@ark-ui/solid 1.0.0-beta.2 → 1.0.0-beta.3
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/CHANGELOG.md +19 -1
- package/cjs/index.js +197 -57
- package/cjs/index.js.map +1 -1
- package/esm/index.js +198 -59
- package/esm/index.js.map +1 -1
- package/package.json +44 -44
- package/source/accordion/accordion-item-content.jsx +3 -3
- package/source/color-picker/color-picker-content.jsx +6 -2
- package/source/color-picker/color-picker-value-text.jsx +9 -0
- package/source/color-picker/index.js +3 -1
- package/source/combobox/combobox-content.jsx +1 -1
- package/source/combobox/combobox-item-group-label.jsx +2 -2
- package/source/date-picker/date-picker-content.jsx +6 -2
- package/source/date-picker/date-picker-view.jsx +4 -1
- package/source/date-picker/date-picker.jsx +1 -1
- package/source/dialog/dialog-backdrop.jsx +1 -1
- package/source/dialog/dialog-content.jsx +1 -1
- package/source/hover-card/hover-card-content.jsx +1 -1
- package/source/menu/menu-content.jsx +1 -1
- package/source/menu/menu-item-group-label.jsx +3 -5
- package/source/popover/popover-content.jsx +1 -1
- package/source/presence/presence.jsx +1 -1
- package/source/presence/split-presence-props.js +1 -0
- package/source/select/select-content.jsx +1 -1
- package/source/select/select-control.jsx +9 -1
- package/source/select/select-item-group-label.jsx +2 -2
- package/source/slider/index.js +3 -3
- package/source/slider/slider-value-text.jsx +10 -0
- package/source/tooltip/tooltip-content.jsx +1 -1
- package/types/accordion/accordion-item-content.d.ts +3 -1
- package/types/color-picker/color-picker-content.d.ts +3 -1
- package/types/color-picker/color-picker-transparency-grid.d.ts +2 -2
- package/types/color-picker/color-picker-value-text.d.ts +5 -0
- package/types/color-picker/index.d.ts +6 -4
- package/types/combobox/combobox-content.d.ts +3 -1
- package/types/combobox/combobox-item-group-label.d.ts +6 -2
- package/types/date-picker/date-picker-content.d.ts +3 -1
- package/types/dialog/dialog-backdrop.d.ts +3 -1
- package/types/dialog/dialog-content.d.ts +3 -1
- package/types/hover-card/hover-card-content.d.ts +3 -1
- package/types/menu/menu-content.d.ts +3 -1
- package/types/menu/menu-item-group-label.d.ts +5 -4
- package/types/popover/popover-content.d.ts +3 -1
- package/types/presence/presence.d.ts +6 -2
- package/types/presence/split-presence-props.d.ts +1 -1
- package/types/select/select-content.d.ts +3 -1
- package/types/select/select-item-group-label.d.ts +6 -2
- package/types/slider/index.d.ts +4 -4
- package/types/slider/{slider-output.d.ts → slider-value-text.d.ts} +2 -2
- package/types/tabs/tab-content.d.ts +1 -1
- package/types/tooltip/tooltip-content.d.ts +3 -1
- package/source/slider/slider-output.jsx +0 -10
package/CHANGELOG.md
CHANGED
|
@@ -1,11 +1,29 @@
|
|
|
1
1
|
---
|
|
2
2
|
id: changelog
|
|
3
3
|
name: Changelog
|
|
4
|
-
description: All notable changes to this project will be documented in this file.
|
|
4
|
+
description: All notable changes to this project will be documented in this file.
|
|
5
5
|
---
|
|
6
6
|
|
|
7
7
|
## [Unreleased]
|
|
8
8
|
|
|
9
|
+
## [1.0.0-beta.3] - 2023-10-31
|
|
10
|
+
|
|
11
|
+
### Added
|
|
12
|
+
|
|
13
|
+
- Added support to lazy mount the `DatePicker` and `ColorPicker` components using the `Presence` component
|
|
14
|
+
- Added `ValueText` to the `ColorPicker` component
|
|
15
|
+
|
|
16
|
+
### Changed
|
|
17
|
+
|
|
18
|
+
- Improved accessibility of all disclosure components when lazy mounting is enabled.
|
|
19
|
+
- Renamed `htmlFor` prop to `for` in `MenuItemGroupLabel`,
|
|
20
|
+
`ComboboxItemGroupLabel` and `SelectItemGroupLabel` component
|
|
21
|
+
|
|
22
|
+
### Fixed
|
|
23
|
+
|
|
24
|
+
- Added missing data attributes to `DatePickerView` component
|
|
25
|
+
- Resolved an accessibility issue with `Select`
|
|
26
|
+
|
|
9
27
|
## [1.0.0-beta.2] - 2023-10-24
|
|
10
28
|
|
|
11
29
|
### Changed
|
package/cjs/index.js
CHANGED
|
@@ -476,7 +476,7 @@ const [EnvironmentProvider, useEnvironmentContext] = createContext({
|
|
|
476
476
|
strict: false
|
|
477
477
|
});
|
|
478
478
|
|
|
479
|
-
const _tmpl$$
|
|
479
|
+
const _tmpl$$m = /*#__PURE__*/web.template(`<span hidden>`);
|
|
480
480
|
const Environment$1 = props => {
|
|
481
481
|
// eslint-disable-next-line prefer-const
|
|
482
482
|
let spanRef = undefined;
|
|
@@ -487,7 +487,7 @@ const Environment$1 = props => {
|
|
|
487
487
|
},
|
|
488
488
|
get children() {
|
|
489
489
|
return [web.memo(() => props.children), web.memo(() => web.memo(() => !!!props.value)() && (() => {
|
|
490
|
-
const _el$ = _tmpl$$
|
|
490
|
+
const _el$ = _tmpl$$m();
|
|
491
491
|
const _ref$ = spanRef;
|
|
492
492
|
typeof _ref$ === "function" ? web.use(_ref$, _el$) : spanRef = _el$;
|
|
493
493
|
return _el$;
|
|
@@ -576,30 +576,38 @@ const Presence$1 = props => {
|
|
|
576
576
|
});
|
|
577
577
|
return web.memo((() => {
|
|
578
578
|
const _c$ = web.memo(() => !!(!api().isPresent && !wasEverPresent() && localProps.lazyMount || localProps.unmountOnExit && !api().isPresent && wasEverPresent()));
|
|
579
|
-
return () => _c$() ?
|
|
579
|
+
return () => _c$() ? localProps.fallback : getChildren();
|
|
580
580
|
})());
|
|
581
581
|
};
|
|
582
582
|
|
|
583
583
|
function splitPresenceProps(props) {
|
|
584
|
-
return createSplitProps()(props, ['lazyMount', 'onExitComplete', 'present', 'unmountOnExit']);
|
|
584
|
+
return createSplitProps()(props, ['fallback', 'lazyMount', 'onExitComplete', 'present', 'unmountOnExit']);
|
|
585
585
|
}
|
|
586
586
|
|
|
587
587
|
const Presence = Object.assign(Presence$1, {
|
|
588
588
|
Root: Presence$1
|
|
589
589
|
});
|
|
590
590
|
|
|
591
|
+
const _tmpl$$l = /*#__PURE__*/web.template(`<div>`);
|
|
591
592
|
const AccordionItemContent = props => {
|
|
592
593
|
const [presenceProps, localProps] = splitPresenceProps(props);
|
|
593
594
|
const api = useAccordionContext();
|
|
594
595
|
const accordionItem = useAccordionItemContext();
|
|
595
|
-
const
|
|
596
|
+
const mergedProps = solid.mergeProps(() => api().getItemContentProps(accordionItem), localProps);
|
|
596
597
|
return web.createComponent(Presence, web.mergeProps({
|
|
597
598
|
get present() {
|
|
598
599
|
return accordionItem.isOpen;
|
|
599
600
|
}
|
|
600
601
|
}, presenceProps, {
|
|
602
|
+
get fallback() {
|
|
603
|
+
return (() => {
|
|
604
|
+
const _el$ = _tmpl$$l();
|
|
605
|
+
web.spread(_el$, web.mergeProps(() => api().getItemContentProps(accordionItem)), false, false);
|
|
606
|
+
return _el$;
|
|
607
|
+
})();
|
|
608
|
+
},
|
|
601
609
|
get children() {
|
|
602
|
-
return web.createComponent(ark.div,
|
|
610
|
+
return web.createComponent(ark.div, mergedProps);
|
|
603
611
|
}
|
|
604
612
|
}));
|
|
605
613
|
};
|
|
@@ -797,12 +805,12 @@ const Checkbox$1 = props => {
|
|
|
797
805
|
});
|
|
798
806
|
};
|
|
799
807
|
|
|
800
|
-
const _tmpl$$
|
|
808
|
+
const _tmpl$$k = /*#__PURE__*/web.template(`<input>`);
|
|
801
809
|
const CheckboxControl = props => {
|
|
802
810
|
const api = useCheckboxContext();
|
|
803
811
|
const mergedProps = solid.mergeProps(() => api().controlProps, props);
|
|
804
812
|
return [web.createComponent(ark.div, mergedProps), (() => {
|
|
805
|
-
const _el$ = _tmpl$$
|
|
813
|
+
const _el$ = _tmpl$$k();
|
|
806
814
|
web.spread(_el$, web.mergeProps(() => api().hiddenInputProps), false, false);
|
|
807
815
|
return _el$;
|
|
808
816
|
})()];
|
|
@@ -846,7 +854,7 @@ const useColorPicker = props => {
|
|
|
846
854
|
return solidJs.createMemo(() => colorPicker__namespace.connect(state, send, solid.normalizeProps));
|
|
847
855
|
};
|
|
848
856
|
|
|
849
|
-
const _tmpl$$
|
|
857
|
+
const _tmpl$$j = /*#__PURE__*/web.template(`<input>`);
|
|
850
858
|
const ColorPicker$1 = props => {
|
|
851
859
|
const [colorPickerProps, localProps] = createSplitProps()(props, ['autoFocus', 'dir', 'disabled', 'getRootNode', 'id', 'ids', 'initialFocusEl', 'name', 'name', 'onFocusOutside', 'onInteractOutside', 'onOpenChange', 'onPointerDownOutside', 'onValueChange', 'onValueChangeEnd', 'open', 'positioning', 'readOnly', 'value']);
|
|
852
860
|
const api = useColorPicker(colorPickerProps);
|
|
@@ -860,7 +868,7 @@ const ColorPicker$1 = props => {
|
|
|
860
868
|
return getChildren();
|
|
861
869
|
}
|
|
862
870
|
})), (() => {
|
|
863
|
-
const _el$ = _tmpl$$
|
|
871
|
+
const _el$ = _tmpl$$j();
|
|
864
872
|
web.spread(_el$, web.mergeProps(() => api().hiddenInputProps), false, false);
|
|
865
873
|
return _el$;
|
|
866
874
|
})()];
|
|
@@ -937,10 +945,27 @@ const ColorPickerChannelSliderTrack = props => {
|
|
|
937
945
|
return web.createComponent(ark.div, mergedProps);
|
|
938
946
|
};
|
|
939
947
|
|
|
948
|
+
const _tmpl$$i = /*#__PURE__*/web.template(`<div>`);
|
|
940
949
|
const ColorPickerContent = props => {
|
|
950
|
+
const [presenceProps, localProps] = splitPresenceProps(props);
|
|
941
951
|
const api = useColorPickerContext();
|
|
942
|
-
const mergedProps = solid.mergeProps(() => api().contentProps,
|
|
943
|
-
return web.createComponent(
|
|
952
|
+
const mergedProps = solid.mergeProps(() => api().contentProps, localProps);
|
|
953
|
+
return web.createComponent(Presence, web.mergeProps({
|
|
954
|
+
get present() {
|
|
955
|
+
return api().isOpen;
|
|
956
|
+
}
|
|
957
|
+
}, presenceProps, {
|
|
958
|
+
get fallback() {
|
|
959
|
+
return (() => {
|
|
960
|
+
const _el$ = _tmpl$$i();
|
|
961
|
+
web.spread(_el$, web.mergeProps(() => api().contentProps), false, false);
|
|
962
|
+
return _el$;
|
|
963
|
+
})();
|
|
964
|
+
},
|
|
965
|
+
get children() {
|
|
966
|
+
return web.createComponent(ark.div, mergedProps);
|
|
967
|
+
}
|
|
968
|
+
}));
|
|
944
969
|
};
|
|
945
970
|
|
|
946
971
|
const ColorPickerControl = props => {
|
|
@@ -1000,6 +1025,16 @@ const ColorPickerTrigger = props => {
|
|
|
1000
1025
|
return web.createComponent(ark.button, mergedProps);
|
|
1001
1026
|
};
|
|
1002
1027
|
|
|
1028
|
+
const ColorPickerValueText = props => {
|
|
1029
|
+
const api = useColorPickerContext();
|
|
1030
|
+
const mergedProps = solid.mergeProps(() => anatomy.colorPickerAnatomy.build().valueText.attrs, props);
|
|
1031
|
+
return web.createComponent(ark.span, web.mergeProps(mergedProps, {
|
|
1032
|
+
get children() {
|
|
1033
|
+
return api().valueAsString || props.children;
|
|
1034
|
+
}
|
|
1035
|
+
}));
|
|
1036
|
+
};
|
|
1037
|
+
|
|
1003
1038
|
const ColorPicker = Object.assign(ColorPicker$1, {
|
|
1004
1039
|
Root: ColorPicker$1,
|
|
1005
1040
|
Area: ColorPickerArea,
|
|
@@ -1018,7 +1053,8 @@ const ColorPicker = Object.assign(ColorPicker$1, {
|
|
|
1018
1053
|
SwatchGroup: ColorPickerSwatchGroup,
|
|
1019
1054
|
SwatchTrigger: ColorPickerSwatchTrigger,
|
|
1020
1055
|
TransparencyGrid: ColorPickerTransparencyGrid,
|
|
1021
|
-
Trigger: ColorPickerTrigger
|
|
1056
|
+
Trigger: ColorPickerTrigger,
|
|
1057
|
+
ValueText: ColorPickerValueText
|
|
1022
1058
|
});
|
|
1023
1059
|
|
|
1024
1060
|
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
@@ -1065,6 +1101,7 @@ const ComboboxClearTrigger = props => {
|
|
|
1065
1101
|
return web.createComponent(ark.button, mergedProps);
|
|
1066
1102
|
};
|
|
1067
1103
|
|
|
1104
|
+
const _tmpl$$h = /*#__PURE__*/web.template(`<div>`);
|
|
1068
1105
|
const ComboboxContent = props => {
|
|
1069
1106
|
const [presenceProps, localProps] = splitPresenceProps(props);
|
|
1070
1107
|
const api = useComboboxContext();
|
|
@@ -1074,6 +1111,13 @@ const ComboboxContent = props => {
|
|
|
1074
1111
|
return api().isOpen;
|
|
1075
1112
|
}
|
|
1076
1113
|
}, presenceProps, {
|
|
1114
|
+
get fallback() {
|
|
1115
|
+
return (() => {
|
|
1116
|
+
const _el$ = _tmpl$$h();
|
|
1117
|
+
web.spread(_el$, web.mergeProps(() => api().contentProps), false, false);
|
|
1118
|
+
return _el$;
|
|
1119
|
+
})();
|
|
1120
|
+
},
|
|
1077
1121
|
get children() {
|
|
1078
1122
|
return web.createComponent(ark.div, mergedProps);
|
|
1079
1123
|
}
|
|
@@ -1122,9 +1166,11 @@ const ComboboxItemGroup = props => {
|
|
|
1122
1166
|
};
|
|
1123
1167
|
|
|
1124
1168
|
const ComboboxItemGroupLabel = props => {
|
|
1125
|
-
const [labelProps, localProps] = createSplitProps()(props, ['
|
|
1169
|
+
const [labelProps, localProps] = createSplitProps()(props, ['for']);
|
|
1126
1170
|
const api = useComboboxContext();
|
|
1127
|
-
const mergedProps = solid.mergeProps(() => api().getItemGroupLabelProps(
|
|
1171
|
+
const mergedProps = solid.mergeProps(() => api().getItemGroupLabelProps({
|
|
1172
|
+
htmlFor: labelProps.for
|
|
1173
|
+
}), localProps);
|
|
1128
1174
|
return web.createComponent(ark.div, mergedProps);
|
|
1129
1175
|
};
|
|
1130
1176
|
|
|
@@ -1197,7 +1243,7 @@ const useDatePicker = props => {
|
|
|
1197
1243
|
};
|
|
1198
1244
|
|
|
1199
1245
|
const DatePicker$1 = props => {
|
|
1200
|
-
const [datePickerProps, localProps] = createSplitProps()(props, ['dir', 'disabled', 'fixedWeeks', 'focusedValue', 'format', 'getRootNode', 'id', 'ids', '
|
|
1246
|
+
const [datePickerProps, localProps] = createSplitProps()(props, ['closeOnSelect', 'dir', 'disabled', 'fixedWeeks', 'focusedValue', 'format', 'getRootNode', 'id', 'ids', 'isDateUnavailable', 'isDateUnavailable', 'locale', 'max', 'messages', 'min', 'modal', 'name', 'numOfMonths', 'onFocusChange', 'onOpenChange', 'onValueChange', 'onViewChange', 'open', 'parse', 'positioning', 'readOnly', 'selectionMode', 'startOfWeek', 'timeZone', 'value', 'view']);
|
|
1201
1247
|
const api = useDatePicker(datePickerProps);
|
|
1202
1248
|
const mergedProps = solid.mergeProps(() => api().rootProps, localProps);
|
|
1203
1249
|
const getChildren = () => runIfFn(localProps.children, api);
|
|
@@ -1219,10 +1265,27 @@ const DatePickerClearTrigger = props => {
|
|
|
1219
1265
|
return web.createComponent(ark.button, mergedProps);
|
|
1220
1266
|
};
|
|
1221
1267
|
|
|
1268
|
+
const _tmpl$$g = /*#__PURE__*/web.template(`<div>`);
|
|
1222
1269
|
const DatePickerContent = props => {
|
|
1270
|
+
const [presenceProps, localProps] = splitPresenceProps(props);
|
|
1223
1271
|
const api = useDatePickerContext();
|
|
1224
|
-
const mergedProps = solid.mergeProps(() => api().contentProps,
|
|
1225
|
-
return web.createComponent(
|
|
1272
|
+
const mergedProps = solid.mergeProps(() => api().contentProps, localProps);
|
|
1273
|
+
return web.createComponent(Presence, web.mergeProps({
|
|
1274
|
+
get present() {
|
|
1275
|
+
return api().isOpen;
|
|
1276
|
+
}
|
|
1277
|
+
}, presenceProps, {
|
|
1278
|
+
get fallback() {
|
|
1279
|
+
return (() => {
|
|
1280
|
+
const _el$ = _tmpl$$g();
|
|
1281
|
+
web.spread(_el$, web.mergeProps(() => api().contentProps), false, false);
|
|
1282
|
+
return _el$;
|
|
1283
|
+
})();
|
|
1284
|
+
},
|
|
1285
|
+
get children() {
|
|
1286
|
+
return web.createComponent(ark.div, mergedProps);
|
|
1287
|
+
}
|
|
1288
|
+
}));
|
|
1226
1289
|
};
|
|
1227
1290
|
|
|
1228
1291
|
const DatePickerControl = props => {
|
|
@@ -1243,14 +1306,14 @@ const DatePickerLabel = props => {
|
|
|
1243
1306
|
return web.createComponent(ark.label, mergedProps);
|
|
1244
1307
|
};
|
|
1245
1308
|
|
|
1246
|
-
const _tmpl$$
|
|
1309
|
+
const _tmpl$$f = /*#__PURE__*/web.template(`<option>`);
|
|
1247
1310
|
const DatePickerMonthSelect = props => {
|
|
1248
1311
|
const api = useDatePickerContext();
|
|
1249
1312
|
const mergedProps = solid.mergeProps(() => api().monthSelectProps, props);
|
|
1250
1313
|
return web.createComponent(ark.select, web.mergeProps(mergedProps, {
|
|
1251
1314
|
get children() {
|
|
1252
1315
|
return api().getMonths().map(month => (() => {
|
|
1253
|
-
const _el$ = _tmpl$$
|
|
1316
|
+
const _el$ = _tmpl$$f();
|
|
1254
1317
|
web.insert(_el$, () => month.label);
|
|
1255
1318
|
web.effect(() => _el$.value = month.value);
|
|
1256
1319
|
return _el$;
|
|
@@ -1395,10 +1458,11 @@ const DatePickerView = props => {
|
|
|
1395
1458
|
const [viewProps, localProps] = createSplitProps()(props, ['view']);
|
|
1396
1459
|
const api = useDatePickerContext();
|
|
1397
1460
|
const getChildren = () => runIfFn(localProps.children, api);
|
|
1461
|
+
const mergedProps = solid.mergeProps(() => anatomy.datePickerAnatomy.build().view.attrs, localProps);
|
|
1398
1462
|
return web.createComponent(DatePickerViewProvider, {
|
|
1399
1463
|
value: viewProps,
|
|
1400
1464
|
get children() {
|
|
1401
|
-
return web.createComponent(ark.div, web.mergeProps(
|
|
1465
|
+
return web.createComponent(ark.div, web.mergeProps(mergedProps, {
|
|
1402
1466
|
get hidden() {
|
|
1403
1467
|
return api().view !== viewProps.view;
|
|
1404
1468
|
},
|
|
@@ -1424,7 +1488,7 @@ const DatePickerViewTrigger = props => {
|
|
|
1424
1488
|
return web.createComponent(ark.button, mergedProps);
|
|
1425
1489
|
};
|
|
1426
1490
|
|
|
1427
|
-
const _tmpl$$
|
|
1491
|
+
const _tmpl$$e = /*#__PURE__*/web.template(`<option>`);
|
|
1428
1492
|
const DatePickerYearSelect = props => {
|
|
1429
1493
|
const api = useDatePickerContext();
|
|
1430
1494
|
const mergedProps = solid.mergeProps(() => api().yearSelectProps, props);
|
|
@@ -1434,7 +1498,7 @@ const DatePickerYearSelect = props => {
|
|
|
1434
1498
|
from: 1_000,
|
|
1435
1499
|
to: 4_000
|
|
1436
1500
|
}).map(year => (() => {
|
|
1437
|
-
const _el$ = _tmpl$$
|
|
1501
|
+
const _el$ = _tmpl$$e();
|
|
1438
1502
|
_el$.value = year;
|
|
1439
1503
|
web.insert(_el$, year);
|
|
1440
1504
|
return _el$;
|
|
@@ -1505,6 +1569,7 @@ const Dialog$1 = props => {
|
|
|
1505
1569
|
});
|
|
1506
1570
|
};
|
|
1507
1571
|
|
|
1572
|
+
const _tmpl$$d = /*#__PURE__*/web.template(`<div>`);
|
|
1508
1573
|
const DialogBackdrop = props => {
|
|
1509
1574
|
const [presenceProps, localProps] = splitPresenceProps(props);
|
|
1510
1575
|
const api = useDialogContext();
|
|
@@ -1514,6 +1579,13 @@ const DialogBackdrop = props => {
|
|
|
1514
1579
|
return api().isOpen;
|
|
1515
1580
|
}
|
|
1516
1581
|
}, presenceProps, {
|
|
1582
|
+
get fallback() {
|
|
1583
|
+
return (() => {
|
|
1584
|
+
const _el$ = _tmpl$$d();
|
|
1585
|
+
web.spread(_el$, web.mergeProps(() => api().backdropProps), false, false);
|
|
1586
|
+
return _el$;
|
|
1587
|
+
})();
|
|
1588
|
+
},
|
|
1517
1589
|
get children() {
|
|
1518
1590
|
return web.createComponent(ark.div, mergedProps);
|
|
1519
1591
|
}
|
|
@@ -1526,6 +1598,7 @@ const DialogCloseTrigger = props => {
|
|
|
1526
1598
|
return web.createComponent(ark.button, triggerProps);
|
|
1527
1599
|
};
|
|
1528
1600
|
|
|
1601
|
+
const _tmpl$$c = /*#__PURE__*/web.template(`<div>`);
|
|
1529
1602
|
const DialogContent = props => {
|
|
1530
1603
|
const [presenceProps, localProps] = splitPresenceProps(props);
|
|
1531
1604
|
const api = useDialogContext();
|
|
@@ -1535,6 +1608,13 @@ const DialogContent = props => {
|
|
|
1535
1608
|
return api().isOpen;
|
|
1536
1609
|
}
|
|
1537
1610
|
}, presenceProps, {
|
|
1611
|
+
get fallback() {
|
|
1612
|
+
return (() => {
|
|
1613
|
+
const _el$ = _tmpl$$c();
|
|
1614
|
+
web.spread(_el$, web.mergeProps(() => api().contentProps), false, false);
|
|
1615
|
+
return _el$;
|
|
1616
|
+
})();
|
|
1617
|
+
},
|
|
1538
1618
|
get children() {
|
|
1539
1619
|
return web.createComponent(ark.div, mergedProps);
|
|
1540
1620
|
}
|
|
@@ -1712,6 +1792,7 @@ const HoverCardArrowTip = props => {
|
|
|
1712
1792
|
return web.createComponent(ark.div, tipProps);
|
|
1713
1793
|
};
|
|
1714
1794
|
|
|
1795
|
+
const _tmpl$$b = /*#__PURE__*/web.template(`<div>`);
|
|
1715
1796
|
const HoverCardContent = props => {
|
|
1716
1797
|
const [presenceProps, localProps] = splitPresenceProps(props);
|
|
1717
1798
|
const api = useHoverCardContext();
|
|
@@ -1721,6 +1802,13 @@ const HoverCardContent = props => {
|
|
|
1721
1802
|
return api().isOpen;
|
|
1722
1803
|
}
|
|
1723
1804
|
}, presenceProps, {
|
|
1805
|
+
get fallback() {
|
|
1806
|
+
return (() => {
|
|
1807
|
+
const _el$ = _tmpl$$b();
|
|
1808
|
+
web.spread(_el$, web.mergeProps(() => api().contentProps), false, false);
|
|
1809
|
+
return _el$;
|
|
1810
|
+
})();
|
|
1811
|
+
},
|
|
1724
1812
|
get children() {
|
|
1725
1813
|
return web.createComponent(ark.div, mergedProps);
|
|
1726
1814
|
}
|
|
@@ -1831,6 +1919,7 @@ const MenuArrowTip = props => {
|
|
|
1831
1919
|
return web.createComponent(ark.div, arrowTipProps);
|
|
1832
1920
|
};
|
|
1833
1921
|
|
|
1922
|
+
const _tmpl$$a = /*#__PURE__*/web.template(`<div>`);
|
|
1834
1923
|
const MenuContent = props => {
|
|
1835
1924
|
const [presenceProps, localProps] = splitPresenceProps(props);
|
|
1836
1925
|
const api = useMenuContext();
|
|
@@ -1840,6 +1929,13 @@ const MenuContent = props => {
|
|
|
1840
1929
|
return api?.().isOpen;
|
|
1841
1930
|
}
|
|
1842
1931
|
}, presenceProps, {
|
|
1932
|
+
get fallback() {
|
|
1933
|
+
return (() => {
|
|
1934
|
+
const _el$ = _tmpl$$a();
|
|
1935
|
+
web.spread(_el$, web.mergeProps(() => api().contentProps), false, false);
|
|
1936
|
+
return _el$;
|
|
1937
|
+
})();
|
|
1938
|
+
},
|
|
1843
1939
|
get children() {
|
|
1844
1940
|
return web.createComponent(ark.div, mergedProps);
|
|
1845
1941
|
}
|
|
@@ -1868,9 +1964,11 @@ const MenuItemGroup = props => {
|
|
|
1868
1964
|
|
|
1869
1965
|
const MenuItemGroupLabel = props => {
|
|
1870
1966
|
const menu = useMenuContext();
|
|
1871
|
-
const [
|
|
1872
|
-
const
|
|
1873
|
-
|
|
1967
|
+
const [labelProps, localProps] = createSplitProps()(props, ['for']);
|
|
1968
|
+
const mergedProps = solid.mergeProps(() => menu?.().getItemGroupLabelProps({
|
|
1969
|
+
htmlFor: labelProps.for
|
|
1970
|
+
}), localProps);
|
|
1971
|
+
return web.createComponent(ark.div, mergedProps);
|
|
1874
1972
|
};
|
|
1875
1973
|
|
|
1876
1974
|
const MenuOptionItem = props => {
|
|
@@ -2087,7 +2185,7 @@ const usePinInput = props => {
|
|
|
2087
2185
|
return solidJs.createMemo(() => pinInput__namespace.connect(state, send, solid.normalizeProps));
|
|
2088
2186
|
};
|
|
2089
2187
|
|
|
2090
|
-
const _tmpl$$
|
|
2188
|
+
const _tmpl$$9 = /*#__PURE__*/web.template(`<input>`);
|
|
2091
2189
|
const PinInput$1 = props => {
|
|
2092
2190
|
const [pinInputProps, localProps] = createSplitProps()(props, ['autoFocus', 'blurOnComplete', 'dir', 'disabled', 'form', 'getRootNode', 'id', 'ids', 'invalid', 'mask', 'name', 'onValueChange', 'onValueComplete', 'onValueInvalid', 'otp', 'pattern', 'placeholder', 'selectOnFocus', 'translations', 'type', 'value']);
|
|
2093
2191
|
const api = usePinInput(pinInputProps);
|
|
@@ -2096,7 +2194,7 @@ const PinInput$1 = props => {
|
|
|
2096
2194
|
value: api,
|
|
2097
2195
|
get children() {
|
|
2098
2196
|
return [web.createComponent(ark.div, mergedProps), (() => {
|
|
2099
|
-
const _el$ = _tmpl$$
|
|
2197
|
+
const _el$ = _tmpl$$9();
|
|
2100
2198
|
web.spread(_el$, web.mergeProps(() => api().hiddenInputProps), false, false);
|
|
2101
2199
|
return _el$;
|
|
2102
2200
|
})()];
|
|
@@ -2182,6 +2280,7 @@ const PopoverCloseTrigger = props => {
|
|
|
2182
2280
|
return web.createComponent(ark.button, triggerProps);
|
|
2183
2281
|
};
|
|
2184
2282
|
|
|
2283
|
+
const _tmpl$$8 = /*#__PURE__*/web.template(`<div>`);
|
|
2185
2284
|
const PopoverContent = props => {
|
|
2186
2285
|
const [presenceProps, localProps] = splitPresenceProps(props);
|
|
2187
2286
|
const api = usePopoverContext();
|
|
@@ -2191,6 +2290,13 @@ const PopoverContent = props => {
|
|
|
2191
2290
|
return api().isOpen;
|
|
2192
2291
|
}
|
|
2193
2292
|
}, presenceProps, {
|
|
2293
|
+
get fallback() {
|
|
2294
|
+
return (() => {
|
|
2295
|
+
const _el$ = _tmpl$$8();
|
|
2296
|
+
web.spread(_el$, web.mergeProps(() => api().contentProps), false, false);
|
|
2297
|
+
return _el$;
|
|
2298
|
+
})();
|
|
2299
|
+
},
|
|
2194
2300
|
get children() {
|
|
2195
2301
|
return web.createComponent(ark.div, mergedProps);
|
|
2196
2302
|
}
|
|
@@ -2293,13 +2399,13 @@ const RadioGroupItem = props => {
|
|
|
2293
2399
|
});
|
|
2294
2400
|
};
|
|
2295
2401
|
|
|
2296
|
-
const _tmpl$$
|
|
2402
|
+
const _tmpl$$7 = /*#__PURE__*/web.template(`<input>`);
|
|
2297
2403
|
const RadioGroupItemControl = props => {
|
|
2298
2404
|
const api = useRadioGroupContext();
|
|
2299
2405
|
const itemProps = useRadioGroupItemContext();
|
|
2300
2406
|
const mergedProps = solid.mergeProps(() => api().getItemControlProps(itemProps), props);
|
|
2301
2407
|
return [web.createComponent(ark.div, mergedProps), (() => {
|
|
2302
|
-
const _el$ = _tmpl$$
|
|
2408
|
+
const _el$ = _tmpl$$7();
|
|
2303
2409
|
web.spread(_el$, web.mergeProps(() => api().getItemHiddenInputProps(itemProps)), false, false);
|
|
2304
2410
|
return _el$;
|
|
2305
2411
|
})()];
|
|
@@ -2356,7 +2462,7 @@ const RatingGroup$1 = props => {
|
|
|
2356
2462
|
});
|
|
2357
2463
|
};
|
|
2358
2464
|
|
|
2359
|
-
const _tmpl$$
|
|
2465
|
+
const _tmpl$$6 = /*#__PURE__*/web.template(`<input>`);
|
|
2360
2466
|
const RatingGroupControl = props => {
|
|
2361
2467
|
const api = useRatingGroupContext();
|
|
2362
2468
|
const getChildren = () => runIfFn(props.children, api);
|
|
@@ -2366,7 +2472,7 @@ const RatingGroupControl = props => {
|
|
|
2366
2472
|
return getChildren();
|
|
2367
2473
|
}
|
|
2368
2474
|
})), (() => {
|
|
2369
|
-
const _el$ = _tmpl$$
|
|
2475
|
+
const _el$ = _tmpl$$6();
|
|
2370
2476
|
web.spread(_el$, web.mergeProps(() => api().hiddenInputProps), false, false);
|
|
2371
2477
|
return _el$;
|
|
2372
2478
|
})()];
|
|
@@ -2460,13 +2566,13 @@ const SegmentGroupItem = props => {
|
|
|
2460
2566
|
});
|
|
2461
2567
|
};
|
|
2462
2568
|
|
|
2463
|
-
const _tmpl$$
|
|
2569
|
+
const _tmpl$$5 = /*#__PURE__*/web.template(`<input>`);
|
|
2464
2570
|
const SegmentGroupItemControl = props => {
|
|
2465
2571
|
const api = useSegmentGroupContext();
|
|
2466
2572
|
const itemProps = useSegmentGroupItemContext();
|
|
2467
2573
|
const mergedProps = solid.mergeProps(() => api().getItemControlProps(itemProps), anatomy.segmentGroupAnatomy.build().itemControl.attrs, props);
|
|
2468
2574
|
return [web.createComponent(ark.div, mergedProps), (() => {
|
|
2469
|
-
const _el$ = _tmpl$$
|
|
2575
|
+
const _el$ = _tmpl$$5();
|
|
2470
2576
|
web.spread(_el$, web.mergeProps(() => api().getItemHiddenInputProps(itemProps)), false, false);
|
|
2471
2577
|
return _el$;
|
|
2472
2578
|
})()];
|
|
@@ -2538,6 +2644,7 @@ const SelectClearTrigger = props => {
|
|
|
2538
2644
|
return web.createComponent(ark.button, mergedProps);
|
|
2539
2645
|
};
|
|
2540
2646
|
|
|
2647
|
+
const _tmpl$$4 = /*#__PURE__*/web.template(`<div>`);
|
|
2541
2648
|
const SelectContent = props => {
|
|
2542
2649
|
const [presenceProps, localProps] = splitPresenceProps(props);
|
|
2543
2650
|
const api = useSelectContext();
|
|
@@ -2547,16 +2654,40 @@ const SelectContent = props => {
|
|
|
2547
2654
|
return api().isOpen;
|
|
2548
2655
|
}
|
|
2549
2656
|
}, presenceProps, {
|
|
2657
|
+
get fallback() {
|
|
2658
|
+
return (() => {
|
|
2659
|
+
const _el$ = _tmpl$$4();
|
|
2660
|
+
web.spread(_el$, web.mergeProps(() => api().contentProps), false, false);
|
|
2661
|
+
return _el$;
|
|
2662
|
+
})();
|
|
2663
|
+
},
|
|
2550
2664
|
get children() {
|
|
2551
2665
|
return web.createComponent(ark.div, mergedProps);
|
|
2552
2666
|
}
|
|
2553
2667
|
}));
|
|
2554
2668
|
};
|
|
2555
2669
|
|
|
2670
|
+
const _tmpl$$3 = /*#__PURE__*/web.template(`<select>`),
|
|
2671
|
+
_tmpl$2 = /*#__PURE__*/web.template(`<option>`);
|
|
2556
2672
|
const SelectControl = props => {
|
|
2557
2673
|
const api = useSelectContext();
|
|
2558
2674
|
const mergedProps = solid.mergeProps(() => api().controlProps, props);
|
|
2559
|
-
return web.createComponent(ark.div, mergedProps)
|
|
2675
|
+
return [web.createComponent(ark.div, mergedProps), (() => {
|
|
2676
|
+
const _el$ = _tmpl$$3();
|
|
2677
|
+
web.spread(_el$, web.mergeProps(() => api().hiddenSelectProps), false, true);
|
|
2678
|
+
web.insert(_el$, web.createComponent(solidJs.Index, {
|
|
2679
|
+
get each() {
|
|
2680
|
+
return api().collection.toArray();
|
|
2681
|
+
},
|
|
2682
|
+
children: option => (() => {
|
|
2683
|
+
const _el$2 = _tmpl$2();
|
|
2684
|
+
web.insert(_el$2, () => option().label);
|
|
2685
|
+
web.effect(() => _el$2.value = option().value);
|
|
2686
|
+
return _el$2;
|
|
2687
|
+
})()
|
|
2688
|
+
}));
|
|
2689
|
+
return _el$;
|
|
2690
|
+
})()];
|
|
2560
2691
|
};
|
|
2561
2692
|
|
|
2562
2693
|
const SelectIndicator = props => {
|
|
@@ -2595,9 +2726,11 @@ const SelectItemGroup = props => {
|
|
|
2595
2726
|
};
|
|
2596
2727
|
|
|
2597
2728
|
const SelectItemGroupLabel = props => {
|
|
2598
|
-
const [labelProps, localProps] = createSplitProps()(props, ['
|
|
2729
|
+
const [labelProps, localProps] = createSplitProps()(props, ['for']);
|
|
2599
2730
|
const api = useSelectContext();
|
|
2600
|
-
const mergedProps = solid.mergeProps(() => api().getItemGroupLabelProps(
|
|
2731
|
+
const mergedProps = solid.mergeProps(() => api().getItemGroupLabelProps({
|
|
2732
|
+
htmlFor: labelProps.for
|
|
2733
|
+
}), localProps);
|
|
2601
2734
|
return web.createComponent(ark.div, mergedProps);
|
|
2602
2735
|
};
|
|
2603
2736
|
|
|
@@ -2719,17 +2852,6 @@ const SliderMarkerGroup = props => {
|
|
|
2719
2852
|
return web.createComponent(ark.div, mergedProps);
|
|
2720
2853
|
};
|
|
2721
2854
|
|
|
2722
|
-
const SliderOutput = props => {
|
|
2723
|
-
const slider = useSliderContext();
|
|
2724
|
-
const getChildren = () => runIfFn(props.children, slider);
|
|
2725
|
-
const outputProps = solid.mergeProps(() => slider().outputProps, props);
|
|
2726
|
-
return web.createComponent(ark.output, web.mergeProps(outputProps, {
|
|
2727
|
-
get children() {
|
|
2728
|
-
return getChildren();
|
|
2729
|
-
}
|
|
2730
|
-
}));
|
|
2731
|
-
};
|
|
2732
|
-
|
|
2733
2855
|
const SliderRange = props => {
|
|
2734
2856
|
const api = useSliderContext();
|
|
2735
2857
|
const mergedProps = solid.mergeProps(() => api().rangeProps, props);
|
|
@@ -2749,16 +2871,27 @@ const SliderTrack = props => {
|
|
|
2749
2871
|
return web.createComponent(ark.div, mergedProps);
|
|
2750
2872
|
};
|
|
2751
2873
|
|
|
2874
|
+
const SliderValueText = props => {
|
|
2875
|
+
const api = useSliderContext();
|
|
2876
|
+
const getChildren = () => runIfFn(props.children, api);
|
|
2877
|
+
const mergedProps = solid.mergeProps(() => api().valueTextProps, props);
|
|
2878
|
+
return web.createComponent(ark.div, web.mergeProps(mergedProps, {
|
|
2879
|
+
get children() {
|
|
2880
|
+
return getChildren();
|
|
2881
|
+
}
|
|
2882
|
+
}));
|
|
2883
|
+
};
|
|
2884
|
+
|
|
2752
2885
|
const Slider = Object.assign(Slider$1, {
|
|
2753
2886
|
Root: Slider$1,
|
|
2754
2887
|
Control: SliderControl,
|
|
2755
2888
|
Label: SliderLabel,
|
|
2756
2889
|
Marker: SliderMarker,
|
|
2757
2890
|
MarkerGroup: SliderMarkerGroup,
|
|
2758
|
-
Output: SliderOutput,
|
|
2759
2891
|
Range: SliderRange,
|
|
2760
2892
|
Thumb: SliderThumb,
|
|
2761
|
-
Track: SliderTrack
|
|
2893
|
+
Track: SliderTrack,
|
|
2894
|
+
ValueText: SliderValueText
|
|
2762
2895
|
});
|
|
2763
2896
|
|
|
2764
2897
|
const [SplitterProvider, useSplitterContext] = createContext({
|
|
@@ -2849,12 +2982,12 @@ const Switch$1 = props => {
|
|
|
2849
2982
|
});
|
|
2850
2983
|
};
|
|
2851
2984
|
|
|
2852
|
-
const _tmpl$$
|
|
2985
|
+
const _tmpl$$2 = /*#__PURE__*/web.template(`<input>`);
|
|
2853
2986
|
const SwitchControl = props => {
|
|
2854
2987
|
const api = useSwitchContext();
|
|
2855
2988
|
const mergedProps = solid.mergeProps(() => api().controlProps, props);
|
|
2856
2989
|
return [web.createComponent(ark.span, mergedProps), (() => {
|
|
2857
|
-
const _el$ = _tmpl$$
|
|
2990
|
+
const _el$ = _tmpl$$2();
|
|
2858
2991
|
web.spread(_el$, web.mergeProps(() => api().hiddenInputProps), false, false);
|
|
2859
2992
|
return _el$;
|
|
2860
2993
|
})()];
|
|
@@ -2973,7 +3106,7 @@ const useTagsInput = props => {
|
|
|
2973
3106
|
return solidJs.createMemo(() => tagsInput__namespace.connect(state, send, solid.normalizeProps));
|
|
2974
3107
|
};
|
|
2975
3108
|
|
|
2976
|
-
const _tmpl
|
|
3109
|
+
const _tmpl$$1 = /*#__PURE__*/web.template(`<input>`);
|
|
2977
3110
|
const TagsInput$1 = props => {
|
|
2978
3111
|
const [tagsInputParams, restProps] = createSplitProps()(props, ['addOnPaste', 'allowEditTag', 'allowOverflow', 'autoFocus', 'blurBehavior', 'delimiter', 'dir', 'disabled', 'form', 'getRootNode', 'id', 'ids', 'inputValue', 'invalid', 'max', 'maxLength', 'name', 'onFocusOutside', 'onHighlightChange', 'onInteractOutside', 'onPointerDownOutside', 'onValueChange', 'onValueInvalid', 'readOnly', 'translations', 'validate', 'value']);
|
|
2979
3112
|
const api = useTagsInput(tagsInputParams);
|
|
@@ -2987,7 +3120,7 @@ const TagsInput$1 = props => {
|
|
|
2987
3120
|
return getChildren();
|
|
2988
3121
|
}
|
|
2989
3122
|
})), (() => {
|
|
2990
|
-
const _el$ = _tmpl
|
|
3123
|
+
const _el$ = _tmpl$$1();
|
|
2991
3124
|
web.spread(_el$, web.mergeProps(() => api().hiddenInputProps), false, false);
|
|
2992
3125
|
return _el$;
|
|
2993
3126
|
})()];
|
|
@@ -3079,8 +3212,6 @@ const [ToastProvider, useToastContext] = createContext({
|
|
|
3079
3212
|
providerName: '<ToastProvider />'
|
|
3080
3213
|
});
|
|
3081
3214
|
|
|
3082
|
-
// TODO simplify types after next zag.js upgrade
|
|
3083
|
-
|
|
3084
3215
|
const createToaster = props => {
|
|
3085
3216
|
const {
|
|
3086
3217
|
placement,
|
|
@@ -3243,6 +3374,7 @@ const TooltipArrowTip = props => {
|
|
|
3243
3374
|
return web.createComponent(ark.div, arrowTipProps);
|
|
3244
3375
|
};
|
|
3245
3376
|
|
|
3377
|
+
const _tmpl$ = /*#__PURE__*/web.template(`<div>`);
|
|
3246
3378
|
const TooltipContent = props => {
|
|
3247
3379
|
const [presenceProps, localProps] = splitPresenceProps(props);
|
|
3248
3380
|
const api = useTooltipContext();
|
|
@@ -3252,6 +3384,13 @@ const TooltipContent = props => {
|
|
|
3252
3384
|
return api().isOpen;
|
|
3253
3385
|
}
|
|
3254
3386
|
}, presenceProps, {
|
|
3387
|
+
get fallback() {
|
|
3388
|
+
return (() => {
|
|
3389
|
+
const _el$ = _tmpl$();
|
|
3390
|
+
web.spread(_el$, web.mergeProps(() => api().contentProps), false, false);
|
|
3391
|
+
return _el$;
|
|
3392
|
+
})();
|
|
3393
|
+
},
|
|
3255
3394
|
get children() {
|
|
3256
3395
|
return web.createComponent(ark.div, contentProps);
|
|
3257
3396
|
}
|
|
@@ -3318,6 +3457,7 @@ exports.ColorPickerSwatchGroup = ColorPickerSwatchGroup;
|
|
|
3318
3457
|
exports.ColorPickerSwatchTrigger = ColorPickerSwatchTrigger;
|
|
3319
3458
|
exports.ColorPickerTransparencyGrid = ColorPickerTransparencyGrid;
|
|
3320
3459
|
exports.ColorPickerTrigger = ColorPickerTrigger;
|
|
3460
|
+
exports.ColorPickerValueText = ColorPickerValueText;
|
|
3321
3461
|
exports.Combobox = Combobox;
|
|
3322
3462
|
exports.ComboboxClearTrigger = ComboboxClearTrigger;
|
|
3323
3463
|
exports.ComboboxContent = ComboboxContent;
|
|
@@ -3453,10 +3593,10 @@ exports.SliderControl = SliderControl;
|
|
|
3453
3593
|
exports.SliderLabel = SliderLabel;
|
|
3454
3594
|
exports.SliderMarker = SliderMarker;
|
|
3455
3595
|
exports.SliderMarkerGroup = SliderMarkerGroup;
|
|
3456
|
-
exports.SliderOutput = SliderOutput;
|
|
3457
3596
|
exports.SliderRange = SliderRange;
|
|
3458
3597
|
exports.SliderThumb = SliderThumb;
|
|
3459
3598
|
exports.SliderTrack = SliderTrack;
|
|
3599
|
+
exports.SliderValueText = SliderValueText;
|
|
3460
3600
|
exports.Splitter = Splitter;
|
|
3461
3601
|
exports.SplitterPanel = SplitterPanel;
|
|
3462
3602
|
exports.SplitterResizeTrigger = SplitterResizeTrigger;
|