adminizer 4.3.0-build.73 → 4.3.0-build.75

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 (92) hide show
  1. package/assets/add-B-wtzl14.js +1 -0
  2. package/assets/{add-form-CGi_qv3J.js → add-form-BlPl0S7W.js} +1 -1
  3. package/assets/add-group-CGiSK3je.js +1 -0
  4. package/assets/{add-group-form-DSd4UrnU.js → add-group-form-Chb9XkVr.js} +1 -1
  5. package/assets/add-user-CI91aShE.js +1 -0
  6. package/assets/{add-user-form-BAssKDpI.js → add-user-form-CpszaZtW.js} +1 -1
  7. package/assets/{app-GsYdx39W.css → app-CpGtjhxF.css} +1 -1
  8. package/assets/app-layout-CDjEwM9a.js +1 -0
  9. package/assets/{app-shell-DHzMWA1L.js → app-shell-CByYJPLe.js} +1 -1
  10. package/assets/{app-sidebar-D7l5BJPV.js → app-sidebar-CLPoDV2f.js} +1 -1
  11. package/assets/app-sidebar-header-B1mI-oGm.js +1 -0
  12. package/assets/app.js +2 -2
  13. package/assets/{breadcrumbs-DnNOEnT4.js → breadcrumbs-0GLBx1iv.js} +1 -1
  14. package/assets/{catalog-BavcTVb4.js → catalog-BEnuFPi6.js} +1 -1
  15. package/assets/{dashboard-xr-OyVyG.js → dashboard-Cb4RAfgr.js} +1 -1
  16. package/assets/{date-picker-DBHnomTY.js → date-picker-Gy19IF7Q.js} +1 -1
  17. package/assets/{del-modal-BeF4r3gk.js → del-modal-COG1XcES.js} +1 -1
  18. package/assets/{field-renderer-Sd68OLyc.js → field-renderer-CrsFaZNM.js} +3 -3
  19. package/assets/{form-DomTBI89.js → form-BwafUUB7.js} +1 -1
  20. package/assets/form-X67d3x3D.js +1 -0
  21. package/assets/{geo-json-CVaNUZbb.js → geo-json-Dswzlx0K.js} +1 -1
  22. package/assets/{handsontable-CZQ5Ietj.js → handsontable-DQYtlTE2.js} +1 -1
  23. package/assets/home-DlxjWnrt.js +2 -0
  24. package/assets/icon-BWrEqTE-.js +1 -0
  25. package/assets/{init-user-DqMDju_E.js → init-user-DKSIGCcH.js} +1 -1
  26. package/assets/{input-error-g1h6ps7t.js → input-error-BBzQCTcg.js} +1 -1
  27. package/assets/list-CjOxUyML.js +1 -0
  28. package/assets/{list-table-Br0K3rXg.js → list-table-DMJKIWta.js} +1 -1
  29. package/assets/login-5G-1gzoH.js +1 -0
  30. package/assets/manifest.json +96 -101
  31. package/assets/{material-icon-BIcI8APG.js → material-icon-BE8cT_z7.js} +1 -1
  32. package/assets/{media-manager-CTstvyHm.js → media-manager-DWLUhFyJ.js} +1 -1
  33. package/assets/{module-CpZBs0fN.js → module-9RNagTns.js} +1 -1
  34. package/assets/{multi-select-BFWbEjH-.js → multi-select-BnR59_kI.js} +1 -1
  35. package/assets/{nav-footer-bO8D-Yir.js → nav-footer-Dq1Z6Fmw.js} +1 -1
  36. package/assets/{nav-main-DVgvko8g.js → nav-main-DQNNAKwu.js} +1 -1
  37. package/assets/{nav-user-vIwYShwE.js → nav-user-q7QW6ZiI.js} +1 -1
  38. package/assets/notification-CIUVTHsw.js +1 -0
  39. package/assets/{pagination-render-rZ5_6g0n.js → pagination-render-PLbPRWg5.js} +1 -1
  40. package/assets/{register-Kfu8zmmu.js → register-48nlLgHz.js} +1 -1
  41. package/assets/{tabs-CwgzWt48.js → tabs-D5eQoog9.js} +1 -1
  42. package/assets/{theme-switcher-fzVA8btX.js → theme-switcher-BZ6eg-WU.js} +1 -1
  43. package/assets/{user-info-Db5Y8KeN.js → user-info-CJp_GYZl.js} +1 -1
  44. package/assets/{user-menu-content-Bc8YNZPf.js → user-menu-content-ljwR9luU.js} +1 -1
  45. package/assets/{welcome-MKPFhPtG.js → welcome-CBKz_MRJ.js} +1 -1
  46. package/controllers/add.js +0 -2
  47. package/controllers/edit.js +3 -3
  48. package/controllers/login.js +21 -56
  49. package/controllers/remove.js +11 -2
  50. package/helpers/diffHelpers.d.ts +1 -1
  51. package/helpers/diffHelpers.js +52 -7
  52. package/helpers/inertiaAutHelper.js +19 -0
  53. package/index.d.ts +0 -1
  54. package/index.js +0 -1
  55. package/interfaces/adminpanelConfig.d.ts +12 -0
  56. package/interfaces/types.d.ts +12 -2
  57. package/lib/Adminizer.d.ts +0 -8
  58. package/lib/Adminizer.js +0 -9
  59. package/lib/v4/DataAccessor.d.ts +1 -1
  60. package/lib/v4/model/AbstractModel.js +12 -0
  61. package/lib/v4/model/adapter/sequelize.js +1 -1
  62. package/lib/v4/notifications/AbstractNotificationService.js +1 -0
  63. package/lib/v4/notifications/GeneralNotificationService.js +1 -1
  64. package/lib/v4/notifications/SystemNotificationService.js +4 -3
  65. package/package.json +1 -1
  66. package/translations/ar.json +5 -4
  67. package/translations/cn.json +5 -4
  68. package/translations/de.json +72 -71
  69. package/translations/en.json +5 -4
  70. package/translations/es.json +5 -4
  71. package/translations/fr.json +5 -4
  72. package/translations/hi.json +5 -4
  73. package/translations/jp.json +5 -4
  74. package/translations/ko.json +5 -4
  75. package/translations/pt.json +5 -4
  76. package/translations/ru.json +2 -1
  77. package/translations/ua.json +5 -4
  78. package/translations/uz.json +73 -72
  79. package/translations/vi.json +5 -4
  80. package/assets/add-BNb5A_qF.js +0 -1
  81. package/assets/add-group-RRjHTu93.js +0 -1
  82. package/assets/add-user-DSuvcKp6.js +0 -1
  83. package/assets/app-layout-ContoN1K.js +0 -1
  84. package/assets/app-sidebar-header-CK8t32cm.js +0 -1
  85. package/assets/form-C9P9m_9q.js +0 -1
  86. package/assets/home-BWHeZm-1.js +0 -2
  87. package/assets/icon-ChQBPA5l.js +0 -1
  88. package/assets/list-EEgAn-nx.js +0 -1
  89. package/assets/login-BR9cqsPn.js +0 -1
  90. package/assets/notification-BTXEslqa.js +0 -1
  91. package/lib/v4/model/adapter/typeorm.d.ts +0 -24
  92. package/lib/v4/model/adapter/typeorm.js +0 -88
@@ -1,4 +1,4 @@
1
- import{r as p,e as Q,ab as Pt,j as h,ac as Yr,ad as Xr,h as ve,c as Je,ae as Wr,G as At,af as Wn,ag as Hn,ah as rn,B as he,E as Xi,F as Wi,A as Hi,ai as Hr,aj as Un,ak as Vn,al as Me,am as Ur,an,ao as Te,ap as Vr,aq as Fr,I as pn,L as Wt,a as _t,ar as Ui,as as Vi,at as Fi,au as Gi,av as Ki,d as Rn,aa as qi,D as Ji,l as lr,m as Zi,n as Qi,aw as ea}from"./app.js";import{P as sn,I as Gr,p as ta}from"./field-renderer-Sd68OLyc.js";import{T as na,a as ra,b as vt,c as bt}from"./tabs-CwgzWt48.js";import{d as ia}from"./debounce-D6eaSoDg.js";import"./dynamic-controls-CSVVCONh.js";import"./multi-select-BFWbEjH-.js";function aa(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];return p.useMemo(()=>r=>{e.forEach(i=>i(r))},e)}const gn=typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u";function Nt(t){const e=Object.prototype.toString.call(t);return e==="[object Window]"||e==="[object global]"}function Fn(t){return"nodeType"in t}function be(t){var e,n;return t?Nt(t)?t:Fn(t)&&(e=(n=t.ownerDocument)==null?void 0:n.defaultView)!=null?e:window:window}function Gn(t){const{Document:e}=be(t);return t instanceof e}function Gt(t){return Nt(t)?!1:t instanceof be(t).HTMLElement}function Kr(t){return t instanceof be(t).SVGElement}function Mt(t){return t?Nt(t)?t.document:Fn(t)?Gn(t)?t:Gt(t)||Kr(t)?t.ownerDocument:document:document:document}const Pe=gn?p.useLayoutEffect:p.useEffect;function mn(t){const e=p.useRef(t);return Pe(()=>{e.current=t}),p.useCallback(function(){for(var n=arguments.length,r=new Array(n),i=0;i<n;i++)r[i]=arguments[i];return e.current==null?void 0:e.current(...r)},[])}function sa(){const t=p.useRef(null),e=p.useCallback((r,i)=>{t.current=setInterval(r,i)},[]),n=p.useCallback(()=>{t.current!==null&&(clearInterval(t.current),t.current=null)},[]);return[e,n]}function Ht(t,e){e===void 0&&(e=[t]);const n=p.useRef(t);return Pe(()=>{n.current!==t&&(n.current=t)},e),n}function Kt(t,e){const n=p.useRef();return p.useMemo(()=>{const r=t(n.current);return n.current=r,r},[...e])}function on(t){const e=mn(t),n=p.useRef(null),r=p.useCallback(i=>{i!==n.current&&(e==null||e(i,n.current)),n.current=i},[]);return[n,r]}function ln(t){const e=p.useRef();return p.useEffect(()=>{e.current=t},[t]),e.current}let Dn={};function qt(t,e){return p.useMemo(()=>{if(e)return e;const n=Dn[t]==null?0:Dn[t]+1;return Dn[t]=n,t+"-"+n},[t,e])}function qr(t){return function(e){for(var n=arguments.length,r=new Array(n>1?n-1:0),i=1;i<n;i++)r[i-1]=arguments[i];return r.reduce((a,s)=>{const o=Object.entries(s);for(const[u,l]of o){const d=a[u];d!=null&&(a[u]=d+t*l)}return a},{...e})}}const Dt=qr(1),Ut=qr(-1);function oa(t){return"clientX"in t&&"clientY"in t}function Jt(t){if(!t)return!1;const{KeyboardEvent:e}=be(t.target);return e&&t instanceof e}function la(t){if(!t)return!1;const{TouchEvent:e}=be(t.target);return e&&t instanceof e}function cn(t){if(la(t)){if(t.touches&&t.touches.length){const{clientX:e,clientY:n}=t.touches[0];return{x:e,y:n}}else if(t.changedTouches&&t.changedTouches.length){const{clientX:e,clientY:n}=t.changedTouches[0];return{x:e,y:n}}}return oa(t)?{x:t.clientX,y:t.clientY}:null}const He=Object.freeze({Translate:{toString(t){if(!t)return;const{x:e,y:n}=t;return"translate3d("+(e?Math.round(e):0)+"px, "+(n?Math.round(n):0)+"px, 0)"}},Scale:{toString(t){if(!t)return;const{scaleX:e,scaleY:n}=t;return"scaleX("+e+") scaleY("+n+")"}},Transform:{toString(t){if(t)return[He.Translate.toString(t),He.Scale.toString(t)].join(" ")}},Transition:{toString(t){let{property:e,duration:n,easing:r}=t;return e+" "+n+"ms "+r}}}),cr="a,frame,iframe,input:not([type=hidden]):not(:disabled),select:not(:disabled),textarea:not(:disabled),button:not(:disabled),*[tabindex]";function ca(t){return t.matches(cr)?t:t.querySelector(cr)}const da={display:"none"};function ua(t){let{id:e,value:n}=t;return Q.createElement("div",{id:e,style:da},n)}function ha(t){let{id:e,announcement:n,ariaLiveType:r="assertive"}=t;const i={position:"fixed",top:0,left:0,width:1,height:1,margin:-1,border:0,padding:0,overflow:"hidden",clip:"rect(0 0 0 0)",clipPath:"inset(100%)",whiteSpace:"nowrap"};return Q.createElement("div",{id:e,style:i,role:"status","aria-live":r,"aria-atomic":!0},n)}function fa(){const[t,e]=p.useState("");return{announce:p.useCallback(r=>{r!=null&&e(r)},[]),announcement:t}}const Jr=p.createContext(null);function pa(t){const e=p.useContext(Jr);p.useEffect(()=>{if(!e)throw new Error("useDndMonitor must be used within a children of <DndContext>");return e(t)},[t,e])}function ga(){const[t]=p.useState(()=>new Set),e=p.useCallback(r=>(t.add(r),()=>t.delete(r)),[t]);return[p.useCallback(r=>{let{type:i,event:a}=r;t.forEach(s=>{var o;return(o=s[i])==null?void 0:o.call(s,a)})},[t]),e]}const ma={draggable:`
1
+ import{r as p,e as Q,ar as Pt,j as h,as as Yr,at as Xr,h as ve,c as Je,aa as Wr,G as At,af as Wn,ag as Hn,au as rn,B as he,E as Xi,F as Wi,A as Hi,av as Hr,ah as Un,ai as Vn,a5 as Me,a3 as Ur,a4 as an,a6 as Te,a9 as Vr,a8 as Fr,I as pn,L as Wt,a as _t,aw as Ui,ax as Vi,ay as Fi,az as Gi,ad as Ki,d as Rn,aq as qi,D as Ji,l as lr,m as Zi,n as Qi,aA as ea}from"./app.js";import{P as sn,I as Gr,p as ta}from"./field-renderer-CrsFaZNM.js";import{c as na,b as ra,T as vt,a as bt}from"./tabs-D5eQoog9.js";import{d as ia}from"./debounce-D6eaSoDg.js";import"./dynamic-controls-CSVVCONh.js";import"./multi-select-BnR59_kI.js";function aa(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];return p.useMemo(()=>r=>{e.forEach(i=>i(r))},e)}const gn=typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u";function Nt(t){const e=Object.prototype.toString.call(t);return e==="[object Window]"||e==="[object global]"}function Fn(t){return"nodeType"in t}function be(t){var e,n;return t?Nt(t)?t:Fn(t)&&(e=(n=t.ownerDocument)==null?void 0:n.defaultView)!=null?e:window:window}function Gn(t){const{Document:e}=be(t);return t instanceof e}function Gt(t){return Nt(t)?!1:t instanceof be(t).HTMLElement}function Kr(t){return t instanceof be(t).SVGElement}function Mt(t){return t?Nt(t)?t.document:Fn(t)?Gn(t)?t:Gt(t)||Kr(t)?t.ownerDocument:document:document:document}const Pe=gn?p.useLayoutEffect:p.useEffect;function mn(t){const e=p.useRef(t);return Pe(()=>{e.current=t}),p.useCallback(function(){for(var n=arguments.length,r=new Array(n),i=0;i<n;i++)r[i]=arguments[i];return e.current==null?void 0:e.current(...r)},[])}function sa(){const t=p.useRef(null),e=p.useCallback((r,i)=>{t.current=setInterval(r,i)},[]),n=p.useCallback(()=>{t.current!==null&&(clearInterval(t.current),t.current=null)},[]);return[e,n]}function Ht(t,e){e===void 0&&(e=[t]);const n=p.useRef(t);return Pe(()=>{n.current!==t&&(n.current=t)},e),n}function Kt(t,e){const n=p.useRef();return p.useMemo(()=>{const r=t(n.current);return n.current=r,r},[...e])}function on(t){const e=mn(t),n=p.useRef(null),r=p.useCallback(i=>{i!==n.current&&(e==null||e(i,n.current)),n.current=i},[]);return[n,r]}function ln(t){const e=p.useRef();return p.useEffect(()=>{e.current=t},[t]),e.current}let Dn={};function qt(t,e){return p.useMemo(()=>{if(e)return e;const n=Dn[t]==null?0:Dn[t]+1;return Dn[t]=n,t+"-"+n},[t,e])}function qr(t){return function(e){for(var n=arguments.length,r=new Array(n>1?n-1:0),i=1;i<n;i++)r[i-1]=arguments[i];return r.reduce((a,s)=>{const o=Object.entries(s);for(const[u,l]of o){const d=a[u];d!=null&&(a[u]=d+t*l)}return a},{...e})}}const Dt=qr(1),Ut=qr(-1);function oa(t){return"clientX"in t&&"clientY"in t}function Jt(t){if(!t)return!1;const{KeyboardEvent:e}=be(t.target);return e&&t instanceof e}function la(t){if(!t)return!1;const{TouchEvent:e}=be(t.target);return e&&t instanceof e}function cn(t){if(la(t)){if(t.touches&&t.touches.length){const{clientX:e,clientY:n}=t.touches[0];return{x:e,y:n}}else if(t.changedTouches&&t.changedTouches.length){const{clientX:e,clientY:n}=t.changedTouches[0];return{x:e,y:n}}}return oa(t)?{x:t.clientX,y:t.clientY}:null}const He=Object.freeze({Translate:{toString(t){if(!t)return;const{x:e,y:n}=t;return"translate3d("+(e?Math.round(e):0)+"px, "+(n?Math.round(n):0)+"px, 0)"}},Scale:{toString(t){if(!t)return;const{scaleX:e,scaleY:n}=t;return"scaleX("+e+") scaleY("+n+")"}},Transform:{toString(t){if(t)return[He.Translate.toString(t),He.Scale.toString(t)].join(" ")}},Transition:{toString(t){let{property:e,duration:n,easing:r}=t;return e+" "+n+"ms "+r}}}),cr="a,frame,iframe,input:not([type=hidden]):not(:disabled),select:not(:disabled),textarea:not(:disabled),button:not(:disabled),*[tabindex]";function ca(t){return t.matches(cr)?t:t.querySelector(cr)}const da={display:"none"};function ua(t){let{id:e,value:n}=t;return Q.createElement("div",{id:e,style:da},n)}function ha(t){let{id:e,announcement:n,ariaLiveType:r="assertive"}=t;const i={position:"fixed",top:0,left:0,width:1,height:1,margin:-1,border:0,padding:0,overflow:"hidden",clip:"rect(0 0 0 0)",clipPath:"inset(100%)",whiteSpace:"nowrap"};return Q.createElement("div",{id:e,style:i,role:"status","aria-live":r,"aria-atomic":!0},n)}function fa(){const[t,e]=p.useState("");return{announce:p.useCallback(r=>{r!=null&&e(r)},[]),announcement:t}}const Jr=p.createContext(null);function pa(t){const e=p.useContext(Jr);p.useEffect(()=>{if(!e)throw new Error("useDndMonitor must be used within a children of <DndContext>");return e(t)},[t,e])}function ga(){const[t]=p.useState(()=>new Set),e=p.useCallback(r=>(t.add(r),()=>t.delete(r)),[t]);return[p.useCallback(r=>{let{type:i,event:a}=r;t.forEach(s=>{var o;return(o=s[i])==null?void 0:o.call(s,a)})},[t]),e]}const ma={draggable:`
2
2
  To pick up a draggable item, press the space bar.
3
3
  While dragging, use the arrow keys to move the item.
4
4
  Press space again to drop the item in its new position, or press escape to cancel.
@@ -1 +1 @@
1
- import{q as p,r as s,j as t,L as i}from"./app.js";import{A as c}from"./app-layout-ContoN1K.js";import"./app-shell-DHzMWA1L.js";import"./app-sidebar-D7l5BJPV.js";import"./nav-main-DVgvko8g.js";import"./material-icon-BIcI8APG.js";import"./app-sidebar-header-CK8t32cm.js";import"./breadcrumbs-DnNOEnT4.js";import"./nav-user-vIwYShwE.js";import"./user-info-Db5Y8KeN.js";import"./user-menu-content-Bc8YNZPf.js";import"./theme-switcher-fzVA8btX.js";import"./use-appearance-CXP5cHaQ.js";import"./icon-ChQBPA5l.js";const d=[];function q(){const r=p(),[n,m]=s.useState(null);return s.useEffect(()=>{const l=async()=>{const e=(await import(r.props.moduleComponent)).default;m(t.jsx(e,{message:r.props.message}))};(()=>{const o=r.props.moduleComponentCSS;if(!o||[...document.head.querySelectorAll("link[rel='stylesheet']")].some(a=>a.href.includes(o)))return;const e=document.createElement("link");e.rel="stylesheet",e.href=o,e.type="text/css",e.onload=()=>console.log(`CSS loaded: ${o}`),e.onerror=()=>console.error(`Failed to load CSS: ${o}`),document.head.appendChild(e)})(),l()},[]),t.jsx(c,{breadcrumbs:d,children:t.jsx("div",{className:"m-5",children:n||t.jsx(i,{className:"size-10 animate-spin text-neutral-500 mx-auto mt-[15%]"})})})}export{q as default};
1
+ import{q as p,r as s,j as t,L as i}from"./app.js";import{A as c}from"./app-layout-CDjEwM9a.js";import"./app-shell-CByYJPLe.js";import"./app-sidebar-CLPoDV2f.js";import"./nav-main-DQNNAKwu.js";import"./material-icon-BE8cT_z7.js";import"./app-sidebar-header-B1mI-oGm.js";import"./breadcrumbs-0GLBx1iv.js";import"./nav-user-q7QW6ZiI.js";import"./user-info-CJp_GYZl.js";import"./user-menu-content-ljwR9luU.js";import"./theme-switcher-BZ6eg-WU.js";import"./use-appearance-CXP5cHaQ.js";import"./icon-BWrEqTE-.js";const d=[];function q(){const r=p(),[n,m]=s.useState(null);return s.useEffect(()=>{const l=async()=>{const e=(await import(r.props.moduleComponent)).default;m(t.jsx(e,{message:r.props.message}))};(()=>{const o=r.props.moduleComponentCSS;if(!o||[...document.head.querySelectorAll("link[rel='stylesheet']")].some(a=>a.href.includes(o)))return;const e=document.createElement("link");e.rel="stylesheet",e.href=o,e.type="text/css",e.onload=()=>console.log(`CSS loaded: ${o}`),e.onerror=()=>console.error(`Failed to load CSS: ${o}`),document.head.appendChild(e)})(),l()},[]),t.jsx(c,{breadcrumbs:d,children:t.jsx("div",{className:"m-5",children:n||t.jsx(i,{className:"size-10 animate-spin text-neutral-500 mx-auto mt-[15%]"})})})}export{q as default};
@@ -1 +1 @@
1
- import{r as q,c as fe,ae as R,j as t,bC as oe,bD as xe,ad as he,bE as pe,bF as ie,bi as ge,B as be,bG as ve,bH as je,bI as ye,bJ as Ce,a9 as we,bK as Ne,bL as Se,bM as ke,bk as Pe,bN as Ve,bl as Ee}from"./app.js";const ce=xe("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"}}),De=q.forwardRef((E,Q)=>{const e=fe.c(87);let x,h,a,o,p,g,m,D,I,O,F,K,$,U,B,u;e[0]!==E?({options:o,onValueChange:a,variant:u,processing:p,disabled:h,defaultValue:m,placeholder:D,notFound:I,search:O,animation:F,maxCount:K,modalPopover:$,asChild:U,className:x,mode:B,...g}=E,e[0]=E,e[1]=x,e[2]=h,e[3]=a,e[4]=o,e[5]=p,e[6]=g,e[7]=m,e[8]=D,e[9]=I,e[10]=O,e[11]=F,e[12]=K,e[13]=$,e[14]=U,e[15]=B,e[16]=u):(x=e[1],h=e[2],a=e[3],o=e[4],p=e[5],g=e[6],m=e[7],D=e[8],I=e[9],O=e[10],F=e[11],K=e[12],$=e[13],U=e[14],B=e[15],u=e[16]);let T;e[17]!==m?(T=m===void 0?[]:m,e[17]=m,e[18]=T):T=e[18];const de=T,Y=D===void 0?"":D,Z=I===void 0?"":I,ee=O===void 0?"":O,f=F===void 0?0:F,i=K===void 0?3:K,te=$===void 0?!1:$,n=B===void 0?"multiple":B,[s,A]=q.useState(de),[se,M]=q.useState(!1),[c,me]=q.useState(!1);let G;e[19]!==a||e[20]!==s?(G=l=>{if(l.key==="Enter")M(!0);else if(l.key==="Backspace"&&!l.currentTarget.value){const r=[...s];r.pop(),A(r),a(r)}},e[19]=a,e[20]=s,e[21]=G):G=e[21];const le=G;let L;e[22]!==n||e[23]!==a||e[24]!==s?(L=l=>{let r;n==="single"?r=s.includes(l)?[]:[l]:r=s.includes(l)?s.filter(V=>V!==l):[...s,l],A(r),a(r),n==="single"&&M(!1)},e[22]=n,e[23]=a,e[24]=s,e[25]=L):L=e[25];const d=L;let X;e[26]!==a?(X=()=>{A([]),a([])},e[26]=a,e[27]=X):X=e[27];const re=X;let z;e[28]===Symbol.for("react.memo_cache_sentinel")?(z=()=>{M(Ie)},e[28]=z):z=e[28];const ue=z;let H;e[29]!==i||e[30]!==a||e[31]!==s?(H=()=>{const l=s.slice(0,i);A(l),a(l)},e[29]=i,e[30]=a,e[31]=s,e[32]=H):H=e[32];const ae=H;let b;e[33]!==x?(b=R("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",x),e[33]=x,e[34]=b):b=e[34];let v;e[35]!==f||e[36]!==ae||e[37]!==re||e[38]!==c||e[39]!==i||e[40]!==n||e[41]!==o||e[42]!==Y||e[43]!==p||e[44]!==s||e[45]!==d||e[46]!==u?(v=s.length>0?t.jsxs("div",{className:"flex justify-between items-center w-full",children:[t.jsxs("div",{className:"flex flex-wrap items-center",children:[s.slice(0,i).map(l=>{const r=o.find(ne=>ne.value===l),V=r==null?void 0:r.icon;return t.jsxs("div",{className:R(c?"animate-bounce":"",ce({variant:u})),style:{animationDuration:`${f}s`},children:[V&&t.jsx(V,{className:"h-4 w-4 mr-2"}),r==null?void 0:r.label,t.jsx(oe,{className:"ml-2 h-4 w-4 cursor-pointer",onClick:ne=>{ne.stopPropagation(),p||d(l)}})]},l)}),n==="multiple"&&s.length>i&&t.jsxs("div",{className:R("bg-transparent text-foreground border-foreground/1 hover:bg-transparent",c?"animate-bounce":"",ce({variant:u})),style:{animationDuration:`${f}s`},children:[`+ ${s.length-i} more`,t.jsx(oe,{className:"ml-2 h-4 w-4 cursor-pointer",onClick:l=>{l.stopPropagation(),ae()}})]})]}),t.jsxs("div",{className:"flex items-center justify-between",children:[s.length>0&&t.jsxs(t.Fragment,{children:[t.jsx(he,{className:"h-4 mx-2 cursor-pointer text-muted-foreground",onClick:l=>{l.stopPropagation(),re()}}),t.jsx(pe,{orientation:"vertical",className:"flex min-h-6 h-full"})]}),t.jsx(ie,{className:"h-4 mx-2 cursor-pointer text-muted-foreground"})]})]}):t.jsxs("div",{className:"flex items-center justify-between w-full mx-auto",children:[t.jsx("span",{className:"text-sm text-muted-foreground mx-3",children:Y}),t.jsx(ie,{className:"h-4 cursor-pointer text-muted-foreground mx-2"})]}),e[35]=f,e[36]=ae,e[37]=re,e[38]=c,e[39]=i,e[40]=n,e[41]=o,e[42]=Y,e[43]=p,e[44]=s,e[45]=d,e[46]=u,e[47]=v):v=e[47];let j;e[48]!==h||e[49]!==g||e[50]!==Q||e[51]!==b||e[52]!==v?(j=t.jsx(ge,{asChild:!0,children:t.jsx(be,{ref:Q,...g,onClick:ue,disabled:h,className:b,children:v})}),e[48]=h,e[49]=g,e[50]=Q,e[51]=b,e[52]=v,e[53]=j):j=e[53];let J;e[54]===Symbol.for("react.memo_cache_sentinel")?(J=()=>M(!1),e[54]=J):J=e[54];let y;e[55]!==le||e[56]!==ee?(y=t.jsx(je,{placeholder:ee,onKeyDown:le}),e[55]=le,e[56]=ee,e[57]=y):y=e[57];let C;e[58]!==Z?(C=t.jsx(ye,{children:Z}),e[58]=Z,e[59]=C):C=e[59];let w;if(e[60]!==o||e[61]!==s||e[62]!==d){let l;e[64]!==s||e[65]!==d?(l=r=>{const V=s.includes(r.value);return t.jsxs(Ce,{onSelect:()=>d(r.value),className:"cursor-pointer",children:[t.jsx("div",{className:R("mr-2 flex h-5 w-5 items-center justify-center rounded border border-primary",V?"bg-primary text-primary-foreground":"opacity-50 [&_svg]:invisible"),children:t.jsx(we,{className:"h-4 w-4 text-primary-foreground"})}),r.icon&&t.jsx(r.icon,{className:"mr-2 h-4 w-4 text-muted-foreground"}),t.jsx("span",{children:r.label})]},r.value)},e[64]=s,e[65]=d,e[66]=l):l=e[66],w=o.map(l),e[60]=o,e[61]=s,e[62]=d,e[63]=w}else w=e[63];let N;e[67]!==w?(N=t.jsx(Ne,{children:w}),e[67]=w,e[68]=N):N=e[68];let W;e[69]===Symbol.for("react.memo_cache_sentinel")?(W=t.jsx(Se,{}),e[69]=W):W=e[69];let S;e[70]!==C||e[71]!==N?(S=t.jsxs(ke,{children:[C,N,W]}),e[70]=C,e[71]=N,e[72]=S):S=e[72];let k;e[73]!==y||e[74]!==S?(k=t.jsx(Pe,{className:"w-auto p-0 z-[410]",align:"start",onEscapeKeyDown:J,children:t.jsxs(Ve,{children:[y,S]})}),e[73]=y,e[74]=S,e[75]=k):k=e[75];let P;e[76]!==f||e[77]!==c||e[78]!==n||e[79]!==s.length?(P=f>0&&s.length>0&&n==="multiple"&&t.jsx(ve,{className:R("cursor-pointer my-2 text-foreground bg-background w-3 h-3",c?"":"text-muted-foreground"),onClick:()=>me(!c)}),e[76]=f,e[77]=c,e[78]=n,e[79]=s.length,e[80]=P):P=e[80];let _;return e[81]!==se||e[82]!==te||e[83]!==j||e[84]!==k||e[85]!==P?(_=t.jsxs(Ee,{open:se,onOpenChange:M,modal:te,children:[j,k,P]}),e[81]=se,e[82]=te,e[83]=j,e[84]=k,e[85]=P,e[86]=_):_=e[86],_});De.displayName="MultiSelect";function Ie(E){return!E}export{De as default};
1
+ import{r as _,c as fe,aa as R,j as t,bF as oe,bG as xe,at as he,bH as pe,bI as ie,bl as ge,B as be,bJ as ve,bK as je,bL as ye,bM as we,ap as Ce,bN as Ne,bO as Se,bP as Pe,bn as ke,bQ as Ve,bo as Ee}from"./app.js";const ce=xe("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"}}),Ie=_.forwardRef((E,q)=>{const e=fe.c(87);let x,h,a,o,p,g,m,I,D,O,F,K,$,U,B,u;e[0]!==E?({options:o,onValueChange:a,variant:u,processing:p,disabled:h,defaultValue:m,placeholder:I,notFound:D,search:O,animation:F,maxCount:K,modalPopover:$,asChild:U,className:x,mode:B,...g}=E,e[0]=E,e[1]=x,e[2]=h,e[3]=a,e[4]=o,e[5]=p,e[6]=g,e[7]=m,e[8]=I,e[9]=D,e[10]=O,e[11]=F,e[12]=K,e[13]=$,e[14]=U,e[15]=B,e[16]=u):(x=e[1],h=e[2],a=e[3],o=e[4],p=e[5],g=e[6],m=e[7],I=e[8],D=e[9],O=e[10],F=e[11],K=e[12],$=e[13],U=e[14],B=e[15],u=e[16]);let T;e[17]!==m?(T=m===void 0?[]:m,e[17]=m,e[18]=T):T=e[18];const de=T,Y=I===void 0?"":I,Z=D===void 0?"":D,ee=O===void 0?"":O,f=F===void 0?0:F,i=K===void 0?3:K,te=$===void 0?!1:$,n=B===void 0?"multiple":B,[s,A]=_.useState(de),[se,M]=_.useState(!1),[c,me]=_.useState(!1);let G;e[19]!==a||e[20]!==s?(G=l=>{if(l.key==="Enter")M(!0);else if(l.key==="Backspace"&&!l.currentTarget.value){const r=[...s];r.pop(),A(r),a(r)}},e[19]=a,e[20]=s,e[21]=G):G=e[21];const le=G;let L;e[22]!==n||e[23]!==a||e[24]!==s?(L=l=>{let r;n==="single"?r=s.includes(l)?[]:[l]:r=s.includes(l)?s.filter(V=>V!==l):[...s,l],A(r),a(r),n==="single"&&M(!1)},e[22]=n,e[23]=a,e[24]=s,e[25]=L):L=e[25];const d=L;let X;e[26]!==a?(X=()=>{A([]),a([])},e[26]=a,e[27]=X):X=e[27];const re=X;let z;e[28]===Symbol.for("react.memo_cache_sentinel")?(z=()=>{M(De)},e[28]=z):z=e[28];const ue=z;let H;e[29]!==i||e[30]!==a||e[31]!==s?(H=()=>{const l=s.slice(0,i);A(l),a(l)},e[29]=i,e[30]=a,e[31]=s,e[32]=H):H=e[32];const ae=H;let b;e[33]!==x?(b=R("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",x),e[33]=x,e[34]=b):b=e[34];let v;e[35]!==f||e[36]!==ae||e[37]!==re||e[38]!==c||e[39]!==i||e[40]!==n||e[41]!==o||e[42]!==Y||e[43]!==p||e[44]!==s||e[45]!==d||e[46]!==u?(v=s.length>0?t.jsxs("div",{className:"flex justify-between items-center w-full",children:[t.jsxs("div",{className:"flex flex-wrap items-center",children:[s.slice(0,i).map(l=>{const r=o.find(ne=>ne.value===l),V=r==null?void 0:r.icon;return t.jsxs("div",{className:R(c?"animate-bounce":"",ce({variant:u})),style:{animationDuration:`${f}s`},children:[V&&t.jsx(V,{className:"h-4 w-4 mr-2"}),r==null?void 0:r.label,t.jsx(oe,{className:"ml-2 h-4 w-4 cursor-pointer",onClick:ne=>{ne.stopPropagation(),p||d(l)}})]},l)}),n==="multiple"&&s.length>i&&t.jsxs("div",{className:R("bg-transparent text-foreground border-foreground/1 hover:bg-transparent",c?"animate-bounce":"",ce({variant:u})),style:{animationDuration:`${f}s`},children:[`+ ${s.length-i} more`,t.jsx(oe,{className:"ml-2 h-4 w-4 cursor-pointer",onClick:l=>{l.stopPropagation(),ae()}})]})]}),t.jsxs("div",{className:"flex items-center justify-between",children:[s.length>0&&t.jsxs(t.Fragment,{children:[t.jsx(he,{className:"h-4 mx-2 cursor-pointer text-muted-foreground",onClick:l=>{l.stopPropagation(),re()}}),t.jsx(pe,{orientation:"vertical",className:"flex min-h-6 h-full"})]}),t.jsx(ie,{className:"h-4 mx-2 cursor-pointer text-muted-foreground"})]})]}):t.jsxs("div",{className:"flex items-center justify-between w-full mx-auto",children:[t.jsx("span",{className:"text-sm text-muted-foreground mx-3",children:Y}),t.jsx(ie,{className:"h-4 cursor-pointer text-muted-foreground mx-2"})]}),e[35]=f,e[36]=ae,e[37]=re,e[38]=c,e[39]=i,e[40]=n,e[41]=o,e[42]=Y,e[43]=p,e[44]=s,e[45]=d,e[46]=u,e[47]=v):v=e[47];let j;e[48]!==h||e[49]!==g||e[50]!==q||e[51]!==b||e[52]!==v?(j=t.jsx(ge,{asChild:!0,children:t.jsx(be,{ref:q,...g,onClick:ue,disabled:h,className:b,children:v})}),e[48]=h,e[49]=g,e[50]=q,e[51]=b,e[52]=v,e[53]=j):j=e[53];let J;e[54]===Symbol.for("react.memo_cache_sentinel")?(J=()=>M(!1),e[54]=J):J=e[54];let y;e[55]!==le||e[56]!==ee?(y=t.jsx(je,{placeholder:ee,onKeyDown:le}),e[55]=le,e[56]=ee,e[57]=y):y=e[57];let w;e[58]!==Z?(w=t.jsx(ye,{children:Z}),e[58]=Z,e[59]=w):w=e[59];let C;if(e[60]!==o||e[61]!==s||e[62]!==d){let l;e[64]!==s||e[65]!==d?(l=r=>{const V=s.includes(r.value);return t.jsxs(we,{onSelect:()=>d(r.value),className:"cursor-pointer",children:[t.jsx("div",{className:R("mr-2 flex h-5 w-5 items-center justify-center rounded border border-primary",V?"bg-primary text-primary-foreground":"opacity-50 [&_svg]:invisible"),children:t.jsx(Ce,{className:"h-4 w-4 text-primary-foreground"})}),r.icon&&t.jsx(r.icon,{className:"mr-2 h-4 w-4 text-muted-foreground"}),t.jsx("span",{children:r.label})]},r.value)},e[64]=s,e[65]=d,e[66]=l):l=e[66],C=o.map(l),e[60]=o,e[61]=s,e[62]=d,e[63]=C}else C=e[63];let N;e[67]!==C?(N=t.jsx(Ne,{children:C}),e[67]=C,e[68]=N):N=e[68];let Q;e[69]===Symbol.for("react.memo_cache_sentinel")?(Q=t.jsx(Se,{}),e[69]=Q):Q=e[69];let S;e[70]!==w||e[71]!==N?(S=t.jsxs(Pe,{children:[w,N,Q]}),e[70]=w,e[71]=N,e[72]=S):S=e[72];let P;e[73]!==y||e[74]!==S?(P=t.jsx(ke,{className:"w-auto p-0 z-[410]",align:"start",onEscapeKeyDown:J,children:t.jsxs(Ve,{children:[y,S]})}),e[73]=y,e[74]=S,e[75]=P):P=e[75];let k;e[76]!==f||e[77]!==c||e[78]!==n||e[79]!==s.length?(k=f>0&&s.length>0&&n==="multiple"&&t.jsx(ve,{className:R("cursor-pointer my-2 text-foreground bg-background w-3 h-3",c?"":"text-muted-foreground"),onClick:()=>me(!c)}),e[76]=f,e[77]=c,e[78]=n,e[79]=s.length,e[80]=k):k=e[80];let W;return e[81]!==se||e[82]!==te||e[83]!==j||e[84]!==P||e[85]!==k?(W=t.jsxs(Ee,{open:se,onOpenChange:M,modal:te,children:[j,P,k]}),e[81]=se,e[82]=te,e[83]=j,e[84]=P,e[85]=k,e[86]=W):W=e[86],W});Ie.displayName="MultiSelect";function De(E){return!E}export{Ie as default};
@@ -1 +1 @@
1
- import{c as u,j as t,b7 as d,aV as p,b1 as x,br as h,aU as f}from"./app.js";import{Icon as m}from"./icon-ChQBPA5l.js";function S(r){const e=u.c(12);let o,a,s;e[0]!==r?({items:a,className:o,...s}=r,e[0]=r,e[1]=o,e[2]=a,e[3]=s):(o=e[1],a=e[2],s=e[3]);const c=`group-data-[collapsible=icon]:p-0 ${o||""}`;let n;e[4]!==a?(n=a.map(b),e[4]=a,e[5]=n):n=e[5];let l;e[6]!==n?(l=t.jsx(h,{children:t.jsx(f,{children:n})}),e[6]=n,e[7]=l):l=e[7];let i;return e[8]!==s||e[9]!==c||e[10]!==l?(i=t.jsx(d,{...s,className:c,children:l}),e[8]=s,e[9]=c,e[10]=l,e[11]=i):i=e[11],i}function b(r){return t.jsx(p,{children:t.jsx(x,{asChild:!0,className:"text-neutral-600 hover:text-neutral-800 dark:text-neutral-300 dark:hover:text-neutral-100",children:t.jsxs("a",{href:r.href,target:"_blank",rel:"noopener noreferrer",children:[r.icon&&t.jsx(m,{iconNode:r.icon,className:"h-5 w-5"}),t.jsx("span",{children:r.title})]})})},r.title)}export{S as NavFooter};
1
+ import{c as u,j as t,ba as d,aY as p,b4 as x,bu as h,aX as f}from"./app.js";import{Icon as m}from"./icon-BWrEqTE-.js";function S(r){const e=u.c(12);let o,a,s;e[0]!==r?({items:a,className:o,...s}=r,e[0]=r,e[1]=o,e[2]=a,e[3]=s):(o=e[1],a=e[2],s=e[3]);const c=`group-data-[collapsible=icon]:p-0 ${o||""}`;let n;e[4]!==a?(n=a.map(b),e[4]=a,e[5]=n):n=e[5];let l;e[6]!==n?(l=t.jsx(h,{children:t.jsx(f,{children:n})}),e[6]=n,e[7]=l):l=e[7];let i;return e[8]!==s||e[9]!==c||e[10]!==l?(i=t.jsx(d,{...s,className:c,children:l}),e[8]=s,e[9]=c,e[10]=l,e[11]=i):i=e[11],i}function b(r){return t.jsx(p,{children:t.jsx(x,{asChild:!0,className:"text-neutral-600 hover:text-neutral-800 dark:text-neutral-300 dark:hover:text-neutral-100",children:t.jsxs("a",{href:r.href,target:"_blank",rel:"noopener noreferrer",children:[r.icon&&t.jsx(m,{iconNode:r.icon,className:"h-5 w-5"}),t.jsx("span",{children:r.title})]})})},r.title)}export{S as NavFooter};
@@ -1 +1 @@
1
- import{c as w,q as E,r as G,j as e,bo as $,aV as N,b0 as _,b1 as g,C as M,bp as A,aS as O,b2 as R,b3 as U,$ as v,b7 as q,bq as z,br as B,aU as L}from"./app.js";import m from"./material-icon-BIcI8APG.js";function T(a){const t=w.c(15),{items:l}=a;let f;t[0]!==l?(f=l===void 0?[]:l,t[0]=l,t[1]=f):f=t[1];const p=f,h=E();let b;t[2]!==p?(b=()=>{const u={};return p.forEach(o=>{const c=o.section||"Platform";c in u||(u[c]=!0)}),u},t[2]=p,t[3]=b):b=t[3];const[d,y]=G.useState(b),k=Q;let x;if(t[4]!==p||t[5]!==d||t[6]!==h){const u=p.reduce(P,{});let o;if(t[8]!==h){o=r=>{var n,C;const{item:s}=r;return((n=s.actions)==null?void 0:n.length)>0?e.jsx($,{asChild:!0,defaultOpen:j(s.link),className:"group/collapsible",children:e.jsxs(N,{children:[e.jsx(_,{asChild:!0,children:e.jsxs(g,{tooltip:s.title,children:[e.jsx(m,{name:s.icon,className:"!text-[18px]"}),e.jsx("span",{className:"overflow-hidden text-ellipsis whitespace-nowrap",children:s.title}),e.jsx(M,{className:"ml-auto transition-transform duration-200 group-data-[state=open]/collapsible:rotate-90"})]})}),e.jsx(A,{children:e.jsx(O,{children:(C=s.actions)==null?void 0:C.map(i=>e.jsx(R,{children:e.jsx(U,{asChild:!0,isActive:j(i.link),children:i.type==="blank"?e.jsxs("a",{href:i.link,target:"_blank",rel:"noopener noreferrer",children:[i.icon&&e.jsx(m,{name:i.icon,className:"!text-[18px]"}),e.jsx("span",{children:i.title})]}):e.jsxs(v,{href:i.link,children:[i.icon&&e.jsx(m,{name:i.icon,className:"!text-[18px]"}),e.jsx("span",{children:i.title})]})})},i.id))})})]})},s.title):e.jsx(N,{children:e.jsx(g,{asChild:!0,isActive:j(s.link),tooltip:{children:s.title},children:s.type==="blank"?e.jsxs("a",{href:s.link,target:"_blank",rel:"noopener noreferrer",children:[s.icon&&e.jsx(m,{name:s.icon,className:"!text-[18px]"}),e.jsx("span",{children:s.title})]}):e.jsxs(v,{href:s.link,children:[s.icon&&e.jsx(m,{name:s.icon,className:"!text-[18px]"}),e.jsx("span",{children:s.title})]})})},s.title)};const j=r=>{const s=k(h.url),n=k(r);return s===n||s.startsWith(`${n}/`)};t[8]=h,t[9]=o}else o=t[9];let c;t[10]!==o||t[11]!==d?(c=j=>{const[r,s]=j;return e.jsxs(q,{className:"px-2 py-0",children:[e.jsx(z,{asChild:!0,className:"cursor-pointer",onClick:()=>y(n=>({...n,[r]:!n[r]})),children:e.jsxs("div",{className:"flex items-center gap-1",children:[e.jsx(M,{className:`transform transition-transform duration-200 ${d[r]?"rotate-90":""}`}),e.jsx("span",{children:r})]})}),d[r]&&e.jsx(B,{children:e.jsx(L,{children:s.map(n=>e.jsx(o,{item:n},n.id||n.title))})})]},r)},t[10]=o,t[11]=d,t[12]=c):c=t[12],x=Object.entries(u).map(c),t[4]=p,t[5]=d,t[6]=h,t[7]=x}else x=t[7];let S;return t[13]!==x?(S=e.jsx(e.Fragment,{children:x}),t[13]=x,t[14]=S):S=t[14],S}function P(a,t){const l=t.section||"Platform";return a[l]||(a[l]=[]),a[l].push(t),a}function Q(a){return a.split("?")[0].replace(/\/$/,"")}export{T as NavMain};
1
+ import{c as w,q as E,r as G,j as e,br as $,aY as N,b3 as _,b4 as g,C as M,bs as A,aV as O,b5 as R,b6 as z,$ as v,ba as B,bt as L,bu as P,aX as Q}from"./app.js";import m from"./material-icon-BE8cT_z7.js";function T(a){const t=w.c(15),{items:l}=a;let f;t[0]!==l?(f=l===void 0?[]:l,t[0]=l,t[1]=f):f=t[1];const p=f,h=E();let b;t[2]!==p?(b=()=>{const u={};return p.forEach(o=>{const c=o.section||"Platform";c in u||(u[c]=!0)}),u},t[2]=p,t[3]=b):b=t[3];const[d,y]=G.useState(b),k=q;let x;if(t[4]!==p||t[5]!==d||t[6]!==h){const u=p.reduce(U,{});let o;if(t[8]!==h){o=r=>{var n,C;const{item:s}=r;return((n=s.actions)==null?void 0:n.length)>0?e.jsx($,{asChild:!0,defaultOpen:j(s.link),className:"group/collapsible",children:e.jsxs(N,{children:[e.jsx(_,{asChild:!0,children:e.jsxs(g,{tooltip:s.title,children:[e.jsx(m,{name:s.icon,className:"!text-[18px]"}),e.jsx("span",{className:"overflow-hidden text-ellipsis whitespace-nowrap",children:s.title}),e.jsx(M,{className:"ml-auto transition-transform duration-200 group-data-[state=open]/collapsible:rotate-90"})]})}),e.jsx(A,{children:e.jsx(O,{children:(C=s.actions)==null?void 0:C.map(i=>e.jsx(R,{children:e.jsx(z,{asChild:!0,isActive:j(i.link),children:i.type==="blank"?e.jsxs("a",{href:i.link,target:"_blank",rel:"noopener noreferrer",children:[i.icon&&e.jsx(m,{name:i.icon,className:"!text-[18px]"}),e.jsx("span",{children:i.title})]}):e.jsxs(v,{href:i.link,children:[i.icon&&e.jsx(m,{name:i.icon,className:"!text-[18px]"}),e.jsx("span",{children:i.title})]})})},i.id))})})]})},s.title):e.jsx(N,{children:e.jsx(g,{asChild:!0,isActive:j(s.link),tooltip:{children:s.title},children:s.type==="blank"?e.jsxs("a",{href:s.link,target:"_blank",rel:"noopener noreferrer",children:[s.icon&&e.jsx(m,{name:s.icon,className:"!text-[18px]"}),e.jsx("span",{children:s.title})]}):e.jsxs(v,{href:s.link,children:[s.icon&&e.jsx(m,{name:s.icon,className:"!text-[18px]"}),e.jsx("span",{children:s.title})]})})},s.title)};const j=r=>{const s=k(h.url),n=k(r);return s===n||s.startsWith(`${n}/`)};t[8]=h,t[9]=o}else o=t[9];let c;t[10]!==o||t[11]!==d?(c=j=>{const[r,s]=j;return e.jsxs(B,{className:"px-2 py-0",children:[e.jsx(L,{asChild:!0,className:"cursor-pointer",onClick:()=>y(n=>({...n,[r]:!n[r]})),children:e.jsxs("div",{className:"flex items-center gap-1",children:[e.jsx(M,{className:`transform transition-transform duration-200 ${d[r]?"rotate-90":""}`}),e.jsx("span",{children:r})]})}),d[r]&&e.jsx(P,{children:e.jsx(Q,{children:s.map(n=>e.jsx(o,{item:n},n.id||n.title))})})]},r)},t[10]=o,t[11]=d,t[12]=c):c=t[12],x=Object.entries(u).map(c),t[4]=p,t[5]=d,t[6]=h,t[7]=x}else x=t[7];let S;return t[13]!==x?(S=e.jsx(e.Fragment,{children:x}),t[13]=x,t[14]=S):S=t[14],S}function U(a,t){const l=t.section||"Platform";return a[l]||(a[l]=[]),a[l].push(t),a}function q(a){return a.split("?")[0].replace(/\/$/,"")}export{T as NavMain};
@@ -1 +1 @@
1
- import{c as b,q as f,bs as x,bt as g,j as s,aP as h,w as j,b1 as w,y as M,aU as S,aV as U,aJ as C}from"./app.js";import{UserInfo as D}from"./user-info-Db5Y8KeN.js";import{UserMenuContent as N}from"./user-menu-content-Bc8YNZPf.js";function y(){const e=b.c(15),{auth:t,logout:u,logoutBtn:c}=f().props,{state:m}=x(),p=g();let r;e[0]!==t.user?(r=s.jsx(D,{user:t.user}),e[0]=t.user,e[1]=r):r=e[1];let a;e[2]===Symbol.for("react.memo_cache_sentinel")?(a=s.jsx(h,{className:"ml-auto size-4"}),e[2]=a):a=e[2];let o;e[3]!==r?(o=s.jsx(j,{asChild:!0,children:s.jsxs(w,{size:"lg",className:"text-sidebar-accent-foreground data-[state=open]:bg-sidebar-accent group focus-visible:ring-0 cursor-pointer",children:[r,a]})}),e[3]=r,e[4]=o):o=e[4];const d=p?"bottom":m==="collapsed"?"left":"bottom";let n;e[5]!==t.user||e[6]!==u||e[7]!==c?(n=s.jsx(N,{user:t.user,logout:u,logoutBtn:c}),e[5]=t.user,e[6]=u,e[7]=c,e[8]=n):n=e[8];let i;e[9]!==d||e[10]!==n?(i=s.jsx(M,{className:"w-(--radix-dropdown-menu-trigger-width) min-w-56 rounded-lg z-[1002]",align:"end",side:d,children:n}),e[9]=d,e[10]=n,e[11]=i):i=e[11];let l;return e[12]!==o||e[13]!==i?(l=s.jsx(S,{children:s.jsx(U,{children:s.jsxs(C,{children:[o,i]})})}),e[12]=o,e[13]=i,e[14]=l):l=e[14],l}export{y as NavUser};
1
+ import{c as b,q as f,bv as x,bw as g,j as s,aS as h,w as j,b4 as w,y as M,aX as S,aY as N,aN as v}from"./app.js";import{UserInfo as C}from"./user-info-CJp_GYZl.js";import{UserMenuContent as D}from"./user-menu-content-ljwR9luU.js";function y(){const e=b.c(15),{auth:t,logout:u,logoutBtn:c}=f().props,{state:m}=x(),p=g();let r;e[0]!==t.user?(r=s.jsx(C,{user:t.user}),e[0]=t.user,e[1]=r):r=e[1];let a;e[2]===Symbol.for("react.memo_cache_sentinel")?(a=s.jsx(h,{className:"ml-auto size-4"}),e[2]=a):a=e[2];let o;e[3]!==r?(o=s.jsx(j,{asChild:!0,children:s.jsxs(w,{size:"lg",className:"text-sidebar-accent-foreground data-[state=open]:bg-sidebar-accent group focus-visible:ring-0 cursor-pointer",children:[r,a]})}),e[3]=r,e[4]=o):o=e[4];const d=p?"bottom":m==="collapsed"?"left":"bottom";let n;e[5]!==t.user||e[6]!==u||e[7]!==c?(n=s.jsx(D,{user:t.user,logout:u,logoutBtn:c}),e[5]=t.user,e[6]=u,e[7]=c,e[8]=n):n=e[8];let i;e[9]!==d||e[10]!==n?(i=s.jsx(M,{className:"w-(--radix-dropdown-menu-trigger-width) min-w-56 rounded-lg z-[1002]",align:"end",side:d,children:n}),e[9]=d,e[10]=n,e[11]=i):i=e[11];let l;return e[12]!==o||e[13]!==i?(l=s.jsx(S,{children:s.jsx(N,{children:s.jsxs(v,{children:[o,i]})})}),e[12]=o,e[13]=i,e[14]=l):l=e[14],l}export{y as NavUser};
@@ -0,0 +1 @@
1
+ import{c as V,j as t,a3 as X,a4 as I,a5 as k,a6 as T,U as Y,V as Z,B as G,a7 as F,W as ee,a8 as se,a9 as te,aa as U,ab as W,e as ae,P as le,ac as ie,ad as ne,r as C,ae as oe,af as ce,ag as de,ah as me,ai as he,q as pe,p as ue,L as xe}from"./app.js";import{A as fe}from"./app-layout-CDjEwM9a.js";import{T as K,a as Q,b as ge,c as je}from"./tabs-D5eQoog9.js";import{u as be}from"./app-sidebar-header-B1mI-oGm.js";import"./app-shell-CByYJPLe.js";import"./app-sidebar-CLPoDV2f.js";import"./nav-main-DQNNAKwu.js";import"./material-icon-BE8cT_z7.js";import"./breadcrumbs-0GLBx1iv.js";import"./nav-user-q7QW6ZiI.js";import"./user-info-CJp_GYZl.js";import"./user-menu-content-ljwR9luU.js";import"./theme-switcher-BZ6eg-WU.js";import"./use-appearance-CXP5cHaQ.js";import"./icon-BWrEqTE-.js";const Ne=s=>{const e=V.c(10),{notifications:o,onMarkAsRead:N}=s;let p;e[0]!==N?(p=async(l,a)=>{try{await N(l,a)}catch(f){console.error("Error marking as read:",f)}},e[0]=N,e[1]=p):p=e[1];const g=p;let x;e[2]===Symbol.for("react.memo_cache_sentinel")?(x=t.jsx(X,{className:"sticky top-0 bg-background shadow z-1",children:t.jsxs(I,{children:[t.jsx(k,{className:"p-2 text-left"}),t.jsx(k,{className:"p-2 text-left",children:"Title"}),t.jsx(k,{className:"p-2 text-left",children:"Message"}),t.jsx(k,{className:"p-2 text-left",children:"Date"})]})}),e[2]=x):x=e[2];let c;if(e[3]!==g||e[4]!==o){let l;e[6]!==g?(l=a=>t.jsxs(I,{className:`${a.read?"":"bg-chart-1/20 hover:bg-chart-1/20"}`,children:[t.jsx(T,{className:"p-2 align-top pt-2.5",children:t.jsxs(Y,{children:[t.jsx(Z,{asChild:!0,children:t.jsx(G,{variant:"ghost",size:"icon",className:`size-4 ${a.read?"opacity-50 pointer-events-none":""}`,onClick:()=>g(a.notificationClass,a.id),children:t.jsx(F,{className:"text-primary"})})}),t.jsx(ee,{side:"right",className:"z-[1003]",children:t.jsx("p",{children:"Make read"})})]})}),t.jsx(T,{className:"p-2 align-top font-medium",children:a.title}),t.jsx(T,{className:"p-2 whitespace-break-spaces",children:t.jsx("div",{className:"max-w-[500px] whitespace-break-spaces",children:a.message})}),t.jsx(T,{className:"p-2 align-top",children:new Date(a.createdAt).toLocaleString()})]},a.id),e[6]=g,e[7]=l):l=e[7],c=o.map(l),e[3]=g,e[4]=o,e[5]=c}else c=e[5];let j;return e[8]!==c?(j=t.jsxs(se,{wrapperHeight:"max-h-[75vh]",children:[x,t.jsx(te,{children:c})]}),e[8]=c,e[9]=j):j=e[9],j},ve=s=>{const e=V.c(20),{changes:o,title:N,className:p}=s,g=N===void 0?"Changes":N,x=p===void 0?"":p;if(!o||o.length===0){let m;e[0]!==x?(m=U("bg-muted border border-border rounded-lg p-4",x),e[0]=x,e[1]=m):m=e[1];let i;e[2]===Symbol.for("react.memo_cache_sentinel")?(i=t.jsxs("div",{className:"flex items-center text-muted-foreground",children:[t.jsx(F,{className:"w-5 h-5 mr-2"}),t.jsx("span",{children:"Changes not found"})]}),e[2]=i):i=e[2];let u;return e[3]!==m?(u=t.jsx("div",{className:m,children:i}),e[3]=m,e[4]=u):u=e[4],u}const c=ye,j=we;let l;e[5]!==x?(l=U("bg-card border border-border rounded-lg shadow-sm",x),e[5]=x,e[6]=l):l=e[6];let a;e[7]===Symbol.for("react.memo_cache_sentinel")?(a=t.jsx(W,{className:"w-5 h-5 mr-2"}),e[7]=a):a=e[7];let f;e[8]!==o.length||e[9]!==g?(f=t.jsx("div",{className:"px-4 py-3 border-b border-border bg-muted",children:t.jsxs("h3",{className:"text-lg font-semibold text-card-foreground flex items-center",children:[a,g," (",o.length,")"]})}),e[8]=o.length,e[9]=g,e[10]=f):f=e[10];let d;if(e[11]!==o){let m;e[13]===Symbol.for("react.memo_cache_sentinel")?(m=(i,u)=>{const n=j(i),b=n==="added"?le:n==="removed"?ie:W,h=U("text-xs px-2 py-1 rounded-full bg-opacity-10",n==="added"&&"text-green-600 bg-green-100",n==="removed"&&"text-destructive bg-destructive/20",n==="modified"&&"text-primary bg-primary/20"),w=n==="added"?"text-green-600":n==="removed"?"text-destructive":"text-primary";return t.jsxs("div",{className:"p-4 hover:bg-muted/50 transition-colors",children:[t.jsxs("div",{className:"flex items-center justify-between mb-2",children:[t.jsxs("div",{className:"flex items-center",children:[ae.createElement(b,{className:U("w-4 h-4 mr-2",w)}),t.jsx("span",{className:"font-medium text-card-foreground",children:i.field})]}),t.jsx("span",{className:h,children:n==="added"?"Added":n==="removed"?"Removed":"Updated"})]}),t.jsxs("div",{className:"grid grid-cols-1 md:grid-cols-2 gap-3 text-sm",children:[n!=="added"&&t.jsxs("div",{className:"p-2 bg-destructive/10 border border-destructive/20 rounded",children:[t.jsx("div",{className:"text-xs text-destructive font-medium mb-1",children:"Old:"}),t.jsx("div",{className:"text-destructive-foreground font-mono break-words",children:c(i.oldValue)})]}),n!=="removed"&&t.jsxs("div",{className:"p-2 bg-green-50 border border-green-100 rounded",children:[t.jsx("div",{className:"text-xs text-green-600 font-medium mb-1",children:"New:"}),t.jsx("div",{className:"text-green-800 font-mono break-words",children:c(i.newValue)})]})]}),n==="modified"&&t.jsxs("div",{className:"mt-2 flex items-center text-xs text-muted-foreground",children:[t.jsx(ne,{className:"w-3 h-3 mr-1"}),"changed type: ",i.type]})]},u)},e[13]=m):m=e[13],d=o.map(m),e[11]=o,e[12]=d}else d=e[12];let v;e[14]!==d?(v=t.jsx("div",{className:"divide-y divide-border",children:d}),e[14]=d,e[15]=v):v=e[15];let r;return e[16]!==l||e[17]!==f||e[18]!==v?(r=t.jsxs("div",{className:l,children:[f,v]}),e[16]=l,e[17]=f,e[18]=v,e[19]=r):r=e[19],r};function ye(s){return s===null?"null":s===void 0?"—":typeof s=="boolean"?s?"Да":"Нет":typeof s=="object"?JSON.stringify(s):String(s)}function we(s){return s.oldValue===void 0?"added":s.newValue===void 0?"removed":"modified"}const Ae=s=>{const e=V.c(20),{notifications:o,onMarkAsRead:N}=s,[p,g]=C.useState(!1),[x,c]=C.useState(null);let j;e[0]!==N?(j=async(b,h)=>{try{await N(b,h)}catch(w){console.error("Error marking as read:",w)}},e[0]=N,e[1]=j):j=e[1];const l=j;let a;e[2]===Symbol.for("react.memo_cache_sentinel")?(a=t.jsx(X,{className:"sticky top-0 bg-background shadow z-1",children:t.jsxs(I,{children:[t.jsx(k,{className:"p-2 text-left"}),t.jsx(k,{className:"p-2 text-left",children:"Title"}),t.jsx(k,{className:"p-2 text-left",children:"Message"}),t.jsx(k,{className:"p-2 text-left",children:"Date"}),t.jsx(k,{className:"p-2 text-left",children:"Diff"})]})}),e[2]=a):a=e[2];let f;if(e[3]!==l||e[4]!==o){let b;e[6]!==l?(b=h=>{var w;return t.jsxs(I,{className:`${h.read?"":"bg-chart-1/20 hover:bg-chart-1/20"}`,children:[t.jsx(T,{className:"p-2 pt-2.5",children:t.jsxs(Y,{children:[t.jsx(Z,{asChild:!0,children:t.jsx(G,{variant:"ghost",size:"icon",className:`size-4 ${h.read?"opacity-50 pointer-events-none":""}`,onClick:()=>l(h.notificationClass,h.id),children:t.jsx(F,{className:"text-primary"})})}),t.jsx(ee,{side:"right",className:"z-[1003]",children:t.jsx("p",{children:"Make read"})})]})}),t.jsx(T,{className:"p-2 font-medium",children:h.title}),t.jsx(T,{className:"p-2 whitespace-break-spaces",children:t.jsx("div",{className:"max-w-[500px] whitespace-break-spaces",children:h.message})}),t.jsx(T,{className:"p-2",children:new Date(h.createdAt).toLocaleString()}),t.jsx(T,{className:"p-2",children:((w=h.metadata)==null?void 0:w.changes)&&t.jsx(G,{variant:"green",size:"sm",onClick:()=>{var S;c((S=h.metadata)==null?void 0:S.changes),g(!0)},children:t.jsx(oe,{})})})]},h.id)},e[6]=l,e[7]=b):b=e[7],f=o.map(b),e[3]=l,e[4]=o,e[5]=f}else f=e[5];let d;e[8]!==f?(d=t.jsxs(se,{wrapperHeight:"max-h-[75vh]",children:[a,t.jsx(te,{children:f})]}),e[8]=f,e[9]=d):d=e[9];let v;e[10]===Symbol.for("react.memo_cache_sentinel")?(v=b=>{g(b),b||setTimeout(ke,300)},e[10]=v):v=e[10];let r;e[11]===Symbol.for("react.memo_cache_sentinel")?(r=t.jsx(ce,{children:t.jsx(de,{children:"Diff"})}),e[11]=r):r=e[11];const m=x;let i;e[12]!==m?(i=t.jsxs(me,{className:"z-[1022] sm:max-w-[60vw]",children:[r,t.jsx(ve,{changes:m,className:"max-h-[80vh] overflow-auto sm:max-w-[60vw] w-full"})]}),e[12]=m,e[13]=i):i=e[13];let u;e[14]!==p||e[15]!==i?(u=t.jsx(he,{open:p,onOpenChange:v,children:i}),e[14]=p,e[15]=i,e[16]=u):u=e[16];let n;return e[17]!==d||e[18]!==u?(n=t.jsxs("div",{children:[d,u]}),e[17]=d,e[18]=u,e[19]=n):n=e[19],n};function ke(){document.body.removeAttribute("style")}const Te=()=>{const s=V.c(54),e=pe(),{allNotifications:o,markAsRead:N,fetchAllNotifications:p,loading:g,refreshBellNotifications:x}=be(),[c,j]=C.useState(!0);let l;s[0]===Symbol.for("react.memo_cache_sentinel")?(l=[],s[0]=l):l=s[0];const[a,f]=C.useState(l);let d;s[1]!==e.props.auth.user.isAdministrator||s[2]!==e.url?(d=()=>{const A=new URL(e.url,window.location.origin).searchParams.get("type");return A==="system"&&e.props.auth.user.isAdministrator?"system":"general"},s[1]=e.props.auth.user.isAdministrator,s[2]=e.url,s[3]=d):d=s[3];const v=d,[r,m]=C.useState(v());let i,u;s[4]!==r||s[5]!==e.props.auth.user.isAdministrator||s[6]!==e.url?(i=()=>{const A=new URL(e.url,window.location.origin).searchParams.get("type");if(A&&A!==r){if(A==="system"&&!e.props.auth.user.isAdministrator){m("general");return}m(A)}},u=[e.url,r,e.props.auth.user.isAdministrator],s[4]=r,s[5]=e.props.auth.user.isAdministrator,s[6]=e.url,s[7]=i,s[8]=u):(i=s[7],u=s[8]),C.useEffect(i,u);let n;s[9]!==r||s[10]!==p?(n=()=>{(async()=>{j(!0),await p(r),j(!1)})()},s[9]=r,s[10]=p,s[11]=n):n=s[11];let b;s[12]!==r?(b=[r],s[12]=r,s[13]=b):b=s[13],C.useEffect(n,b);let h,w;s[14]!==r||s[15]!==o?(h=()=>{const y=o.filter(A=>A.notificationClass===r);f(y)},w=[o,r],s[14]=r,s[15]=o,s[16]=h,s[17]=w):(h=s[16],w=s[17]),C.useEffect(h,w);let S;s[18]!==p||s[19]!==e.props.auth.user.isAdministrator||s[20]!==e.url?(S=async y=>{y==="system"&&!e.props.auth.user.isAdministrator||(m(y),j(!0),ue.get(e.url,{type:y},{preserveState:!0,preserveScroll:!0,replace:!0}),await p(y),j(!1))},s[18]=p,s[19]=e.props.auth.user.isAdministrator,s[20]=e.url,s[21]=S):S=s[21];const q=S;let P;s[22]!==N||s[23]!==x?(P=async(y,A)=>{try{await N(y,A),await x()}catch(re){const J=re;throw console.error("Error marking as read:",J),J}},s[22]=N,s[23]=x,s[24]=P):P=s[24];const B=P;let H;s[25]!==g||s[26]!==a||s[27]!==B||s[28]!==c?(H=y=>c||g?t.jsx(xe,{className:"mx-auto mt-14 size-8 animate-spin"}):a.length===0?t.jsx("div",{className:"text-center font-medium mt-8",children:"No notifications found"}):y==="general"?t.jsx(Ne,{notifications:a,onMarkAsRead:B}):t.jsx(Ae,{notifications:a,onMarkAsRead:B}),s[25]=g,s[26]=a,s[27]=B,s[28]=c,s[29]=H):H=s[29];const _=H;let D;s[30]!==e.props.title?(D=t.jsx("h1",{className:"font-bold text-xl",children:e.props.title}),s[30]=e.props.title,s[31]=D):D=s[31];let R;s[32]!==c?(R=t.jsx(K,{value:"general",disabled:c,children:"General"}),s[32]=c,s[33]=R):R=s[33];let L;s[34]!==c||s[35]!==e.props.auth.user.isAdministrator?(L=e.props.auth.user.isAdministrator&&t.jsx(K,{value:"system",disabled:c,children:"System"}),s[34]=c,s[35]=e.props.auth.user.isAdministrator,s[36]=L):L=s[36];let M;s[37]!==R||s[38]!==L?(M=t.jsxs(ge,{className:"w-full mb-4",children:[R,L]}),s[37]=R,s[38]=L,s[39]=M):M=s[39];let z;s[40]!==_?(z=t.jsx(Q,{value:"general",children:_("general")}),s[40]=_,s[41]=z):z=s[41];let E;s[42]!==e.props.auth.user.isAdministrator||s[43]!==_?(E=e.props.auth.user.isAdministrator&&t.jsx(Q,{value:"system",children:_("system")}),s[42]=e.props.auth.user.isAdministrator,s[43]=_,s[44]=E):E=s[44];let $;s[45]!==r||s[46]!==q||s[47]!==M||s[48]!==z||s[49]!==E?($=t.jsxs(je,{value:r,className:"w-full",onValueChange:q,children:[M,z,E]}),s[45]=r,s[46]=q,s[47]=M,s[48]=z,s[49]=E,s[50]=$):$=s[50];let O;return s[51]!==D||s[52]!==$?(O=t.jsxs("div",{className:"flex h-auto flex-1 flex-col gap-4 rounded-xl p-4",children:[D,$]}),s[51]=D,s[52]=$,s[53]=O):O=s[53],O},Se=[],Ie=()=>{const s=V.c(1);let e;return s[0]===Symbol.for("react.memo_cache_sentinel")?(e=t.jsx(fe,{breadcrumbs:Se,children:t.jsx(Te,{})}),s[0]=e):e=s[0],e};export{Ie as default};
@@ -1 +1 @@
1
- import{c as F,j as a,bS as k,bT as _,bU as w,bV as A,bW as S,bX as T}from"./app.js";const q=i=>{const e=F.c(44),{pagination:t,pageChange:n,currentPage:s}=i,D=t.links.filter(U).map(W),I=D.includes(1),L=D.includes(t.last_page),y=`${I?"opacity-50 pointer-events-none":"opacity-100"}`,j=`px-6 cursor-pointer bg-secondary hover:bg-muted-foreground/15 ${s===1?"opacity-50 pointer-events-none":""}`;let o;e[0]!==s||e[1]!==n?(o=r=>{r.preventDefault(),s!==1&&n(1)},e[0]=s,e[1]=n,e[2]=o):o=e[2];let l;e[3]!==j||e[4]!==o?(l=a.jsx(k,{className:j,onClick:o,children:"First"}),e[3]=j,e[4]=o,e[5]=l):l=e[5];let c;e[6]!==y||e[7]!==l?(c=a.jsx(_,{className:y,children:l}),e[6]=y,e[7]=l,e[8]=c):c=e[8];const P=`cursor-pointer bg-secondary hover:bg-muted-foreground/15 ${t.prev_page_url?"":"opacity-50 pointer-events-none"}`;let p;e[9]!==s||e[10]!==n||e[11]!==t.prev_page_url?(p=r=>{r.preventDefault(),t.prev_page_url&&n(s-1)},e[9]=s,e[10]=n,e[11]=t.prev_page_url,e[12]=p):p=e[12];let u;e[13]!==P||e[14]!==p?(u=a.jsx(_,{children:a.jsx(w,{className:P,onClick:p})}),e[13]=P,e[14]=p,e[15]=u):u=e[15];let g;if(e[16]!==n||e[17]!==t.links){let r;e[19]!==n?(r=(v,R)=>v.label==="Previous"||v.label==="Next"?null:a.jsx(_,{children:a.jsx(k,{className:`cursor-pointer bg-secondary hover:bg-muted-foreground/15 ${v.active?"!bg-primary dark:!bg-muted-foreground !text-primary-foreground dark:!text-ring":""}`,onClick:V=>{V.preventDefault();const E=parseInt(v.label);n(E)},isActive:v.active,children:v.label})},R),e[19]=n,e[20]=r):r=e[20],g=t.links.map(r),e[16]=n,e[17]=t.links,e[18]=g}else g=e[18];const N=`cursor-pointer bg-secondary hover:bg-muted-foreground/15 ${t.next_page_url?"":"opacity-50 pointer-events-none"}`;let f;e[21]!==s||e[22]!==n||e[23]!==t.next_page_url?(f=r=>{r.preventDefault(),t.next_page_url&&n(s+1)},e[21]=s,e[22]=n,e[23]=t.next_page_url,e[24]=f):f=e[24];let d;e[25]!==N||e[26]!==f?(d=a.jsx(_,{children:a.jsx(A,{className:N,onClick:f})}),e[25]=N,e[26]=f,e[27]=d):d=e[27];const $=`${L?"opacity-50 pointer-events-none":"opacity-100"}`,C=`px-6 cursor-pointer bg-secondary hover:bg-muted-foreground/15 ${s===t.last_page?"opacity-50 pointer-events-none":""}`;let b;e[28]!==s||e[29]!==n||e[30]!==t.last_page?(b=r=>{r.preventDefault(),s!==t.last_page&&n(t.last_page)},e[28]=s,e[29]=n,e[30]=t.last_page,e[31]=b):b=e[31];let m;e[32]!==C||e[33]!==b?(m=a.jsx(k,{className:C,onClick:b,children:"Last"}),e[32]=C,e[33]=b,e[34]=m):m=e[34];let x;e[35]!==$||e[36]!==m?(x=a.jsx(_,{className:$,children:m}),e[35]=$,e[36]=m,e[37]=x):x=e[37];let h;return e[38]!==d||e[39]!==x||e[40]!==c||e[41]!==u||e[42]!==g?(h=a.jsx(S,{children:a.jsxs(T,{className:"flex-wrap",children:[c,u,g,d,x]})}),e[38]=d,e[39]=x,e[40]=c,e[41]=u,e[42]=g,e[43]=h):h=e[43],h};function U(i){return i.label!=="Previous"&&i.label!=="Next"}function W(i){return parseInt(i.label)}export{q as default};
1
+ import{c as F,j as a,bV as k,bW as _,bX as w,bY as A,bZ as W,b_ as X}from"./app.js";const z=i=>{const e=F.c(44),{pagination:t,pageChange:n,currentPage:s}=i,D=t.links.filter(Y).map(Z),I=D.includes(1),L=D.includes(t.last_page),y=`${I?"opacity-50 pointer-events-none":"opacity-100"}`,j=`px-6 cursor-pointer bg-secondary hover:bg-muted-foreground/15 ${s===1?"opacity-50 pointer-events-none":""}`;let o;e[0]!==s||e[1]!==n?(o=r=>{r.preventDefault(),s!==1&&n(1)},e[0]=s,e[1]=n,e[2]=o):o=e[2];let l;e[3]!==j||e[4]!==o?(l=a.jsx(k,{className:j,onClick:o,children:"First"}),e[3]=j,e[4]=o,e[5]=l):l=e[5];let c;e[6]!==y||e[7]!==l?(c=a.jsx(_,{className:y,children:l}),e[6]=y,e[7]=l,e[8]=c):c=e[8];const P=`cursor-pointer bg-secondary hover:bg-muted-foreground/15 ${t.prev_page_url?"":"opacity-50 pointer-events-none"}`;let p;e[9]!==s||e[10]!==n||e[11]!==t.prev_page_url?(p=r=>{r.preventDefault(),t.prev_page_url&&n(s-1)},e[9]=s,e[10]=n,e[11]=t.prev_page_url,e[12]=p):p=e[12];let u;e[13]!==P||e[14]!==p?(u=a.jsx(_,{children:a.jsx(w,{className:P,onClick:p})}),e[13]=P,e[14]=p,e[15]=u):u=e[15];let g;if(e[16]!==n||e[17]!==t.links){let r;e[19]!==n?(r=(v,R)=>v.label==="Previous"||v.label==="Next"?null:a.jsx(_,{children:a.jsx(k,{className:`cursor-pointer bg-secondary hover:bg-muted-foreground/15 ${v.active?"!bg-primary dark:!bg-muted-foreground !text-primary-foreground dark:!text-ring":""}`,onClick:V=>{V.preventDefault();const E=parseInt(v.label);n(E)},isActive:v.active,children:v.label})},R),e[19]=n,e[20]=r):r=e[20],g=t.links.map(r),e[16]=n,e[17]=t.links,e[18]=g}else g=e[18];const N=`cursor-pointer bg-secondary hover:bg-muted-foreground/15 ${t.next_page_url?"":"opacity-50 pointer-events-none"}`;let f;e[21]!==s||e[22]!==n||e[23]!==t.next_page_url?(f=r=>{r.preventDefault(),t.next_page_url&&n(s+1)},e[21]=s,e[22]=n,e[23]=t.next_page_url,e[24]=f):f=e[24];let d;e[25]!==N||e[26]!==f?(d=a.jsx(_,{children:a.jsx(A,{className:N,onClick:f})}),e[25]=N,e[26]=f,e[27]=d):d=e[27];const $=`${L?"opacity-50 pointer-events-none":"opacity-100"}`,C=`px-6 cursor-pointer bg-secondary hover:bg-muted-foreground/15 ${s===t.last_page?"opacity-50 pointer-events-none":""}`;let b;e[28]!==s||e[29]!==n||e[30]!==t.last_page?(b=r=>{r.preventDefault(),s!==t.last_page&&n(t.last_page)},e[28]=s,e[29]=n,e[30]=t.last_page,e[31]=b):b=e[31];let m;e[32]!==C||e[33]!==b?(m=a.jsx(k,{className:C,onClick:b,children:"Last"}),e[32]=C,e[33]=b,e[34]=m):m=e[34];let x;e[35]!==$||e[36]!==m?(x=a.jsx(_,{className:$,children:m}),e[35]=$,e[36]=m,e[37]=x):x=e[37];let h;return e[38]!==d||e[39]!==x||e[40]!==c||e[41]!==u||e[42]!==g?(h=a.jsx(W,{children:a.jsxs(X,{className:"flex-wrap",children:[c,u,g,d,x]})}),e[38]=d,e[39]=x,e[40]=c,e[41]=u,e[42]=g,e[43]=h):h=e[43],h};function Y(i){return i.label!=="Previous"&&i.label!=="Next"}function Z(i){return parseInt(i.label)}export{z as default};
@@ -1 +1 @@
1
- import{c as Pe,q as _e,r as ye,a1 as Se,j as l,a as W,I as X,S as ke,b as Ce,B as Le,$ as Ee,T as Te,i as Ie,f as $e,k as qe,t as Be}from"./app.js";import Y from"./input-error-g1h6ps7t.js";import{i as Fe}from"./use-appearance-CXP5cHaQ.js";function Ae(){const e=Pe.c(151),s=_e();let Z;e[0]===Symbol.for("react.memo_cache_sentinel")?(Z=[],e[0]=Z):Z=e[0],ye.useEffect(Ve,Z);let ee;e[1]===Symbol.for("react.memo_cache_sentinel")?(ee={locale:"en",email:"",confirmPassword:"",password:"",fullName:"",login:""},e[1]=ee):ee=e[1];const{post:de,data:r,setData:me,processing:a,setError:fe,errors:t,clearErrors:ue}=Se(ee);let se;e[2]!==r.confirmPassword||e[3]!==r.password||e[4]!==s.props.confirmError||e[5]!==s.props.submitLink||e[6]!==de||e[7]!==fe?(se=i=>{if(i.preventDefault(),r.password!==r.confirmPassword){fe("confirmPassword",s.props.confirmError);return}de(s.props.submitLink,{onSuccess:Re,onError:De})},e[2]=r.confirmPassword,e[3]=r.password,e[4]=s.props.confirmError,e[5]=s.props.submitLink,e[6]=de,e[7]=fe,e[8]=se):se=e[8];const be=se;let le;e[9]!==ue||e[10]!==me?(le=(i,ve)=>{ue(),me(i,ve)},e[9]=ue,e[10]=me,e[11]=le):le=e[11];const o=le;let ae;e[12]===Symbol.for("react.memo_cache_sentinel")?(ae=l.jsx(Te,{position:"top-center",richColors:!0,closeButton:!0}),e[12]=ae):ae=e[12];let n;e[13]!==s.props.header.title?(n=l.jsx("h1",{className:"font-medium mb-2 text-xl",children:s.props.header.title}),e[13]=s.props.header.title,e[14]=n):n=e[14];let p;e[15]!==s.props.header.desc?(p=l.jsx("p",{className:"text-muted-foreground text-sm",children:s.props.header.desc}),e[15]=s.props.header.desc,e[16]=p):p=e[16];let re;e[17]===Symbol.for("react.memo_cache_sentinel")?(re=l.jsx("span",{className:"text-red-500",children:"*"}),e[17]=re):re=e[17];let c;e[18]!==s.props.loginLabel?(c=l.jsxs(W,{htmlFor:"login",children:[s.props.loginLabel,re]}),e[18]=s.props.loginLabel,e[19]=c):c=e[19];const he=`${t.login?"border-red-500":""}`;let d;e[20]!==o?(d=i=>{o("login",i.target.value)},e[20]=o,e[21]=d):d=e[21];let m;e[22]!==r.login||e[23]!==s.props.loginLabel||e[24]!==a||e[25]!==d||e[26]!==he?(m=l.jsx(X,{id:"login",className:he,type:"text",required:!0,tabIndex:1,autoComplete:"username",value:r.login,disabled:a,onChange:d,placeholder:s.props.loginLabel}),e[22]=r.login,e[23]=s.props.loginLabel,e[24]=a,e[25]=d,e[26]=he,e[27]=m):m=e[27];let f;e[28]!==t.login?(f=l.jsx(Y,{message:t.login}),e[28]=t.login,e[29]=f):f=e[29];let u;e[30]!==m||e[31]!==f?(u=l.jsxs("div",{className:"relative",children:[m,f]}),e[30]=m,e[31]=f,e[32]=u):u=e[32];let b;e[33]!==u||e[34]!==c?(b=l.jsxs("div",{className:"grid gap-4",children:[c,u]}),e[33]=u,e[34]=c,e[35]=b):b=e[35];let te;e[36]===Symbol.for("react.memo_cache_sentinel")?(te=l.jsx("span",{className:"text-red-500",children:"*"}),e[36]=te):te=e[36];let h;e[37]!==s.props.fullNameLabel?(h=l.jsxs(W,{htmlFor:"fullName",children:[s.props.fullNameLabel,te]}),e[37]=s.props.fullNameLabel,e[38]=h):h=e[38];const xe=`${t.fullName?"border-red-500":""}`;let x;e[39]!==o?(x=i=>{o("fullName",i.target.value)},e[39]=o,e[40]=x):x=e[40];let g;e[41]!==r.fullName||e[42]!==s.props.fullNameLabel||e[43]!==a||e[44]!==xe||e[45]!==x?(g=l.jsx(X,{id:"fullName",className:xe,type:"text",required:!0,tabIndex:1,autoComplete:"fullName",value:r.fullName,disabled:a,onChange:x,placeholder:s.props.fullNameLabel}),e[41]=r.fullName,e[42]=s.props.fullNameLabel,e[43]=a,e[44]=xe,e[45]=x,e[46]=g):g=e[46];let w;e[47]!==t.fullName?(w=l.jsx(Y,{message:t.fullName}),e[47]=t.fullName,e[48]=w):w=e[48];let j;e[49]!==g||e[50]!==w?(j=l.jsxs("div",{className:"relative",children:[g,w]}),e[49]=g,e[50]=w,e[51]=j):j=e[51];let N;e[52]!==h||e[53]!==j?(N=l.jsxs("div",{className:"grid gap-4",children:[h,j]}),e[52]=h,e[53]=j,e[54]=N):N=e[54];let oe;e[55]===Symbol.for("react.memo_cache_sentinel")?(oe=l.jsx("span",{className:"text-red-500",children:"*"}),e[55]=oe):oe=e[55];let L;e[56]!==s.props.passwordLabel?(L=l.jsxs(W,{htmlFor:"password",children:[s.props.passwordLabel,oe]}),e[56]=s.props.passwordLabel,e[57]=L):L=e[57];const ge=`${t.password?"border-red-500":""}`;let v;e[58]!==o?(v=i=>{o("password",i.target.value)},e[58]=o,e[59]=v):v=e[59];let P;e[60]!==r.password||e[61]!==s.props.passwordLabel||e[62]!==a||e[63]!==ge||e[64]!==v?(P=l.jsx(X,{id:"password",className:ge,type:"password",required:!0,tabIndex:1,autoComplete:"new-password",value:r.password,disabled:a,onChange:v,placeholder:s.props.passwordLabel}),e[60]=r.password,e[61]=s.props.passwordLabel,e[62]=a,e[63]=ge,e[64]=v,e[65]=P):P=e[65];let _;e[66]!==t.password?(_=l.jsx(Y,{message:t.password}),e[66]=t.password,e[67]=_):_=e[67];let y;e[68]!==P||e[69]!==_?(y=l.jsxs("div",{className:"relative",children:[P,_]}),e[68]=P,e[69]=_,e[70]=y):y=e[70];let S;e[71]!==L||e[72]!==y?(S=l.jsxs("div",{className:"grid gap-4",children:[L,y]}),e[71]=L,e[72]=y,e[73]=S):S=e[73];let ie;e[74]===Symbol.for("react.memo_cache_sentinel")?(ie=l.jsx("span",{className:"text-red-500",children:"*"}),e[74]=ie):ie=e[74];let k;e[75]!==s.props.confirmPasswordLabel?(k=l.jsxs(W,{htmlFor:"confirmPassword",children:[s.props.confirmPasswordLabel,ie]}),e[75]=s.props.confirmPasswordLabel,e[76]=k):k=e[76];const we=`${t.confirmPassword?"border-red-500":""}`;let C;e[77]!==o?(C=i=>{o("confirmPassword",i.target.value)},e[77]=o,e[78]=C):C=e[78];let E;e[79]!==r.confirmPassword||e[80]!==s.props.confirmPasswordLabel||e[81]!==a||e[82]!==we||e[83]!==C?(E=l.jsx(X,{id:"confirmPassword",className:we,type:"password",required:!0,tabIndex:1,autoComplete:"new-password",value:r.confirmPassword,disabled:a,onChange:C,placeholder:s.props.confirmPasswordLabel}),e[79]=r.confirmPassword,e[80]=s.props.confirmPasswordLabel,e[81]=a,e[82]=we,e[83]=C,e[84]=E):E=e[84];let T;e[85]!==t.confirmPassword?(T=l.jsx(Y,{message:t.confirmPassword}),e[85]=t.confirmPassword,e[86]=T):T=e[86];let I;e[87]!==E||e[88]!==T?(I=l.jsxs("div",{className:"relative",children:[E,T]}),e[87]=E,e[88]=T,e[89]=I):I=e[89];let $;e[90]!==k||e[91]!==I?($=l.jsxs("div",{className:"grid gap-4",children:[k,I]}),e[90]=k,e[91]=I,e[92]=$):$=e[92];let ne;e[93]===Symbol.for("react.memo_cache_sentinel")?(ne=l.jsx("span",{className:"text-red-500",children:"*"}),e[93]=ne):ne=e[93];let q;e[94]!==s.props.emailLabel?(q=l.jsxs(W,{htmlFor:"email",children:[s.props.emailLabel,ne]}),e[94]=s.props.emailLabel,e[95]=q):q=e[95];const je=`${t.email?"border-red-500":""}`;let B;e[96]!==o?(B=i=>{o("email",i.target.value)},e[96]=o,e[97]=B):B=e[97];let F;e[98]!==r.email||e[99]!==s.props.emailLabel||e[100]!==a||e[101]!==je||e[102]!==B?(F=l.jsx(X,{id:"email",className:je,type:"email",required:!0,tabIndex:1,autoComplete:"email",value:r.email,disabled:a,onChange:B,placeholder:s.props.emailLabel}),e[98]=r.email,e[99]=s.props.emailLabel,e[100]=a,e[101]=je,e[102]=B,e[103]=F):F=e[103];let D;e[104]!==t.email?(D=l.jsx(Y,{message:t.email}),e[104]=t.email,e[105]=D):D=e[105];let R;e[106]!==F||e[107]!==D?(R=l.jsxs("div",{className:"relative",children:[F,D]}),e[106]=F,e[107]=D,e[108]=R):R=e[108];let V;e[109]!==q||e[110]!==R?(V=l.jsxs("div",{className:"grid gap-4",children:[q,R]}),e[109]=q,e[110]=R,e[111]=V):V=e[111];let z;e[112]!==s.props.localeLabel?(z=l.jsx(W,{htmlFor:"locale",children:s.props.localeLabel}),e[112]=s.props.localeLabel,e[113]=z):z=e[113];let J;e[114]!==o?(J=i=>o("locale",i),e[114]=o,e[115]=J):J=e[115];let O;e[116]!==s.props.localeLabel?(O=l.jsx(ke,{className:"w-full cursor-pointer",children:l.jsx(Ce,{placeholder:s.props.localeLabel})}),e[116]=s.props.localeLabel,e[117]=O):O=e[117];let pe;e[118]===Symbol.for("react.memo_cache_sentinel")?(pe=l.jsx(Ie,{children:l.jsx($e,{value:"en",children:"EN"})}),e[118]=pe):pe=e[118];let A;e[119]!==a||e[120]!==J||e[121]!==O?(A=l.jsxs(qe,{onValueChange:J,defaultValue:"en",disabled:a,children:[O,pe]}),e[119]=a,e[120]=J,e[121]=O,e[122]=A):A=e[122];let G;e[123]!==z||e[124]!==A?(G=l.jsxs("div",{className:"grid gap-4",children:[z,A]}),e[123]=z,e[124]=A,e[125]=G):G=e[125];let H;e[126]!==s.props.submitButton||e[127]!==a?(H=l.jsx(Le,{type:"submit",className:"w-fit",disabled:a,children:s.props.submitButton}),e[126]=s.props.submitButton,e[127]=a,e[128]=H):H=e[128];const Ne=`${a} ? 'pointer-events-none opacity-50' : ''`;let K;e[129]!==s.props.backToLogin.link||e[130]!==s.props.backToLogin.text||e[131]!==Ne?(K=l.jsx(Le,{asChild:!0,variant:"outline",children:l.jsx(Ee,{href:s.props.backToLogin.link,className:Ne,children:s.props.backToLogin.text})}),e[129]=s.props.backToLogin.link,e[130]=s.props.backToLogin.text,e[131]=Ne,e[132]=K):K=e[132];let M;e[133]!==H||e[134]!==K?(M=l.jsxs("div",{className:"flex gap-4",children:[H,K]}),e[133]=H,e[134]=K,e[135]=M):M=e[135];let Q;e[136]!==b||e[137]!==N||e[138]!==S||e[139]!==$||e[140]!==V||e[141]!==G||e[142]!==M?(Q=l.jsxs("div",{className:"grid gap-5",children:[b,N,S,$,V,G,M]}),e[136]=b,e[137]=N,e[138]=S,e[139]=$,e[140]=V,e[141]=G,e[142]=M,e[143]=Q):Q=e[143];let U;e[144]!==be||e[145]!==Q?(U=l.jsx("form",{onSubmit:be,className:"mt-6",children:Q}),e[144]=be,e[145]=Q,e[146]=U):U=e[146];let ce;return e[147]!==n||e[148]!==U||e[149]!==p?(ce=l.jsxs("div",{className:"bg-sidebar flex min-h-svh w-full justify-center items-center",children:[ae,l.jsxs("div",{className:"rounded-xl border bg-card text-card-foreground shadow p-6 max-w-sm w-full h-fit",children:[n,p,U]})]}),e[147]=n,e[148]=U,e[149]=p,e[150]=ce):ce=e[150],ce}function De(e){for(const s of Object.keys(e))Be.error(e[s])}function Re(){}function Ve(){Fe()}export{Ae as default};
1
+ import{c as Pe,q as _e,r as ye,a1 as Se,j as l,a as W,I as X,S as ke,b as Ce,B as Le,$ as Ee,T as Te,i as Ie,f as $e,k as qe,t as Be}from"./app.js";import Y from"./input-error-BBzQCTcg.js";import{i as Fe}from"./use-appearance-CXP5cHaQ.js";function Ae(){const e=Pe.c(151),s=_e();let Z;e[0]===Symbol.for("react.memo_cache_sentinel")?(Z=[],e[0]=Z):Z=e[0],ye.useEffect(Ve,Z);let ee;e[1]===Symbol.for("react.memo_cache_sentinel")?(ee={locale:"en",email:"",confirmPassword:"",password:"",fullName:"",login:""},e[1]=ee):ee=e[1];const{post:de,data:r,setData:me,processing:a,setError:fe,errors:t,clearErrors:ue}=Se(ee);let se;e[2]!==r.confirmPassword||e[3]!==r.password||e[4]!==s.props.confirmError||e[5]!==s.props.submitLink||e[6]!==de||e[7]!==fe?(se=i=>{if(i.preventDefault(),r.password!==r.confirmPassword){fe("confirmPassword",s.props.confirmError);return}de(s.props.submitLink,{onSuccess:Re,onError:De})},e[2]=r.confirmPassword,e[3]=r.password,e[4]=s.props.confirmError,e[5]=s.props.submitLink,e[6]=de,e[7]=fe,e[8]=se):se=e[8];const be=se;let le;e[9]!==ue||e[10]!==me?(le=(i,ve)=>{ue(),me(i,ve)},e[9]=ue,e[10]=me,e[11]=le):le=e[11];const o=le;let ae;e[12]===Symbol.for("react.memo_cache_sentinel")?(ae=l.jsx(Te,{position:"top-center",richColors:!0,closeButton:!0}),e[12]=ae):ae=e[12];let n;e[13]!==s.props.header.title?(n=l.jsx("h1",{className:"font-medium mb-2 text-xl",children:s.props.header.title}),e[13]=s.props.header.title,e[14]=n):n=e[14];let p;e[15]!==s.props.header.desc?(p=l.jsx("p",{className:"text-muted-foreground text-sm",children:s.props.header.desc}),e[15]=s.props.header.desc,e[16]=p):p=e[16];let re;e[17]===Symbol.for("react.memo_cache_sentinel")?(re=l.jsx("span",{className:"text-red-500",children:"*"}),e[17]=re):re=e[17];let c;e[18]!==s.props.loginLabel?(c=l.jsxs(W,{htmlFor:"login",children:[s.props.loginLabel,re]}),e[18]=s.props.loginLabel,e[19]=c):c=e[19];const he=`${t.login?"border-red-500":""}`;let d;e[20]!==o?(d=i=>{o("login",i.target.value)},e[20]=o,e[21]=d):d=e[21];let m;e[22]!==r.login||e[23]!==s.props.loginLabel||e[24]!==a||e[25]!==d||e[26]!==he?(m=l.jsx(X,{id:"login",className:he,type:"text",required:!0,tabIndex:1,autoComplete:"username",value:r.login,disabled:a,onChange:d,placeholder:s.props.loginLabel}),e[22]=r.login,e[23]=s.props.loginLabel,e[24]=a,e[25]=d,e[26]=he,e[27]=m):m=e[27];let f;e[28]!==t.login?(f=l.jsx(Y,{message:t.login}),e[28]=t.login,e[29]=f):f=e[29];let u;e[30]!==m||e[31]!==f?(u=l.jsxs("div",{className:"relative",children:[m,f]}),e[30]=m,e[31]=f,e[32]=u):u=e[32];let b;e[33]!==u||e[34]!==c?(b=l.jsxs("div",{className:"grid gap-4",children:[c,u]}),e[33]=u,e[34]=c,e[35]=b):b=e[35];let te;e[36]===Symbol.for("react.memo_cache_sentinel")?(te=l.jsx("span",{className:"text-red-500",children:"*"}),e[36]=te):te=e[36];let h;e[37]!==s.props.fullNameLabel?(h=l.jsxs(W,{htmlFor:"fullName",children:[s.props.fullNameLabel,te]}),e[37]=s.props.fullNameLabel,e[38]=h):h=e[38];const xe=`${t.fullName?"border-red-500":""}`;let x;e[39]!==o?(x=i=>{o("fullName",i.target.value)},e[39]=o,e[40]=x):x=e[40];let g;e[41]!==r.fullName||e[42]!==s.props.fullNameLabel||e[43]!==a||e[44]!==xe||e[45]!==x?(g=l.jsx(X,{id:"fullName",className:xe,type:"text",required:!0,tabIndex:1,autoComplete:"fullName",value:r.fullName,disabled:a,onChange:x,placeholder:s.props.fullNameLabel}),e[41]=r.fullName,e[42]=s.props.fullNameLabel,e[43]=a,e[44]=xe,e[45]=x,e[46]=g):g=e[46];let w;e[47]!==t.fullName?(w=l.jsx(Y,{message:t.fullName}),e[47]=t.fullName,e[48]=w):w=e[48];let j;e[49]!==g||e[50]!==w?(j=l.jsxs("div",{className:"relative",children:[g,w]}),e[49]=g,e[50]=w,e[51]=j):j=e[51];let N;e[52]!==h||e[53]!==j?(N=l.jsxs("div",{className:"grid gap-4",children:[h,j]}),e[52]=h,e[53]=j,e[54]=N):N=e[54];let oe;e[55]===Symbol.for("react.memo_cache_sentinel")?(oe=l.jsx("span",{className:"text-red-500",children:"*"}),e[55]=oe):oe=e[55];let L;e[56]!==s.props.passwordLabel?(L=l.jsxs(W,{htmlFor:"password",children:[s.props.passwordLabel,oe]}),e[56]=s.props.passwordLabel,e[57]=L):L=e[57];const ge=`${t.password?"border-red-500":""}`;let v;e[58]!==o?(v=i=>{o("password",i.target.value)},e[58]=o,e[59]=v):v=e[59];let P;e[60]!==r.password||e[61]!==s.props.passwordLabel||e[62]!==a||e[63]!==ge||e[64]!==v?(P=l.jsx(X,{id:"password",className:ge,type:"password",required:!0,tabIndex:1,autoComplete:"new-password",value:r.password,disabled:a,onChange:v,placeholder:s.props.passwordLabel}),e[60]=r.password,e[61]=s.props.passwordLabel,e[62]=a,e[63]=ge,e[64]=v,e[65]=P):P=e[65];let _;e[66]!==t.password?(_=l.jsx(Y,{message:t.password}),e[66]=t.password,e[67]=_):_=e[67];let y;e[68]!==P||e[69]!==_?(y=l.jsxs("div",{className:"relative",children:[P,_]}),e[68]=P,e[69]=_,e[70]=y):y=e[70];let S;e[71]!==L||e[72]!==y?(S=l.jsxs("div",{className:"grid gap-4",children:[L,y]}),e[71]=L,e[72]=y,e[73]=S):S=e[73];let ie;e[74]===Symbol.for("react.memo_cache_sentinel")?(ie=l.jsx("span",{className:"text-red-500",children:"*"}),e[74]=ie):ie=e[74];let k;e[75]!==s.props.confirmPasswordLabel?(k=l.jsxs(W,{htmlFor:"confirmPassword",children:[s.props.confirmPasswordLabel,ie]}),e[75]=s.props.confirmPasswordLabel,e[76]=k):k=e[76];const we=`${t.confirmPassword?"border-red-500":""}`;let C;e[77]!==o?(C=i=>{o("confirmPassword",i.target.value)},e[77]=o,e[78]=C):C=e[78];let E;e[79]!==r.confirmPassword||e[80]!==s.props.confirmPasswordLabel||e[81]!==a||e[82]!==we||e[83]!==C?(E=l.jsx(X,{id:"confirmPassword",className:we,type:"password",required:!0,tabIndex:1,autoComplete:"new-password",value:r.confirmPassword,disabled:a,onChange:C,placeholder:s.props.confirmPasswordLabel}),e[79]=r.confirmPassword,e[80]=s.props.confirmPasswordLabel,e[81]=a,e[82]=we,e[83]=C,e[84]=E):E=e[84];let T;e[85]!==t.confirmPassword?(T=l.jsx(Y,{message:t.confirmPassword}),e[85]=t.confirmPassword,e[86]=T):T=e[86];let I;e[87]!==E||e[88]!==T?(I=l.jsxs("div",{className:"relative",children:[E,T]}),e[87]=E,e[88]=T,e[89]=I):I=e[89];let $;e[90]!==k||e[91]!==I?($=l.jsxs("div",{className:"grid gap-4",children:[k,I]}),e[90]=k,e[91]=I,e[92]=$):$=e[92];let ne;e[93]===Symbol.for("react.memo_cache_sentinel")?(ne=l.jsx("span",{className:"text-red-500",children:"*"}),e[93]=ne):ne=e[93];let q;e[94]!==s.props.emailLabel?(q=l.jsxs(W,{htmlFor:"email",children:[s.props.emailLabel,ne]}),e[94]=s.props.emailLabel,e[95]=q):q=e[95];const je=`${t.email?"border-red-500":""}`;let B;e[96]!==o?(B=i=>{o("email",i.target.value)},e[96]=o,e[97]=B):B=e[97];let F;e[98]!==r.email||e[99]!==s.props.emailLabel||e[100]!==a||e[101]!==je||e[102]!==B?(F=l.jsx(X,{id:"email",className:je,type:"email",required:!0,tabIndex:1,autoComplete:"email",value:r.email,disabled:a,onChange:B,placeholder:s.props.emailLabel}),e[98]=r.email,e[99]=s.props.emailLabel,e[100]=a,e[101]=je,e[102]=B,e[103]=F):F=e[103];let D;e[104]!==t.email?(D=l.jsx(Y,{message:t.email}),e[104]=t.email,e[105]=D):D=e[105];let R;e[106]!==F||e[107]!==D?(R=l.jsxs("div",{className:"relative",children:[F,D]}),e[106]=F,e[107]=D,e[108]=R):R=e[108];let V;e[109]!==q||e[110]!==R?(V=l.jsxs("div",{className:"grid gap-4",children:[q,R]}),e[109]=q,e[110]=R,e[111]=V):V=e[111];let z;e[112]!==s.props.localeLabel?(z=l.jsx(W,{htmlFor:"locale",children:s.props.localeLabel}),e[112]=s.props.localeLabel,e[113]=z):z=e[113];let J;e[114]!==o?(J=i=>o("locale",i),e[114]=o,e[115]=J):J=e[115];let O;e[116]!==s.props.localeLabel?(O=l.jsx(ke,{className:"w-full cursor-pointer",children:l.jsx(Ce,{placeholder:s.props.localeLabel})}),e[116]=s.props.localeLabel,e[117]=O):O=e[117];let pe;e[118]===Symbol.for("react.memo_cache_sentinel")?(pe=l.jsx(Ie,{children:l.jsx($e,{value:"en",children:"EN"})}),e[118]=pe):pe=e[118];let A;e[119]!==a||e[120]!==J||e[121]!==O?(A=l.jsxs(qe,{onValueChange:J,defaultValue:"en",disabled:a,children:[O,pe]}),e[119]=a,e[120]=J,e[121]=O,e[122]=A):A=e[122];let G;e[123]!==z||e[124]!==A?(G=l.jsxs("div",{className:"grid gap-4",children:[z,A]}),e[123]=z,e[124]=A,e[125]=G):G=e[125];let H;e[126]!==s.props.submitButton||e[127]!==a?(H=l.jsx(Le,{type:"submit",className:"w-fit",disabled:a,children:s.props.submitButton}),e[126]=s.props.submitButton,e[127]=a,e[128]=H):H=e[128];const Ne=`${a} ? 'pointer-events-none opacity-50' : ''`;let K;e[129]!==s.props.backToLogin.link||e[130]!==s.props.backToLogin.text||e[131]!==Ne?(K=l.jsx(Le,{asChild:!0,variant:"outline",children:l.jsx(Ee,{href:s.props.backToLogin.link,className:Ne,children:s.props.backToLogin.text})}),e[129]=s.props.backToLogin.link,e[130]=s.props.backToLogin.text,e[131]=Ne,e[132]=K):K=e[132];let M;e[133]!==H||e[134]!==K?(M=l.jsxs("div",{className:"flex gap-4",children:[H,K]}),e[133]=H,e[134]=K,e[135]=M):M=e[135];let Q;e[136]!==b||e[137]!==N||e[138]!==S||e[139]!==$||e[140]!==V||e[141]!==G||e[142]!==M?(Q=l.jsxs("div",{className:"grid gap-5",children:[b,N,S,$,V,G,M]}),e[136]=b,e[137]=N,e[138]=S,e[139]=$,e[140]=V,e[141]=G,e[142]=M,e[143]=Q):Q=e[143];let U;e[144]!==be||e[145]!==Q?(U=l.jsx("form",{onSubmit:be,className:"mt-6",children:Q}),e[144]=be,e[145]=Q,e[146]=U):U=e[146];let ce;return e[147]!==n||e[148]!==U||e[149]!==p?(ce=l.jsxs("div",{className:"bg-sidebar flex min-h-svh w-full justify-center items-center",children:[ae,l.jsxs("div",{className:"rounded-xl border bg-card text-card-foreground shadow p-6 max-w-sm w-full h-fit",children:[n,p,U]})]}),e[147]=n,e[148]=U,e[149]=p,e[150]=ce):ce=e[150],ce}function De(e){for(const s of Object.keys(e))Be.error(e[s])}function Re(){}function Ve(){Fe()}export{Ae as default};
@@ -1 +1 @@
1
- import{r as a,j as d,ax as fe,ay as $,e as S,az as L,aA as B,aB as R,aC as U,aD as z,aE as pe,aF as me,c as P,ae as j}from"./app.js";function k(t){const e=ve(t),n=a.forwardRef((o,r)=>{const{children:s,...i}=o,l=a.Children.toArray(s),v=l.find(ge);if(v){const p=v.props.children,c=l.map(f=>f===v?a.Children.count(p)>1?a.Children.only(null):a.isValidElement(p)?p.props.children:null:f);return d.jsx(e,{...i,ref:r,children:a.isValidElement(p)?a.cloneElement(p,void 0,c):null})}return d.jsx(e,{...i,ref:r,children:s})});return n.displayName=`${t}.Slot`,n}function ve(t){const e=a.forwardRef((n,o)=>{const{children:r,...s}=n;if(a.isValidElement(r)){const i=xe(r),l=Ie(s,r.props);return r.type!==a.Fragment&&(l.ref=o?fe(o,i):i),a.cloneElement(r,l)}return a.Children.count(r)>1?a.Children.only(null):null});return e.displayName=`${t}.SlotClone`,e}var be=Symbol("radix.slottable");function ge(t){return a.isValidElement(t)&&typeof t.type=="function"&&"__radixId"in t.type&&t.type.__radixId===be}function Ie(t,e){const n={...e};for(const o in e){const r=t[o],s=e[o];/^on[A-Z]/.test(o)?r&&s?n[o]=(...l)=>{const v=s(...l);return r(...l),v}:r&&(n[o]=r):o==="style"?n[o]={...r,...s}:o==="className"&&(n[o]=[r,s].filter(Boolean).join(" "))}return{...t,...n}}function xe(t){var o,r;let e=(o=Object.getOwnPropertyDescriptor(t.props,"ref"))==null?void 0:o.get,n=e&&"isReactWarning"in e&&e.isReactWarning;return n?t.ref:(e=(r=Object.getOwnPropertyDescriptor(t,"ref"))==null?void 0:r.get,n=e&&"isReactWarning"in e&&e.isReactWarning,n?t.props.ref:t.props.ref||t.ref)}function Ce(t){const e=t+"CollectionProvider",[n,o]=$(e),[r,s]=n(e,{collectionRef:{current:null},itemMap:new Map}),i=C=>{const{scope:u,children:g}=C,T=S.useRef(null),m=S.useRef(new Map).current;return d.jsx(r,{scope:u,itemMap:m,collectionRef:T,children:g})};i.displayName=e;const l=t+"CollectionSlot",v=k(l),p=S.forwardRef((C,u)=>{const{scope:g,children:T}=C,m=s(l,g),b=L(u,m.collectionRef);return d.jsx(v,{ref:b,children:T})});p.displayName=l;const c=t+"CollectionItemSlot",f="data-radix-collection-item",I=k(c),y=S.forwardRef((C,u)=>{const{scope:g,children:T,...m}=C,b=S.useRef(null),w=L(u,b),F=s(c,g);return S.useEffect(()=>(F.itemMap.set(b,{ref:b,...m}),()=>void F.itemMap.delete(b))),d.jsx(I,{[f]:"",ref:w,children:T})});y.displayName=c;function h(C){const u=s(t+"CollectionConsumer",C);return S.useCallback(()=>{const T=u.collectionRef.current;if(!T)return[];const m=Array.from(T.querySelectorAll(`[${f}]`));return Array.from(u.itemMap.values()).sort((F,A)=>m.indexOf(F.ref.current)-m.indexOf(A.ref.current))},[u.collectionRef,u.itemMap])}return[{Provider:i,Slot:p,ItemSlot:y},h,o]}var Te=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","select","span","svg","ul"],_=Te.reduce((t,e)=>{const n=k(`Primitive.${e}`),o=a.forwardRef((r,s)=>{const{asChild:i,...l}=r,v=i?n:e;return typeof window<"u"&&(window[Symbol.for("radix-ui")]=!0),d.jsx(v,{...l,ref:s})});return o.displayName=`Primitive.${e}`,{...t,[e]:o}},{}),O="rovingFocusGroup.onEntryFocus",Re={bubbles:!1,cancelable:!0},N="RovingFocusGroup",[G,W,ye]=Ce(N),[Ee,H]=$(N,[ye]),[Se,he]=Ee(N),Y=a.forwardRef((t,e)=>d.jsx(G.Provider,{scope:t.__scopeRovingFocusGroup,children:d.jsx(G.Slot,{scope:t.__scopeRovingFocusGroup,children:d.jsx(we,{...t,ref:e})})}));Y.displayName=N;var we=a.forwardRef((t,e)=>{const{__scopeRovingFocusGroup:n,orientation:o,loop:r=!1,dir:s,currentTabStopId:i,defaultCurrentTabStopId:l,onCurrentTabStopIdChange:v,onEntryFocus:p,preventScrollOnEntryFocus:c=!1,...f}=t,I=a.useRef(null),y=L(e,I),h=U(s),[C,u]=z({prop:i,defaultProp:l??null,onChange:v,caller:N}),[g,T]=a.useState(!1),m=pe(p),b=W(n),w=a.useRef(!1),[F,A]=a.useState(0);return a.useEffect(()=>{const x=I.current;if(x)return x.addEventListener(O,m),()=>x.removeEventListener(O,m)},[m]),d.jsx(Se,{scope:n,orientation:o,dir:h,loop:r,currentTabStopId:C,onItemFocus:a.useCallback(x=>u(x),[u]),onItemShiftTab:a.useCallback(()=>T(!0),[]),onFocusableItemAdd:a.useCallback(()=>A(x=>x+1),[]),onFocusableItemRemove:a.useCallback(()=>A(x=>x-1),[]),children:d.jsx(_.div,{tabIndex:g||F===0?-1:0,"data-orientation":o,...f,ref:y,style:{outline:"none",...t.style},onMouseDown:R(t.onMouseDown,()=>{w.current=!0}),onFocus:R(t.onFocus,x=>{const ce=!w.current;if(x.target===x.currentTarget&&ce&&!g){const K=new CustomEvent(O,Re);if(x.currentTarget.dispatchEvent(K),!K.defaultPrevented){const D=b().filter(E=>E.focusable),le=D.find(E=>E.active),ue=D.find(E=>E.id===C),de=[le,ue,...D].filter(Boolean).map(E=>E.ref.current);J(de,c)}}w.current=!1}),onBlur:R(t.onBlur,()=>T(!1))})})}),q="RovingFocusGroupItem",Z=a.forwardRef((t,e)=>{const{__scopeRovingFocusGroup:n,focusable:o=!0,active:r=!1,tabStopId:s,children:i,...l}=t,v=B(),p=s||v,c=he(q,n),f=c.currentTabStopId===p,I=W(n),{onFocusableItemAdd:y,onFocusableItemRemove:h,currentTabStopId:C}=c;return a.useEffect(()=>{if(o)return y(),()=>h()},[o,y,h]),d.jsx(G.ItemSlot,{scope:n,id:p,focusable:o,active:r,children:d.jsx(_.span,{tabIndex:f?0:-1,"data-orientation":c.orientation,...l,ref:e,onMouseDown:R(t.onMouseDown,u=>{o?c.onItemFocus(p):u.preventDefault()}),onFocus:R(t.onFocus,()=>c.onItemFocus(p)),onKeyDown:R(t.onKeyDown,u=>{if(u.key==="Tab"&&u.shiftKey){c.onItemShiftTab();return}if(u.target!==u.currentTarget)return;const g=Ne(u,c.orientation,c.dir);if(g!==void 0){if(u.metaKey||u.ctrlKey||u.altKey||u.shiftKey)return;u.preventDefault();let m=I().filter(b=>b.focusable).map(b=>b.ref.current);if(g==="last")m.reverse();else if(g==="prev"||g==="next"){g==="prev"&&m.reverse();const b=m.indexOf(u.currentTarget);m=c.loop?Ae(m,b+1):m.slice(b+1)}setTimeout(()=>J(m))}}),children:typeof i=="function"?i({isCurrentTabStop:f,hasTabStop:C!=null}):i})})});Z.displayName=q;var Fe={ArrowLeft:"prev",ArrowUp:"prev",ArrowRight:"next",ArrowDown:"next",PageUp:"first",Home:"first",PageDown:"last",End:"last"};function _e(t,e){return e!=="rtl"?t:t==="ArrowLeft"?"ArrowRight":t==="ArrowRight"?"ArrowLeft":t}function Ne(t,e,n){const o=_e(t.key,n);if(!(e==="vertical"&&["ArrowLeft","ArrowRight"].includes(o))&&!(e==="horizontal"&&["ArrowUp","ArrowDown"].includes(o)))return Fe[o]}function J(t,e=!1){const n=document.activeElement;for(const o of t)if(o===n||(o.focus({preventScroll:e}),document.activeElement!==n))return}function Ae(t,e){return t.map((n,o)=>t[(e+o)%t.length])}var Pe=Y,je=Z,M="Tabs",[Me,Ke]=$(M,[H]),Q=H(),[De,V]=Me(M),X=a.forwardRef((t,e)=>{const{__scopeTabs:n,value:o,onValueChange:r,defaultValue:s,orientation:i="horizontal",dir:l,activationMode:v="automatic",...p}=t,c=U(l),[f,I]=z({prop:o,onChange:r,defaultProp:s??"",caller:M});return d.jsx(De,{scope:n,baseId:B(),value:f,onValueChange:I,orientation:i,dir:c,activationMode:v,children:d.jsx(_.div,{dir:c,"data-orientation":i,...p,ref:e})})});X.displayName=M;var ee="TabsList",te=a.forwardRef((t,e)=>{const{__scopeTabs:n,loop:o=!0,...r}=t,s=V(ee,n),i=Q(n);return d.jsx(Pe,{asChild:!0,...i,orientation:s.orientation,dir:s.dir,loop:o,children:d.jsx(_.div,{role:"tablist","aria-orientation":s.orientation,...r,ref:e})})});te.displayName=ee;var oe="TabsTrigger",ne=a.forwardRef((t,e)=>{const{__scopeTabs:n,value:o,disabled:r=!1,...s}=t,i=V(oe,n),l=Q(n),v=ae(i.baseId,o),p=ie(i.baseId,o),c=o===i.value;return d.jsx(je,{asChild:!0,...l,focusable:!r,active:c,children:d.jsx(_.button,{type:"button",role:"tab","aria-selected":c,"aria-controls":p,"data-state":c?"active":"inactive","data-disabled":r?"":void 0,disabled:r,id:v,...s,ref:e,onMouseDown:R(t.onMouseDown,f=>{!r&&f.button===0&&f.ctrlKey===!1?i.onValueChange(o):f.preventDefault()}),onKeyDown:R(t.onKeyDown,f=>{[" ","Enter"].includes(f.key)&&i.onValueChange(o)}),onFocus:R(t.onFocus,()=>{const f=i.activationMode!=="manual";!c&&!r&&f&&i.onValueChange(o)})})})});ne.displayName=oe;var re="TabsContent",se=a.forwardRef((t,e)=>{const{__scopeTabs:n,value:o,forceMount:r,children:s,...i}=t,l=V(re,n),v=ae(l.baseId,o),p=ie(l.baseId,o),c=o===l.value,f=a.useRef(c);return a.useEffect(()=>{const I=requestAnimationFrame(()=>f.current=!1);return()=>cancelAnimationFrame(I)},[]),d.jsx(me,{present:r||c,children:({present:I})=>d.jsx(_.div,{"data-state":c?"active":"inactive","data-orientation":l.orientation,role:"tabpanel","aria-labelledby":v,hidden:!I,id:p,tabIndex:0,...i,ref:e,style:{...t.style,animationDuration:f.current?"0s":void 0},children:I&&s})})});se.displayName=re;function ae(t,e){return`${t}-trigger-${e}`}function ie(t,e){return`${t}-content-${e}`}var Oe=X,Le=te,ke=ne,Ge=se;function Be(t){const e=P.c(8);let n,o;e[0]!==t?({className:n,...o}=t,e[0]=t,e[1]=n,e[2]=o):(n=e[1],o=e[2]);let r;e[3]!==n?(r=j("flex flex-col gap-2",n),e[3]=n,e[4]=r):r=e[4];let s;return e[5]!==o||e[6]!==r?(s=d.jsx(Oe,{"data-slot":"tabs",className:r,...o}),e[5]=o,e[6]=r,e[7]=s):s=e[7],s}function Ue(t){const e=P.c(8);let n,o;e[0]!==t?({className:n,...o}=t,e[0]=t,e[1]=n,e[2]=o):(n=e[1],o=e[2]);let r;e[3]!==n?(r=j("bg-muted text-muted-foreground inline-flex h-9 w-fit items-center justify-center rounded-lg p-[3px]",n),e[3]=n,e[4]=r):r=e[4];let s;return e[5]!==o||e[6]!==r?(s=d.jsx(Le,{"data-slot":"tabs-list",className:r,...o}),e[5]=o,e[6]=r,e[7]=s):s=e[7],s}function ze(t){const e=P.c(8);let n,o;e[0]!==t?({className:n,...o}=t,e[0]=t,e[1]=n,e[2]=o):(n=e[1],o=e[2]);let r;e[3]!==n?(r=j("data-[state=active]:bg-background dark:data-[state=active]:text-foreground focus-visible:border-ring focus-visible:ring-ring/50 focus-visible:outline-ring dark:data-[state=active]:border-input dark:data-[state=active]:bg-input/30 text-foreground dark:text-muted-foreground inline-flex h-[calc(100%-1px)] flex-1 items-center justify-center gap-1.5 rounded-md border border-transparent px-2 py-1 text-sm font-medium whitespace-nowrap transition-[color,box-shadow] focus-visible:ring-[3px] focus-visible:outline-1 disabled:pointer-events-none disabled:opacity-50 data-[state=active]:shadow-sm [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4 cursor-pointer",n),e[3]=n,e[4]=r):r=e[4];let s;return e[5]!==o||e[6]!==r?(s=d.jsx(ke,{"data-slot":"tabs-trigger",className:r,...o}),e[5]=o,e[6]=r,e[7]=s):s=e[7],s}function We(t){const e=P.c(8);let n,o;e[0]!==t?({className:n,...o}=t,e[0]=t,e[1]=n,e[2]=o):(n=e[1],o=e[2]);let r;e[3]!==n?(r=j("flex-1 outline-none",n),e[3]=n,e[4]=r):r=e[4];let s;return e[5]!==o||e[6]!==r?(s=d.jsx(Ge,{"data-slot":"tabs-content",className:r,...o}),e[5]=o,e[6]=r,e[7]=s):s=e[7],s}export{Be as T,Ue as a,ze as b,We as c};
1
+ import{r as a,j as d,aB as fe,aC as $,e as y,aD as G,aE as B,aF as R,aG as U,aH as H,aI as pe,aJ as me,c as P,aa as j}from"./app.js";function L(t){const e=ve(t),n=a.forwardRef((o,r)=>{const{children:s,...i}=o,l=a.Children.toArray(s),v=l.find(ge);if(v){const p=v.props.children,c=l.map(f=>f===v?a.Children.count(p)>1?a.Children.only(null):a.isValidElement(p)?p.props.children:null:f);return d.jsx(e,{...i,ref:r,children:a.isValidElement(p)?a.cloneElement(p,void 0,c):null})}return d.jsx(e,{...i,ref:r,children:s})});return n.displayName=`${t}.Slot`,n}function ve(t){const e=a.forwardRef((n,o)=>{const{children:r,...s}=n;if(a.isValidElement(r)){const i=Ce(r),l=Ie(s,r.props);return r.type!==a.Fragment&&(l.ref=o?fe(o,i):i),a.cloneElement(r,l)}return a.Children.count(r)>1?a.Children.only(null):null});return e.displayName=`${t}.SlotClone`,e}var be=Symbol("radix.slottable");function ge(t){return a.isValidElement(t)&&typeof t.type=="function"&&"__radixId"in t.type&&t.type.__radixId===be}function Ie(t,e){const n={...e};for(const o in e){const r=t[o],s=e[o];/^on[A-Z]/.test(o)?r&&s?n[o]=(...l)=>{const v=s(...l);return r(...l),v}:r&&(n[o]=r):o==="style"?n[o]={...r,...s}:o==="className"&&(n[o]=[r,s].filter(Boolean).join(" "))}return{...t,...n}}function Ce(t){var o,r;let e=(o=Object.getOwnPropertyDescriptor(t.props,"ref"))==null?void 0:o.get,n=e&&"isReactWarning"in e&&e.isReactWarning;return n?t.ref:(e=(r=Object.getOwnPropertyDescriptor(t,"ref"))==null?void 0:r.get,n=e&&"isReactWarning"in e&&e.isReactWarning,n?t.props.ref:t.props.ref||t.ref)}function xe(t){const e=t+"CollectionProvider",[n,o]=$(e),[r,s]=n(e,{collectionRef:{current:null},itemMap:new Map}),i=x=>{const{scope:u,children:g}=x,T=y.useRef(null),m=y.useRef(new Map).current;return d.jsx(r,{scope:u,itemMap:m,collectionRef:T,children:g})};i.displayName=e;const l=t+"CollectionSlot",v=L(l),p=y.forwardRef((x,u)=>{const{scope:g,children:T}=x,m=s(l,g),b=G(u,m.collectionRef);return d.jsx(v,{ref:b,children:T})});p.displayName=l;const c=t+"CollectionItemSlot",f="data-radix-collection-item",I=L(c),E=y.forwardRef((x,u)=>{const{scope:g,children:T,...m}=x,b=y.useRef(null),w=G(u,b),F=s(c,g);return y.useEffect(()=>(F.itemMap.set(b,{ref:b,...m}),()=>void F.itemMap.delete(b))),d.jsx(I,{[f]:"",ref:w,children:T})});E.displayName=c;function h(x){const u=s(t+"CollectionConsumer",x);return y.useCallback(()=>{const T=u.collectionRef.current;if(!T)return[];const m=Array.from(T.querySelectorAll(`[${f}]`));return Array.from(u.itemMap.values()).sort((F,A)=>m.indexOf(F.ref.current)-m.indexOf(A.ref.current))},[u.collectionRef,u.itemMap])}return[{Provider:i,Slot:p,ItemSlot:E},h,o]}var Te=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","select","span","svg","ul"],_=Te.reduce((t,e)=>{const n=L(`Primitive.${e}`),o=a.forwardRef((r,s)=>{const{asChild:i,...l}=r,v=i?n:e;return typeof window<"u"&&(window[Symbol.for("radix-ui")]=!0),d.jsx(v,{...l,ref:s})});return o.displayName=`Primitive.${e}`,{...t,[e]:o}},{}),O="rovingFocusGroup.onEntryFocus",Re={bubbles:!1,cancelable:!0},N="RovingFocusGroup",[k,W,Ee]=xe(N),[Se,z]=$(N,[Ee]),[ye,he]=Se(N),Y=a.forwardRef((t,e)=>d.jsx(k.Provider,{scope:t.__scopeRovingFocusGroup,children:d.jsx(k.Slot,{scope:t.__scopeRovingFocusGroup,children:d.jsx(we,{...t,ref:e})})}));Y.displayName=N;var we=a.forwardRef((t,e)=>{const{__scopeRovingFocusGroup:n,orientation:o,loop:r=!1,dir:s,currentTabStopId:i,defaultCurrentTabStopId:l,onCurrentTabStopIdChange:v,onEntryFocus:p,preventScrollOnEntryFocus:c=!1,...f}=t,I=a.useRef(null),E=G(e,I),h=U(s),[x,u]=H({prop:i,defaultProp:l??null,onChange:v,caller:N}),[g,T]=a.useState(!1),m=pe(p),b=W(n),w=a.useRef(!1),[F,A]=a.useState(0);return a.useEffect(()=>{const C=I.current;if(C)return C.addEventListener(O,m),()=>C.removeEventListener(O,m)},[m]),d.jsx(ye,{scope:n,orientation:o,dir:h,loop:r,currentTabStopId:x,onItemFocus:a.useCallback(C=>u(C),[u]),onItemShiftTab:a.useCallback(()=>T(!0),[]),onFocusableItemAdd:a.useCallback(()=>A(C=>C+1),[]),onFocusableItemRemove:a.useCallback(()=>A(C=>C-1),[]),children:d.jsx(_.div,{tabIndex:g||F===0?-1:0,"data-orientation":o,...f,ref:E,style:{outline:"none",...t.style},onMouseDown:R(t.onMouseDown,()=>{w.current=!0}),onFocus:R(t.onFocus,C=>{const ce=!w.current;if(C.target===C.currentTarget&&ce&&!g){const K=new CustomEvent(O,Re);if(C.currentTarget.dispatchEvent(K),!K.defaultPrevented){const D=b().filter(S=>S.focusable),le=D.find(S=>S.active),ue=D.find(S=>S.id===x),de=[le,ue,...D].filter(Boolean).map(S=>S.ref.current);Z(de,c)}}w.current=!1}),onBlur:R(t.onBlur,()=>T(!1))})})}),q="RovingFocusGroupItem",J=a.forwardRef((t,e)=>{const{__scopeRovingFocusGroup:n,focusable:o=!0,active:r=!1,tabStopId:s,children:i,...l}=t,v=B(),p=s||v,c=he(q,n),f=c.currentTabStopId===p,I=W(n),{onFocusableItemAdd:E,onFocusableItemRemove:h,currentTabStopId:x}=c;return a.useEffect(()=>{if(o)return E(),()=>h()},[o,E,h]),d.jsx(k.ItemSlot,{scope:n,id:p,focusable:o,active:r,children:d.jsx(_.span,{tabIndex:f?0:-1,"data-orientation":c.orientation,...l,ref:e,onMouseDown:R(t.onMouseDown,u=>{o?c.onItemFocus(p):u.preventDefault()}),onFocus:R(t.onFocus,()=>c.onItemFocus(p)),onKeyDown:R(t.onKeyDown,u=>{if(u.key==="Tab"&&u.shiftKey){c.onItemShiftTab();return}if(u.target!==u.currentTarget)return;const g=Ne(u,c.orientation,c.dir);if(g!==void 0){if(u.metaKey||u.ctrlKey||u.altKey||u.shiftKey)return;u.preventDefault();let m=I().filter(b=>b.focusable).map(b=>b.ref.current);if(g==="last")m.reverse();else if(g==="prev"||g==="next"){g==="prev"&&m.reverse();const b=m.indexOf(u.currentTarget);m=c.loop?Ae(m,b+1):m.slice(b+1)}setTimeout(()=>Z(m))}}),children:typeof i=="function"?i({isCurrentTabStop:f,hasTabStop:x!=null}):i})})});J.displayName=q;var Fe={ArrowLeft:"prev",ArrowUp:"prev",ArrowRight:"next",ArrowDown:"next",PageUp:"first",Home:"first",PageDown:"last",End:"last"};function _e(t,e){return e!=="rtl"?t:t==="ArrowLeft"?"ArrowRight":t==="ArrowRight"?"ArrowLeft":t}function Ne(t,e,n){const o=_e(t.key,n);if(!(e==="vertical"&&["ArrowLeft","ArrowRight"].includes(o))&&!(e==="horizontal"&&["ArrowUp","ArrowDown"].includes(o)))return Fe[o]}function Z(t,e=!1){const n=document.activeElement;for(const o of t)if(o===n||(o.focus({preventScroll:e}),document.activeElement!==n))return}function Ae(t,e){return t.map((n,o)=>t[(e+o)%t.length])}var Pe=Y,je=J,M="Tabs",[Me,Ke]=$(M,[z]),Q=z(),[De,V]=Me(M),X=a.forwardRef((t,e)=>{const{__scopeTabs:n,value:o,onValueChange:r,defaultValue:s,orientation:i="horizontal",dir:l,activationMode:v="automatic",...p}=t,c=U(l),[f,I]=H({prop:o,onChange:r,defaultProp:s??"",caller:M});return d.jsx(De,{scope:n,baseId:B(),value:f,onValueChange:I,orientation:i,dir:c,activationMode:v,children:d.jsx(_.div,{dir:c,"data-orientation":i,...p,ref:e})})});X.displayName=M;var ee="TabsList",te=a.forwardRef((t,e)=>{const{__scopeTabs:n,loop:o=!0,...r}=t,s=V(ee,n),i=Q(n);return d.jsx(Pe,{asChild:!0,...i,orientation:s.orientation,dir:s.dir,loop:o,children:d.jsx(_.div,{role:"tablist","aria-orientation":s.orientation,...r,ref:e})})});te.displayName=ee;var oe="TabsTrigger",ne=a.forwardRef((t,e)=>{const{__scopeTabs:n,value:o,disabled:r=!1,...s}=t,i=V(oe,n),l=Q(n),v=ae(i.baseId,o),p=ie(i.baseId,o),c=o===i.value;return d.jsx(je,{asChild:!0,...l,focusable:!r,active:c,children:d.jsx(_.button,{type:"button",role:"tab","aria-selected":c,"aria-controls":p,"data-state":c?"active":"inactive","data-disabled":r?"":void 0,disabled:r,id:v,...s,ref:e,onMouseDown:R(t.onMouseDown,f=>{!r&&f.button===0&&f.ctrlKey===!1?i.onValueChange(o):f.preventDefault()}),onKeyDown:R(t.onKeyDown,f=>{[" ","Enter"].includes(f.key)&&i.onValueChange(o)}),onFocus:R(t.onFocus,()=>{const f=i.activationMode!=="manual";!c&&!r&&f&&i.onValueChange(o)})})})});ne.displayName=oe;var re="TabsContent",se=a.forwardRef((t,e)=>{const{__scopeTabs:n,value:o,forceMount:r,children:s,...i}=t,l=V(re,n),v=ae(l.baseId,o),p=ie(l.baseId,o),c=o===l.value,f=a.useRef(c);return a.useEffect(()=>{const I=requestAnimationFrame(()=>f.current=!1);return()=>cancelAnimationFrame(I)},[]),d.jsx(me,{present:r||c,children:({present:I})=>d.jsx(_.div,{"data-state":c?"active":"inactive","data-orientation":l.orientation,role:"tabpanel","aria-labelledby":v,hidden:!I,id:p,tabIndex:0,...i,ref:e,style:{...t.style,animationDuration:f.current?"0s":void 0},children:I&&s})})});se.displayName=re;function ae(t,e){return`${t}-trigger-${e}`}function ie(t,e){return`${t}-content-${e}`}var Oe=X,Ge=te,Le=ne,ke=se;function Be(t){const e=P.c(8);let n,o;e[0]!==t?({className:n,...o}=t,e[0]=t,e[1]=n,e[2]=o):(n=e[1],o=e[2]);let r;e[3]!==n?(r=j("flex flex-col gap-2",n),e[3]=n,e[4]=r):r=e[4];let s;return e[5]!==o||e[6]!==r?(s=d.jsx(Oe,{"data-slot":"tabs",className:r,...o}),e[5]=o,e[6]=r,e[7]=s):s=e[7],s}function Ue(t){const e=P.c(8);let n,o;e[0]!==t?({className:n,...o}=t,e[0]=t,e[1]=n,e[2]=o):(n=e[1],o=e[2]);let r;e[3]!==n?(r=j("bg-muted text-muted-foreground inline-flex h-9 w-fit items-center justify-center rounded-lg p-[3px]",n),e[3]=n,e[4]=r):r=e[4];let s;return e[5]!==o||e[6]!==r?(s=d.jsx(Ge,{"data-slot":"tabs-list",className:r,...o}),e[5]=o,e[6]=r,e[7]=s):s=e[7],s}function He(t){const e=P.c(8);let n,o;e[0]!==t?({className:n,...o}=t,e[0]=t,e[1]=n,e[2]=o):(n=e[1],o=e[2]);let r;e[3]!==n?(r=j("data-[state=active]:bg-background dark:data-[state=active]:text-foreground focus-visible:border-ring focus-visible:ring-ring/50 focus-visible:outline-ring dark:data-[state=active]:border-input dark:data-[state=active]:bg-input/30 text-foreground dark:text-muted-foreground inline-flex h-[calc(100%-1px)] flex-1 items-center justify-center gap-1.5 rounded-md border border-transparent px-2 py-1 text-sm font-medium whitespace-nowrap transition-[color,box-shadow] focus-visible:ring-[3px] focus-visible:outline-1 disabled:pointer-events-none disabled:opacity-50 data-[state=active]:shadow-sm [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4 cursor-pointer",n),e[3]=n,e[4]=r):r=e[4];let s;return e[5]!==o||e[6]!==r?(s=d.jsx(Le,{"data-slot":"tabs-trigger",className:r,...o}),e[5]=o,e[6]=r,e[7]=s):s=e[7],s}function We(t){const e=P.c(8);let n,o;e[0]!==t?({className:n,...o}=t,e[0]=t,e[1]=n,e[2]=o):(n=e[1],o=e[2]);let r;e[3]!==n?(r=j("flex-1 outline-none",n),e[3]=n,e[4]=r):r=e[4];let s;return e[5]!==o||e[6]!==r?(s=d.jsx(ke,{"data-slot":"tabs-content",className:r,...o}),e[5]=o,e[6]=r,e[7]=s):s=e[7],s}export{He as T,We as a,Ue as b,Be as c};
@@ -1 +1 @@
1
- import{c as f,bu as h,bv as d,bw as x,j as m,B as k}from"./app.js";import{u as b}from"./use-appearance-CXP5cHaQ.js";import{Icon as y}from"./icon-ChQBPA5l.js";function _(){const e=f.c(10),{appearance:s,updateAppearance:r}=b();let n;e[0]===Symbol.for("react.memo_cache_sentinel")?(n={light:"dark",dark:"system",system:"light"},e[0]=n):n=e[0];const p=n;let o;e[1]===Symbol.for("react.memo_cache_sentinel")?(o={light:x,dark:d,system:h},e[1]=o):o=e[1];const u=o;let a;e[2]!==s||e[3]!==r?(a=()=>r(p[s]),e[2]=s,e[3]=r,e[4]=a):a=e[4];const i=a,l=u[s];let t;e[5]!==l?(t=m.jsx(y,{iconNode:l}),e[5]=l,e[6]=t):t=e[6];let c;return e[7]!==i||e[8]!==t?(c=m.jsx(k,{variant:"ghost",size:"icon",onClick:i,className:"shrink-0",children:t}),e[7]=i,e[8]=t,e[9]=c):c=e[9],c}export{_ as ThemeSwitcher,_ as default};
1
+ import{c as u,bx as h,by as d,bz as x,j as m,B as k}from"./app.js";import{u as y}from"./use-appearance-CXP5cHaQ.js";import{Icon as b}from"./icon-BWrEqTE-.js";function _(){const e=u.c(10),{appearance:s,updateAppearance:r}=y();let n;e[0]===Symbol.for("react.memo_cache_sentinel")?(n={light:"dark",dark:"system",system:"light"},e[0]=n):n=e[0];const p=n;let o;e[1]===Symbol.for("react.memo_cache_sentinel")?(o={light:x,dark:d,system:h},e[1]=o):o=e[1];const f=o;let a;e[2]!==s||e[3]!==r?(a=()=>r(p[s]),e[2]=s,e[3]=r,e[4]=a):a=e[4];const i=a,l=f[s];let t;e[5]!==l?(t=m.jsx(b,{iconNode:l}),e[5]=l,e[6]=t):t=e[6];let c;return e[7]!==i||e[8]!==t?(c=m.jsx(k,{variant:"ghost",size:"icon",onClick:i,className:"shrink-0",children:t}),e[7]=i,e[8]=t,e[9]=c):c=e[9],c}export{_ as ThemeSwitcher,_ as default};
@@ -1 +1 @@
1
- import{c as x,j as l,bx as h,by as p,bz as j}from"./app.js";function v(){return I}function I(g){const t=g.trim().split(" ");if(t.length===0)return"";if(t.length===1)return t[0].charAt(0).toUpperCase();const e=t[0].charAt(0),m=t[t.length-1].charAt(0);return`${e}${m}`.toUpperCase()}function A(g){const t=x.c(22),{user:e,showEmail:m}=g,u=m===void 0?!1:m,d=v();let s;t[0]!==e.avatar||t[1]!==e.login?(s=l.jsx(h,{src:e.avatar,alt:e.login}),t[0]=e.avatar,t[1]=e.login,t[2]=s):s=t[2];let a;t[3]!==d||t[4]!==e.login?(a=d(e.login),t[3]=d,t[4]=e.login,t[5]=a):a=t[5];let i;t[6]!==a?(i=l.jsx(p,{className:"rounded-lg bg-neutral-200 text-black dark:bg-neutral-700 dark:text-white",children:a}),t[6]=a,t[7]=i):i=t[7];let n;t[8]!==s||t[9]!==i?(n=l.jsxs(j,{className:"h-8 w-8 overflow-hidden rounded-full",children:[s,i]}),t[8]=s,t[9]=i,t[10]=n):n=t[10];let r;t[11]!==e.login?(r=l.jsx("span",{className:"truncate font-medium",children:e.login}),t[11]=e.login,t[12]=r):r=t[12];let o;t[13]!==u||t[14]!==e.email?(o=u&&l.jsx("span",{className:"text-muted-foreground truncate text-xs",children:e.email}),t[13]=u,t[14]=e.email,t[15]=o):o=t[15];let c;t[16]!==r||t[17]!==o?(c=l.jsxs("div",{className:"grid flex-1 text-left text-sm leading-tight",children:[r,o]}),t[16]=r,t[17]=o,t[18]=c):c=t[18];let f;return t[19]!==n||t[20]!==c?(f=l.jsxs(l.Fragment,{children:[n,c]}),t[19]=n,t[20]=c,t[21]=f):f=t[21],f}export{A as UserInfo};
1
+ import{c as x,j as l,bA as h,bB as p,bC as j}from"./app.js";function v(){return I}function I(g){const t=g.trim().split(" ");if(t.length===0)return"";if(t.length===1)return t[0].charAt(0).toUpperCase();const e=t[0].charAt(0),m=t[t.length-1].charAt(0);return`${e}${m}`.toUpperCase()}function A(g){const t=x.c(22),{user:e,showEmail:m}=g,u=m===void 0?!1:m,d=v();let s;t[0]!==e.avatar||t[1]!==e.login?(s=l.jsx(h,{src:e.avatar,alt:e.login}),t[0]=e.avatar,t[1]=e.login,t[2]=s):s=t[2];let a;t[3]!==d||t[4]!==e.login?(a=d(e.login),t[3]=d,t[4]=e.login,t[5]=a):a=t[5];let i;t[6]!==a?(i=l.jsx(p,{className:"rounded-lg bg-neutral-200 text-black dark:bg-neutral-700 dark:text-white",children:a}),t[6]=a,t[7]=i):i=t[7];let n;t[8]!==s||t[9]!==i?(n=l.jsxs(j,{className:"h-8 w-8 overflow-hidden rounded-full",children:[s,i]}),t[8]=s,t[9]=i,t[10]=n):n=t[10];let r;t[11]!==e.login?(r=l.jsx("span",{className:"truncate font-medium",children:e.login}),t[11]=e.login,t[12]=r):r=t[12];let o;t[13]!==u||t[14]!==e.email?(o=u&&l.jsx("span",{className:"text-muted-foreground truncate text-xs",children:e.email}),t[13]=u,t[14]=e.email,t[15]=o):o=t[15];let c;t[16]!==r||t[17]!==o?(c=l.jsxs("div",{className:"grid flex-1 text-left text-sm leading-tight",children:[r,o]}),t[16]=r,t[17]=o,t[18]=c):c=t[18];let f;return t[19]!==n||t[20]!==c?(f=l.jsxs(l.Fragment,{children:[n,c]}),t[19]=n,t[20]=c,t[21]=f):f=t[21],f}export{A as UserInfo};
@@ -1 +1 @@
1
- import{c as p,j as t,bA as f,aN as x,bB as d,aL as h,$ as j}from"./app.js";import{UserInfo as b}from"./user-info-Db5Y8KeN.js";function g(){return y}function y(){document.body.style.removeProperty("pointer-events")}function M(u){const e=p.c(11),{user:a,logout:c,logoutBtn:i}=u,m=g();let o;e[0]!==a?(o=t.jsx(f,{className:"p-0 font-normal",children:t.jsx("div",{className:"flex items-center gap-2 px-1 py-1.5 text-left text-sm",children:t.jsx(b,{user:a,showEmail:!0})})}),e[0]=a,e[1]=o):o=e[1];let n;e[2]===Symbol.for("react.memo_cache_sentinel")?(n=t.jsx(x,{}),e[2]=n):n=e[2];let r;e[3]===Symbol.for("react.memo_cache_sentinel")?(r=t.jsx(d,{className:"mr-2"}),e[3]=r):r=e[3];let s;e[4]!==m||e[5]!==c||e[6]!==i?(s=t.jsx(h,{asChild:!0,children:t.jsxs(j,{className:"block w-full cursor-pointer",method:"get",href:c,as:"button",onClick:m,children:[r,i]})}),e[4]=m,e[5]=c,e[6]=i,e[7]=s):s=e[7];let l;return e[8]!==o||e[9]!==s?(l=t.jsxs(t.Fragment,{children:[o,n,s]}),e[8]=o,e[9]=s,e[10]=l):l=e[10],l}export{M as UserMenuContent};
1
+ import{c as p,j as t,bD as f,aQ as x,bE as d,aP as h,$ as j}from"./app.js";import{UserInfo as b}from"./user-info-CJp_GYZl.js";function g(){return y}function y(){document.body.style.removeProperty("pointer-events")}function N(u){const e=p.c(11),{user:a,logout:c,logoutBtn:i}=u,m=g();let o;e[0]!==a?(o=t.jsx(f,{className:"p-0 font-normal",children:t.jsx("div",{className:"flex items-center gap-2 px-1 py-1.5 text-left text-sm",children:t.jsx(b,{user:a,showEmail:!0})})}),e[0]=a,e[1]=o):o=e[1];let n;e[2]===Symbol.for("react.memo_cache_sentinel")?(n=t.jsx(x,{}),e[2]=n):n=e[2];let r;e[3]===Symbol.for("react.memo_cache_sentinel")?(r=t.jsx(d,{className:"mr-2"}),e[3]=r):r=e[3];let s;e[4]!==m||e[5]!==c||e[6]!==i?(s=t.jsx(h,{asChild:!0,children:t.jsxs(j,{className:"block w-full cursor-pointer",method:"get",href:c,as:"button",onClick:m,children:[r,i]})}),e[4]=m,e[5]=c,e[6]=i,e[7]=s):s=e[7];let l;return e[8]!==o||e[9]!==s?(l=t.jsxs(t.Fragment,{children:[o,n,s]}),e[8]=o,e[9]=s,e[10]=l):l=e[10],l}export{N as UserMenuContent};
@@ -1 +1 @@
1
- import{c as l,q as m,j as p}from"./app.js";import{A as x}from"./app-layout-ContoN1K.js";import"./app-shell-DHzMWA1L.js";import"./app-sidebar-D7l5BJPV.js";import"./nav-main-DVgvko8g.js";import"./material-icon-BIcI8APG.js";import"./app-sidebar-header-CK8t32cm.js";import"./breadcrumbs-DnNOEnT4.js";import"./nav-user-vIwYShwE.js";import"./user-info-Db5Y8KeN.js";import"./user-menu-content-Bc8YNZPf.js";import"./theme-switcher-fzVA8btX.js";import"./use-appearance-CXP5cHaQ.js";import"./icon-ChQBPA5l.js";const a=[];function E(){const t=l.c(8),e=m();let r;t[0]!==e.props.title?(r=e.props.title&&p.jsx("div",{className:"text-3xl mb-8",children:e.props.title}),t[0]=e.props.title,t[1]=r):r=t[1];let s;t[2]===Symbol.for("react.memo_cache_sentinel")?(s=p.jsx("div",{className:"text-3xl mb-8",children:"Adminizer"}),t[2]=s):s=t[2];let o;t[3]!==e.props.text?(o=e.props.text&&p.jsx("div",{dangerouslySetInnerHTML:{__html:e.props.text}}),t[3]=e.props.text,t[4]=o):o=t[4];let i;return t[5]!==r||t[6]!==o?(i=p.jsx(x,{breadcrumbs:a,children:p.jsxs("div",{className:"flex h-full flex-1 flex-col gap-4 rounded-xl p-4",children:[r,s,o]})}),t[5]=r,t[6]=o,t[7]=i):i=t[7],i}export{E as default};
1
+ import{c as l,q as m,j as p}from"./app.js";import{A as x}from"./app-layout-CDjEwM9a.js";import"./app-shell-CByYJPLe.js";import"./app-sidebar-CLPoDV2f.js";import"./nav-main-DQNNAKwu.js";import"./material-icon-BE8cT_z7.js";import"./app-sidebar-header-B1mI-oGm.js";import"./breadcrumbs-0GLBx1iv.js";import"./nav-user-q7QW6ZiI.js";import"./user-info-CJp_GYZl.js";import"./user-menu-content-ljwR9luU.js";import"./theme-switcher-BZ6eg-WU.js";import"./use-appearance-CXP5cHaQ.js";import"./icon-BWrEqTE-.js";const a=[];function E(){const t=l.c(8),e=m();let r;t[0]!==e.props.title?(r=e.props.title&&p.jsx("div",{className:"text-3xl mb-8",children:e.props.title}),t[0]=e.props.title,t[1]=r):r=t[1];let s;t[2]===Symbol.for("react.memo_cache_sentinel")?(s=p.jsx("div",{className:"text-3xl mb-8",children:"Adminizer"}),t[2]=s):s=t[2];let o;t[3]!==e.props.text?(o=e.props.text&&p.jsx("div",{dangerouslySetInnerHTML:{__html:e.props.text}}),t[3]=e.props.text,t[4]=o):o=t[4];let i;return t[5]!==r||t[6]!==o?(i=p.jsx(x,{breadcrumbs:a,children:p.jsxs("div",{className:"flex h-full flex-1 flex-col gap-4 rounded-xl p-4",children:[r,s,o]})}),t[5]=r,t[6]=o,t[7]=i):i=t[7],i}export{E as default};
@@ -87,8 +87,6 @@ export default async function add(req, res) {
87
87
  }
88
88
  try {
89
89
  let record = await entity.model.create(reqData, dataAccessor);
90
- // log system event notification
91
- await req.adminizer.logSystemCreatedEvent(req.i18n.__('Created'), `user ${req.user.login} ${req.i18n.__('create')} ${entity.name} ${record.id}`, { test: 'test' });
92
90
  // save associations media to json
93
91
  await saveRelationsMediaManager(fields, rawReqData, entity.model.identity, record.id);
94
92
  Adminizer.log.debug(`A new record was created: `, record);
@@ -115,12 +115,12 @@ export default async function edit(req, res) {
115
115
  try {
116
116
  let newRecord = await entity.model.update(params, reqData, dataAccessor);
117
117
  await saveRelationsMediaManager(fields, rawReqData, entity.model.identity, newRecord[0].id);
118
- // Создаем clean объекты для сравнения (исключаем системные поля)
118
+ // Create diff
119
119
  const cleanOldRecord = sanitizeForDiff(record);
120
120
  const cleanNewRecord = sanitizeForDiff(newRecord[0]);
121
- // Получаем diff
121
+ // Get diff
122
122
  const changesDiff = diff(cleanOldRecord, cleanNewRecord);
123
- // Форматируем для лога
123
+ // Format changes
124
124
  const formattedChanges = formatChanges(changesDiff, cleanOldRecord, cleanNewRecord);
125
125
  // log system event notification
126
126
  await req.adminizer.logSystemUpdatedEvent(req.i18n.__('Updated'), `user ${req.user.login} ${req.i18n.__('update')} ${entity.name} ${record.id}`, {
@@ -14,25 +14,25 @@ export default async function login(req, res) {
14
14
  let login = req.body.login;
15
15
  let password = req.body.password;
16
16
  let captchaSolution = req.body.captchaSolution;
17
- // Handle pretend (impersonation) first against internal users list
17
+ let user;
18
+ try {
19
+ // TODO refactor CRUD functions for DataAccessor usage
20
+ user = await req.adminizer.modelHandler.model.get("UserAP")["_findOne"]({ login: login });
21
+ }
22
+ catch (e) {
23
+ return res.status(500).send({ error: e.message || 'Internal Server Error' });
24
+ }
18
25
  if (req.body.pretend) {
19
- try {
20
- // TODO refactor CRUD functions for DataAccessor usage
21
- const pretendUser = await req.adminizer.modelHandler.model.get("UserAP")["_findOne"]({ login });
22
- if (!pretendUser) {
23
- return res.sendStatus(404);
24
- }
25
- if (req.user.isAdministrator) {
26
- req.session.userPretended = pretendUser;
27
- return req.Inertia.redirect(`${req.adminizer.config.routePrefix}`);
28
- }
29
- return req.Inertia.redirect(`${req.adminizer.config.routePrefix}/`);
26
+ if (!user) {
27
+ return res.sendStatus(404);
30
28
  }
31
- catch (e) {
32
- return res.status(500).send({ error: e.message || 'Internal Server Error' });
29
+ if (req.user.isAdministrator) {
30
+ req.session.userPretended = user;
31
+ // return res.sendStatus(200);
32
+ return req.Inertia.redirect(`${req.adminizer.config.routePrefix}`);
33
33
  }
34
+ return req.Inertia.redirect(`${req.adminizer.config.routePrefix}/`);
34
35
  }
35
- let authenticatedExternally = false;
36
36
  // Verify CAPTCHA solution if enabled
37
37
  if (req.adminizer.config.auth.captcha !== false) {
38
38
  const isCaptchaValid = powCaptcha.check(captchaSolution, `login:${req.ip}`);
@@ -40,22 +40,17 @@ export default async function login(req, res) {
40
40
  return inertiaAdminMessage(req, "Invalid CAPTCHA solution", 'captchaSolution');
41
41
  }
42
42
  }
43
- // First check UserAP model (local auth)
44
- let user;
45
- try {
46
- // TODO refactor CRUD functions for DataAccessor usage
47
- user = await req.adminizer.modelHandler.model.get("UserAP")["_findOne"]({ login: login });
48
- }
49
- catch (e) {
50
- return res.status(500).send({ error: e.message || 'Internal Server Error' });
43
+ if (!user) {
44
+ return inertiaAdminMessage(req, "Wrong username", 'login');
51
45
  }
52
- if (user) {
53
- // User found in UserAP, validate password
54
- if (req.adminizer.config.registration.confirmationRequired && user.isConfirmed === false && !user.isAdministrator) {
46
+ else {
47
+ if (req.adminizer.config.registration.confirmationRequired && !user.isConfirmed && !user.isAdministrator) {
48
+ //Here we use the captchaSolution key to output messages unrelated to the form fields.
55
49
  return inertiaAdminMessage(req, "Profile is not confirmed, please contact to administrator", 'captchaSolution');
56
50
  }
57
51
  if (passwordHash.verify(login + password + process.env.AP_PASSWORD_SALT, user.passwordHashed)) {
58
52
  if (user.expires && Date.now() > Date.parse(user.expires)) {
53
+ //Here we use the captchaSolution key to output messages unrelated to the form fields.
59
54
  return inertiaAdminMessage(req, "Profile expired, contact the administrator", 'captchaSolution');
60
55
  }
61
56
  const token = signUser(user, req.adminizer.jwtSecret);
@@ -71,36 +66,6 @@ export default async function login(req, res) {
71
66
  return inertiaAdminMessage(req, "Wrong password", 'password');
72
67
  }
73
68
  }
74
- // If user not found in UserAP and external auth handler is configured, try external auth
75
- if (typeof req.adminizer.authHandler === 'function') {
76
- try {
77
- const extUser = await req.adminizer.authHandler(req, login, password);
78
- if (!extUser) {
79
- return inertiaAdminMessage(req, "Wrong username or password", 'login');
80
- }
81
- const externalUser = extUser;
82
- if (req.adminizer.config.registration.confirmationRequired && externalUser.isConfirmed === false && !externalUser.isAdministrator) {
83
- return inertiaAdminMessage(req, "Profile is not confirmed, please contact to administrator", 'captchaSolution');
84
- }
85
- if (externalUser.expires && Date.now() > Date.parse(externalUser.expires)) {
86
- return inertiaAdminMessage(req, "Profile expired, contact the administrator", 'captchaSolution');
87
- }
88
- const token = signUser(externalUser, req.adminizer.jwtSecret);
89
- res.setHeader('Set-Cookie', serialize('adminizer_jwt', token, {
90
- httpOnly: true,
91
- sameSite: 'lax',
92
- path: '/',
93
- maxAge: 60 * 60 * 24 * 7 * 2,
94
- }));
95
- return req.Inertia.redirect(`${req.adminizer.config.routePrefix}`);
96
- }
97
- catch (err) {
98
- Adminizer.log.error('External auth handler error', err);
99
- return res.status(500).send({ error: 'Internal Server Error' });
100
- }
101
- }
102
- // If neither UserAP nor external auth worked
103
- return inertiaAdminMessage(req, "Wrong username or password", 'login');
104
69
  }
105
70
  if (req.method.toUpperCase() === "GET") {
106
71
  // Generate new CAPTCHA task if enabled
@@ -2,6 +2,8 @@ import { ControllerHelper } from "../helpers/controllerHelper";
2
2
  import { deleteRelationsMediaManager } from "../lib/media-manager/helpers/MediaManagerHelper";
3
3
  import { DataAccessor } from "../lib/v4/DataAccessor";
4
4
  import { Adminizer } from "../lib/Adminizer";
5
+ import { formatChanges, sanitizeForDiff } from "../helpers/diffHelpers";
6
+ import { diff } from "deep-object-diff";
5
7
  export default async function remove(req, res) {
6
8
  // Checking id of the record
7
9
  if (!req.params.id) {
@@ -60,6 +62,7 @@ export default async function remove(req, res) {
60
62
  const q = {};
61
63
  q[fieldId] = record[fieldId];
62
64
  destroyedRecord = await entity.model.destroy(q, dataAccessor);
65
+ console.log(destroyedRecord[0]);
63
66
  // delete relations media manager
64
67
  await deleteRelationsMediaManager(req.adminizer, entity.name, destroyedRecord);
65
68
  }
@@ -67,8 +70,14 @@ export default async function remove(req, res) {
67
70
  Adminizer.log.error('adminpanel > error', e);
68
71
  }
69
72
  if (destroyedRecord) {
70
- // log system event notification
71
- await req.adminizer.logSystemDeletedEvent(req.i18n.__('Deleted'), `user ${req.user.login} ${req.i18n.__('delete')} ${entity.name} ${destroyedRecord[0].id}`, { test: 'test' });
73
+ const cleanRecordBeforeDelete = sanitizeForDiff(destroyedRecord[0]);
74
+ const changesDiff = diff(cleanRecordBeforeDelete, {});
75
+ const formattedChanges = formatChanges(changesDiff, cleanRecordBeforeDelete, {});
76
+ // log system event notification с diff
77
+ await req.adminizer.logSystemDeletedEvent(req.i18n.__('Deleted'), `user ${req.user.login} ${req.i18n.__('delete')} ${entity.name} ${destroyedRecord[0].id}`, {
78
+ changes: formattedChanges,
79
+ summary: `${req.i18n.__('Deleted')} ${formattedChanges.length} ${req.i18n.__('fields')}`
80
+ });
72
81
  req.flash.setFlashMessage('success', req.i18n.__('Record was removed successfully !'));
73
82
  }
74
83
  else {
@@ -1,2 +1,2 @@
1
1
  export declare function sanitizeForDiff(data: any): any;
2
- export declare function formatChanges(diffObj: any, oldData: any, newData: any): any[];
2
+ export declare function formatChanges(diffObj: any, oldData: any, newData: any, operation?: 'add' | 'remove' | 'update'): any[];
@@ -6,6 +6,7 @@ export function sanitizeForDiff(data) {
6
6
  const systemFields = ['id', 'createdAt', 'updatedAt', 'deletedAt', '__v', '_id'];
7
7
  systemFields.forEach(field => delete result[field]);
8
8
  // Очищаем чувствительные данные
9
+ // TODO: Вынести в переменные окружения или в конфиг
9
10
  const sensitiveFields = ['password', 'token', 'secret', 'apiKey', 'creditCard'];
10
11
  sensitiveFields.forEach(field => {
11
12
  if (result[field] !== undefined) {
@@ -14,11 +15,55 @@ export function sanitizeForDiff(data) {
14
15
  });
15
16
  return result;
16
17
  }
17
- export function formatChanges(diffObj, oldData, newData) {
18
- return Object.entries(diffObj).map(([key, value]) => ({
19
- field: key,
20
- oldValue: oldData[key],
21
- newValue: newData[key],
22
- type: typeof value
23
- }));
18
+ export function formatChanges(diffObj, oldData, newData, operation) {
19
+ const changes = [];
20
+ // Специальная обработка для операции добавления
21
+ if (operation === 'add') {
22
+ for (const [key, value] of Object.entries(newData)) {
23
+ if (value === '***HIDDEN***')
24
+ continue;
25
+ changes.push({
26
+ field: key,
27
+ oldValue: undefined,
28
+ newValue: value,
29
+ type: typeof value,
30
+ operation: 'add'
31
+ });
32
+ }
33
+ return changes;
34
+ }
35
+ // Стандартная обработка для remove и update
36
+ for (const [key, value] of Object.entries(diffObj)) {
37
+ // Для добавленных полей (когда oldData[key] undefined)
38
+ if (oldData[key] === undefined && newData[key] !== undefined) {
39
+ changes.push({
40
+ field: key,
41
+ oldValue: undefined,
42
+ newValue: newData[key],
43
+ type: 'added',
44
+ operation: 'add'
45
+ });
46
+ }
47
+ // Для удаленных полей (когда newData[key] undefined)
48
+ else if (newData[key] === undefined && oldData[key] !== undefined) {
49
+ changes.push({
50
+ field: key,
51
+ oldValue: oldData[key],
52
+ newValue: undefined,
53
+ type: 'deleted',
54
+ operation: 'remove'
55
+ });
56
+ }
57
+ // Для измененных полей
58
+ else {
59
+ changes.push({
60
+ field: key,
61
+ oldValue: oldData[key],
62
+ newValue: newData[key],
63
+ type: typeof value,
64
+ operation: 'update'
65
+ });
66
+ }
67
+ }
68
+ return changes;
24
69
  }
@@ -11,6 +11,25 @@ export function inertiaLoginHelper(req) {
11
11
  link: `${req.adminizer.config.routePrefix}/model/userap/register`
12
12
  };
13
13
  }
14
+ // Optional additional link at the bottom of login page
15
+ const addPage = req.adminizer.config.auth?.addishinalLoginPage;
16
+ if (addPage && typeof addPage.link === 'string' && addPage.link.length > 0) {
17
+ const raw = addPage.link;
18
+ let link = raw;
19
+ if (/^https?:\/\//i.test(raw)) {
20
+ link = raw; // absolute URL
21
+ }
22
+ else if (raw.startsWith(`/${req.adminizer.config.routePrefix}`)) {
23
+ link = `${raw}`;
24
+ }
25
+ else {
26
+ link = `${req.adminizer.config.routePrefix}/${raw}`;
27
+ }
28
+ props.addishinalLoginPage = {
29
+ title: req.i18n.__(addPage.textKey || 'Additional login page'),
30
+ link,
31
+ };
32
+ }
14
33
  return props;
15
34
  }
16
35
  export function inertiaRegisterHelper(req) {
package/index.d.ts CHANGED
@@ -16,7 +16,6 @@ export * from "./interfaces/types";
16
16
  export * from "./interfaces/MaaterialIcons";
17
17
  export * from "./lib/v4/model/AbstractModel";
18
18
  export * from "./lib/v4/model/adapter/waterline";
19
- export * from "./lib/v4/model/adapter/typeorm";
20
19
  export * from "./lib/v4/model/adapter/sequelize";
21
20
  export * from "./lib/Adminizer";
22
21
  export * from "./models/GroupAP";