@fangxinyan/lumina 0.8.0 → 0.9.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/Alert.cjs +5 -5
- package/dist/Alert.js +4 -4
- package/dist/AppShell.cjs +8 -8
- package/dist/AppShell.js +4 -4
- package/dist/AutoComplete.cjs +7 -7
- package/dist/AutoComplete.js +6 -6
- package/dist/Avatar.cjs +4 -4
- package/dist/Avatar.js +3 -3
- package/dist/Badge.cjs +4 -4
- package/dist/Badge.js +3 -3
- package/dist/Button.cjs +6 -6
- package/dist/Button.js +4 -4
- package/dist/Calendar.cjs +5 -5
- package/dist/Calendar.js +4 -4
- package/dist/Card.cjs +7 -7
- package/dist/Card.js +6 -6
- package/dist/Cascader.cjs +7 -7
- package/dist/Cascader.js +6 -6
- package/dist/{Checkbox-IHFML4FV.css → Checkbox-YQ43GFUI.css} +7 -0
- package/dist/Checkbox.cjs +5 -5
- package/dist/Checkbox.d.cts +2 -0
- package/dist/Checkbox.d.ts +2 -0
- package/dist/Checkbox.js +4 -4
- package/dist/Collapse.cjs +5 -5
- package/dist/Collapse.js +4 -4
- package/dist/ColorPicker.cjs +7 -7
- package/dist/ColorPicker.js +6 -6
- package/dist/CommandPalette.cjs +7 -7
- package/dist/CommandPalette.js +6 -6
- package/dist/ContextMenu.cjs +4 -4
- package/dist/ContextMenu.js +3 -3
- package/dist/DatePicker.cjs +9 -9
- package/dist/DatePicker.js +8 -8
- package/dist/DateTimePicker.cjs +9 -9
- package/dist/DateTimePicker.js +8 -8
- package/dist/Divider.cjs +4 -4
- package/dist/Divider.js +3 -3
- package/dist/Drawer.cjs +5 -5
- package/dist/Drawer.js +4 -4
- package/dist/Empty.cjs +4 -4
- package/dist/Empty.js +3 -3
- package/dist/Form.cjs +6 -6
- package/dist/Form.js +3 -3
- package/dist/Icon.cjs +51 -51
- package/dist/Icon.js +3 -3
- package/dist/Image.cjs +9 -9
- package/dist/Image.js +5 -5
- package/dist/Input.cjs +7 -7
- package/dist/Input.js +5 -5
- package/dist/InputNumber.cjs +7 -7
- package/dist/InputNumber.js +6 -6
- package/dist/List.cjs +4 -4
- package/dist/List.js +3 -3
- package/dist/Message.cjs +8 -8
- package/dist/Message.js +4 -4
- package/dist/Modal.cjs +6 -6
- package/dist/Modal.js +5 -5
- package/dist/Pagination.cjs +9 -9
- package/dist/Pagination.js +8 -8
- package/dist/Popover.cjs +4 -4
- package/dist/Popover.js +3 -3
- package/dist/Progress.cjs +4 -4
- package/dist/Progress.js +3 -3
- package/dist/Radio.cjs +5 -5
- package/dist/Radio.js +3 -3
- package/dist/{Select-TU37MAHZ.css → Select-QPBB73KA.css} +34 -5
- package/dist/Select.cjs +8 -8
- package/dist/Select.d.cts +12 -1
- package/dist/Select.d.ts +12 -1
- package/dist/Select.js +7 -7
- package/dist/Skeleton.cjs +4 -4
- package/dist/Skeleton.js +3 -3
- package/dist/Slider.cjs +4 -4
- package/dist/Slider.js +3 -3
- package/dist/Spin.cjs +4 -4
- package/dist/Spin.js +3 -3
- package/dist/Splitter.cjs +4 -4
- package/dist/Splitter.js +3 -3
- package/dist/StatusBar.cjs +5 -5
- package/dist/StatusBar.js +3 -3
- package/dist/Surface.cjs +5 -5
- package/dist/Surface.js +3 -3
- package/dist/{Switch-TATU3LPB.css → Switch-3JV3LCPX.css} +3 -0
- package/dist/Switch.cjs +4 -4
- package/dist/Switch.d.cts +2 -0
- package/dist/Switch.d.ts +2 -0
- package/dist/Switch.js +3 -3
- package/dist/Table.cjs +12 -12
- package/dist/Table.js +11 -11
- package/dist/TablePro.cjs +13 -13
- package/dist/TablePro.js +12 -12
- package/dist/Tabs.cjs +4 -4
- package/dist/Tabs.js +3 -3
- package/dist/Tag.cjs +5 -5
- package/dist/Tag.js +4 -4
- package/dist/Textarea.cjs +6 -6
- package/dist/Textarea.js +4 -4
- package/dist/Theme.cjs +19 -19
- package/dist/Theme.js +1 -1
- package/dist/ThemePanel.cjs +14 -14
- package/dist/ThemePanel.js +11 -11
- package/dist/TimePicker.cjs +8 -8
- package/dist/TimePicker.js +7 -7
- package/dist/Timeline.cjs +5 -5
- package/dist/Timeline.js +4 -4
- package/dist/Tooltip.cjs +4 -4
- package/dist/Tooltip.js +3 -3
- package/dist/Typography.cjs +9 -9
- package/dist/Typography.js +4 -4
- package/dist/{chunk-LQMOYVQF.js → chunk-2BM65ITV.js} +2 -2
- package/dist/{chunk-UQI4R32R.js → chunk-2COQYOVG.js} +4 -4
- package/dist/{chunk-63RSKQID.js → chunk-2NECDEAJ.js} +3 -3
- package/dist/{chunk-I4YPBAQ5.js → chunk-2NXLVPF4.js} +3 -3
- package/dist/{chunk-7QAVPVMW.js → chunk-2V6RQQRI.js} +4 -4
- package/dist/{chunk-ZEYK37VW.cjs → chunk-2XDLXAZT.cjs} +6 -6
- package/dist/{chunk-TYZ6L7E6.cjs → chunk-33YRXHVK.cjs} +6 -6
- package/dist/{chunk-3EMWDDWK.cjs → chunk-3D5RJA7R.cjs} +16 -16
- package/dist/{chunk-VX6MZO4K.cjs → chunk-3J7HOTD6.cjs} +6 -6
- package/dist/{chunk-ARUN2DMD.js → chunk-427CDZDU.js} +2 -2
- package/dist/{chunk-IJDM2U3B.js → chunk-4JANYBXO.js} +2 -2
- package/dist/{chunk-ZHVR4YPB.cjs → chunk-4LYJRFD2.cjs} +3 -3
- package/dist/{chunk-LG62MPMU.cjs → chunk-4MZW2KBN.cjs} +11 -11
- package/dist/{chunk-F7WUCOBP.cjs → chunk-4ZSFMWLF.cjs} +24 -24
- package/dist/{chunk-FMUHLIHB.cjs → chunk-53I3PWRH.cjs} +3 -3
- package/dist/{chunk-JHM7MN3G.js → chunk-563SQXH7.js} +3 -3
- package/dist/{chunk-DRDDQCDD.js → chunk-5HLNFDV4.js} +1 -1
- package/dist/{chunk-2HIN5NFM.js → chunk-5VLANZAJ.js} +3 -3
- package/dist/{chunk-ALAG4ZUH.js → chunk-6OVWY63D.js} +2 -2
- package/dist/{chunk-434Y2JVW.cjs → chunk-6WEXRX7K.cjs} +7 -7
- package/dist/{chunk-MCDW3VKZ.cjs → chunk-76CTKBXD.cjs} +3 -3
- package/dist/{chunk-VA3JWOAB.cjs → chunk-7IWUBBYX.cjs} +15 -15
- package/dist/{chunk-PNKNZREC.cjs → chunk-7KA5D37Z.cjs} +27 -27
- package/dist/{chunk-Y2MT6PI6.js → chunk-7NKNQRK6.js} +4 -4
- package/dist/{chunk-EAUB6FEN.js → chunk-7PUYEPLK.js} +4 -4
- package/dist/{chunk-7VLAHOA7.cjs → chunk-7ZMUCSCJ.cjs} +8 -8
- package/dist/{chunk-RPO7657K.js → chunk-A34P5CU7.js} +3 -3
- package/dist/{chunk-FKCPSVC4.cjs → chunk-ADPXWCTK.cjs} +9 -9
- package/dist/{chunk-QDCPVI3S.cjs → chunk-AE5XWZ24.cjs} +14 -14
- package/dist/{chunk-RR7KWH26.cjs → chunk-AEY76EAH.cjs} +3 -3
- package/dist/{chunk-DURKCGEM.js → chunk-AL2PYVVP.js} +74 -38
- package/dist/{chunk-PIJV2FHO.cjs → chunk-AQN3PD24.cjs} +30 -30
- package/dist/{chunk-RMGFRAZ2.cjs → chunk-AR3MT2ZT.cjs} +10 -10
- package/dist/{chunk-3F424R5P.js → chunk-AXZNZ2IH.js} +3 -3
- package/dist/{chunk-HVPUGYBY.js → chunk-BDPJ2BPN.js} +4 -4
- package/dist/{chunk-HQFKXTX6.js → chunk-BOBT7JUB.js} +2 -2
- package/dist/{chunk-O6G3F5L4.js → chunk-CFKAKB2B.js} +5 -5
- package/dist/{chunk-U5YYOOLC.cjs → chunk-CLJLBFNU.cjs} +4 -4
- package/dist/{chunk-HYHBCHFM.cjs → chunk-CNV7R2OZ.cjs} +7 -7
- package/dist/{chunk-ULTDRMGN.js → chunk-CPVUDSIY.js} +6 -6
- package/dist/{chunk-QDY56GGO.js → chunk-D2N7OXMK.js} +2 -2
- package/dist/{chunk-LJVQQEME.js → chunk-DQMG4XPX.js} +6 -6
- package/dist/{chunk-STQDKMS5.cjs → chunk-GFGMGJ5A.cjs} +13 -13
- package/dist/{chunk-BKW5PXEO.js → chunk-GMFOY7RD.js} +5 -5
- package/dist/{chunk-GTFP7HA3.cjs → chunk-GW77XQEF.cjs} +15 -15
- package/dist/{chunk-DU2DSERH.js → chunk-HAIWLYLR.js} +3 -3
- package/dist/{chunk-VVRXNGYL.cjs → chunk-HJGPUE67.cjs} +9 -9
- package/dist/{chunk-WHBKQZU5.cjs → chunk-HMN65CDW.cjs} +6 -6
- package/dist/{chunk-MUZQWIMR.cjs → chunk-I2YL5XE4.cjs} +18 -18
- package/dist/{chunk-EE5KXDRK.cjs → chunk-I4GJZLJU.cjs} +6 -6
- package/dist/{chunk-QDMFXRPI.js → chunk-INCTDROH.js} +2 -2
- package/dist/{chunk-2BIOTRQC.js → chunk-ISK2RW7F.js} +2 -2
- package/dist/{chunk-OLYSSZHP.js → chunk-IU6PLLEL.js} +10 -10
- package/dist/{chunk-J5UEQ3ZQ.js → chunk-J7D5CQDK.js} +2 -2
- package/dist/{chunk-WMISXERU.js → chunk-JMYUO7V7.js} +7 -7
- package/dist/{chunk-SF7BPXDJ.cjs → chunk-K3KHQ77L.cjs} +86 -50
- package/dist/{chunk-AURYNA6G.js → chunk-KFCWDFBW.js} +2 -2
- package/dist/{chunk-KCDOC3HS.cjs → chunk-KPBZKHCS.cjs} +8 -6
- package/dist/{chunk-PQOBBASY.js → chunk-L2NEYHYG.js} +2 -2
- package/dist/{chunk-VQEMMJHC.js → chunk-LACXN5CI.js} +2 -2
- package/dist/{chunk-T4RR6NVU.cjs → chunk-M3JYP3V4.cjs} +7 -7
- package/dist/{chunk-FY73C7JK.js → chunk-MEBAE7DB.js} +4 -4
- package/dist/{chunk-5AXNUX3J.js → chunk-MFJHI472.js} +2 -2
- package/dist/{chunk-4SKHRPDH.js → chunk-MKVONDTB.js} +6 -6
- package/dist/{chunk-JBS353O4.cjs → chunk-MV56FOAD.cjs} +3 -3
- package/dist/{chunk-LEDESWNL.js → chunk-O6PRE6MZ.js} +5 -3
- package/dist/{chunk-EUTK2ZRJ.cjs → chunk-OBNGHJ3N.cjs} +3 -3
- package/dist/{chunk-62VV5COT.js → chunk-OGMI3TO5.js} +3 -3
- package/dist/{chunk-YAYSXZZZ.cjs → chunk-PYCAGTO7.cjs} +3 -3
- package/dist/{chunk-6DKPJ5LV.cjs → chunk-QI6BJJXM.cjs} +6 -6
- package/dist/{chunk-Y22PTPA7.js → chunk-QK3E6FAQ.js} +5 -5
- package/dist/{chunk-KATJAJUU.js → chunk-QSLXUNLM.js} +6 -4
- package/dist/{chunk-E66PSVBU.cjs → chunk-QTMI4ZA4.cjs} +5 -5
- package/dist/{chunk-LDX6Q6RK.cjs → chunk-RA5BULQ3.cjs} +3 -3
- package/dist/{chunk-BIPOXOHP.cjs → chunk-RWM44VCZ.cjs} +9 -9
- package/dist/{chunk-JKUXA3U6.cjs → chunk-RXITGNPX.cjs} +5 -5
- package/dist/{chunk-YPMQC5HX.js → chunk-RYF5ADJW.js} +3 -3
- package/dist/{chunk-SXLRWYQQ.js → chunk-SXT672KF.js} +5 -5
- package/dist/{chunk-U3SG2YT2.js → chunk-TALNKJQ2.js} +3 -3
- package/dist/{chunk-3IZZBM56.js → chunk-TNQJA5JF.js} +3 -3
- package/dist/{chunk-Q565GDVK.cjs → chunk-TPFY5SKB.cjs} +9 -9
- package/dist/{chunk-RERMZNF3.cjs → chunk-TTRU4TLQ.cjs} +3 -3
- package/dist/{chunk-UE4HFGJ6.js → chunk-TUXF2G2O.js} +4 -4
- package/dist/{chunk-3DKFS44V.js → chunk-TY5LOU3A.js} +3 -3
- package/dist/{chunk-6RQJXSWN.js → chunk-U7V2FOIM.js} +3 -3
- package/dist/{chunk-HQNDVNTQ.js → chunk-UCE53RYR.js} +5 -5
- package/dist/{chunk-WROF2PVG.cjs → chunk-UQF7E32V.cjs} +6 -4
- package/dist/{chunk-NRJXZPZR.cjs → chunk-V6BLBIY6.cjs} +17 -17
- package/dist/{chunk-2AUXUZ3Z.cjs → chunk-VDVKY2IX.cjs} +4 -4
- package/dist/{chunk-YKHIIC7M.js → chunk-VLQ6XIAL.js} +2 -2
- package/dist/{chunk-GFKWSDD6.cjs → chunk-VNP5WB6M.cjs} +6 -6
- package/dist/{chunk-PJFYIXBX.cjs → chunk-VTN6YLRJ.cjs} +11 -11
- package/dist/{chunk-YBGMTQ2V.js → chunk-XFJTJVWD.js} +3 -3
- package/dist/{chunk-77HU7JWK.cjs → chunk-XHKSUKKL.cjs} +6 -6
- package/dist/{chunk-K5HGHOG7.js → chunk-Y3WFWA52.js} +2 -2
- package/dist/{chunk-QNQSNVCU.cjs → chunk-YU4LBDBD.cjs} +6 -6
- package/dist/{chunk-QYPA77OI.cjs → chunk-Z6AG7O4B.cjs} +3 -3
- package/dist/{chunk-AUO2YYHB.js → chunk-Z7GKR4LL.js} +4 -4
- package/dist/{chunk-ZYIE3BH7.cjs → chunk-ZBRFGD3I.cjs} +3 -3
- package/dist/{chunk-5CZA33BK.cjs → chunk-ZCAYS4KR.cjs} +8 -8
- package/dist/{chunk-Q5HLC56A.cjs → chunk-ZGZLEJKA.cjs} +4 -4
- package/dist/{chunk-YUJ7Z6N2.cjs → chunk-ZT7ZWAF2.cjs} +13 -13
- package/dist/index.cjs +189 -189
- package/dist/index.d.cts +2 -2
- package/dist/index.d.ts +2 -2
- package/dist/index.js +52 -52
- package/dist/styles.css +58 -19
- package/dist/{tokens-CEJVVA3G.css → tokens-223RYVVS.css} +14 -14
- package/dist/tokens.css +14 -14
- package/docs/llms/checkbox.md +22 -5
- package/docs/llms/select.md +31 -0
- package/docs/llms/switch.md +22 -5
- package/docs/llms.md +1 -1
- package/package.json +1 -1
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
3
|
var chunkFJB3243S_cjs = require('./chunk-FJB3243S.cjs');
|
|
4
|
-
var
|
|
4
|
+
var chunkGFGMGJ5A_cjs = require('./chunk-GFGMGJ5A.cjs');
|
|
5
5
|
var chunkHSDMJUB6_cjs = require('./chunk-HSDMJUB6.cjs');
|
|
6
|
-
var
|
|
7
|
-
var
|
|
8
|
-
require('./tokens-
|
|
6
|
+
var chunkV6BLBIY6_cjs = require('./chunk-V6BLBIY6.cjs');
|
|
7
|
+
var chunkI4GJZLJU_cjs = require('./chunk-I4GJZLJU.cjs');
|
|
8
|
+
require('./tokens-223RYVVS.css');
|
|
9
9
|
require('./shared-NJHRNLRH.css');
|
|
10
10
|
require('./ColorPicker-GRZOKR5O.css');
|
|
11
11
|
var React = require('react');
|
|
@@ -295,8 +295,8 @@ var ColorPickerBase = React__namespace.forwardRef(
|
|
|
295
295
|
panelWidth: 256,
|
|
296
296
|
panelHeight: 300
|
|
297
297
|
});
|
|
298
|
-
const portalContainer =
|
|
299
|
-
const portalTheme =
|
|
298
|
+
const portalContainer = chunkI4GJZLJU_cjs.usePortalContainer();
|
|
299
|
+
const portalTheme = chunkV6BLBIY6_cjs.useComponentPortalTheme(["ColorPicker", "ThemePanel"]);
|
|
300
300
|
const panelId = React__namespace.useId();
|
|
301
301
|
chunkHSDMJUB6_cjs.useOverlayLayer({
|
|
302
302
|
open: open && !disabled && portalContainer != null,
|
|
@@ -497,8 +497,8 @@ var ColorPickerBase = React__namespace.forwardRef(
|
|
|
497
497
|
/* @__PURE__ */ jsxRuntime.jsx(HueSlider, { hue: h, onChange: handleHue }),
|
|
498
498
|
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "cp-row", children: [
|
|
499
499
|
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "cp-swatch sm", style: { background: current } }),
|
|
500
|
-
/* @__PURE__ */ jsxRuntime.jsx(
|
|
501
|
-
|
|
500
|
+
/* @__PURE__ */ jsxRuntime.jsx(chunkV6BLBIY6_cjs.InternalComponentThemePart, { components: "Input", children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
501
|
+
chunkGFGMGJ5A_cjs.Input,
|
|
502
502
|
{
|
|
503
503
|
className: "cp-input",
|
|
504
504
|
size: "sm",
|
|
@@ -533,7 +533,7 @@ var ColorPickerBase = React__namespace.forwardRef(
|
|
|
533
533
|
}
|
|
534
534
|
);
|
|
535
535
|
ColorPickerBase.displayName = "ColorPicker";
|
|
536
|
-
var ColorPicker =
|
|
536
|
+
var ColorPicker = chunkV6BLBIY6_cjs.withComponentTheme(
|
|
537
537
|
ColorPickerBase,
|
|
538
538
|
"ColorPicker",
|
|
539
539
|
["color-picker", "input"]
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var
|
|
4
|
-
var
|
|
5
|
-
require('./tokens-
|
|
3
|
+
var chunk7KA5D37Z_cjs = require('./chunk-7KA5D37Z.cjs');
|
|
4
|
+
var chunkV6BLBIY6_cjs = require('./chunk-V6BLBIY6.cjs');
|
|
5
|
+
require('./tokens-223RYVVS.css');
|
|
6
6
|
require('./shared-NJHRNLRH.css');
|
|
7
7
|
require('./TablePro-WYE6TXWJ.css');
|
|
8
8
|
var React = require('react');
|
|
@@ -76,8 +76,8 @@ var TableProInner = ({
|
|
|
76
76
|
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "table-toolbar-main", children: toolbar }),
|
|
77
77
|
actions && /* @__PURE__ */ jsxRuntime.jsx("div", { className: "table-toolbar-actions", children: actions })
|
|
78
78
|
] }),
|
|
79
|
-
/* @__PURE__ */ jsxRuntime.jsx(
|
|
80
|
-
|
|
79
|
+
/* @__PURE__ */ jsxRuntime.jsx(chunkV6BLBIY6_cjs.InternalComponentThemePart, { components: "Table", children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
80
|
+
chunk7KA5D37Z_cjs.Table,
|
|
81
81
|
{
|
|
82
82
|
columns,
|
|
83
83
|
data,
|
|
@@ -113,7 +113,7 @@ var TableProInner = ({
|
|
|
113
113
|
};
|
|
114
114
|
var TableProBase = React__namespace.forwardRef(TableProInner);
|
|
115
115
|
TableProBase.displayName = "TablePro";
|
|
116
|
-
var TablePro =
|
|
116
|
+
var TablePro = chunkV6BLBIY6_cjs.withComponentTheme(
|
|
117
117
|
TableProBase,
|
|
118
118
|
"TablePro",
|
|
119
119
|
["table-pro", "table", "button", "checkbox", "pagination", "select", "input"]
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
3
|
var chunkHSDMJUB6_cjs = require('./chunk-HSDMJUB6.cjs');
|
|
4
|
-
var
|
|
5
|
-
var
|
|
6
|
-
var
|
|
7
|
-
var
|
|
8
|
-
require('./tokens-
|
|
4
|
+
var chunkM3JYP3V4_cjs = require('./chunk-M3JYP3V4.cjs');
|
|
5
|
+
var chunkVDVKY2IX_cjs = require('./chunk-VDVKY2IX.cjs');
|
|
6
|
+
var chunkV6BLBIY6_cjs = require('./chunk-V6BLBIY6.cjs');
|
|
7
|
+
var chunkI4GJZLJU_cjs = require('./chunk-I4GJZLJU.cjs');
|
|
8
|
+
require('./tokens-223RYVVS.css');
|
|
9
9
|
require('./shared-NJHRNLRH.css');
|
|
10
10
|
require('./Modal-UI2FXNDR.css');
|
|
11
11
|
var React = require('react');
|
|
@@ -73,8 +73,8 @@ var ModalBase = React__namespace.forwardRef((props, ref) => {
|
|
|
73
73
|
onClick,
|
|
74
74
|
...rest
|
|
75
75
|
} = props;
|
|
76
|
-
const portalContainer =
|
|
77
|
-
const portalTheme =
|
|
76
|
+
const portalContainer = chunkI4GJZLJU_cjs.usePortalContainer();
|
|
77
|
+
const portalTheme = chunkV6BLBIY6_cjs.useComponentPortalTheme("Modal");
|
|
78
78
|
const panelRef = React__namespace.useRef(null);
|
|
79
79
|
const titleId = React__namespace.useId();
|
|
80
80
|
const descriptionId = React__namespace.useId();
|
|
@@ -129,10 +129,10 @@ var ModalBase = React__namespace.forwardRef((props, ref) => {
|
|
|
129
129
|
...hasExplicitWidth ? { width } : null,
|
|
130
130
|
...style
|
|
131
131
|
};
|
|
132
|
-
const defaultFooter = /* @__PURE__ */ jsxRuntime.jsxs(
|
|
133
|
-
/* @__PURE__ */ jsxRuntime.jsx(
|
|
132
|
+
const defaultFooter = /* @__PURE__ */ jsxRuntime.jsxs(chunkV6BLBIY6_cjs.InternalComponentThemePart, { components: "Button", children: [
|
|
133
|
+
/* @__PURE__ */ jsxRuntime.jsx(chunkM3JYP3V4_cjs.Button, { variant: "ghost", onClick: handleCancel, ...cancelButtonProps, children: cancelText }),
|
|
134
134
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
135
|
-
|
|
135
|
+
chunkM3JYP3V4_cjs.Button,
|
|
136
136
|
{
|
|
137
137
|
variant: "primary",
|
|
138
138
|
loading: confirmLoading,
|
|
@@ -182,7 +182,7 @@ var ModalBase = React__namespace.forwardRef((props, ref) => {
|
|
|
182
182
|
className: "modal-close",
|
|
183
183
|
onClick: handleCancel,
|
|
184
184
|
"aria-label": "Close",
|
|
185
|
-
children: closeIcon ?? /* @__PURE__ */ jsxRuntime.jsx(
|
|
185
|
+
children: closeIcon ?? /* @__PURE__ */ jsxRuntime.jsx(chunkVDVKY2IX_cjs.Icon, { name: "x", size: 16 })
|
|
186
186
|
}
|
|
187
187
|
)
|
|
188
188
|
] }),
|
|
@@ -205,7 +205,7 @@ var ModalBase = React__namespace.forwardRef((props, ref) => {
|
|
|
205
205
|
);
|
|
206
206
|
});
|
|
207
207
|
ModalBase.displayName = "Modal";
|
|
208
|
-
var ThemedModalBase =
|
|
208
|
+
var ThemedModalBase = chunkV6BLBIY6_cjs.withComponentTheme(
|
|
209
209
|
ModalBase,
|
|
210
210
|
"Modal",
|
|
211
211
|
["modal", "button"],
|
|
@@ -262,10 +262,10 @@ var StaticModalHost = ({
|
|
|
262
262
|
destroy();
|
|
263
263
|
}, [destroy, onOk]);
|
|
264
264
|
const okVariant = kind === "error" ? "danger" : "primary";
|
|
265
|
-
const mergedFooter = footer !== void 0 ? footer : okCancel ? /* @__PURE__ */ jsxRuntime.jsxs(
|
|
266
|
-
/* @__PURE__ */ jsxRuntime.jsx(
|
|
265
|
+
const mergedFooter = footer !== void 0 ? footer : okCancel ? /* @__PURE__ */ jsxRuntime.jsxs(chunkV6BLBIY6_cjs.InternalComponentThemePart, { components: "Button", children: [
|
|
266
|
+
/* @__PURE__ */ jsxRuntime.jsx(chunkM3JYP3V4_cjs.Button, { variant: "ghost", onClick: close, ...cancelButtonProps, children: cancelText }),
|
|
267
267
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
268
|
-
|
|
268
|
+
chunkM3JYP3V4_cjs.Button,
|
|
269
269
|
{
|
|
270
270
|
variant: okVariant,
|
|
271
271
|
loading: loading || confirmLoading,
|
|
@@ -274,8 +274,8 @@ var StaticModalHost = ({
|
|
|
274
274
|
children: okText
|
|
275
275
|
}
|
|
276
276
|
)
|
|
277
|
-
] }) : /* @__PURE__ */ jsxRuntime.jsx(
|
|
278
|
-
|
|
277
|
+
] }) : /* @__PURE__ */ jsxRuntime.jsx(chunkV6BLBIY6_cjs.InternalComponentThemePart, { components: "Button", children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
278
|
+
chunkM3JYP3V4_cjs.Button,
|
|
279
279
|
{
|
|
280
280
|
variant: okVariant,
|
|
281
281
|
loading: loading || confirmLoading,
|
|
@@ -297,7 +297,7 @@ var StaticModalHost = ({
|
|
|
297
297
|
className,
|
|
298
298
|
maskClassName: ["modal-static-overlay", config.maskClassName].filter(Boolean).join(" "),
|
|
299
299
|
children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "modal-static-body", children: [
|
|
300
|
-
icon !== false && /* @__PURE__ */ jsxRuntime.jsx("span", { className: `modal-static-icon ${kind}`, children: icon ?? /* @__PURE__ */ jsxRuntime.jsx(
|
|
300
|
+
icon !== false && /* @__PURE__ */ jsxRuntime.jsx("span", { className: `modal-static-icon ${kind}`, children: icon ?? /* @__PURE__ */ jsxRuntime.jsx(chunkVDVKY2IX_cjs.Icon, { name: staticIconName[kind], size: 20 }) }),
|
|
301
301
|
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "modal-static-content", children: content ?? children })
|
|
302
302
|
] })
|
|
303
303
|
}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
require('./tokens-
|
|
3
|
+
require('./tokens-223RYVVS.css');
|
|
4
4
|
var React3 = require('react');
|
|
5
5
|
var jsxRuntime = require('react/jsx-runtime');
|
|
6
6
|
|
|
@@ -437,16 +437,16 @@ function visualThemeToStyle(snapshot, prefix = "") {
|
|
|
437
437
|
const d = 0.4 + snapshot.intensity * 0.12;
|
|
438
438
|
const dark = snapshot.colorScheme === "dark";
|
|
439
439
|
style[variable("d")] = String(d);
|
|
440
|
-
style[variable("shadow-offset")] = `calc(${dark ?
|
|
441
|
-
style[variable("shadow-blur")] = `calc(${dark ?
|
|
442
|
-
style[variable("shadow-inset-offset")] = `calc(${dark ?
|
|
443
|
-
style[variable("shadow-inset-blur")] = `calc(${dark ?
|
|
440
|
+
style[variable("shadow-offset")] = `calc(${dark ? 3 : 5}px * ${reference("d")} * ${inheritedReference("shadow-scale")})`;
|
|
441
|
+
style[variable("shadow-blur")] = `calc(${dark ? 8 : 12}px * ${reference("d")} * ${inheritedReference("shadow-scale")})`;
|
|
442
|
+
style[variable("shadow-inset-offset")] = `calc(${dark ? 2 : 3}px * ${reference("d")} * ${inheritedReference("shadow-scale")})`;
|
|
443
|
+
style[variable("shadow-inset-blur")] = `calc(${dark ? 5 : 8}px * ${reference("d")} * ${inheritedReference("shadow-scale")})`;
|
|
444
444
|
style[variable("neu-shadow-panel")] = `${reference("shadow-offset")} ${reference("shadow-offset")} ${reference("shadow-blur")} ${reference("shadow-dark")}, calc(${reference("shadow-offset")} * -1) calc(${reference("shadow-offset")} * -1) ${reference("shadow-blur")} ${reference("shadow-light")}`;
|
|
445
445
|
style[variable("neu-shadow-control")] = `calc(${reference("shadow-offset")} * .5) calc(${reference("shadow-offset")} * .5) calc(${reference("shadow-blur")} * .6) ${reference("shadow-dark")}, calc(${reference("shadow-offset")} * -.5) calc(${reference("shadow-offset")} * -.5) calc(${reference("shadow-blur")} * .6) ${reference("shadow-light")}`;
|
|
446
446
|
style[variable("neu-shadow-lift")] = `calc(${reference("shadow-offset")} * 1.6) calc(${reference("shadow-offset")} * 1.6) calc(${reference("shadow-blur")} * 1.4) ${reference("shadow-dark")}, calc(${reference("shadow-offset")} * -1.6) calc(${reference("shadow-offset")} * -1.6) calc(${reference("shadow-blur")} * 1.4) ${reference("shadow-light")}`;
|
|
447
447
|
style[variable("neu-shadow-inset-strong")] = `inset ${reference("shadow-inset-offset")} ${reference("shadow-inset-offset")} ${reference("shadow-inset-blur")} ${reference("shadow-dark")}, inset calc(${reference("shadow-inset-offset")} * -1) calc(${reference("shadow-inset-offset")} * -1) ${reference("shadow-inset-blur")} ${reference("shadow-light")}`;
|
|
448
448
|
style[variable("neu-shadow-inset")] = `inset calc(${reference("shadow-inset-offset")} * .6) calc(${reference("shadow-inset-offset")} * .6) calc(${reference("shadow-inset-blur")} * .6) ${reference("shadow-dark")}, inset calc(${reference("shadow-inset-offset")} * -.6) calc(${reference("shadow-inset-offset")} * -.6) calc(${reference("shadow-inset-blur")} * .6) ${reference("shadow-light")}`;
|
|
449
|
-
style[variable("neu-shadow-subtle")] =
|
|
449
|
+
style[variable("neu-shadow-subtle")] = `.75px .75px 1.5px ${reference("shadow-dark")}, -.75px -.75px 1.5px ${reference("shadow-light")}`;
|
|
450
450
|
style[variable("neu-shadow-float")] = `0 calc(${reference("shadow-offset")} * 1.8 * ${inheritedReference("shadow-float-scale")}) calc(${reference("shadow-blur")} * 2.2 * ${inheritedReference("shadow-float-scale")}) ${reference("shadow-dark")}, 0 calc(${reference("shadow-offset")} * .4 * ${inheritedReference("shadow-float-scale")}) calc(${reference("shadow-blur")} * .7 * ${inheritedReference("shadow-float-scale")}) ${reference("shadow-dark")}`;
|
|
451
451
|
style[variable("neu-out")] = reference("neu-shadow-panel");
|
|
452
452
|
style[variable("neu-out-sm")] = reference("neu-shadow-control");
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { isTargetWithinOverlayScope } from './chunk-2A4GYSN4.js';
|
|
2
|
-
import { withComponentTheme } from './chunk-
|
|
3
|
-
import './tokens-
|
|
2
|
+
import { withComponentTheme } from './chunk-5HLNFDV4.js';
|
|
3
|
+
import './tokens-223RYVVS.css';
|
|
4
4
|
import './shared-NJHRNLRH.css';
|
|
5
5
|
import './Form-DNEDZRJA.css';
|
|
6
6
|
import * as React from 'react';
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { withComponentTheme } from './chunk-
|
|
2
|
-
import './tokens-
|
|
1
|
+
import { withComponentTheme } from './chunk-5HLNFDV4.js';
|
|
2
|
+
import './tokens-223RYVVS.css';
|
|
3
3
|
import './shared-NJHRNLRH.css';
|
|
4
4
|
import './Divider-OI2BXPBU.css';
|
|
5
5
|
import * as React from 'react';
|
|
@@ -1,14 +1,14 @@
|
|
|
1
|
-
import { Slider } from './chunk-
|
|
1
|
+
import { Slider } from './chunk-Y3WFWA52.js';
|
|
2
2
|
import { pickLuminaThemePresets } from './chunk-TSL3F2K3.js';
|
|
3
|
-
import { Switch } from './chunk-
|
|
4
|
-
import { RadioGroup } from './chunk-
|
|
5
|
-
import { ColorPicker } from './chunk-
|
|
6
|
-
import { Input } from './chunk-
|
|
7
|
-
import { Button } from './chunk-
|
|
8
|
-
import { Icon } from './chunk-
|
|
9
|
-
import { withInternalComponentThemePart, withComponentTheme } from './chunk-
|
|
10
|
-
import { useTheme, ACCENT_PRESETS, mergeComponentThemeOverrides, FONT_STACKS } from './chunk-
|
|
11
|
-
import './tokens-
|
|
3
|
+
import { Switch } from './chunk-O6PRE6MZ.js';
|
|
4
|
+
import { RadioGroup } from './chunk-D2N7OXMK.js';
|
|
5
|
+
import { ColorPicker } from './chunk-MEBAE7DB.js';
|
|
6
|
+
import { Input } from './chunk-TUXF2G2O.js';
|
|
7
|
+
import { Button } from './chunk-563SQXH7.js';
|
|
8
|
+
import { Icon } from './chunk-2BM65ITV.js';
|
|
9
|
+
import { withInternalComponentThemePart, withComponentTheme } from './chunk-5HLNFDV4.js';
|
|
10
|
+
import { useTheme, ACCENT_PRESETS, mergeComponentThemeOverrides, FONT_STACKS } from './chunk-CPVUDSIY.js';
|
|
11
|
+
import './tokens-223RYVVS.css';
|
|
12
12
|
import './shared-NJHRNLRH.css';
|
|
13
13
|
import './ThemePanel-EHNAS4RN.css';
|
|
14
14
|
import * as React from 'react';
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { withComponentTheme } from './chunk-
|
|
2
|
-
import './tokens-
|
|
1
|
+
import { withComponentTheme } from './chunk-5HLNFDV4.js';
|
|
2
|
+
import './tokens-223RYVVS.css';
|
|
3
3
|
import './shared-NJHRNLRH.css';
|
|
4
4
|
import './Splitter-IQ3PFIKK.css';
|
|
5
5
|
import * as React from 'react';
|
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
import { Pagination } from './chunk-
|
|
2
|
-
import { Checkbox } from './chunk-
|
|
1
|
+
import { Pagination } from './chunk-UCE53RYR.js';
|
|
2
|
+
import { Checkbox } from './chunk-QSLXUNLM.js';
|
|
3
3
|
import { useFloating } from './chunk-3QXP2ZNP.js';
|
|
4
4
|
import { useOverlayLayer } from './chunk-2A4GYSN4.js';
|
|
5
|
-
import { Button, IconButton } from './chunk-
|
|
6
|
-
import { Icon } from './chunk-
|
|
7
|
-
import { withComponentTheme, InternalComponentThemePart, useComponentPortalTheme } from './chunk-
|
|
8
|
-
import { usePortalContainer } from './chunk-
|
|
9
|
-
import './tokens-
|
|
5
|
+
import { Button, IconButton } from './chunk-563SQXH7.js';
|
|
6
|
+
import { Icon } from './chunk-2BM65ITV.js';
|
|
7
|
+
import { withComponentTheme, InternalComponentThemePart, useComponentPortalTheme } from './chunk-5HLNFDV4.js';
|
|
8
|
+
import { usePortalContainer } from './chunk-CPVUDSIY.js';
|
|
9
|
+
import './tokens-223RYVVS.css';
|
|
10
10
|
import './shared-NJHRNLRH.css';
|
|
11
11
|
import './Table-KB6EEBDJ.css';
|
|
12
12
|
import * as React from 'react';
|
|
@@ -1,15 +1,15 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var
|
|
3
|
+
var chunkVNP5WB6M_cjs = require('./chunk-VNP5WB6M.cjs');
|
|
4
4
|
var chunkFJB3243S_cjs = require('./chunk-FJB3243S.cjs');
|
|
5
|
-
var
|
|
5
|
+
var chunkGFGMGJ5A_cjs = require('./chunk-GFGMGJ5A.cjs');
|
|
6
6
|
var chunkHSDMJUB6_cjs = require('./chunk-HSDMJUB6.cjs');
|
|
7
|
-
var
|
|
8
|
-
var
|
|
9
|
-
var
|
|
10
|
-
require('./tokens-
|
|
7
|
+
var chunkVDVKY2IX_cjs = require('./chunk-VDVKY2IX.cjs');
|
|
8
|
+
var chunkV6BLBIY6_cjs = require('./chunk-V6BLBIY6.cjs');
|
|
9
|
+
var chunkI4GJZLJU_cjs = require('./chunk-I4GJZLJU.cjs');
|
|
10
|
+
require('./tokens-223RYVVS.css');
|
|
11
11
|
require('./shared-NJHRNLRH.css');
|
|
12
|
-
require('./Select-
|
|
12
|
+
require('./Select-QPBB73KA.css');
|
|
13
13
|
var React = require('react');
|
|
14
14
|
var reactDom = require('react-dom');
|
|
15
15
|
var jsxRuntime = require('react/jsx-runtime');
|
|
@@ -36,6 +36,15 @@ var React__namespace = /*#__PURE__*/_interopNamespace(React);
|
|
|
36
36
|
|
|
37
37
|
var isGroup = (it) => Array.isArray(it.options);
|
|
38
38
|
var flatten = (items) => items.flatMap((it) => isGroup(it) ? it.options : [it]);
|
|
39
|
+
var prioritizePinnedGroups = (items) => {
|
|
40
|
+
const pinnedGroups = [];
|
|
41
|
+
const remainingItems = [];
|
|
42
|
+
items.forEach((item) => {
|
|
43
|
+
if (isGroup(item) && item.pinned) pinnedGroups.push(item);
|
|
44
|
+
else remainingItems.push(item);
|
|
45
|
+
});
|
|
46
|
+
return pinnedGroups.length > 0 ? [...pinnedGroups, ...remainingItems] : items;
|
|
47
|
+
};
|
|
39
48
|
var defaultFilter = (input, opt, optionFilterProp) => {
|
|
40
49
|
const q = input.toLowerCase();
|
|
41
50
|
const propValue = optionFilterProp ? opt[optionFilterProp] : void 0;
|
|
@@ -65,6 +74,7 @@ var SelectInner = (props, forwardedRef) => {
|
|
|
65
74
|
loading,
|
|
66
75
|
emptyContent,
|
|
67
76
|
optionRender,
|
|
77
|
+
optionExtraRender,
|
|
68
78
|
selectedRender,
|
|
69
79
|
listHeight = 260,
|
|
70
80
|
popupStyle,
|
|
@@ -110,8 +120,8 @@ var SelectInner = (props, forwardedRef) => {
|
|
|
110
120
|
const [query, setQuery] = React__namespace.useState("");
|
|
111
121
|
const [activeIdx, setActiveIdx] = React__namespace.useState(-1);
|
|
112
122
|
const searchRef = React__namespace.useRef(null);
|
|
113
|
-
const portalContainer =
|
|
114
|
-
const portalTheme =
|
|
123
|
+
const portalContainer = chunkI4GJZLJU_cjs.usePortalContainer();
|
|
124
|
+
const portalTheme = chunkV6BLBIY6_cjs.useComponentPortalTheme([
|
|
115
125
|
"Select",
|
|
116
126
|
"Pagination",
|
|
117
127
|
"Table",
|
|
@@ -191,7 +201,11 @@ var SelectInner = (props, forwardedRef) => {
|
|
|
191
201
|
}
|
|
192
202
|
if (!open) setActiveIdx(-1);
|
|
193
203
|
}, [open, mergedSearchable]);
|
|
194
|
-
const
|
|
204
|
+
const orderedItems = React__namespace.useMemo(
|
|
205
|
+
() => prioritizePinnedGroups(options),
|
|
206
|
+
[options]
|
|
207
|
+
);
|
|
208
|
+
const allFlat = React__namespace.useMemo(() => flatten(orderedItems), [orderedItems]);
|
|
195
209
|
const filteredFlat = React__namespace.useMemo(() => {
|
|
196
210
|
if (!query.trim()) return allFlat;
|
|
197
211
|
if (filterOption === false) return allFlat;
|
|
@@ -199,15 +213,17 @@ var SelectInner = (props, forwardedRef) => {
|
|
|
199
213
|
return allFlat.filter((o) => f(query, o));
|
|
200
214
|
}, [allFlat, query, filterOption, optionFilterProp]);
|
|
201
215
|
const filteredItems = React__namespace.useMemo(() => {
|
|
202
|
-
if (!query.trim())
|
|
203
|
-
|
|
216
|
+
if (!query.trim()) {
|
|
217
|
+
return orderedItems.filter((item) => !isGroup(item) || item.options.length > 0);
|
|
218
|
+
}
|
|
219
|
+
return orderedItems.map((it) => {
|
|
204
220
|
if (!isGroup(it)) {
|
|
205
221
|
return filteredFlat.includes(it) ? it : null;
|
|
206
222
|
}
|
|
207
223
|
const kept = it.options.filter((o) => filteredFlat.includes(o));
|
|
208
|
-
return kept.length ? {
|
|
224
|
+
return kept.length ? { ...it, options: kept } : null;
|
|
209
225
|
}).filter((x) => x !== null);
|
|
210
|
-
}, [
|
|
226
|
+
}, [orderedItems, filteredFlat, query]);
|
|
211
227
|
React__namespace.useEffect(() => {
|
|
212
228
|
setActiveIdx((current) => {
|
|
213
229
|
if (current >= 0 && current < filteredFlat.length && !isOptionDisabled(filteredFlat[current])) {
|
|
@@ -301,9 +317,9 @@ var SelectInner = (props, forwardedRef) => {
|
|
|
301
317
|
if (selected.length === 0) {
|
|
302
318
|
return /* @__PURE__ */ jsxRuntime.jsx("span", { className: "placeholder", children: placeholder });
|
|
303
319
|
}
|
|
304
|
-
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
320
|
+
return /* @__PURE__ */ jsxRuntime.jsx(chunkV6BLBIY6_cjs.InternalComponentThemePart, { components: "Tag", children: /* @__PURE__ */ jsxRuntime.jsxs("span", { className: "select-tags", children: [
|
|
305
321
|
shown.map((o) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
306
|
-
|
|
322
|
+
chunkVNP5WB6M_cjs.Tag,
|
|
307
323
|
{
|
|
308
324
|
tone: "accent",
|
|
309
325
|
removable: !disabled,
|
|
@@ -318,7 +334,7 @@ var SelectInner = (props, forwardedRef) => {
|
|
|
318
334
|
},
|
|
319
335
|
String(o.value)
|
|
320
336
|
)),
|
|
321
|
-
overflow > 0 && /* @__PURE__ */ jsxRuntime.jsxs(
|
|
337
|
+
overflow > 0 && /* @__PURE__ */ jsxRuntime.jsxs(chunkVNP5WB6M_cjs.Tag, { tone: "neutral", children: [
|
|
322
338
|
"+",
|
|
323
339
|
overflow
|
|
324
340
|
] })
|
|
@@ -330,48 +346,73 @@ var SelectInner = (props, forwardedRef) => {
|
|
|
330
346
|
return /* @__PURE__ */ jsxRuntime.jsx("span", { className: "select-value select-value-custom", children: selectedRender(current, { value: current.value, multiple: false }) });
|
|
331
347
|
}
|
|
332
348
|
return /* @__PURE__ */ jsxRuntime.jsxs("span", { className: "select-value", children: [
|
|
333
|
-
|
|
349
|
+
chunkVDVKY2IX_cjs.renderIconSlot(current.icon, { size: 14, className: "select-icon" }),
|
|
334
350
|
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "select-value-label", children: current.label })
|
|
335
351
|
] });
|
|
336
352
|
};
|
|
337
353
|
const hasSelection = isMulti ? multiValue.length > 0 : singleValue != null;
|
|
338
354
|
const showClear = mergedClearable && hasSelection && !disabled;
|
|
339
355
|
let renderIdx = -1;
|
|
340
|
-
const renderOption = (o) => {
|
|
356
|
+
const renderOption = (o, groupPinned = false) => {
|
|
341
357
|
renderIdx += 1;
|
|
342
358
|
const idx = renderIdx;
|
|
343
359
|
const sel = isSelected(o.value);
|
|
344
360
|
const active = idx === activeIdx;
|
|
345
361
|
const optionDisabled = isOptionDisabled(o);
|
|
362
|
+
const renderInfo = {
|
|
363
|
+
index: idx,
|
|
364
|
+
selected: sel,
|
|
365
|
+
active,
|
|
366
|
+
disabled: optionDisabled,
|
|
367
|
+
groupPinned
|
|
368
|
+
};
|
|
369
|
+
const extraContent = optionExtraRender ? optionExtraRender(o, renderInfo) : o.extra;
|
|
370
|
+
const hasExtra = extraContent !== null && extraContent !== void 0 && extraContent !== false;
|
|
346
371
|
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
347
|
-
"
|
|
372
|
+
"div",
|
|
348
373
|
{
|
|
349
|
-
|
|
350
|
-
|
|
351
|
-
role: "option",
|
|
352
|
-
"aria-selected": sel,
|
|
353
|
-
"aria-label": getOptionAriaLabel(o),
|
|
354
|
-
disabled: optionDisabled,
|
|
355
|
-
className: `menu-item ${sel ? "active" : ""} ${active ? "highlight" : ""}`,
|
|
374
|
+
role: "presentation",
|
|
375
|
+
className: `menu-item-row ${sel ? "active" : ""} ${active ? "highlight" : ""} ${optionDisabled ? "disabled" : ""}`,
|
|
356
376
|
onMouseEnter: () => {
|
|
357
377
|
if (!optionDisabled) setActiveIdx(idx);
|
|
358
378
|
},
|
|
359
|
-
onClick: () => isMulti ? toggleMulti(o) : pickSingle(o),
|
|
360
379
|
children: [
|
|
361
|
-
|
|
362
|
-
|
|
363
|
-
|
|
364
|
-
|
|
365
|
-
|
|
366
|
-
|
|
367
|
-
|
|
368
|
-
|
|
369
|
-
|
|
380
|
+
/* @__PURE__ */ jsxRuntime.jsxs(
|
|
381
|
+
"button",
|
|
382
|
+
{
|
|
383
|
+
id: `${listboxId}-option-${idx}`,
|
|
384
|
+
type: "button",
|
|
385
|
+
role: "option",
|
|
386
|
+
"aria-selected": sel,
|
|
387
|
+
"aria-label": getOptionAriaLabel(o),
|
|
388
|
+
disabled: optionDisabled,
|
|
389
|
+
className: `menu-item ${sel ? "active" : ""} ${active ? "highlight" : ""}`,
|
|
390
|
+
onClick: () => isMulti ? toggleMulti(o) : pickSingle(o),
|
|
391
|
+
children: [
|
|
392
|
+
isMulti && /* @__PURE__ */ jsxRuntime.jsx("span", { className: `menu-check ${sel ? "on" : ""}`, "aria-hidden": true, children: sel && /* @__PURE__ */ jsxRuntime.jsx(chunkVDVKY2IX_cjs.Icon, { name: "check", size: 11, stroke: 3 }) }),
|
|
393
|
+
optionRender ? /* @__PURE__ */ jsxRuntime.jsx("span", { className: "menu-item-custom", children: optionRender(o, renderInfo) }) : /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
394
|
+
chunkVDVKY2IX_cjs.renderIconSlot(o.icon, { size: 14, className: "menu-item-icon" }),
|
|
395
|
+
/* @__PURE__ */ jsxRuntime.jsxs("span", { className: "menu-item-body", children: [
|
|
396
|
+
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "menu-item-label", children: o.label }),
|
|
397
|
+
o.description && /* @__PURE__ */ jsxRuntime.jsx("span", { className: "menu-item-desc", children: o.description })
|
|
398
|
+
] })
|
|
399
|
+
] }),
|
|
400
|
+
!isMulti && /* @__PURE__ */ jsxRuntime.jsx("span", { className: "tick", children: /* @__PURE__ */ jsxRuntime.jsx(chunkVDVKY2IX_cjs.Icon, { name: "check", size: 12, stroke: 3 }) })
|
|
401
|
+
]
|
|
402
|
+
}
|
|
403
|
+
),
|
|
404
|
+
hasExtra && /* @__PURE__ */ jsxRuntime.jsx("span", { className: "menu-item-extra", children: extraContent })
|
|
370
405
|
]
|
|
371
406
|
},
|
|
372
407
|
String(o.value)
|
|
373
408
|
);
|
|
374
409
|
};
|
|
410
|
+
const renderMenuItems = (items) => items.map(
|
|
411
|
+
(item, groupIndex) => isGroup(item) ? /* @__PURE__ */ jsxRuntime.jsxs(React__namespace.Fragment, { children: [
|
|
412
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "menu-group-label", children: item.label }),
|
|
413
|
+
item.options.map((option) => renderOption(option, !!item.pinned))
|
|
414
|
+
] }, `g-${groupIndex}-${item.pinned ? "pinned" : "regular"}`) : renderOption(item)
|
|
415
|
+
);
|
|
375
416
|
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
376
417
|
"div",
|
|
377
418
|
{
|
|
@@ -421,7 +462,7 @@ var SelectInner = (props, forwardedRef) => {
|
|
|
421
462
|
"aria-activedescendant": open && activeIdx >= 0 ? `${listboxId}-option-${activeIdx}` : void 0,
|
|
422
463
|
children: [
|
|
423
464
|
renderTrigger(),
|
|
424
|
-
/* @__PURE__ */ jsxRuntime.jsx(
|
|
465
|
+
/* @__PURE__ */ jsxRuntime.jsx(chunkVDVKY2IX_cjs.Icon, { name: "chevDown", size: 14, className: "select-caret" })
|
|
425
466
|
]
|
|
426
467
|
}
|
|
427
468
|
),
|
|
@@ -437,7 +478,7 @@ var SelectInner = (props, forwardedRef) => {
|
|
|
437
478
|
event.stopPropagation();
|
|
438
479
|
clearAll();
|
|
439
480
|
},
|
|
440
|
-
children: mergedClearIcon ?? /* @__PURE__ */ jsxRuntime.jsx(
|
|
481
|
+
children: mergedClearIcon ?? /* @__PURE__ */ jsxRuntime.jsx(chunkVDVKY2IX_cjs.Icon, { name: "x", size: 12 })
|
|
441
482
|
}
|
|
442
483
|
),
|
|
443
484
|
open && portalContainer && reactDom.createPortal(
|
|
@@ -457,8 +498,8 @@ var SelectInner = (props, forwardedRef) => {
|
|
|
457
498
|
...popupStyle
|
|
458
499
|
},
|
|
459
500
|
children: [
|
|
460
|
-
mergedSearchable && /* @__PURE__ */ jsxRuntime.jsx("div", { className: "menu-search", children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
461
|
-
|
|
501
|
+
mergedSearchable && /* @__PURE__ */ jsxRuntime.jsx("div", { className: "menu-search", children: /* @__PURE__ */ jsxRuntime.jsx(chunkV6BLBIY6_cjs.InternalComponentThemePart, { components: "Input", children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
502
|
+
chunkGFGMGJ5A_cjs.Input,
|
|
462
503
|
{
|
|
463
504
|
ref: searchRef,
|
|
464
505
|
size: "sm",
|
|
@@ -487,15 +528,10 @@ var SelectInner = (props, forwardedRef) => {
|
|
|
487
528
|
children: loading ? /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "menu-state", children: [
|
|
488
529
|
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "menu-state-ico", children: /* @__PURE__ */ jsxRuntime.jsx("span", { className: "spinner" }) }),
|
|
489
530
|
/* @__PURE__ */ jsxRuntime.jsx("span", { children: "\u52A0\u8F7D\u4E2D..." })
|
|
490
|
-
] }) :
|
|
491
|
-
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "menu-state-ico", children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
531
|
+
] }) : filteredFlat.length === 0 ? /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "menu-state", children: [
|
|
532
|
+
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "menu-state-ico", children: /* @__PURE__ */ jsxRuntime.jsx(chunkVDVKY2IX_cjs.Icon, { name: "search", size: 16 }) }),
|
|
492
533
|
/* @__PURE__ */ jsxRuntime.jsx("span", { children: emptyContent ?? "\u6682\u65E0\u5339\u914D\u9879" })
|
|
493
|
-
] }) : filteredItems
|
|
494
|
-
(it, gi) => isGroup(it) ? /* @__PURE__ */ jsxRuntime.jsxs(React__namespace.Fragment, { children: [
|
|
495
|
-
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "menu-group-label", children: it.label }),
|
|
496
|
-
it.options.map(renderOption)
|
|
497
|
-
] }, `g-${gi}`) : renderOption(it)
|
|
498
|
-
)
|
|
534
|
+
] }) : renderMenuItems(filteredItems)
|
|
499
535
|
}
|
|
500
536
|
)
|
|
501
537
|
]
|
|
@@ -509,7 +545,7 @@ var SelectInner = (props, forwardedRef) => {
|
|
|
509
545
|
};
|
|
510
546
|
var SelectBase = React__namespace.forwardRef(SelectInner);
|
|
511
547
|
SelectBase.displayName = "Select";
|
|
512
|
-
var Select =
|
|
548
|
+
var Select = chunkV6BLBIY6_cjs.withComponentTheme(
|
|
513
549
|
SelectBase,
|
|
514
550
|
"Select",
|
|
515
551
|
["select", "input", "tag"]
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { withComponentTheme } from './chunk-
|
|
2
|
-
import './tokens-
|
|
1
|
+
import { withComponentTheme } from './chunk-5HLNFDV4.js';
|
|
2
|
+
import './tokens-223RYVVS.css';
|
|
3
3
|
import './shared-NJHRNLRH.css';
|
|
4
4
|
import './Empty-U5CBLCAL.css';
|
|
5
5
|
import * as React from 'react';
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var
|
|
4
|
-
var
|
|
5
|
-
require('./tokens-
|
|
3
|
+
var chunkVDVKY2IX_cjs = require('./chunk-VDVKY2IX.cjs');
|
|
4
|
+
var chunkV6BLBIY6_cjs = require('./chunk-V6BLBIY6.cjs');
|
|
5
|
+
require('./tokens-223RYVVS.css');
|
|
6
6
|
require('./shared-NJHRNLRH.css');
|
|
7
|
-
require('./Checkbox-
|
|
7
|
+
require('./Checkbox-YQ43GFUI.css');
|
|
8
8
|
var React = require('react');
|
|
9
9
|
var jsxRuntime = require('react/jsx-runtime');
|
|
10
10
|
|
|
@@ -41,6 +41,7 @@ var CheckboxBase = React__namespace.forwardRef(({
|
|
|
41
41
|
value: formValue,
|
|
42
42
|
required,
|
|
43
43
|
form,
|
|
44
|
+
invalid = false,
|
|
44
45
|
"aria-label": ariaLabel,
|
|
45
46
|
"aria-labelledby": ariaLabelledBy,
|
|
46
47
|
"aria-describedby": ariaDescribedBy,
|
|
@@ -65,6 +66,7 @@ var CheckboxBase = React__namespace.forwardRef(({
|
|
|
65
66
|
value && "checked",
|
|
66
67
|
indeterminate && "indeterminate",
|
|
67
68
|
disabled && "disabled",
|
|
69
|
+
invalid && "invalid",
|
|
68
70
|
className
|
|
69
71
|
].filter(Boolean).join(" ");
|
|
70
72
|
return /* @__PURE__ */ jsxRuntime.jsxs("label", { ref, className: cls, ...rest, children: [
|
|
@@ -90,11 +92,11 @@ var CheckboxBase = React__namespace.forwardRef(({
|
|
|
90
92
|
"aria-checked": indeterminate ? "mixed" : value
|
|
91
93
|
}
|
|
92
94
|
),
|
|
93
|
-
/* @__PURE__ */ jsxRuntime.jsx("span", { "aria-hidden": "true", className: "checkbox-box", children: indeterminate ? /* @__PURE__ */ jsxRuntime.jsx(
|
|
95
|
+
/* @__PURE__ */ jsxRuntime.jsx("span", { "aria-hidden": "true", className: "checkbox-box", children: indeterminate ? /* @__PURE__ */ jsxRuntime.jsx(chunkVDVKY2IX_cjs.Icon, { name: "minus", size: 11 }) : value ? /* @__PURE__ */ jsxRuntime.jsx(chunkVDVKY2IX_cjs.Icon, { name: "check", size: 11 }) : null }),
|
|
94
96
|
label && /* @__PURE__ */ jsxRuntime.jsx("span", { className: "checkbox-label", children: label })
|
|
95
97
|
] });
|
|
96
98
|
});
|
|
97
99
|
CheckboxBase.displayName = "Checkbox";
|
|
98
|
-
var Checkbox =
|
|
100
|
+
var Checkbox = chunkV6BLBIY6_cjs.withComponentTheme(CheckboxBase, "Checkbox", "checkbox");
|
|
99
101
|
|
|
100
102
|
exports.Checkbox = Checkbox;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { withComponentTheme } from './chunk-
|
|
2
|
-
import './tokens-
|
|
1
|
+
import { withComponentTheme } from './chunk-5HLNFDV4.js';
|
|
2
|
+
import './tokens-223RYVVS.css';
|
|
3
3
|
import './shared-NJHRNLRH.css';
|
|
4
4
|
import './Spin-F5YIEENO.css';
|
|
5
5
|
import * as React from 'react';
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { withComponentTheme } from './chunk-
|
|
2
|
-
import './tokens-
|
|
1
|
+
import { withComponentTheme } from './chunk-5HLNFDV4.js';
|
|
2
|
+
import './tokens-223RYVVS.css';
|
|
3
3
|
import './shared-NJHRNLRH.css';
|
|
4
4
|
import './List-6BQIFAIT.css';
|
|
5
5
|
import * as React from 'react';
|