@webx-ui/core 0.23.0 → 0.26.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/components/Button/Button.d.ts +1 -0
- package/dist/components/Button/types.d.ts +3 -0
- package/dist/components/DatePicker/DatePicker.d.ts +1 -0
- package/dist/components/DatePicker/types.d.ts +8 -0
- package/dist/components/DateRangePicker/DateRangePicker.d.ts +1 -0
- package/dist/components/DateRangePicker/types.d.ts +8 -0
- package/dist/components/DateTimePicker/DateTimePicker.d.ts +1 -0
- package/dist/components/EntityCard/EntityCard.d.ts +1 -0
- package/dist/components/EntityCard/types.d.ts +8 -0
- package/dist/components/FormItem/FormItem.d.ts +1 -1
- package/dist/components/Icon/icons.d.ts +2 -0
- package/dist/components/RichText/RichText.d.ts +6 -4
- package/dist/components/RichText/tools.d.ts +7 -35
- package/dist/components/RichText/types.d.ts +40 -6
- package/dist/components/Table/Table.d.ts +34 -0
- package/dist/components/Table/types.d.ts +19 -0
- package/dist/components/TimePicker/TimePicker.d.ts +1 -0
- package/dist/composables/useDateLocale.d.ts +23 -0
- package/dist/index.d.ts +2 -0
- package/dist/index.js +5765 -5506
- package/dist/index.js.map +1 -1
- package/dist/internal/dateLocale.d.ts +19 -0
- package/dist/style.css +1 -1
- package/package.json +1 -1
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { RootProps } from '@vuepic/vue-datepicker';
|
|
2
|
+
/** What `@vuepic/vue-datepicker` wants for its language: a date-fns locale object. */
|
|
3
|
+
export type DateFnsLocale = NonNullable<RootProps['locale']>;
|
|
4
|
+
/**
|
|
5
|
+
* Builds a date-fns locale out of `Intl`.
|
|
6
|
+
*
|
|
7
|
+
* The picker bundles exactly one language — `en-US` — and takes any other as a date-fns
|
|
8
|
+
* locale object, so a panel in Russian gets an English calendar unless one is handed in.
|
|
9
|
+
* Reaching for `date-fns/locale` would mean a runtime dependency on date-fns and a chunk
|
|
10
|
+
* per language; the browser already carries every one of them, so the names come from
|
|
11
|
+
* `Intl.DateTimeFormat` and are shaped here into what date-fns reads.
|
|
12
|
+
*
|
|
13
|
+
* Only what the picker asks for is filled in honestly: month, weekday and day-period
|
|
14
|
+
* names, the era, and enough of `match` to parse a typed-in date back. Quarter names and
|
|
15
|
+
* ordinal suffixes have no `Intl` source and fall back to digits — the picker reaches for
|
|
16
|
+
* them only in a quarter picker and in a day cell's `aria-label`, where a bare number
|
|
17
|
+
* reads correctly in most languages anyway.
|
|
18
|
+
*/
|
|
19
|
+
export declare function dateFnsLocale(tag: string): DateFnsLocale;
|