NepaliDatePickerDefaults

Properties

Link copied to clipboard

A default NepaliSelectableDates that allows all dates to be selected.

Link copied to clipboard
Link copied to clipboard
Link copied to clipboard

I will suggest as below considering user's screen width and clarity.

Link copied to clipboard
const val FIRST_DAY_OF_WEEK: Int = 1

The default first day of the week.

Link copied to clipboard

The default shape for date picker dialogs.

Link copied to clipboard

The default tonal elevation used for date picker dialog.

Functions

Link copied to clipboard

fun colors(containerColor: Color = Color.Unspecified, titleContentColor: Color = Color.Unspecified, headlineContentColor: Color = Color.Unspecified, weekdayContentColor: Color = Color.Unspecified, subheadContentColor: Color = Color.Unspecified, navigationContentColor: Color = Color.Unspecified, yearContentColor: Color = Color.Unspecified, disabledYearContentColor: Color = Color.Unspecified, currentYearContentColor: Color = Color.Unspecified, selectedYearContentColor: Color = Color.Unspecified, disabledSelectedYearContentColor: Color = Color.Unspecified, selectedYearContainerColor: Color = Color.Unspecified, disabledSelectedYearContainerColor: Color = Color.Unspecified, dayContentColor: Color = Color.Unspecified, disabledDayContentColor: Color = Color.Unspecified, selectedDayContentColor: Color = Color.Unspecified, disabledSelectedDayContentColor: Color = Color.Unspecified, selectedDayContainerColor: Color = Color.Unspecified, disabledSelectedDayContainerColor: Color = Color.Unspecified, todayContentColor: Color = Color.Unspecified, todayDateBorderColor: Color = Color.Unspecified, dayInSelectionRangeContentColor: Color = Color.Unspecified, dayInSelectionRangeContainerColor: Color = Color.Unspecified, dividerColor: Color = Color.Unspecified, dateTextFieldColors: TextFieldColors? = null): NepaliDatePickerColors

Creates a NepaliDatePickerColors that will potentially animate between the provided colors according to the Material specification.

Link copied to clipboard
fun dayDecorator(markers: Map<SimpleDate, List<Color>>, contentColors: Map<SimpleDate, Color> = emptyMap(), descriptions: Map<SimpleDate, String> = emptyMap()): NepaliDayDecorator

A NepaliDayDecorator built from plain maps, for an app that already holds its events by date.

Link copied to clipboard
fun DialogButton(text: String, onButtonClick: () -> Unit, modifier: Modifier = Modifier, enabled: Boolean = true)

A default button to for Nepali date picker dialog. i.e., "Cancel", "OK"

Link copied to clipboard
fun eventDecorator(policy: NepaliCalendarPolicy, colors: NepaliDayMarkerColors = markerColors(), style: NepaliEventDisplayStyle = NepaliEventDisplayStyle.Default): NepaliDayDecorator

A NepaliDayDecorator that marks the days policy says the institution is closed: its weekly off days, and the holidays its provider reports.

fun eventDecorator(provider: NepaliEventProvider, weeklyOffDays: Set<Int> = NepaliWeekend.Default, colors: NepaliDayMarkerColors = markerColors(), style: NepaliEventDisplayStyle = NepaliEventDisplayStyle.Default): NepaliDayDecorator

eventDecorator for an institution that keeps Nepal's usual week, Saturday off, or none at all. weeklyOffDays = emptySet() marks the provider's holidays and leaves every weekday alone.

Link copied to clipboard
fun eventDisplayStyle(colorWeeklyOff: Boolean = true, colorEvents: Boolean = true, tintContainer: Boolean = false, indicateWeeklyOff: Boolean = false, indicateKinds: Set<NepaliEventKind> = emptySet(), describe: Boolean = true): NepaliEventDisplayStyle

Creates a NepaliEventDisplayStyle, the switches eventDecorator draws a closed day by.

Link copied to clipboard
fun markerColors(weeklyOffColor: Color = Color.Unspecified, publicHolidayColor: Color = Color.Unspecified, religiousColor: Color = Color.Unspecified, regionalColor: Color = Color.Unspecified, observanceColor: Color = Color.Unspecified, eventColor: Color = Color.Unspecified, personalColor: Color = Color.Unspecified, markedContainerColor: Color = Color.Unspecified): NepaliDayMarkerColors

Creates a NepaliDayMarkerColors for the days a NepaliDayDecorator marks.

fun NepaliDateRangePickerHeadlineWithEnglishDate(selectedNepaliStartDate: CustomCalendar?, selectedNepaliEndDate: CustomCalendar?, selectedEnglishStartDate: CustomCalendar?, selectedEnglishEndDate: CustomCalendar?, locale: NepaliDateLocale, englishLocale: NepaliDateLocale, modifier: Modifier = Modifier, isEnglishDateAligned: Boolean = false, calendarSystem: CalendarSystem = CalendarSystem.BIKRAM_SAMBAT)

A Default Headline provider for NepaliDateRangePickerWithEnglish