adminizer 4.5.0-build.199 → 4.5.0-build.201

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.
Files changed (55) hide show
  1. package/assets/{DiffViewer-DL5uCv8d.js → DiffViewer-B36sF5l-.js} +1 -1
  2. package/assets/add-C_-KTZY-.js +1 -0
  3. package/assets/{add-form-Nn7zuSFW.js → add-form-BdmoVC_G.js} +1 -1
  4. package/assets/add-group-Bg5tLxYu.js +1 -0
  5. package/assets/{add-group-form-DUhDxVwB.js → add-group-form-B7c4coU-.js} +1 -1
  6. package/assets/add-user-H6XsOKX_.js +1 -0
  7. package/assets/{add-user-form-Ct4i6Dse.js → add-user-form-BXSGx38D.js} +1 -1
  8. package/assets/{app-layout-DM2_7wxW.js → app-layout-CbRvDFF3.js} +1 -1
  9. package/assets/{app-shell-CwiL9UZ5.js → app-shell-DbPu3ZPM.js} +1 -1
  10. package/assets/{app-sidebar-C7TXiSvV.js → app-sidebar-CQqvkGH0.js} +1 -1
  11. package/assets/{app-sidebar-header-qHEOMq5D.js → app-sidebar-header-C8sntqs3.js} +1 -1
  12. package/assets/app.js +2 -2
  13. package/assets/{breadcrumbs-D5PCyRGn.js → breadcrumbs-Df-vVsyM.js} +1 -1
  14. package/assets/{catalog-BIwiWMeW.js → catalog-BsRePE_I.js} +4 -4
  15. package/assets/{dashboard-C2Y09gw1.js → dashboard-Bynx-P6M.js} +1 -1
  16. package/assets/date-picker-Dk9WjnjY.js +1 -0
  17. package/assets/{del-modal-yU9LPEgz.js → del-modal-TaroxmfE.js} +1 -1
  18. package/assets/{field-renderer-Ddc4u-gC.js → field-renderer-C1uKgcGe.js} +3 -3
  19. package/assets/{form-G2lvZbid.js → form-BjOpJfcr.js} +1 -1
  20. package/assets/form-D6rF7waX.js +1 -0
  21. package/assets/{geo-json-BNEPKsSU.js → geo-json-D5fjz6BF.js} +1 -1
  22. package/assets/history-DL0tB2tZ.js +1 -0
  23. package/assets/{home-Do0C-Tzu.js → home-CADtJAH_.js} +2 -2
  24. package/assets/{icon-FyVrxiPs.js → icon-BTIjB9Wk.js} +1 -1
  25. package/assets/{init-user-DhzPzTRM.js → init-user-CsEDYKZe.js} +1 -1
  26. package/assets/{input-error-cgnQ235Q.js → input-error-CSrUHo1P.js} +1 -1
  27. package/assets/list-B3Ki-psl.js +1 -0
  28. package/assets/{list-table-BxVhDSbv.js → list-table-DSRvmzBT.js} +3 -3
  29. package/assets/{login-Cla-c7nv.js → login-BfN1lJT1.js} +1 -1
  30. package/assets/manifest.json +95 -95
  31. package/assets/{material-icon-DZVU9Gse.js → material-icon-BXxpxGAd.js} +1 -1
  32. package/assets/{media-manager-CDI0y7wm.js → media-manager-Bf7A7-jv.js} +1 -1
  33. package/assets/{module-DI6zzr4C.js → module-B5hkMJ4M.js} +1 -1
  34. package/assets/{nav-footer-B9n8Pd8V.js → nav-footer-Q8fVAK6n.js} +1 -1
  35. package/assets/{nav-main-G6VwCche.js → nav-main-DcvkRp44.js} +1 -1
  36. package/assets/nav-user-PtK5V1sV.js +1 -0
  37. package/assets/{notification-BZzAyhJ1.js → notification-D1_TtX__.js} +1 -1
  38. package/assets/{pagination-render-CqNIIF8P.js → pagination-render-B5A4YOfb.js} +1 -1
  39. package/assets/{register-Bt0RP4PE.js → register-C2TFSMX0.js} +1 -1
  40. package/assets/{tabs-BhUuWdzc.js → tabs-DTgMEGE8.js} +1 -1
  41. package/assets/theme-switcher-Ca0SixmO.js +1 -0
  42. package/assets/{toast-editor-BGjjCkQG.js → toast-editor-D3dhpAw1.js} +1 -1
  43. package/assets/{user-info-gFSwypEN.js → user-info-BTJNUzpi.js} +1 -1
  44. package/assets/{user-menu-content-CjsydEH4.js → user-menu-content-DUnYpt8t.js} +1 -1
  45. package/assets/{welcome-8dJL4cIX.js → welcome-AlKSDf1S.js} +1 -1
  46. package/package.json +1 -1
  47. package/assets/add-D9qTFgIT.js +0 -1
  48. package/assets/add-group-sofsuFYA.js +0 -1
  49. package/assets/add-user-DM1nsN83.js +0 -1
  50. package/assets/date-picker-RBWWCucj.js +0 -1
  51. package/assets/form-P1bFGHCF.js +0 -1
  52. package/assets/history-DHZfSpf_.js +0 -1
  53. package/assets/list-D72uhn00.js +0 -1
  54. package/assets/nav-user-BfROibnw.js +0 -1
  55. package/assets/theme-switcher-BURZ8Tza.js +0 -1
@@ -1 +1 @@
1
- import{j as e,E as f,az as t,bK as n,P as b,bL as g,aF as v}from"./app.js";import{e as p}from"./handsontable-PxYdjN8c.js";const N=({changes:s,title:a="Changes",className:i=""})=>{if(!s||s.length===0)return e.jsx("div",{className:t("bg-muted border border-border rounded-lg p-4",i),children:e.jsxs("div",{className:"flex items-center text-muted-foreground",children:[e.jsx(f,{className:"w-5 h-5 mr-2"}),e.jsx("span",{children:"Changes not found"})]})});const o=r=>r===null?"null":r===void 0?"—":typeof r=="boolean"?r?"Да":"Нет":typeof r=="object"?JSON.stringify(r):String(r),m=r=>r.oldValue===void 0?"added":r.newValue===void 0?"removed":"modified";return e.jsxs("div",{className:t("bg-card border border-border rounded-lg shadow-sm",i),children:[e.jsx("div",{className:"px-4 py-3 border-b border-border bg-muted",children:e.jsxs("h3",{className:"text-lg font-semibold text-card-foreground flex items-center",children:[e.jsx(n,{className:"w-5 h-5 mr-2"}),a," (",s.length,")"]})}),e.jsx("div",{className:"divide-y divide-border",children:s.map((r,l)=>{const d=m(r),c=d==="added"?b:d==="removed"?g:n,x=t("text-xs px-2 py-1 rounded-full bg-opacity-10",d==="added"&&"text-green-600 bg-green-100",d==="removed"&&"text-destructive bg-destructive/20",d==="modified"&&"text-primary bg-primary/20"),u=d==="added"?"text-green-600":d==="removed"?"text-destructive":"text-primary";return e.jsxs("div",{className:"p-4 hover:bg-muted/50 transition-colors",children:[e.jsxs("div",{className:"flex items-center justify-between mb-2",children:[e.jsxs("div",{className:"flex items-center",children:[p.createElement(c,{className:t("w-4 h-4 mr-2",u)}),e.jsx("span",{className:"font-medium text-card-foreground",children:r.field})]}),e.jsx("span",{className:x,children:d==="added"?"Added":d==="removed"?"Removed":"Updated"})]}),e.jsxs("div",{className:"grid grid-cols-1 md:grid-cols-2 gap-3 text-sm",children:[d!=="added"&&e.jsxs("div",{className:"p-2 bg-destructive/10 border border-destructive/20 rounded",children:[e.jsx("div",{className:"text-xs text-destructive font-medium mb-1",children:"Old:"}),e.jsx("div",{className:"text-destructive-foreground font-mono break-words",children:o(r.oldValue)})]}),d!=="removed"&&e.jsxs("div",{className:"p-2 bg-green-50 border border-green-100 rounded",children:[e.jsx("div",{className:"text-xs text-green-600 font-medium mb-1",children:"New:"}),e.jsx("div",{className:"text-green-800 font-mono break-words",children:o(r.newValue)})]})]}),d==="modified"&&e.jsxs("div",{className:"mt-2 flex items-center text-xs text-muted-foreground",children:[e.jsx(v,{className:"w-3 h-3 mr-1"}),"changed type: ",r.type]})]},l)})})]})};export{N as D};
1
+ import{j as e,E as f,aA as t,bL as n,P as b,bM as g,aG as v}from"./app.js";import{e as p}from"./handsontable-PxYdjN8c.js";const N=({changes:s,title:a="Changes",className:i=""})=>{if(!s||s.length===0)return e.jsx("div",{className:t("bg-muted border border-border rounded-lg p-4",i),children:e.jsxs("div",{className:"flex items-center text-muted-foreground",children:[e.jsx(f,{className:"w-5 h-5 mr-2"}),e.jsx("span",{children:"Changes not found"})]})});const o=r=>r===null?"null":r===void 0?"—":typeof r=="boolean"?r?"Да":"Нет":typeof r=="object"?JSON.stringify(r):String(r),m=r=>r.oldValue===void 0?"added":r.newValue===void 0?"removed":"modified";return e.jsxs("div",{className:t("bg-card border border-border rounded-lg shadow-sm",i),children:[e.jsx("div",{className:"px-4 py-3 border-b border-border bg-muted",children:e.jsxs("h3",{className:"text-lg font-semibold text-card-foreground flex items-center",children:[e.jsx(n,{className:"w-5 h-5 mr-2"}),a," (",s.length,")"]})}),e.jsx("div",{className:"divide-y divide-border",children:s.map((r,l)=>{const d=m(r),c=d==="added"?b:d==="removed"?g:n,x=t("text-xs px-2 py-1 rounded-full bg-opacity-10",d==="added"&&"text-green-600 bg-green-100",d==="removed"&&"text-destructive bg-destructive/20",d==="modified"&&"text-primary bg-primary/20"),u=d==="added"?"text-green-600":d==="removed"?"text-destructive":"text-primary";return e.jsxs("div",{className:"p-4 hover:bg-muted/50 transition-colors",children:[e.jsxs("div",{className:"flex items-center justify-between mb-2",children:[e.jsxs("div",{className:"flex items-center",children:[p.createElement(c,{className:t("w-4 h-4 mr-2",u)}),e.jsx("span",{className:"font-medium text-card-foreground",children:r.field})]}),e.jsx("span",{className:x,children:d==="added"?"Added":d==="removed"?"Removed":"Updated"})]}),e.jsxs("div",{className:"grid grid-cols-1 md:grid-cols-2 gap-3 text-sm",children:[d!=="added"&&e.jsxs("div",{className:"p-2 bg-destructive/10 border border-destructive/20 rounded",children:[e.jsx("div",{className:"text-xs text-destructive font-medium mb-1",children:"Old:"}),e.jsx("div",{className:"text-destructive-foreground font-mono break-words",children:o(r.oldValue)})]}),d!=="removed"&&e.jsxs("div",{className:"p-2 bg-green-50 border border-green-100 rounded",children:[e.jsx("div",{className:"text-xs text-green-600 font-medium mb-1",children:"New:"}),e.jsx("div",{className:"text-green-800 font-mono break-words",children:o(r.newValue)})]})]}),d==="modified"&&e.jsxs("div",{className:"mt-2 flex items-center text-xs text-muted-foreground",children:[e.jsx(v,{className:"w-3 h-3 mr-1"}),"changed type: ",r.type]})]},l)})})]})};export{N as D};
@@ -0,0 +1 @@
1
+ import{u as t,j as o}from"./app.js";import{A as m}from"./app-layout-CbRvDFF3.js";import p from"./add-form-BdmoVC_G.js";import"./jsoneditor-De1FvcYu.js";import"./handsontable-PxYdjN8c.js";import"./monaco-BhBYtg3d.js";import"./app-shell-DbPu3ZPM.js";import"./app-sidebar-CQqvkGH0.js";import"./nav-main-DcvkRp44.js";import"./material-icon-BXxpxGAd.js";import"./app-sidebar-header-C8sntqs3.js";import"./breadcrumbs-Df-vVsyM.js";import"./nav-user-PtK5V1sV.js";import"./user-info-BTJNUzpi.js";import"./user-menu-content-DUnYpt8t.js";import"./theme-switcher-Ca0SixmO.js";import"./icon-BTIjB9Wk.js";import"./field-renderer-C1uKgcGe.js";import"./dynamic-controls-k61T9W2P.js";import"./input-error-CSrUHo1P.js";import"./DiffViewer-B36sF5l-.js";const i=[];function k(){const r=t();return o.jsx(m,{breadcrumbs:i,children:o.jsx(p,{page:r,catalog:!1})})}export{k as default};
@@ -1 +1 @@
1
- import{u as se,j as e,a4 as te,a5 as re,a6 as E,a7 as D,a8 as ae,a9 as k,L,B as C,aa as ne,ab as ie,ac as oe,ad as le,ae as ce,h as H,D as de,i as ue,k as me,l as pe,ai as he,bF as U,ah as xe,aR as fe,bG as _,bH as K,g as q,b as $,K as ge,M as je,N as ve,aS as ye,O as be,m as we}from"./app.js";import{r as c}from"./handsontable-PxYdjN8c.js";import{Icon as Q}from"./icon-FyVrxiPs.js";import{F as X}from"./field-renderer-Ddc4u-gC.js";import G from"./input-error-cgnQ235Q.js";import{D as Ne}from"./DiffViewer-DL5uCv8d.js";import"./jsoneditor-De1FvcYu.js";import"./monaco-BhBYtg3d.js";import"./dynamic-controls-k61T9W2P.js";var z=new Map,T=new WeakMap,J=0,Se=void 0;function ke(s){return s?(T.has(s)||(J+=1,T.set(s,J.toString())),T.get(s)):"0"}function Ce(s){return Object.keys(s).sort().filter(r=>s[r]!==void 0).map(r=>`${r}_${r==="root"?ke(s.root):s[r]}`).toString()}function De(s){const r=Ce(s);let n=z.get(r);if(!n){const l=new Map;let x;const u=new IntersectionObserver(d=>{d.forEach(i=>{var p;const b=i.isIntersecting&&x.some(m=>i.intersectionRatio>=m);s.trackVisibility&&typeof i.isVisible>"u"&&(i.isVisible=b),(p=l.get(i.target))==null||p.forEach(m=>{m(b,i)})})},s);x=u.thresholds||(Array.isArray(s.threshold)?s.threshold:[s.threshold||0]),n={id:r,observer:u,elements:l},z.set(r,n)}return n}function Fe(s,r,n={},l=Se){if(typeof window.IntersectionObserver>"u"&&l!==void 0){const p=s.getBoundingClientRect();return r(l,{isIntersecting:l,target:s,intersectionRatio:typeof n.threshold=="number"?n.threshold:0,time:0,boundingClientRect:p,intersectionRect:p,rootBounds:p}),()=>{}}const{id:x,observer:u,elements:d}=De(n),i=d.get(s)||[];return d.has(s)||d.set(s,i),i.push(r),u.observe(s),function(){i.splice(i.indexOf(r),1),i.length===0&&(d.delete(s),u.unobserve(s)),d.size===0&&(u.disconnect(),z.delete(x))}}function Ie({threshold:s,delay:r,trackVisibility:n,rootMargin:l,root:x,triggerOnce:u,skip:d,initialInView:i,fallbackInView:p,onChange:b}={}){var m;const[v,N]=c.useState(null),f=c.useRef(b),[S,h]=c.useState({inView:!!i,entry:void 0});f.current=b,c.useEffect(()=>{if(d||!v)return;let g;return g=Fe(v,(F,y)=>{h({inView:F,entry:y}),f.current&&f.current(F,y),y.isIntersecting&&u&&g&&(g(),g=void 0)},{root:x,rootMargin:l,threshold:s,trackVisibility:n,delay:r},p),()=>{g&&g()}},[Array.isArray(s)?s.toString():s,v,x,l,u,d,n,p,r]);const a=(m=S.entry)==null?void 0:m.target,o=c.useRef(void 0);!v&&a&&!u&&!d&&o.current!==a&&(o.current=a,h({inView:!!i,entry:void 0}));const w=[N,S.inView,S.entry];return w.ref=w[0],w.inView=w[1],w.entry=w[2],w}const Ee=({modelName:s,modelId:r,handleWatchHistory:n})=>{const[l,x]=c.useState([]),[u,d]=c.useState(!1),[i,p]=c.useState(null),[b,m]=c.useState(!0),v=se(),N="currentHistoryView",f=v.props.historyTableMessages;c.useEffect(()=>{(async()=>{m(!0);try{const o=await H.post(`${window.routePrefix}/history/get-model-history`,{modelName:s,modelId:r});o.data.data&&x(o.data.data)}catch(o){console.log(o)}finally{m(!1)}})()},[s,r]);const S=async a=>{try{const o=await H.post(`${window.routePrefix}/history/get-model-fields`,{historyId:a});o.data.data&&(localStorage.setItem(N,a.toString()),n(o.data.data))}catch(o){console.log(o)}},h=a=>{const o=localStorage.getItem(N);return o?o===a.id.toString():a.isCurrent};return e.jsx("div",{className:"relative h-full",children:e.jsxs("div",{className:"h-full overflow-y-auto mt-5 pr-5",children:[e.jsxs(te,{wrapperHeight:"max-h-full",children:[e.jsx(re,{className:"sticky top-0 bg-background shadow",children:e.jsxs(E,{children:[e.jsx(D,{className:"p-2 text-left",children:f.Date}),e.jsx(D,{className:"p-2 text-left",children:f.Event}),e.jsx(D,{className:"p-2 text-left",children:f.User}),e.jsx(D,{className:"p-2 text-left",children:"Diff"}),e.jsx(D,{className:"p-2 text-left"})]})}),e.jsx(ae,{children:b?e.jsx(E,{children:e.jsx(k,{colSpan:5,className:"p-10 text-center",children:e.jsx(L,{className:"mx-auto size-8 animate-spin"})})}):l.length>0?l.map(a=>e.jsxs(E,{children:[e.jsx(k,{className:"p-2 self-start pt-2.5",children:new Date(a.createdAt).toLocaleString()}),e.jsx(k,{className:"p-2 self-start pt-2.5 capitalize",children:a.action}),e.jsx(k,{className:"p-2 self-start pt-2.5 max-w-[250px] whitespace-break-spaces",children:e.jsx("div",{className:"max-w-[500px] whitespace-break-spaces font-medium text-chart-3",children:a.user.login})}),e.jsx(k,{className:"p-2 align-middle",children:e.jsx(C,{variant:"green",size:"sm",onClick:()=>{p(a.diff),d(!0)},children:e.jsx(ne,{})})}),e.jsx(k,{className:"p-2 align-middle text-center",children:h(a)?e.jsx("span",{className:"font-medium",children:f.Current}):e.jsx(C,{variant:"outline",size:"sm",onClick:()=>S(a.id),children:f.Watch})})]},a.id)):e.jsx(E,{children:e.jsx(k,{colSpan:5,className:"p-4 text-center font-medium text-muted-foreground",children:f["There is no history"]})})})]}),e.jsx(ie,{open:u,onOpenChange:a=>{d(a),a||setTimeout(()=>{document.body.removeAttribute("style")},300)},children:e.jsxs(oe,{className:"z-[1022] sm:max-w-[60vw]",children:[e.jsx(le,{children:e.jsx(ce,{children:"Diff"})}),e.jsx(Ne,{changes:i,className:"max-h-[80vh] overflow-auto sm:max-w-[60vw] w-full"})]})})]})})},Te=({dialogRef:s,modelId:r,modelName:n,callback:l})=>e.jsxs(de,{ref:s,children:[e.jsx(ue,{}),e.jsx(me,{children:e.jsx(pe,{children:e.jsx(Ee,{modelId:r,modelName:n,handleWatchHistory:l})})})]}),W=c.memo(({field:s})=>!s||typeof s!="object"||!s.label?(console.error("Invalid field for LabelRenderer:",s),null):e.jsxs("div",{className:"flex gap-3",children:[e.jsx($,{htmlFor:`${s.type}-${s.name}`,children:s.label}),s.tooltip&&e.jsx(ge,{children:e.jsxs(je,{children:[e.jsx(ve,{onClick:r=>r.preventDefault(),children:e.jsx(Q,{iconNode:ye,className:"text-primary w-5 h-5 cursor-pointer"})}),e.jsx(be,{align:"center",side:"top",className:"z-1002",children:e.jsx("p",{children:s.tooltip})})]})})]})),Re=c.memo(({field:s,value:r,onChange:n,processing:l,notFound:x,search:u})=>{if(!s||typeof s!="object"||!s.name||!s.type)return console.error("Invalid field for LazyField:",s),e.jsx("div",{className:"text-red-500",children:"Error: Invalid field data"});const[d,i]=Ie({triggerOnce:!0,rootMargin:"100px 0px"});return e.jsx("div",{ref:d,className:"grid gap-4 w-full",children:i?e.jsx(X,{field:s,value:r,onChange:n,notFound:x,search:u,processing:l}):e.jsx(we,{className:"w-full h-[250px] rounded-sm"})})}),Me=({page:s,catalog:r,callback:n,openNewWindow:l,openNewWindowLabel:x,isNavigation:u,DnavVisible:d,visibleLable:i})=>{var M;const{btnBack:p,btnHistory:b,view:m,edit:v,history:N,notFound:f,model:S,fields:h}=s.props,{data:a,setData:o,post:w,processing:g,transform:F}=he({...Object.fromEntries((h||[]).map(t=>[t.name,t.value??void 0])),jsonPopupCatalog:r}),[y,Y]=c.useState(!1),[B,O]=c.useState(l??!1),[V,Z]=c.useState(d??!1),R=c.useRef(null);c.useEffect(()=>{localStorage.removeItem("currentHistoryView")},[]),c.useEffect(()=>(O(l??!1),U(),o({...Object.fromEntries((h||[]).map(t=>[t.name,(t.type==="mediamanager"||t.type==="single-file")&&(t.value===null||t.value===void 0)?[]:t.value])),jsonPopupCatalog:r}),()=>U()),[h,r,l,o]);const A=c.useCallback((t,j)=>{o(t,j)},[o]);if(!Array.isArray(h))return console.error("Fields is not an array:",h),e.jsx("div",{className:"p-4 text-red-500",children:"Error: Fields data is invalid"});if(h.length===0)return console.warn("Fields array is empty"),e.jsx("div",{className:"p-4 text-gray-500",children:"No fields to display"});const P=h.filter(t=>!t||typeof t!="object"||!t.name||!t.type||!t.label);if(P.length>0)return console.error("Invalid fields found:",P),e.jsx("div",{className:"p-4 text-red-500",children:"Error: Some fields are missing required properties (name, type, label)"});const ee=async t=>{if(t.preventDefault(),r){Y(!0);const j=await H.post(s.props.postLink,a);j.status===200&&n&&(u?n(j.data.record,B,V):n(j.data.record))}else{const j=localStorage.getItem("backUrl");F(I=>({...I,redirectUrl:j??""})),w(s.props.postLink,{onSuccess:()=>{localStorage.setItem("backUrl","")}})}};return e.jsxs("div",{className:"p-4 w-full",children:[!r&&e.jsxs("div",{className:"w-full sticky z-[1001] py-4 pb-8 top-0 h-fit bg-background flex gap-4",children:[e.jsx(C,{className:"w-fit",asChild:!0,children:e.jsxs(xe,{href:p.link,preserveScroll:!0,children:[e.jsx(Q,{iconNode:fe}),p.title]})}),e.jsxs(C,{variant:"green",type:"submit",className:"w-fit lg:hidden",form:"addUserForm",disabled:y||g||s.props.view||_(),children:[y||g&&e.jsx(L,{className:"h-4 w-4 animate-spin"}),s.props.btnSave.title]})]}),e.jsx("form",{id:"addUserForm",onSubmit:ee,className:m?"cursor-not-allowed":"",children:e.jsxs("div",{className:"grid gap-4 max-w-286 pb-8 lg:grid-cols-[1fr_220px]",children:[e.jsx("div",{className:"flex flex-col gap-10",children:h.map(t=>e.jsx("div",{className:`grid gap-4 w-full ${m?"pointer-events-none":""}`,children:t.type==="markdown"||t.type==="table"||t.type==="jsonEditor"||t.type==="codeEditor"||t.type==="geoJson"?e.jsxs(e.Fragment,{children:[e.jsx(W,{field:t}),e.jsx(G,{message:K(`${t.type}-${t.name}`)}),e.jsx(Re,{field:t,value:a[t.name],onChange:A,processing:y||g||m,notFound:f,search:s.props.search})]}):e.jsxs(e.Fragment,{children:[e.jsx(W,{field:t}),e.jsx(G,{message:K(`${t.type}-${t.name}`)}),e.jsx(X,{field:t,value:a[t.name],onChange:A,processing:y||g||m,notFound:f,search:s.props.search})]})},t.name))}),e.jsxs("div",{className:`p-4 rounded-md h-fit sticky shadow ${r?"top-0 grid gap-4":"top-[84px] hidden lg:block"}`,children:[u&&e.jsxs(e.Fragment,{children:[e.jsxs("div",{className:"flex gap-4 items-center",children:[e.jsx(q,{id:"targetBlank",checked:B,onCheckedChange:t=>O(!!t),className:"cursor-pointer size-5"}),e.jsx($,{htmlFor:"targetBlank",children:x})]}),e.jsxs("div",{className:"flex gap-4 items-center",children:[e.jsx(q,{id:"visible",checked:V,onCheckedChange:t=>Z(!!t),className:"cursor-pointer size-5"}),e.jsx($,{htmlFor:"visible",children:i})]})]}),e.jsxs("div",{className:`flex gap-2 ${N&&(v||m)?"justify-center":"justify-start"}`,children:[e.jsxs(C,{variant:"green",type:"submit",className:"w-fit",disabled:y||g||s.props.view||_(),children:[(y||g)&&e.jsx(L,{className:"h-4 w-4 animate-spin"}),s.props.btnSave.title]}),N&&(v||m)&&e.jsx(C,{variant:"outline",className:"w-fit",onClick:t=>{var j;t.preventDefault(),(j=R.current)==null||j.open()},children:b.title})]})]})]})}),N&&(v||m)&&e.jsx(Te,{dialogRef:R,modelName:S,modelId:(M=h.find(t=>t.name==="id"))==null?void 0:M.value,callback:t=>{var j;for(const I of Object.keys(t))o(I,t[I]);(j=R.current)==null||j.close()}})]})};export{W as LabelRenderer,Re as LazyField,Me as default};
1
+ import{u as se,j as e,a5 as te,a6 as re,a7 as E,a8 as D,a9 as ae,aa as k,L,B as C,ab as ne,ac as ie,ad as oe,ae as le,af as ce,h as H,D as de,i as ue,k as me,l as pe,aj as he,bG as U,ai as xe,aS as fe,bH as _,bI as q,g as G,b as $,M as ge,N as je,O as ve,aT as ye,Q as be,m as we}from"./app.js";import{r as c}from"./handsontable-PxYdjN8c.js";import{Icon as W}from"./icon-BTIjB9Wk.js";import{F as X}from"./field-renderer-C1uKgcGe.js";import J from"./input-error-CSrUHo1P.js";import{D as Ne}from"./DiffViewer-B36sF5l-.js";import"./jsoneditor-De1FvcYu.js";import"./monaco-BhBYtg3d.js";import"./dynamic-controls-k61T9W2P.js";var z=new Map,T=new WeakMap,K=0,Se=void 0;function ke(s){return s?(T.has(s)||(K+=1,T.set(s,K.toString())),T.get(s)):"0"}function Ce(s){return Object.keys(s).sort().filter(r=>s[r]!==void 0).map(r=>`${r}_${r==="root"?ke(s.root):s[r]}`).toString()}function De(s){const r=Ce(s);let n=z.get(r);if(!n){const l=new Map;let x;const u=new IntersectionObserver(d=>{d.forEach(i=>{var p;const b=i.isIntersecting&&x.some(m=>i.intersectionRatio>=m);s.trackVisibility&&typeof i.isVisible>"u"&&(i.isVisible=b),(p=l.get(i.target))==null||p.forEach(m=>{m(b,i)})})},s);x=u.thresholds||(Array.isArray(s.threshold)?s.threshold:[s.threshold||0]),n={id:r,observer:u,elements:l},z.set(r,n)}return n}function Fe(s,r,n={},l=Se){if(typeof window.IntersectionObserver>"u"&&l!==void 0){const p=s.getBoundingClientRect();return r(l,{isIntersecting:l,target:s,intersectionRatio:typeof n.threshold=="number"?n.threshold:0,time:0,boundingClientRect:p,intersectionRect:p,rootBounds:p}),()=>{}}const{id:x,observer:u,elements:d}=De(n),i=d.get(s)||[];return d.has(s)||d.set(s,i),i.push(r),u.observe(s),function(){i.splice(i.indexOf(r),1),i.length===0&&(d.delete(s),u.unobserve(s)),d.size===0&&(u.disconnect(),z.delete(x))}}function Ie({threshold:s,delay:r,trackVisibility:n,rootMargin:l,root:x,triggerOnce:u,skip:d,initialInView:i,fallbackInView:p,onChange:b}={}){var m;const[v,N]=c.useState(null),f=c.useRef(b),[S,h]=c.useState({inView:!!i,entry:void 0});f.current=b,c.useEffect(()=>{if(d||!v)return;let g;return g=Fe(v,(F,y)=>{h({inView:F,entry:y}),f.current&&f.current(F,y),y.isIntersecting&&u&&g&&(g(),g=void 0)},{root:x,rootMargin:l,threshold:s,trackVisibility:n,delay:r},p),()=>{g&&g()}},[Array.isArray(s)?s.toString():s,v,x,l,u,d,n,p,r]);const a=(m=S.entry)==null?void 0:m.target,o=c.useRef(void 0);!v&&a&&!u&&!d&&o.current!==a&&(o.current=a,h({inView:!!i,entry:void 0}));const w=[N,S.inView,S.entry];return w.ref=w[0],w.inView=w[1],w.entry=w[2],w}const Ee=({modelName:s,modelId:r,handleWatchHistory:n})=>{const[l,x]=c.useState([]),[u,d]=c.useState(!1),[i,p]=c.useState(null),[b,m]=c.useState(!0),v=se(),N="currentHistoryView",f=v.props.historyTableMessages;c.useEffect(()=>{(async()=>{m(!0);try{const o=await H.post(`${window.routePrefix}/history/get-model-history`,{modelName:s,modelId:r});o.data.data&&x(o.data.data)}catch(o){console.log(o)}finally{m(!1)}})()},[s,r]);const S=async a=>{try{const o=await H.post(`${window.routePrefix}/history/get-model-fields`,{historyId:a});o.data.data&&(localStorage.setItem(N,a.toString()),n(o.data.data))}catch(o){console.log(o)}},h=a=>{const o=localStorage.getItem(N);return o?o===a.id.toString():a.isCurrent};return e.jsx("div",{className:"relative h-full",children:e.jsxs("div",{className:"h-full overflow-y-auto mt-5 pr-5",children:[e.jsxs(te,{wrapperHeight:"max-h-full",children:[e.jsx(re,{className:"sticky top-0 bg-background shadow",children:e.jsxs(E,{children:[e.jsx(D,{className:"p-2 text-left",children:f.Date}),e.jsx(D,{className:"p-2 text-left",children:f.Event}),e.jsx(D,{className:"p-2 text-left",children:f.User}),e.jsx(D,{className:"p-2 text-left",children:"Diff"}),e.jsx(D,{className:"p-2 text-left"})]})}),e.jsx(ae,{children:b?e.jsx(E,{children:e.jsx(k,{colSpan:5,className:"p-10 text-center",children:e.jsx(L,{className:"mx-auto size-8 animate-spin"})})}):l.length>0?l.map(a=>e.jsxs(E,{children:[e.jsx(k,{className:"p-2 self-start pt-2.5",children:new Date(a.createdAt).toLocaleString()}),e.jsx(k,{className:"p-2 self-start pt-2.5 capitalize",children:a.action}),e.jsx(k,{className:"p-2 self-start pt-2.5 max-w-[250px] whitespace-break-spaces",children:e.jsx("div",{className:"max-w-[500px] whitespace-break-spaces font-medium text-chart-3",children:a.user.login})}),e.jsx(k,{className:"p-2 align-middle",children:e.jsx(C,{variant:"green",size:"sm",onClick:()=>{p(a.diff),d(!0)},children:e.jsx(ne,{})})}),e.jsx(k,{className:"p-2 align-middle text-center",children:h(a)?e.jsx("span",{className:"font-medium",children:f.Current}):e.jsx(C,{variant:"outline",size:"sm",onClick:()=>S(a.id),children:f.Watch})})]},a.id)):e.jsx(E,{children:e.jsx(k,{colSpan:5,className:"p-4 text-center font-medium text-muted-foreground",children:f["There is no history"]})})})]}),e.jsx(ie,{open:u,onOpenChange:a=>{d(a),a||setTimeout(()=>{document.body.removeAttribute("style")},300)},children:e.jsxs(oe,{className:"z-[1022] sm:max-w-[60vw]",children:[e.jsx(le,{children:e.jsx(ce,{children:"Diff"})}),e.jsx(Ne,{changes:i,className:"max-h-[80vh] overflow-auto sm:max-w-[60vw] w-full"})]})})]})})},Te=({dialogRef:s,modelId:r,modelName:n,callback:l})=>e.jsxs(de,{ref:s,children:[e.jsx(ue,{}),e.jsx(me,{children:e.jsx(pe,{children:e.jsx(Ee,{modelId:r,modelName:n,handleWatchHistory:l})})})]}),Q=c.memo(({field:s})=>!s||typeof s!="object"||!s.label?(console.error("Invalid field for LabelRenderer:",s),null):e.jsxs("div",{className:"flex gap-3",children:[e.jsx($,{htmlFor:`${s.type}-${s.name}`,children:s.label}),s.tooltip&&e.jsx(ge,{children:e.jsxs(je,{children:[e.jsx(ve,{onClick:r=>r.preventDefault(),children:e.jsx(W,{iconNode:ye,className:"text-primary w-5 h-5 cursor-pointer"})}),e.jsx(be,{align:"center",side:"top",className:"z-1002",children:e.jsx("p",{children:s.tooltip})})]})})]})),Re=c.memo(({field:s,value:r,onChange:n,processing:l,notFound:x,search:u})=>{if(!s||typeof s!="object"||!s.name||!s.type)return console.error("Invalid field for LazyField:",s),e.jsx("div",{className:"text-red-500",children:"Error: Invalid field data"});const[d,i]=Ie({triggerOnce:!0,rootMargin:"100px 0px"});return e.jsx("div",{ref:d,className:"grid gap-4 w-full",children:i?e.jsx(X,{field:s,value:r,onChange:n,notFound:x,search:u,processing:l}):e.jsx(we,{className:"w-full h-[250px] rounded-sm"})})}),Me=({page:s,catalog:r,callback:n,openNewWindow:l,openNewWindowLabel:x,isNavigation:u,DnavVisible:d,visibleLable:i})=>{var M;const{btnBack:p,btnHistory:b,view:m,edit:v,history:N,notFound:f,model:S,fields:h}=s.props,{data:a,setData:o,post:w,processing:g,transform:F}=he({...Object.fromEntries((h||[]).map(t=>[t.name,t.value??void 0])),jsonPopupCatalog:r}),[y,Y]=c.useState(!1),[B,O]=c.useState(l??!1),[V,Z]=c.useState(d??!1),R=c.useRef(null);c.useEffect(()=>{localStorage.removeItem("currentHistoryView")},[]),c.useEffect(()=>(O(l??!1),U(),o({...Object.fromEntries((h||[]).map(t=>[t.name,(t.type==="mediamanager"||t.type==="single-file")&&(t.value===null||t.value===void 0)?[]:t.value])),jsonPopupCatalog:r}),()=>U()),[h,r,l,o]);const A=c.useCallback((t,j)=>{o(t,j)},[o]);if(!Array.isArray(h))return console.error("Fields is not an array:",h),e.jsx("div",{className:"p-4 text-red-500",children:"Error: Fields data is invalid"});if(h.length===0)return console.warn("Fields array is empty"),e.jsx("div",{className:"p-4 text-gray-500",children:"No fields to display"});const P=h.filter(t=>!t||typeof t!="object"||!t.name||!t.type||!t.label);if(P.length>0)return console.error("Invalid fields found:",P),e.jsx("div",{className:"p-4 text-red-500",children:"Error: Some fields are missing required properties (name, type, label)"});const ee=async t=>{if(t.preventDefault(),r){Y(!0);const j=await H.post(s.props.postLink,a);j.status===200&&n&&(u?n(j.data.record,B,V):n(j.data.record))}else{const j=localStorage.getItem("backUrl");F(I=>({...I,redirectUrl:j??""})),w(s.props.postLink,{onSuccess:()=>{localStorage.setItem("backUrl","")}})}};return e.jsxs("div",{className:"p-4 w-full",children:[!r&&e.jsxs("div",{className:"w-full sticky z-[1001] py-4 pb-8 top-0 h-fit bg-background flex gap-4",children:[e.jsx(C,{className:"w-fit",asChild:!0,children:e.jsxs(xe,{href:p.link,preserveScroll:!0,children:[e.jsx(W,{iconNode:fe}),p.title]})}),e.jsxs(C,{variant:"green",type:"submit",className:"w-fit lg:hidden",form:"addUserForm",disabled:y||g||s.props.view||_(),children:[y||g&&e.jsx(L,{className:"h-4 w-4 animate-spin"}),s.props.btnSave.title]})]}),e.jsx("form",{id:"addUserForm",onSubmit:ee,className:m?"cursor-not-allowed":"",children:e.jsxs("div",{className:"grid gap-4 max-w-286 pb-8 lg:grid-cols-[1fr_220px]",children:[e.jsx("div",{className:"flex flex-col gap-10",children:h.map(t=>e.jsx("div",{className:`grid gap-4 w-full ${m?"pointer-events-none":""}`,children:t.type==="markdown"||t.type==="table"||t.type==="jsonEditor"||t.type==="codeEditor"||t.type==="geoJson"?e.jsxs(e.Fragment,{children:[e.jsx(Q,{field:t}),e.jsx(J,{message:q(`${t.type}-${t.name}`)}),e.jsx(Re,{field:t,value:a[t.name],onChange:A,processing:y||g||m,notFound:f,search:s.props.search})]}):e.jsxs(e.Fragment,{children:[e.jsx(Q,{field:t}),e.jsx(J,{message:q(`${t.type}-${t.name}`)}),e.jsx(X,{field:t,value:a[t.name],onChange:A,processing:y||g||m,notFound:f,search:s.props.search})]})},t.name))}),e.jsxs("div",{className:`p-4 rounded-md h-fit sticky shadow ${r?"top-0 grid gap-4":"top-[84px] hidden lg:block"}`,children:[u&&e.jsxs(e.Fragment,{children:[e.jsxs("div",{className:"flex gap-4 items-center",children:[e.jsx(G,{id:"targetBlank",checked:B,onCheckedChange:t=>O(!!t),className:"cursor-pointer size-5"}),e.jsx($,{htmlFor:"targetBlank",children:x})]}),e.jsxs("div",{className:"flex gap-4 items-center",children:[e.jsx(G,{id:"visible",checked:V,onCheckedChange:t=>Z(!!t),className:"cursor-pointer size-5"}),e.jsx($,{htmlFor:"visible",children:i})]})]}),e.jsxs("div",{className:`flex gap-2 ${N&&(v||m)?"justify-center":"justify-start"}`,children:[e.jsxs(C,{variant:"green",type:"submit",className:"w-fit",disabled:y||g||s.props.view||_(),children:[(y||g)&&e.jsx(L,{className:"h-4 w-4 animate-spin"}),s.props.btnSave.title]}),N&&(v||m)&&e.jsx(C,{variant:"outline",className:"w-fit",onClick:t=>{var j;t.preventDefault(),(j=R.current)==null||j.open()},children:b.title})]})]})]})}),N&&(v||m)&&e.jsx(Te,{dialogRef:R,modelName:S,modelId:(M=h.find(t=>t.name==="id"))==null?void 0:M.value,callback:t=>{var j;for(const I of Object.keys(t))o(I,t[I]);(j=R.current)==null||j.close()}})]})};export{Q as LabelRenderer,Re as LazyField,Me as default};
@@ -0,0 +1 @@
1
+ import{j as r}from"./app.js";import{A as o}from"./app-layout-CbRvDFF3.js";import t from"./add-group-form-B7c4coU-.js";import"./jsoneditor-De1FvcYu.js";import"./handsontable-PxYdjN8c.js";import"./monaco-BhBYtg3d.js";import"./app-shell-DbPu3ZPM.js";import"./app-sidebar-CQqvkGH0.js";import"./nav-main-DcvkRp44.js";import"./material-icon-BXxpxGAd.js";import"./app-sidebar-header-C8sntqs3.js";import"./breadcrumbs-Df-vVsyM.js";import"./nav-user-PtK5V1sV.js";import"./user-info-BTJNUzpi.js";import"./user-menu-content-DUnYpt8t.js";import"./theme-switcher-Ca0SixmO.js";import"./icon-BTIjB9Wk.js";const m=[];function y(){return r.jsx(o,{breadcrumbs:m,children:r.jsx(t,{})})}export{y as default};
@@ -1 +1 @@
1
- import{u as D,ai as O,j as e,B as T,ah as M,aR as S,L as q,b as x,I as y,g as z,K as P,M as R,N as U,aS as A,O as G}from"./app.js";import{Icon as I}from"./icon-FyVrxiPs.js";import{r as h}from"./handsontable-PxYdjN8c.js";import"./jsoneditor-De1FvcYu.js";import"./monaco-BhBYtg3d.js";const E=h.memo(({field:s,disabled:d,value:c,onCheckedChange:i,tooltip:t})=>{const m=h.useCallback(l=>{i(s.name,l)},[s.name,i]);return e.jsxs("div",{className:"flex gap-3 items-center",children:[e.jsx(z,{id:s.name,className:"cursor-pointer size-5",disabled:d,checked:c,onCheckedChange:m}),e.jsxs("div",{className:"flex gap-3",children:[e.jsx(x,{className:"cursor-pointer",htmlFor:s.name,children:s.label}),t&&e.jsx(P,{children:e.jsxs(R,{children:[e.jsx(U,{onClick:l=>l.preventDefault(),children:e.jsx(I,{iconNode:A,className:"text-primary w-5 h-5 cursor-pointer"})}),e.jsx(G,{align:"center",side:"top",children:e.jsx("p",{children:s.tooltip})})]})})]})]})});function Q(){var u,g,j,b,v,f,N,k,C,w,F;const s=D(),{fields:d,groupedTokens:c,users:i}=s.props,{data:t,setData:m,clearErrors:l,post:L,processing:o}=O({...Object.fromEntries(d.map(a=>[a.name,a.value])),...Object.fromEntries(i.map(a=>[a.name,a.value])),...Object.fromEntries(c.flatMap(a=>a.fields.map(n=>[n.name,n.value])))}),r=a=>s.props.fields.find(n=>n.name===a),p=h.useCallback((a,n)=>{l(),m(a,n)},[]),B=a=>{a.preventDefault(),L(s.props.postLink)};return e.jsxs("div",{className:"flex h-full flex-1 flex-col gap-4 rounded-xl p-4",children:[e.jsxs("div",{className:"w-full sticky z-[1001] py-4 pb-8 top-0 h-fit bg-background flex gap-4",children:[e.jsx(T,{className:"mb-3 w-fit",asChild:!0,children:e.jsxs(M,{href:s.props.btnBack.link,children:[e.jsx(I,{iconNode:S}),s.props.btnBack.title]})}),e.jsxs(T,{variant:"green",type:"submit",className:"w-fit",form:"addUserForm",disabled:o||s.props.view,children:[o&&e.jsx(q,{className:"h-4 w-4 animate-spin"}),s.props.btnSave.title]})]}),e.jsx("form",{id:"addUserForm",onSubmit:B,className:`${s.props.view?"cursor-not-allowed":""}`,children:e.jsxs("div",{className:"flex flex-col gap-6 max-w-[1144px]",children:[e.jsx("h2",{className:"font-bold text-xl",children:s.props.head}),e.jsxs("div",{className:"grid gap-4",children:[e.jsx(x,{htmlFor:(u=r("name"))==null?void 0:u.name,children:(g=r("name"))==null?void 0:g.label}),e.jsx(y,{id:(j=r("name"))==null?void 0:j.name,type:"text",required:!0,tabIndex:1,autoComplete:(b=r("name"))==null?void 0:b.name,value:t.name,onChange:a=>p("name",a.target.value),disabled:o||s.props.view,placeholder:(v=r("name"))==null?void 0:v.label})]}),e.jsxs("div",{className:"grid gap-4",children:[e.jsx(x,{htmlFor:(f=r("description"))==null?void 0:f.name,children:(N=r("description"))==null?void 0:N.label}),e.jsx(y,{id:(k=r("description"))==null?void 0:k.name,type:"text",required:!0,tabIndex:1,autoComplete:(C=r("description"))==null?void 0:C.name,value:t.description,onChange:a=>p("description",a.target.value),disabled:o||s.props.view,placeholder:(w=r("description"))==null?void 0:w.label})]}),s.props.users.length>0&&e.jsxs(e.Fragment,{children:[e.jsx("h2",{className:"font-bold text-xl",children:s.props.userHead}),s.props.users.map(a=>e.jsx(E,{field:a,disabled:o||s.props.view,value:t[a.name],onCheckedChange:p},a.name))]}),e.jsx("div",{className:"grid grid-cols-1 md:grid-cols-3 xl:grid-cols-4 gap-4",children:((F=s.props.groupedTokens)==null?void 0:F.length)>0&&s.props.groupedTokens.map(a=>e.jsxs("div",{className:"grid gap-4 content-start justify-between",children:[e.jsx("h2",{className:"font-bold text-xl mt-3",children:a.header}),a.fields.map(n=>e.jsx(E,{field:n,disabled:o||s.props.view,value:t[n.name],onCheckedChange:p,tooltip:!0},n.name))]},a.header))})]})})]})}export{Q as default};
1
+ import{u as D,aj as O,j as e,B as T,ai as M,aS as S,L as q,b as x,I as y,g as z,M as P,N as U,O as A,aT as G,Q as H}from"./app.js";import{Icon as I}from"./icon-BTIjB9Wk.js";import{r as h}from"./handsontable-PxYdjN8c.js";import"./jsoneditor-De1FvcYu.js";import"./monaco-BhBYtg3d.js";const E=h.memo(({field:s,disabled:d,value:c,onCheckedChange:i,tooltip:t})=>{const m=h.useCallback(l=>{i(s.name,l)},[s.name,i]);return e.jsxs("div",{className:"flex gap-3 items-center",children:[e.jsx(z,{id:s.name,className:"cursor-pointer size-5",disabled:d,checked:c,onCheckedChange:m}),e.jsxs("div",{className:"flex gap-3",children:[e.jsx(x,{className:"cursor-pointer",htmlFor:s.name,children:s.label}),t&&e.jsx(P,{children:e.jsxs(U,{children:[e.jsx(A,{onClick:l=>l.preventDefault(),children:e.jsx(I,{iconNode:G,className:"text-primary w-5 h-5 cursor-pointer"})}),e.jsx(H,{align:"center",side:"top",children:e.jsx("p",{children:s.tooltip})})]})})]})]})});function K(){var u,j,g,b,v,f,N,k,C,w,F;const s=D(),{fields:d,groupedTokens:c,users:i}=s.props,{data:t,setData:m,clearErrors:l,post:L,processing:o}=O({...Object.fromEntries(d.map(a=>[a.name,a.value])),...Object.fromEntries(i.map(a=>[a.name,a.value])),...Object.fromEntries(c.flatMap(a=>a.fields.map(n=>[n.name,n.value])))}),r=a=>s.props.fields.find(n=>n.name===a),p=h.useCallback((a,n)=>{l(),m(a,n)},[]),B=a=>{a.preventDefault(),L(s.props.postLink)};return e.jsxs("div",{className:"flex h-full flex-1 flex-col gap-4 rounded-xl p-4",children:[e.jsxs("div",{className:"w-full sticky z-[1001] py-4 pb-8 top-0 h-fit bg-background flex gap-4",children:[e.jsx(T,{className:"mb-3 w-fit",asChild:!0,children:e.jsxs(M,{href:s.props.btnBack.link,children:[e.jsx(I,{iconNode:S}),s.props.btnBack.title]})}),e.jsxs(T,{variant:"green",type:"submit",className:"w-fit",form:"addUserForm",disabled:o||s.props.view,children:[o&&e.jsx(q,{className:"h-4 w-4 animate-spin"}),s.props.btnSave.title]})]}),e.jsx("form",{id:"addUserForm",onSubmit:B,className:`${s.props.view?"cursor-not-allowed":""}`,children:e.jsxs("div",{className:"flex flex-col gap-6 max-w-[1144px]",children:[e.jsx("h2",{className:"font-bold text-xl",children:s.props.head}),e.jsxs("div",{className:"grid gap-4",children:[e.jsx(x,{htmlFor:(u=r("name"))==null?void 0:u.name,children:(j=r("name"))==null?void 0:j.label}),e.jsx(y,{id:(g=r("name"))==null?void 0:g.name,type:"text",required:!0,tabIndex:1,autoComplete:(b=r("name"))==null?void 0:b.name,value:t.name,onChange:a=>p("name",a.target.value),disabled:o||s.props.view,placeholder:(v=r("name"))==null?void 0:v.label})]}),e.jsxs("div",{className:"grid gap-4",children:[e.jsx(x,{htmlFor:(f=r("description"))==null?void 0:f.name,children:(N=r("description"))==null?void 0:N.label}),e.jsx(y,{id:(k=r("description"))==null?void 0:k.name,type:"text",required:!0,tabIndex:1,autoComplete:(C=r("description"))==null?void 0:C.name,value:t.description,onChange:a=>p("description",a.target.value),disabled:o||s.props.view,placeholder:(w=r("description"))==null?void 0:w.label})]}),s.props.users.length>0&&e.jsxs(e.Fragment,{children:[e.jsx("h2",{className:"font-bold text-xl",children:s.props.userHead}),s.props.users.map(a=>e.jsx(E,{field:a,disabled:o||s.props.view,value:t[a.name],onCheckedChange:p},a.name))]}),e.jsx("div",{className:"grid grid-cols-1 md:grid-cols-3 xl:grid-cols-4 gap-4",children:((F=s.props.groupedTokens)==null?void 0:F.length)>0&&s.props.groupedTokens.map(a=>e.jsxs("div",{className:"grid gap-4 content-start justify-between",children:[e.jsx("h2",{className:"font-bold text-xl mt-3",children:a.header}),a.fields.map(n=>e.jsx(E,{field:n,disabled:o||s.props.view,value:t[n.name],onCheckedChange:p,tooltip:!0},n.name))]},a.header))})]})})]})}export{K as default};
@@ -0,0 +1 @@
1
+ import{j as r}from"./app.js";import{A as o}from"./app-layout-CbRvDFF3.js";import t from"./add-user-form-BXSGx38D.js";import"./jsoneditor-De1FvcYu.js";import"./handsontable-PxYdjN8c.js";import"./monaco-BhBYtg3d.js";import"./app-shell-DbPu3ZPM.js";import"./app-sidebar-CQqvkGH0.js";import"./nav-main-DcvkRp44.js";import"./material-icon-BXxpxGAd.js";import"./app-sidebar-header-C8sntqs3.js";import"./breadcrumbs-Df-vVsyM.js";import"./nav-user-PtK5V1sV.js";import"./user-info-BTJNUzpi.js";import"./user-menu-content-DUnYpt8t.js";import"./theme-switcher-Ca0SixmO.js";import"./icon-BTIjB9Wk.js";import"./input-error-CSrUHo1P.js";const m=[];function E(){return r.jsx(o,{breadcrumbs:m,children:r.jsx(t,{})})}export{E as default};
@@ -1 +1 @@
1
- import{u as he,ai as ue,j as e,B as c,ah as Q,aR as ge,L as je,b as o,I as n,S as W,c as X,d as Y,e as Z,f as ee,g as m,K as fe,M as ve,N as be,aS as we,O as Ne,h as Ce}from"./app.js";import{Icon as se}from"./icon-FyVrxiPs.js";import{r as ae}from"./handsontable-PxYdjN8c.js";import Pe from"./input-error-cgnQ235Q.js";import ke from"./material-icon-DZVU9Gse.js";import"./jsoneditor-De1FvcYu.js";import"./monaco-BhBYtg3d.js";function Te(){var p,x,h,u,g,j,f,v,b,w,N,C,P,k,F,z,y,I,U,S,E,T,A,L,q,V,B,D,M,O,R,H,K,_,$,G,J;const l=he(),[le,re]=ae.useState(),{fields:ie,groups:de,auth:oe}=l.props,{data:r,setData:te,errors:ne,setError:ce,clearErrors:me,post:pe,processing:i}=ue({...Object.fromEntries(ie.map(s=>[s.name,s.value])),...Object.fromEntries(de.map(s=>[s.name,s.value]))});ae.useEffect(()=>{(async()=>{const t=await Ce.get(`${window.routePrefix}/get-timezones`);re(t.data.timezones)})()},[]);const a=s=>l.props.fields.find(t=>t.name===s),xe=s=>{if(s.preventDefault(),r.userPassword!==r.repeatUserPassword){ce("repeatUserPassword",l.props.passwordError);return}pe(l.props.postLink)},d=(s,t)=>{me(),te(s,t)};return e.jsxs("div",{className:"flex h-full flex-1 flex-col gap-4 rounded-xl p-4",children:[e.jsxs("div",{className:"w-full sticky z-[1001] py-4 pb-8 top-0 h-fit bg-background flex gap-4",children:[e.jsx(c,{className:"mb-3 w-fit",asChild:!0,children:e.jsxs(Q,{href:l.props.btnBack.link,children:[e.jsx(se,{iconNode:ge}),l.props.btnBack.title]})}),e.jsxs(c,{variant:"green",type:"submit",className:"w-fit",form:"addUserForm",disabled:i||l.props.view,children:[i&&e.jsx(je,{className:"h-4 w-4 animate-spin"}),l.props.btnSave.title]})]}),e.jsx("form",{id:"addUserForm",onSubmit:xe,className:l.props.view?"cursor-not-allowed":"",children:e.jsxs("div",{className:"flex flex-col gap-10 max-w-[1144px]",children:[e.jsx("h2",{className:"font-bold text-xl",children:l.props.head}),e.jsxs("div",{className:"flex-col xl:flex-row flex gap-16",children:[e.jsxs("div",{className:"basis-1/2 flex flex-col gap-6",children:[e.jsxs("div",{className:"grid gap-4",children:[e.jsx(o,{htmlFor:(p=a("login"))==null?void 0:p.name,children:(x=a("login"))==null?void 0:x.label}),e.jsx(n,{id:(h=a("login"))==null?void 0:h.name,type:"text",required:!0,tabIndex:1,autoComplete:"username",value:r.login,onChange:s=>d("login",s.target.value),disabled:i||l.props.view,placeholder:(u=a("login"))==null?void 0:u.label})]}),e.jsxs("div",{className:"grid gap-4",children:[e.jsx(o,{htmlFor:(g=a("fullName"))==null?void 0:g.name,children:(j=a("fullName"))==null?void 0:j.label}),e.jsx(n,{id:(f=a("fullName"))==null?void 0:f.name,type:"text",required:!0,tabIndex:1,autoComplete:"additional-name",value:r.fullName,onChange:s=>d("fullName",s.target.value),disabled:i||l.props.view,placeholder:(v=a("fullName"))==null?void 0:v.label})]}),e.jsxs("div",{className:"grid gap-4",children:[e.jsx(o,{htmlFor:(b=a("email"))==null?void 0:b.name,children:(w=a("email"))==null?void 0:w.label}),e.jsx(n,{id:(N=a("email"))==null?void 0:N.name,type:"email",required:!0,tabIndex:1,autoComplete:"email",value:r.email,onChange:s=>d("email",s.target.value),disabled:i||l.props.view,placeholder:(C=a("email"))==null?void 0:C.label})]})]}),e.jsxs("div",{className:"basis-1/2 flex flex-col gap-6",children:[e.jsxs("div",{className:"grid gap-4",children:[e.jsx(o,{htmlFor:(P=a("timezone"))==null?void 0:P.name,children:(k=a("timezone"))==null?void 0:k.label}),e.jsxs(W,{onValueChange:s=>d("timezone",s),defaultValue:r.timezone,disabled:i||l.props.view,children:[e.jsx(X,{className:"w-full cursor-pointer",children:e.jsx(Y,{placeholder:(F=a("timezone"))==null?void 0:F.name})}),e.jsx(Z,{children:(le??[]).map(s=>e.jsx(ee,{value:s.value,children:s.label},s.value))})]})]}),e.jsxs("div",{className:"flex flex-col md:flex-row justify-start gap-4 xl:justify-between items-start md:items-center",children:[a("date")&&e.jsxs("div",{className:"grid gap-4",children:[e.jsx(o,{htmlFor:(z=a("date"))==null?void 0:z.name,children:(y=a("date"))==null?void 0:y.label}),e.jsx(n,{id:(I=a("date"))==null?void 0:I.name,type:"date",className:"max-w-fit",tabIndex:1,value:r.date,onChange:s=>d("date",s.target.value),disabled:i})]}),e.jsxs("div",{className:"flex gap-6",children:[a("isAdmin")&&e.jsxs("div",{className:"grid gap-4",children:[e.jsx(o,{className:"cursor-pointer",htmlFor:(U=a("isAdmin"))==null?void 0:U.name,children:(S=a("isAdmin"))==null?void 0:S.label}),e.jsx(m,{id:(E=a("isAdmin"))==null?void 0:E.name,className:"cursor-pointer size-5",disabled:i||l.props.view,checked:r.isAdmin,onCheckedChange:s=>d("isAdmin",s)})]}),a("isConfirmed")&&e.jsxs("div",{className:"grid gap-4",children:[e.jsx(o,{className:"cursor-pointer",htmlFor:(T=a("isConfirmed"))==null?void 0:T.name,children:(A=a("isConfirmed"))==null?void 0:A.label}),e.jsx(m,{id:(L=a("isConfirmed"))==null?void 0:L.name,className:"cursor-pointer size-5",disabled:i||l.props.view,checked:r.isConfirmed,onCheckedChange:s=>d("isConfirmed",s)})]})]})]}),a("locale")&&e.jsxs("div",{className:"grid gap-4",children:[e.jsx(o,{htmlFor:(q=a("locale"))==null?void 0:q.name,children:(V=a("locale"))==null?void 0:V.label}),e.jsxs(W,{onValueChange:s=>d("locale",s),defaultValue:r.locale,disabled:i||l.props.view,children:[e.jsx(X,{className:"w-full cursor-pointer",children:e.jsx(Y,{placeholder:(B=a("locale"))==null?void 0:B.name})}),e.jsx(Z,{children:(l.props.locales??[]).map(s=>e.jsx(ee,{value:s.value,children:s.label},s.value))})]})]})]})]}),oe.user.isAdministrator&&e.jsx(c,{className:"w-fit",asChild:!0,variant:"outline",children:e.jsxs(Q,{href:l.props.userPretend.postLink,method:"post",data:{login:r.login,pretend:!0},children:[e.jsx(ke,{name:"masks",className:"!text-[18px]"}),l.props.userPretend.label]})}),e.jsxs("div",{className:"flex gap-3",children:[e.jsx("label",{className:"font-bold text-xl",children:(D=a("userPassword"))==null?void 0:D.label}),e.jsx(fe,{children:e.jsxs(ve,{children:[e.jsx(be,{onClick:s=>s.preventDefault(),children:e.jsx(se,{iconNode:we,className:"text-primary w-5 h-5 cursor-pointer"})}),e.jsx(Ne,{align:"center",side:"top",children:e.jsx("p",{children:(M=a("userPassword"))==null?void 0:M.tooltip})})]})})]}),e.jsxs("div",{className:"grid grid-col-1 lg:grid-cols-2 grid-rows-2 gap-x-16 gap-y-6",children:[e.jsxs("div",{className:"grid gap-4 col-span-1",children:[e.jsx(o,{htmlFor:(O=a("userPassword"))==null?void 0:O.name,children:(R=a("userPassword"))==null?void 0:R.label}),e.jsx(n,{id:(H=a("userPassword"))==null?void 0:H.name,type:"password",required:!l.props.edit,tabIndex:1,autoComplete:"new-password",value:r.password,onChange:s=>d("userPassword",s.target.value),disabled:i||l.props.view,placeholder:(K=a("userPassword"))==null?void 0:K.label})]}),e.jsxs("div",{className:"grid gap-4 col-span-1 col-start-1",children:[e.jsx(o,{htmlFor:(_=a("repeatUserPassword"))==null?void 0:_.name,children:($=a("repeatUserPassword"))==null?void 0:$.label}),e.jsx(n,{id:(G=a("repeatUserPassword"))==null?void 0:G.name,type:"password",required:!l.props.edit,tabIndex:1,autoComplete:"new-password",value:r.repeatUserPassword,onChange:s=>d("repeatUserPassword",s.target.value),disabled:i||l.props.view,placeholder:(J=a("repeatUserPassword"))==null?void 0:J.label}),e.jsx(Pe,{message:ne.repeatUserPassword})]})]}),l.props.groups.length>0&&e.jsxs(e.Fragment,{children:[e.jsx("h2",{className:"font-bold text-xl",children:l.props.groupHead}),e.jsx("div",{className:"grid grid-cols-1 md:grid-cols-5 xl:grid-cols-6 gap-4",children:l.props.groups.map(s=>e.jsxs("div",{className:"grid gap-4",children:[e.jsx(o,{className:"cursor-pointer",htmlFor:s.name,children:s.label}),e.jsx(m,{id:s.name,disabled:i||l.props.view,className:"cursor-pointer size-5",checked:r[s.name],onCheckedChange:t=>d(s.name,t)})]},s.name))})]})]})})]})}export{Te as default};
1
+ import{u as he,aj as ue,j as e,B as c,ai as K,aS as ge,L as je,b as o,I as n,S as W,c as X,d as Y,e as Z,f as ee,g as m,M as fe,N as ve,O as be,aT as we,Q as Ne,h as Ce}from"./app.js";import{Icon as se}from"./icon-BTIjB9Wk.js";import{r as ae}from"./handsontable-PxYdjN8c.js";import Pe from"./input-error-CSrUHo1P.js";import ke from"./material-icon-BXxpxGAd.js";import"./jsoneditor-De1FvcYu.js";import"./monaco-BhBYtg3d.js";function Ee(){var p,x,h,u,g,j,f,v,b,w,N,C,P,k,F,z,y,I,U,S,T,E,A,L,q,V,B,D,M,O,H,Q,R,_,$,G,J;const l=he(),[le,re]=ae.useState(),{fields:ie,groups:de,auth:oe}=l.props,{data:r,setData:te,errors:ne,setError:ce,clearErrors:me,post:pe,processing:i}=ue({...Object.fromEntries(ie.map(s=>[s.name,s.value])),...Object.fromEntries(de.map(s=>[s.name,s.value]))});ae.useEffect(()=>{(async()=>{const t=await Ce.get(`${window.routePrefix}/get-timezones`);re(t.data.timezones)})()},[]);const a=s=>l.props.fields.find(t=>t.name===s),xe=s=>{if(s.preventDefault(),r.userPassword!==r.repeatUserPassword){ce("repeatUserPassword",l.props.passwordError);return}pe(l.props.postLink)},d=(s,t)=>{me(),te(s,t)};return e.jsxs("div",{className:"flex h-full flex-1 flex-col gap-4 rounded-xl p-4",children:[e.jsxs("div",{className:"w-full sticky z-[1001] py-4 pb-8 top-0 h-fit bg-background flex gap-4",children:[e.jsx(c,{className:"mb-3 w-fit",asChild:!0,children:e.jsxs(K,{href:l.props.btnBack.link,children:[e.jsx(se,{iconNode:ge}),l.props.btnBack.title]})}),e.jsxs(c,{variant:"green",type:"submit",className:"w-fit",form:"addUserForm",disabled:i||l.props.view,children:[i&&e.jsx(je,{className:"h-4 w-4 animate-spin"}),l.props.btnSave.title]})]}),e.jsx("form",{id:"addUserForm",onSubmit:xe,className:l.props.view?"cursor-not-allowed":"",children:e.jsxs("div",{className:"flex flex-col gap-10 max-w-[1144px]",children:[e.jsx("h2",{className:"font-bold text-xl",children:l.props.head}),e.jsxs("div",{className:"flex-col xl:flex-row flex gap-16",children:[e.jsxs("div",{className:"basis-1/2 flex flex-col gap-6",children:[e.jsxs("div",{className:"grid gap-4",children:[e.jsx(o,{htmlFor:(p=a("login"))==null?void 0:p.name,children:(x=a("login"))==null?void 0:x.label}),e.jsx(n,{id:(h=a("login"))==null?void 0:h.name,type:"text",required:!0,tabIndex:1,autoComplete:"username",value:r.login,onChange:s=>d("login",s.target.value),disabled:i||l.props.view,placeholder:(u=a("login"))==null?void 0:u.label})]}),e.jsxs("div",{className:"grid gap-4",children:[e.jsx(o,{htmlFor:(g=a("fullName"))==null?void 0:g.name,children:(j=a("fullName"))==null?void 0:j.label}),e.jsx(n,{id:(f=a("fullName"))==null?void 0:f.name,type:"text",required:!0,tabIndex:1,autoComplete:"additional-name",value:r.fullName,onChange:s=>d("fullName",s.target.value),disabled:i||l.props.view,placeholder:(v=a("fullName"))==null?void 0:v.label})]}),e.jsxs("div",{className:"grid gap-4",children:[e.jsx(o,{htmlFor:(b=a("email"))==null?void 0:b.name,children:(w=a("email"))==null?void 0:w.label}),e.jsx(n,{id:(N=a("email"))==null?void 0:N.name,type:"email",required:!0,tabIndex:1,autoComplete:"email",value:r.email,onChange:s=>d("email",s.target.value),disabled:i||l.props.view,placeholder:(C=a("email"))==null?void 0:C.label})]})]}),e.jsxs("div",{className:"basis-1/2 flex flex-col gap-6",children:[e.jsxs("div",{className:"grid gap-4",children:[e.jsx(o,{htmlFor:(P=a("timezone"))==null?void 0:P.name,children:(k=a("timezone"))==null?void 0:k.label}),e.jsxs(W,{onValueChange:s=>d("timezone",s),defaultValue:r.timezone,disabled:i||l.props.view,children:[e.jsx(X,{className:"w-full cursor-pointer",children:e.jsx(Y,{placeholder:(F=a("timezone"))==null?void 0:F.name})}),e.jsx(Z,{children:(le??[]).map(s=>e.jsx(ee,{value:s.value,children:s.label},s.value))})]})]}),e.jsxs("div",{className:"flex flex-col md:flex-row justify-start gap-4 xl:justify-between items-start md:items-center",children:[a("date")&&e.jsxs("div",{className:"grid gap-4",children:[e.jsx(o,{htmlFor:(z=a("date"))==null?void 0:z.name,children:(y=a("date"))==null?void 0:y.label}),e.jsx(n,{id:(I=a("date"))==null?void 0:I.name,type:"date",className:"max-w-fit",tabIndex:1,value:r.date,onChange:s=>d("date",s.target.value),disabled:i})]}),e.jsxs("div",{className:"flex gap-6",children:[a("isAdmin")&&e.jsxs("div",{className:"grid gap-4",children:[e.jsx(o,{className:"cursor-pointer",htmlFor:(U=a("isAdmin"))==null?void 0:U.name,children:(S=a("isAdmin"))==null?void 0:S.label}),e.jsx(m,{id:(T=a("isAdmin"))==null?void 0:T.name,className:"cursor-pointer size-5",disabled:i||l.props.view,checked:r.isAdmin,onCheckedChange:s=>d("isAdmin",s)})]}),a("isConfirmed")&&e.jsxs("div",{className:"grid gap-4",children:[e.jsx(o,{className:"cursor-pointer",htmlFor:(E=a("isConfirmed"))==null?void 0:E.name,children:(A=a("isConfirmed"))==null?void 0:A.label}),e.jsx(m,{id:(L=a("isConfirmed"))==null?void 0:L.name,className:"cursor-pointer size-5",disabled:i||l.props.view,checked:r.isConfirmed,onCheckedChange:s=>d("isConfirmed",s)})]})]})]}),a("locale")&&e.jsxs("div",{className:"grid gap-4",children:[e.jsx(o,{htmlFor:(q=a("locale"))==null?void 0:q.name,children:(V=a("locale"))==null?void 0:V.label}),e.jsxs(W,{onValueChange:s=>d("locale",s),defaultValue:r.locale,disabled:i||l.props.view,children:[e.jsx(X,{className:"w-full cursor-pointer",children:e.jsx(Y,{placeholder:(B=a("locale"))==null?void 0:B.name})}),e.jsx(Z,{children:(l.props.locales??[]).map(s=>e.jsx(ee,{value:s.value,children:s.label},s.value))})]})]})]})]}),oe.user.isAdministrator&&e.jsx(c,{className:"w-fit",asChild:!0,variant:"outline",children:e.jsxs(K,{href:l.props.userPretend.postLink,method:"post",data:{login:r.login,pretend:!0},children:[e.jsx(ke,{name:"masks",className:"!text-[18px]"}),l.props.userPretend.label]})}),e.jsxs("div",{className:"flex gap-3",children:[e.jsx("label",{className:"font-bold text-xl",children:(D=a("userPassword"))==null?void 0:D.label}),e.jsx(fe,{children:e.jsxs(ve,{children:[e.jsx(be,{onClick:s=>s.preventDefault(),children:e.jsx(se,{iconNode:we,className:"text-primary w-5 h-5 cursor-pointer"})}),e.jsx(Ne,{align:"center",side:"top",children:e.jsx("p",{children:(M=a("userPassword"))==null?void 0:M.tooltip})})]})})]}),e.jsxs("div",{className:"grid grid-col-1 lg:grid-cols-2 grid-rows-2 gap-x-16 gap-y-6",children:[e.jsxs("div",{className:"grid gap-4 col-span-1",children:[e.jsx(o,{htmlFor:(O=a("userPassword"))==null?void 0:O.name,children:(H=a("userPassword"))==null?void 0:H.label}),e.jsx(n,{id:(Q=a("userPassword"))==null?void 0:Q.name,type:"password",required:!l.props.edit,tabIndex:1,autoComplete:"new-password",value:r.password,onChange:s=>d("userPassword",s.target.value),disabled:i||l.props.view,placeholder:(R=a("userPassword"))==null?void 0:R.label})]}),e.jsxs("div",{className:"grid gap-4 col-span-1 col-start-1",children:[e.jsx(o,{htmlFor:(_=a("repeatUserPassword"))==null?void 0:_.name,children:($=a("repeatUserPassword"))==null?void 0:$.label}),e.jsx(n,{id:(G=a("repeatUserPassword"))==null?void 0:G.name,type:"password",required:!l.props.edit,tabIndex:1,autoComplete:"new-password",value:r.repeatUserPassword,onChange:s=>d("repeatUserPassword",s.target.value),disabled:i||l.props.view,placeholder:(J=a("repeatUserPassword"))==null?void 0:J.label}),e.jsx(Pe,{message:ne.repeatUserPassword})]})]}),l.props.groups.length>0&&e.jsxs(e.Fragment,{children:[e.jsx("h2",{className:"font-bold text-xl",children:l.props.groupHead}),e.jsx("div",{className:"grid grid-cols-1 md:grid-cols-5 xl:grid-cols-6 gap-4",children:l.props.groups.map(s=>e.jsxs("div",{className:"grid gap-4",children:[e.jsx(o,{className:"cursor-pointer",htmlFor:s.name,children:s.label}),e.jsx(m,{id:s.name,disabled:i||l.props.view,className:"cursor-pointer size-5",checked:r[s.name],onCheckedChange:t=>d(s.name,t)})]},s.name))})]})]})})]})}export{Ee as default};
@@ -1 +1 @@
1
- import{u as E,j as e,ag as I,am as L,an as P,B as v,ao as z,S as C,c as M,d as R,e as T,f as D,ap as w,aq as O,L as k}from"./app.js";import B from"./app-shell-CwiL9UZ5.js";import{AppSidebar as K}from"./app-sidebar-C7TXiSvV.js";import{A as V,a as N,N as _,b as F}from"./app-sidebar-header-qHEOMq5D.js";import{r as l}from"./handsontable-PxYdjN8c.js";const H=l.memo(({children:o,breadcrumbs:a=[],className:i})=>{const n=E();return e.jsxs(B,{variant:"sidebar",children:[e.jsx(I,{title:n.props.title}),e.jsx(K,{}),e.jsxs(L,{className:i,children:[e.jsx(V,{breadcrumbs:a}),e.jsx("div",{className:"relative flex-1 overflow-hidden",children:e.jsx("div",{className:"h-full",children:o})})]})]})});function q({width:o="min(25vw, 420px)"}){const{isEnabled:a,isOpen:i,closeChat:n,models:s,activeModel:r,setActiveModel:d,messages:c,loading:m,sending:x,error:j,sendMessage:y}=N(),[f,h]=l.useState(""),g=l.useRef(null);l.useEffect(()=>{i||h("")},[i]),l.useEffect(()=>{g.current&&g.current.scrollIntoView({behavior:"smooth"})},[c]);const u=s.length>0,A=async t=>{t.preventDefault();const p=f.trim();p&&(await y(p),h(""))},S=t=>{if((t.ctrlKey||t.metaKey)&&t.key==="Enter"){t.preventDefault();const p=f.trim();p&&!x&&(y(p),h(""))}};return a?e.jsxs("aside",{id:"ai-assistant-panel","aria-label":"AI assistant chat","aria-hidden":!i,className:w("bg-card text-card-foreground fixed bottom-0 right-0 top-0 z-[60] flex h-full flex-col border-l shadow-xl transition-all duration-300 ease-in-out","md:w-auto w-full",i?"translate-x-0 opacity-100":"translate-x-full opacity-0 pointer-events-none"),style:{width:"var(--ai-assistant-panel-actual-width, "+o+")"},children:[e.jsxs("div",{className:"flex items-center justify-between border-b px-4 py-3",children:[e.jsxs("div",{className:"flex items-center gap-2",children:[e.jsx(P,{className:"size-5 text-primary"}),e.jsxs("div",{className:"flex flex-col",children:[e.jsx("span",{className:"font-semibold leading-tight",children:"AI assistant"}),e.jsx("span",{className:"text-xs text-muted-foreground",children:"Chat with your selected model."})]})]}),e.jsx(v,{variant:"ghost",size:"icon",onClick:n,"aria-label":"Close AI assistant",children:e.jsx(z,{className:"size-4"})})]}),e.jsxs("div",{className:"flex flex-1 flex-col gap-4 overflow-hidden px-4 py-4",children:[!u&&!m&&e.jsx("div",{className:"flex flex-1 items-center justify-center rounded-md border border-dashed p-6 text-sm text-muted-foreground",children:"No AI models are available for your account."}),u&&e.jsxs(e.Fragment,{children:[e.jsxs(C,{value:r,onValueChange:d,children:[e.jsx(M,{className:"w-full",children:e.jsx(R,{placeholder:"Select a model"})}),e.jsx(T,{className:"z-[70]",children:s.map(t=>e.jsx(D,{value:t.id,children:e.jsxs("div",{className:"flex flex-col text-left",children:[e.jsx("span",{className:"font-medium",children:t.name}),t.description&&e.jsx("span",{className:"text-xs text-muted-foreground",children:t.description})]})},t.id))})]}),e.jsxs("div",{className:"flex flex-1 flex-col gap-3 overflow-hidden rounded-md border bg-background p-4",children:[e.jsxs("div",{className:"flex-1 space-y-3 overflow-y-auto pr-2","data-ai-assistant-messages":!0,children:[m&&e.jsx("div",{className:"flex justify-center py-6 text-sm text-muted-foreground",children:"Loading conversation..."}),!m&&c.length===0&&e.jsx("div",{className:"flex h-full items-center justify-center text-sm text-muted-foreground",children:"Start a conversation to see responses here."}),c.map(t=>e.jsxs("div",{className:w("flex flex-col gap-1 rounded-md border p-3 text-sm shadow-xs",t.role==="assistant"?"border-primary/30 bg-primary/5":"border-border bg-background"),children:[e.jsx("span",{className:"font-semibold",children:t.role==="assistant"?"Assistant":"You"}),e.jsx("p",{className:"whitespace-pre-wrap leading-relaxed",children:t.content}),e.jsx("span",{className:"text-xs text-muted-foreground",children:new Date(t.timestamp).toLocaleTimeString()})]},t.id)),e.jsx("div",{ref:g})]}),e.jsxs("form",{className:"space-y-2",onSubmit:A,children:[e.jsx(O,{placeholder:u?"Type your question... (Ctrl+Enter to send)":"No models available",value:f,onChange:t=>h(t.target.value),onKeyDown:S,disabled:!u||x,rows:3}),e.jsxs("div",{className:"flex items-center justify-between gap-3",children:[j&&e.jsx("span",{className:"text-xs text-destructive",children:j}),e.jsx(v,{type:"submit",disabled:!u||x||!f.trim(),children:x?e.jsxs("span",{className:"flex items-center gap-2",children:[e.jsx(k,{className:"size-4 animate-spin"}),"Sending…"]}):"Send"})]})]})]})]})]})]}):null}const $="min(25vw, 420px)",b="margin-right 300ms ease-in-out";function G({children:o,panelWidth:a=$}){const{isEnabled:i,isOpen:n}=N();return l.useEffect(()=>{const s=document.getElementById("app");if(!s)return;const r=s.style.transition,d=r==null?void 0:r.includes("margin-right");return d||(s.style.transition=r?`${r}, ${b}`:b),s.classList.add("ai-assistant-host"),s.style.setProperty("--ai-assistant-panel-width",a),()=>{s.classList.remove("ai-assistant-host"),s.style.removeProperty("--ai-assistant-panel-width"),s.style.removeProperty("--ai-assistant-panel-actual-width"),s.style.removeProperty("margin-right"),delete s.dataset.aiAssistantOpen,d||(s.style.transition=r)}},[a]),l.useEffect(()=>{const s=document.getElementById("app");if(!s)return;const r=window.innerWidth<768,d=r?"100vw":a;s.style.setProperty("--ai-assistant-panel-actual-width",d),i&&n?(s.style.marginRight=r?"0":a,s.dataset.aiAssistantOpen="true"):(s.style.removeProperty("margin-right"),s.dataset.aiAssistantOpen="false");const c=()=>{const m=window.innerWidth<768,x=m?"100vw":a;s.style.setProperty("--ai-assistant-panel-actual-width",x),i&&n&&(s.style.marginRight=m?"0":a)};return window.addEventListener("resize",c),()=>window.removeEventListener("resize",c)},[i,n,a]),e.jsxs(e.Fragment,{children:[o,e.jsx(q,{width:a})]})}const Z=l.memo(({children:o,className:a,breadcrumbs:i,...n})=>e.jsx(_,{children:e.jsxs(F,{children:[e.jsx(H,{breadcrumbs:i,className:a,...n,children:o}),e.jsx(G,{})]})}));export{Z as A};
1
+ import{u as E,j as e,ah as I,an as L,ao as P,B as v,ap as z,S as C,c as M,d as R,e as T,f as D,aq as w,ar as O,L as k}from"./app.js";import B from"./app-shell-DbPu3ZPM.js";import{AppSidebar as K}from"./app-sidebar-CQqvkGH0.js";import{A as V,a as N,N as _,b as F}from"./app-sidebar-header-C8sntqs3.js";import{r as l}from"./handsontable-PxYdjN8c.js";const H=l.memo(({children:o,breadcrumbs:a=[],className:i})=>{const n=E();return e.jsxs(B,{variant:"sidebar",children:[e.jsx(I,{title:n.props.title}),e.jsx(K,{}),e.jsxs(L,{className:i,children:[e.jsx(V,{breadcrumbs:a}),e.jsx("div",{className:"relative flex-1 overflow-hidden",children:e.jsx("div",{className:"h-full",children:o})})]})]})});function q({width:o="min(25vw, 420px)"}){const{isEnabled:a,isOpen:i,closeChat:n,models:s,activeModel:r,setActiveModel:d,messages:c,loading:m,sending:x,error:g,sendMessage:y}=N(),[f,h]=l.useState(""),j=l.useRef(null);l.useEffect(()=>{i||h("")},[i]),l.useEffect(()=>{j.current&&j.current.scrollIntoView({behavior:"smooth"})},[c]);const u=s.length>0,A=async t=>{t.preventDefault();const p=f.trim();p&&(await y(p),h(""))},S=t=>{if((t.ctrlKey||t.metaKey)&&t.key==="Enter"){t.preventDefault();const p=f.trim();p&&!x&&(y(p),h(""))}};return a?e.jsxs("aside",{id:"ai-assistant-panel","aria-label":"AI assistant chat","aria-hidden":!i,className:w("bg-card text-card-foreground fixed bottom-0 right-0 top-0 z-[60] flex h-full flex-col border-l shadow-xl transition-all duration-300 ease-in-out","md:w-auto w-full",i?"translate-x-0 opacity-100":"translate-x-full opacity-0 pointer-events-none"),style:{width:"var(--ai-assistant-panel-actual-width, "+o+")"},children:[e.jsxs("div",{className:"flex items-center justify-between border-b px-4 py-3",children:[e.jsxs("div",{className:"flex items-center gap-2",children:[e.jsx(P,{className:"size-5 text-primary"}),e.jsxs("div",{className:"flex flex-col",children:[e.jsx("span",{className:"font-semibold leading-tight",children:"AI assistant"}),e.jsx("span",{className:"text-xs text-muted-foreground",children:"Chat with your selected model."})]})]}),e.jsx(v,{variant:"ghost",size:"icon",onClick:n,"aria-label":"Close AI assistant",children:e.jsx(z,{className:"size-4"})})]}),e.jsxs("div",{className:"flex flex-1 flex-col gap-4 overflow-hidden px-4 py-4",children:[!u&&!m&&e.jsx("div",{className:"flex flex-1 items-center justify-center rounded-md border border-dashed p-6 text-sm text-muted-foreground",children:"No AI models are available for your account."}),u&&e.jsxs(e.Fragment,{children:[e.jsxs(C,{value:r,onValueChange:d,children:[e.jsx(M,{className:"w-full",children:e.jsx(R,{placeholder:"Select a model"})}),e.jsx(T,{className:"z-[70]",children:s.map(t=>e.jsx(D,{value:t.id,children:e.jsxs("div",{className:"flex flex-col text-left",children:[e.jsx("span",{className:"font-medium",children:t.name}),t.description&&e.jsx("span",{className:"text-xs text-muted-foreground",children:t.description})]})},t.id))})]}),e.jsxs("div",{className:"flex flex-1 flex-col gap-3 overflow-hidden rounded-md border bg-background p-4",children:[e.jsxs("div",{className:"flex-1 space-y-3 overflow-y-auto pr-2","data-ai-assistant-messages":!0,children:[m&&e.jsx("div",{className:"flex justify-center py-6 text-sm text-muted-foreground",children:"Loading conversation..."}),!m&&c.length===0&&e.jsx("div",{className:"flex h-full items-center justify-center text-sm text-muted-foreground",children:"Start a conversation to see responses here."}),c.map(t=>e.jsxs("div",{className:w("flex flex-col gap-1 rounded-md border p-3 text-sm shadow-xs",t.role==="assistant"?"border-primary/30 bg-primary/5":"border-border bg-background"),children:[e.jsx("span",{className:"font-semibold",children:t.role==="assistant"?"Assistant":"You"}),e.jsx("p",{className:"whitespace-pre-wrap leading-relaxed",children:t.content}),e.jsx("span",{className:"text-xs text-muted-foreground",children:new Date(t.timestamp).toLocaleTimeString()})]},t.id)),e.jsx("div",{ref:j})]}),e.jsxs("form",{className:"space-y-2",onSubmit:A,children:[e.jsx(O,{placeholder:u?"Type your question... (Ctrl+Enter to send)":"No models available",value:f,onChange:t=>h(t.target.value),onKeyDown:S,disabled:!u||x,rows:3}),e.jsxs("div",{className:"flex items-center justify-between gap-3",children:[g&&e.jsx("span",{className:"text-xs text-destructive",children:g}),e.jsx(v,{type:"submit",disabled:!u||x||!f.trim(),children:x?e.jsxs("span",{className:"flex items-center gap-2",children:[e.jsx(k,{className:"size-4 animate-spin"}),"Sending…"]}):"Send"})]})]})]})]})]})]}):null}const $="min(25vw, 420px)",b="margin-right 300ms ease-in-out";function G({children:o,panelWidth:a=$}){const{isEnabled:i,isOpen:n}=N();return l.useEffect(()=>{const s=document.getElementById("app");if(!s)return;const r=s.style.transition,d=r==null?void 0:r.includes("margin-right");return d||(s.style.transition=r?`${r}, ${b}`:b),s.classList.add("ai-assistant-host"),s.style.setProperty("--ai-assistant-panel-width",a),()=>{s.classList.remove("ai-assistant-host"),s.style.removeProperty("--ai-assistant-panel-width"),s.style.removeProperty("--ai-assistant-panel-actual-width"),s.style.removeProperty("margin-right"),delete s.dataset.aiAssistantOpen,d||(s.style.transition=r)}},[a]),l.useEffect(()=>{const s=document.getElementById("app");if(!s)return;const r=window.innerWidth<768,d=r?"100vw":a;s.style.setProperty("--ai-assistant-panel-actual-width",d),i&&n?(s.style.marginRight=r?"0":a,s.dataset.aiAssistantOpen="true"):(s.style.removeProperty("margin-right"),s.dataset.aiAssistantOpen="false");const c=()=>{const m=window.innerWidth<768,x=m?"100vw":a;s.style.setProperty("--ai-assistant-panel-actual-width",x),i&&n&&(s.style.marginRight=m?"0":a)};return window.addEventListener("resize",c),()=>window.removeEventListener("resize",c)},[i,n,a]),e.jsxs(e.Fragment,{children:[o,e.jsx(q,{width:a})]})}const Z=l.memo(({children:o,className:a,breadcrumbs:i,...n})=>e.jsx(_,{children:e.jsxs(F,{children:[e.jsx(H,{breadcrumbs:i,className:a,...n,children:o}),e.jsx(G,{})]})}));export{Z as A};
@@ -1 +1 @@
1
- import{j as a,aT as d}from"./app.js";import{r as o}from"./handsontable-PxYdjN8c.js";import"./jsoneditor-De1FvcYu.js";import"./monaco-BhBYtg3d.js";const u=o.memo(({children:e,variant:s="header"})=>{const[t,n]=o.useState(()=>typeof window<"u"?localStorage.getItem("sidebar")!=="false":!0),i=r=>{n(r),typeof window<"u"&&localStorage.setItem("sidebar",String(r))};return s==="header"?a.jsx("div",{className:"flex min-h-screen w-full flex-col",children:e}):a.jsx(d,{defaultOpen:t,open:t,onOpenChange:i,children:e})});export{u as default};
1
+ import{j as a,aU as d}from"./app.js";import{r as o}from"./handsontable-PxYdjN8c.js";import"./jsoneditor-De1FvcYu.js";import"./monaco-BhBYtg3d.js";const u=o.memo(({children:e,variant:s="header"})=>{const[t,n]=o.useState(()=>typeof window<"u"?localStorage.getItem("sidebar")!=="false":!0),i=r=>{n(r),typeof window<"u"&&localStorage.setItem("sidebar",String(r))};return s==="header"?a.jsx("div",{className:"flex min-h-screen w-full flex-col",children:e}):a.jsx(d,{defaultOpen:t,open:t,onOpenChange:i,children:e})});export{u as default};
@@ -1 +1 @@
1
- import{u,j as s,a_ as N,a$ as g,b0 as i,b1 as c,b2 as f,b3 as v,b4 as k,b5 as d,B as C,b6 as M,b7 as w,b8 as _,b9 as y,ba as B,bb as x,ah as n,bc as T,bd as p,be as t,C as o,bf as h,bg as j,bh as b,bi as m,bj as $,bk as R}from"./app.js";import{NavMain as z}from"./nav-main-G6VwCche.js";import l from"./material-icon-DZVU9Gse.js";import"./jsoneditor-De1FvcYu.js";import"./handsontable-PxYdjN8c.js";import"./monaco-BhBYtg3d.js";function L(){const r=u();return s.jsxs(N,{collapsible:"icon",variant:"inset",children:[s.jsx(g,{children:s.jsx(i,{children:s.jsxs(c,{children:[s.jsx(f,{className:"p-0 shadow-none border-none bg-transparent hidden md:block",children:s.jsxs(v,{children:[s.jsx(k,{asChild:!0,className:"text-sidebar-foreground hover:bg-sidebar-accent hover:text-sidebar-accent-foreground rounded-md",children:s.jsx(d,{asChild:!0,children:s.jsx(C,{variant:"ghost",asChild:!0,className:`w-full ${r.props.section?"":"pointer-events-none"}`,children:s.jsxs("div",{children:[s.jsx(l,{name:"rocket_launch",className:"!text-[18px]"}),s.jsx("span",{className:"group-data-[state=collapsed]:hidden",children:r.props.brand}),r.props.section&&s.jsx(M,{className:"ml-auto group-data-[state=collapsed]:hidden"})]})})})}),r.props.section&&s.jsx(w,{side:"right",className:"z-[1003]",children:r.props.section.map(e=>s.jsx("div",{children:e.subItems?s.jsxs(_,{children:[s.jsxs(y,{className:"flex gap-2 items-center cursor-pointer",children:[s.jsx(l,{name:e.icon,className:"!text-[18px]"}),s.jsx("span",{className:"hover:underline",children:e.title})]}),s.jsx(B,{children:e.subItems.map(a=>s.jsx(x,{children:a.type==="blank"?s.jsxs("a",{href:a.link,target:"_blank",className:"flex gap-2 items-center",children:[a.icon&&s.jsx(l,{name:a.icon,className:"!text-[18px]"}),s.jsx("span",{className:"hover:underline",children:a.title})]},a.id):s.jsxs(n,{href:a.link,className:"flex gap-2 items-center",children:[a.icon&&s.jsx(l,{name:a.icon,className:"!text-[18px]"}),s.jsx("span",{className:"hover:underline",children:a.title})]},a.id)},a.id))})]}):s.jsx(x,{children:e.type==="blank"?s.jsxs("a",{href:e.link,target:"_blank",className:"flex gap-2 items-center",children:[e.icon&&s.jsx(l,{name:e.icon,className:"!text-[18px]"}),s.jsx("span",{className:"hover:underline",children:e.title})]}):s.jsxs(n,{href:e.link,className:"flex gap-2 items-center",children:[e.icon&&s.jsx(l,{name:e.icon,className:"!text-[18px]"}),s.jsx("span",{className:"hover:underline",children:e.title})]})})},e.id))})]})}),s.jsx(T,{className:"px-2 py-0 block md:hidden",children:s.jsx(i,{children:s.jsx(p,{asChild:!0,className:"group/collapsible",children:s.jsxs(c,{children:[s.jsx(t,{asChild:!0,children:s.jsxs(d,{children:[s.jsx(l,{name:"rocket_launch",className:"!text-[18px]"}),s.jsx("span",{className:"overflow-hidden text-ellipsis whitespace-nowrap",children:r.props.brand}),r.props.section&&s.jsx(o,{className:"ml-auto transition-transform duration-200 group-data-[state=open]/collapsible:rotate-90"})]})}),r.props.section&&s.jsx(h,{children:s.jsx(j,{children:r.props.section&&r.props.section.map(e=>e.subItems?s.jsx(i,{children:s.jsx(p,{asChild:!0,className:"group/collapsible-sub",children:s.jsxs(c,{children:[s.jsx(t,{asChild:!0,children:s.jsxs(d,{children:[s.jsx(l,{name:e.icon,className:"!text-[18px]"}),s.jsx("span",{className:"overflow-hidden text-ellipsis whitespace-nowrap",children:e.title}),s.jsx(o,{className:"ml-auto transition-transform duration-200 group-data-[state=open]/collapsible-sub:rotate-90"})]})}),s.jsx(h,{children:s.jsx(j,{children:e.subItems.map(a=>s.jsx(b,{children:s.jsx(m,{asChild:!0,children:a.type==="blank"?s.jsxs("a",{href:a.link,target:"_blank",className:"flex gap-2 items-center",children:[a.icon&&s.jsx(l,{name:a.icon,className:"!text-[18px]"}),s.jsx("span",{className:"hover:underline",children:a.title})]}):s.jsxs(n,{href:a.link,className:"flex gap-2 items-center",children:[a.icon&&s.jsx(l,{name:a.icon,className:"!text-[18px]"}),s.jsx("span",{className:"hover:underline",children:a.title})]})})},a.id))})})]})})},e.id):s.jsx(b,{children:s.jsx(m,{asChild:!0,children:e.type==="blank"?s.jsxs("a",{href:e.link,target:"_blank",className:"flex gap-2 items-center",children:[e.icon&&s.jsx(l,{name:e.icon,className:"!text-[18px]"}),s.jsx("span",{className:"hover:underline",children:e.title})]}):s.jsxs(n,{href:e.link,className:"flex gap-2 items-center",children:[e.icon&&s.jsx(l,{name:e.icon,className:"!text-[18px]"}),s.jsx("span",{className:"hover:underline",children:e.title})]})})},e.id))})})]})})})})]},r.props.brand)})}),s.jsx($,{children:s.jsx(z,{items:r.props.menu})}),s.jsx(R,{children:s.jsx("div",{className:"text-center opacity-70",children:r.props.showVersion&&`v.${r.props.versionText||"4.5.0"}`})})]})}export{L as AppSidebar};
1
+ import{u,j as s,a$ as N,b0 as g,b1 as i,b2 as c,b3 as f,b4 as v,b5 as k,b6 as d,B as C,b7 as M,b8 as w,b9 as _,ba as y,bb as B,bc as x,ai as n,bd as T,be as p,bf as t,C as o,bg as h,bh as j,bi as b,bj as m,bk as $,bl as R}from"./app.js";import{NavMain as z}from"./nav-main-DcvkRp44.js";import l from"./material-icon-BXxpxGAd.js";import"./jsoneditor-De1FvcYu.js";import"./handsontable-PxYdjN8c.js";import"./monaco-BhBYtg3d.js";function L(){const r=u();return s.jsxs(N,{collapsible:"icon",variant:"inset",children:[s.jsx(g,{children:s.jsx(i,{children:s.jsxs(c,{children:[s.jsx(f,{className:"p-0 shadow-none border-none bg-transparent hidden md:block",children:s.jsxs(v,{children:[s.jsx(k,{asChild:!0,className:"text-sidebar-foreground hover:bg-sidebar-accent hover:text-sidebar-accent-foreground rounded-md",children:s.jsx(d,{asChild:!0,children:s.jsx(C,{variant:"ghost",asChild:!0,className:`w-full ${r.props.section?"":"pointer-events-none"}`,children:s.jsxs("div",{children:[s.jsx(l,{name:"rocket_launch",className:"!text-[18px]"}),s.jsx("span",{className:"group-data-[state=collapsed]:hidden",children:r.props.brand}),r.props.section&&s.jsx(M,{className:"ml-auto group-data-[state=collapsed]:hidden"})]})})})}),r.props.section&&s.jsx(w,{side:"right",className:"z-[1003]",children:r.props.section.map(e=>s.jsx("div",{children:e.subItems?s.jsxs(_,{children:[s.jsxs(y,{className:"flex gap-2 items-center cursor-pointer",children:[s.jsx(l,{name:e.icon,className:"!text-[18px]"}),s.jsx("span",{className:"hover:underline",children:e.title})]}),s.jsx(B,{children:e.subItems.map(a=>s.jsx(x,{children:a.type==="blank"?s.jsxs("a",{href:a.link,target:"_blank",className:"flex gap-2 items-center",children:[a.icon&&s.jsx(l,{name:a.icon,className:"!text-[18px]"}),s.jsx("span",{className:"hover:underline",children:a.title})]},a.id):s.jsxs(n,{href:a.link,className:"flex gap-2 items-center",children:[a.icon&&s.jsx(l,{name:a.icon,className:"!text-[18px]"}),s.jsx("span",{className:"hover:underline",children:a.title})]},a.id)},a.id))})]}):s.jsx(x,{children:e.type==="blank"?s.jsxs("a",{href:e.link,target:"_blank",className:"flex gap-2 items-center",children:[e.icon&&s.jsx(l,{name:e.icon,className:"!text-[18px]"}),s.jsx("span",{className:"hover:underline",children:e.title})]}):s.jsxs(n,{href:e.link,className:"flex gap-2 items-center",children:[e.icon&&s.jsx(l,{name:e.icon,className:"!text-[18px]"}),s.jsx("span",{className:"hover:underline",children:e.title})]})})},e.id))})]})}),s.jsx(T,{className:"px-2 py-0 block md:hidden",children:s.jsx(i,{children:s.jsx(p,{asChild:!0,className:"group/collapsible",children:s.jsxs(c,{children:[s.jsx(t,{asChild:!0,children:s.jsxs(d,{children:[s.jsx(l,{name:"rocket_launch",className:"!text-[18px]"}),s.jsx("span",{className:"overflow-hidden text-ellipsis whitespace-nowrap",children:r.props.brand}),r.props.section&&s.jsx(o,{className:"ml-auto transition-transform duration-200 group-data-[state=open]/collapsible:rotate-90"})]})}),r.props.section&&s.jsx(h,{children:s.jsx(j,{children:r.props.section&&r.props.section.map(e=>e.subItems?s.jsx(i,{children:s.jsx(p,{asChild:!0,className:"group/collapsible-sub",children:s.jsxs(c,{children:[s.jsx(t,{asChild:!0,children:s.jsxs(d,{children:[s.jsx(l,{name:e.icon,className:"!text-[18px]"}),s.jsx("span",{className:"overflow-hidden text-ellipsis whitespace-nowrap",children:e.title}),s.jsx(o,{className:"ml-auto transition-transform duration-200 group-data-[state=open]/collapsible-sub:rotate-90"})]})}),s.jsx(h,{children:s.jsx(j,{children:e.subItems.map(a=>s.jsx(b,{children:s.jsx(m,{asChild:!0,children:a.type==="blank"?s.jsxs("a",{href:a.link,target:"_blank",className:"flex gap-2 items-center",children:[a.icon&&s.jsx(l,{name:a.icon,className:"!text-[18px]"}),s.jsx("span",{className:"hover:underline",children:a.title})]}):s.jsxs(n,{href:a.link,className:"flex gap-2 items-center",children:[a.icon&&s.jsx(l,{name:a.icon,className:"!text-[18px]"}),s.jsx("span",{className:"hover:underline",children:a.title})]})})},a.id))})})]})})},e.id):s.jsx(b,{children:s.jsx(m,{asChild:!0,children:e.type==="blank"?s.jsxs("a",{href:e.link,target:"_blank",className:"flex gap-2 items-center",children:[e.icon&&s.jsx(l,{name:e.icon,className:"!text-[18px]"}),s.jsx("span",{className:"hover:underline",children:e.title})]}):s.jsxs(n,{href:e.link,className:"flex gap-2 items-center",children:[e.icon&&s.jsx(l,{name:e.icon,className:"!text-[18px]"}),s.jsx("span",{className:"hover:underline",children:e.title})]})})},e.id))})})]})})})})]},r.props.brand)})}),s.jsx($,{children:s.jsx(z,{items:r.props.menu})}),s.jsx(R,{children:s.jsx("div",{className:"text-center opacity-70",children:r.props.showVersion&&`v.${r.props.versionText||"4.5.0"}`})})]})}export{L as AppSidebar};
@@ -1 +1 @@
1
- import{u as z,j as e,h as y,aU as V,q as Y,B as $,aV as G,v as W,w as X,aW as Z,M as L,N as R,E as K,O as B,r as Q,aX as ee,ah as F,L as D,an as te,ap as se,aY as ae,aZ as re}from"./app.js";import{Breadcrumbs as oe}from"./breadcrumbs-D5PCyRGn.js";import{NavUser as ne}from"./nav-user-BfROibnw.js";import{ThemeSwitcher as ie}from"./theme-switcher-BURZ8Tza.js";import{r as a}from"./handsontable-PxYdjN8c.js";import ce from"./material-icon-DZVU9Gse.js";const H=a.createContext(void 0),ve=({children:l})=>{const[w,o]=a.useState([]),[m,u]=a.useState([]),[p,f]=a.useState([]),[E,c]=a.useState(!1),[n,h]=a.useState(null),[j,C]=a.useState(""),v=z(),[g,S]=a.useState({}),M=[...m,...p],x=async()=>{try{const t=await y.get(`${window.routePrefix}/notifications/api`,{params:{unreadOnly:!0,limit:4}});o(t.data)}catch(t){console.error("Error fetching bell notifications:",t)}},i=async()=>{try{const t=await y.post(`${window.routePrefix}/notifications`);S(t.data)}catch(t){console.log(t)}},A=async()=>{await x()},b=async()=>{try{const t=await y.get(`${window.routePrefix}/notifications/api/get-classes`);t.data&&(h(t.data.activeServices),C(t.data.initTab))}catch(t){console.error("Error fetching tabs:",t)}},k=async(t,s)=>{try{if(!t){await P(s);return}const r=await y.post(`${window.routePrefix}/notifications/api/search`,{s:t,notificationClass:s});f(r.data)}catch(r){console.error("Error searching notifications:",r)}},P=async t=>{c(!0);try{const s=`${window.routePrefix}/notifications/api/${t}`,r=await y.get(s,{params:{limit:20,skip:0,unreadOnly:!1}});return u([]),f(r.data),r.data}catch(s){return console.error("Error fetching all notifications:",s),[]}finally{c(!1)}},I=async(t,s)=>{try{const r=`${window.routePrefix}/notifications/api/${t}`,d=await y.get(r,{params:{limit:20,skip:s,unreadOnly:!1}});return f(N=>[...N,...d.data]),d.data}catch(r){return console.error("Error paginating notifications:",r),[]}};a.useEffect(()=>{if(!v.props.notifications)return;i(),x();const t=new EventSource(`${window.routePrefix}/notifications/api/stream`);return t.addEventListener("connected",s=>{const r=JSON.parse(s.data);console.log("Connected event:",r),b()}),t.addEventListener("notification",s=>{const r=JSON.parse(s.data);u(d=>[r,...d]),o(d=>[r,...d].slice(0,4))}),t.onerror=()=>{console.error("SSE connection error")},()=>t.close()},[]);const T=async(t,s)=>{try{await y.put(`${window.routePrefix}/notifications/api/${t}/${s}/read`,{}),u(r=>r.map(d=>d.id===s?{...d,read:!0}:d)),f(r=>r.map(d=>d.id===s?{...d,read:!0}:d)),o([])}catch(r){console.error("Error marking as read:",r)}},_=async()=>{try{await y.put(`${window.routePrefix}/notifications/api/read-all`),u(t=>t.map(s=>({...s,read:!0}))),f(t=>t.map(s=>({...s,read:!0}))),await x()}catch(t){console.error("Error marking all as read:",t)}},O=w.filter(t=>!t.read).length;return e.jsx(H.Provider,{value:{bellNotifications:w,allNotifications:M,unreadCount:O,getTabs:b,tabs:n,initTab:j,search:k,markAsRead:T,markAllAsRead:_,getLocale:i,messages:g,fetchAllNotifications:P,paginateNotifications:I,loading:E,refreshBellNotifications:A},children:l})},U=()=>{const l=a.useContext(H);if(l===void 0)throw new Error("useNotifications must be used within a NotificationProvider");return l};function le(){const{bellNotifications:l,markAsRead:w,unreadCount:o,refreshBellNotifications:m,messages:u}=U(),[p,f]=a.useState(!1),E=async(n,h)=>{f(!0);try{await w(n,h),await m()}catch(j){console.error("Error marking as read:",j)}finally{f(!1)}},c=n=>{const h=new Date,j=new Date(n),C=h.getTime()-j.getTime(),v=Math.floor(C/1e3),g=new Intl.RelativeTimeFormat("en",{numeric:"auto"});if(v<60)return g.format(-v,"second");const S=Math.floor(v/60);if(S<60)return g.format(-S,"minute");const M=Math.floor(S/60);if(M<24)return g.format(-M,"hour");const x=Math.floor(M/24);if(x<30)return g.format(-x,"day");const i=Math.floor(x/30);if(i<12)return g.format(-i,"month");const A=Math.floor(i/12);return g.format(-A,"year")};return e.jsxs(V,{children:[e.jsx(Y,{asChild:!0,className:"cursor-pointer data-[state=open]:bg-sidebar-accent",children:e.jsxs($,{variant:"ghost",className:"relative",children:[e.jsx(G,{}),o>0&&e.jsx("div",{className:"absolute top-1.5 right-1.5 size-1.5 rounded-full bg-destructive"})]})}),e.jsxs(W,{className:"z-[1002] p-2",align:"end",onCloseAutoFocus:n=>n.preventDefault(),children:[e.jsx(X,{className:`${p?"opacity-50 pointer-events-none":""}`,children:l.length===0?e.jsx("div",{className:"p-4 text-center text-muted-foreground",children:"No notifications"}):l.map(n=>e.jsxs("div",{children:[e.jsx(Z,{asChild:!0,className:"cursor-pointer",onSelect:h=>{h.preventDefault(),Q.visit(`${window.routePrefix}/notifications?type=${n.notificationClass}`)},children:e.jsxs("div",{className:"grid grid-cols-[32px_250px] grid-rows-[auto_1fr] items-start gap-x-4 gap-y-2",children:[n.icon?e.jsx(ce,{name:n.icon.icon,style:{color:n.icon.iconColor},className:"!text-[32px]"}):e.jsx("div",{}),e.jsxs("div",{className:"flex flex-col",children:[e.jsx("span",{className:"font-medium",children:n.title}),e.jsx("span",{className:"truncate",children:n.message})]}),e.jsxs("div",{className:"col-start-2 flex justify-between flex-nowrap items-center",children:[e.jsx("div",{className:"flex flex-nowrap gap-2 items-center",children:e.jsx("div",{children:c(n.createdAt)})}),e.jsxs(L,{children:[e.jsx(R,{asChild:!0,children:e.jsx($,{variant:"ghost",size:"icon",className:"size-4",onClick:h=>{h.stopPropagation(),E(n.notificationClass,n.id)},children:e.jsx(K,{className:"text-primary"})})}),e.jsx(B,{side:"left",className:"z-[1003]",children:e.jsx("p",{children:u["Make read"]})})]})]})]})}),e.jsx(ee,{})]},n.id))}),e.jsx($,{variant:"secondary",asChild:!0,children:e.jsxs(F,{href:`${window.routePrefix}/notifications`,className:`w-full ${p?"opacity-50 pointer-events-none":""}`,children:[u["View All"],p&&e.jsx(D,{className:"h-4 w-4 animate-spin"})]})})]})]})}const de=()=>{if(!(typeof window>"u"))return window.__adminizerAiAssistantState__??void 0},ue=l=>{typeof window>"u"||(window.__adminizerAiAssistantState__=l)},q=a.createContext(void 0),Ne=({children:l})=>{const o=z().props.aiAssistant,m=a.useMemo(()=>de(),[]),[u,p]=a.useState(()=>(m==null?void 0:m.isOpen)??!1),[f,E]=a.useState([]),[c,n]=a.useState(()=>(m==null?void 0:m.activeModel)??(o==null?void 0:o.defaultModel)??void 0),[h,j]=a.useState([]),[C,v]=a.useState(!1),[g,S]=a.useState(!1),[M,x]=a.useState(null),i=(o==null?void 0:o.enabled)??!1,A=a.useCallback(async()=>{if(i)try{v(!0);const{data:s}=await y.get(`${window.routePrefix}/api/ai-assistant/models`);E(s),n(r=>{var N;return r||(o!=null&&o.defaultModel&&s.some(J=>J.id===o.defaultModel)?o.defaultModel:(N=s[0])==null?void 0:N.id)})}catch(s){console.error("Failed to load AI assistant models",s),x("Unable to load AI assistant models")}finally{v(!1)}},[o==null?void 0:o.defaultModel,i]),b=a.useCallback(async s=>{if(!(!i||!s))try{v(!0);const{data:r}=await y.get(`${window.routePrefix}/api/ai-assistant/history/${s}`);j(r.history??[])}catch(r){console.error("Failed to load AI assistant history",r),x("Unable to load AI assistant history")}finally{v(!1)}},[i]);a.useEffect(()=>{if(!i){j([]);return}A()},[A,i]),a.useEffect(()=>{!i||!c||b(c)},[c,b,i]);const k=a.useCallback(s=>{n(s)},[]),P=a.useCallback(()=>p(!0),[]),I=a.useCallback(()=>p(!1),[]),T=a.useCallback(()=>p(s=>!s),[]),_=a.useCallback(async s=>{if(!i||!c)return;const r=s.trim();if(!r)return;const d={id:`tmp-${Date.now()}`,role:"user",content:r,timestamp:new Date().toISOString(),modelId:c};j(N=>[...N,d]),S(!0),x(null);try{const{data:N}=await y.post(`${window.routePrefix}/api/ai-assistant/query`,{modelId:c,message:r});j(N.history??[])}catch(N){console.error("Failed to send AI assistant message",N),x("Unable to reach AI assistant"),await b(c)}finally{S(!1)}},[c,b,i]),O=a.useCallback(async()=>{c&&await b(c)},[c,b]);a.useEffect(()=>{i||p(!1)},[i]),a.useEffect(()=>{ue({isOpen:u,activeModel:c})},[c,u]);const t=a.useMemo(()=>({isEnabled:i,isOpen:u,openChat:P,closeChat:I,toggleChat:T,models:f,activeModel:c,setActiveModel:k,messages:h,loading:C,sending:g,error:M,sendMessage:_,refreshHistory:O}),[c,I,M,i,u,C,h,f,P,O,_,g,k,T]);return e.jsx(q.Provider,{value:t,children:l})},fe=()=>{const l=a.useContext(q);if(!l)throw new Error("useAiAssistant must be used within an AiAssistantProvider");return l};function me(){const{isEnabled:l,isOpen:w,toggleChat:o,models:m,sending:u,loading:p}=fe();if(!l)return null;const f=m.length>0;return e.jsx(e.Fragment,{children:e.jsxs(L,{children:[e.jsx(R,{asChild:!0,children:e.jsx($,{variant:"ghost",className:se("relative",{"text-primary":w}),onClick:o,"aria-expanded":w,"aria-haspopup":"true","aria-controls":"ai-assistant-panel",disabled:!f&&p,children:u?e.jsx(D,{className:"size-4 animate-spin"}):e.jsx(te,{className:"size-4"})})}),e.jsx(B,{side:"bottom",className:"z-[1002]",children:e.jsx("span",{children:"AI assistant"})})]})})}function pe({breadcrumbs:l=[]}){const{tabs:w}=U(),o=z();return e.jsx("header",{className:"border-sidebar-border/50 flex h-16 shrink-0 items-center gap-2 border-b px-6 transition-[width,height] ease-linear group-has-data-[collapsible=icon]/sidebar-wrapper:h-12 md:px-4",children:e.jsxs("div",{className:"flex justify-between w-full",children:[e.jsxs("div",{className:"flex items-center gap-2",children:[e.jsx(ae,{className:"-ml-1"}),e.jsx(oe,{breadcrumbs:l})]}),e.jsxs("div",{className:"flex gap-4 items-center",children:[e.jsx(me,{}),o.props.history&&e.jsx(F,{href:`${window.routePrefix}/history/view-all`,children:e.jsx($,{variant:"ghost",size:"icon",className:"shrink-0",children:e.jsx(re,{})})}),e.jsx(ie,{}),o.props.notifications&&(w===null?e.jsx("div",{className:"w-[40px] flex-none flex justify-center",children:e.jsx(D,{className:"size-4 animate-spin"})}):w.length?e.jsx(le,{}):null),e.jsx(ne,{})]})]})})}const be=Object.freeze(Object.defineProperty({__proto__:null,AppSidebarHeader:pe},Symbol.toStringTag,{value:"Module"}));export{pe as A,ve as N,fe as a,Ne as b,be as c,U as u};
1
+ import{u as z,j as e,h as y,aV as V,s as Y,B as $,aW as G,w as Q,x as W,aX as X,N as L,O as R,E as Z,Q as B,r as K,aY as ee,ai as F,L as D,ao as te,aq as se,aZ as ae,a_ as re}from"./app.js";import{Breadcrumbs as oe}from"./breadcrumbs-Df-vVsyM.js";import{NavUser as ne}from"./nav-user-PtK5V1sV.js";import{ThemeSwitcher as ie}from"./theme-switcher-Ca0SixmO.js";import{r as a}from"./handsontable-PxYdjN8c.js";import ce from"./material-icon-BXxpxGAd.js";const H=a.createContext(void 0),ve=({children:l})=>{const[w,o]=a.useState([]),[m,u]=a.useState([]),[p,f]=a.useState([]),[E,c]=a.useState(!1),[n,h]=a.useState(null),[j,C]=a.useState(""),v=z(),[g,S]=a.useState({}),M=[...m,...p],x=async()=>{try{const t=await y.get(`${window.routePrefix}/notifications/api`,{params:{unreadOnly:!0,limit:4}});o(t.data)}catch(t){console.error("Error fetching bell notifications:",t)}},i=async()=>{try{const t=await y.post(`${window.routePrefix}/notifications`);S(t.data)}catch(t){console.log(t)}},A=async()=>{await x()},b=async()=>{try{const t=await y.get(`${window.routePrefix}/notifications/api/get-classes`);t.data&&(h(t.data.activeServices),C(t.data.initTab))}catch(t){console.error("Error fetching tabs:",t)}},k=async(t,s)=>{try{if(!t){await P(s);return}const r=await y.post(`${window.routePrefix}/notifications/api/search`,{s:t,notificationClass:s});f(r.data)}catch(r){console.error("Error searching notifications:",r)}},P=async t=>{c(!0);try{const s=`${window.routePrefix}/notifications/api/${t}`,r=await y.get(s,{params:{limit:20,skip:0,unreadOnly:!1}});return u([]),f(r.data),r.data}catch(s){return console.error("Error fetching all notifications:",s),[]}finally{c(!1)}},I=async(t,s)=>{try{const r=`${window.routePrefix}/notifications/api/${t}`,d=await y.get(r,{params:{limit:20,skip:s,unreadOnly:!1}});return f(N=>[...N,...d.data]),d.data}catch(r){return console.error("Error paginating notifications:",r),[]}};a.useEffect(()=>{if(!v.props.notifications)return;i(),x();const t=new EventSource(`${window.routePrefix}/notifications/api/stream`);return t.addEventListener("connected",s=>{const r=JSON.parse(s.data);console.log("Connected event:",r),b()}),t.addEventListener("notification",s=>{const r=JSON.parse(s.data);u(d=>[r,...d]),o(d=>[r,...d].slice(0,4))}),t.onerror=()=>{console.error("SSE connection error")},()=>t.close()},[]);const T=async(t,s)=>{try{await y.put(`${window.routePrefix}/notifications/api/${t}/${s}/read`,{}),u(r=>r.map(d=>d.id===s?{...d,read:!0}:d)),f(r=>r.map(d=>d.id===s?{...d,read:!0}:d)),o([])}catch(r){console.error("Error marking as read:",r)}},_=async()=>{try{await y.put(`${window.routePrefix}/notifications/api/read-all`),u(t=>t.map(s=>({...s,read:!0}))),f(t=>t.map(s=>({...s,read:!0}))),await x()}catch(t){console.error("Error marking all as read:",t)}},O=w.filter(t=>!t.read).length;return e.jsx(H.Provider,{value:{bellNotifications:w,allNotifications:M,unreadCount:O,getTabs:b,tabs:n,initTab:j,search:k,markAsRead:T,markAllAsRead:_,getLocale:i,messages:g,fetchAllNotifications:P,paginateNotifications:I,loading:E,refreshBellNotifications:A},children:l})},U=()=>{const l=a.useContext(H);if(l===void 0)throw new Error("useNotifications must be used within a NotificationProvider");return l};function le(){const{bellNotifications:l,markAsRead:w,unreadCount:o,refreshBellNotifications:m,messages:u}=U(),[p,f]=a.useState(!1),E=async(n,h)=>{f(!0);try{await w(n,h),await m()}catch(j){console.error("Error marking as read:",j)}finally{f(!1)}},c=n=>{const h=new Date,j=new Date(n),C=h.getTime()-j.getTime(),v=Math.floor(C/1e3),g=new Intl.RelativeTimeFormat("en",{numeric:"auto"});if(v<60)return g.format(-v,"second");const S=Math.floor(v/60);if(S<60)return g.format(-S,"minute");const M=Math.floor(S/60);if(M<24)return g.format(-M,"hour");const x=Math.floor(M/24);if(x<30)return g.format(-x,"day");const i=Math.floor(x/30);if(i<12)return g.format(-i,"month");const A=Math.floor(i/12);return g.format(-A,"year")};return e.jsxs(V,{children:[e.jsx(Y,{asChild:!0,className:"cursor-pointer data-[state=open]:bg-sidebar-accent",children:e.jsxs($,{variant:"ghost",className:"relative",children:[e.jsx(G,{}),o>0&&e.jsx("div",{className:"absolute top-1.5 right-1.5 size-1.5 rounded-full bg-destructive"})]})}),e.jsxs(Q,{className:"z-[1002] p-2",align:"end",onCloseAutoFocus:n=>n.preventDefault(),children:[e.jsx(W,{className:`${p?"opacity-50 pointer-events-none":""}`,children:l.length===0?e.jsx("div",{className:"p-4 text-center text-muted-foreground",children:"No notifications"}):l.map(n=>e.jsxs("div",{children:[e.jsx(X,{asChild:!0,className:"cursor-pointer",onSelect:h=>{h.preventDefault(),K.visit(`${window.routePrefix}/notifications?type=${n.notificationClass}`)},children:e.jsxs("div",{className:"grid grid-cols-[32px_250px] grid-rows-[auto_1fr] items-start gap-x-4 gap-y-2",children:[n.icon?e.jsx(ce,{name:n.icon.icon,style:{color:n.icon.iconColor},className:"!text-[32px]"}):e.jsx("div",{}),e.jsxs("div",{className:"flex flex-col",children:[e.jsx("span",{className:"font-medium",children:n.title}),e.jsx("span",{className:"truncate",children:n.message})]}),e.jsxs("div",{className:"col-start-2 flex justify-between flex-nowrap items-center",children:[e.jsx("div",{className:"flex flex-nowrap gap-2 items-center",children:e.jsx("div",{children:c(n.createdAt)})}),e.jsxs(L,{children:[e.jsx(R,{asChild:!0,children:e.jsx($,{variant:"ghost",size:"icon",className:"size-4",onClick:h=>{h.stopPropagation(),E(n.notificationClass,n.id)},children:e.jsx(Z,{className:"text-primary"})})}),e.jsx(B,{side:"left",className:"z-[1003]",children:e.jsx("p",{children:u["Make read"]})})]})]})]})}),e.jsx(ee,{})]},n.id))}),e.jsx($,{variant:"secondary",asChild:!0,children:e.jsxs(F,{href:`${window.routePrefix}/notifications`,className:`w-full ${p?"opacity-50 pointer-events-none":""}`,children:[u["View All"],p&&e.jsx(D,{className:"h-4 w-4 animate-spin"})]})})]})]})}const de=()=>{if(!(typeof window>"u"))return window.__adminizerAiAssistantState__??void 0},ue=l=>{typeof window>"u"||(window.__adminizerAiAssistantState__=l)},q=a.createContext(void 0),Ne=({children:l})=>{const o=z().props.aiAssistant,m=a.useMemo(()=>de(),[]),[u,p]=a.useState(()=>(m==null?void 0:m.isOpen)??!1),[f,E]=a.useState([]),[c,n]=a.useState(()=>(m==null?void 0:m.activeModel)??(o==null?void 0:o.defaultModel)??void 0),[h,j]=a.useState([]),[C,v]=a.useState(!1),[g,S]=a.useState(!1),[M,x]=a.useState(null),i=(o==null?void 0:o.enabled)??!1,A=a.useCallback(async()=>{if(i)try{v(!0);const{data:s}=await y.get(`${window.routePrefix}/api/ai-assistant/models`);E(s),n(r=>{var N;return r||(o!=null&&o.defaultModel&&s.some(J=>J.id===o.defaultModel)?o.defaultModel:(N=s[0])==null?void 0:N.id)})}catch(s){console.error("Failed to load AI assistant models",s),x("Unable to load AI assistant models")}finally{v(!1)}},[o==null?void 0:o.defaultModel,i]),b=a.useCallback(async s=>{if(!(!i||!s))try{v(!0);const{data:r}=await y.get(`${window.routePrefix}/api/ai-assistant/history/${s}`);j(r.history??[])}catch(r){console.error("Failed to load AI assistant history",r),x("Unable to load AI assistant history")}finally{v(!1)}},[i]);a.useEffect(()=>{if(!i){j([]);return}A()},[A,i]),a.useEffect(()=>{!i||!c||b(c)},[c,b,i]);const k=a.useCallback(s=>{n(s)},[]),P=a.useCallback(()=>p(!0),[]),I=a.useCallback(()=>p(!1),[]),T=a.useCallback(()=>p(s=>!s),[]),_=a.useCallback(async s=>{if(!i||!c)return;const r=s.trim();if(!r)return;const d={id:`tmp-${Date.now()}`,role:"user",content:r,timestamp:new Date().toISOString(),modelId:c};j(N=>[...N,d]),S(!0),x(null);try{const{data:N}=await y.post(`${window.routePrefix}/api/ai-assistant/query`,{modelId:c,message:r});j(N.history??[])}catch(N){console.error("Failed to send AI assistant message",N),x("Unable to reach AI assistant"),await b(c)}finally{S(!1)}},[c,b,i]),O=a.useCallback(async()=>{c&&await b(c)},[c,b]);a.useEffect(()=>{i||p(!1)},[i]),a.useEffect(()=>{ue({isOpen:u,activeModel:c})},[c,u]);const t=a.useMemo(()=>({isEnabled:i,isOpen:u,openChat:P,closeChat:I,toggleChat:T,models:f,activeModel:c,setActiveModel:k,messages:h,loading:C,sending:g,error:M,sendMessage:_,refreshHistory:O}),[c,I,M,i,u,C,h,f,P,O,_,g,k,T]);return e.jsx(q.Provider,{value:t,children:l})},fe=()=>{const l=a.useContext(q);if(!l)throw new Error("useAiAssistant must be used within an AiAssistantProvider");return l};function me(){const{isEnabled:l,isOpen:w,toggleChat:o,models:m,sending:u,loading:p}=fe();if(!l)return null;const f=m.length>0;return e.jsx(e.Fragment,{children:e.jsxs(L,{children:[e.jsx(R,{asChild:!0,children:e.jsx($,{variant:"ghost",className:se("relative",{"text-primary":w}),onClick:o,"aria-expanded":w,"aria-haspopup":"true","aria-controls":"ai-assistant-panel",disabled:!f&&p,children:u?e.jsx(D,{className:"size-4 animate-spin"}):e.jsx(te,{className:"size-4"})})}),e.jsx(B,{side:"bottom",className:"z-[1002]",children:e.jsx("span",{children:"AI assistant"})})]})})}function pe({breadcrumbs:l=[]}){const{tabs:w}=U(),o=z();return e.jsx("header",{className:"border-sidebar-border/50 flex h-16 shrink-0 items-center gap-2 border-b px-6 transition-[width,height] ease-linear group-has-data-[collapsible=icon]/sidebar-wrapper:h-12 md:px-4",children:e.jsxs("div",{className:"flex justify-between w-full",children:[e.jsxs("div",{className:"flex items-center gap-2",children:[e.jsx(ae,{className:"-ml-1"}),e.jsx(oe,{breadcrumbs:l})]}),e.jsxs("div",{className:"flex gap-4 items-center",children:[e.jsx(me,{}),o.props.history&&e.jsx(F,{href:`${window.routePrefix}/history/view-all`,children:e.jsx($,{variant:"ghost",size:"icon",className:"shrink-0",children:e.jsx(re,{})})}),e.jsx(ie,{}),o.props.notifications&&(w===null?e.jsx("div",{className:"w-[40px] flex-none flex justify-center",children:e.jsx(D,{className:"size-4 animate-spin"})}):w.length?e.jsx(le,{}):null),e.jsx(ne,{})]})]})})}const be=Object.freeze(Object.defineProperty({__proto__:null,AppSidebarHeader:pe},Symbol.toStringTag,{value:"Module"}));export{pe as A,ve as N,fe as a,Ne as b,be as c,U as u};
package/assets/app.js CHANGED
@@ -1,4 +1,4 @@
1
- const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["./add-group-sofsuFYA.js","./app-layout-DM2_7wxW.js","./app-shell-CwiL9UZ5.js","./handsontable-PxYdjN8c.js","./jsoneditor-De1FvcYu.js","./monaco-BhBYtg3d.js","./app-sidebar-C7TXiSvV.js","./nav-main-G6VwCche.js","./material-icon-DZVU9Gse.js","./app-sidebar-header-qHEOMq5D.js","./breadcrumbs-D5PCyRGn.js","./nav-user-BfROibnw.js","./user-info-gFSwypEN.js","./user-menu-content-CjsydEH4.js","./theme-switcher-BURZ8Tza.js","./icon-FyVrxiPs.js","./add-group-form-DUhDxVwB.js","./add-user-DM1nsN83.js","./add-user-form-Ct4i6Dse.js","./input-error-cgnQ235Q.js","./add-D9qTFgIT.js","./add-form-Nn7zuSFW.js","./field-renderer-Ddc4u-gC.js","./dynamic-controls-k61T9W2P.js","./field-renderer-DV8OITPR.css","./DiffViewer-DL5uCv8d.js","./catalog-BIwiWMeW.js","./del-modal-yU9LPEgz.js","./catalog-D4n6dpGl.css","./dashboard-C2Y09gw1.js","./dashboard-BOltB2Hq.css","./form-P1bFGHCF.js","./form-G2lvZbid.js","./history-DHZfSpf_.js","./home-Do0C-Tzu.js","./init-user-DhzPzTRM.js","./list-D72uhn00.js","./list-table-BxVhDSbv.js","./pagination-render-CqNIIF8P.js","./login-Cla-c7nv.js","./module-DI6zzr4C.js","./notification-BZzAyhJ1.js","./tabs-BhUuWdzc.js","./register-Bt0RP4PE.js","./welcome-8dJL4cIX.js"])))=>i.map(i=>d[i]);
1
+ const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["./add-group-Bg5tLxYu.js","./app-layout-CbRvDFF3.js","./app-shell-DbPu3ZPM.js","./handsontable-PxYdjN8c.js","./jsoneditor-De1FvcYu.js","./monaco-BhBYtg3d.js","./app-sidebar-CQqvkGH0.js","./nav-main-DcvkRp44.js","./material-icon-BXxpxGAd.js","./app-sidebar-header-C8sntqs3.js","./breadcrumbs-Df-vVsyM.js","./nav-user-PtK5V1sV.js","./user-info-BTJNUzpi.js","./user-menu-content-DUnYpt8t.js","./theme-switcher-Ca0SixmO.js","./icon-BTIjB9Wk.js","./add-group-form-B7c4coU-.js","./add-user-H6XsOKX_.js","./add-user-form-BXSGx38D.js","./input-error-CSrUHo1P.js","./add-C_-KTZY-.js","./add-form-BdmoVC_G.js","./field-renderer-C1uKgcGe.js","./dynamic-controls-k61T9W2P.js","./field-renderer-DV8OITPR.css","./DiffViewer-B36sF5l-.js","./catalog-BsRePE_I.js","./del-modal-TaroxmfE.js","./catalog-D4n6dpGl.css","./dashboard-Bynx-P6M.js","./dashboard-BOltB2Hq.css","./form-D6rF7waX.js","./form-BjOpJfcr.js","./history-DL0tB2tZ.js","./home-CADtJAH_.js","./init-user-CsEDYKZe.js","./list-B3Ki-psl.js","./list-table-DSRvmzBT.js","./pagination-render-B5A4YOfb.js","./login-BfN1lJT1.js","./module-B5hkMJ4M.js","./notification-D1_TtX__.js","./tabs-DTgMEGE8.js","./register-C2TFSMX0.js","./welcome-AlKSDf1S.js"])))=>i.map(i=>d[i]);
2
2
  import{a as cee,c as UH,b as xa,s as Ma,d as ga,i as Mi,h as SF,m as Rj,e as see,f as lee,z as dee,v as uee,_ as vn}from"./jsoneditor-De1FvcYu.js";import{r as p,e as ke,a as Kd,b as CF,c as hee,R as MP,d as ur,F as Ca,f as Na,g as La,h as Ea,i as Ia,j as Aa,k as Ta,l as Ra,m as $a,n as ja,o as Pa,p as Oa,q as Da,s as za,t as qa,u as Ha,v as Va,w as Ba,x as Fa,y as Ua,z as Ga,A as Wa,B as Za,C as Xa,D as Ka,E as Ya,G as Qa,H as Ja,I as eo,J as to,K as no,L as ao,M as oo,N as ro,O as io,P as co,Q as so,S as lo,T as uo,U as ho,V as po,W as fo,X as yo,Y as mo,Z as vo,_ as ko,$ as go,a0 as Mo,a1 as xo,a2 as bo,a3 as wo,a4 as _o,a5 as So,a6 as Co,a7 as No,a8 as Lo,a9 as Eo,aa as Io,ab as Ao,ac as To,ad as Ro,ae as $o,af as jo,ag as Po,ah as Oo,ai as Do,aj as zo,ak as qo,al as Ho,am as Vo,an as Bo,ao as Fo,ap as Yd,aq as Qd,ar as Jd,as as pee,at as fee,au as yee,av as mee,aw as vee,ax as kee,ay as gee,az as Mee}from"./handsontable-PxYdjN8c.js";import{F as xee}from"./monaco-BhBYtg3d.js";var a$={exports:{}},e2={};/**
3
3
  * @license React
4
4
  * react-jsx-runtime.production.js
@@ -8070,4 +8070,4 @@ For more information, see https://radix-ui.com/primitives/docs/components/${t.do
8070
8070
  * Last updated: Mar 09, 2023
8071
8071
  *
8072
8072
  * Description: Definition file for Chinese - China language-country.
8073
- */const PHe={languageCode:"zh-CN",[Fo]:"上方插入行",[Bo]:"下方插入行",[Vo]:"左方插入列",[Ho]:"右方插入列",[qo]:["移除该行","移除多行"],[zo]:["移除该列","移除多列"],[Do]:"撤销",[Oo]:"恢复",[Po]:"只读",[jo]:"清空该列",[$o]:"对齐",[Ro]:"左对齐",[To]:"水平居中",[Ao]:"右对齐",[Io]:"两端对齐",[Eo]:"顶端对齐",[Lo]:"垂直居中",[No]:"底端对齐",[Co]:"冻结该列",[So]:"取消冻结",[_o]:"边框",[wo]:"上",[bo]:"右",[xo]:"下",[Mo]:"左",[go]:"移除边框",[ko]:"插入批注",[vo]:"编辑批注",[mo]:"删除批注",[yo]:"只读批注",[fo]:"合并",[po]:"取消合并",[ho]:"复制",[Jd]:"带标题的复制",[Qd]:"带标题组的复制",[Yd]:"仅复制标题",[uo]:"剪切",[lo]:"插入子行",[so]:"与母行分离",[co]:["隐藏该列","隐藏多列"],[io]:["显示该列","显示多列"],[ro]:["隐藏该行","隐藏多行"],[oo]:["显示该行","显示多行"],[ao]:"无",[no]:"为空",[to]:"不为空",[eo]:"等于",[Ja]:"不等于",[Qa]:"开头是",[Ya]:"结尾是",[Ka]:"包含",[Xa]:"不包含",[Za]:"大于",[Wa]:"大于或等于",[Ga]:"小于",[Ua]:"小于或等于",[Fa]:"在此范围",[Ba]:"不在此范围",[Va]:"之后",[Ha]:"之前",[qa]:"今天",[za]:"明天",[Da]:"昨天",[Oa]:"空白单元格",[Pa]:"按条件过滤",[ja]:"按值过滤",[$a]:"且",[Ra]:"或",[Ta]:"全选",[Aa]:"清除",[Ia]:"确认",[Ea]:"取消",[La]:"搜索",[Na]:"值",[Ca]:"第二值"};mee();const bF={de:CHe,en:gee,es:NHe,fr:LHe,it:EHe,ja:IHe,ko:AHe,nl:THe,pl:RHe,pt:$He,ru:jHe,zh:PHe},OHe=document.documentElement.lang,ZY=bF[OHe]??bF.en;vee(ZY);const XY=({config:e,data:t=[],onChange:a,disabled:o})=>{const{appearance:i}=JO(),[s,l]=p.useState("ht-theme-main"),[h,f]=p.useState(!1),y=p.useCallback((m,x)=>{var b,w;if(x==="loadData")return;const S=(w=(b=k.current)==null?void 0:b.hotInstance)==null?void 0:w.getSourceData();a(S)},[]),k=p.useRef(null);return p.useEffect(()=>{const m=setTimeout(()=>{var x;(x=k.current)!=null&&x.hotInstance&&(k.current.hotInstance.loadData(t??[]),f(!0))},100);return()=>clearTimeout(m)},[t]),p.useEffect(()=>{l(i==="dark"?"ht-theme-main-dark":"ht-theme-main")},[i]),M.jsx("div",{style:{opacity:h?1:0},children:M.jsx(kee,{className:o?"pointer-events-none opacity-50":"",themeName:s,language:ZY.languageCode,ref:k,...e,afterChange:y,children:e.columns.map(m=>M.jsx(Mee,{data:m.data,...m},m.data))})})},vVe=Object.freeze(Object.defineProperty({__proto__:null,default:XY},Symbol.toStringTag,{value:"Module"})),DHe=()=>{const[e,t]=p.useState({width:typeof window<"u"?window.innerWidth:1024,height:typeof window<"u"?window.innerHeight:768});return p.useEffect(()=>{if(typeof window>"u")return;const a=()=>{t({width:window.innerWidth,height:window.innerHeight})};return window.addEventListener("resize",a),()=>window.removeEventListener("resize",a)},[]),e},KY=({onChange:e,value:t,options:a,disabled:o})=>{const{appearance:i}=JO(),[s,l]=p.useState("light"),h=p.useRef(null),f=p.useRef(null),{width:y}=DHe(),k=y<768,m=y>=768&&y<1024,x=_=>{e(_)},S=_=>{h.current=_,b()},b=()=>{var N;if(!h.current)return;const _={minimap:{enabled:!k},fontSize:k?12:m?13:14,lineNumbers:k?"off":"on",lineDecorationsWidth:k?5:10,scrollBeyondLastLine:!k,wordWrap:k?"on":"bounded",renderWhitespace:k?"none":"selection",padding:{top:k?8:16,bottom:k?8:16}};h.current.updateOptions(_),(N=f.current)==null||N.classList.add("overflow-hidden"),setTimeout(()=>{var L,I;(L=h.current)==null||L.layout(),(I=f.current)==null||I.classList.remove("overflow-hidden")},100)};p.useEffect(()=>{l(i==="dark"?"vs-dark":"light")},[i]),p.useEffect(()=>{b()},[y]);const w=k?"300px":m?"400px":"500px";return M.jsx("div",{className:`border rounded-lg ${k?"p-1":"p-2"}`,ref:f,children:M.jsx(xee,{height:w,language:a.language,value:t,theme:s,options:{automaticLayout:!0,...k&&{wordWrap:"on"},minimap:{enabled:!k}},onChange:x,onMount:S,className:`transition-all duration-200 ease-in-out ${o?"pointer-events-none opacity-50 cursor-not-allowed":""}`})})},kVe=Object.freeze(Object.defineProperty({__proto__:null,default:KY},Symbol.toStringTag,{value:"Module"})),wF=gA("m-1 flex items-center border rounded-sm px-1",{variants:{variant:{default:"border-foreground/10 text-foreground bg-card hover:bg-card/80",secondary:"border-foreground/10 bg-secondary text-secondary-foreground hover:bg-secondary/80",destructive:"border-transparent bg-destructive text-destructive-foreground hover:bg-destructive/80",inverted:"inverted"}},defaultVariants:{variant:"default"}}),eD=p.forwardRef(({options:e,onValueChange:t,variant:a,processing:o,disabled:i,defaultValue:s=[],placeholder:l="",notFound:h="",search:f="",animation:y=0,maxCount:k=3,modalPopover:m=!1,asChild:x=!1,className:S,mode:b="multiple",...w},_)=>{const[N,L]=p.useState(s),[I,j]=p.useState(!1),[O,P]=p.useState(!1);p.useEffect(()=>{s&&L(s)},[s]);const A=q=>{if(q.key==="Enter")j(!0);else if(q.key==="Backspace"&&!q.currentTarget.value){const B=[...N];B.pop(),L(B),t(B)}},$=q=>{let B;b==="single"?B=N.includes(q)?[]:[q]:B=N.includes(q)?N.filter(Y=>Y!==q):[...N,q],L(B),t(B),b==="single"&&j(!1)},F=()=>{L([]),t([])},X=()=>{j(q=>!q)},H=()=>{const q=N.slice(0,k);L(q),t(q)};return M.jsxs(gK,{open:I,onOpenChange:j,modal:m,children:[M.jsx(MK,{asChild:!0,children:M.jsx(MA,{ref:_,...w,onClick:X,disabled:i,className:te("flex w-full p-1 rounded-md border-input border-1 min-h-10 h-auto items-center justify-between bg-inherit hover:bg-inherit [&_svg]:pointer-events-auto",S),children:N.length>0?M.jsxs("div",{className:"flex justify-between items-center w-full",children:[M.jsxs("div",{className:"flex flex-wrap items-center",children:[N.slice(0,k).map(q=>{const B=e.find(ue=>ue.value===q),Y=B==null?void 0:B.icon;return M.jsxs("div",{className:te(O?"animate-bounce":"",wF({variant:a})),style:{animationDuration:`${y}s`},children:[Y&&M.jsx(Y,{className:"h-4 w-4 mr-2"}),B==null?void 0:B.label,M.jsx(Or,{className:"ml-2 h-4 w-4 cursor-pointer",onClick:ue=>{ue.stopPropagation(),o||$(q)}})]},q)}),b==="multiple"&&N.length>k&&M.jsxs("div",{className:te("bg-transparent text-foreground border-foreground/1 hover:bg-transparent",O?"animate-bounce":"",wF({variant:a})),style:{animationDuration:`${y}s`},children:[`+ ${N.length-k} more`,M.jsx(Or,{className:"ml-2 h-4 w-4 cursor-pointer",onClick:q=>{q.stopPropagation(),H()}})]})]}),M.jsxs("div",{className:"flex items-center justify-between",children:[N.length>0&&M.jsxs(M.Fragment,{children:[M.jsx(bi,{className:"h-4 mx-2 cursor-pointer text-muted-foreground",onClick:q=>{q.stopPropagation(),F()}}),M.jsx(ZO,{orientation:"vertical",className:"flex min-h-6 h-full"})]}),M.jsx(xi,{className:"h-4 mx-2 cursor-pointer text-muted-foreground"})]})]}):M.jsxs("div",{className:"flex items-center justify-between w-full mx-auto",children:[M.jsx("span",{className:"text-sm text-muted-foreground mx-3",children:l}),M.jsx(xi,{className:"h-4 cursor-pointer text-muted-foreground mx-2"})]})})}),M.jsx(xK,{className:"w-auto p-0 z-[1003]",align:"start",onEscapeKeyDown:()=>j(!1),children:M.jsxs(sO,{children:[M.jsx(zW,{placeholder:f,onKeyDown:A}),M.jsxs(qW,{children:[M.jsx(HW,{children:h}),M.jsx(VW,{children:e.map(q=>{const B=N.includes(q.value);return M.jsxs(FW,{onSelect:()=>$(q.value),className:"cursor-pointer",children:[M.jsx("div",{className:te("mr-2 flex h-5 w-5 items-center justify-center rounded border border-primary",B?"bg-primary text-primary-foreground":"opacity-50 [&_svg]:invisible"),children:M.jsx(sr,{className:"h-4 w-4 text-primary-foreground"})}),q.icon&&M.jsx(q.icon,{className:"mr-2 h-4 w-4 text-muted-foreground"}),M.jsx("span",{children:q.label})]},q.value)})}),M.jsx(BW,{})]})]})}),y>0&&N.length>0&&b==="multiple"&&M.jsx(ki,{className:te("cursor-pointer my-2 text-foreground bg-background w-3 h-3",O?"":"text-muted-foreground"),onClick:()=>P(!O)})]})});eD.displayName="MultiSelect";const gVe=Object.freeze(Object.defineProperty({__proto__:null,default:eD},Symbol.toStringTag,{value:"Module"}));function zHe(){window.UIComponents??(window.UIComponents={}),window.JSComponents??(window.JSComponents={}),window.axios=Nt,window.sonner=Xqe,Object.assign(window.UIComponents,{Avatar:Dre,AvatarImage:zre,AvatarFallback:qre,Badge:Vre,Breadcrumb:F_e,BreadcrumbList:U_e,BreadcrumbItem:G_e,BreadcrumbLink:W_e,BreadcrumbPage:Z_e,BreadcrumbSeparator:X_e,BreadcrumbEllipsis:K_e,Button:MA,Calendar:ONe,Card:DNe,CardHeader:zNe,CardFooter:FNe,CardTitle:qNe,CardAction:VNe,CardDescription:HNe,CardContent:BNe,Checkbox:dLe,Collapsible:CLe,CollapsibleTrigger:NLe,CollapsibleContent:LLe,Command:sO,CommandDialog:OIe,CommandInput:zW,CommandList:qW,CommandEmpty:HW,CommandGroup:VW,CommandItem:FW,CommandShortcut:DIe,CommandSeparator:BW,ContextMenu:s$e,ContextMenuTrigger:l$e,ContextMenuContent:m$e,ContextMenuItem:v$e,ContextMenuCheckboxItem:k$e,ContextMenuRadioItem:g$e,ContextMenuLabel:M$e,ContextMenuSeparator:x$e,ContextMenuShortcut:b$e,ContextMenuGroup:d$e,ContextMenuPortal:u$e,ContextMenuSub:h$e,ContextMenuSubContent:y$e,ContextMenuSubTrigger:f$e,ContextMenuRadioGroup:p$e,Dialog:TW,DialogClose:jIe,DialogContent:jW,DialogDescription:DW,DialogFooter:PIe,DialogHeader:PW,DialogOverlay:$W,DialogPortal:RW,DialogTitle:OW,DialogTrigger:$Ie,DialogStack:yX,DialogStackTrigger:S$e,DialogStackOverlay:C$e,DialogStackBody:N$e,DialogStackContent:L$e,DialogStackTitle:E$e,DialogStackDescription:I$e,DialogStackHeader:A$e,DialogStackFooter:T$e,DialogStackNext:R$e,DialogStackPrevious:$$e,DropdownMenu:Mje,DropdownMenuPortal:xje,DropdownMenuTrigger:bje,DropdownMenuContent:wje,DropdownMenuGroup:_je,DropdownMenuLabel:Eje,DropdownMenuItem:Sje,DropdownMenuCheckboxItem:Cje,DropdownMenuRadioGroup:Nje,DropdownMenuRadioItem:Lje,DropdownMenuSeparator:Ije,DropdownMenuShortcut:Aje,DropdownMenuSub:Tje,DropdownMenuSubTrigger:Rje,DropdownMenuSubContent:$je,Input:jX,Label:Oje,Menubar:CPe,MenubarPortal:rK,MenubarMenu:NPe,MenubarTrigger:IPe,MenubarContent:APe,MenubarGroup:LPe,MenubarSeparator:PPe,MenubarLabel:jPe,MenubarItem:TPe,MenubarShortcut:OPe,MenubarCheckboxItem:RPe,MenubarRadioGroup:EPe,MenubarRadioItem:$Pe,MenubarSub:DPe,MenubarSubTrigger:zPe,MenubarSubContent:qPe,Pagination:HPe,PaginationContent:VPe,PaginationLink:FO,PaginationItem:BPe,PaginationPrevious:FPe,PaginationNext:UPe,PaginationEllipsis:GPe,Popover:gK,PopoverTrigger:MK,PopoverContent:xK,PopoverAnchor:mOe,Select:vDe,SelectContent:xDe,SelectGroup:kDe,SelectItem:wDe,SelectLabel:bDe,SelectScrollDownButton:nY,SelectScrollUpButton:tY,SelectSeparator:_De,SelectTrigger:MDe,SelectValue:gDe,Separator:ZO,Sheet:oY,SheetTrigger:EDe,SheetClose:IDe,SheetContent:rY,SheetHeader:iY,SheetFooter:RDe,SheetTitle:cY,SheetDescription:sY,Sidebar:gze,SidebarContent:Nze,SidebarFooter:Sze,SidebarGroup:Lze,SidebarGroupAction:Ize,SidebarGroupContent:Aze,SidebarGroupLabel:Eze,SidebarHeader:_ze,SidebarInput:wze,SidebarInset:bze,SidebarMenu:Tze,SidebarMenuAction:Pze,SidebarMenuBadge:Oze,SidebarMenuButton:jze,SidebarMenuItem:Rze,SidebarMenuSkeleton:Dze,SidebarMenuSub:zze,SidebarMenuSubButton:Hze,SidebarMenuSubItem:qze,SidebarProvider:kze,SidebarRail:xze,SidebarSeparator:Cze,SidebarTrigger:Mze,useSidebar:Y2,Skeleton:hP,Slider:mqe,Toaster:Kqe,Switch:hHe,Table:pHe,TableHeader:fHe,TableBody:yHe,TableFooter:mHe,TableHead:kHe,TableRow:vHe,TableCell:gHe,TableCaption:MHe,Textarea:xHe,Tooltip:xY,TooltipTrigger:bY,TooltipContent:wY,TooltipProvider:YO,VanillaJSONEditor:gP}),Object.assign(window.JSComponents,{VanillaJSONEditor:gP,HandsonTable:XY,MonacoEditor:KY,MultiSelect:eD})}const{createInertiaApp:qHe,router:YY}=HU;window.React=ke;window.ReactDOM=ur;window.InertiajsReact=HU;window.LucideReact=B_e;zHe();async function HHe(e,t){for(const a of Array.isArray(e)?e:[e]){const o=t[a];if(!(typeof o>"u"))return typeof o=="function"?o():o}throw new Error(`Page not found: ${e}`)}let tD=!1;YY.on("navigate",e=>{tD=!0});YY.on("finish",e=>{tD=!1});const _F=document.createElement.bind(document);document.createElement=function(e,t){const a=_F(e,t);return e.toLowerCase()==="iframe"&&tD?(console.warn("[Adminizer] Prevented iframe creation, forcing full page reload"),setTimeout(()=>{window.location.reload()},0),_F("div")):a};qHe({title:e=>`${e}`,resolve:e=>HHe(`./pages/${e}.tsx`,Object.assign({"./pages/add-group.tsx":()=>vn(()=>import("./add-group-sofsuFYA.js"),__vite__mapDeps([0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16]),import.meta.url),"./pages/add-user.tsx":()=>vn(()=>import("./add-user-DM1nsN83.js"),__vite__mapDeps([17,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,18,19]),import.meta.url),"./pages/add.tsx":()=>vn(()=>import("./add-D9qTFgIT.js"),__vite__mapDeps([20,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,21,22,23,24,19,25]),import.meta.url),"./pages/catalog.tsx":()=>vn(()=>import("./catalog-BIwiWMeW.js"),__vite__mapDeps([26,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,27,21,22,23,24,19,25,28]),import.meta.url),"./pages/dashboard.tsx":()=>vn(()=>import("./dashboard-C2Y09gw1.js"),__vite__mapDeps([29,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,30]),import.meta.url),"./pages/form.tsx":()=>vn(()=>import("./form-P1bFGHCF.js"),__vite__mapDeps([31,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,32,21,22,23,24,19,25]),import.meta.url),"./pages/history.tsx":()=>vn(()=>import("./history-DHZfSpf_.js"),__vite__mapDeps([33,3,4,25,1,2,5,6,7,8,9,10,11,12,13,14,15]),import.meta.url),"./pages/home.tsx":()=>vn(()=>import("./home-Do0C-Tzu.js"),__vite__mapDeps([34,4,3,5]),import.meta.url),"./pages/init-user.tsx":()=>vn(()=>import("./init-user-DhzPzTRM.js"),__vite__mapDeps([35,3,4,19,5]),import.meta.url),"./pages/list.tsx":()=>vn(()=>import("./list-D72uhn00.js"),__vite__mapDeps([36,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,37,27,38]),import.meta.url),"./pages/login.tsx":()=>vn(()=>import("./login-Cla-c7nv.js"),__vite__mapDeps([39,15,4,3,5,19]),import.meta.url),"./pages/module.tsx":()=>vn(()=>import("./module-DI6zzr4C.js"),__vite__mapDeps([40,3,4,1,2,5,6,7,8,9,10,11,12,13,14,15]),import.meta.url),"./pages/notification.tsx":()=>vn(()=>import("./notification-BZzAyhJ1.js"),__vite__mapDeps([41,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,42]),import.meta.url),"./pages/register.tsx":()=>vn(()=>import("./register-Bt0RP4PE.js"),__vite__mapDeps([43,3,4,19,5]),import.meta.url),"./pages/welcome.tsx":()=>vn(()=>import("./welcome-8dJL4cIX.js"),__vite__mapDeps([44,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15]),import.meta.url)})),setup({el:e,App:t,props:a}){Noe.createRoot(e).render(M.jsx(t,{...a}))},progress:{color:"#0f4898"}});export{MK as $,v$e as A,MA as B,lr as C,yX as D,s5 as E,DNe as F,zNe as G,qNe as H,jX as I,FNe as J,YO as K,Fs as L,xY as M,bY as N,wY as O,I9 as P,hHe as Q,S$e as R,vDe as S,Kqe as T,E$e as U,hr as V,uj as W,c2 as X,s2 as Y,wSe as Z,gK as _,i5 as a,_ze as a$,lv as a0,W1 as a1,xK as a2,ONe as a3,pHe as a4,fHe as a5,vHe as a6,kHe as a7,yHe as a8,gHe as a9,PIe as aA,jIe as aB,yf as aC,Kp as aD,ef as aE,of as aF,$Ie as aG,Rs as aH,kt as aI,z2 as aJ,bn as aK,It as aL,xZ as aM,bZ as aN,xe as aO,Pn as aP,DA as aQ,O7 as aR,fM as aS,kze as aT,Mje as aU,gy as aV,Sje as aW,Ije as aX,Mze as aY,U8 as aZ,gze as a_,vc as aa,TW as ab,jW as ac,PW as ad,OW as ae,vG as af,moe as ag,koe as ah,$U as ai,hVe as aj,jE as ak,Rx as al,bze as am,vl as an,bi as ao,YU as ap,xHe as aq,DHe as ar,JO as as,cb as at,B8 as au,v_ as av,sr as aw,UL as ax,M1 as ay,te as az,Oje as b,Tze as b0,Rze as b1,CPe as b2,NPe as b3,IPe as b4,jze as b5,Qv as b6,APe as b7,DPe as b8,zPe as b9,Dre as bA,zre as bB,qre as bC,Eje as bD,jx as bE,yVe as bF,fVe as bG,pVe as bH,eD as bI,mqe as bJ,Un as bK,c7 as bL,dVe as bM,lf as bN,v2 as bO,r1 as bP,__ as bQ,HPe as bR,VPe as bS,BPe as bT,FO as bU,FPe as bV,UPe as bW,mVe as bX,vVe as bY,kVe as bZ,gVe as b_,qPe as ba,TPe as bb,Lze as bc,HG as bd,NLe as be,FG as bf,zze as bg,qze as bh,Hze as bi,Nze as bj,Sze as bk,F_e as bl,U_e as bm,G_e as bn,Z_e as bo,W_e as bp,X_e as bq,Eze as br,Aze as bs,CLe as bt,LLe as bu,Y2 as bv,$De as bw,wN as bx,b7 as by,SN as bz,MDe as c,gDe as d,xDe as e,wDe as f,dLe as g,Nt as h,C$e as i,M as j,N$e as k,L$e as l,hP as m,Yw as n,Bf as o,vX as p,bje as q,qU as r,fc as s,Oqe as t,TP as u,wje as v,_je as w,s$e as x,l$e as y,m$e as z};
8073
+ */const PHe={languageCode:"zh-CN",[Fo]:"上方插入行",[Bo]:"下方插入行",[Vo]:"左方插入列",[Ho]:"右方插入列",[qo]:["移除该行","移除多行"],[zo]:["移除该列","移除多列"],[Do]:"撤销",[Oo]:"恢复",[Po]:"只读",[jo]:"清空该列",[$o]:"对齐",[Ro]:"左对齐",[To]:"水平居中",[Ao]:"右对齐",[Io]:"两端对齐",[Eo]:"顶端对齐",[Lo]:"垂直居中",[No]:"底端对齐",[Co]:"冻结该列",[So]:"取消冻结",[_o]:"边框",[wo]:"上",[bo]:"右",[xo]:"下",[Mo]:"左",[go]:"移除边框",[ko]:"插入批注",[vo]:"编辑批注",[mo]:"删除批注",[yo]:"只读批注",[fo]:"合并",[po]:"取消合并",[ho]:"复制",[Jd]:"带标题的复制",[Qd]:"带标题组的复制",[Yd]:"仅复制标题",[uo]:"剪切",[lo]:"插入子行",[so]:"与母行分离",[co]:["隐藏该列","隐藏多列"],[io]:["显示该列","显示多列"],[ro]:["隐藏该行","隐藏多行"],[oo]:["显示该行","显示多行"],[ao]:"无",[no]:"为空",[to]:"不为空",[eo]:"等于",[Ja]:"不等于",[Qa]:"开头是",[Ya]:"结尾是",[Ka]:"包含",[Xa]:"不包含",[Za]:"大于",[Wa]:"大于或等于",[Ga]:"小于",[Ua]:"小于或等于",[Fa]:"在此范围",[Ba]:"不在此范围",[Va]:"之后",[Ha]:"之前",[qa]:"今天",[za]:"明天",[Da]:"昨天",[Oa]:"空白单元格",[Pa]:"按条件过滤",[ja]:"按值过滤",[$a]:"且",[Ra]:"或",[Ta]:"全选",[Aa]:"清除",[Ia]:"确认",[Ea]:"取消",[La]:"搜索",[Na]:"值",[Ca]:"第二值"};mee();const bF={de:CHe,en:gee,es:NHe,fr:LHe,it:EHe,ja:IHe,ko:AHe,nl:THe,pl:RHe,pt:$He,ru:jHe,zh:PHe},OHe=document.documentElement.lang,ZY=bF[OHe]??bF.en;vee(ZY);const XY=({config:e,data:t=[],onChange:a,disabled:o})=>{const{appearance:i}=JO(),[s,l]=p.useState("ht-theme-main"),[h,f]=p.useState(!1),y=p.useCallback((m,x)=>{var b,w;if(x==="loadData")return;const S=(w=(b=k.current)==null?void 0:b.hotInstance)==null?void 0:w.getSourceData();a(S)},[]),k=p.useRef(null);return p.useEffect(()=>{const m=setTimeout(()=>{var x;(x=k.current)!=null&&x.hotInstance&&(k.current.hotInstance.loadData(t??[]),f(!0))},100);return()=>clearTimeout(m)},[t]),p.useEffect(()=>{l(i==="dark"?"ht-theme-main-dark":"ht-theme-main")},[i]),M.jsx("div",{style:{opacity:h?1:0},children:M.jsx(kee,{className:o?"pointer-events-none opacity-50":"",themeName:s,language:ZY.languageCode,ref:k,...e,afterChange:y,children:e.columns.map(m=>M.jsx(Mee,{data:m.data,...m},m.data))})})},vVe=Object.freeze(Object.defineProperty({__proto__:null,default:XY},Symbol.toStringTag,{value:"Module"})),DHe=()=>{const[e,t]=p.useState({width:typeof window<"u"?window.innerWidth:1024,height:typeof window<"u"?window.innerHeight:768});return p.useEffect(()=>{if(typeof window>"u")return;const a=()=>{t({width:window.innerWidth,height:window.innerHeight})};return window.addEventListener("resize",a),()=>window.removeEventListener("resize",a)},[]),e},KY=({onChange:e,value:t,options:a,disabled:o})=>{const{appearance:i}=JO(),[s,l]=p.useState("light"),h=p.useRef(null),f=p.useRef(null),{width:y}=DHe(),k=y<768,m=y>=768&&y<1024,x=_=>{e(_)},S=_=>{h.current=_,b()},b=()=>{var N;if(!h.current)return;const _={minimap:{enabled:!k},fontSize:k?12:m?13:14,lineNumbers:k?"off":"on",lineDecorationsWidth:k?5:10,scrollBeyondLastLine:!k,wordWrap:k?"on":"bounded",renderWhitespace:k?"none":"selection",padding:{top:k?8:16,bottom:k?8:16}};h.current.updateOptions(_),(N=f.current)==null||N.classList.add("overflow-hidden"),setTimeout(()=>{var L,I;(L=h.current)==null||L.layout(),(I=f.current)==null||I.classList.remove("overflow-hidden")},100)};p.useEffect(()=>{l(i==="dark"?"vs-dark":"light")},[i]),p.useEffect(()=>{b()},[y]);const w=k?"300px":m?"400px":"500px";return M.jsx("div",{className:`border rounded-lg ${k?"p-1":"p-2"}`,ref:f,children:M.jsx(xee,{height:w,language:a.language,value:t,theme:s,options:{automaticLayout:!0,...k&&{wordWrap:"on"},minimap:{enabled:!k}},onChange:x,onMount:S,className:`transition-all duration-200 ease-in-out ${o?"pointer-events-none opacity-50 cursor-not-allowed":""}`})})},kVe=Object.freeze(Object.defineProperty({__proto__:null,default:KY},Symbol.toStringTag,{value:"Module"})),wF=gA("m-1 flex items-center border rounded-sm px-1",{variants:{variant:{default:"border-foreground/10 text-foreground bg-card hover:bg-card/80",secondary:"border-foreground/10 bg-secondary text-secondary-foreground hover:bg-secondary/80",destructive:"border-transparent bg-destructive text-destructive-foreground hover:bg-destructive/80",inverted:"inverted"}},defaultVariants:{variant:"default"}}),eD=p.forwardRef(({options:e,onValueChange:t,variant:a,processing:o,disabled:i,defaultValue:s=[],placeholder:l="",notFound:h="",search:f="",animation:y=0,maxCount:k=3,modalPopover:m=!1,asChild:x=!1,className:S,mode:b="multiple",...w},_)=>{const[N,L]=p.useState(s),[I,j]=p.useState(!1),[O,P]=p.useState(!1);p.useEffect(()=>{s&&L(s)},[s]);const A=q=>{if(q.key==="Enter")j(!0);else if(q.key==="Backspace"&&!q.currentTarget.value){const B=[...N];B.pop(),L(B),t(B)}},$=q=>{let B;b==="single"?B=N.includes(q)?[]:[q]:B=N.includes(q)?N.filter(Y=>Y!==q):[...N,q],L(B),t(B),b==="single"&&j(!1)},F=()=>{L([]),t([])},X=()=>{j(q=>!q)},H=()=>{const q=N.slice(0,k);L(q),t(q)};return M.jsxs(gK,{open:I,onOpenChange:j,modal:m,children:[M.jsx(MK,{asChild:!0,children:M.jsx(MA,{ref:_,...w,onClick:X,disabled:i,className:te("flex w-full p-1 rounded-md border-input border-1 min-h-10 h-auto items-center justify-between bg-inherit hover:bg-inherit [&_svg]:pointer-events-auto",S),children:N.length>0?M.jsxs("div",{className:"flex justify-between items-center w-full",children:[M.jsxs("div",{className:"flex flex-wrap items-center",children:[N.slice(0,k).map(q=>{const B=e.find(ue=>ue.value===q),Y=B==null?void 0:B.icon;return M.jsxs("div",{className:te(O?"animate-bounce":"",wF({variant:a})),style:{animationDuration:`${y}s`},children:[Y&&M.jsx(Y,{className:"h-4 w-4 mr-2"}),B==null?void 0:B.label,M.jsx(Or,{className:"ml-2 h-4 w-4 cursor-pointer",onClick:ue=>{ue.stopPropagation(),o||$(q)}})]},q)}),b==="multiple"&&N.length>k&&M.jsxs("div",{className:te("bg-transparent text-foreground border-foreground/1 hover:bg-transparent",O?"animate-bounce":"",wF({variant:a})),style:{animationDuration:`${y}s`},children:[`+ ${N.length-k} more`,M.jsx(Or,{className:"ml-2 h-4 w-4 cursor-pointer",onClick:q=>{q.stopPropagation(),H()}})]})]}),M.jsxs("div",{className:"flex items-center justify-between",children:[N.length>0&&M.jsxs(M.Fragment,{children:[M.jsx(bi,{className:"h-4 mx-2 cursor-pointer text-muted-foreground",onClick:q=>{q.stopPropagation(),F()}}),M.jsx(ZO,{orientation:"vertical",className:"flex min-h-6 h-full"})]}),M.jsx(xi,{className:"h-4 mx-2 cursor-pointer text-muted-foreground"})]})]}):M.jsxs("div",{className:"flex items-center justify-between w-full mx-auto",children:[M.jsx("span",{className:"text-sm text-muted-foreground mx-3",children:l}),M.jsx(xi,{className:"h-4 cursor-pointer text-muted-foreground mx-2"})]})})}),M.jsx(xK,{className:"w-auto p-0 z-[1003]",align:"start",onEscapeKeyDown:()=>j(!1),children:M.jsxs(sO,{children:[M.jsx(zW,{placeholder:f,onKeyDown:A}),M.jsxs(qW,{children:[M.jsx(HW,{children:h}),M.jsx(VW,{children:e.map(q=>{const B=N.includes(q.value);return M.jsxs(FW,{onSelect:()=>$(q.value),className:"cursor-pointer",children:[M.jsx("div",{className:te("mr-2 flex h-5 w-5 items-center justify-center rounded border border-primary",B?"bg-primary text-primary-foreground":"opacity-50 [&_svg]:invisible"),children:M.jsx(sr,{className:"h-4 w-4 text-primary-foreground"})}),q.icon&&M.jsx(q.icon,{className:"mr-2 h-4 w-4 text-muted-foreground"}),M.jsx("span",{children:q.label})]},q.value)})}),M.jsx(BW,{})]})]})}),y>0&&N.length>0&&b==="multiple"&&M.jsx(ki,{className:te("cursor-pointer my-2 text-foreground bg-background w-3 h-3",O?"":"text-muted-foreground"),onClick:()=>P(!O)})]})});eD.displayName="MultiSelect";const gVe=Object.freeze(Object.defineProperty({__proto__:null,default:eD},Symbol.toStringTag,{value:"Module"}));function zHe(){window.UIComponents??(window.UIComponents={}),window.JSComponents??(window.JSComponents={}),window.axios=Nt,window.sonner=Xqe,Object.assign(window.UIComponents,{Avatar:Dre,AvatarImage:zre,AvatarFallback:qre,Badge:Vre,Breadcrumb:F_e,BreadcrumbList:U_e,BreadcrumbItem:G_e,BreadcrumbLink:W_e,BreadcrumbPage:Z_e,BreadcrumbSeparator:X_e,BreadcrumbEllipsis:K_e,Button:MA,Calendar:ONe,Card:DNe,CardHeader:zNe,CardFooter:FNe,CardTitle:qNe,CardAction:VNe,CardDescription:HNe,CardContent:BNe,Checkbox:dLe,Collapsible:CLe,CollapsibleTrigger:NLe,CollapsibleContent:LLe,Command:sO,CommandDialog:OIe,CommandInput:zW,CommandList:qW,CommandEmpty:HW,CommandGroup:VW,CommandItem:FW,CommandShortcut:DIe,CommandSeparator:BW,ContextMenu:s$e,ContextMenuTrigger:l$e,ContextMenuContent:m$e,ContextMenuItem:v$e,ContextMenuCheckboxItem:k$e,ContextMenuRadioItem:g$e,ContextMenuLabel:M$e,ContextMenuSeparator:x$e,ContextMenuShortcut:b$e,ContextMenuGroup:d$e,ContextMenuPortal:u$e,ContextMenuSub:h$e,ContextMenuSubContent:y$e,ContextMenuSubTrigger:f$e,ContextMenuRadioGroup:p$e,Dialog:TW,DialogClose:jIe,DialogContent:jW,DialogDescription:DW,DialogFooter:PIe,DialogHeader:PW,DialogOverlay:$W,DialogPortal:RW,DialogTitle:OW,DialogTrigger:$Ie,DialogStack:yX,DialogStackTrigger:S$e,DialogStackOverlay:C$e,DialogStackBody:N$e,DialogStackContent:L$e,DialogStackTitle:E$e,DialogStackDescription:I$e,DialogStackHeader:A$e,DialogStackFooter:T$e,DialogStackNext:R$e,DialogStackPrevious:$$e,DropdownMenu:Mje,DropdownMenuPortal:xje,DropdownMenuTrigger:bje,DropdownMenuContent:wje,DropdownMenuGroup:_je,DropdownMenuLabel:Eje,DropdownMenuItem:Sje,DropdownMenuCheckboxItem:Cje,DropdownMenuRadioGroup:Nje,DropdownMenuRadioItem:Lje,DropdownMenuSeparator:Ije,DropdownMenuShortcut:Aje,DropdownMenuSub:Tje,DropdownMenuSubTrigger:Rje,DropdownMenuSubContent:$je,Input:jX,Label:Oje,Menubar:CPe,MenubarPortal:rK,MenubarMenu:NPe,MenubarTrigger:IPe,MenubarContent:APe,MenubarGroup:LPe,MenubarSeparator:PPe,MenubarLabel:jPe,MenubarItem:TPe,MenubarShortcut:OPe,MenubarCheckboxItem:RPe,MenubarRadioGroup:EPe,MenubarRadioItem:$Pe,MenubarSub:DPe,MenubarSubTrigger:zPe,MenubarSubContent:qPe,Pagination:HPe,PaginationContent:VPe,PaginationLink:FO,PaginationItem:BPe,PaginationPrevious:FPe,PaginationNext:UPe,PaginationEllipsis:GPe,Popover:gK,PopoverTrigger:MK,PopoverContent:xK,PopoverAnchor:mOe,Select:vDe,SelectContent:xDe,SelectGroup:kDe,SelectItem:wDe,SelectLabel:bDe,SelectScrollDownButton:nY,SelectScrollUpButton:tY,SelectSeparator:_De,SelectTrigger:MDe,SelectValue:gDe,Separator:ZO,Sheet:oY,SheetTrigger:EDe,SheetClose:IDe,SheetContent:rY,SheetHeader:iY,SheetFooter:RDe,SheetTitle:cY,SheetDescription:sY,Sidebar:gze,SidebarContent:Nze,SidebarFooter:Sze,SidebarGroup:Lze,SidebarGroupAction:Ize,SidebarGroupContent:Aze,SidebarGroupLabel:Eze,SidebarHeader:_ze,SidebarInput:wze,SidebarInset:bze,SidebarMenu:Tze,SidebarMenuAction:Pze,SidebarMenuBadge:Oze,SidebarMenuButton:jze,SidebarMenuItem:Rze,SidebarMenuSkeleton:Dze,SidebarMenuSub:zze,SidebarMenuSubButton:Hze,SidebarMenuSubItem:qze,SidebarProvider:kze,SidebarRail:xze,SidebarSeparator:Cze,SidebarTrigger:Mze,useSidebar:Y2,Skeleton:hP,Slider:mqe,Toaster:Kqe,Switch:hHe,Table:pHe,TableHeader:fHe,TableBody:yHe,TableFooter:mHe,TableHead:kHe,TableRow:vHe,TableCell:gHe,TableCaption:MHe,Textarea:xHe,Tooltip:xY,TooltipTrigger:bY,TooltipContent:wY,TooltipProvider:YO,VanillaJSONEditor:gP}),Object.assign(window.JSComponents,{VanillaJSONEditor:gP,HandsonTable:XY,MonacoEditor:KY,MultiSelect:eD})}const{createInertiaApp:qHe,router:YY}=HU;window.React=ke;window.ReactDOM=ur;window.InertiajsReact=HU;window.LucideReact=B_e;zHe();async function HHe(e,t){for(const a of Array.isArray(e)?e:[e]){const o=t[a];if(!(typeof o>"u"))return typeof o=="function"?o():o}throw new Error(`Page not found: ${e}`)}let tD=!1;YY.on("navigate",e=>{tD=!0});YY.on("finish",e=>{tD=!1});const _F=document.createElement.bind(document);document.createElement=function(e,t){const a=_F(e,t);return e.toLowerCase()==="iframe"&&tD?(console.warn("[Adminizer] Prevented iframe creation, forcing full page reload"),setTimeout(()=>{window.location.reload()},0),_F("div")):a};qHe({title:e=>`${e}`,resolve:e=>HHe(`./pages/${e}.tsx`,Object.assign({"./pages/add-group.tsx":()=>vn(()=>import("./add-group-Bg5tLxYu.js"),__vite__mapDeps([0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16]),import.meta.url),"./pages/add-user.tsx":()=>vn(()=>import("./add-user-H6XsOKX_.js"),__vite__mapDeps([17,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,18,19]),import.meta.url),"./pages/add.tsx":()=>vn(()=>import("./add-C_-KTZY-.js"),__vite__mapDeps([20,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,21,22,23,24,19,25]),import.meta.url),"./pages/catalog.tsx":()=>vn(()=>import("./catalog-BsRePE_I.js"),__vite__mapDeps([26,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,27,21,22,23,24,19,25,28]),import.meta.url),"./pages/dashboard.tsx":()=>vn(()=>import("./dashboard-Bynx-P6M.js"),__vite__mapDeps([29,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,30]),import.meta.url),"./pages/form.tsx":()=>vn(()=>import("./form-D6rF7waX.js"),__vite__mapDeps([31,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,32,21,22,23,24,19,25]),import.meta.url),"./pages/history.tsx":()=>vn(()=>import("./history-DL0tB2tZ.js"),__vite__mapDeps([33,3,4,25,1,2,5,6,7,8,9,10,11,12,13,14,15]),import.meta.url),"./pages/home.tsx":()=>vn(()=>import("./home-CADtJAH_.js"),__vite__mapDeps([34,4,3,5]),import.meta.url),"./pages/init-user.tsx":()=>vn(()=>import("./init-user-CsEDYKZe.js"),__vite__mapDeps([35,3,4,19,5]),import.meta.url),"./pages/list.tsx":()=>vn(()=>import("./list-B3Ki-psl.js"),__vite__mapDeps([36,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,37,27,38]),import.meta.url),"./pages/login.tsx":()=>vn(()=>import("./login-BfN1lJT1.js"),__vite__mapDeps([39,15,4,3,5,19]),import.meta.url),"./pages/module.tsx":()=>vn(()=>import("./module-B5hkMJ4M.js"),__vite__mapDeps([40,3,4,1,2,5,6,7,8,9,10,11,12,13,14,15]),import.meta.url),"./pages/notification.tsx":()=>vn(()=>import("./notification-D1_TtX__.js"),__vite__mapDeps([41,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,42]),import.meta.url),"./pages/register.tsx":()=>vn(()=>import("./register-C2TFSMX0.js"),__vite__mapDeps([43,3,4,19,5]),import.meta.url),"./pages/welcome.tsx":()=>vn(()=>import("./welcome-AlKSDf1S.js"),__vite__mapDeps([44,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15]),import.meta.url)})),setup({el:e,App:t,props:a}){Noe.createRoot(e).render(M.jsx(t,{...a}))},progress:{color:"#0f4898"}});export{gK as $,m$e as A,MA as B,lr as C,yX as D,s5 as E,v$e as F,DNe as G,zNe as H,jX as I,qNe as J,FNe as K,Fs as L,YO as M,xY as N,bY as O,I9 as P,wY as Q,hHe as R,vDe as S,Kqe as T,S$e as U,E$e as V,hr as W,uj as X,c2 as Y,s2 as Z,wSe as _,i5 as a,gze as a$,MK as a0,lv as a1,W1 as a2,xK as a3,ONe as a4,pHe as a5,fHe as a6,vHe as a7,kHe as a8,yHe as a9,te as aA,PIe as aB,jIe as aC,yf as aD,Kp as aE,ef as aF,of as aG,$Ie as aH,Rs as aI,kt as aJ,z2 as aK,bn as aL,It as aM,xZ as aN,bZ as aO,xe as aP,Pn as aQ,DA as aR,O7 as aS,fM as aT,kze as aU,Mje as aV,gy as aW,Sje as aX,Ije as aY,Mze as aZ,U8 as a_,gHe as aa,vc as ab,TW as ac,jW as ad,PW as ae,OW as af,vG as ag,moe as ah,koe as ai,$U as aj,hVe as ak,jE as al,Rx as am,bze as an,vl as ao,bi as ap,YU as aq,xHe as ar,DHe as as,JO as at,cb as au,B8 as av,v_ as aw,sr as ax,UL as ay,M1 as az,Oje as b,gVe as b$,_ze as b0,Tze as b1,Rze as b2,CPe as b3,NPe as b4,IPe as b5,jze as b6,Qv as b7,APe as b8,DPe as b9,SN as bA,Dre as bB,zre as bC,qre as bD,Eje as bE,jx as bF,yVe as bG,fVe as bH,pVe as bI,eD as bJ,mqe as bK,Un as bL,c7 as bM,dVe as bN,lf as bO,v2 as bP,r1 as bQ,__ as bR,HPe as bS,VPe as bT,BPe as bU,FO as bV,FPe as bW,UPe as bX,mVe as bY,vVe as bZ,kVe as b_,zPe as ba,qPe as bb,TPe as bc,Lze as bd,HG as be,NLe as bf,FG as bg,zze as bh,qze as bi,Hze as bj,Nze as bk,Sze as bl,F_e as bm,U_e as bn,G_e as bo,Z_e as bp,W_e as bq,X_e as br,Eze as bs,Aze as bt,CLe as bu,LLe as bv,Y2 as bw,$De as bx,wN as by,b7 as bz,MDe as c,gDe as d,xDe as e,wDe as f,dLe as g,Nt as h,C$e as i,M as j,N$e as k,L$e as l,hP as m,Vre as n,Yw as o,Bf as p,vX as q,qU as r,bje as s,Oqe as t,TP as u,fc as v,wje as w,_je as x,s$e as y,l$e as z};
@@ -1 +1 @@
1
- import{j as r,bl as n,bm as i,bn as c,bo as l,bp as m,ah as d,bq as h}from"./app.js";import{r as o}from"./handsontable-PxYdjN8c.js";import"./jsoneditor-De1FvcYu.js";import"./monaco-BhBYtg3d.js";function b({breadcrumbs:e}){return r.jsx(r.Fragment,{children:e.length>0&&r.jsx(n,{children:r.jsx(i,{children:e.map((s,a)=>{const t=a===e.length-1;return r.jsxs(o.Fragment,{children:[r.jsx(c,{children:t?r.jsx(l,{children:s.title}):r.jsx(m,{asChild:!0,children:r.jsx(d,{href:s.href,children:s.title})})}),!t&&r.jsx(h,{})]},a)})})})})}export{b as Breadcrumbs};
1
+ import{j as r,bm as n,bn as i,bo as c,bp as m,bq as d,ai as l,br as h}from"./app.js";import{r as o}from"./handsontable-PxYdjN8c.js";import"./jsoneditor-De1FvcYu.js";import"./monaco-BhBYtg3d.js";function b({breadcrumbs:e}){return r.jsx(r.Fragment,{children:e.length>0&&r.jsx(n,{children:r.jsx(i,{children:e.map((s,a)=>{const t=a===e.length-1;return r.jsxs(o.Fragment,{children:[r.jsx(c,{children:t?r.jsx(m,{children:s.title}):r.jsx(d,{asChild:!0,children:r.jsx(l,{href:s.href,children:s.title})})}),!t&&r.jsx(h,{})]},a)})})})})}export{b as Breadcrumbs};