ShadcnLocalizationsExtensions extension

Extension methods for ShadcnLocalizations to provide additional formatting and utility functions.

on

Properties

dateDayAbbreviation String

Available on ShadcnLocalizations, provided by the ShadcnLocalizationsExtensions extension

The abbreviation for the day component (e.g., 'DD').
no setter
dateMonthAbbreviation String

Available on ShadcnLocalizations, provided by the ShadcnLocalizationsExtensions extension

The abbreviation for the month component (e.g., 'MM').
no setter
datePartsOrder List<DatePart>

Available on ShadcnLocalizations, provided by the ShadcnLocalizationsExtensions extension

The order of date parts for the current locale.
no setter
dateYearAbbreviation String

Available on ShadcnLocalizations, provided by the ShadcnLocalizationsExtensions extension

The abbreviation for the year component (e.g., 'YYYY').
no setter

Methods

formatDateTime(DateTime dateTime, {bool showDate = true, bool showTime = true, bool showSeconds = false, bool use24HourFormat = true}) String

Available on ShadcnLocalizations, provided by the ShadcnLocalizationsExtensions extension

Formats a DateTime object into a string.
formatDuration(Duration duration, {bool showDays = true, bool showHours = true, bool showMinutes = true, bool showSeconds = true}) String

Available on ShadcnLocalizations, provided by the ShadcnLocalizationsExtensions extension

Formats a Duration into a string.
formatNumber(double value) String

Available on ShadcnLocalizations, provided by the ShadcnLocalizationsExtensions extension

Formats a number as a string, removing decimal point if it's an integer.
formatTimeOfDay(TimeOfDay time, {bool use24HourFormat = true, bool showSeconds = false}) String

Available on ShadcnLocalizations, provided by the ShadcnLocalizationsExtensions extension

Formats a TimeOfDay object into a string.
getAbbreviatedMonth(int month) String

Available on ShadcnLocalizations, provided by the ShadcnLocalizationsExtensions extension

Gets the abbreviated month name for a given month index (1-12).
getAbbreviatedWeekday(int weekday) String

Available on ShadcnLocalizations, provided by the ShadcnLocalizationsExtensions extension

Gets the abbreviated weekday name for a given weekday index (1-7).
getColorPickerMode(ColorPickerMode mode) String

Available on ShadcnLocalizations, provided by the ShadcnLocalizationsExtensions extension

Gets the localized label for a ColorPickerMode.
getDatePartAbbreviation(DatePart part) String

Available on ShadcnLocalizations, provided by the ShadcnLocalizationsExtensions extension

Gets the abbreviation for a specific DatePart.
getDurationPartAbbreviation(DurationPart part) String

Available on ShadcnLocalizations, provided by the ShadcnLocalizationsExtensions extension

Gets the abbreviation for a DurationPart.
getMonth(int month) String

Available on ShadcnLocalizations, provided by the ShadcnLocalizationsExtensions extension

Gets the full month name for a given month index (1-12).
getTimePartAbbreviation(TimePart part) String

Available on ShadcnLocalizations, provided by the ShadcnLocalizationsExtensions extension

Gets the abbreviation for a TimePart.