@okam/stack-ui 1.29.0 → 1.30.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/components/Accordion/components/AccordionItem.d.ts +1 -0
- package/components/Accordion/index.d.ts +2 -1
- package/components/Accordion/interface.d.ts +3 -2
- package/components/Alerts/components/AlertsCloseButton.d.ts +1 -1
- package/components/Alerts/index.d.ts +2 -1
- package/components/Alerts/interface.d.ts +4 -3
- package/components/Box/index.d.ts +3 -2
- package/components/Button/index.d.ts +8 -4
- package/components/Button/interface.d.ts +3 -2
- package/components/Calendar/index.d.ts +5 -1
- package/components/Calendar/interface.d.ts +2 -1
- package/components/Carousel/components/CarouselNavigationButton.d.ts +3 -3
- package/components/Date/index.d.ts +2 -1
- package/components/Date/interface.d.ts +2 -1
- package/components/Icon/index.d.ts +2 -1
- package/components/Icon/interface.d.ts +2 -1
- package/components/Lightbox/hooks/overlay/index.d.ts +75 -0
- package/components/Lightbox/index.d.ts +2 -1
- package/components/Lightbox/interface.d.ts +3 -2
- package/components/Menu/Menu.d.ts +2 -1
- package/components/Menu/interface.d.ts +5 -4
- package/components/Modal/index.d.ts +2 -1
- package/components/Modal/interface.d.ts +2 -1
- package/components/Popover/index.d.ts +2 -1
- package/components/Popover/interface.d.ts +3 -2
- package/components/ShareButton/index.d.ts +2 -1
- package/components/ShareButton/interface.d.ts +2 -2
- package/components/SidePanel/index.d.ts +3 -3
- package/components/SidePanel/interface.d.ts +5 -4
- package/components/Typography/index.d.ts +3 -2
- package/components/Video/index.d.ts +2 -1
- package/components/Video/interface.d.ts +2 -1
- package/components/WysiwygBlock/attributes.d.ts +2 -0
- package/components/WysiwygBlock/index.d.ts +2 -1
- package/components/WysiwygBlock/interface.d.ts +2 -1
- package/components/fields/Checkbox/Checkbox.interface.d.ts +2 -1
- package/components/fields/Checkbox/index.d.ts +2 -1
- package/components/fields/CheckboxGroup/index.d.ts +2 -1
- package/components/fields/CheckboxGroup/interface.d.ts +2 -1
- package/components/fields/DatePicker/index.d.ts +2 -1
- package/components/fields/DatePicker/interface.d.ts +2 -1
- package/components/fields/Radio/Radio.interface.d.ts +3 -2
- package/components/fields/Radio/index.d.ts +3 -2
- package/components/fields/RadioGroup/index.d.ts +2 -1
- package/components/fields/RadioGroup/interface.d.ts +2 -1
- package/components/fields/SearchField/index.d.ts +2 -1
- package/components/fields/SearchField/interface.d.ts +2 -1
- package/components/fields/Select/Select.d.ts +2 -1
- package/components/fields/Select/Select.interface.d.ts +3 -2
- package/components/fields/TextArea/index.d.ts +2 -1
- package/components/fields/TextInputField/interface.d.ts +3 -2
- package/index.d.ts +1 -0
- package/index.js +1 -1
- package/index.mjs +41 -38
- package/index100.js +1 -2
- package/index100.mjs +22 -21
- package/index101.js +2 -1
- package/index101.mjs +22 -63
- package/index102.js +1 -1
- package/index102.mjs +58 -24
- package/index103.js +1 -1
- package/index103.mjs +29 -4
- package/index104.js +1 -1
- package/index104.mjs +52 -11
- package/index105.js +1 -1
- package/index105.mjs +4 -14
- package/index106.js +1 -1
- package/index106.mjs +11 -23
- package/index107.js +1 -1
- package/index107.mjs +13 -22
- package/index108.js +1 -1
- package/index108.mjs +23 -39
- package/index109.js +1 -2
- package/index109.mjs +22 -12
- package/index11.js +1 -1
- package/index11.mjs +2 -2
- package/index110.js +1 -1
- package/index110.mjs +38 -7
- package/index111.js +2 -1
- package/index111.mjs +12 -21
- package/index112.js +1 -1
- package/index112.mjs +7 -38
- package/index113.js +1 -1
- package/index113.mjs +20 -48
- package/index114.js +1 -1
- package/index114.mjs +38 -40
- package/index115.js +1 -1
- package/index115.mjs +47 -11
- package/index116.js +1 -1
- package/index116.mjs +41 -26
- package/index117.js +1 -1
- package/index117.mjs +14 -20
- package/index118.js +1 -1
- package/index118.mjs +30 -8
- package/index119.js +1 -1
- package/index119.mjs +20 -30
- package/index120.js +1 -1
- package/index120.mjs +8 -14
- package/index121.js +1 -1
- package/index121.mjs +29 -16
- package/index122.js +1 -1
- package/index122.mjs +15 -21
- package/index123.js +1 -1
- package/index123.mjs +17 -11
- package/index124.js +1 -2
- package/index124.mjs +20 -21
- package/index125.js +1 -1
- package/index125.mjs +11 -12
- package/index126.js +2 -1
- package/index126.mjs +22 -46
- package/index127.js +1 -1
- package/index127.mjs +12 -241
- package/index128.js +1 -2
- package/index128.mjs +46 -13
- package/index129.js +1 -1
- package/index129.mjs +239 -28
- package/index13.js +1 -1
- package/index13.mjs +8 -5
- package/index130.js +2 -1
- package/index130.mjs +13 -51
- package/index131.js +1 -1
- package/index131.mjs +30 -27
- package/index132.js +1 -1
- package/index132.mjs +49 -19
- package/index133.js +1 -1
- package/index133.mjs +26 -61
- package/index134.js +1 -1
- package/index134.mjs +17 -91
- package/index135.js +1 -1
- package/index135.mjs +59 -29
- package/index136.js +1 -1
- package/index136.mjs +90 -117
- package/index137.js +1 -1
- package/index137.mjs +32 -26
- package/index138.js +1 -1
- package/index138.mjs +118 -121
- package/index139.js +1 -1
- package/index139.mjs +27 -134
- package/index14.js +1 -1
- package/index14.mjs +3 -3
- package/index140.js +1 -1
- package/index140.mjs +122 -12
- package/index141.js +1 -1
- package/index141.mjs +131 -92
- package/index142.js +1 -1
- package/index142.mjs +12 -104
- package/index143.js +1 -1
- package/index143.mjs +95 -5
- package/index144.js +1 -1
- package/index144.mjs +106 -3
- package/index145.js +1 -1
- package/index145.mjs +5 -125
- package/index146.js +1 -1
- package/index146.mjs +3 -29
- package/index147.js +1 -1
- package/index147.mjs +113 -39
- package/index148.js +1 -1
- package/index148.mjs +19 -34
- package/index149.js +1 -1
- package/index149.mjs +40 -26
- package/index150.js +1 -1
- package/index150.mjs +29 -98
- package/index151.js +1 -1
- package/index151.mjs +28 -68
- package/index152.js +1 -1
- package/index152.mjs +90 -78
- package/index153.js +1 -1
- package/index153.mjs +78 -98
- package/index154.js +1 -1
- package/index154.mjs +101 -199
- package/index155.js +1 -1
- package/index155.mjs +98 -65
- package/index156.js +1 -1
- package/index156.mjs +185 -127
- package/index157.js +1 -1
- package/index157.mjs +54 -109
- package/index158.js +1 -1
- package/index158.mjs +126 -202
- package/index159.js +1 -1
- package/index159.mjs +104 -175
- package/index16.js +1 -1
- package/index16.mjs +2 -2
- package/index160.js +1 -1
- package/index160.mjs +208 -60
- package/index161.js +1 -1
- package/index161.mjs +178 -246
- package/index162.js +1 -1
- package/index162.mjs +63 -91
- package/index163.js +1 -1
- package/index163.mjs +250 -166
- package/index164.js +1 -1
- package/index164.mjs +91 -78
- package/index165.js +1 -1
- package/index165.mjs +170 -54
- package/index166.js +1 -1
- package/index166.mjs +72 -114
- package/index167.js +1 -1
- package/index167.mjs +51 -109
- package/index168.js +1 -1
- package/index168.mjs +112 -108
- package/index169.js +1 -1
- package/index169.mjs +109 -65
- package/index170.js +1 -1
- package/index170.mjs +117 -105
- package/index171.js +1 -1
- package/index171.mjs +68 -48
- package/index172.js +1 -1
- package/index172.mjs +108 -91
- package/index173.js +1 -1
- package/index173.mjs +37 -55
- package/index174.js +1 -1
- package/index174.mjs +80 -43
- package/index175.js +1 -1
- package/index175.mjs +52 -81
- package/index176.js +1 -5
- package/index176.mjs +42 -66
- package/index177.js +1 -1
- package/index177.mjs +87 -1999
- package/index178.js +5 -1
- package/index178.mjs +79 -58
- package/index179.js +1 -1
- package/index179.mjs +1998 -175
- package/index18.js +1 -1
- package/index18.mjs +7 -7
- package/index180.js +1 -1
- package/index180.mjs +59 -5
- package/index181.js +1 -1
- package/index181.mjs +183 -125
- package/index182.js +1 -1
- package/index182.mjs +5 -179
- package/index183.js +1 -1
- package/index183.mjs +129 -8
- package/index184.js +1 -1
- package/index184.mjs +179 -3
- package/index185.js +1 -1
- package/index185.mjs +8 -35
- package/index186.js +1 -1
- package/index186.mjs +3 -5
- package/index187.js +1 -1
- package/index187.mjs +35 -28
- package/index188.js +1 -1
- package/index188.mjs +5 -6
- package/index189.js +1 -1
- package/index189.mjs +26 -310
- package/index19.js +1 -1
- package/index19.mjs +2 -2
- package/index190.js +1 -1
- package/index190.mjs +6 -192
- package/index191.js +1 -1
- package/index191.mjs +339 -7
- package/index192.js +1 -1
- package/index192.mjs +180 -23
- package/index193.js +1 -1
- package/index193.mjs +6 -53
- package/index194.js +1 -1
- package/index194.mjs +24 -44
- package/index195.js +1 -1
- package/index195.mjs +55 -124
- package/index196.js +1 -1
- package/index196.mjs +46 -5
- package/index197.js +1 -1
- package/index197.mjs +108 -26
- package/index198.js +1 -1
- package/index198.mjs +32 -6
- package/index199.js +1 -1
- package/index199.mjs +5 -7
- package/index2.js +1 -1
- package/index2.mjs +19 -19
- package/index20.js +1 -1
- package/index20.mjs +1 -1
- package/index200.js +1 -1
- package/index200.mjs +28 -7
- package/index201.js +1 -1
- package/index201.mjs +7 -5
- package/index202.js +1 -1
- package/index202.mjs +7 -5
- package/index203.js +1 -1
- package/index203.mjs +7 -9
- package/index204.js +1 -0
- package/index204.mjs +7 -0
- package/index205.js +1 -0
- package/index205.mjs +8 -0
- package/index206.js +1 -0
- package/index206.mjs +12 -0
- package/index21.js +1 -1
- package/index21.mjs +8 -8
- package/index22.js +1 -1
- package/index22.mjs +2 -2
- package/index23.js +1 -1
- package/index23.mjs +3 -3
- package/index24.js +1 -1
- package/index24.mjs +14 -14
- package/index26.js +1 -1
- package/index26.mjs +28 -21
- package/index27.js +1 -1
- package/index27.mjs +12 -12
- package/index28.js +1 -1
- package/index28.mjs +6 -6
- package/index29.js +1 -1
- package/index29.mjs +1 -1
- package/index30.js +1 -1
- package/index30.mjs +14 -8
- package/index31.js +1 -1
- package/index31.mjs +18 -18
- package/index32.js +1 -1
- package/index32.mjs +1 -1
- package/index33.mjs +43 -43
- package/index34.js +1 -1
- package/index34.mjs +1 -1
- package/index35.js +1 -1
- package/index35.mjs +3 -3
- package/index36.mjs +10 -10
- package/index4.js +1 -1
- package/index4.mjs +3 -3
- package/index6.js +1 -1
- package/index6.mjs +34 -33
- package/index65.js +1 -1
- package/index65.mjs +1 -1
- package/index66.js +1 -1
- package/index66.mjs +2 -2
- package/index67.js +1 -1
- package/index67.mjs +1 -1
- package/index69.js +1 -1
- package/index69.mjs +1 -1
- package/index7.mjs +4 -4
- package/index70.js +1 -1
- package/index70.mjs +1 -1
- package/index71.js +1 -1
- package/index71.mjs +1 -1
- package/index72.js +2 -1
- package/index72.mjs +27 -2
- package/index73.js +1 -2
- package/index73.mjs +2 -9
- package/index74.js +1 -1
- package/index74.mjs +7 -6
- package/index75.js +1 -1
- package/index75.mjs +6 -6
- package/index76.js +1 -1
- package/index76.mjs +6 -6
- package/index77.js +2 -1
- package/index77.mjs +8 -25
- package/index78.js +1 -1
- package/index78.mjs +25 -2
- package/index79.js +1 -6
- package/index79.mjs +2 -94
- package/index8.js +1 -1
- package/index8.mjs +42 -23
- package/index80.js +6 -1
- package/index80.mjs +79 -54
- package/index81.js +1 -1
- package/index81.mjs +61 -33
- package/index82.js +1 -42
- package/index82.mjs +34 -67
- package/index83.js +42 -1
- package/index83.mjs +69 -154
- package/index84.js +1 -9
- package/index84.mjs +149 -47
- package/index85.js +9 -1
- package/index85.mjs +48 -36
- package/index86.js +1 -1
- package/index86.mjs +40 -8
- package/index87.js +1 -1
- package/index87.mjs +9 -31
- package/index88.js +1 -1
- package/index88.mjs +35 -6
- package/index89.js +1 -12
- package/index89.mjs +6 -40
- package/index9.js +1 -1
- package/index9.mjs +7 -7
- package/index90.js +12 -1
- package/index90.mjs +36 -25
- package/index91.js +1 -1
- package/index91.mjs +24 -8
- package/index92.js +1 -7
- package/index92.mjs +7 -13
- package/index93.js +6 -14
- package/index93.mjs +13 -65
- package/index94.js +15 -1
- package/index94.mjs +71 -7
- package/index95.js +1 -16
- package/index95.mjs +7 -25
- package/index96.js +16 -1
- package/index96.mjs +20 -37
- package/index97.js +1 -1
- package/index97.mjs +40 -43
- package/index98.js +1 -1
- package/index98.mjs +44 -47
- package/index99.js +1 -1
- package/index99.mjs +48 -17
- package/package.json +1 -1
- package/providers/Translation/index.d.ts +4 -0
- package/providers/Translation/interface.d.ts +16 -0
- package/theme/Accordion/index.d.ts +12 -12
- package/theme/Alerts/index.d.ts +22 -22
- package/theme/Box/index.d.ts +8 -8
- package/theme/Button/index.d.ts +2 -2
- package/theme/Calendar/index.d.ts +12 -12
- package/theme/Carousel/index.d.ts +11 -11
- package/theme/Checkbox/index.d.ts +8 -8
- package/theme/CheckboxGroup/index.d.ts +3 -3
- package/theme/DatePicker/index.d.ts +9 -9
- package/theme/Image/index.d.ts +1 -1
- package/theme/LightBox/index.d.ts +9 -9
- package/theme/Radio/index.d.ts +6 -6
- package/theme/RadioGroup/index.d.ts +3 -3
- package/theme/Search/index.d.ts +3 -3
- package/theme/ShareButton/index.d.ts +10 -10
- package/theme/SidePanel/index.d.ts +3 -3
- package/theme/TextArea/index.d.ts +2 -2
- package/theme/Typography/index.d.ts +2 -2
- package/transitions/ModalTransition.d.ts +3 -6
- package/transitions/RenderWithSlide.d.ts +3 -6
- package/transitions/SidePanelTransition.d.ts +3 -6
package/index196.mjs
CHANGED
|
@@ -1,8 +1,49 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
1
|
+
import { usePress as m } from "./index191.mjs";
|
|
2
|
+
import { useGlobalListeners as g, useDescription as b, mergeProps as L } from "@react-aria/utils";
|
|
3
|
+
import { useRef as y } from "react";
|
|
4
|
+
const T = 500;
|
|
5
|
+
function E(a) {
|
|
6
|
+
let { isDisabled: o, onLongPressStart: s, onLongPressEnd: n, onLongPress: r, threshold: c = T, accessibilityDescription: u } = a;
|
|
7
|
+
const t = y(void 0);
|
|
8
|
+
let { addGlobalListener: i, removeGlobalListener: l } = g(), { pressProps: d } = m({
|
|
9
|
+
isDisabled: o,
|
|
10
|
+
onPressStart(e) {
|
|
11
|
+
if (e.continuePropagation(), (e.pointerType === "mouse" || e.pointerType === "touch") && (s && s({
|
|
12
|
+
...e,
|
|
13
|
+
type: "longpressstart"
|
|
14
|
+
}), t.current = setTimeout(() => {
|
|
15
|
+
e.target.dispatchEvent(new PointerEvent("pointercancel", {
|
|
16
|
+
bubbles: !0
|
|
17
|
+
})), r && r({
|
|
18
|
+
...e,
|
|
19
|
+
type: "longpress"
|
|
20
|
+
}), t.current = void 0;
|
|
21
|
+
}, c), e.pointerType === "touch")) {
|
|
22
|
+
let p = (P) => {
|
|
23
|
+
P.preventDefault();
|
|
24
|
+
};
|
|
25
|
+
i(e.target, "contextmenu", p, {
|
|
26
|
+
once: !0
|
|
27
|
+
}), i(window, "pointerup", () => {
|
|
28
|
+
setTimeout(() => {
|
|
29
|
+
l(e.target, "contextmenu", p);
|
|
30
|
+
}, 30);
|
|
31
|
+
}, {
|
|
32
|
+
once: !0
|
|
33
|
+
});
|
|
34
|
+
}
|
|
35
|
+
},
|
|
36
|
+
onPressEnd(e) {
|
|
37
|
+
t.current && clearTimeout(t.current), n && (e.pointerType === "mouse" || e.pointerType === "touch") && n({
|
|
38
|
+
...e,
|
|
39
|
+
type: "longpressend"
|
|
40
|
+
});
|
|
41
|
+
}
|
|
42
|
+
}), f = b(r && !o ? u : void 0);
|
|
43
|
+
return {
|
|
44
|
+
longPressProps: L(d, f)
|
|
45
|
+
};
|
|
4
46
|
}
|
|
5
47
|
export {
|
|
6
|
-
|
|
7
|
-
f as tabsIds
|
|
48
|
+
E as useLongPress
|
|
8
49
|
};
|
package/index197.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const o=require("./index198.js"),r=require("@react-aria/utils");class h{isDisabled(t){var e;return this.disabledBehavior==="all"&&(((e=t.props)===null||e===void 0?void 0:e.isDisabled)||this.disabledKeys.has(t.key))}findNextNonDisabled(t,e){for(;t!=null;){let i=this.collection.getItem(t);if((i==null?void 0:i.type)==="item"&&!this.isDisabled(i))return t;t=e(t)}return null}getNextKey(t){return t=this.collection.getKeyAfter(t),this.findNextNonDisabled(t,e=>this.collection.getKeyAfter(e))}getPreviousKey(t){return t=this.collection.getKeyBefore(t),this.findNextNonDisabled(t,e=>this.collection.getKeyBefore(e))}findKey(t,e,i){let l=this.layoutDelegate.getItemRect(t);if(!l)return null;let s=l;do t=e(t),l=this.layoutDelegate.getItemRect(t);while(l&&i(s,l));return t}isSameRow(t,e){return t.y===e.y||t.x!==e.x}isSameColumn(t,e){return t.x===e.x||t.y!==e.y}getKeyBelow(t){return this.layout==="grid"&&this.orientation==="vertical"?this.findKey(t,e=>this.getNextKey(e),this.isSameRow):this.getNextKey(t)}getKeyAbove(t){return this.layout==="grid"&&this.orientation==="vertical"?this.findKey(t,e=>this.getPreviousKey(e),this.isSameRow):this.getPreviousKey(t)}getNextColumn(t,e){return e?this.getPreviousKey(t):this.getNextKey(t)}getKeyRightOf(t){let e=this.direction==="ltr"?"getKeyRightOf":"getKeyLeftOf";return this.layoutDelegate[e]?(t=this.layoutDelegate[e](t),this.findNextNonDisabled(t,i=>this.layoutDelegate[e](i))):this.layout==="grid"?this.orientation==="vertical"?this.getNextColumn(t,this.direction==="rtl"):this.findKey(t,i=>this.getNextColumn(i,this.direction==="rtl"),this.isSameColumn):this.orientation==="horizontal"?this.getNextColumn(t,this.direction==="rtl"):null}getKeyLeftOf(t){let e=this.direction==="ltr"?"getKeyLeftOf":"getKeyRightOf";return this.layoutDelegate[e]?(t=this.layoutDelegate[e](t),this.findNextNonDisabled(t,i=>this.layoutDelegate[e](i))):this.layout==="grid"?this.orientation==="vertical"?this.getNextColumn(t,this.direction==="ltr"):this.findKey(t,i=>this.getNextColumn(i,this.direction==="ltr"),this.isSameColumn):this.orientation==="horizontal"?this.getNextColumn(t,this.direction==="ltr"):null}getFirstKey(){let t=this.collection.getFirstKey();return this.findNextNonDisabled(t,e=>this.collection.getKeyAfter(e))}getLastKey(){let t=this.collection.getLastKey();return this.findNextNonDisabled(t,e=>this.collection.getKeyBefore(e))}getKeyPageAbove(t){let e=this.ref.current,i=this.layoutDelegate.getItemRect(t);if(!i)return null;if(!r.isScrollable(e))return this.getFirstKey();if(this.orientation==="horizontal"){let l=Math.max(0,i.x+i.width-this.layoutDelegate.getVisibleRect().width);for(;i&&i.x>l;)t=this.getKeyAbove(t),i=t==null?null:this.layoutDelegate.getItemRect(t)}else{let l=Math.max(0,i.y+i.height-this.layoutDelegate.getVisibleRect().height);for(;i&&i.y>l;)t=this.getKeyAbove(t),i=t==null?null:this.layoutDelegate.getItemRect(t)}return t??this.getFirstKey()}getKeyPageBelow(t){let e=this.ref.current,i=this.layoutDelegate.getItemRect(t);if(!i)return null;if(!r.isScrollable(e))return this.getLastKey();if(this.orientation==="horizontal"){let l=Math.min(this.layoutDelegate.getContentSize().width,i.y-i.width+this.layoutDelegate.getVisibleRect().width);for(;i&&i.x<l;)t=this.getKeyBelow(t),i=t==null?null:this.layoutDelegate.getItemRect(t)}else{let l=Math.min(this.layoutDelegate.getContentSize().height,i.y-i.height+this.layoutDelegate.getVisibleRect().height);for(;i&&i.y<l;)t=this.getKeyBelow(t),i=t==null?null:this.layoutDelegate.getItemRect(t)}return t??this.getLastKey()}getKeyForSearch(t,e){if(!this.collator)return null;let i=this.collection,l=e||this.getFirstKey();for(;l!=null;){let s=i.getItem(l),n=s.textValue.slice(0,t.length);if(s.textValue&&this.collator.compare(n,t)===0)return l;l=this.getNextKey(l)}return null}constructor(...t){if(t.length===1){let e=t[0];this.collection=e.collection,this.ref=e.ref,this.collator=e.collator,this.disabledKeys=e.disabledKeys||new Set,this.disabledBehavior=e.disabledBehavior||"all",this.orientation=e.orientation||"vertical",this.direction=e.direction,this.layout=e.layout||"stack",this.layoutDelegate=e.layoutDelegate||new o.DOMLayoutDelegate(e.ref)}else this.collection=t[0],this.disabledKeys=t[1],this.ref=t[2],this.collator=t[3],this.layout="stack",this.orientation="vertical",this.disabledBehavior="all",this.layoutDelegate=new o.DOMLayoutDelegate(this.ref);this.layout==="stack"&&this.orientation==="vertical"&&(this.getKeyLeftOf=void 0,this.getKeyRightOf=void 0)}}exports.ListKeyboardDelegate=h;
|
package/index197.mjs
CHANGED
|
@@ -1,31 +1,113 @@
|
|
|
1
|
-
import {
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
1
|
+
import { DOMLayoutDelegate as o } from "./index198.mjs";
|
|
2
|
+
import { isScrollable as r } from "@react-aria/utils";
|
|
3
|
+
class g {
|
|
4
|
+
isDisabled(t) {
|
|
5
|
+
var e;
|
|
6
|
+
return this.disabledBehavior === "all" && (((e = t.props) === null || e === void 0 ? void 0 : e.isDisabled) || this.disabledKeys.has(t.key));
|
|
7
|
+
}
|
|
8
|
+
findNextNonDisabled(t, e) {
|
|
9
|
+
for (; t != null; ) {
|
|
10
|
+
let i = this.collection.getItem(t);
|
|
11
|
+
if ((i == null ? void 0 : i.type) === "item" && !this.isDisabled(i)) return t;
|
|
12
|
+
t = e(t);
|
|
8
13
|
}
|
|
9
|
-
|
|
10
|
-
}
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
14
|
+
return null;
|
|
15
|
+
}
|
|
16
|
+
getNextKey(t) {
|
|
17
|
+
return t = this.collection.getKeyAfter(t), this.findNextNonDisabled(t, (e) => this.collection.getKeyAfter(e));
|
|
18
|
+
}
|
|
19
|
+
getPreviousKey(t) {
|
|
20
|
+
return t = this.collection.getKeyBefore(t), this.findNextNonDisabled(t, (e) => this.collection.getKeyBefore(e));
|
|
21
|
+
}
|
|
22
|
+
findKey(t, e, i) {
|
|
23
|
+
let l = this.layoutDelegate.getItemRect(t);
|
|
24
|
+
if (!l) return null;
|
|
25
|
+
let s = l;
|
|
26
|
+
do
|
|
27
|
+
t = e(t), l = this.layoutDelegate.getItemRect(t);
|
|
28
|
+
while (l && i(s, l));
|
|
29
|
+
return t;
|
|
30
|
+
}
|
|
31
|
+
isSameRow(t, e) {
|
|
32
|
+
return t.y === e.y || t.x !== e.x;
|
|
33
|
+
}
|
|
34
|
+
isSameColumn(t, e) {
|
|
35
|
+
return t.x === e.x || t.y !== e.y;
|
|
36
|
+
}
|
|
37
|
+
getKeyBelow(t) {
|
|
38
|
+
return this.layout === "grid" && this.orientation === "vertical" ? this.findKey(t, (e) => this.getNextKey(e), this.isSameRow) : this.getNextKey(t);
|
|
39
|
+
}
|
|
40
|
+
getKeyAbove(t) {
|
|
41
|
+
return this.layout === "grid" && this.orientation === "vertical" ? this.findKey(t, (e) => this.getPreviousKey(e), this.isSameRow) : this.getPreviousKey(t);
|
|
42
|
+
}
|
|
43
|
+
getNextColumn(t, e) {
|
|
44
|
+
return e ? this.getPreviousKey(t) : this.getNextKey(t);
|
|
45
|
+
}
|
|
46
|
+
getKeyRightOf(t) {
|
|
47
|
+
let e = this.direction === "ltr" ? "getKeyRightOf" : "getKeyLeftOf";
|
|
48
|
+
return this.layoutDelegate[e] ? (t = this.layoutDelegate[e](t), this.findNextNonDisabled(t, (i) => this.layoutDelegate[e](i))) : this.layout === "grid" ? this.orientation === "vertical" ? this.getNextColumn(t, this.direction === "rtl") : this.findKey(t, (i) => this.getNextColumn(i, this.direction === "rtl"), this.isSameColumn) : this.orientation === "horizontal" ? this.getNextColumn(t, this.direction === "rtl") : null;
|
|
49
|
+
}
|
|
50
|
+
getKeyLeftOf(t) {
|
|
51
|
+
let e = this.direction === "ltr" ? "getKeyLeftOf" : "getKeyRightOf";
|
|
52
|
+
return this.layoutDelegate[e] ? (t = this.layoutDelegate[e](t), this.findNextNonDisabled(t, (i) => this.layoutDelegate[e](i))) : this.layout === "grid" ? this.orientation === "vertical" ? this.getNextColumn(t, this.direction === "ltr") : this.findKey(t, (i) => this.getNextColumn(i, this.direction === "ltr"), this.isSameColumn) : this.orientation === "horizontal" ? this.getNextColumn(t, this.direction === "ltr") : null;
|
|
53
|
+
}
|
|
54
|
+
getFirstKey() {
|
|
55
|
+
let t = this.collection.getFirstKey();
|
|
56
|
+
return this.findNextNonDisabled(t, (e) => this.collection.getKeyAfter(e));
|
|
57
|
+
}
|
|
58
|
+
getLastKey() {
|
|
59
|
+
let t = this.collection.getLastKey();
|
|
60
|
+
return this.findNextNonDisabled(t, (e) => this.collection.getKeyBefore(e));
|
|
61
|
+
}
|
|
62
|
+
getKeyPageAbove(t) {
|
|
63
|
+
let e = this.ref.current, i = this.layoutDelegate.getItemRect(t);
|
|
64
|
+
if (!i) return null;
|
|
65
|
+
if (!r(e)) return this.getFirstKey();
|
|
66
|
+
if (this.orientation === "horizontal") {
|
|
67
|
+
let l = Math.max(0, i.x + i.width - this.layoutDelegate.getVisibleRect().width);
|
|
68
|
+
for (; i && i.x > l; )
|
|
69
|
+
t = this.getKeyAbove(t), i = t == null ? null : this.layoutDelegate.getItemRect(t);
|
|
70
|
+
} else {
|
|
71
|
+
let l = Math.max(0, i.y + i.height - this.layoutDelegate.getVisibleRect().height);
|
|
72
|
+
for (; i && i.y > l; )
|
|
73
|
+
t = this.getKeyAbove(t), i = t == null ? null : this.layoutDelegate.getItemRect(t);
|
|
74
|
+
}
|
|
75
|
+
return t ?? this.getFirstKey();
|
|
76
|
+
}
|
|
77
|
+
getKeyPageBelow(t) {
|
|
78
|
+
let e = this.ref.current, i = this.layoutDelegate.getItemRect(t);
|
|
79
|
+
if (!i) return null;
|
|
80
|
+
if (!r(e)) return this.getLastKey();
|
|
81
|
+
if (this.orientation === "horizontal") {
|
|
82
|
+
let l = Math.min(this.layoutDelegate.getContentSize().width, i.y - i.width + this.layoutDelegate.getVisibleRect().width);
|
|
83
|
+
for (; i && i.x < l; )
|
|
84
|
+
t = this.getKeyBelow(t), i = t == null ? null : this.layoutDelegate.getItemRect(t);
|
|
85
|
+
} else {
|
|
86
|
+
let l = Math.min(this.layoutDelegate.getContentSize().height, i.y - i.height + this.layoutDelegate.getVisibleRect().height);
|
|
87
|
+
for (; i && i.y < l; )
|
|
88
|
+
t = this.getKeyBelow(t), i = t == null ? null : this.layoutDelegate.getItemRect(t);
|
|
89
|
+
}
|
|
90
|
+
return t ?? this.getLastKey();
|
|
91
|
+
}
|
|
92
|
+
getKeyForSearch(t, e) {
|
|
93
|
+
if (!this.collator) return null;
|
|
94
|
+
let i = this.collection, l = e || this.getFirstKey();
|
|
95
|
+
for (; l != null; ) {
|
|
96
|
+
let s = i.getItem(l), n = s.textValue.slice(0, t.length);
|
|
97
|
+
if (s.textValue && this.collator.compare(n, t) === 0) return l;
|
|
98
|
+
l = this.getNextKey(l);
|
|
99
|
+
}
|
|
100
|
+
return null;
|
|
101
|
+
}
|
|
102
|
+
constructor(...t) {
|
|
103
|
+
if (t.length === 1) {
|
|
104
|
+
let e = t[0];
|
|
105
|
+
this.collection = e.collection, this.ref = e.ref, this.collator = e.collator, this.disabledKeys = e.disabledKeys || /* @__PURE__ */ new Set(), this.disabledBehavior = e.disabledBehavior || "all", this.orientation = e.orientation || "vertical", this.direction = e.direction, this.layout = e.layout || "stack", this.layoutDelegate = e.layoutDelegate || new o(e.ref);
|
|
106
|
+
} else
|
|
107
|
+
this.collection = t[0], this.disabledKeys = t[1], this.ref = t[2], this.collator = t[3], this.layout = "stack", this.orientation = "vertical", this.disabledBehavior = "all", this.layoutDelegate = new o(this.ref);
|
|
108
|
+
this.layout === "stack" && this.orientation === "vertical" && (this.getKeyLeftOf = void 0, this.getKeyRightOf = void 0);
|
|
26
109
|
}
|
|
27
110
|
}
|
|
28
111
|
export {
|
|
29
|
-
|
|
30
|
-
m as restoreTextSelection
|
|
112
|
+
g as ListKeyboardDelegate
|
|
31
113
|
};
|
package/index198.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});class n{getItemRect(t){let e=this.ref.current,l=t!=null?e.querySelector(`[data-key="${CSS.escape(t.toString())}"]`):null;if(!l)return null;let i=e.getBoundingClientRect(),r=l.getBoundingClientRect();return{x:r.left-i.left+e.scrollLeft,y:r.top-i.top+e.scrollTop,width:r.width,height:r.height}}getContentSize(){let t=this.ref.current;return{width:t.scrollWidth,height:t.scrollHeight}}getVisibleRect(){let t=this.ref.current;return{x:t.scrollLeft,y:t.scrollTop,width:t.offsetWidth,height:t.offsetHeight}}constructor(t){this.ref=t}}exports.DOMLayoutDelegate=n;
|
package/index198.mjs
CHANGED
|
@@ -1,9 +1,35 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
1
|
+
class o {
|
|
2
|
+
getItemRect(t) {
|
|
3
|
+
let e = this.ref.current, l = t != null ? e.querySelector(`[data-key="${CSS.escape(t.toString())}"]`) : null;
|
|
4
|
+
if (!l) return null;
|
|
5
|
+
let i = e.getBoundingClientRect(), r = l.getBoundingClientRect();
|
|
6
|
+
return {
|
|
7
|
+
x: r.left - i.left + e.scrollLeft,
|
|
8
|
+
y: r.top - i.top + e.scrollTop,
|
|
9
|
+
width: r.width,
|
|
10
|
+
height: r.height
|
|
11
|
+
};
|
|
4
12
|
}
|
|
5
|
-
|
|
6
|
-
t
|
|
13
|
+
getContentSize() {
|
|
14
|
+
let t = this.ref.current;
|
|
15
|
+
return {
|
|
16
|
+
width: t.scrollWidth,
|
|
17
|
+
height: t.scrollHeight
|
|
18
|
+
};
|
|
19
|
+
}
|
|
20
|
+
getVisibleRect() {
|
|
21
|
+
let t = this.ref.current;
|
|
22
|
+
return {
|
|
23
|
+
x: t.scrollLeft,
|
|
24
|
+
y: t.scrollTop,
|
|
25
|
+
width: t.offsetWidth,
|
|
26
|
+
height: t.offsetHeight
|
|
27
|
+
};
|
|
28
|
+
}
|
|
29
|
+
constructor(t) {
|
|
30
|
+
this.ref = t;
|
|
31
|
+
}
|
|
32
|
+
}
|
|
7
33
|
export {
|
|
8
|
-
|
|
34
|
+
o as DOMLayoutDelegate
|
|
9
35
|
};
|
package/index199.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const r=new WeakMap;function a(t,e,f){return t?(typeof e=="string"&&(e=e.replace(/\s+/g,"")),`${r.get(t)}-${f}-${e}`):""}exports.generateId=a;exports.tabsIds=r;
|
package/index199.mjs
CHANGED
|
@@ -1,10 +1,8 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
var _ = e(r, t, "get");
|
|
5
|
-
return s(r, _);
|
|
1
|
+
const f = /* @__PURE__ */ new WeakMap();
|
|
2
|
+
function $(t, e, a) {
|
|
3
|
+
return t ? (typeof e == "string" && (e = e.replace(/\s+/g, "")), `${f.get(t)}-${a}-${e}`) : "";
|
|
6
4
|
}
|
|
7
5
|
export {
|
|
8
|
-
|
|
9
|
-
|
|
6
|
+
$ as generateId,
|
|
7
|
+
f as tabsIds
|
|
10
8
|
};
|
package/index2.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
"use client";
|
|
2
|
-
"use strict";const x=require("react"),h=require("./index63.js"),g=require("./
|
|
2
|
+
"use strict";const x=require("react"),h=require("./index63.js"),g=require("./index80.js"),k=require("./index81.js"),i=require("./index82.js"),c=require("./index83.js"),n=require("./index84.js"),m=require("./index85.js"),a=require("./index86.js"),d=require("./index87.js"),t=require("./index88.js"),b=require("./index89.js"),f=require("./index90.js"),s=require("./index91.js"),u=require("./index92.js"),p=require("./index93.js"),o=require("./index94.js"),l=require("./index95.js"),q=require("./index96.js"),r=require("./index97.js"),C=require("./index79.js"),w=C.makeTheme({main:e=>i.main(e),gridItem:e=>i.gridItem(e),grid:e=>i.grid(e),container:e=>i.container(e),accordion:g.accordionTheme,carousel:m,calendar:{container:e=>n.calendarContainer(e),header:e=>n.calendarHeaderContainer(e),navigationButtonsContainer:e=>n.calendarNavigationButtonsContainer(e),navigationButtons:e=>n.calendarNavigationButtons(e),table:e=>n.calendarTable(e),dayLabel:e=>n.calendarDayLabel(e),cellContainer:e=>n.calendarCellContainer(e),cell:e=>n.calendarCell(e),cellDate:e=>n.calendarCellFormattedDate(e)},datePicker:{container:e=>t.datePickerContainer(e),button:e=>t.datePickerButton(e),icon:e=>t.datePickerIcon(e),dateField:e=>t.datePickerDateField(e),dateSegment:e=>t.datePickerDateSegment(e),label:e=>t.datePickerLabel(e),calendarPopover:e=>t.datePickerCalendarPopoverContainer(e),calendarUnderlay:e=>t.datePickerCalendarPopoverUnderlay(e)},popover:{button:e=>c(e),popover:()=>"border-2 text-black p-4 bg-gray-300"},typography:e=>r(e),button:e=>c(e),sidePanel:{wrapper:e=>l.sidePanelWrapper(e),container:e=>l.sidePanelContainer(e),innerContainer:e=>l.sidePanelInnerContainer(e)},lightBox:f,shareButton:{icon:e=>o.shareButtonIcon(e),button:e=>o.shareButton(e),container:e=>o.shareButtonContainer(e),linksList:e=>o.shareButtonLinksList(e),link:e=>o.shareButtonLink(e),linkIcons:e=>o.shareButtonLinkIcons(e)},checkbox:{container:e=>a.checkboxContainer(e),label:e=>a.checkboxLabel(e),checkBox:e=>a.checkBox(e),checkMark:e=>a.checkMark(e),checkMarkIcon:e=>a.checkMarkIcon(e),errorMessage:e=>r(e)},radio:{label:e=>s.radioLabel(e),radio:e=>s.radio(e),selectedMark:e=>s.selectedMark(e),errorMessage:e=>r(e)},radioGroup:{radioGroup:e=>u.radioGroup(e),radioGroupItemsGroup:e=>u.radioGroupItemsGroup(e),errorMessage:e=>r(e)},checkboxGroup:{checkboxGroup:e=>d.checkboxGroup(e),checkboxGroupItemsGroup:e=>d.checkboxGroupItemsGroup(e),errormessage:e=>r(e)},select:{button:e=>c(e),ul:e=>r({...e,className:"outline outline-2 outline-white outline-offset-2 p-2 my-4 rounded-md w-full flex flex-col gap-6"}),popover:e=>c({...e,className:"w-[var(--select-container-width)]"}),errorMessage:e=>r({...e,size:"footnotes",isError:!0}),wrapper:()=>"flex flex-col gap-4 relative",container:()=>"flex flex-col gap-4",li:()=>"transition w-full hover:text-gray-300 focus-ring-white"},textarea:{wrapper:()=>"flex flex-col",container:()=>"flex items-center gap-4",label:()=>"text-gray-3 px-6",input:e=>q.textArea(e),errorMessage:e=>r({...e,size:"footnotes",isError:!0})},search:{wrapper:()=>"min-w-fit sm:w-80 flex flex-col gap-2",container:()=>"relative flex items-center outline outline-2 outline-gray-300 focus-within:outline focus-within:outline-black focus-within:outline-2",label:()=>"text-gray-3",input:e=>p.searchInput(e),icon:e=>p.searchIcon(e),errorMessage:e=>r({...e,size:"footnotes",isError:!0})},textInput:{wrapper:()=>"group flex flex-col rounded-md px-4 py-1 mb-3 m-0.5 border-2 aria-disabled:pointer-events-none aria-disabled:opacity-30 focus-ring-black",label:()=>'group-has-[:required]:after:content-["_*"] group-has-[:required]:after:text-red-500 text-xs',container:()=>"flex items-center gap-4",input:()=>"",errorMessage:e=>r({...e,className:"ml-0",size:"footnotes",isError:!0})},menu:{sidePanel:{wrapper:()=>"",container:()=>"",innerContainer:()=>""},wrapper:()=>""},menuItem:{wrapper:()=>"",container:()=>"",innerContent:()=>"",button:()=>"",anchor:()=>""},img:b.imgTheme,alerts:k}),$=x.memo(h.createThemeProvider(w));module.exports=$;
|
package/index2.mjs
CHANGED
|
@@ -1,25 +1,25 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
import t from "react";
|
|
3
3
|
import { createThemeProvider as a } from "./index63.mjs";
|
|
4
|
-
import { accordionTheme as n } from "./
|
|
5
|
-
import i from "./
|
|
6
|
-
import { main as l, gridItem as c, grid as s, container as p } from "./
|
|
7
|
-
import o from "./
|
|
8
|
-
import { calendarContainer as m, calendarHeaderContainer as d, calendarNavigationButtonsContainer as u, calendarNavigationButtons as f, calendarTable as h, calendarDayLabel as g, calendarCellContainer as x, calendarCell as k, calendarCellFormattedDate as b } from "./
|
|
9
|
-
import C from "./
|
|
10
|
-
import { checkboxContainer as w, checkboxLabel as P, checkBox as I, checkMark as v, checkMarkIcon as y } from "./
|
|
11
|
-
import { checkboxGroup as B, checkboxGroupItemsGroup as G } from "./
|
|
12
|
-
import { datePickerContainer as M, datePickerButton as L, datePickerIcon as T, datePickerDateField as D, datePickerDateSegment as N, datePickerLabel as z, datePickerCalendarPopoverContainer as E, datePickerCalendarPopoverUnderlay as F } from "./
|
|
13
|
-
import { imgTheme as _ } from "./
|
|
14
|
-
import q from "./
|
|
15
|
-
import { radioLabel as S, radio as U, selectedMark as A } from "./
|
|
16
|
-
import { radioGroup as H, radioGroupItemsGroup as R } from "./
|
|
17
|
-
import { searchInput as W, searchIcon as j } from "./
|
|
18
|
-
import { shareButtonIcon as J, shareButton as K, shareButtonContainer as O, shareButtonLinksList as Q, shareButtonLink as V, shareButtonLinkIcons as X } from "./
|
|
19
|
-
import { sidePanelWrapper as Y, sidePanelContainer as Z, sidePanelInnerContainer as $ } from "./
|
|
20
|
-
import { textArea as ee } from "./
|
|
21
|
-
import r from "./
|
|
22
|
-
import { makeTheme as re } from "./
|
|
4
|
+
import { accordionTheme as n } from "./index80.mjs";
|
|
5
|
+
import i from "./index81.mjs";
|
|
6
|
+
import { main as l, gridItem as c, grid as s, container as p } from "./index82.mjs";
|
|
7
|
+
import o from "./index83.mjs";
|
|
8
|
+
import { calendarContainer as m, calendarHeaderContainer as d, calendarNavigationButtonsContainer as u, calendarNavigationButtons as f, calendarTable as h, calendarDayLabel as g, calendarCellContainer as x, calendarCell as k, calendarCellFormattedDate as b } from "./index84.mjs";
|
|
9
|
+
import C from "./index85.mjs";
|
|
10
|
+
import { checkboxContainer as w, checkboxLabel as P, checkBox as I, checkMark as v, checkMarkIcon as y } from "./index86.mjs";
|
|
11
|
+
import { checkboxGroup as B, checkboxGroupItemsGroup as G } from "./index87.mjs";
|
|
12
|
+
import { datePickerContainer as M, datePickerButton as L, datePickerIcon as T, datePickerDateField as D, datePickerDateSegment as N, datePickerLabel as z, datePickerCalendarPopoverContainer as E, datePickerCalendarPopoverUnderlay as F } from "./index88.mjs";
|
|
13
|
+
import { imgTheme as _ } from "./index89.mjs";
|
|
14
|
+
import q from "./index90.mjs";
|
|
15
|
+
import { radioLabel as S, radio as U, selectedMark as A } from "./index91.mjs";
|
|
16
|
+
import { radioGroup as H, radioGroupItemsGroup as R } from "./index92.mjs";
|
|
17
|
+
import { searchInput as W, searchIcon as j } from "./index93.mjs";
|
|
18
|
+
import { shareButtonIcon as J, shareButton as K, shareButtonContainer as O, shareButtonLinksList as Q, shareButtonLink as V, shareButtonLinkIcons as X } from "./index94.mjs";
|
|
19
|
+
import { sidePanelWrapper as Y, sidePanelContainer as Z, sidePanelInnerContainer as $ } from "./index95.mjs";
|
|
20
|
+
import { textArea as ee } from "./index96.mjs";
|
|
21
|
+
import r from "./index97.mjs";
|
|
22
|
+
import { makeTheme as re } from "./index79.mjs";
|
|
23
23
|
const oe = re({
|
|
24
24
|
main: (e) => l(e),
|
|
25
25
|
gridItem: (e) => c(e),
|
package/index20.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
"use client";
|
|
2
|
-
"use strict";const e=require("react/jsx-runtime"),N=require("react"),a=require("react-aria"),g=require("./
|
|
2
|
+
"use strict";const e=require("react/jsx-runtime"),N=require("react"),a=require("react-aria"),g=require("./index111.js"),n=require("./index64.js"),I=require("./index14.js"),b=require("./index3.js"),R=o=>{const{id:r,ariaLabel:j,icon:i,state:l,themeName:s="checkbox",customTheme:t,tokens:f,isDisabled:h=!1,isError:u=!1,value:x,errorMessage:d,label:C}=o,k=N.useRef(null),{inputProps:$}=a.useCheckboxGroupItem(o,l,k),{isSelected:m}=l,c={...f,selected:m(x),isDisabled:h,isError:u},q=n(`${s}.container`,c,t),T=n(`${s}.checkBox`,c,t),p=n(`${s}.checkMark`,c,t),M=n(`${s}.checkMarkIcon`,c,t);return e.jsxs("div",{children:[e.jsx(a.FocusRing,{focusRingClass:"has-focus-ring",within:!0,children:e.jsxs("label",{className:q,htmlFor:r,"aria-label":j,"aria-disabled":h,children:[e.jsx(a.VisuallyHidden,{children:e.jsx("input",{ref:k,...$})}),e.jsx("div",{className:T,"aria-checked":m(x),role:"checkbox","aria-labelledby":r,children:e.jsx("div",{className:p,children:i&&e.jsx(I,{icon:i,customTheme:M})})}),e.jsx(b.default,{themeName:`${s}.label`,tokens:c,children:C})]})}),u&&d&&e.jsx(b.default,{themeName:`${s}.errorMessage`,tokens:c,children:d})]})},v=o=>{const r=g.useCheckboxGroupCtx();return r&&e.jsx(R,{state:r,...o})};module.exports=v;
|
package/index20.mjs
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
import { jsx as e, jsxs as p } from "react/jsx-runtime";
|
|
3
3
|
import { useRef as $ } from "react";
|
|
4
4
|
import { useCheckboxGroupItem as v, FocusRing as y, VisuallyHidden as B } from "react-aria";
|
|
5
|
-
import { useCheckboxGroupCtx as G } from "./
|
|
5
|
+
import { useCheckboxGroupCtx as G } from "./index111.mjs";
|
|
6
6
|
import a from "./index64.mjs";
|
|
7
7
|
import R from "./index14.mjs";
|
|
8
8
|
import x from "./index3.mjs";
|
package/index200.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const l=require("@react-aria/utils");let n="default",i="",s=new WeakMap;function c(e){if(l.isIOS()){if(n==="default"){const t=l.getOwnerDocument(e);i=t.documentElement.style.webkitUserSelect,t.documentElement.style.webkitUserSelect="none"}n="disabled"}else(e instanceof HTMLElement||e instanceof SVGElement)&&(s.set(e,e.style.userSelect),e.style.userSelect="none")}function o(e){if(l.isIOS()){if(n!=="disabled")return;n="restoring",setTimeout(()=>{l.runAfterTransition(()=>{if(n==="restoring"){const t=l.getOwnerDocument(e);t.documentElement.style.webkitUserSelect==="none"&&(t.documentElement.style.webkitUserSelect=i||""),i="",n="default"}})},300)}else if((e instanceof HTMLElement||e instanceof SVGElement)&&e&&s.has(e)){let t=s.get(e);e.style.userSelect==="none"&&(e.style.userSelect=t),e.getAttribute("style")===""&&e.removeAttribute("style"),s.delete(e)}}exports.disableTextSelection=c;exports.restoreTextSelection=o;
|
package/index200.mjs
CHANGED
|
@@ -1,10 +1,31 @@
|
|
|
1
|
-
import {
|
|
2
|
-
|
|
3
|
-
function
|
|
4
|
-
|
|
5
|
-
|
|
1
|
+
import { isIOS as i, getOwnerDocument as c, runAfterTransition as o } from "@react-aria/utils";
|
|
2
|
+
let n = "default", s = "", l = /* @__PURE__ */ new WeakMap();
|
|
3
|
+
function f(e) {
|
|
4
|
+
if (i()) {
|
|
5
|
+
if (n === "default") {
|
|
6
|
+
const t = c(e);
|
|
7
|
+
s = t.documentElement.style.webkitUserSelect, t.documentElement.style.webkitUserSelect = "none";
|
|
8
|
+
}
|
|
9
|
+
n = "disabled";
|
|
10
|
+
} else (e instanceof HTMLElement || e instanceof SVGElement) && (l.set(e, e.style.userSelect), e.style.userSelect = "none");
|
|
11
|
+
}
|
|
12
|
+
function m(e) {
|
|
13
|
+
if (i()) {
|
|
14
|
+
if (n !== "disabled") return;
|
|
15
|
+
n = "restoring", setTimeout(() => {
|
|
16
|
+
o(() => {
|
|
17
|
+
if (n === "restoring") {
|
|
18
|
+
const t = c(e);
|
|
19
|
+
t.documentElement.style.webkitUserSelect === "none" && (t.documentElement.style.webkitUserSelect = s || ""), s = "", n = "default";
|
|
20
|
+
}
|
|
21
|
+
});
|
|
22
|
+
}, 300);
|
|
23
|
+
} else if ((e instanceof HTMLElement || e instanceof SVGElement) && e && l.has(e)) {
|
|
24
|
+
let t = l.get(e);
|
|
25
|
+
e.style.userSelect === "none" && (e.style.userSelect = t), e.getAttribute("style") === "" && e.removeAttribute("style"), l.delete(e);
|
|
26
|
+
}
|
|
6
27
|
}
|
|
7
28
|
export {
|
|
8
|
-
|
|
9
|
-
|
|
29
|
+
f as disableTextSelection,
|
|
30
|
+
m as restoreTextSelection
|
|
10
31
|
};
|
package/index201.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const t=require("react"),e=t.createContext({register:()=>{}});e.displayName="PressResponderContext";exports.PressResponderContext=e;
|
package/index201.mjs
CHANGED
|
@@ -1,7 +1,9 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
1
|
+
import e from "react";
|
|
2
|
+
const t = e.createContext({
|
|
3
|
+
register: () => {
|
|
4
|
+
}
|
|
5
|
+
});
|
|
6
|
+
t.displayName = "PressResponderContext";
|
|
4
7
|
export {
|
|
5
|
-
|
|
6
|
-
a as _class_apply_descriptor_get
|
|
8
|
+
t as PressResponderContext
|
|
7
9
|
};
|
package/index202.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});function
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const s=require("./index204.js"),c=require("./index205.js");function t(e,_){var r=c._class_extract_field_descriptor(e,_,"get");return s._class_apply_descriptor_get(e,r)}exports._=t;exports._class_private_field_get=t;
|
package/index202.mjs
CHANGED
|
@@ -1,8 +1,10 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
1
|
+
import { _class_apply_descriptor_get as s } from "./index204.mjs";
|
|
2
|
+
import { _class_extract_field_descriptor as e } from "./index205.mjs";
|
|
3
|
+
function a(r, t) {
|
|
4
|
+
var _ = e(r, t, "get");
|
|
5
|
+
return s(r, _);
|
|
4
6
|
}
|
|
5
7
|
export {
|
|
6
|
-
|
|
7
|
-
|
|
8
|
+
a as _,
|
|
9
|
+
a as _class_private_field_get
|
|
8
10
|
};
|
package/index203.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const c=require("./index206.js"),i=require("./index205.js");function t(e,_,s){var r=i._class_extract_field_descriptor(e,_,"set");return c._class_apply_descriptor_set(e,r,s),s}exports._=t;exports._class_private_field_set=t;
|
package/index203.mjs
CHANGED
|
@@ -1,12 +1,10 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
e.value = t;
|
|
7
|
-
}
|
|
1
|
+
import { _class_apply_descriptor_set as o } from "./index206.mjs";
|
|
2
|
+
import { _class_extract_field_descriptor as p } from "./index205.mjs";
|
|
3
|
+
function a(r, s, t) {
|
|
4
|
+
var _ = p(r, s, "set");
|
|
5
|
+
return o(r, _, t), t;
|
|
8
6
|
}
|
|
9
7
|
export {
|
|
10
|
-
|
|
11
|
-
|
|
8
|
+
a as _,
|
|
9
|
+
a as _class_private_field_set
|
|
12
10
|
};
|
package/index204.js
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});function t(l,e){return e.get?e.get.call(l):e.value}exports._=t;exports._class_apply_descriptor_get=t;
|
package/index204.mjs
ADDED
package/index205.js
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});function r(t,e,o){if(!e.has(t))throw new TypeError("attempted to "+o+" private field on non-instance");return e.get(t)}exports._=r;exports._class_extract_field_descriptor=r;
|
package/index205.mjs
ADDED
package/index206.js
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});function l(a,e,t){if(e.set)e.set.call(a,t);else{if(!e.writable)throw new TypeError("attempted to set read only private field");e.value=t}}exports._=l;exports._class_apply_descriptor_set=l;
|
package/index206.mjs
ADDED
package/index21.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
"use client";
|
|
2
|
-
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e=require("react/jsx-runtime"),O=require("@react-aria/focus")
|
|
2
|
+
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e=require("react/jsx-runtime"),O=require("@react-aria/focus"),$=require("radash"),A=require("react"),H=require("react-aria"),M=require("react-hook-form"),h=require("./index64.js"),C=require("./index72.js"),P=require("./index3.js"),T=r=>{const{id:s,label:d,name:a,placeholder:R,required:x,disabled:t=!1,errorMessage:n,ariaLabel:o,value:m,onBlur:i,onChange:b,fieldRef:l,themeName:c="textarea",tokens:j,customTheme:g}=r,f=A.useRef(null),{errorMessageProps:p,inputProps:v,labelProps:E}=H.useTextField(r,f),u={...j,isDisabled:t,isError:n!=null},F=h(`${c}.wrapper`,u,g),N=h(`${c}.input`,u,g),k=h(`${c}.label`,u,g),L=h(`${c}.container`,u,g);return e.jsxs("div",{children:[e.jsxs("div",{className:F,"aria-disabled":t,children:[d&&e.jsx("label",{className:k,...E,children:d}),e.jsx("div",{className:L,children:e.jsx(O.FocusRing,{focusRingClass:"has-focus-ring",children:e.jsx("textarea",{...v,ref:q=>{l==null||l(q),f.current=q},className:N,placeholder:R,disabled:t,required:x,id:s,name:a,"aria-label":o,"aria-labelledby":s,value:m,onBlur:i,onChange:b})})})]}),n&&e.jsx(P.default,{themeName:`${c}.errorMessage`,tokens:u,...p,children:n})]})},_=r=>{const{name:s,required:d,minLength:a=0,maxLength:R=99999999,validation:x}=r,{register:t,formState:n}=M.useFormContext(),o=M.get(n.errors,s),m=(o==null?void 0:o.message)??void 0,{t:i}=C.useTranslation(),{ref:b,...l}=t(s,{required:d?i("FORM.ERROR.REQUIRED")??"required":!1,minLength:{value:a,message:i("FORM.ERROR.MIN_LENGTH",{length:a})},maxLength:{value:R,message:i("FORM.ERROR.MAX_LENGTH",{length:a})},...x});return e.jsx(T,{fieldRef:b,...l,...r,isError:!$.isEmpty(m),errorMessage:m})};exports.ReactHookFormTextArea=_;exports.default=T;
|
package/index21.mjs
CHANGED
|
@@ -5,15 +5,15 @@ import { isEmpty as $ } from "radash";
|
|
|
5
5
|
import { useRef as q } from "react";
|
|
6
6
|
import { useTextField as y } from "react-aria";
|
|
7
7
|
import { useFormContext as A, get as H } from "react-hook-form";
|
|
8
|
-
import
|
|
9
|
-
import
|
|
8
|
+
import h from "./index64.mjs";
|
|
9
|
+
import { useTranslation as P } from "./index72.mjs";
|
|
10
10
|
import j from "./index3.mjs";
|
|
11
11
|
const w = (r) => {
|
|
12
12
|
const {
|
|
13
13
|
id: s,
|
|
14
14
|
label: u,
|
|
15
15
|
name: a,
|
|
16
|
-
placeholder:
|
|
16
|
+
placeholder: p,
|
|
17
17
|
required: f,
|
|
18
18
|
disabled: t = !1,
|
|
19
19
|
errorMessage: o,
|
|
@@ -24,8 +24,8 @@ const w = (r) => {
|
|
|
24
24
|
fieldRef: l,
|
|
25
25
|
themeName: m = "textarea",
|
|
26
26
|
tokens: E,
|
|
27
|
-
customTheme:
|
|
28
|
-
} = r, b = q(null), { errorMessageProps: M, inputProps: N, labelProps: v } = y(r, b), c = { ...E, isDisabled: t, isError: o != null }, F =
|
|
27
|
+
customTheme: g
|
|
28
|
+
} = r, b = q(null), { errorMessageProps: M, inputProps: N, labelProps: v } = y(r, b), c = { ...E, isDisabled: t, isError: o != null }, F = h(`${m}.wrapper`, c, g), L = h(`${m}.input`, c, g), O = h(`${m}.label`, c, g), k = h(`${m}.container`, c, g);
|
|
29
29
|
return /* @__PURE__ */ T("div", { children: [
|
|
30
30
|
/* @__PURE__ */ T("div", { className: F, "aria-disabled": t, children: [
|
|
31
31
|
u && /* @__PURE__ */ e("label", { className: O, ...v, children: u }),
|
|
@@ -37,7 +37,7 @@ const w = (r) => {
|
|
|
37
37
|
l == null || l(x), b.current = x;
|
|
38
38
|
},
|
|
39
39
|
className: L,
|
|
40
|
-
placeholder:
|
|
40
|
+
placeholder: p,
|
|
41
41
|
disabled: t,
|
|
42
42
|
required: f,
|
|
43
43
|
id: s,
|
|
@@ -53,14 +53,14 @@ const w = (r) => {
|
|
|
53
53
|
o && /* @__PURE__ */ e(j, { themeName: `${m}.errorMessage`, tokens: c, ...M, children: o })
|
|
54
54
|
] });
|
|
55
55
|
}, z = (r) => {
|
|
56
|
-
const { name: s, required: u, minLength: a = 0, maxLength:
|
|
56
|
+
const { name: s, required: u, minLength: a = 0, maxLength: p = 99999999, validation: f } = r, { register: t, formState: o } = A(), n = H(o.errors, s), d = (n == null ? void 0 : n.message) ?? void 0, { t: i } = P(), { ref: R, ...l } = t(s, {
|
|
57
57
|
required: u ? i("FORM.ERROR.REQUIRED") ?? "required" : !1,
|
|
58
58
|
minLength: {
|
|
59
59
|
value: a,
|
|
60
60
|
message: i("FORM.ERROR.MIN_LENGTH", { length: a })
|
|
61
61
|
},
|
|
62
62
|
maxLength: {
|
|
63
|
-
value:
|
|
63
|
+
value: p,
|
|
64
64
|
message: i("FORM.ERROR.MAX_LENGTH", { length: a })
|
|
65
65
|
},
|
|
66
66
|
...f
|