@synnaxlabs/pluto 0.44.1 → 0.44.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{Animated-KCUNFDvN.js → Animated-BHxq6Pmm.js} +2 -2
- package/dist/{Animated-3QNTHym1.cjs → Animated-DEXELMDa.cjs} +1 -1
- package/dist/LinePlot-BJ10hKs7.cjs +53 -0
- package/dist/LinePlot-VIcFjuPQ.js +6236 -0
- package/dist/{Toggle-1E6vrl6G.js → Toggle-C--I90ch.js} +1 -1
- package/dist/{Toggle-BHiPL61M.cjs → Toggle-CCsw0kkq.cjs} +1 -1
- package/dist/{Video-BidrtYj_.cjs → Video-BbRLzkdH.cjs} +1 -1
- package/dist/{Video-Cm8ZBqid.js → Video-DdsVXhnt.js} +1 -1
- package/dist/button.cjs +1 -1
- package/dist/button.js +1 -1
- package/dist/color.cjs +1 -1
- package/dist/color.js +1 -1
- package/dist/{css-Dl9aM7Jz.js → css-BKrX40Df.js} +713 -685
- package/dist/css-TyQvZIXQ.cjs +8 -0
- package/dist/css.cjs +1 -1
- package/dist/css.js +2 -2
- package/dist/dialog.cjs +1 -1
- package/dist/dialog.js +1 -1
- package/dist/eraser-Bxknv-HS.cjs +63 -0
- package/dist/{eraser-CZknVTjw.js → eraser-DtXU7kOS.js} +4811 -4746
- package/dist/ether.cjs +1 -1
- package/dist/ether.js +66 -63
- package/dist/{external-k23HUvy8.js → external-BApQK7XP.js} +143 -143
- package/dist/{external-lMAel8Te.cjs → external-BBXhtVjD.cjs} +1 -1
- package/dist/{external-5PfK-PF3.js → external-BOmNpcyI.js} +20 -20
- package/dist/{external-CtwEvFYE.cjs → external-BPF50O_x.cjs} +1 -1
- package/dist/{external-DPN-ziJs.js → external-BT0nByPv.js} +2 -2
- package/dist/{external-CKvxjJs5.cjs → external-BUAnicLg.cjs} +1 -1
- package/dist/{external-DJ4pzZBh.cjs → external-BaRBYE0N.cjs} +1 -1
- package/dist/{external-B1mnn7_J.js → external-BmfZaFKB.js} +3 -3
- package/dist/external-BsyCwXWB.cjs +1 -0
- package/dist/{external-BmaCxlPM.js → external-Bt-WjDvD.js} +8 -8
- package/dist/{external-DTzGaj9d.js → external-CEMgElRx.js} +10 -10
- package/dist/{external-DIRuVzOZ.cjs → external-COBt6FnN.cjs} +1 -1
- package/dist/{external-T7fQRFNS.cjs → external-CZSk2V5E.cjs} +1 -1
- package/dist/{external-Bmv3JTk3.cjs → external-Cw5iYImi.cjs} +1 -1
- package/dist/{external-DIE22vag.js → external-Dgui980d.js} +74 -75
- package/dist/external-Dwfn2jsF.js +42 -0
- package/dist/external-EMhi5ISu.cjs +1 -0
- package/dist/{external-BDFD5v83.cjs → external-Jee63xkv.cjs} +1 -1
- package/dist/{external-BzGhOwHW.js → external-NUi5IwGn.js} +20 -20
- package/dist/{external-R1cRWCTB.js → external-ONwuyKzG.js} +27 -27
- package/dist/{external-Dr5azzr8.cjs → external-TAYJZFme.cjs} +1 -1
- package/dist/external-bvOijYCw.cjs +1 -0
- package/dist/{external-Bx2Al5fy.js → external-dkXc0y5z.js} +20 -20
- package/dist/{external-B16icDUE.js → external-n4gJTJfw.js} +23 -23
- package/dist/{external-BgZRkFq4.js → external-tHxdTvxn.js} +2 -2
- package/dist/{external-DRcsXa_0.cjs → external-yddEc8os.cjs} +1 -1
- package/dist/flex.cjs +1 -1
- package/dist/flex.js +1 -1
- package/dist/{fontString-BptzSQcY.cjs → fontString-BWGnZU-8.cjs} +1 -1
- package/dist/{fontString-Bm52S4Lo.js → fontString-D2-HUuI_.js} +2 -2
- package/dist/header.cjs +1 -1
- package/dist/header.js +1 -1
- package/dist/index.cjs +7 -7
- package/dist/index.js +10341 -10380
- package/dist/input.cjs +1 -1
- package/dist/input.js +1 -1
- package/dist/list.cjs +1 -1
- package/dist/list.js +1 -1
- package/dist/menu.cjs +1 -1
- package/dist/menu.js +1 -1
- package/dist/pluto.css +1 -1
- package/dist/src/channel/AliasInput.d.ts +3 -1
- package/dist/src/channel/AliasInput.d.ts.map +1 -1
- package/dist/src/channel/LinePlot.d.ts +2 -0
- package/dist/src/channel/LinePlot.d.ts.map +1 -1
- package/dist/src/channel/Select.d.ts.map +1 -1
- package/dist/src/channel/external.d.ts +0 -2
- package/dist/src/channel/external.d.ts.map +1 -1
- package/dist/src/channel/queries.d.ts +84 -6
- package/dist/src/channel/queries.d.ts.map +1 -1
- package/dist/src/dialog/Frame.d.ts.map +1 -1
- package/dist/src/flux/Provider.d.ts +9 -7
- package/dist/src/flux/Provider.d.ts.map +1 -1
- package/dist/src/flux/aether/external.d.ts +4 -3
- package/dist/src/flux/aether/external.d.ts.map +1 -1
- package/dist/src/flux/aether/provider.d.ts +31 -25
- package/dist/src/flux/aether/provider.d.ts.map +1 -1
- package/dist/src/flux/core/client.d.ts +21 -0
- package/dist/src/flux/core/client.d.ts.map +1 -0
- package/dist/src/flux/core/external.d.ts +4 -0
- package/dist/src/flux/core/external.d.ts.map +1 -0
- package/dist/src/flux/core/index.d.ts +2 -0
- package/dist/src/flux/core/index.d.ts.map +1 -0
- package/dist/src/flux/core/params.d.ts.map +1 -0
- package/dist/src/flux/core/store.d.ts +128 -0
- package/dist/src/flux/core/store.d.ts.map +1 -0
- package/dist/src/flux/core/store.spec.d.ts +2 -0
- package/dist/src/flux/core/store.spec.d.ts.map +1 -0
- package/dist/src/flux/core/streamer.d.ts +31 -0
- package/dist/src/flux/core/streamer.d.ts.map +1 -0
- package/dist/src/flux/core/streamer.spec.d.ts.map +1 -0
- package/dist/src/flux/external.d.ts +3 -5
- package/dist/src/flux/external.d.ts.map +1 -1
- package/dist/src/flux/form.d.ts +6 -3
- package/dist/src/flux/form.d.ts.map +1 -1
- package/dist/src/flux/list.d.ts +13 -13
- package/dist/src/flux/list.d.ts.map +1 -1
- package/dist/src/flux/result.d.ts +10 -9
- package/dist/src/flux/result.d.ts.map +1 -1
- package/dist/src/flux/retrieve.d.ts +18 -39
- package/dist/src/flux/retrieve.d.ts.map +1 -1
- package/dist/src/flux/update.d.ts +12 -7
- package/dist/src/flux/update.d.ts.map +1 -1
- package/dist/src/form/state.d.ts +3 -1
- package/dist/src/form/state.d.ts.map +1 -1
- package/dist/src/form/use.d.ts +1 -0
- package/dist/src/form/use.d.ts.map +1 -1
- package/dist/src/hardware/device/queries.d.ts +12 -4
- package/dist/src/hardware/device/queries.d.ts.map +1 -1
- package/dist/src/hardware/rack/external.d.ts +0 -3
- package/dist/src/hardware/rack/external.d.ts.map +1 -1
- package/dist/src/hardware/rack/queries.d.ts +13 -0
- package/dist/src/hardware/rack/queries.d.ts.map +1 -1
- package/dist/src/hardware/task/queries.d.ts +12 -5
- package/dist/src/hardware/task/queries.d.ts.map +1 -1
- package/dist/src/hooks/index.d.ts +1 -0
- package/dist/src/hooks/index.d.ts.map +1 -1
- package/dist/src/hooks/useDestructors.d.ts +7 -0
- package/dist/src/hooks/useDestructors.d.ts.map +1 -0
- package/dist/src/icon/registry.d.ts +1 -0
- package/dist/src/icon/registry.d.ts.map +1 -1
- package/dist/src/input/Text.d.ts +3 -2
- package/dist/src/input/Text.d.ts.map +1 -1
- package/dist/src/label/queries.d.ts +21 -19
- package/dist/src/label/queries.d.ts.map +1 -1
- package/dist/src/menu/ContextMenu.d.ts +1 -0
- package/dist/src/menu/ContextMenu.d.ts.map +1 -1
- package/dist/src/mosaic/tree.d.ts.map +1 -1
- package/dist/src/ontology/queries.d.ts +19 -4
- package/dist/src/ontology/queries.d.ts.map +1 -1
- package/dist/src/pluto/Pluto.d.ts +23 -2
- package/dist/src/pluto/Pluto.d.ts.map +1 -1
- package/dist/src/pluto/aether/pluto.d.ts.map +1 -1
- package/dist/src/ranger/aether/index.d.ts +2 -0
- package/dist/src/ranger/aether/index.d.ts.map +1 -0
- package/dist/src/ranger/aether/queries.d.ts +11 -0
- package/dist/src/ranger/aether/queries.d.ts.map +1 -0
- package/dist/src/ranger/queries.d.ts +28 -22
- package/dist/src/ranger/queries.d.ts.map +1 -1
- package/dist/src/state/state.d.ts +1 -1
- package/dist/src/state/state.d.ts.map +1 -1
- package/dist/src/status/Aggregator.d.ts +3 -0
- package/dist/src/status/Aggregator.d.ts.map +1 -1
- package/dist/src/status/Summary.d.ts.map +1 -1
- package/dist/src/status/aether/aggregator.d.ts +2 -12
- package/dist/src/status/aether/aggregator.d.ts.map +1 -1
- package/dist/src/status/aether/errorHandler.d.ts +15 -0
- package/dist/src/status/aether/errorHandler.d.ts.map +1 -0
- package/dist/src/status/aether/errorHandler.spec.d.ts +2 -0
- package/dist/src/status/aether/errorHandler.spec.d.ts.map +1 -0
- package/dist/src/status/aether/external.d.ts +3 -0
- package/dist/src/status/aether/external.d.ts.map +1 -0
- package/dist/src/status/aether/index.d.ts +1 -1
- package/dist/src/status/aether/index.d.ts.map +1 -1
- package/dist/src/telem/aether/transformers.d.ts +28 -2
- package/dist/src/telem/aether/transformers.d.ts.map +1 -1
- package/dist/src/testutil/Synnax.d.ts +6 -1
- package/dist/src/testutil/Synnax.d.ts.map +1 -1
- package/dist/src/text/Editable.d.ts.map +1 -1
- package/dist/src/vis/diagram/Diagram.d.ts +6 -0
- package/dist/src/vis/diagram/Diagram.d.ts.map +1 -1
- package/dist/src/vis/line/aether/line.d.ts +9 -2
- package/dist/src/vis/line/aether/line.d.ts.map +1 -1
- package/dist/src/vis/lineplot/range/aether/provider.d.ts +6 -18
- package/dist/src/vis/lineplot/range/aether/provider.d.ts.map +1 -1
- package/dist/src/vis/schematic/Forms.d.ts.map +1 -1
- package/dist/src/vis/value/TelemForm.d.ts.map +1 -1
- package/dist/src/workspace/queries.d.ts +8 -0
- package/dist/src/workspace/queries.d.ts.map +1 -1
- package/dist/{symbols-DzAWrATO.cjs → symbols-DWZqHjhU.cjs} +45 -45
- package/dist/{symbols-5jPiWw_d.js → symbols-aLnytgtc.js} +7283 -7223
- package/dist/tabs.cjs +1 -1
- package/dist/tabs.js +1 -1
- package/dist/text.cjs +1 -1
- package/dist/text.js +2 -2
- package/dist/theming.cjs +1 -1
- package/dist/theming.js +2 -2
- package/dist/tree.cjs +1 -1
- package/dist/tree.js +1 -1
- package/dist/triggers.cjs +1 -1
- package/dist/triggers.js +1 -1
- package/dist/{units-BGkvnLO-.cjs → units-XE06scfL.cjs} +1 -1
- package/dist/{units-HcS_zslH.js → units-ny6lkoIv.js} +1 -1
- package/dist/video.cjs +1 -1
- package/dist/video.js +1 -1
- package/package.json +7 -7
- package/dist/Menu-BFD8DPDp.js +0 -61
- package/dist/Menu-BPH8apK8.cjs +0 -1
- package/dist/css-9yccD6t_.cjs +0 -8
- package/dist/eraser-CLWNvWDn.cjs +0 -63
- package/dist/external-Bx2weRCW.cjs +0 -1
- package/dist/external-DF7sP0pe.cjs +0 -1
- package/dist/external-DMB49R_H.cjs +0 -1
- package/dist/external-DWSWz3Rk.js +0 -42
- package/dist/provider-BhLG7kqF.js +0 -6031
- package/dist/provider-DVZt686Q.cjs +0 -53
- package/dist/src/channel/AliasContext.d.ts +0 -19
- package/dist/src/channel/AliasContext.d.ts.map +0 -1
- package/dist/src/channel/AliasProvider.d.ts +0 -6
- package/dist/src/channel/AliasProvider.d.ts.map +0 -1
- package/dist/src/flux/Context.d.ts +0 -4
- package/dist/src/flux/Context.d.ts.map +0 -1
- package/dist/src/flux/aether/listeners.d.ts +0 -16
- package/dist/src/flux/aether/listeners.d.ts.map +0 -1
- package/dist/src/flux/aether/params.d.ts.map +0 -1
- package/dist/src/flux/aether/streamer.d.ts +0 -22
- package/dist/src/flux/aether/streamer.d.ts.map +0 -1
- package/dist/src/flux/aether/streamer.spec.d.ts.map +0 -1
- package/dist/src/flux/aether/types.d.ts +0 -13
- package/dist/src/flux/aether/types.d.ts.map +0 -1
- package/dist/src/flux/listeners.d.ts +0 -4
- package/dist/src/flux/listeners.d.ts.map +0 -1
- package/dist/src/flux/listeners.spec.d.ts +0 -2
- package/dist/src/flux/listeners.spec.d.ts.map +0 -1
- package/dist/src/flux/useMountListeners.d.ts +0 -7
- package/dist/src/flux/useMountListeners.d.ts.map +0 -1
- package/dist/src/hardware/rack/synchronizers.d.ts +0 -3
- package/dist/src/hardware/rack/synchronizers.d.ts.map +0 -1
- package/dist/src/hardware/rack/use.d.ts +0 -3
- package/dist/src/hardware/rack/use.d.ts.map +0 -1
- package/dist/src/hardware/rack/useStatus.d.ts +0 -3
- package/dist/src/hardware/rack/useStatus.d.ts.map +0 -1
- /package/dist/src/flux/{aether → core}/params.d.ts +0 -0
- /package/dist/src/flux/{aether → core}/streamer.spec.d.ts +0 -0
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";const i=require("./css-
|
|
1
|
+
"use strict";const i=require("./css-TyQvZIXQ.cjs"),_=require("./eraser-Bxknv-HS.cjs"),x=require("./jsx-runtime-CITbqOLs.cjs"),B=require("./Animated-DEXELMDa.cjs"),a=require("./symbols-DWZqHjhU.cjs"),m=require("react");require("react-dom");const L=(e,n)=>n.includes(e.key),v=({nodes:e,expanded:n,sort:t,depth:s=0})=>{const r={keys:[],nodes:[]};return t!=null&&e.sort(t),e.forEach(o=>{const l=L(o,n);if(r.keys.push(o.key),r.nodes.push({depth:s,expanded:l,hasChildren:o.children!=null}),l&&o.children!=null){const{keys:c,nodes:h}=v({nodes:o.children,expanded:n,sort:t,depth:s+1});r.keys.push(...c),r.nodes.push(...h)}}),r},F=({tree:e,destination:n,keys:t})=>(t=_.t.toArray(t),n==null?[...D({tree:e,keys:t}),...e.filter(r=>!t.includes(r.key))]:(t.forEach(s=>{const r=f({tree:e,key:s});r!=null&&(T({tree:e,keys:s}),$({tree:e,destination:n,additions:r}))}),e)),T=({tree:e,keys:n})=>(n=_.t.toArray(n),n.forEach(t=>{const s=e.findIndex(r=>r.key===t);if(s!==-1)e.splice(s,1);else{const r=g({tree:e,key:t});r!=null&&(r.children=r.children?.filter(o=>o.key!==t))}}),e),$=({tree:e,destination:n,additions:t,throwOnMissing:s=!0})=>{t=_.t.toArray(t);const r=i.c.by(t,c=>c.key,!1),o=r.map(c=>c.key);if(n==null)return[...r,...e.filter(c=>!o.includes(c.key))];const l=f({tree:e,key:n});if(l==null){if(s)throw new Error(`Could not find node with key ${n}`);return e}return l.children??=[],l.children=[...r,...l.children.filter(c=>!o.includes(c.key))],e},G=({tree:e,key:n,updater:t,throwOnMissing:s=!0})=>{const r=f({tree:e,key:n});if(r==null){if(s)throw new Error(`Could not find node with key ${n}`);return e}const o=g({tree:e,key:n});if(o!=null){const l=o.children?.findIndex(c=>c.key===n);l!=null&&l!==-1&&o.children?.splice(l,1,t(r))}else e.splice(e.findIndex(l=>l.key===n),1,t(r));return e},z=({tree:e,parent:n,updater:t,throwOnMissing:s=!0})=>{const r=f({tree:e,key:n});if(r==null){if(s)throw new Error(`Could not find node with key ${n}`);return e}return r.children=t(r.children??[]),e},f=({tree:e,key:n,depth:t=0})=>{for(let s=0;s<e.length;s++){const r=e[s];if(r.key===n)return r;if(r.children!=null){const o=f({tree:r.children,key:n,depth:t+1});if(o!=null)return o}}return null},D=({tree:e,keys:n})=>{const t=[];for(const s of n){const r=f({tree:e,key:s});r!=null&&t.push(r)}return t},g=({tree:e,key:n})=>{for(const t of e)if(t.children!=null){if(t.children.some(r=>r.key===n))return t;const s=g({tree:t.children,key:n});if(s!=null)return s}return null},H=e=>e.map(n=>({...n,children:n.children!=null?H(n.children):void 0})),O=(...e)=>{const n=[];return e.forEach(t=>{n.push(t),t.children!=null&&n.push(...O(...t.children))}),n},K=(e,n)=>{const t={keys:[],nodes:[]};return e.keys.forEach((s,r)=>{n(s,e.nodes[r].depth)&&(t.keys.push(s),t.nodes.push(e.nodes[r]))}),t},U=e=>{const n=Math.min(...e.nodes.map(t=>t.depth));return e.keys.filter((t,s)=>e.nodes[s].depth===n)},Y=(e,n)=>{const t=n.keys.findIndex(s=>s===e);return n.nodes[t].depth},P=(e,n)=>{const t=e.keys.findIndex(s=>s===n);return e.nodes[t]},J=({depth:e,hasChildren:n,expanded:t,children:s,style:r,className:o,loading:l,useMargin:c=!1,offsetMultiplier:h=2.5,...S})=>x.jsxRuntimeExports.jsxs(a.ListItem,{className:i.CSS(i.CSS.BE("tree","item"),e!==0&&i.CSS.M("show-rules"),c&&i.CSS.M("margin"),o),style:{[i.CSS.var("tree-item-offset")]:`${e*h+1.5}rem`,...r},gap:"small",align:"center",...S,children:[n&&x.jsxRuntimeExports.jsx(B.Animated,{className:i.CSS.BE("tree","expansion-indicator"),enabled:t,enabledLoc:"bottom",disabledLoc:"right"},"caret"),s,l&&x.jsxRuntimeExports.jsx(a.Loading,{})]}),Q="tree-item",V=[["Shift"]],W=({onExpand:e,nodes:n,initialExpanded:t=[],selected:s,onSelectedChange:r,sort:o})=>{const[l,c,h]=a.useCombinedStateAndRef(t),[S,R]=_.usePassthrough({initial:[],value:s,onChange:r}),N=m.useMemo(()=>v({nodes:n,expanded:l,sort:o}),[n,l,o]),b=a.useSyncedRef(n),j=a.useSyncedRef(N),k=a.useHeldRef({triggers:V}),I=m.useCallback((u,{clicked:d})=>{if(R(p=>u.length===0&&p.length>0?p.slice(0,1):u),d==null||k.current.held)return;const C=P(j.current,d);if(C==null||!C.hasChildren)return;const A=h.current,M=A.some(p=>p===d)?"contract":"expand";let E;M==="contract"?E=A.filter(p=>p!==d):E=[...A,d],c(E),e?.({current:E,action:M,clicked:d})},[e,b,c,R]),w=m.useCallback(u=>{c(d=>i.c.unique([...d,u])),e?.({current:l,action:"expand",clicked:u})},[c]),y=m.useCallback((...u)=>{c(d=>d.filter(C=>!u.includes(C))),u.forEach(d=>{e?.({current:l,action:"contract",clicked:d})})},[c]),q=m.useCallback(()=>c([]),[c]);return{selected:S,expanded:l,contract:y,expand:w,clearExpanded:q,shape:N,onSelect:I}},X=({shape:e,children:n,selected:t,onSelect:s,getItem:r,subscribe:o,className:l,contract:c,expand:h,expanded:S,className:R,clearExpanded:N,showRules:b=!1,virtual:j=!1,...k})=>{const{keys:I,nodes:w}=e;return x.jsxRuntimeExports.jsx(a.Frame$1,{multiple:!0,value:t,replaceOnSingle:!0,data:I,onChange:s,getItem:r,subscribe:o,itemHeight:27,virtual:j,children:x.jsxRuntimeExports.jsx(a.Items,{className:i.CSS(i.CSS.B("tree"),l,b&&i.CSS.M("show-rules")),...k,displayItems:1/0,children:({index:y,...q})=>n({index:y,...w[y],...q})})})},Z=Object.freeze(Object.defineProperty({__proto__:null,HAUL_TYPE:Q,Item:J,Tree:X,deepCopy:H,filterShape:K,findNode:f,findNodeParent:g,findNodes:D,flatten:v,getAllNodesOfMinDepth:U,getDepth:Y,getDescendants:O,getNodeShape:P,moveNode:F,removeNode:T,setNode:$,shouldExpand:L,updateNode:G,updateNodeChildren:z,use:W},Symbol.toStringTag,{value:"Module"}));exports.external=Z;
|
|
@@ -1,15 +1,15 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { K as d, T as x, L as E, N as b, O as K, Q as M, R as S, U as y, V as R, W as _, X as C, Y as T, Z as L, _ as h, $ as j, a0 as v, a1 as H, a2 as O, a3 as Z, a4 as k, a5 as A, a6 as Y, a7 as w, a8 as P, a9 as U, aa as N, ab as I, ac as $, ad as z } from "./symbols-aLnytgtc.js";
|
|
2
2
|
import { j as F } from "./jsx-runtime-C5mzlN2N.js";
|
|
3
|
-
import { useState as
|
|
4
|
-
import { K as i, H as l } from "./css-
|
|
5
|
-
import "./eraser-
|
|
6
|
-
const
|
|
7
|
-
const { listen: o } = d(), [c, n] =
|
|
8
|
-
return
|
|
3
|
+
import { useState as Q, useEffect as V, useRef as m, useCallback as f } from "react";
|
|
4
|
+
import { K as i, H as l } from "./css-BKrX40Df.js";
|
|
5
|
+
import "./eraser-DtXU7kOS.js";
|
|
6
|
+
const W = (e) => {
|
|
7
|
+
const { listen: o } = d(), [c, n] = Q([]);
|
|
8
|
+
return V(
|
|
9
9
|
() => o(({ next: [s] }) => n(s ?? [])),
|
|
10
10
|
[o, n]
|
|
11
11
|
), /* @__PURE__ */ F.jsx(x, { ...e, children: c.join(" ") });
|
|
12
|
-
},
|
|
12
|
+
}, X = ({
|
|
13
13
|
onDrag: e,
|
|
14
14
|
triggers: o = [["MouseLeft"], ["MouseRight"]],
|
|
15
15
|
bound: c,
|
|
@@ -43,16 +43,16 @@ const V = (e) => {
|
|
|
43
43
|
KEYS: M,
|
|
44
44
|
MOUSE_KEYS: S,
|
|
45
45
|
Provider: y,
|
|
46
|
-
Status:
|
|
46
|
+
Status: W,
|
|
47
47
|
Text: R,
|
|
48
48
|
compareModeConfigs: _,
|
|
49
49
|
determineMode: C,
|
|
50
50
|
diff: T,
|
|
51
|
-
eventKey:
|
|
52
|
-
filter:
|
|
53
|
-
flattenConfig:
|
|
54
|
-
isAlphanumericKey:
|
|
55
|
-
keyZ:
|
|
51
|
+
eventKey: L,
|
|
52
|
+
filter: h,
|
|
53
|
+
flattenConfig: j,
|
|
54
|
+
isAlphanumericKey: v,
|
|
55
|
+
keyZ: H,
|
|
56
56
|
keyboardKey: O,
|
|
57
57
|
match: Z,
|
|
58
58
|
matchCallback: k,
|
|
@@ -61,15 +61,15 @@ const V = (e) => {
|
|
|
61
61
|
purge: w,
|
|
62
62
|
purgeMouse: P,
|
|
63
63
|
toSymbols: U,
|
|
64
|
-
triggerZ:
|
|
64
|
+
triggerZ: N,
|
|
65
65
|
use: E,
|
|
66
66
|
useContext: d,
|
|
67
|
-
useDrag:
|
|
68
|
-
useFlattenedMemoConfig:
|
|
69
|
-
useHeld:
|
|
70
|
-
useHeldRef:
|
|
67
|
+
useDrag: X,
|
|
68
|
+
useFlattenedMemoConfig: I,
|
|
69
|
+
useHeld: $,
|
|
70
|
+
useHeldRef: z
|
|
71
71
|
}, Symbol.toStringTag, { value: "Module" }));
|
|
72
72
|
export {
|
|
73
73
|
ee as e,
|
|
74
|
-
|
|
74
|
+
X as u
|
|
75
75
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";const e=require("./symbols-
|
|
1
|
+
"use strict";const e=require("./symbols-DWZqHjhU.cjs"),E=require("./jsx-runtime-CITbqOLs.cjs"),u=require("react"),o=require("./css-TyQvZIXQ.cjs");require("./eraser-Bxknv-HS.cjs");const K=t=>{const{listen:i}=e.useContext$4(),[g,l]=u.useState([]);return u.useEffect(()=>i(({next:[r]})=>l(r??[])),[i,l]),E.jsxRuntimeExports.jsx(e.Text,{...t,children:g.join(" ")})},f=({onDrag:t,triggers:i=[["MouseLeft"],["MouseRight"]],bound:g,loose:l=!1})=>{const r=u.useRef(null),a=u.useRef(o.K.ZERO),d=u.useCallback(s=>{const n=o.K.construct(s);if(r.current===null)return;const{triggers:c}=r.current;t({box:o.Ho.construct(a.current,n),cursor:n,triggers:c,stage:"during"})},[t]),m=u.useCallback(s=>{const{stage:n,cursor:c}=s;n==="start"?(t({box:o.Ho.construct(c),...s}),window.addEventListener("mousemove",d),r.current=s,a.current=c):n==="end"&&r.current!=null&&(t({box:o.Ho.construct(a.current,c),...s}),window.removeEventListener("mousemove",d),r.current=null,a.current=o.K.ZERO)},[t]);e.use$1({triggers:i,callback:m,region:g,loose:l})},y=Object.freeze(Object.defineProperty({__proto__:null,ALPHANUMERIC_KEYS:e.ALPHANUMERIC_KEYS,ALPHANUMERIC_KEYS_SET:e.ALPHANUMERIC_KEYS_SET,KEYS:e.KEYS,MOUSE_KEYS:e.MOUSE_KEYS,Provider:e.Provider$1,Status:K,Text:e.Text$1,compareModeConfigs:e.compareModeConfigs,determineMode:e.determineMode,diff:e.diff,eventKey:e.eventKey,filter:e.filter,flattenConfig:e.flattenConfig,isAlphanumericKey:e.isAlphanumericKey,keyZ:e.keyZ,keyboardKey:e.keyboardKey,match:e.match,matchCallback:e.matchCallback,mouseKey:e.mouseKey,mouseKeyZ:e.mouseKeyZ,purge:e.purge,purgeMouse:e.purgeMouse,toSymbols:e.toSymbols,triggerZ:e.triggerZ,use:e.use$1,useContext:e.useContext$4,useDrag:f,useFlattenedMemoConfig:e.useFlattenedMemoConfig,useHeld:e.useHeld,useHeldRef:e.useHeldRef},Symbol.toStringTag,{value:"Module"}));exports.external=y;exports.useDrag=f;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { C as e, L as a, a as s, d as t, b as i, c as o, l as r, s as E, w as l } from "./eraser-
|
|
2
|
-
import { D as n, E as d, M as m, S, T as b, a as L, e as _, i as c } from "./symbols-
|
|
1
|
+
import { C as e, L as a, a as s, d as t, b as i, c as o, l as r, s as E, w as l } from "./eraser-DtXU7kOS.js";
|
|
2
|
+
import { D as n, E as d, M as m, S, T as b, a as L, e as _, i as c } from "./symbols-aLnytgtc.js";
|
|
3
3
|
const O = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
4
4
|
__proto__: null,
|
|
5
5
|
COMPONENT_SIZE_LEVELS: e,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";const e=require("./symbols-
|
|
1
|
+
"use strict";const e=require("./symbols-DWZqHjhU.cjs"),t=require("./jsx-runtime-CITbqOLs.cjs");require("./css-TyQvZIXQ.cjs");const a=require("./Toggle-CCsw0kkq.cjs");require("react");const m=require("./useKeysData-G9Mk3mA6.cjs");require("./eraser-Bxknv-HS.cjs");require("react-dom");const l=({keys:s,value:n,onChange:o,allowNone:i,multiple:u,...x})=>{const j=m.useKeysData(s);return t.jsxRuntimeExports.jsx(e.Frame$1,{closeDialogOnSelect:!1,...j,allowNone:i,multiple:u,value:n,onChange:o,children:t.jsxRuntimeExports.jsx(e.Box,{pack:!0,...x})})},r=({itemKey:s,...n})=>{const{setSelected:o}=e.useContext$3(),{selected:i,onSelect:u}=e.useItemState(s);return t.jsxRuntimeExports.jsx(a.Toggle,{...n,onChange:u,value:i,onContextMenu:x=>{o([s]),x.preventDefault()}})},c=({value:s,...n})=>t.jsxRuntimeExports.jsxs(l,{...n,value:s,keys:e.ALIGNMENTS,children:[t.jsxRuntimeExports.jsx(r,{itemKey:"start",children:t.jsxRuntimeExports.jsx(e.TextAlign.Left,{})}),t.jsxRuntimeExports.jsx(r,{itemKey:"center",children:t.jsxRuntimeExports.jsx(e.TextAlign.Center,{})}),t.jsxRuntimeExports.jsx(r,{itemKey:"end",children:t.jsxRuntimeExports.jsx(e.TextAlign.Right,{})})]}),p=Object.freeze(Object.defineProperty({__proto__:null,ALIGNMENTS:e.ALIGNMENTS,Box:e.Box,JUSTIFICATIONS:e.JUSTIFICATIONS,SelectAlignment:c,alignmentZ:e.alignmentZ,justificationZ:e.justificationZ,parseDirection:e.parseDirection,shouldReverse:e.shouldReverse},Symbol.toStringTag,{value:"Module"}));exports.Button=r;exports.Buttons=l;exports.SelectAlignment=c;exports.external=p;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";const o=require("./jsx-runtime-CITbqOLs.cjs"),e=require("./css-
|
|
1
|
+
"use strict";const o=require("./jsx-runtime-CITbqOLs.cjs"),e=require("./css-TyQvZIXQ.cjs"),a=require("./symbols-DWZqHjhU.cjs"),u=require("react"),x=require("./eraser-Bxknv-HS.cjs");require("react-dom");const S=({children:t=[],...s})=>o.jsxRuntimeExports.jsx(a.Box,{x:!0,gap:"small",align:"center",className:e.CSS.BE("header","actions"),...s,children:t}),i=u.createContext({divided:!1,level:"h1"}),c=()=>u.use(i),d=({className:t,level:s="p",divided:r=!1,bordered:n=!0,...l})=>o.jsxRuntimeExports.jsx(i,{value:{level:s,divided:r},children:o.jsxRuntimeExports.jsx(a.Box,{el:"header",x:!0,align:"center",justify:"between",className:e.CSS(e.CSS.B("header"),n&&e.CSS.bordered("bottom"),r&&e.CSS.BM("header","divided"),t),...l})}),j=({children:t="",className:s,onClick:r,...n})=>{const{level:l}=c();return o.jsxRuntimeExports.jsx(a.Button,{variant:"text",size:x.LEVEL_COMPONENT_SIZES[l],onClick:r,className:e.CSS(e.CSS.B("header-button-title"),s),sharp:!0,...n,children:t})},m=({className:t,level:s,...r})=>{const{level:n}=c();return o.jsxRuntimeExports.jsx(a.Text,{className:e.CSS(e.CSS.BE("header","text"),t),level:s??n,gap:1.5,...r})},C=Object.freeze(Object.defineProperty({__proto__:null,Actions:S,ButtonTitle:j,Header:d,Title:m,useContext:c},Symbol.toStringTag,{value:"Module"}));exports.external=C;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { S as r, e as a, f as i, t as n } from "./eraser-
|
|
2
|
-
import { u as o, P as S, b as p, t as u, c as m, d as b } from "./symbols-
|
|
3
|
-
import { f as c } from "./fontString-
|
|
1
|
+
import { S as r, e as a, f as i, t as n } from "./eraser-DtXU7kOS.js";
|
|
2
|
+
import { u as o, P as S, b as p, t as u, c as m, d as b } from "./symbols-aLnytgtc.js";
|
|
3
|
+
import { f as c } from "./fontString-D2-HUuI_.js";
|
|
4
4
|
const f = (t) => {
|
|
5
5
|
const { theme: e } = o(), s = e.typography[t];
|
|
6
6
|
return {
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";const e=require("./symbols-DWZqHjhU.cjs"),t=require("./Toggle-CCsw0kkq.cjs"),o=Object.freeze(Object.defineProperty({__proto__:null,Button:e.Button,Toggle:t.Toggle},Symbol.toStringTag,{value:"Module"}));exports.external=o;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { o as s, B as u, p as g, F as x, q as b, r as j } from "./symbols-aLnytgtc.js";
|
|
2
2
|
import { j as a } from "./jsx-runtime-C5mzlN2N.js";
|
|
3
|
-
import { A as v } from "./Animated-
|
|
4
|
-
import { C as
|
|
3
|
+
import { A as v } from "./Animated-BHxq6Pmm.js";
|
|
4
|
+
import { C as r } from "./css-BKrX40Df.js";
|
|
5
5
|
const C = ({
|
|
6
6
|
onClick: l,
|
|
7
7
|
className: n,
|
|
@@ -10,12 +10,12 @@ const C = ({
|
|
|
10
10
|
variant: o,
|
|
11
11
|
...m
|
|
12
12
|
}) => {
|
|
13
|
-
const { toggle: c, visible: f, variant: p } =
|
|
13
|
+
const { toggle: c, visible: f, variant: p } = s();
|
|
14
14
|
let t;
|
|
15
15
|
return o === "preview" && (e = !0), p !== "modal" && !e && (t = /* @__PURE__ */ a.jsx(v, { enabled: f, enabledLoc: "bottom", disabledLoc: "left" })), /* @__PURE__ */ a.jsxs(
|
|
16
16
|
u,
|
|
17
17
|
{
|
|
18
|
-
className:
|
|
18
|
+
className: r(r.BE("dialog", "trigger"), n),
|
|
19
19
|
onClick: (d) => {
|
|
20
20
|
l?.(d), c();
|
|
21
21
|
},
|
|
@@ -28,16 +28,16 @@ const C = ({
|
|
|
28
28
|
]
|
|
29
29
|
}
|
|
30
30
|
);
|
|
31
|
-
},
|
|
31
|
+
}, y = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
32
32
|
__proto__: null,
|
|
33
33
|
Dialog: g,
|
|
34
34
|
Frame: x,
|
|
35
35
|
Trigger: C,
|
|
36
36
|
positionDialog: b,
|
|
37
|
-
useContext:
|
|
37
|
+
useContext: s,
|
|
38
38
|
useInternalContext: j
|
|
39
39
|
}, Symbol.toStringTag, { value: "Module" }));
|
|
40
40
|
export {
|
|
41
41
|
C as T,
|
|
42
|
-
|
|
42
|
+
y as e
|
|
43
43
|
};
|
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { s as u, v as c, w as p, x as j, A as m, y as i, J as d, z as S, G as f, H as g, I as h } from "./symbols-aLnytgtc.js";
|
|
2
2
|
import { j as e } from "./jsx-runtime-C5mzlN2N.js";
|
|
3
|
-
import "./css-
|
|
4
|
-
import { T as y } from "./Toggle-
|
|
3
|
+
import "./css-BKrX40Df.js";
|
|
4
|
+
import { T as y } from "./Toggle-C--I90ch.js";
|
|
5
5
|
import "react";
|
|
6
6
|
import { u as T } from "./useKeysData-B1kiZOOw.js";
|
|
7
|
-
import "./eraser-
|
|
7
|
+
import "./eraser-DtXU7kOS.js";
|
|
8
8
|
import "react-dom";
|
|
9
|
-
const
|
|
9
|
+
const I = ({
|
|
10
10
|
keys: t,
|
|
11
11
|
value: s,
|
|
12
12
|
onChange: o,
|
|
@@ -43,10 +43,10 @@ const v = ({
|
|
|
43
43
|
}
|
|
44
44
|
}
|
|
45
45
|
);
|
|
46
|
-
},
|
|
46
|
+
}, v = ({
|
|
47
47
|
value: t,
|
|
48
48
|
...s
|
|
49
|
-
}) => /* @__PURE__ */ e.jsxs(
|
|
49
|
+
}) => /* @__PURE__ */ e.jsxs(I, { ...s, value: t, keys: m, children: [
|
|
50
50
|
/* @__PURE__ */ e.jsx(l, { itemKey: "start", children: /* @__PURE__ */ e.jsx(i.Left, {}) }),
|
|
51
51
|
/* @__PURE__ */ e.jsx(l, { itemKey: "center", children: /* @__PURE__ */ e.jsx(i.Center, {}) }),
|
|
52
52
|
/* @__PURE__ */ e.jsx(l, { itemKey: "end", children: /* @__PURE__ */ e.jsx(i.Right, {}) })
|
|
@@ -55,15 +55,15 @@ const v = ({
|
|
|
55
55
|
ALIGNMENTS: m,
|
|
56
56
|
Box: c,
|
|
57
57
|
JUSTIFICATIONS: d,
|
|
58
|
-
SelectAlignment:
|
|
58
|
+
SelectAlignment: v,
|
|
59
59
|
alignmentZ: S,
|
|
60
60
|
justificationZ: f,
|
|
61
61
|
parseDirection: g,
|
|
62
62
|
shouldReverse: h
|
|
63
63
|
}, Symbol.toStringTag, { value: "Module" }));
|
|
64
64
|
export {
|
|
65
|
-
|
|
66
|
-
|
|
65
|
+
I as B,
|
|
66
|
+
v as S,
|
|
67
67
|
l as a,
|
|
68
68
|
M as e
|
|
69
69
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";const s=require("./symbols-
|
|
1
|
+
"use strict";const s=require("./symbols-DWZqHjhU.cjs"),a=require("react"),d=require("./useKeysData-G9Mk3mA6.cjs");require("./css-TyQvZIXQ.cjs");const b=require("./eraser-Bxknv-HS.cjs"),y=({retrieve:n,pageSize:r=10})=>{const u=a.useCallback(()=>{n(({offset:o=-r,searchTerm:l="",...i})=>({...i,offset:o+r,limit:r,searchTerm:l}),{mode:"append"})},[n,r]),f=a.useCallback(o=>n(l=>({...l,searchTerm:o,offset:0,limit:r})),[n,r]);return{fetchMore:u,search:f}},h=({initialData:n}={})=>{const r=s.useInitializerRef(()=>{const e=new Map;return n==null||n.forEach(t=>e.set(t.key,t)),e}),u=s.useInitializerRef(()=>new Map),f=a.useCallback(e=>{const t=new Set(e);u.current.forEach((m,c)=>{t.has(m)&&c()})},[]),o=a.useCallback(e=>{const t=b.t.toArray(e),m=t.map(c=>c.key);t.forEach(c=>r.current.set(c.key,c)),f(m)},[]),l=a.useCallback(e=>{const t=b.t.toArray(e);t.forEach(m=>r.current.delete(m)),f(t)},[]),i=a.useCallback((e,t)=>t==null?()=>{}:(u.current.set(e,t),()=>{u.current.delete(e)}),[u]),C=a.useCallback(e=>{if(e!=null)return Array.isArray(e)?e.map(t=>r.current.get(t)).filter(t=>t!=null):r.current.get(e)},[]),I=a.useCallback(e=>r.current.has(e),[]);return{setItem:o,deleteItem:l,subscribe:i,getItem:C,hasItem:I}},k=Object.freeze(Object.defineProperty({__proto__:null,CoreFrame:s.CoreFrame,Frame:s.Frame$2,Item:s.Item,Items:s.Items,useData:s.useData,useItem:s.useItem,useKeysData:d.useKeysData,useMapData:h,usePager:y,useScroller:s.useScroller,useStaticData:s.useStaticData,useUtilContext:s.useUtilContext},Symbol.toStringTag,{value:"Module"}));exports.external=k;exports.usePager=y;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";const e=require("./symbols-
|
|
1
|
+
"use strict";const e=require("./symbols-DWZqHjhU.cjs"),s=require("./jsx-runtime-CITbqOLs.cjs"),b=require("./Animated-DEXELMDa.cjs"),i=require("./css-TyQvZIXQ.cjs"),r=({onClick:l,className:a,hideCaret:t=!1,children:u,variant:o,...c})=>{const{toggle:x,visible:g,variant:m}=e.useContext$2();let n;return o==="preview"&&(t=!0),m!=="modal"&&!t&&(n=s.jsxRuntimeExports.jsx(b.Animated,{enabled:g,enabledLoc:"bottom",disabledLoc:"left"})),s.jsxRuntimeExports.jsxs(e.Button,{className:i.CSS(i.CSS.BE("dialog","trigger"),a),onClick:d=>{l?.(d),x()},full:"x",variant:o,...c,children:[u,n]})},f=Object.freeze(Object.defineProperty({__proto__:null,Dialog:e.Dialog,Frame:e.Frame,Trigger:r,positionDialog:e.positionDialog,useContext:e.useContext$2,useInternalContext:e.useInternalContext},Symbol.toStringTag,{value:"Module"}));exports.Trigger=r;exports.external=f;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";const r=require("./jsx-runtime-CITbqOLs.cjs"),e=require("./symbols-
|
|
1
|
+
"use strict";const r=require("./jsx-runtime-CITbqOLs.cjs"),e=require("./symbols-DWZqHjhU.cjs"),n=require("./css-TyQvZIXQ.cjs");require("./eraser-Bxknv-HS.cjs");require("react");require("react-dom");const b=t=>r.jsxRuntimeExports.jsx(e.Boolean,{inputType:"checkbox",...t}),g=({className:t,variant:i="error",...s})=>r.jsxRuntimeExports.jsx(e.Text,{className:n.CSS(n.CSS.B("input-help-text"),n.CSS.BM("input-help-text",i),t),level:"small",...s}),R=({className:t,required:i=!1,children:s,...l})=>r.jsxRuntimeExports.jsxs("label",{className:n.CSS(n.CSS.B("input-label"),t),...l,children:[s," ",i&&r.jsxRuntimeExports.jsx("span",{className:n.CSS.B("required-indicator"),children:"*"})]}),y=(t,i="y")=>t??(n.g.construct(i)==="y"?"stretch":"center"),B=({label:t,showLabel:i=!0,helpText:s,direction:l,x:c,y:x,className:m,children:u,required:S,align:d,gap:C="small",padHelpText:o=!1,status:a,showHelpText:h=!0,...f})=>{const j=e.parseDirection(l,c,x,!1);let p;const D=h&&s!=null&&s.length>0,E=i&&t!=null&&t.length>0;return!D&&!E?r.jsxRuntimeExports.jsx(r.jsxRuntimeExports.Fragment,{children:u}):(j==="x"?p=r.jsxRuntimeExports.jsxs(e.Box,{y:!0,gap:"small",children:[u,h&&(o||s!=null&&s.length>0)&&r.jsxRuntimeExports.jsx(g,{variant:a,children:s})]}):p=r.jsxRuntimeExports.jsxs(e.Box,{y:!0,gap:1/3,align:"stretch",children:[u,(o||s!=null&&s.length>0)&&r.jsxRuntimeExports.jsx(g,{variant:a,children:s})]}),r.jsxRuntimeExports.jsxs(e.Box,{className:n.CSS(n.CSS.BE("input","item"),m),direction:j,gap:C,align:y(d,j),...f,children:[E&&r.jsxRuntimeExports.jsx(R,{required:S,children:t}),p]}))},T=({ref:t,value:i,style:s,onChange:l,className:c,onFocus:x,selectOnFocus:m=!1,variant:u="outlined",sharp:S=!1,children:d,wrap:C,...o})=>r.jsxRuntimeExports.jsx("textarea",{style:s,className:n.CSS(n.CSS.B("textarea"),n.CSS.BM("textarea",u),n.CSS.sharp(S),c),ref:t,value:i,onChange:a=>l(a.target.value.replace(/\n/g,"")),onFocus:a=>{m&&a.target.select(),x?.(a)},...o}),q=Object.freeze(Object.defineProperty({__proto__:null,Calendar:e.Calendar,Checkbox:b,Date:e.Date,DateTime:e.DateTime$1,DragButton:e.DragButton,HelpText:g,Item:B,Label:R,Numeric:e.Numeric,Switch:e.Switch$1,Text:e.Text$2,TextArea:T,Time:e.Time,TimeSelector:e.TimeSelector,combineDateAndTimeValue:e.combineDateAndTimeValue,createTimeList:e.createTimeList,useDate:e.useDate,useTime:e.useTime},Symbol.toStringTag,{value:"Module"}));exports.Item=B;exports.external=q;
|
|
@@ -1,13 +1,12 @@
|
|
|
1
|
-
import { j as
|
|
2
|
-
import { C as r, H as
|
|
3
|
-
import { createContext as
|
|
4
|
-
import {
|
|
5
|
-
import { C as M, y as re } from "./eraser-
|
|
1
|
+
import { j as s } from "./jsx-runtime-C5mzlN2N.js";
|
|
2
|
+
import { C as r, H as k, K as X, a as G, g as $ } from "./css-BKrX40Df.js";
|
|
3
|
+
import { createContext as q, use as z, useState as I, useCallback as C } from "react";
|
|
4
|
+
import { n as J, k as Q, v as T, B as w, as as U, j as W, h as Y, at as K, T as ee, E as te, au as ne, av as se, ap as oe, ar as le } from "./symbols-aLnytgtc.js";
|
|
5
|
+
import { C as M, y as re } from "./eraser-DtXU7kOS.js";
|
|
6
6
|
import "react-dom";
|
|
7
|
-
import "./Menu-BFD8DPDp.js";
|
|
8
7
|
import { z as g } from "zod";
|
|
9
|
-
const V =
|
|
10
|
-
className:
|
|
8
|
+
const V = q({ tabs: [] }), R = V, L = () => z(V), _ = "tabs-selector", Z = ({
|
|
9
|
+
className: o,
|
|
11
10
|
altColor: t = !1,
|
|
12
11
|
size: e = "medium",
|
|
13
12
|
direction: l = "x",
|
|
@@ -24,11 +23,11 @@ const V = $({ tabs: [] }), R = V, L = () => z(V), _ = "tabs-selector", Z = ({
|
|
|
24
23
|
onDragEnd: S,
|
|
25
24
|
onDragStart: N,
|
|
26
25
|
onDrop: E,
|
|
27
|
-
onRename:
|
|
28
|
-
onCreate:
|
|
26
|
+
onRename: v,
|
|
27
|
+
onCreate: m
|
|
29
28
|
} = L(), j = J(), [O, f] = I(!1);
|
|
30
|
-
return /* @__PURE__ */
|
|
31
|
-
n != null && /* @__PURE__ */
|
|
29
|
+
return /* @__PURE__ */ s.jsxs(s.Fragment, { children: [
|
|
30
|
+
n != null && /* @__PURE__ */ s.jsx(
|
|
32
31
|
Q,
|
|
33
32
|
{
|
|
34
33
|
style: { height: "fit-content" },
|
|
@@ -36,12 +35,12 @@ const V = $({ tabs: [] }), R = V, L = () => z(V), _ = "tabs-selector", Z = ({
|
|
|
36
35
|
menu: n
|
|
37
36
|
}
|
|
38
37
|
),
|
|
39
|
-
/* @__PURE__ */
|
|
38
|
+
/* @__PURE__ */ s.jsxs(
|
|
40
39
|
T,
|
|
41
40
|
{
|
|
42
41
|
className: r(
|
|
43
42
|
r.B(_),
|
|
44
|
-
|
|
43
|
+
o,
|
|
45
44
|
j.className,
|
|
46
45
|
O && r.M("drag-over")
|
|
47
46
|
),
|
|
@@ -54,8 +53,8 @@ const V = $({ tabs: [] }), R = V, L = () => z(V), _ = "tabs-selector", Z = ({
|
|
|
54
53
|
onDrop: E,
|
|
55
54
|
...c,
|
|
56
55
|
children: [
|
|
57
|
-
/* @__PURE__ */
|
|
58
|
-
u.map((d) => /* @__PURE__ */
|
|
56
|
+
/* @__PURE__ */ s.jsxs(T, { direction: l, className: r.BE(_, "tabs"), empty: !0, children: [
|
|
57
|
+
u.map((d) => /* @__PURE__ */ s.jsx(
|
|
59
58
|
ue,
|
|
60
59
|
{
|
|
61
60
|
selected: p,
|
|
@@ -64,14 +63,14 @@ const V = $({ tabs: [] }), R = V, L = () => z(V), _ = "tabs-selector", Z = ({
|
|
|
64
63
|
onClose: D,
|
|
65
64
|
onDragStart: N,
|
|
66
65
|
onDragEnd: S,
|
|
67
|
-
onRename:
|
|
66
|
+
onRename: v,
|
|
68
67
|
closable: d.closable ?? h,
|
|
69
68
|
size: e,
|
|
70
69
|
...d
|
|
71
70
|
},
|
|
72
71
|
d.tabKey
|
|
73
72
|
)),
|
|
74
|
-
E != null && /* @__PURE__ */
|
|
73
|
+
E != null && /* @__PURE__ */ s.jsx(
|
|
75
74
|
T,
|
|
76
75
|
{
|
|
77
76
|
onDragOver: () => f(!0),
|
|
@@ -82,33 +81,33 @@ const V = $({ tabs: [] }), R = V, L = () => z(V), _ = "tabs-selector", Z = ({
|
|
|
82
81
|
}
|
|
83
82
|
)
|
|
84
83
|
] }),
|
|
85
|
-
|
|
86
|
-
|
|
84
|
+
m != null && /* @__PURE__ */ s.jsx(T, { className: r.BE(_, "actions"), children: /* @__PURE__ */ s.jsx(
|
|
85
|
+
w,
|
|
87
86
|
{
|
|
88
87
|
size: e,
|
|
89
88
|
sharp: !0,
|
|
90
|
-
onClick:
|
|
89
|
+
onClick: m,
|
|
91
90
|
tooltip: a,
|
|
92
91
|
variant: "text",
|
|
93
|
-
children: /* @__PURE__ */
|
|
92
|
+
children: /* @__PURE__ */ s.jsx(U, {})
|
|
94
93
|
}
|
|
95
94
|
) })
|
|
96
95
|
]
|
|
97
96
|
}
|
|
98
97
|
)
|
|
99
98
|
] });
|
|
100
|
-
}, ae = ({ unsavedChanges:
|
|
101
|
-
const e = /* @__PURE__ */
|
|
102
|
-
return
|
|
103
|
-
/* @__PURE__ */
|
|
99
|
+
}, ae = ({ unsavedChanges: o, ...t }) => {
|
|
100
|
+
const e = /* @__PURE__ */ s.jsx(ne, { ...t });
|
|
101
|
+
return o ? /* @__PURE__ */ s.jsxs(s.Fragment, { children: [
|
|
102
|
+
/* @__PURE__ */ s.jsx(se, {}),
|
|
104
103
|
e
|
|
105
104
|
] }) : e;
|
|
106
|
-
}, ce = (
|
|
107
|
-
const t =
|
|
108
|
-
|
|
109
|
-
), e = X.construct(
|
|
110
|
-
return
|
|
111
|
-
}, ie = ({ loading:
|
|
105
|
+
}, ce = (o) => {
|
|
106
|
+
const t = k.construct(
|
|
107
|
+
o.target.closest(".pluto-tabs-selector__btn")
|
|
108
|
+
), e = X.construct(o);
|
|
109
|
+
return G.Scale.scale(k.left(t), k.right(t)).scale(0, 1).pos(e.x) < 0.5 ? "left" : "right";
|
|
110
|
+
}, ie = ({ loading: o, icon: t, level: e = "p" }) => (o && (t = /* @__PURE__ */ s.jsx(oe, {})), K(t, {
|
|
112
111
|
className: r.BE(_, "icon"),
|
|
113
112
|
style: {
|
|
114
113
|
color: r.colorVar(9),
|
|
@@ -116,7 +115,7 @@ const V = $({ tabs: [] }), R = V, L = () => z(V), _ = "tabs-selector", Z = ({
|
|
|
116
115
|
width: r.levelSizeVar(e)
|
|
117
116
|
}
|
|
118
117
|
})), ue = ({
|
|
119
|
-
selected:
|
|
118
|
+
selected: o,
|
|
120
119
|
altColor: t = !1,
|
|
121
120
|
onSelect: e,
|
|
122
121
|
onClose: l,
|
|
@@ -131,9 +130,9 @@ const V = $({ tabs: [] }), R = V, L = () => z(V), _ = "tabs-selector", Z = ({
|
|
|
131
130
|
editable: S = !0,
|
|
132
131
|
unsavedChanges: N = !1,
|
|
133
132
|
loading: E = !1,
|
|
134
|
-
onDrop:
|
|
133
|
+
onDrop: v
|
|
135
134
|
}) => {
|
|
136
|
-
const
|
|
135
|
+
const m = C(
|
|
137
136
|
(i) => c?.(i, { tabKey: n, name: a }),
|
|
138
137
|
[c, n, a]
|
|
139
138
|
), j = C(
|
|
@@ -148,15 +147,15 @@ const V = $({ tabs: [] }), R = V, L = () => z(V), _ = "tabs-selector", Z = ({
|
|
|
148
147
|
(i) => {
|
|
149
148
|
x(ce(i));
|
|
150
149
|
},
|
|
151
|
-
[x,
|
|
150
|
+
[x, v]
|
|
152
151
|
), P = C(
|
|
153
152
|
(i) => {
|
|
154
|
-
|
|
153
|
+
v?.(i), x(null);
|
|
155
154
|
},
|
|
156
|
-
[
|
|
157
|
-
), y =
|
|
158
|
-
return /* @__PURE__ */
|
|
159
|
-
|
|
155
|
+
[v, x]
|
|
156
|
+
), y = o === n, H = M[h];
|
|
157
|
+
return /* @__PURE__ */ s.jsxs(
|
|
158
|
+
w,
|
|
160
159
|
{
|
|
161
160
|
el: "div",
|
|
162
161
|
size: h,
|
|
@@ -183,15 +182,15 @@ const V = $({ tabs: [] }), R = V, L = () => z(V), _ = "tabs-selector", Z = ({
|
|
|
183
182
|
onDragOver: B,
|
|
184
183
|
onDrop: P,
|
|
185
184
|
onDragLeave: () => x(null),
|
|
186
|
-
onDragStart:
|
|
185
|
+
onDragStart: m,
|
|
187
186
|
onDragEnd: (i) => {
|
|
188
187
|
x(null), j(i);
|
|
189
188
|
},
|
|
190
189
|
bordered: !1,
|
|
191
190
|
rounded: !1,
|
|
192
191
|
children: [
|
|
193
|
-
/* @__PURE__ */
|
|
194
|
-
/* @__PURE__ */
|
|
192
|
+
/* @__PURE__ */ s.jsx(ie, { loading: E, icon: D, level: H }),
|
|
193
|
+
/* @__PURE__ */ s.jsx(
|
|
195
194
|
de,
|
|
196
195
|
{
|
|
197
196
|
name: a,
|
|
@@ -201,50 +200,50 @@ const V = $({ tabs: [] }), R = V, L = () => z(V), _ = "tabs-selector", Z = ({
|
|
|
201
200
|
level: M[h]
|
|
202
201
|
}
|
|
203
202
|
),
|
|
204
|
-
b && l != null && /* @__PURE__ */
|
|
205
|
-
|
|
203
|
+
b && l != null && /* @__PURE__ */ s.jsx(
|
|
204
|
+
w,
|
|
206
205
|
{
|
|
207
206
|
"aria-label": "pluto-tabs__close",
|
|
208
207
|
onClick: O,
|
|
209
208
|
className: r.E("close"),
|
|
210
209
|
variant: "text",
|
|
211
210
|
sharp: !0,
|
|
212
|
-
children: /* @__PURE__ */
|
|
211
|
+
children: /* @__PURE__ */ s.jsx(ae, { unsavedChanges: N })
|
|
213
212
|
}
|
|
214
213
|
)
|
|
215
214
|
]
|
|
216
215
|
}
|
|
217
216
|
);
|
|
218
217
|
}, de = ({
|
|
219
|
-
onRename:
|
|
218
|
+
onRename: o,
|
|
220
219
|
name: t,
|
|
221
220
|
tabKey: e,
|
|
222
221
|
editable: l = !0,
|
|
223
222
|
level: n
|
|
224
|
-
}) =>
|
|
223
|
+
}) => o == null || !l ? /* @__PURE__ */ s.jsx(ee, { overflow: "ellipsis", level: n, children: t }) : /* @__PURE__ */ s.jsx(
|
|
225
224
|
te,
|
|
226
225
|
{
|
|
227
226
|
level: n,
|
|
228
227
|
id: r.B(`tab-${e}`),
|
|
229
|
-
onChange: (a) =>
|
|
228
|
+
onChange: (a) => o?.(e, a),
|
|
230
229
|
value: t,
|
|
231
230
|
overflow: "ellipsis"
|
|
232
231
|
}
|
|
233
|
-
), ge = (
|
|
232
|
+
), ge = (o = "", t = []) => {
|
|
234
233
|
if (t.length !== 0)
|
|
235
|
-
return t.find((e) => e.tabKey ===
|
|
236
|
-
}, pe = (
|
|
234
|
+
return t.find((e) => e.tabKey === o) != null ? o : t[t.length - 1]?.tabKey;
|
|
235
|
+
}, pe = (o, t, e) => {
|
|
237
236
|
if (t = t.trim(), t.length === 0) return e;
|
|
238
|
-
const l = e.find((n) => n.tabKey ===
|
|
239
|
-
return l == null || l.name === t ? e : e.map((n) => n.tabKey ===
|
|
237
|
+
const l = e.find((n) => n.tabKey === o);
|
|
238
|
+
return l == null || l.name === t ? e : e.map((n) => n.tabKey === o ? { ...n, name: t } : n);
|
|
240
239
|
}, fe = ({
|
|
241
|
-
tabs:
|
|
240
|
+
tabs: o,
|
|
242
241
|
content: t,
|
|
243
242
|
selected: e,
|
|
244
243
|
onSelect: l
|
|
245
244
|
}) => {
|
|
246
245
|
const [n, a] = re({
|
|
247
|
-
initial: e ??
|
|
246
|
+
initial: e ?? o[0]?.tabKey ?? "",
|
|
248
247
|
value: e,
|
|
249
248
|
onChange: l
|
|
250
249
|
}), c = le(e ?? n), u = C(
|
|
@@ -254,13 +253,13 @@ const V = $({ tabs: [] }), R = V, L = () => z(V), _ = "tabs-selector", Z = ({
|
|
|
254
253
|
[n, l]
|
|
255
254
|
);
|
|
256
255
|
return {
|
|
257
|
-
tabs:
|
|
256
|
+
tabs: o,
|
|
258
257
|
selected: n,
|
|
259
258
|
content: t,
|
|
260
259
|
onSelect: u
|
|
261
260
|
};
|
|
262
261
|
}, xe = ({
|
|
263
|
-
id:
|
|
262
|
+
id: o,
|
|
264
263
|
content: t,
|
|
265
264
|
children: e,
|
|
266
265
|
onSelect: l,
|
|
@@ -275,8 +274,8 @@ const V = $({ tabs: [] }), R = V, L = () => z(V), _ = "tabs-selector", Z = ({
|
|
|
275
274
|
onRename: S,
|
|
276
275
|
emptyContent: N,
|
|
277
276
|
className: E,
|
|
278
|
-
onDragOver:
|
|
279
|
-
onDrop:
|
|
277
|
+
onDragOver: v,
|
|
278
|
+
onDrop: m,
|
|
280
279
|
contextMenu: j,
|
|
281
280
|
addTooltip: O,
|
|
282
281
|
size: f = "medium",
|
|
@@ -284,19 +283,19 @@ const V = $({ tabs: [] }), R = V, L = () => z(V), _ = "tabs-selector", Z = ({
|
|
|
284
283
|
x,
|
|
285
284
|
y: B,
|
|
286
285
|
...P
|
|
287
|
-
}) => /* @__PURE__ */
|
|
286
|
+
}) => /* @__PURE__ */ s.jsx(
|
|
288
287
|
T,
|
|
289
288
|
{
|
|
290
|
-
id:
|
|
289
|
+
id: o,
|
|
291
290
|
empty: !0,
|
|
292
291
|
className: r(r.B("tabs"), E),
|
|
293
292
|
direction: d,
|
|
294
293
|
x,
|
|
295
294
|
y: B,
|
|
296
|
-
onDragOver:
|
|
297
|
-
onDrop:
|
|
295
|
+
onDragOver: v,
|
|
296
|
+
onDrop: m,
|
|
298
297
|
...P,
|
|
299
|
-
children: /* @__PURE__ */
|
|
298
|
+
children: /* @__PURE__ */ s.jsxs(
|
|
300
299
|
R,
|
|
301
300
|
{
|
|
302
301
|
value: {
|
|
@@ -311,29 +310,29 @@ const V = $({ tabs: [] }), R = V, L = () => z(V), _ = "tabs-selector", Z = ({
|
|
|
311
310
|
onDragEnd: D,
|
|
312
311
|
onRename: S,
|
|
313
312
|
onCreate: h,
|
|
314
|
-
onDrop:
|
|
313
|
+
onDrop: m
|
|
315
314
|
},
|
|
316
315
|
children: [
|
|
317
|
-
/* @__PURE__ */
|
|
316
|
+
/* @__PURE__ */ s.jsx(
|
|
318
317
|
Z,
|
|
319
318
|
{
|
|
320
319
|
size: f,
|
|
321
|
-
direction:
|
|
320
|
+
direction: $.swap(d),
|
|
322
321
|
altColor: a,
|
|
323
322
|
contextMenu: j,
|
|
324
323
|
addTooltip: O
|
|
325
324
|
}
|
|
326
325
|
),
|
|
327
|
-
/* @__PURE__ */
|
|
326
|
+
/* @__PURE__ */ s.jsx(A, {})
|
|
328
327
|
]
|
|
329
328
|
}
|
|
330
329
|
)
|
|
331
330
|
}
|
|
332
331
|
), A = () => {
|
|
333
|
-
const { tabs:
|
|
332
|
+
const { tabs: o, selected: t, content: e, emptyContent: l, onSelect: n } = L();
|
|
334
333
|
let a = null;
|
|
335
|
-
const c =
|
|
336
|
-
return t == null || c == null ? a = l ?? null : e != null ? typeof e == "function" ? a = e(c) : a = e : c.content != null && (a = c.content), /* @__PURE__ */
|
|
334
|
+
const c = o.find((u) => u.tabKey === t);
|
|
335
|
+
return t == null || c == null ? a = l ?? null : e != null ? typeof e == "function" ? a = e(c) : a = e : c.content != null && (a = c.content), /* @__PURE__ */ s.jsx(
|
|
337
336
|
"div",
|
|
338
337
|
{
|
|
339
338
|
className: r.B("tabs-content"),
|
|
@@ -352,7 +351,7 @@ const V = $({ tabs: [] }), R = V, L = () => z(V), _ = "tabs-selector", Z = ({
|
|
|
352
351
|
loading: g.boolean().optional()
|
|
353
352
|
}), he = F.extend({
|
|
354
353
|
content: g.unknown().optional()
|
|
355
|
-
}),
|
|
354
|
+
}), De = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
356
355
|
__proto__: null,
|
|
357
356
|
Content: A,
|
|
358
357
|
Provider: R,
|
|
@@ -368,7 +367,7 @@ const V = $({ tabs: [] }), R = V, L = () => z(V), _ = "tabs-selector", Z = ({
|
|
|
368
367
|
export {
|
|
369
368
|
xe as T,
|
|
370
369
|
pe as a,
|
|
371
|
-
|
|
370
|
+
De as e,
|
|
372
371
|
ge as r,
|
|
373
372
|
he as t,
|
|
374
373
|
fe as u
|