@sunggang/ui-lib 0.4.7 → 0.4.9
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/baseSwitch.cjs.js +5 -2
- package/baseSwitch.esm.js +5 -2
- package/package.json +1 -1
- package/src/lib/Form/demo.d.ts +33 -1
package/baseSwitch.cjs.js
CHANGED
|
@@ -22352,7 +22352,9 @@ var FlatpickrInput = /*#__PURE__*/ React.forwardRef(function(param, ref) {
|
|
|
22352
22352
|
instance.close();
|
|
22353
22353
|
}, 50);
|
|
22354
22354
|
}
|
|
22355
|
-
} else if (mode === "multiple" || (item === null || item === void 0 ? void 0 : item.flatpickrType) === "time")
|
|
22355
|
+
} else if (mode === "multiple" || (item === null || item === void 0 ? void 0 : item.flatpickrType) === "time") {
|
|
22356
|
+
onChange(selectedDates);
|
|
22357
|
+
} else {
|
|
22356
22358
|
// Single mode: 返回單一日期,預設行為會自動關閉
|
|
22357
22359
|
onChange(selectedDates.length > 0 ? selectedDates[0] : null);
|
|
22358
22360
|
}
|
|
@@ -22429,7 +22431,8 @@ var FlatpickrInput = /*#__PURE__*/ React.forwardRef(function(param, ref) {
|
|
|
22429
22431
|
placeholder: (item === null || item === void 0 ? void 0 : item.placeholder) || "請選擇日期",
|
|
22430
22432
|
style: item === null || item === void 0 ? void 0 : item.style,
|
|
22431
22433
|
disabled: isDisabled,
|
|
22432
|
-
readOnly: true
|
|
22434
|
+
readOnly: true,
|
|
22435
|
+
autoComplete: "off"
|
|
22433
22436
|
}),
|
|
22434
22437
|
(item === null || item === void 0 ? void 0 : item.icon) && /*#__PURE__*/ jsxRuntime.jsx("div", {
|
|
22435
22438
|
className: "absolute right-3 top-1/2 transform -translate-y-1/2 pointer-events-none",
|
package/baseSwitch.esm.js
CHANGED
|
@@ -22323,7 +22323,9 @@ var FlatpickrInput = /*#__PURE__*/ forwardRef(function(param, ref) {
|
|
|
22323
22323
|
instance.close();
|
|
22324
22324
|
}, 50);
|
|
22325
22325
|
}
|
|
22326
|
-
} else if (mode === "multiple" || (item === null || item === void 0 ? void 0 : item.flatpickrType) === "time")
|
|
22326
|
+
} else if (mode === "multiple" || (item === null || item === void 0 ? void 0 : item.flatpickrType) === "time") {
|
|
22327
|
+
onChange(selectedDates);
|
|
22328
|
+
} else {
|
|
22327
22329
|
// Single mode: 返回單一日期,預設行為會自動關閉
|
|
22328
22330
|
onChange(selectedDates.length > 0 ? selectedDates[0] : null);
|
|
22329
22331
|
}
|
|
@@ -22400,7 +22402,8 @@ var FlatpickrInput = /*#__PURE__*/ forwardRef(function(param, ref) {
|
|
|
22400
22402
|
placeholder: (item === null || item === void 0 ? void 0 : item.placeholder) || "請選擇日期",
|
|
22401
22403
|
style: item === null || item === void 0 ? void 0 : item.style,
|
|
22402
22404
|
disabled: isDisabled,
|
|
22403
|
-
readOnly: true
|
|
22405
|
+
readOnly: true,
|
|
22406
|
+
autoComplete: "off"
|
|
22404
22407
|
}),
|
|
22405
22408
|
(item === null || item === void 0 ? void 0 : item.icon) && /*#__PURE__*/ jsx$1("div", {
|
|
22406
22409
|
className: "absolute right-3 top-1/2 transform -translate-y-1/2 pointer-events-none",
|
package/package.json
CHANGED
package/src/lib/Form/demo.d.ts
CHANGED
|
@@ -22,9 +22,38 @@ export declare const config: (getValues: (name: string) => unknown) => (FormItem
|
|
|
22
22
|
time_24hr: boolean;
|
|
23
23
|
enableTime: boolean;
|
|
24
24
|
dateFormat: string;
|
|
25
|
+
noCalendar?: undefined;
|
|
25
26
|
};
|
|
26
|
-
|
|
27
|
+
id?: undefined;
|
|
28
|
+
errorText?: undefined;
|
|
27
29
|
placeholder?: undefined;
|
|
30
|
+
flatpickrType?: undefined;
|
|
31
|
+
option?: undefined;
|
|
32
|
+
noDataText?: undefined;
|
|
33
|
+
hiddenText?: undefined;
|
|
34
|
+
hiddenSearch?: undefined;
|
|
35
|
+
dropStyle?: undefined;
|
|
36
|
+
className?: undefined;
|
|
37
|
+
} | {
|
|
38
|
+
type: string;
|
|
39
|
+
icon: string;
|
|
40
|
+
name: string;
|
|
41
|
+
label: string;
|
|
42
|
+
id: string;
|
|
43
|
+
errorText: string;
|
|
44
|
+
placeholder: string;
|
|
45
|
+
flatpickrType: string;
|
|
46
|
+
validateOption: {
|
|
47
|
+
required: string;
|
|
48
|
+
};
|
|
49
|
+
flatpickrOptions: {
|
|
50
|
+
dateFormat: string;
|
|
51
|
+
enableTime: boolean;
|
|
52
|
+
mode: string;
|
|
53
|
+
noCalendar: boolean;
|
|
54
|
+
time_24hr: boolean;
|
|
55
|
+
};
|
|
56
|
+
option?: undefined;
|
|
28
57
|
noDataText?: undefined;
|
|
29
58
|
hiddenText?: undefined;
|
|
30
59
|
hiddenSearch?: undefined;
|
|
@@ -55,6 +84,9 @@ export declare const config: (getValues: (name: string) => unknown) => (FormItem
|
|
|
55
84
|
className: string;
|
|
56
85
|
icon?: undefined;
|
|
57
86
|
flatpickrOptions?: undefined;
|
|
87
|
+
id?: undefined;
|
|
88
|
+
errorText?: undefined;
|
|
89
|
+
flatpickrType?: undefined;
|
|
58
90
|
})[] | {
|
|
59
91
|
type: string;
|
|
60
92
|
name: string;
|