@expcat/tigercat-core 1.3.3 → 1.4.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/icons/registry.cjs +1 -3
- package/dist/icons/registry.js +1 -3
- package/dist/index.cjs +562 -197
- package/dist/index.d.cts +370 -268
- package/dist/index.d.ts +370 -268
- package/dist/index.js +543 -196
- package/dist/locale-9tTj1QdZ.d.ts +300 -0
- package/dist/locale-DxwhmqfF.d.cts +300 -0
- package/dist/locales/ar-SA.cjs +67 -4
- package/dist/locales/ar-SA.d.cts +1 -1
- package/dist/locales/ar-SA.d.ts +1 -1
- package/dist/locales/ar-SA.js +67 -4
- package/dist/locales/de-DE.cjs +67 -4
- package/dist/locales/de-DE.d.cts +1 -1
- package/dist/locales/de-DE.d.ts +1 -1
- package/dist/locales/de-DE.js +67 -4
- package/dist/locales/en-US.cjs +64 -2
- package/dist/locales/en-US.d.cts +1 -1
- package/dist/locales/en-US.d.ts +1 -1
- package/dist/locales/en-US.js +62 -2
- package/dist/locales/es-ES.cjs +67 -4
- package/dist/locales/es-ES.d.cts +1 -1
- package/dist/locales/es-ES.d.ts +1 -1
- package/dist/locales/es-ES.js +67 -4
- package/dist/locales/fr-FR.cjs +67 -4
- package/dist/locales/fr-FR.d.cts +1 -1
- package/dist/locales/fr-FR.d.ts +1 -1
- package/dist/locales/fr-FR.js +67 -4
- package/dist/locales/id-ID.cjs +5 -2
- package/dist/locales/id-ID.d.cts +1 -1
- package/dist/locales/id-ID.d.ts +1 -1
- package/dist/locales/id-ID.js +5 -2
- package/dist/locales/ja-JP.cjs +5 -2
- package/dist/locales/ja-JP.d.cts +1 -1
- package/dist/locales/ja-JP.d.ts +1 -1
- package/dist/locales/ja-JP.js +5 -2
- package/dist/locales/ko-KR.cjs +5 -2
- package/dist/locales/ko-KR.d.cts +1 -1
- package/dist/locales/ko-KR.d.ts +1 -1
- package/dist/locales/ko-KR.js +5 -2
- package/dist/locales/pt-BR.cjs +67 -4
- package/dist/locales/pt-BR.d.cts +1 -1
- package/dist/locales/pt-BR.d.ts +1 -1
- package/dist/locales/pt-BR.js +67 -4
- package/dist/locales/th-TH.cjs +5 -2
- package/dist/locales/th-TH.d.cts +1 -1
- package/dist/locales/th-TH.d.ts +1 -1
- package/dist/locales/th-TH.js +5 -2
- package/dist/locales/vi-VN.cjs +5 -2
- package/dist/locales/vi-VN.d.cts +1 -1
- package/dist/locales/vi-VN.d.ts +1 -1
- package/dist/locales/vi-VN.js +5 -2
- package/dist/locales/zh-CN.cjs +64 -2
- package/dist/locales/zh-CN.d.cts +1 -1
- package/dist/locales/zh-CN.d.ts +1 -1
- package/dist/locales/zh-CN.js +62 -2
- package/dist/locales/zh-TW.cjs +5 -2
- package/dist/locales/zh-TW.d.cts +1 -1
- package/dist/locales/zh-TW.d.ts +1 -1
- package/dist/locales/zh-TW.js +5 -2
- package/dist/{table-export-CwJR6vfP.d.cts → table-export-BMBH75rj.d.cts} +2 -2
- package/dist/{table-export-B4VAha5n.d.ts → table-export-GRimhvlM.d.ts} +2 -2
- package/dist/tailwind/modern.cjs +1 -1
- package/dist/tailwind/modern.js +1 -1
- package/dist/utils/table-export.cjs +7 -0
- package/dist/utils/table-export.d.cts +2 -2
- package/dist/utils/table-export.d.ts +2 -2
- package/dist/utils/table-export.js +7 -0
- package/package.json +2 -10
- package/tokens/tailwind-tokens.js +3 -6
- package/tokens/tokens.css +15 -30
- package/dist/locale-BRmojkDM.d.cts +0 -131
- package/dist/locale-BxSSFEo2.d.ts +0 -131
package/dist/index.cjs
CHANGED
|
@@ -43,12 +43,15 @@ __export(src_exports, {
|
|
|
43
43
|
ClockIconPath: () => ClockIconPath,
|
|
44
44
|
CloseIconPath: () => CloseIconPath,
|
|
45
45
|
DEFAULT_CHART_COLORS: () => DEFAULT_CHART_COLORS,
|
|
46
|
+
DEFAULT_FORM_VALIDATION_LABELS: () => DEFAULT_FORM_VALIDATION_LABELS,
|
|
46
47
|
DEFAULT_FORM_WIZARD_LABELS: () => DEFAULT_FORM_WIZARD_LABELS,
|
|
47
48
|
DEFAULT_HEATMAP_CANVAS_THRESHOLD: () => DEFAULT_HEATMAP_CANVAS_THRESHOLD,
|
|
48
49
|
DEFAULT_PAGINATION_LABELS: () => DEFAULT_PAGINATION_LABELS,
|
|
49
50
|
DEFAULT_TABLE_LABELS: () => DEFAULT_TABLE_LABELS,
|
|
50
51
|
DEFAULT_TASK_BOARD_LABELS: () => DEFAULT_TASK_BOARD_LABELS,
|
|
52
|
+
DEFAULT_TIME_PICKER_LABELS: () => DEFAULT_TIME_PICKER_LABELS,
|
|
51
53
|
DEFAULT_UPLOAD_CHUNK_SIZE: () => DEFAULT_UPLOAD_CHUNK_SIZE,
|
|
54
|
+
DEFAULT_UPLOAD_LABELS: () => DEFAULT_UPLOAD_LABELS,
|
|
52
55
|
DONUT_BASE_SHADOW: () => DONUT_BASE_SHADOW,
|
|
53
56
|
DONUT_EMPHASIS_SHADOW: () => DONUT_EMPHASIS_SHADOW,
|
|
54
57
|
DROPDOWN_CHEVRON_PATH: () => DROPDOWN_CHEVRON_PATH,
|
|
@@ -106,10 +109,13 @@ __export(src_exports, {
|
|
|
106
109
|
VIEW_TRANSITION_CSS: () => VIEW_TRANSITION_CSS,
|
|
107
110
|
WEEKDAYS: () => WEEKDAYS,
|
|
108
111
|
ZH_CN_DATEPICKER_LOCALE: () => ZH_CN_DATEPICKER_LOCALE,
|
|
112
|
+
ZH_CN_FORM_VALIDATION_LABELS: () => ZH_CN_FORM_VALIDATION_LABELS,
|
|
109
113
|
ZH_CN_FORM_WIZARD_LABELS: () => ZH_CN_FORM_WIZARD_LABELS,
|
|
110
114
|
ZH_CN_PAGINATION_LABELS: () => ZH_CN_PAGINATION_LABELS,
|
|
111
115
|
ZH_CN_TABLE_LABELS: () => ZH_CN_TABLE_LABELS,
|
|
112
116
|
ZH_CN_TASK_BOARD_LABELS: () => ZH_CN_TASK_BOARD_LABELS,
|
|
117
|
+
ZH_CN_TIME_PICKER_LABELS: () => ZH_CN_TIME_PICKER_LABELS,
|
|
118
|
+
ZH_CN_UPLOAD_LABELS: () => ZH_CN_UPLOAD_LABELS,
|
|
113
119
|
activeOpacityClasses: () => activeOpacityClasses,
|
|
114
120
|
activePressClasses: () => activePressClasses,
|
|
115
121
|
activityItemActionsClasses: () => activityItemActionsClasses,
|
|
@@ -119,6 +125,9 @@ __export(src_exports, {
|
|
|
119
125
|
activityItemHeaderClasses: () => activityItemHeaderClasses,
|
|
120
126
|
activityItemLayoutClasses: () => activityItemLayoutClasses,
|
|
121
127
|
activityItemTitleGroupClasses: () => activityItemTitleGroupClasses,
|
|
128
|
+
addDays: () => addDays,
|
|
129
|
+
addMonths: () => addMonths,
|
|
130
|
+
addYears: () => addYears,
|
|
122
131
|
affixWrapperClasses: () => affixWrapperClasses,
|
|
123
132
|
alertBannerClasses: () => alertBannerClasses,
|
|
124
133
|
alertBaseClasses: () => alertBaseClasses,
|
|
@@ -398,6 +407,7 @@ __export(src_exports, {
|
|
|
398
407
|
createImageAnnotationBox: () => createImageAnnotationBox,
|
|
399
408
|
createImageAnnotationPath: () => createImageAnnotationPath,
|
|
400
409
|
createInfiniteScrollObserver: () => createInfiniteScrollObserver,
|
|
410
|
+
createInstanceCounter: () => createInstanceCounter,
|
|
401
411
|
createLinePath: () => createLinePath,
|
|
402
412
|
createLinearScale: () => createLinearScale,
|
|
403
413
|
createLongPressController: () => createLongPressController,
|
|
@@ -593,6 +603,7 @@ __export(src_exports, {
|
|
|
593
603
|
focusMenuEdge: () => focusMenuEdge,
|
|
594
604
|
focusRingClasses: () => focusRingClasses,
|
|
595
605
|
focusRingInsetClasses: () => focusRingInsetClasses,
|
|
606
|
+
focusTimePickerOption: () => focusTimePickerOption,
|
|
596
607
|
formatActivityTime: () => formatActivityTime,
|
|
597
608
|
formatBadgeContent: () => formatBadgeContent,
|
|
598
609
|
formatChatTime: () => formatChatTime,
|
|
@@ -604,6 +615,7 @@ __export(src_exports, {
|
|
|
604
615
|
formatFileSize: () => formatFileSize,
|
|
605
616
|
formatFileSizeLabel: () => formatFileSizeLabel,
|
|
606
617
|
formatGanttDate: () => formatGanttDate,
|
|
618
|
+
formatInputNumberDisplay: () => formatInputNumberDisplay,
|
|
607
619
|
formatIntlNumber: () => formatIntlNumber,
|
|
608
620
|
formatMonthYear: () => formatMonthYear,
|
|
609
621
|
formatPageAriaLabel: () => formatPageAriaLabel,
|
|
@@ -739,6 +751,7 @@ __export(src_exports, {
|
|
|
739
751
|
getCropperResult: () => getCropperResult,
|
|
740
752
|
getCurrentActiveTourStep: () => getCurrentActiveTourStep,
|
|
741
753
|
getCurrentTime: () => getCurrentTime,
|
|
754
|
+
getCyclicIndex: () => getCyclicIndex,
|
|
742
755
|
getDatePickerDayCellClasses: () => getDatePickerDayCellClasses,
|
|
743
756
|
getDatePickerIconButtonClasses: () => getDatePickerIconButtonClasses,
|
|
744
757
|
getDatePickerInputClasses: () => getDatePickerInputClasses,
|
|
@@ -790,6 +803,7 @@ __export(src_exports, {
|
|
|
790
803
|
getFileListItemClasses: () => getFileListItemClasses,
|
|
791
804
|
getFileManagerContainerClasses: () => getFileManagerContainerClasses,
|
|
792
805
|
getFirstDayOfMonth: () => getFirstDayOfMonth,
|
|
806
|
+
getFirstVisibleChildKey: () => getFirstVisibleChildKey,
|
|
793
807
|
getFixedColumnOffsets: () => getFixedColumnOffsets,
|
|
794
808
|
getFixedColumnPosition: () => getFixedColumnPosition,
|
|
795
809
|
getFixedColumnStyle: () => getFixedColumnStyle,
|
|
@@ -805,6 +819,7 @@ __export(src_exports, {
|
|
|
805
819
|
getFormItemErrorClasses: () => getFormItemErrorClasses,
|
|
806
820
|
getFormItemFieldClasses: () => getFormItemFieldClasses,
|
|
807
821
|
getFormItemLabelClasses: () => getFormItemLabelClasses,
|
|
822
|
+
getFormValidationLabels: () => getFormValidationLabels,
|
|
808
823
|
getFormWizardLabels: () => getFormWizardLabels,
|
|
809
824
|
getFunnelGradientPrefix: () => getFunnelGradientPrefix,
|
|
810
825
|
getGanttDependencyPath: () => getGanttDependencyPath,
|
|
@@ -884,6 +899,7 @@ __export(src_exports, {
|
|
|
884
899
|
getMenuItemClasses: () => getMenuItemClasses,
|
|
885
900
|
getMenuItemIndent: () => getMenuItemIndent,
|
|
886
901
|
getMenuItems: () => getMenuItems,
|
|
902
|
+
getMenuNavigationKeys: () => getMenuNavigationKeys,
|
|
887
903
|
getMessageIconPath: () => getMessageIconPath,
|
|
888
904
|
getMessageTypeClasses: () => getMessageTypeClasses,
|
|
889
905
|
getModalContainerClasses: () => getModalContainerClasses,
|
|
@@ -1106,6 +1122,7 @@ __export(src_exports, {
|
|
|
1106
1122
|
getTransferItemClasses: () => getTransferItemClasses,
|
|
1107
1123
|
getTransformOrigin: () => getTransformOrigin,
|
|
1108
1124
|
getTransitionClasses: () => getTransitionClasses,
|
|
1125
|
+
getTreeKeyboardAction: () => getTreeKeyboardAction,
|
|
1109
1126
|
getTreeMapGradientPrefix: () => getTreeMapGradientPrefix,
|
|
1110
1127
|
getTreeNodeClasses: () => getTreeNodeClasses,
|
|
1111
1128
|
getTreeNodeExpandIconClasses: () => getTreeNodeExpandIconClasses,
|
|
@@ -1280,7 +1297,6 @@ __export(src_exports, {
|
|
|
1280
1297
|
isValidHex: () => isValidHex,
|
|
1281
1298
|
isValidUrl: () => isValidUrl,
|
|
1282
1299
|
isWipExceeded: () => isWipExceeded,
|
|
1283
|
-
kanbanAddCardClasses: () => kanbanAddCardClasses,
|
|
1284
1300
|
kanbanAddColumnClasses: () => kanbanAddColumnClasses,
|
|
1285
1301
|
kanbanCardCountClasses: () => kanbanCardCountClasses,
|
|
1286
1302
|
kanbanFilterHighlightClasses: () => kanbanFilterHighlightClasses,
|
|
@@ -1437,6 +1453,7 @@ __export(src_exports, {
|
|
|
1437
1453
|
numberKeyboardGridClasses: () => numberKeyboardGridClasses,
|
|
1438
1454
|
numberKeyboardKeyClasses: () => numberKeyboardKeyClasses,
|
|
1439
1455
|
numberKeyboardRootClasses: () => numberKeyboardRootClasses,
|
|
1456
|
+
orderTableFixedColumns: () => orderTableFixedColumns,
|
|
1440
1457
|
orgChartLinkClasses: () => orgChartLinkClasses,
|
|
1441
1458
|
orgChartNodeClasses: () => orgChartNodeClasses,
|
|
1442
1459
|
orgChartNodeLabelClasses: () => orgChartNodeLabelClasses,
|
|
@@ -1452,6 +1469,7 @@ __export(src_exports, {
|
|
|
1452
1469
|
parseDragData: () => parseDragData,
|
|
1453
1470
|
parseHeight: () => parseHeight,
|
|
1454
1471
|
parseHotkey: () => parseHotkey,
|
|
1472
|
+
parseInputNumberValue: () => parseInputNumberValue,
|
|
1455
1473
|
parseInputValue: () => parseInputValue,
|
|
1456
1474
|
parseMarkdownHeight: () => parseHeight,
|
|
1457
1475
|
parsePaneSize: () => parsePaneSize,
|
|
@@ -2491,6 +2509,10 @@ function normalizeStringOption(options, key) {
|
|
|
2491
2509
|
}
|
|
2492
2510
|
return options;
|
|
2493
2511
|
}
|
|
2512
|
+
function createInstanceCounter() {
|
|
2513
|
+
let counter = 0;
|
|
2514
|
+
return () => ++counter;
|
|
2515
|
+
}
|
|
2494
2516
|
|
|
2495
2517
|
// src/utils/icons/common.ts
|
|
2496
2518
|
var closeIconViewBox = "0 0 24 24";
|
|
@@ -2565,9 +2587,7 @@ var iconRegistry = {
|
|
|
2565
2587
|
"arrow-right": stroke24("M13.5 4.5 21 12m0 0-7.5 7.5M21 12H3"),
|
|
2566
2588
|
"arrow-up": stroke24("M4.5 10.5 12 3m0 0 7.5 7.5M12 3v18"),
|
|
2567
2589
|
"arrow-down": stroke24("M19.5 13.5 12 21m0 0-7.5-7.5M12 21V3"),
|
|
2568
|
-
search: stroke24(
|
|
2569
|
-
"m21 21-5.197-5.197m0 0A7.5 7.5 0 1 0 5.196 5.196a7.5 7.5 0 0 0 10.607 10.607Z"
|
|
2570
|
-
),
|
|
2590
|
+
search: stroke24("m21 21-5.197-5.197m0 0A7.5 7.5 0 1 0 5.196 5.196a7.5 7.5 0 0 0 10.607 10.607Z"),
|
|
2571
2591
|
plus: stroke24("M12 4.5v15m7.5-7.5h-15"),
|
|
2572
2592
|
minus: stroke24("M5 12h14"),
|
|
2573
2593
|
edit: stroke24(
|
|
@@ -2744,6 +2764,14 @@ function getFocusableElements(container) {
|
|
|
2744
2764
|
);
|
|
2745
2765
|
}
|
|
2746
2766
|
function createFocusTrap(container, options = {}) {
|
|
2767
|
+
if (!isBrowser()) {
|
|
2768
|
+
return {
|
|
2769
|
+
activate() {
|
|
2770
|
+
},
|
|
2771
|
+
deactivate() {
|
|
2772
|
+
}
|
|
2773
|
+
};
|
|
2774
|
+
}
|
|
2747
2775
|
const {
|
|
2748
2776
|
initialFocus = null,
|
|
2749
2777
|
returnFocusOnDeactivate = true,
|
|
@@ -2826,6 +2854,7 @@ function getOrCreateLiveRegion(level) {
|
|
|
2826
2854
|
return el;
|
|
2827
2855
|
}
|
|
2828
2856
|
function announceToScreenReader(message, level = "polite") {
|
|
2857
|
+
if (!isBrowser()) return;
|
|
2829
2858
|
const region = getOrCreateLiveRegion(level);
|
|
2830
2859
|
region.textContent = "";
|
|
2831
2860
|
requestAnimationFrame(() => {
|
|
@@ -2833,6 +2862,16 @@ function announceToScreenReader(message, level = "polite") {
|
|
|
2833
2862
|
});
|
|
2834
2863
|
}
|
|
2835
2864
|
function manageLiveRegion(level = "polite") {
|
|
2865
|
+
if (!isBrowser()) {
|
|
2866
|
+
return {
|
|
2867
|
+
announce() {
|
|
2868
|
+
},
|
|
2869
|
+
clear() {
|
|
2870
|
+
},
|
|
2871
|
+
destroy() {
|
|
2872
|
+
}
|
|
2873
|
+
};
|
|
2874
|
+
}
|
|
2836
2875
|
const region = getOrCreateLiveRegion(level);
|
|
2837
2876
|
return {
|
|
2838
2877
|
announce(message) {
|
|
@@ -2859,8 +2898,8 @@ function getActiveElement(doc) {
|
|
|
2859
2898
|
const active = doc?.activeElement;
|
|
2860
2899
|
return isHTMLElement(active) ? active : null;
|
|
2861
2900
|
}
|
|
2862
|
-
function captureActiveElement(doc
|
|
2863
|
-
return getActiveElement(doc);
|
|
2901
|
+
function captureActiveElement(doc) {
|
|
2902
|
+
return getActiveElement(doc ?? (isBrowser() ? document : void 0));
|
|
2864
2903
|
}
|
|
2865
2904
|
function focusElement(element, options) {
|
|
2866
2905
|
if (!element) return false;
|
|
@@ -2891,7 +2930,8 @@ function getMenuItems(container) {
|
|
|
2891
2930
|
function handleMenuNavigation(container, event) {
|
|
2892
2931
|
const items = getMenuItems(container);
|
|
2893
2932
|
if (items.length === 0) return false;
|
|
2894
|
-
const
|
|
2933
|
+
const activeElement = container.ownerDocument?.activeElement ?? (isBrowser() ? document.activeElement : null);
|
|
2934
|
+
const currentIndex = items.indexOf(activeElement);
|
|
2895
2935
|
let nextIndex = -1;
|
|
2896
2936
|
switch (event.key) {
|
|
2897
2937
|
case "ArrowDown":
|
|
@@ -3041,8 +3081,10 @@ var TIGER_LOCALE_KEYS = [
|
|
|
3041
3081
|
"pagination",
|
|
3042
3082
|
"table",
|
|
3043
3083
|
"datePicker",
|
|
3084
|
+
"timePicker",
|
|
3044
3085
|
"formWizard",
|
|
3045
|
-
"taskBoard"
|
|
3086
|
+
"taskBoard",
|
|
3087
|
+
"formValidation"
|
|
3046
3088
|
];
|
|
3047
3089
|
function isRecord3(value) {
|
|
3048
3090
|
return typeof value === "object" && value !== null && !Array.isArray(value);
|
|
@@ -3088,8 +3130,10 @@ function mergeTigerLocale(base, override) {
|
|
|
3088
3130
|
pagination: { ...base?.pagination, ...override?.pagination },
|
|
3089
3131
|
table: { ...base?.table, ...override?.table },
|
|
3090
3132
|
datePicker: { ...base?.datePicker, ...override?.datePicker },
|
|
3133
|
+
timePicker: { ...base?.timePicker, ...override?.timePicker },
|
|
3091
3134
|
formWizard: { ...base?.formWizard, ...override?.formWizard },
|
|
3092
|
-
taskBoard: { ...base?.taskBoard, ...override?.taskBoard }
|
|
3135
|
+
taskBoard: { ...base?.taskBoard, ...override?.taskBoard },
|
|
3136
|
+
formValidation: { ...base?.formValidation, ...override?.formValidation }
|
|
3093
3137
|
};
|
|
3094
3138
|
}
|
|
3095
3139
|
var RTL_LANGUAGE_CODES = /* @__PURE__ */ new Set(["ar", "fa", "he", "iw", "ps", "ur"]);
|
|
@@ -3198,7 +3242,9 @@ var DEFAULT_TABLE_LABELS = {
|
|
|
3198
3242
|
selectedText: "Selected",
|
|
3199
3243
|
selectedItemsText: "items",
|
|
3200
3244
|
columnSettingsText: "Column settings",
|
|
3201
|
-
columnSettingsAriaLabel: "Column settings"
|
|
3245
|
+
columnSettingsAriaLabel: "Column settings",
|
|
3246
|
+
lockColumnAriaLabel: "Lock column {column}",
|
|
3247
|
+
unlockColumnAriaLabel: "Unlock column {column}"
|
|
3202
3248
|
};
|
|
3203
3249
|
var ZH_CN_TABLE_LABELS = {
|
|
3204
3250
|
emptyText: "\u6682\u65E0\u6570\u636E",
|
|
@@ -3215,7 +3261,9 @@ var ZH_CN_TABLE_LABELS = {
|
|
|
3215
3261
|
selectedText: "\u5DF2\u9009\u62E9",
|
|
3216
3262
|
selectedItemsText: "\u9879",
|
|
3217
3263
|
columnSettingsText: "\u5217\u8BBE\u7F6E",
|
|
3218
|
-
columnSettingsAriaLabel: "\u5217\u8BBE\u7F6E"
|
|
3264
|
+
columnSettingsAriaLabel: "\u5217\u8BBE\u7F6E",
|
|
3265
|
+
lockColumnAriaLabel: "\u9501\u5B9A{column}\u5217",
|
|
3266
|
+
unlockColumnAriaLabel: "\u53D6\u6D88\u9501\u5B9A{column}\u5217"
|
|
3219
3267
|
};
|
|
3220
3268
|
function getTableLabels(locale, overrides) {
|
|
3221
3269
|
const isZh = !!locale?.locale?.startsWith("zh") || locale?.common?.emptyText === "\u6682\u65E0\u6570\u636E" || locale?.table?.searchButtonText === "\u641C\u7D22";
|
|
@@ -3235,7 +3283,9 @@ function getTableLabels(locale, overrides) {
|
|
|
3235
3283
|
selectedText: overrides?.selectedText ?? locale?.table?.selectedText ?? defaultLabels.selectedText,
|
|
3236
3284
|
selectedItemsText: overrides?.selectedItemsText ?? locale?.table?.selectedItemsText ?? defaultLabels.selectedItemsText,
|
|
3237
3285
|
columnSettingsText: overrides?.columnSettingsText ?? locale?.table?.columnSettingsText ?? defaultLabels.columnSettingsText,
|
|
3238
|
-
columnSettingsAriaLabel: overrides?.columnSettingsAriaLabel ?? locale?.table?.columnSettingsAriaLabel ?? defaultLabels.columnSettingsAriaLabel
|
|
3286
|
+
columnSettingsAriaLabel: overrides?.columnSettingsAriaLabel ?? locale?.table?.columnSettingsAriaLabel ?? defaultLabels.columnSettingsAriaLabel,
|
|
3287
|
+
lockColumnAriaLabel: overrides?.lockColumnAriaLabel ?? locale?.table?.lockColumnAriaLabel ?? defaultLabels.lockColumnAriaLabel,
|
|
3288
|
+
unlockColumnAriaLabel: overrides?.unlockColumnAriaLabel ?? locale?.table?.unlockColumnAriaLabel ?? defaultLabels.unlockColumnAriaLabel
|
|
3239
3289
|
};
|
|
3240
3290
|
}
|
|
3241
3291
|
function formatTableSelectRowAriaLabel(template, row, locale) {
|
|
@@ -3269,6 +3319,118 @@ function getTaskBoardLabels(locale, overrides) {
|
|
|
3269
3319
|
boardAriaLabel: overrides?.boardAriaLabel ?? locale?.taskBoard?.boardAriaLabel ?? defaultLabels.boardAriaLabel
|
|
3270
3320
|
};
|
|
3271
3321
|
}
|
|
3322
|
+
var DEFAULT_FORM_VALIDATION_LABELS = {
|
|
3323
|
+
required: "This field is required",
|
|
3324
|
+
typeString: "Value must be a string",
|
|
3325
|
+
typeNumber: "Value must be a number",
|
|
3326
|
+
typeBoolean: "Value must be a boolean",
|
|
3327
|
+
typeArray: "Value must be an array",
|
|
3328
|
+
typeObject: "Value must be an object",
|
|
3329
|
+
email: "Please enter a valid email address",
|
|
3330
|
+
phone: "Please enter a valid phone number",
|
|
3331
|
+
url: "Please enter a valid URL",
|
|
3332
|
+
date: "Please enter a valid date",
|
|
3333
|
+
idCard: "Please enter a valid ID card number",
|
|
3334
|
+
minLength: "Minimum length is {min} characters",
|
|
3335
|
+
maxLength: "Maximum length is {max} characters",
|
|
3336
|
+
minValue: "Minimum value is {min}",
|
|
3337
|
+
maxValue: "Maximum value is {max}",
|
|
3338
|
+
minItems: "Minimum {min} items required",
|
|
3339
|
+
maxItems: "Maximum {max} items allowed",
|
|
3340
|
+
patternMismatch: "Value does not match the required pattern",
|
|
3341
|
+
validatorFailed: "Validation failed",
|
|
3342
|
+
validatorError: "Validation error occurred"
|
|
3343
|
+
};
|
|
3344
|
+
var ZH_CN_FORM_VALIDATION_LABELS = {
|
|
3345
|
+
required: "\u6B64\u5B57\u6BB5\u4E3A\u5FC5\u586B\u9879",
|
|
3346
|
+
typeString: "\u503C\u5FC5\u987B\u662F\u5B57\u7B26\u4E32",
|
|
3347
|
+
typeNumber: "\u503C\u5FC5\u987B\u662F\u6570\u5B57",
|
|
3348
|
+
typeBoolean: "\u503C\u5FC5\u987B\u662F\u5E03\u5C14\u503C",
|
|
3349
|
+
typeArray: "\u503C\u5FC5\u987B\u662F\u6570\u7EC4",
|
|
3350
|
+
typeObject: "\u503C\u5FC5\u987B\u662F\u5BF9\u8C61",
|
|
3351
|
+
email: "\u8BF7\u8F93\u5165\u6709\u6548\u7684\u90AE\u7BB1\u5730\u5740",
|
|
3352
|
+
phone: "\u8BF7\u8F93\u5165\u6709\u6548\u7684\u7535\u8BDD\u53F7\u7801",
|
|
3353
|
+
url: "\u8BF7\u8F93\u5165\u6709\u6548\u7684\u7F51\u5740",
|
|
3354
|
+
date: "\u8BF7\u8F93\u5165\u6709\u6548\u7684\u65E5\u671F",
|
|
3355
|
+
idCard: "\u8BF7\u8F93\u5165\u6709\u6548\u7684\u8EAB\u4EFD\u8BC1\u53F7\u7801",
|
|
3356
|
+
minLength: "\u957F\u5EA6\u4E0D\u80FD\u5C11\u4E8E {min} \u4E2A\u5B57\u7B26",
|
|
3357
|
+
maxLength: "\u957F\u5EA6\u4E0D\u80FD\u8D85\u8FC7 {max} \u4E2A\u5B57\u7B26",
|
|
3358
|
+
minValue: "\u6570\u503C\u4E0D\u80FD\u5C0F\u4E8E {min}",
|
|
3359
|
+
maxValue: "\u6570\u503C\u4E0D\u80FD\u5927\u4E8E {max}",
|
|
3360
|
+
minItems: "\u81F3\u5C11\u9700\u8981 {min} \u9879",
|
|
3361
|
+
maxItems: "\u6700\u591A\u5141\u8BB8 {max} \u9879",
|
|
3362
|
+
patternMismatch: "\u683C\u5F0F\u4E0D\u6B63\u786E",
|
|
3363
|
+
validatorFailed: "\u6821\u9A8C\u672A\u901A\u8FC7",
|
|
3364
|
+
validatorError: "\u6821\u9A8C\u65F6\u53D1\u751F\u9519\u8BEF"
|
|
3365
|
+
};
|
|
3366
|
+
function getFormValidationLabels(locale, overrides) {
|
|
3367
|
+
const isZh = !!locale?.locale?.startsWith("zh");
|
|
3368
|
+
const defaultLabels = isZh ? ZH_CN_FORM_VALIDATION_LABELS : DEFAULT_FORM_VALIDATION_LABELS;
|
|
3369
|
+
const fv = locale?.formValidation;
|
|
3370
|
+
const resolved = {};
|
|
3371
|
+
for (const key of Object.keys(defaultLabels)) {
|
|
3372
|
+
resolved[key] = overrides?.[key] ?? fv?.[key] ?? defaultLabels[key];
|
|
3373
|
+
}
|
|
3374
|
+
return resolved;
|
|
3375
|
+
}
|
|
3376
|
+
var DEFAULT_TIME_PICKER_LABELS = {
|
|
3377
|
+
hour: "Hour",
|
|
3378
|
+
minute: "Min",
|
|
3379
|
+
second: "Sec",
|
|
3380
|
+
now: "Now",
|
|
3381
|
+
ok: "OK",
|
|
3382
|
+
start: "Start",
|
|
3383
|
+
end: "End",
|
|
3384
|
+
clear: "Clear time",
|
|
3385
|
+
toggle: "Toggle time picker",
|
|
3386
|
+
dialog: "Time picker",
|
|
3387
|
+
selectTime: "Select time",
|
|
3388
|
+
selectTimeRange: "Select time range"
|
|
3389
|
+
};
|
|
3390
|
+
var ZH_CN_TIME_PICKER_LABELS = {
|
|
3391
|
+
hour: "\u65F6",
|
|
3392
|
+
minute: "\u5206",
|
|
3393
|
+
second: "\u79D2",
|
|
3394
|
+
now: "\u73B0\u5728",
|
|
3395
|
+
ok: "\u786E\u5B9A",
|
|
3396
|
+
start: "\u5F00\u59CB",
|
|
3397
|
+
end: "\u7ED3\u675F",
|
|
3398
|
+
clear: "\u6E05\u9664\u65F6\u95F4",
|
|
3399
|
+
toggle: "\u6253\u5F00\u65F6\u95F4\u9009\u62E9\u5668",
|
|
3400
|
+
dialog: "\u65F6\u95F4\u9009\u62E9\u5668",
|
|
3401
|
+
selectTime: "\u8BF7\u9009\u62E9\u65F6\u95F4",
|
|
3402
|
+
selectTimeRange: "\u8BF7\u9009\u62E9\u65F6\u95F4\u8303\u56F4"
|
|
3403
|
+
};
|
|
3404
|
+
var DEFAULT_UPLOAD_LABELS = {
|
|
3405
|
+
dragAreaAriaLabel: "Upload file by clicking or dragging",
|
|
3406
|
+
buttonAriaLabel: "Upload file",
|
|
3407
|
+
clickToUploadText: "Click to upload",
|
|
3408
|
+
dragAndDropText: "or drag and drop",
|
|
3409
|
+
acceptInfoText: "Accepted: {accept}",
|
|
3410
|
+
maxSizeInfoText: "Max size: {maxSize}",
|
|
3411
|
+
selectFileText: "Select File",
|
|
3412
|
+
uploadedFilesAriaLabel: "Uploaded files",
|
|
3413
|
+
successAriaLabel: "Success",
|
|
3414
|
+
errorAriaLabel: "Error",
|
|
3415
|
+
uploadingAriaLabel: "Uploading",
|
|
3416
|
+
removeFileAriaLabel: "Remove {fileName}",
|
|
3417
|
+
previewFileAriaLabel: "Preview {fileName}"
|
|
3418
|
+
};
|
|
3419
|
+
var ZH_CN_UPLOAD_LABELS = {
|
|
3420
|
+
dragAreaAriaLabel: "\u70B9\u51FB\u6216\u62D6\u62FD\u4E0A\u4F20\u6587\u4EF6",
|
|
3421
|
+
buttonAriaLabel: "\u4E0A\u4F20\u6587\u4EF6",
|
|
3422
|
+
clickToUploadText: "\u70B9\u51FB\u4E0A\u4F20",
|
|
3423
|
+
dragAndDropText: "\u6216\u62D6\u62FD\u5230\u6B64\u5904",
|
|
3424
|
+
acceptInfoText: "\u652F\u6301\uFF1A{accept}",
|
|
3425
|
+
maxSizeInfoText: "\u6700\u5927\u5927\u5C0F\uFF1A{maxSize}",
|
|
3426
|
+
selectFileText: "\u9009\u62E9\u6587\u4EF6",
|
|
3427
|
+
uploadedFilesAriaLabel: "\u5DF2\u4E0A\u4F20\u6587\u4EF6",
|
|
3428
|
+
successAriaLabel: "\u6210\u529F",
|
|
3429
|
+
errorAriaLabel: "\u9519\u8BEF",
|
|
3430
|
+
uploadingAriaLabel: "\u4E0A\u4F20\u4E2D",
|
|
3431
|
+
removeFileAriaLabel: "\u79FB\u9664 {fileName}",
|
|
3432
|
+
previewFileAriaLabel: "\u9884\u89C8 {fileName}"
|
|
3433
|
+
};
|
|
3272
3434
|
|
|
3273
3435
|
// src/utils/datepicker-i18n.ts
|
|
3274
3436
|
var EN_US_DATEPICKER_LOCALE = {
|
|
@@ -3369,35 +3531,104 @@ function getDatePickerLabels(locale, overrides) {
|
|
|
3369
3531
|
};
|
|
3370
3532
|
}
|
|
3371
3533
|
|
|
3534
|
+
// src/utils/picker-utils.ts
|
|
3535
|
+
var defaultIsDisabled = (item) => !!item?.disabled;
|
|
3536
|
+
function findFirstEnabledIndex(items, isDisabled = defaultIsDisabled) {
|
|
3537
|
+
for (let i = 0; i < items.length; i++) {
|
|
3538
|
+
if (!isDisabled(items[i])) return i;
|
|
3539
|
+
}
|
|
3540
|
+
return -1;
|
|
3541
|
+
}
|
|
3542
|
+
function findLastEnabledIndex(items, isDisabled = defaultIsDisabled) {
|
|
3543
|
+
for (let i = items.length - 1; i >= 0; i--) {
|
|
3544
|
+
if (!isDisabled(items[i])) return i;
|
|
3545
|
+
}
|
|
3546
|
+
return -1;
|
|
3547
|
+
}
|
|
3548
|
+
function findNextEnabledIndex(items, current, direction, isDisabled = defaultIsDisabled) {
|
|
3549
|
+
if (items.length === 0) return -1;
|
|
3550
|
+
const start = current < 0 ? direction === 1 ? 0 : items.length - 1 : current + direction;
|
|
3551
|
+
for (let i = start; i >= 0 && i < items.length; i += direction) {
|
|
3552
|
+
if (!isDisabled(items[i])) return i;
|
|
3553
|
+
}
|
|
3554
|
+
return current;
|
|
3555
|
+
}
|
|
3556
|
+
function getCyclicIndex(length, current, direction) {
|
|
3557
|
+
if (length <= 0) return -1;
|
|
3558
|
+
return (current + direction + length) % length;
|
|
3559
|
+
}
|
|
3560
|
+
function getInitialPickerActiveIndex(items, activeFirst, isDisabled = defaultIsDisabled) {
|
|
3561
|
+
return activeFirst ? findFirstEnabledIndex(items, isDisabled) : -1;
|
|
3562
|
+
}
|
|
3563
|
+
function getPickerNavigationIndex(items, current, key, isDisabled = defaultIsDisabled) {
|
|
3564
|
+
switch (key) {
|
|
3565
|
+
case "ArrowDown":
|
|
3566
|
+
return findNextEnabledIndex(items, current, 1, isDisabled);
|
|
3567
|
+
case "ArrowUp":
|
|
3568
|
+
return findNextEnabledIndex(items, current, -1, isDisabled);
|
|
3569
|
+
case "Home":
|
|
3570
|
+
return findFirstEnabledIndex(items, isDisabled);
|
|
3571
|
+
case "End":
|
|
3572
|
+
return findLastEnabledIndex(items, isDisabled);
|
|
3573
|
+
default:
|
|
3574
|
+
return current;
|
|
3575
|
+
}
|
|
3576
|
+
}
|
|
3577
|
+
function getPickerOptionId(listboxId, index) {
|
|
3578
|
+
return `${listboxId}-option-${index}`;
|
|
3579
|
+
}
|
|
3580
|
+
function getDisclosureStateAttr(open) {
|
|
3581
|
+
return { "data-state": open ? "open" : "closed" };
|
|
3582
|
+
}
|
|
3583
|
+
function getPickerComboboxAria({
|
|
3584
|
+
expanded,
|
|
3585
|
+
listboxId,
|
|
3586
|
+
activeIndex = -1,
|
|
3587
|
+
activeOptionId
|
|
3588
|
+
}) {
|
|
3589
|
+
return {
|
|
3590
|
+
role: "combobox",
|
|
3591
|
+
"aria-expanded": expanded,
|
|
3592
|
+
"aria-haspopup": "listbox",
|
|
3593
|
+
"aria-controls": expanded ? listboxId : void 0,
|
|
3594
|
+
"aria-activedescendant": expanded ? activeOptionId ?? (activeIndex >= 0 ? getPickerOptionId(listboxId, activeIndex) : void 0) : void 0,
|
|
3595
|
+
"data-state": expanded ? "open" : "closed"
|
|
3596
|
+
};
|
|
3597
|
+
}
|
|
3598
|
+
function getPickerListboxAria({ id, label } = {}) {
|
|
3599
|
+
return {
|
|
3600
|
+
id,
|
|
3601
|
+
role: "listbox",
|
|
3602
|
+
"aria-label": label
|
|
3603
|
+
};
|
|
3604
|
+
}
|
|
3605
|
+
function getPickerOptionAria({
|
|
3606
|
+
selected = false,
|
|
3607
|
+
disabled = false
|
|
3608
|
+
}) {
|
|
3609
|
+
return {
|
|
3610
|
+
role: "option",
|
|
3611
|
+
"aria-selected": selected,
|
|
3612
|
+
"aria-disabled": disabled || void 0
|
|
3613
|
+
};
|
|
3614
|
+
}
|
|
3615
|
+
function getPickerTriggerKeyAction(key, expanded) {
|
|
3616
|
+
switch (key) {
|
|
3617
|
+
case "Enter":
|
|
3618
|
+
case " ":
|
|
3619
|
+
return "toggle";
|
|
3620
|
+
case "ArrowDown":
|
|
3621
|
+
return expanded ? "none" : "open";
|
|
3622
|
+
case "Escape":
|
|
3623
|
+
return expanded ? "close" : "none";
|
|
3624
|
+
default:
|
|
3625
|
+
return "none";
|
|
3626
|
+
}
|
|
3627
|
+
}
|
|
3628
|
+
|
|
3372
3629
|
// src/utils/timepicker-utils.ts
|
|
3373
|
-
var
|
|
3374
|
-
|
|
3375
|
-
minute: "\u5206",
|
|
3376
|
-
second: "\u79D2",
|
|
3377
|
-
now: "\u73B0\u5728",
|
|
3378
|
-
ok: "\u786E\u5B9A",
|
|
3379
|
-
start: "\u5F00\u59CB",
|
|
3380
|
-
end: "\u7ED3\u675F",
|
|
3381
|
-
clear: "\u6E05\u9664\u65F6\u95F4",
|
|
3382
|
-
toggle: "\u6253\u5F00\u65F6\u95F4\u9009\u62E9\u5668",
|
|
3383
|
-
dialog: "\u65F6\u95F4\u9009\u62E9\u5668",
|
|
3384
|
-
selectTime: "\u8BF7\u9009\u62E9\u65F6\u95F4",
|
|
3385
|
-
selectTimeRange: "\u8BF7\u9009\u62E9\u65F6\u95F4\u8303\u56F4"
|
|
3386
|
-
};
|
|
3387
|
-
var EN_LABELS = {
|
|
3388
|
-
hour: "Hour",
|
|
3389
|
-
minute: "Min",
|
|
3390
|
-
second: "Sec",
|
|
3391
|
-
now: "Now",
|
|
3392
|
-
ok: "OK",
|
|
3393
|
-
start: "Start",
|
|
3394
|
-
end: "End",
|
|
3395
|
-
clear: "Clear time",
|
|
3396
|
-
toggle: "Toggle time picker",
|
|
3397
|
-
dialog: "Time picker",
|
|
3398
|
-
selectTime: "Select time",
|
|
3399
|
-
selectTimeRange: "Select time range"
|
|
3400
|
-
};
|
|
3630
|
+
var EN_LABELS = DEFAULT_TIME_PICKER_LABELS;
|
|
3631
|
+
var ZH_LABELS = ZH_CN_TIME_PICKER_LABELS;
|
|
3401
3632
|
var TIME_PICKER_LABELS_BY_LANGUAGE = {
|
|
3402
3633
|
en: EN_LABELS,
|
|
3403
3634
|
zh: ZH_LABELS,
|
|
@@ -3472,26 +3703,59 @@ var TIME_PICKER_LABELS_BY_LANGUAGE = {
|
|
|
3472
3703
|
selectTimeRange: "\u0627\u062E\u062A\u0631 \u0646\u0637\u0627\u0642 \u0627\u0644\u0648\u0642\u062A"
|
|
3473
3704
|
}
|
|
3474
3705
|
};
|
|
3706
|
+
function getTimePickerLocaleCode(locale) {
|
|
3707
|
+
return typeof locale === "string" ? locale : locale?.locale;
|
|
3708
|
+
}
|
|
3475
3709
|
function isZhLocale(locale) {
|
|
3476
|
-
return (locale ?? "").toLowerCase().startsWith("zh");
|
|
3710
|
+
return (getTimePickerLocaleCode(locale) ?? "").toLowerCase().startsWith("zh");
|
|
3477
3711
|
}
|
|
3478
3712
|
function getTimePickerLabels(locale, overrides) {
|
|
3479
|
-
const
|
|
3713
|
+
const localeCode = getTimePickerLocaleCode(locale);
|
|
3714
|
+
const language = (localeCode ?? "").split("-")[0]?.toLowerCase();
|
|
3480
3715
|
const base = language ? TIME_PICKER_LABELS_BY_LANGUAGE[language] ?? EN_LABELS : EN_LABELS;
|
|
3481
|
-
|
|
3716
|
+
const localeLabels = typeof locale === "string" ? void 0 : locale?.timePicker;
|
|
3717
|
+
return { ...base, ...localeLabels ?? {}, ...overrides ?? {} };
|
|
3482
3718
|
}
|
|
3483
3719
|
function pluralizeEn(value, singular) {
|
|
3484
3720
|
return getIntlPluralCategory(value, "en") === "one" ? singular : `${singular}s`;
|
|
3485
3721
|
}
|
|
3486
3722
|
function getTimePickerOptionAriaLabel(value, unit, locale, labelOverrides) {
|
|
3487
3723
|
const labels = getTimePickerLabels(locale, labelOverrides);
|
|
3724
|
+
const localeCode = getTimePickerLocaleCode(locale);
|
|
3488
3725
|
const unitLabel = unit === "hour" ? labels.hour : unit === "minute" ? labels.minute : labels.second;
|
|
3489
|
-
if (isZhLocale(locale)) return `${formatIntlNumber(value,
|
|
3490
|
-
const lc = (
|
|
3726
|
+
if (isZhLocale(locale)) return `${formatIntlNumber(value, localeCode)}${unitLabel}`;
|
|
3727
|
+
const lc = (localeCode ?? "").toLowerCase();
|
|
3491
3728
|
if (lc.startsWith("en") || !lc && !labelOverrides) {
|
|
3492
|
-
return `${formatIntlNumber(value,
|
|
3729
|
+
return `${formatIntlNumber(value, localeCode)} ${pluralizeEn(value, unit)}`;
|
|
3730
|
+
}
|
|
3731
|
+
return `${formatIntlNumber(value, localeCode)} ${unitLabel}`;
|
|
3732
|
+
}
|
|
3733
|
+
function focusTimePickerOption(panel, unit, action) {
|
|
3734
|
+
if (!panel) return;
|
|
3735
|
+
const nodes = Array.from(
|
|
3736
|
+
panel.querySelectorAll(`button[data-tiger-timepicker-unit="${unit}"]`)
|
|
3737
|
+
).filter((button) => !button.disabled);
|
|
3738
|
+
if (nodes.length === 0) return;
|
|
3739
|
+
const active = panel.ownerDocument.activeElement;
|
|
3740
|
+
const activeIndex = active ? nodes.indexOf(active) : -1;
|
|
3741
|
+
const selectedIndex = nodes.findIndex((button) => button.getAttribute("aria-selected") === "true");
|
|
3742
|
+
const baseIndex = activeIndex >= 0 ? activeIndex : Math.max(0, selectedIndex);
|
|
3743
|
+
let nextIndex = baseIndex;
|
|
3744
|
+
switch (action) {
|
|
3745
|
+
case "prev":
|
|
3746
|
+
nextIndex = findNextEnabledIndex(nodes, baseIndex, -1);
|
|
3747
|
+
break;
|
|
3748
|
+
case "next":
|
|
3749
|
+
nextIndex = findNextEnabledIndex(nodes, baseIndex, 1);
|
|
3750
|
+
break;
|
|
3751
|
+
case "first":
|
|
3752
|
+
nextIndex = findFirstEnabledIndex(nodes);
|
|
3753
|
+
break;
|
|
3754
|
+
case "last":
|
|
3755
|
+
nextIndex = findLastEnabledIndex(nodes);
|
|
3756
|
+
break;
|
|
3493
3757
|
}
|
|
3494
|
-
|
|
3758
|
+
nodes[nextIndex]?.focus();
|
|
3495
3759
|
}
|
|
3496
3760
|
var timePickerBaseClasses = "relative inline-block w-full max-w-xs";
|
|
3497
3761
|
var timePickerInputWrapperClasses = "relative flex items-center";
|
|
@@ -3628,67 +3892,67 @@ function interpolateUploadLabel(template, params) {
|
|
|
3628
3892
|
function getUploadLabels(locale, overrides) {
|
|
3629
3893
|
return {
|
|
3630
3894
|
dragAreaAriaLabel: resolveLocaleText(
|
|
3631
|
-
|
|
3895
|
+
DEFAULT_UPLOAD_LABELS.dragAreaAriaLabel,
|
|
3632
3896
|
overrides?.dragAreaAriaLabel,
|
|
3633
3897
|
locale?.upload?.dragAreaAriaLabel
|
|
3634
3898
|
),
|
|
3635
3899
|
buttonAriaLabel: resolveLocaleText(
|
|
3636
|
-
|
|
3900
|
+
DEFAULT_UPLOAD_LABELS.buttonAriaLabel,
|
|
3637
3901
|
overrides?.buttonAriaLabel,
|
|
3638
3902
|
locale?.upload?.buttonAriaLabel
|
|
3639
3903
|
),
|
|
3640
3904
|
clickToUploadText: resolveLocaleText(
|
|
3641
|
-
|
|
3905
|
+
DEFAULT_UPLOAD_LABELS.clickToUploadText,
|
|
3642
3906
|
overrides?.clickToUploadText,
|
|
3643
3907
|
locale?.upload?.clickToUploadText
|
|
3644
3908
|
),
|
|
3645
3909
|
dragAndDropText: resolveLocaleText(
|
|
3646
|
-
|
|
3910
|
+
DEFAULT_UPLOAD_LABELS.dragAndDropText,
|
|
3647
3911
|
overrides?.dragAndDropText,
|
|
3648
3912
|
locale?.upload?.dragAndDropText
|
|
3649
3913
|
),
|
|
3650
3914
|
acceptInfoText: resolveLocaleText(
|
|
3651
|
-
|
|
3915
|
+
DEFAULT_UPLOAD_LABELS.acceptInfoText,
|
|
3652
3916
|
overrides?.acceptInfoText,
|
|
3653
3917
|
locale?.upload?.acceptInfoText
|
|
3654
3918
|
),
|
|
3655
3919
|
maxSizeInfoText: resolveLocaleText(
|
|
3656
|
-
|
|
3920
|
+
DEFAULT_UPLOAD_LABELS.maxSizeInfoText,
|
|
3657
3921
|
overrides?.maxSizeInfoText,
|
|
3658
3922
|
locale?.upload?.maxSizeInfoText
|
|
3659
3923
|
),
|
|
3660
3924
|
selectFileText: resolveLocaleText(
|
|
3661
|
-
|
|
3925
|
+
DEFAULT_UPLOAD_LABELS.selectFileText,
|
|
3662
3926
|
overrides?.selectFileText,
|
|
3663
3927
|
locale?.upload?.selectFileText
|
|
3664
3928
|
),
|
|
3665
3929
|
uploadedFilesAriaLabel: resolveLocaleText(
|
|
3666
|
-
|
|
3930
|
+
DEFAULT_UPLOAD_LABELS.uploadedFilesAriaLabel,
|
|
3667
3931
|
overrides?.uploadedFilesAriaLabel,
|
|
3668
3932
|
locale?.upload?.uploadedFilesAriaLabel
|
|
3669
3933
|
),
|
|
3670
3934
|
successAriaLabel: resolveLocaleText(
|
|
3671
|
-
|
|
3935
|
+
DEFAULT_UPLOAD_LABELS.successAriaLabel,
|
|
3672
3936
|
overrides?.successAriaLabel,
|
|
3673
3937
|
locale?.upload?.successAriaLabel
|
|
3674
3938
|
),
|
|
3675
3939
|
errorAriaLabel: resolveLocaleText(
|
|
3676
|
-
|
|
3940
|
+
DEFAULT_UPLOAD_LABELS.errorAriaLabel,
|
|
3677
3941
|
overrides?.errorAriaLabel,
|
|
3678
3942
|
locale?.upload?.errorAriaLabel
|
|
3679
3943
|
),
|
|
3680
3944
|
uploadingAriaLabel: resolveLocaleText(
|
|
3681
|
-
|
|
3945
|
+
DEFAULT_UPLOAD_LABELS.uploadingAriaLabel,
|
|
3682
3946
|
overrides?.uploadingAriaLabel,
|
|
3683
3947
|
locale?.upload?.uploadingAriaLabel
|
|
3684
3948
|
),
|
|
3685
3949
|
removeFileAriaLabel: resolveLocaleText(
|
|
3686
|
-
|
|
3950
|
+
DEFAULT_UPLOAD_LABELS.removeFileAriaLabel,
|
|
3687
3951
|
overrides?.removeFileAriaLabel,
|
|
3688
3952
|
locale?.upload?.removeFileAriaLabel
|
|
3689
3953
|
),
|
|
3690
3954
|
previewFileAriaLabel: resolveLocaleText(
|
|
3691
|
-
|
|
3955
|
+
DEFAULT_UPLOAD_LABELS.previewFileAriaLabel,
|
|
3692
3956
|
overrides?.previewFileAriaLabel,
|
|
3693
3957
|
locale?.upload?.previewFileAriaLabel
|
|
3694
3958
|
)
|
|
@@ -3704,7 +3968,10 @@ var enUS = {
|
|
|
3704
3968
|
cancelText: "Cancel",
|
|
3705
3969
|
closeText: "Close",
|
|
3706
3970
|
loadingText: "Loading...",
|
|
3707
|
-
emptyText: "No data"
|
|
3971
|
+
emptyText: "No data",
|
|
3972
|
+
noMoreText: "No more data",
|
|
3973
|
+
searchPlaceholder: "Search",
|
|
3974
|
+
clearText: "Clear"
|
|
3708
3975
|
},
|
|
3709
3976
|
modal: {
|
|
3710
3977
|
closeAriaLabel: "Close",
|
|
@@ -3714,6 +3981,7 @@ var enUS = {
|
|
|
3714
3981
|
drawer: {
|
|
3715
3982
|
closeAriaLabel: "Close"
|
|
3716
3983
|
},
|
|
3984
|
+
upload: DEFAULT_UPLOAD_LABELS,
|
|
3717
3985
|
pagination: {
|
|
3718
3986
|
totalText: "Total {total} items",
|
|
3719
3987
|
itemsPerPageText: "/ page",
|
|
@@ -3739,8 +4007,11 @@ var enUS = {
|
|
|
3739
4007
|
selectedText: "Selected",
|
|
3740
4008
|
selectedItemsText: "items",
|
|
3741
4009
|
columnSettingsText: "Column settings",
|
|
3742
|
-
columnSettingsAriaLabel: "Column settings"
|
|
4010
|
+
columnSettingsAriaLabel: "Column settings",
|
|
4011
|
+
lockColumnAriaLabel: "Lock column {column}",
|
|
4012
|
+
unlockColumnAriaLabel: "Unlock column {column}"
|
|
3743
4013
|
},
|
|
4014
|
+
timePicker: DEFAULT_TIME_PICKER_LABELS,
|
|
3744
4015
|
formWizard: {
|
|
3745
4016
|
prevText: "Previous",
|
|
3746
4017
|
nextText: "Next",
|
|
@@ -3752,6 +4023,28 @@ var enUS = {
|
|
|
3752
4023
|
wipLimitText: "WIP limit: {limit}",
|
|
3753
4024
|
dragHintText: "Drag to move",
|
|
3754
4025
|
boardAriaLabel: "Task Board"
|
|
4026
|
+
},
|
|
4027
|
+
formValidation: {
|
|
4028
|
+
required: "This field is required",
|
|
4029
|
+
typeString: "Value must be a string",
|
|
4030
|
+
typeNumber: "Value must be a number",
|
|
4031
|
+
typeBoolean: "Value must be a boolean",
|
|
4032
|
+
typeArray: "Value must be an array",
|
|
4033
|
+
typeObject: "Value must be an object",
|
|
4034
|
+
email: "Please enter a valid email address",
|
|
4035
|
+
phone: "Please enter a valid phone number",
|
|
4036
|
+
url: "Please enter a valid URL",
|
|
4037
|
+
date: "Please enter a valid date",
|
|
4038
|
+
idCard: "Please enter a valid ID card number",
|
|
4039
|
+
minLength: "Minimum length is {min} characters",
|
|
4040
|
+
maxLength: "Maximum length is {max} characters",
|
|
4041
|
+
minValue: "Minimum value is {min}",
|
|
4042
|
+
maxValue: "Maximum value is {max}",
|
|
4043
|
+
minItems: "Minimum {min} items required",
|
|
4044
|
+
maxItems: "Maximum {max} items allowed",
|
|
4045
|
+
patternMismatch: "Value does not match the required pattern",
|
|
4046
|
+
validatorFailed: "Validation failed",
|
|
4047
|
+
validatorError: "Validation error occurred"
|
|
3755
4048
|
}
|
|
3756
4049
|
};
|
|
3757
4050
|
|
|
@@ -4004,6 +4297,18 @@ function isAtMax(value, max = Infinity) {
|
|
|
4004
4297
|
if (value === null || value === void 0) return false;
|
|
4005
4298
|
return value >= max;
|
|
4006
4299
|
}
|
|
4300
|
+
function formatInputNumberDisplay(value, options = {}) {
|
|
4301
|
+
if (value === null || value === void 0) return "";
|
|
4302
|
+
if (options.formatter) return options.formatter(value);
|
|
4303
|
+
if (options.precision !== void 0) return value.toFixed(options.precision);
|
|
4304
|
+
return String(value);
|
|
4305
|
+
}
|
|
4306
|
+
function parseInputNumberValue(str, options = {}) {
|
|
4307
|
+
if (str === "" || str === "-") return null;
|
|
4308
|
+
if (options.parser) return options.parser(str);
|
|
4309
|
+
const num = Number(str);
|
|
4310
|
+
return Number.isNaN(num) ? null : num;
|
|
4311
|
+
}
|
|
4007
4312
|
|
|
4008
4313
|
// src/utils/form-item-styles.ts
|
|
4009
4314
|
var FORM_ITEM_SPACING = {
|
|
@@ -4398,128 +4703,128 @@ function isEmpty(value) {
|
|
|
4398
4703
|
}
|
|
4399
4704
|
return false;
|
|
4400
4705
|
}
|
|
4401
|
-
function validateType(value, type, customMessage) {
|
|
4706
|
+
function validateType(value, type, customMessage, messages = DEFAULT_FORM_VALIDATION_LABELS) {
|
|
4402
4707
|
switch (type) {
|
|
4403
4708
|
case "string":
|
|
4404
4709
|
if (typeof value !== "string") {
|
|
4405
|
-
return customMessage ||
|
|
4710
|
+
return customMessage || messages.typeString;
|
|
4406
4711
|
}
|
|
4407
4712
|
break;
|
|
4408
4713
|
case "number":
|
|
4409
4714
|
if (typeof value !== "number" && isNaN(Number(value))) {
|
|
4410
|
-
return customMessage ||
|
|
4715
|
+
return customMessage || messages.typeNumber;
|
|
4411
4716
|
}
|
|
4412
4717
|
break;
|
|
4413
4718
|
case "boolean":
|
|
4414
4719
|
if (typeof value !== "boolean") {
|
|
4415
|
-
return customMessage ||
|
|
4720
|
+
return customMessage || messages.typeBoolean;
|
|
4416
4721
|
}
|
|
4417
4722
|
break;
|
|
4418
4723
|
case "array":
|
|
4419
4724
|
if (!Array.isArray(value)) {
|
|
4420
|
-
return customMessage ||
|
|
4725
|
+
return customMessage || messages.typeArray;
|
|
4421
4726
|
}
|
|
4422
4727
|
break;
|
|
4423
4728
|
case "object":
|
|
4424
4729
|
if (typeof value !== "object" || Array.isArray(value)) {
|
|
4425
|
-
return customMessage ||
|
|
4730
|
+
return customMessage || messages.typeObject;
|
|
4426
4731
|
}
|
|
4427
4732
|
break;
|
|
4428
4733
|
case "email":
|
|
4429
4734
|
if (typeof value === "string" && !EMAIL_PATTERN.test(value)) {
|
|
4430
|
-
return customMessage ||
|
|
4735
|
+
return customMessage || messages.email;
|
|
4431
4736
|
}
|
|
4432
4737
|
break;
|
|
4433
4738
|
case "phone":
|
|
4434
4739
|
if (typeof value === "string") {
|
|
4435
4740
|
const digits = value.replace(/\D/g, "");
|
|
4436
4741
|
if (!PHONE_PATTERN.test(value) || digits.length < 7) {
|
|
4437
|
-
return customMessage ||
|
|
4742
|
+
return customMessage || messages.phone;
|
|
4438
4743
|
}
|
|
4439
4744
|
}
|
|
4440
4745
|
break;
|
|
4441
4746
|
case "url":
|
|
4442
4747
|
if (typeof value === "string" && !URL_PATTERN.test(value)) {
|
|
4443
|
-
return customMessage ||
|
|
4748
|
+
return customMessage || messages.url;
|
|
4444
4749
|
}
|
|
4445
4750
|
break;
|
|
4446
4751
|
case "date":
|
|
4447
4752
|
if (!(value instanceof Date) && isNaN(Date.parse(String(value)))) {
|
|
4448
|
-
return customMessage ||
|
|
4753
|
+
return customMessage || messages.date;
|
|
4449
4754
|
}
|
|
4450
4755
|
break;
|
|
4451
4756
|
case "id-card":
|
|
4452
4757
|
if (typeof value === "string" && !ID_CARD_PATTERN.test(value)) {
|
|
4453
|
-
return customMessage ||
|
|
4758
|
+
return customMessage || messages.idCard;
|
|
4454
4759
|
}
|
|
4455
4760
|
break;
|
|
4456
4761
|
}
|
|
4457
4762
|
return null;
|
|
4458
4763
|
}
|
|
4459
|
-
function validateRange(value, min, max, customMessage) {
|
|
4764
|
+
function validateRange(value, min, max, customMessage, messages = DEFAULT_FORM_VALIDATION_LABELS) {
|
|
4460
4765
|
if (typeof value === "string") {
|
|
4461
4766
|
if (min !== void 0 && value.length < min) {
|
|
4462
|
-
return customMessage ||
|
|
4767
|
+
return customMessage || messages.minLength.replace("{min}", String(min));
|
|
4463
4768
|
}
|
|
4464
4769
|
if (max !== void 0 && value.length > max) {
|
|
4465
|
-
return customMessage ||
|
|
4770
|
+
return customMessage || messages.maxLength.replace("{max}", String(max));
|
|
4466
4771
|
}
|
|
4467
4772
|
}
|
|
4468
4773
|
if (typeof value === "number") {
|
|
4469
4774
|
if (min !== void 0 && value < min) {
|
|
4470
|
-
return customMessage ||
|
|
4775
|
+
return customMessage || messages.minValue.replace("{min}", String(min));
|
|
4471
4776
|
}
|
|
4472
4777
|
if (max !== void 0 && value > max) {
|
|
4473
|
-
return customMessage ||
|
|
4778
|
+
return customMessage || messages.maxValue.replace("{max}", String(max));
|
|
4474
4779
|
}
|
|
4475
4780
|
}
|
|
4476
4781
|
if (Array.isArray(value)) {
|
|
4477
4782
|
if (min !== void 0 && value.length < min) {
|
|
4478
|
-
return customMessage ||
|
|
4783
|
+
return customMessage || messages.minItems.replace("{min}", String(min));
|
|
4479
4784
|
}
|
|
4480
4785
|
if (max !== void 0 && value.length > max) {
|
|
4481
|
-
return customMessage ||
|
|
4786
|
+
return customMessage || messages.maxItems.replace("{max}", String(max));
|
|
4482
4787
|
}
|
|
4483
4788
|
}
|
|
4484
4789
|
return null;
|
|
4485
4790
|
}
|
|
4486
|
-
async function validateRule(value, rule, allValues) {
|
|
4791
|
+
async function validateRule(value, rule, allValues, messages = DEFAULT_FORM_VALIDATION_LABELS) {
|
|
4487
4792
|
if (!rule.required && isEmpty(value)) {
|
|
4488
4793
|
return null;
|
|
4489
4794
|
}
|
|
4490
4795
|
const transformedValue = rule.transform ? rule.transform(value) : value;
|
|
4491
4796
|
if (rule.required && isEmpty(transformedValue)) {
|
|
4492
|
-
return rule.message ||
|
|
4797
|
+
return rule.message || messages.required;
|
|
4493
4798
|
}
|
|
4494
4799
|
if (rule.type && !isEmpty(transformedValue)) {
|
|
4495
|
-
const typeError = validateType(transformedValue, rule.type, rule.message);
|
|
4800
|
+
const typeError = validateType(transformedValue, rule.type, rule.message, messages);
|
|
4496
4801
|
if (typeError) return typeError;
|
|
4497
4802
|
}
|
|
4498
4803
|
if (!isEmpty(transformedValue)) {
|
|
4499
|
-
const rangeError = validateRange(transformedValue, rule.min, rule.max, rule.message);
|
|
4804
|
+
const rangeError = validateRange(transformedValue, rule.min, rule.max, rule.message, messages);
|
|
4500
4805
|
if (rangeError) return rangeError;
|
|
4501
4806
|
}
|
|
4502
4807
|
if (rule.pattern && typeof transformedValue === "string") {
|
|
4503
4808
|
if (!rule.pattern.test(transformedValue)) {
|
|
4504
|
-
return rule.message ||
|
|
4809
|
+
return rule.message || messages.patternMismatch;
|
|
4505
4810
|
}
|
|
4506
4811
|
}
|
|
4507
4812
|
if (rule.validator) {
|
|
4508
4813
|
try {
|
|
4509
4814
|
const result = await rule.validator(transformedValue, allValues);
|
|
4510
4815
|
if (result === false) {
|
|
4511
|
-
return rule.message ||
|
|
4816
|
+
return rule.message || messages.validatorFailed;
|
|
4512
4817
|
}
|
|
4513
4818
|
if (typeof result === "string") {
|
|
4514
4819
|
return result;
|
|
4515
4820
|
}
|
|
4516
4821
|
} catch {
|
|
4517
|
-
return rule.message ||
|
|
4822
|
+
return rule.message || messages.validatorError;
|
|
4518
4823
|
}
|
|
4519
4824
|
}
|
|
4520
4825
|
return null;
|
|
4521
4826
|
}
|
|
4522
|
-
async function validateField(fieldName, value, rules, allValues, trigger) {
|
|
4827
|
+
async function validateField(fieldName, value, rules, allValues, trigger, messages = DEFAULT_FORM_VALIDATION_LABELS) {
|
|
4523
4828
|
if (!rules) {
|
|
4524
4829
|
return null;
|
|
4525
4830
|
}
|
|
@@ -4532,18 +4837,18 @@ async function validateField(fieldName, value, rules, allValues, trigger) {
|
|
|
4532
4837
|
continue;
|
|
4533
4838
|
}
|
|
4534
4839
|
}
|
|
4535
|
-
const error = await validateRule(value, rule, allValues);
|
|
4840
|
+
const error = await validateRule(value, rule, allValues, messages);
|
|
4536
4841
|
if (error) {
|
|
4537
4842
|
return error;
|
|
4538
4843
|
}
|
|
4539
4844
|
}
|
|
4540
4845
|
return null;
|
|
4541
4846
|
}
|
|
4542
|
-
async function validateForm(values, rules) {
|
|
4847
|
+
async function validateForm(values, rules, messages = DEFAULT_FORM_VALIDATION_LABELS) {
|
|
4543
4848
|
const errors = [];
|
|
4544
4849
|
for (const [fieldName, fieldRules] of Object.entries(rules)) {
|
|
4545
4850
|
const value = getValueByPath(values, fieldName);
|
|
4546
|
-
const error = await validateField(fieldName, value, fieldRules, values);
|
|
4851
|
+
const error = await validateField(fieldName, value, fieldRules, values, void 0, messages);
|
|
4547
4852
|
if (error) {
|
|
4548
4853
|
errors.push({
|
|
4549
4854
|
field: fieldName,
|
|
@@ -4556,14 +4861,14 @@ async function validateForm(values, rules) {
|
|
|
4556
4861
|
errors
|
|
4557
4862
|
};
|
|
4558
4863
|
}
|
|
4559
|
-
async function validateFormFields(values, rules, fieldNames, trigger) {
|
|
4864
|
+
async function validateFormFields(values, rules, fieldNames, trigger, messages = DEFAULT_FORM_VALIDATION_LABELS) {
|
|
4560
4865
|
const errors = [];
|
|
4561
4866
|
const uniqueFieldNames = Array.from(new Set(fieldNames));
|
|
4562
4867
|
for (const fieldName of uniqueFieldNames) {
|
|
4563
4868
|
const fieldRules = rules[fieldName];
|
|
4564
4869
|
if (!fieldRules) continue;
|
|
4565
4870
|
const value = getValueByPath(values, fieldName);
|
|
4566
|
-
const error = await validateField(fieldName, value, fieldRules, values, trigger);
|
|
4871
|
+
const error = await validateField(fieldName, value, fieldRules, values, trigger, messages);
|
|
4567
4872
|
if (error) {
|
|
4568
4873
|
errors.push({ field: fieldName, message: error });
|
|
4569
4874
|
}
|
|
@@ -4711,6 +5016,23 @@ function normalizeDate(date) {
|
|
|
4711
5016
|
normalized.setHours(0, 0, 0, 0);
|
|
4712
5017
|
return normalized;
|
|
4713
5018
|
}
|
|
5019
|
+
function addDays(date, days) {
|
|
5020
|
+
const next = new Date(date);
|
|
5021
|
+
next.setDate(next.getDate() + days);
|
|
5022
|
+
return next;
|
|
5023
|
+
}
|
|
5024
|
+
function addMonths(date, months) {
|
|
5025
|
+
const next = new Date(date);
|
|
5026
|
+
const day = next.getDate();
|
|
5027
|
+
next.setDate(1);
|
|
5028
|
+
next.setMonth(next.getMonth() + months);
|
|
5029
|
+
const maxDay = getDaysInMonth(next.getFullYear(), next.getMonth());
|
|
5030
|
+
next.setDate(Math.min(day, maxDay));
|
|
5031
|
+
return next;
|
|
5032
|
+
}
|
|
5033
|
+
function addYears(date, years) {
|
|
5034
|
+
return addMonths(date, years * 12);
|
|
5035
|
+
}
|
|
4714
5036
|
function isDateInRange(date, minDate, maxDate) {
|
|
4715
5037
|
if (isNaN(date.getTime())) return false;
|
|
4716
5038
|
const normalizedDate = normalizeDate(date);
|
|
@@ -5866,6 +6188,22 @@ function filterHiddenColumns(columns, hiddenKeys) {
|
|
|
5866
6188
|
const visible = columns.filter((column) => !hidden.has(column.key));
|
|
5867
6189
|
return visible.length === columns.length ? columns : visible;
|
|
5868
6190
|
}
|
|
6191
|
+
function orderTableFixedColumns(columns) {
|
|
6192
|
+
const left = [];
|
|
6193
|
+
const normal = [];
|
|
6194
|
+
const right = [];
|
|
6195
|
+
for (const column of columns) {
|
|
6196
|
+
if (column.fixed === "left") {
|
|
6197
|
+
left.push(column);
|
|
6198
|
+
} else if (column.fixed === "right") {
|
|
6199
|
+
right.push(column);
|
|
6200
|
+
} else {
|
|
6201
|
+
normal.push(column);
|
|
6202
|
+
}
|
|
6203
|
+
}
|
|
6204
|
+
if (left.length === 0 && right.length === 0) return columns;
|
|
6205
|
+
return [...left, ...normal, ...right];
|
|
6206
|
+
}
|
|
5869
6207
|
function parseWidthToPx(width) {
|
|
5870
6208
|
if (typeof width === "number" && Number.isFinite(width)) {
|
|
5871
6209
|
return width;
|
|
@@ -5930,6 +6268,9 @@ function freezeTableColumnWidths(columns, measuredWidths = {}, previousFrozen =
|
|
|
5930
6268
|
const unchanged = previousKeys.length === nextKeys.length && nextKeys.every((key) => previousFrozen[key] === next[key]);
|
|
5931
6269
|
return unchanged ? previousFrozen : next;
|
|
5932
6270
|
}
|
|
6271
|
+
function getColumnWidthForOffset(column, measuredColumnWidths) {
|
|
6272
|
+
return measuredColumnWidths[column.key] || parseWidthToPx(column.width);
|
|
6273
|
+
}
|
|
5933
6274
|
function getFixedColumnOffsets(columns, measuredColumnWidths = {}) {
|
|
5934
6275
|
const leftOffsets = {};
|
|
5935
6276
|
const rightOffsets = {};
|
|
@@ -5940,8 +6281,8 @@ function getFixedColumnOffsets(columns, measuredColumnWidths = {}) {
|
|
|
5940
6281
|
if (column.fixed === "left") {
|
|
5941
6282
|
leftOffsets[column.key] = left;
|
|
5942
6283
|
hasLeftFixedColumns = true;
|
|
6284
|
+
left += getColumnWidthForOffset(column, measuredColumnWidths);
|
|
5943
6285
|
}
|
|
5944
|
-
left += measuredColumnWidths[column.key] || parseWidthToPx(column.width);
|
|
5945
6286
|
}
|
|
5946
6287
|
let right = 0;
|
|
5947
6288
|
for (let i = columns.length - 1; i >= 0; i--) {
|
|
@@ -5949,11 +6290,11 @@ function getFixedColumnOffsets(columns, measuredColumnWidths = {}) {
|
|
|
5949
6290
|
if (column.fixed === "right") {
|
|
5950
6291
|
rightOffsets[column.key] = right;
|
|
5951
6292
|
hasRightFixedColumns = true;
|
|
6293
|
+
right += getColumnWidthForOffset(column, measuredColumnWidths);
|
|
5952
6294
|
}
|
|
5953
|
-
right += measuredColumnWidths[column.key] || parseWidthToPx(column.width);
|
|
5954
6295
|
}
|
|
5955
6296
|
const minTableWidth = columns.reduce(
|
|
5956
|
-
(sum, col) => sum + (
|
|
6297
|
+
(sum, col) => sum + getColumnWidthForOffset(col, measuredColumnWidths),
|
|
5957
6298
|
0
|
|
5958
6299
|
);
|
|
5959
6300
|
const hasFixedColumns = hasLeftFixedColumns || hasRightFixedColumns;
|
|
@@ -6673,6 +7014,75 @@ function getVisibleTreeItems(treeData, expandedKeys = /* @__PURE__ */ new Set(),
|
|
|
6673
7014
|
traverse(treeData, 1);
|
|
6674
7015
|
return result;
|
|
6675
7016
|
}
|
|
7017
|
+
function getFirstVisibleChildKey(visibleItems, parentKey) {
|
|
7018
|
+
const index = visibleItems.findIndex((item) => item.key === parentKey);
|
|
7019
|
+
if (index < 0) return void 0;
|
|
7020
|
+
const base = visibleItems[index];
|
|
7021
|
+
for (let i = index + 1; i < visibleItems.length; i++) {
|
|
7022
|
+
const item = visibleItems[i];
|
|
7023
|
+
if (item.level <= base.level) break;
|
|
7024
|
+
if (item.parentKey === parentKey && !item.node.disabled) return item.key;
|
|
7025
|
+
}
|
|
7026
|
+
return void 0;
|
|
7027
|
+
}
|
|
7028
|
+
function getTreeKeyboardAction(ctx) {
|
|
7029
|
+
const {
|
|
7030
|
+
key,
|
|
7031
|
+
nodeKey,
|
|
7032
|
+
currentKey,
|
|
7033
|
+
focusableKeys,
|
|
7034
|
+
parentKey,
|
|
7035
|
+
firstChildKey,
|
|
7036
|
+
isExpandable,
|
|
7037
|
+
isExpanded,
|
|
7038
|
+
isParentExpanded,
|
|
7039
|
+
isChecked,
|
|
7040
|
+
selectable,
|
|
7041
|
+
checkable
|
|
7042
|
+
} = ctx;
|
|
7043
|
+
const currentIndex = focusableKeys.findIndex((k) => k === currentKey);
|
|
7044
|
+
const focusAt = (index) => ({
|
|
7045
|
+
type: "focus",
|
|
7046
|
+
key: focusableKeys[index] ?? currentKey
|
|
7047
|
+
});
|
|
7048
|
+
switch (key) {
|
|
7049
|
+
case "ArrowDown":
|
|
7050
|
+
return focusAt(currentIndex + 1);
|
|
7051
|
+
case "ArrowUp":
|
|
7052
|
+
return focusAt(currentIndex - 1);
|
|
7053
|
+
case "Home":
|
|
7054
|
+
return focusAt(0);
|
|
7055
|
+
case "End":
|
|
7056
|
+
return focusAt(focusableKeys.length - 1);
|
|
7057
|
+
case "ArrowRight":
|
|
7058
|
+
if (isExpandable && !isExpanded) return { type: "toggleExpand", key: nodeKey };
|
|
7059
|
+
if (isExpandable && isExpanded) return { type: "focus", key: firstChildKey ?? currentKey };
|
|
7060
|
+
return { type: "none" };
|
|
7061
|
+
case "ArrowLeft":
|
|
7062
|
+
if (isExpandable && isExpanded) return { type: "toggleExpand", key: nodeKey };
|
|
7063
|
+
return { type: "focus", key: parentKey ?? currentKey };
|
|
7064
|
+
case "Escape":
|
|
7065
|
+
if (isExpandable && isExpanded) return { type: "toggleExpand", key: nodeKey };
|
|
7066
|
+
if (parentKey !== void 0) {
|
|
7067
|
+
return {
|
|
7068
|
+
type: "collapseAndFocus",
|
|
7069
|
+
collapseKey: isParentExpanded ? parentKey : void 0,
|
|
7070
|
+
focusKey: parentKey
|
|
7071
|
+
};
|
|
7072
|
+
}
|
|
7073
|
+
return { type: "none" };
|
|
7074
|
+
case "Enter":
|
|
7075
|
+
if (selectable) return { type: "select", key: nodeKey };
|
|
7076
|
+
if (isExpandable) return { type: "toggleExpand", key: nodeKey };
|
|
7077
|
+
return { type: "none" };
|
|
7078
|
+
case " ":
|
|
7079
|
+
if (checkable) return { type: "check", key: nodeKey, checked: !isChecked };
|
|
7080
|
+
if (isExpandable) return { type: "toggleExpand", key: nodeKey };
|
|
7081
|
+
return { type: "none" };
|
|
7082
|
+
default:
|
|
7083
|
+
return null;
|
|
7084
|
+
}
|
|
7085
|
+
}
|
|
6676
7086
|
var treeBaseClasses = "w-full bg-white rounded-[var(--tiger-radius-md,0.5rem)]";
|
|
6677
7087
|
var treeNodeWrapperClasses = "select-none";
|
|
6678
7088
|
var treeNodeContentClasses = "flex items-center px-2 py-1.5 cursor-pointer rounded transition-colors duration-200";
|
|
@@ -7430,6 +7840,10 @@ function createSubmenuHeightTransitionController(element, options) {
|
|
|
7430
7840
|
}
|
|
7431
7841
|
};
|
|
7432
7842
|
}
|
|
7843
|
+
function getMenuNavigationKeys(mode, isRoot) {
|
|
7844
|
+
const isHorizontalRoot = isRoot && mode === "horizontal";
|
|
7845
|
+
return isHorizontalRoot ? { nextKey: "ArrowRight", prevKey: "ArrowLeft" } : { nextKey: "ArrowDown", prevKey: "ArrowUp" };
|
|
7846
|
+
}
|
|
7433
7847
|
function getMenuButtons(container) {
|
|
7434
7848
|
return Array.from(
|
|
7435
7849
|
container.querySelectorAll('button[data-tiger-menuitem="true"]')
|
|
@@ -8955,7 +9369,7 @@ function getCodeBlockCopyButtonClasses(isCopied, ...classes) {
|
|
|
8955
9369
|
);
|
|
8956
9370
|
}
|
|
8957
9371
|
|
|
8958
|
-
// src/theme/colors.ts
|
|
9372
|
+
// src/theme-runtime/colors.ts
|
|
8959
9373
|
var defaultThemeColors = {
|
|
8960
9374
|
primary: {
|
|
8961
9375
|
bg: "bg-[var(--tiger-primary,#2563eb)]",
|
|
@@ -9433,6 +9847,9 @@ function getInitialCropRect(imageWidth, imageHeight, aspectRatio) {
|
|
|
9433
9847
|
};
|
|
9434
9848
|
}
|
|
9435
9849
|
function cropCanvas(image, cropRect, displayWidth, displayHeight, outputType = "image/png", quality = 0.92) {
|
|
9850
|
+
if (!isBrowser()) {
|
|
9851
|
+
throw new Error("Image canvas cropping is only available in the browser");
|
|
9852
|
+
}
|
|
9436
9853
|
const scaleX = image.naturalWidth / displayWidth;
|
|
9437
9854
|
const scaleY = image.naturalHeight / displayHeight;
|
|
9438
9855
|
const sx = cropRect.x * scaleX;
|
|
@@ -9773,6 +10190,9 @@ function getAnchorLinkClasses(active, className) {
|
|
|
9773
10190
|
return [anchorLinkBaseClasses, active && anchorLinkActiveClasses, className].filter(Boolean).join(" ");
|
|
9774
10191
|
}
|
|
9775
10192
|
function getAnchorTargetElement(href) {
|
|
10193
|
+
if (!isBrowser()) {
|
|
10194
|
+
return null;
|
|
10195
|
+
}
|
|
9776
10196
|
if (!href || !href.startsWith("#")) {
|
|
9777
10197
|
return null;
|
|
9778
10198
|
}
|
|
@@ -9783,18 +10203,27 @@ function getAnchorTargetElement(href) {
|
|
|
9783
10203
|
return document.getElementById(id);
|
|
9784
10204
|
}
|
|
9785
10205
|
function getContainerScrollTop(container) {
|
|
10206
|
+
if (!isBrowser()) {
|
|
10207
|
+
return container?.scrollTop ?? 0;
|
|
10208
|
+
}
|
|
9786
10209
|
if (container === window) {
|
|
9787
10210
|
return window.scrollY || document.documentElement.scrollTop;
|
|
9788
10211
|
}
|
|
9789
10212
|
return container.scrollTop;
|
|
9790
10213
|
}
|
|
9791
10214
|
function getContainerHeight(container) {
|
|
10215
|
+
if (!isBrowser()) {
|
|
10216
|
+
return container?.clientHeight ?? 0;
|
|
10217
|
+
}
|
|
9792
10218
|
if (container === window) {
|
|
9793
10219
|
return window.innerHeight;
|
|
9794
10220
|
}
|
|
9795
10221
|
return container.clientHeight;
|
|
9796
10222
|
}
|
|
9797
10223
|
function getElementOffsetTop(element, container) {
|
|
10224
|
+
if (!isBrowser()) {
|
|
10225
|
+
return 0;
|
|
10226
|
+
}
|
|
9798
10227
|
if (container === window) {
|
|
9799
10228
|
const rect = element.getBoundingClientRect();
|
|
9800
10229
|
return rect.top + window.scrollY;
|
|
@@ -9814,6 +10243,9 @@ function getElementOffsetTop(element, container) {
|
|
|
9814
10243
|
return offset2;
|
|
9815
10244
|
}
|
|
9816
10245
|
function scrollToAnchor(href, container, targetOffset = 0) {
|
|
10246
|
+
if (!isBrowser()) {
|
|
10247
|
+
return;
|
|
10248
|
+
}
|
|
9817
10249
|
const element = getAnchorTargetElement(href);
|
|
9818
10250
|
if (!element) {
|
|
9819
10251
|
return;
|
|
@@ -9826,6 +10258,9 @@ function findActiveAnchor(links, container, bounds = 5, targetOffset = 0) {
|
|
|
9826
10258
|
if (links.length === 0) {
|
|
9827
10259
|
return "";
|
|
9828
10260
|
}
|
|
10261
|
+
if (!isBrowser()) {
|
|
10262
|
+
return links[0] || "";
|
|
10263
|
+
}
|
|
9829
10264
|
const scrollTop = getContainerScrollTop(container);
|
|
9830
10265
|
for (let i = links.length - 1; i >= 0; i--) {
|
|
9831
10266
|
const href = links[i];
|
|
@@ -9840,11 +10275,11 @@ function findActiveAnchor(links, container, bounds = 5, targetOffset = 0) {
|
|
|
9840
10275
|
return links[0] || "";
|
|
9841
10276
|
}
|
|
9842
10277
|
function createAnchorObserver(links, options) {
|
|
10278
|
+
if (!isBrowser()) return () => {
|
|
10279
|
+
};
|
|
9843
10280
|
if (typeof IntersectionObserver === "undefined") return () => {
|
|
9844
10281
|
};
|
|
9845
10282
|
const { offsetTop = 0, root = null, onChange } = options;
|
|
9846
|
-
if (!isBrowser()) return () => {
|
|
9847
|
-
};
|
|
9848
10283
|
const targets = /* @__PURE__ */ new Map();
|
|
9849
10284
|
for (const href of links) {
|
|
9850
10285
|
const el = getAnchorTargetElement(href);
|
|
@@ -13314,97 +13749,6 @@ function clampCronNumber(value, min, max) {
|
|
|
13314
13749
|
return Math.max(min, Math.min(max, Math.round(value)));
|
|
13315
13750
|
}
|
|
13316
13751
|
|
|
13317
|
-
// src/utils/picker-utils.ts
|
|
13318
|
-
var defaultIsDisabled = (item) => !!item?.disabled;
|
|
13319
|
-
function findFirstEnabledIndex(items, isDisabled = defaultIsDisabled) {
|
|
13320
|
-
for (let i = 0; i < items.length; i++) {
|
|
13321
|
-
if (!isDisabled(items[i])) return i;
|
|
13322
|
-
}
|
|
13323
|
-
return -1;
|
|
13324
|
-
}
|
|
13325
|
-
function findLastEnabledIndex(items, isDisabled = defaultIsDisabled) {
|
|
13326
|
-
for (let i = items.length - 1; i >= 0; i--) {
|
|
13327
|
-
if (!isDisabled(items[i])) return i;
|
|
13328
|
-
}
|
|
13329
|
-
return -1;
|
|
13330
|
-
}
|
|
13331
|
-
function findNextEnabledIndex(items, current, direction, isDisabled = defaultIsDisabled) {
|
|
13332
|
-
if (items.length === 0) return -1;
|
|
13333
|
-
const start = current < 0 ? direction === 1 ? 0 : items.length - 1 : current + direction;
|
|
13334
|
-
for (let i = start; i >= 0 && i < items.length; i += direction) {
|
|
13335
|
-
if (!isDisabled(items[i])) return i;
|
|
13336
|
-
}
|
|
13337
|
-
return current;
|
|
13338
|
-
}
|
|
13339
|
-
function getInitialPickerActiveIndex(items, activeFirst, isDisabled = defaultIsDisabled) {
|
|
13340
|
-
return activeFirst ? findFirstEnabledIndex(items, isDisabled) : -1;
|
|
13341
|
-
}
|
|
13342
|
-
function getPickerNavigationIndex(items, current, key, isDisabled = defaultIsDisabled) {
|
|
13343
|
-
switch (key) {
|
|
13344
|
-
case "ArrowDown":
|
|
13345
|
-
return findNextEnabledIndex(items, current, 1, isDisabled);
|
|
13346
|
-
case "ArrowUp":
|
|
13347
|
-
return findNextEnabledIndex(items, current, -1, isDisabled);
|
|
13348
|
-
case "Home":
|
|
13349
|
-
return findFirstEnabledIndex(items, isDisabled);
|
|
13350
|
-
case "End":
|
|
13351
|
-
return findLastEnabledIndex(items, isDisabled);
|
|
13352
|
-
default:
|
|
13353
|
-
return current;
|
|
13354
|
-
}
|
|
13355
|
-
}
|
|
13356
|
-
function getPickerOptionId(listboxId, index) {
|
|
13357
|
-
return `${listboxId}-option-${index}`;
|
|
13358
|
-
}
|
|
13359
|
-
function getDisclosureStateAttr(open) {
|
|
13360
|
-
return { "data-state": open ? "open" : "closed" };
|
|
13361
|
-
}
|
|
13362
|
-
function getPickerComboboxAria({
|
|
13363
|
-
expanded,
|
|
13364
|
-
listboxId,
|
|
13365
|
-
activeIndex = -1,
|
|
13366
|
-
activeOptionId
|
|
13367
|
-
}) {
|
|
13368
|
-
return {
|
|
13369
|
-
role: "combobox",
|
|
13370
|
-
"aria-expanded": expanded,
|
|
13371
|
-
"aria-haspopup": "listbox",
|
|
13372
|
-
"aria-controls": expanded ? listboxId : void 0,
|
|
13373
|
-
"aria-activedescendant": expanded ? activeOptionId ?? (activeIndex >= 0 ? getPickerOptionId(listboxId, activeIndex) : void 0) : void 0,
|
|
13374
|
-
"data-state": expanded ? "open" : "closed"
|
|
13375
|
-
};
|
|
13376
|
-
}
|
|
13377
|
-
function getPickerListboxAria({ id, label } = {}) {
|
|
13378
|
-
return {
|
|
13379
|
-
id,
|
|
13380
|
-
role: "listbox",
|
|
13381
|
-
"aria-label": label
|
|
13382
|
-
};
|
|
13383
|
-
}
|
|
13384
|
-
function getPickerOptionAria({
|
|
13385
|
-
selected = false,
|
|
13386
|
-
disabled = false
|
|
13387
|
-
}) {
|
|
13388
|
-
return {
|
|
13389
|
-
role: "option",
|
|
13390
|
-
"aria-selected": selected,
|
|
13391
|
-
"aria-disabled": disabled || void 0
|
|
13392
|
-
};
|
|
13393
|
-
}
|
|
13394
|
-
function getPickerTriggerKeyAction(key, expanded) {
|
|
13395
|
-
switch (key) {
|
|
13396
|
-
case "Enter":
|
|
13397
|
-
case " ":
|
|
13398
|
-
return "toggle";
|
|
13399
|
-
case "ArrowDown":
|
|
13400
|
-
return expanded ? "none" : "open";
|
|
13401
|
-
case "Escape":
|
|
13402
|
-
return expanded ? "close" : "none";
|
|
13403
|
-
default:
|
|
13404
|
-
return "none";
|
|
13405
|
-
}
|
|
13406
|
-
}
|
|
13407
|
-
|
|
13408
13752
|
// src/utils/spotlight-utils.ts
|
|
13409
13753
|
var spotlightRootClasses = "fixed inset-0 flex items-start justify-center px-4 py-6 sm:py-10";
|
|
13410
13754
|
var spotlightMaskClasses = "absolute inset-0 bg-black/35";
|
|
@@ -14655,6 +14999,7 @@ function exportTableToExcel(columns, data) {
|
|
|
14655
14999
|
return `<!doctype html><html><head><meta charset="utf-8"></head><body><table><thead><tr>${headerCells}</tr></thead><tbody>${bodyRows}</tbody></table></body></html>`;
|
|
14656
15000
|
}
|
|
14657
15001
|
function downloadCsv(csvContent, filename = "export") {
|
|
15002
|
+
if (!isBrowser()) return;
|
|
14658
15003
|
const blob = new Blob([csvContent], { type: "text/csv;charset=utf-8;" });
|
|
14659
15004
|
const url = URL.createObjectURL(blob);
|
|
14660
15005
|
const link = document.createElement("a");
|
|
@@ -14667,6 +15012,7 @@ function downloadCsv(csvContent, filename = "export") {
|
|
|
14667
15012
|
URL.revokeObjectURL(url);
|
|
14668
15013
|
}
|
|
14669
15014
|
function downloadExcel(excelContent, filename = "export") {
|
|
15015
|
+
if (!isBrowser()) return;
|
|
14670
15016
|
const blob = new Blob([excelContent], { type: "application/vnd.ms-excel;charset=utf-8;" });
|
|
14671
15017
|
const url = URL.createObjectURL(blob);
|
|
14672
15018
|
const link = document.createElement("a");
|
|
@@ -16128,7 +16474,6 @@ var kanbanSwimlaneDotClasses = "w-2.5 h-2.5 rounded-full shrink-0";
|
|
|
16128
16474
|
var kanbanSwimlaneCollapsedClasses = "hidden";
|
|
16129
16475
|
var kanbanFilterHighlightClasses = "bg-[var(--tiger-warning,#fbbf24)]/20";
|
|
16130
16476
|
var kanbanAddColumnClasses = "flex items-center justify-center shrink-0 w-76 min-h-[120px] rounded-[var(--tiger-radius-lg,0.75rem)] border-2 border-dashed border-[var(--tiger-border,#e5e7eb)] bg-[var(--tiger-surface-muted,#f9fafb)]/40 text-sm font-medium text-[var(--tiger-text-muted,#6b7280)] hover:border-[var(--tiger-primary,#2563eb)]/80 hover:text-[var(--tiger-primary,#2563eb)] hover:bg-[var(--tiger-surface,#ffffff)] hover:shadow-sm cursor-pointer transition-all duration-300 active:scale-98";
|
|
16131
|
-
var kanbanAddCardClasses = taskBoardAddCardClasses;
|
|
16132
16477
|
function filterCards(cards, filterText) {
|
|
16133
16478
|
if (!filterText.trim()) return cards;
|
|
16134
16479
|
const lower = filterText.toLowerCase();
|
|
@@ -17149,6 +17494,7 @@ function getChartSvgDataUrl(svg) {
|
|
|
17149
17494
|
return `data:image/svg+xml;charset=utf-8,${encodeURIComponent(serializeChartSvg(svg))}`;
|
|
17150
17495
|
}
|
|
17151
17496
|
function downloadChartSvg(svg, filename = "chart") {
|
|
17497
|
+
if (!isBrowser()) return;
|
|
17152
17498
|
downloadChartBlob(
|
|
17153
17499
|
new Blob([serializeChartSvg(svg)], { type: "image/svg+xml;charset=utf-8" }),
|
|
17154
17500
|
`${filename}.svg`
|
|
@@ -17188,6 +17534,7 @@ async function exportChartPng(svg, options = {}) {
|
|
|
17188
17534
|
});
|
|
17189
17535
|
}
|
|
17190
17536
|
async function downloadChartPng(svg, options = {}) {
|
|
17537
|
+
if (!isBrowser()) return;
|
|
17191
17538
|
const blob = await exportChartPng(svg, options);
|
|
17192
17539
|
downloadChartBlob(blob, `${options.filename ?? "chart"}.png`);
|
|
17193
17540
|
}
|
|
@@ -17364,7 +17711,7 @@ async function getCropperResult(cropper) {
|
|
|
17364
17711
|
return await cropper.getCropResult();
|
|
17365
17712
|
}
|
|
17366
17713
|
|
|
17367
|
-
// src/theme/checkbox.ts
|
|
17714
|
+
// src/theme-runtime/checkbox.ts
|
|
17368
17715
|
var checkboxSizeClasses2 = {
|
|
17369
17716
|
sm: "w-4 h-4",
|
|
17370
17717
|
md: "w-5 h-5",
|
|
@@ -17389,7 +17736,7 @@ function getCheckboxLabelClasses(size = "md", disabled = false) {
|
|
|
17389
17736
|
return [baseClasses2, sizeClass, disabledClasses].filter(Boolean).join(" ");
|
|
17390
17737
|
}
|
|
17391
17738
|
|
|
17392
|
-
// src/theme/switch.ts
|
|
17739
|
+
// src/theme-runtime/switch.ts
|
|
17393
17740
|
var switchBaseClasses = "relative inline-flex items-center rounded-full transition-all duration-150 focus:outline-none focus-visible:ring-2 focus-visible:ring-offset-2 focus-visible:ring-[var(--tiger-focus-ring,var(--tiger-primary,#2563eb))] active:scale-[0.98]";
|
|
17394
17741
|
var switchSizeClasses = {
|
|
17395
17742
|
sm: "h-5 w-9",
|
|
@@ -17424,7 +17771,7 @@ function getSwitchThumbClasses(size = "md", checked = false) {
|
|
|
17424
17771
|
return classNames(baseClasses2, sizeClass, translateClass);
|
|
17425
17772
|
}
|
|
17426
17773
|
|
|
17427
|
-
// src/theme/slider.ts
|
|
17774
|
+
// src/theme-runtime/slider.ts
|
|
17428
17775
|
var sliderBaseClasses = "relative w-full";
|
|
17429
17776
|
var sliderTrackClasses = "bg-[var(--tiger-border,#e5e7eb)] rounded-full";
|
|
17430
17777
|
var sliderRangeClasses = "bg-[var(--tiger-primary,#2563eb)] rounded-full absolute h-full";
|
|
@@ -17463,7 +17810,7 @@ function getSliderTooltipClasses(size = "md") {
|
|
|
17463
17810
|
return [sliderTooltipClasses, sizeClass].filter(Boolean).join(" ");
|
|
17464
17811
|
}
|
|
17465
17812
|
|
|
17466
|
-
// src/theme/index.ts
|
|
17813
|
+
// src/theme-runtime/index.ts
|
|
17467
17814
|
var THEME_CSS_VARS = {
|
|
17468
17815
|
// Primary colors
|
|
17469
17816
|
primary: "--tiger-primary",
|
|
@@ -19026,7 +19373,7 @@ var designTokens = {
|
|
|
19026
19373
|
};
|
|
19027
19374
|
|
|
19028
19375
|
// src/index.ts
|
|
19029
|
-
var version = "1.
|
|
19376
|
+
var version = "1.4.0";
|
|
19030
19377
|
// Annotate the CommonJS export names for ESM import in node:
|
|
19031
19378
|
0 && (module.exports = {
|
|
19032
19379
|
ANIMATION_DURATION_FAST_MS,
|
|
@@ -19042,12 +19389,15 @@ var version = "1.2.0";
|
|
|
19042
19389
|
ClockIconPath,
|
|
19043
19390
|
CloseIconPath,
|
|
19044
19391
|
DEFAULT_CHART_COLORS,
|
|
19392
|
+
DEFAULT_FORM_VALIDATION_LABELS,
|
|
19045
19393
|
DEFAULT_FORM_WIZARD_LABELS,
|
|
19046
19394
|
DEFAULT_HEATMAP_CANVAS_THRESHOLD,
|
|
19047
19395
|
DEFAULT_PAGINATION_LABELS,
|
|
19048
19396
|
DEFAULT_TABLE_LABELS,
|
|
19049
19397
|
DEFAULT_TASK_BOARD_LABELS,
|
|
19398
|
+
DEFAULT_TIME_PICKER_LABELS,
|
|
19050
19399
|
DEFAULT_UPLOAD_CHUNK_SIZE,
|
|
19400
|
+
DEFAULT_UPLOAD_LABELS,
|
|
19051
19401
|
DONUT_BASE_SHADOW,
|
|
19052
19402
|
DONUT_EMPHASIS_SHADOW,
|
|
19053
19403
|
DROPDOWN_CHEVRON_PATH,
|
|
@@ -19105,10 +19455,13 @@ var version = "1.2.0";
|
|
|
19105
19455
|
VIEW_TRANSITION_CSS,
|
|
19106
19456
|
WEEKDAYS,
|
|
19107
19457
|
ZH_CN_DATEPICKER_LOCALE,
|
|
19458
|
+
ZH_CN_FORM_VALIDATION_LABELS,
|
|
19108
19459
|
ZH_CN_FORM_WIZARD_LABELS,
|
|
19109
19460
|
ZH_CN_PAGINATION_LABELS,
|
|
19110
19461
|
ZH_CN_TABLE_LABELS,
|
|
19111
19462
|
ZH_CN_TASK_BOARD_LABELS,
|
|
19463
|
+
ZH_CN_TIME_PICKER_LABELS,
|
|
19464
|
+
ZH_CN_UPLOAD_LABELS,
|
|
19112
19465
|
activeOpacityClasses,
|
|
19113
19466
|
activePressClasses,
|
|
19114
19467
|
activityItemActionsClasses,
|
|
@@ -19118,6 +19471,9 @@ var version = "1.2.0";
|
|
|
19118
19471
|
activityItemHeaderClasses,
|
|
19119
19472
|
activityItemLayoutClasses,
|
|
19120
19473
|
activityItemTitleGroupClasses,
|
|
19474
|
+
addDays,
|
|
19475
|
+
addMonths,
|
|
19476
|
+
addYears,
|
|
19121
19477
|
affixWrapperClasses,
|
|
19122
19478
|
alertBannerClasses,
|
|
19123
19479
|
alertBaseClasses,
|
|
@@ -19397,6 +19753,7 @@ var version = "1.2.0";
|
|
|
19397
19753
|
createImageAnnotationBox,
|
|
19398
19754
|
createImageAnnotationPath,
|
|
19399
19755
|
createInfiniteScrollObserver,
|
|
19756
|
+
createInstanceCounter,
|
|
19400
19757
|
createLinePath,
|
|
19401
19758
|
createLinearScale,
|
|
19402
19759
|
createLongPressController,
|
|
@@ -19592,6 +19949,7 @@ var version = "1.2.0";
|
|
|
19592
19949
|
focusMenuEdge,
|
|
19593
19950
|
focusRingClasses,
|
|
19594
19951
|
focusRingInsetClasses,
|
|
19952
|
+
focusTimePickerOption,
|
|
19595
19953
|
formatActivityTime,
|
|
19596
19954
|
formatBadgeContent,
|
|
19597
19955
|
formatChatTime,
|
|
@@ -19603,6 +19961,7 @@ var version = "1.2.0";
|
|
|
19603
19961
|
formatFileSize,
|
|
19604
19962
|
formatFileSizeLabel,
|
|
19605
19963
|
formatGanttDate,
|
|
19964
|
+
formatInputNumberDisplay,
|
|
19606
19965
|
formatIntlNumber,
|
|
19607
19966
|
formatMonthYear,
|
|
19608
19967
|
formatPageAriaLabel,
|
|
@@ -19738,6 +20097,7 @@ var version = "1.2.0";
|
|
|
19738
20097
|
getCropperResult,
|
|
19739
20098
|
getCurrentActiveTourStep,
|
|
19740
20099
|
getCurrentTime,
|
|
20100
|
+
getCyclicIndex,
|
|
19741
20101
|
getDatePickerDayCellClasses,
|
|
19742
20102
|
getDatePickerIconButtonClasses,
|
|
19743
20103
|
getDatePickerInputClasses,
|
|
@@ -19789,6 +20149,7 @@ var version = "1.2.0";
|
|
|
19789
20149
|
getFileListItemClasses,
|
|
19790
20150
|
getFileManagerContainerClasses,
|
|
19791
20151
|
getFirstDayOfMonth,
|
|
20152
|
+
getFirstVisibleChildKey,
|
|
19792
20153
|
getFixedColumnOffsets,
|
|
19793
20154
|
getFixedColumnPosition,
|
|
19794
20155
|
getFixedColumnStyle,
|
|
@@ -19804,6 +20165,7 @@ var version = "1.2.0";
|
|
|
19804
20165
|
getFormItemErrorClasses,
|
|
19805
20166
|
getFormItemFieldClasses,
|
|
19806
20167
|
getFormItemLabelClasses,
|
|
20168
|
+
getFormValidationLabels,
|
|
19807
20169
|
getFormWizardLabels,
|
|
19808
20170
|
getFunnelGradientPrefix,
|
|
19809
20171
|
getGanttDependencyPath,
|
|
@@ -19883,6 +20245,7 @@ var version = "1.2.0";
|
|
|
19883
20245
|
getMenuItemClasses,
|
|
19884
20246
|
getMenuItemIndent,
|
|
19885
20247
|
getMenuItems,
|
|
20248
|
+
getMenuNavigationKeys,
|
|
19886
20249
|
getMessageIconPath,
|
|
19887
20250
|
getMessageTypeClasses,
|
|
19888
20251
|
getModalContainerClasses,
|
|
@@ -20105,6 +20468,7 @@ var version = "1.2.0";
|
|
|
20105
20468
|
getTransferItemClasses,
|
|
20106
20469
|
getTransformOrigin,
|
|
20107
20470
|
getTransitionClasses,
|
|
20471
|
+
getTreeKeyboardAction,
|
|
20108
20472
|
getTreeMapGradientPrefix,
|
|
20109
20473
|
getTreeNodeClasses,
|
|
20110
20474
|
getTreeNodeExpandIconClasses,
|
|
@@ -20279,7 +20643,6 @@ var version = "1.2.0";
|
|
|
20279
20643
|
isValidHex,
|
|
20280
20644
|
isValidUrl,
|
|
20281
20645
|
isWipExceeded,
|
|
20282
|
-
kanbanAddCardClasses,
|
|
20283
20646
|
kanbanAddColumnClasses,
|
|
20284
20647
|
kanbanCardCountClasses,
|
|
20285
20648
|
kanbanFilterHighlightClasses,
|
|
@@ -20436,6 +20799,7 @@ var version = "1.2.0";
|
|
|
20436
20799
|
numberKeyboardGridClasses,
|
|
20437
20800
|
numberKeyboardKeyClasses,
|
|
20438
20801
|
numberKeyboardRootClasses,
|
|
20802
|
+
orderTableFixedColumns,
|
|
20439
20803
|
orgChartLinkClasses,
|
|
20440
20804
|
orgChartNodeClasses,
|
|
20441
20805
|
orgChartNodeLabelClasses,
|
|
@@ -20451,6 +20815,7 @@ var version = "1.2.0";
|
|
|
20451
20815
|
parseDragData,
|
|
20452
20816
|
parseHeight,
|
|
20453
20817
|
parseHotkey,
|
|
20818
|
+
parseInputNumberValue,
|
|
20454
20819
|
parseInputValue,
|
|
20455
20820
|
parseMarkdownHeight,
|
|
20456
20821
|
parsePaneSize,
|