bunqueue-dashboard 1.0.2 → 1.0.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 (123) hide show
  1. package/README.md +8 -7
  2. package/agent/manager/config.ts +2 -1
  3. package/agent/server/handler.ts +2 -1
  4. package/agent/server/router.ts +1 -0
  5. package/agent/server/types.ts +1 -1
  6. package/agent/workflow/runtime.ts +25 -7
  7. package/agent/workflow/runtimeRoutes.ts +4 -1
  8. package/dist/.vite/manifest.json +341 -603
  9. package/dist/assets/AddJob-Dgjlhzn2.js +3 -0
  10. package/dist/assets/Alerts-Lyzbq0qw.js +1 -0
  11. package/dist/assets/{AreaChart-Db2UVnaK.js → AreaChart-CSP0-00u.js} +1 -1
  12. package/dist/assets/Benchmark-B4NfYkAi.js +1 -0
  13. package/dist/assets/{BulkAddJobs-GRMVnf0j.js → BulkAddJobs-BAN5wT8A.js} +3 -3
  14. package/dist/assets/Cron-Bz46oVXB.js +1 -0
  15. package/dist/assets/CronManager-Cl5RW2cB.js +1 -0
  16. package/dist/assets/Database-CeUKS6Nf.js +3 -0
  17. package/dist/assets/Diagnostics-DuzTPfyb.js +1 -0
  18. package/dist/assets/Dlq-D8s-NhV2.js +1 -0
  19. package/dist/assets/DlqControl-DDxRMM8i.js +1 -0
  20. package/dist/assets/DlqPro-xj-MM6u8.js +1 -0
  21. package/dist/assets/Fleet-BAziMWfo.js +1 -0
  22. package/dist/assets/Flows-BFUMTSWv.js +2 -0
  23. package/dist/assets/JobInspector-BXuXxDwR.js +2 -0
  24. package/dist/assets/Jobs-pQBmffni.js +1 -0
  25. package/dist/assets/JobsPro-k20Pas24.js +1 -0
  26. package/dist/assets/Logs-DA4JFvpM.js +1 -0
  27. package/dist/assets/LogsPro-hna5L6sP.js +1 -0
  28. package/dist/assets/McpServer-Cqem-L3z.js +22 -0
  29. package/dist/assets/Metrics-CJ9dW0me.js +1 -0
  30. package/dist/assets/MetricsPro-BslYrx1A.js +1 -0
  31. package/dist/assets/Overview-Cmg_2NAt.js +1 -0
  32. package/dist/assets/Pagination-WVfHLHDS.js +1 -0
  33. package/dist/assets/{QueueActions-BBxRt-t0.js → QueueActions-BQf1-g5m.js} +1 -1
  34. package/dist/assets/QueueControl-BiMM0jLp.js +1 -0
  35. package/dist/assets/QueueDetail-DfRY4jS4.js +1 -0
  36. package/dist/assets/QueueDetailPro-CpSMSo8A.js +1 -0
  37. package/dist/assets/Queues-C5lElTjp.js +1 -0
  38. package/dist/assets/QueuesOverview-DRohFtuC.js +1 -0
  39. package/dist/assets/S3Backup-DUHmp2Xw.js +1 -0
  40. package/dist/assets/S3BackupPro-Cr2ZJZkw.js +3 -0
  41. package/dist/assets/ServerControl-m58ooJT2.js +3 -0
  42. package/dist/assets/Settings-DXsjoOqD.js +1 -0
  43. package/dist/assets/{StatusBadge-DereLzOj.js → StatusBadge-D-mexaga.js} +1 -1
  44. package/dist/assets/Usage-CY2uEJEu.js +1 -0
  45. package/dist/assets/UsagePro-DtlB1dJc.js +1 -0
  46. package/dist/assets/Webhooks-B_GwTCBW.js +1 -0
  47. package/dist/assets/Workers-Bu8aJlZf.js +1 -0
  48. package/dist/assets/WorkersPro-C6gNYGfo.js +1 -0
  49. package/dist/assets/Workflows-ClF4YzhW.js +1 -0
  50. package/dist/assets/{api-D9aT0ND7.js → api-CCgfskjt.js} +1 -1
  51. package/dist/assets/{classicJobsData-Csj4iihY.js → classicJobsData-wdIr-E4y.js} +1 -1
  52. package/dist/assets/connectionStore-B946Fhuv.js +1 -0
  53. package/dist/assets/controlConnectionEpoch-x9VjrWgN.js +1 -0
  54. package/dist/assets/{form-DG3X6cLL.js → form-DBkslwzu.js} +1 -1
  55. package/dist/assets/{icons-DH9SS1DA.js → icons-BIT5aq1c.js} +1 -1
  56. package/dist/assets/index-DR8flo6r.css +1 -0
  57. package/dist/assets/index-X_fHGbXZ.js +8 -0
  58. package/dist/assets/install-hFu5e6YM.js +3 -0
  59. package/dist/assets/package-Bb3FkjoS.js +1 -0
  60. package/dist/assets/react-vendor-08inPAVO.js +11 -0
  61. package/dist/assets/responses-YgpvqWEr.js +1 -0
  62. package/dist/assets/rolldown-runtime-XKyaHtl9.js +1 -0
  63. package/dist/assets/{useControlActionGuard-1i7aFA7E.js → useControlActionGuard-Bx5MkufG.js} +1 -1
  64. package/dist/assets/{useServerActionGuard-CUx8TOAC.js → useServerActionGuard-uiZWD3dS.js} +1 -1
  65. package/dist/assets/useThroughputSeries-BN5QmKPt.js +1 -0
  66. package/dist/index.html +8 -16
  67. package/package.json +46 -56
  68. package/scripts/embedded.gen.ts +140 -154
  69. package/dist/assets/AddJob-CiwWycYG.js +0 -3
  70. package/dist/assets/Alerts-DCKl_C8D.js +0 -1
  71. package/dist/assets/Benchmark-DyHvEM8x.js +0 -1
  72. package/dist/assets/Button-_aSJvRoW.js +0 -1
  73. package/dist/assets/Card-egIDLwVk.js +0 -1
  74. package/dist/assets/Cron-XL0PdUEc.js +0 -1
  75. package/dist/assets/CronManager-Cqtg9Zr8.js +0 -1
  76. package/dist/assets/Database-BBzyi7f0.js +0 -3
  77. package/dist/assets/Diagnostics-E_icHggb.js +0 -1
  78. package/dist/assets/Dlq-DNs32CzV.js +0 -1
  79. package/dist/assets/DlqControl-DawwIsTI.js +0 -1
  80. package/dist/assets/DlqPro-BEdxFiNN.js +0 -1
  81. package/dist/assets/Fleet-Bkbq0dFB.js +0 -1
  82. package/dist/assets/Flows-DKZxI7ta.js +0 -2
  83. package/dist/assets/JobInspector-BARE52q3.js +0 -2
  84. package/dist/assets/Jobs-CKzKpQ7i.js +0 -1
  85. package/dist/assets/JobsPro-DxDw-akG.js +0 -1
  86. package/dist/assets/Logs-Bj60G_FP.js +0 -1
  87. package/dist/assets/LogsPro-Hv8xwXDK.js +0 -1
  88. package/dist/assets/McpServer-zxSMjG8K.js +0 -24
  89. package/dist/assets/Metrics-BBLdWOw1.js +0 -1
  90. package/dist/assets/MetricsPro-D470b1aP.js +0 -1
  91. package/dist/assets/Overview-B_AOa5kW.js +0 -1
  92. package/dist/assets/PageHeader-CQzNsw8r.js +0 -1
  93. package/dist/assets/Pagination-CSkzhNW6.js +0 -1
  94. package/dist/assets/QueueControl-DaZjeZnw.js +0 -1
  95. package/dist/assets/QueueDetail-Dgo9Ukmp.js +0 -1
  96. package/dist/assets/QueueDetailPro-D7U8ahp2.js +0 -1
  97. package/dist/assets/Queues-CS8LeZtJ.js +0 -1
  98. package/dist/assets/QueuesOverview-BySSnCm0.js +0 -1
  99. package/dist/assets/S3Backup-Ci4dJPP_.js +0 -1
  100. package/dist/assets/S3BackupPro-UwWu0yxr.js +0 -3
  101. package/dist/assets/ServerControl-Ch1wZcKB.js +0 -3
  102. package/dist/assets/Settings-FOzwrB25.js +0 -1
  103. package/dist/assets/Usage-DR90dCt0.js +0 -1
  104. package/dist/assets/UsagePro-DAlE3oCE.js +0 -1
  105. package/dist/assets/Webhooks-BonYUgMo.js +0 -1
  106. package/dist/assets/Workers-D1Ead02h.js +0 -1
  107. package/dist/assets/WorkersPro-XuLxtU4A.js +0 -1
  108. package/dist/assets/Workflows-CqZZ96EK.js +0 -1
  109. package/dist/assets/bq-DR2BTISO.js +0 -1
  110. package/dist/assets/connectionStore-CVjQyIZv.js +0 -1
  111. package/dist/assets/controlConnectionEpoch-ChAeMMLk.js +0 -1
  112. package/dist/assets/feedback-CtGN_kqB.js +0 -1
  113. package/dist/assets/format-Cg7VCIZW.js +0 -1
  114. package/dist/assets/index-DZFZr0Mi.js +0 -8
  115. package/dist/assets/index-DaEyLvTR.css +0 -1
  116. package/dist/assets/install-oydLpc1T.js +0 -3
  117. package/dist/assets/react-vendor-CFL9l8LK.js +0 -11
  118. package/dist/assets/responses-BkR2JTH9.js +0 -1
  119. package/dist/assets/rolldown-runtime-QTnfLwEv.js +0 -1
  120. package/dist/assets/toastStore-XmMX7A5W.js +0 -1
  121. package/dist/assets/usePolledData-CEyyLRYa.js +0 -1
  122. package/dist/assets/useThroughputSeries-CeFx-Mwq.js +0 -1
  123. package/patches/ai@7.0.14.patch +0 -25
@@ -0,0 +1 @@
1
+ import{o as e}from"./upstreamPaths-DQeKSxGc.js";var t=10485760,n=10485760;function r(e,t=1/0){let n=0;for(let r=0;r<e.length;r++){let i=e.charCodeAt(r);if(i<=127?n+=1:i<=2047?n+=2:i>=55296&&i<=56319&&r+1<e.length&&e.charCodeAt(r+1)>=56320&&e.charCodeAt(r+1)<=57343?(n+=4,r+=1):n+=3,n>t)return n}return n}function i(e){return e.length>10485760||r(e,10485760)>10485760?`Job data is too large (maximum 10 MiB UTF-8 / 10,485,760 characters)`:null}function a(e){let t=i(e);if(t)return{ok:!1,kind:`size`,msg:t};let n;try{n=JSON.parse(e)}catch(e){return{ok:!1,kind:`json`,msg:`Invalid JSON: ${e.message}`}}let a=JSON.stringify(n);return a.length>10485760||r(a,10485760)>10485760?{ok:!1,kind:`size`,msg:`Job data is too large after JSON encoding (maximum 10 MiB UTF-8)`}:{ok:!0,data:n}}var o=31536e6,s=864e5,c=2097151;function l(e,t=!1){let n=[{key:`priority`,label:t?`Group priority`:`Priority`,min:t?0:-1e6,max:t?c:1e6},{key:`delay`,label:`Delay`,min:0,max:o},{key:`maxAttempts`,label:`Max attempts`,min:1,max:1e3},{key:`backoff`,label:`Backoff`,min:0,max:s},{key:`timeout`,label:`Timeout`,min:0,max:s},{key:`ttl`,label:`TTL`,min:0,max:o},{key:`groupMaxSize`,label:`Group max size`,min:1,max:2**53-1}],r={};for(let t of n){let n=(e[t.key]??``).trim();if(!n)continue;let i=Number(n);if(!Number.isFinite(i))return{ok:!1,msg:`${t.label} must be a number`};if(!Number.isSafeInteger(i))return{ok:!1,msg:`${t.label} must be a whole, safe integer`};if(i<t.min||i>t.max)return{ok:!1,msg:`${t.label} must be between ${t.min} and ${t.max}`};r[t.key]=i}return{ok:!0,options:r}}function u(t){let n=e(t);return!t&&n?`Choose a queue`:n}function d(e,t){return e==null?t?{ok:!1,msg:`Backoff strategy needs a base delay in Backoff (ms)`}:{ok:!0,backoff:void 0}:{ok:!0,backoff:t?{type:t,delay:e}:e}}function f(e){if(!e.trim())return{ok:!0,repeat:void 0};try{let t=JSON.parse(e);if(typeof t!=`object`||!t||Array.isArray(t))return{ok:!1,msg:`Repeat must be a JSON object`};let n=t,r=new Set([`every`,`limit`,`pattern`]),i=Object.keys(n).filter(e=>!r.has(e));if(i.length)return{ok:!1,msg:`Unknown repeat option${i.length===1?``:`s`}: ${i.join(`, `)}`};if(n.pattern!==void 0)return{ok:!1,msg:`repeat.pattern is unsafe in bunqueue v2.9.3; use repeat.every or a Cron schedule`};let a=n.every;return!Number.isSafeInteger(a)||a<=0||a>31536e6?{ok:!1,msg:`Repeat "every" must be a whole number from 1 to ${o} ms`}:n.limit!==void 0&&(!Number.isSafeInteger(n.limit)||n.limit<1)?{ok:!1,msg:`Repeat "limit" must be a whole number of at least 1`}:{ok:!0,repeat:{every:a,...typeof n.limit==`number`?{limit:n.limit}:{}}}}catch(e){return{ok:!1,msg:`Repeat is not valid JSON: ${e.message}`}}}function p(e){let t=typeof e.backoff==`object`?e.backoff:void 0,n=e.backoffConfig??t;return{backoff:m(n?.delay??(typeof e.backoff==`number`?e.backoff:void 0)),backoffType:n?.type??``,tags:e.tags?.join(`, `)??``,groupId:e.groupId??``,ttl:m(e.ttl)}}var m=e=>e==null?``:String(e);function h(e,t){return{ok:!0,msg:`Accepted ${t} job submission${t===1?``:`s`}; server returned ${e} distinct job ID${e===1?``:`s`} (deduplication may reuse existing jobs)`}}function g(e){if(typeof e!=`object`||!e||e.ok!==!0||typeof e.id!=`string`||!e.id||e.id.length>1024)throw Error(`Add job returned a malformed success response`);return e.id}function _(e,t){let n=e?.ids;if(typeof e!=`object`||!e||e.ok!==!0||!Array.isArray(n)||n.length!==t||n.some(e=>typeof e!=`string`||e.length===0||e.length>1024))throw Error(`Bulk add returned a malformed success response`);return n}export{s as a,m as c,u as d,d as f,r as g,a as h,o as i,l,t as m,g as n,c as o,n as p,h as r,p as s,_ as t,f as u};
@@ -0,0 +1 @@
1
+ var e=Object.create,t=Object.defineProperty,n=Object.getOwnPropertyDescriptor,r=Object.getOwnPropertyNames,i=Object.getPrototypeOf,a=Object.prototype.hasOwnProperty,o=(e,t)=>()=>(t||(e((t={exports:{}}).exports,t,t.exports),e=null),t.exports),s=(e,n)=>{let r={};for(var i in e)t(r,i,{get:e[i],enumerable:!0});return n||t(r,Symbol.toStringTag,{value:`Module`}),r},c=(e,i,o,s)=>{if(i&&typeof i==`object`||typeof i==`function`)for(var c=r(i),l=0,u=c.length,d;l<u;l++)d=c[l],!a.call(e,d)&&d!==o&&t(e,d,{get:(e=>i[e]).bind(null,d),enumerable:!(s=n(i,d))||s.enumerable});return e},l=(n,r,o)=>(o=n==null?{}:e(i(n)),c(r||!n||!n.__esModule||!a.call(n,`default`)?t(o,`default`,{value:n,enumerable:!0}):o,n));export{s as n,l as r,o as t};
@@ -1 +1 @@
1
- import{r as e}from"./rolldown-runtime-QTnfLwEv.js";import{g as t}from"./react-vendor-CFL9l8LK.js";import{n,t as r}from"./controlConnectionEpoch-ChAeMMLk.js";var i=e(t(),1),a=new Map;function o(e){let t=n(),o=`${t}\u0000${e}`,s=(0,i.useRef)(!1),c=(0,i.useRef)(0),l=(0,i.useRef)(o);return l.current!==o&&(l.current=o,c.current+=1),(0,i.useEffect)(()=>(s.current=!0,()=>{s.current=!1,c.current+=1}),[]),{scopeKey:o,begin:(e=`action`)=>{let n=[...new Set(typeof e==`string`?[e]:e)],i=n.map(e=>`${t}\u0000${e}`);if(!s.current||n.length===0||l.current!==o||r()!==t||i.some(e=>a.has(e)))return null;let u=Symbol(`control-action`);for(let e of i)a.set(e,u);let d=c.current,f=()=>s.current&&c.current===d&&l.current===o&&r()===t;return{isCurrent:f,finish:()=>{let e=f();for(let e of i)a.get(e)===u&&a.delete(e);return e}}}}}export{o as t};
1
+ import{r as e}from"./rolldown-runtime-XKyaHtl9.js";import{h as t}from"./react-vendor-08inPAVO.js";import{n,t as r}from"./controlConnectionEpoch-x9VjrWgN.js";var i=e(t(),1),a=new Map;function o(e){let t=n(),o=`${t}\u0000${e}`,s=(0,i.useRef)(!1),c=(0,i.useRef)(0),l=(0,i.useRef)(o);return l.current!==o&&(l.current=o,c.current+=1),(0,i.useEffect)(()=>(s.current=!0,()=>{s.current=!1,c.current+=1}),[]),{scopeKey:o,begin:(e=`action`)=>{let n=[...new Set(typeof e==`string`?[e]:e)],i=n.map(e=>`${t}\u0000${e}`);if(!s.current||n.length===0||l.current!==o||r()!==t||i.some(e=>a.has(e)))return null;let u=Symbol(`control-action`);for(let e of i)a.set(e,u);let d=c.current,f=()=>s.current&&c.current===d&&l.current===o&&r()===t;return{isCurrent:f,finish:()=>{let e=f();for(let e of i)a.get(e)===u&&a.delete(e);return e}}}}}export{o as t};
@@ -1 +1 @@
1
- import{r as e}from"./rolldown-runtime-QTnfLwEv.js";import{g as t}from"./react-vendor-CFL9l8LK.js";import{a as n,o as r}from"./connectionStore-CVjQyIZv.js";var i=e(t(),1),a=new Map;function o(){let e=r.getState().token.trim();return JSON.stringify([n(),e])}var s=0,c=o();r.subscribe(()=>{let e=o();e!==c&&(c=e,s+=1)});function l(e,t=`Operation`){if(typeof e!=`object`||!e||e.ok!==!0)throw Error(`${t} returned a malformed success response`)}function u(e){r(e=>`${e.baseUrl}\u0000${e.token}`);let t=o(),n=s,c=JSON.stringify([n,e]),l=(0,i.useRef)(!1),u=(0,i.useRef)(0),d=(0,i.useRef)(c);return d.current!==c&&(d.current=c,u.current+=1),(0,i.useEffect)(()=>{l.current=!0;let e=o(),t=r.subscribe(()=>{let t=o();t!==e&&(e=t,u.current+=1)});return()=>{l.current=!1,u.current+=1,t()}},[]),{scopeKey:c,begin:(r=`action`)=>{let i=[...new Set(typeof r==`string`?[r]:r)],f=i.map(t=>JSON.stringify([n,e,t]));if(!l.current||i.length===0||d.current!==c||s!==n||o()!==t||f.some(e=>a.has(e)))return null;let p=Symbol(`server-action`);for(let e of f)a.set(e,p);let m=u.current,h=()=>l.current&&u.current===m&&d.current===c&&s===n&&o()===t;return{isCurrent:h,finish:()=>{let e=h();for(let e of f)a.get(e)===p&&a.delete(e);return e}}}}}export{o as n,u as r,l as t};
1
+ import{r as e}from"./rolldown-runtime-XKyaHtl9.js";import{h as t}from"./react-vendor-08inPAVO.js";import{a as n,o as r}from"./connectionStore-B946Fhuv.js";var i=e(t(),1),a=new Map;function o(){let e=r.getState().token.trim();return JSON.stringify([n(),e])}var s=0,c=o();r.subscribe(()=>{let e=o();e!==c&&(c=e,s+=1)});function l(e,t=`Operation`){if(typeof e!=`object`||!e||e.ok!==!0)throw Error(`${t} returned a malformed success response`)}function u(e){r(e=>`${e.baseUrl}\u0000${e.token}`);let t=o(),n=s,c=JSON.stringify([n,e]),l=(0,i.useRef)(!1),u=(0,i.useRef)(0),d=(0,i.useRef)(c);return d.current!==c&&(d.current=c,u.current+=1),(0,i.useEffect)(()=>{l.current=!0;let e=o(),t=r.subscribe(()=>{let t=o();t!==e&&(e=t,u.current+=1)});return()=>{l.current=!1,u.current+=1,t()}},[]),{scopeKey:c,begin:(r=`action`)=>{let i=[...new Set(typeof r==`string`?[r]:r)],f=i.map(t=>JSON.stringify([n,e,t]));if(!l.current||i.length===0||d.current!==c||s!==n||o()!==t||f.some(e=>a.has(e)))return null;let p=Symbol(`server-action`);for(let e of f)a.set(e,p);let m=u.current,h=()=>l.current&&u.current===m&&d.current===c&&s===n&&o()===t;return{isCurrent:h,finish:()=>{let e=h();for(let e of f)a.get(e)===p&&a.delete(e);return e}}}}}export{o as n,u as r,l as t};
@@ -0,0 +1 @@
1
+ import{r as e}from"./rolldown-runtime-XKyaHtl9.js";import{h as t}from"./react-vendor-08inPAVO.js";import{o as n}from"./connectionStore-B946Fhuv.js";import{D as r,I as i}from"./index-X_fHGbXZ.js";var a=e(t(),1),o=1e3,s={push:[],complete:[],fail:[],depth:[]},c=()=>typeof performance<`u`?performance.now():Date.now(),l=(e,t)=>`${e}\u0000${t}`;function u(e=60){let t=l(n(e=>e.baseUrl),n(e=>e.token)),[u,d]=(0,a.useState)(s),[f,p]=(0,a.useState)(null),[m,h]=(0,a.useState)(null),g=(0,a.useRef)(0),_=(0,a.useRef)(0),v=(0,a.useRef)(t),y=v.current===t;return(0,a.useEffect)(()=>{let n=++g.current,a=new AbortController,l=!1;v.current!==t&&(v.current=t,d(s),p(null),h(null),_.current=0);let u=r(()=>globalThis.document?.hidden??!1),f=async()=>{if(l||!u())return;l=!0;let t=c();try{let[r,c]=await Promise.all([i.overview({signal:a.signal}),i.stats({signal:a.signal})]);if(a.signal.aborted||g.current!==n)return;let l=r?.stats,u=r?.throughput,f=c?.stats;if(!l||!u||!f)throw Error(`malformed telemetry body`);if(![l.waiting,l.active,l.delayed,l.completed,l.dlq,l.totalPushed,l.totalPulled,l.totalCompleted,l.totalFailed,l.uptime,u.pushPerSec,u.completePerSec,u.failPerSec,f.waiting,f.prioritized,f.active,f.delayed,f[`waiting-children`]].every(e=>typeof e==`number`&&Number.isFinite(e)))throw Error(`malformed telemetry numeric metrics`);let m=u.pushPerSec,v=u.completePerSec,y=u.failPerSec,b=f.waiting+f.prioritized+f.active+f.delayed+f[`waiting-children`],x=_.current>0&&t-_.current>4*o;_.current=t,p(r),h(null),d(t=>{let n=x?s:t;return{push:[...n.push,m].slice(-e),complete:[...n.complete,v].slice(-e),fail:[...n.fail,y].slice(-e),depth:[...n.depth,b].slice(-e)}})}catch(e){!a.signal.aborted&&g.current===n&&h(e)}finally{l=!1}};f();let m=setInterval(f,o);return()=>{clearInterval(m),a.abort(),g.current===n&&(g.current+=1)}},[e,t]),y?{...u,latest:f,error:m}:{...s,latest:null,error:null}}function d(e,t=o){if(e.length<2)return{slope:0,label:`steady`,draining:!1};let n=e.length,r=(n-1)/2,i=e.reduce((e,t)=>e+t,0)/n,a=0,s=0;for(let t=0;t<n;t++)a+=(t-r)*(e[t]-i),s+=(t-r)**2;let c=s===0?0:a/s,l=t>0?o/t*c:c,u=l<-.05;return{slope:l,label:u?`draining`:l>.05?`accumulating`:`steady`,draining:u}}export{u as n,d as t};
package/dist/index.html CHANGED
@@ -49,23 +49,15 @@
49
49
  content="Fully drive a bunqueue server from one UI: queues, jobs, DLQ, cron, webhooks, workers, and start/stop/restart. Live demo, no signup."
50
50
  />
51
51
  <meta name="twitter:image" content="https://egeominotti.github.io/bunqueue-dashboard/og.png" />
52
- <script type="module" crossorigin src="./assets/index-DZFZr0Mi.js"></script>
53
- <link rel="modulepreload" crossorigin href="./assets/rolldown-runtime-QTnfLwEv.js">
54
- <link rel="modulepreload" crossorigin href="./assets/react-vendor-CFL9l8LK.js">
55
- <link rel="modulepreload" crossorigin href="./assets/connectionStore-CVjQyIZv.js">
52
+ <script type="module" crossorigin src="./assets/index-X_fHGbXZ.js"></script>
53
+ <link rel="modulepreload" crossorigin href="./assets/rolldown-runtime-XKyaHtl9.js">
54
+ <link rel="modulepreload" crossorigin href="./assets/react-vendor-08inPAVO.js">
55
+ <link rel="modulepreload" crossorigin href="./assets/connectionStore-B946Fhuv.js">
56
56
  <link rel="modulepreload" crossorigin href="./assets/upstreamPaths-DQeKSxGc.js">
57
- <link rel="modulepreload" crossorigin href="./assets/bq-DR2BTISO.js">
58
- <link rel="modulepreload" crossorigin href="./assets/toastStore-XmMX7A5W.js">
59
- <link rel="modulepreload" crossorigin href="./assets/icons-DH9SS1DA.js">
60
- <link rel="modulepreload" crossorigin href="./assets/StatusBadge-DereLzOj.js">
61
- <link rel="modulepreload" crossorigin href="./assets/api-D9aT0ND7.js">
62
- <link rel="modulepreload" crossorigin href="./assets/usePolledData-CEyyLRYa.js">
63
- <link rel="modulepreload" crossorigin href="./assets/Button-_aSJvRoW.js">
64
- <link rel="modulepreload" crossorigin href="./assets/Card-egIDLwVk.js">
65
- <link rel="modulepreload" crossorigin href="./assets/feedback-CtGN_kqB.js">
66
- <link rel="modulepreload" crossorigin href="./assets/PageHeader-CQzNsw8r.js">
67
- <link rel="modulepreload" crossorigin href="./assets/format-Cg7VCIZW.js">
68
- <link rel="stylesheet" crossorigin href="./assets/index-DaEyLvTR.css">
57
+ <link rel="modulepreload" crossorigin href="./assets/icons-BIT5aq1c.js">
58
+ <link rel="modulepreload" crossorigin href="./assets/StatusBadge-D-mexaga.js">
59
+ <link rel="modulepreload" crossorigin href="./assets/api-CCgfskjt.js">
60
+ <link rel="stylesheet" crossorigin href="./assets/index-DR8flo6r.css">
69
61
  </head>
70
62
  <body>
71
63
  <div id="root"></div>
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "bunqueue-dashboard",
3
- "version": "1.0.2",
3
+ "version": "1.0.4",
4
4
  "type": "module",
5
5
  "description": "Web dashboard for a bunqueue server (queues, jobs, DLQ, cron, metrics, workers, live activity). Run with `bunx bunqueue-dashboard` (requires Bun 1.4.4).",
6
6
  "packageManager": "bun@1.4.4",
@@ -15,8 +15,7 @@
15
15
  "scripts/bunVersion.ts",
16
16
  "scripts/embedded.gen.ts",
17
17
  "agent",
18
- "shared",
19
- "patches"
18
+ "shared"
20
19
  ],
21
20
  "publishConfig": {
22
21
  "access": "public"
@@ -57,9 +56,9 @@
57
56
  "dev": "vite",
58
57
  "agent": "bun run agent/index.ts",
59
58
  "build": "bun run typecheck && vite build",
60
- "typecheck": "tsc --noEmit && bun run typecheck:agent && bun run typecheck:examples && bun run typecheck:e2e",
61
- "typecheck:agent": "tsc -p tsconfig.agent.json",
62
- "typecheck:examples": "tsc -p tsconfig.examples.json",
59
+ "typecheck": "bun check --no-script && bun run typecheck:agent && bun run typecheck:examples && bun run typecheck:e2e",
60
+ "typecheck:agent": "bun check --no-script -p tsconfig.agent.json",
61
+ "typecheck:examples": "bun check --no-script -p tsconfig.examples.json",
63
62
  "size": "bun run scripts/check-bundle.ts",
64
63
  "version:check": "bun run scripts/check-bun-version.ts && bun run scripts/check-playwright-image.ts",
65
64
  "architecture": "bun run scripts/check-file-size.ts",
@@ -85,11 +84,11 @@
85
84
  "test:soak": "bun scripts/validate-resilience.ts",
86
85
  "test:package": "bun run scripts/validate-package-runtime.ts",
87
86
  "test:coverage": "bun test --coverage --coverage-reporter=text --coverage-reporter=lcov --coverage-dir=coverage && bun scripts/check-coverage.ts && bun scripts/check-critical-coverage.ts && bun scripts/check-test-inventory.ts",
88
- "lint": "oxlint . && bun run scripts/check-implicit-any-let.ts",
89
- "lint:fix": "oxlint --fix . && bun run scripts/check-implicit-any-let.ts",
90
- "format": "oxfmt .",
91
- "format:check": "oxfmt --check .",
92
- "check": "bun run lint && bun run format:check",
87
+ "lint": "bunx --bun --no-install oxlint .",
88
+ "lint:fix": "bunx --bun --no-install oxlint --fix .",
89
+ "format": "bun fmt",
90
+ "format:check": "bun fmt --check",
91
+ "check": "bun run typecheck && bun run lint && bun run format:check",
93
92
  "check:fix": "bun run lint:fix && bun run format",
94
93
  "audit:high": "bun audit --audit-level=high",
95
94
  "quality": "bun run quality:static && bun run quality:unit && bun run quality:runtime-a && bun run quality:runtime-b && bun run quality:runtime-c && bun run quality:runtime-d",
@@ -99,65 +98,56 @@
99
98
  "quality:runtime-b": "bun run test:e2e:queue-operations && bun run test:e2e:postgres-fleet",
100
99
  "quality:runtime-c": "bun run test:package && bun run test:runtime",
101
100
  "quality:runtime-d": "bun run test:soak",
102
- "typecheck:e2e": "tsc -p tsconfig.e2e.json",
101
+ "typecheck:e2e": "bun check --no-script -p tsconfig.e2e.json",
103
102
  "test:e2e:browser:managed": "bun run build && bun scripts/gen-embed.ts && playwright test -c playwright.managed.config.ts",
104
103
  "test:e2e:docs": "bun run docs:build && playwright test -c playwright.docs.config.ts"
105
104
  },
106
105
  "devDependencies": {
107
- "@ai-sdk/anthropic": "^4.0.7",
108
- "@ai-sdk/google": "^4.0.8",
109
- "@ai-sdk/openai": "^4.0.7",
110
- "@ai-sdk/openai-compatible": "^3.0.5",
111
- "@axe-core/playwright": "4.13.0",
112
- "@fontsource-variable/inter": "^5.2.8",
113
- "@fontsource-variable/jetbrains-mono": "^5.2.8",
114
- "@modelcontextprotocol/sdk": "1.32.1",
115
- "@playwright/test": "1.62.1",
116
- "@shikijs/vitepress-twoslash": "^4.3.0",
117
- "@tailwindcss/vite": "^4.3.2",
118
- "@types/node": "^26.0.1",
119
- "@types/react": "^19.2.17",
120
- "@types/react-dom": "^19.2.3",
121
- "@vitejs/plugin-react": "^6.0.3",
122
- "ai": "7.0.14",
106
+ "@ai-sdk/anthropic": "^4.0.89",
107
+ "@ai-sdk/google": "^4.0.106",
108
+ "@ai-sdk/openai": "^4.0.103",
109
+ "@ai-sdk/openai-compatible": "^3.0.79",
110
+ "@axe-core/playwright": "4.14.0",
111
+ "@fontsource-variable/inter": "^5.3.0",
112
+ "@fontsource-variable/jetbrains-mono": "^5.3.0",
113
+ "@modelcontextprotocol/sdk": "1.32.2",
114
+ "@playwright/test": "1.64.1",
115
+ "@tailwindcss/vite": "^4.3.3",
116
+ "@types/node": "^26.6.5",
117
+ "@types/react": "^19.3.0",
118
+ "@types/react-dom": "^19.3.0",
119
+ "@vitejs/plugin-react": "^6.1.2",
120
+ "ai": "7.0.154",
123
121
  "bun-types": "1.4.4",
124
122
  "bunqueue-v2-9-2": "npm:bunqueue@2.9.2",
125
- "happy-dom": "^20.10.6",
126
- "mermaid": "^11.17.2",
127
- "oxfmt": "^0.63.0",
128
- "oxlint": "^1.78.0",
129
- "oxlint-tsgolint": "^7.0.2001",
130
- "react": "^19.2.7",
131
- "react-dom": "^19.2.7",
123
+ "happy-dom": "^21.0.4",
124
+ "mermaid": "^12.2.0",
125
+ "oxlint": "^1.89.0",
126
+ "oxlint-tsgolint": "^7.0.2005",
127
+ "react": "^19.3.1",
128
+ "react-dom": "^19.3.1",
132
129
  "react-router-dom": "^7.18.4",
133
- "tailwindcss": "^4.3.2",
134
- "typescript": "^6.0.3",
135
- "vite": "^8.1.6",
136
- "vitepress": "2.0.0-alpha.18",
137
- "vitepress-plugin-llms": "^1.13.2",
138
- "vitepress-plugin-mermaid": "^2.0.17",
139
- "zod": "^4.4.3",
140
- "zustand": "^5.0.14"
130
+ "tailwindcss": "^4.3.3",
131
+ "vite": "^8.3.5",
132
+ "vitepress": "2.0.0-alpha.21",
133
+ "vitepress-plugin-llms": "^1.14.0",
134
+ "zod": "^4.6.7",
135
+ "zustand": "^5.0.16"
141
136
  },
142
137
  "overrides": {
143
138
  "brace-expansion": "^5.0.12",
144
- "dompurify": "^3.4.16",
145
- "fast-uri": "^3.1.8",
146
- "ip-address": "^10.7.2",
147
- "js-yaml": "^3.15.2",
139
+ "dompurify": "^3.4.17",
140
+ "fast-uri": "^3.1.9",
141
+ "ip-address": "^10.7.5",
148
142
  "markdown-it": "^14.3.3",
149
- "nanoid": "^3.3.18",
150
- "postcss": "^8.5.25",
143
+ "nanoid": "^3.3.20",
144
+ "postcss": "^8.5.32",
151
145
  "proxy-addr": "^2.0.8",
152
146
  "source-map-js": "^1.2.2",
153
- "tinypool": "^2.1.2",
154
- "vue": "^3.5.42"
147
+ "vue": "^3.5.44"
155
148
  },
156
149
  "dependencies": {
157
- "bunqueue": "2.9.4",
158
- "msgpackr": "^1.11.8"
159
- },
160
- "patchedDependencies": {
161
- "ai@7.0.14": "patches/ai@7.0.14.patch"
150
+ "bunqueue": "2.9.20",
151
+ "msgpackr": "^2.1.2"
162
152
  }
163
153
  }
@@ -1,159 +1,145 @@
1
1
  // @ts-nocheck
2
2
  // AUTO-GENERATED by scripts/gen-embed.ts — do not edit, not committed.
3
- import f0 from "../dist/index.html" with { type: 'file' };
4
- import f1 from "../dist/.vite/manifest.json" with { type: 'file' };
5
- import f2 from "../dist/assets/rolldown-runtime-QTnfLwEv.js" with { type: 'file' };
6
- import f3 from "../dist/assets/useThroughputSeries-CeFx-Mwq.js" with { type: 'file' };
7
- import f4 from "../dist/assets/promisePool-BVfQ9n9Q.js" with { type: 'file' };
8
- import f5 from "../dist/assets/Alerts-DCKl_C8D.js" with { type: 'file' };
9
- import f6 from "../dist/assets/Flows-DKZxI7ta.js" with { type: 'file' };
10
- import f7 from "../dist/assets/jetbrains-mono-latin-wght-normal-B9CIFXIH.woff2" with { type: 'file' };
11
- import f8 from "../dist/assets/Card-egIDLwVk.js" with { type: 'file' };
12
- import f9 from "../dist/assets/react-vendor-CFL9l8LK.js" with { type: 'file' };
13
- import f10 from "../dist/assets/JobsPro-DxDw-akG.js" with { type: 'file' };
14
- import f11 from "../dist/assets/useControlActionGuard-1i7aFA7E.js" with { type: 'file' };
15
- import f12 from "../dist/assets/flowOperationPolicy-B2Etcb3f.js" with { type: 'file' };
16
- import f13 from "../dist/assets/ServerControl-Ch1wZcKB.js" with { type: 'file' };
17
- import f14 from "../dist/assets/S3BackupPro-UwWu0yxr.js" with { type: 'file' };
18
- import f15 from "../dist/assets/QueueDetail-Dgo9Ukmp.js" with { type: 'file' };
19
- import f16 from "../dist/assets/jetbrains-mono-latin-ext-wght-normal-DBQx-q_a.woff2" with { type: 'file' };
20
- import f17 from "../dist/assets/Queues-CS8LeZtJ.js" with { type: 'file' };
21
- import f18 from "../dist/assets/Logs-Bj60G_FP.js" with { type: 'file' };
22
- import f19 from "../dist/assets/Overview-B_AOa5kW.js" with { type: 'file' };
23
- import f20 from "../dist/assets/CronManager-Cqtg9Zr8.js" with { type: 'file' };
24
- import f21 from "../dist/assets/QueuesOverview-BySSnCm0.js" with { type: 'file' };
25
- import f22 from "../dist/assets/exportFile-C7xhE8Yh.js" with { type: 'file' };
26
- import f23 from "../dist/assets/bq-DR2BTISO.js" with { type: 'file' };
27
- import f24 from "../dist/assets/BulkAddJobs-GRMVnf0j.js" with { type: 'file' };
28
- import f25 from "../dist/assets/Fleet-Bkbq0dFB.js" with { type: 'file' };
29
- import f26 from "../dist/assets/api-D9aT0ND7.js" with { type: 'file' };
30
- import f27 from "../dist/assets/responses-BkR2JTH9.js" with { type: 'file' };
31
- import f28 from "../dist/assets/Diagnostics-E_icHggb.js" with { type: 'file' };
32
- import f29 from "../dist/assets/Benchmark-DyHvEM8x.js" with { type: 'file' };
33
- import f30 from "../dist/assets/DlqPro-BEdxFiNN.js" with { type: 'file' };
34
- import f31 from "../dist/assets/usePolledData-CEyyLRYa.js" with { type: 'file' };
35
- import f32 from "../dist/assets/connectionStore-CVjQyIZv.js" with { type: 'file' };
36
- import f33 from "../dist/assets/inter-latin-wght-normal-Dx4kXJAl.woff2" with { type: 'file' };
37
- import f34 from "../dist/assets/Workflows-CqZZ96EK.js" with { type: 'file' };
38
- import f35 from "../dist/assets/QueueActions-BBxRt-t0.js" with { type: 'file' };
39
- import f36 from "../dist/assets/S3Backup-Ci4dJPP_.js" with { type: 'file' };
40
- import f37 from "../dist/assets/inter-latin-ext-wght-normal-DO1Apj_S.woff2" with { type: 'file' };
41
- import f38 from "../dist/assets/QueueControl-DaZjeZnw.js" with { type: 'file' };
42
- import f39 from "../dist/assets/Metrics-BBLdWOw1.js" with { type: 'file' };
43
- import f40 from "../dist/assets/LogsPro-Hv8xwXDK.js" with { type: 'file' };
44
- import f41 from "../dist/assets/MetricsPro-D470b1aP.js" with { type: 'file' };
45
- import f42 from "../dist/assets/Jobs-CKzKpQ7i.js" with { type: 'file' };
46
- import f43 from "../dist/assets/toastStore-XmMX7A5W.js" with { type: 'file' };
47
- import f44 from "../dist/assets/Workers-D1Ead02h.js" with { type: 'file' };
48
- import f45 from "../dist/assets/format-Cg7VCIZW.js" with { type: 'file' };
49
- import f46 from "../dist/assets/form-DG3X6cLL.js" with { type: 'file' };
50
- import f47 from "../dist/assets/McpServer-zxSMjG8K.js" with { type: 'file' };
51
- import f48 from "../dist/assets/Dlq-DNs32CzV.js" with { type: 'file' };
52
- import f49 from "../dist/assets/useServerActionGuard-CUx8TOAC.js" with { type: 'file' };
53
- import f50 from "../dist/assets/StatusBadge-DereLzOj.js" with { type: 'file' };
54
- import f51 from "../dist/assets/upstreamPaths-DQeKSxGc.js" with { type: 'file' };
55
- import f52 from "../dist/assets/index-DZFZr0Mi.js" with { type: 'file' };
56
- import f53 from "../dist/assets/AddJob-CiwWycYG.js" with { type: 'file' };
57
- import f54 from "../dist/assets/Pagination-CSkzhNW6.js" with { type: 'file' };
58
- import f55 from "../dist/assets/PageHeader-CQzNsw8r.js" with { type: 'file' };
59
- import f56 from "../dist/assets/AreaChart-Db2UVnaK.js" with { type: 'file' };
60
- import f57 from "../dist/assets/install-oydLpc1T.js" with { type: 'file' };
61
- import f58 from "../dist/assets/feedback-CtGN_kqB.js" with { type: 'file' };
62
- import f59 from "../dist/assets/Button-_aSJvRoW.js" with { type: 'file' };
63
- import f60 from "../dist/assets/flowMutationSafety-YKTHxqKv.js" with { type: 'file' };
64
- import f61 from "../dist/assets/Webhooks-BonYUgMo.js" with { type: 'file' };
65
- import f62 from "../dist/assets/classicJobsData-Csj4iihY.js" with { type: 'file' };
66
- import f63 from "../dist/assets/Database-BBzyi7f0.js" with { type: 'file' };
67
- import f64 from "../dist/assets/Cron-XL0PdUEc.js" with { type: 'file' };
68
- import f65 from "../dist/assets/JobInspector-BARE52q3.js" with { type: 'file' };
69
- import f66 from "../dist/assets/controlConnectionEpoch-ChAeMMLk.js" with { type: 'file' };
70
- import f67 from "../dist/assets/Usage-DR90dCt0.js" with { type: 'file' };
71
- import f68 from "../dist/assets/icons-DH9SS1DA.js" with { type: 'file' };
72
- import f69 from "../dist/assets/UsagePro-DAlE3oCE.js" with { type: 'file' };
73
- import f70 from "../dist/assets/Settings-FOzwrB25.js" with { type: 'file' };
74
- import f71 from "../dist/assets/QueueDetailPro-D7U8ahp2.js" with { type: 'file' };
75
- import f72 from "../dist/assets/WorkersPro-XuLxtU4A.js" with { type: 'file' };
76
- import f73 from "../dist/assets/DlqControl-DawwIsTI.js" with { type: 'file' };
77
- import f74 from "../dist/assets/index-DaEyLvTR.css" with { type: 'file' };
78
- import f75 from "../dist/og.png" with { type: 'file' };
79
- import f76 from "../dist/favicon.svg" with { type: 'file' };
3
+ import f0 from "../dist/favicon.svg" with { type: 'file' };
4
+ import f1 from "../dist/og.png" with { type: 'file' };
5
+ import f2 from "../dist/.vite/manifest.json" with { type: 'file' };
6
+ import f3 from "../dist/assets/connectionStore-B946Fhuv.js" with { type: 'file' };
7
+ import f4 from "../dist/assets/QueueActions-BQf1-g5m.js" with { type: 'file' };
8
+ import f5 from "../dist/assets/classicJobsData-wdIr-E4y.js" with { type: 'file' };
9
+ import f6 from "../dist/assets/Workers-Bu8aJlZf.js" with { type: 'file' };
10
+ import f7 from "../dist/assets/UsagePro-DtlB1dJc.js" with { type: 'file' };
11
+ import f8 from "../dist/assets/package-Bb3FkjoS.js" with { type: 'file' };
12
+ import f9 from "../dist/assets/JobsPro-k20Pas24.js" with { type: 'file' };
13
+ import f10 from "../dist/assets/inter-latin-ext-wght-normal-DO1Apj_S.woff2" with { type: 'file' };
14
+ import f11 from "../dist/assets/Workflows-ClF4YzhW.js" with { type: 'file' };
15
+ import f12 from "../dist/assets/rolldown-runtime-XKyaHtl9.js" with { type: 'file' };
16
+ import f13 from "../dist/assets/responses-YgpvqWEr.js" with { type: 'file' };
17
+ import f14 from "../dist/assets/form-DBkslwzu.js" with { type: 'file' };
18
+ import f15 from "../dist/assets/promisePool-BVfQ9n9Q.js" with { type: 'file' };
19
+ import f16 from "../dist/assets/inter-latin-wght-normal-Dx4kXJAl.woff2" with { type: 'file' };
20
+ import f17 from "../dist/assets/index-DR8flo6r.css" with { type: 'file' };
21
+ import f18 from "../dist/assets/Logs-DA4JFvpM.js" with { type: 'file' };
22
+ import f19 from "../dist/assets/Overview-Cmg_2NAt.js" with { type: 'file' };
23
+ import f20 from "../dist/assets/QueueDetailPro-CpSMSo8A.js" with { type: 'file' };
24
+ import f21 from "../dist/assets/react-vendor-08inPAVO.js" with { type: 'file' };
25
+ import f22 from "../dist/assets/Benchmark-B4NfYkAi.js" with { type: 'file' };
26
+ import f23 from "../dist/assets/Dlq-D8s-NhV2.js" with { type: 'file' };
27
+ import f24 from "../dist/assets/S3BackupPro-Cr2ZJZkw.js" with { type: 'file' };
28
+ import f25 from "../dist/assets/Queues-C5lElTjp.js" with { type: 'file' };
29
+ import f26 from "../dist/assets/StatusBadge-D-mexaga.js" with { type: 'file' };
30
+ import f27 from "../dist/assets/exportFile-C7xhE8Yh.js" with { type: 'file' };
31
+ import f28 from "../dist/assets/WorkersPro-C6gNYGfo.js" with { type: 'file' };
32
+ import f29 from "../dist/assets/jetbrains-mono-latin-ext-wght-normal-DBQx-q_a.woff2" with { type: 'file' };
33
+ import f30 from "../dist/assets/Fleet-BAziMWfo.js" with { type: 'file' };
34
+ import f31 from "../dist/assets/icons-BIT5aq1c.js" with { type: 'file' };
35
+ import f32 from "../dist/assets/upstreamPaths-DQeKSxGc.js" with { type: 'file' };
36
+ import f33 from "../dist/assets/index-X_fHGbXZ.js" with { type: 'file' };
37
+ import f34 from "../dist/assets/S3Backup-DUHmp2Xw.js" with { type: 'file' };
38
+ import f35 from "../dist/assets/BulkAddJobs-BAN5wT8A.js" with { type: 'file' };
39
+ import f36 from "../dist/assets/AddJob-Dgjlhzn2.js" with { type: 'file' };
40
+ import f37 from "../dist/assets/jetbrains-mono-latin-wght-normal-B9CIFXIH.woff2" with { type: 'file' };
41
+ import f38 from "../dist/assets/Database-CeUKS6Nf.js" with { type: 'file' };
42
+ import f39 from "../dist/assets/Webhooks-B_GwTCBW.js" with { type: 'file' };
43
+ import f40 from "../dist/assets/LogsPro-hna5L6sP.js" with { type: 'file' };
44
+ import f41 from "../dist/assets/Alerts-Lyzbq0qw.js" with { type: 'file' };
45
+ import f42 from "../dist/assets/ServerControl-m58ooJT2.js" with { type: 'file' };
46
+ import f43 from "../dist/assets/Metrics-CJ9dW0me.js" with { type: 'file' };
47
+ import f44 from "../dist/assets/AreaChart-CSP0-00u.js" with { type: 'file' };
48
+ import f45 from "../dist/assets/flowOperationPolicy-B2Etcb3f.js" with { type: 'file' };
49
+ import f46 from "../dist/assets/Pagination-WVfHLHDS.js" with { type: 'file' };
50
+ import f47 from "../dist/assets/controlConnectionEpoch-x9VjrWgN.js" with { type: 'file' };
51
+ import f48 from "../dist/assets/Flows-BFUMTSWv.js" with { type: 'file' };
52
+ import f49 from "../dist/assets/flowMutationSafety-YKTHxqKv.js" with { type: 'file' };
53
+ import f50 from "../dist/assets/Diagnostics-DuzTPfyb.js" with { type: 'file' };
54
+ import f51 from "../dist/assets/McpServer-Cqem-L3z.js" with { type: 'file' };
55
+ import f52 from "../dist/assets/useThroughputSeries-BN5QmKPt.js" with { type: 'file' };
56
+ import f53 from "../dist/assets/JobInspector-BXuXxDwR.js" with { type: 'file' };
57
+ import f54 from "../dist/assets/Cron-Bz46oVXB.js" with { type: 'file' };
58
+ import f55 from "../dist/assets/CronManager-Cl5RW2cB.js" with { type: 'file' };
59
+ import f56 from "../dist/assets/QueueControl-BiMM0jLp.js" with { type: 'file' };
60
+ import f57 from "../dist/assets/QueuesOverview-DRohFtuC.js" with { type: 'file' };
61
+ import f58 from "../dist/assets/useServerActionGuard-uiZWD3dS.js" with { type: 'file' };
62
+ import f59 from "../dist/assets/install-hFu5e6YM.js" with { type: 'file' };
63
+ import f60 from "../dist/assets/DlqPro-xj-MM6u8.js" with { type: 'file' };
64
+ import f61 from "../dist/assets/DlqControl-DDxRMM8i.js" with { type: 'file' };
65
+ import f62 from "../dist/assets/QueueDetail-DfRY4jS4.js" with { type: 'file' };
66
+ import f63 from "../dist/assets/Usage-CY2uEJEu.js" with { type: 'file' };
67
+ import f64 from "../dist/assets/api-CCgfskjt.js" with { type: 'file' };
68
+ import f65 from "../dist/assets/useControlActionGuard-Bx5MkufG.js" with { type: 'file' };
69
+ import f66 from "../dist/assets/Jobs-pQBmffni.js" with { type: 'file' };
70
+ import f67 from "../dist/assets/MetricsPro-BslYrx1A.js" with { type: 'file' };
71
+ import f68 from "../dist/assets/Settings-DXsjoOqD.js" with { type: 'file' };
72
+ import f69 from "../dist/index.html" with { type: 'file' };
80
73
 
81
74
  export const ASSETS: Record<string, string> = {
82
- "/index.html": f0,
83
- "/.vite/manifest.json": f1,
84
- "/assets/rolldown-runtime-QTnfLwEv.js": f2,
85
- "/assets/useThroughputSeries-CeFx-Mwq.js": f3,
86
- "/assets/promisePool-BVfQ9n9Q.js": f4,
87
- "/assets/Alerts-DCKl_C8D.js": f5,
88
- "/assets/Flows-DKZxI7ta.js": f6,
89
- "/assets/jetbrains-mono-latin-wght-normal-B9CIFXIH.woff2": f7,
90
- "/assets/Card-egIDLwVk.js": f8,
91
- "/assets/react-vendor-CFL9l8LK.js": f9,
92
- "/assets/JobsPro-DxDw-akG.js": f10,
93
- "/assets/useControlActionGuard-1i7aFA7E.js": f11,
94
- "/assets/flowOperationPolicy-B2Etcb3f.js": f12,
95
- "/assets/ServerControl-Ch1wZcKB.js": f13,
96
- "/assets/S3BackupPro-UwWu0yxr.js": f14,
97
- "/assets/QueueDetail-Dgo9Ukmp.js": f15,
98
- "/assets/jetbrains-mono-latin-ext-wght-normal-DBQx-q_a.woff2": f16,
99
- "/assets/Queues-CS8LeZtJ.js": f17,
100
- "/assets/Logs-Bj60G_FP.js": f18,
101
- "/assets/Overview-B_AOa5kW.js": f19,
102
- "/assets/CronManager-Cqtg9Zr8.js": f20,
103
- "/assets/QueuesOverview-BySSnCm0.js": f21,
104
- "/assets/exportFile-C7xhE8Yh.js": f22,
105
- "/assets/bq-DR2BTISO.js": f23,
106
- "/assets/BulkAddJobs-GRMVnf0j.js": f24,
107
- "/assets/Fleet-Bkbq0dFB.js": f25,
108
- "/assets/api-D9aT0ND7.js": f26,
109
- "/assets/responses-BkR2JTH9.js": f27,
110
- "/assets/Diagnostics-E_icHggb.js": f28,
111
- "/assets/Benchmark-DyHvEM8x.js": f29,
112
- "/assets/DlqPro-BEdxFiNN.js": f30,
113
- "/assets/usePolledData-CEyyLRYa.js": f31,
114
- "/assets/connectionStore-CVjQyIZv.js": f32,
115
- "/assets/inter-latin-wght-normal-Dx4kXJAl.woff2": f33,
116
- "/assets/Workflows-CqZZ96EK.js": f34,
117
- "/assets/QueueActions-BBxRt-t0.js": f35,
118
- "/assets/S3Backup-Ci4dJPP_.js": f36,
119
- "/assets/inter-latin-ext-wght-normal-DO1Apj_S.woff2": f37,
120
- "/assets/QueueControl-DaZjeZnw.js": f38,
121
- "/assets/Metrics-BBLdWOw1.js": f39,
122
- "/assets/LogsPro-Hv8xwXDK.js": f40,
123
- "/assets/MetricsPro-D470b1aP.js": f41,
124
- "/assets/Jobs-CKzKpQ7i.js": f42,
125
- "/assets/toastStore-XmMX7A5W.js": f43,
126
- "/assets/Workers-D1Ead02h.js": f44,
127
- "/assets/format-Cg7VCIZW.js": f45,
128
- "/assets/form-DG3X6cLL.js": f46,
129
- "/assets/McpServer-zxSMjG8K.js": f47,
130
- "/assets/Dlq-DNs32CzV.js": f48,
131
- "/assets/useServerActionGuard-CUx8TOAC.js": f49,
132
- "/assets/StatusBadge-DereLzOj.js": f50,
133
- "/assets/upstreamPaths-DQeKSxGc.js": f51,
134
- "/assets/index-DZFZr0Mi.js": f52,
135
- "/assets/AddJob-CiwWycYG.js": f53,
136
- "/assets/Pagination-CSkzhNW6.js": f54,
137
- "/assets/PageHeader-CQzNsw8r.js": f55,
138
- "/assets/AreaChart-Db2UVnaK.js": f56,
139
- "/assets/install-oydLpc1T.js": f57,
140
- "/assets/feedback-CtGN_kqB.js": f58,
141
- "/assets/Button-_aSJvRoW.js": f59,
142
- "/assets/flowMutationSafety-YKTHxqKv.js": f60,
143
- "/assets/Webhooks-BonYUgMo.js": f61,
144
- "/assets/classicJobsData-Csj4iihY.js": f62,
145
- "/assets/Database-BBzyi7f0.js": f63,
146
- "/assets/Cron-XL0PdUEc.js": f64,
147
- "/assets/JobInspector-BARE52q3.js": f65,
148
- "/assets/controlConnectionEpoch-ChAeMMLk.js": f66,
149
- "/assets/Usage-DR90dCt0.js": f67,
150
- "/assets/icons-DH9SS1DA.js": f68,
151
- "/assets/UsagePro-DAlE3oCE.js": f69,
152
- "/assets/Settings-FOzwrB25.js": f70,
153
- "/assets/QueueDetailPro-D7U8ahp2.js": f71,
154
- "/assets/WorkersPro-XuLxtU4A.js": f72,
155
- "/assets/DlqControl-DawwIsTI.js": f73,
156
- "/assets/index-DaEyLvTR.css": f74,
157
- "/og.png": f75,
158
- "/favicon.svg": f76,
75
+ "/favicon.svg": f0,
76
+ "/og.png": f1,
77
+ "/.vite/manifest.json": f2,
78
+ "/assets/connectionStore-B946Fhuv.js": f3,
79
+ "/assets/QueueActions-BQf1-g5m.js": f4,
80
+ "/assets/classicJobsData-wdIr-E4y.js": f5,
81
+ "/assets/Workers-Bu8aJlZf.js": f6,
82
+ "/assets/UsagePro-DtlB1dJc.js": f7,
83
+ "/assets/package-Bb3FkjoS.js": f8,
84
+ "/assets/JobsPro-k20Pas24.js": f9,
85
+ "/assets/inter-latin-ext-wght-normal-DO1Apj_S.woff2": f10,
86
+ "/assets/Workflows-ClF4YzhW.js": f11,
87
+ "/assets/rolldown-runtime-XKyaHtl9.js": f12,
88
+ "/assets/responses-YgpvqWEr.js": f13,
89
+ "/assets/form-DBkslwzu.js": f14,
90
+ "/assets/promisePool-BVfQ9n9Q.js": f15,
91
+ "/assets/inter-latin-wght-normal-Dx4kXJAl.woff2": f16,
92
+ "/assets/index-DR8flo6r.css": f17,
93
+ "/assets/Logs-DA4JFvpM.js": f18,
94
+ "/assets/Overview-Cmg_2NAt.js": f19,
95
+ "/assets/QueueDetailPro-CpSMSo8A.js": f20,
96
+ "/assets/react-vendor-08inPAVO.js": f21,
97
+ "/assets/Benchmark-B4NfYkAi.js": f22,
98
+ "/assets/Dlq-D8s-NhV2.js": f23,
99
+ "/assets/S3BackupPro-Cr2ZJZkw.js": f24,
100
+ "/assets/Queues-C5lElTjp.js": f25,
101
+ "/assets/StatusBadge-D-mexaga.js": f26,
102
+ "/assets/exportFile-C7xhE8Yh.js": f27,
103
+ "/assets/WorkersPro-C6gNYGfo.js": f28,
104
+ "/assets/jetbrains-mono-latin-ext-wght-normal-DBQx-q_a.woff2": f29,
105
+ "/assets/Fleet-BAziMWfo.js": f30,
106
+ "/assets/icons-BIT5aq1c.js": f31,
107
+ "/assets/upstreamPaths-DQeKSxGc.js": f32,
108
+ "/assets/index-X_fHGbXZ.js": f33,
109
+ "/assets/S3Backup-DUHmp2Xw.js": f34,
110
+ "/assets/BulkAddJobs-BAN5wT8A.js": f35,
111
+ "/assets/AddJob-Dgjlhzn2.js": f36,
112
+ "/assets/jetbrains-mono-latin-wght-normal-B9CIFXIH.woff2": f37,
113
+ "/assets/Database-CeUKS6Nf.js": f38,
114
+ "/assets/Webhooks-B_GwTCBW.js": f39,
115
+ "/assets/LogsPro-hna5L6sP.js": f40,
116
+ "/assets/Alerts-Lyzbq0qw.js": f41,
117
+ "/assets/ServerControl-m58ooJT2.js": f42,
118
+ "/assets/Metrics-CJ9dW0me.js": f43,
119
+ "/assets/AreaChart-CSP0-00u.js": f44,
120
+ "/assets/flowOperationPolicy-B2Etcb3f.js": f45,
121
+ "/assets/Pagination-WVfHLHDS.js": f46,
122
+ "/assets/controlConnectionEpoch-x9VjrWgN.js": f47,
123
+ "/assets/Flows-BFUMTSWv.js": f48,
124
+ "/assets/flowMutationSafety-YKTHxqKv.js": f49,
125
+ "/assets/Diagnostics-DuzTPfyb.js": f50,
126
+ "/assets/McpServer-Cqem-L3z.js": f51,
127
+ "/assets/useThroughputSeries-BN5QmKPt.js": f52,
128
+ "/assets/JobInspector-BXuXxDwR.js": f53,
129
+ "/assets/Cron-Bz46oVXB.js": f54,
130
+ "/assets/CronManager-Cl5RW2cB.js": f55,
131
+ "/assets/QueueControl-BiMM0jLp.js": f56,
132
+ "/assets/QueuesOverview-DRohFtuC.js": f57,
133
+ "/assets/useServerActionGuard-uiZWD3dS.js": f58,
134
+ "/assets/install-hFu5e6YM.js": f59,
135
+ "/assets/DlqPro-xj-MM6u8.js": f60,
136
+ "/assets/DlqControl-DDxRMM8i.js": f61,
137
+ "/assets/QueueDetail-DfRY4jS4.js": f62,
138
+ "/assets/Usage-CY2uEJEu.js": f63,
139
+ "/assets/api-CCgfskjt.js": f64,
140
+ "/assets/useControlActionGuard-Bx5MkufG.js": f65,
141
+ "/assets/Jobs-pQBmffni.js": f66,
142
+ "/assets/MetricsPro-BslYrx1A.js": f67,
143
+ "/assets/Settings-DXsjoOqD.js": f68,
144
+ "/index.html": f69,
159
145
  };
@@ -1,3 +0,0 @@
1
- import{n as e,r as t}from"./rolldown-runtime-QTnfLwEv.js";import{g as n,l as r,r as i,t as a}from"./react-vendor-CFL9l8LK.js";import{i as o}from"./upstreamPaths-DQeKSxGc.js";import{r as s,t as c}from"./bq-DR2BTISO.js";import{t as l}from"./toastStore-XmMX7A5W.js";import{n as u}from"./usePolledData-CEyyLRYa.js";import{t as d}from"./Button-_aSJvRoW.js";import{n as f,t as p}from"./Card-egIDLwVk.js";import{t as m}from"./PageHeader-CQzNsw8r.js";import{a as h,n as g,o as _,t as v}from"./form-DG3X6cLL.js";import{r as y}from"./useServerActionGuard-CUx8TOAC.js";import{a as b,c as x,d as S,f as C,h as w,i as T,l as E,m as D,n as O,o as k,r as A,s as j,t as M,u as N}from"./responses-BkR2JTH9.js";var P=t(n(),1),F=a();function I({values:e,setValue:t,queueNames:n,queueDiscoveryError:r,onRetryQueues:i,jsonError:a,setJsonError:o}){return(0,F.jsxs)(p,{children:[(0,F.jsx)(f,{title:`Job`}),(0,F.jsxs)(`div`,{className:`flex flex-col gap-4`,children:[(0,F.jsxs)(v,{label:`Queue`,children:[(0,F.jsx)(g,{list:`queue-options`,"aria-label":`Queue`,name:`target-queue`,autoComplete:`off`,value:e.queue,onChange:e=>t(`queue`,e.target.value),placeholder:`queue name (existing or new)`}),(0,F.jsx)(`datalist`,{id:`queue-options`,children:n.map(e=>(0,F.jsx)(`option`,{value:e},e))})]}),(0,F.jsx)(v,{label:`Job name`,hint:`Worker routing name in Bunqueue 2.9.3; separate from the JSON payload.`,children:(0,F.jsx)(g,{name:`job-name`,autoComplete:`off`,maxLength:256,value:e.name,onChange:e=>t(`name`,e.target.value),placeholder:`default`})}),r&&(0,F.jsxs)(`p`,{role:`status`,className:`-mt-2 text-xs text-warning`,children:[`Existing queue suggestions unavailable — `,r.message,`. You can still enter a queue name manually.`,` `,(0,F.jsx)(`button`,{type:`button`,onClick:i,className:`font-medium underline underline-offset-2 hover:text-fg`,children:`Retry`})]}),(0,F.jsxs)(`div`,{children:[(0,F.jsx)(v,{label:`Data (JSON)`,children:(0,F.jsx)(`textarea`,{name:`job-data`,value:e.dataText,onChange:e=>t(`dataText`,e.target.value),onBlur:()=>{let t=w(e.dataText);o(t.ok?null:t.msg)},maxLength:D,spellCheck:!1,rows:7,className:`w-full rounded-lg border border-line bg-surface-2 p-3 font-mono text-sm text-fg focus:border-accent/60 focus:outline-none focus:ring-2 focus:ring-accent/30`})}),a&&(0,F.jsx)(`p`,{role:`alert`,className:`mt-2 text-xs text-danger`,children:a})]})]})]})}function L({values:e,setValue:t}){return(0,F.jsxs)(p,{children:[(0,F.jsx)(f,{title:`Options`}),(0,F.jsxs)(`div`,{className:`grid grid-cols-2 gap-4 md:grid-cols-3`,children:[(0,F.jsx)(B,{label:e.groupId.trim()?`Group priority`:`Priority`,hint:e.groupId.trim()?`0 is highest within this group`:void 0,name:`priority`,value:e.priority,min:e.groupId.trim()?0:-1e6,max:e.groupId.trim()?k:1e6,placeholder:`0`,onChange:e=>t(`priority`,e)}),(0,F.jsx)(B,{label:`Delay (ms)`,name:`delay`,value:e.delay,min:0,max:T,placeholder:`0`,disabled:e.runAt.trim()!==``,onChange:e=>t(`delay`,e)}),(0,F.jsx)(v,{label:`Run at`,hint:e.runAt.trim()?`Overrides Delay — derived from this time (local time).`:`(local time)`,children:(0,F.jsx)(g,{type:`datetime-local`,name:`run-at`,value:e.runAt,onChange:e=>t(`runAt`,e.target.value)})}),(0,F.jsx)(B,{label:`Max attempts`,hint:`blank = server default`,name:`max-attempts`,value:e.maxAttempts,min:1,max:1e3,placeholder:`3`,onChange:e=>t(`maxAttempts`,e)}),(0,F.jsx)(B,{label:`Backoff (ms)`,hint:`blank = server default`,name:`backoff`,value:e.backoff,min:0,max:b,placeholder:`1000`,onChange:e=>t(`backoff`,e)}),(0,F.jsx)(v,{label:`Backoff strategy`,hint:`flat delay unless set`,children:(0,F.jsxs)(h,{name:`backoff-strategy`,value:e.backoffType,onChange:e=>t(`backoffType`,e.target.value),children:[(0,F.jsx)(`option`,{value:``,children:`flat`}),(0,F.jsx)(`option`,{value:`fixed`,children:`fixed`}),(0,F.jsx)(`option`,{value:`exponential`,children:`exponential`})]})}),(0,F.jsx)(B,{label:`Timeout (ms)`,name:`timeout`,value:e.timeout,min:0,max:b,placeholder:`—`,onChange:e=>t(`timeout`,e)}),(0,F.jsx)(B,{label:`TTL (ms)`,hint:`blank = no expiry`,name:`ttl`,value:e.ttl,min:0,max:T,placeholder:`—`,onChange:e=>t(`ttl`,e)}),(0,F.jsx)(v,{label:`Custom job ID`,children:(0,F.jsx)(g,{name:`custom-job-id`,value:e.jobId,onChange:e=>t(`jobId`,e.target.value),placeholder:`idempotency key`})})]}),(0,F.jsxs)(`div`,{className:`mt-4 flex flex-wrap gap-6`,children:[(0,F.jsx)(V,{label:`removeOnComplete`,checked:e.removeOnComplete,onChange:e=>t(`removeOnComplete`,e)}),(0,F.jsx)(V,{label:`removeOnFail`,checked:e.removeOnFail,onChange:e=>t(`removeOnFail`,e)}),(0,F.jsx)(V,{label:`durable`,checked:e.durable,onChange:e=>t(`durable`,e)}),(0,F.jsx)(V,{label:`lifo`,checked:e.lifo,onChange:e=>t(`lifo`,e)})]}),(0,F.jsx)(R,{values:e,setValue:t})]})}function R({values:e,setValue:t}){return(0,F.jsxs)(`div`,{className:`mt-4 border-t border-line pt-4`,children:[(0,F.jsx)(`div`,{className:`mb-3 text-[11px] uppercase tracking-wider text-faint`,children:`Advanced`}),(0,F.jsxs)(`div`,{className:`grid grid-cols-2 gap-4 md:grid-cols-3`,children:[(0,F.jsx)(z,{label:`Tags`,hint:`comma-separated`,name:`tags`,value:e.tags,placeholder:`email, urgent`,onChange:e=>t(`tags`,e)}),(0,F.jsx)(z,{label:`Group ID`,name:`group-id`,value:e.groupId,placeholder:`—`,onChange:e=>t(`groupId`,e)}),(0,F.jsx)(B,{label:`Group max size`,hint:`Atomic pending-job cap (2.9.3)`,name:`group-max-size`,value:e.groupMaxSize,min:1,max:2**53-1,placeholder:`—`,onChange:e=>t(`groupMaxSize`,e)}),(0,F.jsx)(z,{label:`Unique key`,hint:`dedup key`,name:`unique-key`,value:e.uniqueKey,placeholder:`—`,onChange:e=>t(`uniqueKey`,e)}),(0,F.jsx)(z,{label:`Depends on`,hint:`parent job ids, comma-separated`,name:`depends-on`,value:e.dependsOn,placeholder:`job-id-1, job-id-2`,onChange:e=>t(`dependsOn`,e)}),(0,F.jsx)(`div`,{className:`col-span-2 md:col-span-3`,children:(0,F.jsx)(v,{label:`Repeat policy (JSON)`,hint:`v2.9.3-safe form: e.g. {"every":60000,"limit":10}. Use Cron Manager for cron patterns.`,children:(0,F.jsx)(`textarea`,{name:`repeat-policy`,value:e.repeatText,onChange:e=>t(`repeatText`,e.target.value),rows:2,spellCheck:!1,placeholder:`{"every": 60000}`,className:`w-full rounded-lg border border-line bg-surface-2 px-3 py-2 font-mono text-xs text-fg placeholder:text-faint focus:border-accent/60 focus:outline-none focus:ring-2 focus:ring-accent/30`})})})]})]})}function z({label:e,hint:t,name:n,value:r,placeholder:i,onChange:a}){return(0,F.jsx)(v,{label:e,hint:t,children:(0,F.jsx)(g,{name:n,value:r,onChange:e=>a(e.target.value),placeholder:i})})}function B({label:e,hint:t,name:n,value:r,min:i,max:a,placeholder:o,disabled:s,onChange:c}){return(0,F.jsx)(v,{label:e,hint:t,children:(0,F.jsx)(g,{type:`number`,min:i,max:a,step:1,name:n,value:r,onChange:e=>c(e.target.value),placeholder:o,disabled:s})})}function V({label:e,checked:t,onChange:n}){return(0,F.jsxs)(`div`,{className:`flex items-center gap-2`,children:[(0,F.jsx)(_,{checked:t,onChange:n,label:e}),(0,F.jsx)(`span`,{className:`font-mono text-xs text-muted`,children:e})]})}function H(e){let t=e?.options??{},n=j(t);return{queue:e?.queue??``,name:e?.name??`default`,dataText:e?.dataText??`{
2
- "hello": "world"
3
- }`,count:`1`,priority:x(t.priority),delay:``,runAt:``,maxAttempts:x(t.maxAttempts),backoff:n.backoff,timeout:x(t.timeout),ttl:n.ttl,jobId:``,removeOnComplete:t.removeOnComplete??!1,removeOnFail:t.removeOnFail??!1,durable:!1,lifo:!1,backoffType:n.backoffType,tags:n.tags,groupId:n.groupId,groupMaxSize:``,dependsOn:``,uniqueKey:``,repeatText:``}}function U(e,t=Date.now()){let n=e.queue.trim(),r=S(n);if(r)return W(r);let i=e.name.trim();if(!i||i.length>256)return W(`Job name must be a non-empty string of at most 256 characters`);let a=w(e.dataText);if(!a.ok)return{ok:!1,msg:a.msg,field:a.kind===`json`?`data`:`result`};let s=e.groupId.trim();if(s.length>256||s.includes(`\0`))return W(`Group ID must contain 1–256 characters and no NUL`);let c=E({priority:e.priority,delay:e.runAt.trim()?``:e.delay,maxAttempts:e.maxAttempts,backoff:e.backoff,timeout:e.timeout,ttl:e.ttl,groupMaxSize:e.groupMaxSize},!!s);if(!c.ok)return W(c.msg);if(c.options.groupMaxSize!==void 0&&!s)return W(`Group max size requires a Group ID`);let l=c.options.delay;if(e.runAt.trim()){let n=new Date(e.runAt).getTime();if(!Number.isFinite(n))return W(`Run at is not a valid date/time`);if(l=Math.max(0,n-t),l>31536e6)return W(`Run at must be within the next 365 days`)}let u=C(c.options.backoff,e.backoffType);if(!u.ok)return W(u.msg);let d=G(e.tags),f=G(e.dependsOn),p=e.jobId.trim();if(p){let e=o(p);if(e)return W(`Job ID: ${e}`)}for(let e of f){let t=o(e);if(t)return W(`Dependency ID "${e}": ${t}`)}let m=N(e.repeatText);if(!m.ok)return W(m.msg);let h=Number(e.count);return!Number.isSafeInteger(h)||h<1||h>1e4?W(`Count must be a whole number from 1 to 10000`):{ok:!0,target:n,count:h,body:{name:i,data:a.data,priority:c.options.priority,delay:l,maxAttempts:c.options.maxAttempts,backoff:u.backoff,timeout:c.options.timeout,ttl:c.options.ttl,jobId:p||void 0,removeOnComplete:e.removeOnComplete||void 0,removeOnFail:e.removeOnFail||void 0,durable:e.durable||void 0,lifo:e.lifo||void 0,tags:d.length?d:void 0,groupId:s||void 0,groupMaxSize:c.options.groupMaxSize,dependsOn:f.length?f:void 0,uniqueKey:e.uniqueKey.trim()||void 0,repeat:m.repeat}}}var W=e=>({ok:!1,msg:e,field:`result`}),G=e=>e.split(`,`).map(e=>e.trim()).filter(Boolean),K=e({AddJob:()=>q,MAX_JOB_DATA_BYTES:()=>MAX_JOB_DATA_BYTES,MAX_JOB_DATA_CHARS:()=>D});function q(){let{data:e,error:t,refetch:n}=u(()=>c.queues(),[],{intervalMs:3e4}),a=r().state?.clone,[o,f]=(0,P.useState)(()=>H(a)),[p,h]=(0,P.useState)(!1),[_,b]=(0,P.useState)(null),[x,S]=(0,P.useState)(null),C=y(`add-job`),w=(e,t)=>f(n=>({...n,[e]:t}));(0,P.useEffect)(()=>{h(!1),b(null),S(null)},[C.scopeKey]);let T=async()=>{b(null),S(null);let e=U(o);if(!e.ok){e.field===`data`?S(e.msg):b({ok:!1,msg:e.msg});return}let t=C.begin();if(!t)return;h(!0);let{target:n,body:r,count:i}=e;try{if(i===1&&r.groupMaxSize===void 0){let e=O(await c.addJob(n,r));if(!t.isCurrent())return;b({ok:!0,msg:`Accepted job ID ${e} (it may be an existing deduplicated job)`}),l.success(`Job submission accepted`,`${n} · ${e}`)}else{let e=Array.from({length:i},()=>r),a=s(e);if(a){t.isCurrent()&&b({ok:!1,msg:a});return}let o=M(await c.addJobsBulk(n,e),i);if(!t.isCurrent())return;let u=A(new Set(o).size,i);b(u),l.success(u.msg,`in ${n}`)}}catch(e){if(!t.isCurrent())return;b({ok:!1,msg:e.message}),l.error(`Add job failed`,e.message)}finally{t.finish()&&h(!1)}};return(0,F.jsxs)(`div`,{children:[(0,F.jsx)(m,{title:`Add Job`,description:`Enqueue a job with full options.`,actions:(0,F.jsx)(i,{to:`/jobs/bulk-add`,className:`rounded-lg border border-line px-3 py-1.5 text-sm text-muted hover:bg-surface-2 hover:text-fg`,children:`Bulk import`})}),a&&(0,F.jsx)(`div`,{className:`mb-4 flex items-center gap-2 rounded-lg border border-accent/30 bg-accent/[0.06] px-4 py-2 text-sm text-accent`,children:`Pre-filled from an existing job. Review the data and options, then enqueue a fresh job.`}),(0,F.jsxs)(`form`,{className:`grid grid-cols-1 gap-6 lg:grid-cols-2`,onSubmit:e=>{e.preventDefault(),T()},children:[(0,F.jsx)(I,{values:o,setValue:w,queueNames:(e?.queues??[]).map(e=>e.name),queueDiscoveryError:t,onRetryQueues:()=>void n(),jsonError:x,setJsonError:S}),(0,F.jsx)(L,{values:o,setValue:w}),(0,F.jsxs)(`div`,{className:`flex flex-wrap items-end gap-3 lg:col-span-2`,children:[(0,F.jsx)(`div`,{className:`w-28`,children:(0,F.jsx)(v,{label:`Count`,hint:`1–10000`,children:(0,F.jsx)(g,{type:`number`,min:1,max:1e4,step:1,name:`count`,value:o.count,onChange:e=>w(`count`,e.target.value)})})}),(0,F.jsx)(d,{type:`submit`,variant:`accent`,disabled:p,children:p?`Adding…`:`Add job`}),_&&(0,F.jsx)(`span`,{role:_.ok?`status`:`alert`,className:_.ok?`text-sm text-success`:`text-sm text-danger`,children:_.msg})]})]})]})}export{K as t};