nestlens 0.9.3 → 0.9.4

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 (62) hide show
  1. package/dist/api/dto/cursor-query.dto.d.ts +10 -0
  2. package/dist/api/dto/cursor-query.dto.js +62 -12
  3. package/dist/dashboard/public/assets/{BatchDetailView-S21SOoT4.js → BatchDetailView-CBbONEZ6.js} +1 -1
  4. package/dist/dashboard/public/assets/{BatchesPage-B4mRZv-7.js → BatchesPage-C5asqolh.js} +1 -1
  5. package/dist/dashboard/public/assets/{CacheDetailView-CUN4Xlj1.js → CacheDetailView-CqMU8Hge.js} +1 -1
  6. package/dist/dashboard/public/assets/{CachePage-sSG3fOH-.js → CachePage-Ce_yT75F.js} +1 -1
  7. package/dist/dashboard/public/assets/{CommandDetailView-DOnJl4--.js → CommandDetailView-LlOynfrs.js} +1 -1
  8. package/dist/dashboard/public/assets/{CommandsPage-DGSwYx1i.js → CommandsPage-BwMh373Z.js} +1 -1
  9. package/dist/dashboard/public/assets/{CopyButton-DkKluR16.js → CopyButton-YkpN9Yi5.js} +1 -1
  10. package/dist/dashboard/public/assets/{DashboardPage-DMggZXZm.js → DashboardPage-DdaOxHZ2.js} +1 -1
  11. package/dist/dashboard/public/assets/{DataTable-CQVsrmrF.js → DataTable-C9UKN_wr.js} +1 -1
  12. package/dist/dashboard/public/assets/{DetailRow-CR50H99O.js → DetailRow-D_sZP7WV.js} +1 -1
  13. package/dist/dashboard/public/assets/{DumpDetailView-CB2MK264.js → DumpDetailView-B6Zk2IcH.js} +1 -1
  14. package/dist/dashboard/public/assets/{DumpsPage-BFejJT0i.js → DumpsPage-BrYuIT5U.js} +1 -1
  15. package/dist/dashboard/public/assets/{EntryDetailPage-jW_ZykXS.js → EntryDetailPage-D7qvNuMn.js} +3 -3
  16. package/dist/dashboard/public/assets/{EntrySearchInput-DRSpv1XV.js → EntrySearchInput-DeOYz9h4.js} +1 -1
  17. package/dist/dashboard/public/assets/{EventDetailView-_Sg4kaoC.js → EventDetailView-dR0UDb6r.js} +1 -1
  18. package/dist/dashboard/public/assets/{EventsPage-BGCQccD5.js → EventsPage-O1icFuRw.js} +1 -1
  19. package/dist/dashboard/public/assets/{ExceptionDetailView-wg6kccnW.js → ExceptionDetailView-FijwhgLY.js} +1 -1
  20. package/dist/dashboard/public/assets/{ExceptionsPage-BP0Omwzc.js → ExceptionsPage-KuyeMrqK.js} +1 -1
  21. package/dist/dashboard/public/assets/{GateDetailView-B2GkdfXI.js → GateDetailView-CCUc65Vb.js} +1 -1
  22. package/dist/dashboard/public/assets/{GatesPage-BQrbIY_I.js → GatesPage-BKLfGgS9.js} +1 -1
  23. package/dist/dashboard/public/assets/{GraphQLDetailView-CVKiNjx8.js → GraphQLDetailView-DN7qwLjl.js} +1 -1
  24. package/dist/dashboard/public/assets/{GraphQLPage-DdXPF_EJ.js → GraphQLPage-BqkJnBEt.js} +1 -1
  25. package/dist/dashboard/public/assets/{HttpClientDetailView-BOKfN_N3.js → HttpClientDetailView-D7SRccHj.js} +1 -1
  26. package/dist/dashboard/public/assets/{HttpClientPage-Dc4CyjM2.js → HttpClientPage-qC_nBzq2.js} +1 -1
  27. package/dist/dashboard/public/assets/{JobDetailView-DGB3YKwK.js → JobDetailView-B4A5Y2PM.js} +1 -1
  28. package/dist/dashboard/public/assets/{JobsPage-BtHUaYit.js → JobsPage-DyiOLpB1.js} +1 -1
  29. package/dist/dashboard/public/assets/{LogDetailView-Bg5bExCD.js → LogDetailView-DZyruHPx.js} +1 -1
  30. package/dist/dashboard/public/assets/{LogsPage-DCO8kMBG.js → LogsPage-6dDP3Pu_.js} +1 -1
  31. package/dist/dashboard/public/assets/{MailDetailView-Bh1b9g3u.js → MailDetailView-CLhOX0PN.js} +1 -1
  32. package/dist/dashboard/public/assets/{MailPage-yMJfR2pc.js → MailPage-tBhdhWmz.js} +1 -1
  33. package/dist/dashboard/public/assets/{ModelDetailView-C03CykA7.js → ModelDetailView-CVszB9Qw.js} +1 -1
  34. package/dist/dashboard/public/assets/{ModelsPage-DjLplWf-.js → ModelsPage-BTLkoWRR.js} +1 -1
  35. package/dist/dashboard/public/assets/{NotificationDetailView-BTOXMue0.js → NotificationDetailView-CwpaMgGn.js} +1 -1
  36. package/dist/dashboard/public/assets/{NotificationsPage-Dw_KBVVy.js → NotificationsPage-BOPuEc8u.js} +1 -1
  37. package/dist/dashboard/public/assets/{PageHeader-Ce9Hbh0m.js → PageHeader-BQ2bLFIt.js} +1 -1
  38. package/dist/dashboard/public/assets/{QueriesPage-sxyFCofb.js → QueriesPage-Plp4pZSN.js} +1 -1
  39. package/dist/dashboard/public/assets/{QueryDetailView-D3qcL29Q.js → QueryDetailView-B64qfjgM.js} +1 -1
  40. package/dist/dashboard/public/assets/{RedisDetailView-BXlR80r_.js → RedisDetailView-BJ2OaAFq.js} +1 -1
  41. package/dist/dashboard/public/assets/{RedisPage-CJTBRYRA.js → RedisPage-CS2bcK-q.js} +1 -1
  42. package/dist/dashboard/public/assets/{RequestDetailView-BXn6Lehg.js → RequestDetailView-DtTVzNFt.js} +1 -1
  43. package/dist/dashboard/public/assets/{RequestsPage-DzT18Gb7.js → RequestsPage-D9KghDZ-.js} +1 -1
  44. package/dist/dashboard/public/assets/{ScheduleDetailView-DKDN8aDq.js → ScheduleDetailView-D8WOTS8u.js} +1 -1
  45. package/dist/dashboard/public/assets/{SchedulePage-DpUQnTKK.js → SchedulePage-B3mUO2Ng.js} +1 -1
  46. package/dist/dashboard/public/assets/{UserCard-BY0J84X6.js → UserCard-B8lhlqKk.js} +1 -1
  47. package/dist/dashboard/public/assets/{ViewDetailView-DcZJa3Wh.js → ViewDetailView-CUH2MA6k.js} +1 -1
  48. package/dist/dashboard/public/assets/{ViewsPage-BrVbaxmk.js → ViewsPage-BhlcyTU3.js} +1 -1
  49. package/dist/dashboard/public/assets/{calendar-DHSpyI4Y.js → calendar-gUrKMEEq.js} +1 -1
  50. package/dist/dashboard/public/assets/{circle-alert-CraCmO0F.js → circle-alert-WNDYen0I.js} +1 -1
  51. package/dist/dashboard/public/assets/{circle-check-big-ebbAguBz.js → circle-check-big-B6oE8hF5.js} +1 -1
  52. package/dist/dashboard/public/assets/{circle-x-CJZEsYDL.js → circle-x-Ch0JMytg.js} +1 -1
  53. package/dist/dashboard/public/assets/{eye-BEruVuaB.js → eye-DWj2WfH_.js} +1 -1
  54. package/dist/dashboard/public/assets/{index-f3yHnTBu.js → index-B1QFrlfD.js} +2 -2
  55. package/dist/dashboard/public/assets/{search-B0XZ1Fr6.js → search-n3qpR8sp.js} +1 -1
  56. package/dist/dashboard/public/assets/{send-C1Uq07c-.js → send-DkLuIqBH.js} +1 -1
  57. package/dist/dashboard/public/assets/{timer-Dk6Eg1NI.js → timer-Dczpo1G1.js} +1 -1
  58. package/dist/dashboard/public/assets/{types-DZrHs5Iv.js → types-DwzjtRI3.js} +1 -1
  59. package/dist/dashboard/public/assets/{users-Bz2xBYFa.js → users-D7CwV95U.js} +1 -1
  60. package/dist/dashboard/public/assets/{zap-C4mgfWMp.js → zap-C7m34sPr.js} +1 -1
  61. package/dist/dashboard/public/index.html +1 -1
  62. package/package.json +1 -1
@@ -1 +1 @@
1
- import{j as t,A as P,d as A}from"./index-f3yHnTBu.js";import{e as q,b as R}from"./vendor-DBTT3jXp.js";import{f as v,p as D}from"./badgeColors-DQ_P_DOX.js";import{u as L,P as M,N as F,L as H}from"./PageHeader-Ce9Hbh0m.js";import{u as S,i as G,C as l}from"./types-DZrHs5Iv.js";import{E as B}from"./EntrySearchInput-DRSpv1XV.js";import{T as d,D as I,a as O,b as U}from"./DataTable-CQVsrmrF.js";import"./search-B0XZ1Fr6.js";const W=["GET","POST","PUT","PATCH","DELETE","HEAD","OPTIONS","GRAPHQL"],Q=s=>{var a;return(a=s.payload.path)!=null&&a.toLowerCase().includes("/graphql")?"GRAPHQL":s.payload.method.toUpperCase()};function _(){const s=q(),{addFilter:a,clearAll:u,serverFilters:h,headerFilters:p,hasFilters:c}=S("requests"),{entries:m,loading:g,refreshing:r,newEntriesCount:x,hasMore:y,loadMore:f,loadNew:j,autoRefreshEnabled:C,live:T,setAutoRefresh:E,meta:i,isHighlighted:b}=L({type:"request",limit:50,filters:h}),o=m.filter(e=>G(e)),k=R.useMemo(()=>[{key:"method",header:"Method",width:"100px",render:e=>t.jsx(l,{listType:"requests",filterType:"methods",children:Q(e)})},{key:"path",header:"Path",minWidth:"200px",render:e=>t.jsx(d,{mono:!0,truncate:!0,maxWidth:"400px",children:e.payload.path})},{key:"status",header:"Status",width:"80px",align:"center",render:e=>t.jsx(l,{listType:"requests",filterType:"statuses",children:e.payload.statusCode??0})},{key:"duration",header:"Duration",width:"100px",align:"right",render:e=>t.jsx(I,{ms:e.payload.duration??0})},{key:"tags",header:"Tags",minWidth:"150px",render:e=>t.jsx(O,{tags:(e.tags??[]).filter(n=>!W.includes(n.toUpperCase())),max:3,onTagClick:(n,N)=>{N.stopPropagation(),a("tags",n)}})},{key:"time",header:"Time",width:"170px",align:"right",render:e=>t.jsx(d,{secondary:!0,className:"text-xs",children:v(D(e.createdAt),{addSuffix:!0})})}],[a]);if(g&&o.length===0)return t.jsx("div",{className:"flex items-center justify-center h-64",role:"status","aria-label":"Loading...",children:t.jsx("div",{className:"animate-spin rounded-full h-8 w-8 border-b-2 border-primary-600"})});const w=c?"pt-28":"pt-16";return t.jsxs("div",{children:[t.jsx(M,{title:"Requests",icon:P,iconColor:"text-blue-600 dark:text-blue-400",count:o.length,totalCount:i==null?void 0:i.total,refreshing:r,autoRefreshEnabled:C,live:T,onAutoRefreshToggle:E,filters:p,onClearAllFilters:u}),t.jsxs("div",{className:`${w} space-y-4 transition-all duration-200`,children:[t.jsx(B,{placeholder:"Search by path, method, status, tag, or content..."}),t.jsx(F,{count:x,onClick:j,loading:r}),t.jsx(U,{columns:k,data:o,keyExtractor:e=>e.id,onRowClick:e=>s(`/requests/${e.id}`),emptyMessage:"No requests recorded yet",emptyIcon:t.jsx(A,{className:"h-8 w-8 text-gray-400 dark:text-gray-500"}),rowClassName:e=>b(e.id)?"highlight-new":""}),t.jsx(H,{hasMore:y,onClick:f,loading:r})]})]})}export{_ as default};
1
+ import{j as t,A as P,d as A}from"./index-B1QFrlfD.js";import{e as q,b as R}from"./vendor-DBTT3jXp.js";import{f as v,p as D}from"./badgeColors-DQ_P_DOX.js";import{u as L,P as M,N as F,L as H}from"./PageHeader-BQ2bLFIt.js";import{u as S,i as G,C as l}from"./types-DwzjtRI3.js";import{E as B}from"./EntrySearchInput-DeOYz9h4.js";import{T as d,D as I,a as O,b as U}from"./DataTable-C9UKN_wr.js";import"./search-n3qpR8sp.js";const W=["GET","POST","PUT","PATCH","DELETE","HEAD","OPTIONS","GRAPHQL"],Q=s=>{var a;return(a=s.payload.path)!=null&&a.toLowerCase().includes("/graphql")?"GRAPHQL":s.payload.method.toUpperCase()};function _(){const s=q(),{addFilter:a,clearAll:u,serverFilters:h,headerFilters:p,hasFilters:c}=S("requests"),{entries:m,loading:g,refreshing:r,newEntriesCount:x,hasMore:y,loadMore:f,loadNew:j,autoRefreshEnabled:C,live:T,setAutoRefresh:E,meta:i,isHighlighted:b}=L({type:"request",limit:50,filters:h}),o=m.filter(e=>G(e)),k=R.useMemo(()=>[{key:"method",header:"Method",width:"100px",render:e=>t.jsx(l,{listType:"requests",filterType:"methods",children:Q(e)})},{key:"path",header:"Path",minWidth:"200px",render:e=>t.jsx(d,{mono:!0,truncate:!0,maxWidth:"400px",children:e.payload.path})},{key:"status",header:"Status",width:"80px",align:"center",render:e=>t.jsx(l,{listType:"requests",filterType:"statuses",children:e.payload.statusCode??0})},{key:"duration",header:"Duration",width:"100px",align:"right",render:e=>t.jsx(I,{ms:e.payload.duration??0})},{key:"tags",header:"Tags",minWidth:"150px",render:e=>t.jsx(O,{tags:(e.tags??[]).filter(n=>!W.includes(n.toUpperCase())),max:3,onTagClick:(n,N)=>{N.stopPropagation(),a("tags",n)}})},{key:"time",header:"Time",width:"170px",align:"right",render:e=>t.jsx(d,{secondary:!0,className:"text-xs",children:v(D(e.createdAt),{addSuffix:!0})})}],[a]);if(g&&o.length===0)return t.jsx("div",{className:"flex items-center justify-center h-64",role:"status","aria-label":"Loading...",children:t.jsx("div",{className:"animate-spin rounded-full h-8 w-8 border-b-2 border-primary-600"})});const w=c?"pt-28":"pt-16";return t.jsxs("div",{children:[t.jsx(M,{title:"Requests",icon:P,iconColor:"text-blue-600 dark:text-blue-400",count:o.length,totalCount:i==null?void 0:i.total,refreshing:r,autoRefreshEnabled:C,live:T,onAutoRefreshToggle:E,filters:p,onClearAllFilters:u}),t.jsxs("div",{className:`${w} space-y-4 transition-all duration-200`,children:[t.jsx(B,{placeholder:"Search by path, method, status, tag, or content..."}),t.jsx(F,{count:x,onClick:j,loading:r}),t.jsx(U,{columns:k,data:o,keyExtractor:e=>e.id,onRowClick:e=>s(`/requests/${e.id}`),emptyMessage:"No requests recorded yet",emptyIcon:t.jsx(A,{className:"h-8 w-8 text-gray-400 dark:text-gray-500"}),rowClassName:e=>b(e.id)?"highlight-new":""}),t.jsx(H,{hasMore:y,onClick:f,loading:r})]})]})}export{_ as default};
@@ -1 +1 @@
1
- import{w as b,j as e,C as n}from"./index-f3yHnTBu.js";import{f as a,c as N}from"./format-BlNP-apw.js";import{C as o,B as v}from"./types-DZrHs5Iv.js";import{p as l,f as m}from"./badgeColors-DQ_P_DOX.js";import{D as t,f as g}from"./DetailRow-CR50H99O.js";import{C as u}from"./circle-x-CJZEsYDL.js";import{C as k}from"./circle-check-big-ebbAguBz.js";import{T as w}from"./timer-Dk6Eg1NI.js";import{C as T}from"./calendar-DHSpyI4Y.js";import"./vendor-DBTT3jXp.js";function d(i){try{return N.toString(i)}catch{return null}}const h={started:{icon:b,color:"text-blue-500",bg:"bg-blue-100 dark:bg-blue-900/30",label:"STARTED"},completed:{icon:k,color:"text-green-500",bg:"bg-green-100 dark:bg-green-900/30",label:"COMPLETED"},failed:{icon:u,color:"text-red-500",bg:"bg-red-100 dark:bg-red-900/30",label:"FAILED"}},C=["started","completed","failed"];function I({entry:i}){const{payload:s,createdAt:c,tags:j}=i,x=(j??[]).filter(f=>!C.includes(f.toLowerCase())),r=h[s.status]||h.started,p=r.icon,y=()=>s.cron?s.cron:s.interval?`${s.interval}ms`:"-";return e.jsxs("div",{className:"space-y-6",children:[e.jsxs("div",{className:"card",children:[e.jsx("div",{className:"p-4 border-b border-gray-200 dark:border-gray-700",children:e.jsx("div",{className:"flex items-center justify-between",children:e.jsxs("div",{className:"flex items-center space-x-3",children:[e.jsx("div",{className:`p-2 ${r.bg} rounded-lg`,children:e.jsx(n,{className:`h-5 w-5 ${r.color}`})}),e.jsxs("div",{className:"min-w-0 flex-1",children:[e.jsx("h2",{className:"text-lg font-semibold text-gray-900 dark:text-white truncate font-mono",children:s.name}),e.jsx("p",{className:"text-sm text-gray-500 dark:text-gray-400",children:"Scheduled Task"})]})]})})}),e.jsxs("div",{className:"grid grid-cols-2 md:grid-cols-4 divide-x divide-gray-200 dark:divide-gray-700",children:[e.jsxs("div",{className:"p-4",children:[e.jsxs("div",{className:"flex items-center space-x-2 text-gray-500 dark:text-gray-400 mb-1",children:[e.jsx(p,{className:"h-4 w-4"}),e.jsx("span",{className:"text-xs uppercase tracking-wider",children:"Status"})]}),e.jsx("p",{className:`text-lg font-bold ${s.status==="completed"?"text-green-600 dark:text-green-400":s.status==="failed"?"text-red-600 dark:text-red-400":"text-blue-600 dark:text-blue-400"}`,children:r.label})]}),e.jsxs("div",{className:"p-4",children:[e.jsxs("div",{className:"flex items-center space-x-2 text-gray-500 dark:text-gray-400 mb-1",children:[e.jsx(w,{className:"h-4 w-4"}),e.jsx("span",{className:"text-xs uppercase tracking-wider",children:"Duration"})]}),e.jsx("p",{className:"text-lg font-bold text-gray-900 dark:text-white",children:s.duration!==void 0?e.jsxs(e.Fragment,{children:[s.duration,e.jsx("span",{className:"text-sm font-normal text-gray-500 dark:text-gray-400",children:"ms"})]}):"-"})]}),e.jsxs("div",{className:"p-4",children:[e.jsxs("div",{className:"flex items-center space-x-2 text-gray-500 dark:text-gray-400 mb-1",children:[e.jsx(T,{className:"h-4 w-4"}),e.jsx("span",{className:"text-xs uppercase tracking-wider",children:"Schedule"})]}),e.jsx("p",{className:"text-lg font-bold text-gray-900 dark:text-white font-mono",children:y()}),s.cron&&d(s.cron)&&e.jsx("p",{className:"text-xs text-gray-500 dark:text-gray-400 mt-0.5",children:d(s.cron)}),s.interval&&a(s.interval)&&e.jsx("p",{className:"text-xs text-gray-500 dark:text-gray-400 mt-0.5",children:a(s.interval)})]}),e.jsxs("div",{className:"p-4",children:[e.jsxs("div",{className:"flex items-center space-x-2 text-gray-500 dark:text-gray-400 mb-1",children:[e.jsx(n,{className:"h-4 w-4"}),e.jsx("span",{className:"text-xs uppercase tracking-wider",children:"Timeout"})]}),e.jsx("p",{className:"text-lg font-bold text-gray-900 dark:text-white",children:s.timeout!==void 0?e.jsxs(e.Fragment,{children:[s.timeout,e.jsx("span",{className:"text-sm font-normal text-gray-500 dark:text-gray-400",children:"ms"})]}):"-"}),s.timeout!==void 0&&a(s.timeout)&&e.jsx("p",{className:"text-xs text-gray-500 dark:text-gray-400 mt-0.5",children:a(s.timeout)})]})]})]}),e.jsxs("div",{className:"card",children:[e.jsx("div",{className:"px-4 py-3 border-b border-gray-200 dark:border-gray-700",children:e.jsx("h2",{className:"text-lg font-semibold text-gray-900 dark:text-white",children:"Details"})}),e.jsx("div",{className:"p-4",children:e.jsxs("dl",{className:"divide-y-0",children:[e.jsx(t,{label:"Time",value:e.jsxs("span",{children:[g(l(c),"MMMM do yyyy, h:mm:ss a")," ",e.jsxs("span",{className:"text-gray-500 dark:text-gray-400",children:["(",m(l(c),{addSuffix:!0}),")"]})]})}),e.jsx(t,{label:"Task Name",value:e.jsx(o,{listType:"schedule",filterType:"names",filterValue:s.name,className:"font-mono",children:s.name})}),s.cron&&e.jsx(t,{label:"Cron Expression",value:e.jsxs("div",{children:[e.jsx("code",{className:"text-sm font-mono text-gray-900 dark:text-white",children:s.cron}),d(s.cron)&&e.jsx("p",{className:"text-xs text-gray-500 dark:text-gray-400 mt-0.5",children:d(s.cron)})]})}),s.interval&&e.jsx(t,{label:"Interval",value:e.jsxs("div",{children:[e.jsxs("span",{children:[s.interval,"ms"]}),a(s.interval)&&e.jsx("p",{className:"text-xs text-gray-500 dark:text-gray-400 mt-0.5",children:a(s.interval)})]})}),e.jsx(t,{label:"Status",value:e.jsx(o,{listType:"schedule",filterType:"statuses",filterValue:s.status,children:s.status})}),s.duration!==void 0&&e.jsx(t,{label:"Duration",value:`${s.duration}ms`}),s.timeout!==void 0&&e.jsx(t,{label:"Timeout",value:e.jsxs("div",{children:[e.jsxs("span",{children:[s.timeout,"ms"]}),a(s.timeout)&&e.jsx("p",{className:"text-xs text-gray-500 dark:text-gray-400 mt-0.5",children:a(s.timeout)})]})}),s.nextRun&&e.jsx(t,{label:"Next Run",value:e.jsxs("span",{children:[g(l(s.nextRun),"MMMM do yyyy, h:mm:ss a")," ",e.jsxs("span",{className:"text-gray-500 dark:text-gray-400",children:["(",m(l(s.nextRun),{addSuffix:!0}),")"]})]})}),x.length>0&&e.jsx(t,{label:"Tags",value:e.jsx(v,{items:x,listType:"schedule"})})]})})]}),s.error&&e.jsxs("div",{className:"card border-red-200 dark:border-red-800",children:[e.jsx("div",{className:"px-4 py-3 border-b border-red-200 dark:border-red-800 bg-red-50 dark:bg-red-900/20",children:e.jsxs("div",{className:"flex items-center space-x-2",children:[e.jsx(u,{className:"h-5 w-5 text-red-500"}),e.jsx("h2",{className:"text-lg font-semibold text-red-700 dark:text-red-400",children:"Error"})]})}),e.jsx("div",{className:"p-4 bg-red-50/50 dark:bg-red-900/10",children:e.jsx("pre",{className:"text-sm text-red-600 dark:text-red-400 font-mono whitespace-pre-wrap overflow-x-auto",children:s.error})})]})]})}export{I as default};
1
+ import{w as b,j as e,C as n}from"./index-B1QFrlfD.js";import{f as a,c as N}from"./format-BlNP-apw.js";import{C as o,B as v}from"./types-DwzjtRI3.js";import{p as l,f as m}from"./badgeColors-DQ_P_DOX.js";import{D as t,f as g}from"./DetailRow-D_sZP7WV.js";import{C as u}from"./circle-x-Ch0JMytg.js";import{C as k}from"./circle-check-big-B6oE8hF5.js";import{T as w}from"./timer-Dczpo1G1.js";import{C as T}from"./calendar-gUrKMEEq.js";import"./vendor-DBTT3jXp.js";function d(i){try{return N.toString(i)}catch{return null}}const h={started:{icon:b,color:"text-blue-500",bg:"bg-blue-100 dark:bg-blue-900/30",label:"STARTED"},completed:{icon:k,color:"text-green-500",bg:"bg-green-100 dark:bg-green-900/30",label:"COMPLETED"},failed:{icon:u,color:"text-red-500",bg:"bg-red-100 dark:bg-red-900/30",label:"FAILED"}},C=["started","completed","failed"];function I({entry:i}){const{payload:s,createdAt:c,tags:j}=i,x=(j??[]).filter(f=>!C.includes(f.toLowerCase())),r=h[s.status]||h.started,p=r.icon,y=()=>s.cron?s.cron:s.interval?`${s.interval}ms`:"-";return e.jsxs("div",{className:"space-y-6",children:[e.jsxs("div",{className:"card",children:[e.jsx("div",{className:"p-4 border-b border-gray-200 dark:border-gray-700",children:e.jsx("div",{className:"flex items-center justify-between",children:e.jsxs("div",{className:"flex items-center space-x-3",children:[e.jsx("div",{className:`p-2 ${r.bg} rounded-lg`,children:e.jsx(n,{className:`h-5 w-5 ${r.color}`})}),e.jsxs("div",{className:"min-w-0 flex-1",children:[e.jsx("h2",{className:"text-lg font-semibold text-gray-900 dark:text-white truncate font-mono",children:s.name}),e.jsx("p",{className:"text-sm text-gray-500 dark:text-gray-400",children:"Scheduled Task"})]})]})})}),e.jsxs("div",{className:"grid grid-cols-2 md:grid-cols-4 divide-x divide-gray-200 dark:divide-gray-700",children:[e.jsxs("div",{className:"p-4",children:[e.jsxs("div",{className:"flex items-center space-x-2 text-gray-500 dark:text-gray-400 mb-1",children:[e.jsx(p,{className:"h-4 w-4"}),e.jsx("span",{className:"text-xs uppercase tracking-wider",children:"Status"})]}),e.jsx("p",{className:`text-lg font-bold ${s.status==="completed"?"text-green-600 dark:text-green-400":s.status==="failed"?"text-red-600 dark:text-red-400":"text-blue-600 dark:text-blue-400"}`,children:r.label})]}),e.jsxs("div",{className:"p-4",children:[e.jsxs("div",{className:"flex items-center space-x-2 text-gray-500 dark:text-gray-400 mb-1",children:[e.jsx(w,{className:"h-4 w-4"}),e.jsx("span",{className:"text-xs uppercase tracking-wider",children:"Duration"})]}),e.jsx("p",{className:"text-lg font-bold text-gray-900 dark:text-white",children:s.duration!==void 0?e.jsxs(e.Fragment,{children:[s.duration,e.jsx("span",{className:"text-sm font-normal text-gray-500 dark:text-gray-400",children:"ms"})]}):"-"})]}),e.jsxs("div",{className:"p-4",children:[e.jsxs("div",{className:"flex items-center space-x-2 text-gray-500 dark:text-gray-400 mb-1",children:[e.jsx(T,{className:"h-4 w-4"}),e.jsx("span",{className:"text-xs uppercase tracking-wider",children:"Schedule"})]}),e.jsx("p",{className:"text-lg font-bold text-gray-900 dark:text-white font-mono",children:y()}),s.cron&&d(s.cron)&&e.jsx("p",{className:"text-xs text-gray-500 dark:text-gray-400 mt-0.5",children:d(s.cron)}),s.interval&&a(s.interval)&&e.jsx("p",{className:"text-xs text-gray-500 dark:text-gray-400 mt-0.5",children:a(s.interval)})]}),e.jsxs("div",{className:"p-4",children:[e.jsxs("div",{className:"flex items-center space-x-2 text-gray-500 dark:text-gray-400 mb-1",children:[e.jsx(n,{className:"h-4 w-4"}),e.jsx("span",{className:"text-xs uppercase tracking-wider",children:"Timeout"})]}),e.jsx("p",{className:"text-lg font-bold text-gray-900 dark:text-white",children:s.timeout!==void 0?e.jsxs(e.Fragment,{children:[s.timeout,e.jsx("span",{className:"text-sm font-normal text-gray-500 dark:text-gray-400",children:"ms"})]}):"-"}),s.timeout!==void 0&&a(s.timeout)&&e.jsx("p",{className:"text-xs text-gray-500 dark:text-gray-400 mt-0.5",children:a(s.timeout)})]})]})]}),e.jsxs("div",{className:"card",children:[e.jsx("div",{className:"px-4 py-3 border-b border-gray-200 dark:border-gray-700",children:e.jsx("h2",{className:"text-lg font-semibold text-gray-900 dark:text-white",children:"Details"})}),e.jsx("div",{className:"p-4",children:e.jsxs("dl",{className:"divide-y-0",children:[e.jsx(t,{label:"Time",value:e.jsxs("span",{children:[g(l(c),"MMMM do yyyy, h:mm:ss a")," ",e.jsxs("span",{className:"text-gray-500 dark:text-gray-400",children:["(",m(l(c),{addSuffix:!0}),")"]})]})}),e.jsx(t,{label:"Task Name",value:e.jsx(o,{listType:"schedule",filterType:"names",filterValue:s.name,className:"font-mono",children:s.name})}),s.cron&&e.jsx(t,{label:"Cron Expression",value:e.jsxs("div",{children:[e.jsx("code",{className:"text-sm font-mono text-gray-900 dark:text-white",children:s.cron}),d(s.cron)&&e.jsx("p",{className:"text-xs text-gray-500 dark:text-gray-400 mt-0.5",children:d(s.cron)})]})}),s.interval&&e.jsx(t,{label:"Interval",value:e.jsxs("div",{children:[e.jsxs("span",{children:[s.interval,"ms"]}),a(s.interval)&&e.jsx("p",{className:"text-xs text-gray-500 dark:text-gray-400 mt-0.5",children:a(s.interval)})]})}),e.jsx(t,{label:"Status",value:e.jsx(o,{listType:"schedule",filterType:"statuses",filterValue:s.status,children:s.status})}),s.duration!==void 0&&e.jsx(t,{label:"Duration",value:`${s.duration}ms`}),s.timeout!==void 0&&e.jsx(t,{label:"Timeout",value:e.jsxs("div",{children:[e.jsxs("span",{children:[s.timeout,"ms"]}),a(s.timeout)&&e.jsx("p",{className:"text-xs text-gray-500 dark:text-gray-400 mt-0.5",children:a(s.timeout)})]})}),s.nextRun&&e.jsx(t,{label:"Next Run",value:e.jsxs("span",{children:[g(l(s.nextRun),"MMMM do yyyy, h:mm:ss a")," ",e.jsxs("span",{className:"text-gray-500 dark:text-gray-400",children:["(",m(l(s.nextRun),{addSuffix:!0}),")"]})]})}),x.length>0&&e.jsx(t,{label:"Tags",value:e.jsx(v,{items:x,listType:"schedule"})})]})})]}),s.error&&e.jsxs("div",{className:"card border-red-200 dark:border-red-800",children:[e.jsx("div",{className:"px-4 py-3 border-b border-red-200 dark:border-red-800 bg-red-50 dark:bg-red-900/20",children:e.jsxs("div",{className:"flex items-center space-x-2",children:[e.jsx(u,{className:"h-5 w-5 text-red-500"}),e.jsx("h2",{className:"text-lg font-semibold text-red-700 dark:text-red-400",children:"Error"})]})}),e.jsx("div",{className:"p-4 bg-red-50/50 dark:bg-red-900/10",children:e.jsx("pre",{className:"text-sm text-red-600 dark:text-red-400 font-mono whitespace-pre-wrap overflow-x-auto",children:s.error})})]})]})}export{I as default};
@@ -1 +1 @@
1
- import{j as a,C as c}from"./index-f3yHnTBu.js";import{e as A,b as u}from"./vendor-DBTT3jXp.js";import{f as h,c as L}from"./format-BlNP-apw.js";import{f as R,p as H}from"./badgeColors-DQ_P_DOX.js";import{u as B,P as W,N as $,L as I}from"./PageHeader-Ce9Hbh0m.js";import{u as q,h as z,C as m}from"./types-DZrHs5Iv.js";import{T as i,D as G,a as J,b as K}from"./DataTable-CQVsrmrF.js";const O=["started","completed","failed"];function p(t){try{return L.toString(t)}catch{return null}}function ee(){const t=A(),{addFilter:n,clearAll:x,serverFilters:g,headerFilters:f,hasFilters:y}=q("schedule"),{entries:k,loading:j,refreshing:s,newEntriesCount:C,hasMore:N,loadMore:T,loadNew:v,autoRefreshEnabled:b,live:w,setAutoRefresh:E,meta:r,isHighlighted:S}=B({type:"schedule",limit:50,filters:g}),l=k.filter(e=>z(e)),d=u.useCallback(e=>e.payload.cron?e.payload.cron:e.payload.interval?`${e.payload.interval}ms`:"-",[]),D=u.useMemo(()=>[{key:"task",header:"Task",minWidth:"200px",render:e=>a.jsx(m,{listType:"schedule",filterType:"names",className:"font-mono",children:e.payload.name})},{key:"schedule",header:"Schedule",minWidth:"150px",render:e=>a.jsxs("div",{children:[a.jsx(i,{mono:!0,children:d(e)}),e.payload.cron&&p(e.payload.cron)&&a.jsx("span",{className:"text-xs text-gray-500 dark:text-gray-400 block mt-0.5",children:p(e.payload.cron)}),e.payload.interval&&h(e.payload.interval)&&a.jsx("span",{className:"text-xs text-gray-500 dark:text-gray-400 block mt-0.5",children:h(e.payload.interval)})]})},{key:"status",header:"Status",width:"100px",render:e=>a.jsx(m,{listType:"schedule",filterType:"statuses",children:e.payload.status})},{key:"duration",header:"Duration",width:"100px",align:"right",render:e=>e.payload.duration?a.jsx(G,{ms:e.payload.duration}):a.jsx(i,{secondary:!0,children:"—"})},{key:"tags",header:"Tags",minWidth:"150px",render:e=>{const M=(e.tags??[]).filter(o=>!O.includes(o.toLowerCase()));return a.jsx(J,{tags:M,max:3,onTagClick:(o,P)=>{P.stopPropagation(),n("tags",o)}})}},{key:"time",header:"Time",width:"170px",align:"right",render:e=>a.jsx(i,{secondary:!0,className:"text-xs",children:R(H(e.createdAt),{addSuffix:!0})})}],[n,d]);if(j&&l.length===0)return a.jsx("div",{className:"flex items-center justify-center h-64",role:"status","aria-label":"Loading...",children:a.jsx("div",{className:"animate-spin rounded-full h-8 w-8 border-b-2 border-primary-600"})});const F=y?"pt-28":"pt-16";return a.jsxs("div",{children:[a.jsx(W,{title:"Schedule",icon:c,iconColor:"text-gray-600 dark:text-gray-400",count:l.length,totalCount:r==null?void 0:r.total,refreshing:s,autoRefreshEnabled:b,live:w,onAutoRefreshToggle:E,filters:f,onClearAllFilters:x}),a.jsxs("div",{className:`${F} space-y-4 transition-all duration-200`,children:[a.jsx($,{count:C,onClick:v,loading:s}),a.jsx(K,{columns:D,data:l,keyExtractor:e=>e.id,onRowClick:e=>t(`/schedule/${e.id}`),rowClassName:e=>S(e.id)?"highlight-new":"",emptyMessage:"No scheduled tasks recorded yet",emptyIcon:a.jsx(c,{className:"h-8 w-8 text-gray-400 dark:text-gray-500"})}),a.jsx(I,{hasMore:N,onClick:T,loading:s})]})]})}export{ee as default};
1
+ import{j as a,C as c}from"./index-B1QFrlfD.js";import{e as A,b as u}from"./vendor-DBTT3jXp.js";import{f as h,c as L}from"./format-BlNP-apw.js";import{f as R,p as H}from"./badgeColors-DQ_P_DOX.js";import{u as B,P as W,N as $,L as I}from"./PageHeader-BQ2bLFIt.js";import{u as q,h as z,C as m}from"./types-DwzjtRI3.js";import{T as i,D as G,a as J,b as K}from"./DataTable-C9UKN_wr.js";const O=["started","completed","failed"];function p(t){try{return L.toString(t)}catch{return null}}function ee(){const t=A(),{addFilter:n,clearAll:x,serverFilters:g,headerFilters:f,hasFilters:y}=q("schedule"),{entries:k,loading:j,refreshing:s,newEntriesCount:C,hasMore:N,loadMore:T,loadNew:v,autoRefreshEnabled:b,live:w,setAutoRefresh:E,meta:r,isHighlighted:S}=B({type:"schedule",limit:50,filters:g}),l=k.filter(e=>z(e)),d=u.useCallback(e=>e.payload.cron?e.payload.cron:e.payload.interval?`${e.payload.interval}ms`:"-",[]),D=u.useMemo(()=>[{key:"task",header:"Task",minWidth:"200px",render:e=>a.jsx(m,{listType:"schedule",filterType:"names",className:"font-mono",children:e.payload.name})},{key:"schedule",header:"Schedule",minWidth:"150px",render:e=>a.jsxs("div",{children:[a.jsx(i,{mono:!0,children:d(e)}),e.payload.cron&&p(e.payload.cron)&&a.jsx("span",{className:"text-xs text-gray-500 dark:text-gray-400 block mt-0.5",children:p(e.payload.cron)}),e.payload.interval&&h(e.payload.interval)&&a.jsx("span",{className:"text-xs text-gray-500 dark:text-gray-400 block mt-0.5",children:h(e.payload.interval)})]})},{key:"status",header:"Status",width:"100px",render:e=>a.jsx(m,{listType:"schedule",filterType:"statuses",children:e.payload.status})},{key:"duration",header:"Duration",width:"100px",align:"right",render:e=>e.payload.duration?a.jsx(G,{ms:e.payload.duration}):a.jsx(i,{secondary:!0,children:"—"})},{key:"tags",header:"Tags",minWidth:"150px",render:e=>{const M=(e.tags??[]).filter(o=>!O.includes(o.toLowerCase()));return a.jsx(J,{tags:M,max:3,onTagClick:(o,P)=>{P.stopPropagation(),n("tags",o)}})}},{key:"time",header:"Time",width:"170px",align:"right",render:e=>a.jsx(i,{secondary:!0,className:"text-xs",children:R(H(e.createdAt),{addSuffix:!0})})}],[n,d]);if(j&&l.length===0)return a.jsx("div",{className:"flex items-center justify-center h-64",role:"status","aria-label":"Loading...",children:a.jsx("div",{className:"animate-spin rounded-full h-8 w-8 border-b-2 border-primary-600"})});const F=y?"pt-28":"pt-16";return a.jsxs("div",{children:[a.jsx(W,{title:"Schedule",icon:c,iconColor:"text-gray-600 dark:text-gray-400",count:l.length,totalCount:r==null?void 0:r.total,refreshing:s,autoRefreshEnabled:b,live:w,onAutoRefreshToggle:E,filters:f,onClearAllFilters:x}),a.jsxs("div",{className:`${F} space-y-4 transition-all duration-200`,children:[a.jsx($,{count:C,onClick:v,loading:s}),a.jsx(K,{columns:D,data:l,keyExtractor:e=>e.id,onRowClick:e=>t(`/schedule/${e.id}`),rowClassName:e=>S(e.id)?"highlight-new":"",emptyMessage:"No scheduled tasks recorded yet",emptyIcon:a.jsx(c,{className:"h-8 w-8 text-gray-400 dark:text-gray-500"})}),a.jsx(I,{hasMore:N,onClick:T,loading:s})]})]})}export{ee as default};
@@ -1 +1 @@
1
- import{j as h}from"./index-f3yHnTBu.js";import{D as _}from"./DetailRow-CR50H99O.js";function J(x){function j(t,l){return t<<l|t>>>32-l}function i(t,l){const a=(t&65535)+(l&65535);return(t>>16)+(l>>16)+(a>>16)<<16|a&65535}function E(t,l,a){return t&l|~t&a}function R(t,l,a){return t&a|l&~a}function T(t,l,a){return t^l^a}function M(t,l,a){return l^(t|~a)}function c(t,l,a,f,p,S,g){return t=i(t,i(i(E(l,a,f),p),g)),i(j(t,S),l)}function d(t,l,a,f,p,S,g){return t=i(t,i(i(R(l,a,f),p),g)),i(j(t,S),l)}function m(t,l,a,f,p,S,g){return t=i(t,i(i(T(l,a,f),p),g)),i(j(t,S),l)}function u(t,l,a,f,p,S,g){return t=i(t,i(i(M(l,a,f),p),g)),i(j(t,S),l)}function q(t){const l=[],a=t.length,f=a+8,S=((f-f%64)/64+1)*16;for(let b=0;b<S;b++)l[b]=0;let g=0,N=0;for(;N<a;){const b=(N-N%4)/4;g=N%4*8,l[b]=l[b]|t.charCodeAt(N)<<g,N++}const $=(N-N%4)/4;return g=N%4*8,l[$]=l[$]|128<<g,l[S-2]=a<<3,l[S-1]=a>>>29,l}function v(t){let l="";for(let a=0;a<=3;a++){const f=t>>>a*8&255;l+=("0"+f.toString(16)).slice(-2)}return l}const s=q(x);let e=1732584193,n=4023233417,r=2562383102,o=271733878;const w=7,y=12,W=17,C=22,A=5,U=9,k=14,D=20,B=4,G=11,H=16,I=23,O=6,F=10,L=15,P=21;for(let t=0;t<s.length;t+=16){const l=e,a=n,f=r,p=o;e=c(e,n,r,o,s[t+0],w,3614090360),o=c(o,e,n,r,s[t+1],y,3905402710),r=c(r,o,e,n,s[t+2],W,606105819),n=c(n,r,o,e,s[t+3],C,3250441966),e=c(e,n,r,o,s[t+4],w,4118548399),o=c(o,e,n,r,s[t+5],y,1200080426),r=c(r,o,e,n,s[t+6],W,2821735955),n=c(n,r,o,e,s[t+7],C,4249261313),e=c(e,n,r,o,s[t+8],w,1770035416),o=c(o,e,n,r,s[t+9],y,2336552879),r=c(r,o,e,n,s[t+10],W,4294925233),n=c(n,r,o,e,s[t+11],C,2304563134),e=c(e,n,r,o,s[t+12],w,1804603682),o=c(o,e,n,r,s[t+13],y,4254626195),r=c(r,o,e,n,s[t+14],W,2792965006),n=c(n,r,o,e,s[t+15],C,1236535329),e=d(e,n,r,o,s[t+1],A,4129170786),o=d(o,e,n,r,s[t+6],U,3225465664),r=d(r,o,e,n,s[t+11],k,643717713),n=d(n,r,o,e,s[t+0],D,3921069994),e=d(e,n,r,o,s[t+5],A,3593408605),o=d(o,e,n,r,s[t+10],U,38016083),r=d(r,o,e,n,s[t+15],k,3634488961),n=d(n,r,o,e,s[t+4],D,3889429448),e=d(e,n,r,o,s[t+9],A,568446438),o=d(o,e,n,r,s[t+14],U,3275163606),r=d(r,o,e,n,s[t+3],k,4107603335),n=d(n,r,o,e,s[t+8],D,1163531501),e=d(e,n,r,o,s[t+13],A,2850285829),o=d(o,e,n,r,s[t+2],U,4243563512),r=d(r,o,e,n,s[t+7],k,1735328473),n=d(n,r,o,e,s[t+12],D,2368359562),e=m(e,n,r,o,s[t+5],B,4294588738),o=m(o,e,n,r,s[t+8],G,2272392833),r=m(r,o,e,n,s[t+11],H,1839030562),n=m(n,r,o,e,s[t+14],I,4259657740),e=m(e,n,r,o,s[t+1],B,2763975236),o=m(o,e,n,r,s[t+4],G,1272893353),r=m(r,o,e,n,s[t+7],H,4139469664),n=m(n,r,o,e,s[t+10],I,3200236656),e=m(e,n,r,o,s[t+13],B,681279174),o=m(o,e,n,r,s[t+0],G,3936430074),r=m(r,o,e,n,s[t+3],H,3572445317),n=m(n,r,o,e,s[t+6],I,76029189),e=m(e,n,r,o,s[t+9],B,3654602809),o=m(o,e,n,r,s[t+12],G,3873151461),r=m(r,o,e,n,s[t+15],H,530742520),n=m(n,r,o,e,s[t+2],I,3299628645),e=u(e,n,r,o,s[t+0],O,4096336452),o=u(o,e,n,r,s[t+7],F,1126891415),r=u(r,o,e,n,s[t+14],L,2878612391),n=u(n,r,o,e,s[t+5],P,4237533241),e=u(e,n,r,o,s[t+12],O,1700485571),o=u(o,e,n,r,s[t+3],F,2399980690),r=u(r,o,e,n,s[t+10],L,4293915773),n=u(n,r,o,e,s[t+1],P,2240044497),e=u(e,n,r,o,s[t+8],O,1873313359),o=u(o,e,n,r,s[t+15],F,4264355552),r=u(r,o,e,n,s[t+6],L,2734768916),n=u(n,r,o,e,s[t+13],P,1309151649),e=u(e,n,r,o,s[t+4],O,4149444226),o=u(o,e,n,r,s[t+11],F,3174756917),r=u(r,o,e,n,s[t+2],L,718787259),n=u(n,r,o,e,s[t+9],P,3951481745),e=i(e,l),n=i(n,a),r=i(r,f),o=i(o,p)}return v(e)+v(n)+v(r)+v(o)}function K(x,j=80){return`https://www.gravatar.com/avatar/${J(x.toLowerCase().trim())}?d=identicon&s=${j}`}function X({user:x}){const j=x.email?K(x.email):null;return h.jsxs("div",{className:"card",children:[h.jsx("div",{className:"px-4 py-3 border-b border-gray-200 dark:border-gray-700",children:h.jsx("h2",{className:"text-lg font-semibold text-gray-900 dark:text-white",children:"Authenticated User"})}),h.jsx("div",{className:"p-4",children:h.jsxs("dl",{className:"divide-y-0",children:[h.jsx(_,{label:"ID",value:h.jsx("code",{className:"text-sm font-mono bg-gray-100 dark:bg-gray-800 px-2 py-0.5 rounded",children:String(x.id)})}),x.name&&h.jsx(_,{label:"Name",value:h.jsxs("span",{className:"flex items-center gap-2",children:[j&&h.jsx("img",{src:j,alt:x.name,className:"w-6 h-6 rounded-full"}),h.jsx("span",{children:x.name})]})}),x.email&&h.jsx(_,{label:"Email Address",value:h.jsx("a",{href:`mailto:${x.email}`,className:"text-indigo-600 dark:text-indigo-400 hover:underline",children:x.email})})]})})]})}export{X as U};
1
+ import{j as h}from"./index-B1QFrlfD.js";import{D as _}from"./DetailRow-D_sZP7WV.js";function J(x){function j(t,l){return t<<l|t>>>32-l}function i(t,l){const a=(t&65535)+(l&65535);return(t>>16)+(l>>16)+(a>>16)<<16|a&65535}function E(t,l,a){return t&l|~t&a}function R(t,l,a){return t&a|l&~a}function T(t,l,a){return t^l^a}function M(t,l,a){return l^(t|~a)}function c(t,l,a,f,p,S,g){return t=i(t,i(i(E(l,a,f),p),g)),i(j(t,S),l)}function d(t,l,a,f,p,S,g){return t=i(t,i(i(R(l,a,f),p),g)),i(j(t,S),l)}function m(t,l,a,f,p,S,g){return t=i(t,i(i(T(l,a,f),p),g)),i(j(t,S),l)}function u(t,l,a,f,p,S,g){return t=i(t,i(i(M(l,a,f),p),g)),i(j(t,S),l)}function q(t){const l=[],a=t.length,f=a+8,S=((f-f%64)/64+1)*16;for(let b=0;b<S;b++)l[b]=0;let g=0,N=0;for(;N<a;){const b=(N-N%4)/4;g=N%4*8,l[b]=l[b]|t.charCodeAt(N)<<g,N++}const $=(N-N%4)/4;return g=N%4*8,l[$]=l[$]|128<<g,l[S-2]=a<<3,l[S-1]=a>>>29,l}function v(t){let l="";for(let a=0;a<=3;a++){const f=t>>>a*8&255;l+=("0"+f.toString(16)).slice(-2)}return l}const s=q(x);let e=1732584193,n=4023233417,r=2562383102,o=271733878;const w=7,y=12,W=17,C=22,A=5,U=9,k=14,D=20,B=4,G=11,H=16,I=23,O=6,F=10,L=15,P=21;for(let t=0;t<s.length;t+=16){const l=e,a=n,f=r,p=o;e=c(e,n,r,o,s[t+0],w,3614090360),o=c(o,e,n,r,s[t+1],y,3905402710),r=c(r,o,e,n,s[t+2],W,606105819),n=c(n,r,o,e,s[t+3],C,3250441966),e=c(e,n,r,o,s[t+4],w,4118548399),o=c(o,e,n,r,s[t+5],y,1200080426),r=c(r,o,e,n,s[t+6],W,2821735955),n=c(n,r,o,e,s[t+7],C,4249261313),e=c(e,n,r,o,s[t+8],w,1770035416),o=c(o,e,n,r,s[t+9],y,2336552879),r=c(r,o,e,n,s[t+10],W,4294925233),n=c(n,r,o,e,s[t+11],C,2304563134),e=c(e,n,r,o,s[t+12],w,1804603682),o=c(o,e,n,r,s[t+13],y,4254626195),r=c(r,o,e,n,s[t+14],W,2792965006),n=c(n,r,o,e,s[t+15],C,1236535329),e=d(e,n,r,o,s[t+1],A,4129170786),o=d(o,e,n,r,s[t+6],U,3225465664),r=d(r,o,e,n,s[t+11],k,643717713),n=d(n,r,o,e,s[t+0],D,3921069994),e=d(e,n,r,o,s[t+5],A,3593408605),o=d(o,e,n,r,s[t+10],U,38016083),r=d(r,o,e,n,s[t+15],k,3634488961),n=d(n,r,o,e,s[t+4],D,3889429448),e=d(e,n,r,o,s[t+9],A,568446438),o=d(o,e,n,r,s[t+14],U,3275163606),r=d(r,o,e,n,s[t+3],k,4107603335),n=d(n,r,o,e,s[t+8],D,1163531501),e=d(e,n,r,o,s[t+13],A,2850285829),o=d(o,e,n,r,s[t+2],U,4243563512),r=d(r,o,e,n,s[t+7],k,1735328473),n=d(n,r,o,e,s[t+12],D,2368359562),e=m(e,n,r,o,s[t+5],B,4294588738),o=m(o,e,n,r,s[t+8],G,2272392833),r=m(r,o,e,n,s[t+11],H,1839030562),n=m(n,r,o,e,s[t+14],I,4259657740),e=m(e,n,r,o,s[t+1],B,2763975236),o=m(o,e,n,r,s[t+4],G,1272893353),r=m(r,o,e,n,s[t+7],H,4139469664),n=m(n,r,o,e,s[t+10],I,3200236656),e=m(e,n,r,o,s[t+13],B,681279174),o=m(o,e,n,r,s[t+0],G,3936430074),r=m(r,o,e,n,s[t+3],H,3572445317),n=m(n,r,o,e,s[t+6],I,76029189),e=m(e,n,r,o,s[t+9],B,3654602809),o=m(o,e,n,r,s[t+12],G,3873151461),r=m(r,o,e,n,s[t+15],H,530742520),n=m(n,r,o,e,s[t+2],I,3299628645),e=u(e,n,r,o,s[t+0],O,4096336452),o=u(o,e,n,r,s[t+7],F,1126891415),r=u(r,o,e,n,s[t+14],L,2878612391),n=u(n,r,o,e,s[t+5],P,4237533241),e=u(e,n,r,o,s[t+12],O,1700485571),o=u(o,e,n,r,s[t+3],F,2399980690),r=u(r,o,e,n,s[t+10],L,4293915773),n=u(n,r,o,e,s[t+1],P,2240044497),e=u(e,n,r,o,s[t+8],O,1873313359),o=u(o,e,n,r,s[t+15],F,4264355552),r=u(r,o,e,n,s[t+6],L,2734768916),n=u(n,r,o,e,s[t+13],P,1309151649),e=u(e,n,r,o,s[t+4],O,4149444226),o=u(o,e,n,r,s[t+11],F,3174756917),r=u(r,o,e,n,s[t+2],L,718787259),n=u(n,r,o,e,s[t+9],P,3951481745),e=i(e,l),n=i(n,a),r=i(r,f),o=i(o,p)}return v(e)+v(n)+v(r)+v(o)}function K(x,j=80){return`https://www.gravatar.com/avatar/${J(x.toLowerCase().trim())}?d=identicon&s=${j}`}function X({user:x}){const j=x.email?K(x.email):null;return h.jsxs("div",{className:"card",children:[h.jsx("div",{className:"px-4 py-3 border-b border-gray-200 dark:border-gray-700",children:h.jsx("h2",{className:"text-lg font-semibold text-gray-900 dark:text-white",children:"Authenticated User"})}),h.jsx("div",{className:"p-4",children:h.jsxs("dl",{className:"divide-y-0",children:[h.jsx(_,{label:"ID",value:h.jsx("code",{className:"text-sm font-mono bg-gray-100 dark:bg-gray-800 px-2 py-0.5 rounded",children:String(x.id)})}),x.name&&h.jsx(_,{label:"Name",value:h.jsxs("span",{className:"flex items-center gap-2",children:[j&&h.jsx("img",{src:j,alt:x.name,className:"w-6 h-6 rounded-full"}),h.jsx("span",{children:x.name})]})}),x.email&&h.jsx(_,{label:"Email Address",value:h.jsx("a",{href:`mailto:${x.email}`,className:"text-indigo-600 dark:text-indigo-400 hover:underline",children:x.email})})]})})]})}export{X as U};
@@ -1 +1 @@
1
- import{j as e,F as p,C as h}from"./index-f3yHnTBu.js";import{p as i,f as j}from"./badgeColors-DQ_P_DOX.js";import{D as s,f as g}from"./DetailRow-CR50H99O.js";import{C as c}from"./types-DZrHs5Iv.js";import{u as b,C as f,T as N}from"./EntryDetailPage-jW_ZykXS.js";import{C as u}from"./CopyButton-DkKluR16.js";import{E as o}from"./eye-BEruVuaB.js";import{C as y}from"./circle-check-big-ebbAguBz.js";import{C as x}from"./circle-x-CJZEsYDL.js";import"./vendor-DBTT3jXp.js";import"./search-B0XZ1Fr6.js";function M({entry:n}){const{payload:a,createdAt:d}=n,r=b(),t=a.status==="rendered"?{icon:y,color:"text-green-500",bg:"bg-green-100 dark:bg-green-900/30"}:{icon:x,color:"text-red-500",bg:"bg-red-100 dark:bg-red-900/30"},m=t.icon,l=[];return a.locals!==void 0&&l.push({id:"locals",label:"Locals",content:e.jsx(f,{data:a.locals,toolbarState:r.state,searchBar:r.SearchBar,maxHeight:400})}),e.jsxs("div",{className:"space-y-6",children:[e.jsxs("div",{className:"card",children:[e.jsx("div",{className:"p-4 border-b border-gray-200 dark:border-gray-700",children:e.jsxs("div",{className:"flex items-center justify-between",children:[e.jsxs("div",{className:"flex items-center space-x-3",children:[e.jsx("div",{className:`p-2 ${t.bg} rounded-lg`,children:e.jsx(o,{className:`h-5 w-5 ${t.color}`})}),e.jsxs("div",{children:[e.jsx("h2",{className:"text-lg font-semibold text-gray-900 dark:text-white font-mono",children:a.template}),e.jsx("p",{className:"text-sm text-gray-500 dark:text-gray-400",children:"View Render"})]})]}),e.jsx(u,{text:a.template,label:"Copy template"})]})}),e.jsxs("div",{className:"grid grid-cols-2 md:grid-cols-4 divide-x divide-gray-200 dark:divide-gray-700",children:[e.jsxs("div",{className:"p-4",children:[e.jsxs("div",{className:"flex items-center space-x-2 text-gray-500 dark:text-gray-400 mb-1",children:[e.jsx(p,{className:"h-4 w-4"}),e.jsx("span",{className:"text-xs uppercase tracking-wider",children:"Format"})]}),e.jsx("p",{className:"text-lg font-bold text-gray-900 dark:text-white font-mono",children:a.format||"HTML"})]}),e.jsxs("div",{className:"p-4",children:[e.jsxs("div",{className:"flex items-center space-x-2 text-gray-500 dark:text-gray-400 mb-1",children:[e.jsx(m,{className:"h-4 w-4"}),e.jsx("span",{className:"text-xs uppercase tracking-wider",children:"Status"})]}),e.jsx("p",{className:`text-lg font-bold ${t.color}`,children:a.status.toUpperCase()})]}),e.jsxs("div",{className:"p-4",children:[e.jsxs("div",{className:"flex items-center space-x-2 text-gray-500 dark:text-gray-400 mb-1",children:[e.jsx(h,{className:"h-4 w-4"}),e.jsx("span",{className:"text-xs uppercase tracking-wider",children:"Duration"})]}),e.jsxs("p",{className:"text-lg font-bold text-gray-900 dark:text-white",children:[a.duration,e.jsx("span",{className:"text-sm font-normal text-gray-500 dark:text-gray-400",children:"ms"})]})]}),e.jsxs("div",{className:"p-4",children:[e.jsxs("div",{className:"flex items-center space-x-2 text-gray-500 dark:text-gray-400 mb-1",children:[e.jsx(o,{className:"h-4 w-4"}),e.jsx("span",{className:"text-xs uppercase tracking-wider",children:"Cache"})]}),e.jsx("p",{className:"text-lg font-bold text-gray-900 dark:text-white",children:a.cacheHit?"Yes":"No"})]})]})]}),e.jsxs("div",{className:"card",children:[e.jsx("div",{className:"px-4 py-3 border-b border-gray-200 dark:border-gray-700",children:e.jsx("h2",{className:"text-lg font-semibold text-gray-900 dark:text-white",children:"Details"})}),e.jsx("div",{className:"p-4",children:e.jsxs("dl",{className:"divide-y-0",children:[e.jsx(s,{label:"Time",value:e.jsxs("span",{children:[g(i(d),"MMMM do yyyy, h:mm:ss a")," ",e.jsxs("span",{className:"text-gray-500 dark:text-gray-400",children:["(",j(i(d),{addSuffix:!0}),")"]})]})}),e.jsx(s,{label:"Template",value:e.jsx("code",{className:"text-sm font-mono text-gray-900 dark:text-white",children:a.template})}),a.format&&e.jsx(s,{label:"Format",value:e.jsx(c,{listType:"views",filterType:"formats",filterValue:a.format,children:a.format})}),e.jsx(s,{label:"Status",value:e.jsx(c,{listType:"views",filterType:"statuses",filterValue:a.status,children:a.status.toUpperCase()})}),e.jsx(s,{label:"Duration",value:`${a.duration}ms`}),a.cacheHit!==void 0&&e.jsx(s,{label:"Cached",value:a.cacheHit?"Yes":"No"}),a.dataSize!==void 0&&e.jsx(s,{label:"Data Size",value:`${a.dataSize} bytes`}),a.outputSize!==void 0&&e.jsx(s,{label:"Output Size",value:`${a.outputSize} bytes`})]})})]}),a.error&&e.jsxs("div",{className:"card border-red-200 dark:border-red-800",children:[e.jsx("div",{className:"px-4 py-3 border-b border-red-200 dark:border-red-800 bg-red-50 dark:bg-red-900/20",children:e.jsxs("div",{className:"flex items-center space-x-2",children:[e.jsx(x,{className:"h-5 w-5 text-red-500"}),e.jsx("h2",{className:"text-lg font-semibold text-red-700 dark:text-red-400",children:"Error"})]})}),e.jsx("div",{className:"p-4 bg-red-50/50 dark:bg-red-900/10",children:e.jsx("pre",{className:"text-sm text-red-600 dark:text-red-400 font-mono whitespace-pre-wrap overflow-x-auto",children:a.error})})]}),l.length>0&&e.jsx(N,{tabs:l,defaultTab:"locals",hashKey:"view",headerRight:a.locals!==void 0?e.jsx(r.Toolbar,{data:a.locals}):void 0})]})}export{M as default};
1
+ import{j as e,F as p,C as h}from"./index-B1QFrlfD.js";import{p as i,f as j}from"./badgeColors-DQ_P_DOX.js";import{D as s,f as g}from"./DetailRow-D_sZP7WV.js";import{C as c}from"./types-DwzjtRI3.js";import{u as b,C as f,T as N}from"./EntryDetailPage-D7qvNuMn.js";import{C as u}from"./CopyButton-YkpN9Yi5.js";import{E as o}from"./eye-DWj2WfH_.js";import{C as y}from"./circle-check-big-B6oE8hF5.js";import{C as x}from"./circle-x-Ch0JMytg.js";import"./vendor-DBTT3jXp.js";import"./search-n3qpR8sp.js";function M({entry:n}){const{payload:a,createdAt:d}=n,r=b(),t=a.status==="rendered"?{icon:y,color:"text-green-500",bg:"bg-green-100 dark:bg-green-900/30"}:{icon:x,color:"text-red-500",bg:"bg-red-100 dark:bg-red-900/30"},m=t.icon,l=[];return a.locals!==void 0&&l.push({id:"locals",label:"Locals",content:e.jsx(f,{data:a.locals,toolbarState:r.state,searchBar:r.SearchBar,maxHeight:400})}),e.jsxs("div",{className:"space-y-6",children:[e.jsxs("div",{className:"card",children:[e.jsx("div",{className:"p-4 border-b border-gray-200 dark:border-gray-700",children:e.jsxs("div",{className:"flex items-center justify-between",children:[e.jsxs("div",{className:"flex items-center space-x-3",children:[e.jsx("div",{className:`p-2 ${t.bg} rounded-lg`,children:e.jsx(o,{className:`h-5 w-5 ${t.color}`})}),e.jsxs("div",{children:[e.jsx("h2",{className:"text-lg font-semibold text-gray-900 dark:text-white font-mono",children:a.template}),e.jsx("p",{className:"text-sm text-gray-500 dark:text-gray-400",children:"View Render"})]})]}),e.jsx(u,{text:a.template,label:"Copy template"})]})}),e.jsxs("div",{className:"grid grid-cols-2 md:grid-cols-4 divide-x divide-gray-200 dark:divide-gray-700",children:[e.jsxs("div",{className:"p-4",children:[e.jsxs("div",{className:"flex items-center space-x-2 text-gray-500 dark:text-gray-400 mb-1",children:[e.jsx(p,{className:"h-4 w-4"}),e.jsx("span",{className:"text-xs uppercase tracking-wider",children:"Format"})]}),e.jsx("p",{className:"text-lg font-bold text-gray-900 dark:text-white font-mono",children:a.format||"HTML"})]}),e.jsxs("div",{className:"p-4",children:[e.jsxs("div",{className:"flex items-center space-x-2 text-gray-500 dark:text-gray-400 mb-1",children:[e.jsx(m,{className:"h-4 w-4"}),e.jsx("span",{className:"text-xs uppercase tracking-wider",children:"Status"})]}),e.jsx("p",{className:`text-lg font-bold ${t.color}`,children:a.status.toUpperCase()})]}),e.jsxs("div",{className:"p-4",children:[e.jsxs("div",{className:"flex items-center space-x-2 text-gray-500 dark:text-gray-400 mb-1",children:[e.jsx(h,{className:"h-4 w-4"}),e.jsx("span",{className:"text-xs uppercase tracking-wider",children:"Duration"})]}),e.jsxs("p",{className:"text-lg font-bold text-gray-900 dark:text-white",children:[a.duration,e.jsx("span",{className:"text-sm font-normal text-gray-500 dark:text-gray-400",children:"ms"})]})]}),e.jsxs("div",{className:"p-4",children:[e.jsxs("div",{className:"flex items-center space-x-2 text-gray-500 dark:text-gray-400 mb-1",children:[e.jsx(o,{className:"h-4 w-4"}),e.jsx("span",{className:"text-xs uppercase tracking-wider",children:"Cache"})]}),e.jsx("p",{className:"text-lg font-bold text-gray-900 dark:text-white",children:a.cacheHit?"Yes":"No"})]})]})]}),e.jsxs("div",{className:"card",children:[e.jsx("div",{className:"px-4 py-3 border-b border-gray-200 dark:border-gray-700",children:e.jsx("h2",{className:"text-lg font-semibold text-gray-900 dark:text-white",children:"Details"})}),e.jsx("div",{className:"p-4",children:e.jsxs("dl",{className:"divide-y-0",children:[e.jsx(s,{label:"Time",value:e.jsxs("span",{children:[g(i(d),"MMMM do yyyy, h:mm:ss a")," ",e.jsxs("span",{className:"text-gray-500 dark:text-gray-400",children:["(",j(i(d),{addSuffix:!0}),")"]})]})}),e.jsx(s,{label:"Template",value:e.jsx("code",{className:"text-sm font-mono text-gray-900 dark:text-white",children:a.template})}),a.format&&e.jsx(s,{label:"Format",value:e.jsx(c,{listType:"views",filterType:"formats",filterValue:a.format,children:a.format})}),e.jsx(s,{label:"Status",value:e.jsx(c,{listType:"views",filterType:"statuses",filterValue:a.status,children:a.status.toUpperCase()})}),e.jsx(s,{label:"Duration",value:`${a.duration}ms`}),a.cacheHit!==void 0&&e.jsx(s,{label:"Cached",value:a.cacheHit?"Yes":"No"}),a.dataSize!==void 0&&e.jsx(s,{label:"Data Size",value:`${a.dataSize} bytes`}),a.outputSize!==void 0&&e.jsx(s,{label:"Output Size",value:`${a.outputSize} bytes`})]})})]}),a.error&&e.jsxs("div",{className:"card border-red-200 dark:border-red-800",children:[e.jsx("div",{className:"px-4 py-3 border-b border-red-200 dark:border-red-800 bg-red-50 dark:bg-red-900/20",children:e.jsxs("div",{className:"flex items-center space-x-2",children:[e.jsx(x,{className:"h-5 w-5 text-red-500"}),e.jsx("h2",{className:"text-lg font-semibold text-red-700 dark:text-red-400",children:"Error"})]})}),e.jsx("div",{className:"p-4 bg-red-50/50 dark:bg-red-900/10",children:e.jsx("pre",{className:"text-sm text-red-600 dark:text-red-400 font-mono whitespace-pre-wrap overflow-x-auto",children:a.error})})]}),l.length>0&&e.jsx(N,{tabs:l,defaultTab:"locals",hashKey:"view",headerRight:a.locals!==void 0?e.jsx(r.Toolbar,{data:a.locals}):void 0})]})}export{M as default};
@@ -1 +1 @@
1
- import{j as t}from"./index-f3yHnTBu.js";import{e as P,b as T}from"./vendor-DBTT3jXp.js";import{f as D,p as A}from"./badgeColors-DQ_P_DOX.js";import{u as M,P as R,N as H,L as B}from"./PageHeader-Ce9Hbh0m.js";import{u as L,n as V,C as l}from"./types-DZrHs5Iv.js";import{T as r,D as S,b as W}from"./DataTable-CQVsrmrF.js";import{E as d}from"./eye-BEruVuaB.js";function J(){const c=P(),{addFilter:s,clearAll:h,serverFilters:m,headerFilters:u,hasFilters:p}=L("views"),{entries:x,loading:g,refreshing:i,newEntriesCount:f,hasMore:y,loadMore:w,loadNew:j,autoRefreshEnabled:C,live:k,setAutoRefresh:N,meta:o,isHighlighted:v}=M({type:"view",limit:50,filters:m}),n=x.filter(e=>V(e)),E=T.useMemo(()=>[{key:"template",header:"Template",minWidth:"250px",render:e=>t.jsx(r,{mono:!0,truncate:!0,maxWidth:"350px",children:e.payload.template})},{key:"format",header:"Format",width:"100px",render:e=>{const a=e.payload.format;return a?t.jsx(l,{onClick:F=>{F.stopPropagation(),s("formats",a)},className:"font-mono",children:a}):t.jsx(r,{secondary:!0,children:"-"})}},{key:"duration",header:"Duration",width:"100px",align:"right",render:e=>t.jsx(S,{ms:e.payload.duration||0})},{key:"status",header:"Status",width:"100px",render:e=>t.jsx(l,{onClick:a=>{a.stopPropagation(),s("statuses",e.payload.status)},children:e.payload.status.toUpperCase()})},{key:"cache",header:"Cache",width:"80px",align:"center",render:e=>e.payload.cacheHit!==void 0?t.jsx(r,{children:e.payload.cacheHit?"Yes":"No"}):t.jsx(r,{secondary:!0,children:"-"})},{key:"time",header:"Time",width:"170px",align:"right",render:e=>t.jsx(r,{secondary:!0,className:"text-xs",children:D(A(e.createdAt),{addSuffix:!0})})}],[s]);if(g&&n.length===0)return t.jsx("div",{className:"flex items-center justify-center h-64",role:"status","aria-label":"Loading...",children:t.jsx("div",{className:"animate-spin rounded-full h-8 w-8 border-b-2 border-primary-600"})});const b=p?"pt-28":"pt-16";return t.jsxs("div",{children:[t.jsx(R,{title:"Views",icon:d,iconColor:"text-teal-600 dark:text-teal-400",count:n.length,totalCount:o==null?void 0:o.total,refreshing:i,autoRefreshEnabled:C,live:k,onAutoRefreshToggle:N,filters:u,onClearAllFilters:h}),t.jsxs("div",{className:`${b} space-y-4 transition-all duration-200`,children:[t.jsx(H,{count:f,onClick:j,loading:i}),t.jsx(W,{columns:E,data:n,keyExtractor:e=>e.id,onRowClick:e=>c(`/views/${e.id}`),rowClassName:e=>v(e.id)?"highlight-new":"",emptyMessage:"No view renders recorded yet",emptyIcon:t.jsx(d,{className:"h-8 w-8 text-gray-400 dark:text-gray-500"})}),t.jsx(B,{hasMore:y,onClick:w,loading:i})]})]})}export{J as default};
1
+ import{j as t}from"./index-B1QFrlfD.js";import{e as P,b as T}from"./vendor-DBTT3jXp.js";import{f as D,p as A}from"./badgeColors-DQ_P_DOX.js";import{u as M,P as R,N as H,L as B}from"./PageHeader-BQ2bLFIt.js";import{u as L,n as V,C as l}from"./types-DwzjtRI3.js";import{T as r,D as S,b as W}from"./DataTable-C9UKN_wr.js";import{E as d}from"./eye-DWj2WfH_.js";function J(){const c=P(),{addFilter:s,clearAll:h,serverFilters:m,headerFilters:u,hasFilters:p}=L("views"),{entries:x,loading:g,refreshing:i,newEntriesCount:f,hasMore:y,loadMore:w,loadNew:j,autoRefreshEnabled:C,live:k,setAutoRefresh:N,meta:o,isHighlighted:v}=M({type:"view",limit:50,filters:m}),n=x.filter(e=>V(e)),E=T.useMemo(()=>[{key:"template",header:"Template",minWidth:"250px",render:e=>t.jsx(r,{mono:!0,truncate:!0,maxWidth:"350px",children:e.payload.template})},{key:"format",header:"Format",width:"100px",render:e=>{const a=e.payload.format;return a?t.jsx(l,{onClick:F=>{F.stopPropagation(),s("formats",a)},className:"font-mono",children:a}):t.jsx(r,{secondary:!0,children:"-"})}},{key:"duration",header:"Duration",width:"100px",align:"right",render:e=>t.jsx(S,{ms:e.payload.duration||0})},{key:"status",header:"Status",width:"100px",render:e=>t.jsx(l,{onClick:a=>{a.stopPropagation(),s("statuses",e.payload.status)},children:e.payload.status.toUpperCase()})},{key:"cache",header:"Cache",width:"80px",align:"center",render:e=>e.payload.cacheHit!==void 0?t.jsx(r,{children:e.payload.cacheHit?"Yes":"No"}):t.jsx(r,{secondary:!0,children:"-"})},{key:"time",header:"Time",width:"170px",align:"right",render:e=>t.jsx(r,{secondary:!0,className:"text-xs",children:D(A(e.createdAt),{addSuffix:!0})})}],[s]);if(g&&n.length===0)return t.jsx("div",{className:"flex items-center justify-center h-64",role:"status","aria-label":"Loading...",children:t.jsx("div",{className:"animate-spin rounded-full h-8 w-8 border-b-2 border-primary-600"})});const b=p?"pt-28":"pt-16";return t.jsxs("div",{children:[t.jsx(R,{title:"Views",icon:d,iconColor:"text-teal-600 dark:text-teal-400",count:n.length,totalCount:o==null?void 0:o.total,refreshing:i,autoRefreshEnabled:C,live:k,onAutoRefreshToggle:N,filters:u,onClearAllFilters:h}),t.jsxs("div",{className:`${b} space-y-4 transition-all duration-200`,children:[t.jsx(H,{count:f,onClick:j,loading:i}),t.jsx(W,{columns:E,data:n,keyExtractor:e=>e.id,onRowClick:e=>c(`/views/${e.id}`),rowClassName:e=>v(e.id)?"highlight-new":"",emptyMessage:"No view renders recorded yet",emptyIcon:t.jsx(d,{className:"h-8 w-8 text-gray-400 dark:text-gray-500"})}),t.jsx(B,{hasMore:y,onClick:w,loading:i})]})]})}export{J as default};
@@ -1,4 +1,4 @@
1
- import{c as e}from"./index-f3yHnTBu.js";/**
1
+ import{c as e}from"./index-B1QFrlfD.js";/**
2
2
  * @license lucide-react v0.468.0 - ISC
3
3
  *
4
4
  * This source code is licensed under the ISC license.
@@ -1,4 +1,4 @@
1
- import{c as e}from"./index-f3yHnTBu.js";/**
1
+ import{c as e}from"./index-B1QFrlfD.js";/**
2
2
  * @license lucide-react v0.468.0 - ISC
3
3
  *
4
4
  * This source code is licensed under the ISC license.
@@ -1,4 +1,4 @@
1
- import{c}from"./index-f3yHnTBu.js";/**
1
+ import{c}from"./index-B1QFrlfD.js";/**
2
2
  * @license lucide-react v0.468.0 - ISC
3
3
  *
4
4
  * This source code is licensed under the ISC license.
@@ -1,4 +1,4 @@
1
- import{c}from"./index-f3yHnTBu.js";/**
1
+ import{c}from"./index-B1QFrlfD.js";/**
2
2
  * @license lucide-react v0.468.0 - ISC
3
3
  *
4
4
  * This source code is licensed under the ISC license.
@@ -1,4 +1,4 @@
1
- import{c}from"./index-f3yHnTBu.js";/**
1
+ import{c}from"./index-B1QFrlfD.js";/**
2
2
  * @license lucide-react v0.468.0 - ISC
3
3
  *
4
4
  * This source code is licensed under the ISC license.
@@ -1,4 +1,4 @@
1
- const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["./DashboardPage-DMggZXZm.js","./vendor-DBTT3jXp.js","./badgeColors-DQ_P_DOX.js","./zap-C4mgfWMp.js","./calendar-DHSpyI4Y.js","./RequestsPage-DzT18Gb7.js","./PageHeader-Ce9Hbh0m.js","./types-DZrHs5Iv.js","./EntrySearchInput-DRSpv1XV.js","./search-B0XZ1Fr6.js","./DataTable-CQVsrmrF.js","./QueriesPage-sxyFCofb.js","./ExceptionsPage-BP0Omwzc.js","./circle-check-big-ebbAguBz.js","./LogsPage-DCO8kMBG.js","./EventsPage-BGCQccD5.js","./JobsPage-BtHUaYit.js","./CachePage-sSG3fOH-.js","./MailPage-yMJfR2pc.js","./SchedulePage-DpUQnTKK.js","./format-BlNP-apw.js","./HttpClientPage-Dc4CyjM2.js","./RedisPage-CJTBRYRA.js","./ModelsPage-DjLplWf-.js","./NotificationsPage-Dw_KBVVy.js","./ViewsPage-BrVbaxmk.js","./eye-BEruVuaB.js","./CommandsPage-DGSwYx1i.js","./GatesPage-BQrbIY_I.js","./BatchesPage-B4mRZv-7.js","./DumpsPage-BFejJT0i.js","./GraphQLPage-DdXPF_EJ.js","./EntryDetailPage-jW_ZykXS.js"])))=>i.map(i=>d[i]);
1
+ const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["./DashboardPage-DdaOxHZ2.js","./vendor-DBTT3jXp.js","./badgeColors-DQ_P_DOX.js","./zap-C7m34sPr.js","./calendar-gUrKMEEq.js","./RequestsPage-D9KghDZ-.js","./PageHeader-BQ2bLFIt.js","./types-DwzjtRI3.js","./EntrySearchInput-DeOYz9h4.js","./search-n3qpR8sp.js","./DataTable-C9UKN_wr.js","./QueriesPage-Plp4pZSN.js","./ExceptionsPage-KuyeMrqK.js","./circle-check-big-B6oE8hF5.js","./LogsPage-6dDP3Pu_.js","./EventsPage-O1icFuRw.js","./JobsPage-DyiOLpB1.js","./CachePage-Ce_yT75F.js","./MailPage-tBhdhWmz.js","./SchedulePage-B3mUO2Ng.js","./format-BlNP-apw.js","./HttpClientPage-qC_nBzq2.js","./RedisPage-CS2bcK-q.js","./ModelsPage-BTLkoWRR.js","./NotificationsPage-BOPuEc8u.js","./ViewsPage-BhlcyTU3.js","./eye-DWj2WfH_.js","./CommandsPage-BwMh373Z.js","./GatesPage-BKLfGgS9.js","./BatchesPage-C5asqolh.js","./DumpsPage-BrYuIT5U.js","./GraphQLPage-BqkJnBEt.js","./EntryDetailPage-D7qvNuMn.js"])))=>i.map(i=>d[i]);
2
2
  var Pe=Object.defineProperty;var Ce=(s,a,e)=>a in s?Pe(s,a,{enumerable:!0,configurable:!0,writable:!0,value:e}):s[a]=e;var z=(s,a,e)=>Ce(s,typeof a!="symbol"?a+"":a,e);import{r as Re,a as Le,g as Te,b as r,u as Ae,L as D,O as Oe,R as De,c as p,N as Me,d as qe,B as $e}from"./vendor-DBTT3jXp.js";(function(){const a=document.createElement("link").relList;if(a&&a.supports&&a.supports("modulepreload"))return;for(const l of document.querySelectorAll('link[rel="modulepreload"]'))i(l);new MutationObserver(l=>{for(const o of l)if(o.type==="childList")for(const n of o.addedNodes)n.tagName==="LINK"&&n.rel==="modulepreload"&&i(n)}).observe(document,{childList:!0,subtree:!0});function e(l){const o={};return l.integrity&&(o.integrity=l.integrity),l.referrerPolicy&&(o.referrerPolicy=l.referrerPolicy),l.crossOrigin==="use-credentials"?o.credentials="include":l.crossOrigin==="anonymous"?o.credentials="omit":o.credentials="same-origin",o}function i(l){if(l.ep)return;l.ep=!0;const o=e(l);fetch(l.href,o)}})();var G={exports:{}},M={};/**
3
3
  * @license React
4
4
  * react-jsx-runtime.production.min.js
@@ -358,4 +358,4 @@ to {
358
358
  *
359
359
  * This source code is licensed under the ISC license.
360
360
  * See the LICENSE file in the root directory of this source tree.
361
- */const rs=g("X",[["path",{d:"M18 6 6 18",key:"1bl5f8"}],["path",{d:"m6 6 12 12",key:"d8bk6v"}]]),we=()=>window.__NESTLENS_BASE__??"",ns=s=>`${window.location.origin}${we()}/__nestlens__${s}`,Se=ns("/api");async function P(s,a){const e=await fetch(`${Se}${s}`,a);if(!e.ok)throw new Error(`API error: ${e.status}`);return e.json()}async function $s(s){return P(`/entries/${s}`)}async function ce(){return P("/stats")}async function os(){return(await fetch(`${Se}/entries`,{method:"DELETE"})).json()}async function zs(s){const a=new URLSearchParams;if(s.type&&a.set("type",s.type),s.limit&&a.set("limit",s.limit.toString()),s.beforeSequence!==void 0&&a.set("beforeSequence",s.beforeSequence.toString()),s.afterSequence!==void 0&&a.set("afterSequence",s.afterSequence.toString()),s.filters){const e=s.filters;e.levels&&e.levels.length>0&&a.set("levels",e.levels.join(",")),e.contexts&&e.contexts.length>0&&a.set("contexts",e.contexts.join(",")),e.queryTypes&&e.queryTypes.length>0&&a.set("queryTypes",e.queryTypes.join(",")),e.sources&&e.sources.length>0&&a.set("sources",e.sources.join(",")),e.slow!==void 0&&a.set("slow",e.slow.toString()),e.names&&e.names.length>0&&a.set("names",e.names.join(",")),e.methods&&e.methods.length>0&&a.set("methods",e.methods.join(",")),e.paths&&e.paths.length>0&&a.set("paths",e.paths.join(",")),e.resolved!==void 0&&a.set("resolved",e.resolved.toString()),e.statuses&&e.statuses.length>0&&a.set("statuses",e.statuses.join(",")),e.hostnames&&e.hostnames.length>0&&a.set("hostnames",e.hostnames.join(",")),e.controllers&&e.controllers.length>0&&a.set("controllers",e.controllers.join(",")),e.ips&&e.ips.length>0&&a.set("ips",e.ips.join(",")),e.eventNames&&e.eventNames.length>0&&a.set("eventNames",e.eventNames.join(",")),e.scheduleStatuses&&e.scheduleStatuses.length>0&&a.set("scheduleStatuses",e.scheduleStatuses.join(",")),e.scheduleNames&&e.scheduleNames.length>0&&a.set("scheduleNames",e.scheduleNames.join(",")),e.jobStatuses&&e.jobStatuses.length>0&&a.set("jobStatuses",e.jobStatuses.join(",")),e.jobNames&&e.jobNames.length>0&&a.set("jobNames",e.jobNames.join(",")),e.queues&&e.queues.length>0&&a.set("queues",e.queues.join(",")),e.cacheOperations&&e.cacheOperations.length>0&&a.set("cacheOperations",e.cacheOperations.join(",")),e.mailStatuses&&e.mailStatuses.length>0&&a.set("mailStatuses",e.mailStatuses.join(",")),e.redisStatuses&&e.redisStatuses.length>0&&a.set("redisStatuses",e.redisStatuses.join(",")),e.redisCommands&&e.redisCommands.length>0&&a.set("redisCommands",e.redisCommands.join(",")),e.modelActions&&e.modelActions.length>0&&a.set("modelActions",e.modelActions.join(",")),e.entities&&e.entities.length>0&&a.set("entities",e.entities.join(",")),e.modelSources&&e.modelSources.length>0&&a.set("modelSources",e.modelSources.join(",")),e.notificationTypes&&e.notificationTypes.length>0&&a.set("notificationTypes",e.notificationTypes.join(",")),e.notificationStatuses&&e.notificationStatuses.length>0&&a.set("notificationStatuses",e.notificationStatuses.join(",")),e.viewFormats&&e.viewFormats.length>0&&a.set("viewFormats",e.viewFormats.join(",")),e.viewStatuses&&e.viewStatuses.length>0&&a.set("viewStatuses",e.viewStatuses.join(",")),e.commandStatuses&&e.commandStatuses.length>0&&a.set("commandStatuses",e.commandStatuses.join(",")),e.commandNames&&e.commandNames.length>0&&a.set("commandNames",e.commandNames.join(",")),e.gateNames&&e.gateNames.length>0&&a.set("gateNames",e.gateNames.join(",")),e.gateResults&&e.gateResults.length>0&&a.set("gateResults",e.gateResults.join(",")),e.batchStatuses&&e.batchStatuses.length>0&&a.set("batchStatuses",e.batchStatuses.join(",")),e.batchOperations&&e.batchOperations.length>0&&a.set("batchOperations",e.batchOperations.join(",")),e.dumpStatuses&&e.dumpStatuses.length>0&&a.set("dumpStatuses",e.dumpStatuses.join(",")),e.dumpOperations&&e.dumpOperations.length>0&&a.set("dumpOperations",e.dumpOperations.join(",")),e.dumpFormats&&e.dumpFormats.length>0&&a.set("dumpFormats",e.dumpFormats.join(",")),e.operationTypes&&e.operationTypes.length>0&&a.set("operationTypes",e.operationTypes.join(",")),e.operationNames&&e.operationNames.length>0&&a.set("operationNames",e.operationNames.join(",")),e.hasErrors!==void 0&&a.set("hasErrors",e.hasErrors.toString()),e.hasN1!==void 0&&a.set("hasN1",e.hasN1.toString()),e.tags&&e.tags.length>0&&a.set("tags",e.tags.join(",")),e.search&&a.set("search",e.search)}return P(`/entries/cursor?${a.toString()}`)}async function Is(s){const a=new URLSearchParams;return s&&a.set("type",s),P(`/entries/latest-sequence?${a.toString()}`)}async function Ks(s,a){const e=new URLSearchParams;return e.set("afterSequence",s.toString()),a&&e.set("type",a),P(`/entries/check-new?${e.toString()}`)}async function Vs(){return P("/storage/stats")}async function Bs(){return P("/pruning/status")}async function Fs(){return P("/pruning/run",{method:"POST"})}async function Hs(s){return P(`/entries/${s}/resolve`,{method:"PATCH"})}async function Gs(s){return P(`/entries/${s}/unresolve`,{method:"PATCH"})}async function is(s){return P("/recording/pause",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({reason:s})})}async function ls(){return P("/recording/resume",{method:"POST"})}async function cs(){return P("/recording/status")}function ds(s){const a=r.useCallback(e=>{const i=e.target,l=i.tagName==="INPUT"||i.tagName==="TEXTAREA"||i.isContentEditable;for(const o of s){const{key:n,ctrl:c,meta:u,shift:x,alt:d,handler:h,preventDefault:y=!0}=o;if(l&&n.toLowerCase()!=="escape")continue;const j=e.key.toLowerCase()===n.toLowerCase(),k=x?e.shiftKey:!e.shiftKey,m=d?e.altKey:!e.altKey;if(c){if((e.ctrlKey||e.metaKey)&&j&&k&&m){y&&e.preventDefault(),h(e);return}continue}if(u){if(e.metaKey&&!e.ctrlKey&&j&&k&&m){y&&e.preventDefault(),h(e);return}continue}if(!e.ctrlKey&&!e.metaKey&&j&&k&&m){y&&e.preventDefault(),h(e);return}}},[s]);r.useEffect(()=>(document.addEventListener("keydown",a),()=>{document.removeEventListener("keydown",a)}),[a])}class _e extends r.Component{constructor(){super(...arguments);z(this,"state",{hasError:!1});z(this,"handleReload",()=>{window.location.reload()});z(this,"handleReset",()=>{this.setState({hasError:!1,error:void 0,errorInfo:void 0})})}static getDerivedStateFromError(e){return{hasError:!0,error:e}}componentDidCatch(e,i){console.error("ErrorBoundary caught an error:",e,i),this.setState({errorInfo:i})}render(){return this.state.hasError?this.props.fallback?this.props.fallback:t.jsx("div",{className:"min-h-screen flex items-center justify-center bg-gray-50 dark:bg-gray-900 p-4",children:t.jsxs("div",{className:"max-w-md w-full bg-white dark:bg-gray-800 rounded-lg shadow-lg p-6 text-center",children:[t.jsx("div",{className:"mx-auto w-12 h-12 flex items-center justify-center rounded-full bg-red-100 dark:bg-red-900/30 mb-4",children:t.jsx(ve,{className:"h-6 w-6 text-red-600 dark:text-red-400"})}),t.jsx("h1",{className:"text-xl font-semibold text-gray-900 dark:text-white mb-2",children:"Something went wrong"}),t.jsx("p",{className:"text-gray-600 dark:text-gray-400 mb-4",children:"An unexpected error occurred. Please try refreshing the page."}),this.state.error&&t.jsx("div",{className:"mb-4 p-3 bg-red-50 dark:bg-red-900/20 rounded-lg text-left",children:t.jsx("p",{className:"text-sm font-mono text-red-600 dark:text-red-400 break-all",children:this.state.error.message})}),t.jsxs("div",{className:"flex gap-3 justify-center",children:[t.jsx("button",{onClick:this.handleReset,className:"px-4 py-2 text-sm font-medium text-gray-700 dark:text-gray-300 bg-gray-100 dark:bg-gray-700 hover:bg-gray-200 dark:hover:bg-gray-600 rounded-lg transition-colors",children:"Try Again"}),t.jsxs("button",{onClick:this.handleReload,className:"flex items-center gap-2 px-4 py-2 text-sm font-medium text-white bg-primary-600 hover:bg-primary-700 rounded-lg transition-colors",children:[t.jsx(ts,{className:"h-4 w-4"}),"Refresh Page"]})]}),!1]})}):this.props.children}}const Ee=r.createContext(void 0);function us(){const s=r.useContext(Ee);if(s===void 0)throw new Error("useStats must be used within a StatsProvider");return s}function de(){const[s,a]=r.useState(null),[e,i]=r.useState(!1);r.useEffect(()=>{const o=async()=>{try{const c=await cs();a(c.data)}catch(c){console.error("Failed to fetch recording status:",c)}};o();const n=setInterval(o,5e3);return()=>clearInterval(n)},[]);const l=async()=>{if(!(!s||e)){i(!0);try{if(s.isPaused){const o=await ls();a(o.data),q.success("Recording resumed")}else{const o=await is();a(o.data),q.success("Recording paused")}}catch{q.error("Failed to toggle recording")}finally{i(!1)}}};return s?t.jsx("button",{onClick:l,disabled:e,className:`p-2.5 rounded-lg transition-colors ${s.isPaused?"text-yellow-600 hover:text-yellow-700 dark:text-yellow-400 dark:hover:text-yellow-300 hover:bg-yellow-50 dark:hover:bg-yellow-900/20":"text-green-600 hover:text-green-700 dark:text-green-400 dark:hover:text-green-300 hover:bg-green-50 dark:hover:bg-green-900/20"} ${e?"opacity-50 cursor-not-allowed":""}`,"aria-label":s.isPaused?"Resume recording":"Pause recording",title:s.isPaused?"Resume Recording":"Pause Recording",children:s.isPaused?t.jsx(Yt,{className:"h-5 w-5"}):t.jsx(Xt,{className:"h-5 w-5"})}):null}const ue={dashboard:"text-primary-500",request:"text-blue-500",query:"text-purple-500",graphql:"text-fuchsia-500",exception:"text-red-500",log:"text-green-500",job:"text-yellow-500",schedule:"text-gray-500",batch:"text-lime-500",command:"text-slate-500",cache:"text-cyan-500",redis:"text-rose-500",model:"text-violet-500","http-client":"text-indigo-500",mail:"text-pink-500",notification:"text-orange-500",event:"text-emerald-500",view:"text-teal-500",gate:"text-amber-500",dump:"text-stone-500"},he=[{name:"Overview",items:[{name:"Dashboard",href:"/",icon:Ut,colorKey:"dashboard"}]},{name:"Core",items:[{name:"Requests",href:"/requests",icon:qt,colorKey:"request"},{name:"Queries",href:"/queries",icon:Vt,colorKey:"query"},{name:"GraphQL",href:"/graphql",icon:Ft,colorKey:"graphql"},{name:"Exceptions",href:"/exceptions",icon:ve,badge:"exceptions",colorKey:"exception"},{name:"Logs",href:"/logs",icon:Bt,colorKey:"log"}]},{name:"Background",items:[{name:"Jobs",href:"/jobs",icon:It,colorKey:"job"},{name:"Schedule",href:"/schedule",icon:Kt,colorKey:"schedule"},{name:"Batches",href:"/batches",icon:Qt,colorKey:"batch"},{name:"Commands",href:"/commands",icon:as,colorKey:"command"}]},{name:"Data",items:[{name:"Cache",href:"/cache",icon:ne,colorKey:"cache"},{name:"Redis",href:"/redis",icon:zt,colorKey:"redis"},{name:"Models",href:"/models",icon:Gt,colorKey:"model"}]},{name:"Communication",items:[{name:"HTTP Client",href:"/http-client",icon:Ht,colorKey:"http-client"},{name:"Mail",href:"/mail",icon:Jt,colorKey:"mail"},{name:"Notifications",href:"/notifications",icon:$t,colorKey:"notification"},{name:"Events",href:"/events",icon:es,colorKey:"event"}]},{name:"System",items:[{name:"Views",href:"/views",icon:Zt,colorKey:"view"},{name:"Gates",href:"/gates",icon:ss,colorKey:"gate"},{name:"Dumps",href:"/dumps",icon:ne,colorKey:"dump"}]}];function me(s){return s!=="system"?s==="dark":window.matchMedia("(prefers-color-scheme: dark)").matches}function hs(){const s=Ae(),[a,e]=r.useState(!1),{stats:i}=us(),[l,o]=r.useState(()=>{if(typeof window<"u"){const m=localStorage.getItem("nestlens-collapsed-groups");return m?new Set(JSON.parse(m)):new Set}return new Set}),[n,c]=r.useState(()=>typeof window<"u"?document.documentElement.classList.contains("dark"):!1),[u,x]=r.useState(()=>{if(typeof window<"u"){const m=localStorage.getItem("nestlens-theme");if(m==="system"||m==="light"||m==="dark")return m}return"system"}),d=r.useCallback(m=>{o(w=>{const E=new Set(w);return E.has(m)?E.delete(m):E.add(m),localStorage.setItem("nestlens-collapsed-groups",JSON.stringify([...E])),E})},[]),h=r.useCallback(m=>{if(!i)return 0;switch(m){case"exceptions":return i.unresolvedExceptions??i.byType.exception??0;default:return 0}},[i]),y=r.useCallback(m=>{const w=me(m);w?document.documentElement.classList.add("dark"):document.documentElement.classList.remove("dark"),c(w)},[]),j=r.useCallback(()=>{const m=n?"light":"dark";x(m),localStorage.setItem("nestlens-theme",m),y(m)},[n,y]),k=r.useCallback(async()=>{window.confirm("Are you sure you want to clear all entries?")&&(await os(),q.success("All entries cleared"),window.location.reload())},[]);return r.useEffect(()=>{const m=me(u);if(document.documentElement.classList.toggle("dark",m),u==="system"){const w=window.matchMedia("(prefers-color-scheme: dark)"),E=b=>{document.documentElement.classList.toggle("dark",b.matches),c(b.matches)};return w.addEventListener("change",E),()=>w.removeEventListener("change",E)}},[u]),ds([{key:"k",ctrl:!0,handler:()=>k()},{key:"Escape",handler:()=>{a&&e(!1)},preventDefault:!1},{key:"d",ctrl:!0,handler:()=>j()}]),t.jsxs("div",{className:"min-h-screen bg-gray-50 dark:bg-gray-900",children:[t.jsxs("div",{className:`fixed inset-0 z-50 lg:hidden ${a?"":"hidden"}`,children:[t.jsx("div",{className:"fixed inset-0 bg-gray-900/80",onClick:()=>e(!1)}),t.jsxs("div",{id:"mobile-sidebar","data-testid":"mobile-sidebar",className:"fixed inset-y-0 left-0 w-64 bg-white dark:bg-gray-800 flex flex-col",children:[t.jsxs("div",{className:"flex h-16 items-center justify-between px-4 border-b border-gray-200 dark:border-gray-700",children:[t.jsxs(D,{to:"/",className:"flex items-center space-x-2",children:[t.jsx(U,{className:"h-8 w-8 text-primary-600"}),t.jsx("span",{className:"text-xl font-bold text-gray-900 dark:text-white",children:"NestLens"})]}),t.jsx("button",{onClick:()=>e(!1),className:"text-gray-500 hover:text-gray-700 dark:text-gray-400","aria-label":"Close sidebar",children:t.jsx(rs,{className:"h-6 w-6","aria-hidden":"true"})})]}),t.jsx("nav",{className:"flex-1 min-h-0 overflow-y-auto py-4 px-3",children:he.map((m,w)=>{const E=l.has(m.name);return t.jsxs("div",{className:w>0?"mt-4":"",children:[t.jsxs("button",{onClick:()=>d(m.name),className:"flex items-center justify-between w-full px-2 py-1.5 text-xs font-semibold text-gray-400 dark:text-gray-500 uppercase tracking-wider hover:text-gray-600 dark:hover:text-gray-400 transition-colors","aria-expanded":!E,"aria-controls":`nav-group-${m.name.toLowerCase().replace(/\s+/g,"-")}`,children:[t.jsx("span",{children:m.name}),E?t.jsx(ae,{className:"h-3 w-3","aria-hidden":"true"}):t.jsx(se,{className:"h-3 w-3","aria-hidden":"true"})]}),!E&&t.jsx("div",{className:"mt-1 space-y-0.5",children:m.items.map(b=>{const N=b.href==="/"?s.pathname==="/":s.pathname.startsWith(b.href),C="badge"in b?h(b.badge):0;return t.jsxs(D,{to:b.href,"aria-current":N?"page":void 0,className:`group flex items-center justify-between px-3 py-2 rounded-lg transition-colors ${N?"bg-primary-50 text-primary-700 dark:bg-primary-900/50 dark:text-primary-200 font-medium":"text-gray-600 hover:bg-gray-100 dark:text-gray-400 dark:hover:bg-gray-800 hover:text-gray-900 dark:hover:text-white"}`,onClick:()=>e(!1),children:[t.jsxs("div",{className:"flex items-center space-x-3",children:[t.jsx(b.icon,{className:`h-4 w-4 ${ue[b.colorKey]||"text-gray-400"}`}),t.jsx("span",{className:"text-sm",children:b.name})]}),C>0&&t.jsx("span",{className:"inline-flex items-center justify-center min-w-[20px] h-5 px-1.5 text-xs font-medium bg-red-100 text-red-700 dark:bg-red-900/50 dark:text-red-400 rounded-full",children:C>99?"99+":C})]},b.name)})})]},m.name)})}),t.jsx("div",{className:"flex-shrink-0 p-3 border-t border-gray-200 dark:border-gray-700",children:t.jsxs("div",{className:"flex items-center justify-center gap-1",children:[t.jsx(de,{}),t.jsx("button",{onClick:j,className:"p-2.5 text-gray-500 hover:text-gray-700 dark:text-gray-400 dark:hover:text-gray-200 hover:bg-gray-100 dark:hover:bg-gray-700 rounded-lg transition-colors","aria-label":n?"Switch to light mode":"Switch to dark mode",children:n?t.jsx(ie,{className:"h-5 w-5"}):t.jsx(oe,{className:"h-5 w-5"})}),t.jsx("button",{onClick:k,className:"p-2.5 text-gray-500 hover:text-red-600 dark:text-gray-400 dark:hover:text-red-400 hover:bg-red-50 dark:hover:bg-red-900/20 rounded-lg transition-colors","aria-label":"Clear all data",children:t.jsx(le,{className:"h-5 w-5"})}),t.jsx("a",{href:"https://github.com/mogretici/nestlens",target:"_blank",rel:"noopener noreferrer",className:"p-2.5 text-gray-500 hover:text-gray-700 dark:text-gray-400 dark:hover:text-gray-200 hover:bg-gray-100 dark:hover:bg-gray-700 rounded-lg transition-colors","aria-label":"Documentation",children:t.jsx(re,{className:"h-5 w-5"})})]})})]})]}),t.jsx("div",{"data-testid":"sidebar",className:"hidden lg:fixed lg:inset-y-0 lg:flex lg:w-64 lg:flex-col",children:t.jsxs("div",{className:"flex flex-col h-full bg-white dark:bg-gray-800 border-r border-gray-200 dark:border-gray-700",children:[t.jsx("div",{className:"flex h-16 items-center px-4 border-b border-gray-200 dark:border-gray-700",children:t.jsxs(D,{to:"/",className:"flex items-center space-x-2.5",children:[t.jsx("div",{className:"p-1.5 bg-primary-100 dark:bg-primary-900/50 rounded-lg",children:t.jsx(U,{className:"h-6 w-6 text-primary-600 dark:text-primary-400"})}),t.jsxs("div",{children:[t.jsx("span",{className:"text-lg font-bold text-gray-900 dark:text-white",children:"NestLens"}),t.jsxs("span",{className:"hidden xl:inline text-xs text-gray-400 dark:text-gray-500 ml-1.5",children:["v","0.9.3"]})]})]})}),t.jsx("nav",{className:"flex-1 min-h-0 overflow-y-auto py-4 px-3",children:he.map((m,w)=>{const E=l.has(m.name);return t.jsxs("div",{className:w>0?"mt-6":"",children:[t.jsxs("button",{onClick:()=>d(m.name),className:"flex items-center justify-between w-full px-2 py-1.5 text-[11px] font-semibold text-gray-400 dark:text-gray-500 uppercase tracking-wider hover:text-gray-600 dark:hover:text-gray-400 transition-colors","aria-expanded":!E,"aria-controls":`desktop-nav-group-${m.name.toLowerCase().replace(/\s+/g,"-")}`,children:[t.jsx("span",{children:m.name}),E?t.jsx(ae,{className:"h-3 w-3","aria-hidden":"true"}):t.jsx(se,{className:"h-3 w-3","aria-hidden":"true"})]}),!E&&t.jsx("div",{className:"mt-1 space-y-0.5",children:m.items.map(b=>{const N=b.href==="/"?s.pathname==="/":s.pathname.startsWith(b.href),C="badge"in b?h(b.badge):0;return t.jsxs(D,{to:b.href,"aria-current":N?"page":void 0,className:`group flex items-center justify-between px-3 py-2 rounded-lg transition-all duration-150 ${N?"bg-primary-50 text-primary-700 dark:bg-primary-900/50 dark:text-primary-200 font-medium shadow-sm":"text-gray-600 hover:bg-gray-50 dark:text-gray-400 dark:hover:bg-gray-800/50 hover:text-gray-900 dark:hover:text-white"}`,children:[t.jsxs("div",{className:"flex items-center space-x-3",children:[t.jsx(b.icon,{className:`h-[18px] w-[18px] ${ue[b.colorKey]||"text-gray-400"}`}),t.jsx("span",{className:"text-sm",children:b.name})]}),C>0&&t.jsx("span",{className:`inline-flex items-center justify-center min-w-[20px] h-5 px-1.5 text-xs font-semibold rounded-full transition-colors ${N?"bg-primary-200 text-primary-800 dark:bg-primary-800 dark:text-primary-200":"bg-red-100 text-red-700 dark:bg-red-900/50 dark:text-red-400"}`,children:C>99?"99+":C})]},b.name)})})]},m.name)})}),t.jsx("div",{className:"flex-shrink-0 p-3 border-t border-gray-200 dark:border-gray-700",children:t.jsxs("div",{className:"flex items-center justify-center gap-1",children:[t.jsx(de,{}),t.jsx("button",{onClick:j,className:"p-2.5 text-gray-500 hover:text-gray-700 dark:text-gray-400 dark:hover:text-gray-200 hover:bg-gray-100 dark:hover:bg-gray-700 rounded-lg transition-colors","aria-label":n?"Switch to light mode":"Switch to dark mode",title:n?"Light Mode (⌘D)":"Dark Mode (⌘D)",children:n?t.jsx(ie,{className:"h-5 w-5"}):t.jsx(oe,{className:"h-5 w-5"})}),t.jsx("button",{onClick:k,className:"p-2.5 text-gray-500 hover:text-red-600 dark:text-gray-400 dark:hover:text-red-400 hover:bg-red-50 dark:hover:bg-red-900/20 rounded-lg transition-colors","aria-label":"Clear all data",title:"Clear All Data (⌘K)",children:t.jsx(le,{className:"h-5 w-5"})}),t.jsx("a",{href:"https://github.com/mogretici/nestlens",target:"_blank",rel:"noopener noreferrer",className:"p-2.5 text-gray-500 hover:text-gray-700 dark:text-gray-400 dark:hover:text-gray-200 hover:bg-gray-100 dark:hover:bg-gray-700 rounded-lg transition-colors","aria-label":"Documentation",title:"Documentation",children:t.jsx(re,{className:"h-5 w-5"})})]})})]})}),t.jsxs("div",{className:"lg:pl-64",children:[t.jsxs("header",{className:"sticky top-0 z-40 flex h-14 items-center gap-4 border-b border-gray-200 dark:border-gray-700 bg-white dark:bg-gray-800 px-4 lg:hidden",children:[t.jsx("button",{onClick:()=>e(!0),className:"text-gray-500 hover:text-gray-700 dark:text-gray-400","aria-expanded":a,"aria-controls":"mobile-sidebar","aria-label":"Open navigation menu",children:t.jsx(Wt,{className:"h-6 w-6","aria-hidden":"true"})}),t.jsxs(D,{to:"/",className:"flex items-center space-x-2",children:[t.jsx(U,{className:"h-6 w-6 text-primary-600"}),t.jsx("span",{className:"text-lg font-bold text-gray-900 dark:text-white",children:"NestLens"})]})]}),t.jsx("main",{className:"p-4 lg:p-6",children:t.jsx(_e,{children:t.jsx(Oe,{})},s.pathname)})]})]})}function f(){return t.jsx("div",{className:"flex items-center justify-center min-h-[400px]",children:t.jsxs("div",{className:"flex flex-col items-center gap-3",children:[t.jsx("div",{className:"animate-spin rounded-full h-10 w-10 border-b-2 border-primary-600 dark:border-primary-400"}),t.jsx("p",{className:"text-sm text-gray-500 dark:text-gray-400",children:"Loading..."})]})})}const ms=r.lazy(()=>v(()=>import("./DashboardPage-DMggZXZm.js"),__vite__mapDeps([0,1,2,3,4]),import.meta.url)),ps=r.lazy(()=>v(()=>import("./RequestsPage-DzT18Gb7.js"),__vite__mapDeps([5,1,2,6,7,8,9,10]),import.meta.url)),xs=r.lazy(()=>v(()=>import("./QueriesPage-sxyFCofb.js"),__vite__mapDeps([11,1,2,6,7,8,9,10,3]),import.meta.url)),fs=r.lazy(()=>v(()=>import("./ExceptionsPage-BP0Omwzc.js"),__vite__mapDeps([12,1,2,6,7,8,9,10,13]),import.meta.url)),ys=r.lazy(()=>v(()=>import("./LogsPage-DCO8kMBG.js"),__vite__mapDeps([14,1,2,6,7,8,9,10]),import.meta.url)),gs=r.lazy(()=>v(()=>import("./EventsPage-BGCQccD5.js"),__vite__mapDeps([15,1,2,6,7,10]),import.meta.url)),js=r.lazy(()=>v(()=>import("./JobsPage-BtHUaYit.js"),__vite__mapDeps([16,1,2,6,7,10]),import.meta.url)),bs=r.lazy(()=>v(()=>import("./CachePage-sSG3fOH-.js"),__vite__mapDeps([17,1,2,6,7,10]),import.meta.url)),ks=r.lazy(()=>v(()=>import("./MailPage-yMJfR2pc.js"),__vite__mapDeps([18,1,2,6,7,10]),import.meta.url)),vs=r.lazy(()=>v(()=>import("./SchedulePage-DpUQnTKK.js"),__vite__mapDeps([19,1,20,2,6,7,10]),import.meta.url)),ws=r.lazy(()=>v(()=>import("./HttpClientPage-Dc4CyjM2.js"),__vite__mapDeps([21,1,2,6,7,10]),import.meta.url)),Ss=r.lazy(()=>v(()=>import("./RedisPage-CJTBRYRA.js"),__vite__mapDeps([22,1,2,6,7,10]),import.meta.url)),_s=r.lazy(()=>v(()=>import("./ModelsPage-DjLplWf-.js"),__vite__mapDeps([23,1,2,6,7,10]),import.meta.url)),Es=r.lazy(()=>v(()=>import("./NotificationsPage-Dw_KBVVy.js"),__vite__mapDeps([24,1,2,6,7,10]),import.meta.url)),Ns=r.lazy(()=>v(()=>import("./ViewsPage-BrVbaxmk.js"),__vite__mapDeps([25,1,2,6,7,10,26]),import.meta.url)),Ps=r.lazy(()=>v(()=>import("./CommandsPage-DGSwYx1i.js"),__vite__mapDeps([27,1,2,6,7,10]),import.meta.url)),Cs=r.lazy(()=>v(()=>import("./GatesPage-BQrbIY_I.js"),__vite__mapDeps([28,1,2,6,7,10]),import.meta.url)),Rs=r.lazy(()=>v(()=>import("./BatchesPage-B4mRZv-7.js"),__vite__mapDeps([29,1,2,6,7,10]),import.meta.url)),Ls=r.lazy(()=>v(()=>import("./DumpsPage-BFejJT0i.js"),__vite__mapDeps([30,1,2,6,7,10]),import.meta.url)),Ts=r.lazy(()=>v(()=>import("./GraphQLPage-DdXPF_EJ.js"),__vite__mapDeps([31,1,2,8,9,6,7,10]),import.meta.url)),S=r.lazy(()=>v(()=>import("./EntryDetailPage-jW_ZykXS.js").then(s=>s.E),__vite__mapDeps([32,1,2,7,9]),import.meta.url));function As(){return t.jsx(De,{children:t.jsxs(p,{path:"/",element:t.jsx(hs,{}),children:[t.jsx(p,{index:!0,element:t.jsx(r.Suspense,{fallback:t.jsx(f,{}),children:t.jsx(ms,{})})}),t.jsx(p,{path:"requests",element:t.jsx(r.Suspense,{fallback:t.jsx(f,{}),children:t.jsx(ps,{})})}),t.jsx(p,{path:"queries",element:t.jsx(r.Suspense,{fallback:t.jsx(f,{}),children:t.jsx(xs,{})})}),t.jsx(p,{path:"exceptions",element:t.jsx(r.Suspense,{fallback:t.jsx(f,{}),children:t.jsx(fs,{})})}),t.jsx(p,{path:"logs",element:t.jsx(r.Suspense,{fallback:t.jsx(f,{}),children:t.jsx(ys,{})})}),t.jsx(p,{path:"events",element:t.jsx(r.Suspense,{fallback:t.jsx(f,{}),children:t.jsx(gs,{})})}),t.jsx(p,{path:"jobs",element:t.jsx(r.Suspense,{fallback:t.jsx(f,{}),children:t.jsx(js,{})})}),t.jsx(p,{path:"cache",element:t.jsx(r.Suspense,{fallback:t.jsx(f,{}),children:t.jsx(bs,{})})}),t.jsx(p,{path:"mail",element:t.jsx(r.Suspense,{fallback:t.jsx(f,{}),children:t.jsx(ks,{})})}),t.jsx(p,{path:"schedule",element:t.jsx(r.Suspense,{fallback:t.jsx(f,{}),children:t.jsx(vs,{})})}),t.jsx(p,{path:"http-client",element:t.jsx(r.Suspense,{fallback:t.jsx(f,{}),children:t.jsx(ws,{})})}),t.jsx(p,{path:"redis",element:t.jsx(r.Suspense,{fallback:t.jsx(f,{}),children:t.jsx(Ss,{})})}),t.jsx(p,{path:"models",element:t.jsx(r.Suspense,{fallback:t.jsx(f,{}),children:t.jsx(_s,{})})}),t.jsx(p,{path:"notifications",element:t.jsx(r.Suspense,{fallback:t.jsx(f,{}),children:t.jsx(Es,{})})}),t.jsx(p,{path:"views",element:t.jsx(r.Suspense,{fallback:t.jsx(f,{}),children:t.jsx(Ns,{})})}),t.jsx(p,{path:"commands",element:t.jsx(r.Suspense,{fallback:t.jsx(f,{}),children:t.jsx(Ps,{})})}),t.jsx(p,{path:"gates",element:t.jsx(r.Suspense,{fallback:t.jsx(f,{}),children:t.jsx(Cs,{})})}),t.jsx(p,{path:"batches",element:t.jsx(r.Suspense,{fallback:t.jsx(f,{}),children:t.jsx(Rs,{})})}),t.jsx(p,{path:"dumps",element:t.jsx(r.Suspense,{fallback:t.jsx(f,{}),children:t.jsx(Ls,{})})}),t.jsx(p,{path:"graphql",element:t.jsx(r.Suspense,{fallback:t.jsx(f,{}),children:t.jsx(Ts,{})})}),t.jsx(p,{path:"requests/:id",element:t.jsx(r.Suspense,{fallback:t.jsx(f,{}),children:t.jsx(S,{})})}),t.jsx(p,{path:"queries/:id",element:t.jsx(r.Suspense,{fallback:t.jsx(f,{}),children:t.jsx(S,{})})}),t.jsx(p,{path:"exceptions/:id",element:t.jsx(r.Suspense,{fallback:t.jsx(f,{}),children:t.jsx(S,{})})}),t.jsx(p,{path:"logs/:id",element:t.jsx(r.Suspense,{fallback:t.jsx(f,{}),children:t.jsx(S,{})})}),t.jsx(p,{path:"events/:id",element:t.jsx(r.Suspense,{fallback:t.jsx(f,{}),children:t.jsx(S,{})})}),t.jsx(p,{path:"jobs/:id",element:t.jsx(r.Suspense,{fallback:t.jsx(f,{}),children:t.jsx(S,{})})}),t.jsx(p,{path:"cache/:id",element:t.jsx(r.Suspense,{fallback:t.jsx(f,{}),children:t.jsx(S,{})})}),t.jsx(p,{path:"mail/:id",element:t.jsx(r.Suspense,{fallback:t.jsx(f,{}),children:t.jsx(S,{})})}),t.jsx(p,{path:"schedule/:id",element:t.jsx(r.Suspense,{fallback:t.jsx(f,{}),children:t.jsx(S,{})})}),t.jsx(p,{path:"http-client/:id",element:t.jsx(r.Suspense,{fallback:t.jsx(f,{}),children:t.jsx(S,{})})}),t.jsx(p,{path:"redis/:id",element:t.jsx(r.Suspense,{fallback:t.jsx(f,{}),children:t.jsx(S,{})})}),t.jsx(p,{path:"models/:id",element:t.jsx(r.Suspense,{fallback:t.jsx(f,{}),children:t.jsx(S,{})})}),t.jsx(p,{path:"notifications/:id",element:t.jsx(r.Suspense,{fallback:t.jsx(f,{}),children:t.jsx(S,{})})}),t.jsx(p,{path:"views/:id",element:t.jsx(r.Suspense,{fallback:t.jsx(f,{}),children:t.jsx(S,{})})}),t.jsx(p,{path:"commands/:id",element:t.jsx(r.Suspense,{fallback:t.jsx(f,{}),children:t.jsx(S,{})})}),t.jsx(p,{path:"gates/:id",element:t.jsx(r.Suspense,{fallback:t.jsx(f,{}),children:t.jsx(S,{})})}),t.jsx(p,{path:"batches/:id",element:t.jsx(r.Suspense,{fallback:t.jsx(f,{}),children:t.jsx(S,{})})}),t.jsx(p,{path:"dumps/:id",element:t.jsx(r.Suspense,{fallback:t.jsx(f,{}),children:t.jsx(S,{})})}),t.jsx(p,{path:"graphql/:id",element:t.jsx(r.Suspense,{fallback:t.jsx(f,{}),children:t.jsx(S,{})})}),t.jsx(p,{path:"entries/:id",element:t.jsx(r.Suspense,{fallback:t.jsx(f,{}),children:t.jsx(S,{})})}),t.jsx(p,{path:"*",element:t.jsx(Me,{to:"/",replace:!0})})]})})}const Os=1e4;function Ds({children:s}){const[a,e]=r.useState(null),[i,l]=r.useState(null),o=r.useRef(!0),n=r.useRef(!0),c=r.useCallback(d=>{n.current&&(e(d),l(null),o.current=!1)},[]),u=r.useCallback(d=>{if(!n.current)return;const h=d instanceof Error?d:new Error("Failed to fetch stats");l(h),console.error("Failed to fetch stats:",d),o.current&&q.error("Failed to load statistics"),o.current=!1},[]),x=r.useCallback(async()=>ce().then(d=>c(d.data),d=>u(d)),[c,u]);return r.useEffect(()=>{n.current=!0;const d=setInterval(()=>void x(),Os);return ce().then(h=>c(h.data),u),()=>{n.current=!1,clearInterval(d)}},[x,c,u]),t.jsx(Ee.Provider,{value:{stats:a,error:i,refreshStats:x},children:s})}const Ne=document.getElementById("root");if(!Ne)throw new Error("NestLens dashboard: no #root element in the served index.html");Be.createRoot(Ne).render(t.jsx(qe.StrictMode,{children:t.jsx(_e,{children:t.jsx($e,{basename:we(),children:t.jsxs(Ds,{children:[t.jsx(As,{}),t.jsx(Lt,{position:"bottom-right",toastOptions:{duration:3e3,style:{background:"#1f2937",color:"#f3f4f6",borderRadius:"0.5rem"},success:{iconTheme:{primary:"#10b981",secondary:"#f3f4f6"}},error:{iconTheme:{primary:"#ef4444",secondary:"#f3f4f6"}}}})]})})})}));export{qt as A,It as B,Kt as C,Vt as D,Bt as F,Ft as G,ne as H,Gt as L,Jt as M,Qt as P,es as R,ss as S,ve as T,rs as X,v as _,as as a,zt as b,g as c,Ht as d,$t as e,Zt as f,ae as g,le as h,ts as i,t as j,Vs as k,Bs as l,zs as m,Gs as n,Hs as o,ns as p,Is as q,Fs as r,Ks as s,se as t,us as u,$s as v,Yt as w,q as z};
361
+ */const rs=g("X",[["path",{d:"M18 6 6 18",key:"1bl5f8"}],["path",{d:"m6 6 12 12",key:"d8bk6v"}]]),we=()=>window.__NESTLENS_BASE__??"",ns=s=>`${window.location.origin}${we()}/__nestlens__${s}`,Se=ns("/api");async function P(s,a){const e=await fetch(`${Se}${s}`,a);if(!e.ok)throw new Error(`API error: ${e.status}`);return e.json()}async function $s(s){return P(`/entries/${s}`)}async function ce(){return P("/stats")}async function os(){return(await fetch(`${Se}/entries`,{method:"DELETE"})).json()}async function zs(s){const a=new URLSearchParams;if(s.type&&a.set("type",s.type),s.limit&&a.set("limit",s.limit.toString()),s.beforeSequence!==void 0&&a.set("beforeSequence",s.beforeSequence.toString()),s.afterSequence!==void 0&&a.set("afterSequence",s.afterSequence.toString()),s.filters){const e=s.filters;e.levels&&e.levels.length>0&&a.set("levels",e.levels.join(",")),e.contexts&&e.contexts.length>0&&a.set("contexts",e.contexts.join(",")),e.queryTypes&&e.queryTypes.length>0&&a.set("queryTypes",e.queryTypes.join(",")),e.sources&&e.sources.length>0&&a.set("sources",e.sources.join(",")),e.slow!==void 0&&a.set("slow",e.slow.toString()),e.names&&e.names.length>0&&a.set("names",e.names.join(",")),e.methods&&e.methods.length>0&&a.set("methods",e.methods.join(",")),e.paths&&e.paths.length>0&&a.set("paths",e.paths.join(",")),e.resolved!==void 0&&a.set("resolved",e.resolved.toString()),e.statuses&&e.statuses.length>0&&a.set("statuses",e.statuses.join(",")),e.hostnames&&e.hostnames.length>0&&a.set("hostnames",e.hostnames.join(",")),e.controllers&&e.controllers.length>0&&a.set("controllers",e.controllers.join(",")),e.ips&&e.ips.length>0&&a.set("ips",e.ips.join(",")),e.eventNames&&e.eventNames.length>0&&a.set("eventNames",e.eventNames.join(",")),e.scheduleStatuses&&e.scheduleStatuses.length>0&&a.set("scheduleStatuses",e.scheduleStatuses.join(",")),e.scheduleNames&&e.scheduleNames.length>0&&a.set("scheduleNames",e.scheduleNames.join(",")),e.jobStatuses&&e.jobStatuses.length>0&&a.set("jobStatuses",e.jobStatuses.join(",")),e.jobNames&&e.jobNames.length>0&&a.set("jobNames",e.jobNames.join(",")),e.queues&&e.queues.length>0&&a.set("queues",e.queues.join(",")),e.cacheOperations&&e.cacheOperations.length>0&&a.set("cacheOperations",e.cacheOperations.join(",")),e.mailStatuses&&e.mailStatuses.length>0&&a.set("mailStatuses",e.mailStatuses.join(",")),e.redisStatuses&&e.redisStatuses.length>0&&a.set("redisStatuses",e.redisStatuses.join(",")),e.redisCommands&&e.redisCommands.length>0&&a.set("redisCommands",e.redisCommands.join(",")),e.modelActions&&e.modelActions.length>0&&a.set("modelActions",e.modelActions.join(",")),e.entities&&e.entities.length>0&&a.set("entities",e.entities.join(",")),e.modelSources&&e.modelSources.length>0&&a.set("modelSources",e.modelSources.join(",")),e.notificationTypes&&e.notificationTypes.length>0&&a.set("notificationTypes",e.notificationTypes.join(",")),e.notificationStatuses&&e.notificationStatuses.length>0&&a.set("notificationStatuses",e.notificationStatuses.join(",")),e.viewFormats&&e.viewFormats.length>0&&a.set("viewFormats",e.viewFormats.join(",")),e.viewStatuses&&e.viewStatuses.length>0&&a.set("viewStatuses",e.viewStatuses.join(",")),e.commandStatuses&&e.commandStatuses.length>0&&a.set("commandStatuses",e.commandStatuses.join(",")),e.commandNames&&e.commandNames.length>0&&a.set("commandNames",e.commandNames.join(",")),e.gateNames&&e.gateNames.length>0&&a.set("gateNames",e.gateNames.join(",")),e.gateResults&&e.gateResults.length>0&&a.set("gateResults",e.gateResults.join(",")),e.batchStatuses&&e.batchStatuses.length>0&&a.set("batchStatuses",e.batchStatuses.join(",")),e.batchOperations&&e.batchOperations.length>0&&a.set("batchOperations",e.batchOperations.join(",")),e.dumpStatuses&&e.dumpStatuses.length>0&&a.set("dumpStatuses",e.dumpStatuses.join(",")),e.dumpOperations&&e.dumpOperations.length>0&&a.set("dumpOperations",e.dumpOperations.join(",")),e.dumpFormats&&e.dumpFormats.length>0&&a.set("dumpFormats",e.dumpFormats.join(",")),e.operationTypes&&e.operationTypes.length>0&&a.set("operationTypes",e.operationTypes.join(",")),e.operationNames&&e.operationNames.length>0&&a.set("operationNames",e.operationNames.join(",")),e.hasErrors!==void 0&&a.set("hasErrors",e.hasErrors.toString()),e.hasN1!==void 0&&a.set("hasN1",e.hasN1.toString()),e.tags&&e.tags.length>0&&a.set("tags",e.tags.join(",")),e.search&&a.set("search",e.search)}return P(`/entries/cursor?${a.toString()}`)}async function Is(s){const a=new URLSearchParams;return s&&a.set("type",s),P(`/entries/latest-sequence?${a.toString()}`)}async function Ks(s,a){const e=new URLSearchParams;return e.set("afterSequence",s.toString()),a&&e.set("type",a),P(`/entries/check-new?${e.toString()}`)}async function Vs(){return P("/storage/stats")}async function Bs(){return P("/pruning/status")}async function Fs(){return P("/pruning/run",{method:"POST"})}async function Hs(s){return P(`/entries/${s}/resolve`,{method:"PATCH"})}async function Gs(s){return P(`/entries/${s}/unresolve`,{method:"PATCH"})}async function is(s){return P("/recording/pause",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({reason:s})})}async function ls(){return P("/recording/resume",{method:"POST"})}async function cs(){return P("/recording/status")}function ds(s){const a=r.useCallback(e=>{const i=e.target,l=i.tagName==="INPUT"||i.tagName==="TEXTAREA"||i.isContentEditable;for(const o of s){const{key:n,ctrl:c,meta:u,shift:x,alt:d,handler:h,preventDefault:y=!0}=o;if(l&&n.toLowerCase()!=="escape")continue;const j=e.key.toLowerCase()===n.toLowerCase(),k=x?e.shiftKey:!e.shiftKey,m=d?e.altKey:!e.altKey;if(c){if((e.ctrlKey||e.metaKey)&&j&&k&&m){y&&e.preventDefault(),h(e);return}continue}if(u){if(e.metaKey&&!e.ctrlKey&&j&&k&&m){y&&e.preventDefault(),h(e);return}continue}if(!e.ctrlKey&&!e.metaKey&&j&&k&&m){y&&e.preventDefault(),h(e);return}}},[s]);r.useEffect(()=>(document.addEventListener("keydown",a),()=>{document.removeEventListener("keydown",a)}),[a])}class _e extends r.Component{constructor(){super(...arguments);z(this,"state",{hasError:!1});z(this,"handleReload",()=>{window.location.reload()});z(this,"handleReset",()=>{this.setState({hasError:!1,error:void 0,errorInfo:void 0})})}static getDerivedStateFromError(e){return{hasError:!0,error:e}}componentDidCatch(e,i){console.error("ErrorBoundary caught an error:",e,i),this.setState({errorInfo:i})}render(){return this.state.hasError?this.props.fallback?this.props.fallback:t.jsx("div",{className:"min-h-screen flex items-center justify-center bg-gray-50 dark:bg-gray-900 p-4",children:t.jsxs("div",{className:"max-w-md w-full bg-white dark:bg-gray-800 rounded-lg shadow-lg p-6 text-center",children:[t.jsx("div",{className:"mx-auto w-12 h-12 flex items-center justify-center rounded-full bg-red-100 dark:bg-red-900/30 mb-4",children:t.jsx(ve,{className:"h-6 w-6 text-red-600 dark:text-red-400"})}),t.jsx("h1",{className:"text-xl font-semibold text-gray-900 dark:text-white mb-2",children:"Something went wrong"}),t.jsx("p",{className:"text-gray-600 dark:text-gray-400 mb-4",children:"An unexpected error occurred. Please try refreshing the page."}),this.state.error&&t.jsx("div",{className:"mb-4 p-3 bg-red-50 dark:bg-red-900/20 rounded-lg text-left",children:t.jsx("p",{className:"text-sm font-mono text-red-600 dark:text-red-400 break-all",children:this.state.error.message})}),t.jsxs("div",{className:"flex gap-3 justify-center",children:[t.jsx("button",{onClick:this.handleReset,className:"px-4 py-2 text-sm font-medium text-gray-700 dark:text-gray-300 bg-gray-100 dark:bg-gray-700 hover:bg-gray-200 dark:hover:bg-gray-600 rounded-lg transition-colors",children:"Try Again"}),t.jsxs("button",{onClick:this.handleReload,className:"flex items-center gap-2 px-4 py-2 text-sm font-medium text-white bg-primary-600 hover:bg-primary-700 rounded-lg transition-colors",children:[t.jsx(ts,{className:"h-4 w-4"}),"Refresh Page"]})]}),!1]})}):this.props.children}}const Ee=r.createContext(void 0);function us(){const s=r.useContext(Ee);if(s===void 0)throw new Error("useStats must be used within a StatsProvider");return s}function de(){const[s,a]=r.useState(null),[e,i]=r.useState(!1);r.useEffect(()=>{const o=async()=>{try{const c=await cs();a(c.data)}catch(c){console.error("Failed to fetch recording status:",c)}};o();const n=setInterval(o,5e3);return()=>clearInterval(n)},[]);const l=async()=>{if(!(!s||e)){i(!0);try{if(s.isPaused){const o=await ls();a(o.data),q.success("Recording resumed")}else{const o=await is();a(o.data),q.success("Recording paused")}}catch{q.error("Failed to toggle recording")}finally{i(!1)}}};return s?t.jsx("button",{onClick:l,disabled:e,className:`p-2.5 rounded-lg transition-colors ${s.isPaused?"text-yellow-600 hover:text-yellow-700 dark:text-yellow-400 dark:hover:text-yellow-300 hover:bg-yellow-50 dark:hover:bg-yellow-900/20":"text-green-600 hover:text-green-700 dark:text-green-400 dark:hover:text-green-300 hover:bg-green-50 dark:hover:bg-green-900/20"} ${e?"opacity-50 cursor-not-allowed":""}`,"aria-label":s.isPaused?"Resume recording":"Pause recording",title:s.isPaused?"Resume Recording":"Pause Recording",children:s.isPaused?t.jsx(Yt,{className:"h-5 w-5"}):t.jsx(Xt,{className:"h-5 w-5"})}):null}const ue={dashboard:"text-primary-500",request:"text-blue-500",query:"text-purple-500",graphql:"text-fuchsia-500",exception:"text-red-500",log:"text-green-500",job:"text-yellow-500",schedule:"text-gray-500",batch:"text-lime-500",command:"text-slate-500",cache:"text-cyan-500",redis:"text-rose-500",model:"text-violet-500","http-client":"text-indigo-500",mail:"text-pink-500",notification:"text-orange-500",event:"text-emerald-500",view:"text-teal-500",gate:"text-amber-500",dump:"text-stone-500"},he=[{name:"Overview",items:[{name:"Dashboard",href:"/",icon:Ut,colorKey:"dashboard"}]},{name:"Core",items:[{name:"Requests",href:"/requests",icon:qt,colorKey:"request"},{name:"Queries",href:"/queries",icon:Vt,colorKey:"query"},{name:"GraphQL",href:"/graphql",icon:Ft,colorKey:"graphql"},{name:"Exceptions",href:"/exceptions",icon:ve,badge:"exceptions",colorKey:"exception"},{name:"Logs",href:"/logs",icon:Bt,colorKey:"log"}]},{name:"Background",items:[{name:"Jobs",href:"/jobs",icon:It,colorKey:"job"},{name:"Schedule",href:"/schedule",icon:Kt,colorKey:"schedule"},{name:"Batches",href:"/batches",icon:Qt,colorKey:"batch"},{name:"Commands",href:"/commands",icon:as,colorKey:"command"}]},{name:"Data",items:[{name:"Cache",href:"/cache",icon:ne,colorKey:"cache"},{name:"Redis",href:"/redis",icon:zt,colorKey:"redis"},{name:"Models",href:"/models",icon:Gt,colorKey:"model"}]},{name:"Communication",items:[{name:"HTTP Client",href:"/http-client",icon:Ht,colorKey:"http-client"},{name:"Mail",href:"/mail",icon:Jt,colorKey:"mail"},{name:"Notifications",href:"/notifications",icon:$t,colorKey:"notification"},{name:"Events",href:"/events",icon:es,colorKey:"event"}]},{name:"System",items:[{name:"Views",href:"/views",icon:Zt,colorKey:"view"},{name:"Gates",href:"/gates",icon:ss,colorKey:"gate"},{name:"Dumps",href:"/dumps",icon:ne,colorKey:"dump"}]}];function me(s){return s!=="system"?s==="dark":window.matchMedia("(prefers-color-scheme: dark)").matches}function hs(){const s=Ae(),[a,e]=r.useState(!1),{stats:i}=us(),[l,o]=r.useState(()=>{if(typeof window<"u"){const m=localStorage.getItem("nestlens-collapsed-groups");return m?new Set(JSON.parse(m)):new Set}return new Set}),[n,c]=r.useState(()=>typeof window<"u"?document.documentElement.classList.contains("dark"):!1),[u,x]=r.useState(()=>{if(typeof window<"u"){const m=localStorage.getItem("nestlens-theme");if(m==="system"||m==="light"||m==="dark")return m}return"system"}),d=r.useCallback(m=>{o(w=>{const E=new Set(w);return E.has(m)?E.delete(m):E.add(m),localStorage.setItem("nestlens-collapsed-groups",JSON.stringify([...E])),E})},[]),h=r.useCallback(m=>{if(!i)return 0;switch(m){case"exceptions":return i.unresolvedExceptions??i.byType.exception??0;default:return 0}},[i]),y=r.useCallback(m=>{const w=me(m);w?document.documentElement.classList.add("dark"):document.documentElement.classList.remove("dark"),c(w)},[]),j=r.useCallback(()=>{const m=n?"light":"dark";x(m),localStorage.setItem("nestlens-theme",m),y(m)},[n,y]),k=r.useCallback(async()=>{window.confirm("Are you sure you want to clear all entries?")&&(await os(),q.success("All entries cleared"),window.location.reload())},[]);return r.useEffect(()=>{const m=me(u);if(document.documentElement.classList.toggle("dark",m),u==="system"){const w=window.matchMedia("(prefers-color-scheme: dark)"),E=b=>{document.documentElement.classList.toggle("dark",b.matches),c(b.matches)};return w.addEventListener("change",E),()=>w.removeEventListener("change",E)}},[u]),ds([{key:"k",ctrl:!0,handler:()=>k()},{key:"Escape",handler:()=>{a&&e(!1)},preventDefault:!1},{key:"d",ctrl:!0,handler:()=>j()}]),t.jsxs("div",{className:"min-h-screen bg-gray-50 dark:bg-gray-900",children:[t.jsxs("div",{className:`fixed inset-0 z-50 lg:hidden ${a?"":"hidden"}`,children:[t.jsx("div",{className:"fixed inset-0 bg-gray-900/80",onClick:()=>e(!1)}),t.jsxs("div",{id:"mobile-sidebar","data-testid":"mobile-sidebar",className:"fixed inset-y-0 left-0 w-64 bg-white dark:bg-gray-800 flex flex-col",children:[t.jsxs("div",{className:"flex h-16 items-center justify-between px-4 border-b border-gray-200 dark:border-gray-700",children:[t.jsxs(D,{to:"/",className:"flex items-center space-x-2",children:[t.jsx(U,{className:"h-8 w-8 text-primary-600"}),t.jsx("span",{className:"text-xl font-bold text-gray-900 dark:text-white",children:"NestLens"})]}),t.jsx("button",{onClick:()=>e(!1),className:"text-gray-500 hover:text-gray-700 dark:text-gray-400","aria-label":"Close sidebar",children:t.jsx(rs,{className:"h-6 w-6","aria-hidden":"true"})})]}),t.jsx("nav",{className:"flex-1 min-h-0 overflow-y-auto py-4 px-3",children:he.map((m,w)=>{const E=l.has(m.name);return t.jsxs("div",{className:w>0?"mt-4":"",children:[t.jsxs("button",{onClick:()=>d(m.name),className:"flex items-center justify-between w-full px-2 py-1.5 text-xs font-semibold text-gray-400 dark:text-gray-500 uppercase tracking-wider hover:text-gray-600 dark:hover:text-gray-400 transition-colors","aria-expanded":!E,"aria-controls":`nav-group-${m.name.toLowerCase().replace(/\s+/g,"-")}`,children:[t.jsx("span",{children:m.name}),E?t.jsx(ae,{className:"h-3 w-3","aria-hidden":"true"}):t.jsx(se,{className:"h-3 w-3","aria-hidden":"true"})]}),!E&&t.jsx("div",{className:"mt-1 space-y-0.5",children:m.items.map(b=>{const N=b.href==="/"?s.pathname==="/":s.pathname.startsWith(b.href),C="badge"in b?h(b.badge):0;return t.jsxs(D,{to:b.href,"aria-current":N?"page":void 0,className:`group flex items-center justify-between px-3 py-2 rounded-lg transition-colors ${N?"bg-primary-50 text-primary-700 dark:bg-primary-900/50 dark:text-primary-200 font-medium":"text-gray-600 hover:bg-gray-100 dark:text-gray-400 dark:hover:bg-gray-800 hover:text-gray-900 dark:hover:text-white"}`,onClick:()=>e(!1),children:[t.jsxs("div",{className:"flex items-center space-x-3",children:[t.jsx(b.icon,{className:`h-4 w-4 ${ue[b.colorKey]||"text-gray-400"}`}),t.jsx("span",{className:"text-sm",children:b.name})]}),C>0&&t.jsx("span",{className:"inline-flex items-center justify-center min-w-[20px] h-5 px-1.5 text-xs font-medium bg-red-100 text-red-700 dark:bg-red-900/50 dark:text-red-400 rounded-full",children:C>99?"99+":C})]},b.name)})})]},m.name)})}),t.jsx("div",{className:"flex-shrink-0 p-3 border-t border-gray-200 dark:border-gray-700",children:t.jsxs("div",{className:"flex items-center justify-center gap-1",children:[t.jsx(de,{}),t.jsx("button",{onClick:j,className:"p-2.5 text-gray-500 hover:text-gray-700 dark:text-gray-400 dark:hover:text-gray-200 hover:bg-gray-100 dark:hover:bg-gray-700 rounded-lg transition-colors","aria-label":n?"Switch to light mode":"Switch to dark mode",children:n?t.jsx(ie,{className:"h-5 w-5"}):t.jsx(oe,{className:"h-5 w-5"})}),t.jsx("button",{onClick:k,className:"p-2.5 text-gray-500 hover:text-red-600 dark:text-gray-400 dark:hover:text-red-400 hover:bg-red-50 dark:hover:bg-red-900/20 rounded-lg transition-colors","aria-label":"Clear all data",children:t.jsx(le,{className:"h-5 w-5"})}),t.jsx("a",{href:"https://github.com/mogretici/nestlens",target:"_blank",rel:"noopener noreferrer",className:"p-2.5 text-gray-500 hover:text-gray-700 dark:text-gray-400 dark:hover:text-gray-200 hover:bg-gray-100 dark:hover:bg-gray-700 rounded-lg transition-colors","aria-label":"Documentation",children:t.jsx(re,{className:"h-5 w-5"})})]})})]})]}),t.jsx("div",{"data-testid":"sidebar",className:"hidden lg:fixed lg:inset-y-0 lg:flex lg:w-64 lg:flex-col",children:t.jsxs("div",{className:"flex flex-col h-full bg-white dark:bg-gray-800 border-r border-gray-200 dark:border-gray-700",children:[t.jsx("div",{className:"flex h-16 items-center px-4 border-b border-gray-200 dark:border-gray-700",children:t.jsxs(D,{to:"/",className:"flex items-center space-x-2.5",children:[t.jsx("div",{className:"p-1.5 bg-primary-100 dark:bg-primary-900/50 rounded-lg",children:t.jsx(U,{className:"h-6 w-6 text-primary-600 dark:text-primary-400"})}),t.jsxs("div",{children:[t.jsx("span",{className:"text-lg font-bold text-gray-900 dark:text-white",children:"NestLens"}),t.jsxs("span",{className:"hidden xl:inline text-xs text-gray-400 dark:text-gray-500 ml-1.5",children:["v","0.9.4"]})]})]})}),t.jsx("nav",{className:"flex-1 min-h-0 overflow-y-auto py-4 px-3",children:he.map((m,w)=>{const E=l.has(m.name);return t.jsxs("div",{className:w>0?"mt-6":"",children:[t.jsxs("button",{onClick:()=>d(m.name),className:"flex items-center justify-between w-full px-2 py-1.5 text-[11px] font-semibold text-gray-400 dark:text-gray-500 uppercase tracking-wider hover:text-gray-600 dark:hover:text-gray-400 transition-colors","aria-expanded":!E,"aria-controls":`desktop-nav-group-${m.name.toLowerCase().replace(/\s+/g,"-")}`,children:[t.jsx("span",{children:m.name}),E?t.jsx(ae,{className:"h-3 w-3","aria-hidden":"true"}):t.jsx(se,{className:"h-3 w-3","aria-hidden":"true"})]}),!E&&t.jsx("div",{className:"mt-1 space-y-0.5",children:m.items.map(b=>{const N=b.href==="/"?s.pathname==="/":s.pathname.startsWith(b.href),C="badge"in b?h(b.badge):0;return t.jsxs(D,{to:b.href,"aria-current":N?"page":void 0,className:`group flex items-center justify-between px-3 py-2 rounded-lg transition-all duration-150 ${N?"bg-primary-50 text-primary-700 dark:bg-primary-900/50 dark:text-primary-200 font-medium shadow-sm":"text-gray-600 hover:bg-gray-50 dark:text-gray-400 dark:hover:bg-gray-800/50 hover:text-gray-900 dark:hover:text-white"}`,children:[t.jsxs("div",{className:"flex items-center space-x-3",children:[t.jsx(b.icon,{className:`h-[18px] w-[18px] ${ue[b.colorKey]||"text-gray-400"}`}),t.jsx("span",{className:"text-sm",children:b.name})]}),C>0&&t.jsx("span",{className:`inline-flex items-center justify-center min-w-[20px] h-5 px-1.5 text-xs font-semibold rounded-full transition-colors ${N?"bg-primary-200 text-primary-800 dark:bg-primary-800 dark:text-primary-200":"bg-red-100 text-red-700 dark:bg-red-900/50 dark:text-red-400"}`,children:C>99?"99+":C})]},b.name)})})]},m.name)})}),t.jsx("div",{className:"flex-shrink-0 p-3 border-t border-gray-200 dark:border-gray-700",children:t.jsxs("div",{className:"flex items-center justify-center gap-1",children:[t.jsx(de,{}),t.jsx("button",{onClick:j,className:"p-2.5 text-gray-500 hover:text-gray-700 dark:text-gray-400 dark:hover:text-gray-200 hover:bg-gray-100 dark:hover:bg-gray-700 rounded-lg transition-colors","aria-label":n?"Switch to light mode":"Switch to dark mode",title:n?"Light Mode (⌘D)":"Dark Mode (⌘D)",children:n?t.jsx(ie,{className:"h-5 w-5"}):t.jsx(oe,{className:"h-5 w-5"})}),t.jsx("button",{onClick:k,className:"p-2.5 text-gray-500 hover:text-red-600 dark:text-gray-400 dark:hover:text-red-400 hover:bg-red-50 dark:hover:bg-red-900/20 rounded-lg transition-colors","aria-label":"Clear all data",title:"Clear All Data (⌘K)",children:t.jsx(le,{className:"h-5 w-5"})}),t.jsx("a",{href:"https://github.com/mogretici/nestlens",target:"_blank",rel:"noopener noreferrer",className:"p-2.5 text-gray-500 hover:text-gray-700 dark:text-gray-400 dark:hover:text-gray-200 hover:bg-gray-100 dark:hover:bg-gray-700 rounded-lg transition-colors","aria-label":"Documentation",title:"Documentation",children:t.jsx(re,{className:"h-5 w-5"})})]})})]})}),t.jsxs("div",{className:"lg:pl-64",children:[t.jsxs("header",{className:"sticky top-0 z-40 flex h-14 items-center gap-4 border-b border-gray-200 dark:border-gray-700 bg-white dark:bg-gray-800 px-4 lg:hidden",children:[t.jsx("button",{onClick:()=>e(!0),className:"text-gray-500 hover:text-gray-700 dark:text-gray-400","aria-expanded":a,"aria-controls":"mobile-sidebar","aria-label":"Open navigation menu",children:t.jsx(Wt,{className:"h-6 w-6","aria-hidden":"true"})}),t.jsxs(D,{to:"/",className:"flex items-center space-x-2",children:[t.jsx(U,{className:"h-6 w-6 text-primary-600"}),t.jsx("span",{className:"text-lg font-bold text-gray-900 dark:text-white",children:"NestLens"})]})]}),t.jsx("main",{className:"p-4 lg:p-6",children:t.jsx(_e,{children:t.jsx(Oe,{})},s.pathname)})]})]})}function f(){return t.jsx("div",{className:"flex items-center justify-center min-h-[400px]",children:t.jsxs("div",{className:"flex flex-col items-center gap-3",children:[t.jsx("div",{className:"animate-spin rounded-full h-10 w-10 border-b-2 border-primary-600 dark:border-primary-400"}),t.jsx("p",{className:"text-sm text-gray-500 dark:text-gray-400",children:"Loading..."})]})})}const ms=r.lazy(()=>v(()=>import("./DashboardPage-DdaOxHZ2.js"),__vite__mapDeps([0,1,2,3,4]),import.meta.url)),ps=r.lazy(()=>v(()=>import("./RequestsPage-D9KghDZ-.js"),__vite__mapDeps([5,1,2,6,7,8,9,10]),import.meta.url)),xs=r.lazy(()=>v(()=>import("./QueriesPage-Plp4pZSN.js"),__vite__mapDeps([11,1,2,6,7,8,9,10,3]),import.meta.url)),fs=r.lazy(()=>v(()=>import("./ExceptionsPage-KuyeMrqK.js"),__vite__mapDeps([12,1,2,6,7,8,9,10,13]),import.meta.url)),ys=r.lazy(()=>v(()=>import("./LogsPage-6dDP3Pu_.js"),__vite__mapDeps([14,1,2,6,7,8,9,10]),import.meta.url)),gs=r.lazy(()=>v(()=>import("./EventsPage-O1icFuRw.js"),__vite__mapDeps([15,1,2,6,7,10]),import.meta.url)),js=r.lazy(()=>v(()=>import("./JobsPage-DyiOLpB1.js"),__vite__mapDeps([16,1,2,6,7,10]),import.meta.url)),bs=r.lazy(()=>v(()=>import("./CachePage-Ce_yT75F.js"),__vite__mapDeps([17,1,2,6,7,10]),import.meta.url)),ks=r.lazy(()=>v(()=>import("./MailPage-tBhdhWmz.js"),__vite__mapDeps([18,1,2,6,7,10]),import.meta.url)),vs=r.lazy(()=>v(()=>import("./SchedulePage-B3mUO2Ng.js"),__vite__mapDeps([19,1,20,2,6,7,10]),import.meta.url)),ws=r.lazy(()=>v(()=>import("./HttpClientPage-qC_nBzq2.js"),__vite__mapDeps([21,1,2,6,7,10]),import.meta.url)),Ss=r.lazy(()=>v(()=>import("./RedisPage-CS2bcK-q.js"),__vite__mapDeps([22,1,2,6,7,10]),import.meta.url)),_s=r.lazy(()=>v(()=>import("./ModelsPage-BTLkoWRR.js"),__vite__mapDeps([23,1,2,6,7,10]),import.meta.url)),Es=r.lazy(()=>v(()=>import("./NotificationsPage-BOPuEc8u.js"),__vite__mapDeps([24,1,2,6,7,10]),import.meta.url)),Ns=r.lazy(()=>v(()=>import("./ViewsPage-BhlcyTU3.js"),__vite__mapDeps([25,1,2,6,7,10,26]),import.meta.url)),Ps=r.lazy(()=>v(()=>import("./CommandsPage-BwMh373Z.js"),__vite__mapDeps([27,1,2,6,7,10]),import.meta.url)),Cs=r.lazy(()=>v(()=>import("./GatesPage-BKLfGgS9.js"),__vite__mapDeps([28,1,2,6,7,10]),import.meta.url)),Rs=r.lazy(()=>v(()=>import("./BatchesPage-C5asqolh.js"),__vite__mapDeps([29,1,2,6,7,10]),import.meta.url)),Ls=r.lazy(()=>v(()=>import("./DumpsPage-BrYuIT5U.js"),__vite__mapDeps([30,1,2,6,7,10]),import.meta.url)),Ts=r.lazy(()=>v(()=>import("./GraphQLPage-BqkJnBEt.js"),__vite__mapDeps([31,1,2,8,9,6,7,10]),import.meta.url)),S=r.lazy(()=>v(()=>import("./EntryDetailPage-D7qvNuMn.js").then(s=>s.E),__vite__mapDeps([32,1,2,7,9]),import.meta.url));function As(){return t.jsx(De,{children:t.jsxs(p,{path:"/",element:t.jsx(hs,{}),children:[t.jsx(p,{index:!0,element:t.jsx(r.Suspense,{fallback:t.jsx(f,{}),children:t.jsx(ms,{})})}),t.jsx(p,{path:"requests",element:t.jsx(r.Suspense,{fallback:t.jsx(f,{}),children:t.jsx(ps,{})})}),t.jsx(p,{path:"queries",element:t.jsx(r.Suspense,{fallback:t.jsx(f,{}),children:t.jsx(xs,{})})}),t.jsx(p,{path:"exceptions",element:t.jsx(r.Suspense,{fallback:t.jsx(f,{}),children:t.jsx(fs,{})})}),t.jsx(p,{path:"logs",element:t.jsx(r.Suspense,{fallback:t.jsx(f,{}),children:t.jsx(ys,{})})}),t.jsx(p,{path:"events",element:t.jsx(r.Suspense,{fallback:t.jsx(f,{}),children:t.jsx(gs,{})})}),t.jsx(p,{path:"jobs",element:t.jsx(r.Suspense,{fallback:t.jsx(f,{}),children:t.jsx(js,{})})}),t.jsx(p,{path:"cache",element:t.jsx(r.Suspense,{fallback:t.jsx(f,{}),children:t.jsx(bs,{})})}),t.jsx(p,{path:"mail",element:t.jsx(r.Suspense,{fallback:t.jsx(f,{}),children:t.jsx(ks,{})})}),t.jsx(p,{path:"schedule",element:t.jsx(r.Suspense,{fallback:t.jsx(f,{}),children:t.jsx(vs,{})})}),t.jsx(p,{path:"http-client",element:t.jsx(r.Suspense,{fallback:t.jsx(f,{}),children:t.jsx(ws,{})})}),t.jsx(p,{path:"redis",element:t.jsx(r.Suspense,{fallback:t.jsx(f,{}),children:t.jsx(Ss,{})})}),t.jsx(p,{path:"models",element:t.jsx(r.Suspense,{fallback:t.jsx(f,{}),children:t.jsx(_s,{})})}),t.jsx(p,{path:"notifications",element:t.jsx(r.Suspense,{fallback:t.jsx(f,{}),children:t.jsx(Es,{})})}),t.jsx(p,{path:"views",element:t.jsx(r.Suspense,{fallback:t.jsx(f,{}),children:t.jsx(Ns,{})})}),t.jsx(p,{path:"commands",element:t.jsx(r.Suspense,{fallback:t.jsx(f,{}),children:t.jsx(Ps,{})})}),t.jsx(p,{path:"gates",element:t.jsx(r.Suspense,{fallback:t.jsx(f,{}),children:t.jsx(Cs,{})})}),t.jsx(p,{path:"batches",element:t.jsx(r.Suspense,{fallback:t.jsx(f,{}),children:t.jsx(Rs,{})})}),t.jsx(p,{path:"dumps",element:t.jsx(r.Suspense,{fallback:t.jsx(f,{}),children:t.jsx(Ls,{})})}),t.jsx(p,{path:"graphql",element:t.jsx(r.Suspense,{fallback:t.jsx(f,{}),children:t.jsx(Ts,{})})}),t.jsx(p,{path:"requests/:id",element:t.jsx(r.Suspense,{fallback:t.jsx(f,{}),children:t.jsx(S,{})})}),t.jsx(p,{path:"queries/:id",element:t.jsx(r.Suspense,{fallback:t.jsx(f,{}),children:t.jsx(S,{})})}),t.jsx(p,{path:"exceptions/:id",element:t.jsx(r.Suspense,{fallback:t.jsx(f,{}),children:t.jsx(S,{})})}),t.jsx(p,{path:"logs/:id",element:t.jsx(r.Suspense,{fallback:t.jsx(f,{}),children:t.jsx(S,{})})}),t.jsx(p,{path:"events/:id",element:t.jsx(r.Suspense,{fallback:t.jsx(f,{}),children:t.jsx(S,{})})}),t.jsx(p,{path:"jobs/:id",element:t.jsx(r.Suspense,{fallback:t.jsx(f,{}),children:t.jsx(S,{})})}),t.jsx(p,{path:"cache/:id",element:t.jsx(r.Suspense,{fallback:t.jsx(f,{}),children:t.jsx(S,{})})}),t.jsx(p,{path:"mail/:id",element:t.jsx(r.Suspense,{fallback:t.jsx(f,{}),children:t.jsx(S,{})})}),t.jsx(p,{path:"schedule/:id",element:t.jsx(r.Suspense,{fallback:t.jsx(f,{}),children:t.jsx(S,{})})}),t.jsx(p,{path:"http-client/:id",element:t.jsx(r.Suspense,{fallback:t.jsx(f,{}),children:t.jsx(S,{})})}),t.jsx(p,{path:"redis/:id",element:t.jsx(r.Suspense,{fallback:t.jsx(f,{}),children:t.jsx(S,{})})}),t.jsx(p,{path:"models/:id",element:t.jsx(r.Suspense,{fallback:t.jsx(f,{}),children:t.jsx(S,{})})}),t.jsx(p,{path:"notifications/:id",element:t.jsx(r.Suspense,{fallback:t.jsx(f,{}),children:t.jsx(S,{})})}),t.jsx(p,{path:"views/:id",element:t.jsx(r.Suspense,{fallback:t.jsx(f,{}),children:t.jsx(S,{})})}),t.jsx(p,{path:"commands/:id",element:t.jsx(r.Suspense,{fallback:t.jsx(f,{}),children:t.jsx(S,{})})}),t.jsx(p,{path:"gates/:id",element:t.jsx(r.Suspense,{fallback:t.jsx(f,{}),children:t.jsx(S,{})})}),t.jsx(p,{path:"batches/:id",element:t.jsx(r.Suspense,{fallback:t.jsx(f,{}),children:t.jsx(S,{})})}),t.jsx(p,{path:"dumps/:id",element:t.jsx(r.Suspense,{fallback:t.jsx(f,{}),children:t.jsx(S,{})})}),t.jsx(p,{path:"graphql/:id",element:t.jsx(r.Suspense,{fallback:t.jsx(f,{}),children:t.jsx(S,{})})}),t.jsx(p,{path:"entries/:id",element:t.jsx(r.Suspense,{fallback:t.jsx(f,{}),children:t.jsx(S,{})})}),t.jsx(p,{path:"*",element:t.jsx(Me,{to:"/",replace:!0})})]})})}const Os=1e4;function Ds({children:s}){const[a,e]=r.useState(null),[i,l]=r.useState(null),o=r.useRef(!0),n=r.useRef(!0),c=r.useCallback(d=>{n.current&&(e(d),l(null),o.current=!1)},[]),u=r.useCallback(d=>{if(!n.current)return;const h=d instanceof Error?d:new Error("Failed to fetch stats");l(h),console.error("Failed to fetch stats:",d),o.current&&q.error("Failed to load statistics"),o.current=!1},[]),x=r.useCallback(async()=>ce().then(d=>c(d.data),d=>u(d)),[c,u]);return r.useEffect(()=>{n.current=!0;const d=setInterval(()=>void x(),Os);return ce().then(h=>c(h.data),u),()=>{n.current=!1,clearInterval(d)}},[x,c,u]),t.jsx(Ee.Provider,{value:{stats:a,error:i,refreshStats:x},children:s})}const Ne=document.getElementById("root");if(!Ne)throw new Error("NestLens dashboard: no #root element in the served index.html");Be.createRoot(Ne).render(t.jsx(qe.StrictMode,{children:t.jsx(_e,{children:t.jsx($e,{basename:we(),children:t.jsxs(Ds,{children:[t.jsx(As,{}),t.jsx(Lt,{position:"bottom-right",toastOptions:{duration:3e3,style:{background:"#1f2937",color:"#f3f4f6",borderRadius:"0.5rem"},success:{iconTheme:{primary:"#10b981",secondary:"#f3f4f6"}},error:{iconTheme:{primary:"#ef4444",secondary:"#f3f4f6"}}}})]})})})}));export{qt as A,It as B,Kt as C,Vt as D,Bt as F,Ft as G,ne as H,Gt as L,Jt as M,Qt as P,es as R,ss as S,ve as T,rs as X,v as _,as as a,zt as b,g as c,Ht as d,$t as e,Zt as f,ae as g,le as h,ts as i,t as j,Vs as k,Bs as l,zs as m,Gs as n,Hs as o,ns as p,Is as q,Fs as r,Ks as s,se as t,us as u,$s as v,Yt as w,q as z};
@@ -1,4 +1,4 @@
1
- import{c}from"./index-f3yHnTBu.js";/**
1
+ import{c}from"./index-B1QFrlfD.js";/**
2
2
  * @license lucide-react v0.468.0 - ISC
3
3
  *
4
4
  * This source code is licensed under the ISC license.
@@ -1,4 +1,4 @@
1
- import{c as a}from"./index-f3yHnTBu.js";/**
1
+ import{c as a}from"./index-B1QFrlfD.js";/**
2
2
  * @license lucide-react v0.468.0 - ISC
3
3
  *
4
4
  * This source code is licensed under the ISC license.
@@ -1,4 +1,4 @@
1
- import{c as e}from"./index-f3yHnTBu.js";/**
1
+ import{c as e}from"./index-B1QFrlfD.js";/**
2
2
  * @license lucide-react v0.468.0 - ISC
3
3
  *
4
4
  * This source code is licensed under the ISC license.
@@ -1 +1 @@
1
- import{j as E}from"./index-f3yHnTBu.js";import{f as C,b as d,e as L,u as R}from"./vendor-DBTT3jXp.js";import{g as w,h as q}from"./badgeColors-DQ_P_DOX.js";const T={request:{displayName:"Request",pluralName:"Requests",route:"requests",icon:"Globe",filters:{methods:{urlKey:"methods",displayName:"Method",values:["GET","POST","PUT","PATCH","DELETE","HEAD","OPTIONS","GRAPHQL"]},statuses:{urlKey:"statuses",displayName:"Status",values:[]},paths:{urlKey:"paths",displayName:"Path",values:[]},controllers:{urlKey:"controllers",displayName:"Controller",values:[]},hostnames:{urlKey:"hostnames",displayName:"Hostname",values:[]},ips:{urlKey:"ips",displayName:"IP",values:[]}}},query:{displayName:"Query",pluralName:"Queries",route:"queries",icon:"Database",filters:{types:{urlKey:"queryTypes",displayName:"Type",values:["SELECT","INSERT","UPDATE","DELETE","CREATE","ALTER","DROP","TRUNCATE"]},sources:{urlKey:"sources",displayName:"Source",values:["typeorm","prisma","mongoose","sequelize","knex","mikro-orm","drizzle"]}}},exception:{displayName:"Exception",pluralName:"Exceptions",route:"exceptions",icon:"AlertTriangle",filters:{names:{urlKey:"names",displayName:"Name",values:[]},methods:{urlKey:"methods",displayName:"Method",values:["GET","POST","PUT","PATCH","DELETE","HEAD","OPTIONS"]},paths:{urlKey:"paths",displayName:"Path",values:[]}}},log:{displayName:"Log",pluralName:"Logs",route:"logs",icon:"FileText",filters:{levels:{urlKey:"levels",displayName:"Level",values:["log","error","warn","debug","verbose","fatal","info"]},contexts:{urlKey:"contexts",displayName:"Context",values:[]}}},event:{displayName:"Event",pluralName:"Events",route:"events",icon:"Zap",filters:{names:{urlKey:"eventNames",displayName:"Event",values:[]}}},job:{displayName:"Job",pluralName:"Jobs",route:"jobs",icon:"Briefcase",filters:{names:{urlKey:"jobNames",displayName:"Job",values:[]},statuses:{urlKey:"jobStatuses",displayName:"Status",values:["waiting","active","completed","failed","delayed","paused","stuck"]},queues:{urlKey:"queues",displayName:"Queue",values:[]}}},schedule:{displayName:"Schedule",pluralName:"Schedule",route:"schedule",icon:"Clock",filters:{names:{urlKey:"scheduleNames",displayName:"Task",values:[]},statuses:{urlKey:"scheduleStatuses",displayName:"Status",values:["started","completed","failed","skipped","running"]}}},cache:{displayName:"Cache",pluralName:"Cache",route:"cache",icon:"HardDrive",filters:{operations:{urlKey:"cacheOperations",displayName:"Operation",values:["get","set","del","clear","has","reset","mget","mset"]}}},mail:{displayName:"Mail",pluralName:"Mail",route:"mail",icon:"Mail",filters:{statuses:{urlKey:"mailStatuses",displayName:"Status",values:["sent","failed","pending","queued","delivered","bounced","error"]}}},"http-client":{displayName:"HTTP Client",pluralName:"HTTP Client",route:"http-client",icon:"Globe",filters:{methods:{urlKey:"methods",displayName:"Method",values:["GET","POST","PUT","PATCH","DELETE","HEAD","OPTIONS"]},statuses:{urlKey:"statuses",displayName:"Status",values:[]},hostnames:{urlKey:"hostnames",displayName:"Hostname",values:[]}}},redis:{displayName:"Redis",pluralName:"Redis",route:"redis",icon:"Database",filters:{commands:{urlKey:"redisCommands",displayName:"Command",values:["GET","SET","DEL","HGET","HSET","HDEL","HGETALL","LPUSH","RPUSH","LPOP","RPOP","LRANGE","SADD","SREM","SMEMBERS","ZADD","ZRANGE","ZREM","EXPIRE","TTL","KEYS","SCAN","PING","INFO","INCR","DECR","MGET","MSET","PUBLISH","SUBSCRIBE"]},statuses:{urlKey:"redisStatuses",displayName:"Status",values:["success","failed","error","timeout"]}}},model:{displayName:"Model",pluralName:"Models",route:"models",icon:"Box",filters:{actions:{urlKey:"modelActions",displayName:"Action",values:["find","findOne","findMany","create","update","delete","save","remove","count","aggregate","upsert","createMany","updateMany","deleteMany"]},entities:{urlKey:"entities",displayName:"Entity",values:[]},sources:{urlKey:"modelSources",displayName:"Source",values:["typeorm","prisma","mongoose","sequelize","mikro-orm","drizzle"]}}},notification:{displayName:"Notification",pluralName:"Notifications",route:"notifications",icon:"Bell",filters:{types:{urlKey:"notificationTypes",displayName:"Type",values:["email","sms","push","socket","webhook","slack","telegram","discord"]},statuses:{urlKey:"notificationStatuses",displayName:"Status",values:["sent","failed","pending","delivered","read","error","queued"]}}},view:{displayName:"View",pluralName:"Views",route:"views",icon:"Layout",filters:{formats:{urlKey:"viewFormats",displayName:"Format",values:["html","json","xml","pdf","csv","text","markdown"]},statuses:{urlKey:"viewStatuses",displayName:"Status",values:["rendered","error","failed","cached","success"]}}},command:{displayName:"Command",pluralName:"Commands",route:"commands",icon:"Terminal",filters:{statuses:{urlKey:"commandStatuses",displayName:"Status",values:["executing","completed","failed","cancelled","timeout","running"]},names:{urlKey:"commandNames",displayName:"Command",values:[]}}},gate:{displayName:"Gate",pluralName:"Gates",route:"gates",icon:"Shield",filters:{names:{urlKey:"gateNames",displayName:"Gate",values:[]},results:{urlKey:"gateResults",displayName:"Result",values:["allowed","denied"]}}},batch:{displayName:"Batch",pluralName:"Batches",route:"batches",icon:"Layers",filters:{operations:{urlKey:"batchOperations",displayName:"Operation",values:["insert","update","delete","upsert","sync"]},statuses:{urlKey:"batchStatuses",displayName:"Status",values:["pending","processing","completed","failed","partial","cancelled"]}}},dump:{displayName:"Dump",pluralName:"Dumps",route:"dumps",icon:"HardDrive",filters:{operations:{urlKey:"dumpOperations",displayName:"Operation",values:["export","import","backup","restore","migrate","sync"]},formats:{urlKey:"dumpFormats",displayName:"Format",values:["json","csv","xml","sql","yaml","binary","xlsx"]},statuses:{urlKey:"dumpStatuses",displayName:"Status",values:["pending","completed","failed","error","success","cancelled","running"]}}},graphql:{displayName:"GraphQL",pluralName:"GraphQL",route:"graphql",icon:"Hexagon",filters:{operationTypes:{urlKey:"operationTypes",displayName:"Type",values:["query","mutation","subscription"]},operationNames:{urlKey:"operationNames",displayName:"Operation",values:[]},statuses:{urlKey:"statuses",displayName:"Status",values:[]},ips:{urlKey:"ips",displayName:"IP",values:[]}}}},k={requests:"request",queries:"query",exceptions:"exception",logs:"log",events:"event",jobs:"job",schedule:"schedule",cache:"cache",mail:"mail","http-client":"http-client",redis:"redis",models:"model",notifications:"notification",views:"view",commands:"command",gates:"gate",batches:"batch",dumps:"dump",graphql:"graphql"};function O(e){if(e in T)return T[e];const s=k[e];if(s)return T[s]}const x=O;function B(e){const[s,i]=C(),a=x(e),c=d.useCallback(r=>{if(r==="tags")return"tags";if(!a)return r;const t=a.filters[r];return(t==null?void 0:t.urlKey)||r},[a]),u=d.useMemo(()=>{const r={};if(!a)return r;const t=Object.values(a.filters).map(l=>l.urlKey);t.push("tags","search");for(const l of t){const n=s.get(l);n&&(r[l]=n.split(",").filter(Boolean))}return r},[s,a]),N=d.useCallback((r,t)=>{!a&&r!=="tags"&&console.warn("[useEntryFilters] No config found for entry type, using category as urlKey");const l=c(r),n=u[l]||[];if(!n.includes(t)){const o=new URLSearchParams(s);o.set(l,[...n,t].join(",")),i(o,{replace:!0})}},[a,c,u,s,i]),p=d.useCallback((r,t)=>{const n=(u[r]||[]).filter(f=>f!==t),o=new URLSearchParams(s);n.length>0?o.set(r,n.join(",")):o.delete(r),i(o,{replace:!0})},[u,s,i]),S=d.useCallback(()=>{i({},{replace:!0})},[i]),g=d.useMemo(()=>u,[u]),y=d.useMemo(()=>{if(!a)return[];const r=[];for(const[t,l]of Object.entries(u)){if(l.length===0)continue;let n=t,o=t==="tags"?"Tag":t;for(const[f,h]of Object.entries(a.filters))if(h.urlKey===t){n=f,o=h.displayName;break}r.push({category:n,urlKey:t,displayName:o,values:l})}return r},[u,a]),m=d.useMemo(()=>{const r=[];for(const t of y)for(const l of t.values)r.push({category:t.displayName,value:l.toUpperCase(),onRemove:()=>p(t.urlKey,l)});return r},[y,p]),K=y.length>0;return{addFilter:N,removeFilter:p,clearAll:S,serverFilters:g,activeFilters:y,headerFilters:m,hasFilters:K,getUrlKey:c}}function D(e,s){if(s==="tags")return"tags";const i=x(e);if(!i)return s;const a=i.filters[s];return(a==null?void 0:a.urlKey)||s}const M=["localhost"],A=(e,s)=>{if(s&&s!=="tag")return s;if(/^user:/i.test(e))return"tags";if(/^(\d{1,3}\.){3}\d{1,3}$/.test(e))return"ips";const i=e.toUpperCase();if(q.includes(i))return"methods";const a=parseInt(e,10);return!isNaN(a)&&a>=100&&a<600?"statuses":/^[a-fA-F0-9:]+$/.test(e)&&e.includes(":")&&!e.includes(".")?"ips":e.includes("#")||e.includes("::")||/Controller\./i.test(e)?"controllers":M.includes(e.toLowerCase())||(e.includes(".")||e.includes(":"))&&!e.startsWith("/")&&!/^\d+$/.test(e)?"hostnames":"tags"};function H({children:e,listType:s,filterType:i="tag",filterValue:a,onClick:c,clickable:u=!0,className:N="",ariaLabel:p}){const S=L(),g=R(),y=n=>{if(n.preventDefault(),n.stopPropagation(),c){c(n);return}if(s&&u){const o=a||String(e),f=i&&i!=="tag"?D(s,i):A(o,i),h=g.pathname,v=h===`/${s}`||h.startsWith(`/${s}/`)?new URLSearchParams(g.search):new URLSearchParams,b=v.get(f);if(b){const P=b.split(",");P.includes(o)||v.set(f,[...P,o].join(","))}else v.set(f,o);S(`/${s}?${v.toString()}`)}},m=u&&(!!c||!!s),K=w(String(e)),r=m?"cursor-pointer hover:scale-105 transition-transform":"",t=String(e).toUpperCase(),l=p||(m?`Click to filter by ${t}`:void 0);return E.jsx("span",{onClick:m?y:void 0,role:m?"button":void 0,"aria-label":l,tabIndex:m?0:void 0,onKeyDown:m?n=>{(n.key==="Enter"||n.key===" ")&&(n.preventDefault(),y(n))}:void 0,title:t,className:`inline-flex items-center px-2 py-0.5 rounded text-xs font-bold uppercase tracking-wide max-w-[200px] overflow-hidden text-ellipsis whitespace-nowrap shadow ${K} ${r} ${m?"focus:outline-none focus:ring-2 focus:ring-primary-500 focus:ring-offset-1":""} ${N}`,children:t})}function I({items:e,listType:s,filterType:i="tag",maxItems:a=99,clickable:c=!0}){if(!e||e.length===0)return null;const u=e.slice(0,a),N=e.length-a;return E.jsxs("div",{className:"flex flex-wrap items-center gap-1",children:[u.map(p=>E.jsx(H,{listType:s,filterType:i,clickable:c,children:p},p)),N>0&&E.jsxs("span",{className:"text-xs text-gray-500 dark:text-gray-400",children:["+",N]})]})}function $(e){return e.type==="request"}function Q(e){return e.type==="query"}function V(e){return e.type==="exception"}function z(e){return e.type==="log"}function J(e){return e.type==="cache"}function Y(e){return e.type==="event"}function Z(e){return e.type==="job"}function _(e){return e.type==="schedule"}function W(e){return e.type==="mail"}function X(e){return e.type==="http-client"}function ee(e){return e.type==="redis"}function se(e){return e.type==="model"}function te(e){return e.type==="notification"}function ae(e){return e.type==="view"}function re(e){return e.type==="command"}function ne(e){return e.type==="gate"}function ie(e){return e.type==="batch"}function le(e){return e.type==="dump"}function oe(e){return e.type==="graphql"}export{I as B,H as C,Q as a,V as b,z as c,Y as d,Z as e,J as f,W as g,_ as h,$ as i,X as j,ee as k,se as l,te as m,ae as n,re as o,ne as p,ie as q,le as r,oe as s,B as u};
1
+ import{j as E}from"./index-B1QFrlfD.js";import{f as C,b as d,e as L,u as R}from"./vendor-DBTT3jXp.js";import{g as w,h as q}from"./badgeColors-DQ_P_DOX.js";const T={request:{displayName:"Request",pluralName:"Requests",route:"requests",icon:"Globe",filters:{methods:{urlKey:"methods",displayName:"Method",values:["GET","POST","PUT","PATCH","DELETE","HEAD","OPTIONS","GRAPHQL"]},statuses:{urlKey:"statuses",displayName:"Status",values:[]},paths:{urlKey:"paths",displayName:"Path",values:[]},controllers:{urlKey:"controllers",displayName:"Controller",values:[]},hostnames:{urlKey:"hostnames",displayName:"Hostname",values:[]},ips:{urlKey:"ips",displayName:"IP",values:[]}}},query:{displayName:"Query",pluralName:"Queries",route:"queries",icon:"Database",filters:{types:{urlKey:"queryTypes",displayName:"Type",values:["SELECT","INSERT","UPDATE","DELETE","CREATE","ALTER","DROP","TRUNCATE"]},sources:{urlKey:"sources",displayName:"Source",values:["typeorm","prisma","mongoose","sequelize","knex","mikro-orm","drizzle"]}}},exception:{displayName:"Exception",pluralName:"Exceptions",route:"exceptions",icon:"AlertTriangle",filters:{names:{urlKey:"names",displayName:"Name",values:[]},methods:{urlKey:"methods",displayName:"Method",values:["GET","POST","PUT","PATCH","DELETE","HEAD","OPTIONS"]},paths:{urlKey:"paths",displayName:"Path",values:[]}}},log:{displayName:"Log",pluralName:"Logs",route:"logs",icon:"FileText",filters:{levels:{urlKey:"levels",displayName:"Level",values:["log","error","warn","debug","verbose","fatal","info"]},contexts:{urlKey:"contexts",displayName:"Context",values:[]}}},event:{displayName:"Event",pluralName:"Events",route:"events",icon:"Zap",filters:{names:{urlKey:"eventNames",displayName:"Event",values:[]}}},job:{displayName:"Job",pluralName:"Jobs",route:"jobs",icon:"Briefcase",filters:{names:{urlKey:"jobNames",displayName:"Job",values:[]},statuses:{urlKey:"jobStatuses",displayName:"Status",values:["waiting","active","completed","failed","delayed","paused","stuck"]},queues:{urlKey:"queues",displayName:"Queue",values:[]}}},schedule:{displayName:"Schedule",pluralName:"Schedule",route:"schedule",icon:"Clock",filters:{names:{urlKey:"scheduleNames",displayName:"Task",values:[]},statuses:{urlKey:"scheduleStatuses",displayName:"Status",values:["started","completed","failed","skipped","running"]}}},cache:{displayName:"Cache",pluralName:"Cache",route:"cache",icon:"HardDrive",filters:{operations:{urlKey:"cacheOperations",displayName:"Operation",values:["get","set","del","clear","has","reset","mget","mset"]}}},mail:{displayName:"Mail",pluralName:"Mail",route:"mail",icon:"Mail",filters:{statuses:{urlKey:"mailStatuses",displayName:"Status",values:["sent","failed","pending","queued","delivered","bounced","error"]}}},"http-client":{displayName:"HTTP Client",pluralName:"HTTP Client",route:"http-client",icon:"Globe",filters:{methods:{urlKey:"methods",displayName:"Method",values:["GET","POST","PUT","PATCH","DELETE","HEAD","OPTIONS"]},statuses:{urlKey:"statuses",displayName:"Status",values:[]},hostnames:{urlKey:"hostnames",displayName:"Hostname",values:[]}}},redis:{displayName:"Redis",pluralName:"Redis",route:"redis",icon:"Database",filters:{commands:{urlKey:"redisCommands",displayName:"Command",values:["GET","SET","DEL","HGET","HSET","HDEL","HGETALL","LPUSH","RPUSH","LPOP","RPOP","LRANGE","SADD","SREM","SMEMBERS","ZADD","ZRANGE","ZREM","EXPIRE","TTL","KEYS","SCAN","PING","INFO","INCR","DECR","MGET","MSET","PUBLISH","SUBSCRIBE"]},statuses:{urlKey:"redisStatuses",displayName:"Status",values:["success","failed","error","timeout"]}}},model:{displayName:"Model",pluralName:"Models",route:"models",icon:"Box",filters:{actions:{urlKey:"modelActions",displayName:"Action",values:["find","findOne","findMany","create","update","delete","save","remove","count","aggregate","upsert","createMany","updateMany","deleteMany"]},entities:{urlKey:"entities",displayName:"Entity",values:[]},sources:{urlKey:"modelSources",displayName:"Source",values:["typeorm","prisma","mongoose","sequelize","mikro-orm","drizzle"]}}},notification:{displayName:"Notification",pluralName:"Notifications",route:"notifications",icon:"Bell",filters:{types:{urlKey:"notificationTypes",displayName:"Type",values:["email","sms","push","socket","webhook","slack","telegram","discord"]},statuses:{urlKey:"notificationStatuses",displayName:"Status",values:["sent","failed","pending","delivered","read","error","queued"]}}},view:{displayName:"View",pluralName:"Views",route:"views",icon:"Layout",filters:{formats:{urlKey:"viewFormats",displayName:"Format",values:["html","json","xml","pdf","csv","text","markdown"]},statuses:{urlKey:"viewStatuses",displayName:"Status",values:["rendered","error","failed","cached","success"]}}},command:{displayName:"Command",pluralName:"Commands",route:"commands",icon:"Terminal",filters:{statuses:{urlKey:"commandStatuses",displayName:"Status",values:["executing","completed","failed","cancelled","timeout","running"]},names:{urlKey:"commandNames",displayName:"Command",values:[]}}},gate:{displayName:"Gate",pluralName:"Gates",route:"gates",icon:"Shield",filters:{names:{urlKey:"gateNames",displayName:"Gate",values:[]},results:{urlKey:"gateResults",displayName:"Result",values:["allowed","denied"]}}},batch:{displayName:"Batch",pluralName:"Batches",route:"batches",icon:"Layers",filters:{operations:{urlKey:"batchOperations",displayName:"Operation",values:["insert","update","delete","upsert","sync"]},statuses:{urlKey:"batchStatuses",displayName:"Status",values:["pending","processing","completed","failed","partial","cancelled"]}}},dump:{displayName:"Dump",pluralName:"Dumps",route:"dumps",icon:"HardDrive",filters:{operations:{urlKey:"dumpOperations",displayName:"Operation",values:["export","import","backup","restore","migrate","sync"]},formats:{urlKey:"dumpFormats",displayName:"Format",values:["json","csv","xml","sql","yaml","binary","xlsx"]},statuses:{urlKey:"dumpStatuses",displayName:"Status",values:["pending","completed","failed","error","success","cancelled","running"]}}},graphql:{displayName:"GraphQL",pluralName:"GraphQL",route:"graphql",icon:"Hexagon",filters:{operationTypes:{urlKey:"operationTypes",displayName:"Type",values:["query","mutation","subscription"]},operationNames:{urlKey:"operationNames",displayName:"Operation",values:[]},statuses:{urlKey:"statuses",displayName:"Status",values:[]},ips:{urlKey:"ips",displayName:"IP",values:[]}}}},k={requests:"request",queries:"query",exceptions:"exception",logs:"log",events:"event",jobs:"job",schedule:"schedule",cache:"cache",mail:"mail","http-client":"http-client",redis:"redis",models:"model",notifications:"notification",views:"view",commands:"command",gates:"gate",batches:"batch",dumps:"dump",graphql:"graphql"};function O(e){if(e in T)return T[e];const s=k[e];if(s)return T[s]}const x=O;function B(e){const[s,i]=C(),a=x(e),c=d.useCallback(r=>{if(r==="tags")return"tags";if(!a)return r;const t=a.filters[r];return(t==null?void 0:t.urlKey)||r},[a]),u=d.useMemo(()=>{const r={};if(!a)return r;const t=Object.values(a.filters).map(l=>l.urlKey);t.push("tags","search");for(const l of t){const n=s.get(l);n&&(r[l]=n.split(",").filter(Boolean))}return r},[s,a]),N=d.useCallback((r,t)=>{!a&&r!=="tags"&&console.warn("[useEntryFilters] No config found for entry type, using category as urlKey");const l=c(r),n=u[l]||[];if(!n.includes(t)){const o=new URLSearchParams(s);o.set(l,[...n,t].join(",")),i(o,{replace:!0})}},[a,c,u,s,i]),p=d.useCallback((r,t)=>{const n=(u[r]||[]).filter(f=>f!==t),o=new URLSearchParams(s);n.length>0?o.set(r,n.join(",")):o.delete(r),i(o,{replace:!0})},[u,s,i]),S=d.useCallback(()=>{i({},{replace:!0})},[i]),g=d.useMemo(()=>u,[u]),y=d.useMemo(()=>{if(!a)return[];const r=[];for(const[t,l]of Object.entries(u)){if(l.length===0)continue;let n=t,o=t==="tags"?"Tag":t;for(const[f,h]of Object.entries(a.filters))if(h.urlKey===t){n=f,o=h.displayName;break}r.push({category:n,urlKey:t,displayName:o,values:l})}return r},[u,a]),m=d.useMemo(()=>{const r=[];for(const t of y)for(const l of t.values)r.push({category:t.displayName,value:l.toUpperCase(),onRemove:()=>p(t.urlKey,l)});return r},[y,p]),K=y.length>0;return{addFilter:N,removeFilter:p,clearAll:S,serverFilters:g,activeFilters:y,headerFilters:m,hasFilters:K,getUrlKey:c}}function D(e,s){if(s==="tags")return"tags";const i=x(e);if(!i)return s;const a=i.filters[s];return(a==null?void 0:a.urlKey)||s}const M=["localhost"],A=(e,s)=>{if(s&&s!=="tag")return s;if(/^user:/i.test(e))return"tags";if(/^(\d{1,3}\.){3}\d{1,3}$/.test(e))return"ips";const i=e.toUpperCase();if(q.includes(i))return"methods";const a=parseInt(e,10);return!isNaN(a)&&a>=100&&a<600?"statuses":/^[a-fA-F0-9:]+$/.test(e)&&e.includes(":")&&!e.includes(".")?"ips":e.includes("#")||e.includes("::")||/Controller\./i.test(e)?"controllers":M.includes(e.toLowerCase())||(e.includes(".")||e.includes(":"))&&!e.startsWith("/")&&!/^\d+$/.test(e)?"hostnames":"tags"};function H({children:e,listType:s,filterType:i="tag",filterValue:a,onClick:c,clickable:u=!0,className:N="",ariaLabel:p}){const S=L(),g=R(),y=n=>{if(n.preventDefault(),n.stopPropagation(),c){c(n);return}if(s&&u){const o=a||String(e),f=i&&i!=="tag"?D(s,i):A(o,i),h=g.pathname,v=h===`/${s}`||h.startsWith(`/${s}/`)?new URLSearchParams(g.search):new URLSearchParams,b=v.get(f);if(b){const P=b.split(",");P.includes(o)||v.set(f,[...P,o].join(","))}else v.set(f,o);S(`/${s}?${v.toString()}`)}},m=u&&(!!c||!!s),K=w(String(e)),r=m?"cursor-pointer hover:scale-105 transition-transform":"",t=String(e).toUpperCase(),l=p||(m?`Click to filter by ${t}`:void 0);return E.jsx("span",{onClick:m?y:void 0,role:m?"button":void 0,"aria-label":l,tabIndex:m?0:void 0,onKeyDown:m?n=>{(n.key==="Enter"||n.key===" ")&&(n.preventDefault(),y(n))}:void 0,title:t,className:`inline-flex items-center px-2 py-0.5 rounded text-xs font-bold uppercase tracking-wide max-w-[200px] overflow-hidden text-ellipsis whitespace-nowrap shadow ${K} ${r} ${m?"focus:outline-none focus:ring-2 focus:ring-primary-500 focus:ring-offset-1":""} ${N}`,children:t})}function I({items:e,listType:s,filterType:i="tag",maxItems:a=99,clickable:c=!0}){if(!e||e.length===0)return null;const u=e.slice(0,a),N=e.length-a;return E.jsxs("div",{className:"flex flex-wrap items-center gap-1",children:[u.map(p=>E.jsx(H,{listType:s,filterType:i,clickable:c,children:p},p)),N>0&&E.jsxs("span",{className:"text-xs text-gray-500 dark:text-gray-400",children:["+",N]})]})}function $(e){return e.type==="request"}function Q(e){return e.type==="query"}function V(e){return e.type==="exception"}function z(e){return e.type==="log"}function J(e){return e.type==="cache"}function Y(e){return e.type==="event"}function Z(e){return e.type==="job"}function _(e){return e.type==="schedule"}function W(e){return e.type==="mail"}function X(e){return e.type==="http-client"}function ee(e){return e.type==="redis"}function se(e){return e.type==="model"}function te(e){return e.type==="notification"}function ae(e){return e.type==="view"}function re(e){return e.type==="command"}function ne(e){return e.type==="gate"}function ie(e){return e.type==="batch"}function le(e){return e.type==="dump"}function oe(e){return e.type==="graphql"}export{I as B,H as C,Q as a,V as b,z as c,Y as d,Z as e,J as f,W as g,_ as h,$ as i,X as j,ee as k,se as l,te as m,ae as n,re as o,ne as p,ie as q,le as r,oe as s,B as u};
@@ -1,4 +1,4 @@
1
- import{c as e}from"./index-f3yHnTBu.js";/**
1
+ import{c as e}from"./index-B1QFrlfD.js";/**
2
2
  * @license lucide-react v0.468.0 - ISC
3
3
  *
4
4
  * This source code is licensed under the ISC license.
@@ -1,4 +1,4 @@
1
- import{c as a}from"./index-f3yHnTBu.js";/**
1
+ import{c as a}from"./index-B1QFrlfD.js";/**
2
2
  * @license lucide-react v0.468.0 - ISC
3
3
  *
4
4
  * This source code is licensed under the ISC license.
@@ -5,7 +5,7 @@
5
5
  <link rel="icon" type="image/svg+xml" href="./nestlens-icon.svg" />
6
6
  <meta name="viewport" content="width=device-width, initial-scale=1.0" />
7
7
  <title>NestLens - Debug Dashboard</title>
8
- <script type="module" crossorigin src="./assets/index-f3yHnTBu.js"></script>
8
+ <script type="module" crossorigin src="./assets/index-B1QFrlfD.js"></script>
9
9
  <link rel="modulepreload" crossorigin href="./assets/vendor-DBTT3jXp.js">
10
10
  <link rel="stylesheet" crossorigin href="./assets/index-B9BCPNKv.css">
11
11
  </head>
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "nestlens",
3
- "version": "0.9.3",
3
+ "version": "0.9.4",
4
4
  "description": "Laravel Telescope-like debugging and monitoring tool for NestJS",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",