| 123456789101112131415161718192021222324 |
- const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/PrintersPage-zDUFDj5q.js","assets/chunk-aKtaBQYM.js","assets/CartesianChart-DcboTNtX.js","assets/createLucideIcon-Yo2YoYjm.js","assets/client-BdOyoZJz.js","assets/react-dom-xhkz5--P.js","assets/with-selector-C2KEMbwS.js","assets/QueryClientProvider-Clbyr4Jg.js","assets/useMutation-qh3Iyscy.js","assets/useQuery-CCy0EwsM.js","assets/ErrorBarContext-6wvnfk_q.js","assets/FileUploadModal-hFWmsB_i.js","assets/info-DcT0QU8O.js","assets/ToastContext-VFOrCCoA.js","assets/loader-circle-CB4leTZa.js","assets/x-Dctff5l9.js","assets/file-DDkFXH-b.js","assets/ContextMenu-CqE3-J0R.js","assets/search-BpAJdxRw.js","assets/zoom-out-C85W_TC5.js","assets/OrbitControls-Bbqf07B-.js","assets/Button-pwVKPiYn.js","assets/haSensorDisplay-CSo8Nw_c.js","assets/gauge-xO5PdXj0.js","assets/lock-C288ZvMI.js","assets/wind-CsHQYbhI.js","assets/triangle-alert-gIik0G2C.js","assets/arrow-down-C4OBNDqJ.js","assets/arrow-left-MSgMxOFV.js","assets/arrow-right-Da96kh4S.js","assets/arrow-up-down-C-1Kkt1x.js","assets/arrow-up-Dam8cLfE.js","assets/ReferenceLine-l3CI8D5f.js","assets/box-BIRPxdgi.js","assets/fan-DSlOeWAh.js","assets/calendar-DiVEdzUw.js","assets/check-D1Pn8T1J.js","assets/copy-3N5VKzXz.js","assets/ellipsis-vertical-So0E77JK.js","assets/eye-off-B6dY82pM.js","assets/file-box-BjB1o93N.js","assets/GcodeToolpathViewer-D4M17KI8.js","assets/scan-search-LN9I03Ga.js","assets/funnel-BtI48m95.js","assets/grip-vertical-D4urhrwn.js","assets/hard-drive-CN9rq6Uq.js","assets/layout-grid-D4S7CgZJ.js","assets/log-in-D7NdqHOf.js","assets/maximize-2-Cggm3z8J.js","assets/minimize-2-BLq3FJZO.js","assets/CameraDiagnoseModal-DWbtempu.js","assets/minus-D0aY9wbr.js","assets/CopyButton-CyNT06yS.js","assets/move-CEngqF8v.js","assets/package-D9xR0eOt.js","assets/pause-CPKrVlsD.js","assets/play-DROvjtg7.js","assets/settings-2-DYB5IzKV.js","assets/unlink-DJBJ04VB.js","assets/CameraWall-Br9MDE6G.js","assets/useQueries-C87lFrjE.js","assets/date-G9KUauqz.js","assets/ConfigureAmsSlotModal-C4N9v6PJ.js","assets/utils-D0ctH_jZ.js","assets/useCancellableTimeout-CXuQGelB.js","assets/inventorySearch-yJim1_Yj.js","assets/slicerPrinterMatch-g7Dr6p0c.js","assets/Card-OUAj0Ayh.js","assets/Toggle-CwMiiK0g.js","assets/filamentSwatchHelpers-D3oXQSGk.js","assets/printerModel-DrNvERGQ.js","assets/queueItemName-UFY7kpjG.js","assets/ArchivesPage-MaOGuDlA.js","assets/RichTextEditor-CtyYZFiu.js","assets/list-CBXEiN6g.js","assets/purify.es-F_7NWVtX.js","assets/chevrons-right-OnQ-9jKz.js","assets/cog-pa-nvQzt.js","assets/coins-6tqy9spE.js","assets/columns-2-CGEUxYp_.js","assets/file-spreadsheet-8-W2zdLi.js","assets/git-compare-DbgnTP6k.js","assets/SliceModal-DilRo4MU.js","assets/cloud-off-DmnG-KIw.js","assets/history-BBZbf3sJ.js","assets/pen-line-DYnjxVtS.js","assets/qr-code-PQYGpSrt.js","assets/skip-forward-BE5zCMec.js","assets/sticky-note-C75KNLfY.js","assets/ColumnConfigModal-B9cmtxVm.js","assets/PhotoGalleryModal-BxTCJXU3.js","assets/slicer-DgCA7cW6.js","assets/QueuePage-DTh2aCRG.js","assets/sortable.esm-uF6WmP46.js","assets/timer-BYBW_ysJ.js","assets/workflow-DxBrfirU.js","assets/StatsPage-D0cqrND3.js","assets/dollar-sign-ChtX2KHo.js","assets/target-PpftuQXz.js","assets/AreaChart-J0I0YlYN.js","assets/SettingsPage-DOroBYzD.js","assets/briefcase-BmuFBTLZ.js","assets/cpu-DAX4KhDZ.js","assets/link-2-Bj1oMj3O.js","assets/locationSensorDefaults-rSWWVL7r.js","assets/scale-lRomj4j_.js","assets/shield-CfkeOiiL.js","assets/smartphone-DOKM2tP4.js","assets/OverlayFrame-BUFy7NI1.js","assets/FinancePage-BfhaugR1.js","assets/ProfilesPage-C0jHVdln.js","assets/droplet-PpnaB65N.js","assets/sparkles-AUof3WTI.js","assets/MaintenancePage-BAMWk5DI.js","assets/ProjectsPage-C2aXY-5x.js","assets/ProjectDetailPage-CaZEFrXK.js","assets/libraryFiles-B0B1SFfn.js","assets/FileManagerPage-Kp8jeXP4.js","assets/usePreviewFullscreen-DOsgAeT7.js","assets/LibraryTrashPage-Ck7R9blU.js","assets/CameraPage-C1mWeQfG.js","assets/CamWallPage-C1rIEzhG.js","assets/StreamOverlayPage-DWOhiuT-.js","assets/StreamOverlayPage-CA9KpVK8.css","assets/ExternalLinkPage-CM4__1rh.js","assets/GroupEditPage-i9TLWDyl.js","assets/PrinterLocationsPage-D2AqeJ9i.js","assets/InventoryPage-BWTPGneX.js","assets/AdditionalSection-Bcoa_hnW.js","assets/AssignToAmsModal-kr-0EzwV.js","assets/AmsUnitCard-DLM3L08d.js","assets/spoolPaint-CrvpHqdD.js","assets/ModelSourcesPage-C9OvAi9p.js","assets/SystemInfoPage-ClAReSss.js","assets/LoginPage-CXIN3BLj.js","assets/ConnectAuthorizePage-DtVlpfFV.js","assets/SetupPage-hUHebIlA.js","assets/NotificationsPage-5GOJDRkw.js","assets/GCodeViewerPage-C24Va31U.js","assets/SpoolBuddyDashboard-B_0MmvgI.js","assets/SpoolIcon-OZKzbEc8.js","assets/SpoolBuddyAmsPage-CCeWMoIm.js","assets/SpoolBuddySettingsPage-DKia6Rid.js","assets/SpoolBuddyCalibrationPage-BPEaykbd.js","assets/SpoolBuddyWriteTagPage-CMlhWgSL.js","assets/SpoolBuddyInventoryPage-BmxJPbmk.js"])))=>i.map(i=>d[i]);
- import{i as e,t}from"./chunk-aKtaBQYM.js";import{C as n,D as r,E as i,_ as a,a as o,d as s,g as c,h as l,i as u,l as d,m as f,o as p,p as m,t as h,u as g,v as _,w as v,x as y,y as b}from"./client-BdOyoZJz.js";import{t as x}from"./react-dom-xhkz5--P.js";import{A as S,C,D as w,N as T,S as E,_ as D,b as O,c as k,d as A,f as j,g as M,h as N,m as P,n as F,p as I,s as ee,t as te,u as ne,x as L}from"./QueryClientProvider-Clbyr4Jg.js";import{f as R,t as z}from"./useQuery-CCy0EwsM.js";import{n as re,t as ie}from"./useMutation-qh3Iyscy.js";import{t as B}from"./useQueries-C87lFrjE.js";import{t as V}from"./createLucideIcon-Yo2YoYjm.js";import{t as ae}from"./arrow-down-C4OBNDqJ.js";import{t as oe}from"./arrow-up-Dam8cLfE.js";import{t as se}from"./calendar-DiVEdzUw.js";import{t as ce}from"./check-D1Pn8T1J.js";import{a as le,i as H,n as ue,r as de,t as U}from"./info-DcT0QU8O.js";import{n as fe,r as pe,t as me}from"./ToastContext-VFOrCCoA.js";import{t as he}from"./loader-circle-CB4leTZa.js";import{t as ge}from"./triangle-alert-gIik0G2C.js";import{t as _e}from"./x-Dctff5l9.js";import{i as ve,n as ye,t as be}from"./Card-OUAj0Ayh.js";import{t as xe}from"./Button-pwVKPiYn.js";import{_ as Se,d as Ce,f as we,g as Te,i as Ee,m as De,o as Oe,p as ke,r as Ae,v as je,y as Me}from"./date-G9KUauqz.js";import{n as Ne,r as Pe}from"./filamentSwatchHelpers-D3oXQSGk.js";(function(){let e=document.createElement(`link`).relList;if(e&&e.supports&&e.supports(`modulepreload`))return;for(let e of document.querySelectorAll(`link[rel="modulepreload"]`))n(e);new MutationObserver(e=>{for(let t of e)if(t.type===`childList`)for(let e of t.addedNodes)e.tagName===`LINK`&&e.rel===`modulepreload`&&n(e)}).observe(document,{childList:!0,subtree:!0});function t(e){let t={};return e.integrity&&(t.integrity=e.integrity),e.referrerPolicy&&(t.referrerPolicy=e.referrerPolicy),e.crossOrigin===`use-credentials`?t.credentials=`include`:e.crossOrigin===`anonymous`?t.credentials=`omit`:t.credentials=`same-origin`,t}function n(e){if(e.ep)return;e.ep=!0;let n=t(e);fetch(e.href,n)}})();var Fe=t((e=>{function t(e,t){var n=e.length;e.push(t);a:for(;0<n;){var r=n-1>>>1,a=e[r];if(0<i(a,t))e[r]=t,e[n]=a,n=r;else break a}}function n(e){return e.length===0?null:e[0]}function r(e){if(e.length===0)return null;var t=e[0],n=e.pop();if(n!==t){e[0]=n;a:for(var r=0,a=e.length,o=a>>>1;r<o;){var s=2*(r+1)-1,c=e[s],l=s+1,u=e[l];if(0>i(c,n))l<a&&0>i(u,c)?(e[r]=u,e[l]=n,r=l):(e[r]=c,e[s]=n,r=s);else if(l<a&&0>i(u,n))e[r]=u,e[l]=n,r=l;else break a}}return t}function i(e,t){var n=e.sortIndex-t.sortIndex;return n===0?e.id-t.id:n}if(e.unstable_now=void 0,typeof performance==`object`&&typeof performance.now==`function`){var a=performance;e.unstable_now=function(){return a.now()}}else{var o=Date,s=o.now();e.unstable_now=function(){return o.now()-s}}var c=[],l=[],u=1,d=null,f=3,p=!1,m=!1,h=!1,g=!1,_=typeof setTimeout==`function`?setTimeout:null,v=typeof clearTimeout==`function`?clearTimeout:null,y=typeof setImmediate<`u`?setImmediate:null;function b(e){for(var i=n(l);i!==null;){if(i.callback===null)r(l);else if(i.startTime<=e)r(l),i.sortIndex=i.expirationTime,t(c,i);else break;i=n(l)}}function x(e){if(h=!1,b(e),!m)if(n(c)!==null)m=!0,S||(S=!0,O());else{var t=n(l);t!==null&&j(x,t.startTime-e)}}var S=!1,C=-1,w=5,T=-1;function E(){return g?!0:!(e.unstable_now()-T<w)}function D(){if(g=!1,S){var t=e.unstable_now();T=t;var i=!0;try{a:{m=!1,h&&(h=!1,v(C),C=-1),p=!0;var a=f;try{b:{for(b(t),d=n(c);d!==null&&!(d.expirationTime>t&&E());){var o=d.callback;if(typeof o==`function`){d.callback=null,f=d.priorityLevel;var s=o(d.expirationTime<=t);if(t=e.unstable_now(),typeof s==`function`){d.callback=s,b(t),i=!0;break b}d===n(c)&&r(c),b(t)}else r(c);d=n(c)}if(d!==null)i=!0;else{var u=n(l);u!==null&&j(x,u.startTime-t),i=!1}}break a}finally{d=null,f=a,p=!1}i=void 0}}finally{i?O():S=!1}}}var O;if(typeof y==`function`)O=function(){y(D)};else if(typeof MessageChannel<`u`){var k=new MessageChannel,A=k.port2;k.port1.onmessage=D,O=function(){A.postMessage(null)}}else O=function(){_(D,0)};function j(t,n){C=_(function(){t(e.unstable_now())},n)}e.unstable_IdlePriority=5,e.unstable_ImmediatePriority=1,e.unstable_LowPriority=4,e.unstable_NormalPriority=3,e.unstable_Profiling=null,e.unstable_UserBlockingPriority=2,e.unstable_cancelCallback=function(e){e.callback=null},e.unstable_forceFrameRate=function(e){0>e||125<e?console.error(`forceFrameRate takes a positive int between 0 and 125, forcing frame rates higher than 125 fps is not supported`):w=0<e?Math.floor(1e3/e):5},e.unstable_getCurrentPriorityLevel=function(){return f},e.unstable_next=function(e){switch(f){case 1:case 2:case 3:var t=3;break;default:t=f}var n=f;f=t;try{return e()}finally{f=n}},e.unstable_requestPaint=function(){g=!0},e.unstable_runWithPriority=function(e,t){switch(e){case 1:case 2:case 3:case 4:case 5:break;default:e=3}var n=f;f=e;try{return t()}finally{f=n}},e.unstable_scheduleCallback=function(r,i,a){var o=e.unstable_now();switch(typeof a==`object`&&a?(a=a.delay,a=typeof a==`number`&&0<a?o+a:o):a=o,r){case 1:var s=-1;break;case 2:s=250;break;case 5:s=1073741823;break;case 4:s=1e4;break;default:s=5e3}return s=a+s,r={id:u++,callback:i,priorityLevel:r,startTime:a,expirationTime:s,sortIndex:-1},a>o?(r.sortIndex=a,t(l,r),n(c)===null&&r===n(l)&&(h?(v(C),C=-1):h=!0,j(x,a-o))):(r.sortIndex=s,t(c,r),m||p||(m=!0,S||(S=!0,O()))),r},e.unstable_shouldYield=E,e.unstable_wrapCallback=function(e){var t=f;return function(){var n=f;f=t;try{return e.apply(this,arguments)}finally{f=n}}}})),Ie=t(((e,t)=>{t.exports=Fe()})),Le=t((e=>{var t=Ie(),n=r(),i=x();function a(e){var t=`https://react.dev/errors/`+e;if(1<arguments.length){t+=`?args[]=`+encodeURIComponent(arguments[1]);for(var n=2;n<arguments.length;n++)t+=`&args[]=`+encodeURIComponent(arguments[n])}return`Minified React error #`+e+`; visit `+t+` for the full message or use the non-minified dev environment for full errors and additional helpful warnings.`}function o(e){return!(!e||e.nodeType!==1&&e.nodeType!==9&&e.nodeType!==11)}function s(e){var t=e,n=e;if(e.alternate)for(;t.return;)t=t.return;else{e=t;do t=e,t.flags&4098&&(n=t.return),e=t.return;while(e)}return t.tag===3?n:null}function c(e){if(e.tag===13){var t=e.memoizedState;if(t===null&&(e=e.alternate,e!==null&&(t=e.memoizedState)),t!==null)return t.dehydrated}return null}function l(e){if(e.tag===31){var t=e.memoizedState;if(t===null&&(e=e.alternate,e!==null&&(t=e.memoizedState)),t!==null)return t.dehydrated}return null}function u(e){if(s(e)!==e)throw Error(a(188))}function d(e){var t=e.alternate;if(!t){if(t=s(e),t===null)throw Error(a(188));return t===e?e:null}for(var n=e,r=t;;){var i=n.return;if(i===null)break;var o=i.alternate;if(o===null){if(r=i.return,r!==null){n=r;continue}break}if(i.child===o.child){for(o=i.child;o;){if(o===n)return u(i),e;if(o===r)return u(i),t;o=o.sibling}throw Error(a(188))}if(n.return!==r.return)n=i,r=o;else{for(var c=!1,l=i.child;l;){if(l===n){c=!0,n=i,r=o;break}if(l===r){c=!0,r=i,n=o;break}l=l.sibling}if(!c){for(l=o.child;l;){if(l===n){c=!0,n=o,r=i;break}if(l===r){c=!0,r=o,n=i;break}l=l.sibling}if(!c)throw Error(a(189))}}if(n.alternate!==r)throw Error(a(190))}if(n.tag!==3)throw Error(a(188));return n.stateNode.current===n?e:t}function f(e){var t=e.tag;if(t===5||t===26||t===27||t===6)return e;for(e=e.child;e!==null;){if(t=f(e),t!==null)return t;e=e.sibling}return null}var p=Object.assign,m=Symbol.for(`react.element`),h=Symbol.for(`react.transitional.element`),g=Symbol.for(`react.portal`),_=Symbol.for(`react.fragment`),v=Symbol.for(`react.strict_mode`),y=Symbol.for(`react.profiler`),b=Symbol.for(`react.consumer`),S=Symbol.for(`react.context`),C=Symbol.for(`react.forward_ref`),w=Symbol.for(`react.suspense`),T=Symbol.for(`react.suspense_list`),E=Symbol.for(`react.memo`),D=Symbol.for(`react.lazy`),O=Symbol.for(`react.activity`),k=Symbol.for(`react.memo_cache_sentinel`),A=Symbol.iterator;function j(e){return typeof e!=`object`||!e?null:(e=A&&e[A]||e[`@@iterator`],typeof e==`function`?e:null)}var M=Symbol.for(`react.client.reference`);function N(e){if(e==null)return null;if(typeof e==`function`)return e.$$typeof===M?null:e.displayName||e.name||null;if(typeof e==`string`)return e;switch(e){case _:return`Fragment`;case y:return`Profiler`;case v:return`StrictMode`;case w:return`Suspense`;case T:return`SuspenseList`;case O:return`Activity`}if(typeof e==`object`)switch(e.$$typeof){case g:return`Portal`;case S:return e.displayName||`Context`;case b:return(e._context.displayName||`Context`)+`.Consumer`;case C:var t=e.render;return e=e.displayName,e||=(e=t.displayName||t.name||``,e===``?`ForwardRef`:`ForwardRef(`+e+`)`),e;case E:return t=e.displayName||null,t===null?N(e.type)||`Memo`:t;case D:t=e._payload,e=e._init;try{return N(e(t))}catch{}}return null}var P=Array.isArray,F=n.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,I=i.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,ee={pending:!1,data:null,method:null,action:null},te=[],ne=-1;function L(e){return{current:e}}function R(e){0>ne||(e.current=te[ne],te[ne]=null,ne--)}function z(e,t){ne++,te[ne]=e.current,e.current=t}var re=L(null),ie=L(null),B=L(null),V=L(null);function ae(e,t){switch(z(B,t),z(ie,e),z(re,null),t.nodeType){case 9:case 11:e=(e=t.documentElement)&&(e=e.namespaceURI)?Vd(e):0;break;default:if(e=t.tagName,t=t.namespaceURI)t=Vd(t),e=Hd(t,e);else switch(e){case`svg`:e=1;break;case`math`:e=2;break;default:e=0}}R(re),z(re,e)}function oe(){R(re),R(ie),R(B)}function se(e){e.memoizedState!==null&&z(V,e);var t=re.current,n=Hd(t,e.type);t!==n&&(z(ie,e),z(re,n))}function ce(e){ie.current===e&&(R(re),R(ie)),V.current===e&&(R(V),Qf._currentValue=ee)}var le,H;function ue(e){if(le===void 0)try{throw Error()}catch(e){var t=e.stack.trim().match(/\n( *(at )?)/);le=t&&t[1]||``,H=-1<e.stack.indexOf(`
- at`)?` (<anonymous>)`:-1<e.stack.indexOf(`@`)?`@unknown:0:0`:``}return`
- `+le+e+H}var de=!1;function U(e,t){if(!e||de)return``;de=!0;var n=Error.prepareStackTrace;Error.prepareStackTrace=void 0;try{var r={DetermineComponentFrameRoot:function(){try{if(t){var n=function(){throw Error()};if(Object.defineProperty(n.prototype,"props",{set:function(){throw Error()}}),typeof Reflect==`object`&&Reflect.construct){try{Reflect.construct(n,[])}catch(e){var r=e}Reflect.construct(e,[],n)}else{try{n.call()}catch(e){r=e}e.call(n.prototype)}}else{try{throw Error()}catch(e){r=e}(n=e())&&typeof n.catch==`function`&&n.catch(function(){})}}catch(e){if(e&&r&&typeof e.stack==`string`)return[e.stack,r.stack]}return[null,null]}};r.DetermineComponentFrameRoot.displayName=`DetermineComponentFrameRoot`;var i=Object.getOwnPropertyDescriptor(r.DetermineComponentFrameRoot,`name`);i&&i.configurable&&Object.defineProperty(r.DetermineComponentFrameRoot,"name",{value:`DetermineComponentFrameRoot`});var a=r.DetermineComponentFrameRoot(),o=a[0],s=a[1];if(o&&s){var c=o.split(`
- `),l=s.split(`
- `);for(i=r=0;r<c.length&&!c[r].includes(`DetermineComponentFrameRoot`);)r++;for(;i<l.length&&!l[i].includes(`DetermineComponentFrameRoot`);)i++;if(r===c.length||i===l.length)for(r=c.length-1,i=l.length-1;1<=r&&0<=i&&c[r]!==l[i];)i--;for(;1<=r&&0<=i;r--,i--)if(c[r]!==l[i]){if(r!==1||i!==1)do if(r--,i--,0>i||c[r]!==l[i]){var u=`
- `+c[r].replace(` at new `,` at `);return e.displayName&&u.includes(`<anonymous>`)&&(u=u.replace(`<anonymous>`,e.displayName)),u}while(1<=r&&0<=i);break}}}finally{de=!1,Error.prepareStackTrace=n}return(n=e?e.displayName||e.name:``)?ue(n):``}function fe(e,t){switch(e.tag){case 26:case 27:case 5:return ue(e.type);case 16:return ue(`Lazy`);case 13:return e.child!==t&&t!==null?ue(`Suspense Fallback`):ue(`Suspense`);case 19:return ue(`SuspenseList`);case 0:case 15:return U(e.type,!1);case 11:return U(e.type.render,!1);case 1:return U(e.type,!0);case 31:return ue(`Activity`);default:return``}}function pe(e){try{var t=``,n=null;do t+=fe(e,n),n=e,e=e.return;while(e);return t}catch(e){return`
- Error generating stack: `+e.message+`
- `+e.stack}}var me=Object.prototype.hasOwnProperty,he=t.unstable_scheduleCallback,ge=t.unstable_cancelCallback,_e=t.unstable_shouldYield,ve=t.unstable_requestPaint,ye=t.unstable_now,be=t.unstable_getCurrentPriorityLevel,xe=t.unstable_ImmediatePriority,Se=t.unstable_UserBlockingPriority,Ce=t.unstable_NormalPriority,we=t.unstable_LowPriority,Te=t.unstable_IdlePriority,Ee=t.log,De=t.unstable_setDisableYieldValue,Oe=null,ke=null;function Ae(e){if(typeof Ee==`function`&&De(e),ke&&typeof ke.setStrictMode==`function`)try{ke.setStrictMode(Oe,e)}catch{}}var je=Math.clz32?Math.clz32:Pe,Me=Math.log,Ne=Math.LN2;function Pe(e){return e>>>=0,e===0?32:31-(Me(e)/Ne|0)|0}var Fe=256,Le=262144,Re=4194304;function W(e){var t=e&42;if(t!==0)return t;switch(e&-e){case 1:return 1;case 2:return 2;case 4:return 4;case 8:return 8;case 16:return 16;case 32:return 32;case 64:return 64;case 128:return 128;case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:return e&261888;case 262144:case 524288:case 1048576:case 2097152:return e&3932160;case 4194304:case 8388608:case 16777216:case 33554432:return e&62914560;case 67108864:return 67108864;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 0;default:return e}}function ze(e,t,n){var r=e.pendingLanes;if(r===0)return 0;var i=0,a=e.suspendedLanes,o=e.pingedLanes;e=e.warmLanes;var s=r&134217727;return s===0?(s=r&~a,s===0?o===0?n||(n=r&~e,n!==0&&(i=W(n))):i=W(o):i=W(s)):(r=s&~a,r===0?(o&=s,o===0?n||(n=s&~e,n!==0&&(i=W(n))):i=W(o)):i=W(r)),i===0?0:t!==0&&t!==i&&(t&a)===0&&(a=i&-i,n=t&-t,a>=n||a===32&&n&4194048)?t:i}function G(e,t){return(e.pendingLanes&~(e.suspendedLanes&~e.pingedLanes)&t)===0}function Be(e,t){switch(e){case 1:case 2:case 4:case 8:case 64:return t+250;case 16:case 32:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return t+5e3;case 4194304:case 8388608:case 16777216:case 33554432:return-1;case 67108864:case 134217728:case 268435456:case 536870912:case 1073741824:return-1;default:return-1}}function Ve(){var e=Re;return Re<<=1,!(Re&62914560)&&(Re=4194304),e}function He(e){for(var t=[],n=0;31>n;n++)t.push(e);return t}function Ue(e,t){e.pendingLanes|=t,t!==268435456&&(e.suspendedLanes=0,e.pingedLanes=0,e.warmLanes=0)}function We(e,t,n,r,i,a){var o=e.pendingLanes;e.pendingLanes=n,e.suspendedLanes=0,e.pingedLanes=0,e.warmLanes=0,e.expiredLanes&=n,e.entangledLanes&=n,e.errorRecoveryDisabledLanes&=n,e.shellSuspendCounter=0;var s=e.entanglements,c=e.expirationTimes,l=e.hiddenUpdates;for(n=o&~n;0<n;){var u=31-je(n),d=1<<u;s[u]=0,c[u]=-1;var f=l[u];if(f!==null)for(l[u]=null,u=0;u<f.length;u++){var p=f[u];p!==null&&(p.lane&=-536870913)}n&=~d}r!==0&&Ge(e,r,0),a!==0&&i===0&&e.tag!==0&&(e.suspendedLanes|=a&~(o&~t))}function Ge(e,t,n){e.pendingLanes|=t,e.suspendedLanes&=~t;var r=31-je(t);e.entangledLanes|=t,e.entanglements[r]=e.entanglements[r]|1073741824|n&261930}function Ke(e,t){var n=e.entangledLanes|=t;for(e=e.entanglements;n;){var r=31-je(n),i=1<<r;i&t|e[r]&t&&(e[r]|=t),n&=~i}}function qe(e,t){var n=t&-t;return n=n&42?1:Je(n),(n&(e.suspendedLanes|t))===0?n:0}function Je(e){switch(e){case 2:e=1;break;case 8:e=4;break;case 32:e=16;break;case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:case 4194304:case 8388608:case 16777216:case 33554432:e=128;break;case 268435456:e=134217728;break;default:e=0}return e}function Ye(e){return e&=-e,2<e?8<e?e&134217727?32:268435456:8:2}function Xe(){var e=I.p;return e===0?(e=window.event,e===void 0?32:mp(e.type)):e}function Ze(e,t){var n=I.p;try{return I.p=e,t()}finally{I.p=n}}var Qe=Math.random().toString(36).slice(2),$e=`__reactFiber$`+Qe,et=`__reactProps$`+Qe,tt=`__reactContainer$`+Qe,nt=`__reactEvents$`+Qe,rt=`__reactListeners$`+Qe,it=`__reactHandles$`+Qe,at=`__reactResources$`+Qe,ot=`__reactMarker$`+Qe;function st(e){delete e[$e],delete e[et],delete e[nt],delete e[rt],delete e[it]}function ct(e){var t=e[$e];if(t)return t;for(var n=e.parentNode;n;){if(t=n[tt]||n[$e]){if(n=t.alternate,t.child!==null||n!==null&&n.child!==null)for(e=df(e);e!==null;){if(n=e[$e])return n;e=df(e)}return t}e=n,n=e.parentNode}return null}function lt(e){if(e=e[$e]||e[tt]){var t=e.tag;if(t===5||t===6||t===13||t===31||t===26||t===27||t===3)return e}return null}function ut(e){var t=e.tag;if(t===5||t===26||t===27||t===6)return e.stateNode;throw Error(a(33))}function dt(e){var t=e[at];return t||=e[at]={hoistableStyles:new Map,hoistableScripts:new Map},t}function ft(e){e[ot]=!0}var pt=new Set,mt={};function ht(e,t){gt(e,t),gt(e+`Capture`,t)}function gt(e,t){for(mt[e]=t,e=0;e<t.length;e++)pt.add(t[e])}var _t=RegExp(`^[:A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD][:A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD\\-.0-9\\u00B7\\u0300-\\u036F\\u203F-\\u2040]*$`),vt={},yt={};function bt(e){return me.call(yt,e)?!0:me.call(vt,e)?!1:_t.test(e)?yt[e]=!0:(vt[e]=!0,!1)}function xt(e,t,n){if(bt(t))if(n===null)e.removeAttribute(t);else{switch(typeof n){case`undefined`:case`function`:case`symbol`:e.removeAttribute(t);return;case`boolean`:var r=t.toLowerCase().slice(0,5);if(r!==`data-`&&r!==`aria-`){e.removeAttribute(t);return}}e.setAttribute(t,``+n)}}function St(e,t,n){if(n===null)e.removeAttribute(t);else{switch(typeof n){case`undefined`:case`function`:case`symbol`:case`boolean`:e.removeAttribute(t);return}e.setAttribute(t,``+n)}}function Ct(e,t,n,r){if(r===null)e.removeAttribute(n);else{switch(typeof r){case`undefined`:case`function`:case`symbol`:case`boolean`:e.removeAttribute(n);return}e.setAttributeNS(t,n,``+r)}}function wt(e){switch(typeof e){case`bigint`:case`boolean`:case`number`:case`string`:case`undefined`:return e;case`object`:return e;default:return``}}function Tt(e){var t=e.type;return(e=e.nodeName)&&e.toLowerCase()===`input`&&(t===`checkbox`||t===`radio`)}function Et(e,t,n){var r=Object.getOwnPropertyDescriptor(e.constructor.prototype,t);if(!e.hasOwnProperty(t)&&r!==void 0&&typeof r.get==`function`&&typeof r.set==`function`){var i=r.get,a=r.set;return Object.defineProperty(e,t,{configurable:!0,get:function(){return i.call(this)},set:function(e){n=``+e,a.call(this,e)}}),Object.defineProperty(e,t,{enumerable:r.enumerable}),{getValue:function(){return n},setValue:function(e){n=``+e},stopTracking:function(){e._valueTracker=null,delete e[t]}}}}function Dt(e){if(!e._valueTracker){var t=Tt(e)?`checked`:`value`;e._valueTracker=Et(e,t,``+e[t])}}function Ot(e){if(!e)return!1;var t=e._valueTracker;if(!t)return!0;var n=t.getValue(),r=``;return e&&(r=Tt(e)?e.checked?`true`:`false`:e.value),e=r,e===n?!1:(t.setValue(e),!0)}function kt(e){if(e||=typeof document<`u`?document:void 0,e===void 0)return null;try{return e.activeElement||e.body}catch{return e.body}}var At=/[\n"\\]/g;function jt(e){return e.replace(At,function(e){return`\\`+e.charCodeAt(0).toString(16)+` `})}function Mt(e,t,n,r,i,a,o,s){e.name=``,o!=null&&typeof o!=`function`&&typeof o!=`symbol`&&typeof o!=`boolean`?e.type=o:e.removeAttribute(`type`),t==null?o!==`submit`&&o!==`reset`||e.removeAttribute(`value`):o===`number`?(t===0&&e.value===``||e.value!=t)&&(e.value=``+wt(t)):e.value!==``+wt(t)&&(e.value=``+wt(t)),t==null?n==null?r!=null&&e.removeAttribute(`value`):Pt(e,o,wt(n)):Pt(e,o,wt(t)),i==null&&a!=null&&(e.defaultChecked=!!a),i!=null&&(e.checked=i&&typeof i!=`function`&&typeof i!=`symbol`),s!=null&&typeof s!=`function`&&typeof s!=`symbol`&&typeof s!=`boolean`?e.name=``+wt(s):e.removeAttribute(`name`)}function Nt(e,t,n,r,i,a,o,s){if(a!=null&&typeof a!=`function`&&typeof a!=`symbol`&&typeof a!=`boolean`&&(e.type=a),t!=null||n!=null){if(!(a!==`submit`&&a!==`reset`||t!=null)){Dt(e);return}n=n==null?``:``+wt(n),t=t==null?n:``+wt(t),s||t===e.value||(e.value=t),e.defaultValue=t}r??=i,r=typeof r!=`function`&&typeof r!=`symbol`&&!!r,e.checked=s?e.checked:!!r,e.defaultChecked=!!r,o!=null&&typeof o!=`function`&&typeof o!=`symbol`&&typeof o!=`boolean`&&(e.name=o),Dt(e)}function Pt(e,t,n){t===`number`&&kt(e.ownerDocument)===e||e.defaultValue===``+n||(e.defaultValue=``+n)}function Ft(e,t,n,r){if(e=e.options,t){t={};for(var i=0;i<n.length;i++)t[`$`+n[i]]=!0;for(n=0;n<e.length;n++)i=t.hasOwnProperty(`$`+e[n].value),e[n].selected!==i&&(e[n].selected=i),i&&r&&(e[n].defaultSelected=!0)}else{for(n=``+wt(n),t=null,i=0;i<e.length;i++){if(e[i].value===n){e[i].selected=!0,r&&(e[i].defaultSelected=!0);return}t!==null||e[i].disabled||(t=e[i])}t!==null&&(t.selected=!0)}}function It(e,t,n){if(t!=null&&(t=``+wt(t),t!==e.value&&(e.value=t),n==null)){e.defaultValue!==t&&(e.defaultValue=t);return}e.defaultValue=n==null?``:``+wt(n)}function Lt(e,t,n,r){if(t==null){if(r!=null){if(n!=null)throw Error(a(92));if(P(r)){if(1<r.length)throw Error(a(93));r=r[0]}n=r}n??=``,t=n}n=wt(t),e.defaultValue=n,r=e.textContent,r===n&&r!==``&&r!==null&&(e.value=r),Dt(e)}function Rt(e,t){if(t){var n=e.firstChild;if(n&&n===e.lastChild&&n.nodeType===3){n.nodeValue=t;return}}e.textContent=t}var zt=new Set(`animationIterationCount aspectRatio borderImageOutset borderImageSlice borderImageWidth boxFlex boxFlexGroup boxOrdinalGroup columnCount columns flex flexGrow flexPositive flexShrink flexNegative flexOrder gridArea gridRow gridRowEnd gridRowSpan gridRowStart gridColumn gridColumnEnd gridColumnSpan gridColumnStart fontWeight lineClamp lineHeight opacity order orphans scale tabSize widows zIndex zoom fillOpacity floodOpacity stopOpacity strokeDasharray strokeDashoffset strokeMiterlimit strokeOpacity strokeWidth MozAnimationIterationCount MozBoxFlex MozBoxFlexGroup MozLineClamp msAnimationIterationCount msFlex msZoom msFlexGrow msFlexNegative msFlexOrder msFlexPositive msFlexShrink msGridColumn msGridColumnSpan msGridRow msGridRowSpan WebkitAnimationIterationCount WebkitBoxFlex WebKitBoxFlexGroup WebkitBoxOrdinalGroup WebkitColumnCount WebkitColumns WebkitFlex WebkitFlexGrow WebkitFlexPositive WebkitFlexShrink WebkitLineClamp`.split(` `));function Bt(e,t,n){var r=t.indexOf(`--`)===0;n==null||typeof n==`boolean`||n===``?r?e.setProperty(t,``):t===`float`?e.cssFloat=``:e[t]=``:r?e.setProperty(t,n):typeof n!=`number`||n===0||zt.has(t)?t===`float`?e.cssFloat=n:e[t]=(``+n).trim():e[t]=n+`px`}function Vt(e,t,n){if(t!=null&&typeof t!=`object`)throw Error(a(62));if(e=e.style,n!=null){for(var r in n)!n.hasOwnProperty(r)||t!=null&&t.hasOwnProperty(r)||(r.indexOf(`--`)===0?e.setProperty(r,``):r===`float`?e.cssFloat=``:e[r]=``);for(var i in t)r=t[i],t.hasOwnProperty(i)&&n[i]!==r&&Bt(e,i,r)}else for(var o in t)t.hasOwnProperty(o)&&Bt(e,o,t[o])}function Ht(e){if(e.indexOf(`-`)===-1)return!1;switch(e){case`annotation-xml`:case`color-profile`:case`font-face`:case`font-face-src`:case`font-face-uri`:case`font-face-format`:case`font-face-name`:case`missing-glyph`:return!1;default:return!0}}var Ut=new Map([[`acceptCharset`,`accept-charset`],[`htmlFor`,`for`],[`httpEquiv`,`http-equiv`],[`crossOrigin`,`crossorigin`],[`accentHeight`,`accent-height`],[`alignmentBaseline`,`alignment-baseline`],[`arabicForm`,`arabic-form`],[`baselineShift`,`baseline-shift`],[`capHeight`,`cap-height`],[`clipPath`,`clip-path`],[`clipRule`,`clip-rule`],[`colorInterpolation`,`color-interpolation`],[`colorInterpolationFilters`,`color-interpolation-filters`],[`colorProfile`,`color-profile`],[`colorRendering`,`color-rendering`],[`dominantBaseline`,`dominant-baseline`],[`enableBackground`,`enable-background`],[`fillOpacity`,`fill-opacity`],[`fillRule`,`fill-rule`],[`floodColor`,`flood-color`],[`floodOpacity`,`flood-opacity`],[`fontFamily`,`font-family`],[`fontSize`,`font-size`],[`fontSizeAdjust`,`font-size-adjust`],[`fontStretch`,`font-stretch`],[`fontStyle`,`font-style`],[`fontVariant`,`font-variant`],[`fontWeight`,`font-weight`],[`glyphName`,`glyph-name`],[`glyphOrientationHorizontal`,`glyph-orientation-horizontal`],[`glyphOrientationVertical`,`glyph-orientation-vertical`],[`horizAdvX`,`horiz-adv-x`],[`horizOriginX`,`horiz-origin-x`],[`imageRendering`,`image-rendering`],[`letterSpacing`,`letter-spacing`],[`lightingColor`,`lighting-color`],[`markerEnd`,`marker-end`],[`markerMid`,`marker-mid`],[`markerStart`,`marker-start`],[`overlinePosition`,`overline-position`],[`overlineThickness`,`overline-thickness`],[`paintOrder`,`paint-order`],[`panose-1`,`panose-1`],[`pointerEvents`,`pointer-events`],[`renderingIntent`,`rendering-intent`],[`shapeRendering`,`shape-rendering`],[`stopColor`,`stop-color`],[`stopOpacity`,`stop-opacity`],[`strikethroughPosition`,`strikethrough-position`],[`strikethroughThickness`,`strikethrough-thickness`],[`strokeDasharray`,`stroke-dasharray`],[`strokeDashoffset`,`stroke-dashoffset`],[`strokeLinecap`,`stroke-linecap`],[`strokeLinejoin`,`stroke-linejoin`],[`strokeMiterlimit`,`stroke-miterlimit`],[`strokeOpacity`,`stroke-opacity`],[`strokeWidth`,`stroke-width`],[`textAnchor`,`text-anchor`],[`textDecoration`,`text-decoration`],[`textRendering`,`text-rendering`],[`transformOrigin`,`transform-origin`],[`underlinePosition`,`underline-position`],[`underlineThickness`,`underline-thickness`],[`unicodeBidi`,`unicode-bidi`],[`unicodeRange`,`unicode-range`],[`unitsPerEm`,`units-per-em`],[`vAlphabetic`,`v-alphabetic`],[`vHanging`,`v-hanging`],[`vIdeographic`,`v-ideographic`],[`vMathematical`,`v-mathematical`],[`vectorEffect`,`vector-effect`],[`vertAdvY`,`vert-adv-y`],[`vertOriginX`,`vert-origin-x`],[`vertOriginY`,`vert-origin-y`],[`wordSpacing`,`word-spacing`],[`writingMode`,`writing-mode`],[`xmlnsXlink`,`xmlns:xlink`],[`xHeight`,`x-height`]]),Wt=/^[\u0000-\u001F ]*j[\r\n\t]*a[\r\n\t]*v[\r\n\t]*a[\r\n\t]*s[\r\n\t]*c[\r\n\t]*r[\r\n\t]*i[\r\n\t]*p[\r\n\t]*t[\r\n\t]*:/i;function Gt(e){return Wt.test(``+e)?`javascript:throw new Error('React has blocked a javascript: URL as a security precaution.')`:e}function Kt(){}var qt=null;function Jt(e){return e=e.target||e.srcElement||window,e.correspondingUseElement&&(e=e.correspondingUseElement),e.nodeType===3?e.parentNode:e}var Yt=null,Xt=null;function Zt(e){var t=lt(e);if(t&&(e=t.stateNode)){var n=e[et]||null;a:switch(e=t.stateNode,t.type){case`input`:if(Mt(e,n.value,n.defaultValue,n.defaultValue,n.checked,n.defaultChecked,n.type,n.name),t=n.name,n.type===`radio`&&t!=null){for(n=e;n.parentNode;)n=n.parentNode;for(n=n.querySelectorAll(`input[name="`+jt(``+t)+`"][type="radio"]`),t=0;t<n.length;t++){var r=n[t];if(r!==e&&r.form===e.form){var i=r[et]||null;if(!i)throw Error(a(90));Mt(r,i.value,i.defaultValue,i.defaultValue,i.checked,i.defaultChecked,i.type,i.name)}}for(t=0;t<n.length;t++)r=n[t],r.form===e.form&&Ot(r)}break a;case`textarea`:It(e,n.value,n.defaultValue);break a;case`select`:t=n.value,t!=null&&Ft(e,!!n.multiple,t,!1)}}}var Qt=!1;function $t(e,t,n){if(Qt)return e(t,n);Qt=!0;try{return e(t)}finally{if(Qt=!1,(Yt!==null||Xt!==null)&&(vu(),Yt&&(t=Yt,e=Xt,Xt=Yt=null,Zt(t),e)))for(t=0;t<e.length;t++)Zt(e[t])}}function en(e,t){var n=e.stateNode;if(n===null)return null;var r=n[et]||null;if(r===null)return null;n=r[t];a:switch(t){case`onClick`:case`onClickCapture`:case`onDoubleClick`:case`onDoubleClickCapture`:case`onMouseDown`:case`onMouseDownCapture`:case`onMouseMove`:case`onMouseMoveCapture`:case`onMouseUp`:case`onMouseUpCapture`:case`onMouseEnter`:(r=!r.disabled)||(e=e.type,r=!(e===`button`||e===`input`||e===`select`||e===`textarea`)),e=!r;break a;default:e=!1}if(e)return null;if(n&&typeof n!=`function`)throw Error(a(231,t,typeof n));return n}var tn=!(typeof window>`u`||window.document===void 0||window.document.createElement===void 0),nn=!1;if(tn)try{var rn={};Object.defineProperty(rn,"passive",{get:function(){nn=!0}}),window.addEventListener(`test`,rn,rn),window.removeEventListener(`test`,rn,rn)}catch{nn=!1}var an=null,on=null,sn=null;function cn(){if(sn)return sn;var e,t=on,n=t.length,r,i=`value`in an?an.value:an.textContent,a=i.length;for(e=0;e<n&&t[e]===i[e];e++);var o=n-e;for(r=1;r<=o&&t[n-r]===i[a-r];r++);return sn=i.slice(e,1<r?1-r:void 0)}function ln(e){var t=e.keyCode;return`charCode`in e?(e=e.charCode,e===0&&t===13&&(e=13)):e=t,e===10&&(e=13),32<=e||e===13?e:0}function un(){return!0}function dn(){return!1}function fn(e){function t(t,n,r,i,a){for(var o in this._reactName=t,this._targetInst=r,this.type=n,this.nativeEvent=i,this.target=a,this.currentTarget=null,e)e.hasOwnProperty(o)&&(t=e[o],this[o]=t?t(i):i[o]);return this.isDefaultPrevented=(i.defaultPrevented==null?!1===i.returnValue:i.defaultPrevented)?un:dn,this.isPropagationStopped=dn,this}return p(t.prototype,{preventDefault:function(){this.defaultPrevented=!0;var e=this.nativeEvent;e&&(e.preventDefault?e.preventDefault():typeof e.returnValue!=`unknown`&&(e.returnValue=!1),this.isDefaultPrevented=un)},stopPropagation:function(){var e=this.nativeEvent;e&&(e.stopPropagation?e.stopPropagation():typeof e.cancelBubble!=`unknown`&&(e.cancelBubble=!0),this.isPropagationStopped=un)},persist:function(){},isPersistent:un}),t}var pn={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(e){return e.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},K=fn(pn),mn=p({},pn,{view:0,detail:0}),hn=fn(mn),gn,_n,q,vn=p({},mn,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:kn,button:0,buttons:0,relatedTarget:function(e){return e.relatedTarget===void 0?e.fromElement===e.srcElement?e.toElement:e.fromElement:e.relatedTarget},movementX:function(e){return`movementX`in e?e.movementX:(e!==q&&(q&&e.type===`mousemove`?(gn=e.screenX-q.screenX,_n=e.screenY-q.screenY):_n=gn=0,q=e),gn)},movementY:function(e){return`movementY`in e?e.movementY:_n}}),yn=fn(vn),bn=fn(p({},vn,{dataTransfer:0})),xn=fn(p({},mn,{relatedTarget:0})),Sn=fn(p({},pn,{animationName:0,elapsedTime:0,pseudoElement:0})),Cn=fn(p({},pn,{clipboardData:function(e){return`clipboardData`in e?e.clipboardData:window.clipboardData}})),wn=fn(p({},pn,{data:0})),Tn={Esc:`Escape`,Spacebar:` `,Left:`ArrowLeft`,Up:`ArrowUp`,Right:`ArrowRight`,Down:`ArrowDown`,Del:`Delete`,Win:`OS`,Menu:`ContextMenu`,Apps:`ContextMenu`,Scroll:`ScrollLock`,MozPrintableKey:`Unidentified`},En={8:`Backspace`,9:`Tab`,12:`Clear`,13:`Enter`,16:`Shift`,17:`Control`,18:`Alt`,19:`Pause`,20:`CapsLock`,27:`Escape`,32:` `,33:`PageUp`,34:`PageDown`,35:`End`,36:`Home`,37:`ArrowLeft`,38:`ArrowUp`,39:`ArrowRight`,40:`ArrowDown`,45:`Insert`,46:`Delete`,112:`F1`,113:`F2`,114:`F3`,115:`F4`,116:`F5`,117:`F6`,118:`F7`,119:`F8`,120:`F9`,121:`F10`,122:`F11`,123:`F12`,144:`NumLock`,145:`ScrollLock`,224:`Meta`},Dn={Alt:`altKey`,Control:`ctrlKey`,Meta:`metaKey`,Shift:`shiftKey`};function On(e){var t=this.nativeEvent;return t.getModifierState?t.getModifierState(e):(e=Dn[e])?!!t[e]:!1}function kn(){return On}var An=fn(p({},mn,{key:function(e){if(e.key){var t=Tn[e.key]||e.key;if(t!==`Unidentified`)return t}return e.type===`keypress`?(e=ln(e),e===13?`Enter`:String.fromCharCode(e)):e.type===`keydown`||e.type===`keyup`?En[e.keyCode]||`Unidentified`:``},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:kn,charCode:function(e){return e.type===`keypress`?ln(e):0},keyCode:function(e){return e.type===`keydown`||e.type===`keyup`?e.keyCode:0},which:function(e){return e.type===`keypress`?ln(e):e.type===`keydown`||e.type===`keyup`?e.keyCode:0}})),jn=fn(p({},vn,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0})),Mn=fn(p({},mn,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:kn})),Nn=fn(p({},pn,{propertyName:0,elapsedTime:0,pseudoElement:0})),Pn=fn(p({},vn,{deltaX:function(e){return`deltaX`in e?e.deltaX:`wheelDeltaX`in e?-e.wheelDeltaX:0},deltaY:function(e){return`deltaY`in e?e.deltaY:`wheelDeltaY`in e?-e.wheelDeltaY:`wheelDelta`in e?-e.wheelDelta:0},deltaZ:0,deltaMode:0})),Fn=fn(p({},pn,{newState:0,oldState:0})),In=[9,13,27,32],Ln=tn&&`CompositionEvent`in window,Rn=null;tn&&`documentMode`in document&&(Rn=document.documentMode);var zn=tn&&`TextEvent`in window&&!Rn,Bn=tn&&(!Ln||Rn&&8<Rn&&11>=Rn),Vn=` `,Hn=!1;function Un(e,t){switch(e){case`keyup`:return In.indexOf(t.keyCode)!==-1;case`keydown`:return t.keyCode!==229;case`keypress`:case`mousedown`:case`focusout`:return!0;default:return!1}}function Wn(e){return e=e.detail,typeof e==`object`&&`data`in e?e.data:null}var Gn=!1;function Kn(e,t){switch(e){case`compositionend`:return Wn(t);case`keypress`:return t.which===32?(Hn=!0,Vn):null;case`textInput`:return e=t.data,e===Vn&&Hn?null:e;default:return null}}function qn(e,t){if(Gn)return e===`compositionend`||!Ln&&Un(e,t)?(e=cn(),sn=on=an=null,Gn=!1,e):null;switch(e){case`paste`:return null;case`keypress`:if(!(t.ctrlKey||t.altKey||t.metaKey)||t.ctrlKey&&t.altKey){if(t.char&&1<t.char.length)return t.char;if(t.which)return String.fromCharCode(t.which)}return null;case`compositionend`:return Bn&&t.locale!==`ko`?null:t.data;default:return null}}var Jn={color:!0,date:!0,datetime:!0,"datetime-local":!0,email:!0,month:!0,number:!0,password:!0,range:!0,search:!0,tel:!0,text:!0,time:!0,url:!0,week:!0};function Yn(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t===`input`?!!Jn[e.type]:t===`textarea`}function Xn(e,t,n,r){Yt?Xt?Xt.push(r):Xt=[r]:Yt=r,t=Td(t,`onChange`),0<t.length&&(n=new K(`onChange`,`change`,null,n,r),e.push({event:n,listeners:t}))}var Zn=null,Qn=null;function $n(e){vd(e,0)}function er(e){if(Ot(ut(e)))return e}function tr(e,t){if(e===`change`)return t}var nr=!1;if(tn){var rr;if(tn){var ir=`oninput`in document;if(!ir){var ar=document.createElement(`div`);ar.setAttribute(`oninput`,`return;`),ir=typeof ar.oninput==`function`}rr=ir}else rr=!1;nr=rr&&(!document.documentMode||9<document.documentMode)}function or(){Zn&&(Zn.detachEvent(`onpropertychange`,sr),Qn=Zn=null)}function sr(e){if(e.propertyName===`value`&&er(Qn)){var t=[];Xn(t,Qn,e,Jt(e)),$t($n,t)}}function cr(e,t,n){e===`focusin`?(or(),Zn=t,Qn=n,Zn.attachEvent(`onpropertychange`,sr)):e===`focusout`&&or()}function lr(e){if(e===`selectionchange`||e===`keyup`||e===`keydown`)return er(Qn)}function ur(e,t){if(e===`click`)return er(t)}function dr(e,t){if(e===`input`||e===`change`)return er(t)}function fr(e,t){return e===t&&(e!==0||1/e==1/t)||e!==e&&t!==t}var pr=typeof Object.is==`function`?Object.is:fr;function mr(e,t){if(pr(e,t))return!0;if(typeof e!=`object`||!e||typeof t!=`object`||!t)return!1;var n=Object.keys(e),r=Object.keys(t);if(n.length!==r.length)return!1;for(r=0;r<n.length;r++){var i=n[r];if(!me.call(t,i)||!pr(e[i],t[i]))return!1}return!0}function hr(e){for(;e&&e.firstChild;)e=e.firstChild;return e}function gr(e,t){var n=hr(e);e=0;for(var r;n;){if(n.nodeType===3){if(r=e+n.textContent.length,e<=t&&r>=t)return{node:n,offset:t-e};e=r}a:{for(;n;){if(n.nextSibling){n=n.nextSibling;break a}n=n.parentNode}n=void 0}n=hr(n)}}function _r(e,t){return e&&t?e===t?!0:e&&e.nodeType===3?!1:t&&t.nodeType===3?_r(e,t.parentNode):`contains`in e?e.contains(t):e.compareDocumentPosition?!!(e.compareDocumentPosition(t)&16):!1:!1}function vr(e){e=e!=null&&e.ownerDocument!=null&&e.ownerDocument.defaultView!=null?e.ownerDocument.defaultView:window;for(var t=kt(e.document);t instanceof e.HTMLIFrameElement;){try{var n=typeof t.contentWindow.location.href==`string`}catch{n=!1}if(n)e=t.contentWindow;else break;t=kt(e.document)}return t}function yr(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t&&(t===`input`&&(e.type===`text`||e.type===`search`||e.type===`tel`||e.type===`url`||e.type===`password`)||t===`textarea`||e.contentEditable===`true`)}var br=tn&&`documentMode`in document&&11>=document.documentMode,xr=null,Sr=null,Cr=null,wr=!1;function Tr(e,t,n){var r=n.window===n?n.document:n.nodeType===9?n:n.ownerDocument;wr||xr==null||xr!==kt(r)||(r=xr,`selectionStart`in r&&yr(r)?r={start:r.selectionStart,end:r.selectionEnd}:(r=(r.ownerDocument&&r.ownerDocument.defaultView||window).getSelection(),r={anchorNode:r.anchorNode,anchorOffset:r.anchorOffset,focusNode:r.focusNode,focusOffset:r.focusOffset}),Cr&&mr(Cr,r)||(Cr=r,r=Td(Sr,`onSelect`),0<r.length&&(t=new K(`onSelect`,`select`,null,t,n),e.push({event:t,listeners:r}),t.target=xr)))}function Er(e,t){var n={};return n[e.toLowerCase()]=t.toLowerCase(),n[`Webkit`+e]=`webkit`+t,n[`Moz`+e]=`moz`+t,n}var Dr={animationend:Er(`Animation`,`AnimationEnd`),animationiteration:Er(`Animation`,`AnimationIteration`),animationstart:Er(`Animation`,`AnimationStart`),transitionrun:Er(`Transition`,`TransitionRun`),transitionstart:Er(`Transition`,`TransitionStart`),transitioncancel:Er(`Transition`,`TransitionCancel`),transitionend:Er(`Transition`,`TransitionEnd`)},Or={},kr={};tn&&(kr=document.createElement(`div`).style,`AnimationEvent`in window||(delete Dr.animationend.animation,delete Dr.animationiteration.animation,delete Dr.animationstart.animation),`TransitionEvent`in window||delete Dr.transitionend.transition);function Ar(e){if(Or[e])return Or[e];if(!Dr[e])return e;var t=Dr[e],n;for(n in t)if(t.hasOwnProperty(n)&&n in kr)return Or[e]=t[n];return e}var jr=Ar(`animationend`),Mr=Ar(`animationiteration`),Nr=Ar(`animationstart`),Pr=Ar(`transitionrun`),Fr=Ar(`transitionstart`),Ir=Ar(`transitioncancel`),Lr=Ar(`transitionend`),Rr=new Map,zr=`abort auxClick beforeToggle cancel canPlay canPlayThrough click close contextMenu copy cut drag dragEnd dragEnter dragExit dragLeave dragOver dragStart drop durationChange emptied encrypted ended error gotPointerCapture input invalid keyDown keyPress keyUp load loadedData loadedMetadata loadStart lostPointerCapture mouseDown mouseMove mouseOut mouseOver mouseUp paste pause play playing pointerCancel pointerDown pointerMove pointerOut pointerOver pointerUp progress rateChange reset resize seeked seeking stalled submit suspend timeUpdate touchCancel touchEnd touchStart volumeChange scroll toggle touchMove waiting wheel`.split(` `);zr.push(`scrollEnd`);function Br(e,t){Rr.set(e,t),ht(t,[e])}var Vr=typeof reportError==`function`?reportError:function(e){if(typeof window==`object`&&typeof window.ErrorEvent==`function`){var t=new window.ErrorEvent(`error`,{bubbles:!0,cancelable:!0,message:typeof e==`object`&&e&&typeof e.message==`string`?String(e.message):String(e),error:e});if(!window.dispatchEvent(t))return}else if(typeof process==`object`&&typeof process.emit==`function`){process.emit(`uncaughtException`,e);return}console.error(e)},Hr=[],Ur=0,Wr=0;function Gr(){for(var e=Ur,t=Wr=Ur=0;t<e;){var n=Hr[t];Hr[t++]=null;var r=Hr[t];Hr[t++]=null;var i=Hr[t];Hr[t++]=null;var a=Hr[t];if(Hr[t++]=null,r!==null&&i!==null){var o=r.pending;o===null?i.next=i:(i.next=o.next,o.next=i),r.pending=i}a!==0&&Yr(n,i,a)}}function Kr(e,t,n,r){Hr[Ur++]=e,Hr[Ur++]=t,Hr[Ur++]=n,Hr[Ur++]=r,Wr|=r,e.lanes|=r,e=e.alternate,e!==null&&(e.lanes|=r)}function qr(e,t,n,r){return Kr(e,t,n,r),Xr(e)}function Jr(e,t){return Kr(e,null,null,t),Xr(e)}function Yr(e,t,n){e.lanes|=n;var r=e.alternate;r!==null&&(r.lanes|=n);for(var i=!1,a=e.return;a!==null;)a.childLanes|=n,r=a.alternate,r!==null&&(r.childLanes|=n),a.tag===22&&(e=a.stateNode,e===null||e._visibility&1||(i=!0)),e=a,a=a.return;return e.tag===3?(a=e.stateNode,i&&t!==null&&(i=31-je(n),e=a.hiddenUpdates,r=e[i],r===null?e[i]=[t]:r.push(t),t.lane=n|536870912),a):null}function Xr(e){if(50<lu)throw lu=0,uu=null,Error(a(185));for(var t=e.return;t!==null;)e=t,t=e.return;return e.tag===3?e.stateNode:null}var Zr={};function Qr(e,t,n,r){this.tag=e,this.key=n,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.refCleanup=this.ref=null,this.pendingProps=t,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=r,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function $r(e,t,n,r){return new Qr(e,t,n,r)}function ei(e){return e=e.prototype,!(!e||!e.isReactComponent)}function ti(e,t){var n=e.alternate;return n===null?(n=$r(e.tag,t,e.key,e.mode),n.elementType=e.elementType,n.type=e.type,n.stateNode=e.stateNode,n.alternate=e,e.alternate=n):(n.pendingProps=t,n.type=e.type,n.flags=0,n.subtreeFlags=0,n.deletions=null),n.flags=e.flags&65011712,n.childLanes=e.childLanes,n.lanes=e.lanes,n.child=e.child,n.memoizedProps=e.memoizedProps,n.memoizedState=e.memoizedState,n.updateQueue=e.updateQueue,t=e.dependencies,n.dependencies=t===null?null:{lanes:t.lanes,firstContext:t.firstContext},n.sibling=e.sibling,n.index=e.index,n.ref=e.ref,n.refCleanup=e.refCleanup,n}function ni(e,t){e.flags&=65011714;var n=e.alternate;return n===null?(e.childLanes=0,e.lanes=t,e.child=null,e.subtreeFlags=0,e.memoizedProps=null,e.memoizedState=null,e.updateQueue=null,e.dependencies=null,e.stateNode=null):(e.childLanes=n.childLanes,e.lanes=n.lanes,e.child=n.child,e.subtreeFlags=0,e.deletions=null,e.memoizedProps=n.memoizedProps,e.memoizedState=n.memoizedState,e.updateQueue=n.updateQueue,e.type=n.type,t=n.dependencies,e.dependencies=t===null?null:{lanes:t.lanes,firstContext:t.firstContext}),e}function ri(e,t,n,r,i,o){var s=0;if(r=e,typeof e==`function`)ei(e)&&(s=1);else if(typeof e==`string`)s=Uf(e,n,re.current)?26:e===`html`||e===`head`||e===`body`?27:5;else a:switch(e){case O:return e=$r(31,n,t,i),e.elementType=O,e.lanes=o,e;case _:return ii(n.children,i,o,t);case v:s=8,i|=24;break;case y:return e=$r(12,n,t,i|2),e.elementType=y,e.lanes=o,e;case w:return e=$r(13,n,t,i),e.elementType=w,e.lanes=o,e;case T:return e=$r(19,n,t,i),e.elementType=T,e.lanes=o,e;default:if(typeof e==`object`&&e)switch(e.$$typeof){case S:s=10;break a;case b:s=9;break a;case C:s=11;break a;case E:s=14;break a;case D:s=16,r=null;break a}s=29,n=Error(a(130,e===null?`null`:typeof e,``)),r=null}return t=$r(s,n,t,i),t.elementType=e,t.type=r,t.lanes=o,t}function ii(e,t,n,r){return e=$r(7,e,r,t),e.lanes=n,e}function ai(e,t,n){return e=$r(6,e,null,t),e.lanes=n,e}function oi(e){var t=$r(18,null,null,0);return t.stateNode=e,t}function si(e,t,n){return t=$r(4,e.children===null?[]:e.children,e.key,t),t.lanes=n,t.stateNode={containerInfo:e.containerInfo,pendingChildren:null,implementation:e.implementation},t}var ci=new WeakMap;function li(e,t){if(typeof e==`object`&&e){var n=ci.get(e);return n===void 0?(t={value:e,source:t,stack:pe(t)},ci.set(e,t),t):n}return{value:e,source:t,stack:pe(t)}}var ui=[],di=0,fi=null,pi=0,mi=[],hi=0,gi=null,_i=1,vi=``;function yi(e,t){ui[di++]=pi,ui[di++]=fi,fi=e,pi=t}function bi(e,t,n){mi[hi++]=_i,mi[hi++]=vi,mi[hi++]=gi,gi=e;var r=_i;e=vi;var i=32-je(r)-1;r&=~(1<<i),n+=1;var a=32-je(t)+i;if(30<a){var o=i-i%5;a=(r&(1<<o)-1).toString(32),r>>=o,i-=o,_i=1<<32-je(t)+i|n<<i|r,vi=a+e}else _i=1<<a|n<<i|r,vi=e}function xi(e){e.return!==null&&(yi(e,1),bi(e,1,0))}function Si(e){for(;e===fi;)fi=ui[--di],ui[di]=null,pi=ui[--di],ui[di]=null;for(;e===gi;)gi=mi[--hi],mi[hi]=null,vi=mi[--hi],mi[hi]=null,_i=mi[--hi],mi[hi]=null}function Ci(e,t){mi[hi++]=_i,mi[hi++]=vi,mi[hi++]=gi,_i=t.id,vi=t.overflow,gi=e}var wi=null,Ti=null,J=!1,Y=null,Ei=!1,Di=Error(a(519));function Oi(e){throw Pi(li(Error(a(418,1<arguments.length&&arguments[1]!==void 0&&arguments[1]?`text`:`HTML`,``)),e)),Di}function ki(e){var t=e.stateNode,n=e.type,r=e.memoizedProps;switch(t[$e]=e,t[et]=r,n){case`dialog`:$(`cancel`,t),$(`close`,t);break;case`iframe`:case`object`:case`embed`:$(`load`,t);break;case`video`:case`audio`:for(n=0;n<gd.length;n++)$(gd[n],t);break;case`source`:$(`error`,t);break;case`img`:case`image`:case`link`:$(`error`,t),$(`load`,t);break;case`details`:$(`toggle`,t);break;case`input`:$(`invalid`,t),Nt(t,r.value,r.defaultValue,r.checked,r.defaultChecked,r.type,r.name,!0);break;case`select`:$(`invalid`,t);break;case`textarea`:$(`invalid`,t),Lt(t,r.value,r.defaultValue,r.children)}n=r.children,typeof n!=`string`&&typeof n!=`number`&&typeof n!=`bigint`||t.textContent===``+n||!0===r.suppressHydrationWarning||jd(t.textContent,n)?(r.popover!=null&&($(`beforetoggle`,t),$(`toggle`,t)),r.onScroll!=null&&$(`scroll`,t),r.onScrollEnd!=null&&$(`scrollend`,t),r.onClick!=null&&(t.onclick=Kt),t=!0):t=!1,t||Oi(e,!0)}function Ai(e){for(wi=e.return;wi;)switch(wi.tag){case 5:case 31:case 13:Ei=!1;return;case 27:case 3:Ei=!0;return;default:wi=wi.return}}function ji(e){if(e!==wi)return!1;if(!J)return Ai(e),J=!0,!1;var t=e.tag,n;if((n=t!==3&&t!==27)&&((n=t===5)&&(n=e.type,n=!(n!==`form`&&n!==`button`)||Ud(e.type,e.memoizedProps)),n=!n),n&&Ti&&Oi(e),Ai(e),t===13){if(e=e.memoizedState,e=e===null?null:e.dehydrated,!e)throw Error(a(317));Ti=uf(e)}else if(t===31){if(e=e.memoizedState,e=e===null?null:e.dehydrated,!e)throw Error(a(317));Ti=uf(e)}else t===27?(t=Ti,Zd(e.type)?(e=lf,lf=null,Ti=e):Ti=t):Ti=wi?cf(e.stateNode.nextSibling):null;return!0}function Mi(){Ti=wi=null,J=!1}function Ni(){var e=Y;return e!==null&&(Yl===null?Yl=e:Yl.push.apply(Yl,e),Y=null),e}function Pi(e){Y===null?Y=[e]:Y.push(e)}var Fi=L(null),Ii=null,Li=null;function Ri(e,t,n){z(Fi,t._currentValue),t._currentValue=n}function zi(e){e._currentValue=Fi.current,R(Fi)}function Bi(e,t,n){for(;e!==null;){var r=e.alternate;if((e.childLanes&t)===t?r!==null&&(r.childLanes&t)!==t&&(r.childLanes|=t):(e.childLanes|=t,r!==null&&(r.childLanes|=t)),e===n)break;e=e.return}}function Vi(e,t,n,r){var i=e.child;for(i!==null&&(i.return=e);i!==null;){var o=i.dependencies;if(o!==null){var s=i.child;o=o.firstContext;a:for(;o!==null;){var c=o;o=i;for(var l=0;l<t.length;l++)if(c.context===t[l]){o.lanes|=n,c=o.alternate,c!==null&&(c.lanes|=n),Bi(o.return,n,e),r||(s=null);break a}o=c.next}}else if(i.tag===18){if(s=i.return,s===null)throw Error(a(341));s.lanes|=n,o=s.alternate,o!==null&&(o.lanes|=n),Bi(s,n,e),s=null}else s=i.child;if(s!==null)s.return=i;else for(s=i;s!==null;){if(s===e){s=null;break}if(i=s.sibling,i!==null){i.return=s.return,s=i;break}s=s.return}i=s}}function Hi(e,t,n,r){e=null;for(var i=t,o=!1;i!==null;){if(!o){if(i.flags&524288)o=!0;else if(i.flags&262144)break}if(i.tag===10){var s=i.alternate;if(s===null)throw Error(a(387));if(s=s.memoizedProps,s!==null){var c=i.type;pr(i.pendingProps.value,s.value)||(e===null?e=[c]:e.push(c))}}else if(i===V.current){if(s=i.alternate,s===null)throw Error(a(387));s.memoizedState.memoizedState!==i.memoizedState.memoizedState&&(e===null?e=[Qf]:e.push(Qf))}i=i.return}e!==null&&Vi(t,e,n,r),t.flags|=262144}function Ui(e){for(e=e.firstContext;e!==null;){if(!pr(e.context._currentValue,e.memoizedValue))return!0;e=e.next}return!1}function Wi(e){Ii=e,Li=null,e=e.dependencies,e!==null&&(e.firstContext=null)}function Gi(e){return qi(Ii,e)}function Ki(e,t){return Ii===null&&Wi(e),qi(e,t)}function qi(e,t){var n=t._currentValue;if(t={context:t,memoizedValue:n,next:null},Li===null){if(e===null)throw Error(a(308));Li=t,e.dependencies={lanes:0,firstContext:t},e.flags|=524288}else Li=Li.next=t;return n}var Ji=typeof AbortController<`u`?AbortController:function(){var e=[],t=this.signal={aborted:!1,addEventListener:function(t,n){e.push(n)}};this.abort=function(){t.aborted=!0,e.forEach(function(e){return e()})}},Yi=t.unstable_scheduleCallback,Xi=t.unstable_NormalPriority,Zi={$$typeof:S,Consumer:null,Provider:null,_currentValue:null,_currentValue2:null,_threadCount:0};function Qi(){return{controller:new Ji,data:new Map,refCount:0}}function $i(e){e.refCount--,e.refCount===0&&Yi(Xi,function(){e.controller.abort()})}var ea=null,ta=0,na=0,ra=null;function ia(e,t){if(ea===null){var n=ea=[];ta=0,na=ud(),ra={status:`pending`,value:void 0,then:function(e){n.push(e)}}}return ta++,t.then(aa,aa),t}function aa(){if(--ta===0&&ea!==null){ra!==null&&(ra.status=`fulfilled`);var e=ea;ea=null,na=0,ra=null;for(var t=0;t<e.length;t++)(0,e[t])()}}function oa(e,t){var n=[],r={status:`pending`,value:null,reason:null,then:function(e){n.push(e)}};return e.then(function(){r.status=`fulfilled`,r.value=t;for(var e=0;e<n.length;e++)(0,n[e])(t)},function(e){for(r.status=`rejected`,r.reason=e,e=0;e<n.length;e++)(0,n[e])(void 0)}),r}var sa=F.S;F.S=function(e,t){Ql=ye(),typeof t==`object`&&t&&typeof t.then==`function`&&ia(e,t),sa!==null&&sa(e,t)};var ca=L(null);function la(){var e=ca.current;return e===null?Pl.pooledCache:e}function ua(e,t){t===null?z(ca,ca.current):z(ca,t.pool)}function da(){var e=la();return e===null?null:{parent:Zi._currentValue,pool:e}}var fa=Error(a(460)),pa=Error(a(474)),ma=Error(a(542)),ha={then:function(){}};function ga(e){return e=e.status,e===`fulfilled`||e===`rejected`}function _a(e,t,n){switch(n=e[n],n===void 0?e.push(t):n!==t&&(t.then(Kt,Kt),t=n),t.status){case`fulfilled`:return t.value;case`rejected`:throw e=t.reason,xa(e),e;default:if(typeof t.status==`string`)t.then(Kt,Kt);else{if(e=Pl,e!==null&&100<e.shellSuspendCounter)throw Error(a(482));e=t,e.status=`pending`,e.then(function(e){if(t.status===`pending`){var n=t;n.status=`fulfilled`,n.value=e}},function(e){if(t.status===`pending`){var n=t;n.status=`rejected`,n.reason=e}})}switch(t.status){case`fulfilled`:return t.value;case`rejected`:throw e=t.reason,xa(e),e}throw ya=t,fa}}function va(e){try{var t=e._init;return t(e._payload)}catch(e){throw typeof e==`object`&&e&&typeof e.then==`function`?(ya=e,fa):e}}var ya=null;function ba(){if(ya===null)throw Error(a(459));var e=ya;return ya=null,e}function xa(e){if(e===fa||e===ma)throw Error(a(483))}var Sa=null,Ca=0;function wa(e){var t=Ca;return Ca+=1,Sa===null&&(Sa=[]),_a(Sa,e,t)}function Ta(e,t){t=t.props.ref,e.ref=t===void 0?null:t}function Ea(e,t){throw t.$$typeof===m?Error(a(525)):(e=Object.prototype.toString.call(t),Error(a(31,e===`[object Object]`?`object with keys {`+Object.keys(t).join(`, `)+`}`:e)))}function Da(e){function t(t,n){if(e){var r=t.deletions;r===null?(t.deletions=[n],t.flags|=16):r.push(n)}}function n(n,r){if(!e)return null;for(;r!==null;)t(n,r),r=r.sibling;return null}function r(e){for(var t=new Map;e!==null;)e.key===null?t.set(e.index,e):t.set(e.key,e),e=e.sibling;return t}function i(e,t){return e=ti(e,t),e.index=0,e.sibling=null,e}function o(t,n,r){return t.index=r,e?(r=t.alternate,r===null?(t.flags|=67108866,n):(r=r.index,r<n?(t.flags|=67108866,n):r)):(t.flags|=1048576,n)}function s(t){return e&&t.alternate===null&&(t.flags|=67108866),t}function c(e,t,n,r){return t===null||t.tag!==6?(t=ai(n,e.mode,r),t.return=e,t):(t=i(t,n),t.return=e,t)}function l(e,t,n,r){var a=n.type;return a===_?d(e,t,n.props.children,r,n.key):t!==null&&(t.elementType===a||typeof a==`object`&&a&&a.$$typeof===D&&va(a)===t.type)?(t=i(t,n.props),Ta(t,n),t.return=e,t):(t=ri(n.type,n.key,n.props,null,e.mode,r),Ta(t,n),t.return=e,t)}function u(e,t,n,r){return t===null||t.tag!==4||t.stateNode.containerInfo!==n.containerInfo||t.stateNode.implementation!==n.implementation?(t=si(n,e.mode,r),t.return=e,t):(t=i(t,n.children||[]),t.return=e,t)}function d(e,t,n,r,a){return t===null||t.tag!==7?(t=ii(n,e.mode,r,a),t.return=e,t):(t=i(t,n),t.return=e,t)}function f(e,t,n){if(typeof t==`string`&&t!==``||typeof t==`number`||typeof t==`bigint`)return t=ai(``+t,e.mode,n),t.return=e,t;if(typeof t==`object`&&t){switch(t.$$typeof){case h:return n=ri(t.type,t.key,t.props,null,e.mode,n),Ta(n,t),n.return=e,n;case g:return t=si(t,e.mode,n),t.return=e,t;case D:return t=va(t),f(e,t,n)}if(P(t)||j(t))return t=ii(t,e.mode,n,null),t.return=e,t;if(typeof t.then==`function`)return f(e,wa(t),n);if(t.$$typeof===S)return f(e,Ki(e,t),n);Ea(e,t)}return null}function p(e,t,n,r){var i=t===null?null:t.key;if(typeof n==`string`&&n!==``||typeof n==`number`||typeof n==`bigint`)return i===null?c(e,t,``+n,r):null;if(typeof n==`object`&&n){switch(n.$$typeof){case h:return n.key===i?l(e,t,n,r):null;case g:return n.key===i?u(e,t,n,r):null;case D:return n=va(n),p(e,t,n,r)}if(P(n)||j(n))return i===null?d(e,t,n,r,null):null;if(typeof n.then==`function`)return p(e,t,wa(n),r);if(n.$$typeof===S)return p(e,t,Ki(e,n),r);Ea(e,n)}return null}function m(e,t,n,r,i){if(typeof r==`string`&&r!==``||typeof r==`number`||typeof r==`bigint`)return e=e.get(n)||null,c(t,e,``+r,i);if(typeof r==`object`&&r){switch(r.$$typeof){case h:return e=e.get(r.key===null?n:r.key)||null,l(t,e,r,i);case g:return e=e.get(r.key===null?n:r.key)||null,u(t,e,r,i);case D:return r=va(r),m(e,t,n,r,i)}if(P(r)||j(r))return e=e.get(n)||null,d(t,e,r,i,null);if(typeof r.then==`function`)return m(e,t,n,wa(r),i);if(r.$$typeof===S)return m(e,t,n,Ki(t,r),i);Ea(t,r)}return null}function v(i,a,s,c){for(var l=null,u=null,d=a,h=a=0,g=null;d!==null&&h<s.length;h++){d.index>h?(g=d,d=null):g=d.sibling;var _=p(i,d,s[h],c);if(_===null){d===null&&(d=g);break}e&&d&&_.alternate===null&&t(i,d),a=o(_,a,h),u===null?l=_:u.sibling=_,u=_,d=g}if(h===s.length)return n(i,d),J&&yi(i,h),l;if(d===null){for(;h<s.length;h++)d=f(i,s[h],c),d!==null&&(a=o(d,a,h),u===null?l=d:u.sibling=d,u=d);return J&&yi(i,h),l}for(d=r(d);h<s.length;h++)g=m(d,i,h,s[h],c),g!==null&&(e&&g.alternate!==null&&d.delete(g.key===null?h:g.key),a=o(g,a,h),u===null?l=g:u.sibling=g,u=g);return e&&d.forEach(function(e){return t(i,e)}),J&&yi(i,h),l}function y(i,s,c,l){if(c==null)throw Error(a(151));for(var u=null,d=null,h=s,g=s=0,_=null,v=c.next();h!==null&&!v.done;g++,v=c.next()){h.index>g?(_=h,h=null):_=h.sibling;var y=p(i,h,v.value,l);if(y===null){h===null&&(h=_);break}e&&h&&y.alternate===null&&t(i,h),s=o(y,s,g),d===null?u=y:d.sibling=y,d=y,h=_}if(v.done)return n(i,h),J&&yi(i,g),u;if(h===null){for(;!v.done;g++,v=c.next())v=f(i,v.value,l),v!==null&&(s=o(v,s,g),d===null?u=v:d.sibling=v,d=v);return J&&yi(i,g),u}for(h=r(h);!v.done;g++,v=c.next())v=m(h,i,g,v.value,l),v!==null&&(e&&v.alternate!==null&&h.delete(v.key===null?g:v.key),s=o(v,s,g),d===null?u=v:d.sibling=v,d=v);return e&&h.forEach(function(e){return t(i,e)}),J&&yi(i,g),u}function b(e,r,o,c){if(typeof o==`object`&&o&&o.type===_&&o.key===null&&(o=o.props.children),typeof o==`object`&&o){switch(o.$$typeof){case h:a:{for(var l=o.key;r!==null;){if(r.key===l){if(l=o.type,l===_){if(r.tag===7){n(e,r.sibling),c=i(r,o.props.children),c.return=e,e=c;break a}}else if(r.elementType===l||typeof l==`object`&&l&&l.$$typeof===D&&va(l)===r.type){n(e,r.sibling),c=i(r,o.props),Ta(c,o),c.return=e,e=c;break a}n(e,r);break}else t(e,r);r=r.sibling}o.type===_?(c=ii(o.props.children,e.mode,c,o.key),c.return=e,e=c):(c=ri(o.type,o.key,o.props,null,e.mode,c),Ta(c,o),c.return=e,e=c)}return s(e);case g:a:{for(l=o.key;r!==null;){if(r.key===l)if(r.tag===4&&r.stateNode.containerInfo===o.containerInfo&&r.stateNode.implementation===o.implementation){n(e,r.sibling),c=i(r,o.children||[]),c.return=e,e=c;break a}else{n(e,r);break}else t(e,r);r=r.sibling}c=si(o,e.mode,c),c.return=e,e=c}return s(e);case D:return o=va(o),b(e,r,o,c)}if(P(o))return v(e,r,o,c);if(j(o)){if(l=j(o),typeof l!=`function`)throw Error(a(150));return o=l.call(o),y(e,r,o,c)}if(typeof o.then==`function`)return b(e,r,wa(o),c);if(o.$$typeof===S)return b(e,r,Ki(e,o),c);Ea(e,o)}return typeof o==`string`&&o!==``||typeof o==`number`||typeof o==`bigint`?(o=``+o,r!==null&&r.tag===6?(n(e,r.sibling),c=i(r,o),c.return=e,e=c):(n(e,r),c=ai(o,e.mode,c),c.return=e,e=c),s(e)):n(e,r)}return function(e,t,n,r){try{Ca=0;var i=b(e,t,n,r);return Sa=null,i}catch(t){if(t===fa||t===ma)throw t;var a=$r(29,t,null,e.mode);return a.lanes=r,a.return=e,a}}}var Oa=Da(!0),ka=Da(!1),Aa=!1;function ja(e){e.updateQueue={baseState:e.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,lanes:0,hiddenCallbacks:null},callbacks:null}}function Ma(e,t){e=e.updateQueue,t.updateQueue===e&&(t.updateQueue={baseState:e.baseState,firstBaseUpdate:e.firstBaseUpdate,lastBaseUpdate:e.lastBaseUpdate,shared:e.shared,callbacks:null})}function Na(e){return{lane:e,tag:0,payload:null,callback:null,next:null}}function Pa(e,t,n){var r=e.updateQueue;if(r===null)return null;if(r=r.shared,Nl&2){var i=r.pending;return i===null?t.next=t:(t.next=i.next,i.next=t),r.pending=t,t=Xr(e),Yr(e,null,n),t}return Kr(e,r,t,n),Xr(e)}function Fa(e,t,n){if(t=t.updateQueue,t!==null&&(t=t.shared,n&4194048)){var r=t.lanes;r&=e.pendingLanes,n|=r,t.lanes=n,Ke(e,n)}}function Ia(e,t){var n=e.updateQueue,r=e.alternate;if(r!==null&&(r=r.updateQueue,n===r)){var i=null,a=null;if(n=n.firstBaseUpdate,n!==null){do{var o={lane:n.lane,tag:n.tag,payload:n.payload,callback:null,next:null};a===null?i=a=o:a=a.next=o,n=n.next}while(n!==null);a===null?i=a=t:a=a.next=t}else i=a=t;n={baseState:r.baseState,firstBaseUpdate:i,lastBaseUpdate:a,shared:r.shared,callbacks:r.callbacks},e.updateQueue=n;return}e=n.lastBaseUpdate,e===null?n.firstBaseUpdate=t:e.next=t,n.lastBaseUpdate=t}var La=!1;function Ra(){if(La){var e=ra;if(e!==null)throw e}}function za(e,t,n,r){La=!1;var i=e.updateQueue;Aa=!1;var a=i.firstBaseUpdate,o=i.lastBaseUpdate,s=i.shared.pending;if(s!==null){i.shared.pending=null;var c=s,l=c.next;c.next=null,o===null?a=l:o.next=l,o=c;var u=e.alternate;u!==null&&(u=u.updateQueue,s=u.lastBaseUpdate,s!==o&&(s===null?u.firstBaseUpdate=l:s.next=l,u.lastBaseUpdate=c))}if(a!==null){var d=i.baseState;o=0,u=l=c=null,s=a;do{var f=s.lane&-536870913,m=f!==s.lane;if(m?(Fl&f)===f:(r&f)===f){f!==0&&f===na&&(La=!0),u!==null&&(u=u.next={lane:0,tag:s.tag,payload:s.payload,callback:null,next:null});a:{var h=e,g=s;f=t;var _=n;switch(g.tag){case 1:if(h=g.payload,typeof h==`function`){d=h.call(_,d,f);break a}d=h;break a;case 3:h.flags=h.flags&-65537|128;case 0:if(h=g.payload,f=typeof h==`function`?h.call(_,d,f):h,f==null)break a;d=p({},d,f);break a;case 2:Aa=!0}}f=s.callback,f!==null&&(e.flags|=64,m&&(e.flags|=8192),m=i.callbacks,m===null?i.callbacks=[f]:m.push(f))}else m={lane:f,tag:s.tag,payload:s.payload,callback:s.callback,next:null},u===null?(l=u=m,c=d):u=u.next=m,o|=f;if(s=s.next,s===null){if(s=i.shared.pending,s===null)break;m=s,s=m.next,m.next=null,i.lastBaseUpdate=m,i.shared.pending=null}}while(1);u===null&&(c=d),i.baseState=c,i.firstBaseUpdate=l,i.lastBaseUpdate=u,a===null&&(i.shared.lanes=0),Ul|=o,e.lanes=o,e.memoizedState=d}}function Ba(e,t){if(typeof e!=`function`)throw Error(a(191,e));e.call(t)}function Va(e,t){var n=e.callbacks;if(n!==null)for(e.callbacks=null,e=0;e<n.length;e++)Ba(n[e],t)}var Ha=L(null),Ua=L(0);function Wa(e,t){e=Vl,z(Ua,e),z(Ha,t),Vl=e|t.baseLanes}function Ga(){z(Ua,Vl),z(Ha,Ha.current)}function Ka(){Vl=Ua.current,R(Ha),R(Ua)}var qa=L(null),Ja=null;function Ya(e){var t=e.alternate;z(eo,eo.current&1),z(qa,e),Ja===null&&(t===null||Ha.current!==null||t.memoizedState!==null)&&(Ja=e)}function Xa(e){z(eo,eo.current),z(qa,e),Ja===null&&(Ja=e)}function Za(e){e.tag===22?(z(eo,eo.current),z(qa,e),Ja===null&&(Ja=e)):Qa(e)}function Qa(){z(eo,eo.current),z(qa,qa.current)}function $a(e){R(qa),Ja===e&&(Ja=null),R(eo)}var eo=L(0);function to(e){for(var t=e;t!==null;){if(t.tag===13){var n=t.memoizedState;if(n!==null&&(n=n.dehydrated,n===null||af(n)||of(n)))return t}else if(t.tag===19&&(t.memoizedProps.revealOrder===`forwards`||t.memoizedProps.revealOrder===`backwards`||t.memoizedProps.revealOrder===`unstable_legacy-backwards`||t.memoizedProps.revealOrder===`together`)){if(t.flags&128)return t}else if(t.child!==null){t.child.return=t,t=t.child;continue}if(t===e)break;for(;t.sibling===null;){if(t.return===null||t.return===e)return null;t=t.return}t.sibling.return=t.return,t=t.sibling}return null}var no=0,X=null,ro=null,io=null,ao=!1,oo=!1,so=!1,co=0,lo=0,uo=null,fo=0;function po(){throw Error(a(321))}function mo(e,t){if(t===null)return!1;for(var n=0;n<t.length&&n<e.length;n++)if(!pr(e[n],t[n]))return!1;return!0}function ho(e,t,n,r,i,a){return no=a,X=t,t.memoizedState=null,t.updateQueue=null,t.lanes=0,F.H=e===null||e.memoizedState===null?js:Ms,so=!1,a=n(r,i),so=!1,oo&&(a=_o(t,n,r,i)),go(e),a}function go(e){F.H=As;var t=ro!==null&&ro.next!==null;if(no=0,io=ro=X=null,ao=!1,lo=0,uo=null,t)throw Error(a(300));e===null||Ys||(e=e.dependencies,e!==null&&Ui(e)&&(Ys=!0))}function _o(e,t,n,r){X=e;var i=0;do{if(oo&&(uo=null),lo=0,oo=!1,25<=i)throw Error(a(301));if(i+=1,io=ro=null,e.updateQueue!=null){var o=e.updateQueue;o.lastEffect=null,o.events=null,o.stores=null,o.memoCache!=null&&(o.memoCache.index=0)}F.H=Ns,o=t(n,r)}while(oo);return o}function vo(){var e=F.H,t=e.useState()[0];return t=typeof t.then==`function`?To(t):t,e=e.useState()[0],(ro===null?null:ro.memoizedState)!==e&&(X.flags|=1024),t}function yo(){var e=co!==0;return co=0,e}function bo(e,t,n){t.updateQueue=e.updateQueue,t.flags&=-2053,e.lanes&=~n}function xo(e){if(ao){for(e=e.memoizedState;e!==null;){var t=e.queue;t!==null&&(t.pending=null),e=e.next}ao=!1}no=0,io=ro=X=null,oo=!1,lo=co=0,uo=null}function So(){var e={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return io===null?X.memoizedState=io=e:io=io.next=e,io}function Co(){if(ro===null){var e=X.alternate;e=e===null?null:e.memoizedState}else e=ro.next;var t=io===null?X.memoizedState:io.next;if(t!==null)io=t,ro=e;else{if(e===null)throw X.alternate===null?Error(a(467)):Error(a(310));ro=e,e={memoizedState:ro.memoizedState,baseState:ro.baseState,baseQueue:ro.baseQueue,queue:ro.queue,next:null},io===null?X.memoizedState=io=e:io=io.next=e}return io}function wo(){return{lastEffect:null,events:null,stores:null,memoCache:null}}function To(e){var t=lo;return lo+=1,uo===null&&(uo=[]),e=_a(uo,e,t),t=X,(io===null?t.memoizedState:io.next)===null&&(t=t.alternate,F.H=t===null||t.memoizedState===null?js:Ms),e}function Eo(e){if(typeof e==`object`&&e){if(typeof e.then==`function`)return To(e);if(e.$$typeof===S)return Gi(e)}throw Error(a(438,String(e)))}function Do(e){var t=null,n=X.updateQueue;if(n!==null&&(t=n.memoCache),t==null){var r=X.alternate;r!==null&&(r=r.updateQueue,r!==null&&(r=r.memoCache,r!=null&&(t={data:r.data.map(function(e){return e.slice()}),index:0})))}if(t??={data:[],index:0},n===null&&(n=wo(),X.updateQueue=n),n.memoCache=t,n=t.data[t.index],n===void 0)for(n=t.data[t.index]=Array(e),r=0;r<e;r++)n[r]=k;return t.index++,n}function Oo(e,t){return typeof t==`function`?t(e):t}function ko(e){return Ao(Co(),ro,e)}function Ao(e,t,n){var r=e.queue;if(r===null)throw Error(a(311));r.lastRenderedReducer=n;var i=e.baseQueue,o=r.pending;if(o!==null){if(i!==null){var s=i.next;i.next=o.next,o.next=s}t.baseQueue=i=o,r.pending=null}if(o=e.baseState,i===null)e.memoizedState=o;else{t=i.next;var c=s=null,l=null,u=t,d=!1;do{var f=u.lane&-536870913;if(f===u.lane?(no&f)===f:(Fl&f)===f){var p=u.revertLane;if(p===0)l!==null&&(l=l.next={lane:0,revertLane:0,gesture:null,action:u.action,hasEagerState:u.hasEagerState,eagerState:u.eagerState,next:null}),f===na&&(d=!0);else if((no&p)===p){u=u.next,p===na&&(d=!0);continue}else f={lane:0,revertLane:u.revertLane,gesture:null,action:u.action,hasEagerState:u.hasEagerState,eagerState:u.eagerState,next:null},l===null?(c=l=f,s=o):l=l.next=f,X.lanes|=p,Ul|=p;f=u.action,so&&n(o,f),o=u.hasEagerState?u.eagerState:n(o,f)}else p={lane:f,revertLane:u.revertLane,gesture:u.gesture,action:u.action,hasEagerState:u.hasEagerState,eagerState:u.eagerState,next:null},l===null?(c=l=p,s=o):l=l.next=p,X.lanes|=f,Ul|=f;u=u.next}while(u!==null&&u!==t);if(l===null?s=o:l.next=c,!pr(o,e.memoizedState)&&(Ys=!0,d&&(n=ra,n!==null)))throw n;e.memoizedState=o,e.baseState=s,e.baseQueue=l,r.lastRenderedState=o}return i===null&&(r.lanes=0),[e.memoizedState,r.dispatch]}function jo(e){var t=Co(),n=t.queue;if(n===null)throw Error(a(311));n.lastRenderedReducer=e;var r=n.dispatch,i=n.pending,o=t.memoizedState;if(i!==null){n.pending=null;var s=i=i.next;do o=e(o,s.action),s=s.next;while(s!==i);pr(o,t.memoizedState)||(Ys=!0),t.memoizedState=o,t.baseQueue===null&&(t.baseState=o),n.lastRenderedState=o}return[o,r]}function Mo(e,t,n){var r=X,i=Co(),o=J;if(o){if(n===void 0)throw Error(a(407));n=n()}else n=t();var s=!pr((ro||i).memoizedState,n);if(s&&(i.memoizedState=n,Ys=!0),i=i.queue,rs(Fo.bind(null,r,i,e),[e]),i.getSnapshot!==t||s||io!==null&&io.memoizedState.tag&1){if(r.flags|=2048,Qo(9,{destroy:void 0},Po.bind(null,r,i,n,t),null),Pl===null)throw Error(a(349));o||no&127||No(r,t,n)}return n}function No(e,t,n){e.flags|=16384,e={getSnapshot:t,value:n},t=X.updateQueue,t===null?(t=wo(),X.updateQueue=t,t.stores=[e]):(n=t.stores,n===null?t.stores=[e]:n.push(e))}function Po(e,t,n,r){t.value=n,t.getSnapshot=r,Io(t)&&Lo(e)}function Fo(e,t,n){return n(function(){Io(t)&&Lo(e)})}function Io(e){var t=e.getSnapshot;e=e.value;try{var n=t();return!pr(e,n)}catch{return!0}}function Lo(e){var t=Jr(e,2);t!==null&&pu(t,e,2)}function Ro(e){var t=So();if(typeof e==`function`){var n=e;if(e=n(),so){Ae(!0);try{n()}finally{Ae(!1)}}}return t.memoizedState=t.baseState=e,t.queue={pending:null,lanes:0,dispatch:null,lastRenderedReducer:Oo,lastRenderedState:e},t}function zo(e,t,n,r){return e.baseState=n,Ao(e,ro,typeof r==`function`?r:Oo)}function Bo(e,t,n,r,i){if(Ds(e))throw Error(a(485));if(e=t.action,e!==null){var o={payload:i,action:e,next:null,isTransition:!0,status:`pending`,value:null,reason:null,listeners:[],then:function(e){o.listeners.push(e)}};F.T===null?o.isTransition=!1:n(!0),r(o),n=t.pending,n===null?(o.next=t.pending=o,Vo(t,o)):(o.next=n.next,t.pending=n.next=o)}}function Vo(e,t){var n=t.action,r=t.payload,i=e.state;if(t.isTransition){var a=F.T,o={};F.T=o;try{var s=n(i,r),c=F.S;c!==null&&c(o,s),Ho(e,t,s)}catch(n){Wo(e,t,n)}finally{a!==null&&o.types!==null&&(a.types=o.types),F.T=a}}else try{a=n(i,r),Ho(e,t,a)}catch(n){Wo(e,t,n)}}function Ho(e,t,n){typeof n==`object`&&n&&typeof n.then==`function`?n.then(function(n){Uo(e,t,n)},function(n){return Wo(e,t,n)}):Uo(e,t,n)}function Uo(e,t,n){t.status=`fulfilled`,t.value=n,Go(t),e.state=n,t=e.pending,t!==null&&(n=t.next,n===t?e.pending=null:(n=n.next,t.next=n,Vo(e,n)))}function Wo(e,t,n){var r=e.pending;if(e.pending=null,r!==null){r=r.next;do t.status=`rejected`,t.reason=n,Go(t),t=t.next;while(t!==r)}e.action=null}function Go(e){e=e.listeners;for(var t=0;t<e.length;t++)(0,e[t])()}function Ko(e,t){return t}function qo(e,t){if(J){var n=Pl.formState;if(n!==null){a:{var r=X;if(J){if(Ti){b:{for(var i=Ti,a=Ei;i.nodeType!==8;){if(!a){i=null;break b}if(i=cf(i.nextSibling),i===null){i=null;break b}}a=i.data,i=a===`F!`||a===`F`?i:null}if(i){Ti=cf(i.nextSibling),r=i.data===`F!`;break a}}Oi(r)}r=!1}r&&(t=n[0])}}return n=So(),n.memoizedState=n.baseState=t,r={pending:null,lanes:0,dispatch:null,lastRenderedReducer:Ko,lastRenderedState:t},n.queue=r,n=Z.bind(null,X,r),r.dispatch=n,r=Ro(!1),a=Es.bind(null,X,!1,r.queue),r=So(),i={state:t,dispatch:null,action:e,pending:null},r.queue=i,n=Bo.bind(null,X,i,a,n),i.dispatch=n,r.memoizedState=e,[t,n,!1]}function Jo(e){return Yo(Co(),ro,e)}function Yo(e,t,n){if(t=Ao(e,t,Ko)[0],e=ko(Oo)[0],typeof t==`object`&&t&&typeof t.then==`function`)try{var r=To(t)}catch(e){throw e===fa?ma:e}else r=t;t=Co();var i=t.queue,a=i.dispatch;return n!==t.memoizedState&&(X.flags|=2048,Qo(9,{destroy:void 0},Xo.bind(null,i,n),null)),[r,a,e]}function Xo(e,t){e.action=t}function Zo(e){var t=Co(),n=ro;if(n!==null)return Yo(t,n,e);Co(),t=t.memoizedState,n=Co();var r=n.queue.dispatch;return n.memoizedState=e,[t,r,!1]}function Qo(e,t,n,r){return e={tag:e,create:n,deps:r,inst:t,next:null},t=X.updateQueue,t===null&&(t=wo(),X.updateQueue=t),n=t.lastEffect,n===null?t.lastEffect=e.next=e:(r=n.next,n.next=e,e.next=r,t.lastEffect=e),e}function $o(){return Co().memoizedState}function es(e,t,n,r){var i=So();X.flags|=e,i.memoizedState=Qo(1|t,{destroy:void 0},n,r===void 0?null:r)}function ts(e,t,n,r){var i=Co();r=r===void 0?null:r;var a=i.memoizedState.inst;ro!==null&&r!==null&&mo(r,ro.memoizedState.deps)?i.memoizedState=Qo(t,a,n,r):(X.flags|=e,i.memoizedState=Qo(1|t,a,n,r))}function ns(e,t){es(8390656,8,e,t)}function rs(e,t){ts(2048,8,e,t)}function is(e){X.flags|=4;var t=X.updateQueue;if(t===null)t=wo(),X.updateQueue=t,t.events=[e];else{var n=t.events;n===null?t.events=[e]:n.push(e)}}function as(e){var t=Co().memoizedState;return is({ref:t,nextImpl:e}),function(){if(Nl&2)throw Error(a(440));return t.impl.apply(void 0,arguments)}}function os(e,t){return ts(4,2,e,t)}function ss(e,t){return ts(4,4,e,t)}function cs(e,t){if(typeof t==`function`){e=e();var n=t(e);return function(){typeof n==`function`?n():t(null)}}if(t!=null)return e=e(),t.current=e,function(){t.current=null}}function ls(e,t,n){n=n==null?null:n.concat([e]),ts(4,4,cs.bind(null,t,e),n)}function us(){}function ds(e,t){var n=Co();t=t===void 0?null:t;var r=n.memoizedState;return t!==null&&mo(t,r[1])?r[0]:(n.memoizedState=[e,t],e)}function fs(e,t){var n=Co();t=t===void 0?null:t;var r=n.memoizedState;if(t!==null&&mo(t,r[1]))return r[0];if(r=e(),so){Ae(!0);try{e()}finally{Ae(!1)}}return n.memoizedState=[r,t],r}function ps(e,t,n){return n===void 0||no&1073741824&&!(Fl&261930)?e.memoizedState=t:(e.memoizedState=n,e=fu(),X.lanes|=e,Ul|=e,n)}function ms(e,t,n,r){return pr(n,t)?n:Ha.current===null?!(no&42)||no&1073741824&&!(Fl&261930)?(Ys=!0,e.memoizedState=n):(e=fu(),X.lanes|=e,Ul|=e,t):(e=ps(e,n,r),pr(e,t)||(Ys=!0),e)}function hs(e,t,n,r,i){var a=I.p;I.p=a!==0&&8>a?a:8;var o=F.T,s={};F.T=s,Es(e,!1,t,n);try{var c=i(),l=F.S;l!==null&&l(s,c),typeof c==`object`&&c&&typeof c.then==`function`?Ts(e,t,oa(c,r),du(e)):Ts(e,t,r,du(e))}catch(n){Ts(e,t,{then:function(){},status:`rejected`,reason:n},du())}finally{I.p=a,o!==null&&s.types!==null&&(o.types=s.types),F.T=o}}function gs(){}function _s(e,t,n,r){if(e.tag!==5)throw Error(a(476));var i=vs(e).queue;hs(e,i,t,ee,n===null?gs:function(){return ys(e),n(r)})}function vs(e){var t=e.memoizedState;if(t!==null)return t;t={memoizedState:ee,baseState:ee,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:Oo,lastRenderedState:ee},next:null};var n={};return t.next={memoizedState:n,baseState:n,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:Oo,lastRenderedState:n},next:null},e.memoizedState=t,e=e.alternate,e!==null&&(e.memoizedState=t),t}function ys(e){var t=vs(e);t.next===null&&(t=e.alternate.memoizedState),Ts(e,t.next.queue,{},du())}function bs(){return Gi(Qf)}function xs(){return Co().memoizedState}function Ss(){return Co().memoizedState}function Cs(e){for(var t=e.return;t!==null;){switch(t.tag){case 24:case 3:var n=du();e=Na(n);var r=Pa(t,e,n);r!==null&&(pu(r,t,n),Fa(r,t,n)),t={cache:Qi()},e.payload=t;return}t=t.return}}function ws(e,t,n){var r=du();n={lane:r,revertLane:0,gesture:null,action:n,hasEagerState:!1,eagerState:null,next:null},Ds(e)?Os(t,n):(n=qr(e,t,n,r),n!==null&&(pu(n,e,r),ks(n,t,r)))}function Z(e,t,n){Ts(e,t,n,du())}function Ts(e,t,n,r){var i={lane:r,revertLane:0,gesture:null,action:n,hasEagerState:!1,eagerState:null,next:null};if(Ds(e))Os(t,i);else{var a=e.alternate;if(e.lanes===0&&(a===null||a.lanes===0)&&(a=t.lastRenderedReducer,a!==null))try{var o=t.lastRenderedState,s=a(o,n);if(i.hasEagerState=!0,i.eagerState=s,pr(s,o))return Kr(e,t,i,0),Pl===null&&Gr(),!1}catch{}if(n=qr(e,t,i,r),n!==null)return pu(n,e,r),ks(n,t,r),!0}return!1}function Es(e,t,n,r){if(r={lane:2,revertLane:ud(),gesture:null,action:r,hasEagerState:!1,eagerState:null,next:null},Ds(e)){if(t)throw Error(a(479))}else t=qr(e,n,r,2),t!==null&&pu(t,e,2)}function Ds(e){var t=e.alternate;return e===X||t!==null&&t===X}function Os(e,t){oo=ao=!0;var n=e.pending;n===null?t.next=t:(t.next=n.next,n.next=t),e.pending=t}function ks(e,t,n){if(n&4194048){var r=t.lanes;r&=e.pendingLanes,n|=r,t.lanes=n,Ke(e,n)}}var As={readContext:Gi,use:Eo,useCallback:po,useContext:po,useEffect:po,useImperativeHandle:po,useLayoutEffect:po,useInsertionEffect:po,useMemo:po,useReducer:po,useRef:po,useState:po,useDebugValue:po,useDeferredValue:po,useTransition:po,useSyncExternalStore:po,useId:po,useHostTransitionStatus:po,useFormState:po,useActionState:po,useOptimistic:po,useMemoCache:po,useCacheRefresh:po};As.useEffectEvent=po;var js={readContext:Gi,use:Eo,useCallback:function(e,t){return So().memoizedState=[e,t===void 0?null:t],e},useContext:Gi,useEffect:ns,useImperativeHandle:function(e,t,n){n=n==null?null:n.concat([e]),es(4194308,4,cs.bind(null,t,e),n)},useLayoutEffect:function(e,t){return es(4194308,4,e,t)},useInsertionEffect:function(e,t){es(4,2,e,t)},useMemo:function(e,t){var n=So();t=t===void 0?null:t;var r=e();if(so){Ae(!0);try{e()}finally{Ae(!1)}}return n.memoizedState=[r,t],r},useReducer:function(e,t,n){var r=So();if(n!==void 0){var i=n(t);if(so){Ae(!0);try{n(t)}finally{Ae(!1)}}}else i=t;return r.memoizedState=r.baseState=i,e={pending:null,lanes:0,dispatch:null,lastRenderedReducer:e,lastRenderedState:i},r.queue=e,e=e.dispatch=ws.bind(null,X,e),[r.memoizedState,e]},useRef:function(e){var t=So();return e={current:e},t.memoizedState=e},useState:function(e){e=Ro(e);var t=e.queue,n=Z.bind(null,X,t);return t.dispatch=n,[e.memoizedState,n]},useDebugValue:us,useDeferredValue:function(e,t){return ps(So(),e,t)},useTransition:function(){var e=Ro(!1);return e=hs.bind(null,X,e.queue,!0,!1),So().memoizedState=e,[!1,e]},useSyncExternalStore:function(e,t,n){var r=X,i=So();if(J){if(n===void 0)throw Error(a(407));n=n()}else{if(n=t(),Pl===null)throw Error(a(349));Fl&127||No(r,t,n)}i.memoizedState=n;var o={value:n,getSnapshot:t};return i.queue=o,ns(Fo.bind(null,r,o,e),[e]),r.flags|=2048,Qo(9,{destroy:void 0},Po.bind(null,r,o,n,t),null),n},useId:function(){var e=So(),t=Pl.identifierPrefix;if(J){var n=vi,r=_i;n=(r&~(1<<32-je(r)-1)).toString(32)+n,t=`_`+t+`R_`+n,n=co++,0<n&&(t+=`H`+n.toString(32)),t+=`_`}else n=fo++,t=`_`+t+`r_`+n.toString(32)+`_`;return e.memoizedState=t},useHostTransitionStatus:bs,useFormState:qo,useActionState:qo,useOptimistic:function(e){var t=So();t.memoizedState=t.baseState=e;var n={pending:null,lanes:0,dispatch:null,lastRenderedReducer:null,lastRenderedState:null};return t.queue=n,t=Es.bind(null,X,!0,n),n.dispatch=t,[e,t]},useMemoCache:Do,useCacheRefresh:function(){return So().memoizedState=Cs.bind(null,X)},useEffectEvent:function(e){var t=So(),n={impl:e};return t.memoizedState=n,function(){if(Nl&2)throw Error(a(440));return n.impl.apply(void 0,arguments)}}},Ms={readContext:Gi,use:Eo,useCallback:ds,useContext:Gi,useEffect:rs,useImperativeHandle:ls,useInsertionEffect:os,useLayoutEffect:ss,useMemo:fs,useReducer:ko,useRef:$o,useState:function(){return ko(Oo)},useDebugValue:us,useDeferredValue:function(e,t){return ms(Co(),ro.memoizedState,e,t)},useTransition:function(){var e=ko(Oo)[0],t=Co().memoizedState;return[typeof e==`boolean`?e:To(e),t]},useSyncExternalStore:Mo,useId:xs,useHostTransitionStatus:bs,useFormState:Jo,useActionState:Jo,useOptimistic:function(e,t){return zo(Co(),ro,e,t)},useMemoCache:Do,useCacheRefresh:Ss};Ms.useEffectEvent=as;var Ns={readContext:Gi,use:Eo,useCallback:ds,useContext:Gi,useEffect:rs,useImperativeHandle:ls,useInsertionEffect:os,useLayoutEffect:ss,useMemo:fs,useReducer:jo,useRef:$o,useState:function(){return jo(Oo)},useDebugValue:us,useDeferredValue:function(e,t){var n=Co();return ro===null?ps(n,e,t):ms(n,ro.memoizedState,e,t)},useTransition:function(){var e=jo(Oo)[0],t=Co().memoizedState;return[typeof e==`boolean`?e:To(e),t]},useSyncExternalStore:Mo,useId:xs,useHostTransitionStatus:bs,useFormState:Zo,useActionState:Zo,useOptimistic:function(e,t){var n=Co();return ro===null?(n.baseState=e,[e,n.queue.dispatch]):zo(n,ro,e,t)},useMemoCache:Do,useCacheRefresh:Ss};Ns.useEffectEvent=as;function Ps(e,t,n,r){t=e.memoizedState,n=n(r,t),n=n==null?t:p({},t,n),e.memoizedState=n,e.lanes===0&&(e.updateQueue.baseState=n)}var Fs={enqueueSetState:function(e,t,n){e=e._reactInternals;var r=du(),i=Na(r);i.payload=t,n!=null&&(i.callback=n),t=Pa(e,i,r),t!==null&&(pu(t,e,r),Fa(t,e,r))},enqueueReplaceState:function(e,t,n){e=e._reactInternals;var r=du(),i=Na(r);i.tag=1,i.payload=t,n!=null&&(i.callback=n),t=Pa(e,i,r),t!==null&&(pu(t,e,r),Fa(t,e,r))},enqueueForceUpdate:function(e,t){e=e._reactInternals;var n=du(),r=Na(n);r.tag=2,t!=null&&(r.callback=t),t=Pa(e,r,n),t!==null&&(pu(t,e,n),Fa(t,e,n))}};function Is(e,t,n,r,i,a,o){return e=e.stateNode,typeof e.shouldComponentUpdate==`function`?e.shouldComponentUpdate(r,a,o):t.prototype&&t.prototype.isPureReactComponent?!mr(n,r)||!mr(i,a):!0}function Ls(e,t,n,r){e=t.state,typeof t.componentWillReceiveProps==`function`&&t.componentWillReceiveProps(n,r),typeof t.UNSAFE_componentWillReceiveProps==`function`&&t.UNSAFE_componentWillReceiveProps(n,r),t.state!==e&&Fs.enqueueReplaceState(t,t.state,null)}function Rs(e,t){var n=t;if(`ref`in t)for(var r in n={},t)r!==`ref`&&(n[r]=t[r]);if(e=e.defaultProps)for(var i in n===t&&(n=p({},n)),e)n[i]===void 0&&(n[i]=e[i]);return n}function zs(e){Vr(e)}function Bs(e){console.error(e)}function Vs(e){Vr(e)}function Hs(e,t){try{var n=e.onUncaughtError;n(t.value,{componentStack:t.stack})}catch(e){setTimeout(function(){throw e})}}function Us(e,t,n){try{var r=e.onCaughtError;r(n.value,{componentStack:n.stack,errorBoundary:t.tag===1?t.stateNode:null})}catch(e){setTimeout(function(){throw e})}}function Ws(e,t,n){return n=Na(n),n.tag=3,n.payload={element:null},n.callback=function(){Hs(e,t)},n}function Gs(e){return e=Na(e),e.tag=3,e}function Ks(e,t,n,r){var i=n.type.getDerivedStateFromError;if(typeof i==`function`){var a=r.value;e.payload=function(){return i(a)},e.callback=function(){Us(t,n,r)}}var o=n.stateNode;o!==null&&typeof o.componentDidCatch==`function`&&(e.callback=function(){Us(t,n,r),typeof i!=`function`&&(tu===null?tu=new Set([this]):tu.add(this));var e=r.stack;this.componentDidCatch(r.value,{componentStack:e===null?``:e})})}function qs(e,t,n,r,i){if(n.flags|=32768,typeof r==`object`&&r&&typeof r.then==`function`){if(t=n.alternate,t!==null&&Hi(t,n,i,!0),n=qa.current,n!==null){switch(n.tag){case 31:case 13:return Ja===null?Tu():n.alternate===null&&Hl===0&&(Hl=3),n.flags&=-257,n.flags|=65536,n.lanes=i,r===ha?n.flags|=16384:(t=n.updateQueue,t===null?n.updateQueue=new Set([r]):t.add(r),Wu(e,r,i)),!1;case 22:return n.flags|=65536,r===ha?n.flags|=16384:(t=n.updateQueue,t===null?(t={transitions:null,markerInstances:null,retryQueue:new Set([r])},n.updateQueue=t):(n=t.retryQueue,n===null?t.retryQueue=new Set([r]):n.add(r)),Wu(e,r,i)),!1}throw Error(a(435,n.tag))}return Wu(e,r,i),Tu(),!1}if(J)return t=qa.current,t===null?(r!==Di&&(t=Error(a(423),{cause:r}),Pi(li(t,n))),e=e.current.alternate,e.flags|=65536,i&=-i,e.lanes|=i,r=li(r,n),i=Ws(e.stateNode,r,i),Ia(e,i),Hl!==4&&(Hl=2)):(!(t.flags&65536)&&(t.flags|=256),t.flags|=65536,t.lanes=i,r!==Di&&(e=Error(a(422),{cause:r}),Pi(li(e,n)))),!1;var o=Error(a(520),{cause:r});if(o=li(o,n),Jl===null?Jl=[o]:Jl.push(o),Hl!==4&&(Hl=2),t===null)return!0;r=li(r,n),n=t;do{switch(n.tag){case 3:return n.flags|=65536,e=i&-i,n.lanes|=e,e=Ws(n.stateNode,r,e),Ia(n,e),!1;case 1:if(t=n.type,o=n.stateNode,!(n.flags&128)&&(typeof t.getDerivedStateFromError==`function`||o!==null&&typeof o.componentDidCatch==`function`&&(tu===null||!tu.has(o))))return n.flags|=65536,i&=-i,n.lanes|=i,i=Gs(i),Ks(i,e,n,r),Ia(n,i),!1}n=n.return}while(n!==null);return!1}var Js=Error(a(461)),Ys=!1;function Xs(e,t,n,r){t.child=e===null?ka(t,null,n,r):Oa(t,e.child,n,r)}function Zs(e,t,n,r,i){n=n.render;var a=t.ref;if(`ref`in r){var o={};for(var s in r)s!==`ref`&&(o[s]=r[s])}else o=r;return Wi(t),r=ho(e,t,n,o,a,i),s=yo(),e!==null&&!Ys?(bo(e,t,i),xc(e,t,i)):(J&&s&&xi(t),t.flags|=1,Xs(e,t,r,i),t.child)}function Qs(e,t,n,r,i){if(e===null){var a=n.type;return typeof a==`function`&&!ei(a)&&a.defaultProps===void 0&&n.compare===null?(t.tag=15,t.type=a,$s(e,t,a,r,i)):(e=ri(n.type,null,r,t,t.mode,i),e.ref=t.ref,e.return=t,t.child=e)}if(a=e.child,!Sc(e,i)){var o=a.memoizedProps;if(n=n.compare,n=n===null?mr:n,n(o,r)&&e.ref===t.ref)return xc(e,t,i)}return t.flags|=1,e=ti(a,r),e.ref=t.ref,e.return=t,t.child=e}function $s(e,t,n,r,i){if(e!==null){var a=e.memoizedProps;if(mr(a,r)&&e.ref===t.ref)if(Ys=!1,t.pendingProps=r=a,Sc(e,i))e.flags&131072&&(Ys=!0);else return t.lanes=e.lanes,xc(e,t,i)}return sc(e,t,n,r,i)}function ec(e,t,n,r){var i=r.children,a=e===null?null:e.memoizedState;if(e===null&&t.stateNode===null&&(t.stateNode={_visibility:1,_pendingMarkers:null,_retryCache:null,_transitions:null}),r.mode===`hidden`){if(t.flags&128){if(a=a===null?n:a.baseLanes|n,e!==null){for(r=t.child=e.child,i=0;r!==null;)i=i|r.lanes|r.childLanes,r=r.sibling;r=i&~a}else r=0,t.child=null;return nc(e,t,a,n,r)}if(n&536870912)t.memoizedState={baseLanes:0,cachePool:null},e!==null&&ua(t,a===null?null:a.cachePool),a===null?Ga():Wa(t,a),Za(t);else return r=t.lanes=536870912,nc(e,t,a===null?n:a.baseLanes|n,n,r)}else a===null?(e!==null&&ua(t,null),Ga(),Qa(t)):(ua(t,a.cachePool),Wa(t,a),Qa(t),t.memoizedState=null);return Xs(e,t,i,n),t.child}function tc(e,t){return e!==null&&e.tag===22||t.stateNode!==null||(t.stateNode={_visibility:1,_pendingMarkers:null,_retryCache:null,_transitions:null}),t.sibling}function nc(e,t,n,r,i){var a=la();return a=a===null?null:{parent:Zi._currentValue,pool:a},t.memoizedState={baseLanes:n,cachePool:a},e!==null&&ua(t,null),Ga(),Za(t),e!==null&&Hi(e,t,r,!0),t.childLanes=i,null}function rc(e,t){return t=gc({mode:t.mode,children:t.children},e.mode),t.ref=e.ref,e.child=t,t.return=e,t}function ic(e,t,n){return Oa(t,e.child,null,n),e=rc(t,t.pendingProps),e.flags|=2,$a(t),t.memoizedState=null,e}function ac(e,t,n){var r=t.pendingProps,i=(t.flags&128)!=0;if(t.flags&=-129,e===null){if(J){if(r.mode===`hidden`)return e=rc(t,r),t.lanes=536870912,tc(null,e);if(Xa(t),(e=Ti)?(e=rf(e,Ei),e=e!==null&&e.data===`&`?e:null,e!==null&&(t.memoizedState={dehydrated:e,treeContext:gi===null?null:{id:_i,overflow:vi},retryLane:536870912,hydrationErrors:null},n=oi(e),n.return=t,t.child=n,wi=t,Ti=null)):e=null,e===null)throw Oi(t);return t.lanes=536870912,null}return rc(t,r)}var o=e.memoizedState;if(o!==null){var s=o.dehydrated;if(Xa(t),i)if(t.flags&256)t.flags&=-257,t=ic(e,t,n);else if(t.memoizedState!==null)t.child=e.child,t.flags|=128,t=null;else throw Error(a(558));else if(Ys||Hi(e,t,n,!1),i=(n&e.childLanes)!==0,Ys||i){if(r=Pl,r!==null&&(s=qe(r,n),s!==0&&s!==o.retryLane))throw o.retryLane=s,Jr(e,s),pu(r,e,s),Js;Tu(),t=ic(e,t,n)}else e=o.treeContext,Ti=cf(s.nextSibling),wi=t,J=!0,Y=null,Ei=!1,e!==null&&Ci(t,e),t=rc(t,r),t.flags|=4096;return t}return e=ti(e.child,{mode:r.mode,children:r.children}),e.ref=t.ref,t.child=e,e.return=t,e}function oc(e,t){var n=t.ref;if(n===null)e!==null&&e.ref!==null&&(t.flags|=4194816);else{if(typeof n!=`function`&&typeof n!=`object`)throw Error(a(284));(e===null||e.ref!==n)&&(t.flags|=4194816)}}function sc(e,t,n,r,i){return Wi(t),n=ho(e,t,n,r,void 0,i),r=yo(),e!==null&&!Ys?(bo(e,t,i),xc(e,t,i)):(J&&r&&xi(t),t.flags|=1,Xs(e,t,n,i),t.child)}function cc(e,t,n,r,i,a){return Wi(t),t.updateQueue=null,n=_o(t,r,n,i),go(e),r=yo(),e!==null&&!Ys?(bo(e,t,a),xc(e,t,a)):(J&&r&&xi(t),t.flags|=1,Xs(e,t,n,a),t.child)}function lc(e,t,n,r,i){if(Wi(t),t.stateNode===null){var a=Zr,o=n.contextType;typeof o==`object`&&o&&(a=Gi(o)),a=new n(r,a),t.memoizedState=a.state!==null&&a.state!==void 0?a.state:null,a.updater=Fs,t.stateNode=a,a._reactInternals=t,a=t.stateNode,a.props=r,a.state=t.memoizedState,a.refs={},ja(t),o=n.contextType,a.context=typeof o==`object`&&o?Gi(o):Zr,a.state=t.memoizedState,o=n.getDerivedStateFromProps,typeof o==`function`&&(Ps(t,n,o,r),a.state=t.memoizedState),typeof n.getDerivedStateFromProps==`function`||typeof a.getSnapshotBeforeUpdate==`function`||typeof a.UNSAFE_componentWillMount!=`function`&&typeof a.componentWillMount!=`function`||(o=a.state,typeof a.componentWillMount==`function`&&a.componentWillMount(),typeof a.UNSAFE_componentWillMount==`function`&&a.UNSAFE_componentWillMount(),o!==a.state&&Fs.enqueueReplaceState(a,a.state,null),za(t,r,a,i),Ra(),a.state=t.memoizedState),typeof a.componentDidMount==`function`&&(t.flags|=4194308),r=!0}else if(e===null){a=t.stateNode;var s=t.memoizedProps,c=Rs(n,s);a.props=c;var l=a.context,u=n.contextType;o=Zr,typeof u==`object`&&u&&(o=Gi(u));var d=n.getDerivedStateFromProps;u=typeof d==`function`||typeof a.getSnapshotBeforeUpdate==`function`,s=t.pendingProps!==s,u||typeof a.UNSAFE_componentWillReceiveProps!=`function`&&typeof a.componentWillReceiveProps!=`function`||(s||l!==o)&&Ls(t,a,r,o),Aa=!1;var f=t.memoizedState;a.state=f,za(t,r,a,i),Ra(),l=t.memoizedState,s||f!==l||Aa?(typeof d==`function`&&(Ps(t,n,d,r),l=t.memoizedState),(c=Aa||Is(t,n,c,r,f,l,o))?(u||typeof a.UNSAFE_componentWillMount!=`function`&&typeof a.componentWillMount!=`function`||(typeof a.componentWillMount==`function`&&a.componentWillMount(),typeof a.UNSAFE_componentWillMount==`function`&&a.UNSAFE_componentWillMount()),typeof a.componentDidMount==`function`&&(t.flags|=4194308)):(typeof a.componentDidMount==`function`&&(t.flags|=4194308),t.memoizedProps=r,t.memoizedState=l),a.props=r,a.state=l,a.context=o,r=c):(typeof a.componentDidMount==`function`&&(t.flags|=4194308),r=!1)}else{a=t.stateNode,Ma(e,t),o=t.memoizedProps,u=Rs(n,o),a.props=u,d=t.pendingProps,f=a.context,l=n.contextType,c=Zr,typeof l==`object`&&l&&(c=Gi(l)),s=n.getDerivedStateFromProps,(l=typeof s==`function`||typeof a.getSnapshotBeforeUpdate==`function`)||typeof a.UNSAFE_componentWillReceiveProps!=`function`&&typeof a.componentWillReceiveProps!=`function`||(o!==d||f!==c)&&Ls(t,a,r,c),Aa=!1,f=t.memoizedState,a.state=f,za(t,r,a,i),Ra();var p=t.memoizedState;o!==d||f!==p||Aa||e!==null&&e.dependencies!==null&&Ui(e.dependencies)?(typeof s==`function`&&(Ps(t,n,s,r),p=t.memoizedState),(u=Aa||Is(t,n,u,r,f,p,c)||e!==null&&e.dependencies!==null&&Ui(e.dependencies))?(l||typeof a.UNSAFE_componentWillUpdate!=`function`&&typeof a.componentWillUpdate!=`function`||(typeof a.componentWillUpdate==`function`&&a.componentWillUpdate(r,p,c),typeof a.UNSAFE_componentWillUpdate==`function`&&a.UNSAFE_componentWillUpdate(r,p,c)),typeof a.componentDidUpdate==`function`&&(t.flags|=4),typeof a.getSnapshotBeforeUpdate==`function`&&(t.flags|=1024)):(typeof a.componentDidUpdate!=`function`||o===e.memoizedProps&&f===e.memoizedState||(t.flags|=4),typeof a.getSnapshotBeforeUpdate!=`function`||o===e.memoizedProps&&f===e.memoizedState||(t.flags|=1024),t.memoizedProps=r,t.memoizedState=p),a.props=r,a.state=p,a.context=c,r=u):(typeof a.componentDidUpdate!=`function`||o===e.memoizedProps&&f===e.memoizedState||(t.flags|=4),typeof a.getSnapshotBeforeUpdate!=`function`||o===e.memoizedProps&&f===e.memoizedState||(t.flags|=1024),r=!1)}return a=r,oc(e,t),r=(t.flags&128)!=0,a||r?(a=t.stateNode,n=r&&typeof n.getDerivedStateFromError!=`function`?null:a.render(),t.flags|=1,e!==null&&r?(t.child=Oa(t,e.child,null,i),t.child=Oa(t,null,n,i)):Xs(e,t,n,i),t.memoizedState=a.state,e=t.child):e=xc(e,t,i),e}function uc(e,t,n,r){return Mi(),t.flags|=256,Xs(e,t,n,r),t.child}var dc={dehydrated:null,treeContext:null,retryLane:0,hydrationErrors:null};function fc(e){return{baseLanes:e,cachePool:da()}}function pc(e,t,n){return e=e===null?0:e.childLanes&~n,t&&(e|=Kl),e}function mc(e,t,n){var r=t.pendingProps,i=!1,o=(t.flags&128)!=0,s;if((s=o)||(s=e!==null&&e.memoizedState===null?!1:(eo.current&2)!=0),s&&(i=!0,t.flags&=-129),s=(t.flags&32)!=0,t.flags&=-33,e===null){if(J){if(i?Ya(t):Qa(t),(e=Ti)?(e=rf(e,Ei),e=e!==null&&e.data!==`&`?e:null,e!==null&&(t.memoizedState={dehydrated:e,treeContext:gi===null?null:{id:_i,overflow:vi},retryLane:536870912,hydrationErrors:null},n=oi(e),n.return=t,t.child=n,wi=t,Ti=null)):e=null,e===null)throw Oi(t);return of(e)?t.lanes=32:t.lanes=536870912,null}var c=r.children;return r=r.fallback,i?(Qa(t),i=t.mode,c=gc({mode:`hidden`,children:c},i),r=ii(r,i,n,null),c.return=t,r.return=t,c.sibling=r,t.child=c,r=t.child,r.memoizedState=fc(n),r.childLanes=pc(e,s,n),t.memoizedState=dc,tc(null,r)):(Ya(t),hc(t,c))}var l=e.memoizedState;if(l!==null&&(c=l.dehydrated,c!==null)){if(o)t.flags&256?(Ya(t),t.flags&=-257,t=_c(e,t,n)):t.memoizedState===null?(Qa(t),c=r.fallback,i=t.mode,r=gc({mode:`visible`,children:r.children},i),c=ii(c,i,n,null),c.flags|=2,r.return=t,c.return=t,r.sibling=c,t.child=r,Oa(t,e.child,null,n),r=t.child,r.memoizedState=fc(n),r.childLanes=pc(e,s,n),t.memoizedState=dc,t=tc(null,r)):(Qa(t),t.child=e.child,t.flags|=128,t=null);else if(Ya(t),of(c)){if(s=c.nextSibling&&c.nextSibling.dataset,s)var u=s.dgst;s=u,r=Error(a(419)),r.stack=``,r.digest=s,Pi({value:r,source:null,stack:null}),t=_c(e,t,n)}else if(Ys||Hi(e,t,n,!1),s=(n&e.childLanes)!==0,Ys||s){if(s=Pl,s!==null&&(r=qe(s,n),r!==0&&r!==l.retryLane))throw l.retryLane=r,Jr(e,r),pu(s,e,r),Js;af(c)||Tu(),t=_c(e,t,n)}else af(c)?(t.flags|=192,t.child=e.child,t=null):(e=l.treeContext,Ti=cf(c.nextSibling),wi=t,J=!0,Y=null,Ei=!1,e!==null&&Ci(t,e),t=hc(t,r.children),t.flags|=4096);return t}return i?(Qa(t),c=r.fallback,i=t.mode,l=e.child,u=l.sibling,r=ti(l,{mode:`hidden`,children:r.children}),r.subtreeFlags=l.subtreeFlags&65011712,u===null?(c=ii(c,i,n,null),c.flags|=2):c=ti(u,c),c.return=t,r.return=t,r.sibling=c,t.child=r,tc(null,r),r=t.child,c=e.child.memoizedState,c===null?c=fc(n):(i=c.cachePool,i===null?i=da():(l=Zi._currentValue,i=i.parent===l?i:{parent:l,pool:l}),c={baseLanes:c.baseLanes|n,cachePool:i}),r.memoizedState=c,r.childLanes=pc(e,s,n),t.memoizedState=dc,tc(e.child,r)):(Ya(t),n=e.child,e=n.sibling,n=ti(n,{mode:`visible`,children:r.children}),n.return=t,n.sibling=null,e!==null&&(s=t.deletions,s===null?(t.deletions=[e],t.flags|=16):s.push(e)),t.child=n,t.memoizedState=null,n)}function hc(e,t){return t=gc({mode:`visible`,children:t},e.mode),t.return=e,e.child=t}function gc(e,t){return e=$r(22,e,null,t),e.lanes=0,e}function _c(e,t,n){return Oa(t,e.child,null,n),e=hc(t,t.pendingProps.children),e.flags|=2,t.memoizedState=null,e}function vc(e,t,n){e.lanes|=t;var r=e.alternate;r!==null&&(r.lanes|=t),Bi(e.return,t,n)}function yc(e,t,n,r,i,a){var o=e.memoizedState;o===null?e.memoizedState={isBackwards:t,rendering:null,renderingStartTime:0,last:r,tail:n,tailMode:i,treeForkCount:a}:(o.isBackwards=t,o.rendering=null,o.renderingStartTime=0,o.last=r,o.tail=n,o.tailMode=i,o.treeForkCount=a)}function bc(e,t,n){var r=t.pendingProps,i=r.revealOrder,a=r.tail;r=r.children;var o=eo.current,s=(o&2)!=0;if(s?(o=o&1|2,t.flags|=128):o&=1,z(eo,o),Xs(e,t,r,n),r=J?pi:0,!s&&e!==null&&e.flags&128)a:for(e=t.child;e!==null;){if(e.tag===13)e.memoizedState!==null&&vc(e,n,t);else if(e.tag===19)vc(e,n,t);else if(e.child!==null){e.child.return=e,e=e.child;continue}if(e===t)break a;for(;e.sibling===null;){if(e.return===null||e.return===t)break a;e=e.return}e.sibling.return=e.return,e=e.sibling}switch(i){case`forwards`:for(n=t.child,i=null;n!==null;)e=n.alternate,e!==null&&to(e)===null&&(i=n),n=n.sibling;n=i,n===null?(i=t.child,t.child=null):(i=n.sibling,n.sibling=null),yc(t,!1,i,n,a,r);break;case`backwards`:case`unstable_legacy-backwards`:for(n=null,i=t.child,t.child=null;i!==null;){if(e=i.alternate,e!==null&&to(e)===null){t.child=i;break}e=i.sibling,i.sibling=n,n=i,i=e}yc(t,!0,n,null,a,r);break;case`together`:yc(t,!1,null,null,void 0,r);break;default:t.memoizedState=null}return t.child}function xc(e,t,n){if(e!==null&&(t.dependencies=e.dependencies),Ul|=t.lanes,(n&t.childLanes)===0)if(e!==null){if(Hi(e,t,n,!1),(n&t.childLanes)===0)return null}else return null;if(e!==null&&t.child!==e.child)throw Error(a(153));if(t.child!==null){for(e=t.child,n=ti(e,e.pendingProps),t.child=n,n.return=t;e.sibling!==null;)e=e.sibling,n=n.sibling=ti(e,e.pendingProps),n.return=t;n.sibling=null}return t.child}function Sc(e,t){return(e.lanes&t)===0?(e=e.dependencies,!!(e!==null&&Ui(e))):!0}function Cc(e,t,n){switch(t.tag){case 3:ae(t,t.stateNode.containerInfo),Ri(t,Zi,e.memoizedState.cache),Mi();break;case 27:case 5:se(t);break;case 4:ae(t,t.stateNode.containerInfo);break;case 10:Ri(t,t.type,t.memoizedProps.value);break;case 31:if(t.memoizedState!==null)return t.flags|=128,Xa(t),null;break;case 13:var r=t.memoizedState;if(r!==null)return r.dehydrated===null?(n&t.child.childLanes)===0?(Ya(t),e=xc(e,t,n),e===null?null:e.sibling):mc(e,t,n):(Ya(t),t.flags|=128,null);Ya(t);break;case 19:var i=(e.flags&128)!=0;if(r=(n&t.childLanes)!==0,r||=(Hi(e,t,n,!1),(n&t.childLanes)!==0),i){if(r)return bc(e,t,n);t.flags|=128}if(i=t.memoizedState,i!==null&&(i.rendering=null,i.tail=null,i.lastEffect=null),z(eo,eo.current),r)break;return null;case 22:return t.lanes=0,ec(e,t,n,t.pendingProps);case 24:Ri(t,Zi,e.memoizedState.cache)}return xc(e,t,n)}function wc(e,t,n){if(e!==null)if(e.memoizedProps!==t.pendingProps)Ys=!0;else{if(!Sc(e,n)&&!(t.flags&128))return Ys=!1,Cc(e,t,n);Ys=!!(e.flags&131072)}else Ys=!1,J&&t.flags&1048576&&bi(t,pi,t.index);switch(t.lanes=0,t.tag){case 16:a:{var r=t.pendingProps;if(e=va(t.elementType),t.type=e,typeof e==`function`)ei(e)?(r=Rs(e,r),t.tag=1,t=lc(null,t,e,r,n)):(t.tag=0,t=sc(null,t,e,r,n));else{if(e!=null){var i=e.$$typeof;if(i===C){t.tag=11,t=Zs(null,t,e,r,n);break a}else if(i===E){t.tag=14,t=Qs(null,t,e,r,n);break a}}throw t=N(e)||e,Error(a(306,t,``))}}return t;case 0:return sc(e,t,t.type,t.pendingProps,n);case 1:return r=t.type,i=Rs(r,t.pendingProps),lc(e,t,r,i,n);case 3:a:{if(ae(t,t.stateNode.containerInfo),e===null)throw Error(a(387));r=t.pendingProps;var o=t.memoizedState;i=o.element,Ma(e,t),za(t,r,null,n);var s=t.memoizedState;if(r=s.cache,Ri(t,Zi,r),r!==o.cache&&Vi(t,[Zi],n,!0),Ra(),r=s.element,o.isDehydrated)if(o={element:r,isDehydrated:!1,cache:s.cache},t.updateQueue.baseState=o,t.memoizedState=o,t.flags&256){t=uc(e,t,r,n);break a}else if(r!==i){i=li(Error(a(424)),t),Pi(i),t=uc(e,t,r,n);break a}else{switch(e=t.stateNode.containerInfo,e.nodeType){case 9:e=e.body;break;default:e=e.nodeName===`HTML`?e.ownerDocument.body:e}for(Ti=cf(e.firstChild),wi=t,J=!0,Y=null,Ei=!0,n=ka(t,null,r,n),t.child=n;n;)n.flags=n.flags&-3|4096,n=n.sibling}else{if(Mi(),r===i){t=xc(e,t,n);break a}Xs(e,t,r,n)}t=t.child}return t;case 26:return oc(e,t),e===null?(n=kf(t.type,null,t.pendingProps,null))?t.memoizedState=n:J||(n=t.type,e=t.pendingProps,r=Bd(B.current).createElement(n),r[$e]=t,r[et]=e,Pd(r,n,e),ft(r),t.stateNode=r):t.memoizedState=kf(t.type,e.memoizedProps,t.pendingProps,e.memoizedState),null;case 27:return se(t),e===null&&J&&(r=t.stateNode=ff(t.type,t.pendingProps,B.current),wi=t,Ei=!0,i=Ti,Zd(t.type)?(lf=i,Ti=cf(r.firstChild)):Ti=i),Xs(e,t,t.pendingProps.children,n),oc(e,t),e===null&&(t.flags|=4194304),t.child;case 5:return e===null&&J&&((i=r=Ti)&&(r=tf(r,t.type,t.pendingProps,Ei),r===null?i=!1:(t.stateNode=r,wi=t,Ti=cf(r.firstChild),Ei=!1,i=!0)),i||Oi(t)),se(t),i=t.type,o=t.pendingProps,s=e===null?null:e.memoizedProps,r=o.children,Ud(i,o)?r=null:s!==null&&Ud(i,s)&&(t.flags|=32),t.memoizedState!==null&&(i=ho(e,t,vo,null,null,n),Qf._currentValue=i),oc(e,t),Xs(e,t,r,n),t.child;case 6:return e===null&&J&&((e=n=Ti)&&(n=nf(n,t.pendingProps,Ei),n===null?e=!1:(t.stateNode=n,wi=t,Ti=null,e=!0)),e||Oi(t)),null;case 13:return mc(e,t,n);case 4:return ae(t,t.stateNode.containerInfo),r=t.pendingProps,e===null?t.child=Oa(t,null,r,n):Xs(e,t,r,n),t.child;case 11:return Zs(e,t,t.type,t.pendingProps,n);case 7:return Xs(e,t,t.pendingProps,n),t.child;case 8:return Xs(e,t,t.pendingProps.children,n),t.child;case 12:return Xs(e,t,t.pendingProps.children,n),t.child;case 10:return r=t.pendingProps,Ri(t,t.type,r.value),Xs(e,t,r.children,n),t.child;case 9:return i=t.type._context,r=t.pendingProps.children,Wi(t),i=Gi(i),r=r(i),t.flags|=1,Xs(e,t,r,n),t.child;case 14:return Qs(e,t,t.type,t.pendingProps,n);case 15:return $s(e,t,t.type,t.pendingProps,n);case 19:return bc(e,t,n);case 31:return ac(e,t,n);case 22:return ec(e,t,n,t.pendingProps);case 24:return Wi(t),r=Gi(Zi),e===null?(i=la(),i===null&&(i=Pl,o=Qi(),i.pooledCache=o,o.refCount++,o!==null&&(i.pooledCacheLanes|=n),i=o),t.memoizedState={parent:r,cache:i},ja(t),Ri(t,Zi,i)):((e.lanes&n)!==0&&(Ma(e,t),za(t,null,null,n),Ra()),i=e.memoizedState,o=t.memoizedState,i.parent===r?(r=o.cache,Ri(t,Zi,r),r!==i.cache&&Vi(t,[Zi],n,!0)):(i={parent:r,cache:r},t.memoizedState=i,t.lanes===0&&(t.memoizedState=t.updateQueue.baseState=i),Ri(t,Zi,r))),Xs(e,t,t.pendingProps.children,n),t.child;case 29:throw t.pendingProps}throw Error(a(156,t.tag))}function Tc(e){e.flags|=4}function Ec(e,t,n,r,i){if((t=(e.mode&32)!=0)&&(t=!1),t){if(e.flags|=16777216,(i&335544128)===i)if(e.stateNode.complete)e.flags|=8192;else if(Su())e.flags|=8192;else throw ya=ha,pa}else e.flags&=-16777217}function Dc(e,t){if(t.type!==`stylesheet`||t.state.loading&4)e.flags&=-16777217;else if(e.flags|=16777216,!Wf(t))if(Su())e.flags|=8192;else throw ya=ha,pa}function Oc(e,t){t!==null&&(e.flags|=4),e.flags&16384&&(t=e.tag===22?536870912:Ve(),e.lanes|=t,ql|=t)}function kc(e,t){if(!J)switch(e.tailMode){case`hidden`:t=e.tail;for(var n=null;t!==null;)t.alternate!==null&&(n=t),t=t.sibling;n===null?e.tail=null:n.sibling=null;break;case`collapsed`:n=e.tail;for(var r=null;n!==null;)n.alternate!==null&&(r=n),n=n.sibling;r===null?t||e.tail===null?e.tail=null:e.tail.sibling=null:r.sibling=null}}function Ac(e){var t=e.alternate!==null&&e.alternate.child===e.child,n=0,r=0;if(t)for(var i=e.child;i!==null;)n|=i.lanes|i.childLanes,r|=i.subtreeFlags&65011712,r|=i.flags&65011712,i.return=e,i=i.sibling;else for(i=e.child;i!==null;)n|=i.lanes|i.childLanes,r|=i.subtreeFlags,r|=i.flags,i.return=e,i=i.sibling;return e.subtreeFlags|=r,e.childLanes=n,t}function jc(e,t,n){var r=t.pendingProps;switch(Si(t),t.tag){case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return Ac(t),null;case 1:return Ac(t),null;case 3:return n=t.stateNode,r=null,e!==null&&(r=e.memoizedState.cache),t.memoizedState.cache!==r&&(t.flags|=2048),zi(Zi),oe(),n.pendingContext&&(n.context=n.pendingContext,n.pendingContext=null),(e===null||e.child===null)&&(ji(t)?Tc(t):e===null||e.memoizedState.isDehydrated&&!(t.flags&256)||(t.flags|=1024,Ni())),Ac(t),null;case 26:var i=t.type,o=t.memoizedState;return e===null?(Tc(t),o===null?(Ac(t),Ec(t,i,null,r,n)):(Ac(t),Dc(t,o))):o?o===e.memoizedState?(Ac(t),t.flags&=-16777217):(Tc(t),Ac(t),Dc(t,o)):(e=e.memoizedProps,e!==r&&Tc(t),Ac(t),Ec(t,i,e,r,n)),null;case 27:if(ce(t),n=B.current,i=t.type,e!==null&&t.stateNode!=null)e.memoizedProps!==r&&Tc(t);else{if(!r){if(t.stateNode===null)throw Error(a(166));return Ac(t),null}e=re.current,ji(t)?ki(t,e):(e=ff(i,r,n),t.stateNode=e,Tc(t))}return Ac(t),null;case 5:if(ce(t),i=t.type,e!==null&&t.stateNode!=null)e.memoizedProps!==r&&Tc(t);else{if(!r){if(t.stateNode===null)throw Error(a(166));return Ac(t),null}if(o=re.current,ji(t))ki(t,o);else{var s=Bd(B.current);switch(o){case 1:o=s.createElementNS(`http://www.w3.org/2000/svg`,i);break;case 2:o=s.createElementNS(`http://www.w3.org/1998/Math/MathML`,i);break;default:switch(i){case`svg`:o=s.createElementNS(`http://www.w3.org/2000/svg`,i);break;case`math`:o=s.createElementNS(`http://www.w3.org/1998/Math/MathML`,i);break;case`script`:o=s.createElement(`div`),o.innerHTML=`<script><\/script>`,o=o.removeChild(o.firstChild);break;case`select`:o=typeof r.is==`string`?s.createElement(`select`,{is:r.is}):s.createElement(`select`),r.multiple?o.multiple=!0:r.size&&(o.size=r.size);break;default:o=typeof r.is==`string`?s.createElement(i,{is:r.is}):s.createElement(i)}}o[$e]=t,o[et]=r;a:for(s=t.child;s!==null;){if(s.tag===5||s.tag===6)o.appendChild(s.stateNode);else if(s.tag!==4&&s.tag!==27&&s.child!==null){s.child.return=s,s=s.child;continue}if(s===t)break a;for(;s.sibling===null;){if(s.return===null||s.return===t)break a;s=s.return}s.sibling.return=s.return,s=s.sibling}t.stateNode=o;a:switch(Pd(o,i,r),i){case`button`:case`input`:case`select`:case`textarea`:r=!!r.autoFocus;break a;case`img`:r=!0;break a;default:r=!1}r&&Tc(t)}}return Ac(t),Ec(t,t.type,e===null?null:e.memoizedProps,t.pendingProps,n),null;case 6:if(e&&t.stateNode!=null)e.memoizedProps!==r&&Tc(t);else{if(typeof r!=`string`&&t.stateNode===null)throw Error(a(166));if(e=B.current,ji(t)){if(e=t.stateNode,n=t.memoizedProps,r=null,i=wi,i!==null)switch(i.tag){case 27:case 5:r=i.memoizedProps}e[$e]=t,e=!!(e.nodeValue===n||r!==null&&!0===r.suppressHydrationWarning||jd(e.nodeValue,n)),e||Oi(t,!0)}else e=Bd(e).createTextNode(r),e[$e]=t,t.stateNode=e}return Ac(t),null;case 31:if(n=t.memoizedState,e===null||e.memoizedState!==null){if(r=ji(t),n!==null){if(e===null){if(!r)throw Error(a(318));if(e=t.memoizedState,e=e===null?null:e.dehydrated,!e)throw Error(a(557));e[$e]=t}else Mi(),!(t.flags&128)&&(t.memoizedState=null),t.flags|=4;Ac(t),e=!1}else n=Ni(),e!==null&&e.memoizedState!==null&&(e.memoizedState.hydrationErrors=n),e=!0;if(!e)return t.flags&256?($a(t),t):($a(t),null);if(t.flags&128)throw Error(a(558))}return Ac(t),null;case 13:if(r=t.memoizedState,e===null||e.memoizedState!==null&&e.memoizedState.dehydrated!==null){if(i=ji(t),r!==null&&r.dehydrated!==null){if(e===null){if(!i)throw Error(a(318));if(i=t.memoizedState,i=i===null?null:i.dehydrated,!i)throw Error(a(317));i[$e]=t}else Mi(),!(t.flags&128)&&(t.memoizedState=null),t.flags|=4;Ac(t),i=!1}else i=Ni(),e!==null&&e.memoizedState!==null&&(e.memoizedState.hydrationErrors=i),i=!0;if(!i)return t.flags&256?($a(t),t):($a(t),null)}return $a(t),t.flags&128?(t.lanes=n,t):(n=r!==null,e=e!==null&&e.memoizedState!==null,n&&(r=t.child,i=null,r.alternate!==null&&r.alternate.memoizedState!==null&&r.alternate.memoizedState.cachePool!==null&&(i=r.alternate.memoizedState.cachePool.pool),o=null,r.memoizedState!==null&&r.memoizedState.cachePool!==null&&(o=r.memoizedState.cachePool.pool),o!==i&&(r.flags|=2048)),n!==e&&n&&(t.child.flags|=8192),Oc(t,t.updateQueue),Ac(t),null);case 4:return oe(),e===null&&xd(t.stateNode.containerInfo),Ac(t),null;case 10:return zi(t.type),Ac(t),null;case 19:if(R(eo),r=t.memoizedState,r===null)return Ac(t),null;if(i=(t.flags&128)!=0,o=r.rendering,o===null)if(i)kc(r,!1);else{if(Hl!==0||e!==null&&e.flags&128)for(e=t.child;e!==null;){if(o=to(e),o!==null){for(t.flags|=128,kc(r,!1),e=o.updateQueue,t.updateQueue=e,Oc(t,e),t.subtreeFlags=0,e=n,n=t.child;n!==null;)ni(n,e),n=n.sibling;return z(eo,eo.current&1|2),J&&yi(t,r.treeForkCount),t.child}e=e.sibling}r.tail!==null&&ye()>$l&&(t.flags|=128,i=!0,kc(r,!1),t.lanes=4194304)}else{if(!i)if(e=to(o),e!==null){if(t.flags|=128,i=!0,e=e.updateQueue,t.updateQueue=e,Oc(t,e),kc(r,!0),r.tail===null&&r.tailMode===`hidden`&&!o.alternate&&!J)return Ac(t),null}else 2*ye()-r.renderingStartTime>$l&&n!==536870912&&(t.flags|=128,i=!0,kc(r,!1),t.lanes=4194304);r.isBackwards?(o.sibling=t.child,t.child=o):(e=r.last,e===null?t.child=o:e.sibling=o,r.last=o)}return r.tail===null?(Ac(t),null):(e=r.tail,r.rendering=e,r.tail=e.sibling,r.renderingStartTime=ye(),e.sibling=null,n=eo.current,z(eo,i?n&1|2:n&1),J&&yi(t,r.treeForkCount),e);case 22:case 23:return $a(t),Ka(),r=t.memoizedState!==null,e===null?r&&(t.flags|=8192):e.memoizedState!==null!==r&&(t.flags|=8192),r?n&536870912&&!(t.flags&128)&&(Ac(t),t.subtreeFlags&6&&(t.flags|=8192)):Ac(t),n=t.updateQueue,n!==null&&Oc(t,n.retryQueue),n=null,e!==null&&e.memoizedState!==null&&e.memoizedState.cachePool!==null&&(n=e.memoizedState.cachePool.pool),r=null,t.memoizedState!==null&&t.memoizedState.cachePool!==null&&(r=t.memoizedState.cachePool.pool),r!==n&&(t.flags|=2048),e!==null&&R(ca),null;case 24:return n=null,e!==null&&(n=e.memoizedState.cache),t.memoizedState.cache!==n&&(t.flags|=2048),zi(Zi),Ac(t),null;case 25:return null;case 30:return null}throw Error(a(156,t.tag))}function Mc(e,t){switch(Si(t),t.tag){case 1:return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 3:return zi(Zi),oe(),e=t.flags,e&65536&&!(e&128)?(t.flags=e&-65537|128,t):null;case 26:case 27:case 5:return ce(t),null;case 31:if(t.memoizedState!==null){if($a(t),t.alternate===null)throw Error(a(340));Mi()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 13:if($a(t),e=t.memoizedState,e!==null&&e.dehydrated!==null){if(t.alternate===null)throw Error(a(340));Mi()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 19:return R(eo),null;case 4:return oe(),null;case 10:return zi(t.type),null;case 22:case 23:return $a(t),Ka(),e!==null&&R(ca),e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 24:return zi(Zi),null;case 25:return null;default:return null}}function Nc(e,t){switch(Si(t),t.tag){case 3:zi(Zi),oe();break;case 26:case 27:case 5:ce(t);break;case 4:oe();break;case 31:t.memoizedState!==null&&$a(t);break;case 13:$a(t);break;case 19:R(eo);break;case 10:zi(t.type);break;case 22:case 23:$a(t),Ka(),e!==null&&R(ca);break;case 24:zi(Zi)}}function Pc(e,t){try{var n=t.updateQueue,r=n===null?null:n.lastEffect;if(r!==null){var i=r.next;n=i;do{if((n.tag&e)===e){r=void 0;var a=n.create,o=n.inst;r=a(),o.destroy=r}n=n.next}while(n!==i)}}catch(e){Uu(t,t.return,e)}}function Fc(e,t,n){try{var r=t.updateQueue,i=r===null?null:r.lastEffect;if(i!==null){var a=i.next;r=a;do{if((r.tag&e)===e){var o=r.inst,s=o.destroy;if(s!==void 0){o.destroy=void 0,i=t;var c=n,l=s;try{l()}catch(e){Uu(i,c,e)}}}r=r.next}while(r!==a)}}catch(e){Uu(t,t.return,e)}}function Ic(e){var t=e.updateQueue;if(t!==null){var n=e.stateNode;try{Va(t,n)}catch(t){Uu(e,e.return,t)}}}function Lc(e,t,n){n.props=Rs(e.type,e.memoizedProps),n.state=e.memoizedState;try{n.componentWillUnmount()}catch(n){Uu(e,t,n)}}function Rc(e,t){try{var n=e.ref;if(n!==null){switch(e.tag){case 26:case 27:case 5:var r=e.stateNode;break;case 30:r=e.stateNode;break;default:r=e.stateNode}typeof n==`function`?e.refCleanup=n(r):n.current=r}}catch(n){Uu(e,t,n)}}function zc(e,t){var n=e.ref,r=e.refCleanup;if(n!==null)if(typeof r==`function`)try{r()}catch(n){Uu(e,t,n)}finally{e.refCleanup=null,e=e.alternate,e!=null&&(e.refCleanup=null)}else if(typeof n==`function`)try{n(null)}catch(n){Uu(e,t,n)}else n.current=null}function Bc(e){var t=e.type,n=e.memoizedProps,r=e.stateNode;try{a:switch(t){case`button`:case`input`:case`select`:case`textarea`:n.autoFocus&&r.focus();break a;case`img`:n.src?r.src=n.src:n.srcSet&&(r.srcset=n.srcSet)}}catch(t){Uu(e,e.return,t)}}function Vc(e,t,n){try{var r=e.stateNode;Fd(r,e.type,n,t),r[et]=t}catch(t){Uu(e,e.return,t)}}function Hc(e){return e.tag===5||e.tag===3||e.tag===26||e.tag===27&&Zd(e.type)||e.tag===4}function Uc(e){a:for(;;){for(;e.sibling===null;){if(e.return===null||Hc(e.return))return null;e=e.return}for(e.sibling.return=e.return,e=e.sibling;e.tag!==5&&e.tag!==6&&e.tag!==18;){if(e.tag===27&&Zd(e.type)||e.flags&2||e.child===null||e.tag===4)continue a;e.child.return=e,e=e.child}if(!(e.flags&2))return e.stateNode}}function Wc(e,t,n){var r=e.tag;if(r===5||r===6)e=e.stateNode,t?(n.nodeType===9?n.body:n.nodeName===`HTML`?n.ownerDocument.body:n).insertBefore(e,t):(t=n.nodeType===9?n.body:n.nodeName===`HTML`?n.ownerDocument.body:n,t.appendChild(e),n=n._reactRootContainer,n!=null||t.onclick!==null||(t.onclick=Kt));else if(r!==4&&(r===27&&Zd(e.type)&&(n=e.stateNode,t=null),e=e.child,e!==null))for(Wc(e,t,n),e=e.sibling;e!==null;)Wc(e,t,n),e=e.sibling}function Gc(e,t,n){var r=e.tag;if(r===5||r===6)e=e.stateNode,t?n.insertBefore(e,t):n.appendChild(e);else if(r!==4&&(r===27&&Zd(e.type)&&(n=e.stateNode),e=e.child,e!==null))for(Gc(e,t,n),e=e.sibling;e!==null;)Gc(e,t,n),e=e.sibling}function Kc(e){var t=e.stateNode,n=e.memoizedProps;try{for(var r=e.type,i=t.attributes;i.length;)t.removeAttributeNode(i[0]);Pd(t,r,n),t[$e]=e,t[et]=n}catch(t){Uu(e,e.return,t)}}var qc=!1,Jc=!1,Yc=!1,Xc=typeof WeakSet==`function`?WeakSet:Set,Zc=null;function Qc(e,t){if(e=e.containerInfo,Rd=sp,e=vr(e),yr(e)){if(`selectionStart`in e)var n={start:e.selectionStart,end:e.selectionEnd};else a:{n=(n=e.ownerDocument)&&n.defaultView||window;var r=n.getSelection&&n.getSelection();if(r&&r.rangeCount!==0){n=r.anchorNode;var i=r.anchorOffset,o=r.focusNode;r=r.focusOffset;try{n.nodeType,o.nodeType}catch{n=null;break a}var s=0,c=-1,l=-1,u=0,d=0,f=e,p=null;b:for(;;){for(var m;f!==n||i!==0&&f.nodeType!==3||(c=s+i),f!==o||r!==0&&f.nodeType!==3||(l=s+r),f.nodeType===3&&(s+=f.nodeValue.length),(m=f.firstChild)!==null;)p=f,f=m;for(;;){if(f===e)break b;if(p===n&&++u===i&&(c=s),p===o&&++d===r&&(l=s),(m=f.nextSibling)!==null)break;f=p,p=f.parentNode}f=m}n=c===-1||l===-1?null:{start:c,end:l}}else n=null}n||={start:0,end:0}}else n=null;for(zd={focusedElem:e,selectionRange:n},sp=!1,Zc=t;Zc!==null;)if(t=Zc,e=t.child,t.subtreeFlags&1028&&e!==null)e.return=t,Zc=e;else for(;Zc!==null;){switch(t=Zc,o=t.alternate,e=t.flags,t.tag){case 0:if(e&4&&(e=t.updateQueue,e=e===null?null:e.events,e!==null))for(n=0;n<e.length;n++)i=e[n],i.ref.impl=i.nextImpl;break;case 11:case 15:break;case 1:if(e&1024&&o!==null){e=void 0,n=t,i=o.memoizedProps,o=o.memoizedState,r=n.stateNode;try{var h=Rs(n.type,i);e=r.getSnapshotBeforeUpdate(h,o),r.__reactInternalSnapshotBeforeUpdate=e}catch(e){Uu(n,n.return,e)}}break;case 3:if(e&1024){if(e=t.stateNode.containerInfo,n=e.nodeType,n===9)ef(e);else if(n===1)switch(e.nodeName){case`HEAD`:case`HTML`:case`BODY`:ef(e);break;default:e.textContent=``}}break;case 5:case 26:case 27:case 6:case 4:case 17:break;default:if(e&1024)throw Error(a(163))}if(e=t.sibling,e!==null){e.return=t.return,Zc=e;break}Zc=t.return}}function $c(e,t,n){var r=n.flags;switch(n.tag){case 0:case 11:case 15:ml(e,n),r&4&&Pc(5,n);break;case 1:if(ml(e,n),r&4)if(e=n.stateNode,t===null)try{e.componentDidMount()}catch(e){Uu(n,n.return,e)}else{var i=Rs(n.type,t.memoizedProps);t=t.memoizedState;try{e.componentDidUpdate(i,t,e.__reactInternalSnapshotBeforeUpdate)}catch(e){Uu(n,n.return,e)}}r&64&&Ic(n),r&512&&Rc(n,n.return);break;case 3:if(ml(e,n),r&64&&(e=n.updateQueue,e!==null)){if(t=null,n.child!==null)switch(n.child.tag){case 27:case 5:t=n.child.stateNode;break;case 1:t=n.child.stateNode}try{Va(e,t)}catch(e){Uu(n,n.return,e)}}break;case 27:t===null&&r&4&&Kc(n);case 26:case 5:ml(e,n),t===null&&r&4&&Bc(n),r&512&&Rc(n,n.return);break;case 12:ml(e,n);break;case 31:ml(e,n),r&4&&al(e,n);break;case 13:ml(e,n),r&4&&ol(e,n),r&64&&(e=n.memoizedState,e!==null&&(e=e.dehydrated,e!==null&&(n=qu.bind(null,n),sf(e,n))));break;case 22:if(r=n.memoizedState!==null||qc,!r){t=t!==null&&t.memoizedState!==null||Jc,i=qc;var a=Jc;qc=r,(Jc=t)&&!a?gl(e,n,(n.subtreeFlags&8772)!=0):ml(e,n),qc=i,Jc=a}break;case 30:break;default:ml(e,n)}}function el(e){var t=e.alternate;t!==null&&(e.alternate=null,el(t)),e.child=null,e.deletions=null,e.sibling=null,e.tag===5&&(t=e.stateNode,t!==null&&st(t)),e.stateNode=null,e.return=null,e.dependencies=null,e.memoizedProps=null,e.memoizedState=null,e.pendingProps=null,e.stateNode=null,e.updateQueue=null}var tl=null,nl=!1;function rl(e,t,n){for(n=n.child;n!==null;)il(e,t,n),n=n.sibling}function il(e,t,n){if(ke&&typeof ke.onCommitFiberUnmount==`function`)try{ke.onCommitFiberUnmount(Oe,n)}catch{}switch(n.tag){case 26:Jc||zc(n,t),rl(e,t,n),n.memoizedState?n.memoizedState.count--:n.stateNode&&(n=n.stateNode,n.parentNode.removeChild(n));break;case 27:Jc||zc(n,t);var r=tl,i=nl;Zd(n.type)&&(tl=n.stateNode,nl=!1),rl(e,t,n),pf(n.stateNode),tl=r,nl=i;break;case 5:Jc||zc(n,t);case 6:if(r=tl,i=nl,tl=null,rl(e,t,n),tl=r,nl=i,tl!==null)if(nl)try{(tl.nodeType===9?tl.body:tl.nodeName===`HTML`?tl.ownerDocument.body:tl).removeChild(n.stateNode)}catch(e){Uu(n,t,e)}else try{tl.removeChild(n.stateNode)}catch(e){Uu(n,t,e)}break;case 18:tl!==null&&(nl?(e=tl,Qd(e.nodeType===9?e.body:e.nodeName===`HTML`?e.ownerDocument.body:e,n.stateNode),Np(e)):Qd(tl,n.stateNode));break;case 4:r=tl,i=nl,tl=n.stateNode.containerInfo,nl=!0,rl(e,t,n),tl=r,nl=i;break;case 0:case 11:case 14:case 15:Fc(2,n,t),Jc||Fc(4,n,t),rl(e,t,n);break;case 1:Jc||(zc(n,t),r=n.stateNode,typeof r.componentWillUnmount==`function`&&Lc(n,t,r)),rl(e,t,n);break;case 21:rl(e,t,n);break;case 22:Jc=(r=Jc)||n.memoizedState!==null,rl(e,t,n),Jc=r;break;default:rl(e,t,n)}}function al(e,t){if(t.memoizedState===null&&(e=t.alternate,e!==null&&(e=e.memoizedState,e!==null))){e=e.dehydrated;try{Np(e)}catch(e){Uu(t,t.return,e)}}}function ol(e,t){if(t.memoizedState===null&&(e=t.alternate,e!==null&&(e=e.memoizedState,e!==null&&(e=e.dehydrated,e!==null))))try{Np(e)}catch(e){Uu(t,t.return,e)}}function sl(e){switch(e.tag){case 31:case 13:case 19:var t=e.stateNode;return t===null&&(t=e.stateNode=new Xc),t;case 22:return e=e.stateNode,t=e._retryCache,t===null&&(t=e._retryCache=new Xc),t;default:throw Error(a(435,e.tag))}}function cl(e,t){var n=sl(e);t.forEach(function(t){if(!n.has(t)){n.add(t);var r=Ju.bind(null,e,t);t.then(r,r)}})}function ll(e,t){var n=t.deletions;if(n!==null)for(var r=0;r<n.length;r++){var i=n[r],o=e,s=t,c=s;a:for(;c!==null;){switch(c.tag){case 27:if(Zd(c.type)){tl=c.stateNode,nl=!1;break a}break;case 5:tl=c.stateNode,nl=!1;break a;case 3:case 4:tl=c.stateNode.containerInfo,nl=!0;break a}c=c.return}if(tl===null)throw Error(a(160));il(o,s,i),tl=null,nl=!1,o=i.alternate,o!==null&&(o.return=null),i.return=null}if(t.subtreeFlags&13886)for(t=t.child;t!==null;)dl(t,e),t=t.sibling}var ul=null;function dl(e,t){var n=e.alternate,r=e.flags;switch(e.tag){case 0:case 11:case 14:case 15:ll(t,e),fl(e),r&4&&(Fc(3,e,e.return),Pc(3,e),Fc(5,e,e.return));break;case 1:ll(t,e),fl(e),r&512&&(Jc||n===null||zc(n,n.return)),r&64&&qc&&(e=e.updateQueue,e!==null&&(r=e.callbacks,r!==null&&(n=e.shared.hiddenCallbacks,e.shared.hiddenCallbacks=n===null?r:n.concat(r))));break;case 26:var i=ul;if(ll(t,e),fl(e),r&512&&(Jc||n===null||zc(n,n.return)),r&4){var o=n===null?null:n.memoizedState;if(r=e.memoizedState,n===null)if(r===null)if(e.stateNode===null){a:{r=e.type,n=e.memoizedProps,i=i.ownerDocument||i;b:switch(r){case`title`:o=i.getElementsByTagName(`title`)[0],(!o||o[ot]||o[$e]||o.namespaceURI===`http://www.w3.org/2000/svg`||o.hasAttribute(`itemprop`))&&(o=i.createElement(r),i.head.insertBefore(o,i.querySelector(`head > title`))),Pd(o,r,n),o[$e]=e,ft(o),r=o;break a;case`link`:var s=Vf(`link`,`href`,i).get(r+(n.href||``));if(s){for(var c=0;c<s.length;c++)if(o=s[c],o.getAttribute(`href`)===(n.href==null||n.href===``?null:n.href)&&o.getAttribute(`rel`)===(n.rel==null?null:n.rel)&&o.getAttribute(`title`)===(n.title==null?null:n.title)&&o.getAttribute(`crossorigin`)===(n.crossOrigin==null?null:n.crossOrigin)){s.splice(c,1);break b}}o=i.createElement(r),Pd(o,r,n),i.head.appendChild(o);break;case`meta`:if(s=Vf(`meta`,`content`,i).get(r+(n.content||``))){for(c=0;c<s.length;c++)if(o=s[c],o.getAttribute(`content`)===(n.content==null?null:``+n.content)&&o.getAttribute(`name`)===(n.name==null?null:n.name)&&o.getAttribute(`property`)===(n.property==null?null:n.property)&&o.getAttribute(`http-equiv`)===(n.httpEquiv==null?null:n.httpEquiv)&&o.getAttribute(`charset`)===(n.charSet==null?null:n.charSet)){s.splice(c,1);break b}}o=i.createElement(r),Pd(o,r,n),i.head.appendChild(o);break;default:throw Error(a(468,r))}o[$e]=e,ft(o),r=o}e.stateNode=r}else Hf(i,e.type,e.stateNode);else e.stateNode=If(i,r,e.memoizedProps);else o===r?r===null&&e.stateNode!==null&&Vc(e,e.memoizedProps,n.memoizedProps):(o===null?n.stateNode!==null&&(n=n.stateNode,n.parentNode.removeChild(n)):o.count--,r===null?Hf(i,e.type,e.stateNode):If(i,r,e.memoizedProps))}break;case 27:ll(t,e),fl(e),r&512&&(Jc||n===null||zc(n,n.return)),n!==null&&r&4&&Vc(e,e.memoizedProps,n.memoizedProps);break;case 5:if(ll(t,e),fl(e),r&512&&(Jc||n===null||zc(n,n.return)),e.flags&32){i=e.stateNode;try{Rt(i,``)}catch(t){Uu(e,e.return,t)}}r&4&&e.stateNode!=null&&(i=e.memoizedProps,Vc(e,i,n===null?i:n.memoizedProps)),r&1024&&(Yc=!0);break;case 6:if(ll(t,e),fl(e),r&4){if(e.stateNode===null)throw Error(a(162));r=e.memoizedProps,n=e.stateNode;try{n.nodeValue=r}catch(t){Uu(e,e.return,t)}}break;case 3:if(Bf=null,i=ul,ul=gf(t.containerInfo),ll(t,e),ul=i,fl(e),r&4&&n!==null&&n.memoizedState.isDehydrated)try{Np(t.containerInfo)}catch(t){Uu(e,e.return,t)}Yc&&(Yc=!1,pl(e));break;case 4:r=ul,ul=gf(e.stateNode.containerInfo),ll(t,e),fl(e),ul=r;break;case 12:ll(t,e),fl(e);break;case 31:ll(t,e),fl(e),r&4&&(r=e.updateQueue,r!==null&&(e.updateQueue=null,cl(e,r)));break;case 13:ll(t,e),fl(e),e.child.flags&8192&&e.memoizedState!==null!=(n!==null&&n.memoizedState!==null)&&(Zl=ye()),r&4&&(r=e.updateQueue,r!==null&&(e.updateQueue=null,cl(e,r)));break;case 22:i=e.memoizedState!==null;var l=n!==null&&n.memoizedState!==null,u=qc,d=Jc;if(qc=u||i,Jc=d||l,ll(t,e),Jc=d,qc=u,fl(e),r&8192)a:for(t=e.stateNode,t._visibility=i?t._visibility&-2:t._visibility|1,i&&(n===null||l||qc||Jc||hl(e)),n=null,t=e;;){if(t.tag===5||t.tag===26){if(n===null){l=n=t;try{if(o=l.stateNode,i)s=o.style,typeof s.setProperty==`function`?s.setProperty(`display`,`none`,`important`):s.display=`none`;else{c=l.stateNode;var f=l.memoizedProps.style,p=f!=null&&f.hasOwnProperty(`display`)?f.display:null;c.style.display=p==null||typeof p==`boolean`?``:(``+p).trim()}}catch(e){Uu(l,l.return,e)}}}else if(t.tag===6){if(n===null){l=t;try{l.stateNode.nodeValue=i?``:l.memoizedProps}catch(e){Uu(l,l.return,e)}}}else if(t.tag===18){if(n===null){l=t;try{var m=l.stateNode;i?$d(m,!0):$d(l.stateNode,!1)}catch(e){Uu(l,l.return,e)}}}else if((t.tag!==22&&t.tag!==23||t.memoizedState===null||t===e)&&t.child!==null){t.child.return=t,t=t.child;continue}if(t===e)break a;for(;t.sibling===null;){if(t.return===null||t.return===e)break a;n===t&&(n=null),t=t.return}n===t&&(n=null),t.sibling.return=t.return,t=t.sibling}r&4&&(r=e.updateQueue,r!==null&&(n=r.retryQueue,n!==null&&(r.retryQueue=null,cl(e,n))));break;case 19:ll(t,e),fl(e),r&4&&(r=e.updateQueue,r!==null&&(e.updateQueue=null,cl(e,r)));break;case 30:break;case 21:break;default:ll(t,e),fl(e)}}function fl(e){var t=e.flags;if(t&2){try{for(var n,r=e.return;r!==null;){if(Hc(r)){n=r;break}r=r.return}if(n==null)throw Error(a(160));switch(n.tag){case 27:var i=n.stateNode;Gc(e,Uc(e),i);break;case 5:var o=n.stateNode;n.flags&32&&(Rt(o,``),n.flags&=-33),Gc(e,Uc(e),o);break;case 3:case 4:var s=n.stateNode.containerInfo;Wc(e,Uc(e),s);break;default:throw Error(a(161))}}catch(t){Uu(e,e.return,t)}e.flags&=-3}t&4096&&(e.flags&=-4097)}function pl(e){if(e.subtreeFlags&1024)for(e=e.child;e!==null;){var t=e;pl(t),t.tag===5&&t.flags&1024&&t.stateNode.reset(),e=e.sibling}}function ml(e,t){if(t.subtreeFlags&8772)for(t=t.child;t!==null;)$c(e,t.alternate,t),t=t.sibling}function hl(e){for(e=e.child;e!==null;){var t=e;switch(t.tag){case 0:case 11:case 14:case 15:Fc(4,t,t.return),hl(t);break;case 1:zc(t,t.return);var n=t.stateNode;typeof n.componentWillUnmount==`function`&&Lc(t,t.return,n),hl(t);break;case 27:pf(t.stateNode);case 26:case 5:zc(t,t.return),hl(t);break;case 22:t.memoizedState===null&&hl(t);break;case 30:hl(t);break;default:hl(t)}e=e.sibling}}function gl(e,t,n){for(n&&=(t.subtreeFlags&8772)!=0,t=t.child;t!==null;){var r=t.alternate,i=e,a=t,o=a.flags;switch(a.tag){case 0:case 11:case 15:gl(i,a,n),Pc(4,a);break;case 1:if(gl(i,a,n),r=a,i=r.stateNode,typeof i.componentDidMount==`function`)try{i.componentDidMount()}catch(e){Uu(r,r.return,e)}if(r=a,i=r.updateQueue,i!==null){var s=r.stateNode;try{var c=i.shared.hiddenCallbacks;if(c!==null)for(i.shared.hiddenCallbacks=null,i=0;i<c.length;i++)Ba(c[i],s)}catch(e){Uu(r,r.return,e)}}n&&o&64&&Ic(a),Rc(a,a.return);break;case 27:Kc(a);case 26:case 5:gl(i,a,n),n&&r===null&&o&4&&Bc(a),Rc(a,a.return);break;case 12:gl(i,a,n);break;case 31:gl(i,a,n),n&&o&4&&al(i,a);break;case 13:gl(i,a,n),n&&o&4&&ol(i,a);break;case 22:a.memoizedState===null&&gl(i,a,n),Rc(a,a.return);break;case 30:break;default:gl(i,a,n)}t=t.sibling}}function _l(e,t){var n=null;e!==null&&e.memoizedState!==null&&e.memoizedState.cachePool!==null&&(n=e.memoizedState.cachePool.pool),e=null,t.memoizedState!==null&&t.memoizedState.cachePool!==null&&(e=t.memoizedState.cachePool.pool),e!==n&&(e!=null&&e.refCount++,n!=null&&$i(n))}function vl(e,t){e=null,t.alternate!==null&&(e=t.alternate.memoizedState.cache),t=t.memoizedState.cache,t!==e&&(t.refCount++,e!=null&&$i(e))}function yl(e,t,n,r){if(t.subtreeFlags&10256)for(t=t.child;t!==null;)bl(e,t,n,r),t=t.sibling}function bl(e,t,n,r){var i=t.flags;switch(t.tag){case 0:case 11:case 15:yl(e,t,n,r),i&2048&&Pc(9,t);break;case 1:yl(e,t,n,r);break;case 3:yl(e,t,n,r),i&2048&&(e=null,t.alternate!==null&&(e=t.alternate.memoizedState.cache),t=t.memoizedState.cache,t!==e&&(t.refCount++,e!=null&&$i(e)));break;case 12:if(i&2048){yl(e,t,n,r),e=t.stateNode;try{var a=t.memoizedProps,o=a.id,s=a.onPostCommit;typeof s==`function`&&s(o,t.alternate===null?`mount`:`update`,e.passiveEffectDuration,-0)}catch(e){Uu(t,t.return,e)}}else yl(e,t,n,r);break;case 31:yl(e,t,n,r);break;case 13:yl(e,t,n,r);break;case 23:break;case 22:a=t.stateNode,o=t.alternate,t.memoizedState===null?a._visibility&2?yl(e,t,n,r):(a._visibility|=2,xl(e,t,n,r,(t.subtreeFlags&10256)!=0||!1)):a._visibility&2?yl(e,t,n,r):Sl(e,t),i&2048&&_l(o,t);break;case 24:yl(e,t,n,r),i&2048&&vl(t.alternate,t);break;default:yl(e,t,n,r)}}function xl(e,t,n,r,i){for(i&&=(t.subtreeFlags&10256)!=0||!1,t=t.child;t!==null;){var a=e,o=t,s=n,c=r,l=o.flags;switch(o.tag){case 0:case 11:case 15:xl(a,o,s,c,i),Pc(8,o);break;case 23:break;case 22:var u=o.stateNode;o.memoizedState===null?(u._visibility|=2,xl(a,o,s,c,i)):u._visibility&2?xl(a,o,s,c,i):Sl(a,o),i&&l&2048&&_l(o.alternate,o);break;case 24:xl(a,o,s,c,i),i&&l&2048&&vl(o.alternate,o);break;default:xl(a,o,s,c,i)}t=t.sibling}}function Sl(e,t){if(t.subtreeFlags&10256)for(t=t.child;t!==null;){var n=e,r=t,i=r.flags;switch(r.tag){case 22:Sl(n,r),i&2048&&_l(r.alternate,r);break;case 24:Sl(n,r),i&2048&&vl(r.alternate,r);break;default:Sl(n,r)}t=t.sibling}}var Cl=8192;function wl(e,t,n){if(e.subtreeFlags&Cl)for(e=e.child;e!==null;)Tl(e,t,n),e=e.sibling}function Tl(e,t,n){switch(e.tag){case 26:wl(e,t,n),e.flags&Cl&&e.memoizedState!==null&&Gf(n,ul,e.memoizedState,e.memoizedProps);break;case 5:wl(e,t,n);break;case 3:case 4:var r=ul;ul=gf(e.stateNode.containerInfo),wl(e,t,n),ul=r;break;case 22:e.memoizedState===null&&(r=e.alternate,r!==null&&r.memoizedState!==null?(r=Cl,Cl=16777216,wl(e,t,n),Cl=r):wl(e,t,n));break;default:wl(e,t,n)}}function El(e){var t=e.alternate;if(t!==null&&(e=t.child,e!==null)){t.child=null;do t=e.sibling,e.sibling=null,e=t;while(e!==null)}}function Dl(e){var t=e.deletions;if(e.flags&16){if(t!==null)for(var n=0;n<t.length;n++){var r=t[n];Zc=r,Al(r,e)}El(e)}if(e.subtreeFlags&10256)for(e=e.child;e!==null;)Ol(e),e=e.sibling}function Ol(e){switch(e.tag){case 0:case 11:case 15:Dl(e),e.flags&2048&&Fc(9,e,e.return);break;case 3:Dl(e);break;case 12:Dl(e);break;case 22:var t=e.stateNode;e.memoizedState!==null&&t._visibility&2&&(e.return===null||e.return.tag!==13)?(t._visibility&=-3,kl(e)):Dl(e);break;default:Dl(e)}}function kl(e){var t=e.deletions;if(e.flags&16){if(t!==null)for(var n=0;n<t.length;n++){var r=t[n];Zc=r,Al(r,e)}El(e)}for(e=e.child;e!==null;){switch(t=e,t.tag){case 0:case 11:case 15:Fc(8,t,t.return),kl(t);break;case 22:n=t.stateNode,n._visibility&2&&(n._visibility&=-3,kl(t));break;default:kl(t)}e=e.sibling}}function Al(e,t){for(;Zc!==null;){var n=Zc;switch(n.tag){case 0:case 11:case 15:Fc(8,n,t);break;case 23:case 22:if(n.memoizedState!==null&&n.memoizedState.cachePool!==null){var r=n.memoizedState.cachePool.pool;r!=null&&r.refCount++}break;case 24:$i(n.memoizedState.cache)}if(r=n.child,r!==null)r.return=n,Zc=r;else a:for(n=e;Zc!==null;){r=Zc;var i=r.sibling,a=r.return;if(el(r),r===n){Zc=null;break a}if(i!==null){i.return=a,Zc=i;break a}Zc=a}}}var jl={getCacheForType:function(e){var t=Gi(Zi),n=t.data.get(e);return n===void 0&&(n=e(),t.data.set(e,n)),n},cacheSignal:function(){return Gi(Zi).controller.signal}},Ml=typeof WeakMap==`function`?WeakMap:Map,Nl=0,Pl=null,Q=null,Fl=0,Il=0,Ll=null,Rl=!1,zl=!1,Bl=!1,Vl=0,Hl=0,Ul=0,Wl=0,Gl=0,Kl=0,ql=0,Jl=null,Yl=null,Xl=!1,Zl=0,Ql=0,$l=1/0,eu=null,tu=null,nu=0,ru=null,iu=null,au=0,ou=0,su=null,cu=null,lu=0,uu=null;function du(){return Nl&2&&Fl!==0?Fl&-Fl:F.T===null?Xe():ud()}function fu(){if(Kl===0)if(!(Fl&536870912)||J){var e=Le;Le<<=1,!(Le&3932160)&&(Le=262144),Kl=e}else Kl=536870912;return e=qa.current,e!==null&&(e.flags|=32),Kl}function pu(e,t,n){(e===Pl&&(Il===2||Il===9)||e.cancelPendingCommit!==null)&&(bu(e,0),_u(e,Fl,Kl,!1)),Ue(e,n),(!(Nl&2)||e!==Pl)&&(e===Pl&&(!(Nl&2)&&(Wl|=n),Hl===4&&_u(e,Fl,Kl,!1)),nd(e))}function mu(e,t,n){if(Nl&6)throw Error(a(327));var r=!n&&(t&127)==0&&(t&e.expiredLanes)===0||G(e,t),i=r?Ou(e,t):Eu(e,t,!0),o=r;do{if(i===0){zl&&!r&&_u(e,t,0,!1);break}else{if(n=e.current.alternate,o&&!gu(n)){i=Eu(e,t,!1),o=!1;continue}if(i===2){if(o=t,e.errorRecoveryDisabledLanes&o)var s=0;else s=e.pendingLanes&-536870913,s=s===0?s&536870912?536870912:0:s;if(s!==0){t=s;a:{var c=e;i=Jl;var l=c.current.memoizedState.isDehydrated;if(l&&(bu(c,s).flags|=256),s=Eu(c,s,!1),s!==2){if(Bl&&!l){c.errorRecoveryDisabledLanes|=o,Wl|=o,i=4;break a}o=Yl,Yl=i,o!==null&&(Yl===null?Yl=o:Yl.push.apply(Yl,o))}i=s}if(o=!1,i!==2)continue}}if(i===1){bu(e,0),_u(e,t,0,!0);break}a:{switch(r=e,o=i,o){case 0:case 1:throw Error(a(345));case 4:if((t&4194048)!==t)break;case 6:_u(r,t,Kl,!Rl);break a;case 2:Yl=null;break;case 3:case 5:break;default:throw Error(a(329))}if((t&62914560)===t&&(i=Zl+300-ye(),10<i)){if(_u(r,t,Kl,!Rl),ze(r,0,!0)!==0)break a;au=t,r.timeoutHandle=Kd(hu.bind(null,r,n,Yl,eu,Xl,t,Kl,Wl,ql,Rl,o,`Throttled`,-0,0),i);break a}hu(r,n,Yl,eu,Xl,t,Kl,Wl,ql,Rl,o,null,-0,0)}}break}while(1);nd(e)}function hu(e,t,n,r,i,a,o,s,c,l,u,d,f,p){if(e.timeoutHandle=-1,d=t.subtreeFlags,d&8192||(d&16785408)==16785408){d={stylesheets:null,count:0,imgCount:0,imgBytes:0,suspenseyImages:[],waitingForImages:!0,waitingForViewTransition:!1,unsuspend:Kt},Tl(t,a,d);var m=(a&62914560)===a?Zl-ye():(a&4194048)===a?Ql-ye():0;if(m=qf(d,m),m!==null){au=a,e.cancelPendingCommit=m(Fu.bind(null,e,t,a,n,r,i,o,s,c,u,d,null,f,p)),_u(e,a,o,!l);return}}Fu(e,t,a,n,r,i,o,s,c)}function gu(e){for(var t=e;;){var n=t.tag;if((n===0||n===11||n===15)&&t.flags&16384&&(n=t.updateQueue,n!==null&&(n=n.stores,n!==null)))for(var r=0;r<n.length;r++){var i=n[r],a=i.getSnapshot;i=i.value;try{if(!pr(a(),i))return!1}catch{return!1}}if(n=t.child,t.subtreeFlags&16384&&n!==null)n.return=t,t=n;else{if(t===e)break;for(;t.sibling===null;){if(t.return===null||t.return===e)return!0;t=t.return}t.sibling.return=t.return,t=t.sibling}}return!0}function _u(e,t,n,r){t&=~Gl,t&=~Wl,e.suspendedLanes|=t,e.pingedLanes&=~t,r&&(e.warmLanes|=t),r=e.expirationTimes;for(var i=t;0<i;){var a=31-je(i),o=1<<a;r[a]=-1,i&=~o}n!==0&&Ge(e,n,t)}function vu(){return Nl&6?!0:(rd(0,!1),!1)}function yu(){if(Q!==null){if(Il===0)var e=Q.return;else e=Q,Li=Ii=null,xo(e),Sa=null,Ca=0,e=Q;for(;e!==null;)Nc(e.alternate,e),e=e.return;Q=null}}function bu(e,t){var n=e.timeoutHandle;n!==-1&&(e.timeoutHandle=-1,qd(n)),n=e.cancelPendingCommit,n!==null&&(e.cancelPendingCommit=null,n()),au=0,yu(),Pl=e,Q=n=ti(e.current,null),Fl=t,Il=0,Ll=null,Rl=!1,zl=G(e,t),Bl=!1,ql=Kl=Gl=Wl=Ul=Hl=0,Yl=Jl=null,Xl=!1,t&8&&(t|=t&32);var r=e.entangledLanes;if(r!==0)for(e=e.entanglements,r&=t;0<r;){var i=31-je(r),a=1<<i;t|=e[i],r&=~a}return Vl=t,Gr(),n}function xu(e,t){X=null,F.H=As,t===fa||t===ma?(t=ba(),Il=3):t===pa?(t=ba(),Il=4):Il=t===Js?8:typeof t==`object`&&t&&typeof t.then==`function`?6:1,Ll=t,Q===null&&(Hl=1,Hs(e,li(t,e.current)))}function Su(){var e=qa.current;return e===null?!0:(Fl&4194048)===Fl?Ja===null:(Fl&62914560)===Fl||Fl&536870912?e===Ja:!1}function Cu(){var e=F.H;return F.H=As,e===null?As:e}function wu(){var e=F.A;return F.A=jl,e}function Tu(){Hl=4,Rl||(Fl&4194048)!==Fl&&qa.current!==null||(zl=!0),!(Ul&134217727)&&!(Wl&134217727)||Pl===null||_u(Pl,Fl,Kl,!1)}function Eu(e,t,n){var r=Nl;Nl|=2;var i=Cu(),a=wu();(Pl!==e||Fl!==t)&&(eu=null,bu(e,t)),t=!1;var o=Hl;a:do try{if(Il!==0&&Q!==null){var s=Q,c=Ll;switch(Il){case 8:yu(),o=6;break a;case 3:case 2:case 9:case 6:qa.current===null&&(t=!0);var l=Il;if(Il=0,Ll=null,Mu(e,s,c,l),n&&zl){o=0;break a}break;default:l=Il,Il=0,Ll=null,Mu(e,s,c,l)}}Du(),o=Hl;break}catch(t){xu(e,t)}while(1);return t&&e.shellSuspendCounter++,Li=Ii=null,Nl=r,F.H=i,F.A=a,Q===null&&(Pl=null,Fl=0,Gr()),o}function Du(){for(;Q!==null;)Au(Q)}function Ou(e,t){var n=Nl;Nl|=2;var r=Cu(),i=wu();Pl!==e||Fl!==t?(eu=null,$l=ye()+500,bu(e,t)):zl=G(e,t);a:do try{if(Il!==0&&Q!==null){t=Q;var o=Ll;b:switch(Il){case 1:Il=0,Ll=null,Mu(e,t,o,1);break;case 2:case 9:if(ga(o)){Il=0,Ll=null,ju(t);break}t=function(){Il!==2&&Il!==9||Pl!==e||(Il=7),nd(e)},o.then(t,t);break a;case 3:Il=7;break a;case 4:Il=5;break a;case 7:ga(o)?(Il=0,Ll=null,ju(t)):(Il=0,Ll=null,Mu(e,t,o,7));break;case 5:var s=null;switch(Q.tag){case 26:s=Q.memoizedState;case 5:case 27:var c=Q;if(s?Wf(s):c.stateNode.complete){Il=0,Ll=null;var l=c.sibling;if(l!==null)Q=l;else{var u=c.return;u===null?Q=null:(Q=u,Nu(u))}break b}}Il=0,Ll=null,Mu(e,t,o,5);break;case 6:Il=0,Ll=null,Mu(e,t,o,6);break;case 8:yu(),Hl=6;break a;default:throw Error(a(462))}}ku();break}catch(t){xu(e,t)}while(1);return Li=Ii=null,F.H=r,F.A=i,Nl=n,Q===null?(Pl=null,Fl=0,Gr(),Hl):0}function ku(){for(;Q!==null&&!_e();)Au(Q)}function Au(e){var t=wc(e.alternate,e,Vl);e.memoizedProps=e.pendingProps,t===null?Nu(e):Q=t}function ju(e){var t=e,n=t.alternate;switch(t.tag){case 15:case 0:t=cc(n,t,t.pendingProps,t.type,void 0,Fl);break;case 11:t=cc(n,t,t.pendingProps,t.type.render,t.ref,Fl);break;case 5:xo(t);default:Nc(n,t),t=Q=ni(t,Vl),t=wc(n,t,Vl)}e.memoizedProps=e.pendingProps,t===null?Nu(e):Q=t}function Mu(e,t,n,r){Li=Ii=null,xo(t),Sa=null,Ca=0;var i=t.return;try{if(qs(e,i,t,n,Fl)){Hl=1,Hs(e,li(n,e.current)),Q=null;return}}catch(t){if(i!==null)throw Q=i,t;Hl=1,Hs(e,li(n,e.current)),Q=null;return}t.flags&32768?(J||r===1?e=!0:zl||Fl&536870912?e=!1:(Rl=e=!0,(r===2||r===9||r===3||r===6)&&(r=qa.current,r!==null&&r.tag===13&&(r.flags|=16384))),Pu(t,e)):Nu(t)}function Nu(e){var t=e;do{if(t.flags&32768){Pu(t,Rl);return}e=t.return;var n=jc(t.alternate,t,Vl);if(n!==null){Q=n;return}if(t=t.sibling,t!==null){Q=t;return}Q=t=e}while(t!==null);Hl===0&&(Hl=5)}function Pu(e,t){do{var n=Mc(e.alternate,e);if(n!==null){n.flags&=32767,Q=n;return}if(n=e.return,n!==null&&(n.flags|=32768,n.subtreeFlags=0,n.deletions=null),!t&&(e=e.sibling,e!==null)){Q=e;return}Q=e=n}while(e!==null);Hl=6,Q=null}function Fu(e,t,n,r,i,o,s,c,l){e.cancelPendingCommit=null;do Bu();while(nu!==0);if(Nl&6)throw Error(a(327));if(t!==null){if(t===e.current)throw Error(a(177));if(o=t.lanes|t.childLanes,o|=Wr,We(e,n,o,s,c,l),e===Pl&&(Q=Pl=null,Fl=0),iu=t,ru=e,au=n,ou=o,su=i,cu=r,t.subtreeFlags&10256||t.flags&10256?(e.callbackNode=null,e.callbackPriority=0,Yu(Ce,function(){return Vu(),null})):(e.callbackNode=null,e.callbackPriority=0),r=(t.flags&13878)!=0,t.subtreeFlags&13878||r){r=F.T,F.T=null,i=I.p,I.p=2,s=Nl,Nl|=4;try{Qc(e,t,n)}finally{Nl=s,I.p=i,F.T=r}}nu=1,Iu(),Lu(),Ru()}}function Iu(){if(nu===1){nu=0;var e=ru,t=iu,n=(t.flags&13878)!=0;if(t.subtreeFlags&13878||n){n=F.T,F.T=null;var r=I.p;I.p=2;var i=Nl;Nl|=4;try{dl(t,e);var a=zd,o=vr(e.containerInfo),s=a.focusedElem,c=a.selectionRange;if(o!==s&&s&&s.ownerDocument&&_r(s.ownerDocument.documentElement,s)){if(c!==null&&yr(s)){var l=c.start,u=c.end;if(u===void 0&&(u=l),`selectionStart`in s)s.selectionStart=l,s.selectionEnd=Math.min(u,s.value.length);else{var d=s.ownerDocument||document,f=d&&d.defaultView||window;if(f.getSelection){var p=f.getSelection(),m=s.textContent.length,h=Math.min(c.start,m),g=c.end===void 0?h:Math.min(c.end,m);!p.extend&&h>g&&(o=g,g=h,h=o);var _=gr(s,h),v=gr(s,g);if(_&&v&&(p.rangeCount!==1||p.anchorNode!==_.node||p.anchorOffset!==_.offset||p.focusNode!==v.node||p.focusOffset!==v.offset)){var y=d.createRange();y.setStart(_.node,_.offset),p.removeAllRanges(),h>g?(p.addRange(y),p.extend(v.node,v.offset)):(y.setEnd(v.node,v.offset),p.addRange(y))}}}}for(d=[],p=s;p=p.parentNode;)p.nodeType===1&&d.push({element:p,left:p.scrollLeft,top:p.scrollTop});for(typeof s.focus==`function`&&s.focus(),s=0;s<d.length;s++){var b=d[s];b.element.scrollLeft=b.left,b.element.scrollTop=b.top}}sp=!!Rd,zd=Rd=null}finally{Nl=i,I.p=r,F.T=n}}e.current=t,nu=2}}function Lu(){if(nu===2){nu=0;var e=ru,t=iu,n=(t.flags&8772)!=0;if(t.subtreeFlags&8772||n){n=F.T,F.T=null;var r=I.p;I.p=2;var i=Nl;Nl|=4;try{$c(e,t.alternate,t)}finally{Nl=i,I.p=r,F.T=n}}nu=3}}function Ru(){if(nu===4||nu===3){nu=0,ve();var e=ru,t=iu,n=au,r=cu;t.subtreeFlags&10256||t.flags&10256?nu=5:(nu=0,iu=ru=null,zu(e,e.pendingLanes));var i=e.pendingLanes;if(i===0&&(tu=null),Ye(n),t=t.stateNode,ke&&typeof ke.onCommitFiberRoot==`function`)try{ke.onCommitFiberRoot(Oe,t,void 0,(t.current.flags&128)==128)}catch{}if(r!==null){t=F.T,i=I.p,I.p=2,F.T=null;try{for(var a=e.onRecoverableError,o=0;o<r.length;o++){var s=r[o];a(s.value,{componentStack:s.stack})}}finally{F.T=t,I.p=i}}au&3&&Bu(),nd(e),i=e.pendingLanes,n&261930&&i&42?e===uu?lu++:(lu=0,uu=e):lu=0,rd(0,!1)}}function zu(e,t){(e.pooledCacheLanes&=t)===0&&(t=e.pooledCache,t!=null&&(e.pooledCache=null,$i(t)))}function Bu(){return Iu(),Lu(),Ru(),Vu()}function Vu(){if(nu!==5)return!1;var e=ru,t=ou;ou=0;var n=Ye(au),r=F.T,i=I.p;try{I.p=32>n?32:n,F.T=null,n=su,su=null;var o=ru,s=au;if(nu=0,iu=ru=null,au=0,Nl&6)throw Error(a(331));var c=Nl;if(Nl|=4,Ol(o.current),bl(o,o.current,s,n),Nl=c,rd(0,!1),ke&&typeof ke.onPostCommitFiberRoot==`function`)try{ke.onPostCommitFiberRoot(Oe,o)}catch{}return!0}finally{I.p=i,F.T=r,zu(e,t)}}function Hu(e,t,n){t=li(n,t),t=Ws(e.stateNode,t,2),e=Pa(e,t,2),e!==null&&(Ue(e,2),nd(e))}function Uu(e,t,n){if(e.tag===3)Hu(e,e,n);else for(;t!==null;){if(t.tag===3){Hu(t,e,n);break}else if(t.tag===1){var r=t.stateNode;if(typeof t.type.getDerivedStateFromError==`function`||typeof r.componentDidCatch==`function`&&(tu===null||!tu.has(r))){e=li(n,e),n=Gs(2),r=Pa(t,n,2),r!==null&&(Ks(n,r,t,e),Ue(r,2),nd(r));break}}t=t.return}}function Wu(e,t,n){var r=e.pingCache;if(r===null){r=e.pingCache=new Ml;var i=new Set;r.set(t,i)}else i=r.get(t),i===void 0&&(i=new Set,r.set(t,i));i.has(n)||(Bl=!0,i.add(n),e=Gu.bind(null,e,t,n),t.then(e,e))}function Gu(e,t,n){var r=e.pingCache;r!==null&&r.delete(t),e.pingedLanes|=e.suspendedLanes&n,e.warmLanes&=~n,Pl===e&&(Fl&n)===n&&(Hl===4||Hl===3&&(Fl&62914560)===Fl&&300>ye()-Zl?!(Nl&2)&&bu(e,0):Gl|=n,ql===Fl&&(ql=0)),nd(e)}function Ku(e,t){t===0&&(t=Ve()),e=Jr(e,t),e!==null&&(Ue(e,t),nd(e))}function qu(e){var t=e.memoizedState,n=0;t!==null&&(n=t.retryLane),Ku(e,n)}function Ju(e,t){var n=0;switch(e.tag){case 31:case 13:var r=e.stateNode,i=e.memoizedState;i!==null&&(n=i.retryLane);break;case 19:r=e.stateNode;break;case 22:r=e.stateNode._retryCache;break;default:throw Error(a(314))}r!==null&&r.delete(t),Ku(e,n)}function Yu(e,t){return he(e,t)}var Xu=null,Zu=null,Qu=!1,$u=!1,ed=!1,td=0;function nd(e){e!==Zu&&e.next===null&&(Zu===null?Xu=Zu=e:Zu=Zu.next=e),$u=!0,Qu||(Qu=!0,ld())}function rd(e,t){if(!ed&&$u){ed=!0;do for(var n=!1,r=Xu;r!==null;){if(!t)if(e!==0){var i=r.pendingLanes;if(i===0)var a=0;else{var o=r.suspendedLanes,s=r.pingedLanes;a=(1<<31-je(42|e)+1)-1,a&=i&~(o&~s),a=a&201326741?a&201326741|1:a?a|2:0}a!==0&&(n=!0,cd(r,a))}else a=Fl,a=ze(r,r===Pl?a:0,r.cancelPendingCommit!==null||r.timeoutHandle!==-1),!(a&3)||G(r,a)||(n=!0,cd(r,a));r=r.next}while(n);ed=!1}}function id(){ad()}function ad(){$u=Qu=!1;var e=0;td!==0&&Gd()&&(e=td);for(var t=ye(),n=null,r=Xu;r!==null;){var i=r.next,a=od(r,t);a===0?(r.next=null,n===null?Xu=i:n.next=i,i===null&&(Zu=n)):(n=r,(e!==0||a&3)&&($u=!0)),r=i}nu!==0&&nu!==5||rd(e,!1),td!==0&&(td=0)}function od(e,t){for(var n=e.suspendedLanes,r=e.pingedLanes,i=e.expirationTimes,a=e.pendingLanes&-62914561;0<a;){var o=31-je(a),s=1<<o,c=i[o];c===-1?((s&n)===0||(s&r)!==0)&&(i[o]=Be(s,t)):c<=t&&(e.expiredLanes|=s),a&=~s}if(t=Pl,n=Fl,n=ze(e,e===t?n:0,e.cancelPendingCommit!==null||e.timeoutHandle!==-1),r=e.callbackNode,n===0||e===t&&(Il===2||Il===9)||e.cancelPendingCommit!==null)return r!==null&&r!==null&&ge(r),e.callbackNode=null,e.callbackPriority=0;if(!(n&3)||G(e,n)){if(t=n&-n,t===e.callbackPriority)return t;switch(r!==null&&ge(r),Ye(n)){case 2:case 8:n=Se;break;case 32:n=Ce;break;case 268435456:n=Te;break;default:n=Ce}return r=sd.bind(null,e),n=he(n,r),e.callbackPriority=t,e.callbackNode=n,t}return r!==null&&r!==null&&ge(r),e.callbackPriority=2,e.callbackNode=null,2}function sd(e,t){if(nu!==0&&nu!==5)return e.callbackNode=null,e.callbackPriority=0,null;var n=e.callbackNode;if(Bu()&&e.callbackNode!==n)return null;var r=Fl;return r=ze(e,e===Pl?r:0,e.cancelPendingCommit!==null||e.timeoutHandle!==-1),r===0?null:(mu(e,r,t),od(e,ye()),e.callbackNode!=null&&e.callbackNode===n?sd.bind(null,e):null)}function cd(e,t){if(Bu())return null;mu(e,t,!0)}function ld(){Yd(function(){Nl&6?he(xe,id):ad()})}function ud(){if(td===0){var e=na;e===0&&(e=Fe,Fe<<=1,!(Fe&261888)&&(Fe=256)),td=e}return td}function dd(e){return e==null||typeof e==`symbol`||typeof e==`boolean`?null:typeof e==`function`?e:Gt(``+e)}function fd(e,t){var n=t.ownerDocument.createElement(`input`);return n.name=t.name,n.value=t.value,e.id&&n.setAttribute(`form`,e.id),t.parentNode.insertBefore(n,t),e=new FormData(e),n.parentNode.removeChild(n),e}function pd(e,t,n,r,i){if(t===`submit`&&n&&n.stateNode===i){var a=dd((i[et]||null).action),o=r.submitter;o&&(t=(t=o[et]||null)?dd(t.formAction):o.getAttribute(`formAction`),t!==null&&(a=t,o=null));var s=new K(`action`,`action`,null,r,i);e.push({event:s,listeners:[{instance:null,listener:function(){if(r.defaultPrevented){if(td!==0){var e=o?fd(i,o):new FormData(i);_s(n,{pending:!0,data:e,method:i.method,action:a},null,e)}}else typeof a==`function`&&(s.preventDefault(),e=o?fd(i,o):new FormData(i),_s(n,{pending:!0,data:e,method:i.method,action:a},a,e))},currentTarget:i}]})}}for(var md=0;md<zr.length;md++){var hd=zr[md];Br(hd.toLowerCase(),`on`+(hd[0].toUpperCase()+hd.slice(1)))}Br(jr,`onAnimationEnd`),Br(Mr,`onAnimationIteration`),Br(Nr,`onAnimationStart`),Br(`dblclick`,`onDoubleClick`),Br(`focusin`,`onFocus`),Br(`focusout`,`onBlur`),Br(Pr,`onTransitionRun`),Br(Fr,`onTransitionStart`),Br(Ir,`onTransitionCancel`),Br(Lr,`onTransitionEnd`),gt(`onMouseEnter`,[`mouseout`,`mouseover`]),gt(`onMouseLeave`,[`mouseout`,`mouseover`]),gt(`onPointerEnter`,[`pointerout`,`pointerover`]),gt(`onPointerLeave`,[`pointerout`,`pointerover`]),ht(`onChange`,`change click focusin focusout input keydown keyup selectionchange`.split(` `)),ht(`onSelect`,`focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange`.split(` `)),ht(`onBeforeInput`,[`compositionend`,`keypress`,`textInput`,`paste`]),ht(`onCompositionEnd`,`compositionend focusout keydown keypress keyup mousedown`.split(` `)),ht(`onCompositionStart`,`compositionstart focusout keydown keypress keyup mousedown`.split(` `)),ht(`onCompositionUpdate`,`compositionupdate focusout keydown keypress keyup mousedown`.split(` `));var gd=`abort canplay canplaythrough durationchange emptied encrypted ended error loadeddata loadedmetadata loadstart pause play playing progress ratechange resize seeked seeking stalled suspend timeupdate volumechange waiting`.split(` `),_d=new Set(`beforetoggle cancel close invalid load scroll scrollend toggle`.split(` `).concat(gd));function vd(e,t){t=(t&4)!=0;for(var n=0;n<e.length;n++){var r=e[n],i=r.event;r=r.listeners;a:{var a=void 0;if(t)for(var o=r.length-1;0<=o;o--){var s=r[o],c=s.instance,l=s.currentTarget;if(s=s.listener,c!==a&&i.isPropagationStopped())break a;a=s,i.currentTarget=l;try{a(i)}catch(e){Vr(e)}i.currentTarget=null,a=c}else for(o=0;o<r.length;o++){if(s=r[o],c=s.instance,l=s.currentTarget,s=s.listener,c!==a&&i.isPropagationStopped())break a;a=s,i.currentTarget=l;try{a(i)}catch(e){Vr(e)}i.currentTarget=null,a=c}}}}function $(e,t){var n=t[nt];n===void 0&&(n=t[nt]=new Set);var r=e+`__bubble`;n.has(r)||(Sd(t,e,2,!1),n.add(r))}function yd(e,t,n){var r=0;t&&(r|=4),Sd(n,e,r,t)}var bd=`_reactListening`+Math.random().toString(36).slice(2);function xd(e){if(!e[bd]){e[bd]=!0,pt.forEach(function(t){t!==`selectionchange`&&(_d.has(t)||yd(t,!1,e),yd(t,!0,e))});var t=e.nodeType===9?e:e.ownerDocument;t===null||t[bd]||(t[bd]=!0,yd(`selectionchange`,!1,t))}}function Sd(e,t,n,r){switch(mp(t)){case 2:var i=cp;break;case 8:i=lp;break;default:i=up}n=i.bind(null,t,n,e),i=void 0,!nn||t!==`touchstart`&&t!==`touchmove`&&t!==`wheel`||(i=!0),r?i===void 0?e.addEventListener(t,n,!0):e.addEventListener(t,n,{capture:!0,passive:i}):i===void 0?e.addEventListener(t,n,!1):e.addEventListener(t,n,{passive:i})}function Cd(e,t,n,r,i){var a=r;if(!(t&1)&&!(t&2)&&r!==null)a:for(;;){if(r===null)return;var o=r.tag;if(o===3||o===4){var c=r.stateNode.containerInfo;if(c===i)break;if(o===4)for(o=r.return;o!==null;){var l=o.tag;if((l===3||l===4)&&o.stateNode.containerInfo===i)return;o=o.return}for(;c!==null;){if(o=ct(c),o===null)return;if(l=o.tag,l===5||l===6||l===26||l===27){r=a=o;continue a}c=c.parentNode}}r=r.return}$t(function(){var r=a,i=Jt(n),o=[];a:{var c=Rr.get(e);if(c!==void 0){var l=K,u=e;switch(e){case`keypress`:if(ln(n)===0)break a;case`keydown`:case`keyup`:l=An;break;case`focusin`:u=`focus`,l=xn;break;case`focusout`:u=`blur`,l=xn;break;case`beforeblur`:case`afterblur`:l=xn;break;case`click`:if(n.button===2)break a;case`auxclick`:case`dblclick`:case`mousedown`:case`mousemove`:case`mouseup`:case`mouseout`:case`mouseover`:case`contextmenu`:l=yn;break;case`drag`:case`dragend`:case`dragenter`:case`dragexit`:case`dragleave`:case`dragover`:case`dragstart`:case`drop`:l=bn;break;case`touchcancel`:case`touchend`:case`touchmove`:case`touchstart`:l=Mn;break;case jr:case Mr:case Nr:l=Sn;break;case Lr:l=Nn;break;case`scroll`:case`scrollend`:l=hn;break;case`wheel`:l=Pn;break;case`copy`:case`cut`:case`paste`:l=Cn;break;case`gotpointercapture`:case`lostpointercapture`:case`pointercancel`:case`pointerdown`:case`pointermove`:case`pointerout`:case`pointerover`:case`pointerup`:l=jn;break;case`toggle`:case`beforetoggle`:l=Fn}var d=(t&4)!=0,f=!d&&(e===`scroll`||e===`scrollend`),p=d?c===null?null:c+`Capture`:c;d=[];for(var m=r,h;m!==null;){var g=m;if(h=g.stateNode,g=g.tag,g!==5&&g!==26&&g!==27||h===null||p===null||(g=en(m,p),g!=null&&d.push(wd(m,g,h))),f)break;m=m.return}0<d.length&&(c=new l(c,u,null,n,i),o.push({event:c,listeners:d}))}}if(!(t&7)){a:{if(c=e===`mouseover`||e===`pointerover`,l=e===`mouseout`||e===`pointerout`,c&&n!==qt&&(u=n.relatedTarget||n.fromElement)&&(ct(u)||u[tt]))break a;if((l||c)&&(c=i.window===i?i:(c=i.ownerDocument)?c.defaultView||c.parentWindow:window,l?(u=n.relatedTarget||n.toElement,l=r,u=u?ct(u):null,u!==null&&(f=s(u),d=u.tag,u!==f||d!==5&&d!==27&&d!==6)&&(u=null)):(l=null,u=r),l!==u)){if(d=yn,g=`onMouseLeave`,p=`onMouseEnter`,m=`mouse`,(e===`pointerout`||e===`pointerover`)&&(d=jn,g=`onPointerLeave`,p=`onPointerEnter`,m=`pointer`),f=l==null?c:ut(l),h=u==null?c:ut(u),c=new d(g,m+`leave`,l,n,i),c.target=f,c.relatedTarget=h,g=null,ct(i)===r&&(d=new d(p,m+`enter`,u,n,i),d.target=h,d.relatedTarget=f,g=d),f=g,l&&u)b:{for(d=Ed,p=l,m=u,h=0,g=p;g;g=d(g))h++;g=0;for(var _=m;_;_=d(_))g++;for(;0<h-g;)p=d(p),h--;for(;0<g-h;)m=d(m),g--;for(;h--;){if(p===m||m!==null&&p===m.alternate){d=p;break b}p=d(p),m=d(m)}d=null}else d=null;l!==null&&Dd(o,c,l,d,!1),u!==null&&f!==null&&Dd(o,f,u,d,!0)}}a:{if(c=r?ut(r):window,l=c.nodeName&&c.nodeName.toLowerCase(),l===`select`||l===`input`&&c.type===`file`)var v=tr;else if(Yn(c))if(nr)v=dr;else{v=lr;var y=cr}else l=c.nodeName,!l||l.toLowerCase()!==`input`||c.type!==`checkbox`&&c.type!==`radio`?r&&Ht(r.elementType)&&(v=tr):v=ur;if(v&&=v(e,r)){Xn(o,v,n,i);break a}y&&y(e,c,r),e===`focusout`&&r&&c.type===`number`&&r.memoizedProps.value!=null&&Pt(c,`number`,c.value)}switch(y=r?ut(r):window,e){case`focusin`:(Yn(y)||y.contentEditable===`true`)&&(xr=y,Sr=r,Cr=null);break;case`focusout`:Cr=Sr=xr=null;break;case`mousedown`:wr=!0;break;case`contextmenu`:case`mouseup`:case`dragend`:wr=!1,Tr(o,n,i);break;case`selectionchange`:if(br)break;case`keydown`:case`keyup`:Tr(o,n,i)}var b;if(Ln)b:{switch(e){case`compositionstart`:var x=`onCompositionStart`;break b;case`compositionend`:x=`onCompositionEnd`;break b;case`compositionupdate`:x=`onCompositionUpdate`;break b}x=void 0}else Gn?Un(e,n)&&(x=`onCompositionEnd`):e===`keydown`&&n.keyCode===229&&(x=`onCompositionStart`);x&&(Bn&&n.locale!==`ko`&&(Gn||x!==`onCompositionStart`?x===`onCompositionEnd`&&Gn&&(b=cn()):(an=i,on=`value`in an?an.value:an.textContent,Gn=!0)),y=Td(r,x),0<y.length&&(x=new wn(x,e,null,n,i),o.push({event:x,listeners:y}),b?x.data=b:(b=Wn(n),b!==null&&(x.data=b)))),(b=zn?Kn(e,n):qn(e,n))&&(x=Td(r,`onBeforeInput`),0<x.length&&(y=new wn(`onBeforeInput`,`beforeinput`,null,n,i),o.push({event:y,listeners:x}),y.data=b)),pd(o,e,r,n,i)}vd(o,t)})}function wd(e,t,n){return{instance:e,listener:t,currentTarget:n}}function Td(e,t){for(var n=t+`Capture`,r=[];e!==null;){var i=e,a=i.stateNode;if(i=i.tag,i!==5&&i!==26&&i!==27||a===null||(i=en(e,n),i!=null&&r.unshift(wd(e,i,a)),i=en(e,t),i!=null&&r.push(wd(e,i,a))),e.tag===3)return r;e=e.return}return[]}function Ed(e){if(e===null)return null;do e=e.return;while(e&&e.tag!==5&&e.tag!==27);return e||null}function Dd(e,t,n,r,i){for(var a=t._reactName,o=[];n!==null&&n!==r;){var s=n,c=s.alternate,l=s.stateNode;if(s=s.tag,c!==null&&c===r)break;s!==5&&s!==26&&s!==27||l===null||(c=l,i?(l=en(n,a),l!=null&&o.unshift(wd(n,l,c))):i||(l=en(n,a),l!=null&&o.push(wd(n,l,c)))),n=n.return}o.length!==0&&e.push({event:t,listeners:o})}var Od=/\r\n?/g,kd=/\u0000|\uFFFD/g;function Ad(e){return(typeof e==`string`?e:``+e).replace(Od,`
- `).replace(kd,``)}function jd(e,t){return t=Ad(t),Ad(e)===t}function Md(e,t,n,r,i,o){switch(n){case`children`:typeof r==`string`?t===`body`||t===`textarea`&&r===``||Rt(e,r):(typeof r==`number`||typeof r==`bigint`)&&t!==`body`&&Rt(e,``+r);break;case`className`:St(e,`class`,r);break;case`tabIndex`:St(e,`tabindex`,r);break;case`dir`:case`role`:case`viewBox`:case`width`:case`height`:St(e,n,r);break;case`style`:Vt(e,r,o);break;case`data`:if(t!==`object`){St(e,`data`,r);break}case`src`:case`href`:if(r===``&&(t!==`a`||n!==`href`)){e.removeAttribute(n);break}if(r==null||typeof r==`function`||typeof r==`symbol`||typeof r==`boolean`){e.removeAttribute(n);break}r=Gt(``+r),e.setAttribute(n,r);break;case`action`:case`formAction`:if(typeof r==`function`){e.setAttribute(n,`javascript:throw new Error('A React form was unexpectedly submitted. If you called form.submit() manually, consider using form.requestSubmit() instead. If you\\'re trying to use event.stopPropagation() in a submit event handler, consider also calling event.preventDefault().')`);break}else typeof o==`function`&&(n===`formAction`?(t!==`input`&&Md(e,t,`name`,i.name,i,null),Md(e,t,`formEncType`,i.formEncType,i,null),Md(e,t,`formMethod`,i.formMethod,i,null),Md(e,t,`formTarget`,i.formTarget,i,null)):(Md(e,t,`encType`,i.encType,i,null),Md(e,t,`method`,i.method,i,null),Md(e,t,`target`,i.target,i,null)));if(r==null||typeof r==`symbol`||typeof r==`boolean`){e.removeAttribute(n);break}r=Gt(``+r),e.setAttribute(n,r);break;case`onClick`:r!=null&&(e.onclick=Kt);break;case`onScroll`:r!=null&&$(`scroll`,e);break;case`onScrollEnd`:r!=null&&$(`scrollend`,e);break;case`dangerouslySetInnerHTML`:if(r!=null){if(typeof r!=`object`||!(`__html`in r))throw Error(a(61));if(n=r.__html,n!=null){if(i.children!=null)throw Error(a(60));e.innerHTML=n}}break;case`multiple`:e.multiple=r&&typeof r!=`function`&&typeof r!=`symbol`;break;case`muted`:e.muted=r&&typeof r!=`function`&&typeof r!=`symbol`;break;case`suppressContentEditableWarning`:case`suppressHydrationWarning`:case`defaultValue`:case`defaultChecked`:case`innerHTML`:case`ref`:break;case`autoFocus`:break;case`xlinkHref`:if(r==null||typeof r==`function`||typeof r==`boolean`||typeof r==`symbol`){e.removeAttribute(`xlink:href`);break}n=Gt(``+r),e.setAttributeNS(`http://www.w3.org/1999/xlink`,`xlink:href`,n);break;case`contentEditable`:case`spellCheck`:case`draggable`:case`value`:case`autoReverse`:case`externalResourcesRequired`:case`focusable`:case`preserveAlpha`:r!=null&&typeof r!=`function`&&typeof r!=`symbol`?e.setAttribute(n,``+r):e.removeAttribute(n);break;case`inert`:case`allowFullScreen`:case`async`:case`autoPlay`:case`controls`:case`default`:case`defer`:case`disabled`:case`disablePictureInPicture`:case`disableRemotePlayback`:case`formNoValidate`:case`hidden`:case`loop`:case`noModule`:case`noValidate`:case`open`:case`playsInline`:case`readOnly`:case`required`:case`reversed`:case`scoped`:case`seamless`:case`itemScope`:r&&typeof r!=`function`&&typeof r!=`symbol`?e.setAttribute(n,``):e.removeAttribute(n);break;case`capture`:case`download`:!0===r?e.setAttribute(n,``):!1!==r&&r!=null&&typeof r!=`function`&&typeof r!=`symbol`?e.setAttribute(n,r):e.removeAttribute(n);break;case`cols`:case`rows`:case`size`:case`span`:r!=null&&typeof r!=`function`&&typeof r!=`symbol`&&!isNaN(r)&&1<=r?e.setAttribute(n,r):e.removeAttribute(n);break;case`rowSpan`:case`start`:r==null||typeof r==`function`||typeof r==`symbol`||isNaN(r)?e.removeAttribute(n):e.setAttribute(n,r);break;case`popover`:$(`beforetoggle`,e),$(`toggle`,e),xt(e,`popover`,r);break;case`xlinkActuate`:Ct(e,`http://www.w3.org/1999/xlink`,`xlink:actuate`,r);break;case`xlinkArcrole`:Ct(e,`http://www.w3.org/1999/xlink`,`xlink:arcrole`,r);break;case`xlinkRole`:Ct(e,`http://www.w3.org/1999/xlink`,`xlink:role`,r);break;case`xlinkShow`:Ct(e,`http://www.w3.org/1999/xlink`,`xlink:show`,r);break;case`xlinkTitle`:Ct(e,`http://www.w3.org/1999/xlink`,`xlink:title`,r);break;case`xlinkType`:Ct(e,`http://www.w3.org/1999/xlink`,`xlink:type`,r);break;case`xmlBase`:Ct(e,`http://www.w3.org/XML/1998/namespace`,`xml:base`,r);break;case`xmlLang`:Ct(e,`http://www.w3.org/XML/1998/namespace`,`xml:lang`,r);break;case`xmlSpace`:Ct(e,`http://www.w3.org/XML/1998/namespace`,`xml:space`,r);break;case`is`:xt(e,`is`,r);break;case`innerText`:case`textContent`:break;default:(!(2<n.length)||n[0]!==`o`&&n[0]!==`O`||n[1]!==`n`&&n[1]!==`N`)&&(n=Ut.get(n)||n,xt(e,n,r))}}function Nd(e,t,n,r,i,o){switch(n){case`style`:Vt(e,r,o);break;case`dangerouslySetInnerHTML`:if(r!=null){if(typeof r!=`object`||!(`__html`in r))throw Error(a(61));if(n=r.__html,n!=null){if(i.children!=null)throw Error(a(60));e.innerHTML=n}}break;case`children`:typeof r==`string`?Rt(e,r):(typeof r==`number`||typeof r==`bigint`)&&Rt(e,``+r);break;case`onScroll`:r!=null&&$(`scroll`,e);break;case`onScrollEnd`:r!=null&&$(`scrollend`,e);break;case`onClick`:r!=null&&(e.onclick=Kt);break;case`suppressContentEditableWarning`:case`suppressHydrationWarning`:case`innerHTML`:case`ref`:break;case`innerText`:case`textContent`:break;default:if(!mt.hasOwnProperty(n))a:{if(n[0]===`o`&&n[1]===`n`&&(i=n.endsWith(`Capture`),t=n.slice(2,i?n.length-7:void 0),o=e[et]||null,o=o==null?null:o[n],typeof o==`function`&&e.removeEventListener(t,o,i),typeof r==`function`)){typeof o!=`function`&&o!==null&&(n in e?e[n]=null:e.hasAttribute(n)&&e.removeAttribute(n)),e.addEventListener(t,r,i);break a}n in e?e[n]=r:!0===r?e.setAttribute(n,``):xt(e,n,r)}}}function Pd(e,t,n){switch(t){case`div`:case`span`:case`svg`:case`path`:case`a`:case`g`:case`p`:case`li`:break;case`img`:$(`error`,e),$(`load`,e);var r=!1,i=!1,o;for(o in n)if(n.hasOwnProperty(o)){var s=n[o];if(s!=null)switch(o){case`src`:r=!0;break;case`srcSet`:i=!0;break;case`children`:case`dangerouslySetInnerHTML`:throw Error(a(137,t));default:Md(e,t,o,s,n,null)}}i&&Md(e,t,`srcSet`,n.srcSet,n,null),r&&Md(e,t,`src`,n.src,n,null);return;case`input`:$(`invalid`,e);var c=o=s=i=null,l=null,u=null;for(r in n)if(n.hasOwnProperty(r)){var d=n[r];if(d!=null)switch(r){case`name`:i=d;break;case`type`:s=d;break;case`checked`:l=d;break;case`defaultChecked`:u=d;break;case`value`:o=d;break;case`defaultValue`:c=d;break;case`children`:case`dangerouslySetInnerHTML`:if(d!=null)throw Error(a(137,t));break;default:Md(e,t,r,d,n,null)}}Nt(e,o,c,l,u,s,i,!1);return;case`select`:for(i in $(`invalid`,e),r=s=o=null,n)if(n.hasOwnProperty(i)&&(c=n[i],c!=null))switch(i){case`value`:o=c;break;case`defaultValue`:s=c;break;case`multiple`:r=c;default:Md(e,t,i,c,n,null)}t=o,n=s,e.multiple=!!r,t==null?n!=null&&Ft(e,!!r,n,!0):Ft(e,!!r,t,!1);return;case`textarea`:for(s in $(`invalid`,e),o=i=r=null,n)if(n.hasOwnProperty(s)&&(c=n[s],c!=null))switch(s){case`value`:r=c;break;case`defaultValue`:i=c;break;case`children`:o=c;break;case`dangerouslySetInnerHTML`:if(c!=null)throw Error(a(91));break;default:Md(e,t,s,c,n,null)}Lt(e,r,i,o);return;case`option`:for(l in n)if(n.hasOwnProperty(l)&&(r=n[l],r!=null))switch(l){case`selected`:e.selected=r&&typeof r!=`function`&&typeof r!=`symbol`;break;default:Md(e,t,l,r,n,null)}return;case`dialog`:$(`beforetoggle`,e),$(`toggle`,e),$(`cancel`,e),$(`close`,e);break;case`iframe`:case`object`:$(`load`,e);break;case`video`:case`audio`:for(r=0;r<gd.length;r++)$(gd[r],e);break;case`image`:$(`error`,e),$(`load`,e);break;case`details`:$(`toggle`,e);break;case`embed`:case`source`:case`link`:$(`error`,e),$(`load`,e);case`area`:case`base`:case`br`:case`col`:case`hr`:case`keygen`:case`meta`:case`param`:case`track`:case`wbr`:case`menuitem`:for(u in n)if(n.hasOwnProperty(u)&&(r=n[u],r!=null))switch(u){case`children`:case`dangerouslySetInnerHTML`:throw Error(a(137,t));default:Md(e,t,u,r,n,null)}return;default:if(Ht(t)){for(d in n)n.hasOwnProperty(d)&&(r=n[d],r!==void 0&&Nd(e,t,d,r,n,void 0));return}}for(c in n)n.hasOwnProperty(c)&&(r=n[c],r!=null&&Md(e,t,c,r,n,null))}function Fd(e,t,n,r){switch(t){case`div`:case`span`:case`svg`:case`path`:case`a`:case`g`:case`p`:case`li`:break;case`input`:var i=null,o=null,s=null,c=null,l=null,u=null,d=null;for(m in n){var f=n[m];if(n.hasOwnProperty(m)&&f!=null)switch(m){case`checked`:break;case`value`:break;case`defaultValue`:l=f;default:r.hasOwnProperty(m)||Md(e,t,m,null,r,f)}}for(var p in r){var m=r[p];if(f=n[p],r.hasOwnProperty(p)&&(m!=null||f!=null))switch(p){case`type`:o=m;break;case`name`:i=m;break;case`checked`:u=m;break;case`defaultChecked`:d=m;break;case`value`:s=m;break;case`defaultValue`:c=m;break;case`children`:case`dangerouslySetInnerHTML`:if(m!=null)throw Error(a(137,t));break;default:m!==f&&Md(e,t,p,m,r,f)}}Mt(e,s,c,l,u,d,o,i);return;case`select`:for(o in m=s=c=p=null,n)if(l=n[o],n.hasOwnProperty(o)&&l!=null)switch(o){case`value`:break;case`multiple`:m=l;default:r.hasOwnProperty(o)||Md(e,t,o,null,r,l)}for(i in r)if(o=r[i],l=n[i],r.hasOwnProperty(i)&&(o!=null||l!=null))switch(i){case`value`:p=o;break;case`defaultValue`:c=o;break;case`multiple`:s=o;default:o!==l&&Md(e,t,i,o,r,l)}t=c,n=s,r=m,p==null?!!r!=!!n&&(t==null?Ft(e,!!n,n?[]:``,!1):Ft(e,!!n,t,!0)):Ft(e,!!n,p,!1);return;case`textarea`:for(c in m=p=null,n)if(i=n[c],n.hasOwnProperty(c)&&i!=null&&!r.hasOwnProperty(c))switch(c){case`value`:break;case`children`:break;default:Md(e,t,c,null,r,i)}for(s in r)if(i=r[s],o=n[s],r.hasOwnProperty(s)&&(i!=null||o!=null))switch(s){case`value`:p=i;break;case`defaultValue`:m=i;break;case`children`:break;case`dangerouslySetInnerHTML`:if(i!=null)throw Error(a(91));break;default:i!==o&&Md(e,t,s,i,r,o)}It(e,p,m);return;case`option`:for(var h in n)if(p=n[h],n.hasOwnProperty(h)&&p!=null&&!r.hasOwnProperty(h))switch(h){case`selected`:e.selected=!1;break;default:Md(e,t,h,null,r,p)}for(l in r)if(p=r[l],m=n[l],r.hasOwnProperty(l)&&p!==m&&(p!=null||m!=null))switch(l){case`selected`:e.selected=p&&typeof p!=`function`&&typeof p!=`symbol`;break;default:Md(e,t,l,p,r,m)}return;case`img`:case`link`:case`area`:case`base`:case`br`:case`col`:case`embed`:case`hr`:case`keygen`:case`meta`:case`param`:case`source`:case`track`:case`wbr`:case`menuitem`:for(var g in n)p=n[g],n.hasOwnProperty(g)&&p!=null&&!r.hasOwnProperty(g)&&Md(e,t,g,null,r,p);for(u in r)if(p=r[u],m=n[u],r.hasOwnProperty(u)&&p!==m&&(p!=null||m!=null))switch(u){case`children`:case`dangerouslySetInnerHTML`:if(p!=null)throw Error(a(137,t));break;default:Md(e,t,u,p,r,m)}return;default:if(Ht(t)){for(var _ in n)p=n[_],n.hasOwnProperty(_)&&p!==void 0&&!r.hasOwnProperty(_)&&Nd(e,t,_,void 0,r,p);for(d in r)p=r[d],m=n[d],!r.hasOwnProperty(d)||p===m||p===void 0&&m===void 0||Nd(e,t,d,p,r,m);return}}for(var v in n)p=n[v],n.hasOwnProperty(v)&&p!=null&&!r.hasOwnProperty(v)&&Md(e,t,v,null,r,p);for(f in r)p=r[f],m=n[f],!r.hasOwnProperty(f)||p===m||p==null&&m==null||Md(e,t,f,p,r,m)}function Id(e){switch(e){case`css`:case`script`:case`font`:case`img`:case`image`:case`input`:case`link`:return!0;default:return!1}}function Ld(){if(typeof performance.getEntriesByType==`function`){for(var e=0,t=0,n=performance.getEntriesByType(`resource`),r=0;r<n.length;r++){var i=n[r],a=i.transferSize,o=i.initiatorType,s=i.duration;if(a&&s&&Id(o)){for(o=0,s=i.responseEnd,r+=1;r<n.length;r++){var c=n[r],l=c.startTime;if(l>s)break;var u=c.transferSize,d=c.initiatorType;u&&Id(d)&&(c=c.responseEnd,o+=u*(c<s?1:(s-l)/(c-l)))}if(--r,t+=8*(a+o)/(i.duration/1e3),e++,10<e)break}}if(0<e)return t/e/1e6}return navigator.connection&&(e=navigator.connection.downlink,typeof e==`number`)?e:5}var Rd=null,zd=null;function Bd(e){return e.nodeType===9?e:e.ownerDocument}function Vd(e){switch(e){case`http://www.w3.org/2000/svg`:return 1;case`http://www.w3.org/1998/Math/MathML`:return 2;default:return 0}}function Hd(e,t){if(e===0)switch(t){case`svg`:return 1;case`math`:return 2;default:return 0}return e===1&&t===`foreignObject`?0:e}function Ud(e,t){return e===`textarea`||e===`noscript`||typeof t.children==`string`||typeof t.children==`number`||typeof t.children==`bigint`||typeof t.dangerouslySetInnerHTML==`object`&&t.dangerouslySetInnerHTML!==null&&t.dangerouslySetInnerHTML.__html!=null}var Wd=null;function Gd(){var e=window.event;return e&&e.type===`popstate`?e===Wd?!1:(Wd=e,!0):(Wd=null,!1)}var Kd=typeof setTimeout==`function`?setTimeout:void 0,qd=typeof clearTimeout==`function`?clearTimeout:void 0,Jd=typeof Promise==`function`?Promise:void 0,Yd=typeof queueMicrotask==`function`?queueMicrotask:Jd===void 0?Kd:function(e){return Jd.resolve(null).then(e).catch(Xd)};function Xd(e){setTimeout(function(){throw e})}function Zd(e){return e===`head`}function Qd(e,t){var n=t,r=0;do{var i=n.nextSibling;if(e.removeChild(n),i&&i.nodeType===8)if(n=i.data,n===`/$`||n===`/&`){if(r===0){e.removeChild(i),Np(t);return}r--}else if(n===`$`||n===`$?`||n===`$~`||n===`$!`||n===`&`)r++;else if(n===`html`)pf(e.ownerDocument.documentElement);else if(n===`head`){n=e.ownerDocument.head,pf(n);for(var a=n.firstChild;a;){var o=a.nextSibling,s=a.nodeName;a[ot]||s===`SCRIPT`||s===`STYLE`||s===`LINK`&&a.rel.toLowerCase()===`stylesheet`||n.removeChild(a),a=o}}else n===`body`&&pf(e.ownerDocument.body);n=i}while(n);Np(t)}function $d(e,t){var n=e;e=0;do{var r=n.nextSibling;if(n.nodeType===1?t?(n._stashedDisplay=n.style.display,n.style.display=`none`):(n.style.display=n._stashedDisplay||``,n.getAttribute(`style`)===``&&n.removeAttribute(`style`)):n.nodeType===3&&(t?(n._stashedText=n.nodeValue,n.nodeValue=``):n.nodeValue=n._stashedText||``),r&&r.nodeType===8)if(n=r.data,n===`/$`){if(e===0)break;e--}else n!==`$`&&n!==`$?`&&n!==`$~`&&n!==`$!`||e++;n=r}while(n)}function ef(e){var t=e.firstChild;for(t&&t.nodeType===10&&(t=t.nextSibling);t;){var n=t;switch(t=t.nextSibling,n.nodeName){case`HTML`:case`HEAD`:case`BODY`:ef(n),st(n);continue;case`SCRIPT`:case`STYLE`:continue;case`LINK`:if(n.rel.toLowerCase()===`stylesheet`)continue}e.removeChild(n)}}function tf(e,t,n,r){for(;e.nodeType===1;){var i=n;if(e.nodeName.toLowerCase()!==t.toLowerCase()){if(!r&&(e.nodeName!==`INPUT`||e.type!==`hidden`))break}else if(!r)if(t===`input`&&e.type===`hidden`){var a=i.name==null?null:``+i.name;if(i.type===`hidden`&&e.getAttribute(`name`)===a)return e}else return e;else if(!e[ot])switch(t){case`meta`:if(!e.hasAttribute(`itemprop`))break;return e;case`link`:if(a=e.getAttribute(`rel`),a===`stylesheet`&&e.hasAttribute(`data-precedence`)||a!==i.rel||e.getAttribute(`href`)!==(i.href==null||i.href===``?null:i.href)||e.getAttribute(`crossorigin`)!==(i.crossOrigin==null?null:i.crossOrigin)||e.getAttribute(`title`)!==(i.title==null?null:i.title))break;return e;case`style`:if(e.hasAttribute(`data-precedence`))break;return e;case`script`:if(a=e.getAttribute(`src`),(a!==(i.src==null?null:i.src)||e.getAttribute(`type`)!==(i.type==null?null:i.type)||e.getAttribute(`crossorigin`)!==(i.crossOrigin==null?null:i.crossOrigin))&&a&&e.hasAttribute(`async`)&&!e.hasAttribute(`itemprop`))break;return e;default:return e}if(e=cf(e.nextSibling),e===null)break}return null}function nf(e,t,n){if(t===``)return null;for(;e.nodeType!==3;)if((e.nodeType!==1||e.nodeName!==`INPUT`||e.type!==`hidden`)&&!n||(e=cf(e.nextSibling),e===null))return null;return e}function rf(e,t){for(;e.nodeType!==8;)if((e.nodeType!==1||e.nodeName!==`INPUT`||e.type!==`hidden`)&&!t||(e=cf(e.nextSibling),e===null))return null;return e}function af(e){return e.data===`$?`||e.data===`$~`}function of(e){return e.data===`$!`||e.data===`$?`&&e.ownerDocument.readyState!==`loading`}function sf(e,t){var n=e.ownerDocument;if(e.data===`$~`)e._reactRetry=t;else if(e.data!==`$?`||n.readyState!==`loading`)t();else{var r=function(){t(),n.removeEventListener(`DOMContentLoaded`,r)};n.addEventListener(`DOMContentLoaded`,r),e._reactRetry=r}}function cf(e){for(;e!=null;e=e.nextSibling){var t=e.nodeType;if(t===1||t===3)break;if(t===8){if(t=e.data,t===`$`||t===`$!`||t===`$?`||t===`$~`||t===`&`||t===`F!`||t===`F`)break;if(t===`/$`||t===`/&`)return null}}return e}var lf=null;function uf(e){e=e.nextSibling;for(var t=0;e;){if(e.nodeType===8){var n=e.data;if(n===`/$`||n===`/&`){if(t===0)return cf(e.nextSibling);t--}else n!==`$`&&n!==`$!`&&n!==`$?`&&n!==`$~`&&n!==`&`||t++}e=e.nextSibling}return null}function df(e){e=e.previousSibling;for(var t=0;e;){if(e.nodeType===8){var n=e.data;if(n===`$`||n===`$!`||n===`$?`||n===`$~`||n===`&`){if(t===0)return e;t--}else n!==`/$`&&n!==`/&`||t++}e=e.previousSibling}return null}function ff(e,t,n){switch(t=Bd(n),e){case`html`:if(e=t.documentElement,!e)throw Error(a(452));return e;case`head`:if(e=t.head,!e)throw Error(a(453));return e;case`body`:if(e=t.body,!e)throw Error(a(454));return e;default:throw Error(a(451))}}function pf(e){for(var t=e.attributes;t.length;)e.removeAttributeNode(t[0]);st(e)}var mf=new Map,hf=new Set;function gf(e){return typeof e.getRootNode==`function`?e.getRootNode():e.nodeType===9?e:e.ownerDocument}var _f=I.d;I.d={f:vf,r:yf,D:Sf,C:Cf,L:wf,m:Tf,X:Df,S:Ef,M:Of};function vf(){var e=_f.f(),t=vu();return e||t}function yf(e){var t=lt(e);t!==null&&t.tag===5&&t.type===`form`?ys(t):_f.r(e)}var bf=typeof document>`u`?null:document;function xf(e,t,n){var r=bf;if(r&&typeof t==`string`&&t){var i=jt(t);i=`link[rel="`+e+`"][href="`+i+`"]`,typeof n==`string`&&(i+=`[crossorigin="`+n+`"]`),hf.has(i)||(hf.add(i),e={rel:e,crossOrigin:n,href:t},r.querySelector(i)===null&&(t=r.createElement(`link`),Pd(t,`link`,e),ft(t),r.head.appendChild(t)))}}function Sf(e){_f.D(e),xf(`dns-prefetch`,e,null)}function Cf(e,t){_f.C(e,t),xf(`preconnect`,e,t)}function wf(e,t,n){_f.L(e,t,n);var r=bf;if(r&&e&&t){var i=`link[rel="preload"][as="`+jt(t)+`"]`;t===`image`&&n&&n.imageSrcSet?(i+=`[imagesrcset="`+jt(n.imageSrcSet)+`"]`,typeof n.imageSizes==`string`&&(i+=`[imagesizes="`+jt(n.imageSizes)+`"]`)):i+=`[href="`+jt(e)+`"]`;var a=i;switch(t){case`style`:a=Af(e);break;case`script`:a=Pf(e)}mf.has(a)||(e=p({rel:`preload`,href:t===`image`&&n&&n.imageSrcSet?void 0:e,as:t},n),mf.set(a,e),r.querySelector(i)!==null||t===`style`&&r.querySelector(jf(a))||t===`script`&&r.querySelector(Ff(a))||(t=r.createElement(`link`),Pd(t,`link`,e),ft(t),r.head.appendChild(t)))}}function Tf(e,t){_f.m(e,t);var n=bf;if(n&&e){var r=t&&typeof t.as==`string`?t.as:`script`,i=`link[rel="modulepreload"][as="`+jt(r)+`"][href="`+jt(e)+`"]`,a=i;switch(r){case`audioworklet`:case`paintworklet`:case`serviceworker`:case`sharedworker`:case`worker`:case`script`:a=Pf(e)}if(!mf.has(a)&&(e=p({rel:`modulepreload`,href:e},t),mf.set(a,e),n.querySelector(i)===null)){switch(r){case`audioworklet`:case`paintworklet`:case`serviceworker`:case`sharedworker`:case`worker`:case`script`:if(n.querySelector(Ff(a)))return}r=n.createElement(`link`),Pd(r,`link`,e),ft(r),n.head.appendChild(r)}}}function Ef(e,t,n){_f.S(e,t,n);var r=bf;if(r&&e){var i=dt(r).hoistableStyles,a=Af(e);t||=`default`;var o=i.get(a);if(!o){var s={loading:0,preload:null};if(o=r.querySelector(jf(a)))s.loading=5;else{e=p({rel:`stylesheet`,href:e,"data-precedence":t},n),(n=mf.get(a))&&Rf(e,n);var c=o=r.createElement(`link`);ft(c),Pd(c,`link`,e),c._p=new Promise(function(e,t){c.onload=e,c.onerror=t}),c.addEventListener(`load`,function(){s.loading|=1}),c.addEventListener(`error`,function(){s.loading|=2}),s.loading|=4,Lf(o,t,r)}o={type:`stylesheet`,instance:o,count:1,state:s},i.set(a,o)}}}function Df(e,t){_f.X(e,t);var n=bf;if(n&&e){var r=dt(n).hoistableScripts,i=Pf(e),a=r.get(i);a||(a=n.querySelector(Ff(i)),a||(e=p({src:e,async:!0},t),(t=mf.get(i))&&zf(e,t),a=n.createElement(`script`),ft(a),Pd(a,`link`,e),n.head.appendChild(a)),a={type:`script`,instance:a,count:1,state:null},r.set(i,a))}}function Of(e,t){_f.M(e,t);var n=bf;if(n&&e){var r=dt(n).hoistableScripts,i=Pf(e),a=r.get(i);a||(a=n.querySelector(Ff(i)),a||(e=p({src:e,async:!0,type:`module`},t),(t=mf.get(i))&&zf(e,t),a=n.createElement(`script`),ft(a),Pd(a,`link`,e),n.head.appendChild(a)),a={type:`script`,instance:a,count:1,state:null},r.set(i,a))}}function kf(e,t,n,r){var i=(i=B.current)?gf(i):null;if(!i)throw Error(a(446));switch(e){case`meta`:case`title`:return null;case`style`:return typeof n.precedence==`string`&&typeof n.href==`string`?(t=Af(n.href),n=dt(i).hoistableStyles,r=n.get(t),r||(r={type:`style`,instance:null,count:0,state:null},n.set(t,r)),r):{type:`void`,instance:null,count:0,state:null};case`link`:if(n.rel===`stylesheet`&&typeof n.href==`string`&&typeof n.precedence==`string`){e=Af(n.href);var o=dt(i).hoistableStyles,s=o.get(e);if(s||(i=i.ownerDocument||i,s={type:`stylesheet`,instance:null,count:0,state:{loading:0,preload:null}},o.set(e,s),(o=i.querySelector(jf(e)))&&!o._p&&(s.instance=o,s.state.loading=5),mf.has(e)||(n={rel:`preload`,as:`style`,href:n.href,crossOrigin:n.crossOrigin,integrity:n.integrity,media:n.media,hrefLang:n.hrefLang,referrerPolicy:n.referrerPolicy},mf.set(e,n),o||Nf(i,e,n,s.state))),t&&r===null)throw Error(a(528,``));return s}if(t&&r!==null)throw Error(a(529,``));return null;case`script`:return t=n.async,n=n.src,typeof n==`string`&&t&&typeof t!=`function`&&typeof t!=`symbol`?(t=Pf(n),n=dt(i).hoistableScripts,r=n.get(t),r||(r={type:`script`,instance:null,count:0,state:null},n.set(t,r)),r):{type:`void`,instance:null,count:0,state:null};default:throw Error(a(444,e))}}function Af(e){return`href="`+jt(e)+`"`}function jf(e){return`link[rel="stylesheet"][`+e+`]`}function Mf(e){return p({},e,{"data-precedence":e.precedence,precedence:null})}function Nf(e,t,n,r){e.querySelector(`link[rel="preload"][as="style"][`+t+`]`)?r.loading=1:(t=e.createElement(`link`),r.preload=t,t.addEventListener(`load`,function(){return r.loading|=1}),t.addEventListener(`error`,function(){return r.loading|=2}),Pd(t,`link`,n),ft(t),e.head.appendChild(t))}function Pf(e){return`[src="`+jt(e)+`"]`}function Ff(e){return`script[async]`+e}function If(e,t,n){if(t.count++,t.instance===null)switch(t.type){case`style`:var r=e.querySelector(`style[data-href~="`+jt(n.href)+`"]`);if(r)return t.instance=r,ft(r),r;var i=p({},n,{"data-href":n.href,"data-precedence":n.precedence,href:null,precedence:null});return r=(e.ownerDocument||e).createElement(`style`),ft(r),Pd(r,`style`,i),Lf(r,n.precedence,e),t.instance=r;case`stylesheet`:i=Af(n.href);var o=e.querySelector(jf(i));if(o)return t.state.loading|=4,t.instance=o,ft(o),o;r=Mf(n),(i=mf.get(i))&&Rf(r,i),o=(e.ownerDocument||e).createElement(`link`),ft(o);var s=o;return s._p=new Promise(function(e,t){s.onload=e,s.onerror=t}),Pd(o,`link`,r),t.state.loading|=4,Lf(o,n.precedence,e),t.instance=o;case`script`:return o=Pf(n.src),(i=e.querySelector(Ff(o)))?(t.instance=i,ft(i),i):(r=n,(i=mf.get(o))&&(r=p({},n),zf(r,i)),e=e.ownerDocument||e,i=e.createElement(`script`),ft(i),Pd(i,`link`,r),e.head.appendChild(i),t.instance=i);case`void`:return null;default:throw Error(a(443,t.type))}else t.type===`stylesheet`&&!(t.state.loading&4)&&(r=t.instance,t.state.loading|=4,Lf(r,n.precedence,e));return t.instance}function Lf(e,t,n){for(var r=n.querySelectorAll(`link[rel="stylesheet"][data-precedence],style[data-precedence]`),i=r.length?r[r.length-1]:null,a=i,o=0;o<r.length;o++){var s=r[o];if(s.dataset.precedence===t)a=s;else if(a!==i)break}a?a.parentNode.insertBefore(e,a.nextSibling):(t=n.nodeType===9?n.head:n,t.insertBefore(e,t.firstChild))}function Rf(e,t){e.crossOrigin??=t.crossOrigin,e.referrerPolicy??=t.referrerPolicy,e.title??=t.title}function zf(e,t){e.crossOrigin??=t.crossOrigin,e.referrerPolicy??=t.referrerPolicy,e.integrity??=t.integrity}var Bf=null;function Vf(e,t,n){if(Bf===null){var r=new Map,i=Bf=new Map;i.set(n,r)}else i=Bf,r=i.get(n),r||(r=new Map,i.set(n,r));if(r.has(e))return r;for(r.set(e,null),n=n.getElementsByTagName(e),i=0;i<n.length;i++){var a=n[i];if(!(a[ot]||a[$e]||e===`link`&&a.getAttribute(`rel`)===`stylesheet`)&&a.namespaceURI!==`http://www.w3.org/2000/svg`){var o=a.getAttribute(t)||``;o=e+o;var s=r.get(o);s?s.push(a):r.set(o,[a])}}return r}function Hf(e,t,n){e=e.ownerDocument||e,e.head.insertBefore(n,t===`title`?e.querySelector(`head > title`):null)}function Uf(e,t,n){if(n===1||t.itemProp!=null)return!1;switch(e){case`meta`:case`title`:return!0;case`style`:if(typeof t.precedence!=`string`||typeof t.href!=`string`||t.href===``)break;return!0;case`link`:if(typeof t.rel!=`string`||typeof t.href!=`string`||t.href===``||t.onLoad||t.onError)break;switch(t.rel){case`stylesheet`:return e=t.disabled,typeof t.precedence==`string`&&e==null;default:return!0}case`script`:if(t.async&&typeof t.async!=`function`&&typeof t.async!=`symbol`&&!t.onLoad&&!t.onError&&t.src&&typeof t.src==`string`)return!0}return!1}function Wf(e){return!(e.type===`stylesheet`&&!(e.state.loading&3))}function Gf(e,t,n,r){if(n.type===`stylesheet`&&(typeof r.media!=`string`||!1!==matchMedia(r.media).matches)&&!(n.state.loading&4)){if(n.instance===null){var i=Af(r.href),a=t.querySelector(jf(i));if(a){t=a._p,typeof t==`object`&&t&&typeof t.then==`function`&&(e.count++,e=Jf.bind(e),t.then(e,e)),n.state.loading|=4,n.instance=a,ft(a);return}a=t.ownerDocument||t,r=Mf(r),(i=mf.get(i))&&Rf(r,i),a=a.createElement(`link`),ft(a);var o=a;o._p=new Promise(function(e,t){o.onload=e,o.onerror=t}),Pd(a,`link`,r),n.instance=a}e.stylesheets===null&&(e.stylesheets=new Map),e.stylesheets.set(n,t),(t=n.state.preload)&&!(n.state.loading&3)&&(e.count++,n=Jf.bind(e),t.addEventListener(`load`,n),t.addEventListener(`error`,n))}}var Kf=0;function qf(e,t){return e.stylesheets&&e.count===0&&Xf(e,e.stylesheets),0<e.count||0<e.imgCount?function(n){var r=setTimeout(function(){if(e.stylesheets&&Xf(e,e.stylesheets),e.unsuspend){var t=e.unsuspend;e.unsuspend=null,t()}},6e4+t);0<e.imgBytes&&Kf===0&&(Kf=62500*Ld());var i=setTimeout(function(){if(e.waitingForImages=!1,e.count===0&&(e.stylesheets&&Xf(e,e.stylesheets),e.unsuspend)){var t=e.unsuspend;e.unsuspend=null,t()}},(e.imgBytes>Kf?50:800)+t);return e.unsuspend=n,function(){e.unsuspend=null,clearTimeout(r),clearTimeout(i)}}:null}function Jf(){if(this.count--,this.count===0&&(this.imgCount===0||!this.waitingForImages)){if(this.stylesheets)Xf(this,this.stylesheets);else if(this.unsuspend){var e=this.unsuspend;this.unsuspend=null,e()}}}var Yf=null;function Xf(e,t){e.stylesheets=null,e.unsuspend!==null&&(e.count++,Yf=new Map,t.forEach(Zf,e),Yf=null,Jf.call(e))}function Zf(e,t){if(!(t.state.loading&4)){var n=Yf.get(e);if(n)var r=n.get(null);else{n=new Map,Yf.set(e,n);for(var i=e.querySelectorAll(`link[data-precedence],style[data-precedence]`),a=0;a<i.length;a++){var o=i[a];(o.nodeName===`LINK`||o.getAttribute(`media`)!==`not all`)&&(n.set(o.dataset.precedence,o),r=o)}r&&n.set(null,r)}i=t.instance,o=i.getAttribute(`data-precedence`),a=n.get(o)||r,a===r&&n.set(null,i),n.set(o,i),this.count++,r=Jf.bind(this),i.addEventListener(`load`,r),i.addEventListener(`error`,r),a?a.parentNode.insertBefore(i,a.nextSibling):(e=e.nodeType===9?e.head:e,e.insertBefore(i,e.firstChild)),t.state.loading|=4}}var Qf={$$typeof:S,Provider:null,Consumer:null,_currentValue:ee,_currentValue2:ee,_threadCount:0};function $f(e,t,n,r,i,a,o,s,c){this.tag=1,this.containerInfo=e,this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.next=this.pendingContext=this.context=this.cancelPendingCommit=null,this.callbackPriority=0,this.expirationTimes=He(-1),this.entangledLanes=this.shellSuspendCounter=this.errorRecoveryDisabledLanes=this.expiredLanes=this.warmLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=He(0),this.hiddenUpdates=He(null),this.identifierPrefix=r,this.onUncaughtError=i,this.onCaughtError=a,this.onRecoverableError=o,this.pooledCache=null,this.pooledCacheLanes=0,this.formState=c,this.incompleteTransitions=new Map}function ep(e,t,n,r,i,a,o,s,c,l,u,d){return e=new $f(e,t,n,o,c,l,u,d,s),t=1,!0===a&&(t|=24),a=$r(3,null,null,t),e.current=a,a.stateNode=e,t=Qi(),t.refCount++,e.pooledCache=t,t.refCount++,a.memoizedState={element:r,isDehydrated:n,cache:t},ja(a),e}function tp(e){return e?(e=Zr,e):Zr}function np(e,t,n,r,i,a){i=tp(i),r.context===null?r.context=i:r.pendingContext=i,r=Na(t),r.payload={element:n},a=a===void 0?null:a,a!==null&&(r.callback=a),n=Pa(e,r,t),n!==null&&(pu(n,e,t),Fa(n,e,t))}function rp(e,t){if(e=e.memoizedState,e!==null&&e.dehydrated!==null){var n=e.retryLane;e.retryLane=n!==0&&n<t?n:t}}function ip(e,t){rp(e,t),(e=e.alternate)&&rp(e,t)}function ap(e){if(e.tag===13||e.tag===31){var t=Jr(e,67108864);t!==null&&pu(t,e,67108864),ip(e,67108864)}}function op(e){if(e.tag===13||e.tag===31){var t=du();t=Je(t);var n=Jr(e,t);n!==null&&pu(n,e,t),ip(e,t)}}var sp=!0;function cp(e,t,n,r){var i=F.T;F.T=null;var a=I.p;try{I.p=2,up(e,t,n,r)}finally{I.p=a,F.T=i}}function lp(e,t,n,r){var i=F.T;F.T=null;var a=I.p;try{I.p=8,up(e,t,n,r)}finally{I.p=a,F.T=i}}function up(e,t,n,r){if(sp){var i=dp(r);if(i===null)Cd(e,t,r,fp,n),Cp(e,r);else if(Tp(i,e,t,n,r))r.stopPropagation();else if(Cp(e,r),t&4&&-1<Sp.indexOf(e)){for(;i!==null;){var a=lt(i);if(a!==null)switch(a.tag){case 3:if(a=a.stateNode,a.current.memoizedState.isDehydrated){var o=W(a.pendingLanes);if(o!==0){var s=a;for(s.pendingLanes|=2,s.entangledLanes|=2;o;){var c=1<<31-je(o);s.entanglements[1]|=c,o&=~c}nd(a),!(Nl&6)&&($l=ye()+500,rd(0,!1))}}break;case 31:case 13:s=Jr(a,2),s!==null&&pu(s,a,2),vu(),ip(a,2)}if(a=dp(r),a===null&&Cd(e,t,r,fp,n),a===i)break;i=a}i!==null&&r.stopPropagation()}else Cd(e,t,r,null,n)}}function dp(e){return e=Jt(e),pp(e)}var fp=null;function pp(e){if(fp=null,e=ct(e),e!==null){var t=s(e);if(t===null)e=null;else{var n=t.tag;if(n===13){if(e=c(t),e!==null)return e;e=null}else if(n===31){if(e=l(t),e!==null)return e;e=null}else if(n===3){if(t.stateNode.current.memoizedState.isDehydrated)return t.tag===3?t.stateNode.containerInfo:null;e=null}else t!==e&&(e=null)}}return fp=e,null}function mp(e){switch(e){case`beforetoggle`:case`cancel`:case`click`:case`close`:case`contextmenu`:case`copy`:case`cut`:case`auxclick`:case`dblclick`:case`dragend`:case`dragstart`:case`drop`:case`focusin`:case`focusout`:case`input`:case`invalid`:case`keydown`:case`keypress`:case`keyup`:case`mousedown`:case`mouseup`:case`paste`:case`pause`:case`play`:case`pointercancel`:case`pointerdown`:case`pointerup`:case`ratechange`:case`reset`:case`resize`:case`seeked`:case`submit`:case`toggle`:case`touchcancel`:case`touchend`:case`touchstart`:case`volumechange`:case`change`:case`selectionchange`:case`textInput`:case`compositionstart`:case`compositionend`:case`compositionupdate`:case`beforeblur`:case`afterblur`:case`beforeinput`:case`blur`:case`fullscreenchange`:case`focus`:case`hashchange`:case`popstate`:case`select`:case`selectstart`:return 2;case`drag`:case`dragenter`:case`dragexit`:case`dragleave`:case`dragover`:case`mousemove`:case`mouseout`:case`mouseover`:case`pointermove`:case`pointerout`:case`pointerover`:case`scroll`:case`touchmove`:case`wheel`:case`mouseenter`:case`mouseleave`:case`pointerenter`:case`pointerleave`:return 8;case`message`:switch(be()){case xe:return 2;case Se:return 8;case Ce:case we:return 32;case Te:return 268435456;default:return 32}default:return 32}}var hp=!1,gp=null,_p=null,vp=null,yp=new Map,bp=new Map,xp=[],Sp=`mousedown mouseup touchcancel touchend touchstart auxclick dblclick pointercancel pointerdown pointerup dragend dragstart drop compositionend compositionstart keydown keypress keyup input textInput copy cut paste click change contextmenu reset`.split(` `);function Cp(e,t){switch(e){case`focusin`:case`focusout`:gp=null;break;case`dragenter`:case`dragleave`:_p=null;break;case`mouseover`:case`mouseout`:vp=null;break;case`pointerover`:case`pointerout`:yp.delete(t.pointerId);break;case`gotpointercapture`:case`lostpointercapture`:bp.delete(t.pointerId)}}function wp(e,t,n,r,i,a){return e===null||e.nativeEvent!==a?(e={blockedOn:t,domEventName:n,eventSystemFlags:r,nativeEvent:a,targetContainers:[i]},t!==null&&(t=lt(t),t!==null&&ap(t)),e):(e.eventSystemFlags|=r,t=e.targetContainers,i!==null&&t.indexOf(i)===-1&&t.push(i),e)}function Tp(e,t,n,r,i){switch(t){case`focusin`:return gp=wp(gp,e,t,n,r,i),!0;case`dragenter`:return _p=wp(_p,e,t,n,r,i),!0;case`mouseover`:return vp=wp(vp,e,t,n,r,i),!0;case`pointerover`:var a=i.pointerId;return yp.set(a,wp(yp.get(a)||null,e,t,n,r,i)),!0;case`gotpointercapture`:return a=i.pointerId,bp.set(a,wp(bp.get(a)||null,e,t,n,r,i)),!0}return!1}function Ep(e){var t=ct(e.target);if(t!==null){var n=s(t);if(n!==null){if(t=n.tag,t===13){if(t=c(n),t!==null){e.blockedOn=t,Ze(e.priority,function(){op(n)});return}}else if(t===31){if(t=l(n),t!==null){e.blockedOn=t,Ze(e.priority,function(){op(n)});return}}else if(t===3&&n.stateNode.current.memoizedState.isDehydrated){e.blockedOn=n.tag===3?n.stateNode.containerInfo:null;return}}}e.blockedOn=null}function Dp(e){if(e.blockedOn!==null)return!1;for(var t=e.targetContainers;0<t.length;){var n=dp(e.nativeEvent);if(n===null){n=e.nativeEvent;var r=new n.constructor(n.type,n);qt=r,n.target.dispatchEvent(r),qt=null}else return t=lt(n),t!==null&&ap(t),e.blockedOn=n,!1;t.shift()}return!0}function Op(e,t,n){Dp(e)&&n.delete(t)}function kp(){hp=!1,gp!==null&&Dp(gp)&&(gp=null),_p!==null&&Dp(_p)&&(_p=null),vp!==null&&Dp(vp)&&(vp=null),yp.forEach(Op),bp.forEach(Op)}function Ap(e,n){e.blockedOn===n&&(e.blockedOn=null,hp||(hp=!0,t.unstable_scheduleCallback(t.unstable_NormalPriority,kp)))}var jp=null;function Mp(e){jp!==e&&(jp=e,t.unstable_scheduleCallback(t.unstable_NormalPriority,function(){jp===e&&(jp=null);for(var t=0;t<e.length;t+=3){var n=e[t],r=e[t+1],i=e[t+2];if(typeof r!=`function`){if(pp(r||n)===null)continue;break}var a=lt(n);a!==null&&(e.splice(t,3),t-=3,_s(a,{pending:!0,data:i,method:n.method,action:r},r,i))}}))}function Np(e){function t(t){return Ap(t,e)}gp!==null&&Ap(gp,e),_p!==null&&Ap(_p,e),vp!==null&&Ap(vp,e),yp.forEach(t),bp.forEach(t);for(var n=0;n<xp.length;n++){var r=xp[n];r.blockedOn===e&&(r.blockedOn=null)}for(;0<xp.length&&(n=xp[0],n.blockedOn===null);)Ep(n),n.blockedOn===null&&xp.shift();if(n=(e.ownerDocument||e).$$reactFormReplay,n!=null)for(r=0;r<n.length;r+=3){var i=n[r],a=n[r+1],o=i[et]||null;if(typeof a==`function`)o||Mp(n);else if(o){var s=null;if(a&&a.hasAttribute(`formAction`)){if(i=a,o=a[et]||null)s=o.formAction;else if(pp(i)!==null)continue}else s=o.action;typeof s==`function`?n[r+1]=s:(n.splice(r,3),r-=3),Mp(n)}}}function Pp(){function e(e){e.canIntercept&&e.info===`react-transition`&&e.intercept({handler:function(){return new Promise(function(e){return i=e})},focusReset:`manual`,scroll:`manual`})}function t(){i!==null&&(i(),i=null),r||setTimeout(n,20)}function n(){if(!r&&!navigation.transition){var e=navigation.currentEntry;e&&e.url!=null&&navigation.navigate(e.url,{state:e.getState(),info:`react-transition`,history:`replace`})}}if(typeof navigation==`object`){var r=!1,i=null;return navigation.addEventListener(`navigate`,e),navigation.addEventListener(`navigatesuccess`,t),navigation.addEventListener(`navigateerror`,t),setTimeout(n,100),function(){r=!0,navigation.removeEventListener(`navigate`,e),navigation.removeEventListener(`navigatesuccess`,t),navigation.removeEventListener(`navigateerror`,t),i!==null&&(i(),i=null)}}}function Fp(e){this._internalRoot=e}Ip.prototype.render=Fp.prototype.render=function(e){var t=this._internalRoot;if(t===null)throw Error(a(409));var n=t.current;np(n,du(),e,t,null,null)},Ip.prototype.unmount=Fp.prototype.unmount=function(){var e=this._internalRoot;if(e!==null){this._internalRoot=null;var t=e.containerInfo;np(e.current,2,null,e,null,null),vu(),t[tt]=null}};function Ip(e){this._internalRoot=e}Ip.prototype.unstable_scheduleHydration=function(e){if(e){var t=Xe();e={blockedOn:null,target:e,priority:t};for(var n=0;n<xp.length&&t!==0&&t<xp[n].priority;n++);xp.splice(n,0,e),n===0&&Ep(e)}};var Lp=n.version;if(Lp!==`19.2.4`)throw Error(a(527,Lp,`19.2.4`));I.findDOMNode=function(e){var t=e._reactInternals;if(t===void 0)throw typeof e.render==`function`?Error(a(188)):(e=Object.keys(e).join(`,`),Error(a(268,e)));return e=d(t),e=e===null?null:f(e),e=e===null?null:e.stateNode,e};var Rp={bundleType:0,version:`19.2.4`,rendererPackageName:`react-dom`,currentDispatcherRef:F,reconcilerVersion:`19.2.4`};if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<`u`){var zp=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!zp.isDisabled&&zp.supportsFiber)try{Oe=zp.inject(Rp),ke=zp}catch{}}e.createRoot=function(e,t){if(!o(e))throw Error(a(299));var n=!1,r=``,i=zs,s=Bs,c=Vs;return t!=null&&(!0===t.unstable_strictMode&&(n=!0),t.identifierPrefix!==void 0&&(r=t.identifierPrefix),t.onUncaughtError!==void 0&&(i=t.onUncaughtError),t.onCaughtError!==void 0&&(s=t.onCaughtError),t.onRecoverableError!==void 0&&(c=t.onRecoverableError)),t=ep(e,1,!1,null,null,n,r,null,i,s,c,Pp),e[tt]=t.current,xd(e),new Fp(t)}})),Re=t(((e,t)=>{function n(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>`u`||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!=`function`))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(n)}catch(e){console.error(e)}}n(),t.exports=Le()})),W=e(r(),1),ze=Re(),G=e=>typeof e==`string`,Be=()=>{let e,t,n=new Promise((n,r)=>{e=n,t=r});return n.resolve=e,n.reject=t,n},Ve=e=>e==null?``:``+e,He=(e,t,n)=>{e.forEach(e=>{t[e]&&(n[e]=t[e])})},Ue=/###/g,We=e=>e&&e.indexOf(`###`)>-1?e.replace(Ue,`.`):e,Ge=e=>!e||G(e),Ke=(e,t,n)=>{let r=G(t)?t.split(`.`):t,i=0;for(;i<r.length-1;){if(Ge(e))return{};let t=We(r[i]);!e[t]&&n&&(e[t]=new n),e=Object.prototype.hasOwnProperty.call(e,t)?e[t]:{},++i}return Ge(e)?{}:{obj:e,k:We(r[i])}},qe=(e,t,n)=>{let{obj:r,k:i}=Ke(e,t,Object);if(r!==void 0||t.length===1){r[i]=n;return}let a=t[t.length-1],o=t.slice(0,t.length-1),s=Ke(e,o,Object);for(;s.obj===void 0&&o.length;)a=`${o[o.length-1]}.${a}`,o=o.slice(0,o.length-1),s=Ke(e,o,Object),s?.obj&&s.obj[`${s.k}.${a}`]!==void 0&&(s.obj=void 0);s.obj[`${s.k}.${a}`]=n},Je=(e,t,n,r)=>{let{obj:i,k:a}=Ke(e,t,Object);i[a]=i[a]||[],i[a].push(n)},Ye=(e,t)=>{let{obj:n,k:r}=Ke(e,t);if(n&&Object.prototype.hasOwnProperty.call(n,r))return n[r]},Xe=(e,t,n)=>{let r=Ye(e,n);return r===void 0?Ye(t,n):r},Ze=(e,t,n)=>{for(let r in t)r!==`__proto__`&&r!==`constructor`&&(r in e?G(e[r])||e[r]instanceof String||G(t[r])||t[r]instanceof String?n&&(e[r]=t[r]):Ze(e[r],t[r],n):e[r]=t[r]);return e},Qe=e=>e.replace(/[\-\[\]\/\{\}\(\)\*\+\?\.\\\^\$\|]/g,`\\$&`),$e={"&":`&`,"<":`<`,">":`>`,'"':`"`,"'":`'`,"/":`/`},et=e=>G(e)?e.replace(/[&<>"'\/]/g,e=>$e[e]):e,tt=class{constructor(e){this.capacity=e,this.regExpMap=new Map,this.regExpQueue=[]}getRegExp(e){let t=this.regExpMap.get(e);if(t!==void 0)return t;let n=new RegExp(e);return this.regExpQueue.length===this.capacity&&this.regExpMap.delete(this.regExpQueue.shift()),this.regExpMap.set(e,n),this.regExpQueue.push(e),n}},nt=[` `,`,`,`?`,`!`,`;`],rt=new tt(20),it=(e,t,n)=>{t||=``,n||=``;let r=nt.filter(e=>t.indexOf(e)<0&&n.indexOf(e)<0);if(r.length===0)return!0;let i=rt.getRegExp(`(${r.map(e=>e===`?`?`\\?`:e).join(`|`)})`),a=!i.test(e);if(!a){let t=e.indexOf(n);t>0&&!i.test(e.substring(0,t))&&(a=!0)}return a},at=(e,t,n=`.`)=>{if(!e)return;if(e[t])return Object.prototype.hasOwnProperty.call(e,t)?e[t]:void 0;let r=t.split(n),i=e;for(let e=0;e<r.length;){if(!i||typeof i!=`object`)return;let t,a=``;for(let o=e;o<r.length;++o)if(o!==e&&(a+=n),a+=r[o],t=i[a],t!==void 0){if([`string`,`number`,`boolean`].indexOf(typeof t)>-1&&o<r.length-1)continue;e+=o-e+1;break}i=t}return i},ot=e=>e?.replace(`_`,`-`),st={type:`logger`,log(e){this.output(`log`,e)},warn(e){this.output(`warn`,e)},error(e){this.output(`error`,e)},output(e,t){console?.[e]?.apply?.(console,t)}},ct=new class e{constructor(e,t={}){this.init(e,t)}init(e,t={}){this.prefix=t.prefix||`i18next:`,this.logger=e||st,this.options=t,this.debug=t.debug}log(...e){return this.forward(e,`log`,``,!0)}warn(...e){return this.forward(e,`warn`,``,!0)}error(...e){return this.forward(e,`error`,``)}deprecate(...e){return this.forward(e,`warn`,`WARNING DEPRECATED: `,!0)}forward(e,t,n,r){return r&&!this.debug?null:(G(e[0])&&(e[0]=`${n}${this.prefix} ${e[0]}`),this.logger[t](e))}create(t){return new e(this.logger,{prefix:`${this.prefix}:${t}:`,...this.options})}clone(t){return t||=this.options,t.prefix=t.prefix||this.prefix,new e(this.logger,t)}},lt=class{constructor(){this.observers={}}on(e,t){return e.split(` `).forEach(e=>{this.observers[e]||(this.observers[e]=new Map);let n=this.observers[e].get(t)||0;this.observers[e].set(t,n+1)}),this}off(e,t){if(this.observers[e]){if(!t){delete this.observers[e];return}this.observers[e].delete(t)}}emit(e,...t){this.observers[e]&&Array.from(this.observers[e].entries()).forEach(([e,n])=>{for(let r=0;r<n;r++)e(...t)}),this.observers[`*`]&&Array.from(this.observers[`*`].entries()).forEach(([n,r])=>{for(let i=0;i<r;i++)n.apply(n,[e,...t])})}},ut=class extends lt{constructor(e,t={ns:[`translation`],defaultNS:`translation`}){super(),this.data=e||{},this.options=t,this.options.keySeparator===void 0&&(this.options.keySeparator=`.`),this.options.ignoreJSONStructure===void 0&&(this.options.ignoreJSONStructure=!0)}addNamespaces(e){this.options.ns.indexOf(e)<0&&this.options.ns.push(e)}removeNamespaces(e){let t=this.options.ns.indexOf(e);t>-1&&this.options.ns.splice(t,1)}getResource(e,t,n,r={}){let i=r.keySeparator===void 0?this.options.keySeparator:r.keySeparator,a=r.ignoreJSONStructure===void 0?this.options.ignoreJSONStructure:r.ignoreJSONStructure,o;e.indexOf(`.`)>-1?o=e.split(`.`):(o=[e,t],n&&(Array.isArray(n)?o.push(...n):G(n)&&i?o.push(...n.split(i)):o.push(n)));let s=Ye(this.data,o);return!s&&!t&&!n&&e.indexOf(`.`)>-1&&(e=o[0],t=o[1],n=o.slice(2).join(`.`)),s||!a||!G(n)?s:at(this.data?.[e]?.[t],n,i)}addResource(e,t,n,r,i={silent:!1}){let a=i.keySeparator===void 0?this.options.keySeparator:i.keySeparator,o=[e,t];n&&(o=o.concat(a?n.split(a):n)),e.indexOf(`.`)>-1&&(o=e.split(`.`),r=t,t=o[1]),this.addNamespaces(t),qe(this.data,o,r),i.silent||this.emit(`added`,e,t,n,r)}addResources(e,t,n,r={silent:!1}){for(let r in n)(G(n[r])||Array.isArray(n[r]))&&this.addResource(e,t,r,n[r],{silent:!0});r.silent||this.emit(`added`,e,t,n)}addResourceBundle(e,t,n,r,i,a={silent:!1,skipCopy:!1}){let o=[e,t];e.indexOf(`.`)>-1&&(o=e.split(`.`),r=n,n=t,t=o[1]),this.addNamespaces(t);let s=Ye(this.data,o)||{};a.skipCopy||(n=JSON.parse(JSON.stringify(n))),r?Ze(s,n,i):s={...s,...n},qe(this.data,o,s),a.silent||this.emit(`added`,e,t,n)}removeResourceBundle(e,t){this.hasResourceBundle(e,t)&&delete this.data[e][t],this.removeNamespaces(t),this.emit(`removed`,e,t)}hasResourceBundle(e,t){return this.getResource(e,t)!==void 0}getResourceBundle(e,t){return t||=this.options.defaultNS,this.getResource(e,t)}getDataByLanguage(e){return this.data[e]}hasLanguageSomeTranslations(e){let t=this.getDataByLanguage(e);return!!(t&&Object.keys(t)||[]).find(e=>t[e]&&Object.keys(t[e]).length>0)}toJSON(){return this.data}},dt={processors:{},addPostProcessor(e){this.processors[e.name]=e},handle(e,t,n,r,i){return e.forEach(e=>{t=this.processors[e]?.process(t,n,r,i)??t}),t}},ft=Symbol(`i18next/PATH_KEY`);function pt(){let e=[],t=Object.create(null),n;return t.get=(r,i)=>(n?.revoke?.(),i===ft?e:(e.push(i),n=Proxy.revocable(r,t),n.proxy)),Proxy.revocable(Object.create(null),t).proxy}function mt(e,t){let{[ft]:n}=e(pt());return n.join(t?.keySeparator??`.`)}var ht={},gt=e=>!G(e)&&typeof e!=`boolean`&&typeof e!=`number`,_t=class e extends lt{constructor(e,t={}){super(),He([`resourceStore`,`languageUtils`,`pluralResolver`,`interpolator`,`backendConnector`,`i18nFormat`,`utils`],e,this),this.options=t,this.options.keySeparator===void 0&&(this.options.keySeparator=`.`),this.logger=ct.create(`translator`)}changeLanguage(e){e&&(this.language=e)}exists(e,t={interpolation:{}}){let n={...t};if(e==null)return!1;let r=this.resolve(e,n);if(r?.res===void 0)return!1;let i=gt(r.res);return!(n.returnObjects===!1&&i)}extractFromKey(e,t){let n=t.nsSeparator===void 0?this.options.nsSeparator:t.nsSeparator;n===void 0&&(n=`:`);let r=t.keySeparator===void 0?this.options.keySeparator:t.keySeparator,i=t.ns||this.options.defaultNS||[],a=n&&e.indexOf(n)>-1,o=!this.options.userDefinedKeySeparator&&!t.keySeparator&&!this.options.userDefinedNsSeparator&&!t.nsSeparator&&!it(e,n,r);if(a&&!o){let t=e.match(this.interpolator.nestingRegexp);if(t&&t.length>0)return{key:e,namespaces:G(i)?[i]:i};let a=e.split(n);(n!==r||n===r&&this.options.ns.indexOf(a[0])>-1)&&(i=a.shift()),e=a.join(r)}return{key:e,namespaces:G(i)?[i]:i}}translate(t,n,r){let i=typeof n==`object`?{...n}:n;if(typeof i!=`object`&&this.options.overloadTranslationOptionHandler&&(i=this.options.overloadTranslationOptionHandler(arguments)),typeof i==`object`&&(i={...i}),i||={},t==null)return``;typeof t==`function`&&(t=mt(t,{...this.options,...i})),Array.isArray(t)||(t=[String(t)]);let a=i.returnDetails===void 0?this.options.returnDetails:i.returnDetails,o=i.keySeparator===void 0?this.options.keySeparator:i.keySeparator,{key:s,namespaces:c}=this.extractFromKey(t[t.length-1],i),l=c[c.length-1],u=i.nsSeparator===void 0?this.options.nsSeparator:i.nsSeparator;u===void 0&&(u=`:`);let d=i.lng||this.language,f=i.appendNamespaceToCIMode||this.options.appendNamespaceToCIMode;if(d?.toLowerCase()===`cimode`)return f?a?{res:`${l}${u}${s}`,usedKey:s,exactUsedKey:s,usedLng:d,usedNS:l,usedParams:this.getUsedParamsDetails(i)}:`${l}${u}${s}`:a?{res:s,usedKey:s,exactUsedKey:s,usedLng:d,usedNS:l,usedParams:this.getUsedParamsDetails(i)}:s;let p=this.resolve(t,i),m=p?.res,h=p?.usedKey||s,g=p?.exactUsedKey||s,_=[`[object Number]`,`[object Function]`,`[object RegExp]`],v=i.joinArrays===void 0?this.options.joinArrays:i.joinArrays,y=!this.i18nFormat||this.i18nFormat.handleAsObject,b=i.count!==void 0&&!G(i.count),x=e.hasDefaultValue(i),S=b?this.pluralResolver.getSuffix(d,i.count,i):``,C=i.ordinal&&b?this.pluralResolver.getSuffix(d,i.count,{ordinal:!1}):``,w=b&&!i.ordinal&&i.count===0,T=w&&i[`defaultValue${this.options.pluralSeparator}zero`]||i[`defaultValue${S}`]||i[`defaultValue${C}`]||i.defaultValue,E=m;y&&!m&&x&&(E=T);let D=gt(E),O=Object.prototype.toString.apply(E);if(y&&E&&D&&_.indexOf(O)<0&&!(G(v)&&Array.isArray(E))){if(!i.returnObjects&&!this.options.returnObjects){this.options.returnedObjectHandler||this.logger.warn(`accessing an object - but returnObjects options is not enabled!`);let e=this.options.returnedObjectHandler?this.options.returnedObjectHandler(h,E,{...i,ns:c}):`key '${s} (${this.language})' returned an object instead of string.`;return a?(p.res=e,p.usedParams=this.getUsedParamsDetails(i),p):e}if(o){let e=Array.isArray(E),t=e?[]:{},n=e?g:h;for(let e in E)if(Object.prototype.hasOwnProperty.call(E,e)){let r=`${n}${o}${e}`;x&&!m?t[e]=this.translate(r,{...i,defaultValue:gt(T)?T[e]:void 0,joinArrays:!1,ns:c}):t[e]=this.translate(r,{...i,joinArrays:!1,ns:c}),t[e]===r&&(t[e]=E[e])}m=t}}else if(y&&G(v)&&Array.isArray(m))m=m.join(v),m&&=this.extendTranslation(m,t,i,r);else{let e=!1,n=!1;!this.isValidLookup(m)&&x&&(e=!0,m=T),this.isValidLookup(m)||(n=!0,m=s);let a=(i.missingKeyNoValueFallbackToKey||this.options.missingKeyNoValueFallbackToKey)&&n?void 0:m,c=x&&T!==m&&this.options.updateMissing;if(n||e||c){if(this.logger.log(c?`updateKey`:`missingKey`,d,l,s,c?T:m),o){let e=this.resolve(s,{...i,keySeparator:!1});e&&e.res&&this.logger.warn(`Seems the loaded translations were in flat JSON format instead of nested. Either set keySeparator: false on init or make sure your translations are published in nested format.`)}let e=[],t=this.languageUtils.getFallbackCodes(this.options.fallbackLng,i.lng||this.language);if(this.options.saveMissingTo===`fallback`&&t&&t[0])for(let n=0;n<t.length;n++)e.push(t[n]);else this.options.saveMissingTo===`all`?e=this.languageUtils.toResolveHierarchy(i.lng||this.language):e.push(i.lng||this.language);let n=(e,t,n)=>{let r=x&&n!==m?n:a;this.options.missingKeyHandler?this.options.missingKeyHandler(e,l,t,r,c,i):this.backendConnector?.saveMissing&&this.backendConnector.saveMissing(e,l,t,r,c,i),this.emit(`missingKey`,e,l,t,m)};this.options.saveMissing&&(this.options.saveMissingPlurals&&b?e.forEach(e=>{let t=this.pluralResolver.getSuffixes(e,i);w&&i[`defaultValue${this.options.pluralSeparator}zero`]&&t.indexOf(`${this.options.pluralSeparator}zero`)<0&&t.push(`${this.options.pluralSeparator}zero`),t.forEach(t=>{n([e],s+t,i[`defaultValue${t}`]||T)})}):n(e,s,T))}m=this.extendTranslation(m,t,i,p,r),n&&m===s&&this.options.appendNamespaceToMissingKey&&(m=`${l}${u}${s}`),(n||e)&&this.options.parseMissingKeyHandler&&(m=this.options.parseMissingKeyHandler(this.options.appendNamespaceToMissingKey?`${l}${u}${s}`:s,e?m:void 0,i))}return a?(p.res=m,p.usedParams=this.getUsedParamsDetails(i),p):m}extendTranslation(e,t,n,r,i){if(this.i18nFormat?.parse)e=this.i18nFormat.parse(e,{...this.options.interpolation.defaultVariables,...n},n.lng||this.language||r.usedLng,r.usedNS,r.usedKey,{resolved:r});else if(!n.skipInterpolation){n.interpolation&&this.interpolator.init({...n,interpolation:{...this.options.interpolation,...n.interpolation}});let a=G(e)&&(n?.interpolation?.skipOnVariables===void 0?this.options.interpolation.skipOnVariables:n.interpolation.skipOnVariables),o;if(a){let t=e.match(this.interpolator.nestingRegexp);o=t&&t.length}let s=n.replace&&!G(n.replace)?n.replace:n;if(this.options.interpolation.defaultVariables&&(s={...this.options.interpolation.defaultVariables,...s}),e=this.interpolator.interpolate(e,s,n.lng||this.language||r.usedLng,n),a){let t=e.match(this.interpolator.nestingRegexp),r=t&&t.length;o<r&&(n.nest=!1)}!n.lng&&r&&r.res&&(n.lng=this.language||r.usedLng),n.nest!==!1&&(e=this.interpolator.nest(e,(...e)=>i?.[0]===e[0]&&!n.context?(this.logger.warn(`It seems you are nesting recursively key: ${e[0]} in key: ${t[0]}`),null):this.translate(...e,t),n)),n.interpolation&&this.interpolator.reset()}let a=n.postProcess||this.options.postProcess,o=G(a)?[a]:a;return e!=null&&o?.length&&n.applyPostProcessor!==!1&&(e=dt.handle(o,e,t,this.options&&this.options.postProcessPassResolved?{i18nResolved:{...r,usedParams:this.getUsedParamsDetails(n)},...n}:n,this)),e}resolve(e,t={}){let n,r,i,a,o;return G(e)&&(e=[e]),e.forEach(e=>{if(this.isValidLookup(n))return;let s=this.extractFromKey(e,t),c=s.key;r=c;let l=s.namespaces;this.options.fallbackNS&&(l=l.concat(this.options.fallbackNS));let u=t.count!==void 0&&!G(t.count),d=u&&!t.ordinal&&t.count===0,f=t.context!==void 0&&(G(t.context)||typeof t.context==`number`)&&t.context!==``,p=t.lngs?t.lngs:this.languageUtils.toResolveHierarchy(t.lng||this.language,t.fallbackLng);l.forEach(e=>{this.isValidLookup(n)||(o=e,!ht[`${p[0]}-${e}`]&&this.utils?.hasLoadedNamespace&&!this.utils?.hasLoadedNamespace(o)&&(ht[`${p[0]}-${e}`]=!0,this.logger.warn(`key "${r}" for languages "${p.join(`, `)}" won't get resolved as namespace "${o}" was not yet loaded`,`This means something IS WRONG in your setup. You access the t function before i18next.init / i18next.loadNamespace / i18next.changeLanguage was done. Wait for the callback or Promise to resolve before accessing it!!!`)),p.forEach(r=>{if(this.isValidLookup(n))return;a=r;let o=[c];if(this.i18nFormat?.addLookupKeys)this.i18nFormat.addLookupKeys(o,c,r,e,t);else{let e;u&&(e=this.pluralResolver.getSuffix(r,t.count,t));let n=`${this.options.pluralSeparator}zero`,i=`${this.options.pluralSeparator}ordinal${this.options.pluralSeparator}`;if(u&&(t.ordinal&&e.indexOf(i)===0&&o.push(c+e.replace(i,this.options.pluralSeparator)),o.push(c+e),d&&o.push(c+n)),f){let r=`${c}${this.options.contextSeparator||`_`}${t.context}`;o.push(r),u&&(t.ordinal&&e.indexOf(i)===0&&o.push(r+e.replace(i,this.options.pluralSeparator)),o.push(r+e),d&&o.push(r+n))}}let s;for(;s=o.pop();)this.isValidLookup(n)||(i=s,n=this.getResource(r,e,s,t))}))})}),{res:n,usedKey:r,exactUsedKey:i,usedLng:a,usedNS:o}}isValidLookup(e){return e!==void 0&&!(!this.options.returnNull&&e===null)&&!(!this.options.returnEmptyString&&e===``)}getResource(e,t,n,r={}){return this.i18nFormat?.getResource?this.i18nFormat.getResource(e,t,n,r):this.resourceStore.getResource(e,t,n,r)}getUsedParamsDetails(e={}){let t=[`defaultValue`,`ordinal`,`context`,`replace`,`lng`,`lngs`,`fallbackLng`,`ns`,`keySeparator`,`nsSeparator`,`returnObjects`,`returnDetails`,`joinArrays`,`postProcess`,`interpolation`],n=e.replace&&!G(e.replace),r=n?e.replace:e;if(n&&e.count!==void 0&&(r.count=e.count),this.options.interpolation.defaultVariables&&(r={...this.options.interpolation.defaultVariables,...r}),!n){r={...r};for(let e of t)delete r[e]}return r}static hasDefaultValue(e){for(let t in e)if(Object.prototype.hasOwnProperty.call(e,t)&&t.substring(0,12)===`defaultValue`&&e[t]!==void 0)return!0;return!1}},vt=class{constructor(e){this.options=e,this.supportedLngs=this.options.supportedLngs||!1,this.logger=ct.create(`languageUtils`)}getScriptPartFromCode(e){if(e=ot(e),!e||e.indexOf(`-`)<0)return null;let t=e.split(`-`);return t.length===2||(t.pop(),t[t.length-1].toLowerCase()===`x`)?null:this.formatLanguageCode(t.join(`-`))}getLanguagePartFromCode(e){if(e=ot(e),!e||e.indexOf(`-`)<0)return e;let t=e.split(`-`);return this.formatLanguageCode(t[0])}formatLanguageCode(e){if(G(e)&&e.indexOf(`-`)>-1){let t;try{t=Intl.getCanonicalLocales(e)[0]}catch{}return t&&this.options.lowerCaseLng&&(t=t.toLowerCase()),t||(this.options.lowerCaseLng?e.toLowerCase():e)}return this.options.cleanCode||this.options.lowerCaseLng?e.toLowerCase():e}isSupportedCode(e){return(this.options.load===`languageOnly`||this.options.nonExplicitSupportedLngs)&&(e=this.getLanguagePartFromCode(e)),!this.supportedLngs||!this.supportedLngs.length||this.supportedLngs.indexOf(e)>-1}getBestMatchFromCodes(e){if(!e)return null;let t;return e.forEach(e=>{if(t)return;let n=this.formatLanguageCode(e);(!this.options.supportedLngs||this.isSupportedCode(n))&&(t=n)}),!t&&this.options.supportedLngs&&e.forEach(e=>{if(t)return;let n=this.getScriptPartFromCode(e);if(this.isSupportedCode(n))return t=n;let r=this.getLanguagePartFromCode(e);if(this.isSupportedCode(r))return t=r;t=this.options.supportedLngs.find(e=>{if(e===r||!(e.indexOf(`-`)<0&&r.indexOf(`-`)<0)&&(e.indexOf(`-`)>0&&r.indexOf(`-`)<0&&e.substring(0,e.indexOf(`-`))===r||e.indexOf(r)===0&&r.length>1))return e})}),t||=this.getFallbackCodes(this.options.fallbackLng)[0],t}getFallbackCodes(e,t){if(!e)return[];if(typeof e==`function`&&(e=e(t)),G(e)&&(e=[e]),Array.isArray(e))return e;if(!t)return e.default||[];let n=e[t];return n||=e[this.getScriptPartFromCode(t)],n||=e[this.formatLanguageCode(t)],n||=e[this.getLanguagePartFromCode(t)],n||=e.default,n||[]}toResolveHierarchy(e,t){let n=this.getFallbackCodes((t===!1?[]:t)||this.options.fallbackLng||[],e),r=[],i=e=>{e&&(this.isSupportedCode(e)?r.push(e):this.logger.warn(`rejecting language code not found in supportedLngs: ${e}`))};return G(e)&&(e.indexOf(`-`)>-1||e.indexOf(`_`)>-1)?(this.options.load!==`languageOnly`&&i(this.formatLanguageCode(e)),this.options.load!==`languageOnly`&&this.options.load!==`currentOnly`&&i(this.getScriptPartFromCode(e)),this.options.load!==`currentOnly`&&i(this.getLanguagePartFromCode(e))):G(e)&&i(this.formatLanguageCode(e)),n.forEach(e=>{r.indexOf(e)<0&&i(this.formatLanguageCode(e))}),r}},yt={zero:0,one:1,two:2,few:3,many:4,other:5},bt={select:e=>e===1?`one`:`other`,resolvedOptions:()=>({pluralCategories:[`one`,`other`]})},xt=class{constructor(e,t={}){this.languageUtils=e,this.options=t,this.logger=ct.create(`pluralResolver`),this.pluralRulesCache={}}addRule(e,t){this.rules[e]=t}clearCache(){this.pluralRulesCache={}}getRule(e,t={}){let n=ot(e===`dev`?`en`:e),r=t.ordinal?`ordinal`:`cardinal`,i=JSON.stringify({cleanedCode:n,type:r});if(i in this.pluralRulesCache)return this.pluralRulesCache[i];let a;try{a=new Intl.PluralRules(n,{type:r})}catch{if(!Intl)return this.logger.error(`No Intl support, please use an Intl polyfill!`),bt;if(!e.match(/-|_/))return bt;let n=this.languageUtils.getLanguagePartFromCode(e);a=this.getRule(n,t)}return this.pluralRulesCache[i]=a,a}needsPlural(e,t={}){let n=this.getRule(e,t);return n||=this.getRule(`dev`,t),n?.resolvedOptions().pluralCategories.length>1}getPluralFormsOfKey(e,t,n={}){return this.getSuffixes(e,n).map(e=>`${t}${e}`)}getSuffixes(e,t={}){let n=this.getRule(e,t);return n||=this.getRule(`dev`,t),n?n.resolvedOptions().pluralCategories.sort((e,t)=>yt[e]-yt[t]).map(e=>`${this.options.prepend}${t.ordinal?`ordinal${this.options.prepend}`:``}${e}`):[]}getSuffix(e,t,n={}){let r=this.getRule(e,n);return r?`${this.options.prepend}${n.ordinal?`ordinal${this.options.prepend}`:``}${r.select(t)}`:(this.logger.warn(`no plural rule found for: ${e}`),this.getSuffix(`dev`,t,n))}},St=(e,t,n,r=`.`,i=!0)=>{let a=Xe(e,t,n);return!a&&i&&G(n)&&(a=at(e,n,r),a===void 0&&(a=at(t,n,r))),a},Ct=e=>e.replace(/\$/g,`$$$$`),wt=class{constructor(e={}){this.logger=ct.create(`interpolator`),this.options=e,this.format=e?.interpolation?.format||(e=>e),this.init(e)}init(e={}){e.interpolation||={escapeValue:!0};let{escape:t,escapeValue:n,useRawValueToEscape:r,prefix:i,prefixEscaped:a,suffix:o,suffixEscaped:s,formatSeparator:c,unescapeSuffix:l,unescapePrefix:u,nestingPrefix:d,nestingPrefixEscaped:f,nestingSuffix:p,nestingSuffixEscaped:m,nestingOptionsSeparator:h,maxReplaces:g,alwaysFormat:_}=e.interpolation;this.escape=t===void 0?et:t,this.escapeValue=n===void 0?!0:n,this.useRawValueToEscape=r===void 0?!1:r,this.prefix=i?Qe(i):a||`{{`,this.suffix=o?Qe(o):s||`}}`,this.formatSeparator=c||`,`,this.unescapePrefix=l?``:u||`-`,this.unescapeSuffix=this.unescapePrefix?``:l||``,this.nestingPrefix=d?Qe(d):f||Qe(`$t(`),this.nestingSuffix=p?Qe(p):m||Qe(`)`),this.nestingOptionsSeparator=h||`,`,this.maxReplaces=g||1e3,this.alwaysFormat=_===void 0?!1:_,this.resetRegExp()}reset(){this.options&&this.init(this.options)}resetRegExp(){let e=(e,t)=>e?.source===t?(e.lastIndex=0,e):new RegExp(t,`g`);this.regexp=e(this.regexp,`${this.prefix}(.+?)${this.suffix}`),this.regexpUnescape=e(this.regexpUnescape,`${this.prefix}${this.unescapePrefix}(.+?)${this.unescapeSuffix}${this.suffix}`),this.nestingRegexp=e(this.nestingRegexp,`${this.nestingPrefix}((?:[^()"']+|"[^"]*"|'[^']*'|\\((?:[^()]|"[^"]*"|'[^']*')*\\))*?)${this.nestingSuffix}`)}interpolate(e,t,n,r){let i,a,o,s=this.options&&this.options.interpolation&&this.options.interpolation.defaultVariables||{},c=e=>{if(e.indexOf(this.formatSeparator)<0){let i=St(t,s,e,this.options.keySeparator,this.options.ignoreJSONStructure);return this.alwaysFormat?this.format(i,void 0,n,{...r,...t,interpolationkey:e}):i}let i=e.split(this.formatSeparator),a=i.shift().trim(),o=i.join(this.formatSeparator).trim();return this.format(St(t,s,a,this.options.keySeparator,this.options.ignoreJSONStructure),o,n,{...r,...t,interpolationkey:a})};this.resetRegExp();let l=r?.missingInterpolationHandler||this.options.missingInterpolationHandler,u=r?.interpolation?.skipOnVariables===void 0?this.options.interpolation.skipOnVariables:r.interpolation.skipOnVariables;return[{regex:this.regexpUnescape,safeValue:e=>Ct(e)},{regex:this.regexp,safeValue:e=>this.escapeValue?Ct(this.escape(e)):Ct(e)}].forEach(t=>{for(o=0;i=t.regex.exec(e);){let n=i[1].trim();if(a=c(n),a===void 0)if(typeof l==`function`){let t=l(e,i,r);a=G(t)?t:``}else if(r&&Object.prototype.hasOwnProperty.call(r,n))a=``;else if(u){a=i[0];continue}else this.logger.warn(`missed to pass in variable ${n} for interpolating ${e}`),a=``;else !G(a)&&!this.useRawValueToEscape&&(a=Ve(a));let s=t.safeValue(a);if(e=e.replace(i[0],s),u?(t.regex.lastIndex+=a.length,t.regex.lastIndex-=i[0].length):t.regex.lastIndex=0,o++,o>=this.maxReplaces)break}}),e}nest(e,t,n={}){let r,i,a,o=(e,t)=>{let n=this.nestingOptionsSeparator;if(e.indexOf(n)<0)return e;let r=e.split(RegExp(`${n}[ ]*{`)),i=`{${r[1]}`;e=r[0],i=this.interpolate(i,a);let o=i.match(/'/g),s=i.match(/"/g);((o?.length??0)%2==0&&!s||s.length%2!=0)&&(i=i.replace(/'/g,`"`));try{a=JSON.parse(i),t&&(a={...t,...a})}catch(t){return this.logger.warn(`failed parsing options string in nesting for key ${e}`,t),`${e}${n}${i}`}return a.defaultValue&&a.defaultValue.indexOf(this.prefix)>-1&&delete a.defaultValue,e};for(;r=this.nestingRegexp.exec(e);){let s=[];a={...n},a=a.replace&&!G(a.replace)?a.replace:a,a.applyPostProcessor=!1,delete a.defaultValue;let c=/{.*}/.test(r[1])?r[1].lastIndexOf(`}`)+1:r[1].indexOf(this.formatSeparator);if(c!==-1&&(s=r[1].slice(c).split(this.formatSeparator).map(e=>e.trim()).filter(Boolean),r[1]=r[1].slice(0,c)),i=t(o.call(this,r[1].trim(),a),a),i&&r[0]===e&&!G(i))return i;G(i)||(i=Ve(i)),i||=(this.logger.warn(`missed to resolve ${r[1]} for nesting ${e}`),``),s.length&&(i=s.reduce((e,t)=>this.format(e,t,n.lng,{...n,interpolationkey:r[1].trim()}),i.trim())),e=e.replace(r[0],i),this.regexp.lastIndex=0}return e}},Tt=e=>{let t=e.toLowerCase().trim(),n={};if(e.indexOf(`(`)>-1){let r=e.split(`(`);t=r[0].toLowerCase().trim();let i=r[1].substring(0,r[1].length-1);t===`currency`&&i.indexOf(`:`)<0?n.currency||=i.trim():t===`relativetime`&&i.indexOf(`:`)<0?n.range||=i.trim():i.split(`;`).forEach(e=>{if(e){let[t,...r]=e.split(`:`),i=r.join(`:`).trim().replace(/^'+|'+$/g,``),a=t.trim();n[a]||(n[a]=i),i===`false`&&(n[a]=!1),i===`true`&&(n[a]=!0),isNaN(i)||(n[a]=parseInt(i,10))}})}return{formatName:t,formatOptions:n}},Et=e=>{let t={};return(n,r,i)=>{let a=i;i&&i.interpolationkey&&i.formatParams&&i.formatParams[i.interpolationkey]&&i[i.interpolationkey]&&(a={...a,[i.interpolationkey]:void 0});let o=r+JSON.stringify(a),s=t[o];return s||(s=e(ot(r),i),t[o]=s),s(n)}},Dt=e=>(t,n,r)=>e(ot(n),r)(t),Ot=class{constructor(e={}){this.logger=ct.create(`formatter`),this.options=e,this.init(e)}init(e,t={interpolation:{}}){this.formatSeparator=t.interpolation.formatSeparator||`,`;let n=t.cacheInBuiltFormats?Et:Dt;this.formats={number:n((e,t)=>{let n=new Intl.NumberFormat(e,{...t});return e=>n.format(e)}),currency:n((e,t)=>{let n=new Intl.NumberFormat(e,{...t,style:`currency`});return e=>n.format(e)}),datetime:n((e,t)=>{let n=new Intl.DateTimeFormat(e,{...t});return e=>n.format(e)}),relativetime:n((e,t)=>{let n=new Intl.RelativeTimeFormat(e,{...t});return e=>n.format(e,t.range||`day`)}),list:n((e,t)=>{let n=new Intl.ListFormat(e,{...t});return e=>n.format(e)})}}add(e,t){this.formats[e.toLowerCase().trim()]=t}addCached(e,t){this.formats[e.toLowerCase().trim()]=Et(t)}format(e,t,n,r={}){let i=t.split(this.formatSeparator);if(i.length>1&&i[0].indexOf(`(`)>1&&i[0].indexOf(`)`)<0&&i.find(e=>e.indexOf(`)`)>-1)){let e=i.findIndex(e=>e.indexOf(`)`)>-1);i[0]=[i[0],...i.splice(1,e)].join(this.formatSeparator)}return i.reduce((e,t)=>{let{formatName:i,formatOptions:a}=Tt(t);if(this.formats[i]){let t=e;try{let o=r?.formatParams?.[r.interpolationkey]||{},s=o.locale||o.lng||r.locale||r.lng||n;t=this.formats[i](e,s,{...a,...r,...o})}catch(e){this.logger.warn(e)}return t}else this.logger.warn(`there was no format function for ${i}`);return e},e)}},kt=(e,t)=>{e.pending[t]!==void 0&&(delete e.pending[t],e.pendingCount--)},At=class extends lt{constructor(e,t,n,r={}){super(),this.backend=e,this.store=t,this.services=n,this.languageUtils=n.languageUtils,this.options=r,this.logger=ct.create(`backendConnector`),this.waitingReads=[],this.maxParallelReads=r.maxParallelReads||10,this.readingCalls=0,this.maxRetries=r.maxRetries>=0?r.maxRetries:5,this.retryTimeout=r.retryTimeout>=1?r.retryTimeout:350,this.state={},this.queue=[],this.backend?.init?.(n,r.backend,r)}queueLoad(e,t,n,r){let i={},a={},o={},s={};return e.forEach(e=>{let r=!0;t.forEach(t=>{let o=`${e}|${t}`;!n.reload&&this.store.hasResourceBundle(e,t)?this.state[o]=2:this.state[o]<0||(this.state[o]===1?a[o]===void 0&&(a[o]=!0):(this.state[o]=1,r=!1,a[o]===void 0&&(a[o]=!0),i[o]===void 0&&(i[o]=!0),s[t]===void 0&&(s[t]=!0)))}),r||(o[e]=!0)}),(Object.keys(i).length||Object.keys(a).length)&&this.queue.push({pending:a,pendingCount:Object.keys(a).length,loaded:{},errors:[],callback:r}),{toLoad:Object.keys(i),pending:Object.keys(a),toLoadLanguages:Object.keys(o),toLoadNamespaces:Object.keys(s)}}loaded(e,t,n){let r=e.split(`|`),i=r[0],a=r[1];t&&this.emit(`failedLoading`,i,a,t),!t&&n&&this.store.addResourceBundle(i,a,n,void 0,void 0,{skipCopy:!0}),this.state[e]=t?-1:2,t&&n&&(this.state[e]=0);let o={};this.queue.forEach(n=>{Je(n.loaded,[i],a),kt(n,e),t&&n.errors.push(t),n.pendingCount===0&&!n.done&&(Object.keys(n.loaded).forEach(e=>{o[e]||(o[e]={});let t=n.loaded[e];t.length&&t.forEach(t=>{o[e][t]===void 0&&(o[e][t]=!0)})}),n.done=!0,n.errors.length?n.callback(n.errors):n.callback())}),this.emit(`loaded`,o),this.queue=this.queue.filter(e=>!e.done)}read(e,t,n,r=0,i=this.retryTimeout,a){if(!e.length)return a(null,{});if(this.readingCalls>=this.maxParallelReads){this.waitingReads.push({lng:e,ns:t,fcName:n,tried:r,wait:i,callback:a});return}this.readingCalls++;let o=(o,s)=>{if(this.readingCalls--,this.waitingReads.length>0){let e=this.waitingReads.shift();this.read(e.lng,e.ns,e.fcName,e.tried,e.wait,e.callback)}if(o&&s&&r<this.maxRetries){setTimeout(()=>{this.read.call(this,e,t,n,r+1,i*2,a)},i);return}a(o,s)},s=this.backend[n].bind(this.backend);if(s.length===2){try{let n=s(e,t);n&&typeof n.then==`function`?n.then(e=>o(null,e)).catch(o):o(null,n)}catch(e){o(e)}return}return s(e,t,o)}prepareLoading(e,t,n={},r){if(!this.backend)return this.logger.warn(`No backend was added via i18next.use. Will not load resources.`),r&&r();G(e)&&(e=this.languageUtils.toResolveHierarchy(e)),G(t)&&(t=[t]);let i=this.queueLoad(e,t,n,r);if(!i.toLoad.length)return i.pending.length||r(),null;i.toLoad.forEach(e=>{this.loadOne(e)})}load(e,t,n){this.prepareLoading(e,t,{},n)}reload(e,t,n){this.prepareLoading(e,t,{reload:!0},n)}loadOne(e,t=``){let n=e.split(`|`),r=n[0],i=n[1];this.read(r,i,`read`,void 0,void 0,(n,a)=>{n&&this.logger.warn(`${t}loading namespace ${i} for language ${r} failed`,n),!n&&a&&this.logger.log(`${t}loaded namespace ${i} for language ${r}`,a),this.loaded(e,n,a)})}saveMissing(e,t,n,r,i,a={},o=()=>{}){if(this.services?.utils?.hasLoadedNamespace&&!this.services?.utils?.hasLoadedNamespace(t)){this.logger.warn(`did not save key "${n}" as the namespace "${t}" was not yet loaded`,`This means something IS WRONG in your setup. You access the t function before i18next.init / i18next.loadNamespace / i18next.changeLanguage was done. Wait for the callback or Promise to resolve before accessing it!!!`);return}if(!(n==null||n===``)){if(this.backend?.create){let s={...a,isUpdate:i},c=this.backend.create.bind(this.backend);if(c.length<6)try{let i;i=c.length===5?c(e,t,n,r,s):c(e,t,n,r),i&&typeof i.then==`function`?i.then(e=>o(null,e)).catch(o):o(null,i)}catch(e){o(e)}else c(e,t,n,r,o,s)}!e||!e[0]||this.store.addResource(e[0],t,n,r)}}},jt=()=>({debug:!1,initAsync:!0,ns:[`translation`],defaultNS:[`translation`],fallbackLng:[`dev`],fallbackNS:!1,supportedLngs:!1,nonExplicitSupportedLngs:!1,load:`all`,preload:!1,simplifyPluralSuffix:!0,keySeparator:`.`,nsSeparator:`:`,pluralSeparator:`_`,contextSeparator:`_`,partialBundledLanguages:!1,saveMissing:!1,updateMissing:!1,saveMissingTo:`fallback`,saveMissingPlurals:!0,missingKeyHandler:!1,missingInterpolationHandler:!1,postProcess:!1,postProcessPassResolved:!1,returnNull:!1,returnEmptyString:!0,returnObjects:!1,joinArrays:!1,returnedObjectHandler:!1,parseMissingKeyHandler:!1,appendNamespaceToMissingKey:!1,appendNamespaceToCIMode:!1,overloadTranslationOptionHandler:e=>{let t={};if(typeof e[1]==`object`&&(t=e[1]),G(e[1])&&(t.defaultValue=e[1]),G(e[2])&&(t.tDescription=e[2]),typeof e[2]==`object`||typeof e[3]==`object`){let n=e[3]||e[2];Object.keys(n).forEach(e=>{t[e]=n[e]})}return t},interpolation:{escapeValue:!0,format:e=>e,prefix:`{{`,suffix:`}}`,formatSeparator:`,`,unescapePrefix:`-`,nestingPrefix:`$t(`,nestingSuffix:`)`,nestingOptionsSeparator:`,`,maxReplaces:1e3,skipOnVariables:!0},cacheInBuiltFormats:!0}),Mt=e=>(G(e.ns)&&(e.ns=[e.ns]),G(e.fallbackLng)&&(e.fallbackLng=[e.fallbackLng]),G(e.fallbackNS)&&(e.fallbackNS=[e.fallbackNS]),e.supportedLngs?.indexOf?.(`cimode`)<0&&(e.supportedLngs=e.supportedLngs.concat([`cimode`])),typeof e.initImmediate==`boolean`&&(e.initAsync=e.initImmediate),e),Nt=()=>{},Pt=e=>{Object.getOwnPropertyNames(Object.getPrototypeOf(e)).forEach(t=>{typeof e[t]==`function`&&(e[t]=e[t].bind(e))})},Ft=class e extends lt{constructor(e={},t){if(super(),this.options=Mt(e),this.services={},this.logger=ct,this.modules={external:[]},Pt(this),t&&!this.isInitialized&&!e.isClone){if(!this.options.initAsync)return this.init(e,t),this;setTimeout(()=>{this.init(e,t)},0)}}init(e={},t){this.isInitializing=!0,typeof e==`function`&&(t=e,e={}),e.defaultNS==null&&e.ns&&(G(e.ns)?e.defaultNS=e.ns:e.ns.indexOf(`translation`)<0&&(e.defaultNS=e.ns[0]));let n=jt();this.options={...n,...this.options,...Mt(e)},this.options.interpolation={...n.interpolation,...this.options.interpolation},e.keySeparator!==void 0&&(this.options.userDefinedKeySeparator=e.keySeparator),e.nsSeparator!==void 0&&(this.options.userDefinedNsSeparator=e.nsSeparator);let r=e=>e?typeof e==`function`?new e:e:null;if(!this.options.isClone){this.modules.logger?ct.init(r(this.modules.logger),this.options):ct.init(null,this.options);let e;e=this.modules.formatter?this.modules.formatter:Ot;let t=new vt(this.options);this.store=new ut(this.options.resources,this.options);let i=this.services;i.logger=ct,i.resourceStore=this.store,i.languageUtils=t,i.pluralResolver=new xt(t,{prepend:this.options.pluralSeparator,simplifyPluralSuffix:this.options.simplifyPluralSuffix}),this.options.interpolation.format&&this.options.interpolation.format!==n.interpolation.format&&this.logger.deprecate(`init: you are still using the legacy format function, please use the new approach: https://www.i18next.com/translation-function/formatting`),e&&(!this.options.interpolation.format||this.options.interpolation.format===n.interpolation.format)&&(i.formatter=r(e),i.formatter.init&&i.formatter.init(i,this.options),this.options.interpolation.format=i.formatter.format.bind(i.formatter)),i.interpolator=new wt(this.options),i.utils={hasLoadedNamespace:this.hasLoadedNamespace.bind(this)},i.backendConnector=new At(r(this.modules.backend),i.resourceStore,i,this.options),i.backendConnector.on(`*`,(e,...t)=>{this.emit(e,...t)}),this.modules.languageDetector&&(i.languageDetector=r(this.modules.languageDetector),i.languageDetector.init&&i.languageDetector.init(i,this.options.detection,this.options)),this.modules.i18nFormat&&(i.i18nFormat=r(this.modules.i18nFormat),i.i18nFormat.init&&i.i18nFormat.init(this)),this.translator=new _t(this.services,this.options),this.translator.on(`*`,(e,...t)=>{this.emit(e,...t)}),this.modules.external.forEach(e=>{e.init&&e.init(this)})}if(this.format=this.options.interpolation.format,t||=Nt,this.options.fallbackLng&&!this.services.languageDetector&&!this.options.lng){let e=this.services.languageUtils.getFallbackCodes(this.options.fallbackLng);e.length>0&&e[0]!==`dev`&&(this.options.lng=e[0])}!this.services.languageDetector&&!this.options.lng&&this.logger.warn(`init: no languageDetector is used and no lng is defined`),[`getResource`,`hasResourceBundle`,`getResourceBundle`,`getDataByLanguage`].forEach(e=>{this[e]=(...t)=>this.store[e](...t)}),[`addResource`,`addResources`,`addResourceBundle`,`removeResourceBundle`].forEach(e=>{this[e]=(...t)=>(this.store[e](...t),this)});let i=Be(),a=()=>{let e=(e,n)=>{this.isInitializing=!1,this.isInitialized&&!this.initializedStoreOnce&&this.logger.warn(`init: i18next is already initialized. You should call init just once!`),this.isInitialized=!0,this.options.isClone||this.logger.log(`initialized`,this.options),this.emit(`initialized`,this.options),i.resolve(n),t(e,n)};if(this.languages&&!this.isInitialized)return e(null,this.t.bind(this));this.changeLanguage(this.options.lng,e)};return this.options.resources||!this.options.initAsync?a():setTimeout(a,0),i}loadResources(e,t=Nt){let n=t,r=G(e)?e:this.language;if(typeof e==`function`&&(n=e),!this.options.resources||this.options.partialBundledLanguages){if(r?.toLowerCase()===`cimode`&&(!this.options.preload||this.options.preload.length===0))return n();let e=[],t=t=>{t&&t!==`cimode`&&this.services.languageUtils.toResolveHierarchy(t).forEach(t=>{t!==`cimode`&&e.indexOf(t)<0&&e.push(t)})};r?t(r):this.services.languageUtils.getFallbackCodes(this.options.fallbackLng).forEach(e=>t(e)),this.options.preload?.forEach?.(e=>t(e)),this.services.backendConnector.load(e,this.options.ns,e=>{!e&&!this.resolvedLanguage&&this.language&&this.setResolvedLanguage(this.language),n(e)})}else n(null)}reloadResources(e,t,n){let r=Be();return typeof e==`function`&&(n=e,e=void 0),typeof t==`function`&&(n=t,t=void 0),e||=this.languages,t||=this.options.ns,n||=Nt,this.services.backendConnector.reload(e,t,e=>{r.resolve(),n(e)}),r}use(e){if(!e)throw Error(`You are passing an undefined module! Please check the object you are passing to i18next.use()`);if(!e.type)throw Error(`You are passing a wrong module! Please check the object you are passing to i18next.use()`);return e.type===`backend`&&(this.modules.backend=e),(e.type===`logger`||e.log&&e.warn&&e.error)&&(this.modules.logger=e),e.type===`languageDetector`&&(this.modules.languageDetector=e),e.type===`i18nFormat`&&(this.modules.i18nFormat=e),e.type===`postProcessor`&&dt.addPostProcessor(e),e.type===`formatter`&&(this.modules.formatter=e),e.type===`3rdParty`&&this.modules.external.push(e),this}setResolvedLanguage(e){if(!(!e||!this.languages)&&!([`cimode`,`dev`].indexOf(e)>-1)){for(let e=0;e<this.languages.length;e++){let t=this.languages[e];if(!([`cimode`,`dev`].indexOf(t)>-1)&&this.store.hasLanguageSomeTranslations(t)){this.resolvedLanguage=t;break}}!this.resolvedLanguage&&this.languages.indexOf(e)<0&&this.store.hasLanguageSomeTranslations(e)&&(this.resolvedLanguage=e,this.languages.unshift(e))}}changeLanguage(e,t){this.isLanguageChangingTo=e;let n=Be();this.emit(`languageChanging`,e);let r=e=>{this.language=e,this.languages=this.services.languageUtils.toResolveHierarchy(e),this.resolvedLanguage=void 0,this.setResolvedLanguage(e)},i=(i,a)=>{a?this.isLanguageChangingTo===e&&(r(a),this.translator.changeLanguage(a),this.isLanguageChangingTo=void 0,this.emit(`languageChanged`,a),this.logger.log(`languageChanged`,a)):this.isLanguageChangingTo=void 0,n.resolve((...e)=>this.t(...e)),t&&t(i,(...e)=>this.t(...e))},a=t=>{!e&&!t&&this.services.languageDetector&&(t=[]);let n=G(t)?t:t&&t[0],a=this.store.hasLanguageSomeTranslations(n)?n:this.services.languageUtils.getBestMatchFromCodes(G(t)?[t]:t);a&&(this.language||r(a),this.translator.language||this.translator.changeLanguage(a),this.services.languageDetector?.cacheUserLanguage?.(a)),this.loadResources(a,e=>{i(e,a)})};return!e&&this.services.languageDetector&&!this.services.languageDetector.async?a(this.services.languageDetector.detect()):!e&&this.services.languageDetector&&this.services.languageDetector.async?this.services.languageDetector.detect.length===0?this.services.languageDetector.detect().then(a):this.services.languageDetector.detect(a):a(e),n}getFixedT(e,t,n){let r=(e,t,...i)=>{let a;a=typeof t==`object`?{...t}:this.options.overloadTranslationOptionHandler([e,t].concat(i)),a.lng=a.lng||r.lng,a.lngs=a.lngs||r.lngs,a.ns=a.ns||r.ns,a.keyPrefix!==``&&(a.keyPrefix=a.keyPrefix||n||r.keyPrefix);let o=this.options.keySeparator||`.`,s;return a.keyPrefix&&Array.isArray(e)?s=e.map(e=>(typeof e==`function`&&(e=mt(e,{...this.options,...t})),`${a.keyPrefix}${o}${e}`)):(typeof e==`function`&&(e=mt(e,{...this.options,...t})),s=a.keyPrefix?`${a.keyPrefix}${o}${e}`:e),this.t(s,a)};return G(e)?r.lng=e:r.lngs=e,r.ns=t,r.keyPrefix=n,r}t(...e){return this.translator?.translate(...e)}exists(...e){return this.translator?.exists(...e)}setDefaultNamespace(e){this.options.defaultNS=e}hasLoadedNamespace(e,t={}){if(!this.isInitialized)return this.logger.warn(`hasLoadedNamespace: i18next was not initialized`,this.languages),!1;if(!this.languages||!this.languages.length)return this.logger.warn(`hasLoadedNamespace: i18n.languages were undefined or empty`,this.languages),!1;let n=t.lng||this.resolvedLanguage||this.languages[0],r=this.options?this.options.fallbackLng:!1,i=this.languages[this.languages.length-1];if(n.toLowerCase()===`cimode`)return!0;let a=(e,t)=>{let n=this.services.backendConnector.state[`${e}|${t}`];return n===-1||n===0||n===2};if(t.precheck){let e=t.precheck(this,a);if(e!==void 0)return e}return!!(this.hasResourceBundle(n,e)||!this.services.backendConnector.backend||this.options.resources&&!this.options.partialBundledLanguages||a(n,e)&&(!r||a(i,e)))}loadNamespaces(e,t){let n=Be();return this.options.ns?(G(e)&&(e=[e]),e.forEach(e=>{this.options.ns.indexOf(e)<0&&this.options.ns.push(e)}),this.loadResources(e=>{n.resolve(),t&&t(e)}),n):(t&&t(),Promise.resolve())}loadLanguages(e,t){let n=Be();G(e)&&(e=[e]);let r=this.options.preload||[],i=e.filter(e=>r.indexOf(e)<0&&this.services.languageUtils.isSupportedCode(e));return i.length?(this.options.preload=r.concat(i),this.loadResources(e=>{n.resolve(),t&&t(e)}),n):(t&&t(),Promise.resolve())}dir(e){if(e||=this.resolvedLanguage||(this.languages?.length>0?this.languages[0]:this.language),!e)return`rtl`;try{let t=new Intl.Locale(e);if(t&&t.getTextInfo){let e=t.getTextInfo();if(e&&e.direction)return e.direction}}catch{}let t=`ar.shu.sqr.ssh.xaa.yhd.yud.aao.abh.abv.acm.acq.acw.acx.acy.adf.ads.aeb.aec.afb.ajp.apc.apd.arb.arq.ars.ary.arz.auz.avl.ayh.ayl.ayn.ayp.bbz.pga.he.iw.ps.pbt.pbu.pst.prp.prd.ug.ur.ydd.yds.yih.ji.yi.hbo.men.xmn.fa.jpr.peo.pes.prs.dv.sam.ckb`.split(`.`),n=this.services?.languageUtils||new vt(jt());return e.toLowerCase().indexOf(`-latn`)>1?`ltr`:t.indexOf(n.getLanguagePartFromCode(e))>-1||e.toLowerCase().indexOf(`-arab`)>1?`rtl`:`ltr`}static createInstance(t={},n){let r=new e(t,n);return r.createInstance=e.createInstance,r}cloneInstance(t={},n=Nt){let r=t.forkResourceStore;r&&delete t.forkResourceStore;let i={...this.options,...t,isClone:!0},a=new e(i);return(t.debug!==void 0||t.prefix!==void 0)&&(a.logger=a.logger.clone(t)),[`store`,`services`,`language`].forEach(e=>{a[e]=this[e]}),a.services={...this.services},a.services.utils={hasLoadedNamespace:a.hasLoadedNamespace.bind(a)},r&&(a.store=new ut(Object.keys(this.store.data).reduce((e,t)=>(e[t]={...this.store.data[t]},e[t]=Object.keys(e[t]).reduce((n,r)=>(n[r]={...e[t][r]},n),e[t]),e),{}),i),a.services.resourceStore=a.store),a.translator=new _t(a.services,i),a.translator.on(`*`,(e,...t)=>{a.emit(e,...t)}),a.init(i,n),a.translator.options=i,a.translator.backendConnector.services.utils={hasLoadedNamespace:a.hasLoadedNamespace.bind(a)},a}toJSON(){return{options:this.options,store:this.store,language:this.language,languages:this.languages,resolvedLanguage:this.resolvedLanguage}}}.createInstance();Ft.createInstance,Ft.dir,Ft.init,Ft.loadResources,Ft.reloadResources,Ft.use,Ft.changeLanguage,Ft.getFixedT,Ft.t,Ft.exists,Ft.setDefaultNamespace,Ft.hasLoadedNamespace,Ft.loadNamespaces,Ft.loadLanguages;var{slice:It,forEach:Lt}=[];function Rt(e){return Lt.call(It.call(arguments,1),t=>{if(t)for(let n in t)e[n]===void 0&&(e[n]=t[n])}),e}function zt(e){return typeof e==`string`?[/<\s*script.*?>/i,/<\s*\/\s*script\s*>/i,/<\s*img.*?on\w+\s*=/i,/<\s*\w+\s*on\w+\s*=.*?>/i,/javascript\s*:/i,/vbscript\s*:/i,/expression\s*\(/i,/eval\s*\(/i,/alert\s*\(/i,/document\.cookie/i,/document\.write\s*\(/i,/window\.location/i,/innerHTML/i].some(t=>t.test(e)):!1}var Bt=/^[\u0009\u0020-\u007e\u0080-\u00ff]+$/,Vt=function(e,t){let n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{path:`/`},r=`${e}=${encodeURIComponent(t)}`;if(n.maxAge>0){let e=n.maxAge-0;if(Number.isNaN(e))throw Error(`maxAge should be a Number`);r+=`; Max-Age=${Math.floor(e)}`}if(n.domain){if(!Bt.test(n.domain))throw TypeError(`option domain is invalid`);r+=`; Domain=${n.domain}`}if(n.path){if(!Bt.test(n.path))throw TypeError(`option path is invalid`);r+=`; Path=${n.path}`}if(n.expires){if(typeof n.expires.toUTCString!=`function`)throw TypeError(`option expires is invalid`);r+=`; Expires=${n.expires.toUTCString()}`}if(n.httpOnly&&(r+=`; HttpOnly`),n.secure&&(r+=`; Secure`),n.sameSite)switch(typeof n.sameSite==`string`?n.sameSite.toLowerCase():n.sameSite){case!0:r+=`; SameSite=Strict`;break;case`lax`:r+=`; SameSite=Lax`;break;case`strict`:r+=`; SameSite=Strict`;break;case`none`:r+=`; SameSite=None`;break;default:throw TypeError(`option sameSite is invalid`)}return n.partitioned&&(r+=`; Partitioned`),r},Ht={create(e,t,n,r){let i=arguments.length>4&&arguments[4]!==void 0?arguments[4]:{path:`/`,sameSite:`strict`};n&&(i.expires=new Date,i.expires.setTime(i.expires.getTime()+n*60*1e3)),r&&(i.domain=r),document.cookie=Vt(e,t,i)},read(e){let t=`${e}=`,n=document.cookie.split(`;`);for(let e=0;e<n.length;e++){let r=n[e];for(;r.charAt(0)===` `;)r=r.substring(1,r.length);if(r.indexOf(t)===0)return r.substring(t.length,r.length)}return null},remove(e,t){this.create(e,``,-1,t)}},Ut={name:`cookie`,lookup(e){let{lookupCookie:t}=e;if(t&&typeof document<`u`)return Ht.read(t)||void 0},cacheUserLanguage(e,t){let{lookupCookie:n,cookieMinutes:r,cookieDomain:i,cookieOptions:a}=t;n&&typeof document<`u`&&Ht.create(n,e,r,i,a)}},Wt={name:`querystring`,lookup(e){let{lookupQuerystring:t}=e,n;if(typeof window<`u`){let{search:e}=window.location;!window.location.search&&window.location.hash?.indexOf(`?`)>-1&&(e=window.location.hash.substring(window.location.hash.indexOf(`?`)));let r=e.substring(1).split(`&`);for(let e=0;e<r.length;e++){let i=r[e].indexOf(`=`);i>0&&r[e].substring(0,i)===t&&(n=r[e].substring(i+1))}}return n}},Gt={name:`hash`,lookup(e){let{lookupHash:t,lookupFromHashIndex:n}=e,r;if(typeof window<`u`){let{hash:e}=window.location;if(e&&e.length>2){let i=e.substring(1);if(t){let e=i.split(`&`);for(let n=0;n<e.length;n++){let i=e[n].indexOf(`=`);i>0&&e[n].substring(0,i)===t&&(r=e[n].substring(i+1))}}if(r)return r;if(!r&&n>-1){let t=e.match(/\/([a-zA-Z-]*)/g);return Array.isArray(t)?t[typeof n==`number`?n:0]?.replace(`/`,``):void 0}}}return r}},Kt=null,qt=()=>{if(Kt!==null)return Kt;try{if(Kt=typeof window<`u`&&window.localStorage!==null,!Kt)return!1;let e=`i18next.translate.boo`;window.localStorage.setItem(e,`foo`),window.localStorage.removeItem(e)}catch{Kt=!1}return Kt},Jt={name:`localStorage`,lookup(e){let{lookupLocalStorage:t}=e;if(t&&qt())return window.localStorage.getItem(t)||void 0},cacheUserLanguage(e,t){let{lookupLocalStorage:n}=t;n&&qt()&&window.localStorage.setItem(n,e)}},Yt=null,Xt=()=>{if(Yt!==null)return Yt;try{if(Yt=typeof window<`u`&&window.sessionStorage!==null,!Yt)return!1;let e=`i18next.translate.boo`;window.sessionStorage.setItem(e,`foo`),window.sessionStorage.removeItem(e)}catch{Yt=!1}return Yt},Zt={name:`sessionStorage`,lookup(e){let{lookupSessionStorage:t}=e;if(t&&Xt())return window.sessionStorage.getItem(t)||void 0},cacheUserLanguage(e,t){let{lookupSessionStorage:n}=t;n&&Xt()&&window.sessionStorage.setItem(n,e)}},Qt={name:`navigator`,lookup(e){let t=[];if(typeof navigator<`u`){let{languages:e,userLanguage:n,language:r}=navigator;if(e)for(let n=0;n<e.length;n++)t.push(e[n]);n&&t.push(n),r&&t.push(r)}return t.length>0?t:void 0}},$t={name:`htmlTag`,lookup(e){let{htmlTag:t}=e,n,r=t||(typeof document<`u`?document.documentElement:null);return r&&typeof r.getAttribute==`function`&&(n=r.getAttribute(`lang`)),n}},en={name:`path`,lookup(e){let{lookupFromPathIndex:t}=e;if(typeof window>`u`)return;let n=window.location.pathname.match(/\/([a-zA-Z-]*)/g);if(Array.isArray(n))return n[typeof t==`number`?t:0]?.replace(`/`,``)}},tn={name:`subdomain`,lookup(e){let{lookupFromSubdomainIndex:t}=e,n=typeof t==`number`?t+1:1,r=typeof window<`u`&&window.location?.hostname?.match(/^(\w{2,5})\.(([a-z0-9-]{1,63}\.[a-z]{2,6})|localhost)/i);if(r)return r[n]}},nn=!1;try{document.cookie,nn=!0}catch{}var rn=[`querystring`,`cookie`,`localStorage`,`sessionStorage`,`navigator`,`htmlTag`];nn||rn.splice(1,1);var an=()=>({order:rn,lookupQuerystring:`lng`,lookupCookie:`i18next`,lookupLocalStorage:`i18nextLng`,lookupSessionStorage:`i18nextLng`,caches:[`localStorage`],excludeCacheFor:[`cimode`],convertDetectedLanguage:e=>e}),on=class{constructor(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};this.type=`languageDetector`,this.detectors={},this.init(e,t)}init(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{languageUtils:{}},t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};this.services=e,this.options=Rt(t,this.options||{},an()),typeof this.options.convertDetectedLanguage==`string`&&this.options.convertDetectedLanguage.indexOf(`15897`)>-1&&(this.options.convertDetectedLanguage=e=>e.replace(`-`,`_`)),this.options.lookupFromUrlIndex&&(this.options.lookupFromPathIndex=this.options.lookupFromUrlIndex),this.i18nOptions=n,this.addDetector(Ut),this.addDetector(Wt),this.addDetector(Jt),this.addDetector(Zt),this.addDetector(Qt),this.addDetector($t),this.addDetector(en),this.addDetector(tn),this.addDetector(Gt)}addDetector(e){return this.detectors[e.name]=e,this}detect(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:this.options.order,t=[];return e.forEach(e=>{if(this.detectors[e]){let n=this.detectors[e].lookup(this.options);n&&typeof n==`string`&&(n=[n]),n&&(t=t.concat(n))}}),t=t.filter(e=>e!=null&&!zt(e)).map(e=>this.options.convertDetectedLanguage(e)),this.services&&this.services.languageUtils&&this.services.languageUtils.getBestMatchFromCodes?t:t.length>0?t[0]:null}cacheUserLanguage(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:this.options.caches;t&&(this.options.excludeCacheFor&&this.options.excludeCacheFor.indexOf(e)>-1||t.forEach(t=>{this.detectors[t]&&this.detectors[t].cacheUserLanguage(e,this.options)}))}};on.type=`languageDetector`;var sn=`bambuddy_chunk_reload_at`,cn=1e4,ln=3e3,un=!1;function dn(){if(un)return!0;try{let e=Number(window.sessionStorage.getItem(sn));if(e&&Date.now()-e<cn)return!1;window.sessionStorage.setItem(sn,String(Date.now()))}catch{return!1}return un=!0,window.location.reload(),!0}async function fn(){try{return(await fetch(`/health`,{cache:`no-store`,redirect:`manual`})).status<500}catch{return!1}}async function pn(){for(;!await fn();)await new Promise(e=>setTimeout(e,ln));return dn()}function K(e,t){return(0,W.lazy)(async()=>{try{return{default:(await e())[t]}}catch(e){if(await pn())return new Promise(()=>{});throw e}})}var mn={nav:{printers:`Printers`,archives:`Archives`,queue:`Print Queue`,stats:`Statistics`,profiles:`Profiles`,maintenance:`Maintenance`,projects:`Projects`,finance:`Finance`,inventory:`Filament`,files:`File Manager`,makerworld:`MakerWorld`,modelSources:`Model Sources`,notifications:`Notifications`,settings:`Settings`,system:`System`,collapseSidebar:`Collapse sidebar`,expandSidebar:`Expand sidebar`,update:`Update`,updateAvailable:`Update available: v{{version}}`,updateAvailableBanner:`Version {{version}} is available!`,viewUpdate:`View update`,viewOnGithub:`View on GitHub`,keyboardShortcuts:`Keyboard shortcuts (?)`,switchToLight:`Switch to light mode`,switchToDark:`Switch to dark mode`,switchToSystem:`Switch to system mode`,smartSwitches:`Smart Switches`,logout:`Logout`,installApp:`Install app`,installAppSuccess:`Bambuddy was installed`},announcements:{title:`Announcements`,unread:`Unread announcements: {{count}}`,empty:`No announcements right now.`,earlier:`Earlier ({{count}})`,new:`New`,readMore:`Read more`,readMoreCount:`Read more (+{{count}})`,gotIt:`Got it`,source:`From the Bambuddy maintainers, fetched from GitHub. You can turn them off in Settings.`,level:{info:`Info`,important:`Important`,critical:`Critical`}},common:{plusNMore:`+{{count}} more`,save:`Save`,saving:`Saving...`,cancel:`Cancel`,delete:`Delete`,edit:`Edit`,add:`Add`,close:`Close`,confirm:`Confirm`,loading:`Loading...`,error:`Error`,errorLoading:`Error loading data`,retry:`Retry`,success:`Success`,warning:`Warning`,enabled:`Enabled`,disabled:`Disabled`,yes:`Yes`,no:`No`,on:`On`,off:`Off`,all:`All`,none:`None`,search:`Search`,filter:`Filter`,sort:`Sort`,refresh:`Refresh`,download:`Download`,upload:`Upload`,uploading:`Uploading...`,uploadFailed:`Upload failed`,actions:`Actions`,status:`Status`,name:`Name`,user:`User`,description:`Description`,date:`Date`,time:`Time`,hours:`hours`,minutes:`minutes`,seconds:`seconds`,days:`days`,enable:`Enable`,disable:`Disable`,permissions:`Permissions`,noPrinters:`No printers configured`,noData:`No data available`,linkNotFound:`Link not found`,required:`Required`,optional:`Optional`,dismiss:`Dismiss`,apply:`Apply`,reset:`Reset`,export:`Export`,import:`Import`,clear:`Clear`,selectAll:`Select All`,deselectAll:`Deselect All`,noChange:`— No change —`,unchanged:`Unchanged`,unassigned:`Unassigned`,unknown:`Unknown`,unknownError:`Unknown error`,today:`Today`,tomorrow:`Tomorrow`,asap:`ASAP`,overdue:`Overdue`,now:`Now`,collapse:`Collapse`,expand:`Expand`,previous:`Previous`,next:`Next`,viewArchive:`View archive`,viewInFileManager:`View in File Manager`,addedBy:`Added by {{username}}`,prints:`prints`,more:`+{{count}} more`,ascending:`Ascending`,descending:`Descending`,back:`Back`,copy:`Copy`,copied:`Copied!`,printer:`Printer`,remove:`Remove`,type:`Type`,print:`Print`,rename:`Rename`,move:`Move`,create:`Create`,duplicate:`Duplicate`,left:`Left`,right:`Right`,run:`Run`,running:`Running...`},finance:{allTypes:`All types`,allCostCenters:`All cost centers`,title:`Finance`,subtitle:`Wallet, personal transactions, and cost centers`,noAccess:`You do not have permission to view finance data.`,personalView:`Personal view`,adminView:`Admin view`,createCostCenter:`Create cost center`,adjustWallet:`Adjust wallet`,addManualPrint:`Add manual print`,manageMembers:`Manage cost center members`,currentBalance:`Personal balance`,transactions:`Transactions`,personalTransactions:`Personal transactions`,costCenters:`Cost centers`,availableForPrinting:`Available for print assignment`,costCenterName:`Name`,budgetType:`Budget type`,monthlyBudget:`Monthly budget`,totalBudget:`Total budget`,noBudget:`No budget`,create:`Create`,selectUser:`Select user`,transactionType:`Type`,amount:`Amount`,noCostCenter:`No cost center`,descriptionOptional:`Description (optional)`,applyAdjustment:`Apply adjustment`,memberCanPrint:`Member can print`,addMember:`Add member`,canPrint:`Can print`,noMembers:`No members assigned.`,editCostCenter:`Edit cost center`,myCostCenters:`My cost centers`,costCentersHint:`Review budget limits and keep costs under control`,noCostCenters:`No cost centers found.`,owner:`Owner`,balance:`Account balance`,unlimited:`Unlimited`,budgetPolicyHint:`Account balances track costs. Printing is limited only by the selected cost center budget; without a budget, printing is unlimited.`,budget:`Budget`,shared:`Shared`,cannotEditPrivateCostCenter:`Private cost centers cannot be edited here`,recentTransactions:`Recent transactions`,transactionsHint:`Filter by type and cost center`,first:`First`,prev:`Previous`,next:`Next`,last:`Last`,pageNumberOf:`Page {{page}} of {{total}}`,noTransactions:`No transactions available.`,noTransactionsForFilter:`No transactions match the selected filters.`,costCenter:`Cost center`,balanceAfter:`Balance after`,userWithId:`User #{{id}}`,partial:`Partial`,editTransaction:`Edit Transaction`,selectCostCenter:`Select cost center...`,costCenterRequired:`Please select a cost center`,amountExample:`e.g., 4.00`,manualAdjustmentExample:`e.g., Manual adjustment`,userRequired:`Please select a user`,amountInvalid:`Amount must be a valid number`,createdCostCenter:`Cost center created`,createCostCenterFailed:`Failed to create cost center`,transactionDeleted:`Transaction deleted`,deleteTransactionFailed:`Failed to delete transaction`,transactionEdited:`Transaction updated and ledger recalculated`,editTransactionFailed:`Failed to edit transaction`,manualPrintCreated:`Manual print charge added and ledger recalculated`,manualPrintFailed:`Failed to create manual print`,memberSaved:`Member saved`,memberSaveFailed:`Failed to save member`,memberRemoved:`Member removed`,memberRemoveFailed:`Failed to remove member`,costCenterNameRequired:`Cost center name is required`,costCenterUpdated:`Cost center updated`,costCenterUpdateFailed:`Failed to update cost center`,confirmDeleteCostCenter:`Delete cost center "{{name}}"?`,costCenterDeleted:`Cost center deleted`,costCenterDeleteFailed:`Failed to delete cost center`,deleteTransactionConfirm:`Delete this transaction? Balances will be recalculated automatically.`,deposit:`Deposit`,withdraw:`Withdraw`,printCharge:`Print charge`,deleteTransaction:`Delete transaction`},printers:{locations:{title:`Printer Locations`,backToPrinters:`Back to Printers`,subtitle:`{{grouped}} in a location, {{ungrouped}} without one`,search:`Search locations...`,showEmpty:`Show empty`,hideEmpty:`Hide empty`,select:`Select`,done:`Done`,sortNameAsc:`Name A→Z`,sortNameDesc:`Name Z→A`,sortCountAsc:`Fewest printers`,sortCountDesc:`Most printers`,create:`New Location`,createTitle:`Create Location`,editTitle:`Edit Location`,namePlaceholder:`Location name`,icon:`Icon`,color:`Color`,noColor:`No color`,none:`No printer locations yet`,noResults:`No locations match your search`,printerCount:`Printers: {{count}}`,noPrinters:`No printers in this location`,selectPrinter:`Select printer`,move:`Move to another location`,moveButton:`Move`,removeFromLocation:`Remove from location`,ungroupedPrinters:`Printers without a location: {{count}}`,selected:`Selected: {{count}}`,deleteSelected:`Delete selected`,moveTitle:`Move printer`,moveTitleMany:`Move printers ({{count}})`,targetPlaceholder:`Select a location...`,noLocation:`No location`,deleteTitle:`Delete location`,deleteTitleMany:`Delete locations ({{count}})`,deleteMessage:`Delete {{names}}? Printers left without a location: {{count}}.`,created:`Location created`,saved:`Location updated`,deleted:`Locations deleted: {{count}}`,moved:`Printers moved: {{count}}`,failed:`Could not save the change: {{error}}`},title:`Printers`,addPrinter:`Add Printer`,addPreflight:{checking:`Checking connection...`,warning:`Some connection checks failed. This printer may show as offline. Review the checks below, fix what you can, or save anyway.`,back:`Back`,saveAnyway:`Save anyway`},editPrinter:`Edit Printer`,deletePrinter:`Delete Printer`,printerName:`Printer Name`,serialNumber:`Serial Number`,ipAddress:`IP Address / Hostname`,accessCode:`Access Code`,model:`Model`,nozzleCount:`Nozzle Count`,autoArchive:`Auto Archive`,status:{available:`Available`,idle:`Idle`,printing:`Printing`,paused:`Paused`,offline:`Offline`,problem:`Problem`,error:`Error`,finished:`Finished`,unknown:`Unknown`},temperatures:{nozzle:`Nozzle`,bed:`Bed`,chamber:`Chamber`},heaterHistory:{title:`Heater History`,openLabel:`View heater history`,nozzle:`Nozzle`,nozzle2:`Nozzle 2`,bed:`Bed`,chamber:`Chamber`,error:`Failed to load history`,empty:`No data recorded yet`},progress:`{{percent}}% complete`,timeRemaining:`{{time}} remaining`,deleteConfirm:`Are you sure you want to delete "{{name}}"?`,maintenanceOk:`Maintenance OK`,maintenanceWarning:`{{count}} warning`,maintenanceWarning_plural:`{{count}} warnings`,maintenanceDue:`{{count}} due`,maintenanceDue_plural:`{{count}} due`,sort:{name:`Name`,status:`Status`,model:`Model`,location:`Location`,eta:`ETA`,ascending:`Sort ascending`,descending:`Sort descending`},cardSize:{small:`Small cards`,medium:`Medium cards`,large:`Large cards`,extraLarge:`Extra large cards`},pageView:{openCamWallPage:`Open cam wall as page`,cards:`Cards`,camWall:`Cam wall`},camWall:{page:{tokenRejected:`This Cam Wall link is no longer valid. The token may have expired or been revoked.`,loadFailed:`Could not load the printers.`},tileSize:{small:`Small tiles`,medium:`Medium tiles`,large:`Large tiles`,extraLarge:`Extra large tiles`},noPrinters:`No printers to show`,noSignal:`No signal`,live:`Live`,snap:`Snap`,off:`Off`,summary:`{{live}} live, {{snap}} snapshots, {{total}} total`,layer:`Layer {{cur}}/{{total}}`,timeLeft:`{{time}} left`,statusMode:{off:`Off`,compact:`Compact`,full:`Full`},settings:{title:`Cam wall settings`,maxLive:`Max live streams`,maxLiveHint:`How many tiles stream live at once. Others refresh as snapshots.`,snapshotInterval:`Snapshot interval (seconds)`,snapshotIntervalHint:`How often non-live tiles fetch a fresh snapshot.`,statusOverlay:`Status overlay`,statusOverlayHint:`Compact: state badge only. Full: + progress, layer, time left.`}},hideOffline:`Hide offline`,nextAvailable:`Next available`,powerOn:`Power On`,offlinePrintersWithPlugs:`Offline printers with smart plugs`,noPrintersConfigured:`No printers configured yet`,search:`Search printers...`,noSearchResults:`No printers match your search or filters`,filter:{allStatuses:`All statuses`,allLocations:`All locations`},toolbar:{filters:`Filters`,view:`View`,actions:`Actions`},readyToPrint:`Ready to print`,external:`External`,ext:`Ext`,extL:`Ext-L`,extR:`Ext-R`,deleteArchives:`Delete print archives`,noLabel:`No label`,printPreview:`Print preview`,width:`Width`,height:`Height`,noObjectsFound:`No objects found`,objectsLoadedOnPrintStart:`Objects are loaded when a print starts`,willBeSkipped:`Will be skipped`,name:`Name`,serialCannotBeChanged:`Serial number cannot be changed`,locationHelp:`Used to group printers and filter queue jobs`,wifiSignal:{veryWeak:`Very weak`,weak:`Weak`,fair:`Fair`,good:`Good`,excellent:`Excellent`},maintenanceUpToDate:`All maintenance up to date - Click to view`,maintenance:{title:`In Maintenance`,subtitle:`This printer is paused — not connected, not eligible for the queue, not sending notifications.`,pillLabel:`Maintenance`,exitButton:`Exit maintenance`,menuEnter:`Enter maintenance mode`,menuExit:`Exit maintenance mode`,toastEntered:`{{name}} is now in maintenance mode`,toastExited:`{{name}} is back online`,confirmMidPrintTitle:`Enter maintenance mode mid-print?`,confirmMidPrintMessage:`{{name}} is currently printing. Entering maintenance mode will disconnect MQTT and stop progress tracking and completion notifications for this job. Continue?`,editFieldLabel:`Maintenance mode`,editFieldHelp:`When on, this printer is paused from MQTT, queue dispatch and notifications — useful for repair, parallel Bambuddy installs, or temporary suspension.`},chamberLightOn:`Turn on chamber light`,chamberLightOff:`Turn off chamber light`,files:`Files`,browseFiles:`Browse printer files`,autoOffAfterPrint:`Auto power-off after print`,autoOffExecuted:`Auto-off was executed - turn printer on to reset`,hmsErrors:`HMS Errors`,viewHmsErrors:`View {{count}} HMS error(s)`,resume:`Resume`,pause:`Pause`,stop:`Stop`,camera:`Camera`,skipObject:`Skip Object`,reconnect:`Reconnect`,forceRefresh:`Force Refresh`,forceRefreshSuccess:`Refresh requested`,mqttDebug:`MQTT Debug`,printerInformation:`Printer Information`,copyToClipboard:`Copy`,copied:`Copied!`,state:`State`,wifiSignalLabel:`WiFi Signal`,developerMode:`Developer Mode`,enabled:`Enabled`,disabled:`Disabled`,addedOn:`Added`,sdCard:`SD Card`,inserted:`Inserted`,notInserted:`Not inserted`,totalPrintHours:`Print Hours`,activeNozzle:`Active: {{nozzle}} nozzle`,amsSwitchInletTooltip:`Filament Track Switch IN-{{inlet}} ({{side}}) — feeds both nozzles`,nozzleRack:`Nozzle Rack`,nozzleDocked:`Docked`,nozzleMounted:`Mounted`,nozzleActive:`Active`,nozzleIdle:`Idle`,nozzleDiameter:`Diameter`,nozzleType:`Type`,nozzleStatus:`Status`,nozzleFilament:`Filament`,nozzleWear:`Wear`,nozzleMaxTemp:`Max Temp`,nozzleSerial:`Serial`,nozzleHardenedSteel:`Hardened Steel`,nozzleStainlessSteel:`Stainless Steel`,nozzleTungstenCarbide:`Tungsten Carbide`,nozzleFlow:`Flow`,nozzleHighFlow:`High Flow`,nozzleStandardFlow:`Standard`,firmwareUpdate:`Firmware Update`,firmwareInstructions:`On the printer's touchscreen, go to`,firmwareNav:`Navigate to`,settings:`Settings`,firmware:`Firmware`,discoverPrinters:`Discover Printers`,searching:`Searching...`,manualEntry:`Manual Entry`,addFromCloud:`Add from Cloud`,toast:{printerDeleted:`Printer deleted`,missingSpoolAssignment:`Print started on {{printer}}. Missing spool assignment for: {{slots}}`,killSwitchTriggered:`The billing kill switch stopped an unauthorized print on {{printer}}: {{filename}}`,billingChargeFailed:`Billing failed for {{filename}} on {{printer}}. The budget reservation was retained; check the server logs.`,assignmentVerified:`Filament loaded on slot {{slot}} ({{printer}})`,assignmentVerifiedNoKprofile:`Slot {{slot}} on {{printer}} loaded, but the flow calibration (K-profile) was not applied`,assignmentNotConfirmed:`Could not confirm the assignment for slot {{slot}} on {{printer}} — check the AMS slot`,printerAdded:`Printer added`,printerUpdated:`Printer updated`,failedToDelete:`Failed to delete printer`,failedToAdd:`Failed to add printer`,connectionFailedNotAdded:`Could not connect to the printer. Verify the IP, serial number, and access code, and confirm LAN-only mode is on. The printer was not added.`,failedToUpdate:`Failed to update printer`,commandSent:`Command sent`,failedToSendCommand:`Failed to send command`,turnedOn:`{{name}} turned on`,failedToPowerOn:`Failed to power on {{name}}`,scriptTriggered:`Script triggered`,printStopped:`Print stopped`,printPaused:`Print paused`,printResumed:`Print resumed`,referenceDeleted:`Reference deleted`,detectionAreaSaved:`Detection area saved`,failedToRunScript:`Failed to run script`,failedToStopPrint:`Failed to stop print`,failedToPausePrint:`Failed to pause print`,failedToResumePrint:`Failed to resume print`,failedToControlChamberLight:`Failed to control chamber light`,failedToSetSpeed:`Failed to set print speed`,failedToUpdateSetting:`Failed to update setting`,failedToSkipObjects:`Failed to skip objects`,failedToRereadRfid:`Failed to re-read RFID`,failedToCheckPlate:`Failed to check plate`,failedToUpdateLabel:`Failed to update label`,failedToDeleteReference:`Failed to delete reference`,failedToSaveDetectionArea:`Failed to save detection area`,plateCheckEnabled:`Plate check enabled`,plateCheckDisabled:`Plate check disabled`,calibrationSaved:`Calibration saved!`,calibrationFailed:`Calibration failed`,rfidRereadInitiated:`RFID re-read initiated`,loadInitiated:`Loading filament…`,unloadInitiated:`Unloading filament…`,failedToLoad:`Failed to load filament`,failedToUnload:`Failed to unload filament`},connection:{connected:`Connected`,offline:`Offline`},plateStatus:{markCleared:`Mark plate as cleared`,cleared:`Plate Clear`,notCleared:`Plate not Clear`,inUse:`Plate in Use`},queue:{inQueue:`{{count}} print in queue`,inQueue_plural:`{{count}} prints in queue`},controls:`Controls`,rfid:{reread:`Re-read RFID`},ams:{load:`Load`,unload:`Unload`,feedTitle:`Load {{slot}} to which nozzle?`,feedPrompt:`The Filament Track Switch can route this slot to either hotend. Choose which one to feed.`,feedLeft:`Left nozzle`,feedRight:`Right nozzle`,feedAlreadyLoaded:`Already loaded`,switchNotReady:`The Filament Track Switch is not set up yet. Assign every AMS to an inlet on the printer, then try again.`},bedJog:{limitWarning:`Travel limits are not enforced during manual moves — a Bambu firmware bug ignores software endstops for remote commands. Move carefully to avoid a collision.`,title:`Jog Controls`,bed:`Bed`,step:`Step (mm)`,up:`Move plate up`,down:`Move plate down`,toolheadUp:`Move toolhead up`,toolheadDown:`Move toolhead down`,disabledWhilePrinting:`Disabled while printing`,notHomedTitle:`Printer is not homed`,notHomedMessage:`The printer has not been homed since the last print. Run auto-home first for safe positioning (parks the toolhead, then homes X, Y, and Z), or move anyway — soft endstops will be bypassed.`,homeZ:`Auto Home`,moveAnyway:`Move anyway`,homingStarted:`Auto-homing printer…`},permission:{noAdd:`You do not have permission to add printers`,noEdit:`You do not have permission to edit printers`,noDelete:`You do not have permission to delete printers`,noControl:`You do not have permission to control printers`,noFiles:`You do not have permission to access printer files`,noAmsRfid:`You do not have permission to re-read AMS RFID`,noSmartPlugControl:`You do not have permission to control smart plugs`,noCamera:`You do not have permission to view cameras`},modal:{addTitle:`Add Printer`,editTitle:`Edit Printer`,myPrinter:`My Printer`,selectModel:`Select model...`,locationGroup:`Location / Group (optional)`,locationPlaceholder:`e.g., Workshop, Office, Basement`,autoArchiveLabel:`Auto-archive completed prints`,wearCostLabel:`Wear cost per printing hour ({{currency}})`,wearCostHelp:`What an hour of printing costs this printer in wear and parts. It is added to the cost of every print from now on; earlier prints are not changed. Leave empty to turn it off.`,fromPrinterSettings:`From printer settings`,modelOptional:`Model (optional)`,saveChanges:`Save Changes`},skipObjects:{tooltip:`Skip objects`,onlyWhilePrinting:`Skip objects (only while printing)`,requiresMultiple:`Skip objects (requires 2+ objects)`,title:`Skip Objects`,matchIdsInfo:`Match IDs with your printer display`,printerShowsIds:`The printer screen shows object IDs on the build plate`,skipSelected:`Skip Selected`,skipping:`Skipping...`,noObjectsSelected:`No objects selected`,selectObjectsToSkip:`Select objects you want to skip from the current print`,skipped:`skipped`,objectsSkipped:`Objects skipped`,activeCount:`{{count}} active`,waitForLayer:`Wait for layer 2+ to skip objects (currently layer {{layer}})`,skip:`Skip`,confirmTitle:`Skip Object?`,confirmMessage:`Are you sure you want to skip "{{name}}"? This cannot be undone.`,confirmAllMessage:`All remaining objects are selected. This will stop the print job. Continue?`,confirmMultipleMessage:`Skip {{count}} selected objects? This cannot be undone.`},confirm:{deleteTitle:`Delete Printer`,deleteMessage:`Are you sure you want to delete "{{name}}"? This will remove all connection settings.`,deleteArchivesNote:`All print history for this printer will be permanently deleted.`,keepArchivesNote:`Print history will be kept but no longer associated with this printer.`,stopTitle:`Stop Print`,stopMessage:`Are you sure you want to stop the current print on "{{name}}"? This will cancel the print job.`,stopButton:`Stop Print`,pauseTitle:`Pause Print`,pauseMessage:`Are you sure you want to pause the current print on "{{name}}"?`,pauseButton:`Pause Print`,resumeTitle:`Resume Print`,resumeMessage:`Are you sure you want to resume the print on "{{name}}"?`,resumeButton:`Resume Print`,powerOnTitle:`Power On Printer`,powerOnMessage:`Are you sure you want to turn ON the power for "{{name}}"?`,powerOnButton:`Power On`,powerOffTitle:`Power Off Printer`,powerOffMessage:`Are you sure you want to turn OFF the power for "{{name}}"?`,powerOffWarning:`WARNING: "{{name}}" is currently printing! Are you sure you want to turn OFF the power? This will interrupt the print and may damage the printer.`,powerOffButton:`Power Off`,haToggleTitle:`Toggle "{{name}}"`,haToggleMessage:`Toggle the Home Assistant entity {{entity}}? This may turn power off if it is currently on.`,haToggleWarning:`WARNING: "{{name}}" is currently printing! Toggling {{entity}} may cut power and interrupt the print. Continue?`,haToggleButton:`Toggle`},bulk:{select:`Select`,selectAll:`Select All`,selectByLocation:`Select by Location`,selected:`{{count}} selected`,actions:{stop:`Stop`,pause:`Pause`,resume:`Resume`,clearPlate:`Clear Bed`,clearHMS:`Clear Notifications`},confirm:{stopTitle:`Stop {{count}} Prints`,stopMessage:`This will cancel active prints on {{count}} printer(s). This action cannot be undone.`,stopButton:`Stop All`,pauseTitle:`Pause {{count}} Prints`,pauseMessage:`This will pause active prints on {{count}} printer(s).`,pauseButton:`Pause All`,clearPlateTitle:`Clear {{count}} Print Beds`,clearPlateMessage:`This will clear the print bed on {{count}} printer(s) and may trigger queued jobs.`,clearPlateButton:`Clear All`},success:`{{action}} completed on {{count}} printer(s)`,partial:`{{succeeded}} succeeded, {{failed}} failed`,noneApplicable:`No selected printers are in the right state for this action`,selectByState:`Select by State`},discovery:{title:`Discover Printers`,searching:`Searching...`,scanning:`Scanning...`,scanProgress:`Scanning... {{scanned}}/{{total}}`,foundPrinters:`Found {{count}} printer(s)`,noPrintersFound:`No printers found`,noPrintersFoundSubnet:`No printers found in the specified subnet.`,noPrintersFoundNetwork:`No printers found on the network.`,allConfigured:`All discovered printers are already configured.`,alreadyAdded:`Already added`,select:`Select`,manualEntry:`Manual Entry`,addFromCloud:`Add from Cloud`,subnetToScan:`Subnet to scan`,dockerNote:`Docker detected. Enter your printer's subnet in CIDR notation. Requires network_mode: host in docker-compose.yml.`,scanSubnet:`Scan Subnet for Printers`,discoverNetwork:`Discover Printers on Network`,scanningSubnet:`Scanning subnet for Bambu printers...`,scanningNetwork:`Scanning network...`,serialRequired:`Serial required`,unknown:`Unknown`,failedToStart:`Failed to start discovery`,customSubnetOption:`Custom subnet...`,customSubnetLabel:`Custom subnet (CIDR)`,customSubnetNote:`Use a custom subnet if your printer is on a different network than this server. The FTP (990) and MQTT (8883) ports must be reachable across the routing boundary.`},drying:{start:`Start Drying`,stop:`Stop Drying`,temperature:`Temperature`,duration:`Duration`,hours:`hours`,timeRemaining:`{{time}} left`,active:`Drying`,notRunning:`Drying not running`,notRunningHint:`The printer holds a drying timer, but the countdown has stopped and the AMS reports no drying phase. The cycle never started or was paused, for example by the power limit or the current print.`,targetSummary:`{{filament}} @ {{temp}}°C`,notSupported:`Drying not supported`,powerRequired:`Connect AMS power adapter to enable drying`,cannotDryNow:`AMS can't start drying right now`,startingDrying:`Starting drying...`,toastCommandSent:`Drying command sent`,toastStopped:`Drying stopped`,toastNotStarted:`The printer accepted the command but the AMS never started drying. Check that the AMS power adapter is connected and that the printer is idle.`,screenOnly:`AMS drying on this printer can only be controlled from the printer's own screen (Bambu limitation)`,stoppingDrying:`Stopping drying...`,rotateTray:`Rotate spool during drying`,rotateUnavailableReason:`Unavailable — a slot in this AMS is loaded to the toolhead. The spool is locked by the feed tube and cannot rotate. Retract the filament first.`,startMode:`Start time`,modeNow:`Now`,modeDelay:`After delay`,modeAtTime:`At time`,schedule:`Schedule`,scheduledFor:`Drying scheduled for {{time}}`,scheduledAsap:`Drying scheduled (waiting for printer)`,cancelScheduled:`Cancel scheduled drying`,scheduleFailed:`Failed to schedule drying`,retractFilament:`Retract the filament at the AMS outlet to start drying`,waitingAmsNotFound:`Waiting for the AMS to be detected`,waitingOffline:`Waiting for the printer to come online`,waitingPrinterBusy:`Waiting for the printer to be free`,waitingAlreadyDrying:`Waiting for the current drying cycle to finish`,waitingInterrupted:`Interrupted, will restart when the printer is free`,scheduleFailedReason:`Scheduled drying failed: {{reason}}`,scheduleFailedUnknown:`Unknown error`,scheduleFailedDidNotStart:`The printer accepted the command, but the AMS did not start drying`,dismissFailed:`Dismiss`},amsBackup:{titleOn:`AMS Filament Backup is ON. Click to disable.`,titleOff:`AMS Filament Backup is OFF. Click to enable.`,titleUnknown:`AMS Filament Backup status unavailable on this printer.`,toastEnabled:`AMS Filament Backup enabled`,toastDisabled:`AMS Filament Backup disabled`,modalTitle:`AMS Filament Backup`,modalHelp:`When the active slot runs out, the printer cycles through any matching same-preset, same-colour slots in this order.`,modalNoSlots:`No filament loaded.`,modalNoPairs:`No backup pairs — no two slots share the same filament profile and colour.`,extruderRightShort:`R`,extruderLeftShort:`L`,stateOn:`Enabled`,stateOff:`Disabled`,stateUnknown:`Unsupported on this printer`},activeJobSlot:{title:`This slot is filament {{n}} in the active print`,ariaLabel:`Active print slot {{n}}`},expectedSlot:{title:`The printer is waiting for filament in this slot`,ariaLabel:`Expected filament slot {{n}}`,label:`{{ams}} · Slot {{slot}}`,external:`External spool`},filaments:`Filaments`,externalSpool:{hide:`Hide external spool`,show:`Show external spool`},openCameraOverlay:`Open camera overlay`,openCameraWindow:`Open camera in new window`,firmwareUpdateAvailable:`Firmware update available: {{current}} → {{latest}}`,firmwareUpToDate:`Firmware {{version}} — Up to date`,firmwareUpdateButton:`Update`,plateDetection:{noPermission:`You do not have permission to update printers`,enabledClick:`Plate check enabled - Click to disable`,disabledClick:`Plate check disabled - Click to enable`,manageCalibration:`Manage plate detection calibration`,calibrationRequired:`Calibration Required`,calibrationInstructions:`Please ensure the build plate is <strong>completely empty</strong>, then click Calibrate.`,calibrationDescription:`Calibration captures a reference image of the empty plate. Future checks will compare against this reference to detect objects.`,calibrationTip:`<strong>Tip:</strong> You can store up to 5 calibrations for different plates. The system automatically uses the best match when checking.`,plateEmpty:`Plate appears empty`,objectsDetected:`Objects detected on plate`,confidence:`Confidence`,difference:`Difference`,analysisPreview:`Analysis preview:`,analysisLegend:`Green box = detection area, Red overlay = differences from calibration`,savedReferences:`Saved References ({{count}}/{{max}})`,deleteReference:`Delete reference`,labelPlaceholder:`Label...`,clickToEdit:`{{label}} - Click to edit`,clickToAddLabel:`Click to add label`},speed:{title:`Print Speed`,silent:`Silent (50%)`,standard:`Standard (100%)`,sport:`Sport (124%)`,ludicrous:`Ludicrous (166%)`},airduct:{title:`Airduct Mode`,cooling:`Cooling`,heating:`Heating`},noSdCard:`No SD`,door:{open:`Open`,closed:`Closed`},fans:{partCooling:`Part Cooling Fan`,auxiliary:`Auxiliary Fan`,leftAuxiliary:`Left Auxiliary Fan`,exhaust:`Exhaust`,chamber:`Chamber Fan`},clickToViewHmsErrors:`Click to view HMS errors`,aiDetection:{safe:`Safe`,warning:`Warning`,failure:`Failure`,idle:`Idle`,error:`Not checking`,unknown:`Starting`,tooltipError:`AI Failure Detection is not checking this print: {{reason}} - click for details`,tooltipUnknown:`AI Failure Detection: waiting for the first result - click for details`,errorHint:`This print is not being checked. Detection resumes automatically once the problem below is fixed.`,tooltip:`AI Failure Detection: {{status}} (score {{score}}) - click for details`,tooltipIdle:`AI Failure Detection enabled - monitoring starts with the next print - click for details`,modalTitle:`AI Failure Detection - {{name}}`,currentStatus:`Status`,score:`Score`,framesAnalyzed:`Frames analyzed`,idleHint:`No print is being monitored right now. Monitoring starts automatically with the next print.`,lastError:`Last error`,openSettings:`Open settings`},estimatedCompletion:`Estimated completion time`,plateNumber:`Plate {{number}}`,slotOptions:`Slot options`,amsPopup:{friendlyName:`AMS Name`,friendlyNamePlaceholder:`e.g. AMS Friendly Name`,serialNumber:`Serial Number`,firmwareVersion:`Firmware`,save:`Save`,clear:`Clear`,noEditPermission:`You do not have permission to rename AMS units`},firmwareModal:{title:`Firmware Update`,titleUpToDate:`Firmware Info`,currentVersion:`Current:`,latestVersion:`Latest:`,releaseNotes:`Release Notes`,checkingPrereqs:`Checking prerequisites...`,sdCardReady:`SD card ready. Click below to upload firmware.`,uploadedSuccess:`Firmware uploaded to SD card!`,applyInstructions:`To apply the update on your printer:`,step1:`On the printer's touchscreen, go to <strong>Settings</strong>`,step2:`Navigate to <strong>Firmware</strong>`,step3:`Select <strong>Update from SD card</strong>`,step4:`The update will take 10-20 minutes`,done:`Done`,starting:`Starting...`,uploadFirmware:`Upload Firmware`,uploadFailed:`Failed to start upload: {{error}}`,uploadedToast:`Firmware uploaded! Trigger update from printer screen.`,availableVersions:`Available versions`,usable:`Usable`,unavailable:`Unavailable`,installed:`Installed`,newerBadge:`newer`,olderBadge:`older`,currentBadge:`current`},accessCodePlaceholder:`Leave empty to keep current`,roi:{title:`Detection Area (ROI)`,xStart:`X Start`,yStart:`Y Start`,width:`Width`,height:`Height`,instruction:`Adjust the detection area to focus on the build plate. The green box in the preview shows the current area.`},developerModeWarning:`Developer LAN mode is not enabled on: {{names}}. Some features may not work.`,howToEnable:`How to enable`,incompatibleFile:`This file was sliced for {{slicedFor}}, but this printer is a {{printerModel}}`,dropNotPrintable:`Only .gcode and .gcode.3mf files can be printed`,dropToPrint:`Drop to print`,dropToQueue:`Drop to queue`},archives:{media:{title:`Print videos`,download:`Download print videos`,searching:`Checking the printer for videos…`,searchFailed:`Could not check the printer for videos.`,none:`No timelapse or IP camera chunks were found for this print.`,attachedTimelapse:`Attached timelapse`,printerFiles:`Files still on the printer`,downloadSelected:`Download selected`,printerMissing:`Printer is no longer configured`,timelapseUnavailable:`The timelapse directory could not be read`,ipcamUnavailable:`The IP camera directory could not be read`},title:`Print Archives`,no3mfBanner:{title:`Some recent prints couldn't be archived with thumbnails`,body:`The slicer didn't leave the .gcode.3mf on the printer's SD card, so Bambuddy couldn't pull the thumbnail or slicer metadata. This is usually because "Store sent files on external storage" is off in the slicer (Bambu Studio / OrcaSlicer Device tab).`,docsLink:`See install step 4`,dismissLabel:`Dismiss this notice`,docsLinkInternalStorage:`Why this happens`,titleInternalStorage:`Some recent prints stayed on the printer's internal storage`,bodyInternalStorage:`Bambu Studio put the sliced file on the printer's internal storage instead of the card, so there was nothing for Bambuddy to read over FTP. On H2-series, P2S and X2D its Print button always does that — only Send offers a choice, and that defaults to Cache too. Those prints are still archived with their name and timing, just without a thumbnail or slicer metadata. For complete archives, start the print from Bambuddy, or slice in OrcaSlicer — or in Bambu Studio use Send with External selected and start the print afterwards. All of them need a card or stick in the printer.`,titleNoExternalStorage:`Some recent prints couldn't be archived — no storage in the printer`,bodyNoExternalStorage:`The printer reports no card or stick in its slot, so the sliced file had nowhere to land and Bambuddy had nothing to read. Insert one and the next print will archive in full.`,titleInternalHistory:`Some recent prints were started from a file already on the printer`,bodyInternalHistory:`Those prints ran from the printer's own library — a re-print from its screen, a start from Handy, or a file sent earlier and printed later. Bambuddy reads print files over FTP, which serves only the card or stick, while the printer keeps that library in an area FTP cannot reach, so there was no 3MF to read. No slicer setting changes this, because nothing was sent for these prints. They are still archived with their name and timing, and Edit Archive lets you fill in the filament used by hand. For a complete archive, start the print from Bambuddy or from your slicer instead.`,titleFtpsCooloff:`Some recent prints couldn't be archived — the printer refused the file connection`,bodyFtpsCooloff:`Bambuddy opened the printer's file-transfer port (FTPS 990) and the printer answered with something that is not TLS, so nothing could be read from it. Those prints are still archived with their name and timing, just without a thumbnail or slicer metadata. This is not a slicer setting and not something you changed — the same models and firmware run normally on other installs, and an affected printer usually works again later on its own. After such a failure Bambuddy pauses transfers to that printer for five minutes and comes back for the file once the pause clears, so a short episode fills itself in; a card still empty means the refusal outlasted the retry. What triggers it is not yet known. If it keeps happening, turn on debug logging on the System page and attach a support bundle to your report.`,titleFtpTransferFailed:`Some recent prints couldn't be archived — the file transfer ran out of time`,bodyFtpTransferFailed:`The sliced file was on the printer's card and the printer served it, but the transfer did not finish in the time allowed. At print start the printer is also handling its camera, its status messages and the job upload, and a large 3MF does not always get through against all that. Those prints are still archived with their name and timing, just without a thumbnail or slicer metadata. This is not a slicer setting and not something you changed. Bambuddy comes back for the file three times over the following ten minutes, so most of these fill themselves in; a card still empty means every attempt ran out of time too. If it keeps happening, raise Connection Timeout under Settings > Network > FTP Retry.`},searchPlaceholder:`Search archives...`,filterByPrinter:`Filter by printer`,filterByStatus:`Filter by status`,sortBy:`Sort by`,sortNewest:`Newest first`,sortOldest:`Oldest first`,sortName:`Name`,sortDuration:`Duration`,sortLargest:`Largest first`,sortSmallest:`Smallest first`,sortSize:`Size`,noArchives:`No archives found`,noArchivesSearch:`No archives match your search`,originalPrintNotVisible:`Original print not visible - try clearing filters`,noArchivesYet:`No archives yet`,prints:`prints`,pagination:{showing:`Showing`,to:`to`,of:`of`,show:`Show`,page:`Page`,all:`All`},loadingArchives:`Loading archives...`,releaseToUpload:`Release to upload`,showAll:`Show all`,showFavoritesOnly:`Show favorites only`,gridView:`Grid view`,listView:`List view`,calendarView:`Calendar view`,logView:`Print Log`,manageTags:`Manage Tags`,showFailedPrints:`Show failed prints`,hideFailedPrints:`Hide failed prints`,hideDuplicates:`Hide Duplicates`,filterUnconfirmed:`Unconfirmed`,filterUnconfirmedTitle:`Show only prints still waiting for their outcome verdict`,viewOriginalPrint:`Click to view original print (#{{id}})`,printTime:`Print Time`,filamentUsed:`Filament Used`,cost:`Cost`,preview:`Preview`,deleteArchive:`Delete Archive`,deleteConfirm:`Are you sure you want to delete this archive?`,favorite:`Favorite`,unfavorite:`Remove from favorites`,viewDetails:`View Details`,status:{completed:`Completed`,failed:`Failed`,stopped:`Stopped`},toast:{source3mfAttached:`Source 3MF attached: {{filename}}`,failedUploadSource3mf:`Failed to upload source 3MF`,source3mfRemoved:`Source 3MF removed`,failedRemoveSource3mf:`Failed to remove source 3MF`,f3dAttached:`F3D attached: {{filename}}`,failedUploadF3d:`Failed to upload F3D`,f3dRemoved:`F3D removed`,failedRemoveF3d:`Failed to remove F3D`,timelapseAttached:`Timelapse attached: {{filename}}`,timelapseAlreadyAttached:`Timelapse already attached`,noMatchingTimelapse:`No matching timelapse found`,failedScanTimelapse:`Failed to scan for timelapse`,failedAttachTimelapse:`Failed to attach timelapse`,timelapseRemoved:`Timelapse removed`,failedRemoveTimelapse:`Failed to remove timelapse`,timelapseUploaded:`Timelapse uploaded: {{filename}}`,failedUploadTimelapse:`Failed to upload timelapse`,archiveDeleted:`Archive deleted`,failedDeleteArchive:`Failed to delete archive`,addedToFavorites:`Added to favorites`,removedFromFavorites:`Removed from favorites`,projectUpdated:`Project updated`,failedUpdateProject:`Failed to update project`,linkCopied:`Link copied to clipboard`,failedCopyLink:`Failed to copy link`,photoDeleted:`Photo deleted`,failedDeletePhoto:`Failed to delete photo`,failedDeleteArchives:`Failed to delete archives`,failedUpdateFavorites:`Failed to update favorites`,exportDownloaded:`Export downloaded`,exportFailed:`Export failed`},menu:{print:`Print`,openInBambuStudio:`Open in Slicer`,slice:`Slice`,externalLink:`External Link`,viewOnMakerWorld:`View on MakerWorld`,confirmOutcome:`Confirm Outcome`,preview3d:`3D Preview`,viewTimelapse:`View Timelapse`,scanForTimelapse:`Scan for Timelapse`,uploadTimelapse:`Upload Timelapse`,removeTimelapse:`Remove Timelapse`,downloadSource3mf:`Download Source 3MF`,uploadSource3mf:`Upload Source 3MF`,replaceSource3mf:`Replace Source 3MF`,removeSource3mf:`Remove Source 3MF`,uploadF3d:`Upload F3D`,replaceF3d:`Replace F3D`,downloadF3d:`Download F3D`,removeF3d:`Remove F3D`,download:`Download`,copyDownloadLink:`Copy Download Link`,qrCode:`QR Code`,viewPhotos:`View Photos`,viewPhotosCount:`View Photos ({{count}})`,projectPage:`Project Page`,addToFavorites:`Add to Favorites`,removeFromFavorites:`Remove from Favorites`,edit:`Edit`,printLog:`Print Log`,goToProject:`Go to Project: {{name}}`,addToProject:`Add to Project`,removeFromProject:`Remove from Project`,loading:`Loading...`,noProjectsAvailable:`No projects available`,searchProjects:`Search projects…`,select:`Select`,deselect:`Deselect`,delete:`Delete`},permission:{noReprint:`You do not have permission to reprint this archive`,noAddToQueue:`You do not have permission to add to queue`,noUpdateArchives:`You do not have permission to update archives`,noUploadFiles:`You do not have permission to upload files`,noDownload:`You do not have permission to download archives`,noCopyLink:`You do not have permission to copy download links`,noDelete:`You do not have permission to delete this archive`,noEdit:`You do not have permission to edit this entry`,noCreate:`You do not have permission to create archives`},platePicker:{title:`Select plate to preview`,hint:`This archive has multiple plates. Pick one to open in the GCode viewer.`,plateLabel:`Plate {{index}}`,objectCount:`{{count}} object`,objectCount_plural:`{{count}} objects`,noGcode:`This archive has no sliced G-code to preview. Open it in Bambu Studio to slice first.`},card:{previousPlate:`Previous plate`,nextPlate:`Next plate`,plateNumber:`Plate {{index}}`,moreOptions:`Right-click for more options`,addToFavorites:`Add to favorites`,removeFromFavorites:`Remove from favorites`,cancelled:`cancelled`,failed:`failed`,confirmPending:`outcome?`,confirmPendingTitle:`This print asked for an outcome verdict — click to answer`,rejected:`rejected`,rejectedTitle:`Completed on the printer, marked as reject by the user`,confirmedGood:`good`,confirmedGoodTitle:`Confirmed as a good part by the user`,duplicate:`duplicate`,duplicateTitle:`This model has been printed before`,openSource3mf:`Open source 3MF in Bambu Studio (right-click for more options)`,downloadF3d:`Download Fusion 360 design file`,viewTimelapse:`View timelapse`,viewPhoto:`View 1 photo`,viewPhotos:`View {{count}} photos`,openFolder:`Open folder: {{name}}`,slicedFile:`Sliced file - ready to print`,sourceFile:`Source file only - no AMS mapping available`,gcode:`GCODE`,source:`SOURCE`,project:`Project: {{name}}`,runsBadge:`{{count}} prints`,runsBadgeTitle:`{{count}} prints total — {{successful}} successful, {{failed}} failed. Click to see the full print log.`,estimated:`Estimated: {{time}}`,actual:`Actual: {{time}}`,accuracy:`Accuracy: {{percent}}%`,filament:`{{weight}}g`,layer:`{{count}} layer`,layers:`{{count}} layers`,wearCost:`Printer wear`,object:`{{count}} object`,objects:`{{count}} objects`,slicedFor:`Sliced for {{model}}`,uploadedBy:`Uploaded By`,noPermissionReprint:`You do not have permission to reprint`,noFileForReprint:`No 3MF file available — the file could not be downloaded from the printer when the print was recorded`,slicerAmsMapping:`AMS mapping saved ({{printer}})`,slicerAmsMappingTooltip:`The slicer's own AMS slot choice was saved for {{printer}}. Tray numbers only mean something on that printer, so a reprint reuses them only when it targets {{printer}} again.`,noPermissionEdit:`You do not have permission to edit archives`,noPermissionDelete:`You do not have permission to delete archives`,openInBambuStudio:`Open in Slicer`,openInBambuStudioToSlice:`Open in Slicer to slice`,slice:`Slice`,externalLink:`External Link`,makerWorld:`MakerWorld: {{designer}}`,viewProject:`View project`,noExternalLink:`No external link`,preview3d:`3D Preview`,download:`Download`,edit:`Edit`,delete:`Delete`},runLog:{title:`Print Log`,modalTitle:`Print Log — {{name}}`,modalTitleFallback:`this archive`,empty:`No print events recorded for this archive yet.`,col:{date:`Date`,status:`Status`,duration:`Duration`,filament:`Filament`,cost:`Cost`},status:{completed:`Completed`,failed:`Failed`,cancelled:`Cancelled`,stopped:`Stopped`,skipped:`Skipped`,printing:`Printing`}},modal:{deleteArchive:`Delete Archive`,deleteConfirm:`Are you sure you want to delete "{{name}}"? This action cannot be undone.`,deleteButton:`Delete`,deletePurgeStats:`Also remove this print from Quick Stats (filament, time, cost, energy)`,deleteQueueItemsWarning:`{{count}} queue item(s) linked to this archive will also be removed.`,deleteBlockedByPrinting:`Cannot delete — {{count}} queue item(s) are currently printing. Stop the print first, then retry.`,removeSource3mf:`Remove Source 3MF`,removeSource3mfConfirm:`Are you sure you want to remove the source 3MF file from "{{name}}"? This will delete the original slicer project file.`,removeButton:`Remove`,removeF3d:`Remove F3D`,removeF3dConfirm:`Are you sure you want to remove the Fusion 360 design file from "{{name}}"?`,removeTimelapse:`Remove Timelapse`,removeTimelapseConfirm:`Are you sure you want to remove the timelapse video from "{{name}}"?`,timelapse:`{{name}} - Timelapse`,selectTimelapse:`Select Timelapse`,selectTimelapseDesc:`No auto-match found. Select the timelapse for this print:`,deleteArchives:`Delete Archives`,deleteArchivesConfirm:`Are you sure you want to delete {{count}} archive(s)? This action cannot be undone.`,deleteCount:`Delete {{count}}`},page:{title:`Archives`,printsCount:`{{filtered}} of {{total}} prints`,dropFilesHere:`Drop .3mf files here`,releaseToUpload:`Release to upload`,only3mfSupported:`Only .3mf files are supported`,close:`Close`,selected:`{{count}} selected`,selectAll:`Select All`,tags:`Tags`,project:`Project`,favorite:`Favorite`,delete:`Delete`,toggledFavorites:`Toggled favorites for {{count}} archive(s)`,failedUpdateFavorites:`Failed to update favorites`,archivesDeleted:`{{count}} archive(s) deleted`,failedDeleteArchives:`Failed to delete archives`,photoDeleted:`Photo deleted`,failedDeletePhoto:`Failed to delete photo`},list:{name:`Name`,printer:`Printer`,date:`Date`,size:`Size`,actions:`Actions`,hasTimelapse:`Has timelapse`},log:{date:`Date`,printName:`Print Name`,printer:`Printer`,user:`User`,status:`Status`,duration:`Duration`,filament:`Filament`,filamentUsed:`Filament Used`,cost:`Cost`,energy:`Energy`,energyCost:`Energy Cost`,wearCost:`Wear Cost`,completedAt:`Finished`,columns:`Columns`,sortBy:`Sort by {{column}}`,allPrinters:`All Printers`,allUsers:`All Users`,allStatuses:`All Statuses`,cancelled:`Cancelled`,skipped:`Skipped`,dateFrom:`From`,dateTo:`To`,noEntries:`No print log entries found`,showing:`Showing {{count}} of {{total}} entries`,rowsPerPage:`Rows`,page:`Page`,prev:`Prev`,next:`Next`,clearLog:`Clear Log`,clearLogTitle:`Clear Print Log`,clearLogConfirm:`All print log entries will be permanently deleted. Archives and queue items are not affected. This action cannot be undone. Are you sure?`,clearLogButton:`Clear All`,cleared:`{{count}} log entries cleared`,clearFailed:`Failed to clear print log`,deleteEntryTitle:`Delete print log entry`,deleteEntryConfirm:`This entry will be removed from the log and its filament, time, and cost contributions will drop out of Quick Stats. The matching archive (if any) is not affected. This action cannot be undone.`,entryDeleted:`Print log entry deleted`,entryDeleteFailed:`Failed to delete print log entry`,editEntryTitle:`Edit print log entry`,editEntryDescription:`Classify this print run. The Failure Analysis widget groups by these values, so updates flow through to stats immediately.`,entryUpdated:`Print log entry updated`,entryUpdateFailed:`Failed to update print log entry`,statuses:{completed:`Completed`,failed:`Failed`,stopped:`Stopped`,cancelled:`Cancelled`,skipped:`Skipped`}}},dispatchToast:{untitled:`Print job`,startingPrints:`Starting prints`,progressSummary:`{{complete}}/{{total}} complete • Processing: {{processing}}`,expandDetails:`Expand dispatch details`,collapseDetails:`Collapse dispatch details`,awaitingPrinter:`Awaiting printer…`,status:{processing:`Processing`,completed:`Completed`,failed:`Failed`},failed:{generic:`Dispatch failed`,upload_failed:`Upload to printer failed`,start_command_failed:`Printer rejected start command`},dismiss:`Dismiss`},pipelineRuns:{title:`Pipeline Runs`,loading:`Loading…`,empty:`No pipeline runs yet.`,filter:{pipeline:`Pipeline`,status:`Status`,target:`Target`,all:`All`,allPipelines:`All pipelines`,allStatus:`All statuses`,allTargets:`All targets`,clear:`Clear filters`,noMatches:`No runs match the current filters.`},totalCount_one:`{{n}} run`,totalCount_other:`{{n}} runs`,copies:`{{n}} copies`,failedCount:`{{n}} failed`,copyN:`Copy {{n}}`,retryFailed:`Retry failed`,retryOf:`retry of #{{n}}`,pagination:`{{start}}–{{end}} of {{total}}`,cancelledByUser:`Cancelled by user`,toast:{cancelled:`Run cancelled`,cancelFailed:`Cancel failed`,retryStarted:`Retry started`,retryFailed:`Retry failed`,cleared:`{{n}} runs cleared`,clearFailed:`Clear failed`},clearLog:`Clear log`,clearConfirmTitle:`Clear log?`,clearConfirmBody:`Delete every completed, failed, cancelled, and partial-failure pipeline run? In-flight runs are kept. This cannot be undone.`,clearConfirmAction:`Clear`,jobStatus:{pending:`pending`,awaiting_printer:`awaiting printer`,queued:`queued`,printing:`printing`,completed:`completed`,failed:`failed`,cancelled:`cancelled`}},queue:{title:`Print Queue`,subtitle:`Schedule and manage your print jobs`,filamentShort:{rowBadge:`Insufficient filament for the assigned spool`,rowTooltip:`The dispatch scheduler flagged this item. Click Play to see the per-slot deficit and decide whether to print anyway.`,confirmTitle:`Insufficient filament`,confirmIntro:`The assigned spool cannot satisfy at least one slot. Print anyway?`,lineItem:`Slot {{slot}}: needs {{required}} g, {{remaining}} g remaining`,unknown:`unknown`,printAnyway:`Print Anyway`},filamentMissing:{confirmTitle:`Filament not loaded`,confirmIntro:`The printer has no tray with this filament. Load it and press Start again, or print anyway:`},slicerAmsMapping:{rowBadge:`AMS slots saved for this printer`,rowTooltip:`This archive carries the exact AMS slots the slicer picked, saved for the printer this item targets. A reprint on it can reuse those trays instead of matching again by type and colour.`},editQueueItem:`Edit Queue Item`,selectAllPlates:`Select All {{count}} Plates`,deselectAll:`Deselect All`,printQueued:`Print queued`,printQueuedWillStartWhenIdle:`Will start when printer is idle`,itemsQueued:`{{count}} items queued`,sending:`Sending...`,sendingProgress:`Sending {{current}}/{{total}}...`,adding:`Adding...`,addingProgress:`Adding {{current}}/{{total}}...`,savingProgress:`Saving {{current}}/{{total}}...`,clearQueue:`Clear Queue`,clearHistory:`Clear History`,emptyQueue:`Queue is empty`,position:`Position`,scheduledTime:`Scheduled Time`,moveUp:`Move Up`,moveDown:`Move Down`,startNow:`Start Now`,printingInProgress:`Printing in progress...`,viewArchive:`View archive`,viewInFileManager:`View in File Manager`,itemCount:`{{count}} item`,itemCount_plural:`{{count}} items`,dragToReorder:`Drag to reorder (ASAP only)`,reorderHint:`Position only affects ASAP items. Scheduled items run at their set time.`,sjf:{label:`SJF`,tooltip:`Shortest Job First — scheduler prioritizes shorter prints`},addedBy:`Added by {{name}}`,nextInQueue:`Next in queue`,clearPlateSuccess:`Plate cleared — ready for next print`,plateNumber:`Plate {{index}}`,quantity:`Quantity`,quantityHint:`Creates {{count}} queue items`,plateQuantityLabel:`Runs of {{plate}}`,plateQuantityTotal_one:`{{count}} run in total`,plateQuantityTotal_other:`{{count}} runs in total`,batchOrders:{title:`Batch Orders`,emptyTitle:`No batch orders`,emptyDescription:`Queue a multi-plate file, or more than one copy of a plate, and the order shows up here with its progress.`,filter:{active:`Active`,completed:`Completed`,cancelled:`Cancelled`,all:`All`},status:{active:`Active`,completed:`Completed`,cancelled:`Cancelled`},noTargets:`Grouping only`,noTargetsHint:`Created before per-plate targets existed, so it tracks the runs it queued rather than a target.`,dispatchRemaining:`Queue {{count}} remaining`,dispatchPlate:`Queue remaining`,strandedPlate:`Nothing left to copy settings from`,strandedNotice:`Cannot queue {{runs}} of the {{owed}} runs still owed: that plate has no queued or finished run left to copy settings from. Queue the plate once from the file, or cancel the order.`,dispatched:`Queued the remaining runs for {{name}}`,plateProgress:`{{completed}} of {{target}} done`,remaining:`{{count}} still owed`,failed:`{{count}} failed`,printing:`{{count}} printing`,wholeFile:`Whole file`,due:`Due {{date}}`,costSoFar:`{{amount}} so far`,costRemaining:`({{amount}} to go)`},activeBatches:`Active Batches`,batchProgress:`{{completed}} of {{total}} completed`,cancelBatch:`Cancel Remaining`,batchCancelled:`Remaining batch items cancelled`,cancelBatchConfirmTitle:`Cancel Batch`,cancelBatchConfirmMessage:`Close this order? Any runs still queued are cancelled, and it stops asking for what it has not produced.`,batch:{defaultName:`Batch`,label:`{{count}} item`,label_plural:`{{count}} items`,pendingCount:`{{count}} pending`,pendingCount_plural:`{{count}} pending`,expand:`Expand batch`,collapse:`Collapse batch`,groupAsBatch:`Group as batch…`,groupAsBatchDescription:`Combine the {{count}} selected items into a single collapsible batch.`,nameLabel:`Batch name`,namePlaceholder:`e.g. Friday gifts`,create:`Create batch`,ungroup:`Ungroup`,ungroupConfirmTitle:`Ungroup batch?`,ungroupConfirmMessage:`The items will stay in the queue but no longer be grouped together.`,dragGroup:`Drag group`},tabs:{batches:`Batches`,queue:`Queue`,history:`History`,timeline:`Timeline`,pipelines:`Pipelines`},layout:{flatList:`List`,byPrinter:`By Printer`,groupByPrinter:`Group by Printer`},history:{emptyTitle:`No history yet`,emptyDescription:`Completed, cancelled, and failed prints will appear here.`,showMore:`Show more`,showingCount:`Showing {{shown}} of {{total}}`},dragGhost:{multiCount:`{{count}} items`,batch:`{{name}} ({{count}} copy)`,batch_plural:`{{name}} ({{count}} copies)`},sections:{currentlyPrinting:`Currently Printing`,queued:`Queued`,history:`History`},status:{pending:`Pending`,waiting:`Waiting`,printing:`Printing`,paused:`Paused`,completed:`Completed`,failed:`Failed`,skipped:`Skipped`,cancelled:`Cancelled`},summary:{printing:`Printing`,queued:`Queued`,totalTime:`Total Queue Time`,totalWeight:`Total Queue Weight`,history:`History`},filter:{allPrinters:`All Printers`,unassigned:`Unassigned`,allStatus:`All Status`,allLocations:`All Locations`,any:`Any`},sort:{byPosition:`Sort by Position`,byName:`Sort by Name`,byPrinter:`Sort by Printer`,bySchedule:`Sort by Schedule`,byDate:`Sort by Date`,ascendingOldest:`Ascending (oldest first)`,descendingNewest:`Descending (newest first)`},badges:{awaitingReview:`Waiting for review`,staged:`Staged`,requiresPrevious:`Requires previous success`,autoPowerOff:`Auto power off`,gcodeInjection:`G-code`,confirmOutcome:`Outcome prompt`,confirmOutcomeTitle:`Asks how the print came out after it completes`},empty:{title:`No prints scheduled`,description:`Schedule a print from the Archives page using the "Schedule" option in the context menu, or drag and drop files to get started.`},time:{etaIfStartedNow:`Completion time if this job started now`,whenFree:`When a printer is free`,overdue:`Overdue`,now:`Now`,lessThanMinute:`In less than a minute`,inMinutes:`In {{count}} min`,inHours:`In {{count}} hours`},actions:{startPrint:`Start Print`,stopPrint:`Stop Print`,requeue:`Re-queue`},bulkEdit:{title:`Edit {{count}} Item`,title_plural:`Edit {{count}} Items`,description:`Only changed settings will be applied to selected items.`,printer:`Printer`,noChange:`— No change —`,queueOptions:`Queue Options`,staged:`Staged (manual start)`,autoPowerOff:`Auto power off after print`,requirePrevious:`Require previous success`,gcodeInjection:`Inject G-code`,printOptions:`Print Options`,bedLevelling:`Bed levelling`,flowCalibration:`Flow calibration`,vibrationCalibration:`Vibration calibration`,layerInspection:`First layer inspection`,timelapse:`Timelapse`,useAms:`Use AMS`,confirmOutcome:`Ask for outcome`,nozzleOffsetCali:`Nozzle offset calibration`,applyChanges:`Apply Changes`,selectAll:`Select All`,deselectAll:`Deselect All`,selected:`{{count}} selected`,editSelected:`Edit Selected`,cancelSelected:`Cancel Selected`},confirm:{cancelTitle:`Cancel Scheduled Print`,cancelMessage:`Are you sure you want to cancel "{{name}}"?`,stopTitle:`Stop Print`,stopMessage:`Are you sure you want to stop the current print "{{name}}"? This will cancel the print job on the printer.`,removeTitle:`Remove from History`,removeMessage:`Are you sure you want to remove "{{name}}" from the queue history?`,clearHistoryTitle:`Clear History`,clearHistoryMessage:`Are you sure you want to remove all {{count}} item(s) from the history?`,cancelButton:`Cancel Print`,stopButton:`Stop Print`,thisPrint:`this print`,thisItem:`this item`},toast:{cancelled:`Queue item cancelled`,cancelFailed:`Failed to cancel item`,removed:`Queue item removed`,keptForOrder:`Cancelled instead of removed: this is the only run its batch order can re-queue this plate from`,historyKeptForOrders:`Kept {{kept}} that batch orders still need.`,removeFailed:`Failed to remove item`,stopped:`Print stopped`,stopFailed:`Failed to stop print`,released:`Print released to queue`,startFailed:`Failed to start print`,reorderFailed:`Failed to reorder queue`,historyCleared:`Cleared {{count}} history item(s)`,clearHistoryFailed:`Failed to clear history`,updateFailed:`Failed to update items`,bulkCancelled:`Cancelled {{count}} item(s)`,bulkCancelFailed:`Failed to cancel items`,batchCreated:`Batch "{{name}}" created`,batchCreateFailed:`Failed to create batch`,batchUngrouped:`Ungrouped {{count}} item(s)`,batchUngroupFailed:`Failed to ungroup batch`,resumedAfterFailure:`Resumed queue — {{restored}} job(s) restored to pending`,resumeAfterFailureFailed:`Failed to resume queue`},resumeAfterFailure:{banner:`{{printer}} is blocked by a previous-print failure — {{count}} job(s) skipped`,bannerHint:`Fix the printer issue, then resume to restore the skipped jobs and clear the gate.`,button:`Resume after failure`,confirmTitle:`Resume queue after failure?`,confirmMessage:`Restore {{count}} skipped job(s) on {{printer}} to pending and clear the previous-print gate. Make sure the printer is ready before continuing.`},timeline:{listView:`List`,timelineView:`Timeline`,unassigned:`Unassigned`,noData:`No scheduled prints for this day`,nothingCommitted:`No committed schedules in this window. Staged items, waiting items, and ASAP jobs on idle printers are not shown — set a scheduled time or release a staged item to see it here.`,allDoneBy:`All prints estimated done by {{time}}`,staged:`Staged`,filterAll:`Show All`,filterPrinting:`Printing`,filterQueued:`Queued`,time:{anyMoment:`any moment`,minutesLeft:`{{minutes}}m left`,hoursLeft:`{{hours}}h left`,hoursMinutesLeft:`{{hours}}h {{minutes}}m left`},day:{previous:`Previous day`,next:`Next day`,today:`Today`},window:{back12h:`Back 12 hours`,forward12h:`Forward 12 hours`,now:`Now`},printerColumnHeader:`Printer`},permissions:{noStopPrint:`You do not have permission to stop prints`,noStartPrint:`You do not have permission to start prints`,awaitingReview:`Waiting for review: someone who manages the queue starts this job`,noEdit:`You do not have permission to edit this queue item`,noCancel:`You do not have permission to cancel this queue item`,noRequeue:`You do not have permission to re-queue items`,noRemove:`You do not have permission to remove this queue item`,noClearHistory:`You do not have permission to clear all history`,noEditItems:`You do not have permission to edit queue items`,noCancelItems:`You do not have permission to cancel queue items`}},stats:{title:`Statistics`,subtitle:`Drag widgets to rearrange. Click the eye icon to hide.`,overview:`Overview`,totalPrints:`Total Prints`,successRate:`Success Rate`,totalPrintTime:`Total Print Time`,printTime:`Print Time`,totalFilament:`Total Filament Used`,filamentUsed:`Filament Used`,filamentCost:`Filament Cost`,totalCost:`Total Cost`,energyUsed:`Energy Used`,energyCost:`Energy Cost`,wearCost:`Wear Cost`,energyWarmingUpTooltip:`Energy tracking is still collecting hourly snapshots. Date-range totals will become accurate once at least one snapshot exists before the selected range. Early values may undercount.`,averagePrintTime:`Average Print Time`,printsPerDay:`Prints per Day`,byPrinter:`By Printer`,printsByPrinter:`Prints by Printer`,byMaterial:`By Material`,byMonth:`By Month`,last7Days:`Last 7 Days`,last30Days:`Last 30 Days`,last90Days:`Last 90 Days`,allTime:`All Time`,quickStats:`Quick Stats`,printActivity:`Print Activity`,filamentTypes:`Filament Types`,filamentTrends:`Filament Trends`,materialNumbers:{title:`By Material Number`,empty:`No material numbers assigned yet. Add them to spools in the inventory to group consumption and costs here.`,loadFailed:`Could not load the material number statistics.`,spools:`Spools`,remaining:`Remaining`,consumed:`Consumed`,cost:`Cost`},suppliers:{title:`By Supplier`,empty:`No purchases recorded yet. Mark on a spool which supplier it was bought from to group consumption and costs here.`,error:`Could not load supplier statistics`,supplier:`Supplier`,spools:`Spools`,remaining:`Remaining`,consumed:`Consumed`,cost:`Cost`},failureAnalysis:`Failure Analysis`,timeAccuracy:`Time Accuracy`,successful:`Successful:`,failed:`Failed:`,cancelled:`Cancelled:`,perfectEstimate:`100% = perfect estimate`,noTimeAccuracyData:`No time accuracy data yet`,noFilamentData:`No filament data available`,noPrinterData:`No printer data available`,noPrintData:`No print data available`,noPrintDataLast30Days:`No print data in the last 30 days`,failureReasons:`Failure Reasons`,topFailureReasons:`Top Failure Reasons`,failedPrintsCount:`{{failed}} / {{total}} prints failed`,rejectedPrintsCount:`{{rejected}} rejected after completion`,yieldRate:`Yield: {{rate}}%`,lastWeekRate:`Last week: {{rate}}%`,resetLayout:`Reset Layout`,recalculateCosts:`Recalculate Costs`,recalculateCostsHint:`Recalculate all archive costs using current filament prices`,exportStats:`Export Stats`,exportAsCsv:`Export as CSV`,exportAsExcel:`Export as Excel`,hiddenCount:`{{count}} Hidden`,exportDownloaded:`Export downloaded`,exportFailed:`Export failed`,layoutReset:`Layout reset`,recalculatedCosts:`Recalculated costs for {{count}} archives`,recalculateFailed:`Failed to recalculate costs`,loadingStats:`Loading statistics...`,noPermissionResetLayout:`You do not have permission to reset layout`,noPermissionRecalculate:`You do not have permission to recalculate costs`,noPrintDataInRange:`No print data in selected range`,periodFilament:`Period Filament`,periodCost:`Period Cost`,avgPerPrint:`Avg per Print`,usageOverTime:`Usage Over Time`,energyOverTime:`Energy Over Time`,filamentByWeight:`Weight`,printDuration:`Print Duration`,printerUtilization:`Printer Utilization`,filamentSuccess:`Success by Material`,printHabits:`Print Habits`,printTimeOfDay:`Print Time of Day`,colorDistribution:`Color Distribution`,noColorData:`No color data available`,records:`Records`,longestPrint:`Longest Print`,heaviestPrint:`Heaviest Print`,mostExpensivePrint:`Most Expensive`,busiestDay:`Busiest Day`,successStreak:`Success Streak`,streakPrint:`consecutive print`,streakPrints:`{{count}} consecutive prints`,printerStats:`Printer Stats`,hours:`hours`,avgPrints:`Avg. prints`,noArchiveData:`No print data available`,filamentByTime:`Time`,avgWeight:`Avg. weight`,avgTime:`Avg. time`,filamentByPrints:`Prints`,timeframe:{today:`Today`,"this-week":`This Week`,"this-month":`This Month`,"last-7":`Last 7 Days`,"last-30":`Last 30 Days`,"last-90":`Last 90 Days`,"this-year":`This Year`,"all-time":`All Time`,custom:`Custom Range`,from:`From`,to:`To`},allUsers:`All Users`,noUser:`No User (System)`,filterByUser:`Filter by User`},maintenance:{title:`Maintenance`,overview:`Overview`,allOk:`All maintenance up to date`,dueCount:`{{count}} item due`,dueCount_plural:`{{count}} items due`,warningCount:`{{count}} warning`,warningCount_plural:`{{count}} warnings`,totalPrintTime:`Total Print Time`,nextMaintenance:`Next Maintenance`,nothingDue:`Nothing due`,tasks:`Tasks`,lastPerformed:`Last performed`,interval:`Interval`,hoursRemaining:`{{hours}}h remaining`,hoursOverdue:`{{hours}}h overdue`,markDone:`Mark as Done`,performMaintenance:`Perform Maintenance`,history:`History`,noHistory:`No maintenance history`,editPrintHours:`Edit Print Hours`,currentHours:`Current Hours`,statusTab:`Status`,settingsTab:`Settings`,overdueCount:`{{count}} overdue`,dueSoonCount:`{{count}} due soon`,dueSoon:`Due soon`,allGood:`All good`,overdueBy:`Overdue by {{duration}}`,dueIn:`Due in {{duration}}`,timeLeft:`{{duration}} left`,day:`1 day`,days:`{{count}} days`,week:`1 week`,weeks:`{{count}} weeks`,month:`1 month`,months:`{{count}} months`,year:`1 year`,maintenanceTypes:`Maintenance Types`,maintenanceTypesDescription:`System types and your custom maintenance tasks`,addCustomType:`Add Custom Type`,restoreDefaults:`Restore Default Tasks`,intervalType:`Interval Type`,intervalValue:`Interval ({{type}})`,icon:`Icon`,documentationLink:`Documentation Link (optional)`,assignToPrinters:`Assign to Printers`,selectAtLeastOnePrinter:`Select at least one printer`,addType:`Add Type`,custom:`Custom`,printHours:`Print Hours`,calendarDays:`Calendar Days`,exampleName:`e.g., Replace HEPA Filter`,viewDocumentation:`View documentation`,timeBasedInterval:`Time-based interval`,intervalOverrides:`Interval Overrides`,intervalOverridesDescription:`Customize intervals for specific printers`,assignedToPrinters:`Assigned to printers:`,noPrintersAssigned:`No printers assigned`,addPrinterShort:`Add:`,printersAssignedClick:`{{count}} printer(s) assigned - click to manage`,removeFromPrinter:`Remove from this printer`,types:{lubricateCarbonRods:`Lubricate Carbon Rods`,lubricateRails:`Lubricate Linear Rails`,cleanNozzle:`Clean Nozzle/Hotend`,checkBelts:`Check Belt Tension`,cleanBuildPlate:`Clean Build Plate`,checkExtruder:`Check Extruder Gears`,checkCooling:`Check Cooling Fans`,generalInspection:`General Inspection`,cleanCarbonRods:`Clean Carbon Rods`,lubricateSteelRods:`Lubricate Steel Rods`,cleanSteelRods:`Clean Steel Rods`,cleanLinearRails:`Clean Linear Rails`,checkPtfeTube:`Check PTFE Tube`,replaceHepaFilter:`Replace HEPA Filter`,replaceCarbonFilter:`Replace Carbon Filter`,lubricateLeftNozzleRail:`Lubricate Left Nozzle Rail`},maintenanceComplete:`Maintenance marked as complete`,typeUpdated:`Maintenance type updated`,typeDeleted:`Maintenance type deleted`,defaultsRestored:`Restored {{count}} default task(s)`,printHoursUpdated:`Print hours updated`,printerAssigned:`Printer assigned`,printerRemoved:`Printer removed`,deleteTypeConfirm:`Delete "{{name}}"?`,deleteSystemTypeTitle:`Delete default maintenance task?`,deleteSystemTypeMessage:`Are you sure you want to delete the default maintenance task "{{name}}"?`,noPermissionUpdate:`You do not have permission to update maintenance items`,noPermissionPerform:`You do not have permission to perform maintenance`,noPermissionEditTypes:`You do not have permission to edit maintenance types`,noPermissionDeleteTypes:`You do not have permission to delete maintenance types`,noPermissionEditHours:`You do not have permission to edit print hours`,noPermissionRemovePrinter:`You do not have permission to remove printer assignments`,noPermissionAssignPrinter:`You do not have permission to assign printers`,noPermissionEditIntervals:`You do not have permission to edit intervals`,configureSettings:`Configure maintenance types and intervals`},settings:{sliceEngine:`Slice engine`,sliceEngineSidecar:`Server sidecar`,sliceEngineSidecarHint:`Slicing runs on the server, in the slicer sidecar container.`,sliceEngineBrowser:`In browser`,sliceEngineBrowserHint:`Slicing runs on this device, with no server involved.`,title:`Settings`,general:`General`,tabs:{general:`General`,smartPlugs:`Smart Plugs`,sensors:`Sensors`,notifications:`Notifications`,queue:`Workflow`,queueDispatch:`Queue & Dispatch`,queuePipelines:`Pipelines`,filament:`Filament`,camera:`Camera`,network:`Network`,apiKeys:`API Keys`,virtualPrinter:`Virtual Printer`,spoolbuddy:`SpoolBuddy`,failureDetection:`Failure Detection`,users:`Authentication`,backup:`Backup`,emailAuth:`Email Authentication`,ldap:`LDAP`,twoFa:`Two-Factor Auth`,oidc:`SSO / OIDC`,security:`Security`},spoolbuddy:{infoTitle:`SpoolBuddy devices`,infoBody:`SpoolBuddy kiosks register themselves automatically via heartbeat. Unregister a device here if it is no longer in use or if a stale duplicate was left behind by a daemon crash.`,duplicatesTitle:`{{count}} devices registered`,duplicatesBody:`Only the first registered device is used by the kiosk UI. If one of these is a stale duplicate from a crash, unregister it — an online device will re-register itself on its next heartbeat.`,empty:`No SpoolBuddy devices registered yet.`,online:`Online`,offline:`Offline`,unregister:`Unregister`,unregisterSuccess:`Device unregistered`,unregisterError:`Failed to unregister device`,confirmTitle:`Unregister SpoolBuddy device?`,confirmBody:`This will remove "{{hostname}}" ({{deviceId}}) from the database. If the device is online, it will re-register itself on its next heartbeat.`,ipAddress:`IP address`,firmware:`Firmware`,lastSeen:`Last seen`,daemonUptime:`Daemon uptime`,systemUptime:`System uptime`,never:`never`,nfc:`NFC`,scale:`Scale`,cpuTemp:`CPU temp`,cpuLoad:`CPU load`,memory:`Memory`,disk:`Disk`,update:`Update`,updateConfirmTitle:`Update Spoolbuddy daemon?`,updateConfirmBody:`Trigger a software update on "{{hostname}}"? The daemon will restart once the update is applied.`,restartBrowser:`Restart Browser`,restartBrowserConfirmTitle:`Restart kiosk browser?`,restartBrowserConfirmBody:`Restart the kiosk browser on "{{hostname}}"? The display will blank briefly.`,restartDaemon:`Restart Daemon`,restartDaemonConfirmTitle:`Restart Spoolbuddy daemon?`,restartDaemonConfirmBody:`Restart the Spoolbuddy daemon on "{{hostname}}"? The device will go offline for a few seconds.`,reboot:`Reboot`,rebootConfirmTitle:`Reboot device?`,rebootConfirmBody:`Reboot "{{hostname}}"? The device will be offline for around a minute.`,shutdown:`Shutdown`,shutdownConfirmTitle:`Shutdown device?`,shutdownConfirmBody:`Shutdown "{{hostname}}"? You will need physical access to power it back on.`,commandConfirm:`Confirm`,commandQueued:`Command queued`,commandError:`Failed to send command`},ldap:{title:`LDAP Authentication`,enabledDesc:`LDAP authentication is enabled`,disabledDesc:`LDAP authentication is disabled`,disabledHint:`Configure and save LDAP settings below, then enable.`,enabled:`LDAP authentication enabled`,disabled:`LDAP authentication disabled`,feature1:`Users can login with LDAP credentials`,feature2:`Local admin account remains as fallback`,feature3:`LDAP groups are mapped to BamBuddy groups on login`,serverConfig:`LDAP Server Configuration`,serverUrl:`Server URL`,serverUrlHint:`Use ldaps:// for SSL or ldap:// with StartTLS`,security:`Security`,securityHint:`StartTLS upgrades a plain connection to TLS. LDAPS uses TLS from the start.`,bindDn:`Bind DN (Service Account)`,bindPassword:`Bind Password`,searchBase:`Search Base DN`,userFilter:`User Search Filter`,userFilterHint:`{username} is replaced with the login username. Use (uid={username}) for OpenLDAP.`,advanced:`Advanced`,autoProvision:`Auto-provision users`,autoProvisionHint:`Automatically create a BamBuddy account on first LDAP login`,defaultGroup:`Default group`,defaultGroupNone:`— None (no fallback) —`,defaultGroupHint:`Fallback group assigned when an LDAP user authenticates but is not listed in any mapped LDAP group. Leave empty to leave unmapped users without permissions.`,groupMapping:`Group Mapping (JSON)`,groupMappingHint:`Map LDAP group DNs to BamBuddy groups. Available groups: `,testConnection:`Test Connection`,settingsSaved:`LDAP settings saved`,errors:{serverRequired:`LDAP server URL is required`,searchBaseRequired:`Search base DN is required`,enableAuthFirst:`Enable authentication first`,configureLdapFirst:`Save LDAP settings first`}},email:{smtpSettings:`SMTP Configuration`,smtpHost:`SMTP Server`,smtpPort:`SMTP Port`,security:`Security`,authentication:`Authentication`,username:`Username`,password:`Password`,fromEmail:`From Email`,fromName:`From Name`,testConnection:`Test SMTP Connection`,testRecipient:`Test Recipient Email`,sendTest:`Send Test Email`,sending:`Sending...`,save:`Save Settings`,saving:`Saving...`,advancedAuth:`Advanced Authentication`,advancedAuthEnabled:`Advanced Authentication is enabled`,advancedAuthEnabledDesc:`Email-based user management features are active. New users will receive auto-generated passwords via email, and users can reset their passwords through the forgot password feature.`,advancedAuthDisabled:`Advanced Authentication is disabled`,advancedAuthDisabledDesc:`Enable advanced authentication to activate email-based features for user management.`,enable:`Enable`,disable:`Disable`,feature1:`Passwords are auto-generated and emailed to new users`,feature2:`Users can login with username or email`,feature3:`Forgot password feature is available`,feature4:`Admins can reset user passwords via email`,errors:{requiredFields:`Please fill in all required fields`,usernameRequired:`Username is required when authentication is enabled`,enterTestEmail:`Please enter a test email address`,smtpServerAndEmail:`Please fill in SMTP Server and From Email before testing`,usernamePasswordRequired:`Username and Password are required when authentication is enabled`,configureSmtpFirst:`Please configure and test SMTP settings first`,enableAuthFirst:`Please enable authentication first to use email-based features.`},success:{settingsSaved:`SMTP settings saved successfully`},securityOptions:{starttls:`STARTTLS (Port 587)`,ssl:`SSL/TLS (Port 465)`,none:`None (Port 25)`},authOptions:{enabled:`Enabled`,disabled:`Disabled`}},appearance:`Appearance`,notifications:`Notifications`,smartPlugs:`Smart Plugs`,spoolman:`Spoolman`,updates:`Updates`,language:`Language`,languageDescription:`Select your preferred language`,theme:`Theme`,themeLight:`Light`,themeDark:`Dark`,themeSystem:`System`,defaultView:`Default View`,defaultViewDescription:`Page to show when opening the app`,checkForUpdates:`Check for Updates`,autoUpdate:`Auto Update`,currentVersion:`Current Version`,latestVersion:`Latest Version`,upToDate:`You are up to date`,updateAvailable:`Update available`,notificationLanguage:`Notification Language`,notificationLanguageDescription:`Language for push notifications`,bedCooledThreshold:`Bed Cooled Threshold`,bedCooledThresholdDescription:`Temperature below which the bed is considered cooled after a print`,userNotificationsEnabled:`User Notifications`,userNotificationsEnabledDescription:`Enable the user notifications menu and email notifications for print job events. Requires Advanced Authentication.`,userNotificationsDisabledHint:`Enable Advanced Authentication to use user notifications.`,notificationProviders:`Notification Providers`,addProvider:`Add Provider`,editProvider:`Edit Provider`,providerType:`Provider Type`,testNotification:`Test Notification`,testSuccess:`Test notification sent successfully`,testFailed:`Failed to send test notification`,quietHours:`Quiet Hours`,quietHoursDescription:`Do not disturb during these hours`,quietHoursStart:`Start`,quietHoursEnd:`End`,events:{title:`Notification Events`,printStart:`Print Started`,printComplete:`Print Completed`,printFailed:`Print Failed`,printStopped:`Print Stopped`,printProgress:`Progress Milestones`,printProgressDescription:`Notify at 25%, 50%, 75%`,printerOffline:`Printer Offline`,printerError:`Printer Error`,filamentLow:`Low Filament`,maintenanceDue:`Maintenance Due`,maintenanceDueDescription:`Notify when maintenance is needed`},smartPlug:{title:`Smart Plugs`,add:`Add Smart Plug`,edit:`Edit Smart Plug`,name:`Name`,ipAddress:`IP Address`,linkedPrinter:`Linked Printer`,autoOn:`Auto Power On`,autoOnDescription:`Turn on when print starts`,autoOff:`Auto Power Off`,autoOffDescription:`Turn off after print completes`,offDelay:`Off Delay`,offDelayMinutes:`Minutes after print`,offDelayTemp:`When nozzle below temperature`,currentState:`Current State`,turnOn:`Turn On`,turnOff:`Turn Off`},filamentTracking:`Filament Tracking`,filamentTrackingDesc:`Choose how to track your filament spools. You can use the built-in inventory or connect an external Spoolman server.`,autoAddUnknownRfid:`Auto-add unknown RFID spools`,autoAddUnknownRfidDesc:`Automatically create an inventory entry when a spool with an unknown RFID tag is detected. Turn off if you pre-register new spools manually to avoid duplicates.`,filamentChecks:`Filament checks`,disableFilamentWarnings:`Disable filament warnings`,disableFilamentWarningsDesc:`Don't show warnings about insufficient filament when printing or queueing`,preferLowestFilament:`Prefer lowest remaining filament`,preferLowestFilamentDesc:`When multiple spools match, use the one with the least filament remaining`,preferLowestFilamentBackupNote:`Only takes effect when AMS Filament Backup is enabled on the printer — otherwise the printer cannot switch to a second spool when the picked one runs out.`,trackingModeBuiltIn:`Built-in Inventory`,trackingModeBuiltInDesc:`RFID auto-matching and usage tracking included`,trackingModeSpoolmanDesc:`External filament management server`,builtInFeatureRfid:`Automatically detects Bambu Lab RFID spools in AMS`,builtInFeatureUsage:`Tracks filament consumption per print`,builtInFeatureCatalog:`Manage spools, colors, and K-factor profiles`,builtInFeatureThirdParty:`Third-party spools can be assigned to inventory spools`,amsSyncButton:`Sync Weights from AMS`,amsSyncTitle:`Sync Spool Weights from AMS`,amsSyncMessage:`This will overwrite all inventory spool weights with the current AMS remain% values from connected printers. Use this to recover from corrupted weight data. Printers must be online.`,amsSyncing:`Syncing...`,amsSyncSuccess:`{{synced}} spool(s) synced, {{skipped}} skipped`,amsSyncError:`Failed to sync weights from AMS`,spoolmanAmsSyncButton:`Sync Spoolman Weights from AMS`,spoolmanAmsSyncTitle:`Sync Spoolman Spool Weights from AMS`,spoolmanAmsSyncMessage:`This will update all Spoolman spool weights based on the current AMS remain% values from connected printers. Printers must be online.`,spoolmanAmsSyncing:`Syncing...`,spoolmanAmsSyncSuccess:`{{synced}} spool(s) synced, {{skipped}} skipped`,spoolmanAmsSyncError:`Failed to sync Spoolman weights from AMS`,spoolmanAmsSyncErrorUnreachable:`Failed to sync Spoolman weights (Spoolman unreachable)`,spoolmanAmsSyncErrorNotConfigured:`Failed to sync Spoolman weights (Spoolman not configured)`,spoolmanNotConfigured:`Spoolman not configured`,spoolmanFilamentCatalogTitle:`Spoolman Filament Catalog`,spoolmanFilamentCatalogDesc:`Filament names and tare weights from your Spoolman instance. Name and spool weight are editable here; all other properties are managed directly in Spoolman.`,spoolmanUrl:`Spoolman URL`,spoolmanUrlHint:`URL of your Spoolman server (e.g., http://localhost:7912)`,spoolmanConnected:`Connected`,spoolmanDisconnected:`Disconnected`,status:`Status`,connect:`Connect`,disconnect:`Disconnect`,howSyncWorks:`How Sync Works`,syncInfoRfidOnly:`Only official Bambu Lab spools with RFID are synced`,syncInfoAutoCreate:`New spools are auto-created in Spoolman on first sync`,syncInfoThirdPartySkipped:`Non-Bambu Lab spools (third-party, refilled) are skipped`,linkingExistingSpools:`Linking Existing Spools`,linkingExistingSpoolsDesc:`To link existing Spoolman spools to your AMS, hover over an AMS slot and click "Link to Spoolman".`,syncMode:`Sync Mode`,syncModeAuto:`Automatic`,syncModeManual:`Manual Only`,syncModeAutoDesc:`AMS data syncs automatically when changes are detected`,syncModeManualDesc:`Only sync when manually triggered`,syncAmsData:`Sync AMS Data`,syncAmsDataDesc:`Manually sync printer AMS data to Spoolman`,allPrinters:`All Printers`,noDefaultPrinter:`No default (ask each time)`,sidebarOrder:`Sidebar order`,saveThumbnails:`Save thumbnails`,captureFinishPhoto:`Capture finish photo`,noPrintersConfigured:`No printers configured`,archiveMode:{always:`Always create archive entry`,never:`Never create archive entry`,ask:`Ask each time`},checkForUpdatesLabel:`Check for updates`,checkPrinterFirmware:`Check printer firmware`,includeBetaUpdates:`Include beta versions`,includeBetaUpdatesDesc:`Notify about beta and prerelease versions when checking for updates`,announcementsEnabled:`Receive announcements`,announcementsEnabledDesc:`Messages from the Bambuddy maintainers, such as security fixes and breaking changes. Bambuddy fetches a signed file from GitHub every few hours; nothing about this install is sent.`,announcementsLearnMore:`Learn more`,announcementsAllUsers:`Show to all users`,announcementsAllUsersDesc:`Off: only administrators see them. Has no effect while authentication is off.`,localLogin:{disable:`Disable local username/password login`,disableHint:`When enabled, only SSO providers can sign in. LDAP is unaffected. Set BAMBUDDY_LOCAL_LOGIN=true on the server to keep a recovery path.`},enableRetry:`Enable retry`,homeAssistantDescription:`Control smart plugs via Home Assistant`,environmentManagedLabel:`(Environment Managed)`,autoEnabledViaEnv:`Automatically enabled via environment variables`,urlFromEnvReadOnly:`Value set by HA_URL environment variable (read-only)`,tokenFromEnvReadOnly:`Value set by HA_TOKEN environment variable (read-only)`,mqttConnectedTo:`Connected to`,prometheusDescription:`Expose printer data in Prometheus format`,noSmartPlugsTitle:`No smart plugs configured`,noSmartPlugsDescription:`Add a Tasmota-based smart plug to track energy usage and automate power control.`,noProvidersTitle:`No providers configured`,noProvidersDescription:`Add a provider to receive alerts.`,noTemplatesAvailable:`No templates available. Restart the backend to seed default templates.`,apiPermissionView:`View printer status and queue`,apiPermissionEdit:`Add and remove items from print queue`,apiKeysEmptyTitle:`No API keys`,apiKeysEmptyDescription:`Create an API key to integrate with external services.`,noUsersFound:`No users found`,noGroupsFound:`No groups found`,noGroupsAvailable:`No groups available`,passwordsDoNotMatch:`Passwords do not match`,systemGroupWarning:`System group names cannot be changed`,authDisabledTitle:`Authentication is Disabled`,authDisabledFeature1:`Require login to access the system`,authDisabledFeature2:`Create multiple users with group-based permissions`,authDisabledFeature3:`Control access with 50+ granular permissions`,userHasCreated:`This user has created:`,userItemsQuestion:`What would you like to do with these items?`,deleteUserConfirm:`Are you sure you want to delete this user?`,actionCannotBeUndone:`This action cannot be undone.`,addFirstSmartPlug:`Add Your First Smart Plug`,providers:`Providers`,log:`Log`,testAll:`Test All`,testResults:`Test Results`,testPassedCount:`{{count}} passed`,testFailedCount:`{{count}} failed`,messageTemplates:`Message Templates`,messageTemplatesDescription:`Customize notification messages for each event.`,apiKeys:`API Keys`,apiKeysDescription:`Create API keys for external integrations and webhooks.`,createKey:`Create Key`,apiKeyCreated:`API Key Created Successfully`,apiKeyCopyWarning:`Copy this key now - it won't be shown again!`,useInApiBrowser:`Use in API Browser`,apiKeyQrButton:`QR code`,apiKeyQrTitle:`Scan to configure`,apiKeyQrCaption:`Scan with your mobile app to add this server and API key.`,apiKeyQrWarning:`Contains your secret API key — don't share or screenshot it where others can see.`,createNewApiKey:`Create New API Key`,keyName:`Key Name`,keyNamePlaceholder:`e.g., Home Assistant, OctoPrint`,readStatus:`Read Status`,readStatusDescription:`View printer status, queue, library, archives, and slicer pipelines`,manageQueue:`Manage Queue`,manageQueueDescription:`Add and remove items from print queue. With Manage Library, run slicer pipelines`,controlPrinter:`Control Printer`,controlPrinterDescription:`Pause, resume, and stop prints`,manageLibrary:`Manage Library`,manageLibraryDescription:`Upload, rename, delete, and slice library files; import models from MakerWorld. With Manage Queue, run slicer pipelines`,manageInventory:`Manage Inventory`,manageInventoryDescription:`Create, update, and delete spools and inventory records. Required for SpoolBuddy kiosks (NFC scan, scale readings, kiosk system commands).`,manageMaintenance:`Manage Maintenance`,manageMaintenanceDescription:`Log completed maintenance, reset counters, edit intervals, and manage the maintenance-type catalog. Suited to Home Assistant automations that record "I cleaned the nozzle" without granting broader printer control.`,manageArchives:`Manage Archives`,manageArchivesDescription:`Edit and delete print archives, including removing old prints and their contribution to statistics. Suited to automations that prune the print history.`,manageProjects:`Manage Projects`,manageProjectsDescription:`Create, update, and delete projects, and add archives to them. Suited to automations that organize prints into projects.`,libraryBadge:`Library`,inventoryBadge:`Inventory`,maintenanceBadge:`Maintenance`,archivesBadge:`Archives`,projectsBadge:`Projects`,cloudAccess:`Allow cloud access`,cloudAccessDescription:`Read Bambu Cloud presets and filaments on your behalf. Requires you to be signed into Bambu Cloud.`,cloudBadge:`Cloud`,updateEnergyCost:`Update electricity price`,updateEnergyCostDescription:`Allow this key to POST a new per-kWh electricity price to /settings/electricity-price. Useful for Home Assistant dynamic-tariff automations (Tibber, Octopus, etc.). This is the only settings field writable via API key.`,energyCostBadge:`Energy`,sendNotifications:`Send notifications`,sendNotificationsDescription:`Allow this key to send messages through the notification channels that accept messages from connected apps (POST /notifications/app-message). For apps like Bambuddy Orders. Nothing else: the key can't read or change the channels.`,sendNotificationsBadge:`Notify`,legacyKey:`Legacy`,legacyKeyTooltip:`Created before per-user ownership; recreate to use cloud access`,unnamedKey:`Unnamed Key`,lastUsed:`Last used`,read:`Read`,control:`Control`,createFirstKey:`Create Your First Key`,webhookEndpoints:`Webhook Endpoints`,webhookApiKeyHint:`Use your API key in the X-API-Key header.`,webhook:{getAllStatus:`Get all printer status`,getSpecificStatus:`Get specific printer status`,addToQueue:`Add to print queue`,pausePrint:`Pause print`,resumePrint:`Resume print`,stopPrint:`Stop print`},apiBrowser:`API Browser`,apiBrowserDescription:`Explore and test all available API endpoints.`,apiKeyForTesting:`API Key for Testing`,apiKeyPlaceholder:`Paste your API key here to test authenticated endpoints...`,apiKeyHint:`This key will be sent as X-API-Key header with requests.`,deleteApiKeyTitle:`Delete API Key`,deleteApiKeyMessage:`Are you sure you want to delete this API key? Any integrations using this key will stop working.`,deleteKey:`Delete Key`,amsDisplayThresholds:`AMS Display Thresholds`,amsThresholdsDescription:`Configure color thresholds for AMS humidity and temperature indicators.`,humidity:`Humidity`,goodGreen:`Good (green)`,fairOrange:`Fair (orange)`,aboveFairBad:`Above fair threshold shows as red (bad)`,fairAlsoDryingThreshold:`This threshold is also used to trigger auto-drying when enabled`,fairBelowDryingFloor:`Auto-drying cannot reach this value: an AMS reads {{floor}}% or more while its heater runs, so every cycle would end and restart immediately. Raise it above {{floor}}% if auto-drying is on.`,temperature:`Temperature`,goodBlue:`Good (blue)`,aboveFairHot:`Above fair threshold shows as red (hot)`,tempAlarmThreshold:`Alarm above`,tempAlarmSeparateFromBand:`Only the alarm threshold sends notifications — Good and Fair colour the display. Leave it empty to alarm at the fair threshold, as before.`,tempAlarmMustBePositive:`A threshold of 0 or less is ignored — the alarm falls back to the fair threshold.`,historyRetention:`History Retention`,keepSensorHistory:`Keep sensor history for`,historyRetentionDescription:`Older humidity and temperature data will be automatically deleted`,defaultPrintOptions:`Default Print Options`,defaultPrintOptionsDescription:`Set default values for print options when starting new prints. These can be overridden per print in the print dialog.`,defaultBedLevelling:`Bed Levelling`,defaultBedLevellingDesc:`Auto-level bed before print`,defaultFlowCali:`Flow Calibration`,defaultFlowCaliDesc:`Calibrate extrusion flow`,defaultVibrationCali:`Vibration Calibration`,defaultVibrationCaliDesc:`Reduce ringing artifacts`,defaultLayerInspect:`First Layer Inspection`,defaultLayerInspectDesc:`AI inspection of first layer`,defaultTimelapse:`Timelapse`,defaultTimelapseDesc:`Record timelapse video`,defaultConfirmOutcome:`Ask for Outcome`,defaultConfirmOutcomeDesc:`Ask whether the print came out well after it completes`,confirmOutcomeExternalPrints:`Also ask for prints started outside Bambuddy`,confirmOutcomeExternalPrintsDesc:`Prints started at the printer, in Bambu Studio or in the Handy app are archived by Bambuddy too. With this on, they get the same outcome prompt as queued prints.`,confirmDefaultGoodOnPlateClear:`Count unanswered outcomes as good on plate release`,confirmDefaultGoodOnPlateClearDescription:`When the plate is released (manually or by the next queued print) and the print's outcome prompt is still unanswered, record it as a good part automatically. The print then counts as good as soon as the plate is released; a Telegram or link answer after that only shows the recorded result.`,defaultNozzleOffsetCali:`Nozzle Offset Calibration`,defaultNozzleOffsetCaliDesc:`Calibrate nozzle offsets between extruders`,tempFanPresetsTitle:`Temperature & Fan Presets`,tempFanPresetsDescription:`Customize the quick-select values shown in printer-card temperature and fan-speed popovers. The Off button is always shown.`,tempFanPresetsNozzle:`Nozzle temperature`,tempFanPresetsBed:`Bed temperature`,tempFanPresetsChamber:`Chamber temperature`,tempFanPresetsFan:`Fan speed`,tempFanPresetsReset:`Reset to defaults`,concurrentUploadsTitle:`Concurrent Uploads`,concurrentUploadsDescription:`How many printers the queue may send files to at the same time. Printers receive files slowly (a large print can take several minutes), and each one waits its turn — so on a bigger fleet, raising this is what stops the last printer in a batch from waiting out every transfer before it. Lower it if your network or Bambuddy host struggles with parallel transfers.`,concurrentUploadsLabel:`Printers uploaded to at once`,concurrentUploadsHelp:`1 sends to one printer at a time (the old behaviour). Default is 4.`,staggeredStart:`Staggered Start`,staggeredStartDescription:`Default group size and interval when staggering multi-printer batch starts. Can be overridden per batch in the print modal.`,preheatTitle:`Preheat & Heat Soak`,preheatDescription:`Heat the bed (and chamber, if supported) and hold at temperature before each queued print starts. Helpful for engineering filaments (PA, ABS) on printers without an active chamber heater — the bed warms the chamber by radiation while the soak timer runs. The bed target is read from the print file; chamber behaviour depends on printer model.`,preheatEnabled:`Enable preheat & soak`,preheatEnabledDesc:`When off, queued prints dispatch immediately. Each queue item can override per print.`,preheatFilamentTargetsLabel:`Per-filament chamber target (°C)`,preheatFilamentTargetsHint:`Bambuddy picks the highest target across the loaded AMS slots. A print whose slots all derive 0 — PLA, PETG, TPU, PVA — skips preheat entirely and starts immediately.`,preheatFilamentTargetsReset:`Reset to defaults`,preheatFilamentTargetsDefaultRow:`Other / unmapped`,preheatMaxWait:`Max wait (seconds)`,preheatMaxWaitHelp:`Cap on the chamber warm-up phase before falling through.`,preheatSoak:`Soak (seconds)`,preheatSoakHelp:`Hold time after target reached or max-wait elapsed.`,preheatHardwareTitle:`Per-printer behaviour:`,preheatHardwareDetail:`H2C/H2D/H2D Pro/H2S/X2D/X1E actively heat the chamber via M141. X1C/P2S read chamber temp but rely on bed-radiation heating. P1S/P1P/A1/A1 Mini have no chamber sensor — only the soak timer applies.`,preheatPerItemDesc:`Heat the bed and chamber before this print starts. Defaults to the global Settings → Workflow toggle.`,preheatOverride_inherit:`Inherit`,preheatOverride_on:`On`,preheatOverride_off:`Off`,calibrationMode_off:`Off`,calibrationMode_on:`On`,calibrationMode_auto:`Auto`,preheatTargetOverride:`Chamber target override (°C, blank = filament default)`,preheatTargetOverrideHelp:`0 heats the bed and runs the soak without the chamber. Leave blank and a print with no chamber requirement skips preheat entirely.`,plateClear:`Plate-Clear Confirmation`,requirePlateClear:`Require plate-clear confirmation`,requirePlateClearDescription:`When enabled, the scheduler waits for per-printer plate-clear confirmation before starting queued prints on printers with finished jobs. Disabling this also hides the plate status badge and the "Mark plate as cleared" button on printer cards.`,keepBedWarm:`Keep bed warm between prints`,keepBedWarmDesc:`While awaiting plate-clear, hold the bed at the keep-warm temperature below so the chamber stays hot — or at the next print's own bed temperature when that is higher. Only applies when the next print needs chamber heating (ASA, ABS, PA, PC etc.). Requires plate-clear confirmation to be enabled.`,keepWarmBedTemp:`Keep-warm bed temperature (°C)`,keepWarmBedTempHelp:`Used whenever the bed's job is to heat the chamber — the keep-warm hold, and preheat when the print file carries no bed temperature. A higher bed temperature from the print file always wins.`,keepWarmMaxMinutes:`Stop keeping warm after (minutes)`,keepWarmMaxMinutesHelp:`If the plate is not cleared within this time, the heaters are switched off rather than held indefinitely.`,gcodeInjection:`G-code Injection`,gcodeInjectionDescription:`Configure custom G-code to inject at the start and/or end of prints for auto-print systems like Farmloop, SwapMod, AutoClear, and Printflow 3D. Snippets are configured per printer model and applied when "Inject G-code" is enabled on a queue item.`,gcodeInjectionNoPrinters:`No printers found. Add printers to configure G-code snippets.`,gcodeStartLabel:`Start G-code`,gcodeEndLabel:`End G-code`,gcodeStartPlaceholder:`G-code prepended before the print starts...`,gcodeEndPlaceholder:`G-code appended after the print ends...`,staggerGroupSize:`Group size`,staggerGroupSizeHelp:`Printers to start simultaneously per group`,staggerInterval:`Interval (minutes)`,staggerIntervalHelp:`Delay between each group starting`,queueDrying:`Queue Auto-Drying`,queueDryingDescription:`Automatically dry AMS filament when printer is idle between queued prints. Uses humidity threshold above to trigger drying.`,queueDryingEnabled:`Enable auto-drying`,queueDryingEnabledDescription:`Start AMS drying automatically when printer is idle and humidity is above threshold`,queueDryingBlock:`Wait for drying to complete`,queueDryingBlockDescription:`Block the print queue until drying finishes. When off, prints take priority over drying.`,ambientDryingEnabled:`Ambient drying`,ambientDryingEnabledDescription:`Automatically dry filament on idle printers when humidity exceeds threshold, even without queued prints.`,ambientDryingSustainedEnabled:`Require sustained humidity`,ambientDryingSustainedDescription:`Wait until humidity has stayed above the threshold for a set time before starting an ambient dry — rides out the spike from opening the AMS lid.`,ambientDryingSustainedMinutes:`Sustained time (minutes)`,printDryingEnabled:`Continue drying while printing`,printDryingEnabledDescription:`Allow auto-drying to keep running during a print on supported hardware (H2D, H2C, H2S, P2S, H2D Pro, X2D, X1C, A2L on recent firmware). Drying temperature is automatically capped 5°C below the idle preset to protect spools.`,dryingPresets:`Drying Presets`,dryingPresetsDescription:`Temperature and duration per filament type. AMS 2 Pro uses lower temps, AMS-HT supports higher temps.`,dryingFilament:`Filament`,humidityThresholds:`Humidity Thresholds`,humidityThresholdsDescription:`Per-filament humidity trigger for auto-drying and alarms. Mixed loads in one AMS use the lowest threshold.`,humidityThresholdCol:`Threshold`,humidityThresholdDefault:`Default (unknown types)`,printModal:`Print Modal`,expandCustomMapping:`Expand custom mapping by default`,expandCustomMappingDescription:`When printing to multiple printers, show per-printer AMS mapping expanded`,authentication:`Authentication`,authEnabledDescription:`Your instance is secured with user authentication`,authDisabledDescription:`Enable to require login and manage user access`,authDisabledMessage:`Enable authentication to create user accounts, manage permissions, and secure your Bambuddy instance.`,enableAuthentication:`Enable Authentication`,currentUser:`Current User`,changePassword:`Change Password`,admin:`Admin`,users:`Users`,addUser:`Add User`,groups:`Groups`,addGroup:`Add Group`,system:`System`,noDescription:`No description`,userCount:`{{count}} users`,permissionCount:`{{count}} permissions`,createUser:`Create User`,username:`Username`,enterUsername:`Enter username`,password:`Password`,enterPassword:`Enter password`,passwordRequirements:`At least 8 characters, with one uppercase, one lowercase, one digit, and one special character.`,confirmPassword:`Confirm Password`,confirmPasswordPlaceholder:`Confirm password`,viewReleaseOnGitHub:`View release on GitHub`,turnAllPlugsOn:`Turn all plugs on`,turnAllPlugsOff:`Turn all plugs off`,clearNotificationLogs:`Clear Notification Logs`,clearLogsMessage:`This will permanently delete all notification logs older than 30 days. This action cannot be undone.`,clearLogs:`Clear Logs`,resetUiPreferences:`Reset UI Preferences`,resetUiPreferencesMessage:`This will reset all UI preferences to defaults: sidebar order, theme, dashboard layout, view modes, and sorting preferences. Your printers, archives, and server settings will NOT be affected. The page will reload after clearing.`,resetPreferences:`Reset Preferences`,deleteGroupTitle:`Delete Group`,deleteGroupMessage:`Are you sure you want to delete this group? Users in this group will lose these permissions.`,deleteGroup:`Delete Group`,disableAuthenticationTitle:`Disable Authentication`,disableAuthenticationMessage:`Are you sure you want to disable authentication? This will make your Bambuddy instance accessible without login. All users will remain in the database but authentication will be disabled.`,disableAuthentication:`Disable Authentication`,configureBambuddy:`Configure Bambuddy`,systemDefault:`System Default`,archiveSettings:`Archive Settings`,newWindow:`New Window`,embeddedOverlay:`Embedded Overlay`,preferredSlicer:`Preferred Slicer`,preferredSlicerDescription:`Slicer used for in-app slicing via the API sidecar`,openInSlicerLabel:`Open in Slicer`,openInSlicerInherit:`Same as API slicer`,openInSlicerDescription:`Desktop slicer used by the 'Open in Slicer' button. Leave on 'Same as API slicer' to inherit, or pick a different slicer to use locally.`,orcaslicerKnownIssuesWarning:`OrcaSlicer 2.3.2 / 2.4.0-dev have known CLI bugs that block slicing many Bambu-authored 3MFs — see upstream issues #12426 (segfault on painted multi-extruder files) and #13386 (parameter-range strict-validation reject). Bambu Studio is recommended until the upstream fixes land.`,useSlicerApi:`Use Slicer API`,useSlicerApiDescription:`When on, "Slice" actions open the in-app slicer modal and call the slicer-API sidecar. When off (default), they hand off to the desktop slicer via URI scheme.`,slicerCard:`Slicer`,orcaslicerApiUrl:`OrcaSlicer sidecar URL`,bambuStudioApiUrl:`Bambu Studio sidecar URL`,slicerStallTimeout:`Slicer stall timeout (minutes)`,slicerStallTimeoutDescription:`Give up on a slice after this long with no progress from the sidecar. Heavy models that keep reporting progress are never cut off, however long they take. Sidecars that do not report progress use this as a total time limit instead.`,slicerApiUrlDescription:`URL of the slicer-API sidecar container. Leave blank to use the SLICER_API_URL / BAMBU_STUDIO_API_URL env var defaults.`,externalCameras:`External Cameras`,costTracking:`Cost Tracking`,billingEnabled:`Enable Billing`,billingEnabledDescription:`Charge users for prints and enable finance features`,printerKillSwitch:`Unauthorized print kill switch`,printerKillSwitchDescription:`Immediately stop prints that start without authorization.`,financeBudgetReset:`Finance Monthly Budget Reset`,financeBudgetResetDay:`Reset Day`,financeBudgetResetDayHelp:`For short months, reset uses the last day of the month.`,financeBudgetResetTimezone:`Reset timezone`,financeBudgetResetTimezoneHelp:`Budget window start is calculated in this timezone.")`,rebuildLedger:`Rebuild wallet ledger`,rebuildLedgerStarted:`Ledger rebuild started`,rebuildLedgerConfirmTitle:`Rebuild wallet ledger?`,rebuildLedgerConfirmMessage:`This will rebuild the wallet ledger to repair historical balance values. Run this only if you know what you are doing.`,rebuildLedgerInProgress:`Starting rebuild...`,printsOnly:`Prints Only`,totalConsumption:`Total Consumption`,dataManagement:`Data Management`,storageUsage:`Storage Usage`,storageUsageDescription:`Breakdown of data usage by category`,storageUsageTotal:`Total`,storageUsageErrors:`Errors`,storageUsageOtherBreakdown:`Other (includes static assets, scripts, and configuration files)`,storageUsageSystem:`System`,storageUsageData:`Data`,storageUsageUnavailable:`Storage usage information unavailable`,clearNotificationLogsDescription:`Delete notification logs older than 30 days`,resetUiPreferencesDescription:`Reset sidebar order, theme, view modes, and layout preferences. Printers, archives, and settings are not affected.`,enableHomeAssistant:`Enable Home Assistant`,enableMqtt:`Enable MQTT`,useTls:`Use TLS`,enableMetricsEndpoint:`Enable Metrics Endpoint`,availableMetrics:`Available Metrics`,editUser:`Edit User`,deleteUserTitle:`Delete User`,groupName:`Group Name`,leaveEmptyForAnonymous:`Leave empty for anonymous`,leaveEmptyForNoAuth:`Leave empty for no authentication`,enterNewPassword:`Enter new password`,confirmNewPassword:`Confirm new password`,enterGroupName:`Enter group name`,enterDescriptionOptional:`Enter description (optional)`,enterCurrentPassword:`Enter current password`,enterNewPasswordMin6:`Enter new password (min 6 characters)`,toast:{keyCopied:`Key copied to clipboard`,copyFailed:`Failed to copy key`,keyAddedToBrowser:`Key added to API Browser`,clearLogsFailed:`Failed to clear logs`,uiPreferencesReset:`UI preferences reset. Refreshing...`,authDisabled:`Authentication disabled successfully`,authDisableFailed:`Failed to disable authentication`,apiKeyCreated:`API key created`,apiKeyDeleted:`API key deleted`,userCreated:`User created successfully`,userUpdated:`User updated successfully`,userDeleted:`User deleted successfully`,groupCreated:`Group created successfully`,groupUpdated:`Group updated successfully`,groupDeleted:`Group deleted successfully`,fillRequiredFields:`Please fill in all required fields`,passwordsDoNotMatch:`Passwords do not match`,passwordTooShort:`Password must be at least 8 characters`,passwordNeedsUppercase:`Password must contain at least one uppercase letter`,passwordNeedsLowercase:`Password must contain at least one lowercase letter`,passwordNeedsDigit:`Password must contain at least one digit`,passwordNeedsSpecial:`Password must contain at least one special character`,enterGroupName:`Please enter a group name`,settingsSaved:`Settings saved`,noPermissionUpdate:`You do not have permission to change settings`,cameraSettingsSaved:`Camera settings saved`,enterCameraUrl:`Please enter a camera URL`,passwordChanged:`Password changed successfully`,connectionFailed:`Connection failed`,testFailed:`Test failed`,cameraConnected:`Camera connected{{resolution}}`,cameraConnectedCoalesced:`Camera connected{{resolution}} (shared with a capture already running)`},testConnection:`Test Connection`,catalog:{spoolCatalog:`Spool Catalog`,spoolCatalogDescription:`Empty spool weights by brand/type. Used for automatic weight lookup when adding spools.`,searchCatalog:`Search catalog...`,addNewEntry:`Add New Entry`,namePlaceholder:`Name (e.g., Bambu Lab - Plastic)`,weight:`Weight`,type:`Type`,default:`Default`,custom:`Custom`,noMatch:`No entries match your search`,empty:`No entries in catalog`,deleteEntry:`Delete Entry`,deleteConfirm:`Are you sure you want to delete "{{name}}"?`,resetCatalog:`Reset Catalog`,resetConfirm:`Reset catalog to defaults? This will remove all custom entries.`,loadFailed:`Failed to load spool catalog`,nameWeightRequired:`Name and weight are required`,entryAdded:`Entry added`,addFailed:`Failed to add entry`,entryUpdated:`Entry updated`,updateFailed:`Failed to update entry`,entryDeleted:`Entry deleted`,deleteFailed:`Failed to delete entry`,resetSuccess:`Catalog reset to defaults`,resetFailed:`Failed to reset catalog`,exported:`Exported {{count}} entries`,imported:`Imported {{added}} entries ({{skipped}} skipped)`,importFailed:`Failed to import: invalid JSON format`,exportTooltip:`Export catalog to JSON`,importTooltip:`Import catalog from JSON`,resetTooltip:`Reset to defaults`,selectedCount:`{{count}} selected`,deleteSelected:`Delete Selected`,bulkDeleteConfirm:`Are you sure you want to delete {{count}} entries?`,bulkDeleted:`Deleted {{count}} entries`,bulkDeleteFailed:`Failed to delete entries`,material:`Material`,spoolWeight:`Spool Weight`,color:`Color`,updateSpoolWeight:`Update Spool Weight`,filamentUpdated:`Filament updated`,filamentUpdateFailed:`Failed to update filament`,filamentUpdateInvalid:`Invalid filament data`,keepExistingSpoolWeight:`Keep old weight for existing spools`,keepExistingSpoolWeightDesc:`Spools already created with this filament type retain the old tare weight. New spools use the updated value.`,applyToAllSpools:`Apply to all spools`,applyToAllSpoolsDesc:`All weight calculations for this filament type immediately use the new tare weight.`},colorCatalog:{title:`Color Catalog`,description:`Filament colors by manufacturer/material. Used for automatic color lookup when adding spools.`,searchColors:`Search colors...`,allManufacturers:`All manufacturers`,addNewColor:`Add New Color`,manufacturer:`Manufacturer`,colorName:`Color Name`,hex:`Hex`,materialOptional:`Material (optional)`,showing:`Showing {{filtered}} of {{total}} colors`,noMatch:`No colors match your search`,empty:`No colors in catalog`,deleteColor:`Delete Color`,deleteConfirm:`Are you sure you want to delete "{{name}}"?`,resetCatalog:`Reset Color Catalog`,resetConfirm:`Reset catalog to defaults? This will remove all custom colors.`,sync:`Sync`,starting:`Starting...`,syncTooltip:`Sync from FilamentColors.xyz (2000+ colors, may take a minute)`,loadFailed:`Failed to load color catalog`,fieldsRequired:`Manufacturer, color name, and hex color are required`,colorAdded:`Color added`,addFailed:`Failed to add color`,colorUpdated:`Color updated`,updateFailed:`Failed to update color`,colorDeleted:`Color deleted`,deleteFailed:`Failed to delete color`,resetSuccess:`Color catalog reset to defaults`,resetFailed:`Failed to reset catalog`,syncUpToDate:`Already up to date ({{count}} colors checked)`,syncComplete:`Added {{added}} new colors ({{skipped}} already existed)`,syncError:`Sync error`,syncFailed:`Failed to sync from FilamentColors.xyz`,exported:`Exported {{count}} colors`,imported:`Imported {{added}} colors ({{skipped}} skipped)`,importFailed:`Failed to import: invalid JSON format`,selectedCount:`{{count}} selected`,deleteSelected:`Delete Selected`,bulkDeleteConfirm:`Are you sure you want to delete {{count}} colors?`,bulkDeleted:`Deleted {{count}} colors`,bulkDeleteFailed:`Failed to delete colors`},dateFormat:`Date Format`,dateFormatUs:`US (MM/DD/YYYY)`,dateFormatEu:`EU (DD/MM/YYYY)`,dateFormatIso:`ISO (YYYY-MM-DD)`,timeFormat:`Time Format`,timeFormat12:`12-hour (3:30 PM)`,timeFormat24:`24-hour (15:30)`,defaultPrinter:`Default Printer`,defaultPrinterDescription:`Pre-select this printer for uploads, reprints, and other operations.`,slicerBambuStudio:`Bambu Studio`,slicerOrcaSlicer:`OrcaSlicer`,sidebarOrderDescription:`Use Sidebar to reorder items, reset visibility, and manage custom links.`,setDefault:`Set Default`,sidebarOrderSetDefaultHint:`Set default applies the current menu order to users who haven't customized theirs.`,sidebarDefaultSet:`Default menu order has been set.`,sidebarDefaultCleared:`Default menu order cleared.`,sidebarDefaultFailed:`Failed to set default menu order.`,reset:`Reset`,darkMode:`Dark Mode`,lightMode:`Light Mode`,active:`(active)`,background:`Background`,accent:`Accent`,style:`Style`,bgNeutral:`Neutral`,bgWarm:`Warm`,bgCool:`Cool`,bgOled:`OLED Black`,bgSlate:`Slate Blue`,bgForest:`Forest Green`,accentGreen:`Green`,accentTeal:`Teal`,accentBlue:`Blue`,accentOrange:`Orange`,accentPurple:`Purple`,accentRed:`Red`,styleClassic:`Classic`,styleGlow:`Glow`,styleVibrant:`Vibrant`,themeToggleHint:`Toggle between dark, light, and system mode using the icon in the sidebar.`,progressInTitle:`Print progress in tab`,progressInTitleDescription:`Show the active print's percentage and a progress ring in the browser tab.`,autoArchivePrints:`Auto-archive prints`,autoArchiveDescription:`Automatically save 3MF files when prints complete`,saveThumbnailsDescription:`Extract and save preview images from 3MF files`,captureFinishPhotoDescription:`Take a photo from printer camera when print completes. Bambuddy records a brief timelapse during the print so the photo can be sourced from the moment before the bed drops; the timelapse file is kept if you enabled timelapse for this print, otherwise it is deleted automatically after the photo is captured.`,finishPhotoRestorePlate:`Restore plate for finish photo`,finishPhotoRestorePlateDescription:`The printer drops the build plate about 100 mm when a print ends, leaving the finished print below the camera's framing. Bambuddy raises it back to just above the last printed layer, takes the photo, then lowers it again. Skipped when the print height is unknown or another job is queued.`,ffmpegNotInstalled:`ffmpeg not installed`,ffmpegRequired:`Camera capture requires ffmpeg. Install it via <brew>brew install ffmpeg</brew> (macOS) or <apt>apt install ffmpeg</apt> (Linux).`,camera:`Camera`,cameraViewMode:`Camera View Mode`,cameraOverlayDescription:`Camera opens in a resizable overlay on the main screen`,cameraWindowDescription:`Camera opens in a separate browser window`,externalCamerasDescription:`Configure external cameras to replace the built-in printer camera. Supports MJPEG streams, RTSP, HTTP snapshots, and USB cameras (V4L2). When enabled, the external camera is used for live view and finish photos.`,cameraPlaceholderUsb:`Device path (/dev/video0)`,cameraPlaceholderUrl:`Camera URL (rtsp://... or http://...)`,cameraTypeMjpeg:`MJPEG Stream`,cameraTypeRtsp:`RTSP Stream`,cameraTypeSnapshot:`HTTP Snapshot`,cameraTypeUsb:`USB Camera (V4L2)`,cameraSnapshotUrl:`Snapshot URL (optional)`,cameraSnapshotUrlPlaceholder:`http://192.168.1.61:1984/api/frame.jpeg?src=printer`,cameraSnapshotUrlHelp:`Single-frame URL used for notification thumbnails, finish photos, layer-timelapse frames, and plate detection. Timelapse and plate detection each require their own per-printer toggle — this URL is just the image source they pull from when active. Leave blank to capture from the live stream above. Useful for go2rtc (/api/frame.jpeg) and IP cameras with a dedicated snapshot endpoint.`,cameraRotation:`Rotation`,cameraLight:`Turn on chamber light for camera`,cameraLightHint:`Turns the light on while someone watches the camera and for automatic snapshots such as notification photos, finish photos and Home Assistant pictures. Turns it off again afterwards, but only if Bambuddy turned it on.`,cameraLightDelay:`Wait before snapshot`,cameraLightDelayHint:`Only when the light was off. Gives the light, and any light synced to it, time to come on.`,cameraLightMode_off:`Off`,cameraLightMode_all:`All printers`,cameraLightMode_selected:`Selected printers`,cameraLightDelayUnit:`seconds`,cameraLightNoneSelected:`No printer picked yet.`,cameraLightAddPrinter:`Add printer`,cameraLightRemovePrinter:`Remove {{name}}`,externalCameraAdd:`Add external camera`,externalCameraRemove:`Remove the external camera from {{name}}`,printerPickerSearch:`Search printers`,printerPickerNoMatch:`No printer matches.`,cameraShowSettings:`Camera settings`,test:`Test`,connected:`Connected`,disconnected:`Disconnected`,currency:`Currency`,defaultFilamentCost:`Default filament cost (per kg)`,electricityCost:`Electricity cost per kWh`,energyPriceSource:`Electricity price source`,energyPriceSourceFixed:`Fixed price`,energyPriceSourceHomeAssistant:`Home Assistant sensor`,energyPriceHaEntity:`Price sensor`,energyPriceLastRead:`Last price read per kWh`,energyPriceFixedHint:`A new price applies to the energy used from then on; energy already used keeps the price it was used at.`,energyPriceHaHint:`Read every hour and at the start and end of each print, and each hour of energy is costed at its own price. The sensor must give the price per kWh (per MWh and per Wh are converted).`,energyPriceHaNotConfigured:`Home Assistant is not set up. Connect it under Settings → Network → Home Assistant.`,energyDisplayMode:`Energy display mode`,energyModePrintDescription:`Dashboard shows sum of energy used during prints`,energyModeTotalDescription:`Dashboard shows lifetime energy from smart plugs`,fileManager:`File Manager`,createArchiveEntry:`Create Archive Entry When Printing`,createArchiveEntryDescription:`When printing from File Manager, optionally create an archive entry`,lowDiskSpaceWarning:`Low Disk Space Warning`,lowDiskSpaceDescription:`Show warning when free disk space falls below this threshold`,printerFirmware:`Printer Firmware`,checkFirmwareDescription:`Check for printer firmware updates from Bambu Lab`,bambuddySoftware:`Bambuddy Software`,autoCheckDescription:`Automatically check for new versions on startup`,checkNow:`Check now`,updateAvailableVersion:`Update available: v{{version}}`,releaseNotes:`Release Notes`,updateViaDocker:`Update via Docker Compose:`,composeDirectory:`Compose directory`,composeDirectoryHint:`Directory containing your docker-compose.yml. Leave blank to omit the cd.`,copyUpdateCommand:`Copy update command`,updateViaHomeAssistant:`Updates are managed by the Home Assistant Supervisor. Open Settings → Add-ons → Bambuddy in Home Assistant to install the new version.`,updateViaWindowsInstaller:`Windows installations are updated by re-running the installer. Download the new version below — your data, settings and printers are preserved.`,downloadWindowsInstaller:`Download installer for v{{version}}`,installUpdate:`Install Update`,latestVersionRunning:`You're running the latest version`,failedToCheckUpdates:`Failed to check for updates: {{error}}`,backupRestore:`Backup & Restore`,backupRestoreDescription:`Export/import settings and configure GitHub backup`,goToBackup:`Go to Backup`,externalUrl:`External URL`,externalUrlDescription:`The external URL where Bambuddy is accessible. Used for notification images and external integrations.`,bambuddyUrl:`Bambuddy URL`,externalUrlHint:`Include protocol and port (e.g., http://192.168.1.100:8000)`,ftpRetry:`FTP Retry`,ftpRetryDescription:`Retry FTP operations when printer WiFi is unreliable. Applies to 3MF downloads, print uploads, timelapse downloads, and firmware updates.`,autoRetryDescription:`Automatically retry failed FTP operations`,retryAttempts:`Retry attempts`,retryDelay:`Retry delay`,connectionTimeout:`Connection timeout`,time_one:`{{count}} time`,time_other:`{{count}} times`,second_one:`{{count}} second`,second_other:`{{count}} seconds`,nSeconds:`{{count}} seconds`,increaseForWeakWifi:`Increase for printers with weak WiFi`,homeAssistant:`Home Assistant`,homeAssistantFullDescription:`Connect to Home Assistant to control smart plugs via HA's REST API. Supports switch, light, input_boolean, and script entities.`,homeAssistantUrl:`Home Assistant URL`,longLivedAccessToken:`Long-Lived Access Token`,haTokenHint:`Create a token in HA: Profile → Long-Lived Access Tokens → Create Token`,connectionSuccessful:`Connection Successful`,connectionFailed:`Connection Failed`,haConnectionSuccess:`Successfully connected to Home Assistant.`,haConnectionFailed:`Failed to connect to Home Assistant.`,mqttPublishing:`MQTT Publishing`,mqttDescription:`Publish BamBuddy events to an external MQTT broker for integration with Node-RED, Home Assistant, and other automation systems.`,mqttEnableDescription:`Publish events to external MQTT broker`,brokerHostname:`Broker hostname`,port:`Port`,usernameOptional:`Username (optional)`,passwordOptional:`Password (optional)`,topicPrefix:`Topic prefix`,topicPrefixHint:`Topics will be: {{prefix}}/printers/<serial>/status, etc.`,prometheusMetrics:`Prometheus Metrics`,prometheusEndpointDescription:`Expose printer metrics at <code>/api/v1/metrics</code> for Prometheus/Grafana monitoring.`,bearerTokenOptional:`Bearer Token (optional)`,bearerTokenHint:`If set, requests must include <code>Authorization: Bearer <token></code>`,metricsConnectionStatus:`Connection status`,metricsPrinterState:`Printer state (idle/printing/etc)`,metricsPrintProgress:`Print progress 0-100%`,metricsBedTemp:`Bed temperature`,metricsNozzleTemp:`Nozzle temperature`,metricsPrintsTotal:`Total prints by result`,metricsMore:`...and more (layers, fans, queue, filament usage)`,smartPlugsDescription:`Connect smart plugs (Tasmota or Home Assistant) to automate power control and track energy usage for your printers.`,allOn:`All On`,allOff:`All Off`,addSmartPlug:`Add Smart Plug`,energySummary:`Energy Summary`,currentPower:`Current Power`,plugsOnline:`{{reachable}}/{{total}} plugs online`,today:`Today`,yesterday:`Yesterday`,total:`Total`,enablePlugsForSummary:`Enable plugs to see energy summary`,addNotificationProvider:`Add`,systemBadge:`(System)`,creating:`Creating...`,changing:`Changing...`,deleteUserAndItems:`Delete user AND their items`,deleteUserKeepItems:`Delete user, keep items (become ownerless)`,ok:`OK`,twoFa:{totpTitle:`Authenticator App (TOTP)`,totpDesc:`Use an authenticator app like Google Authenticator, Aegis or Authy.`,emailOtpTitle:`Email OTP`,emailOtpDesc:`Send a one-time code to {{email}} when you log in.`,emailOtpNoEmail:`Add an email address to your account to enable this method.`,addEmailFirst:`Your account has no email address. Ask an admin to add one before enabling Email OTP.`,setupTotp:`Set up Authenticator App`,setupAuthApp:`Set up Authenticator App`,setupInstructions:`Scan the QR code below with your authenticator app, then confirm with a code.`,manualEntry:`Can't scan? Enter this secret manually:`,scannedContinue:`I've scanned the code — continue`,enterCodeToConfirm:`Enter the 6-digit code from your authenticator app to confirm setup.`,activate:`Activate`,disableTotp:`Disable Authenticator`,disableConfirmHint:`Enter a valid TOTP code or a backup code to disable the authenticator.`,totpDisabled:`Authenticator app disabled.`,emailOtpEnabled:`Email OTP enabled.`,emailOtpDisabled:`Email OTP disabled.`,smtpRequired:`Please configure and test SMTP settings first.`,invalidCode:`Invalid code. Please try again.`,enableEmailOtp:`Enable Email OTP`,disableEmailOtp:`Disable Email OTP`,emailSetupEnterCode:`A verification code has been sent to your email address. Enter it below to confirm you own this inbox.`,verifyAndEnable:`Verify & Enable`,emailDisablePasswordHint:`Enter your account password to confirm disabling email OTP.`,passwordPlaceholder:`Enter your password`,backupCodesTitle:`Save your backup codes`,backupCodesWarning:`Save these codes somewhere safe. Each code can only be used once and they will not be shown again.`,backupCodesRemaining:`{{count}} backup codes remaining`,savedCodes:`I've saved my codes`,regenBackup:`Regenerate Backup Codes`,regenBackupHint:`Enter your current TOTP code to generate 10 new backup codes. All existing backup codes will be invalidated.`,newBackupCodes:`New backup codes`,linkedAccounts:`Linked SSO Accounts`,linkedAccountsDesc:`These external identity providers are linked to your account.`,oidcUnlinked:`Account unlinked.`},sessionPolicy:{title:`Session Policy`,description:`Maximum session lifetime for new user logins. Already-issued tokens keep their original expiry.`,preset24h:`24 hours`,preset7d:`7 days`,preset30d:`30 days`,customHoursLabel:`Custom session lifetime in hours`,hoursSuffix:`hours`,warning:`Longer sessions reduce automatic logout protection. Recommended only for trusted single-user deployments.`},oidc:{title:`SSO / OIDC Providers`,desc:`Configure OpenID Connect providers to allow single sign-on via external identity providers.`,addProvider:`Add Provider`,newProvider:`New Provider`,empty:`No OIDC providers configured yet.`,created:`Provider created.`,updated:`Provider updated.`,deleted:`Provider deleted.`,refreshIcon:`Refresh icon`,removeIcon:`Remove icon`,iconRefreshed:`Icon refreshed.`,iconRemoved:`Icon removed.`,iconFetchFailed:`Icon could not be fetched from the provider URL.`,deleteTitle:`Delete Provider`,deleteMessage:`Delete "{{name}}"? All linked user accounts will be disconnected.`,form:{name:`Display Name`,issuerUrl:`Issuer URL`,clientId:`Client ID`,clientSecret:`Client Secret`,scopes:`Scopes`,iconUrl:`Icon URL (optional)`,enabled:`Enabled`,autoCreate:`Auto-create users`,autoCreateDesc:`Automatically create a local account on first login.`,autoLink:`Auto-link existing accounts`,autoLinkDesc:`Link existing local accounts by matching email on first login.`,secretHint:`leave blank to keep current`,secretPlaceholder:`new secret`,emailClaim:`Email Claim`,emailClaimDesc:`JWT claim used as email identity. Use 'preferred_username' or 'upn' for Azure Entra ID (which does not send email_verified). Only use trusted claim names.`,emailClaimPlaceholder:`email`,emailClaimCustomClaimAutoLinkWarning:`Custom claims are safe for auto-link only when the value is tenant-administered (e.g. Azure Entra ID upn / preferred_username). Do not enable auto-link if your IdP allows users to self-assert this claim.`,requireEmailVerified:`Require email verified`,requireEmailVerifiedDesc:`Only accept the email claim when the provider marks it as verified.`,requireEmailVerifiedWarning:`Warning: email will be accepted even without verification. Use only with trusted providers.`,requireEmailVerifiedAutoLink:`Disable auto-link first to change this setting.`,defaultGroup:`Default Group`,defaultGroupDesc:`Group assigned to auto-created users. Falls back to Viewers if not set.`,defaultGroupViewersFallback:`Viewers (default)`,autologin:`Autologin`,autologinDesc:`Redirect unauthenticated visitors straight to this provider. Only one provider can carry this flag.`,groupClaim:`Group Claim`,groupClaimDesc:`JWT claim that holds the user's groups at the identity provider. Most providers use 'groups'; values can be a JSON array or a string.`,groupMapping:`Group Mapping`,groupMappingDesc:`Mapped groups are synced on every login. Groups not named here are left untouched, so manual assignments survive. Leave empty to disable group sync.`,groupMappingIdpGroupPlaceholder:`Identity provider group name`,groupMappingSelectGroup:`Select Bambuddy group…`,groupMappingAddRow:`Add Mapping`,groupMappingDeletedGroupOption:`{{group}} (deleted)`,groupMappingDeletedGroupWarning:`This Bambuddy group has been deleted. Pick a replacement or remove this mapping.`,groupMappingIncompleteRow:`Enter the identity provider group and pick a Bambuddy group, or remove this mapping.`,groupMappingDuplicateRow:`This identity provider group is already mapped above. Group names are compared ignoring case.`,groupSync:`Group Sync`,groupSyncOn:`On`}},encryption:{title:`MFA Encryption Status`,enabledFromEnv:`At-rest encryption enabled (key from MFA_ENCRYPTION_KEY environment variable)`,enabledFromFile:`At-rest encryption enabled (key loaded from data directory)`,enabledGenerated:`At-rest encryption enabled with auto-generated key`,notConfigured:`At-rest encryption not configured`,notConfiguredDesc:`TOTP secrets and OIDC client_secrets are stored in plaintext. Set MFA_ENCRYPTION_KEY or restart Bambuddy with a writable data directory to auto-generate one.`,allEncrypted:`All MFA secrets are encrypted at rest.`,legacyRowsLabel:`Legacy plaintext rows`,encryptedRowsLabel:`Encrypted rows`,legacyRowsWarning:`{{count}} legacy plaintext row(s) detected. Re-save the OIDC provider or re-enroll the user’s authenticator app to migrate to encrypted storage.`,backupHint:`The auto-generated key is stored at DATA_DIR/.mfa_encryption_key and is included in local backup ZIPs. Keep your backups secure or set MFA_ENCRYPTION_KEY explicitly.`,decryptionBrokenTitle:`Encryption key missing`,decryptionBrokenError:`{{count}} encrypted record(s) cannot be decrypted because the encryption key is no longer available. Restore the previous MFA_ENCRYPTION_KEY or DATA_DIR/.mfa_encryption_key to recover.`,migrationErrorWarning:`{{count}} legacy row(s) failed to re-encrypt at startup. Check server logs and restart Bambuddy to retry.`},pipelineLimits:{title:`Slicer Pipeline limits`,maxCopiesLabel:`Max copies per run`,maxCopiesDesc:`Upper bound on the copies operators can request when running a pipeline. Server-side hard cap is 1000.`},pipelines:{title:`Slicer Pipelines`,subtitle:`Reusable preset bundles (printer + process + filaments + bed type). Save one from the Slice dialog and apply it with a single click on the next file.`,loading:`Loading pipelines…`,loadError:`Could not load pipelines.`,confirmDelete:`Delete this pipeline? This cannot be undone.`,staleWarning:`One or more referenced presets no longer exist. Re-save this pipeline from the Slice dialog to fix.`,empty:{title:`No pipelines yet.`,howto:`Open the Slice dialog for any file, pick your printer / process / filaments / bed type, then click "Save as pipeline". Your saved pipelines will appear here.`},field:{name:`Pipeline name`,description:`Description`,targetPrinter:`Target printer`,noTarget:`— No target —`,targetKind:`Target type`,targetKindSpecific:`Specific printer`,targetKindClass:`Printer class`,targetModelClass:`Printer model`,fanoutStrategy:`Fanout strategy`,fanout:{max_parallel:`Max parallel — distribute across any idle matching printer`,round_robin:`Round robin — cycle through eligible printers`,fill_one_first:`Fill one first — pin all copies to one printer`},fanoutShort:{max_parallel:`parallel`,round_robin:`round robin`,fill_one_first:`fill one first`}},action:{save:`Save`,cancel:`Cancel`,rename:`Rename`,delete:`Delete`},slot:{printer:`Printer`,process:`Process`,filament:`Filament`,filamentN:`Filament {{n}}`,filamentAll:`All {{n}} slots`,bed:`Bed`},group:{profiles:`Profiles`,filaments:`Filaments`},searchPlaceholder:`Search pipelines…`,filterTargetType:`Filter by target type`,filterTarget:`Filter by target`,filter:{all:`All targets`,noTarget:`No target set`,count:`{{shown}} / {{total}}`,noMatches:`No pipelines match the current filters.`},toast:{saved:`Pipeline saved`,saveFailed:`Save failed`,deleted:`Pipeline deleted`,deleteFailed:`Delete failed`},noTargetHint:`Set a target printer to run this`,noTargetWarning:`Set a target printer before running this pipeline.`,runs:{lastRun:`Last run`,status:{queued:`queued`,slicing:`slicing`,dispatching:`dispatching`,in_progress:`printing`,completed:`completed`,failed:`failed`,partial_failure:`partial failure`,cancelled:`cancelled`}}}},notification:{printStarted:{title:`Print Started`,body:`{{printer}}: {{filename}} has started printing`},printCompleted:{title:`Print Completed`,body:`{{printer}}: {{filename}} completed successfully`},printFailed:{title:`Print Failed`,body:`{{printer}}: {{filename}} has failed`},printStopped:{title:`Print Stopped`,body:`{{printer}}: {{filename}} was stopped`},printProgress:{title:`Print Progress`,body:`{{printer}}: {{filename}} is {{percent}}% complete`},printerOffline:{title:`Printer Offline`,body:`{{printer}} is offline`},printerError:{title:`Printer Error`,body:`{{printer}}: {{error}}`},filamentLow:{title:`Low Filament`,body:`{{printer}}: Filament is running low`},maintenanceDue:{title:`Maintenance Due`,body:`{{printer}}: {{items}} need attention`}},errors:{generic:`Something went wrong`,networkError:`Network error. Please check your connection.`,notFound:`Not found`,unauthorized:`Unauthorized`,serverError:`Server error`,validationError:`Please check your input`,printerConnectionFailed:`Failed to connect to printer`,saveFailed:`Failed to save changes`,deleteFailed:`Failed to delete`,loadFailed:`Failed to load data`},hmsErrors:{title:`Errors - {{name}}`,noErrors:`No errors`,viewOnWiki:`View on Bambu Lab Wiki`,mqttVerifyFailedRemedy:`Enable Developer Mode on the printer, restart the printer, then start the job again.`,mqttVerifyFailedDescription:`The printer rejected a command because it could not verify it. Prints, temperature changes and filament loads sent from Bambuddy will be ignored until this is fixed.`,severityError:`Error`,severityWarning:`Warning`,severityNotice:`Notice`,severityUnknown:`Unknown level`,uncountedSummary:`Also reported, not counted ({{n}})`,uncountedHint:`Notices that don't need you, and codes Bambu publishes no text for. They don't count as problems on the printer card and don't send notifications.`,unknownCode:`Unknown HMS code — see the Bambu Lab wiki for details.`,clearInstructions:`Clear errors on the printer to dismiss them here.`,clearErrors:`Clear Errors`,clearSuccess:`HMS errors cleared`,clearFailed:`Failed to clear HMS errors`,actionSuccess:`Action sent to printer`,actionFailed:`Failed to send action`,runoutExpectedSlot:`Filament ran out in {{ranOut}}. The printer is now waiting for compatible filament in {{expected}}. Insert a spool into {{expected}}, then select Retry.`,runoutExpectedSlotOnly:`The printer is waiting for compatible filament in {{expected}}. Insert a spool there, then select Retry.`,runoutSlotUnknown:`Filament ran out and the print is paused. Bambuddy could not determine which slot the printer now expects — check the printer screen for the requested slot.`,actions:{RESUME_PRINTING:`Resume Printing`,RESUME_PRINTING_DEFECTS:`Resume (defects acceptable)`,RESUME_PRINTING_PROBELM_SOLVED:`Resume (problem solved)`,STOP_PRINTING:`Stop Printing`,CHECK_ASSISTANT:`Check Assistant`,FILAMENT_EXTRUDED:`Filament Extruded, Continue`,RETRY_FILAMENT_EXTRUDED:`Not Extruded Yet, Retry`,CONTINUE:`Finished, Continue`,LOAD_VIRTUAL_TRAY:`Load Filament`,OK_BUTTON:`OK`,FILAMENT_LOAD_RESUME:`Filament Loaded, Resume`,JUMP_TO_LIVEVIEW:`View Liveview`,NO_REMINDER_NEXT_TIME:`No Reminder Next Time`,REFRESH_NOZZLE:`Recheck`,IGNORE_NO_REMINDER_NEXT_TIME:`Ignore. Don't Remind Next Time`,IGNORE_RESUME:`Ignore this and Resume`,PROBLEM_SOLVED_RESUME:`Problem Solved and Resume`,TURN_OFF_FIRE_ALARM:`Got it, Turn off the Fire Alarm.`,RETRY_PROBLEM_SOLVED:`Retry (problem solved)`,CANCLE:`Cancle`,STOP_DRYING:`Stop Drying`,PROCEED:`Proceed`,OK_JUMP_RACK:`OK`,ABORT:`Abort`,DISABLE_PURIFICATION:`Disable Purification for This Print`,DONT_REMIND_NEXT_TIME:`Don't Remind Me`,DBL_CHECK_CANCEL:`Cancel`,DBL_CHECK_DONE:`Done`,DBL_CHECK_RETRY:`Retry`,DBL_CHECK_RESUME:`Resume`,DBL_CHECK_OK:`Confirm`,REMOVE_CLOSE_BTN:`Close`}},mqttDebug:{title:`MQTT Debug Log`,searchPlaceholder:`Search topic or payload...`,noMessages:`No messages logged yet`,startLoggingHint:`Click "Start Logging" to begin capturing MQTT messages`,noMessagesMatch:`No messages match your filter`,adjustFilterHint:`Try adjusting your search or filter criteria`,incoming:`Incoming`,outgoing:`Outgoing`,loggingStopped:`Logging stopped`,loggingActive:`Logging active - messages will auto-refresh`,startLogging:`Start Logging`,stopLogging:`Stop Logging`,clearLog:`Clear Log`,topic:`Topic`,timestamp:`Timestamp`,direction:`Direction`,all:`All`},printerFiles:{zipStarted_one:`Started ZIP download for {{count}} file`,zipStarted_other:`Started ZIP download for {{count}} files`,zipPartial:`ZIP download started with {{successful}} of {{total}} files; the rest could not be retrieved`,downloadFailed:`Download failed: {{error}}`,unknownError:`Unknown error`,shiftSelectHint:`Shift-click to select a range`,selectFile:`Select {{name}}`,deselectFile:`Deselect {{name}}`,title:`File Manager`,storageUsed:`Used:`,storageFree:`Free:`,filterPlaceholder:`Filter files...`,deleteButton:`Delete`,deleteFiles:`Delete {{count}} Files`,deleteFileConfirm:`Delete "{{name}}"? This cannot be undone.`,deleteFilesConfirm:`Delete {{count}} selected files? This cannot be undone.`,noFiles:`No files on printer`,printerUnavailable:`The printer file service is unavailable. Try again when the printer is reachable.`,loadingFiles:`Loading files...`,failedToLoad:`Failed to load files`,toast:{filesDeleted:`Deleted {{count}} file(s)`,deleteFailed:`Delete failed: {{error}}`}},confirm:{delete:`Are you sure you want to delete this?`,unsavedChanges:`You have unsaved changes. Are you sure you want to leave?`,clearQueue:`Are you sure you want to clear the queue?`},login:{title:`Bambuddy Login`,subtitle:`Sign in to your account`,username:`Username`,usernamePlaceholder:`Enter your username`,usernameOrEmail:`Username or Email`,usernameOrEmailPlaceholder:`Username or @ Email`,password:`Password`,passwordPlaceholder:`Enter your password`,signIn:`Sign in`,signingIn:`Logging in...`,rememberMe:`Remember Me`,forgotPassword:`Forgot your password?`,autologinFailed:`Automatic SSO sign-in failed. Pick a provider below to continue.`,localDisabledNotice:`Local sign-in is disabled. Use one of the SSO providers below.`,loginSuccess:`Logged in successfully`,loginFailed:`Login failed`,enterCredentials:`Please enter username and password`,enterEmail:`Please enter your email address`,oidcLoginFailed:`OIDC login failed`,oidcErrors:{providerError:`The identity provider returned an error`,missingParameters:`OIDC callback is missing required parameters`,invalidState:`OIDC state is invalid or has already been used`,stateExpired:`OIDC login session expired — please try again`,providerNotFound:`OIDC provider not found`,discoveryFailed:`Failed to fetch OIDC discovery document`,invalidDiscovery:`OIDC discovery document is invalid`,networkError:`Network error during OIDC token exchange`,badResponse:`Unexpected response during OIDC token exchange`,noIdToken:`OIDC provider did not return an ID token`,validationFailed:`OIDC token validation failed`,nonceMismatch:`OIDC nonce mismatch — possible replay attack`,missingSubClaim:`OIDC token is missing the sub claim`,noLinkedAccount:`No local account is linked to this OIDC identity`,accountInactive:`Your account is inactive`,userResolutionFailed:`Failed to resolve your account`,internalError:`An internal error occurred during OIDC login`,tokenExchangeFailed:`OIDC token exchange failed`},forgotPasswordTitle:`Forgot Password`,forgotPasswordMessage:`If you've forgotten your password, please contact your system administrator to reset it.`,forgotPasswordEmailMessage:`Enter your email address and we'll send you a new password.`,emailAddress:`Email Address`,emailPlaceholder:`your.email@example.com`,cancel:`Cancel`,sending:`Sending...`,sendResetEmail:`Send Reset Email`,howToReset:`How to reset your password:`,resetStep1:`Contact your Bambuddy administrator`,resetStep2:`Ask them to reset your password in User Management`,resetStep3:`They can set a new temporary password for you`,resetStep4:`Log in with the new password and change it in Settings`,gotIt:`Got it`,resetPassword:{title:`Set New Password`,subtitle:`Enter and confirm your new password below.`,newPassword:`New Password`,newPasswordPlaceholder:`At least 8 characters`,confirmPassword:`Confirm Password`,confirmPasswordPlaceholder:`Repeat new password`,saving:`Saving…`,submit:`Set New Password`,backToLogin:`Back to login`,passwordsDoNotMatch:`Passwords do not match`,passwordTooShort:`Password must be at least 8 characters`,resetFailed:`Password reset failed. The link may have expired.`},twoFA:{title:`Two-Factor Authentication`,subtitle:`Your account is protected with 2FA. Enter the verification code below.`,methodAuthenticator:`Authenticator App`,methodEmail:`Email Code`,methodBackup:`Backup Code`,instructionsTotp:`Open your authenticator app and enter the 6-digit code for Bambuddy.`,instructionsEmail:`A 6-digit code has been sent to your email address. It expires in 10 minutes.`,instructionsEmailNotSent:`Click the button below to receive a verification code via email.`,instructionsBackup:`Enter one of your 8-character backup recovery codes. Each code can only be used once.`,sendCodeButton:`Send Code via Email`,sendingCode:`Sending...`,resendCode:`Resend code`,codeLabel:`Verification Code`,backupCodeLabel:`Backup Code`,codePlaceholder:`000000`,backupCodePlaceholder:`XXXXXXXX`,verifyButton:`Verify`,verifyingButton:`Verifying...`,backToLogin:`← Back to login`,orContinueWith:`or continue with`,signInWith:`Sign in with {{provider}}`,enterCode:`Please enter the verification code`,sendCodeFailed:`Failed to send verification code`,invalidCode:`Invalid code. Please try again.`}},setup:{title:`Bambuddy Setup`,subtitle:`Configure authentication for your Bambuddy instance`,enableAuth:`Enable Authentication`,adminAccount:`Admin Account`,adminAccountDesc:`If admin users already exist, authentication will be enabled using the existing admin accounts. Leave the fields below empty to use existing admins, or enter new credentials to create a new admin user.`,adminUsername:`Admin Username`,adminPassword:`Admin Password`,optionalIfAdminExists:`(optional if admin users exist)`,adminUsernamePlaceholder:`Enter admin username (optional)`,adminPasswordPlaceholder:`Enter admin password (optional)`,confirmPassword:`Confirm Password`,confirmPasswordPlaceholder:`Confirm admin password`,settingUp:`Setting up...`,completeSetup:`Complete Setup`,toast:{authEnabledAdminCreated:`Authentication enabled and admin user created`,authEnabledExistingAdmins:`Authentication enabled using existing admin users`,setupCompleted:`Setup completed`,enterBothCredentials:`Please enter both admin username and password, or leave both empty to use existing admin users`,passwordsDoNotMatch:`Passwords do not match`,passwordTooShort:`Password must be at least 6 characters`}},changePassword:{title:`Change Password`,currentPassword:`Current Password`,currentPasswordPlaceholder:`Enter current password`,newPassword:`New Password`,newPasswordPlaceholder:`Enter new password (min 6 characters)`,confirmPassword:`Confirm New Password`,confirmPasswordPlaceholder:`Confirm new password`,passwordsDoNotMatch:`Passwords do not match`,passwordTooShort:`Password must be at least 6 characters`,changing:`Changing...`,success:`Password changed successfully`,failed:`Failed to change password`},plateAlert:{title:`Print Paused!`,message:`Objects detected on build plate. The print has been automatically paused. Please clear the plate and resume the print.`,understand:`I Understand`},camera:{title:`Camera View`,invalidPrinterId:`Invalid printer ID`,live:`Live`,snapshot:`Snapshot`,restartStream:`Restart stream`,refreshSnapshot:`Refresh snapshot`,fullscreen:`Fullscreen`,exitFullscreen:`Exit fullscreen`,connectingToCamera:`Connecting to camera...`,capturingSnapshot:`Capturing snapshot...`,connectionLost:`Connection lost`,connectionFailed:`Camera connection failed`,reconnecting:`Reconnecting in {{countdown}}s... (attempt {{attempt}}/{{max}})`,reconnectNow:`Reconnect now`,cameraUnavailable:`Camera unavailable`,cameraUnavailableDesc:`Make sure the printer is powered on and connected.`,noCamera:`No camera available`,retry:`Retry`,cameraStream:`Camera stream`,zoomOut:`Zoom out`,zoomIn:`Zoom in`,resetZoom:`Reset zoom`,recording:`Recording`,startRecording:`Start Recording`,stopRecording:`Stop Recording`,chamberLight:`Toggle chamber light`,unavailable:`Camera unavailable`,diagnose:{button:`Diagnose`,modalTitle:`Camera diagnostic`,running:`Running diagnostic...`,runFailed:`Diagnostic could not run: {{error}}`,retry:`Run again`,stage:{tcp_reachable:`Network reachability`,first_frame:`Frame capture`,live_stream_active:`Live stream active`},summary:{all_ok:`Camera is working. The diagnostic completed all stages successfully.`,live_stream_active_healthy:`Camera is currently streaming with recent frames — no test needed.`,printer_unreachable:`Printer is not reachable. Check the IP address, network connection, and that the printer is powered on.`,camera_port_closed:`Printer is reachable but the camera port is closed. Make sure LAN-only mode and Developer Mode are enabled in the printer settings.`,no_frame:`Connected to the camera but no frames were received. Try again, or check that the camera is enabled in the printer settings.`,unknown_failure:`Camera diagnostic failed for an unknown reason. Check the support log for details.`},meta:{protocol:`Protocol`,port:`Port`,profile:`Profile`}}},groups:{title:`Group Management`,subtitle:`Manage permission groups for access control`,backToSettings:`Back to Settings`,createGroup:`Create Group`,noPermission:`You do not have permission to access this page.`,system:`System`,noDescription:`No description`,usersCount:`{{count}} users`,permissionsCount:`{{count}} permissions`,edit:`Edit`,delete:`Delete`,toast:{created:`Group created successfully`,updated:`Group updated successfully`,deleted:`Group deleted successfully`,enterGroupName:`Please enter a group name`},modal:{editGroup:`Edit Group`,createGroup:`Create Group`,cancel:`Cancel`,saving:`Saving...`,creating:`Creating...`,saveChanges:`Save Changes`},form:{groupName:`Group Name`,groupNamePlaceholder:`Enter group name`,systemGroupWarning:`System group names cannot be changed`,description:`Description`,descriptionPlaceholder:`Enter description (optional)`,permissions:`Permissions ({{count}} selected)`},deleteModal:{title:`Delete Group`,message:`Are you sure you want to delete this group? Users in this group will lose these permissions.`,confirm:`Delete Group`},editor:{title:`Edit Group`,createTitle:`Create Group`,search:`Search permissions...`,selectAll:`Select All`,clearAll:`Clear All`,permissionsSelected:`{{count}} selected`,noResults:`No permissions match your search`,websocketHint:`Required for live updates. Without it, the interface falls back to periodic polling.`,printerAccess:`Printer access`,adminsSeeAllPrinters:`Administrators always see every printer.`,printerAccessAfterCreate:`Once the group is created, choose its printers under Settings → Authentication → Printer access.`,printerAccessLimited:`Limited: {{printers}} printers picked, {{locations}} locations`,printerAccessOpen:`Not limited: members see every printer.`,managePrinterAccess:`Manage printer access`}},printerAccess:{tab:`Printer access`,intro:`Choose which printers each group's members may see and control. A group that isn't limited narrows nothing: a user who is in no limited group sees every printer, and administrators always do.`,byGroup:`By group`,byPrinter:`By printer`,searchGroups:`Search groups`,groupFilter:{all:`All`,limited:`Limited`,open:`Not limited`},noGroupsMatch:`No groups match.`,alwaysAll:`Always every printer`,notLimited:`Every printer`,reachShort:`{{count}} of {{total}} printers`,unsaved:`Unsaved changes`,pickGroup:`Pick a group to choose its printers.`,memberCount:`Members: {{count}}`,editGroup:`Edit group`,adminsSeeAll:`Administrators always see every printer.`,limit:`Limit members to the printers and locations chosen here`,limitHint:`Off: this group doesn't narrow which printers its members see.`,reach:`Members can use {{count}} of {{total}} printers.`,noneGranted:`Nothing chosen: members of this group won't see any printer.`,noPrinters:`No printers have been added yet.`,searchPrinters:`Search name, model, serial or location`,allLocations:`All locations`,noLocation:`No location`,allModels:`All models`,accessFilter:`Access`,accessAll:`With and without access`,accessWith:`With access`,accessWithout:`Without access`,tickShown:`Tick all shown`,untickShown:`Untick all shown`,emptyLocation:`no printer is here at the moment`,wholeLocation:`Whole location`,wholeLocationHint:`Every printer in {{location}}, including printers added there later`,noPrintersMatch:`No printers match.`,viaLocation:`via location`,alsoVisible:`Besides the groups listed here, every printer is visible to administrators and to users who are in no limited group.`,openUsers:`Users in no limited group: {{names}}`,noOpenUsers:`Every user apart from administrators is in a limited group.`,noLimitedGroups:`No group is limited yet, so every user sees every printer. Limit a group under By group.`,noLimitedGroupReaches:`No limited group`,showingOne:`Showing one printer.`,showAll:`Show all printers`,viaLocationTitle:`Through location {{location}}. Change it under By group.`,removeGroup:`Remove access for {{group}}`,addGroup:`Give access to…`,changedGroups:`Unsaved changes: {{names}}`,discard:`Discard`,saved:`Printer access saved`,whoHasAccess:`Who has access`,moveWarning:`Moving this printer to another location changes who can use it: {{groups}}.`},users:{title:`User Management`,subtitle:`Manage users and their access to your Bambuddy instance`,backToSettings:`Back to Settings`,createUser:`Create User`,noPermission:`You do not have permission to access this page.`,admin:`Admin`,noGroups:`No groups`,active:`Active`,inactive:`Inactive`,edit:`Edit`,delete:`Delete`,system:`System`,noGroupsAvailable:`No groups available`,table:{username:`Username`,groups:`Groups`,status:`Status`,actions:`Actions`},toast:{created:`User created successfully`,updated:`User updated successfully`,deleted:`User deleted successfully`,fillRequired:`Please fill in all required fields`,passwordsDoNotMatch:`Passwords do not match`,passwordTooShort:`Password must be at least 6 characters`,ldapProvisioned:`Provisioned LDAP user "{{username}}"`},modal:{createUser:`Create User`,editUser:`Edit User`,cancel:`Cancel`,creating:`Creating...`,saving:`Saving...`,saveChanges:`Save Changes`,advancedAuthSubtitle:`with Advanced Authentication`,tabsAriaLabel:`User source`,localTab:`Local`,ldapTab:`LDAP`,ldapSearchLabel:`Search directory`,ldapSearchPlaceholder:`Type a username, name, or email...`,ldapMinChars:`Type at least 2 characters to search`,ldapTypeToSearch:`Start typing to search the LDAP directory`,ldapSearching:`Searching directory...`,ldapNoResults:`No matching users in the directory`,ldapSearchError:`Directory search failed. Check the LDAP server status.`,ldapAlreadyProvisioned:`Already provisioned`,ldapSelectedLabel:`Selected`,ldapProvision:`Provision user`,ldapProvisioning:`Provisioning...`,ldapErrorProvision:`Provisioning failed. Check the LDAP server status and try again.`},form:{username:`Username`,usernamePlaceholder:`Enter username`,email:`Email`,emailPlaceholder:`user@example.com`,password:`Password`,passwordPlaceholder:`Enter password`,confirmPassword:`Confirm Password`,confirmPasswordPlaceholder:`Confirm password`,newPasswordPlaceholder:`Enter new password`,confirmNewPasswordPlaceholder:`Confirm new password`,leaveBlankToKeep:`leave blank to keep current`,groups:`Groups`,optional:`optional`,autoGeneratedPassword:`A secure password will be automatically generated and emailed to the user.`,passwordManagedByAdvancedAuth:`Password is managed by Advanced Authentication. Use "Reset Password" to send a new password to the user via email.`,resetPassword:`Reset Password`,resettingPassword:`Resetting Password...`},deleteModal:{title:`Delete User`,message:`Are you sure you want to delete this user? This action cannot be undone.`,confirm:`Delete User`}},streamOverlay:{branding:{title:`Branding`,hint:`One shared logo for this installation. PNG or WebP, up to 2 MiB and 4 million pixels. Replacing or removing it affects overlays using it.`,upload:`Upload logo`,logo:`Custom logo`,from:`From colour`,to:`To colour`,reset:`Reset colours`,failed:`Could not save the logo. Check the image format and size.`},title:`Stream Overlay`,invalidPrinterId:`Invalid printer ID`,cameraStream:`Camera stream`,progress:`Progress`,eta:`ETA`,printerIdle:`Printer is idle`,printerOffline:`Printer offline`,layer:`Layer`,remaining:`Remaining`,builder:{backgroundTransparency:`Background transparency`,backgroundTransparencyHint:`Fade the dark backgrounds only. Text, logos and camera stay visible.`,layout:`Layout`,landscape:`Landscape`,portrait:`Portrait`,both:`Both`,orientationUrl:`{{orientation}} URL`,orientationPreview:`{{orientation}} preview`,sourceDimensions:`Browser source: {{width}} × {{height}} px`,artwork:`Artwork`,artworkClassic:`Classic`,artworkV2:`Version 2`,createToken:`Create overlay token`,showToken:`Show token`,hideToken:`Hide token`,credentialHint:`Create a token above, enter an existing token, or import an overlay URL. Copy the URL before leaving: tokens are held only in memory and cannot be recovered from their stored hash.`,importUrl:`Existing overlay URL`,importAction:`Import URL`,importHint:`Import a URL locally to reuse its token and settings on this server. Settings Bambuddy doesn't recognise are ignored.`,rememberedHint:`Your choices are remembered in this browser. The token is not.`,resetChoices:`Reset choices`,importError:`Enter a valid HTTP(S) overlay URL with a positive printer number, at most one token and no user name or password.`,manualToken:`Manual token`,title:`Streaming Overlay`,description:`Build the URL for a streaming overlay — a full-screen camera view with live print data drawn over it, for OBS, a wall display, or any browser source. Pick the fields you want and copy the URL.`,printer:`Printer`,size:`Text size`,sizeSmall:`Small`,sizeMedium:`Medium`,sizeLarge:`Large`,fps:`Frame rate`,fpsHint:`A1 and P1 cameras top out around 5 fps whatever you ask for.`,tokenWarning:`This URL contains a token — anyone who can read it can watch the stream and see the file name. Revoke the token to cut it off.`,fields:`Fields to show`,fieldPrinter:`Printer name`,fieldModel:`Printer model`,fieldFilename:`File name`,fieldStatus:`Status`,fieldProgress:`Progress bar`,fieldLayers:`Layer count`,fieldEta:`Time remaining and ETA`,fieldCamera:`Camera feed`,chamberHint:`Chamber temperature only appears on models with a real chamber sensor — P1 and A1 printers report a meaningless value, so it is left out there.`,urlTitle:`Overlay URL`,open:`Open`,showPreview:`Show preview`,hidePreview:`Hide preview`,previewTitle:`Overlay preview`},status:{printing:`Printing`,paused:`Paused`,finished:`Finished`,failed:`Failed`,idle:`Idle`,unknown:`Unknown`}},profiles:{title:`Profiles`,subtitle:`Manage your slicer presets and pressure advance calibrations`,tabs:{bambuCloud:`Bambu Cloud`,orcaCloud:`Orca Cloud`,local:`Local Profiles`,kprofiles:`K-Profiles`},orcaCloud:{connectedAs:`Connected as`,connectedShort:`Connected to Orca Cloud`,logout:`Disconnect`,noLogoutPermission:`You do not have permission to disconnect`,noConnectPermission:`You do not have permission to connect to Orca Cloud`,retry:`Retry`,connectButton:`Connect Orca Cloud`,connect:{title:`Connect to Orca Cloud`,description:`Sign in to your Orca Cloud account to sync your slicer profiles into Bambuddy.`},device:{title:`Approve Bambuddy in Orca Cloud`,instruction:`Open Orca Cloud and approve this code. Bambuddy connects automatically once you approve.`,codeLabel:`Your pairing code`,openButton:`Open Orca Cloud approval page`,manualHint:`Or go to {{url}} and enter the code above.`,waiting:`Waiting for you to approve…`,cancel:`Cancel`},profiles:{title:`Your Orca Cloud profiles ({{count}})`,refresh:`Refresh`,empty:`No profiles found in your Orca Cloud account yet.`},toast:{disconnected:`Disconnected from Orca Cloud`},errors:{startFailed:`Could not start Orca Cloud pairing.`,denied:`The pairing was denied in Orca Cloud.`,expired:`The pairing code expired. Click Connect to try again.`,pollFailed:`Lost the connection while waiting for approval. Please try again.`}},localProfiles:{title:`Local Profiles`,subtitle:`Import and manage slicer presets from OrcaSlicer`,import:`Import Profiles`,importDesc:`Drop .bbscfg, .bbsflmt, .orca_filament, .zip, or .json files here`,importing:`Importing...`,search:`Search local presets...`,noPresets:`No local presets yet`,noSearchResults:`No presets match your search`,badge:`Local`,edit:`Edit`,delete:`Delete`,cancel:`Cancel`,deleteConfirmTitle:`Delete Preset`,deleteConfirm:`Are you sure you want to delete this preset? This cannot be undone.`,source:`Source`,inheritsFrom:`Inherits`,filamentType:`Type`,vendor:`Vendor`,compatiblePrinters:`Printers`,nozzleTemp:`Nozzle Temp`,cost:`Cost`,density:`Density`,pressureAdvance:`Pressure Advance`,filament:`Filament`,process:`Process`,printer:`Printer`,toast:{importSuccess:`{{count}} preset(s) imported`,importSkipped:`{{count}} preset(s) skipped (duplicates)`,importError:`{{count}} error(s) during import`,deleted:`Preset deleted`,updated:`Preset updated`}},connectedAs:`Connected as`,signInExpiredTitle:`Bambu Cloud sign-in expired`,signInExpiredBody:`Bambu Lab no longer accepts the stored token. Sign in again to restore cloud profiles, MakerWorld imports and firmware checks.`,logout:`Logout`,noLogoutPermission:`You do not have permission to logout`,failedToLoad:`Failed to load profiles`,retry:`Retry`,time:{justNow:`Just now`,minsAgo:`{{count}}m ago`,hoursAgo:`{{count}}h ago`,daysAgo:`{{count}}d ago`},toast:{loggedOut:`Logged out`},login:{title:`Connect to Bambu Cloud`,subtitle:`Sync your slicer presets across devices`,email:`Email`,password:`Password`,region:`Region`,regionGlobal:`Global`,regionChina:`China`,verificationCode:`Verification Code`,totpCode:`Authenticator Code`,checkEmail:`Check your email ({{email}}) for a 6-digit code`,enterTotpHint:`Enter the 6-digit code from your authenticator app`,accessToken:`Access Token`,accessTokenHint:`Paste your Bambu Cloud access token. China-region accounts must use this path (phone-bound — email login unavailable). See the wiki for how to retrieve the token from MakerWorld cookies.`,back:`Back`,loginButton:`Login`,verifyButton:`Verify`,setTokenButton:`Set Token`,useToken:`Use access token instead`,captchaTitle:`Bambu Cloud is asking for a CAPTCHA`,captchaBody:`Bambu is challenging your network before it will accept a sign-in, and the challenge cannot be answered from Bambuddy. Your email and password are not the problem. The block is tied to your public IP address and normally clears by itself within a few hours — retrying repeatedly makes it last longer. To sign in now, use an access token from a browser session instead.`,useEmail:`Login with email instead`,toast:{loggedIn:`Logged in successfully`,codeSent:`Verification code sent to your email`,enterTotp:`Enter code from your authenticator app`,tokenSet:`Token set successfully`}},presets:{myPreset:`My preset (editable)`,duplicate:`Duplicate`,editable:`Editable`,failedToLoadDetails:`Failed to load preset details`,deleteConfirm:`Delete this preset?`,deleteWarning:`This will permanently delete "{{name}}" from Bambu Cloud. This cannot be undone.`,noDuplicatePermission:`You do not have permission to duplicate presets`,noEditPermission:`You do not have permission to edit presets`,noDeletePermission:`You do not have permission to delete presets`,types:{filament:`Filament preset`,printer:`Printer preset`,process:`Process preset`},toast:{deleted:`Preset deleted`,created:`Preset created`,updated:`Preset updated`,duplicated:`Preset duplicated`,fieldAdded:`Field "{{key}}" added`,exported:`Preset exported`},baseLabel:`Base: {{name}}`,currentLabel:`Current: {{name}}`,newPreset:`New Preset`,editPreset:`Edit Preset`,duplicatePreset:`Duplicate Preset`,createNewPreset:`Create New Preset`,customizeSettings:`Customize settings for your new preset`,compareWithBase:`Compare with base preset`,compare:`Compare`,basePreset:`Base Preset`,selectBasePreset:`Select base preset...`,presetName:`Preset Name`,myCustomPreset:`My custom preset`,inheritsFrom:`Inherits from`,dropJsonToImport:`Drop JSON to import`,tabs:{common:`Common`,allFields:`All Fields`},availableFields:`Available Fields`,searchFieldsPlaceholder:`Search fields...`,noMatchingFields:`No matching fields`,allFieldsAdded:`All fields added`,addCustomField:`Add custom field`,yourOverrides:`Your Overrides`,noOverridesYet:`No overrides yet`,clickFieldsToAdd:`Click fields on the left to add them`,saveAsTemplate:`Save as template`,jsonTip:`Tip: Drag & drop a .json file anywhere on this modal to import settings`},cloudView:{searchPlaceholder:`Search presets...`,templates:`Templates`,refresh:`Refresh`,newPreset:`New Preset`,clearFilters:`Clear filters`,compareMode:`Compare Mode`,selectAnotherPreset:`Select another {{type}} preset`,clickTwoPresets:`Click two presets of the same type to compare`,selectFirst:`1. Select first`,selectSecond:`2. Select second`,compareNow:`Compare Now`,lastSynced:`Last synced:`,showingCount:`Showing {{showing}} of {{total}} presets`,noPresetsFound:`No presets found`,columns:{filament:`Filament`,process:`Process`,printer:`Printer`},noFilamentPresets:`No filament presets`,noProcessPresets:`No process presets`,noPrinterPresets:`No printer presets`,filters:{type:`Type`,owner:`Owner`,printer:`Printer`,nozzle:`Nozzle`,filament:`Filament`,layer:`Layer`,all:`All`,myPresets:`My Presets`,builtIn:`Built-in`,process:`Process`},noTemplatesPermission:`You do not have permission to manage templates`,noRefreshPermission:`You do not have permission to refresh profiles`,noCreatePermission:`You do not have permission to create presets`},templates:{title:`Quick Templates`,noTemplates:`No templates yet`,createFirst:`Create templates from the preset editor`,typeFilter:`Type:`,deleteTitle:`Delete Template`,deleteWarning:`This action cannot be undone`,deleteConfirm:`Are you sure you want to delete "{{name}}"?`,namePlaceholder:`Template name`,descriptionPlaceholder:`Description`,settingsJson:`Settings (JSON)`,fieldsCount:`{{count}} fields`,shownInModals:`Shown in modals`,hiddenInModals:`Hidden in modals`,apply:`Apply`,toast:{deleted:`Template deleted`,updated:`Template updated`,created:`Template created`,applied:`Template applied`}}},support:{debugLoggingActive:`Debug logging is active`,manageLogs:`Manage`,collectItem7:`Printer connectivity and firmware versions`,collectItem8:`Integration status (Spoolman, MQTT, HA)`,collectItem9:`Network interfaces (subnets only)`,collectItem10:`Python package versions`,collectItem11:`Database health checks`,collectItem12:`Docker environment details`,bundleGenerating:`Generating bundle...`,bundleStepConnection:`Running printer connectivity checks`,bundleStepVirtualPrinters:`Running virtual-printer setup checks`,bundleStepLogScan:`Scanning recent logs for known issues`,bundleStepBuild:`Building the support bundle ZIP`},fileManager:{combine:{action:`Combine to 3MF`,tooltip:`Combine the selected STLs into one 3MF so they can be sliced on a single plate`,title:`Combine to 3MF`,description:`Builds one 3MF with every model below, ready to slice on a single plate. Turn on auto-arrange when slicing to lay them out on the bed.`,nameLabel:`File name`,defaultName:`{{name}} + {{count}} more`,model:`Model`,copies:`Copies`,copiesFor:`Copies of {{filename}}`,total:`Objects on the plate: {{count}}`,tooMany:`At most {{max}} objects per plate`,sliceNext:`Open the slicer when done`,submit:`Combine`,done:`Created {{filename}} with {{count}} objects`},variants:{badge:`{{count}} versions`,groupAction:`Group as versions`,groupTooltip:`Mark these files as the same job sliced for different printers`,grouped:`Grouped {{count}} files as versions`,printAlternatives:`Print ({{count}} alternatives)`},title:`File Manager`,subtitle:`Organize and manage your print files`,uploadFiles:`Upload Files`,newFolder:`New Folder`,folderName:`Folder Name`,folderNamePlaceholder:`e.g., Functional Parts`,renameFile:`Rename File`,renameFolder:`Rename Folder`,invalidFilenameChar:`The character "{{char}}" is not allowed in print filenames. The printer SD card rejects: < > : " / \\ | ? *`,moveFiles:`Move {{count}} File(s)`,rootNoFolder:`Root (No Folder)`,current:`current`,linkFolder:`Link Folder`,linkFolderDescription:`Link "{{name}}" to a project or archive for quick access.`,project:`Project`,archive:`Archive`,noProjectsFound:`No projects found`,noArchivesFound:`No archives found`,unlink:`Unlink`,link:`Link`,dragDropFiles:`Drag & drop files here`,dropFilesHere:`Drop files here`,releaseToUpload:`Release to upload`,orClickToBrowse:`or click to browse`,allFileTypesSupported:`All file types supported. ZIP files will be extracted.`,zipFilesDetected:`ZIP files detected`,zipExtractOptions:`ZIP files will be extracted. Choose how to handle folder structure:`,preserveZipStructure:`Preserve folder structure from ZIP`,createFolderFromZip:`Create folder from ZIP filename`,stlThumbnailGeneration:`STL thumbnail generation`,zipMayContainStl:`ZIP files may contain STL files. Thumbnails can be generated during extraction.`,thumbnailsCanBeGenerated:`Thumbnails can be generated for STL files. Large models may take longer to process.`,generateThumbnailsForStl:`Generate thumbnails for STL files`,threemfDetected:`3MF files detected`,threemfExtractionInfo:`Printer model, material, color, and print settings will be automatically extracted from 3MF files.`,willBeExtracted:`Will be extracted`,filesExtracted:`{{count}} files extracted`,uploadComplete:`Upload complete: {{succeeded}} succeeded`,uploadFailed:`Upload failed`,zipFilesFailed:`{{count}} files failed`,uploading:`Uploading...`,changeLink:`Change Link...`,linkTo:`Link to...`,linkToProjectOrArchive:`Link to project or archive`,generateThumbnail:`Generate Thumbnail`,generateThumbnails:`Generate Thumbnails`,generateThumbnailsForMissing:`Generate thumbnails for STL and PDF files missing them`,gridView:`Grid view`,listView:`List view`,columnsView:`Column view`,lowDiskSpaceWarning:`Low disk space warning`,lowDiskSpaceDetails:`Only {{free}} free of {{total}} total. Threshold is set to {{threshold}} GB in settings.`,files:`Files`,folders:`Folders`,size:`Size`,free:`Free`,allFiles:`All Files`,allExternal:`External`,externalIsEmpty:`No external files`,externalEmptyDescription:`Files in your linked external folders will appear here.`,wrap:`Wrap`,enableTextWrapping:`Enable text wrapping`,disableTextWrapping:`Disable text wrapping`,collapse:`Collapse`,collapseFoldersByDefault:`Collapse folders by default`,expandFoldersByDefault:`Expand folders by default`,folderSort:`Sort folders`,folderSortByName:`By name`,folderSortByActivity:`By recent activity`,dragToResizeTooltip:`Drag to resize, double-click to reset`,searchFiles:`Search files...`,searchSubfoldersHint:`Including subfolders`,readme:{truncated:`Truncated`,show:`Show README`,hide:`Hide README`,label:`README`},tags:{title:`Tags`,subtitle:`Label files for cross-cutting filtering — toys, kid-safe, PETG-only, anything.`,manage:`Tags`,manageTitle:`Manage tag catalog`,add:`New tag`,edit:`Rename tag`,name:`Name`,fileCount:`Files`,empty:`No tags yet. Create one to start labelling files.`,noMatches:`No matching tags.`,createPlaceholder:`e.g. toys, kid-safe, petg`,createButton:`Create`,nameRequired:`Name is required.`,searchPlaceholder:`Filter tags...`,created:`Tag created.`,updated:`Tag renamed.`,deleted:`Tag removed.`,saveFailed:`Could not save tag.`,deleteFailed:`Could not remove tag.`,applyFailed:`Could not apply tags.`,applyAdd:`Add tags`,applyRemove:`Remove tags`,applyAddSuccess:`Added {{count}} tag(s) across {{files}} file(s).`,applyRemoveSuccess:`Removed {{count}} tag(s) across {{files}} file(s).`,actionAdd:`Add to selected files`,actionRemove:`Remove from selected files`,tagAction:`Tag`,bulkTitle:`Tag {{count}} selected file(s)`,bulkTooltip:`Add or remove tags on every selected file.`,noPermission:`You do not have permission to tag files.`,filterLabel:`Filtering by:`,clearAll:`Clear all`,confirmDelete:`Delete tag "{{name}}"?`,confirmDeleteMessage:`This removes the tag from the catalog. Files keep their other tags.`,confirmDeleteInUseMessage:`This tag is on {{count}} file(s). Deleting removes the chip from all of them; files themselves are untouched.`,editAria:`Edit {{name}}`,deleteAria:`Delete {{name}}`},allTypes:`All types`,prints:`Prints`,ascending:`Ascending`,descending:`Descending`,showModified:`Show modified dates`,hideModified:`Hide modified dates`,lastModified:`Last modified`,lastActivity:`Last activity`,resultsCount:`{{showing}} of {{total}} files`,selectAll:`Select All`,deselectAll:`Deselect All`,selected:`{{count}} selected`,adding:`Adding...`,loadingFiles:`Loading files...`,folderIsEmpty:`Folder is empty`,noFilesOutsideFolders:`No files outside folders`,noFilesYet:`No files yet`,folderEmptyDescription:`Upload files or move files into this folder to get started.`,noFilesDescription:`Upload files to start organizing your print-related files.`,noMatchingFiles:`No matching files`,noMatchingFilesDescription:`No files match your current search or filter criteria.`,clearFilters:`Clear filters`,printedCount:`Printed {{count}}x`,uploadedBy:`Uploaded By`,deleteFolder:`Delete Folder`,deleteFile:`Delete File`,deleteFilesCount:`Delete {{count}} Files`,deleteFolderConfirm:`Are you sure you want to delete this folder? All files inside will also be deleted.`,deleteFileConfirm:`Are you sure you want to delete this file?`,deleteFilesConfirm:`Are you sure you want to delete {{count}} selected files? This action cannot be undone.`,deleting:`Deleting...`,noPermissionRenameFolder:`You do not have permission to rename folders`,noPermissionLinkFolder:`You do not have permission to link folders`,noPermissionDeleteFolder:`You do not have permission to delete folders`,onlyOwnFoldersDeletable:`You can only delete your own folders when everything in them is yours, or empty folders without an owner`,shareFolder:`Share with everyone`,unshareFolder:`Stop sharing`,shareFolderHint:`Shared folders are visible to every user, who can add files and subfolders to them`,sharedFolder:`Shared with everyone`,folderNotWritable:`You can only add to your own folders and folders shared with everyone`,noPermissionPrint:`You do not have permission to print`,noPermissionAddToQueue:`You do not have permission to add to queue`,noPermissionSlice:`You do not have permission to slice files`,noPermissionDownload:`You do not have permission to download files`,noPermissionPreview:`You do not have permission to preview files`,preview3d:`3D Preview`,preview:{open:`Preview`,error:`This file cannot be previewed.`,tooLarge:`File is too large to preview ({{size}}).`,page:`Page {{current}} of {{total}}`,prevPage:`Previous page`,nextPage:`Next page`,zoomIn:`Zoom in`,zoomOut:`Zoom out`,resetZoom:`Reset zoom`,fullscreen:`Fullscreen`,exitFullscreen:`Exit fullscreen`,emptySheet:`This sheet is empty`,truncatedRows:`Showing the first {{shown}} of {{total}} rows`,truncatedCols:`Showing the first {{shown}} of {{total}} columns`},details:{title:`File details`,size:`Size`,type:`Type`,printName:`Print name`,printTime:`Print time`,filament:`Filament`,slicedFor:`Sliced for`,source:`Source`,created:`Created`,modified:`Modified`,notes:`Notes`,notesPlaceholder:`Print settings, tips, what worked...`,externalLink:`External link`,externalLinkPlaceholder:`https://printables.com/model/...`,openLink:`Open link`,photos:`Photos`,addPhoto:`Add photo`,noPhotos:`No photos yet`,deletePhoto:`Delete photo`,photoCount_one:`{{count}} photo`,photoCount_other:`{{count}} photos`,hasNotes:`Has notes`,save:`Save`,saved:`File details saved`,saveFailed:`Failed to save file details`,uploadFailed:`Failed to upload photo`,deleteFailed:`Failed to delete photo`},noPermissionRenameFile:`You do not have permission to rename this file`,noPermissionGenerateThumbnail:`You do not have permission to generate thumbnails`,noPermissionDeleteFile:`You do not have permission to delete this file`,noPermissionCreateFolder:`You do not have permission to create folders`,noPermissionUpload:`You do not have permission to upload files`,noPermissionMoveFiles:`You do not have permission to move files`,noPermissionDeleteFiles:`You do not have permission to delete files`,linkExternal:`Link External`,linkExternalFolder:`Link External Folder`,linkExternalFolderDescription:`Mount a host directory (NAS, USB, network share) into the File Manager. Files are not copied — they are accessed directly from the original path.`,externalFolderNamePlaceholder:`e.g., NAS Prints`,externalPath:`Host Path`,externalPathHelp:`Absolute path to the directory on the Docker host. Must be bind-mounted into the container.`,readOnly:`Read Only`,readOnlyHelp:`prevents uploads and deletions`,showHiddenFiles:`Show hidden files (dotfiles)`,externalFolder:`External Folder`,scanFolder:`Scan`,toast:{folderCreated:`Folder created`,openInSlicerFailed:`Could not open in slicer`,folderDeleted:`Folder deleted`,fileDeleted:`File deleted`,filesDeleted:`Deleted {{count}} files`,filesMoved:`Files moved`,folderLinked:`Folder linked`,folderUnlinked:`Folder unlinked`,externalFolderLinked:`External folder linked and scanned`,folderScanned:`Scan complete: {{added}} added, {{removed}} removed`,addedToQueue:`Added {{count}} file(s) to queue`,addedToQueuePartial:`Added {{added}} file(s), {{failed}} failed`,failedToAddToQueue:`Failed to add files: {{error}}`,fileRenamed:`File renamed`,folderRenamed:`Folder renamed`,folderShared:`Folder shared with everyone`,folderUnshared:`Folder no longer shared`,thumbnailsGenerated:`Generated {{count}} thumbnail(s)`,thumbnailsGeneratedPartial:`Generated {{succeeded}} thumbnail(s), {{failed}} failed`,noStlMissingThumbnails:`No STL or PDF files missing thumbnails`,failedToGenerateThumbnails:`Failed to generate thumbnails: {{error}}`,thumbnailGenerated:`Thumbnail generated`,failedToGenerateThumbnail:`Failed to generate thumbnail: {{error}}`}},projects:{parentLabel:`Parent project`,parentNone:`None (top-level project)`,parentHint:`Nest this project under another one so its figures roll up into a master project`,partOf:`Part of {{name}}`,subProjectCount:`{{count}} sub-projects`,subProjectsOf:`Sub-projects of {{name}}`,collapseSubProjects:`Collapse sub-projects`,expandSubProjects:`Expand sub-projects`,title:`Projects`,subtitle:`Organize and track your 3D printing projects`,newProject:`New Project`,editProject:`Edit Project`,deleteProject:`Delete Project`,projectName:`Project Name`,description:`Description`,noProjects:`No projects yet`,noProjectsFiltered:`No {{status}} projects`,noProjectsFilteredHelp:`You don't have any {{status}} projects. Projects will appear here when their status changes.`,createFirst:`Create your first project to start organizing related prints, tracking progress, and managing your builds.`,createFirstButton:`Create Your First Project`,create:`Create`,files:`Files`,prints:`Prints`,plates:`plates`,parts:`parts`,lastModified:`Last Modified`,deleteConfirm:`Are you sure you want to delete this project? Archives and queue items will be unlinked but not deleted.`,addFiles:`Add Files`,removeFile:`Remove File`,viewDetails:`View Details`,namePlaceholder:`e.g., Voron 2.4 Build`,descriptionPlaceholder:`Optional description...`,urlLabel:`URL`,urlPlaceholder:`https://makerworld.com/...`,urlInvalid:`URL must start with http:// or https://`,openExternalUrl:`Open project URL`,coverImageLabel:`Cover photo`,coverImageAlt:`Project cover photo`,coverImageUpload:`Upload`,coverImageReplace:`Replace`,coverImageRemove:`Remove`,color:`Color`,targetPlates:`Target Plates`,targetPlatesPlaceholder:`e.g., 25`,targetPlatesHelp:`Number of print jobs`,targetParts:`Target Parts`,targetPartsPlaceholder:`e.g., 150`,targetPartsHelp:`Total objects needed`,targetSets:`Copies per File`,targetSetsPlaceholder:`e.g., 10`,targetSetsHelp:`Times each printable file should be printed`,tagsLabel:`Tags (comma-separated)`,tagsPlaceholder:`e.g., voron, functional, gift`,dueDate:`Due Date`,priority:`Priority`,priorityLow:`Low`,priorityNormal:`Normal`,priorityHigh:`High`,priorityUrgent:`Urgent`,statusActive:`Active`,statusCompleted:`Completed`,statusArchived:`Archived`,done:`Done`,completed:`completed`,failed:`failed`,inQueue:`in queue`,noPrintsYet:`No prints yet`,printJobs:`Print jobs (plates)`,partsPrinted:`Parts printed`,failedParts:`Failed parts`,import:`Import`,export:`Export`,importProject:`Import project`,exportAll:`Export all projects`,loading:`Loading projects...`,noEditPermission:`You do not have permission to edit projects`,noDeletePermission:`You do not have permission to delete projects`,noCreatePermission:`You do not have permission to create projects`,noImportPermission:`You do not have permission to import projects`,noExportPermission:`You do not have permission to export projects`,toast:{created:`Project created`,updated:`Project updated`,deleted:`Project deleted`,imported:`Project imported`,multipleImported:`{{count}} projects imported`,importFailed:`Import failed`,exported:`Projects exported (metadata only)`}},projectDetail:{notFound:`Project not found`,backToProjects:`Back to Projects`,export:`Export`,exportProject:`Export project`,noExportPermission:`You do not have permission to export projects`,noEditPermission:`You do not have permission to edit projects`,partOf:`Part of:`,priorityLabel:`Priority:`,noPrints:`No prints in this project yet`,status:{active:`Active`,completed:`Completed`,archived:`Archived`},priority:{low:`Low`,normal:`Normal`,high:`High`,urgent:`Urgent`},dueDate:{overdue:`Overdue`,today:`Due today`,daysLeft:`{{count}} days left`},progress:{platesProgress:`Plates Progress`,partsProgress:`Parts Progress`,setsProgress:`Complete Sets`,sets:`sets`,setsHint:`A set is complete once every printable file has reached this count`,printJobs:`print jobs`,parts:`parts`,percentComplete:`{{percent}}% complete`,remaining:`{{count}} remaining`},stats:{printJobs:`Print Jobs`,total:`total`,failed:`{{count}} failed`,partsPrinted:`{{count}} parts printed`,printTime:`Print Time`,filamentUsed:`Filament Used`},cost:{title:`Cost Tracking`,filamentCost:`Filament Cost`,energy:`Energy`,totalCost:`Estimated Cost`,total:`Total`,includesBom:`incl. BOM`,wear:`Printer Wear`,budget:`Budget`,remaining:`Remaining`},subProjects:{title:`Sub-projects ({{count}})`,jobs:`{{count}} jobs`},rollup:{title:`Including {{count}} sub-projects`,progress:`Overall progress`,percentComplete:`{{percent}}% complete`},notes:{title:`Notes`,noEditPermission:`You do not have permission to edit notes`,placeholder:`Add notes about this project...`,empty:`No notes yet. Click Edit to add notes.`},files:{title:`Files`,linkFolders:`Link folders from the File Manager`,forQuickAccess:`to this project for quick access.`,fileCount:`{{count}} file(s)`,empty:`No folders linked. Go to File Manager and link a folder to this project.`,printedCount:`Printed {{count}} time(s)`,progressTooltip:`{{done}} of {{target}} completed prints`,noFiles:`No files in this folder.`},bom:{title:`Bill of Materials`,acquired:`{{completed}}/{{total}} acquired`,showAll:`Show all`,hideDone:`Hide done`,addPart:`Add Part`,noAddPermission:`You do not have permission to add parts`,partNamePlaceholder:`Part name (e.g., M3x8 screws)`,partName:`Part name`,qty:`Qty`,price:`Price ({{currency}})`,sourcingUrlPlaceholder:`Sourcing URL (optional)`,remarksPlaceholder:`Remarks (optional)`,deletePart:`Delete Part`,deleteConfirm:`Are you sure you want to delete "{{name}}"?`,noUpdatePermission:`You do not have permission to update parts`,noEditPermission:`You do not have permission to edit parts`,noDeletePermission:`You do not have permission to delete parts`,totalCost:`Total cost:`,empty:`No parts in the bill of materials. Add hardware, electronics, or other components to track what needs to be sourced.`},timeline:{title:`Activity Timeline`,empty:`No activity yet.`},template:{saveAsTemplate:`Save as Template`,noCreatePermission:`You do not have permission to create templates`},queue:{title:`Queue`,viewAll:`View all`,printing:`{{count}} printing`,queued:`{{count}} queued`},prints:{title:`Prints ({{count}})`},toast:{projectUpdated:`Project updated`,partAdded:`Part added`,partRemoved:`Part removed`,exportFailed:`Export failed`,projectExported:`Project exported`,templateCreated:`Template created`}},system:{title:`System Information`,version:`Version`,uptime:`Uptime`,cpuUsage:`CPU Usage`,memoryUsage:`Memory Usage`,diskUsage:`Disk Usage`,networkInfo:`Network Info`,logs:`Logs`,debugMode:`Debug Mode`,enableDebug:`Enable Debug Logging`,disableDebug:`Disable Debug Logging`,downloadLogs:`Download Logs`,clearLogs:`Clear Logs`,dockerInfo:`Docker Info`,containerName:`Container Name`,imageName:`Image Name`,platform:`Platform`,architecture:`Architecture`},sponsors:{sectionTitle:`Independent & community-funded`,tagline:`Bambuddy is free and stays that way because people choose to support it. No VC, no cloud lock-in.`,viewSupporters:`View supporters`,toastPrints:`You've completed {{count}} prints with Bambuddy. Bambuddy stays free thanks to its supporters.`,toastCost:`You've tracked {{total}} in filament with Bambuddy. See who keeps the project independent.`,toastArchives:`{{count}} prints archived with Bambuddy. See who keeps it independent.`,toastAnniversary:`One year with Bambuddy! See who keeps the project independent.`,toastVersionUpdate:`Updated to v{{version}}. Bambuddy stays free thanks to its supporters.`,toastBusiness:`Running Bambuddy on {{count}} printers? There's a support plan for teams — priority fixes, invoicing, and a direct line to the maintainer.`,businessCta:`Bambuddy for business`,businessTitle:`Bambuddy for business`,businessTagline:`You're running {{count}} printers. Priority support, commercial licensing and invoicing are available for teams and print farms.`},library:{title:`Filament Library`,addFilament:`Add Filament`,editFilament:`Edit Filament`,deleteFilament:`Delete Filament`,vendor:`Vendor`,material:`Material`,color:`Color`,kFactor:`K Factor`,temperature:`Temperature`,noFilaments:`No filaments in library`,deleteConfirm:`Are you sure you want to delete this filament?`,importFromPrinter:`Import from Printer`,exportToFile:`Export to File`,runWithPipeline:{actionLabel:`Run with pipeline`,noPermission:`You do not have permission to run pipelines`,modalTitle:`Run with pipeline`,confirmTitle:`Confirm run`,confirmIntro:`Pre-flight found issues with this run`,sourceHint:`Source`,pipelineHint:`Pipeline`,targetHint:`Target`,pipelineListAria:`Available pipelines`,runAnyway:`Run anyway`,loading:`Loading…`,empty:`No pipelines saved yet. Open the Slice dialog and click "Save as pipeline" to create one.`,noTarget:`No target printer set`,noTargetMessage:`This pipeline has no target printer set. Open it in Settings to pick one.`,copies:`Copies`,copiesHint:`max {{n}}`,classTarget:`Any {{model}}`,toast:{started:`Pipeline run started`,failed:`Could not start run`},issue:{printerNotSet:`No target printer set on this pipeline.`,printerNotFound:`Target printer no longer exists.`,printerDisabled:`Target printer is disabled.`,printerOffline:`Target printer is offline.`,filamentType:`Filament slot {{slot}}: expected {{expected}}, AMS has {{actual}}`,filamentColor:`Filament slot {{slot}}: colour differs (expected {{expected}}, AMS has {{actual}})`,amsSlotMissing:`AMS slot {{slot}} not available on this printer`,filamentUnverified:`Filament slot {{slot}} comes from a cloud / standard preset and could not be statically verified.`,noClassMatches:`No printers in this install match the pipeline's target model class ({{expected}}).`,classNotSet:`Pipeline target is set to a printer class but no model was chosen.`}}},slicerSettings:{presetValuesOutdatedSidecar:`Showing slicer defaults: your slicer sidecar is older than this feature and can't report a preset's values. Update the sidecar image to see them. Anything you don't change still uses the preset.`,presetValuesNotConfigured:`Showing slicer defaults: no slicer sidecar is configured, so a preset's values can't be read. Anything you don't change still uses the preset.`,presetValuesSidecarUnavailable:`Showing slicer defaults: the slicer sidecar did not answer, so a preset's values can't be read. Anything you don't change still uses the preset.`,presetValuesUnavailable:`Showing slicer defaults: the picked preset's own values could not be read. Anything you don't change still uses the preset.`,filamentDefault:`Default`,fromFile:`from file`,fromFileHint:`The designer changed this in the source file. Its value is {{value}}.`,fromFilePrinterCoupled:`designer's printer`,fromFilePrinterCoupledHint:`Tuned for the printer this file was designed for -- may be wrong or out of range on yours.`,fromFileOverridesPreset:`overrides preset`,fromFileOverridesPresetHint:`The file sets this to {{value}} where the preset you picked uses {{preset}}. Tick it only if the file should win.`,useFromFile:`Use the source file's value for {{option}}`,otherFromFile:`Other settings from this file`,fromFileSummary:`The designer changed {{count}} process settings in this file. Only the ones you tick are used.`,fromFileUseAll:`Use the designer's settings`,fromFileUseAllHint:`Ticks the settings that carry across printers. The ones tuned for the designer's own printer, and the ones that define the preset you picked, stay off.`,fromFileClear:`Clear {{count}}`,loading:`Loading slicer settings…`,mode:{simple:`Simple`,advanced:`Advanced`,expert:`Expert`},searchPlaceholder:`Search settings`,resetAll:`Reset {{count}}`,resetOption:`Reset to default`,noMatches:`No settings match this search.`},slice:{filamentSlotUnset:`not set`,processSettingsEmbedded:`Not used while "Use the file's built-in settings" is on -- the file's own settings drive this slice.`,processSettingsInactive:`Inactive`,presetsHidden:`{{count}} hidden`,showAllPresets:`Show all`,showFewerPresets:`Show fewer`,processSettings:`Process settings`,processSettingsHint:`Adjust the picked preset for this slice. Anything you don't touch stays as the preset defines it.`,processSettingsChanged:`{{count}} changed`,processSettingsUnchanged:`Preset defaults`,title:`Slice model`,action:`Slice`,actionAll:`Slice all {{count}} plates`,actionAllTitle:`Slice every plate into one multi-plate output (single archive). Filament selection covers every slot the project defines.`,allPlatesToggle:`Slice all {{count}} plates`,slicing:`Slicing…`,printer:`Printer profile`,process:`Process profile`,filament:`Filament profile`,filamentSlot:`Filament {{index}} ({{type}})`,filamentColour:`Filament colour`,selectPreset:`— Select a preset —`,loadingPresets:`Loading presets…`,analyzingPlateFilaments:`Analyzing plate filaments…`,analyzingPlateFilamentsHint:`Running a preview slice to discover which AMS slots this plate uses. Cached after — re-opening is instant.`,previewToast:`Analyzing {{name}} — {{elapsed}}`,previewWithProgress:`Analyzing {{name}} — {{stage}} ({{percent}}%) — {{elapsed}}`,notUsedByPlate:`— not used by this plate`,noPresetsForSlot:`No presets available`,otherPrinters:`Other printers`,presetsLoadFailed:`Failed to load presets. Open Settings → Profiles to import them first.`,refreshPresets:`Refresh`,refreshPresetsTitle:`Refresh presets — fetch the latest cloud and bundled listings (use after deleting a preset in Bambu Studio or Bambu Handy)`,allPresetsRequired:`All presets must be selected`,useEmbedded:`Use the file's built-in settings`,useEmbeddedHint:`Slice it the way the designer set it up (walls, infill, filament) instead of the profiles above. Offered because your printer matches the file's.`,autoOrient:`Auto-orient objects`,autoOrientHint:`Let the slicer turn each object onto its best printing side first. Overrides the way the model was laid down in the file.`,autoArrange:`Auto-arrange on the plate`,autoArrangeHint:`Let the slicer position the objects so they no longer overlap. Replaces the layout the file came with.`,enqueuing:`Submitting slice job…`,queued:`Queued…`,failed:`Slicing failed. Check the slicer sidecar logs.`,startedToast:`Slicing {{name}} in the background…`,queuedToast:`Queued: {{name}} — {{elapsed}}`,runningToast:`Slicing {{name}} — {{elapsed}}`,runningWithProgress:`{{name}} — {{stage}} ({{percent}}%) — {{elapsed}}`,runningWithProgressMultiPlate:`Plate {{plateIndex}} of {{plateCount}} • {{name}} — {{stage}} ({{percent}}%) — {{elapsed}}`,completedToast:`Sliced {{name}}`,externalWriteFallbackToast:`Saved to the internal library: the external folder could not be written to`,failedTitle:`Slicing failed`,failedToast:`Slicing {{name}} failed: {{detail}}`,tier:{local:`Imported`,cloud:`Bambu Cloud`,orcaCloud:`Orca Cloud`,standard:`Standard`},cloud:{notAuthenticated:`Sign in to Bambu Cloud (Settings → Profiles → Bambu Cloud) to see your cloud presets.`,expired:`Bambu Cloud session expired — sign in again to refresh your cloud presets.`,unreachable:`Bambu Cloud is unreachable right now. Local and standard presets still work.`},orcaCloud:{notAuthenticated:`Sign in to Orca Cloud (Profiles → Orca Cloud) to see your Orca presets.`,expired:`Orca Cloud session expired — sign in again to refresh your Orca presets.`,unreachable:`Orca Cloud is unreachable right now. Other presets still work.`},bedType:{label:`Build plate`,auto:`Auto (use process preset)`,coolPlate:`Cool Plate`,coolPlateSuperTack:`Cool Plate SuperTack`,engineering:`Engineering Plate`,highTemp:`High Temp Plate`,texturedPEI:`Textured PEI Plate`,smoothPEI:`Smooth PEI Plate`},filters:{onlyConnectedModels:`Only printers that are online`,onlyConnectedModelsHint:`Printer profiles for the models online right now, at every nozzle size.`,onlyLoadedSpools:`Only spools that are loaded`,onlyLoadedSpoolsHint:`Filament profiles of the spools in the online printers of the selected model. A profile you pick yourself stays.`,noneOnline:`No printer is online, so every profile is shown.`,noneLoaded:`No loaded spool has a profile for this printer, so every filament profile is shown.`,notOnline:`Not online`,notLoaded:`Not loaded`},loadedSpools:{title:`Loaded spools`,pick:`Pick`,pickTitle:`Pick a spool loaded in a connected printer`,none:`No printer of this model is online.`,nothingLoaded:`No AMS and no external spool.`,unknownSpool:`Unidentified spool`,empty:`Empty`,noProfile:`No profile for the selected printer`,noProfileShort:`No profile for this printer`},pipelines:{label:`Pipeline`,applyAria:`Apply pipeline`,applyPrompt:`Apply pipeline…`,empty:`No saved pipelines`,saveButton:`Save as pipeline`,saveTitle:`Save the current four-slot selection as a reusable pipeline`,namePlaceholder:`Pipeline name`,nameAria:`New pipeline name`,toast:{applied:`Applied "{{name}}"`,saved:`Pipeline saved`,saveFailed:`Save failed`}}},spoolman:{title:`Spoolman Integration`,enabled:`Spoolman Enabled`,url:`Spoolman URL`,connected:`Connected`,disconnected:`Not Connected`,testConnection:`Test Connection`,sync:`Sync`,syncing:`Syncing...`,lastSync:`Last Sync`,linkToSpoolman:`Link to Spoolman`,openInSpoolman:`Open in Spoolman`,unlinkSpool:`Unlink Spool`,unlinkConfirmTitle:`Unassign Spool?`,unlinkConfirmMessage:`This will remove the spool from this slot. The spool data itself will remain unchanged.`,selectSpool:`Select Spool`,noUnlinkedSpools:`No unassigned spools available`,linkSuccess:`Spool assigned successfully`,linkFailed:`Failed to assign spool`,unlinkSuccess:`Spool unassigned successfully`,unlinkFailed:`Failed to unassign spool`,linkedSpool:`Assigned spool`,spoolId:`Spool ID`,fillSourceLabel:`(Spoolman)`,weight:`Weight`,remaining:`Remaining`,disableWeightSync:`Disable AMS Estimated Weight Sync`,disableWeightSyncDesc:`Don't update remaining capacity from AMS estimates. Use this if you prefer Spoolman's usage tracking over AMS percentage-based estimates. New spools will still use the AMS estimate as their initial weight.`,reportPartialUsage:`Report Partial Usage for Failed Prints`,reportPartialUsageDesc:`When a print fails or is cancelled, report the estimated filament used up to that point based on layer progress.`},locations:{title:`Storage Locations`,subtitle:`Manage shelves, drawers, and other physical storage spots for your spools`,add:`Add Location`,addShort:`Add`,edit:`Edit Location`,name:`Name`,spools:`Spools`,sensors:`Sensors`,empty:`No storage locations yet. Create your first shelf or drawer.`,manage:`Locations`,createPlaceholder:`e.g. Shelf A, Drawer 1`,nameRequired:`Location name is required`,created:`Location created`,updated:`Location updated`,deleted:`Location deleted`,saveFailed:`Failed to save location`,deleteFailed:`Failed to delete location`,deleteBlocked:`Remove all spools from this location before deleting`,confirmDelete:`Delete "{{name}}"?`,confirmDeleteMessage:`This location will be removed from the catalog. Spools must be moved first.`,confirmDeleteMessageWithSensors:`This location will be removed from the catalog. Spools must be moved first. Connected sensors will also be deleted.`},inventory:{title:`Spool Inventory`,subtitle:`Manage your spools`,addToInventory:`Add to Inventory`,addToInventoryPending:`Adding...`,addToInventorySuccess:`Spool added to inventory`,addToInventoryFailed:`Failed to add spool to inventory`,unknownSpoolTitle:`New filament detected`,unknownSpoolMessage:`A spool with an unknown RFID tag was detected at {{location}}. Add it to your inventory now?`,unknownSpoolSlot:`Slot`,bulk:{selectAllVisible:`Select all visible`,selectRow:`Select row`,selectGroup:`Select group`,selectionCount:`{{count}} selected`,edit:`Edit`,printLabels:`Print labels`,resetUsage:`Reset usage`,restore:`Restore`,archive:`Archive`,delete:`Delete`,clearSelection:`Clear selection`,editTitle:`Bulk edit spools`,editSubtitle:`Applies to {{count}} selected spools. Only fields you tick get updated.`,editHint:`Type into a field to mark it for update — only ticked rows are sent. Leaving a field empty leaves the spools unchanged (clearing fields is per-spool only).`,useCustom:`Use "{{value}}"`,toggleField:`Toggle update for this field`,changeCount:`{{count}} fields will be updated.`,applyPending:`Applying...`,applyButton:`Apply to {{count}} spools`,deleteTitle:`Delete selected spools`,archiveTitle:`Archive selected spools`,restoreTitle:`Restore selected spools`,resetUsageTitle:`Reset usage on selected spools`,deleteMessage:`Permanently delete {{count}} spools? This cannot be undone.`,archiveMessage:`Archive {{count}} spools? They can be restored later.`,restoreMessage:`Restore {{count}} archived spools?`,resetUsageMessage:`Reset the "Total Consumed" counter on {{count}} spools? Remaining weight is preserved.`,updateSuccess:`{{count}} spools updated`,updateFailed:`Bulk update failed`,updatePartial:`{{ok}} spools updated, {{failed}} failed`,updateAllFailed:`All {{count}} spool updates failed — selection kept so you can retry`,deleteSuccess:`{{count}} spools deleted`,deleteFailed:`Bulk delete failed`,deletePartial:`{{ok}} spools deleted, {{failed}} failed`,deleteAllFailed:`All {{count}} spool deletions failed — selection kept so you can retry`,archiveSuccess:`{{count}} spools archived`,archiveFailed:`Bulk archive failed`,archivePartial:`{{ok}} spools archived, {{failed}} failed`,archiveAllFailed:`All {{count}} spool archives failed — selection kept so you can retry`,restoreSuccess:`{{count}} spools restored`,restoreFailed:`Bulk restore failed`,restorePartial:`{{ok}} spools restored, {{failed}} failed`,restoreAllFailed:`All {{count}} spool restores failed — selection kept so you can retry`,invalidHex:`Enter 6 hex characters (RRGGBB) or 8 (RRGGBBAA). The field will not be applied otherwise.`},spoolmanMixedContentTitle:`Spoolman can't load over HTTPS — mixed-content blocked by your browser`,spoolmanMixedContentBody:`Bambuddy is served over HTTPS (via your reverse proxy), but your Spoolman URL is still plain HTTP. Browsers block mixed content for security, so the embedded Spoolman UI can't render. Spoolman needs to be reachable over HTTPS for this to work.`,spoolmanMixedContentFixReverseProxy:`Put Spoolman behind the same reverse proxy as Bambuddy (Traefik / Nginx / Caddy) with HTTPS, then update the Spoolman URL in Settings to the new HTTPS address.`,spoolmanMixedContentFixOpenNewTab:`As a workaround, open Spoolman in a new browser tab over HTTP — mixed-content rules only apply to embedded frames, so a standalone tab still works.`,spoolmanOpenInNewTab:`Open Spoolman in a new tab`,labels:{title:`Print spool labels`,selectedCount:`{{count}} selected`,pickSpools:`Pick which spools to print labels for:`,monochrome:`Monochrome (black & white printer)`,monochromeHint:`Drops the colour swatch and widens the text`,startingPosition:`Starting label position`,startingPositionInvalid:`Enter a whole number from 1 to {{capacity}}.`,startingPositionFirst:`Printing starts at position 1.`,startingPositionSkipped:`Positions 1 through {{lastPosition}} will be left blank on the first sheet.`,searchPlaceholder:`Search name, brand, or #ID`,filterByMaterial:`Material:`,allMaterials:`All`,selectVisible:`Select all visible ({{count}})`,deselectVisible:`Deselect visible`,clearAll:`Clear all`,noSpoolsToShow:`No spools to show. Adjust your filter and try again.`,noMatches:`No spools match the current search or filter.`,printOne:`Print label for this spool`,printLabels:`Print labels…`,bulkTitle:`Pick spools to print labels for from the {{count}} currently shown`,noSpoolsTitle:`No spools to label`,error:`Could not generate labels: {{msg}}`,template:`Label size`,preview:`Preview`,previewOf:`Preview of #{{id}}`,previewNoSelection:`Select a spool to see its label.`,previewError:`Could not render the preview: {{msg}}`,previewAlt:`Label preview`,previewHint:`Lines that don't fit on this label size are left out.`,content:`Print on the label`,resetFields:`Reset to default`,format:`Output:`,dpi:`Resolution`,pngHint:`For label printer software that takes images. Match your printer's resolution; several labels come as a ZIP.`,createPdf:`Create PDF`,downloadPng:`Download PNG`,selectedTitle:`Print labels for the {{count}} selected spools`,fields:{brand:`Brand`,material:`Material and subtype`,hex:`Colour code`,name:`Colour or filament name`,location:`Storage location`,materialNumber:`Material number`,temps:`Nozzle temperature`,weight:`Net weight`,note:`Note`,added:`Date added`,qr:`QR code`,spoolId:`Spool ID`},sortBy:{label:`Sort:`,id:`By ID`,color:`By colour`},templates:{amsHolderSmall:{label:`AMS holder — small (74 × 33 mm)`,hint:`Single label per page; matches the printable label from MakerWorld model 752566 (AMS Filament Label Holder).`},amsHolderLarge:{label:`AMS holder — large (75 × 55 mm)`,hint:`Single label per page; fits the cardstock-insert variant of the AMS Filament Label Holder. Roomy enough for swatch, brand, material, ID, and QR code.`},box40x30:{label:`Box label (40 × 30 mm)`,hint:`Single label per page; common DK/Brother roll size, good for filament-bag and storage-bin labels.`},box:{label:`Box label (62 × 29 mm)`,hint:`Single label per page; sized for Brother PT/QL and Dymo small labels.`},averyL7160:{label:`Avery L7160 — A4 sheet (38.1 × 63.5 mm × 21)`,hint:`EU sheet stock; 21 labels per A4 page.`},avery5160:{label:`Avery 5160 — US Letter sheet (25.4 × 66.7 mm × 30)`,hint:`US sheet stock; 30 labels per Letter page.`}}},csv:{importButton:`Import CSV`,exportButton:`Export CSV`,modalTitle:`Import spools from CSV`,selectFile:`Choose a CSV file or drag it here`,dragHint:`Header: material (required), brand, subtype, color_name, rgba, …`,parsing:`Reading file…`,previewError:`Could not read the CSV file`,validCount:`{{count}} valid`,errorCount:`{{count}} error`,skippedCount:`{{count}} skipped`,colRow:`Row`,colStatus:`Status`,colColor:`Color`,colorResolved:`Color filled from catalog`,colorCrossMaterial:`Color taken from a different material — no exact match in catalog`,duplicateExisting:`A spool with this material, brand and color already exists — it will still be imported as a new spool`,spoolmanHint:`In Spoolman mode, use Spoolman's built-in CSV import/export.`,importValidRows:`Import {{count}} valid rows`,noValidRows:`No valid rows`,importing:`Importing…`,importSuccess:`{{count}} spools imported`,importError:`Import failed`,exportError:`Export failed`},addSpool:`Add Spool`,editSpool:`Edit Spool`,copySpool:`Copy Spool`,material:`Material`,selectMaterial:`Select material...`,subtype:`Subtype`,brand:`Brand`,searchBrand:`Search brand...`,useCustomBrand:`Use "{{brand}}"`,useCustomMaterial:`Use custom material: {{material}}`,suggestedOptions:`Suggested`,allOptions:`All`,colorName:`Color Name`,colorNamePlaceholder:`Jade White, Fire Red...`,color:`Color`,hexColor:`Hex Color`,pickColor:`Pick custom color`,labelWeight:`Label Weight`,coreWeight:`Empty Spool Weight`,searchSpoolWeight:`Search spool weight...`,weightUsed:`Used`,currentWeight:`Remaining Weight`,measuredWeight:`Measured Weight`,spoolName:`Spool`,costPerKg:`Cost per kg`,storageLocation:`Storage Location`,temperature:`Temperature`,humidity:`Humidity`,battery:`Battery`,storageLocationPlaceholder:`e.g. Shelf A, Drawer 1`,openInInventory:`Open in Inventory`,measuredWeightError:`Measured weight must be between {{min}}g and {{max}}g.`,slicerFilament:`Slicer Filament`,slicerFilamentName:`Slicer Preset Name`,slicerPreset:`Slicer Preset`,searchPresets:`Search filament presets...`,selectedPreset:`Selected`,noPresetsFound:`No presets found`,tempOverrides:`Temperature Overrides`,note:`Note`,notePlaceholder:`Any additional notes about this spool...`,category:`Category`,categoryPlaceholder:`e.g. Production, Prototype, Client A`,categoryNone:`Uncategorized`,storageLocationNone:`No location set`,lowStockThresholdOverride:`Low-stock threshold (this spool)`,lowStockThresholdOverrideHelp:`Leave blank to use the global threshold ({{global}}%).`,materialNumber:`Material No.`,materialNumberPlaceholder:`e.g. 15`,materialNumberHelp:`Internal purchasing number — shared by all spools of this product. New spools of the same product inherit it.`,materialNumberNone:`No material number`,suppliers:{label:`Suppliers`,none:`No supplier`,addSupplier:`Add supplier…`,searchPlaceholder:`Search suppliers…`,noneLeft:`All suppliers are already assigned`,createNew:`Create "{{name}}"`,createFailed:`Failed to create supplier`,purchaseSource:`Bought here`,purchaseSourceHelp:`Marks where this spool was actually purchased; the other entries are alternative sources.`,articleNumberPlaceholder:`Supplier article no.`,pricePlaceholder:`Quoted price/kg`,priceHelp:`Quoted price at this supplier, for comparing sources — the spool's own cost per kg stays the cost basis.`,help:`Where this product can be bought. The highlighted entry is where this spool was purchased.`,saveFailed:`Failed to save supplier assignments`,title:`Suppliers`,description:`Manage where you buy filament — distinct from brand, which is who made it. Assign suppliers to spools in the spool dialog; a supplier that is still assigned to spools cannot be deleted.`,search:`Search suppliers...`,addNew:`Add new supplier`,namePlaceholder:`Name (e.g. Filament24)`,websitePlaceholder:`Website / shop URL`,customerNumberPlaceholder:`Customer no.`,notePlaceholder:`Note`,nameRequired:`Name is required`,duplicateName:`A supplier with this name already exists`,customerNumber:`Customer no.`,spools:`Spools`,noMatch:`No suppliers match your search`,empty:`No suppliers yet`,added:`Supplier added`,addFailed:`Failed to add supplier`,updated:`Supplier updated`,updateFailed:`Failed to update supplier`,deleted:`Supplier deleted`,deleteFailed:`Failed to delete supplier`,deleteBlocked:`Cannot delete: still assigned to {{count}} spool(s)`,loadFailed:`Failed to load suppliers`,deleteTitle:`Delete Supplier`,deleteConfirm:`Delete "{{name}}"?`,deleteConfirmReferenced:`"{{name}}" is assigned to {{count}} spool(s). Deleting is blocked until those assignments are removed.`},clearRfid:`Clear RFID Tag`,rfidCleared:`RFID tag cleared`,archive:`Archive`,restore:`Restore`,noSpools:`No spools yet. Add your first spool to get started.`,noAvailableSpools:`No spools available. Add a spool to your inventory or unassign one from another slot first.`,kProfiles:`K-Profiles`,addKProfile:`Add K-Profile`,assignSpool:`Assign Spool`,unassignSpool:`Unassign`,assignSuccess:`Spool assigned and AMS slot configured`,assignPendingInsert:`Assigned. Slot will configure when you insert the spool.`,assignFailed:`Failed to assign spool`,selectSpool:`Select a spool to assign to this slot`,assigned:`Assigned`,assigning:`Assigning...`,searchSpools:`Search spools...`,showAllSpools:`Show all spools`,spoolmanSpools:`Spoolman Spools`,allMaterials:`All Materials`,filterByBrand:`Filter by brand...`,showArchived:`Show archived`,quickAdd:`Quick Add (Stock)`,quantity:`Quantity`,stock:`Stock`,configured:`Configured`,spoolsCreated:`{{count}} spools created`,spoolsPartiallyCreated:`{{created}} of {{total}} spools created (some failed)`,spoolCreated:`Spool created`,spoolUpdated:`Spool updated`,spoolDeleted:`Spool deleted`,deepLinkSpoolNotFound:`Spool not found`,deepLinkFetchFailed:`Could not load spool — try again`,spoolArchived:`Spool archived`,spoolRestored:`Spool restored`,kProfileSaveFailed:`K-profile settings could not be saved`,syncWeightSpoolNotFound:`Spool not found — it may have been deleted`,syncWeightSpoolmanUnreachable:`Spoolman is unreachable — try again later`,syncWeightFailed:`Failed to sync weight`,spoolmanUnreachable:`Spoolman is not reachable — please try again later`,deleteSpoolNotFound:`Spool not found — it may have already been deleted`,deleteFailed:`Failed to delete spool`,archiveSpoolNotFound:`Spool not found — it may have already been deleted`,archiveFailed:`Failed to archive spool`,restoreSpoolNotFound:`Spool not found — it may have already been deleted`,restoreFailed:`Failed to restore spool`,saveFailed:`Failed to save changes`,tagClearFailed:`Failed to clear tag`,deleteConfirm:`Are you sure you want to delete this spool? This cannot be undone.`,archiveConfirm:`Are you sure you want to archive this spool?`,advancedSettings:`Advanced Settings`,filamentInfoTab:`Filament Info`,paProfileTab:`PA Profile`,colorAndCostTab:`Color & Cost`,printersTab:`Printers`,filamentInfo:`Filament`,additional:`Additional`,loadingPresets:`Loading cloud presets...`,cloudConnected:`Cloud connected`,cloudNotConnected:`Cloud not connected (using defaults)`,recentColors:`Recent`,searchColors:`Search colors...`,searchResults:`Search results`,allColors:`All colors`,commonColors:`Common colors`,showLess:`Show less`,showAll:`Show all`,noColorsFound:`No colors match your search`,noResults:`No matches found`,extraColorsLabel:`Extra colors`,extraColorsPlaceholder:`EC984C,#6CD4BC,A66EB9,D87694`,extraColorsHint:`Paste 2 to 8 hex stops, separated by commas. Renders as a gradient.`,extraColorsInvalid:`Ignored invalid hex: {{tokens}}`,colorEffectLabel:`Effect`,colorEffect:{none:`None`,sparkle:`Sparkle`,wood:`Wood`,marble:`Marble`,glow:`Glow`,matte:`Matte`,silk:`Silk`,galaxy:`Galaxy`,rainbow:`Rainbow`,metal:`Metal`,translucent:`Translucent`,gradient:`Gradient`,dualColor:`Dual Color`,triColor:`Tri Color`,multicolor:`Multicolor`},selectMaterialFirst:`Please select a material first in the Filament Info tab.`,noPrintersConfigured:`No printers configured. Add printers to use PA profiles.`,matchingFilter:`Matching`,anyBrand:`Any brand`,anyVariant:`Any variant`,autoSelect:`Auto-select`,matches:`matches`,match:`match`,noMatches:`No matches`,connected:`Connected`,offline:`Offline`,printerOffline:`Printer is offline. Connect to view calibration profiles.`,noKProfilesMatch:`No K-profiles match the selected filament.`,leftNozzle:`Left Nozzle`,rightNozzle:`Right Nozzle`,profilesSelected:`calibration profile(s) selected`,filamentPreset:`Filament preset`,presetUseSpoolDefault:`Use the spool's preset`,presetInherited:`inherited`,presetOverride:`override`,presetNeedsModel:`This printer has not reported its model yet, so it cannot have its own preset.`,autoMatchPresets:`Auto-match`,autoMatchPresetsHint:`Find the variant of this spool's preset that names each model`,kProfilesPerPrinter:`K profiles`,kProfileNotSet:`Not set`,kProfileFlowMismatch:`This profile was measured on a {{profile}} nozzle but a {{fitted}} nozzle is fitted, so it will not be applied`,nozzle:`Nozzle`,unknownModel:`Unknown model`,onePrinter:`1 printer`,nPrinters:`{{n}} printers`,filamentPresetsLoadFailed:`Could not load this spool's per-model presets`,filamentPresetSaveFailed:`Could not save the per-model presets`,totalInventory:`Total Inventory`,totalConsumed:`Total Consumed`,byMaterial:`By Material`,inPrinter:`In Printer`,lowStock:`Low Stock`,sinceTracking:`Since tracking started`,resetConsumedCounter:`Reset counter`,resetConsumedCounterTooltip:`Zero the consumed-grams counter for this spool. Remaining weight is not changed.`,resetConsumedCounterConfirm:`Reset this spool's consumed-grams counter to 0? Future prints will track from zero again. The spool itself, its remaining weight calculation, and your settings are not changed.`,resetAllConsumedCounters:`Reset all counters`,resetAllConsumedCountersTooltip:`Zero the consumed-grams counter on every spool. Remaining weights are not changed.`,resetAllConsumedCountersConfirm:`Reset the consumed-grams counter to 0 on all {{count}} spools (archived ones included)? This clears the "Total Consumed" stat so future prints track from zero. Spools and remaining weights are not changed.`,consumedCounterReset:`Counter reset`,allConsumedCountersReset:`Counter reset for {{count}} spool(s)`,resetConsumedCounterFailed:`Failed to reset counter`,loadedInAms:`Loaded in AMS/Ext`,remaining:`Remaining`,weightCheck:`Weight Check`,lastWeighed:`Last weighed`,neverWeighed:`Never weighed`,search:`Search spools...`,showing:`Showing`,to:`to`,of:`of`,show:`Show`,spools:`spools`,spool:`spool`,page:`Page`,noSpoolsMatch:`No results found`,noSpoolsMatchDesc:`Try adjusting your search or filters to find what you're looking for.`,active:`Active`,archived:`Archived`,all:`All`,used:`Used`,new:`New`,clearFilters:`Clear filters`,table:`Table`,cards:`Cards`,net:`Net`,groupSimilar:`Group`,groupedSpools:`{{count}} identical spools`,groupedRows:`rows`,columns:`Columns`,configureColumns:`Configure Columns`,configureColumnsDesc:`Drag to reorder columns or use arrows. Toggle visibility with the eye icon.`,visible:`visible`,reset:`Reset`,cancel:`Cancel`,applyChanges:`Apply Changes`,moveUp:`Move up`,moveDown:`Move down`,hideColumn:`Hide column`,showColumn:`Show column`,linkToSpool:`Link to Spool`,tagLinked:`Tag linked to spool`,tagLinkFailed:`Failed to link tag`,tagAlreadyLinked:`Tag already linked to spool #{{id}}`,unknownTag:`Unknown RFID tag detected`,usageHistory:`Usage History`,noUsageHistory:`No usage recorded yet`,printName:`Print Name`,weightConsumed:`Weight Consumed`,clearHistory:`Clear`,historyCleared:`Usage history cleared`,fillSourceLabel:`(Inv)`,lowStockThresholdError:`Threshold must be between 0.1 and 99.9`,assignMismatchTitle:`Material mismatch`,assignMismatchMessage:`The selected spool material "{{spoolMaterial}}" does not match the tray material "{{trayMaterial}}" for {{location}}. Assign anyway?`,assignMismatchConfirm:`Assign Anyway`,assignPartialMismatchMessage:`The spool material "{{spoolMaterial}}" is similar to but not exactly matching "{{trayMaterial}}" in {{location}}. Do you want to proceed?`,assignProfileMismatchMessage:`The spool profile "{{spoolProfile}}" does not match the tray profile "{{trayProfile}}" in {{location}}. Do you want to proceed?`,assignReconfigureNote:`The AMS slot will be reconfigured to use the spool's profile.`,spoolmanFilamentCatalog:`Spoolman Filament Catalog`,pickFromSpoolmanCatalog:`Pick from Spoolman catalog…`,spoolmanFilamentSelected:`Filament selected from Spoolman catalog`,spoolmanFilamentUnlinked:`Filament catalog link cleared`,noSpoolmanFilaments:`No filaments found in Spoolman catalog`,spoolmanFilamentColorSwatch:`Filament color`,spoolmanCatalogLoadFailed:`Failed to load Spoolman filament catalog`},timelapse:{title:`Timelapse`,create:`Create Timelapse`,download:`Download`,delete:`Delete`,preview:`Preview`,frameRate:`Frame Rate`,quality:`Quality`,processing:`Processing...`,noTimelapses:`No timelapses available`},ams:{title:`AMS`,slot:`Slot`,empty:`Empty`,emptySlot:`Empty slot`,slotEmpty:`Empty`,slotUnconfigured:`?`,emptySlotReset:`No filament assigned`,unknown:`Unknown`,humidity:`Humidity`,temperature:`Temperature`,filamentType:`Filament Type`,filamentColor:`Color`,remaining:`Remaining`,history:`AMS History`,noHistory:`No history available`,configureSlot:`Configure Slot`,externalSpool:`External Spool`,profile:`Profile`,kFactor:`K Factor`,kFactorShort:`K`,fill:`Fill`,configure:`Configure`,used:`used`,remainingUnit:`remaining`},printModal:{variants:{editNote:`These alternatives were set when the job was queued. Cancel and re-queue to change them.`,title:`Printer alternatives`,help:`One job, one queue slot. The first matching printer to free up runs its file.`,unknownModel:`Unknown model`,plateFor:`Plate for {{filename}}`,moveUp:`Move up`,moveDown:`Move down`,queued:`Queued with {{count}} alternatives`},selectPrinter:`Select Printer`,selectPlate:`Select Plate`,filamentMapping:`Filament Mapping`,useArchiveMapping:`Mapping`,useArchiveMappingTooltip:`Select every slot from the AMS mapping saved with this archive (from the slicer), instead of matching by type/color.`,clickToChangeSlot:`Click to change slot assignment`,reRead:`Re-read`,plateN:`Plate {{n}}`,plateFilamentsUnreadable:`The filaments of a selected plate could not be read, so it can't be mapped. Deselect it to queue the others.`,totalCost:`Total cost:`,slotRemainingShort:` - {{grams}}g left`,printSettings:`Print Settings`,bedLeveling:`Bed Leveling`,flowCalibration:`Flow Calibration`,vibrationCalibration:`Vibration Calibration`,layerInspection:`First Layer Inspection`,timelapse:`Timelapse`,cancel:`Cancel`,noPrintersAvailable:`No printers available`,printerBusy:`Printer is busy`,printerOffline:`Printer is offline`,sameTypeDifferentColor:`Same type, different color`,filamentTypeNotLoaded:`Filament type not loaded`,statusReady:`Ready`,statusColorMismatch:`Color mismatch`,statusTypeNotFound:`Type not found`,requiredTooltip:`Required: {{name}} - {{color}}`,manuallySelected:`Manually selected`,autoMatched:`Auto-matched`,selectSlot:`Select slot`,exactColorMatch:`Exact colour match`,slotForFilament:`Printer slot for {{name}}`,overrideForFilament:`Filament override for {{name}}`,sameTypeDifferentColorDetail:`Same type, different color: needs {{required}}, slot has {{loaded}}`,requiredTypeNotInPrinter:`Required filament type not found in printer.`,whenToPrint:`When to print`,asap:`ASAP`,queue:`Queue`,schedule:`Schedule`,dateTime:`Date & Time`,invalidDateTime:`Please enter a valid date and time`,openCalendar:`Open calendar`,requireManualStart:`Require manual start`,awaitingReviewNote:`Your print waits for review: it starts once someone who manages the queue starts it.`,requirePreviousSuccess:`Only start if previous print succeeded`,autoOffAfter:`Power off printer when done`,helpAsap:`Print will be added to the top of the queue and start as soon as an eligible printer is idle.`,helpSchedule:`Print will start at the scheduled time if the printer is idle. If busy, it will wait until the printer becomes available.`,helpQueue:`Print will be added to the back of the queue.`,leftNozzle:`L`,rightNozzle:`R`,leftNozzleTooltip:`Left nozzle`,rightNozzleTooltip:`Right nozzle`,ftsSameInletHint:`All filaments for this print are on Filament Track Switch IN-{{inlet}}. Switching between filaments on the same inlet is slower — move one to an AMS on the other inlet to speed it up.`,rackPosition:`Rack position`,rackPositionTooltip:`Which nozzle on the rack prints this filament. Positions are numbered as on the printer.`,rackEmptyPosition:`This rack position is empty`,rackWrongNozzle:`Holds a {{has}} nozzle; this filament needs {{needs}}`,filamentOverride:`Filament Override`,filamentOverrideHint:`Optionally override filaments for model-based assignment. The scheduler will match against your selected filaments instead of the original 3MF values.`,originalFilament:`Original`,overrideWith:`Override with`,resetToOriginal:`Reset to original`,insufficientFilamentTitle:`Not enough filament`,waitingForAmsStatus:`Waiting for AMS status from {{printer}}…`,insufficientFilamentMessage:`Some assigned spools have less filament remaining than this print needs:`,insufficientFilamentLine:`{{printer}} - {{slot}}: needs {{required}}g, remaining {{remaining}}g`,insufficientFilamentLinePooled:`{{printer}} - {{slot}}: needs {{required}}g, {{remaining}}g available across matching spools (AMS Filament Backup)`,printAnyway:`Print anyway`,forceColorMatch:`Force color match`,staggerPrinterStarts:`Stagger printer starts`,staggerGroupSize:`Group size`,staggerInterval:`Interval (min)`,staggerPreview:`{{printers}} printers → {{groups}} groups of {{size}}, starting every {{interval}} min`,staggerLastGroup:`last group: {{count}}`,staggerTotal:`total: {{minutes}} min`,staggerToPrinters:`Stagger to {{count}} printers`,gcodeInjection:`Inject auto-print G-code`,insufficientBudget:`Insufficient Budget`,unlimitedNoBudget:`Unlimited – no budget limit is set.`,noPrintableCostCenters:`No active cost center is available for printing. Ask an administrator to grant you print access.`,askForOutcome:`Ask for Outcome`,askForOutcomeTitle:`Ask how the print came out after it completes`},backup:{includesEncryptionKey:`Local backups include the MFA encryption key file (DATA_DIR/.mfa_encryption_key) so a backup ZIP is self-contained. Treat the ZIP as sensitive — anyone with the file can decrypt the OIDC client secrets and TOTP secrets stored inside.`,title:`Backup & Restore`,createBackup:`Create Backup`,restoreBackup:`Restore Backup`,restoreDescription:`Replace all data from a backup file`,downloadBackup:`Download Backup`,uploadBackup:`Upload Backup`,lastBackup:`Last Backup`,autoBackup:`Auto Backup`,backupNow:`Backup Now`,restoreWarning:`Warning: Restoring a backup will overwrite all current data.`,includeArchives:`Include Archives`,includeSettings:`Include Settings`,includeProfiles:`Include Profiles`,backupSuccess:`Backup created successfully`,restoreSuccess:`Backup restored successfully`,backupFailed:`Backup failed`,restoreFailed:`Restore failed`,restoreNote:`Virtual Printer will be stopped during restore`,githubBackup:`Git Backup`,enabled:`Enabled`,cloudLoginRequired:`Bambu Cloud login required. Sign in under Profiles → Cloud Profiles to enable GitHub backup.`,cloudLoginRequiredShort:`Cloud login required`,githubDescription:`Automatically sync your profiles to a private GitHub repository for backup and version history.`,repoIsPrivate:`Repository is private — safe to back up to.`,repoIsPublicWarning:`Repository is PUBLIC. Bambuddy backups include MQTT credentials, Home Assistant tokens, Prometheus tokens, your Bambu Cloud email, and printer access codes via K-profiles. Saving is blocked until you make the repository private in your provider's settings.`,repoVisibilityUnknown:`Could not determine repository visibility. Bambuddy refuses to back up to anything not confirmed private; saving will be blocked.`,repositoryUrl:`Repository URL`,repoUrlPlaceholderGitHub:`https://github.com/username/repo-name`,repoUrlPlaceholderGitea:`https://gitea.example.com/username/repo-name`,repoUrlPlaceholderForgejo:`https://forgejo.example.com/username/repo-name`,repoUrlPlaceholderGitLab:`https://gitlab.com/username/repo-name`,allowInsecureHttp:`Allow insecure HTTP`,allowInsecureHttpHint:`Enable for self-hosted instances on private networks without TLS`,personalAccessToken:`Personal Access Token`,tokenSaved:`(saved)`,enterNewToken:`Enter new token to update`,tokenHintGitHub:`Fine-grained token with Contents read and write access, or a classic token with the repo scope.`,tokenHintGitLab:`Token with the api scope, or read_repository and write_repository together.`,tokenHintGitea:`Token with the write:repository scope.`,tokenHintForgejo:`Token with the write:repository scope. A token limited to this one repository is enough.`,branch:`Branch`,provider:`Git Provider`,providerGitHub:`GitHub`,providerGitLab:`GitLab`,providerGitea:`Gitea`,providerForgejo:`Forgejo`,manualOnly:`Manual only`,hourly:`Hourly`,daily:`Daily`,weekly:`Weekly`,includeInBackup:`Include in backup`,kProfiles:`K-Profiles`,kProfilesDescription:`Pressure advance calibration from connected printers`,noPrintersConnected:`No printers connected`,printersConnected:`{{connected}}/{{total}} connected`,cloudProfiles:`Cloud Profiles`,cloudProfilesDescription:`Filament, printer, and process presets from Bambu Cloud and Orca Cloud`,cloudProfilesAccounts:`Connected accounts — Bambu Cloud: {{bambu}}, Orca Cloud: {{orca}}`,appSettings:`App Settings`,appSettingsDescription:`Bambuddy configuration (complete database)`,spoolInventory:`Spool Inventory`,spoolInventoryDescription:`Filament spools, usage history, and cost tracking`,printArchives:`Print Archives`,printArchivesDescription:`Print history metadata (no gcode/3MF files)`,lastBackupAt:`Last backup:`,noBackupsYet:`No backups yet`,next:`Next:`,startingBackup:`Starting backup...`,test:`Test`,enableBackup:`Enable Backup`,testConnection:`Test Connection`,enterRepoUrl:`Enter repository URL`,enterRepoAndToken:`Enter repository URL and access token`,repoRequired:`Repository URL is required`,tokenRequired:`Access token is required`,githubBackupEnabled:`GitHub backup enabled`,tokenUpdated:`Token updated`,settingsSaved:`Settings saved`,failedToSave:`Failed to save: {{message}}`,backupCompleteFiles:`Backup complete - {{count}} files updated`,backupSkippedNoChanges:`Backup skipped - no changes`,backupFailed2:`Backup failed: {{message}}`,clearedLogs:`Cleared {{count}} logs`,failedToClearLogs:`Failed to clear logs: {{message}}`,restoreFromGit:{button:`Restore from Git`,title:`Restore from Git Backup`,subtitle:`Pick a commit and choose what to restore`,commitLabel:`Backup commit`,latestCommit:`Latest backup (branch tip)`,categoriesLabel:`What to restore`,inspecting:`Reading backup contents...`,itemCount:`{{count}} in backup`,overwriteLabel:`Overwrite existing entries`,overwriteOn:`Existing entries will be updated from the backup.`,overwriteOff:`Only missing entries are added; existing ones are left untouched.`,selectedCount:`{{count}} selected`,restoring:`Restoring...`,confirmTitle:`Restore from backup?`,confirmMessage:`The selected categories will be restored from this commit. Missing entries are added; existing entries stay as they are.`,confirmMessageOverwrite:`The selected categories will be restored from this commit, overwriting entries that already exist locally. This cannot be undone.`,kprofilesOverwriteCaveat:`K-profiles are the exception: writing a slot always replaces the calibration on the printer.`,tally:`{{restored}} restored, {{skipped}} skipped, {{failed}} failed`,reloadHint:`Reload Bambuddy so the restored data appears everywhere.`,partialHint:`The categories listed above finished and are on disk. Any that are missing did not run.`,failed:`Restore failed.`,loadFailed:`Could not read the backup repository.`,details:{notPresent:`Not present in this backup commit`,unreadableJson:`Unreadable JSON: {{paths}}`,settingsNoPayload:`No settings in payload`,settingsCredentialsWillSkip:`{{count}} credential-like key(s) will be skipped`,settingsCompanionWillSkip:`{{count}} credential-like key(s) will be skipped, and {{companion}} switch(es) that depend on them will be left off`,settingsCompanionOnlyWillSkip:`{{companion}} switch(es) will be left off - the credential each one needs cannot be restored from a backup`,spoolsUsageCount:`including {{count}} usage record(s)`,archivesMetadataOnly:`Metadata only - 3MF files and thumbnails are not in a Git backup`,kprofilesPrinterCount:`across {{count}} printer(s)`},notes:{noData:`No data of this kind in this backup`,archivesPrinterMissing:`Some archives referenced printers that no longer exist - link cleared`,archivesProjectMissing:`Some archives referenced projects that no longer exist - link cleared`,archivesOwnerCleared:`Some archives referenced users that no longer exist - owner cleared, so they are visible only to users with the archives:read_all permission until an admin reassigns them`,archivesOwnerUnmatched:`Some archives name an owner this instance does not have - owner cleared rather than guessed from the backup's user id, so they are visible only to users with the archives:read_all permission until an admin reassigns them`,archivesOwnerUnknown:`Some archives were restored without an owner - this backup does not record one, so they are visible only to users with the archives:read_all permission until an admin reassigns them`,archivesUndeleted:`Archive(s) deleted since the backup are visible again - overwrite was on`,archivesMetadataOnly:`Restored archives carry metadata only - the 3MF and thumbnail files are not in a Git backup`,spoolUsageUnresolved:`{{count}} usage record(s) skipped - their spool is not in this backup's spool list, so there is nothing to attach them to.`,spoolUsageUnlinked:`{{count}} usage record(s) restored without their print-history link - select Print archives alongside Spool inventory to keep it.`,spoolTagKept:`{{count}} spool tag(s) left as they are - the backup would have cleared a tag that has since been scanned, or moved one onto a second spool.`,settingsCredentialsSkipped:`{{count}} credential-like key(s) skipped - re-enter secrets manually`,settingsAuthSkipped:`{{count}} authentication setting(s) skipped - change those in Settings > Authentication so the lockout checks still run`,settingsCompanionSkipped:`{{keys}} left switched off - the credential each one needs cannot be restored from a backup and this instance has none stored, so switching them on would leave the integration unauthenticated`,settingsMqttRelayFailed:`MQTT settings restored, but the relay could not be reconnected - restart Bambuddy`,kprofilesAlwaysOverwrite:`K-profiles always overwrite the matching slot on the printer`,kprofilesAckUnreliable:`A printer that does not answer still counts as restored - verify the profiles on the printer`,kprofilesPrinterMissing:`No printer with serial {{serial}} - skipped`,kprofilesPrinterOffline:`{{printer}} ({{serial}}) is not connected - skipped`,kprofilesUnknownNozzle:`Unexpected nozzle diameter {{nozzle}} for {{serial}} - sent as-is`,kprofilesUnmatched:`{{count}} profile(s) for {{nozzle}} had no counterpart on {{printer}} - added as new profiles`,kprofilesSendFailed:`Failed to send {{nozzle}} profiles to {{printer}} ({{serial}})`,kprofilesRefused:`{{printer}} ({{serial}}) refused the {{nozzle}} profiles: {{reason}}`,kprofilesStepFailed:`The K-profile step could not be completed - {{reason}}. Anything restored before it is still saved.`}},history:`History`,clear:`Clear`,date:`Date`,status:`Status`,trigger:`Type`,triggers:{manual:`Backup (manual)`,scheduled:`Backup (scheduled)`,restore:`Restore`},commit:`Commit`,localBackup:`Local Backup`,localBackupDescription:`Create a complete backup of your Bambuddy data including the database, archives, uploads, and all files.`,downloadBackupLabel:`Download Backup`,completeBackupZip:`Complete backup: database + all files (ZIP)`,download:`Download`,preparingBackup:`Preparing backup...`,creatingArchive:`Creating backup archive... This may take a while for large archives.`,downloadingFile:`Downloading backup file...`,backupDownloaded:`Backup downloaded successfully`,failedToCreateBackup:`Failed to create backup: {{message}}`,restore:`Restore`,restoreReplacesAll:`Restore replaces all data.`,restoreReplacesAllDetail:`Your current database and files will be completely replaced. A restart is required after restore.`,restoreConfirmTitle:`Restore Backup`,restoreConfirmMessage:`Are you sure you want to restore from "{{filename}}"? This will completely replace your current database and all files. The application will need to be restarted after restore.`,restoreConfirmButton:`Restore Backup`,uploadingFile:`Uploading backup file...`,backupRestoredRestart:`Backup restored. Please restart Bambuddy.`,failedToRestore:`Failed to restore backup. Please check the file format.`,reloadNow:`Reload Now`,creatingBackup:`Creating Backup`,restoringBackup:`Restoring Backup`,preparing:`Preparing...`,processing:`Processing...`,doNotClosePage:`Please do not close this page or navigate away. This operation may take several minutes for large backups.`,restoring:`Restoring...`,restoreComplete:`Restore Complete`,restoreFailed2:`Restore Failed`,importSettings:`Import settings from a backup file`,pleaseWaitRestoring:`Please wait while your data is being restored`,selectBackupFile:`Click to select backup file (.json or .zip)`,duplicateHandling:`How duplicate handling works:`,matchPrinters:`Printers`,matchPrintersBy:`matched by serial number`,matchSmartPlugs:`Smart Plugs`,matchSmartPlugsBy:`matched by IP address`,matchNotificationProviders:`Notification Providers`,matchNotificationProvidersBy:`matched by name`,matchFilaments:`Filaments`,matchFilamentsBy:`matched by name + type + brand`,matchArchives:`Archives`,matchArchivesBy:`matched by content hash (always skipped)`,matchPendingUploads:`Pending Uploads`,matchPendingUploadsBy:`matched by filename`,matchSettingsTemplates:`Settings & Templates`,matchSettingsTemplatesBy:`always overwritten`,replaceExisting:`Replace existing data`,keepExisting:`Keep existing data`,overwriteDescription:`Overwrite items that already exist with backup data`,keepDescription:`Only restore items that don't already exist`,overwriteCaution:`Caution:`,overwriteWarning:`Overwriting will replace your current configurations with data from the backup. Printer access codes are never overwritten for security.`,cancel:`Cancel`,processingBackup:`Processing backup file...`,itemsRestored:`Items Restored`,itemsSkipped:`Items Skipped`,restored:`Restored`,skippedAlreadyExist:`Skipped (already exist)`,filesCategory:`Files (3MF, thumbnails, etc.)`,andMore:`...and {{count}} more`,newApiKeysGenerated:`New API Keys Generated`,keysShownOnce:`These keys are only shown once. Copy them now!`,copy:`Copy`,noDataFound:`No data was found to restore in the backup file.`,close:`Close`,scheduledBackup:`Scheduled Backups`,scheduledBackupDescription:`Automatically create backup snapshots on a schedule. Output directory can be mounted to a NAS or external storage.`,frequency:`Frequency`,backupTime:`Time`,retention:`Retention`,retentionDescription:`Number of backups to keep`,outputPath:`Output Path`,outputPathPlaceholder:`Default: {{path}}`,outputPathDescription:`Leave empty for default location`,runNow:`Run Now`,backupFiles:`Backup Files`,noScheduledBackups:`No backups yet`,deleteBackup:`Delete`,deleteBackupConfirm:`Delete this backup file?`,backupRunning:`Backup in progress...`,scheduledBackupComplete:`Backup completed successfully`,scheduledBackupFailed:`Backup failed`,nextBackup:`Next backup`,backupSize:`Size`,localTimeHint:`Local time ({{tz}})`,defaultPathLabel:`Default:`,pathCheck:{title:`Bambuddy cannot write to this directory`,howToFix:`How to fix:`,sandboxed:`The Bambuddy service cannot write to {{path}}. Its systemd unit runs with ProtectSystem=strict, which makes every directory outside the install, data and log directories read-only for the service - even one you can write to from your own shell.`,read_only:`{{path}} is on a read-only filesystem.`,permission_denied:`Bambuddy is not allowed to write to {{path}}. Check the directory owner and permissions.`,no_space:`The filesystem holding {{path}} is full.`,not_a_directory:`{{path}} exists but is not a directory.`,missing:`{{path}} does not exist and could not be created.`,error:`Bambuddy cannot write to {{path}}.`,ephemeralTitle:`These backups will not survive a container restart`,container_ephemeral:`{{path}} is inside the Bambuddy container, not on the host. Backups written there are lost when the container is recreated. Mount the directory from the host:`},categories:{settings:`Settings`,notification_providers:`Notification Providers`,notification_templates:`Notification Templates`,smart_plugs:`Smart Plugs`,printers:`Printers`,filaments:`Filaments`,maintenance_types:`Maintenance Types`,archives:`Archives`,projects:`Projects`,pending_uploads:`Pending Uploads`,external_links:`External Links`,api_keys:`API Keys`}},tags:{title:`Tags`,addTag:`Add Tag`,editTag:`Edit Tag`,deleteTag:`Delete Tag`,tagName:`Tag Name`,tagColor:`Tag Color`,noTags:`No tags`,deleteConfirm:`Are you sure you want to delete this tag?`,manageTags:`Manage Tags`},uploadModal:{title:`Upload 3MF Files`,dragDrop:`Drag & drop .3mf files here`,or:`or`,browseFiles:`Browse Files`,extractionInfo:`The printer model will be automatically extracted from the 3MF file metadata.`,uploaded:`uploaded`,failed:`failed`,uploading:`Uploading...`,upload:`Upload`,uploadFailed:`Upload failed`},confirmOutcome:{title:`How did your print come out?`,good:`Good`,reject:`Reject`,later:`Ask me later`,noPhoto:`No finish photo available`,savedGood:`Marked as good part`,savedReject:`Marked as rejected`,saveFailed:`Could not save the verdict`,rejectReason:`Reject reason (optional)`,noReason:`No reason`,saveReject:`Save`,rejectAndReprint:`Print again`,alreadyGood:`Already confirmed as a good part.`,alreadyRejected:`Already marked as rejected.`,cardPrompt:`How did it come out?`,sources:{dialog:`Recorded in the app.`,link:`Recorded with a one-tap link.`,plateClear:`Recorded when the plate was cleared.`,printerCard:`Recorded from the printer card.`,api:`Recorded through the API.`,reaction:`Recorded with a reaction in chat.`}},editArchive:{title:`Edit Archive`,name:`Name`,namePlaceholder:`Print name`,printer:`Printer`,noPrinter:`No printer`,project:`Project`,noProject:`No project`,itemsPrinted:`Items Printed`,itemsPrintedHelp:`Number of items produced in this print job. Use 0 if the whole plate was ruined.`,filamentUsed:`Filament used (g)`,filamentUsedPlaceholder:`e.g. 46.16`,filamentUsedHelp:`Set this by hand when a print archived without its 3MF, so it still counts towards the filament totals. Rescanning an archive that has its 3MF reads the figure back from the file.`,notes:`Notes`,notesPlaceholder:`Add notes about this print...`,externalLink:`External Link`,externalLinkPlaceholder:`https://printables.com/model/...`,externalLinkHelp:`Link to Printables, Thingiverse, or other source`,tags:`Tags`,tagsPlaceholder:`Add tags...`,addMoreTags:`Add more tags...`,matchingTags:`Matching "{{query}}"`,existingTags:`Existing tags`,clickToAdd:`(click to add)`,status:`Status`,userVerdict:`Outcome Verdict`,verdicts:{none:`Not set`,good:`Good part`,reject:`Rejected`},failureReason:`Failure Reason`,selectReason:`Select reason...`,photos:`Photos of Printed Result`,photosHelp:`Click + to add photos of your printed result`,printResult:`Print result`,saving:`Saving...`,failureReasons:{adhesionFailure:`Adhesion failure`,spaghettiDetached:`Spaghetti / Detached`,layerShift:`Layer shift`,cloggedNozzle:`Clogged nozzle`,filamentRunout:`Filament runout`,warping:`Warping`,stringing:`Stringing`,underExtrusion:`Under-extrusion`,powerFailure:`Power failure`,userCancelled:`User cancelled`,noStatusUpdate:`No status update received`,other:`Other`},statuses:{completed:`Completed`,failed:`Failed`,aborted:`Cancelled`,printing:`Printing`}},kProfiles:{title:`K-Profiles`,noPrintersConfigured:`No Printers Configured`,addPrinterInSettings:`Add a printer in Settings to manage K-profiles`,noActivePrinters:`No Active Printers`,enablePrinterConnection:`Enable a printer connection to view its K-profiles`,loadingProfiles:`Loading K-Profiles...`,printerOffline:`Printer Offline`,printerOfflineDesc:`The selected printer is not connected. Power it on to view K-profiles.`,noMatchingProfiles:`No Matching Profiles`,noMatchingProfilesDesc:`No profiles match your search criteria`,noKProfiles:`No K-Profiles`,noKProfilesDesc:`No pressure advance profiles found for {{diameter}}mm nozzle`,createFirstProfile:`Create First Profile`,printer:`Printer`,nozzle:`Nozzle`,refresh:`Refresh`,addProfile:`Add Profile`,export:`Export`,import:`Import`,select:`Select`,selectAll:`Select All`,delete:`Delete`,searchPlaceholder:`Search by name or filament...`,allExtruders:`All Extruders`,leftOnly:`Left Only`,rightOnly:`Right Only`,allFlow:`All Flow`,hfOnly:`HF Only`,sOnly:`S Only`,sortName:`Sort: Name`,sortKValue:`Sort: K-Value`,sortFilament:`Sort: Filament`,leftExtruder:`Left Extruder`,rightExtruder:`Right Extruder`,modal:{addTitle:`Add K-Profile`,editTitle:`Edit K-Profile`,profileName:`Profile Name`,profileNamePlaceholder:`My PLA Profile`,kValue:`K-Value`,kValuePlaceholder:`0.020`,kValueHelp:`Typical range: 0.01 - 0.06 for PLA, 0.02 - 0.10 for PETG`,filament:`Filament`,selectFilament:`Select filament...`,source:{local:`Imported`,orcaCloud:`Orca Cloud`,bambuCloud:`Bambu Cloud`,builtin:`Built-in`},noFilamentsHelp:`No filaments available. Sign in to Bambu Cloud, or import presets under Profiles → Local Profiles.`,searchFilaments:`Search filaments...`,noFilamentMatches:`No filament matches that search`,flowType:`Flow Type`,highFlow:`High Flow`,standard:`Standard`,nozzleSize:`Nozzle Size`,extruder:`Extruder`,extruders:`Extruders`,left:`Left`,right:`Right`,notes:`Notes (stored locally)`,notesPlaceholder:`Add notes about this profile...`,notesHelp:`Notes are saved in Bambuddy, not on the printer`,syncing:`Syncing with printer...`,savingExtruder:`Saving to extruder {{current}}/{{total}}...`,pleaseWait:`Please wait`},deleteConfirm:{title:`Delete Profile`,cannotUndo:`This cannot be undone`,message:`Are you sure you want to delete "{{name}}" from the printer?`},bulkDelete:{title:`Delete Profiles`,cannotUndo:`This cannot be undone`,message:`Are you sure you want to delete {{count}} selected profiles from the printer?`},toast:{profileSaved:`K-profile saved`,profilesSaved:`K-profile saved to {{count}} extruders`,selectAtLeastOneExtruder:`Please select at least one extruder`,selectFilament:`Select a filament first`,filamentNotResolvable:`No Bambu filament ID for {{name}} — the printer cannot store a profile for it`,profileDeleted:`K-profile deleted`,profilesDeleted:`Deleted {{count}} profiles`,exportedProfiles:`Exported {{count}} profiles`,importedProfiles:`Imported {{count}} of {{total}} profiles`,noProfilesToExport:`No profiles to export`,invalidFileFormat:`Invalid file format`,failedToParseImport:`Failed to parse import file`,failedToSaveBatch:`Failed to save K-profiles`,noteSaved:`Note saved`,failedToSaveNote:`Failed to save note`},permission:{noRead:`You do not have permission to refresh profiles`,noCreate:`You do not have permission to add profiles`,noUpdate:`You do not have permission to update K-profiles`,noDelete:`You do not have permission to delete K-profiles`,noExport:`You do not have permission to export profiles`,noImport:`You do not have permission to import profiles`}},virtualPrinter:{title:`Virtual Printer`,running:`Running`,stopped:`Stopped`,description:{default:`Enable a virtual printer that appears in Bambu Studio and OrcaSlicer. Files sent to this printer will be archived directly without printing.`,proxy:`Enable a proxy that relays slicer traffic to a real printer, allowing remote printing over any network.`},enable:{title:`Enable Virtual Printer`,visibleInSlicer:`Visible as "Bambuddy" in slicer discovery`,proxyingTo:`Proxying to {{name}}`,notActive:`Not active`},model:{title:`Printer Model`,description:`Select which printer model to emulate.`,restartWarning:`Changing the model will restart the virtual printer`},accessCode:{title:`Access Code`,isSet:`Access code is set`,notSet:`No access code set - required to enable`,placeholder:`Enter 8-char code`,placeholderChange:`Enter new code to change`,hint:`Must be exactly 8 characters. Used by slicers to authenticate.`,charCount:`({{count}}/8)`,inheritedFromTarget:`Inherited from target`,derivedFromTargetHint:`Uses the target printer's access code. The bridge forwards slicer auth to the real printer, so the codes must match — edit the printer's access code to change this value.`,reveal:`Show access code`,hide:`Hide access code`},targetPrinter:{title:`Target Printer`,configured:`Proxy target configured`,notConfigured:`No target printer selected - required for proxy mode`,placeholder:`Select a printer...`,hint:`Select the printer to proxy slicer traffic to. The printer must be in LAN mode.`,noPrinters:`No printers configured. Add a printer first to use proxy mode.`},remoteInterface:{title:`Network Interface Override`,configured:`Interface override active`,optional:`Optional - use if auto-detected IP is wrong (e.g. multiple NICs, Docker, VPN)`,placeholder:`Auto-detect (default)...`,hint:`Override the IP address advertised via SSDP and used in the TLS certificate. Useful when Bambuddy has multiple network interfaces.`},mode:{title:`Mode`,archive:`Archive`,archiveDesc:`Archive files immediately`,review:`Review`,reviewDesc:`Review before archiving`,queue:`Queue`,queueDesc:`Archive and add to queue`,proxy:`Proxy`,proxyDesc:`Relay to real printer`},autoDispatch:{title:`Auto-dispatch`,description:`Automatically start prints when added to queue. When off, prints wait for manual dispatch.`},queueForceColorMatch:{title:`Force color match`,description:`Refuse to dispatch onto a printer that does not have the exact filament type and color loaded. Off by default — without this, the queue uses model-only matching and may pick a printer with the wrong color loaded.`},saveAmsMapping:{title:`Save AMS mapping`,description:`Persist the slicer's own AMS-slot pick (from the project_file MQTT command) onto the archive, so a later reprint reuses the exact physical spool instead of re-deriving one from the file's type/color. Off by default.`},gcodeInjection:{title:`G-code injection`,description:`Apply the per-model G-code snippets configured in Settings to jobs from this VP. Off by default.`},tailscaleDisabled:{title:`Tailscale integration`,description:`Enable to mark this VP as exposed over Tailscale. Shows the host's Tailscale address so you know which IP to paste into the slicer. The CA-import step is unchanged — this toggle has no effect on certificates.`},setupRequired:{title:`Setup Required`,description:`The virtual printer feature requires additional system configuration before it will work. This includes port forwarding, firewall rules, and platform-specific settings.`,readGuide:`Read the setup guide before enabling`},archiveNameSource:{title:`Archive name source`,description:`Choose how new archives are named when files arrive via the virtual printer. "Metadata" uses the slicer-embedded Title from the 3MF (default). "Filename" uses the filename Bambu Studio sent over FTP. Note: Bambu Studio overwrites the name you type in the "send to printer" dialog with the 3MF's Title field whenever one is present, so both modes often produce the same string.`,metadata:`Metadata`,filename:`Filename`},caCert:{title:`Slicer certificate`,description:`Virtual printers use a TLS certificate signed by the Bambuddy CA. Import this CA certificate into your slicer's trust store once so it accepts the connection — no need to copy it from the command line.`,copy:`Copy`,copied:`Copied`,download:`Download`,fingerprint:`SHA-256`},howItWorks:{title:`How it works`,step1:`On the same LAN, virtual printers appear in your slicer (Bambu Studio / OrcaSlicer) automatically via discovery. From other networks, add them manually by IP address and access code.`,step2:`In Archive, Review, and Queue modes, use the "Send" button in your slicer to upload 3MF files to Bambuddy. The slicer will show "Print success" — the file is stored, not printed.`,step3:`In Proxy mode, the virtual printer relays all traffic to a real printer — prints start immediately as if connected directly.`},status:{title:`Status Details`,printerName:`Printer Name`,model:`Model`,serialNumber:`Serial Number`,mode:`Mode`,pendingFiles:`Pending Files`,targetPrinter:`Target Printer`,ftpPort:`FTP Port`,mqttPort:`MQTT Port`,ftpConnections:`FTP Connections`,mqttConnections:`MQTT Connections`},toast:{updated:`Virtual printer settings updated`,failedToUpdate:`Failed to update settings`,copyFailed:`Failed to copy — try selecting the text manually`,accessCodeRequired:`Please set an access code first`,targetPrinterRequired:`Please select a target printer first`,bindIpRequired:`Please set a bind IP first`,accessCodeEmpty:`Access code cannot be empty`,accessCodeLength:`Access code must be exactly 8 characters`,targetCodeChangedRebind:`Access code now matches the new target printer. Re-add this device in your slicer to pick up the new code.`,created:`Virtual printer created`,failedToCreate:`Failed to create virtual printer`,deleted:`Virtual printer deleted`,failedToDelete:`Failed to delete virtual printer`},list:{title:`Virtual Printers`,add:`Add`,addFirst:`Add Virtual Printer`,empty:`No virtual printers configured. Add one to get started.`},bindIp:{title:`Bind Interface`,placeholder:`Select interface...`,hint:`Network interface for this virtual printer to bind to. Must be unique per printer.`},proxy:{accessCodeHint:`In proxy mode, use your target printer's access code in the slicer. The connection is forwarded transparently to the real printer.`},addDialog:{title:`Add Virtual Printer`,name:`Name`,hint:`You can configure access code, target printer, and other settings after creating.`,create:`Create`},deleteConfirm:{title:`Delete Virtual Printer`,message:`Are you sure you want to delete "{{name}}"? This will stop all services for this printer.`}},modelViewer:{stepConverting:`Converting STEP model… {{seconds}} s`,stepSlowHint:`Large STEP files can take a minute or more.`,openInSlicer:`Open in Slicer`,openInSlicerWith:`Open in {{slicer}}`,moreSlicerOptions:`More slicer options`,openInSlicerFailed:`Could not open in slicer`,tabs:{model:`3D Model`},notAvailable:`not available`,plates:`Plates`,allPlates:`All Plates`,plateNumber:`Plate {{number}}`,plateCount:`{{count}} plate`,plateCount_other:`{{count}} plates`,objectCount:`{{count}} object`,objectCount_other:`{{count}} objects`,filamentCount:`{{count}} filament`,filamentCount_other:`{{count}} filaments`,eta:`ETA {{minutes}} min`,noPreview:`No preview available for this file`,pagination:{pageOf:`Page {{current}} of {{total}}`,prev:`Prev`,next:`Next`},errors:{failedToLoad:`Failed to load file`,noMeshes:`No meshes found in 3MF file`,unsupportedFormat:`Unsupported file format`}},maintenanceDescriptions:{lubricateCarbonRods:`Apply lubricant to carbon rods for smooth motion`,lubricateRails:`Apply lubricant to linear rails for smooth motion`,cleanNozzle:`Clean hotend and nozzle to prevent clogs`,checkBelts:`Verify belt tension for accurate prints`,cleanBuildPlate:`Clean build plate for better adhesion`,checkExtruder:`Inspect extruder gears for wear`,checkCooling:`Ensure cooling fans are working properly`,generalInspection:`General printer inspection`,cleanCarbonRods:`Clean carbon rods to reduce friction`,lubricateSteelRods:`Apply lubricant to steel rods for smooth motion`,cleanSteelRods:`Clean steel rods to reduce friction`,cleanLinearRails:`Wipe linear rails to remove dust and debris`,checkPtfeTube:`Inspect PTFE tube for wear or damage`,replaceHepaFilter:`Replace HEPA filter for air quality`,replaceCarbonFilter:`Replace activated carbon filter`,lubricateLeftNozzleRail:`Lubricate left nozzle rail (H2 series)`},haSensors:{label:`Sensors`,unavailable:`Unavailable`,blocksPrints:`{{entity}} — holds prints while alerting`,states:{open:`Open`,closed:`Closed`,unlocked:`Unlocked`,locked:`Locked`,detected:`Detected`,clear:`Clear`,wet:`Wet`,dry:`Dry`,problem:`Problem`,ok:`OK`,running:`Running`,stopped:`Stopped`,on:`On`,off:`Off`},sectionTitle:`Home Assistant Sensors (Printers)`,add:`Add Sensor`,addTitle:`Add Home Assistant Sensor`,editTitle:`Edit Home Assistant Sensor`,empty:`No sensors yet. Bind a door contact or a thermometer from Home Assistant to show it on a printer card.`,unknownPrinter:`Unknown printer`,badgeBlocks:`Holds prints`,badgeNotifies:`Notifies`,badgeHidden:`Hidden on card`,printer:`Printer`,entity:`Entity`,searchPlaceholder:`Search entities...`,noEntities:`No matching entities`,name:`Display name`,alertWhen:`Alert when`,alertNever:`Never — display only`,alertAbove:`Above`,alertBelow:`Below`,alertHint:`The alert state highlights the sensor on the printer card and enables the options below.`,showOnCard:`Show on printer card`,notifyOnAlert:`Send a notification when it starts alerting`,blockPrint:`Hold queued prints while alerting`,blockPrintHint:`Jobs stay queued and start on their own once the sensor clears. Ignored while Home Assistant is unreachable.`,toast:{created:`Sensor added`,updated:`Sensor saved`,deleted:`Sensor removed`},error:{pickEntity:`Pick a Home Assistant entity`,nameRequired:`Enter a display name`,printerRequired:`Pick a printer`,alertRequired:`Set an alert condition first`}},locationHaSensors:{sectionTitle:`Home Assistant Sensors (Storage Locations)`,sectionDescription:`Bind Home Assistant temperature, humidity, or battery sensors to your storage locations to show live readings on the filament card and in the table. Only one sensor per category is allowed per location.`,add:`Add Sensor`,addTitle:`Add Home Assistant Sensor`,editTitle:`Edit Home Assistant Sensor`,empty:`No sensors yet. Bind a temperature or humidity sensor from Home Assistant to show it on the filament card.`,unknownLocation:`Unknown location`,location:`Storage Location`,showOnCard:`Show on filament card`,overwriteConfirm:{title:`Replace existing sensor?`,messageTemperature:`"{{location}}" already has a temperature sensor bound: {{name}}. Continuing will replace it.`,messageHumidity:`"{{location}}" already has a humidity sensor bound: {{name}}. Continuing will replace it.`,messageBattery:`"{{location}}" already has a battery sensor bound: {{name}}. Continuing will replace it.`},autoAdd:{confirmTitle:`Add the other sensors too?`,confirmMessage:`Bambuddy also found other sensors for this location. Choose which ones to add too.`,added:`Also added: {{names}}`,noneFound:`No matching temperature, humidity, or battery sensors found for this location.`,onlyThisOne:`Only this one`},options:{buttonLabel:`Sensor options`,title:`Location Sensor Options`,description:`These values are used when a temperature, humidity, or battery sensor is bound automatically alongside the first sensor for a location.`,generalSettings:`General settings`,pollInterval:`Update interval (seconds)`,pollIntervalHint:`How often Bambuddy polls Home Assistant and refreshes sensor values on screen. Minimum 60 seconds.`,colorizeValues:`Colorize sensor values against their alert thresholds`,aboveColor:`Above threshold color`,belowColor:`Below threshold color`,optimalColor:`Optimal value color`,colors:{red:`Red`,orange:`Orange`,yellow:`Yellow`,green:`Green`,blue:`Blue`,purple:`Purple`,pink:`Pink`},saved:`Options saved`,saveFailed:`Failed to save options`,reset:`Reset`,resetConfirm:{title:`Reset all existing location sensors?`,message:`This overwrites the alert thresholds, notifications, and card visibility of every existing storage-location temperature, humidity, and battery sensor with the values configured above, and restores each sensor's name to its Home Assistant friendly name — printer sensors are not affected. This cannot be undone. Depending on how many sensors you have, this may take a moment.`},resetDone:`Applied to {{count}} location sensors`,resetFailed:`Failed to reset location sensors`},deleteAllConfirm:{title:`Delete all sensors?`,message:`This removes all {{count}} sensors bound to "{{location}}". This cannot be undone.`},currentlyBound:`Currently bound: {{entity}}`,error:{locationRequired:`Pick a storage location`},toast:{created:`Sensor added`,updated:`Sensor saved`,deleted:`Sensor removed`}},smartPlugs:{offline:`Offline`,admin:`Admin`,openPlugAdminPage:`Open plug admin page`,deleteSmartPlug:`Delete Smart Plug`,turnOnSmartPlug:`Turn On Smart Plug`,turnOffSmartPlug:`Turn Off Smart Plug`,turnOn:`Turn On`,turnOff:`Turn Off`,addSmartPlug:{scanningNetwork:`Scanning network...`,chooseEntity:`Choose an entity...`,connectionFailed:`Connection failed`,searchEntities:`Search entities...`,searchPowerSensors:`Search power sensors...`,searchEnergySensors:`Search energy sensors...`,placeholders:{plugName:`Living Room Plug`,mqttStateOnValue:`ON, true, 1`,mqttSameAsPower:`Same as power topic, or different`}},linkedTo:`Linked to:`,monitorOnly:`Monitor Only`,alerts:`Alerts`,scheduleOn:`On {{time}}`,scheduleOff:`Off {{time}}`,on:`On`,off:`Off`,power:`Power`,kwhToday:`kWh Today`,settings:`Settings`,automationSettings:`Automation Settings`,showInSwitchbar:`Show in Switchbar`,quickAccessSidebar:`Quick access from sidebar`,enabled:`Enabled`,enableAutomation:`Enable automation for this plug`,autoOn:`Auto On`,autoOnDescription:`Turn on when print starts`,autoOff:`Auto Off`,autoOffDescription:`Turn off when print completes (one-shot)`,autoOffPersistent:`Keep Enabled`,autoOffPersistentDescription:`Stay enabled between prints instead of one-shot`,controlsPrinterPower:`Powers the printer`,controlsPrinterPowerDescription:`Turn off if this plug only powers an accessory (filter fan, lights). Otherwise switching it off marks the printer offline.`,autoOffAfterDrying:`Auto Off After Drying`,autoOffAfterDryingDescription:`Turn off when AMS drying completes`,delayAfterDryingMinutes:`Drying delay (minutes)`,turnOffDelayMode:`Turn Off Delay Mode`,time:`Time`,temp:`Temp`,delayMinutes:`Delay (minutes)`,tempThreshold:`Temperature threshold (°C)`,tempThresholdDescription:`Turns off when nozzle cools below this temperature`,edit:`Edit`,deleteConfirm:`Are you sure you want to delete "{{name}}"? This cannot be undone.`,turnOnConfirm:`Are you sure you want to turn on "{{name}}"?`,turnOffConfirm:`Are you sure you want to turn off "{{name}}"? This will cut power to the connected device.`,failedToTurn:`Failed to turn {{action}} "{{name}}"`,unknown:`Unknown`,addTitle:`Add Smart Plug`,editTitle:`Edit Smart Plug`,stopScanning:`Stop Scanning`,discoverTasmota:`Discover Tasmota Devices`,foundDevices:`Found {{count}} device(s) - click to select:`,noDevicesFound:`No Tasmota devices found on your network`,haNotConfigured:`Home Assistant is not configured. Set it up in`,haSettingsPath:`Settings → Network → Home Assistant`,selectEntity:`Select Entity *`,ipAddress:`IP Address *`,nameLabel:`Name *`,username:`Username`,password:`Password`,authHint:`Leave empty if your Tasmota device doesn't require authentication`,linkToPrinter:`Link to Printer`,noPrinter:`No printer (manual control only)`,linkingDescription:`Linking enables automatic on/off when prints start/complete`,powerAlerts:`Power Alerts`,alertAbove:`Alert if above (W)`,alertBelow:`Alert if below (W)`,alertDescription:`Get notified when power consumption crosses these thresholds. Leave empty to disable that direction.`,dailySchedule:`Daily Schedule`,turnOnAt:`Turn On at`,turnOffAt:`Turn Off at`,scheduleDescription:`Automatically turn the plug on/off at these times daily. Leave empty to skip that action.`,showOnPrinterCard:`Show on Printer Card`,displayOnPrinterCard:`Display button on printer card`,connectedResult:`Connected!`,deviceLabel:`Device: {{name}} - `,stateLabel:`State: {{state}}`,test:`Test`,delete:`Delete`,save:`Save`,add:`Add`,cancel:`Cancel`,failedToStartScan:`Failed to start scan`,nameRequired:`Name is required`,entityRequired:`Entity is required for Home Assistant plugs`,mqttTopicRequired:`At least one MQTT topic must be configured for power, energy, or state monitoring`,loadingEntities:`Loading entities...`,loading:`Loading...`,failedToLoadEntities:`Failed to load entities: {{error}}`,noEntitiesMatching:`No entities found matching "{{search}}"`,noEntitiesAvailable:`No entities available`,searchingEntities:`Searching all entities ({{count}} found)`,showingEntities:`Showing switch, light, input_boolean ({{count}} available)`,energyMonitoringOptional:`Energy Monitoring (Optional)`,energyMonitoringHint:`Search and select sensors that provide power/energy data.`,powerSensorW:`Power Sensor (W)`,energyTodayKwh:`Energy Today (kWh)`,totalEnergyKwh:`Total Energy (kWh)`,noMatchingSensors:`No matching sensors`,none:`None`,mqttNotConfigured:`MQTT broker not configured. Set broker address in`,mqttSettingsPath:`Settings → Network → MQTT Publishing`,mqttNotConfiguredSuffix:`(you don't need to enable publishing, just fill in the broker details).`,mqttMonitorOnlyDescription:`MQTT plugs receive power/energy data via MQTT subscription. On/off control is not available - use your MQTT broker or home automation system.`,powerMonitoring:`Power Monitoring`,energyMonitoring:`Energy Monitoring`,stateMonitoring:`State Monitoring`,optional:`optional`,topic:`Topic`,jsonPath:`JSON Path`,multiplier:`Multiplier`,onValue:`ON Value`,mqttPowerHint:`JSON path extracts value from JSON payload (e.g., "power_l1"). Leave empty if topic publishes raw numeric values.
- Use multiplier 0.001 for mW→W, 1000 for kW→W.`,mqttEnergyHint:`JSON path extracts value from JSON payload. Leave empty for raw values.
- Use multiplier 0.001 for Wh→kWh, 1000 for MWh→kWh.`,mqttStateHint:`JSON path extracts value from JSON payload. Leave empty for raw values.
- ON value: the exact string that means "ON". Leave empty for auto-detect (ON, true, 1).`,restControl:`Control`,restOnUrl:`Turn ON URL`,restOffUrl:`Turn OFF URL`,restOnBody:`ON Request Body`,restOffBody:`OFF Request Body`,restMethod:`HTTP Method`,restHeaders:`Custom Headers (JSON)`,restStatusUrl:`Status URL`,restStatusPath:`State JSON Path`,restStatusOnValue:`ON Value`,restPowerUrl:`Power URL`,restPowerPath:`Power JSON Path`,restPowerMultiplier:`Power Multiplier`,restEnergyUrl:`Energy URL`,restEnergyPath:`Energy JSON Path (today)`,restEnergyTotalPath:`Energy JSON Path (lifetime)`,restEnergyTotalMultiplier:`Lifetime Multiplier`,restEnergyTotalPathHint:`e.g. aenergy.total`,restEnergyTotalHint:`Many plugs — every Shelly among them — report only a lifetime counter that never resets. It belongs here, not in the field above: read as today's usage it would never reset at midnight, and Yesterday and Total would stay empty. Bambuddy works Today and Yesterday out from it, which takes a day or two of readings to fill in. A Shelly reports watt-hours, so use a multiplier of 0.001.`,restEnergyMultiplier:`Energy Multiplier`,restUrlRequired:`At least one URL (ON or OFF) is required for REST plugs`,restHeadersHint:`e.g. {"Authorization": "Bearer your-token"}`,restBodyHint:`e.g. ON, {"state": "on"}`,restStatusHint:`URL to poll for current state`,restPathHint:`e.g. state or data.power.status`,restPowerUrlHint:`Separate URL for power data (uses Status URL if empty)`,restEnergyUrlHint:`Separate URL for energy data (uses Status URL if empty)`,restEnergyHint:`Each value can use its own URL or fall back to the Status URL. Use multipliers for unit conversion (e.g. 0.001 to convert Wh to kWh).`,testConnection:`Test Connection`,connectionSuccess:`Connection successful`,noSwitchesInSwitchbar:`No switches in switchbar`,enableSwitchbarHint:`Enable "Show in Switchbar" in Settings > Smart Plugs`},notifications:{providerTypes:{callmebot:`CallMeBot/WhatsApp`,ntfy:`ntfy`,pushover:`Pushover`,telegram:`Telegram`,email:`Email`,discord:`Discord`,webhook:`Webhook`,homeassistant:`Home Assistant`,bark:`Bark`,gotify:`Gotify`},providerDescriptions:{email:`SMTP email notifications`,telegram:`Notifications via Telegram bot`,discord:`Send to Discord channel via webhook`,ntfy:`Free, self-hostable push notifications`,pushover:`Simple, reliable push notifications`,callmebot:`Free WhatsApp notifications via CallMeBot`,webhook:`Generic HTTP POST to any URL`,homeassistant:`Persistent notifications in Home Assistant dashboard`,bark:`iOS push notifications via Bark (self-hostable)`,gotify:`Push notifications via your own Gotify server`},lastSuccess:`Last: {{date}}`,error:`Error`,printer:`Printer:`,allPrinters:`All printers`,sendTestNotification:`Send Test Notification`,eventSettings:`Event Settings`,enabled:`Enabled`,sendFromProvider:`Send notifications from this provider`,printEvents:`Print Events`,printerStatus:`Printer Status`,amsAlarms:`AMS Alarms`,amsHtAlarms:`AMS-HT Alarms`,printQueue:`Print Queue`,start:`Start`,plateCheck:`Plate Check`,complete:`Complete`,failed:`Failed`,stopped:`Stopped`,progress:`Progress`,offline:`Offline`,lowFilament:`Low Filament`,maintenance:`Maintenance`,amsHumidity:`AMS Humidity`,amsTemp:`AMS Temp`,amsDryingSuspended:`Drying Suspended`,amsHtHumidity:`AMS-HT Humidity`,amsHtTemp:`AMS-HT Temp`,bedCooled:`Bed Cooled`,firstLayer:`First Layer`,quiet:`Quiet`,digest:`Digest {{time}}`,noPhoto:`No Photo`,printStarted:`Print Started`,plateNotEmpty:`Plate Not Empty`,plateNotEmptyDescription:`Objects detected before print`,plateClearRequired:`Plate Clear Required`,plateClearRequiredDescription:`Print finished, queue waits for plate confirmation`,printConfirmRequest:`Outcome Confirmation`,printConfirmRequestDescription:`Ask for a good/reject verdict with one-tap links when an opted-in print completes`,plateClear:`Plate Clear`,printCompleted:`Print Completed`,bedCooledLabel:`Bed Cooled`,bedCooledDescription:`Bed cooled below threshold after print`,firstLayerCompleteLabel:`First Layer Complete`,firstLayerCompleteDescription:`Notify with snapshot when first layer finishes`,connectedApps:`Connected apps`,appMessages:`Messages from connected apps`,appMessagesDescription:`Deliver messages other applications send through Bambuddy, e.g. Bambuddy Orders`,appMessagesBadge:`Apps`,missingSpoolAssignmentLabel:`Missing Spool Assignment`,billingChargeFailedLabel:`Billing Charge Failed`,billingChargeFailedDescription:`Notify when print costs could not be recorded`,missingSpoolAssignmentDescription:`Notify when print starts and required trays have no assigned spool`,printFailed:`Print Failed`,printStopped:`Print Stopped`,progressMilestones:`Progress Milestones`,progressMilestonesDescription:`Notify at 25%, 50%, 75%`,printerOffline:`Printer Offline`,printerError:`Printer Error`,aiFailureDetection:`AI Failure Detection`,aiFailureDetectionDescription:`Notify when Obico AI detects a possible print failure`,lowFilamentLabel:`Low Filament`,maintenanceDue:`Maintenance Due`,maintenanceDueDescription:`Notify when maintenance is needed`,amsHumidityHigh:`AMS Humidity High`,amsHumidityHighDescription:`Regular AMS humidity exceeds threshold`,amsTemperatureHigh:`AMS Temperature High`,amsTemperatureHighDescription:`Regular AMS temperature exceeds threshold`,amsDryingSuspendedTitle:`Auto-Drying Suspended`,amsDryingSuspendedDescription:`Automatic drying gave up on an AMS unit because humidity never fell below the threshold`,amsHtHumidityHigh:`AMS-HT Humidity High`,amsHtHumidityHighDescription:`AMS-HT humidity exceeds threshold`,amsHtTemperatureHigh:`AMS-HT Temperature High`,amsHtTemperatureHighDescription:`AMS-HT temperature exceeds threshold`,inventoryAlerts:`Inventory Alerts`,stockReorderAlert:`Reorder Alert`,stockReorderAlertDescription:`SKU has reached its reorder point`,stockBreakAlert:`Stock Break Alert`,stockBreakAlertDescription:`Stock will run out before replenishment arrives`,jobAdded:`Job Added`,jobAddedDescription:`Job added to queue`,jobAssigned:`Job Assigned`,jobAssignedDescription:`Model-based job assigned to printer`,jobStarted:`Job Started`,jobStartedDescription:`Queue job started printing`,jobWaiting:`Job Waiting`,jobWaitingDescription:`Job waiting for filament or printer`,jobSkipped:`Job Skipped`,jobSkippedDescription:`Job skipped (previous failed)`,jobFailed:`Job Failed`,jobFailedDescription:`Job failed to start`,queueComplete:`Queue Complete`,queueCompleteDescription:`All queue jobs finished`,quietHours:`Quiet Hours`,noNotificationsDuring:`No notifications during these hours`,editProviderToChangeQuietHours:`Edit provider to change quiet hours`,dailyDigest:`Daily Digest`,batchNotifications:`Batch notifications into a single daily summary`,sendAt:`Send at {{time}}`,editProviderToChangeDigestTime:`Edit provider to change digest time`,edit:`Edit`,deleteProvider:`Delete Notification Provider`,deleteConfirm:`Are you sure you want to delete "{{name}}"? This cannot be undone.`,delete:`Delete`,addTitle:`Add Notification Provider`,editTitle:`Edit Notification Provider`,nameLabel:`Name *`,namePlaceholder:`My Notifications`,providerTypeLabel:`Provider Type *`,configuration:`Configuration`,testConfiguration:`Test Configuration`,printerFilter:`Printer Filter`,onlyFromPrinter:`Only send notifications for events from this printer`,attachPhotoLabel:`Attach Photo`,attachPhotoDescription:`Include a camera snapshot with notifications, when one was captured for the event`,quietHoursDnd:`Quiet Hours (Do Not Disturb)`,quietStart:`Start`,quietEnd:`End`,dailyDigestLabel:`Daily Digest`,sendDigestAt:`Send digest at`,digestCollected:`Events will be collected and sent as a single summary at this time`,notificationEvents:`Notification Events`,progressPercent:`(25%, 50%, 75%)`,bedCooledAfterPrint:`(after print completes)`,haSensorAlert:`Printer Sensor Alert`,haSensorAlertDescription:`(a bound Home Assistant sensor needs attention)`,locationHaSensorAlert:`Storage Location Sensor Alert`,locationHaSensorAlertDescription:`(a Home Assistant sensor bound to a storage location needs attention)`,eventPriority:{sectionTitle:`ntfy Priority`,helpNtfy:`Pick a priority for each enabled event. ntfy uses these to escalate alerts (sound, visibility, push behavior). Levels not set here use the ntfy server default.`,sectionTitleGotify:`Gotify Priority`,helpGotify:`Pick a priority for each enabled event. Bambuddy sends Min, Low, Default, High and Urgent to Gotify as 0, 2, 5, 8 and 10. In the Gotify Android app, Default and above play a sound, and High and Urgent pop up.`,min:`Min`,low:`Low`,default:`Default`,high:`High`,urgent:`Urgent`},cancel:`Cancel`,save:`Save`,add:`Add`,nameRequired:`Name is required`,fieldRequired:`{{field}} is required`,haDataInvalid:`The Data field must be a valid JSON object, e.g. {"priority": "high", "ttl": 0}`,haServiceHelp:`Optional — defaults to a persistent notification in Home Assistant's UI. Set a notify service (e.g. notify.mobile_app_myphone) to get push notifications on your phone, which also attaches a camera snapshot automatically when one is available and External URL is set in Settings → Network.`,phoneNumber:`Phone Number`,apiKey:`API Key`,serverUrl:`Server URL`,topic:`Topic`,authToken:`Auth Token`,userKey:`User Key`,appToken:`App Token`,priority:`Priority`,pushoverRetry:`Emergency Retry (s)`,pushoverExpire:`Emergency Expire (s)`,botToken:`Bot Token`,chatId:`Chat ID`,telegramThreadId:`Forum Topic ID`,telegramThreadIdHelp:`Optional. Posts into a single topic of a forum group — the last number in the topic link (t.me/c/.../25). Leave empty for the General topic.`,telegramThreadIdInvalid:`Forum Topic ID must be a number.`,telegramVerdictMode:`Outcome verdict via`,telegramVerdictModeButtons:`Inline buttons (link)`,telegramVerdictModeReactions:`Reaction (👍 / 👎)`,telegramVerdictModeBoth:`Buttons and reaction`,telegramVerdictModeHelp:`How the outcome prompt is answered. Reactions need no inbound connectivity or external URL — Bambuddy polls the bot for them. For reactions, use a bot only Bambuddy uses: another app polling the same bot (Home Assistant, for example) stops receiving its messages, and that stays so even after switching back to buttons. In a group the bot must be an admin to see reactions.`,telegramVerdictBadgeReactions:`Reactions`,telegramVerdictBadgeBoth:`Buttons + reactions`,smtpServer:`SMTP Server`,smtpPort:`SMTP Port`,security:`Security`,authentication:`Authentication`,username:`Username`,password:`Password`,fromEmail:`From Email`,toEmail:`To Email`,webhookUrl:`Webhook URL`,payloadFormat:`Payload Format`,authorization:`Authorization`,titleFieldName:`Title Field Name`,messageFieldName:`Message Field Name`,editTemplate:`Edit Template: {{name}}`,titleLabel:`Title`,bodyLabel:`Body`,titlePlaceholder:`Notification title...`,bodyPlaceholder:`Notification body...`,availableVariables:`Available Variables`,clickToInsert:`Click to insert at cursor position in body`,livePreview:`Live Preview`,hide:`Hide`,show:`Show`,loadingPreview:`Loading preview...`,enterTemplateContent:`Enter template content to see preview`,titlePreview:`Title:`,bodyPreview:`Body:`,photoPreview:`Photo:`,photoPreviewNote:`Example only — providers that support attachments (ntfy, Pushover, Telegram, Discord, Home Assistant, Bark, Slack webhook) include a camera snapshot automatically when one was captured, regardless of what the body above says.`,photoPreviewNoteWithEmail:`Example only — attached automatically for supported providers (ntfy, Pushover, Telegram, Discord, Home Assistant, Bark, Slack webhook) when a snapshot was captured. For Email, add {finish_photo_url} to the body above to include it inline.`,photoPreviewNoteEmailOnly:`Example only — this is always an email. Add {finish_photo_url} to the body above to include the photo inline; without it, only the text is sent.`,resetToDefault:`Reset to Default`,titleRequired:`Title is required`,bodyRequired:`Body is required`,notificationLog:`Notification Log`,showFailedOnly:`Failed only`,last24Hours:`Last 24 hours`,last7Days:`Last 7 days`,last30Days:`Last 30 days`,last90Days:`Last 90 days`,justNow:`Just now`,noFailedNotifications:`No failed notifications`,noNotificationsLogged:`No notifications logged`,unknownProvider:`Unknown Provider`,logTitle:`Title`,logMessage:`Message`,logError:`Error`,logProvider:`Provider: {{type}}`,logTime:`Time: {{time}}`,refresh:`Refresh`,clearOld:`Clear Old`,statsSummary:`Last {{days}} days:`,statsNotifications:`notifications`,statsSent:`{{count}} sent`,statsFailed:`{{count}} failed`,eventTypes:{print_start:`Print Started`,print_complete:`Print Complete`,print_failed:`Print Failed`,print_stopped:`Print Stopped`,print_progress:`Progress`,printer_offline:`Printer Offline`,printer_error:`Printer Error`,filament_low:`Low Filament`,maintenance_due:`Maintenance Due`,test:`Test`},userEmail:{title:`Notifications`,emailNotifications:`Email Notifications`,emailNotificationsDesc:`Receive email notifications for your own print jobs. Emails are sent using the system SMTP settings configured in Advanced Authentication.`,sendingTo:`Notifications will be sent to`,noEmailWarning:`Your account does not have an email address. Contact an administrator to add one.`,printJobNotifications:`Print Job Notifications`,printJobNotificationsDesc:`Choose which events trigger email notifications for print jobs you submit.`,printJobStarts:`Print Job Starts`,printJobStartsDesc:`Get notified when your print job begins.`,printJobFinishes:`Print Job Finishes`,printJobFinishesDesc:`Get notified when your print job completes successfully.`,printErrors:`Print Errors`,printErrorsDesc:`Get notified when your print job fails or encounters an error.`,printJobStops:`Print Job Stops`,printJobStopsDesc:`Get notified when your print job is cancelled or stopped.`,saveSuccess:`Notification preferences saved.`,saveError:`Failed to save notification preferences.`}},richTextEditor:{bold:`Bold`,italic:`Italic`,underline:`Underline`,bulletList:`Bullet List`,numberedList:`Numbered List`,alignLeft:`Align Left`,alignCenter:`Align Center`,alignRight:`Align Right`,addLink:`Add Link`,removeLink:`Remove Link`},externalLinks:{title:`Sidebar Links`,sidebarLayout:`Sidebar`,sidebarLayoutDescription:`Show or hide built-in pages, add external links, and drag items to reorder the sidebar navigation.`,systemPages:`Bambuddy pages`,externalLinks:`External links`,visibleInSidebar:`Visible in sidebar`,hiddenFromSidebar:`Hidden from sidebar`,requiredInSidebar:`Required in sidebar`,hidePage:`Hide page`,showPage:`Show page`,settingsCannotBeHidden:`Settings cannot be hidden`,noLinksConfigured:`No external links configured`,deleteLink:`Delete Link`,removeCustomIcon:`Remove custom icon`,openInNewTab:`Open in new tab`,placeholders:{linkName:`My Link`}},keyboardShortcuts:{title:`Keyboard Shortcuts`,navigation:`Navigation`,archivesSection:`Archives`,kProfilesSection:`K-Profiles`,generalSection:`General`,shortcuts:{goToPrinters:`Go to Printers`,goToArchives:`Go to Archives`,goToQueue:`Go to Queue`,goToStats:`Go to Statistics`,goToProfiles:`Go to Cloud Profiles`,goToSettings:`Go to Settings`,focusSearch:`Focus search`,openUploadModal:`Open upload modal`,clearSelection:`Clear selection / blur input`,contextMenu:`Context menu on cards`,refreshProfiles:`Refresh profiles`,newProfile:`New profile`,exitSelectionMode:`Exit selection mode`,showHelp:`Show this help`},footer:`Press Esc or click outside to close`},notificationLog:{title:`Notification Log`,events:{printStarted:`Print Started`,printComplete:`Print Complete`,printFailed:`Print Failed`,printStopped:`Print Stopped`,progress:`Progress`,printerOffline:`Printer Offline`,printerError:`Printer Error`,lowFilament:`Low Filament`,maintenanceDue:`Maintenance Due`,test:`Test`},timeAgo:{justNow:`Just now`,minutesAgo:`{{minutes}}m ago`,hoursAgo:`{{hours}}h ago`}},restoreBackup:{title:`Restore Backup`,restoring:`Restoring...`,restoreComplete:`Restore Complete`,restoreFailed:`Restore Failed`,importSettings:`Import settings from a backup file`,pleaseWait:`Please wait while your data is being restored`,clickToSelect:`Click to select backup file (.json or .zip)`,howDuplicateHandling:`How duplicate handling works:`,categories:{printers:`Printers`,smartPlugs:`Smart Plugs`,notificationProviders:`Notification Providers`,filaments:`Filaments`,archives:`Archives`,pendingUploads:`Pending Uploads`,settingsTemplates:`Settings & Templates`},matchingInfo:{printers:`matched by serial number`,smartPlugs:`matched by IP address`,notificationProviders:`matched by name`,filaments:`matched by name + type + brand`,archives:`matched by content hash`,pendingUploads:`matched by filename`,settingsTemplates:`always overwritten`},replaceExisting:`Replace existing data`,keepExisting:`Keep existing data`,replaceDescription:`Overwrite items that already exist with backup data`,keepDescription:`Only restore items that don't already exist`,caution:`Caution:`,cautionText:`Overwriting will replace your current configurations with backup data. Printer access codes are never overwritten for security.`,itemsRestored:`Items Restored`,itemsSkipped:`Items Skipped`,restored:`Restored`,skipped:`Skipped (already exist)`,filesLabel:`Files (3MF, thumbnails, etc.)`,newApiKeysGenerated:`New API Keys Generated`,newApiKeysWarning:`These keys are only shown once. Copy them now!`,processingBackup:`Processing backup file...`,noDataFound:`No data was found to restore in the backup file.`,failedToRestore:`Failed to restore backup. Please check the file format.`},backupExport:{title:`Export Backup`,selectData:`Select data to include`,selectAll:`Select All`,selectNone:`Select None`,categoryDescriptions:{settings:`Language, theme, update preferences`,notifications:`ntfy, Pushover, Discord, etc.`,templates:`Custom message templates`,smartPlugs:`Tasmota plug configurations`,externalLinks:`Sidebar links to external services`,printers:`Printer info (access codes excluded)`,plateDetection:`Empty plate reference images`,filaments:`Filament types and costs`,maintenance:`Custom maintenance schedules`,archives:`All print data + files (3MF, thumbnails, photos)`,projects:`Projects, BOM items, and attachments`,pendingUploads:`Virtual printer uploads awaiting review`,apiKeys:`Webhook API keys (new keys generated on import)`},requiresPrinters:`Requires Printers to be selected`,zipFileWarning:`ZIP file will be created.`,zipFileDescription:`Includes all 3MF files, thumbnails, timelapses, and photos. This may take a while and result in a large file.`,includeAccessCodes:`Include Access Codes`,includeAccessCodesDescription:`For transferring to another machine`,includeAccessCodesWarning:`Access codes will be included in plain text. Keep this backup file secure!`,categoriesSelected:`{{selectedCount}} categories selected`},pendingUploads:{placeholders:{notes:`Add notes about this print...`},discardUpload:`Discard Upload`,archiveAllUploads:`Archive All Uploads`,discardAllUploads:`Discard All Uploads`,archive:`Archive`,timeAgo:{justNow:`Just now`,minutesAgo:`{{minutes}}m ago`,hoursAgo:`{{hours}}h ago`,daysAgo:`{{days}}d ago`}},apiBrowser:{placeholders:{requestBody:`JSON request body...`,searchEndpoints:`Search endpoints...`}},configureAmsSlot:{title:`Configure AMS Slot`,slotConfigured:`Slot Configured!`,configuringSlot:`Configuring slot:`,slotLabel:`{{ams}} Slot {{slot}}`,searchPresets:`Search presets...`,colorPlaceholder:`Color name or hex (e.g., brown, FF8800)`,clearCustomColor:`Clear custom color`,noCloudPresets:`No cloud presets. Login to Bambu Cloud to sync.`,noPresetsAvailable:`No presets available. Login to Bambu Cloud or import local profiles.`,noMatchingPresets:`No matching presets found.`,custom:`Custom`,builtin:`Built-in`,orcaCloud:`Orca Cloud`,bambuCloud:`Bambu Cloud`,settingsSentToPrinter:`Settings sent to printer`,filamentProfile:`Filament Profile`,kProfileLabel:`K Profile (Pressure Advance)`,filteringFor:`Filtering for: {{material}}`,noKProfile:`No K profile (use default 0.020)`,noMatchingKProfiles:`No matching K profiles found. Default K=0.020 will be used.`,otherKProfiles:`Other K profiles on this printer`,selectFilamentFirst:`Select a filament profile first`,kFromCalibration:`K={{value}} from printer calibration`,customColorLabel:`Custom Color (optional)`,presetColors:`{{name}} colors:`,showLessColors:`Show less colors`,showMoreColors:`Show more colors`,clear:`Clear`,hexLabel:`Hex: #{{hex}}`,resetting:`Resetting...`,resetSlot:`Reset Slot`,cancel:`Cancel`,configuring:`Configuring...`,configureSlot:`Configure Slot`,orcaFallback:{no_filament_id:`This Orca profile has no filament ID of its own, so OrcaSlicer will see this slot as Generic {{material}}.`,lookup_failed:`Couldn't read this profile's filament ID from Orca Cloud, so OrcaSlicer will see this slot as Generic {{material}}. Try again in a moment.`,no_permission:`You don't have Orca Cloud access, so this profile's filament ID couldn't be read. OrcaSlicer will see this slot as Generic {{material}}.`}},githubBackup:{title:`Git Backup`,history:`History`,downloadBackup:`Download Backup`,restoreBackup:`Restore Backup`,noBackupsYet:`No backups yet`},emailSettings:{placeholders:{fromName:`BamBuddy`}},tagManagement:{searchTags:`Search tags...`,renameTag:`Rename tag`,deleteTag:`Delete tag`},notificationTemplates:{placeholders:{title:`Notification title...`,body:`Notification body...`}},batchTag:{placeholders:{newTag:`Enter new tag...`}},photoGallery:{deletePhoto:`Delete Photo`},filamentHoverCard:{copySpoolUuid:`Copy spool UUID`},kProfilesView:{hasNote:`Has note`,copyProfile:`Copy profile`},layout:{openMenu:`Open menu`,noPermissionSystemInfo:`You do not have permission to view system information`},dashboard:{dragToReorder:`Drag to reorder`,hideWidget:`Hide widget`},notificationProviderCard:{deleteNotificationProvider:`Delete Notification Provider`},fileManagerModal:{closeFileManager:`Close file manager`,sortFiles:`Sort files`,goToParentFolder:`Go to parent folder`,threeView:`3D View`},embeddedCameraViewer:{refreshStream:`Refresh stream`,close:`Close`,zoomOut:`Zoom out`,resetZoom:`Reset zoom`,zoomIn:`Zoom in`,dragToResize:`Drag to resize`},timelapseViewer:{skipBack5s:`Skip back 5s`,skipForward5s:`Skip forward 5s`},notificationProviders:{descriptions:{email:`SMTP email notifications`,telegram:`Notifications via Telegram bot`,discord:`Send to Discord channel via webhook`,ntfy:`Free, self-hostable push notifications`,pushover:`Simple, reliable push notifications`,callmebot:`Free WhatsApp notifications via CallMeBot`,webhook:`Generic HTTP POST to any URL`}},logViewer:{searchPlaceholder:`Search message or logger name...`,noLogEntries:`No log entries found`},switchbarPopover:{noSwitchesInSwitchbar:`No switches in switchbar`},projectPageModal:{placeholders:{title:`Title`,designer:`Designer`,license:`License`,description:`Enter description...`,profileTitle:`Profile Title`,profileDescription:`Profile description...`}},spoolmanSettings:{},time:{unknown:`-`,waiting:`Waiting`,justNow:`Just now`,now:`Now`,minsAgo:`{{count}}m ago`,inMins:`in {{count}}m`,hoursAgo:`{{count}}h ago`,inHours:`in {{count}}h`,daysAgo:`{{count}}d ago`,inDays:`in {{count}}d`},spoolbuddy:{nav:{dashboard:`Dashboard`,ams:`AMS`,inventory:`Inventory`,writeTag:`Write`,settings:`Settings`},status:{nfcReady:`NFC Ready`,nfcOff:`NFC Off`,offline:`Offline`,online:`Online`,noPrinters:`No printers`,deviceOffline:`Device Offline`,waitingConnection:`Waiting for device connection...`,systemReady:`System Ready`,status:`Status`},dashboard:{readyToScan:`Ready to scan`,idleMessage:`Place a spool on the scale to identify it`,nfcHint:`NFC tag will be read automatically`,device:`Device`,syncWeight:`Sync Weight`,weightSynced:`Synced!`,unknownTag:`Unknown Tag`,newTag:`New Tag Detected`,onScale:`on scale`,linkSpool:`Link to Spool`,linkTagTitle:`Link Tag to Spool`,linkTag:`Link Tag`,selectSpool:`Select a spool to link this tag to:`,noUntagged:`No spools without tags found`,tagDetected:`Tag detected`,noTag:`No tag`,tagId:`Tag`,grossWeight:`Gross weight`,spoolSize:`Spool size`,close:`Close`,currentSpool:`Current Spool`,plateReady:`Plate ready: {{name}}`,plateReadyLabel:`Plates ready to clear`,plateClearAction:`Clear`,plateClearedToast:`Plate marked as cleared`,plateClearFailed:`Could not mark plate as cleared`},modal:{spoolDetected:`Spool Detected`,assignToAms:`Assign to AMS`,syncWeight:`Sync Weight`,weightSynced:`Synced!`,syncing:`Syncing...`,newTagDetected:`New Tag Detected`,addToInventory:`Add to Inventory`,assignToAmsTitle:`Assign to AMS`,selectSlot:`Select a slot`,assign:`Assign`,assigning:`Assigning...`,assignSuccess:`Assigned!`,assignPendingInsert:`Assigned. Slot will configure when you insert the spool.`,assignError:`Failed to assign spool. Please try again.`,noPrinterSelected:`Select a printer...`,noAmsDetected:`No AMS detected on this printer`,slot:`Slot`},weight:{noReading:`No reading`,stable:`Stable`,measuring:`Measuring...`,tare:`Tare`,calibrate:`Calibrate`},spool:{remaining:`Remaining`,material:`Material`,brand:`Brand`,color:`Color`,coreWeight:`Core`,labelWeight:`Label`,scaleWeight:`Scale`,netWeight:`Net`,lastUsed:`Last used`,unknownColor:`Unknown color`},ams:{noData:`No AMS detected`,connectAms:`Connect an AMS to see filament slots`,noPrinter:`No printer selected`,selectPrinter:`Select a printer from the top bar`,printerDisconnected:`Printer disconnected`,humidity:`Humidity`,level:`Level`,active:`Active`,slot:`Slot`,empty:`Empty`},inventory:{search:`Search spools...`,empty:`No spools in inventory`,noResults:`No matching spools`,spools:`spools`,addSpool:`Add Spool`},settings:{tabDevice:`Device`,tabDisplay:`Display`,tabScale:`Scale`,tabUpdates:`Updates`,nfcReader:`NFC Reader`,type:`Type`,connection:`Connection`,notConnected:`N/A`,deviceInfo:`Device Info`,hostname:`Host`,uptime:`Uptime`,systemConfig:`Backend & Auth`,backendUrl:`Bambuddy Backend URL`,apiToken:`API Token`,apiTokenPlaceholder:`Enter API token`,saveConfig:`Save Config`,systemQueued:`Config queued.`,nfcDiagnostic:`NFC Diagnostic`,scaleDiagnostic:`Scale Diagnostic`,readTagDiagnostic:`Read Tag Diagnostic`,testNfc:`Test reader`,testScale:`Test accuracy`,testReadTag:`Read tag`,systemFieldsRequired:`Backend URL is required.`,brightness:`Brightness`,saved:`Saved`,noBacklight:`No DSI backlight detected. Brightness control requires a DSI display.`,screenBlank:`Screen Blank Timeout`,screenBlankDesc:`Screen turns off after inactivity. Touch to wake.`,displayNote:`Brightness is applied as a software filter.`,scaleCalibration:`Scale Calibration`,currentWeight:`Current weight`,tareOffset:`Tare`,calFactor:`Factor`,knownWeight:`Known weight`,calStep1:`Remove all items from the scale and press Set Zero.`,calStep2:`Place known weight on scale.`,setZero:`Set Zero`,calibrateNow:`Calibrate`,calibrated:`Calibrated`,tareSet:`Tare command sent. Waiting for device...`,tareComplete:`Tare complete!`,tareTimedOut:`Tare timed out — is the SpoolBuddy daemon running?`,tareFailed:`Failed to send tare command`,zeroSet:`Zero point set. Place known weight on scale.`,calibrationDone:`Calibration complete!`,calibrationFailed:`Calibration failed`,lastCalibrated:`Last calibrated`,stable:`Stable`,settling:`Settling...`,firmware:`Firmware`,scale:`Scale`,noDevice:`No SpoolBuddy device found`,daemonVersion:`Daemon Version`,currentVersion:`Current`,versionPending:`Waiting for daemon...`,checking:`Checking...`,checkUpdates:`Check for Updates`,updateAvailable:`Update available`,updateInstructions:`Update via SSH: run the SpoolBuddy install script to upgrade.`,upToDate:`Up to date`,includeBeta:`Include beta versions`},writeTag:{tabExisting:`Existing Spool`,tabNew:`New Spool`,tabReplace:`Replace Tag`,searchPlaceholder:`Search by material, color, brand...`,noUntaggedSpools:`No spools without tags`,noTaggedSpools:`No spools with tags`,selectSpool:`Select a spool, then place a blank NTAG on the reader`,placeTag:`Place an NTAG on the reader`,tagReady:`Tag detected — ready to write`,writeTag:`Write Tag`,replaceTag:`Replace Tag`,writing:`Writing tag...`,waiting:`Waiting for SpoolBuddy...`,writeSuccess:`Tag written successfully!`,writeFailed:`Write failed`,queueFailed:`Failed to queue write command`,tryAgain:`Try Again`,cancel:`Cancel`,replaceWarning:`Old tag will be unlinked. New tag will replace it.`,deviceOffline:`SpoolBuddy is offline`,material:`Material`,colorName:`Color Name`,color:`Color`,brand:`Brand`,weight:`Weight (g)`,createSpool:`Create Spool`,creating:`Creating...`,spoolCreated:`Spool created! Ready to write.`,createFailed:`Failed to create spool`,incompleteDataWarning:`Tag written with incomplete Spoolman data`},quickMenu:{printerPower:`Printer Power`,systemControls:`System`,restartDaemon:`Restart Daemon`,restartBrowser:`Restart Browser`,reboot:`Reboot`,shutdown:`Shutdown`,swipeToClose:`Swipe down to close`,confirmTitle:`Confirm`,confirmShutdown:`Are you sure you want to shut down the SpoolBuddy? You will need physical access to turn it back on.`,confirmReboot:`Are you sure you want to reboot the SpoolBuddy?`,confirmRestartDaemon:`Restart the SpoolBuddy daemon? NFC and scale will be temporarily unavailable.`,confirmRestartBrowser:`Restart the kiosk browser? The display will briefly go blank.`,confirm:`Confirm`,confirmPlugOn:`Turn on {{name}}?`,confirmPlugOff:`Turn off {{name}}?`,turnOn:`Turn On`,turnOff:`Turn Off`}},diagnostic:{modalTitle:`Connection diagnostic — {{name}}`,running:`Running diagnostic...`,runningElapsed:`Running diagnostic... ({{elapsed}}s)`,waitingForReportHint:`Listening for the printer to publish a status report — this can take up to {{max}} seconds.`,runFailed:`Diagnostic could not run: {{error}}`,retry:`Run again`,runButton:`Run diagnostic`,sectionTitle:`Connection Diagnostic`,sectionDescription:`Check why a printer won't connect or won't print — port reachability, LAN developer mode, Docker network mode, and credentials.`,noPrinters:`No printers configured.`,overall:{ok:`No problems found — the printer connection looks healthy.`,warnings:`The printer should work, but some things need attention.`,problems:`Found problems that explain why the printer won't connect or print.`},check:{port_mqtt:{title:`Control port (MQTT 8883)`,pass:`Reachable — the printer is accepting control connections.`,fail:`Port 8883 is unreachable. The printer is powered off, on a different IP address, or a firewall is blocking it. Verify the printer IP and that nothing blocks port 8883.`},port_ftps:{title:`File transfer port (FTPS 990)`,pass:`Reachable — sending print files will work.`,warn:`Port 990 is unreachable. Monitoring may still work, but sending prints to the printer will fail. Make sure port 990 is not blocked.`,warn_no_tls:`Port 990 is open but the printer's file service is not completing a TLS handshake. Print files, covers and timelapses cannot be fetched, so archives stay empty. Restart the printer — unblocking the port will not help.`},external_storage:{title:`Store sent files on external storage (install step 4)`,pass:`The printer reports this option is on — sent files will be stored on the SD card and archives will have thumbnails and slicer metadata.`,fail:`The printer reports this option is off. Enable "Store sent files on external storage" — on newer firmware (P2S 01.02 / Bambu Studio 2.6+) the toggle lives on the printer's Print Settings; on older versions it's in Bambu Studio / OrcaSlicer's Device tab. Without it, every archived print is missing its thumbnail and slicer metadata.`,skip:`Not checked — needs a live MQTT connection. On older slicers where this setting lives only in the slicer the printer never reports it, so this check will pass even when the option is off — verify install step 4 manually.`,skip_unsupported_model:`This model has an SD slot but no way to turn the option on — current P1-series firmware doesn't expose the toggle in Bambu Studio and the printer has no screen. Nothing to fix here; archived prints may lack thumbnails and slicer metadata until Bambu Lab adds firmware support.`,fail_no_media:`The option is on, but the printer reports no card or stick in its slot, so there is nowhere for sent files to go. Insert one and print again — until then every archived print will be missing its thumbnail and slicer metadata.`,warn_internal_storage:`The option is on and storage is present, but the last print still went to the printer's internal storage, which Bambuddy cannot read. On H2-series, P2S and X2D, Bambu Studio's Print button always sends there whatever this option is set to. Prints archive with their name and timing, but without a thumbnail or slicer metadata. For complete archives, start prints from Bambuddy or slice in OrcaSlicer — or in Bambu Studio use Send with External selected, then start the print.`,warn_internal_history:`The option is on and storage is present, but the last print ran from a file that was already on the printer — a re-print from its screen, a start from Handy, or a file sent earlier. That library sits on internal storage Bambuddy cannot read, and no setting changes it, because nothing was sent for that print. It still archives with its name and timing, but without a thumbnail or slicer metadata. For complete archives, start prints from Bambuddy or send them from the slicer.`},port_rtsps:{title:`Camera port ({{protocol}} {{port}})`,pass:`Reachable — the camera stream will work.`,warn:`Port {{port}} is unreachable. The live camera view will not work. This does not affect printing.`},macos_local_network:{title:`macOS Local Network permission`,pass:`macOS is allowing Bambuddy to reach the local network.`,warn_unsigned:`The Python that runs Bambuddy has no code signature, so macOS has nothing to attach a Local Network permission to and silently drops every connection to the printer — no error and no prompt. Run the Bambuddy updater (install/update_macos.sh), which signs it, then restart Bambuddy. Interpreter: {{executable}}`,warn_permission:`If the printer is powered on and at this address, open System Settings > Privacy & Security > Local Network and make sure the Python that runs Bambuddy is enabled. macOS drops local connections silently when it is not, and updating Python can leave the old permission behind.`},network_mode:{title:`Container network mode`,genericRuntime:`a container`,pass:`Running in {{runtime}} with host networking.`,warn:`Bambuddy is running in {{runtime}} with bridge networking. Printer discovery and the Virtual Printer need host networking — recreate the container with host network mode ("network_mode: host" in docker-compose, "--network=host" for Podman).`,skip:`Not running in a container — not applicable.`,skip_unknown:`Bambuddy is running in {{runtime}}, but its network mode could not be determined. If printer discovery or the Virtual Printer do not work, recreate the container with host networking.`,skip_system_container:`Bambuddy is running in a {{runtime}} system container, which sits on the LAN like a virtual machine — not applicable.`},subnet:{title:`Network subnet`,pass:`The printer and Bambuddy are on the same subnet.`,warn:`The printer ({{printer_ip}}) and Bambuddy ({{host_ip}}) are on different subnets. They may not reach each other unless routing between the subnets is configured.`,skip:`Subnet could not be determined — skipped.`},mqtt_auth:{title:`Printer credentials`,pass:`The printer accepted the connection.`,fail:`The printer is reachable but Bambuddy is not connected to it. The access code or serial number is most likely wrong — the access code changes every time LAN Only or Developer Mode is toggled, so re-copy it from the printer screen. A printer that is rebooting, or already at its limit of simultaneous connections, can look the same.`,fail_auth_rejected:`The printer refused Bambuddy's credentials. The access code or serial number is wrong — the access code changes every time LAN Only or Developer Mode is toggled, so re-copy it from the printer screen and save it in the printer settings.`,skip:`Not checked — the printer could not be reached.`},developer_mode:{title:`LAN Developer Mode`,pass:`Developer Mode is enabled.`,fail:`Developer Mode is OFF on the printer. Enable it in the printer's LAN settings — and confirm with OK. Without it, prints will not start.`,skip:`Could not be checked — requires a live connection to the printer.`},printer_publishing:{title:`Printer is publishing status`,pass:`The printer is publishing status updates — AMS, filaments, and K-profiles will mirror correctly to the slicer.`,fail:`The MQTT broker accepted the connection but the printer has not published any status reports. This is almost always a wrong or mis-cased serial number — the device/<serial>/report topic is case-sensitive. Re-check the serial in printer settings against the screen on the printer.`,skip:`Could not be checked — requires a live connection to the printer.`}}},systemHealth:{sectionTitle:`System Health`,sectionDescription:`Scans recent logs for known issues you can usually fix yourself, before they turn into a support ticket.`,rescan:`Re-scan`,clean:`No known issues found in the last {{times}} log entries.`,logUnavailable:`File logging is disabled, so logs cannot be scanned. Enable file logging to use this check.`,learnMore:`How to fix`,fixLabel:`Fix:`,occurrences:`Seen {{times}}× — last at {{lastSeen}}`,category:{layer8:`You can fix this`,environment:`Environment`,bug:`Please report this`},signature:{"ftp-auth-rejected":{name:`Printer rejected the access code`,cause:`The printer refused the file-transfer login. The access code is wrong, or it changed after Developer Mode was toggled.`,fix:`Re-copy the access code from the printer screen (LAN settings) and update it in the printer's settings in Bambuddy.`},"ftp-connection-timeout":{name:`File-transfer connection timed out`,cause:`Bambuddy could not reach the printer's file-transfer port (FTPS 990). The port is blocked, or the printer is off or on another subnet.`,fix:`Make sure nothing blocks port 990 between Bambuddy and the printer, and that both are on the same network.`},"ftp-ssl-error":{name:`Secure file-transfer handshake failed`,cause:`The printer's file service answered port 990 without TLS. Its file server has wedged — a printer-side fault, not a firewall or firmware problem.`,fix:`Restart the printer. Until then print files, covers and timelapses cannot be fetched; printing itself is unaffected.`},"bambu-cloud-captcha":{name:`Bambu Cloud is asking for a CAPTCHA`,cause:`Bambu's anti-abuse layer is challenging this network, so no Bambu Cloud sign-in can complete. It is tied to the public IP address, not to your account or this installation.`,fix:`Wait — it normally clears within a few hours, and repeated sign-in attempts prolong it. To connect meanwhile, sign in with an access token taken from a browser session.`},"mqtt-connection-flapping":{name:`Printer connection keeps dropping`,cause:`The control connection (MQTT 8883) repeatedly disconnects and reconnects — usually a weak network path or a partially blocked port.`,fix:`Check the Wi-Fi signal at the printer, prefer a wired connection, and make sure port 8883 is reliably reachable.`},"camera-connection-refused":{name:`Camera stream unreachable`,cause:`The live camera could not be reached on port RTSPS 322. The port is blocked, or the camera or LAN liveview is off on the printer.`,fix:`Enable the camera and LAN liveview on the printer, and make sure port 322 is not blocked. This does not affect printing.`},"database-locked":{name:`Database write contention`,cause:`The SQLite database is hitting "database is locked" errors under load — common when running several printers at once.`,fix:`Switch Bambuddy to an external PostgreSQL database. See the PostgreSQL guide in the documentation.`}}},vpDiagnostic:{title:`Setup check — {{name}}`,runButton:`Run setup check`,running:`Running setup check...`,runFailed:`Could not run the setup check: {{error}}`,retry:`Run again`,overall:{ok:`All checks passed — this virtual printer is set up correctly.`,warnings:`The virtual printer should work, but some things need attention.`,problems:`Found problems that explain why the slicer can't see or use this virtual printer.`},check:{enabled:{title:`Virtual printer enabled`,fail:`This virtual printer is switched off. Toggle it on to make it discoverable.`},running:{title:`Services running`,fail:`The virtual printer is enabled but its services are not running. Check the Bambuddy log — a bind IP conflict or a permission error usually stops them.`},bind_interface:{title:`Bind network interface`,fail:`The bind interface is not set, or no longer exists on this host. Pick a current interface in the Bind Interface dropdown.`},access_code:{title:`Access code set`,fail:`No access code is set. The slicer must be given the same 8-character access code you set here.`},target_printer:{title:`Target printer`,fail:`No target printer is selected. Proxy mode needs a real printer to forward to.`,warn:`The target printer is offline right now — proxying will resume once it reconnects.`},port_ftps:{title:`File-upload service (port {{port}})`,fail:`Nothing is listening on port {{port}} of the bind IP, so the slicer cannot upload files. A port conflict on this interface is the usual cause.`},port_mqtt:{title:`Control service (port {{port}})`,fail:`Nothing is listening on port {{port}} of the bind IP, so the slicer cannot connect or show status.`},port_bind:{title:`Discovery service (port {{port}})`,fail:`Nothing is listening on port {{port}} of the bind IP, so the slicer's discovery handshake fails.`},privileged_ports:{title:`Privileged port binding`,fail:`Port {{port}} is below 1024, and this service is not permitted to bind it — which is why nothing is listening above. Add AmbientCapabilities=CAP_NET_BIND_SERVICE to /etc/systemd/system/bambuddy.service and restart, or run "sudo setcap cap_net_bind_service=+ep $(readlink -f $(which python3))". On Docker, add cap_add: [NET_BIND_SERVICE].`},certificate:{title:`TLS certificate`,pass:`Certificate ready. Make sure the Bambuddy CA certificate (above) is imported into your slicer's trust store.`,fail:`The TLS certificate for this virtual printer is missing. Check that the Bambuddy data directory is writable.`}}},bugReport:{title:`Report a Bug`,description:`Description`,descriptionPlaceholder:`What went wrong? Please describe the issue...`,email:`Email (optional)`,emailPlaceholder:`your@email.com`,emailPrivacy:`If provided, your email will be included in a collapsed section of the GitHub issue so the maintainer can follow up.`,screenshot:`Screenshot`,uploadOrPaste:`Upload, paste, or drag an image`,dataCollectedSummary:`What data is included in the report?`,dataIncluded:`Included:`,dataIncludedList:`App version, OS, architecture, Python version, database stats (counts only), printer models, nozzle counts, firmware versions, connectivity status, integration status (Spoolman, MQTT, HA), non-sensitive settings, network interface count, Docker details, dependency versions.`,dataNeverIncluded:`Never included:`,dataNeverIncludedList:`Printer names, serial numbers, access codes, passwords, IP addresses, email addresses, API keys, tokens, webhook URLs, hostnames, or usernames.`,submit:`Submit`,startLogging:`Start Debug Logging`,stepEnableLogging:`Debug logging enabled`,stepReproduce:`Reproduce the issue now`,stepStopLogging:`Stop & submit report`,stopAndSubmit:`Stop & Submit`,maxDuration:`Auto-stops after {{minutes}} min`,stoppingLogs:`Collecting logs & submitting...`,submitting:`Submitting bug report...`,submittingStepConnection:`Running printer connectivity checks`,submittingStepVirtualPrinters:`Running virtual-printer setup checks`,submittingStepLogScan:`Scanning recent logs for known issues`,submittingStepSubmit:`Submitting report to GitHub`,submitSuccess:`Bug report submitted successfully!`,submitFailed:`Failed to submit bug report`,diagnosticChecking:`Checking printer connections...`,diagnosticHealthy:`Connection check passed — no problems found on your printers.`,diagnosticSummary:`{{problems}} of {{total}} printers have connection issues`,diagnosticIntro:`One or more printers have a connection problem that may be causing your issue. Expand a printer below to see the fix — resolving it could solve the problem without a bug report. You can still submit a report below.`,logHealthSummary:`Known issues found in your logs`,logHealthIntro:`Recent logs match known problems. Check the fixes below — resolving them could solve your issue without a bug report. You can still submit a report below.`,thankYou:`Thank you!`,submitted:`Your bug report has been submitted.`,viewIssue:`View Issue`,closeKeepsRecording:`You can close this panel while you reproduce the problem — recording keeps running, and reopening brings you back here.`,resumeRecording:`Bug report recording — {{elapsed}}. Click to finish.`,resumeReport:`Resume report`,unexpectedError:`An unexpected error occurred`},failureDetection:{title:`AI Failure Detection`,description:`Monitor prints with a self-hosted Obico ML API and act on detected failures automatically.`,mlUrl:`Obico ML API URL`,mlUrlHint:`Base URL of your self-hosted Obico ml_api container (e.g. http://192.168.1.10:3333).`,mlToken:`ML API Token (optional)`,mlTokenPlaceholder:`Leave empty if the server runs without ML_API_TOKEN`,mlTokenHint:`Must match the ML_API_TOKEN environment variable of your Obico ml_api container. Leave empty when the container runs without one.`,test:`Test`,testSuccess:`ML API reachable and healthy.`,testSuccessTokenUnknown:`ML API reachable and healthy. The token could not be checked.`,testFailed:`Could not reach the ML API.`,sensitivity:`Sensitivity`,sensitivityLow:`Low (fewer false positives)`,sensitivityMedium:`Medium (balanced)`,sensitivityHigh:`High (detect early, more false positives)`,sensitivityHint:`Adjusts the confidence thresholds that trigger warnings and failures.`,action:`Action on detected failure`,actionNotify:`Notify only`,actionPause:`Pause print`,actionPauseOff:`Pause and cut power`,pollInterval:`Poll interval (seconds)`,pollIntervalHint:`How often to check each printer while it is printing. Minimum 5s, maximum 120s.`,externalUrlMissing:`External URL is not set.`,externalUrlHint:`The ML API fetches the camera snapshot by URL. Set the External URL in General settings so the ML API container can reach Bambuddy.`,perPrinterTitle:`Monitored Printers`,perPrinterHint:`Choose which printers the detection service watches.`,monitorAll:`Monitor all connected printers`,statusTitle:`Status`,serviceRunning:`Service running`,thresholds:`Low / High thresholds`,activePrinters:`Active prints`,noActivePrints:`No prints currently running.`,historyTitle:`Recent Detections`,noHistory:`No detections yet.`},modelSources:{title:`Model Sources`,tabMakerworld:`MakerWorld`,tabManyfold:`Manyfold`},manyfold:{description:`Browse and search your Manyfold library and import its files to slice and print them.`,notConnectedTitle:`Manyfold is not connected`,notConnectedBody:`Ask an administrator to connect your Manyfold library.`,connectionTitle:`Manyfold connection`,connectionHelp:`In Manyfold, open Settings → API and create an application with the scopes "public" and "read". Enter its client ID and secret here. Bambuddy sees the models the application's owner can see.`,url:`Manyfold URL`,urlPlaceholder:`http://192.168.1.10:3214`,clientId:`Client ID`,clientSecret:`Client secret`,clientSecretStored:`Stored. Leave empty to keep it.`,test:`Test connection`,testOk:`Connected. Models Bambuddy can see: {{count}}`,disconnect:`Disconnect`,disconnectTitle:`Disconnect Manyfold?`,disconnectBody:`Bambuddy forgets the Manyfold URL, client ID and secret. Files you imported stay in your library.`,disconnected:`Manyfold disconnected`,editConnection:`Connection`,searchPlaceholder:`Search models`,modelCount:`Models: {{count}}`,noModels:`No models found.`,previous:`Previous`,next:`Next`,page:`Page {{page}}`,back:`Back to models`,openInManyfold:`Open in Manyfold`,license:`License`,files:`Files`,noFiles:`This model has no files.`,importTo:`Import to`,folderAuto:`Manyfold folder`,import:`Import`,importing:`Importing…`,imported:`Imported {{filename}}`,alreadyInLibrary:`Already in your library`,inLibrary:`In library`,showInLibrary:`Show in library`,notImportable:`Bambuddy can't slice or print this type`,selectAll:`Select all`,selectFile:`Select {{name}}`,importSelected:`Import selected ({{count}})`,importAll:`Import all`,importProgress:`Importing {{current}}/{{total}}`,bulkDone:`Imported: {{imported}} · already in library: {{existing}} · failed: {{failed}}`,bulkFailed:`Not imported: {{names}}. {{reason}}`,bulkNothing:`Nothing to import: every printable file is already in your library.`,selectModel:`Select {{name}}`,selectPage:`Select page`,modelsSelected:`Models selected: {{count}}`,importModels:`Import their files`,clearSelection:`Clear selection`,collectProgress:`Reading models {{current}}/{{total}}`,modelsUnreadable:`Could not read: {{names}}`,errors:{manyfold_not_configured:`Manyfold is not connected.`,manyfold_credentials:`Manyfold did not accept the client ID or secret.`,manyfold_scope:`The Manyfold application needs the "read" scope. Edit it in Manyfold under Settings → API.`,manyfold_rate_limited:`Manyfold is limiting sign-ins. Try again in a few minutes.`,manyfold_unreachable:`Bambuddy can't reach Manyfold. Check the URL and that Manyfold is running.`,manyfold_forbidden:`Manyfold refused access. Check that the application's owner can see this model.`,manyfold_not_found:`Manyfold can't find this model or file.`,manyfold_too_large:`The file is larger than 200 MB.`,manyfold_not_importable:`Only 3MF, STL and STEP files can be imported.`,manyfold_bad_url:`Enter the Manyfold URL starting with http:// or https://.`,manyfold_secret_required:`Enter the client secret.`,manyfold_failed:`Manyfold answered with an error.`}},makerworld:{title:`MakerWorld`,description:`Paste a MakerWorld model URL to import and print it directly from Bambuddy — without leaving for the Bambu Handy app.`,pasteUrlHeader:`Import from MakerWorld`,pasteUrlPlaceholder:`https://makerworld.com/en/models/… or paste any MakerWorld link`,resolveButton:`Resolve`,signInRequiredTitle:`Bambu Cloud sign-in required to download`,signInRequiredBody:`You can browse model details anonymously, but MakerWorld requires a Bambu Cloud account to download 3MF files.`,signInExpiredTitle:`Bambu Cloud sign-in expired`,signInExpiredBody:`You are still signed in to Bambuddy, but Bambu Lab has stopped accepting the stored token, so downloads will fail. Sign in to Bambu Cloud again.`,openCloudSettings:`Open Cloud settings`,untitledModel:`Untitled model`,byCreator:`by {{name}}`,downloadsCount:`{{count}} downloads`,licensePrefix:`License`,alreadyImported:`Already in library`,openOnMakerworld:`Open on MakerWorld`,alreadyInLibrary:`This model is already in your library — find it in File Manager → MakerWorld`,importSuccess:`Imported {{filename}} — saved to File Manager → MakerWorld`,platesHeader:`Plates ({{count}})`,plateDefaultName:`Plate {{n}}`,materialCount:`{{count}} filaments`,amsRequired:`AMS required`,slicedFor:`Sliced for {{printer}}`,alsoCompatible:`Also marked compatible: {{printers}}`,importToLibrary:`Save`,sliceIn:`Save & Slice in {{slicer}}`,disclaimer:`MakerWorld integration uses community-documented API endpoints. Bambuddy is not affiliated with or endorsed by MakerWorld or Bambu Lab.`,lastImportSuccess:`Imported to your library`,lastImportAlreadyInLibrary:`Already in your library`,viewInLibrary:`View in File Manager`,openInBambuStudio:`Open in Bambu Studio`,openInOrcaSlicer:`Open in OrcaSlicer`,importTo:`Import to file manager`,recentImportsHeader:`Recent imports`,phaseResolving:`Resolving`,phaseDownloading:`Downloading`,folderAuto:`MakerWorld (default)`,importAll:`Import all`,importAllProgress:`Importing {{current}}/{{total}}`,openGallery:`Open image gallery`,galleryPrev:`Previous image`,galleryNext:`Next image`,deleteImport:`Remove from library`,importDeleting:`Removing…`,importDeleted:`Removed from library`,confirmDelete:`Remove {{filename}} from the library? This deletes the local file but the plate can be re-imported from MakerWorld.`,errors:{resolveFailed:`Could not resolve that MakerWorld URL.`,downloadFailed:`Download failed. Please try again.`,deleteFailed:`Could not remove the file from the library.`}},gcodeViewer:{filamentSlot:`Filament {{n}}`,loading:`Reading toolpath…`,loadFailed:`Could not load the G-code for this file.`,showTravel:`Travel moves`,topLayer:`Top layer`,bottomLayer:`Bottom layer`,noSource:`No file was given to preview.`,view:{filament:`Filament`,feature:`Feature`,height:`Height`,width:`Width`},feature:{wall:`Walls`,sparseInfill:`Sparse infill`,solidInfill:`Solid infill`,bridge:`Bridge / overhang`,support:`Support`,skirt:`Skirt / brim`,gapFill:`Gap fill`,ironing:`Ironing`,primeTower:`Prime tower`},back:`Back`,backToArchives:`Back to Print Archives`,backToFiles:`Back to File Manager`,plates:`Plates`,plateN:`Plate {{n}}`},libraryTrash:{title:`Trash`,headerButton:`Trash`,headerTooltip:`View files moved to the trash`,backToFiles:`Back to File Manager`,subtitleAdmin:`Deleted files stay here for {{days}} days, then auto-delete. This view shows trashed files for all users.`,subtitleUser:`Deleted files stay here for {{days}} days, then auto-delete.`,loading:`Loading trash…`,loadError:`Could not load the trash.`,empty:`The trash is empty.`,summary:`{{count}} files · {{size}}`,emptyTrash:`Empty trash`,restore:`Restore`,purgeNow:`Delete now`,autoPurgeIn:`Auto-deletes in {{when}}`,days:`days`,retentionLabel:`Auto-delete after`,selectAll:`Select all`,selectOne:`Select {{filename}}`,selectionCount:`{{count}} selected`,bulkRestore:`Restore selected`,bulkPurge:`Delete selected`,col:{filename:`File`,folder:`Folder`,size:`Size`,deleted:`Moved to trash`,autoPurge:`Auto-deletes`,owner:`Owner`,actions:`Actions`},confirm:{purgeTitle:`Delete permanently?`,purgeBody:`{{filename}} will be deleted from disk and cannot be restored.`,emptyTitle:`Empty the trash?`,emptyBody:`All {{count}} files will be deleted from disk. This cannot be undone.`,bulkPurgeTitle:`Delete selected files permanently?`,bulkPurgeBody:`The {{count}} selected files will be deleted from disk and cannot be restored.`,cta:`Delete permanently`},toast:{restored:`File restored.`,restoreFailed:`Could not restore the file.`,purged:`File deleted permanently.`,purgeFailed:`Could not delete the file.`,emptied:`Deleted {{count}} file(s) from trash.`,emptyFailed:`Could not empty the trash.`,retentionSaved:`Auto-delete set to {{days}} days.`,retentionFailed:`Could not save retention setting.`,bulkRestored:`Restored {{count}} file(s).`,bulkPurged:`Deleted {{count}} file(s).`}},libraryPurge:{title:`Purge old files`,headerButton:`Purge old`,headerTooltip:`Bulk-move old files to trash`,description:`Sweep old files out of your library in one shot. Files with a print history are aged by their last-printed date; files that were never printed are aged by their upload date.`,ageLabel:`Move files older than`,days:`days`,includeNeverPrinted:`Include files that have never been printed`,effectsTitle:`What happens when you click Purge`,effect1:`Matching files are moved to Trash — they are not deleted from disk yet.`,effect2:`You can restore them from Trash at any time until the retention window expires.`,effect3:`After retention, the trash sweeper permanently removes them from disk.`,effect4:`Files in external (linked) folders are skipped — Bambuddy never deletes bytes it does not own.`,previewLoading:`Checking how many files match…`,previewFailed:`Could not preview the purge.`,previewSummary:`{{count}} files · {{size}} would move to trash`,andMore:`…and {{count}} more`,warning:`Trashed files still count against storage until the retention window expires. Empty the Trash afterwards to free disk immediately.`,confirmCta:`Move {{count}} to trash`,purging:`Moving to trash…`,toast:{success:`Moved {{count}} file(s) to trash.`,failed:`Could not purge files.`}},libraryAutoPurge:{enableLabel:`Auto-purge old files`,enableDescription:`Runs the admin purge once per day. Files go to Trash first — they are not deleted immediately.`,ageLabel:`Auto-purge files older than`,ageDescription:`Minimum 7 days, maximum 10 years. Uses the same age rule as the manual Purge button.`,days:`days`,includeNeverPrinted:`Include files that have never been printed`,saveFailed:`Could not save auto-purge settings.`},archivePurge:{headerButton:`Purge old`,headerTooltip:`Bulk-delete old archives`,title:`Purge old archives`,description:`Clear out old print history. Each archive is aged by its most recent print completion — reprinting an archive refreshes its age, so active work is never purged.`,ageLabel:`Delete archives not printed in the last`,days:`days`,effectsTitle:`What happens when you click Purge`,effect1:`Each matching archive is hidden from the listings and its files are removed from disk (3MF, thumbnail, timelapse, source 3MF, F3D design file, photos).`,effect2:`The archive row stays in the database so Quick Stats keeps the filament, time, cost, and energy contribution — same as the single-archive delete default.`,effect3:`Tick "Also remove from statistics" below to drop the Quick Stats contribution too (matches the single-archive delete option). That path is irreversible.`,effect4:`Reprinting an archive refreshes its age clock, so archives you still use are safe.`,purgeStatsLabel:`Also remove from statistics`,purgeStatsHint:`Drops the matching archives from Quick Stats (filament, time, cost, energy). Without this, Quick Stats keeps every contribution and only the files leave disk.`,previewLoading:`Checking how many archives match…`,previewFailed:`Could not preview the purge.`,previewSummary:`{{count}} archives · {{size}} would be removed`,andMore:`…and {{count}} more`,warning:`Files are removed from disk and cannot be restored. Download or favourite anything you want to keep before continuing.`,confirmCta:`Remove {{count}} archive(s)`,purging:`Removing…`,toast:{success:`Removed {{count}} archive(s).`,failed:`Could not purge archives.`}},archiveAutoPurge:{enableLabel:`Auto-purge old archives`,enableDescription:`Once per day, hides archives from the listings and removes their files from disk when they have not been printed within the threshold. Reprinting an archive resets the clock.`,ageLabel:`Auto-delete archives not printed in the last`,ageDescription:`Minimum 7 days, maximum 10 years. Based on the most recent print completion — reprinting an archive refreshes its age. Removes the 3MF, thumbnail, timelapse, source 3MF, F3D, and photos.`,days:`days`,purgeStatsLabel:`Also remove from statistics`,purgeStatsDescription:`When enabled, the daily sweeper also drops each purged archive from Quick Stats (filament, time, cost, energy). Default off — Quick Stats keeps the contribution, only the files leave disk.`,runNow:`Purge archives now`,saveFailed:`Could not save auto-purge settings.`},connectedApps:{title:`Connected Apps`,description:`Apps that sign people in with their Bambuddy account. Each app gets a client ID and secret, and Bambuddy only ever sends a sign-in to the callback URL registered here.`,requiresAuth:`Connected apps need Bambuddy authentication. Turn it on under Users first.`,name:`App name`,namePlaceholder:`e.g. Order manager`,callbackUrl:`Callback URL`,callbackHint:`The app's documentation gives its callback URL. It must match exactly.`,add:`Add app`,empty:`No connected apps yet.`,clientId:`Client ID`,clientSecret:`Client secret`,lastUsed:`Last sign-in`,disabledBadge:`Disabled`,enable:`Enable`,disable:`Disable`,rotate:`New secret`,delete:`Delete`,cancel:`Cancel`,copy:`Copy`,secret:{title:`{{name}}: copy the secret now`,warning:`Paste the client ID and secret into the app. The secret is shown only this once; if it's lost, create a new one.`,dismiss:`I've saved it`},confirmRotate:{title:`Create a new secret?`,body:`"{{name}}" stops signing people in until you paste the new secret into it.`},confirmDelete:{title:`Delete this app?`,body:`"{{name}}" can no longer sign anyone in. If it's added again, everyone is asked for permission again.`},toast:{created:`App added`,enabled:`App enabled`,disabled:`App disabled`,rotated:`New secret created`,deleted:`App deleted`,copied:`Copied to clipboard`,copyFailed:`Copy failed. Select the text and copy it manually.`,failed:`Something went wrong`},authorize:{checking:`Checking the sign-in request…`,redirecting:`Signing you in…`,errorTitle:`Can't sign you in`,invalidRequest:`This sign-in request isn't valid: the app isn't registered, is disabled, or uses a different callback URL. Ask your Bambuddy admin to check Settings > API Keys > Connected Apps.`,authDisabled:`Sign-in with Bambuddy isn't available because Bambuddy authentication is turned off. Use the app's own login instead.`,failed:`Sign-in failed. Go back to the app and try again.`,title:`{{app}} wants to sign you in`,signedInAs:`Signed in to Bambuddy as {{username}}`,sharedData:`{{app}} will see your username, email address, groups and permissions. It doesn't get your password or your Bambuddy session.`,allow:`Allow`,deny:`Cancel`}},cameraTokens:{scope:{camera_stream:`Camera stream`,camwall:`Cam Wall`,overlay:`Streaming Overlay`},title:`Camera API Tokens`,navTitle:`Camera API tokens`,description:`Long-lived tokens for embedding the camera stream into Home Assistant, Frigate, kiosks, or any other tool that needs a stable URL. Pick the scope when you create one; a token can be revoked at any time.`,loading:`Loading…`,confirmRevoke:{title:`Revoke this token?`,body:`Any device using "{{name}}" will lose access immediately. This cannot be undone.`,cancel:`Cancel`,confirm:`Revoke`},create:{scopeLabel:`Scope`,hintCameraStream:`A camera-stream token can only fetch camera streams and snapshots. Use it for Home Assistant, Frigate, or anything embedding a single camera.`,hintCamWall:`A Cam Wall token opens /camwall on a screen with no login. It can see every printer's name and state, and their camera streams. It cannot see filenames, addresses or access codes.`,hintOverlay:`A Streaming Overlay token opens /overlay/{printerId} on a screen with no login — for OBS or any live stream. It can see one printer's camera stream plus its live print status, including the filename shown on screen. It cannot see addresses or access codes.`,title:`Create new token`,nameLabel:`Token name`,namePlaceholder:`e.g. Home Assistant`,daysLabel:`Days until expiry`,submit:`Create`,hint:`Maximum lifetime is 365 days. The token value is shown only once on creation — copy it now.`},created:{camWallUrlTitle:`Cam Wall URL for this display`,camWallUrlHint:`Open this on the screen. Anyone who can read the URL can watch the wall, so treat it like a key — revoke the token to cut the display off.`,overlayUrlTitle:`Overlay URL for OBS`,overlayUrlHint:`Add this as a Browser Source in OBS. Change the /overlay/1 number to your printer's number (from its URL on the Printers page). Anyone who can read the URL can watch the stream, so treat it like a key — revoke the token to cut it off.`,title:`Token created — copy it now`,warning:`This is the only time this token will be visible. After you close this dialog you can never view it again.`,copy:`Copy`,dismiss:`I've saved it`},list:{scope:`Scope`,myTitle:`My tokens`,allTitle:`All users (admin view)`,empty:`No tokens yet.`,name:`Name`,owner:`Owner`,prefix:`Prefix`,created:`Created`,expires:`Expires`,lastUsed:`Last used`,revoke:`Revoke`,expired:`Expired`},toast:{created:`Token created`,createFailed:`Failed to create token`,revoked:`Token revoked`,revokeFailed:`Failed to revoke token`,loadFailed:`Failed to load tokens`,copied:`Copied to clipboard`,copyFailed:`Copy failed — select and copy manually`}},forecast:{title:`Forecast`,noSpools:`No active spools found. Add spools to your inventory to see forecast data.`,noUsageData:`No usage data available — cannot project stock timeline.`,sku:`SKU`,material:`Material`,stock:`Stock`,dailyRate:`Rate`,daysLeft:`Days Left`,emptyBy:`Empty By`,reorderBy:`Reorder By`,actions:`Actions`,trend:`Trend`,estimated:`Est.`,noData:`No data`,timeframe:`Timeframe`,chartTitle:`Projected Stock — Top 5 Materials`,dashedLinesROP:`Dashed lines = reorder points`,stockLevel:`Stock Level`,reorderPoint:`Reorder Point`,safetyMargin:`Safety Margin`,trendLegend:`Trend (history-based, 95% service level)`,estimatedLegend:`Estimated (weight delta)`,noDataLegend:`No data`,ropLabel:`ROP`,ssLabel:`SS`,safetyStockLegend:`Safety stock`,stockArrivalLegend:`Stock arrival`,stockoutLegend:`Stockout`,alertCount_one:`{{count}} alert`,alertCount_other:`{{count}} alerts`,order:`Order`,save:`Save`,cancel:`Cancel`,settingsSaved:`Settings saved`,failedSaveSettings:`Failed to save settings`,globalLeadTimeSaved:`Global lead time saved`,globalLeadTime:`Global lead time`,globalLeadTimeHint:`Global lead time floor — used in reorder point calculation for all SKUs`,skuLeadTimeOverride:`Lead Time Override`,skuLeadTimeHint:`0 = use global lead time. Set >0 to override for this SKU.`,safetyMarginLabel:`Safety Margin`,effectiveLeadTime:`Effective Lead Time`,effectiveLeadTimeHint:`max(global {{global}}d, SKU {{sku}}d)`,reorderPointHint:`d̄ × LT + safety margin — order when stock hits this level`,safetyMarginHint:`Statistical safety stock (z=1.65 × σ × √LT) + user-defined buffer`,safetyMarginHintDays:`Buffer added on top of statistical safety stock.{{approx}}`,safetyMarginHintDaysApprox:` ≈ {{g}}g at current rate.`,safetyMarginHintG:`Fixed weight buffer added on top of statistical safety stock.{{approx}}`,safetyMarginHintGApprox:` ≈ {{days}}d at current rate.`,individualSpools:`Individual spools`,labelWeight:`Label`,spoolCount_one:`{{count}} spool`,spoolCount_other:`{{count}} spools`,stockBreakRisk:`Stock break risk`,stockBreakDetail:`{{days}}d remaining, lead time {{lt}}d.`,stockBreakBefore:`Stock break before replenishment`,reorderNow:`Reorder now`,reorderTriggerPassed:`Trigger date {{date}} has passed.`,shoppingList:`Shopping List`,shoppingListItems_one:`({{count}} item)`,shoppingListItems_other:`({{count}} items)`,shoppingListEmpty:`Shopping list is empty. Click the cart icon on any row to add items.`,addToCart:`Add to shopping list`,alertsSnoozed:`Mute alerts for this SKU`,alertsEnabled:`Unmute alerts for this SKU`,addedToCart:`Added to shopping list`,failedAddItem:`Failed to add item`,listView:`List`,logisticsView:`Logistics`,qty:`Qty`,weight:`Weight`,leadTime:`Lead Time`,expectedRestock:`Expected Restock`,status:`Status`,note:`Note`,pending:`Pending`,purchased:`Purchased`,received:`Received`,markPurchased:`Mark as purchased`,markReceived:`Mark as received — adds spools to Stock inventory`,resetToPending:`Reset to pending`,remove:`Remove`,clearAll:`Clear all`,downloadCsv:`CSV`,addToCartTitle:`Add to Shopping List`,byQuantity:`By Quantity`,byDuration:`By Duration`,numberOfSpools:`Number of spools`,lastHowManyDays:`Should last how many days?`,noUsageQty:`No usage data — quantity set to 1.`,noteOptional:`Note (optional)`,notePlaceholder:`e.g. for project X, urgent…`,addNSpools_one:`Add {{count}} spool`,addNSpools_other:`Add {{count}} spools`,onArrival:`On Arrival`,stockBreakIn:`Stock break in {{days}}d.`,stockRunsOutBefore:`Stock runs out before the {{lt}}d lead time elapses.`,atRate:`At {{rate}}g/day you need`,moreSpools_one:`{{count}} more spool`,moreSpools_other:`{{count}} more spools`,bridgeGap:`to bridge the gap.`,noReadAccess:`You do not have permission to view inventory forecasts.`,noWriteAccess:`You do not have permission to modify forecast settings.`}},hn=`modulepreload`,gn=function(e){return`/`+e},_n={},q=function(e,t,n){let r=Promise.resolve();if(t&&t.length>0){let e=document.getElementsByTagName(`link`),i=document.querySelector(`meta[property=csp-nonce]`),a=i?.nonce||i?.getAttribute(`nonce`);function o(e){return Promise.all(e.map(e=>Promise.resolve(e).then(e=>({status:`fulfilled`,value:e}),e=>({status:`rejected`,reason:e}))))}r=o(t.map(t=>{if(t=gn(t,n),t in _n)return;_n[t]=!0;let r=t.endsWith(`.css`),i=r?`[rel="stylesheet"]`:``;if(n)for(let n=e.length-1;n>=0;n--){let i=e[n];if(i.href===t&&(!r||i.rel===`stylesheet`))return}else if(document.querySelector(`link[href="${t}"]${i}`))return;let o=document.createElement(`link`);if(o.rel=r?`stylesheet`:hn,r||(o.as=`script`),o.crossOrigin=``,o.href=t,a&&o.setAttribute(`nonce`,a),document.head.appendChild(o),r)return new Promise((e,n)=>{o.addEventListener(`load`,e),o.addEventListener(`error`,()=>n(Error(`Unable to preload CSS for ${t}`)))})}))}function i(e){let t=new Event(`vite:preloadError`,{cancelable:!0});if(t.payload=e,window.dispatchEvent(t),!t.defaultPrevented)throw e}return r.then(t=>{for(let e of t||[])e.status===`rejected`&&i(e.reason);return e().catch(i)})},vn={de:()=>q(()=>import(`./de-DvnDPDo7.js`),[]),es:()=>q(()=>import(`./es-DZZ0IPDC.js`),[]),fr:()=>q(()=>import(`./fr-D9McbtW3.js`),[]),ja:()=>q(()=>import(`./ja-T2xC1zs8.js`),[]),it:()=>q(()=>import(`./it-BpOecomy.js`),[]),nl:()=>q(()=>import(`./nl-CtZfK3Nf.js`),[]),ko:()=>q(()=>import(`./ko-C1--UcOC.js`),[]),"pt-BR":()=>q(()=>import(`./pt-BR-CrNWoBDc.js`),[]),"zh-CN":()=>q(()=>import(`./zh-CN-zENHv8ar.js`),[]),"zh-TW":()=>q(()=>import(`./zh-TW-BbdM61yf.js`),[]),sv:()=>q(()=>import(`./sv-BB_QxdtQ.js`),[]),tr:()=>q(()=>import(`./tr-BBzKsz9z.js`),[]),ru:()=>q(()=>import(`./ru-BH6X9QDA.js`),[]),uk:()=>q(()=>import(`./uk-BYvqnFMj.js`),[])},yn={type:`backend`,init(){},read(e,t,n){let r=vn[e];if(!r){n(null,{});return}r().then(e=>n(null,e.default),e=>{pn().then(t=>{t||n(e,null)})})}},bn=[`en`,`de`,`es`,`fr`,`ja`,`it`,`ko`,`nl`,`pt-BR`,`ru`,`sv`,`tr`,`uk`,`zh-CN`,`zh-TW`],xn=`bambuddy_appliance_locale_consumed`,Sn=Ft.use(yn).use(on).use(i).init({resources:{en:{translation:mn}},partialBundledLanguages:!0,fallbackLng:`en`,supportedLngs:bn,detection:{order:[`localStorage`,`navigator`,`htmlTag`],lookupLocalStorage:`bambutrack_language`,caches:[`localStorage`]},interpolation:{escapeValue:!1},react:{useSuspense:!1}});function Cn(){if(typeof window>`u`||!window.localStorage)return;let e=window.localStorage;typeof e.getItem!=`function`||typeof e.setItem!=`function`||e.getItem(xn)||fetch(`/api/v1/system/appliance`).then(e=>e.ok?e.json():null).then(t=>{!t||typeof t.locale!=`string`||bn.includes(t.locale)&&(Ft.changeLanguage(t.locale),e.setItem(xn,`1`))}).catch(()=>{})}Cn();var wn=[{code:`en`,name:`English`,nativeName:`English`},{code:`de`,name:`German`,nativeName:`Deutsch`},{code:`es`,name:`Spanish`,nativeName:`Español`},{code:`fr`,name:`French`,nativeName:`Français`},{code:`ja`,name:`Japanese`,nativeName:`日本語`},{code:`it`,name:`Italian`,nativeName:`Italiano`},{code:`ko`,name:`Korean`,nativeName:`한국어`},{code:`nl`,name:`Dutch`,nativeName:`Nederlands`},{code:`pt-BR`,name:`Portuguese (Brazil)`,nativeName:`Português (Brasil)`},{code:`zh-CN`,name:`Chinese (Simplified)`,nativeName:`简体中文`},{code:`zh-TW`,name:`Chinese (Traditional)`,nativeName:`繁體中文`},{code:`sv`,name:`Swedish`,nativeName:`Svenska`},{code:`tr`,name:`Turkish`,nativeName:`Türkçe`},{code:`ru`,name:`Russian`,nativeName:`Русский`},{code:`uk`,name:`Ukrainian`,nativeName:`Українська`}],Tn=/^(?:[a-z][a-z0-9+.-]*:|[\\/]{2})/i,En=/^[\\/]{2}/;function Dn(e,t){return t+e.replace(/\\/g,`/`)}var On=`popstate`;function kn(e){return typeof e==`object`&&!!e&&`pathname`in e&&`search`in e&&`hash`in e&&`state`in e&&`key`in e}function An(e={}){function t(e,t){let n=t.state?.masked,{pathname:r,search:i,hash:a}=n||e.location;return Fn(``,{pathname:r,search:i,hash:a},t.state&&t.state.usr||null,t.state&&t.state.key||`default`,n?{pathname:e.location.pathname,search:e.location.search,hash:e.location.hash}:void 0)}function n(e,t){return typeof t==`string`?t:In(t)}return Rn(t,n,null,e)}function jn(e,t){if(e===!1||e==null)throw Error(t)}function Mn(e,t){if(!e){typeof console<`u`&&console.warn(t);try{throw Error(t)}catch{}}}function Nn(){return Math.random().toString(36).substring(2,10)}function Pn(e,t){return{usr:e.state,key:e.key,idx:t,masked:e.mask?{pathname:e.pathname,search:e.search,hash:e.hash}:void 0}}function Fn(e,t,n=null,r,i){return{pathname:typeof e==`string`?e:e.pathname,search:``,hash:``,...typeof t==`string`?Ln(t):t,state:n,key:t&&t.key||r||Nn(),mask:i}}function In({pathname:e=`/`,search:t=``,hash:n=``}){return t&&t!==`?`&&(e+=t.charAt(0)===`?`?t:`?`+t),n&&n!==`#`&&(e+=n.charAt(0)===`#`?n:`#`+n),e}function Ln(e){let t={};if(e){let n=e.indexOf(`#`);n>=0&&(t.hash=e.substring(n),e=e.substring(0,n));let r=e.indexOf(`?`);r>=0&&(t.search=e.substring(r),e=e.substring(0,r)),e&&(t.pathname=e)}return t}function Rn(e,t,n,r={}){let{window:i=document.defaultView,v5Compat:a=!1}=r,o=i.history,s=`POP`,c=null,l=u();l??(l=0,o.replaceState({...o.state,idx:l},``));function u(){return(o.state||{idx:null}).idx}function d(){s=`POP`;let e=u(),t=e==null?null:e-l;l=e,c&&c({action:s,location:h.location,delta:t})}function f(e,t){s=`PUSH`;let r=kn(e)?e:Fn(h.location,e,t);n&&n(r,e),l=u()+1;let d=Pn(r,l),f=h.createHref(r.mask||r);try{o.pushState(d,``,f)}catch(e){if(e instanceof DOMException&&e.name===`DataCloneError`)throw e;i.location.assign(f)}a&&c&&c({action:s,location:h.location,delta:1})}function p(e,t){s=`REPLACE`;let r=kn(e)?e:Fn(h.location,e,t);n&&n(r,e),l=u();let i=Pn(r,l),d=h.createHref(r.mask||r);o.replaceState(i,``,d),a&&c&&c({action:s,location:h.location,delta:0})}function m(e){return zn(i,e)}let h={get action(){return s},get location(){return e(i,o)},listen(e){if(c)throw Error(`A history only accepts one active listener`);return i.addEventListener(On,d),c=e,()=>{i.removeEventListener(On,d),c=null}},createHref(e){return t(i,e)},createURL:m,encodeLocation(e){let t=m(e);return{pathname:t.pathname,search:t.search,hash:t.hash}},push:f,replace:p,go(e){return o.go(e)}};return h}function zn(e,t,n=!1){let r=`http://localhost`;e&&(r=e.location.origin===`null`?e.location.href:e.location.origin),jn(r,`No window.location.(origin|href) available to create URL`);let i=typeof t==`string`?t:In(t);return i=i.replace(/ $/,`%20`),!n&&En.test(i)&&(i=r+i),new URL(i,r)}function Bn(e,t,n=`/`){return Vn(e,t,n,!1)}function Vn(e,t,n,r,i){let a=sr((typeof t==`string`?Ln(t):t).pathname||`/`,n);if(a==null)return null;let o=i??Un(e),s=null,c=or(a);for(let e=0;s==null&&e<o.length;++e)s=nr(o[e],c,r);return s}function Hn(e,t){let{route:n,pathname:r,params:i}=e;return{id:n.id,pathname:r,params:i,data:t[n.id],loaderData:t[n.id],handle:n.handle}}function Un(e){let t=Wn(e);return Kn(t),t}function Wn(e,t=[],n=[],r=``,i=!1){let a=(e,a,o=i,s)=>{let c={relativePath:s===void 0?e.path||``:s,caseSensitive:e.caseSensitive===!0,childrenIndex:a,route:e};if(c.relativePath.startsWith(`/`)){if(!c.relativePath.startsWith(r)&&o)return;jn(c.relativePath.startsWith(r),`Absolute route path "${c.relativePath}" nested under path "${r}" is not valid. An absolute child route path must start with the combined path of all its parent routes.`),c.relativePath=c.relativePath.slice(r.length)}let l=hr([r,c.relativePath]),u=n.concat(c);e.children&&e.children.length>0&&(jn(e.index!==!0,`Index routes must not have child routes. Please remove all child routes from route path "${l}".`),Wn(e.children,t,u,l,o)),!(e.path==null&&!e.index)&&t.push({path:l,score:er(l,e.index),routesMeta:u.map((e,t)=>{let[n,r]=ar(e.relativePath,e.caseSensitive,t===u.length-1);return{...e,matcher:n,compiledParams:r}})})};return e.forEach((e,t)=>{if(e.path===``||!e.path?.includes(`?`))a(e,t);else for(let n of Gn(e.path))a(e,t,!0,n)}),t}function Gn(e){let t=e.split(`/`);if(t.length===0)return[];let[n,...r]=t,i=n.endsWith(`?`),a=n.replace(/\?$/,``);if(r.length===0)return i?[a,``]:[a];let o=Gn(r.join(`/`)),s=[];return s.push(...o.map(e=>e===``?a:[a,e].join(`/`))),i&&s.push(...o),s.map(t=>e.startsWith(`/`)&&t===``?`/`:t)}function Kn(e){e.sort((e,t)=>e.score===t.score?tr(e.routesMeta.map(e=>e.childrenIndex),t.routesMeta.map(e=>e.childrenIndex)):t.score-e.score)}var qn=/^:[\w-]+$/,Jn=3,Yn=2,Xn=1,Zn=10,Qn=-2,$n=e=>e===`*`;function er(e,t){let n=e.split(`/`),r=n.length;return n.some($n)&&(r+=Qn),t&&(r+=Yn),n.filter(e=>!$n(e)).reduce((e,t)=>e+(qn.test(t)?Jn:t===``?Xn:Zn),r)}function tr(e,t){return e.length===t.length&&e.slice(0,-1).every((e,n)=>e===t[n])?e[e.length-1]-t[t.length-1]:0}function nr(e,t,n=!1){let{routesMeta:r}=e,i={},a=`/`,o=[];for(let e=0;e<r.length;++e){let s=r[e],c=e===r.length-1,l=a===`/`?t:t.slice(a.length)||`/`,u={path:s.relativePath,caseSensitive:s.caseSensitive,end:c},d=s.matcher&&s.compiledParams?ir(u,l,s.matcher,s.compiledParams):rr(u,l),f=s.route;if(!d&&c&&n&&!r[r.length-1].route.index&&(d=rr({path:s.relativePath,caseSensitive:s.caseSensitive,end:!1},l)),!d)return null;Object.assign(i,d.params),o.push({params:i,pathname:hr([a,d.pathname]),pathnameBase:_r(hr([a,d.pathnameBase])),route:f}),d.pathnameBase!==`/`&&(a=hr([a,d.pathnameBase]))}return o}function rr(e,t){typeof e==`string`&&(e={path:e,caseSensitive:!1,end:!0});let[n,r]=ar(e.path,e.caseSensitive,e.end);return ir(e,t,n,r)}function ir(e,t,n,r){let i=t.match(n);if(!i)return null;let a=i[0],o=a.replace(/(.)\/+$/,`$1`),s=i.slice(1);return{params:r.reduce((e,{paramName:t,isOptional:n},r)=>{if(t===`*`){let e=s[r]||``;o=a.slice(0,a.length-e.length).replace(/(.)\/+$/,`$1`)}let i=s[r];return n&&!i?e[t]=void 0:e[t]=(i||``).replace(/%2F/g,`/`),e},{}),pathname:a,pathnameBase:o,pattern:e}}function ar(e,t=!1,n=!0){Mn(e===`*`||!e.endsWith(`*`)||e.endsWith(`/*`),`Route path "${e}" will be treated as if it were "${e.replace(/\*$/,`/*`)}" because the \`*\` character must always follow a \`/\` in the pattern. To get rid of this warning, please change the route path to "${e.replace(/\*$/,`/*`)}".`);let r=[],i=`^`+e.replace(/\/*\*?$/,``).replace(/^\/*/,`/`).replace(/[\\.*+^${}|()[\]]/g,`\\$&`).replace(/\/:([\w-]+)(\?)?/g,(e,t,n,i,a)=>{if(r.push({paramName:t,isOptional:n!=null}),n){let t=a.charAt(i+e.length);return t&&t!==`/`?`/([^\\/]*)`:`(?:/([^\\/]*))?`}return`/([^\\/]+)`}).replace(/\/([\w-]+)\?(\/|$)/g,`(/$1)?$2`);return e.endsWith(`*`)?(r.push({paramName:`*`}),i+=e===`*`||e===`/*`?`(.*)$`:`(?:\\/(.+)|\\/*)$`):n?i+=`\\/*$`:e!==``&&e!==`/`&&(i+=`(?:(?=\\/|$))`),[new RegExp(i,t?void 0:`i`),r]}function or(e){try{return e.split(`/`).map(e=>decodeURIComponent(e).replace(/\//g,`%2F`)).join(`/`)}catch(t){return Mn(!1,`The URL path "${e}" could not be decoded because it is a malformed URL segment. This is probably due to a bad percent encoding (${t}).`),e}}function sr(e,t){if(t===`/`)return e;if(!e.toLowerCase().startsWith(t.toLowerCase()))return null;let n=t.endsWith(`/`)?t.length-1:t.length,r=e.charAt(n);return r&&r!==`/`?null:e.slice(n)||`/`}function cr(e,t=`/`){let{pathname:n,search:r=``,hash:i=``}=typeof e==`string`?Ln(e):e,a;return n?(n=mr(n),a=n.startsWith(`/`)?lr(n.substring(1),`/`):lr(n,t)):a=t,{pathname:a,search:vr(r),hash:yr(i)}}function lr(e,t){let n=gr(t).split(`/`);return e.split(`/`).forEach(e=>{e===`..`?n.length>1&&n.pop():e!==`.`&&n.push(e)}),n.length>1?n.join(`/`):`/`}function ur(e,t,n,r){return`Cannot include a '${e}' character in a manually specified \`to.${t}\` field [${JSON.stringify(r)}]. Please separate it out to the \`to.${n}\` field. Alternatively you may provide the full path as a string in <Link to="..."> and the router will parse it for you.`}function dr(e){return e.filter((e,t)=>t===0||e.route.path&&e.route.path.length>0)}function fr(e){let t=dr(e);return t.map((e,n)=>n===t.length-1?e.pathname:e.pathnameBase)}function pr(e,t,n,r=!1){let i;typeof e==`string`?i=Ln(e):(i={...e},jn(!i.pathname||!i.pathname.includes(`?`),ur(`?`,`pathname`,`search`,i)),jn(!i.pathname||!i.pathname.includes(`#`),ur(`#`,`pathname`,`hash`,i)),jn(!i.search||!i.search.includes(`#`),ur(`#`,`search`,`hash`,i)));let a=e===``||i.pathname===``,o=a?`/`:i.pathname,s;if(o==null)s=n;else{let e=t.length-1;if(!r&&o.startsWith(`..`)){let t=o.split(`/`);for(;t[0]===`..`;)t.shift(),--e;i.pathname=t.join(`/`)}s=e>=0?t[e]:`/`}let c=cr(i,s),l=o&&o!==`/`&&o.endsWith(`/`),u=(a||o===`.`)&&n.endsWith(`/`);return!c.pathname.endsWith(`/`)&&(l||u)&&(c.pathname+=`/`),c}var mr=e=>e.replace(/[\\/]{2,}/g,`/`),hr=e=>mr(e.join(`/`)),gr=e=>e.replace(/\/+$/,``),_r=e=>gr(e).replace(/^\/*/,`/`),vr=e=>!e||e===`?`?``:e.startsWith(`?`)?e:`?`+e,yr=e=>!e||e===`#`?``:e.startsWith(`#`)?e:`#`+e,br=class{constructor(e,t,n,r=!1){this.status=e,this.statusText=t||``,this.internal=r,n instanceof Error?(this.data=n.toString(),this.error=n):this.data=n}};function xr(e){return e!=null&&typeof e.status==`number`&&typeof e.statusText==`string`&&typeof e.internal==`boolean`&&`data`in e}function Sr(e){return hr(e.map(e=>e.route.path).filter(Boolean))||`/`}var Cr=typeof window<`u`&&window.document!==void 0&&window.document.createElement!==void 0;function wr(e,t){let n=e;if(typeof n!=`string`||!Tn.test(n))return{absoluteURL:void 0,isExternal:!1,to:n};let r=n,i=!1;if(Cr)try{let e=new URL(window.location.href),r=En.test(n)?new URL(Dn(n,e.protocol)):new URL(n),a=sr(r.pathname,t);r.origin===e.origin&&a!=null?n=a+r.search+r.hash:i=!0}catch{Mn(!1,`<Link to="${n}"> contains an invalid URL which will probably break when clicked - please update to a valid URL path.`)}return{absoluteURL:r,isExternal:i,to:n}}Object.getOwnPropertyNames(Object.prototype).sort().join(`\0`);var Tr=[`POST`,`PUT`,`PATCH`,`DELETE`];new Set(Tr);var Er=[`GET`,...Tr];new Set(Er);var Dr=[`about:`,`blob:`,`chrome:`,`chrome-untrusted:`,`content:`,`data:`,`devtools:`,`file:`,`filesystem:`,`javascript:`];function Or(e){try{return Dr.includes(new URL(e).protocol)}catch{return!1}}var kr=W.createContext(null);kr.displayName=`DataRouter`;var Ar=W.createContext(null);Ar.displayName=`DataRouterState`;var jr=W.createContext(!1);function Mr(){return W.useContext(jr)}var Nr=W.createContext({isTransitioning:!1});Nr.displayName=`ViewTransition`;var Pr=W.createContext(new Map);Pr.displayName=`Fetchers`;var Fr=W.createContext(null);Fr.displayName=`Await`;var Ir=W.createContext(null);Ir.displayName=`Navigation`;var Lr=W.createContext(null);Lr.displayName=`Location`;var Rr=W.createContext({outlet:null,matches:[],isDataRoute:!1});Rr.displayName=`Route`;var zr=W.createContext(null);zr.displayName=`RouteError`;var Br=`REACT_ROUTER_ERROR`,Vr=`REDIRECT`,Hr=`ROUTE_ERROR_RESPONSE`;function Ur(e){if(e.startsWith(`${Br}:${Vr}:{`))try{let t=JSON.parse(e.slice(28));if(typeof t==`object`&&t&&typeof t.status==`number`&&typeof t.statusText==`string`&&typeof t.location==`string`&&typeof t.reloadDocument==`boolean`&&typeof t.replace==`boolean`)return t}catch{}}function Wr(e){if(e.startsWith(`${Br}:${Hr}:{`))try{let t=JSON.parse(e.slice(40));if(typeof t==`object`&&t&&typeof t.status==`number`&&typeof t.statusText==`string`)return new br(t.status,t.statusText,t.data)}catch{}}function Gr(e,{relative:t}={}){jn(Kr(),`useHref() may be used only in the context of a <Router> component.`);let{basename:n,navigator:r}=W.useContext(Ir),{hash:i,pathname:a,search:o}=ni(e,{relative:t}),s=a;return n!==`/`&&(s=a===`/`?n:hr([n,a])),r.createHref({pathname:s,search:o,hash:i})}function Kr(){return W.useContext(Lr)!=null}function qr(){return jn(Kr(),`useLocation() may be used only in the context of a <Router> component.`),W.useContext(Lr).location}var Jr=`You should call navigate() in a React.useEffect(), not when your component is first rendered.`;function Yr(e){W.useContext(Ir).static||W.useLayoutEffect(e)}function Xr(){let{isDataRoute:e}=W.useContext(Rr);return e?xi():Zr()}function Zr(){jn(Kr(),`useNavigate() may be used only in the context of a <Router> component.`);let e=W.useContext(kr),{basename:t,navigator:n}=W.useContext(Ir),{matches:r}=W.useContext(Rr),{pathname:i}=qr(),a=JSON.stringify(fr(r)),o=W.useRef(!1);return Yr(()=>{o.current=!0}),W.useCallback((r,s={})=>{if(Mn(o.current,Jr),!o.current)return;if(typeof r==`number`){n.go(r);return}let c=pr(r,JSON.parse(a),i,s.relative===`path`);e==null&&t!==`/`&&(c.pathname=c.pathname===`/`?t:hr([t,c.pathname])),(s.replace?n.replace:n.push)(c,s.state,s)},[t,n,a,i,e])}var Qr=W.createContext(null);function $r(){return W.useContext(Qr)}function ei(e){let t=W.useContext(Rr).outlet;return W.useMemo(()=>t&&W.createElement(Qr.Provider,{value:e},t),[t,e])}function ti(){let{matches:e}=W.useContext(Rr);return e[e.length-1]?.params??{}}function ni(e,{relative:t}={}){let{matches:n}=W.useContext(Rr),{pathname:r}=qr(),i=JSON.stringify(fr(n));return W.useMemo(()=>pr(e,JSON.parse(i),r,t===`path`),[e,i,r,t])}function ri(e,t){return ii(e,t)}function ii(e,t,n){jn(Kr(),`useRoutes() may be used only in the context of a <Router> component.`);let{navigator:r}=W.useContext(Ir),{matches:i}=W.useContext(Rr),a=i[i.length-1],o=a?a.params:{},s=a?a.pathname:`/`,c=a?a.pathnameBase:`/`,l=a&&a.route;{let e=l&&l.path||``;Ci(s,!l||e.endsWith(`*`)||e.endsWith(`*?`),`You rendered descendant <Routes> (or called \`useRoutes()\`) at "${s}" (under <Route path="${e}">) but the parent route path has no trailing "*". This means if you navigate deeper, the parent won't match anymore and therefore the child routes will never render.
- Please change the parent <Route path="${e}"> to <Route path="${e===`/`?`*`:`${e}/*`}">.`)}let u=qr(),d;if(t){let e=typeof t==`string`?Ln(t):t;jn(c===`/`||e.pathname?.startsWith(c),`When overriding the location using \`<Routes location>\` or \`useRoutes(routes, location)\`, the location pathname must begin with the portion of the URL pathname that was matched by all parent routes. The current pathname base is "${c}" but pathname "${e.pathname}" was given in the \`location\` prop.`),d=e}else d=u;let f=d.pathname||`/`,p=f;if(c!==`/`){let e=c.replace(/^\//,``).split(`/`);p=`/`+f.replace(/^\//,``).split(`/`).slice(e.length).join(`/`)}let m=n&&n.state.matches.length?n.state.matches.map(e=>Object.assign(e,{route:n.manifest[e.route.id]||e.route})):Bn(e,{pathname:p});Mn(l||m!=null,`No routes matched location "${d.pathname}${d.search}${d.hash}" `),Mn(m==null||m[m.length-1].route.element!==void 0||m[m.length-1].route.Component!==void 0||m[m.length-1].route.lazy!==void 0,`Matched leaf route at location "${d.pathname}${d.search}${d.hash}" does not have an element or Component. This means it will render an <Outlet /> with a null value by default resulting in an "empty" page.`);let h=di(m&&m.map(e=>Object.assign({},e,{params:Object.assign({},o,e.params),pathname:hr([c,r.encodeLocation?r.encodeLocation(e.pathname.replace(/%/g,`%25`).replace(/\?/g,`%3F`).replace(/#/g,`%23`)).pathname:e.pathname]),pathnameBase:e.pathnameBase===`/`?c:hr([c,r.encodeLocation?r.encodeLocation(e.pathnameBase.replace(/%/g,`%25`).replace(/\?/g,`%3F`).replace(/#/g,`%23`)).pathname:e.pathnameBase])})),i,n);return t&&h?W.createElement(Lr.Provider,{value:{location:{pathname:`/`,search:``,hash:``,state:null,key:`default`,mask:void 0,...d},navigationType:`POP`}},h):h}function ai(){let e=bi(),t=xr(e)?`${e.status} ${e.statusText}`:e instanceof Error?e.message:JSON.stringify(e),n=e instanceof Error?e.stack:null,r=`rgba(200,200,200, 0.5)`,i={padding:`0.5rem`,backgroundColor:r},a={padding:`2px 4px`,backgroundColor:r},o=null;return console.error(`Error handled by React Router default ErrorBoundary:`,e),o=W.createElement(W.Fragment,null,W.createElement(`p`,null,`💿 Hey developer 👋`),W.createElement(`p`,null,`You can provide a way better UX than this when your app throws errors by providing your own `,W.createElement(`code`,{style:a},`ErrorBoundary`),` or`,` `,W.createElement(`code`,{style:a},`errorElement`),` prop on your route.`)),W.createElement(W.Fragment,null,W.createElement(`h2`,null,`Unexpected Application Error!`),W.createElement(`h3`,{style:{fontStyle:`italic`}},t),n?W.createElement(`pre`,{style:i},n):null,o)}var oi=W.createElement(ai,null),si=class extends W.Component{constructor(e){super(e),this.state={location:e.location,revalidation:e.revalidation,error:e.error}}static getDerivedStateFromError(e){return{error:e}}static getDerivedStateFromProps(e,t){return t.location!==e.location||t.revalidation!==`idle`&&e.revalidation===`idle`?{error:e.error,location:e.location,revalidation:e.revalidation}:{error:e.error===void 0?t.error:e.error,location:t.location,revalidation:e.revalidation||t.revalidation}}componentDidCatch(e,t){this.props.onError?this.props.onError(e,t):console.error(`React Router caught the following error during render`,e)}render(){let e=this.state.error;if(this.context&&typeof e==`object`&&e&&`digest`in e&&typeof e.digest==`string`){let t=Wr(e.digest);t&&(e=t)}let t=e===void 0?this.props.children:W.createElement(Rr.Provider,{value:this.props.routeContext},W.createElement(zr.Provider,{value:e,children:this.props.component}));return this.context?W.createElement(li,{error:e},t):t}};si.contextType=jr;var ci=new WeakMap;function li({children:e,error:t}){let{basename:n}=W.useContext(Ir);if(typeof t==`object`&&t&&`digest`in t&&typeof t.digest==`string`){let e=Ur(t.digest);if(e){let r=ci.get(t);if(r)throw r;let i=wr(e.location,n),a=i.absoluteURL||i.to;if(Or(a))throw Error(`Invalid redirect location`);if(Cr&&!ci.get(t))if(i.isExternal||e.reloadDocument)window.location.href=a;else{let n=Promise.resolve().then(()=>window.__reactRouterDataRouter.navigate(i.to,{replace:e.replace}));throw ci.set(t,n),n}return W.createElement(`meta`,{httpEquiv:`refresh`,content:`0;url=${a}`})}}return e}function ui({routeContext:e,match:t,children:n}){let r=W.useContext(kr);return r&&r.static&&r.staticContext&&(t.route.errorElement||t.route.ErrorBoundary)&&(r.staticContext._deepestRenderedBoundaryId=t.route.id),W.createElement(Rr.Provider,{value:e},n)}function di(e,t=[],n){let r=n?.state;if(e==null){if(!r)return null;if(r.errors)e=r.matches;else if(t.length===0&&!r.initialized&&r.matches.length>0)e=r.matches;else return null}let i=e,a=r?.errors;if(a!=null){let e=i.findIndex(e=>e.route.id&&a?.[e.route.id]!==void 0);jn(e>=0,`Could not find a matching route for errors on route IDs: ${Object.keys(a).join(`,`)}`),i=i.slice(0,Math.min(i.length,e+1))}let o=!1,s=-1;if(n&&r){o=r.renderFallback;for(let e=0;e<i.length;e++){let t=i[e];if((t.route.HydrateFallback||t.route.hydrateFallbackElement)&&(s=e),t.route.id){let{loaderData:e,errors:a}=r,c=t.route.loader&&!e.hasOwnProperty(t.route.id)&&(!a||a[t.route.id]===void 0);if(t.route.lazy||c){n.isStatic&&(o=!0),i=s>=0?i.slice(0,s+1):[i[0]];break}}}}let c=n?.onError,l=r&&c?(e,t)=>{c(e,{location:r.location,params:r.matches?.[0]?.params??{},pattern:Sr(r.matches),errorInfo:t})}:void 0;return i.reduceRight((e,n,c)=>{let u,d=!1,f=null,p=null;r&&(u=a&&n.route.id?a[n.route.id]:void 0,f=n.route.errorElement||oi,o&&(s<0&&c===0?(Ci(`route-fallback`,!1,"No `HydrateFallback` element provided to render during initial hydration"),d=!0,p=null):s===c&&(d=!0,p=n.route.hydrateFallbackElement||null)));let m=t.concat(i.slice(0,c+1)),h=()=>{let t;return t=u?f:d?p:n.route.Component?W.createElement(n.route.Component,null):n.route.element?n.route.element:e,W.createElement(ui,{match:n,routeContext:{outlet:e,matches:m,isDataRoute:r!=null},children:t})};return r&&(n.route.ErrorBoundary||n.route.errorElement||c===0)?W.createElement(si,{location:r.location,revalidation:r.revalidation,component:f,error:u,children:h(),routeContext:{outlet:null,matches:m,isDataRoute:!0},onError:l}):h()},null)}function fi(e){return`${e} must be used within a data router. See https://reactrouter.com/en/main/routers/picking-a-router.`}function pi(e){let t=W.useContext(kr);return jn(t,fi(e)),t}function mi(e){let t=W.useContext(Ar);return jn(t,fi(e)),t}function hi(e){let t=W.useContext(Rr);return jn(t,fi(e)),t}function gi(e){let t=hi(e),n=t.matches[t.matches.length-1];return jn(n.route.id,`${e} can only be used on routes that contain a unique "id"`),n.route.id}function _i(){return gi(`useRouteId`)}function vi(){let e=mi(`useNavigation`);return W.useMemo(()=>{let{matches:t,historyAction:n,...r}=e.navigation;return r},[e.navigation])}function yi(){let{matches:e,loaderData:t}=mi(`useMatches`);return W.useMemo(()=>e.map(e=>Hn(e,t)),[e,t])}function bi(){let e=W.useContext(zr),t=mi(`useRouteError`),n=gi(`useRouteError`);return e===void 0?t.errors?.[n]:e}function xi(){let{router:e}=pi(`useNavigate`),t=gi(`useNavigate`),n=W.useRef(!1);return Yr(()=>{n.current=!0}),W.useCallback(async(r,i={})=>{Mn(n.current,Jr),n.current&&(typeof r==`number`?await e.navigate(r):await e.navigate(r,{fromRouteId:t,...i}))},[e,t])}var Si={};function Ci(e,t,n){!t&&!Si[e]&&(Si[e]=!0,Mn(!1,n))}W.memo(wi);function wi({routes:e,manifest:t,future:n,state:r,isStatic:i,onError:a}){return ii(e,void 0,{manifest:t,state:r,isStatic:i,onError:a,future:n})}function Ti({to:e,replace:t,state:n,relative:r}){jn(Kr(),`<Navigate> may be used only in the context of a <Router> component.`);let{static:i}=W.useContext(Ir);Mn(!i,`<Navigate> must not be used on the initial render in a <StaticRouter>. This is a no-op, but you should modify your code so the <Navigate> is only ever rendered in response to some user interaction or state change.`);let{matches:a}=W.useContext(Rr),{pathname:o}=qr(),s=Xr(),c=pr(e,fr(a),o,r===`path`),l=JSON.stringify(c);return W.useEffect(()=>{s(JSON.parse(l),{replace:t,state:n,relative:r})},[s,l,r,t,n]),null}function J(e){return ei(e.context)}function Y(e){jn(!1,`A <Route> is only ever to be used as the child of <Routes> element, never rendered directly. Please wrap your <Route> in a <Routes>.`)}function Ei({basename:e=`/`,children:t=null,location:n,navigationType:r=`POP`,navigator:i,static:a=!1,useTransitions:o}){jn(!Kr(),`You cannot render a <Router> inside another <Router>. You should never have more than one in your app.`);let s=e.replace(/^\/*/,`/`),c=W.useMemo(()=>({basename:s,navigator:i,static:a,useTransitions:o,future:{}}),[s,i,a,o]);typeof n==`string`&&(n=Ln(n));let{pathname:l=`/`,search:u=``,hash:d=``,state:f=null,key:p=`default`,mask:m}=n,h=W.useMemo(()=>{let e=sr(l,s);return e==null?null:{location:{pathname:e,search:u,hash:d,state:f,key:p,mask:m},navigationType:r}},[s,l,u,d,f,p,r,m]);return Mn(h!=null,`<Router basename="${s}"> is not able to match the URL "${l}${u}${d}" because it does not start with the basename, so the <Router> won't render anything.`),h==null?null:W.createElement(Ir.Provider,{value:c},W.createElement(Lr.Provider,{children:t,value:h}))}function Di({children:e,location:t}){return ri(Oi(e),t)}W.Component;function Oi(e,t=[]){let n=[];return W.Children.forEach(e,(e,r)=>{if(!W.isValidElement(e))return;let i=[...t,r];if(e.type===W.Fragment){n.push.apply(n,Oi(e.props.children,i));return}jn(e.type===Y,`[${typeof e.type==`string`?e.type:e.type.name}] is not a <Route> component. All component children of <Routes> must be a <Route> or <React.Fragment>`),jn(!e.props.index||!e.props.children,`An index route cannot have child routes.`);let a={id:e.props.id||i.join(`-`),caseSensitive:e.props.caseSensitive,element:e.props.element,Component:e.props.Component,index:e.props.index,path:e.props.path,middleware:e.props.middleware,loader:e.props.loader,action:e.props.action,hydrateFallbackElement:e.props.hydrateFallbackElement,HydrateFallback:e.props.HydrateFallback,errorElement:e.props.errorElement,ErrorBoundary:e.props.ErrorBoundary,hasErrorBoundary:e.props.hasErrorBoundary===!0||e.props.ErrorBoundary!=null||e.props.errorElement!=null,shouldRevalidate:e.props.shouldRevalidate,handle:e.props.handle,lazy:e.props.lazy};e.props.children&&(a.children=Oi(e.props.children,i)),n.push(a)}),n}var ki=`get`,Ai=`application/x-www-form-urlencoded`;function ji(e){return typeof HTMLElement<`u`&&e instanceof HTMLElement}function Mi(e){return ji(e)&&e.tagName.toLowerCase()===`button`}function Ni(e){return ji(e)&&e.tagName.toLowerCase()===`form`}function Pi(e){return ji(e)&&e.tagName.toLowerCase()===`input`}function Fi(e){return!!(e.metaKey||e.altKey||e.ctrlKey||e.shiftKey)}function Ii(e,t){return e.button===0&&(!t||t===`_self`)&&!Fi(e)}function Li(e=``){return new URLSearchParams(typeof e==`string`||Array.isArray(e)||e instanceof URLSearchParams?e:Object.keys(e).reduce((t,n)=>{let r=e[n];return t.concat(Array.isArray(r)?r.map(e=>[n,e]):[[n,r]])},[]))}function Ri(e,t){let n=Li(e);return t&&t.forEach((e,r)=>{n.has(r)||t.getAll(r).forEach(e=>{n.append(r,e)})}),n}var zi=null;function Bi(){if(zi===null)try{new FormData(document.createElement(`form`),0),zi=!1}catch{zi=!0}return zi}var Vi=new Set([`application/x-www-form-urlencoded`,`multipart/form-data`,`text/plain`]);function Hi(e){return e!=null&&!Vi.has(e)?(Mn(!1,`"${e}" is not a valid \`encType\` for \`<Form>\`/\`<fetcher.Form>\` and will default to "${Ai}"`),null):e}function Ui(e,t){let n,r,i,a,o;if(Ni(e)){let o=e.getAttribute(`action`);r=o?sr(o,t):null,n=e.getAttribute(`method`)||ki,i=Hi(e.getAttribute(`enctype`))||Ai,a=new FormData(e)}else if(Mi(e)||Pi(e)&&(e.type===`submit`||e.type===`image`)){let o=e.form;if(o==null)throw Error(`Cannot submit a <button> or <input type="submit"> without a <form>`);let s=e.getAttribute(`formaction`)||o.getAttribute(`action`);if(r=s?sr(s,t):null,n=e.getAttribute(`formmethod`)||o.getAttribute(`method`)||ki,i=Hi(e.getAttribute(`formenctype`))||Hi(o.getAttribute(`enctype`))||Ai,a=new FormData(o,e),!Bi()){let{name:t,type:n,value:r}=e;if(n===`image`){let e=t?`${t}.`:``;a.append(`${e}x`,`0`),a.append(`${e}y`,`0`)}else t&&a.append(t,r)}}else if(ji(e))throw Error(`Cannot submit element that is not <form>, <button>, or <input type="submit|image">`);else n=ki,r=null,i=Ai,o=e;return a&&i===`text/plain`&&(o=a,a=void 0),{action:r,method:n.toLowerCase(),encType:i,formData:a,body:o}}Object.getOwnPropertyNames(Object.prototype).sort().join(`\0`);var Wi={"&":`\\u0026`,">":`\\u003e`,"<":`\\u003c`,"\u2028":`\\u2028`,"\u2029":`\\u2029`},Gi=/[&><\u2028\u2029]/g;function Ki(e){return e.replace(Gi,e=>Wi[e])}function qi(e,t){if(e===!1||e==null)throw Error(t)}function Ji(e,t,n,r){let i=typeof e==`string`?new URL(e,typeof window>`u`?`server://singlefetch/`:window.location.origin):e;return n?i.pathname.endsWith(`/`)?i.pathname=`${i.pathname}_.${r}`:i.pathname=`${i.pathname}.${r}`:i.pathname===`/`?i.pathname=`_root.${r}`:t&&sr(i.pathname,t)===`/`?i.pathname=`${gr(t)}/_root.${r}`:i.pathname=`${gr(i.pathname)}.${r}`,i}async function Yi(e,t){if(e.id in t)return t[e.id];try{let n=await q(()=>import(e.module),[]);return t[e.id]=n,n}catch(t){return console.error(`Error loading route module \`${e.module}\`, reloading page...`),console.error(t),window.__reactRouterContext&&window.__reactRouterContext.isSpaMode,window.location.reload(),new Promise(()=>{})}}function Xi(e){return e!=null&&typeof e.page==`string`}function Zi(e){return e==null?!1:e.href==null?e.rel===`preload`&&typeof e.imageSrcSet==`string`&&typeof e.imageSizes==`string`:typeof e.rel==`string`&&typeof e.href==`string`}async function Qi(e,t,n){return ra((await Promise.all(e.map(async e=>{let r=t.routes[e.route.id];if(r){let e=await Yi(r,n);return e.links?e.links():[]}return[]}))).flat(1).filter(Zi).filter(e=>e.rel===`stylesheet`||e.rel===`preload`).map(e=>e.rel===`stylesheet`?{...e,rel:`prefetch`,as:`style`}:{...e,rel:`prefetch`}))}function $i(e,t,n,r,i,a){let o=(e,t)=>n[t]?e.route.id!==n[t].route.id:!0,s=(e,t)=>n[t].pathname!==e.pathname||n[t].route.path?.endsWith(`*`)&&n[t].params[`*`]!==e.params[`*`];return a===`assets`?t.filter((e,t)=>o(e,t)||s(e,t)):a===`data`?t.filter((t,a)=>{let c=r.routes[t.route.id];if(!c||!c.hasLoader)return!1;if(o(t,a)||s(t,a))return!0;if(t.route.shouldRevalidate){let r=t.route.shouldRevalidate({currentUrl:new URL(i.pathname+i.search+i.hash,window.origin),currentParams:n[0]?.params||{},nextUrl:new URL(e,window.origin),nextParams:t.params,defaultShouldRevalidate:!0});if(typeof r==`boolean`)return r}return!0}):[]}function ea(e,t,{includeHydrateFallback:n}={}){return ta(e.map(e=>{let r=t.routes[e.route.id];if(!r)return[];let i=[r.module];return r.clientActionModule&&(i=i.concat(r.clientActionModule)),r.clientLoaderModule&&(i=i.concat(r.clientLoaderModule)),n&&r.hydrateFallbackModule&&(i=i.concat(r.hydrateFallbackModule)),r.imports&&(i=i.concat(r.imports)),i}).flat(1))}function ta(e){return[...new Set(e)]}function na(e){let t={},n=Object.keys(e).sort();for(let r of n)t[r]=e[r];return t}function ra(e,t){let n=new Set,r=new Set(t);return e.reduce((e,i)=>{if(t&&!Xi(i)&&i.as===`script`&&i.href&&r.has(i.href))return e;let a=JSON.stringify(na(i));return n.has(a)||(n.add(a),e.push({key:a,link:i})),e},[])}function ia(){let e=W.useContext(kr);return qi(e,`You must render this element inside a <DataRouterContext.Provider> element`),e}function aa(){let e=W.useContext(Ar);return qi(e,`You must render this element inside a <DataRouterStateContext.Provider> element`),e}var oa=W.createContext(void 0);oa.displayName=`FrameworkContext`;function sa(){let e=W.useContext(oa);return qi(e,`You must render this element inside a <HydratedRouter> element`),e}function ca(e,t){let n=W.useContext(oa),[r,i]=W.useState(!1),[a,o]=W.useState(!1),{onFocus:s,onBlur:c,onMouseEnter:l,onMouseLeave:u,onTouchStart:d}=t,f=W.useRef(null);W.useEffect(()=>{if(e===`render`&&o(!0),e===`viewport`){let e=new IntersectionObserver(e=>{e.forEach(e=>{o(e.isIntersecting)})},{threshold:.5});return f.current&&e.observe(f.current),()=>{e.disconnect()}}},[e]),W.useEffect(()=>{if(r){let e=setTimeout(()=>{o(!0)},100);return()=>{clearTimeout(e)}}},[r]);let p=()=>{i(!0)},m=()=>{i(!1),o(!1)};return n?e===`intent`?[a,f,{onFocus:la(s,p),onBlur:la(c,m),onMouseEnter:la(l,p),onMouseLeave:la(u,m),onTouchStart:la(d,p)}]:[a,f,{}]:[!1,f,{}]}function la(e,t){return n=>{e&&e(n),n.defaultPrevented||t(n)}}function ua({page:e,...t}){let n=Mr(),{nonce:r}=sa(),{router:i}=ia(),a=W.useMemo(()=>Bn(i.routes,e,i.basename),[i.routes,e,i.basename]);return a?(t.nonce==null&&r&&(t={...t,nonce:r}),n?W.createElement(fa,{page:e,matches:a,...t}):W.createElement(pa,{page:e,matches:a,...t})):null}function da(e){let{manifest:t,routeModules:n}=sa(),[r,i]=W.useState([]);return W.useEffect(()=>{let r=!1;return Qi(e,t,n).then(e=>{r||i(e)}),()=>{r=!0}},[e,t,n]),r}function fa({page:e,matches:t,...n}){let r=qr(),{future:i}=sa(),{basename:a}=ia(),o=W.useMemo(()=>{if(e===r.pathname+r.search+r.hash)return[];let n=Ji(e,a,i.v8_trailingSlashAwareDataRequests,`rsc`),o=!1,s=[];for(let e of t)typeof e.route.shouldRevalidate==`function`?o=!0:s.push(e.route.id);return o&&s.length>0&&n.searchParams.set(`_routes`,s.join(`,`)),[n.pathname+n.search]},[a,i.v8_trailingSlashAwareDataRequests,e,r,t]);return W.createElement(W.Fragment,null,o.map(e=>W.createElement(`link`,{key:e,rel:`prefetch`,as:`fetch`,href:e,...n})))}function pa({page:e,matches:t,...n}){let r=qr(),{future:i,manifest:a,routeModules:o}=sa(),{basename:s}=ia(),{loaderData:c,matches:l}=aa(),u=W.useMemo(()=>$i(e,t,l,a,r,`data`),[e,t,l,a,r]),d=W.useMemo(()=>$i(e,t,l,a,r,`assets`),[e,t,l,a,r]),f=W.useMemo(()=>{if(e===r.pathname+r.search+r.hash)return[];let n=new Set,l=!1;if(t.forEach(e=>{let t=a.routes[e.route.id];!t||!t.hasLoader||(!u.some(t=>t.route.id===e.route.id)&&e.route.id in c&&o[e.route.id]?.shouldRevalidate||t.hasClientLoader?l=!0:n.add(e.route.id))}),n.size===0)return[];let d=Ji(e,s,i.v8_trailingSlashAwareDataRequests,`data`);return l&&n.size>0&&d.searchParams.set(`_routes`,t.filter(e=>n.has(e.route.id)).map(e=>e.route.id).join(`,`)),[d.pathname+d.search]},[s,i.v8_trailingSlashAwareDataRequests,c,r,a,u,t,e,o]),p=W.useMemo(()=>ea(d,a),[d,a]),m=da(d);return W.createElement(W.Fragment,null,f.map(e=>W.createElement(`link`,{key:e,rel:`prefetch`,as:`fetch`,href:e,...n})),p.map(e=>W.createElement(`link`,{key:e,rel:`modulepreload`,href:e,...n})),m.map(({key:e,link:t})=>W.createElement(`link`,{key:e,nonce:n.nonce,...t,crossOrigin:t.crossOrigin??n.crossOrigin})))}function ma(...e){return t=>{e.forEach(e=>{typeof e==`function`?e(t):e!=null&&(e.current=t)})}}W.Component;var ha=typeof window<`u`&&window.document!==void 0&&window.document.createElement!==void 0;try{ha&&(window.__reactRouterVersion=`7.18.2`)}catch{}function ga({basename:e,children:t,useTransitions:n,window:r}){let i=W.useRef();i.current??=An({window:r,v5Compat:!0});let a=i.current,[o,s]=W.useState({action:a.action,location:a.location}),c=W.useCallback(e=>{n===!1?s(e):W.startTransition(()=>s(e))},[n]);return W.useLayoutEffect(()=>a.listen(c),[a,c]),W.createElement(Ei,{basename:e,children:t,location:o.location,navigationType:o.action,navigator:a,useTransitions:n})}function _a({basename:e,children:t,history:n,useTransitions:r}){let[i,a]=W.useState({action:n.action,location:n.location}),o=W.useCallback(e=>{r===!1?a(e):W.startTransition(()=>a(e))},[r]);return W.useLayoutEffect(()=>n.listen(o),[n,o]),W.createElement(Ei,{basename:e,children:t,location:i.location,navigationType:i.action,navigator:n,useTransitions:r})}_a.displayName=`unstable_HistoryRouter`;var va=W.forwardRef(function({onClick:e,discover:t=`render`,prefetch:n=`none`,relative:r,reloadDocument:i,replace:a,mask:o,state:s,target:c,to:l,preventScrollReset:u,viewTransition:d,defaultShouldRevalidate:f,...p},m){let{basename:h,navigator:g,useTransitions:_}=W.useContext(Ir),v=typeof l==`string`&&Tn.test(l),y=wr(l,h);l=y.to;let b=Gr(l,{relative:r}),x=qr(),S=null;if(o){let e=pr(o,[],x.mask?x.mask.pathname:`/`,!0);h!==`/`&&(e.pathname=e.pathname===`/`?h:hr([h,e.pathname])),S=g.createHref(e)}let[C,w,T]=ca(n,p),E=Ta(l,{replace:a,mask:o,state:s,target:c,preventScrollReset:u,relative:r,viewTransition:d,defaultShouldRevalidate:f,useTransitions:_});function D(t){e&&e(t),t.defaultPrevented||E(t)}let O=!(y.isExternal||i),k=W.createElement(`a`,{...p,...T,href:(O?S:void 0)||y.absoluteURL||b,onClick:O?D:e,ref:ma(m,w),target:c,"data-discover":!v&&t===`render`?`true`:void 0});return C&&!v?W.createElement(W.Fragment,null,k,W.createElement(ua,{page:b})):k});va.displayName=`Link`;var ya=W.forwardRef(function({"aria-current":e=`page`,caseSensitive:t=!1,className:n=``,end:r=!1,style:i,to:a,viewTransition:o,children:s,...c},l){let u=ni(a,{relative:c.relative}),d=qr(),f=W.useContext(Ar),{navigator:p,basename:m}=W.useContext(Ir),h=f!=null&&Ia(u)&&o===!0,g=p.encodeLocation?p.encodeLocation(u).pathname:u.pathname,_=d.pathname,v=f&&f.navigation&&f.navigation.location?f.navigation.location.pathname:null;t||(_=_.toLowerCase(),v=v?v.toLowerCase():null,g=g.toLowerCase()),v&&m&&(v=sr(v,m)||v);let y=g!==`/`&&g.endsWith(`/`)?g.length-1:g.length,b=_===g||!r&&_.startsWith(g)&&_.charAt(y)===`/`,x=v!=null&&(v===g||!r&&v.startsWith(g)&&v.charAt(g.length)===`/`),S={isActive:b,isPending:x,isTransitioning:h},C=b?e:void 0,w;w=typeof n==`function`?n(S):[n,b?`active`:null,x?`pending`:null,h?`transitioning`:null].filter(Boolean).join(` `);let T=typeof i==`function`?i(S):i;return W.createElement(va,{...c,"aria-current":C,className:w,ref:l,style:T,to:a,viewTransition:o},typeof s==`function`?s(S):s)});ya.displayName=`NavLink`;var ba=W.forwardRef(({discover:e=`render`,fetcherKey:t,navigate:n,reloadDocument:r,replace:i,state:a,method:o=ki,action:s,onSubmit:c,relative:l,preventScrollReset:u,viewTransition:d,defaultShouldRevalidate:f,...p},m)=>{let{useTransitions:h}=W.useContext(Ir),g=ka(),_=Aa(s,{relative:l}),v=o.toLowerCase()===`get`?`get`:`post`,y=typeof s==`string`&&Tn.test(s);return W.createElement(`form`,{ref:m,method:v,action:_,onSubmit:r?c:e=>{if(c&&c(e),e.defaultPrevented)return;e.preventDefault();let r=e.nativeEvent.submitter,s=r?.getAttribute(`formmethod`)||o,p=()=>g(r||e.currentTarget,{fetcherKey:t,method:s,navigate:n,replace:i,state:a,relative:l,preventScrollReset:u,viewTransition:d,defaultShouldRevalidate:f});h&&n!==!1?W.startTransition(()=>p()):p()},...p,"data-discover":!y&&e===`render`?`true`:void 0})});ba.displayName=`Form`;function xa({getKey:e,storageKey:t,...n}){let r=W.useContext(oa),{basename:i}=W.useContext(Ir),a=qr(),o=yi();Pa({getKey:e,storageKey:t});let s=W.useMemo(()=>{if(!r||!e)return null;let t=Na(a,o,i,e);return t===a.key?null:t},[]);if(!r||r.isSpaMode)return null;let c=((e,t)=>{if(!window.history.state||!window.history.state.key){let e=Math.random().toString(32).slice(2);window.history.replaceState({key:e},``)}try{let n=JSON.parse(sessionStorage.getItem(e)||`{}`)[t||window.history.state.key];typeof n==`number`&&window.scrollTo(0,n)}catch(t){console.error(t),sessionStorage.removeItem(e)}}).toString();return n.nonce==null&&r?.nonce&&(n.nonce=r.nonce),W.createElement(`script`,{...n,suppressHydrationWarning:!0,dangerouslySetInnerHTML:{__html:`(${c})(${Ki(JSON.stringify(t||ja))}, ${Ki(JSON.stringify(s))})`}})}xa.displayName=`ScrollRestoration`;function Sa(e){return`${e} must be used within a data router. See https://reactrouter.com/en/main/routers/picking-a-router.`}function Ca(e){let t=W.useContext(kr);return jn(t,Sa(e)),t}function wa(e){let t=W.useContext(Ar);return jn(t,Sa(e)),t}function Ta(e,{target:t,replace:n,mask:r,state:i,preventScrollReset:a,relative:o,viewTransition:s,defaultShouldRevalidate:c,useTransitions:l}={}){let u=Xr(),d=qr(),f=ni(e,{relative:o});return W.useCallback(p=>{if(Ii(p,t)){p.preventDefault();let t=n===void 0?In(d)===In(f):n,m=()=>u(e,{replace:t,mask:r,state:i,preventScrollReset:a,relative:o,viewTransition:s,defaultShouldRevalidate:c});l?W.startTransition(()=>m()):m()}},[d,u,f,n,r,i,t,e,a,o,s,c,l])}function Ea(e){Mn(typeof URLSearchParams<`u`,"You cannot use the `useSearchParams` hook in a browser that does not support the URLSearchParams API. If you need to support Internet Explorer 11, we recommend you load a polyfill such as https://github.com/ungap/url-search-params.");let t=W.useRef(Li(e)),n=W.useRef(!1),r=qr(),i=W.useMemo(()=>Ri(r.search,n.current?null:t.current),[r.search]),a=Xr();return[i,W.useCallback((e,t)=>{let r=Li(typeof e==`function`?e(new URLSearchParams(i)):e);n.current=!0,a(`?`+r,t)},[a,i])]}var Da=0,Oa=()=>`__${String(++Da)}__`;function ka(){let{router:e}=Ca(`useSubmit`),{basename:t}=W.useContext(Ir),n=_i(),r=e.fetch,i=e.navigate;return W.useCallback(async(e,a={})=>{let{action:o,method:s,encType:c,formData:l,body:u}=Ui(e,t);a.navigate===!1?await r(a.fetcherKey||Oa(),n,a.action||o,{defaultShouldRevalidate:a.defaultShouldRevalidate,preventScrollReset:a.preventScrollReset,formData:l,body:u,formMethod:a.method||s,formEncType:a.encType||c,flushSync:a.flushSync}):await i(a.action||o,{defaultShouldRevalidate:a.defaultShouldRevalidate,preventScrollReset:a.preventScrollReset,formData:l,body:u,formMethod:a.method||s,formEncType:a.encType||c,replace:a.replace,state:a.state,fromRouteId:n,flushSync:a.flushSync,viewTransition:a.viewTransition})},[r,i,t,n])}function Aa(e,{relative:t}={}){let{basename:n}=W.useContext(Ir),r=W.useContext(Rr);jn(r,`useFormAction must be used inside a RouteContext`);let[i]=r.matches.slice(-1),a={...ni(e||`.`,{relative:t})},o=qr();if(e==null){a.search=o.search;let e=new URLSearchParams(a.search),t=e.getAll(`index`);if(t.some(e=>e===``)){e.delete(`index`),t.filter(e=>e).forEach(t=>e.append(`index`,t));let n=e.toString();a.search=n?`?${n}`:``}}return(!e||e===`.`)&&i.route.index&&(a.search=a.search?a.search.replace(/^\?/,`?index&`):`?index`),n!==`/`&&(a.pathname=a.pathname===`/`?n:hr([n,a.pathname])),In(a)}var ja=`react-router-scroll-positions`,Ma={};function Na(e,t,n,r){let i=null;return r&&(i=r(n===`/`?e:{...e,pathname:sr(e.pathname,n)||e.pathname},t)),i??=e.key,i}function Pa({getKey:e,storageKey:t}={}){let{router:n}=Ca(`useScrollRestoration`),{restoreScrollPosition:r,preventScrollReset:i}=wa(`useScrollRestoration`),{basename:a}=W.useContext(Ir),o=qr(),s=yi(),c=vi();W.useEffect(()=>(window.history.scrollRestoration=`manual`,()=>{window.history.scrollRestoration=`auto`}),[]),Fa(W.useCallback(()=>{if(c.state===`idle`){let t=Na(o,s,a,e);Ma[t]=window.scrollY}try{sessionStorage.setItem(t||ja,JSON.stringify(Ma))}catch(e){Mn(!1,`Failed to save scroll positions in sessionStorage, <ScrollRestoration /> will not work properly (${e}).`)}window.history.scrollRestoration=`auto`},[c.state,e,a,o,s,t])),typeof document<`u`&&(W.useLayoutEffect(()=>{try{let e=sessionStorage.getItem(t||ja);e&&(Ma=JSON.parse(e))}catch{}},[t]),W.useLayoutEffect(()=>{let t=n?.enableScrollRestoration(Ma,()=>window.scrollY,e?(t,n)=>Na(t,n,a,e):void 0);return()=>t&&t()},[n,a,e]),W.useLayoutEffect(()=>{if(r!==!1){if(typeof r==`number`){window.scrollTo(0,r);return}try{if(o.hash){let e=document.getElementById(decodeURIComponent(o.hash.slice(1)));if(e){e.scrollIntoView();return}}}catch{Mn(!1,`"${o.hash.slice(1)}" is not a decodable element ID. The view will not scroll to it.`)}i!==!0&&window.scrollTo(0,0)}},[o,r,i]))}function Fa(e,t){let{capture:n}=t||{};W.useEffect(()=>{let t=n==null?void 0:{capture:n};return window.addEventListener(`pagehide`,e,t),()=>{window.removeEventListener(`pagehide`,e,t)}},[e,n])}function Ia(e,{relative:t}={}){let n=W.useContext(Nr);jn(n!=null,"`useViewTransitionState` must be used within `react-router-dom`'s `RouterProvider`. Did you accidentally import `RouterProvider` from `react-router`?");let{basename:r}=Ca(`useViewTransitionState`),i=ni(e,{relative:t});if(!n.isTransitioning)return!1;let a=sr(n.currentLocation.pathname,r)||n.currentLocation.pathname,o=sr(n.nextLocation.pathname,r)||n.nextLocation.pathname;return rr(i.pathname,o)!=null||rr(i.pathname,a)!=null}function La(e){return{onFetch:(t,n)=>{let r=t.options,i=t.fetchOptions?.meta?.fetchMore?.direction,a=t.state.data?.pages||[],o=t.state.data?.pageParams||[],s={pages:[],pageParams:[]},c=0,l=async()=>{let n=!1,l=e=>{A(e,()=>t.signal,()=>n=!0)},u=P(t.options,t.fetchOptions),d=async(e,r,i)=>{if(n)return Promise.reject();if(r==null&&e.pages.length)return Promise.resolve(e);let a=await u((()=>{let e={client:t.client,queryKey:t.queryKey,pageParam:r,direction:i?`backward`:`forward`,meta:t.options.meta};return l(e),e})()),{maxPages:o}=t.options,s=i?I:j;return{pages:s(e.pages,a,o),pageParams:s(e.pageParams,r,o)}};if(i&&a.length){let e=i===`backward`,t=e?za:Ra,n={pages:a,pageParams:o};s=await d(n,t(r,n),e)}else{let t=e??a.length;do{let e=c===0?o[0]??r.initialPageParam:Ra(r,s);if(c>0&&e==null)break;s=await d(s,e),c++}while(c<t)}return s};t.options.persister?t.fetchFn=()=>t.options.persister?.(l,{client:t.client,queryKey:t.queryKey,meta:t.options.meta,signal:t.signal},n):t.fetchFn=l}}}function Ra(e,{pages:t,pageParams:n}){let r=t.length-1;return t.length>0?e.getNextPageParam(t[r],t,n[r],n):void 0}function za(e,{pages:t,pageParams:n}){return t.length>0?e.getPreviousPageParam?.(t[0],t,n[0],n):void 0}var Ba=class extends T{constructor(e={}){super(),this.config=e,this.#e=new Set,this.#t=new Map,this.#n=0}#e;#t;#n;build(e,t,n){let r=new re({client:e,mutationCache:this,mutationId:++this.#n,options:e.defaultMutationOptions(t),state:n});return this.add(r),r}add(e){this.#e.add(e);let t=Va(e);if(typeof t==`string`){let n=this.#t.get(t);n?n.push(e):this.#t.set(t,[e])}this.notify({type:`added`,mutation:e})}remove(e){if(this.#e.delete(e)){let t=Va(e);if(typeof t==`string`){let n=this.#t.get(t);if(n)if(n.length>1){let t=n.indexOf(e);t!==-1&&n.splice(t,1)}else n[0]===e&&this.#t.delete(t)}}this.notify({type:`removed`,mutation:e})}canRun(e){let t=Va(e);if(typeof t==`string`){let n=this.#t.get(t)?.find(e=>e.state.status===`pending`);return!n||n===e}else return!0}runNext(e){let t=Va(e);return typeof t==`string`?(this.#t.get(t)?.find(t=>t!==e&&t.state.isPaused))?.continue()??Promise.resolve():Promise.resolve()}clear(){k.batch(()=>{this.#e.forEach(e=>{this.notify({type:`removed`,mutation:e})}),this.#e.clear(),this.#t.clear()})}getAll(){return Array.from(this.#e)}find(e){let t={exact:!0,...e};return this.getAll().find(e=>O(t,e))}findAll(e={}){return this.getAll().filter(t=>O(e,t))}notify(e){k.batch(()=>{this.listeners.forEach(t=>{t(e)})})}resumePausedMutations(){let e=this.getAll().filter(e=>e.state.isPaused);return k.batch(()=>Promise.all(e.map(e=>e.continue().catch(E))))}};function Va(e){return e.options.scope?.id}var Ha=class extends T{constructor(e={}){super(),this.config=e,this.#e=new Map}#e;build(e,t,n){let r=t.queryKey,i=t.queryHash??D(r,t),a=this.get(i);return a||(a=new R({client:e,queryKey:r,queryHash:i,options:e.defaultQueryOptions(t),state:n,defaultOptions:e.getQueryDefaults(r)}),this.add(a)),a}add(e){this.#e.has(e.queryHash)||(this.#e.set(e.queryHash,e),this.notify({type:`added`,query:e}))}remove(e){let t=this.#e.get(e.queryHash);t&&(e.destroy(),t===e&&this.#e.delete(e.queryHash),this.notify({type:`removed`,query:e}))}clear(){k.batch(()=>{this.getAll().forEach(e=>{this.remove(e)})})}get(e){return this.#e.get(e)}getAll(){return[...this.#e.values()]}find(e){let t={exact:!0,...e};return this.getAll().find(e=>L(t,e))}findAll(e={}){let t=this.getAll();return Object.keys(e).length>0?t.filter(t=>L(e,t)):t}notify(e){k.batch(()=>{this.listeners.forEach(t=>{t(e)})})}onFocus(){k.batch(()=>{this.getAll().forEach(e=>{e.onFocus()})})}onOnline(){k.batch(()=>{this.getAll().forEach(e=>{e.onOnline()})})}},Ua=class{#e;#t;#n;#r;#i;#a;#o;#s;constructor(e={}){this.#e=e.queryCache||new Ha,this.#t=e.mutationCache||new Ba,this.#n=e.defaultOptions||{},this.#r=new Map,this.#i=new Map,this.#a=0}mount(){this.#a++,this.#a===1&&(this.#o=ne.subscribe(async e=>{e&&(await this.resumePausedMutations(),this.#e.onFocus())}),this.#s=ee.subscribe(async e=>{e&&(await this.resumePausedMutations(),this.#e.onOnline())}))}unmount(){this.#a--,this.#a===0&&(this.#o?.(),this.#o=void 0,this.#s?.(),this.#s=void 0)}isFetching(e){return this.#e.findAll({...e,fetchStatus:`fetching`}).length}isMutating(e){return this.#t.findAll({...e,status:`pending`}).length}getQueryData(e){let t=this.defaultQueryOptions({queryKey:e});return this.#e.get(t.queryHash)?.state.data}ensureQueryData(e){let t=this.defaultQueryOptions(e),n=this.#e.build(this,t),r=n.state.data;return r===void 0?this.fetchQuery(e):(e.revalidateIfStale&&n.isStaleByTime(w(t.staleTime,n))&&this.prefetchQuery(t),Promise.resolve(r))}getQueriesData(e){return this.#e.findAll(e).map(({queryKey:e,state:t})=>[e,t.data])}setQueryData(e,t,n){let r=this.defaultQueryOptions({queryKey:e}),i=this.#e.get(r.queryHash)?.state.data,a=N(t,i);if(a!==void 0)return this.#e.build(this,r).setData(a,{...n,manual:!0})}setQueriesData(e,t,n){return k.batch(()=>this.#e.findAll(e).map(({queryKey:e})=>[e,this.setQueryData(e,t,n)]))}getQueryState(e){let t=this.defaultQueryOptions({queryKey:e});return this.#e.get(t.queryHash)?.state}removeQueries(e){let t=this.#e;k.batch(()=>{t.findAll(e).forEach(e=>{t.remove(e)})})}resetQueries(e,t){let n=this.#e;return k.batch(()=>(n.findAll(e).forEach(e=>{e.reset()}),this.refetchQueries({type:`active`,...e},t)))}cancelQueries(e,t={}){let n={revert:!0,...t},r=k.batch(()=>this.#e.findAll(e).map(e=>e.cancel(n)));return Promise.all(r).then(E).catch(E)}invalidateQueries(e,t={}){return k.batch(()=>(this.#e.findAll(e).forEach(e=>{e.invalidate()}),e?.refetchType===`none`?Promise.resolve():this.refetchQueries({...e,type:e?.refetchType??e?.type??`active`},t)))}refetchQueries(e,t={}){let n={...t,cancelRefetch:t.cancelRefetch??!0},r=k.batch(()=>this.#e.findAll(e).filter(e=>!e.isDisabled()&&!e.isStatic()).map(e=>{let t=e.fetch(void 0,n);return n.throwOnError||(t=t.catch(E)),e.state.fetchStatus===`paused`?Promise.resolve():t}));return Promise.all(r).then(E)}fetchQuery(e){let t=this.defaultQueryOptions(e);t.retry===void 0&&(t.retry=!1);let n=this.#e.build(this,t);return n.isStaleByTime(w(t.staleTime,n))?n.fetch(t):Promise.resolve(n.state.data)}prefetchQuery(e){return this.fetchQuery(e).then(E).catch(E)}fetchInfiniteQuery(e){return e.behavior=La(e.pages),this.fetchQuery(e)}prefetchInfiniteQuery(e){return this.fetchInfiniteQuery(e).then(E).catch(E)}ensureInfiniteQueryData(e){return e.behavior=La(e.pages),this.ensureQueryData(e)}resumePausedMutations(){return ee.isOnline()?this.#t.resumePausedMutations():Promise.resolve()}getQueryCache(){return this.#e}getMutationCache(){return this.#t}getDefaultOptions(){return this.#n}setDefaultOptions(e){this.#n=e}setQueryDefaults(e,t){this.#r.set(M(e),{queryKey:e,defaultOptions:t})}getQueryDefaults(e){let t=[...this.#r.values()],n={};return t.forEach(t=>{C(e,t.queryKey)&&Object.assign(n,t.defaultOptions)}),n}setMutationDefaults(e,t){this.#i.set(M(e),{mutationKey:e,defaultOptions:t})}getMutationDefaults(e){let t=[...this.#i.values()],n={};return t.forEach(t=>{C(e,t.mutationKey)&&Object.assign(n,t.defaultOptions)}),n}defaultQueryOptions(e){if(e._defaulted)return e;let t={...this.#n.queries,...this.getQueryDefaults(e.queryKey),...e,_defaulted:!0};return t.queryHash||=D(t.queryKey,t),t.refetchOnReconnect===void 0&&(t.refetchOnReconnect=t.networkMode!==`always`),t.throwOnError===void 0&&(t.throwOnError=!!t.suspense),!t.networkMode&&t.persister&&(t.networkMode=`offlineFirst`),t.queryFn===S&&(t.enabled=!1),t}defaultMutationOptions(e){return e?._defaulted?e:{...this.#n.mutations,...e?.mutationKey&&this.getMutationDefaults(e.mutationKey),...e,_defaulted:!0}}clear(){this.#e.clear(),this.#t.clear()}},Wa=V(`archive`,[[`rect`,{width:`20`,height:`5`,x:`2`,y:`3`,rx:`1`,key:`1wp1u1`}],[`path`,{d:`M4 8v11a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V8`,key:`1s80jp`}],[`path`,{d:`M10 12h4`,key:`a56b0p`}]]),Ga=V(`bell`,[[`path`,{d:`M10.268 21a2 2 0 0 0 3.464 0`,key:`vwvbt9`}],[`path`,{d:`M3.262 15.326A1 1 0 0 0 4 17h16a1 1 0 0 0 .74-1.673C19.41 13.956 18 12.499 18 8A6 6 0 0 0 6 8c0 4.499-1.411 5.956-2.738 7.326`,key:`11g9vi`}]]),Ka=V(`book`,[[`path`,{d:`M4 19.5v-15A2.5 2.5 0 0 1 6.5 2H19a1 1 0 0 1 1 1v18a1 1 0 0 1-1 1H6.5a1 1 0 0 1 0-5H20`,key:`k3hazp`}]]),qa=V(`bookmark`,[[`path`,{d:`m19 21-7-4-7 4V5a2 2 0 0 1 2-2h10a2 2 0 0 1 2 2v16z`,key:`1fy3hk`}]]),Ja=V(`bug`,[[`path`,{d:`M12 20v-9`,key:`1qisl0`}],[`path`,{d:`M14 7a4 4 0 0 1 4 4v3a6 6 0 0 1-12 0v-3a4 4 0 0 1 4-4z`,key:`uouzyp`}],[`path`,{d:`M14.12 3.88 16 2`,key:`qol33r`}],[`path`,{d:`M21 21a4 4 0 0 0-3.81-4`,key:`1b0z45`}],[`path`,{d:`M21 5a4 4 0 0 1-3.55 3.97`,key:`5cxbf6`}],[`path`,{d:`M22 13h-4`,key:`1jl80f`}],[`path`,{d:`M3 21a4 4 0 0 1 3.81-4`,key:`1fjd4g`}],[`path`,{d:`M3 5a4 4 0 0 0 3.55 3.97`,key:`1d7oge`}],[`path`,{d:`M6 13H2`,key:`82j7cp`}],[`path`,{d:`m8 2 1.88 1.88`,key:`fmnt4t`}],[`path`,{d:`M9 7.13V6a3 3 0 1 1 6 0v1.13`,key:`1vgav8`}]]),Ya=V(`camera`,[[`path`,{d:`M13.997 4a2 2 0 0 1 1.76 1.05l.486.9A2 2 0 0 0 18.003 7H20a2 2 0 0 1 2 2v9a2 2 0 0 1-2 2H4a2 2 0 0 1-2-2V9a2 2 0 0 1 2-2h1.997a2 2 0 0 0 1.759-1.048l.489-.904A2 2 0 0 1 10.004 4z`,key:`18u6gg`}],[`circle`,{cx:`12`,cy:`13`,r:`3`,key:`1vg3eu`}]]),Xa=V(`chart-column`,[[`path`,{d:`M3 3v16a2 2 0 0 0 2 2h16`,key:`c24i48`}],[`path`,{d:`M18 17V9`,key:`2bz60n`}],[`path`,{d:`M13 17V5`,key:`1frdt8`}],[`path`,{d:`M8 17v-3`,key:`17ska0`}]]),Za=V(`chevron-right`,[[`path`,{d:`m9 18 6-6-6-6`,key:`mthhwq`}]]),Qa=V(`chevron-left`,[[`path`,{d:`m15 18-6-6 6-6`,key:`1wnfg3`}]]),$a=V(`circle-arrow-up`,[[`circle`,{cx:`12`,cy:`12`,r:`10`,key:`1mglay`}],[`path`,{d:`m16 12-4-4-4 4`,key:`177agl`}],[`path`,{d:`M12 16V8`,key:`1sbj14`}]]),eo=V(`circle-check`,[[`circle`,{cx:`12`,cy:`12`,r:`10`,key:`1mglay`}],[`path`,{d:`m9 12 2 2 4-4`,key:`dzmm74`}]]),to=V(`circle-minus`,[[`circle`,{cx:`12`,cy:`12`,r:`10`,key:`1mglay`}],[`path`,{d:`M8 12h8`,key:`1wcyev`}]]),no=V(`circle`,[[`circle`,{cx:`12`,cy:`12`,r:`10`,key:`1mglay`}]]),X=V(`clock`,[[`path`,{d:`M12 6v6l4 2`,key:`mmk7yg`}],[`circle`,{cx:`12`,cy:`12`,r:`10`,key:`1mglay`}]]),ro=V(`cloud`,[[`path`,{d:`M17.5 19H9a7 7 0 1 1 6.71-9h1.79a4.5 4.5 0 1 1 0 9Z`,key:`p7xjir`}]]),io=V(`code`,[[`path`,{d:`m16 18 6-6-6-6`,key:`eg8j8`}],[`path`,{d:`m8 6-6 6 6 6`,key:`ppft3o`}]]),ao=V(`coffee`,[[`path`,{d:`M10 2v2`,key:`7u0qdc`}],[`path`,{d:`M14 2v2`,key:`6buw04`}],[`path`,{d:`M16 8a1 1 0 0 1 1 1v8a4 4 0 0 1-4 4H7a4 4 0 0 1-4-4V9a1 1 0 0 1 1-1h14a4 4 0 1 1 0 8h-1`,key:`pwadti`}],[`path`,{d:`M6 2v2`,key:`colzsn`}]]),oo=V(`compass`,[[`path`,{d:`m16.24 7.76-1.804 5.411a2 2 0 0 1-1.265 1.265L7.76 16.24l1.804-5.411a2 2 0 0 1 1.265-1.265z`,key:`9ktpf1`}],[`circle`,{cx:`12`,cy:`12`,r:`10`,key:`1mglay`}]]),so=V(`database`,[[`ellipse`,{cx:`12`,cy:`5`,rx:`9`,ry:`3`,key:`msslwz`}],[`path`,{d:`M3 5V19A9 3 0 0 0 21 19V5`,key:`1wlel7`}],[`path`,{d:`M3 12A9 3 0 0 0 21 12`,key:`mv7ke4`}]]),co=V(`disc-3`,[[`circle`,{cx:`12`,cy:`12`,r:`10`,key:`1mglay`}],[`path`,{d:`M6 12c0-1.7.7-3.2 1.8-4.2`,key:`oqkarx`}],[`circle`,{cx:`12`,cy:`12`,r:`2`,key:`1c9p78`}],[`path`,{d:`M18 12c0 1.7-.7 3.2-1.8 4.2`,key:`1eah9h`}]]),lo=V(`download`,[[`path`,{d:`M12 15V3`,key:`m9g1x1`}],[`path`,{d:`M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4`,key:`ih7n3h`}],[`path`,{d:`m7 10 5 5 5-5`,key:`brsn70`}]]),uo=V(`external-link`,[[`path`,{d:`M15 3h6v6`,key:`1q9fwt`}],[`path`,{d:`M10 14 21 3`,key:`gplh6r`}],[`path`,{d:`M18 13v6a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2h6`,key:`a6xqqp`}]]),fo=V(`eye`,[[`path`,{d:`M2.062 12.348a1 1 0 0 1 0-.696 10.75 10.75 0 0 1 19.876 0 1 1 0 0 1 0 .696 10.75 10.75 0 0 1-19.876 0`,key:`1nclc0`}],[`circle`,{cx:`12`,cy:`12`,r:`3`,key:`1v7zrd`}]]),po=V(`file-text`,[[`path`,{d:`M6 22a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h8a2.4 2.4 0 0 1 1.704.706l3.588 3.588A2.4 2.4 0 0 1 20 8v12a2 2 0 0 1-2 2z`,key:`1oefj6`}],[`path`,{d:`M14 2v5a1 1 0 0 0 1 1h5`,key:`wfsgrz`}],[`path`,{d:`M10 9H8`,key:`b1mrlr`}],[`path`,{d:`M16 13H8`,key:`t4e002`}],[`path`,{d:`M16 17H8`,key:`z1uh3a`}]]),mo=V(`flame`,[[`path`,{d:`M12 3q1 4 4 6.5t3 5.5a1 1 0 0 1-14 0 5 5 0 0 1 1-3 1 1 0 0 0 5 0c0-2-1.5-3-1.5-5q0-2 2.5-4`,key:`1slcih`}]]),ho=V(`folder-kanban`,[[`path`,{d:`M4 20h16a2 2 0 0 0 2-2V8a2 2 0 0 0-2-2h-7.93a2 2 0 0 1-1.66-.9l-.82-1.2A2 2 0 0 0 7.93 3H4a2 2 0 0 0-2 2v13c0 1.1.9 2 2 2Z`,key:`1fr9dc`}],[`path`,{d:`M8 10v4`,key:`tgpxqk`}],[`path`,{d:`M12 10v2`,key:`hh53o1`}],[`path`,{d:`M16 10v6`,key:`1d6xys`}]]),go=V(`folder-open`,[[`path`,{d:`m6 14 1.5-2.9A2 2 0 0 1 9.24 10H20a2 2 0 0 1 1.94 2.5l-1.54 6a2 2 0 0 1-1.95 1.5H4a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h3.9a2 2 0 0 1 1.69.9l.81 1.2a2 2 0 0 0 1.67.9H18a2 2 0 0 1 2 2v2`,key:`usdka0`}]]),_o=V(`folder`,[[`path`,{d:`M20 20a2 2 0 0 0 2-2V8a2 2 0 0 0-2-2h-7.9a2 2 0 0 1-1.69-.9L9.6 3.9A2 2 0 0 0 7.93 3H4a2 2 0 0 0-2 2v13a2 2 0 0 0 2 2Z`,key:`1kt360`}]]),vo=V(`gift`,[[`rect`,{x:`3`,y:`8`,width:`18`,height:`4`,rx:`1`,key:`bkv52`}],[`path`,{d:`M12 8v13`,key:`1c76mn`}],[`path`,{d:`M19 12v7a2 2 0 0 1-2 2H7a2 2 0 0 1-2-2v-7`,key:`6wjy6b`}],[`path`,{d:`M7.5 8a2.5 2.5 0 0 1 0-5A4.8 8 0 0 1 12 8a4.8 8 0 0 1 4.5-5 2.5 2.5 0 0 1 0 5`,key:`1ihvrl`}]]),yo=V(`github`,[[`path`,{d:`M15 22v-4a4.8 4.8 0 0 0-1-3.5c3 0 6-2 6-5.5.08-1.25-.27-2.48-1-3.5.28-1.15.28-2.35 0-3.5 0 0-1 0-3 1.5-2.64-.5-5.36-.5-8 0C6 2 5 2 5 2c-.3 1.15-.3 2.35 0 3.5A5.403 5.403 0 0 0 4 9c0 3.5 3 5.5 6 5.5-.39.49-.68 1.05-.85 1.65-.17.6-.22 1.23-.15 1.85v4`,key:`tonef`}],[`path`,{d:`M9 18c-4.51 2-5-2-7-2`,key:`9comsn`}]]),bo=V(`globe`,[[`circle`,{cx:`12`,cy:`12`,r:`10`,key:`1mglay`}],[`path`,{d:`M12 2a14.5 14.5 0 0 0 0 20 14.5 14.5 0 0 0 0-20`,key:`13o1zl`}],[`path`,{d:`M2 12h20`,key:`9i4pu4`}]]),xo=V(`hand`,[[`path`,{d:`M18 11V6a2 2 0 0 0-2-2a2 2 0 0 0-2 2`,key:`1fvzgz`}],[`path`,{d:`M14 10V4a2 2 0 0 0-2-2a2 2 0 0 0-2 2v2`,key:`1kc0my`}],[`path`,{d:`M10 10.5V6a2 2 0 0 0-2-2a2 2 0 0 0-2 2v8`,key:`10h0bg`}],[`path`,{d:`M18 8a2 2 0 1 1 4 0v6a8 8 0 0 1-8 8h-2c-2.8 0-4.5-.86-5.99-2.34l-3.6-3.6a2 2 0 0 1 2.83-2.82L7 15`,key:`1s1gnw`}]]),So=V(`hash`,[[`line`,{x1:`4`,x2:`20`,y1:`9`,y2:`9`,key:`4lhtct`}],[`line`,{x1:`4`,x2:`20`,y1:`15`,y2:`15`,key:`vyu0kd`}],[`line`,{x1:`10`,x2:`8`,y1:`3`,y2:`21`,key:`1ggp8o`}],[`line`,{x1:`16`,x2:`14`,y1:`3`,y2:`21`,key:`weycgp`}]]),Co=V(`heart`,[[`path`,{d:`M2 9.5a5.5 5.5 0 0 1 9.591-3.676.56.56 0 0 0 .818 0A5.49 5.49 0 0 1 22 9.5c0 2.29-1.5 4-3 5.5l-5.492 5.313a2 2 0 0 1-3 .019L5 15c-1.5-1.5-3-3.2-3-5.5`,key:`mvr1a0`}]]),wo=V(`house`,[[`path`,{d:`M15 21v-8a1 1 0 0 0-1-1h-4a1 1 0 0 0-1 1v8`,key:`5wwlr5`}],[`path`,{d:`M3 10a2 2 0 0 1 .709-1.528l7-6a2 2 0 0 1 2.582 0l7 6A2 2 0 0 1 21 10v9a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2z`,key:`r6nss1`}]]),To=V(`image-off`,[[`line`,{x1:`2`,x2:`22`,y1:`2`,y2:`22`,key:`a6p6uj`}],[`path`,{d:`M10.41 10.41a2 2 0 1 1-2.83-2.83`,key:`1bzlo9`}],[`line`,{x1:`13.5`,x2:`6`,y1:`13.5`,y2:`21`,key:`1q0aeu`}],[`line`,{x1:`18`,x2:`21`,y1:`12`,y2:`15`,key:`5mozeu`}],[`path`,{d:`M3.59 3.59A1.99 1.99 0 0 0 3 5v14a2 2 0 0 0 2 2h14c.55 0 1.052-.22 1.41-.59`,key:`mmje98`}],[`path`,{d:`M21 15V5a2 2 0 0 0-2-2H9`,key:`43el77`}]]),Eo=V(`image`,[[`rect`,{width:`18`,height:`18`,x:`3`,y:`3`,rx:`2`,ry:`2`,key:`1m3agn`}],[`circle`,{cx:`9`,cy:`9`,r:`2`,key:`af1f0g`}],[`path`,{d:`m21 15-3.086-3.086a2 2 0 0 0-2.828 0L6 21`,key:`1xmnt7`}]]),Do=V(`key`,[[`path`,{d:`m15.5 7.5 2.3 2.3a1 1 0 0 0 1.4 0l2.1-2.1a1 1 0 0 0 0-1.4L19 4`,key:`g0fldk`}],[`path`,{d:`m21 2-9.6 9.6`,key:`1j0ho8`}],[`circle`,{cx:`7.5`,cy:`15.5`,r:`5.5`,key:`yqb3hr`}]]),Oo=V(`keyboard`,[[`path`,{d:`M10 8h.01`,key:`1r9ogq`}],[`path`,{d:`M12 12h.01`,key:`1mp3jc`}],[`path`,{d:`M14 8h.01`,key:`1primd`}],[`path`,{d:`M16 12h.01`,key:`1l6xoz`}],[`path`,{d:`M18 8h.01`,key:`emo2bl`}],[`path`,{d:`M6 8h.01`,key:`x9i8wu`}],[`path`,{d:`M7 16h10`,key:`wp8him`}],[`path`,{d:`M8 12h.01`,key:`czm47f`}],[`rect`,{width:`20`,height:`16`,x:`2`,y:`4`,rx:`2`,key:`18n3k1`}]]),ko=V(`layers`,[[`path`,{d:`M12.83 2.18a2 2 0 0 0-1.66 0L2.6 6.08a1 1 0 0 0 0 1.83l8.58 3.91a2 2 0 0 0 1.66 0l8.58-3.9a1 1 0 0 0 0-1.83z`,key:`zw3jo`}],[`path`,{d:`M2 12a1 1 0 0 0 .58.91l8.6 3.91a2 2 0 0 0 1.65 0l8.58-3.9A1 1 0 0 0 22 12`,key:`1wduqc`}],[`path`,{d:`M2 17a1 1 0 0 0 .58.91l8.6 3.91a2 2 0 0 0 1.65 0l8.58-3.9A1 1 0 0 0 22 17`,key:`kqbvx6`}]]),Ao=V(`link`,[[`path`,{d:`M10 13a5 5 0 0 0 7.54.54l3-3a5 5 0 0 0-7.07-7.07l-1.72 1.71`,key:`1cjeqo`}],[`path`,{d:`M14 11a5 5 0 0 0-7.54-.54l-3 3a5 5 0 0 0 7.07 7.07l1.71-1.71`,key:`19qd67`}]]),jo=V(`list-ordered`,[[`path`,{d:`M11 5h10`,key:`1cz7ny`}],[`path`,{d:`M11 12h10`,key:`1438ji`}],[`path`,{d:`M11 19h10`,key:`11t30w`}],[`path`,{d:`M4 4h1v5`,key:`10yrso`}],[`path`,{d:`M4 9h2`,key:`r1h2o0`}],[`path`,{d:`M6.5 20H3.4c0-1 2.6-1.925 2.6-3.5a1.5 1.5 0 0 0-2.6-1.02`,key:`xtkcd5`}]]),Mo=V(`log-out`,[[`path`,{d:`m16 17 5-5-5-5`,key:`1bji2h`}],[`path`,{d:`M21 12H9`,key:`dn1m92`}],[`path`,{d:`M9 21H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h4`,key:`1uf3rs`}]]),No=V(`mail`,[[`path`,{d:`m22 7-8.991 5.727a2 2 0 0 1-2.009 0L2 7`,key:`132q7q`}],[`rect`,{x:`2`,y:`4`,width:`20`,height:`16`,rx:`2`,key:`izxlao`}]]),Po=V(`map`,[[`path`,{d:`M14.106 5.553a2 2 0 0 0 1.788 0l3.659-1.83A1 1 0 0 1 21 4.619v12.764a1 1 0 0 1-.553.894l-4.553 2.277a2 2 0 0 1-1.788 0l-4.212-2.106a2 2 0 0 0-1.788 0l-3.659 1.83A1 1 0 0 1 3 19.381V6.618a1 1 0 0 1 .553-.894l4.553-2.277a2 2 0 0 1 1.788 0z`,key:`169xi5`}],[`path`,{d:`M15 5.764v15`,key:`1pn4in`}],[`path`,{d:`M9 3.236v15`,key:`1uimfh`}]]),Fo=V(`megaphone`,[[`path`,{d:`M11 6a13 13 0 0 0 8.4-2.8A1 1 0 0 1 21 4v12a1 1 0 0 1-1.6.8A13 13 0 0 0 11 14H5a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2z`,key:`q8bfy3`}],[`path`,{d:`M6 14a12 12 0 0 0 2.4 7.2 2 2 0 0 0 3.2-2.4A8 8 0 0 1 10 14`,key:`1853fq`}],[`path`,{d:`M8 6v8`,key:`15ugcq`}]]),Io=V(`menu`,[[`path`,{d:`M4 5h16`,key:`1tepv9`}],[`path`,{d:`M4 12h16`,key:`1lakjw`}],[`path`,{d:`M4 19h16`,key:`1djgab`}]]),Lo=V(`monitor`,[[`rect`,{width:`20`,height:`14`,x:`2`,y:`3`,rx:`2`,key:`48i651`}],[`line`,{x1:`8`,x2:`16`,y1:`21`,y2:`21`,key:`1svkeh`}],[`line`,{x1:`12`,x2:`12`,y1:`17`,y2:`21`,key:`vw1qmm`}]]),Ro=V(`moon`,[[`path`,{d:`M20.985 12.486a9 9 0 1 1-9.473-9.472c.405-.022.617.46.402.803a6 6 0 0 0 8.268 8.268c.344-.215.825-.004.803.401`,key:`kfwtm`}]]),zo=V(`music`,[[`path`,{d:`M9 18V5l12-2v13`,key:`1jmyc2`}],[`circle`,{cx:`6`,cy:`18`,r:`3`,key:`fqmcym`}],[`circle`,{cx:`18`,cy:`16`,r:`3`,key:`1hluhg`}]]),Bo=V(`palette`,[[`path`,{d:`M12 22a1 1 0 0 1 0-20 10 9 0 0 1 10 9 5 5 0 0 1-5 5h-2.25a1.75 1.75 0 0 0-1.4 2.8l.3.4a1.75 1.75 0 0 1-1.4 2.8z`,key:`e79jfc`}],[`circle`,{cx:`13.5`,cy:`6.5`,r:`.5`,fill:`currentColor`,key:`1okk4w`}],[`circle`,{cx:`17.5`,cy:`10.5`,r:`.5`,fill:`currentColor`,key:`f64h9f`}],[`circle`,{cx:`6.5`,cy:`12.5`,r:`.5`,fill:`currentColor`,key:`qy21gx`}],[`circle`,{cx:`8.5`,cy:`7.5`,r:`.5`,fill:`currentColor`,key:`fotxhn`}]]),Vo=V(`pencil`,[[`path`,{d:`M21.174 6.812a1 1 0 0 0-3.986-3.987L3.842 16.174a2 2 0 0 0-.5.83l-1.321 4.352a.5.5 0 0 0 .623.622l4.353-1.32a2 2 0 0 0 .83-.497z`,key:`1a8usu`}],[`path`,{d:`m15 5 4 4`,key:`1mk7zo`}]]),Ho=V(`phone`,[[`path`,{d:`M13.832 16.568a1 1 0 0 0 1.213-.303l.355-.465A2 2 0 0 1 17 15h3a2 2 0 0 1 2 2v3a2 2 0 0 1-2 2A18 18 0 0 1 2 4a2 2 0 0 1 2-2h3a2 2 0 0 1 2 2v3a2 2 0 0 1-.8 1.6l-.468.351a1 1 0 0 0-.292 1.233 14 14 0 0 0 6.392 6.384`,key:`9njp5v`}]]),Uo=V(`plug`,[[`path`,{d:`M12 22v-5`,key:`1ega77`}],[`path`,{d:`M9 8V2`,key:`14iosj`}],[`path`,{d:`M15 8V2`,key:`18g5xt`}],[`path`,{d:`M18 8v5a4 4 0 0 1-4 4h-4a4 4 0 0 1-4-4V8Z`,key:`osxo6l`}]]),Wo=V(`plus`,[[`path`,{d:`M5 12h14`,key:`1ays0h`}],[`path`,{d:`M12 5v14`,key:`s699le`}]]),Go=V(`power-off`,[[`path`,{d:`M18.36 6.64A9 9 0 0 1 20.77 15`,key:`dxknvb`}],[`path`,{d:`M6.16 6.16a9 9 0 1 0 12.68 12.68`,key:`1x7qb5`}],[`path`,{d:`M12 2v4`,key:`3427ic`}],[`path`,{d:`m2 2 20 20`,key:`1ooewy`}]]),Ko=V(`power`,[[`path`,{d:`M12 2v10`,key:`mnfbl`}],[`path`,{d:`M18.4 6.6a9 9 0 1 1-12.77.04`,key:`obofu9`}]]),qo=V(`printer`,[[`path`,{d:`M6 18H4a2 2 0 0 1-2-2v-5a2 2 0 0 1 2-2h16a2 2 0 0 1 2 2v5a2 2 0 0 1-2 2h-2`,key:`143wyd`}],[`path`,{d:`M6 9V3a1 1 0 0 1 1-1h10a1 1 0 0 1 1 1v6`,key:`1itne7`}],[`rect`,{x:`6`,y:`14`,width:`12`,height:`8`,rx:`1`,key:`1ue0tg`}]]),Jo=V(`radio`,[[`path`,{d:`M16.247 7.761a6 6 0 0 1 0 8.478`,key:`1fwjs5`}],[`path`,{d:`M19.075 4.933a10 10 0 0 1 0 14.134`,key:`ehdyv1`}],[`path`,{d:`M4.925 19.067a10 10 0 0 1 0-14.134`,key:`1q22gi`}],[`path`,{d:`M7.753 16.239a6 6 0 0 1 0-8.478`,key:`r2q7qm`}],[`circle`,{cx:`12`,cy:`12`,r:`2`,key:`1c9p78`}]]),Yo=V(`receipt`,[[`path`,{d:`M4 2v20l2-1 2 1 2-1 2 1 2-1 2 1 2-1 2 1V2l-2 1-2-1-2 1-2-1-2 1-2-1-2 1Z`,key:`q3az6g`}],[`path`,{d:`M16 8h-6a2 2 0 1 0 0 4h4a2 2 0 1 1 0 4H8`,key:`1h4pet`}],[`path`,{d:`M12 17.5v-11`,key:`1jc1ny`}]]),Xo=V(`refresh-cw`,[[`path`,{d:`M3 12a9 9 0 0 1 9-9 9.75 9.75 0 0 1 6.74 2.74L21 8`,key:`v9h5vc`}],[`path`,{d:`M21 3v5h-5`,key:`1q7to0`}],[`path`,{d:`M21 12a9 9 0 0 1-9 9 9.75 9.75 0 0 1-6.74-2.74L3 16`,key:`3uifl3`}],[`path`,{d:`M8 16H3v5`,key:`1cv678`}]]),Zo=V(`rotate-ccw`,[[`path`,{d:`M3 12a9 9 0 1 0 9-9 9.75 9.75 0 0 0-6.74 2.74L3 8`,key:`1357e3`}],[`path`,{d:`M3 3v5h5`,key:`1xhq8a`}]]),Qo=V(`rotate-cw`,[[`path`,{d:`M21 12a9 9 0 1 1-9-9c2.52 0 4.93 1 6.74 2.74L21 8`,key:`1p45f6`}],[`path`,{d:`M21 3v5h-5`,key:`1q7to0`}]]),$o=V(`save`,[[`path`,{d:`M15.2 3a2 2 0 0 1 1.4.6l3.8 3.8a2 2 0 0 1 .6 1.4V19a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2z`,key:`1c8476`}],[`path`,{d:`M17 21v-7a1 1 0 0 0-1-1H8a1 1 0 0 0-1 1v7`,key:`1ydtos`}],[`path`,{d:`M7 3v4a1 1 0 0 0 1 1h7`,key:`t51u73`}]]),es=V(`server-cog`,[[`path`,{d:`m10.852 14.772-.383.923`,key:`11vil6`}],[`path`,{d:`M13.148 14.772a3 3 0 1 0-2.296-5.544l-.383-.923`,key:`1v3clb`}],[`path`,{d:`m13.148 9.228.383-.923`,key:`t2zzyc`}],[`path`,{d:`m13.53 15.696-.382-.924a3 3 0 1 1-2.296-5.544`,key:`1bxfiv`}],[`path`,{d:`m14.772 10.852.923-.383`,key:`k9m8cz`}],[`path`,{d:`m14.772 13.148.923.383`,key:`1xvhww`}],[`path`,{d:`M4.5 10H4a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h16a2 2 0 0 1 2 2v4a2 2 0 0 1-2 2h-.5`,key:`tn8das`}],[`path`,{d:`M4.5 14H4a2 2 0 0 0-2 2v4a2 2 0 0 0 2 2h16a2 2 0 0 0 2-2v-4a2 2 0 0 0-2-2h-.5`,key:`1g2pve`}],[`path`,{d:`M6 18h.01`,key:`uhywen`}],[`path`,{d:`M6 6h.01`,key:`1utrut`}],[`path`,{d:`m9.228 10.852-.923-.383`,key:`1wtb30`}],[`path`,{d:`m9.228 13.148-.923.383`,key:`1a830x`}]]),ts=V(`server`,[[`rect`,{width:`20`,height:`8`,x:`2`,y:`2`,rx:`2`,ry:`2`,key:`ngkwjq`}],[`rect`,{width:`20`,height:`8`,x:`2`,y:`14`,rx:`2`,ry:`2`,key:`iecqi9`}],[`line`,{x1:`6`,x2:`6.01`,y1:`6`,y2:`6`,key:`16zg32`}],[`line`,{x1:`6`,x2:`6.01`,y1:`18`,y2:`18`,key:`nzw8ys`}]]),ns=V(`settings`,[[`path`,{d:`M9.671 4.136a2.34 2.34 0 0 1 4.659 0 2.34 2.34 0 0 0 3.319 1.915 2.34 2.34 0 0 1 2.33 4.033 2.34 2.34 0 0 0 0 3.831 2.34 2.34 0 0 1-2.33 4.033 2.34 2.34 0 0 0-3.319 1.915 2.34 2.34 0 0 1-4.659 0 2.34 2.34 0 0 0-3.32-1.915 2.34 2.34 0 0 1-2.33-4.033 2.34 2.34 0 0 0 0-3.831A2.34 2.34 0 0 1 6.35 6.051a2.34 2.34 0 0 0 3.319-1.915`,key:`1i5ecw`}],[`circle`,{cx:`12`,cy:`12`,r:`3`,key:`1v7zrd`}]]),rs=V(`shield-alert`,[[`path`,{d:`M20 13c0 5-3.5 7.5-7.66 8.95a1 1 0 0 1-.67-.01C7.5 20.5 4 18 4 13V6a1 1 0 0 1 1-1c2 0 4.5-1.2 6.24-2.72a1.17 1.17 0 0 1 1.52 0C14.51 3.81 17 5 19 5a1 1 0 0 1 1 1z`,key:`oel41y`}],[`path`,{d:`M12 8v4`,key:`1got3b`}],[`path`,{d:`M12 16h.01`,key:`1drbdi`}]]),is=V(`shopping-cart`,[[`circle`,{cx:`8`,cy:`21`,r:`1`,key:`jimo8o`}],[`circle`,{cx:`19`,cy:`21`,r:`1`,key:`13723u`}],[`path`,{d:`M2.05 2.05h2l2.66 12.42a2 2 0 0 0 2 1.58h9.78a2 2 0 0 0 1.95-1.57l1.65-7.43H5.12`,key:`9zh506`}]]),as=V(`square-check-big`,[[`path`,{d:`M21 10.656V19a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h12.344`,key:`2acyp4`}],[`path`,{d:`m9 11 3 3L22 4`,key:`1pflzl`}]]),os=V(`square`,[[`rect`,{width:`18`,height:`18`,x:`3`,y:`3`,rx:`2`,key:`afitv7`}]]),ss=V(`star`,[[`path`,{d:`M11.525 2.295a.53.53 0 0 1 .95 0l2.31 4.679a2.123 2.123 0 0 0 1.595 1.16l5.166.756a.53.53 0 0 1 .294.904l-3.736 3.638a2.123 2.123 0 0 0-.611 1.878l.882 5.14a.53.53 0 0 1-.771.56l-4.618-2.428a2.122 2.122 0 0 0-1.973 0L6.396 21.01a.53.53 0 0 1-.77-.56l.881-5.139a2.122 2.122 0 0 0-.611-1.879L2.16 9.795a.53.53 0 0 1 .294-.906l5.165-.755a2.122 2.122 0 0 0 1.597-1.16z`,key:`r04s7s`}]]),cs=V(`stethoscope`,[[`path`,{d:`M11 2v2`,key:`1539x4`}],[`path`,{d:`M5 2v2`,key:`1yf1q8`}],[`path`,{d:`M5 3H4a2 2 0 0 0-2 2v4a6 6 0 0 0 12 0V5a2 2 0 0 0-2-2h-1`,key:`rb5t3r`}],[`path`,{d:`M8 15a6 6 0 0 0 12 0v-3`,key:`x18d4x`}],[`circle`,{cx:`20`,cy:`10`,r:`2`,key:`ts1r5v`}]]),ls=V(`sun`,[[`circle`,{cx:`12`,cy:`12`,r:`4`,key:`4exip2`}],[`path`,{d:`M12 2v2`,key:`tus03m`}],[`path`,{d:`M12 20v2`,key:`1lh1kg`}],[`path`,{d:`m4.93 4.93 1.41 1.41`,key:`149t6j`}],[`path`,{d:`m17.66 17.66 1.41 1.41`,key:`ptbguv`}],[`path`,{d:`M2 12h2`,key:`1t8f8n`}],[`path`,{d:`M20 12h2`,key:`1q8mjw`}],[`path`,{d:`m6.34 17.66-1.41 1.41`,key:`1m8zz5`}],[`path`,{d:`m19.07 4.93-1.41 1.41`,key:`1shlcs`}]]),us=V(`tag`,[[`path`,{d:`M12.586 2.586A2 2 0 0 0 11.172 2H4a2 2 0 0 0-2 2v7.172a2 2 0 0 0 .586 1.414l8.704 8.704a2.426 2.426 0 0 0 3.42 0l6.58-6.58a2.426 2.426 0 0 0 0-3.42z`,key:`vktsd0`}],[`circle`,{cx:`7.5`,cy:`7.5`,r:`.5`,fill:`currentColor`,key:`kqv944`}]]),ds=V(`terminal`,[[`path`,{d:`M12 19h8`,key:`baeox8`}],[`path`,{d:`m4 17 6-6-6-6`,key:`1yngyt`}]]),fs=V(`thumbs-down`,[[`path`,{d:`M17 14V2`,key:`8ymqnk`}],[`path`,{d:`M9 18.12 10 14H4.17a2 2 0 0 1-1.92-2.56l2.33-8A2 2 0 0 1 6.5 2H20a2 2 0 0 1 2 2v8a2 2 0 0 1-2 2h-2.76a2 2 0 0 0-1.79 1.11L12 22a3.13 3.13 0 0 1-3-3.88Z`,key:`m61m77`}]]),ps=V(`thumbs-up`,[[`path`,{d:`M7 10v12`,key:`1qc93n`}],[`path`,{d:`M15 5.88 14 10h5.83a2 2 0 0 1 1.92 2.56l-2.33 8A2 2 0 0 1 17.5 22H4a2 2 0 0 1-2-2v-8a2 2 0 0 1 2-2h2.76a2 2 0 0 0 1.79-1.11L12 2a3.13 3.13 0 0 1 3 3.88Z`,key:`emmmcr`}]]),ms=V(`trash-2`,[[`path`,{d:`M10 11v6`,key:`nco0om`}],[`path`,{d:`M14 11v6`,key:`outv1u`}],[`path`,{d:`M19 6v14a2 2 0 0 1-2 2H7a2 2 0 0 1-2-2V6`,key:`miytrc`}],[`path`,{d:`M3 6h18`,key:`d0wm0j`}],[`path`,{d:`M8 6V4a2 2 0 0 1 2-2h4a2 2 0 0 1 2 2v2`,key:`e791ji`}]]),hs=V(`upload`,[[`path`,{d:`M12 3v12`,key:`1x0j5s`}],[`path`,{d:`m17 8-5-5-5 5`,key:`7q97r8`}],[`path`,{d:`M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4`,key:`ih7n3h`}]]),gs=V(`user`,[[`path`,{d:`M19 21v-2a4 4 0 0 0-4-4H9a4 4 0 0 0-4 4v2`,key:`975kel`}],[`circle`,{cx:`12`,cy:`7`,r:`4`,key:`17ys0d`}]]),_s=V(`users`,[[`path`,{d:`M16 21v-2a4 4 0 0 0-4-4H6a4 4 0 0 0-4 4v2`,key:`1yyitq`}],[`path`,{d:`M16 3.128a4 4 0 0 1 0 7.744`,key:`16gr8j`}],[`path`,{d:`M22 21v-2a4 4 0 0 0-3-3.87`,key:`kshegd`}],[`circle`,{cx:`9`,cy:`7`,r:`4`,key:`nufk8`}]]),vs=V(`video`,[[`path`,{d:`m16 13 5.223 3.482a.5.5 0 0 0 .777-.416V7.87a.5.5 0 0 0-.752-.432L16 10.5`,key:`ftymec`}],[`rect`,{x:`2`,y:`6`,width:`14`,height:`12`,rx:`2`,key:`158x01`}]]),ys=V(`wand-sparkles`,[[`path`,{d:`m21.64 3.64-1.28-1.28a1.21 1.21 0 0 0-1.72 0L2.36 18.64a1.21 1.21 0 0 0 0 1.72l1.28 1.28a1.2 1.2 0 0 0 1.72 0L21.64 5.36a1.2 1.2 0 0 0 0-1.72`,key:`ul74o6`}],[`path`,{d:`m14 7 3 3`,key:`1r5n42`}],[`path`,{d:`M5 6v4`,key:`ilb8ba`}],[`path`,{d:`M19 14v4`,key:`blhpug`}],[`path`,{d:`M10 2v2`,key:`7u0qdc`}],[`path`,{d:`M7 8H3`,key:`zfb6yr`}],[`path`,{d:`M21 16h-4`,key:`1cnmox`}],[`path`,{d:`M11 3H9`,key:`1obp7u`}]]),bs=V(`weight`,[[`circle`,{cx:`12`,cy:`5`,r:`3`,key:`rqqgnr`}],[`path`,{d:`M6.5 8a2 2 0 0 0-1.905 1.46L2.1 18.5A2 2 0 0 0 4 21h16a2 2 0 0 0 1.925-2.54L19.4 9.5A2 2 0 0 0 17.48 8Z`,key:`56o5sh`}]]),xs=V(`wifi-off`,[[`path`,{d:`M12 20h.01`,key:`zekei9`}],[`path`,{d:`M8.5 16.429a5 5 0 0 1 7 0`,key:`1bycff`}],[`path`,{d:`M5 12.859a10 10 0 0 1 5.17-2.69`,key:`1dl1wf`}],[`path`,{d:`M19 12.859a10 10 0 0 0-2.007-1.523`,key:`4k23kn`}],[`path`,{d:`M2 8.82a15 15 0 0 1 4.177-2.643`,key:`1grhjp`}],[`path`,{d:`M22 8.82a15 15 0 0 0-11.288-3.764`,key:`z3jwby`}],[`path`,{d:`m2 2 20 20`,key:`1ooewy`}]]),Ss=V(`wifi`,[[`path`,{d:`M12 20h.01`,key:`zekei9`}],[`path`,{d:`M2 8.82a15 15 0 0 1 20 0`,key:`dnpr2z`}],[`path`,{d:`M5 12.859a10 10 0 0 1 14 0`,key:`1x1e6c`}],[`path`,{d:`M8.5 16.429a5 5 0 0 1 7 0`,key:`1bycff`}]]),Cs=V(`wrench`,[[`path`,{d:`M14.7 6.3a1 1 0 0 0 0 1.4l1.6 1.6a1 1 0 0 0 1.4 0l3.106-3.105c.32-.322.863-.22.983.218a6 6 0 0 1-8.259 7.057l-7.91 7.91a1 1 0 0 1-2.999-3l7.91-7.91a6 6 0 0 1 7.057-8.259c.438.12.54.662.219.984z`,key:`1ngwbx`}]]),ws=V(`zap`,[[`path`,{d:`M4 14a1 1 0 0 1-.78-1.63l9.9-10.2a.5.5 0 0 1 .86.46l-1.92 6.02A1 1 0 0 0 13 10h7a1 1 0 0 1 .78 1.63l-9.9 10.2a.5.5 0 0 1-.86-.46l1.92-6.02A1 1 0 0 0 11 14z`,key:`1xq2db`}]]),Z=n();function Ts({fullScreen:e=!1}){let{t}=v();return(0,Z.jsx)(`div`,{role:`status`,"aria-label":t(`common.loading`),className:`flex items-center justify-center ${e?`min-h-screen`:`py-24`}`,children:(0,Z.jsx)(he,{className:`w-8 h-8 animate-spin text-bambu-green`})})}var Es=(0,W.createContext)(void 0);function Ds({children:e}){let[t,n]=(0,W.useState)(null),[r,i]=(0,W.useState)(!1),[a,s]=(0,W.useState)(!1),[c,l]=(0,W.useState)(!0),u=(0,W.useRef)(!1),p=(0,W.useRef)(!0),m=async()=>{try{let e=new URLSearchParams(window.location.search),t=/^\/(?:overlay\/[^/]+|camwall)\/?$/i.test(window.location.pathname)?null:e.get(`token`);if(t){f(t,`session`),e.delete(`token`);let n=e.toString(),r=window.location.pathname+(n?`?${n}`:``)+window.location.hash;window.history.replaceState({},``,r)}let r=await o.getAuthStatus();if(!p.current)return;if(i(r.auth_enabled),s(r.requires_setup),r.auth_enabled){let e=d();if(e){let r=null,i=!1;for(let e=1;e<=3;e++)try{r=await o.getCurrentUser();break}catch(t){if(!p.current)return;if(t instanceof h&&t.status===401){i=!0;break}e<3&&await new Promise(t=>setTimeout(t,400*e))}if(!p.current)return;r?(n(r),t&&e===t&&f(t,`persistent`)):(i&&f(null),n(null))}else n(null)}else n(null)}catch{if(!p.current)return;i(!1),n(null)}finally{p.current&&l(!1)}};(0,W.useEffect)(()=>{p.current=!0,m();let e=()=>{p.current&&n(null)};return window.addEventListener(`auth:expired`,e),()=>{p.current=!1,window.removeEventListener(`auth:expired`,e)}},[]),(0,W.useEffect)(()=>{if(!c&&a&&!r){let e=window.location.pathname;e!==`/setup`&&!e.startsWith(`/camera/`)&&!u.current&&(u.current=!0,window.location.href=`/setup`)}else a||(u.current=!1)},[c,a,r]);let g=async(e,t,n=`session`)=>{let r=await o.login({username:e,password:t});return!r.requires_2fa&&r.access_token&&(f(r.access_token,n),await m()),r},_=(e,t,r=`session`)=>{f(e,r),n(t),i(!0)},v=()=>{f(null),n(null),o.logout().catch(()=>{}),window.location.href=`/login`},y=async()=>{if(r&&d())try{let e=await o.getCurrentUser();p.current&&n(e)}catch{f(null),p.current&&n(null)}},b=async()=>{await m()},x=(0,W.useMemo)(()=>new Set(t?.permissions??[]),[t?.permissions]),S=(0,W.useMemo)(()=>r?t?.is_admin??!1:!0,[r,t?.is_admin]),C=(0,W.useCallback)(e=>!r||S?!0:x.has(e),[r,S,x]),w=(0,W.useCallback)((...e)=>!r||S?!0:e.some(e=>x.has(e)),[r,S,x]),T=(0,W.useCallback)((...e)=>!r||S?!0:e.every(e=>x.has(e)),[r,S,x]),E=(0,W.useCallback)((e,n,i)=>{if(!r||S)return!0;let a=`${e}:${n}_all`,o=`${e}:${n}_own`;return x.has(a)?!0:x.has(o)?i==null?!1:i===t?.id:!1},[r,S,x,t?.id]);return(0,Z.jsx)(Es.Provider,{value:{user:t,authEnabled:r,requiresSetup:a,loading:c,isAdmin:S,login:g,loginWithToken:_,logout:v,refreshUser:y,refreshAuth:b,hasPermission:C,hasAnyPermission:w,hasAllPermissions:T,canModify:E},children:e})}function Os(){let e=(0,W.useContext)(Es);if(e===void 0)throw Error(`useAuth must be used within an AuthProvider`);return e}var ks=(0,W.createContext)(void 0);function As({children:e}){let{authEnabled:t,user:n,loading:r}=Os(),[i,a]=(0,W.useState)(()=>{let e=localStorage.getItem(`theme-mode`),t=localStorage.getItem(`theme`);return e||t||`dark`}),[s,c]=(0,W.useState)(()=>window.matchMedia(`(prefers-color-scheme: dark)`).matches?`dark`:`light`);(0,W.useEffect)(()=>{let e=window.matchMedia(`(prefers-color-scheme: dark)`),t=e=>{c(e.matches?`dark`:`light`)};return e.addEventListener(`change`,t),()=>e.removeEventListener(`change`,t)},[]);let l=i===`system`?s:i,[u,d]=(0,W.useState)(()=>localStorage.getItem(`dark-style`)||`vibrant`),[f,p]=(0,W.useState)(()=>localStorage.getItem(`dark-background`)||`cool`),[m,h]=(0,W.useState)(()=>localStorage.getItem(`dark-accent`)||`green`),[g,_]=(0,W.useState)(()=>localStorage.getItem(`light-style`)||`classic`),[v,y]=(0,W.useState)(()=>localStorage.getItem(`light-background`)||`neutral`),[b,x]=(0,W.useState)(()=>localStorage.getItem(`light-accent`)||`green`),[S,C]=(0,W.useState)(()=>localStorage.getItem(`progress-in-title`)===`true`);return(0,W.useEffect)(()=>{r||t&&n===null||o.getSettings().then(e=>{e.dark_style&&(d(e.dark_style),localStorage.setItem(`dark-style`,e.dark_style)),e.dark_background&&(p(e.dark_background),localStorage.setItem(`dark-background`,e.dark_background)),e.dark_accent&&(h(e.dark_accent),localStorage.setItem(`dark-accent`,e.dark_accent)),e.light_style&&(_(e.light_style),localStorage.setItem(`light-style`,e.light_style)),e.light_background&&(y(e.light_background),localStorage.setItem(`light-background`,e.light_background)),e.light_accent&&(x(e.light_accent),localStorage.setItem(`light-accent`,e.light_accent))}).catch(()=>{})},[r,t,n]),(0,W.useEffect)(()=>{let e=document.documentElement;e.classList.remove(`dark`,`style-classic`,`style-glow`,`style-vibrant`,`bg-neutral`,`bg-warm`,`bg-cool`,`bg-oled`,`bg-slate`,`bg-forest`,`accent-green`,`accent-teal`,`accent-blue`,`accent-orange`,`accent-purple`,`accent-red`),l===`dark`?(e.classList.add(`dark`),e.classList.add(`style-${u}`),e.classList.add(`bg-${f}`),e.classList.add(`accent-${m}`)):(e.classList.add(`style-${g}`),e.classList.add(`bg-${v}`),e.classList.add(`accent-${b}`)),localStorage.setItem(`theme-mode`,i),localStorage.removeItem(`theme`)},[i,l,u,f,m,g,v,b]),(0,Z.jsx)(ks.Provider,{value:{mode:i,resolvedMode:l,darkStyle:u,darkBackground:f,darkAccent:m,lightStyle:g,lightBackground:v,lightAccent:b,progressInTitle:S,setProgressInTitle:e=>{C(e),localStorage.setItem(`progress-in-title`,String(e))},toggleMode:()=>a(e=>e===`dark`?`light`:e===`light`?`system`:`dark`),setMode:e=>a(e),setDarkStyle:e=>{d(e),localStorage.setItem(`dark-style`,e),o.updateSettings({dark_style:e}).catch(()=>{})},setDarkBackground:e=>{p(e),localStorage.setItem(`dark-background`,e),o.updateSettings({dark_background:e}).catch(()=>{})},setDarkAccent:e=>{h(e),localStorage.setItem(`dark-accent`,e),o.updateSettings({dark_accent:e}).catch(()=>{})},setLightStyle:e=>{_(e),localStorage.setItem(`light-style`,e),o.updateSettings({light_style:e}).catch(()=>{})},setLightBackground:e=>{y(e),localStorage.setItem(`light-background`,e),o.updateSettings({light_background:e}).catch(()=>{})},setLightAccent:e=>{x(e),localStorage.setItem(`light-accent`,e),o.updateSettings({light_accent:e}).catch(()=>{})}},children:e})}function js(){let e=(0,W.useContext)(ks);if(!e)throw Error(`useTheme must be used within ThemeProvider`);return e}function Ms(e,t,n){return[{category:`Navigation`,items:e?e.slice(0,9).map((e,t)=>({keys:[String(t+1)],description:e.type===`external`?`Open ${e.label}`:`Go to ${e.labelKey?n(e.labelKey):e.label}`,isExternal:e.type===`external`})):t?t.map((e,t)=>({keys:[String(t+1)],description:`Go to ${n(e.labelKey)}`,isExternal:!1})):[{keys:[`1`],description:`Go to Printers`,isExternal:!1},{keys:[`2`],description:`Go to Archives`,isExternal:!1},{keys:[`3`],description:`Go to Queue`,isExternal:!1},{keys:[`4`],description:`Go to Statistics`,isExternal:!1},{keys:[`5`],description:`Go to Cloud Profiles`,isExternal:!1},{keys:[`6`],description:`Go to Settings`,isExternal:!1}]},{category:`Archives`,items:[{keys:[`/`],description:`Focus search`,isExternal:!1},{keys:[`U`],description:`Open upload modal`,isExternal:!1},{keys:[`Esc`],description:`Clear selection / blur input`,isExternal:!1},{keys:[`Right-click`],description:`Context menu on cards`,isExternal:!1}]},{category:`K-Profiles`,items:[{keys:[`R`],description:`Refresh profiles`,isExternal:!1},{keys:[`N`],description:`New profile`,isExternal:!1},{keys:[`Esc`],description:`Exit selection mode`,isExternal:!1}]},{category:`General`,items:[{keys:[`?`],description:`Show this help`,isExternal:!1}]}]}function Ns({children:e}){return(0,Z.jsx)(`kbd`,{className:`px-2 py-1 text-xs font-mono bg-bambu-dark border border-bambu-dark-tertiary rounded text-white`,children:e})}function Ps({onClose:e,navItems:t,sidebarItems:n}){let{t:r}=v(),i=Ms(n,t,r);return(0,W.useEffect)(()=>{let t=t=>{t.key===`Escape`&&e()};return window.addEventListener(`keydown`,t),()=>window.removeEventListener(`keydown`,t)},[e]),(0,Z.jsx)(`div`,{className:`fixed inset-0 bg-black/50 flex items-center justify-center z-50 p-4`,onClick:e,children:(0,Z.jsx)(be,{className:`w-full max-w-md`,onClick:e=>e.stopPropagation(),children:(0,Z.jsxs)(ye,{className:`p-0`,children:[(0,Z.jsxs)(`div`,{className:`flex items-center justify-between p-4 border-b border-bambu-dark-tertiary`,children:[(0,Z.jsxs)(`div`,{className:`flex items-center gap-2`,children:[(0,Z.jsx)(Oo,{className:`w-5 h-5 text-bambu-green`}),(0,Z.jsx)(`h2`,{className:`text-xl font-semibold text-white`,children:`Keyboard Shortcuts`})]}),(0,Z.jsx)(`button`,{onClick:e,className:`text-bambu-gray hover:text-white transition-colors`,children:(0,Z.jsx)(_e,{className:`w-5 h-5`})})]}),(0,Z.jsx)(`div`,{className:`p-4 space-y-6 max-h-[60vh] overflow-y-auto`,children:i.map(e=>(0,Z.jsxs)(`div`,{children:[(0,Z.jsx)(`h3`,{className:`text-sm font-medium text-bambu-gray mb-3`,children:e.category}),(0,Z.jsx)(`div`,{className:`space-y-2`,children:e.items.map(e=>(0,Z.jsxs)(`div`,{className:`flex items-center justify-between`,children:[(0,Z.jsxs)(`span`,{className:`text-white text-sm flex items-center gap-1.5`,children:[e.description,e.isExternal&&(0,Z.jsx)(uo,{className:`w-3 h-3 text-bambu-gray`})]}),(0,Z.jsx)(`div`,{className:`flex gap-1`,children:e.keys.map(e=>(0,Z.jsx)(Ns,{children:e},e))})]},e.description))})]},e.category))}),(0,Z.jsx)(`div`,{className:`p-4 border-t border-bambu-dark-tertiary`,children:(0,Z.jsxs)(`p`,{className:`text-xs text-bambu-gray text-center`,children:[`Press `,(0,Z.jsx)(Ns,{children:`Esc`}),` or click outside to close`]})})]})})})}function Fs(){let{t:e}=v(),{showToast:t}=fe(),[n,r]=(0,W.useState)(null);return(0,W.useEffect)(()=>{let e=e=>{e.preventDefault(),r(e)},t=()=>r(null);return window.addEventListener(`beforeinstallprompt`,e),window.addEventListener(`appinstalled`,t),()=>{window.removeEventListener(`beforeinstallprompt`,e),window.removeEventListener(`appinstalled`,t)}},[]),n?(0,Z.jsx)(`button`,{onClick:async()=>{await n.prompt();let{outcome:i}=await n.userChoice;r(null),i===`accepted`&&t(e(`nav.installAppSuccess`),`success`)},className:`p-2 rounded-lg hover:bg-bambu-dark-tertiary transition-colors text-bambu-gray-light hover:text-white`,title:e(`nav.installApp`),"aria-label":e(`nav.installApp`),children:(0,Z.jsx)(lo,{className:`w-5 h-5`})}):null}function Is({title:e,message:t,confirmText:n,cancelText:r,cancelVariant:i,cardClassName:a,overlayZIndex:o,variant:s=`default`,isLoading:c=!1,loadingText:l,confirmDisabled:u=!1,children:d,onConfirm:f,onCancel:p}){let{t:m}=v(),h=n??m(`common.confirm`),g=r??m(`common.cancel`),_=l??m(`common.loading`);(0,W.useEffect)(()=>{let e=e=>{e.key===`Escape`&&!c&&p()};return window.addEventListener(`keydown`,e),()=>window.removeEventListener(`keydown`,e)},[p,c]);let y={danger:{icon:`text-red-600 dark:text-red-400`,button:`bg-red-500 hover:bg-red-600`},warning:{icon:`text-yellow-600 dark:text-yellow-400`,button:`bg-yellow-500 hover:bg-yellow-600 text-black`},default:{icon:`text-bambu-green`,button:`bg-bambu-green hover:bg-bambu-green-dark`}}[s];return(0,Z.jsx)(`div`,{className:`fixed inset-0 bg-black/50 flex items-center justify-center p-4 ${o??`z-50`}`,onClick:c?void 0:p,children:(0,Z.jsx)(be,{className:`w-full max-w-md ${a??``}`,onClick:e=>e.stopPropagation(),children:(0,Z.jsxs)(ye,{className:`p-6`,children:[(0,Z.jsxs)(`div`,{className:`flex items-start gap-4`,children:[(0,Z.jsx)(`div`,{className:`p-2 rounded-full bg-bambu-dark ${y.icon}`,children:(0,Z.jsx)(ge,{className:`w-6 h-6`})}),(0,Z.jsxs)(`div`,{className:`flex-1`,children:[(0,Z.jsx)(`h3`,{className:`text-lg font-semibold text-white mb-2`,children:e}),(0,Z.jsx)(`p`,{className:`text-bambu-gray text-sm whitespace-pre-line`,children:t}),d&&(0,Z.jsx)(`div`,{className:`mt-4`,children:d})]})]}),(0,Z.jsxs)(`div`,{className:`flex gap-3 mt-6`,children:[(0,Z.jsx)(xe,{variant:i??`secondary`,onClick:p,className:`flex-1`,disabled:c,children:g}),(0,Z.jsx)(xe,{onClick:f,className:`flex-1 ${y.button}`,disabled:c||u,children:c?(0,Z.jsxs)(Z.Fragment,{children:[(0,Z.jsx)(he,{className:`w-4 h-4 mr-2 animate-spin`}),_]}):h})]})]})})})}function Ls({plug:e}){let t=F(),[n,r]=(0,W.useState)(null),{data:i,isLoading:a}=z({queryKey:[`smart-plug-status`,e.id],queryFn:()=>o.getSmartPlugStatus(e.id),refetchInterval:1e4}),s=ie({mutationFn:t=>o.controlSmartPlug(e.id,t),onSuccess:()=>{t.invalidateQueries({queryKey:[`smart-plug-status`,e.id]})}}),c=i?.state===`ON`,l=e.plug_type===`mqtt`&&i?.energy?.power!==null&&i?.energy?.power!==void 0,u=(i?.reachable??!1)||l,d=s.isPending,f=e.plug_type===`mqtt`;return(0,Z.jsxs)(Z.Fragment,{children:[(0,Z.jsxs)(`div`,{className:`flex items-center justify-between py-2 px-3 hover:bg-bambu-dark-tertiary rounded-lg transition-colors`,children:[(0,Z.jsxs)(`div`,{className:`flex items-center gap-2`,children:[(0,Z.jsx)(`div`,{className:`p-1.5 rounded ${f?u?`bg-teal-500/20`:`bg-red-500/20`:u?c?`bg-bambu-green/20`:`bg-bambu-dark`:`bg-red-500/20`}`,children:f?(0,Z.jsx)(Jo,{className:`w-4 h-4 ${u?`text-teal-600 dark:text-teal-400`:`text-red-600 dark:text-red-400`}`}):(0,Z.jsx)(Uo,{className:`w-4 h-4 ${u?c?`text-bambu-green`:`text-bambu-gray`:`text-red-600 dark:text-red-400`}`})}),(0,Z.jsxs)(`div`,{children:[(0,Z.jsx)(`p`,{className:`text-sm text-white font-medium`,children:e.name}),(0,Z.jsx)(`div`,{className:`flex items-center gap-1 text-xs`,children:a?(0,Z.jsx)(he,{className:`w-3 h-3 text-bambu-gray animate-spin`}):f?u?(0,Z.jsxs)(Z.Fragment,{children:[(0,Z.jsx)(ws,{className:`w-3 h-3 text-teal-600 dark:text-teal-400`}),(0,Z.jsxs)(`span`,{className:`text-teal-700 dark:text-teal-400`,children:[Math.round(i?.energy?.power??0),`W`]}),(0,Z.jsx)(`span`,{className:`text-bambu-gray mx-1`,children:`|`}),(0,Z.jsx)(fo,{className:`w-3 h-3 text-bambu-gray`}),(0,Z.jsx)(`span`,{className:`text-bambu-gray`,children:`Monitor`})]}):(0,Z.jsxs)(Z.Fragment,{children:[(0,Z.jsx)(xs,{className:`w-3 h-3 text-status-error`}),(0,Z.jsx)(`span`,{className:`text-status-error`,children:`Waiting`})]}):u?(0,Z.jsxs)(Z.Fragment,{children:[(0,Z.jsx)(Ss,{className:`w-3 h-3 text-status-ok`}),(0,Z.jsx)(`span`,{className:c?`text-status-ok`:`text-bambu-gray`,children:i?.state||`Unknown`}),i?.energy?.power!==null&&i?.energy?.power!==void 0&&(0,Z.jsxs)(Z.Fragment,{children:[(0,Z.jsx)(`span`,{className:`text-bambu-gray mx-1`,children:`|`}),(0,Z.jsx)(ws,{className:`w-3 h-3 text-yellow-600 dark:text-yellow-400`}),(0,Z.jsxs)(`span`,{className:`text-yellow-700 dark:text-yellow-400`,children:[Math.round(i.energy.power),`W`]})]})]}):(0,Z.jsxs)(Z.Fragment,{children:[(0,Z.jsx)(xs,{className:`w-3 h-3 text-status-error`}),(0,Z.jsx)(`span`,{className:`text-status-error`,children:`Offline`})]})})]})]}),!f&&(0,Z.jsxs)(`div`,{className:`flex gap-1`,children:[(0,Z.jsx)(`button`,{onClick:()=>r(`on`),disabled:!u||d,className:`p-1.5 rounded transition-colors ${c?`bg-bambu-green text-white`:`bg-bambu-dark text-bambu-gray hover:text-white`} disabled:opacity-50 disabled:cursor-not-allowed`,title:`Turn On`,children:d?(0,Z.jsx)(he,{className:`w-4 h-4 animate-spin`}):(0,Z.jsx)(Ko,{className:`w-4 h-4`})}),(0,Z.jsx)(`button`,{onClick:()=>r(`off`),disabled:!u||d,className:`p-1.5 rounded transition-colors ${!c&&u?`bg-bambu-dark-tertiary text-white`:`bg-bambu-dark text-bambu-gray hover:text-white`} disabled:opacity-50 disabled:cursor-not-allowed`,title:`Turn Off`,children:d?(0,Z.jsx)(he,{className:`w-4 h-4 animate-spin`}):(0,Z.jsx)(Go,{className:`w-4 h-4`})})]})]}),n&&(0,Z.jsx)(Is,{title:`Turn ${n===`on`?`On`:`Off`} Smart Plug`,message:`Are you sure you want to turn ${n===`on`?`on`:`off`} "${e.name}"?`,confirmText:n===`on`?`Turn On`:`Turn Off`,variant:n===`off`?`warning`:`default`,onConfirm:()=>{n&&(s.mutate(n),r(null))},onCancel:()=>r(null)})]})}function Rs({onClose:e}){let{t}=v(),{data:n,isLoading:r}=z({queryKey:[`smart-plugs`],queryFn:o.getSmartPlugs}),i=n?.filter(e=>e.show_in_switchbar)||[];return(0,Z.jsxs)(`div`,{className:`absolute bottom-full left-0 mb-2 w-72 bg-bambu-dark-secondary border border-bambu-dark-tertiary rounded-xl shadow-xl z-50`,onMouseLeave:e,children:[(0,Z.jsx)(`div`,{className:`px-4 py-3 border-b border-bambu-dark-tertiary`,children:(0,Z.jsxs)(`h3`,{className:`text-sm font-semibold text-white flex items-center gap-2`,children:[(0,Z.jsx)(Uo,{className:`w-4 h-4 text-bambu-green`}),`Smart Switches`]})}),(0,Z.jsx)(`div`,{className:`p-2 max-h-80 overflow-y-auto`,children:r?(0,Z.jsx)(`div`,{className:`flex items-center justify-center py-8`,children:(0,Z.jsx)(he,{className:`w-6 h-6 text-bambu-gray animate-spin`})}):i.length===0?(0,Z.jsxs)(`div`,{className:`text-center py-6 px-4`,children:[(0,Z.jsx)(Uo,{className:`w-8 h-8 text-bambu-gray mx-auto mb-2`}),(0,Z.jsx)(`p`,{className:`text-sm text-bambu-gray`,children:t(`smartPlugs.noSwitchesInSwitchbar`)}),(0,Z.jsx)(`p`,{className:`text-xs text-bambu-gray mt-1`,children:t(`smartPlugs.enableSwitchbarHint`)})]}):(0,Z.jsx)(`div`,{className:`space-y-1`,children:i.map(e=>(0,Z.jsx)(Ls,{plug:e},e.id))})})]})}var zs=[{name:`globe`,icon:bo},{name:`link`,icon:Ao},{name:`external-link`,icon:uo},{name:`book`,icon:Ka},{name:`file-text`,icon:po},{name:`home`,icon:wo},{name:`star`,icon:ss},{name:`heart`,icon:Co},{name:`bookmark`,icon:qa},{name:`shopping-cart`,icon:is},{name:`music`,icon:zo},{name:`video`,icon:vs},{name:`image`,icon:Eo},{name:`camera`,icon:Ya},{name:`map`,icon:Po},{name:`compass`,icon:oo},{name:`coffee`,icon:ao},{name:`gift`,icon:vo},{name:`wrench`,icon:Cs},{name:`zap`,icon:ws},{name:`cloud`,icon:ro},{name:`database`,icon:so},{name:`folder`,icon:_o},{name:`mail`,icon:No},{name:`phone`,icon:Ho},{name:`user`,icon:gs},{name:`users`,icon:_s},{name:`server`,icon:ts},{name:`terminal`,icon:ds},{name:`code`,icon:io}];function Bs(e){return zs.find(t=>t.name===e)?.icon||Ao}function Vs({value:e,onChange:t}){let[n,r]=(0,W.useState)(!1);return(0,Z.jsxs)(`div`,{className:`relative`,children:[(0,Z.jsxs)(`button`,{type:`button`,onClick:()=>r(!n),className:`flex items-center gap-2 px-3 py-2 bg-bambu-dark border border-bambu-dark-tertiary rounded-lg text-white hover:border-bambu-gray focus:border-bambu-green focus:outline-none w-full`,children:[(0,Z.jsx)(Bs(e),{className:`w-5 h-5`}),(0,Z.jsx)(`span`,{className:`text-sm text-bambu-gray flex-1 text-left`,children:e})]}),n&&(0,Z.jsxs)(Z.Fragment,{children:[(0,Z.jsx)(`div`,{className:`fixed inset-0 z-40`,onClick:()=>r(!1)}),(0,Z.jsx)(`div`,{className:`absolute z-50 mt-1 w-full max-h-64 overflow-y-auto bg-bambu-dark-secondary border border-bambu-dark-tertiary rounded-lg shadow-lg`,children:(0,Z.jsx)(`div`,{className:`grid grid-cols-5 gap-1 p-2`,children:zs.map(({name:n,icon:i})=>(0,Z.jsx)(`button`,{type:`button`,onClick:()=>{t(n),r(!1)},className:`p-2 rounded-lg transition-colors flex items-center justify-center ${e===n?`bg-bambu-green text-white`:`hover:bg-bambu-dark-tertiary text-bambu-gray hover:text-white`}`,title:n,children:(0,Z.jsx)(i,{className:`w-5 h-5`})},n))})})]})]})}var Hs=1144;function Us(){let[e,t]=(0,W.useState)(()=>typeof window<`u`?window.innerWidth<Hs:!1);return(0,W.useEffect)(()=>{let e=window.matchMedia(`(max-width: ${Hs-1}px)`),n=e=>{t(e.matches)};return t(e.matches),e.addEventListener(`change`,n),()=>e.removeEventListener(`change`,n)},[]),e}var Ws={},Gs={},Ks=0,qs=new Set;function Js(e,t){let n={};for(let[t,r]of Object.entries(e)){if(!t||!r)continue;let e=t.replace(`#`,``).toLowerCase().slice(0,6);e.length===6&&(n[e]=r)}let r={};for(let[e,n]of Object.entries(t||{})){if(!e||!n)continue;let t=e.lastIndexOf(`|`);if(t<=0)continue;let i=e.slice(0,t).trim().toLowerCase(),a=e.slice(t+1).replace(`#`,``).toLowerCase().slice(0,6);i&&a.length===6&&(r[`${i}|${a}`]=n)}Ws=n,Gs=r,Ks+=1;for(let e of Array.from(qs))e()}function Ys(e){return qs.add(e),()=>{qs.delete(e)}}function Xs(){return Ks}var Zs=[`Red`,`Orange`,`Yellow`,`Green`,`Cyan`,`Blue`,`Purple`,`Pink`,`Brown`,`White`,`Light Gray`,`Gray`,`Dark Gray`,`Black`,`Clear`],Qs=new Set([`White`,`Light Gray`,`Gray`,`Dark Gray`,`Black`,`Clear`]);function $s(e){if(!e||e.length<6)return null;let t=e.replace(`#`,``),n=parseInt(t.substring(0,2),16),r=parseInt(t.substring(2,4),16),i=parseInt(t.substring(4,6),16);if(Number.isNaN(n)||Number.isNaN(r)||Number.isNaN(i))return null;let a=Math.max(n,r,i)/255,o=Math.min(n,r,i)/255,s=(a+o)/2,c=0,l=0;if(a!==o){let e=a-o;l=s>.5?e/(2-a-o):e/(a+o);let t=n/255,u=r/255,d=i/255;c=a===t?((u-d)/e+(u<d?6:0))/6:a===u?((d-t)/e+2)/6:((t-u)/e+4)/6}return{h:c*360,s:l,l:s}}function ec(e){if(!e||e.length<6)return null;let t=e.replace(`#`,``);if(t.length===8&&t.substring(6,8).toLowerCase()===`00`)return`Clear`;let n=$s(t);if(!n)return null;let{h:r,s:i,l:a}=n;return a<.15?`Black`:a>.85?`White`:i<.15?a<.4?`Dark Gray`:a>.6?`Light Gray`:`Gray`:r>=15&&r<45&&a<.45||r>=45&&r<70&&a<.4?`Brown`:r<15||r>=345?`Red`:r<45?`Orange`:r<70?`Yellow`:r<150?`Green`:r<200?`Cyan`:r<260?`Blue`:r<290?`Purple`:`Pink`}function tc(e){return ec(e)??`Unknown`}function nc(e){let t=ec(e);if(!t)return`99|0000|0000|0000`;let n=String(Zs.indexOf(t)).padStart(2,`0`),r=$s(e)??{h:0,s:0,l:0},i=e=>String(Math.round(e)).padStart(4,`0`);return Qs.has(t)?`${n}|0000|${i(1e3-r.l*1e3)}|${i(r.s*1e3)}`:`${n}|${i(r.h*10)}|${i(r.s*1e3)}|${i(r.l*1e3)}`}function rc(e,t){if(!e)return tc(e);let n=e.replace(`#`,``).toLowerCase();if(n.length===8&&n.substring(6,8)===`00`)return`Clear`;let r=n.substring(0,6);if(t){let e=Gs[`${t.trim().toLowerCase()}|${r}`];if(e)return e}return Ws[r]||tc(e)}function ic(e,t){let n=e=>{let t=(e??``).replace(`#`,``).trim().slice(0,6).toUpperCase();return/^[0-9A-F]{6}$/.test(t)?`#${t}`:``},r=(e.name??``).trim(),i=(t.name??``).trim(),a=n(e.hex),o=n(t.hex);return!r||!i?[r||a,i||o]:r.toLowerCase()!==i.toLowerCase()||!a&&!o?[r,i]:[a?`${r} (${a})`:r,o?`${i} (${o})`:i]}function ac(e,t,n=!1){let r=e&&!/^[A-Z]\d+-[A-Z]\d+$/.test(e)?e:null;if(r&&!n)return r;if(t&&t.length>=6){let e=t.replace(`#`,``).toLowerCase();if(e.length===8&&e.substring(6,8)===`00`)return`Clear`;let n=e.substring(0,6),r=Ws[n];if(r)return r}return r||null}function oc(e){if(!e)return`#808080`;let t=e.replace(/^#/,``);return t.length<6?`#808080`:t.length>=8&&t.substring(6,8).toLowerCase()!==`ff`?`#${t.substring(0,8)}`:`#${t.substring(0,6)}`}var sc=`repeating-conic-gradient(#979797 0% 25%, #f5f5f5 0% 50%)`;function cc(e){if(!e)return{backgroundColor:`#808080`};let t=e.replace(/^#/,``);if(t.length<6)return{backgroundColor:`#808080`};if(t.length>=8){let e=t.substring(6,8).toLowerCase();if(e===`00`)return{backgroundImage:sc,backgroundSize:`8px 8px`};if(e!==`ff`){let e=`#${t.substring(0,8)}`;return{backgroundImage:`linear-gradient(${e}, ${e}), ${sc}`,backgroundSize:`100% 100%, 8px 8px`}}}return{backgroundColor:`#${t.substring(0,6)}`}}function lc(e){if(!e||e===`00000000`||e.length<6)return null;let t=e.slice(0,2),n=e.slice(2,4),r=e.slice(4,6),i=e.length>=8?parseInt(e.slice(6,8),16)/255:1;return i===0?null:`rgba(${parseInt(t,16)}, ${parseInt(n,16)}, ${parseInt(r,16)}, ${i})`}function uc(e){if(!e||e.length<6)return!1;let t=e.replace(`#`,``);if(t.length===8&&t.slice(6,8).toLowerCase()===`00`)return!0;let n=parseInt(t.slice(0,2),16),r=parseInt(t.slice(2,4),16),i=parseInt(t.slice(4,6),16);return(.299*n+.587*r+.114*i)/255>.6}function dc(){return(0,W.useSyncExternalStore)(Ys,Xs,Xs)}var fc={USD:`$`,EUR:`€`,GBP:`£`,CHF:`Fr.`,JPY:`¥`,CNY:`¥`,CAD:`$`,AUD:`$`,INR:`₹`,HKD:`HK$`,KRW:`₩`,SEK:`kr`,NOK:`kr`,DKK:`kr`,PLN:`zł`,BRL:`R$`,TWD:`NT$`,SGD:`S$`,NZD:`NZ$`,MXN:`MX$`,BZD:`BZ$`,MYR:`RM`,CZK:`Kč`,THB:`฿`,ZAR:`R`,TRY:`₺`,RUB:`₽`,HUF:`Ft`,ILS:`₪`,UAH:`₴`,IDR:`Rp`,PHP:`₱`};function pc(e){return fc[e.toUpperCase()]||e}var mc=Object.entries(fc).map(([e,t])=>({code:e,label:`${e} (${t})`}));function hc(e){return e>=5?`business`:`personal`}function gc(e,t){return`https://bambuddy.cool/${e===`business`?`business.html`:`sponsors.html`}?from=${t}`}var _c=`sponsor-prompt`,vc=`sponsorPromptShown`;function yc(e,t=0){return typeof e==`number`?e:t}function bc(e,t=``){return typeof e==`string`?e:t}function xc(e,t,n,r,i){if(r===`business`)return e(`sponsors.toastBusiness`,{count:i});let a=t.family,o=t.payload??{},s=t.threshold??0;switch(a){case`prints`:return e(`sponsors.toastPrints`,{count:yc(o.count,s)});case`archives`:return e(`sponsors.toastArchives`,{count:yc(o.count,s)});case`cost`:{let t=yc(o.total,s);return e(`sponsors.toastCost`,{total:`${pc(n)}${t}`})}case`anniversary`:return e(`sponsors.toastAnniversary`);case`version-update`:return e(`sponsors.toastVersionUpdate`,{version:bc(o.to)});default:return null}}function Sc(e=`EUR`){let{t}=v(),{loading:n}=Os(),{showPersistentToast:r}=fe(),i=(0,W.useRef)(!1),{data:s,isPending:c}=z({queryKey:[`printers`],queryFn:o.getPrinters,retry:!1});(0,W.useEffect)(()=>{if(n||c||i.current)return;if(sessionStorage.getItem(vc)){i.current=!0;return}i.current=!0,sessionStorage.setItem(vc,`1`);let o=s?.length??0,l=hc(o);(async()=>{try{let n=await a.check();if(!n.show||!n.milestone)return;let i=xc(t,n,e,l,o);if(!i)return;r(_c,i,`info`,{action:{label:l===`business`?t(`sponsors.businessCta`,`Bambuddy for business`):t(`sponsors.viewSupporters`,`View supporters`),href:gc(l,`app-toast-${n.milestone}`)}}),a.dismiss(n.milestone)}catch{}})()},[n,c,s,t,r,e])}function Cc(e){if(!e)return`#808080`;let t=e.replace(`#`,``);return t.length>=8&&t.substring(6,8).toLowerCase()!==`ff`?`#${t.substring(0,8)}`:`#${t.substring(0,6)}`}function wc(e){return e?e.replace(`#`,``).toLowerCase().substring(0,6):``}var Tc={A:`L`,B:`R`},Ec={A:1,B:0};function Dc(e,t,n,r){if(e===255)return t===0||t===1?1-t:void 0;let i=n?.[String(e)];if(i!==void 0)return i;let a=r?.[String(e)];return a?Ec[a.toUpperCase()]:void 0}function Oc(e,t){let n=typeof e==`string`?parseInt(e,10):e,r=isNaN(n)?0:n;if(r===255)return`External`;if(r===6)return`AMS Lite`;let i=t===1,a=r>=128?r-128:r,o=String.fromCharCode(65+a);return i?`HT-${o}`:`AMS-${o}`}var kc=[[`PA-CF`,`PA12-CF`,`PAHT-CF`]],Ac={};for(let e of kc){let t=e[0];for(let n of e)Ac[n.toUpperCase()]=t.toUpperCase()}function jc(e){if(!e)return``;let t=e.toUpperCase();return Ac[t]??t}function Mc(e,t){return jc(e)===jc(t)}function Nc(e,t,n=40){let r=wc(e),i=wc(t);if(!r||!i||r.length<6||i.length<6)return!1;let a=parseInt(r.substring(0,2),16),o=parseInt(r.substring(2,4),16),s=parseInt(r.substring(4,6),16),c=parseInt(i.substring(0,2),16),l=parseInt(i.substring(2,4),16),u=parseInt(i.substring(4,6),16);return Math.abs(a-c)<=n&&Math.abs(o-l)<=n&&Math.abs(s-u)<=n}var Pc=[.95047,1,1.08883],Fc=6/29;function Ic(e){let t=wc(e);if(!t||t.length<6)return null;let n=[0,2,4].map(e=>parseInt(t.substring(e,e+2),16)/255);if(n.some(Number.isNaN))return null;let[r,i,a]=n.map(e=>e<=.04045?e/12.92:((e+.055)/1.055)**2.4),o=[.4124564*r+.3575761*i+.1804375*a,.2126729*r+.7151522*i+.072175*a,.0193339*r+.119192*i+.9503041*a],s=e=>e>Fc**3?Math.cbrt(e):e/(3*Fc*Fc)+4/29,[c,l,u]=o.map((e,t)=>s(e/Pc[t]));return[116*l-16,500*(c-l),200*(l-u)]}function Lc(e,t){let[n,r,i]=e,[a,o,s]=t,c=e=>e*Math.PI/180,l=((Math.hypot(r,i)+Math.hypot(o,s))/2)**7,u=.5*(1-Math.sqrt(l/(l+25**7))),d=(1+u)*r,f=(1+u)*o,p=Math.hypot(d,i),m=Math.hypot(f,s),h=(e,t)=>{if(e===0&&t===0)return 0;let n=Math.atan2(t,e)*180/Math.PI;return n<0?n+360:n},g=h(d,i),_=h(f,s),v=a-n,y=m-p,b=p*m,x=0;b!==0&&(x=_-g,x>180?x-=360:x<-180&&(x+=360));let S=2*Math.sqrt(b)*Math.sin(c(x)/2),C=(n+a)/2,w=(p+m)/2,T;T=b===0?g+_:Math.abs(g-_)<=180?(g+_)/2:g+_<360?(g+_+360)/2:(g+_-360)/2;let E=1-.17*Math.cos(c(T-30))+.24*Math.cos(c(2*T))+.32*Math.cos(c(3*T+6))-.2*Math.cos(c(4*T-63)),D=w**7,O=2*Math.sqrt(D/(D+25**7)),k=1+.015*(C-50)**2/Math.sqrt(20+(C-50)**2),A=1+.045*w,j=1+.015*w*E,M=-Math.sin(c(2*(30*Math.exp(-(((T-275)/25)**2)))))*O,N=v/k,P=y/A,F=S/j;return Math.sqrt(N*N+P*P+F*F+M*P*F)}function Rc(e,t){let n=Ic(e),r=Ic(t);return!n||!r?null:Lc(n,r)}function zc(e,t,n){let r,i=1/0;for(let a of e){let e=n(a);if(!Nc(e,t))continue;let o=Rc(e,t);o!==null&&o<i&&(r=a,i=o)}return r}function Bc(e){return e?.tray_type?null:e?.exists===!0?`reset`:e?.exists===!1||e?.state===9||e?.state===10?`physical`:`reset`}function Vc(e,t,n,r){if(r)return`Ext`;let i=String.fromCharCode(65+(e>=128?e-128:e));return n?`HT-${i}`:`${i}${t+1}`}function Hc(e,t,n){return n?254+t:e>=128?e:e*4+t}function Uc(e){return e>50?`#00ae42`:e>=15?`#f59e0b`:`#ef4444`}function Wc(e){return!e?.remaining_weight||!e?.filament_weight||e.filament_weight<=0?null:Math.min(100,Math.round(e.remaining_weight/e.filament_weight*100))}function Gc(e,t){return(Number.isFinite(e)?Math.max(0,Math.trunc(e)):0).toString(16).toUpperCase().padStart(t,`0`).slice(-t)}function Kc(e){let t=(e||``).trim().toUpperCase(),n=2166136261;for(let e=0;e<t.length;e++)n^=t.charCodeAt(e),n=Math.imul(n,16777619);return(n>>>0).toString(16).toUpperCase().padStart(8,`0`)}function qc(e,t,n){return`${Kc(e)}${Gc(t,4)}${Gc(n,4)}`}function Jc(e){if(!e)return!1;let t=Date.now()+4320*60*60*1e3;return(je(e)?.getTime()??0)>t}function Yc(e,t){return e==null||e<0?1e4:e>=128?1e3+(e-128)*4+(t??0):e*4+(t??0)}function Xc(e,t){let n=Yc(e.amsId,e.trayId);if(t&&t.has(e.globalTrayId))return[0,t.get(e.globalTrayId)??0,n];let r=e.remain??-1;return[1,r>=0?r:101,n]}function Zc(e,t){return e[0]-t[0]||e[1]-t[1]||e[2]-t[2]}function Qc(e,t){return e?t!==!1:!1}function $c(e,t,n,r,i){let a=el(t,e.nozzle_id);r&&(a=[...a].sort((e,t)=>Zc(Xc(e,i),Xc(t,i))));let o=a.find(t=>!n.has(t.globalTrayId)&&Mc(t.type,e.type)&&wc(t.color)===wc(e.color)),s=o?void 0:zc(a.filter(t=>!n.has(t.globalTrayId)&&Mc(t.type,e.type)),e.color,e=>e.color),c=o||s?void 0:a.find(t=>!n.has(t.globalTrayId)&&Mc(t.type,e.type));return o??s??c}function el(e,t){return e.filter(e=>t==null||e.extruderId===t)}function tl(e){let t=new Set,n=[];for(let r of e?.nozzles??[]){let e=(r?.nozzle_diameter??``).trim();!e||!(parseFloat(e)>0)||t.has(e)||(t.add(e),n.push(e))}return n}function nl(e,t){let n=e?.nozzles;if(!(!n||n.length===0))return n[e?.ams_extruder_map?.[String(t)]??0]?.nozzle_diameter||n[0]?.nozzle_diameter||void 0}function rl(e){return e?!!(e.tray_uuid&&e.tray_uuid!==`00000000000000000000000000000000`||e.tag_uid&&e.tag_uid!==`0000000000000000`):!1}function il(e,t,n){let r=(e||``).split(`_`)[0].toUpperCase(),i=(t||``).split(`_`)[0].toUpperCase(),a=(n||``).split(`_`)[0].toUpperCase();return a&&i?a===i:!r.startsWith(`GFS`)||!i.startsWith(`GF`)||i.startsWith(`GFS`)?!0:`GF${r.slice(3)}`===i}function al(e){let t=(e||``).trim().replace(/^#/,``).toUpperCase();return t.length===8&&(t=t.slice(0,6)),t}function ol(e,t,n){if(!e||e.length===0)return[];let r=new Set,i=[];for(let t of e)r.has(t.id)||(r.add(t.id),i.push(t));let a=new Map;for(let e of i){let r=n?Number(t?.[String(e.id)]??0):0;e.tray.forEach((t,n)=>{if(!t?.tray_type)return;let i=(t.tray_info_idx||``).trim(),o=Hc(e.id,n,!1),s={amsId:e.id,slotIdx:n,globalTrayId:o},c,l;i?(c=`preset:${i}|color:${al(t.tray_color)}#${r}`,l=i):(c=`unmatched:${e.id}:${n}#${r}`,l=null);let u=a.get(c);u?u.members.push(s):a.set(c,{key:c,presetId:l,extruder:r,displayName:t.tray_sub_brands||t.tray_type||``,trayColor:t.tray_color??null,members:[s]})})}return Array.from(a.values()).sort((e,t)=>{if(e.extruder!==t.extruder)return e.extruder-t.extruder;let n=+(e.members.length===1),r=+(t.members.length===1);return n===r?e.displayName===t.displayName?e.members[0].globalTrayId-t.members[0].globalTrayId:e.displayName.localeCompare(t.displayName):n-r})}function sl(e,t,n){return`${e}|${t}|${n}`}function cl(){let{t:e}=v(),t=F(),{showToast:n}=fe(),{user:r,authEnabled:i}=Os(),[a,s]=(0,W.useState)([]),c=!i||!!r,l=(0,W.useCallback)(n=>{if(!n.tray_type)return null;let r=t.getQueryData([`printers`])?.find(e=>e.id===n.printer_id),i=n.tray_count??4;return{printer_id:n.printer_id,ams_id:n.ams_id,tray_id:n.tray_id,printer_name:r?.name??`Printer ${n.printer_id}`,ams_label:Oc(n.ams_id,i),slot_label:`${e(`inventory.unknownSpoolSlot`,`Slot`)} ${n.tray_id+1}`,material:n.tray_type??null,color_hex:n.tray_color??null,brand:n.tray_sub_brands??null}},[t,e]);(0,W.useEffect)(()=>{if(!c)return;let e=e=>{let t=e.detail;if(!t)return;let n=l(t);n&&s(e=>{let t=sl(n.printer_id,n.ams_id,n.tray_id);return e.some(e=>sl(e.printer_id,e.ams_id,e.tray_id)===t)?e:[...e,n]})};return window.addEventListener(`unknown-tag`,e),()=>window.removeEventListener(`unknown-tag`,e)},[c,l]);let u=a[0]??null,d=ie({mutationFn:async e=>{t.getQueryData([`settings`])?.spoolman_enabled?await o.createSpoolmanSpoolFromSlot({printer_id:e.printer_id,ams_id:e.ams_id,tray_id:e.tray_id}):await o.createSpoolFromSlot({printer_id:e.printer_id,ams_id:e.ams_id,tray_id:e.tray_id})},onSuccess:()=>{n(e(`inventory.addToInventorySuccess`),`success`),t.invalidateQueries({queryKey:[`inventory-spools`]}),t.invalidateQueries({queryKey:[`spool-assignments`]}),t.invalidateQueries({queryKey:[`spoolman-inventory-spools`]}),t.invalidateQueries({queryKey:[`spoolman-slot-assignments`]}),t.invalidateQueries({queryKey:[`linked-spools`]}),s(e=>e.slice(1))},onError:t=>{n(t.message||e(`inventory.addToInventoryFailed`),`error`)}}),f=(0,W.useCallback)(()=>{!u||d.isPending||d.mutate(u)},[u,d]),p=(0,W.useCallback)(()=>{u&&s(e=>e.slice(1))},[u]);return(0,W.useMemo)(()=>({prompt:u,isPending:d.isPending,confirm:f,cancel:p}),[u,d.isPending,f,p])}function ll({prompt:e,isPending:t,onConfirm:n,onCancel:r}){let{t:i}=v();if(!e)return null;let a=`${e.printer_name} • ${e.ams_label} • ${e.slot_label}`,o=e.color_hex?cc(e.color_hex):void 0;return(0,Z.jsx)(Is,{title:i(`inventory.unknownSpoolTitle`),message:i(`inventory.unknownSpoolMessage`,{location:a}),confirmText:i(`inventory.addToInventory`),cancelText:i(`common.cancel`),variant:`default`,isLoading:t,loadingText:i(`inventory.addToInventoryPending`),onConfirm:n,onCancel:r,children:(0,Z.jsxs)(`div`,{className:`flex items-center gap-3 p-3 rounded-lg bg-bambu-dark-secondary border border-bambu-dark-tertiary`,children:[o&&(0,Z.jsx)(`div`,{className:`w-8 h-8 rounded-full border border-black/20 flex-shrink-0`,style:o,"aria-label":e.color_hex??void 0}),(0,Z.jsxs)(`div`,{className:`min-w-0 flex-1`,children:[(0,Z.jsx)(`p`,{className:`text-white text-sm font-medium truncate`,children:e.brand?`${e.brand} ${e.material??``}`.trim():e.material??`—`}),e.color_hex&&(0,Z.jsxs)(`p`,{className:`text-xs text-bambu-gray font-mono uppercase`,children:[`#`,e.color_hex.replace(/^#/,``).slice(0,6)]})]})]})})}function ul(e){if(!e||e<=0)return`—`;let t=Math.floor(e/3600),n=Math.floor(e%3600/60);return t>0?`${t}h ${n}m`:`${n}m`}function dl(e){if(!e)return`—`;let t=je(e);return t?t.toLocaleString():`—`}function fl({archiveId:e}){let{t}=v(),{data:n,isLoading:r}=z({queryKey:[`archive-runs`,e],queryFn:()=>o.getArchiveRuns(e)});if(r)return(0,Z.jsx)(`div`,{className:`flex justify-center py-4`,children:(0,Z.jsx)(he,{className:`w-5 h-5 text-bambu-gray animate-spin`})});let i=n?.items||[];return i.length===0?(0,Z.jsx)(`p`,{className:`text-sm text-bambu-gray italic py-2`,children:t(`archives.runLog.empty`)}):(0,Z.jsx)(`div`,{className:`overflow-x-auto`,children:(0,Z.jsxs)(`table`,{className:`w-full text-xs`,children:[(0,Z.jsx)(`thead`,{children:(0,Z.jsxs)(`tr`,{className:`text-bambu-gray border-b border-bambu-dark-tertiary`,children:[(0,Z.jsx)(`th`,{className:`text-left py-1.5 pr-2 font-medium`,children:t(`archives.runLog.col.date`)}),(0,Z.jsx)(`th`,{className:`text-left py-1.5 pr-2 font-medium`,children:t(`archives.runLog.col.status`)}),(0,Z.jsx)(`th`,{className:`text-right py-1.5 pr-2 font-medium`,children:t(`archives.runLog.col.duration`)}),(0,Z.jsx)(`th`,{className:`text-right py-1.5 pr-2 font-medium`,children:t(`archives.runLog.col.filament`)}),(0,Z.jsx)(`th`,{className:`text-right py-1.5 font-medium`,children:t(`archives.runLog.col.cost`)})]})}),(0,Z.jsx)(`tbody`,{children:i.map(e=>{let n=e.status===`completed`?`text-bambu-green`:e.status===`failed`?`text-red-700 dark:text-red-400`:`text-bambu-gray`;return(0,Z.jsxs)(`tr`,{className:`border-b border-bambu-dark-tertiary/40 last:border-0`,children:[(0,Z.jsx)(`td`,{className:`py-1.5 pr-2 text-bambu-gray-light`,children:dl(e.started_at||e.created_at)}),(0,Z.jsxs)(`td`,{className:`py-1.5 pr-2 font-medium ${n}`,children:[t(`archives.runLog.status.${e.status}`,{defaultValue:e.status}),e.failure_reason&&(0,Z.jsx)(`span`,{className:`block text-[10px] text-bambu-gray font-normal`,children:t(`editArchive.failureReasons.${e.failure_reason}`,{defaultValue:e.failure_reason})})]}),(0,Z.jsx)(`td`,{className:`py-1.5 pr-2 text-right text-bambu-gray-light`,children:ul(e.duration_seconds)}),(0,Z.jsx)(`td`,{className:`py-1.5 pr-2 text-right text-bambu-gray-light`,children:e.filament_used_grams==null?`—`:`${e.filament_used_grams.toFixed(1)} g`}),(0,Z.jsx)(`td`,{className:`py-1.5 text-right text-bambu-gray-light`,children:e.cost==null?`—`:e.cost.toFixed(2)})]},e.id)})})]})})}var pl=[[`projects`],[`project`],[`project-archives`],[`project-timeline`],[`project-file-progress`]];function ml(e){return Promise.all(pl.map(t=>e.invalidateQueries({queryKey:[...t]})))}function hl(e){return Promise.all([e.invalidateQueries({queryKey:[`archives`]}),ml(e)])}function gl(e,t){if(t===void 0)return e;let n=new Set([t]),r=!0;for(;r;){r=!1;for(let t of e)t.parent_id!==null&&n.has(t.parent_id)&&!n.has(t.id)&&(n.add(t.id),r=!0)}return e.filter(e=>!n.has(e.id))}function _l(e,t){return e.filter(e=>e.status!==`archived`||e.id===t)}var vl={dialog:`confirmOutcome.sources.dialog`,link:`confirmOutcome.sources.link`,plate_clear:`confirmOutcome.sources.plateClear`,printer_card:`confirmOutcome.sources.printerCard`,api:`confirmOutcome.sources.api`,reaction:`confirmOutcome.sources.reaction`};function yl(e){return e?vl[e]??null:null}function bl({value:e,onChange:t,min:n,max:r,integer:i=!0,fallback:a,onBlur:o,...s}){let[c,l]=(0,W.useState)(null),u=e=>i?parseInt(e,10):parseFloat(e),d=e=>(n===void 0||e>=n)&&(r===void 0||e<=r),f=e=>Math.min(r??1/0,Math.max(n??-1/0,e));return(0,Z.jsx)(`input`,{...s,type:`number`,min:n,max:r,value:c??e??``,onChange:n=>{let r=n.target.value;l(r);let i=u(r);!Number.isNaN(i)&&d(i)&&i!==e&&t(i)},onBlur:n=>{if(c!==null){let n=u(c),r=Number.isNaN(n)?a:n;r!==void 0&&f(r)!==e&&t(f(r)),l(null)}o?.(n)}})}var xl=[`adhesionFailure`,`spaghettiDetached`,`layerShift`,`cloggedNozzle`,`filamentRunout`,`warping`,`stringing`,`underExtrusion`,`powerFailure`,`userCancelled`,`noStatusUpdate`,`other`],Sl=[`completed`,`failed`,`aborted`,`printing`],Cl=1e5;function wl({archive:e,onClose:t,existingTags:n=[]}){let{t:r}=v();(0,W.useEffect)(()=>{let e=e=>{e.key===`Escape`&&t()};return window.addEventListener(`keydown`,e),()=>window.removeEventListener(`keydown`,e)},[t]);let i=F(),[a,s]=(0,W.useState)(e.print_name||``),[c,l]=(0,W.useState)(e.printer_id),[u,d]=(0,W.useState)(e.project_id??null),[f,p]=(0,W.useState)(e.notes||``),[m,h]=(0,W.useState)(e.tags||``),[g,_]=(0,W.useState)(()=>{let t=e.failure_reason||``;return t?xl.includes(t)?t:xl.find(e=>r(`editArchive.failureReasons.${e}`)===t)||t:``}),y=g&&!xl.includes(g)?g:null,[b,x]=(0,W.useState)(e.status),[S,C]=(0,W.useState)(e.user_verdict??``),w=yl(e.user_verdict_source),[T,E]=(0,W.useState)(e.quantity??1),[D,O]=(0,W.useState)(e.filament_used_grams==null?``:String(e.filament_used_grams)),[k,A]=(0,W.useState)(e.photos||[]),[j,M]=(0,W.useState)(e.external_url||``),[N,P]=(0,W.useState)(!1),[I,ee]=(0,W.useState)(!1),te=(0,W.useRef)(null),ne=(0,W.useRef)(null),L=(0,W.useRef)(null),{data:R}=z({queryKey:[`printers`],queryFn:o.getPrinters}),{data:re}=z({queryKey:[`projects`],queryFn:()=>o.getProjects(),select:e=>[...e].sort((e,t)=>e.name.localeCompare(t.name))}),B=(0,W.useMemo)(()=>_l(re??[],e.project_id),[re,e.project_id]),{data:V}=z({queryKey:[`tags`],queryFn:o.getTags,enabled:n.length===0}),ae=n.length>0?n:V?.map(e=>e.name)||[],oe=m.split(`,`).map(e=>e.trim()).filter(Boolean),se=m.includes(`,`)?m.substring(m.lastIndexOf(`,`)+1).trim().toLowerCase():m.trim().toLowerCase(),ce=ae.filter(e=>!oe.includes(e)&&(se===``||e.toLowerCase().includes(se))),le=e=>{let t;t=se&&!ae.includes(se)?m.includes(`,`)?m.substring(0,m.lastIndexOf(`,`)).split(`,`).map(e=>e.trim()).filter(Boolean):[]:oe,t.includes(e)||h([...t,e].join(`, `)),L.current!==null&&clearTimeout(L.current),te.current?.focus()},H=e=>{h(oe.filter(t=>t!==e).join(`, `))},ue=ie({mutationFn:t=>o.updateArchive(e.id,t),onSuccess:()=>{hl(i),i.invalidateQueries({queryKey:[`archive-runs`,e.id]}),t()}}),de=async t=>{let n=t.target.files?.[0];if(n){P(!0);try{A((await o.uploadArchivePhoto(e.id,n)).photos),i.invalidateQueries({queryKey:[`archives`]})}catch(e){console.error(`Failed to upload photo:`,e)}finally{P(!1),ne.current&&(ne.current.value=``)}}},U=async t=>{try{A((await o.deleteArchivePhoto(e.id,t)).photos||[]),i.invalidateQueries({queryKey:[`archives`]})}catch(e){console.error(`Failed to delete photo:`,e)}};return(0,Z.jsx)(`div`,{className:`fixed inset-0 bg-black/70 flex items-center justify-center z-50 p-4`,onClick:t,children:(0,Z.jsxs)(`div`,{className:`bg-bambu-dark-secondary rounded-xl border border-bambu-dark-tertiary w-full max-w-md max-h-[90vh] flex flex-col`,onClick:e=>e.stopPropagation(),children:[(0,Z.jsxs)(`div`,{className:`flex items-center justify-between px-6 py-4 border-b border-bambu-dark-tertiary`,children:[(0,Z.jsx)(`h2`,{className:`text-lg font-semibold text-white`,children:r(`editArchive.title`)}),(0,Z.jsx)(`button`,{onClick:t,className:`text-bambu-gray hover:text-white transition-colors`,children:(0,Z.jsx)(_e,{className:`w-5 h-5`})})]}),(0,Z.jsxs)(`form`,{onSubmit:t=>{t.preventDefault();let n={print_name:a||void 0,printer_id:c,project_id:u,notes:f||void 0,tags:m||void 0,quantity:T,external_url:j||null};b!==e.status&&(n.status=b),S!==(e.user_verdict??``)&&(n.user_verdict=S===``?null:S,n.user_verdict_source=`dialog`);let r=D.trim(),i=r===``?null:Number(r),o=i!==null&&!Number.isFinite(i),s=i===null?null:Math.min(Math.max(i,0),Cl),l=e.filament_used_grams??null;!o&&s!==l&&(n.filament_used_grams=s),b===`failed`||b===`aborted`||b===`completed`&&S===`reject`?n.failure_reason=g||void 0:(e.status===`failed`||e.status===`aborted`||e.user_verdict===`reject`)&&(n.failure_reason=null),ue.mutate(n)},className:`p-6 space-y-4 overflow-y-auto flex-1`,children:[(0,Z.jsxs)(`div`,{children:[(0,Z.jsx)(`label`,{className:`block text-sm text-bambu-gray mb-1`,children:r(`archives.runLog.title`)}),(0,Z.jsx)(fl,{archiveId:e.id})]}),(0,Z.jsxs)(`div`,{children:[(0,Z.jsx)(`label`,{className:`block text-sm text-bambu-gray mb-1`,children:r(`editArchive.name`)}),(0,Z.jsx)(`input`,{type:`text`,value:a,onChange:e=>s(e.target.value),className:`w-full px-3 py-2 bg-bambu-dark border border-bambu-dark-tertiary rounded-lg text-white focus:border-bambu-green focus:outline-none`,placeholder:r(`editArchive.namePlaceholder`)})]}),(0,Z.jsxs)(`div`,{children:[(0,Z.jsx)(`label`,{className:`block text-sm text-bambu-gray mb-1`,children:r(`editArchive.printer`)}),(0,Z.jsxs)(`select`,{value:c??``,onChange:e=>l(e.target.value?Number(e.target.value):null),className:`w-full px-3 py-2 bg-bambu-dark border border-bambu-dark-tertiary rounded-lg text-white focus:border-bambu-green focus:outline-none`,children:[(0,Z.jsx)(`option`,{value:``,children:r(`editArchive.noPrinter`)}),R?.map(e=>(0,Z.jsx)(`option`,{value:e.id,children:e.name},e.id))]})]}),(0,Z.jsxs)(`div`,{children:[(0,Z.jsxs)(`label`,{className:`block text-sm text-bambu-gray mb-1`,children:[(0,Z.jsx)(ho,{className:`w-4 h-4 inline mr-1`}),r(`editArchive.project`)]}),(0,Z.jsxs)(`select`,{value:u??``,onChange:e=>d(e.target.value?Number(e.target.value):null),className:`w-full px-3 py-2 bg-bambu-dark border border-bambu-dark-tertiary rounded-lg text-white focus:border-bambu-green focus:outline-none`,children:[(0,Z.jsx)(`option`,{value:``,children:r(`editArchive.noProject`)}),B.map(e=>(0,Z.jsx)(`option`,{value:e.id,children:e.name},e.id))]})]}),(0,Z.jsxs)(`div`,{children:[(0,Z.jsxs)(`label`,{className:`block text-sm text-bambu-gray mb-1`,htmlFor:`archive-items-printed`,children:[(0,Z.jsx)(So,{className:`w-4 h-4 inline mr-1`}),r(`editArchive.itemsPrinted`)]}),(0,Z.jsx)(bl,{id:`archive-items-printed`,min:0,value:T,onChange:E,fallback:0,className:`w-full px-3 py-2 bg-bambu-dark border border-bambu-dark-tertiary rounded-lg text-white focus:border-bambu-green focus:outline-none`,placeholder:`1`}),(0,Z.jsx)(`p`,{className:`text-xs text-bambu-gray mt-1`,children:r(`editArchive.itemsPrintedHelp`)})]}),(0,Z.jsxs)(`div`,{children:[(0,Z.jsxs)(`label`,{className:`block text-sm text-bambu-gray mb-1`,htmlFor:`archive-filament-grams`,children:[(0,Z.jsx)(bs,{className:`w-4 h-4 inline mr-1`}),r(`editArchive.filamentUsed`)]}),(0,Z.jsx)(`input`,{id:`archive-filament-grams`,type:`text`,inputMode:`decimal`,value:D,onChange:e=>{let t=e.target.value.replace(`,`,`.`);(t===``||/^\d*\.?\d*$/.test(t))&&O(t)},onBlur:()=>O(e=>{let t=Number(e);return e===``||!Number.isFinite(t)?``:String(Math.min(t,Cl))}),className:`w-full px-3 py-2 bg-bambu-dark border border-bambu-dark-tertiary rounded-lg text-white focus:border-bambu-green focus:outline-none`,placeholder:r(`editArchive.filamentUsedPlaceholder`)}),(0,Z.jsx)(`p`,{className:`text-xs text-bambu-gray mt-1`,children:r(`editArchive.filamentUsedHelp`)})]}),(0,Z.jsxs)(`div`,{children:[(0,Z.jsx)(`label`,{className:`block text-sm text-bambu-gray mb-1`,children:r(`editArchive.notes`)}),(0,Z.jsx)(`textarea`,{value:f,onChange:e=>p(e.target.value),rows:3,className:`w-full px-3 py-2 bg-bambu-dark border border-bambu-dark-tertiary rounded-lg text-white focus:border-bambu-green focus:outline-none resize-none`,placeholder:r(`editArchive.notesPlaceholder`)})]}),(0,Z.jsxs)(`div`,{children:[(0,Z.jsxs)(`label`,{className:`block text-sm text-bambu-gray mb-1`,children:[(0,Z.jsx)(Ao,{className:`w-4 h-4 inline mr-1`}),r(`editArchive.externalLink`)]}),(0,Z.jsx)(`input`,{type:`url`,value:j,onChange:e=>M(e.target.value),className:`w-full px-3 py-2 bg-bambu-dark border border-bambu-dark-tertiary rounded-lg text-white focus:border-bambu-green focus:outline-none`,placeholder:`https://printables.com/model/...`}),(0,Z.jsx)(`p`,{className:`text-xs text-bambu-gray mt-1`,children:r(`editArchive.externalLinkHelp`)})]}),(0,Z.jsxs)(`div`,{children:[(0,Z.jsx)(`label`,{className:`block text-sm text-bambu-gray mb-1`,children:r(`editArchive.tags`)}),oe.length>0&&(0,Z.jsx)(`div`,{className:`flex flex-wrap gap-1.5 mb-2`,children:oe.map(e=>(0,Z.jsxs)(`span`,{className:`inline-flex items-center gap-1 px-2 py-0.5 bg-bambu-dark-tertiary rounded text-sm text-white`,children:[(0,Z.jsx)(us,{className:`w-3 h-3`}),e,(0,Z.jsx)(`button`,{type:`button`,onClick:()=>H(e),className:`ml-0.5 text-bambu-gray hover:text-white`,children:(0,Z.jsx)(_e,{className:`w-3 h-3`})})]},e))}),(0,Z.jsxs)(`div`,{className:`relative`,children:[(0,Z.jsx)(`input`,{ref:te,type:`text`,value:m,onChange:e=>h(e.target.value),onFocus:()=>{L.current!==null&&clearTimeout(L.current),ee(!0)},onBlur:()=>{L.current=window.setTimeout(()=>ee(!1),200)},className:`w-full px-3 py-2 bg-bambu-dark border border-bambu-dark-tertiary rounded-lg text-white focus:border-bambu-green focus:outline-none`,placeholder:oe.length>0?r(`editArchive.addMoreTags`):r(`editArchive.tagsPlaceholder`)}),I&&ce.length>0&&(0,Z.jsxs)(`div`,{className:`absolute top-full left-0 right-0 mt-1 bg-bambu-dark-secondary border border-bambu-dark-tertiary rounded-lg shadow-lg z-10 max-h-40 overflow-y-auto`,children:[(0,Z.jsxs)(`div`,{className:`p-2 text-xs text-bambu-gray border-b border-bambu-dark-tertiary`,children:[se?r(`editArchive.matchingTags`,{query:se}):r(`editArchive.existingTags`),` `,r(`editArchive.clickToAdd`)]}),(0,Z.jsx)(`div`,{className:`p-2 flex flex-wrap gap-1.5`,children:ce.map(e=>(0,Z.jsx)(`button`,{type:`button`,onClick:()=>le(e),className:`px-2 py-0.5 bg-bambu-dark-tertiary hover:bg-bambu-green/20 rounded text-sm text-bambu-gray hover:text-white transition-colors`,children:e},e))})]})]})]}),(0,Z.jsxs)(`div`,{children:[(0,Z.jsx)(`label`,{className:`block text-sm text-bambu-gray mb-1`,children:r(`editArchive.status`)}),(0,Z.jsx)(`select`,{value:b,onChange:e=>{x(e.target.value),e.target.value===`completed`&&_(``)},className:`w-full px-3 py-2 bg-bambu-dark border border-bambu-dark-tertiary rounded-lg text-white focus:border-bambu-green focus:outline-none`,children:Sl.map(e=>(0,Z.jsx)(`option`,{value:e,children:r(`editArchive.statuses.${e}`)},e))})]}),b===`completed`&&(0,Z.jsxs)(`div`,{children:[(0,Z.jsx)(`label`,{htmlFor:`user-verdict-select`,className:`block text-sm text-bambu-gray mb-1`,children:r(`editArchive.userVerdict`)}),(0,Z.jsxs)(`select`,{id:`user-verdict-select`,value:S,onChange:e=>C(e.target.value),className:`w-full px-3 py-2 bg-bambu-dark border border-bambu-dark-tertiary rounded-lg text-white focus:border-bambu-green focus:outline-none`,children:[(0,Z.jsx)(`option`,{value:``,children:r(`editArchive.verdicts.none`)}),(0,Z.jsx)(`option`,{value:`good`,children:r(`editArchive.verdicts.good`)}),(0,Z.jsx)(`option`,{value:`reject`,children:r(`editArchive.verdicts.reject`)})]}),w&&S===(e.user_verdict??``)&&(0,Z.jsx)(`p`,{className:`text-xs text-bambu-gray/70 mt-1`,"data-testid":`verdict-source-hint`,children:r(w)})]}),(b===`failed`||b===`aborted`||b===`completed`&&S===`reject`)&&(0,Z.jsxs)(`div`,{children:[(0,Z.jsx)(`label`,{htmlFor:`failure-reason-select`,className:`block text-sm text-bambu-gray mb-1`,children:r(`editArchive.failureReason`)}),(0,Z.jsxs)(`select`,{id:`failure-reason-select`,value:g,onChange:e=>_(e.target.value),className:`w-full px-3 py-2 bg-bambu-dark border border-bambu-dark-tertiary rounded-lg text-white focus:border-bambu-green focus:outline-none`,children:[(0,Z.jsx)(`option`,{value:``,children:r(`editArchive.selectReason`)}),xl.map(e=>(0,Z.jsx)(`option`,{value:e,children:r(`editArchive.failureReasons.${e}`)},e)),y&&(0,Z.jsx)(`option`,{value:y,children:y})]})]}),(0,Z.jsxs)(`div`,{children:[(0,Z.jsxs)(`label`,{className:`block text-sm text-bambu-gray mb-1`,children:[(0,Z.jsx)(Ya,{className:`w-4 h-4 inline mr-1`}),r(`editArchive.photos`)]}),(0,Z.jsxs)(`div`,{className:`flex flex-wrap gap-2 mb-2`,children:[k.map(t=>(0,Z.jsxs)(`div`,{className:`relative group`,children:[(0,Z.jsx)(`img`,{src:o.getArchivePhotoUrl(e.id,t),alt:r(`editArchive.printResult`),className:`w-20 h-20 object-cover rounded-lg border border-bambu-dark-tertiary`}),(0,Z.jsx)(`button`,{type:`button`,onClick:()=>U(t),className:`absolute -top-1 -right-1 p-1 bg-red-500 rounded-full can-hover:opacity-0 group-hover:opacity-100 focus-visible:opacity-100 transition-opacity`,children:(0,Z.jsx)(ms,{className:`w-3 h-3 text-white`})})]},t)),(0,Z.jsxs)(`label`,{className:`w-20 h-20 flex items-center justify-center border-2 border-dashed border-bambu-dark-tertiary rounded-lg cursor-pointer hover:border-bambu-green transition-colors`,children:[(0,Z.jsx)(`input`,{ref:ne,type:`file`,accept:`image/jpeg,image/png,image/webp`,onChange:de,className:`hidden`,disabled:N}),N?(0,Z.jsx)(he,{className:`w-6 h-6 text-bambu-gray animate-spin`}):(0,Z.jsx)(Wo,{className:`w-6 h-6 text-bambu-gray`})]})]}),(0,Z.jsx)(`p`,{className:`text-xs text-bambu-gray`,children:r(`editArchive.photosHelp`)})]}),(0,Z.jsxs)(`div`,{className:`flex gap-3 pt-2`,children:[(0,Z.jsx)(xe,{type:`button`,variant:`secondary`,onClick:t,className:`flex-1`,children:r(`common.cancel`)}),(0,Z.jsxs)(xe,{type:`submit`,disabled:ue.isPending,className:`flex-1`,children:[(0,Z.jsx)($o,{className:`w-4 h-4`}),ue.isPending?r(`common.saving`):r(`common.save`)]})]})]})]})})}function Tl(e){if(!e)return null;let t=[e.brand,e.material,e.subtype].filter(Boolean);return t.length>0?t.join(` `):null}function El(e,t){let n=[],r=e?.ams_extruder_map,i=!!e?.nozzles?.[1]?.nozzle_diameter||r&&Object.keys(r).length>0||(e?.vt_tray?.length??0)>1;e?.ams?.forEach(e=>{let i=e.tray.length===1;e.tray.forEach(a=>{if(a.tray_type){let o=Cc(a.tray_color),s=Hc(e.id,a.id,!1),c=t?.get(s);n.push({type:a.tray_type,color:o,colorName:c?.color_name?.trim()||rc(o,a.tray_sub_brands),amsId:e.id,trayId:a.id,isHt:i,isExternal:!1,label:Vc(e.id,a.id,i,!1),globalTrayId:s,trayInfoIdx:a.tray_info_idx||``,traySubBrands:a.tray_sub_brands||``,spoolName:Tl(c)??void 0,extraColors:c?.extra_colors??void 0,effectType:c?.effect_type??void 0,spoolSubtype:c?.subtype??void 0,extruderId:r?.[String(e.id)],remain:a.remain??-1})}})});for(let r of e?.vt_tray??[])if(r.tray_type){let a=Cc(r.tray_color),o=r.id??254,s=(e?.vt_tray?.length??0)>1,c=t?.get(o);n.push({type:r.tray_type,color:a,colorName:c?.color_name?.trim()||rc(a,r.tray_sub_brands),amsId:-1,trayId:o-254,isHt:!1,isExternal:!0,label:s?o===254?`Ext-L`:`Ext-R`:`External`,globalTrayId:o,trayInfoIdx:r.tray_info_idx||``,traySubBrands:r.tray_sub_brands||``,spoolName:Tl(c)??void 0,extraColors:c?.extra_colors??void 0,effectType:c?.effect_type??void 0,spoolSubtype:c?.subtype??void 0,extruderId:i?255-o:void 0,remain:r.remain??-1})}return n}function Dl(e,t,n,r){let i=El(t);if(i.length!==0)return jl(Al(e,i,{},n,r,t?.fila_switch?.installed===!0))}function Ol(e,t){return(0,W.useMemo)(()=>El(e,t),[e,t])}function kl(e,t){let n=wc(t);return n?wc(e)===n||Nc(e,t):!0}function Al(e,t,n,r,i,a=!1){if(!e?.filaments||e.filaments.length===0)return[];let o=new Set(Object.values(n));return e.filaments.map(e=>{let s=e.slot_id||0;if(s>0&&n[s]!==void 0){let r=n[s],i=t.find(e=>e.globalTrayId===r);if(i){let t=Mc(i.type,e.type),n=kl(i.color,e.color),r;return r=t&&n?`match`:t?`type_only`:`mismatch`,{...e,loaded:i,hasFilament:!0,typeMatch:t,colorMatch:n,status:r,isManual:!0}}}let c=e.tray_info_idx||``,l=t.filter(e=>!o.has(e.globalTrayId));e.nozzle_id!=null&&!a&&(l=l.filter(t=>t.extruderId===e.nozzle_id)),r&&(l=[...l].sort((e,t)=>Zc(Xc(e,i),Xc(t,i))));let u,d,f,p;if(c){let t=l.filter(e=>e.trayInfoIdx===c);t.length===1?u=t[0]:t.length>1&&(r&&t.sort((e,t)=>Zc(Xc(e,i),Xc(t,i))),d=t.find(t=>Mc(t.type,e.type)&&wc(t.color)===wc(e.color)),d||(f=zc(t.filter(t=>Mc(t.type,e.type)),e.color,e=>e.color)),!d&&!f&&(p=t.find(t=>Mc(t.type,e.type))))}!u&&!d&&!f&&!p&&(d=l.find(t=>Mc(t.type,e.type)&&wc(t.color)===wc(e.color)),d||(f=zc(l.filter(t=>Mc(t.type,e.type)),e.color,e=>e.color)),!d&&!f&&(p=l.find(t=>Mc(t.type,e.type))));let m=u||d||f||p||void 0;m&&o.add(m.globalTrayId);let h=!!m,g=h,_=h&&kl(m.color,e.color),v;return v=h?_?`match`:`type_only`:`mismatch`,{...e,loaded:m,hasFilament:h,typeMatch:g,colorMatch:_,status:v,isManual:!1}})}function jl(e){if(e.length===0)return;let t=Math.max(...e.map(e=>e.slot_id||0));if(t<=0)return;let n=Array(t).fill(-1);return e.forEach(e=>{e.slot_id&&e.slot_id>0&&(n[e.slot_id-1]=e.loaded?.globalTrayId??-1)}),n}function Ml(e,t,n,r,i,a){let o=Ol(t,a),s=t?.fila_switch?.installed===!0,c=(0,W.useMemo)(()=>Al(e,o,n,r,i,s),[e,o,n,r,s,i]);return{loadedFilaments:o,filamentComparison:c,amsMapping:(0,W.useMemo)(()=>o.length===0?void 0:jl(c),[c,o.length]),hasTypeMismatch:c.some(e=>e.status===`mismatch`),hasColorMismatch:c.some(e=>e.status===`type_only`)}}function Nl(e,t,n,r,i){if(!e||e.length===0)return{exactMatches:0,typeOnlyMatches:0,missingTypes:0,totalSlots:0,status:`full`};let a=0,o=0,s=0,c=new Set(Object.values(n));for(let l of e){let e=l.slot_id||0;if(e>0&&n[e]!==void 0){let r=n[e],i=t.find(e=>e.globalTrayId===r);if(i){let e=Mc(i.type,l.type),t=wc(i.color)===wc(l.color)||Nc(i.color,l.color);e&&t?a++:e?o++:s++;continue}}let u=t.filter(e=>!c.has(e.globalTrayId));if(l.nozzle_id!=null){let e=u.filter(e=>e.extruderId===l.nozzle_id);e.length>0&&(u=e)}r&&(u=[...u].sort((e,t)=>Zc(Xc(e,i),Xc(t,i))));let d=u.find(e=>Mc(e.type,l.type)&&wc(e.color)===wc(l.color)),f=d?void 0:zc(u.filter(e=>Mc(e.type,l.type)),l.color,e=>e.color),p=d||f?void 0:u.find(e=>Mc(e.type,l.type)),m=d??f??p;m&&c.add(m.globalTrayId),d||f?a++:p?o++:s++}let l=e.length,u=`full`;return s>0?u=`missing`:o>0&&(u=`partial`),{exactMatches:a,typeOnlyMatches:o,missingTypes:s,totalSlots:l,status:u}}function Pl(e,t,n,r,i){if(!e?.filaments||e.filaments.length===0)return;let a=El(t);if(a.length===0)return;let o=new Set(Object.values(n)),s=[];for(let t of e.filaments){let e=t.slot_id||0;if(e>0&&n[e]!==void 0){s.push({slot_id:e,globalTrayId:n[e]});continue}let c=a.filter(e=>!o.has(e.globalTrayId));if(t.nozzle_id!=null){let e=c.filter(e=>e.extruderId===t.nozzle_id);e.length>0&&(c=e)}r&&(c=[...c].sort((e,t)=>Zc(Xc(e,i),Xc(t,i))));let l=c.find(e=>Mc(e.type,t.type)&&wc(e.color)===wc(t.color)),u=l?void 0:zc(c.filter(e=>Mc(e.type,t.type)),t.color,e=>e.color),d=l||u?void 0:c.find(e=>Mc(e.type,t.type)),f=l??u??d;f&&o.add(f.globalTrayId),s.push({slot_id:e,globalTrayId:f?.globalTrayId??-1})}let c=Math.max(...s.map(e=>e.slot_id||0));if(c<=0)return;let l=Array(c).fill(-1);return s.forEach(e=>{e.slot_id&&e.slot_id>0&&(l[e.slot_id-1]=e.globalTrayId)}),l}var Q={useDefault:!0,manualMappings:{},autoConfigured:!1};function Fl(e,t,n,r,i,a,s,c,l){let u=B({queries:e.map(t=>({queryKey:[`printer-status`,t],queryFn:()=>o.getPrinterStatus(t),enabled:e.length>0,staleTime:5e3}))}),d=(0,W.useMemo)(()=>e.map((e,a)=>{let o=u[a],d=o?.data,f=t?.find(t=>t.id===e)?.name||`Printer ${e}`,p=El(d),m=i[e]||Q,h=c?.get(e),g=Qc(s,d?.ams_filament_backup),_=Dl(n,d,g,h),v=l!=null&&e===l,y=m.useDefault?v?r:{}:m.manualMappings,b=Pl(n,d,y,g,h),x=Nl(n?.filaments,p,y,g,h);return{printerId:e,printerName:f,status:d,isLoading:o?.isLoading??!1,loadedFilaments:p,autoMapping:_,finalMapping:b,matchStatus:x.status,exactMatches:x.exactMatches,typeOnlyMatches:x.typeOnlyMatches,missingTypes:x.missingTypes,totalSlots:x.totalSlots,config:m,inventoryByTrayId:h}}),[e,u,t,n,i,r,s,c,l]),f=u.some(e=>e.isLoading),p=(e,t)=>{a(n=>({...n,[e]:{...n[e]||Q,...t}}))},m=e=>{let t=d.find(t=>t.printerId===e);if(!t||!t.status||!n?.filaments)return;let r=Dl(n,t.status,Qc(s,t.status?.ams_filament_backup),c?.get(e));if(!r)return;let i={};r.forEach((e,t)=>{e!==-1&&(i[t+1]=e)}),p(e,{useDefault:!1,manualMappings:i,autoConfigured:!0})};return{printerResults:d,isLoading:f,perPrinterConfigs:i,updatePrinterConfig:p,autoConfigureAll:()=>{for(let t of e)m(t)},autoConfigurePrinter:m,getFinalMapping:e=>d.find(t=>t.printerId===e)?.finalMapping,allPrintersReady:d.every(e=>e.matchStatus!==`missing`)}}function Il(e){if(!e)return`/img/printers/default.png`;let t=e.toLowerCase().replace(/\s+/g,``);return t.includes(`x1e`)?`/img/printers/x1e.png`:t.includes(`x1c`)||t.includes(`x1carbon`)||t.includes(`x1`)?`/img/printers/x1c.png`:t.includes(`x2d`)||t===`n6`?`/img/printers/x2d.png`:t.includes(`h2dpro`)||t.includes(`h2d-pro`)?`/img/printers/h2dpro.png`:t.includes(`h2d`)?`/img/printers/h2d.png`:t.includes(`h2c`)?`/img/printers/h2c.png`:t.includes(`h2s`)?`/img/printers/h2d.png`:t.includes(`p2s`)||t.includes(`p1s`)?`/img/printers/p1s.png`:t.includes(`p1p`)?`/img/printers/p1p.png`:t.includes(`a2l`)||t===`n9`?`/img/printers/a2l.png`:t.includes(`a1mini`)?`/img/printers/a1mini.png`:t.includes(`a1`)?`/img/printers/a1.png`:`/img/printers/default.png`}var Ll=[new Set([`X1`,`X1C`,`X1E`,`P1P`,`P1S`])];function Rl(e,t){if(!e||!t)return!0;let n=e=>e.trim().toUpperCase().replace(/[\s-]/g,``),r=n(e),i=n(t);return r===i?!0:Ll.some(e=>e.has(r)&&e.has(i))}function zl(e){return e>=-50?{labelKey:`printers.wifiSignal.excellent`,color:`text-bambu-green`,bars:4}:e>=-60?{labelKey:`printers.wifiSignal.good`,color:`text-bambu-green`,bars:3}:e>=-70?{labelKey:`printers.wifiSignal.fair`,color:`text-yellow-400`,bars:2}:e>=-80?{labelKey:`printers.wifiSignal.weak`,color:`text-orange-400`,bars:1}:{labelKey:`printers.wifiSignal.veryWeak`,color:`text-red-400`,bars:1}}function Bl(e){return!e?.connected||e.awaiting_plate_clear||e.ams?.some(e=>e.dry_time>0&&!e.dry_countdown_stalled)?!1:[`IDLE`,`FINISH`,`FAILED`].includes(e.state??``)}function Vl(e,t,n,r){return e.filter(e=>{if(e.printer_id!=null)return!0;if(e.required_filament_types&&e.required_filament_types.length>0&&t!==void 0&&!e.required_filament_types.every(e=>t.has(e.toUpperCase())))return!1;if(e.filament_overrides&&e.filament_overrides.length>0&&n!==void 0){let t=e.filament_overrides.filter(e=>e.force_color_match===!0),i=e.filament_overrides.filter(e=>e.force_color_match!==!0);if(t.length>0&&!t.every(e=>{let t=(e.type||``).toUpperCase(),i=(e.color||``).replace(`#`,``).toLowerCase().slice(0,6),a=e.tray_info_idx||``;return!a||r===void 0?n.has(`${t}:${i}`):r.has(`${t}:${i}:${a}`)||r.has(`${t}:${i}:`)})||i.length>0&&t.length===0&&!i.some(e=>{let t=(e.type||``).toUpperCase(),r=(e.color||``).replace(`#`,``).toLowerCase().slice(0,6);return n.has(`${t}:${r}`)}))return!1}return!0})}var Hl=`/img/bed`,Ul={"cool plate":{icon:`${Hl}/bed_cool.png`,label:`Cool Plate`},"pc plate":{icon:`${Hl}/bed_cool.png`,label:`Cool Plate`},"cool plate (supertack)":{icon:`${Hl}/bed_cool_supertack.png`,label:`Cool Plate SuperTack`},"supertack plate":{icon:`${Hl}/bed_cool_supertack.png`,label:`Cool Plate SuperTack`},"bambu cool plate supertack":{icon:`${Hl}/bed_cool_supertack.png`,label:`Cool Plate SuperTack`},"engineering plate":{icon:`${Hl}/bed_engineering.png`,label:`Engineering Plate`},"high temp plate":{icon:`${Hl}/bed_high_templ.png`,label:`High Temp Plate`},"textured pei plate":{icon:`${Hl}/bed_pei.png`,label:`Textured PEI Plate`},"pei plate":{icon:`${Hl}/bed_pei.png`,label:`PEI Plate`},"smooth pei plate":{icon:`${Hl}/bed_pei_cool.png`,label:`Smooth PEI Plate`}};function Wl(e){return e?Ul[e.trim().toLowerCase()]??null:null}function Gl(e,t){if(t==null)return;let n=e?.slicer_ams_mapping;if(!(!n||typeof n!=`object`)&&n.printer_id===t&&!(!Array.isArray(n.mapping)||n.mapping.length===0))return n.mapping}var Kl=e(x(),1);function ql({rgba:e,extraColors:t,effectType:n,subtype:r,className:i=`w-5 h-5`,shape:a=`circle`,style:o,title:s,effectSize:c}){let l=(0,W.useMemo)(()=>Pe(t),[t]),u=(0,W.useMemo)(()=>Ne({effectSize:c,rgba:e,extraColors:t,effectType:n,subtype:r}),[c,e,t,n,r]),d=u.backgroundImage,f=u.backgroundSize,p=a===`circle`||a===`pill`?`rounded-full`:`rounded`,m=(()=>{if(!e)return;let t=e.replace(/^#/,``);return t.length>=8&&t.substring(6,8).toLowerCase()!==`ff`?`#${t.substring(0,8)}`:`#${t.substring(0,6)}`})(),h=s??(l.length>0?l.join(`, `):m);return(0,Z.jsx)(`span`,{"data-testid":`filament-swatch`,className:`${i} ${p} border border-black/20 inline-block flex-shrink-0`,style:{backgroundImage:d,backgroundSize:f,...o},title:h})}var Jl=`w-3 h-3`;function Yl({value:e,options:t,placeholder:n,placeholderOption:r,onChange:i,disabled:a=!1,ariaLabel:o,title:s,className:c=``,exactMatchLabel:l}){let[u,d]=(0,W.useState)(!1),[f,p]=(0,W.useState)(0),[m,h]=(0,W.useState)(null),g=(0,W.useRef)(null),_=(0,W.useRef)(null),v=[{...r??{},value:``,label:n},...t],y=Math.max(0,v.findIndex(t=>t.value===e)),b=v[y],x=(0,W.useCallback)(()=>{let e=g.current;if(!e)return;let t=e.getBoundingClientRect(),n=window.innerHeight-t.bottom,r=Math.min(_.current?.scrollHeight??0,240);h({top:n<r+8&&t.top>n?Math.max(8,t.top-r-4):t.bottom+4,left:t.left,width:t.width})},[]);(0,W.useLayoutEffect)(()=>{u&&x()},[u,x]),(0,W.useEffect)(()=>{if(!u)return;let e=e=>{let t=e.target;g.current?.contains(t)||_.current?.contains(t)||d(!1)},t=e=>{e.key===`Escape`&&(e.stopPropagation(),d(!1),g.current?.focus())},n=()=>x();return document.addEventListener(`mousedown`,e),document.addEventListener(`keydown`,t,!0),window.addEventListener(`scroll`,n,!0),window.addEventListener(`resize`,n),()=>{document.removeEventListener(`mousedown`,e),document.removeEventListener(`keydown`,t,!0),window.removeEventListener(`scroll`,n,!0),window.removeEventListener(`resize`,n)}},[u,x]);let S=e=>{i(v[e].value),d(!1),g.current?.focus()},C=e=>{p(e),d(!0)},w=e=>{if(!a){if(!u){(e.key===`ArrowDown`||e.key===`ArrowUp`||e.key===`Enter`||e.key===` `)&&(e.preventDefault(),C(y));return}e.key===`ArrowDown`?(e.preventDefault(),p(e=>Math.min(v.length-1,e+1))):e.key===`ArrowUp`?(e.preventDefault(),p(e=>Math.max(0,e-1))):e.key===`Home`?(e.preventDefault(),p(0)):e.key===`End`?(e.preventDefault(),p(v.length-1)):e.key===`Enter`||e.key===` `?(e.preventDefault(),S(f)):e.key===`Tab`&&d(!1)}},T=`slot-picker-${o.replace(/\W+/g,`-`)}`,E=e=>e.rgba?(0,Z.jsx)(ql,{rgba:e.rgba,extraColors:e.extraColors,effectType:e.effectType,subtype:e.subtype,className:Jl,effectSize:`table`}):null;return(0,Z.jsxs)(Z.Fragment,{children:[(0,Z.jsxs)(`button`,{ref:g,type:`button`,role:`combobox`,"aria-label":o,"aria-haspopup":`listbox`,"aria-expanded":u,"aria-controls":u?T:void 0,"aria-activedescendant":u?`${T}-${f}`:void 0,disabled:a,title:s,onClick:()=>u?d(!1):C(y),onKeyDown:w,className:`flex-1 min-w-0 flex items-center gap-1.5 px-2 py-1 rounded border text-xs bg-bambu-dark-secondary text-left focus:outline-none focus:ring-1 focus:ring-bambu-green disabled:opacity-50 ${c}`,children:[E(b),(0,Z.jsxs)(`span`,{className:`flex-1 min-w-0 truncate`,children:[b.label,b.meta?(0,Z.jsx)(`span`,{className:`text-bambu-gray`,children:b.meta}):null]}),(0,Z.jsx)(le,{className:`w-3 h-3 shrink-0 opacity-70`})]}),u&&(0,Kl.createPortal)((0,Z.jsx)(`div`,{ref:_,id:T,role:`listbox`,"aria-label":o,className:`fixed z-[60] max-h-60 overflow-y-auto rounded-lg border border-bambu-dark-tertiary bg-bambu-dark-secondary p-1 shadow-xl`,style:{top:m?.top??-9999,left:m?.left??-9999,width:m?.width,visibility:m?`visible`:`hidden`},children:v.map((e,t)=>(0,Z.jsxs)(`button`,{id:`${T}-${t}`,type:`button`,role:`option`,"data-value":e.value,"aria-selected":t===y,onMouseEnter:()=>p(t),onClick:()=>S(t),className:`w-full flex items-center gap-1.5 text-left px-2 py-1.5 rounded-md text-xs ${t===y?`bg-bambu-green/15 text-bambu-green`:t===f?`bg-bambu-dark text-white`:`text-white`}`,children:[E(e),(0,Z.jsxs)(`span`,{className:`flex-1 min-w-0 truncate`,title:e.label,children:[e.label,e.meta?(0,Z.jsx)(`span`,{className:`text-bambu-gray`,children:e.meta}):null]}),e.hex?(0,Z.jsx)(`span`,{className:`shrink-0 font-mono text-[10px] uppercase text-bambu-gray`,children:e.hex}):null,e.exactMatch?(0,Z.jsx)(`span`,{title:l,className:`shrink-0 text-bambu-green`,children:(0,Z.jsx)(ce,{className:`w-3 h-3`})}):null]},e.key??`${e.value}-${t}`))}),document.body)]})}function Xl(e){if(!e)return null;let t=e.trim().replace(/^#/,``);return/^[0-9a-fA-F]{6}([0-9a-fA-F]{2})?$/.test(t)?`#${(t.length===8&&t.substring(6,8).toLowerCase()!==`ff`?t:t.substring(0,6)).toUpperCase()}`:null}function Zl(e){let t=e.trim().split(/\s+/);return t.length<=1?e.trim():t.slice(1).join(` `)}function Ql(e){let{data:t}=z({queryKey:[`builtin-filaments`],queryFn:()=>o.getBuiltinFilaments(),staleTime:300*1e3}),{data:n}=z({queryKey:[`filament-id-map`],queryFn:()=>o.getFilamentIdMap(),staleTime:300*1e3}),r=(0,W.useMemo)(()=>{let e={};for(let n of t||[])n.filament_id&&(e[n.filament_id]=n.name);for(let[t,r]of Object.entries(n||{}))t&&r&&(e[t]=r);return e},[t,n]),i=(0,W.useMemo)(()=>(e||[]).map(e=>{let t=e.tray_info_idx&&r[e.tray_info_idx]||e.type;return{resolvedName:t,materialHint:Zl(t),color:e.color}}),[e,r]),a=B({queries:i.map(({color:e,materialHint:t})=>({queryKey:[`color-by-material`,e,t],queryFn:()=>o.getColorByMaterial(e,t),enabled:!!e,staleTime:300*1e3}))});return i.map(({resolvedName:e,color:t},n)=>({resolvedName:e,colorLabel:(a[n]?.data?.color_name??null)||rc(t)}))}var $l=Array.from({length:6},(e,t)=>t+1),eu=0;function tu(e){let t=new Map,n;for(let r of e??[]){if(r.id===eu){n=r;continue}let e=r.id-15;e>=1&&e<=6&&t.set(e,r)}let r=$l.filter(e=>!t.has(e));return r.length===1&&n&&(n.nozzle_diameter||n.nozzle_type)&&t.set(r[0],n),t}function nu(e,t){if(!e||!e.nozzle_diameter&&!e.nozzle_type)return!1;let n=Number.parseFloat(e.nozzle_diameter),r=Number.parseFloat(t.nozzle_diameter);if(!Number.isFinite(n)||!Number.isFinite(r)||Math.abs(n-r)>.005)return!1;let i=(t.volume_type||``).trim().toLowerCase();if(i&&e.nozzle_type){let t=e.nozzle_type.toUpperCase().startsWith(`HH`);if(i.startsWith(`high flow`)!==t)return!1}return!0}function ru(e,t,n){let r=tu(e);return $l.map(e=>{let i=r.get(e),a=nu(i,t),o;return a||(o=i?n(`printModal.rackWrongNozzle`,{has:`${i.nozzle_diameter||`?`} ${i.nozzle_type||``}`.trim(),needs:`${t.nozzle_diameter} ${t.volume_type}`.trim()}):n(`printModal.rackEmptyPosition`)),{position:e,diameter:i?.nozzle_diameter??``,nozzleType:i?.nozzle_type??``,filamentColor:i?.filament_color??``,eligible:a,reason:o}})}function iu(e,t,n={}){let r=tu(e),i={},a=new Set,o=[...t.keys()].filter(e=>t.get(e).on_rack).sort((e,t)=>e-t);for(let e of o){let o=n[e];if(o!=null){if(a.has(o)||!nu(r.get(o),t.get(e)))return null;i[e]=o,a.add(o)}}for(let e of o){if(i[e]!=null)continue;let n=t.get(e),o=$l.filter(e=>!a.has(e)&&nu(r.get(e),n));if(o.length===0)return null;let s=au(n.filament_color),c=(s?o.find(e=>au(r.get(e)?.filament_color)===s):void 0)??o[0];i[e]=c,a.add(c)}return i}function au(e){return(e??``).trim().replace(/^#/,``).slice(0,6).toUpperCase()}function ou({printerId:e,filamentReqs:t,manualMappings:n,onManualMappingChange:r,onEstimatedCostChange:i,budgetAvailable:a,quantity:s=1,currencySymbol:c,defaultCostPerKg:l,defaultExpanded:u=!1,forceColorMatch:d,onForceColorMatchChange:f,plateLabel:p,archiveAmsMapping:m,nozzleRackChoice:h,onNozzleRackChoiceChange:g}){let{t:_}=v(),y=F(),[b,x]=(0,W.useState)(!1),[S,C]=(0,W.useState)(u),[w,T]=(0,W.useState)(!1),E=(0,W.useRef)([]);(0,W.useEffect)(()=>{T(!1),E.current=[]},[m,p,e]);let D=()=>{if(!m||!t?.filaments)return;if(w){let e={...n};for(let t of E.current)delete e[t];r(e),E.current=[],T(!1);return}let e={...n},i=[];for(let n of t.filaments){let t=n.slot_id-1;n.slot_id>0&&t>=0&&t<m.length&&m[t]>=0&&(e[n.slot_id]=m[t],i.push(n.slot_id))}r(e),E.current=i,T(!0)},{data:O}=z({queryKey:[`printer-status`,e],queryFn:()=>o.getPrinterStatus(e),enabled:!!e}),{data:k}=z({queryKey:[`spool-assignments`,e],queryFn:()=>o.getAssignments(e),enabled:!!e}),{data:A}=z({queryKey:[`settings`],queryFn:o.getSettings}),{data:j}=z({queryKey:[`printer-inventory-remain`,e],queryFn:()=>o.getInventoryRemain(e),enabled:!!e,staleTime:30*1e3,refetchOnMount:`always`}),M=(0,W.useMemo)(()=>{if(!j?.inventory_remain_g)return;let e=new Map;return Object.entries(j.inventory_remain_g).forEach(([t,n])=>{let r=Number(t);Number.isNaN(r)||e.set(r,n)}),e},[j]),N=(0,W.useMemo)(()=>{let e=j?.slot_materials;if(!e?.length)return;let t=new Map;return e.forEach(e=>{e.spool&&t.set(e.global_tray_id,e.spool)}),t.size>0?t:void 0},[j]),{loadedFilaments:P,filamentComparison:I,hasTypeMismatch:ee,hasColorMismatch:te}=Ml(t,O,n,Qc(A?.prefer_lowest_filament,O?.ams_filament_backup),M,N),ne=Ql(t?.filaments),L=(0,W.useMemo)(()=>{let e=new Map;for(let t of k||[]){let n=t.ams_id===255,r=Hc(t.ams_id,t.tray_id,n);e.set(r,t.spool?.cost_per_kg??null)}return e},[k]),R=(0,W.useMemo)(()=>{let e=new Map;for(let t of k||[]){let n=t.ams_id===255,r=Hc(t.ams_id,t.tray_id,n),i=t.spool;if(!i){e.set(r,null);continue}e.set(r,Math.max(0,Math.round((i.label_weight??0)-(i.weight_used??0))))}return e},[k]),re=(0,W.useMemo)(()=>{let e=0;for(let t of I){let n=t.loaded?.globalTrayId;if(n==null)continue;let r=L.get(n)??null??l;r>0&&(e+=t.used_grams/1e3*r)}return e},[I,L,l]),ie=(0,W.useRef)(i);(0,W.useEffect)(()=>{ie.current=i},[i]),(0,W.useEffect)(()=>{ie.current?.(re>0?re:null)},[re]);let B=(0,W.useMemo)(()=>Array.from(L.values()).some(e=>e!=null&&e>0),[L]),V=re*Math.max(1,s),ae=a!=null&&V>a,oe=t?.filaments&&t.filaments.length>0,se=t?.filaments?.some(e=>e.nozzle_id!=null)??!1,ue=(0,W.useMemo)(()=>{let e=new Map;for(let n of t?.filaments??[])n.group_id!=null&&n.group&&e.set(n.group_id,n.group);return e},[t]),de=(O?.nozzle_rack?.some(e=>e.id>=16)??!1)&&[...ue.values()].some(e=>e.on_rack),U=(0,W.useMemo)(()=>de?iu(O?.nozzle_rack,ue,h??{})??h??{}:{},[de,O?.nozzle_rack,ue,h]),fe=(e,t)=>{g&&g({...U,[e]:t})},pe=O?.fila_switch?.installed===!0,me=O?.ams_switch_inlet,he=e=>pe&&me?.[String(e)]||null,_e=(0,W.useMemo)(()=>{if(!pe)return null;let e=new Set;for(let t of I){if(!t.loaded||t.loaded.isExternal)return null;let n=he(t.loaded.amsId);if(!n)return null;e.add(n)}return I.length<2||e.size!==1?null:[...e][0]},[pe,me,I]);if(!oe||!O)return null;let ve=ee?`#f97316`:te?`#facc15`:`#00ae42`,ye=(e,t)=>{if(e>0)if(t===``){let t={...n};delete t[e],r(t)}else r({...n,[e]:parseInt(t,10)})};return(0,Z.jsxs)(`div`,{className:`mb-4`,children:[(0,Z.jsxs)(`button`,{type:`button`,onClick:()=>C(!S),className:`flex items-center gap-2 text-sm text-bambu-gray hover:text-white transition-colors w-full`,children:[(0,Z.jsx)(no,{className:`w-4 h-4`,fill:ve,stroke:`none`}),(0,Z.jsx)(`span`,{children:p?`${_(`printModal.filamentMapping`)} — ${p}`:_(`printModal.filamentMapping`)}),ee?(0,Z.jsxs)(`span`,{className:`text-xs text-orange-700 dark:text-orange-400`,children:[`(`,_(`printModal.statusTypeNotFound`),`)`]}):te?(0,Z.jsxs)(`span`,{className:`text-xs text-yellow-700 dark:text-yellow-400`,children:[`(`,_(`printModal.statusColorMismatch`),`)`]}):(0,Z.jsxs)(`span`,{className:`text-xs text-bambu-green`,children:[`(`,_(`printModal.statusReady`),`)`]}),S?(0,Z.jsx)(H,{className:`w-4 h-4 ml-auto`}):(0,Z.jsx)(le,{className:`w-4 h-4 ml-auto`})]}),S&&(0,Z.jsxs)(`div`,{className:`mt-2 bg-bambu-dark rounded-lg p-3 space-y-2`,children:[(0,Z.jsxs)(`div`,{className:`flex items-center justify-between mb-2`,children:[(0,Z.jsx)(`span`,{className:`text-xs text-bambu-gray`,children:_(`printModal.clickToChangeSlot`)}),(0,Z.jsxs)(`div`,{className:`flex items-center gap-1.5`,children:[m&&(0,Z.jsxs)(`button`,{type:`button`,onClick:D,title:_(`printModal.useArchiveMappingTooltip`),className:`flex items-center gap-1 px-2 py-0.5 text-xs rounded border transition-colors ${w?`border-bambu-green bg-bambu-green/10 text-bambu-green`:`border-bambu-gray/30 hover:border-bambu-gray hover:bg-bambu-dark-tertiary text-bambu-gray hover:text-white`}`,children:[(0,Z.jsx)(ce,{className:`w-3 h-3`}),(0,Z.jsx)(`span`,{children:_(`printModal.useArchiveMapping`)})]}),(0,Z.jsxs)(`button`,{type:`button`,onClick:async()=>{x(!0);try{await o.refreshPrinterStatus(e),await new Promise(e=>setTimeout(e,500)),await y.refetchQueries({queryKey:[`printer-status`,e]})}finally{x(!1)}},className:`flex items-center gap-1 px-2 py-0.5 text-xs rounded border border-bambu-gray/30 hover:border-bambu-gray hover:bg-bambu-dark-tertiary transition-colors text-bambu-gray hover:text-white`,disabled:b,children:[(0,Z.jsx)(Xo,{className:`w-3 h-3 ${b?`animate-spin`:``}`}),(0,Z.jsx)(`span`,{children:_(`printModal.reRead`)})]})]})]}),_e&&(0,Z.jsxs)(`div`,{className:`flex items-start gap-1.5 rounded border border-yellow-500/40 bg-yellow-500/10 px-2 py-1.5 text-xs text-yellow-700 dark:text-yellow-400`,children:[(0,Z.jsx)(ge,{className:`w-3 h-3 mt-0.5 shrink-0`}),(0,Z.jsx)(`span`,{children:_(`printModal.ftsSameInletHint`,{inlet:_e})})]}),I.map((e,t)=>{let n=e.slot_id??0,r=n>0&&f!=null,{resolvedName:i,colorLabel:a}=ne[t]??{resolvedName:e.type,colorLabel:rc(e.color)},[o,s]=ic({name:a,hex:e.color},{name:e.loaded?.colorName,hex:e.loaded?.color});return(0,Z.jsxs)(`div`,{className:`space-y-1`,children:[(0,Z.jsxs)(`div`,{className:`grid items-center gap-2 text-xs`,style:{gridTemplateColumns:de?`16px minmax(210px, 1.4fr) auto 2fr 16px`:`16px minmax(70px, 1fr) auto 2fr 16px`},children:[(0,Z.jsx)(`span`,{title:_(`printModal.requiredTooltip`,{name:i,color:o}),children:(0,Z.jsx)(no,{className:`w-3 h-3`,fill:e.color,stroke:e.color})}),(0,Z.jsxs)(`span`,{className:`text-white flex items-center gap-1 min-w-0`,children:[de&&e.group_id!=null&&e.group?e.group.on_rack?(0,Z.jsx)(`select`,{value:U[e.group_id]??``,onChange:t=>fe(e.group_id,Number(t.target.value)),disabled:!g,title:_(`printModal.rackPositionTooltip`),"aria-label":_(`printModal.rackPosition`),className:`shrink-0 bg-bambu-dark-tertiary text-white text-[10px] font-bold rounded px-1 py-0.5 border border-bambu-dark-tertiary focus:border-bambu-green outline-none disabled:opacity-60`,children:ru(O?.nozzle_rack,e.group,_).map(e=>(0,Z.jsxs)(`option`,{value:e.position,disabled:!e.eligible,title:e.reason,children:[`R`,e.position,e.diameter?` · ${e.diameter}`:``]},e.position))}):(0,Z.jsx)(`span`,{className:`inline-flex items-center justify-center w-3.5 h-3.5 rounded text-[9px] font-bold leading-none bg-bambu-gray/20 text-bambu-gray shrink-0`,title:_(`printModal.leftNozzleTooltip`),children:_(`printModal.leftNozzle`)}):se&&e.nozzle_id!=null?(0,Z.jsx)(`span`,{className:`inline-flex items-center justify-center w-3.5 h-3.5 rounded text-[9px] font-bold leading-none bg-bambu-gray/20 text-bambu-gray shrink-0`,title:e.nozzle_id===1?_(`printModal.leftNozzleTooltip`):_(`printModal.rightNozzleTooltip`),children:e.nozzle_id===1?_(`printModal.leftNozzle`):_(`printModal.rightNozzle`)}):null,(0,Z.jsx)(`span`,{className:`truncate min-w-0`,title:i,children:i}),(0,Z.jsxs)(`span`,{className:`text-bambu-gray shrink-0 whitespace-nowrap`,children:[`(`,e.used_grams,`g)`]})]}),(0,Z.jsx)(`span`,{className:`text-bambu-gray`,children:`→`}),(0,Z.jsx)(Yl,{value:e.loaded?.globalTrayId==null?``:String(e.loaded.globalTrayId),onChange:e=>ye(n,e),placeholder:`-- ${_(`printModal.selectSlot`)} --`,ariaLabel:_(`printModal.slotForFilament`,{name:i}),exactMatchLabel:_(`printModal.exactColorMatch`),className:`${e.status===`match`?`border-bambu-green/50 text-bambu-green`:e.status===`type_only`?`border-yellow-500 dark:border-yellow-400/50 text-yellow-700 dark:text-yellow-400`:`border-orange-500 dark:border-orange-400/50 text-orange-700 dark:text-orange-400`} ${e.isManual?`ring-1 ring-blue-400/50`:``}`,title:e.isManual?_(`printModal.manuallySelected`):_(`printModal.autoMatched`),options:P.map(t=>{let n=R.get(t.globalTrayId),r=n==null?``:_(`printModal.slotRemainingShort`,{grams:n,defaultValue:` - ${n}g left`}),i=he(t.amsId),a=i==null?``:` [${Tc[i]}]`;return{value:String(t.globalTrayId),label:`${t.label}: ${t.spoolName||t.traySubBrands||t.type} (${t.colorName})`,meta:`${r}${a}`,rgba:t.color,extraColors:t.extraColors,effectType:t.effectType,subtype:t.spoolSubtype,hex:Xl(t.color),exactMatch:wc(e.color)!==``&&wc(t.color)===wc(e.color)}})}),e.status===`match`?(0,Z.jsx)(ce,{className:`w-3 h-3 text-bambu-green`}):e.status===`type_only`?(0,Z.jsx)(`span`,{title:o&&s?_(`printModal.sameTypeDifferentColorDetail`,{required:o,loaded:s}):_(`printModal.sameTypeDifferentColor`),children:(0,Z.jsx)(ge,{className:`w-3 h-3 text-yellow-600 dark:text-yellow-400`})}):(0,Z.jsx)(`span`,{title:_(`printModal.filamentTypeNotLoaded`),children:(0,Z.jsx)(ge,{className:`w-3 h-3 text-orange-600 dark:text-orange-400`})})]}),r&&(0,Z.jsxs)(`label`,{className:`inline-flex items-center gap-1.5 text-xs text-bambu-gray cursor-pointer select-none pl-5`,children:[(0,Z.jsx)(`input`,{type:`checkbox`,checked:d?.[n]??!1,onChange:e=>f(n,e.target.checked),className:`accent-bambu-green w-3 h-3`}),(0,Z.jsx)(Bo,{className:`w-3 h-3`}),_(`printModal.forceColorMatch`)]})]},t)}),(0,Z.jsxs)(`div`,{className:`text-xs text-bambu-gray`,children:[_(`printModal.totalCost`),` `,(0,Z.jsx)(`span`,{className:`text-white`,children:re>0||B?`${c}${re.toFixed(2)}`:`N/A`}),s>1&&re>0&&(0,Z.jsx)(`span`,{className:`ml-2`,children:_(`printModal.totalCostForQuantity`,`total: {{cost}}`,{cost:`${c}${V.toFixed(2)}`})})]}),ae&&(0,Z.jsx)(`p`,{className:`text-xs text-red-400 mt-2`,children:_(`printModal.insufficientBudget`,`Insufficient budget for this cost center.`)}),ee&&(0,Z.jsx)(`p`,{className:`text-xs text-orange-700 dark:text-orange-400 mt-2`,children:_(`printModal.requiredTypeNotInPrinter`)})]})]})}function su({filamentReqs:e,availableFilaments:t,overrides:n,onChange:r,forceColorMatch:i,onForceColorMatchChange:a,plateLabel:o,showHint:s=!0}){let{t:c}=v(),l=Ql(e?.filaments),u=(0,W.useMemo)(()=>{let e={};for(let n of t){let t=jc(n.type);e[t]||(e[t]=[]),e[t].push(n)}return e},[t]),d=e?.filaments;if(!d||d.length===0||t.length===0)return null;let f=(e,t)=>{if(t===``){let t={...n};delete t[e],r(t)}else{let[i,a]=t.split(`|`);r({...n,[e]:{type:i,color:a}})}};return(0,Z.jsxs)(`div`,{className:`mb-4`,children:[(0,Z.jsx)(`div`,{className:`flex items-center gap-2 text-sm text-bambu-gray mb-2`,children:(0,Z.jsx)(`span`,{children:o?`${c(`printModal.filamentOverride`)} — ${o}`:c(`printModal.filamentOverride`)})}),s&&(0,Z.jsx)(`p`,{className:`text-xs text-bambu-gray mb-2`,children:c(`printModal.filamentOverrideHint`)}),(0,Z.jsx)(`div`,{className:`bg-bambu-dark rounded-lg p-3 space-y-2`,children:d.map((e,t)=>{let r=n[e.slot_id],o=!!r,s=u[jc(e.type)]||[],d=e.nozzle_id==null?s:s.filter(t=>t.extruder_id==null||t.extruder_id===e.nozzle_id),{resolvedName:p,colorLabel:m}=l[t]??{resolvedName:e.type,colorLabel:rc(e.color)};return(0,Z.jsxs)(`div`,{className:`space-y-1`,children:[(0,Z.jsxs)(`div`,{className:`grid items-center gap-2 text-xs`,style:{gridTemplateColumns:`16px minmax(70px, 1fr) auto 2fr 20px`},children:[(0,Z.jsx)(`span`,{title:`${c(`printModal.originalFilament`)}: ${p} - ${m}`,children:(0,Z.jsx)(no,{className:`w-3 h-3`,fill:e.color,stroke:e.color})}),(0,Z.jsxs)(`span`,{className:`text-white truncate`,children:[p,` `,(0,Z.jsxs)(`span`,{className:`text-bambu-gray`,children:[`(`,e.used_grams,`g)`]})]}),(0,Z.jsx)(`span`,{className:`text-bambu-gray`,children:`→`}),(0,Z.jsx)(Yl,{value:o?`${r.type}|${r.color}`:``,onChange:t=>f(e.slot_id,t),placeholder:`${c(`printModal.originalFilament`)}: ${p} (${m})`,placeholderOption:{rgba:e.color,hex:Xl(e.color)},disabled:d.length===0,ariaLabel:c(`printModal.overrideForFilament`,{name:p}),exactMatchLabel:c(`printModal.exactColorMatch`),className:o?`border-blue-500/50 dark:border-blue-400/50 text-blue-700 dark:text-blue-400`:`border-bambu-gray/30 text-bambu-gray`,options:d.map((t,n)=>({value:`${t.type}|${t.color}`,key:`${t.type}-${t.color}-${t.tray_sub_brands}-${n}`,label:`${t.tray_sub_brands||t.type} (${rc(t.color,t.tray_sub_brands)})`,rgba:t.color,hex:Xl(t.color),exactMatch:wc(e.color)!==``&&wc(t.color)===wc(e.color)}))}),o?(0,Z.jsx)(`button`,{type:`button`,onClick:()=>f(e.slot_id,``),className:`text-bambu-gray hover:text-white transition-colors`,title:c(`printModal.resetToOriginal`),children:(0,Z.jsx)(Zo,{className:`w-3 h-3`})}):(0,Z.jsx)(`span`,{className:`w-3`})]}),(0,Z.jsxs)(`label`,{className:`inline-flex items-center gap-1.5 text-xs text-bambu-gray cursor-pointer select-none pl-5`,children:[(0,Z.jsx)(`input`,{type:`checkbox`,checked:i?.[e.slot_id]??!1,onChange:t=>a?.(e.slot_id,t.target.checked),className:`accent-bambu-green w-3 h-3`}),(0,Z.jsx)(Bo,{className:`w-3 h-3`}),c(`printModal.forceColorMatch`)]})]},e.slot_id)})})]})}function cu({plates:e,isMultiPlate:t,selectedPlates:n,onToggle:r,onSelectAll:i,onDeselectAll:a,multiSelect:o,quantities:s,onQuantityChange:c}){let{t:l}=v();if(!t||e.length<=1)return null;let u=n.size===e.length,d=!!s&&!!c,f=d?e.reduce((e,t)=>n.has(t.index)?e+(s[t.index]??1):e,0):0;return(0,Z.jsxs)(`div`,{className:`mb-4`,children:[(0,Z.jsxs)(`div`,{className:`flex items-center gap-2 mb-2`,children:[(0,Z.jsx)(ko,{className:`w-4 h-4 text-bambu-gray`}),(0,Z.jsxs)(`span`,{className:`text-sm text-bambu-gray`,children:[`Select Plate`,o?`s`:``,` to Print`]}),n.size===0&&(0,Z.jsxs)(`span`,{className:`text-xs text-orange-700 dark:text-orange-400 flex items-center gap-1`,children:[(0,Z.jsx)(ge,{className:`w-3 h-3`}),`Selection required`]}),o&&i&&a&&(0,Z.jsx)(`button`,{type:`button`,onClick:u?a:i,className:`ml-auto text-xs px-2 py-0.5 rounded-full border transition-colors ${u?`border-bambu-green bg-bambu-green/10 text-bambu-green`:`border-bambu-dark-tertiary text-bambu-gray hover:border-bambu-gray`}`,children:u?l(`queue.deselectAll`):l(`queue.selectAllPlates`,{count:e.length})})]}),(0,Z.jsx)(`div`,{className:`grid grid-cols-2 gap-2`,children:e.map(e=>{let t=n.has(e.index);return(0,Z.jsxs)(`div`,{className:`flex items-center gap-2 p-2 rounded-lg border transition-colors ${t?`border-bambu-green bg-bambu-green/10`:`border-bambu-dark-tertiary bg-bambu-dark hover:border-bambu-gray`}`,children:[(0,Z.jsxs)(`button`,{type:`button`,onClick:()=>r(e.index),className:`flex items-center gap-2 text-left min-w-0 flex-1`,children:[o&&(t?(0,Z.jsx)(as,{className:`w-4 h-4 text-bambu-green flex-shrink-0`}):(0,Z.jsx)(os,{className:`w-4 h-4 text-bambu-gray flex-shrink-0`})),e.has_thumbnail&&e.thumbnail_url!=null?(0,Z.jsx)(`img`,{src:y(e.thumbnail_url),alt:`Plate ${e.index}`,className:`w-10 h-10 rounded object-cover bg-bambu-dark-tertiary`}):(0,Z.jsx)(`div`,{className:`w-10 h-10 rounded bg-bambu-dark-tertiary flex items-center justify-center`,children:(0,Z.jsx)(ko,{className:`w-5 h-5 text-bambu-gray`})}),(0,Z.jsxs)(`div`,{className:`min-w-0 flex-1`,children:[(0,Z.jsx)(`p`,{className:`text-sm text-white font-medium truncate`,children:e.name||`Plate ${e.index}`}),(0,Z.jsxs)(`p`,{className:`text-xs text-bambu-gray truncate`,children:[e.objects.length>0?e.objects.slice(0,3).join(`, `)+(e.objects.length>3?`...`:``):`${e.filaments.length} filament${e.filaments.length===1?``:`s`}`,e.print_time_seconds==null?``:` • ${Oe(e.print_time_seconds)}`]}),(()=>{let t=Wl(e.bed_type);return t?(0,Z.jsxs)(`p`,{className:`text-xs text-bambu-gray flex items-center gap-1 mt-0.5 truncate`,title:t.label,children:[(0,Z.jsx)(`img`,{src:t.icon,alt:``,className:`w-3.5 h-3.5 object-contain flex-shrink-0`}),(0,Z.jsx)(`span`,{className:`truncate`,children:t.label})]}):null})()]}),!o&&t&&(0,Z.jsx)(ce,{className:`w-4 h-4 text-bambu-green flex-shrink-0`})]}),d&&t&&(0,Z.jsxs)(`div`,{className:`flex items-center gap-1 flex-shrink-0`,children:[(0,Z.jsx)(`span`,{className:`text-xs text-bambu-gray`,"aria-hidden":`true`,children:`×`}),(0,Z.jsx)(bl,{min:1,max:999,value:s[e.index]??1,"aria-label":l(`queue.plateQuantityLabel`,{plate:e.name||l(`queue.plateNumber`,{index:e.index})}),onChange:t=>c(e.index,t),fallback:1,className:`w-14 px-1.5 py-1 text-sm bg-bambu-dark border border-bambu-dark-tertiary rounded text-white text-center focus:outline-none focus:ring-1 focus:ring-bambu-green`})]})]},e.index)})}),d&&f>n.size&&(0,Z.jsx)(`p`,{className:`text-xs text-bambu-gray mt-2`,children:l(`queue.plateQuantityTotal`,{count:f})})]})}var lu=new Set([`IDLE`,`FINISH`,`FAILED`]);function uu({printerResult:e,filamentReqs:t,onUpdateConfig:n}){let r=F(),[i,a]=(0,W.useState)(!1),s=(t,r)=>{if(t<=0)return;let i={...e.config.manualMappings};r===``?delete i[t]:i[t]=parseInt(r,10),n({useDefault:!1,manualMappings:i,autoConfigured:!1})},c=async()=>{a(!0);try{await o.refreshPrinterStatus(e.printerId),await new Promise(e=>setTimeout(e,500)),await r.refetchQueries({queryKey:[`printer-status`,e.printerId]})}finally{a(!1)}},l=t.map(t=>{let n=t.slot_id||0,i=e.config.manualMappings[n],a,o=!1;if(i!==void 0)a=e.loadedFilaments.find(e=>e.globalTrayId===i),o=!0;else{let n=new Set(Object.values(e.config.manualMappings)),i=r.getQueryData([`settings`]);a=$c(t,e.loadedFilaments,n,Qc(i?.prefer_lowest_filament,e.status?.ams_filament_backup),e.inventoryByTrayId)}let s=`mismatch`;if(a){let e=Mc(a.type,t.type),n=wc(a.color)===wc(t.color)||Nc(a.color,t.color);e&&n?s=`match`:e&&(s=`type_only`)}return{req:t,loaded:a,status:s,isManual:o}});return(0,Z.jsxs)(`div`,{className:`mt-2 bg-bambu-dark rounded-lg p-3 space-y-2`,children:[(0,Z.jsxs)(`div`,{className:`flex items-center justify-between mb-2`,children:[(0,Z.jsx)(`span`,{className:`text-xs text-bambu-gray`,children:`Custom slot mapping`}),(0,Z.jsxs)(`button`,{type:`button`,onClick:c,className:`flex items-center gap-1 px-2 py-0.5 text-xs rounded border border-bambu-gray/30 hover:border-bambu-gray hover:bg-bambu-dark-tertiary transition-colors text-bambu-gray hover:text-white`,disabled:i,children:[(0,Z.jsx)(Xo,{className:`w-3 h-3 ${i?`animate-spin`:``}`}),(0,Z.jsx)(`span`,{children:`Re-read`})]})]}),l.map(({req:t,loaded:n,status:r,isManual:i},a)=>(0,Z.jsxs)(`div`,{className:`grid items-center gap-2 text-xs`,style:{gridTemplateColumns:`16px minmax(70px, 1fr) auto 2fr 16px`},children:[(0,Z.jsx)(`span`,{title:`Required: ${t.type} - ${rc(t.color)}`,children:(0,Z.jsx)(no,{className:`w-3 h-3`,fill:t.color,stroke:t.color})}),(0,Z.jsxs)(`span`,{className:`text-white flex items-center gap-1 min-w-0`,children:[(0,Z.jsx)(`span`,{className:`truncate min-w-0`,title:t.type,children:t.type}),(0,Z.jsxs)(`span`,{className:`text-bambu-gray shrink-0 whitespace-nowrap`,children:[`(`,t.used_grams,`g)`]})]}),(0,Z.jsx)(`span`,{className:`text-bambu-gray`,children:`→`}),(0,Z.jsxs)(`select`,{value:n?.globalTrayId??``,onChange:e=>s(t.slot_id||0,e.target.value),className:`flex-1 px-2 py-1 rounded border text-xs bg-bambu-dark-secondary focus:outline-none focus:ring-1 focus:ring-bambu-green ${r===`match`?`border-bambu-green/50 text-bambu-green`:r===`type_only`?`border-yellow-500 dark:border-yellow-400/50 text-yellow-700 dark:text-yellow-400`:`border-orange-500 dark:border-orange-400/50 text-orange-700 dark:text-orange-400`} ${i?`ring-1 ring-blue-400/50`:``}`,title:i?`Manually selected`:`Auto-matched`,children:[(0,Z.jsx)(`option`,{value:``,className:`bg-bambu-dark text-bambu-gray`,children:`-- Select slot --`}),el(e.loadedFilaments,t.nozzle_id).map(e=>(0,Z.jsxs)(`option`,{value:e.globalTrayId,className:`bg-bambu-dark text-white`,children:[e.label,`: `,e.traySubBrands||e.type,` (`,e.colorName,`)`]},e.globalTrayId))]}),r===`match`?(0,Z.jsx)(ce,{className:`w-3 h-3 text-bambu-green`}):r===`type_only`?(0,Z.jsx)(`span`,{title:`Same type, different color`,children:(0,Z.jsx)(ge,{className:`w-3 h-3 text-yellow-600 dark:text-yellow-400`})}):(0,Z.jsx)(`span`,{title:`Filament type not loaded`,children:(0,Z.jsx)(ge,{className:`w-3 h-3 text-orange-600 dark:text-orange-400`})})]},a))]})}function du({printers:e,selectedPrinterIds:t,onMultiSelect:n,isLoading:r=!1,allowMultiple:i=!1,showInactive:a=!1,disableBusy:s=!1,printerMappingResults:c,filamentReqs:l,onAutoConfigurePrinter:u,onUpdatePrinterConfig:d,assignmentMode:f=`printer`,onAssignmentModeChange:p,targetModel:m,onTargetModelChange:h,targetLocation:g,onTargetLocationChange:_,slicedForModel:v}){let[y,b]=(0,W.useState)(!1),x=a?e:e.filter(e=>e.is_active),S=B({queries:x.map(e=>({queryKey:[`printerStatus`,e.id],queryFn:()=>o.getPrinterStatus(e.id),staleTime:5e3}))}),C=(0,W.useMemo)(()=>{let e=new Map;return x.forEach((t,n)=>{let r=S[n];r?.data&&e.set(t.id,r.data)}),e},[x,S]),w=e=>{let t=C.get(e);return t?t.connected?!lu.has(t.state??``):!0:!1},T=e=>{let t=C.get(e);if(!t)return null;if(!t.connected)return`Offline`;let n=t.state;return n?n===`RUNNING`?t.stg_cur_name||`Printing`:n===`PREPARE`?`Preparing`:n===`PAUSE`?`Paused`:n===`IDLE`?`Idle`:n===`FINISH`?`Finished`:n===`FAILED`?`Failed`:n:null},E=(0,W.useMemo)(()=>{if(f!==`printer`||!v||y)return x;let e=x.filter(e=>e.model===v);return e.length>0?e:x},[x,f,v,y]),D=x.length-E.length,O=(0,W.useMemo)(()=>{let e=x.map(e=>e.model).filter(e=>!!e);return[...new Set(e)].sort()},[x]),k=(0,W.useMemo)(()=>{if(!m)return[];let e=x.filter(e=>e.model===m&&e.location).map(e=>e.location).filter(e=>!!e);return[...new Set(e)].sort()},[x,m]),A=p&&h&&O.length>0,j=i&&t.length>1&&c&&l?.filaments&&l.filaments.length>0&&u&&d;if(r)return(0,Z.jsx)(`div`,{className:`flex justify-center py-8`,children:(0,Z.jsx)(he,{className:`w-6 h-6 text-bambu-green animate-spin`})});if(E.length===0)return(0,Z.jsxs)(`div`,{className:`flex items-center gap-2 text-red-700 dark:text-red-400 text-sm mb-4`,children:[(0,Z.jsx)(de,{className:`w-4 h-4`}),`No `,a?``:`active `,`printers available`]});let M=e=>{s&&w(e)||(i?t.includes(e)?n(t.filter(t=>t!==e)):n([...t,e]):n([e]))},N=()=>{n((s?E.filter(e=>!w(e.id)):E).map(e=>e.id))},P=()=>{n([])},F=(e,t,n)=>{n.stopPropagation(),!(!u||!d)&&(t?u(e):d(e,{useDefault:!0,manualMappings:{},autoConfigured:!1}))},I=e=>t.includes(e),ee=t.length,te=e=>c?.find(t=>t.printerId===e);return(0,Z.jsxs)(`div`,{className:`space-y-2 mb-6`,children:[A&&(0,Z.jsxs)(`div`,{className:`flex gap-2 mb-4`,children:[(0,Z.jsxs)(`button`,{type:`button`,onClick:()=>{p(`printer`),h(null)},className:`flex-1 flex items-center justify-center gap-2 px-3 py-2 rounded-lg border transition-colors ${f===`printer`?`border-bambu-green bg-bambu-green/10 text-white`:`border-bambu-dark-tertiary bg-bambu-dark text-bambu-gray hover:border-bambu-gray`}`,children:[(0,Z.jsx)(qo,{className:`w-4 h-4`}),(0,Z.jsx)(`span`,{className:`text-sm`,children:`Specific Printer`})]}),(0,Z.jsxs)(`button`,{type:`button`,onClick:()=>{p(`model`),n([]),h(v&&O.includes(v)?v:null)},className:`flex-1 flex items-center justify-center gap-2 px-3 py-2 rounded-lg border transition-colors ${f===`model`?`border-bambu-green bg-bambu-green/10 text-white`:`border-bambu-dark-tertiary bg-bambu-dark text-bambu-gray hover:border-bambu-gray`}`,children:[(0,Z.jsx)(_s,{className:`w-4 h-4`}),(0,Z.jsxs)(`span`,{className:`text-sm`,children:[`Any `,(f===`model`?m:null)||v||`Model`]})]})]}),f===`model`&&A&&(0,Z.jsxs)(`div`,{className:`space-y-3 mb-4`,children:[(0,Z.jsxs)(`div`,{children:[(0,Z.jsxs)(`label`,{className:`block text-xs text-bambu-gray mb-1`,children:[`Target Model`,v&&(0,Z.jsxs)(`span`,{className:`ml-2 text-bambu-gray/70`,children:[`(sliced for `,v,`)`]})]}),(0,Z.jsxs)(`select`,{value:m||``,onChange:e=>{h(e.target.value||null),_&&_(null)},className:`w-full px-3 py-2 bg-bambu-dark border border-bambu-dark-tertiary rounded-lg text-white focus:border-bambu-green focus:outline-none text-sm`,children:[(0,Z.jsx)(`option`,{value:``,children:`Select a model...`}),O.map(e=>{let t=Rl(v,e);return(0,Z.jsxs)(`option`,{value:e,disabled:!t,children:[e,t?``:` — incompatible with ${v} G-code`]},e)})]})]}),v&&m&&m!==v&&(Rl(v,m)?(0,Z.jsxs)(`div`,{className:`p-3 bg-yellow-50 dark:bg-yellow-500/10 border border-yellow-300 dark:border-yellow-500/30 rounded-lg flex items-center gap-2`,children:[(0,Z.jsx)(ge,{className:`w-4 h-4 text-yellow-600 dark:text-yellow-400 flex-shrink-0`}),(0,Z.jsxs)(`span`,{className:`text-sm text-yellow-700 dark:text-yellow-400`,children:[`File was sliced for `,v,`, but will be dispatched to a `,m,` printer`]})]}):(0,Z.jsxs)(`div`,{className:`p-3 bg-red-50 dark:bg-red-500/10 border border-red-300 dark:border-red-500/30 rounded-lg flex items-center gap-2`,children:[(0,Z.jsx)(de,{className:`w-4 h-4 text-red-600 dark:text-red-400 flex-shrink-0`}),(0,Z.jsxs)(`span`,{className:`text-sm text-red-700 dark:text-red-400`,children:[`File was sliced for `,v,` and cannot be dispatched to `,m,` printers — select a compatible model`]})]})),m&&k.length>0&&_&&(0,Z.jsxs)(`div`,{children:[(0,Z.jsx)(`label`,{className:`block text-xs text-bambu-gray mb-1`,children:`Location Filter (optional)`}),(0,Z.jsxs)(`select`,{value:g||``,onChange:e=>_(e.target.value||null),className:`w-full px-3 py-2 bg-bambu-dark border border-bambu-dark-tertiary rounded-lg text-white focus:border-bambu-green focus:outline-none text-sm`,children:[(0,Z.jsx)(`option`,{value:``,children:`Any location`}),k.map(e=>(0,Z.jsx)(`option`,{value:e,children:e},e))]})]}),m&&(0,Z.jsxs)(`p`,{className:`text-xs text-bambu-gray`,children:[`Scheduler will assign to first available idle `,m,` printer`,g?` in ${g}`:``]})]}),f===`printer`&&i&&E.length>1&&(0,Z.jsxs)(`div`,{className:`flex items-center justify-between text-xs text-bambu-gray mb-2`,children:[(0,Z.jsx)(`span`,{children:ee===0?`Select printers`:`${ee} printer${ee===1?``:`s`} selected`}),(0,Z.jsxs)(`div`,{className:`flex gap-2`,children:[ee<E.length&&(0,Z.jsx)(`button`,{type:`button`,onClick:N,className:`text-bambu-green hover:text-bambu-green/80 transition-colors`,children:`Select all`}),ee>0&&(0,Z.jsx)(`button`,{type:`button`,onClick:P,className:`text-bambu-gray hover:text-white transition-colors`,children:`Clear`})]})]}),f===`printer`&&E.map(e=>{let t=I(e.id),n=te(e.id),r=n&&!n.config.useDefault,a=w(e.id),o=s&&a,c=T(e.id);return(0,Z.jsxs)(`div`,{children:[(0,Z.jsxs)(`button`,{type:`button`,onClick:()=>M(e.id),disabled:o,className:`w-full flex items-center gap-3 p-3 rounded-lg border transition-colors ${o?`border-bambu-dark-tertiary bg-bambu-dark opacity-50 cursor-not-allowed`:t?`border-bambu-green bg-bambu-green/10`:`border-bambu-dark-tertiary bg-bambu-dark hover:border-bambu-gray`} ${e.is_active?``:`opacity-60`}`,children:[(0,Z.jsx)(`div`,{className:`p-2 rounded-lg ${o?`bg-bambu-dark-tertiary`:t?`bg-bambu-green/20`:`bg-bambu-dark-tertiary`}`,children:(0,Z.jsx)(qo,{className:`w-5 h-5 ${o?`text-bambu-gray/50`:t?`text-bambu-green`:`text-bambu-gray`}`})}),(0,Z.jsxs)(`div`,{className:`text-left flex-1`,children:[(0,Z.jsxs)(`p`,{className:`font-medium ${o?`text-bambu-gray`:`text-white`}`,children:[e.name,!e.is_active&&(0,Z.jsx)(`span`,{className:`text-bambu-gray text-xs ml-2`,children:`(inactive)`})]}),(0,Z.jsxs)(`p`,{className:`text-xs text-bambu-gray`,children:[e.model||`Unknown model`,` • `,e.ip_address]})]}),c&&(0,Z.jsx)(`span`,{className:`text-xs px-2 py-0.5 rounded-full ${a?`bg-yellow-100 dark:bg-yellow-500/20 text-yellow-700 dark:text-yellow-400`:`bg-bambu-green/20 text-bambu-green`}`,children:c}),i&&(0,Z.jsx)(`div`,{className:`w-5 h-5 rounded border-2 flex items-center justify-center transition-colors ${o?`border-bambu-gray/30`:t?`bg-bambu-green border-bambu-green`:`border-bambu-gray/50`}`,children:t&&(0,Z.jsx)(ce,{className:`w-3 h-3 text-white`})})]}),t&&j&&n&&(0,Z.jsxs)(`div`,{className:`ml-4 mt-2 mb-3`,children:[(0,Z.jsxs)(`div`,{className:`flex items-center gap-2`,children:[(0,Z.jsxs)(`label`,{className:`flex items-center gap-2 cursor-pointer`,onClick:e=>e.stopPropagation(),children:[(0,Z.jsx)(`input`,{type:`checkbox`,checked:r,onChange:t=>F(e.id,t.target.checked,t),className:`w-3.5 h-3.5 rounded border-bambu-gray/30 bg-bambu-dark-secondary text-bambu-green focus:ring-bambu-green focus:ring-offset-0`}),(0,Z.jsx)(`span`,{className:`text-xs text-bambu-gray`,children:`Custom mapping`})]}),(0,Z.jsxs)(`span`,{className:`text-xs ml-2 ${n.matchStatus===`full`?`text-bambu-green`:n.matchStatus===`partial`?`text-yellow-700 dark:text-yellow-400`:`text-orange-700 dark:text-orange-400`}`,children:[`(`,n.exactMatches,`/`,n.totalSlots,` matched)`]}),n.isLoading&&(0,Z.jsx)(Xo,{className:`w-3 h-3 text-bambu-gray animate-spin`}),r&&(0,Z.jsxs)(`button`,{type:`button`,onClick:t=>{t.stopPropagation(),u(e.id)},className:`ml-auto flex items-center gap-1 px-2 py-0.5 text-xs rounded border border-bambu-gray/30 hover:border-bambu-gray hover:bg-bambu-dark-tertiary transition-colors text-bambu-gray hover:text-white`,children:[(0,Z.jsx)(ys,{className:`w-3 h-3`}),`Auto`]})]}),r&&(0,Z.jsx)(uu,{printerResult:n,filamentReqs:l.filaments,onUpdateConfig:t=>d(e.id,t)})]})]},e.id)}),f===`printer`&&D>0&&!y&&(0,Z.jsxs)(`button`,{type:`button`,onClick:()=>b(!0),className:`text-xs text-bambu-gray hover:text-white transition-colors mt-2 flex items-center gap-1`,children:[(0,Z.jsx)(ge,{className:`w-3 h-3 text-yellow-600 dark:text-yellow-400`}),D,` other printer`,D>1?`s`:``,` hidden (different model) —`,(0,Z.jsx)(`span`,{className:`underline`,children:`show all`})]}),f===`printer`&&y&&v&&(0,Z.jsx)(`button`,{type:`button`,onClick:()=>b(!1),className:`text-xs text-bambu-gray hover:text-white transition-colors mt-2`,children:(0,Z.jsxs)(`span`,{className:`underline`,children:[`Show only `,v,` printers`]})}),f===`printer`&&ee===0&&(0,Z.jsxs)(`p`,{className:`text-xs text-orange-700 dark:text-orange-400 mt-1 flex items-center gap-1`,children:[(0,Z.jsx)(de,{className:`w-3 h-3`}),`Select at least one printer`]}),f===`model`&&!m&&(0,Z.jsxs)(`p`,{className:`text-xs text-orange-700 dark:text-orange-400 mt-1 flex items-center gap-1`,children:[(0,Z.jsx)(de,{className:`w-3 h-3`}),`Select a target printer model`]})]})}var fu=[`off`,`auto`,`on`],pu={off:`bg-red-500 text-white`,auto:`bg-blue-500 text-white`,on:`bg-bambu-green text-white`},mu=`bg-bambu-dark-tertiary text-bambu-gray hover:text-white`,hu=[`off`,`on`];function gu({options:e,onChange:t,defaultExpanded:n=!1,showDualNozzleOptions:r=!1}){let{t:i}=v(),[a,o]=(0,W.useState)(n),s=[{key:`bed_levelling`,label:i(`settings.defaultBedLevelling`),desc:i(`settings.defaultBedLevellingDesc`),tristate:!0},{key:`flow_cali`,label:i(`settings.defaultFlowCali`),desc:i(`settings.defaultFlowCaliDesc`),tristate:!0},{key:`vibration_cali`,label:i(`settings.defaultVibrationCali`),desc:i(`settings.defaultVibrationCaliDesc`)},{key:`layer_inspect`,label:i(`settings.defaultLayerInspect`),desc:i(`settings.defaultLayerInspectDesc`)},{key:`timelapse`,label:i(`settings.defaultTimelapse`),desc:i(`settings.defaultTimelapseDesc`)},{key:`nozzle_offset_cali`,label:i(`settings.defaultNozzleOffsetCali`),desc:i(`settings.defaultNozzleOffsetCaliDesc`),dualNozzleOnly:!0,tristate:!0},{key:`confirm_outcome`,label:i(`settings.defaultConfirmOutcome`),desc:i(`settings.defaultConfirmOutcomeDesc`)}].filter(e=>!e.dualNozzleOnly||r),c=(n,r)=>{t({...e,[n]:r})},l=(n,r)=>{t({...e,[n]:r})},u=n=>{t({...e,preheat_override:n,...n===`off`?{preheat_chamber_target_override:null}:{}})},d=n=>{if(n===``){t({...e,preheat_chamber_target_override:null});return}let r=parseInt(n,10);Number.isNaN(r)||t({...e,preheat_chamber_target_override:Math.max(0,Math.min(65,r))})};return(0,Z.jsxs)(`div`,{className:`mb-4`,children:[(0,Z.jsxs)(`button`,{type:`button`,onClick:()=>o(!a),className:`flex items-center gap-2 text-sm text-bambu-gray hover:text-white transition-colors w-full`,children:[(0,Z.jsx)(ns,{className:`w-4 h-4`}),(0,Z.jsx)(`span`,{children:i(`queue.bulkEdit.printOptions`)}),a?(0,Z.jsx)(H,{className:`w-4 h-4 ml-auto`}):(0,Z.jsx)(le,{className:`w-4 h-4 ml-auto`})]}),a&&(0,Z.jsxs)(`div`,{className:`mt-2 bg-bambu-dark rounded-lg p-3 space-y-2`,children:[s.map(({key:t,label:n,desc:r,tristate:a})=>a?(0,Z.jsxs)(`div`,{className:`flex items-center justify-between gap-3`,children:[(0,Z.jsxs)(`div`,{children:[(0,Z.jsx)(`span`,{className:`text-sm text-white`,children:n}),(0,Z.jsx)(`p`,{className:`text-xs text-bambu-gray`,children:r})]}),(0,Z.jsx)(`div`,{className:`flex gap-1 shrink-0`,children:fu.map(n=>(0,Z.jsx)(`button`,{type:`button`,onClick:()=>l(t,n),className:`px-2.5 py-1 text-xs rounded transition-colors ${e[t]===n?pu[n]:`bg-bambu-dark-tertiary text-bambu-gray hover:text-white`}`,children:i(`settings.calibrationMode_${n}`)},n))})]},t):(0,Z.jsxs)(`div`,{className:`flex items-center justify-between gap-3`,children:[(0,Z.jsxs)(`div`,{children:[(0,Z.jsx)(`span`,{className:`text-sm text-white`,children:n}),(0,Z.jsx)(`p`,{className:`text-xs text-bambu-gray`,children:r})]}),(0,Z.jsx)(`div`,{className:`flex gap-1 shrink-0`,children:hu.map(n=>(0,Z.jsx)(`button`,{type:`button`,onClick:()=>c(t,n===`on`),className:`px-2.5 py-1 text-xs rounded transition-colors ${(e[t]?`on`:`off`)===n?pu[n]:`bg-bambu-dark-tertiary text-bambu-gray hover:text-white`}`,children:i(`settings.calibrationMode_${n}`)},n))})]},t)),(0,Z.jsxs)(`div`,{className:`pt-2 mt-1 border-t border-bambu-dark-tertiary/60`,children:[(0,Z.jsxs)(`div`,{className:`flex items-center gap-2 mb-1.5`,children:[(0,Z.jsx)(mo,{className:`w-3.5 h-3.5 text-amber-600 dark:text-amber-400`}),(0,Z.jsx)(`span`,{className:`text-sm text-white`,children:i(`settings.preheatTitle`,`Preheat & Heat Soak`)})]}),(0,Z.jsx)(`p`,{className:`text-xs text-bambu-gray mb-2`,children:i(`settings.preheatPerItemDesc`,`Heat the bed and chamber before this print starts. Defaults to the global Settings → Workflow toggle.`)}),(0,Z.jsx)(`div`,{className:`flex gap-1.5 mb-2`,children:[`inherit`,`on`,`off`].map(t=>(0,Z.jsx)(`button`,{type:`button`,onClick:()=>u(t),className:`flex-1 px-2 py-1.5 text-xs rounded transition-colors ${e.preheat_override===t?`bg-bambu-green text-white`:`bg-bambu-dark-tertiary text-bambu-gray hover:text-white`}`,children:i(`settings.preheatOverride_${t}`,t===`inherit`?`Inherit`:t===`on`?`On`:`Off`)},t))}),e.preheat_override!==`off`&&(0,Z.jsxs)(`div`,{className:`flex items-center gap-2`,children:[(0,Z.jsx)(`label`,{className:`text-xs text-bambu-gray flex-1`,children:i(`settings.preheatTargetOverride`,`Chamber target override (°C, blank = filament default)`)}),(0,Z.jsx)(`input`,{type:`number`,min:0,max:65,step:1,value:e.preheat_chamber_target_override??``,onChange:e=>d(e.target.value),placeholder:`—`,className:`w-16 px-2 py-1 bg-bambu-dark-tertiary border border-bambu-dark-tertiary rounded text-white text-xs text-right focus:outline-none focus:border-bambu-green`})]}),e.preheat_override!==`off`&&(0,Z.jsx)(`p`,{className:`text-[11px] text-bambu-gray mt-1`,children:i(`settings.preheatTargetOverrideHelp`,`0 heats the bed and runs the soak without the chamber. Leave blank and a print with no chamber requirement skips preheat entirely.`)})]})]})]})}function _u({options:e,onChange:t,dateFormat:n=`system`,timeFormat:r=`system`,canControlPrinter:i=!0,showStagger:a=!1,printerCount:o=0,hasGcodeSnippets:s=!1,needsReview:c=!1}){let{t:l}=v(),[u,d]=(0,W.useState)(``),[f,p]=(0,W.useState)(``),[m,h]=(0,W.useState)(!0),[g,_]=(0,W.useState)(!0),y=(0,W.useRef)(null),b=(0,W.useRef)(!1);(0,W.useEffect)(()=>{if(e.scheduleType!==`scheduled`){b.current=!1;return}if(!b.current){b.current=!0;let i;e.scheduledTime?(i=new Date(e.scheduledTime),isNaN(i.getTime())&&(i=new Date,i.setHours(i.getHours()+1,0,0,0))):(i=new Date,i.setHours(i.getHours()+1,0,0,0),t({...e,scheduledTime:Me(i)})),d(Ae(i,n)),p(Ce(i,r)),h(!0),_(!0)}},[e.scheduleType,e.scheduledTime,n,r,t,e]);let x=n=>{t({...e,scheduleType:n,requireManualStart:n===`queue`?e.requireManualStart:!1})},S=(r,i)=>{let a=Te(r,n),o=Se(i);h(!!a),_(!!o),a&&o&&(a.setHours(o.hours,o.minutes,0,0),a>new Date&&t({...e,scheduledTime:Me(a)}))},C=e=>{d(e),S(e,f)},w=e=>{p(e),S(u,e)};return(0,Z.jsxs)(`div`,{className:`space-y-4`,children:[(0,Z.jsxs)(`div`,{children:[(0,Z.jsx)(`label`,{className:`block text-sm text-bambu-gray mb-2`,children:l(`printModal.whenToPrint`)}),(0,Z.jsxs)(`div`,{className:`flex gap-2`,children:[(0,Z.jsxs)(`button`,{type:`button`,className:`flex-1 px-2 py-2 rounded-lg border text-sm flex items-center justify-center gap-1.5 transition-colors ${e.scheduleType===`asap`?`bg-bambu-green border-bambu-green text-white`:`bg-bambu-dark border-bambu-dark-tertiary text-bambu-gray hover:text-white`}`,onClick:()=>x(`asap`),children:[(0,Z.jsx)(X,{className:`w-4 h-4`}),l(`printModal.asap`)]}),(0,Z.jsxs)(`button`,{type:`button`,className:`flex-1 px-2 py-2 rounded-lg border text-sm flex items-center justify-center gap-1.5 transition-colors ${e.scheduleType===`queue`?`bg-bambu-green border-bambu-green text-white`:`bg-bambu-dark border-bambu-dark-tertiary text-bambu-gray hover:text-white`}`,onClick:()=>x(`queue`),children:[(0,Z.jsx)(jo,{className:`w-4 h-4`}),l(`printModal.queue`)]}),(0,Z.jsxs)(`button`,{type:`button`,className:`flex-1 px-2 py-2 rounded-lg border text-sm flex items-center justify-center gap-1.5 transition-colors ${e.scheduleType===`scheduled`?`bg-bambu-green border-bambu-green text-white`:`bg-bambu-dark border-bambu-dark-tertiary text-bambu-gray hover:text-white`}`,onClick:()=>x(`scheduled`),children:[(0,Z.jsx)(se,{className:`w-4 h-4`}),l(`printModal.schedule`)]})]})]}),e.scheduleType===`scheduled`&&(0,Z.jsxs)(`div`,{children:[(0,Z.jsx)(`label`,{className:`block text-sm text-bambu-gray mb-1`,children:l(`printModal.dateTime`)}),(0,Z.jsxs)(`div`,{className:`flex gap-2`,children:[(0,Z.jsxs)(`div`,{className:`flex-1 relative`,children:[(0,Z.jsx)(`input`,{type:`text`,className:`w-full px-3 py-2 pr-10 bg-bambu-dark border rounded-lg text-white focus:outline-none ${m?`border-bambu-dark-tertiary focus:border-bambu-green`:`border-red-500`}`,value:u,onChange:e=>C(e.target.value),placeholder:ke(n)}),(0,Z.jsx)(`button`,{type:`button`,onClick:()=>{y.current?.showPicker()},className:`absolute right-2 top-1/2 -translate-y-1/2 text-bambu-gray hover:text-white`,title:l(`printModal.openCalendar`),children:(0,Z.jsx)(se,{className:`w-4 h-4`})}),(0,Z.jsx)(`input`,{ref:y,type:`datetime-local`,className:`absolute top-0 left-0 w-0 h-0 opacity-0 pointer-events-none`,value:e.scheduledTime,onChange:i=>{let a=i.target.value;if(a){let i=new Date(a);isNaN(i.getTime())||(d(Ae(i,n)),p(Ce(i,r)),h(!0),_(!0),t({...e,scheduledTime:a}))}},tabIndex:-1})]}),(0,Z.jsx)(`div`,{className:`w-32`,children:(0,Z.jsx)(`input`,{type:`text`,className:`w-full px-3 py-2 bg-bambu-dark border rounded-lg text-white focus:outline-none ${g?`border-bambu-dark-tertiary focus:border-bambu-green`:`border-red-500`}`,value:f,onChange:e=>w(e.target.value),placeholder:De(r)})})]}),(!m||!g)&&(0,Z.jsx)(`p`,{className:`mt-1 text-xs text-red-700 dark:text-red-400`,children:l(`printModal.invalidDateTime`)})]}),c&&(0,Z.jsxs)(`p`,{className:`flex items-start gap-1.5 text-sm text-bambu-gray`,children:[(0,Z.jsx)(xo,{className:`w-3.5 h-3.5 mt-0.5 flex-shrink-0`}),l(`printModal.awaitingReviewNote`)]}),!c&&e.scheduleType===`queue`&&(0,Z.jsxs)(`div`,{className:`flex items-center gap-2`,children:[(0,Z.jsx)(`input`,{type:`checkbox`,id:`requireManualStart`,checked:e.requireManualStart,onChange:n=>t({...e,requireManualStart:n.target.checked}),className:`rounded border-bambu-dark-tertiary bg-bambu-dark text-bambu-green focus:ring-bambu-green`}),(0,Z.jsxs)(`label`,{htmlFor:`requireManualStart`,className:`text-sm flex items-center gap-1 text-bambu-gray`,children:[(0,Z.jsx)(xo,{className:`w-3.5 h-3.5`}),l(`printModal.requireManualStart`)]})]}),(0,Z.jsxs)(`div`,{className:`flex items-center gap-2`,children:[(0,Z.jsx)(`input`,{type:`checkbox`,id:`requirePrevious`,checked:e.requirePreviousSuccess,onChange:n=>t({...e,requirePreviousSuccess:n.target.checked}),className:`rounded border-bambu-dark-tertiary bg-bambu-dark text-bambu-green focus:ring-bambu-green`}),(0,Z.jsx)(`label`,{htmlFor:`requirePrevious`,className:`text-sm text-bambu-gray`,children:l(`printModal.requirePreviousSuccess`)})]}),(0,Z.jsxs)(`div`,{className:`flex items-center gap-2`,children:[(0,Z.jsx)(`input`,{type:`checkbox`,id:`autoOffAfter`,checked:e.autoOffAfter,onChange:n=>t({...e,autoOffAfter:n.target.checked}),disabled:!i,className:`rounded border-bambu-dark-tertiary bg-bambu-dark text-bambu-green focus:ring-bambu-green disabled:opacity-50`}),(0,Z.jsxs)(`label`,{htmlFor:`autoOffAfter`,className:`text-sm flex items-center gap-1 ${i?`text-bambu-gray`:`text-bambu-gray/50`}`,children:[(0,Z.jsx)(Ko,{className:`w-3.5 h-3.5`}),l(`printModal.autoOffAfter`)]})]}),s&&(0,Z.jsxs)(`div`,{className:`flex items-center gap-2`,children:[(0,Z.jsx)(`input`,{type:`checkbox`,id:`gcodeInjection`,checked:e.gcodeInjection,onChange:n=>t({...e,gcodeInjection:n.target.checked}),className:`rounded border-bambu-dark-tertiary bg-bambu-dark text-bambu-green focus:ring-bambu-green`}),(0,Z.jsxs)(`label`,{htmlFor:`gcodeInjection`,className:`text-sm flex items-center gap-1 text-bambu-gray`,children:[(0,Z.jsx)(io,{className:`w-3.5 h-3.5`}),l(`printModal.gcodeInjection`,`Inject auto-print G-code`)]})]}),a&&e.scheduleType!==`queue`&&(0,Z.jsxs)(`div`,{className:`space-y-3`,children:[(0,Z.jsxs)(`div`,{className:`flex items-center gap-2`,children:[(0,Z.jsx)(`input`,{type:`checkbox`,id:`staggerEnabled`,checked:e.staggerEnabled,onChange:n=>t({...e,staggerEnabled:n.target.checked}),className:`rounded border-bambu-dark-tertiary bg-bambu-dark text-bambu-green focus:ring-bambu-green`}),(0,Z.jsxs)(`label`,{htmlFor:`staggerEnabled`,className:`text-sm flex items-center gap-1 text-bambu-gray`,children:[(0,Z.jsx)(ko,{className:`w-3.5 h-3.5`}),l(`printModal.staggerPrinterStarts`,`Stagger printer starts`)]})]}),e.staggerEnabled&&(0,Z.jsxs)(`div`,{className:`ml-6 space-y-3`,children:[(0,Z.jsxs)(`div`,{className:`flex gap-3`,children:[(0,Z.jsxs)(`div`,{className:`flex-1`,children:[(0,Z.jsx)(`label`,{className:`block text-xs text-bambu-gray mb-1`,children:l(`printModal.staggerGroupSize`,`Group size`)}),(0,Z.jsx)(bl,{min:1,max:o,value:e.staggerGroupSize,onChange:n=>t({...e,staggerGroupSize:n}),fallback:1,className:`w-full px-3 py-2 bg-bambu-dark border border-bambu-dark-tertiary rounded-lg text-white text-sm focus:outline-none focus:border-bambu-green`})]}),(0,Z.jsxs)(`div`,{className:`flex-1`,children:[(0,Z.jsx)(`label`,{className:`block text-xs text-bambu-gray mb-1`,children:l(`printModal.staggerInterval`,`Interval (min)`)}),(0,Z.jsx)(bl,{min:1,max:60,value:e.staggerIntervalMinutes,onChange:n=>t({...e,staggerIntervalMinutes:n}),fallback:1,className:`w-full px-3 py-2 bg-bambu-dark border border-bambu-dark-tertiary rounded-lg text-white text-sm focus:outline-none focus:border-bambu-green`})]})]}),o>0&&(()=>{let t=Math.ceil(o/e.staggerGroupSize),n=o%e.staggerGroupSize,r=(t-1)*e.staggerIntervalMinutes;return(0,Z.jsxs)(`p`,{className:`text-xs text-bambu-gray`,children:[l(`printModal.staggerPreview`,`{{printers}} printers → {{groups}} groups of {{size}}, starting every {{interval}} min`,{printers:o,groups:t,size:e.staggerGroupSize,interval:e.staggerIntervalMinutes}),n!==0&&e.staggerGroupSize<o?` (${l(`printModal.staggerLastGroup`,`last group: {{count}}`,{count:n})})`:``,t>1?` (${l(`printModal.staggerTotal`,`total: {{minutes}} min`,{minutes:r})})`:``]})})()]})]}),(0,Z.jsx)(`p`,{className:`text-xs text-bambu-gray`,children:e.scheduleType===`asap`?l(`printModal.helpAsap`):e.scheduleType===`scheduled`?l(`printModal.helpSchedule`):l(`printModal.helpQueue`)})]})}function vu({candidates:e,onReorder:t,plateByFile:n,onPlateChange:r,readOnly:i=!1,readOnlyNote:a}){let{t:s}=v(),c=B({queries:i?[]:e.map(e=>({queryKey:[`library-file-plates`,e.id],queryFn:()=>o.getLibraryFilePlates(e.id),staleTime:6e4}))}),l=(0,W.useMemo)(()=>{let t={};return e.forEach((e,n)=>{let r=c[n]?.data;r?.is_multi_plate&&r.plates.length>1&&(t[e.id]=r.plates.map(e=>({index:e.index,name:e.name})))}),t},[e,c]),u=(n,r)=>{if(r<0||r>=e.length)return;let i=[...e],[a]=i.splice(n,1);i.splice(r,0,a),t(i)};return(0,Z.jsxs)(`div`,{className:`mb-4`,children:[(0,Z.jsxs)(`div`,{className:`flex items-center gap-2 mb-2`,children:[(0,Z.jsx)(qo,{className:`w-4 h-4 text-bambu-gray`}),(0,Z.jsx)(`span`,{className:`text-sm text-bambu-gray`,children:s(`printModal.variants.title`)})]}),(0,Z.jsx)(`p`,{className:`text-xs text-bambu-gray mb-2`,children:i?a??s(`printModal.variants.help`):s(`printModal.variants.help`)}),(0,Z.jsx)(`div`,{className:`space-y-2`,children:e.map((t,a)=>{let o=l[t.id],c=t.sliced_for_model;return(0,Z.jsxs)(`div`,{className:`flex flex-wrap items-center gap-2 rounded border border-bambu-dark-tertiary p-2`,children:[(0,Z.jsxs)(`span`,{className:`text-xs font-mono text-bambu-gray w-5 shrink-0`,children:[a+1,`.`]}),(0,Z.jsx)(`span`,{className:`px-2 py-0.5 rounded-full bg-bambu-green/10 text-bambu-green text-xs shrink-0`,children:c||s(`printModal.variants.unknownModel`)}),(0,Z.jsx)(`span`,{className:`text-sm text-white truncate min-w-0 flex-1`,title:t.filename,children:t.filename}),o&&(0,Z.jsxs)(`label`,{className:`flex items-center gap-1 text-xs text-bambu-gray shrink-0`,children:[(0,Z.jsx)(ko,{className:`w-3 h-3`}),(0,Z.jsx)(`select`,{className:`bg-bambu-dark-secondary border border-bambu-dark-tertiary rounded px-1 py-0.5 text-xs text-white`,value:n[t.id]??o[0].index,onChange:e=>r(t.id,Number(e.target.value)),"aria-label":s(`printModal.variants.plateFor`,{filename:t.filename}),children:o.map(e=>(0,Z.jsx)(`option`,{value:e.index,children:e.name||s(`printModal.plateN`,{n:e.index})},e.index))})]}),!i&&(0,Z.jsxs)(`div`,{className:`flex items-center gap-1 shrink-0`,children:[(0,Z.jsx)(`button`,{type:`button`,onClick:()=>u(a,a-1),disabled:a===0,className:`p-1 rounded text-bambu-gray hover:text-white disabled:opacity-30`,"aria-label":s(`printModal.variants.moveUp`),children:(0,Z.jsx)(oe,{className:`w-3.5 h-3.5`})}),(0,Z.jsx)(`button`,{type:`button`,onClick:()=>u(a,a+1),disabled:a===e.length-1,className:`p-1 rounded text-bambu-gray hover:text-white disabled:opacity-30`,"aria-label":s(`printModal.variants.moveDown`),children:(0,Z.jsx)(ae,{className:`w-3.5 h-3.5`})})]})]},t.id)})})]})}function yu({costCenters:e,selectedCostCenterId:t,onChange:n}){let{t:r}=v();if(e.length===0)return null;let i=e.find(e=>e.id===t);return(0,Z.jsxs)(`div`,{className:`space-y-1`,children:[(0,Z.jsx)(`label`,{htmlFor:`printCostCenter`,className:`text-sm text-bambu-gray`,children:r(`printModal.costCenter`,`Cost center`)}),(0,Z.jsx)(`select`,{id:`printCostCenter`,value:t??``,onChange:e=>n(e.target.value?Number(e.target.value):null),className:`w-full px-3 py-2 text-sm bg-bambu-dark border border-bambu-dark-tertiary rounded text-white focus:outline-none focus:ring-1 focus:ring-bambu-green`,children:e.map(e=>(0,Z.jsxs)(`option`,{value:e.id,children:[e.name,e.is_private?` (${r(`printModal.personalDefault`,`Personal`)})`:``]},e.id))}),i?.budget_mode===`none`&&(0,Z.jsx)(`p`,{className:`text-xs text-bambu-gray`,children:r(`printModal.unlimitedNoBudget`,`Unlimited – no budget limit is set.`)})]})}var bu={bed_levelling:`auto`,flow_cali:`auto`,vibration_cali:!0,layer_inspect:!1,timelapse:!1,nozzle_offset_cali:`auto`,confirm_outcome:!1,preheat_override:`inherit`,preheat_chamber_target_override:null},xu={scheduleType:`asap`,scheduledTime:``,requireManualStart:!1,requirePreviousSuccess:!1,autoOffAfter:!1,gcodeInjection:!1,staggerEnabled:!1,staggerGroupSize:2,staggerIntervalMinutes:5};function Su(e,t){let n=e=>(e||``).replace(`#`,``).toLowerCase().slice(0,6);return(e.type||``).toUpperCase()===(t.type||``).toUpperCase()&&n(e.color)===n(t.color)}function Cu(e,t){let n=e=>{let n=t[e.slot_id];return!!n&&!Su(n,e)};return!e?.filaments||!e.filaments.some(n)?e:{...e,filaments:e.filaments.map(e=>n(e)?{...e,type:t[e.slot_id].type,color:t[e.slot_id].color,tray_info_idx:``}:e)}}function wu({mode:e,archiveId:t,libraryFileId:n,archiveName:r,queueItem:i,initialSelectedPrinterIds:a,onClose:s,onSuccess:c,projectId:l,cleanupLibraryAfterDispatch:u,variantFiles:d}){let{t:f}=v(),p=F(),{showToast:m}=fe(),{hasPermission:h,hasAnyPermission:g,user:_}=Os(),y=!g(`queue:start_unreviewed`,`queue:update_all`),b=!!n&&!t,x=e===`edit-queue-item`,S=e===`create`&&(d?.length??0)>1,C=e===`edit-queue-item`&&(i?.variants?.length??0)>1?i.variants.map(e=>({id:e.library_file_id,filename:e.filename,sliced_for_model:e.target_model})):[],w=C.length>0,[T,E]=(0,W.useState)(d??[]),[D,O]=(0,W.useState)({}),[k,A]=(0,W.useState)(()=>e===`edit-queue-item`&&i?.printer_id?[i.printer_id]:a?.length?a:[]),[j,M]=(0,W.useState)(()=>e===`edit-queue-item`&&i?.plate_id!=null?new Set([i.plate_id]):new Set),N=j.size===1?[...j][0]:null,[P,I]=(0,W.useState)(1),[ee,te]=(0,W.useState)({}),[ne,L]=(0,W.useState)(()=>e===`edit-queue-item`&&i?{bed_levelling:i.bed_levelling??bu.bed_levelling,flow_cali:i.flow_cali??bu.flow_cali,vibration_cali:i.vibration_cali??bu.vibration_cali,layer_inspect:i.layer_inspect??bu.layer_inspect,timelapse:i.timelapse??bu.timelapse,nozzle_offset_cali:i.nozzle_offset_cali??bu.nozzle_offset_cali,confirm_outcome:i.confirm_outcome??bu.confirm_outcome,preheat_override:i.preheat_override??bu.preheat_override,preheat_chamber_target_override:i.preheat_chamber_target_override??bu.preheat_chamber_target_override}:bu),[R,re]=(0,W.useState)(()=>{if(e===`edit-queue-item`&&i){let e=`queue`;i.scheduled_time&&!Jc(i.scheduled_time)&&(e=`scheduled`);let t=``;return i.scheduled_time&&!Jc(i.scheduled_time)&&(t=Me(je(i.scheduled_time)??new Date)),{scheduleType:e,scheduledTime:t,requireManualStart:i.manual_start,requirePreviousSuccess:i.require_previous_success,autoOffAfter:i.auto_off_after,gcodeInjection:i.gcode_injection??!1,staggerEnabled:!1,staggerGroupSize:xu.staggerGroupSize,staggerIntervalMinutes:xu.staggerIntervalMinutes}}return xu}),[V,ae]=(0,W.useState)(()=>{if(e===`edit-queue-item`&&i?.ams_mapping&&Array.isArray(i.ams_mapping)){let e={};return i.ams_mapping.forEach((t,n)=>{t!==-1&&(e[n+1]=t)}),e}return{}}),[oe,se]=(0,W.useState)(()=>e===`edit-queue-item`?i?.printer_id??null:null),[ce,le]=(0,W.useState)({}),[H,ue]=(0,W.useState)(()=>S||e===`edit-queue-item`&&i?.target_model?`model`:`printer`),[U,pe]=(0,W.useState)(()=>e===`edit-queue-item`&&i?.target_model?i.target_model:null),[me,ve]=(0,W.useState)(()=>e===`edit-queue-item`&&i?.target_location?i.target_location:null),[Se,Ce]=(0,W.useState)(()=>e===`edit-queue-item`?i?.cost_center_id??null:null),[we,Te]=(0,W.useState)(i?.estimated_cost??null),[Ee,De]=(0,W.useState)({}),[Oe,ke]=(0,W.useState)(()=>{if(e===`edit-queue-item`&&i?.filament_overrides){let e={};for(let t of i.filament_overrides)e[t.slot_id]={type:t.type,color:t.color};return e}return{}}),[Ae,Ne]=(0,W.useState)(()=>{if(e===`edit-queue-item`&&i?.filament_overrides){let e={};for(let t of i.filament_overrides)e[t.slot_id]=t.force_color_match===!0;return e}return{}}),[Pe]=(0,W.useState)(()=>e===`edit-queue-item`&&i?.printer_id?[i.printer_id]:[]),[Fe]=(0,W.useState)(()=>e===`edit-queue-item`&&i?i.plate_id:null),[Ie,Le]=(0,W.useState)(!1),[Re,ze]=(0,W.useState)({current:0,total:0}),[G,Be]=(0,W.useState)(null),[Ve,He]=(0,W.useState)(new Set),Ue=k.length,We=k.length>0?k[0]:null,{data:Ge}=z({queryKey:[`settings`],queryFn:o.getSettings}),Ke=(0,W.useRef)(!1);(0,W.useEffect)(()=>{!Ge||Ke.current||e===`edit-queue-item`||(Ke.current=!0,L({bed_levelling:Ge.default_bed_levelling??bu.bed_levelling,flow_cali:Ge.default_flow_cali??bu.flow_cali,vibration_cali:Ge.default_vibration_cali??bu.vibration_cali,layer_inspect:Ge.default_layer_inspect??bu.layer_inspect,timelapse:Ge.default_timelapse??bu.timelapse,nozzle_offset_cali:Ge.default_nozzle_offset_cali??bu.nozzle_offset_cali,confirm_outcome:Ge.default_confirm_outcome??bu.confirm_outcome,preheat_override:bu.preheat_override,preheat_chamber_target_override:bu.preheat_chamber_target_override}))},[Ge,e]);let qe=(0,W.useRef)(!1);(0,W.useEffect)(()=>{!Ge||qe.current||e===`edit-queue-item`||(qe.current=!0,re(e=>({...e,staggerGroupSize:Ge.stagger_group_size??e.staggerGroupSize,staggerIntervalMinutes:Ge.stagger_interval_minutes??e.staggerIntervalMinutes})))},[Ge,e]);let Je=pc(Ge?.currency||`USD`),Ye=Ge?.default_filament_cost??0,Xe=Ge?.billing_enabled===!0,{data:Ze,isLoading:Qe}=z({queryKey:[`printers`],queryFn:o.getPrinters}),{data:$e,isLoading:et}=z({queryKey:[`finance`,`cost-centers`,`mine`],queryFn:o.getMyCostCenters,enabled:!!_&&Xe}),tt=(0,W.useMemo)(()=>($e||[]).filter(e=>e.can_print&&e.is_active),[$e]),nt=(0,W.useMemo)(()=>tt.find(e=>e.id===Se)??null,[tt,Se]);(0,W.useEffect)(()=>{tt.length!==0&&(Se!=null&&tt.some(e=>e.id===Se)||Ce(tt.find(e=>e.is_private)?.id??tt[0].id))},[tt,Se]);let rt=B({queries:k.map(e=>({queryKey:[`printer-inventory-remain`,e],queryFn:()=>o.getInventoryRemain(e),staleTime:30*1e3,refetchOnMount:`always`,enabled:k.length>0}))}),it=(0,W.useMemo)(()=>{let e=new Map;return k.forEach((t,n)=>{let r=rt[n]?.data?.inventory_remain_g;if(!r)return;let i=new Map;Object.entries(r).forEach(([e,t])=>{let n=Number(e);Number.isNaN(n)||i.set(n,t)}),e.set(t,i)}),e},[k,rt]),at=(0,W.useMemo)(()=>{let e=new Map;return k.forEach((t,n)=>{let r=rt[n]?.data?.slot_materials;if(!r)return;let i=new Map;r.forEach(e=>i.set(e.global_tray_id,e)),e.set(t,i)}),e},[k,rt]),{data:ot}=z({queryKey:[`archive`,t],queryFn:()=>o.getArchive(t),enabled:!!t&&!b}),{data:st}=z({queryKey:[`library-file`,n],queryFn:()=>o.getLibraryFile(n),enabled:b&&!!n}),ct=ot?.sliced_for_model||st?.sliced_for_model||null,lt=(0,W.useMemo)(()=>b?void 0:Gl(ot?.extra_data,We),[b,ot?.extra_data,We]),{data:ut,isError:dt}=z({queryKey:[`archive-plates`,t],queryFn:()=>o.getArchivePlates(t),enabled:!!t&&!b,retry:!1}),{data:ft}=z({queryKey:[`library-file-plates`,n],queryFn:()=>o.getLibraryFilePlates(n),enabled:b&&!!n}),pt=b?ft:ut,{data:mt,isError:ht}=z({queryKey:[`archive-filaments`,t,N],queryFn:()=>o.getArchiveFilamentRequirements(t,N??void 0),enabled:!!t&&!b&&(N!==null||!pt?.is_multi_plate),retry:!1}),{data:gt}=z({queryKey:[`library-file-filaments`,n,N],queryFn:()=>o.getLibraryFileFilamentRequirements(n,N??void 0),enabled:b&&!!n&&(N!==null||!pt?.is_multi_plate)}),_t=!b&&(dt||ht),vt=b?gt:mt,yt=(0,W.useMemo)(()=>Cu(vt,Oe),[vt,Oe]),{data:bt}=z({queryKey:[`available-filaments`,U,me],queryFn:()=>o.getAvailableFilaments(U,me??void 0),enabled:H===`model`&&!!U}),xt=(0,W.useMemo)(()=>Array.from(new Set(T.map(e=>e.sliced_for_model).filter(e=>!!e))),[T]),St=B({queries:S?xt.map(e=>({queryKey:[`available-filaments`,e,me],queryFn:()=>o.getAvailableFilaments(e,me??void 0)})):[]}),Ct=(0,W.useMemo)(()=>{let e=new Set,t=[];for(let n of St)for(let r of n.data??[]){let n=`${r.type}|${r.color}|${r.tray_info_idx}`;e.has(n)||(e.add(n),t.push(r))}return t},[St]),wt=S?Ct:bt,{data:Tt,isLoading:Et}=z({queryKey:[`printer-status`,We],queryFn:()=>o.getPrinterStatus(We),enabled:!!We}),Dt=Qc(Ge?.prefer_lowest_filament,Tt?.ams_filament_backup),Ot=async()=>{if(R.scheduleType!==`asap`||H!==`printer`||k.length===0)return!1;try{return(await Promise.all(k.map(e=>p.fetchQuery({queryKey:[`printer-status`,e],queryFn:()=>o.getPrinterStatus(e),staleTime:0})))).some(e=>!Bl(e))}catch{return!0}},{amsMapping:kt}=Ml(yt,Tt,V,Dt,We?it.get(We):void 0),At=(0,W.useMemo)(()=>[...j].sort((e,t)=>e-t),[j]),jt=j.size>1,Mt=B({queries:(jt?At:[]).map(e=>({queryKey:b?[`library-file-filaments`,n,e]:[`archive-filaments`,t,e],queryFn:()=>b?o.getLibraryFileFilamentRequirements(n,e):o.getArchiveFilamentRequirements(t,e),enabled:b?!!n:!!t,retry:!1}))}),Nt=Mt.some(e=>e.isPending),Pt=Mt.some(e=>e.isError),Ft=(0,W.useMemo)(()=>{let e=new Map;return At.forEach((t,n)=>{let r=Mt[n]?.data;r&&e.set(t,r)}),e},[At,Mt.map(e=>e.dataUpdatedAt).join(`|`)]),It=(0,W.useMemo)(()=>{let e=new Map;for(let[t,n]of Ft)e.set(t,Cu(n,Oe)??n);return e},[Ft,Oe]),[Lt,Rt]=(0,W.useState)({}),[zt,Bt]=(0,W.useState)(()=>{if(e===`edit-queue-item`&&i?.nozzle_rack_choice){let e={};for(let[t,n]of Object.entries(i.nozzle_rack_choice)){let r=Number(t);Number.isInteger(r)&&Number.isInteger(n)&&(e[r]=n)}return e}return{}}),[Vt,Ht]=(0,W.useState)({}),Ut=(0,W.useMemo)(()=>{let e=new Map;if(!jt||!We||k.length!==1)return e;let t=El(Tt),n=Tt?.fila_switch?.installed===!0,r=it.get(We);for(let i of At){let a=It.get(i);if(!a)continue;let o=Al(a,t,Lt[i]??{},Dt,r,n);e.set(i,jl(o))}return e},[jt,We,Tt,it,At,It,Lt,Dt,k.length]),Wt=Fl(k,Ze,yt,V,ce,le,Ge?.prefer_lowest_filament,it,oe);(0,W.useEffect)(()=>{pt?.plates&&pt.plates.length>=1&&j.size===0&&M(new Set([pt.plates[0].index]))},[pt,j.size]),(0,W.useEffect)(()=>{if(!S||!n)return;let e=D[n];e!=null&&M(t=>t.size===1&&t.has(e)?t:new Set([e]))},[S,n,D]),(0,W.useEffect)(()=>{if(e===`edit-queue-item`)return;let t=Ze?.filter(e=>e.is_active)||[];t.length===1&&k.length===0&&A([t[0].id])},[e,Ze,k.length]),(0,W.useEffect)(()=>{e===`edit-queue-item`?(JSON.stringify(k.sort())!==JSON.stringify(Pe.sort())||N!==Fe)&&(ae({}),Rt({}),le({}),He(new Set)):(ae({}),Rt({}),le({}),He(new Set))},[e,k,N,Pe,Fe]);let[Gt,Kt]=(0,W.useState)(U),[qt,Jt]=(0,W.useState)(N);(0,W.useEffect)(()=>{let t=U!==null&&U!==Gt,n=N!==qt;!t&&!n||(t&&Kt(U),n&&Jt(N),!(t&&!n&&Gt===null)&&(e!==`edit-queue-item`||Gt!==null)&&(ke({}),Ne({})))},[U,N,Gt,qt,e]),(0,W.useEffect)(()=>{H!==`model`||U||!ct||Ze?.some(e=>e.is_active&&e.model===ct)&&pe(ct)},[H,U,ct,Ze]),(0,W.useEffect)(()=>{if(!Ge?.per_printer_mapping_expanded||k.length<=1)return;let e=k.filter(e=>{if(Ve.has(e))return!1;let t=Wt.printerResults.find(t=>t.printerId===e);return t&&t.status&&!t.isLoading});e.length>0&&(He(t=>{let n=new Set(t);return e.forEach(e=>n.add(e)),n}),e.forEach(e=>{Wt.autoConfigurePrinter(e)}))},[Ge?.per_printer_mapping_expanded,k,Ve,Wt]),(0,W.useEffect)(()=>{let e=e=>{e.key===`Escape`&&!Ie&&s()};return window.addEventListener(`keydown`,e),()=>window.removeEventListener(`keydown`,e)},[s,Ie]);let Yt=pt?.is_multi_plate??!1,Xt=pt?.plates??[],Zt=(0,W.useMemo)(()=>{if(!G||G.length===0)return``;let e=G.map(e=>e.pooled?f(`printModal.insufficientFilamentLinePooled`,{printer:e.printerName,slot:e.slotLabel,required:Math.round(e.requiredGrams),remaining:Math.round(e.remainingGrams)}):f(`printModal.insufficientFilamentLine`,{printer:e.printerName,slot:e.slotLabel,required:Math.round(e.requiredGrams),remaining:Math.round(e.remainingGrams)}));return[f(`printModal.insufficientFilamentMessage`),...e].join(`
- `)},[G,f]),Qt=ie({mutationFn:e=>o.addToQueue(e)}),$t=ie({mutationFn:e=>o.updateQueueItem(i.id,e),onSuccess:()=>{p.invalidateQueries({queryKey:[`queue`]}),m(`Queue item updated`),c?.(),s()},onError:e=>{m(e.message||`Failed to update queue item`,`error`)}}),en=(e,t)=>jt?t===null||k.length!==1?void 0:Ut.get(t):k.length>1||oe!==null&&oe!==e?Wt.getFinalMapping(e):kt,tn=(t,n,r)=>{if(!(e!==`edit-queue-item`||!Array.isArray(i?.ams_mapping))&&!(t!==i.printer_id||n!==Fe))return i.ams_mapping[r-1]},nn=(e,t,n)=>{if(!n)return!1;let r=jt?t==null?void 0:It.get(t)?.filaments:yt?.filaments;if(!r)return!1;let i=El(k.length>1?Wt.printerResults.find(t=>t.printerId===e)?.status:Tt);return r.some(r=>{let a=r.slot_id??0,o=a>0?n[a-1]:void 0;if(o==null||o<0||tn(e,t,a)===o)return!1;let s=i.find(e=>e.globalTrayId===o);return!!s?.type&&!!r.type&&!Mc(s.type,r.type)})},rn=y||(R.scheduleType===`queue`?R.requireManualStart:R.scheduleType===`scheduled`&&!!i?.manual_start),an=async(a,d)=>{if(a?.preventDefault(),Xe&&nt==null){m(f(`printModal.noPrintableCostCenters`),`error`);return}if(!d?.skipFilamentCheck&&!Ge?.disable_filament_warnings&&!x&&H===`printer`){let e=[],t=jt?At.map(e=>({plateId:e,reqs:Ft.get(e)?.filaments??[]})):[{plateId:N,reqs:vt?.filaments??[]}];if(t.some(e=>e.reqs.length>0)&&at.size>0)for(let n of k){let r=k.length>1?Wt.printerResults.find(e=>e.printerId===n)?.status:Tt,i=El(r),a=new Map(i.map(e=>[e.globalTrayId,e.label])),o=at.get(n),s=Ze?.find(e=>e.id===n)?.name??`Printer ${n}`;if(!o||o.size===0)continue;let c=new Map;for(let e of t){let t=en(n,e.plateId);t&&e.reqs.forEach(e=>{if(!e.slot_id||e.slot_id<=0)return;let n=t[e.slot_id-1];!Number.isFinite(n)||n<0||c.set(n,(c.get(n)??0)+e.used_grams)})}let l=r?.ams_filament_backup===!0,u=e=>`${e.material_key}#${e.extruder}`,d=new Map,f=new Map,p=new Map;if(l){o.forEach(e=>{let t=u(e);d.set(t,(d.get(t)??0)+e.remaining_g),f.set(t,(f.get(t)??0)+1)});for(let[e,t]of c){let n=o.get(e);if(!n)continue;let r=u(n);p.set(r,(p.get(r)??0)+t)}}for(let[t,n]of c){let r=o.get(t);if(!r)continue;let i=a.get(t)??`Tray ${t}`;if(l){let t=u(r),n=d.get(t)??0,a=p.get(t)??0;if(n>=a)continue;e.push({printerName:s,slotLabel:i,requiredGrams:a,remainingGrams:n,pooled:(f.get(t)??1)>1});continue}r.remaining_g>=n||e.push({printerName:s,slotLabel:i,requiredGrams:n,remainingGrams:r.remaining_g})}}if(e.length>0){Be(e);return}}if(H===`printer`&&k.length===0){m(`Please select at least one printer`,`error`);return}if(!S&&H===`model`&&!U){m(`Please select a target printer model`,`error`);return}if(!S&&H===`model`&&!Rl(ct,U)){m(`File was sliced for ${ct} and cannot be dispatched to ${U} printers`,`error`);return}Le(!0);let h=j.size>1?Xt.filter(e=>j.has(e.index)):[null],g=H===`model`?h.length:k.length*h.length;ze({current:0,total:g});let _={success:0,failed:0,errors:[]},v=new Map((e===`edit-queue-item`?i?.filament_overrides??[]:[]).map(e=>[e.slot_id,e])),C=(e,t,n)=>{let r=v.get(e);return r?.tray_info_idx&&Su(r,{type:t,color:n})?{tray_info_idx:r.tray_info_idx}:{}},w=e=>{let t=[];if(e?.filaments)for(let n of e.filaments){let e=Oe[n.slot_id],r=Ae[n.slot_id]??!1,i=e?.type??n.type,a=e?.color??n.color;(e||r)&&t.push({slot_id:n.slot_id,type:i,color:a,color_name:rc(a),...C(n.slot_id,i,a),force_color_match:r})}else for(let[e,{type:n,color:r}]of Object.entries(Oe)){let i=parseInt(e,10),a=Ae[i]??!1;t.push({slot_id:i,type:n,color:r,color_name:rc(r),...C(i,n,r),force_color_match:a})}return t.length>0?t:void 0},E=w(vt),O=e=>jt&&e!==null?w(Ft.get(e)):E,A=e=>{let t=O(e)?.filter(e=>Oe[e.slot_id]);return t&&t.length>0?t:void 0};if(S){try{await o.addToQueue({variants:T.map(e=>({library_file_id:e.id,plate_id:D[e.id]??null,filament_overrides:E})),target_location:me,require_previous_success:R.requirePreviousSuccess,auto_off_after:R.autoOffAfter,gcode_injection:R.gcodeInjection,manual_start:y||R.scheduleType===`queue`&&R.requireManualStart,scheduled_time:R.scheduleType===`scheduled`&&R.scheduledTime?new Date(R.scheduledTime).toISOString():void 0,quantity:P,...ne,project_id:l??void 0}),m(f(`printModal.variants.queued`,{count:T.length}),`success`),p.invalidateQueries({queryKey:[`queue`]}),c?.(),s()}catch(e){m(e instanceof Error?e.message:String(e),`error`)}finally{Le(!1)}return}let M=h.map((e,t)=>{let n=e?e.index:N;return{plate_id:n,plate_name:e&&e.name||null,quantity_target:un(n),sort_order:t}}),F=M.reduce((e,t)=>e+t.quantity_target,0),I=e===`create`&&(h.length>1||F>1)&&(H===`model`||k.length===1),ee=null;if(I)try{let e=(r||``).replace(/\.gcode\.3mf$/i,``).replace(/\.3mf$/i,``),i=h.length>1?`${e||`Batch`} · ${h.length} plates`:`${e||`Batch`} ×${F}`;ee=(await o.createBatch({name:i,archive_id:b?void 0:t,library_file_id:b?n:void 0,plates:M})).id}catch{ee=null}let te=0,L=(e,t=1)=>{R.scheduleType===`asap`&&(e.insert_at_top=!0,e.insert_position=te+1,te+=t)},z=e=>{let t=e!=null&&jt?Vt[e]:zt;return t&&Object.keys(t).length>0?t:void 0},re=(e,r)=>{let i=r===void 0?N:r,a=i!=null&&jt?Ee[i]??null:we;return{printer_id:H===`printer`?e:null,target_model:H===`model`?U:null,target_location:H===`model`?me:null,filament_overrides:H===`model`?O(i):A(i),archive_id:b?void 0:t,library_file_id:b?n:void 0,require_previous_success:R.requirePreviousSuccess,auto_off_after:R.autoOffAfter,gcode_injection:R.gcodeInjection,manual_start:y||R.scheduleType===`queue`&&R.requireManualStart,skip_filament_check:d?.skipFilamentCheck===!0||e!=null&&nn(e,i,en(e,i))?!0:void 0,ams_mapping:e?en(e,i):void 0,nozzle_rack_choice:e?z(i):void 0,plate_id:i,scheduled_time:R.scheduleType===`scheduled`&&R.scheduledTime?new Date(R.scheduledTime).toISOString():void 0,...ne,project_id:l??void 0,cost_center_id:Xe?Se:void 0,estimated_cost:Xe&&Se!=null?a:void 0,batch_id:ee??void 0,cleanup_library_after_dispatch:u}};if(H===`model`){let t=0;for(let n of h){t++,ze({current:t,total:g});let r=n?n.index:N;try{if(e===`edit-queue-item`&&!n){let e={printer_id:null,target_model:U,target_location:me,filament_overrides:E||null,require_previous_success:R.requirePreviousSuccess,auto_off_after:R.autoOffAfter,gcode_injection:R.gcodeInjection,manual_start:rn,ams_mapping:void 0,plate_id:r,scheduled_time:R.scheduleType===`scheduled`&&R.scheduledTime?new Date(R.scheduledTime).toISOString():null,...ne,cost_center_id:Xe?Se:void 0,estimated_cost:Xe&&Se!=null?we:void 0};await $t.mutateAsync(e)}else{let e=re(null,r),t=un(r);t>1&&(e.quantity=t),L(e,t),await Qt.mutateAsync(e)}_.success++}catch(e){_.failed++;let t=n?n.name||`Plate ${n.index}`:``;_.errors.push(t?`${t}: ${e.message}`:e.message)}}}else{let e=R.staggerEnabled&&!x&&k.length>1,t=e?R.scheduleType===`scheduled`&&R.scheduledTime?new Date(R.scheduledTime).getTime():Date.now():0,n=0;for(let r of h){let i=r?r.index:N;for(let a=0;a<k.length;a++){let o=k[a];n++,ze({current:n,total:g});try{if(x&&n===1){let e=en(o,i),t={printer_id:o,target_model:null,target_location:null,filament_overrides:A(i)??null,require_previous_success:R.requirePreviousSuccess,auto_off_after:R.autoOffAfter,gcode_injection:R.gcodeInjection,manual_start:rn,ams_mapping:e,skip_filament_check:nn(o,i,e)?!0:void 0,nozzle_rack_choice:z(i)??null,plate_id:i,scheduled_time:R.scheduleType===`scheduled`&&R.scheduledTime?new Date(R.scheduledTime).toISOString():null,...ne,cost_center_id:Xe?Se:void 0,estimated_cost:Xe&&Se!=null?i!=null&&jt?Ee[i]??null:we:void 0};await $t.mutateAsync(t)}else{let n=re(o,i),r=un(i);if(r>1&&(n.quantity=r),L(n,r),e){let e=Math.floor(a/R.staggerGroupSize);if(e>0){let r=e*R.staggerIntervalMinutes*6e4;n.scheduled_time=new Date(t+r).toISOString()}}await Qt.mutateAsync(n)}_.success++}catch(e){_.failed++;let t=Ze?.find(e=>e.id===o)?.name||`Printer ${o}`,n=r?r.name||`Plate ${r.index}`:``,i=n?`${t} (${n})`:t;_.errors.push(`${i}: ${e.message}`)}}}}Le(!1),_.failed===0?(x?e===`edit-queue-item`&&m(`Queue item updated`):_.success===1?m(await Ot()?f(`queue.printQueuedWillStartWhenIdle`):H===`model`?`Queued for any ${U}`:f(`queue.printQueued`)):m(await Ot()?f(`queue.printQueuedWillStartWhenIdle`):f(`queue.itemsQueued`,{count:_.success})),p.invalidateQueries({queryKey:[`queue`]}),c?.(),s()):_.success===0?m(`Failed: ${_.errors[0]}`,`error`):(m(`${_.success} succeeded, ${_.failed} failed`,`error`),p.invalidateQueries({queryKey:[`queue`]}))},on=Ie||$t.isPending,sn=(0,W.useMemo)(()=>!(on||Xe&&(et||nt==null)||H===`printer`&&k.length===0||!S&&H===`model`&&!U||!S&&H===`model`&&!Rl(ct,U)||Yt&&j.size===0||Nt||Pt||H===`printer`&&k.length===1&&Et),[k.length,H,U,ct,Yt,j.size,on,Nt,Pt,Et,S,Xe,et,nt]),cn=H===`printer`&&k.length>1?1:P,ln=e===`create`&&!S&&Yt&&Xt.length>1,un=e=>!ln||e==null?cn:H===`printer`&&k.length>1?1:Math.max(1,ee[e]??1);(0,W.useEffect)(()=>{e===`create`&&R.gcodeInjection&&!Ge?.gcode_snippets&&re(e=>({...e,gcodeInjection:!1}))},[e,Ge?.gcode_snippets,R.gcodeInjection]);let dn=x?{title:f(`queue.editQueueItem`),icon:Vo,submitText:f(`common.save`),submitIcon:Vo,loadingText:Re.total>1?f(`queue.savingProgress`,{current:Re.current,total:Re.total}):f(`common.saving`)}:{title:f(`common.print`),icon:qo,submitText:f(`common.print`),submitIcon:qo,loadingText:Re.total>1?f(`queue.addingProgress`,{current:Re.current,total:Re.total}):f(`queue.adding`)},fn=dn.icon,pn=dn.submitIcon,K=We&&j.size<=1&&(b||(Yt?N!==null:!0));(0,W.useEffect)(()=>{(!K||_t||k.length!==1)&&Te(null)},[_t,k.length,K]);let mn=!!We&&jt&&k.length===1,hn=H===`model`&&(S||!!U)&&!!wt&&wt.length>0,gn=(0,W.useMemo)(()=>new Set([`H2D`,`H2DPRO`,`H2C`,`X2D`]),[]),_n=(0,W.useMemo)(()=>H===`model`?U?gn.has(U.toUpperCase().replace(/[\s-]/g,``)):!1:!Ze||k.length===0?!1:k.some(e=>Ze.find(t=>t.id===e)?.nozzle_count===2),[H,U,Ze,k,gn]);return(0,Z.jsxs)(`div`,{className:`fixed inset-0 bg-black/70 flex items-center justify-center z-50 p-4`,onClick:Ie?void 0:s,children:[(0,Z.jsx)(be,{className:`w-full max-w-4xl max-h-[90vh] overflow-y-auto`,onClick:e=>e.stopPropagation(),children:(0,Z.jsxs)(ye,{className:`p-0`,children:[(0,Z.jsxs)(`div`,{className:`flex items-center justify-between p-4 border-b border-bambu-dark-tertiary`,children:[(0,Z.jsxs)(`div`,{className:`flex items-center gap-2`,children:[(0,Z.jsx)(fn,{className:`w-5 h-5 text-bambu-green`}),(0,Z.jsx)(`h2`,{className:`text-lg font-semibold text-white`,children:dn.title})]}),(0,Z.jsx)(xe,{variant:`ghost`,size:`sm`,onClick:s,disabled:Ie,children:(0,Z.jsx)(_e,{className:`w-5 h-5`})})]}),(0,Z.jsxs)(`form`,{onSubmit:an,className:`p-4 space-y-4`,children:[(0,Z.jsxs)(`p`,{className:`text-sm text-bambu-gray`,children:[(0,Z.jsx)(`span`,{className:`block text-bambu-gray mb-1`,children:`Print Job`}),(0,Z.jsx)(`span`,{className:`text-white font-medium truncate block`,children:r})]}),(()=>{if(!Xt.length)return null;let e=Wl((N==null?Xt[0]:Xt.find(e=>e.index===N))?.bed_type);return e?(0,Z.jsxs)(`p`,{className:`flex items-center gap-1.5 text-xs text-bambu-gray -mt-2`,title:e.label,children:[(0,Z.jsx)(`img`,{src:e.icon,alt:``,className:`w-4 h-4 object-contain flex-shrink-0`}),(0,Z.jsx)(`span`,{className:`truncate`,children:e.label})]}):null})(),!S&&(0,Z.jsx)(cu,{plates:Xt,isMultiPlate:Yt,selectedPlates:j,onToggle:e=>{M(t=>{let n=new Set(t);return x?(n.clear(),n.add(e)):n.has(e)?n.delete(e):n.add(e),n})},onSelectAll:x?void 0:()=>M(new Set(Xt.map(e=>e.index))),onDeselectAll:x?void 0:()=>M(new Set),multiSelect:!x,quantities:ln?ee:void 0,onQuantityChange:ln?(e,t)=>te(n=>({...n,[e]:t})):void 0}),S&&(0,Z.jsx)(vu,{candidates:T,onReorder:E,plateByFile:D,onPlateChange:(e,t)=>O(n=>({...n,[e]:t}))}),w&&(0,Z.jsx)(vu,{candidates:C,readOnly:!0,readOnlyNote:f(`printModal.variants.editNote`),onReorder:()=>{},plateByFile:{},onPlateChange:()=>{}}),!S&&!w&&!a?.length&&(0,Z.jsx)(du,{printers:Ze||[],selectedPrinterIds:k,onMultiSelect:A,isLoading:Qe,allowMultiple:!0,showInactive:e===`edit-queue-item`,disableBusy:!1,printerMappingResults:Wt.printerResults,filamentReqs:jt?void 0:yt,onAutoConfigurePrinter:Wt.autoConfigurePrinter,onUpdatePrinterConfig:Wt.updatePrinterConfig,assignmentMode:H,onAssignmentModeChange:ue,targetModel:U,onTargetModelChange:pe,targetLocation:me,onTargetLocationChange:ve,slicedForModel:ct}),hn&&!jt&&vt&&(0,Z.jsx)(su,{filamentReqs:vt,availableFilaments:wt,overrides:Oe,onChange:ke,forceColorMatch:Ae,onForceColorMatchChange:(e,t)=>Ne(n=>({...n,[e]:t}))}),hn&&jt&&At.map((e,t)=>{let n=Xt.find(t=>t.index===e),r=Ft.get(e);return r?(0,Z.jsx)(su,{plateLabel:n?.name||f(`printModal.plateN`,`Plate {{n}}`,{n:e}),showHint:t===0,filamentReqs:r,availableFilaments:bt,overrides:Oe,onChange:ke,forceColorMatch:Ae,onForceColorMatchChange:(e,t)=>Ne(n=>({...n,[e]:t}))},e):null}),ct&&H===`printer`&&k.length===1&&(()=>{let e=Ze?.find(e=>e.id===k[0]);return e&&e.model&&ct!==e.model?(0,Z.jsxs)(`div`,{className:`p-3 mb-2 bg-yellow-50 dark:bg-yellow-500/10 border border-yellow-300 dark:border-yellow-500/30 rounded-lg flex items-center gap-2`,children:[(0,Z.jsx)(ge,{className:`w-4 h-4 text-yellow-600 dark:text-yellow-400 flex-shrink-0`}),(0,Z.jsxs)(`span`,{className:`text-sm text-yellow-700 dark:text-yellow-400`,children:[`File was sliced for `,ct,`, but printing on `,e.model]})]}):null})(),_t&&(0,Z.jsxs)(`div`,{className:`flex items-start gap-2 p-3 mb-2 bg-orange-50 dark:bg-orange-500/10 border border-orange-300 dark:border-orange-500/30 rounded-lg text-sm`,children:[(0,Z.jsx)(de,{className:`w-4 h-4 text-orange-600 dark:text-orange-400 mt-0.5 flex-shrink-0`}),(0,Z.jsx)(`p`,{className:`text-orange-700 dark:text-orange-400`,children:`Archive data unavailable. The source file may have been deleted. Filament mapping is disabled.`})]}),Pt&&(0,Z.jsxs)(`div`,{className:`flex items-start gap-2 p-3 mb-2 bg-orange-50 dark:bg-orange-500/10 border border-orange-300 dark:border-orange-500/30 rounded-lg text-sm`,children:[(0,Z.jsx)(de,{className:`w-4 h-4 text-orange-600 dark:text-orange-400 mt-0.5 flex-shrink-0`}),(0,Z.jsx)(`p`,{className:`text-orange-700 dark:text-orange-400`,children:f(`printModal.plateFilamentsUnreadable`,`The filaments of a selected plate could not be read, so it can't be mapped. Deselect it to queue the others.`)})]}),K&&!_t&&k.length===1&&(0,Z.jsx)(ou,{printerId:We,filamentReqs:yt,manualMappings:V,onManualMappingChange:e=>{se(We),ae(e)},onEstimatedCostChange:Te,budgetAvailable:Xe?nt?.budget_available??null:null,quantity:cn,defaultExpanded:!!a?.length||(Ge?.per_printer_mapping_expanded??!1),currencySymbol:Je,defaultCostPerKg:Ye,forceColorMatch:Ae,onForceColorMatchChange:(e,t)=>Ne(n=>({...n,[e]:t})),archiveAmsMapping:lt,nozzleRackChoice:zt,onNozzleRackChoiceChange:Bt}),mn&&!_t&&At.map(e=>{let t=Xt.find(t=>t.index===e),n=It.get(e);return n?(0,Z.jsx)(ou,{printerId:We,plateLabel:t?.name||f(`printModal.plateN`,`Plate {{n}}`,{n:e}),filamentReqs:n,manualMappings:Lt[e]??{},onManualMappingChange:t=>Rt(n=>({...n,[e]:t})),onEstimatedCostChange:t=>De(n=>({...n,[e]:t})),budgetAvailable:Xe?nt?.budget_available??null:null,quantity:un(e),defaultExpanded:!1,currencySymbol:Je,defaultCostPerKg:Ye,forceColorMatch:Ae,onForceColorMatchChange:(e,t)=>Ne(n=>({...n,[e]:t})),archiveAmsMapping:lt,nozzleRackChoice:Vt[e]??{},onNozzleRackChoiceChange:t=>Ht(n=>({...n,[e]:t}))},e):null}),(e===`create`||Ue>0||H===`model`&&U)&&(0,Z.jsx)(gu,{options:ne,onChange:L,defaultExpanded:!!a?.length,showDualNozzleOptions:_n}),Xe&&tt.length>0&&(0,Z.jsx)(yu,{costCenters:tt,selectedCostCenterId:Se,onChange:Ce}),Xe&&!et&&tt.length===0&&(0,Z.jsxs)(`div`,{role:`alert`,className:`p-3 bg-yellow-100 dark:bg-yellow-500/20 border border-yellow-500/50 rounded-lg text-sm text-yellow-800 dark:text-yellow-300 flex items-start gap-2`,children:[(0,Z.jsx)(ge,{className:`w-4 h-4 mt-0.5 shrink-0`}),f(`printModal.noPrintableCostCenters`)]}),e!==`edit-queue-item`&&!ln&&(H===`model`||k.length<=1)&&(0,Z.jsxs)(`div`,{className:`flex items-center gap-3`,children:[(0,Z.jsx)(`label`,{htmlFor:`printQuantity`,className:`text-sm text-bambu-gray whitespace-nowrap`,children:f(`queue.quantity`,`Quantity`)}),(0,Z.jsx)(bl,{id:`printQuantity`,min:1,max:999,value:P,onChange:I,fallback:1,className:`w-20 px-2 py-1 text-sm bg-bambu-dark border border-bambu-dark-tertiary rounded text-white focus:outline-none focus:ring-1 focus:ring-bambu-green`}),P>1&&(0,Z.jsx)(`span`,{className:`text-xs text-bambu-gray`,children:f(`queue.quantityHint`,`Creates {{count}} queue items`,{count:P})})]}),(0,Z.jsx)(_u,{options:R,onChange:re,dateFormat:Ge?.date_format||`system`,timeFormat:Ge?.time_format||`system`,canControlPrinter:h(`printers:control`),showStagger:!x&&H===`printer`&&k.length>1,printerCount:k.length,hasGcodeSnippets:!!Ge?.gcode_snippets,needsReview:y}),(0,Z.jsxs)(`button`,{type:`button`,"aria-pressed":ne.confirm_outcome,title:f(`printModal.askForOutcomeTitle`),onClick:()=>L(e=>({...e,confirm_outcome:!e.confirm_outcome})),className:`inline-flex items-center gap-1.5 px-3 py-1.5 rounded-full border text-sm transition-colors ${ne.confirm_outcome?`bg-bambu-green/20 border-bambu-green text-bambu-green`:`bg-bambu-dark border-bambu-dark-tertiary text-bambu-gray hover:text-white`}`,children:[(0,Z.jsx)(ps,{className:`w-4 h-4`}),f(`printModal.askForOutcome`)]}),$t.isError&&(0,Z.jsx)(`div`,{className:`mb-4 p-3 bg-red-100 dark:bg-red-500/20 border border-red-500/50 rounded-lg text-sm text-red-700 dark:text-red-400`,children:$t.error?.message||`Failed to complete operation`}),H===`printer`&&k.length===1&&Et&&(0,Z.jsxs)(`div`,{className:`mb-4 p-3 bg-blue-100 dark:bg-blue-500/20 border border-blue-500/50 rounded-lg text-sm text-blue-700 dark:text-blue-400 flex items-center gap-2`,children:[(0,Z.jsx)(he,{className:`w-4 h-4 animate-spin`}),f(`printModal.waitingForAmsStatus`,{printer:Ze?.find(e=>e.id===We)?.name??``})]}),(0,Z.jsxs)(`div`,{className:`flex gap-3 pt-2`,children:[(0,Z.jsx)(xe,{type:`button`,variant:`secondary`,onClick:s,className:`flex-1`,disabled:Ie,children:`Cancel`}),(0,Z.jsx)(xe,{type:`submit`,disabled:!sn,className:`flex-1`,children:on?(0,Z.jsxs)(Z.Fragment,{children:[(0,Z.jsx)(he,{className:`w-4 h-4 animate-spin`}),dn.loadingText]}):(0,Z.jsxs)(Z.Fragment,{children:[(0,Z.jsx)(pn,{className:`w-4 h-4`}),dn.submitText]})})]})]})]})}),G&&G.length>0&&(0,Z.jsx)(Is,{title:f(`printModal.insufficientFilamentTitle`),message:Zt,confirmText:f(`printModal.printAnyway`),cancelText:f(`common.cancel`),variant:`warning`,onConfirm:()=>{Be(null),an(void 0,{skipFilamentCheck:!0})},onCancel:()=>Be(null)})]})}function Tu({archiveId:e,onClose:t}){let{t:n}=v(),{showToast:r}=fe(),i=F(),[a,s]=(0,W.useState)(!1),[c,l]=(0,W.useState)(``),[u,d]=(0,W.useState)(!1),{data:f}=z({queryKey:[`archive`,e],queryFn:()=>o.getArchive(e)}),p=ie({mutationFn:t=>o.updateArchive(e,{...t,user_verdict_source:`dialog`}),onSuccess:(a,o)=>{i.invalidateQueries({queryKey:[`archives`]}),i.invalidateQueries({queryKey:[`archive`,e]}),r(o.user_verdict===`good`?n(`confirmOutcome.savedGood`):n(`confirmOutcome.savedReject`),`success`),o.user_verdict===`good`&&t()},onError:()=>r(n(`confirmOutcome.saveFailed`),`error`)}),m=f?.print_name||f?.filename||``,h=f?.photos?.[0]??null,g=h?o.getArchivePhotoUrl(e,h):null,_=f?.user_verdict!=null,y=yl(f?.user_verdict_source),b=()=>p.mutate({user_verdict:`good`}),x=e=>{p.mutate({user_verdict:`reject`,...c?{failure_reason:c}:{}},{onSuccess:()=>{e?d(!0):t()}})};return u&&f?(0,Z.jsx)(wu,{mode:`create`,archiveId:e,archiveName:m,onClose:t}):(0,Z.jsx)(`div`,{className:`fixed inset-0 z-50 bg-black/60 flex items-center justify-center p-4`,"data-testid":`confirm-outcome-dialog`,children:(0,Z.jsxs)(`div`,{className:`bg-bambu-dark-secondary rounded-xl border border-bambu-dark-tertiary w-full max-w-md overflow-hidden`,children:[(0,Z.jsxs)(`div`,{className:`flex items-center justify-between px-4 py-3 border-b border-bambu-dark-tertiary`,children:[(0,Z.jsx)(`h3`,{className:`text-white font-semibold`,children:n(`confirmOutcome.title`)}),(0,Z.jsx)(`button`,{onClick:t,className:`text-bambu-gray hover:text-white transition-colors`,title:n(`common.close`),children:(0,Z.jsx)(_e,{className:`w-5 h-5`})})]}),(0,Z.jsx)(`div`,{className:`bg-bambu-dark aspect-video flex items-center justify-center overflow-hidden`,children:g?(0,Z.jsx)(`img`,{src:g,alt:m,className:`w-full h-full object-contain`}):(0,Z.jsxs)(`div`,{className:`flex flex-col items-center gap-2 text-bambu-gray/60`,children:[(0,Z.jsx)(To,{className:`w-10 h-10`}),(0,Z.jsx)(`span`,{className:`text-xs`,children:n(`confirmOutcome.noPhoto`)})]})}),(0,Z.jsxs)(`div`,{className:`p-4`,children:[(0,Z.jsx)(`p`,{className:`text-sm text-white text-center mb-1 truncate`,title:m,children:m}),_?(0,Z.jsxs)(Z.Fragment,{children:[(0,Z.jsx)(`p`,{className:`text-sm text-bambu-gray text-center`,children:f?.user_verdict===`good`?n(`confirmOutcome.alreadyGood`):n(`confirmOutcome.alreadyRejected`)}),y&&(0,Z.jsx)(`p`,{className:`text-xs text-bambu-gray/70 text-center mt-1`,"data-testid":`verdict-source-hint`,children:n(y)})]}):a?(0,Z.jsxs)(`div`,{className:`mt-3`,children:[(0,Z.jsx)(`label`,{className:`block text-xs text-bambu-gray mb-1`,children:n(`confirmOutcome.rejectReason`)}),(0,Z.jsxs)(`select`,{value:c,onChange:e=>l(e.target.value),className:`w-full px-3 py-2 bg-bambu-dark border border-bambu-dark-tertiary rounded-lg text-white text-sm focus:outline-none focus:border-bambu-green`,children:[(0,Z.jsx)(`option`,{value:``,children:n(`confirmOutcome.noReason`)}),xl.map(e=>(0,Z.jsx)(`option`,{value:e,children:n(`editArchive.failureReasons.${e}`)},e))]}),(0,Z.jsxs)(`div`,{className:`flex gap-2 mt-3`,children:[(0,Z.jsx)(`button`,{type:`button`,onClick:()=>x(!1),disabled:p.isPending,className:`flex-1 px-3 py-2 rounded-lg bg-red-500/80 hover:bg-red-500 text-white text-sm transition-colors`,children:n(`confirmOutcome.saveReject`)}),(0,Z.jsxs)(`button`,{type:`button`,onClick:()=>x(!0),disabled:p.isPending,className:`flex-1 px-3 py-2 rounded-lg bg-bambu-dark border border-bambu-dark-tertiary hover:border-bambu-green/60 text-white text-sm transition-colors flex items-center justify-center gap-1.5`,children:[(0,Z.jsx)(Zo,{className:`w-4 h-4`}),n(`confirmOutcome.rejectAndReprint`)]})]}),(0,Z.jsx)(`button`,{type:`button`,onClick:()=>s(!1),className:`w-full mt-2 text-xs text-bambu-gray hover:text-white transition-colors`,children:n(`common.back`)})]}):(0,Z.jsxs)(`div`,{className:`flex items-center justify-center gap-6 mt-3`,children:[(0,Z.jsxs)(`button`,{type:`button`,onClick:()=>s(!0),disabled:p.isPending,className:`flex flex-col items-center gap-1.5 px-6 py-3 rounded-xl border border-red-500/40 text-red-500 hover:bg-red-500/10 transition-colors`,children:[(0,Z.jsx)(fs,{className:`w-7 h-7`}),(0,Z.jsx)(`span`,{className:`text-xs`,children:n(`confirmOutcome.reject`)})]}),(0,Z.jsxs)(`button`,{type:`button`,onClick:b,disabled:p.isPending,className:`flex flex-col items-center gap-1.5 px-6 py-3 rounded-xl border border-bambu-green/50 text-bambu-green hover:bg-bambu-green/10 transition-colors`,children:[(0,Z.jsx)(ps,{className:`w-7 h-7`}),(0,Z.jsx)(`span`,{className:`text-xs`,children:n(`confirmOutcome.good`)})]})]}),!_&&!a&&(0,Z.jsx)(`button`,{type:`button`,onClick:t,className:`w-full mt-4 text-xs text-bambu-gray hover:text-white transition-colors`,children:n(`confirmOutcome.later`)})]})]})})}function Eu({status:e}){return e===`pass`?(0,Z.jsx)(eo,{className:`w-5 h-5 text-bambu-green flex-shrink-0`}):e===`fail`?(0,Z.jsx)(ue,{className:`w-5 h-5 text-red-600 dark:text-red-400 flex-shrink-0`}):e===`warn`?(0,Z.jsx)(ge,{className:`w-5 h-5 text-amber-600 dark:text-amber-400 flex-shrink-0`}):(0,Z.jsx)(to,{className:`w-5 h-5 text-bambu-gray flex-shrink-0`})}function Du({result:e}){let{t}=v(),n=e.overall===`ok`?`bg-bambu-green/10 border-bambu-green/30 text-bambu-green`:e.overall===`warnings`?`bg-amber-50 dark:bg-amber-500/10 border-amber-300 dark:border-amber-500/30 text-amber-700 dark:text-amber-300`:`bg-red-50 dark:bg-red-500/10 border-red-300 dark:border-red-500/30 text-red-700 dark:text-red-300`;return(0,Z.jsxs)(`div`,{className:`space-y-4`,children:[(0,Z.jsx)(`ol`,{className:`space-y-2`,children:e.checks.map(e=>{let n=e.id===`port_rtsps`?{protocol:`RTSPS`,port:322,...e.params}:e.id===`network_mode`&&e.params?.runtime===`container`?{...e.params,runtime:t(`diagnostic.check.network_mode.genericRuntime`)}:e.params,r=e.params?.reason,i=t(`diagnostic.check.${e.id}.${e.status}${r?`_${r}`:``}`,{...n,defaultValue:r?t(`diagnostic.check.${e.id}.${e.status}`,{...n,defaultValue:``}):``});return(0,Z.jsxs)(`li`,{className:`flex items-start gap-3 bg-bambu-dark rounded-lg px-4 py-2.5 ${e.status===`skip`?`opacity-60`:``}`,children:[(0,Z.jsx)(`div`,{className:`mt-0.5`,children:(0,Z.jsx)(Eu,{status:e.status})}),(0,Z.jsxs)(`div`,{className:`flex-1 min-w-0`,children:[(0,Z.jsx)(`div`,{className:`text-sm text-white`,children:t(`diagnostic.check.${e.id}.title`,n)}),i&&(0,Z.jsx)(`div`,{className:`text-xs text-bambu-gray mt-0.5`,children:i})]})]},e.id)})}),(0,Z.jsx)(`div`,{className:`rounded-lg border px-4 py-3 text-sm ${n}`,children:t(`diagnostic.overall.${e.overall}`)})]})}var Ou=10;function ku(e){let{onClose:t,printerName:n}=e,{t:r}=v(),i=`printerId`in e?e.printerId:void 0,a=`connection`in e?e.connection:void 0,s=ie({mutationFn:()=>i===void 0?o.diagnoseConnection(a):o.diagnosePrinter(i)});(0,W.useEffect)(()=>{s.mutate()},[]),(0,W.useEffect)(()=>{let e=e=>{e.key===`Escape`&&t()};return window.addEventListener(`keydown`,e),()=>window.removeEventListener(`keydown`,e)},[t]);let[c,l]=(0,W.useState)(0);(0,W.useEffect)(()=>{if(!s.isPending){l(0);return}let e=Date.now(),t=window.setInterval(()=>{l(Math.floor((Date.now()-e)/1e3))},500);return()=>window.clearInterval(t)},[s.isPending]);let u=s.data;return(0,Z.jsx)(`div`,{className:`fixed inset-0 bg-black/70 flex items-center justify-center z-50 p-4`,onClick:t,children:(0,Z.jsxs)(`div`,{className:`bg-bambu-dark-secondary rounded-xl border border-bambu-dark-tertiary w-full max-w-lg flex flex-col max-h-[85vh]`,onClick:e=>e.stopPropagation(),children:[(0,Z.jsxs)(`div`,{className:`flex items-center justify-between px-6 py-4 border-b border-bambu-dark-tertiary`,children:[(0,Z.jsxs)(`div`,{className:`flex items-center gap-2 min-w-0`,children:[(0,Z.jsx)(cs,{className:`w-5 h-5 text-bambu-green flex-shrink-0`}),(0,Z.jsx)(`h2`,{className:`text-lg font-semibold text-white truncate`,children:r(`diagnostic.modalTitle`,{name:n||``})})]}),(0,Z.jsx)(`button`,{onClick:t,className:`text-bambu-gray hover:text-white transition-colors`,title:r(`common.close`),children:(0,Z.jsx)(_e,{className:`w-5 h-5`})})]}),(0,Z.jsxs)(`div`,{className:`p-6 space-y-4 overflow-y-auto`,children:[s.isPending&&(0,Z.jsxs)(`div`,{className:`space-y-1.5`,children:[(0,Z.jsxs)(`div`,{className:`flex items-center gap-2 text-bambu-gray`,children:[(0,Z.jsx)(he,{className:`w-4 h-4 animate-spin`}),(0,Z.jsx)(`span`,{children:c>0?r(`diagnostic.runningElapsed`,{elapsed:c}):r(`diagnostic.running`)})]}),i!==void 0&&(0,Z.jsx)(`p`,{className:`text-xs text-bambu-gray-light pl-6`,children:r(`diagnostic.waitingForReportHint`,{max:Ou})})]}),s.isError&&(0,Z.jsx)(`div`,{className:`rounded-lg bg-red-50 dark:bg-red-500/10 border border-red-300 dark:border-red-500/30 px-4 py-3 text-sm text-red-700 dark:text-red-300`,children:r(`diagnostic.runFailed`,{error:s.error.message})}),u&&(0,Z.jsx)(Du,{result:u})]}),(0,Z.jsxs)(`div`,{className:`px-6 py-4 border-t border-bambu-dark-tertiary flex justify-end gap-2`,children:[(0,Z.jsx)(`button`,{onClick:()=>s.mutate(),disabled:s.isPending,className:`px-4 py-2 bg-bambu-dark hover:bg-bambu-dark-tertiary disabled:opacity-50 text-white text-sm rounded-lg transition-colors`,children:r(`diagnostic.retry`)}),(0,Z.jsx)(`button`,{onClick:t,className:`px-4 py-2 bg-bambu-green hover:bg-bambu-green/90 text-white text-sm rounded-lg transition-colors`,children:r(`common.close`)})]})]})})}var Au=`https://wiki.bambuddy.cool/reference/troubleshooting/`,ju={layer8:{icon:Cs,badgeClass:`bg-bambu-green/15 text-bambu-green border-bambu-green/30`},environment:{icon:es,badgeClass:`bg-amber-100 dark:bg-amber-500/15 text-amber-700 dark:text-amber-300 border-amber-300 dark:border-amber-500/30`},bug:{icon:Ja,badgeClass:`bg-red-100 dark:bg-red-500/15 text-red-700 dark:text-red-300 border-red-300 dark:border-red-500/30`}};function Mu({finding:e}){let{t}=v(),n=e.signature_id,r=t(`systemHealth.signature.${n}.name`,{defaultValue:n}),i=t(`systemHealth.signature.${n}.cause`,{defaultValue:``}),a=t(`systemHealth.signature.${n}.fix`,{defaultValue:``}),o=ju[e.category]??ju.bug,s=o.icon;return(0,Z.jsxs)(`div`,{className:`bg-bambu-dark rounded-lg border border-bambu-dark-tertiary p-4 space-y-2`,children:[(0,Z.jsxs)(`div`,{className:`flex items-start gap-3`,children:[(0,Z.jsx)(e.severity===`error`?ue:ge,{className:`w-5 h-5 flex-shrink-0 mt-0.5 ${e.severity===`error`?`text-red-600 dark:text-red-400`:`text-amber-600 dark:text-amber-400`}`}),(0,Z.jsxs)(`div`,{className:`flex-1 min-w-0`,children:[(0,Z.jsxs)(`div`,{className:`flex items-center gap-2 flex-wrap`,children:[(0,Z.jsx)(`span`,{className:`text-sm font-medium text-white`,children:r}),(0,Z.jsxs)(`span`,{className:`inline-flex items-center gap-1 text-xs px-2 py-0.5 rounded-full border ${o.badgeClass}`,children:[(0,Z.jsx)(s,{className:`w-3 h-3`}),t(`systemHealth.category.${e.category}`)]})]}),i&&(0,Z.jsx)(`p`,{className:`text-xs text-bambu-gray mt-1`,children:i})]})]}),a&&(0,Z.jsxs)(`div`,{className:`text-xs text-white/90 bg-bambu-dark-secondary rounded px-3 py-2`,children:[(0,Z.jsx)(`span`,{className:`text-bambu-green font-medium`,children:t(`systemHealth.fixLabel`)}),` `,a]}),(0,Z.jsx)(`div`,{className:`text-xs font-mono text-bambu-gray/70 bg-bambu-dark-secondary rounded px-3 py-2 break-all`,children:e.sample}),(0,Z.jsxs)(`div`,{className:`flex items-center justify-between gap-2 flex-wrap`,children:[(0,Z.jsx)(`span`,{className:`text-xs text-bambu-gray`,children:t(`systemHealth.occurrences`,{times:e.count,lastSeen:e.last_seen})}),(0,Z.jsxs)(`a`,{href:`${Au}#${e.wiki_anchor}`,target:`_blank`,rel:`noopener noreferrer`,className:`inline-flex items-center gap-1 text-xs text-bambu-green hover:underline`,children:[t(`systemHealth.learnMore`),(0,Z.jsx)(uo,{className:`w-3 h-3`})]})]})]})}function Nu({result:e}){let{t}=v();return e.log_available?e.findings.length===0?(0,Z.jsxs)(`div`,{className:`rounded-lg bg-bambu-green/10 border border-bambu-green/30 px-4 py-3 text-sm text-bambu-green flex items-center gap-2`,children:[(0,Z.jsx)(eo,{className:`w-5 h-5 flex-shrink-0`}),(0,Z.jsx)(`span`,{children:t(`systemHealth.clean`,{times:e.scanned_entries})})]}):(0,Z.jsx)(`div`,{className:`space-y-3`,children:e.findings.map(e=>(0,Z.jsx)(Mu,{finding:e},e.signature_id))}):(0,Z.jsx)(`div`,{className:`rounded-lg bg-amber-50 dark:bg-amber-500/10 border border-amber-300 dark:border-amber-500/30 px-4 py-3 text-sm text-amber-700 dark:text-amber-300`,children:t(`systemHealth.logUnavailable`)})}function Pu({summary:e,children:t,defaultOpen:n=!1,className:r=``,summaryClassName:i=``,open:a,onToggle:o}){let[s,c]=(0,W.useState)(n),l=a!==void 0,u=l?a:s,d=()=>{let e=!u;l||c(e),o?.(e)};return(0,Z.jsxs)(`div`,{className:r,children:[(0,Z.jsxs)(`div`,{role:`button`,tabIndex:0,onClick:d,onKeyDown:e=>{(e.key===`Enter`||e.key===` `)&&(e.preventDefault(),d())},className:`w-full flex items-center justify-between gap-2 text-left cursor-pointer ${i}`,"aria-expanded":u,children:[(0,Z.jsx)(`div`,{className:`flex-1 min-w-0`,children:e}),(0,Z.jsx)(le,{className:`w-4 h-4 text-bambu-gray flex-shrink-0 transition-transform ${u?`rotate-180`:``}`})]}),u&&(0,Z.jsx)(`div`,{className:`mt-3`,children:t})]})}var Fu=768;function Iu(){let[e,t]=(0,W.useState)(()=>typeof window<`u`?window.innerWidth<Fu:!1);return(0,W.useEffect)(()=>{let e=window.matchMedia(`(max-width: ${Fu-1}px)`),n=e=>{t(e.matches)};return t(e.matches),e.addEventListener(`change`,n),()=>e.removeEventListener(`change`,n)},[]),e}var Lu=1920,Ru=.7,zu=300,Bu=`bambuddy-bug-report-session`;function Vu(){try{let e=window.localStorage.getItem(Bu);if(!e)return null;let t=JSON.parse(e);return typeof t?.startedAt==`number`?{description:typeof t.description==`string`?t.description:``,email:typeof t.email==`string`?t.email:``,wasDebug:t.wasDebug===!0,startedAt:t.startedAt}:null}catch{return null}}function Hu(e){try{window.localStorage.setItem(Bu,JSON.stringify(e))}catch{}}function Uu(){try{window.localStorage.removeItem(Bu)}catch{}}function Wu(e){return new Promise((t,n)=>{let r=new Image;r.onload=()=>{let{width:e,height:i}=r;if(e>Lu||i>Lu){let t=Lu/Math.max(e,i);e=Math.round(e*t),i=Math.round(i*t)}let a=document.createElement(`canvas`);a.width=e,a.height=i;let o=a.getContext(`2d`);if(!o){n(Error(`No canvas context`));return}o.drawImage(r,0,0,e,i),t(a.toDataURL(`image/jpeg`,Ru).replace(/^data:[^;]+;base64,/,``))},r.onerror=n,r.src=URL.createObjectURL(e)})}function Gu(e){let t=Math.floor(e/60),n=e%60;return`${t.toString().padStart(2,`0`)}:${n.toString().padStart(2,`0`)}`}function Ku({showTrigger:e=!0,open:t,onOpenChange:n,onLoggingChange:r}={}){let{t:i}=v(),a=Iu(),[s,c]=(0,W.useState)(!1),l=t!==void 0,u=l?t:s,d=(0,W.useCallback)(e=>{l||c(e),n?.(e)},[l,n]),[f,m]=(0,W.useState)(`form`),[h,g]=(0,W.useState)(``),[_,y]=(0,W.useState)(``),[x,S]=(0,W.useState)(null),[C,w]=(0,W.useState)(!1),[T,E]=(0,W.useState)(null),[D,O]=(0,W.useState)(null),[k,A]=(0,W.useState)(``),[j,M]=(0,W.useState)(0),[N,P]=(0,W.useState)(null),[F,I]=(0,W.useState)(!1),ee=(0,W.useRef)(null),te=(0,W.useRef)(null),ne=(0,W.useRef)(()=>{}),L=(0,W.useRef)(f);L.current=f;let R=f===`logging`;(0,W.useEffect)(()=>{r?.(R)},[R,r]);let re=z({queryKey:[`bugReportDiagnostic`],enabled:u&&f===`form`,staleTime:3e4,queryFn:async()=>{let e=await o.getPrinters();return(await Promise.all(e.map(async e=>{let t=await o.diagnosePrinter(e.id).catch(()=>null);return t?{name:e.name,result:t}:null}))).filter(e=>e!==null)}}),ie=re.data??[],B=ie.filter(e=>e.result.overall===`problems`),V=z({queryKey:[`bugReportLogHealth`],enabled:u&&f===`form`,staleTime:3e4,queryFn:o.getSystemHealth}),ae=V.data?.findings??[];(0,W.useEffect)(()=>{if(f!==`logging`||N===null)return;let e=()=>{let e=Math.floor((Date.now()-N)/1e3);M(e),e>=zu&&ne.current()};e();let t=setInterval(e,1e3);return()=>clearInterval(t)},[f,N]),(0,W.useEffect)(()=>{u&&(L.current===`logging`||L.current===`stopping`||L.current===`submitting`||(m(`form`),g(``),y(``),S(null),E(null),O(null),A(``),M(0),P(null),I(!1)))},[u]),(0,W.useEffect)(()=>{let e=Vu();if(!e)return;let t=!1;return(async()=>{let n;try{n=(await b.getDebugLoggingState()).enabled}catch{return}if(t||L.current!==`form`)return;if(!n){Uu();return}let r=Math.floor((Date.now()-e.startedAt)/1e3);if(r>=zu){try{await p.stopLogging(e.wasDebug)}catch{}Uu();return}g(e.description),y(e.email),I(e.wasDebug),P(e.startedAt),M(r),m(`logging`)})(),()=>{t=!0}},[]);let oe=()=>d(!0),se=()=>{d(!1)},ce=(0,W.useCallback)(async e=>{if(e.type.startsWith(`image/`))try{S(await Wu(e))}catch{}},[]),le=(0,W.useCallback)(e=>{let t=e.clipboardData?.items;if(t){for(let e of t)if(e.type.startsWith(`image/`)){let t=e.getAsFile();t&&ce(t);break}}},[ce]),H=(0,W.useCallback)(e=>{e.preventDefault(),w(!0)},[]),ue=(0,W.useCallback)(e=>{e.preventDefault(),w(!1)},[]),U=(0,W.useCallback)(e=>{e.preventDefault(),w(!1);let t=e.dataTransfer.files?.[0];t&&ce(t)},[ce]),fe=async()=>{if(h.trim())try{let e=await p.startLogging(),t=Date.now();I(e.was_debug),P(t),M(0),m(`logging`),Hu({description:h.trim(),email:_.trim(),wasDebug:e.was_debug,startedAt:t})}catch(e){A(e instanceof Error?e.message:i(`bugReport.unexpectedError`)),m(`error`)}},me=async()=>{d(!0),Uu(),P(null),m(`stopping`);try{await ve((await p.stopLogging(F)).logs)}catch(e){A(e instanceof Error?e.message:i(`bugReport.unexpectedError`)),m(`error`)}};ne.current=me;let ve=async e=>{m(`submitting`);try{let t=await p.submit({description:h.trim(),email:_.trim()||void 0,screenshot_base64:x||void 0,include_support_info:!0,debug_logs:e||void 0});t.success?(E(t.issue_url||null),O(t.issue_number||null),m(`success`)):(A(t.message),m(`error`))}catch(e){A(e instanceof Error?e.message:i(`bugReport.unexpectedError`)),m(`error`)}};return(0,Z.jsxs)(Z.Fragment,{children:[e&&(0,Z.jsxs)(`button`,{onClick:oe,className:`fixed bottom-4 right-4 z-40 w-12 h-12 rounded-full text-white shadow-lg hover:shadow-xl transition-all duration-200 hover:scale-110 flex items-center justify-center ${R?`bg-amber-500 hover:bg-amber-600`:`bg-red-500 hover:bg-red-600`}`,title:R?i(`bugReport.resumeRecording`,{elapsed:Gu(j)}):i(`bugReport.title`),children:[R&&(0,Z.jsx)(`span`,{className:`absolute inset-0 rounded-full bg-amber-400 opacity-75 animate-ping`}),(0,Z.jsx)(Ja,{className:`w-5 h-5 relative`})]}),u&&(0,Z.jsx)(`div`,{id:`bug-report-modal`,className:a?`fixed inset-x-0 bottom-0 z-50`:e?`fixed bottom-20 right-4 z-50 w-full max-w-md`:`fixed top-16 right-4 z-50 w-full max-w-md`,onPaste:le,children:(0,Z.jsxs)(`div`,{ref:ee,className:`bg-white dark:bg-gray-800 shadow-2xl border border-gray-200 dark:border-gray-700 overflow-y-auto ${a?`rounded-t-2xl max-h-[85vh] pb-[env(safe-area-inset-bottom)]`:`rounded-lg max-h-[80vh]`}`,children:[(0,Z.jsxs)(`div`,{className:`flex items-center justify-between p-4 border-b border-gray-200 dark:border-gray-700 sticky top-0 bg-white dark:bg-gray-800 z-10`,children:[(0,Z.jsxs)(`h2`,{className:`text-lg font-semibold text-gray-900 dark:text-white flex items-center gap-2`,children:[(0,Z.jsx)(Ja,{className:`w-5 h-5 text-red-500`}),i(`bugReport.title`)]}),(0,Z.jsx)(`button`,{onClick:se,className:`text-gray-400 hover:text-gray-600 dark:hover:text-gray-300`,children:(0,Z.jsx)(_e,{className:`w-5 h-5`})})]}),(0,Z.jsxs)(`div`,{className:`p-4 space-y-4`,children:[f===`form`&&(0,Z.jsxs)(Z.Fragment,{children:[re.isLoading&&(0,Z.jsxs)(`div`,{className:`flex items-center gap-2 text-xs text-gray-500 dark:text-gray-400`,children:[(0,Z.jsx)(he,{className:`w-3.5 h-3.5 animate-spin`}),i(`bugReport.diagnosticChecking`)]}),!re.isLoading&&B.length>0&&(0,Z.jsxs)(`div`,{className:`rounded-lg bg-amber-50 dark:bg-amber-900/20 border border-amber-200 dark:border-amber-800 p-3 space-y-3`,children:[(0,Z.jsxs)(`div`,{className:`flex items-start gap-2`,children:[(0,Z.jsx)(cs,{className:`w-4 h-4 mt-0.5 flex-shrink-0 text-amber-600 dark:text-amber-400`}),(0,Z.jsxs)(`div`,{children:[(0,Z.jsx)(`p`,{className:`text-sm font-medium text-amber-700 dark:text-amber-300`,children:i(`bugReport.diagnosticSummary`,{problems:B.length,total:ie.length})}),(0,Z.jsx)(`p`,{className:`text-xs text-amber-800 dark:text-amber-200 mt-0.5`,children:i(`bugReport.diagnosticIntro`)})]})]}),(0,Z.jsx)(`div`,{className:`space-y-2`,children:B.map(e=>(0,Z.jsx)(Pu,{defaultOpen:B.length===1,className:`rounded-lg bg-amber-100/60 dark:bg-amber-900/30 px-3 py-2`,summary:(0,Z.jsxs)(`div`,{className:`flex items-center gap-2 min-w-0`,children:[(0,Z.jsx)(ge,{className:`w-4 h-4 flex-shrink-0 text-amber-600 dark:text-amber-400`}),(0,Z.jsx)(`span`,{className:`text-sm font-medium text-amber-800 dark:text-amber-200 truncate`,children:e.name})]}),children:(0,Z.jsx)(Du,{result:e.result})},e.result.printer_id??e.result.ip_address))})]}),!re.isLoading&&ie.length>0&&B.length===0&&(0,Z.jsxs)(`div`,{className:`flex items-start gap-2 rounded-lg bg-green-50 dark:bg-green-900/20 border border-green-200 dark:border-green-800 p-3`,children:[(0,Z.jsx)(pe,{className:`w-4 h-4 mt-0.5 flex-shrink-0 text-green-600 dark:text-green-400`}),(0,Z.jsx)(`p`,{className:`text-xs text-green-800 dark:text-green-200`,children:i(`bugReport.diagnosticHealthy`)})]}),!V.isLoading&&ae.length>0&&V.data&&(0,Z.jsxs)(`div`,{className:`rounded-lg bg-amber-50 dark:bg-amber-900/20 border border-amber-200 dark:border-amber-800 p-3 space-y-3`,children:[(0,Z.jsxs)(`div`,{className:`flex items-start gap-2`,children:[(0,Z.jsx)(cs,{className:`w-4 h-4 mt-0.5 flex-shrink-0 text-amber-600 dark:text-amber-400`}),(0,Z.jsxs)(`div`,{children:[(0,Z.jsx)(`p`,{className:`text-sm font-medium text-amber-700 dark:text-amber-300`,children:i(`bugReport.logHealthSummary`)}),(0,Z.jsx)(`p`,{className:`text-xs text-amber-800 dark:text-amber-200 mt-0.5`,children:i(`bugReport.logHealthIntro`)})]})]}),(0,Z.jsx)(Nu,{result:V.data})]}),(0,Z.jsxs)(`div`,{children:[(0,Z.jsxs)(`label`,{className:`block text-sm font-medium text-gray-700 dark:text-gray-300 mb-1`,children:[i(`bugReport.description`),` *`]}),(0,Z.jsx)(`textarea`,{value:h,onChange:e=>g(e.target.value),placeholder:i(`bugReport.descriptionPlaceholder`),rows:3,className:`w-full px-3 py-2 border border-gray-300 dark:border-gray-600 rounded-lg bg-white dark:bg-gray-700 text-gray-900 dark:text-white placeholder-gray-400 focus:ring-2 focus:ring-blue-500 focus:border-transparent resize-vertical`})]}),(0,Z.jsxs)(`div`,{children:[(0,Z.jsx)(`label`,{className:`block text-sm font-medium text-gray-700 dark:text-gray-300 mb-1`,children:i(`bugReport.email`)}),(0,Z.jsx)(`input`,{type:`email`,value:_,onChange:e=>y(e.target.value),placeholder:i(`bugReport.emailPlaceholder`),className:`w-full px-3 py-2 border border-gray-300 dark:border-gray-600 rounded-lg bg-white dark:bg-gray-700 text-gray-900 dark:text-white placeholder-gray-400 focus:ring-2 focus:ring-blue-500 focus:border-transparent`}),(0,Z.jsx)(`p`,{className:`mt-1 text-xs text-gray-500 dark:text-gray-400`,children:i(`bugReport.emailPrivacy`)})]}),(0,Z.jsxs)(`div`,{children:[(0,Z.jsx)(`label`,{className:`block text-sm font-medium text-gray-700 dark:text-gray-300 mb-1`,children:i(`bugReport.screenshot`)}),x?(0,Z.jsxs)(`div`,{className:`relative`,children:[(0,Z.jsx)(`img`,{src:`data:image/jpeg;base64,${x}`,alt:i(`bugReport.screenshot`),className:`w-full max-h-40 object-contain rounded-lg border border-gray-200 dark:border-gray-600`}),(0,Z.jsx)(`button`,{onClick:()=>S(null),className:`absolute top-2 right-2 p-1 bg-red-500 hover:bg-red-600 text-white rounded-full shadow`,title:i(`common.delete`),children:(0,Z.jsx)(ms,{className:`w-3 h-3`})})]}):(0,Z.jsxs)(`button`,{type:`button`,onClick:()=>te.current?.click(),onDragOver:H,onDragLeave:ue,onDrop:U,className:`w-full flex flex-col items-center gap-2 px-4 py-4 border-2 border-dashed rounded-lg transition-colors cursor-pointer ${C?`border-blue-500 bg-blue-50 dark:bg-blue-900/20 text-blue-500`:`border-gray-300 dark:border-gray-600 text-gray-500 dark:text-gray-400 hover:border-gray-400 dark:hover:border-gray-500 hover:text-gray-600 dark:hover:text-gray-300`}`,children:[(0,Z.jsx)(hs,{className:`w-5 h-5`}),(0,Z.jsx)(`span`,{className:`text-sm`,children:i(`bugReport.uploadOrPaste`)})]}),(0,Z.jsx)(`input`,{ref:te,type:`file`,accept:`image/*`,className:`hidden`,onChange:e=>{let t=e.target.files?.[0];t&&ce(t),e.target.value=``}})]}),(0,Z.jsxs)(`details`,{className:`text-xs bg-amber-50 dark:bg-amber-900/20 border border-amber-200 dark:border-amber-800 rounded-lg p-3`,children:[(0,Z.jsx)(`summary`,{className:`cursor-pointer font-medium text-amber-700 dark:text-amber-300 hover:text-amber-800 dark:hover:text-amber-200`,children:i(`bugReport.dataCollectedSummary`)}),(0,Z.jsxs)(`div`,{className:`mt-2 space-y-2 pl-2 border-l-2 border-amber-300 dark:border-amber-700 text-amber-800 dark:text-amber-200`,children:[(0,Z.jsx)(`p`,{className:`font-medium`,children:i(`bugReport.dataIncluded`)}),(0,Z.jsx)(`p`,{children:i(`bugReport.dataIncludedList`)}),(0,Z.jsx)(`p`,{className:`font-medium`,children:i(`bugReport.dataNeverIncluded`)}),(0,Z.jsx)(`p`,{children:i(`bugReport.dataNeverIncludedList`)})]})]}),(0,Z.jsxs)(`div`,{className:`flex justify-end gap-2 pt-2`,children:[(0,Z.jsx)(`button`,{onClick:se,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:i(`common.cancel`)}),(0,Z.jsx)(`button`,{onClick:fe,disabled:!h.trim(),className:`px-4 py-2 text-sm font-medium text-white bg-red-500 hover:bg-red-600 disabled:opacity-50 disabled:cursor-not-allowed rounded-lg transition-colors`,children:i(`bugReport.startLogging`)})]})]}),f===`logging`&&(0,Z.jsxs)(`div`,{className:`py-6 space-y-6`,children:[(0,Z.jsxs)(`div`,{className:`space-y-3 px-2`,children:[(0,Z.jsxs)(`div`,{className:`flex items-center gap-3`,children:[(0,Z.jsx)(eo,{className:`w-5 h-5 text-green-500 flex-shrink-0`}),(0,Z.jsx)(`span`,{className:`text-sm text-green-700 dark:text-green-400`,children:i(`bugReport.stepEnableLogging`)})]}),(0,Z.jsxs)(`div`,{className:`flex items-center gap-3`,children:[(0,Z.jsxs)(`span`,{className:`relative flex h-5 w-5 flex-shrink-0 items-center justify-center`,children:[(0,Z.jsx)(`span`,{className:`animate-ping absolute inline-flex h-full w-full rounded-full bg-blue-400 opacity-75`}),(0,Z.jsx)(`span`,{className:`relative inline-flex rounded-full h-3 w-3 bg-blue-500`})]}),(0,Z.jsx)(`span`,{"data-testid":`bug-report-step-reproduce`,className:`text-sm font-medium text-blue-700 dark:text-blue-300`,children:i(`bugReport.stepReproduce`)})]}),(0,Z.jsxs)(`div`,{className:`flex items-center gap-3`,children:[(0,Z.jsx)(no,{className:`w-5 h-5 text-gray-300 dark:text-gray-600 flex-shrink-0`}),(0,Z.jsx)(`span`,{className:`text-sm text-gray-400 dark:text-gray-500`,children:i(`bugReport.stepStopLogging`)})]})]}),(0,Z.jsxs)(`div`,{className:`text-center`,children:[(0,Z.jsx)(`p`,{className:`text-3xl font-mono text-blue-500`,children:Gu(j)}),(0,Z.jsx)(`p`,{className:`text-xs text-gray-500 dark:text-gray-400 mt-1`,children:i(`bugReport.maxDuration`,{minutes:5})}),(0,Z.jsx)(`p`,{className:`text-xs text-gray-500 dark:text-gray-400 mt-2`,children:i(`bugReport.closeKeepsRecording`)})]}),(0,Z.jsx)(`div`,{className:`flex justify-center`,children:(0,Z.jsx)(`button`,{onClick:me,className:`px-6 py-2.5 text-sm font-medium text-white bg-red-500 hover:bg-red-600 rounded-lg transition-colors`,children:i(`bugReport.stopAndSubmit`)})})]}),(f===`stopping`||f===`submitting`)&&(0,Z.jsxs)(`div`,{className:`flex flex-col items-center justify-center py-6 gap-3`,children:[(0,Z.jsx)(he,{className:`w-8 h-8 animate-spin text-blue-500`}),(0,Z.jsx)(`p`,{className:`text-sm text-gray-600 dark:text-gray-400 text-center`,children:i(f===`stopping`?`bugReport.stoppingLogs`:`bugReport.submitting`)}),f===`submitting`&&(0,Z.jsxs)(`ul`,{className:`text-xs text-gray-500 dark:text-gray-400 list-disc list-inside space-y-0.5`,children:[(0,Z.jsx)(`li`,{children:i(`bugReport.submittingStepConnection`)}),(0,Z.jsx)(`li`,{children:i(`bugReport.submittingStepVirtualPrinters`)}),(0,Z.jsx)(`li`,{children:i(`bugReport.submittingStepLogScan`)}),(0,Z.jsx)(`li`,{children:i(`bugReport.submittingStepSubmit`)})]})]}),f===`success`&&(0,Z.jsxs)(`div`,{className:`flex flex-col items-center justify-center py-8 gap-3`,children:[(0,Z.jsx)(pe,{className:`w-12 h-12 text-green-500`}),(0,Z.jsx)(`p`,{className:`text-lg font-semibold text-gray-900 dark:text-white`,children:i(`bugReport.thankYou`)}),(0,Z.jsx)(`p`,{className:`text-sm text-gray-600 dark:text-gray-400`,children:i(`bugReport.submitted`)}),T&&(0,Z.jsxs)(`a`,{href:T,target:`_blank`,rel:`noopener noreferrer`,className:`text-sm text-blue-500 hover:text-blue-600 underline`,children:[i(`bugReport.viewIssue`),` #`,D]}),(0,Z.jsx)(`button`,{onClick:se,className:`mt-4 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:i(`common.close`)})]}),f===`error`&&(0,Z.jsxs)(`div`,{className:`flex flex-col items-center justify-center py-8 gap-3`,children:[(0,Z.jsx)(de,{className:`w-12 h-12 text-red-500`}),(0,Z.jsx)(`p`,{className:`text-lg font-semibold text-gray-900 dark:text-white`,children:i(`bugReport.submitFailed`)}),(0,Z.jsx)(`p`,{className:`text-sm text-gray-600 dark:text-gray-400 text-center`,children:k}),(0,Z.jsxs)(`div`,{className:`flex gap-2 mt-4`,children:[(0,Z.jsx)(`button`,{onClick:()=>m(`form`),className:`px-4 py-2 text-sm font-medium text-white bg-red-500 hover:bg-red-600 rounded-lg transition-colors`,children:i(`bugReport.submit`)}),(0,Z.jsx)(`button`,{onClick:se,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:i(`common.close`)})]})]})]})]})})]})}var qu=[`github.com`,`bambuddy.cool`];function Ju(e){if(!e)return!1;try{let t=new URL(e);if(t.protocol!==`https:`||t.username||t.password||t.port&&t.port!==`443`)return!1;let n=t.hostname.toLowerCase();return qu.some(e=>n===e||n.endsWith(`.${e}`))}catch{return!1}}function Yu(e,t){let{texts:n}=e;if(n[t])return n[t];let r=t.toLowerCase(),i=Object.keys(n).find(e=>e.toLowerCase()===r);if(i)return n[i];let a=r.split(`-`)[0],o=Object.keys(n).find(e=>e.toLowerCase().split(`-`)[0]===a);return o?n[o]:n.en}var Xu={critical:2,important:1,info:0};function Zu(){let{authEnabled:e,user:t,loading:n}=Os(),r=F(),{data:i}=z({queryKey:[`announcements`],queryFn:u.list,enabled:!n&&(!e||!!t),staleTime:300*1e3,refetchInterval:600*1e3}),a=i?.visible??!1,o=(0,W.useMemo)(()=>i?.announcements??[],[i]),{mutate:s}=ie({mutationFn:u.markRead,onMutate:e=>{r.setQueryData([`announcements`],t=>t&&{...t,announcements:t.announcements.map(t=>t.id===e?{...t,read:!0}:t)})},onError:()=>r.invalidateQueries({queryKey:[`announcements`]})}),c=(0,W.useCallback)(e=>s(e),[s]),l=(0,W.useMemo)(()=>o.filter(e=>!e.read&&!e.archived),[o]);return{visible:a,announcements:o,unread:l,bannerItems:(0,W.useMemo)(()=>l.filter(e=>e.level!==`info`).sort((e,t)=>Xu[t.level]-Xu[e.level]),[l]),markRead:c}}var Qu={info:`bg-sky-100 text-sky-800 dark:bg-sky-500/20 dark:text-sky-300`,important:`bg-amber-100 text-amber-800 dark:bg-amber-500/20 dark:text-amber-300`,critical:`bg-red-100 text-red-800 dark:bg-red-500/20 dark:text-red-300`};function $u({open:e,onClose:t,announcements:n,markRead:r,focusId:i}){let{t:a}=v(),[o,s]=(0,W.useState)(()=>new Set),[c,l]=(0,W.useState)(!1),u=(0,W.useRef)(null),d=(0,W.useRef)({announcements:n,markRead:r});d.current={announcements:n,markRead:r};let f=(0,W.useCallback)(e=>{s(t=>new Set(t).add(e));let t=d.current.announcements.find(t=>t.id===e);t&&!t.read&&!t.archived&&d.current.markRead(e)},[]),p=(0,W.useCallback)(e=>{o.has(e)?s(t=>{let n=new Set(t);return n.delete(e),n}):f(e)},[o,f]);if((0,W.useEffect)(()=>{e&&(s(new Set),l(!1),i&&f(i),u.current?.focus())},[e,i,f]),(0,W.useEffect)(()=>{if(!e)return;let n=e=>{e.key===`Escape`&&t()};return window.addEventListener(`keydown`,n),()=>window.removeEventListener(`keydown`,n)},[e,t]),!e)return null;let m=n.filter(e=>!e.archived),h=n.filter(e=>e.archived);return(0,Z.jsxs)(Z.Fragment,{children:[(0,Z.jsx)(`div`,{className:`fixed inset-0 bg-black/60 z-[60]`,onClick:t,"aria-hidden":`true`}),(0,Z.jsxs)(`aside`,{role:`dialog`,"aria-modal":`true`,"aria-labelledby":`announcements-title`,className:`fixed inset-y-0 right-0 z-[61] w-full max-w-md bg-bambu-dark-secondary border-l border-bambu-dark-tertiary flex flex-col shadow-2xl`,children:[(0,Z.jsxs)(`header`,{className:`flex items-center gap-3 px-5 py-4 border-b border-bambu-dark-tertiary`,children:[(0,Z.jsx)(Fo,{className:`w-5 h-5 text-bambu-green`}),(0,Z.jsx)(`h2`,{id:`announcements-title`,className:`text-lg font-semibold text-white`,children:a(`announcements.title`)}),(0,Z.jsx)(`button`,{ref:u,onClick:t,className:`ml-auto p-2 -mr-2 rounded-lg text-bambu-gray-light hover:text-white hover:bg-bambu-dark-tertiary transition-colors`,"aria-label":a(`common.close`),title:a(`common.close`),children:(0,Z.jsx)(_e,{className:`w-5 h-5`})})]}),(0,Z.jsxs)(`div`,{className:`flex-1 overflow-y-auto`,children:[m.length===0?(0,Z.jsx)(`p`,{className:`p-6 text-center text-bambu-gray`,children:a(`announcements.empty`)}):(0,Z.jsx)(`ul`,{className:`divide-y divide-bambu-dark-tertiary`,children:m.map(e=>(0,Z.jsx)(ed,{announcement:e,expanded:o.has(e.id),onToggle:p},e.id))}),h.length>0&&(0,Z.jsxs)(`section`,{className:`border-t border-bambu-dark-tertiary`,children:[(0,Z.jsxs)(`button`,{onClick:()=>l(e=>!e),"aria-expanded":c,className:`w-full flex items-center gap-2 px-5 py-3 text-sm font-medium text-bambu-gray-light hover:text-white hover:bg-bambu-dark-tertiary transition-colors`,children:[c?(0,Z.jsx)(le,{className:`w-4 h-4`}):(0,Z.jsx)(Za,{className:`w-4 h-4`}),a(`announcements.earlier`,{count:h.length})]}),c&&(0,Z.jsx)(`ul`,{className:`divide-y divide-bambu-dark-tertiary opacity-80`,children:h.map(e=>(0,Z.jsx)(ed,{announcement:e,expanded:o.has(e.id),onToggle:p},e.id))})]})]}),(0,Z.jsx)(`footer`,{className:`px-5 py-3 border-t border-bambu-dark-tertiary text-xs text-bambu-gray`,children:a(`announcements.source`)})]})]})}function ed({announcement:e,expanded:t,onToggle:n}){let{t:r,i18n:i}=v(),a=Yu(e,i.language),o=Ju(e.link_url)?e.link_url:null,s=!e.read&&!e.archived,c=`announcement-body-${e.id}`;return(0,Z.jsxs)(`li`,{children:[(0,Z.jsxs)(`button`,{onClick:()=>n(e.id),"aria-expanded":t,"aria-controls":c,className:`w-full text-left px-5 py-3 flex items-start gap-3 hover:bg-bambu-dark-tertiary transition-colors`,children:[(0,Z.jsx)(`span`,{className:`mt-1.5 w-2 h-2 flex-shrink-0 rounded-full`,"aria-hidden":`true`,children:s&&(0,Z.jsx)(`span`,{className:`block w-2 h-2 rounded-full bg-bambu-green`})}),(0,Z.jsxs)(`span`,{className:`flex-1 min-w-0 space-y-1`,children:[(0,Z.jsxs)(`span`,{className:`flex items-center gap-2 flex-wrap text-xs`,children:[(0,Z.jsx)(`span`,{className:`px-2 py-0.5 rounded-full font-semibold ${Qu[e.level]}`,children:r(`announcements.level.${e.level}`)}),s&&(0,Z.jsx)(`span`,{className:`px-2 py-0.5 rounded-full font-semibold bg-bambu-green/20 text-bambu-green`,children:r(`announcements.new`)}),e.published_at&&(0,Z.jsx)(`span`,{className:`ml-auto text-bambu-gray`,children:Ee(e.published_at)})]}),(0,Z.jsx)(`span`,{className:`block text-balance ${s?`text-white font-semibold`:`text-bambu-gray-light font-medium`}`,children:a.title})]}),(0,Z.jsx)(le,{className:`w-4 h-4 mt-1 flex-shrink-0 text-bambu-gray transition-transform ${t?`rotate-180`:``}`,"aria-hidden":`true`})]}),t&&(0,Z.jsxs)(`div`,{id:c,className:`pl-10 pr-5 pb-4 space-y-2`,children:[(0,Z.jsx)(`p`,{className:`text-sm text-bambu-gray-light whitespace-pre-line break-words`,children:a.body}),o&&(0,Z.jsxs)(`a`,{href:o,target:`_blank`,rel:`noopener noreferrer`,className:`inline-flex items-center gap-1 text-sm font-medium text-bambu-green hover:underline`,children:[a.link_label||r(`announcements.readMore`),(0,Z.jsx)(uo,{className:`w-3.5 h-3.5`})]})]})]})}function td({items:e,onOpen:t,markRead:n}){let{t:r,i18n:i}=v(),a=e[0];if(!a)return null;let o=Yu(a,i.language),s=a.level===`critical`;return(0,Z.jsxs)(`div`,{role:s?`alert`:`status`,className:`px-4 py-2 flex items-center gap-3 border-b text-sm ${s?`bg-red-100 dark:bg-red-500/20 border-red-300 dark:border-red-500/30`:`bg-amber-100 dark:bg-amber-500/20 border-amber-300 dark:border-amber-500/30`}`,children:[(0,Z.jsx)(s?ge:Fo,{className:`w-4 h-4 flex-shrink-0 ${s?`text-red-500`:`text-amber-500`}`}),(0,Z.jsxs)(`div`,{className:`flex items-center gap-x-2 gap-y-1 flex-wrap min-w-0`,children:[(0,Z.jsx)(`span`,{className:`font-medium ${s?`text-red-800 dark:text-red-200`:`text-amber-800 dark:text-amber-200`}`,children:o.title}),(0,Z.jsx)(`button`,{onClick:()=>t(a.id),className:`font-medium underline ${s?`text-red-700 dark:text-red-400 hover:text-red-900 dark:hover:text-red-300`:`text-amber-700 dark:text-amber-400 hover:text-amber-900 dark:hover:text-amber-300`}`,children:e.length>1?r(`announcements.readMoreCount`,{count:e.length-1}):r(`announcements.readMore`)})]}),(0,Z.jsx)(`button`,{onClick:()=>n(a.id),className:`ml-auto flex-shrink-0 px-2 py-1 rounded font-medium text-bambu-gray-light hover:text-white hover:bg-bambu-dark-tertiary transition-colors`,children:r(`announcements.gotIt`)})]})}var nd=`sidebarHiddenSystemItems`,rd=`sidebarOrder`,id=`sidebar-layout-changed`;function ad(e){return e.startsWith(`ext-`)}function od(e){let t=localStorage.getItem(rd);if(!t)return e;try{let n=JSON.parse(t);return Array.isArray(n)?n.filter(e=>typeof e==`string`):e}catch{return e}}function sd(e){localStorage.setItem(rd,JSON.stringify(e)),window.dispatchEvent(new CustomEvent(id))}function cd(){let e=localStorage.getItem(nd);if(!e)return[];try{let t=JSON.parse(e);return Array.isArray(t)?t.filter(e=>typeof e==`string`):[]}catch{return[]}}function ld(e){localStorage.setItem(nd,JSON.stringify(Array.from(new Set(e)))),window.dispatchEvent(new CustomEvent(id))}var ud=[{id:`printers`,to:`/`,icon:qo,labelKey:`nav.printers`},{id:`inventory`,to:`/inventory`,icon:co,labelKey:`nav.inventory`},{id:`archives`,to:`/archives`,icon:Wa,labelKey:`nav.archives`},{id:`queue`,to:`/queue`,icon:jo,labelKey:`nav.queue`},{id:`projects`,to:`/projects`,icon:ho,labelKey:`nav.projects`},{id:`files`,to:`/files`,icon:go,labelKey:`nav.files`},{id:`makerworld`,to:`/model-sources`,icon:bo,labelKey:`nav.modelSources`},{id:`profiles`,to:`/profiles`,icon:ro,labelKey:`nav.profiles`},{id:`maintenance`,to:`/maintenance`,icon:Cs,labelKey:`nav.maintenance`},{id:`stats`,to:`/stats`,icon:Xa,labelKey:`nav.stats`},{id:`finance`,to:`/finance`,icon:Yo,labelKey:`nav.finance`},{id:`notifications`,to:`/notifications`,icon:Ga,labelKey:`nav.notifications`},{id:`settings`,to:`/settings`,icon:ns,labelKey:`nav.settings`}];function dd(){return localStorage.getItem(`defaultView`)||`/`}function fd(e){localStorage.setItem(`defaultView`,e)}function pd(){let e=Xr(),t=qr(),{mode:n,resolvedMode:r,toggleMode:i}=js(),{t:a}=v(),s=Us(),[c,l]=(0,W.useState)(!1),[u,d]=(0,W.useState)(!1),f={dark:ls,light:Lo,system:Ro}[n],p=a({dark:`nav.switchToLight`,light:`nav.switchToSystem`,system:`nav.switchToDark`}[n]);dc();let{user:h,authEnabled:g,logout:_,hasPermission:y,hasAnyPermission:x,loading:S}=Os(),{showToast:C}=fe(),[w,T]=(0,W.useState)(!1),[E,D]=(0,W.useState)({currentPassword:``,newPassword:``,confirmPassword:``}),[O,k]=(0,W.useState)(!1),[A,j]=(0,W.useState)(()=>localStorage.getItem(`sidebarExpanded`)!==`false`),[M,N]=(0,W.useState)(!1),[P,F]=(0,W.useState)(!1),[I,ee]=(0,W.useState)(!1),te=(0,W.useMemo)(()=>ud.map(e=>e.id),[]),[ne,L]=(0,W.useState)(()=>od(ud.map(e=>e.id))),[R,re]=(0,W.useState)(cd),ie=(0,W.useRef)(!1),[V,ae]=(0,W.useState)(()=>sessionStorage.getItem(`dismissedUpdateVersion`)),[oe,se]=(0,W.useState)(null),[ce,le]=(0,W.useState)(null),{data:H}=z({queryKey:[`version`],queryFn:o.getVersion,staleTime:1/0}),{data:ue}=z({queryKey:[`ui-flags`],queryFn:o.getUiFlags,staleTime:300*1e3}),{visible:de,announcements:pe,unread:me,bannerItems:ge,markRead:Se}=Zu(),[Ce,we]=(0,W.useState)(!1),[Te,Ee]=(0,W.useState)(null),De=(0,W.useCallback)(e=>{N(!1),Ee(e??null),we(!0)},[]),Oe=(0,W.useCallback)(()=>we(!1),[]);Sc(ue?.currency??`USD`);let ke=cl(),{data:Ae}=z({queryKey:[`default-sidebar-order`],queryFn:o.getDefaultSidebarOrder,staleTime:300*1e3});(0,W.useEffect)(()=>{let e=Ae?.default_sidebar_order;if(!e||g&&!h)return;let t=h?`sidebarDefaultApplied_${h.id}`:`sidebarDefaultApplied`;if(!localStorage.getItem(t))try{let n=JSON.parse(e),r=Array.isArray(n)?n:n.order;if(!Array.isArray(r)||r.length===0)return;let i=new Set(ud.map(e=>e.id)),a=r.filter(e=>typeof e==`string`&&(i.has(e)||ad(e)));if(a.length>0){L(a),sd(a);let e=Array.isArray(n)?[]:n.hiddenSystemItemIds;if(Array.isArray(e)){let t=e.filter(e=>typeof e==`string`&&i.has(e)&&e!==`settings`);re(t),ld(t)}localStorage.setItem(t,`1`)}}catch(e){console.error(`Failed to apply default sidebar order:`,e)}},[Ae?.default_sidebar_order,L,h,g]);let{data:Me}=z({queryKey:[`advancedAuthStatus`],queryFn:o.getAdvancedAuthStatus,staleTime:300*1e3,enabled:g}),{data:Ne}=z({queryKey:[`updateCheck`],queryFn:o.checkForUpdates,enabled:ue?.check_updates!==!1,staleTime:3600*1e3,refetchInterval:3600*1e3}),{data:Pe}=z({queryKey:[`external-links`],queryFn:o.getExternalLinks}),{data:Fe}=z({queryKey:[`smart-plugs`],queryFn:o.getSmartPlugs,staleTime:30*1e3}),Ie=Fe?.some(e=>e.show_in_switchbar)??!1,{data:Le}=z({queryKey:[`debugLogging`],queryFn:b.getDebugLoggingState,staleTime:60*1e3,refetchInterval:60*1e3}),{data:Re}=z({queryKey:[`developer-mode-warnings`],queryFn:o.getDeveloperModeWarnings,staleTime:10*1e3,refetchInterval:30*1e3,refetchOnWindowFocus:!0}),{data:ze}=z({queryKey:[`queue`,`pending`],queryFn:()=>o.getQueue(void 0,`pending`),staleTime:5*1e3,refetchInterval:5*1e3,refetchOnWindowFocus:!0}),G=ze?.length??0,{data:Be}=z({queryKey:[`pending-uploads`,`count`],queryFn:m.getCount,staleTime:5*1e3,refetchInterval:5*1e3,refetchOnWindowFocus:!0}),Ve=Be?.count??0,He=B({queries:(0,W.useMemo)(()=>{let e=new Set;return ze?.forEach(t=>{t.printer_id&&e.add(t.printer_id)}),Array.from(e)},[ze]).map(e=>({queryKey:[`printerStatus`,e],queryFn:()=>o.getPrinterStatus(e),staleTime:30*1e3}))}).some(e=>{let t=e.data;return t?!!t.awaiting_plate_clear:!1}),[Ue,We]=(0,W.useState)(null);(0,W.useEffect)(()=>{if(!Le?.enabled||!Le.enabled_at){We(null);return}let e=je(Le.enabled_at)?.getTime()??Date.now(),t=()=>{We(Math.floor((Date.now()-e)/1e3))};t();let n=setInterval(t,1e3);return()=>clearInterval(n)},[Le?.enabled,Le?.enabled_at]);let Ge=(0,W.useMemo)(()=>new Map(ud.map(e=>[e.id,e])),[]),Ke=(0,W.useMemo)(()=>new Map((Pe||[]).map(e=>[`ext-${e.id}`,e])),[Pe]),qe=(()=>{let e=[],t=new Set,n={archives:[`archives:read`,`archives:read_own`,`archives:read_all`],queue:[`queue:read`,`queue:read_own`,`queue:read_all`],stats:`stats:read`,profiles:`kprofiles:read`,maintenance:`maintenance:read`,projects:`projects:read`,inventory:`inventory:read`,finance:`cost_centers:read_own`,files:[`library:read`,`library:read_own`,`library:read_all`],makerworld:[`makerworld:view`,`manyfold:view`],settings:`settings:read`,notifications:`notifications:user_email`},r=e=>{if(R.includes(e))return!0;if(g&&e in n){let t=n[e];if(!(Array.isArray(t)?t.some(e=>y(e)):y(t)))return!0}return e===`notifications`&&(!g||!Me?.advanced_auth_enabled||ue?.user_notifications_enabled===!1)||e===`finance`&&ue?.billing_enabled!==!0};for(let n of ne)r(n)||(Ge.has(n)||Ke.has(n))&&(e.push(n),t.add(n));for(let n of ud)r(n.id)||t.has(n.id)||(e.push(n.id),t.add(n.id));for(let n of Pe||[]){let r=`ext-${n.id}`;t.has(r)||(e.push(r),t.add(r))}return e})(),Je=Ne?.update_available&&Ne.latest_version&&Ne.latest_version!==V&&!Ne.is_ha_addon,Ye=()=>{Ne?.latest_version&&(sessionStorage.setItem(`dismissedUpdateVersion`,Ne.latest_version),ae(Ne.latest_version))};(0,W.useEffect)(()=>{if(!ie.current&&t.pathname===`/`){let t=dd();t!==`/`&&(ie.current=!0,e(t,{replace:!0}))}},[t.pathname,e]),(0,W.useEffect)(()=>{localStorage.setItem(`sidebarExpanded`,String(A))},[A]),(0,W.useEffect)(()=>{let e=()=>{L(od(te)),re(cd())};return window.addEventListener(id,e),window.addEventListener(`storage`,e),()=>{window.removeEventListener(id,e),window.removeEventListener(`storage`,e)}},[te]),(0,W.useEffect)(()=>{s&&N(!1)},[t.pathname,s]),(0,W.useEffect)(()=>{let e=e=>{if(!y(`printers:control`))return;let t=e.detail;se({printer_id:t.printer_id,printer_name:t.printer_name,message:t.message})};return window.addEventListener(`plate-not-empty`,e),()=>window.removeEventListener(`plate-not-empty`,e)},[y]);let Xe=!S&&x(`archives:update_all`,`archives:update_own`);(0,W.useEffect)(()=>{let e=e=>{let t=e.detail;typeof t?.archive_id==`number`&&le(t.archive_id)};return window.addEventListener(`print-confirm-request`,e),()=>window.removeEventListener(`print-confirm-request`,e)},[]),(0,W.useEffect)(()=>{let n=new URLSearchParams(t.search),r=n.get(`confirm`);if(!r||!/^\d+$/.test(r))return;le(Number(r)),n.delete(`confirm`);let i=n.toString();e({pathname:t.pathname,search:i?`?${i}`:``},{replace:!0})},[t.pathname,t.search,e]);let Ze=(0,W.useCallback)(t=>{let n=t.target;if(!(n.tagName===`INPUT`||n.tagName===`TEXTAREA`||n.isContentEditable)&&!t.metaKey&&!t.ctrlKey&&!t.altKey){let n=parseInt(t.key);if(n>=1&&n<=qe.length&&n<=9){let r=qe[n-1];if(t.preventDefault(),ad(r)){let t=Ke.get(r);t?.open_in_new_tab?window.open(t.url,`_blank`,`noopener,noreferrer`):e(`/external/${r.replace(`ext-`,``)}`)}else{let t=Ge.get(r);t&&e(t.to)}return}switch(t.key){case`?`:t.preventDefault(),F(!0);break;case`Escape`:F(!1);break}}},[e,qe,Ge,Ke]);return(0,W.useEffect)(()=>(document.addEventListener(`keydown`,Ze),()=>document.removeEventListener(`keydown`,Ze)),[Ze]),(0,Z.jsxs)(`div`,{className:`flex min-h-screen`,children:[s&&(0,Z.jsxs)(`header`,{className:`fixed top-0 left-0 right-0 z-40 h-14 bg-bambu-dark-secondary border-b border-bambu-dark-tertiary flex items-center px-4`,children:[(0,Z.jsx)(`button`,{onClick:()=>N(!0),className:`p-2 -ml-2 rounded-lg hover:bg-bambu-dark-tertiary transition-colors`,"aria-label":`Open menu`,children:(0,Z.jsx)(Io,{className:`w-6 h-6 text-white`})}),(0,Z.jsx)(`img`,{src:r===`dark`?`/img/bambuddy_logo_dark_transparent.png`:`/img/bambuddy_logo_light.png`,alt:`Bambuddy`,className:`h-8 ml-3`}),(0,Z.jsx)(`button`,{onClick:()=>l(!0),className:`ml-auto p-2 -mr-2 rounded-lg hover:bg-bambu-dark-tertiary transition-colors ${u?`text-amber-500`:`text-red-500`}`,title:a(u?`bugReport.resumeReport`:`bugReport.title`),"aria-label":a(u?`bugReport.resumeReport`:`bugReport.title`),children:(0,Z.jsx)(Ja,{className:`w-5 h-5 ${u?`animate-pulse`:``}`})})]}),s&&M&&(0,Z.jsx)(`div`,{className:`fixed inset-0 bg-black/60 z-40 transition-opacity`,onClick:()=>N(!1)}),(0,Z.jsxs)(`aside`,{className:`bg-bambu-dark-secondary border-r border-bambu-dark-tertiary flex flex-col transition-all duration-300 ${s?`fixed inset-y-0 left-0 z-50 w-72 transform ${M?`translate-x-0`:`-translate-x-full`}`:`fixed inset-y-0 left-0 z-30 ${A?`w-64`:`w-16`}`}`,children:[(0,Z.jsx)(`div`,{className:`border-b border-bambu-dark-tertiary flex items-center justify-center ${s||A?`p-4`:`p-2`}`,children:(0,Z.jsx)(`img`,{src:r===`dark`?`/img/bambuddy_logo_dark_transparent.png`:`/img/bambuddy_logo_light.png`,alt:`Bambuddy`,className:s||A?`h-16 w-auto`:`h-8 w-8 object-cover object-left`})}),(0,Z.jsx)(`nav`,{className:`flex-1 p-2 overflow-y-auto`,children:(0,Z.jsx)(`ul`,{className:`space-y-2`,children:qe.map(e=>{if(ad(e)){let t=Ke.get(e);if(!t)return null;let n=t.custom_icon?null:Bs(t.icon);return(0,Z.jsx)(`li`,{children:t.open_in_new_tab?(0,Z.jsxs)(`a`,{href:t.url,target:`_blank`,rel:`noopener noreferrer`,className:`flex items-center ${s||A?`gap-3 px-4`:`justify-center px-2`} py-3 rounded-lg transition-colors group text-bambu-gray-light hover:bg-bambu-dark-tertiary hover:text-white`,title:!s&&!A?t.name:void 0,children:[t.custom_icon?(0,Z.jsx)(`img`,{src:o.getExternalLinkIconUrl(t.id),alt:``,className:`w-5 h-5 flex-shrink-0`}):n&&(0,Z.jsx)(n,{className:`w-5 h-5 flex-shrink-0`}),(s||A)&&(0,Z.jsx)(`span`,{children:t.name})]}):(0,Z.jsxs)(ya,{to:`/external/${t.id}`,className:({isActive:e})=>`flex items-center ${s||A?`gap-3 px-4`:`justify-center px-2`} py-3 rounded-lg transition-colors group ${e?`bg-bambu-green text-white`:`text-bambu-gray-light hover:bg-bambu-dark-tertiary hover:text-white`}`,title:!s&&!A?t.name:void 0,children:[t.custom_icon?(0,Z.jsx)(`img`,{src:o.getExternalLinkIconUrl(t.id),alt:``,className:`w-5 h-5 flex-shrink-0`}):n&&(0,Z.jsx)(n,{className:`w-5 h-5 flex-shrink-0`}),(s||A)&&(0,Z.jsx)(`span`,{children:t.name})]})},e)}else{let t=Ge.get(e);if(!t)return null;let{to:n,icon:r,labelKey:i}=t,o=e===`queue`&&G>0,c=e===`archives`&&Ve>0,l=o?G:c?Ve:0,u=o||c,d=e===`printers`&&He;return(0,Z.jsx)(`li`,{children:(0,Z.jsxs)(ya,{to:n,className:({isActive:e})=>`flex items-center ${s||A?`gap-3 px-4`:`justify-center px-2`} py-3 rounded-lg transition-colors group ${e?`bg-bambu-green text-white`:`text-bambu-gray-light hover:bg-bambu-dark-tertiary hover:text-white`}`,title:!s&&!A?a(i):void 0,children:[(0,Z.jsxs)(`div`,{className:`relative`,children:[(0,Z.jsx)(r,{className:`w-5 h-5 flex-shrink-0`}),d&&(0,Z.jsx)(`span`,{className:`absolute -top-0.5 -right-0.5 w-2.5 h-2.5 bg-yellow-500 rounded-full border-2 border-bambu-dark-secondary`}),u&&(0,Z.jsx)(`span`,{className:`absolute -top-1.5 -right-1.5 min-w-[18px] h-[18px] px-1 flex items-center justify-center text-[10px] font-bold rounded-full ${c?`bg-blue-500 text-white`:`bg-yellow-500 text-black`}`,children:l>99?`99+`:l})]}),(s||A)&&(0,Z.jsx)(`span`,{children:a(i)})]})},e)}})})}),!s&&(0,Z.jsx)(`button`,{onClick:()=>j(!A),className:`p-2 mx-2 mb-2 rounded-lg hover:bg-bambu-dark-tertiary transition-colors text-bambu-gray-light hover:text-white flex items-center justify-center`,title:a(A?`nav.collapseSidebar`:`nav.expandSidebar`),children:A?(0,Z.jsx)(Qa,{className:`w-5 h-5`}):(0,Z.jsx)(Za,{className:`w-5 h-5`})}),(0,Z.jsx)(`div`,{className:`flex-shrink-0 p-2 border-t border-bambu-dark-tertiary`,children:s||A?(0,Z.jsxs)(`div`,{className:`flex flex-col gap-2`,children:[(0,Z.jsxs)(`div`,{className:`flex items-center justify-center flex-wrap [&>a]:p-1.5 [&>button]:p-1.5 [&>span]:p-1.5 [&>div>button]:p-1.5`,children:[Ie&&(0,Z.jsxs)(`div`,{className:`relative`,children:[(0,Z.jsx)(`button`,{onMouseEnter:()=>ee(!0),className:`p-2 rounded-lg hover:bg-bambu-dark-tertiary transition-colors ${I?`text-bambu-green`:`text-bambu-gray-light hover:text-white`}`,title:a(`nav.smartSwitches`,{defaultValue:`Smart Switches`}),children:(0,Z.jsx)(Uo,{className:`w-5 h-5`})}),I&&(0,Z.jsx)(Rs,{onClose:()=>ee(!1)})]}),de&&(0,Z.jsxs)(`button`,{onClick:()=>De(),className:`relative p-2 rounded-lg hover:bg-bambu-dark-tertiary transition-colors text-bambu-gray-light hover:text-white`,title:a(`announcements.title`),"aria-label":me.length>0?a(`announcements.unread`,{count:me.length}):a(`announcements.title`),children:[(0,Z.jsx)(Fo,{className:`w-5 h-5`}),me.length>0&&(0,Z.jsx)(`span`,{className:`absolute -top-0.5 -right-0.5 min-w-[16px] h-4 px-1 flex items-center justify-center text-[10px] font-bold rounded-full bg-bambu-green text-white`,children:me.length})]}),y(`system:read`)?(0,Z.jsx)(ya,{to:`/system`,className:({isActive:e})=>`p-2 rounded-lg hover:bg-bambu-dark-tertiary transition-colors ${e?`text-bambu-green`:`text-bambu-gray-light hover:text-white`}`,title:a(`nav.system`),children:(0,Z.jsx)(U,{className:`w-5 h-5`})}):(0,Z.jsx)(`span`,{className:`p-2 rounded-lg text-bambu-gray/50 cursor-not-allowed`,title:`You do not have permission to view system information`,children:(0,Z.jsx)(U,{className:`w-5 h-5`})}),(0,Z.jsx)(Fs,{}),(0,Z.jsx)(`a`,{href:`https://github.com/maziggy/bambuddy`,target:`_blank`,rel:`noopener noreferrer`,className:`p-2 rounded-lg hover:bg-bambu-dark-tertiary transition-colors text-bambu-gray-light hover:text-white`,title:a(`nav.viewOnGithub`),children:(0,Z.jsx)(yo,{className:`w-5 h-5`})}),(0,Z.jsx)(`button`,{onClick:()=>F(!0),className:`p-2 rounded-lg hover:bg-bambu-dark-tertiary transition-colors text-bambu-gray-light hover:text-white`,title:a(`nav.keyboardShortcuts`),children:(0,Z.jsx)(Oo,{className:`w-5 h-5`})}),(0,Z.jsx)(`button`,{onClick:i,className:`p-2 rounded-lg hover:bg-bambu-dark-tertiary transition-colors text-bambu-gray-light hover:text-white`,title:p,children:(0,Z.jsx)(f,{className:`w-5 h-5`})}),g&&h&&(0,Z.jsxs)(Z.Fragment,{children:[(0,Z.jsx)(`button`,{onClick:()=>T(!0),className:`p-2 rounded-lg hover:bg-bambu-dark-tertiary transition-colors text-bambu-gray-light hover:text-white`,title:a(`changePassword.title`),children:(0,Z.jsx)(Do,{className:`w-5 h-5`})}),(0,Z.jsx)(`button`,{onClick:_,className:`p-2 rounded-lg hover:bg-bambu-dark-tertiary transition-colors text-bambu-gray-light hover:text-white`,title:a(`nav.logout`,{defaultValue:`Logout`}),children:(0,Z.jsx)(Mo,{className:`w-5 h-5`})})]})]}),(0,Z.jsxs)(`div`,{className:`flex items-center justify-center gap-2`,children:[(0,Z.jsxs)(`span`,{className:`text-sm text-bambu-gray`,children:[`v`,H?.version||`...`]}),Ne?.update_available&&(0,Z.jsxs)(`button`,{onClick:()=>e(`/settings`),className:`flex items-center gap-1 text-xs text-bambu-green hover:text-bambu-green/80 transition-colors`,title:a(`nav.updateAvailable`,{version:Ne.latest_version}),children:[(0,Z.jsx)($a,{className:`w-4 h-4`}),(0,Z.jsx)(`span`,{children:a(`nav.update`)})]})]})]}):(0,Z.jsxs)(`div`,{className:`flex flex-col items-center gap-1 overflow-y-auto max-h-[50vh]`,children:[Ne?.update_available&&(0,Z.jsx)(`button`,{onClick:()=>e(`/settings`),className:`p-2 rounded-lg hover:bg-bambu-dark-tertiary transition-colors text-bambu-green hover:text-bambu-green/80`,title:a(`nav.updateAvailable`,{version:Ne.latest_version}),children:(0,Z.jsx)($a,{className:`w-5 h-5`})}),Ie&&(0,Z.jsxs)(`div`,{className:`relative`,children:[(0,Z.jsx)(`button`,{onMouseEnter:()=>ee(!0),className:`p-2 rounded-lg hover:bg-bambu-dark-tertiary transition-colors ${I?`text-bambu-green`:`text-bambu-gray-light hover:text-white`}`,title:a(`nav.smartSwitches`,{defaultValue:`Smart Switches`}),children:(0,Z.jsx)(Uo,{className:`w-5 h-5`})}),I&&(0,Z.jsx)(Rs,{onClose:()=>ee(!1)})]}),de&&(0,Z.jsxs)(`button`,{onClick:()=>De(),className:`relative p-2 rounded-lg hover:bg-bambu-dark-tertiary transition-colors text-bambu-gray-light hover:text-white`,title:a(`announcements.title`),"aria-label":me.length>0?a(`announcements.unread`,{count:me.length}):a(`announcements.title`),children:[(0,Z.jsx)(Fo,{className:`w-5 h-5`}),me.length>0&&(0,Z.jsx)(`span`,{className:`absolute top-1 right-1 w-2.5 h-2.5 rounded-full bg-bambu-green ring-2 ring-bambu-dark-secondary`})]}),y(`system:read`)?(0,Z.jsx)(ya,{to:`/system`,className:({isActive:e})=>`p-2 rounded-lg hover:bg-bambu-dark-tertiary transition-colors ${e?`text-bambu-green`:`text-bambu-gray-light hover:text-white`}`,title:a(`nav.system`),children:(0,Z.jsx)(U,{className:`w-5 h-5`})}):(0,Z.jsx)(`span`,{className:`p-2 rounded-lg text-bambu-gray/50 cursor-not-allowed`,title:`You do not have permission to view system information`,children:(0,Z.jsx)(U,{className:`w-5 h-5`})}),(0,Z.jsx)(Fs,{}),(0,Z.jsx)(`a`,{href:`https://github.com/maziggy/bambuddy`,target:`_blank`,rel:`noopener noreferrer`,className:`p-2 rounded-lg hover:bg-bambu-dark-tertiary transition-colors text-bambu-gray-light hover:text-white`,title:a(`nav.viewOnGithub`),children:(0,Z.jsx)(yo,{className:`w-5 h-5`})}),(0,Z.jsx)(`button`,{onClick:()=>F(!0),className:`p-2 rounded-lg hover:bg-bambu-dark-tertiary transition-colors text-bambu-gray-light hover:text-white`,title:a(`nav.keyboardShortcuts`),children:(0,Z.jsx)(Oo,{className:`w-5 h-5`})}),(0,Z.jsx)(`button`,{onClick:i,className:`p-2 rounded-lg hover:bg-bambu-dark-tertiary transition-colors text-bambu-gray-light hover:text-white`,title:p,children:(0,Z.jsx)(f,{className:`w-5 h-5`})}),g&&h&&(0,Z.jsxs)(Z.Fragment,{children:[(0,Z.jsx)(`button`,{onClick:()=>T(!0),className:`p-2 rounded-lg hover:bg-bambu-dark-tertiary transition-colors text-bambu-gray-light hover:text-white`,title:a(`changePassword.title`),children:(0,Z.jsx)(Do,{className:`w-5 h-5`})}),(0,Z.jsx)(`button`,{onClick:_,className:`p-2 rounded-lg hover:bg-bambu-dark-tertiary transition-colors text-bambu-gray-light hover:text-white`,title:a(`nav.logout`,{defaultValue:`Logout`}),children:(0,Z.jsx)(Mo,{className:`w-5 h-5`})})]})]})})]}),(0,Z.jsxs)(`main`,{className:`flex-1 bg-bambu-dark overflow-auto transition-all duration-300 ${s?`mt-14`:A?`ml-64`:`ml-16`}`,children:[Le?.enabled&&(0,Z.jsx)(`div`,{className:`bg-amber-100 dark:bg-amber-500/20 border-b border-amber-300 dark:border-amber-500/30 px-4 py-2 flex items-center justify-between`,children:(0,Z.jsxs)(`div`,{className:`flex items-center gap-2 text-sm`,children:[(0,Z.jsx)(Ja,{className:`w-4 h-4 text-amber-500 animate-pulse`}),(0,Z.jsxs)(`span`,{className:`text-amber-800 dark:text-amber-200`,children:[a(`support.debugLoggingActive`,{defaultValue:`Debug logging is active`}),Ue!==null&&(0,Z.jsxs)(`span`,{className:`text-amber-700/80 dark:text-amber-300/70 ml-2`,children:[`(`,Math.floor(Ue/60),`m `,Ue%60,`s)`]})]}),u&&(0,Z.jsx)(`button`,{onClick:()=>l(!0),className:`text-amber-700 dark:text-amber-400 hover:text-amber-900 dark:hover:text-amber-300 font-medium underline ml-2`,children:a(`bugReport.resumeReport`)}),(0,Z.jsx)(`button`,{onClick:()=>e(`/system`),className:`text-amber-700 dark:text-amber-400 hover:text-amber-900 dark:hover:text-amber-300 font-medium underline ml-2`,children:a(`support.manageLogs`,{defaultValue:`Manage`})})]})}),Re&&Re.length>0&&(0,Z.jsx)(`div`,{className:`bg-orange-100 dark:bg-orange-500/20 border-b border-orange-300 dark:border-orange-500/30 px-4 py-2 flex items-center justify-between`,children:(0,Z.jsxs)(`div`,{className:`flex items-center gap-2 text-sm`,children:[(0,Z.jsx)(rs,{className:`w-4 h-4 text-orange-500`}),(0,Z.jsx)(`span`,{className:`text-orange-800 dark:text-orange-200`,children:a(`printers.developerModeWarning`,{names:Re.map(e=>e.name).join(`, `),defaultValue:`Developer LAN mode is not enabled on: ${Re.map(e=>e.name).join(`, `)}. Some features may not work.`})}),(0,Z.jsx)(`a`,{href:`https://wiki.bambulab.com/en/knowledge-sharing/enable-developer-mode`,target:`_blank`,rel:`noopener noreferrer`,className:`text-orange-700 dark:text-orange-400 hover:text-orange-900 dark:hover:text-orange-300 font-medium underline ml-2`,children:a(`printers.howToEnable`,{defaultValue:`How to enable`})})]})}),(0,Z.jsx)(td,{items:ge,onOpen:De,markRead:Se}),Je&&(0,Z.jsxs)(`div`,{className:`bg-bambu-green/20 border-b border-bambu-green/30 px-4 py-2 flex items-center justify-between`,children:[(0,Z.jsxs)(`div`,{className:`flex items-center gap-2 text-sm`,children:[(0,Z.jsx)($a,{className:`w-4 h-4 text-bambu-green`}),(0,Z.jsx)(`span`,{children:a(`nav.updateAvailableBanner`,{version:Ne?.latest_version,defaultValue:`Version ${Ne?.latest_version} is available!`})}),(0,Z.jsx)(`button`,{onClick:()=>e(`/settings`),className:`text-bambu-green hover:text-bambu-green/80 font-medium underline`,children:a(`nav.viewUpdate`,{defaultValue:`View update`})})]}),(0,Z.jsx)(`button`,{onClick:Ye,className:`p-1 hover:bg-bambu-dark-tertiary rounded transition-colors`,title:a(`common.dismiss`,{defaultValue:`Dismiss`}),children:(0,Z.jsx)(_e,{className:`w-4 h-4`})})]}),(0,Z.jsx)(W.Suspense,{fallback:(0,Z.jsx)(Ts,{}),children:(0,Z.jsx)(J,{})})]}),(0,Z.jsx)($u,{open:Ce,onClose:Oe,announcements:pe,markRead:Se,focusId:Te}),(0,Z.jsx)(ll,{prompt:ke.prompt,isPending:ke.isPending,onConfirm:ke.confirm,onCancel:ke.cancel}),P&&(0,Z.jsx)(Ps,{onClose:()=>F(!1),sidebarItems:qe.map(e=>{if(ad(e)){let t=Ke.get(e);return t?{type:`external`,label:t.name}:null}else{let t=Ge.get(e);return t?{type:`nav`,label:t.labelKey,labelKey:t.labelKey}:null}}).filter(Boolean)}),oe&&(0,Z.jsx)(`div`,{className:`fixed inset-0 bg-black/70 flex items-center justify-center z-[100] p-4`,children:(0,Z.jsx)(`div`,{className:`bg-bambu-dark-secondary border-2 border-yellow-500 rounded-xl shadow-2xl max-w-md w-full animate-in fade-in zoom-in duration-200`,children:(0,Z.jsxs)(`div`,{className:`p-6 text-center`,children:[(0,Z.jsx)(`div`,{className:`w-16 h-16 mx-auto mb-4 rounded-full bg-yellow-500/20 flex items-center justify-center`,children:(0,Z.jsx)(`svg`,{className:`w-10 h-10 text-yellow-500`,fill:`none`,viewBox:`0 0 24 24`,stroke:`currentColor`,strokeWidth:2,children:(0,Z.jsx)(`path`,{strokeLinecap:`round`,strokeLinejoin:`round`,d:`M12 9v2m0 4h.01m-6.938 4h13.856c1.54 0 2.502-1.667 1.732-3L13.732 4c-.77-1.333-2.694-1.333-3.464 0L3.34 16c-.77 1.333.192 3 1.732 3z`})})}),(0,Z.jsx)(`h2`,{className:`text-xl font-bold text-yellow-700 dark:text-yellow-400 mb-2`,children:a(`plateAlert.title`)}),(0,Z.jsx)(`p`,{className:`text-lg text-white mb-2`,children:oe.printer_name}),(0,Z.jsx)(`p`,{className:`text-bambu-gray mb-6`,children:a(`plateAlert.message`)}),(0,Z.jsx)(`button`,{onClick:()=>se(null),className:`w-full py-3 px-6 bg-yellow-500 hover:bg-yellow-600 text-black font-semibold rounded-lg transition-colors`,children:a(`plateAlert.understand`)})]})})}),Xe&&ce!==null&&(0,Z.jsx)(Tu,{archiveId:ce,onClose:()=>le(null)}),w&&(0,Z.jsx)(`div`,{className:`fixed inset-0 bg-black/70 flex items-center justify-center z-50 p-4`,onClick:()=>{T(!1),D({currentPassword:``,newPassword:``,confirmPassword:``})},children:(0,Z.jsxs)(be,{className:`w-full max-w-md`,onClick:e=>e.stopPropagation(),children:[(0,Z.jsx)(ve,{children:(0,Z.jsxs)(`div`,{className:`flex items-center justify-between`,children:[(0,Z.jsxs)(`div`,{className:`flex items-center gap-2`,children:[(0,Z.jsx)(Do,{className:`w-5 h-5 text-bambu-green`}),(0,Z.jsx)(`h2`,{className:`text-lg font-semibold text-white`,children:a(`changePassword.title`)})]}),(0,Z.jsx)(xe,{variant:`ghost`,size:`sm`,onClick:()=>{T(!1),D({currentPassword:``,newPassword:``,confirmPassword:``})},children:(0,Z.jsx)(_e,{className:`w-5 h-5`})})]})}),(0,Z.jsxs)(ye,{children:[(0,Z.jsxs)(`div`,{className:`space-y-4`,children:[(0,Z.jsx)(`input`,{type:`text`,name:`username`,autoComplete:`username`,value:h?.username??``,readOnly:!0,hidden:!0,"aria-hidden":`true`,tabIndex:-1}),(0,Z.jsxs)(`div`,{children:[(0,Z.jsx)(`label`,{className:`block text-sm font-medium text-white mb-2`,children:a(`changePassword.currentPassword`)}),(0,Z.jsx)(`input`,{type:`password`,value:E.currentPassword,onChange:e=>D({...E,currentPassword:e.target.value}),className:`w-full px-4 py-3 bg-bambu-dark-secondary border border-bambu-dark-tertiary rounded-lg text-white placeholder-bambu-gray focus:outline-none focus:ring-2 focus:ring-bambu-green/50 focus:border-bambu-green transition-colors`,placeholder:a(`changePassword.currentPasswordPlaceholder`),autoComplete:`current-password`})]}),(0,Z.jsxs)(`div`,{children:[(0,Z.jsx)(`label`,{className:`block text-sm font-medium text-white mb-2`,children:a(`changePassword.newPassword`)}),(0,Z.jsx)(`input`,{type:`password`,value:E.newPassword,onChange:e=>D({...E,newPassword:e.target.value}),className:`w-full px-4 py-3 bg-bambu-dark-secondary border border-bambu-dark-tertiary rounded-lg text-white placeholder-bambu-gray focus:outline-none focus:ring-2 focus:ring-bambu-green/50 focus:border-bambu-green transition-colors`,placeholder:a(`changePassword.newPasswordPlaceholder`),autoComplete:`new-password`,minLength:6})]}),(0,Z.jsxs)(`div`,{children:[(0,Z.jsx)(`label`,{className:`block text-sm font-medium text-white mb-2`,children:a(`changePassword.confirmPassword`)}),(0,Z.jsx)(`input`,{type:`password`,value:E.confirmPassword,onChange:e=>D({...E,confirmPassword:e.target.value}),className:`w-full px-4 py-3 bg-bambu-dark-secondary border rounded-lg text-white placeholder-bambu-gray focus:outline-none focus:ring-2 focus:ring-bambu-green/50 focus:border-bambu-green transition-colors ${E.confirmPassword&&E.newPassword!==E.confirmPassword?`border-red-500`:`border-bambu-dark-tertiary`}`,placeholder:a(`changePassword.confirmPasswordPlaceholder`),autoComplete:`new-password`,minLength:6}),E.confirmPassword&&E.newPassword!==E.confirmPassword&&(0,Z.jsx)(`p`,{className:`text-red-700 dark:text-red-400 text-xs mt-1`,children:a(`changePassword.passwordsDoNotMatch`)})]})]}),(0,Z.jsxs)(`div`,{className:`mt-6 flex justify-end gap-3`,children:[(0,Z.jsx)(xe,{variant:`secondary`,onClick:()=>{T(!1),D({currentPassword:``,newPassword:``,confirmPassword:``})},children:a(`common.cancel`)}),(0,Z.jsx)(xe,{onClick:async()=>{if(E.newPassword!==E.confirmPassword){C(a(`changePassword.passwordsDoNotMatch`),`error`);return}if(E.newPassword.length<6){C(a(`changePassword.passwordTooShort`),`error`);return}k(!0);try{await o.changePassword(E.currentPassword,E.newPassword),C(a(`changePassword.success`),`success`),T(!1),D({currentPassword:``,newPassword:``,confirmPassword:``})}catch(e){C(e instanceof Error?e.message:a(`changePassword.failed`),`error`)}finally{k(!1)}},disabled:O||!E.currentPassword||!E.newPassword||E.newPassword!==E.confirmPassword||E.newPassword.length<6,children:O?(0,Z.jsxs)(Z.Fragment,{children:[(0,Z.jsx)(he,{className:`w-4 h-4 animate-spin`}),a(`changePassword.changing`)]}):(0,Z.jsxs)(Z.Fragment,{children:[(0,Z.jsx)(Do,{className:`w-4 h-4`}),a(`changePassword.title`)]})})]})]})]})}),(0,Z.jsx)(Ku,{showTrigger:!s,open:c,onOpenChange:l,onLoggingChange:d})]})}var md=[`inventory-locations`];function hd(e){return e.invalidateQueries({queryKey:md})}var gd=[`inventory-suppliers`];function _d(e){return e.invalidateQueries({queryKey:gd})}function vd(e,t){return Promise.all([e.invalidateQueries({queryKey:[...t]}),hd(e)])}var $=4401;function yd(){let e=(0,W.useRef)(null),t=(0,W.useRef)(null),n=(0,W.useRef)(!1),r=F(),[i,a]=(0,W.useState)(!1),s=(0,W.useRef)(new Map),{showToast:c}=fe(),{t:l}=v(),u=(0,W.useRef)(new Set),d=(0,W.useRef)(null),f=(0,W.useRef)(new Map),p=(0,W.useRef)(null),m=(0,W.useRef)([]),g=(0,W.useRef)(!1),_=(0,W.useRef)(()=>{}),y=(0,W.useCallback)(()=>{if(g.current||m.current.length===0)return;g.current=!0;let e=()=>{let t=m.current.shift();t?(_.current(t),m.current.length>0?setTimeout(e,16):g.current=!1):g.current=!1};e()},[]),b=(0,W.useCallback)(async()=>{if(n.current||e.current?.readyState===WebSocket.OPEN)return;let r;try{r=(await o.getWebSocketToken()).token}catch(e){let t=e instanceof h?e.status:0;if(t===401||t===403)return}if(n.current)return;let i=window.location.protocol===`https:`?`wss:`:`ws:`,s=r?`?token=${encodeURIComponent(r)}`:``,c=`${i}//${window.location.host}/api/v1/ws${s}`,l=new WebSocket(c),u=null;l.onopen=()=>{console.log(`[WebSocket] Connected`),a(!0),u=window.setInterval(()=>{l.readyState===WebSocket.OPEN&&l.send(JSON.stringify({type:`ping`}))},3e4)},l.onmessage=e=>{try{let t=JSON.parse(e.data);t.type===`printer_status`&&t.printer_id!==void 0&&t.data?_.current(t):(m.current.push(t),y())}catch{}},l.onclose=r=>{console.log(`[WebSocket] Closed`,r.code,r.reason),u&&=(clearInterval(u),null),a(!1),e.current=null,!(n.current||r.code===$)&&(t.current=window.setTimeout(()=>{b()},3e3))},l.onerror=e=>{console.error(`[WebSocket] Error`,e),l.close()},e.current=l},[y]),x=(0,W.useCallback)(()=>{p.current&&=(clearTimeout(p.current),null);let e=new Map(f.current);f.current.clear(),e.forEach((e,t)=>{r.setQueryData([`printerStatus`,t],t=>{let n={...t,...e};return n.wifi_signal==null&&t?.wifi_signal!=null&&(n.wifi_signal=t.wifi_signal),n})})},[r]),S=(0,W.useCallback)((e,t)=>{let n=f.current.get(e)||{};if(f.current.set(e,{...n,...t}),document.hidden){x();return}p.current||=window.setTimeout(x,100)},[x]),C=(0,W.useCallback)(e=>{u.current.add(e),d.current&&clearTimeout(d.current),d.current=window.setTimeout(()=>{let e=Array.from(u.current);u.current.clear(),d.current=null;let t=0;e.forEach(e=>{setTimeout(()=>{r.invalidateQueries({queryKey:[e]})},t),t+=500})},3e3)},[r]),w=(0,W.useCallback)(()=>{r.invalidateQueries({queryKey:[`spool-assignments`]}),r.invalidateQueries({queryKey:[`spoolman-slot-assignments`]}),r.invalidateQueries({queryKey:[`slotPresets`]})},[r]),T=(0,W.useCallback)(e=>{switch(e.type){case`printer_status`:e.printer_id!==void 0&&e.data&&S(e.printer_id,e.data);break;case`print_start`:e.printer_id!==void 0&&r.invalidateQueries({queryKey:[`printerStatus`,e.printer_id]});break;case`missing_spool_assignment`:{if(e.printer_id===void 0||!Array.isArray(e.missing_slots))break;let t=e.missing_slots.map(e=>e&&typeof e.slot==`string`?e.slot:`Unknown`).filter(e=>e.length>0);if(t.length===0){s.current.delete(e.printer_id);break}let n=t.join(`|`);if(s.current.get(e.printer_id)===n)break;s.current.set(e.printer_id,n),c(l(`printers.toast.missingSpoolAssignment`,{printer:e.printer_name||`Printer ${e.printer_id}`,slots:t.join(`, `)}),`warning`);break}case`print_complete`:C(`archives`),C(`archiveStats`);break;case`print_confirm_request`:{let t=e.data;t?.archive_id!=null&&window.dispatchEvent(new CustomEvent(`print-confirm-request`,{detail:t}));break}case`kill_switch_triggered`:c(l(`printers.toast.killSwitchTriggered`,{printer:e.printer_name||`Printer ${e.printer_id??`?`}`,filename:e.filename||l(`common.unknown`)}),`error`);break;case`billing_charge_failed`:c(l(`printers.toast.billingChargeFailed`,{printer:e.printer_name||`Printer ${e.printer_id??`?`}`,filename:e.filename||l(`common.unknown`)}),`error`);break;case`archive_created`:C(`archives`),C(`archiveStats`);break;case`archive_updated`:C(`archives`);break;case`pong`:break;case`plate_not_empty`:window.dispatchEvent(new CustomEvent(`plate-not-empty`,{detail:{printer_id:e.printer_id,printer_name:e.printer_name,message:e.message}}));break;case`announcements_changed`:C(`announcements`);break;case`printer_locations_changed`:C(`printer-locations`),C(`printers`);break;case`inventory_changed`:C(`inventory-spools`),C(`spoolman-inventory-spools`),C(md[0]),C(gd[0]),C(`material-number-stats`);break;case`spool_assignment_changed`:w();break;case`spool_assignment_verified`:{let t=e.printer_name||`Printer`,n=e.slot||`?`;e.verified?e.kprofile_applied===!1?c(l(`printers.toast.assignmentVerifiedNoKprofile`,{slot:n,printer:t}),`warning`):c(l(`printers.toast.assignmentVerified`,{slot:n,printer:t}),`success`):c(l(`printers.toast.assignmentNotConfirmed`,{slot:n,printer:t}),`warning`);break}case`spool_auto_assigned`:C(`inventory-spools`),w();break;case`spool_usage_logged`:C(`inventory-spools`);break;case`unknown_tag`:{let t=e;window.dispatchEvent(new CustomEvent(`unknown-tag`,{detail:{printer_id:t.printer_id,ams_id:t.ams_id,tray_id:t.tray_id,tag_uid:t.tag_uid,tray_uuid:t.tray_uuid,tray_type:t.tray_type,tray_color:t.tray_color,tray_sub_brands:t.tray_sub_brands,tray_count:t.tray_count}}));break}case`spoolbuddy_weight`:window.dispatchEvent(new CustomEvent(`spoolbuddy-weight`,{detail:e}));break;case`spoolbuddy_tag_matched`:window.dispatchEvent(new CustomEvent(`spoolbuddy-tag-matched`,{detail:e})),C(`inventory-spools`);break;case`spoolbuddy_unknown_tag`:window.dispatchEvent(new CustomEvent(`spoolbuddy-unknown-tag`,{detail:e}));break;case`spoolbuddy_tag_removed`:window.dispatchEvent(new CustomEvent(`spoolbuddy-tag-removed`,{detail:e}));break;case`spoolbuddy_tag_written`:window.dispatchEvent(new CustomEvent(`spoolbuddy-tag-written`,{detail:e})),C(`inventory-spools`);break;case`spoolbuddy_tag_write_failed`:window.dispatchEvent(new CustomEvent(`spoolbuddy-tag-write-failed`,{detail:e}));break;case`spoolbuddy_online`:window.dispatchEvent(new CustomEvent(`spoolbuddy-online`,{detail:e})),C(`spoolbuddy-devices`),C(`spoolbuddy-update-check`);break;case`spoolbuddy_offline`:window.dispatchEvent(new CustomEvent(`spoolbuddy-offline`,{detail:e})),C(`spoolbuddy-devices`);break;case`spoolbuddy_update`:C(`spoolbuddy-devices`),C(`spoolbuddy-update-check`);break;case`queue_item_uploading`:case`queue_item_upload_progress`:case`queue_item_acked`:case`queue_item_failed`:window.dispatchEvent(new CustomEvent(`bambuddy:dispatch-toast`,{detail:e}));break;case`pipeline_run_updated`:r.invalidateQueries({queryKey:[`pipeline-runs-all`]}),e.run?.pipeline_id&&r.invalidateQueries({queryKey:[`pipeline-runs`,e.run.pipeline_id]});break}},[r,C,w,S,c,l]);return(0,W.useEffect)(()=>{_.current=T},[T]),(0,W.useEffect)(()=>(n.current=!1,b(),()=>{n.current=!0,t.current&&clearTimeout(t.current),d.current&&clearTimeout(d.current),p.current&&clearTimeout(p.current),e.current&&e.current.close()}),[b]),{isConnected:i,sendMessage:(0,W.useCallback)(t=>{e.current?.readyState===WebSocket.OPEN&&e.current.send(JSON.stringify(t))},[])}}var bd=`#00ae42`,xd=e=>e!=null&&e>0?e:1/0;function Sd(e){let t=null;for(let n of e){if(!n||n.state!==`RUNNING`||n.progress==null)continue;if(t===null){t=n;continue}let e=xd(n.remaining_time),r=xd(t.remaining_time);(e<r||e===r&&(n.progress??0)>(t.progress??0))&&(t=n)}return t}function Cd(e){let t=document.createElement(`canvas`);t.width=32,t.height=32;let n=t.getContext(`2d`);if(!n)return null;let r=getComputedStyle(document.documentElement).getPropertyValue(`--accent`).trim()||bd,i=Math.max(0,Math.min(100,e))/100,a=-Math.PI/2;return n.lineWidth=4,n.beginPath(),n.arc(16,16,13,0,Math.PI*2),n.strokeStyle=`rgba(128,128,128,0.3)`,n.stroke(),n.beginPath(),n.arc(16,16,13,a,a+i*Math.PI*2),n.strokeStyle=r,n.lineCap=`round`,n.stroke(),t.toDataURL(`image/png`)}function wd(e,t){document.querySelectorAll(`link[rel~="icon"]`).forEach(n=>{if(e)t.has(n)||t.set(n,n.href),n.href=e;else{let e=t.get(n);e!==void 0&&(n.href=e)}}),e||t.clear()}function Td(){let{progressInTitle:e,resolvedMode:t,darkAccent:n,lightAccent:r}=js(),i=t===`dark`?n:r,{data:a}=z({queryKey:[`printers`],queryFn:o.getPrinters,enabled:e}),s=B({queries:(e?a??[]:[]).map(e=>({queryKey:[`printerStatus`,e.id],queryFn:()=>o.getPrinterStatus(e.id)}))}),c=(0,W.useRef)(new Map),l=(0,W.useRef)(document.title),u=(0,W.useRef)(!1),d=e?Sd(s.map(e=>e.data)):null,f=d&&d.progress!=null?Math.round(d.progress):null;(0,W.useEffect)(()=>{e&&f!=null?(document.title=`${f}% · ${l.current}`,wd(Cd(f),c.current),u.current=!0):u.current&&=(document.title=l.current,wd(null,c.current),!1)},[e,f,i]),(0,W.useEffect)(()=>{let e=c.current,t=u,n=l.current;return()=>{t.current&&(document.title=n,wd(null,e))}},[])}function Ed(e){return e.includes(`/camera/`)}function Dd(e,t,n){let r=0;return e.querySelectorAll(`img[src*="/api/v1/"], video[src*="/api/v1/"]`).forEach(e=>{let i=e.getAttribute(`src`)||``,a=Ed(i)?n:t;if(!a)return;let o=`token=${encodeURIComponent(a)}`;if(i.includes(o))return;let s=i.replace(/([?&])token=[^&]*(&|$)/,(e,t,n)=>n===`&`?t:``);e.src=`${s}${s.includes(`?`)?`&`:`?`}${o}`,r+=1}),r}function Od(){let{authEnabled:e,user:t,loading:n,hasPermission:r}=Os(),i=F(),a=(0,W.useRef)(!1),u=!n&&(!e||t!==null),{data:d}=z({queryKey:[`media-token`,t?.id??null],queryFn:()=>o.getMediaToken(),enabled:u,staleTime:3e3*1e3,refetchInterval:3e3*1e3}),f=!e||r(`camera:view`),{data:p}=z({queryKey:[`camera-stream-token`,t?.id??null],queryFn:()=>o.getCameraStreamToken(),enabled:u&&f,staleTime:3e3*1e3,refetchInterval:3e3*1e3}),m=d?.token??null,h=p?.token??null;(0,W.useEffect)(()=>(l(m),c(h),(m||h)&&Dd(document,m,h),()=>{l(null),c(null)}),[m,h]),(0,W.useEffect)(()=>{if(!e)return;let t=e=>{let t=e.target;if(!(t instanceof HTMLImageElement||t instanceof HTMLVideoElement))return;let n=t.src||``,r=Ed(n),o=r?s():g();!o||!n.includes(`token=${encodeURIComponent(o)}`)||a.current||(a.current=!0,i.invalidateQueries({queryKey:r?[`camera-stream-token`]:[`media-token`]}),setTimeout(()=>{a.current=!1},5e3))};return document.addEventListener(`error`,t,!0),()=>document.removeEventListener(`error`,t,!0)},[e,i])}function kd({title:e,message:t,subtitle:n,closeText:r,variant:i=`error`,onClose:a}){let{t:o}=v(),s=r??o(`common.close`);return(0,W.useEffect)(()=>{let e=e=>{e.key===`Escape`&&a()};return window.addEventListener(`keydown`,e),()=>window.removeEventListener(`keydown`,e)},[a]),(0,Z.jsx)(`div`,{className:`fixed inset-0 bg-black/50 flex items-center justify-center p-4 z-[120]`,onClick:a,children:(0,Z.jsx)(be,{className:`w-full max-w-md`,onClick:e=>e.stopPropagation(),children:(0,Z.jsxs)(ye,{className:`p-6`,children:[(0,Z.jsxs)(`div`,{className:`flex items-start gap-4`,children:[(0,Z.jsx)(`div`,{className:`p-2 rounded-full bg-bambu-dark ${i===`warning`?`text-yellow-600 dark:text-yellow-400`:`text-red-600 dark:text-red-400`}`,children:(0,Z.jsx)(ge,{className:`w-6 h-6`})}),(0,Z.jsxs)(`div`,{className:`flex-1 min-w-0`,children:[(0,Z.jsx)(`h3`,{className:`text-lg font-semibold text-white mb-1`,children:e}),n&&(0,Z.jsx)(`p`,{className:`text-xs text-bambu-gray mb-2 truncate`,children:n}),(0,Z.jsx)(`p`,{className:`text-bambu-gray text-sm whitespace-pre-line break-words`,children:t})]})]}),(0,Z.jsx)(`div`,{className:`flex mt-6`,children:(0,Z.jsx)(xe,{onClick:a,className:`flex-1`,children:s})})]})})})}var Ad=(0,W.createContext)(null),jd=1500,Md=1e3,Nd=e=>`slice-job-${e}`;function Pd(e){try{return decodeURIComponent(e)}catch{return e}}function Fd(e){let t=Math.max(0,Math.floor(e));if(t<60)return`${t}s`;let n=Math.floor(t/60),r=t%60;return n<60?`${n}m ${r}s`:`${Math.floor(n/60)}h ${n%60}m`}function Id({children:e}){let{t}=v(),{showToast:n,showPersistentToast:r,dismissToast:i}=fe(),a=F(),[s,c]=(0,W.useState)([]),[l,u]=(0,W.useState)(null),d=(0,W.useRef)([]);d.current=s;let f=(0,W.useRef)(new Map),p=(0,W.useRef)(new Map),m=(0,W.useRef)(new Map),h=(0,W.useRef)(new Set),g=(0,W.useCallback)(e=>{let n=f.current.get(e.id);if(n==null)return;let i=(Date.now()-n)/1e3,a=p.current.get(e.id)??`pending`,o=Fd(i),s=m.current.get(e.id)??null,c=s&&s.stage&&s.total_percent>0;if(a===`running`&&c){let n=Pd(e.sourceName),i=s.stage,a=Math.min(100,Math.max(0,Math.round(s.total_percent))),c=typeof s.multi_plate_index==`number`&&typeof s.multi_plate_count==`number`&&s.multi_plate_count>1?t(`slice.runningWithProgressMultiPlate`,`Plate {{plateIndex}} of {{plateCount}} • {{name}} — {{stage}} ({{percent}}%) — {{elapsed}}`,{plateIndex:s.multi_plate_index,plateCount:s.multi_plate_count,name:n,stage:i,percent:a,elapsed:o}):t(`slice.runningWithProgress`,`{{name}} — {{stage}} ({{percent}}%) — {{elapsed}}`,{name:n,stage:i,percent:a,elapsed:o});r(Nd(e.id),c,`loading`);return}let l=a===`pending`?`slice.queuedToast`:`slice.runningToast`,u=a===`pending`?`Queued: {{name}} — {{elapsed}}`:`Slicing {{name}} — {{elapsed}}`;r(Nd(e.id),t(l,u,{name:Pd(e.sourceName),elapsed:o}),`loading`)},[r,t]),_=(0,W.useCallback)((e,t,n)=>{c(r=>r.some(t=>t.id===e)?r:[...r,{id:e,kind:t,sourceName:n}]),h.current.delete(e),f.current.set(e,Date.now()),p.current.set(e,`pending`),m.current.set(e,null),g({id:e,kind:t,sourceName:n})},[g]),y=(0,W.useCallback)((e,r)=>{h.current.has(e.id)||(h.current.add(e.id),c(t=>t.filter(t=>t.id!==e.id)),f.current.delete(e.id),p.current.delete(e.id),m.current.delete(e.id),i(Nd(e.id)),r.status===`completed`?(n(t(`slice.completedToast`,`Sliced {{name}}`,{name:Pd(e.sourceName)}),`success`),r.result&&`external_write_fallback`in r.result&&r.result.external_write_fallback&&n(t(`slice.externalWriteFallbackToast`,`Saved to the internal library: the external folder could not be written to`),`warning`)):r.status===`failed`&&u({name:Pd(e.sourceName),detail:r.error_detail||t(`slice.failed`)}),a.invalidateQueries({queryKey:[`library-files`]}),a.invalidateQueries({queryKey:[`archives`]}))},[i,a,n,t]);return(0,W.useEffect)(()=>{if(s.length===0)return;let e=!1,t=!1,n=setInterval(async()=>{if(!(e||t)){t=!0;try{let t=[...d.current];for(let n of t)try{let t=await o.getSliceJob(n.id);if(e)return;p.current.set(n.id,t.status),t.progress&&m.current.set(n.id,t.progress),(t.status===`completed`||t.status===`failed`)&&y(n,t)}catch{}}finally{t=!1}}},jd);return()=>{e=!0,clearInterval(n)}},[s.length,y]),(0,W.useEffect)(()=>{if(s.length===0)return;let e=setInterval(()=>{for(let e of d.current)g(e)},Md);return()=>clearInterval(e)},[s.length,g]),(0,Z.jsxs)(Ad.Provider,{value:{trackJob:_,activeJobs:s},children:[e,l&&(0,Z.jsx)(kd,{title:t(`slice.failedTitle`),subtitle:l.name,message:l.detail,onClose:()=>u(null)})]})}function Ld(){let e=(0,W.useContext)(Ad);if(!e)throw Error(`useSliceJobTracker must be used inside SliceJobTrackerProvider`);return e}function Rd({children:e}){let{authEnabled:t,user:n,loading:r}=Os(),{data:i}=z({queryKey:[`color-catalog-map`],queryFn:async()=>{let e=await o.getColorNameMap();return{colors:e.colors,byMaterial:e.by_material??{}}},staleTime:1/0,gcTime:1/0,retry:2,enabled:!r&&(!t||n!==null)});return(0,W.useEffect)(()=>{i&&Js(i.colors,i.byMaterial)},[i]),(0,Z.jsx)(Z.Fragment,{children:e})}function zd({selectedPrinterId:e,onPrinterChange:t,deviceOnline:n}){let{t:r}=v(),[i,a]=(0,W.useState)(new Date),{data:s=[]}=z({queryKey:[`printers`],queryFn:()=>o.getPrinters()}),c=B({queries:s.map(e=>({queryKey:[`printerStatus`,e.id],queryFn:()=>o.getPrinterStatus(e.id),refetchInterval:1e4}))}),l=(0,W.useMemo)(()=>s.filter((e,t)=>c[t]?.data?.connected),[s,c]);(0,W.useEffect)(()=>{let n=l.some(t=>t.id===e);(!e||!n)&&l.length>0&&t(l[0].id)},[l,e,t]);let{data:u}=z({queryKey:[`settings`],queryFn:o.getSettings});return(0,W.useEffect)(()=>{let e=setInterval(()=>a(new Date),1e3);return()=>clearInterval(e)},[]),(0,Z.jsxs)(`div`,{className:`h-12 bg-bambu-dark-secondary border-b border-bambu-dark-tertiary flex items-center px-3 gap-4 shrink-0`,children:[(0,Z.jsx)(`div`,{className:`flex items-center shrink-0`,children:(0,Z.jsx)(`img`,{src:`/img/spoolbuddy_logo_dark_small.png`,alt:`SpoolBuddy`,width:113,height:28,className:`h-7 w-auto`})}),(0,Z.jsx)(`div`,{className:`flex-1 flex justify-center`,children:(0,Z.jsx)(`select`,{value:e??``,onChange:e=>t(Number(e.target.value)),className:`bg-bambu-dark text-white text-base px-4 py-2 rounded border border-bambu-dark-tertiary focus:outline-none focus:border-bambu-green min-w-[180px]`,children:l.length===0?(0,Z.jsx)(`option`,{value:``,children:r(`spoolbuddy.status.noPrinters`,`No printers online`)}):l.map(e=>(0,Z.jsx)(`option`,{value:e.id,children:e.name},e.id))})}),(0,Z.jsxs)(`div`,{className:`flex items-center gap-3 shrink-0`,children:[(0,Z.jsx)(`div`,{className:`flex items-center`,title:n?r(`spoolbuddy.status.backend`,`Backend`):r(`spoolbuddy.status.offline`,`Offline`),children:n?(0,Z.jsx)(`div`,{className:`flex items-end gap-0.5 h-4`,children:[1,2,3,4].map(e=>(0,Z.jsx)(`div`,{className:`w-1 rounded-sm ${e<=4?`bg-white`:`bg-bambu-dark-tertiary`}`,style:{height:`${e*4}px`}},e))}):(0,Z.jsx)(xs,{className:`w-5 h-5 text-red-400`})}),(0,Z.jsxs)(`div`,{className:`flex items-center gap-1.5`,children:[(0,Z.jsx)(`div`,{className:`w-3 h-3 rounded-full ${n?`bg-bambu-green shadow-[0_0_6px_rgba(34,197,94,0.5)]`:`bg-bambu-gray`}`}),(0,Z.jsx)(`span`,{className:`text-sm text-white/50`,children:n?r(`spoolbuddy.status.backend`,`Backend`):r(`spoolbuddy.status.offline`,`Offline`)})]}),(0,Z.jsx)(`span`,{className:`text-white/50 text-base font-mono min-w-[50px] text-right`,children:we(i,u?.time_format||`system`)})]})]})}var Bd=[{to:`/spoolbuddy`,labelKey:`spoolbuddy.nav.dashboard`,fallback:`Dashboard`,icon:(0,Z.jsx)(`svg`,{className:`w-6 h-6`,fill:`none`,viewBox:`0 0 24 24`,stroke:`currentColor`,children:(0,Z.jsx)(`path`,{strokeLinecap:`round`,strokeLinejoin:`round`,strokeWidth:2,d:`M3 12l2-2m0 0l7-7 7 7M5 10v10a1 1 0 001 1h3m10-11l2 2m-2-2v10a1 1 0 01-1 1h-3m-6 0a1 1 0 001-1v-4a1 1 0 011-1h2a1 1 0 011 1v4a1 1 0 001 1m-6 0h6`})})},{to:`/spoolbuddy/ams`,labelKey:`spoolbuddy.nav.ams`,fallback:`AMS`,icon:(0,Z.jsx)(`svg`,{className:`w-6 h-6`,fill:`none`,viewBox:`0 0 24 24`,stroke:`currentColor`,children:(0,Z.jsx)(`path`,{strokeLinecap:`round`,strokeLinejoin:`round`,strokeWidth:2,d:`M19 11H5m14 0a2 2 0 012 2v6a2 2 0 01-2 2H5a2 2 0 01-2-2v-6a2 2 0 012-2m14 0V9a2 2 0 00-2-2M5 11V9a2 2 0 012-2m0 0V5a2 2 0 012-2h6a2 2 0 012 2v2M7 7h10`})})},{to:`/spoolbuddy/write-tag`,labelKey:`spoolbuddy.nav.writeTag`,fallback:`Write`,icon:(0,Z.jsxs)(`svg`,{className:`w-6 h-6`,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:2,children:[(0,Z.jsx)(`path`,{strokeLinecap:`round`,strokeLinejoin:`round`,d:`M8.288 15.038a5.25 5.25 0 017.424 0M5.106 11.856c3.807-3.808 9.98-3.808 13.788 0M1.924 8.674c5.565-5.565 14.587-5.565 20.152 0`}),(0,Z.jsx)(`path`,{strokeLinecap:`round`,strokeLinejoin:`round`,d:`M12.53 18.22l-.53.53-.53-.53a.75.75 0 011.06 0z`})]})},{to:`/spoolbuddy/inventory`,labelKey:`spoolbuddy.nav.inventory`,fallback:`Inventory`,icon:(0,Z.jsx)(`svg`,{className:`w-6 h-6`,fill:`none`,viewBox:`0 0 24 24`,stroke:`currentColor`,children:(0,Z.jsx)(`path`,{strokeLinecap:`round`,strokeLinejoin:`round`,strokeWidth:2,d:`M20 7l-8-4-8 4m16 0l-8 4m8-4v10l-8 4m0-10L4 7m8 4v10M4 7v10l8 4`})})},{to:`/spoolbuddy/settings`,labelKey:`spoolbuddy.nav.settings`,fallback:`Settings`,icon:(0,Z.jsxs)(`svg`,{className:`w-6 h-6`,fill:`none`,viewBox:`0 0 24 24`,stroke:`currentColor`,children:[(0,Z.jsx)(`path`,{strokeLinecap:`round`,strokeLinejoin:`round`,strokeWidth:2,d:`M10.325 4.317c.426-1.756 2.924-1.756 3.35 0a1.724 1.724 0 002.573 1.066c1.543-.94 3.31.826 2.37 2.37a1.724 1.724 0 001.066 2.573c1.756.426 1.756 2.924 0 3.35a1.724 1.724 0 00-1.066 2.573c.94 1.543-.826 3.31-2.37 2.37a1.724 1.724 0 00-2.573 1.066c-.426 1.756-2.924 1.756-3.35 0a1.724 1.724 0 00-2.573-1.066c-1.543.94-3.31-.826-2.37-2.37a1.724 1.724 0 00-1.066-2.573c-1.756-.426-1.756-2.924 0-3.35a1.724 1.724 0 001.066-2.573c-.94-1.543.826-3.31 2.37-2.37.996.608 2.296.07 2.572-1.065z`}),(0,Z.jsx)(`path`,{strokeLinecap:`round`,strokeLinejoin:`round`,strokeWidth:2,d:`M15 12a3 3 0 11-6 0 3 3 0 016 0z`})]})}];function Vd(){let{t:e}=v();return(0,Z.jsx)(`nav`,{className:`h-14 bg-bambu-dark-secondary border-t border-bambu-dark-tertiary flex items-stretch shrink-0`,children:Bd.map(t=>(0,Z.jsxs)(ya,{to:t.to,end:t.to===`/spoolbuddy`,className:({isActive:e})=>`flex-1 flex flex-col items-center justify-center gap-1 transition-colors ${e?`text-bambu-green bg-bambu-dark`:`text-white/50 hover:text-white/70 hover:bg-bambu-dark-tertiary`}`,children:[t.icon,(0,Z.jsx)(`span`,{className:`text-xs font-medium`,children:e(t.labelKey,t.fallback)})]},t.to))})}function Hd({alert:e}){let{t}=v(),n=e?e.type===`error`?`bg-red-500`:e.type===`warning`?`bg-amber-500`:`bg-bambu-green`:`bg-bambu-green`;return(0,Z.jsxs)(`div`,{className:`h-9 bg-bambu-dark-secondary border-t-2 ${e?e.type===`error`?`border-red-500`:e.type===`warning`?`border-amber-500`:`border-bambu-dark-tertiary`:`border-bambu-dark-tertiary`} flex items-center px-3 gap-3 shrink-0`,children:[(0,Z.jsx)(`div`,{className:`w-3.5 h-3.5 rounded-full ${n}`}),(0,Z.jsx)(`div`,{className:`flex-1 text-sm text-white/50 truncate`,children:e?(0,Z.jsx)(`span`,{children:e.message}):(0,Z.jsx)(`span`,{className:`text-bambu-green`,children:t(`spoolbuddy.status.systemReady`,`System Ready`)})})]})}function Ud({isOpen:e,onClose:t,deviceId:n,deviceOnline:r}){let{t:i}=v(),[a,s]=(0,W.useState)(null),[c,l]=(0,W.useState)(!1),[u,d]=(0,W.useState)(new Map),{data:f=[]}=z({queryKey:[`printers`],queryFn:()=>o.getPrinters(),enabled:e}),{data:p=[]}=z({queryKey:[`smart-plugs`],queryFn:()=>o.getSmartPlugs(),enabled:e}),m=f.map(e=>{let t=p.find(t=>t.printer_id===e.id&&t.plug_type!==`mqtt`&&t.enabled);if(!t)return null;let n=u.get(t.id);return{plug:t,printer:e,status:n?{state:n.state,reachable:!0,device_name:null,energy:null}:null,loading:n?.loading??!1}}).filter(Boolean);(0,W.useEffect)(()=>{!e||p.length===0||p.filter(e=>e.printer_id!==null&&e.plug_type!==`mqtt`&&e.enabled).forEach(async e=>{try{let t=await o.getSmartPlugStatus(e.id);d(n=>{let r=new Map(n);return r.set(e.id,{loading:!1,state:t.state}),r})}catch{d(t=>{let n=new Map(t);return n.set(e.id,{loading:!1,state:null}),n})}})},[e,p]),(0,W.useEffect)(()=>{e||(s(null),l(!1))},[e]);let h=(0,W.useCallback)(async e=>{d(t=>{let n=new Map(t),r=n.get(e.id);return n.set(e.id,{loading:!0,state:r?.state??null}),n});try{await o.controlSmartPlug(e.id,`toggle`);let t=await o.getSmartPlugStatus(e.id);d(n=>{let r=new Map(n);return r.set(e.id,{loading:!1,state:t.state}),r})}catch{d(t=>{let n=new Map(t),r=n.get(e.id);return n.set(e.id,{loading:!1,state:r?.state??null}),n})}},[]),g=(0,W.useCallback)(async e=>{if(n){l(!0);try{await _.systemCommand(n,e),setTimeout(()=>t(),500)}catch{l(!1)}}},[n,t]),y=(0,W.useCallback)(()=>{a&&(a.type===`system`?g(a.command):h(a.plug),s(null))},[a,g,h]);if(!e)return null;let b=e=>e===`ON`||e===`on`;return(0,Z.jsxs)(Z.Fragment,{children:[(0,Z.jsx)(`div`,{className:`fixed inset-0 z-40 bg-black/50`,onPointerDown:t}),(0,Z.jsxs)(`div`,{className:`fixed top-0 left-0 right-0 z-50 bg-bambu-dark-secondary border-b border-bambu-dark-tertiary rounded-b-2xl shadow-2xl animate-slide-down`,children:[(0,Z.jsx)(`div`,{className:`flex justify-center pt-2 pb-1`,children:(0,Z.jsx)(`div`,{className:`w-10 h-1 rounded-full bg-zinc-600`})}),(0,Z.jsxs)(`div`,{className:`px-4 pb-4 max-h-[80vh] overflow-y-auto`,children:[m.length>0&&(0,Z.jsxs)(`div`,{className:`mb-4`,children:[(0,Z.jsx)(`h3`,{className:`text-xs font-semibold text-zinc-500 uppercase tracking-wide mb-2`,children:i(`spoolbuddy.quickMenu.printerPower`,`Printer Power`)}),(0,Z.jsx)(`div`,{className:`space-y-1`,children:m.map(({plug:e,printer:t,loading:n})=>{let r=u.get(e.id),i=b(r?.state??null);return(0,Z.jsxs)(`button`,{onClick:()=>s({type:`plug`,plug:e,printer:t,currentState:r?.state??null}),disabled:n,className:`w-full flex items-center gap-2 px-3 py-1.5 rounded-lg bg-zinc-800/60 hover:bg-zinc-700/60 transition-colors min-h-[36px]`,children:[(0,Z.jsx)(`div`,{className:`w-2 h-2 rounded-full shrink-0 ${i?`bg-green-500`:`bg-zinc-600`}`}),n&&(0,Z.jsx)(he,{className:`w-3 h-3 animate-spin text-zinc-400 shrink-0`}),(0,Z.jsx)(`span`,{className:`flex-1 text-sm text-zinc-200 text-left truncate`,children:t.name}),(0,Z.jsx)(`span`,{className:`text-xs font-medium ${i?`text-green-400`:`text-zinc-500`}`,children:r?.state??`—`})]},e.id)})})]}),(0,Z.jsxs)(`div`,{children:[(0,Z.jsx)(`h3`,{className:`text-xs font-semibold text-zinc-500 uppercase tracking-wide mb-2`,children:i(`spoolbuddy.quickMenu.systemControls`,`System`)}),(0,Z.jsxs)(`div`,{className:`grid grid-cols-2 gap-2`,children:[(0,Z.jsx)(Wd,{icon:(0,Z.jsx)(Qo,{className:`w-4 h-4`}),label:i(`spoolbuddy.quickMenu.restartDaemon`,`Restart Daemon`),onClick:()=>s({type:`system`,command:`restart_daemon`}),disabled:!n||!r||c}),(0,Z.jsx)(Wd,{icon:(0,Z.jsx)(Lo,{className:`w-4 h-4`}),label:i(`spoolbuddy.quickMenu.restartBrowser`,`Restart Browser`),onClick:()=>s({type:`system`,command:`restart_browser`}),disabled:!n||!r||c}),(0,Z.jsx)(Wd,{icon:(0,Z.jsx)(Qo,{className:`w-4 h-4`}),label:i(`spoolbuddy.quickMenu.reboot`,`Reboot`),onClick:()=>s({type:`system`,command:`reboot`}),disabled:!n||!r||c,variant:`warning`}),(0,Z.jsx)(Wd,{icon:(0,Z.jsx)(Go,{className:`w-4 h-4`}),label:i(`spoolbuddy.quickMenu.shutdown`,`Shutdown`),onClick:()=>s({type:`system`,command:`shutdown`}),disabled:!n||!r||c,variant:`danger`})]})]}),(0,Z.jsx)(`div`,{className:`flex justify-center mt-3`,children:(0,Z.jsxs)(`div`,{className:`flex items-center gap-1 text-xs text-zinc-600`,children:[(0,Z.jsx)(le,{className:`w-3 h-3`}),(0,Z.jsx)(`span`,{children:i(`spoolbuddy.quickMenu.swipeToClose`,`Swipe down to close`)})]})})]})]}),a&&(0,Z.jsx)(`div`,{className:`fixed inset-0 z-[60] flex items-center justify-center bg-black/60`,children:(0,Z.jsxs)(`div`,{className:`bg-zinc-800 rounded-2xl p-5 mx-4 max-w-sm w-full border border-zinc-700`,children:[(0,Z.jsx)(`h3`,{className:`text-lg font-semibold text-zinc-100 mb-2`,children:i(`spoolbuddy.quickMenu.confirmTitle`,`Confirm`)}),(0,Z.jsx)(`p`,{className:`text-sm text-zinc-400 mb-5`,children:a.type===`plug`?b(a.currentState)?i(`spoolbuddy.quickMenu.confirmPlugOff`,`Turn off {{name}}?`,{name:a.printer.name}):i(`spoolbuddy.quickMenu.confirmPlugOn`,`Turn on {{name}}?`,{name:a.printer.name}):a.command===`shutdown`?i(`spoolbuddy.quickMenu.confirmShutdown`,`Are you sure you want to shut down the SpoolBuddy? You will need physical access to turn it back on.`):a.command===`reboot`?i(`spoolbuddy.quickMenu.confirmReboot`,`Are you sure you want to reboot the SpoolBuddy?`):a.command===`restart_daemon`?i(`spoolbuddy.quickMenu.confirmRestartDaemon`,`Restart the SpoolBuddy daemon? NFC and scale will be temporarily unavailable.`):i(`spoolbuddy.quickMenu.confirmRestartBrowser`,`Restart the kiosk browser? The display will briefly go blank.`)}),(0,Z.jsxs)(`div`,{className:`flex gap-3`,children:[(0,Z.jsx)(`button`,{onClick:()=>s(null),className:`flex-1 px-4 py-2.5 rounded-lg text-sm font-medium bg-zinc-700 text-zinc-300 hover:bg-zinc-600 transition-colors min-h-[44px]`,children:i(`common.cancel`,`Cancel`)}),(0,Z.jsx)(`button`,{onClick:y,disabled:c,className:`flex-1 px-4 py-2.5 rounded-lg text-sm font-medium text-white transition-colors min-h-[44px] ${a.type===`plug`?b(a.currentState)?`bg-red-600 hover:bg-red-700`:`bg-green-600 hover:bg-green-700`:a.command===`shutdown`?`bg-red-600 hover:bg-red-700`:a.command===`reboot`?`bg-amber-600 hover:bg-amber-700`:`bg-blue-600 hover:bg-blue-700`} disabled:opacity-50`,children:c?(0,Z.jsx)(he,{className:`w-4 h-4 animate-spin mx-auto`}):a.type===`plug`?b(a.currentState)?i(`spoolbuddy.quickMenu.turnOff`,`Turn Off`):i(`spoolbuddy.quickMenu.turnOn`,`Turn On`):i(`spoolbuddy.quickMenu.confirm`,`Confirm`)})]})]})})]})}function Wd({icon:e,label:t,onClick:n,disabled:r,variant:i=`default`}){return(0,Z.jsxs)(`button`,{onClick:n,disabled:r,className:`flex items-center gap-2.5 p-3 rounded-xl transition-colors min-h-[48px] disabled:opacity-40 ${{default:`bg-zinc-800/60 hover:bg-zinc-700/60 text-zinc-300`,warning:`bg-amber-900/30 hover:bg-amber-900/50 text-amber-400`,danger:`bg-red-900/30 hover:bg-red-900/50 text-red-400`}[i]}`,children:[e,(0,Z.jsx)(`span`,{className:`text-sm font-medium`,children:t})]})}var Gd={weight:null,weightStable:!1,rawAdc:null,matchedSpool:null,unknownTagUid:null,unknownTrayUuid:null,deviceOnline:!1,deviceId:null};function Kd(e,t){switch(t.type){case`WEIGHT_UPDATE`:return{...e,weight:t.weight,weightStable:t.stable,rawAdc:t.rawAdc,deviceId:t.deviceId,deviceOnline:!0};case`TAG_MATCHED`:return{...e,matchedSpool:t.spool,unknownTagUid:null,unknownTrayUuid:null,deviceId:t.deviceId};case`UNKNOWN_TAG`:return{...e,matchedSpool:null,unknownTagUid:t.tagUid,unknownTrayUuid:t.trayUuid??null,deviceId:t.deviceId};case`TAG_REMOVED`:return{...e,matchedSpool:null,unknownTagUid:null,unknownTrayUuid:null};case`DEVICE_ONLINE`:return{...e,deviceOnline:!0,deviceId:t.deviceId};case`DEVICE_OFFLINE`:return{...e,deviceOnline:!1,weight:null,weightStable:!1,rawAdc:null};default:return e}}function qd(){let[e,t]=(0,W.useReducer)(Kd,Gd),n=(0,W.useCallback)(e=>{let n=e.detail;t({type:`WEIGHT_UPDATE`,weight:n.weight_grams??n.data?.weight_grams,stable:n.stable??n.data?.stable??!1,rawAdc:n.raw_adc??n.data?.raw_adc??null,deviceId:n.device_id??n.data?.device_id??``})},[]),r=(0,W.useCallback)(e=>{let n=e.detail,r=n.spool??n.data?.spool;r&&t({type:`TAG_MATCHED`,spool:{id:r.id,tag_uid:n.tag_uid??n.data?.tag_uid??``,material:r.material??``,subtype:r.subtype??null,color_name:r.color_name??null,color_name_is_synthesized:r.color_name_is_synthesized??!1,rgba:r.rgba??null,extra_colors:r.extra_colors??null,effect_type:r.effect_type??null,brand:r.brand??null,label_weight:r.label_weight??0,core_weight:r.core_weight??0,weight_used:r.weight_used??0},deviceId:n.device_id??n.data?.device_id??``})},[]),i=(0,W.useCallback)(e=>{let n=e.detail;t({type:`UNKNOWN_TAG`,tagUid:n.tag_uid??n.data?.tag_uid??``,trayUuid:n.tray_uuid??n.data?.tray_uuid??null,deviceId:n.device_id??n.data?.device_id??``})},[]),a=(0,W.useCallback)(e=>{let n=e.detail;t({type:`TAG_REMOVED`,deviceId:n.device_id??n.data?.device_id??``})},[]),o=(0,W.useCallback)(e=>{let n=e.detail;t({type:`DEVICE_ONLINE`,deviceId:n.device_id??n.data?.device_id??``})},[]),s=(0,W.useCallback)(e=>{let n=e.detail;t({type:`DEVICE_OFFLINE`,deviceId:n.device_id??n.data?.device_id??``})},[]);(0,W.useEffect)(()=>(window.addEventListener(`spoolbuddy-weight`,n),window.addEventListener(`spoolbuddy-tag-matched`,r),window.addEventListener(`spoolbuddy-unknown-tag`,i),window.addEventListener(`spoolbuddy-tag-removed`,a),window.addEventListener(`spoolbuddy-online`,o),window.addEventListener(`spoolbuddy-offline`,s),()=>{window.removeEventListener(`spoolbuddy-weight`,n),window.removeEventListener(`spoolbuddy-tag-matched`,r),window.removeEventListener(`spoolbuddy-unknown-tag`,i),window.removeEventListener(`spoolbuddy-tag-removed`,a),window.removeEventListener(`spoolbuddy-online`,o),window.removeEventListener(`spoolbuddy-offline`,s)}),[n,r,i,a,o,s]);let c=e.matchedSpool?Math.max(0,e.matchedSpool.label_weight-e.matchedSpool.weight_used):null,l=e.weight!==null&&e.matchedSpool?Math.max(0,e.weight-e.matchedSpool.core_weight):null;return{...e,remainingWeight:c,netWeight:l}}var Jd=e(t(((e,t)=>{(function(n,i){typeof e==`object`&&typeof t==`object`?t.exports=i(r()):typeof define==`function`&&define.amd?define([`react`],i):typeof e==`object`?e.ReactSimpleKeyboard=i(r()):n.ReactSimpleKeyboard=i(n.React)})(e,(function(e){return function(){var t={981:function(){typeof Element>`u`||`remove`in Element.prototype||(Element.prototype.remove=function(){this.parentNode&&this.parentNode.removeChild(this)}),typeof self<`u`&&`document`in self&&((!(`classList`in document.createElement(`_`))||document.createElementNS&&!(`classList`in document.createElementNS(`http://www.w3.org/2000/svg`,`g`)))&&function(e){if(`Element`in e){var t=`classList`,n=`prototype`,r=e.Element[n],i=Object,a=String[n].trim||function(){return this.replace(/^\s+|\s+$/g,``)},o=Array[n].indexOf||function(e){for(var t=0,n=this.length;t<n;t++)if(t in this&&this[t]===e)return t;return-1},s=function(e,t){this.name=e,this.code=DOMException[e],this.message=t},c=function(e,t){if(t===``)throw new s(`SYNTAX_ERR`,`The token must not be empty.`);if(/\s/.test(t))throw new s(`INVALID_CHARACTER_ERR`,`The token must not contain space characters.`);return o.call(e,t)},l=function(e){for(var t=a.call(e.getAttribute(`class`)||``),n=t?t.split(/\s+/):[],r=0,i=n.length;r<i;r++)this.push(n[r]);this._updateClassName=function(){e.setAttribute(`class`,this.toString())}},u=l[n]=[],d=function(){return new l(this)};if(s[n]=Error[n],u.item=function(e){return this[e]||null},u.contains=function(e){return~c(this,e+``)},u.add=function(){var e,t=arguments,n=0,r=t.length,i=!1;do~c(this,e=t[n]+``)||(this.push(e),i=!0);while(++n<r);i&&this._updateClassName()},u.remove=function(){var e,t,n=arguments,r=0,i=n.length,a=!1;do for(t=c(this,e=n[r]+``);~t;)this.splice(t,1),a=!0,t=c(this,e);while(++r<i);a&&this._updateClassName()},u.toggle=function(e,t){var n=this.contains(e),r=n?!0!==t&&`remove`:!1!==t&&`add`;return r&&this[r](e),!0===t||!1===t?t:!n},u.replace=function(e,t){var n=c(e+``);~n&&(this.splice(n,1,t),this._updateClassName())},u.toString=function(){return this.join(` `)},i.defineProperty){var f={get:d,enumerable:!0,configurable:!0};try{i.defineProperty(r,t,f)}catch(e){e.number!==void 0&&e.number!==-2146823252||(f.enumerable=!1,i.defineProperty(r,t,f))}}else i[n].__defineGetter__&&r.__defineGetter__(t,d)}}(self),function(){var e=document.createElement(`_`);if(e.classList.add(`c1`,`c2`),!e.classList.contains(`c2`)){var t=function(e){var t=DOMTokenList.prototype[e];DOMTokenList.prototype[e]=function(e){var n,r=arguments.length;for(n=0;n<r;n++)e=arguments[n],t.call(this,e)}};t(`add`),t(`remove`)}if(e.classList.toggle(`c3`,!1),e.classList.contains(`c3`)){var n=DOMTokenList.prototype.toggle;DOMTokenList.prototype.toggle=function(e,t){return 1 in arguments&&!this.contains(e)==!t?t:n.call(this,e)}}`replace`in document.createElement(`_`).classList||(DOMTokenList.prototype.replace=function(e,t){var n=this.toString().split(` `),r=n.indexOf(e+``);~r&&(n=n.slice(r),this.remove.apply(this,n),this.add(t),this.add.apply(this,n.slice(1)))}),e=null}())},548:function(e){e.exports=function(){var e={9306:function(e,t,n){var r=n(4901),i=n(6823),a=TypeError;e.exports=function(e){if(r(e))return e;throw new a(i(e)+` is not a function`)}},5548:function(e,t,n){var r=n(3517),i=n(6823),a=TypeError;e.exports=function(e){if(r(e))return e;throw new a(i(e)+` is not a constructor`)}},3506:function(e,t,n){var r=n(3925),i=String,a=TypeError;e.exports=function(e){if(r(e))return e;throw new a(`Can't set `+i(e)+` as a prototype`)}},6469:function(e,t,n){var r=n(8227),i=n(2360),a=n(4913).f,o=r(`unscopables`),s=Array.prototype;s[o]===void 0&&a(s,o,{configurable:!0,value:i(null)}),e.exports=function(e){s[o][e]=!0}},7829:function(e,t,n){var r=n(8183).charAt;e.exports=function(e,t,n){return t+(n?r(e,t).length:1)}},8551:function(e,t,n){var r=n(34),i=String,a=TypeError;e.exports=function(e){if(r(e))return e;throw new a(i(e)+` is not an object`)}},235:function(e,t,n){var r=n(9213).forEach;e.exports=n(4598)(`forEach`)?[].forEach:function(e){return r(this,e,arguments.length>1?arguments[1]:void 0)}},7916:function(e,t,n){var r=n(6080),i=n(9565),a=n(8981),o=n(6319),s=n(4209),c=n(3517),l=n(6198),u=n(4659),d=n(4527),f=n(81),p=n(851),m=Array;e.exports=function(e){var t=a(e),n=c(this),h=arguments.length,g=h>1?arguments[1]:void 0,_=g!==void 0;_&&(g=r(g,h>2?arguments[2]:void 0));var v,y,b,x,S,C,w=p(t),T=0;if(!w||this===m&&s(w))for(v=l(t),y=n?new this(v):m(v);v>T;T++)C=_?g(t[T],T):t[T],u(y,T,C);else for(y=n?new this:[],S=(x=f(t,w)).next;!(b=i(S,x)).done;T++)C=_?o(x,g,[b.value,T],!0):b.value,u(y,T,C);return d(y,T),y}},9617:function(e,t,n){var r=n(5397),i=n(5610),a=n(6198),o=function(e){return function(t,n,o){var s=r(t),c=a(s);if(c===0)return!e&&-1;var l,u=i(o,c);if(e&&n!=n){for(;c>u;)if((l=s[u++])!=l)return!0}else for(;c>u;u++)if((e||u in s)&&s[u]===n)return e||u||0;return!e&&-1}};e.exports={includes:o(!0),indexOf:o(!1)}},9213:function(e,t,n){var r=n(6080),i=n(7055),a=n(8981),o=n(6198),s=n(1469),c=n(4659),l=function(e){var t=e===1,n=e===2,l=e===3,u=e===4,d=e===6,f=e===7,p=e===5||d;return function(m,h,g){for(var _,v,y=a(m),b=i(y),x=o(b),S=r(h,g),C=0,w=0,T=t?s(m,x):n||f?s(m,0):void 0;x>C;C++)if((p||C in b)&&(v=S(_=b[C],C,y),e))if(t)c(T,C,v);else if(v)switch(e){case 3:return!0;case 5:return _;case 6:return C;case 2:c(T,w++,_)}else switch(e){case 4:return!1;case 7:c(T,w++,_)}return d?-1:l||u?u:T}};e.exports={forEach:l(0),map:l(1),filter:l(2),some:l(3),every:l(4),find:l(5),findIndex:l(6),filterReject:l(7)}},597:function(e,t,n){var r=n(9039),i=n(8227),a=n(9519),o=i(`species`);e.exports=function(e){return a>=51||!r((function(){var t=[];return(t.constructor={})[o]=function(){return{foo:1}},t[e](Boolean).foo!==1}))}},4598:function(e,t,n){var r=n(9039);e.exports=function(e,t){var n=[][e];return!!n&&r((function(){n.call(null,t||function(){return 1},1)}))}},926:function(e,t,n){var r=n(9306),i=n(8981),a=n(7055),o=n(6198),s=TypeError,c=`Reduce of empty array with no initial value`,l=function(e){return function(t,n,l,u){var d=i(t),f=a(d),p=o(d);if(r(n),p===0&&l<2)throw new s(c);var m=e?p-1:0,h=e?-1:1;if(l<2)for(;;){if(m in f){u=f[m],m+=h;break}if(m+=h,e?m<0:p<=m)throw new s(c)}for(;e?m>=0:p>m;m+=h)m in f&&(u=n(u,f[m],m,d));return u}};e.exports={left:l(!1),right:l(!0)}},4527:function(e,t,n){var r=n(3724),i=n(4376),a=TypeError,o=Object.getOwnPropertyDescriptor;e.exports=r&&!function(){if(this!==void 0)return!0;try{Object.defineProperty([],"length",{writable:!1}).length=1}catch(e){return e instanceof TypeError}}()?function(e,t){if(i(e)&&!o(e,`length`).writable)throw new a(`Cannot set read only .length`);return e.length=t}:function(e,t){return e.length=t}},7680:function(e,t,n){e.exports=n(9504)([].slice)},4488:function(e,t,n){var r=n(7680),i=Math.floor,a=function(e,t){var n=e.length;if(n<8)for(var o,s,c=1;c<n;){for(s=c,o=e[c];s&&t(e[s-1],o)>0;)e[s]=e[--s];s!==c++&&(e[s]=o)}else for(var l=i(n/2),u=a(r(e,0,l),t),d=a(r(e,l),t),f=u.length,p=d.length,m=0,h=0;m<f||h<p;)e[m+h]=m<f&&h<p?t(u[m],d[h])<=0?u[m++]:d[h++]:m<f?u[m++]:d[h++];return e};e.exports=a},7433:function(e,t,n){var r=n(4376),i=n(3517),a=n(34),o=n(8227)(`species`),s=Array;e.exports=function(e){var t;return r(e)&&(t=e.constructor,(i(t)&&(t===s||r(t.prototype))||a(t)&&(t=t[o])===null)&&(t=void 0)),t===void 0?s:t}},1469:function(e,t,n){var r=n(7433);e.exports=function(e,t){return new(r(e))(t===0?0:t)}},6319:function(e,t,n){var r=n(8551),i=n(9539);e.exports=function(e,t,n,a){try{return a?t(r(n)[0],n[1]):t(n)}catch(t){i(e,`throw`,t)}}},4428:function(e,t,n){var r=n(8227)(`iterator`),i=!1;try{var a=0,o={next:function(){return{done:!!a++}},return:function(){i=!0}};o[r]=function(){return this},Array.from(o,(function(){throw 2}))}catch{}e.exports=function(e,t){try{if(!t&&!i)return!1}catch{return!1}var n=!1;try{var a={};a[r]=function(){return{next:function(){return{done:n=!0}}}},e(a)}catch{}return n}},2195:function(e,t,n){var r=n(9504),i=r({}.toString),a=r(``.slice);e.exports=function(e){return a(i(e),8,-1)}},6955:function(e,t,n){var r=n(2140),i=n(4901),a=n(2195),o=n(8227)(`toStringTag`),s=Object,c=a(function(){return arguments}())===`Arguments`;e.exports=r?a:function(e){var t,n,r;return e===void 0?`Undefined`:e===null?`Null`:typeof(n=function(e,t){try{return e[t]}catch{}}(t=s(e),o))==`string`?n:c?a(t):(r=a(t))===`Object`&&i(t.callee)?`Arguments`:r}},7740:function(e,t,n){var r=n(9297),i=n(5031),a=n(7347),o=n(4913);e.exports=function(e,t,n){for(var s=i(t),c=o.f,l=a.f,u=0;u<s.length;u++){var d=s[u];r(e,d)||n&&r(n,d)||c(e,d,l(t,d))}}},1436:function(e,t,n){var r=n(8227)(`match`);e.exports=function(e){var t=/./;try{`/./`[e](t)}catch{try{return t[r]=!1,`/./`[e](t)}catch{}}return!1}},2211:function(e,t,n){e.exports=!n(9039)((function(){function e(){}return e.prototype.constructor=null,Object.getPrototypeOf(new e)!==e.prototype}))},2529:function(e){e.exports=function(e,t){return{value:e,done:t}}},6699:function(e,t,n){var r=n(3724),i=n(4913),a=n(6980);e.exports=r?function(e,t,n){return i.f(e,t,a(1,n))}:function(e,t,n){return e[t]=n,e}},6980:function(e){e.exports=function(e,t){return{enumerable:!(1&e),configurable:!(2&e),writable:!(4&e),value:t}}},4659:function(e,t,n){var r=n(3724),i=n(4913),a=n(6980);e.exports=function(e,t,n){r?i.f(e,t,a(0,n)):e[t]=n}},3640:function(e,t,n){var r=n(8551),i=n(4270),a=TypeError;e.exports=function(e){if(r(this),e===`string`||e==="default")e=`string`;else if(e!==`number`)throw new a(`Incorrect hint`);return i(this,e)}},2106:function(e,t,n){var r=n(283),i=n(4913);e.exports=function(e,t,n){return n.get&&r(n.get,t,{getter:!0}),n.set&&r(n.set,t,{setter:!0}),i.f(e,t,n)}},6840:function(e,t,n){var r=n(4901),i=n(4913),a=n(283),o=n(9433);e.exports=function(e,t,n,s){s||={};var c=s.enumerable,l=s.name===void 0?t:s.name;if(r(n)&&a(n,l,s),s.global)c?e[t]=n:o(t,n);else{try{s.unsafe?e[t]&&(c=!0):delete e[t]}catch{}c?e[t]=n:i.f(e,t,{value:n,enumerable:!1,configurable:!s.nonConfigurable,writable:!s.nonWritable})}return e}},9433:function(e,t,n){var r=n(4576),i=Object.defineProperty;e.exports=function(e,t){try{i(r,e,{value:t,configurable:!0,writable:!0})}catch{r[e]=t}return t}},4606:function(e,t,n){var r=n(6823),i=TypeError;e.exports=function(e,t){if(!delete e[t])throw new i(`Cannot delete property `+r(t)+` of `+r(e))}},3724:function(e,t,n){e.exports=!n(9039)((function(){return Object.defineProperty({},1,{get:function(){return 7}})[1]!==7}))},4055:function(e,t,n){var r=n(4576),i=n(34),a=r.document,o=i(a)&&i(a.createElement);e.exports=function(e){return o?a.createElement(e):{}}},6837:function(e){var t=TypeError;e.exports=function(e){if(e>9007199254740991)throw t(`Maximum allowed index exceeded`);return e}},7400:function(e){e.exports={CSSRuleList:0,CSSStyleDeclaration:0,CSSValueList:0,ClientRectList:0,DOMRectList:0,DOMStringList:0,DOMTokenList:1,DataTransferItemList:0,FileList:0,HTMLAllCollection:0,HTMLCollection:0,HTMLFormElement:0,HTMLSelectElement:0,MediaList:0,MimeTypeArray:0,NamedNodeMap:0,NodeList:1,PaintRequestList:0,Plugin:0,PluginArray:0,SVGLengthList:0,SVGNumberList:0,SVGPathSegList:0,SVGPointList:0,SVGStringList:0,SVGTransformList:0,SourceBufferList:0,StyleSheetList:0,TextTrackCueList:0,TextTrackList:0,TouchList:0}},9296:function(e,t,n){var r=n(4055)(`span`).classList,i=r&&r.constructor&&r.constructor.prototype;e.exports=i===Object.prototype?void 0:i},8727:function(e){e.exports=[`constructor`,`hasOwnProperty`,`isPrototypeOf`,`propertyIsEnumerable`,`toLocaleString`,`toString`,`valueOf`]},3709:function(e,t,n){var r=n(2839).match(/firefox\/(\d+)/i);e.exports=!!r&&+r[1]},3763:function(e,t,n){var r=n(2839);e.exports=/MSIE|Trident/.test(r)},6193:function(e,t,n){e.exports=n(4215)===`NODE`},2839:function(e,t,n){var r=n(4576).navigator,i=r&&r.userAgent;e.exports=i?String(i):``},9519:function(e,t,n){var r,i,a=n(4576),o=n(2839),s=a.process,c=a.Deno,l=s&&s.versions||c&&c.version,u=l&&l.v8;u&&(i=(r=u.split(`.`))[0]>0&&r[0]<4?1:+(r[0]+r[1])),!i&&o&&(!(r=o.match(/Edge\/(\d+)/))||r[1]>=74)&&(r=o.match(/Chrome\/(\d+)/))&&(i=+r[1]),e.exports=i},3607:function(e,t,n){var r=n(2839).match(/AppleWebKit\/(\d+)\./);e.exports=!!r&&+r[1]},4215:function(e,t,n){var r=n(4576),i=n(2839),a=n(2195),o=function(e){return i.slice(0,e.length)===e};e.exports=o(`Bun/`)?`BUN`:o(`Cloudflare-Workers`)?`CLOUDFLARE`:o(`Deno/`)?`DENO`:o(`Node.js/`)?`NODE`:r.Bun&&typeof Bun.version==`string`?`BUN`:r.Deno&&typeof Deno.version==`object`?`DENO`:a(r.process)===`process`?`NODE`:r.window&&r.document?`BROWSER`:`REST`},6518:function(e,t,n){var r=n(4576),i=n(7347).f,a=n(6699),o=n(6840),s=n(9433),c=n(7740),l=n(2796);e.exports=function(e,t){var n,u,d,f,p,m=e.target,h=e.global,g=e.stat;if(n=h?r:g?r[m]||s(m,{}):r[m]&&r[m].prototype)for(u in t){if(f=t[u],d=e.dontCallGetSet?(p=i(n,u))&&p.value:n[u],!l(h?u:m+(g?`.`:`#`)+u,e.forced)&&d!==void 0){if(typeof f==typeof d)continue;c(f,d)}(e.sham||d&&d.sham)&&a(f,`sham`,!0),o(n,u,f,e)}}},9039:function(e){e.exports=function(e){try{return!!e()}catch{return!0}}},9228:function(e,t,n){n(7495);var r=n(9565),i=n(6840),a=n(7323),o=n(9039),s=n(8227),c=n(6699),l=s(`species`),u=RegExp.prototype;e.exports=function(e,t,n,d){var f=s(e),p=!o((function(){var t={};return t[f]=function(){return 7},``[e](t)!==7})),m=p&&!o((function(){var t=!1,n=/a/;if(e===`split`){var r={};r[l]=function(){return n},(n={constructor:r,flags:``})[f]=/./[f]}return n.exec=function(){return t=!0,null},n[f](``),!t}));if(!p||!m||n){var h=/./[f],g=t(f,``[e],(function(e,t,n,i,o){var s=t.exec;return s===a||s===u.exec?p&&!o?{done:!0,value:r(h,t,n,i)}:{done:!0,value:r(e,n,t,i)}:{done:!1}}));i(String.prototype,e,g[0]),i(u,f,g[1])}d&&c(u[f],`sham`,!0)}},8745:function(e,t,n){var r=n(616),i=Function.prototype,a=i.apply,o=i.call;e.exports=typeof Reflect==`object`&&Reflect.apply||(r?o.bind(a):function(){return o.apply(a,arguments)})},6080:function(e,t,n){var r=n(7476),i=n(9306),a=n(616),o=r(r.bind);e.exports=function(e,t){return i(e),t===void 0?e:a?o(e,t):function(){return e.apply(t,arguments)}}},616:function(e,t,n){e.exports=!n(9039)((function(){var e=function(){}.bind();return typeof e!=`function`||e.hasOwnProperty(`prototype`)}))},566:function(e,t,n){var r=n(9504),i=n(9306),a=n(34),o=n(9297),s=n(7680),c=n(616),l=Function,u=r([].concat),d=r([].join),f={};e.exports=c?l.bind:function(e){var t=i(this),n=t.prototype,r=s(arguments,1),c=function(){var n=u(r,s(arguments));return this instanceof c?function(e,t,n){if(!o(f,t)){for(var r=[],i=0;i<t;i++)r[i]=`a[`+i+`]`;f[t]=l(`C,a`,`return new C(`+d(r,`,`)+`)`)}return f[t](e,n)}(t,n.length,n):t.apply(e,n)};return a(n)&&(c.prototype=n),c}},9565:function(e,t,n){var r=n(616),i=Function.prototype.call;e.exports=r?i.bind(i):function(){return i.apply(i,arguments)}},350:function(e,t,n){var r=n(3724),i=n(9297),a=Function.prototype,o=r&&Object.getOwnPropertyDescriptor,s=i(a,`name`);e.exports={EXISTS:s,PROPER:s&&function(){}.name===`something`,CONFIGURABLE:s&&(!r||r&&o(a,`name`).configurable)}},6706:function(e,t,n){var r=n(9504),i=n(9306);e.exports=function(e,t,n){try{return r(i(Object.getOwnPropertyDescriptor(e,t)[n]))}catch{}}},7476:function(e,t,n){var r=n(2195),i=n(9504);e.exports=function(e){if(r(e)===`Function`)return i(e)}},9504:function(e,t,n){var r=n(616),i=Function.prototype,a=i.call,o=r&&i.bind.bind(a,a);e.exports=r?o:function(e){return function(){return a.apply(e,arguments)}}},7751:function(e,t,n){var r=n(4576),i=n(4901);e.exports=function(e,t){return arguments.length<2?(n=r[e],i(n)?n:void 0):r[e]&&r[e][t];var n}},851:function(e,t,n){var r=n(6955),i=n(5966),a=n(4117),o=n(6269),s=n(8227)(`iterator`);e.exports=function(e){if(!a(e))return i(e,s)||i(e,`@@iterator`)||o[r(e)]}},81:function(e,t,n){var r=n(9565),i=n(9306),a=n(8551),o=n(6823),s=n(851),c=TypeError;e.exports=function(e,t){var n=arguments.length<2?s(e):t;if(i(n))return a(r(n,e));throw new c(o(e)+` is not iterable`)}},5966:function(e,t,n){var r=n(9306),i=n(4117);e.exports=function(e,t){var n=e[t];return i(n)?void 0:r(n)}},2478:function(e,t,n){var r=n(9504),i=n(8981),a=Math.floor,o=r(``.charAt),s=r(``.replace),c=r(``.slice),l=/\$([$&'`]|\d{1,2}|<[^>]*>)/g,u=/\$([$&'`]|\d{1,2})/g;e.exports=function(e,t,n,r,d,f){var p=n+e.length,m=r.length,h=u;return d!==void 0&&(d=i(d),h=l),s(f,h,(function(i,s){var l;switch(o(s,0)){case`$`:return`$`;case`&`:return e;case"`":return c(t,0,n);case`'`:return c(t,p);case`<`:l=d[c(s,1,-1)];break;default:var u=+s;if(u===0)return i;if(u>m){var f=a(u/10);return f===0?i:f<=m?r[f-1]===void 0?o(s,1):r[f-1]+o(s,1):i}l=r[u-1]}return l===void 0?``:l}))}},4576:function(e,t,n){var r=function(e){return e&&e.Math===Math&&e};e.exports=r(typeof globalThis==`object`&&globalThis)||r(typeof window==`object`&&window)||r(typeof self==`object`&&self)||r(typeof n.g==`object`&&n.g)||r(typeof this==`object`&&this)||function(){return this}()||Function(`return this`)()},9297:function(e,t,n){var r=n(9504),i=n(8981),a=r({}.hasOwnProperty);e.exports=Object.hasOwn||function(e,t){return a(i(e),t)}},421:function(e){e.exports={}},397:function(e,t,n){e.exports=n(7751)(`document`,`documentElement`)},5917:function(e,t,n){var r=n(3724),i=n(9039),a=n(4055);e.exports=!r&&!i((function(){return Object.defineProperty(a(`div`),"a",{get:function(){return 7}}).a!==7}))},7055:function(e,t,n){var r=n(9504),i=n(9039),a=n(2195),o=Object,s=r(``.split);e.exports=i((function(){return!o(`z`).propertyIsEnumerable(0)}))?function(e){return a(e)===`String`?s(e,``):o(e)}:o},3167:function(e,t,n){var r=n(4901),i=n(34),a=n(2967);e.exports=function(e,t,n){var o,s;return a&&r(o=t.constructor)&&o!==n&&i(s=o.prototype)&&s!==n.prototype&&a(e,s),e}},3706:function(e,t,n){var r=n(9504),i=n(4901),a=n(7629),o=r(Function.toString);i(a.inspectSource)||(a.inspectSource=function(e){return o(e)}),e.exports=a.inspectSource},1181:function(e,t,n){var r,i,a,o=n(8622),s=n(4576),c=n(34),l=n(6699),u=n(9297),d=n(7629),f=n(6119),p=n(421),m=`Object already initialized`,h=s.TypeError,g=s.WeakMap;if(o||d.state){var _=d.state||=new g;_.get=_.get,_.has=_.has,_.set=_.set,r=function(e,t){if(_.has(e))throw new h(m);return t.facade=e,_.set(e,t),t},i=function(e){return _.get(e)||{}},a=function(e){return _.has(e)}}else{var v=f(`state`);p[v]=!0,r=function(e,t){if(u(e,v))throw new h(m);return t.facade=e,l(e,v,t),t},i=function(e){return u(e,v)?e[v]:{}},a=function(e){return u(e,v)}}e.exports={set:r,get:i,has:a,enforce:function(e){return a(e)?i(e):r(e,{})},getterFor:function(e){return function(t){var n;if(!c(t)||(n=i(t)).type!==e)throw new h(`Incompatible receiver, `+e+` required`);return n}}}},4209:function(e,t,n){var r=n(8227),i=n(6269),a=r(`iterator`),o=Array.prototype;e.exports=function(e){return e!==void 0&&(i.Array===e||o[a]===e)}},4376:function(e,t,n){var r=n(2195);e.exports=Array.isArray||function(e){return r(e)===`Array`}},4901:function(e){var t=typeof document==`object`&&document.all;e.exports=t===void 0&&t!==void 0?function(e){return typeof e==`function`||e===t}:function(e){return typeof e==`function`}},3517:function(e,t,n){var r=n(9504),i=n(9039),a=n(4901),o=n(6955),s=n(7751),c=n(3706),l=function(){},u=s(`Reflect`,`construct`),d=/^\s*(?:class|function)\b/,f=r(d.exec),p=!d.test(l),m=function(e){if(!a(e))return!1;try{return u(l,[],e),!0}catch{return!1}},h=function(e){if(!a(e))return!1;switch(o(e)){case`AsyncFunction`:case`GeneratorFunction`:case`AsyncGeneratorFunction`:return!1}try{return p||!!f(d,c(e))}catch{return!0}};h.sham=!0,e.exports=!u||i((function(){var e;return m(m.call)||!m(Object)||!m((function(){e=!0}))||e}))?h:m},2796:function(e,t,n){var r=n(9039),i=n(4901),a=/#|\.prototype\./,o=function(e,t){var n=c[s(e)];return n===u||n!==l&&(i(t)?r(t):!!t)},s=o.normalize=function(e){return String(e).replace(a,`.`).toLowerCase()},c=o.data={},l=o.NATIVE=`N`,u=o.POLYFILL=`P`;e.exports=o},2087:function(e,t,n){var r=n(34),i=Math.floor;e.exports=Number.isInteger||function(e){return!r(e)&&isFinite(e)&&i(e)===e}},4117:function(e){e.exports=function(e){return e==null}},34:function(e,t,n){var r=n(4901);e.exports=function(e){return typeof e==`object`?e!==null:r(e)}},3925:function(e,t,n){var r=n(34);e.exports=function(e){return r(e)||e===null}},6395:function(e){e.exports=!1},5810:function(e,t,n){var r=n(34),i=n(1181).get;e.exports=function(e){if(!r(e))return!1;var t=i(e);return!!t&&t.type===`RawJSON`}},788:function(e,t,n){var r=n(34),i=n(2195),a=n(8227)(`match`);e.exports=function(e){var t;return r(e)&&((t=e[a])===void 0?i(e)===`RegExp`:!!t)}},757:function(e,t,n){var r=n(7751),i=n(4901),a=n(1625),o=n(7040),s=Object;e.exports=o?function(e){return typeof e==`symbol`}:function(e){var t=r(`Symbol`);return i(t)&&a(t.prototype,s(e))}},9539:function(e,t,n){var r=n(9565),i=n(8551),a=n(5966);e.exports=function(e,t,n){var o,s;i(e);try{if(!(o=a(e,`return`))){if(t===`throw`)throw n;return n}o=r(o,e)}catch(e){s=!0,o=e}if(t===`throw`)throw n;if(s)throw o;return i(o),n}},3994:function(e,t,n){var r=n(7657).IteratorPrototype,i=n(2360),a=n(6980),o=n(687),s=n(6269),c=function(){return this};e.exports=function(e,t,n,l){var u=t+` Iterator`;return e.prototype=i(r,{next:a(+!l,n)}),o(e,u,!1,!0),s[u]=c,e}},1088:function(e,t,n){var r=n(6518),i=n(9565),a=n(6395),o=n(350),s=n(4901),c=n(3994),l=n(2787),u=n(2967),d=n(687),f=n(6699),p=n(6840),m=n(8227),h=n(6269),g=n(7657),_=o.PROPER,v=o.CONFIGURABLE,y=g.IteratorPrototype,b=g.BUGGY_SAFARI_ITERATORS,x=m(`iterator`),S=`keys`,C=`values`,w=`entries`,T=function(){return this};e.exports=function(e,t,n,o,m,g,E){c(n,t,o);var D,O,k,A=function(e){if(e===m&&F)return F;if(!b&&e&&e in N)return N[e];switch(e){case S:case C:case w:return function(){return new n(this,e)}}return function(){return new n(this)}},j=t+` Iterator`,M=!1,N=e.prototype,P=N[x]||N[`@@iterator`]||m&&N[m],F=!b&&P||A(m),I=t===`Array`&&N.entries||P;if(I&&(D=l(I.call(new e)))!==Object.prototype&&D.next&&(a||l(D)===y||(u?u(D,y):s(D[x])||p(D,x,T)),d(D,j,!0,!0),a&&(h[j]=T)),_&&m===C&&P&&P.name!==C&&(!a&&v?f(N,`name`,C):(M=!0,F=function(){return i(P,this)})),m)if(O={values:A(C),keys:g?F:A(S),entries:A(w)},E)for(k in O)(b||M||!(k in N))&&p(N,k,O[k]);else r({target:t,proto:!0,forced:b||M},O);return a&&!E||N[x]===F||p(N,x,F,{name:m}),h[t]=F,O}},7657:function(e,t,n){var r,i,a,o=n(9039),s=n(4901),c=n(34),l=n(2360),u=n(2787),d=n(6840),f=n(8227),p=n(6395),m=f(`iterator`),h=!1;[].keys&&(`next`in(a=[].keys())?(i=u(u(a)))!==Object.prototype&&(r=i):h=!0),!c(r)||o((function(){var e={};return r[m].call(e)!==e}))?r={}:p&&(r=l(r)),s(r[m])||d(r,m,(function(){return this})),e.exports={IteratorPrototype:r,BUGGY_SAFARI_ITERATORS:h}},6269:function(e){e.exports={}},6198:function(e,t,n){var r=n(8014);e.exports=function(e){return r(e.length)}},283:function(e,t,n){var r=n(9504),i=n(9039),a=n(4901),o=n(9297),s=n(3724),c=n(350).CONFIGURABLE,l=n(3706),u=n(1181),d=u.enforce,f=u.get,p=String,m=Object.defineProperty,h=r(``.slice),g=r(``.replace),_=r([].join),v=s&&!i((function(){return m((function(){}),`length`,{value:8}).length!==8})),y=String(String).split(`String`),b=e.exports=function(e,t,n){h(p(t),0,7)===`Symbol(`&&(t=`[`+g(p(t),/^Symbol\(([^)]*)\).*$/,`$1`)+`]`),n&&n.getter&&(t=`get `+t),n&&n.setter&&(t=`set `+t),(!o(e,`name`)||c&&e.name!==t)&&(s?m(e,`name`,{value:t,configurable:!0}):e.name=t),v&&n&&o(n,`arity`)&&e.length!==n.arity&&m(e,`length`,{value:n.arity});try{n&&o(n,`constructor`)&&n.constructor?s&&m(e,`prototype`,{writable:!1}):e.prototype&&=void 0}catch{}var r=d(e);return o(r,`source`)||(r.source=_(y,typeof t==`string`?t:``)),e};Function.prototype.toString=b((function(){return a(this)&&f(this).source||l(this)}),`toString`)},741:function(e){var t=Math.ceil,n=Math.floor;e.exports=Math.trunc||function(e){var r=+e;return(r>0?n:t)(r)}},7819:function(e,t,n){e.exports=!n(9039)((function(){var e=`9007199254740993`,t=JSON.rawJSON(e);return!JSON.isRawJSON(t)||JSON.stringify(t)!==e}))},5749:function(e,t,n){var r=n(788),i=TypeError;e.exports=function(e){if(r(e))throw new i(`The method doesn't accept regular expressions`);return e}},4213:function(e,t,n){var r=n(3724),i=n(9504),a=n(9565),o=n(9039),s=n(1072),c=n(3717),l=n(8773),u=n(8981),d=n(7055),f=Object.assign,p=Object.defineProperty,m=i([].concat);e.exports=!f||o((function(){if(r&&f({b:1},f(p({},`a`,{enumerable:!0,get:function(){p(this,`b`,{value:3,enumerable:!1})}}),{b:2})).b!==1)return!0;var e={},t={},n=Symbol(`assign detection`),i=`abcdefghijklmnopqrst`;return e[n]=7,i.split(``).forEach((function(e){t[e]=e})),f({},e)[n]!==7||s(f({},t)).join(``)!==i}))?function(e,t){for(var n=u(e),i=arguments.length,o=1,f=c.f,p=l.f;i>o;)for(var h,g=d(arguments[o++]),_=f?m(s(g),f(g)):s(g),v=_.length,y=0;v>y;)h=_[y++],r&&!a(p,g,h)||(n[h]=g[h]);return n}:f},2360:function(e,t,n){var r,i=n(8551),a=n(6801),o=n(8727),s=n(421),c=n(397),l=n(4055),u=n(6119),d=`prototype`,f=`script`,p=u(`IE_PROTO`),m=function(){},h=function(e){return`<`+f+`>`+e+`</`+f+`>`},g=function(e){e.write(h(``)),e.close();var t=e.parentWindow.Object;return e=null,t},_=function(){try{r=new ActiveXObject(`htmlfile`)}catch{}var e,t,n;_=typeof document<`u`?document.domain&&r?g(r):(t=l(`iframe`),n=`java`+f+`:`,t.style.display=`none`,c.appendChild(t),t.src=String(n),(e=t.contentWindow.document).open(),e.write(h(`document.F=Object`)),e.close(),e.F):g(r);for(var i=o.length;i--;)delete _[d][o[i]];return _()};s[p]=!0,e.exports=Object.create||function(e,t){var n;return e===null?n=_():(m[d]=i(e),n=new m,m[d]=null,n[p]=e),t===void 0?n:a.f(n,t)}},6801:function(e,t,n){var r=n(3724),i=n(8686),a=n(4913),o=n(8551),s=n(5397),c=n(1072);t.f=r&&!i?Object.defineProperties:function(e,t){o(e);for(var n,r=s(t),i=c(t),l=i.length,u=0;l>u;)a.f(e,n=i[u++],r[n]);return e}},4913:function(e,t,n){var r=n(3724),i=n(5917),a=n(8686),o=n(8551),s=n(6969),c=TypeError,l=Object.defineProperty,u=Object.getOwnPropertyDescriptor,d=`enumerable`,f=`configurable`,p=`writable`;t.f=r?a?function(e,t,n){if(o(e),t=s(t),o(n),typeof e==`function`&&t===`prototype`&&`value`in n&&p in n&&!n[p]){var r=u(e,t);r&&r[p]&&(e[t]=n.value,n={configurable:f in n?n[f]:r[f],enumerable:d in n?n[d]:r[d],writable:!1})}return l(e,t,n)}:l:function(e,t,n){if(o(e),t=s(t),o(n),i)try{return l(e,t,n)}catch{}if(`get`in n||`set`in n)throw new c(`Accessors not supported`);return`value`in n&&(e[t]=n.value),e}},7347:function(e,t,n){var r=n(3724),i=n(9565),a=n(8773),o=n(6980),s=n(5397),c=n(6969),l=n(9297),u=n(5917),d=Object.getOwnPropertyDescriptor;t.f=r?d:function(e,t){if(e=s(e),t=c(t),u)try{return d(e,t)}catch{}if(l(e,t))return o(!i(a.f,e,t),e[t])}},298:function(e,t,n){var r=n(2195),i=n(5397),a=n(8480).f,o=n(7680),s=typeof window==`object`&&window&&Object.getOwnPropertyNames?Object.getOwnPropertyNames(window):[];e.exports.f=function(e){return s&&r(e)===`Window`?function(e){try{return a(e)}catch{return o(s)}}(e):a(i(e))}},8480:function(e,t,n){var r=n(1828),i=n(8727).concat(`length`,`prototype`);t.f=Object.getOwnPropertyNames||function(e){return r(e,i)}},3717:function(e,t){t.f=Object.getOwnPropertySymbols},2787:function(e,t,n){var r=n(9297),i=n(4901),a=n(8981),o=n(6119),s=n(2211),c=o(`IE_PROTO`),l=Object,u=l.prototype;e.exports=s?l.getPrototypeOf:function(e){var t=a(e);if(r(t,c))return t[c];var n=t.constructor;return i(n)&&t instanceof n?n.prototype:t instanceof l?u:null}},1625:function(e,t,n){e.exports=n(9504)({}.isPrototypeOf)},1828:function(e,t,n){var r=n(9504),i=n(9297),a=n(5397),o=n(9617).indexOf,s=n(421),c=r([].push);e.exports=function(e,t){var n,r=a(e),l=0,u=[];for(n in r)!i(s,n)&&i(r,n)&&c(u,n);for(;t.length>l;)i(r,n=t[l++])&&(~o(u,n)||c(u,n));return u}},1072:function(e,t,n){var r=n(1828),i=n(8727);e.exports=Object.keys||function(e){return r(e,i)}},8773:function(e,t){var n={}.propertyIsEnumerable,r=Object.getOwnPropertyDescriptor;t.f=r&&!n.call({1:2},1)?function(e){var t=r(this,e);return!!t&&t.enumerable}:n},2551:function(e,t,n){var r=n(6395),i=n(4576),a=n(9039),o=n(3607);e.exports=r||!a((function(){if(!(o&&o<535)){var e=Math.random();__defineSetter__.call(null,e,(function(){})),delete i[e]}}))},2967:function(e,t,n){var r=n(6706),i=n(34),a=n(7750),o=n(3506);e.exports=Object.setPrototypeOf||(`__proto__`in{}?function(){var e,t=!1,n={};try{(e=r(Object.prototype,`__proto__`,`set`))(n,[]),t=n instanceof Array}catch{}return function(n,r){return a(n),o(r),i(n)&&(t?e(n,r):n.__proto__=r),n}}():void 0)},3179:function(e,t,n){var r=n(2140),i=n(6955);e.exports=r?{}.toString:function(){return`[object `+i(this)+`]`}},4270:function(e,t,n){var r=n(9565),i=n(4901),a=n(34),o=TypeError;e.exports=function(e,t){var n,s;if(t===`string`&&i(n=e.toString)&&!a(s=r(n,e))||i(n=e.valueOf)&&!a(s=r(n,e))||t!==`string`&&i(n=e.toString)&&!a(s=r(n,e)))return s;throw new o(`Can't convert object to primitive value`)}},5031:function(e,t,n){var r=n(7751),i=n(9504),a=n(8480),o=n(3717),s=n(8551),c=i([].concat);e.exports=r(`Reflect`,`ownKeys`)||function(e){var t=a.f(s(e)),n=o.f;return n?c(t,n(e)):t}},8235:function(e,t,n){var r=n(9504),i=n(9297),a=SyntaxError,o=parseInt,s=String.fromCharCode,c=r(``.charAt),l=r(``.slice),u=r(/./.exec),d={'\\"':`"`,"\\\\":`\\`,"\\/":`/`,"\\b":`\b`,"\\f":`\f`,"\\n":`
- `,"\\r":`\r`,"\\t":` `},f=/^[\da-f]{4}$/i,p=/^[\u0000-\u001F]$/;e.exports=function(e,t){for(var n=!0,r=``;t<e.length;){var m=c(e,t);if(m===`\\`){var h=l(e,t,t+2);if(i(d,h))r+=d[h],t+=2;else{if(h!==`\\u`)throw new a(`Unknown escape sequence: "`+h+`"`);var g=l(e,t+=2,t+4);if(!u(f,g))throw new a(`Bad Unicode escape at: `+t);r+=s(o(g,16)),t+=4}}else{if(m===`"`){n=!1,t++;break}if(u(p,m))throw new a(`Bad control character in string literal at: `+t);r+=m,t++}}if(n)throw new a(`Unterminated string at: `+t);return{value:r,end:t}}},9167:function(e,t,n){e.exports=n(4576)},1056:function(e,t,n){var r=n(4913).f;e.exports=function(e,t,n){n in e||r(e,n,{configurable:!0,get:function(){return t[n]},set:function(e){t[n]=e}})}},6682:function(e,t,n){var r=n(9565),i=n(8551),a=n(4901),o=n(2195),s=n(7323),c=TypeError;e.exports=function(e,t){var n=e.exec;if(a(n)){var l=r(n,e,t);return l!==null&&i(l),l}if(o(e)===`RegExp`)return r(s,e,t);throw new c(`RegExp#exec called on incompatible receiver`)}},7323:function(e,t,n){var r,i,a=n(9565),o=n(9504),s=n(655),c=n(7979),l=n(8429),u=n(5745),d=n(2360),f=n(1181).get,p=n(3635),m=n(8814),h=u(`native-string-replace`,String.prototype.replace),g=RegExp.prototype.exec,_=g,v=o(``.charAt),y=o(``.indexOf),b=o(``.replace),x=o(``.slice),S=(i=/b*/g,a(g,r=/a/,`a`),a(g,i,`a`),r.lastIndex!==0||i.lastIndex!==0),C=l.BROKEN_CARET,w=/()??/.exec(``)[1]!==void 0;(S||w||C||p||m)&&(_=function(e){var t,n,r,i,o,l,u,p=this,m=f(p),T=s(e),E=m.raw;if(E)return E.lastIndex=p.lastIndex,t=a(_,E,T),p.lastIndex=E.lastIndex,t;var D=m.groups,O=C&&p.sticky,k=a(c,p),A=p.source,j=0,M=T;if(O&&(k=b(k,`y`,``),y(k,`g`)===-1&&(k+=`g`),M=x(T,p.lastIndex),p.lastIndex>0&&(!p.multiline||p.multiline&&v(T,p.lastIndex-1)!==`
- `)&&(A=`(?: `+A+`)`,M=` `+M,j++),n=RegExp(`^(?:`+A+`)`,k)),w&&(n=RegExp(`^`+A+`$(?!\\s)`,k)),S&&(r=p.lastIndex),i=a(g,O?n:p,M),O?i?(i.input=x(i.input,j),i[0]=x(i[0],j),i.index=p.lastIndex,p.lastIndex+=i[0].length):p.lastIndex=0:S&&i&&(p.lastIndex=p.global?i.index+i[0].length:r),w&&i&&i.length>1&&a(h,i[0],n,(function(){for(o=1;o<arguments.length-2;o++)arguments[o]===void 0&&(i[o]=void 0)})),i&&D)for(i.groups=l=d(null),o=0;o<D.length;o++)l[(u=D[o])[0]]=i[u[1]];return i}),e.exports=_},5213:function(e,t,n){var r=n(4576),i=n(9039),a=r.RegExp;e.exports={correct:!i((function(){var e=!0;try{a(`.`,`d`)}catch{e=!1}var t={},n=``,r=e?`dgimsy`:`gimsy`,i=function(e,r){Object.defineProperty(t,e,{get:function(){return n+=r,!0}})},o={dotAll:`s`,global:`g`,ignoreCase:`i`,multiline:`m`,sticky:`y`};for(var s in e&&(o.hasIndices=`d`),o)i(s,o[s]);return Object.getOwnPropertyDescriptor(a.prototype,`flags`).get.call(t)!==r||n!==r}))}},7979:function(e,t,n){var r=n(8551);e.exports=function(){var e=r(this),t=``;return e.hasIndices&&(t+=`d`),e.global&&(t+=`g`),e.ignoreCase&&(t+=`i`),e.multiline&&(t+=`m`),e.dotAll&&(t+=`s`),e.unicode&&(t+=`u`),e.unicodeSets&&(t+=`v`),e.sticky&&(t+=`y`),t}},1034:function(e,t,n){var r=n(9565),i=n(9297),a=n(1625),o=n(5213),s=n(7979),c=RegExp.prototype;e.exports=o.correct?function(e){return e.flags}:function(e){return o.correct||!a(c,e)||i(e,`flags`)?e.flags:r(s,e)}},8429:function(e,t,n){var r=n(9039),i=n(4576).RegExp,a=r((function(){var e=i(`a`,`y`);return e.lastIndex=2,e.exec(`abcd`)!==null})),o=a||r((function(){return!i(`a`,`y`).sticky}));e.exports={BROKEN_CARET:a||r((function(){var e=i(`^r`,`gy`);return e.lastIndex=2,e.exec(`str`)!==null})),MISSED_STICKY:o,UNSUPPORTED_Y:a}},3635:function(e,t,n){var r=n(9039),i=n(4576).RegExp;e.exports=r((function(){var e=i(`.`,`s`);return!(e.dotAll&&e.test(`
- `)&&e.flags===`s`)}))},8814:function(e,t,n){var r=n(9039),i=n(4576).RegExp;e.exports=r((function(){var e=i(`(?<a>b)`,`g`);return e.exec(`b`).groups.a!==`b`||`b`.replace(e,`$<a>c`)!==`bc`}))},7750:function(e,t,n){var r=n(4117),i=TypeError;e.exports=function(e){if(r(e))throw new i(`Can't call method on `+e);return e}},7633:function(e,t,n){var r=n(7751),i=n(2106),a=n(8227),o=n(3724),s=a(`species`);e.exports=function(e){var t=r(e);o&&t&&!t[s]&&i(t,s,{configurable:!0,get:function(){return this}})}},687:function(e,t,n){var r=n(4913).f,i=n(9297),a=n(8227)(`toStringTag`);e.exports=function(e,t,n){e&&!n&&(e=e.prototype),e&&!i(e,a)&&r(e,a,{configurable:!0,value:t})}},6119:function(e,t,n){var r=n(5745),i=n(3392),a=r(`keys`);e.exports=function(e){return a[e]||(a[e]=i(e))}},7629:function(e,t,n){var r=n(6395),i=n(4576),a=n(9433),o=`__core-js_shared__`,s=e.exports=i[o]||a(o,{});(s.versions||=[]).push({version:`3.48.0`,mode:r?`pure`:`global`,copyright:`© 2013–2025 Denis Pushkarev (zloirock.ru), 2025–2026 CoreJS Company (core-js.io). All rights reserved.`,license:`https://github.com/zloirock/core-js/blob/v3.48.0/LICENSE`,source:`https://github.com/zloirock/core-js`})},5745:function(e,t,n){var r=n(7629);e.exports=function(e,t){return r[e]||(r[e]=t||{})}},2293:function(e,t,n){var r=n(8551),i=n(5548),a=n(4117),o=n(8227)(`species`);e.exports=function(e,t){var n,s=r(e).constructor;return s===void 0||a(n=r(s)[o])?t:i(n)}},8183:function(e,t,n){var r=n(9504),i=n(1291),a=n(655),o=n(7750),s=r(``.charAt),c=r(``.charCodeAt),l=r(``.slice),u=function(e){return function(t,n){var r,u,d=a(o(t)),f=i(n),p=d.length;return f<0||f>=p?e?``:void 0:(r=c(d,f))<55296||r>56319||f+1===p||(u=c(d,f+1))<56320||u>57343?e?s(d,f):r:e?l(d,f,f+2):u-56320+(r-55296<<10)+65536}};e.exports={codeAt:u(!1),charAt:u(!0)}},706:function(e,t,n){var r=n(350).PROPER,i=n(9039),a=n(7452);e.exports=function(e){return i((function(){return!!a[e]()||`
`[e]()!==`
`||r&&a[e].name!==e}))}},3802:function(e,t,n){var r=n(9504),i=n(7750),a=n(655),o=n(7452),s=r(``.replace),c=RegExp(`^[`+o+`]+`),l=RegExp(`(^|[^`+o+`])[`+o+`]+$`),u=function(e){return function(t){var n=a(i(t));return 1&e&&(n=s(n,c,``)),2&e&&(n=s(n,l,`$1`)),n}};e.exports={start:u(1),end:u(2),trim:u(3)}},4495:function(e,t,n){var r=n(9519),i=n(9039),a=n(4576).String;e.exports=!!Object.getOwnPropertySymbols&&!i((function(){var e=Symbol(`symbol detection`);return!a(e)||!(Object(e)instanceof Symbol)||!Symbol.sham&&r&&r<41}))},8242:function(e,t,n){var r=n(9565),i=n(7751),a=n(8227),o=n(6840);e.exports=function(){var e=i(`Symbol`),t=e&&e.prototype,n=t&&t.valueOf,s=a(`toPrimitive`);t&&!t[s]&&o(t,s,(function(e){return r(n,this)}),{arity:1})}},1296:function(e,t,n){e.exports=n(4495)&&!!Symbol.for&&!!Symbol.keyFor},1240:function(e,t,n){e.exports=n(9504)(1.1.valueOf)},5610:function(e,t,n){var r=n(1291),i=Math.max,a=Math.min;e.exports=function(e,t){var n=r(e);return n<0?i(n+t,0):a(n,t)}},5397:function(e,t,n){var r=n(7055),i=n(7750);e.exports=function(e){return r(i(e))}},1291:function(e,t,n){var r=n(741);e.exports=function(e){var t=+e;return t!=t||t===0?0:r(t)}},8014:function(e,t,n){var r=n(1291),i=Math.min;e.exports=function(e){var t=r(e);return t>0?i(t,9007199254740991):0}},8981:function(e,t,n){var r=n(7750),i=Object;e.exports=function(e){return i(r(e))}},2777:function(e,t,n){var r=n(9565),i=n(34),a=n(757),o=n(5966),s=n(4270),c=n(8227),l=TypeError,u=c(`toPrimitive`);e.exports=function(e,t){if(!i(e)||a(e))return e;var n,c=o(e,u);if(c){if(t===void 0&&(t=`default`),n=r(c,e,t),!i(n)||a(n))return n;throw new l(`Can't convert object to primitive value`)}return t===void 0&&(t=`number`),s(e,t)}},6969:function(e,t,n){var r=n(2777),i=n(757);e.exports=function(e){var t=r(e,`string`);return i(t)?t:t+``}},2140:function(e,t,n){var r={};r[n(8227)(`toStringTag`)]=`z`,e.exports=String(r)===`[object z]`},655:function(e,t,n){var r=n(6955),i=String;e.exports=function(e){if(r(e)===`Symbol`)throw TypeError(`Cannot convert a Symbol value to a string`);return i(e)}},6823:function(e){var t=String;e.exports=function(e){try{return t(e)}catch{return`Object`}}},3392:function(e,t,n){var r=n(9504),i=0,a=Math.random(),o=r(1.1.toString);e.exports=function(e){return`Symbol(`+(e===void 0?``:e)+`)_`+o(++i+a,36)}},7040:function(e,t,n){e.exports=n(4495)&&!Symbol.sham&&typeof Symbol.iterator==`symbol`},8686:function(e,t,n){var r=n(3724),i=n(9039);e.exports=r&&i((function(){return Object.defineProperty((function(){}),"prototype",{value:42,writable:!1}).prototype!==42}))},8622:function(e,t,n){var r=n(4576),i=n(4901),a=r.WeakMap;e.exports=i(a)&&/native code/.test(String(a))},511:function(e,t,n){var r=n(9167),i=n(9297),a=n(1951),o=n(4913).f;e.exports=function(e){var t=r.Symbol||={};i(t,e)||o(t,e,{value:a.f(e)})}},1951:function(e,t,n){t.f=n(8227)},8227:function(e,t,n){var r=n(4576),i=n(5745),a=n(9297),o=n(3392),s=n(4495),c=n(7040),l=r.Symbol,u=i(`wks`),d=c?l.for||l:l&&l.withoutSetter||o;e.exports=function(e){return a(u,e)||(u[e]=s&&a(l,e)?l[e]:d(`Symbol.`+e)),u[e]}},7452:function(e){e.exports=`
- \v\f\r \xA0 \u2028\u2029`},8706:function(e,t,n){var r=n(6518),i=n(9039),a=n(4376),o=n(34),s=n(8981),c=n(6198),l=n(6837),u=n(4659),d=n(4527),f=n(1469),p=n(597),m=n(8227),h=n(9519),g=m(`isConcatSpreadable`),_=h>=51||!i((function(){var e=[];return e[g]=!1,e.concat()[0]!==e})),v=function(e){if(!o(e))return!1;var t=e[g];return t===void 0?a(e):!!t};r({target:`Array`,proto:!0,arity:1,forced:!_||!p(`concat`)},{concat:function(e){var t,n,r,i,a,o=s(this),p=f(o,0),m=0;for(t=-1,r=arguments.length;t<r;t++)if(v(a=t===-1?o:arguments[t]))for(i=c(a),l(m+i),n=0;n<i;n++,m++)n in a&&u(p,m,a[n]);else l(m+1),u(p,m++,a);return d(p,m),p}})},2008:function(e,t,n){var r=n(6518),i=n(9213).filter;r({target:`Array`,proto:!0,forced:!n(597)(`filter`)},{filter:function(e){return i(this,e,arguments.length>1?arguments[1]:void 0)}})},3418:function(e,t,n){var r=n(6518),i=n(7916);r({target:`Array`,stat:!0,forced:!n(4428)((function(e){Array.from(e)}))},{from:i})},4423:function(e,t,n){var r=n(6518),i=n(9617).includes,a=n(9039),o=n(6469);r({target:`Array`,proto:!0,forced:a((function(){return![,].includes()}))},{includes:function(e){return i(this,e,arguments.length>1?arguments[1]:void 0)}}),o(`includes`)},5276:function(e,t,n){var r=n(6518),i=n(7476),a=n(9617).indexOf,o=n(4598),s=i([].indexOf),c=!!s&&1/s([1],1,-0)<0;r({target:`Array`,proto:!0,forced:c||!o(`indexOf`)},{indexOf:function(e){var t=arguments.length>1?arguments[1]:void 0;return c?s(this,e,t)||0:a(this,e,t)}})},3792:function(e,t,n){var r=n(5397),i=n(6469),a=n(6269),o=n(1181),s=n(4913).f,c=n(1088),l=n(2529),u=n(6395),d=n(3724),f=`Array Iterator`,p=o.set,m=o.getterFor(f);e.exports=c(Array,`Array`,(function(e,t){p(this,{type:f,target:r(e),index:0,kind:t})}),(function(){var e=m(this),t=e.target,n=e.index++;if(!t||n>=t.length)return e.target=null,l(void 0,!0);switch(e.kind){case`keys`:return l(n,!1);case`values`:return l(t[n],!1)}return l([n,t[n]],!1)}),`values`);var h=a.Arguments=a.Array;if(i(`keys`),i(`values`),i(`entries`),!u&&d&&h.name!==`values`)try{s(h,`name`,{value:`values`})}catch{}},8598:function(e,t,n){var r=n(6518),i=n(9504),a=n(7055),o=n(5397),s=n(4598),c=i([].join);r({target:`Array`,proto:!0,forced:a!==Object||!s(`join`,`,`)},{join:function(e){return c(o(this),e===void 0?`,`:e)}})},2062:function(e,t,n){var r=n(6518),i=n(9213).map;r({target:`Array`,proto:!0,forced:!n(597)(`map`)},{map:function(e){return i(this,e,arguments.length>1?arguments[1]:void 0)}})},2712:function(e,t,n){var r=n(6518),i=n(926).left,a=n(4598),o=n(9519);r({target:`Array`,proto:!0,forced:!n(6193)&&o>79&&o<83||!a(`reduce`)},{reduce:function(e){var t=arguments.length;return i(this,e,t,t>1?arguments[1]:void 0)}})},4782:function(e,t,n){var r=n(6518),i=n(4376),a=n(3517),o=n(34),s=n(5610),c=n(6198),l=n(5397),u=n(4659),d=n(4527),f=n(8227),p=n(597),m=n(7680),h=p(`slice`),g=f(`species`),_=Array,v=Math.max;r({target:`Array`,proto:!0,forced:!h},{slice:function(e,t){var n,r,f,p=l(this),h=c(p),y=s(e,h),b=s(t===void 0?h:t,h);if(i(p)&&(n=p.constructor,(a(n)&&(n===_||i(n.prototype))||o(n)&&(n=n[g])===null)&&(n=void 0),n===_||n===void 0))return m(p,y,b);for(r=new(n===void 0?_:n)(v(b-y,0)),f=0;y<b;y++,f++)y in p&&u(r,f,p[y]);return d(r,f),r}})},6910:function(e,t,n){var r=n(6518),i=n(9504),a=n(9306),o=n(8981),s=n(6198),c=n(4606),l=n(655),u=n(9039),d=n(4488),f=n(4598),p=n(3709),m=n(3763),h=n(9519),g=n(3607),_=[],v=i(_.sort),y=i(_.push),b=u((function(){_.sort(void 0)})),x=u((function(){_.sort(null)})),S=f(`sort`),C=!u((function(){if(h)return h<70;if(!(p&&p>3)){if(m)return!0;if(g)return g<603;var e,t,n,r,i=``;for(e=65;e<76;e++){switch(t=String.fromCharCode(e),e){case 66:case 69:case 70:case 72:n=3;break;case 68:case 71:n=4;break;default:n=2}for(r=0;r<47;r++)_.push({k:t+r,v:n})}for(_.sort((function(e,t){return t.v-e.v})),r=0;r<_.length;r++)t=_[r].k.charAt(0),i.charAt(i.length-1)!==t&&(i+=t);return i!==`DGBEFHACIJK`}}));r({target:`Array`,proto:!0,forced:b||!x||!S||!C},{sort:function(e){e!==void 0&&a(e);var t=o(this);if(C)return e===void 0?v(t):v(t,e);var n,r,i=[],u=s(t);for(r=0;r<u;r++)r in t&&y(i,t[r]);for(d(i,function(e){return function(t,n){return n===void 0?-1:t===void 0?1:e===void 0?l(t)>l(n)?1:-1:+e(t,n)||0}}(e)),n=s(i),r=0;r<n;)t[r]=i[r++];for(;r<u;)c(t,r++);return t}})},4554:function(e,t,n){var r=n(6518),i=n(8981),a=n(5610),o=n(1291),s=n(6198),c=n(4527),l=n(6837),u=n(1469),d=n(4659),f=n(4606),p=n(597)(`splice`),m=Math.max,h=Math.min;r({target:`Array`,proto:!0,forced:!p},{splice:function(e,t){var n,r,p,g,_,v,y=i(this),b=s(y),x=a(e,b),S=arguments.length;for(S===0?n=r=0:S===1?(n=0,r=b-x):(n=S-2,r=h(m(o(t),0),b-x)),l(b+n-r),p=u(y,r),g=0;g<r;g++)(_=x+g)in y&&d(p,g,y[_]);if(c(p,r),n<r){for(g=x;g<b-r;g++)v=g+n,(_=g+r)in y?y[v]=y[_]:f(y,v);for(g=b;g>b-r+n;g--)f(y,g-1)}else if(n>r)for(g=b-r;g>x;g--)v=g+n-1,(_=g+r-1)in y?y[v]=y[_]:f(y,v);for(g=0;g<n;g++)y[g+x]=arguments[g+2];return c(y,b-r+n),p}})},739:function(e,t,n){var r=n(6518),i=n(9039),a=n(8981),o=n(2777);r({target:`Date`,proto:!0,arity:1,forced:i((function(){return new Date(NaN).toJSON()!==null||Date.prototype.toJSON.call({toISOString:function(){return 1}})!==1}))},{toJSON:function(e){var t=a(this),n=o(t,`number`);return typeof n!=`number`||isFinite(n)?t.toISOString():null}})},9572:function(e,t,n){var r=n(9297),i=n(6840),a=n(3640),o=n(8227)(`toPrimitive`),s=Date.prototype;r(s,o)||i(s,o,a)},2010:function(e,t,n){var r=n(3724),i=n(350).EXISTS,a=n(9504),o=n(2106),s=Function.prototype,c=a(s.toString),l=/function\b(?:\s|\/\*[\S\s]*?\*\/|\/\/[^\n\r]*[\n\r]+)*([^\s(/]*)/,u=a(l.exec);r&&!i&&o(s,`name`,{configurable:!0,get:function(){try{return u(l,c(this))[1]}catch{return``}}})},3110:function(e,t,n){var r=n(6518),i=n(7751),a=n(8745),o=n(9565),s=n(9504),c=n(9039),l=n(4376),u=n(4901),d=n(5810),f=n(757),p=n(2195),m=n(655),h=n(7680),g=n(8235),_=n(3392),v=n(4495),y=n(7819),b=String,x=i(`JSON`,`stringify`),S=s(/./.exec),C=s(``.charAt),w=s(``.charCodeAt),T=s(``.replace),E=s(``.slice),D=s([].push),O=s(1.1.toString),k=/[\uD800-\uDFFF]/g,A=/^[\uD800-\uDBFF]$/,j=/^[\uDC00-\uDFFF]$/,M=_(),N=M.length,P=!v||c((function(){var e=i(`Symbol`)(`stringify detection`);return x([e])!==`[null]`||x({a:e})!==`{}`||x(Object(e))!==`{}`})),F=c((function(){return x(`\udf06\ud834`)!==`"\\udf06\\ud834"`||x(`\udead`)!==`"\\udead"`})),I=P?function(e,t){var n=h(arguments),r=te(t);if(u(r)||e!==void 0&&!f(e))return n[1]=function(e,t){if(u(r)&&(t=o(r,this,b(e),t)),!f(t))return t},a(x,null,n)}:x,ee=function(e,t,n){var r=C(n,t-1),i=C(n,t+1);return S(A,e)&&!S(j,i)||S(j,e)&&!S(A,r)?`\\u`+O(w(e,0),16):e},te=function(e){if(u(e))return e;if(l(e)){for(var t=e.length,n=[],r=0;r<t;r++){var i=e[r];typeof i==`string`?D(n,i):typeof i!=`number`&&p(i)!==`Number`&&p(i)!==`String`||D(n,m(i))}var a=n.length,o=!0;return function(e,t){if(o)return o=!1,t;if(l(this))return t;for(var r=0;r<a;r++)if(n[r]===e)return t}}};x&&r({target:`JSON`,stat:!0,arity:3,forced:P||F||!y},{stringify:function(e,t,n){var r=te(t),i=[],a=I(e,(function(e,t){var n=u(r)?o(r,this,b(e),t):t;return!y&&d(n)?M+(D(i,n.rawJSON)-1):n}),n);if(typeof a!=`string`||(F&&(a=T(a,k,ee)),y))return a;for(var s=``,c=a.length,l=0;l<c;l++){var f=C(a,l);if(f===`"`){var p=g(a,++l).end-1,m=E(a,l,p);s+=E(m,0,N)===M?i[E(m,N)]:`"`+m+`"`,l=p}else s+=f}return s}})},2892:function(e,t,n){var r=n(6518),i=n(6395),a=n(3724),o=n(4576),s=n(9167),c=n(9504),l=n(2796),u=n(9297),d=n(3167),f=n(1625),p=n(757),m=n(2777),h=n(9039),g=n(8480).f,_=n(7347).f,v=n(4913).f,y=n(1240),b=n(3802).trim,x=`Number`,S=o[x],C=s[x],w=S.prototype,T=o.TypeError,E=c(``.slice),D=c(``.charCodeAt),O=function(e){var t,n,r,i,a,o,s,c,l=m(e,`number`);if(p(l))throw new T(`Cannot convert a Symbol value to a number`);if(typeof l==`string`&&l.length>2){if(l=b(l),(t=D(l,0))===43||t===45){if((n=D(l,2))===88||n===120)return NaN}else if(t===48){switch(D(l,1)){case 66:case 98:r=2,i=49;break;case 79:case 111:r=8,i=55;break;default:return+l}for(o=(a=E(l,2)).length,s=0;s<o;s++)if((c=D(a,s))<48||c>i)return NaN;return parseInt(a,r)}}return+l},k=l(x,!S(` 0o1`)||!S(`0b1`)||S(`+0x1`)),A=function(e){var t,n=arguments.length<1?0:S(function(e){var t=m(e,`number`);return typeof t==`bigint`?t:O(t)}(e));return f(w,t=this)&&h((function(){y(t)}))?d(Object(n),this,A):n};A.prototype=w,k&&!i&&(w.constructor=A),r({global:!0,constructor:!0,wrap:!0,forced:k},{Number:A});var j=function(e,t){for(var n,r=a?g(t):`MAX_VALUE,MIN_VALUE,NaN,NEGATIVE_INFINITY,POSITIVE_INFINITY,EPSILON,MAX_SAFE_INTEGER,MIN_SAFE_INTEGER,isFinite,isInteger,isNaN,isSafeInteger,parseFloat,parseInt,fromString,range`.split(`,`),i=0;r.length>i;i++)u(t,n=r[i])&&!u(e,n)&&v(e,n,_(t,n))};i&&C&&j(s[x],C),(k||i)&&j(s[x],S)},2637:function(e,t,n){n(6518)({target:`Number`,stat:!0},{isInteger:n(2087)})},9085:function(e,t,n){var r=n(6518),i=n(4213);r({target:`Object`,stat:!0,arity:2,forced:Object.assign!==i},{assign:i})},7427:function(e,t,n){var r=n(6518),i=n(3724),a=n(2551),o=n(9306),s=n(8981),c=n(4913);i&&r({target:`Object`,proto:!0,forced:a},{__defineGetter__:function(e,t){c.f(s(this),e,{get:o(t),enumerable:!0,configurable:!0})}})},3851:function(e,t,n){var r=n(6518),i=n(9039),a=n(5397),o=n(7347).f,s=n(3724);r({target:`Object`,stat:!0,forced:!s||i((function(){o(1)})),sham:!s},{getOwnPropertyDescriptor:function(e,t){return o(a(e),t)}})},1278:function(e,t,n){var r=n(6518),i=n(3724),a=n(5031),o=n(5397),s=n(7347),c=n(4659);r({target:`Object`,stat:!0,sham:!i},{getOwnPropertyDescriptors:function(e){for(var t,n,r=o(e),i=s.f,l=a(r),u={},d=0;l.length>d;)(n=i(r,t=l[d++]))!==void 0&&c(u,t,n);return u}})},1480:function(e,t,n){var r=n(6518),i=n(9039),a=n(298).f;r({target:`Object`,stat:!0,forced:i((function(){return!Object.getOwnPropertyNames(1)}))},{getOwnPropertyNames:a})},9773:function(e,t,n){var r=n(6518),i=n(4495),a=n(9039),o=n(3717),s=n(8981);r({target:`Object`,stat:!0,forced:!i||a((function(){o.f(1)}))},{getOwnPropertySymbols:function(e){var t=o.f;return t?t(s(e)):[]}})},9432:function(e,t,n){var r=n(6518),i=n(8981),a=n(1072);r({target:`Object`,stat:!0,forced:n(9039)((function(){a(1)}))},{keys:function(e){return a(i(e))}})},6099:function(e,t,n){var r=n(2140),i=n(6840),a=n(3179);r||i(Object.prototype,`toString`,a,{unsafe:!0})},825:function(e,t,n){var r=n(6518),i=n(7751),a=n(8745),o=n(566),s=n(5548),c=n(8551),l=n(34),u=n(2360),d=n(9039),f=i(`Reflect`,`construct`),p=Object.prototype,m=[].push,h=d((function(){function e(){}return!(f((function(){}),[],e)instanceof e)})),g=!d((function(){f((function(){}))})),_=h||g;r({target:`Reflect`,stat:!0,forced:_,sham:_},{construct:function(e,t){s(e),c(t);var n=arguments.length<3?e:s(arguments[2]);if(g&&!h)return f(e,t,n);if(e===n){switch(t.length){case 0:return new e;case 1:return new e(t[0]);case 2:return new e(t[0],t[1]);case 3:return new e(t[0],t[1],t[2]);case 4:return new e(t[0],t[1],t[2],t[3])}var r=[null];return a(m,r,t),new(a(o,e,r))}var i=n.prototype,d=u(l(i)?i:p),_=a(e,d,t);return l(_)?_:d}})},4864:function(e,t,n){var r=n(3724),i=n(4576),a=n(9504),o=n(2796),s=n(3167),c=n(6699),l=n(2360),u=n(8480).f,d=n(1625),f=n(788),p=n(655),m=n(1034),h=n(8429),g=n(1056),_=n(6840),v=n(9039),y=n(9297),b=n(1181).enforce,x=n(7633),S=n(8227),C=n(3635),w=n(8814),T=S(`match`),E=i.RegExp,D=E.prototype,O=i.SyntaxError,k=a(D.exec),A=a(``.charAt),j=a(``.replace),M=a(``.indexOf),N=a(``.slice),P=/^\?<[^\s\d!#%&*+<=>@^][^\s!#%&*+<=>@^]*>/,F=/a/g,I=/a/g,ee=new E(F)!==F,te=h.MISSED_STICKY,ne=h.UNSUPPORTED_Y;if(o(`RegExp`,r&&(!ee||te||C||w||v((function(){return I[T]=!1,E(F)!==F||E(I)===I||String(E(F,`i`))!==`/a/i`}))))){for(var L=function(e,t){var n,r,i,a,o,u,h=d(D,this),g=f(e),_=t===void 0,v=[],x=e;if(!h&&g&&_&&e.constructor===L)return e;if((g||d(D,e))&&(e=e.source,_&&(t=m(x))),e=e===void 0?``:p(e),t=t===void 0?``:p(t),x=e,C&&`dotAll`in F&&(r=!!t&&M(t,`s`)>-1)&&(t=j(t,/s/g,``)),n=t,te&&`sticky`in F&&(i=!!t&&M(t,`y`)>-1)&&ne&&(t=j(t,/y/g,``)),w&&(a=function(e){for(var t,n=e.length,r=0,i=``,a=[],o=l(null),s=!1,c=!1,u=0,d=``;r<n;r++){if((t=A(e,r))===`\\`)t+=A(e,++r);else if(t===`]`)s=!1;else if(!s)switch(!0){case t===`[`:s=!0;break;case t===`(`:if(i+=t,N(e,r+1,r+3)===`?:`)continue;k(P,N(e,r+1))&&(r+=2,c=!0),u++;continue;case t===`>`&&c:if(d===``||y(o,d))throw new O(`Invalid capture group name`);o[d]=!0,a[a.length]=[d,u],c=!1,d=``;continue}c?d+=t:i+=t}return[i,a]}(e),e=a[0],v=a[1]),o=s(E(e,t),h?this:D,L),(r||i||v.length)&&(u=b(o),r&&(u.dotAll=!0,u.raw=L(function(e){for(var t,n=e.length,r=0,i=``,a=!1;r<n;r++)(t=A(e,r))===`\\`?i+=t+A(e,++r):a||t!==`.`?(t===`[`?a=!0:t===`]`&&(a=!1),i+=t):i+=`[\\s\\S]`;return i}(e),n)),i&&(u.sticky=!0),v.length&&(u.groups=v)),e!==x)try{c(o,`source`,x===``?`(?:)`:x)}catch{}return o},R=u(E),z=0;R.length>z;)g(L,E,R[z++]);D.constructor=L,L.prototype=D,_(i,`RegExp`,L,{constructor:!0})}x(`RegExp`)},7495:function(e,t,n){var r=n(6518),i=n(7323);r({target:`RegExp`,proto:!0,forced:/./.exec!==i},{exec:i})},8781:function(e,t,n){var r=n(350).PROPER,i=n(6840),a=n(8551),o=n(655),s=n(9039),c=n(1034),l=`toString`,u=RegExp.prototype,d=u[l],f=s((function(){return d.call({source:`a`,flags:`b`})!==`/a/b`})),p=r&&d.name!==l;(f||p)&&i(u,l,(function(){var e=a(this);return`/`+o(e.source)+`/`+o(c(e))}),{unsafe:!0})},1699:function(e,t,n){var r=n(6518),i=n(9504),a=n(5749),o=n(7750),s=n(655),c=n(1436),l=i(``.indexOf);r({target:`String`,proto:!0,forced:!c(`includes`)},{includes:function(e){return!!~l(s(o(this)),s(a(e)),arguments.length>1?arguments[1]:void 0)}})},7764:function(e,t,n){var r=n(8183).charAt,i=n(655),a=n(1181),o=n(1088),s=n(2529),c=`String Iterator`,l=a.set,u=a.getterFor(c);o(String,`String`,(function(e){l(this,{type:c,string:i(e),index:0})}),(function(){var e,t=u(this),n=t.string,i=t.index;return i>=n.length?s(void 0,!0):(e=r(n,i),t.index+=e.length,s(e,!1))}))},8543:function(e,t,n){var r=n(6518),i=n(9565),a=n(7476),o=n(3994),s=n(2529),c=n(7750),l=n(8014),u=n(655),d=n(8551),f=n(34),p=n(2195),m=n(788),h=n(1034),g=n(5966),_=n(6840),v=n(9039),y=n(8227),b=n(2293),x=n(7829),S=n(6682),C=n(1181),w=n(6395),T=y(`matchAll`),E=`RegExp String`,D=E+` Iterator`,O=C.set,k=C.getterFor(D),A=RegExp.prototype,j=TypeError,M=a(``.indexOf),N=a(``.matchAll),P=!!N&&!v((function(){N(`a`,/./)})),F=o((function(e,t,n,r){O(this,{type:D,regexp:e,string:t,global:n,unicode:r,done:!1})}),E,(function(){var e=k(this);if(e.done)return s(void 0,!0);var t=e.regexp,n=e.string,r=S(t,n);return r===null?(e.done=!0,s(void 0,!0)):e.global?(u(r[0])===``&&(t.lastIndex=x(n,l(t.lastIndex),e.unicode)),s(r,!1)):(e.done=!0,s(r,!1))})),I=function(e){var t,n,r,i=d(this),a=u(e),o=b(i,RegExp),s=u(h(i));return t=new o(o===RegExp?i.source:i,s),n=!!~M(s,`g`),r=!!~M(s,`u`),t.lastIndex=l(i.lastIndex),new F(t,a,n,r)};r({target:`String`,proto:!0,forced:P},{matchAll:function(e){var t,n,r,a,o=c(this);if(f(e)){if(m(e)&&(t=u(c(h(e))),!~M(t,`g`)))throw new j("`.matchAll` does not allow non-global regexes");if(P)return N(o,e);if((r=g(e,T))===void 0&&w&&p(e)===`RegExp`&&(r=I),r)return i(r,e,o)}else if(P)return N(o,e);return n=u(o),a=new RegExp(e,`g`),w?i(I,a,n):a[T](n)}}),w||T in A||_(A,T,I)},1761:function(e,t,n){var r=n(9565),i=n(9504),a=n(9228),o=n(8551),s=n(34),c=n(8014),l=n(655),u=n(7750),d=n(5966),f=n(7829),p=n(1034),m=n(6682),h=i(``.indexOf);a(`match`,(function(e,t,n){return[function(t){var n=u(this),i=s(t)?d(t,e):void 0;return i?r(i,t,n):new RegExp(t)[e](l(n))},function(e){var r=o(this),i=l(e),a=n(t,r,i);if(a.done)return a.value;var s=l(p(r));if(h(s,`g`)===-1)return m(r,i);var u=h(s,`u`)!==-1;r.lastIndex=0;for(var d,g=[],_=0;(d=m(r,i))!==null;){var v=l(d[0]);g[_]=v,v===``&&(r.lastIndex=f(i,c(r.lastIndex),u)),_++}return _===0?null:g}]}))},5440:function(e,t,n){var r=n(8745),i=n(9565),a=n(9504),o=n(9228),s=n(9039),c=n(8551),l=n(4901),u=n(34),d=n(1291),f=n(8014),p=n(655),m=n(7750),h=n(7829),g=n(5966),_=n(2478),v=n(1034),y=n(6682),b=n(8227)(`replace`),x=Math.max,S=Math.min,C=a([].concat),w=a([].push),T=a(``.indexOf),E=a(``.slice),D=`a`.replace(/./,`$0`)===`$0`,O=!!/./[b]&&/./[b](`a`,`$0`)===``;o(`replace`,(function(e,t,n){var a=O?`$`:`$0`;return[function(e,n){var r=m(this),a=u(e)?g(e,b):void 0;return a?i(a,e,r,n):i(t,p(r),e,n)},function(e,i){var o=c(this),s=p(e);if(typeof i==`string`&&T(i,a)===-1&&T(i,`$<`)===-1){var u=n(t,o,s,i);if(u.done)return u.value}var m=l(i);m||(i=p(i));var g,b=p(v(o)),D=T(b,`g`)!==-1;D&&(g=T(b,`u`)!==-1,o.lastIndex=0);for(var O,k=[];(O=y(o,s))!==null&&(w(k,O),D);)p(O[0])===``&&(o.lastIndex=h(s,f(o.lastIndex),g));for(var A,j=``,M=0,N=0;N<k.length;N++){for(var P,F=p((O=k[N])[0]),I=x(S(d(O.index),s.length),0),ee=[],te=1;te<O.length;te++)w(ee,(A=O[te])===void 0?A:String(A));var ne=O.groups;if(m){var L=C([F],ee,I,s);ne!==void 0&&w(L,ne),P=p(r(i,void 0,L))}else P=_(F,s,I,ee,ne,i);I>=M&&(j+=E(s,M,I)+P,M=I+F.length)}return j+E(s,M)}]}),!!s((function(){var e=/./;return e.exec=function(){var e=[];return e.groups={a:`7`},e},``.replace(e,`$<a>`)!==`7`}))||!D||O)},744:function(e,t,n){var r=n(9565),i=n(9504),a=n(9228),o=n(8551),s=n(34),c=n(7750),l=n(2293),u=n(7829),d=n(8014),f=n(655),p=n(5966),m=n(6682),h=n(8429),g=n(9039),_=h.UNSUPPORTED_Y,v=Math.min,y=i([].push),b=i(``.slice),x=!g((function(){var e=/(?:)/,t=e.exec;e.exec=function(){return t.apply(this,arguments)};var n=`ab`.split(e);return n.length!==2||n[0]!==`a`||n[1]!==`b`})),S=`abbc`.split(/(b)*/)[1]===`c`||`test`.split(/(?:)/,-1).length!==4||`ab`.split(/(?:ab)*/).length!==2||`.`.split(/(.?)(.?)/).length!==4||`.`.split(/()()/).length>1||``.split(/.?/).length;a(`split`,(function(e,t,n){var i=`0`.split(void 0,0).length?function(e,n){return e===void 0&&n===0?[]:r(t,this,e,n)}:t;return[function(t,n){var a=c(this),o=s(t)?p(t,e):void 0;return o?r(o,t,a,n):r(i,f(a),t,n)},function(e,r){var a=o(this),s=f(e);if(!S){var c=n(i,a,s,r,i!==t);if(c.done)return c.value}var p=l(a,RegExp),h=a.unicode,g=(a.ignoreCase?`i`:``)+(a.multiline?`m`:``)+(a.unicode?`u`:``)+(_?`g`:`y`),x=new p(_?`^(?:`+a.source+`)`:a,g),C=r===void 0?4294967295:r>>>0;if(C===0)return[];if(s.length===0)return m(x,s)===null?[s]:[];for(var w=0,T=0,E=[];T<s.length;){x.lastIndex=_?0:T;var D,O=m(x,_?b(s,T):s);if(O===null||(D=v(d(x.lastIndex+(_?T:0)),s.length))===w)T=u(s,T,h);else{if(y(E,b(s,w,T)),E.length===C)return E;for(var k=1;k<=O.length-1;k++)if(y(E,O[k]),E.length===C)return E;T=w=D}}return y(E,b(s,w)),E}]}),S||!x,_)},2762:function(e,t,n){var r=n(6518),i=n(3802).trim;r({target:`String`,proto:!0,forced:n(706)(`trim`)},{trim:function(){return i(this)}})},6761:function(e,t,n){var r=n(6518),i=n(4576),a=n(9565),o=n(9504),s=n(6395),c=n(3724),l=n(4495),u=n(9039),d=n(9297),f=n(1625),p=n(8551),m=n(5397),h=n(6969),g=n(655),_=n(6980),v=n(2360),y=n(1072),b=n(8480),x=n(298),S=n(3717),C=n(7347),w=n(4913),T=n(6801),E=n(8773),D=n(6840),O=n(2106),k=n(5745),A=n(6119),j=n(421),M=n(3392),N=n(8227),P=n(1951),F=n(511),I=n(8242),ee=n(687),te=n(1181),ne=n(9213).forEach,L=A(`hidden`),R=`Symbol`,z=`prototype`,re=te.set,ie=te.getterFor(R),B=Object[z],V=i.Symbol,ae=V&&V[z],oe=i.RangeError,se=i.TypeError,ce=i.QObject,le=C.f,H=w.f,ue=x.f,de=E.f,U=o([].push),fe=k(`symbols`),pe=k(`op-symbols`),me=k(`wks`),he=!ce||!ce[z]||!ce[z].findChild,ge=function(e,t,n){var r=le(B,t);r&&delete B[t],H(e,t,n),r&&e!==B&&H(B,t,r)},_e=c&&u((function(){return v(H({},`a`,{get:function(){return H(this,`a`,{value:7}).a}})).a!==7}))?ge:H,ve=function(e,t){var n=fe[e]=v(ae);return re(n,{type:R,tag:e,description:t}),c||(n.description=t),n},ye=function(e,t,n){e===B&&ye(pe,t,n),p(e);var r=h(t);return p(n),d(fe,r)?(n.enumerable?(d(e,L)&&e[L][r]&&(e[L][r]=!1),n=v(n,{enumerable:_(0,!1)})):(d(e,L)||H(e,L,_(1,v(null))),e[L][r]=!0),_e(e,r,n)):H(e,r,n)},be=function(e,t){p(e);var n=m(t);return ne(y(n).concat(we(n)),(function(t){c&&!a(xe,n,t)||ye(e,t,n[t])})),e},xe=function(e){var t=h(e),n=a(de,this,t);return!(this===B&&d(fe,t)&&!d(pe,t))&&(!(n||!d(this,t)||!d(fe,t)||d(this,L)&&this[L][t])||n)},Se=function(e,t){var n=m(e),r=h(t);if(n!==B||!d(fe,r)||d(pe,r)){var i=le(n,r);return!i||!d(fe,r)||d(n,L)&&n[L][r]||(i.enumerable=!0),i}},Ce=function(e){var t=ue(m(e)),n=[];return ne(t,(function(e){d(fe,e)||d(j,e)||U(n,e)})),n},we=function(e){var t=e===B,n=ue(t?pe:m(e)),r=[];return ne(n,(function(e){!d(fe,e)||t&&!d(B,e)||U(r,fe[e])})),r};l||(V=function(){if(f(ae,this))throw new se(`Symbol is not a constructor`);var e=arguments.length&&arguments[0]!==void 0?g(arguments[0]):void 0,t=M(e),n=function(e){var r=this===void 0?i:this;r===B&&a(n,pe,e),d(r,L)&&d(r[L],t)&&(r[L][t]=!1);var o=_(1,e);try{_e(r,t,o)}catch(e){if(!(e instanceof oe))throw e;ge(r,t,o)}};return c&&he&&_e(B,t,{configurable:!0,set:n}),ve(t,e)},D(ae=V[z],`toString`,(function(){return ie(this).tag})),D(V,`withoutSetter`,(function(e){return ve(M(e),e)})),E.f=xe,w.f=ye,T.f=be,C.f=Se,b.f=x.f=Ce,S.f=we,P.f=function(e){return ve(N(e),e)},c&&(O(ae,`description`,{configurable:!0,get:function(){return ie(this).description}}),s||D(B,`propertyIsEnumerable`,xe,{unsafe:!0}))),r({global:!0,constructor:!0,wrap:!0,forced:!l,sham:!l},{Symbol:V}),ne(y(me),(function(e){F(e)})),r({target:R,stat:!0,forced:!l},{useSetter:function(){he=!0},useSimple:function(){he=!1}}),r({target:`Object`,stat:!0,forced:!l,sham:!c},{create:function(e,t){return t===void 0?v(e):be(v(e),t)},defineProperty:ye,defineProperties:be,getOwnPropertyDescriptor:Se}),r({target:`Object`,stat:!0,forced:!l},{getOwnPropertyNames:Ce}),I(),ee(V,R),j[L]=!0},9463:function(e,t,n){var r=n(6518),i=n(3724),a=n(4576),o=n(9504),s=n(9297),c=n(4901),l=n(1625),u=n(655),d=n(2106),f=n(7740),p=a.Symbol,m=p&&p.prototype;if(i&&c(p)&&(!(`description`in m)||p().description!==void 0)){var h={},g=function(){var e=arguments.length<1||arguments[0]===void 0?void 0:u(arguments[0]),t=l(m,this)?new p(e):e===void 0?p():p(e);return e===``&&(h[t]=!0),t};f(g,p),g.prototype=m,m.constructor=g;var _=String(p(`description detection`))===`Symbol(description detection)`,v=o(m.valueOf),y=o(m.toString),b=/^Symbol\((.*)\)[^)]+$/,x=o(``.replace),S=o(``.slice);d(m,`description`,{configurable:!0,get:function(){var e=v(this);if(s(h,e))return``;var t=y(e),n=_?S(t,7,-1):x(t,b,`$1`);return n===``?void 0:n}}),r({global:!0,constructor:!0,forced:!0},{Symbol:g})}},1510:function(e,t,n){var r=n(6518),i=n(7751),a=n(9297),o=n(655),s=n(5745),c=n(1296),l=s(`string-to-symbol-registry`),u=s(`symbol-to-string-registry`);r({target:`Symbol`,stat:!0,forced:!c},{for:function(e){var t=o(e);if(a(l,t))return l[t];var n=i(`Symbol`)(t);return l[t]=n,u[n]=t,n}})},2259:function(e,t,n){n(511)(`iterator`)},2675:function(e,t,n){n(6761),n(1510),n(7812),n(3110),n(9773)},7812:function(e,t,n){var r=n(6518),i=n(9297),a=n(757),o=n(6823),s=n(5745),c=n(1296),l=s(`symbol-to-string-registry`);r({target:`Symbol`,stat:!0,forced:!c},{keyFor:function(e){if(!a(e))throw TypeError(o(e)+` is not a symbol`);if(i(l,e))return l[e]}})},5700:function(e,t,n){var r=n(511),i=n(8242);r(`toPrimitive`),i()},8344:function(e,t,n){n(8543)},3500:function(e,t,n){var r=n(4576),i=n(7400),a=n(9296),o=n(235),s=n(6699),c=function(e){if(e&&e.forEach!==o)try{s(e,`forEach`,o)}catch{e.forEach=o}};for(var l in i)i[l]&&c(r[l]&&r[l].prototype);c(a)},2953:function(e,t,n){var r=n(4576),i=n(7400),a=n(9296),o=n(3792),s=n(6699),c=n(687),l=n(8227)(`iterator`),u=o.values,d=function(e,t){if(e){if(e[l]!==u)try{s(e,l,u)}catch{e[l]=u}if(c(e,t,!0),i[t]){for(var n in o)if(e[n]!==o[n])try{s(e,n,o[n])}catch{e[n]=o[n]}}}};for(var f in i)d(r[f]&&r[f].prototype,f);d(a,`DOMTokenList`)}},t={};function n(r){var i=t[r];if(i!==void 0)return i.exports;var a=t[r]={exports:{}};return e[r].call(a.exports,a,a.exports,n),a.exports}n.d=function(e,t){for(var r in t)n.o(t,r)&&!n.o(e,r)&&Object.defineProperty(e,r,{enumerable:!0,get:t[r]})},n.g=function(){if(typeof globalThis==`object`)return globalThis;try{return this||Function(`return this`)()}catch{if(typeof window==`object`)return window}}(),n.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},n.r=function(e){typeof Symbol<`u`&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:`Module`}),Object.defineProperty(e,"__esModule",{value:!0})};var r={};function i(e){return function(e){if(Array.isArray(e))return o(e)}(e)||function(e){if(typeof Symbol<`u`&&e[Symbol.iterator]!=null||e[`@@iterator`]!=null)return Array.from(e)}(e)||a(e)||function(){throw TypeError(`Invalid attempt to spread non-iterable instance.
- In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}()}function a(e,t){if(e){if(typeof e==`string`)return o(e,t);var n={}.toString.call(e).slice(8,-1);return n===`Object`&&e.constructor&&(n=e.constructor.name),n===`Map`||n===`Set`?Array.from(e):n===`Arguments`||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?o(e,t):void 0}}function o(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}function s(e){return s=typeof Symbol==`function`&&typeof Symbol.iterator==`symbol`?function(e){return typeof e}:function(e){return e&&typeof Symbol==`function`&&e.constructor===Symbol&&e!==Symbol.prototype?`symbol`:typeof e},s(e)}function c(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,`value`in r&&(r.writable=!0),Object.defineProperty(e,u(r.key),r)}}function l(e,t,n){return(t=u(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function u(e){var t=function(e,t){if(s(e)!=`object`||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||`default`);if(s(r)!=`object`)return r;throw TypeError(`@@toPrimitive must return a primitive value.`)}return(t===`string`?String:Number)(e)}(e,`string`);return s(t)==`symbol`?t:t+``}n.r(r),n.d(r,{SimpleKeyboard:function(){return A},default:function(){return j}}),n(5276),n(8598),n(4782),n(4554),n(2010),n(7427),n(6099),n(7495),n(8781),n(5440),n(744),n(2762),typeof Element>`u`||`remove`in Element.prototype||(Element.prototype.remove=function(){this.parentNode&&this.parentNode.removeChild(this)}),typeof self<`u`&&`document`in self&&((!(`classList`in document.createElement(`_`))||document.createElementNS&&!(`classList`in document.createElementNS(`http://www.w3.org/2000/svg`,`g`)))&&function(e){if(`Element`in e){var t=`classList`,n=`prototype`,r=e.Element[n],i=Object,a=String[n].trim||function(){return this.replace(/^\s+|\s+$/g,``)},o=Array[n].indexOf||function(e){for(var t=0,n=this.length;t<n;t++)if(t in this&&this[t]===e)return t;return-1},s=function(e,t){this.name=e,this.code=DOMException[e],this.message=t},c=function(e,t){if(t===``)throw new s(`SYNTAX_ERR`,`The token must not be empty.`);if(/\s/.test(t))throw new s(`INVALID_CHARACTER_ERR`,`The token must not contain space characters.`);return o.call(e,t)},l=function(e){for(var t=a.call(e.getAttribute(`class`)||``),n=t?t.split(/\s+/):[],r=0,i=n.length;r<i;r++)this.push(n[r]);this._updateClassName=function(){e.setAttribute(`class`,this.toString())}},u=l[n]=[],d=function(){return new l(this)};if(s[n]=Error[n],u.item=function(e){return this[e]||null},u.contains=function(e){return~c(this,e+``)},u.add=function(){var e,t=arguments,n=0,r=t.length,i=!1;do~c(this,e=t[n]+``)||(this.push(e),i=!0);while(++n<r);i&&this._updateClassName()},u.remove=function(){var e,t,n=arguments,r=0,i=n.length,a=!1;do for(t=c(this,e=n[r]+``);~t;)this.splice(t,1),a=!0,t=c(this,e);while(++r<i);a&&this._updateClassName()},u.toggle=function(e,t){var n=this.contains(e),r=n?!0!==t&&`remove`:!1!==t&&`add`;return r&&this[r](e),!0===t||!1===t?t:!n},u.replace=function(e,t){var n=c(e+``);~n&&(this.splice(n,1,t),this._updateClassName())},u.toString=function(){return this.join(` `)},i.defineProperty){var f={get:d,enumerable:!0,configurable:!0};try{i.defineProperty(r,t,f)}catch(e){e.number!==void 0&&e.number!==-2146823252||(f.enumerable=!1,i.defineProperty(r,t,f))}}else i[n].__defineGetter__&&r.__defineGetter__(t,d)}}(self),function(){var e=document.createElement(`_`);if(e.classList.add(`c1`,`c2`),!e.classList.contains(`c2`)){var t=function(e){var t=DOMTokenList.prototype[e];DOMTokenList.prototype[e]=function(e){var n,r=arguments.length;for(n=0;n<r;n++)e=arguments[n],t.call(this,e)}};t(`add`),t(`remove`)}if(e.classList.toggle(`c3`,!1),e.classList.contains(`c3`)){var n=DOMTokenList.prototype.toggle;DOMTokenList.prototype.toggle=function(e,t){return 1 in arguments&&!this.contains(e)==!t?t:n.call(this,e)}}`replace`in document.createElement(`_`).classList||(DOMTokenList.prototype.replace=function(e,t){var n=this.toString().split(` `),r=n.indexOf(e+``);~r&&(n=n.slice(r),this.remove.apply(this,n),this.add(t),this.add.apply(this,n.slice(1)))}),e=null}()),n(2675),n(9463),n(2259),n(5700),n(8706),n(2008),n(3418),n(4423),n(3792),n(2062),n(6910),n(739),n(9572),n(2892),n(9085),n(3851),n(1278),n(9432),n(4864),n(1699),n(7764),n(8344),n(3500),n(2953),n(2712),n(2637),n(1480),n(825),n(1761);var d=function(){return e=function e(t){var n=t.getOptions,r=t.getCaretPosition,i=t.getCaretPositionEnd,a=t.dispatch;(function(e,t){if(!(e instanceof t))throw TypeError(`Cannot call a class as a function`)})(this,e),l(this,`getOptions`,void 0),l(this,`getCaretPosition`,void 0),l(this,`getCaretPositionEnd`,void 0),l(this,`dispatch`,void 0),l(this,`maxLengthReached`,void 0),l(this,`isStandardButton`,(function(e){return e&&!(e[0]===`{`&&e[e.length-1]===`}`)})),this.getOptions=n,this.getCaretPosition=r,this.getCaretPositionEnd=i,this.dispatch=a,e.bindMethods(e,this)},t=[{key:`getButtonType`,value:function(e){return e.includes(`{`)&&e.includes(`}`)&&e!==`{//}`?`functionBtn`:`standardBtn`}},{key:`getButtonClass`,value:function(e){var t=this.getButtonType(e),n=e.replace(`{`,``).replace(`}`,``),r=``;return t!==`standardBtn`&&(r=` hg-button-${n}`),`hg-${t}${r}`}},{key:`getDefaultDiplay`,value:function(){return{"{bksp}":`backspace`,"{backspace}":`backspace`,"{enter}":`< enter`,"{shift}":`shift`,"{shiftleft}":`shift`,"{shiftright}":`shift`,"{alt}":`alt`,"{s}":`shift`,"{tab}":`tab`,"{lock}":`caps`,"{capslock}":`caps`,"{accept}":`Submit`,"{space}":` `,"{//}":` `,"{esc}":`esc`,"{escape}":`esc`,"{f1}":`f1`,"{f2}":`f2`,"{f3}":`f3`,"{f4}":`f4`,"{f5}":`f5`,"{f6}":`f6`,"{f7}":`f7`,"{f8}":`f8`,"{f9}":`f9`,"{f10}":`f10`,"{f11}":`f11`,"{f12}":`f12`,"{numpaddivide}":`/`,"{numlock}":`lock`,"{arrowup}":`↑`,"{arrowleft}":`←`,"{arrowdown}":`↓`,"{arrowright}":`→`,"{prtscr}":`print`,"{scrolllock}":`scroll`,"{pause}":`pause`,"{insert}":`ins`,"{home}":`home`,"{pageup}":`up`,"{delete}":`del`,"{forwarddelete}":`del`,"{end}":`end`,"{pagedown}":`down`,"{numpadmultiply}":`*`,"{numpadsubtract}":`-`,"{numpadadd}":`+`,"{numpadenter}":`enter`,"{period}":`.`,"{numpaddecimal}":`.`,"{numpad0}":`0`,"{numpad1}":`1`,"{numpad2}":`2`,"{numpad3}":`3`,"{numpad4}":`4`,"{numpad5}":`5`,"{numpad6}":`6`,"{numpad7}":`7`,"{numpad8}":`8`,"{numpad9}":`9`}}},{key:`getButtonDisplayName`,value:function(e,t){return(t=arguments.length>2&&arguments[2]!==void 0&&arguments[2]?Object.assign({},this.getDefaultDiplay(),t):t||this.getDefaultDiplay())[e]||e}},{key:`getUpdatedInput`,value:function(e,t,n){var r=arguments.length>3&&arguments[3]!==void 0?arguments[3]:n,i=arguments.length>4&&arguments[4]!==void 0&&arguments[4],a=this.getOptions(),o=[n,r,i],s=t;return(e===`{bksp}`||e===`{backspace}`)&&s.length>0?s=this.removeAt.apply(this,[s].concat(o)):(e===`{delete}`||e===`{forwarddelete}`)&&s.length>0?s=this.removeForwardsAt.apply(this,[s].concat(o)):e===`{space}`?s=this.addStringAt.apply(this,[s,` `].concat(o)):e!==`{tab}`||typeof a.tabCharOnTab==`boolean`&&!1===a.tabCharOnTab?e!==`{enter}`&&e!==`{numpadenter}`||!a.newLineOnEnter?e.includes(`numpad`)&&Number.isInteger(Number(e[e.length-2]))?s=this.addStringAt.apply(this,[s,e[e.length-2]].concat(o)):e===`{numpaddivide}`?s=this.addStringAt.apply(this,[s,`/`].concat(o)):e===`{numpadmultiply}`?s=this.addStringAt.apply(this,[s,`*`].concat(o)):e===`{numpadsubtract}`?s=this.addStringAt.apply(this,[s,`-`].concat(o)):e===`{numpadadd}`?s=this.addStringAt.apply(this,[s,`+`].concat(o)):e===`{numpaddecimal}`?s=this.addStringAt.apply(this,[s,`.`].concat(o)):e===`{`||e===`}`?s=this.addStringAt.apply(this,[s,e].concat(o)):e.includes(`{`)||e.includes(`}`)||(s=this.addStringAt.apply(this,[s,e].concat(o))):s=this.addStringAt.apply(this,[s,`
- `].concat(o)):s=this.addStringAt.apply(this,[s,` `].concat(o)),a.debug&&console.log(`Input will be: `+s),s}},{key:`updateCaretPos`,value:function(e){var t=arguments.length>1&&arguments[1]!==void 0&&arguments[1],n=this.updateCaretPosAction(e,t);this.dispatch((function(e){e.setCaretPosition(n)}))}},{key:`updateCaretPosAction`,value:function(e){var t=arguments.length>1&&arguments[1]!==void 0&&arguments[1],n=this.getOptions(),r=this.getCaretPosition();return r!=null&&(t?r>0&&(r-=e):r+=e),n.debug&&console.log(`Caret at:`,r),r}},{key:`addStringAt`,value:function(e,t){var n,r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:e.length,i=arguments.length>3&&arguments[3]!==void 0?arguments[3]:e.length,a=arguments.length>4&&arguments[4]!==void 0&&arguments[4];return r||r===0?(n=[e.slice(0,r),t,e.slice(i)].join(``),this.isMaxLengthReached()||a&&this.updateCaretPos(t.length)):n=e+t,n}},{key:`removeAt`,value:function(e){var t,n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:e.length,r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:e.length,i=arguments.length>3&&arguments[3]!==void 0&&arguments[3];if(n===0&&r===0)return e;if(n===r){var a=/([\uD800-\uDBFF][\uDC00-\uDFFF])/g;n&&n>=0?e.substring(n-2,n).match(a)?(t=e.substr(0,n-2)+e.substr(n),i&&this.updateCaretPos(2,!0)):(t=e.substr(0,n-1)+e.substr(n),i&&this.updateCaretPos(1,!0)):e.slice(-2).match(a)?(t=e.slice(0,-2),i&&this.updateCaretPos(2,!0)):(t=e.slice(0,-1),i&&this.updateCaretPos(1,!0))}else t=e.slice(0,n)+e.slice(r),i&&this.dispatch((function(e){e.setCaretPosition(n)}));return t}},{key:`removeForwardsAt`,value:function(e){var t,n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:e.length,r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:e.length,i=arguments.length>3&&arguments[3]!==void 0&&arguments[3];return e!=null&&e.length&&n!==null?(n===r?t=e.substring(n,n+2).match(/([\uD800-\uDBFF][\uDC00-\uDFFF])/g)?e.substr(0,n)+e.substr(n+2):e.substr(0,n)+e.substr(n+1):(t=e.slice(0,n)+e.slice(r),i&&this.dispatch((function(e){e.setCaretPosition(n)}))),t):e}},{key:`handleMaxLength`,value:function(e,t){var n=this.getOptions(),r=n.maxLength,i=e[n.inputName||`default`],a=t.length-1>=r;if(t.length<=i.length)return!1;if(Number.isInteger(r))return n.debug&&console.log(`maxLength (num) reached:`,a),a?(this.maxLengthReached=!0,!0):(this.maxLengthReached=!1,!1);if(s(r)===`object`){var o=t.length-1>=r[n.inputName||`default`];return n.debug&&console.log(`maxLength (obj) reached:`,o),o?(this.maxLengthReached=!0,!0):(this.maxLengthReached=!1,!1)}}},{key:`isMaxLengthReached`,value:function(){return!!this.maxLengthReached}},{key:`isTouchDevice`,value:function(){return`ontouchstart`in window||navigator.maxTouchPoints}},{key:`pointerEventsSupported`,value:function(){return!!window.PointerEvent}},{key:`camelCase`,value:function(e){return e?e.toLowerCase().trim().split(/[.\-_\s]/g).reduce((function(e,t){return t.length?e+t[0].toUpperCase()+t.slice(1):e})):``}},{key:`chunkArray`,value:function(e,t){return i(Array(Math.ceil(e.length/t))).map((function(n,r){return e.slice(t*r,t+t*r)}))}},{key:`escapeRegex`,value:function(e){return e.replace(/[-\/\\^$*+?.()|[\]{}]/g,`\\$&`)}},{key:`getRtlOffset`,value:function(e,t){var n=e,r=t.indexOf(``);return r<e&&r!=-1&&n--,t.indexOf(``)<e&&r!=-1&&n--,n<0?0:n}},{key:`isConstructor`,value:function(e){try{Reflect.construct(String,[],e)}catch{return!1}return!0}}],n=[{key:`bindMethods`,value:function(e,t){var n,r=function(e,t){var n=typeof Symbol<`u`&&e[Symbol.iterator]||e[`@@iterator`];if(!n){if(Array.isArray(e)||(n=a(e))||t&&e&&typeof e.length==`number`){n&&(e=n);var r=0,i=function(){};return{s:i,n:function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}},e:function(e){throw e},f:i}}throw TypeError(`Invalid attempt to iterate non-iterable instance.
- In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}var o,s=!0,c=!1;return{s:function(){n=n.call(e)},n:function(){var e=n.next();return s=e.done,e},e:function(e){c=!0,o=e},f:function(){try{s||n.return==null||n.return()}finally{if(c)throw o}}}}(Object.getOwnPropertyNames(e.prototype));try{for(r.s();!(n=r.n()).done;){var i=n.value;i===`constructor`||i===`bindMethods`||(t[i]=t[i].bind(t))}}catch(e){r.e(e)}finally{r.f()}}}],t&&c(e.prototype,t),n&&c(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e;var e,t,n}();l(d,`noop`,(function(){}));var f=d;function p(e){return p=typeof Symbol==`function`&&typeof Symbol.iterator==`symbol`?function(e){return typeof e}:function(e){return e&&typeof Symbol==`function`&&e.constructor===Symbol&&e!==Symbol.prototype?`symbol`:typeof e},p(e)}function m(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,`value`in r&&(r.writable=!0),Object.defineProperty(e,g(r.key),r)}}function h(e,t,n){return(t=g(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function g(e){var t=function(e,t){if(p(e)!=`object`||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||`default`);if(p(r)!=`object`)return r;throw TypeError(`@@toPrimitive must return a primitive value.`)}return(t===`string`?String:Number)(e)}(e,`string`);return p(t)==`symbol`?t:t+``}var _=function(){return e=function e(t){var n=this,r=t.dispatch,i=t.getOptions;(function(e,t){if(!(e instanceof t))throw TypeError(`Cannot call a class as a function`)})(this,e),h(this,`getOptions`,void 0),h(this,`dispatch`,void 0),h(this,`isModifierKey`,(function(e){return e.altKey||e.ctrlKey||e.shiftKey||[`Tab`,`CapsLock`,`Esc`,`ArrowUp`,`ArrowDown`,`ArrowLeft`,`ArrowRight`].includes(e.code||e.key||n.keyCodeToKey(e?.keyCode))})),this.dispatch=r,this.getOptions=i,f.bindMethods(e,this)},t=[{key:`handleHighlightKeyDown`,value:function(e){var t=this.getOptions();t.physicalKeyboardHighlightPreventDefault&&this.isModifierKey(e)&&(e.preventDefault(),e.stopImmediatePropagation());var n=this.getSimpleKeyboardLayoutKey(e);this.dispatch((function(r){var i,a,o=r.getButtonElement(n),s=r.getButtonElement(`{${n}}`);if(o)i=o,a=n;else{if(!s)return;i=s,a=`{${n}}`}var c,l,u,d,f=function(e){e.style.background=t.physicalKeyboardHighlightBgColor||`#dadce4`,e.style.color=t.physicalKeyboardHighlightTextColor||`black`};if(i)if(Array.isArray(i)){if(i.forEach((function(e){return f(e)})),t.physicalKeyboardHighlightPress)if(t.physicalKeyboardHighlightPressUsePointerEvents)(c=i[0])==null||(l=c.onpointerdown)==null||l.call(c,e);else if(t.physicalKeyboardHighlightPressUseClick){var p;(p=i[0])==null||p.click()}else r.handleButtonClicked(a,e)}else f(i),t.physicalKeyboardHighlightPress&&(t.physicalKeyboardHighlightPressUsePointerEvents?(u=i)==null||(d=u.onpointerdown)==null||d.call(u,e):t.physicalKeyboardHighlightPressUseClick?i.click():r.handleButtonClicked(a,e))}))}},{key:`handleHighlightKeyUp`,value:function(e){var t=this.getOptions();t.physicalKeyboardHighlightPreventDefault&&this.isModifierKey(e)&&(e.preventDefault(),e.stopImmediatePropagation());var n=this.getSimpleKeyboardLayoutKey(e);this.dispatch((function(r){var i,a,o,s=r.getButtonElement(n)||r.getButtonElement(`{${n}}`),c=function(e){e.removeAttribute&&e.removeAttribute(`style`)};s&&(Array.isArray(s)?(s.forEach((function(e){return c(e)})),t.physicalKeyboardHighlightPressUsePointerEvents&&((i=s[0])==null||(a=i.onpointerup)==null||a.call(i,e))):(c(s),t.physicalKeyboardHighlightPressUsePointerEvents&&(s==null||(o=s.onpointerup)==null||o.call(s,e))))}))}},{key:`getSimpleKeyboardLayoutKey`,value:function(e){var t=``,n=e.code||e.key||this.keyCodeToKey(e?.keyCode);return(t=n!=null&&n.includes(`Numpad`)||n!=null&&n.includes(`Shift`)||n!=null&&n.includes(`Space`)||n!=null&&n.includes(`Backspace`)||n!=null&&n.includes(`Control`)||n!=null&&n.includes(`Alt`)||n!=null&&n.includes(`Meta`)?e.code||``:e.key||this.keyCodeToKey(e?.keyCode)||``).length>1?t?.toLowerCase():t}},{key:`keyCodeToKey`,value:function(e){return{8:`Backspace`,9:`Tab`,13:`Enter`,16:`Shift`,17:`Ctrl`,18:`Alt`,19:`Pause`,20:`CapsLock`,27:`Esc`,32:`Space`,33:`PageUp`,34:`PageDown`,35:`End`,36:`Home`,37:`ArrowLeft`,38:`ArrowUp`,39:`ArrowRight`,40:`ArrowDown`,45:`Insert`,46:`Delete`,48:`0`,49:`1`,50:`2`,51:`3`,52:`4`,53:`5`,54:`6`,55:`7`,56:`8`,57:`9`,65:`A`,66:`B`,67:`C`,68:`D`,69:`E`,70:`F`,71:`G`,72:`H`,73:`I`,74:`J`,75:`K`,76:`L`,77:`M`,78:`N`,79:`O`,80:`P`,81:`Q`,82:`R`,83:`S`,84:`T`,85:`U`,86:`V`,87:`W`,88:`X`,89:`Y`,90:`Z`,91:`Meta`,96:`Numpad0`,97:`Numpad1`,98:`Numpad2`,99:`Numpad3`,100:`Numpad4`,101:`Numpad5`,102:`Numpad6`,103:`Numpad7`,104:`Numpad8`,105:`Numpad9`,106:`NumpadMultiply`,107:`NumpadAdd`,109:`NumpadSubtract`,110:`NumpadDecimal`,111:`NumpadDivide`,112:`F1`,113:`F2`,114:`F3`,115:`F4`,116:`F5`,117:`F6`,118:`F7`,119:`F8`,120:`F9`,121:`F10`,122:`F11`,123:`F12`,144:`NumLock`,145:`ScrollLock`,186:`;`,187:`=`,188:`,`,189:`-`,190:`.`,191:`/`,192:"`",219:`[`,220:`\\`,221:`]`,222:`'`}[e]||``}}],t&&m(e.prototype,t),n&&m(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e;var e,t,n}();function v(e){return v=typeof Symbol==`function`&&typeof Symbol.iterator==`symbol`?function(e){return typeof e}:function(e){return e&&typeof Symbol==`function`&&e.constructor===Symbol&&e!==Symbol.prototype?`symbol`:typeof e},v(e)}function y(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,`value`in r&&(r.writable=!0),Object.defineProperty(e,x(r.key),r)}}function b(e,t,n){return(t=x(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function x(e){var t=function(e,t){if(v(e)!=`object`||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||`default`);if(v(r)!=`object`)return r;throw TypeError(`@@toPrimitive must return a primitive value.`)}return(t===`string`?String:Number)(e)}(e,`string`);return v(t)==`symbol`?t:t+``}var S=function(){return e=function e(t){var n=t.utilities,r=t.options;(function(e,t){if(!(e instanceof t))throw TypeError(`Cannot call a class as a function`)})(this,e),b(this,`utilities`,void 0),b(this,`options`,void 0),b(this,`candidateBoxElement`,void 0),b(this,`pageIndex`,0),b(this,`pageSize`,void 0),this.utilities=n,this.options=r,f.bindMethods(e,this),this.pageSize=this.utilities.getOptions().layoutCandidatesPageSize||5},t=[{key:`destroy`,value:function(){this.candidateBoxElement&&(this.candidateBoxElement.remove(),this.pageIndex=0)}},{key:`show`,value:function(e){var t=this,n=e.candidateValue,r=e.targetElement,i=e.onSelect;if(n&&n.length){var a=this.utilities.chunkArray(n.split(` `),this.pageSize);this.renderPage({candidateListPages:a,targetElement:r,pageIndex:this.pageIndex,nbPages:a.length,onItemSelected:function(e,n){i(e,n),t.destroy()}})}}},{key:`renderPage`,value:function(e){var t,n=this,r=e.candidateListPages,i=e.targetElement,a=e.pageIndex,o=e.nbPages,s=e.onItemSelected;(t=this.candidateBoxElement)==null||t.remove(),this.candidateBoxElement=document.createElement(`div`),this.candidateBoxElement.className=`hg-candidate-box`;var c=document.createElement(`ul`);c.className=`hg-candidate-box-list`,r[a].forEach((function(e){var t=document.createElement(`li`),r=function(){var e=new(n.options.useTouchEvents?TouchEvent:MouseEvent)(`click`);return Object.defineProperty(e,"target",{value:t}),e};t.className=`hg-candidate-box-list-item`,t.innerHTML=n.options.display?.[e]||e,n.options.useTouchEvents?t.ontouchstart=function(t){return s(e,t||r())}:t.onclick=function(){return s(e,arguments.length>0&&arguments[0]!==void 0?arguments[0]:r())},c.appendChild(t)}));var l=a>0,u=document.createElement(`div`);u.classList.add(`hg-candidate-box-prev`),l&&u.classList.add(`hg-candidate-box-btn-active`);var d=function(){l&&n.renderPage({candidateListPages:r,targetElement:i,pageIndex:a-1,nbPages:o,onItemSelected:s})};this.options.useTouchEvents?u.ontouchstart=d:u.onclick=d,this.candidateBoxElement.appendChild(u),this.candidateBoxElement.appendChild(c);var f=a<o-1,p=document.createElement(`div`);p.classList.add(`hg-candidate-box-next`),f&&p.classList.add(`hg-candidate-box-btn-active`);var m=function(){f&&n.renderPage({candidateListPages:r,targetElement:i,pageIndex:a+1,nbPages:o,onItemSelected:s})};this.options.useTouchEvents?p.ontouchstart=m:p.onclick=m,this.candidateBoxElement.appendChild(p),i.prepend(this.candidateBoxElement)}}],t&&y(e.prototype,t),n&&y(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e;var e,t,n}();function C(e){return function(e){if(Array.isArray(e))return w(e)}(e)||function(e){if(typeof Symbol<`u`&&e[Symbol.iterator]!=null||e[`@@iterator`]!=null)return Array.from(e)}(e)||function(e,t){if(e){if(typeof e==`string`)return w(e,t);var n={}.toString.call(e).slice(8,-1);return n===`Object`&&e.constructor&&(n=e.constructor.name),n===`Map`||n===`Set`?Array.from(e):n===`Arguments`||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?w(e,t):void 0}}(e)||function(){throw TypeError(`Invalid attempt to spread non-iterable instance.
- In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}()}function w(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}function T(e){return T=typeof Symbol==`function`&&typeof Symbol.iterator==`symbol`?function(e){return typeof e}:function(e){return e&&typeof Symbol==`function`&&e.constructor===Symbol&&e!==Symbol.prototype?`symbol`:typeof e},T(e)}function E(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function D(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,`value`in r&&(r.writable=!0),Object.defineProperty(e,k(r.key),r)}}function O(e,t,n){return(t=k(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function k(e){var t=function(e,t){if(T(e)!=`object`||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||`default`);if(T(r)!=`object`)return r;throw TypeError(`@@toPrimitive must return a primitive value.`)}return(t===`string`?String:Number)(e)}(e,`string`);return T(t)==`symbol`?t:t+``}var A=function(){return e=function e(t,n){var r=this;if(function(e,t){if(!(e instanceof t))throw TypeError(`Cannot call a class as a function`)}(this,e),O(this,`input`,void 0),O(this,`options`,void 0),O(this,`utilities`,void 0),O(this,`caretPosition`,void 0),O(this,`caretPositionEnd`,void 0),O(this,`keyboardDOM`,void 0),O(this,`keyboardPluginClasses`,void 0),O(this,`keyboardDOMClass`,void 0),O(this,`buttonElements`,void 0),O(this,`currentInstanceName`,void 0),O(this,`allKeyboardInstances`,void 0),O(this,`keyboardInstanceNames`,void 0),O(this,`isFirstKeyboardInstance`,void 0),O(this,`physicalKeyboard`,void 0),O(this,`modules`,void 0),O(this,`activeButtonClass`,void 0),O(this,`holdInteractionTimeout`,void 0),O(this,`holdTimeout`,void 0),O(this,`isMouseHold`,void 0),O(this,`initialized`,void 0),O(this,`candidateBox`,void 0),O(this,`keyboardRowsDOM`,void 0),O(this,`defaultName`,`default`),O(this,`activeInputElement`,null),O(this,`handleParams`,(function(e,t){var n,r,i;if(typeof e==`string`)n=e.split(`.`).join(``),r=document.querySelector(`.${n}`),i=t;else if(e instanceof HTMLDivElement){if(!e.className)throw console.warn(`Any DOM element passed as parameter must have a class.`),Error(`KEYBOARD_DOM_CLASS_ERROR`);n=e.className.split(` `)[0],r=e,i=t}else n=`simple-keyboard`,r=document.querySelector(`.${n}`),i=e;return{keyboardDOMClass:n,keyboardDOM:r,options:i}})),O(this,`getOptions`,(function(){return r.options})),O(this,`getCaretPosition`,(function(){return r.caretPosition})),O(this,`getCaretPositionEnd`,(function(){return r.caretPositionEnd})),O(this,`registerModule`,(function(e,t){r.modules[e]||(r.modules[e]={}),t(r.modules[e])})),O(this,`getKeyboardClassString`,(function(){var e=[...arguments];return[r.keyboardDOMClass].concat(e).filter((function(e){return!!e})).join(` `)})),typeof window<`u`){var i=this.handleParams(t,n),a=i.keyboardDOMClass,o=i.keyboardDOM,s=i.options,c=s===void 0?{}:s;this.utilities=new f({getOptions:this.getOptions,getCaretPosition:this.getCaretPosition,getCaretPositionEnd:this.getCaretPositionEnd,dispatch:this.dispatch}),this.caretPosition=null,this.caretPositionEnd=null,this.keyboardDOM=o,this.options=function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]==null?{}:arguments[t];t%2?E(Object(n),!0).forEach((function(t){O(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):E(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}({layoutName:`default`,theme:`hg-theme-default`,inputName:`default`,preventMouseDownDefault:!1,enableLayoutCandidates:!0,excludeFromLayout:{}},c),this.keyboardPluginClasses=``,f.bindMethods(e,this);var l=this.options.inputName,u=l===void 0?this.defaultName:l;if(this.input={},this.input[u]=``,this.keyboardDOMClass=a,this.buttonElements={},window.SimpleKeyboardInstances||(window.SimpleKeyboardInstances={}),this.currentInstanceName=this.utilities.camelCase(this.keyboardDOMClass),window.SimpleKeyboardInstances[this.currentInstanceName]=this,this.allKeyboardInstances=window.SimpleKeyboardInstances,this.keyboardInstanceNames=Object.keys(window.SimpleKeyboardInstances),this.isFirstKeyboardInstance=this.keyboardInstanceNames[0]===this.currentInstanceName,this.physicalKeyboard=new _({dispatch:this.dispatch,getOptions:this.getOptions}),this.candidateBox=this.options.enableLayoutCandidates?new S({utilities:this.utilities,options:this.options}):null,!this.keyboardDOM)throw console.warn(`".${a}" was not found in the DOM.`),Error(`KEYBOARD_DOM_ERROR`);this.render(),this.modules={},this.loadModules()}},t=[{key:`setCaretPosition`,value:function(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:e;this.caretPosition=e,this.caretPositionEnd=t}},{key:`getInputCandidates`,value:function(e){var t=this,n=this.options,r=n.layoutCandidates,i=n.layoutCandidatesCaseSensitiveMatch;if(!r||T(r)!==`object`)return{};var a=Object.keys(r).filter((function(n){var r=e.substring(0,t.getCaretPositionEnd()||0)||e,a=RegExp(`${t.utilities.escapeRegex(n)}\$`,i?`g`:`gi`);return!!C(r.matchAll(a)).length}));if(a.length>1){var o=a.sort((function(e,t){return t.length-e.length}))[0];return{candidateKey:o,candidateValue:r[o]}}if(a.length){var s=a[0];return{candidateKey:s,candidateValue:r[s]}}return{}}},{key:`showCandidatesBox`,value:function(e,t,n){var r=this;this.candidateBox&&this.candidateBox.show({candidateValue:t,targetElement:n,onSelect:function(t,n){var i=r.options,a=i.layoutCandidatesCaseSensitiveMatch,o=i.disableCandidateNormalization,s=i.enableLayoutCandidatesKeyPress,c=t;o||(c=t.normalize(`NFD`)),typeof r.options.beforeInputUpdate==`function`&&r.options.beforeInputUpdate(r);var l=r.getInput(r.options.inputName,!0),u=r.getCaretPositionEnd()||0,d=l.substring(0,u||0)||l,f=RegExp(`${r.utilities.escapeRegex(e)}\$`,a?`g`:`gi`),p=d.replace(f,c),m=l.replace(d,p),h=p.length-d.length,g=(u||l.length)+h;g<0&&(g=0),r.setInput(m,r.options.inputName,!0),r.setCaretPosition(g),s&&typeof r.options.onKeyPress==`function`&&r.options.onKeyPress(t,n),typeof r.options.onChange==`function`&&r.options.onChange(r.getInput(r.options.inputName,!0),n),typeof r.options.onChangeAll==`function`&&r.options.onChangeAll(r.getAllInputs(),n)}})}},{key:`handleButtonClicked`,value:function(e,t){var n=this.options,r=n.inputName,i=r===void 0?this.defaultName:r,a=n.debug;if(e!==`{//}`){this.input[i]||(this.input[i]=``),typeof this.options.beforeInputUpdate==`function`&&this.options.beforeInputUpdate(this);var o=this.utilities.getUpdatedInput(e,this.input[i],this.caretPosition,this.caretPositionEnd);if(this.utilities.isStandardButton(e)&&this.activeInputElement&&this.input[i]&&this.input[i]===o&&this.caretPosition===0&&this.caretPositionEnd===o.length)return this.setInput(``,this.options.inputName,!0),this.setCaretPosition(0),this.activeInputElement.value=``,this.activeInputElement.setSelectionRange(0,0),void this.handleButtonClicked(e,t);if(typeof this.options.onKeyPress==`function`&&this.options.onKeyPress(e,t),this.input[i]!==o&&(!this.options.inputPattern||this.options.inputPattern&&this.inputPatternIsValid(o))){if(this.options.maxLength&&this.utilities.handleMaxLength(this.input,o))return;var s=this.utilities.getUpdatedInput(e,this.input[i],this.caretPosition,this.caretPositionEnd,!0);if(this.setInput(s,this.options.inputName,!0),a&&console.log(`Input changed:`,this.getAllInputs()),this.options.debug&&console.log(`Caret at: `,this.getCaretPosition(),this.getCaretPositionEnd(),`(${this.keyboardDOMClass})`,t?.type),this.options.syncInstanceInputs&&this.syncInstanceInputs(),typeof this.options.onChange==`function`&&this.options.onChange(this.getInput(this.options.inputName,!0),t),typeof this.options.onChangeAll==`function`&&this.options.onChangeAll(this.getAllInputs(),t),t!=null&&t.target&&this.options.enableLayoutCandidates){var c,l=this.getInputCandidates(o),u=l.candidateKey,d=l.candidateValue;u&&d?this.showCandidatesBox(u,d,this.keyboardDOM):(c=this.candidateBox)==null||c.destroy()}}this.caretPositionEnd&&this.caretPosition!==this.caretPositionEnd&&(this.setCaretPosition(this.caretPositionEnd,this.caretPositionEnd),this.activeInputElement&&this.activeInputElement.setSelectionRange(this.caretPositionEnd,this.caretPositionEnd),this.options.debug&&console.log(`Caret position aligned`,this.caretPosition)),a&&console.log(`Key pressed:`,e)}}},{key:`getMouseHold`,value:function(){return this.isMouseHold}},{key:`setMouseHold`,value:function(e){this.options.syncInstanceInputs?this.dispatch((function(t){t.isMouseHold=e})):this.isMouseHold=e}},{key:`handleButtonMouseDown`,value:function(e,t){var n=this;t&&(this.options.preventMouseDownDefault&&t.preventDefault(),this.options.stopMouseDownPropagation&&t.stopPropagation(),t.target.classList.add(this.activeButtonClass)),this.holdInteractionTimeout&&clearTimeout(this.holdInteractionTimeout),this.holdTimeout&&clearTimeout(this.holdTimeout),this.setMouseHold(!0),this.options.disableButtonHold||(this.holdTimeout=window.setTimeout((function(){(n.getMouseHold()&&(!e.includes(`{`)&&!e.includes(`}`)||e===`{delete}`||e===`{backspace}`||e===`{bksp}`||e===`{space}`||e===`{tab}`)||e===`{arrowright}`||e===`{arrowleft}`||e===`{arrowup}`||e===`{arrowdown}`)&&(n.options.debug&&console.log(`Button held:`,e),n.handleButtonHold(e)),clearTimeout(n.holdTimeout)}),500))}},{key:`handleButtonMouseUp`,value:function(e,t){var n=this;t&&(this.options.preventMouseUpDefault&&t.preventDefault&&t.preventDefault(),this.options.stopMouseUpPropagation&&t.stopPropagation&&t.stopPropagation(),!(t.target===this.keyboardDOM||t.target&&this.keyboardDOM.contains(t.target)||this.candidateBox&&this.candidateBox.candidateBoxElement&&(t.target===this.candidateBox.candidateBoxElement||t.target&&this.candidateBox.candidateBoxElement.contains(t.target)))&&this.candidateBox&&this.candidateBox.destroy()),this.recurseButtons((function(e){e.classList.remove(n.activeButtonClass)})),this.setMouseHold(!1),this.holdInteractionTimeout&&clearTimeout(this.holdInteractionTimeout),e&&typeof this.options.onKeyReleased==`function`&&this.options.onKeyReleased(e,t)}},{key:`handleKeyboardContainerMouseDown`,value:function(e){this.options.preventMouseDownDefault&&e.preventDefault()}},{key:`handleButtonHold`,value:function(e){var t=this;this.holdInteractionTimeout&&clearTimeout(this.holdInteractionTimeout),this.holdInteractionTimeout=window.setTimeout((function(){t.getMouseHold()?(t.handleButtonClicked(e),t.handleButtonHold(e)):clearTimeout(t.holdInteractionTimeout)}),100)}},{key:`syncInstanceInputs`,value:function(){var e=this;this.dispatch((function(t){t.replaceInput(e.input),t.setCaretPosition(e.caretPosition,e.caretPositionEnd)}))}},{key:`clearInput`,value:function(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:this.options.inputName||this.defaultName;this.input[e]=``,this.setCaretPosition(0),this.options.syncInstanceInputs&&this.syncInstanceInputs()}},{key:`getInput`,value:function(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:this.options.inputName||this.defaultName,t=arguments.length>1&&arguments[1]!==void 0&&arguments[1];return this.options.syncInstanceInputs&&!t&&this.syncInstanceInputs(),this.options.rtl?``+this.input[e].replace(``,``).replace(``,``)+``:this.input[e]}},{key:`getAllInputs`,value:function(){var e=this,t={};return Object.keys(this.input).forEach((function(n){t[n]=e.getInput(n,!0)})),t}},{key:`setInput`,value:function(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:this.options.inputName||this.defaultName,n=arguments.length>2?arguments[2]:void 0;this.input[t]=e,!n&&this.options.syncInstanceInputs&&this.syncInstanceInputs()}},{key:`replaceInput`,value:function(e){this.input=e}},{key:`setOptions`,value:function(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},t=this.changedOptions(e);this.options=Object.assign(this.options,e),t.length&&(this.options.debug&&console.log(`changedOptions`,t),this.onSetOptions(t),this.render())}},{key:`changedOptions`,value:function(e){var t=this;return Object.keys(e).filter((function(n){return JSON.stringify(e[n])!==JSON.stringify(t.options[n])}))}},{key:`onSetOptions`,value:function(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[];e.includes(`layoutName`)&&this.candidateBox&&this.candidateBox.destroy(),(e.includes(`layoutCandidatesPageSize`)||e.includes(`layoutCandidates`))&&this.candidateBox&&(this.candidateBox.destroy(),this.candidateBox=new S({utilities:this.utilities,options:this.options}))}},{key:`resetRows`,value:function(){this.keyboardRowsDOM&&this.keyboardRowsDOM.remove(),this.keyboardDOM.className=this.keyboardDOMClass,this.keyboardDOM.setAttribute(`data-skInstance`,this.currentInstanceName),this.buttonElements={}}},{key:`dispatch`,value:function(e){if(!window.SimpleKeyboardInstances)throw console.warn(`SimpleKeyboardInstances is not defined. Dispatch cannot be called.`),Error(`INSTANCES_VAR_ERROR`);return Object.keys(window.SimpleKeyboardInstances).forEach((function(t){e(window.SimpleKeyboardInstances[t],t)}))}},{key:`addButtonTheme`,value:function(e,t){var n=this;t&&e&&(e.split(` `).forEach((function(r){t.split(` `).forEach((function(t){n.options.buttonTheme||(n.options.buttonTheme=[]);var i=!1;n.options.buttonTheme.map((function(e){if(e!=null&&e.class.split(` `).includes(t)){i=!0;var n=e.buttons.split(` `);n.includes(r)||(i=!0,n.push(r),e.buttons=n.join(` `))}return e})),i||n.options.buttonTheme.push({class:t,buttons:e})}))})),this.render())}},{key:`removeButtonTheme`,value:function(e,t){var n=this;if(!e&&!t)return this.options.buttonTheme=[],void this.render();e&&Array.isArray(this.options.buttonTheme)&&this.options.buttonTheme.length&&(e.split(` `).forEach((function(e){var r;(r=n.options)==null||(r=r.buttonTheme)==null||r.map((function(r,i){if(r&&t&&t.includes(r.class)||!t){var a,o=r?.buttons.split(` `).filter((function(t){return t!==e}));r&&o!=null&&o.length?r.buttons=o.join(` `):((a=n.options.buttonTheme)==null||a.splice(i,1),r=null)}return r}))})),this.render())}},{key:`getButtonElement`,value:function(e){var t,n=this.buttonElements[e];return n&&(t=n.length>1?n:n[0]),t}},{key:`inputPatternIsValid`,value:function(e){var t,n=this.options.inputPattern;if((t=n instanceof RegExp?n:n[this.options.inputName||this.defaultName])&&e){var r=t.test(e);return this.options.debug&&console.log(`inputPattern ("${t}"): ${r?`passed`:`did not pass!`}`),r}return!0}},{key:`setEventListeners`,value:function(){if(this.isFirstKeyboardInstance||!this.allKeyboardInstances){this.options.debug&&console.log(`Caret handling started (${this.keyboardDOMClass})`);var e=this.options.physicalKeyboardHighlightPreventDefault,t=e!==void 0&&e;document.addEventListener(`keyup`,this.handleKeyUp,t),document.addEventListener(`keydown`,this.handleKeyDown,t),document.addEventListener(`mouseup`,this.handleMouseUp),document.addEventListener(`touchend`,this.handleTouchEnd),this.options.updateCaretOnSelectionChange&&document.addEventListener(`selectionchange`,this.handleSelectionChange),document.addEventListener(`select`,this.handleSelect)}}},{key:`handleKeyUp`,value:function(e){this.caretEventHandler(e),this.options.physicalKeyboardHighlight&&this.physicalKeyboard.handleHighlightKeyUp(e)}},{key:`handleKeyDown`,value:function(e){this.options.physicalKeyboardHighlight&&this.physicalKeyboard.handleHighlightKeyDown(e)}},{key:`handleMouseUp`,value:function(e){this.caretEventHandler(e)}},{key:`handleTouchEnd`,value:function(e){this.caretEventHandler(e)}},{key:`handleSelect`,value:function(e){this.caretEventHandler(e)}},{key:`handleSelectionChange`,value:function(e){navigator.userAgent.includes(`Firefox`)||this.caretEventHandler(e)}},{key:`caretEventHandler`,value:function(e){var t,n=this;e.target.tagName&&(t=e.target.tagName.toLowerCase()),this.dispatch((function(r){var i=e.target===r.keyboardDOM||e.target&&r.keyboardDOM.contains(e.target);if(n.options.syncInstanceInputs&&Array.isArray(e.path)&&(i=e.path.some((function(e){var t;return e==null||(t=e.hasAttribute)==null?void 0:t.call(e,`data-skInstance`)}))),(t===`textarea`||t===`input`&&[`text`,`search`,`url`,`tel`,`password`].includes(e.target.type))&&!r.options.disableCaretPositioning){var a=e.target.selectionStart,o=e.target.selectionEnd;r.options.rtl&&(a=r.utilities.getRtlOffset(a,r.getInput()),o=r.utilities.getRtlOffset(o,r.getInput())),r.setCaretPosition(a,o),r.activeInputElement=e.target,r.options.debug&&console.log(`Caret at: `,r.getCaretPosition(),r.getCaretPositionEnd(),e&&e.target.tagName.toLowerCase(),`(${r.keyboardDOMClass})`,e?.type)}else !r.options.disableCaretPositioning&&i||e?.type===`selectionchange`||(r.setCaretPosition(null),r.activeInputElement=null,r.options.debug&&console.log(`Caret position reset due to "${e?.type}" event`,e))}))}},{key:`recurseButtons`,value:function(e){var t=this;e&&Object.keys(this.buttonElements).forEach((function(n){return t.buttonElements[n].forEach(e)}))}},{key:`destroy`,value:function(){this.options.debug&&console.log(`Destroying simple-keyboard instance: ${this.currentInstanceName}`);var e=this.options.physicalKeyboardHighlightPreventDefault,t=e!==void 0&&e;document.removeEventListener(`keyup`,this.handleKeyUp,t),document.removeEventListener(`keydown`,this.handleKeyDown,t),document.removeEventListener(`mouseup`,this.handleMouseUp),document.removeEventListener(`touchend`,this.handleTouchEnd),document.removeEventListener(`select`,this.handleSelect),this.options.updateCaretOnSelectionChange&&document.removeEventListener(`selectionchange`,this.handleSelectionChange),document.onpointerup=null,document.ontouchend=null,document.ontouchcancel=null,document.onmouseup=null,this.recurseButtons((function(e){e&&=(e.onpointerdown=null,e.onpointerup=null,e.onpointercancel=null,e.ontouchstart=null,e.ontouchend=null,e.ontouchcancel=null,e.onclick=null,e.onmousedown=null,e.onmouseup=null,e.remove(),null)})),this.keyboardDOM.onpointerdown=null,this.keyboardDOM.ontouchstart=null,this.keyboardDOM.onmousedown=null,this.resetRows(),this.candidateBox&&=(this.candidateBox.destroy(),null),this.activeInputElement=null,this.keyboardDOM.removeAttribute(`data-skInstance`),this.keyboardDOM.innerHTML=``,window.SimpleKeyboardInstances[this.currentInstanceName]=null,delete window.SimpleKeyboardInstances[this.currentInstanceName],this.initialized=!1}},{key:`getButtonThemeClasses`,value:function(e){var t=this.options.buttonTheme,n=[];return Array.isArray(t)&&t.forEach((function(t){if(t&&t.class&&typeof t.class==`string`&&t.buttons&&typeof t.buttons==`string`){var r=t.class.split(` `);t.buttons.split(` `).includes(e)&&(n=[].concat(C(n),C(r)))}else console.warn(`Incorrect "buttonTheme". Please check the documentation.`,t)})),n}},{key:`setDOMButtonAttributes`,value:function(e,t){var n=this.options.buttonAttributes;Array.isArray(n)&&n.forEach((function(n){n.attribute&&typeof n.attribute==`string`&&n.value&&typeof n.value==`string`?n.buttons&&typeof n.buttons==`string`?n.buttons.split(` `).includes(e)&&t(n.attribute,n.value):t(n.attribute,n.value):console.warn(`Incorrect "buttonAttributes". Please check the documentation.`,n)}))}},{key:`onTouchDeviceDetected`,value:function(){this.processAutoTouchEvents(),this.disableContextualWindow()}},{key:`disableContextualWindow`,value:function(){window.oncontextmenu=function(e){var t;if((t=e.target.classList)!=null&&t.contains(`hg-button`))return e.preventDefault(),e.stopPropagation(),!1}}},{key:`processAutoTouchEvents`,value:function(){this.options.autoUseTouchEvents&&(this.options.useTouchEvents=!0,this.options.debug&&console.log(`autoUseTouchEvents: Touch device detected, useTouchEvents enabled.`))}},{key:`onInit`,value:function(){this.options.debug&&console.log(`${this.keyboardDOMClass} Initialized`),this.setEventListeners(),typeof this.options.onInit==`function`&&this.options.onInit(this)}},{key:`beforeFirstRender`,value:function(){this.utilities.isTouchDevice()&&this.onTouchDeviceDetected(),typeof this.options.beforeFirstRender==`function`&&this.options.beforeFirstRender(this),this.isFirstKeyboardInstance&&this.utilities.pointerEventsSupported()&&!this.options.useTouchEvents&&!this.options.useMouseEvents&&this.options.debug&&console.log(`Using PointerEvents as it is supported by this browser`),this.options.useTouchEvents&&this.options.debug&&console.log(`useTouchEvents has been enabled. Only touch events will be used.`)}},{key:`beforeRender`,value:function(){typeof this.options.beforeRender==`function`&&this.options.beforeRender(this)}},{key:`onRender`,value:function(){typeof this.options.onRender==`function`&&this.options.onRender(this)}},{key:`onModulesLoaded`,value:function(){typeof this.options.onModulesLoaded==`function`&&this.options.onModulesLoaded(this)}},{key:`loadModules`,value:function(){var e=this;Array.isArray(this.options.modules)&&(this.options.modules.forEach((function(t){var n=e.utilities.isConstructor(t)?new t(e):t(e);n.init&&n.init(e)})),this.keyboardPluginClasses=`modules-loaded`,this.render(),this.onModulesLoaded())}},{key:`getModuleProp`,value:function(e,t){return!!this.modules[e]&&this.modules[e][t]}},{key:`getModulesList`,value:function(){return Object.keys(this.modules)}},{key:`parseRowDOMContainers`,value:function(e,t,n,r){var i=this,a=Array.from(e.children),o=0;return a.length&&n.forEach((function(n,s){var c=r[s];if(!(c&&c>n))return!1;var l=n-o,u=c-o,d=document.createElement(`div`);d.className+=`hg-button-container`;var f=`${i.options.layoutName}-r${t}c${s}`;d.setAttribute(`data-skUID`,f);var p=a.splice(l,u-l+1);o+=u-l,p.forEach((function(e){return d.appendChild(e)})),a.splice(l,0,d),e.innerHTML=``,a.forEach((function(t){return e.appendChild(t)})),i.options.debug&&console.log(`rowDOMContainer`,p,l,u,o+1)})),e}},{key:`render`,value:function(){var e=this;this.resetRows(),this.initialized||this.beforeFirstRender(),this.beforeRender();var t=`hg-layout-${this.options.layoutName}`,n=this.options.layout||{default:["` 1 2 3 4 5 6 7 8 9 0 - = {bksp}",`{tab} q w e r t y u i o p [ ] \\`,`{lock} a s d f g h j k l ; ' {enter}`,`{shift} z x c v b n m , . / {shift}`,`.com @ {space}`],shift:[`~ ! @ # $ % ^ & * ( ) _ + {bksp}`,`{tab} Q W E R T Y U I O P { } |`,`{lock} A S D F G H J K L : " {enter}`,`{shift} Z X C V B N M < > ? {shift}`,`.com @ {space}`]},r=this.options.useTouchEvents||!1,i=r?`hg-touch-events`:``,a=this.options.useMouseEvents||!1,o=this.options.disableRowButtonContainers;this.keyboardDOM.className=this.getKeyboardClassString(this.options.theme,t,this.keyboardPluginClasses,i),this.keyboardDOM.setAttribute(`data-skInstance`,this.currentInstanceName),this.keyboardRowsDOM=document.createElement(`div`),this.keyboardRowsDOM.className=`hg-rows`,n[this.options.layoutName||this.defaultName].forEach((function(t,n){var i=t.split(` `);e.options.excludeFromLayout&&e.options.excludeFromLayout[e.options.layoutName||e.defaultName]&&(i=i.filter((function(t){return e.options.excludeFromLayout&&!e.options.excludeFromLayout[e.options.layoutName||e.defaultName].includes(t)})));var s=document.createElement(`div`);s.className+=`hg-row`;var c=[],l=[];i.forEach((function(t,i){var u,d=!o&&typeof t==`string`&&t.length>1&&t.indexOf(`[`)===0,f=!o&&typeof t==`string`&&t.length>1&&t.indexOf(`]`)===t.length-1;d&&(c.push(i),t=t.replace(/\[/g,``)),f&&(l.push(i),t=t.replace(/\]/g,``));var p=e.utilities.getButtonClass(t),m=e.utilities.getButtonDisplayName(t,e.options.display,e.options.mergeDisplay),h=e.options.useButtonTag?`button`:`div`,g=document.createElement(h);g.className+=`hg-button ${p}`,(u=g.classList).add.apply(u,C(e.getButtonThemeClasses(t))),e.setDOMButtonAttributes(t,(function(e,t){g.setAttribute(e,t)})),e.activeButtonClass=`hg-activeButton`,!e.utilities.pointerEventsSupported()||r||a?r?(g.ontouchstart=function(n){e.handleButtonClicked(t,n),e.handleButtonMouseDown(t,n)},g.ontouchend=function(n){e.handleButtonMouseUp(t,n)},g.ontouchcancel=function(n){e.handleButtonMouseUp(t,n)}):(g.onclick=function(n){e.setMouseHold(!1),typeof e.options.onKeyReleased==`function`||e.options.useMouseEvents&&e.options.clickOnMouseDown||e.handleButtonClicked(t,n)},g.onmousedown=function(n){(typeof e.options.onKeyReleased==`function`||e.options.useMouseEvents&&e.options.clickOnMouseDown)&&!e.isMouseHold&&e.handleButtonClicked(t,n),e.handleButtonMouseDown(t,n)},g.onmouseup=function(n){e.handleButtonMouseUp(t,n)}):(g.onpointerdown=function(n){e.handleButtonClicked(t,n),e.handleButtonMouseDown(t,n)},g.onpointerup=function(n){e.handleButtonMouseUp(t,n)},g.onpointercancel=function(n){e.handleButtonMouseUp(t,n)}),g.setAttribute(`data-skBtn`,t);var _=`${e.options.layoutName}-r${n}b${i}`;g.setAttribute(`data-skBtnUID`,_);var v=document.createElement(`span`);v.innerHTML=m,g.appendChild(v),e.buttonElements[t]||(e.buttonElements[t]=[]),e.buttonElements[t].push(g),s.appendChild(g)})),s=e.parseRowDOMContainers(s,n,c,l),e.keyboardRowsDOM.appendChild(s)})),this.keyboardDOM.appendChild(this.keyboardRowsDOM),this.onRender(),this.initialized||(this.initialized=!0,!this.utilities.pointerEventsSupported()||r||a?r?(document.ontouchend=function(t){return e.handleButtonMouseUp(void 0,t)},document.ontouchcancel=function(t){return e.handleButtonMouseUp(void 0,t)},this.keyboardDOM.ontouchstart=function(t){return e.handleKeyboardContainerMouseDown(t)}):r||(document.onmouseup=function(t){return e.handleButtonMouseUp(void 0,t)},this.keyboardDOM.onmousedown=function(t){return e.handleKeyboardContainerMouseDown(t)}):(document.onpointerup=function(t){return e.handleButtonMouseUp(void 0,t)},this.keyboardDOM.onpointerdown=function(t){return e.handleKeyboardContainerMouseDown(t)}),this.onInit())}}],t&&D(e.prototype,t),n&&D(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e;var e,t,n}(),j=A;return r}()},442:function(t){t.exports=e}},n={};function r(e){var i=n[e];if(i!==void 0)return i.exports;var a=n[e]={exports:{}};return t[e].call(a.exports,a,a.exports,r),a.exports}r.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return r.d(t,{a:t}),t},r.d=function(e,t){for(var n in t)r.o(t,n)&&!r.o(e,n)&&Object.defineProperty(e,n,{enumerable:!0,get:t[n]})},r.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},r.r=function(e){typeof Symbol<`u`&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:`Module`}),Object.defineProperty(e,"__esModule",{value:!0})};var i={};return function(){r.r(i),r.d(i,{KeyboardReact:function(){return u},default:function(){return d}}),r(981);var e=r(442),t=r(548),n=r.n(t);function a(e){return a=typeof Symbol==`function`&&typeof Symbol.iterator==`symbol`?function(e){return typeof e}:function(e){return e&&typeof Symbol==`function`&&e.constructor===Symbol&&e!==Symbol.prototype?`symbol`:typeof e},a(e)}function o(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function s(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]==null?{}:arguments[t];t%2?o(Object(n),!0).forEach((function(t){c(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):o(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function c(e,t,n){return(t=function(e){var t=function(e,t){if(a(e)!=`object`||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||`default`);if(a(r)!=`object`)return r;throw TypeError(`@@toPrimitive must return a primitive value.`)}return(t===`string`?String:Number)(e)}(e,`string`);return a(t)==`symbol`?t:t+``}(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var l=function(e){return s(s({},e),{},{keyboardRef:null})},u=function(t){var r=t.baseClass||`react-simple-keyboard`,i=e.useRef(null),a=e.useRef(null),o=e.useRef(null),c=e.useRef(t);return e.useEffect((function(){return function(){o.current&&o.current.destroy(),i.current=!1}}),[]),e.useEffect((function(){var e=function(e){return s(s({},e),{},{theme:`simple-keyboard ${e.theme||`hg-theme-default`}`})}(t);if(!i.current){i.current=!0,e.debug&&console.log(`ReactSimpleKeyboard: Init`);var u=a.current,d=`.${r}`;o.current=new(n())(u||d,e),e.keyboardRef&&e.keyboardRef(o.current)}var f=function(e,t){var n=l(t),r=l(e);return Object.keys(n).filter((function(e){return n[e]!==r[e]}))}(c.current,e);if(f.length){var p=o.current;c.current=e,p?.setOptions(e),e.debug&&console.log(`ReactSimpleKeyboard - setOptions called due to updated props:`,f)}}),[i,r,c,t]),e.createElement(`div`,{className:r,ref:a})},d=u}(),i}()}))}))(),1);function Yd(e,t=[]){if(Xd(e))return e;if(typeof e==`object`&&e){let n=e;if(Xd(n.default))return n.default;for(let e of t)if(Xd(n[e]))return n[e]}return e}function Xd(e){return typeof e==`function`||typeof e==`string`?!0:typeof e==`object`&&!!e&&`$$typeof`in e}var Zd=Yd(Jd.default,[`KeyboardReact`]),Qd=new Set([`text`,`password`,`email`,`search`,`url`,`number`]);function $d(e,t){(Object.getOwnPropertyDescriptor(HTMLInputElement.prototype,`value`)?.set??Object.getOwnPropertyDescriptor(HTMLTextAreaElement.prototype,`value`)?.set)?.call(e,t),e.dispatchEvent(new Event(`input`,{bubbles:!0}))}function ef({onVisibilityChange:e}){let[t,n]=(0,W.useState)(!1),[r,i]=(0,W.useState)(!1),a=(0,W.useRef)(!1),[o,s]=(0,W.useState)(`default`),c=(0,W.useRef)(null),l=(0,W.useRef)(null),u=(0,W.useRef)(null);(0,W.useEffect)(()=>{e?.(t)},[t,e]);let d=(0,W.useCallback)(e=>{if(a.current)return;let t=e.target;if(!t.closest(`[data-vkb="false"]`)){if(t instanceof HTMLInputElement){if(!Qd.has(t.type))return}else if(!(t instanceof HTMLTextAreaElement))return;c.current=t,n(!0),s(`default`),l.current?.setInput?.(c.current.value),setTimeout(()=>{(t.closest(`.bg-zinc-800, .rounded-lg, [data-vkb-group]`)??t).scrollIntoView({behavior:`smooth`,block:`nearest`})},100)}},[]),f=(0,W.useCallback)(()=>{setTimeout(()=>{let e=document.activeElement;e&&(u.current?.contains(e)||e===c.current)||(n(!1),c.current=null)},150)},[]);(0,W.useEffect)(()=>(document.addEventListener(`focusin`,d),document.addEventListener(`focusout`,f),()=>{document.removeEventListener(`focusin`,d),document.removeEventListener(`focusout`,f)}),[d,f]);let p=(0,W.useCallback)(()=>{a.current=!0,i(!0),c.current?.blur(),c.current=null,setTimeout(()=>{n(!1),i(!1),a.current=!1},400)},[]),m=(0,W.useCallback)(e=>{let t=c.current;if(t){if(e===`{shift}`){s(e=>e==="default"?`shift`:`default`);return}if(e===`{lock}`){s(e=>e==="default"?`shift`:`default`);return}if(e===`{close}`){p();return}e===`{bksp}`?$d(t,t.value.slice(0,-1)):e===`{space}`?$d(t,t.value+` `):($d(t,t.value+e),o===`shift`&&s(`default`)),t.focus(),l.current?.setInput?.(t.value)}},[o,p]);return t?(0,Z.jsxs)(Z.Fragment,{children:[(0,Z.jsx)(`div`,{className:`fixed inset-0 z-[9998] bg-transparent`,onMouseDown:e=>{e.preventDefault(),e.stopPropagation(),r||p()},onTouchStart:e=>{e.preventDefault(),e.stopPropagation(),r||p()},onClick:e=>{e.preventDefault(),e.stopPropagation()}}),!r&&(0,Z.jsx)(`div`,{ref:u,className:`relative z-[9999] shrink-0`,onMouseDown:e=>e.preventDefault(),onTouchStart:e=>{e.target.closest(`.hg-button`)||e.preventDefault()},children:(0,Z.jsx)(Zd,{keyboardRef:e=>{l.current=e},layoutName:o,onKeyPress:m,theme:`simple-keyboard vkb-theme`,layout:{default:[`1 2 3 4 5 6 7 8 9 0 {bksp}`,`q w e r t y u i o p`,`{lock} a s d f g h j k l`,`{shift} z x c v b n m . @`,`{space} {close}`],shift:[`! @ # $ % ^ & * ( ) {bksp}`,`Q W E R T Y U I O P`,`{lock} A S D F G H J K L`,`{shift} Z X C V B N M , _`,`{space} {close}`]},display:{"{bksp}":`⌫`,"{close}":`✕ Close`,"{shift}":`⇧`,"{lock}":`⇪`,"{space}":` `}})})]}):null}function tf(){dc();let[e,t]=(0,W.useState)(null),[n,r]=(0,W.useState)(null),[i,a]=(0,W.useState)(100),{i18n:s}=v(),c=Xr(),l=qr(),u=qd(),{setViewportSuppressed:d}=fe();(0,W.useEffect)(()=>(d(!0),()=>d(!1)),[d]);let{data:f}=z({queryKey:[`settings`],queryFn:o.getSettings});(0,W.useEffect)(()=>{f?.language&&f.language!==s.language&&s.changeLanguage(f.language)},[f?.language,s]);let{data:p=[]}=z({queryKey:[`spoolbuddy-devices`],queryFn:()=>_.getDevices(),refetchInterval:3e4}),m=p[0],h=u.deviceOnline||!!m?.online,g=(0,W.useMemo)(()=>({...u,deviceOnline:h}),[u,h]),y=(0,W.useRef)(!1);(0,W.useEffect)(()=>{m&&!y.current&&(a(m.display_brightness),y.current=!0)},[m]),(0,W.useEffect)(()=>{let e=document.documentElement,t=e.classList.contains(`dark`);return e.classList.add(`dark`),()=>{t||e.classList.remove(`dark`)}},[]);let{data:b}=z({queryKey:[`spoolbuddy-update-check`,m?.device_id],queryFn:()=>m?_.checkDaemonUpdate(m.device_id):Promise.resolve(null),enabled:!!m,refetchInterval:300*1e3,staleTime:0}),x=(0,W.useRef)(null);(0,W.useEffect)(()=>{if(!h){let e=`SpoolBuddy device disconnected`;r({type:`warning`,message:e}),x.current=e}else if(b?.update_available&&b.latest_version){let e=`Update available: v${b.latest_version}`;r({type:`info`,message:e}),x.current=e}else x.current&&=(r(null),null)},[h,b?.update_available,b?.latest_version]);let S=!!(u.matchedSpool||u.unknownTagUid||u.unknownTrayUuid),C=(0,W.useRef)(!1);(0,W.useEffect)(()=>{S&&!C.current&&l.pathname!==`/spoolbuddy`&&c(`/spoolbuddy`),C.current=S},[S,l.pathname,c]);let{data:w=[]}=z({queryKey:[`printers`],queryFn:()=>o.getPrinters()}),T=B({queries:w.map(e=>({queryKey:[`printerStatus`,e.id],queryFn:()=>o.getPrinterStatus(e.id),refetchInterval:1e4,select:e=>({connected:e?.connected})}))}),E=(0,W.useMemo)(()=>w.filter((e,t)=>T[t]?.data?.connected),[w,T]),D=(0,W.useRef)(null),O=(0,W.useRef)(!1),k=(0,W.useRef)(null),A=(0,W.useCallback)(e=>{D.current={x:e.touches[0].clientX,y:e.touches[0].clientY},O.current=!1},[]),j=(0,W.useCallback)(n=>{if(!D.current)return;let r=n.changedTouches[0].clientX-D.current.x,i=n.changedTouches[0].clientY-D.current.y,a=D.current.y;if(D.current=null,O.current=!1,i>=50&&Math.abs(i)>Math.abs(r)&&a<120){F(!0);return}if(E.length<2||Math.abs(r)<50||Math.abs(i)>Math.abs(r))return;let o=E.findIndex(t=>t.id===e);t(E[r<0?(o+1)%E.length:(o-1+E.length)%E.length].id)},[E,e,t]);(0,W.useEffect)(()=>{let e=k.current;if(!e)return;let t=e=>{if(!D.current)return;let t=Math.abs(e.touches[0].clientX-D.current.x),n=Math.abs(e.touches[0].clientY-D.current.y);if(O.current){e.preventDefault();return}t>10&&t>n&&(O.current=!0,e.preventDefault())};return e.addEventListener(`touchmove`,t,{passive:!1}),()=>e.removeEventListener(`touchmove`,t)},[]);let[M,N]=(0,W.useState)(!1),[P,F]=(0,W.useState)(!1);return(0,Z.jsxs)(Z.Fragment,{children:[(0,Z.jsxs)(`div`,{ref:k,"data-spoolbuddy-kiosk":!0,className:`w-screen h-screen bg-bambu-dark text-white flex flex-col overflow-hidden`,style:{...i<100?{filter:`brightness(${i/100})`}:void 0,overscrollBehaviorX:`none`},onTouchStart:A,onTouchEnd:j,children:[(0,Z.jsx)(`button`,{onClick:()=>F(!0),className:`w-full h-1.5 bg-bambu-dark-secondary flex justify-center items-center shrink-0 touch-none`,"aria-label":`Open quick menu`,children:(0,Z.jsx)(`div`,{className:`w-8 h-0.5 rounded-full bg-zinc-600`})}),(0,Z.jsx)(zd,{selectedPrinterId:e,onPrinterChange:t,deviceOnline:h}),(0,Z.jsx)(`main`,{className:`flex-1 overflow-y-auto`,children:(0,Z.jsx)(W.Suspense,{fallback:(0,Z.jsx)(Ts,{}),children:(0,Z.jsx)(J,{context:{selectedPrinterId:e,setSelectedPrinterId:t,sbState:g,setAlert:r,displayBrightness:i,setDisplayBrightness:a}})})}),!M&&(0,Z.jsx)(Hd,{alert:n}),!M&&(0,Z.jsx)(Vd,{}),(0,Z.jsx)(ef,{onVisibilityChange:N})]}),(0,Z.jsx)(Ud,{isOpen:P,onClose:()=>F(!1),deviceId:m?.device_id??null,deviceOnline:h})]})}var nf=K(()=>q(()=>import(`./PrintersPage-zDUFDj5q.js`),__vite__mapDeps([0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71])),`PrintersPage`),rf=K(()=>q(()=>import(`./ArchivesPage-MaOGuDlA.js`),__vite__mapDeps([72,1,7,4,8,9,73,3,74,58,5,6,75,30,33,35,36,12,76,13,14,15,16,77,78,79,37,38,40,80,17,18,42,43,23,81,82,83,61,66,84,46,54,55,85,56,86,87,88,26,21,67,89,39,44,90,91])),`ArchivesPage`),af=K(()=>q(()=>import(`./QueuePage-DTh2aCRG.js`),__vite__mapDeps([92,1,93,3,4,5,7,8,60,9,27,31,35,36,12,13,14,15,16,78,43,44,74,54,55,56,87,94,26,95,21,67,61,71])),`QueuePage`),of=K(()=>q(()=>import(`./StatsPage-D0cqrND3.js`),__vite__mapDeps([96,1,93,3,4,5,2,6,9,7,10,35,12,13,14,15,16,97,39,80,44,48,49,54,98,26,99,21,61])),`StatsPage`),sf=K(()=>q(()=>import(`./SettingsPage-DOroBYzD.js`),__vite__mapDeps([100,1,7,4,8,60,9,3,22,23,24,25,26,101,35,36,12,13,14,15,16,77,37,102,97,39,44,45,84,46,103,104,21,52,54,56,86,105,18,57,106,87,107,95,67,108,68,69,61])),`SettingsPage`),cf=K(()=>q(()=>import(`./FinancePage-BfhaugR1.js`),__vite__mapDeps([109,1,7,4,8,9,3,76,13,12,14,15,16,21,67,61])),`FinancePage`),lf=K(()=>q(()=>import(`./ProfilesPage-C0jHVdln.js`),__vite__mapDeps([110,1,7,4,8,9,3,29,31,36,12,13,14,15,16,37,111,39,43,23,81,45,74,47,51,18,57,112,88,26,21,67,63,64,61])),`ProfilesPage`),uf=K(()=>q(()=>import(`./MaintenancePage-BAMWk5DI.js`),__vite__mapDeps([113,1,7,4,8,9,3,33,34,35,36,12,13,14,15,16,77,111,43,85,112,98,25,94,26,21,67,68])),`MaintenancePage`),df=K(()=>q(()=>import(`./ProjectsPage-C2aXY-5x.js`),__vite__mapDeps([114,1,7,4,8,9,3,12,13,14,15,16,38,54,85,26,5,21])),`ProjectsPage`),ff=K(()=>q(()=>import(`./ProjectDetailPage-CaZEFrXK.js`),__vite__mapDeps([115,1,7,4,8,9,73,3,74,58,5,6,75,28,35,12,13,14,15,16,37,40,114,38,54,85,26,21,84,67,61,116,91])),`ProjectDetailPage`),pf=K(()=>q(()=>import(`./FileManagerPage-Kp8jeXP4.js`),__vite__mapDeps([117,1,7,4,8,60,9,11,12,3,13,14,15,16,17,18,19,20,21,33,101,36,77,79,38,40,80,43,82,83,61,66,45,46,103,74,24,56,88,26,58,90,118,48,49,116,91])),`FileManagerPage`),mf=K(()=>q(()=>import(`./LibraryTrashPage-Ck7R9blU.js`),__vite__mapDeps([119,1,7,4,8,9,28,3,13,12,14,15,16,21,61])),`LibraryTrashPage`),hf=K(()=>q(()=>import(`./CameraPage-C1mWeQfG.js`),__vite__mapDeps([120,1,7,4,8,9,3,13,12,14,15,16,50,33,48,26,19])),`CameraPage`),gf=K(()=>q(()=>import(`./CamWallPage-C1rIEzhG.js`),__vite__mapDeps([121,1,9,7,4,59,8,60,3,12,13,14,15,16,26,61])),`CamWallPage`),_f=K(()=>q(()=>import(`./StreamOverlayPage-DWOhiuT-.js`),__vite__mapDeps([122,1,7,4,9,33,3,94,108,61,70,123])),`StreamOverlayPage`),vf=K(()=>q(()=>import(`./ExternalLinkPage-CM4__1rh.js`),__vite__mapDeps([124,1,9,7,4,14,3,26])),`ExternalLinkPage`),yf=K(()=>q(()=>import(`./GroupEditPage-i9TLWDyl.js`),__vite__mapDeps([125,1,7,4,8,9,28,3,36,13,12,14,15,16,51,18,106,26,21,67])),`GroupEditPage`),bf=K(()=>q(()=>import(`./PrinterLocationsPage-D2AqeJ9i.js`),__vite__mapDeps([126,1,7,4,8,60,9,3,28,33,12,13,14,15,16,53,18,21,67])),`PrinterLocationsPage`),xf=K(()=>q(()=>import(`./InventoryPage-BWTPGneX.js`),__vite__mapDeps([127,1,2,3,4,5,6,7,8,60,9,22,23,24,25,26,27,30,31,32,36,12,76,13,14,15,16,79,37,46,103,104,21,54,18,112,58,99,89,39,44,67,69,128,83,105,63,129,130,131,61,65,66])),`default`),Sf=K(()=>q(()=>import(`./ModelSourcesPage-C9OvAi9p.js`),__vite__mapDeps([132,1,7,4,8,9,75,3,28,29,33,36,12,13,14,15,16,77,82,83,18,61,66,21,67,116,91])),`ModelSourcesPage`),Cf=K(()=>q(()=>import(`./SystemInfoPage-ClAReSss.js`),__vite__mapDeps([133,1,7,4,8,9,3,12,102,45,14,56,18,26,15,67,61])),`SystemInfoPage`),wf=K(()=>q(()=>import(`./LoginPage-CXIN3BLj.js`),__vite__mapDeps([134,1,8,7,4,9,13,3,12,14,15,16,106,107,21,67])),`LoginPage`),Tf=K(()=>q(()=>import(`./ConnectAuthorizePage-DtVlpfFV.js`),__vite__mapDeps([135,1,103,3,4,14,26])),`ConnectAuthorizePage`),Ef=K(()=>q(()=>import(`./SetupPage-hUHebIlA.js`),__vite__mapDeps([136,1,8,7,4,12,3,13,14,15,16])),`SetupPage`),Df=K(()=>q(()=>import(`./NotificationsPage-5GOJDRkw.js`),__vite__mapDeps([137,1,7,4,8,9,13,3,12,14,15,16,21,67])),`NotificationsPage`),Of=K(()=>q(()=>import(`./GCodeViewerPage-C24Va31U.js`),__vite__mapDeps([138,1,9,7,4,28,3,41,14,20])),`GCodeViewerPage`),kf=K(()=>q(()=>import(`./SpoolBuddyDashboard-B_0MmvgI.js`),__vite__mapDeps([139,1,7,4,8,60,9,36,3,13,12,14,15,16,26,58,129,130,131,69,140])),`SpoolBuddyDashboard`),Af=K(()=>q(()=>import(`./SpoolBuddyAmsPage-CCeWMoIm.js`),__vite__mapDeps([141,1,7,4,8,9,13,3,12,14,15,16,103,54,57,58,62,18,21,63,64,65,66,130,131,69,70])),`SpoolBuddyAmsPage`),jf=K(()=>q(()=>import(`./SpoolBuddySettingsPage-DKia6Rid.js`),__vite__mapDeps([142,1,7,4,9,56,3,15,61])),`SpoolBuddySettingsPage`),Mf=K(()=>q(()=>import(`./SpoolBuddyCalibrationPage-BPEaykbd.js`),__vite__mapDeps([143,1,9,7,4])),`SpoolBuddyCalibrationPage`),Nf=K(()=>q(()=>import(`./SpoolBuddyWriteTagPage-CMlhWgSL.js`),__vite__mapDeps([144,1,9,7,4,12,3,13,14,15,16,112,128,83,105,18,69,63,131])),`SpoolBuddyWriteTagPage`),Pf=K(()=>q(()=>import(`./SpoolBuddyInventoryPage-BmxJPbmk.js`),__vite__mapDeps([145,1,7,4,8,9,36,3,13,12,14,15,16,54,18,26,58,129,130,131,69,140,65])),`SpoolBuddyInventoryPage`),Ff=class extends W.Component{state={error:null,errorInfo:null};static getDerivedStateFromError(e){return{error:e}}componentDidCatch(e,t){this.setState({errorInfo:t}),console.error(`React crash:`,e,t)}render(){return this.state.error?(0,Z.jsxs)(`div`,{style:{padding:24,color:`#ef4444`,backgroundColor:`#18181b`,minHeight:`100vh`,fontFamily:`monospace`},children:[(0,Z.jsx)(`h1`,{style:{fontSize:20,marginBottom:12},children:`UI Crash`}),(0,Z.jsx)(`pre`,{style:{whiteSpace:`pre-wrap`,fontSize:14},children:this.state.error.message}),(0,Z.jsx)(`pre`,{style:{whiteSpace:`pre-wrap`,fontSize:12,color:`#a1a1aa`,marginTop:12},children:this.state.error.stack}),(0,Z.jsx)(`button`,{onClick:()=>{this.setState({error:null,errorInfo:null})},style:{marginTop:16,padding:`8px 16px`,backgroundColor:`#3b82f6`,color:`#fff`,border:`none`,borderRadius:8,cursor:`pointer`},children:`Retry`})]}):this.props.children}},If=new Ua({defaultOptions:{queries:{staleTime:1e3*60,retry:1}}});function Lf(){return Od(),null}function Rf({children:e}){return yd(),Td(),(0,Z.jsx)(Z.Fragment,{children:e})}function zf({children:e}){let{authEnabled:t,loading:n,user:r}=Os(),i=qr();return n?(0,Z.jsx)(`div`,{className:`min-h-screen flex items-center justify-center`,children:`Loading...`}):t&&!r?(0,Z.jsx)(Ti,{to:`/login`,replace:!0,state:{from:i}}):(0,Z.jsx)(Z.Fragment,{children:e})}function Bf({permission:e,children:t}){let{authEnabled:n,loading:r,user:i,hasPermission:a}=Os(),o=qr();return r?(0,Z.jsx)(`div`,{className:`min-h-screen flex items-center justify-center`,children:`Loading...`}):n?i?(Array.isArray(e)?e:[e]).some(e=>a(e))?(0,Z.jsx)(Z.Fragment,{children:t}):(0,Z.jsx)(Ti,{to:`/`,replace:!0}):(0,Z.jsx)(Ti,{to:`/login`,replace:!0,state:{from:o}}):(0,Z.jsx)(Z.Fragment,{children:t})}function Vf({children:e}){let{authEnabled:t,loading:n}=Os();return n?(0,Z.jsx)(`div`,{className:`min-h-screen flex items-center justify-center`,children:`Loading...`}):t?(0,Z.jsx)(Ti,{to:`/login`,replace:!0}):(0,Z.jsx)(Z.Fragment,{children:e})}function Hf(){return(0,Z.jsx)(Ff,{children:(0,Z.jsx)(me,{children:(0,Z.jsx)(te,{client:If,children:(0,Z.jsx)(Ds,{children:(0,Z.jsx)(As,{children:(0,Z.jsx)(Rd,{children:(0,Z.jsxs)(Id,{children:[(0,Z.jsx)(Lf,{}),(0,Z.jsx)(ga,{children:(0,Z.jsx)(W.Suspense,{fallback:(0,Z.jsx)(Ts,{fullScreen:!0}),children:(0,Z.jsxs)(Di,{children:[(0,Z.jsx)(Y,{path:`/setup`,element:(0,Z.jsx)(Vf,{children:(0,Z.jsx)(Ef,{})})}),(0,Z.jsx)(Y,{path:`/login`,element:(0,Z.jsx)(wf,{})}),(0,Z.jsx)(Y,{path:`/connect/authorize`,element:(0,Z.jsx)(zf,{children:(0,Z.jsx)(Tf,{})})}),(0,Z.jsx)(Y,{path:`/camera/:printerId`,element:(0,Z.jsx)(hf,{})}),(0,Z.jsx)(Y,{path:`/overlay/:printerId`,element:(0,Z.jsx)(_f,{})}),(0,Z.jsx)(Y,{path:`/camwall`,element:(0,Z.jsx)(gf,{})}),(0,Z.jsxs)(Y,{element:(0,Z.jsx)(zf,{children:(0,Z.jsx)(Rf,{children:(0,Z.jsx)(tf,{})})}),children:[(0,Z.jsx)(Y,{path:`spoolbuddy`,element:(0,Z.jsx)(kf,{})}),(0,Z.jsx)(Y,{path:`spoolbuddy/ams`,element:(0,Z.jsx)(Af,{})}),(0,Z.jsx)(Y,{path:`spoolbuddy/write-tag`,element:(0,Z.jsx)(Nf,{})}),(0,Z.jsx)(Y,{path:`spoolbuddy/inventory`,element:(0,Z.jsx)(Pf,{})}),(0,Z.jsx)(Y,{path:`spoolbuddy/settings`,element:(0,Z.jsx)(jf,{})}),(0,Z.jsx)(Y,{path:`spoolbuddy/calibration`,element:(0,Z.jsx)(Mf,{})})]}),(0,Z.jsxs)(Y,{element:(0,Z.jsx)(zf,{children:(0,Z.jsx)(Rf,{children:(0,Z.jsx)(pd,{})})}),children:[(0,Z.jsx)(Y,{index:!0,element:(0,Z.jsx)(nf,{})}),(0,Z.jsx)(Y,{path:`archives`,element:(0,Z.jsx)(rf,{})}),(0,Z.jsx)(Y,{path:`queue`,element:(0,Z.jsx)(af,{})}),(0,Z.jsx)(Y,{path:`pipelines/runs`,element:(0,Z.jsx)(Ti,{to:`/queue?tab=pipelines`,replace:!0})}),(0,Z.jsx)(Y,{path:`stats`,element:(0,Z.jsx)(of,{})}),(0,Z.jsx)(Y,{path:`profiles`,element:(0,Z.jsx)(lf,{})}),(0,Z.jsx)(Y,{path:`finance`,element:(0,Z.jsx)(Bf,{permission:`cost_centers:read_own`,children:(0,Z.jsx)(cf,{})})}),(0,Z.jsx)(Y,{path:`maintenance`,element:(0,Z.jsx)(uf,{})}),(0,Z.jsx)(Y,{path:`projects`,element:(0,Z.jsx)(df,{})}),(0,Z.jsx)(Y,{path:`projects/:id`,element:(0,Z.jsx)(ff,{})}),(0,Z.jsx)(Y,{path:`inventory`,element:(0,Z.jsx)(xf,{})}),(0,Z.jsx)(Y,{path:`files`,element:(0,Z.jsx)(pf,{})}),(0,Z.jsx)(Y,{path:`files/trash`,element:(0,Z.jsx)(mf,{})}),(0,Z.jsx)(Y,{path:`model-sources`,element:(0,Z.jsx)(Bf,{permission:[`makerworld:view`,`manyfold:view`],children:(0,Z.jsx)(Sf,{})})}),(0,Z.jsx)(Y,{path:`makerworld`,element:(0,Z.jsx)(Ti,{to:`/model-sources?tab=makerworld`,replace:!0})}),(0,Z.jsx)(Y,{path:`settings`,element:(0,Z.jsx)(Bf,{permission:`settings:read`,children:(0,Z.jsx)(sf,{})})}),(0,Z.jsx)(Y,{path:`groups/new`,element:(0,Z.jsx)(Bf,{permission:`groups:create`,children:(0,Z.jsx)(yf,{})})}),(0,Z.jsx)(Y,{path:`groups/:id/edit`,element:(0,Z.jsx)(Bf,{permission:`groups:update`,children:(0,Z.jsx)(yf,{})})}),(0,Z.jsx)(Y,{path:`printer-locations`,element:(0,Z.jsx)(Bf,{permission:`printers:read`,children:(0,Z.jsx)(bf,{})})}),(0,Z.jsx)(Y,{path:`users`,element:(0,Z.jsx)(Ti,{to:`/settings?tab=users`,replace:!0})}),(0,Z.jsx)(Y,{path:`groups`,element:(0,Z.jsx)(Ti,{to:`/settings?tab=users`,replace:!0})}),(0,Z.jsx)(Y,{path:`system`,element:(0,Z.jsx)(Cf,{})}),(0,Z.jsx)(Y,{path:`notifications`,element:(0,Z.jsx)(Df,{})}),(0,Z.jsx)(Y,{path:`gcode-viewer`,element:(0,Z.jsx)(Of,{})}),(0,Z.jsx)(Y,{path:`external/:id`,element:(0,Z.jsx)(vf,{})}),(0,Z.jsx)(Y,{path:`camera-tokens`,element:(0,Z.jsx)(Ti,{to:`/settings?tab=camera#card-camera-tokens`,replace:!0})})]})]})})})]})})})})})})})}var Uf=3e3;Promise.race([Sn,new Promise(e=>setTimeout(e,Uf))]).catch(()=>{}).then(()=>{(0,ze.createRoot)(document.getElementById(`root`)).render((0,Z.jsx)(W.StrictMode,{children:(0,Z.jsx)(Hf,{})}))});export{Dc as $,Vo as $t,El as A,eo as An,ms as At,Nc as B,qr as Bn,rs as Bt,mu as C,uo as Cn,xs as Ct,Il as D,ro as Dn,_s as Dt,Vl as E,io as En,vs as Et,_l as F,Ja as Fn,cs as Ft,qc as G,wn as Gn,Zo as Gt,Vc as H,$r as Hn,ts as Ht,gl as I,Ga as In,ss as It,Wc as J,qo as Jt,Uc as K,q as Kn,Xo as Kt,hl as L,Wa as Ln,os as Lt,xl as M,Za as Mn,fs as Mt,bl as N,Xa as Nn,ds as Nt,zl as O,X as On,gs as Ot,yl as P,Ya as Pn,us as Pt,wc as Q,Uo as Qt,fl as R,va as Rn,as as Rt,pu as S,fo as Sn,Ss as St,Wl as T,so as Tn,ys as Tt,Oc as U,ti as Un,$o as Ut,ol as V,Xr as Vn,ns as Vt,Bc as W,Ea as Wn,Qo as Wt,rl as X,Go as Xt,tl as Y,Ko as Yt,Cc as Z,Wo as Zt,ku as _,_o as _n,Is as _t,vd as a,Mo as an,pc as at,wu as b,mo as bn,ws as bt,ud as c,ko as cn,rc as ct,cd as d,To as dn,lc as dt,Bo as en,nl as et,od as f,wo as fn,ac as ft,Nu as g,yo as gn,Bs as gt,Pu as h,bo as hn,Vs as ht,_d as i,No as in,mc as it,wl as j,Qa as jn,ps as jt,Bl as k,to as kn,hs as kt,dd as l,Do as ln,cc as lt,sd as m,xo as mn,zs as mt,Od as n,Ro as nn,hc as nt,md as o,jo as on,dc as ot,ld as p,Co as pn,oc as pt,Hc as q,Jo as qt,hd as r,Lo as rn,gc as rt,gd as s,Ao as sn,nc as st,Ld as t,zo as tn,il as tt,fd as u,Eo as un,uc as ut,Du as v,go as vn,js as vt,ql as w,lo as wn,bs as wt,fu as x,po as xn,Cs as xt,Tu as y,ho as yn,Os as yt,Tc as z,Ti as zn,is as zt};
|