Skip to content

Inputs

Calendar

Bit.BlazorUI

BitCalendar is a fully-featured inline calendar for browsing and selecting a single date, or a date and time when the built-in time picker is enabled. It offers day, month and year grids, day events with details, and flexible day/week rules such as disabled and highlighted dates, a custom first day of week and week numbers. It works with any culture and time zone, including right-to-left and non-Gregorian calendars, and every grid follows the WAI-ARIA grid pattern for the keyboard.

Dates & navigation

The range of dates it allows, the days it disables, highlights or classes, the week layout, and the month and year pickers.

Min & Max

MinDate and MaxDate bound the selectable range: the days outside it are disabled and the month, year and year-range navigation stops at the edges. DisablePast and DisableFuture do the same against today without a bound to keep up to date; where both apply the narrower wins, and today stays selectable under either.
  • The bounds rule out whole days, compared in the calendar's TimeZone: the day a bound falls on stays selectable whatever time of day it carries. That time only limits the hours of that one day in the Time picker.
  • The months and years wholly outside the range are disabled in the month and year grids, the arrows are disabled at the edges, and the keyboard stops there too.
  • A calendar whose value (or today) is outside the range opens on the month of the nearest bound. The bounds never change or reject a value set from code, so validate one that may come from elsewhere yourself.
  • DisablePast / DisableFuture measure from Today when it is set, and the bound they draw is an instant: with a time picker, the hours of today before (or after) the current minute are ruled out as well.


MinDate / MaxDate = ±5 days:
November 2026
S
M
T
W
T
F
S


MinDate / MaxDate = -5 years / +1 year:
November 2026
S
M
T
W
T
F
S


DisablePast:
November 2026
S
M
T
W
T
F
S


DisableFuture:
November 2026
S
M
T
W
T
F
S

Disabled & highlighted days

Beyond the bounds, single days can be ruled out with DisabledDates, whole weekdays with DisabledDaysOfWeek, and anything else with the IsDateDisabled predicate. A disabled day is not selectable and the arrow keys skip over it. HighlightedDates marks days without disabling them, and GetDayClass hands any day a class of your own.
  • The rules add up: a day is disabled when any of them, or the bounds, says so. A disabled day is a disabled button, so a day carrying events cannot open its details dialog either.
  • DisabledDates and HighlightedDates are compared by day in the calendar's TimeZone; the time of day they carry is ignored.
  • IsDateDisabled and GetDayClass are called with the day at midnight in that zone, for every day drawn (the days of the adjacent months included) on every render, so keep them cheap. d.Day and d.Month are Gregorian: under a culture with another calendar, read the parts through Culture.DateTimeFormat.Calendar.
  • GetDayClass adds its class to the day's button. A class written in a scoped (.razor.css) stylesheet needs ::deep to reach it; per-state styles with no function of your own are on Classes / Styles (see the Style & Class section).
  • HighlightToday (default true) paints today's day. Turned off, the day looks like any other but still reports aria-current="date" to a screen reader.
None of these rules changes or rejects a value set from code.


DisabledDaysOfWeek (weekends):
November 2026
S
M
T
W
T
F
S


DisabledDates & IsDateDisabled (three dates, plus every odd day):
November 2026
S
M
T
W
T
F
S


HighlightedDates & GetDayClass (Sundays in red):
November 2026
S
M
T
W
T
F
S


HighlightToday = false:
November 2026
S
M
T
W
T
F
S

Week layout

FirstDayOfWeek overrides the day the week starts on, WeekNumberRule picks how ShowWeekNumbers counts the weeks (Monday plus FirstFourDayWeek is ISO 8601), ShowOutsideDays hides the days of the adjacent months, and FixedWeeks always renders six weeks so the height never changes while browsing.
  • FirstDayOfWeek defaults to the first day of the week of the Culture, and also decides where Home / End land and how the weeks are numbered.
  • WeekNumberRule defaults to FirstFullWeek. The numbers come from the culture's own calendar (Calendar.GetWeekOfYear), which can number the last days of December 53 where ISO 8601 already counts week 1 of the next year. The column is headed by a number sign named by WeekNumbersHeaderTitle, and each number is titled with WeekNumberTitle ({0} is the number).
  • A day of an adjacent month can be picked like any other, which moves the view onto its month. With ShowOutsideDays off those cells stay empty, and FixedWeeks then pads the grid with empty rows.
  • With more than one month on screen (see Multiple months), FixedWeeks is always on and ShowOutsideDays has no effect.


ISO 8601 week numbers:
November 2026
#
M
T
W
T
F
S
S
44
45
46
47
48
49


ShowOutsideDays = false:
November 2026
S
M
T
W
T
F
S


FixedWeeks:
November 2026
S
M
T
W
T
F
S

Month & year pickers

ShowMonthPicker toggles the month and year grids, and ShowMonthPickerAsOverlay moves them on top of the day grid, reached from the month title. HighlightSelectedMonth marks the month that is displayed and HighlightCurrentMonth the current one - worth turning on, since otherwise the month grid shows no sign of where you are.
  • ShowMonthPicker (default true) turned off leaves the arrows as the only way to move, and the month title becomes plain text.
  • With ShowMonthPickerAsOverlay the month title is a button (named by MonthPickerToggleTitle) that swaps the day grid for the month grid; picking a month, or Escape, brings the day grid back. An inline time picker takes the place beside the day grid, so with one on screen the month picker works this way too.
  • The arrows of the month grid move by a year and its title opens the year grid: twelve years, whose arrows move by twelve and whose title goes back to the months. Picking a month or a year only moves the view; it never changes the value.
  • HighlightSelectedMonth marks the month on screen, not the month of the value. HighlightCurrentMonth marks the month of today (or of Today) while its year is on screen, painted with the Color. Either way, the current month and year report aria-current="date" to a screen reader.


ShowMonthPicker:

November 2026
S
M
T
W
T
F
S



ShowMonthPickerAsOverlay:

November 2026
S
M
T
W
T
F
S



HighlightSelectedMonth & HighlightCurrentMonth:
November 2026
S
M
T
W
T
F
S

Feedback

Found a mistake, a gap, or something that could be clearer? Every page and every component is one click from its source.