syncfusion-blazor-calendars — independently scanned and version-tracked by SaferSkills.
SaferSkills independently audited syncfusion-blazor-calendars (Agent Skill) and scored it 100/100 (green). The audit ran 55 deterministic rules across Security, Supply Chain, Maintenance, Transparency, and Community; it found 0 high-severity and 0 lower-severity findings. The full rule-by-rule trace and per-finding evidence are below. Free, methodology-open.
Findings & checks · 0 flagged
Every scanned point with the score it earned and what moved between them.
First recorded scan — no prior version to compare against.
The primary manifest — the file an agent reads to learn what this artifact does.
The Calendar component is a lightweight, feature-rich date selection component that provides flexible date picking, multiple views (month/year/decade), date range constraints, localization, and accessibility compliance. Use this skill whenever you need to implement date selection, calendar display, or date-based UI interactions.
Use this skill when:
Related components:
| Feature | Details |
|---|---|
| Views | Month (default), Year, Decade - hierarchical drill-down navigation |
| Selection | Single date, date ranges (Min/Max), multi-select |
| Data Types | DateTime, DateTime?, DateOnly (.NET 6+) |
| Binding | One-way, two-way (@bind-Value), dynamic |
| Events | ValueChange, OnRenderDayCell, Created, Destroyed, Navigated |
| Localization | Multi-language, RTL support, locale customization |
| Accessibility | WCAG 2.2 AA, keyboard navigation, screen reader support |
| Styling | CSS customization, theme integration, special date highlights |
#### Getting Started 📄 Read: references/getting-started.md
#### Calendar Views & Navigation 📄 Read: references/calendar-views.md
#### Date Selection & Data Binding 📄 Read: references/date-selection-binding.md
@bind-Value)#### Events & Interactions 📄 Read: references/events-handling.md
#### Styling & Customization 📄 Read: references/styling-appearance.md
#### Localization & Globalization 📄 Read: references/localization-globalization.md
#### Accessibility & Keyboard Navigation 📄 Read: references/accessibility.md
#### Advanced Features & Patterns 📄 Read: references/advanced-features.md
@using Syncfusion.Blazor.Calendars
<!-- Basic Calendar -->
<SfCalendar TValue="DateTime?" Value="@SelectedDate"></SfCalendar>
<!-- Calendar with Date Range -->
<SfCalendar TValue="DateTime?"
Value="@SelectedDate"
Min="@MinDate"
Max="@MaxDate">
</SfCalendar>
<!-- Calendar with Value Change Event -->
<SfCalendar TValue="DateTime?" @bind-Value="@SelectedDate">
<CalendarEvents TValue="DateTime?" ValueChange="@OnDateChanged"></CalendarEvents>
</SfCalendar>
<!-- Multi-Selection Calendar -->
<SfCalendar TValue="DateTime?"
IsMultiSelection="true"
@bind-Values="@SelectedDates">
<CalendarEvents TValue="DateTime?"
Selected="@OnDateSelected"
DeSelected="@OnDateDeselected">
</CalendarEvents>
</SfCalendar>
@code {
public DateTime? SelectedDate { get; set; } = DateTime.Now;
public DateTime[] SelectedDates { get; set; } = new DateTime[] { };
private void OnDateChanged(ChangedEventArgs<DateTime?> args)
{
SelectedDate = args.Value;
// Handle date change
}
private void OnDateSelected(SelectedEventArgs<DateTime?> args)
{
// Handle date added to selection
}
private void OnDateDeselected(DeSelectedEventArgs<DateTime?> args)
{
// Handle date removed from selection
}
}#### Pattern 1: Date Range Selection Define Min and Max boundaries to constrain user selection:
<SfCalendar TValue="DateTime?" Value="@SelectedDate"
Min="@MinDate" Max="@MaxDate"></SfCalendar>#### Pattern 2: Two-Way Data Binding Keep Calendar in sync with component state:
<p>Selected: @SelectedDate</p>
<SfCalendar TValue="DateTime?" @bind-Value="@SelectedDate"></SfCalendar>#### Pattern 3: Custom Cell Rendering Highlight or customize specific date cells during render:
<SfCalendar TValue="DateTime?">
<CalendarEvents TValue="DateTime?" OnRenderDayCell="@CustomizeCell"></CalendarEvents>
</SfCalendar>#### Pattern 4: View Restrictions Limit navigation to specific view levels (e.g., Year → Month only):
<SfCalendar TValue="DateTime?"
Start="CalendarView.Year"
Depth="CalendarView.Month"></SfCalendar>#### Pattern 5: Localization Render calendar in specific language/culture:
<SfCalendar TValue="DateTime?" EnableRtl="false"></SfCalendar>| Property | Type | Purpose | Example |
|---|---|---|---|
Value | TValue | Selected date (one-way binding) | Value="@SelectedDate" |
@bind-Value | TValue | Two-way data binding | @bind-Value="@SelectedDate" |
Values | DateTime[] | Multiple selected dates (multi-select mode) | Values="@SelectedDates" |
@bind-Values | DateTime[] | Two-way binding for multi-selection | @bind-Values="@SelectedDates" |
IsMultiSelection | bool | Enable multiple date selection | IsMultiSelection="true" |
Min | DateTime | Earliest selectable date (inclusive) | Min="@minSelectableDate" |
Max | DateTime | Latest selectable date (inclusive) | Max="@maxSelectableDate" |
Start | CalendarView | Initial view (Month/Year/Decade) | Start="CalendarView.Year" |
Depth | CalendarView | Deepest view level for drilling | Depth="CalendarView.Month" |
ShowTodayButton | bool | Display "Today" button in footer | ShowTodayButton="true" |
CalendarMode | CalendarType | Calendar system (Gregorian/Islamic) | CalendarMode="CalendarType.Islamic" |
WeekRule | CalendarWeekRule | Week numbering calculation rule | WeekRule="CalendarWeekRule.FirstDay" |
DayHeaderFormat | DayHeaderFormats | Day header display format | DayHeaderFormat="DayHeaderFormats.Short" |
EnableRtl | bool | Right-to-left layout | EnableRtl="true" |
WeekNumber | bool | Display week numbers in calendar | WeekNumber="true" |
FirstDayOfWeek | int | First day (0=Sunday, 1=Monday) | FirstDayOfWeek="1" |
CssClass | string | Custom CSS class for styling | CssClass="custom-calendar" |
Enabled | bool | Enable/disable component | Enabled="false" |
All calendar components use child event components to declare event handlers. This approach provides type safety and clear separation of concerns.
#### Event Child Components
<CalendarEvents> child component<DatePickerEvents> child component<DateRangePickerEvents> child component<DateTimePickerEvents> child component<TimePickerEvents> child component#### Example: Calendar with Events
<SfCalendar TValue="DateTime?" @bind-Value="@SelectedDate">
<CalendarEvents TValue="DateTime?"
ValueChange="@OnValueChanged"
OnRenderDayCell="@OnDayCellRender"
Navigated="@OnNavigated">
</CalendarEvents>
</SfCalendar>
@code {
private DateTime? SelectedDate { get; set; }
private void OnValueChanged(ChangedEventArgs<DateTime?> args)
{
Console.WriteLine($"Date changed: {args.Value}");
}
private void OnDayCellRender(RenderDayCellEventArgs args)
{
// Disable weekends
if (args.Date.DayOfWeek == DayOfWeek.Saturday || args.Date.DayOfWeek == DayOfWeek.Sunday)
{
args.IsDisabled = true;
}
}
private void OnNavigated(NavigatedEventArgs args)
{
Console.WriteLine($"Navigated to: {args.View}");
}
}#### Common Event Patterns
Pattern 1: Value Change with Validation
<SfDatePicker TValue="DateTime?" @bind-Value="@OrderDate">
<DatePickerEvents TValue="DateTime?" ValueChange="@ValidateAndUpdate"></DatePickerEvents>
</SfDatePicker>
@code {
private DateTime? OrderDate { get; set; }
private void ValidateAndUpdate(ChangedEventArgs<DateTime?> args)
{
if (args.Value.HasValue && args.Value.Value > DateTime.Now.AddMonths(6))
{
// Show error - date too far in future
OrderDate = DateTime.Now;
}
else
{
OrderDate = args.Value;
}
}
}Pattern 2: Popup Lifecycle Management
<SfDateTimePicker TValue="DateTime?" @bind-Value="@AppointmentTime">
<DateTimePickerEvents TValue="DateTime?"
OnOpen="@HandlePopupOpen"
OnClose="@HandlePopupClose">
</DateTimePickerEvents>
</SfDateTimePicker>
@code {
private DateTime? AppointmentTime { get; set; }
private void HandlePopupOpen(PopupObjectArgs args)
{
Console.WriteLine("Popup opened");
// Can cancel opening: args.Cancel = true;
}
private void HandlePopupClose(PopupObjectArgs args)
{
Console.WriteLine("Popup closed");
}
}Pattern 3: Custom Cell Rendering
<SfCalendar TValue="DateTime?" @bind-Value="@EventDate">
<CalendarEvents TValue="DateTime?" OnRenderDayCell="@CustomizeCells"></CalendarEvents>
</SfCalendar>
@code {
private DateTime? EventDate { get; set; }
private List<DateTime> EventDates = new List<DateTime>
{
DateTime.Now.AddDays(5),
DateTime.Now.AddDays(10)
};
private void CustomizeCells(RenderDayCellEventArgs args)
{
// Highlight event dates
if (EventDates.Any(d => d.Date == args.Date.Date))
{
args.CellData.ClassList = "e-special-date";
}
}
}#### Event Argument Types Reference
IMPORTANT: Different components use different event argument types for the ValueChange event:
| Component | ValueChange Event Argument Type | Notes |
|---|---|---|
| Calendar | ChangedEventArgs<TValue> | For single and multi-date selection |
| DatePicker | ChangedEventArgs<TValue> | Includes Value, IsInteracted, Event properties |
| DateTimePicker | ChangedEventArgs<TValue> | Same as DatePicker |
| TimePicker | ChangeEventArgs<TValue> | Note: Different class name (no 'd') |
| DateRangePicker | RangePickerEventArgs<TValue> | Includes StartDate and EndDate properties |
Key Differences:
ChangedEventArgs<TValue> (with 'd') - Used by Calendar, DatePicker, DateTimePickerValue, Values (for multi-selection), IsInteracted, Event, Element, NameChangeEventArgs<TValue> (no 'd') - Used by TimePicker onlyValue, Text, IsInteracted, Event, ElementRangePickerEventArgs<TValue> - Used by DateRangePicker onlyStartDate, EndDate, Text, Value, IsInteracted, Event, ElementA comprehensive skill for implementing and customizing the DatePicker component. This skill helps you install, configure, and integrate DatePicker across Blazor Server, Blazor WebAssembly, and Blazor Web App projects.
Use this skill when you need to:
The DatePicker component provides an intuitive calendar UI for users to select single dates. It supports:
#### 1. Install NuGet Package
dotnet add package Syncfusion.Blazor.Calendars
dotnet add package Syncfusion.Blazor.Themes#### 2. Import in _Imports.razor
@using Syncfusion.Blazor
@using Syncfusion.Blazor.Calendars#### 3. Register in Program.cs
builder.Services.AddSyncfusionBlazor();#### 4. Add Theme in App.razor or Layout
<link href="_content/Syncfusion.Blazor.Themes/bootstrap5.css" rel="stylesheet" />
<script src="_content/Syncfusion.Blazor.Core/scripts/syncfusion-blazor.min.js"></script>#### 5. Use in Component
<SfDatePicker TValue="DateTime?" @bind-Value="@selectedDate">
<DatePickerEvents TValue="DateTime?" ValueChange="@OnDateChange"></DatePickerEvents>
</SfDatePicker>
@code {
DateTime? selectedDate = new DateTime(2026, 3, 18);
void OnDateChange(ChangedEventArgs<DateTime?> args)
{
selectedDate = args.Value;
}
}Choose a reference based on your task:
#### Getting Started 📄 Read: references/getting-started.md
#### Data Binding 📄 Read: references/data-binding.md
Value property@bind-Value#### Date Formats & Input 📄 Read: references/date-formats-and-input.md
#### Date Range & Constraints 📄 Read: references/date-range-and-constraints.md
#### Events & Interaction 📄 Read: references/events.md
#### Advanced Features 📄 Read: references/advanced-features.md
#### Styling & Appearance 📄 Read: references/styling-and-appearance.md
#### Accessibility 📄 Read: references/accessibility.md
#### Server vs WebAssembly 📄 Read: references/server-vs-webassembly.md
#### Troubleshooting 📄 Read: references/troubleshooting.md
#### Pattern 1: Basic Date Selection
<SfDatePicker TValue="DateTime?" Value="@selectedDate"
Placeholder="Select a date"></SfDatePicker>Use when: User needs a simple, standard date picker for form input.
#### Pattern 2: Date Range with Constraints
<SfDatePicker TValue="DateTime?" Value="@selectedDate"
Min="@minDate" Max="@maxDate"></SfDatePicker>Use when: Date must fall within a specific range (e.g., future dates only, event dates).
#### Pattern 3: Two-Way Binding
<SfDatePicker TValue="DateTime?" @bind-Value="@formData.BirthDate"></SfDatePicker>Use when: DatePicker must automatically update parent component state or form data.
#### Pattern 4: Event-Driven Logic
<SfDatePicker TValue="DateTime?">
<DatePickerEvents TValue="DateTime?" ValueChange="@OnDateSelected"></DatePickerEvents>
</SfDatePicker>
@code {
void OnDateSelected(ChangedEventArgs<DateTime?> args)
{
// Trigger calculations, API calls, or validation
}
}Use when: Selection should trigger workflows, calculations, or dependent updates.
#### Pattern 5: Formatted Display with Custom Input
<SfDatePicker TValue="DateTime?" Value="@selectedDate"
Format="dd/MM/yyyy" Placeholder="DD/MM/YYYY"></SfDatePicker>Use when: Date display must match regional or business requirements.
| Property | Type | Purpose |
|---|---|---|
Value | TValue | The selected date (one-way binding) |
@bind-Value | TValue | Two-way data binding |
Min | DateTime | Earliest selectable date |
Max | DateTime | Latest selectable date |
Format | string | Display format pattern (e.g., "dd/MM/yyyy") |
Placeholder | string | Input placeholder text |
AllowEdit | bool | Allow manual text input editing |
StrictMode | bool | Restrict to valid dates only |
EnableMask | bool | Enable input masking for date entry |
OpenOnFocus | bool | Open calendar popup when input is focused |
FloatLabelType | FloatLabelType | Float label behavior (Auto/Always/Never) |
InputFormats | string[] | Array of acceptable input formats |
Enabled | bool | Enable/disable component |
Readonly | bool | Read-only mode (no user input) |
ShowClearButton | bool | Show clear button to reset value |
WeekNumber | bool | Display week numbers in calendar |
Start | CalendarView | Initial calendar view (Month/Year/Decade) |
Depth | CalendarView | Deepest view level allowed |
ZIndex | int | Z-index for popup positioning |
Width | string | Component width (e.g., "300px") |
CssClass | string | Custom CSS class for styling |
A comprehensive skill for implementing and customizing the DateRangePicker component. This component enables users to select date ranges with calendar pickers, providing features for range constraints, customization, accessibility, and globalization.
Use this skill when you need to:
SfDateRangePicker is a calendar-based input component that allows users to select a continuous date range. Key characteristics:
#### Getting Started 📄 Read: references/getting-started.md
#### Range Selection & Data Binding 📄 Read: references/range-selection.md
#### Customization & Styling 📄 Read: references/customization-and-styling.md
#### Data & Globalization 📄 Read: references/data-and-globalization.md
#### Events & Interactions 📄 Read: references/events-and-interactions.md
#### Accessibility 📄 Read: references/accessibility.md
#### Basic DateRangePicker
@using Syncfusion.Blazor.Calendars
<SfDateRangePicker TValue="DateTime?" Placeholder="Select a date range"></SfDateRangePicker>#### With Date Constraints
<SfDateRangePicker TValue="DateTime?"
Placeholder="Choose a range"
Min="@MinDate"
Max="@MaxDate">
</SfDateRangePicker>
@code {
public DateTime MinDate { get; set; } = new DateTime(2024, 1, 1);
public DateTime MaxDate { get; set; } = new DateTime(2024, 12, 31);
}#### With Data Binding (StartDate/EndDate)
<SfDateRangePicker TValue="DateTime?"
@bind-StartDate="StartDate"
@bind-EndDate="EndDate">
</SfDateRangePicker>
@code {
private DateTime? StartDate { get; set; }
private DateTime? EndDate { get; set; }
}#### With Range Constraints
<SfDateRangePicker TValue="DateTime?"
MinDays="3"
MaxDays="30"
@bind-StartDate="StartDate"
@bind-EndDate="EndDate">
</SfDateRangePicker>
@code {
// User must select range between 3 and 30 days
private DateTime? StartDate { get; set; }
private DateTime? EndDate { get; set; }
}#### With Preset Ranges
<SfDateRangePicker TValue="DateTime?">
<DateRangePickerPresets>
<DateRangePickerPreset Label="Last 7 Days" Start="@last7DaysStart" End="@currentDate"></DateRangePickerPreset>
<DateRangePickerPreset Label="Last 30 Days" Start="@last30DaysStart" End="@currentDate"></DateRangePickerPreset>
<DateRangePickerPreset Label="This Month" Start="@currentMonthStart" End="@currentDate"></DateRangePickerPreset>
</DateRangePickerPresets>
</SfDateRangePicker>
@code {
private DateTime currentDate = DateTime.Now;
private DateTime last7DaysStart = DateTime.Now.AddDays(-7);
private DateTime last30DaysStart = DateTime.Now.AddDays(-30);
private DateTime currentMonthStart = new DateTime(DateTime.Now.Year, DateTime.Now.Month, 1);
}| Property | Type | Purpose |
|---|---|---|
StartDate | TValue | Start date of the range (one-way binding) |
@bind-StartDate | TValue | Two-way binding for start date |
EndDate | TValue | End date of the range (one-way binding) |
@bind-EndDate | TValue | Two-way binding for end date |
Value | Object | Combined range value (legacy) |
Min | DateTime | Earliest selectable date |
Max | DateTime | Latest selectable date |
MinDays | int? | Minimum required days in range |
MaxDays | int? | Maximum allowed days in range |
Presets | List<Presets> | Predefined date range presets |
Separator | string | Separator between start and end dates (default: "-") |
Format | string | Display format pattern |
Placeholder | string | Input placeholder text |
AllowEdit | bool | Allow manual text input editing |
StrictMode | bool | Restrict to valid dates only |
OpenOnFocus | bool | Open popup when input is focused |
FloatLabelType | FloatLabelType | Float label behavior |
Enabled | bool | Enable/disable component |
Readonly | bool | Read-only mode |
ShowClearButton | bool | Show clear button |
WeekNumber | bool | Display week numbers |
FirstDayOfWeek | int | First day (0=Sunday, 1=Monday) |
ZIndex | int | Z-index for popup |
Width | string | Component width |
CssClass | string | Custom CSS class |
#### Pattern 1: Range Selection with Validation
<SfDateRangePicker TValue="DateTime?"
@bind-Value="BookingRange"
Min="@minBookingDate"
Placeholder="Select booking dates">
</SfDateRangePicker>
@code {
private DateTime? BookingRange { get; set; }
private DateTime minBookingDate = DateTime.Today;
}#### Pattern 2: Event Handling
<SfDateRangePicker TValue="DateTime?"
@bind-StartDate="@StartDate"
@bind-EndDate="@EndDate">
<DateRangePickerEvents TValue="DateTime?" ValueChange="@OnDateRangeChange"></DateRangePickerEvents>
</SfDateRangePicker>
@code {
private DateTime? StartDate { get; set; }
private DateTime? EndDate { get; set; }
private void OnDateRangeChange(RangePickerEventArgs<DateTime?> args)
{
// Handle date range selection
Console.WriteLine($"Start: {args.StartDate}, End: {args.EndDate}");
}
}#### Pattern 3: Multiple Instances with Different Constraints
<div>
<h4>Q1 Reporting Period (Jan-Mar)</h4>
<SfDateRangePicker TValue="DateTime?"
Min="@new DateTime(2024, 1, 1)"
Max="@new DateTime(2024, 3, 31)"
Placeholder="Select dates">
</SfDateRangePicker>
</div>
<div>
<h4>Q2 Reporting Period (Apr-Jun)</h4>
<SfDateRangePicker TValue="DateTime?"
Min="@new DateTime(2024, 4, 1)"
Max="@new DateTime(2024, 6, 30)"
Placeholder="Select dates">
</SfDateRangePicker>
</div>A comprehensive guide for implementing and customizing the DateTimePicker component. The DateTimePicker enables users to select both date and time values with support for multiple formats, masks, globalization, and extensive customization options.
Use this skill when you need to:
#### Getting Started 📄 Read: references/getting-started.md
#### Date & Time Formatting 📄 Read: references/date-time-formatting.md
#### Data Binding & Events 📄 Read: references/data-binding-and-events.md
#### Date Ranges & Special Dates 📄 Read: references/date-ranges-and-special-dates.md
#### Masking & Input Validation 📄 Read: references/masking-and-input-validation.md
#### Customization & Styling 📄 Read: references/customization-and-styling.md
#### Globalization & Accessibility 📄 Read: references/globalization-and-accessibility.md
Here's a minimal working example to get started with the DateTimePicker:
@page "/datetimepicker-demo"
@using Syncfusion.Blazor.Calendars
<div>
<label>Select Date and Time:</label>
<SfDateTimePicker TValue="DateTime?"
@bind-Value="@selectedDateTime"
Placeholder="Choose date and time">
<DateTimePickerEvents TValue="DateTime?" ValueChange="@OnValueChanged"></DateTimePickerEvents>
</SfDateTimePicker>
@if (selectedDateTime.HasValue)
{
<p>Selected: @selectedDateTime.Value.ToString("g")</p>
}
</div>
@code {
private DateTime? selectedDateTime;
private void OnValueChanged(ChangedEventArgs<DateTime?> args)
{
selectedDateTime = args.Value;
Console.WriteLine($"Date changed to: {selectedDateTime}");
}
}#### Pattern 1: With Date Range Constraints
<SfDateTimePicker TValue="DateTime?"
Min="@minDate"
Max="@maxDate"
Value="selectedDateTime">
</SfDateTimePicker>
@code {
private DateTime minDate = new DateTime(2024, 1, 1);
private DateTime maxDate = new DateTime(2024, 12, 31);
private DateTime? selectedDateTime;
}#### Pattern 2: With Format Customization
<SfDateTimePicker TValue="DateTime?"
Format="dd/MM/yyyy HH:mm"
Value="selectedDateTime">
</SfDateTimePicker>#### Pattern 3: With Input Mask
<SfDateTimePicker TValue="DateTime?"
EnableMask="true"
Format="dd/MM/yyyy HH:mm"
Value="selectedDateTime">
<DateTimePickerMaskPlaceholder Day="dd" Month="MM" Year="yyyy" Hour="HH" Minute="mm"></DateTimePickerMaskPlaceholder>
</SfDateTimePicker>#### Pattern 4: With Data Binding
<SfDateTimePicker TValue="DateTime?"
@bind-Value="model.CreatedDate">
<DateTimePickerEvents TValue="DateTime?" ValueChange="@OnDateChanged"></DateTimePickerEvents>
</SfDateTimePicker>| Property | Type | Purpose |
|---|---|---|
Value | TValue | Gets or sets the selected date-time value |
@bind-Value | TValue | Two-way data binding |
Format | string | Display format (e.g., "dd/MM/yyyy HH:mm") |
TimeFormat | string | Format for time portion only (e.g., "HH:mm") |
Placeholder | string | Placeholder text for the input field |
Min | DateTime | Minimum selectable date (date portion) |
Max | DateTime | Maximum selectable date (date portion) |
MinTime | DateTime | Minimum selectable time |
MaxTime | DateTime | Maximum selectable time |
Step | int | Time interval step in minutes (default: 30) |
ScrollTo | DateTime? | Initial scroll position in time list |
AllowEdit | bool | Allows manual text input |
StrictMode | bool | Enforces strict input validation |
EnableMask | bool | Enable input masking for date/time entry |
OpenOnFocus | bool | Opens popup on input focus |
FloatLabelType | FloatLabelType | Float label behavior |
Enabled | bool | Enables/disables the component |
Readonly | bool | Makes the component read-only |
ShowClearButton | bool | Show clear button |
ShowTodayButton | bool | Displays today button in calendar |
WeekNumber | bool | Display week numbers |
FirstDayOfWeek | int | First day (0=Sunday, 1=Monday) |
Start | CalendarView | Initial calendar view |
Depth | CalendarView | Deepest view level |
ZIndex | int | Z-index for popup |
Width | string | Component width |
CssClass | string | Custom CSS class |
A comprehensive skill for implementing and customizing the TimePicker component. This skill covers installation, configuration, data binding, events, styling, accessibility, internationalization, and advanced features like input masking.
Use this skill when you need to:
The SfTimePicker is a Blazor input component for time selection. It provides:
#### Basic TimePicker
@using Syncfusion.Blazor.Calendars
<SfTimePicker TValue="DateTime?" Placeholder="Select a time"></SfTimePicker>#### TimePicker with Value Binding
@using Syncfusion.Blazor.Calendars
<p>Selected Time: @SelectedTime</p>
<SfTimePicker TValue="DateTime?" @bind-Value="@SelectedTime"></SfTimePicker>
@code {
public DateTime? SelectedTime { get; set; } = DateTime.Now;
}#### TimePicker with Format and Step
@using Syncfusion.Blazor.Calendars
<SfTimePicker TValue="DateTime?"
Value="@TimeValue"
Format="HH:mm"
Step=60
Placeholder="Select time (24-hour)">
</SfTimePicker>
@code {
public DateTime TimeValue { get; set; } = DateTime.Now;
}| Property | Type | Description | Default |
|---|---|---|---|
Value | TValue | Current time value (one-way binding) | null |
@bind-Value | TValue | Two-way data binding | - |
Placeholder | string | Placeholder text in input | "Select a time" |
Format | string | Display format string (HH:mm, hh:mm tt) | Culture-based |
InputFormats | string[] | Accepted input format patterns | Culture-based |
Step | int | Time interval in minutes | 30 |
ScrollTo | DateTime? | Initial scroll position in time list | null |
Min | DateTime | Minimum selectable time | 00:00 |
Max | DateTime | Maximum selectable time | 23:59 |
AllowEdit | bool | Allow manual text input | true |
StrictMode | bool | Enforce strict input validation | false |
EnableMask | bool | Enable input masking | false |
OpenOnFocus | bool | Open popup when input is focused | false |
FloatLabelType | FloatLabelType | Float label behavior | Never |
Enabled | bool | Enable/disable component | true |
Readonly | bool | Read-only mode | false |
ShowClearButton | bool | Show clear button | false |
EnableRtl | bool | Enable right-to-left (RTL) direction | false |
FullScreen | bool | Full-screen mode on mobile | false |
ZIndex | int | Z-index for popup | 1000 |
Width | string | Component width | "100%" |
CssClass | string | Custom CSS class | null |
TabIndex | int | Tab order index | 0 |
#### Getting Started 📄 Read: references/getting-started.md
#### Time Formats 📄 Read: references/time-formats.md
#### Data Binding 📄 Read: references/data-binding.md
#### Events and Handlers 📄 Read: references/events-and-handlers.md
#### Styling and Appearance 📄 Read: references/styling-and-appearance.md
#### Accessibility and Globalization 📄 Read: references/accessibility-and-globalization.md
#### Mask Support 📄 Read: references/mask-support.md
#### Pattern 1: Simple Time Selection
When users need a basic time picker without complex requirements:
<SfTimePicker TValue="DateTime?"
@bind-Value="@AppointmentTime"
Placeholder="Select appointment time">
</SfTimePicker>#### Pattern 2: Business Hours Only
When time selection should be limited to specific hours:
<SfTimePicker TValue="DateTime?"
@bind-Value="@BusinessTime"
Min="@new DateTime(2026, 1, 1, 09, 0, 0)"
Max="@new DateTime(2026, 1, 1, 17, 0, 0)"
Step=30
Format="HH:mm">
</SfTimePicker>
@code {
public DateTime? BusinessTime { get; set; }
}#### Pattern 3: 12-Hour Format with AM/PM
When displaying time in 12-hour format:
<SfTimePicker TValue="DateTime?"
@bind-Value="@UserTime"
Format="hh:mm tt"
Placeholder="Select time (12-hour)">
</SfTimePicker>
@code {
public DateTime? UserTime { get; set; } = DateTime.Now;
}#### Pattern 4: With Event Handling
When tracking time selection changes:
<SfTimePicker TValue="DateTime?">
<TimePickerEvents TValue="DateTime?" ValueChange="@OnTimeChanged"></TimePickerEvents>
</SfTimePicker>
@code {
private void OnTimeChanged(ChangeEventArgs<DateTime?> args)
{
Console.WriteLine($"Time selected: {args.Value}");
}
}Syncfusion.Blazor.CalendarsSyncfusion.Blazor.ThemesProgram.csReady to implement Calendar components? Start with Getting Started guides above for setup, then navigate to other references based on your specific needs.
Next Steps: Start with the Getting Started guide for your chosen component, then navigate to other references based on your specific task.
For detailed implementation patterns, complete code examples, and troubleshooting guidance, read the appropriate reference file based on your specific needs.
~30 seconds. Free. No account. Every finding cites a rule and a line of evidence.