NepaliDatePickerViewController

fun NepaliDatePickerViewController(initialSelectedDate: SimpleDate?, locale: NepaliDateLocale, yearRangeStart: Int, yearRangeEnd: Int, selectableDates: NepaliSelectableDates?, options: NepaliCalendarOptions?, events: NepaliEventOptions?, onHeightChange: (Float) -> Unit, onDateSelected: (CustomCalendar?) -> Unit): UIViewController(source)

Hosts the full-size NepaliDatePicker for a Swift caller.

Composable functions cannot be called from Swift, so this factory is the iOS entry point to the calendar grid. Wrap the returned controller in a UIViewControllerRepresentable to embed it in SwiftUI.

Parameters

initialSelectedDate

date selected when the picker first appears, or null for no selection.

locale

language, date format and digit script the picker renders with.

yearRangeStart

first Bikram Sambat year the picker allows.

yearRangeEnd

last Bikram Sambat year the picker allows.

selectableDates

policy deciding which dates are enabled, or null to allow every date.

options

appearance and behaviour knobs, or null for the library defaults.

events

the days to mark, or null to draw the calendar plain. Marking never blocks a date; pass a policy's asSelectableDates() through selectableDates for that.

onHeightChange

receives the content height in points, so the caller can size its frame.

onDateSelected

invoked with the current selection whenever it changes, including the initial value.