wimui 0.38.0 → 0.40.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.
@@ -1,2 +1,2 @@
1
1
  "use client";
2
- const e=require("../../../_virtual/_rolldown/runtime.cjs"),t=require("../../../node_modules/@radix-ui/react-slot/dist/index.cjs"),n=require("../../media/Icon/Icon.cjs"),r=require("./swipe-action.module.cjs"),i=require("./SwipeableList.cjs");let a=require("react");a=e.__toESM(a,1);let o=require("classnames");o=e.__toESM(o,1);let s=require("react/jsx-runtime");var c=a.default.forwardRef(({as:e=`div`,leftActions:c=[],rightActions:l=[],children:u,asChild:d=!1,id:f,closeOnAction:p=!0,className:m,...h},g)=>{let _=(0,a.useId)(),v=f||_,y=i.useSwipeableList(),[b,x]=(0,a.useState)(0),[S,C]=(0,a.useState)(!1),w=(0,a.useRef)(0),T=(0,a.useRef)(0),E=(0,a.useRef)(null);(0,a.useImperativeHandle)(g,()=>({close:()=>{x(0),y?.reportClose(v)}}));let D=(0,a.useRef)(!1);(0,a.useEffect)(()=>{if(S){D.current=!0;return}if(D.current){let e=setTimeout(()=>{D.current=!1},100);return()=>clearTimeout(e)}y?.openedId&&y.openedId!==v&&x(0)},[y?.openedId,v,S]);let O=c.length*80,k=l.length*80,A=e=>{w.current=`touches`in e?e.touches[0].clientX:e.clientX,T.current=b,C(!0)},j=e=>{if(!S)return;let t=(`touches`in e?e.touches[0].clientX:e.clientX)-w.current,n=T.current+t;Math.abs(t)>5&&y?.openedId!==v&&y?.reportOpen(v),n>O&&(n=O+(n-O)*.3),n<-k&&(n=-k+(n+k)*.3),x(n)},M=()=>{S&&(C(!1),b>O/2?(x(O),y?.reportOpen(v)):b<-k/2?(x(-k),y?.reportOpen(v)):(x(0),y?.reportClose(v)))},N=d?t.Root:`div`;return(0,s.jsxs)(e,{ref:E,className:(0,o.default)(`wim-swipe-action`,r.default.container,m),onMouseLeave:M,...h,children:[O>0&&(0,s.jsx)(`div`,{className:(0,o.default)(r.default.actions,r.default.left),style:{width:O},children:c.map((e,t)=>(0,s.jsxs)(`button`,{className:(0,o.default)(r.default.action,e.intent&&r.default[e.intent]),style:{backgroundColor:e.color},onClick:()=>{e.onClick(),p&&(x(0),y?.reportClose(v))},type:`button`,children:[(0,s.jsx)(n.Icon,{name:e.icon,size:`md`}),(0,s.jsx)(`span`,{className:r.default.label,children:e.label})]},t))}),k>0&&(0,s.jsx)(`div`,{className:(0,o.default)(r.default.actions,r.default.right),style:{width:k},children:l.map((e,t)=>(0,s.jsxs)(`button`,{className:(0,o.default)(r.default.action,e.intent&&r.default[e.intent]),style:{backgroundColor:e.color},onClick:()=>{e.onClick(),p&&(x(0),y?.reportClose(v))},type:`button`,children:[(0,s.jsx)(n.Icon,{name:e.icon,size:`md`}),(0,s.jsx)(`span`,{className:r.default.label,children:e.label})]},t))}),(0,s.jsx)(N,{className:r.default.content,style:{transform:`translateX(${b}px)`,transition:S?`none`:`transform 0.4s cubic-bezier(0.16, 1, 0.3, 1)`},onTouchStart:A,onTouchMove:j,onTouchEnd:M,onMouseDown:A,onMouseMove:j,onMouseUp:M,children:u})]})});c.displayName=`SwipeAction`,exports.SwipeAction=c;
2
+ const e=require("../../../_virtual/_rolldown/runtime.cjs"),t=require("../../../node_modules/@radix-ui/react-slot/dist/index.cjs"),n=require("../../media/Icon/Icon.cjs"),r=require("./swipe-action.module.cjs"),i=require("./SwipeableList.cjs");let a=require("react");a=e.__toESM(a,1);let o=require("classnames");o=e.__toESM(o,1);let s=require("react/jsx-runtime");var c=a.default.forwardRef(({as:e=`div`,leftActions:c=[],rightActions:l=[],children:u,asChild:d=!1,id:f,closeOnAction:p=!0,fullSwipe:m,className:h,...g},_)=>{let v=(0,a.useId)(),y=f||v,b=i.useSwipeableList(),[x,S]=(0,a.useState)(0),[C,w]=(0,a.useState)(!1),T=(0,a.useRef)(0),E=(0,a.useRef)(0),D=(0,a.useRef)(null);(0,a.useImperativeHandle)(_,()=>({close:()=>{S(0),b?.reportClose(y)}}));let O=(0,a.useRef)(!1);(0,a.useEffect)(()=>{if(C){O.current=!0;return}if(O.current){let e=setTimeout(()=>{O.current=!1},100);return()=>clearTimeout(e)}b?.openedId&&b.openedId!==y&&S(0)},[b?.openedId,y,C]);let k=c.length*80,A=l.length*80,j=k>0&&(m===`left`||m===`both`),M=A>0&&(m===`right`||m===`both`),N=D.current?.offsetWidth??0,P=e=>Math.max(e+40,N/2),F=C&&j&&x>=P(k)?`left`:C&&M&&-x>=P(A)?`right`:null,I=e=>{T.current=`touches`in e?e.touches[0].clientX:e.clientX,E.current=x,w(!0)},L=e=>{if(!C)return;let t=(`touches`in e?e.touches[0].clientX:e.clientX)-T.current,n=E.current+t;Math.abs(t)>5&&b?.openedId!==y&&b?.reportOpen(y),n>k&&!j&&(n=k+(n-k)*.3),n<-A&&!M&&(n=-A+(n+A)*.3),S(n)},R=(e=!0)=>{if(C){if(w(!1),F){let t=F===`left`?c[0]:l[l.length-1];if(e){W(t),p||(S(F===`left`?k:-A),b?.reportOpen(y));return}}x>k/2?(S(k),b?.reportOpen(y)):x<-A/2?(S(-A),b?.reportOpen(y)):(S(0),b?.reportClose(y))}},z=d?t.Root:`div`,B=(0,a.useRef)(null),V=k>0||A>0,H=e=>{let t=e===`left`?k:-A;x!==t&&S(t),b?.reportOpen(y)},U=e=>{let t=e.relatedTarget;t&&D.current?.contains(t)||x!==0&&!C&&(S(0),b?.reportClose(y))},W=(e,t)=>{e.onClick(),p&&(S(0),b?.reportClose(y),t&&document.activeElement===t&&B.current?.focus())},G=(e,t,i)=>{let a=e===`left`?j:M,c=e===`left`?Math.max(0,x):Math.max(0,-x),l=e===`left`?0:t.length-1;return(0,s.jsx)(`div`,{className:(0,o.default)(r.default.actions,r.default[e],a&&c>i&&r.default.stretched,F===e&&r.default.armed),style:{width:a?Math.max(i,c):i,"--_action-w":`80px`},children:t.map((t,i)=>(0,s.jsxs)(`button`,{className:(0,o.default)(r.default.action,t.intent&&r.default[t.intent],a&&i===l&&r.default.outer),style:{backgroundColor:t.color},onFocus:()=>H(e),onClick:e=>W(t,e.currentTarget),type:`button`,children:[(0,s.jsx)(n.Icon,{name:t.icon,size:`md`}),(0,s.jsx)(`span`,{className:r.default.label,children:t.label})]},i))})};return(0,s.jsxs)(e,{ref:D,className:(0,o.default)(`wim-swipe-action`,r.default.container,h),onMouseLeave:()=>R(!1),onBlur:U,...g,children:[(0,s.jsx)(z,{ref:B,className:r.default.content,tabIndex:V?-1:void 0,style:{transform:`translateX(${x}px)`,transition:C?`none`:`transform 0.4s cubic-bezier(0.16, 1, 0.3, 1)`},onTouchStart:I,onTouchMove:L,onTouchEnd:()=>R(),onMouseDown:I,onMouseMove:L,onMouseUp:()=>R(),children:u}),k>0&&G(`left`,c,k),A>0&&G(`right`,l,A)]})});c.displayName=`SwipeAction`,exports.SwipeAction=c;
@@ -27,6 +27,12 @@ export interface SwipeActionProps extends React.HTMLAttributes<HTMLDivElement> {
27
27
  id?: string;
28
28
  /** Whether to automatically close the actions when an action is clicked. Default is true. */
29
29
  closeOnAction?: boolean;
30
+ /**
31
+ * Sides where swiping all the way across runs the outermost action without a tap
32
+ * (`leftActions[0]` / the last of `rightActions`), as in iOS Mail. Off by default so a
33
+ * destructive action is never triggered by momentum; the action stays available as a button.
34
+ */
35
+ fullSwipe?: "left" | "right" | "both";
30
36
  }
31
37
  export interface SwipeActionRef {
32
38
  /** Method to programmatically close the swipe actions */
@@ -7,96 +7,103 @@ import i, { useEffect as a, useId as o, useImperativeHandle as s, useRef as c, u
7
7
  import u from "classnames";
8
8
  import { jsx as d, jsxs as f } from "react/jsx-runtime";
9
9
  //#region src/components/data-display/SwipeAction/SwipeAction.tsx
10
- var p = i.forwardRef(({ as: i = "div", leftActions: p = [], rightActions: m = [], children: h, asChild: g = !1, id: _, closeOnAction: v = !0, className: y, ...b }, x) => {
11
- let S = o(), C = _ || S, w = r(), [T, E] = l(0), [D, O] = l(!1), k = c(0), A = c(0), j = c(null);
12
- s(x, () => ({ close: () => {
13
- E(0), w?.reportClose(C);
10
+ var p = i.forwardRef(({ as: i = "div", leftActions: p = [], rightActions: m = [], children: h, asChild: g = !1, id: _, closeOnAction: v = !0, fullSwipe: y, className: b, ...x }, S) => {
11
+ let C = o(), w = _ || C, T = r(), [E, D] = l(0), [O, k] = l(!1), A = c(0), j = c(0), M = c(null);
12
+ s(S, () => ({ close: () => {
13
+ D(0), T?.reportClose(w);
14
14
  } }));
15
- let M = c(!1);
15
+ let N = c(!1);
16
16
  a(() => {
17
- if (D) {
18
- M.current = !0;
17
+ if (O) {
18
+ N.current = !0;
19
19
  return;
20
20
  }
21
- if (M.current) {
21
+ if (N.current) {
22
22
  let e = setTimeout(() => {
23
- M.current = !1;
23
+ N.current = !1;
24
24
  }, 100);
25
25
  return () => clearTimeout(e);
26
26
  }
27
- w?.openedId && w.openedId !== C && E(0);
27
+ T?.openedId && T.openedId !== w && D(0);
28
28
  }, [
29
- w?.openedId,
30
- C,
31
- D
29
+ T?.openedId,
30
+ w,
31
+ O
32
32
  ]);
33
- let N = p.length * 80, P = m.length * 80, F = (e) => {
34
- k.current = "touches" in e ? e.touches[0].clientX : e.clientX, A.current = T, O(!0);
35
- }, I = (e) => {
36
- if (!D) return;
37
- let t = ("touches" in e ? e.touches[0].clientX : e.clientX) - k.current, n = A.current + t;
38
- Math.abs(t) > 5 && w?.openedId !== C && w?.reportOpen(C), n > N && (n = N + (n - N) * .3), n < -P && (n = -P + (n + P) * .3), E(n);
39
- }, L = () => {
40
- D && (O(!1), T > N / 2 ? (E(N), w?.reportOpen(C)) : T < -P / 2 ? (E(-P), w?.reportOpen(C)) : (E(0), w?.reportClose(C)));
41
- }, R = g ? e : "div";
33
+ let P = p.length * 80, F = m.length * 80, I = P > 0 && (y === "left" || y === "both"), L = F > 0 && (y === "right" || y === "both"), R = M.current?.offsetWidth ?? 0, z = (e) => Math.max(e + 40, R / 2), B = O && I && E >= z(P) ? "left" : O && L && -E >= z(F) ? "right" : null, V = (e) => {
34
+ A.current = "touches" in e ? e.touches[0].clientX : e.clientX, j.current = E, k(!0);
35
+ }, H = (e) => {
36
+ if (!O) return;
37
+ let t = ("touches" in e ? e.touches[0].clientX : e.clientX) - A.current, n = j.current + t;
38
+ Math.abs(t) > 5 && T?.openedId !== w && T?.reportOpen(w), n > P && !I && (n = P + (n - P) * .3), n < -F && !L && (n = -F + (n + F) * .3), D(n);
39
+ }, U = (e = !0) => {
40
+ if (O) {
41
+ if (k(!1), B) {
42
+ let t = B === "left" ? p[0] : m[m.length - 1];
43
+ if (e) {
44
+ Y(t), v || (D(B === "left" ? P : -F), T?.reportOpen(w));
45
+ return;
46
+ }
47
+ }
48
+ E > P / 2 ? (D(P), T?.reportOpen(w)) : E < -F / 2 ? (D(-F), T?.reportOpen(w)) : (D(0), T?.reportClose(w));
49
+ }
50
+ }, W = g ? e : "div", G = c(null), K = P > 0 || F > 0, q = (e) => {
51
+ let t = e === "left" ? P : -F;
52
+ E !== t && D(t), T?.reportOpen(w);
53
+ }, J = (e) => {
54
+ let t = e.relatedTarget;
55
+ t && M.current?.contains(t) || E !== 0 && !O && (D(0), T?.reportClose(w));
56
+ }, Y = (e, t) => {
57
+ e.onClick(), v && (D(0), T?.reportClose(w), t && document.activeElement === t && G.current?.focus());
58
+ }, X = (e, r, i) => {
59
+ let a = e === "left" ? I : L, o = e === "left" ? Math.max(0, E) : Math.max(0, -E), s = e === "left" ? 0 : r.length - 1;
60
+ return /* @__PURE__ */ d("div", {
61
+ className: u(n.actions, n[e], a && o > i && n.stretched, B === e && n.armed),
62
+ style: {
63
+ width: a ? Math.max(i, o) : i,
64
+ "--_action-w": "80px"
65
+ },
66
+ children: r.map((r, i) => /* @__PURE__ */ f("button", {
67
+ className: u(n.action, r.intent && n[r.intent], a && i === s && n.outer),
68
+ style: { backgroundColor: r.color },
69
+ onFocus: () => q(e),
70
+ onClick: (e) => Y(r, e.currentTarget),
71
+ type: "button",
72
+ children: [/* @__PURE__ */ d(t, {
73
+ name: r.icon,
74
+ size: "md"
75
+ }), /* @__PURE__ */ d("span", {
76
+ className: n.label,
77
+ children: r.label
78
+ })]
79
+ }, i))
80
+ });
81
+ };
42
82
  return /* @__PURE__ */ f(i, {
43
- ref: j,
44
- className: u("wim-swipe-action", n.container, y),
45
- onMouseLeave: L,
46
- ...b,
83
+ ref: M,
84
+ className: u("wim-swipe-action", n.container, b),
85
+ onMouseLeave: () => U(!1),
86
+ onBlur: J,
87
+ ...x,
47
88
  children: [
48
- N > 0 && /* @__PURE__ */ d("div", {
49
- className: u(n.actions, n.left),
50
- style: { width: N },
51
- children: p.map((e, r) => /* @__PURE__ */ f("button", {
52
- className: u(n.action, e.intent && n[e.intent]),
53
- style: { backgroundColor: e.color },
54
- onClick: () => {
55
- e.onClick(), v && (E(0), w?.reportClose(C));
56
- },
57
- type: "button",
58
- children: [/* @__PURE__ */ d(t, {
59
- name: e.icon,
60
- size: "md"
61
- }), /* @__PURE__ */ d("span", {
62
- className: n.label,
63
- children: e.label
64
- })]
65
- }, r))
66
- }),
67
- P > 0 && /* @__PURE__ */ d("div", {
68
- className: u(n.actions, n.right),
69
- style: { width: P },
70
- children: m.map((e, r) => /* @__PURE__ */ f("button", {
71
- className: u(n.action, e.intent && n[e.intent]),
72
- style: { backgroundColor: e.color },
73
- onClick: () => {
74
- e.onClick(), v && (E(0), w?.reportClose(C));
75
- },
76
- type: "button",
77
- children: [/* @__PURE__ */ d(t, {
78
- name: e.icon,
79
- size: "md"
80
- }), /* @__PURE__ */ d("span", {
81
- className: n.label,
82
- children: e.label
83
- })]
84
- }, r))
85
- }),
86
- /* @__PURE__ */ d(R, {
89
+ /* @__PURE__ */ d(W, {
90
+ ref: G,
87
91
  className: n.content,
92
+ tabIndex: K ? -1 : void 0,
88
93
  style: {
89
- transform: `translateX(${T}px)`,
90
- transition: D ? "none" : "transform 0.4s cubic-bezier(0.16, 1, 0.3, 1)"
94
+ transform: `translateX(${E}px)`,
95
+ transition: O ? "none" : "transform 0.4s cubic-bezier(0.16, 1, 0.3, 1)"
91
96
  },
92
- onTouchStart: F,
93
- onTouchMove: I,
94
- onTouchEnd: L,
95
- onMouseDown: F,
96
- onMouseMove: I,
97
- onMouseUp: L,
97
+ onTouchStart: V,
98
+ onTouchMove: H,
99
+ onTouchEnd: () => U(),
100
+ onMouseDown: V,
101
+ onMouseMove: H,
102
+ onMouseUp: () => U(),
98
103
  children: h
99
- })
104
+ }),
105
+ P > 0 && X("left", p, P),
106
+ F > 0 && X("right", m, F)
100
107
  ]
101
108
  });
102
109
  });
@@ -1,2 +1,2 @@
1
1
  "use client";
2
- const e=require("../../../_virtual/_rolldown/runtime.cjs");let t=require("react");t=e.__toESM(t,1);let n=require("classnames");n=e.__toESM(n,1),require("react/jsx-runtime");var r=(0,t.createContext)(null),i=()=>(0,t.useContext)(r);exports.useSwipeableList=i;
2
+ const e=require("../../../_virtual/_rolldown/runtime.cjs");let t=require("react");t=e.__toESM(t,1);let n=require("classnames");n=e.__toESM(n,1);let r=require("react/jsx-runtime");var i=(0,t.createContext)(null),a=()=>(0,t.useContext)(i),o=({children:e,exclusive:a=!0,className:o})=>{let[s,c]=(0,t.useState)(null),l=(0,t.useCallback)(e=>{a&&c(e)},[a]),u=(0,t.useCallback)(e=>{a&&c(t=>t===e?null:t)},[a]);return(0,r.jsx)(i.Provider,{value:{openedId:s,reportOpen:l,reportClose:u},children:(0,r.jsx)(`div`,{className:(0,n.default)(`wim-swipeable-list`,o),children:e})})};exports.SwipeableList=o,exports.useSwipeableList=a;
@@ -6,9 +6,14 @@ interface SwipeableListContextValue {
6
6
  }
7
7
  export declare const useSwipeableList: () => SwipeableListContextValue | null;
8
8
  export interface SwipeableListProps {
9
+ /** The `SwipeAction` rows to coordinate */
9
10
  children: React.ReactNode;
10
- /** If true, only one item can be swiped open at a time. */
11
+ /**
12
+ * If true (default), only one row can be open at a time — opening a row, by swipe
13
+ * or by keyboard focus on its actions, closes the others.
14
+ */
11
15
  exclusive?: boolean;
16
+ /** Additional CSS class */
12
17
  className?: string;
13
18
  }
14
19
  /**
@@ -1,8 +1,25 @@
1
1
  "use client";
2
- import { createContext as e, useContext as t } from "react";
3
- import "classnames";
4
- import "react/jsx-runtime";
2
+ import { createContext as e, useCallback as t, useContext as n, useState as r } from "react";
3
+ import i from "classnames";
4
+ import { jsx as a } from "react/jsx-runtime";
5
5
  //#region src/components/data-display/SwipeAction/SwipeableList.tsx
6
- var n = e(null), r = () => t(n);
6
+ var o = e(null), s = () => n(o), c = ({ children: e, exclusive: n = !0, className: s }) => {
7
+ let [c, l] = r(null), u = t((e) => {
8
+ n && l(e);
9
+ }, [n]), d = t((e) => {
10
+ n && l((t) => t === e ? null : t);
11
+ }, [n]);
12
+ return /* @__PURE__ */ a(o.Provider, {
13
+ value: {
14
+ openedId: c,
15
+ reportOpen: u,
16
+ reportClose: d
17
+ },
18
+ children: /* @__PURE__ */ a("div", {
19
+ className: i("wim-swipeable-list", s),
20
+ children: e
21
+ })
22
+ });
23
+ };
7
24
  //#endregion
8
- export { r as useSwipeableList };
25
+ export { c as SwipeableList, s as useSwipeableList };
@@ -1,2 +1,2 @@
1
1
  "use client";
2
- var e=`_container_8pbgw_2`,t=`_actions_8pbgw_10`,n=`_left_8pbgw_17`,r=`_right_8pbgw_20`,i=`_action_8pbgw_10`,a=`_primary_8pbgw_45`,o=`_danger_8pbgw_48`,s=`_warning_8pbgw_51`,c=`_success_8pbgw_55`,l=`_neutral_8pbgw_58`,u=`_label_8pbgw_61`,d=`_content_8pbgw_64`,f={container:e,actions:t,left:n,right:r,action:i,primary:a,danger:o,warning:s,success:c,neutral:l,label:u,content:d};exports.action=i,exports.actions=t,exports.container=e,exports.content=d,exports.danger=o,exports.default=f,exports.label=u,exports.left=n,exports.neutral=l,exports.primary=a,exports.right=r,exports.success=c,exports.warning=s;
2
+ var e=`_container_13gak_3`,t=`_actions_13gak_11`,n=`_left_13gak_18`,r=`_right_13gak_21`,i=`_stretched_13gak_28`,a=`_action_13gak_11`,o=`_outer_13gak_28`,s=`_armed_13gak_35`,c=`_primary_13gak_63`,l=`_danger_13gak_66`,u=`_warning_13gak_69`,d=`_success_13gak_73`,f=`_neutral_13gak_76`,p=`_label_13gak_79`,m=`_content_13gak_82`,h={container:e,actions:t,left:n,right:r,stretched:i,action:a,outer:o,armed:s,primary:c,danger:l,warning:u,success:d,neutral:f,label:p,content:m};exports.action=a,exports.actions=t,exports.armed=s,exports.container=e,exports.content=m,exports.danger=l,exports.default=h,exports.label=p,exports.left=n,exports.neutral=f,exports.outer=o,exports.primary=c,exports.right=r,exports.stretched=i,exports.success=d,exports.warning=u;
@@ -1,18 +1,21 @@
1
1
  "use client";
2
2
  //#region src/components/data-display/SwipeAction/swipe-action.module.scss
3
- var e = "_container_8pbgw_2", t = "_actions_8pbgw_10", n = "_left_8pbgw_17", r = "_right_8pbgw_20", i = "_action_8pbgw_10", a = "_primary_8pbgw_45", o = "_danger_8pbgw_48", s = "_warning_8pbgw_51", c = "_success_8pbgw_55", l = "_neutral_8pbgw_58", u = "_label_8pbgw_61", d = "_content_8pbgw_64", f = {
3
+ var e = "_container_13gak_3", t = "_actions_13gak_11", n = "_left_13gak_18", r = "_right_13gak_21", i = "_stretched_13gak_28", a = "_action_13gak_11", o = "_outer_13gak_28", s = "_armed_13gak_35", c = "_primary_13gak_63", l = "_danger_13gak_66", u = "_warning_13gak_69", d = "_success_13gak_73", f = "_neutral_13gak_76", p = "_label_13gak_79", m = "_content_13gak_82", h = {
4
4
  container: e,
5
5
  actions: t,
6
6
  left: n,
7
7
  right: r,
8
- action: i,
9
- primary: a,
10
- danger: o,
11
- warning: s,
12
- success: c,
13
- neutral: l,
14
- label: u,
15
- content: d
8
+ stretched: i,
9
+ action: a,
10
+ outer: o,
11
+ armed: s,
12
+ primary: c,
13
+ danger: l,
14
+ warning: u,
15
+ success: d,
16
+ neutral: f,
17
+ label: p,
18
+ content: m
16
19
  };
17
20
  //#endregion
18
- export { i as action, t as actions, e as container, d as content, o as danger, f as default, u as label, n as left, l as neutral, a as primary, r as right, c as success, s as warning };
21
+ export { a as action, t as actions, s as armed, e as container, m as content, l as danger, h as default, p as label, n as left, f as neutral, o as outer, c as primary, r as right, i as stretched, d as success, u as warning };
@@ -23,6 +23,8 @@ export * from './components/data-display/FAQSection/FAQSection';
23
23
  export * from './components/data-display/InfiniteScroll/InfiniteScroll';
24
24
  export * from './components/data-display/SortableList/SortableList';
25
25
  export * from './components/data-display/SwipeAction/SwipeAction';
26
+ export { SwipeableList } from './components/data-display/SwipeAction/SwipeableList';
27
+ export type { SwipeableListProps } from './components/data-display/SwipeAction/SwipeableList';
26
28
  export * from './components/data-display/PullToRefresh/PullToRefresh';
27
29
  export * from './components/data-display/JsonViewer/JsonViewer';
28
30
  export * from './components/data-display/CalendarHeatmap/CalendarHeatmap';
@@ -1,2 +1,2 @@
1
1
  "use client";
2
- Object.defineProperty(exports,Symbol.toStringTag,{value:`Module`});const e=require("./components/data-display/Card/Card.cjs"),t=require("./components/data-display/Badge/Badge.cjs"),n=require("./components/data-display/Calendar/Calendar.cjs"),r=require("./components/data-display/Chip/Chip.cjs"),i=require("./components/data-display/VirtualList/VirtualList.cjs"),a=require("./components/data-display/TreeView/TreeView.cjs"),o=require("./components/data-display/Tag/Tag.cjs"),s=require("./components/data-display/Accordion/Accordion.cjs"),c=require("./components/data-display/Avatar/Avatar.cjs"),l=require("./components/data-display/AvatarGroup/AvatarGroup.cjs"),u=require("./components/data-display/Calendar/RangeCalendar.cjs"),d=require("./components/data-display/Carousel/Carousel.cjs"),f=require("./components/data-display/Table/useTableSort.cjs"),p=require("./components/data-display/Table/Table.cjs"),m=require("./components/data-display/DataGrid/DataGrid.cjs"),h=require("./components/data-display/DescriptionList/DescriptionList.cjs"),g=require("./components/data-display/EmptyState/EmptyState.cjs"),_=require("./components/data-display/Kanban/Kanban.cjs"),v=require("./components/data-display/List/List.cjs"),y=require("./components/data-display/Marquee/Marquee.cjs"),b=require("./components/data-display/Stats/Stats.cjs"),x=require("./components/data-display/Timeline/Timeline.cjs"),S=require("./components/data-display/FAQSection/FAQSection.cjs"),C=require("./components/data-display/InfiniteScroll/InfiniteScroll.cjs"),w=require("./components/data-display/SortableList/SortableList.cjs"),T=require("./components/data-display/SwipeAction/SwipeAction.cjs"),E=require("./components/data-display/PullToRefresh/PullToRefresh.cjs"),D=require("./components/data-display/JsonViewer/JsonViewer.cjs"),O=require("./components/data-display/CalendarHeatmap/CalendarHeatmap.cjs"),k=require("./components/data-display/Reaction/Reaction.cjs"),A=require("./components/data-display/Leaderboard/Leaderboard.cjs"),j=require("./components/data-display/RelativeTime/RelativeTime.cjs"),M=require("./components/data-display/Comment/Comment.cjs"),N=require("./components/data-display/Countdown/Countdown.cjs"),P=require("./components/data-display/Presence/Presence.cjs"),F=require("./components/data-display/Barcode/Barcode.cjs");exports.Accordion=s.Accordion,exports.AccordionContent=s.AccordionContent,exports.AccordionItem=s.AccordionItem,exports.AccordionTrigger=s.AccordionTrigger,exports.Avatar=c.Avatar,exports.AvatarGroup=l.AvatarGroup,exports.Badge=t.Badge,exports.Barcode=F.Barcode,exports.Calendar=n.Calendar,exports.CalendarHeatmap=O.CalendarHeatmap,exports.Card=e.Card,exports.CardBody=e.CardBody,exports.CardFooter=e.CardFooter,exports.CardHeader=e.CardHeader,exports.Carousel=d.Carousel,exports.Chip=r.Chip,exports.Comment=M.Comment,exports.Countdown=N.Countdown,exports.DataGrid=m.DataGrid,exports.DescriptionList=h.DescriptionList,exports.DescriptionListDetails=h.DescriptionListDetails,exports.DescriptionListItem=h.DescriptionListItem,exports.DescriptionListTerm=h.DescriptionListTerm,exports.EmptyState=g.EmptyState,exports.FAQSection=S.FAQSection,exports.InfiniteScroll=C.InfiniteScroll,exports.JsonViewer=D.JsonViewer,exports.Kanban=_.Kanban,exports.KanbanBoard=_.KanbanBoard,exports.KanbanCard=_.KanbanCard,exports.KanbanColumn=_.KanbanColumn,exports.Leaderboard=A.Leaderboard,exports.List=v.List,exports.ListItem=v.ListItem,exports.Marquee=y.Marquee,exports.Presence=P.Presence,exports.PullToRefresh=E.PullToRefresh,exports.RangeCalendar=u.RangeCalendar,exports.Reaction=k.Reaction,exports.RelativeTime=j.RelativeTime,exports.SortableList=w.SortableList,exports.SortableListDragHandle=w.SortableListDragHandle,exports.SortableListItem=w.SortableListItem,exports.Stats=b.Stats,exports.StatsDescription=b.StatsDescription,exports.StatsLabel=b.StatsLabel,exports.StatsTrend=b.StatsTrend,exports.StatsValue=b.StatsValue,exports.SwipeAction=T.SwipeAction,exports.Table=p.Table,exports.TableBody=p.TableBody,exports.TableCell=p.TableCell,exports.TableFooter=p.TableFooter,exports.TableHead=p.TableHead,exports.TableHeader=p.TableHeader,exports.TableRow=p.TableRow,exports.Tag=o.Tag,exports.Timeline=x.Timeline,exports.TimelineConnector=x.TimelineConnector,exports.TimelineContent=x.TimelineContent,exports.TimelineItem=x.TimelineItem,exports.TimelineOppositeContent=x.TimelineOppositeContent,exports.TimelinePoint=x.TimelinePoint,exports.TimelineSeparator=x.TimelineSeparator,exports.TreeView=a.TreeView,exports.TreeViewItem=a.TreeViewItem,exports.VirtualList=i.VirtualList,exports.getNextSortDirection=f.getNextSortDirection,exports.useTableSort=f.useTableSort;
2
+ Object.defineProperty(exports,Symbol.toStringTag,{value:`Module`});const e=require("./components/data-display/Card/Card.cjs"),t=require("./components/data-display/Badge/Badge.cjs"),n=require("./components/data-display/Calendar/Calendar.cjs"),r=require("./components/data-display/Chip/Chip.cjs"),i=require("./components/data-display/VirtualList/VirtualList.cjs"),a=require("./components/data-display/TreeView/TreeView.cjs"),o=require("./components/data-display/Tag/Tag.cjs"),s=require("./components/data-display/Accordion/Accordion.cjs"),c=require("./components/data-display/Avatar/Avatar.cjs"),l=require("./components/data-display/AvatarGroup/AvatarGroup.cjs"),u=require("./components/data-display/Calendar/RangeCalendar.cjs"),d=require("./components/data-display/Carousel/Carousel.cjs"),f=require("./components/data-display/Table/useTableSort.cjs"),p=require("./components/data-display/Table/Table.cjs"),m=require("./components/data-display/DataGrid/DataGrid.cjs"),h=require("./components/data-display/DescriptionList/DescriptionList.cjs"),g=require("./components/data-display/EmptyState/EmptyState.cjs"),_=require("./components/data-display/Kanban/Kanban.cjs"),v=require("./components/data-display/List/List.cjs"),y=require("./components/data-display/Marquee/Marquee.cjs"),b=require("./components/data-display/Stats/Stats.cjs"),x=require("./components/data-display/Timeline/Timeline.cjs"),S=require("./components/data-display/FAQSection/FAQSection.cjs"),C=require("./components/data-display/InfiniteScroll/InfiniteScroll.cjs"),w=require("./components/data-display/SortableList/SortableList.cjs"),T=require("./components/data-display/SwipeAction/SwipeableList.cjs"),E=require("./components/data-display/SwipeAction/SwipeAction.cjs"),D=require("./components/data-display/PullToRefresh/PullToRefresh.cjs"),O=require("./components/data-display/JsonViewer/JsonViewer.cjs"),k=require("./components/data-display/CalendarHeatmap/CalendarHeatmap.cjs"),A=require("./components/data-display/Reaction/Reaction.cjs"),j=require("./components/data-display/Leaderboard/Leaderboard.cjs"),M=require("./components/data-display/RelativeTime/RelativeTime.cjs"),N=require("./components/data-display/Comment/Comment.cjs"),P=require("./components/data-display/Countdown/Countdown.cjs"),F=require("./components/data-display/Presence/Presence.cjs"),I=require("./components/data-display/Barcode/Barcode.cjs");exports.Accordion=s.Accordion,exports.AccordionContent=s.AccordionContent,exports.AccordionItem=s.AccordionItem,exports.AccordionTrigger=s.AccordionTrigger,exports.Avatar=c.Avatar,exports.AvatarGroup=l.AvatarGroup,exports.Badge=t.Badge,exports.Barcode=I.Barcode,exports.Calendar=n.Calendar,exports.CalendarHeatmap=k.CalendarHeatmap,exports.Card=e.Card,exports.CardBody=e.CardBody,exports.CardFooter=e.CardFooter,exports.CardHeader=e.CardHeader,exports.Carousel=d.Carousel,exports.Chip=r.Chip,exports.Comment=N.Comment,exports.Countdown=P.Countdown,exports.DataGrid=m.DataGrid,exports.DescriptionList=h.DescriptionList,exports.DescriptionListDetails=h.DescriptionListDetails,exports.DescriptionListItem=h.DescriptionListItem,exports.DescriptionListTerm=h.DescriptionListTerm,exports.EmptyState=g.EmptyState,exports.FAQSection=S.FAQSection,exports.InfiniteScroll=C.InfiniteScroll,exports.JsonViewer=O.JsonViewer,exports.Kanban=_.Kanban,exports.KanbanBoard=_.KanbanBoard,exports.KanbanCard=_.KanbanCard,exports.KanbanColumn=_.KanbanColumn,exports.Leaderboard=j.Leaderboard,exports.List=v.List,exports.ListItem=v.ListItem,exports.Marquee=y.Marquee,exports.Presence=F.Presence,exports.PullToRefresh=D.PullToRefresh,exports.RangeCalendar=u.RangeCalendar,exports.Reaction=A.Reaction,exports.RelativeTime=M.RelativeTime,exports.SortableList=w.SortableList,exports.SortableListDragHandle=w.SortableListDragHandle,exports.SortableListItem=w.SortableListItem,exports.Stats=b.Stats,exports.StatsDescription=b.StatsDescription,exports.StatsLabel=b.StatsLabel,exports.StatsTrend=b.StatsTrend,exports.StatsValue=b.StatsValue,exports.SwipeAction=E.SwipeAction,exports.SwipeableList=T.SwipeableList,exports.Table=p.Table,exports.TableBody=p.TableBody,exports.TableCell=p.TableCell,exports.TableFooter=p.TableFooter,exports.TableHead=p.TableHead,exports.TableHeader=p.TableHeader,exports.TableRow=p.TableRow,exports.Tag=o.Tag,exports.Timeline=x.Timeline,exports.TimelineConnector=x.TimelineConnector,exports.TimelineContent=x.TimelineContent,exports.TimelineItem=x.TimelineItem,exports.TimelineOppositeContent=x.TimelineOppositeContent,exports.TimelinePoint=x.TimelinePoint,exports.TimelineSeparator=x.TimelineSeparator,exports.TreeView=a.TreeView,exports.TreeViewItem=a.TreeViewItem,exports.VirtualList=i.VirtualList,exports.getNextSortDirection=f.getNextSortDirection,exports.useTableSort=f.useTableSort;
@@ -24,15 +24,16 @@ import { Timeline as K, TimelineConnector as q, TimelineContent as J, TimelineIt
24
24
  import { FAQSection as $ } from "./components/data-display/FAQSection/FAQSection.js";
25
25
  import { InfiniteScroll as ee } from "./components/data-display/InfiniteScroll/InfiniteScroll.js";
26
26
  import { SortableList as te, SortableListDragHandle as ne, SortableListItem as re } from "./components/data-display/SortableList/SortableList.js";
27
- import { SwipeAction as ie } from "./components/data-display/SwipeAction/SwipeAction.js";
28
- import { PullToRefresh as ae } from "./components/data-display/PullToRefresh/PullToRefresh.js";
29
- import { JsonViewer as oe } from "./components/data-display/JsonViewer/JsonViewer.js";
30
- import { CalendarHeatmap as se } from "./components/data-display/CalendarHeatmap/CalendarHeatmap.js";
31
- import { Reaction as ce } from "./components/data-display/Reaction/Reaction.js";
32
- import { Leaderboard as le } from "./components/data-display/Leaderboard/Leaderboard.js";
33
- import { RelativeTime as ue } from "./components/data-display/RelativeTime/RelativeTime.js";
34
- import { Comment as de } from "./components/data-display/Comment/Comment.js";
35
- import { Countdown as fe } from "./components/data-display/Countdown/Countdown.js";
36
- import { Presence as pe } from "./components/data-display/Presence/Presence.js";
37
- import { Barcode as me } from "./components/data-display/Barcode/Barcode.js";
38
- export { d as Accordion, f as AccordionContent, p as AccordionItem, m as AccordionTrigger, h as Avatar, g as AvatarGroup, i as Badge, me as Barcode, a as Calendar, se as CalendarHeatmap, e as Card, t as CardBody, n as CardFooter, r as CardHeader, v as Carousel, o as Chip, de as Comment, fe as Countdown, O as DataGrid, k as DescriptionList, A as DescriptionListDetails, j as DescriptionListItem, M as DescriptionListTerm, N as EmptyState, $ as FAQSection, ee as InfiniteScroll, oe as JsonViewer, P as Kanban, F as KanbanBoard, I as KanbanCard, L as KanbanColumn, le as Leaderboard, R as List, z as ListItem, B as Marquee, pe as Presence, ae as PullToRefresh, _ as RangeCalendar, ce as Reaction, ue as RelativeTime, te as SortableList, ne as SortableListDragHandle, re as SortableListItem, V as Stats, H as StatsDescription, U as StatsLabel, W as StatsTrend, G as StatsValue, ie as SwipeAction, x as Table, S as TableBody, C as TableCell, w as TableFooter, T as TableHead, E as TableHeader, D as TableRow, u as Tag, K as Timeline, q as TimelineConnector, J as TimelineContent, Y as TimelineItem, X as TimelineOppositeContent, Z as TimelinePoint, Q as TimelineSeparator, c as TreeView, l as TreeViewItem, s as VirtualList, y as getNextSortDirection, b as useTableSort };
27
+ import { SwipeableList as ie } from "./components/data-display/SwipeAction/SwipeableList.js";
28
+ import { SwipeAction as ae } from "./components/data-display/SwipeAction/SwipeAction.js";
29
+ import { PullToRefresh as oe } from "./components/data-display/PullToRefresh/PullToRefresh.js";
30
+ import { JsonViewer as se } from "./components/data-display/JsonViewer/JsonViewer.js";
31
+ import { CalendarHeatmap as ce } from "./components/data-display/CalendarHeatmap/CalendarHeatmap.js";
32
+ import { Reaction as le } from "./components/data-display/Reaction/Reaction.js";
33
+ import { Leaderboard as ue } from "./components/data-display/Leaderboard/Leaderboard.js";
34
+ import { RelativeTime as de } from "./components/data-display/RelativeTime/RelativeTime.js";
35
+ import { Comment as fe } from "./components/data-display/Comment/Comment.js";
36
+ import { Countdown as pe } from "./components/data-display/Countdown/Countdown.js";
37
+ import { Presence as me } from "./components/data-display/Presence/Presence.js";
38
+ import { Barcode as he } from "./components/data-display/Barcode/Barcode.js";
39
+ export { d as Accordion, f as AccordionContent, p as AccordionItem, m as AccordionTrigger, h as Avatar, g as AvatarGroup, i as Badge, he as Barcode, a as Calendar, ce as CalendarHeatmap, e as Card, t as CardBody, n as CardFooter, r as CardHeader, v as Carousel, o as Chip, fe as Comment, pe as Countdown, O as DataGrid, k as DescriptionList, A as DescriptionListDetails, j as DescriptionListItem, M as DescriptionListTerm, N as EmptyState, $ as FAQSection, ee as InfiniteScroll, se as JsonViewer, P as Kanban, F as KanbanBoard, I as KanbanCard, L as KanbanColumn, ue as Leaderboard, R as List, z as ListItem, B as Marquee, me as Presence, oe as PullToRefresh, _ as RangeCalendar, le as Reaction, de as RelativeTime, te as SortableList, ne as SortableListDragHandle, re as SortableListItem, V as Stats, H as StatsDescription, U as StatsLabel, W as StatsTrend, G as StatsValue, ae as SwipeAction, ie as SwipeableList, x as Table, S as TableBody, C as TableCell, w as TableFooter, T as TableHead, E as TableHeader, D as TableRow, u as Tag, K as Timeline, q as TimelineConnector, J as TimelineContent, Y as TimelineItem, X as TimelineOppositeContent, Z as TimelinePoint, Q as TimelineSeparator, c as TreeView, l as TreeViewItem, s as VirtualList, y as getNextSortDirection, b as useTableSort };