Skip to content
IzzyBlazor 0.1.0-alpha.20

Enter all results ↑ ↓ move Esc close

DateRangeField

Since 0.1.0-alpha.20
Two whole days, both included, in the browser's own date inputs.

IzzyBlazor.DateRangeField in the IzzyBlazor.Core package, generated from the 0.1.0-alpha.20 assembly and its doc comments.

Properties (22)

ReadOnlybool = falseAdded in 0.1.0-alpha.20

Makes the field read-only: it can be focused, and it still posts.

MinDateOnly?Added in 0.1.0-alpha.20

The earliest day either end can be.

MaxDateOnly?Added in 0.1.0-alpha.20

The latest day either end can be.

MinDaysint?Added in 0.1.0-alpha.20

The fewest days a range can span, both ends counted.

MaxDaysint?Added in 0.1.0-alpha.20

The most days a range can span, both ends counted.

AllowDisabledInRangebool = falseAdded in 0.1.0-alpha.20

Lets a range span days that DateDisabled turns off, as a stay can span a day with no arrivals. Its ends still can't be those days.

UseNativebool = falseAdded in 0.1.0-alpha.20

Keeps the browser's calendars in place of the library's months. DateDisabled, MinDays and MaxDays are then checked only on the server.

DisplayMonthsint = 2Added in 0.1.0-alpha.20

How many months show side by side, from 1 to 6. Defaults to 2. A phone shows one.

Clearablebool = falseAdded in 0.1.0-alpha.20

A button in the field that empties both ends, there while it holds something. Off by default.

PresetsIReadOnlyList<DateRangePreset>?Added in 0.1.0-alpha.20

Ranges to choose in one click, beside the months, such as Common. They show with the months, so not with UseNative or no script.

ChooseLabelstring?Added in 0.1.0-alpha.20

The name of the months' button, in place of "Choose dates" and "Change dates" with both days.

StartTextstring?Added in 0.1.0-alpha.20

The caption of the first date, in place of "Start".

EndTextstring?Added in 0.1.0-alpha.20

The caption of the second date, in place of "End".

FirstDayOfWeekDayOfWeek? (computed)Added in 0.1.0-alpha.20

The first column. Defaults to the culture's first day of the week.

CultureCultureInfo? (computed)Added in 0.1.0-alpha.20

The culture for the month and day names, the first day and the week numbers. Defaults to the current culture.

ShowWeekNumbersbool = falseAdded in 0.1.0-alpha.20

Adds a first column with the week of the year, counted as the culture counts them.

ShowAdjacentDaysbool = trueAdded in 0.1.0-alpha.20

Whether to show the days of the months before and after, muted, in the first and last weeks. Defaults to true.

DateDisabledFunc<DateOnly, bool>?Added in 0.1.0-alpha.20

Whether a day can't be chosen. Checked on the server too, so it stops OnValidSubmit whatever was posted. It's called for every day in the window on every render, so keep it cheap.

DateDisabledWindowTimeSpan?Added in 0.1.0-alpha.20

How far each way from the value or today to call DateDisabled and DayClass, in whole days, for an end the limits don't set. About a year unless set. With DateDisabled, the month stops at the window's edge.

DayClassFunc<DateOnly, string?>?Added in 0.1.0-alpha.20

A class for a day's button, or null. Called like DateDisabled, so keep it cheap.

@bind-ValueDateRange?Added in 0.1.0-alpha.20

The value, bound with @bind-Value.

DisplayNamestring?Added in 0.1.0-alpha.20

The field's name in validation messages from the input itself, such as a value that can't be parsed.

Events (0)

No events.

Types (2)

DateRange

record

Two whole days, both included, either of which may be open. It holds days rather than times, so midnight never enters it. The properties are settable for form binding on a static post.

DateRange members
MemberDescription
Start DateOnly?

The first day, or null for no limit.

End DateOnly?

The last day, included, or null for no limit.

IsEmpty bool

Whether it has no ends, as a static post of an empty field can bind to.

Days int?

How many days it spans, both ends counted, or null with an open end.

Contains(DateOnly day)

Whether this day is in the range.

Contains(DateTime time)

Whether this time's clock date is in the range. Any time on the last day counts.

DateTimeOffset?> ToUtc(TimeZoneInfo zone)

The range as instants in UTC, for a query: from <= x && x < until, either null with an open end. Until is the first instant of the day after End in this zone, so it's right across a change of the clocks, and an index can serve it.

DateRangePreset

record

A range to choose in one click, drawn beside a DateRangeField's months.

DateRangePreset members
MemberDescription
Label string

What the button says.

Start DateOnly

Its first day.

End DateOnly

Its last day, included.

Connection lost

Rejoining the server…