@object-ui/console 3.0.1 → 3.0.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (127) hide show
  1. package/dist/assets/{AuditLogPage-BQW_Xbnm.js → AuditLogPage-CyY7VZJW.js} +1 -1
  2. package/dist/assets/AuditLogPage-CyY7VZJW.js.br +0 -0
  3. package/dist/assets/AuditLogPage-CyY7VZJW.js.gz +0 -0
  4. package/dist/assets/DashboardView-DSh9LYBb.js +1 -0
  5. package/dist/assets/DashboardView-DSh9LYBb.js.br +0 -0
  6. package/dist/assets/DashboardView-DSh9LYBb.js.gz +0 -0
  7. package/dist/assets/{ForgotPasswordPage-zr9S5vrE.js → ForgotPasswordPage-DUfjj-wh.js} +1 -1
  8. package/dist/assets/{KanbanEnhanced-BlGp--J7.js → KanbanEnhanced-ZOndyXyg.js} +1 -1
  9. package/dist/assets/KanbanEnhanced-ZOndyXyg.js.br +0 -0
  10. package/dist/assets/KanbanEnhanced-ZOndyXyg.js.gz +0 -0
  11. package/dist/assets/{KanbanImpl-B5wWMXrJ.js → KanbanImpl-BsMtStI7.js} +1 -1
  12. package/dist/assets/KanbanImpl-BsMtStI7.js.br +0 -0
  13. package/dist/assets/KanbanImpl-BsMtStI7.js.gz +0 -0
  14. package/dist/assets/{LoginPage-H688gsah.js → LoginPage-2CoFvwsL.js} +1 -1
  15. package/dist/assets/{OrgManagementPage-x3qIkxHL.js → OrgManagementPage-BJt5Iiun.js} +1 -1
  16. package/dist/assets/OrgManagementPage-BJt5Iiun.js.br +0 -0
  17. package/dist/assets/OrgManagementPage-BJt5Iiun.js.gz +0 -0
  18. package/dist/assets/PageView-bHvRhycc.js +1 -0
  19. package/dist/assets/PageView-bHvRhycc.js.br +0 -0
  20. package/dist/assets/PageView-bHvRhycc.js.gz +0 -0
  21. package/dist/assets/{ProfilePage-DjAiGvFb.js → ProfilePage-MVUfKMrp.js} +1 -1
  22. package/dist/assets/ProfilePage-MVUfKMrp.js.br +0 -0
  23. package/dist/assets/ProfilePage-MVUfKMrp.js.gz +0 -0
  24. package/dist/assets/{RecordDetailView-Bfu7541n.js → RecordDetailView-Sm8_iQw_.js} +1 -1
  25. package/dist/assets/RecordDetailView-Sm8_iQw_.js.br +0 -0
  26. package/dist/assets/RecordDetailView-Sm8_iQw_.js.gz +0 -0
  27. package/dist/assets/{RegisterPage-CR91Lc7x.js → RegisterPage-B9itUVYp.js} +1 -1
  28. package/dist/assets/ReportView-B0D9jx4v.js +1 -0
  29. package/dist/assets/ReportView-B0D9jx4v.js.br +0 -0
  30. package/dist/assets/ReportView-B0D9jx4v.js.gz +0 -0
  31. package/dist/assets/{RoleManagementPage-DnWuzxKJ.js → RoleManagementPage-BRqaeF_L.js} +1 -1
  32. package/dist/assets/RoleManagementPage-BRqaeF_L.js.br +0 -0
  33. package/dist/assets/RoleManagementPage-BRqaeF_L.js.gz +0 -0
  34. package/dist/assets/SearchResultsPage-wlC0eLLr.js +1 -0
  35. package/dist/assets/SearchResultsPage-wlC0eLLr.js.br +0 -0
  36. package/dist/assets/SearchResultsPage-wlC0eLLr.js.gz +0 -0
  37. package/dist/assets/{UserManagementPage-o0_K0dzR.js → UserManagementPage-DOH6ql6-.js} +1 -1
  38. package/dist/assets/UserManagementPage-DOH6ql6-.js.br +0 -0
  39. package/dist/assets/UserManagementPage-DOH6ql6-.js.gz +0 -0
  40. package/dist/assets/{ViewDesignerPage-BbwrZa9D.js → ViewDesignerPage-TCaXYb43.js} +1 -1
  41. package/dist/assets/ViewDesignerPage-TCaXYb43.js.br +0 -0
  42. package/dist/assets/{ViewDesignerPage-BbwrZa9D.js.gz → ViewDesignerPage-TCaXYb43.js.gz} +0 -0
  43. package/dist/assets/{data-adapter-Cn800k4a.js → data-adapter-D15yh-pb.js} +1 -1
  44. package/dist/assets/data-adapter-D15yh-pb.js.br +0 -0
  45. package/dist/assets/data-adapter-D15yh-pb.js.gz +0 -0
  46. package/dist/assets/index-RAPqkKVL.js +9 -0
  47. package/dist/assets/index-RAPqkKVL.js.br +0 -0
  48. package/dist/assets/index-RAPqkKVL.js.gz +0 -0
  49. package/dist/assets/{infrastructure-aS2LF8OZ.js → infrastructure-Di0WqY4l.js} +1 -1
  50. package/dist/assets/infrastructure-Di0WqY4l.js.br +0 -0
  51. package/dist/assets/infrastructure-Di0WqY4l.js.gz +0 -0
  52. package/dist/assets/{plugins-core-CcBSZCjG.js → plugins-core-Cv2TPt86.js} +2 -2
  53. package/dist/assets/plugins-core-Cv2TPt86.js.br +0 -0
  54. package/dist/assets/plugins-core-Cv2TPt86.js.gz +0 -0
  55. package/dist/assets/plugins-views-divN-xXs.js +60 -0
  56. package/dist/assets/plugins-views-divN-xXs.js.br +0 -0
  57. package/dist/assets/plugins-views-divN-xXs.js.gz +0 -0
  58. package/dist/assets/{ui-components-DVonQS7H.js → ui-components-CseD2Dpn.js} +1 -1
  59. package/dist/assets/ui-components-CseD2Dpn.js.br +0 -0
  60. package/dist/assets/ui-components-CseD2Dpn.js.gz +0 -0
  61. package/dist/assets/{ui-layout-BENIRxAF.js → ui-layout-CF_1bNSv.js} +1 -1
  62. package/dist/assets/ui-layout-CF_1bNSv.js.br +0 -0
  63. package/dist/assets/ui-layout-CF_1bNSv.js.gz +0 -0
  64. package/dist/assets/vendor-objectstack-Bifvxvds.js +1 -0
  65. package/dist/assets/vendor-objectstack-Bifvxvds.js.br +0 -0
  66. package/dist/assets/vendor-objectstack-Bifvxvds.js.gz +0 -0
  67. package/dist/assets/{vendor-zod-Dpl-cylz.js → vendor-zod-UZPqlszj.js} +4 -4
  68. package/dist/assets/vendor-zod-UZPqlszj.js.br +0 -0
  69. package/dist/assets/vendor-zod-UZPqlszj.js.gz +0 -0
  70. package/dist/index.html +24 -24
  71. package/dist/index.html.br +0 -0
  72. package/dist/index.html.gz +0 -0
  73. package/dist/stats.html +1 -1
  74. package/package.json +46 -41
  75. package/plugin.d.ts +44 -0
  76. package/plugin.js +62 -0
  77. package/plugin.ts +9 -118
  78. package/dist/assets/AuditLogPage-BQW_Xbnm.js.br +0 -0
  79. package/dist/assets/AuditLogPage-BQW_Xbnm.js.gz +0 -0
  80. package/dist/assets/DashboardView-Dt-4VhH6.js +0 -1
  81. package/dist/assets/DashboardView-Dt-4VhH6.js.br +0 -0
  82. package/dist/assets/DashboardView-Dt-4VhH6.js.gz +0 -0
  83. package/dist/assets/KanbanEnhanced-BlGp--J7.js.br +0 -0
  84. package/dist/assets/KanbanEnhanced-BlGp--J7.js.gz +0 -0
  85. package/dist/assets/KanbanImpl-B5wWMXrJ.js.br +0 -0
  86. package/dist/assets/KanbanImpl-B5wWMXrJ.js.gz +0 -0
  87. package/dist/assets/OrgManagementPage-x3qIkxHL.js.br +0 -0
  88. package/dist/assets/OrgManagementPage-x3qIkxHL.js.gz +0 -0
  89. package/dist/assets/PageView-BRN1h8QD.js +0 -1
  90. package/dist/assets/PageView-BRN1h8QD.js.br +0 -0
  91. package/dist/assets/PageView-BRN1h8QD.js.gz +0 -0
  92. package/dist/assets/ProfilePage-DjAiGvFb.js.br +0 -0
  93. package/dist/assets/ProfilePage-DjAiGvFb.js.gz +0 -0
  94. package/dist/assets/RecordDetailView-Bfu7541n.js.br +0 -0
  95. package/dist/assets/RecordDetailView-Bfu7541n.js.gz +0 -0
  96. package/dist/assets/ReportView-CwWsv2yl.js +0 -1
  97. package/dist/assets/ReportView-CwWsv2yl.js.br +0 -0
  98. package/dist/assets/ReportView-CwWsv2yl.js.gz +0 -0
  99. package/dist/assets/RoleManagementPage-DnWuzxKJ.js.br +0 -0
  100. package/dist/assets/RoleManagementPage-DnWuzxKJ.js.gz +0 -0
  101. package/dist/assets/SearchResultsPage-DBpjAlh2.js +0 -1
  102. package/dist/assets/SearchResultsPage-DBpjAlh2.js.br +0 -0
  103. package/dist/assets/SearchResultsPage-DBpjAlh2.js.gz +0 -0
  104. package/dist/assets/UserManagementPage-o0_K0dzR.js.br +0 -0
  105. package/dist/assets/UserManagementPage-o0_K0dzR.js.gz +0 -0
  106. package/dist/assets/ViewDesignerPage-BbwrZa9D.js.br +0 -0
  107. package/dist/assets/data-adapter-Cn800k4a.js.br +0 -0
  108. package/dist/assets/data-adapter-Cn800k4a.js.gz +0 -0
  109. package/dist/assets/index-BjEGJcpx.js +0 -56
  110. package/dist/assets/index-BjEGJcpx.js.br +0 -0
  111. package/dist/assets/index-BjEGJcpx.js.gz +0 -0
  112. package/dist/assets/infrastructure-aS2LF8OZ.js.br +0 -0
  113. package/dist/assets/infrastructure-aS2LF8OZ.js.gz +0 -0
  114. package/dist/assets/plugins-core-CcBSZCjG.js.br +0 -0
  115. package/dist/assets/plugins-core-CcBSZCjG.js.gz +0 -0
  116. package/dist/assets/plugins-views-DQwkCaaO.js +0 -60
  117. package/dist/assets/plugins-views-DQwkCaaO.js.br +0 -0
  118. package/dist/assets/plugins-views-DQwkCaaO.js.gz +0 -0
  119. package/dist/assets/ui-components-DVonQS7H.js.br +0 -0
  120. package/dist/assets/ui-components-DVonQS7H.js.gz +0 -0
  121. package/dist/assets/ui-layout-BENIRxAF.js.br +0 -0
  122. package/dist/assets/ui-layout-BENIRxAF.js.gz +0 -0
  123. package/dist/assets/vendor-objectstack-DqojdwYW.js +0 -37
  124. package/dist/assets/vendor-objectstack-DqojdwYW.js.br +0 -0
  125. package/dist/assets/vendor-objectstack-DqojdwYW.js.gz +0 -0
  126. package/dist/assets/vendor-zod-Dpl-cylz.js.br +0 -0
  127. package/dist/assets/vendor-zod-Dpl-cylz.js.gz +0 -0
@@ -1 +1 @@
1
- import{j as e}from"./vendor-react-Dy_xkBQQ.js";import{Y as l,Z as m,a1 as d}from"./ui-components-DVonQS7H.js";import"./framework-mHWN965c.js";import"./vendor-ui-utils-h6yAcIi9.js";import{s as n}from"./systemObjects-DSpePIIy.js";import{bx as a}from"./vendor-icons-CQ8b-fGy.js";import"./vendor-radix-BbeYj_o4.js";import"./vendor-i18n-D5KbMT7w.js";import"./vendor-charts-CSvoW-yB.js";const t=n.find(s=>s.name==="sys_audit_log");function N(){return e.jsxs("div",{className:"flex flex-col gap-4 sm:gap-6 p-4 sm:p-6",children:[e.jsxs("div",{className:"flex items-center gap-3 min-w-0",children:[e.jsx("div",{className:"bg-primary/10 p-2 rounded-md shrink-0",children:e.jsx(a,{className:"h-5 w-5 text-primary"})}),e.jsxs("div",{className:"min-w-0",children:[e.jsx("h1",{className:"text-xl sm:text-2xl font-bold tracking-tight",children:"Audit Log"}),e.jsx("p",{className:"text-sm text-muted-foreground mt-0.5",children:"View system activity and user actions"})]})]}),e.jsx(l,{children:e.jsx(m,{className:"p-0",children:e.jsx("div",{className:"overflow-x-auto",children:e.jsxs("table",{className:"w-full text-sm",children:[e.jsx("thead",{children:e.jsx("tr",{className:"border-b bg-muted/50",children:t.views[0].columns.map(s=>{const r=t.fields.find(i=>i.name===s);return e.jsx("th",{className:"h-10 px-3 sm:px-4 text-left font-medium text-muted-foreground whitespace-nowrap",children:r?.label??s},s)})})}),e.jsx("tbody",{children:e.jsx("tr",{children:e.jsx("td",{className:"p-4 sm:p-6 text-center text-sm text-muted-foreground",colSpan:t.views[0].columns.length,children:e.jsxs("div",{className:"flex flex-col items-center gap-2 py-4",children:[e.jsx(a,{className:"h-8 w-8 text-muted-foreground/50"}),e.jsx("p",{children:"Connect to ObjectStack server to load audit logs."}),e.jsx(d,{variant:"secondary",className:"text-xs",children:"Read-only"})]})})})})]})})})})]})}export{N as AuditLogPage};
1
+ import{j as e}from"./vendor-react-Dy_xkBQQ.js";import{Y as l,Z as m,a1 as d}from"./ui-components-CseD2Dpn.js";import"./framework-mHWN965c.js";import"./vendor-ui-utils-h6yAcIi9.js";import{s as n}from"./systemObjects-DSpePIIy.js";import{bx as a}from"./vendor-icons-CQ8b-fGy.js";import"./vendor-radix-BbeYj_o4.js";import"./vendor-i18n-D5KbMT7w.js";import"./vendor-charts-CSvoW-yB.js";const t=n.find(s=>s.name==="sys_audit_log");function N(){return e.jsxs("div",{className:"flex flex-col gap-4 sm:gap-6 p-4 sm:p-6",children:[e.jsxs("div",{className:"flex items-center gap-3 min-w-0",children:[e.jsx("div",{className:"bg-primary/10 p-2 rounded-md shrink-0",children:e.jsx(a,{className:"h-5 w-5 text-primary"})}),e.jsxs("div",{className:"min-w-0",children:[e.jsx("h1",{className:"text-xl sm:text-2xl font-bold tracking-tight",children:"Audit Log"}),e.jsx("p",{className:"text-sm text-muted-foreground mt-0.5",children:"View system activity and user actions"})]})]}),e.jsx(l,{children:e.jsx(m,{className:"p-0",children:e.jsx("div",{className:"overflow-x-auto",children:e.jsxs("table",{className:"w-full text-sm",children:[e.jsx("thead",{children:e.jsx("tr",{className:"border-b bg-muted/50",children:t.views[0].columns.map(s=>{const r=t.fields.find(i=>i.name===s);return e.jsx("th",{className:"h-10 px-3 sm:px-4 text-left font-medium text-muted-foreground whitespace-nowrap",children:r?.label??s},s)})})}),e.jsx("tbody",{children:e.jsx("tr",{children:e.jsx("td",{className:"p-4 sm:p-6 text-center text-sm text-muted-foreground",colSpan:t.views[0].columns.length,children:e.jsxs("div",{className:"flex flex-col items-center gap-2 py-4",children:[e.jsx(a,{className:"h-8 w-8 text-muted-foreground/50"}),e.jsx("p",{children:"Connect to ObjectStack server to load audit logs."}),e.jsx(d,{variant:"secondary",className:"text-xs",children:"Read-only"})]})})})})]})})})})]})}export{N as AuditLogPage};
@@ -0,0 +1 @@
1
+ import{j as s,h,r as i}from"./vendor-react-Dy_xkBQQ.js";import{a as p}from"./plugins-views-divN-xXs.js";import{a9 as e,aH as f,aI as u,aJ as j}from"./ui-components-CseD2Dpn.js";import"./framework-mHWN965c.js";import"./vendor-ui-utils-h6yAcIi9.js";import{u as g,b as N,r as d,M as b,a as w}from"./index-RAPqkKVL.js";import{aD as v}from"./vendor-icons-CQ8b-fGy.js";import"./vendor-charts-CSvoW-yB.js";import"./vendor-i18n-D5KbMT7w.js";import"./vendor-radix-BbeYj_o4.js";import"./plugins-core-Cv2TPt86.js";import"./infrastructure-Di0WqY4l.js";import"./data-adapter-D15yh-pb.js";import"./vendor-objectstack-Bifvxvds.js";import"./vendor-zod-UZPqlszj.js";import"./ui-layout-CF_1bNSv.js";function y({cards:l=6}){return s.jsxs("div",{className:"w-full space-y-6 p-4 sm:p-6",children:[s.jsxs("div",{className:"space-y-2",children:[s.jsx(e,{className:"h-7 w-56"}),s.jsx(e,{className:"h-4 w-80"})]}),s.jsx("div",{className:"grid grid-cols-2 md:grid-cols-4 gap-4",children:Array.from({length:4}).map((t,r)=>s.jsxs("div",{className:"rounded-lg border p-4 space-y-2",children:[s.jsx(e,{className:"h-4 w-20"}),s.jsx(e,{className:"h-8 w-24"}),s.jsx(e,{className:"h-3 w-16"})]},`stat-${r}`))}),s.jsx("div",{className:"grid grid-cols-1 md:grid-cols-2 lg:grid-cols-3 gap-4",children:Array.from({length:l}).map((t,r)=>s.jsxs("div",{className:"rounded-lg border p-4 space-y-3",children:[s.jsxs("div",{className:"flex items-center justify-between",children:[s.jsx(e,{className:"h-5 w-32"}),s.jsx(e,{className:"h-5 w-5 rounded-full"})]}),s.jsx(e,{className:"h-40 w-full"}),s.jsxs("div",{className:"flex items-center gap-2",children:[s.jsx(e,{className:"h-3 w-16"}),s.jsx(e,{className:"h-3 w-12"})]})]},`widget-${r}`))})]})}function H({dataSource:l}){const{dashboardName:t}=h(),{showDebug:r,toggleDebug:m}=g(),[c,o]=i.useState(!0);i.useEffect(()=>{o(!0),queueMicrotask(()=>o(!1))},[t]);const{dashboards:n}=N(),a=n?.find(x=>x.name===t);return c?s.jsx(y,{}):a?s.jsxs("div",{className:"flex flex-col h-full overflow-hidden bg-background",children:[s.jsxs("div",{className:"flex flex-col sm:flex-row justify-between sm:items-center gap-3 sm:gap-4 p-4 sm:p-6 border-b shrink-0",children:[s.jsxs("div",{className:"min-w-0 flex-1",children:[s.jsx("h1",{className:"text-lg sm:text-xl md:text-2xl font-bold tracking-tight truncate",children:d(a.label)||a.name}),a.description&&s.jsx("p",{className:"text-sm text-muted-foreground mt-1 line-clamp-2",children:d(a.description)})]}),s.jsx("div",{className:"shrink-0",children:s.jsx(b,{open:r,onToggle:m})})]}),s.jsxs("div",{className:"flex-1 overflow-hidden flex flex-col sm:flex-row relative",children:[s.jsx("div",{className:"flex-1 overflow-auto p-4 sm:p-6",children:s.jsx(p,{schema:a,dataSource:l})}),s.jsx(w,{open:r,sections:[{title:"Dashboard Configuration",data:a}]})]})]}):s.jsx("div",{className:"h-full flex items-center justify-center p-8",children:s.jsxs(f,{children:[s.jsx("div",{className:"mx-auto mb-4 flex h-12 w-12 items-center justify-center rounded-full bg-muted",children:s.jsx(v,{className:"h-6 w-6 text-muted-foreground"})}),s.jsx(u,{children:"Dashboard Not Found"}),s.jsxs(j,{children:['The dashboard "',t,'" could not be found. It may have been removed or renamed.']})]})})}export{H as DashboardView};
@@ -1 +1 @@
1
- import{j as r}from"./vendor-react-Dy_xkBQQ.js";import{F as o}from"./infrastructure-aS2LF8OZ.js";import"./vendor-i18n-D5KbMT7w.js";function i(){return r.jsx("div",{className:"flex min-h-screen items-center justify-center bg-background px-4 py-8",children:r.jsx(o,{loginUrl:"/login"})})}export{i as ForgotPasswordPage};
1
+ import{j as r}from"./vendor-react-Dy_xkBQQ.js";import{F as o}from"./infrastructure-Di0WqY4l.js";import"./vendor-i18n-D5KbMT7w.js";function i(){return r.jsx("div",{className:"flex min-h-screen items-center justify-center bg-background px-4 py-8",children:r.jsx(o,{loginUrl:"/login"})})}export{i as ForgotPasswordPage};
@@ -1 +1 @@
1
- import{r as c,j as e}from"./vendor-react-Dy_xkBQQ.js";import{u as F}from"./plugins-core-CcBSZCjG.js";import{u as H,a as K,D as P,c as Y,b as M,d as U,P as Z,e as z,S as q,v as G,C as J}from"./vendor-dndkit-DRGpK6sP.js";import{B as Q,a1 as I,Y as W,$ as X,a0 as _,ab as ee,Z as se}from"./ui-components-DVonQS7H.js";import"./framework-mHWN965c.js";import"./vendor-ui-utils-h6yAcIi9.js";import{a as te,C as re,T as ae}from"./vendor-icons-CQ8b-fGy.js";import"./plugins-views-DQwkCaaO.js";import"./vendor-charts-CSvoW-yB.js";import"./vendor-i18n-D5KbMT7w.js";import"./vendor-radix-BbeYj_o4.js";const k=(...s)=>s.filter(Boolean).join(" ");function E({card:s}){const{attributes:x,listeners:o,setNodeRef:m,transform:r,transition:g,isDragging:v}=z({id:s.id}),f={transform:J.Transform.toString(r),transition:g,opacity:v?.5:void 0};return e.jsx("div",{ref:m,style:f,...x,...o,children:e.jsxs(W,{className:"mb-2 cursor-grab active:cursor-grabbing border-border bg-card/60 hover:border-primary/40 hover:shadow-lg hover:shadow-primary/10 transition-all duration-300 group",children:[e.jsxs(X,{className:"p-4",children:[e.jsx(_,{className:"text-sm font-medium font-mono tracking-tight text-foreground group-hover:text-primary transition-colors",children:s.title}),s.description&&e.jsx(ee,{className:"text-xs text-muted-foreground font-mono",children:s.description})]}),s.badges&&s.badges.length>0&&e.jsx(se,{className:"p-4 pt-0",children:e.jsx("div",{className:"flex flex-wrap gap-1",children:s.badges.map((l,a)=>e.jsx(I,{variant:l.variant||"default",className:"text-xs",children:l.label},a))})})]})})}function ie({cards:s,parentRef:x}){const o=F({count:s.length,getScrollElement:()=>x.current,estimateSize:()=>120,overscan:5});return e.jsx("div",{style:{height:`${o.getTotalSize()}px`,width:"100%",position:"relative"},children:o.getVirtualItems().map(m=>{const r=s[m.index];return e.jsx("div",{style:{position:"absolute",top:0,left:0,width:"100%",transform:`translateY(${m.start}px)`},children:e.jsx(E,{card:r})},r.id)})})}function ne({column:s,cards:x,onToggle:o,enableVirtual:m}){const r=x||[],g=c.useRef(null),{setNodeRef:v}=z({id:s.id,data:{type:"column"}}),f=s.limit&&r.length>=s.limit,l=s.limit&&r.length>=s.limit*.8;return e.jsxs("div",{ref:v,className:k("flex flex-col flex-shrink-0 rounded-lg border border-border bg-card/20 backdrop-blur-sm shadow-xl transition-all",s.collapsed?"w-16":"w-80",s.className),children:[e.jsxs("div",{className:"p-4 border-b border-border/50 bg-muted/20 flex items-center justify-between",children:[e.jsxs("div",{className:"flex items-center gap-2 flex-1 min-w-0",children:[e.jsx(Q,{variant:"ghost",size:"sm",className:"h-6 w-6 p-0",onClick:()=>o(!s.collapsed),children:s.collapsed?e.jsx(te,{className:"h-4 w-4"}):e.jsx(re,{className:"h-4 w-4"})}),!s.collapsed&&e.jsxs(e.Fragment,{children:[e.jsx("h3",{className:"font-mono text-sm font-semibold tracking-wider text-primary/90 uppercase truncate",children:s.title}),e.jsxs("div",{className:"flex items-center gap-2",children:[e.jsxs("span",{className:k("font-mono text-xs",f?"text-destructive":l?"text-yellow-500":"text-muted-foreground"),children:[r.length,s.limit&&` / ${s.limit}`]}),f&&e.jsx(I,{variant:"destructive",className:"text-xs",children:"Full"}),l&&!f&&e.jsx(ae,{className:"h-3 w-3 text-yellow-500"})]})]})]}),s.collapsed&&e.jsxs("div",{className:"flex flex-col items-center gap-1",children:[e.jsx("span",{className:"font-mono text-xs font-bold text-primary/90 [writing-mode:vertical-rl] rotate-180",children:s.title}),e.jsx(I,{variant:"secondary",className:"text-xs",children:r.length})]})]}),!s.collapsed&&e.jsx("div",{ref:g,className:"flex-1 p-4 overflow-y-auto",style:{maxHeight:"600px"},children:e.jsx(q,{items:r.map(a=>a.id),strategy:G,children:m?e.jsx(ie,{cards:r,parentRef:g}):e.jsx("div",{className:"space-y-2",children:r.map(a=>e.jsx(E,{card:a},a.id))})})})]})}function ve({columns:s,onCardMove:x,onColumnToggle:o,enableVirtualScrolling:m=!1,virtualScrollThreshold:r=50,className:g}){const[v,f]=c.useState(null),l=c.useMemo(()=>(s||[]).map(t=>({...t,cards:t.cards||[]})),[s]),[a,S]=c.useState(l);c.useEffect(()=>{S(l)},[l]);const T=H(K(Z,{activationConstraint:{distance:8}})),V=t=>{const{active:i}=t,n=$(i.id);f(n)},L=t=>{const{active:i,over:n}=t;if(f(null),!n)return;const d=i.id,b=n.id;if(d===b)return;const u=B(d),j=B(b)||O(b);if(!(!u||!j))if(u.id===j.id){const h=[...u.cards],C=h.findIndex(p=>p.id===d),D=h.findIndex(p=>p.id===b),R=U(h,C,D);S(p=>p.map(N=>N.id===u.id?{...N,cards:R}:N))}else{const h=[...u.cards],C=[...j.cards],D=h.findIndex(w=>w.id===d),p=b===j.id?C.length:C.findIndex(w=>w.id===b),[N]=h.splice(D,1);C.splice(p,0,N),S(w=>w.map(y=>y.id===u.id?{...y,cards:h}:y.id===j.id?{...y,cards:C}:y)),x&&x(d,u.id,j.id,p)}},$=c.useCallback(t=>{for(const i of a){const n=i.cards.find(d=>d.id===t);if(n)return n}return null},[a]),B=c.useCallback(t=>a.find(i=>i.cards.some(n=>n.id===t))||null,[a]),O=c.useCallback(t=>a.find(i=>i.id===t)||null,[a]),A=c.useCallback((t,i)=>{S(n=>n.map(d=>d.id===t?{...d,collapsed:i}:d)),o?.(t,i)},[o]);return e.jsxs(P,{sensors:T,collisionDetection:Y,onDragStart:V,onDragEnd:L,children:[e.jsx("div",{className:k("flex gap-4 overflow-x-auto p-4",g),children:a.map(t=>{const i=m&&t.cards.length>r;return e.jsx(ne,{column:t,cards:t.cards,onToggle:n=>A(t.id,n),enableVirtual:i},t.id)})}),e.jsx(M,{children:v?e.jsx(E,{card:v}):null})]})}export{ve as KanbanEnhanced,ve as default};
1
+ import{r as c,j as e}from"./vendor-react-Dy_xkBQQ.js";import{u as F}from"./plugins-core-Cv2TPt86.js";import{u as H,a as K,D as P,c as Y,b as M,d as U,P as Z,e as z,S as q,v as G,C as J}from"./vendor-dndkit-DRGpK6sP.js";import{B as Q,a1 as I,Y as W,$ as X,a0 as _,ab as ee,Z as se}from"./ui-components-CseD2Dpn.js";import"./framework-mHWN965c.js";import"./vendor-ui-utils-h6yAcIi9.js";import{a as te,C as re,T as ae}from"./vendor-icons-CQ8b-fGy.js";import"./plugins-views-divN-xXs.js";import"./vendor-charts-CSvoW-yB.js";import"./vendor-i18n-D5KbMT7w.js";import"./vendor-radix-BbeYj_o4.js";const k=(...s)=>s.filter(Boolean).join(" ");function E({card:s}){const{attributes:x,listeners:o,setNodeRef:m,transform:r,transition:g,isDragging:v}=z({id:s.id}),f={transform:J.Transform.toString(r),transition:g,opacity:v?.5:void 0};return e.jsx("div",{ref:m,style:f,...x,...o,children:e.jsxs(W,{className:"mb-2 cursor-grab active:cursor-grabbing border-border bg-card/60 hover:border-primary/40 hover:shadow-lg hover:shadow-primary/10 transition-all duration-300 group",children:[e.jsxs(X,{className:"p-4",children:[e.jsx(_,{className:"text-sm font-medium font-mono tracking-tight text-foreground group-hover:text-primary transition-colors",children:s.title}),s.description&&e.jsx(ee,{className:"text-xs text-muted-foreground font-mono",children:s.description})]}),s.badges&&s.badges.length>0&&e.jsx(se,{className:"p-4 pt-0",children:e.jsx("div",{className:"flex flex-wrap gap-1",children:s.badges.map((l,a)=>e.jsx(I,{variant:l.variant||"default",className:"text-xs",children:l.label},a))})})]})})}function ie({cards:s,parentRef:x}){const o=F({count:s.length,getScrollElement:()=>x.current,estimateSize:()=>120,overscan:5});return e.jsx("div",{style:{height:`${o.getTotalSize()}px`,width:"100%",position:"relative"},children:o.getVirtualItems().map(m=>{const r=s[m.index];return e.jsx("div",{style:{position:"absolute",top:0,left:0,width:"100%",transform:`translateY(${m.start}px)`},children:e.jsx(E,{card:r})},r.id)})})}function ne({column:s,cards:x,onToggle:o,enableVirtual:m}){const r=x||[],g=c.useRef(null),{setNodeRef:v}=z({id:s.id,data:{type:"column"}}),f=s.limit&&r.length>=s.limit,l=s.limit&&r.length>=s.limit*.8;return e.jsxs("div",{ref:v,className:k("flex flex-col flex-shrink-0 rounded-lg border border-border bg-card/20 backdrop-blur-sm shadow-xl transition-all",s.collapsed?"w-16":"w-80",s.className),children:[e.jsxs("div",{className:"p-4 border-b border-border/50 bg-muted/20 flex items-center justify-between",children:[e.jsxs("div",{className:"flex items-center gap-2 flex-1 min-w-0",children:[e.jsx(Q,{variant:"ghost",size:"sm",className:"h-6 w-6 p-0",onClick:()=>o(!s.collapsed),children:s.collapsed?e.jsx(te,{className:"h-4 w-4"}):e.jsx(re,{className:"h-4 w-4"})}),!s.collapsed&&e.jsxs(e.Fragment,{children:[e.jsx("h3",{className:"font-mono text-sm font-semibold tracking-wider text-primary/90 uppercase truncate",children:s.title}),e.jsxs("div",{className:"flex items-center gap-2",children:[e.jsxs("span",{className:k("font-mono text-xs",f?"text-destructive":l?"text-yellow-500":"text-muted-foreground"),children:[r.length,s.limit&&` / ${s.limit}`]}),f&&e.jsx(I,{variant:"destructive",className:"text-xs",children:"Full"}),l&&!f&&e.jsx(ae,{className:"h-3 w-3 text-yellow-500"})]})]})]}),s.collapsed&&e.jsxs("div",{className:"flex flex-col items-center gap-1",children:[e.jsx("span",{className:"font-mono text-xs font-bold text-primary/90 [writing-mode:vertical-rl] rotate-180",children:s.title}),e.jsx(I,{variant:"secondary",className:"text-xs",children:r.length})]})]}),!s.collapsed&&e.jsx("div",{ref:g,className:"flex-1 p-4 overflow-y-auto",style:{maxHeight:"600px"},children:e.jsx(q,{items:r.map(a=>a.id),strategy:G,children:m?e.jsx(ie,{cards:r,parentRef:g}):e.jsx("div",{className:"space-y-2",children:r.map(a=>e.jsx(E,{card:a},a.id))})})})]})}function ve({columns:s,onCardMove:x,onColumnToggle:o,enableVirtualScrolling:m=!1,virtualScrollThreshold:r=50,className:g}){const[v,f]=c.useState(null),l=c.useMemo(()=>(s||[]).map(t=>({...t,cards:t.cards||[]})),[s]),[a,S]=c.useState(l);c.useEffect(()=>{S(l)},[l]);const T=H(K(Z,{activationConstraint:{distance:8}})),V=t=>{const{active:i}=t,n=$(i.id);f(n)},L=t=>{const{active:i,over:n}=t;if(f(null),!n)return;const d=i.id,b=n.id;if(d===b)return;const u=B(d),j=B(b)||O(b);if(!(!u||!j))if(u.id===j.id){const h=[...u.cards],C=h.findIndex(p=>p.id===d),D=h.findIndex(p=>p.id===b),R=U(h,C,D);S(p=>p.map(N=>N.id===u.id?{...N,cards:R}:N))}else{const h=[...u.cards],C=[...j.cards],D=h.findIndex(w=>w.id===d),p=b===j.id?C.length:C.findIndex(w=>w.id===b),[N]=h.splice(D,1);C.splice(p,0,N),S(w=>w.map(y=>y.id===u.id?{...y,cards:h}:y.id===j.id?{...y,cards:C}:y)),x&&x(d,u.id,j.id,p)}},$=c.useCallback(t=>{for(const i of a){const n=i.cards.find(d=>d.id===t);if(n)return n}return null},[a]),B=c.useCallback(t=>a.find(i=>i.cards.some(n=>n.id===t))||null,[a]),O=c.useCallback(t=>a.find(i=>i.id===t)||null,[a]),A=c.useCallback((t,i)=>{S(n=>n.map(d=>d.id===t?{...d,collapsed:i}:d)),o?.(t,i)},[o]);return e.jsxs(P,{sensors:T,collisionDetection:Y,onDragStart:V,onDragEnd:L,children:[e.jsx("div",{className:k("flex gap-4 overflow-x-auto p-4",g),children:a.map(t=>{const i=m&&t.cards.length>r;return e.jsx(ne,{column:t,cards:t.cards,onToggle:n=>A(t.id,n),enableVirtual:i},t.id)})}),e.jsx(M,{children:v?e.jsx(E,{card:v}):null})]})}export{ve as KanbanEnhanced,ve as default};
@@ -1 +1 @@
1
- import{j as e,r as h}from"./vendor-react-Dy_xkBQQ.js";import{u as H,a as B,D as L,c as Y,b as Z,d as q,T as z,P as G,e as E,S as J,v as M,C as Q}from"./vendor-dndkit-DRGpK6sP.js";import{a1 as K,aP as U,Y as V,$ as W,a0 as X,ab as _,Z as ee}from"./ui-components-DVonQS7H.js";import{i as se,j as re}from"./framework-mHWN965c.js";import"./vendor-ui-utils-h6yAcIi9.js";import"./vendor-icons-CQ8b-fGy.js";import"./vendor-radix-BbeYj_o4.js";import"./vendor-i18n-D5KbMT7w.js";import"./vendor-charts-CSvoW-yB.js";const P=(...s)=>s.filter(Boolean).join(" ");function T({card:s,onCardClick:i}){const{attributes:x,listeners:n,setNodeRef:a,transform:o,transition:c,isDragging:C}=E({id:s.id}),d={transform:Q.Transform.toString(o),transition:c,opacity:C?.5:void 0};return e.jsx("div",{ref:a,style:d,...x,...n,role:"listitem","aria-label":s.title,onClick:()=>i?.(s),children:e.jsxs(V,{className:"mb-2 cursor-grab active:cursor-grabbing border-border bg-card/60 hover:border-primary/40 hover:shadow-lg hover:shadow-primary/10 transition-all duration-300 group touch-manipulation",children:[e.jsxs(W,{className:"p-2 sm:p-4",children:[e.jsx(X,{className:"text-xs sm:text-sm font-medium font-mono tracking-tight text-foreground group-hover:text-primary transition-colors",children:s.title}),s.description&&e.jsx(_,{className:"text-xs text-muted-foreground font-mono line-clamp-2 sm:line-clamp-none",children:s.description})]}),s.badges&&s.badges.length>0&&e.jsx(ee,{className:"p-2 sm:p-4 pt-0",children:e.jsx("div",{className:"flex flex-wrap gap-1",children:s.badges.map((b,S)=>e.jsx(K,{variant:b.variant||"default",className:"text-xs",children:b.label},S))})})]})})}function ae({column:s,cards:i,onCardClick:x}){const n=i||[],{setNodeRef:a}=E({id:s.id,data:{type:"column"}}),o=s.limit&&n.length>=s.limit;return e.jsxs("div",{ref:a,role:"group","aria-label":s.title,className:P("flex flex-col w-[85vw] sm:w-80 flex-shrink-0 rounded-lg border border-border bg-card/20 backdrop-blur-sm shadow-xl snap-start",s.className),children:[e.jsx("div",{className:"p-3 sm:p-4 border-b border-border/50 bg-muted/20",children:e.jsxs("div",{className:"flex items-center justify-between",children:[e.jsx("h3",{id:`kanban-col-${s.id}`,className:"font-mono text-xs sm:text-sm font-semibold tracking-wider text-primary/90 uppercase truncate",children:s.title}),e.jsxs("div",{className:"flex items-center gap-2",children:[e.jsxs("span",{className:"font-mono text-xs text-muted-foreground","aria-label":`${n.length} cards${s.limit?` of ${s.limit} maximum`:""}`,children:[n.length,s.limit&&` / ${s.limit}`]}),o&&e.jsx(K,{variant:"destructive",className:"text-xs",children:"Full"})]})]})}),e.jsx(U,{className:"flex-1 p-4",children:e.jsx(J,{items:n.map(c=>c.id),strategy:M,children:e.jsx("div",{className:"space-y-2",role:"list","aria-label":`${s.title} cards`,children:n.map(c=>e.jsx(T,{card:c,onCardClick:x},c.id))})})})]})}function te({children:s}){const i=re();return e.jsx(e.Fragment,{children:s(i)})}function ue({columns:s,onCardMove:i,onCardClick:x,className:n}){return se()?e.jsx(te,{children:o=>e.jsx($,{columns:s,onCardMove:i,onCardClick:x,className:n,dnd:o})}):e.jsx($,{columns:s,onCardMove:i,onCardClick:x,className:n,dnd:null})}function $({columns:s,onCardMove:i,onCardClick:x,className:n,dnd:a}){const[o,c]=h.useState(null),C=h.useMemo(()=>(s||[]).map(r=>({...r,cards:r.cards||[]})),[s]),[d,b]=h.useState(C);h.useEffect(()=>{b(C)},[C]);const S=H(B(G,{activationConstraint:{distance:5}}),B(z,{activationConstraint:{delay:200,tolerance:5}})),O=r=>{const{active:m}=r,t=A(m.id);if(c(t),a&&t){const l=w(t.id);l&&a.startDrag({id:t.id,type:"kanban-card",data:t,sourceId:l.id})}},R=r=>{const{active:m,over:t}=r;if(c(null),!t){a&&a.endDrag();return}const l=m.id,v=t.id;if(l===v){a&&a.endDrag();return}const u=w(l),p=w(v)||F(v);if(!u||!p){a&&a.endDrag();return}if(u.id===p.id){const g=[...u.cards],j=g.findIndex(f=>f.id===l),I=g.findIndex(f=>f.id===v),k=q(g,j,I);b(f=>f.map(D=>D.id===u.id?{...D,cards:k}:D))}else{const g=[...u.cards],j=[...p.cards],I=g.findIndex(N=>N.id===l),f=v===p.id?j.length:j.findIndex(N=>N.id===v),[D]=g.splice(I,1);j.splice(f,0,D),b(N=>N.map(y=>y.id===u.id?{...y,cards:g}:y.id===p.id?{...y,cards:j}:y)),i&&i(l,u.id,p.id,f)}a&&a.endDrag(p.id)},A=h.useCallback(r=>{for(const m of d){const t=m.cards.find(l=>l.id===r);if(t)return t}return null},[d]),w=h.useCallback(r=>d.find(m=>m.cards.some(t=>t.id===r))||null,[d]),F=h.useCallback(r=>d.find(m=>m.id===r)||null,[d]);return e.jsxs(L,{sensors:S,collisionDetection:Y,onDragStart:O,onDragEnd:R,children:[e.jsxs("div",{className:"flex sm:hidden items-center justify-between px-3 pb-2 text-xs text-muted-foreground",children:[e.jsxs("span",{children:[d.length," columns"]}),e.jsx("span",{children:"← Swipe to navigate →"})]}),e.jsx("div",{className:P("flex gap-3 sm:gap-4 overflow-x-auto snap-x snap-mandatory p-2 sm:p-4 [-webkit-overflow-scrolling:touch]",n),role:"region","aria-label":"Kanban board",children:d.map(r=>e.jsx(ae,{column:r,cards:r.cards,onCardClick:x},r.id))}),e.jsx(Z,{children:e.jsx("div",{"aria-live":"assertive","aria-label":o?`Dragging ${o.title}`:void 0,children:o?e.jsx(T,{card:o}):null})})]})}export{ue as default};
1
+ import{j as e,r as h}from"./vendor-react-Dy_xkBQQ.js";import{u as H,a as B,D as L,c as Y,b as Z,d as q,T as z,P as G,e as E,S as J,v as M,C as Q}from"./vendor-dndkit-DRGpK6sP.js";import{a1 as K,aP as U,Y as V,$ as W,a0 as X,ab as _,Z as ee}from"./ui-components-CseD2Dpn.js";import{i as se,j as re}from"./framework-mHWN965c.js";import"./vendor-ui-utils-h6yAcIi9.js";import"./vendor-icons-CQ8b-fGy.js";import"./vendor-radix-BbeYj_o4.js";import"./vendor-i18n-D5KbMT7w.js";import"./vendor-charts-CSvoW-yB.js";const P=(...s)=>s.filter(Boolean).join(" ");function T({card:s,onCardClick:i}){const{attributes:x,listeners:n,setNodeRef:a,transform:o,transition:c,isDragging:C}=E({id:s.id}),d={transform:Q.Transform.toString(o),transition:c,opacity:C?.5:void 0};return e.jsx("div",{ref:a,style:d,...x,...n,role:"listitem","aria-label":s.title,onClick:()=>i?.(s),children:e.jsxs(V,{className:"mb-2 cursor-grab active:cursor-grabbing border-border bg-card/60 hover:border-primary/40 hover:shadow-lg hover:shadow-primary/10 transition-all duration-300 group touch-manipulation",children:[e.jsxs(W,{className:"p-2 sm:p-4",children:[e.jsx(X,{className:"text-xs sm:text-sm font-medium font-mono tracking-tight text-foreground group-hover:text-primary transition-colors",children:s.title}),s.description&&e.jsx(_,{className:"text-xs text-muted-foreground font-mono line-clamp-2 sm:line-clamp-none",children:s.description})]}),s.badges&&s.badges.length>0&&e.jsx(ee,{className:"p-2 sm:p-4 pt-0",children:e.jsx("div",{className:"flex flex-wrap gap-1",children:s.badges.map((b,S)=>e.jsx(K,{variant:b.variant||"default",className:"text-xs",children:b.label},S))})})]})})}function ae({column:s,cards:i,onCardClick:x}){const n=i||[],{setNodeRef:a}=E({id:s.id,data:{type:"column"}}),o=s.limit&&n.length>=s.limit;return e.jsxs("div",{ref:a,role:"group","aria-label":s.title,className:P("flex flex-col w-[85vw] sm:w-80 flex-shrink-0 rounded-lg border border-border bg-card/20 backdrop-blur-sm shadow-xl snap-start",s.className),children:[e.jsx("div",{className:"p-3 sm:p-4 border-b border-border/50 bg-muted/20",children:e.jsxs("div",{className:"flex items-center justify-between",children:[e.jsx("h3",{id:`kanban-col-${s.id}`,className:"font-mono text-xs sm:text-sm font-semibold tracking-wider text-primary/90 uppercase truncate",children:s.title}),e.jsxs("div",{className:"flex items-center gap-2",children:[e.jsxs("span",{className:"font-mono text-xs text-muted-foreground","aria-label":`${n.length} cards${s.limit?` of ${s.limit} maximum`:""}`,children:[n.length,s.limit&&` / ${s.limit}`]}),o&&e.jsx(K,{variant:"destructive",className:"text-xs",children:"Full"})]})]})}),e.jsx(U,{className:"flex-1 p-4",children:e.jsx(J,{items:n.map(c=>c.id),strategy:M,children:e.jsx("div",{className:"space-y-2",role:"list","aria-label":`${s.title} cards`,children:n.map(c=>e.jsx(T,{card:c,onCardClick:x},c.id))})})})]})}function te({children:s}){const i=re();return e.jsx(e.Fragment,{children:s(i)})}function ue({columns:s,onCardMove:i,onCardClick:x,className:n}){return se()?e.jsx(te,{children:o=>e.jsx($,{columns:s,onCardMove:i,onCardClick:x,className:n,dnd:o})}):e.jsx($,{columns:s,onCardMove:i,onCardClick:x,className:n,dnd:null})}function $({columns:s,onCardMove:i,onCardClick:x,className:n,dnd:a}){const[o,c]=h.useState(null),C=h.useMemo(()=>(s||[]).map(r=>({...r,cards:r.cards||[]})),[s]),[d,b]=h.useState(C);h.useEffect(()=>{b(C)},[C]);const S=H(B(G,{activationConstraint:{distance:5}}),B(z,{activationConstraint:{delay:200,tolerance:5}})),O=r=>{const{active:m}=r,t=A(m.id);if(c(t),a&&t){const l=w(t.id);l&&a.startDrag({id:t.id,type:"kanban-card",data:t,sourceId:l.id})}},R=r=>{const{active:m,over:t}=r;if(c(null),!t){a&&a.endDrag();return}const l=m.id,v=t.id;if(l===v){a&&a.endDrag();return}const u=w(l),p=w(v)||F(v);if(!u||!p){a&&a.endDrag();return}if(u.id===p.id){const g=[...u.cards],j=g.findIndex(f=>f.id===l),I=g.findIndex(f=>f.id===v),k=q(g,j,I);b(f=>f.map(D=>D.id===u.id?{...D,cards:k}:D))}else{const g=[...u.cards],j=[...p.cards],I=g.findIndex(N=>N.id===l),f=v===p.id?j.length:j.findIndex(N=>N.id===v),[D]=g.splice(I,1);j.splice(f,0,D),b(N=>N.map(y=>y.id===u.id?{...y,cards:g}:y.id===p.id?{...y,cards:j}:y)),i&&i(l,u.id,p.id,f)}a&&a.endDrag(p.id)},A=h.useCallback(r=>{for(const m of d){const t=m.cards.find(l=>l.id===r);if(t)return t}return null},[d]),w=h.useCallback(r=>d.find(m=>m.cards.some(t=>t.id===r))||null,[d]),F=h.useCallback(r=>d.find(m=>m.id===r)||null,[d]);return e.jsxs(L,{sensors:S,collisionDetection:Y,onDragStart:O,onDragEnd:R,children:[e.jsxs("div",{className:"flex sm:hidden items-center justify-between px-3 pb-2 text-xs text-muted-foreground",children:[e.jsxs("span",{children:[d.length," columns"]}),e.jsx("span",{children:"← Swipe to navigate →"})]}),e.jsx("div",{className:P("flex gap-3 sm:gap-4 overflow-x-auto snap-x snap-mandatory p-2 sm:p-4 [-webkit-overflow-scrolling:touch]",n),role:"region","aria-label":"Kanban board",children:d.map(r=>e.jsx(ae,{column:r,cards:r.cards,onCardClick:x},r.id))}),e.jsx(Z,{children:e.jsx("div",{"aria-live":"assertive","aria-label":o?`Dragging ${o.title}`:void 0,children:o?e.jsx(T,{card:o}):null})})]})}export{ue as default};
@@ -1 +1 @@
1
- import{i as s,j as r}from"./vendor-react-Dy_xkBQQ.js";import{L as o}from"./infrastructure-aS2LF8OZ.js";import"./vendor-i18n-D5KbMT7w.js";function a(){const e=s();return r.jsx("div",{className:"flex min-h-screen items-center justify-center bg-background px-4 py-8",children:r.jsx(o,{onSuccess:()=>e("/"),registerUrl:"/register",forgotPasswordUrl:"/forgot-password"})})}export{a as LoginPage};
1
+ import{i as s,j as r}from"./vendor-react-Dy_xkBQQ.js";import{L as o}from"./infrastructure-Di0WqY4l.js";import"./vendor-i18n-D5KbMT7w.js";function a(){const e=s();return r.jsx("div",{className:"flex min-h-screen items-center justify-center bg-background px-4 py-8",children:r.jsx(o,{onSuccess:()=>e("/"),registerUrl:"/register",forgotPasswordUrl:"/forgot-password"})})}export{a as LoginPage};
@@ -1 +1 @@
1
- import{j as e}from"./vendor-react-Dy_xkBQQ.js";import{u as l}from"./infrastructure-aS2LF8OZ.js";import{B as d,Y as c,Z as o,a1 as x}from"./ui-components-DVonQS7H.js";import"./framework-mHWN965c.js";import"./vendor-ui-utils-h6yAcIi9.js";import{s as p}from"./systemObjects-DSpePIIy.js";import{bv as r,m as h}from"./vendor-icons-CQ8b-fGy.js";import"./vendor-i18n-D5KbMT7w.js";import"./vendor-radix-BbeYj_o4.js";import"./vendor-charts-CSvoW-yB.js";const a=p.find(s=>s.name==="sys_org");function z(){const{user:s}=l(),n=s?.role==="admin";return e.jsxs("div",{className:"flex flex-col gap-4 sm:gap-6 p-4 sm:p-6",children:[e.jsxs("div",{className:"flex flex-col sm:flex-row sm:items-center sm:justify-between gap-3",children:[e.jsxs("div",{className:"flex items-center gap-3 min-w-0",children:[e.jsx("div",{className:"bg-primary/10 p-2 rounded-md shrink-0",children:e.jsx(r,{className:"h-5 w-5 text-primary"})}),e.jsxs("div",{className:"min-w-0",children:[e.jsx("h1",{className:"text-xl sm:text-2xl font-bold tracking-tight",children:"Organization Management"}),e.jsx("p",{className:"text-sm text-muted-foreground mt-0.5",children:"Manage organizations and their members"})]})]}),n&&e.jsxs(d,{size:"sm",className:"shrink-0 gap-2",children:[e.jsx(h,{className:"h-4 w-4"}),"Add Organization"]})]}),e.jsx(c,{children:e.jsx(o,{className:"p-0",children:e.jsx("div",{className:"overflow-x-auto",children:e.jsxs("table",{className:"w-full text-sm",children:[e.jsx("thead",{children:e.jsx("tr",{className:"border-b bg-muted/50",children:a.views[0].columns.map(t=>{const i=a.fields.find(m=>m.name===t);return e.jsx("th",{className:"h-10 px-3 sm:px-4 text-left font-medium text-muted-foreground whitespace-nowrap",children:i?.label??t},t)})})}),e.jsx("tbody",{children:e.jsx("tr",{children:e.jsx("td",{className:"p-4 sm:p-6 text-center text-sm text-muted-foreground",colSpan:a.views[0].columns.length,children:e.jsxs("div",{className:"flex flex-col items-center gap-2 py-4",children:[e.jsx(r,{className:"h-8 w-8 text-muted-foreground/50"}),e.jsx("p",{children:"Connect to ObjectStack server to load organizations."}),e.jsx(x,{variant:"secondary",className:"text-xs",children:"plugin-grid powered"})]})})})})]})})})})]})}export{z as OrgManagementPage};
1
+ import{j as e}from"./vendor-react-Dy_xkBQQ.js";import{u as l}from"./infrastructure-Di0WqY4l.js";import{B as d,Y as c,Z as o,a1 as x}from"./ui-components-CseD2Dpn.js";import"./framework-mHWN965c.js";import"./vendor-ui-utils-h6yAcIi9.js";import{s as p}from"./systemObjects-DSpePIIy.js";import{bv as r,m as h}from"./vendor-icons-CQ8b-fGy.js";import"./vendor-i18n-D5KbMT7w.js";import"./vendor-radix-BbeYj_o4.js";import"./vendor-charts-CSvoW-yB.js";const a=p.find(s=>s.name==="sys_org");function z(){const{user:s}=l(),n=s?.role==="admin";return e.jsxs("div",{className:"flex flex-col gap-4 sm:gap-6 p-4 sm:p-6",children:[e.jsxs("div",{className:"flex flex-col sm:flex-row sm:items-center sm:justify-between gap-3",children:[e.jsxs("div",{className:"flex items-center gap-3 min-w-0",children:[e.jsx("div",{className:"bg-primary/10 p-2 rounded-md shrink-0",children:e.jsx(r,{className:"h-5 w-5 text-primary"})}),e.jsxs("div",{className:"min-w-0",children:[e.jsx("h1",{className:"text-xl sm:text-2xl font-bold tracking-tight",children:"Organization Management"}),e.jsx("p",{className:"text-sm text-muted-foreground mt-0.5",children:"Manage organizations and their members"})]})]}),n&&e.jsxs(d,{size:"sm",className:"shrink-0 gap-2",children:[e.jsx(h,{className:"h-4 w-4"}),"Add Organization"]})]}),e.jsx(c,{children:e.jsx(o,{className:"p-0",children:e.jsx("div",{className:"overflow-x-auto",children:e.jsxs("table",{className:"w-full text-sm",children:[e.jsx("thead",{children:e.jsx("tr",{className:"border-b bg-muted/50",children:a.views[0].columns.map(t=>{const i=a.fields.find(m=>m.name===t);return e.jsx("th",{className:"h-10 px-3 sm:px-4 text-left font-medium text-muted-foreground whitespace-nowrap",children:i?.label??t},t)})})}),e.jsx("tbody",{children:e.jsx("tr",{children:e.jsx("td",{className:"p-4 sm:p-6 text-center text-sm text-muted-foreground",colSpan:a.views[0].columns.length,children:e.jsxs("div",{className:"flex flex-col items-center gap-2 py-4",children:[e.jsx(r,{className:"h-8 w-8 text-muted-foreground/50"}),e.jsx("p",{children:"Connect to ObjectStack server to load organizations."}),e.jsx(x,{variant:"secondary",className:"text-xs",children:"plugin-grid powered"})]})})})})]})})})})]})}export{z as OrgManagementPage};
@@ -0,0 +1 @@
1
+ import{h as l,k as p,j as e}from"./vendor-react-Dy_xkBQQ.js";import{S as c}from"./framework-mHWN965c.js";import{aH as d,aI as u,aJ as f}from"./ui-components-CseD2Dpn.js";import"./vendor-ui-utils-h6yAcIi9.js";import{u as h,b as x,M as g,a as j}from"./index-RAPqkKVL.js";import{a1 as v}from"./vendor-icons-CQ8b-fGy.js";import"./vendor-radix-BbeYj_o4.js";import"./vendor-i18n-D5KbMT7w.js";import"./vendor-charts-CSvoW-yB.js";import"./plugins-core-Cv2TPt86.js";import"./plugins-views-divN-xXs.js";import"./infrastructure-Di0WqY4l.js";import"./data-adapter-D15yh-pb.js";import"./vendor-objectstack-Bifvxvds.js";import"./vendor-zod-UZPqlszj.js";import"./ui-layout-CF_1bNSv.js";function H(){const{pageName:s}=l(),[o]=p(),{showDebug:a,toggleDebug:r}=h(),{pages:i}=x(),t=i?.find(n=>n.name===s);if(!t)return e.jsx("div",{className:"h-full flex items-center justify-center p-8",children:e.jsxs(d,{children:[e.jsx("div",{className:"mx-auto mb-4 flex h-12 w-12 items-center justify-center rounded-full bg-muted",children:e.jsx(v,{className:"h-6 w-6 text-muted-foreground"})}),e.jsx(u,{children:"Page Not Found"}),e.jsxs(f,{children:['The page "',s,'" could not be found. It may have been removed or renamed.']})]})});const m=Object.fromEntries(o.entries());return e.jsxs("div",{className:"flex flex-row h-full w-full overflow-hidden relative",children:[e.jsxs("div",{className:"flex-1 overflow-auto h-full relative group",children:[e.jsx("div",{className:`absolute top-1.5 sm:top-2 right-1.5 sm:right-2 z-50 transition-opacity ${a?"opacity-100":"opacity-0 group-hover:opacity-100"}`,children:e.jsx(g,{open:a,onToggle:r})}),e.jsx(c,{schema:{...t,type:t.type||"page",context:{...t.context,params:m}}})]}),e.jsx(j,{open:a,sections:[{title:"Page Configuration",data:t}]})]})}export{H as PageView};
@@ -1 +1 @@
1
- import{r as l,j as e}from"./vendor-react-Dy_xkBQQ.js";import{u as w,g as C}from"./infrastructure-aS2LF8OZ.js";import{Y as i,Z as u,ap as S,aq as A,ar as E,a1 as P,$ as h,a0 as p,ab as j,aN as g,aO as f,L as n,M as c,B as U}from"./ui-components-DVonQS7H.js";import"./framework-mHWN965c.js";import"./vendor-ui-utils-h6yAcIi9.js";import{by as k,h as I,g as L,bz as B}from"./vendor-icons-CQ8b-fGy.js";import"./vendor-i18n-D5KbMT7w.js";import"./vendor-radix-BbeYj_o4.js";import"./vendor-charts-CSvoW-yB.js";function Y(){const{user:s,updateUser:N,isLoading:a}=w(),[d,v]=l.useState(s?.name??""),[b,m]=l.useState(!1),[o,x]=l.useState(null),y=async t=>{t.preventDefault(),x(null),m(!1);try{await N({name:d}),m(!0)}catch(r){x(r instanceof Error?r.message:String(r))}};return s?e.jsxs("div",{className:"flex flex-col gap-4 sm:gap-6 p-4 sm:p-6 max-w-2xl",children:[e.jsxs("div",{className:"min-w-0",children:[e.jsx("h1",{className:"text-xl sm:text-2xl font-bold tracking-tight",children:"Profile"}),e.jsx("p",{className:"text-sm text-muted-foreground mt-1",children:"Manage your account settings"})]}),e.jsx(i,{children:e.jsx(u,{className:"pt-6",children:e.jsxs("div",{className:"flex items-center gap-4",children:[e.jsxs(S,{className:"h-16 w-16",children:[e.jsx(A,{src:s.image??void 0,alt:s.name??"User"}),e.jsx(E,{className:"text-lg bg-primary text-primary-foreground",children:C(s)})]}),e.jsxs("div",{className:"min-w-0 flex-1",children:[e.jsx("p",{className:"text-lg font-semibold truncate",children:s.name??"User"}),e.jsx("p",{className:"text-sm text-muted-foreground truncate",children:s.email}),e.jsx(P,{variant:"secondary",className:"mt-1",children:s.role??"member"})]})]})})}),e.jsxs(i,{children:[e.jsxs(h,{children:[e.jsxs("div",{className:"flex items-center gap-2",children:[e.jsx(k,{className:"h-4 w-4 text-muted-foreground"}),e.jsx(p,{className:"text-base sm:text-lg",children:"Personal Information"})]}),e.jsx(j,{children:"Update your name and view account details"})]}),e.jsx(u,{children:e.jsxs("form",{onSubmit:y,className:"space-y-4",children:[o&&e.jsxs(g,{variant:"destructive",children:[e.jsx(I,{className:"h-4 w-4"}),e.jsx(f,{children:o})]}),b&&e.jsxs(g,{children:[e.jsx(L,{className:"h-4 w-4 text-green-600"}),e.jsx(f,{className:"text-green-800 dark:text-green-400",children:"Profile updated successfully."})]}),e.jsxs("div",{className:"space-y-2",children:[e.jsx(n,{htmlFor:"profile-name",children:"Name"}),e.jsx(c,{id:"profile-name",type:"text",value:d,onChange:t=>v(t.target.value),required:!0,disabled:a})]}),e.jsxs("div",{className:"space-y-2",children:[e.jsx(n,{htmlFor:"profile-email",children:"Email"}),e.jsx(c,{id:"profile-email",type:"email",value:s.email,disabled:!0,className:"bg-muted text-muted-foreground"}),e.jsx("p",{className:"text-xs text-muted-foreground",children:"Email cannot be changed."})]}),e.jsxs("div",{className:"space-y-2",children:[e.jsx(n,{children:"Role"}),e.jsx(c,{type:"text",value:s.role??"member",disabled:!0,className:"bg-muted text-muted-foreground"})]}),e.jsx(U,{type:"submit",disabled:a,className:"w-full sm:w-auto",children:a?"Saving...":"Save Changes"})]})})]}),e.jsx(i,{children:e.jsxs(h,{children:[e.jsxs("div",{className:"flex items-center gap-2",children:[e.jsx(B,{className:"h-4 w-4 text-muted-foreground"}),e.jsx(p,{className:"text-base sm:text-lg",children:"Change Password"})]}),e.jsx(j,{children:"To change your password, use the password reset flow from the login page."})]})})]}):null}export{Y as ProfilePage};
1
+ import{r as l,j as e}from"./vendor-react-Dy_xkBQQ.js";import{u as w,g as C}from"./infrastructure-Di0WqY4l.js";import{Y as i,Z as u,ap as S,aq as A,ar as E,a1 as P,$ as h,a0 as p,ab as j,aN as g,aO as f,L as n,M as c,B as U}from"./ui-components-CseD2Dpn.js";import"./framework-mHWN965c.js";import"./vendor-ui-utils-h6yAcIi9.js";import{by as k,h as I,g as L,bz as B}from"./vendor-icons-CQ8b-fGy.js";import"./vendor-i18n-D5KbMT7w.js";import"./vendor-radix-BbeYj_o4.js";import"./vendor-charts-CSvoW-yB.js";function Y(){const{user:s,updateUser:N,isLoading:a}=w(),[d,v]=l.useState(s?.name??""),[b,m]=l.useState(!1),[o,x]=l.useState(null),y=async t=>{t.preventDefault(),x(null),m(!1);try{await N({name:d}),m(!0)}catch(r){x(r instanceof Error?r.message:String(r))}};return s?e.jsxs("div",{className:"flex flex-col gap-4 sm:gap-6 p-4 sm:p-6 max-w-2xl",children:[e.jsxs("div",{className:"min-w-0",children:[e.jsx("h1",{className:"text-xl sm:text-2xl font-bold tracking-tight",children:"Profile"}),e.jsx("p",{className:"text-sm text-muted-foreground mt-1",children:"Manage your account settings"})]}),e.jsx(i,{children:e.jsx(u,{className:"pt-6",children:e.jsxs("div",{className:"flex items-center gap-4",children:[e.jsxs(S,{className:"h-16 w-16",children:[e.jsx(A,{src:s.image??void 0,alt:s.name??"User"}),e.jsx(E,{className:"text-lg bg-primary text-primary-foreground",children:C(s)})]}),e.jsxs("div",{className:"min-w-0 flex-1",children:[e.jsx("p",{className:"text-lg font-semibold truncate",children:s.name??"User"}),e.jsx("p",{className:"text-sm text-muted-foreground truncate",children:s.email}),e.jsx(P,{variant:"secondary",className:"mt-1",children:s.role??"member"})]})]})})}),e.jsxs(i,{children:[e.jsxs(h,{children:[e.jsxs("div",{className:"flex items-center gap-2",children:[e.jsx(k,{className:"h-4 w-4 text-muted-foreground"}),e.jsx(p,{className:"text-base sm:text-lg",children:"Personal Information"})]}),e.jsx(j,{children:"Update your name and view account details"})]}),e.jsx(u,{children:e.jsxs("form",{onSubmit:y,className:"space-y-4",children:[o&&e.jsxs(g,{variant:"destructive",children:[e.jsx(I,{className:"h-4 w-4"}),e.jsx(f,{children:o})]}),b&&e.jsxs(g,{children:[e.jsx(L,{className:"h-4 w-4 text-green-600"}),e.jsx(f,{className:"text-green-800 dark:text-green-400",children:"Profile updated successfully."})]}),e.jsxs("div",{className:"space-y-2",children:[e.jsx(n,{htmlFor:"profile-name",children:"Name"}),e.jsx(c,{id:"profile-name",type:"text",value:d,onChange:t=>v(t.target.value),required:!0,disabled:a})]}),e.jsxs("div",{className:"space-y-2",children:[e.jsx(n,{htmlFor:"profile-email",children:"Email"}),e.jsx(c,{id:"profile-email",type:"email",value:s.email,disabled:!0,className:"bg-muted text-muted-foreground"}),e.jsx("p",{className:"text-xs text-muted-foreground",children:"Email cannot be changed."})]}),e.jsxs("div",{className:"space-y-2",children:[e.jsx(n,{children:"Role"}),e.jsx(c,{type:"text",value:s.role??"member",disabled:!0,className:"bg-muted text-muted-foreground"})]}),e.jsx(U,{type:"submit",disabled:a,className:"w-full sm:w-auto",children:a?"Saving...":"Save Changes"})]})})]}),e.jsx(i,{children:e.jsxs(h,{children:[e.jsxs("div",{className:"flex items-center gap-2",children:[e.jsx(B,{className:"h-4 w-4 text-muted-foreground"}),e.jsx(p,{className:"text-base sm:text-lg",children:"Change Password"})]}),e.jsx(j,{children:"To change your password, use the password reset flow from the login page."})]})})]}):null}export{Y as ProfilePage};
@@ -1 +1 @@
1
- import{j as e,h as f,r as x}from"./vendor-react-Dy_xkBQQ.js";import{D as j}from"./plugins-views-DQwkCaaO.js";import{a9 as s,aH as u,aI as N,aJ as g}from"./ui-components-DVonQS7H.js";import"./framework-mHWN965c.js";import"./vendor-ui-utils-h6yAcIi9.js";import{u as w,M as v,a as b}from"./index-BjEGJcpx.js";import{as as y}from"./vendor-icons-CQ8b-fGy.js";import"./vendor-charts-CSvoW-yB.js";import"./vendor-i18n-D5KbMT7w.js";import"./vendor-radix-BbeYj_o4.js";import"./plugins-core-CcBSZCjG.js";import"./data-adapter-Cn800k4a.js";import"./vendor-objectstack-DqojdwYW.js";import"./vendor-zod-Dpl-cylz.js";import"./infrastructure-aS2LF8OZ.js";import"./ui-layout-BENIRxAF.js";function D({fields:r=8,columns:c=2}){return e.jsxs("div",{className:"w-full space-y-6 p-4 sm:p-6",children:[e.jsxs("div",{className:"flex items-center justify-between",children:[e.jsxs("div",{className:"flex items-center gap-3",children:[e.jsx(s,{className:"h-8 w-8 rounded"}),e.jsxs("div",{className:"space-y-2",children:[e.jsx(s,{className:"h-6 w-48"}),e.jsx(s,{className:"h-4 w-32"})]})]}),e.jsxs("div",{className:"flex items-center gap-2",children:[e.jsx(s,{className:"h-9 w-20"}),e.jsx(s,{className:"h-9 w-20"})]})]}),e.jsx(s,{className:"h-5 w-24"}),e.jsx("div",{className:`grid grid-cols-1 ${c===2?"md:grid-cols-2":""} gap-4`,children:Array.from({length:r}).map((o,a)=>e.jsxs("div",{className:"space-y-2",children:[e.jsx(s,{className:"h-4 w-24"}),e.jsx(s,{className:"h-9 w-full"})]},`field-${a}`))}),e.jsxs("div",{className:"space-y-3 pt-4 border-t",children:[e.jsx(s,{className:"h-5 w-32"}),e.jsx("div",{className:"space-y-2",children:Array.from({length:3}).map((o,a)=>e.jsxs("div",{className:"flex items-center gap-3 py-2",children:[e.jsx(s,{className:"h-8 w-8 rounded-full"}),e.jsxs("div",{className:"flex-1 space-y-1",children:[e.jsx(s,{className:"h-4 w-40"}),e.jsx(s,{className:"h-3 w-24"})]})]},`related-${a}`))})]})]})}function z({dataSource:r,objects:c,onEdit:o}){const{objectName:a,recordId:i}=f(),{showDebug:m,toggleDebug:p}=w(),[h,d]=x.useState(!0),t=c.find(l=>l.name===a);if(x.useEffect(()=>{d(!0),queueMicrotask(()=>d(!1))},[a,i]),h)return e.jsx(D,{});if(!t)return e.jsx("div",{className:"flex h-full items-center justify-center p-4",children:e.jsxs(u,{children:[e.jsx("div",{className:"mx-auto mb-4 flex h-12 w-12 items-center justify-center rounded-full bg-muted",children:e.jsx(y,{className:"h-6 w-6 text-muted-foreground"})}),e.jsx(N,{children:"Object Not Found"}),e.jsxs(g,{children:['Object "',a,'" definition missing. Check your configuration or navigate back to select a valid object.']})]})});const n={type:"detail-view",objectName:t.name,resourceId:i,showBack:!0,onBack:"history",showEdit:!0,title:t.label,sections:[{title:"Details",fields:Object.keys(t.fields||{}).map(l=>({name:l,label:t.fields[l].label||l,type:t.fields[l].type||"text"})),columns:2}]};return e.jsxs("div",{className:"h-full bg-background overflow-hidden flex flex-col relative",children:[e.jsx("div",{className:"absolute top-2 sm:top-4 right-2 sm:right-4 z-50",children:e.jsx(v,{open:m,onToggle:p})}),e.jsxs("div",{className:"flex-1 overflow-hidden flex flex-row",children:[e.jsx("div",{className:"flex-1 overflow-auto p-3 sm:p-4 lg:p-6 scroll-pb-48",children:e.jsx(j,{schema:n,dataSource:r,onEdit:()=>o({_id:i,id:i})})}),e.jsx(b,{open:m,sections:[{title:"View Schema",data:n}]})]})]})}export{z as RecordDetailView};
1
+ import{j as e,h as f,r as x}from"./vendor-react-Dy_xkBQQ.js";import{D as j}from"./plugins-views-divN-xXs.js";import{a9 as s,aH as u,aI as N,aJ as g}from"./ui-components-CseD2Dpn.js";import"./framework-mHWN965c.js";import"./vendor-ui-utils-h6yAcIi9.js";import{u as w,M as v,a as b}from"./index-RAPqkKVL.js";import{as as y}from"./vendor-icons-CQ8b-fGy.js";import"./vendor-charts-CSvoW-yB.js";import"./vendor-i18n-D5KbMT7w.js";import"./vendor-radix-BbeYj_o4.js";import"./plugins-core-Cv2TPt86.js";import"./infrastructure-Di0WqY4l.js";import"./data-adapter-D15yh-pb.js";import"./vendor-objectstack-Bifvxvds.js";import"./vendor-zod-UZPqlszj.js";import"./ui-layout-CF_1bNSv.js";function D({fields:r=8,columns:c=2}){return e.jsxs("div",{className:"w-full space-y-6 p-4 sm:p-6",children:[e.jsxs("div",{className:"flex items-center justify-between",children:[e.jsxs("div",{className:"flex items-center gap-3",children:[e.jsx(s,{className:"h-8 w-8 rounded"}),e.jsxs("div",{className:"space-y-2",children:[e.jsx(s,{className:"h-6 w-48"}),e.jsx(s,{className:"h-4 w-32"})]})]}),e.jsxs("div",{className:"flex items-center gap-2",children:[e.jsx(s,{className:"h-9 w-20"}),e.jsx(s,{className:"h-9 w-20"})]})]}),e.jsx(s,{className:"h-5 w-24"}),e.jsx("div",{className:`grid grid-cols-1 ${c===2?"md:grid-cols-2":""} gap-4`,children:Array.from({length:r}).map((o,a)=>e.jsxs("div",{className:"space-y-2",children:[e.jsx(s,{className:"h-4 w-24"}),e.jsx(s,{className:"h-9 w-full"})]},`field-${a}`))}),e.jsxs("div",{className:"space-y-3 pt-4 border-t",children:[e.jsx(s,{className:"h-5 w-32"}),e.jsx("div",{className:"space-y-2",children:Array.from({length:3}).map((o,a)=>e.jsxs("div",{className:"flex items-center gap-3 py-2",children:[e.jsx(s,{className:"h-8 w-8 rounded-full"}),e.jsxs("div",{className:"flex-1 space-y-1",children:[e.jsx(s,{className:"h-4 w-40"}),e.jsx(s,{className:"h-3 w-24"})]})]},`related-${a}`))})]})]})}function z({dataSource:r,objects:c,onEdit:o}){const{objectName:a,recordId:i}=f(),{showDebug:m,toggleDebug:p}=w(),[h,d]=x.useState(!0),t=c.find(l=>l.name===a);if(x.useEffect(()=>{d(!0),queueMicrotask(()=>d(!1))},[a,i]),h)return e.jsx(D,{});if(!t)return e.jsx("div",{className:"flex h-full items-center justify-center p-4",children:e.jsxs(u,{children:[e.jsx("div",{className:"mx-auto mb-4 flex h-12 w-12 items-center justify-center rounded-full bg-muted",children:e.jsx(y,{className:"h-6 w-6 text-muted-foreground"})}),e.jsx(N,{children:"Object Not Found"}),e.jsxs(g,{children:['Object "',a,'" definition missing. Check your configuration or navigate back to select a valid object.']})]})});const n={type:"detail-view",objectName:t.name,resourceId:i,showBack:!0,onBack:"history",showEdit:!0,title:t.label,sections:[{title:"Details",fields:Object.keys(t.fields||{}).map(l=>({name:l,label:t.fields[l].label||l,type:t.fields[l].type||"text"})),columns:2}]};return e.jsxs("div",{className:"h-full bg-background overflow-hidden flex flex-col relative",children:[e.jsx("div",{className:"absolute top-2 sm:top-4 right-2 sm:right-4 z-50",children:e.jsx(v,{open:m,onToggle:p})}),e.jsxs("div",{className:"flex-1 overflow-hidden flex flex-row",children:[e.jsx("div",{className:"flex-1 overflow-auto p-3 sm:p-4 lg:p-6 scroll-pb-48",children:e.jsx(j,{schema:n,dataSource:r,onEdit:()=>o({_id:i,id:i})})}),e.jsx(b,{open:m,sections:[{title:"View Schema",data:n}]})]})]})}export{z as RecordDetailView};
@@ -1 +1 @@
1
- import{i as s,j as e}from"./vendor-react-Dy_xkBQQ.js";import{R as i}from"./infrastructure-aS2LF8OZ.js";import"./vendor-i18n-D5KbMT7w.js";function a(){const r=s();return e.jsx("div",{className:"flex min-h-screen items-center justify-center bg-background px-4 py-8",children:e.jsx(i,{onSuccess:()=>r("/"),loginUrl:"/login"})})}export{a as RegisterPage};
1
+ import{i as s,j as e}from"./vendor-react-Dy_xkBQQ.js";import{R as i}from"./infrastructure-Di0WqY4l.js";import"./vendor-i18n-D5KbMT7w.js";function a(){const r=s();return e.jsx("div",{className:"flex min-h-screen items-center justify-center bg-background px-4 py-8",children:e.jsx(i,{onSuccess:()=>r("/"),loginUrl:"/login"})})}export{a as RegisterPage};
@@ -0,0 +1 @@
1
+ import{h as f,r as n,j as e}from"./vendor-react-Dy_xkBQQ.js";import{R as g,b}from"./plugins-views-divN-xXs.js";import{aH as j,aI as v,aJ as N,B as m}from"./ui-components-CseD2Dpn.js";import"./framework-mHWN965c.js";import"./vendor-ui-utils-h6yAcIi9.js";import{u as w,b as y,M as R,a as E}from"./index-RAPqkKVL.js";import{L as S,aE as k,b as C,aP as M}from"./vendor-icons-CQ8b-fGy.js";import"./vendor-charts-CSvoW-yB.js";import"./vendor-i18n-D5KbMT7w.js";import"./vendor-radix-BbeYj_o4.js";import"./plugins-core-Cv2TPt86.js";import"./infrastructure-Di0WqY4l.js";import"./data-adapter-D15yh-pb.js";import"./vendor-objectstack-Bifvxvds.js";import"./vendor-zod-UZPqlszj.js";import"./ui-layout-CF_1bNSv.js";const B=[{name:"month",label:"Month",type:"string"},{name:"revenue",label:"Revenue",type:"number"},{name:"count",label:"Count",type:"number"},{name:"region",label:"Region",type:"string"},{name:"product",label:"Product",type:"string"},{name:"source",label:"Lead Source",type:"string"},{name:"stage",label:"Stage",type:"string"},{name:"amount",label:"Amount",type:"currency"}];function U({dataSource:D}){const{reportName:o}=f(),{showDebug:l,toggleDebug:d}=w(),[c,t]=n.useState(!1),{reports:u,loading:p}=y(),a=u?.find(r=>r.name===o),[s,i]=n.useState(a);if(n.useEffect(()=>{i(a)},[a]),p)return e.jsx("div",{className:"h-full flex items-center justify-center p-8",children:e.jsx(S,{className:"h-8 w-8 animate-spin text-muted-foreground"})});if(!a)return e.jsx("div",{className:"h-full flex items-center justify-center p-8",children:e.jsxs(j,{children:[e.jsx("div",{className:"mx-auto mb-4 flex h-12 w-12 items-center justify-center rounded-full bg-muted",children:e.jsx(k,{className:"h-6 w-6 text-muted-foreground"})}),e.jsx(v,{children:"Report Not Found"}),e.jsxs(N,{children:['The report "',o,'" could not be found. It may have been removed or renamed.']})]})});const x=r=>{console.log("Saving report:",r),i(r),t(!1)};if(c)return e.jsxs("div",{className:"flex flex-col h-full overflow-hidden bg-background",children:[e.jsxs("div",{className:"flex items-center p-3 sm:p-4 border-b bg-muted/10 gap-2",children:[e.jsxs(m,{variant:"ghost",size:"sm",onClick:()=>t(!1),className:"shrink-0",children:[e.jsx(C,{className:"h-4 w-4 mr-1"}),e.jsx("span",{className:"hidden sm:inline",children:"Back to View"}),e.jsx("span",{className:"sm:hidden",children:"Back"})]}),e.jsxs("div",{className:"font-medium truncate",children:["Edit Report: ",s.title]})]}),e.jsx("div",{className:"flex-1 overflow-auto",children:e.jsx(g,{schema:{title:"Report Builder",report:s,availableFields:B,onSave:x,onCancel:()=>t(!1)}})})]});const h={type:"report-viewer",report:s,showToolbar:!0,allowExport:!0};return e.jsxs("div",{className:"flex flex-col h-full overflow-hidden bg-background",children:[e.jsxs("div",{className:"flex flex-col sm:flex-row justify-between sm:items-center gap-3 sm:gap-4 p-4 sm:p-6 border-b shrink-0 bg-muted/10",children:[e.jsx("div",{className:"min-w-0",children:e.jsx("h1",{className:"text-base sm:text-lg font-medium text-muted-foreground truncate",children:s.title||"Report Viewer"})}),e.jsxs("div",{className:"flex items-center gap-2 shrink-0",children:[e.jsxs(m,{variant:"outline",size:"sm",onClick:()=>t(!0),className:"h-8",children:[e.jsx(M,{className:"h-4 w-4 sm:mr-2"}),e.jsx("span",{className:"hidden sm:inline",children:"Edit Report"})]}),e.jsx(R,{open:l,onToggle:d})]})]}),e.jsxs("div",{className:"flex-1 overflow-hidden flex flex-row relative",children:[e.jsx("div",{className:"flex-1 overflow-auto p-4 sm:p-6 lg:p-8 bg-muted/5",children:e.jsx("div",{className:"max-w-5xl mx-auto shadow-sm border rounded-lg sm:rounded-xl bg-background overflow-hidden min-h-150",children:e.jsx(b,{schema:h})})}),e.jsx(E,{open:l,sections:[{title:"Report Configuration",data:s}]})]})]})}export{U as ReportView};
@@ -1 +1 @@
1
- import{j as e}from"./vendor-react-Dy_xkBQQ.js";import{u as i}from"./infrastructure-aS2LF8OZ.js";import{B as d,Y as c,Z as o,a1 as x}from"./ui-components-DVonQS7H.js";import"./framework-mHWN965c.js";import"./vendor-ui-utils-h6yAcIi9.js";import{s as p}from"./systemObjects-DSpePIIy.js";import{bw as a,m as h}from"./vendor-icons-CQ8b-fGy.js";import"./vendor-i18n-D5KbMT7w.js";import"./vendor-radix-BbeYj_o4.js";import"./vendor-charts-CSvoW-yB.js";const r=p.find(s=>s.name==="sys_role");function C(){const{user:s}=i(),l=s?.role==="admin";return e.jsxs("div",{className:"flex flex-col gap-4 sm:gap-6 p-4 sm:p-6",children:[e.jsxs("div",{className:"flex flex-col sm:flex-row sm:items-center sm:justify-between gap-3",children:[e.jsxs("div",{className:"flex items-center gap-3 min-w-0",children:[e.jsx("div",{className:"bg-primary/10 p-2 rounded-md shrink-0",children:e.jsx(a,{className:"h-5 w-5 text-primary"})}),e.jsxs("div",{className:"min-w-0",children:[e.jsx("h1",{className:"text-xl sm:text-2xl font-bold tracking-tight",children:"Role Management"}),e.jsx("p",{className:"text-sm text-muted-foreground mt-0.5",children:"Define roles and assign permissions"})]})]}),l&&e.jsxs(d,{size:"sm",className:"shrink-0 gap-2",children:[e.jsx(h,{className:"h-4 w-4"}),"Add Role"]})]}),e.jsx(c,{children:e.jsx(o,{className:"p-0",children:e.jsx("div",{className:"overflow-x-auto",children:e.jsxs("table",{className:"w-full text-sm",children:[e.jsx("thead",{children:e.jsx("tr",{className:"border-b bg-muted/50",children:r.views[0].columns.map(t=>{const m=r.fields.find(n=>n.name===t);return e.jsx("th",{className:"h-10 px-3 sm:px-4 text-left font-medium text-muted-foreground whitespace-nowrap",children:m?.label??t},t)})})}),e.jsx("tbody",{children:e.jsx("tr",{children:e.jsx("td",{className:"p-4 sm:p-6 text-center text-sm text-muted-foreground",colSpan:r.views[0].columns.length,children:e.jsxs("div",{className:"flex flex-col items-center gap-2 py-4",children:[e.jsx(a,{className:"h-8 w-8 text-muted-foreground/50"}),e.jsx("p",{children:"Connect to ObjectStack server to load roles."}),e.jsx(x,{variant:"secondary",className:"text-xs",children:"plugin-grid powered"})]})})})})]})})})})]})}export{C as RoleManagementPage};
1
+ import{j as e}from"./vendor-react-Dy_xkBQQ.js";import{u as i}from"./infrastructure-Di0WqY4l.js";import{B as d,Y as c,Z as o,a1 as x}from"./ui-components-CseD2Dpn.js";import"./framework-mHWN965c.js";import"./vendor-ui-utils-h6yAcIi9.js";import{s as p}from"./systemObjects-DSpePIIy.js";import{bw as a,m as h}from"./vendor-icons-CQ8b-fGy.js";import"./vendor-i18n-D5KbMT7w.js";import"./vendor-radix-BbeYj_o4.js";import"./vendor-charts-CSvoW-yB.js";const r=p.find(s=>s.name==="sys_role");function C(){const{user:s}=i(),l=s?.role==="admin";return e.jsxs("div",{className:"flex flex-col gap-4 sm:gap-6 p-4 sm:p-6",children:[e.jsxs("div",{className:"flex flex-col sm:flex-row sm:items-center sm:justify-between gap-3",children:[e.jsxs("div",{className:"flex items-center gap-3 min-w-0",children:[e.jsx("div",{className:"bg-primary/10 p-2 rounded-md shrink-0",children:e.jsx(a,{className:"h-5 w-5 text-primary"})}),e.jsxs("div",{className:"min-w-0",children:[e.jsx("h1",{className:"text-xl sm:text-2xl font-bold tracking-tight",children:"Role Management"}),e.jsx("p",{className:"text-sm text-muted-foreground mt-0.5",children:"Define roles and assign permissions"})]})]}),l&&e.jsxs(d,{size:"sm",className:"shrink-0 gap-2",children:[e.jsx(h,{className:"h-4 w-4"}),"Add Role"]})]}),e.jsx(c,{children:e.jsx(o,{className:"p-0",children:e.jsx("div",{className:"overflow-x-auto",children:e.jsxs("table",{className:"w-full text-sm",children:[e.jsx("thead",{children:e.jsx("tr",{className:"border-b bg-muted/50",children:r.views[0].columns.map(t=>{const m=r.fields.find(n=>n.name===t);return e.jsx("th",{className:"h-10 px-3 sm:px-4 text-left font-medium text-muted-foreground whitespace-nowrap",children:m?.label??t},t)})})}),e.jsx("tbody",{children:e.jsx("tr",{children:e.jsx("td",{className:"p-4 sm:p-6 text-center text-sm text-muted-foreground",colSpan:r.views[0].columns.length,children:e.jsxs("div",{className:"flex flex-col items-center gap-2 py-4",children:[e.jsx(a,{className:"h-8 w-8 text-muted-foreground/50"}),e.jsx("p",{children:"Connect to ObjectStack server to load roles."}),e.jsx(x,{variant:"secondary",className:"text-xs",children:"plugin-grid powered"})]})})})})]})})})})]})}export{C as RoleManagementPage};
@@ -0,0 +1 @@
1
+ import{h as S,k as L,r as m,j as s,L as g}from"./vendor-react-Dy_xkBQQ.js";import{M as I,a1 as f,Y as P,Z as A}from"./ui-components-CseD2Dpn.js";import"./framework-mHWN965c.js";import"./vendor-ui-utils-h6yAcIi9.js";import{b as E}from"./index-RAPqkKVL.js";import{A as M,S as b,aE as T,a1 as q,aD as O,as as x}from"./vendor-icons-CQ8b-fGy.js";import"./vendor-radix-BbeYj_o4.js";import"./vendor-i18n-D5KbMT7w.js";import"./vendor-charts-CSvoW-yB.js";import"./plugins-core-Cv2TPt86.js";import"./plugins-views-divN-xXs.js";import"./infrastructure-Di0WqY4l.js";import"./data-adapter-D15yh-pb.js";import"./vendor-objectstack-Bifvxvds.js";import"./vendor-zod-UZPqlszj.js";import"./ui-layout-CF_1bNSv.js";function N(p){const l=[];for(const o of p)o.type==="group"&&o.children?l.push(...N(o.children)):l.push(o);return l}const j={object:x,dashboard:O,page:q,report:T},D={object:"bg-blue-100 text-blue-800 dark:bg-blue-900 dark:text-blue-200",dashboard:"bg-purple-100 text-purple-800 dark:bg-purple-900 dark:text-purple-200",page:"bg-green-100 text-green-800 dark:bg-green-900 dark:text-green-200",report:"bg-orange-100 text-orange-800 dark:bg-orange-900 dark:text-orange-200"};function ee(){const{appName:p}=S(),[l,o]=L(),y=l.get("q")||"",[n,v]=m.useState(y),{apps:w}=E(),h=w||[],u=h.find(t=>t.name===p)||h[0],c=`/apps/${p}`,i=m.useMemo(()=>u?N(u.navigation||[]).map(e=>{let a="#";return e.type==="object"?a=`${c}/${e.objectName}`:e.type==="dashboard"?a=`${c}/dashboard/${e.dashboardName}`:e.type==="page"?a=`${c}/page/${e.pageName}`:e.type==="report"&&(a=`${c}/report/${e.reportName}`),{id:e.id,label:e.label||e.objectName||e.dashboardName||e.pageName||e.reportName||"",href:a,type:e.type,description:e.description}}).filter(e=>e.href!=="#"):[],[u,c]),d=m.useMemo(()=>{if(!n.trim())return i;const t=n.toLowerCase();return i.filter(e=>e.label.toLowerCase().includes(t)||e.type.toLowerCase().includes(t)||e.description&&e.description.toLowerCase().includes(t))},[i,n]),$=t=>{v(t),o(t?{q:t}:{})},C=m.useMemo(()=>{const t={};for(const e of d)(t[e.type]||=[]).push(e);return t},[d]);return s.jsxs("div",{className:"flex flex-col gap-6 p-4 sm:p-6 max-w-4xl mx-auto",children:[s.jsxs("div",{className:"flex items-center gap-3",children:[s.jsxs(g,{to:c,className:"flex items-center gap-1 text-sm text-muted-foreground hover:text-foreground transition-colors",children:[s.jsx(M,{className:"h-4 w-4"}),"Back"]}),s.jsx("h1",{className:"text-xl font-semibold",children:"Search"})]}),s.jsxs("div",{className:"relative",children:[s.jsx(b,{className:"absolute left-3 top-1/2 -translate-y-1/2 h-4 w-4 text-muted-foreground"}),s.jsx(I,{value:n,onChange:t=>$(t.target.value),placeholder:"Search objects, dashboards, pages, reports...",className:"pl-10 h-11 text-base",autoFocus:!0})]}),s.jsx("div",{className:"text-sm text-muted-foreground",children:n.trim()?`${d.length} result${d.length!==1?"s":""} for "${n}"`:`${i.length} items available`}),d.length===0?s.jsxs("div",{className:"flex flex-col items-center justify-center py-12 text-center",children:[s.jsx(b,{className:"h-12 w-12 text-muted-foreground/30 mb-4"}),s.jsx("p",{className:"text-lg font-medium text-muted-foreground",children:"No results found"}),s.jsx("p",{className:"text-sm text-muted-foreground/80 mt-1",children:"Try adjusting your search terms"})]}):s.jsx("div",{className:"space-y-6",children:Object.entries(C).map(([t,e])=>{const a=j[t]||x;return s.jsxs("div",{children:[s.jsxs("h2",{className:"text-sm font-medium text-muted-foreground mb-2 flex items-center gap-1.5",children:[s.jsx(a,{className:"h-4 w-4"}),t.charAt(0).toUpperCase()+t.slice(1),"s",s.jsx(f,{variant:"secondary",className:"ml-1 text-xs",children:e.length})]}),s.jsx("div",{className:"grid gap-2",children:e.map(r=>{const k=j[r.type]||x;return s.jsx(g,{to:r.href,children:s.jsx(P,{className:"hover:bg-accent/50 transition-colors cursor-pointer",children:s.jsxs(A,{className:"flex items-center gap-3 p-3",children:[s.jsx("div",{className:`flex h-8 w-8 items-center justify-center rounded ${D[r.type]||""}`,children:s.jsx(k,{className:"h-4 w-4"})}),s.jsxs("div",{className:"flex-1 min-w-0",children:[s.jsx("p",{className:"text-sm font-medium truncate",children:r.label}),r.description&&s.jsx("p",{className:"text-xs text-muted-foreground truncate",children:r.description})]}),s.jsx(f,{variant:"outline",className:"text-xs shrink-0",children:r.type})]})})},r.id)})})]},t)})})]})}export{ee as SearchResultsPage};
@@ -1 +1 @@
1
- import{j as e}from"./vendor-react-Dy_xkBQQ.js";import{u as i}from"./infrastructure-aS2LF8OZ.js";import{B as c,Y as d,Z as o,a1 as x}from"./ui-components-DVonQS7H.js";import"./framework-mHWN965c.js";import"./vendor-ui-utils-h6yAcIi9.js";import{s as p}from"./systemObjects-DSpePIIy.js";import{bu as a,m as h}from"./vendor-icons-CQ8b-fGy.js";import"./vendor-i18n-D5KbMT7w.js";import"./vendor-radix-BbeYj_o4.js";import"./vendor-charts-CSvoW-yB.js";const r=p.find(s=>s.name==="sys_user");function k(){const{user:s}=i(),m=s?.role==="admin";return e.jsxs("div",{className:"flex flex-col gap-4 sm:gap-6 p-4 sm:p-6",children:[e.jsxs("div",{className:"flex flex-col sm:flex-row sm:items-center sm:justify-between gap-3",children:[e.jsxs("div",{className:"flex items-center gap-3 min-w-0",children:[e.jsx("div",{className:"bg-primary/10 p-2 rounded-md shrink-0",children:e.jsx(a,{className:"h-5 w-5 text-primary"})}),e.jsxs("div",{className:"min-w-0",children:[e.jsx("h1",{className:"text-xl sm:text-2xl font-bold tracking-tight",children:"User Management"}),e.jsx("p",{className:"text-sm text-muted-foreground mt-0.5",children:"Manage system users and their roles"})]})]}),m&&e.jsxs(c,{size:"sm",className:"shrink-0 gap-2",children:[e.jsx(h,{className:"h-4 w-4"}),"Add User"]})]}),e.jsx(d,{children:e.jsx(o,{className:"p-0",children:e.jsx("div",{className:"overflow-x-auto",children:e.jsxs("table",{className:"w-full text-sm",children:[e.jsx("thead",{children:e.jsx("tr",{className:"border-b bg-muted/50",children:r.views[0].columns.map(t=>{const n=r.fields.find(l=>l.name===t);return e.jsx("th",{className:"h-10 px-3 sm:px-4 text-left font-medium text-muted-foreground whitespace-nowrap",children:n?.label??t},t)})})}),e.jsx("tbody",{children:e.jsx("tr",{children:e.jsx("td",{className:"p-4 sm:p-6 text-center text-sm text-muted-foreground",colSpan:r.views[0].columns.length,children:e.jsxs("div",{className:"flex flex-col items-center gap-2 py-4",children:[e.jsx(a,{className:"h-8 w-8 text-muted-foreground/50"}),e.jsx("p",{children:"Connect to ObjectStack server to load users."}),e.jsx(x,{variant:"secondary",className:"text-xs",children:"plugin-grid powered"})]})})})})]})})})})]})}export{k as UserManagementPage};
1
+ import{j as e}from"./vendor-react-Dy_xkBQQ.js";import{u as i}from"./infrastructure-Di0WqY4l.js";import{B as c,Y as d,Z as o,a1 as x}from"./ui-components-CseD2Dpn.js";import"./framework-mHWN965c.js";import"./vendor-ui-utils-h6yAcIi9.js";import{s as p}from"./systemObjects-DSpePIIy.js";import{bu as a,m as h}from"./vendor-icons-CQ8b-fGy.js";import"./vendor-i18n-D5KbMT7w.js";import"./vendor-radix-BbeYj_o4.js";import"./vendor-charts-CSvoW-yB.js";const r=p.find(s=>s.name==="sys_user");function k(){const{user:s}=i(),m=s?.role==="admin";return e.jsxs("div",{className:"flex flex-col gap-4 sm:gap-6 p-4 sm:p-6",children:[e.jsxs("div",{className:"flex flex-col sm:flex-row sm:items-center sm:justify-between gap-3",children:[e.jsxs("div",{className:"flex items-center gap-3 min-w-0",children:[e.jsx("div",{className:"bg-primary/10 p-2 rounded-md shrink-0",children:e.jsx(a,{className:"h-5 w-5 text-primary"})}),e.jsxs("div",{className:"min-w-0",children:[e.jsx("h1",{className:"text-xl sm:text-2xl font-bold tracking-tight",children:"User Management"}),e.jsx("p",{className:"text-sm text-muted-foreground mt-0.5",children:"Manage system users and their roles"})]})]}),m&&e.jsxs(c,{size:"sm",className:"shrink-0 gap-2",children:[e.jsx(h,{className:"h-4 w-4"}),"Add User"]})]}),e.jsx(d,{children:e.jsx(o,{className:"p-0",children:e.jsx("div",{className:"overflow-x-auto",children:e.jsxs("table",{className:"w-full text-sm",children:[e.jsx("thead",{children:e.jsx("tr",{className:"border-b bg-muted/50",children:r.views[0].columns.map(t=>{const n=r.fields.find(l=>l.name===t);return e.jsx("th",{className:"h-10 px-3 sm:px-4 text-left font-medium text-muted-foreground whitespace-nowrap",children:n?.label??t},t)})})}),e.jsx("tbody",{children:e.jsx("tr",{children:e.jsx("td",{className:"p-4 sm:p-6 text-center text-sm text-muted-foreground",colSpan:r.views[0].columns.length,children:e.jsxs("div",{className:"flex flex-col items-center gap-2 py-4",children:[e.jsx(a,{className:"h-8 w-8 text-muted-foreground/50"}),e.jsx("p",{children:"Connect to ObjectStack server to load users."}),e.jsx(x,{variant:"secondary",className:"text-xs",children:"plugin-grid powered"})]})})})})]})})})})]})}export{k as UserManagementPage};