@solibo/solibo-ui 0.5.7 → 0.5.9
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/assets/index14.css +1 -1
- package/dist/assets/index15.css +1 -1
- package/dist/assets/index16.css +1 -1
- package/dist/assets/index17.css +1 -1
- package/dist/assets/index18.css +1 -1
- package/dist/assets/index19.css +1 -1
- package/dist/assets/index2.css +1 -1
- package/dist/assets/index20.css +1 -1
- package/dist/assets/index21.css +1 -1
- package/dist/assets/index28.css +1 -1
- package/dist/assets/index29.css +1 -1
- package/dist/assets/index30.css +1 -1
- package/dist/assets/index31.css +1 -1
- package/dist/assets/index32.css +1 -1
- package/dist/assets/index33.css +1 -1
- package/dist/assets/index34.css +1 -1
- package/dist/assets/index35.css +1 -1
- package/dist/assets/index36.css +1 -1
- package/dist/assets/index37.css +1 -1
- package/dist/assets/index38.css +1 -1
- package/dist/assets/index39.css +1 -1
- package/dist/assets/index40.css +1 -1
- package/dist/assets/index41.css +1 -1
- package/dist/assets/index42.css +1 -1
- package/dist/assets/index43.css +1 -1
- package/dist/assets/index44.css +1 -1
- package/dist/assets/index45.css +1 -0
- package/dist/assets/index46.css +1 -0
- package/dist/components/_avatar/index.cjs +1 -1
- package/dist/components/_avatar/index.js +7 -7
- package/dist/components/_card/index.cjs +1 -1
- package/dist/components/_card/index.js +26 -26
- package/dist/components/_collapsible/index.cjs +1 -1
- package/dist/components/_collapsible/index.js +2 -2
- package/dist/components/_croppable/index.cjs +1 -1
- package/dist/components/_croppable/index.js +110 -110
- package/dist/components/_dropdown/index.cjs +1 -1
- package/dist/components/_dropdown/index.js +3 -3
- package/dist/components/_dropzone/index.cjs +1 -1
- package/dist/components/_dropzone/index.js +1 -1
- package/dist/components/_editor/index.cjs +1 -1
- package/dist/components/_editor/index.js +1 -1
- package/dist/components/_menu/index.cjs +2 -0
- package/dist/components/_menu/index.cjs.map +1 -0
- package/dist/components/_menu/index.js +78 -0
- package/dist/components/_menu/index.js.map +1 -0
- package/dist/components/_sortable/index.cjs +1 -1
- package/dist/components/_sortable/index.js +1 -1
- package/dist/components/app-link/index.cjs +1 -1
- package/dist/components/app-link/index.js +1 -1
- package/dist/components/aside/index.cjs +1 -1
- package/dist/components/aside/index.js +1 -1
- package/dist/components/badge/index.cjs +1 -1
- package/dist/components/badge/index.js +9 -9
- package/dist/components/branding/index.cjs +1 -1
- package/dist/components/branding/index.js +1 -1
- package/dist/components/button/index.cjs +1 -1
- package/dist/components/button/index.js +13 -13
- package/dist/components/checkbox/index.cjs +1 -1
- package/dist/components/checkbox/index.js +2 -2
- package/dist/components/figure/index.cjs +1 -1
- package/dist/components/figure/index.js +1 -1
- package/dist/components/form/index.cjs +1 -1
- package/dist/components/form/index.js +1 -1
- package/dist/components/icon/index.cjs +1 -1
- package/dist/components/icon/index.js +2 -2
- package/dist/components/input/index.cjs +1 -1
- package/dist/components/input/index.js +1 -1
- package/dist/components/link/index.cjs +1 -1
- package/dist/components/link/index.js +1 -1
- package/dist/components/list/index.cjs +1 -1
- package/dist/components/list/index.js +1 -1
- package/dist/components/loading/index.cjs +1 -1
- package/dist/components/loading/index.js +7 -7
- package/dist/components/message/index.cjs +1 -1
- package/dist/components/message/index.js +6 -6
- package/dist/components/nav/index.cjs +1 -1
- package/dist/components/nav/index.js +2 -2
- package/dist/components/popover/index.cjs +2 -0
- package/dist/components/popover/index.cjs.map +1 -0
- package/dist/components/popover/index.js +68 -0
- package/dist/components/popover/index.js.map +1 -0
- package/dist/components/select/index.cjs +1 -1
- package/dist/components/select/index.js +2 -2
- package/dist/components/textarea/index.cjs +1 -1
- package/dist/components/textarea/index.js +1 -1
- package/dist/components/toast/index.cjs +1 -1
- package/dist/components/toast/index.js +1 -1
- package/dist/components/toggle/index.cjs +1 -1
- package/dist/components/toggle/index.js +8 -8
- package/dist/components/toolbar/index.cjs +1 -1
- package/dist/components/toolbar/index.js +1 -1
- package/dist/{icons-DkF2p6NO.js → icons-06oXnjRF.js} +9 -5
- package/dist/icons-06oXnjRF.js.map +1 -0
- package/dist/icons-o8Z5npPW.cjs +2 -0
- package/dist/icons-o8Z5npPW.cjs.map +1 -0
- package/dist/{index-BGqIgxnV.js → index-DXvkoITF.js} +3 -3
- package/dist/{index-BGqIgxnV.js.map → index-DXvkoITF.js.map} +1 -1
- package/dist/{index-908yg65J.cjs → index-WOhmAd8s.cjs} +2 -2
- package/dist/{index-908yg65J.cjs.map → index-WOhmAd8s.cjs.map} +1 -1
- package/dist/index.cjs +1 -1
- package/dist/index.d.ts +47 -0
- package/dist/index.js +76 -72
- package/dist/index.js.map +1 -1
- package/dist/tokens.json +1 -1
- package/package.json +1 -1
- package/dist/icons-DkF2p6NO.js.map +0 -1
- package/dist/icons-vqS7W0cD.cjs +0 -2
- package/dist/icons-vqS7W0cD.cjs.map +0 -1
|
@@ -0,0 +1,78 @@
|
|
|
1
|
+
import { jsx as o, jsxs as h } from "react/jsx-runtime";
|
|
2
|
+
import { t as b } from "../../classix-DG18itHa.js";
|
|
3
|
+
import { useRef as x, useCallback as D, useEffect as _ } from "react";
|
|
4
|
+
import { Button as y } from "../button/index.js";
|
|
5
|
+
import { Icon as m } from "../icon/index.js";
|
|
6
|
+
import { List as k } from "../list/index.js";
|
|
7
|
+
import { Popover as w } from "../popover/index.js";
|
|
8
|
+
import '../../assets/index21.css';const A = "_list_1x03m_1", B = "_item_1x03m_13", C = "_danger_1x03m_41", f = {
|
|
9
|
+
list: A,
|
|
10
|
+
item: B,
|
|
11
|
+
danger: C
|
|
12
|
+
};
|
|
13
|
+
function E(s) {
|
|
14
|
+
return s.filter((t) => !!(t && !t.disabled));
|
|
15
|
+
}
|
|
16
|
+
const I = ({
|
|
17
|
+
close: s,
|
|
18
|
+
initialFocus: t,
|
|
19
|
+
items: u,
|
|
20
|
+
menuAccessibleLabel: c,
|
|
21
|
+
onItemSelect: a
|
|
22
|
+
}) => {
|
|
23
|
+
const l = x([]), r = D((e) => {
|
|
24
|
+
const n = E(l.current);
|
|
25
|
+
if (n.length === 0)
|
|
26
|
+
return;
|
|
27
|
+
if (e === "first") {
|
|
28
|
+
n[0].focus();
|
|
29
|
+
return;
|
|
30
|
+
}
|
|
31
|
+
if (e === "last") {
|
|
32
|
+
n[n.length - 1].focus();
|
|
33
|
+
return;
|
|
34
|
+
}
|
|
35
|
+
const i = n.indexOf(document.activeElement), g = e === "next" ? (i + 1) % n.length : (i - 1 + n.length) % n.length;
|
|
36
|
+
n[g].focus();
|
|
37
|
+
}, []);
|
|
38
|
+
_(() => {
|
|
39
|
+
r(t ?? "first");
|
|
40
|
+
}, [r, t]);
|
|
41
|
+
const d = (e) => {
|
|
42
|
+
if (e.key === "ArrowDown") {
|
|
43
|
+
e.preventDefault(), r("next");
|
|
44
|
+
return;
|
|
45
|
+
}
|
|
46
|
+
if (e.key === "ArrowUp") {
|
|
47
|
+
e.preventDefault(), r("previous");
|
|
48
|
+
return;
|
|
49
|
+
}
|
|
50
|
+
if (e.key === "Home") {
|
|
51
|
+
e.preventDefault(), r("first");
|
|
52
|
+
return;
|
|
53
|
+
}
|
|
54
|
+
e.key === "End" && (e.preventDefault(), r("last"));
|
|
55
|
+
}, p = (e) => {
|
|
56
|
+
var n;
|
|
57
|
+
(n = e.onSelect) == null || n.call(e), a == null || a(e), s();
|
|
58
|
+
};
|
|
59
|
+
return /* @__PURE__ */ o(k, { "aria-label": c, className: f.list, onKeyDown: d, role: "menu", "data-component": "menupanel", children: u.map((e, n) => /* @__PURE__ */ o("li", { role: "none", children: /* @__PURE__ */ h(y, { "aria-label": e.accessibleLabel, className: b(f.item, e.isDanger && f.danger), disabled: e.disabled, onClick: () => p(e), ref: (i) => {
|
|
60
|
+
l.current[n] = i;
|
|
61
|
+
}, role: "menuitem", variant: "minimal", children: [
|
|
62
|
+
e.icon && /* @__PURE__ */ o(m, { gap: "right", name: e.icon, size: "small", variant: e.isDanger ? "danger" : "default" }),
|
|
63
|
+
/* @__PURE__ */ o("span", { children: e.label })
|
|
64
|
+
] }) }, e.id ?? n)) });
|
|
65
|
+
}, L = ({
|
|
66
|
+
items: s,
|
|
67
|
+
menuAccessibleLabel: t = "Menu",
|
|
68
|
+
onItemSelect: u,
|
|
69
|
+
position: c = "left",
|
|
70
|
+
triggerAccessibleLabel: a = "Open menu"
|
|
71
|
+
}) => /* @__PURE__ */ o(w, { position: c, triggerAccessibleLabel: a, triggerAriaHasPopup: "menu", triggerButtonContent: /* @__PURE__ */ o(m, { name: "dots", size: "medium" }), "data-component": "menu", children: ({
|
|
72
|
+
close: l,
|
|
73
|
+
initialFocus: r
|
|
74
|
+
}) => /* @__PURE__ */ o(I, { close: l, initialFocus: r, items: s, menuAccessibleLabel: t, onItemSelect: u }) });
|
|
75
|
+
export {
|
|
76
|
+
L as Menu
|
|
77
|
+
};
|
|
78
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sources":["../../../src/components/_menu/index.tsx"],"sourcesContent":["import cx from 'classix';\nimport { useCallback, useEffect, useRef } from 'react';\n\nimport { Button } from '@/components/button';\nimport { Icon } from '@/components/icon';\nimport { type IconName } from '@/components/icon/icons';\nimport { List } from '@/components/list';\nimport { Popover, type PopoverInitialFocus, type PopoverRenderProps } from '@/components/popover';\n\nimport styles from './styles.module.css';\n\nexport type MenuItem = {\n accessibleLabel?: string;\n disabled?: boolean;\n icon?: IconName;\n id?: string;\n isDanger?: boolean;\n label: React.ReactNode;\n onSelect?: () => void;\n};\n\nexport type MenuProps = {\n items: MenuItem[];\n menuAccessibleLabel?: string;\n onItemSelect?: (item: MenuItem) => void;\n position?: 'left' | 'right';\n triggerAccessibleLabel?: string;\n};\n\ntype MenuFocusTarget = 'first' | 'last' | 'next' | 'previous';\n\ntype MenuPanelProps = Pick<MenuProps, 'items' | 'menuAccessibleLabel' | 'onItemSelect'> & {\n close: PopoverRenderProps['close'];\n initialFocus?: PopoverInitialFocus;\n};\n\nfunction getFocusableItems(items: Array<HTMLButtonElement | null>) {\n return items.filter((item): item is HTMLButtonElement => Boolean(item && !item.disabled));\n}\n\nconst MenuPanel = ({\n close,\n initialFocus,\n items,\n menuAccessibleLabel,\n onItemSelect,\n}: MenuPanelProps) => {\n const itemRefs = useRef<Array<HTMLButtonElement | null>>([]);\n\n const focusItem = useCallback((target: MenuFocusTarget) => {\n const focusableItems = getFocusableItems(itemRefs.current);\n\n if (focusableItems.length === 0) {\n return;\n }\n\n if (target === 'first') {\n focusableItems[0].focus();\n return;\n }\n\n if (target === 'last') {\n focusableItems[focusableItems.length - 1].focus();\n return;\n }\n\n const currentIndex = focusableItems.indexOf(document.activeElement as HTMLButtonElement);\n const nextIndex =\n target === 'next'\n ? (currentIndex + 1) % focusableItems.length\n : (currentIndex - 1 + focusableItems.length) % focusableItems.length;\n\n focusableItems[nextIndex].focus();\n }, []);\n\n useEffect(() => {\n focusItem(initialFocus ?? 'first');\n }, [focusItem, initialFocus]);\n\n const handleKeyDown = (event: React.KeyboardEvent<HTMLUListElement>) => {\n if (event.key === 'ArrowDown') {\n event.preventDefault();\n focusItem('next');\n return;\n }\n\n if (event.key === 'ArrowUp') {\n event.preventDefault();\n focusItem('previous');\n return;\n }\n\n if (event.key === 'Home') {\n event.preventDefault();\n focusItem('first');\n return;\n }\n\n if (event.key === 'End') {\n event.preventDefault();\n focusItem('last');\n }\n };\n\n const handleItemSelect = (item: MenuItem) => {\n item.onSelect?.();\n onItemSelect?.(item);\n close();\n };\n\n return (\n <List\n aria-label={menuAccessibleLabel}\n className={styles.list}\n onKeyDown={handleKeyDown}\n role='menu'\n >\n {items.map((item, index) => (\n <li\n key={item.id ?? index}\n role='none'\n >\n <Button\n aria-label={item.accessibleLabel}\n className={cx(styles.item, item.isDanger && styles.danger)}\n disabled={item.disabled}\n onClick={() => handleItemSelect(item)}\n ref={(node) => {\n itemRefs.current[index] = node;\n }}\n role='menuitem'\n variant='minimal'\n >\n {item.icon && (\n <Icon\n gap='right'\n name={item.icon}\n size='small'\n variant={item.isDanger ? 'danger' : 'default'}\n />\n )}\n <span>{item.label}</span>\n </Button>\n </li>\n ))}\n </List>\n );\n};\n\nexport const Menu = ({\n items,\n menuAccessibleLabel = 'Menu',\n onItemSelect,\n position = 'left',\n triggerAccessibleLabel = 'Open menu',\n}: MenuProps) => {\n return (\n <Popover\n position={position}\n triggerAccessibleLabel={triggerAccessibleLabel}\n triggerAriaHasPopup='menu'\n triggerButtonContent={\n <Icon\n name='dots'\n size='medium'\n />\n }\n >\n {({ close, initialFocus }) => (\n <MenuPanel\n close={close}\n initialFocus={initialFocus}\n items={items}\n menuAccessibleLabel={menuAccessibleLabel}\n onItemSelect={onItemSelect}\n />\n )}\n </Popover>\n );\n};\n"],"names":["getFocusableItems","items","filter","item","Boolean","disabled","MenuPanel","close","initialFocus","menuAccessibleLabel","onItemSelect","itemRefs","useRef","focusItem","useCallback","target","focusableItems","current","length","focus","currentIndex","indexOf","document","activeElement","nextIndex","useEffect","handleKeyDown","event","key","preventDefault","handleItemSelect","onSelect","jsx","List","styles","list","map","index","Button","accessibleLabel","cx","isDanger","danger","node","icon","Icon","label","id","Menu","position","triggerAccessibleLabel","Popover"],"mappings":";;;;;;;;;;;;AAoCA,SAASA,EAAkBC,GAAwC;AACjE,SAAOA,EAAMC,OAAO,CAACC,MAAoCC,GAAQD,KAAQ,CAACA,EAAKE,SAAS;AAC1F;AAEA,MAAMC,IAAYA,CAAC;AAAA,EACjBC,OAAAA;AAAAA,EACAC,cAAAA;AAAAA,EACAP,OAAAA;AAAAA,EACAQ,qBAAAA;AAAAA,EACAC,cAAAA;AACc,MAAM;AACpB,QAAMC,IAAWC,EAAwC,EAAE,GAErDC,IAAYC,EAAY,CAACC,MAA4B;AACzD,UAAMC,IAAiBhB,EAAkBW,EAASM,OAAO;AAEzD,QAAID,EAAeE,WAAW;AAC5B;AAGF,QAAIH,MAAW,SAAS;AACtBC,MAAAA,EAAe,CAAC,EAAEG,MAAAA;AAClB;AAAA,IACF;AAEA,QAAIJ,MAAW,QAAQ;AACrBC,MAAAA,EAAeA,EAAeE,SAAS,CAAC,EAAEC,MAAAA;AAC1C;AAAA,IACF;AAEA,UAAMC,IAAeJ,EAAeK,QAAQC,SAASC,aAAkC,GACjFC,IACJT,MAAW,UACNK,IAAe,KAAKJ,EAAeE,UACnCE,IAAe,IAAIJ,EAAeE,UAAUF,EAAeE;AAElEF,IAAAA,EAAeQ,CAAS,EAAEL,MAAAA;AAAAA,EAC5B,GAAG,CAAA,CAAE;AAELM,EAAAA,EAAU,MAAM;AACdZ,IAAAA,EAAUL,KAAgB,OAAO;AAAA,EACnC,GAAG,CAACK,GAAWL,CAAY,CAAC;AAE5B,QAAMkB,IAAgBA,CAACC,MAAiD;AACtE,QAAIA,EAAMC,QAAQ,aAAa;AAC7BD,MAAAA,EAAME,eAAAA,GACNhB,EAAU,MAAM;AAChB;AAAA,IACF;AAEA,QAAIc,EAAMC,QAAQ,WAAW;AAC3BD,MAAAA,EAAME,eAAAA,GACNhB,EAAU,UAAU;AACpB;AAAA,IACF;AAEA,QAAIc,EAAMC,QAAQ,QAAQ;AACxBD,MAAAA,EAAME,eAAAA,GACNhB,EAAU,OAAO;AACjB;AAAA,IACF;AAEA,IAAIc,EAAMC,QAAQ,UAChBD,EAAME,eAAAA,GACNhB,EAAU,MAAM;AAAA,EAEpB,GAEMiB,IAAmBA,CAAC3B,MAAmB;;AAC3CA,KAAAA,IAAAA,EAAK4B,aAAL5B,QAAAA,EAAAA,KAAAA,IACAO,KAAAA,QAAAA,EAAeP,IACfI,EAAAA;AAAAA,EACF;AAEA,SACE,gBAAAyB,EAACC,KACC,cAAYxB,GACZ,WAAWyB,EAAOC,MAClB,WAAWT,GACX,MAAK,QAAM,kBAAA,aAEVzB,YAAMmC,IAAI,CAACjC,GAAMkC,MAChB,gBAAAL,EAAC,QAEC,MAAK,QAEL,4BAACM,GAAA,EACC,cAAYnC,EAAKoC,iBACjB,WAAWC,EAAGN,EAAO/B,MAAMA,EAAKsC,YAAYP,EAAOQ,MAAM,GACzD,UAAUvC,EAAKE,UACf,SAAS,MAAMyB,EAAiB3B,CAAI,GACpC,KAAMwC,CAAAA,MAAS;AACbhC,IAAAA,EAASM,QAAQoB,CAAK,IAAIM;AAAAA,EAC5B,GACA,MAAK,YACL,SAAQ,WAEPxC,UAAAA;AAAAA,IAAAA,EAAKyC,QACJ,gBAAAZ,EAACa,GAAA,EACC,KAAI,SACJ,MAAM1C,EAAKyC,MACX,MAAK,SACL,SAASzC,EAAKsC,WAAW,WAAW,WAAU;AAAA,IAGlD,gBAAAT,EAAC,QAAA,EAAM7B,UAAAA,EAAK2C,MAAAA,CAAM;AAAA,EAAA,EAAA,CACpB,EAAA,GAvBK3C,EAAK4C,MAAMV,CAwBlB,CACD,EAAA,CACH;AAEJ,GAEaW,IAAOA,CAAC;AAAA,EACnB/C,OAAAA;AAAAA,EACAQ,qBAAAA,IAAsB;AAAA,EACtBC,cAAAA;AAAAA,EACAuC,UAAAA,IAAW;AAAA,EACXC,wBAAAA,IAAyB;AAChB,wBAENC,GAAA,EACC,UAAAF,GACA,wBAAAC,GACA,qBAAoB,QACpB,sBACE,gBAAAlB,EAACa,GAAA,EACC,MAAK,QACL,MAAK,SAAA,IAER,kBAAA,QAEA,UAAA,CAAC;AAAA,EAAEtC,OAAAA;AAAAA,EAAOC,cAAAA;AAAAA,wBACRF,GAAA,EACC,OAAAC,GACA,cAAAC,GACA,OAAAP,GACA,qBAAAQ,GACA,cAAAC,GAA2B,GAGjC;"}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});require('../../assets/index24.css');const y=require("react/jsx-runtime"),T=require("../../classix-5H4IWnMA.cjs"),o=require("react"),A=require("../../icons-
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});require('../../assets/index24.css');const y=require("react/jsx-runtime"),T=require("../../classix-5H4IWnMA.cjs"),o=require("react"),A=require("../../icons-o8Z5npPW.cjs"),H=require("../list/index.cjs"),M="_sortable_c1ptl_5",V="_dragging_c1ptl_35",z="_dropping_c1ptl_50",B="_columns_c1ptl_63",N="_pseudo_c1ptl_73",c={sortable:M,dragging:V,dropping:z,columns:B,pseudo:N,"target-above":"_target-above_c1ptl_88","target-below":"_target-below_c1ptl_89"};function k({children:h,className:I,columns:g=1,isRearranging:d=!1,onChangeOrder:f,...b}){const x=Number.isFinite(g)?Math.max(1,Math.floor(g)):1,v=o.useMemo(()=>o.Children.toArray(h),[h]),n=o.useRef(-1),[p,q]=o.useState({height:0,width:0}),[a,m]=o.useState(null),[E,S]=o.useState(null),$={...b.style,"--icon-svg":A.iconSVG("sort",!0),"--height":`calc(${p.height}px - var(--scale-16))`,"--width":x>1?`calc(${p.width}px - var(--scale-16))`:`${p.width}px`},w=()=>{n.current=-1,m(null)};return o.useEffect(()=>{d||S(null)},[d]),y.jsx(H.List,{className:T.t(I,c.sortable,x>1&&c.columns),columns:g,ordered:!0,style:$,...b,"data-component":"sortable",children:v.map((_,t)=>{const j=o.isValidElement(_)?_.key:null;return y.jsx("li",{className:T.t(a!==null&&a>t-10&&a<t+10&&c.pseudo,a===t&&n.current<t&&c["target-below"],a===t&&n.current>t&&c["target-above"],n.current===t&&c.dragging,E===t&&d&&c.dropping),draggable:!d,onDragEnd:()=>w(),onDragOver:e=>{e.preventDefault(),e.dataTransfer.dropEffect="move";const r=n.current;if(r<0||r===t)return;const s=e.currentTarget.getBoundingClientRect(),l=t===r+1?p.height:s.height,u=e.clientY>s.top+l/2?t+1:t,i=u>r?u-1:u;m(i)},onDragStart:e=>{n.current=t,q({height:e.currentTarget.offsetHeight,width:e.currentTarget.offsetWidth}),e.dataTransfer.setData("text/plain",""),e.dataTransfer.effectAllowed="move",m(t)},onDrop:e=>{e.preventDefault();const r=n.current,s=a;if(r<0||s===null||r===s)return;S(s);const l=v.slice(),[D]=l.splice(r,1);l.splice(s,0,D),f==null||f(l.map((u,i)=>({id:String(o.isValidElement(u)?u.props["data-id"]??`idx-${i}`:`idx-${i}`),weight:l.length-1-i}))),w()},"data-component":"sortable",children:_},j??t)})})}exports.Sortable=k;
|
|
2
2
|
//# sourceMappingURL=index.cjs.map
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { jsx as I } from "react/jsx-runtime";
|
|
2
2
|
import { t as T } from "../../classix-DG18itHa.js";
|
|
3
3
|
import _, { useMemo as z, useRef as B, useState as h, useEffect as M } from "react";
|
|
4
|
-
import { i as N } from "../../icons-
|
|
4
|
+
import { i as N } from "../../icons-06oXnjRF.js";
|
|
5
5
|
import { List as k } from "../list/index.js";
|
|
6
6
|
import '../../assets/index24.css';const j = "_sortable_c1ptl_5", F = "_dragging_c1ptl_35", G = "_dropping_c1ptl_50", L = "_columns_c1ptl_63", W = "_pseudo_c1ptl_73", s = {
|
|
7
7
|
sortable: j,
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});require('../../assets/
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});require('../../assets/index28.css');const l=require("react/jsx-runtime"),s=require("../../classix-5H4IWnMA.cjs"),a=require("../link/index.cjs"),t="data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20width='20'%20height='24'%20fill='none'%3e%3cpath%20fill='%23000'%20d='M16.705%2012.763c.012-.92.262-1.822.727-2.622a5.5%205.5%200%200%201%201.933-1.954A5.7%205.7%200%200%200%2017.4%206.478a5.8%205.8%200%200%200-2.54-.669c-1.896-.194-3.734%201.107-4.7%201.107-.985%200-2.472-1.088-4.074-1.056a6.1%206.1%200%200%200-2.93.854%205.9%205.9%200%200%200-2.12%202.153c-2.182%203.69-.554%209.114%201.537%2012.097%201.047%201.46%202.27%203.092%203.87%203.035%201.566-.064%202.15-.975%204.04-.975%201.873%200%202.422.974%204.054.938%201.68-.027%202.74-1.468%203.749-2.942A12%2012%200%200%200%2020%2017.612a5.37%205.37%200%200%201-2.395-1.94%205.2%205.2%200%200%201-.9-2.909M13.62%203.847A5.29%205.29%200%200%200%2014.88%200a5.64%205.64%200%200%200-3.621%201.83%205.1%205.1%200%200%200-1.023%201.726%205%205%200%200%200-.268%201.978c.7.007%201.393-.141%202.025-.433a4.6%204.6%200%200%200%201.629-1.254'/%3e%3c/svg%3e",p="data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20width='74'%20height='15'%3e%3cpath%20d='M57.518%2011.41h1.629V.398h-1.629zm14.67-7.045-1.866%204.774h-.056l-1.938-4.774h-1.755l2.906%206.672-1.656%203.712h1.698L74%204.365zm-9.236%205.794c-.534%200-1.278-.269-1.278-.936%200-.849.926-1.175%201.727-1.175.715%200%201.053.156%201.488.369-.127%201.02-.997%201.742-1.937%201.742m.196-6.035c-1.179%200-2.401.524-2.906%201.686l1.446.609c.309-.609.884-.808%201.488-.808.843%200%201.699.51%201.713%201.417v.113c-.295-.17-.926-.425-1.699-.425-1.558%200-3.145.865-3.145%202.48%200%201.473%201.278%202.422%202.71%202.422%201.095%200%201.7-.495%202.078-1.077h.056v.85h1.572V7.17c0-1.954-1.446-3.045-3.313-3.045M53.082%205.705h-2.316V1.931h2.316c1.218%200%201.91%201.017%201.91%201.887%200%20.853-.692%201.887-1.91%201.887M53.04.398h-3.902V11.41h1.628V7.238h2.274c1.805%200%203.58-1.32%203.58-3.42%200-2.101-1.775-3.42-3.58-3.42m-21.282%209.763c-1.125%200-2.067-.95-2.067-2.256%200-1.32.942-2.285%202.067-2.285%201.112%200%201.983.965%201.983%202.285%200%201.305-.871%202.256-1.983%202.256m1.87-5.18h-.056c-.366-.44-1.068-.837-1.954-.837-1.857%200-3.558%201.646-3.558%203.76%200%202.1%201.701%203.733%203.558%203.733.886%200%201.588-.397%201.954-.852h.057v.54c0%201.433-.76%202.2-1.983%202.2-.999%200-1.618-.725-1.87-1.335l-1.421.596c.408.994%201.49%202.214%203.29%202.214%201.913%200%203.53-1.135%203.53-3.902V4.37H33.63zm2.673%206.429h1.631V.397h-1.631zm4.035-3.633c-.042-1.447%201.111-2.185%201.94-2.185.648%200%201.196.326%201.379.794zM45.4%206.528c-.31-.837-1.252-2.384-3.178-2.384-1.913%200-3.501%201.518-3.501%203.747%200%202.1%201.574%203.746%203.683%203.746%201.702%200%202.687-1.05%203.095-1.66l-1.266-.852c-.422.624-.999%201.036-1.829%201.036s-1.42-.384-1.8-1.135l4.964-2.073zM5.85%205.294v1.589h3.768c-.112.894-.407%201.547-.857%202-.549.554-1.407%201.165-2.91%201.165-2.322%200-4.136-1.888-4.136-4.23%200-2.341%201.814-4.228%204.135-4.228%201.252%200%202.166.497%202.84%201.135l1.112-1.121C8.859.696%207.608%200%205.85%200%202.672%200%200%202.612%200%205.819s2.672%205.818%205.85%205.818c1.715%200%203.009-.568%204.021-1.632%201.042-1.05%201.365-2.526%201.365-3.718%200-.37-.028-.71-.085-.993zm9.67%204.867c-1.124%200-2.095-.937-2.095-2.27%200-1.349.97-2.271%202.096-2.271%201.124%200%202.095.922%202.095%202.27%200%201.334-.97%202.27-2.095%202.27m0-6.017c-2.053%200-3.726%201.575-3.726%203.747%200%202.157%201.673%203.746%203.727%203.746s3.726-1.59%203.726-3.746c0-2.172-1.673-3.747-3.726-3.747m8.13%206.017c-1.125%200-2.096-.937-2.096-2.27%200-1.349.97-2.271%202.096-2.271%201.125%200%202.095.922%202.095%202.27%200%201.334-.97%202.27-2.095%202.27m0-6.017c-2.053%200-3.726%201.575-3.726%203.747%200%202.157%201.673%203.746%203.726%203.746s3.726-1.59%203.726-3.746c0-2.172-1.673-3.747-3.726-3.747'/%3e%3c/svg%3e",g="data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20width='21'%20height='24'%20fill='none'%3e%3cpath%20fill='%23EA4335'%20d='M9.805%2011.462.09%2022.006l.001.006C.39%2023.158%201.411%2024%202.625%2024c.486%200%20.941-.134%201.332-.37l.03-.018%2010.936-6.453z'/%3e%3cpath%20fill='%23FBBC04'%20d='m19.633%209.666-.009-.006-4.721-2.799-5.32%204.84%205.339%205.457%204.696-2.77A2.7%202.7%200%200%200%2021%2012.022a2.69%202.69%200%200%200-1.367-2.356'/%3e%3cpath%20fill='%234285F4'%20d='M.09%201.993a2.7%202.7%200%200%200-.09.69v18.633q0%20.36.09.69L10.14%2011.73z'/%3e%3cpath%20fill='%2334A853'%20d='m9.877%2012%205.027-5.14L3.982.383A2.6%202.6%200%200%200%202.626%200C1.412%200%20.389.844.09%201.99v.003z'/%3e%3c/svg%3e",i="_apple_zdked_17",h="_google_zdked_49",c={"app-link":"_app-link_zdked_1",apple:i,google:h},n=({label:o,type:e})=>l.jsxs(a.Link,{to:e==="apple"?"https://apps.apple.com/app/6478964287":"https://play.google.com/store/apps/details?id=no.solibo.mobile.home",className:s.t(c["app-link"],c[e]),"data-component":"applink",children:[e==="apple"?l.jsx("img",{src:t,alt:"Apple logo"}):l.jsx("img",{src:g,alt:"Google logo"}),l.jsxs("div",{children:[l.jsx("span",{children:o}),l.jsx("span",{children:e==="google"?l.jsx("img",{src:p,alt:"Google Play logo"}):"App Store"})]})]});exports.AppLink=n;
|
|
2
2
|
//# sourceMappingURL=index.cjs.map
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { jsxs as c, jsx as l } from "react/jsx-runtime";
|
|
2
2
|
import { t as a } from "../../classix-DG18itHa.js";
|
|
3
3
|
import { Link as s } from "../link/index.js";
|
|
4
|
-
import '../../assets/
|
|
4
|
+
import '../../assets/index28.css';const t = "data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20width='20'%20height='24'%20fill='none'%3e%3cpath%20fill='%23000'%20d='M16.705%2012.763c.012-.92.262-1.822.727-2.622a5.5%205.5%200%200%201%201.933-1.954A5.7%205.7%200%200%200%2017.4%206.478a5.8%205.8%200%200%200-2.54-.669c-1.896-.194-3.734%201.107-4.7%201.107-.985%200-2.472-1.088-4.074-1.056a6.1%206.1%200%200%200-2.93.854%205.9%205.9%200%200%200-2.12%202.153c-2.182%203.69-.554%209.114%201.537%2012.097%201.047%201.46%202.27%203.092%203.87%203.035%201.566-.064%202.15-.975%204.04-.975%201.873%200%202.422.974%204.054.938%201.68-.027%202.74-1.468%203.749-2.942A12%2012%200%200%200%2020%2017.612a5.37%205.37%200%200%201-2.395-1.94%205.2%205.2%200%200%201-.9-2.909M13.62%203.847A5.29%205.29%200%200%200%2014.88%200a5.64%205.64%200%200%200-3.621%201.83%205.1%205.1%200%200%200-1.023%201.726%205%205%200%200%200-.268%201.978c.7.007%201.393-.141%202.025-.433a4.6%204.6%200%200%200%201.629-1.254'/%3e%3c/svg%3e", g = "data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20width='74'%20height='15'%3e%3cpath%20d='M57.518%2011.41h1.629V.398h-1.629zm14.67-7.045-1.866%204.774h-.056l-1.938-4.774h-1.755l2.906%206.672-1.656%203.712h1.698L74%204.365zm-9.236%205.794c-.534%200-1.278-.269-1.278-.936%200-.849.926-1.175%201.727-1.175.715%200%201.053.156%201.488.369-.127%201.02-.997%201.742-1.937%201.742m.196-6.035c-1.179%200-2.401.524-2.906%201.686l1.446.609c.309-.609.884-.808%201.488-.808.843%200%201.699.51%201.713%201.417v.113c-.295-.17-.926-.425-1.699-.425-1.558%200-3.145.865-3.145%202.48%200%201.473%201.278%202.422%202.71%202.422%201.095%200%201.7-.495%202.078-1.077h.056v.85h1.572V7.17c0-1.954-1.446-3.045-3.313-3.045M53.082%205.705h-2.316V1.931h2.316c1.218%200%201.91%201.017%201.91%201.887%200%20.853-.692%201.887-1.91%201.887M53.04.398h-3.902V11.41h1.628V7.238h2.274c1.805%200%203.58-1.32%203.58-3.42%200-2.101-1.775-3.42-3.58-3.42m-21.282%209.763c-1.125%200-2.067-.95-2.067-2.256%200-1.32.942-2.285%202.067-2.285%201.112%200%201.983.965%201.983%202.285%200%201.305-.871%202.256-1.983%202.256m1.87-5.18h-.056c-.366-.44-1.068-.837-1.954-.837-1.857%200-3.558%201.646-3.558%203.76%200%202.1%201.701%203.733%203.558%203.733.886%200%201.588-.397%201.954-.852h.057v.54c0%201.433-.76%202.2-1.983%202.2-.999%200-1.618-.725-1.87-1.335l-1.421.596c.408.994%201.49%202.214%203.29%202.214%201.913%200%203.53-1.135%203.53-3.902V4.37H33.63zm2.673%206.429h1.631V.397h-1.631zm4.035-3.633c-.042-1.447%201.111-2.185%201.94-2.185.648%200%201.196.326%201.379.794zM45.4%206.528c-.31-.837-1.252-2.384-3.178-2.384-1.913%200-3.501%201.518-3.501%203.747%200%202.1%201.574%203.746%203.683%203.746%201.702%200%202.687-1.05%203.095-1.66l-1.266-.852c-.422.624-.999%201.036-1.829%201.036s-1.42-.384-1.8-1.135l4.964-2.073zM5.85%205.294v1.589h3.768c-.112.894-.407%201.547-.857%202-.549.554-1.407%201.165-2.91%201.165-2.322%200-4.136-1.888-4.136-4.23%200-2.341%201.814-4.228%204.135-4.228%201.252%200%202.166.497%202.84%201.135l1.112-1.121C8.859.696%207.608%200%205.85%200%202.672%200%200%202.612%200%205.819s2.672%205.818%205.85%205.818c1.715%200%203.009-.568%204.021-1.632%201.042-1.05%201.365-2.526%201.365-3.718%200-.37-.028-.71-.085-.993zm9.67%204.867c-1.124%200-2.095-.937-2.095-2.27%200-1.349.97-2.271%202.096-2.271%201.124%200%202.095.922%202.095%202.27%200%201.334-.97%202.27-2.095%202.27m0-6.017c-2.053%200-3.726%201.575-3.726%203.747%200%202.157%201.673%203.746%203.727%203.746s3.726-1.59%203.726-3.746c0-2.172-1.673-3.747-3.726-3.747m8.13%206.017c-1.125%200-2.096-.937-2.096-2.27%200-1.349.97-2.271%202.096-2.271%201.125%200%202.095.922%202.095%202.27%200%201.334-.97%202.27-2.095%202.27m0-6.017c-2.053%200-3.726%201.575-3.726%203.747%200%202.157%201.673%203.746%203.726%203.746s3.726-1.59%203.726-3.746c0-2.172-1.673-3.747-3.726-3.747'/%3e%3c/svg%3e", h = "data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20width='21'%20height='24'%20fill='none'%3e%3cpath%20fill='%23EA4335'%20d='M9.805%2011.462.09%2022.006l.001.006C.39%2023.158%201.411%2024%202.625%2024c.486%200%20.941-.134%201.332-.37l.03-.018%2010.936-6.453z'/%3e%3cpath%20fill='%23FBBC04'%20d='m19.633%209.666-.009-.006-4.721-2.799-5.32%204.84%205.339%205.457%204.696-2.77A2.7%202.7%200%200%200%2021%2012.022a2.69%202.69%200%200%200-1.367-2.356'/%3e%3cpath%20fill='%234285F4'%20d='M.09%201.993a2.7%202.7%200%200%200-.09.69v18.633q0%20.36.09.69L10.14%2011.73z'/%3e%3cpath%20fill='%2334A853'%20d='m9.877%2012%205.027-5.14L3.982.383A2.6%202.6%200%200%200%202.626%200C1.412%200%20.389.844.09%201.99v.003z'/%3e%3c/svg%3e", i = "_apple_zdked_17", m = "_google_zdked_49", e = {
|
|
5
5
|
"app-link": "_app-link_zdked_1",
|
|
6
6
|
apple: i,
|
|
7
7
|
google: m
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});require('../../assets/
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});require('../../assets/index29.css');const n=require("react/jsx-runtime"),c=require("../../classix-5H4IWnMA.cjs"),d="_aside_mn1ep_1",o="_meta_mn1ep_14",m="_sticky_mn1ep_41",e={aside:d,meta:o,sticky:m},r={default:e.default,meta:e.meta},u=({children:s,className:t,sticky:a=!1,variant:i="default"})=>n.jsx("aside",{className:c.t(t&&t,e.aside,a&&e.sticky,r[i]),"data-component":"aside",children:s});exports.Aside=u;
|
|
2
2
|
//# sourceMappingURL=index.cjs.map
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { jsx as m } from "react/jsx-runtime";
|
|
2
2
|
import { t as n } from "../../classix-DG18itHa.js";
|
|
3
|
-
import '../../assets/
|
|
3
|
+
import '../../assets/index29.css';const o = "_aside_mn1ep_1", c = "_meta_mn1ep_14", d = "_sticky_mn1ep_41", t = {
|
|
4
4
|
aside: o,
|
|
5
5
|
meta: c,
|
|
6
6
|
sticky: d
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});require('../../assets/
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});require('../../assets/index30.css');const n=require("react/jsx-runtime"),r=require("../../classix-5H4IWnMA.cjs"),s=require("../button/index.cjs"),c=require("../icon/index.cjs"),d="_badge_j10be_1",m="_primary_j10be_8",l="_info_j10be_13",e={badge:d,primary:m,info:l},u={default:e.default,info:e.info,primary:e.primary},_=({children:t,deleteAccessibleLabel:i="Remove",onDelete:a,variant:o="default"})=>n.jsxs("span",{className:r.t(e.badge,u[o]),"data-component":"badge",children:[t,a&&n.jsx(s.Button,{"aria-label":i,onClick:a,variant:"minimal",children:n.jsx(c.Icon,{name:"x"})})]});exports.Badge=_;
|
|
2
2
|
//# sourceMappingURL=index.cjs.map
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import { jsxs as
|
|
2
|
-
import { t as
|
|
3
|
-
import { Button as
|
|
4
|
-
import { Icon as
|
|
5
|
-
import '../../assets/
|
|
6
|
-
badge:
|
|
7
|
-
primary:
|
|
1
|
+
import { jsxs as e, jsx as o } from "react/jsx-runtime";
|
|
2
|
+
import { t as m } from "../../classix-DG18itHa.js";
|
|
3
|
+
import { Button as s } from "../button/index.js";
|
|
4
|
+
import { Icon as c } from "../icon/index.js";
|
|
5
|
+
import '../../assets/index30.css';const d = "_badge_j10be_1", f = "_primary_j10be_8", p = "_info_j10be_13", a = {
|
|
6
|
+
badge: d,
|
|
7
|
+
primary: f,
|
|
8
8
|
info: p
|
|
9
9
|
}, l = {
|
|
10
10
|
default: a.default,
|
|
@@ -15,9 +15,9 @@ import '../../assets/index29.css';const c = "_badge_17jf9_1", d = "_primary_17jf
|
|
|
15
15
|
deleteAccessibleLabel: i = "Remove",
|
|
16
16
|
onDelete: r,
|
|
17
17
|
variant: t = "default"
|
|
18
|
-
}) => /* @__PURE__ */
|
|
18
|
+
}) => /* @__PURE__ */ e("span", { className: m(a.badge, l[t]), "data-component": "badge", children: [
|
|
19
19
|
n,
|
|
20
|
-
r && /* @__PURE__ */ o(
|
|
20
|
+
r && /* @__PURE__ */ o(s, { "aria-label": i, onClick: r, variant: "minimal", children: /* @__PURE__ */ o(c, { name: "x" }) })
|
|
21
21
|
] });
|
|
22
22
|
export {
|
|
23
23
|
j as Badge
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});require('../../assets/
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});require('../../assets/index31.css');const e=require("react/jsx-runtime"),h=require("../../classix-5H4IWnMA.cjs");function l(a){return`url("data:image/svg+xml, ${encodeURI(a)}")`}const v={logo:'<svg xmlns="http://www.w3.org/2000/svg" viewBox="212.84 265.6 645.02 573.4"><g><path d="m212.84 681.26 8.86-19.64c9.5 6.92 23.67 11.75 37.19 11.75 15.46 0 21.74-5.15 21.74-12.07 0-21.1-65.54-6.6-65.54-48.47 0-19.16 15.46-35.11 47.51-35.11 14.17 0 28.66 3.39 39.13 10l-8.06 19.81c-10.46-6-21.25-8.86-31.24-8.86-15.45 0-21.41 5.8-21.41 12.88 0 20.77 65.54 6.44 65.54 47.82 0 18.84-15.62 34.95-47.83 34.95-17.87 0-35.91-5.32-45.89-13M317.33 636c0-33.5 26.09-58.3 61.68-58.3 35.42 0 61.67 24.64 61.67 58.3s-26.25 58.31-61.68 58.31c-35.59 0-61.68-24.8-61.68-58.29m96.94 0C414.27 614.6 399.14 600 379 600s-35.26 14.6-35.26 36 15.14 36.07 35.27 36.07 35.26-14.66 35.26-36.07m46.04-56.34h26.09v91.46h56.52v21.26h-82.61zm105.3 0h26.09v112.72h-26.09zm156.19 81.96c0 19.48-15.46 30.75-45.08 30.75h-58.3V579.65h55.08c28.18 0 42.67 11.76 42.67 29.31a27.1 27.1 0 0 1-15 24.8c12.56 4 20.61 13.69 20.61 27.86m-77.43-62.32v26.57h25.93c12.72 0 19.64-4.51 19.64-13.36S683 599.3 670.28 599.3Zm51.21 59.58c0-9.5-7.25-14-20.78-14h-30.43v27.86h30.43c13.53 0 20.78-4.19 20.78-13.85M734.51 636c0-33.5 26.09-58.3 61.68-58.3 35.43 0 61.67 24.64 61.67 58.3s-26.24 58.29-61.67 58.29c-35.59 0-61.68-24.8-61.68-58.29m96.94 0c0-21.42-15.13-36.07-35.26-36.07S760.92 614.6 760.92 636s15.14 36.07 35.27 36.07 35.26-14.66 35.26-36.07M535.93 406.9a30.06 30.06 0 1 0-30-30 30.05 30.05 0 0 0 30 30m41.29 72.66v-24.08a41.29 41.29 0 0 0-82.58 0v94.22l28.83-42.58h53.78Z" class="cls-1"/><path d="M675.26 507.22H519.83c-4.07 0 2.55-3.3 2.55-7.36l20-16.14a7.36 7.36 0 0 1 7.36-7.36h94.66a7.37 7.37 0 0 0 7.36-7.36V363.24a7.36 7.36 0 0 0-4-6.55L539 301.09a7.34 7.34 0 0 0-6.72 0L423.74 357a7.37 7.37 0 0 0-4 6.54V469a7.37 7.37 0 0 0 7.37 7.36h29.22v30.86h-60.09a7.37 7.37 0 0 1-7.36-7.36V344.68a7.38 7.38 0 0 1 4-6.55l139.35-71.72a7.37 7.37 0 0 1 6.72 0l139.67 71.4a7.37 7.37 0 0 1 4 6.56v155.5a7.37 7.37 0 0 1-7.36 7.36M380.2 789.7h-53.93v42.19c0 4.76-3.35 5.59-5 5.59s-5-.83-5-5.59v-89.7c0-4.75 3.35-5.59 5-5.59s5 .84 5 5.59v38.29h53.93v-38.29c0-4.75 3.36-5.59 5-5.59s5 .84 5 5.59v89.7c0 4.76-3.35 5.59-5 5.59s-5-.83-5-5.59Zm82.58 49.3c-29.48 0-51.56-21.94-51.56-52s22.08-52 51.56-52 51.56 21.93 51.56 52-22.08 52-51.56 52m0-95.15c-25.43 0-40.94 20.12-40.94 43.17s15.51 43 40.94 43 40.94-20 40.94-43-15.51-43.15-40.94-43.15Zm165.01 93.63c-1.67 0-5-.83-5-5.59v-72.51h-.28l-32.27 73.77a6.53 6.53 0 0 1-12.3 0l-32.3-73.35h-.28v72.09c0 4.76-3.36 5.59-5 5.59s-5-.83-5-5.59v-88.44c0-5.73 4.05-6.85 6.14-6.85s4.75.7 6.85 5.45l35.91 82h.14l35.49-82c2.1-4.75 4.75-5.45 6.85-5.45s6.14 1.12 6.14 6.85v88.44c-.06 4.76-3.41 5.59-5.09 5.59m41.36-48.06v38.14h49c4.2 0 4.89 3.08 4.89 4.48s-.69 4.47-4.89 4.47H665.1c-4.05 0-6-2-6-6v-86.92c0-4.05 2-6 6-6h51.42c4.19 0 4.89 3.07 4.89 4.47s-.7 4.47-4.89 4.47h-47.37v34.1h44c4.2 0 4.89 3.07 4.89 4.33s-.69 4.47-4.89 4.47Z"/></g></svg>'},g="_branding_ganjz_1",i="_white_ganjz_11",c={branding:g,default:"_default_ganjz_7",white:i},r={default:c.default,white:c.white},o=({name:a="logo",size:s=128,variant:t="default"})=>{const n={height:s,maskImage:l(v[a].toString()),width:s};return e.jsx("span",{className:h.t(c.branding,r[t]),style:n,"data-component":"branding"})};exports.Branding=o;
|
|
2
2
|
//# sourceMappingURL=index.cjs.map
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { jsx as h } from "react/jsx-runtime";
|
|
2
2
|
import { t as v } from "../../classix-DG18itHa.js";
|
|
3
|
-
import '../../assets/
|
|
3
|
+
import '../../assets/index31.css';function e(a) {
|
|
4
4
|
return `url("data:image/svg+xml, ${encodeURI(a)}")`;
|
|
5
5
|
}
|
|
6
6
|
const l = {
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});require('../../assets/
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});require('../../assets/index32.css');const e=require("react/jsx-runtime"),l=require("../../classix-5H4IWnMA.cjs"),c=require("../icon/index.cjs"),d="_button_18vba_1",_="_danger_18vba_23",b="_minimal_18vba_36",p="_primary_18vba_43",t={button:d,danger:_,minimal:b,primary:p},g={danger:t.danger,default:t.default,minimal:t.minimal,primary:t.primary};function y({children:i,className:r,disabled:o=!1,icon:a,onClick:s,ref:m,variant:n="default",...u}){return e.jsxs("button",{className:l.t(t.button,g[n],r),disabled:o,onClick:s,ref:m,type:"button",...u,"data-component":"button",children:[a&&e.jsx(c.Icon,{gap:"right",name:a,size:"small",variant:n==="minimal"||n==="default"?"default":"white"}),i]})}exports.Button=y;
|
|
2
2
|
//# sourceMappingURL=index.cjs.map
|
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
import { jsxs as
|
|
2
|
-
import { t as
|
|
3
|
-
import { Icon as
|
|
4
|
-
import '../../assets/
|
|
5
|
-
button:
|
|
6
|
-
danger:
|
|
7
|
-
minimal:
|
|
8
|
-
primary:
|
|
1
|
+
import { jsxs as s, jsx as u } from "react/jsx-runtime";
|
|
2
|
+
import { t as d } from "../../classix-DG18itHa.js";
|
|
3
|
+
import { Icon as p } from "../icon/index.js";
|
|
4
|
+
import '../../assets/index32.css';const _ = "_button_18vba_1", b = "_danger_18vba_23", c = "_minimal_18vba_36", f = "_primary_18vba_43", t = {
|
|
5
|
+
button: _,
|
|
6
|
+
danger: b,
|
|
7
|
+
minimal: c,
|
|
8
|
+
primary: f
|
|
9
9
|
}, g = {
|
|
10
10
|
danger: t.danger,
|
|
11
11
|
default: t.default,
|
|
@@ -16,14 +16,14 @@ function x({
|
|
|
16
16
|
children: m,
|
|
17
17
|
className: r,
|
|
18
18
|
disabled: i = !1,
|
|
19
|
-
icon:
|
|
19
|
+
icon: n,
|
|
20
20
|
onClick: o,
|
|
21
21
|
ref: e,
|
|
22
|
-
variant:
|
|
23
|
-
...
|
|
22
|
+
variant: a = "default",
|
|
23
|
+
...l
|
|
24
24
|
}) {
|
|
25
|
-
return /* @__PURE__ */
|
|
26
|
-
|
|
25
|
+
return /* @__PURE__ */ s("button", { className: d(t.button, g[a], r), disabled: i, onClick: o, ref: e, type: "button", ...l, "data-component": "button", children: [
|
|
26
|
+
n && /* @__PURE__ */ u(p, { gap: "right", name: n, size: "small", variant: a === "minimal" || a === "default" ? "default" : "white" }),
|
|
27
27
|
m
|
|
28
28
|
] });
|
|
29
29
|
}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});require('../../assets/
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});require('../../assets/index33.css');const e=require("react/jsx-runtime"),x=require("../../icons-o8Z5npPW.cjs"),b=require("../loading/index.cjs"),h="_checkbox_1e5vl_1",k={checkbox:h},l=({checked:s,disabled:t,isLoading:c,label:o,onChange:n,...i})=>{const r={"--icon-svg":x.iconSVG("check")};return e.jsxs("label",{className:k.checkbox,"data-component":"checkbox",children:[c&&e.jsx(b.Loading,{size:24,sticky:!0}),e.jsx("input",{checked:s,disabled:t||c,onChange:n,type:"checkbox",style:r,...i}),o&&o]})};exports.Checkbox=l;
|
|
2
2
|
//# sourceMappingURL=index.cjs.map
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { jsxs as h, jsx as e } from "react/jsx-runtime";
|
|
2
|
-
import { i as x } from "../../icons-
|
|
2
|
+
import { i as x } from "../../icons-06oXnjRF.js";
|
|
3
3
|
import { Loading as k } from "../loading/index.js";
|
|
4
|
-
import '../../assets/
|
|
4
|
+
import '../../assets/index33.css';const b = "_checkbox_1e5vl_1", m = {
|
|
5
5
|
checkbox: b
|
|
6
6
|
}, d = ({
|
|
7
7
|
checked: t,
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});require('../../assets/
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});require('../../assets/index34.css');const s=require("react/jsx-runtime"),o=require("../../classix-5H4IWnMA.cjs"),c="_figure_jy92q_1",u="_offset_jy92q_20",r={figure:c,offset:u},f=({accessibleLabel:t,children:i,className:n,offset:e})=>s.jsxs("figure",{className:o.t(r.figure,e&&r.offset,n),style:{...e&&{[`--offset-${e}`]:"calc(var(--utils-tokens-negative-unit) * 2)"}},"data-component":"figure",children:[i,t&&s.jsx("figcaption",{"data-content":"screen-reader",children:t})]});exports.Figure=f;
|
|
2
2
|
//# sourceMappingURL=index.cjs.map
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { jsxs as f, jsx as i } from "react/jsx-runtime";
|
|
2
2
|
import { t as n } from "../../classix-DG18itHa.js";
|
|
3
|
-
import '../../assets/
|
|
3
|
+
import '../../assets/index34.css';const c = "_figure_jy92q_1", a = "_offset_jy92q_20", r = {
|
|
4
4
|
figure: c,
|
|
5
5
|
offset: a
|
|
6
6
|
}, m = ({
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});require('../../assets/
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});require('../../assets/index35.css');const r=require("react/jsx-runtime"),m=require("../../classix-5H4IWnMA.cjs"),a="_form_1sine_1",c="_inline_1sine_26",e={form:a,inline:c},l=({animation:o,children:n,className:t,inline:i=!1,...s})=>r.jsx("form",{className:m.t(t,i&&e.inline,e.form),"data-animation":o,...s,"data-component":"form",children:n&&n});exports.Form=l;
|
|
2
2
|
//# sourceMappingURL=index.cjs.map
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { jsx as e } from "react/jsx-runtime";
|
|
2
2
|
import { t as s } from "../../classix-DG18itHa.js";
|
|
3
|
-
import '../../assets/
|
|
3
|
+
import '../../assets/index35.css';const a = "_form_1sine_1", f = "_inline_1sine_26", o = {
|
|
4
4
|
form: a,
|
|
5
5
|
inline: f
|
|
6
6
|
}, _ = ({
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});require('../../assets/
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});require('../../assets/index36.css');const r=require("react/jsx-runtime"),o=require("../../classix-5H4IWnMA.cjs"),n=require("../../icons-o8Z5npPW.cjs"),l="_icon_1uucz_1",_="_small_1uucz_9",m="_medium_1uucz_14",d="_large_1uucz_19",g="_danger_1uucz_24",p="_primary_1uucz_32",y="_white_1uucz_36",e={icon:l,small:_,medium:m,large:d,danger:g,default:"_default_1uucz_28",primary:p,white:y,"gap-right":"_gap-right_1uucz_40","gap-left":"_gap-left_1uucz_44"},z={large:e.large,medium:e.medium,small:e.small},f={danger:e.danger,default:e.default,primary:e.primary,white:e.white},h=({fill:a,gap:t="none",name:c,size:s="medium",variant:u="default"})=>{const i={maskImage:n.iconSVG(c,a??!1)};return r.jsx("span",{"aria-hidden":"true",className:o.t(t!=="none"&&e[`gap-${t}`],z[s],e.icon,f[u]),style:i,"data-component":"icon"})},w=()=>Object.keys(n.iconPaths);exports.Icon=h;exports.Icons=w;
|
|
2
2
|
//# sourceMappingURL=index.cjs.map
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { jsx as i } from "react/jsx-runtime";
|
|
2
2
|
import { t as o } from "../../classix-DG18itHa.js";
|
|
3
|
-
import { i as u, a as m } from "../../icons-
|
|
4
|
-
import '../../assets/
|
|
3
|
+
import { i as u, a as m } from "../../icons-06oXnjRF.js";
|
|
4
|
+
import '../../assets/index36.css';const _ = "_icon_1uucz_1", l = "_small_1uucz_9", d = "_medium_1uucz_14", g = "_large_1uucz_19", p = "_danger_1uucz_24", f = "_primary_1uucz_32", z = "_white_1uucz_36", a = {
|
|
5
5
|
icon: _,
|
|
6
6
|
small: l,
|
|
7
7
|
medium: d,
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const n=require("react/jsx-runtime"),y=require("../../classix-5H4IWnMA.cjs"),l=require("react"),P=require("../../icons-
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const n=require("react/jsx-runtime"),y=require("../../classix-5H4IWnMA.cjs"),l=require("react"),P=require("../../icons-o8Z5npPW.cjs"),T=require("../../utils-DBzf7CFq.cjs"),s=require("../../styles.module-DvIhipVo.cjs");function b({className:C,defaultCountryCode:h="+47",disabled:a=!1,icon:i,label:d,placeholder:m,ref:v,required:c,type:t="text",...e}){const[r,g]=l.useState(""),[o,x]=l.useState(""),{onChange:N,value:j,...q}=e,{touched:S,onBlur:p}=T.useTouched(j===""),f=i&&t!=="radio"&&t!=="datetime-local"?{"--icon-svg":P.iconSVG(i,!0)}:void 0;l.useEffect(()=>{if(typeof e.onChange=="function"&&t==="tel"){const u={name:e.name,value:o?(r||h).split(" ").join("")+o.split(" ").join(""):void 0};e.onChange({target:u,currentTarget:u})}},[r,o]),l.useEffect(()=>{t==="tel"&&!e.value&&(x(""),g(""))},[e.value,t]);const I=n.jsxs(n.Fragment,{children:[n.jsx("input",{disabled:a,hidden:!0,onChange:N,pattern:void 0,placeholder:m,ref:v,type:t,value:j}),n.jsx("input",{type:"text",className:s.inputStyles.input,disabled:a,maxLength:5,onChange:u=>g(u.target.value),placeholder:h,value:r}),n.jsx("input",{type:"tel",className:y.t(s.inputStyles.input,S&&s.inputStyles.touched),"data-icon":i?"true":void 0,disabled:a,maxLength:14,name:void 0,onChange:u=>x(u.target.value),onBlur:p,pattern:e.pattern,required:c,style:f,value:o,...q})]});return n.jsxs("label",{className:s.inputStyles.label,"data-component":"input",children:[d&&n.jsx("span",{"data-required":c||void 0,children:d}),t==="tel"?I:n.jsx("input",{ref:v,className:y.t(s.inputStyles.input,C,S&&s.inputStyles.touched),"data-icon":i?"true":void 0,disabled:a,onBlur:p,placeholder:m,required:c,style:f,type:t,...e})]})}exports.Input=b;
|
|
2
2
|
//# sourceMappingURL=index.cjs.map
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { jsxs as N, Fragment as w, jsx as o } from "react/jsx-runtime";
|
|
2
2
|
import { t as j } from "../../classix-DG18itHa.js";
|
|
3
3
|
import { useState as S, useEffect as I } from "react";
|
|
4
|
-
import { i as B } from "../../icons-
|
|
4
|
+
import { i as B } from "../../icons-06oXnjRF.js";
|
|
5
5
|
import { u as E } from "../../utils--n2yqjCy.js";
|
|
6
6
|
import { i as a } from "../../styles.module-BUYR37kC.js";
|
|
7
7
|
function A({
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});require('../../assets/
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});require('../../assets/index37.css');const s=require("react/jsx-runtime"),l=require("../../classix-5H4IWnMA.cjs"),m="_link_xhd9q_1",o="_primary_xhd9q_7",c="_danger_xhd9q_13",_="_minimal_xhd9q_21",n={link:m,primary:o,danger:c,minimal:_},d=({children:i,className:r,to:e="#",variant:t="primary",...a})=>s.jsx("a",{className:l.t(r,n.link,n[t]),href:e,...a,"data-component":"link",children:i});exports.Link=d;
|
|
2
2
|
//# sourceMappingURL=index.cjs.map
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { jsx as o } from "react/jsx-runtime";
|
|
2
2
|
import { t as _ } from "../../classix-DG18itHa.js";
|
|
3
|
-
import '../../assets/
|
|
3
|
+
import '../../assets/index37.css';const s = "_link_xhd9q_1", l = "_primary_xhd9q_7", e = "_danger_xhd9q_13", c = "_minimal_xhd9q_21", n = {
|
|
4
4
|
link: s,
|
|
5
5
|
primary: l,
|
|
6
6
|
danger: e,
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});require('../../assets/
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});require('../../assets/index38.css');const c=require("react/jsx-runtime"),_=require("../../classix-5H4IWnMA.cjs"),r=require("../../helpers-BD5fFZi-.cjs"),d="_horizontal_1w5i6_1",w="_list_1w5i6_12",x="_columns_1w5i6_53",s={horizontal:d,list:w,columns:x};function y({children:t,className:a,columns:o=1,horizontal:u,ordered:m,style:h,...l}){const i=Number.isFinite(o)?Math.max(1,Math.floor(o)):1,n=_.t(a,s.list,i>1&&s.columns,u&&s.horizontal),e={...h,"--list-columns":i};return m?c.jsx("ol",{className:n,style:e,...l,"data-component":"list",children:r.wrapChildren(t)}):c.jsx("ul",{className:n,style:e,...l,"data-component":"list",children:r.wrapChildren(t)})}exports.List=y;
|
|
2
2
|
//# sourceMappingURL=index.cjs.map
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { jsx as c } from "react/jsx-runtime";
|
|
2
2
|
import { t as u } from "../../classix-DG18itHa.js";
|
|
3
3
|
import { w as r } from "../../helpers-D56OHkFI.js";
|
|
4
|
-
import '../../assets/
|
|
4
|
+
import '../../assets/index38.css';const w = "_horizontal_1w5i6_1", f = "_list_1w5i6_12", p = "_columns_1w5i6_53", t = {
|
|
5
5
|
horizontal: w,
|
|
6
6
|
list: f,
|
|
7
7
|
columns: p
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});require('../../assets/
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});require('../../assets/index39.css');const t=require("react/jsx-runtime"),i=require("../../classix-5H4IWnMA.cjs"),d="_loading_2k531_23",l="_spin_2k531_1",_="_ping_2k531_39",r="_sticky_2k531_65",n={loading:d,default:"_default_2k531_28",spin:l,ping:_,sticky:r},g=({variant:o="default",size:s,sticky:a=!1,...e})=>{const c={"--border-size":s?s/8+"px":void 0,"--size":s?s+"px":void 0};return t.jsx("div",{className:i.t(n.loading,a&&n.sticky),"data-component":"loading",children:t.jsx("span",{className:i.t(n.loading,n[o]),style:c,...e})})};exports.Loading=g;
|
|
2
2
|
//# sourceMappingURL=index.cjs.map
|
|
@@ -1,24 +1,24 @@
|
|
|
1
1
|
import { jsx as s } from "react/jsx-runtime";
|
|
2
2
|
import { t } from "../../classix-DG18itHa.js";
|
|
3
|
-
import '../../assets/
|
|
3
|
+
import '../../assets/index39.css';const l = "_loading_2k531_23", _ = "_spin_2k531_1", p = "_ping_2k531_39", e = "_sticky_2k531_65", o = {
|
|
4
4
|
loading: l,
|
|
5
|
-
default: "
|
|
5
|
+
default: "_default_2k531_28",
|
|
6
6
|
spin: _,
|
|
7
7
|
ping: p,
|
|
8
8
|
sticky: e
|
|
9
|
-
},
|
|
9
|
+
}, k = ({
|
|
10
10
|
variant: i = "default",
|
|
11
11
|
size: n,
|
|
12
|
-
sticky:
|
|
13
|
-
...
|
|
12
|
+
sticky: a = !1,
|
|
13
|
+
...d
|
|
14
14
|
}) => {
|
|
15
15
|
const c = {
|
|
16
16
|
"--border-size": n ? n / 8 + "px" : void 0,
|
|
17
17
|
"--size": n ? n + "px" : void 0
|
|
18
18
|
};
|
|
19
|
-
return /* @__PURE__ */ s("div", { className: t(o.loading,
|
|
19
|
+
return /* @__PURE__ */ s("div", { className: t(o.loading, a && o.sticky), "data-component": "loading", children: /* @__PURE__ */ s("span", { className: t(o.loading, o[i]), style: c, ...d }) });
|
|
20
20
|
};
|
|
21
21
|
export {
|
|
22
|
-
|
|
22
|
+
k as Loading
|
|
23
23
|
};
|
|
24
24
|
//# sourceMappingURL=index.js.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});require('../../assets/
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});require('../../assets/index40.css');const s=require("react/jsx-runtime"),i=require("../../classix-5H4IWnMA.cjs"),r=require("../icon/index.cjs"),c="_message_1whow_1",m="_preview_1whow_40",t={message:c,preview:m},g=({content:a,id:n,preview:o,type:e="default"})=>s.jsxs("div",{className:i.t(t.message,o&&t.preview),"data-id":n,"data-type":e,"data-component":"message",children:[e=="system"&&s.jsx(r.Icon,{gap:"right",name:"info"}),a]});exports.Message=g;
|
|
2
2
|
//# sourceMappingURL=index.cjs.map
|
|
@@ -1,19 +1,19 @@
|
|
|
1
|
-
import { jsxs as
|
|
1
|
+
import { jsxs as m, jsx as r } from "react/jsx-runtime";
|
|
2
2
|
import { t as i } from "../../classix-DG18itHa.js";
|
|
3
3
|
import { Icon as n } from "../icon/index.js";
|
|
4
|
-
import '../../assets/
|
|
4
|
+
import '../../assets/index40.css';const p = "_message_1whow_1", c = "_preview_1whow_40", s = {
|
|
5
5
|
message: p,
|
|
6
6
|
preview: c
|
|
7
|
-
},
|
|
7
|
+
}, _ = ({
|
|
8
8
|
content: t,
|
|
9
9
|
id: a,
|
|
10
|
-
preview:
|
|
10
|
+
preview: o,
|
|
11
11
|
type: e = "default"
|
|
12
|
-
}) => /* @__PURE__ */
|
|
12
|
+
}) => /* @__PURE__ */ m("div", { className: i(s.message, o && s.preview), "data-id": a, "data-type": e, "data-component": "message", children: [
|
|
13
13
|
e == "system" && /* @__PURE__ */ r(n, { gap: "right", name: "info" }),
|
|
14
14
|
t
|
|
15
15
|
] });
|
|
16
16
|
export {
|
|
17
|
-
|
|
17
|
+
_ as Message
|
|
18
18
|
};
|
|
19
19
|
//# sourceMappingURL=index.js.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});require('../../assets/
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});require('../../assets/index41.css');const p=require("react/jsx-runtime"),_=require("../../classix-5H4IWnMA.cjs"),f=require("react"),v=require("../../icons-o8Z5npPW.cjs"),h="_nav_15tsi_1",b="_horizontal_15tsi_7",g="_tabs_15tsi_17",m="_pills_15tsi_38",t={nav:h,horizontal:b,tabs:g,pills:m},w={default:t.default,pills:t.pills,tabs:t.tabs},q=({animation:i,children:o,className:l,horizontal:e=!1,variant:s="default",...r})=>{const[c,a]=f.useState(!1),u={"--icon-svg":v.iconSVG("chevron")};return p.jsx("nav",{className:_.t(l,e&&t.horizontal,t.nav,w[s]),"data-animation":i,"data-open":c?"true":"false","data-orientation":e?"horizontal":"vertical",onBlurCapture:n=>{if(s!=="pills"||window.innerWidth>960)return;const d=n.relatedTarget;n.currentTarget.contains(d)||a(!1)},onClick:()=>{s!=="pills"||window.innerWidth>960||a(n=>!n)},style:u,...r,"data-component":"nav",children:o})};exports.Nav=q;
|
|
2
2
|
//# sourceMappingURL=index.cjs.map
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { jsx as d } from "react/jsx-runtime";
|
|
2
2
|
import { t as _ } from "../../classix-DG18itHa.js";
|
|
3
3
|
import { useState as m } from "react";
|
|
4
|
-
import { i as u } from "../../icons-
|
|
5
|
-
import '../../assets/
|
|
4
|
+
import { i as u } from "../../icons-06oXnjRF.js";
|
|
5
|
+
import '../../assets/index41.css';const v = "_nav_15tsi_1", h = "_horizontal_15tsi_7", b = "_tabs_15tsi_17", w = "_pills_15tsi_38", t = {
|
|
6
6
|
nav: v,
|
|
7
7
|
horizontal: h,
|
|
8
8
|
tabs: b,
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});require('../../assets/index42.css');const a=require("react/jsx-runtime"),g=require("../../classix-5H4IWnMA.cjs"),o=require("react"),R=require("../button/index.cjs"),x="_popover_ttn4t_1",F="_left_ttn4t_23",P="_right_ttn4t_28",b="_trigger_ttn4t_33",s={popover:x,"popover-panel":"_popover-panel_ttn4t_6",left:F,right:P,trigger:b},j=({children:i,position:_="left",triggerAccessibleLabel:m,triggerAriaHasPopup:y,triggerButtonContent:w})=>{const u=o.useRef(null),l=o.useRef(void 0),p=o.useId(),f=o.useRef(null),[t,d]=o.useState(!1),c=({initialFocus:e}={})=>{l.current=e,d(!0)},n=o.useCallback(({restoreFocus:e=!0}={})=>{var r;d(!1),e&&((r=f.current)==null||r.focus())},[]),h=e=>{t&&e.key==="Escape"&&n()},D=e=>{if(!t){if(e.key==="ArrowDown"){e.preventDefault(),c({initialFocus:"first"});return}e.key==="ArrowUp"&&(e.preventDefault(),c({initialFocus:"last"}))}};return o.useEffect(()=>{if(!t)return;const e=r=>{var v;(v=u.current)!=null&&v.contains(r.target)||n({restoreFocus:!1})};return document.addEventListener("mousedown",e),()=>{document.removeEventListener("mousedown",e)}},[n,t]),a.jsxs("div",{className:s.popover,onKeyDown:h,ref:u,"data-component":"popover",children:[a.jsx(R.Button,{"aria-controls":t?p:void 0,"aria-expanded":t,"aria-haspopup":y,"aria-label":m,className:g.t(s.trigger),onKeyDown:D,onClick:()=>t?n({restoreFocus:!1}):c(),ref:f,variant:"minimal",children:w}),t&&a.jsx("div",{className:g.t(s["popover-panel"],s[_]),id:p,children:typeof i=="function"?i({close:n,initialFocus:l.current,isOpen:t}):i})]})};exports.Popover=j;
|
|
2
|
+
//# sourceMappingURL=index.cjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.cjs","sources":["../../../src/components/popover/index.tsx"],"sourcesContent":["import cx from 'classix';\nimport {\n type AriaAttributes,\n type ReactNode,\n useCallback,\n useEffect,\n useId,\n useRef,\n useState,\n} from 'react';\n\nimport { Button } from '@/components/button';\n\nimport styles from './styles.module.css';\n\nexport type PopoverCloseOptions = {\n restoreFocus?: boolean;\n};\n\nexport type PopoverInitialFocus = 'first' | 'last';\n\nexport type PopoverRenderProps = {\n close: (options?: PopoverCloseOptions) => void;\n initialFocus?: PopoverInitialFocus;\n isOpen: boolean;\n};\n\ntype PopoverOpenOptions = {\n initialFocus?: PopoverInitialFocus;\n};\n\nexport type PopoverProps = {\n children: ReactNode | ((props: PopoverRenderProps) => ReactNode);\n position?: 'left' | 'right';\n triggerAccessibleLabel?: string;\n triggerAriaHasPopup?: AriaAttributes['aria-haspopup'];\n triggerButtonContent: ReactNode;\n};\n\nexport const Popover = ({\n children,\n position = 'left',\n triggerAccessibleLabel,\n triggerAriaHasPopup,\n triggerButtonContent,\n}: PopoverProps) => {\n const containerRef = useRef<HTMLDivElement>(null);\n const initialFocusRef = useRef<PopoverInitialFocus | undefined>(undefined);\n const panelId = useId();\n const triggerRef = useRef<HTMLButtonElement>(null);\n const [isOpen, setIsOpen] = useState(false);\n\n const openPopover = ({ initialFocus }: PopoverOpenOptions = {}) => {\n initialFocusRef.current = initialFocus;\n setIsOpen(true);\n };\n\n const closePopover = useCallback(({ restoreFocus = true }: PopoverCloseOptions = {}) => {\n setIsOpen(false);\n\n if (restoreFocus) {\n triggerRef.current?.focus();\n }\n }, []);\n\n const handleKeyDown = (event: React.KeyboardEvent<HTMLDivElement>) => {\n if (isOpen && event.key === 'Escape') {\n closePopover();\n }\n };\n\n const handleTriggerKeyDown = (event: React.KeyboardEvent<HTMLButtonElement>) => {\n if (isOpen) {\n return;\n }\n\n if (event.key === 'ArrowDown') {\n event.preventDefault();\n openPopover({ initialFocus: 'first' });\n return;\n }\n\n if (event.key === 'ArrowUp') {\n event.preventDefault();\n openPopover({ initialFocus: 'last' });\n }\n };\n\n useEffect(() => {\n if (!isOpen) {\n return;\n }\n\n const handlePointerDown = (event: MouseEvent) => {\n if (!containerRef.current?.contains(event.target as Node)) {\n closePopover({ restoreFocus: false });\n }\n };\n\n document.addEventListener('mousedown', handlePointerDown);\n\n return () => {\n document.removeEventListener('mousedown', handlePointerDown);\n };\n }, [closePopover, isOpen]);\n\n return (\n <div\n className={styles.popover}\n onKeyDown={handleKeyDown}\n ref={containerRef}\n >\n <Button\n aria-controls={isOpen ? panelId : undefined}\n aria-expanded={isOpen}\n aria-haspopup={triggerAriaHasPopup}\n aria-label={triggerAccessibleLabel}\n className={cx(styles.trigger)}\n onKeyDown={handleTriggerKeyDown}\n onClick={() => (isOpen ? closePopover({ restoreFocus: false }) : openPopover())}\n ref={triggerRef}\n variant='minimal'\n >\n {triggerButtonContent}\n </Button>\n {isOpen && (\n <div\n className={cx(styles['popover-panel'], styles[position])}\n id={panelId}\n >\n {typeof children === 'function'\n ? children({ close: closePopover, initialFocus: initialFocusRef.current, isOpen })\n : children}\n </div>\n )}\n </div>\n );\n};\n"],"names":["Popover","children","position","triggerAccessibleLabel","triggerAriaHasPopup","triggerButtonContent","containerRef","useRef","initialFocusRef","undefined","panelId","useId","triggerRef","isOpen","setIsOpen","useState","openPopover","initialFocus","current","closePopover","useCallback","restoreFocus","focus","handleKeyDown","event","key","handleTriggerKeyDown","preventDefault","useEffect","handlePointerDown","contains","target","document","addEventListener","removeEventListener","jsxs","styles","popover","jsx","Button","cx","trigger","close"],"mappings":"mXAuCaA,EAAUA,CAAC,CACtBC,SAAAA,EACAC,SAAAA,EAAW,OACXC,uBAAAA,EACAC,oBAAAA,EACAC,qBAAAA,CACY,IAAM,CAClB,MAAMC,EAAeC,EAAAA,OAAuB,IAAI,EAC1CC,EAAkBD,EAAAA,OAAwCE,MAAS,EACnEC,EAAUC,EAAAA,MAAAA,EACVC,EAAaL,EAAAA,OAA0B,IAAI,EAC3C,CAACM,EAAQC,CAAS,EAAIC,EAAAA,SAAS,EAAK,EAEpCC,EAAcA,CAAC,CAAEC,aAAAA,CAAAA,EAAqC,KAAO,CACjET,EAAgBU,QAAUD,EAC1BH,EAAU,EAAI,CAChB,EAEMK,EAAeC,EAAAA,YAAY,CAAC,CAAEC,aAAAA,EAAe,EAAA,EAA8B,KAAO,OACtFP,EAAU,EAAK,EAEXO,KACFT,EAAAA,EAAWM,UAAXN,MAAAA,EAAoBU,QAExB,EAAG,CAAA,CAAE,EAECC,EAAiBC,GAA+C,CAChEX,GAAUW,EAAMC,MAAQ,UAC1BN,EAAAA,CAEJ,EAEMO,EAAwBF,GAAkD,CAC9E,GAAIX,CAAAA,EAIJ,IAAIW,EAAMC,MAAQ,YAAa,CAC7BD,EAAMG,eAAAA,EACNX,EAAY,CAAEC,aAAc,OAAA,CAAS,EACrC,MACF,CAEIO,EAAMC,MAAQ,YAChBD,EAAMG,eAAAA,EACNX,EAAY,CAAEC,aAAc,MAAA,CAAQ,GAExC,EAEAW,OAAAA,EAAAA,UAAU,IAAM,CACd,GAAI,CAACf,EACH,OAGF,MAAMgB,EAAqBL,GAAsB,QAC1ClB,EAAAA,EAAaY,UAAbZ,MAAAA,EAAsBwB,SAASN,EAAMO,SACxCZ,EAAa,CAAEE,aAAc,EAAA,CAAO,CAExC,EAEAW,gBAASC,iBAAiB,YAAaJ,CAAiB,EAEjD,IAAM,CACXG,SAASE,oBAAoB,YAAaL,CAAiB,CAC7D,CACF,EAAG,CAACV,EAAcN,CAAM,CAAC,EAGvBsB,EAAAA,KAAC,MAAA,CACC,UAAWC,EAAOC,QAClB,UAAWd,EACX,IAAKjB,EAAa,iBAAA,UAElB,SAAA,CAAAgC,EAAAA,IAACC,EAAAA,OAAA,CACC,gBAAe1B,EAASH,EAAUD,OAClC,gBAAeI,EACf,gBAAeT,EACf,aAAYD,EACZ,UAAWqC,EAAAA,EAAGJ,EAAOK,OAAO,EAC5B,UAAWf,EACX,QAAS,IAAOb,EAASM,EAAa,CAAEE,aAAc,EAAA,CAAO,EAAIL,EAAAA,EACjE,IAAKJ,EACL,QAAQ,UAEPP,SAAAA,EACH,EACCQ,GACCyB,EAAAA,IAAC,MAAA,CACC,UAAWE,IAAGJ,EAAO,eAAe,EAAGA,EAAOlC,CAAQ,CAAC,EACvD,GAAIQ,EAEH,SAAA,OAAOT,GAAa,WACjBA,EAAS,CAAEyC,MAAOvB,EAAcF,aAAcT,EAAgBU,QAASL,OAAAA,CAAAA,CAAQ,EAC/EZ,CAAAA,CACN,CAAA,EAEJ,CAEJ"}
|