react-kui 3.2.0 → 3.3.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/ai/kui-components.json +825 -168
- package/es/_virtual/_rolldown/runtime.js +2 -3
- package/es/affix/index.js +73 -185
- package/es/alert/index.js +3 -4
- package/es/anchor/anchor-context.js +2 -3
- package/es/anchor/anchor-link.js +3 -4
- package/es/anchor/anchor.js +195 -398
- package/es/auto-complete/index.js +160 -561
- package/es/avatar/avatar-group-context.js +2 -3
- package/es/avatar/avatar-group.js +32 -124
- package/es/avatar/avatar.js +58 -159
- package/es/back-top/index.js +66 -201
- package/es/badge/index.js +4 -5
- package/es/base/teleport.js +22 -54
- package/es/base/transition-props.js +2 -3
- package/es/base/transition.js +2 -3
- package/es/breadcrumb/breadcrumb-context.js +2 -3
- package/es/breadcrumb/breadcrumb-item.js +19 -102
- package/es/breadcrumb/breadcrumb.js +10 -59
- package/es/button/button-group-context.js +2 -3
- package/es/button/button-group.js +15 -75
- package/es/button/button.js +4 -5
- package/es/calendar/index.js +4 -5
- package/es/card/index.js +4 -5
- package/es/carousel/carousel-context.js +2 -3
- package/es/carousel/carousel-item.js +3 -4
- package/es/carousel/carousel.js +281 -628
- package/es/carousel/drag.js +2 -3
- package/es/cascader/index.js +7 -8
- package/es/check-card/check-card-group.js +53 -179
- package/es/check-card/check-card.js +100 -293
- package/es/check-card/context.js +2 -3
- package/es/checkbox/checkbox-group-context.js +2 -3
- package/es/checkbox/checkbox-group.js +34 -138
- package/es/checkbox/checkbox.js +4 -5
- package/es/checkbox/index.js +2 -3
- package/es/collapse/collapse-panel.js +84 -206
- package/es/collapse/collapse.js +38 -170
- package/es/color-picker/alpha.js +44 -125
- package/es/color-picker/hue.js +39 -108
- package/es/color-picker/index.js +7 -6
- package/es/color-picker/mode.js +76 -159
- package/es/color-picker/paint.js +66 -163
- package/es/color-picker/presets.js +12 -44
- package/es/components.js +37 -32
- package/es/config/config-context.js +2 -3
- package/es/config/context.js +2 -3
- package/es/config/index.js +3 -4
- package/es/config/popup-host.js +3 -4
- package/es/config/size-context.js +2 -3
- package/es/config/use-config-appearance.js +3 -4
- package/es/const/var.js +2 -3
- package/es/date-picker/index.js +8 -9
- package/es/descriptions/descriptions-item.js +3 -4
- package/es/descriptions/descriptions.js +53 -144
- package/es/divider/index.js +2 -3
- package/es/drawer/index.js +171 -465
- package/es/dropdown/dropdown-button.js +25 -128
- package/es/dropdown/dropdown-context.js +2 -3
- package/es/dropdown/dropdown.js +56 -207
- package/es/dropdown/trigger.js +37 -125
- package/es/empty/index.js +34 -111
- package/es/feature-card/index.js +2 -3
- package/es/feedback-panel/index.js +30 -155
- package/es/flame-wrap/index.js +3 -4
- package/es/flame-wrap/types.js +2 -3
- package/es/flex/index.js +2 -3
- package/es/form/field-context.js +3 -4
- package/es/form/form-context.js +2 -3
- package/es/form/form-item.js +4 -5
- package/es/form/form.js +108 -279
- package/es/form/utils.js +2 -3
- package/es/gradient-picker/corners.js +55 -0
- package/es/gradient-picker/index.js +191 -0
- package/es/gradient-picker/stops.js +219 -0
- package/es/gradient-picker/types.js +147 -0
- package/es/grid/grid-item.js +25 -116
- package/es/grid/grid.js +40 -151
- package/es/grid/useBreakpoint.js +3 -4
- package/es/icon/index.js +24 -126
- package/es/image/group.js +3 -4
- package/es/image/image-group-context.js +2 -3
- package/es/image/image.js +5 -6
- package/es/image/instance.js +2 -3
- package/es/image/preview.js +4 -5
- package/es/image/utils.js +2 -3
- package/es/index.js +5 -4
- package/es/input/index.js +2 -3
- package/es/input/input-base.js +4 -5
- package/es/input/input-box.js +2 -3
- package/es/input/input-group.js +4 -5
- package/es/input/input.js +3 -4
- package/es/input/textarea.js +3 -4
- package/es/input-number/drag.js +63 -0
- package/es/input-number/index.js +41 -11
- package/es/input-otp/index.js +3 -4
- package/es/input-tag/index.js +5 -6
- package/es/kanban/index.js +31 -168
- package/es/layout/index.js +43 -215
- package/es/layout/layout-context.js +2 -3
- package/es/list-panel/index.js +47 -185
- package/es/loading/index.js +2 -3
- package/es/loading/loading-bar.js +54 -114
- package/es/locale/de.js +2 -3
- package/es/locale/el.js +2 -3
- package/es/locale/en.js +2 -3
- package/es/locale/fr.js +2 -3
- package/es/locale/it.js +2 -3
- package/es/locale/ja.js +2 -3
- package/es/locale/ko.js +2 -3
- package/es/locale/ru.js +2 -3
- package/es/locale/th.js +2 -3
- package/es/locale/uk.js +2 -3
- package/es/locale/vi.js +2 -3
- package/es/locale/zh-CN.js +2 -3
- package/es/locale/zh-TW.js +2 -3
- package/es/mentions/index.js +214 -581
- package/es/menu/menu-context.js +2 -3
- package/es/menu/menu-divider.js +3 -4
- package/es/menu/menu-group.js +3 -4
- package/es/menu/menu-item.js +2 -3
- package/es/menu/menu-keyboard.js +2 -3
- package/es/menu/menu.js +184 -442
- package/es/menu/recursive-menu.js +3 -4
- package/es/menu/sub-menu.js +5 -6
- package/es/message/index.js +2 -3
- package/es/modal/api.js +2 -3
- package/es/modal/modal.js +263 -599
- package/es/modal/toast.js +63 -179
- package/es/node_modules/.pnpm/kui-icons@5.0.0/node_modules/kui-icons/dist/kui-icons.esm.js +2 -3
- package/es/notice/container.js +2 -3
- package/es/notice/content.js +4 -5
- package/es/notice/index.js +2 -3
- package/es/notice/instance.js +2 -3
- package/es/page/index.js +4 -5
- package/es/page/responsive.js +2 -3
- package/es/page-header/index.js +3 -4
- package/es/popconfirm/index.js +24 -70
- package/es/poptip/index.js +29 -88
- package/es/popup/index.js +8 -6
- package/es/popup/layers.js +2 -3
- package/es/progress/index.js +95 -229
- package/es/qrcode/index.js +3 -4
- package/es/radio/radio-button.js +37 -131
- package/es/radio/radio-group-context.js +2 -3
- package/es/radio/radio-group.js +69 -223
- package/es/radio/radio.js +3 -4
- package/es/rate/index.js +68 -226
- package/es/rate/star.js +38 -129
- package/es/result/index.js +35 -127
- package/es/ripple/index.js +3 -4
- package/es/ripple/types.js +2 -3
- package/es/row-col/col.js +59 -149
- package/es/row-col/row.js +2 -3
- package/es/segmented/index.js +72 -196
- package/es/select/option.js +23 -116
- package/es/select/select.js +9 -10
- package/es/skeleton/skeleton-avatar.js +2 -3
- package/es/skeleton/skeleton-button.js +2 -3
- package/es/skeleton/skeleton-image.js +28 -108
- package/es/skeleton/skeleton-text.js +17 -93
- package/es/skeleton/skeleton.js +46 -133
- package/es/skeleton/use-skeleton-loading.js +3 -4
- package/es/slider/index.js +92 -286
- package/es/slider/thumb.js +43 -133
- package/es/space/index.js +3 -4
- package/es/spin/index.js +2 -3
- package/es/splitter/splitter-panel.js +3 -4
- package/es/splitter/splitter.js +77 -219
- package/es/stat-card/countup.js +46 -141
- package/es/stat-card/rollup.js +27 -105
- package/es/stat-card/stat-card.js +3 -4
- package/es/stat-card/stat-number.js +26 -113
- package/es/stat-card/utils/countup.js +2 -3
- package/es/stat-card/utils/odometer.js +2 -3
- package/es/stat-card/utils/stat-item-key.js +2 -3
- package/es/steps/index.js +45 -123
- package/es/switch/index.js +4 -5
- package/es/table/column-setting.js +43 -139
- package/es/table/index.js +25 -15
- package/es/table/utils.js +3 -5
- package/es/tabs/tab-panel.js +19 -71
- package/es/tabs/tabs.js +6 -7
- package/es/tag/index.js +4 -5
- package/es/time-line/timeline-item.js +3 -4
- package/es/time-line/timeline.js +8 -44
- package/es/tooltip/index.js +41 -142
- package/es/tour/index.js +138 -356
- package/es/transfer/index.js +184 -487
- package/es/tree/index.js +8 -9
- package/es/tree/utils.js +2 -3
- package/es/tree-select/index.js +8 -9
- package/es/typography/index.js +75 -306
- package/es/upload/file-list.js +95 -119
- package/es/upload/index.js +8 -9
- package/es/upload/picture-sort.js +2 -3
- package/es/upload/selector.js +63 -193
- package/es/utils/checked.js +2 -3
- package/es/utils/color.js +2 -3
- package/es/utils/css.js +2 -3
- package/es/utils/focus.js +2 -3
- package/es/utils/number.js +2 -3
- package/es/utils/overlay-order.js +2 -3
- package/es/utils/overlay-stack.js +3 -4
- package/es/utils/placement.js +16 -4
- package/es/utils/popup-arrow.js +45 -0
- package/es/utils/popup.js +2 -3
- package/es/utils/promise.js +2 -3
- package/es/utils/react-node.js +2 -3
- package/es/utils/selection-tags.js +2 -3
- package/es/utils/share.js +2 -3
- package/es/utils/theme.js +2 -3
- package/es/utils/transition.js +2 -3
- package/es/utils/use-value.js +3 -4
- package/es/virtual-list/index.js +49 -187
- package/es/virtual-list/range.js +2 -3
- package/es/watermark/index.js +149 -289
- package/lib/index.cjs +2 -2
- package/lib/locale/de.cjs +1 -1
- package/lib/locale/el.cjs +1 -1
- package/lib/locale/en.cjs +1 -1
- package/lib/locale/fr.cjs +1 -1
- package/lib/locale/it.cjs +1 -1
- package/lib/locale/ja.cjs +1 -1
- package/lib/locale/ko.cjs +1 -1
- package/lib/locale/ru.cjs +1 -1
- package/lib/locale/th.cjs +1 -1
- package/lib/locale/uk.cjs +1 -1
- package/lib/locale/vi.cjs +1 -1
- package/lib/locale/zh-CN.cjs +1 -1
- package/lib/locale/zh-TW.cjs +1 -1
- package/package.json +24 -24
- package/style/base.css +1 -1
- package/style/components.css +2 -2
- package/style/index.css +2 -2
- package/style/theme.css +1 -1
- package/types/affix/index.d.cts +1 -1
- package/types/affix/index.d.ts +1 -1
- package/types/anchor/anchor-link.d.cts +1 -1
- package/types/anchor/anchor-link.d.ts +1 -1
- package/types/anchor/anchor.d.cts +1 -1
- package/types/anchor/anchor.d.ts +1 -1
- package/types/back-top/index.d.cts +1 -1
- package/types/back-top/index.d.ts +1 -1
- package/types/carousel/carousel-item.d.cts +1 -1
- package/types/carousel/carousel-item.d.ts +1 -1
- package/types/cascader/index.d.cts +1 -1
- package/types/cascader/index.d.ts +1 -1
- package/types/color-picker/alpha.d.cts +1 -1
- package/types/color-picker/alpha.d.ts +1 -1
- package/types/color-picker/hue.d.cts +1 -1
- package/types/color-picker/hue.d.ts +1 -1
- package/types/color-picker/index.d.cts +3 -2
- package/types/color-picker/index.d.ts +3 -2
- package/types/color-picker/mode.d.cts +1 -1
- package/types/color-picker/mode.d.ts +1 -1
- package/types/color-picker/paint.d.cts +1 -1
- package/types/color-picker/paint.d.ts +1 -1
- package/types/color-picker/presets.d.cts +1 -1
- package/types/color-picker/presets.d.ts +1 -1
- package/types/components.d.cts +3 -0
- package/types/components.d.ts +3 -0
- package/types/date-picker/index.d.cts +2 -2
- package/types/date-picker/index.d.ts +2 -2
- package/types/feature-card/index.d.cts +1 -1
- package/types/feature-card/index.d.ts +1 -1
- package/types/feedback-panel/index.d.cts +1 -1
- package/types/feedback-panel/index.d.ts +1 -1
- package/types/flame-wrap/index.d.cts +1 -1
- package/types/flame-wrap/index.d.ts +1 -1
- package/types/form/form-item.d.cts +1 -1
- package/types/form/form-item.d.ts +1 -1
- package/types/gradient-picker/corners.d.cts +8 -0
- package/types/gradient-picker/corners.d.ts +8 -0
- package/types/gradient-picker/index.d.cts +25 -0
- package/types/gradient-picker/index.d.ts +25 -0
- package/types/gradient-picker/stops.d.cts +12 -0
- package/types/gradient-picker/stops.d.ts +12 -0
- package/types/gradient-picker/types.d.cts +34 -0
- package/types/gradient-picker/types.d.ts +34 -0
- package/types/grid/grid-item.d.cts +1 -1
- package/types/grid/grid-item.d.ts +1 -1
- package/types/grid/grid.d.cts +1 -1
- package/types/grid/grid.d.ts +1 -1
- package/types/image/group.d.cts +1 -1
- package/types/image/group.d.ts +1 -1
- package/types/input-number/drag.d.cts +9 -0
- package/types/input-number/drag.d.ts +9 -0
- package/types/input-number/index.d.cts +1 -0
- package/types/input-number/index.d.ts +1 -0
- package/types/kanban/index.d.cts +1 -1
- package/types/kanban/index.d.ts +1 -1
- package/types/list-panel/index.d.cts +1 -1
- package/types/list-panel/index.d.ts +1 -1
- package/types/loading/loading-bar.d.cts +1 -1
- package/types/loading/loading-bar.d.ts +1 -1
- package/types/modal/toast.d.cts +1 -1
- package/types/modal/toast.d.ts +1 -1
- package/types/notice/content.d.cts +2 -2
- package/types/notice/content.d.ts +2 -2
- package/types/page-header/index.d.cts +1 -1
- package/types/page-header/index.d.ts +1 -1
- package/types/popconfirm/index.d.cts +1 -0
- package/types/popconfirm/index.d.ts +1 -0
- package/types/poptip/index.d.cts +1 -0
- package/types/poptip/index.d.ts +1 -0
- package/types/popup/index.d.cts +1 -0
- package/types/popup/index.d.ts +1 -0
- package/types/result/index.d.cts +1 -1
- package/types/result/index.d.ts +1 -1
- package/types/ripple/index.d.cts +1 -1
- package/types/ripple/index.d.ts +1 -1
- package/types/segmented/index.d.cts +2 -1
- package/types/segmented/index.d.ts +2 -1
- package/types/slider/index.d.cts +1 -1
- package/types/slider/index.d.ts +1 -1
- package/types/splitter/splitter-panel.d.cts +1 -1
- package/types/splitter/splitter-panel.d.ts +1 -1
- package/types/splitter/splitter.d.cts +1 -1
- package/types/splitter/splitter.d.ts +1 -1
- package/types/stat-card/countup.d.cts +1 -1
- package/types/stat-card/countup.d.ts +1 -1
- package/types/stat-card/rollup.d.cts +1 -1
- package/types/stat-card/rollup.d.ts +1 -1
- package/types/stat-card/stat-card.d.cts +1 -1
- package/types/stat-card/stat-card.d.ts +1 -1
- package/types/stat-card/stat-number.d.cts +1 -1
- package/types/stat-card/stat-number.d.ts +1 -1
- package/types/table/column-setting.d.cts +1 -1
- package/types/table/column-setting.d.ts +1 -1
- package/types/table/index.d.cts +1 -1
- package/types/table/index.d.ts +1 -1
- package/types/time-line/timeline-item.d.cts +1 -1
- package/types/time-line/timeline-item.d.ts +1 -1
- package/types/time-line/timeline.d.cts +1 -1
- package/types/time-line/timeline.d.ts +1 -1
- package/types/tooltip/index.d.cts +1 -0
- package/types/tooltip/index.d.ts +1 -0
- package/types/transfer/index.d.cts +1 -1
- package/types/transfer/index.d.ts +1 -1
- package/types/tree-select/index.d.cts +1 -1
- package/types/tree-select/index.d.ts +1 -1
- package/types/upload/file-list.d.cts +1 -1
- package/types/upload/file-list.d.ts +1 -1
- package/types/upload/selector.d.cts +1 -1
- package/types/upload/selector.d.ts +1 -1
- package/types/utils/placement.d.cts +2 -1
- package/types/utils/placement.d.ts +2 -1
- package/types/utils/popup-arrow.d.cts +5 -0
- package/types/utils/popup-arrow.d.ts +5 -0
- package/types/utils/selection-tags.d.cts +1 -1
- package/types/utils/selection-tags.d.ts +1 -1
- package/types/watermark/index.d.cts +1 -1
- package/types/watermark/index.d.ts +1 -1
package/es/grid/grid.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/*!
|
|
2
|
-
* react-kui v3.
|
|
2
|
+
* react-kui v3.3.0
|
|
3
3
|
* Copyright 2017-present, kui-react.
|
|
4
4
|
* All rights reserved.
|
|
5
5
|
* Homepage: https://react.k-ui.cn
|
|
@@ -7,11 +7,10 @@
|
|
|
7
7
|
*/
|
|
8
8
|
|
|
9
9
|
import { GridContext, useBreakpoint } from "./useBreakpoint.js";
|
|
10
|
-
import { c } from "react/compiler-runtime";
|
|
11
10
|
import clsx from "clsx";
|
|
12
|
-
import { useRef } from "react";
|
|
11
|
+
import { useCallback, useMemo, useRef } from "react";
|
|
13
12
|
import { jsx } from "react/jsx-runtime";
|
|
14
|
-
|
|
13
|
+
// components/grid/grid.tsx
|
|
15
14
|
var order = [
|
|
16
15
|
"xxl",
|
|
17
16
|
"xl",
|
|
@@ -20,158 +19,48 @@ var order = [
|
|
|
20
19
|
"sm",
|
|
21
20
|
"xs"
|
|
22
21
|
];
|
|
23
|
-
function Grid(
|
|
24
|
-
const $ = c(43);
|
|
25
|
-
let align;
|
|
26
|
-
let children;
|
|
27
|
-
let className;
|
|
28
|
-
let itemMinWidth;
|
|
29
|
-
let justify;
|
|
30
|
-
let rest;
|
|
31
|
-
let style;
|
|
32
|
-
let t1;
|
|
33
|
-
let t2;
|
|
34
|
-
let t3;
|
|
35
|
-
let t4;
|
|
36
|
-
let t5;
|
|
37
|
-
let t6;
|
|
38
|
-
let t7;
|
|
39
|
-
if ($[0] !== t0) {
|
|
40
|
-
({cols: t1, rows: t2, autoRows: t3, xGap: t4, yGap: t5, itemMinWidth, align, justify, flow: t6, debug: t7, className, style, children, ...rest} = t0);
|
|
41
|
-
$[0] = t0;
|
|
42
|
-
$[1] = align;
|
|
43
|
-
$[2] = children;
|
|
44
|
-
$[3] = className;
|
|
45
|
-
$[4] = itemMinWidth;
|
|
46
|
-
$[5] = justify;
|
|
47
|
-
$[6] = rest;
|
|
48
|
-
$[7] = style;
|
|
49
|
-
$[8] = t1;
|
|
50
|
-
$[9] = t2;
|
|
51
|
-
$[10] = t3;
|
|
52
|
-
$[11] = t4;
|
|
53
|
-
$[12] = t5;
|
|
54
|
-
$[13] = t6;
|
|
55
|
-
$[14] = t7;
|
|
56
|
-
} else {
|
|
57
|
-
align = $[1];
|
|
58
|
-
children = $[2];
|
|
59
|
-
className = $[3];
|
|
60
|
-
itemMinWidth = $[4];
|
|
61
|
-
justify = $[5];
|
|
62
|
-
rest = $[6];
|
|
63
|
-
style = $[7];
|
|
64
|
-
t1 = $[8];
|
|
65
|
-
t2 = $[9];
|
|
66
|
-
t3 = $[10];
|
|
67
|
-
t4 = $[11];
|
|
68
|
-
t5 = $[12];
|
|
69
|
-
t6 = $[13];
|
|
70
|
-
t7 = $[14];
|
|
71
|
-
}
|
|
72
|
-
const cols = t1 === void 0 ? 24 : t1;
|
|
73
|
-
const rows = t2 === void 0 ? "auto" : t2;
|
|
74
|
-
const autoRows = t3 === void 0 ? "auto" : t3;
|
|
75
|
-
const xGap = t4 === void 0 ? 0 : t4;
|
|
76
|
-
const yGap = t5 === void 0 ? 0 : t5;
|
|
77
|
-
const flow = t6 === void 0 ? "row" : t6;
|
|
78
|
-
const debug = t7 === void 0 ? false : t7;
|
|
22
|
+
function Grid({ cols = 24, rows = "auto", autoRows = "auto", xGap = 0, yGap = 0, itemMinWidth, align, justify, flow = "row", debug = false, className, style, children, ...rest }) {
|
|
79
23
|
const gridRef = useRef(null);
|
|
80
24
|
const breakpoint = useBreakpoint(gridRef);
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
const
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
Object.assign(gridStyle, style);
|
|
115
|
-
$[17] = align;
|
|
116
|
-
$[18] = autoRows;
|
|
117
|
-
$[19] = cols;
|
|
118
|
-
$[20] = debug;
|
|
119
|
-
$[21] = flow;
|
|
120
|
-
$[22] = itemMinWidth;
|
|
121
|
-
$[23] = justify;
|
|
122
|
-
$[24] = resolveResponsive;
|
|
123
|
-
$[25] = rows;
|
|
124
|
-
$[26] = style;
|
|
125
|
-
$[27] = xGap;
|
|
126
|
-
$[28] = yGap;
|
|
127
|
-
$[29] = gridStyle;
|
|
128
|
-
} else gridStyle = $[29];
|
|
129
|
-
let t9;
|
|
130
|
-
if ($[30] !== breakpoint || $[31] !== resolveResponsive) {
|
|
131
|
-
t9 = {
|
|
132
|
-
breakpoint,
|
|
133
|
-
resolveResponsive
|
|
134
|
-
};
|
|
135
|
-
$[30] = breakpoint;
|
|
136
|
-
$[31] = resolveResponsive;
|
|
137
|
-
$[32] = t9;
|
|
138
|
-
} else t9 = $[32];
|
|
139
|
-
const context = t9;
|
|
140
|
-
let t10;
|
|
141
|
-
if ($[33] !== className) {
|
|
142
|
-
t10 = clsx("k-grid", className);
|
|
143
|
-
$[33] = className;
|
|
144
|
-
$[34] = t10;
|
|
145
|
-
} else t10 = $[34];
|
|
146
|
-
let t11;
|
|
147
|
-
if ($[35] !== children || $[36] !== gridStyle || $[37] !== rest || $[38] !== t10) {
|
|
148
|
-
t11 = /* @__PURE__ */ jsx("div", {
|
|
25
|
+
const resolveResponsive = useCallback((value, fallback) => {
|
|
26
|
+
if (value === void 0) return fallback;
|
|
27
|
+
if (typeof value !== "object" || value === null) return value;
|
|
28
|
+
const responsive = value;
|
|
29
|
+
const current = order.indexOf(breakpoint);
|
|
30
|
+
for (let index = current; index < order.length; index++) {
|
|
31
|
+
const candidate = responsive[order[index]];
|
|
32
|
+
if (candidate !== void 0) return candidate;
|
|
33
|
+
}
|
|
34
|
+
return fallback;
|
|
35
|
+
}, [breakpoint]);
|
|
36
|
+
const activeCols = resolveResponsive(cols, 24);
|
|
37
|
+
const activeRows = resolveResponsive(rows, "auto");
|
|
38
|
+
const parseGap = (value_0) => typeof value_0 === "number" ? `${value_0}px` : value_0;
|
|
39
|
+
const gridStyle = {
|
|
40
|
+
gridTemplateColumns: itemMinWidth ? `repeat(auto-fill, minmax(min(100%, ${typeof itemMinWidth === "number" ? `${itemMinWidth}px` : itemMinWidth}), 1fr))` : typeof activeCols === "number" ? `repeat(${activeCols}, minmax(0, 1fr))` : activeCols,
|
|
41
|
+
gridTemplateRows: typeof activeRows === "number" ? `repeat(${activeRows}, minmax(0, 1fr))` : activeRows,
|
|
42
|
+
columnGap: parseGap(resolveResponsive(xGap, 0)),
|
|
43
|
+
rowGap: parseGap(resolveResponsive(yGap, 0)),
|
|
44
|
+
gridAutoRows: autoRows,
|
|
45
|
+
alignItems: align,
|
|
46
|
+
justifyItems: justify,
|
|
47
|
+
gridAutoFlow: flow
|
|
48
|
+
};
|
|
49
|
+
if (debug && typeof activeCols === "number") gridStyle.backgroundImage = `repeating-linear-gradient(to right, rgba(255,0,0,.05) 0, rgba(255,0,0,.05) ${100 / activeCols}%, transparent ${100 / activeCols}%, transparent ${200 / activeCols}%)`;
|
|
50
|
+
Object.assign(gridStyle, style);
|
|
51
|
+
const context = useMemo(() => ({
|
|
52
|
+
breakpoint,
|
|
53
|
+
resolveResponsive
|
|
54
|
+
}), [breakpoint, resolveResponsive]);
|
|
55
|
+
return /* @__PURE__ */ jsx(GridContext.Provider, {
|
|
56
|
+
value: context,
|
|
57
|
+
children: /* @__PURE__ */ jsx("div", {
|
|
149
58
|
...rest,
|
|
150
59
|
ref: gridRef,
|
|
151
|
-
className:
|
|
60
|
+
className: clsx("k-grid", className),
|
|
152
61
|
style: gridStyle,
|
|
153
62
|
children
|
|
154
|
-
})
|
|
155
|
-
|
|
156
|
-
$[36] = gridStyle;
|
|
157
|
-
$[37] = rest;
|
|
158
|
-
$[38] = t10;
|
|
159
|
-
$[39] = t11;
|
|
160
|
-
} else t11 = $[39];
|
|
161
|
-
let t12;
|
|
162
|
-
if ($[40] !== context || $[41] !== t11) {
|
|
163
|
-
t12 = /* @__PURE__ */ jsx(GridContext.Provider, {
|
|
164
|
-
value: context,
|
|
165
|
-
children: t11
|
|
166
|
-
});
|
|
167
|
-
$[40] = context;
|
|
168
|
-
$[41] = t11;
|
|
169
|
-
$[42] = t12;
|
|
170
|
-
} else t12 = $[42];
|
|
171
|
-
return t12;
|
|
63
|
+
})
|
|
64
|
+
});
|
|
172
65
|
}
|
|
173
|
-
function _temp(value_0) {
|
|
174
|
-
return typeof value_0 === "number" ? `${value_0}px` : value_0;
|
|
175
|
-
}
|
|
176
|
-
//#endregion
|
|
177
66
|
export { Grid as default };
|
package/es/grid/useBreakpoint.js
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
/*!
|
|
2
|
-
* react-kui v3.
|
|
2
|
+
* react-kui v3.3.0
|
|
3
3
|
* Copyright 2017-present, kui-react.
|
|
4
4
|
* All rights reserved.
|
|
5
5
|
* Homepage: https://react.k-ui.cn
|
|
6
6
|
* Author: Qiu / https://chuchur.com
|
|
7
7
|
*/
|
|
8
8
|
|
|
9
|
-
import { c } from "react/compiler-runtime";
|
|
10
9
|
import { createContext, useLayoutEffect, useState } from "react";
|
|
11
|
-
|
|
10
|
+
import { c } from "react/compiler-runtime";
|
|
11
|
+
// components/grid/useBreakpoint.ts
|
|
12
12
|
var breakpointMap = [
|
|
13
13
|
[1600, "xxl"],
|
|
14
14
|
[1200, "xl"],
|
|
@@ -60,5 +60,4 @@ function useBreakpoint(elementRef) {
|
|
|
60
60
|
useLayoutEffect(t0, t1);
|
|
61
61
|
return active;
|
|
62
62
|
}
|
|
63
|
-
//#endregion
|
|
64
63
|
export { GridContext, useBreakpoint };
|
package/es/icon/index.js
CHANGED
|
@@ -1,16 +1,15 @@
|
|
|
1
1
|
/*!
|
|
2
|
-
* react-kui v3.
|
|
2
|
+
* react-kui v3.3.0
|
|
3
3
|
* Copyright 2017-present, kui-react.
|
|
4
4
|
* All rights reserved.
|
|
5
5
|
* Homepage: https://react.k-ui.cn
|
|
6
6
|
* Author: Qiu / https://chuchur.com
|
|
7
7
|
*/
|
|
8
8
|
|
|
9
|
-
import { c } from "react/compiler-runtime";
|
|
10
9
|
import clsx from "clsx";
|
|
11
10
|
import { forwardRef } from "react";
|
|
12
11
|
import { jsx } from "react/jsx-runtime";
|
|
13
|
-
|
|
12
|
+
// components/icon/index.tsx
|
|
14
13
|
var parseStyle = (styleString = "") => {
|
|
15
14
|
const styles = {};
|
|
16
15
|
for (const rule of styleString.split(";")) {
|
|
@@ -22,86 +21,25 @@ var parseStyle = (styleString = "") => {
|
|
|
22
21
|
}
|
|
23
22
|
return styles;
|
|
24
23
|
};
|
|
25
|
-
var Icon = forwardRef(function Icon(
|
|
26
|
-
const
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
$[5] = size;
|
|
45
|
-
$[6] = style;
|
|
46
|
-
$[7] = t1;
|
|
47
|
-
$[8] = t2;
|
|
48
|
-
$[9] = t3;
|
|
49
|
-
$[10] = t4;
|
|
50
|
-
} else {
|
|
51
|
-
className = $[1];
|
|
52
|
-
color = $[2];
|
|
53
|
-
onClick = $[3];
|
|
54
|
-
rest = $[4];
|
|
55
|
-
size = $[5];
|
|
56
|
-
style = $[6];
|
|
57
|
-
t1 = $[7];
|
|
58
|
-
t2 = $[8];
|
|
59
|
-
t3 = $[9];
|
|
60
|
-
t4 = $[10];
|
|
61
|
-
}
|
|
62
|
-
let t5;
|
|
63
|
-
if ($[11] !== t1) {
|
|
64
|
-
t5 = t1 === void 0 ? [] : t1;
|
|
65
|
-
$[11] = t1;
|
|
66
|
-
$[12] = t5;
|
|
67
|
-
} else t5 = $[12];
|
|
68
|
-
const type = t5;
|
|
69
|
-
const spin = t2 === void 0 ? false : t2;
|
|
70
|
-
const strokeWidth = t3 === void 0 ? 2 : t3;
|
|
71
|
-
const reverseFill = t4 === void 0 ? false : t4;
|
|
72
|
-
const t6 = size === void 0 ? void 0 : typeof size === "number" ? `${size}px` : size;
|
|
73
|
-
let t7;
|
|
74
|
-
if ($[13] !== color || $[14] !== style || $[15] !== t6) {
|
|
75
|
-
t7 = {
|
|
76
|
-
...style,
|
|
77
|
-
color,
|
|
78
|
-
fontSize: t6
|
|
79
|
-
};
|
|
80
|
-
$[13] = color;
|
|
81
|
-
$[14] = style;
|
|
82
|
-
$[15] = t6;
|
|
83
|
-
$[16] = t7;
|
|
84
|
-
} else t7 = $[16];
|
|
85
|
-
const iconStyle = t7;
|
|
86
|
-
let t8;
|
|
87
|
-
if ($[17] !== onClick) {
|
|
88
|
-
t8 = (event) => onClick?.(event);
|
|
89
|
-
$[17] = onClick;
|
|
90
|
-
$[18] = t8;
|
|
91
|
-
} else t8 = $[18];
|
|
92
|
-
const handleClick = t8;
|
|
93
|
-
let t9;
|
|
94
|
-
if ($[19] !== className || $[20] !== spin) {
|
|
95
|
-
t9 = clsx("k-icon", { "k-load-loop": spin }, className);
|
|
96
|
-
$[19] = className;
|
|
97
|
-
$[20] = spin;
|
|
98
|
-
$[21] = t9;
|
|
99
|
-
} else t9 = $[21];
|
|
100
|
-
let t10;
|
|
101
|
-
if ($[22] !== reverseFill || $[23] !== strokeWidth || $[24] !== type) {
|
|
102
|
-
let t11;
|
|
103
|
-
if ($[26] !== reverseFill || $[27] !== strokeWidth) {
|
|
104
|
-
t11 = (item, index) => {
|
|
24
|
+
var Icon = forwardRef(function Icon({ type = [], size, color, spin = false, strokeWidth = 2, reverseFill = false, className, style, onClick, ...rest }, ref) {
|
|
25
|
+
const iconStyle = {
|
|
26
|
+
...style,
|
|
27
|
+
color,
|
|
28
|
+
fontSize: size === void 0 ? void 0 : typeof size === "number" ? `${size}px` : size
|
|
29
|
+
};
|
|
30
|
+
const handleClick = (event) => onClick?.(event);
|
|
31
|
+
return /* @__PURE__ */ jsx("i", {
|
|
32
|
+
...rest,
|
|
33
|
+
ref,
|
|
34
|
+
className: clsx("k-icon", { "k-load-loop": spin }, className),
|
|
35
|
+
style: iconStyle,
|
|
36
|
+
onClick: handleClick,
|
|
37
|
+
children: /* @__PURE__ */ jsx("svg", {
|
|
38
|
+
viewBox: "0 0 24 24",
|
|
39
|
+
width: "1em",
|
|
40
|
+
height: "1em",
|
|
41
|
+
"aria-hidden": "true",
|
|
42
|
+
children: type.map((item, index) => {
|
|
105
43
|
const pathStyle = parseStyle(item.s);
|
|
106
44
|
if (reverseFill && pathStyle.stroke === "currentcolor" && pathStyle.fill === "none") {
|
|
107
45
|
pathStyle.fill = "currentColor";
|
|
@@ -114,48 +52,8 @@ var Icon = forwardRef(function Icon(t0, ref) {
|
|
|
114
52
|
strokeWidth
|
|
115
53
|
}
|
|
116
54
|
}, `${item.d}-${index}`);
|
|
117
|
-
}
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
$[28] = t11;
|
|
121
|
-
} else t11 = $[28];
|
|
122
|
-
t10 = type.map(t11);
|
|
123
|
-
$[22] = reverseFill;
|
|
124
|
-
$[23] = strokeWidth;
|
|
125
|
-
$[24] = type;
|
|
126
|
-
$[25] = t10;
|
|
127
|
-
} else t10 = $[25];
|
|
128
|
-
let t11;
|
|
129
|
-
if ($[29] !== t10) {
|
|
130
|
-
t11 = /* @__PURE__ */ jsx("svg", {
|
|
131
|
-
viewBox: "0 0 24 24",
|
|
132
|
-
width: "1em",
|
|
133
|
-
height: "1em",
|
|
134
|
-
"aria-hidden": "true",
|
|
135
|
-
children: t10
|
|
136
|
-
});
|
|
137
|
-
$[29] = t10;
|
|
138
|
-
$[30] = t11;
|
|
139
|
-
} else t11 = $[30];
|
|
140
|
-
let t12;
|
|
141
|
-
if ($[31] !== handleClick || $[32] !== iconStyle || $[33] !== ref || $[34] !== rest || $[35] !== t11 || $[36] !== t9) {
|
|
142
|
-
t12 = /* @__PURE__ */ jsx("i", {
|
|
143
|
-
...rest,
|
|
144
|
-
ref,
|
|
145
|
-
className: t9,
|
|
146
|
-
style: iconStyle,
|
|
147
|
-
onClick: handleClick,
|
|
148
|
-
children: t11
|
|
149
|
-
});
|
|
150
|
-
$[31] = handleClick;
|
|
151
|
-
$[32] = iconStyle;
|
|
152
|
-
$[33] = ref;
|
|
153
|
-
$[34] = rest;
|
|
154
|
-
$[35] = t11;
|
|
155
|
-
$[36] = t9;
|
|
156
|
-
$[37] = t12;
|
|
157
|
-
} else t12 = $[37];
|
|
158
|
-
return t12;
|
|
55
|
+
})
|
|
56
|
+
})
|
|
57
|
+
});
|
|
159
58
|
});
|
|
160
|
-
//#endregion
|
|
161
59
|
export { Icon as default };
|
package/es/image/group.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/*!
|
|
2
|
-
* react-kui v3.
|
|
2
|
+
* react-kui v3.3.0
|
|
3
3
|
* Copyright 2017-present, kui-react.
|
|
4
4
|
* All rights reserved.
|
|
5
5
|
* Homepage: https://react.k-ui.cn
|
|
@@ -8,11 +8,11 @@
|
|
|
8
8
|
|
|
9
9
|
import createInstance from "./instance.js";
|
|
10
10
|
import { ImageGroupContext } from "./image-group-context.js";
|
|
11
|
-
import { c } from "react/compiler-runtime";
|
|
12
11
|
import clsx from "clsx";
|
|
13
12
|
import { useEffect, useRef } from "react";
|
|
14
13
|
import { jsx } from "react/jsx-runtime";
|
|
15
|
-
|
|
14
|
+
import { c } from "react/compiler-runtime";
|
|
15
|
+
// components/image/group.tsx
|
|
16
16
|
function ImageGroup(t0) {
|
|
17
17
|
const $ = c(18);
|
|
18
18
|
let children;
|
|
@@ -117,5 +117,4 @@ function ImageGroup(t0) {
|
|
|
117
117
|
} else t8 = $[17];
|
|
118
118
|
return t8;
|
|
119
119
|
}
|
|
120
|
-
//#endregion
|
|
121
120
|
export { ImageGroup as default };
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/*!
|
|
2
|
-
* react-kui v3.
|
|
2
|
+
* react-kui v3.3.0
|
|
3
3
|
* Copyright 2017-present, kui-react.
|
|
4
4
|
* All rights reserved.
|
|
5
5
|
* Homepage: https://react.k-ui.cn
|
|
@@ -7,7 +7,6 @@
|
|
|
7
7
|
*/
|
|
8
8
|
|
|
9
9
|
import { createContext } from "react";
|
|
10
|
-
|
|
10
|
+
// components/image/image-group-context.ts
|
|
11
11
|
var ImageGroupContext = createContext(null);
|
|
12
|
-
//#endregion
|
|
13
12
|
export { ImageGroupContext };
|
package/es/image/image.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/*!
|
|
2
|
-
* react-kui v3.
|
|
2
|
+
* react-kui v3.3.0
|
|
3
3
|
* Copyright 2017-present, kui-react.
|
|
4
4
|
* All rights reserved.
|
|
5
5
|
* Homepage: https://react.k-ui.cn
|
|
@@ -9,14 +9,14 @@
|
|
|
9
9
|
import { resolvePaintedTheme, useConfigAppearance } from "../config/use-config-appearance.js";
|
|
10
10
|
import { Image, Loading } from "../node_modules/.pnpm/kui-icons@5.0.0/node_modules/kui-icons/dist/kui-icons.esm.js";
|
|
11
11
|
import Icon from "../icon/index.js";
|
|
12
|
-
import { loadImage } from "./utils.js";
|
|
13
|
-
import createInstance from "./instance.js";
|
|
14
12
|
import { ImageGroupContext } from "./image-group-context.js";
|
|
15
|
-
import
|
|
13
|
+
import createInstance from "./instance.js";
|
|
14
|
+
import { loadImage } from "./utils.js";
|
|
16
15
|
import clsx from "clsx";
|
|
17
16
|
import { forwardRef, useContext, useEffect, useImperativeHandle, useRef, useState } from "react";
|
|
18
17
|
import { jsx, jsxs } from "react/jsx-runtime";
|
|
19
|
-
|
|
18
|
+
import { c } from "react/compiler-runtime";
|
|
19
|
+
// components/image/image.tsx
|
|
20
20
|
var PAINTED_THEMES = [
|
|
21
21
|
"fill",
|
|
22
22
|
"outline",
|
|
@@ -324,5 +324,4 @@ var KImage = forwardRef(function KImage(t0, ref) {
|
|
|
324
324
|
function _temp(value) {
|
|
325
325
|
return typeof value === "number" ? `${value}px` : value;
|
|
326
326
|
}
|
|
327
|
-
//#endregion
|
|
328
327
|
export { KImage as default };
|
package/es/image/instance.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/*!
|
|
2
|
-
* react-kui v3.
|
|
2
|
+
* react-kui v3.3.0
|
|
3
3
|
* Copyright 2017-present, kui-react.
|
|
4
4
|
* All rights reserved.
|
|
5
5
|
* Homepage: https://react.k-ui.cn
|
|
@@ -9,7 +9,7 @@
|
|
|
9
9
|
import ImagePreview from "./preview.js";
|
|
10
10
|
import { jsx } from "react/jsx-runtime";
|
|
11
11
|
import { createRoot } from "react-dom/client";
|
|
12
|
-
|
|
12
|
+
// components/image/instance.tsx
|
|
13
13
|
function createInstance(props = {}) {
|
|
14
14
|
const container = document.createElement("div");
|
|
15
15
|
container.id = "k-image-preview-box";
|
|
@@ -43,5 +43,4 @@ function createInstance(props = {}) {
|
|
|
43
43
|
}
|
|
44
44
|
};
|
|
45
45
|
}
|
|
46
|
-
//#endregion
|
|
47
46
|
export { createInstance as default };
|
package/es/image/preview.js
CHANGED
|
@@ -1,21 +1,21 @@
|
|
|
1
1
|
/*!
|
|
2
|
-
* react-kui v3.
|
|
2
|
+
* react-kui v3.3.0
|
|
3
3
|
* Copyright 2017-present, kui-react.
|
|
4
4
|
* All rights reserved.
|
|
5
5
|
* Homepage: https://react.k-ui.cn
|
|
6
6
|
* Author: Qiu / https://chuchur.com
|
|
7
7
|
*/
|
|
8
8
|
|
|
9
|
-
import { Transition } from "../base/transition.js";
|
|
10
9
|
import { ArrowDown, ArrowLeft, ArrowRight, ChevronLeft, ChevronRight, Image, Loading, Minus, Plus, RotateCcwSquare, RotateCwSquare, X } from "../node_modules/.pnpm/kui-icons@5.0.0/node_modules/kui-icons/dist/kui-icons.esm.js";
|
|
11
|
-
import Icon from "../icon/index.js";
|
|
12
10
|
import Button from "../button/button.js";
|
|
11
|
+
import Icon from "../icon/index.js";
|
|
13
12
|
import slider_default from "../slider/index.js";
|
|
13
|
+
import { Transition } from "../base/transition.js";
|
|
14
14
|
import { loadImage } from "./utils.js";
|
|
15
15
|
import clsx from "clsx";
|
|
16
16
|
import { forwardRef, useCallback, useEffect, useImperativeHandle, useLayoutEffect, useRef, useState } from "react";
|
|
17
17
|
import { Fragment as Fragment$1, jsx, jsxs } from "react/jsx-runtime";
|
|
18
|
-
|
|
18
|
+
// components/image/preview.tsx
|
|
19
19
|
var ImagePreview = forwardRef(function ImagePreview(initial, ref) {
|
|
20
20
|
const [options, setOptions] = useState(initial);
|
|
21
21
|
const [visible, setVisible] = useState(true);
|
|
@@ -379,5 +379,4 @@ var ImagePreview = forwardRef(function ImagePreview(initial, ref) {
|
|
|
379
379
|
})
|
|
380
380
|
});
|
|
381
381
|
});
|
|
382
|
-
//#endregion
|
|
383
382
|
export { ImagePreview as default };
|
package/es/image/utils.js
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
/*!
|
|
2
|
-
* react-kui v3.
|
|
2
|
+
* react-kui v3.3.0
|
|
3
3
|
* Copyright 2017-present, kui-react.
|
|
4
4
|
* All rights reserved.
|
|
5
5
|
* Homepage: https://react.k-ui.cn
|
|
6
6
|
* Author: Qiu / https://chuchur.com
|
|
7
7
|
*/
|
|
8
8
|
|
|
9
|
-
|
|
9
|
+
// components/image/utils.ts
|
|
10
10
|
var loadImage = (src, callback, err) => {
|
|
11
11
|
if (!src) return () => {};
|
|
12
12
|
let image = new Image();
|
|
@@ -35,5 +35,4 @@ var loadImage = (src, callback, err) => {
|
|
|
35
35
|
image.src = src;
|
|
36
36
|
return cleanup;
|
|
37
37
|
};
|
|
38
|
-
//#endregion
|
|
39
38
|
export { loadImage };
|
package/es/index.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/*!
|
|
2
|
-
* react-kui v3.
|
|
2
|
+
* react-kui v3.3.0
|
|
3
3
|
* Copyright 2017-present, kui-react.
|
|
4
4
|
* All rights reserved.
|
|
5
5
|
* Homepage: https://react.k-ui.cn
|
|
@@ -46,6 +46,8 @@ import { getVirtualRange } from "./virtual-list/range.js";
|
|
|
46
46
|
import VirtualList from "./virtual-list/index.js";
|
|
47
47
|
import select_default from "./select/select.js";
|
|
48
48
|
import color_picker_default, { ColorPickerPanel } from "./color-picker/index.js";
|
|
49
|
+
import { createCornerGradient, createLinearGradient, formatGradient } from "./gradient-picker/types.js";
|
|
50
|
+
import gradient_picker_default from "./gradient-picker/index.js";
|
|
49
51
|
import date_picker_default, { DatePickerPanel } from "./date-picker/index.js";
|
|
50
52
|
import Descriptions from "./descriptions/descriptions.js";
|
|
51
53
|
import DescriptionsItem from "./descriptions/descriptions-item.js";
|
|
@@ -123,8 +125,7 @@ import Theme from "./utils/theme.js";
|
|
|
123
125
|
import transfer_default from "./transfer/index.js";
|
|
124
126
|
import Typography, { TypographyParagraph, TypographyText, TypographyTitle } from "./typography/index.js";
|
|
125
127
|
import { components_exports } from "./components.js";
|
|
126
|
-
|
|
128
|
+
// components/index.ts
|
|
127
129
|
var version = void 0;
|
|
128
130
|
var components_default = { version: void 0 };
|
|
129
|
-
|
|
130
|
-
export { Affix, Alert, Anchor, AnchorLink, auto_complete_default as AutoComplete, Avatar, AvatarGroup, BackTop, Badge, Breadcrumb, BreadcrumbItem, Button, ButtonGroup, Calendar, Card, CardMeta, Carousel, CarouselItem, cascader_default as Cascader, check_card_default as CheckCard, check_card_group_default as CheckCardGroup, checkbox_default as Checkbox, checkbox_group_default as CheckboxGroup, Col, Collapse, CollapsePanel, color_picker_default as ColorPicker, ColorPickerPanel, ConfigProvider, Content, date_picker_default as DatePicker, DatePickerPanel, Descriptions, DescriptionsItem, Divider, Drawer, Dropdown, DropdownButton, Empty, FeatureCard, FeedbackPanel, FlameWrap, Flex, Footer, Form, FormItem, Grid, GridItem, Header, Icon, ImageGroup, input_default as Input, input_group_default as InputGroup, input_number_default as InputNumber, input_otp_default as InputOTP, input_tag_default as InputTag, KImage, Kanban, Layout, ListPanel, mentions_default as Mentions, Menu, MenuDivider, MenuGroup, MenuItem, MessagePanel, Modal, ModalPanel, NoticePanel, Option, Page, PageHeader, Popconfirm, PopconfirmPanel, Poptip, PoptipPanel, Popup, Progress, QRCode, radio_default as Radio, radio_button_default as RadioButton, radio_group_default as RadioGroup, rate_default as Rate, Result, Ripple, Row, segmented_default as Segmented, select_default as Select, Sider, Skeleton, SkeletonAvatar, SkeletonButton, SkeletonImage, SkeletonText, slider_default as Slider, Space, Spin, Splitter, SplitterPanel, StatCard, StatNumber, Step, Steps, SubMenu, switch_default as Switch, TabPanel, Table, TableColumnSetting, Tabs, Tag, textarea_default as TextArea, TimeLine, TimeLineItem, Tooltip, TooltipPanel, Tour, transfer_default as Transfer, Tree, tree_select_default as TreeSelect, Typography, TypographyParagraph, TypographyText, TypographyTitle, upload_default as Upload, VirtualList, Watermark, components_exports as components, components_default as default, getVirtualRange, loading, message, modal, notice, Theme as theme, version };
|
|
131
|
+
export { Affix, Alert, Anchor, AnchorLink, auto_complete_default as AutoComplete, Avatar, AvatarGroup, BackTop, Badge, Breadcrumb, BreadcrumbItem, Button, ButtonGroup, Calendar, Card, CardMeta, Carousel, CarouselItem, cascader_default as Cascader, check_card_default as CheckCard, check_card_group_default as CheckCardGroup, checkbox_default as Checkbox, checkbox_group_default as CheckboxGroup, Col, Collapse, CollapsePanel, color_picker_default as ColorPicker, ColorPickerPanel, ConfigProvider, Content, date_picker_default as DatePicker, DatePickerPanel, Descriptions, DescriptionsItem, Divider, Drawer, Dropdown, DropdownButton, Empty, FeatureCard, FeedbackPanel, FlameWrap, Flex, Footer, Form, FormItem, gradient_picker_default as GradientPicker, Grid, GridItem, Header, Icon, ImageGroup, input_default as Input, input_group_default as InputGroup, input_number_default as InputNumber, input_otp_default as InputOTP, input_tag_default as InputTag, KImage, Kanban, Layout, ListPanel, mentions_default as Mentions, Menu, MenuDivider, MenuGroup, MenuItem, MessagePanel, Modal, ModalPanel, NoticePanel, Option, Page, PageHeader, Popconfirm, PopconfirmPanel, Poptip, PoptipPanel, Popup, Progress, QRCode, radio_default as Radio, radio_button_default as RadioButton, radio_group_default as RadioGroup, rate_default as Rate, Result, Ripple, Row, segmented_default as Segmented, select_default as Select, Sider, Skeleton, SkeletonAvatar, SkeletonButton, SkeletonImage, SkeletonText, slider_default as Slider, Space, Spin, Splitter, SplitterPanel, StatCard, StatNumber, Step, Steps, SubMenu, switch_default as Switch, TabPanel, Table, TableColumnSetting, Tabs, Tag, textarea_default as TextArea, TimeLine, TimeLineItem, Tooltip, TooltipPanel, Tour, transfer_default as Transfer, Tree, tree_select_default as TreeSelect, Typography, TypographyParagraph, TypographyText, TypographyTitle, upload_default as Upload, VirtualList, Watermark, components_exports as components, createCornerGradient, createLinearGradient, components_default as default, formatGradient, getVirtualRange, loading, message, modal, notice, Theme as theme, version };
|
package/es/input/index.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/*!
|
|
2
|
-
* react-kui v3.
|
|
2
|
+
* react-kui v3.3.0
|
|
3
3
|
* Copyright 2017-present, kui-react.
|
|
4
4
|
* All rights reserved.
|
|
5
5
|
* Homepage: https://react.k-ui.cn
|
|
@@ -9,7 +9,6 @@
|
|
|
9
9
|
import input_group_default from "./input-group.js";
|
|
10
10
|
import input_default$1 from "./input.js";
|
|
11
11
|
import textarea_default from "./textarea.js";
|
|
12
|
-
|
|
12
|
+
// components/input/index.ts
|
|
13
13
|
var input_default = input_default$1;
|
|
14
|
-
//#endregion
|
|
15
14
|
export { input_default$1 as Input, input_group_default as InputGroup, textarea_default as TextArea, input_default as default };
|
package/es/input/input-base.js
CHANGED
|
@@ -1,23 +1,23 @@
|
|
|
1
1
|
/*!
|
|
2
|
-
* react-kui v3.
|
|
2
|
+
* react-kui v3.3.0
|
|
3
3
|
* Copyright 2017-present, kui-react.
|
|
4
4
|
* All rights reserved.
|
|
5
5
|
* Homepage: https://react.k-ui.cn
|
|
6
6
|
* Author: Qiu / https://chuchur.com
|
|
7
7
|
*/
|
|
8
8
|
|
|
9
|
+
import { useValue } from "../utils/use-value.js";
|
|
9
10
|
import { resolveTheme, useFormAppearance } from "../config/use-config-appearance.js";
|
|
10
11
|
import { CircleX, Eye, EyeOff, Search } from "../node_modules/.pnpm/kui-icons@5.0.0/node_modules/kui-icons/dist/kui-icons.esm.js";
|
|
11
|
-
import Icon from "../icon/index.js";
|
|
12
|
-
import { useValue } from "../utils/use-value.js";
|
|
13
12
|
import { SizeContext } from "../config/size-context.js";
|
|
13
|
+
import Icon from "../icon/index.js";
|
|
14
14
|
import { isEmpty } from "../utils/number.js";
|
|
15
15
|
import InputBox from "./input-box.js";
|
|
16
16
|
import input_group_default from "./input-group.js";
|
|
17
17
|
import clsx from "clsx";
|
|
18
18
|
import React, { useContext, useImperativeHandle, useRef, useState } from "react";
|
|
19
19
|
import { jsx, jsxs } from "react/jsx-runtime";
|
|
20
|
-
|
|
20
|
+
// components/input/input-base.tsx
|
|
21
21
|
/** Shared implementation. Deliberately absent from the public component barrel. */
|
|
22
22
|
var InputBase = React.forwardRef(({ clearable = true, visiblePasswordIcon = true, size: sizeProp, value, disabled = false, readOnly = false, type = "text", icon, suffix, prefix, addonBefore, addonAfter, theme: themeProp, shape: shapeProp, onSearch, onIconClick, onClear, onChange, className = "", style, onFocus, onBlur, onInput, controls, stylePrefix: inputType = "input", ...rest }, ref) => {
|
|
23
23
|
const inheritedAppearance = useFormAppearance();
|
|
@@ -198,5 +198,4 @@ var InputBase = React.forwardRef(({ clearable = true, visiblePasswordIcon = true
|
|
|
198
198
|
});
|
|
199
199
|
});
|
|
200
200
|
InputBase.displayName = "InputBase";
|
|
201
|
-
//#endregion
|
|
202
201
|
export { InputBase as default };
|