A nepali date picker which is a simple and fully customizable written in swift
NepaliDatePicker
NepaliDatePicker is a nepali date picker which is a simple and fully customizable written in swift.
Requirements
- iOS 12.1
- Xcode 12
- Swift 5.0
Installation
You can use CocoaPods to install NepaliDatePicker by adding it to your Podfile:
- pod 'NepaliDatePicker'
- pod install
Usage
import 'NepaliDatePicker'
class ViewController: UIViewController, NepaliDatePickerDelegate {
@objc func caleOpenBtnPress(){
let dateView = CalendarVC()
dateView.delegate = self
dateView.headerTintColor = .black
dateView.headerBackgroundColor = .white
dateView.headerLabelFont = UIFont.systemFont(ofSize: 17, weight: .medium)
dateView.headerLabelColor = .black
dateView.weekLabelFont = UIFont.systemFont(ofSize: 16, weight: .medium)
dateView.weekLabelColor = .darkGray
dateView.dayLabelFont = UIFont.systemFont(ofSize: 21, weight: .medium)
dateView.todayDayLabelColor = .red
dateView.dayLabelBackgroundColor = .white
dateView.dayStyle = .roundishSquare
dateView.show()
}
func onDatePickSuccess(year: String, month: String, day: String) {
datelbl.text = String(format: "%@/%@/%@", year, month, day)
}
}