From e88d25f38fbdf58fda192fc6b39fd33f15045a7c Mon Sep 17 00:00:00 2001 From: Lea Anthony Date: Wed, 7 Jan 2026 23:52:13 +1100 Subject: [PATCH] feat(setup): add signing configuration forms with inline platform icons - Add Configure button for each platform that opens a form - Add configuration forms for macOS (identity, team ID, notarization profile) - Add configuration forms for Windows (certificate path, thumbprint, timestamp) - Add configuration forms for Linux (GPG key ID, key path) - Use inline SVGs for platform icons (same as CrossPlatformPage) - Forms save to defaults.yaml via /api/signing endpoint - Include helpful command hints for finding signing identities --- .../frontend/dist/assets/index-C4-hlb8q.css | 1 - .../frontend/dist/assets/index-Cxa-r7OW.js | 60 -- .../frontend/dist/assets/index-DgfT-RTI.js | 60 ++ .../frontend/dist/assets/index-Dq6tbWrr.css | 1 + .../setupwizard/frontend/dist/index.html | 4 +- .../frontend/src/components/SigningStep.tsx | 521 ++++++++++++------ 6 files changed, 419 insertions(+), 228 deletions(-) delete mode 100644 v3/internal/setupwizard/frontend/dist/assets/index-C4-hlb8q.css delete mode 100644 v3/internal/setupwizard/frontend/dist/assets/index-Cxa-r7OW.js create mode 100644 v3/internal/setupwizard/frontend/dist/assets/index-DgfT-RTI.js create mode 100644 v3/internal/setupwizard/frontend/dist/assets/index-Dq6tbWrr.css diff --git a/v3/internal/setupwizard/frontend/dist/assets/index-C4-hlb8q.css b/v3/internal/setupwizard/frontend/dist/assets/index-C4-hlb8q.css deleted file mode 100644 index 3eb9cd6bc..000000000 --- a/v3/internal/setupwizard/frontend/dist/assets/index-C4-hlb8q.css +++ /dev/null @@ -1 +0,0 @@ -*,:before,:after{--tw-border-spacing-x: 0;--tw-border-spacing-y: 0;--tw-translate-x: 0;--tw-translate-y: 0;--tw-rotate: 0;--tw-skew-x: 0;--tw-skew-y: 0;--tw-scale-x: 1;--tw-scale-y: 1;--tw-pan-x: ;--tw-pan-y: ;--tw-pinch-zoom: ;--tw-scroll-snap-strictness: proximity;--tw-gradient-from-position: ;--tw-gradient-via-position: ;--tw-gradient-to-position: ;--tw-ordinal: ;--tw-slashed-zero: ;--tw-numeric-figure: ;--tw-numeric-spacing: ;--tw-numeric-fraction: ;--tw-ring-inset: ;--tw-ring-offset-width: 0px;--tw-ring-offset-color: #fff;--tw-ring-color: rgb(59 130 246 / .5);--tw-ring-offset-shadow: 0 0 #0000;--tw-ring-shadow: 0 0 #0000;--tw-shadow: 0 0 #0000;--tw-shadow-colored: 0 0 #0000;--tw-blur: ;--tw-brightness: ;--tw-contrast: ;--tw-grayscale: ;--tw-hue-rotate: ;--tw-invert: ;--tw-saturate: ;--tw-sepia: ;--tw-drop-shadow: ;--tw-backdrop-blur: ;--tw-backdrop-brightness: ;--tw-backdrop-contrast: ;--tw-backdrop-grayscale: ;--tw-backdrop-hue-rotate: ;--tw-backdrop-invert: ;--tw-backdrop-opacity: ;--tw-backdrop-saturate: ;--tw-backdrop-sepia: ;--tw-contain-size: ;--tw-contain-layout: ;--tw-contain-paint: ;--tw-contain-style: }::backdrop{--tw-border-spacing-x: 0;--tw-border-spacing-y: 0;--tw-translate-x: 0;--tw-translate-y: 0;--tw-rotate: 0;--tw-skew-x: 0;--tw-skew-y: 0;--tw-scale-x: 1;--tw-scale-y: 1;--tw-pan-x: ;--tw-pan-y: ;--tw-pinch-zoom: ;--tw-scroll-snap-strictness: proximity;--tw-gradient-from-position: ;--tw-gradient-via-position: ;--tw-gradient-to-position: ;--tw-ordinal: ;--tw-slashed-zero: ;--tw-numeric-figure: ;--tw-numeric-spacing: ;--tw-numeric-fraction: ;--tw-ring-inset: ;--tw-ring-offset-width: 0px;--tw-ring-offset-color: #fff;--tw-ring-color: rgb(59 130 246 / .5);--tw-ring-offset-shadow: 0 0 #0000;--tw-ring-shadow: 0 0 #0000;--tw-shadow: 0 0 #0000;--tw-shadow-colored: 0 0 #0000;--tw-blur: ;--tw-brightness: ;--tw-contrast: ;--tw-grayscale: ;--tw-hue-rotate: ;--tw-invert: ;--tw-saturate: ;--tw-sepia: ;--tw-drop-shadow: ;--tw-backdrop-blur: ;--tw-backdrop-brightness: ;--tw-backdrop-contrast: ;--tw-backdrop-grayscale: ;--tw-backdrop-hue-rotate: ;--tw-backdrop-invert: ;--tw-backdrop-opacity: ;--tw-backdrop-saturate: ;--tw-backdrop-sepia: ;--tw-contain-size: ;--tw-contain-layout: ;--tw-contain-paint: ;--tw-contain-style: }*,:before,:after{box-sizing:border-box;border-width:0;border-style:solid;border-color:#e5e7eb}:before,:after{--tw-content: ""}html,:host{line-height:1.5;-webkit-text-size-adjust:100%;-moz-tab-size:4;-o-tab-size:4;tab-size:4;font-family:Inter,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen,Ubuntu,Cantarell,sans-serif;font-feature-settings:normal;font-variation-settings:normal;-webkit-tap-highlight-color:transparent}body{margin:0;line-height:inherit}hr{height:0;color:inherit;border-top-width:1px}abbr:where([title]){-webkit-text-decoration:underline dotted;text-decoration:underline dotted}h1,h2,h3,h4,h5,h6{font-size:inherit;font-weight:inherit}a{color:inherit;text-decoration:inherit}b,strong{font-weight:bolder}code,kbd,samp,pre{font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace;font-feature-settings:normal;font-variation-settings:normal;font-size:1em}small{font-size:80%}sub,sup{font-size:75%;line-height:0;position:relative;vertical-align:baseline}sub{bottom:-.25em}sup{top:-.5em}table{text-indent:0;border-color:inherit;border-collapse:collapse}button,input,optgroup,select,textarea{font-family:inherit;font-feature-settings:inherit;font-variation-settings:inherit;font-size:100%;font-weight:inherit;line-height:inherit;letter-spacing:inherit;color:inherit;margin:0;padding:0}button,select{text-transform:none}button,input:where([type=button]),input:where([type=reset]),input:where([type=submit]){-webkit-appearance:button;background-color:transparent;background-image:none}:-moz-focusring{outline:auto}:-moz-ui-invalid{box-shadow:none}progress{vertical-align:baseline}::-webkit-inner-spin-button,::-webkit-outer-spin-button{height:auto}[type=search]{-webkit-appearance:textfield;outline-offset:-2px}::-webkit-search-decoration{-webkit-appearance:none}::-webkit-file-upload-button{-webkit-appearance:button;font:inherit}summary{display:list-item}blockquote,dl,dd,h1,h2,h3,h4,h5,h6,hr,figure,p,pre{margin:0}fieldset{margin:0;padding:0}legend{padding:0}ol,ul,menu{list-style:none;margin:0;padding:0}dialog{padding:0}textarea{resize:vertical}input::-moz-placeholder,textarea::-moz-placeholder{opacity:1;color:#9ca3af}input::placeholder,textarea::placeholder{opacity:1;color:#9ca3af}button,[role=button]{cursor:pointer}:disabled{cursor:default}img,svg,video,canvas,audio,iframe,embed,object{display:block;vertical-align:middle}img,video{max-width:100%;height:auto}[hidden]:where(:not([hidden=until-found])){display:none}.sr-only{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border-width:0}.pointer-events-none{pointer-events:none}.static{position:static}.absolute{position:absolute}.relative{position:relative}.inset-0{top:0;right:0;bottom:0;left:0}.left-4{left:1rem}.right-4{right:1rem}.top-4{top:1rem}.z-10{z-index:10}.z-50{z-index:50}.mx-auto{margin-left:auto;margin-right:auto}.mb-1{margin-bottom:.25rem}.mb-1\.5{margin-bottom:.375rem}.mb-10{margin-bottom:2.5rem}.mb-2{margin-bottom:.5rem}.mb-3{margin-bottom:.75rem}.mb-4{margin-bottom:1rem}.mb-5{margin-bottom:1.25rem}.mb-6{margin-bottom:1.5rem}.mb-8{margin-bottom:2rem}.ml-9{margin-left:2.25rem}.mt-0\.5{margin-top:.125rem}.mt-1{margin-top:.25rem}.mt-3{margin-top:.75rem}.mt-6{margin-top:1.5rem}.flex{display:flex}.inline-flex{display:inline-flex}.grid{display:grid}.hidden{display:none}.aspect-square{aspect-ratio:1 / 1}.h-1{height:.25rem}.h-1\/2{height:50%}.h-10{height:2.5rem}.h-12{height:3rem}.h-14{height:3.5rem}.h-16{height:4rem}.h-2{height:.5rem}.h-20{height:5rem}.h-24{height:6rem}.h-3{height:.75rem}.h-3\.5{height:.875rem}.h-4{height:1rem}.h-48{height:12rem}.h-5{height:1.25rem}.h-6{height:1.5rem}.h-72{height:18rem}.h-8{height:2rem}.h-96{height:24rem}.h-\[200\%\]{height:200%}.h-\[75vh\]{height:75vh}.h-full{height:100%}.max-h-\[800px\]{max-height:800px}.min-h-0{min-height:0px}.min-h-screen{min-height:100vh}.w-10{width:2.5rem}.w-12{width:3rem}.w-14{width:3.5rem}.w-16{width:4rem}.w-2{width:.5rem}.w-20{width:5rem}.w-3{width:.75rem}.w-3\.5{width:.875rem}.w-4{width:1rem}.w-40{width:10rem}.w-48{width:12rem}.w-5{width:1.25rem}.w-56{width:14rem}.w-6{width:1.5rem}.w-64{width:16rem}.w-8{width:2rem}.w-\[75vw\]{width:75vw}.w-full{width:100%}.min-w-0{min-width:0px}.max-w-2xl{max-width:42rem}.max-w-4xl{max-width:56rem}.max-w-\[1200px\]{max-width:1200px}.max-w-full{max-width:100%}.max-w-lg{max-width:32rem}.max-w-md{max-width:28rem}.max-w-sm{max-width:24rem}.max-w-xl{max-width:36rem}.max-w-xs{max-width:20rem}.flex-1{flex:1 1 0%}.flex-shrink-0,.shrink-0{flex-shrink:0}.cursor-not-allowed{cursor:not-allowed}.cursor-pointer{cursor:pointer}.grid-cols-4{grid-template-columns:repeat(4,minmax(0,1fr))}.flex-col{flex-direction:column}.items-start{align-items:flex-start}.items-center{align-items:center}.justify-start{justify-content:flex-start}.justify-center{justify-content:center}.justify-between{justify-content:space-between}.gap-1{gap:.25rem}.gap-1\.5{gap:.375rem}.gap-2{gap:.5rem}.gap-3{gap:.75rem}.gap-4{gap:1rem}.gap-6{gap:1.5rem}.space-y-0\.5>:not([hidden])~:not([hidden]){--tw-space-y-reverse: 0;margin-top:calc(.125rem * calc(1 - var(--tw-space-y-reverse)));margin-bottom:calc(.125rem * var(--tw-space-y-reverse))}.space-y-1>:not([hidden])~:not([hidden]){--tw-space-y-reverse: 0;margin-top:calc(.25rem * calc(1 - var(--tw-space-y-reverse)));margin-bottom:calc(.25rem * var(--tw-space-y-reverse))}.space-y-4>:not([hidden])~:not([hidden]){--tw-space-y-reverse: 0;margin-top:calc(1rem * calc(1 - var(--tw-space-y-reverse)));margin-bottom:calc(1rem * var(--tw-space-y-reverse))}.overflow-auto{overflow:auto}.overflow-hidden{overflow:hidden}.overflow-x-auto{overflow-x:auto}.overflow-y-auto{overflow-y:auto}.whitespace-pre-wrap{white-space:pre-wrap}.rounded{border-radius:.25rem}.rounded-2xl{border-radius:1rem}.rounded-full{border-radius:9999px}.rounded-lg{border-radius:.5rem}.rounded-xl{border-radius:.75rem}.border{border-width:1px}.border-2{border-width:2px}.border-b{border-bottom-width:1px}.border-r{border-right-width:1px}.border-none{border-style:none}.border-amber-500\/30{border-color:#f59e0b4d}.border-blue-200{--tw-border-opacity: 1;border-color:rgb(191 219 254 / var(--tw-border-opacity, 1))}.border-blue-400{--tw-border-opacity: 1;border-color:rgb(96 165 250 / var(--tw-border-opacity, 1))}.border-blue-500{--tw-border-opacity: 1;border-color:rgb(59 130 246 / var(--tw-border-opacity, 1))}.border-gray-200{--tw-border-opacity: 1;border-color:rgb(229 231 235 / var(--tw-border-opacity, 1))}.border-gray-200\/50{border-color:#e5e7eb80}.border-gray-300{--tw-border-opacity: 1;border-color:rgb(209 213 219 / var(--tw-border-opacity, 1))}.border-purple-400{--tw-border-opacity: 1;border-color:rgb(192 132 252 / var(--tw-border-opacity, 1))}.border-red-500{--tw-border-opacity: 1;border-color:rgb(239 68 68 / var(--tw-border-opacity, 1))}.border-white\/10{border-color:#ffffff1a}.border-yellow-400{--tw-border-opacity: 1;border-color:rgb(250 204 21 / var(--tw-border-opacity, 1))}.border-t-red-500{--tw-border-opacity: 1;border-top-color:rgb(239 68 68 / var(--tw-border-opacity, 1))}.bg-amber-500\/20{background-color:#f59e0b33}.bg-blue-400\/10{background-color:#60a5fa1a}.bg-blue-50{--tw-bg-opacity: 1;background-color:rgb(239 246 255 / var(--tw-bg-opacity, 1))}.bg-blue-500{--tw-bg-opacity: 1;background-color:rgb(59 130 246 / var(--tw-bg-opacity, 1))}.bg-blue-500\/20{background-color:#3b82f633}.bg-blue-600{--tw-bg-opacity: 1;background-color:rgb(37 99 235 / var(--tw-bg-opacity, 1))}.bg-gray-100{--tw-bg-opacity: 1;background-color:rgb(243 244 246 / var(--tw-bg-opacity, 1))}.bg-gray-100\/80{background-color:#f3f4f6cc}.bg-gray-200{--tw-bg-opacity: 1;background-color:rgb(229 231 235 / var(--tw-bg-opacity, 1))}.bg-gray-300{--tw-bg-opacity: 1;background-color:rgb(209 213 219 / var(--tw-bg-opacity, 1))}.bg-gray-50{--tw-bg-opacity: 1;background-color:rgb(249 250 251 / var(--tw-bg-opacity, 1))}.bg-gray-900{--tw-bg-opacity: 1;background-color:rgb(17 24 39 / var(--tw-bg-opacity, 1))}.bg-green-500{--tw-bg-opacity: 1;background-color:rgb(34 197 94 / var(--tw-bg-opacity, 1))}.bg-green-500\/20{background-color:#22c55e33}.bg-purple-400\/10{background-color:#c084fc1a}.bg-red-500{--tw-bg-opacity: 1;background-color:rgb(239 68 68 / var(--tw-bg-opacity, 1))}.bg-red-500\/10{background-color:#ef44441a}.bg-red-500\/20{background-color:#ef444433}.bg-transparent{background-color:transparent}.bg-white{--tw-bg-opacity: 1;background-color:rgb(255 255 255 / var(--tw-bg-opacity, 1))}.bg-white\/5{background-color:#ffffff0d}.bg-white\/50{background-color:#ffffff80}.bg-yellow-400\/10{background-color:#facc151a}.object-contain{-o-object-fit:contain;object-fit:contain}.object-cover{-o-object-fit:cover;object-fit:cover}.object-center{-o-object-position:center;object-position:center}.p-1{padding:.25rem}.p-2{padding:.5rem}.p-3{padding:.75rem}.p-4{padding:1rem}.p-5{padding:1.25rem}.p-6{padding:1.5rem}.px-1{padding-left:.25rem;padding-right:.25rem}.px-10{padding-left:2.5rem;padding-right:2.5rem}.px-2{padding-left:.5rem;padding-right:.5rem}.px-3{padding-left:.75rem;padding-right:.75rem}.px-4{padding-left:1rem;padding-right:1rem}.px-5{padding-left:1.25rem;padding-right:1.25rem}.px-6{padding-left:1.5rem;padding-right:1.5rem}.px-8{padding-left:2rem;padding-right:2rem}.py-0\.5{padding-top:.125rem;padding-bottom:.125rem}.py-1{padding-top:.25rem;padding-bottom:.25rem}.py-1\.5{padding-top:.375rem;padding-bottom:.375rem}.py-2{padding-top:.5rem;padding-bottom:.5rem}.py-2\.5{padding-top:.625rem;padding-bottom:.625rem}.py-3{padding-top:.75rem;padding-bottom:.75rem}.pb-6{padding-bottom:1.5rem}.pt-10{padding-top:2.5rem}.pt-4{padding-top:1rem}.pt-\[15\%\]{padding-top:15%}.text-left{text-align:left}.text-center{text-align:center}.font-mono{font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace}.text-2xl{font-size:1.5rem;line-height:2rem}.text-\[10px\]{font-size:10px}.text-base{font-size:1rem;line-height:1.5rem}.text-lg{font-size:1.125rem;line-height:1.75rem}.text-sm{font-size:.875rem;line-height:1.25rem}.text-xl{font-size:1.25rem;line-height:1.75rem}.text-xs{font-size:.75rem;line-height:1rem}.font-medium{font-weight:500}.font-semibold{font-weight:600}.uppercase{text-transform:uppercase}.leading-relaxed{line-height:1.625}.leading-tight{line-height:1.25}.tracking-tight{letter-spacing:-.025em}.tracking-wide{letter-spacing:.025em}.text-amber-500{--tw-text-opacity: 1;color:rgb(245 158 11 / var(--tw-text-opacity, 1))}.text-amber-600{--tw-text-opacity: 1;color:rgb(217 119 6 / var(--tw-text-opacity, 1))}.text-blue-500{--tw-text-opacity: 1;color:rgb(59 130 246 / var(--tw-text-opacity, 1))}.text-blue-600{--tw-text-opacity: 1;color:rgb(37 99 235 / var(--tw-text-opacity, 1))}.text-gray-100{--tw-text-opacity: 1;color:rgb(243 244 246 / var(--tw-text-opacity, 1))}.text-gray-400{--tw-text-opacity: 1;color:rgb(156 163 175 / var(--tw-text-opacity, 1))}.text-gray-500{--tw-text-opacity: 1;color:rgb(107 114 128 / var(--tw-text-opacity, 1))}.text-gray-600{--tw-text-opacity: 1;color:rgb(75 85 99 / var(--tw-text-opacity, 1))}.text-gray-700{--tw-text-opacity: 1;color:rgb(55 65 81 / var(--tw-text-opacity, 1))}.text-gray-800{--tw-text-opacity: 1;color:rgb(31 41 55 / var(--tw-text-opacity, 1))}.text-gray-900{--tw-text-opacity: 1;color:rgb(17 24 39 / var(--tw-text-opacity, 1))}.text-green-500{--tw-text-opacity: 1;color:rgb(34 197 94 / var(--tw-text-opacity, 1))}.text-green-700{--tw-text-opacity: 1;color:rgb(21 128 61 / var(--tw-text-opacity, 1))}.text-red-500{--tw-text-opacity: 1;color:rgb(239 68 68 / var(--tw-text-opacity, 1))}.text-red-600{--tw-text-opacity: 1;color:rgb(220 38 38 / var(--tw-text-opacity, 1))}.text-white{--tw-text-opacity: 1;color:rgb(255 255 255 / var(--tw-text-opacity, 1))}.text-yellow-500{--tw-text-opacity: 1;color:rgb(234 179 8 / var(--tw-text-opacity, 1))}.placeholder-gray-400::-moz-placeholder{--tw-placeholder-opacity: 1;color:rgb(156 163 175 / var(--tw-placeholder-opacity, 1))}.placeholder-gray-400::placeholder{--tw-placeholder-opacity: 1;color:rgb(156 163 175 / var(--tw-placeholder-opacity, 1))}.opacity-50{opacity:.5}.opacity-\[0\.08\]{opacity:.08}.shadow-lg{--tw-shadow: 0 10px 15px -3px rgb(0 0 0 / .1), 0 4px 6px -4px rgb(0 0 0 / .1);--tw-shadow-colored: 0 10px 15px -3px var(--tw-shadow-color), 0 4px 6px -4px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}.shadow-blue-400\/20{--tw-shadow-color: rgb(96 165 250 / .2);--tw-shadow: var(--tw-shadow-colored)}.shadow-purple-400\/20{--tw-shadow-color: rgb(192 132 252 / .2);--tw-shadow: var(--tw-shadow-colored)}.shadow-red-500\/10{--tw-shadow-color: rgb(239 68 68 / .1);--tw-shadow: var(--tw-shadow-colored)}.shadow-yellow-400\/20{--tw-shadow-color: rgb(250 204 21 / .2);--tw-shadow: var(--tw-shadow-colored)}.drop-shadow{--tw-drop-shadow: drop-shadow(0 1px 2px rgb(0 0 0 / .1)) drop-shadow(0 1px 1px rgb(0 0 0 / .06));filter:var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow)}.filter{filter:var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow)}.transition{transition-property:color,background-color,border-color,text-decoration-color,fill,stroke,opacity,box-shadow,transform,filter,backdrop-filter;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.transition-all{transition-property:all;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.transition-colors{transition-property:color,background-color,border-color,text-decoration-color,fill,stroke;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.transition-opacity{transition-property:opacity;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.duration-300{transition-duration:.3s}:root{--wails-red: #ef4444;--wails-red-dark: #dc2626;--wails-red-light: #f87171;--wails-blue: #1d63ed;--wails-blue-dark: #1554d0;--wails-blue-light: #3b7dff;--bg-primary: #05070b;--bg-secondary: #0a0e16;--bg-tertiary: #0f1420;--glass-bg: rgba(255, 255, 255, .06);--glass-border: rgba(255, 255, 255, .08)}*{box-sizing:border-box}html,body,#root{margin:0;padding:0;min-height:100vh;background:var(--bg-primary);color:#fff;font-family:Inter,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen,Ubuntu,Cantarell,sans-serif;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}.gradient-text{background:linear-gradient(135deg,#fff,#ef4444);-webkit-background-clip:text;-webkit-text-fill-color:transparent;background-clip:text}.glass-card{background:linear-gradient(180deg,#ffffff14,#ffffff0a);backdrop-filter:blur(20px);-webkit-backdrop-filter:blur(20px);border:1px solid var(--glass-border);box-shadow:0 30px 80px #00000080}.glass-sidebar{background:#05070c8c;backdrop-filter:blur(30px);-webkit-backdrop-filter:blur(30px);border-right:1px solid var(--glass-border)}.settings-row{display:flex;align-items:center;justify-content:space-between;padding:0 20px;height:52px;cursor:pointer;-webkit-user-select:none;-moz-user-select:none;user-select:none;transition:background-color .12s ease}.settings-row:hover{background:#0000000a}.dark .settings-row:hover{background:#ffffff0f}.settings-row+.settings-row{border-top:1px solid rgba(0,0,0,.1)}.dark .settings-row+.settings-row{border-top:1px solid var(--glass-border)}.settings-group{border-radius:12px;background:#0000000a;box-shadow:0 4px 12px #00000014,0 0 0 1px #00000014 inset;overflow:hidden}.dark .settings-group{background:#ffffff1a;box-shadow:0 12px 30px #00000059,0 0 0 1px var(--glass-border) inset;backdrop-filter:blur(10px);-webkit-backdrop-filter:blur(10px)}.grid-bg{background-image:linear-gradient(rgba(239,68,68,.03) 1px,transparent 1px),linear-gradient(90deg,rgba(239,68,68,.03) 1px,transparent 1px);background-size:40px 40px}.radial-glow{background:radial-gradient(ellipse at center,rgba(239,68,68,.1) 0%,transparent 70%)}::-webkit-scrollbar{width:8px}::-webkit-scrollbar-track{background:var(--bg-primary)}::-webkit-scrollbar-thumb{background:var(--bg-tertiary);border-radius:4px}::-webkit-scrollbar-thumb:hover{background:#4b5563}.scrollbar-thin::-webkit-scrollbar{width:4px}.scrollbar-thin::-webkit-scrollbar-track{background:transparent}.scrollbar-thin::-webkit-scrollbar-thumb{background:#9ca3af4d;border-radius:2px}.scrollbar-thin::-webkit-scrollbar-thumb:hover{background:#9ca3af80}.btn-primary{border-radius:.75rem;background-image:linear-gradient(to right,var(--tw-gradient-stops));--tw-gradient-from: #ef4444 var(--tw-gradient-from-position);--tw-gradient-to: rgb(239 68 68 / 0) var(--tw-gradient-to-position);--tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to);--tw-gradient-to: #dc2626 var(--tw-gradient-to-position);padding:.75rem 2rem;font-weight:600;--tw-text-opacity: 1;color:rgb(255 255 255 / var(--tw-text-opacity, 1));--tw-shadow: 0 10px 15px -3px rgb(0 0 0 / .1), 0 4px 6px -4px rgb(0 0 0 / .1);--tw-shadow-colored: 0 10px 15px -3px var(--tw-shadow-color), 0 4px 6px -4px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow);transition-property:all;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.3s}.btn-primary:hover{--tw-scale-x: 1.05;--tw-scale-y: 1.05;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y));--tw-shadow: 0 20px 25px -5px rgb(0 0 0 / .1), 0 8px 10px -6px rgb(0 0 0 / .1);--tw-shadow-colored: 0 20px 25px -5px var(--tw-shadow-color), 0 8px 10px -6px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow);--tw-shadow-color: rgb(239 68 68 / .3);--tw-shadow: var(--tw-shadow-colored)}.btn-primary:active{--tw-scale-x: .95;--tw-scale-y: .95;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.btn-secondary{border-radius:.75rem;border-width:1px;--tw-border-opacity: 1;border-color:rgb(75 85 99 / var(--tw-border-opacity, 1));background-color:transparent;padding:.75rem 2rem;font-weight:500;--tw-text-opacity: 1;color:rgb(209 213 219 / var(--tw-text-opacity, 1));transition-property:all;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.3s}.btn-secondary:hover{--tw-border-opacity: 1;border-color:rgb(107 114 128 / var(--tw-border-opacity, 1));background-color:#1f293780;--tw-text-opacity: 1;color:rgb(255 255 255 / var(--tw-text-opacity, 1))}@keyframes spin{to{transform:rotate(360deg)}}.spinner{animation:spin 1s linear infinite}.check-path{stroke-dasharray:100;stroke-dashoffset:100;animation:drawCheck .5s ease-out forwards}@keyframes scrollBackground{0%{transform:translateY(0)}to{transform:translateY(-50%)}}.scrolling-bg{animation:scrollBackground 60s linear infinite}@media (prefers-reduced-motion: reduce){*:not(.animate-spin):not(.spinner),*:not(.animate-spin):not(.spinner):before,*:not(.animate-spin):not(.spinner):after{animation-duration:.01ms!important;animation-iteration-count:1!important;transition-duration:.01ms!important}}.sr-only{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border:0}.settings-row:focus-visible{outline:2px solid #ef4444;outline-offset:-2px}.last\:border-0:last-child{border-width:0px}.hover\:bg-blue-500:hover{--tw-bg-opacity: 1;background-color:rgb(59 130 246 / var(--tw-bg-opacity, 1))}.hover\:bg-blue-500\/10:hover{background-color:#3b82f61a}.hover\:bg-blue-600:hover{--tw-bg-opacity: 1;background-color:rgb(37 99 235 / var(--tw-bg-opacity, 1))}.hover\:bg-gray-100:hover{--tw-bg-opacity: 1;background-color:rgb(243 244 246 / var(--tw-bg-opacity, 1))}.hover\:bg-gray-200:hover{--tw-bg-opacity: 1;background-color:rgb(229 231 235 / var(--tw-bg-opacity, 1))}.hover\:bg-gray-50:hover{--tw-bg-opacity: 1;background-color:rgb(249 250 251 / var(--tw-bg-opacity, 1))}.hover\:bg-red-500\/10:hover{background-color:#ef44441a}.hover\:bg-white\/10:hover{background-color:#ffffff1a}.hover\:text-blue-600:hover{--tw-text-opacity: 1;color:rgb(37 99 235 / var(--tw-text-opacity, 1))}.hover\:text-gray-700:hover{--tw-text-opacity: 1;color:rgb(55 65 81 / var(--tw-text-opacity, 1))}.hover\:opacity-70:hover{opacity:.7}.focus\:outline-none:focus{outline:2px solid transparent;outline-offset:2px}.focus\:ring-2:focus{--tw-ring-offset-shadow: var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow: var(--tw-ring-inset) 0 0 0 calc(2px + var(--tw-ring-offset-width)) var(--tw-ring-color);box-shadow:var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow, 0 0 #0000)}.focus\:ring-inset:focus{--tw-ring-inset: inset}.focus\:ring-blue-400:focus{--tw-ring-opacity: 1;--tw-ring-color: rgb(96 165 250 / var(--tw-ring-opacity, 1))}.focus\:ring-blue-500:focus{--tw-ring-opacity: 1;--tw-ring-color: rgb(59 130 246 / var(--tw-ring-opacity, 1))}.focus\:ring-gray-500:focus{--tw-ring-opacity: 1;--tw-ring-color: rgb(107 114 128 / var(--tw-ring-opacity, 1))}.focus\:ring-purple-400:focus{--tw-ring-opacity: 1;--tw-ring-color: rgb(192 132 252 / var(--tw-ring-opacity, 1))}.focus\:ring-red-500:focus{--tw-ring-opacity: 1;--tw-ring-color: rgb(239 68 68 / var(--tw-ring-opacity, 1))}.focus\:ring-yellow-400:focus{--tw-ring-opacity: 1;--tw-ring-color: rgb(250 204 21 / var(--tw-ring-opacity, 1))}.focus\:ring-offset-2:focus{--tw-ring-offset-width: 2px}.dark\:border-blue-800:is(.dark *){--tw-border-opacity: 1;border-color:rgb(30 64 175 / var(--tw-border-opacity, 1))}.dark\:border-gray-600:is(.dark *){--tw-border-opacity: 1;border-color:rgb(75 85 99 / var(--tw-border-opacity, 1))}.dark\:border-gray-700:is(.dark *){--tw-border-opacity: 1;border-color:rgb(55 65 81 / var(--tw-border-opacity, 1))}.dark\:border-gray-800\/50:is(.dark *){border-color:#1f293780}.dark\:border-transparent:is(.dark *){border-color:transparent}.dark\:border-white\/10:is(.dark *){border-color:#ffffff1a}.dark\:bg-\[\#0f0f0f\]:is(.dark *){--tw-bg-opacity: 1;background-color:rgb(15 15 15 / var(--tw-bg-opacity, 1))}.dark\:bg-black\/30:is(.dark *){background-color:#0000004d}.dark\:bg-blue-900\/20:is(.dark *){background-color:#1e3a8a33}.dark\:bg-gray-700:is(.dark *){--tw-bg-opacity: 1;background-color:rgb(55 65 81 / var(--tw-bg-opacity, 1))}.dark\:bg-gray-800:is(.dark *){--tw-bg-opacity: 1;background-color:rgb(31 41 55 / var(--tw-bg-opacity, 1))}.dark\:bg-gray-800\/50:is(.dark *){background-color:#1f293780}.dark\:bg-gray-800\/80:is(.dark *){background-color:#1f2937cc}.dark\:bg-gray-900:is(.dark *){--tw-bg-opacity: 1;background-color:rgb(17 24 39 / var(--tw-bg-opacity, 1))}.dark\:bg-gray-900\/50:is(.dark *){background-color:#11182780}.dark\:bg-transparent:is(.dark *){background-color:transparent}.dark\:bg-white\/5:is(.dark *){background-color:#ffffff0d}.dark\:bg-white\/\[0\.03\]:is(.dark *){background-color:#ffffff08}.dark\:text-amber-400:is(.dark *){--tw-text-opacity: 1;color:rgb(251 191 36 / var(--tw-text-opacity, 1))}.dark\:text-blue-400:is(.dark *){--tw-text-opacity: 1;color:rgb(96 165 250 / var(--tw-text-opacity, 1))}.dark\:text-gray-300:is(.dark *){--tw-text-opacity: 1;color:rgb(209 213 219 / var(--tw-text-opacity, 1))}.dark\:text-gray-400:is(.dark *){--tw-text-opacity: 1;color:rgb(156 163 175 / var(--tw-text-opacity, 1))}.dark\:text-gray-500:is(.dark *){--tw-text-opacity: 1;color:rgb(107 114 128 / var(--tw-text-opacity, 1))}.dark\:text-gray-600:is(.dark *){--tw-text-opacity: 1;color:rgb(75 85 99 / var(--tw-text-opacity, 1))}.dark\:text-red-400:is(.dark *){--tw-text-opacity: 1;color:rgb(248 113 113 / var(--tw-text-opacity, 1))}.dark\:text-white:is(.dark *){--tw-text-opacity: 1;color:rgb(255 255 255 / var(--tw-text-opacity, 1))}.dark\:text-white\/40:is(.dark *){color:#fff6}.dark\:text-white\/50:is(.dark *){color:#ffffff80}.dark\:text-white\/65:is(.dark *){color:#ffffffa6}.dark\:text-white\/70:is(.dark *){color:#ffffffb3}.dark\:text-white\/90:is(.dark *){color:#ffffffe6}.dark\:placeholder-gray-500:is(.dark *)::-moz-placeholder{--tw-placeholder-opacity: 1;color:rgb(107 114 128 / var(--tw-placeholder-opacity, 1))}.dark\:placeholder-gray-500:is(.dark *)::placeholder{--tw-placeholder-opacity: 1;color:rgb(107 114 128 / var(--tw-placeholder-opacity, 1))}.dark\:opacity-\[0\.06\]:is(.dark *){opacity:.06}.dark\:hover\:bg-gray-700:hover:is(.dark *){--tw-bg-opacity: 1;background-color:rgb(55 65 81 / var(--tw-bg-opacity, 1))}.dark\:hover\:bg-gray-800:hover:is(.dark *){--tw-bg-opacity: 1;background-color:rgb(31 41 55 / var(--tw-bg-opacity, 1))}.dark\:hover\:bg-gray-800\/50:hover:is(.dark *){background-color:#1f293780}.dark\:hover\:bg-white\/10:hover:is(.dark *){background-color:#ffffff1a}.dark\:hover\:text-blue-300:hover:is(.dark *){--tw-text-opacity: 1;color:rgb(147 197 253 / var(--tw-text-opacity, 1))}.dark\:hover\:text-gray-200:hover:is(.dark *){--tw-text-opacity: 1;color:rgb(229 231 235 / var(--tw-text-opacity, 1))}.dark\:hover\:text-gray-300:hover:is(.dark *){--tw-text-opacity: 1;color:rgb(209 213 219 / var(--tw-text-opacity, 1))}.dark\:focus\:ring-offset-gray-900:focus:is(.dark *){--tw-ring-offset-color: #111827} diff --git a/v3/internal/setupwizard/frontend/dist/assets/index-Cxa-r7OW.js b/v3/internal/setupwizard/frontend/dist/assets/index-Cxa-r7OW.js deleted file mode 100644 index 45d9ce124..000000000 --- a/v3/internal/setupwizard/frontend/dist/assets/index-Cxa-r7OW.js +++ /dev/null @@ -1,60 +0,0 @@ -(function(){const t=document.createElement("link").relList;if(t&&t.supports&&t.supports("modulepreload"))return;for(const i of document.querySelectorAll('link[rel="modulepreload"]'))r(i);new MutationObserver(i=>{for(const s of i)if(s.type==="childList")for(const o of s.addedNodes)o.tagName==="LINK"&&o.rel==="modulepreload"&&r(o)}).observe(document,{childList:!0,subtree:!0});function n(i){const s={};return i.integrity&&(s.integrity=i.integrity),i.referrerPolicy&&(s.referrerPolicy=i.referrerPolicy),i.crossOrigin==="use-credentials"?s.credentials="include":i.crossOrigin==="anonymous"?s.credentials="omit":s.credentials="same-origin",s}function r(i){if(i.ep)return;i.ep=!0;const s=n(i);fetch(i.href,s)}})();function am(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var ef={exports:{}},Es={},tf={exports:{}},_={};/** - * @license React - * react.production.min.js - * - * Copyright (c) Facebook, Inc. and its affiliates. - * - * This source code is licensed under the MIT license found in the - * LICENSE file in the root directory of this source tree. - */var si=Symbol.for("react.element"),lm=Symbol.for("react.portal"),um=Symbol.for("react.fragment"),cm=Symbol.for("react.strict_mode"),dm=Symbol.for("react.profiler"),fm=Symbol.for("react.provider"),hm=Symbol.for("react.context"),pm=Symbol.for("react.forward_ref"),mm=Symbol.for("react.suspense"),gm=Symbol.for("react.memo"),ym=Symbol.for("react.lazy"),Pu=Symbol.iterator;function vm(e){return e===null||typeof e!="object"?null:(e=Pu&&e[Pu]||e["@@iterator"],typeof e=="function"?e:null)}var nf={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},rf=Object.assign,sf={};function nr(e,t,n){this.props=e,this.context=t,this.refs=sf,this.updater=n||nf}nr.prototype.isReactComponent={};nr.prototype.setState=function(e,t){if(typeof e!="object"&&typeof e!="function"&&e!=null)throw Error("setState(...): takes an object of state variables to update or a function which returns an object of state variables.");this.updater.enqueueSetState(this,e,t,"setState")};nr.prototype.forceUpdate=function(e){this.updater.enqueueForceUpdate(this,e,"forceUpdate")};function of(){}of.prototype=nr.prototype;function Za(e,t,n){this.props=e,this.context=t,this.refs=sf,this.updater=n||nf}var qa=Za.prototype=new of;qa.constructor=Za;rf(qa,nr.prototype);qa.isPureReactComponent=!0;var Eu=Array.isArray,af=Object.prototype.hasOwnProperty,Ja={current:null},lf={key:!0,ref:!0,__self:!0,__source:!0};function uf(e,t,n){var r,i={},s=null,o=null;if(t!=null)for(r in t.ref!==void 0&&(o=t.ref),t.key!==void 0&&(s=""+t.key),t)af.call(t,r)&&!lf.hasOwnProperty(r)&&(i[r]=t[r]);var a=arguments.length-2;if(a===1)i.children=n;else if(1>>1,re=E[U];if(0>>1;Ui(lr,V))pti(kn,lr)?(E[U]=kn,E[pt]=V,U=pt):(E[U]=lr,E[ht]=V,U=ht);else if(pti(kn,V))E[U]=kn,E[pt]=V,U=pt;else break e}}return A}function i(E,A){var V=E.sortIndex-A.sortIndex;return V!==0?V:E.id-A.id}if(typeof performance=="object"&&typeof performance.now=="function"){var s=performance;e.unstable_now=function(){return s.now()}}else{var o=Date,a=o.now();e.unstable_now=function(){return o.now()-a}}var l=[],u=[],c=1,h=null,f=3,v=!1,x=!1,y=!1,T=typeof setTimeout=="function"?setTimeout:null,m=typeof clearTimeout=="function"?clearTimeout:null,p=typeof setImmediate<"u"?setImmediate:null;typeof navigator<"u"&&navigator.scheduling!==void 0&&navigator.scheduling.isInputPending!==void 0&&navigator.scheduling.isInputPending.bind(navigator.scheduling);function g(E){for(var A=n(u);A!==null;){if(A.callback===null)r(u);else if(A.startTime<=E)r(u),A.sortIndex=A.expirationTime,t(l,A);else break;A=n(u)}}function w(E){if(y=!1,g(E),!x)if(n(l)!==null)x=!0,de(k);else{var A=n(u);A!==null&&Y(w,A.startTime-E)}}function k(E,A){x=!1,y&&(y=!1,m(C),C=-1),v=!0;var V=f;try{for(g(A),h=n(l);h!==null&&(!(h.expirationTime>A)||E&&!J());){var U=h.callback;if(typeof U=="function"){h.callback=null,f=h.priorityLevel;var re=U(h.expirationTime<=A);A=e.unstable_now(),typeof re=="function"?h.callback=re:h===n(l)&&r(l),g(A)}else r(l);h=n(l)}if(h!==null)var wn=!0;else{var ht=n(u);ht!==null&&Y(w,ht.startTime-A),wn=!1}return wn}finally{h=null,f=V,v=!1}}var j=!1,N=null,C=-1,b=5,L=-1;function J(){return!(e.unstable_now()-LE||125U?(E.sortIndex=V,t(u,E),n(l)===null&&E===n(u)&&(y?(m(C),C=-1):y=!0,Y(w,V-U))):(E.sortIndex=re,t(l,E),x||v||(x=!0,de(k))),E},e.unstable_shouldYield=J,e.unstable_wrapCallback=function(E){var A=f;return function(){var V=f;f=A;try{return E.apply(this,arguments)}finally{f=V}}}})(pf);hf.exports=pf;var Lm=hf.exports;/** - * @license React - * react-dom.production.min.js - * - * Copyright (c) Facebook, Inc. and its affiliates. - * - * This source code is licensed under the MIT license found in the - * LICENSE file in the root directory of this source tree. - */var Dm=S,_e=Lm;function P(e){for(var t="https://reactjs.org/docs/error-decoder.html?invariant="+e,n=1;n"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),Fo=Object.prototype.hasOwnProperty,Am=/^[: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]*$/,Lu={},Du={};function Rm(e){return Fo.call(Du,e)?!0:Fo.call(Lu,e)?!1:Am.test(e)?Du[e]=!0:(Lu[e]=!0,!1)}function Vm(e,t,n,r){if(n!==null&&n.type===0)return!1;switch(typeof t){case"function":case"symbol":return!0;case"boolean":return r?!1:n!==null?!n.acceptsBooleans:(e=e.toLowerCase().slice(0,5),e!=="data-"&&e!=="aria-");default:return!1}}function bm(e,t,n,r){if(t===null||typeof t>"u"||Vm(e,t,n,r))return!0;if(r)return!1;if(n!==null)switch(n.type){case 3:return!t;case 4:return t===!1;case 5:return isNaN(t);case 6:return isNaN(t)||1>t}return!1}function Pe(e,t,n,r,i,s,o){this.acceptsBooleans=t===2||t===3||t===4,this.attributeName=r,this.attributeNamespace=i,this.mustUseProperty=n,this.propertyName=e,this.type=t,this.sanitizeURL=s,this.removeEmptyString=o}var me={};"children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style".split(" ").forEach(function(e){me[e]=new Pe(e,0,!1,e,null,!1,!1)});[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach(function(e){var t=e[0];me[t]=new Pe(t,1,!1,e[1],null,!1,!1)});["contentEditable","draggable","spellCheck","value"].forEach(function(e){me[e]=new Pe(e,2,!1,e.toLowerCase(),null,!1,!1)});["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach(function(e){me[e]=new Pe(e,2,!1,e,null,!1,!1)});"allowFullScreen async autoFocus autoPlay controls default defer disabled disablePictureInPicture disableRemotePlayback formNoValidate hidden loop noModule noValidate open playsInline readOnly required reversed scoped seamless itemScope".split(" ").forEach(function(e){me[e]=new Pe(e,3,!1,e.toLowerCase(),null,!1,!1)});["checked","multiple","muted","selected"].forEach(function(e){me[e]=new Pe(e,3,!0,e,null,!1,!1)});["capture","download"].forEach(function(e){me[e]=new Pe(e,4,!1,e,null,!1,!1)});["cols","rows","size","span"].forEach(function(e){me[e]=new Pe(e,6,!1,e,null,!1,!1)});["rowSpan","start"].forEach(function(e){me[e]=new Pe(e,5,!1,e.toLowerCase(),null,!1,!1)});var tl=/[\-:]([a-z])/g;function nl(e){return e[1].toUpperCase()}"accent-height alignment-baseline arabic-form baseline-shift cap-height clip-path clip-rule color-interpolation color-interpolation-filters color-profile color-rendering dominant-baseline enable-background fill-opacity fill-rule flood-color flood-opacity font-family font-size font-size-adjust font-stretch font-style font-variant font-weight glyph-name glyph-orientation-horizontal glyph-orientation-vertical horiz-adv-x horiz-origin-x image-rendering letter-spacing lighting-color marker-end marker-mid marker-start overline-position overline-thickness paint-order panose-1 pointer-events rendering-intent shape-rendering stop-color stop-opacity strikethrough-position strikethrough-thickness stroke-dasharray stroke-dashoffset stroke-linecap stroke-linejoin stroke-miterlimit stroke-opacity stroke-width text-anchor text-decoration text-rendering underline-position underline-thickness unicode-bidi unicode-range units-per-em v-alphabetic v-hanging v-ideographic v-mathematical vector-effect vert-adv-y vert-origin-x vert-origin-y word-spacing writing-mode xmlns:xlink x-height".split(" ").forEach(function(e){var t=e.replace(tl,nl);me[t]=new Pe(t,1,!1,e,null,!1,!1)});"xlink:actuate xlink:arcrole xlink:role xlink:show xlink:title xlink:type".split(" ").forEach(function(e){var t=e.replace(tl,nl);me[t]=new Pe(t,1,!1,e,"http://www.w3.org/1999/xlink",!1,!1)});["xml:base","xml:lang","xml:space"].forEach(function(e){var t=e.replace(tl,nl);me[t]=new Pe(t,1,!1,e,"http://www.w3.org/XML/1998/namespace",!1,!1)});["tabIndex","crossOrigin"].forEach(function(e){me[e]=new Pe(e,1,!1,e.toLowerCase(),null,!1,!1)});me.xlinkHref=new Pe("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1);["src","href","action","formAction"].forEach(function(e){me[e]=new Pe(e,1,!1,e.toLowerCase(),null,!0,!0)});function rl(e,t,n,r){var i=me.hasOwnProperty(t)?me[t]:null;(i!==null?i.type!==0:r||!(2a||i[o]!==s[a]){var l=` -`+i[o].replace(" at new "," at ");return e.displayName&&l.includes("")&&(l=l.replace("",e.displayName)),l}while(1<=o&&0<=a);break}}}finally{Xs=!1,Error.prepareStackTrace=n}return(e=e?e.displayName||e.name:"")?vr(e):""}function Im(e){switch(e.tag){case 5:return vr(e.type);case 16:return vr("Lazy");case 13:return vr("Suspense");case 19:return vr("SuspenseList");case 0:case 2:case 15:return e=Zs(e.type,!1),e;case 11:return e=Zs(e.type.render,!1),e;case 1:return e=Zs(e.type,!0),e;default:return""}}function Uo(e){if(e==null)return null;if(typeof e=="function")return e.displayName||e.name||null;if(typeof e=="string")return e;switch(e){case Cn:return"Fragment";case jn:return"Portal";case Oo:return"Profiler";case il:return"StrictMode";case Bo:return"Suspense";case zo:return"SuspenseList"}if(typeof e=="object")switch(e.$$typeof){case yf:return(e.displayName||"Context")+".Consumer";case gf:return(e._context.displayName||"Context")+".Provider";case sl:var t=e.render;return e=e.displayName,e||(e=t.displayName||t.name||"",e=e!==""?"ForwardRef("+e+")":"ForwardRef"),e;case ol:return t=e.displayName||null,t!==null?t:Uo(e.type)||"Memo";case Mt:t=e._payload,e=e._init;try{return Uo(e(t))}catch{}}return null}function _m(e){var t=e.type;switch(e.tag){case 24:return"Cache";case 9:return(t.displayName||"Context")+".Consumer";case 10:return(t._context.displayName||"Context")+".Provider";case 18:return"DehydratedFragment";case 11:return e=t.render,e=e.displayName||e.name||"",t.displayName||(e!==""?"ForwardRef("+e+")":"ForwardRef");case 7:return"Fragment";case 5:return t;case 4:return"Portal";case 3:return"Root";case 6:return"Text";case 16:return Uo(t);case 8:return t===il?"StrictMode":"Mode";case 22:return"Offscreen";case 12:return"Profiler";case 21:return"Scope";case 13:return"Suspense";case 19:return"SuspenseList";case 25:return"TracingMarker";case 1:case 0:case 17:case 2:case 14:case 15:if(typeof t=="function")return t.displayName||t.name||null;if(typeof t=="string")return t}return null}function Wt(e){switch(typeof e){case"boolean":case"number":case"string":case"undefined":return e;case"object":return e;default:return""}}function xf(e){var t=e.type;return(e=e.nodeName)&&e.toLowerCase()==="input"&&(t==="checkbox"||t==="radio")}function Fm(e){var t=xf(e)?"checked":"value",n=Object.getOwnPropertyDescriptor(e.constructor.prototype,t),r=""+e[t];if(!e.hasOwnProperty(t)&&typeof n<"u"&&typeof n.get=="function"&&typeof n.set=="function"){var i=n.get,s=n.set;return Object.defineProperty(e,t,{configurable:!0,get:function(){return i.call(this)},set:function(o){r=""+o,s.call(this,o)}}),Object.defineProperty(e,t,{enumerable:n.enumerable}),{getValue:function(){return r},setValue:function(o){r=""+o},stopTracking:function(){e._valueTracker=null,delete e[t]}}}}function gi(e){e._valueTracker||(e._valueTracker=Fm(e))}function wf(e){if(!e)return!1;var t=e._valueTracker;if(!t)return!0;var n=t.getValue(),r="";return e&&(r=xf(e)?e.checked?"true":"false":e.value),e=r,e!==n?(t.setValue(e),!0):!1}function qi(e){if(e=e||(typeof document<"u"?document:void 0),typeof e>"u")return null;try{return e.activeElement||e.body}catch{return e.body}}function Wo(e,t){var n=t.checked;return q({},t,{defaultChecked:void 0,defaultValue:void 0,value:void 0,checked:n??e._wrapperState.initialChecked})}function Ru(e,t){var n=t.defaultValue==null?"":t.defaultValue,r=t.checked!=null?t.checked:t.defaultChecked;n=Wt(t.value!=null?t.value:n),e._wrapperState={initialChecked:r,initialValue:n,controlled:t.type==="checkbox"||t.type==="radio"?t.checked!=null:t.value!=null}}function kf(e,t){t=t.checked,t!=null&&rl(e,"checked",t,!1)}function $o(e,t){kf(e,t);var n=Wt(t.value),r=t.type;if(n!=null)r==="number"?(n===0&&e.value===""||e.value!=n)&&(e.value=""+n):e.value!==""+n&&(e.value=""+n);else if(r==="submit"||r==="reset"){e.removeAttribute("value");return}t.hasOwnProperty("value")?Ho(e,t.type,n):t.hasOwnProperty("defaultValue")&&Ho(e,t.type,Wt(t.defaultValue)),t.checked==null&&t.defaultChecked!=null&&(e.defaultChecked=!!t.defaultChecked)}function Vu(e,t,n){if(t.hasOwnProperty("value")||t.hasOwnProperty("defaultValue")){var r=t.type;if(!(r!=="submit"&&r!=="reset"||t.value!==void 0&&t.value!==null))return;t=""+e._wrapperState.initialValue,n||t===e.value||(e.value=t),e.defaultValue=t}n=e.name,n!==""&&(e.name=""),e.defaultChecked=!!e._wrapperState.initialChecked,n!==""&&(e.name=n)}function Ho(e,t,n){(t!=="number"||qi(e.ownerDocument)!==e)&&(n==null?e.defaultValue=""+e._wrapperState.initialValue:e.defaultValue!==""+n&&(e.defaultValue=""+n))}var xr=Array.isArray;function Bn(e,t,n,r){if(e=e.options,t){t={};for(var i=0;i"+t.valueOf().toString()+"",t=yi.firstChild;e.firstChild;)e.removeChild(e.firstChild);for(;t.firstChild;)e.appendChild(t.firstChild)}});function _r(e,t){if(t){var n=e.firstChild;if(n&&n===e.lastChild&&n.nodeType===3){n.nodeValue=t;return}}e.textContent=t}var jr={animationIterationCount:!0,aspectRatio:!0,borderImageOutset:!0,borderImageSlice:!0,borderImageWidth:!0,boxFlex:!0,boxFlexGroup:!0,boxOrdinalGroup:!0,columnCount:!0,columns:!0,flex:!0,flexGrow:!0,flexPositive:!0,flexShrink:!0,flexNegative:!0,flexOrder:!0,gridArea:!0,gridRow:!0,gridRowEnd:!0,gridRowSpan:!0,gridRowStart:!0,gridColumn:!0,gridColumnEnd:!0,gridColumnSpan:!0,gridColumnStart:!0,fontWeight:!0,lineClamp:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,tabSize:!0,widows:!0,zIndex:!0,zoom:!0,fillOpacity:!0,floodOpacity:!0,stopOpacity:!0,strokeDasharray:!0,strokeDashoffset:!0,strokeMiterlimit:!0,strokeOpacity:!0,strokeWidth:!0},Om=["Webkit","ms","Moz","O"];Object.keys(jr).forEach(function(e){Om.forEach(function(t){t=t+e.charAt(0).toUpperCase()+e.substring(1),jr[t]=jr[e]})});function Tf(e,t,n){return t==null||typeof t=="boolean"||t===""?"":n||typeof t!="number"||t===0||jr.hasOwnProperty(e)&&jr[e]?(""+t).trim():t+"px"}function Nf(e,t){e=e.style;for(var n in t)if(t.hasOwnProperty(n)){var r=n.indexOf("--")===0,i=Tf(n,t[n],r);n==="float"&&(n="cssFloat"),r?e.setProperty(n,i):e[n]=i}}var Bm=q({menuitem:!0},{area:!0,base:!0,br:!0,col:!0,embed:!0,hr:!0,img:!0,input:!0,keygen:!0,link:!0,meta:!0,param:!0,source:!0,track:!0,wbr:!0});function Yo(e,t){if(t){if(Bm[e]&&(t.children!=null||t.dangerouslySetInnerHTML!=null))throw Error(P(137,e));if(t.dangerouslySetInnerHTML!=null){if(t.children!=null)throw Error(P(60));if(typeof t.dangerouslySetInnerHTML!="object"||!("__html"in t.dangerouslySetInnerHTML))throw Error(P(61))}if(t.style!=null&&typeof t.style!="object")throw Error(P(62))}}function Qo(e,t){if(e.indexOf("-")===-1)return typeof t.is=="string";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 Xo=null;function al(e){return e=e.target||e.srcElement||window,e.correspondingUseElement&&(e=e.correspondingUseElement),e.nodeType===3?e.parentNode:e}var Zo=null,zn=null,Un=null;function _u(e){if(e=li(e)){if(typeof Zo!="function")throw Error(P(280));var t=e.stateNode;t&&(t=Rs(t),Zo(e.stateNode,e.type,t))}}function Pf(e){zn?Un?Un.push(e):Un=[e]:zn=e}function Ef(){if(zn){var e=zn,t=Un;if(Un=zn=null,_u(e),t)for(e=0;e>>=0,e===0?32:31-(Zm(e)/qm|0)|0}var vi=64,xi=4194304;function wr(e){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: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 e&4194240;case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:return e&130023424;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 1073741824;default:return e}}function ns(e,t){var n=e.pendingLanes;if(n===0)return 0;var r=0,i=e.suspendedLanes,s=e.pingedLanes,o=n&268435455;if(o!==0){var a=o&~i;a!==0?r=wr(a):(s&=o,s!==0&&(r=wr(s)))}else o=n&~i,o!==0?r=wr(o):s!==0&&(r=wr(s));if(r===0)return 0;if(t!==0&&t!==r&&!(t&i)&&(i=r&-r,s=t&-t,i>=s||i===16&&(s&4194240)!==0))return t;if(r&4&&(r|=n&16),t=e.entangledLanes,t!==0)for(e=e.entanglements,t&=r;0n;n++)t.push(e);return t}function oi(e,t,n){e.pendingLanes|=t,t!==536870912&&(e.suspendedLanes=0,e.pingedLanes=0),e=e.eventTimes,t=31-nt(t),e[t]=n}function ng(e,t){var n=e.pendingLanes&~t;e.pendingLanes=t,e.suspendedLanes=0,e.pingedLanes=0,e.expiredLanes&=t,e.mutableReadLanes&=t,e.entangledLanes&=t,t=e.entanglements;var r=e.eventTimes;for(e=e.expirationTimes;0=Tr),Ku=" ",Gu=!1;function Yf(e,t){switch(e){case"keyup":return Lg.indexOf(t.keyCode)!==-1;case"keydown":return t.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function Qf(e){return e=e.detail,typeof e=="object"&&"data"in e?e.data:null}var Tn=!1;function Ag(e,t){switch(e){case"compositionend":return Qf(t);case"keypress":return t.which!==32?null:(Gu=!0,Ku);case"textInput":return e=t.data,e===Ku&&Gu?null:e;default:return null}}function Rg(e,t){if(Tn)return e==="compositionend"||!ml&&Yf(e,t)?(e=Kf(),Oi=fl=Rt=null,Tn=!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)return{node:n,offset:t-e};e=r}e:{for(;n;){if(n.nextSibling){n=n.nextSibling;break e}n=n.parentNode}n=void 0}n=Zu(n)}}function Jf(e,t){return e&&t?e===t?!0:e&&e.nodeType===3?!1:t&&t.nodeType===3?Jf(e,t.parentNode):"contains"in e?e.contains(t):e.compareDocumentPosition?!!(e.compareDocumentPosition(t)&16):!1:!1}function eh(){for(var e=window,t=qi();t instanceof e.HTMLIFrameElement;){try{var n=typeof t.contentWindow.location.href=="string"}catch{n=!1}if(n)e=t.contentWindow;else break;t=qi(e.document)}return t}function gl(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")}function Ug(e){var t=eh(),n=e.focusedElem,r=e.selectionRange;if(t!==n&&n&&n.ownerDocument&&Jf(n.ownerDocument.documentElement,n)){if(r!==null&&gl(n)){if(t=r.start,e=r.end,e===void 0&&(e=t),"selectionStart"in n)n.selectionStart=t,n.selectionEnd=Math.min(e,n.value.length);else if(e=(t=n.ownerDocument||document)&&t.defaultView||window,e.getSelection){e=e.getSelection();var i=n.textContent.length,s=Math.min(r.start,i);r=r.end===void 0?s:Math.min(r.end,i),!e.extend&&s>r&&(i=r,r=s,s=i),i=qu(n,s);var o=qu(n,r);i&&o&&(e.rangeCount!==1||e.anchorNode!==i.node||e.anchorOffset!==i.offset||e.focusNode!==o.node||e.focusOffset!==o.offset)&&(t=t.createRange(),t.setStart(i.node,i.offset),e.removeAllRanges(),s>r?(e.addRange(t),e.extend(o.node,o.offset)):(t.setEnd(o.node,o.offset),e.addRange(t)))}}for(t=[],e=n;e=e.parentNode;)e.nodeType===1&&t.push({element:e,left:e.scrollLeft,top:e.scrollTop});for(typeof n.focus=="function"&&n.focus(),n=0;n=document.documentMode,Nn=null,ra=null,Pr=null,ia=!1;function Ju(e,t,n){var r=n.window===n?n.document:n.nodeType===9?n:n.ownerDocument;ia||Nn==null||Nn!==qi(r)||(r=Nn,"selectionStart"in r&&gl(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}),Pr&&Wr(Pr,r)||(Pr=r,r=ss(ra,"onSelect"),0Mn||(e.current=ca[Mn],ca[Mn]=null,Mn--)}function z(e,t){Mn++,ca[Mn]=e.current,e.current=t}var $t={},Se=Yt($t),De=Yt(!1),hn=$t;function Yn(e,t){var n=e.type.contextTypes;if(!n)return $t;var r=e.stateNode;if(r&&r.__reactInternalMemoizedUnmaskedChildContext===t)return r.__reactInternalMemoizedMaskedChildContext;var i={},s;for(s in n)i[s]=t[s];return r&&(e=e.stateNode,e.__reactInternalMemoizedUnmaskedChildContext=t,e.__reactInternalMemoizedMaskedChildContext=i),i}function Ae(e){return e=e.childContextTypes,e!=null}function as(){$(De),$(Se)}function oc(e,t,n){if(Se.current!==$t)throw Error(P(168));z(Se,t),z(De,n)}function uh(e,t,n){var r=e.stateNode;if(t=t.childContextTypes,typeof r.getChildContext!="function")return n;r=r.getChildContext();for(var i in r)if(!(i in t))throw Error(P(108,_m(e)||"Unknown",i));return q({},n,r)}function ls(e){return e=(e=e.stateNode)&&e.__reactInternalMemoizedMergedChildContext||$t,hn=Se.current,z(Se,e),z(De,De.current),!0}function ac(e,t,n){var r=e.stateNode;if(!r)throw Error(P(169));n?(e=uh(e,t,hn),r.__reactInternalMemoizedMergedChildContext=e,$(De),$(Se),z(Se,e)):$(De),z(De,n)}var gt=null,Vs=!1,fo=!1;function ch(e){gt===null?gt=[e]:gt.push(e)}function ey(e){Vs=!0,ch(e)}function Qt(){if(!fo&>!==null){fo=!0;var e=0,t=O;try{var n=gt;for(O=1;e>=o,i-=o,yt=1<<32-nt(t)+i|n<C?(b=N,N=null):b=N.sibling;var L=f(m,N,g[C],w);if(L===null){N===null&&(N=b);break}e&&N&&L.alternate===null&&t(m,N),p=s(L,p,C),j===null?k=L:j.sibling=L,j=L,N=b}if(C===g.length)return n(m,N),K&&en(m,C),k;if(N===null){for(;CC?(b=N,N=null):b=N.sibling;var J=f(m,N,L.value,w);if(J===null){N===null&&(N=b);break}e&&N&&J.alternate===null&&t(m,N),p=s(J,p,C),j===null?k=J:j.sibling=J,j=J,N=b}if(L.done)return n(m,N),K&&en(m,C),k;if(N===null){for(;!L.done;C++,L=g.next())L=h(m,L.value,w),L!==null&&(p=s(L,p,C),j===null?k=L:j.sibling=L,j=L);return K&&en(m,C),k}for(N=r(m,N);!L.done;C++,L=g.next())L=v(N,m,C,L.value,w),L!==null&&(e&&L.alternate!==null&&N.delete(L.key===null?C:L.key),p=s(L,p,C),j===null?k=L:j.sibling=L,j=L);return e&&N.forEach(function(Be){return t(m,Be)}),K&&en(m,C),k}function T(m,p,g,w){if(typeof g=="object"&&g!==null&&g.type===Cn&&g.key===null&&(g=g.props.children),typeof g=="object"&&g!==null){switch(g.$$typeof){case mi:e:{for(var k=g.key,j=p;j!==null;){if(j.key===k){if(k=g.type,k===Cn){if(j.tag===7){n(m,j.sibling),p=i(j,g.props.children),p.return=m,m=p;break e}}else if(j.elementType===k||typeof k=="object"&&k!==null&&k.$$typeof===Mt&&cc(k)===j.type){n(m,j.sibling),p=i(j,g.props),p.ref=pr(m,j,g),p.return=m,m=p;break e}n(m,j);break}else t(m,j);j=j.sibling}g.type===Cn?(p=cn(g.props.children,m.mode,w,g.key),p.return=m,m=p):(w=Gi(g.type,g.key,g.props,null,m.mode,w),w.ref=pr(m,p,g),w.return=m,m=w)}return o(m);case jn:e:{for(j=g.key;p!==null;){if(p.key===j)if(p.tag===4&&p.stateNode.containerInfo===g.containerInfo&&p.stateNode.implementation===g.implementation){n(m,p.sibling),p=i(p,g.children||[]),p.return=m,m=p;break e}else{n(m,p);break}else t(m,p);p=p.sibling}p=wo(g,m.mode,w),p.return=m,m=p}return o(m);case Mt:return j=g._init,T(m,p,j(g._payload),w)}if(xr(g))return x(m,p,g,w);if(ur(g))return y(m,p,g,w);Ni(m,g)}return typeof g=="string"&&g!==""||typeof g=="number"?(g=""+g,p!==null&&p.tag===6?(n(m,p.sibling),p=i(p,g),p.return=m,m=p):(n(m,p),p=xo(g,m.mode,w),p.return=m,m=p),o(m)):n(m,p)}return T}var Xn=ph(!0),mh=ph(!1),ds=Yt(null),fs=null,An=null,wl=null;function kl(){wl=An=fs=null}function Sl(e){var t=ds.current;$(ds),e._currentValue=t}function ha(e,t,n){for(;e!==null;){var r=e.alternate;if((e.childLanes&t)!==t?(e.childLanes|=t,r!==null&&(r.childLanes|=t)):r!==null&&(r.childLanes&t)!==t&&(r.childLanes|=t),e===n)break;e=e.return}}function $n(e,t){fs=e,wl=An=null,e=e.dependencies,e!==null&&e.firstContext!==null&&(e.lanes&t&&(Me=!0),e.firstContext=null)}function Ye(e){var t=e._currentValue;if(wl!==e)if(e={context:e,memoizedValue:t,next:null},An===null){if(fs===null)throw Error(P(308));An=e,fs.dependencies={lanes:0,firstContext:e}}else An=An.next=e;return t}var sn=null;function jl(e){sn===null?sn=[e]:sn.push(e)}function gh(e,t,n,r){var i=t.interleaved;return i===null?(n.next=n,jl(t)):(n.next=i.next,i.next=n),t.interleaved=n,St(e,r)}function St(e,t){e.lanes|=t;var n=e.alternate;for(n!==null&&(n.lanes|=t),n=e,e=e.return;e!==null;)e.childLanes|=t,n=e.alternate,n!==null&&(n.childLanes|=t),n=e,e=e.return;return n.tag===3?n.stateNode:null}var Lt=!1;function Cl(e){e.updateQueue={baseState:e.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,interleaved:null,lanes:0},effects:null}}function yh(e,t){e=e.updateQueue,t.updateQueue===e&&(t.updateQueue={baseState:e.baseState,firstBaseUpdate:e.firstBaseUpdate,lastBaseUpdate:e.lastBaseUpdate,shared:e.shared,effects:e.effects})}function xt(e,t){return{eventTime:e,lane:t,tag:0,payload:null,callback:null,next:null}}function Ot(e,t,n){var r=e.updateQueue;if(r===null)return null;if(r=r.shared,F&2){var i=r.pending;return i===null?t.next=t:(t.next=i.next,i.next=t),r.pending=t,St(e,n)}return i=r.interleaved,i===null?(t.next=t,jl(r)):(t.next=i.next,i.next=t),r.interleaved=t,St(e,n)}function zi(e,t,n){if(t=t.updateQueue,t!==null&&(t=t.shared,(n&4194240)!==0)){var r=t.lanes;r&=e.pendingLanes,n|=r,t.lanes=n,ul(e,n)}}function dc(e,t){var n=e.updateQueue,r=e.alternate;if(r!==null&&(r=r.updateQueue,n===r)){var i=null,s=null;if(n=n.firstBaseUpdate,n!==null){do{var o={eventTime:n.eventTime,lane:n.lane,tag:n.tag,payload:n.payload,callback:n.callback,next:null};s===null?i=s=o:s=s.next=o,n=n.next}while(n!==null);s===null?i=s=t:s=s.next=t}else i=s=t;n={baseState:r.baseState,firstBaseUpdate:i,lastBaseUpdate:s,shared:r.shared,effects:r.effects},e.updateQueue=n;return}e=n.lastBaseUpdate,e===null?n.firstBaseUpdate=t:e.next=t,n.lastBaseUpdate=t}function hs(e,t,n,r){var i=e.updateQueue;Lt=!1;var s=i.firstBaseUpdate,o=i.lastBaseUpdate,a=i.shared.pending;if(a!==null){i.shared.pending=null;var l=a,u=l.next;l.next=null,o===null?s=u:o.next=u,o=l;var c=e.alternate;c!==null&&(c=c.updateQueue,a=c.lastBaseUpdate,a!==o&&(a===null?c.firstBaseUpdate=u:a.next=u,c.lastBaseUpdate=l))}if(s!==null){var h=i.baseState;o=0,c=u=l=null,a=s;do{var f=a.lane,v=a.eventTime;if((r&f)===f){c!==null&&(c=c.next={eventTime:v,lane:0,tag:a.tag,payload:a.payload,callback:a.callback,next:null});e:{var x=e,y=a;switch(f=t,v=n,y.tag){case 1:if(x=y.payload,typeof x=="function"){h=x.call(v,h,f);break e}h=x;break e;case 3:x.flags=x.flags&-65537|128;case 0:if(x=y.payload,f=typeof x=="function"?x.call(v,h,f):x,f==null)break e;h=q({},h,f);break e;case 2:Lt=!0}}a.callback!==null&&a.lane!==0&&(e.flags|=64,f=i.effects,f===null?i.effects=[a]:f.push(a))}else v={eventTime:v,lane:f,tag:a.tag,payload:a.payload,callback:a.callback,next:null},c===null?(u=c=v,l=h):c=c.next=v,o|=f;if(a=a.next,a===null){if(a=i.shared.pending,a===null)break;f=a,a=f.next,f.next=null,i.lastBaseUpdate=f,i.shared.pending=null}}while(!0);if(c===null&&(l=h),i.baseState=l,i.firstBaseUpdate=u,i.lastBaseUpdate=c,t=i.shared.interleaved,t!==null){i=t;do o|=i.lane,i=i.next;while(i!==t)}else s===null&&(i.shared.lanes=0);gn|=o,e.lanes=o,e.memoizedState=h}}function fc(e,t,n){if(e=t.effects,t.effects=null,e!==null)for(t=0;tn?n:4,e(!0);var r=po.transition;po.transition={};try{e(!1),t()}finally{O=n,po.transition=r}}function Vh(){return Qe().memoizedState}function iy(e,t,n){var r=zt(e);if(n={lane:r,action:n,hasEagerState:!1,eagerState:null,next:null},bh(e))Ih(t,n);else if(n=gh(e,t,n,r),n!==null){var i=Te();rt(n,e,r,i),_h(n,t,r)}}function sy(e,t,n){var r=zt(e),i={lane:r,action:n,hasEagerState:!1,eagerState:null,next:null};if(bh(e))Ih(t,i);else{var s=e.alternate;if(e.lanes===0&&(s===null||s.lanes===0)&&(s=t.lastRenderedReducer,s!==null))try{var o=t.lastRenderedState,a=s(o,n);if(i.hasEagerState=!0,i.eagerState=a,it(a,o)){var l=t.interleaved;l===null?(i.next=i,jl(t)):(i.next=l.next,l.next=i),t.interleaved=i;return}}catch{}finally{}n=gh(e,t,i,r),n!==null&&(i=Te(),rt(n,e,r,i),_h(n,t,r))}}function bh(e){var t=e.alternate;return e===Z||t!==null&&t===Z}function Ih(e,t){Er=ms=!0;var n=e.pending;n===null?t.next=t:(t.next=n.next,n.next=t),e.pending=t}function _h(e,t,n){if(n&4194240){var r=t.lanes;r&=e.pendingLanes,n|=r,t.lanes=n,ul(e,n)}}var gs={readContext:Ye,useCallback:ye,useContext:ye,useEffect:ye,useImperativeHandle:ye,useInsertionEffect:ye,useLayoutEffect:ye,useMemo:ye,useReducer:ye,useRef:ye,useState:ye,useDebugValue:ye,useDeferredValue:ye,useTransition:ye,useMutableSource:ye,useSyncExternalStore:ye,useId:ye,unstable_isNewReconciler:!1},oy={readContext:Ye,useCallback:function(e,t){return ot().memoizedState=[e,t===void 0?null:t],e},useContext:Ye,useEffect:pc,useImperativeHandle:function(e,t,n){return n=n!=null?n.concat([e]):null,Wi(4194308,4,Mh.bind(null,t,e),n)},useLayoutEffect:function(e,t){return Wi(4194308,4,e,t)},useInsertionEffect:function(e,t){return Wi(4,2,e,t)},useMemo:function(e,t){var n=ot();return t=t===void 0?null:t,e=e(),n.memoizedState=[e,t],e},useReducer:function(e,t,n){var r=ot();return t=n!==void 0?n(t):t,r.memoizedState=r.baseState=t,e={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:e,lastRenderedState:t},r.queue=e,e=e.dispatch=iy.bind(null,Z,e),[r.memoizedState,e]},useRef:function(e){var t=ot();return e={current:e},t.memoizedState=e},useState:hc,useDebugValue:Al,useDeferredValue:function(e){return ot().memoizedState=e},useTransition:function(){var e=hc(!1),t=e[0];return e=ry.bind(null,e[1]),ot().memoizedState=e,[t,e]},useMutableSource:function(){},useSyncExternalStore:function(e,t,n){var r=Z,i=ot();if(K){if(n===void 0)throw Error(P(407));n=n()}else{if(n=t(),ce===null)throw Error(P(349));mn&30||kh(r,t,n)}i.memoizedState=n;var s={value:n,getSnapshot:t};return i.queue=s,pc(jh.bind(null,r,s,e),[e]),r.flags|=2048,Zr(9,Sh.bind(null,r,s,n,t),void 0,null),n},useId:function(){var e=ot(),t=ce.identifierPrefix;if(K){var n=vt,r=yt;n=(r&~(1<<32-nt(r)-1)).toString(32)+n,t=":"+t+"R"+n,n=Qr++,0<\/script>",e=e.removeChild(e.firstChild)):typeof r.is=="string"?e=o.createElement(n,{is:r.is}):(e=o.createElement(n),n==="select"&&(o=e,r.multiple?o.multiple=!0:r.size&&(o.size=r.size))):e=o.createElementNS(e,n),e[at]=t,e[Kr]=r,Gh(e,t,!1,!1),t.stateNode=e;e:{switch(o=Qo(n,r),n){case"dialog":W("cancel",e),W("close",e),i=r;break;case"iframe":case"object":case"embed":W("load",e),i=r;break;case"video":case"audio":for(i=0;iJn&&(t.flags|=128,r=!0,mr(s,!1),t.lanes=4194304)}else{if(!r)if(e=ps(o),e!==null){if(t.flags|=128,r=!0,n=e.updateQueue,n!==null&&(t.updateQueue=n,t.flags|=4),mr(s,!0),s.tail===null&&s.tailMode==="hidden"&&!o.alternate&&!K)return ve(t),null}else 2*ne()-s.renderingStartTime>Jn&&n!==1073741824&&(t.flags|=128,r=!0,mr(s,!1),t.lanes=4194304);s.isBackwards?(o.sibling=t.child,t.child=o):(n=s.last,n!==null?n.sibling=o:t.child=o,s.last=o)}return s.tail!==null?(t=s.tail,s.rendering=t,s.tail=t.sibling,s.renderingStartTime=ne(),t.sibling=null,n=Q.current,z(Q,r?n&1|2:n&1),t):(ve(t),null);case 22:case 23:return Fl(),r=t.memoizedState!==null,e!==null&&e.memoizedState!==null!==r&&(t.flags|=8192),r&&t.mode&1?Ve&1073741824&&(ve(t),t.subtreeFlags&6&&(t.flags|=8192)):ve(t),null;case 24:return null;case 25:return null}throw Error(P(156,t.tag))}function py(e,t){switch(vl(t),t.tag){case 1:return Ae(t.type)&&as(),e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 3:return Zn(),$(De),$(Se),Pl(),e=t.flags,e&65536&&!(e&128)?(t.flags=e&-65537|128,t):null;case 5:return Nl(t),null;case 13:if($(Q),e=t.memoizedState,e!==null&&e.dehydrated!==null){if(t.alternate===null)throw Error(P(340));Qn()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 19:return $(Q),null;case 4:return Zn(),null;case 10:return Sl(t.type._context),null;case 22:case 23:return Fl(),null;case 24:return null;default:return null}}var Ei=!1,xe=!1,my=typeof WeakSet=="function"?WeakSet:Set,M=null;function Rn(e,t){var n=e.ref;if(n!==null)if(typeof n=="function")try{n(null)}catch(r){te(e,t,r)}else n.current=null}function Sa(e,t,n){try{n()}catch(r){te(e,t,r)}}var Tc=!1;function gy(e,t){if(sa=rs,e=eh(),gl(e)){if("selectionStart"in e)var n={start:e.selectionStart,end:e.selectionEnd};else e:{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,s=r.focusNode;r=r.focusOffset;try{n.nodeType,s.nodeType}catch{n=null;break e}var o=0,a=-1,l=-1,u=0,c=0,h=e,f=null;t:for(;;){for(var v;h!==n||i!==0&&h.nodeType!==3||(a=o+i),h!==s||r!==0&&h.nodeType!==3||(l=o+r),h.nodeType===3&&(o+=h.nodeValue.length),(v=h.firstChild)!==null;)f=h,h=v;for(;;){if(h===e)break t;if(f===n&&++u===i&&(a=o),f===s&&++c===r&&(l=o),(v=h.nextSibling)!==null)break;h=f,f=h.parentNode}h=v}n=a===-1||l===-1?null:{start:a,end:l}}else n=null}n=n||{start:0,end:0}}else n=null;for(oa={focusedElem:e,selectionRange:n},rs=!1,M=t;M!==null;)if(t=M,e=t.child,(t.subtreeFlags&1028)!==0&&e!==null)e.return=t,M=e;else for(;M!==null;){t=M;try{var x=t.alternate;if(t.flags&1024)switch(t.tag){case 0:case 11:case 15:break;case 1:if(x!==null){var y=x.memoizedProps,T=x.memoizedState,m=t.stateNode,p=m.getSnapshotBeforeUpdate(t.elementType===t.type?y:Je(t.type,y),T);m.__reactInternalSnapshotBeforeUpdate=p}break;case 3:var g=t.stateNode.containerInfo;g.nodeType===1?g.textContent="":g.nodeType===9&&g.documentElement&&g.removeChild(g.documentElement);break;case 5:case 6:case 4:case 17:break;default:throw Error(P(163))}}catch(w){te(t,t.return,w)}if(e=t.sibling,e!==null){e.return=t.return,M=e;break}M=t.return}return x=Tc,Tc=!1,x}function Mr(e,t,n){var r=t.updateQueue;if(r=r!==null?r.lastEffect:null,r!==null){var i=r=r.next;do{if((i.tag&e)===e){var s=i.destroy;i.destroy=void 0,s!==void 0&&Sa(t,n,s)}i=i.next}while(i!==r)}}function _s(e,t){if(t=t.updateQueue,t=t!==null?t.lastEffect:null,t!==null){var n=t=t.next;do{if((n.tag&e)===e){var r=n.create;n.destroy=r()}n=n.next}while(n!==t)}}function ja(e){var t=e.ref;if(t!==null){var n=e.stateNode;switch(e.tag){case 5:e=n;break;default:e=n}typeof t=="function"?t(e):t.current=e}}function Xh(e){var t=e.alternate;t!==null&&(e.alternate=null,Xh(t)),e.child=null,e.deletions=null,e.sibling=null,e.tag===5&&(t=e.stateNode,t!==null&&(delete t[at],delete t[Kr],delete t[ua],delete t[qg],delete t[Jg])),e.stateNode=null,e.return=null,e.dependencies=null,e.memoizedProps=null,e.memoizedState=null,e.pendingProps=null,e.stateNode=null,e.updateQueue=null}function Zh(e){return e.tag===5||e.tag===3||e.tag===4}function Nc(e){e:for(;;){for(;e.sibling===null;){if(e.return===null||Zh(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.flags&2||e.child===null||e.tag===4)continue e;e.child.return=e,e=e.child}if(!(e.flags&2))return e.stateNode}}function Ca(e,t,n){var r=e.tag;if(r===5||r===6)e=e.stateNode,t?n.nodeType===8?n.parentNode.insertBefore(e,t):n.insertBefore(e,t):(n.nodeType===8?(t=n.parentNode,t.insertBefore(e,n)):(t=n,t.appendChild(e)),n=n._reactRootContainer,n!=null||t.onclick!==null||(t.onclick=os));else if(r!==4&&(e=e.child,e!==null))for(Ca(e,t,n),e=e.sibling;e!==null;)Ca(e,t,n),e=e.sibling}function Ta(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&&(e=e.child,e!==null))for(Ta(e,t,n),e=e.sibling;e!==null;)Ta(e,t,n),e=e.sibling}var fe=null,et=!1;function Pt(e,t,n){for(n=n.child;n!==null;)qh(e,t,n),n=n.sibling}function qh(e,t,n){if(lt&&typeof lt.onCommitFiberUnmount=="function")try{lt.onCommitFiberUnmount(Ms,n)}catch{}switch(n.tag){case 5:xe||Rn(n,t);case 6:var r=fe,i=et;fe=null,Pt(e,t,n),fe=r,et=i,fe!==null&&(et?(e=fe,n=n.stateNode,e.nodeType===8?e.parentNode.removeChild(n):e.removeChild(n)):fe.removeChild(n.stateNode));break;case 18:fe!==null&&(et?(e=fe,n=n.stateNode,e.nodeType===8?co(e.parentNode,n):e.nodeType===1&&co(e,n),zr(e)):co(fe,n.stateNode));break;case 4:r=fe,i=et,fe=n.stateNode.containerInfo,et=!0,Pt(e,t,n),fe=r,et=i;break;case 0:case 11:case 14:case 15:if(!xe&&(r=n.updateQueue,r!==null&&(r=r.lastEffect,r!==null))){i=r=r.next;do{var s=i,o=s.destroy;s=s.tag,o!==void 0&&(s&2||s&4)&&Sa(n,t,o),i=i.next}while(i!==r)}Pt(e,t,n);break;case 1:if(!xe&&(Rn(n,t),r=n.stateNode,typeof r.componentWillUnmount=="function"))try{r.props=n.memoizedProps,r.state=n.memoizedState,r.componentWillUnmount()}catch(a){te(n,t,a)}Pt(e,t,n);break;case 21:Pt(e,t,n);break;case 22:n.mode&1?(xe=(r=xe)||n.memoizedState!==null,Pt(e,t,n),xe=r):Pt(e,t,n);break;default:Pt(e,t,n)}}function Pc(e){var t=e.updateQueue;if(t!==null){e.updateQueue=null;var n=e.stateNode;n===null&&(n=e.stateNode=new my),t.forEach(function(r){var i=Ty.bind(null,e,r);n.has(r)||(n.add(r),r.then(i,i))})}}function Xe(e,t){var n=t.deletions;if(n!==null)for(var r=0;ri&&(i=o),r&=~s}if(r=i,r=ne()-r,r=(120>r?120:480>r?480:1080>r?1080:1920>r?1920:3e3>r?3e3:4320>r?4320:1960*vy(r/1960))-r,10e?16:e,Vt===null)var r=!1;else{if(e=Vt,Vt=null,xs=0,F&6)throw Error(P(331));var i=F;for(F|=4,M=e.current;M!==null;){var s=M,o=s.child;if(M.flags&16){var a=s.deletions;if(a!==null){for(var l=0;lne()-Il?un(e,0):bl|=n),Re(e,t)}function op(e,t){t===0&&(e.mode&1?(t=xi,xi<<=1,!(xi&130023424)&&(xi=4194304)):t=1);var n=Te();e=St(e,t),e!==null&&(oi(e,t,n),Re(e,n))}function Cy(e){var t=e.memoizedState,n=0;t!==null&&(n=t.retryLane),op(e,n)}function Ty(e,t){var n=0;switch(e.tag){case 13:var r=e.stateNode,i=e.memoizedState;i!==null&&(n=i.retryLane);break;case 19:r=e.stateNode;break;default:throw Error(P(314))}r!==null&&r.delete(t),op(e,n)}var ap;ap=function(e,t,n){if(e!==null)if(e.memoizedProps!==t.pendingProps||De.current)Me=!0;else{if(!(e.lanes&n)&&!(t.flags&128))return Me=!1,fy(e,t,n);Me=!!(e.flags&131072)}else Me=!1,K&&t.flags&1048576&&dh(t,cs,t.index);switch(t.lanes=0,t.tag){case 2:var r=t.type;$i(e,t),e=t.pendingProps;var i=Yn(t,Se.current);$n(t,n),i=Ml(null,t,r,e,i,n);var s=Ll();return t.flags|=1,typeof i=="object"&&i!==null&&typeof i.render=="function"&&i.$$typeof===void 0?(t.tag=1,t.memoizedState=null,t.updateQueue=null,Ae(r)?(s=!0,ls(t)):s=!1,t.memoizedState=i.state!==null&&i.state!==void 0?i.state:null,Cl(t),i.updater=Is,t.stateNode=i,i._reactInternals=t,ma(t,r,e,n),t=va(null,t,r,!0,s,n)):(t.tag=0,K&&s&&yl(t),je(null,t,i,n),t=t.child),t;case 16:r=t.elementType;e:{switch($i(e,t),e=t.pendingProps,i=r._init,r=i(r._payload),t.type=r,i=t.tag=Py(r),e=Je(r,e),i){case 0:t=ya(null,t,r,e,n);break e;case 1:t=Sc(null,t,r,e,n);break e;case 11:t=wc(null,t,r,e,n);break e;case 14:t=kc(null,t,r,Je(r.type,e),n);break e}throw Error(P(306,r,""))}return t;case 0:return r=t.type,i=t.pendingProps,i=t.elementType===r?i:Je(r,i),ya(e,t,r,i,n);case 1:return r=t.type,i=t.pendingProps,i=t.elementType===r?i:Je(r,i),Sc(e,t,r,i,n);case 3:e:{if($h(t),e===null)throw Error(P(387));r=t.pendingProps,s=t.memoizedState,i=s.element,yh(e,t),hs(t,r,null,n);var o=t.memoizedState;if(r=o.element,s.isDehydrated)if(s={element:r,isDehydrated:!1,cache:o.cache,pendingSuspenseBoundaries:o.pendingSuspenseBoundaries,transitions:o.transitions},t.updateQueue.baseState=s,t.memoizedState=s,t.flags&256){i=qn(Error(P(423)),t),t=jc(e,t,r,n,i);break e}else if(r!==i){i=qn(Error(P(424)),t),t=jc(e,t,r,n,i);break e}else for(be=Ft(t.stateNode.containerInfo.firstChild),Ie=t,K=!0,tt=null,n=mh(t,null,r,n),t.child=n;n;)n.flags=n.flags&-3|4096,n=n.sibling;else{if(Qn(),r===i){t=jt(e,t,n);break e}je(e,t,r,n)}t=t.child}return t;case 5:return vh(t),e===null&&fa(t),r=t.type,i=t.pendingProps,s=e!==null?e.memoizedProps:null,o=i.children,aa(r,i)?o=null:s!==null&&aa(r,s)&&(t.flags|=32),Wh(e,t),je(e,t,o,n),t.child;case 6:return e===null&&fa(t),null;case 13:return Hh(e,t,n);case 4:return Tl(t,t.stateNode.containerInfo),r=t.pendingProps,e===null?t.child=Xn(t,null,r,n):je(e,t,r,n),t.child;case 11:return r=t.type,i=t.pendingProps,i=t.elementType===r?i:Je(r,i),wc(e,t,r,i,n);case 7:return je(e,t,t.pendingProps,n),t.child;case 8:return je(e,t,t.pendingProps.children,n),t.child;case 12:return je(e,t,t.pendingProps.children,n),t.child;case 10:e:{if(r=t.type._context,i=t.pendingProps,s=t.memoizedProps,o=i.value,z(ds,r._currentValue),r._currentValue=o,s!==null)if(it(s.value,o)){if(s.children===i.children&&!De.current){t=jt(e,t,n);break e}}else for(s=t.child,s!==null&&(s.return=t);s!==null;){var a=s.dependencies;if(a!==null){o=s.child;for(var l=a.firstContext;l!==null;){if(l.context===r){if(s.tag===1){l=xt(-1,n&-n),l.tag=2;var u=s.updateQueue;if(u!==null){u=u.shared;var c=u.pending;c===null?l.next=l:(l.next=c.next,c.next=l),u.pending=l}}s.lanes|=n,l=s.alternate,l!==null&&(l.lanes|=n),ha(s.return,n,t),a.lanes|=n;break}l=l.next}}else if(s.tag===10)o=s.type===t.type?null:s.child;else if(s.tag===18){if(o=s.return,o===null)throw Error(P(341));o.lanes|=n,a=o.alternate,a!==null&&(a.lanes|=n),ha(o,n,t),o=s.sibling}else o=s.child;if(o!==null)o.return=s;else for(o=s;o!==null;){if(o===t){o=null;break}if(s=o.sibling,s!==null){s.return=o.return,o=s;break}o=o.return}s=o}je(e,t,i.children,n),t=t.child}return t;case 9:return i=t.type,r=t.pendingProps.children,$n(t,n),i=Ye(i),r=r(i),t.flags|=1,je(e,t,r,n),t.child;case 14:return r=t.type,i=Je(r,t.pendingProps),i=Je(r.type,i),kc(e,t,r,i,n);case 15:return zh(e,t,t.type,t.pendingProps,n);case 17:return r=t.type,i=t.pendingProps,i=t.elementType===r?i:Je(r,i),$i(e,t),t.tag=1,Ae(r)?(e=!0,ls(t)):e=!1,$n(t,n),Fh(t,r,i),ma(t,r,i,n),va(null,t,r,!0,e,n);case 19:return Kh(e,t,n);case 22:return Uh(e,t,n)}throw Error(P(156,t.tag))};function lp(e,t){return bf(e,t)}function Ny(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.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 $e(e,t,n,r){return new Ny(e,t,n,r)}function Bl(e){return e=e.prototype,!(!e||!e.isReactComponent)}function Py(e){if(typeof e=="function")return Bl(e)?1:0;if(e!=null){if(e=e.$$typeof,e===sl)return 11;if(e===ol)return 14}return 2}function Ut(e,t){var n=e.alternate;return n===null?(n=$e(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&14680064,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}function Gi(e,t,n,r,i,s){var o=2;if(r=e,typeof e=="function")Bl(e)&&(o=1);else if(typeof e=="string")o=5;else e:switch(e){case Cn:return cn(n.children,i,s,t);case il:o=8,i|=8;break;case Oo:return e=$e(12,n,t,i|2),e.elementType=Oo,e.lanes=s,e;case Bo:return e=$e(13,n,t,i),e.elementType=Bo,e.lanes=s,e;case zo:return e=$e(19,n,t,i),e.elementType=zo,e.lanes=s,e;case vf:return Os(n,i,s,t);default:if(typeof e=="object"&&e!==null)switch(e.$$typeof){case gf:o=10;break e;case yf:o=9;break e;case sl:o=11;break e;case ol:o=14;break e;case Mt:o=16,r=null;break e}throw Error(P(130,e==null?e:typeof e,""))}return t=$e(o,n,t,i),t.elementType=e,t.type=r,t.lanes=s,t}function cn(e,t,n,r){return e=$e(7,e,r,t),e.lanes=n,e}function Os(e,t,n,r){return e=$e(22,e,r,t),e.elementType=vf,e.lanes=n,e.stateNode={isHidden:!1},e}function xo(e,t,n){return e=$e(6,e,null,t),e.lanes=n,e}function wo(e,t,n){return t=$e(4,e.children!==null?e.children:[],e.key,t),t.lanes=n,t.stateNode={containerInfo:e.containerInfo,pendingChildren:null,implementation:e.implementation},t}function Ey(e,t,n,r,i){this.tag=t,this.containerInfo=e,this.finishedWork=this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.pendingContext=this.context=null,this.callbackPriority=0,this.eventTimes=Js(0),this.expirationTimes=Js(-1),this.entangledLanes=this.finishedLanes=this.mutableReadLanes=this.expiredLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=Js(0),this.identifierPrefix=r,this.onRecoverableError=i,this.mutableSourceEagerHydrationData=null}function zl(e,t,n,r,i,s,o,a,l){return e=new Ey(e,t,n,a,l),t===1?(t=1,s===!0&&(t|=8)):t=0,s=$e(3,null,null,t),e.current=s,s.stateNode=e,s.memoizedState={element:r,isDehydrated:n,cache:null,transitions:null,pendingSuspenseBoundaries:null},Cl(s),e}function My(e,t,n){var r=3"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(fp)}catch(e){console.error(e)}}fp(),ff.exports=Fe;var Vy=ff.exports,bc=Vy;_o.createRoot=bc.createRoot,_o.hydrateRoot=bc.hydrateRoot;const Hl=S.createContext({});function Kl(e){const t=S.useRef(null);return t.current===null&&(t.current=e()),t.current}const Gl=typeof window<"u",hp=Gl?S.useLayoutEffect:S.useEffect,$s=S.createContext(null);function Yl(e,t){e.indexOf(t)===-1&&e.push(t)}function Ql(e,t){const n=e.indexOf(t);n>-1&&e.splice(n,1)}const Ct=(e,t,n)=>n>t?t:n{};const Tt={},pp=e=>/^-?(?:\d+(?:\.\d+)?|\.\d+)$/u.test(e);function mp(e){return typeof e=="object"&&e!==null}const gp=e=>/^0[^.\s]+$/u.test(e);function Zl(e){let t;return()=>(t===void 0&&(t=e()),t)}const Ge=e=>e,by=(e,t)=>n=>t(e(n)),ci=(...e)=>e.reduce(by),Jr=(e,t,n)=>{const r=t-e;return r===0?1:(n-e)/r};class ql{constructor(){this.subscriptions=[]}add(t){return Yl(this.subscriptions,t),()=>Ql(this.subscriptions,t)}notify(t,n,r){const i=this.subscriptions.length;if(i)if(i===1)this.subscriptions[0](t,n,r);else for(let s=0;se*1e3,He=e=>e/1e3;function yp(e,t){return t?e*(1e3/t):0}const vp=(e,t,n)=>(((1-3*n+3*t)*e+(3*n-6*t))*e+3*t)*e,Iy=1e-7,_y=12;function Fy(e,t,n,r,i){let s,o,a=0;do o=t+(n-t)/2,s=vp(o,r,i)-e,s>0?n=o:t=o;while(Math.abs(s)>Iy&&++a<_y);return o}function di(e,t,n,r){if(e===t&&n===r)return Ge;const i=s=>Fy(s,0,1,e,n);return s=>s===0||s===1?s:vp(i(s),t,r)}const xp=e=>t=>t<=.5?e(2*t)/2:(2-e(2*(1-t)))/2,wp=e=>t=>1-e(1-t),kp=di(.33,1.53,.69,.99),Jl=wp(kp),Sp=xp(Jl),jp=e=>(e*=2)<1?.5*Jl(e):.5*(2-Math.pow(2,-10*(e-1))),eu=e=>1-Math.sin(Math.acos(e)),Cp=wp(eu),Tp=xp(eu),Oy=di(.42,0,1,1),By=di(0,0,.58,1),Np=di(.42,0,.58,1),zy=e=>Array.isArray(e)&&typeof e[0]!="number",Pp=e=>Array.isArray(e)&&typeof e[0]=="number",Uy={linear:Ge,easeIn:Oy,easeInOut:Np,easeOut:By,circIn:eu,circInOut:Tp,circOut:Cp,backIn:Jl,backInOut:Sp,backOut:kp,anticipate:jp},Wy=e=>typeof e=="string",Ic=e=>{if(Pp(e)){Xl(e.length===4);const[t,n,r,i]=e;return di(t,n,r,i)}else if(Wy(e))return Uy[e];return e},Di=["setup","read","resolveKeyframes","preUpdate","update","preRender","render","postRender"];function $y(e,t){let n=new Set,r=new Set,i=!1,s=!1;const o=new WeakSet;let a={delta:0,timestamp:0,isProcessing:!1};function l(c){o.has(c)&&(u.schedule(c),e()),c(a)}const u={schedule:(c,h=!1,f=!1)=>{const x=f&&i?n:r;return h&&o.add(c),x.has(c)||x.add(c),c},cancel:c=>{r.delete(c),o.delete(c)},process:c=>{if(a=c,i){s=!0;return}i=!0,[n,r]=[r,n],n.forEach(l),n.clear(),i=!1,s&&(s=!1,u.process(c))}};return u}const Hy=40;function Ep(e,t){let n=!1,r=!0;const i={delta:0,timestamp:0,isProcessing:!1},s=()=>n=!0,o=Di.reduce((g,w)=>(g[w]=$y(s),g),{}),{setup:a,read:l,resolveKeyframes:u,preUpdate:c,update:h,preRender:f,render:v,postRender:x}=o,y=()=>{const g=Tt.useManualTiming?i.timestamp:performance.now();n=!1,Tt.useManualTiming||(i.delta=r?1e3/60:Math.max(Math.min(g-i.timestamp,Hy),1)),i.timestamp=g,i.isProcessing=!0,a.process(i),l.process(i),u.process(i),c.process(i),h.process(i),f.process(i),v.process(i),x.process(i),i.isProcessing=!1,n&&t&&(r=!1,e(y))},T=()=>{n=!0,r=!0,i.isProcessing||e(y)};return{schedule:Di.reduce((g,w)=>{const k=o[w];return g[w]=(j,N=!1,C=!1)=>(n||T(),k.schedule(j,N,C)),g},{}),cancel:g=>{for(let w=0;w(Yi===void 0&&Le.set(he.isProcessing||Tt.useManualTiming?he.timestamp:performance.now()),Yi),set:e=>{Yi=e,queueMicrotask(Ky)}},Mp=e=>t=>typeof t=="string"&&t.startsWith(e),tu=Mp("--"),Gy=Mp("var(--"),nu=e=>Gy(e)?Yy.test(e.split("/*")[0].trim()):!1,Yy=/var\(--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)$/iu,sr={test:e=>typeof e=="number",parse:parseFloat,transform:e=>e},ei={...sr,transform:e=>Ct(0,1,e)},Ai={...sr,default:1},Ar=e=>Math.round(e*1e5)/1e5,ru=/-?(?:\d+(?:\.\d+)?|\.\d+)/gu;function Qy(e){return e==null}const Xy=/^(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))$/iu,iu=(e,t)=>n=>!!(typeof n=="string"&&Xy.test(n)&&n.startsWith(e)||t&&!Qy(n)&&Object.prototype.hasOwnProperty.call(n,t)),Lp=(e,t,n)=>r=>{if(typeof r!="string")return r;const[i,s,o,a]=r.match(ru);return{[e]:parseFloat(i),[t]:parseFloat(s),[n]:parseFloat(o),alpha:a!==void 0?parseFloat(a):1}},Zy=e=>Ct(0,255,e),So={...sr,transform:e=>Math.round(Zy(e))},an={test:iu("rgb","red"),parse:Lp("red","green","blue"),transform:({red:e,green:t,blue:n,alpha:r=1})=>"rgba("+So.transform(e)+", "+So.transform(t)+", "+So.transform(n)+", "+Ar(ei.transform(r))+")"};function qy(e){let t="",n="",r="",i="";return e.length>5?(t=e.substring(1,3),n=e.substring(3,5),r=e.substring(5,7),i=e.substring(7,9)):(t=e.substring(1,2),n=e.substring(2,3),r=e.substring(3,4),i=e.substring(4,5),t+=t,n+=n,r+=r,i+=i),{red:parseInt(t,16),green:parseInt(n,16),blue:parseInt(r,16),alpha:i?parseInt(i,16)/255:1}}const La={test:iu("#"),parse:qy,transform:an.transform},fi=e=>({test:t=>typeof t=="string"&&t.endsWith(e)&&t.split(" ").length===1,parse:parseFloat,transform:t=>`${t}${e}`}),Et=fi("deg"),dt=fi("%"),R=fi("px"),Jy=fi("vh"),e1=fi("vw"),_c={...dt,parse:e=>dt.parse(e)/100,transform:e=>dt.transform(e*100)},bn={test:iu("hsl","hue"),parse:Lp("hue","saturation","lightness"),transform:({hue:e,saturation:t,lightness:n,alpha:r=1})=>"hsla("+Math.round(e)+", "+dt.transform(Ar(t))+", "+dt.transform(Ar(n))+", "+Ar(ei.transform(r))+")"},ie={test:e=>an.test(e)||La.test(e)||bn.test(e),parse:e=>an.test(e)?an.parse(e):bn.test(e)?bn.parse(e):La.parse(e),transform:e=>typeof e=="string"?e:e.hasOwnProperty("red")?an.transform(e):bn.transform(e),getAnimatableNone:e=>{const t=ie.parse(e);return t.alpha=0,ie.transform(t)}},t1=/(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))/giu;function n1(e){var t,n;return isNaN(e)&&typeof e=="string"&&(((t=e.match(ru))==null?void 0:t.length)||0)+(((n=e.match(t1))==null?void 0:n.length)||0)>0}const Dp="number",Ap="color",r1="var",i1="var(",Fc="${}",s1=/var\s*\(\s*--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)|#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\)|-?(?:\d+(?:\.\d+)?|\.\d+)/giu;function ti(e){const t=e.toString(),n=[],r={color:[],number:[],var:[]},i=[];let s=0;const a=t.replace(s1,l=>(ie.test(l)?(r.color.push(s),i.push(Ap),n.push(ie.parse(l))):l.startsWith(i1)?(r.var.push(s),i.push(r1),n.push(l)):(r.number.push(s),i.push(Dp),n.push(parseFloat(l))),++s,Fc)).split(Fc);return{values:n,split:a,indexes:r,types:i}}function Rp(e){return ti(e).values}function Vp(e){const{split:t,types:n}=ti(e),r=t.length;return i=>{let s="";for(let o=0;otypeof e=="number"?0:ie.test(e)?ie.getAnimatableNone(e):e;function a1(e){const t=Rp(e);return Vp(e)(t.map(o1))}const Kt={test:n1,parse:Rp,createTransformer:Vp,getAnimatableNone:a1};function jo(e,t,n){return n<0&&(n+=1),n>1&&(n-=1),n<1/6?e+(t-e)*6*n:n<1/2?t:n<2/3?e+(t-e)*(2/3-n)*6:e}function l1({hue:e,saturation:t,lightness:n,alpha:r}){e/=360,t/=100,n/=100;let i=0,s=0,o=0;if(!t)i=s=o=n;else{const a=n<.5?n*(1+t):n+t-n*t,l=2*n-a;i=jo(l,a,e+1/3),s=jo(l,a,e),o=jo(l,a,e-1/3)}return{red:Math.round(i*255),green:Math.round(s*255),blue:Math.round(o*255),alpha:r}}function Ss(e,t){return n=>n>0?t:e}const X=(e,t,n)=>e+(t-e)*n,Co=(e,t,n)=>{const r=e*e,i=n*(t*t-r)+r;return i<0?0:Math.sqrt(i)},u1=[La,an,bn],c1=e=>u1.find(t=>t.test(e));function Oc(e){const t=c1(e);if(!t)return!1;let n=t.parse(e);return t===bn&&(n=l1(n)),n}const Bc=(e,t)=>{const n=Oc(e),r=Oc(t);if(!n||!r)return Ss(e,t);const i={...n};return s=>(i.red=Co(n.red,r.red,s),i.green=Co(n.green,r.green,s),i.blue=Co(n.blue,r.blue,s),i.alpha=X(n.alpha,r.alpha,s),an.transform(i))},Da=new Set(["none","hidden"]);function d1(e,t){return Da.has(e)?n=>n<=0?e:t:n=>n>=1?t:e}function f1(e,t){return n=>X(e,t,n)}function su(e){return typeof e=="number"?f1:typeof e=="string"?nu(e)?Ss:ie.test(e)?Bc:m1:Array.isArray(e)?bp:typeof e=="object"?ie.test(e)?Bc:h1:Ss}function bp(e,t){const n=[...e],r=n.length,i=e.map((s,o)=>su(s)(s,t[o]));return s=>{for(let o=0;o{for(const s in r)n[s]=r[s](i);return n}}function p1(e,t){const n=[],r={color:0,var:0,number:0};for(let i=0;i{const n=Kt.createTransformer(t),r=ti(e),i=ti(t);return r.indexes.var.length===i.indexes.var.length&&r.indexes.color.length===i.indexes.color.length&&r.indexes.number.length>=i.indexes.number.length?Da.has(e)&&!i.values.length||Da.has(t)&&!r.values.length?d1(e,t):ci(bp(p1(r,i),i.values),n):Ss(e,t)};function Ip(e,t,n){return typeof e=="number"&&typeof t=="number"&&typeof n=="number"?X(e,t,n):su(e)(e,t)}const g1=e=>{const t=({timestamp:n})=>e(n);return{start:(n=!0)=>G.update(t,n),stop:()=>Ht(t),now:()=>he.isProcessing?he.timestamp:Le.now()}},_p=(e,t,n=10)=>{let r="";const i=Math.max(Math.round(t/n),2);for(let s=0;s=js?1/0:t}function y1(e,t=100,n){const r=n({...e,keyframes:[0,t]}),i=Math.min(ou(r),js);return{type:"keyframes",ease:s=>r.next(i*s).value/t,duration:He(i)}}const v1=5;function Fp(e,t,n){const r=Math.max(t-v1,0);return yp(n-e(r),t-r)}const ee={stiffness:100,damping:10,mass:1,velocity:0,duration:800,bounce:.3,visualDuration:.3,restSpeed:{granular:.01,default:2},restDelta:{granular:.005,default:.5},minDuration:.01,maxDuration:10,minDamping:.05,maxDamping:1},To=.001;function x1({duration:e=ee.duration,bounce:t=ee.bounce,velocity:n=ee.velocity,mass:r=ee.mass}){let i,s,o=1-t;o=Ct(ee.minDamping,ee.maxDamping,o),e=Ct(ee.minDuration,ee.maxDuration,He(e)),o<1?(i=u=>{const c=u*o,h=c*e,f=c-n,v=Aa(u,o),x=Math.exp(-h);return To-f/v*x},s=u=>{const h=u*o*e,f=h*n+n,v=Math.pow(o,2)*Math.pow(u,2)*e,x=Math.exp(-h),y=Aa(Math.pow(u,2),o);return(-i(u)+To>0?-1:1)*((f-v)*x)/y}):(i=u=>{const c=Math.exp(-u*e),h=(u-n)*e+1;return-To+c*h},s=u=>{const c=Math.exp(-u*e),h=(n-u)*(e*e);return c*h});const a=5/e,l=k1(i,s,a);if(e=ct(e),isNaN(l))return{stiffness:ee.stiffness,damping:ee.damping,duration:e};{const u=Math.pow(l,2)*r;return{stiffness:u,damping:o*2*Math.sqrt(r*u),duration:e}}}const w1=12;function k1(e,t,n){let r=n;for(let i=1;ie[n]!==void 0)}function C1(e){let t={velocity:ee.velocity,stiffness:ee.stiffness,damping:ee.damping,mass:ee.mass,isResolvedFromDuration:!1,...e};if(!zc(e,j1)&&zc(e,S1))if(e.visualDuration){const n=e.visualDuration,r=2*Math.PI/(n*1.2),i=r*r,s=2*Ct(.05,1,1-(e.bounce||0))*Math.sqrt(i);t={...t,mass:ee.mass,stiffness:i,damping:s}}else{const n=x1(e);t={...t,...n,mass:ee.mass},t.isResolvedFromDuration=!0}return t}function Cs(e=ee.visualDuration,t=ee.bounce){const n=typeof e!="object"?{visualDuration:e,keyframes:[0,1],bounce:t}:e;let{restSpeed:r,restDelta:i}=n;const s=n.keyframes[0],o=n.keyframes[n.keyframes.length-1],a={done:!1,value:s},{stiffness:l,damping:u,mass:c,duration:h,velocity:f,isResolvedFromDuration:v}=C1({...n,velocity:-He(n.velocity||0)}),x=f||0,y=u/(2*Math.sqrt(l*c)),T=o-s,m=He(Math.sqrt(l/c)),p=Math.abs(T)<5;r||(r=p?ee.restSpeed.granular:ee.restSpeed.default),i||(i=p?ee.restDelta.granular:ee.restDelta.default);let g;if(y<1){const k=Aa(m,y);g=j=>{const N=Math.exp(-y*m*j);return o-N*((x+y*m*T)/k*Math.sin(k*j)+T*Math.cos(k*j))}}else if(y===1)g=k=>o-Math.exp(-m*k)*(T+(x+m*T)*k);else{const k=m*Math.sqrt(y*y-1);g=j=>{const N=Math.exp(-y*m*j),C=Math.min(k*j,300);return o-N*((x+y*m*T)*Math.sinh(C)+k*T*Math.cosh(C))/k}}const w={calculatedDuration:v&&h||null,next:k=>{const j=g(k);if(v)a.done=k>=h;else{let N=k===0?x:0;y<1&&(N=k===0?ct(x):Fp(g,k,j));const C=Math.abs(N)<=r,b=Math.abs(o-j)<=i;a.done=C&&b}return a.value=a.done?o:j,a},toString:()=>{const k=Math.min(ou(w),js),j=_p(N=>w.next(k*N).value,k,30);return k+"ms "+j},toTransition:()=>{}};return w}Cs.applyToOptions=e=>{const t=y1(e,100,Cs);return e.ease=t.ease,e.duration=ct(t.duration),e.type="keyframes",e};function Ra({keyframes:e,velocity:t=0,power:n=.8,timeConstant:r=325,bounceDamping:i=10,bounceStiffness:s=500,modifyTarget:o,min:a,max:l,restDelta:u=.5,restSpeed:c}){const h=e[0],f={done:!1,value:h},v=C=>a!==void 0&&Cl,x=C=>a===void 0?l:l===void 0||Math.abs(a-C)-y*Math.exp(-C/r),g=C=>m+p(C),w=C=>{const b=p(C),L=g(C);f.done=Math.abs(b)<=u,f.value=f.done?m:L};let k,j;const N=C=>{v(f.value)&&(k=C,j=Cs({keyframes:[f.value,x(f.value)],velocity:Fp(g,C,f.value),damping:i,stiffness:s,restDelta:u,restSpeed:c}))};return N(0),{calculatedDuration:null,next:C=>{let b=!1;return!j&&k===void 0&&(b=!0,w(C),N(C)),k!==void 0&&C>=k?j.next(C-k):(!b&&w(C),f)}}}function T1(e,t,n){const r=[],i=n||Tt.mix||Ip,s=e.length-1;for(let o=0;ot[0];if(s===2&&t[0]===t[1])return()=>t[1];const o=e[0]===e[1];e[0]>e[s-1]&&(e=[...e].reverse(),t=[...t].reverse());const a=T1(t,r,i),l=a.length,u=c=>{if(o&&c1)for(;hu(Ct(e[0],e[s-1],c)):u}function P1(e,t){const n=e[e.length-1];for(let r=1;r<=t;r++){const i=Jr(0,t,r);e.push(X(n,1,i))}}function E1(e){const t=[0];return P1(t,e.length-1),t}function M1(e,t){return e.map(n=>n*t)}function L1(e,t){return e.map(()=>t||Np).splice(0,e.length-1)}function Rr({duration:e=300,keyframes:t,times:n,ease:r="easeInOut"}){const i=zy(r)?r.map(Ic):Ic(r),s={done:!1,value:t[0]},o=M1(n&&n.length===t.length?n:E1(t),e),a=N1(o,t,{ease:Array.isArray(i)?i:L1(t,i)});return{calculatedDuration:e,next:l=>(s.value=a(l),s.done=l>=e,s)}}const D1=e=>e!==null;function au(e,{repeat:t,repeatType:n="loop"},r,i=1){const s=e.filter(D1),a=i<0||t&&n!=="loop"&&t%2===1?0:s.length-1;return!a||r===void 0?s[a]:r}const A1={decay:Ra,inertia:Ra,tween:Rr,keyframes:Rr,spring:Cs};function Op(e){typeof e.type=="string"&&(e.type=A1[e.type])}class lu{constructor(){this.updateFinished()}get finished(){return this._finished}updateFinished(){this._finished=new Promise(t=>{this.resolve=t})}notifyFinished(){this.resolve()}then(t,n){return this.finished.then(t,n)}}const R1=e=>e/100;class uu extends lu{constructor(t){super(),this.state="idle",this.startTime=null,this.isStopped=!1,this.currentTime=0,this.holdTime=null,this.playbackSpeed=1,this.stop=()=>{var r,i;const{motionValue:n}=this.options;n&&n.updatedAt!==Le.now()&&this.tick(Le.now()),this.isStopped=!0,this.state!=="idle"&&(this.teardown(),(i=(r=this.options).onStop)==null||i.call(r))},this.options=t,this.initAnimation(),this.play(),t.autoplay===!1&&this.pause()}initAnimation(){const{options:t}=this;Op(t);const{type:n=Rr,repeat:r=0,repeatDelay:i=0,repeatType:s,velocity:o=0}=t;let{keyframes:a}=t;const l=n||Rr;l!==Rr&&typeof a[0]!="number"&&(this.mixKeyframes=ci(R1,Ip(a[0],a[1])),a=[0,100]);const u=l({...t,keyframes:a});s==="mirror"&&(this.mirroredGenerator=l({...t,keyframes:[...a].reverse(),velocity:-o})),u.calculatedDuration===null&&(u.calculatedDuration=ou(u));const{calculatedDuration:c}=u;this.calculatedDuration=c,this.resolvedDuration=c+i,this.totalDuration=this.resolvedDuration*(r+1)-i,this.generator=u}updateTime(t){const n=Math.round(t-this.startTime)*this.playbackSpeed;this.holdTime!==null?this.currentTime=this.holdTime:this.currentTime=n}tick(t,n=!1){const{generator:r,totalDuration:i,mixKeyframes:s,mirroredGenerator:o,resolvedDuration:a,calculatedDuration:l}=this;if(this.startTime===null)return r.next(0);const{delay:u=0,keyframes:c,repeat:h,repeatType:f,repeatDelay:v,type:x,onUpdate:y,finalKeyframe:T}=this.options;this.speed>0?this.startTime=Math.min(this.startTime,t):this.speed<0&&(this.startTime=Math.min(t-i/this.speed,this.startTime)),n?this.currentTime=t:this.updateTime(t);const m=this.currentTime-u*(this.playbackSpeed>=0?1:-1),p=this.playbackSpeed>=0?m<0:m>i;this.currentTime=Math.max(m,0),this.state==="finished"&&this.holdTime===null&&(this.currentTime=i);let g=this.currentTime,w=r;if(h){const C=Math.min(this.currentTime,i)/a;let b=Math.floor(C),L=C%1;!L&&C>=1&&(L=1),L===1&&b--,b=Math.min(b,h+1),!!(b%2)&&(f==="reverse"?(L=1-L,v&&(L-=v/a)):f==="mirror"&&(w=o)),g=Ct(0,1,L)*a}const k=p?{done:!1,value:c[0]}:w.next(g);s&&(k.value=s(k.value));let{done:j}=k;!p&&l!==null&&(j=this.playbackSpeed>=0?this.currentTime>=i:this.currentTime<=0);const N=this.holdTime===null&&(this.state==="finished"||this.state==="running"&&j);return N&&x!==Ra&&(k.value=au(c,this.options,T,this.speed)),y&&y(k.value),N&&this.finish(),k}then(t,n){return this.finished.then(t,n)}get duration(){return He(this.calculatedDuration)}get iterationDuration(){const{delay:t=0}=this.options||{};return this.duration+He(t)}get time(){return He(this.currentTime)}set time(t){var n;t=ct(t),this.currentTime=t,this.startTime===null||this.holdTime!==null||this.playbackSpeed===0?this.holdTime=t:this.driver&&(this.startTime=this.driver.now()-t/this.playbackSpeed),(n=this.driver)==null||n.start(!1)}get speed(){return this.playbackSpeed}set speed(t){this.updateTime(Le.now());const n=this.playbackSpeed!==t;this.playbackSpeed=t,n&&(this.time=He(this.currentTime))}play(){var i,s;if(this.isStopped)return;const{driver:t=g1,startTime:n}=this.options;this.driver||(this.driver=t(o=>this.tick(o))),(s=(i=this.options).onPlay)==null||s.call(i);const r=this.driver.now();this.state==="finished"?(this.updateFinished(),this.startTime=r):this.holdTime!==null?this.startTime=r-this.holdTime:this.startTime||(this.startTime=n??r),this.state==="finished"&&this.speed<0&&(this.startTime+=this.calculatedDuration),this.holdTime=null,this.state="running",this.driver.start()}pause(){this.state="paused",this.updateTime(Le.now()),this.holdTime=this.currentTime}complete(){this.state!=="running"&&this.play(),this.state="finished",this.holdTime=null}finish(){var t,n;this.notifyFinished(),this.teardown(),this.state="finished",(n=(t=this.options).onComplete)==null||n.call(t)}cancel(){var t,n;this.holdTime=null,this.startTime=0,this.tick(0),this.teardown(),(n=(t=this.options).onCancel)==null||n.call(t)}teardown(){this.state="idle",this.stopDriver(),this.startTime=this.holdTime=null}stopDriver(){this.driver&&(this.driver.stop(),this.driver=void 0)}sample(t){return this.startTime=0,this.tick(t,!0)}attachTimeline(t){var n;return this.options.allowFlatten&&(this.options.type="keyframes",this.options.ease="linear",this.initAnimation()),(n=this.driver)==null||n.stop(),t.observe(this)}}function V1(e){for(let t=1;te*180/Math.PI,Va=e=>{const t=ln(Math.atan2(e[1],e[0]));return ba(t)},b1={x:4,y:5,translateX:4,translateY:5,scaleX:0,scaleY:3,scale:e=>(Math.abs(e[0])+Math.abs(e[3]))/2,rotate:Va,rotateZ:Va,skewX:e=>ln(Math.atan(e[1])),skewY:e=>ln(Math.atan(e[2])),skew:e=>(Math.abs(e[1])+Math.abs(e[2]))/2},ba=e=>(e=e%360,e<0&&(e+=360),e),Uc=Va,Wc=e=>Math.sqrt(e[0]*e[0]+e[1]*e[1]),$c=e=>Math.sqrt(e[4]*e[4]+e[5]*e[5]),I1={x:12,y:13,z:14,translateX:12,translateY:13,translateZ:14,scaleX:Wc,scaleY:$c,scale:e=>(Wc(e)+$c(e))/2,rotateX:e=>ba(ln(Math.atan2(e[6],e[5]))),rotateY:e=>ba(ln(Math.atan2(-e[2],e[0]))),rotateZ:Uc,rotate:Uc,skewX:e=>ln(Math.atan(e[4])),skewY:e=>ln(Math.atan(e[1])),skew:e=>(Math.abs(e[1])+Math.abs(e[4]))/2};function Ia(e){return e.includes("scale")?1:0}function _a(e,t){if(!e||e==="none")return Ia(t);const n=e.match(/^matrix3d\(([-\d.e\s,]+)\)$/u);let r,i;if(n)r=I1,i=n;else{const a=e.match(/^matrix\(([-\d.e\s,]+)\)$/u);r=b1,i=a}if(!i)return Ia(t);const s=r[t],o=i[1].split(",").map(F1);return typeof s=="function"?s(o):o[s]}const _1=(e,t)=>{const{transform:n="none"}=getComputedStyle(e);return _a(n,t)};function F1(e){return parseFloat(e.trim())}const or=["transformPerspective","x","y","z","translateX","translateY","translateZ","scale","scaleX","scaleY","rotate","rotateX","rotateY","rotateZ","skew","skewX","skewY"],ar=new Set(or),Hc=e=>e===sr||e===R,O1=new Set(["x","y","z"]),B1=or.filter(e=>!O1.has(e));function z1(e){const t=[];return B1.forEach(n=>{const r=e.getValue(n);r!==void 0&&(t.push([n,r.get()]),r.set(n.startsWith("scale")?1:0))}),t}const dn={width:({x:e},{paddingLeft:t="0",paddingRight:n="0"})=>e.max-e.min-parseFloat(t)-parseFloat(n),height:({y:e},{paddingTop:t="0",paddingBottom:n="0"})=>e.max-e.min-parseFloat(t)-parseFloat(n),top:(e,{top:t})=>parseFloat(t),left:(e,{left:t})=>parseFloat(t),bottom:({y:e},{top:t})=>parseFloat(t)+(e.max-e.min),right:({x:e},{left:t})=>parseFloat(t)+(e.max-e.min),x:(e,{transform:t})=>_a(t,"x"),y:(e,{transform:t})=>_a(t,"y")};dn.translateX=dn.x;dn.translateY=dn.y;const fn=new Set;let Fa=!1,Oa=!1,Ba=!1;function Bp(){if(Oa){const e=Array.from(fn).filter(r=>r.needsMeasurement),t=new Set(e.map(r=>r.element)),n=new Map;t.forEach(r=>{const i=z1(r);i.length&&(n.set(r,i),r.render())}),e.forEach(r=>r.measureInitialState()),t.forEach(r=>{r.render();const i=n.get(r);i&&i.forEach(([s,o])=>{var a;(a=r.getValue(s))==null||a.set(o)})}),e.forEach(r=>r.measureEndState()),e.forEach(r=>{r.suspendedScrollY!==void 0&&window.scrollTo(0,r.suspendedScrollY)})}Oa=!1,Fa=!1,fn.forEach(e=>e.complete(Ba)),fn.clear()}function zp(){fn.forEach(e=>{e.readKeyframes(),e.needsMeasurement&&(Oa=!0)})}function U1(){Ba=!0,zp(),Bp(),Ba=!1}class cu{constructor(t,n,r,i,s,o=!1){this.state="pending",this.isAsync=!1,this.needsMeasurement=!1,this.unresolvedKeyframes=[...t],this.onComplete=n,this.name=r,this.motionValue=i,this.element=s,this.isAsync=o}scheduleResolve(){this.state="scheduled",this.isAsync?(fn.add(this),Fa||(Fa=!0,G.read(zp),G.resolveKeyframes(Bp))):(this.readKeyframes(),this.complete())}readKeyframes(){const{unresolvedKeyframes:t,name:n,element:r,motionValue:i}=this;if(t[0]===null){const s=i==null?void 0:i.get(),o=t[t.length-1];if(s!==void 0)t[0]=s;else if(r&&n){const a=r.readValue(n,o);a!=null&&(t[0]=a)}t[0]===void 0&&(t[0]=o),i&&s===void 0&&i.set(t[0])}V1(t)}setFinalKeyframe(){}measureInitialState(){}renderEndStyles(){}measureEndState(){}complete(t=!1){this.state="complete",this.onComplete(this.unresolvedKeyframes,this.finalKeyframe,t),fn.delete(this)}cancel(){this.state==="scheduled"&&(fn.delete(this),this.state="pending")}resume(){this.state==="pending"&&this.scheduleResolve()}}const W1=e=>e.startsWith("--");function $1(e,t,n){W1(t)?e.style.setProperty(t,n):e.style[t]=n}const H1=Zl(()=>window.ScrollTimeline!==void 0),K1={};function G1(e,t){const n=Zl(e);return()=>K1[t]??n()}const Up=G1(()=>{try{document.createElement("div").animate({opacity:0},{easing:"linear(0, 1)"})}catch{return!1}return!0},"linearEasing"),Sr=([e,t,n,r])=>`cubic-bezier(${e}, ${t}, ${n}, ${r})`,Kc={linear:"linear",ease:"ease",easeIn:"ease-in",easeOut:"ease-out",easeInOut:"ease-in-out",circIn:Sr([0,.65,.55,1]),circOut:Sr([.55,0,1,.45]),backIn:Sr([.31,.01,.66,-.59]),backOut:Sr([.33,1.53,.69,.99])};function Wp(e,t){if(e)return typeof e=="function"?Up()?_p(e,t):"ease-out":Pp(e)?Sr(e):Array.isArray(e)?e.map(n=>Wp(n,t)||Kc.easeOut):Kc[e]}function Y1(e,t,n,{delay:r=0,duration:i=300,repeat:s=0,repeatType:o="loop",ease:a="easeOut",times:l}={},u=void 0){const c={[t]:n};l&&(c.offset=l);const h=Wp(a,i);Array.isArray(h)&&(c.easing=h);const f={delay:r,duration:i,easing:Array.isArray(h)?"linear":h,fill:"both",iterations:s+1,direction:o==="reverse"?"alternate":"normal"};return u&&(f.pseudoElement=u),e.animate(c,f)}function $p(e){return typeof e=="function"&&"applyToOptions"in e}function Q1({type:e,...t}){return $p(e)&&Up()?e.applyToOptions(t):(t.duration??(t.duration=300),t.ease??(t.ease="easeOut"),t)}class X1 extends lu{constructor(t){if(super(),this.finishedTime=null,this.isStopped=!1,!t)return;const{element:n,name:r,keyframes:i,pseudoElement:s,allowFlatten:o=!1,finalKeyframe:a,onComplete:l}=t;this.isPseudoElement=!!s,this.allowFlatten=o,this.options=t,Xl(typeof t.type!="string");const u=Q1(t);this.animation=Y1(n,r,i,u,s),u.autoplay===!1&&this.animation.pause(),this.animation.onfinish=()=>{if(this.finishedTime=this.time,!s){const c=au(i,this.options,a,this.speed);this.updateMotionValue?this.updateMotionValue(c):$1(n,r,c),this.animation.cancel()}l==null||l(),this.notifyFinished()}}play(){this.isStopped||(this.animation.play(),this.state==="finished"&&this.updateFinished())}pause(){this.animation.pause()}complete(){var t,n;(n=(t=this.animation).finish)==null||n.call(t)}cancel(){try{this.animation.cancel()}catch{}}stop(){if(this.isStopped)return;this.isStopped=!0;const{state:t}=this;t==="idle"||t==="finished"||(this.updateMotionValue?this.updateMotionValue():this.commitStyles(),this.isPseudoElement||this.cancel())}commitStyles(){var t,n;this.isPseudoElement||(n=(t=this.animation).commitStyles)==null||n.call(t)}get duration(){var n,r;const t=((r=(n=this.animation.effect)==null?void 0:n.getComputedTiming)==null?void 0:r.call(n).duration)||0;return He(Number(t))}get iterationDuration(){const{delay:t=0}=this.options||{};return this.duration+He(t)}get time(){return He(Number(this.animation.currentTime)||0)}set time(t){this.finishedTime=null,this.animation.currentTime=ct(t)}get speed(){return this.animation.playbackRate}set speed(t){t<0&&(this.finishedTime=null),this.animation.playbackRate=t}get state(){return this.finishedTime!==null?"finished":this.animation.playState}get startTime(){return Number(this.animation.startTime)}set startTime(t){this.animation.startTime=t}attachTimeline({timeline:t,observe:n}){var r;return this.allowFlatten&&((r=this.animation.effect)==null||r.updateTiming({easing:"linear"})),this.animation.onfinish=null,t&&H1()?(this.animation.timeline=t,Ge):n(this)}}const Hp={anticipate:jp,backInOut:Sp,circInOut:Tp};function Z1(e){return e in Hp}function q1(e){typeof e.ease=="string"&&Z1(e.ease)&&(e.ease=Hp[e.ease])}const Gc=10;class J1 extends X1{constructor(t){q1(t),Op(t),super(t),t.startTime&&(this.startTime=t.startTime),this.options=t}updateMotionValue(t){const{motionValue:n,onUpdate:r,onComplete:i,element:s,...o}=this.options;if(!n)return;if(t!==void 0){n.set(t);return}const a=new uu({...o,autoplay:!1}),l=ct(this.finishedTime??this.time);n.setWithVelocity(a.sample(l-Gc).value,a.sample(l).value,Gc),a.stop()}}const Yc=(e,t)=>t==="zIndex"?!1:!!(typeof e=="number"||Array.isArray(e)||typeof e=="string"&&(Kt.test(e)||e==="0")&&!e.startsWith("url("));function ev(e){const t=e[0];if(e.length===1)return!0;for(let n=0;nObject.hasOwnProperty.call(Element.prototype,"animate"));function iv(e){var c;const{motionValue:t,name:n,repeatDelay:r,repeatType:i,damping:s,type:o}=e;if(!(((c=t==null?void 0:t.owner)==null?void 0:c.current)instanceof HTMLElement))return!1;const{onUpdate:l,transformTemplate:u}=t.owner.getProps();return rv()&&n&&nv.has(n)&&(n!=="transform"||!u)&&!l&&!r&&i!=="mirror"&&s!==0&&o!=="inertia"}const sv=40;class ov extends lu{constructor({autoplay:t=!0,delay:n=0,type:r="keyframes",repeat:i=0,repeatDelay:s=0,repeatType:o="loop",keyframes:a,name:l,motionValue:u,element:c,...h}){var x;super(),this.stop=()=>{var y,T;this._animation&&(this._animation.stop(),(y=this.stopTimeline)==null||y.call(this)),(T=this.keyframeResolver)==null||T.cancel()},this.createdAt=Le.now();const f={autoplay:t,delay:n,type:r,repeat:i,repeatDelay:s,repeatType:o,name:l,motionValue:u,element:c,...h},v=(c==null?void 0:c.KeyframeResolver)||cu;this.keyframeResolver=new v(a,(y,T,m)=>this.onKeyframesResolved(y,T,f,!m),l,u,c),(x=this.keyframeResolver)==null||x.scheduleResolve()}onKeyframesResolved(t,n,r,i){this.keyframeResolver=void 0;const{name:s,type:o,velocity:a,delay:l,isHandoff:u,onUpdate:c}=r;this.resolvedAt=Le.now(),tv(t,s,o,a)||((Tt.instantAnimations||!l)&&(c==null||c(au(t,r,n))),t[0]=t[t.length-1],za(r),r.repeat=0);const f={startTime:i?this.resolvedAt?this.resolvedAt-this.createdAt>sv?this.resolvedAt:this.createdAt:this.createdAt:void 0,finalKeyframe:n,...r,keyframes:t},v=!u&&iv(f)?new J1({...f,element:f.motionValue.owner.current}):new uu(f);v.finished.then(()=>this.notifyFinished()).catch(Ge),this.pendingTimeline&&(this.stopTimeline=v.attachTimeline(this.pendingTimeline),this.pendingTimeline=void 0),this._animation=v}get finished(){return this._animation?this.animation.finished:this._finished}then(t,n){return this.finished.finally(t).then(()=>{})}get animation(){var t;return this._animation||((t=this.keyframeResolver)==null||t.resume(),U1()),this._animation}get duration(){return this.animation.duration}get iterationDuration(){return this.animation.iterationDuration}get time(){return this.animation.time}set time(t){this.animation.time=t}get speed(){return this.animation.speed}get state(){return this.animation.state}set speed(t){this.animation.speed=t}get startTime(){return this.animation.startTime}attachTimeline(t){return this._animation?this.stopTimeline=this.animation.attachTimeline(t):this.pendingTimeline=t,()=>this.stop()}play(){this.animation.play()}pause(){this.animation.pause()}complete(){this.animation.complete()}cancel(){var t;this._animation&&this.animation.cancel(),(t=this.keyframeResolver)==null||t.cancel()}}const av=/^var\(--(?:([\w-]+)|([\w-]+), ?([a-zA-Z\d ()%#.,-]+))\)/u;function lv(e){const t=av.exec(e);if(!t)return[,];const[,n,r,i]=t;return[`--${n??r}`,i]}function Kp(e,t,n=1){const[r,i]=lv(e);if(!r)return;const s=window.getComputedStyle(t).getPropertyValue(r);if(s){const o=s.trim();return pp(o)?parseFloat(o):o}return nu(i)?Kp(i,t,n+1):i}function du(e,t){return(e==null?void 0:e[t])??(e==null?void 0:e.default)??e}const Gp=new Set(["width","height","top","left","right","bottom",...or]),uv={test:e=>e==="auto",parse:e=>e},Yp=e=>t=>t.test(e),Qp=[sr,R,dt,Et,e1,Jy,uv],Qc=e=>Qp.find(Yp(e));function cv(e){return typeof e=="number"?e===0:e!==null?e==="none"||e==="0"||gp(e):!0}const dv=new Set(["brightness","contrast","saturate","opacity"]);function fv(e){const[t,n]=e.slice(0,-1).split("(");if(t==="drop-shadow")return e;const[r]=n.match(ru)||[];if(!r)return e;const i=n.replace(r,"");let s=dv.has(t)?1:0;return r!==n&&(s*=100),t+"("+s+i+")"}const hv=/\b([a-z-]*)\(.*?\)/gu,Ua={...Kt,getAnimatableNone:e=>{const t=e.match(hv);return t?t.map(fv).join(" "):e}},Xc={...sr,transform:Math.round},pv={rotate:Et,rotateX:Et,rotateY:Et,rotateZ:Et,scale:Ai,scaleX:Ai,scaleY:Ai,scaleZ:Ai,skew:Et,skewX:Et,skewY:Et,distance:R,translateX:R,translateY:R,translateZ:R,x:R,y:R,z:R,perspective:R,transformPerspective:R,opacity:ei,originX:_c,originY:_c,originZ:R},fu={borderWidth:R,borderTopWidth:R,borderRightWidth:R,borderBottomWidth:R,borderLeftWidth:R,borderRadius:R,radius:R,borderTopLeftRadius:R,borderTopRightRadius:R,borderBottomRightRadius:R,borderBottomLeftRadius:R,width:R,maxWidth:R,height:R,maxHeight:R,top:R,right:R,bottom:R,left:R,padding:R,paddingTop:R,paddingRight:R,paddingBottom:R,paddingLeft:R,margin:R,marginTop:R,marginRight:R,marginBottom:R,marginLeft:R,backgroundPositionX:R,backgroundPositionY:R,...pv,zIndex:Xc,fillOpacity:ei,strokeOpacity:ei,numOctaves:Xc},mv={...fu,color:ie,backgroundColor:ie,outlineColor:ie,fill:ie,stroke:ie,borderColor:ie,borderTopColor:ie,borderRightColor:ie,borderBottomColor:ie,borderLeftColor:ie,filter:Ua,WebkitFilter:Ua},Xp=e=>mv[e];function Zp(e,t){let n=Xp(e);return n!==Ua&&(n=Kt),n.getAnimatableNone?n.getAnimatableNone(t):void 0}const gv=new Set(["auto","none","0"]);function yv(e,t,n){let r=0,i;for(;r{t.getValue(l).set(u)}),this.resolveNoneKeyframes()}}function xv(e,t,n){if(e instanceof EventTarget)return[e];if(typeof e=="string"){let r=document;const i=(n==null?void 0:n[e])??r.querySelectorAll(e);return i?Array.from(i):[]}return Array.from(e)}const qp=(e,t)=>t&&typeof e=="number"?t.transform(e):e;function Jp(e){return mp(e)&&"offsetHeight"in e}const Zc=30,wv=e=>!isNaN(parseFloat(e));class kv{constructor(t,n={}){this.canTrackVelocity=null,this.events={},this.updateAndNotify=r=>{var s;const i=Le.now();if(this.updatedAt!==i&&this.setPrevFrameValue(),this.prev=this.current,this.setCurrent(r),this.current!==this.prev&&((s=this.events.change)==null||s.notify(this.current),this.dependents))for(const o of this.dependents)o.dirty()},this.hasAnimated=!1,this.setCurrent(t),this.owner=n.owner}setCurrent(t){this.current=t,this.updatedAt=Le.now(),this.canTrackVelocity===null&&t!==void 0&&(this.canTrackVelocity=wv(this.current))}setPrevFrameValue(t=this.current){this.prevFrameValue=t,this.prevUpdatedAt=this.updatedAt}onChange(t){return this.on("change",t)}on(t,n){this.events[t]||(this.events[t]=new ql);const r=this.events[t].add(n);return t==="change"?()=>{r(),G.read(()=>{this.events.change.getSize()||this.stop()})}:r}clearListeners(){for(const t in this.events)this.events[t].clear()}attach(t,n){this.passiveEffect=t,this.stopPassiveEffect=n}set(t){this.passiveEffect?this.passiveEffect(t,this.updateAndNotify):this.updateAndNotify(t)}setWithVelocity(t,n,r){this.set(n),this.prev=void 0,this.prevFrameValue=t,this.prevUpdatedAt=this.updatedAt-r}jump(t,n=!0){this.updateAndNotify(t),this.prev=t,this.prevUpdatedAt=this.prevFrameValue=void 0,n&&this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}dirty(){var t;(t=this.events.change)==null||t.notify(this.current)}addDependent(t){this.dependents||(this.dependents=new Set),this.dependents.add(t)}removeDependent(t){this.dependents&&this.dependents.delete(t)}get(){return this.current}getPrevious(){return this.prev}getVelocity(){const t=Le.now();if(!this.canTrackVelocity||this.prevFrameValue===void 0||t-this.updatedAt>Zc)return 0;const n=Math.min(this.updatedAt-this.prevUpdatedAt,Zc);return yp(parseFloat(this.current)-parseFloat(this.prevFrameValue),n)}start(t){return this.stop(),new Promise(n=>{this.hasAnimated=!0,this.animation=t(n),this.events.animationStart&&this.events.animationStart.notify()}).then(()=>{this.events.animationComplete&&this.events.animationComplete.notify(),this.clearAnimation()})}stop(){this.animation&&(this.animation.stop(),this.events.animationCancel&&this.events.animationCancel.notify()),this.clearAnimation()}isAnimating(){return!!this.animation}clearAnimation(){delete this.animation}destroy(){var t,n;(t=this.dependents)==null||t.clear(),(n=this.events.destroy)==null||n.notify(),this.clearListeners(),this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}}function er(e,t){return new kv(e,t)}const{schedule:hu}=Ep(queueMicrotask,!1),qe={x:!1,y:!1};function e0(){return qe.x||qe.y}function Sv(e){return e==="x"||e==="y"?qe[e]?null:(qe[e]=!0,()=>{qe[e]=!1}):qe.x||qe.y?null:(qe.x=qe.y=!0,()=>{qe.x=qe.y=!1})}function t0(e,t){const n=xv(e),r=new AbortController,i={passive:!0,...t,signal:r.signal};return[n,i,()=>r.abort()]}function qc(e){return!(e.pointerType==="touch"||e0())}function jv(e,t,n={}){const[r,i,s]=t0(e,n),o=a=>{if(!qc(a))return;const{target:l}=a,u=t(l,a);if(typeof u!="function"||!l)return;const c=h=>{qc(h)&&(u(h),l.removeEventListener("pointerleave",c))};l.addEventListener("pointerleave",c,i)};return r.forEach(a=>{a.addEventListener("pointerenter",o,i)}),s}const n0=(e,t)=>t?e===t?!0:n0(e,t.parentElement):!1,pu=e=>e.pointerType==="mouse"?typeof e.button!="number"||e.button<=0:e.isPrimary!==!1,Cv=new Set(["BUTTON","INPUT","SELECT","TEXTAREA","A"]);function Tv(e){return Cv.has(e.tagName)||e.tabIndex!==-1}const Qi=new WeakSet;function Jc(e){return t=>{t.key==="Enter"&&e(t)}}function No(e,t){e.dispatchEvent(new PointerEvent("pointer"+t,{isPrimary:!0,bubbles:!0}))}const Nv=(e,t)=>{const n=e.currentTarget;if(!n)return;const r=Jc(()=>{if(Qi.has(n))return;No(n,"down");const i=Jc(()=>{No(n,"up")}),s=()=>No(n,"cancel");n.addEventListener("keyup",i,t),n.addEventListener("blur",s,t)});n.addEventListener("keydown",r,t),n.addEventListener("blur",()=>n.removeEventListener("keydown",r),t)};function ed(e){return pu(e)&&!e0()}function Pv(e,t,n={}){const[r,i,s]=t0(e,n),o=a=>{const l=a.currentTarget;if(!ed(a))return;Qi.add(l);const u=t(l,a),c=(v,x)=>{window.removeEventListener("pointerup",h),window.removeEventListener("pointercancel",f),Qi.has(l)&&Qi.delete(l),ed(v)&&typeof u=="function"&&u(v,{success:x})},h=v=>{c(v,l===window||l===document||n.useGlobalTarget||n0(l,v.target))},f=v=>{c(v,!1)};window.addEventListener("pointerup",h,i),window.addEventListener("pointercancel",f,i)};return r.forEach(a=>{(n.useGlobalTarget?window:a).addEventListener("pointerdown",o,i),Jp(a)&&(a.addEventListener("focus",u=>Nv(u,i)),!Tv(a)&&!a.hasAttribute("tabindex")&&(a.tabIndex=0))}),s}function r0(e){return mp(e)&&"ownerSVGElement"in e}function Ev(e){return r0(e)&&e.tagName==="svg"}const ke=e=>!!(e&&e.getVelocity),Mv=[...Qp,ie,Kt],Lv=e=>Mv.find(Yp(e)),mu=S.createContext({transformPagePoint:e=>e,isStatic:!1,reducedMotion:"never"});function td(e,t){if(typeof e=="function")return e(t);e!=null&&(e.current=t)}function Dv(...e){return t=>{let n=!1;const r=e.map(i=>{const s=td(i,t);return!n&&typeof s=="function"&&(n=!0),s});if(n)return()=>{for(let i=0;i{const{width:u,height:c,top:h,left:f,right:v}=o.current;if(t||!s.current||!u||!c)return;const x=n==="left"?`left: ${f}`:`right: ${v}`;s.current.dataset.motionPopId=i;const y=document.createElement("style");a&&(y.nonce=a);const T=r??document.head;return T.appendChild(y),y.sheet&&y.sheet.insertRule(` - [data-motion-pop-id="${i}"] { - position: absolute !important; - width: ${u}px !important; - height: ${c}px !important; - ${x}px !important; - top: ${h}px !important; - } - `),()=>{T.contains(y)&&T.removeChild(y)}},[t]),d.jsx(Rv,{isPresent:t,childRef:s,sizeRef:o,children:S.cloneElement(e,{ref:l})})}const bv=({children:e,initial:t,isPresent:n,onExitComplete:r,custom:i,presenceAffectsLayout:s,mode:o,anchorX:a,root:l})=>{const u=Kl(Iv),c=S.useId();let h=!0,f=S.useMemo(()=>(h=!1,{id:c,initial:t,isPresent:n,custom:i,onExitComplete:v=>{u.set(v,!0);for(const x of u.values())if(!x)return;r&&r()},register:v=>(u.set(v,!1),()=>u.delete(v))}),[n,u,r]);return s&&h&&(f={...f}),S.useMemo(()=>{u.forEach((v,x)=>u.set(x,!1))},[n]),S.useEffect(()=>{!n&&!u.size&&r&&r()},[n]),o==="popLayout"&&(e=d.jsx(Vv,{isPresent:n,anchorX:a,root:l,children:e})),d.jsx($s.Provider,{value:f,children:e})};function Iv(){return new Map}function i0(e=!0){const t=S.useContext($s);if(t===null)return[!0,null];const{isPresent:n,onExitComplete:r,register:i}=t,s=S.useId();S.useEffect(()=>{if(e)return i(s)},[e]);const o=S.useCallback(()=>e&&r&&r(s),[s,r,e]);return!n&&r?[!1,o]:[!0]}const Ri=e=>e.key||"";function nd(e){const t=[];return S.Children.forEach(e,n=>{S.isValidElement(n)&&t.push(n)}),t}const rd=({children:e,custom:t,initial:n=!0,onExitComplete:r,presenceAffectsLayout:i=!0,mode:s="sync",propagate:o=!1,anchorX:a="left",root:l})=>{const[u,c]=i0(o),h=S.useMemo(()=>nd(e),[e]),f=o&&!u?[]:h.map(Ri),v=S.useRef(!0),x=S.useRef(h),y=Kl(()=>new Map),[T,m]=S.useState(h),[p,g]=S.useState(h);hp(()=>{v.current=!1,x.current=h;for(let j=0;j{const N=Ri(j),C=o&&!u?!1:h===p||f.includes(N),b=()=>{if(y.has(N))y.set(N,!0);else return;let L=!0;y.forEach(J=>{J||(L=!1)}),L&&(k==null||k(),g(x.current),o&&(c==null||c()),r&&r())};return d.jsx(bv,{isPresent:C,initial:!v.current||n?void 0:!1,custom:t,presenceAffectsLayout:i,mode:s,root:l,onExitComplete:C?void 0:b,anchorX:a,children:j},N)})})},s0=S.createContext({strict:!1}),id={animation:["animate","variants","whileHover","whileTap","exit","whileInView","whileFocus","whileDrag"],exit:["exit"],drag:["drag","dragControls"],focus:["whileFocus"],hover:["whileHover","onHoverStart","onHoverEnd"],tap:["whileTap","onTap","onTapStart","onTapCancel"],pan:["onPan","onPanStart","onPanSessionStart","onPanEnd"],inView:["whileInView","onViewportEnter","onViewportLeave"],layout:["layout","layoutId"]},tr={};for(const e in id)tr[e]={isEnabled:t=>id[e].some(n=>!!t[n])};function _v(e){for(const t in e)tr[t]={...tr[t],...e[t]}}const Fv=new Set(["animate","exit","variants","initial","style","values","variants","transition","transformTemplate","custom","inherit","onBeforeLayoutMeasure","onAnimationStart","onAnimationComplete","onUpdate","onDragStart","onDrag","onDragEnd","onMeasureDragConstraints","onDirectionLock","onDragTransitionEnd","_dragX","_dragY","onHoverStart","onHoverEnd","onViewportEnter","onViewportLeave","globalTapTarget","ignoreStrict","viewport"]);function Ts(e){return e.startsWith("while")||e.startsWith("drag")&&e!=="draggable"||e.startsWith("layout")||e.startsWith("onTap")||e.startsWith("onPan")||e.startsWith("onLayout")||Fv.has(e)}let o0=e=>!Ts(e);function Ov(e){typeof e=="function"&&(o0=t=>t.startsWith("on")?!Ts(t):e(t))}try{Ov(require("@emotion/is-prop-valid").default)}catch{}function Bv(e,t,n){const r={};for(const i in e)i==="values"&&typeof e.values=="object"||(o0(i)||n===!0&&Ts(i)||!t&&!Ts(i)||e.draggable&&i.startsWith("onDrag"))&&(r[i]=e[i]);return r}const Hs=S.createContext({});function Ks(e){return e!==null&&typeof e=="object"&&typeof e.start=="function"}function ni(e){return typeof e=="string"||Array.isArray(e)}const gu=["animate","whileInView","whileFocus","whileHover","whileTap","whileDrag","exit"],yu=["initial",...gu];function Gs(e){return Ks(e.animate)||yu.some(t=>ni(e[t]))}function a0(e){return!!(Gs(e)||e.variants)}function zv(e,t){if(Gs(e)){const{initial:n,animate:r}=e;return{initial:n===!1||ni(n)?n:void 0,animate:ni(r)?r:void 0}}return e.inherit!==!1?t:{}}function Uv(e){const{initial:t,animate:n}=zv(e,S.useContext(Hs));return S.useMemo(()=>({initial:t,animate:n}),[sd(t),sd(n)])}function sd(e){return Array.isArray(e)?e.join(" "):e}const ri={};function Wv(e){for(const t in e)ri[t]=e[t],tu(t)&&(ri[t].isCSSVariable=!0)}function l0(e,{layout:t,layoutId:n}){return ar.has(e)||e.startsWith("origin")||(t||n!==void 0)&&(!!ri[e]||e==="opacity")}const $v={x:"translateX",y:"translateY",z:"translateZ",transformPerspective:"perspective"},Hv=or.length;function Kv(e,t,n){let r="",i=!0;for(let s=0;s({style:{},transform:{},transformOrigin:{},vars:{}});function u0(e,t,n){for(const r in t)!ke(t[r])&&!l0(r,n)&&(e[r]=t[r])}function Gv({transformTemplate:e},t){return S.useMemo(()=>{const n=xu();return vu(n,t,e),Object.assign({},n.vars,n.style)},[t])}function Yv(e,t){const n=e.style||{},r={};return u0(r,n,e),Object.assign(r,Gv(e,t)),r}function Qv(e,t){const n={},r=Yv(e,t);return e.drag&&e.dragListener!==!1&&(n.draggable=!1,r.userSelect=r.WebkitUserSelect=r.WebkitTouchCallout="none",r.touchAction=e.drag===!0?"none":`pan-${e.drag==="x"?"y":"x"}`),e.tabIndex===void 0&&(e.onTap||e.onTapStart||e.whileTap)&&(n.tabIndex=0),n.style=r,n}const Xv={offset:"stroke-dashoffset",array:"stroke-dasharray"},Zv={offset:"strokeDashoffset",array:"strokeDasharray"};function qv(e,t,n=1,r=0,i=!0){e.pathLength=1;const s=i?Xv:Zv;e[s.offset]=R.transform(-r);const o=R.transform(t),a=R.transform(n);e[s.array]=`${o} ${a}`}function c0(e,{attrX:t,attrY:n,attrScale:r,pathLength:i,pathSpacing:s=1,pathOffset:o=0,...a},l,u,c){if(vu(e,a,u),l){e.style.viewBox&&(e.attrs.viewBox=e.style.viewBox);return}e.attrs=e.style,e.style={};const{attrs:h,style:f}=e;h.transform&&(f.transform=h.transform,delete h.transform),(f.transform||h.transformOrigin)&&(f.transformOrigin=h.transformOrigin??"50% 50%",delete h.transformOrigin),f.transform&&(f.transformBox=(c==null?void 0:c.transformBox)??"fill-box",delete h.transformBox),t!==void 0&&(h.x=t),n!==void 0&&(h.y=n),r!==void 0&&(h.scale=r),i!==void 0&&qv(h,i,s,o,!1)}const d0=()=>({...xu(),attrs:{}}),f0=e=>typeof e=="string"&&e.toLowerCase()==="svg";function Jv(e,t,n,r){const i=S.useMemo(()=>{const s=d0();return c0(s,t,f0(r),e.transformTemplate,e.style),{...s.attrs,style:{...s.style}}},[t]);if(e.style){const s={};u0(s,e.style,e),i.style={...s,...i.style}}return i}const ex=["animate","circle","defs","desc","ellipse","g","image","line","filter","marker","mask","metadata","path","pattern","polygon","polyline","rect","stop","switch","symbol","svg","text","tspan","use","view"];function wu(e){return typeof e!="string"||e.includes("-")?!1:!!(ex.indexOf(e)>-1||/[A-Z]/u.test(e))}function tx(e,t,n,{latestValues:r},i,s=!1){const a=(wu(e)?Jv:Qv)(t,r,i,e),l=Bv(t,typeof e=="string",s),u=e!==S.Fragment?{...l,...a,ref:n}:{},{children:c}=t,h=S.useMemo(()=>ke(c)?c.get():c,[c]);return S.createElement(e,{...u,children:h})}function od(e){const t=[{},{}];return e==null||e.values.forEach((n,r)=>{t[0][r]=n.get(),t[1][r]=n.getVelocity()}),t}function ku(e,t,n,r){if(typeof t=="function"){const[i,s]=od(r);t=t(n!==void 0?n:e.custom,i,s)}if(typeof t=="string"&&(t=e.variants&&e.variants[t]),typeof t=="function"){const[i,s]=od(r);t=t(n!==void 0?n:e.custom,i,s)}return t}function Xi(e){return ke(e)?e.get():e}function nx({scrapeMotionValuesFromProps:e,createRenderState:t},n,r,i){return{latestValues:rx(n,r,i,e),renderState:t()}}function rx(e,t,n,r){const i={},s=r(e,{});for(const f in s)i[f]=Xi(s[f]);let{initial:o,animate:a}=e;const l=Gs(e),u=a0(e);t&&u&&!l&&e.inherit!==!1&&(o===void 0&&(o=t.initial),a===void 0&&(a=t.animate));let c=n?n.initial===!1:!1;c=c||o===!1;const h=c?a:o;if(h&&typeof h!="boolean"&&!Ks(h)){const f=Array.isArray(h)?h:[h];for(let v=0;v(t,n)=>{const r=S.useContext(Hs),i=S.useContext($s),s=()=>nx(e,t,r,i);return n?s():Kl(s)};function Su(e,t,n){var s;const{style:r}=e,i={};for(const o in r)(ke(r[o])||t.style&&ke(t.style[o])||l0(o,e)||((s=n==null?void 0:n.getValue(o))==null?void 0:s.liveStyle)!==void 0)&&(i[o]=r[o]);return i}const ix=h0({scrapeMotionValuesFromProps:Su,createRenderState:xu});function p0(e,t,n){const r=Su(e,t,n);for(const i in e)if(ke(e[i])||ke(t[i])){const s=or.indexOf(i)!==-1?"attr"+i.charAt(0).toUpperCase()+i.substring(1):i;r[s]=e[i]}return r}const sx=h0({scrapeMotionValuesFromProps:p0,createRenderState:d0}),ox=Symbol.for("motionComponentSymbol");function In(e){return e&&typeof e=="object"&&Object.prototype.hasOwnProperty.call(e,"current")}function ax(e,t,n){return S.useCallback(r=>{r&&e.onMount&&e.onMount(r),t&&(r?t.mount(r):t.unmount()),n&&(typeof n=="function"?n(r):In(n)&&(n.current=r))},[t])}const ju=e=>e.replace(/([a-z])([A-Z])/gu,"$1-$2").toLowerCase(),lx="framerAppearId",m0="data-"+ju(lx),g0=S.createContext({});function ux(e,t,n,r,i){var y,T;const{visualElement:s}=S.useContext(Hs),o=S.useContext(s0),a=S.useContext($s),l=S.useContext(mu).reducedMotion,u=S.useRef(null);r=r||o.renderer,!u.current&&r&&(u.current=r(e,{visualState:t,parent:s,props:n,presenceContext:a,blockInitialAnimation:a?a.initial===!1:!1,reducedMotionConfig:l}));const c=u.current,h=S.useContext(g0);c&&!c.projection&&i&&(c.type==="html"||c.type==="svg")&&cx(u.current,n,i,h);const f=S.useRef(!1);S.useInsertionEffect(()=>{c&&f.current&&c.update(n,a)});const v=n[m0],x=S.useRef(!!v&&!((y=window.MotionHandoffIsComplete)!=null&&y.call(window,v))&&((T=window.MotionHasOptimisedAnimation)==null?void 0:T.call(window,v)));return hp(()=>{c&&(f.current=!0,window.MotionIsMounted=!0,c.updateFeatures(),c.scheduleRenderMicrotask(),x.current&&c.animationState&&c.animationState.animateChanges())}),S.useEffect(()=>{c&&(!x.current&&c.animationState&&c.animationState.animateChanges(),x.current&&(queueMicrotask(()=>{var m;(m=window.MotionHandoffMarkAsComplete)==null||m.call(window,v)}),x.current=!1),c.enteringChildren=void 0)}),c}function cx(e,t,n,r){const{layoutId:i,layout:s,drag:o,dragConstraints:a,layoutScroll:l,layoutRoot:u,layoutCrossfade:c}=t;e.projection=new n(e.latestValues,t["data-framer-portal-id"]?void 0:y0(e.parent)),e.projection.setOptions({layoutId:i,layout:s,alwaysMeasureLayout:!!o||a&&In(a),visualElement:e,animationType:typeof s=="string"?s:"both",initialPromotionConfig:r,crossfade:c,layoutScroll:l,layoutRoot:u})}function y0(e){if(e)return e.options.allowProjection!==!1?e.projection:y0(e.parent)}function Po(e,{forwardMotionProps:t=!1}={},n,r){n&&_v(n);const i=wu(e)?sx:ix;function s(a,l){let u;const c={...S.useContext(mu),...a,layoutId:dx(a)},{isStatic:h}=c,f=Uv(a),v=i(a,h);if(!h&&Gl){fx();const x=hx(c);u=x.MeasureLayout,f.visualElement=ux(e,v,c,r,x.ProjectionNode)}return d.jsxs(Hs.Provider,{value:f,children:[u&&f.visualElement?d.jsx(u,{visualElement:f.visualElement,...c}):null,tx(e,a,ax(v,f.visualElement,l),v,h,t)]})}s.displayName=`motion.${typeof e=="string"?e:`create(${e.displayName??e.name??""})`}`;const o=S.forwardRef(s);return o[ox]=e,o}function dx({layoutId:e}){const t=S.useContext(Hl).id;return t&&e!==void 0?t+"-"+e:e}function fx(e,t){S.useContext(s0).strict}function hx(e){const{drag:t,layout:n}=tr;if(!t&&!n)return{};const r={...t,...n};return{MeasureLayout:t!=null&&t.isEnabled(e)||n!=null&&n.isEnabled(e)?r.MeasureLayout:void 0,ProjectionNode:r.ProjectionNode}}function px(e,t){if(typeof Proxy>"u")return Po;const n=new Map,r=(s,o)=>Po(s,o,e,t),i=(s,o)=>r(s,o);return new Proxy(i,{get:(s,o)=>o==="create"?r:(n.has(o)||n.set(o,Po(o,void 0,e,t)),n.get(o))})}function v0({top:e,left:t,right:n,bottom:r}){return{x:{min:t,max:n},y:{min:e,max:r}}}function mx({x:e,y:t}){return{top:t.min,right:e.max,bottom:t.max,left:e.min}}function gx(e,t){if(!t)return e;const n=t({x:e.left,y:e.top}),r=t({x:e.right,y:e.bottom});return{top:n.y,left:n.x,bottom:r.y,right:r.x}}function Eo(e){return e===void 0||e===1}function Wa({scale:e,scaleX:t,scaleY:n}){return!Eo(e)||!Eo(t)||!Eo(n)}function nn(e){return Wa(e)||x0(e)||e.z||e.rotate||e.rotateX||e.rotateY||e.skewX||e.skewY}function x0(e){return ad(e.x)||ad(e.y)}function ad(e){return e&&e!=="0%"}function Ns(e,t,n){const r=e-n,i=t*r;return n+i}function ld(e,t,n,r,i){return i!==void 0&&(e=Ns(e,i,r)),Ns(e,n,r)+t}function $a(e,t=0,n=1,r,i){e.min=ld(e.min,t,n,r,i),e.max=ld(e.max,t,n,r,i)}function w0(e,{x:t,y:n}){$a(e.x,t.translate,t.scale,t.originPoint),$a(e.y,n.translate,n.scale,n.originPoint)}const ud=.999999999999,cd=1.0000000000001;function yx(e,t,n,r=!1){const i=n.length;if(!i)return;t.x=t.y=1;let s,o;for(let a=0;aud&&(t.x=1),t.yud&&(t.y=1)}function _n(e,t){e.min=e.min+t,e.max=e.max+t}function dd(e,t,n,r,i=.5){const s=X(e.min,e.max,i);$a(e,t,n,s,r)}function Fn(e,t){dd(e.x,t.x,t.scaleX,t.scale,t.originX),dd(e.y,t.y,t.scaleY,t.scale,t.originY)}function k0(e,t){return v0(gx(e.getBoundingClientRect(),t))}function vx(e,t,n){const r=k0(e,n),{scroll:i}=t;return i&&(_n(r.x,i.offset.x),_n(r.y,i.offset.y)),r}const fd=()=>({translate:0,scale:1,origin:0,originPoint:0}),On=()=>({x:fd(),y:fd()}),hd=()=>({min:0,max:0}),oe=()=>({x:hd(),y:hd()}),Ha={current:null},S0={current:!1};function xx(){if(S0.current=!0,!!Gl)if(window.matchMedia){const e=window.matchMedia("(prefers-reduced-motion)"),t=()=>Ha.current=e.matches;e.addEventListener("change",t),t()}else Ha.current=!1}const wx=new WeakMap;function kx(e,t,n){for(const r in t){const i=t[r],s=n[r];if(ke(i))e.addValue(r,i);else if(ke(s))e.addValue(r,er(i,{owner:e}));else if(s!==i)if(e.hasValue(r)){const o=e.getValue(r);o.liveStyle===!0?o.jump(i):o.hasAnimated||o.set(i)}else{const o=e.getStaticValue(r);e.addValue(r,er(o!==void 0?o:i,{owner:e}))}}for(const r in n)t[r]===void 0&&e.removeValue(r);return t}const pd=["AnimationStart","AnimationComplete","Update","BeforeLayoutMeasure","LayoutMeasure","LayoutAnimationStart","LayoutAnimationComplete"];class Sx{scrapeMotionValuesFromProps(t,n,r){return{}}constructor({parent:t,props:n,presenceContext:r,reducedMotionConfig:i,blockInitialAnimation:s,visualState:o},a={}){this.current=null,this.children=new Set,this.isVariantNode=!1,this.isControllingVariants=!1,this.shouldReduceMotion=null,this.values=new Map,this.KeyframeResolver=cu,this.features={},this.valueSubscriptions=new Map,this.prevMotionValues={},this.events={},this.propEventSubscriptions={},this.notifyUpdate=()=>this.notify("Update",this.latestValues),this.render=()=>{this.current&&(this.triggerBuild(),this.renderInstance(this.current,this.renderState,this.props.style,this.projection))},this.renderScheduledAt=0,this.scheduleRender=()=>{const f=Le.now();this.renderScheduledAtthis.bindToMotionValue(i,r)),S0.current||xx(),this.shouldReduceMotion=this.reducedMotionConfig==="never"?!1:this.reducedMotionConfig==="always"?!0:Ha.current,(n=this.parent)==null||n.addChild(this),this.update(this.props,this.presenceContext)}unmount(){var t;this.projection&&this.projection.unmount(),Ht(this.notifyUpdate),Ht(this.render),this.valueSubscriptions.forEach(n=>n()),this.valueSubscriptions.clear(),this.removeFromVariantTree&&this.removeFromVariantTree(),(t=this.parent)==null||t.removeChild(this);for(const n in this.events)this.events[n].clear();for(const n in this.features){const r=this.features[n];r&&(r.unmount(),r.isMounted=!1)}this.current=null}addChild(t){this.children.add(t),this.enteringChildren??(this.enteringChildren=new Set),this.enteringChildren.add(t)}removeChild(t){this.children.delete(t),this.enteringChildren&&this.enteringChildren.delete(t)}bindToMotionValue(t,n){this.valueSubscriptions.has(t)&&this.valueSubscriptions.get(t)();const r=ar.has(t);r&&this.onBindTransform&&this.onBindTransform();const i=n.on("change",o=>{this.latestValues[t]=o,this.props.onUpdate&&G.preRender(this.notifyUpdate),r&&this.projection&&(this.projection.isTransformDirty=!0),this.scheduleRender()});let s;window.MotionCheckAppearSync&&(s=window.MotionCheckAppearSync(this,t,n)),this.valueSubscriptions.set(t,()=>{i(),s&&s(),n.owner&&n.stop()})}sortNodePosition(t){return!this.current||!this.sortInstanceNodePosition||this.type!==t.type?0:this.sortInstanceNodePosition(this.current,t.current)}updateFeatures(){let t="animation";for(t in tr){const n=tr[t];if(!n)continue;const{isEnabled:r,Feature:i}=n;if(!this.features[t]&&i&&r(this.props)&&(this.features[t]=new i(this)),this.features[t]){const s=this.features[t];s.isMounted?s.update():(s.mount(),s.isMounted=!0)}}}triggerBuild(){this.build(this.renderState,this.latestValues,this.props)}measureViewportBox(){return this.current?this.measureInstanceViewportBox(this.current,this.props):oe()}getStaticValue(t){return this.latestValues[t]}setStaticValue(t,n){this.latestValues[t]=n}update(t,n){(t.transformTemplate||this.props.transformTemplate)&&this.scheduleRender(),this.prevProps=this.props,this.props=t,this.prevPresenceContext=this.presenceContext,this.presenceContext=n;for(let r=0;rn.variantChildren.delete(t)}addValue(t,n){const r=this.values.get(t);n!==r&&(r&&this.removeValue(t),this.bindToMotionValue(t,n),this.values.set(t,n),this.latestValues[t]=n.get())}removeValue(t){this.values.delete(t);const n=this.valueSubscriptions.get(t);n&&(n(),this.valueSubscriptions.delete(t)),delete this.latestValues[t],this.removeValueFromRenderState(t,this.renderState)}hasValue(t){return this.values.has(t)}getValue(t,n){if(this.props.values&&this.props.values[t])return this.props.values[t];let r=this.values.get(t);return r===void 0&&n!==void 0&&(r=er(n===null?void 0:n,{owner:this}),this.addValue(t,r)),r}readValue(t,n){let r=this.latestValues[t]!==void 0||!this.current?this.latestValues[t]:this.getBaseTargetFromProps(this.props,t)??this.readValueFromInstance(this.current,t,this.options);return r!=null&&(typeof r=="string"&&(pp(r)||gp(r))?r=parseFloat(r):!Lv(r)&&Kt.test(n)&&(r=Zp(t,n)),this.setBaseTarget(t,ke(r)?r.get():r)),ke(r)?r.get():r}setBaseTarget(t,n){this.baseTarget[t]=n}getBaseTarget(t){var s;const{initial:n}=this.props;let r;if(typeof n=="string"||typeof n=="object"){const o=ku(this.props,n,(s=this.presenceContext)==null?void 0:s.custom);o&&(r=o[t])}if(n&&r!==void 0)return r;const i=this.getBaseTargetFromProps(this.props,t);return i!==void 0&&!ke(i)?i:this.initialValues[t]!==void 0&&r===void 0?void 0:this.baseTarget[t]}on(t,n){return this.events[t]||(this.events[t]=new ql),this.events[t].add(n)}notify(t,...n){this.events[t]&&this.events[t].notify(...n)}scheduleRenderMicrotask(){hu.render(this.render)}}class j0 extends Sx{constructor(){super(...arguments),this.KeyframeResolver=vv}sortInstanceNodePosition(t,n){return t.compareDocumentPosition(n)&2?1:-1}getBaseTargetFromProps(t,n){return t.style?t.style[n]:void 0}removeValueFromRenderState(t,{vars:n,style:r}){delete n[t],delete r[t]}handleChildMotionValue(){this.childSubscription&&(this.childSubscription(),delete this.childSubscription);const{children:t}=this.props;ke(t)&&(this.childSubscription=t.on("change",n=>{this.current&&(this.current.textContent=`${n}`)}))}}function C0(e,{style:t,vars:n},r,i){const s=e.style;let o;for(o in t)s[o]=t[o];i==null||i.applyProjectionStyles(s,r);for(o in n)s.setProperty(o,n[o])}function jx(e){return window.getComputedStyle(e)}class Cx extends j0{constructor(){super(...arguments),this.type="html",this.renderInstance=C0}readValueFromInstance(t,n){var r;if(ar.has(n))return(r=this.projection)!=null&&r.isProjecting?Ia(n):_1(t,n);{const i=jx(t),s=(tu(n)?i.getPropertyValue(n):i[n])||0;return typeof s=="string"?s.trim():s}}measureInstanceViewportBox(t,{transformPagePoint:n}){return k0(t,n)}build(t,n,r){vu(t,n,r.transformTemplate)}scrapeMotionValuesFromProps(t,n,r){return Su(t,n,r)}}const T0=new Set(["baseFrequency","diffuseConstant","kernelMatrix","kernelUnitLength","keySplines","keyTimes","limitingConeAngle","markerHeight","markerWidth","numOctaves","targetX","targetY","surfaceScale","specularConstant","specularExponent","stdDeviation","tableValues","viewBox","gradientTransform","pathLength","startOffset","textLength","lengthAdjust"]);function Tx(e,t,n,r){C0(e,t,void 0,r);for(const i in t.attrs)e.setAttribute(T0.has(i)?i:ju(i),t.attrs[i])}class Nx extends j0{constructor(){super(...arguments),this.type="svg",this.isSVGTag=!1,this.measureInstanceViewportBox=oe}getBaseTargetFromProps(t,n){return t[n]}readValueFromInstance(t,n){if(ar.has(n)){const r=Xp(n);return r&&r.default||0}return n=T0.has(n)?n:ju(n),t.getAttribute(n)}scrapeMotionValuesFromProps(t,n,r){return p0(t,n,r)}build(t,n,r){c0(t,n,this.isSVGTag,r.transformTemplate,r.style)}renderInstance(t,n,r,i){Tx(t,n,r,i)}mount(t){this.isSVGTag=f0(t.tagName),super.mount(t)}}const Px=(e,t)=>wu(e)?new Nx(t):new Cx(t,{allowProjection:e!==S.Fragment});function Kn(e,t,n){const r=e.getProps();return ku(r,t,n!==void 0?n:r.custom,e)}const Ka=e=>Array.isArray(e);function Ex(e,t,n){e.hasValue(t)?e.getValue(t).set(n):e.addValue(t,er(n))}function Mx(e){return Ka(e)?e[e.length-1]||0:e}function Lx(e,t){const n=Kn(e,t);let{transitionEnd:r={},transition:i={},...s}=n||{};s={...s,...r};for(const o in s){const a=Mx(s[o]);Ex(e,o,a)}}function Dx(e){return!!(ke(e)&&e.add)}function Ga(e,t){const n=e.getValue("willChange");if(Dx(n))return n.add(t);if(!n&&Tt.WillChange){const r=new Tt.WillChange("auto");e.addValue("willChange",r),r.add(t)}}function N0(e){return e.props[m0]}const Ax=e=>e!==null;function Rx(e,{repeat:t,repeatType:n="loop"},r){const i=e.filter(Ax),s=t&&n!=="loop"&&t%2===1?0:i.length-1;return i[s]}const Vx={type:"spring",stiffness:500,damping:25,restSpeed:10},bx=e=>({type:"spring",stiffness:550,damping:e===0?2*Math.sqrt(550):30,restSpeed:10}),Ix={type:"keyframes",duration:.8},_x={type:"keyframes",ease:[.25,.1,.35,1],duration:.3},Fx=(e,{keyframes:t})=>t.length>2?Ix:ar.has(e)?e.startsWith("scale")?bx(t[1]):Vx:_x;function Ox({when:e,delay:t,delayChildren:n,staggerChildren:r,staggerDirection:i,repeat:s,repeatType:o,repeatDelay:a,from:l,elapsed:u,...c}){return!!Object.keys(c).length}const Cu=(e,t,n,r={},i,s)=>o=>{const a=du(r,e)||{},l=a.delay||r.delay||0;let{elapsed:u=0}=r;u=u-ct(l);const c={keyframes:Array.isArray(n)?n:[null,n],ease:"easeOut",velocity:t.getVelocity(),...a,delay:-u,onUpdate:f=>{t.set(f),a.onUpdate&&a.onUpdate(f)},onComplete:()=>{o(),a.onComplete&&a.onComplete()},name:e,motionValue:t,element:s?void 0:i};Ox(a)||Object.assign(c,Fx(e,c)),c.duration&&(c.duration=ct(c.duration)),c.repeatDelay&&(c.repeatDelay=ct(c.repeatDelay)),c.from!==void 0&&(c.keyframes[0]=c.from);let h=!1;if((c.type===!1||c.duration===0&&!c.repeatDelay)&&(za(c),c.delay===0&&(h=!0)),(Tt.instantAnimations||Tt.skipAnimations)&&(h=!0,za(c),c.delay=0),c.allowFlatten=!a.type&&!a.ease,h&&!s&&t.get()!==void 0){const f=Rx(c.keyframes,a);if(f!==void 0){G.update(()=>{c.onUpdate(f),c.onComplete()});return}}return a.isSync?new uu(c):new ov(c)};function Bx({protectedKeys:e,needsAnimating:t},n){const r=e.hasOwnProperty(n)&&t[n]!==!0;return t[n]=!1,r}function P0(e,t,{delay:n=0,transitionOverride:r,type:i}={}){let{transition:s=e.getDefaultTransition(),transitionEnd:o,...a}=t;r&&(s=r);const l=[],u=i&&e.animationState&&e.animationState.getState()[i];for(const c in a){const h=e.getValue(c,e.latestValues[c]??null),f=a[c];if(f===void 0||u&&Bx(u,c))continue;const v={delay:n,...du(s||{},c)},x=h.get();if(x!==void 0&&!h.isAnimating&&!Array.isArray(f)&&f===x&&!v.velocity)continue;let y=!1;if(window.MotionHandoffAnimation){const m=N0(e);if(m){const p=window.MotionHandoffAnimation(m,c,G);p!==null&&(v.startTime=p,y=!0)}}Ga(e,c),h.start(Cu(c,h,f,e.shouldReduceMotion&&Gp.has(c)?{type:!1}:v,e,y));const T=h.animation;T&&l.push(T)}return o&&Promise.all(l).then(()=>{G.update(()=>{o&&Lx(e,o)})}),l}function E0(e,t,n,r=0,i=1){const s=Array.from(e).sort((u,c)=>u.sortNodePosition(c)).indexOf(t),o=e.size,a=(o-1)*r;return typeof n=="function"?n(s,o):i===1?s*r:a-s*r}function Ya(e,t,n={}){var l;const r=Kn(e,t,n.type==="exit"?(l=e.presenceContext)==null?void 0:l.custom:void 0);let{transition:i=e.getDefaultTransition()||{}}=r||{};n.transitionOverride&&(i=n.transitionOverride);const s=r?()=>Promise.all(P0(e,r,n)):()=>Promise.resolve(),o=e.variantChildren&&e.variantChildren.size?(u=0)=>{const{delayChildren:c=0,staggerChildren:h,staggerDirection:f}=i;return zx(e,t,u,c,h,f,n)}:()=>Promise.resolve(),{when:a}=i;if(a){const[u,c]=a==="beforeChildren"?[s,o]:[o,s];return u().then(()=>c())}else return Promise.all([s(),o(n.delay)])}function zx(e,t,n=0,r=0,i=0,s=1,o){const a=[];for(const l of e.variantChildren)l.notify("AnimationStart",t),a.push(Ya(l,t,{...o,delay:n+(typeof r=="function"?0:r)+E0(e.variantChildren,l,r,i,s)}).then(()=>l.notify("AnimationComplete",t)));return Promise.all(a)}function Ux(e,t,n={}){e.notify("AnimationStart",t);let r;if(Array.isArray(t)){const i=t.map(s=>Ya(e,s,n));r=Promise.all(i)}else if(typeof t=="string")r=Ya(e,t,n);else{const i=typeof t=="function"?Kn(e,t,n.custom):t;r=Promise.all(P0(e,i,n))}return r.then(()=>{e.notify("AnimationComplete",t)})}function M0(e,t){if(!Array.isArray(t))return!1;const n=t.length;if(n!==e.length)return!1;for(let r=0;rPromise.all(t.map(({animation:n,options:r})=>Ux(e,n,r)))}function Gx(e){let t=Kx(e),n=md(),r=!0;const i=l=>(u,c)=>{var f;const h=Kn(e,c,l==="exit"?(f=e.presenceContext)==null?void 0:f.custom:void 0);if(h){const{transition:v,transitionEnd:x,...y}=h;u={...u,...y,...x}}return u};function s(l){t=l(e)}function o(l){const{props:u}=e,c=L0(e.parent)||{},h=[],f=new Set;let v={},x=1/0;for(let T=0;Tx&&w,b=!1;const L=Array.isArray(g)?g:[g];let J=L.reduce(i(m),{});k===!1&&(J={});const{prevResolvedValues:Be={}}=p,ft={...Be,...J},H=Y=>{C=!0,f.has(Y)&&(b=!0,f.delete(Y)),p.needsAnimating[Y]=!0;const E=e.getValue(Y);E&&(E.liveStyle=!1)};for(const Y in ft){const E=J[Y],A=Be[Y];if(v.hasOwnProperty(Y))continue;let V=!1;Ka(E)&&Ka(A)?V=!M0(E,A):V=E!==A,V?E!=null?H(Y):f.add(Y):E!==void 0&&f.has(Y)?H(Y):p.protectedKeys[Y]=!0}p.prevProp=g,p.prevResolvedValues=J,p.isActive&&(v={...v,...J}),r&&e.blockInitialAnimation&&(C=!1);const ge=j&&N;C&&(!ge||b)&&h.push(...L.map(Y=>{const E={type:m};if(typeof Y=="string"&&r&&!ge&&e.manuallyAnimateOnMount&&e.parent){const{parent:A}=e,V=Kn(A,Y);if(A.enteringChildren&&V){const{delayChildren:U}=V.transition||{};E.delay=E0(A.enteringChildren,e,U)}}return{animation:Y,options:E}}))}if(f.size){const T={};if(typeof u.initial!="boolean"){const m=Kn(e,Array.isArray(u.initial)?u.initial[0]:u.initial);m&&m.transition&&(T.transition=m.transition)}f.forEach(m=>{const p=e.getBaseTarget(m),g=e.getValue(m);g&&(g.liveStyle=!0),T[m]=p??null}),h.push({animation:T})}let y=!!h.length;return r&&(u.initial===!1||u.initial===u.animate)&&!e.manuallyAnimateOnMount&&(y=!1),r=!1,y?t(h):Promise.resolve()}function a(l,u){var h;if(n[l].isActive===u)return Promise.resolve();(h=e.variantChildren)==null||h.forEach(f=>{var v;return(v=f.animationState)==null?void 0:v.setActive(l,u)}),n[l].isActive=u;const c=o(l);for(const f in n)n[f].protectedKeys={};return c}return{animateChanges:o,setActive:a,setAnimateFunction:s,getState:()=>n,reset:()=>{n=md()}}}function Yx(e,t){return typeof t=="string"?t!==e:Array.isArray(t)?!M0(t,e):!1}function Jt(e=!1){return{isActive:e,protectedKeys:{},needsAnimating:{},prevResolvedValues:{}}}function md(){return{animate:Jt(!0),whileInView:Jt(),whileHover:Jt(),whileTap:Jt(),whileDrag:Jt(),whileFocus:Jt(),exit:Jt()}}class Xt{constructor(t){this.isMounted=!1,this.node=t}update(){}}class Qx extends Xt{constructor(t){super(t),t.animationState||(t.animationState=Gx(t))}updateAnimationControlsSubscription(){const{animate:t}=this.node.getProps();Ks(t)&&(this.unmountControls=t.subscribe(this.node))}mount(){this.updateAnimationControlsSubscription()}update(){const{animate:t}=this.node.getProps(),{animate:n}=this.node.prevProps||{};t!==n&&this.updateAnimationControlsSubscription()}unmount(){var t;this.node.animationState.reset(),(t=this.unmountControls)==null||t.call(this)}}let Xx=0;class Zx extends Xt{constructor(){super(...arguments),this.id=Xx++}update(){if(!this.node.presenceContext)return;const{isPresent:t,onExitComplete:n}=this.node.presenceContext,{isPresent:r}=this.node.prevPresenceContext||{};if(!this.node.animationState||t===r)return;const i=this.node.animationState.setActive("exit",!t);n&&!t&&i.then(()=>{n(this.id)})}mount(){const{register:t,onExitComplete:n}=this.node.presenceContext||{};n&&n(this.id),t&&(this.unmount=t(this.id))}unmount(){}}const qx={animation:{Feature:Qx},exit:{Feature:Zx}};function ii(e,t,n,r={passive:!0}){return e.addEventListener(t,n,r),()=>e.removeEventListener(t,n)}function hi(e){return{point:{x:e.pageX,y:e.pageY}}}const Jx=e=>t=>pu(t)&&e(t,hi(t));function Vr(e,t,n,r){return ii(e,t,Jx(n),r)}const D0=1e-4,e2=1-D0,t2=1+D0,A0=.01,n2=0-A0,r2=0+A0;function Ce(e){return e.max-e.min}function i2(e,t,n){return Math.abs(e-t)<=n}function gd(e,t,n,r=.5){e.origin=r,e.originPoint=X(t.min,t.max,e.origin),e.scale=Ce(n)/Ce(t),e.translate=X(n.min,n.max,e.origin)-e.originPoint,(e.scale>=e2&&e.scale<=t2||isNaN(e.scale))&&(e.scale=1),(e.translate>=n2&&e.translate<=r2||isNaN(e.translate))&&(e.translate=0)}function br(e,t,n,r){gd(e.x,t.x,n.x,r?r.originX:void 0),gd(e.y,t.y,n.y,r?r.originY:void 0)}function yd(e,t,n){e.min=n.min+t.min,e.max=e.min+Ce(t)}function s2(e,t,n){yd(e.x,t.x,n.x),yd(e.y,t.y,n.y)}function vd(e,t,n){e.min=t.min-n.min,e.max=e.min+Ce(t)}function Ps(e,t,n){vd(e.x,t.x,n.x),vd(e.y,t.y,n.y)}function ze(e){return[e("x"),e("y")]}const R0=({current:e})=>e?e.ownerDocument.defaultView:null,xd=(e,t)=>Math.abs(e-t);function o2(e,t){const n=xd(e.x,t.x),r=xd(e.y,t.y);return Math.sqrt(n**2+r**2)}class V0{constructor(t,n,{transformPagePoint:r,contextWindow:i=window,dragSnapToOrigin:s=!1,distanceThreshold:o=3}={}){if(this.startEvent=null,this.lastMoveEvent=null,this.lastMoveEventInfo=null,this.handlers={},this.contextWindow=window,this.updatePoint=()=>{if(!(this.lastMoveEvent&&this.lastMoveEventInfo))return;const f=Lo(this.lastMoveEventInfo,this.history),v=this.startEvent!==null,x=o2(f.offset,{x:0,y:0})>=this.distanceThreshold;if(!v&&!x)return;const{point:y}=f,{timestamp:T}=he;this.history.push({...y,timestamp:T});const{onStart:m,onMove:p}=this.handlers;v||(m&&m(this.lastMoveEvent,f),this.startEvent=this.lastMoveEvent),p&&p(this.lastMoveEvent,f)},this.handlePointerMove=(f,v)=>{this.lastMoveEvent=f,this.lastMoveEventInfo=Mo(v,this.transformPagePoint),G.update(this.updatePoint,!0)},this.handlePointerUp=(f,v)=>{this.end();const{onEnd:x,onSessionEnd:y,resumeAnimation:T}=this.handlers;if(this.dragSnapToOrigin&&T&&T(),!(this.lastMoveEvent&&this.lastMoveEventInfo))return;const m=Lo(f.type==="pointercancel"?this.lastMoveEventInfo:Mo(v,this.transformPagePoint),this.history);this.startEvent&&x&&x(f,m),y&&y(f,m)},!pu(t))return;this.dragSnapToOrigin=s,this.handlers=n,this.transformPagePoint=r,this.distanceThreshold=o,this.contextWindow=i||window;const a=hi(t),l=Mo(a,this.transformPagePoint),{point:u}=l,{timestamp:c}=he;this.history=[{...u,timestamp:c}];const{onSessionStart:h}=n;h&&h(t,Lo(l,this.history)),this.removeListeners=ci(Vr(this.contextWindow,"pointermove",this.handlePointerMove),Vr(this.contextWindow,"pointerup",this.handlePointerUp),Vr(this.contextWindow,"pointercancel",this.handlePointerUp))}updateHandlers(t){this.handlers=t}end(){this.removeListeners&&this.removeListeners(),Ht(this.updatePoint)}}function Mo(e,t){return t?{point:t(e.point)}:e}function wd(e,t){return{x:e.x-t.x,y:e.y-t.y}}function Lo({point:e},t){return{point:e,delta:wd(e,b0(t)),offset:wd(e,a2(t)),velocity:l2(t,.1)}}function a2(e){return e[0]}function b0(e){return e[e.length-1]}function l2(e,t){if(e.length<2)return{x:0,y:0};let n=e.length-1,r=null;const i=b0(e);for(;n>=0&&(r=e[n],!(i.timestamp-r.timestamp>ct(t)));)n--;if(!r)return{x:0,y:0};const s=He(i.timestamp-r.timestamp);if(s===0)return{x:0,y:0};const o={x:(i.x-r.x)/s,y:(i.y-r.y)/s};return o.x===1/0&&(o.x=0),o.y===1/0&&(o.y=0),o}function u2(e,{min:t,max:n},r){return t!==void 0&&en&&(e=r?X(n,e,r.max):Math.min(e,n)),e}function kd(e,t,n){return{min:t!==void 0?e.min+t:void 0,max:n!==void 0?e.max+n-(e.max-e.min):void 0}}function c2(e,{top:t,left:n,bottom:r,right:i}){return{x:kd(e.x,n,i),y:kd(e.y,t,r)}}function Sd(e,t){let n=t.min-e.min,r=t.max-e.max;return t.max-t.minr?n=Jr(t.min,t.max-r,e.min):r>i&&(n=Jr(e.min,e.max-i,t.min)),Ct(0,1,n)}function h2(e,t){const n={};return t.min!==void 0&&(n.min=t.min-e.min),t.max!==void 0&&(n.max=t.max-e.min),n}const Qa=.35;function p2(e=Qa){return e===!1?e=0:e===!0&&(e=Qa),{x:jd(e,"left","right"),y:jd(e,"top","bottom")}}function jd(e,t,n){return{min:Cd(e,t),max:Cd(e,n)}}function Cd(e,t){return typeof e=="number"?e:e[t]||0}const m2=new WeakMap;class g2{constructor(t){this.openDragLock=null,this.isDragging=!1,this.currentDirection=null,this.originPoint={x:0,y:0},this.constraints=!1,this.hasMutatedConstraints=!1,this.elastic=oe(),this.latestPointerEvent=null,this.latestPanInfo=null,this.visualElement=t}start(t,{snapToCursor:n=!1,distanceThreshold:r}={}){const{presenceContext:i}=this.visualElement;if(i&&i.isPresent===!1)return;const s=h=>{const{dragSnapToOrigin:f}=this.getProps();f?this.pauseAnimation():this.stopAnimation(),n&&this.snapToCursor(hi(h).point)},o=(h,f)=>{const{drag:v,dragPropagation:x,onDragStart:y}=this.getProps();if(v&&!x&&(this.openDragLock&&this.openDragLock(),this.openDragLock=Sv(v),!this.openDragLock))return;this.latestPointerEvent=h,this.latestPanInfo=f,this.isDragging=!0,this.currentDirection=null,this.resolveConstraints(),this.visualElement.projection&&(this.visualElement.projection.isAnimationBlocked=!0,this.visualElement.projection.target=void 0),ze(m=>{let p=this.getAxisMotionValue(m).get()||0;if(dt.test(p)){const{projection:g}=this.visualElement;if(g&&g.layout){const w=g.layout.layoutBox[m];w&&(p=Ce(w)*(parseFloat(p)/100))}}this.originPoint[m]=p}),y&&G.postRender(()=>y(h,f)),Ga(this.visualElement,"transform");const{animationState:T}=this.visualElement;T&&T.setActive("whileDrag",!0)},a=(h,f)=>{this.latestPointerEvent=h,this.latestPanInfo=f;const{dragPropagation:v,dragDirectionLock:x,onDirectionLock:y,onDrag:T}=this.getProps();if(!v&&!this.openDragLock)return;const{offset:m}=f;if(x&&this.currentDirection===null){this.currentDirection=y2(m),this.currentDirection!==null&&y&&y(this.currentDirection);return}this.updateAxis("x",f.point,m),this.updateAxis("y",f.point,m),this.visualElement.render(),T&&T(h,f)},l=(h,f)=>{this.latestPointerEvent=h,this.latestPanInfo=f,this.stop(h,f),this.latestPointerEvent=null,this.latestPanInfo=null},u=()=>ze(h=>{var f;return this.getAnimationState(h)==="paused"&&((f=this.getAxisMotionValue(h).animation)==null?void 0:f.play())}),{dragSnapToOrigin:c}=this.getProps();this.panSession=new V0(t,{onSessionStart:s,onStart:o,onMove:a,onSessionEnd:l,resumeAnimation:u},{transformPagePoint:this.visualElement.getTransformPagePoint(),dragSnapToOrigin:c,distanceThreshold:r,contextWindow:R0(this.visualElement)})}stop(t,n){const r=t||this.latestPointerEvent,i=n||this.latestPanInfo,s=this.isDragging;if(this.cancel(),!s||!i||!r)return;const{velocity:o}=i;this.startAnimation(o);const{onDragEnd:a}=this.getProps();a&&G.postRender(()=>a(r,i))}cancel(){this.isDragging=!1;const{projection:t,animationState:n}=this.visualElement;t&&(t.isAnimationBlocked=!1),this.panSession&&this.panSession.end(),this.panSession=void 0;const{dragPropagation:r}=this.getProps();!r&&this.openDragLock&&(this.openDragLock(),this.openDragLock=null),n&&n.setActive("whileDrag",!1)}updateAxis(t,n,r){const{drag:i}=this.getProps();if(!r||!Vi(t,i,this.currentDirection))return;const s=this.getAxisMotionValue(t);let o=this.originPoint[t]+r[t];this.constraints&&this.constraints[t]&&(o=u2(o,this.constraints[t],this.elastic[t])),s.set(o)}resolveConstraints(){var s;const{dragConstraints:t,dragElastic:n}=this.getProps(),r=this.visualElement.projection&&!this.visualElement.projection.layout?this.visualElement.projection.measure(!1):(s=this.visualElement.projection)==null?void 0:s.layout,i=this.constraints;t&&In(t)?this.constraints||(this.constraints=this.resolveRefConstraints()):t&&r?this.constraints=c2(r.layoutBox,t):this.constraints=!1,this.elastic=p2(n),i!==this.constraints&&r&&this.constraints&&!this.hasMutatedConstraints&&ze(o=>{this.constraints!==!1&&this.getAxisMotionValue(o)&&(this.constraints[o]=h2(r.layoutBox[o],this.constraints[o]))})}resolveRefConstraints(){const{dragConstraints:t,onMeasureDragConstraints:n}=this.getProps();if(!t||!In(t))return!1;const r=t.current,{projection:i}=this.visualElement;if(!i||!i.layout)return!1;const s=vx(r,i.root,this.visualElement.getTransformPagePoint());let o=d2(i.layout.layoutBox,s);if(n){const a=n(mx(o));this.hasMutatedConstraints=!!a,a&&(o=v0(a))}return o}startAnimation(t){const{drag:n,dragMomentum:r,dragElastic:i,dragTransition:s,dragSnapToOrigin:o,onDragTransitionEnd:a}=this.getProps(),l=this.constraints||{},u=ze(c=>{if(!Vi(c,n,this.currentDirection))return;let h=l&&l[c]||{};o&&(h={min:0,max:0});const f=i?200:1e6,v=i?40:1e7,x={type:"inertia",velocity:r?t[c]:0,bounceStiffness:f,bounceDamping:v,timeConstant:750,restDelta:1,restSpeed:10,...s,...h};return this.startAxisValueAnimation(c,x)});return Promise.all(u).then(a)}startAxisValueAnimation(t,n){const r=this.getAxisMotionValue(t);return Ga(this.visualElement,t),r.start(Cu(t,r,0,n,this.visualElement,!1))}stopAnimation(){ze(t=>this.getAxisMotionValue(t).stop())}pauseAnimation(){ze(t=>{var n;return(n=this.getAxisMotionValue(t).animation)==null?void 0:n.pause()})}getAnimationState(t){var n;return(n=this.getAxisMotionValue(t).animation)==null?void 0:n.state}getAxisMotionValue(t){const n=`_drag${t.toUpperCase()}`,r=this.visualElement.getProps(),i=r[n];return i||this.visualElement.getValue(t,(r.initial?r.initial[t]:void 0)||0)}snapToCursor(t){ze(n=>{const{drag:r}=this.getProps();if(!Vi(n,r,this.currentDirection))return;const{projection:i}=this.visualElement,s=this.getAxisMotionValue(n);if(i&&i.layout){const{min:o,max:a}=i.layout.layoutBox[n];s.set(t[n]-X(o,a,.5))}})}scalePositionWithinConstraints(){if(!this.visualElement.current)return;const{drag:t,dragConstraints:n}=this.getProps(),{projection:r}=this.visualElement;if(!In(n)||!r||!this.constraints)return;this.stopAnimation();const i={x:0,y:0};ze(o=>{const a=this.getAxisMotionValue(o);if(a&&this.constraints!==!1){const l=a.get();i[o]=f2({min:l,max:l},this.constraints[o])}});const{transformTemplate:s}=this.visualElement.getProps();this.visualElement.current.style.transform=s?s({},""):"none",r.root&&r.root.updateScroll(),r.updateLayout(),this.resolveConstraints(),ze(o=>{if(!Vi(o,t,null))return;const a=this.getAxisMotionValue(o),{min:l,max:u}=this.constraints[o];a.set(X(l,u,i[o]))})}addListeners(){if(!this.visualElement.current)return;m2.set(this.visualElement,this);const t=this.visualElement.current,n=Vr(t,"pointerdown",l=>{const{drag:u,dragListener:c=!0}=this.getProps();u&&c&&this.start(l)}),r=()=>{const{dragConstraints:l}=this.getProps();In(l)&&l.current&&(this.constraints=this.resolveRefConstraints())},{projection:i}=this.visualElement,s=i.addEventListener("measure",r);i&&!i.layout&&(i.root&&i.root.updateScroll(),i.updateLayout()),G.read(r);const o=ii(window,"resize",()=>this.scalePositionWithinConstraints()),a=i.addEventListener("didUpdate",({delta:l,hasLayoutChanged:u})=>{this.isDragging&&u&&(ze(c=>{const h=this.getAxisMotionValue(c);h&&(this.originPoint[c]+=l[c].translate,h.set(h.get()+l[c].translate))}),this.visualElement.render())});return()=>{o(),n(),s(),a&&a()}}getProps(){const t=this.visualElement.getProps(),{drag:n=!1,dragDirectionLock:r=!1,dragPropagation:i=!1,dragConstraints:s=!1,dragElastic:o=Qa,dragMomentum:a=!0}=t;return{...t,drag:n,dragDirectionLock:r,dragPropagation:i,dragConstraints:s,dragElastic:o,dragMomentum:a}}}function Vi(e,t,n){return(t===!0||t===e)&&(n===null||n===e)}function y2(e,t=10){let n=null;return Math.abs(e.y)>t?n="y":Math.abs(e.x)>t&&(n="x"),n}class v2 extends Xt{constructor(t){super(t),this.removeGroupControls=Ge,this.removeListeners=Ge,this.controls=new g2(t)}mount(){const{dragControls:t}=this.node.getProps();t&&(this.removeGroupControls=t.subscribe(this.controls)),this.removeListeners=this.controls.addListeners()||Ge}unmount(){this.removeGroupControls(),this.removeListeners()}}const Td=e=>(t,n)=>{e&&G.postRender(()=>e(t,n))};class x2 extends Xt{constructor(){super(...arguments),this.removePointerDownListener=Ge}onPointerDown(t){this.session=new V0(t,this.createPanHandlers(),{transformPagePoint:this.node.getTransformPagePoint(),contextWindow:R0(this.node)})}createPanHandlers(){const{onPanSessionStart:t,onPanStart:n,onPan:r,onPanEnd:i}=this.node.getProps();return{onSessionStart:Td(t),onStart:Td(n),onMove:r,onEnd:(s,o)=>{delete this.session,i&&G.postRender(()=>i(s,o))}}}mount(){this.removePointerDownListener=Vr(this.node.current,"pointerdown",t=>this.onPointerDown(t))}update(){this.session&&this.session.updateHandlers(this.createPanHandlers())}unmount(){this.removePointerDownListener(),this.session&&this.session.end()}}const Zi={hasAnimatedSinceResize:!0,hasEverUpdated:!1};function Nd(e,t){return t.max===t.min?0:e/(t.max-t.min)*100}const yr={correct:(e,t)=>{if(!t.target)return e;if(typeof e=="string")if(R.test(e))e=parseFloat(e);else return e;const n=Nd(e,t.target.x),r=Nd(e,t.target.y);return`${n}% ${r}%`}},w2={correct:(e,{treeScale:t,projectionDelta:n})=>{const r=e,i=Kt.parse(e);if(i.length>5)return r;const s=Kt.createTransformer(e),o=typeof i[0]!="number"?1:0,a=n.x.scale*t.x,l=n.y.scale*t.y;i[0+o]/=a,i[1+o]/=l;const u=X(a,l,.5);return typeof i[2+o]=="number"&&(i[2+o]/=u),typeof i[3+o]=="number"&&(i[3+o]/=u),s(i)}};let Do=!1;class k2 extends S.Component{componentDidMount(){const{visualElement:t,layoutGroup:n,switchLayoutGroup:r,layoutId:i}=this.props,{projection:s}=t;Wv(S2),s&&(n.group&&n.group.add(s),r&&r.register&&i&&r.register(s),Do&&s.root.didUpdate(),s.addEventListener("animationComplete",()=>{this.safeToRemove()}),s.setOptions({...s.options,onExitComplete:()=>this.safeToRemove()})),Zi.hasEverUpdated=!0}getSnapshotBeforeUpdate(t){const{layoutDependency:n,visualElement:r,drag:i,isPresent:s}=this.props,{projection:o}=r;return o&&(o.isPresent=s,Do=!0,i||t.layoutDependency!==n||n===void 0||t.isPresent!==s?o.willUpdate():this.safeToRemove(),t.isPresent!==s&&(s?o.promote():o.relegate()||G.postRender(()=>{const a=o.getStack();(!a||!a.members.length)&&this.safeToRemove()}))),null}componentDidUpdate(){const{projection:t}=this.props.visualElement;t&&(t.root.didUpdate(),hu.postRender(()=>{!t.currentAnimation&&t.isLead()&&this.safeToRemove()}))}componentWillUnmount(){const{visualElement:t,layoutGroup:n,switchLayoutGroup:r}=this.props,{projection:i}=t;Do=!0,i&&(i.scheduleCheckAfterUnmount(),n&&n.group&&n.group.remove(i),r&&r.deregister&&r.deregister(i))}safeToRemove(){const{safeToRemove:t}=this.props;t&&t()}render(){return null}}function I0(e){const[t,n]=i0(),r=S.useContext(Hl);return d.jsx(k2,{...e,layoutGroup:r,switchLayoutGroup:S.useContext(g0),isPresent:t,safeToRemove:n})}const S2={borderRadius:{...yr,applyTo:["borderTopLeftRadius","borderTopRightRadius","borderBottomLeftRadius","borderBottomRightRadius"]},borderTopLeftRadius:yr,borderTopRightRadius:yr,borderBottomLeftRadius:yr,borderBottomRightRadius:yr,boxShadow:w2};function j2(e,t,n){const r=ke(e)?e:er(e);return r.start(Cu("",r,t,n)),r.animation}const C2=(e,t)=>e.depth-t.depth;class T2{constructor(){this.children=[],this.isDirty=!1}add(t){Yl(this.children,t),this.isDirty=!0}remove(t){Ql(this.children,t),this.isDirty=!0}forEach(t){this.isDirty&&this.children.sort(C2),this.isDirty=!1,this.children.forEach(t)}}function N2(e,t){const n=Le.now(),r=({timestamp:i})=>{const s=i-n;s>=t&&(Ht(r),e(s-t))};return G.setup(r,!0),()=>Ht(r)}const _0=["TopLeft","TopRight","BottomLeft","BottomRight"],P2=_0.length,Pd=e=>typeof e=="string"?parseFloat(e):e,Ed=e=>typeof e=="number"||R.test(e);function E2(e,t,n,r,i,s){i?(e.opacity=X(0,n.opacity??1,M2(r)),e.opacityExit=X(t.opacity??1,0,L2(r))):s&&(e.opacity=X(t.opacity??1,n.opacity??1,r));for(let o=0;ort?1:n(Jr(e,t,r))}function Ld(e,t){e.min=t.min,e.max=t.max}function Ze(e,t){Ld(e.x,t.x),Ld(e.y,t.y)}function Dd(e,t){e.translate=t.translate,e.scale=t.scale,e.originPoint=t.originPoint,e.origin=t.origin}function Ad(e,t,n,r,i){return e-=t,e=Ns(e,1/n,r),i!==void 0&&(e=Ns(e,1/i,r)),e}function D2(e,t=0,n=1,r=.5,i,s=e,o=e){if(dt.test(t)&&(t=parseFloat(t),t=X(o.min,o.max,t/100)-o.min),typeof t!="number")return;let a=X(s.min,s.max,r);e===s&&(a-=t),e.min=Ad(e.min,t,n,a,i),e.max=Ad(e.max,t,n,a,i)}function Rd(e,t,[n,r,i],s,o){D2(e,t[n],t[r],t[i],t.scale,s,o)}const A2=["x","scaleX","originX"],R2=["y","scaleY","originY"];function Vd(e,t,n,r){Rd(e.x,t,A2,n?n.x:void 0,r?r.x:void 0),Rd(e.y,t,R2,n?n.y:void 0,r?r.y:void 0)}function bd(e){return e.translate===0&&e.scale===1}function O0(e){return bd(e.x)&&bd(e.y)}function Id(e,t){return e.min===t.min&&e.max===t.max}function V2(e,t){return Id(e.x,t.x)&&Id(e.y,t.y)}function _d(e,t){return Math.round(e.min)===Math.round(t.min)&&Math.round(e.max)===Math.round(t.max)}function B0(e,t){return _d(e.x,t.x)&&_d(e.y,t.y)}function Fd(e){return Ce(e.x)/Ce(e.y)}function Od(e,t){return e.translate===t.translate&&e.scale===t.scale&&e.originPoint===t.originPoint}class b2{constructor(){this.members=[]}add(t){Yl(this.members,t),t.scheduleRender()}remove(t){if(Ql(this.members,t),t===this.prevLead&&(this.prevLead=void 0),t===this.lead){const n=this.members[this.members.length-1];n&&this.promote(n)}}relegate(t){const n=this.members.findIndex(i=>t===i);if(n===0)return!1;let r;for(let i=n;i>=0;i--){const s=this.members[i];if(s.isPresent!==!1){r=s;break}}return r?(this.promote(r),!0):!1}promote(t,n){const r=this.lead;if(t!==r&&(this.prevLead=r,this.lead=t,t.show(),r)){r.instance&&r.scheduleRender(),t.scheduleRender(),t.resumeFrom=r,n&&(t.resumeFrom.preserveOpacity=!0),r.snapshot&&(t.snapshot=r.snapshot,t.snapshot.latestValues=r.animationValues||r.latestValues),t.root&&t.root.isUpdating&&(t.isLayoutDirty=!0);const{crossfade:i}=t.options;i===!1&&r.hide()}}exitAnimationComplete(){this.members.forEach(t=>{const{options:n,resumingFrom:r}=t;n.onExitComplete&&n.onExitComplete(),r&&r.options.onExitComplete&&r.options.onExitComplete()})}scheduleRender(){this.members.forEach(t=>{t.instance&&t.scheduleRender(!1)})}removeLeadSnapshot(){this.lead&&this.lead.snapshot&&(this.lead.snapshot=void 0)}}function I2(e,t,n){let r="";const i=e.x.translate/t.x,s=e.y.translate/t.y,o=(n==null?void 0:n.z)||0;if((i||s||o)&&(r=`translate3d(${i}px, ${s}px, ${o}px) `),(t.x!==1||t.y!==1)&&(r+=`scale(${1/t.x}, ${1/t.y}) `),n){const{transformPerspective:u,rotate:c,rotateX:h,rotateY:f,skewX:v,skewY:x}=n;u&&(r=`perspective(${u}px) ${r}`),c&&(r+=`rotate(${c}deg) `),h&&(r+=`rotateX(${h}deg) `),f&&(r+=`rotateY(${f}deg) `),v&&(r+=`skewX(${v}deg) `),x&&(r+=`skewY(${x}deg) `)}const a=e.x.scale*t.x,l=e.y.scale*t.y;return(a!==1||l!==1)&&(r+=`scale(${a}, ${l})`),r||"none"}const Ao=["","X","Y","Z"],_2=1e3;let F2=0;function Ro(e,t,n,r){const{latestValues:i}=t;i[e]&&(n[e]=i[e],t.setStaticValue(e,0),r&&(r[e]=0))}function z0(e){if(e.hasCheckedOptimisedAppear=!0,e.root===e)return;const{visualElement:t}=e.options;if(!t)return;const n=N0(t);if(window.MotionHasOptimisedAnimation(n,"transform")){const{layout:i,layoutId:s}=e.options;window.MotionCancelOptimisedAnimation(n,"transform",G,!(i||s))}const{parent:r}=e;r&&!r.hasCheckedOptimisedAppear&&z0(r)}function U0({attachResizeListener:e,defaultParent:t,measureScroll:n,checkIsScrollRoot:r,resetTransform:i}){return class{constructor(o={},a=t==null?void 0:t()){this.id=F2++,this.animationId=0,this.animationCommitId=0,this.children=new Set,this.options={},this.isTreeAnimating=!1,this.isAnimationBlocked=!1,this.isLayoutDirty=!1,this.isProjectionDirty=!1,this.isSharedProjectionDirty=!1,this.isTransformDirty=!1,this.updateManuallyBlocked=!1,this.updateBlockedByResize=!1,this.isUpdating=!1,this.isSVG=!1,this.needsReset=!1,this.shouldResetTransform=!1,this.hasCheckedOptimisedAppear=!1,this.treeScale={x:1,y:1},this.eventHandlers=new Map,this.hasTreeAnimated=!1,this.layoutVersion=0,this.updateScheduled=!1,this.scheduleUpdate=()=>this.update(),this.projectionUpdateScheduled=!1,this.checkUpdateFailed=()=>{this.isUpdating&&(this.isUpdating=!1,this.clearAllSnapshots())},this.updateProjection=()=>{this.projectionUpdateScheduled=!1,this.nodes.forEach(z2),this.nodes.forEach(H2),this.nodes.forEach(K2),this.nodes.forEach(U2)},this.resolvedRelativeTargetAt=0,this.linkedParentVersion=0,this.hasProjected=!1,this.isVisible=!0,this.animationProgress=0,this.sharedNodes=new Map,this.latestValues=o,this.root=a?a.root||a:this,this.path=a?[...a.path,a]:[],this.parent=a,this.depth=a?a.depth+1:0;for(let l=0;lthis.root.updateBlockedByResize=!1;G.read(()=>{h=window.innerWidth}),e(o,()=>{const v=window.innerWidth;v!==h&&(h=v,this.root.updateBlockedByResize=!0,c&&c(),c=N2(f,250),Zi.hasAnimatedSinceResize&&(Zi.hasAnimatedSinceResize=!1,this.nodes.forEach(Ud)))})}a&&this.root.registerSharedNode(a,this),this.options.animate!==!1&&u&&(a||l)&&this.addEventListener("didUpdate",({delta:c,hasLayoutChanged:h,hasRelativeLayoutChanged:f,layout:v})=>{if(this.isTreeAnimationBlocked()){this.target=void 0,this.relativeTarget=void 0;return}const x=this.options.transition||u.getDefaultTransition()||Z2,{onLayoutAnimationStart:y,onLayoutAnimationComplete:T}=u.getProps(),m=!this.targetLayout||!B0(this.targetLayout,v),p=!h&&f;if(this.options.layoutRoot||this.resumeFrom||p||h&&(m||!this.currentAnimation)){this.resumeFrom&&(this.resumingFrom=this.resumeFrom,this.resumingFrom.resumingFrom=void 0);const g={...du(x,"layout"),onPlay:y,onComplete:T};(u.shouldReduceMotion||this.options.layoutRoot)&&(g.delay=0,g.type=!1),this.startAnimation(g),this.setAnimationOrigin(c,p)}else h||Ud(this),this.isLead()&&this.options.onExitComplete&&this.options.onExitComplete();this.targetLayout=v})}unmount(){this.options.layoutId&&this.willUpdate(),this.root.nodes.remove(this);const o=this.getStack();o&&o.remove(this),this.parent&&this.parent.children.delete(this),this.instance=void 0,this.eventHandlers.clear(),Ht(this.updateProjection)}blockUpdate(){this.updateManuallyBlocked=!0}unblockUpdate(){this.updateManuallyBlocked=!1}isUpdateBlocked(){return this.updateManuallyBlocked||this.updateBlockedByResize}isTreeAnimationBlocked(){return this.isAnimationBlocked||this.parent&&this.parent.isTreeAnimationBlocked()||!1}startUpdate(){this.isUpdateBlocked()||(this.isUpdating=!0,this.nodes&&this.nodes.forEach(G2),this.animationId++)}getTransformTemplate(){const{visualElement:o}=this.options;return o&&o.getProps().transformTemplate}willUpdate(o=!0){if(this.root.hasTreeAnimated=!0,this.root.isUpdateBlocked()){this.options.onExitComplete&&this.options.onExitComplete();return}if(window.MotionCancelOptimisedAnimation&&!this.hasCheckedOptimisedAppear&&z0(this),!this.root.isUpdating&&this.root.startUpdate(),this.isLayoutDirty)return;this.isLayoutDirty=!0;for(let c=0;c{this.isLayoutDirty?this.root.didUpdate():this.root.checkUpdateFailed()})}updateSnapshot(){this.snapshot||!this.instance||(this.snapshot=this.measure(),this.snapshot&&!Ce(this.snapshot.measuredBox.x)&&!Ce(this.snapshot.measuredBox.y)&&(this.snapshot=void 0))}updateLayout(){if(!this.instance||(this.updateScroll(),!(this.options.alwaysMeasureLayout&&this.isLead())&&!this.isLayoutDirty))return;if(this.resumeFrom&&!this.resumeFrom.instance)for(let l=0;l{const k=w/1e3;Wd(h.x,o.x,k),Wd(h.y,o.y,k),this.setTargetDelta(h),this.relativeTarget&&this.relativeTargetOrigin&&this.layout&&this.relativeParent&&this.relativeParent.layout&&(Ps(f,this.layout.layoutBox,this.relativeParent.layout.layoutBox),Q2(this.relativeTarget,this.relativeTargetOrigin,f,k),g&&V2(this.relativeTarget,g)&&(this.isProjectionDirty=!1),g||(g=oe()),Ze(g,this.relativeTarget)),y&&(this.animationValues=c,E2(c,u,this.latestValues,k,p,m)),this.root.scheduleUpdateProjection(),this.scheduleRender(),this.animationProgress=k},this.mixTargetDelta(this.options.layoutRoot?1e3:0)}startAnimation(o){var a,l,u;this.notifyListeners("animationStart"),(a=this.currentAnimation)==null||a.stop(),(u=(l=this.resumingFrom)==null?void 0:l.currentAnimation)==null||u.stop(),this.pendingAnimation&&(Ht(this.pendingAnimation),this.pendingAnimation=void 0),this.pendingAnimation=G.update(()=>{Zi.hasAnimatedSinceResize=!0,this.motionValue||(this.motionValue=er(0)),this.currentAnimation=j2(this.motionValue,[0,1e3],{...o,velocity:0,isSync:!0,onUpdate:c=>{this.mixTargetDelta(c),o.onUpdate&&o.onUpdate(c)},onStop:()=>{},onComplete:()=>{o.onComplete&&o.onComplete(),this.completeAnimation()}}),this.resumingFrom&&(this.resumingFrom.currentAnimation=this.currentAnimation),this.pendingAnimation=void 0})}completeAnimation(){this.resumingFrom&&(this.resumingFrom.currentAnimation=void 0,this.resumingFrom.preserveOpacity=void 0);const o=this.getStack();o&&o.exitAnimationComplete(),this.resumingFrom=this.currentAnimation=this.animationValues=void 0,this.notifyListeners("animationComplete")}finishAnimation(){this.currentAnimation&&(this.mixTargetDelta&&this.mixTargetDelta(_2),this.currentAnimation.stop()),this.completeAnimation()}applyTransformsToTarget(){const o=this.getLead();let{targetWithTransforms:a,target:l,layout:u,latestValues:c}=o;if(!(!a||!l||!u)){if(this!==o&&this.layout&&u&&W0(this.options.animationType,this.layout.layoutBox,u.layoutBox)){l=this.target||oe();const h=Ce(this.layout.layoutBox.x);l.x.min=o.target.x.min,l.x.max=l.x.min+h;const f=Ce(this.layout.layoutBox.y);l.y.min=o.target.y.min,l.y.max=l.y.min+f}Ze(a,l),Fn(a,c),br(this.projectionDeltaWithTransform,this.layoutCorrected,a,c)}}registerSharedNode(o,a){this.sharedNodes.has(o)||this.sharedNodes.set(o,new b2),this.sharedNodes.get(o).add(a);const u=a.options.initialPromotionConfig;a.promote({transition:u?u.transition:void 0,preserveFollowOpacity:u&&u.shouldPreserveFollowOpacity?u.shouldPreserveFollowOpacity(a):void 0})}isLead(){const o=this.getStack();return o?o.lead===this:!0}getLead(){var a;const{layoutId:o}=this.options;return o?((a=this.getStack())==null?void 0:a.lead)||this:this}getPrevLead(){var a;const{layoutId:o}=this.options;return o?(a=this.getStack())==null?void 0:a.prevLead:void 0}getStack(){const{layoutId:o}=this.options;if(o)return this.root.sharedNodes.get(o)}promote({needsReset:o,transition:a,preserveFollowOpacity:l}={}){const u=this.getStack();u&&u.promote(this,l),o&&(this.projectionDelta=void 0,this.needsReset=!0),a&&this.setOptions({transition:a})}relegate(){const o=this.getStack();return o?o.relegate(this):!1}resetSkewAndRotation(){const{visualElement:o}=this.options;if(!o)return;let a=!1;const{latestValues:l}=o;if((l.z||l.rotate||l.rotateX||l.rotateY||l.rotateZ||l.skewX||l.skewY)&&(a=!0),!a)return;const u={};l.z&&Ro("z",o,u,this.animationValues);for(let c=0;c{var a;return(a=o.currentAnimation)==null?void 0:a.stop()}),this.root.nodes.forEach(Bd),this.root.sharedNodes.clear()}}}function O2(e){e.updateLayout()}function B2(e){var n;const t=((n=e.resumeFrom)==null?void 0:n.snapshot)||e.snapshot;if(e.isLead()&&e.layout&&t&&e.hasListeners("didUpdate")){const{layoutBox:r,measuredBox:i}=e.layout,{animationType:s}=e.options,o=t.source!==e.layout.source;s==="size"?ze(h=>{const f=o?t.measuredBox[h]:t.layoutBox[h],v=Ce(f);f.min=r[h].min,f.max=f.min+v}):W0(s,t.layoutBox,r)&&ze(h=>{const f=o?t.measuredBox[h]:t.layoutBox[h],v=Ce(r[h]);f.max=f.min+v,e.relativeTarget&&!e.currentAnimation&&(e.isProjectionDirty=!0,e.relativeTarget[h].max=e.relativeTarget[h].min+v)});const a=On();br(a,r,t.layoutBox);const l=On();o?br(l,e.applyTransform(i,!0),t.measuredBox):br(l,r,t.layoutBox);const u=!O0(a);let c=!1;if(!e.resumeFrom){const h=e.getClosestProjectingParent();if(h&&!h.resumeFrom){const{snapshot:f,layout:v}=h;if(f&&v){const x=oe();Ps(x,t.layoutBox,f.layoutBox);const y=oe();Ps(y,r,v.layoutBox),B0(x,y)||(c=!0),h.options.layoutRoot&&(e.relativeTarget=y,e.relativeTargetOrigin=x,e.relativeParent=h)}}}e.notifyListeners("didUpdate",{layout:r,snapshot:t,delta:l,layoutDelta:a,hasLayoutChanged:u,hasRelativeLayoutChanged:c})}else if(e.isLead()){const{onExitComplete:r}=e.options;r&&r()}e.options.transition=void 0}function z2(e){e.parent&&(e.isProjecting()||(e.isProjectionDirty=e.parent.isProjectionDirty),e.isSharedProjectionDirty||(e.isSharedProjectionDirty=!!(e.isProjectionDirty||e.parent.isProjectionDirty||e.parent.isSharedProjectionDirty)),e.isTransformDirty||(e.isTransformDirty=e.parent.isTransformDirty))}function U2(e){e.isProjectionDirty=e.isSharedProjectionDirty=e.isTransformDirty=!1}function W2(e){e.clearSnapshot()}function Bd(e){e.clearMeasurements()}function zd(e){e.isLayoutDirty=!1}function $2(e){const{visualElement:t}=e.options;t&&t.getProps().onBeforeLayoutMeasure&&t.notify("BeforeLayoutMeasure"),e.resetTransform()}function Ud(e){e.finishAnimation(),e.targetDelta=e.relativeTarget=e.target=void 0,e.isProjectionDirty=!0}function H2(e){e.resolveTargetDelta()}function K2(e){e.calcProjection()}function G2(e){e.resetSkewAndRotation()}function Y2(e){e.removeLeadSnapshot()}function Wd(e,t,n){e.translate=X(t.translate,0,n),e.scale=X(t.scale,1,n),e.origin=t.origin,e.originPoint=t.originPoint}function $d(e,t,n,r){e.min=X(t.min,n.min,r),e.max=X(t.max,n.max,r)}function Q2(e,t,n,r){$d(e.x,t.x,n.x,r),$d(e.y,t.y,n.y,r)}function X2(e){return e.animationValues&&e.animationValues.opacityExit!==void 0}const Z2={duration:.45,ease:[.4,0,.1,1]},Hd=e=>typeof navigator<"u"&&navigator.userAgent&&navigator.userAgent.toLowerCase().includes(e),Kd=Hd("applewebkit/")&&!Hd("chrome/")?Math.round:Ge;function Gd(e){e.min=Kd(e.min),e.max=Kd(e.max)}function q2(e){Gd(e.x),Gd(e.y)}function W0(e,t,n){return e==="position"||e==="preserve-aspect"&&!i2(Fd(t),Fd(n),.2)}function J2(e){var t;return e!==e.root&&((t=e.scroll)==null?void 0:t.wasRoot)}const e3=U0({attachResizeListener:(e,t)=>ii(e,"resize",t),measureScroll:()=>({x:document.documentElement.scrollLeft||document.body.scrollLeft,y:document.documentElement.scrollTop||document.body.scrollTop}),checkIsScrollRoot:()=>!0}),Vo={current:void 0},$0=U0({measureScroll:e=>({x:e.scrollLeft,y:e.scrollTop}),defaultParent:()=>{if(!Vo.current){const e=new e3({});e.mount(window),e.setOptions({layoutScroll:!0}),Vo.current=e}return Vo.current},resetTransform:(e,t)=>{e.style.transform=t!==void 0?t:"none"},checkIsScrollRoot:e=>window.getComputedStyle(e).position==="fixed"}),t3={pan:{Feature:x2},drag:{Feature:v2,ProjectionNode:$0,MeasureLayout:I0}};function Yd(e,t,n){const{props:r}=e;e.animationState&&r.whileHover&&e.animationState.setActive("whileHover",n==="Start");const i="onHover"+n,s=r[i];s&&G.postRender(()=>s(t,hi(t)))}class n3 extends Xt{mount(){const{current:t}=this.node;t&&(this.unmount=jv(t,(n,r)=>(Yd(this.node,r,"Start"),i=>Yd(this.node,i,"End"))))}unmount(){}}class r3 extends Xt{constructor(){super(...arguments),this.isActive=!1}onFocus(){let t=!1;try{t=this.node.current.matches(":focus-visible")}catch{t=!0}!t||!this.node.animationState||(this.node.animationState.setActive("whileFocus",!0),this.isActive=!0)}onBlur(){!this.isActive||!this.node.animationState||(this.node.animationState.setActive("whileFocus",!1),this.isActive=!1)}mount(){this.unmount=ci(ii(this.node.current,"focus",()=>this.onFocus()),ii(this.node.current,"blur",()=>this.onBlur()))}unmount(){}}function Qd(e,t,n){const{props:r}=e;if(e.current instanceof HTMLButtonElement&&e.current.disabled)return;e.animationState&&r.whileTap&&e.animationState.setActive("whileTap",n==="Start");const i="onTap"+(n==="End"?"":n),s=r[i];s&&G.postRender(()=>s(t,hi(t)))}class i3 extends Xt{mount(){const{current:t}=this.node;t&&(this.unmount=Pv(t,(n,r)=>(Qd(this.node,r,"Start"),(i,{success:s})=>Qd(this.node,i,s?"End":"Cancel")),{useGlobalTarget:this.node.props.globalTapTarget}))}unmount(){}}const Xa=new WeakMap,bo=new WeakMap,s3=e=>{const t=Xa.get(e.target);t&&t(e)},o3=e=>{e.forEach(s3)};function a3({root:e,...t}){const n=e||document;bo.has(n)||bo.set(n,{});const r=bo.get(n),i=JSON.stringify(t);return r[i]||(r[i]=new IntersectionObserver(o3,{root:e,...t})),r[i]}function l3(e,t,n){const r=a3(t);return Xa.set(e,n),r.observe(e),()=>{Xa.delete(e),r.unobserve(e)}}const u3={some:0,all:1};class c3 extends Xt{constructor(){super(...arguments),this.hasEnteredView=!1,this.isInView=!1}startObserver(){this.unmount();const{viewport:t={}}=this.node.getProps(),{root:n,margin:r,amount:i="some",once:s}=t,o={root:n?n.current:void 0,rootMargin:r,threshold:typeof i=="number"?i:u3[i]},a=l=>{const{isIntersecting:u}=l;if(this.isInView===u||(this.isInView=u,s&&!u&&this.hasEnteredView))return;u&&(this.hasEnteredView=!0),this.node.animationState&&this.node.animationState.setActive("whileInView",u);const{onViewportEnter:c,onViewportLeave:h}=this.node.getProps(),f=u?c:h;f&&f(l)};return l3(this.node.current,o,a)}mount(){this.startObserver()}update(){if(typeof IntersectionObserver>"u")return;const{props:t,prevProps:n}=this.node;["amount","margin","root"].some(d3(t,n))&&this.startObserver()}unmount(){}}function d3({viewport:e={}},{viewport:t={}}={}){return n=>e[n]!==t[n]}const f3={inView:{Feature:c3},tap:{Feature:i3},focus:{Feature:r3},hover:{Feature:n3}},h3={layout:{ProjectionNode:$0,MeasureLayout:I0}},p3={...qx,...f3,...t3,...h3},B=px(p3,Px),Zt="/api";async function m3(){return(await fetch(`${Zt}/state`)).json()}async function Xd(){return(await fetch(`${Zt}/dependencies/check`)).json()}async function Zd(){return(await fetch(`${Zt}/docker/status`)).json()}function Io(e){let t=null,n=!1;const r=()=>{n||(t=new EventSource(`${Zt}/docker/status/stream`),t.onmessage=i=>{try{const s=JSON.parse(i.data);e(s)}catch(s){console.error("Failed to parse docker status:",s)}},t.onerror=()=>{t==null||t.close(),n||setTimeout(r,1e3)})};return r(),()=>{n=!0,t==null||t.close()}}async function g3(){return(await fetch(`${Zt}/docker/build`,{method:"POST"})).json()}async function bi(){return(await fetch(`${Zt}/defaults`)).json()}async function qd(e){return(await fetch(`${Zt}/defaults`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify(e)})).json()}async function y3(){return(await fetch(`${Zt}/signing/status`)).json()}const H0="/assets/wails-logo-white-text-B284k7fX.svg",K0="/assets/wails-logo-black-text-Cx-vsZ4W.svg",v3={initial:{opacity:0},animate:{opacity:1},exit:{opacity:0}},Jd={darwin:{name:"macOS",icon:"🍎"},windows:{name:"Windows",icon:"🪟"},linux:{name:"Linux",icon:"🐧"}};function x3({onNext:e,onSkip:t,onBack:n,canGoBack:r}){const[i,s]=S.useState(null),[o,a]=S.useState(!0),[l,u]=S.useState("darwin"),c=S.useRef(null);S.useEffect(()=>{var y;(y=c.current)==null||y.focus(),h()},[]);const h=async()=>{try{const y=await y3();s(y)}catch(y){console.error("Failed to load signing status:",y)}finally{a(!1)}},f=()=>{if(!i)return null;if(l==="darwin"){const y=i.darwin;return d.jsxs("div",{className:"space-y-4",children:[d.jsxs("div",{className:"flex items-center gap-3 p-4 rounded-lg bg-gray-100 dark:bg-gray-900/50",children:[d.jsx("div",{className:`w-8 h-8 rounded-full flex items-center justify-center ${y.hasIdentity?"bg-green-500/20":"bg-gray-200 dark:bg-gray-800"}`,children:y.hasIdentity?d.jsx("svg",{className:"w-4 h-4 text-green-500",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",children:d.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2.5,d:"M5 13l4 4L19 7"})}):d.jsx("svg",{className:"w-4 h-4 text-gray-400",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",children:d.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M6 18L18 6M6 6l12 12"})})}),d.jsxs("div",{className:"flex-1",children:[d.jsx("div",{className:"text-sm font-medium text-gray-900 dark:text-white",children:"Code Signing Identity"}),d.jsx("div",{className:"text-xs text-gray-500 dark:text-gray-400",children:y.hasIdentity?y.identity:"Not configured"})]}),y.configSource&&d.jsx("span",{className:"text-xs px-2 py-1 rounded-full bg-gray-200 dark:bg-gray-800 text-gray-600 dark:text-gray-400",children:y.configSource})]}),d.jsxs("div",{className:"flex items-center gap-3 p-4 rounded-lg bg-gray-100 dark:bg-gray-900/50",children:[d.jsx("div",{className:`w-8 h-8 rounded-full flex items-center justify-center ${y.hasNotarization?"bg-green-500/20":"bg-gray-200 dark:bg-gray-800"}`,children:y.hasNotarization?d.jsx("svg",{className:"w-4 h-4 text-green-500",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",children:d.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2.5,d:"M5 13l4 4L19 7"})}):d.jsx("svg",{className:"w-4 h-4 text-gray-400",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",children:d.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M6 18L18 6M6 6l12 12"})})}),d.jsxs("div",{className:"flex-1",children:[d.jsx("div",{className:"text-sm font-medium text-gray-900 dark:text-white",children:"Notarization"}),d.jsx("div",{className:"text-xs text-gray-500 dark:text-gray-400",children:y.hasNotarization?`Team ID: ${y.teamID||"Configured"}`:"Not configured"})]})]}),y.identities&&y.identities.length>1&&d.jsxs("div",{className:"text-xs text-gray-500 dark:text-gray-400 p-3 rounded-lg bg-blue-50 dark:bg-blue-900/20 border border-blue-200 dark:border-blue-800",children:[d.jsxs("span",{className:"font-medium",children:[y.identities.length," signing identities"]})," found in keychain"]})]})}if(l==="windows"){const y=i.windows;return d.jsxs("div",{className:"space-y-4",children:[d.jsxs("div",{className:"flex items-center gap-3 p-4 rounded-lg bg-gray-100 dark:bg-gray-900/50",children:[d.jsx("div",{className:`w-8 h-8 rounded-full flex items-center justify-center ${y.hasCertificate?"bg-green-500/20":"bg-gray-200 dark:bg-gray-800"}`,children:y.hasCertificate?d.jsx("svg",{className:"w-4 h-4 text-green-500",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",children:d.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2.5,d:"M5 13l4 4L19 7"})}):d.jsx("svg",{className:"w-4 h-4 text-gray-400",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",children:d.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M6 18L18 6M6 6l12 12"})})}),d.jsxs("div",{className:"flex-1",children:[d.jsx("div",{className:"text-sm font-medium text-gray-900 dark:text-white",children:"Code Signing Certificate"}),d.jsx("div",{className:"text-xs text-gray-500 dark:text-gray-400",children:y.hasCertificate?`Type: ${y.certificateType}`:"Not configured"})]}),y.configSource&&d.jsx("span",{className:"text-xs px-2 py-1 rounded-full bg-gray-200 dark:bg-gray-800 text-gray-600 dark:text-gray-400",children:y.configSource})]}),d.jsxs("div",{className:"flex items-center gap-3 p-4 rounded-lg bg-gray-100 dark:bg-gray-900/50",children:[d.jsx("div",{className:`w-8 h-8 rounded-full flex items-center justify-center ${y.hasSignTool?"bg-green-500/20":"bg-gray-200 dark:bg-gray-800"}`,children:y.hasSignTool?d.jsx("svg",{className:"w-4 h-4 text-green-500",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",children:d.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2.5,d:"M5 13l4 4L19 7"})}):d.jsx("svg",{className:"w-4 h-4 text-gray-400",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",children:d.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M6 18L18 6M6 6l12 12"})})}),d.jsxs("div",{className:"flex-1",children:[d.jsx("div",{className:"text-sm font-medium text-gray-900 dark:text-white",children:"SignTool"}),d.jsx("div",{className:"text-xs text-gray-500 dark:text-gray-400",children:y.hasSignTool?"Available":"Not found (Windows SDK required)"})]})]}),y.timestampServer&&d.jsxs("div",{className:"text-xs text-gray-500 dark:text-gray-400 p-3 rounded-lg bg-gray-50 dark:bg-gray-800/50",children:["Timestamp server: ",d.jsx("code",{className:"font-mono",children:y.timestampServer})]})]})}if(l==="linux"){const y=i.linux;return d.jsx("div",{className:"space-y-4",children:d.jsxs("div",{className:"flex items-center gap-3 p-4 rounded-lg bg-gray-100 dark:bg-gray-900/50",children:[d.jsx("div",{className:`w-8 h-8 rounded-full flex items-center justify-center ${y.hasGpgKey?"bg-green-500/20":"bg-gray-200 dark:bg-gray-800"}`,children:y.hasGpgKey?d.jsx("svg",{className:"w-4 h-4 text-green-500",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",children:d.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2.5,d:"M5 13l4 4L19 7"})}):d.jsx("svg",{className:"w-4 h-4 text-gray-400",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",children:d.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M6 18L18 6M6 6l12 12"})})}),d.jsxs("div",{className:"flex-1",children:[d.jsx("div",{className:"text-sm font-medium text-gray-900 dark:text-white",children:"GPG Signing Key"}),d.jsx("div",{className:"text-xs text-gray-500 dark:text-gray-400",children:y.hasGpgKey?`Key ID: ${y.gpgKeyID}`:"Not configured"})]}),y.configSource&&d.jsx("span",{className:"text-xs px-2 py-1 rounded-full bg-gray-200 dark:bg-gray-800 text-gray-600 dark:text-gray-400",children:y.configSource})]})})}return null},x=(()=>{if(!i)return{configured:0,total:3};let y=0;return i.darwin.hasIdentity&&y++,i.windows.hasCertificate&&y++,i.linux.hasGpgKey&&y++,{configured:y,total:3}})();return d.jsxs(B.main,{variants:v3,initial:"initial",animate:"animate",exit:"exit",transition:{duration:.3},className:"flex-1 flex flex-col","aria-labelledby":"signing-title",children:[d.jsxs("header",{className:"text-center mb-6 flex-shrink-0 px-10 pt-10",children:[d.jsx("h1",{ref:c,id:"signing-title",className:"text-2xl font-semibold text-gray-900 dark:text-white mb-1.5 tracking-tight focus:outline-none",tabIndex:-1,children:"Code Signing"}),d.jsx("p",{className:"text-base text-gray-500 dark:text-gray-400",children:x.configured>0?`${x.configured} of ${x.total} platforms configured`:"Sign your apps for distribution"})]}),d.jsx("div",{className:"flex-1 overflow-y-auto scrollbar-thin min-h-0 px-10",children:o?d.jsx("div",{className:"flex items-center justify-center h-48",children:d.jsx(B.div,{className:"w-8 h-8 border-2 border-gray-300 dark:border-gray-600 border-t-red-500 rounded-full",animate:{rotate:360},transition:{duration:1,repeat:1/0,ease:"linear"}})}):d.jsxs("div",{className:"max-w-xl mx-auto",children:[d.jsx("div",{className:"flex gap-2 mb-6",role:"tablist",children:["darwin","windows","linux"].map(y=>{const T=Jd[y],m=l===y,p=i&&(y==="darwin"&&i.darwin.hasIdentity||y==="windows"&&i.windows.hasCertificate||y==="linux"&&i.linux.hasGpgKey);return d.jsxs("button",{role:"tab","aria-selected":m,onClick:()=>u(y),className:`flex-1 flex items-center justify-center gap-2 px-4 py-3 rounded-lg text-sm font-medium transition-all ${m?"bg-gray-100 dark:bg-gray-800 text-gray-900 dark:text-white":"text-gray-500 dark:text-gray-400 hover:bg-gray-50 dark:hover:bg-gray-800/50"}`,children:[d.jsx("span",{className:"text-lg",children:T.icon}),d.jsx("span",{children:T.name}),p&&d.jsx("span",{className:"w-2 h-2 rounded-full bg-green-500"})]},y)})}),d.jsx("div",{role:"tabpanel","aria-label":`${Jd[l].name} signing status`,children:f()}),d.jsx("p",{className:"text-xs text-gray-500 dark:text-gray-400 mt-6 text-center",children:"Code signing ensures your app is trusted and hasn't been tampered with"})]})}),d.jsxs("div",{className:"flex-shrink-0 pt-4 pb-6 flex flex-col items-center gap-1.5",children:[d.jsxs("div",{className:"flex items-center gap-3",children:[r&&n&&d.jsx("button",{onClick:n,className:"px-4 py-2 rounded-lg text-sm font-medium transition-colors border border-gray-300 dark:border-gray-600 text-gray-600 dark:text-gray-400 hover:bg-gray-100 dark:hover:bg-gray-800 focus:outline-none focus:ring-2 focus:ring-gray-500 focus:ring-offset-2 dark:focus:ring-offset-gray-900",children:"Back"}),d.jsx("button",{onClick:e,className:"px-5 py-2 rounded-lg text-sm font-medium transition-colors border border-red-500 text-red-600 dark:text-red-400 hover:bg-red-500/10 focus:outline-none focus:ring-2 focus:ring-red-500 focus:ring-offset-2 dark:focus:ring-offset-gray-900",children:"Continue"})]}),d.jsx("button",{onClick:t,className:"text-xs text-gray-500 dark:text-gray-400 hover:text-gray-700 dark:hover:text-gray-300 transition-colors focus:outline-none focus:ring-2 focus:ring-gray-500 focus:ring-offset-2 dark:focus:ring-offset-gray-900 rounded",children:"Set up later"})]})]})}function w3(e){switch(e){case"splash":case"checking":return"welcome";case"deps-ready":case"deps-missing":return"dependencies";case"cross-platform":case"docker-setup":return"platform";case"projects":case"signing":return"identity";case"language-select":case"binding-style":case"template-select":return"templates";case"complete":return"complete";default:return"welcome"}}function k3(e){return["welcome","dependencies","platform","identity","templates","complete"].indexOf(e)+1}const G0=S.createContext({theme:"dark",toggleTheme:()=>{}}),Y0=()=>S.useContext(G0),we={initial:{opacity:0},animate:{opacity:1},exit:{opacity:0}};function S3({currentStep:e,dockerStatus:t,buildingDocker:n}){const{theme:r,toggleTheme:i}=Y0(),s=w3(e),o=k3(s),a=[{key:"welcome",label:"Welcome"},{key:"dependencies",label:"Dependencies"},{key:"platform",label:"Platform"},{key:"identity",label:"Projects"},{key:"templates",label:"Templates"},{key:"complete",label:"Complete"}],l=()=>{window.open("https://github.com/sponsors/leaanthony","_blank","noopener,noreferrer")},u=n;return d.jsxs("aside",{className:"w-48 flex-shrink-0 bg-gray-100/80 dark:bg-transparent dark:glass-sidebar border-r border-gray-200 dark:border-transparent flex flex-col","aria-label":"Setup progress",children:[d.jsx("div",{className:"p-6 flex justify-center",children:d.jsx("img",{src:r==="dark"?H0:K0,alt:"Wails logo",className:"h-24 object-contain"})}),d.jsx("nav",{className:"flex-1 px-4 py-2","aria-label":"Setup steps",children:d.jsx("ol",{className:"space-y-1",children:a.map((c,h)=>{const f=h+1,v=c.key===s,x=f{var f;(f=c.current)==null||f.focus()},[e]);const h=r||s?d.jsxs("div",{className:"flex-shrink-0 pt-4 pb-6 flex flex-col items-center gap-1.5",role:"group","aria-label":"Page actions",children:[d.jsxs("div",{className:"flex items-center gap-3",children:[u&&l&&d.jsx("button",{onClick:l,className:"px-4 py-2 rounded-lg text-sm font-medium transition-colors border border-gray-300 dark:border-gray-600 text-gray-600 dark:text-gray-400 hover:bg-gray-100 dark:hover:bg-gray-800 focus:outline-none focus:ring-2 focus:ring-gray-500 focus:ring-offset-2 dark:focus:ring-offset-gray-900",children:"Back"}),r&&i&&d.jsx("button",{onClick:r,disabled:a,className:`px-5 py-2 rounded-lg text-sm font-medium transition-colors border focus:outline-none focus:ring-2 focus:ring-red-500 focus:ring-offset-2 dark:focus:ring-offset-gray-900 ${a?"border-gray-300 dark:border-gray-700 text-gray-400 cursor-not-allowed":"border-red-500 text-red-600 dark:text-red-400 hover:bg-red-500/10"}`,"aria-disabled":a,children:i})]}),s&&o&&d.jsx("button",{onClick:s,className:"text-xs text-gray-500 dark:text-gray-400 hover:text-gray-700 dark:hover:text-gray-300 transition-colors focus:outline-none focus:ring-2 focus:ring-gray-500 focus:ring-offset-2 dark:focus:ring-offset-gray-900 rounded",children:o})]}):null;return d.jsxs(B.main,{variants:we,initial:"initial",animate:"animate",exit:"exit",transition:{duration:.3},className:"flex-1 flex flex-col","aria-labelledby":"page-title",children:[d.jsxs("header",{className:"text-center mb-6 flex-shrink-0 px-10 pt-10",children:[d.jsx("h1",{ref:c,id:"page-title",className:"text-2xl font-semibold text-gray-900 dark:text-white mb-1.5 tracking-tight focus:outline-none",tabIndex:-1,children:e}),d.jsx("p",{className:"text-base text-gray-500 dark:text-gray-400",children:t})]}),d.jsx("div",{className:"flex-1 overflow-y-auto scrollbar-thin min-h-0 px-10",children:n}),h]})}function j3({onNext:e}){const{theme:t}=Y0(),n=S.useRef(null),r=S.useRef(null);S.useEffect(()=>{var s;(s=n.current)==null||s.focus()},[]);const i=s=>{s.key==="Enter"&&document.activeElement===r.current&&e()};return d.jsxs(B.main,{variants:we,initial:"initial",animate:"animate",exit:"exit",transition:{duration:.3},className:"flex-1 flex flex-col items-center justify-center","aria-labelledby":"splash-title",onKeyDown:i,children:[d.jsx(B.div,{className:"text-center mb-10",initial:{opacity:0,scale:.9},animate:{opacity:1,scale:1},transition:{duration:.6,ease:"easeOut"},children:d.jsx("div",{className:"flex justify-center",children:d.jsx("img",{src:t==="dark"?H0:K0,alt:"",width:280,className:"object-contain",style:{filter:"drop-shadow(0 0 60px rgba(239, 68, 68, 0.4))"},"aria-hidden":"true"})})}),d.jsxs(B.div,{className:"text-center px-8 max-w-lg",initial:{opacity:0,y:20},animate:{opacity:1,y:0},transition:{duration:.5,delay:.2},children:[d.jsxs("div",{className:"flex items-center justify-center gap-2 mb-3",children:[d.jsx("h1",{ref:n,id:"splash-title",className:"text-2xl font-semibold text-gray-900 dark:text-white tracking-tight focus:outline-none",tabIndex:-1,children:"Welcome to Wails"}),d.jsx("span",{className:"px-2 py-0.5 text-[10px] font-medium uppercase tracking-wide rounded-full bg-amber-500/20 text-amber-600 dark:text-amber-400 border border-amber-500/30",role:"status","aria-label":"This setup wizard is experimental",children:"Experimental"})]}),d.jsx("p",{className:"text-base text-gray-600 dark:text-gray-300 leading-relaxed mb-8",children:"Build beautiful cross-platform apps using Go and web technologies"})]}),d.jsx(B.button,{ref:r,onClick:e,className:"px-6 py-2.5 rounded-lg border border-red-500 text-red-600 dark:text-red-400 text-sm font-medium hover:bg-red-500/10 transition-colors focus:outline-none focus:ring-2 focus:ring-red-500 focus:ring-offset-2 dark:focus:ring-offset-gray-900",initial:{opacity:0},animate:{opacity:1},transition:{duration:.5,delay:.4},children:"Let's Start"})]})}function C3(){const e=S.useRef(null);return S.useEffect(()=>{var t;(t=e.current)==null||t.focus()},[]),d.jsxs(B.main,{variants:we,initial:"initial",animate:"animate",exit:"exit",transition:{duration:.3},className:"flex-1 flex flex-col items-center justify-start pt-[15%]","aria-labelledby":"checking-title","aria-busy":"true",children:[d.jsx(B.div,{className:"w-12 h-12 border-3 border-gray-300 dark:border-gray-600 border-t-red-500 rounded-full mb-6",animate:{rotate:360},transition:{duration:1,repeat:1/0,ease:"linear"},role:"status","aria-label":"Loading"}),d.jsx("h2",{ref:e,id:"checking-title",className:"text-xl font-semibold text-gray-900 dark:text-white mb-2 focus:outline-none",tabIndex:-1,children:"Checking your system..."}),d.jsx("p",{className:"text-gray-500 dark:text-gray-400","aria-live":"polite",children:"This will only take a moment"})]})}function T3({onNext:e,onBack:t,canGoBack:n}){const r=S.useRef(null);return S.useEffect(()=>{var i;(i=r.current)==null||i.focus()},[]),d.jsxs(B.main,{variants:we,initial:"initial",animate:"animate",exit:"exit",transition:{duration:.3},className:"flex-1 flex flex-col items-center justify-center","aria-labelledby":"deps-ready-title",children:[d.jsx(B.div,{initial:{scale:0},animate:{scale:1},transition:{type:"spring",stiffness:200,damping:15},className:"w-20 h-20 rounded-full bg-green-500/20 flex items-center justify-center mb-6","aria-hidden":"true",children:d.jsx("svg",{className:"w-10 h-10 text-green-500",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",children:d.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2.5,d:"M5 13l4 4L19 7"})})}),d.jsx("h2",{ref:r,id:"deps-ready-title",className:"text-2xl font-semibold text-gray-900 dark:text-white mb-2 focus:outline-none",tabIndex:-1,children:"All dependencies installed"}),d.jsx("p",{className:"text-gray-500 dark:text-gray-400 mb-8 text-center max-w-sm",children:"Your system has everything needed to build Wails apps"}),d.jsxs("div",{className:"flex items-center gap-3",role:"group","aria-label":"Navigation",children:[n&&t&&d.jsx("button",{onClick:t,className:"px-4 py-2 rounded-lg text-sm font-medium transition-colors border border-gray-300 dark:border-gray-600 text-gray-600 dark:text-gray-400 hover:bg-gray-100 dark:hover:bg-gray-800 focus:outline-none focus:ring-2 focus:ring-gray-500 focus:ring-offset-2 dark:focus:ring-offset-gray-900",children:"Back"}),d.jsx("button",{onClick:e,className:"px-5 py-2 rounded-lg border border-red-500 text-red-600 dark:text-red-400 text-sm font-medium hover:bg-red-500/10 transition-colors focus:outline-none focus:ring-2 focus:ring-red-500 focus:ring-offset-2 dark:focus:ring-offset-gray-900",children:"Continue"})]})]})}function N3({dependencies:e,onRetry:t,onContinue:n,onBack:r,canGoBack:i}){const[s,o]=S.useState(!1),a=e.filter(c=>!c.installed&&c.required),l=(()=>{const c=a.filter(x=>{var y;return(y=x.installCommand)==null?void 0:y.startsWith("sudo ")}).map(x=>x.installCommand);if(c.length===0)return null;const h=[],f=[],v=[];for(const x of c)if(x.includes("pacman -S")){const y=x.match(/pacman -S\s+(.+)/);y&&h.push(...y[1].split(/\s+/))}else if(x.includes("apt install")){const y=x.match(/apt install\s+(.+)/);y&&f.push(...y[1].split(/\s+/))}else if(x.includes("dnf install")){const y=x.match(/dnf install\s+(.+)/);y&&v.push(...y[1].split(/\s+/))}return h.length>0?`sudo pacman -S ${h.join(" ")}`:f.length>0?`sudo apt install ${f.join(" ")}`:v.length>0?`sudo dnf install ${v.join(" ")}`:null})(),u=()=>{l&&(navigator.clipboard.writeText(l),o(!0),setTimeout(()=>o(!1),2e3))};return d.jsxs(Tu,{title:"Almost there!",subtitle:"A few things need to be installed first",primaryAction:t,primaryLabel:"Check Again",secondaryAction:n,secondaryLabel:"Continue anyway",onBack:r,canGoBack:i,children:[d.jsx("div",{className:"bg-gray-100 dark:bg-gray-900/50 rounded-lg p-4 mb-4",children:a.map(c=>d.jsxs("div",{className:"flex items-start gap-3 py-2 border-b border-gray-200/50 dark:border-gray-800/50 last:border-0",children:[d.jsx("div",{className:"w-5 h-5 rounded-full bg-red-500/20 flex items-center justify-center flex-shrink-0 mt-0.5",children:d.jsx("svg",{className:"w-3 h-3 text-red-500",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",children:d.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:3,d:"M6 18L18 6M6 6l12 12"})})}),d.jsxs("div",{children:[d.jsx("div",{className:"text-sm font-medium text-gray-900 dark:text-white",children:c.name}),c.message&&d.jsx("p",{className:"text-xs text-gray-500 mt-0.5",children:c.message}),c.helpUrl&&d.jsxs("a",{href:c.helpUrl,target:"_blank",rel:"noopener noreferrer",className:"inline-flex items-center gap-1 text-xs text-blue-500 dark:text-blue-400 hover:text-blue-600 dark:hover:text-blue-300 mt-1",children:["Install instructions",d.jsx("svg",{className:"w-3 h-3",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",children:d.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M10 6H6a2 2 0 00-2 2v10a2 2 0 002 2h10a2 2 0 002-2v-4M14 4h6m0 0v6m0-6L10 14"})})]})]})]},c.name))}),l&&d.jsxs("div",{className:"bg-gray-100 dark:bg-gray-900/50 rounded-lg p-4",children:[d.jsx("p",{className:"text-sm text-gray-600 dark:text-gray-300 mb-2",children:"Run this command to install everything:"}),d.jsxs("div",{className:"flex items-center gap-2",children:[d.jsx("code",{className:"flex-1 text-xs bg-gray-200 dark:bg-gray-900 text-gray-700 dark:text-gray-300 px-3 py-2 rounded font-mono overflow-x-auto",children:l}),d.jsx("button",{onClick:u,className:"text-gray-500 hover:text-gray-700 dark:hover:text-gray-300 transition-colors p-2",title:"Copy command",children:s?d.jsx("svg",{className:"w-5 h-5 text-green-500",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",children:d.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M5 13l4 4L19 7"})}):d.jsx("svg",{className:"w-5 h-5",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",children:d.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M8 16H6a2 2 0 01-2-2V6a2 2 0 012-2h8a2 2 0 012 2v2m-6 12h8a2 2 0 002-2v-8a2 2 0 00-2-2h-8a2 2 0 00-2 2v8a2 2 0 002 2z"})})})]})]})]})}function P3({dockerDep:e,onYes:t,onSkip:n,onBack:r,canGoBack:i}){const s=(e==null?void 0:e.installed)&&(e==null?void 0:e.imageBuilt)===!0;return d.jsx(B.div,{variants:we,initial:"initial",animate:"animate",exit:"exit",transition:{duration:.3},className:"flex-1 flex flex-col items-center justify-center",children:s?d.jsxs(d.Fragment,{children:[d.jsx(B.div,{initial:{scale:0},animate:{scale:1},transition:{type:"spring",stiffness:200,damping:15},className:"w-20 h-20 rounded-full bg-green-500/20 flex items-center justify-center mb-6",children:d.jsx("svg",{className:"w-10 h-10 text-green-500",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",children:d.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2.5,d:"M5 13l4 4L19 7"})})}),d.jsxs("div",{className:"flex items-center gap-4 mb-4",children:[d.jsx("svg",{className:"w-8 h-8 text-gray-600 dark:text-gray-400",viewBox:"0 0 24 24",fill:"currentColor",children:d.jsx("path",{d:"M0 3.449L9.75 2.1v9.451H0m10.949-9.602L24 0v11.4H10.949M0 12.6h9.75v9.451L0 20.699M10.949 12.6H24V24l-12.9-1.801"})}),d.jsx("svg",{className:"w-8 h-8 text-gray-600 dark:text-gray-400",viewBox:"0 0 24 24",fill:"currentColor",children:d.jsx("path",{d:"M18.71 19.5c-.83 1.24-1.71 2.45-3.05 2.47-1.34.03-1.77-.79-3.29-.79-1.53 0-2 .77-3.27.82-1.31.05-2.3-1.32-3.14-2.53C4.25 17 2.94 12.45 4.7 9.39c.87-1.52 2.43-2.48 4.12-2.51 1.28-.02 2.5.87 3.29.87.78 0 2.26-1.07 3.81-.91.65.03 2.47.26 3.64 1.98-.09.06-2.17 1.28-2.15 3.81.03 3.02 2.65 4.03 2.68 4.04-.03.07-.42 1.44-1.38 2.83M13 3.5c.73-.83 1.94-1.46 2.94-1.5.13 1.17-.34 2.35-1.04 3.19-.69.85-1.83 1.51-2.95 1.42-.15-1.15.41-2.35 1.05-3.11z"})}),d.jsx("svg",{className:"w-8 h-8 text-gray-600 dark:text-gray-400",viewBox:"0 0 24 24",fill:"currentColor",children:d.jsx("path",{d:"M12.504 0c-.155 0-.315.008-.48.021-4.226.333-3.105 4.807-3.17 6.298-.076 1.092-.3 1.953-1.05 3.02-.885 1.051-2.127 2.75-2.716 4.521-.278.832-.41 1.684-.287 2.489a.424.424 0 00-.11.135c-.26.268-.45.6-.663.839-.199.199-.485.267-.797.4-.313.136-.658.269-.864.68-.09.189-.136.394-.132.602 0 .199.027.4.055.536.058.399.116.728.04.97-.249.68-.28 1.145-.106 1.484.174.334.535.47.94.601.81.2 1.91.135 2.774.6.926.466 1.866.67 2.616.47.526-.116.97-.464 1.208-.946.587-.003 1.23-.269 2.26-.334.699-.058 1.574.267 2.577.2.025.134.063.198.114.333l.003.003c.391.778 1.113 1.132 1.884 1.071.771-.06 1.592-.536 2.257-1.306.631-.765 1.683-1.084 2.378-1.503.348-.199.629-.469.649-.853.023-.4-.2-.811-.714-1.376v-.097l-.003-.003c-.17-.2-.25-.535-.338-.926-.085-.401-.182-.786-.492-1.046h-.003c-.059-.054-.123-.067-.188-.135a.357.357 0 00-.19-.064c.431-1.278.264-2.55-.173-3.694-.533-1.41-1.465-2.638-2.175-3.483-.796-1.005-1.576-1.957-1.56-3.368.026-2.152.236-6.133-3.544-6.139zm.529 3.405h.013c.213 0 .396.062.584.198.19.135.33.332.438.533.105.259.158.459.166.724 0-.02.006-.04.006-.06v.105a.086.086 0 01-.004-.021l-.004-.024a1.807 1.807 0 01-.15.706.953.953 0 01-.213.335.71.71 0 00-.088-.042c-.104-.045-.198-.064-.284-.133a1.312 1.312 0 00-.22-.066c.05-.06.146-.133.183-.198.053-.128.082-.264.088-.402v-.02a1.21 1.21 0 00-.061-.4c-.045-.134-.101-.2-.183-.333-.084-.066-.167-.132-.267-.132h-.016c-.093 0-.176.03-.262.132a.8.8 0 00-.205.334 1.18 1.18 0 00-.09.4v.019c.002.089.008.179.02.267-.193-.067-.438-.135-.607-.202a1.635 1.635 0 01-.018-.2v-.02a1.772 1.772 0 01.15-.768c.082-.22.232-.406.43-.533a.985.985 0 01.594-.2zm-2.962.059h.036c.142 0 .27.048.399.135.146.129.264.288.344.465.09.199.14.4.153.667v.004c.007.134.006.2-.002.266v.08c-.03.007-.056.018-.083.024-.152.055-.274.135-.393.2.012-.09.013-.18.003-.267v-.015c-.012-.133-.04-.2-.082-.333a.613.613 0 00-.166-.267.248.248 0 00-.183-.064h-.021c-.071.006-.13.04-.186.132a.552.552 0 00-.12.27.944.944 0 00-.023.33v.015c.012.135.037.2.08.334.046.134.098.2.166.268.01.009.02.018.034.024-.07.057-.117.07-.176.136a.304.304 0 01-.131.068 2.62 2.62 0 01-.275-.402 1.772 1.772 0 01-.155-.667 1.759 1.759 0 01.08-.668 1.43 1.43 0 01.283-.535c.128-.133.26-.2.418-.2zm1.37 1.706c.332 0 .733.065 1.216.399.293.2.523.269 1.052.468h.003c.255.136.405.266.478.399v-.131a.571.571 0 01.016.47c-.123.31-.516.643-1.063.842v.002c-.268.135-.501.333-.775.465-.276.135-.588.292-1.012.267a1.139 1.139 0 01-.448-.067 3.566 3.566 0 01-.322-.198c-.195-.135-.363-.332-.612-.465v-.005h-.005c-.4-.246-.616-.512-.686-.71-.07-.268-.005-.47.193-.6.224-.135.38-.271.483-.336.104-.074.143-.102.176-.131h.002v-.003c.169-.202.436-.47.839-.601.139-.036.294-.065.466-.065zm2.8 2.142c.358 1.417 1.196 3.475 1.735 4.473.286.534.855 1.659 1.102 3.024.156-.005.33.018.513.064.646-1.671-.546-3.467-1.089-3.966-.22-.2-.232-.335-.123-.335.59.534 1.365 1.572 1.646 2.757.13.535.16 1.104.021 1.67.067.028.135.06.205.067 1.032.534 1.413.938 1.23 1.537v-.002c-.06-.135-.12-.2-.09-.267.046-.134.078-.333-.201-.465-.57-.267-.96-.4-1.18-.535a.98.98 0 01-.36-.4c-.298.533-.648.868-.94 1.002-.04-.2-.021-.4.09-.6a.71.71 0 01.381-.267c.376-.202.559-.47.646-.869.067-.399.024-.733-.135-1.135-.15-.4-.396-.665-.794-.933a2.01 2.01 0 00-.92-.267c-.435-.064-.747.048-.988.135-.075.022-.155.04-.239.054a2.56 2.56 0 01.106-.858c.09-.335.2-.6.323-.868a.262.262 0 01-.09-.134c-.067-.267-.2-.2-.33-.002a1.763 1.763 0 00-.172.535 2.114 2.114 0 00-.038.467c-.065.065-.132.135-.198.199-.257.193-.52.398-.737.601a2.71 2.71 0 01-.18-.202c-.27-.332-.393-.667-.354-1.067a.89.89 0 01.11-.334c.031-.053.067-.067.1-.135a.065.065 0 01.016-.023.09.09 0 01.015-.023v-.003a5.59 5.59 0 01.166-.267c.126-.2.27-.4.461-.602.14-.134.274-.267.41-.4.069-.066.14-.135.21-.2.07-.066.136-.135.203-.2.069-.134.202-.2.37-.266a.33.33 0 00.14-.067c-.12-.067-.137-.2-.061-.336.134-.332.453-.668.785-.933.332-.265.66-.4.875-.4.232.003.325.068.227.403z"})})]}),d.jsx("h2",{className:"text-2xl font-semibold text-gray-900 dark:text-white mb-2 text-center",children:"Cross-platform builds ready!"}),d.jsx("p",{className:"text-gray-500 dark:text-gray-400 mb-8 text-center max-w-md",children:"You can build for Windows, macOS, and Linux from this machine"}),d.jsxs("div",{className:"flex items-center gap-3",children:[i&&r&&d.jsx("button",{onClick:r,className:"px-4 py-2 rounded-lg text-sm font-medium transition-colors border border-gray-300 dark:border-gray-600 text-gray-600 dark:text-gray-400 hover:bg-gray-100 dark:hover:bg-gray-800",children:"Back"}),d.jsx("button",{onClick:n,className:"px-5 py-2 rounded-lg border border-red-500 text-red-600 dark:text-red-400 text-sm font-medium hover:bg-red-500/10 transition-colors",children:"Continue"})]})]}):d.jsxs(d.Fragment,{children:[d.jsxs("div",{className:"flex items-center gap-6 mb-8",children:[d.jsx("svg",{className:"w-12 h-12 text-gray-600 dark:text-gray-400",viewBox:"0 0 24 24",fill:"currentColor",children:d.jsx("path",{d:"M0 3.449L9.75 2.1v9.451H0m10.949-9.602L24 0v11.4H10.949M0 12.6h9.75v9.451L0 20.699M10.949 12.6H24V24l-12.9-1.801"})}),d.jsx("svg",{className:"w-12 h-12 text-gray-600 dark:text-gray-400",viewBox:"0 0 24 24",fill:"currentColor",children:d.jsx("path",{d:"M18.71 19.5c-.83 1.24-1.71 2.45-3.05 2.47-1.34.03-1.77-.79-3.29-.79-1.53 0-2 .77-3.27.82-1.31.05-2.3-1.32-3.14-2.53C4.25 17 2.94 12.45 4.7 9.39c.87-1.52 2.43-2.48 4.12-2.51 1.28-.02 2.5.87 3.29.87.78 0 2.26-1.07 3.81-.91.65.03 2.47.26 3.64 1.98-.09.06-2.17 1.28-2.15 3.81.03 3.02 2.65 4.03 2.68 4.04-.03.07-.42 1.44-1.38 2.83M13 3.5c.73-.83 1.94-1.46 2.94-1.5.13 1.17-.34 2.35-1.04 3.19-.69.85-1.83 1.51-2.95 1.42-.15-1.15.41-2.35 1.05-3.11z"})}),d.jsx("svg",{className:"w-12 h-12 text-gray-600 dark:text-gray-400",viewBox:"0 0 24 24",fill:"currentColor",children:d.jsx("path",{d:"M12.504 0c-.155 0-.315.008-.48.021-4.226.333-3.105 4.807-3.17 6.298-.076 1.092-.3 1.953-1.05 3.02-.885 1.051-2.127 2.75-2.716 4.521-.278.832-.41 1.684-.287 2.489a.424.424 0 00-.11.135c-.26.268-.45.6-.663.839-.199.199-.485.267-.797.4-.313.136-.658.269-.864.68-.09.189-.136.394-.132.602 0 .199.027.4.055.536.058.399.116.728.04.97-.249.68-.28 1.145-.106 1.484.174.334.535.47.94.601.81.2 1.91.135 2.774.6.926.466 1.866.67 2.616.47.526-.116.97-.464 1.208-.946.587-.003 1.23-.269 2.26-.334.699-.058 1.574.267 2.577.2.025.134.063.198.114.333l.003.003c.391.778 1.113 1.132 1.884 1.071.771-.06 1.592-.536 2.257-1.306.631-.765 1.683-1.084 2.378-1.503.348-.199.629-.469.649-.853.023-.4-.2-.811-.714-1.376v-.097l-.003-.003c-.17-.2-.25-.535-.338-.926-.085-.401-.182-.786-.492-1.046h-.003c-.059-.054-.123-.067-.188-.135a.357.357 0 00-.19-.064c.431-1.278.264-2.55-.173-3.694-.533-1.41-1.465-2.638-2.175-3.483-.796-1.005-1.576-1.957-1.56-3.368.026-2.152.236-6.133-3.544-6.139zm.529 3.405h.013c.213 0 .396.062.584.198.19.135.33.332.438.533.105.259.158.459.166.724 0-.02.006-.04.006-.06v.105a.086.086 0 01-.004-.021l-.004-.024a1.807 1.807 0 01-.15.706.953.953 0 01-.213.335.71.71 0 00-.088-.042c-.104-.045-.198-.064-.284-.133a1.312 1.312 0 00-.22-.066c.05-.06.146-.133.183-.198.053-.128.082-.264.088-.402v-.02a1.21 1.21 0 00-.061-.4c-.045-.134-.101-.2-.183-.333-.084-.066-.167-.132-.267-.132h-.016c-.093 0-.176.03-.262.132a.8.8 0 00-.205.334 1.18 1.18 0 00-.09.4v.019c.002.089.008.179.02.267-.193-.067-.438-.135-.607-.202a1.635 1.635 0 01-.018-.2v-.02a1.772 1.772 0 01.15-.768c.082-.22.232-.406.43-.533a.985.985 0 01.594-.2zm-2.962.059h.036c.142 0 .27.048.399.135.146.129.264.288.344.465.09.199.14.4.153.667v.004c.007.134.006.2-.002.266v.08c-.03.007-.056.018-.083.024-.152.055-.274.135-.393.2.012-.09.013-.18.003-.267v-.015c-.012-.133-.04-.2-.082-.333a.613.613 0 00-.166-.267.248.248 0 00-.183-.064h-.021c-.071.006-.13.04-.186.132a.552.552 0 00-.12.27.944.944 0 00-.023.33v.015c.012.135.037.2.08.334.046.134.098.2.166.268.01.009.02.018.034.024-.07.057-.117.07-.176.136a.304.304 0 01-.131.068 2.62 2.62 0 01-.275-.402 1.772 1.772 0 01-.155-.667 1.759 1.759 0 01.08-.668 1.43 1.43 0 01.283-.535c.128-.133.26-.2.418-.2zm1.37 1.706c.332 0 .733.065 1.216.399.293.2.523.269 1.052.468h.003c.255.136.405.266.478.399v-.131a.571.571 0 01.016.47c-.123.31-.516.643-1.063.842v.002c-.268.135-.501.333-.775.465-.276.135-.588.292-1.012.267a1.139 1.139 0 01-.448-.067 3.566 3.566 0 01-.322-.198c-.195-.135-.363-.332-.612-.465v-.005h-.005c-.4-.246-.616-.512-.686-.71-.07-.268-.005-.47.193-.6.224-.135.38-.271.483-.336.104-.074.143-.102.176-.131h.002v-.003c.169-.202.436-.47.839-.601.139-.036.294-.065.466-.065zm2.8 2.142c.358 1.417 1.196 3.475 1.735 4.473.286.534.855 1.659 1.102 3.024.156-.005.33.018.513.064.646-1.671-.546-3.467-1.089-3.966-.22-.2-.232-.335-.123-.335.59.534 1.365 1.572 1.646 2.757.13.535.16 1.104.021 1.67.067.028.135.06.205.067 1.032.534 1.413.938 1.23 1.537v-.002c-.06-.135-.12-.2-.09-.267.046-.134.078-.333-.201-.465-.57-.267-.96-.4-1.18-.535a.98.98 0 01-.36-.4c-.298.533-.648.868-.94 1.002-.04-.2-.021-.4.09-.6a.71.71 0 01.381-.267c.376-.202.559-.47.646-.869.067-.399.024-.733-.135-1.135-.15-.4-.396-.665-.794-.933a2.01 2.01 0 00-.92-.267c-.435-.064-.747.048-.988.135-.075.022-.155.04-.239.054a2.56 2.56 0 01.106-.858c.09-.335.2-.6.323-.868a.262.262 0 01-.09-.134c-.067-.267-.2-.2-.33-.002a1.763 1.763 0 00-.172.535 2.114 2.114 0 00-.038.467c-.065.065-.132.135-.198.199-.257.193-.52.398-.737.601a2.71 2.71 0 01-.18-.202c-.27-.332-.393-.667-.354-1.067a.89.89 0 01.11-.334c.031-.053.067-.067.1-.135a.065.065 0 01.016-.023.09.09 0 01.015-.023v-.003a5.59 5.59 0 01.166-.267c.126-.2.27-.4.461-.602.14-.134.274-.267.41-.4.069-.066.14-.135.21-.2.07-.066.136-.135.203-.2.069-.134.202-.2.37-.266a.33.33 0 00.14-.067c-.12-.067-.137-.2-.061-.336.134-.332.453-.668.785-.933.332-.265.66-.4.875-.4.232.003.325.068.227.403z"})})]}),d.jsx("h2",{className:"text-2xl font-semibold text-gray-900 dark:text-white mb-2 text-center",children:"Build for multiple platforms?"}),d.jsx("p",{className:"text-gray-500 dark:text-gray-400 mb-2 text-center max-w-md",children:"Wails can compile your app for Windows, macOS, and Linux from a single machine"}),d.jsx("p",{className:"text-xs text-gray-400 dark:text-gray-500 mb-8 text-center",children:"Requires Docker for cross-compilation"}),d.jsxs("div",{className:"flex flex-col items-center gap-2",children:[d.jsxs("div",{className:"flex items-center gap-3",children:[i&&r&&d.jsx("button",{onClick:r,className:"px-4 py-2 rounded-lg text-sm font-medium transition-colors border border-gray-300 dark:border-gray-600 text-gray-600 dark:text-gray-400 hover:bg-gray-100 dark:hover:bg-gray-800",children:"Back"}),d.jsx("button",{onClick:t,className:"px-5 py-2 rounded-lg border border-red-500 text-red-600 dark:text-red-400 text-sm font-medium hover:bg-red-500/10 transition-colors",children:"Yes, set this up"})]}),d.jsx("button",{onClick:n,className:"text-xs text-gray-500 dark:text-gray-400 hover:text-gray-700 dark:hover:text-gray-300 transition-colors",children:"Not right now"})]})]})})}function E3({onBuildImage:e,onUseLocalSDK:t,onSkip:n}){const[r,i]=S.useState(!1),[s,o]=S.useState(null),a=async()=>{if(!s){const u=await(await fetch("/api/docker/logs")).text();o(u)}i(!0)};return r?d.jsxs(B.div,{variants:we,initial:"initial",animate:"animate",exit:"exit",transition:{duration:.3},className:"flex-1 flex flex-col items-center justify-center max-w-4xl mx-auto w-full",children:[d.jsxs("div",{className:"w-full flex items-center justify-between mb-4",children:[d.jsx("h2",{className:"text-lg font-semibold text-gray-900 dark:text-white",children:"Build Logs"}),d.jsx("button",{onClick:()=>i(!1),className:"text-sm text-gray-500 hover:text-gray-700 dark:text-gray-400 dark:hover:text-gray-200",children:"Back"})]}),d.jsx("pre",{className:"w-full h-96 overflow-auto bg-gray-900 text-gray-100 p-4 rounded-lg text-xs font-mono whitespace-pre-wrap",children:s||"No logs available"})]}):d.jsxs(B.div,{variants:we,initial:"initial",animate:"animate",exit:"exit",transition:{duration:.3},className:"flex-1 flex flex-col items-center justify-center",children:[d.jsx("div",{className:"w-16 h-16 rounded-2xl bg-amber-500/20 flex items-center justify-center mb-6",children:d.jsx("svg",{className:"w-8 h-8 text-amber-500",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",children:d.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,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"})})}),d.jsx("h2",{className:"text-xl font-semibold text-gray-900 dark:text-white mb-2",children:"Build failed"}),d.jsx("p",{className:"text-sm text-gray-500 dark:text-gray-400 mb-2 text-center max-w-sm",children:"Check your internet connection and try again, or download the SDK manually."}),d.jsx("button",{onClick:a,className:"text-sm text-blue-500 hover:text-blue-600 mb-6",children:"View logs"}),d.jsxs("div",{className:"flex flex-col gap-3 items-center",children:[d.jsxs("div",{className:"flex gap-3",children:[d.jsx("button",{onClick:e,className:"px-5 py-2.5 rounded-lg bg-blue-500 text-white text-sm font-medium hover:bg-blue-600 transition-colors",children:"Try again"}),d.jsxs("label",{className:"px-5 py-2.5 rounded-lg border border-blue-500 text-blue-600 dark:text-blue-400 text-sm font-medium hover:bg-blue-500/10 transition-colors cursor-pointer",children:["Use local file",d.jsx("input",{type:"file",accept:".tar.xz",className:"hidden",onChange:l=>{var c;const u=(c=l.target.files)==null?void 0:c[0];u&&t(u)}})]})]}),d.jsx("a",{href:"https://github.com/wailsapp/macosx-sdks/releases/download/26.1/MacOSX26.1.sdk.tar.xz",download:!0,className:"text-xs text-gray-500 dark:text-gray-400 hover:text-gray-700 dark:hover:text-gray-300 transition-colors",children:"Download SDK manually"}),d.jsx("button",{onClick:n,className:"text-xs text-gray-500 dark:text-gray-400 hover:text-gray-700 dark:hover:text-gray-300 transition-colors",children:"Skip for now"})]})]})}function M3({onAgree:e,onDecline:t,onBack:n,canGoBack:r}){const[i,s]=S.useState(!1);return d.jsxs(B.div,{variants:we,initial:"initial",animate:"animate",exit:"exit",transition:{duration:.3},className:"flex-1 flex flex-col items-center justify-center",children:[r&&n&&d.jsx("button",{onClick:n,className:"absolute top-4 left-4 p-2 rounded-lg text-gray-500 hover:text-gray-700 dark:text-gray-400 dark:hover:text-gray-200 hover:bg-gray-100 dark:hover:bg-gray-800 transition-colors","aria-label":"Go back",children:d.jsx("svg",{className:"w-5 h-5",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",children:d.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M15 19l-7-7 7-7"})})}),d.jsx("div",{className:"w-12 h-12 rounded-xl bg-gray-100 dark:bg-gray-800 flex items-center justify-center mb-4",children:d.jsx("svg",{className:"w-6 h-6 text-gray-600 dark:text-gray-300",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",children:d.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M9 12h6m-6 4h6m2 5H7a2 2 0 01-2-2V5a2 2 0 012-2h5.586a1 1 0 01.707.293l5.414 5.414a1 1 0 01.293.707V19a2 2 0 01-2 2z"})})}),d.jsx("h2",{className:"text-lg font-semibold text-gray-900 dark:text-white mb-1",children:"Apple SDK License Agreement"}),d.jsx("p",{className:"text-sm text-gray-500 dark:text-gray-400 mb-4 text-center max-w-md",children:"Cross-platform builds for macOS require the Apple SDK. Please review and accept the license terms."}),d.jsx("div",{className:"w-full max-w-2xl h-72 mb-4 rounded-lg overflow-hidden border border-gray-200 dark:border-gray-700 bg-white",children:d.jsx("iframe",{src:"/assets/apple-sdk-license.pdf#view=FitH&navpanes=0&toolbar=0",className:"w-full h-full",title:"Apple Xcode and SDK License Agreement"})}),d.jsxs("label",{className:"flex items-center gap-2 mb-5 cursor-pointer",children:[d.jsx("input",{type:"checkbox",checked:i,onChange:o=>s(o.target.checked),className:"w-4 h-4 rounded border-gray-300 text-blue-500 focus:ring-blue-500"}),d.jsx("span",{className:"text-sm text-gray-600 dark:text-gray-300",children:"I agree to Apple's Xcode and SDK License Agreement"})]}),d.jsxs("div",{className:"flex gap-3",children:[d.jsx("button",{onClick:t,className:"px-5 py-2.5 rounded-lg border border-gray-300 dark:border-gray-600 text-gray-700 dark:text-gray-300 text-sm font-medium hover:bg-gray-50 dark:hover:bg-gray-800 transition-colors",children:"Skip cross-platform"}),d.jsx("button",{onClick:e,disabled:!i,className:`px-5 py-2.5 rounded-lg text-sm font-medium transition-colors ${i?"bg-blue-500 text-white hover:bg-blue-600":"bg-gray-200 text-gray-400 cursor-not-allowed"}`,children:"Continue"})]})]})}function L3({dockerStatus:e,buildingImage:t,onBuildImage:n,onCheckAgain:r,onContinueBackground:i,onUseLocalSDK:s,onSkip:o,onBack:a,canGoBack:l}){if(!e||!e.installed)return d.jsxs(B.div,{variants:we,initial:"initial",animate:"animate",exit:"exit",transition:{duration:.3},className:"flex-1 flex flex-col items-center justify-center",children:[d.jsx("div",{className:"w-16 h-16 rounded-2xl bg-blue-500/20 flex items-center justify-center mb-6",children:d.jsx("svg",{className:"w-10 h-10",viewBox:"0 0 756.26 596.9",children:d.jsx("path",{fill:"#1d63ed",d:"M743.96,245.25c-18.54-12.48-67.26-17.81-102.68-8.27-1.91-35.28-20.1-65.01-53.38-90.95l-12.32-8.27-8.21,12.4c-16.14,24.5-22.94,57.14-20.53,86.81,1.9,18.28,8.26,38.83,20.53,53.74-46.1,26.74-88.59,20.67-276.77,20.67H.06c-.85,42.49,5.98,124.23,57.96,190.77,5.74,7.35,12.04,14.46,18.87,21.31,42.26,42.32,106.11,73.35,201.59,73.44,145.66.13,270.46-78.6,346.37-268.97,24.98.41,90.92,4.48,123.19-57.88.79-1.05,8.21-16.54,8.21-16.54l-12.3-8.27ZM189.67,206.39h-81.7v81.7h81.7v-81.7ZM295.22,206.39h-81.7v81.7h81.7v-81.7ZM400.77,206.39h-81.7v81.7h81.7v-81.7ZM506.32,206.39h-81.7v81.7h81.7v-81.7ZM84.12,206.39H2.42v81.7h81.7v-81.7ZM189.67,103.2h-81.7v81.7h81.7v-81.7ZM295.22,103.2h-81.7v81.7h81.7v-81.7ZM400.77,103.2h-81.7v81.7h81.7v-81.7ZM400.77,0h-81.7v81.7h81.7V0Z"})})}),d.jsx("h2",{className:"text-xl font-semibold text-gray-900 dark:text-white mb-2",children:"Install Docker"}),d.jsx("p",{className:"text-gray-500 dark:text-gray-400 mb-6 text-center max-w-sm",children:"Cross-platform builds require Docker Desktop"}),d.jsxs("a",{href:"https://docs.docker.com/get-docker/",target:"_blank",rel:"noopener noreferrer",className:"px-5 py-2 rounded-lg bg-blue-600 text-white text-sm font-medium hover:bg-blue-500 transition-colors inline-flex items-center gap-2 mb-4",children:["Download Docker Desktop",d.jsx("svg",{className:"w-4 h-4",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",children:d.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M10 6H6a2 2 0 00-2 2v10a2 2 0 002 2h10a2 2 0 002-2v-4M14 4h6m0 0v6m0-6L10 14"})})]}),d.jsx("p",{className:"text-xs text-gray-400 dark:text-gray-500 mb-6 text-center max-w-xs",children:"After installing, come back and we'll continue setting up. Some platforms may require a reboot."}),d.jsxs("div",{className:"flex flex-col items-center gap-1.5",children:[d.jsxs("div",{className:"flex items-center gap-3",children:[l&&a&&d.jsx("button",{onClick:a,className:"px-4 py-2 rounded-lg text-sm font-medium transition-colors border border-gray-300 dark:border-gray-600 text-gray-600 dark:text-gray-400 hover:bg-gray-100 dark:hover:bg-gray-800",children:"Back"}),d.jsx("button",{onClick:r,className:"px-5 py-1.5 rounded-lg bg-gray-100 dark:bg-gray-800 text-gray-700 dark:text-gray-300 text-sm font-medium hover:bg-gray-200 dark:hover:bg-gray-700 transition-colors",children:"Check Again"})]}),d.jsx("button",{onClick:o,className:"text-xs text-gray-500 dark:text-gray-400 hover:text-gray-700 dark:hover:text-gray-300 transition-colors",children:"Skip for now"})]})]});if(!e.running)return d.jsxs(B.div,{variants:we,initial:"initial",animate:"animate",exit:"exit",transition:{duration:.3},className:"flex-1 flex flex-col items-center justify-center",children:[d.jsx("div",{className:"w-16 h-16 rounded-2xl bg-gray-200 dark:bg-gray-800 flex items-center justify-center mb-6 opacity-50",children:d.jsx("svg",{className:"w-10 h-10",viewBox:"0 0 756.26 596.9",children:d.jsx("path",{fill:"#6b7280",d:"M743.96,245.25c-18.54-12.48-67.26-17.81-102.68-8.27-1.91-35.28-20.1-65.01-53.38-90.95l-12.32-8.27-8.21,12.4c-16.14,24.5-22.94,57.14-20.53,86.81,1.9,18.28,8.26,38.83,20.53,53.74-46.1,26.74-88.59,20.67-276.77,20.67H.06c-.85,42.49,5.98,124.23,57.96,190.77,5.74,7.35,12.04,14.46,18.87,21.31,42.26,42.32,106.11,73.35,201.59,73.44,145.66.13,270.46-78.6,346.37-268.97,24.98.41,90.92,4.48,123.19-57.88.79-1.05,8.21-16.54,8.21-16.54l-12.3-8.27ZM189.67,206.39h-81.7v81.7h81.7v-81.7ZM295.22,206.39h-81.7v81.7h81.7v-81.7ZM400.77,206.39h-81.7v81.7h81.7v-81.7ZM506.32,206.39h-81.7v81.7h81.7v-81.7ZM84.12,206.39H2.42v81.7h81.7v-81.7ZM189.67,103.2h-81.7v81.7h81.7v-81.7ZM295.22,103.2h-81.7v81.7h81.7v-81.7ZM400.77,103.2h-81.7v81.7h81.7v-81.7ZM400.77,0h-81.7v81.7h81.7V0Z"})})}),d.jsx("h2",{className:"text-xl font-semibold text-gray-900 dark:text-white mb-2",children:"Start Docker"}),d.jsx("p",{className:"text-gray-500 dark:text-gray-400 mb-8 text-center max-w-sm",children:"Please start Docker Desktop to continue"}),d.jsxs("div",{className:"flex flex-col items-center gap-1.5",children:[d.jsxs("div",{className:"flex items-center gap-3",children:[l&&a&&d.jsx("button",{onClick:a,className:"px-4 py-2 rounded-lg text-sm font-medium transition-colors border border-gray-300 dark:border-gray-600 text-gray-600 dark:text-gray-400 hover:bg-gray-100 dark:hover:bg-gray-800",children:"Back"}),d.jsx("button",{onClick:r,className:"px-5 py-2 rounded-lg border border-red-500 text-red-600 dark:text-red-400 text-sm font-medium hover:bg-red-500/10 transition-colors",children:"Check Again"})]}),d.jsx("button",{onClick:o,className:"text-xs text-gray-500 dark:text-gray-400 hover:text-gray-700 dark:hover:text-gray-300 transition-colors",children:"Skip for now"})]})]});if(t||e.pullStatus==="pulling"){const u=e.pullProgress||0,c=e.pullMessage||"Connecting";return d.jsxs(B.div,{variants:we,initial:"initial",animate:"animate",exit:"exit",transition:{duration:.3},className:"flex-1 flex flex-col items-center justify-center",children:[d.jsx("div",{className:"w-16 h-16 rounded-2xl bg-blue-500/20 flex items-center justify-center mb-6",children:d.jsx("svg",{className:"w-10 h-10",viewBox:"0 0 756.26 596.9",children:d.jsx("path",{fill:"#1d63ed",d:"M743.96,245.25c-18.54-12.48-67.26-17.81-102.68-8.27-1.91-35.28-20.1-65.01-53.38-90.95l-12.32-8.27-8.21,12.4c-16.14,24.5-22.94,57.14-20.53,86.81,1.9,18.28,8.26,38.83,20.53,53.74-46.1,26.74-88.59,20.67-276.77,20.67H.06c-.85,42.49,5.98,124.23,57.96,190.77,5.74,7.35,12.04,14.46,18.87,21.31,42.26,42.32,106.11,73.35,201.59,73.44,145.66.13,270.46-78.6,346.37-268.97,24.98.41,90.92,4.48,123.19-57.88.79-1.05,8.21-16.54,8.21-16.54l-12.3-8.27ZM189.67,206.39h-81.7v81.7h81.7v-81.7ZM295.22,206.39h-81.7v81.7h81.7v-81.7ZM400.77,206.39h-81.7v81.7h81.7v-81.7ZM506.32,206.39h-81.7v81.7h81.7v-81.7ZM84.12,206.39H2.42v81.7h81.7v-81.7ZM189.67,103.2h-81.7v81.7h81.7v-81.7ZM295.22,103.2h-81.7v81.7h81.7v-81.7ZM400.77,103.2h-81.7v81.7h81.7v-81.7ZM400.77,0h-81.7v81.7h81.7V0Z"})})}),d.jsx("h2",{className:"text-xl font-semibold text-gray-900 dark:text-white mb-2",children:"Downloading cross-compiler image"}),d.jsxs("div",{className:"w-64 mb-4",children:[d.jsxs("div",{className:"flex items-center justify-between text-sm text-gray-500 mb-1",children:[d.jsx("span",{children:c}),d.jsxs("span",{children:[u,"%"]})]}),d.jsx("div",{className:"h-2 bg-gray-200 dark:bg-gray-700 rounded-full overflow-hidden",children:d.jsx(B.div,{className:"h-full bg-blue-500",animate:{width:`${u}%`}})})]}),d.jsx("p",{className:"text-xs text-gray-400 dark:text-gray-500 mb-8 text-center",children:"This may take several minutes"}),d.jsx("button",{onClick:i,className:"px-5 py-2 rounded-lg border border-red-500 text-red-600 dark:text-red-400 text-sm font-medium hover:bg-red-500/10 transition-colors",children:"Continue in background"})]})}return e.pullStatus==="error"?d.jsx(E3,{onBuildImage:n,onUseLocalSDK:s,onSkip:o}):e.imageBuilt?d.jsxs(B.div,{variants:we,initial:"initial",animate:"animate",exit:"exit",transition:{duration:.3},className:"flex-1 flex flex-col items-center justify-center",children:[d.jsx(B.div,{initial:{scale:0},animate:{scale:1},transition:{type:"spring",stiffness:200,damping:15},className:"w-16 h-16 rounded-2xl bg-green-500/20 flex items-center justify-center mb-6",children:d.jsx("svg",{className:"w-8 h-8 text-green-500",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",children:d.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2.5,d:"M5 13l4 4L19 7"})})}),d.jsx("h2",{className:"text-xl font-semibold text-gray-900 dark:text-white mb-2",children:"Cross-platform builds ready!"}),d.jsx("p",{className:"text-gray-500 dark:text-gray-400 mb-8 text-center max-w-sm",children:"You can now build for Windows, macOS, and Linux"}),d.jsxs("div",{className:"flex items-center gap-3",children:[l&&a&&d.jsx("button",{onClick:a,className:"px-4 py-2 rounded-lg text-sm font-medium transition-colors border border-gray-300 dark:border-gray-600 text-gray-600 dark:text-gray-400 hover:bg-gray-100 dark:hover:bg-gray-800",children:"Back"}),d.jsx("button",{onClick:i,className:"px-5 py-2 rounded-lg border border-red-500 text-red-600 dark:text-red-400 text-sm font-medium hover:bg-red-500/10 transition-colors",children:"Continue"})]})]}):d.jsxs(B.div,{variants:we,initial:"initial",animate:"animate",exit:"exit",transition:{duration:.3},className:"flex-1 flex flex-col items-center justify-center",children:[d.jsx("div",{className:"w-16 h-16 rounded-2xl bg-blue-500/20 flex items-center justify-center mb-6",children:d.jsx("svg",{className:"w-10 h-10",viewBox:"0 0 756.26 596.9",children:d.jsx("path",{fill:"#1d63ed",d:"M743.96,245.25c-18.54-12.48-67.26-17.81-102.68-8.27-1.91-35.28-20.1-65.01-53.38-90.95l-12.32-8.27-8.21,12.4c-16.14,24.5-22.94,57.14-20.53,86.81,1.9,18.28,8.26,38.83,20.53,53.74-46.1,26.74-88.59,20.67-276.77,20.67H.06c-.85,42.49,5.98,124.23,57.96,190.77,5.74,7.35,12.04,14.46,18.87,21.31,42.26,42.32,106.11,73.35,201.59,73.44,145.66.13,270.46-78.6,346.37-268.97,24.98.41,90.92,4.48,123.19-57.88.79-1.05,8.21-16.54,8.21-16.54l-12.3-8.27ZM189.67,206.39h-81.7v81.7h81.7v-81.7ZM295.22,206.39h-81.7v81.7h81.7v-81.7ZM400.77,206.39h-81.7v81.7h81.7v-81.7ZM506.32,206.39h-81.7v81.7h81.7v-81.7ZM84.12,206.39H2.42v81.7h81.7v-81.7ZM189.67,103.2h-81.7v81.7h81.7v-81.7ZM295.22,103.2h-81.7v81.7h81.7v-81.7ZM400.77,103.2h-81.7v81.7h81.7v-81.7ZM400.77,0h-81.7v81.7h81.7V0Z"})})}),d.jsx("h2",{className:"text-xl font-semibold text-gray-900 dark:text-white mb-2",children:"Docker is ready!"}),d.jsx("p",{className:"text-gray-500 dark:text-gray-400 mb-2 text-center max-w-sm",children:"Download the cross-compilation image to enable building for all platforms"}),d.jsx("p",{className:"text-xs text-gray-400 dark:text-gray-500 mb-8 text-center",children:"This will download ~800MB and may take several minutes"}),d.jsxs("div",{className:"flex flex-col items-center gap-2",children:[d.jsxs("div",{className:"flex items-center gap-3",children:[l&&a&&d.jsx("button",{onClick:a,className:"px-4 py-2 rounded-lg text-sm font-medium transition-colors border border-gray-300 dark:border-gray-600 text-gray-600 dark:text-gray-400 hover:bg-gray-100 dark:hover:bg-gray-800",children:"Back"}),d.jsx("button",{onClick:n,className:"px-5 py-2 rounded-lg bg-blue-600 text-white text-sm font-medium hover:bg-blue-500 transition-colors",children:"Download Image"})]}),d.jsx("button",{onClick:o,className:"text-xs text-gray-500 dark:text-gray-400 hover:text-gray-700 dark:hover:text-gray-300 transition-colors",children:"Skip, I'll do it later"})]})]})}const D3=[{id:"vanilla",name:"Vanilla",description:"Plain JavaScript/TypeScript",color:"#f7df1e",icon:"javascript"},{id:"react",name:"React",description:"React with Vite",color:"#61dafb",icon:"react"},{id:"vue",name:"Vue",description:"Vue 3 with Vite",color:"#42b883",icon:"vue"},{id:"svelte",name:"Svelte",description:"Svelte with Vite",color:"#ff3e00",icon:"svelte"},{id:"preact",name:"Preact",description:"Lightweight React alternative",color:"#673ab8",icon:"preact"},{id:"lit",name:"Lit",description:"Web Components with Lit",color:"#324fff",icon:"lit"},{id:"solid",name:"Solid",description:"Solid.js with Vite",color:"#2c4f7c",icon:"solid"},{id:"qwik",name:"Qwik",description:"Qwik with Vite",color:"#18b6f6",icon:"qwik"}];function A3({preferTypeScript:e,onSelect:t,onNext:n,onBack:r,canGoBack:i}){const s=S.useRef(null);return S.useEffect(()=>{var o;(o=s.current)==null||o.focus()},[]),d.jsxs(B.main,{variants:we,initial:"initial",animate:"animate",exit:"exit",transition:{duration:.3},className:"flex-1 flex flex-col items-center justify-center","aria-labelledby":"language-title",children:[d.jsx("h2",{ref:s,id:"language-title",className:"text-2xl font-semibold text-gray-900 dark:text-white mb-2 text-center focus:outline-none",tabIndex:-1,children:"Language Preference"}),d.jsx("p",{className:"text-gray-500 dark:text-gray-400 mb-8 text-center max-w-md",children:"Choose your preferred language for new projects"}),d.jsxs("div",{className:"flex gap-4 mb-8",role:"radiogroup","aria-label":"Programming language",children:[d.jsxs("button",{onClick:()=>t(!1),role:"radio","aria-checked":!e,className:`w-40 h-48 rounded-xl p-5 flex flex-col items-center justify-center gap-3 transition-all border-2 focus:outline-none focus:ring-2 focus:ring-yellow-400 focus:ring-offset-2 dark:focus:ring-offset-gray-900 ${e?"border-gray-200 dark:border-white/10 bg-gray-100 dark:bg-white/5 hover:bg-gray-200 dark:hover:bg-white/10":"border-yellow-400 bg-yellow-400/10 shadow-lg shadow-yellow-400/20"}`,children:[d.jsx("div",{className:"w-16 h-16 flex items-center justify-center","aria-hidden":"true",children:d.jsx("img",{src:"/logos/javascript.svg",alt:"",className:"w-14 h-14"})}),d.jsx("span",{className:"text-lg font-semibold text-gray-900 dark:text-white",children:"JavaScript"}),d.jsx("span",{className:"text-xs text-gray-500 dark:text-white/50",children:"Dynamic typing"})]}),d.jsxs("button",{onClick:()=>t(!0),role:"radio","aria-checked":e,className:`w-40 h-48 rounded-xl p-5 flex flex-col items-center justify-center gap-3 transition-all border-2 focus:outline-none focus:ring-2 focus:ring-blue-400 focus:ring-offset-2 dark:focus:ring-offset-gray-900 ${e?"border-blue-400 bg-blue-400/10 shadow-lg shadow-blue-400/20":"border-gray-200 dark:border-white/10 bg-gray-100 dark:bg-white/5 hover:bg-gray-200 dark:hover:bg-white/10"}`,children:[d.jsx("div",{className:"w-16 h-16 flex items-center justify-center","aria-hidden":"true",children:d.jsx("img",{src:"/logos/typescript.svg",alt:"",className:"w-14 h-14"})}),d.jsx("span",{className:"text-lg font-semibold text-gray-900 dark:text-white",children:"TypeScript"}),d.jsx("span",{className:"text-xs text-gray-500 dark:text-white/50",children:"Type safety"})]})]}),d.jsxs("div",{className:"flex items-center gap-3",role:"group","aria-label":"Navigation",children:[i&&r&&d.jsx("button",{onClick:r,className:"px-4 py-2 rounded-lg text-sm font-medium transition-colors border border-gray-300 dark:border-gray-600 text-gray-600 dark:text-gray-400 hover:bg-gray-100 dark:hover:bg-gray-800 focus:outline-none focus:ring-2 focus:ring-gray-500 focus:ring-offset-2 dark:focus:ring-offset-gray-900",children:"Back"}),d.jsx("button",{onClick:n,className:"px-6 py-2.5 rounded-lg border border-red-500 text-red-600 dark:text-red-400 text-sm font-medium hover:bg-red-500/10 transition-colors focus:outline-none focus:ring-2 focus:ring-red-500 focus:ring-offset-2 dark:focus:ring-offset-gray-900",children:"Continue"})]})]})}function R3({useInterfaces:e,onSelect:t,onNext:n,onBack:r,canGoBack:i}){const s=S.useRef(null);return S.useEffect(()=>{var o;(o=s.current)==null||o.focus()},[]),d.jsxs(B.main,{variants:we,initial:"initial",animate:"animate",exit:"exit",transition:{duration:.3},className:"flex-1 flex flex-col items-center justify-center px-4 overflow-hidden","aria-labelledby":"binding-title",children:[d.jsx("h2",{ref:s,id:"binding-title",className:"text-2xl font-semibold text-gray-900 dark:text-white mb-2 text-center focus:outline-none",tabIndex:-1,children:"TypeScript Binding Style"}),d.jsx("p",{className:"text-gray-500 dark:text-gray-400 mb-6 text-center max-w-lg",children:"Choose how Go structs are represented in TypeScript"}),d.jsxs("div",{className:"flex gap-4 mb-8 max-w-full overflow-x-auto p-1",role:"radiogroup","aria-label":"Binding style",children:[d.jsxs("button",{onClick:()=>t(!0),role:"radio","aria-checked":e,className:`w-56 shrink-0 rounded-xl p-4 flex flex-col items-start gap-2 transition-all border-2 text-left focus:outline-none focus:ring-2 focus:ring-blue-400 focus:ring-offset-2 dark:focus:ring-offset-gray-900 ${e?"border-blue-400 bg-blue-400/10 shadow-lg shadow-blue-400/20":"border-white/10 bg-white/5 hover:bg-white/10"}`,children:[d.jsx("span",{className:"text-base font-semibold text-gray-900 dark:text-white",children:"Interfaces"}),d.jsx("pre",{className:"text-[10px] leading-tight text-gray-700 dark:text-white/70 font-mono bg-gray-100 dark:bg-black/30 p-2 rounded-lg w-full overflow-x-auto","aria-hidden":"true",children:`interface Person { - name: string; - age: number; -}`}),d.jsxs("ul",{className:"text-[10px] text-gray-500 dark:text-white/50 space-y-0.5","aria-label":"Features",children:[d.jsx("li",{children:"Lightweight types"}),d.jsx("li",{children:"No runtime code"}),d.jsx("li",{children:"Simpler output"})]})]}),d.jsxs("button",{onClick:()=>t(!1),role:"radio","aria-checked":!e,className:`w-56 shrink-0 rounded-xl p-4 flex flex-col items-start gap-2 transition-all border-2 text-left focus:outline-none focus:ring-2 focus:ring-purple-400 focus:ring-offset-2 dark:focus:ring-offset-gray-900 ${e?"border-white/10 bg-white/5 hover:bg-white/10":"border-purple-400 bg-purple-400/10 shadow-lg shadow-purple-400/20"}`,children:[d.jsx("span",{className:"text-base font-semibold text-gray-900 dark:text-white",children:"Classes"}),d.jsx("pre",{className:"text-[10px] leading-tight text-gray-700 dark:text-white/70 font-mono bg-gray-100 dark:bg-black/30 p-2 rounded-lg w-full overflow-x-auto","aria-hidden":"true",children:`class Person { - name: string; - age: number; - constructor(src) { - Object.assign(this, src); - } - static createFrom(src) { - return new Person(src); - } -}`}),d.jsxs("ul",{className:"text-[10px] text-gray-500 dark:text-white/50 space-y-0.5","aria-label":"Features",children:[d.jsx("li",{children:"Factory methods"}),d.jsx("li",{children:"Default initialization"}),d.jsx("li",{children:"More verbose"})]})]})]}),d.jsxs("div",{className:"flex items-center gap-3",role:"group","aria-label":"Navigation",children:[i&&r&&d.jsx("button",{onClick:r,className:"px-4 py-2 rounded-lg text-sm font-medium transition-colors border border-gray-300 dark:border-gray-600 text-gray-600 dark:text-gray-400 hover:bg-gray-100 dark:hover:bg-gray-800 focus:outline-none focus:ring-2 focus:ring-gray-500 focus:ring-offset-2 dark:focus:ring-offset-gray-900",children:"Back"}),d.jsx("button",{onClick:n,className:"px-6 py-2.5 rounded-lg border border-red-500 text-red-600 dark:text-red-400 text-sm font-medium hover:bg-red-500/10 transition-colors focus:outline-none focus:ring-2 focus:ring-red-500 focus:ring-offset-2 dark:focus:ring-offset-gray-900",children:"Continue"})]})]})}function V3({selectedFramework:e,preferTypeScript:t,onSelect:n,onNext:r,onSkip:i,onBack:s,canGoBack:o}){return d.jsx(Tu,{title:"Default Template",subtitle:"Choose a framework for new projects",primaryAction:r,primaryLabel:"Continue",secondaryAction:i,secondaryLabel:"Skip",onBack:s,canGoBack:o,children:d.jsx("div",{className:"grid grid-cols-4 gap-3 max-w-2xl mx-auto p-1",role:"radiogroup","aria-label":"Framework templates",children:D3.map(a=>d.jsxs("button",{onClick:()=>n(a.id),role:"radio","aria-checked":e===a.id,className:`aspect-square rounded-xl p-4 flex flex-col items-center justify-center gap-2 transition-all border-2 focus:outline-none focus:ring-2 focus:ring-red-500 focus:ring-offset-2 dark:focus:ring-offset-gray-900 ${e===a.id?"border-red-500 bg-red-500/10 shadow-lg shadow-red-500/10":"border-gray-200 dark:border-white/10 bg-gray-100 dark:bg-white/5 hover:bg-gray-200 dark:hover:bg-white/10"}`,children:[d.jsx("img",{src:`/logos/${a.id==="vanilla"?t?"typescript":"javascript":a.icon}.svg`,alt:"","aria-hidden":"true",className:"w-12 h-12"}),d.jsx("span",{className:"text-sm font-medium text-gray-900 dark:text-white",children:a.name})]},a.id))})})}function b3({defaults:e,onDefaultsChange:t,onNext:n,onSkip:r,saving:i,onBack:s,canGoBack:o}){const[a,l]=S.useState(null),[u,c]=S.useState(""),h=x=>{x==="name"?c(e.author.name):x==="company"?c(e.author.company):x==="bundleId"&&c(e.project.productIdentifierPrefix),l(x)},f=()=>{a==="name"?t({...e,author:{...e.author,name:u}}):a==="company"?t({...e,author:{...e.author,company:u}}):a==="bundleId"&&t({...e,project:{...e.project,productIdentifierPrefix:u}}),l(null)},v=x=>{x.key==="Enter"?f():x.key==="Escape"&&l(null)};return d.jsx(Tu,{title:"Project Defaults",subtitle:"Set defaults for new Wails projects",primaryAction:n,primaryLabel:i?"Saving...":"Continue",primaryDisabled:i,secondaryAction:r,secondaryLabel:"Skip",onBack:s,canGoBack:o,children:d.jsxs("div",{className:"max-w-xl mx-auto",children:[d.jsxs("div",{className:"settings-group",role:"group","aria-label":"Project default settings",children:[a==="name"?d.jsxs("div",{className:"settings-row",children:[d.jsx("label",{htmlFor:"author-input",className:"sr-only",children:"Author name"}),d.jsx("div",{className:"flex-1",children:d.jsx("input",{id:"author-input",type:"text",value:u,onChange:x=>c(x.target.value),onKeyDown:v,onBlur:f,autoFocus:!0,placeholder:"Your Name","aria-label":"Author name",className:"w-full bg-transparent border-none text-sm text-gray-900 dark:text-white placeholder-gray-400 dark:placeholder-gray-500 focus:outline-none focus:ring-2 focus:ring-red-500 rounded px-1"})})]}):d.jsxs("button",{className:"settings-row w-full text-left focus:outline-none focus:ring-2 focus:ring-inset focus:ring-red-500",onClick:()=>h("name"),"aria-label":`Author: ${e.author.name||"Not set"}. Click to edit.`,children:[d.jsx("span",{className:"text-sm font-medium text-gray-800 dark:text-white/90",children:"Author"}),d.jsxs("div",{className:"flex items-center gap-2 text-sm text-gray-600 dark:text-white/65",children:[d.jsx("span",{children:e.author.name||"Not set"}),d.jsx("span",{className:"text-gray-400 dark:text-white/40 text-xs","aria-hidden":"true",children:"▸"})]})]}),a==="company"?d.jsxs("div",{className:"settings-row",children:[d.jsx("label",{htmlFor:"company-input",className:"sr-only",children:"Company name"}),d.jsx("div",{className:"flex-1",children:d.jsx("input",{id:"company-input",type:"text",value:u,onChange:x=>c(x.target.value),onKeyDown:v,onBlur:f,autoFocus:!0,placeholder:"Acme Corp","aria-label":"Company name",className:"w-full bg-transparent border-none text-sm text-gray-900 dark:text-white placeholder-gray-400 dark:placeholder-gray-500 focus:outline-none focus:ring-2 focus:ring-red-500 rounded px-1"})})]}):d.jsxs("button",{className:"settings-row w-full text-left focus:outline-none focus:ring-2 focus:ring-inset focus:ring-red-500",onClick:()=>h("company"),"aria-label":`Company: ${e.author.company||"Not set"}. Click to edit.`,children:[d.jsx("span",{className:"text-sm font-medium text-gray-800 dark:text-white/90",children:"Company"}),d.jsxs("div",{className:"flex items-center gap-2 text-sm text-gray-600 dark:text-white/65",children:[d.jsx("span",{children:e.author.company||"Not set"}),d.jsx("span",{className:"text-gray-400 dark:text-white/40 text-xs","aria-hidden":"true",children:"▸"})]})]}),a==="bundleId"?d.jsxs("div",{className:"settings-row",children:[d.jsx("label",{htmlFor:"bundle-input",className:"sr-only",children:"Bundle identifier"}),d.jsx("div",{className:"flex-1",children:d.jsx("input",{id:"bundle-input",type:"text",value:u,onChange:x=>c(x.target.value),onKeyDown:v,onBlur:f,autoFocus:!0,placeholder:"com.example","aria-label":"Bundle identifier",className:"w-full bg-transparent border-none text-sm text-gray-900 dark:text-white placeholder-gray-400 dark:placeholder-gray-500 focus:outline-none focus:ring-2 focus:ring-red-500 rounded px-1 font-mono"})})]}):d.jsxs("button",{className:"settings-row w-full text-left focus:outline-none focus:ring-2 focus:ring-inset focus:ring-red-500",onClick:()=>h("bundleId"),"aria-label":`Bundle identifier: ${e.project.productIdentifierPrefix||"com.example"}. Click to edit.`,children:[d.jsx("span",{className:"text-sm font-medium text-gray-800 dark:text-white/90",children:"Bundle identifier"}),d.jsxs("div",{className:"flex items-center gap-2 text-sm text-gray-600 dark:text-white/65",children:[d.jsx("span",{className:"font-mono",children:e.project.productIdentifierPrefix||"com.example"}),d.jsx("span",{className:"text-gray-400 dark:text-white/40 text-xs","aria-hidden":"true",children:"▸"})]})]})]}),d.jsx("p",{className:"text-xs text-gray-500 dark:text-white/40 mt-3 text-center",id:"settings-description",children:"These defaults are used when creating new projects"})]})})}function I3(){const e=S.useRef(null);S.useEffect(()=>{var n;(n=e.current)==null||n.focus()},[]);const t=()=>{window.open("https://v3alpha.wails.io/quick-start/first-app/","_blank","noopener,noreferrer")};return d.jsxs(B.main,{variants:we,initial:"initial",animate:"animate",exit:"exit",transition:{duration:.3},"aria-labelledby":"complete-title",className:"flex-1 flex flex-col items-center justify-center px-8",children:[d.jsx(B.div,{initial:{scale:0},animate:{scale:1},transition:{type:"spring",stiffness:200,damping:15},className:"w-16 h-16 rounded-full bg-green-500/20 flex items-center justify-center mb-4","aria-hidden":"true",children:d.jsx("svg",{className:"w-8 h-8 text-green-500",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",children:d.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2.5,d:"M5 13l4 4L19 7"})})}),d.jsx("h2",{ref:e,id:"complete-title",className:"text-xl font-semibold text-gray-900 dark:text-white mb-6 focus:outline-none",tabIndex:-1,children:"You're ready to build!"}),d.jsx("button",{onClick:t,className:"px-5 py-2 rounded-lg border border-red-500 text-red-600 dark:text-red-400 text-sm font-medium hover:bg-red-500/10 transition-colors focus:outline-none focus:ring-2 focus:ring-red-500 focus:ring-offset-2 dark:focus:ring-offset-gray-900",children:"Start Building"})]})}function _3(){const[e,t]=S.useState("splash"),[n,r]=S.useState([]),[i,s]=S.useState([]),[o,a]=S.useState(null),[l,u]=S.useState(null),[c,h]=S.useState(!1),[f,v]=S.useState({author:{name:"",company:""},project:{productIdentifierPrefix:"com.example",defaultTemplate:"vanilla",copyrightTemplate:"(c) {year}, {company}",descriptionTemplate:"A {name} application",defaultVersion:"0.1.0",useInterfaces:!0}}),[x,y]=S.useState(!1),[T,m]=S.useState(!1),[p,g]=S.useState(!0),[w,k]=S.useState("vanilla"),[j,N]=S.useState(!0),[C,b]=S.useState(!1),[L,J]=S.useState(null),[Be,ft]=S.useState(()=>{if(typeof window<"u"){const D=localStorage.getItem("wails-setup-theme");if(D==="light"||D==="dark")return D;if(window.matchMedia("(prefers-color-scheme: light)").matches)return"light"}return"dark"}),H=D=>{r(I=>[...I,e]),t(D)},ge=()=>{if(n.length===0)return;const D=[...n];let I=D.pop();for(;I==="checking"&&D.length>0;)I=D.pop();r(D),t(I)},de=n.length>0&&e!=="splash"&&e!=="checking",Y=()=>{ft(D=>{const I=D==="dark"?"light":"dark";return localStorage.setItem("wails-setup-theme",I),I})};S.useEffect(()=>{Be==="dark"?document.documentElement.classList.add("dark"):document.documentElement.classList.remove("dark")},[Be]),S.useEffect(()=>{E()},[]),S.useEffect(()=>{const D=I=>{I.target instanceof HTMLInputElement||I.target instanceof HTMLTextAreaElement||I.key==="Escape"&&de&&(I.preventDefault(),ge())};return window.addEventListener("keydown",D),()=>window.removeEventListener("keydown",D)},[de,e]);const E=async()=>{const D=await m3();a(D.system)},A=async()=>{H("checking");const D=await Xd();s(D),D.filter(qt=>qt.required&&!qt.installed).length===0?t("deps-ready"):t("deps-missing")},V=async()=>{H("cross-platform")},U=async()=>{t("checking");const D=await Xd();s(D),D.filter(qt=>qt.required&&!qt.installed).length===0?t("deps-ready"):t("deps-missing")},re=async()=>{H("cross-platform")},wn=async()=>{H("sdk-license")},ht=async()=>{const D=await Zd();u(D),H("docker-setup")},lr=async()=>{var I;const D=await bi();v(D),N(((I=D.project)==null?void 0:I.useInterfaces)??!0),H("projects")},pt=async()=>{var I;const D=await bi();v(D),N(((I=D.project)==null?void 0:I.useInterfaces)??!0),H("projects")},kn=async()=>{const D=await Zd();u(D)},Q0=async()=>{h(!0),await g3();const D=Io(I=>{u(I),I.pullStatus!=="pulling"&&(h(!1),D())})},X0=async()=>{var I;(c||l&&l.pullStatus==="pulling")&&m(!0);const D=await bi();v(D),N(((I=D.project)==null?void 0:I.useInterfaces)??!0),H("projects")},Z0=async()=>{var I;const D=await bi();v(D),N(((I=D.project)==null?void 0:I.useInterfaces)??!0),H("projects")},q0=async D=>{h(!0);const I=new FormData;I.append("sdk",D),await fetch("/api/docker/build-with-sdk",{method:"POST",body:I});const qt=Io(Nu=>{u(Nu),Nu.pullStatus!=="pulling"&&(h(!1),qt())})},J0=()=>{H("signing")},em=()=>{H("signing")},tm=()=>{H("language-select")},nm=()=>{H("language-select")},rm=()=>{H(p?"binding-style":"template-select")},im=()=>{H("template-select")},sm=async()=>{const D=p&&w!=="vanilla"?`${w}-ts`:p&&w==="vanilla"?"vanilla-ts":w,I={...f,project:{...f.project,defaultTemplate:D,useInterfaces:p?j:!0}};y(!0),await qd(I),y(!1),H("complete")},om=async()=>{const D={...f,project:{...f.project,useInterfaces:p?j:!0}};y(!0),await qd(D),y(!1),H("complete")};return S.useEffect(()=>{if(T&&(c||l&&l.pullStatus==="pulling"))return Io(I=>{u(I),I.pullStatus!=="pulling"&&h(!1)})},[T,c,l==null?void 0:l.pullStatus]),S.useEffect(()=>{if(L==="pulling"&&(l==null?void 0:l.pullStatus)==="complete"&&e!=="docker-setup"){b(!0);const D=setTimeout(()=>b(!1),3e3);return()=>clearTimeout(D)}J((l==null?void 0:l.pullStatus)||null)},[l==null?void 0:l.pullStatus,e]),d.jsx(G0.Provider,{value:{theme:Be,toggleTheme:Y},children:d.jsxs("div",{className:"min-h-screen bg-gray-50 dark:bg-[#0f0f0f] flex items-center justify-center p-4 transition-colors relative overflow-hidden",children:[d.jsx("div",{className:"absolute inset-0 overflow-hidden pointer-events-none",children:d.jsxs("div",{className:"scrolling-bg w-full h-[200%] opacity-[0.08] dark:opacity-[0.06]",children:[d.jsx("img",{src:"/showcase/montage.png",alt:"",className:"w-full h-1/2 object-cover object-center"}),d.jsx("img",{src:"/showcase/montage.png",alt:"",className:"w-full h-1/2 object-cover object-center"})]})}),d.jsxs("div",{className:"w-[75vw] max-w-[1200px] h-[75vh] max-h-[800px] glass-card rounded-2xl flex overflow-hidden relative z-10",children:[d.jsx(S3,{currentStep:e,dockerStatus:l,buildingDocker:T&&(c||(l==null?void 0:l.pullStatus)==="pulling")}),d.jsxs("div",{className:"flex-1 flex flex-col min-w-0 bg-white/50 dark:bg-white/[0.03] relative",children:[d.jsx(rd,{children:C&&d.jsxs(B.div,{initial:{opacity:0,y:-20,scale:.95},animate:{opacity:1,y:0,scale:1},exit:{opacity:0,y:-10,scale:.95},transition:{duration:.15,ease:"easeOut"},className:"absolute top-4 right-4 z-50 flex items-center gap-2 px-3 py-2 bg-green-500 text-white rounded-lg shadow-lg",children:[d.jsx("svg",{className:"w-4 h-4",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",strokeWidth:2.5,children:d.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M5 13l4 4L19 7"})}),d.jsx("span",{className:"text-sm font-medium",children:"Docker image ready"})]})}),d.jsx("div",{className:"flex-1 flex flex-col min-h-0",children:d.jsxs(rd,{mode:"wait",children:[e==="splash"&&d.jsx(j3,{onNext:A},"splash"),e==="checking"&&d.jsx(C3,{},"checking"),e==="deps-ready"&&d.jsx(T3,{onNext:V,onBack:ge,canGoBack:de},"deps-ready"),e==="deps-missing"&&d.jsx(N3,{dependencies:i,onRetry:U,onContinue:re,onBack:ge,canGoBack:de},"deps-missing"),e==="cross-platform"&&d.jsx(P3,{dockerDep:i.find(D=>D.name==="docker"),onYes:wn,onSkip:pt,onBack:ge,canGoBack:de},"cross-platform"),e==="sdk-license"&&d.jsx(M3,{onAgree:ht,onDecline:lr,onBack:ge,canGoBack:de},"sdk-license"),e==="docker-setup"&&d.jsx(L3,{dockerStatus:l,buildingImage:c,onBuildImage:Q0,onCheckAgain:kn,onContinueBackground:X0,onUseLocalSDK:q0,onSkip:Z0,onBack:ge,canGoBack:de},"docker-setup"),e==="projects"&&d.jsx(b3,{defaults:f,onDefaultsChange:v,onNext:J0,onSkip:em,saving:x,onBack:ge,canGoBack:de},"projects"),e==="signing"&&d.jsx(x3,{onNext:tm,onSkip:nm,onBack:ge,canGoBack:de},"signing"),e==="language-select"&&d.jsx(A3,{preferTypeScript:p,onSelect:g,onNext:rm,onBack:ge,canGoBack:de},"language-select"),e==="binding-style"&&d.jsx(R3,{useInterfaces:j,onSelect:N,onNext:im,onBack:ge,canGoBack:de},"binding-style"),e==="template-select"&&d.jsx(V3,{selectedFramework:w,preferTypeScript:p,onSelect:k,onNext:sm,onSkip:om,onBack:ge,canGoBack:de},"template-select"),e==="complete"&&d.jsx(I3,{},"complete")]})})]})]})]})})}_o.createRoot(document.getElementById("root")).render(d.jsx(jm.StrictMode,{children:d.jsx(_3,{})})); diff --git a/v3/internal/setupwizard/frontend/dist/assets/index-DgfT-RTI.js b/v3/internal/setupwizard/frontend/dist/assets/index-DgfT-RTI.js new file mode 100644 index 000000000..718328ff6 --- /dev/null +++ b/v3/internal/setupwizard/frontend/dist/assets/index-DgfT-RTI.js @@ -0,0 +1,60 @@ +(function(){const t=document.createElement("link").relList;if(t&&t.supports&&t.supports("modulepreload"))return;for(const i of document.querySelectorAll('link[rel="modulepreload"]'))r(i);new MutationObserver(i=>{for(const s of i)if(s.type==="childList")for(const o of s.addedNodes)o.tagName==="LINK"&&o.rel==="modulepreload"&&r(o)}).observe(document,{childList:!0,subtree:!0});function n(i){const s={};return i.integrity&&(s.integrity=i.integrity),i.referrerPolicy&&(s.referrerPolicy=i.referrerPolicy),i.crossOrigin==="use-credentials"?s.credentials="include":i.crossOrigin==="anonymous"?s.credentials="omit":s.credentials="same-origin",s}function r(i){if(i.ep)return;i.ep=!0;const s=n(i);fetch(i.href,s)}})();function lm(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var tf={exports:{}},Ms={},nf={exports:{}},_={};/** + * @license React + * react.production.min.js + * + * Copyright (c) Facebook, Inc. and its affiliates. + * + * This source code is licensed under the MIT license found in the + * LICENSE file in the root directory of this source tree. + */var oi=Symbol.for("react.element"),um=Symbol.for("react.portal"),cm=Symbol.for("react.fragment"),dm=Symbol.for("react.strict_mode"),fm=Symbol.for("react.profiler"),hm=Symbol.for("react.provider"),pm=Symbol.for("react.context"),mm=Symbol.for("react.forward_ref"),gm=Symbol.for("react.suspense"),ym=Symbol.for("react.memo"),vm=Symbol.for("react.lazy"),Du=Symbol.iterator;function xm(e){return e===null||typeof e!="object"?null:(e=Du&&e[Du]||e["@@iterator"],typeof e=="function"?e:null)}var rf={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},sf=Object.assign,of={};function nr(e,t,n){this.props=e,this.context=t,this.refs=of,this.updater=n||rf}nr.prototype.isReactComponent={};nr.prototype.setState=function(e,t){if(typeof e!="object"&&typeof e!="function"&&e!=null)throw Error("setState(...): takes an object of state variables to update or a function which returns an object of state variables.");this.updater.enqueueSetState(this,e,t,"setState")};nr.prototype.forceUpdate=function(e){this.updater.enqueueForceUpdate(this,e,"forceUpdate")};function af(){}af.prototype=nr.prototype;function el(e,t,n){this.props=e,this.context=t,this.refs=of,this.updater=n||rf}var tl=el.prototype=new af;tl.constructor=el;sf(tl,nr.prototype);tl.isPureReactComponent=!0;var bu=Array.isArray,lf=Object.prototype.hasOwnProperty,nl={current:null},uf={key:!0,ref:!0,__self:!0,__source:!0};function cf(e,t,n){var r,i={},s=null,o=null;if(t!=null)for(r in t.ref!==void 0&&(o=t.ref),t.key!==void 0&&(s=""+t.key),t)lf.call(t,r)&&!uf.hasOwnProperty(r)&&(i[r]=t[r]);var a=arguments.length-2;if(a===1)i.children=n;else if(1>>1,ie=E[H];if(0>>1;Hi(lr,R))mti(kn,lr)?(E[H]=kn,E[mt]=R,H=mt):(E[H]=lr,E[pt]=R,H=pt);else if(mti(kn,R))E[H]=kn,E[mt]=R,H=mt;else break e}}return L}function i(E,L){var R=E.sortIndex-L.sortIndex;return R!==0?R:E.id-L.id}if(typeof performance=="object"&&typeof performance.now=="function"){var s=performance;e.unstable_now=function(){return s.now()}}else{var o=Date,a=o.now();e.unstable_now=function(){return o.now()-a}}var l=[],u=[],c=1,h=null,f=3,y=!1,v=!1,x=!1,P=typeof setTimeout=="function"?setTimeout:null,m=typeof clearTimeout=="function"?clearTimeout:null,p=typeof setImmediate<"u"?setImmediate:null;typeof navigator<"u"&&navigator.scheduling!==void 0&&navigator.scheduling.isInputPending!==void 0&&navigator.scheduling.isInputPending.bind(navigator.scheduling);function g(E){for(var L=n(u);L!==null;){if(L.callback===null)r(u);else if(L.startTime<=E)r(u),L.sortIndex=L.expirationTime,t(l,L);else break;L=n(u)}}function k(E){if(x=!1,g(E),!v)if(n(l)!==null)v=!0,fe(S);else{var L=n(u);L!==null&&X(k,L.startTime-E)}}function S(E,L){v=!1,x&&(x=!1,m(j),j=-1),y=!0;var R=f;try{for(g(L),h=n(l);h!==null&&(!(h.expirationTime>L)||E&&!W());){var H=h.callback;if(typeof H=="function"){h.callback=null,f=h.priorityLevel;var ie=H(h.expirationTime<=L);L=e.unstable_now(),typeof ie=="function"?h.callback=ie:h===n(l)&&r(l),g(L)}else r(l);h=n(l)}if(h!==null)var wn=!0;else{var pt=n(u);pt!==null&&X(k,pt.startTime-L),wn=!1}return wn}finally{h=null,f=R,y=!1}}var T=!1,w=null,j=-1,V=5,D=-1;function W(){return!(e.unstable_now()-DE||125H?(E.sortIndex=R,t(u,E),n(l)===null&&E===n(u)&&(x?(m(j),j=-1):x=!0,X(k,R-H))):(E.sortIndex=ie,t(l,E),v||y||(v=!0,fe(S))),E},e.unstable_shouldYield=W,e.unstable_wrapCallback=function(E){var L=f;return function(){var R=f;f=L;try{return E.apply(this,arguments)}finally{f=R}}}})(mf);pf.exports=mf;var bm=pf.exports;/** + * @license React + * react-dom.production.min.js + * + * Copyright (c) Facebook, Inc. and its affiliates. + * + * This source code is licensed under the MIT license found in the + * LICENSE file in the root directory of this source tree. + */var Lm=C,Fe=bm;function N(e){for(var t="https://reactjs.org/docs/error-decoder.html?invariant="+e,n=1;n"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),Bo=Object.prototype.hasOwnProperty,Am=/^[: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]*$/,Au={},Ru={};function Rm(e){return Bo.call(Ru,e)?!0:Bo.call(Au,e)?!1:Am.test(e)?Ru[e]=!0:(Au[e]=!0,!1)}function Vm(e,t,n,r){if(n!==null&&n.type===0)return!1;switch(typeof t){case"function":case"symbol":return!0;case"boolean":return r?!1:n!==null?!n.acceptsBooleans:(e=e.toLowerCase().slice(0,5),e!=="data-"&&e!=="aria-");default:return!1}}function Im(e,t,n,r){if(t===null||typeof t>"u"||Vm(e,t,n,r))return!0;if(r)return!1;if(n!==null)switch(n.type){case 3:return!t;case 4:return t===!1;case 5:return isNaN(t);case 6:return isNaN(t)||1>t}return!1}function Ee(e,t,n,r,i,s,o){this.acceptsBooleans=t===2||t===3||t===4,this.attributeName=r,this.attributeNamespace=i,this.mustUseProperty=n,this.propertyName=e,this.type=t,this.sanitizeURL=s,this.removeEmptyString=o}var ge={};"children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style".split(" ").forEach(function(e){ge[e]=new Ee(e,0,!1,e,null,!1,!1)});[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach(function(e){var t=e[0];ge[t]=new Ee(t,1,!1,e[1],null,!1,!1)});["contentEditable","draggable","spellCheck","value"].forEach(function(e){ge[e]=new Ee(e,2,!1,e.toLowerCase(),null,!1,!1)});["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach(function(e){ge[e]=new Ee(e,2,!1,e,null,!1,!1)});"allowFullScreen async autoFocus autoPlay controls default defer disabled disablePictureInPicture disableRemotePlayback formNoValidate hidden loop noModule noValidate open playsInline readOnly required reversed scoped seamless itemScope".split(" ").forEach(function(e){ge[e]=new Ee(e,3,!1,e.toLowerCase(),null,!1,!1)});["checked","multiple","muted","selected"].forEach(function(e){ge[e]=new Ee(e,3,!0,e,null,!1,!1)});["capture","download"].forEach(function(e){ge[e]=new Ee(e,4,!1,e,null,!1,!1)});["cols","rows","size","span"].forEach(function(e){ge[e]=new Ee(e,6,!1,e,null,!1,!1)});["rowSpan","start"].forEach(function(e){ge[e]=new Ee(e,5,!1,e.toLowerCase(),null,!1,!1)});var il=/[\-:]([a-z])/g;function sl(e){return e[1].toUpperCase()}"accent-height alignment-baseline arabic-form baseline-shift cap-height clip-path clip-rule color-interpolation color-interpolation-filters color-profile color-rendering dominant-baseline enable-background fill-opacity fill-rule flood-color flood-opacity font-family font-size font-size-adjust font-stretch font-style font-variant font-weight glyph-name glyph-orientation-horizontal glyph-orientation-vertical horiz-adv-x horiz-origin-x image-rendering letter-spacing lighting-color marker-end marker-mid marker-start overline-position overline-thickness paint-order panose-1 pointer-events rendering-intent shape-rendering stop-color stop-opacity strikethrough-position strikethrough-thickness stroke-dasharray stroke-dashoffset stroke-linecap stroke-linejoin stroke-miterlimit stroke-opacity stroke-width text-anchor text-decoration text-rendering underline-position underline-thickness unicode-bidi unicode-range units-per-em v-alphabetic v-hanging v-ideographic v-mathematical vector-effect vert-adv-y vert-origin-x vert-origin-y word-spacing writing-mode xmlns:xlink x-height".split(" ").forEach(function(e){var t=e.replace(il,sl);ge[t]=new Ee(t,1,!1,e,null,!1,!1)});"xlink:actuate xlink:arcrole xlink:role xlink:show xlink:title xlink:type".split(" ").forEach(function(e){var t=e.replace(il,sl);ge[t]=new Ee(t,1,!1,e,"http://www.w3.org/1999/xlink",!1,!1)});["xml:base","xml:lang","xml:space"].forEach(function(e){var t=e.replace(il,sl);ge[t]=new Ee(t,1,!1,e,"http://www.w3.org/XML/1998/namespace",!1,!1)});["tabIndex","crossOrigin"].forEach(function(e){ge[e]=new Ee(e,1,!1,e.toLowerCase(),null,!1,!1)});ge.xlinkHref=new Ee("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1);["src","href","action","formAction"].forEach(function(e){ge[e]=new Ee(e,1,!1,e.toLowerCase(),null,!0,!0)});function ol(e,t,n,r){var i=ge.hasOwnProperty(t)?ge[t]:null;(i!==null?i.type!==0:r||!(2a||i[o]!==s[a]){var l=` +`+i[o].replace(" at new "," at ");return e.displayName&&l.includes("")&&(l=l.replace("",e.displayName)),l}while(1<=o&&0<=a);break}}}finally{Zs=!1,Error.prepareStackTrace=n}return(e=e?e.displayName||e.name:"")?xr(e):""}function _m(e){switch(e.tag){case 5:return xr(e.type);case 16:return xr("Lazy");case 13:return xr("Suspense");case 19:return xr("SuspenseList");case 0:case 2:case 15:return e=qs(e.type,!1),e;case 11:return e=qs(e.type.render,!1),e;case 1:return e=qs(e.type,!0),e;default:return""}}function Wo(e){if(e==null)return null;if(typeof e=="function")return e.displayName||e.name||null;if(typeof e=="string")return e;switch(e){case jn:return"Fragment";case Cn:return"Portal";case zo:return"Profiler";case al:return"StrictMode";case Uo:return"Suspense";case $o:return"SuspenseList"}if(typeof e=="object")switch(e.$$typeof){case vf:return(e.displayName||"Context")+".Consumer";case yf:return(e._context.displayName||"Context")+".Provider";case ll:var t=e.render;return e=e.displayName,e||(e=t.displayName||t.name||"",e=e!==""?"ForwardRef("+e+")":"ForwardRef"),e;case ul:return t=e.displayName||null,t!==null?t:Wo(e.type)||"Memo";case Dt:t=e._payload,e=e._init;try{return Wo(e(t))}catch{}}return null}function Fm(e){var t=e.type;switch(e.tag){case 24:return"Cache";case 9:return(t.displayName||"Context")+".Consumer";case 10:return(t._context.displayName||"Context")+".Provider";case 18:return"DehydratedFragment";case 11:return e=t.render,e=e.displayName||e.name||"",t.displayName||(e!==""?"ForwardRef("+e+")":"ForwardRef");case 7:return"Fragment";case 5:return t;case 4:return"Portal";case 3:return"Root";case 6:return"Text";case 16:return Wo(t);case 8:return t===al?"StrictMode":"Mode";case 22:return"Offscreen";case 12:return"Profiler";case 21:return"Scope";case 13:return"Suspense";case 19:return"SuspenseList";case 25:return"TracingMarker";case 1:case 0:case 17:case 2:case 14:case 15:if(typeof t=="function")return t.displayName||t.name||null;if(typeof t=="string")return t}return null}function Wt(e){switch(typeof e){case"boolean":case"number":case"string":case"undefined":return e;case"object":return e;default:return""}}function wf(e){var t=e.type;return(e=e.nodeName)&&e.toLowerCase()==="input"&&(t==="checkbox"||t==="radio")}function Om(e){var t=wf(e)?"checked":"value",n=Object.getOwnPropertyDescriptor(e.constructor.prototype,t),r=""+e[t];if(!e.hasOwnProperty(t)&&typeof n<"u"&&typeof n.get=="function"&&typeof n.set=="function"){var i=n.get,s=n.set;return Object.defineProperty(e,t,{configurable:!0,get:function(){return i.call(this)},set:function(o){r=""+o,s.call(this,o)}}),Object.defineProperty(e,t,{enumerable:n.enumerable}),{getValue:function(){return r},setValue:function(o){r=""+o},stopTracking:function(){e._valueTracker=null,delete e[t]}}}}function yi(e){e._valueTracker||(e._valueTracker=Om(e))}function kf(e){if(!e)return!1;var t=e._valueTracker;if(!t)return!0;var n=t.getValue(),r="";return e&&(r=wf(e)?e.checked?"true":"false":e.value),e=r,e!==n?(t.setValue(e),!0):!1}function Ji(e){if(e=e||(typeof document<"u"?document:void 0),typeof e>"u")return null;try{return e.activeElement||e.body}catch{return e.body}}function Ho(e,t){var n=t.checked;return ee({},t,{defaultChecked:void 0,defaultValue:void 0,value:void 0,checked:n??e._wrapperState.initialChecked})}function Iu(e,t){var n=t.defaultValue==null?"":t.defaultValue,r=t.checked!=null?t.checked:t.defaultChecked;n=Wt(t.value!=null?t.value:n),e._wrapperState={initialChecked:r,initialValue:n,controlled:t.type==="checkbox"||t.type==="radio"?t.checked!=null:t.value!=null}}function Sf(e,t){t=t.checked,t!=null&&ol(e,"checked",t,!1)}function Ko(e,t){Sf(e,t);var n=Wt(t.value),r=t.type;if(n!=null)r==="number"?(n===0&&e.value===""||e.value!=n)&&(e.value=""+n):e.value!==""+n&&(e.value=""+n);else if(r==="submit"||r==="reset"){e.removeAttribute("value");return}t.hasOwnProperty("value")?Go(e,t.type,n):t.hasOwnProperty("defaultValue")&&Go(e,t.type,Wt(t.defaultValue)),t.checked==null&&t.defaultChecked!=null&&(e.defaultChecked=!!t.defaultChecked)}function _u(e,t,n){if(t.hasOwnProperty("value")||t.hasOwnProperty("defaultValue")){var r=t.type;if(!(r!=="submit"&&r!=="reset"||t.value!==void 0&&t.value!==null))return;t=""+e._wrapperState.initialValue,n||t===e.value||(e.value=t),e.defaultValue=t}n=e.name,n!==""&&(e.name=""),e.defaultChecked=!!e._wrapperState.initialChecked,n!==""&&(e.name=n)}function Go(e,t,n){(t!=="number"||Ji(e.ownerDocument)!==e)&&(n==null?e.defaultValue=""+e._wrapperState.initialValue:e.defaultValue!==""+n&&(e.defaultValue=""+n))}var wr=Array.isArray;function Bn(e,t,n,r){if(e=e.options,t){t={};for(var i=0;i"+t.valueOf().toString()+"",t=vi.firstChild;e.firstChild;)e.removeChild(e.firstChild);for(;t.firstChild;)e.appendChild(t.firstChild)}});function Fr(e,t){if(t){var n=e.firstChild;if(n&&n===e.lastChild&&n.nodeType===3){n.nodeValue=t;return}}e.textContent=t}var jr={animationIterationCount:!0,aspectRatio:!0,borderImageOutset:!0,borderImageSlice:!0,borderImageWidth:!0,boxFlex:!0,boxFlexGroup:!0,boxOrdinalGroup:!0,columnCount:!0,columns:!0,flex:!0,flexGrow:!0,flexPositive:!0,flexShrink:!0,flexNegative:!0,flexOrder:!0,gridArea:!0,gridRow:!0,gridRowEnd:!0,gridRowSpan:!0,gridRowStart:!0,gridColumn:!0,gridColumnEnd:!0,gridColumnSpan:!0,gridColumnStart:!0,fontWeight:!0,lineClamp:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,tabSize:!0,widows:!0,zIndex:!0,zoom:!0,fillOpacity:!0,floodOpacity:!0,stopOpacity:!0,strokeDasharray:!0,strokeDashoffset:!0,strokeMiterlimit:!0,strokeOpacity:!0,strokeWidth:!0},Bm=["Webkit","ms","Moz","O"];Object.keys(jr).forEach(function(e){Bm.forEach(function(t){t=t+e.charAt(0).toUpperCase()+e.substring(1),jr[t]=jr[e]})});function Pf(e,t,n){return t==null||typeof t=="boolean"||t===""?"":n||typeof t!="number"||t===0||jr.hasOwnProperty(e)&&jr[e]?(""+t).trim():t+"px"}function Nf(e,t){e=e.style;for(var n in t)if(t.hasOwnProperty(n)){var r=n.indexOf("--")===0,i=Pf(n,t[n],r);n==="float"&&(n="cssFloat"),r?e.setProperty(n,i):e[n]=i}}var zm=ee({menuitem:!0},{area:!0,base:!0,br:!0,col:!0,embed:!0,hr:!0,img:!0,input:!0,keygen:!0,link:!0,meta:!0,param:!0,source:!0,track:!0,wbr:!0});function Xo(e,t){if(t){if(zm[e]&&(t.children!=null||t.dangerouslySetInnerHTML!=null))throw Error(N(137,e));if(t.dangerouslySetInnerHTML!=null){if(t.children!=null)throw Error(N(60));if(typeof t.dangerouslySetInnerHTML!="object"||!("__html"in t.dangerouslySetInnerHTML))throw Error(N(61))}if(t.style!=null&&typeof t.style!="object")throw Error(N(62))}}function Zo(e,t){if(e.indexOf("-")===-1)return typeof t.is=="string";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 qo=null;function cl(e){return e=e.target||e.srcElement||window,e.correspondingUseElement&&(e=e.correspondingUseElement),e.nodeType===3?e.parentNode:e}var Jo=null,zn=null,Un=null;function Bu(e){if(e=ui(e)){if(typeof Jo!="function")throw Error(N(280));var t=e.stateNode;t&&(t=Rs(t),Jo(e.stateNode,e.type,t))}}function Ef(e){zn?Un?Un.push(e):Un=[e]:zn=e}function Mf(){if(zn){var e=zn,t=Un;if(Un=zn=null,Bu(e),t)for(e=0;e>>=0,e===0?32:31-(qm(e)/Jm|0)|0}var xi=64,wi=4194304;function kr(e){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: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 e&4194240;case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:return e&130023424;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 1073741824;default:return e}}function rs(e,t){var n=e.pendingLanes;if(n===0)return 0;var r=0,i=e.suspendedLanes,s=e.pingedLanes,o=n&268435455;if(o!==0){var a=o&~i;a!==0?r=kr(a):(s&=o,s!==0&&(r=kr(s)))}else o=n&~i,o!==0?r=kr(o):s!==0&&(r=kr(s));if(r===0)return 0;if(t!==0&&t!==r&&!(t&i)&&(i=r&-r,s=t&-t,i>=s||i===16&&(s&4194240)!==0))return t;if(r&4&&(r|=n&16),t=e.entangledLanes,t!==0)for(e=e.entanglements,t&=r;0n;n++)t.push(e);return t}function ai(e,t,n){e.pendingLanes|=t,t!==536870912&&(e.suspendedLanes=0,e.pingedLanes=0),e=e.eventTimes,t=31-rt(t),e[t]=n}function rg(e,t){var n=e.pendingLanes&~t;e.pendingLanes=t,e.suspendedLanes=0,e.pingedLanes=0,e.expiredLanes&=t,e.mutableReadLanes&=t,e.entangledLanes&=t,t=e.entanglements;var r=e.eventTimes;for(e=e.expirationTimes;0=Pr),Qu=" ",Xu=!1;function Qf(e,t){switch(e){case"keyup":return bg.indexOf(t.keyCode)!==-1;case"keydown":return t.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function Xf(e){return e=e.detail,typeof e=="object"&&"data"in e?e.data:null}var Tn=!1;function Ag(e,t){switch(e){case"compositionend":return Xf(t);case"keypress":return t.which!==32?null:(Xu=!0,Qu);case"textInput":return e=t.data,e===Qu&&Xu?null:e;default:return null}}function Rg(e,t){if(Tn)return e==="compositionend"||!vl&&Qf(e,t)?(e=Gf(),Bi=ml=Rt=null,Tn=!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)return{node:n,offset:t-e};e=r}e:{for(;n;){if(n.nextSibling){n=n.nextSibling;break e}n=n.parentNode}n=void 0}n=ec(n)}}function eh(e,t){return e&&t?e===t?!0:e&&e.nodeType===3?!1:t&&t.nodeType===3?eh(e,t.parentNode):"contains"in e?e.contains(t):e.compareDocumentPosition?!!(e.compareDocumentPosition(t)&16):!1:!1}function th(){for(var e=window,t=Ji();t instanceof e.HTMLIFrameElement;){try{var n=typeof t.contentWindow.location.href=="string"}catch{n=!1}if(n)e=t.contentWindow;else break;t=Ji(e.document)}return t}function xl(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")}function $g(e){var t=th(),n=e.focusedElem,r=e.selectionRange;if(t!==n&&n&&n.ownerDocument&&eh(n.ownerDocument.documentElement,n)){if(r!==null&&xl(n)){if(t=r.start,e=r.end,e===void 0&&(e=t),"selectionStart"in n)n.selectionStart=t,n.selectionEnd=Math.min(e,n.value.length);else if(e=(t=n.ownerDocument||document)&&t.defaultView||window,e.getSelection){e=e.getSelection();var i=n.textContent.length,s=Math.min(r.start,i);r=r.end===void 0?s:Math.min(r.end,i),!e.extend&&s>r&&(i=r,r=s,s=i),i=tc(n,s);var o=tc(n,r);i&&o&&(e.rangeCount!==1||e.anchorNode!==i.node||e.anchorOffset!==i.offset||e.focusNode!==o.node||e.focusOffset!==o.offset)&&(t=t.createRange(),t.setStart(i.node,i.offset),e.removeAllRanges(),s>r?(e.addRange(t),e.extend(o.node,o.offset)):(t.setEnd(o.node,o.offset),e.addRange(t)))}}for(t=[],e=n;e=e.parentNode;)e.nodeType===1&&t.push({element:e,left:e.scrollLeft,top:e.scrollTop});for(typeof n.focus=="function"&&n.focus(),n=0;n=document.documentMode,Pn=null,sa=null,Er=null,oa=!1;function nc(e,t,n){var r=n.window===n?n.document:n.nodeType===9?n:n.ownerDocument;oa||Pn==null||Pn!==Ji(r)||(r=Pn,"selectionStart"in r&&xl(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}),Er&&Wr(Er,r)||(Er=r,r=os(sa,"onSelect"),0Mn||(e.current=fa[Mn],fa[Mn]=null,Mn--)}function $(e,t){Mn++,fa[Mn]=e.current,e.current=t}var Ht={},Se=Qt(Ht),Le=Qt(!1),hn=Ht;function Yn(e,t){var n=e.type.contextTypes;if(!n)return Ht;var r=e.stateNode;if(r&&r.__reactInternalMemoizedUnmaskedChildContext===t)return r.__reactInternalMemoizedMaskedChildContext;var i={},s;for(s in n)i[s]=t[s];return r&&(e=e.stateNode,e.__reactInternalMemoizedUnmaskedChildContext=t,e.__reactInternalMemoizedMaskedChildContext=i),i}function Ae(e){return e=e.childContextTypes,e!=null}function ls(){G(Le),G(Se)}function uc(e,t,n){if(Se.current!==Ht)throw Error(N(168));$(Se,t),$(Le,n)}function ch(e,t,n){var r=e.stateNode;if(t=t.childContextTypes,typeof r.getChildContext!="function")return n;r=r.getChildContext();for(var i in r)if(!(i in t))throw Error(N(108,Fm(e)||"Unknown",i));return ee({},n,r)}function us(e){return e=(e=e.stateNode)&&e.__reactInternalMemoizedMergedChildContext||Ht,hn=Se.current,$(Se,e),$(Le,Le.current),!0}function cc(e,t,n){var r=e.stateNode;if(!r)throw Error(N(169));n?(e=ch(e,t,hn),r.__reactInternalMemoizedMergedChildContext=e,G(Le),G(Se),$(Se,e)):G(Le),$(Le,n)}var yt=null,Vs=!1,ho=!1;function dh(e){yt===null?yt=[e]:yt.push(e)}function t1(e){Vs=!0,dh(e)}function Xt(){if(!ho&&yt!==null){ho=!0;var e=0,t=z;try{var n=yt;for(z=1;e>=o,i-=o,vt=1<<32-rt(t)+i|n<j?(V=w,w=null):V=w.sibling;var D=f(m,w,g[j],k);if(D===null){w===null&&(w=V);break}e&&w&&D.alternate===null&&t(m,w),p=s(D,p,j),T===null?S=D:T.sibling=D,T=D,w=V}if(j===g.length)return n(m,w),Y&&en(m,j),S;if(w===null){for(;jj?(V=w,w=null):V=w.sibling;var W=f(m,w,D.value,k);if(W===null){w===null&&(w=V);break}e&&w&&W.alternate===null&&t(m,w),p=s(W,p,j),T===null?S=W:T.sibling=W,T=W,w=V}if(D.done)return n(m,w),Y&&en(m,j),S;if(w===null){for(;!D.done;j++,D=g.next())D=h(m,D.value,k),D!==null&&(p=s(D,p,j),T===null?S=D:T.sibling=D,T=D);return Y&&en(m,j),S}for(w=r(m,w);!D.done;j++,D=g.next())D=y(w,m,j,D.value,k),D!==null&&(e&&D.alternate!==null&&w.delete(D.key===null?j:D.key),p=s(D,p,j),T===null?S=D:T.sibling=D,T=D);return e&&w.forEach(function(Ce){return t(m,Ce)}),Y&&en(m,j),S}function P(m,p,g,k){if(typeof g=="object"&&g!==null&&g.type===jn&&g.key===null&&(g=g.props.children),typeof g=="object"&&g!==null){switch(g.$$typeof){case gi:e:{for(var S=g.key,T=p;T!==null;){if(T.key===S){if(S=g.type,S===jn){if(T.tag===7){n(m,T.sibling),p=i(T,g.props.children),p.return=m,m=p;break e}}else if(T.elementType===S||typeof S=="object"&&S!==null&&S.$$typeof===Dt&&hc(S)===T.type){n(m,T.sibling),p=i(T,g.props),p.ref=pr(m,T,g),p.return=m,m=p;break e}n(m,T);break}else t(m,T);T=T.sibling}g.type===jn?(p=cn(g.props.children,m.mode,k,g.key),p.return=m,m=p):(k=Yi(g.type,g.key,g.props,null,m.mode,k),k.ref=pr(m,p,g),k.return=m,m=k)}return o(m);case Cn:e:{for(T=g.key;p!==null;){if(p.key===T)if(p.tag===4&&p.stateNode.containerInfo===g.containerInfo&&p.stateNode.implementation===g.implementation){n(m,p.sibling),p=i(p,g.children||[]),p.return=m,m=p;break e}else{n(m,p);break}else t(m,p);p=p.sibling}p=ko(g,m.mode,k),p.return=m,m=p}return o(m);case Dt:return T=g._init,P(m,p,T(g._payload),k)}if(wr(g))return v(m,p,g,k);if(ur(g))return x(m,p,g,k);Ni(m,g)}return typeof g=="string"&&g!==""||typeof g=="number"?(g=""+g,p!==null&&p.tag===6?(n(m,p.sibling),p=i(p,g),p.return=m,m=p):(n(m,p),p=wo(g,m.mode,k),p.return=m,m=p),o(m)):n(m,p)}return P}var Xn=mh(!0),gh=mh(!1),fs=Qt(null),hs=null,Ln=null,Cl=null;function jl(){Cl=Ln=hs=null}function Tl(e){var t=fs.current;G(fs),e._currentValue=t}function ma(e,t,n){for(;e!==null;){var r=e.alternate;if((e.childLanes&t)!==t?(e.childLanes|=t,r!==null&&(r.childLanes|=t)):r!==null&&(r.childLanes&t)!==t&&(r.childLanes|=t),e===n)break;e=e.return}}function Wn(e,t){hs=e,Cl=Ln=null,e=e.dependencies,e!==null&&e.firstContext!==null&&(e.lanes&t&&(De=!0),e.firstContext=null)}function Qe(e){var t=e._currentValue;if(Cl!==e)if(e={context:e,memoizedValue:t,next:null},Ln===null){if(hs===null)throw Error(N(308));Ln=e,hs.dependencies={lanes:0,firstContext:e}}else Ln=Ln.next=e;return t}var sn=null;function Pl(e){sn===null?sn=[e]:sn.push(e)}function yh(e,t,n,r){var i=t.interleaved;return i===null?(n.next=n,Pl(t)):(n.next=i.next,i.next=n),t.interleaved=n,Ct(e,r)}function Ct(e,t){e.lanes|=t;var n=e.alternate;for(n!==null&&(n.lanes|=t),n=e,e=e.return;e!==null;)e.childLanes|=t,n=e.alternate,n!==null&&(n.childLanes|=t),n=e,e=e.return;return n.tag===3?n.stateNode:null}var bt=!1;function Nl(e){e.updateQueue={baseState:e.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,interleaved:null,lanes:0},effects:null}}function vh(e,t){e=e.updateQueue,t.updateQueue===e&&(t.updateQueue={baseState:e.baseState,firstBaseUpdate:e.firstBaseUpdate,lastBaseUpdate:e.lastBaseUpdate,shared:e.shared,effects:e.effects})}function wt(e,t){return{eventTime:e,lane:t,tag:0,payload:null,callback:null,next:null}}function Bt(e,t,n){var r=e.updateQueue;if(r===null)return null;if(r=r.shared,F&2){var i=r.pending;return i===null?t.next=t:(t.next=i.next,i.next=t),r.pending=t,Ct(e,n)}return i=r.interleaved,i===null?(t.next=t,Pl(r)):(t.next=i.next,i.next=t),r.interleaved=t,Ct(e,n)}function Ui(e,t,n){if(t=t.updateQueue,t!==null&&(t=t.shared,(n&4194240)!==0)){var r=t.lanes;r&=e.pendingLanes,n|=r,t.lanes=n,fl(e,n)}}function pc(e,t){var n=e.updateQueue,r=e.alternate;if(r!==null&&(r=r.updateQueue,n===r)){var i=null,s=null;if(n=n.firstBaseUpdate,n!==null){do{var o={eventTime:n.eventTime,lane:n.lane,tag:n.tag,payload:n.payload,callback:n.callback,next:null};s===null?i=s=o:s=s.next=o,n=n.next}while(n!==null);s===null?i=s=t:s=s.next=t}else i=s=t;n={baseState:r.baseState,firstBaseUpdate:i,lastBaseUpdate:s,shared:r.shared,effects:r.effects},e.updateQueue=n;return}e=n.lastBaseUpdate,e===null?n.firstBaseUpdate=t:e.next=t,n.lastBaseUpdate=t}function ps(e,t,n,r){var i=e.updateQueue;bt=!1;var s=i.firstBaseUpdate,o=i.lastBaseUpdate,a=i.shared.pending;if(a!==null){i.shared.pending=null;var l=a,u=l.next;l.next=null,o===null?s=u:o.next=u,o=l;var c=e.alternate;c!==null&&(c=c.updateQueue,a=c.lastBaseUpdate,a!==o&&(a===null?c.firstBaseUpdate=u:a.next=u,c.lastBaseUpdate=l))}if(s!==null){var h=i.baseState;o=0,c=u=l=null,a=s;do{var f=a.lane,y=a.eventTime;if((r&f)===f){c!==null&&(c=c.next={eventTime:y,lane:0,tag:a.tag,payload:a.payload,callback:a.callback,next:null});e:{var v=e,x=a;switch(f=t,y=n,x.tag){case 1:if(v=x.payload,typeof v=="function"){h=v.call(y,h,f);break e}h=v;break e;case 3:v.flags=v.flags&-65537|128;case 0:if(v=x.payload,f=typeof v=="function"?v.call(y,h,f):v,f==null)break e;h=ee({},h,f);break e;case 2:bt=!0}}a.callback!==null&&a.lane!==0&&(e.flags|=64,f=i.effects,f===null?i.effects=[a]:f.push(a))}else y={eventTime:y,lane:f,tag:a.tag,payload:a.payload,callback:a.callback,next:null},c===null?(u=c=y,l=h):c=c.next=y,o|=f;if(a=a.next,a===null){if(a=i.shared.pending,a===null)break;f=a,a=f.next,f.next=null,i.lastBaseUpdate=f,i.shared.pending=null}}while(!0);if(c===null&&(l=h),i.baseState=l,i.firstBaseUpdate=u,i.lastBaseUpdate=c,t=i.shared.interleaved,t!==null){i=t;do o|=i.lane,i=i.next;while(i!==t)}else s===null&&(i.shared.lanes=0);gn|=o,e.lanes=o,e.memoizedState=h}}function mc(e,t,n){if(e=t.effects,t.effects=null,e!==null)for(t=0;tn?n:4,e(!0);var r=mo.transition;mo.transition={};try{e(!1),t()}finally{z=n,mo.transition=r}}function Vh(){return Xe().memoizedState}function s1(e,t,n){var r=Ut(e);if(n={lane:r,action:n,hasEagerState:!1,eagerState:null,next:null},Ih(e))_h(t,n);else if(n=yh(e,t,n,r),n!==null){var i=Pe();it(n,e,r,i),Fh(n,t,r)}}function o1(e,t,n){var r=Ut(e),i={lane:r,action:n,hasEagerState:!1,eagerState:null,next:null};if(Ih(e))_h(t,i);else{var s=e.alternate;if(e.lanes===0&&(s===null||s.lanes===0)&&(s=t.lastRenderedReducer,s!==null))try{var o=t.lastRenderedState,a=s(o,n);if(i.hasEagerState=!0,i.eagerState=a,st(a,o)){var l=t.interleaved;l===null?(i.next=i,Pl(t)):(i.next=l.next,l.next=i),t.interleaved=i;return}}catch{}finally{}n=yh(e,t,i,r),n!==null&&(i=Pe(),it(n,e,r,i),Fh(n,t,r))}}function Ih(e){var t=e.alternate;return e===J||t!==null&&t===J}function _h(e,t){Mr=gs=!0;var n=e.pending;n===null?t.next=t:(t.next=n.next,n.next=t),e.pending=t}function Fh(e,t,n){if(n&4194240){var r=t.lanes;r&=e.pendingLanes,n|=r,t.lanes=n,fl(e,n)}}var ys={readContext:Qe,useCallback:ye,useContext:ye,useEffect:ye,useImperativeHandle:ye,useInsertionEffect:ye,useLayoutEffect:ye,useMemo:ye,useReducer:ye,useRef:ye,useState:ye,useDebugValue:ye,useDeferredValue:ye,useTransition:ye,useMutableSource:ye,useSyncExternalStore:ye,useId:ye,unstable_isNewReconciler:!1},a1={readContext:Qe,useCallback:function(e,t){return at().memoizedState=[e,t===void 0?null:t],e},useContext:Qe,useEffect:yc,useImperativeHandle:function(e,t,n){return n=n!=null?n.concat([e]):null,Wi(4194308,4,Dh.bind(null,t,e),n)},useLayoutEffect:function(e,t){return Wi(4194308,4,e,t)},useInsertionEffect:function(e,t){return Wi(4,2,e,t)},useMemo:function(e,t){var n=at();return t=t===void 0?null:t,e=e(),n.memoizedState=[e,t],e},useReducer:function(e,t,n){var r=at();return t=n!==void 0?n(t):t,r.memoizedState=r.baseState=t,e={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:e,lastRenderedState:t},r.queue=e,e=e.dispatch=s1.bind(null,J,e),[r.memoizedState,e]},useRef:function(e){var t=at();return e={current:e},t.memoizedState=e},useState:gc,useDebugValue:Vl,useDeferredValue:function(e){return at().memoizedState=e},useTransition:function(){var e=gc(!1),t=e[0];return e=i1.bind(null,e[1]),at().memoizedState=e,[t,e]},useMutableSource:function(){},useSyncExternalStore:function(e,t,n){var r=J,i=at();if(Y){if(n===void 0)throw Error(N(407));n=n()}else{if(n=t(),de===null)throw Error(N(349));mn&30||Sh(r,t,n)}i.memoizedState=n;var s={value:n,getSnapshot:t};return i.queue=s,yc(jh.bind(null,r,s,e),[e]),r.flags|=2048,qr(9,Ch.bind(null,r,s,n,t),void 0,null),n},useId:function(){var e=at(),t=de.identifierPrefix;if(Y){var n=xt,r=vt;n=(r&~(1<<32-rt(r)-1)).toString(32)+n,t=":"+t+"R"+n,n=Xr++,0<\/script>",e=e.removeChild(e.firstChild)):typeof r.is=="string"?e=o.createElement(n,{is:r.is}):(e=o.createElement(n),n==="select"&&(o=e,r.multiple?o.multiple=!0:r.size&&(o.size=r.size))):e=o.createElementNS(e,n),e[lt]=t,e[Gr]=r,Yh(e,t,!1,!1),t.stateNode=e;e:{switch(o=Zo(n,r),n){case"dialog":K("cancel",e),K("close",e),i=r;break;case"iframe":case"object":case"embed":K("load",e),i=r;break;case"video":case"audio":for(i=0;iJn&&(t.flags|=128,r=!0,mr(s,!1),t.lanes=4194304)}else{if(!r)if(e=ms(o),e!==null){if(t.flags|=128,r=!0,n=e.updateQueue,n!==null&&(t.updateQueue=n,t.flags|=4),mr(s,!0),s.tail===null&&s.tailMode==="hidden"&&!o.alternate&&!Y)return ve(t),null}else 2*re()-s.renderingStartTime>Jn&&n!==1073741824&&(t.flags|=128,r=!0,mr(s,!1),t.lanes=4194304);s.isBackwards?(o.sibling=t.child,t.child=o):(n=s.last,n!==null?n.sibling=o:t.child=o,s.last=o)}return s.tail!==null?(t=s.tail,s.rendering=t,s.tail=t.sibling,s.renderingStartTime=re(),t.sibling=null,n=Z.current,$(Z,r?n&1|2:n&1),t):(ve(t),null);case 22:case 23:return zl(),r=t.memoizedState!==null,e!==null&&e.memoizedState!==null!==r&&(t.flags|=8192),r&&t.mode&1?Ve&1073741824&&(ve(t),t.subtreeFlags&6&&(t.flags|=8192)):ve(t),null;case 24:return null;case 25:return null}throw Error(N(156,t.tag))}function m1(e,t){switch(kl(t),t.tag){case 1:return Ae(t.type)&&ls(),e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 3:return Zn(),G(Le),G(Se),Dl(),e=t.flags,e&65536&&!(e&128)?(t.flags=e&-65537|128,t):null;case 5:return Ml(t),null;case 13:if(G(Z),e=t.memoizedState,e!==null&&e.dehydrated!==null){if(t.alternate===null)throw Error(N(340));Qn()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 19:return G(Z),null;case 4:return Zn(),null;case 10:return Tl(t.type._context),null;case 22:case 23:return zl(),null;case 24:return null;default:return null}}var Mi=!1,xe=!1,g1=typeof WeakSet=="function"?WeakSet:Set,M=null;function An(e,t){var n=e.ref;if(n!==null)if(typeof n=="function")try{n(null)}catch(r){ne(e,t,r)}else n.current=null}function ja(e,t,n){try{n()}catch(r){ne(e,t,r)}}var Ec=!1;function y1(e,t){if(aa=is,e=th(),xl(e)){if("selectionStart"in e)var n={start:e.selectionStart,end:e.selectionEnd};else e:{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,s=r.focusNode;r=r.focusOffset;try{n.nodeType,s.nodeType}catch{n=null;break e}var o=0,a=-1,l=-1,u=0,c=0,h=e,f=null;t:for(;;){for(var y;h!==n||i!==0&&h.nodeType!==3||(a=o+i),h!==s||r!==0&&h.nodeType!==3||(l=o+r),h.nodeType===3&&(o+=h.nodeValue.length),(y=h.firstChild)!==null;)f=h,h=y;for(;;){if(h===e)break t;if(f===n&&++u===i&&(a=o),f===s&&++c===r&&(l=o),(y=h.nextSibling)!==null)break;h=f,f=h.parentNode}h=y}n=a===-1||l===-1?null:{start:a,end:l}}else n=null}n=n||{start:0,end:0}}else n=null;for(la={focusedElem:e,selectionRange:n},is=!1,M=t;M!==null;)if(t=M,e=t.child,(t.subtreeFlags&1028)!==0&&e!==null)e.return=t,M=e;else for(;M!==null;){t=M;try{var v=t.alternate;if(t.flags&1024)switch(t.tag){case 0:case 11:case 15:break;case 1:if(v!==null){var x=v.memoizedProps,P=v.memoizedState,m=t.stateNode,p=m.getSnapshotBeforeUpdate(t.elementType===t.type?x:et(t.type,x),P);m.__reactInternalSnapshotBeforeUpdate=p}break;case 3:var g=t.stateNode.containerInfo;g.nodeType===1?g.textContent="":g.nodeType===9&&g.documentElement&&g.removeChild(g.documentElement);break;case 5:case 6:case 4:case 17:break;default:throw Error(N(163))}}catch(k){ne(t,t.return,k)}if(e=t.sibling,e!==null){e.return=t.return,M=e;break}M=t.return}return v=Ec,Ec=!1,v}function Dr(e,t,n){var r=t.updateQueue;if(r=r!==null?r.lastEffect:null,r!==null){var i=r=r.next;do{if((i.tag&e)===e){var s=i.destroy;i.destroy=void 0,s!==void 0&&ja(t,n,s)}i=i.next}while(i!==r)}}function Fs(e,t){if(t=t.updateQueue,t=t!==null?t.lastEffect:null,t!==null){var n=t=t.next;do{if((n.tag&e)===e){var r=n.create;n.destroy=r()}n=n.next}while(n!==t)}}function Ta(e){var t=e.ref;if(t!==null){var n=e.stateNode;switch(e.tag){case 5:e=n;break;default:e=n}typeof t=="function"?t(e):t.current=e}}function Zh(e){var t=e.alternate;t!==null&&(e.alternate=null,Zh(t)),e.child=null,e.deletions=null,e.sibling=null,e.tag===5&&(t=e.stateNode,t!==null&&(delete t[lt],delete t[Gr],delete t[da],delete t[Jg],delete t[e1])),e.stateNode=null,e.return=null,e.dependencies=null,e.memoizedProps=null,e.memoizedState=null,e.pendingProps=null,e.stateNode=null,e.updateQueue=null}function qh(e){return e.tag===5||e.tag===3||e.tag===4}function Mc(e){e:for(;;){for(;e.sibling===null;){if(e.return===null||qh(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.flags&2||e.child===null||e.tag===4)continue e;e.child.return=e,e=e.child}if(!(e.flags&2))return e.stateNode}}function Pa(e,t,n){var r=e.tag;if(r===5||r===6)e=e.stateNode,t?n.nodeType===8?n.parentNode.insertBefore(e,t):n.insertBefore(e,t):(n.nodeType===8?(t=n.parentNode,t.insertBefore(e,n)):(t=n,t.appendChild(e)),n=n._reactRootContainer,n!=null||t.onclick!==null||(t.onclick=as));else if(r!==4&&(e=e.child,e!==null))for(Pa(e,t,n),e=e.sibling;e!==null;)Pa(e,t,n),e=e.sibling}function Na(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&&(e=e.child,e!==null))for(Na(e,t,n),e=e.sibling;e!==null;)Na(e,t,n),e=e.sibling}var he=null,tt=!1;function Et(e,t,n){for(n=n.child;n!==null;)Jh(e,t,n),n=n.sibling}function Jh(e,t,n){if(ut&&typeof ut.onCommitFiberUnmount=="function")try{ut.onCommitFiberUnmount(Ds,n)}catch{}switch(n.tag){case 5:xe||An(n,t);case 6:var r=he,i=tt;he=null,Et(e,t,n),he=r,tt=i,he!==null&&(tt?(e=he,n=n.stateNode,e.nodeType===8?e.parentNode.removeChild(n):e.removeChild(n)):he.removeChild(n.stateNode));break;case 18:he!==null&&(tt?(e=he,n=n.stateNode,e.nodeType===8?fo(e.parentNode,n):e.nodeType===1&&fo(e,n),Ur(e)):fo(he,n.stateNode));break;case 4:r=he,i=tt,he=n.stateNode.containerInfo,tt=!0,Et(e,t,n),he=r,tt=i;break;case 0:case 11:case 14:case 15:if(!xe&&(r=n.updateQueue,r!==null&&(r=r.lastEffect,r!==null))){i=r=r.next;do{var s=i,o=s.destroy;s=s.tag,o!==void 0&&(s&2||s&4)&&ja(n,t,o),i=i.next}while(i!==r)}Et(e,t,n);break;case 1:if(!xe&&(An(n,t),r=n.stateNode,typeof r.componentWillUnmount=="function"))try{r.props=n.memoizedProps,r.state=n.memoizedState,r.componentWillUnmount()}catch(a){ne(n,t,a)}Et(e,t,n);break;case 21:Et(e,t,n);break;case 22:n.mode&1?(xe=(r=xe)||n.memoizedState!==null,Et(e,t,n),xe=r):Et(e,t,n);break;default:Et(e,t,n)}}function Dc(e){var t=e.updateQueue;if(t!==null){e.updateQueue=null;var n=e.stateNode;n===null&&(n=e.stateNode=new g1),t.forEach(function(r){var i=P1.bind(null,e,r);n.has(r)||(n.add(r),r.then(i,i))})}}function Ze(e,t){var n=t.deletions;if(n!==null)for(var r=0;ri&&(i=o),r&=~s}if(r=i,r=re()-r,r=(120>r?120:480>r?480:1080>r?1080:1920>r?1920:3e3>r?3e3:4320>r?4320:1960*x1(r/1960))-r,10e?16:e,Vt===null)var r=!1;else{if(e=Vt,Vt=null,ws=0,F&6)throw Error(N(331));var i=F;for(F|=4,M=e.current;M!==null;){var s=M,o=s.child;if(M.flags&16){var a=s.deletions;if(a!==null){for(var l=0;lre()-Ol?un(e,0):Fl|=n),Re(e,t)}function a0(e,t){t===0&&(e.mode&1?(t=wi,wi<<=1,!(wi&130023424)&&(wi=4194304)):t=1);var n=Pe();e=Ct(e,t),e!==null&&(ai(e,t,n),Re(e,n))}function T1(e){var t=e.memoizedState,n=0;t!==null&&(n=t.retryLane),a0(e,n)}function P1(e,t){var n=0;switch(e.tag){case 13:var r=e.stateNode,i=e.memoizedState;i!==null&&(n=i.retryLane);break;case 19:r=e.stateNode;break;default:throw Error(N(314))}r!==null&&r.delete(t),a0(e,n)}var l0;l0=function(e,t,n){if(e!==null)if(e.memoizedProps!==t.pendingProps||Le.current)De=!0;else{if(!(e.lanes&n)&&!(t.flags&128))return De=!1,h1(e,t,n);De=!!(e.flags&131072)}else De=!1,Y&&t.flags&1048576&&fh(t,ds,t.index);switch(t.lanes=0,t.tag){case 2:var r=t.type;Hi(e,t),e=t.pendingProps;var i=Yn(t,Se.current);Wn(t,n),i=Ll(null,t,r,e,i,n);var s=Al();return t.flags|=1,typeof i=="object"&&i!==null&&typeof i.render=="function"&&i.$$typeof===void 0?(t.tag=1,t.memoizedState=null,t.updateQueue=null,Ae(r)?(s=!0,us(t)):s=!1,t.memoizedState=i.state!==null&&i.state!==void 0?i.state:null,Nl(t),i.updater=_s,t.stateNode=i,i._reactInternals=t,ya(t,r,e,n),t=wa(null,t,r,!0,s,n)):(t.tag=0,Y&&s&&wl(t),je(null,t,i,n),t=t.child),t;case 16:r=t.elementType;e:{switch(Hi(e,t),e=t.pendingProps,i=r._init,r=i(r._payload),t.type=r,i=t.tag=E1(r),e=et(r,e),i){case 0:t=xa(null,t,r,e,n);break e;case 1:t=Tc(null,t,r,e,n);break e;case 11:t=Cc(null,t,r,e,n);break e;case 14:t=jc(null,t,r,et(r.type,e),n);break e}throw Error(N(306,r,""))}return t;case 0:return r=t.type,i=t.pendingProps,i=t.elementType===r?i:et(r,i),xa(e,t,r,i,n);case 1:return r=t.type,i=t.pendingProps,i=t.elementType===r?i:et(r,i),Tc(e,t,r,i,n);case 3:e:{if(Hh(t),e===null)throw Error(N(387));r=t.pendingProps,s=t.memoizedState,i=s.element,vh(e,t),ps(t,r,null,n);var o=t.memoizedState;if(r=o.element,s.isDehydrated)if(s={element:r,isDehydrated:!1,cache:o.cache,pendingSuspenseBoundaries:o.pendingSuspenseBoundaries,transitions:o.transitions},t.updateQueue.baseState=s,t.memoizedState=s,t.flags&256){i=qn(Error(N(423)),t),t=Pc(e,t,r,n,i);break e}else if(r!==i){i=qn(Error(N(424)),t),t=Pc(e,t,r,n,i);break e}else for(Ie=Ot(t.stateNode.containerInfo.firstChild),_e=t,Y=!0,nt=null,n=gh(t,null,r,n),t.child=n;n;)n.flags=n.flags&-3|4096,n=n.sibling;else{if(Qn(),r===i){t=jt(e,t,n);break e}je(e,t,r,n)}t=t.child}return t;case 5:return xh(t),e===null&&pa(t),r=t.type,i=t.pendingProps,s=e!==null?e.memoizedProps:null,o=i.children,ua(r,i)?o=null:s!==null&&ua(r,s)&&(t.flags|=32),Wh(e,t),je(e,t,o,n),t.child;case 6:return e===null&&pa(t),null;case 13:return Kh(e,t,n);case 4:return El(t,t.stateNode.containerInfo),r=t.pendingProps,e===null?t.child=Xn(t,null,r,n):je(e,t,r,n),t.child;case 11:return r=t.type,i=t.pendingProps,i=t.elementType===r?i:et(r,i),Cc(e,t,r,i,n);case 7:return je(e,t,t.pendingProps,n),t.child;case 8:return je(e,t,t.pendingProps.children,n),t.child;case 12:return je(e,t,t.pendingProps.children,n),t.child;case 10:e:{if(r=t.type._context,i=t.pendingProps,s=t.memoizedProps,o=i.value,$(fs,r._currentValue),r._currentValue=o,s!==null)if(st(s.value,o)){if(s.children===i.children&&!Le.current){t=jt(e,t,n);break e}}else for(s=t.child,s!==null&&(s.return=t);s!==null;){var a=s.dependencies;if(a!==null){o=s.child;for(var l=a.firstContext;l!==null;){if(l.context===r){if(s.tag===1){l=wt(-1,n&-n),l.tag=2;var u=s.updateQueue;if(u!==null){u=u.shared;var c=u.pending;c===null?l.next=l:(l.next=c.next,c.next=l),u.pending=l}}s.lanes|=n,l=s.alternate,l!==null&&(l.lanes|=n),ma(s.return,n,t),a.lanes|=n;break}l=l.next}}else if(s.tag===10)o=s.type===t.type?null:s.child;else if(s.tag===18){if(o=s.return,o===null)throw Error(N(341));o.lanes|=n,a=o.alternate,a!==null&&(a.lanes|=n),ma(o,n,t),o=s.sibling}else o=s.child;if(o!==null)o.return=s;else for(o=s;o!==null;){if(o===t){o=null;break}if(s=o.sibling,s!==null){s.return=o.return,o=s;break}o=o.return}s=o}je(e,t,i.children,n),t=t.child}return t;case 9:return i=t.type,r=t.pendingProps.children,Wn(t,n),i=Qe(i),r=r(i),t.flags|=1,je(e,t,r,n),t.child;case 14:return r=t.type,i=et(r,t.pendingProps),i=et(r.type,i),jc(e,t,r,i,n);case 15:return Uh(e,t,t.type,t.pendingProps,n);case 17:return r=t.type,i=t.pendingProps,i=t.elementType===r?i:et(r,i),Hi(e,t),t.tag=1,Ae(r)?(e=!0,us(t)):e=!1,Wn(t,n),Oh(t,r,i),ya(t,r,i,n),wa(null,t,r,!0,e,n);case 19:return Gh(e,t,n);case 22:return $h(e,t,n)}throw Error(N(156,t.tag))};function u0(e,t){return If(e,t)}function N1(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.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 He(e,t,n,r){return new N1(e,t,n,r)}function $l(e){return e=e.prototype,!(!e||!e.isReactComponent)}function E1(e){if(typeof e=="function")return $l(e)?1:0;if(e!=null){if(e=e.$$typeof,e===ll)return 11;if(e===ul)return 14}return 2}function $t(e,t){var n=e.alternate;return n===null?(n=He(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&14680064,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}function Yi(e,t,n,r,i,s){var o=2;if(r=e,typeof e=="function")$l(e)&&(o=1);else if(typeof e=="string")o=5;else e:switch(e){case jn:return cn(n.children,i,s,t);case al:o=8,i|=8;break;case zo:return e=He(12,n,t,i|2),e.elementType=zo,e.lanes=s,e;case Uo:return e=He(13,n,t,i),e.elementType=Uo,e.lanes=s,e;case $o:return e=He(19,n,t,i),e.elementType=$o,e.lanes=s,e;case xf:return Bs(n,i,s,t);default:if(typeof e=="object"&&e!==null)switch(e.$$typeof){case yf:o=10;break e;case vf:o=9;break e;case ll:o=11;break e;case ul:o=14;break e;case Dt:o=16,r=null;break e}throw Error(N(130,e==null?e:typeof e,""))}return t=He(o,n,t,i),t.elementType=e,t.type=r,t.lanes=s,t}function cn(e,t,n,r){return e=He(7,e,r,t),e.lanes=n,e}function Bs(e,t,n,r){return e=He(22,e,r,t),e.elementType=xf,e.lanes=n,e.stateNode={isHidden:!1},e}function wo(e,t,n){return e=He(6,e,null,t),e.lanes=n,e}function ko(e,t,n){return t=He(4,e.children!==null?e.children:[],e.key,t),t.lanes=n,t.stateNode={containerInfo:e.containerInfo,pendingChildren:null,implementation:e.implementation},t}function M1(e,t,n,r,i){this.tag=t,this.containerInfo=e,this.finishedWork=this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.pendingContext=this.context=null,this.callbackPriority=0,this.eventTimes=eo(0),this.expirationTimes=eo(-1),this.entangledLanes=this.finishedLanes=this.mutableReadLanes=this.expiredLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=eo(0),this.identifierPrefix=r,this.onRecoverableError=i,this.mutableSourceEagerHydrationData=null}function Wl(e,t,n,r,i,s,o,a,l){return e=new M1(e,t,n,a,l),t===1?(t=1,s===!0&&(t|=8)):t=0,s=He(3,null,null,t),e.current=s,s.stateNode=e,s.memoizedState={element:r,isDehydrated:n,cache:null,transitions:null,pendingSuspenseBoundaries:null},Nl(s),e}function D1(e,t,n){var r=3"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(h0)}catch(e){console.error(e)}}h0(),hf.exports=Oe;var V1=hf.exports,Fc=V1;Oo.createRoot=Fc.createRoot,Oo.hydrateRoot=Fc.hydrateRoot;const Yl=C.createContext({});function Ql(e){const t=C.useRef(null);return t.current===null&&(t.current=e()),t.current}const Xl=typeof window<"u",p0=Xl?C.useLayoutEffect:C.useEffect,Hs=C.createContext(null);function Zl(e,t){e.indexOf(t)===-1&&e.push(t)}function ql(e,t){const n=e.indexOf(t);n>-1&&e.splice(n,1)}const Tt=(e,t,n)=>n>t?t:n{};const Pt={},m0=e=>/^-?(?:\d+(?:\.\d+)?|\.\d+)$/u.test(e);function g0(e){return typeof e=="object"&&e!==null}const y0=e=>/^0[^.\s]+$/u.test(e);function eu(e){let t;return()=>(t===void 0&&(t=e()),t)}const Ye=e=>e,I1=(e,t)=>n=>t(e(n)),di=(...e)=>e.reduce(I1),ei=(e,t,n)=>{const r=t-e;return r===0?1:(n-e)/r};class tu{constructor(){this.subscriptions=[]}add(t){return Zl(this.subscriptions,t),()=>ql(this.subscriptions,t)}notify(t,n,r){const i=this.subscriptions.length;if(i)if(i===1)this.subscriptions[0](t,n,r);else for(let s=0;se*1e3,Ke=e=>e/1e3;function v0(e,t){return t?e*(1e3/t):0}const x0=(e,t,n)=>(((1-3*n+3*t)*e+(3*n-6*t))*e+3*t)*e,_1=1e-7,F1=12;function O1(e,t,n,r,i){let s,o,a=0;do o=t+(n-t)/2,s=x0(o,r,i)-e,s>0?n=o:t=o;while(Math.abs(s)>_1&&++aO1(s,0,1,e,n);return s=>s===0||s===1?s:x0(i(s),t,r)}const w0=e=>t=>t<=.5?e(2*t)/2:(2-e(2*(1-t)))/2,k0=e=>t=>1-e(1-t),S0=fi(.33,1.53,.69,.99),nu=k0(S0),C0=w0(nu),j0=e=>(e*=2)<1?.5*nu(e):.5*(2-Math.pow(2,-10*(e-1))),ru=e=>1-Math.sin(Math.acos(e)),T0=k0(ru),P0=w0(ru),B1=fi(.42,0,1,1),z1=fi(0,0,.58,1),N0=fi(.42,0,.58,1),U1=e=>Array.isArray(e)&&typeof e[0]!="number",E0=e=>Array.isArray(e)&&typeof e[0]=="number",$1={linear:Ye,easeIn:B1,easeInOut:N0,easeOut:z1,circIn:ru,circInOut:P0,circOut:T0,backIn:nu,backInOut:C0,backOut:S0,anticipate:j0},W1=e=>typeof e=="string",Oc=e=>{if(E0(e)){Jl(e.length===4);const[t,n,r,i]=e;return fi(t,n,r,i)}else if(W1(e))return $1[e];return e},Li=["setup","read","resolveKeyframes","preUpdate","update","preRender","render","postRender"];function H1(e,t){let n=new Set,r=new Set,i=!1,s=!1;const o=new WeakSet;let a={delta:0,timestamp:0,isProcessing:!1};function l(c){o.has(c)&&(u.schedule(c),e()),c(a)}const u={schedule:(c,h=!1,f=!1)=>{const v=f&&i?n:r;return h&&o.add(c),v.has(c)||v.add(c),c},cancel:c=>{r.delete(c),o.delete(c)},process:c=>{if(a=c,i){s=!0;return}i=!0,[n,r]=[r,n],n.forEach(l),n.clear(),i=!1,s&&(s=!1,u.process(c))}};return u}const K1=40;function M0(e,t){let n=!1,r=!0;const i={delta:0,timestamp:0,isProcessing:!1},s=()=>n=!0,o=Li.reduce((g,k)=>(g[k]=H1(s),g),{}),{setup:a,read:l,resolveKeyframes:u,preUpdate:c,update:h,preRender:f,render:y,postRender:v}=o,x=()=>{const g=Pt.useManualTiming?i.timestamp:performance.now();n=!1,Pt.useManualTiming||(i.delta=r?1e3/60:Math.max(Math.min(g-i.timestamp,K1),1)),i.timestamp=g,i.isProcessing=!0,a.process(i),l.process(i),u.process(i),c.process(i),h.process(i),f.process(i),y.process(i),v.process(i),i.isProcessing=!1,n&&t&&(r=!1,e(x))},P=()=>{n=!0,r=!0,i.isProcessing||e(x)};return{schedule:Li.reduce((g,k)=>{const S=o[k];return g[k]=(T,w=!1,j=!1)=>(n||P(),S.schedule(T,w,j)),g},{}),cancel:g=>{for(let k=0;k(Qi===void 0&&be.set(pe.isProcessing||Pt.useManualTiming?pe.timestamp:performance.now()),Qi),set:e=>{Qi=e,queueMicrotask(G1)}},D0=e=>t=>typeof t=="string"&&t.startsWith(e),iu=D0("--"),Y1=D0("var(--"),su=e=>Y1(e)?Q1.test(e.split("/*")[0].trim()):!1,Q1=/var\(--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)$/iu,sr={test:e=>typeof e=="number",parse:parseFloat,transform:e=>e},ti={...sr,transform:e=>Tt(0,1,e)},Ai={...sr,default:1},Ar=e=>Math.round(e*1e5)/1e5,ou=/-?(?:\d+(?:\.\d+)?|\.\d+)/gu;function X1(e){return e==null}const Z1=/^(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))$/iu,au=(e,t)=>n=>!!(typeof n=="string"&&Z1.test(n)&&n.startsWith(e)||t&&!X1(n)&&Object.prototype.hasOwnProperty.call(n,t)),b0=(e,t,n)=>r=>{if(typeof r!="string")return r;const[i,s,o,a]=r.match(ou);return{[e]:parseFloat(i),[t]:parseFloat(s),[n]:parseFloat(o),alpha:a!==void 0?parseFloat(a):1}},q1=e=>Tt(0,255,e),Co={...sr,transform:e=>Math.round(q1(e))},an={test:au("rgb","red"),parse:b0("red","green","blue"),transform:({red:e,green:t,blue:n,alpha:r=1})=>"rgba("+Co.transform(e)+", "+Co.transform(t)+", "+Co.transform(n)+", "+Ar(ti.transform(r))+")"};function J1(e){let t="",n="",r="",i="";return e.length>5?(t=e.substring(1,3),n=e.substring(3,5),r=e.substring(5,7),i=e.substring(7,9)):(t=e.substring(1,2),n=e.substring(2,3),r=e.substring(3,4),i=e.substring(4,5),t+=t,n+=n,r+=r,i+=i),{red:parseInt(t,16),green:parseInt(n,16),blue:parseInt(r,16),alpha:i?parseInt(i,16)/255:1}}const La={test:au("#"),parse:J1,transform:an.transform},hi=e=>({test:t=>typeof t=="string"&&t.endsWith(e)&&t.split(" ").length===1,parse:parseFloat,transform:t=>`${t}${e}`}),Mt=hi("deg"),ft=hi("%"),A=hi("px"),ey=hi("vh"),ty=hi("vw"),Bc={...ft,parse:e=>ft.parse(e)/100,transform:e=>ft.transform(e*100)},Vn={test:au("hsl","hue"),parse:b0("hue","saturation","lightness"),transform:({hue:e,saturation:t,lightness:n,alpha:r=1})=>"hsla("+Math.round(e)+", "+ft.transform(Ar(t))+", "+ft.transform(Ar(n))+", "+Ar(ti.transform(r))+")"},se={test:e=>an.test(e)||La.test(e)||Vn.test(e),parse:e=>an.test(e)?an.parse(e):Vn.test(e)?Vn.parse(e):La.parse(e),transform:e=>typeof e=="string"?e:e.hasOwnProperty("red")?an.transform(e):Vn.transform(e),getAnimatableNone:e=>{const t=se.parse(e);return t.alpha=0,se.transform(t)}},ny=/(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))/giu;function ry(e){var t,n;return isNaN(e)&&typeof e=="string"&&(((t=e.match(ou))==null?void 0:t.length)||0)+(((n=e.match(ny))==null?void 0:n.length)||0)>0}const L0="number",A0="color",iy="var",sy="var(",zc="${}",oy=/var\s*\(\s*--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)|#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\)|-?(?:\d+(?:\.\d+)?|\.\d+)/giu;function ni(e){const t=e.toString(),n=[],r={color:[],number:[],var:[]},i=[];let s=0;const a=t.replace(oy,l=>(se.test(l)?(r.color.push(s),i.push(A0),n.push(se.parse(l))):l.startsWith(sy)?(r.var.push(s),i.push(iy),n.push(l)):(r.number.push(s),i.push(L0),n.push(parseFloat(l))),++s,zc)).split(zc);return{values:n,split:a,indexes:r,types:i}}function R0(e){return ni(e).values}function V0(e){const{split:t,types:n}=ni(e),r=t.length;return i=>{let s="";for(let o=0;otypeof e=="number"?0:se.test(e)?se.getAnimatableNone(e):e;function ly(e){const t=R0(e);return V0(e)(t.map(ay))}const Gt={test:ry,parse:R0,createTransformer:V0,getAnimatableNone:ly};function jo(e,t,n){return n<0&&(n+=1),n>1&&(n-=1),n<1/6?e+(t-e)*6*n:n<1/2?t:n<2/3?e+(t-e)*(2/3-n)*6:e}function uy({hue:e,saturation:t,lightness:n,alpha:r}){e/=360,t/=100,n/=100;let i=0,s=0,o=0;if(!t)i=s=o=n;else{const a=n<.5?n*(1+t):n+t-n*t,l=2*n-a;i=jo(l,a,e+1/3),s=jo(l,a,e),o=jo(l,a,e-1/3)}return{red:Math.round(i*255),green:Math.round(s*255),blue:Math.round(o*255),alpha:r}}function Cs(e,t){return n=>n>0?t:e}const q=(e,t,n)=>e+(t-e)*n,To=(e,t,n)=>{const r=e*e,i=n*(t*t-r)+r;return i<0?0:Math.sqrt(i)},cy=[La,an,Vn],dy=e=>cy.find(t=>t.test(e));function Uc(e){const t=dy(e);if(!t)return!1;let n=t.parse(e);return t===Vn&&(n=uy(n)),n}const $c=(e,t)=>{const n=Uc(e),r=Uc(t);if(!n||!r)return Cs(e,t);const i={...n};return s=>(i.red=To(n.red,r.red,s),i.green=To(n.green,r.green,s),i.blue=To(n.blue,r.blue,s),i.alpha=q(n.alpha,r.alpha,s),an.transform(i))},Aa=new Set(["none","hidden"]);function fy(e,t){return Aa.has(e)?n=>n<=0?e:t:n=>n>=1?t:e}function hy(e,t){return n=>q(e,t,n)}function lu(e){return typeof e=="number"?hy:typeof e=="string"?su(e)?Cs:se.test(e)?$c:gy:Array.isArray(e)?I0:typeof e=="object"?se.test(e)?$c:py:Cs}function I0(e,t){const n=[...e],r=n.length,i=e.map((s,o)=>lu(s)(s,t[o]));return s=>{for(let o=0;o{for(const s in r)n[s]=r[s](i);return n}}function my(e,t){const n=[],r={color:0,var:0,number:0};for(let i=0;i{const n=Gt.createTransformer(t),r=ni(e),i=ni(t);return r.indexes.var.length===i.indexes.var.length&&r.indexes.color.length===i.indexes.color.length&&r.indexes.number.length>=i.indexes.number.length?Aa.has(e)&&!i.values.length||Aa.has(t)&&!r.values.length?fy(e,t):di(I0(my(r,i),i.values),n):Cs(e,t)};function _0(e,t,n){return typeof e=="number"&&typeof t=="number"&&typeof n=="number"?q(e,t,n):lu(e)(e,t)}const yy=e=>{const t=({timestamp:n})=>e(n);return{start:(n=!0)=>Q.update(t,n),stop:()=>Kt(t),now:()=>pe.isProcessing?pe.timestamp:be.now()}},F0=(e,t,n=10)=>{let r="";const i=Math.max(Math.round(t/n),2);for(let s=0;s=js?1/0:t}function vy(e,t=100,n){const r=n({...e,keyframes:[0,t]}),i=Math.min(uu(r),js);return{type:"keyframes",ease:s=>r.next(i*s).value/t,duration:Ke(i)}}const xy=5;function O0(e,t,n){const r=Math.max(t-xy,0);return v0(n-e(r),t-r)}const te={stiffness:100,damping:10,mass:1,velocity:0,duration:800,bounce:.3,visualDuration:.3,restSpeed:{granular:.01,default:2},restDelta:{granular:.005,default:.5},minDuration:.01,maxDuration:10,minDamping:.05,maxDamping:1},Po=.001;function wy({duration:e=te.duration,bounce:t=te.bounce,velocity:n=te.velocity,mass:r=te.mass}){let i,s,o=1-t;o=Tt(te.minDamping,te.maxDamping,o),e=Tt(te.minDuration,te.maxDuration,Ke(e)),o<1?(i=u=>{const c=u*o,h=c*e,f=c-n,y=Ra(u,o),v=Math.exp(-h);return Po-f/y*v},s=u=>{const h=u*o*e,f=h*n+n,y=Math.pow(o,2)*Math.pow(u,2)*e,v=Math.exp(-h),x=Ra(Math.pow(u,2),o);return(-i(u)+Po>0?-1:1)*((f-y)*v)/x}):(i=u=>{const c=Math.exp(-u*e),h=(u-n)*e+1;return-Po+c*h},s=u=>{const c=Math.exp(-u*e),h=(n-u)*(e*e);return c*h});const a=5/e,l=Sy(i,s,a);if(e=dt(e),isNaN(l))return{stiffness:te.stiffness,damping:te.damping,duration:e};{const u=Math.pow(l,2)*r;return{stiffness:u,damping:o*2*Math.sqrt(r*u),duration:e}}}const ky=12;function Sy(e,t,n){let r=n;for(let i=1;ie[n]!==void 0)}function Ty(e){let t={velocity:te.velocity,stiffness:te.stiffness,damping:te.damping,mass:te.mass,isResolvedFromDuration:!1,...e};if(!Wc(e,jy)&&Wc(e,Cy))if(e.visualDuration){const n=e.visualDuration,r=2*Math.PI/(n*1.2),i=r*r,s=2*Tt(.05,1,1-(e.bounce||0))*Math.sqrt(i);t={...t,mass:te.mass,stiffness:i,damping:s}}else{const n=wy(e);t={...t,...n,mass:te.mass},t.isResolvedFromDuration=!0}return t}function Ts(e=te.visualDuration,t=te.bounce){const n=typeof e!="object"?{visualDuration:e,keyframes:[0,1],bounce:t}:e;let{restSpeed:r,restDelta:i}=n;const s=n.keyframes[0],o=n.keyframes[n.keyframes.length-1],a={done:!1,value:s},{stiffness:l,damping:u,mass:c,duration:h,velocity:f,isResolvedFromDuration:y}=Ty({...n,velocity:-Ke(n.velocity||0)}),v=f||0,x=u/(2*Math.sqrt(l*c)),P=o-s,m=Ke(Math.sqrt(l/c)),p=Math.abs(P)<5;r||(r=p?te.restSpeed.granular:te.restSpeed.default),i||(i=p?te.restDelta.granular:te.restDelta.default);let g;if(x<1){const S=Ra(m,x);g=T=>{const w=Math.exp(-x*m*T);return o-w*((v+x*m*P)/S*Math.sin(S*T)+P*Math.cos(S*T))}}else if(x===1)g=S=>o-Math.exp(-m*S)*(P+(v+m*P)*S);else{const S=m*Math.sqrt(x*x-1);g=T=>{const w=Math.exp(-x*m*T),j=Math.min(S*T,300);return o-w*((v+x*m*P)*Math.sinh(j)+S*P*Math.cosh(j))/S}}const k={calculatedDuration:y&&h||null,next:S=>{const T=g(S);if(y)a.done=S>=h;else{let w=S===0?v:0;x<1&&(w=S===0?dt(v):O0(g,S,T));const j=Math.abs(w)<=r,V=Math.abs(o-T)<=i;a.done=j&&V}return a.value=a.done?o:T,a},toString:()=>{const S=Math.min(uu(k),js),T=F0(w=>k.next(S*w).value,S,30);return S+"ms "+T},toTransition:()=>{}};return k}Ts.applyToOptions=e=>{const t=vy(e,100,Ts);return e.ease=t.ease,e.duration=dt(t.duration),e.type="keyframes",e};function Va({keyframes:e,velocity:t=0,power:n=.8,timeConstant:r=325,bounceDamping:i=10,bounceStiffness:s=500,modifyTarget:o,min:a,max:l,restDelta:u=.5,restSpeed:c}){const h=e[0],f={done:!1,value:h},y=j=>a!==void 0&&jl,v=j=>a===void 0?l:l===void 0||Math.abs(a-j)-x*Math.exp(-j/r),g=j=>m+p(j),k=j=>{const V=p(j),D=g(j);f.done=Math.abs(V)<=u,f.value=f.done?m:D};let S,T;const w=j=>{y(f.value)&&(S=j,T=Ts({keyframes:[f.value,v(f.value)],velocity:O0(g,j,f.value),damping:i,stiffness:s,restDelta:u,restSpeed:c}))};return w(0),{calculatedDuration:null,next:j=>{let V=!1;return!T&&S===void 0&&(V=!0,k(j),w(j)),S!==void 0&&j>=S?T.next(j-S):(!V&&k(j),f)}}}function Py(e,t,n){const r=[],i=n||Pt.mix||_0,s=e.length-1;for(let o=0;ot[0];if(s===2&&t[0]===t[1])return()=>t[1];const o=e[0]===e[1];e[0]>e[s-1]&&(e=[...e].reverse(),t=[...t].reverse());const a=Py(t,r,i),l=a.length,u=c=>{if(o&&c1)for(;hu(Tt(e[0],e[s-1],c)):u}function Ey(e,t){const n=e[e.length-1];for(let r=1;r<=t;r++){const i=ei(0,t,r);e.push(q(n,1,i))}}function My(e){const t=[0];return Ey(t,e.length-1),t}function Dy(e,t){return e.map(n=>n*t)}function by(e,t){return e.map(()=>t||N0).splice(0,e.length-1)}function Rr({duration:e=300,keyframes:t,times:n,ease:r="easeInOut"}){const i=U1(r)?r.map(Oc):Oc(r),s={done:!1,value:t[0]},o=Dy(n&&n.length===t.length?n:My(t),e),a=Ny(o,t,{ease:Array.isArray(i)?i:by(t,i)});return{calculatedDuration:e,next:l=>(s.value=a(l),s.done=l>=e,s)}}const Ly=e=>e!==null;function cu(e,{repeat:t,repeatType:n="loop"},r,i=1){const s=e.filter(Ly),a=i<0||t&&n!=="loop"&&t%2===1?0:s.length-1;return!a||r===void 0?s[a]:r}const Ay={decay:Va,inertia:Va,tween:Rr,keyframes:Rr,spring:Ts};function B0(e){typeof e.type=="string"&&(e.type=Ay[e.type])}class du{constructor(){this.updateFinished()}get finished(){return this._finished}updateFinished(){this._finished=new Promise(t=>{this.resolve=t})}notifyFinished(){this.resolve()}then(t,n){return this.finished.then(t,n)}}const Ry=e=>e/100;class fu extends du{constructor(t){super(),this.state="idle",this.startTime=null,this.isStopped=!1,this.currentTime=0,this.holdTime=null,this.playbackSpeed=1,this.stop=()=>{var r,i;const{motionValue:n}=this.options;n&&n.updatedAt!==be.now()&&this.tick(be.now()),this.isStopped=!0,this.state!=="idle"&&(this.teardown(),(i=(r=this.options).onStop)==null||i.call(r))},this.options=t,this.initAnimation(),this.play(),t.autoplay===!1&&this.pause()}initAnimation(){const{options:t}=this;B0(t);const{type:n=Rr,repeat:r=0,repeatDelay:i=0,repeatType:s,velocity:o=0}=t;let{keyframes:a}=t;const l=n||Rr;l!==Rr&&typeof a[0]!="number"&&(this.mixKeyframes=di(Ry,_0(a[0],a[1])),a=[0,100]);const u=l({...t,keyframes:a});s==="mirror"&&(this.mirroredGenerator=l({...t,keyframes:[...a].reverse(),velocity:-o})),u.calculatedDuration===null&&(u.calculatedDuration=uu(u));const{calculatedDuration:c}=u;this.calculatedDuration=c,this.resolvedDuration=c+i,this.totalDuration=this.resolvedDuration*(r+1)-i,this.generator=u}updateTime(t){const n=Math.round(t-this.startTime)*this.playbackSpeed;this.holdTime!==null?this.currentTime=this.holdTime:this.currentTime=n}tick(t,n=!1){const{generator:r,totalDuration:i,mixKeyframes:s,mirroredGenerator:o,resolvedDuration:a,calculatedDuration:l}=this;if(this.startTime===null)return r.next(0);const{delay:u=0,keyframes:c,repeat:h,repeatType:f,repeatDelay:y,type:v,onUpdate:x,finalKeyframe:P}=this.options;this.speed>0?this.startTime=Math.min(this.startTime,t):this.speed<0&&(this.startTime=Math.min(t-i/this.speed,this.startTime)),n?this.currentTime=t:this.updateTime(t);const m=this.currentTime-u*(this.playbackSpeed>=0?1:-1),p=this.playbackSpeed>=0?m<0:m>i;this.currentTime=Math.max(m,0),this.state==="finished"&&this.holdTime===null&&(this.currentTime=i);let g=this.currentTime,k=r;if(h){const j=Math.min(this.currentTime,i)/a;let V=Math.floor(j),D=j%1;!D&&j>=1&&(D=1),D===1&&V--,V=Math.min(V,h+1),!!(V%2)&&(f==="reverse"?(D=1-D,y&&(D-=y/a)):f==="mirror"&&(k=o)),g=Tt(0,1,D)*a}const S=p?{done:!1,value:c[0]}:k.next(g);s&&(S.value=s(S.value));let{done:T}=S;!p&&l!==null&&(T=this.playbackSpeed>=0?this.currentTime>=i:this.currentTime<=0);const w=this.holdTime===null&&(this.state==="finished"||this.state==="running"&&T);return w&&v!==Va&&(S.value=cu(c,this.options,P,this.speed)),x&&x(S.value),w&&this.finish(),S}then(t,n){return this.finished.then(t,n)}get duration(){return Ke(this.calculatedDuration)}get iterationDuration(){const{delay:t=0}=this.options||{};return this.duration+Ke(t)}get time(){return Ke(this.currentTime)}set time(t){var n;t=dt(t),this.currentTime=t,this.startTime===null||this.holdTime!==null||this.playbackSpeed===0?this.holdTime=t:this.driver&&(this.startTime=this.driver.now()-t/this.playbackSpeed),(n=this.driver)==null||n.start(!1)}get speed(){return this.playbackSpeed}set speed(t){this.updateTime(be.now());const n=this.playbackSpeed!==t;this.playbackSpeed=t,n&&(this.time=Ke(this.currentTime))}play(){var i,s;if(this.isStopped)return;const{driver:t=yy,startTime:n}=this.options;this.driver||(this.driver=t(o=>this.tick(o))),(s=(i=this.options).onPlay)==null||s.call(i);const r=this.driver.now();this.state==="finished"?(this.updateFinished(),this.startTime=r):this.holdTime!==null?this.startTime=r-this.holdTime:this.startTime||(this.startTime=n??r),this.state==="finished"&&this.speed<0&&(this.startTime+=this.calculatedDuration),this.holdTime=null,this.state="running",this.driver.start()}pause(){this.state="paused",this.updateTime(be.now()),this.holdTime=this.currentTime}complete(){this.state!=="running"&&this.play(),this.state="finished",this.holdTime=null}finish(){var t,n;this.notifyFinished(),this.teardown(),this.state="finished",(n=(t=this.options).onComplete)==null||n.call(t)}cancel(){var t,n;this.holdTime=null,this.startTime=0,this.tick(0),this.teardown(),(n=(t=this.options).onCancel)==null||n.call(t)}teardown(){this.state="idle",this.stopDriver(),this.startTime=this.holdTime=null}stopDriver(){this.driver&&(this.driver.stop(),this.driver=void 0)}sample(t){return this.startTime=0,this.tick(t,!0)}attachTimeline(t){var n;return this.options.allowFlatten&&(this.options.type="keyframes",this.options.ease="linear",this.initAnimation()),(n=this.driver)==null||n.stop(),t.observe(this)}}function Vy(e){for(let t=1;te*180/Math.PI,Ia=e=>{const t=ln(Math.atan2(e[1],e[0]));return _a(t)},Iy={x:4,y:5,translateX:4,translateY:5,scaleX:0,scaleY:3,scale:e=>(Math.abs(e[0])+Math.abs(e[3]))/2,rotate:Ia,rotateZ:Ia,skewX:e=>ln(Math.atan(e[1])),skewY:e=>ln(Math.atan(e[2])),skew:e=>(Math.abs(e[1])+Math.abs(e[2]))/2},_a=e=>(e=e%360,e<0&&(e+=360),e),Hc=Ia,Kc=e=>Math.sqrt(e[0]*e[0]+e[1]*e[1]),Gc=e=>Math.sqrt(e[4]*e[4]+e[5]*e[5]),_y={x:12,y:13,z:14,translateX:12,translateY:13,translateZ:14,scaleX:Kc,scaleY:Gc,scale:e=>(Kc(e)+Gc(e))/2,rotateX:e=>_a(ln(Math.atan2(e[6],e[5]))),rotateY:e=>_a(ln(Math.atan2(-e[2],e[0]))),rotateZ:Hc,rotate:Hc,skewX:e=>ln(Math.atan(e[4])),skewY:e=>ln(Math.atan(e[1])),skew:e=>(Math.abs(e[1])+Math.abs(e[4]))/2};function Fa(e){return e.includes("scale")?1:0}function Oa(e,t){if(!e||e==="none")return Fa(t);const n=e.match(/^matrix3d\(([-\d.e\s,]+)\)$/u);let r,i;if(n)r=_y,i=n;else{const a=e.match(/^matrix\(([-\d.e\s,]+)\)$/u);r=Iy,i=a}if(!i)return Fa(t);const s=r[t],o=i[1].split(",").map(Oy);return typeof s=="function"?s(o):o[s]}const Fy=(e,t)=>{const{transform:n="none"}=getComputedStyle(e);return Oa(n,t)};function Oy(e){return parseFloat(e.trim())}const or=["transformPerspective","x","y","z","translateX","translateY","translateZ","scale","scaleX","scaleY","rotate","rotateX","rotateY","rotateZ","skew","skewX","skewY"],ar=new Set(or),Yc=e=>e===sr||e===A,By=new Set(["x","y","z"]),zy=or.filter(e=>!By.has(e));function Uy(e){const t=[];return zy.forEach(n=>{const r=e.getValue(n);r!==void 0&&(t.push([n,r.get()]),r.set(n.startsWith("scale")?1:0))}),t}const dn={width:({x:e},{paddingLeft:t="0",paddingRight:n="0"})=>e.max-e.min-parseFloat(t)-parseFloat(n),height:({y:e},{paddingTop:t="0",paddingBottom:n="0"})=>e.max-e.min-parseFloat(t)-parseFloat(n),top:(e,{top:t})=>parseFloat(t),left:(e,{left:t})=>parseFloat(t),bottom:({y:e},{top:t})=>parseFloat(t)+(e.max-e.min),right:({x:e},{left:t})=>parseFloat(t)+(e.max-e.min),x:(e,{transform:t})=>Oa(t,"x"),y:(e,{transform:t})=>Oa(t,"y")};dn.translateX=dn.x;dn.translateY=dn.y;const fn=new Set;let Ba=!1,za=!1,Ua=!1;function z0(){if(za){const e=Array.from(fn).filter(r=>r.needsMeasurement),t=new Set(e.map(r=>r.element)),n=new Map;t.forEach(r=>{const i=Uy(r);i.length&&(n.set(r,i),r.render())}),e.forEach(r=>r.measureInitialState()),t.forEach(r=>{r.render();const i=n.get(r);i&&i.forEach(([s,o])=>{var a;(a=r.getValue(s))==null||a.set(o)})}),e.forEach(r=>r.measureEndState()),e.forEach(r=>{r.suspendedScrollY!==void 0&&window.scrollTo(0,r.suspendedScrollY)})}za=!1,Ba=!1,fn.forEach(e=>e.complete(Ua)),fn.clear()}function U0(){fn.forEach(e=>{e.readKeyframes(),e.needsMeasurement&&(za=!0)})}function $y(){Ua=!0,U0(),z0(),Ua=!1}class hu{constructor(t,n,r,i,s,o=!1){this.state="pending",this.isAsync=!1,this.needsMeasurement=!1,this.unresolvedKeyframes=[...t],this.onComplete=n,this.name=r,this.motionValue=i,this.element=s,this.isAsync=o}scheduleResolve(){this.state="scheduled",this.isAsync?(fn.add(this),Ba||(Ba=!0,Q.read(U0),Q.resolveKeyframes(z0))):(this.readKeyframes(),this.complete())}readKeyframes(){const{unresolvedKeyframes:t,name:n,element:r,motionValue:i}=this;if(t[0]===null){const s=i==null?void 0:i.get(),o=t[t.length-1];if(s!==void 0)t[0]=s;else if(r&&n){const a=r.readValue(n,o);a!=null&&(t[0]=a)}t[0]===void 0&&(t[0]=o),i&&s===void 0&&i.set(t[0])}Vy(t)}setFinalKeyframe(){}measureInitialState(){}renderEndStyles(){}measureEndState(){}complete(t=!1){this.state="complete",this.onComplete(this.unresolvedKeyframes,this.finalKeyframe,t),fn.delete(this)}cancel(){this.state==="scheduled"&&(fn.delete(this),this.state="pending")}resume(){this.state==="pending"&&this.scheduleResolve()}}const Wy=e=>e.startsWith("--");function Hy(e,t,n){Wy(t)?e.style.setProperty(t,n):e.style[t]=n}const Ky=eu(()=>window.ScrollTimeline!==void 0),Gy={};function Yy(e,t){const n=eu(e);return()=>Gy[t]??n()}const $0=Yy(()=>{try{document.createElement("div").animate({opacity:0},{easing:"linear(0, 1)"})}catch{return!1}return!0},"linearEasing"),Cr=([e,t,n,r])=>`cubic-bezier(${e}, ${t}, ${n}, ${r})`,Qc={linear:"linear",ease:"ease",easeIn:"ease-in",easeOut:"ease-out",easeInOut:"ease-in-out",circIn:Cr([0,.65,.55,1]),circOut:Cr([.55,0,1,.45]),backIn:Cr([.31,.01,.66,-.59]),backOut:Cr([.33,1.53,.69,.99])};function W0(e,t){if(e)return typeof e=="function"?$0()?F0(e,t):"ease-out":E0(e)?Cr(e):Array.isArray(e)?e.map(n=>W0(n,t)||Qc.easeOut):Qc[e]}function Qy(e,t,n,{delay:r=0,duration:i=300,repeat:s=0,repeatType:o="loop",ease:a="easeOut",times:l}={},u=void 0){const c={[t]:n};l&&(c.offset=l);const h=W0(a,i);Array.isArray(h)&&(c.easing=h);const f={delay:r,duration:i,easing:Array.isArray(h)?"linear":h,fill:"both",iterations:s+1,direction:o==="reverse"?"alternate":"normal"};return u&&(f.pseudoElement=u),e.animate(c,f)}function H0(e){return typeof e=="function"&&"applyToOptions"in e}function Xy({type:e,...t}){return H0(e)&&$0()?e.applyToOptions(t):(t.duration??(t.duration=300),t.ease??(t.ease="easeOut"),t)}class Zy extends du{constructor(t){if(super(),this.finishedTime=null,this.isStopped=!1,!t)return;const{element:n,name:r,keyframes:i,pseudoElement:s,allowFlatten:o=!1,finalKeyframe:a,onComplete:l}=t;this.isPseudoElement=!!s,this.allowFlatten=o,this.options=t,Jl(typeof t.type!="string");const u=Xy(t);this.animation=Qy(n,r,i,u,s),u.autoplay===!1&&this.animation.pause(),this.animation.onfinish=()=>{if(this.finishedTime=this.time,!s){const c=cu(i,this.options,a,this.speed);this.updateMotionValue?this.updateMotionValue(c):Hy(n,r,c),this.animation.cancel()}l==null||l(),this.notifyFinished()}}play(){this.isStopped||(this.animation.play(),this.state==="finished"&&this.updateFinished())}pause(){this.animation.pause()}complete(){var t,n;(n=(t=this.animation).finish)==null||n.call(t)}cancel(){try{this.animation.cancel()}catch{}}stop(){if(this.isStopped)return;this.isStopped=!0;const{state:t}=this;t==="idle"||t==="finished"||(this.updateMotionValue?this.updateMotionValue():this.commitStyles(),this.isPseudoElement||this.cancel())}commitStyles(){var t,n;this.isPseudoElement||(n=(t=this.animation).commitStyles)==null||n.call(t)}get duration(){var n,r;const t=((r=(n=this.animation.effect)==null?void 0:n.getComputedTiming)==null?void 0:r.call(n).duration)||0;return Ke(Number(t))}get iterationDuration(){const{delay:t=0}=this.options||{};return this.duration+Ke(t)}get time(){return Ke(Number(this.animation.currentTime)||0)}set time(t){this.finishedTime=null,this.animation.currentTime=dt(t)}get speed(){return this.animation.playbackRate}set speed(t){t<0&&(this.finishedTime=null),this.animation.playbackRate=t}get state(){return this.finishedTime!==null?"finished":this.animation.playState}get startTime(){return Number(this.animation.startTime)}set startTime(t){this.animation.startTime=t}attachTimeline({timeline:t,observe:n}){var r;return this.allowFlatten&&((r=this.animation.effect)==null||r.updateTiming({easing:"linear"})),this.animation.onfinish=null,t&&Ky()?(this.animation.timeline=t,Ye):n(this)}}const K0={anticipate:j0,backInOut:C0,circInOut:P0};function qy(e){return e in K0}function Jy(e){typeof e.ease=="string"&&qy(e.ease)&&(e.ease=K0[e.ease])}const Xc=10;class ev extends Zy{constructor(t){Jy(t),B0(t),super(t),t.startTime&&(this.startTime=t.startTime),this.options=t}updateMotionValue(t){const{motionValue:n,onUpdate:r,onComplete:i,element:s,...o}=this.options;if(!n)return;if(t!==void 0){n.set(t);return}const a=new fu({...o,autoplay:!1}),l=dt(this.finishedTime??this.time);n.setWithVelocity(a.sample(l-Xc).value,a.sample(l).value,Xc),a.stop()}}const Zc=(e,t)=>t==="zIndex"?!1:!!(typeof e=="number"||Array.isArray(e)||typeof e=="string"&&(Gt.test(e)||e==="0")&&!e.startsWith("url("));function tv(e){const t=e[0];if(e.length===1)return!0;for(let n=0;nObject.hasOwnProperty.call(Element.prototype,"animate"));function sv(e){var c;const{motionValue:t,name:n,repeatDelay:r,repeatType:i,damping:s,type:o}=e;if(!(((c=t==null?void 0:t.owner)==null?void 0:c.current)instanceof HTMLElement))return!1;const{onUpdate:l,transformTemplate:u}=t.owner.getProps();return iv()&&n&&rv.has(n)&&(n!=="transform"||!u)&&!l&&!r&&i!=="mirror"&&s!==0&&o!=="inertia"}const ov=40;class av extends du{constructor({autoplay:t=!0,delay:n=0,type:r="keyframes",repeat:i=0,repeatDelay:s=0,repeatType:o="loop",keyframes:a,name:l,motionValue:u,element:c,...h}){var v;super(),this.stop=()=>{var x,P;this._animation&&(this._animation.stop(),(x=this.stopTimeline)==null||x.call(this)),(P=this.keyframeResolver)==null||P.cancel()},this.createdAt=be.now();const f={autoplay:t,delay:n,type:r,repeat:i,repeatDelay:s,repeatType:o,name:l,motionValue:u,element:c,...h},y=(c==null?void 0:c.KeyframeResolver)||hu;this.keyframeResolver=new y(a,(x,P,m)=>this.onKeyframesResolved(x,P,f,!m),l,u,c),(v=this.keyframeResolver)==null||v.scheduleResolve()}onKeyframesResolved(t,n,r,i){this.keyframeResolver=void 0;const{name:s,type:o,velocity:a,delay:l,isHandoff:u,onUpdate:c}=r;this.resolvedAt=be.now(),nv(t,s,o,a)||((Pt.instantAnimations||!l)&&(c==null||c(cu(t,r,n))),t[0]=t[t.length-1],$a(r),r.repeat=0);const f={startTime:i?this.resolvedAt?this.resolvedAt-this.createdAt>ov?this.resolvedAt:this.createdAt:this.createdAt:void 0,finalKeyframe:n,...r,keyframes:t},y=!u&&sv(f)?new ev({...f,element:f.motionValue.owner.current}):new fu(f);y.finished.then(()=>this.notifyFinished()).catch(Ye),this.pendingTimeline&&(this.stopTimeline=y.attachTimeline(this.pendingTimeline),this.pendingTimeline=void 0),this._animation=y}get finished(){return this._animation?this.animation.finished:this._finished}then(t,n){return this.finished.finally(t).then(()=>{})}get animation(){var t;return this._animation||((t=this.keyframeResolver)==null||t.resume(),$y()),this._animation}get duration(){return this.animation.duration}get iterationDuration(){return this.animation.iterationDuration}get time(){return this.animation.time}set time(t){this.animation.time=t}get speed(){return this.animation.speed}get state(){return this.animation.state}set speed(t){this.animation.speed=t}get startTime(){return this.animation.startTime}attachTimeline(t){return this._animation?this.stopTimeline=this.animation.attachTimeline(t):this.pendingTimeline=t,()=>this.stop()}play(){this.animation.play()}pause(){this.animation.pause()}complete(){this.animation.complete()}cancel(){var t;this._animation&&this.animation.cancel(),(t=this.keyframeResolver)==null||t.cancel()}}const lv=/^var\(--(?:([\w-]+)|([\w-]+), ?([a-zA-Z\d ()%#.,-]+))\)/u;function uv(e){const t=lv.exec(e);if(!t)return[,];const[,n,r,i]=t;return[`--${n??r}`,i]}function G0(e,t,n=1){const[r,i]=uv(e);if(!r)return;const s=window.getComputedStyle(t).getPropertyValue(r);if(s){const o=s.trim();return m0(o)?parseFloat(o):o}return su(i)?G0(i,t,n+1):i}function pu(e,t){return(e==null?void 0:e[t])??(e==null?void 0:e.default)??e}const Y0=new Set(["width","height","top","left","right","bottom",...or]),cv={test:e=>e==="auto",parse:e=>e},Q0=e=>t=>t.test(e),X0=[sr,A,ft,Mt,ty,ey,cv],qc=e=>X0.find(Q0(e));function dv(e){return typeof e=="number"?e===0:e!==null?e==="none"||e==="0"||y0(e):!0}const fv=new Set(["brightness","contrast","saturate","opacity"]);function hv(e){const[t,n]=e.slice(0,-1).split("(");if(t==="drop-shadow")return e;const[r]=n.match(ou)||[];if(!r)return e;const i=n.replace(r,"");let s=fv.has(t)?1:0;return r!==n&&(s*=100),t+"("+s+i+")"}const pv=/\b([a-z-]*)\(.*?\)/gu,Wa={...Gt,getAnimatableNone:e=>{const t=e.match(pv);return t?t.map(hv).join(" "):e}},Jc={...sr,transform:Math.round},mv={rotate:Mt,rotateX:Mt,rotateY:Mt,rotateZ:Mt,scale:Ai,scaleX:Ai,scaleY:Ai,scaleZ:Ai,skew:Mt,skewX:Mt,skewY:Mt,distance:A,translateX:A,translateY:A,translateZ:A,x:A,y:A,z:A,perspective:A,transformPerspective:A,opacity:ti,originX:Bc,originY:Bc,originZ:A},mu={borderWidth:A,borderTopWidth:A,borderRightWidth:A,borderBottomWidth:A,borderLeftWidth:A,borderRadius:A,radius:A,borderTopLeftRadius:A,borderTopRightRadius:A,borderBottomRightRadius:A,borderBottomLeftRadius:A,width:A,maxWidth:A,height:A,maxHeight:A,top:A,right:A,bottom:A,left:A,padding:A,paddingTop:A,paddingRight:A,paddingBottom:A,paddingLeft:A,margin:A,marginTop:A,marginRight:A,marginBottom:A,marginLeft:A,backgroundPositionX:A,backgroundPositionY:A,...mv,zIndex:Jc,fillOpacity:ti,strokeOpacity:ti,numOctaves:Jc},gv={...mu,color:se,backgroundColor:se,outlineColor:se,fill:se,stroke:se,borderColor:se,borderTopColor:se,borderRightColor:se,borderBottomColor:se,borderLeftColor:se,filter:Wa,WebkitFilter:Wa},Z0=e=>gv[e];function q0(e,t){let n=Z0(e);return n!==Wa&&(n=Gt),n.getAnimatableNone?n.getAnimatableNone(t):void 0}const yv=new Set(["auto","none","0"]);function vv(e,t,n){let r=0,i;for(;r{t.getValue(l).set(u)}),this.resolveNoneKeyframes()}}function wv(e,t,n){if(e instanceof EventTarget)return[e];if(typeof e=="string"){let r=document;const i=(n==null?void 0:n[e])??r.querySelectorAll(e);return i?Array.from(i):[]}return Array.from(e)}const J0=(e,t)=>t&&typeof e=="number"?t.transform(e):e;function ep(e){return g0(e)&&"offsetHeight"in e}const ed=30,kv=e=>!isNaN(parseFloat(e));class Sv{constructor(t,n={}){this.canTrackVelocity=null,this.events={},this.updateAndNotify=r=>{var s;const i=be.now();if(this.updatedAt!==i&&this.setPrevFrameValue(),this.prev=this.current,this.setCurrent(r),this.current!==this.prev&&((s=this.events.change)==null||s.notify(this.current),this.dependents))for(const o of this.dependents)o.dirty()},this.hasAnimated=!1,this.setCurrent(t),this.owner=n.owner}setCurrent(t){this.current=t,this.updatedAt=be.now(),this.canTrackVelocity===null&&t!==void 0&&(this.canTrackVelocity=kv(this.current))}setPrevFrameValue(t=this.current){this.prevFrameValue=t,this.prevUpdatedAt=this.updatedAt}onChange(t){return this.on("change",t)}on(t,n){this.events[t]||(this.events[t]=new tu);const r=this.events[t].add(n);return t==="change"?()=>{r(),Q.read(()=>{this.events.change.getSize()||this.stop()})}:r}clearListeners(){for(const t in this.events)this.events[t].clear()}attach(t,n){this.passiveEffect=t,this.stopPassiveEffect=n}set(t){this.passiveEffect?this.passiveEffect(t,this.updateAndNotify):this.updateAndNotify(t)}setWithVelocity(t,n,r){this.set(n),this.prev=void 0,this.prevFrameValue=t,this.prevUpdatedAt=this.updatedAt-r}jump(t,n=!0){this.updateAndNotify(t),this.prev=t,this.prevUpdatedAt=this.prevFrameValue=void 0,n&&this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}dirty(){var t;(t=this.events.change)==null||t.notify(this.current)}addDependent(t){this.dependents||(this.dependents=new Set),this.dependents.add(t)}removeDependent(t){this.dependents&&this.dependents.delete(t)}get(){return this.current}getPrevious(){return this.prev}getVelocity(){const t=be.now();if(!this.canTrackVelocity||this.prevFrameValue===void 0||t-this.updatedAt>ed)return 0;const n=Math.min(this.updatedAt-this.prevUpdatedAt,ed);return v0(parseFloat(this.current)-parseFloat(this.prevFrameValue),n)}start(t){return this.stop(),new Promise(n=>{this.hasAnimated=!0,this.animation=t(n),this.events.animationStart&&this.events.animationStart.notify()}).then(()=>{this.events.animationComplete&&this.events.animationComplete.notify(),this.clearAnimation()})}stop(){this.animation&&(this.animation.stop(),this.events.animationCancel&&this.events.animationCancel.notify()),this.clearAnimation()}isAnimating(){return!!this.animation}clearAnimation(){delete this.animation}destroy(){var t,n;(t=this.dependents)==null||t.clear(),(n=this.events.destroy)==null||n.notify(),this.clearListeners(),this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}}function er(e,t){return new Sv(e,t)}const{schedule:gu}=M0(queueMicrotask,!1),Je={x:!1,y:!1};function tp(){return Je.x||Je.y}function Cv(e){return e==="x"||e==="y"?Je[e]?null:(Je[e]=!0,()=>{Je[e]=!1}):Je.x||Je.y?null:(Je.x=Je.y=!0,()=>{Je.x=Je.y=!1})}function np(e,t){const n=wv(e),r=new AbortController,i={passive:!0,...t,signal:r.signal};return[n,i,()=>r.abort()]}function td(e){return!(e.pointerType==="touch"||tp())}function jv(e,t,n={}){const[r,i,s]=np(e,n),o=a=>{if(!td(a))return;const{target:l}=a,u=t(l,a);if(typeof u!="function"||!l)return;const c=h=>{td(h)&&(u(h),l.removeEventListener("pointerleave",c))};l.addEventListener("pointerleave",c,i)};return r.forEach(a=>{a.addEventListener("pointerenter",o,i)}),s}const rp=(e,t)=>t?e===t?!0:rp(e,t.parentElement):!1,yu=e=>e.pointerType==="mouse"?typeof e.button!="number"||e.button<=0:e.isPrimary!==!1,Tv=new Set(["BUTTON","INPUT","SELECT","TEXTAREA","A"]);function Pv(e){return Tv.has(e.tagName)||e.tabIndex!==-1}const Xi=new WeakSet;function nd(e){return t=>{t.key==="Enter"&&e(t)}}function No(e,t){e.dispatchEvent(new PointerEvent("pointer"+t,{isPrimary:!0,bubbles:!0}))}const Nv=(e,t)=>{const n=e.currentTarget;if(!n)return;const r=nd(()=>{if(Xi.has(n))return;No(n,"down");const i=nd(()=>{No(n,"up")}),s=()=>No(n,"cancel");n.addEventListener("keyup",i,t),n.addEventListener("blur",s,t)});n.addEventListener("keydown",r,t),n.addEventListener("blur",()=>n.removeEventListener("keydown",r),t)};function rd(e){return yu(e)&&!tp()}function Ev(e,t,n={}){const[r,i,s]=np(e,n),o=a=>{const l=a.currentTarget;if(!rd(a))return;Xi.add(l);const u=t(l,a),c=(y,v)=>{window.removeEventListener("pointerup",h),window.removeEventListener("pointercancel",f),Xi.has(l)&&Xi.delete(l),rd(y)&&typeof u=="function"&&u(y,{success:v})},h=y=>{c(y,l===window||l===document||n.useGlobalTarget||rp(l,y.target))},f=y=>{c(y,!1)};window.addEventListener("pointerup",h,i),window.addEventListener("pointercancel",f,i)};return r.forEach(a=>{(n.useGlobalTarget?window:a).addEventListener("pointerdown",o,i),ep(a)&&(a.addEventListener("focus",u=>Nv(u,i)),!Pv(a)&&!a.hasAttribute("tabindex")&&(a.tabIndex=0))}),s}function ip(e){return g0(e)&&"ownerSVGElement"in e}function Mv(e){return ip(e)&&e.tagName==="svg"}const ke=e=>!!(e&&e.getVelocity),Dv=[...X0,se,Gt],bv=e=>Dv.find(Q0(e)),vu=C.createContext({transformPagePoint:e=>e,isStatic:!1,reducedMotion:"never"});function id(e,t){if(typeof e=="function")return e(t);e!=null&&(e.current=t)}function Lv(...e){return t=>{let n=!1;const r=e.map(i=>{const s=id(i,t);return!n&&typeof s=="function"&&(n=!0),s});if(n)return()=>{for(let i=0;i{const{width:u,height:c,top:h,left:f,right:y}=o.current;if(t||!s.current||!u||!c)return;const v=n==="left"?`left: ${f}`:`right: ${y}`;s.current.dataset.motionPopId=i;const x=document.createElement("style");a&&(x.nonce=a);const P=r??document.head;return P.appendChild(x),x.sheet&&x.sheet.insertRule(` + [data-motion-pop-id="${i}"] { + position: absolute !important; + width: ${u}px !important; + height: ${c}px !important; + ${v}px !important; + top: ${h}px !important; + } + `),()=>{P.contains(x)&&P.removeChild(x)}},[t]),d.jsx(Rv,{isPresent:t,childRef:s,sizeRef:o,children:C.cloneElement(e,{ref:l})})}const Iv=({children:e,initial:t,isPresent:n,onExitComplete:r,custom:i,presenceAffectsLayout:s,mode:o,anchorX:a,root:l})=>{const u=Ql(_v),c=C.useId();let h=!0,f=C.useMemo(()=>(h=!1,{id:c,initial:t,isPresent:n,custom:i,onExitComplete:y=>{u.set(y,!0);for(const v of u.values())if(!v)return;r&&r()},register:y=>(u.set(y,!1),()=>u.delete(y))}),[n,u,r]);return s&&h&&(f={...f}),C.useMemo(()=>{u.forEach((y,v)=>u.set(v,!1))},[n]),C.useEffect(()=>{!n&&!u.size&&r&&r()},[n]),o==="popLayout"&&(e=d.jsx(Vv,{isPresent:n,anchorX:a,root:l,children:e})),d.jsx(Hs.Provider,{value:f,children:e})};function _v(){return new Map}function sp(e=!0){const t=C.useContext(Hs);if(t===null)return[!0,null];const{isPresent:n,onExitComplete:r,register:i}=t,s=C.useId();C.useEffect(()=>{if(e)return i(s)},[e]);const o=C.useCallback(()=>e&&r&&r(s),[s,r,e]);return!n&&r?[!1,o]:[!0]}const Ri=e=>e.key||"";function sd(e){const t=[];return C.Children.forEach(e,n=>{C.isValidElement(n)&&t.push(n)}),t}const Ha=({children:e,custom:t,initial:n=!0,onExitComplete:r,presenceAffectsLayout:i=!0,mode:s="sync",propagate:o=!1,anchorX:a="left",root:l})=>{const[u,c]=sp(o),h=C.useMemo(()=>sd(e),[e]),f=o&&!u?[]:h.map(Ri),y=C.useRef(!0),v=C.useRef(h),x=Ql(()=>new Map),[P,m]=C.useState(h),[p,g]=C.useState(h);p0(()=>{y.current=!1,v.current=h;for(let T=0;T{const w=Ri(T),j=o&&!u?!1:h===p||f.includes(w),V=()=>{if(x.has(w))x.set(w,!0);else return;let D=!0;x.forEach(W=>{W||(D=!1)}),D&&(S==null||S(),g(v.current),o&&(c==null||c()),r&&r())};return d.jsx(Iv,{isPresent:j,initial:!y.current||n?void 0:!1,custom:t,presenceAffectsLayout:i,mode:s,root:l,onExitComplete:j?void 0:V,anchorX:a,children:T},w)})})},op=C.createContext({strict:!1}),od={animation:["animate","variants","whileHover","whileTap","exit","whileInView","whileFocus","whileDrag"],exit:["exit"],drag:["drag","dragControls"],focus:["whileFocus"],hover:["whileHover","onHoverStart","onHoverEnd"],tap:["whileTap","onTap","onTapStart","onTapCancel"],pan:["onPan","onPanStart","onPanSessionStart","onPanEnd"],inView:["whileInView","onViewportEnter","onViewportLeave"],layout:["layout","layoutId"]},tr={};for(const e in od)tr[e]={isEnabled:t=>od[e].some(n=>!!t[n])};function Fv(e){for(const t in e)tr[t]={...tr[t],...e[t]}}const Ov=new Set(["animate","exit","variants","initial","style","values","variants","transition","transformTemplate","custom","inherit","onBeforeLayoutMeasure","onAnimationStart","onAnimationComplete","onUpdate","onDragStart","onDrag","onDragEnd","onMeasureDragConstraints","onDirectionLock","onDragTransitionEnd","_dragX","_dragY","onHoverStart","onHoverEnd","onViewportEnter","onViewportLeave","globalTapTarget","ignoreStrict","viewport"]);function Ps(e){return e.startsWith("while")||e.startsWith("drag")&&e!=="draggable"||e.startsWith("layout")||e.startsWith("onTap")||e.startsWith("onPan")||e.startsWith("onLayout")||Ov.has(e)}let ap=e=>!Ps(e);function Bv(e){typeof e=="function"&&(ap=t=>t.startsWith("on")?!Ps(t):e(t))}try{Bv(require("@emotion/is-prop-valid").default)}catch{}function zv(e,t,n){const r={};for(const i in e)i==="values"&&typeof e.values=="object"||(ap(i)||n===!0&&Ps(i)||!t&&!Ps(i)||e.draggable&&i.startsWith("onDrag"))&&(r[i]=e[i]);return r}const Ks=C.createContext({});function Gs(e){return e!==null&&typeof e=="object"&&typeof e.start=="function"}function ri(e){return typeof e=="string"||Array.isArray(e)}const xu=["animate","whileInView","whileFocus","whileHover","whileTap","whileDrag","exit"],wu=["initial",...xu];function Ys(e){return Gs(e.animate)||wu.some(t=>ri(e[t]))}function lp(e){return!!(Ys(e)||e.variants)}function Uv(e,t){if(Ys(e)){const{initial:n,animate:r}=e;return{initial:n===!1||ri(n)?n:void 0,animate:ri(r)?r:void 0}}return e.inherit!==!1?t:{}}function $v(e){const{initial:t,animate:n}=Uv(e,C.useContext(Ks));return C.useMemo(()=>({initial:t,animate:n}),[ad(t),ad(n)])}function ad(e){return Array.isArray(e)?e.join(" "):e}const ii={};function Wv(e){for(const t in e)ii[t]=e[t],iu(t)&&(ii[t].isCSSVariable=!0)}function up(e,{layout:t,layoutId:n}){return ar.has(e)||e.startsWith("origin")||(t||n!==void 0)&&(!!ii[e]||e==="opacity")}const Hv={x:"translateX",y:"translateY",z:"translateZ",transformPerspective:"perspective"},Kv=or.length;function Gv(e,t,n){let r="",i=!0;for(let s=0;s({style:{},transform:{},transformOrigin:{},vars:{}});function cp(e,t,n){for(const r in t)!ke(t[r])&&!up(r,n)&&(e[r]=t[r])}function Yv({transformTemplate:e},t){return C.useMemo(()=>{const n=Su();return ku(n,t,e),Object.assign({},n.vars,n.style)},[t])}function Qv(e,t){const n=e.style||{},r={};return cp(r,n,e),Object.assign(r,Yv(e,t)),r}function Xv(e,t){const n={},r=Qv(e,t);return e.drag&&e.dragListener!==!1&&(n.draggable=!1,r.userSelect=r.WebkitUserSelect=r.WebkitTouchCallout="none",r.touchAction=e.drag===!0?"none":`pan-${e.drag==="x"?"y":"x"}`),e.tabIndex===void 0&&(e.onTap||e.onTapStart||e.whileTap)&&(n.tabIndex=0),n.style=r,n}const Zv={offset:"stroke-dashoffset",array:"stroke-dasharray"},qv={offset:"strokeDashoffset",array:"strokeDasharray"};function Jv(e,t,n=1,r=0,i=!0){e.pathLength=1;const s=i?Zv:qv;e[s.offset]=A.transform(-r);const o=A.transform(t),a=A.transform(n);e[s.array]=`${o} ${a}`}function dp(e,{attrX:t,attrY:n,attrScale:r,pathLength:i,pathSpacing:s=1,pathOffset:o=0,...a},l,u,c){if(ku(e,a,u),l){e.style.viewBox&&(e.attrs.viewBox=e.style.viewBox);return}e.attrs=e.style,e.style={};const{attrs:h,style:f}=e;h.transform&&(f.transform=h.transform,delete h.transform),(f.transform||h.transformOrigin)&&(f.transformOrigin=h.transformOrigin??"50% 50%",delete h.transformOrigin),f.transform&&(f.transformBox=(c==null?void 0:c.transformBox)??"fill-box",delete h.transformBox),t!==void 0&&(h.x=t),n!==void 0&&(h.y=n),r!==void 0&&(h.scale=r),i!==void 0&&Jv(h,i,s,o,!1)}const fp=()=>({...Su(),attrs:{}}),hp=e=>typeof e=="string"&&e.toLowerCase()==="svg";function ex(e,t,n,r){const i=C.useMemo(()=>{const s=fp();return dp(s,t,hp(r),e.transformTemplate,e.style),{...s.attrs,style:{...s.style}}},[t]);if(e.style){const s={};cp(s,e.style,e),i.style={...s,...i.style}}return i}const tx=["animate","circle","defs","desc","ellipse","g","image","line","filter","marker","mask","metadata","path","pattern","polygon","polyline","rect","stop","switch","symbol","svg","text","tspan","use","view"];function Cu(e){return typeof e!="string"||e.includes("-")?!1:!!(tx.indexOf(e)>-1||/[A-Z]/u.test(e))}function nx(e,t,n,{latestValues:r},i,s=!1){const a=(Cu(e)?ex:Xv)(t,r,i,e),l=zv(t,typeof e=="string",s),u=e!==C.Fragment?{...l,...a,ref:n}:{},{children:c}=t,h=C.useMemo(()=>ke(c)?c.get():c,[c]);return C.createElement(e,{...u,children:h})}function ld(e){const t=[{},{}];return e==null||e.values.forEach((n,r)=>{t[0][r]=n.get(),t[1][r]=n.getVelocity()}),t}function ju(e,t,n,r){if(typeof t=="function"){const[i,s]=ld(r);t=t(n!==void 0?n:e.custom,i,s)}if(typeof t=="string"&&(t=e.variants&&e.variants[t]),typeof t=="function"){const[i,s]=ld(r);t=t(n!==void 0?n:e.custom,i,s)}return t}function Zi(e){return ke(e)?e.get():e}function rx({scrapeMotionValuesFromProps:e,createRenderState:t},n,r,i){return{latestValues:ix(n,r,i,e),renderState:t()}}function ix(e,t,n,r){const i={},s=r(e,{});for(const f in s)i[f]=Zi(s[f]);let{initial:o,animate:a}=e;const l=Ys(e),u=lp(e);t&&u&&!l&&e.inherit!==!1&&(o===void 0&&(o=t.initial),a===void 0&&(a=t.animate));let c=n?n.initial===!1:!1;c=c||o===!1;const h=c?a:o;if(h&&typeof h!="boolean"&&!Gs(h)){const f=Array.isArray(h)?h:[h];for(let y=0;y(t,n)=>{const r=C.useContext(Ks),i=C.useContext(Hs),s=()=>rx(e,t,r,i);return n?s():Ql(s)};function Tu(e,t,n){var s;const{style:r}=e,i={};for(const o in r)(ke(r[o])||t.style&&ke(t.style[o])||up(o,e)||((s=n==null?void 0:n.getValue(o))==null?void 0:s.liveStyle)!==void 0)&&(i[o]=r[o]);return i}const sx=pp({scrapeMotionValuesFromProps:Tu,createRenderState:Su});function mp(e,t,n){const r=Tu(e,t,n);for(const i in e)if(ke(e[i])||ke(t[i])){const s=or.indexOf(i)!==-1?"attr"+i.charAt(0).toUpperCase()+i.substring(1):i;r[s]=e[i]}return r}const ox=pp({scrapeMotionValuesFromProps:mp,createRenderState:fp}),ax=Symbol.for("motionComponentSymbol");function In(e){return e&&typeof e=="object"&&Object.prototype.hasOwnProperty.call(e,"current")}function lx(e,t,n){return C.useCallback(r=>{r&&e.onMount&&e.onMount(r),t&&(r?t.mount(r):t.unmount()),n&&(typeof n=="function"?n(r):In(n)&&(n.current=r))},[t])}const Pu=e=>e.replace(/([a-z])([A-Z])/gu,"$1-$2").toLowerCase(),ux="framerAppearId",gp="data-"+Pu(ux),yp=C.createContext({});function cx(e,t,n,r,i){var x,P;const{visualElement:s}=C.useContext(Ks),o=C.useContext(op),a=C.useContext(Hs),l=C.useContext(vu).reducedMotion,u=C.useRef(null);r=r||o.renderer,!u.current&&r&&(u.current=r(e,{visualState:t,parent:s,props:n,presenceContext:a,blockInitialAnimation:a?a.initial===!1:!1,reducedMotionConfig:l}));const c=u.current,h=C.useContext(yp);c&&!c.projection&&i&&(c.type==="html"||c.type==="svg")&&dx(u.current,n,i,h);const f=C.useRef(!1);C.useInsertionEffect(()=>{c&&f.current&&c.update(n,a)});const y=n[gp],v=C.useRef(!!y&&!((x=window.MotionHandoffIsComplete)!=null&&x.call(window,y))&&((P=window.MotionHasOptimisedAnimation)==null?void 0:P.call(window,y)));return p0(()=>{c&&(f.current=!0,window.MotionIsMounted=!0,c.updateFeatures(),c.scheduleRenderMicrotask(),v.current&&c.animationState&&c.animationState.animateChanges())}),C.useEffect(()=>{c&&(!v.current&&c.animationState&&c.animationState.animateChanges(),v.current&&(queueMicrotask(()=>{var m;(m=window.MotionHandoffMarkAsComplete)==null||m.call(window,y)}),v.current=!1),c.enteringChildren=void 0)}),c}function dx(e,t,n,r){const{layoutId:i,layout:s,drag:o,dragConstraints:a,layoutScroll:l,layoutRoot:u,layoutCrossfade:c}=t;e.projection=new n(e.latestValues,t["data-framer-portal-id"]?void 0:vp(e.parent)),e.projection.setOptions({layoutId:i,layout:s,alwaysMeasureLayout:!!o||a&&In(a),visualElement:e,animationType:typeof s=="string"?s:"both",initialPromotionConfig:r,crossfade:c,layoutScroll:l,layoutRoot:u})}function vp(e){if(e)return e.options.allowProjection!==!1?e.projection:vp(e.parent)}function Eo(e,{forwardMotionProps:t=!1}={},n,r){n&&Fv(n);const i=Cu(e)?ox:sx;function s(a,l){let u;const c={...C.useContext(vu),...a,layoutId:fx(a)},{isStatic:h}=c,f=$v(a),y=i(a,h);if(!h&&Xl){hx();const v=px(c);u=v.MeasureLayout,f.visualElement=cx(e,y,c,r,v.ProjectionNode)}return d.jsxs(Ks.Provider,{value:f,children:[u&&f.visualElement?d.jsx(u,{visualElement:f.visualElement,...c}):null,nx(e,a,lx(y,f.visualElement,l),y,h,t)]})}s.displayName=`motion.${typeof e=="string"?e:`create(${e.displayName??e.name??""})`}`;const o=C.forwardRef(s);return o[ax]=e,o}function fx({layoutId:e}){const t=C.useContext(Yl).id;return t&&e!==void 0?t+"-"+e:e}function hx(e,t){C.useContext(op).strict}function px(e){const{drag:t,layout:n}=tr;if(!t&&!n)return{};const r={...t,...n};return{MeasureLayout:t!=null&&t.isEnabled(e)||n!=null&&n.isEnabled(e)?r.MeasureLayout:void 0,ProjectionNode:r.ProjectionNode}}function mx(e,t){if(typeof Proxy>"u")return Eo;const n=new Map,r=(s,o)=>Eo(s,o,e,t),i=(s,o)=>r(s,o);return new Proxy(i,{get:(s,o)=>o==="create"?r:(n.has(o)||n.set(o,Eo(o,void 0,e,t)),n.get(o))})}function xp({top:e,left:t,right:n,bottom:r}){return{x:{min:t,max:n},y:{min:e,max:r}}}function gx({x:e,y:t}){return{top:t.min,right:e.max,bottom:t.max,left:e.min}}function yx(e,t){if(!t)return e;const n=t({x:e.left,y:e.top}),r=t({x:e.right,y:e.bottom});return{top:n.y,left:n.x,bottom:r.y,right:r.x}}function Mo(e){return e===void 0||e===1}function Ka({scale:e,scaleX:t,scaleY:n}){return!Mo(e)||!Mo(t)||!Mo(n)}function nn(e){return Ka(e)||wp(e)||e.z||e.rotate||e.rotateX||e.rotateY||e.skewX||e.skewY}function wp(e){return ud(e.x)||ud(e.y)}function ud(e){return e&&e!=="0%"}function Ns(e,t,n){const r=e-n,i=t*r;return n+i}function cd(e,t,n,r,i){return i!==void 0&&(e=Ns(e,i,r)),Ns(e,n,r)+t}function Ga(e,t=0,n=1,r,i){e.min=cd(e.min,t,n,r,i),e.max=cd(e.max,t,n,r,i)}function kp(e,{x:t,y:n}){Ga(e.x,t.translate,t.scale,t.originPoint),Ga(e.y,n.translate,n.scale,n.originPoint)}const dd=.999999999999,fd=1.0000000000001;function vx(e,t,n,r=!1){const i=n.length;if(!i)return;t.x=t.y=1;let s,o;for(let a=0;add&&(t.x=1),t.ydd&&(t.y=1)}function _n(e,t){e.min=e.min+t,e.max=e.max+t}function hd(e,t,n,r,i=.5){const s=q(e.min,e.max,i);Ga(e,t,n,s,r)}function Fn(e,t){hd(e.x,t.x,t.scaleX,t.scale,t.originX),hd(e.y,t.y,t.scaleY,t.scale,t.originY)}function Sp(e,t){return xp(yx(e.getBoundingClientRect(),t))}function xx(e,t,n){const r=Sp(e,n),{scroll:i}=t;return i&&(_n(r.x,i.offset.x),_n(r.y,i.offset.y)),r}const pd=()=>({translate:0,scale:1,origin:0,originPoint:0}),On=()=>({x:pd(),y:pd()}),md=()=>({min:0,max:0}),ae=()=>({x:md(),y:md()}),Ya={current:null},Cp={current:!1};function wx(){if(Cp.current=!0,!!Xl)if(window.matchMedia){const e=window.matchMedia("(prefers-reduced-motion)"),t=()=>Ya.current=e.matches;e.addEventListener("change",t),t()}else Ya.current=!1}const kx=new WeakMap;function Sx(e,t,n){for(const r in t){const i=t[r],s=n[r];if(ke(i))e.addValue(r,i);else if(ke(s))e.addValue(r,er(i,{owner:e}));else if(s!==i)if(e.hasValue(r)){const o=e.getValue(r);o.liveStyle===!0?o.jump(i):o.hasAnimated||o.set(i)}else{const o=e.getStaticValue(r);e.addValue(r,er(o!==void 0?o:i,{owner:e}))}}for(const r in n)t[r]===void 0&&e.removeValue(r);return t}const gd=["AnimationStart","AnimationComplete","Update","BeforeLayoutMeasure","LayoutMeasure","LayoutAnimationStart","LayoutAnimationComplete"];class Cx{scrapeMotionValuesFromProps(t,n,r){return{}}constructor({parent:t,props:n,presenceContext:r,reducedMotionConfig:i,blockInitialAnimation:s,visualState:o},a={}){this.current=null,this.children=new Set,this.isVariantNode=!1,this.isControllingVariants=!1,this.shouldReduceMotion=null,this.values=new Map,this.KeyframeResolver=hu,this.features={},this.valueSubscriptions=new Map,this.prevMotionValues={},this.events={},this.propEventSubscriptions={},this.notifyUpdate=()=>this.notify("Update",this.latestValues),this.render=()=>{this.current&&(this.triggerBuild(),this.renderInstance(this.current,this.renderState,this.props.style,this.projection))},this.renderScheduledAt=0,this.scheduleRender=()=>{const f=be.now();this.renderScheduledAtthis.bindToMotionValue(i,r)),Cp.current||wx(),this.shouldReduceMotion=this.reducedMotionConfig==="never"?!1:this.reducedMotionConfig==="always"?!0:Ya.current,(n=this.parent)==null||n.addChild(this),this.update(this.props,this.presenceContext)}unmount(){var t;this.projection&&this.projection.unmount(),Kt(this.notifyUpdate),Kt(this.render),this.valueSubscriptions.forEach(n=>n()),this.valueSubscriptions.clear(),this.removeFromVariantTree&&this.removeFromVariantTree(),(t=this.parent)==null||t.removeChild(this);for(const n in this.events)this.events[n].clear();for(const n in this.features){const r=this.features[n];r&&(r.unmount(),r.isMounted=!1)}this.current=null}addChild(t){this.children.add(t),this.enteringChildren??(this.enteringChildren=new Set),this.enteringChildren.add(t)}removeChild(t){this.children.delete(t),this.enteringChildren&&this.enteringChildren.delete(t)}bindToMotionValue(t,n){this.valueSubscriptions.has(t)&&this.valueSubscriptions.get(t)();const r=ar.has(t);r&&this.onBindTransform&&this.onBindTransform();const i=n.on("change",o=>{this.latestValues[t]=o,this.props.onUpdate&&Q.preRender(this.notifyUpdate),r&&this.projection&&(this.projection.isTransformDirty=!0),this.scheduleRender()});let s;window.MotionCheckAppearSync&&(s=window.MotionCheckAppearSync(this,t,n)),this.valueSubscriptions.set(t,()=>{i(),s&&s(),n.owner&&n.stop()})}sortNodePosition(t){return!this.current||!this.sortInstanceNodePosition||this.type!==t.type?0:this.sortInstanceNodePosition(this.current,t.current)}updateFeatures(){let t="animation";for(t in tr){const n=tr[t];if(!n)continue;const{isEnabled:r,Feature:i}=n;if(!this.features[t]&&i&&r(this.props)&&(this.features[t]=new i(this)),this.features[t]){const s=this.features[t];s.isMounted?s.update():(s.mount(),s.isMounted=!0)}}}triggerBuild(){this.build(this.renderState,this.latestValues,this.props)}measureViewportBox(){return this.current?this.measureInstanceViewportBox(this.current,this.props):ae()}getStaticValue(t){return this.latestValues[t]}setStaticValue(t,n){this.latestValues[t]=n}update(t,n){(t.transformTemplate||this.props.transformTemplate)&&this.scheduleRender(),this.prevProps=this.props,this.props=t,this.prevPresenceContext=this.presenceContext,this.presenceContext=n;for(let r=0;rn.variantChildren.delete(t)}addValue(t,n){const r=this.values.get(t);n!==r&&(r&&this.removeValue(t),this.bindToMotionValue(t,n),this.values.set(t,n),this.latestValues[t]=n.get())}removeValue(t){this.values.delete(t);const n=this.valueSubscriptions.get(t);n&&(n(),this.valueSubscriptions.delete(t)),delete this.latestValues[t],this.removeValueFromRenderState(t,this.renderState)}hasValue(t){return this.values.has(t)}getValue(t,n){if(this.props.values&&this.props.values[t])return this.props.values[t];let r=this.values.get(t);return r===void 0&&n!==void 0&&(r=er(n===null?void 0:n,{owner:this}),this.addValue(t,r)),r}readValue(t,n){let r=this.latestValues[t]!==void 0||!this.current?this.latestValues[t]:this.getBaseTargetFromProps(this.props,t)??this.readValueFromInstance(this.current,t,this.options);return r!=null&&(typeof r=="string"&&(m0(r)||y0(r))?r=parseFloat(r):!bv(r)&&Gt.test(n)&&(r=q0(t,n)),this.setBaseTarget(t,ke(r)?r.get():r)),ke(r)?r.get():r}setBaseTarget(t,n){this.baseTarget[t]=n}getBaseTarget(t){var s;const{initial:n}=this.props;let r;if(typeof n=="string"||typeof n=="object"){const o=ju(this.props,n,(s=this.presenceContext)==null?void 0:s.custom);o&&(r=o[t])}if(n&&r!==void 0)return r;const i=this.getBaseTargetFromProps(this.props,t);return i!==void 0&&!ke(i)?i:this.initialValues[t]!==void 0&&r===void 0?void 0:this.baseTarget[t]}on(t,n){return this.events[t]||(this.events[t]=new tu),this.events[t].add(n)}notify(t,...n){this.events[t]&&this.events[t].notify(...n)}scheduleRenderMicrotask(){gu.render(this.render)}}class jp extends Cx{constructor(){super(...arguments),this.KeyframeResolver=xv}sortInstanceNodePosition(t,n){return t.compareDocumentPosition(n)&2?1:-1}getBaseTargetFromProps(t,n){return t.style?t.style[n]:void 0}removeValueFromRenderState(t,{vars:n,style:r}){delete n[t],delete r[t]}handleChildMotionValue(){this.childSubscription&&(this.childSubscription(),delete this.childSubscription);const{children:t}=this.props;ke(t)&&(this.childSubscription=t.on("change",n=>{this.current&&(this.current.textContent=`${n}`)}))}}function Tp(e,{style:t,vars:n},r,i){const s=e.style;let o;for(o in t)s[o]=t[o];i==null||i.applyProjectionStyles(s,r);for(o in n)s.setProperty(o,n[o])}function jx(e){return window.getComputedStyle(e)}class Tx extends jp{constructor(){super(...arguments),this.type="html",this.renderInstance=Tp}readValueFromInstance(t,n){var r;if(ar.has(n))return(r=this.projection)!=null&&r.isProjecting?Fa(n):Fy(t,n);{const i=jx(t),s=(iu(n)?i.getPropertyValue(n):i[n])||0;return typeof s=="string"?s.trim():s}}measureInstanceViewportBox(t,{transformPagePoint:n}){return Sp(t,n)}build(t,n,r){ku(t,n,r.transformTemplate)}scrapeMotionValuesFromProps(t,n,r){return Tu(t,n,r)}}const Pp=new Set(["baseFrequency","diffuseConstant","kernelMatrix","kernelUnitLength","keySplines","keyTimes","limitingConeAngle","markerHeight","markerWidth","numOctaves","targetX","targetY","surfaceScale","specularConstant","specularExponent","stdDeviation","tableValues","viewBox","gradientTransform","pathLength","startOffset","textLength","lengthAdjust"]);function Px(e,t,n,r){Tp(e,t,void 0,r);for(const i in t.attrs)e.setAttribute(Pp.has(i)?i:Pu(i),t.attrs[i])}class Nx extends jp{constructor(){super(...arguments),this.type="svg",this.isSVGTag=!1,this.measureInstanceViewportBox=ae}getBaseTargetFromProps(t,n){return t[n]}readValueFromInstance(t,n){if(ar.has(n)){const r=Z0(n);return r&&r.default||0}return n=Pp.has(n)?n:Pu(n),t.getAttribute(n)}scrapeMotionValuesFromProps(t,n,r){return mp(t,n,r)}build(t,n,r){dp(t,n,this.isSVGTag,r.transformTemplate,r.style)}renderInstance(t,n,r,i){Px(t,n,r,i)}mount(t){this.isSVGTag=hp(t.tagName),super.mount(t)}}const Ex=(e,t)=>Cu(e)?new Nx(t):new Tx(t,{allowProjection:e!==C.Fragment});function Kn(e,t,n){const r=e.getProps();return ju(r,t,n!==void 0?n:r.custom,e)}const Qa=e=>Array.isArray(e);function Mx(e,t,n){e.hasValue(t)?e.getValue(t).set(n):e.addValue(t,er(n))}function Dx(e){return Qa(e)?e[e.length-1]||0:e}function bx(e,t){const n=Kn(e,t);let{transitionEnd:r={},transition:i={},...s}=n||{};s={...s,...r};for(const o in s){const a=Dx(s[o]);Mx(e,o,a)}}function Lx(e){return!!(ke(e)&&e.add)}function Xa(e,t){const n=e.getValue("willChange");if(Lx(n))return n.add(t);if(!n&&Pt.WillChange){const r=new Pt.WillChange("auto");e.addValue("willChange",r),r.add(t)}}function Np(e){return e.props[gp]}const Ax=e=>e!==null;function Rx(e,{repeat:t,repeatType:n="loop"},r){const i=e.filter(Ax),s=t&&n!=="loop"&&t%2===1?0:i.length-1;return i[s]}const Vx={type:"spring",stiffness:500,damping:25,restSpeed:10},Ix=e=>({type:"spring",stiffness:550,damping:e===0?2*Math.sqrt(550):30,restSpeed:10}),_x={type:"keyframes",duration:.8},Fx={type:"keyframes",ease:[.25,.1,.35,1],duration:.3},Ox=(e,{keyframes:t})=>t.length>2?_x:ar.has(e)?e.startsWith("scale")?Ix(t[1]):Vx:Fx;function Bx({when:e,delay:t,delayChildren:n,staggerChildren:r,staggerDirection:i,repeat:s,repeatType:o,repeatDelay:a,from:l,elapsed:u,...c}){return!!Object.keys(c).length}const Nu=(e,t,n,r={},i,s)=>o=>{const a=pu(r,e)||{},l=a.delay||r.delay||0;let{elapsed:u=0}=r;u=u-dt(l);const c={keyframes:Array.isArray(n)?n:[null,n],ease:"easeOut",velocity:t.getVelocity(),...a,delay:-u,onUpdate:f=>{t.set(f),a.onUpdate&&a.onUpdate(f)},onComplete:()=>{o(),a.onComplete&&a.onComplete()},name:e,motionValue:t,element:s?void 0:i};Bx(a)||Object.assign(c,Ox(e,c)),c.duration&&(c.duration=dt(c.duration)),c.repeatDelay&&(c.repeatDelay=dt(c.repeatDelay)),c.from!==void 0&&(c.keyframes[0]=c.from);let h=!1;if((c.type===!1||c.duration===0&&!c.repeatDelay)&&($a(c),c.delay===0&&(h=!0)),(Pt.instantAnimations||Pt.skipAnimations)&&(h=!0,$a(c),c.delay=0),c.allowFlatten=!a.type&&!a.ease,h&&!s&&t.get()!==void 0){const f=Rx(c.keyframes,a);if(f!==void 0){Q.update(()=>{c.onUpdate(f),c.onComplete()});return}}return a.isSync?new fu(c):new av(c)};function zx({protectedKeys:e,needsAnimating:t},n){const r=e.hasOwnProperty(n)&&t[n]!==!0;return t[n]=!1,r}function Ep(e,t,{delay:n=0,transitionOverride:r,type:i}={}){let{transition:s=e.getDefaultTransition(),transitionEnd:o,...a}=t;r&&(s=r);const l=[],u=i&&e.animationState&&e.animationState.getState()[i];for(const c in a){const h=e.getValue(c,e.latestValues[c]??null),f=a[c];if(f===void 0||u&&zx(u,c))continue;const y={delay:n,...pu(s||{},c)},v=h.get();if(v!==void 0&&!h.isAnimating&&!Array.isArray(f)&&f===v&&!y.velocity)continue;let x=!1;if(window.MotionHandoffAnimation){const m=Np(e);if(m){const p=window.MotionHandoffAnimation(m,c,Q);p!==null&&(y.startTime=p,x=!0)}}Xa(e,c),h.start(Nu(c,h,f,e.shouldReduceMotion&&Y0.has(c)?{type:!1}:y,e,x));const P=h.animation;P&&l.push(P)}return o&&Promise.all(l).then(()=>{Q.update(()=>{o&&bx(e,o)})}),l}function Mp(e,t,n,r=0,i=1){const s=Array.from(e).sort((u,c)=>u.sortNodePosition(c)).indexOf(t),o=e.size,a=(o-1)*r;return typeof n=="function"?n(s,o):i===1?s*r:a-s*r}function Za(e,t,n={}){var l;const r=Kn(e,t,n.type==="exit"?(l=e.presenceContext)==null?void 0:l.custom:void 0);let{transition:i=e.getDefaultTransition()||{}}=r||{};n.transitionOverride&&(i=n.transitionOverride);const s=r?()=>Promise.all(Ep(e,r,n)):()=>Promise.resolve(),o=e.variantChildren&&e.variantChildren.size?(u=0)=>{const{delayChildren:c=0,staggerChildren:h,staggerDirection:f}=i;return Ux(e,t,u,c,h,f,n)}:()=>Promise.resolve(),{when:a}=i;if(a){const[u,c]=a==="beforeChildren"?[s,o]:[o,s];return u().then(()=>c())}else return Promise.all([s(),o(n.delay)])}function Ux(e,t,n=0,r=0,i=0,s=1,o){const a=[];for(const l of e.variantChildren)l.notify("AnimationStart",t),a.push(Za(l,t,{...o,delay:n+(typeof r=="function"?0:r)+Mp(e.variantChildren,l,r,i,s)}).then(()=>l.notify("AnimationComplete",t)));return Promise.all(a)}function $x(e,t,n={}){e.notify("AnimationStart",t);let r;if(Array.isArray(t)){const i=t.map(s=>Za(e,s,n));r=Promise.all(i)}else if(typeof t=="string")r=Za(e,t,n);else{const i=typeof t=="function"?Kn(e,t,n.custom):t;r=Promise.all(Ep(e,i,n))}return r.then(()=>{e.notify("AnimationComplete",t)})}function Dp(e,t){if(!Array.isArray(t))return!1;const n=t.length;if(n!==e.length)return!1;for(let r=0;rPromise.all(t.map(({animation:n,options:r})=>$x(e,n,r)))}function Yx(e){let t=Gx(e),n=yd(),r=!0;const i=l=>(u,c)=>{var f;const h=Kn(e,c,l==="exit"?(f=e.presenceContext)==null?void 0:f.custom:void 0);if(h){const{transition:y,transitionEnd:v,...x}=h;u={...u,...x,...v}}return u};function s(l){t=l(e)}function o(l){const{props:u}=e,c=bp(e.parent)||{},h=[],f=new Set;let y={},v=1/0;for(let P=0;Pv&&k,V=!1;const D=Array.isArray(g)?g:[g];let W=D.reduce(i(m),{});S===!1&&(W={});const{prevResolvedValues:Ce={}}=p,ze={...Ce,...W},U=X=>{j=!0,f.has(X)&&(V=!0,f.delete(X)),p.needsAnimating[X]=!0;const E=e.getValue(X);E&&(E.liveStyle=!1)};for(const X in ze){const E=W[X],L=Ce[X];if(y.hasOwnProperty(X))continue;let R=!1;Qa(E)&&Qa(L)?R=!Dp(E,L):R=E!==L,R?E!=null?U(X):f.add(X):E!==void 0&&f.has(X)?U(X):p.protectedKeys[X]=!0}p.prevProp=g,p.prevResolvedValues=W,p.isActive&&(y={...y,...W}),r&&e.blockInitialAnimation&&(j=!1);const O=T&&w;j&&(!O||V)&&h.push(...D.map(X=>{const E={type:m};if(typeof X=="string"&&r&&!O&&e.manuallyAnimateOnMount&&e.parent){const{parent:L}=e,R=Kn(L,X);if(L.enteringChildren&&R){const{delayChildren:H}=R.transition||{};E.delay=Mp(L.enteringChildren,e,H)}}return{animation:X,options:E}}))}if(f.size){const P={};if(typeof u.initial!="boolean"){const m=Kn(e,Array.isArray(u.initial)?u.initial[0]:u.initial);m&&m.transition&&(P.transition=m.transition)}f.forEach(m=>{const p=e.getBaseTarget(m),g=e.getValue(m);g&&(g.liveStyle=!0),P[m]=p??null}),h.push({animation:P})}let x=!!h.length;return r&&(u.initial===!1||u.initial===u.animate)&&!e.manuallyAnimateOnMount&&(x=!1),r=!1,x?t(h):Promise.resolve()}function a(l,u){var h;if(n[l].isActive===u)return Promise.resolve();(h=e.variantChildren)==null||h.forEach(f=>{var y;return(y=f.animationState)==null?void 0:y.setActive(l,u)}),n[l].isActive=u;const c=o(l);for(const f in n)n[f].protectedKeys={};return c}return{animateChanges:o,setActive:a,setAnimateFunction:s,getState:()=>n,reset:()=>{n=yd()}}}function Qx(e,t){return typeof t=="string"?t!==e:Array.isArray(t)?!Dp(t,e):!1}function Jt(e=!1){return{isActive:e,protectedKeys:{},needsAnimating:{},prevResolvedValues:{}}}function yd(){return{animate:Jt(!0),whileInView:Jt(),whileHover:Jt(),whileTap:Jt(),whileDrag:Jt(),whileFocus:Jt(),exit:Jt()}}class Zt{constructor(t){this.isMounted=!1,this.node=t}update(){}}class Xx extends Zt{constructor(t){super(t),t.animationState||(t.animationState=Yx(t))}updateAnimationControlsSubscription(){const{animate:t}=this.node.getProps();Gs(t)&&(this.unmountControls=t.subscribe(this.node))}mount(){this.updateAnimationControlsSubscription()}update(){const{animate:t}=this.node.getProps(),{animate:n}=this.node.prevProps||{};t!==n&&this.updateAnimationControlsSubscription()}unmount(){var t;this.node.animationState.reset(),(t=this.unmountControls)==null||t.call(this)}}let Zx=0;class qx extends Zt{constructor(){super(...arguments),this.id=Zx++}update(){if(!this.node.presenceContext)return;const{isPresent:t,onExitComplete:n}=this.node.presenceContext,{isPresent:r}=this.node.prevPresenceContext||{};if(!this.node.animationState||t===r)return;const i=this.node.animationState.setActive("exit",!t);n&&!t&&i.then(()=>{n(this.id)})}mount(){const{register:t,onExitComplete:n}=this.node.presenceContext||{};n&&n(this.id),t&&(this.unmount=t(this.id))}unmount(){}}const Jx={animation:{Feature:Xx},exit:{Feature:qx}};function si(e,t,n,r={passive:!0}){return e.addEventListener(t,n,r),()=>e.removeEventListener(t,n)}function pi(e){return{point:{x:e.pageX,y:e.pageY}}}const e2=e=>t=>yu(t)&&e(t,pi(t));function Vr(e,t,n,r){return si(e,t,e2(n),r)}const Lp=1e-4,t2=1-Lp,n2=1+Lp,Ap=.01,r2=0-Ap,i2=0+Ap;function Te(e){return e.max-e.min}function s2(e,t,n){return Math.abs(e-t)<=n}function vd(e,t,n,r=.5){e.origin=r,e.originPoint=q(t.min,t.max,e.origin),e.scale=Te(n)/Te(t),e.translate=q(n.min,n.max,e.origin)-e.originPoint,(e.scale>=t2&&e.scale<=n2||isNaN(e.scale))&&(e.scale=1),(e.translate>=r2&&e.translate<=i2||isNaN(e.translate))&&(e.translate=0)}function Ir(e,t,n,r){vd(e.x,t.x,n.x,r?r.originX:void 0),vd(e.y,t.y,n.y,r?r.originY:void 0)}function xd(e,t,n){e.min=n.min+t.min,e.max=e.min+Te(t)}function o2(e,t,n){xd(e.x,t.x,n.x),xd(e.y,t.y,n.y)}function wd(e,t,n){e.min=t.min-n.min,e.max=e.min+Te(t)}function Es(e,t,n){wd(e.x,t.x,n.x),wd(e.y,t.y,n.y)}function Ue(e){return[e("x"),e("y")]}const Rp=({current:e})=>e?e.ownerDocument.defaultView:null,kd=(e,t)=>Math.abs(e-t);function a2(e,t){const n=kd(e.x,t.x),r=kd(e.y,t.y);return Math.sqrt(n**2+r**2)}class Vp{constructor(t,n,{transformPagePoint:r,contextWindow:i=window,dragSnapToOrigin:s=!1,distanceThreshold:o=3}={}){if(this.startEvent=null,this.lastMoveEvent=null,this.lastMoveEventInfo=null,this.handlers={},this.contextWindow=window,this.updatePoint=()=>{if(!(this.lastMoveEvent&&this.lastMoveEventInfo))return;const f=bo(this.lastMoveEventInfo,this.history),y=this.startEvent!==null,v=a2(f.offset,{x:0,y:0})>=this.distanceThreshold;if(!y&&!v)return;const{point:x}=f,{timestamp:P}=pe;this.history.push({...x,timestamp:P});const{onStart:m,onMove:p}=this.handlers;y||(m&&m(this.lastMoveEvent,f),this.startEvent=this.lastMoveEvent),p&&p(this.lastMoveEvent,f)},this.handlePointerMove=(f,y)=>{this.lastMoveEvent=f,this.lastMoveEventInfo=Do(y,this.transformPagePoint),Q.update(this.updatePoint,!0)},this.handlePointerUp=(f,y)=>{this.end();const{onEnd:v,onSessionEnd:x,resumeAnimation:P}=this.handlers;if(this.dragSnapToOrigin&&P&&P(),!(this.lastMoveEvent&&this.lastMoveEventInfo))return;const m=bo(f.type==="pointercancel"?this.lastMoveEventInfo:Do(y,this.transformPagePoint),this.history);this.startEvent&&v&&v(f,m),x&&x(f,m)},!yu(t))return;this.dragSnapToOrigin=s,this.handlers=n,this.transformPagePoint=r,this.distanceThreshold=o,this.contextWindow=i||window;const a=pi(t),l=Do(a,this.transformPagePoint),{point:u}=l,{timestamp:c}=pe;this.history=[{...u,timestamp:c}];const{onSessionStart:h}=n;h&&h(t,bo(l,this.history)),this.removeListeners=di(Vr(this.contextWindow,"pointermove",this.handlePointerMove),Vr(this.contextWindow,"pointerup",this.handlePointerUp),Vr(this.contextWindow,"pointercancel",this.handlePointerUp))}updateHandlers(t){this.handlers=t}end(){this.removeListeners&&this.removeListeners(),Kt(this.updatePoint)}}function Do(e,t){return t?{point:t(e.point)}:e}function Sd(e,t){return{x:e.x-t.x,y:e.y-t.y}}function bo({point:e},t){return{point:e,delta:Sd(e,Ip(t)),offset:Sd(e,l2(t)),velocity:u2(t,.1)}}function l2(e){return e[0]}function Ip(e){return e[e.length-1]}function u2(e,t){if(e.length<2)return{x:0,y:0};let n=e.length-1,r=null;const i=Ip(e);for(;n>=0&&(r=e[n],!(i.timestamp-r.timestamp>dt(t)));)n--;if(!r)return{x:0,y:0};const s=Ke(i.timestamp-r.timestamp);if(s===0)return{x:0,y:0};const o={x:(i.x-r.x)/s,y:(i.y-r.y)/s};return o.x===1/0&&(o.x=0),o.y===1/0&&(o.y=0),o}function c2(e,{min:t,max:n},r){return t!==void 0&&en&&(e=r?q(n,e,r.max):Math.min(e,n)),e}function Cd(e,t,n){return{min:t!==void 0?e.min+t:void 0,max:n!==void 0?e.max+n-(e.max-e.min):void 0}}function d2(e,{top:t,left:n,bottom:r,right:i}){return{x:Cd(e.x,n,i),y:Cd(e.y,t,r)}}function jd(e,t){let n=t.min-e.min,r=t.max-e.max;return t.max-t.minr?n=ei(t.min,t.max-r,e.min):r>i&&(n=ei(e.min,e.max-i,t.min)),Tt(0,1,n)}function p2(e,t){const n={};return t.min!==void 0&&(n.min=t.min-e.min),t.max!==void 0&&(n.max=t.max-e.min),n}const qa=.35;function m2(e=qa){return e===!1?e=0:e===!0&&(e=qa),{x:Td(e,"left","right"),y:Td(e,"top","bottom")}}function Td(e,t,n){return{min:Pd(e,t),max:Pd(e,n)}}function Pd(e,t){return typeof e=="number"?e:e[t]||0}const g2=new WeakMap;class y2{constructor(t){this.openDragLock=null,this.isDragging=!1,this.currentDirection=null,this.originPoint={x:0,y:0},this.constraints=!1,this.hasMutatedConstraints=!1,this.elastic=ae(),this.latestPointerEvent=null,this.latestPanInfo=null,this.visualElement=t}start(t,{snapToCursor:n=!1,distanceThreshold:r}={}){const{presenceContext:i}=this.visualElement;if(i&&i.isPresent===!1)return;const s=h=>{const{dragSnapToOrigin:f}=this.getProps();f?this.pauseAnimation():this.stopAnimation(),n&&this.snapToCursor(pi(h).point)},o=(h,f)=>{const{drag:y,dragPropagation:v,onDragStart:x}=this.getProps();if(y&&!v&&(this.openDragLock&&this.openDragLock(),this.openDragLock=Cv(y),!this.openDragLock))return;this.latestPointerEvent=h,this.latestPanInfo=f,this.isDragging=!0,this.currentDirection=null,this.resolveConstraints(),this.visualElement.projection&&(this.visualElement.projection.isAnimationBlocked=!0,this.visualElement.projection.target=void 0),Ue(m=>{let p=this.getAxisMotionValue(m).get()||0;if(ft.test(p)){const{projection:g}=this.visualElement;if(g&&g.layout){const k=g.layout.layoutBox[m];k&&(p=Te(k)*(parseFloat(p)/100))}}this.originPoint[m]=p}),x&&Q.postRender(()=>x(h,f)),Xa(this.visualElement,"transform");const{animationState:P}=this.visualElement;P&&P.setActive("whileDrag",!0)},a=(h,f)=>{this.latestPointerEvent=h,this.latestPanInfo=f;const{dragPropagation:y,dragDirectionLock:v,onDirectionLock:x,onDrag:P}=this.getProps();if(!y&&!this.openDragLock)return;const{offset:m}=f;if(v&&this.currentDirection===null){this.currentDirection=v2(m),this.currentDirection!==null&&x&&x(this.currentDirection);return}this.updateAxis("x",f.point,m),this.updateAxis("y",f.point,m),this.visualElement.render(),P&&P(h,f)},l=(h,f)=>{this.latestPointerEvent=h,this.latestPanInfo=f,this.stop(h,f),this.latestPointerEvent=null,this.latestPanInfo=null},u=()=>Ue(h=>{var f;return this.getAnimationState(h)==="paused"&&((f=this.getAxisMotionValue(h).animation)==null?void 0:f.play())}),{dragSnapToOrigin:c}=this.getProps();this.panSession=new Vp(t,{onSessionStart:s,onStart:o,onMove:a,onSessionEnd:l,resumeAnimation:u},{transformPagePoint:this.visualElement.getTransformPagePoint(),dragSnapToOrigin:c,distanceThreshold:r,contextWindow:Rp(this.visualElement)})}stop(t,n){const r=t||this.latestPointerEvent,i=n||this.latestPanInfo,s=this.isDragging;if(this.cancel(),!s||!i||!r)return;const{velocity:o}=i;this.startAnimation(o);const{onDragEnd:a}=this.getProps();a&&Q.postRender(()=>a(r,i))}cancel(){this.isDragging=!1;const{projection:t,animationState:n}=this.visualElement;t&&(t.isAnimationBlocked=!1),this.panSession&&this.panSession.end(),this.panSession=void 0;const{dragPropagation:r}=this.getProps();!r&&this.openDragLock&&(this.openDragLock(),this.openDragLock=null),n&&n.setActive("whileDrag",!1)}updateAxis(t,n,r){const{drag:i}=this.getProps();if(!r||!Vi(t,i,this.currentDirection))return;const s=this.getAxisMotionValue(t);let o=this.originPoint[t]+r[t];this.constraints&&this.constraints[t]&&(o=c2(o,this.constraints[t],this.elastic[t])),s.set(o)}resolveConstraints(){var s;const{dragConstraints:t,dragElastic:n}=this.getProps(),r=this.visualElement.projection&&!this.visualElement.projection.layout?this.visualElement.projection.measure(!1):(s=this.visualElement.projection)==null?void 0:s.layout,i=this.constraints;t&&In(t)?this.constraints||(this.constraints=this.resolveRefConstraints()):t&&r?this.constraints=d2(r.layoutBox,t):this.constraints=!1,this.elastic=m2(n),i!==this.constraints&&r&&this.constraints&&!this.hasMutatedConstraints&&Ue(o=>{this.constraints!==!1&&this.getAxisMotionValue(o)&&(this.constraints[o]=p2(r.layoutBox[o],this.constraints[o]))})}resolveRefConstraints(){const{dragConstraints:t,onMeasureDragConstraints:n}=this.getProps();if(!t||!In(t))return!1;const r=t.current,{projection:i}=this.visualElement;if(!i||!i.layout)return!1;const s=xx(r,i.root,this.visualElement.getTransformPagePoint());let o=f2(i.layout.layoutBox,s);if(n){const a=n(gx(o));this.hasMutatedConstraints=!!a,a&&(o=xp(a))}return o}startAnimation(t){const{drag:n,dragMomentum:r,dragElastic:i,dragTransition:s,dragSnapToOrigin:o,onDragTransitionEnd:a}=this.getProps(),l=this.constraints||{},u=Ue(c=>{if(!Vi(c,n,this.currentDirection))return;let h=l&&l[c]||{};o&&(h={min:0,max:0});const f=i?200:1e6,y=i?40:1e7,v={type:"inertia",velocity:r?t[c]:0,bounceStiffness:f,bounceDamping:y,timeConstant:750,restDelta:1,restSpeed:10,...s,...h};return this.startAxisValueAnimation(c,v)});return Promise.all(u).then(a)}startAxisValueAnimation(t,n){const r=this.getAxisMotionValue(t);return Xa(this.visualElement,t),r.start(Nu(t,r,0,n,this.visualElement,!1))}stopAnimation(){Ue(t=>this.getAxisMotionValue(t).stop())}pauseAnimation(){Ue(t=>{var n;return(n=this.getAxisMotionValue(t).animation)==null?void 0:n.pause()})}getAnimationState(t){var n;return(n=this.getAxisMotionValue(t).animation)==null?void 0:n.state}getAxisMotionValue(t){const n=`_drag${t.toUpperCase()}`,r=this.visualElement.getProps(),i=r[n];return i||this.visualElement.getValue(t,(r.initial?r.initial[t]:void 0)||0)}snapToCursor(t){Ue(n=>{const{drag:r}=this.getProps();if(!Vi(n,r,this.currentDirection))return;const{projection:i}=this.visualElement,s=this.getAxisMotionValue(n);if(i&&i.layout){const{min:o,max:a}=i.layout.layoutBox[n];s.set(t[n]-q(o,a,.5))}})}scalePositionWithinConstraints(){if(!this.visualElement.current)return;const{drag:t,dragConstraints:n}=this.getProps(),{projection:r}=this.visualElement;if(!In(n)||!r||!this.constraints)return;this.stopAnimation();const i={x:0,y:0};Ue(o=>{const a=this.getAxisMotionValue(o);if(a&&this.constraints!==!1){const l=a.get();i[o]=h2({min:l,max:l},this.constraints[o])}});const{transformTemplate:s}=this.visualElement.getProps();this.visualElement.current.style.transform=s?s({},""):"none",r.root&&r.root.updateScroll(),r.updateLayout(),this.resolveConstraints(),Ue(o=>{if(!Vi(o,t,null))return;const a=this.getAxisMotionValue(o),{min:l,max:u}=this.constraints[o];a.set(q(l,u,i[o]))})}addListeners(){if(!this.visualElement.current)return;g2.set(this.visualElement,this);const t=this.visualElement.current,n=Vr(t,"pointerdown",l=>{const{drag:u,dragListener:c=!0}=this.getProps();u&&c&&this.start(l)}),r=()=>{const{dragConstraints:l}=this.getProps();In(l)&&l.current&&(this.constraints=this.resolveRefConstraints())},{projection:i}=this.visualElement,s=i.addEventListener("measure",r);i&&!i.layout&&(i.root&&i.root.updateScroll(),i.updateLayout()),Q.read(r);const o=si(window,"resize",()=>this.scalePositionWithinConstraints()),a=i.addEventListener("didUpdate",({delta:l,hasLayoutChanged:u})=>{this.isDragging&&u&&(Ue(c=>{const h=this.getAxisMotionValue(c);h&&(this.originPoint[c]+=l[c].translate,h.set(h.get()+l[c].translate))}),this.visualElement.render())});return()=>{o(),n(),s(),a&&a()}}getProps(){const t=this.visualElement.getProps(),{drag:n=!1,dragDirectionLock:r=!1,dragPropagation:i=!1,dragConstraints:s=!1,dragElastic:o=qa,dragMomentum:a=!0}=t;return{...t,drag:n,dragDirectionLock:r,dragPropagation:i,dragConstraints:s,dragElastic:o,dragMomentum:a}}}function Vi(e,t,n){return(t===!0||t===e)&&(n===null||n===e)}function v2(e,t=10){let n=null;return Math.abs(e.y)>t?n="y":Math.abs(e.x)>t&&(n="x"),n}class x2 extends Zt{constructor(t){super(t),this.removeGroupControls=Ye,this.removeListeners=Ye,this.controls=new y2(t)}mount(){const{dragControls:t}=this.node.getProps();t&&(this.removeGroupControls=t.subscribe(this.controls)),this.removeListeners=this.controls.addListeners()||Ye}unmount(){this.removeGroupControls(),this.removeListeners()}}const Nd=e=>(t,n)=>{e&&Q.postRender(()=>e(t,n))};class w2 extends Zt{constructor(){super(...arguments),this.removePointerDownListener=Ye}onPointerDown(t){this.session=new Vp(t,this.createPanHandlers(),{transformPagePoint:this.node.getTransformPagePoint(),contextWindow:Rp(this.node)})}createPanHandlers(){const{onPanSessionStart:t,onPanStart:n,onPan:r,onPanEnd:i}=this.node.getProps();return{onSessionStart:Nd(t),onStart:Nd(n),onMove:r,onEnd:(s,o)=>{delete this.session,i&&Q.postRender(()=>i(s,o))}}}mount(){this.removePointerDownListener=Vr(this.node.current,"pointerdown",t=>this.onPointerDown(t))}update(){this.session&&this.session.updateHandlers(this.createPanHandlers())}unmount(){this.removePointerDownListener(),this.session&&this.session.end()}}const qi={hasAnimatedSinceResize:!0,hasEverUpdated:!1};function Ed(e,t){return t.max===t.min?0:e/(t.max-t.min)*100}const yr={correct:(e,t)=>{if(!t.target)return e;if(typeof e=="string")if(A.test(e))e=parseFloat(e);else return e;const n=Ed(e,t.target.x),r=Ed(e,t.target.y);return`${n}% ${r}%`}},k2={correct:(e,{treeScale:t,projectionDelta:n})=>{const r=e,i=Gt.parse(e);if(i.length>5)return r;const s=Gt.createTransformer(e),o=typeof i[0]!="number"?1:0,a=n.x.scale*t.x,l=n.y.scale*t.y;i[0+o]/=a,i[1+o]/=l;const u=q(a,l,.5);return typeof i[2+o]=="number"&&(i[2+o]/=u),typeof i[3+o]=="number"&&(i[3+o]/=u),s(i)}};let Lo=!1;class S2 extends C.Component{componentDidMount(){const{visualElement:t,layoutGroup:n,switchLayoutGroup:r,layoutId:i}=this.props,{projection:s}=t;Wv(C2),s&&(n.group&&n.group.add(s),r&&r.register&&i&&r.register(s),Lo&&s.root.didUpdate(),s.addEventListener("animationComplete",()=>{this.safeToRemove()}),s.setOptions({...s.options,onExitComplete:()=>this.safeToRemove()})),qi.hasEverUpdated=!0}getSnapshotBeforeUpdate(t){const{layoutDependency:n,visualElement:r,drag:i,isPresent:s}=this.props,{projection:o}=r;return o&&(o.isPresent=s,Lo=!0,i||t.layoutDependency!==n||n===void 0||t.isPresent!==s?o.willUpdate():this.safeToRemove(),t.isPresent!==s&&(s?o.promote():o.relegate()||Q.postRender(()=>{const a=o.getStack();(!a||!a.members.length)&&this.safeToRemove()}))),null}componentDidUpdate(){const{projection:t}=this.props.visualElement;t&&(t.root.didUpdate(),gu.postRender(()=>{!t.currentAnimation&&t.isLead()&&this.safeToRemove()}))}componentWillUnmount(){const{visualElement:t,layoutGroup:n,switchLayoutGroup:r}=this.props,{projection:i}=t;Lo=!0,i&&(i.scheduleCheckAfterUnmount(),n&&n.group&&n.group.remove(i),r&&r.deregister&&r.deregister(i))}safeToRemove(){const{safeToRemove:t}=this.props;t&&t()}render(){return null}}function _p(e){const[t,n]=sp(),r=C.useContext(Yl);return d.jsx(S2,{...e,layoutGroup:r,switchLayoutGroup:C.useContext(yp),isPresent:t,safeToRemove:n})}const C2={borderRadius:{...yr,applyTo:["borderTopLeftRadius","borderTopRightRadius","borderBottomLeftRadius","borderBottomRightRadius"]},borderTopLeftRadius:yr,borderTopRightRadius:yr,borderBottomLeftRadius:yr,borderBottomRightRadius:yr,boxShadow:k2};function j2(e,t,n){const r=ke(e)?e:er(e);return r.start(Nu("",r,t,n)),r.animation}const T2=(e,t)=>e.depth-t.depth;class P2{constructor(){this.children=[],this.isDirty=!1}add(t){Zl(this.children,t),this.isDirty=!0}remove(t){ql(this.children,t),this.isDirty=!0}forEach(t){this.isDirty&&this.children.sort(T2),this.isDirty=!1,this.children.forEach(t)}}function N2(e,t){const n=be.now(),r=({timestamp:i})=>{const s=i-n;s>=t&&(Kt(r),e(s-t))};return Q.setup(r,!0),()=>Kt(r)}const Fp=["TopLeft","TopRight","BottomLeft","BottomRight"],E2=Fp.length,Md=e=>typeof e=="string"?parseFloat(e):e,Dd=e=>typeof e=="number"||A.test(e);function M2(e,t,n,r,i,s){i?(e.opacity=q(0,n.opacity??1,D2(r)),e.opacityExit=q(t.opacity??1,0,b2(r))):s&&(e.opacity=q(t.opacity??1,n.opacity??1,r));for(let o=0;ort?1:n(ei(e,t,r))}function Ld(e,t){e.min=t.min,e.max=t.max}function qe(e,t){Ld(e.x,t.x),Ld(e.y,t.y)}function Ad(e,t){e.translate=t.translate,e.scale=t.scale,e.originPoint=t.originPoint,e.origin=t.origin}function Rd(e,t,n,r,i){return e-=t,e=Ns(e,1/n,r),i!==void 0&&(e=Ns(e,1/i,r)),e}function L2(e,t=0,n=1,r=.5,i,s=e,o=e){if(ft.test(t)&&(t=parseFloat(t),t=q(o.min,o.max,t/100)-o.min),typeof t!="number")return;let a=q(s.min,s.max,r);e===s&&(a-=t),e.min=Rd(e.min,t,n,a,i),e.max=Rd(e.max,t,n,a,i)}function Vd(e,t,[n,r,i],s,o){L2(e,t[n],t[r],t[i],t.scale,s,o)}const A2=["x","scaleX","originX"],R2=["y","scaleY","originY"];function Id(e,t,n,r){Vd(e.x,t,A2,n?n.x:void 0,r?r.x:void 0),Vd(e.y,t,R2,n?n.y:void 0,r?r.y:void 0)}function _d(e){return e.translate===0&&e.scale===1}function Bp(e){return _d(e.x)&&_d(e.y)}function Fd(e,t){return e.min===t.min&&e.max===t.max}function V2(e,t){return Fd(e.x,t.x)&&Fd(e.y,t.y)}function Od(e,t){return Math.round(e.min)===Math.round(t.min)&&Math.round(e.max)===Math.round(t.max)}function zp(e,t){return Od(e.x,t.x)&&Od(e.y,t.y)}function Bd(e){return Te(e.x)/Te(e.y)}function zd(e,t){return e.translate===t.translate&&e.scale===t.scale&&e.originPoint===t.originPoint}class I2{constructor(){this.members=[]}add(t){Zl(this.members,t),t.scheduleRender()}remove(t){if(ql(this.members,t),t===this.prevLead&&(this.prevLead=void 0),t===this.lead){const n=this.members[this.members.length-1];n&&this.promote(n)}}relegate(t){const n=this.members.findIndex(i=>t===i);if(n===0)return!1;let r;for(let i=n;i>=0;i--){const s=this.members[i];if(s.isPresent!==!1){r=s;break}}return r?(this.promote(r),!0):!1}promote(t,n){const r=this.lead;if(t!==r&&(this.prevLead=r,this.lead=t,t.show(),r)){r.instance&&r.scheduleRender(),t.scheduleRender(),t.resumeFrom=r,n&&(t.resumeFrom.preserveOpacity=!0),r.snapshot&&(t.snapshot=r.snapshot,t.snapshot.latestValues=r.animationValues||r.latestValues),t.root&&t.root.isUpdating&&(t.isLayoutDirty=!0);const{crossfade:i}=t.options;i===!1&&r.hide()}}exitAnimationComplete(){this.members.forEach(t=>{const{options:n,resumingFrom:r}=t;n.onExitComplete&&n.onExitComplete(),r&&r.options.onExitComplete&&r.options.onExitComplete()})}scheduleRender(){this.members.forEach(t=>{t.instance&&t.scheduleRender(!1)})}removeLeadSnapshot(){this.lead&&this.lead.snapshot&&(this.lead.snapshot=void 0)}}function _2(e,t,n){let r="";const i=e.x.translate/t.x,s=e.y.translate/t.y,o=(n==null?void 0:n.z)||0;if((i||s||o)&&(r=`translate3d(${i}px, ${s}px, ${o}px) `),(t.x!==1||t.y!==1)&&(r+=`scale(${1/t.x}, ${1/t.y}) `),n){const{transformPerspective:u,rotate:c,rotateX:h,rotateY:f,skewX:y,skewY:v}=n;u&&(r=`perspective(${u}px) ${r}`),c&&(r+=`rotate(${c}deg) `),h&&(r+=`rotateX(${h}deg) `),f&&(r+=`rotateY(${f}deg) `),y&&(r+=`skewX(${y}deg) `),v&&(r+=`skewY(${v}deg) `)}const a=e.x.scale*t.x,l=e.y.scale*t.y;return(a!==1||l!==1)&&(r+=`scale(${a}, ${l})`),r||"none"}const Ao=["","X","Y","Z"],F2=1e3;let O2=0;function Ro(e,t,n,r){const{latestValues:i}=t;i[e]&&(n[e]=i[e],t.setStaticValue(e,0),r&&(r[e]=0))}function Up(e){if(e.hasCheckedOptimisedAppear=!0,e.root===e)return;const{visualElement:t}=e.options;if(!t)return;const n=Np(t);if(window.MotionHasOptimisedAnimation(n,"transform")){const{layout:i,layoutId:s}=e.options;window.MotionCancelOptimisedAnimation(n,"transform",Q,!(i||s))}const{parent:r}=e;r&&!r.hasCheckedOptimisedAppear&&Up(r)}function $p({attachResizeListener:e,defaultParent:t,measureScroll:n,checkIsScrollRoot:r,resetTransform:i}){return class{constructor(o={},a=t==null?void 0:t()){this.id=O2++,this.animationId=0,this.animationCommitId=0,this.children=new Set,this.options={},this.isTreeAnimating=!1,this.isAnimationBlocked=!1,this.isLayoutDirty=!1,this.isProjectionDirty=!1,this.isSharedProjectionDirty=!1,this.isTransformDirty=!1,this.updateManuallyBlocked=!1,this.updateBlockedByResize=!1,this.isUpdating=!1,this.isSVG=!1,this.needsReset=!1,this.shouldResetTransform=!1,this.hasCheckedOptimisedAppear=!1,this.treeScale={x:1,y:1},this.eventHandlers=new Map,this.hasTreeAnimated=!1,this.layoutVersion=0,this.updateScheduled=!1,this.scheduleUpdate=()=>this.update(),this.projectionUpdateScheduled=!1,this.checkUpdateFailed=()=>{this.isUpdating&&(this.isUpdating=!1,this.clearAllSnapshots())},this.updateProjection=()=>{this.projectionUpdateScheduled=!1,this.nodes.forEach(U2),this.nodes.forEach(K2),this.nodes.forEach(G2),this.nodes.forEach($2)},this.resolvedRelativeTargetAt=0,this.linkedParentVersion=0,this.hasProjected=!1,this.isVisible=!0,this.animationProgress=0,this.sharedNodes=new Map,this.latestValues=o,this.root=a?a.root||a:this,this.path=a?[...a.path,a]:[],this.parent=a,this.depth=a?a.depth+1:0;for(let l=0;lthis.root.updateBlockedByResize=!1;Q.read(()=>{h=window.innerWidth}),e(o,()=>{const y=window.innerWidth;y!==h&&(h=y,this.root.updateBlockedByResize=!0,c&&c(),c=N2(f,250),qi.hasAnimatedSinceResize&&(qi.hasAnimatedSinceResize=!1,this.nodes.forEach(Wd)))})}a&&this.root.registerSharedNode(a,this),this.options.animate!==!1&&u&&(a||l)&&this.addEventListener("didUpdate",({delta:c,hasLayoutChanged:h,hasRelativeLayoutChanged:f,layout:y})=>{if(this.isTreeAnimationBlocked()){this.target=void 0,this.relativeTarget=void 0;return}const v=this.options.transition||u.getDefaultTransition()||q2,{onLayoutAnimationStart:x,onLayoutAnimationComplete:P}=u.getProps(),m=!this.targetLayout||!zp(this.targetLayout,y),p=!h&&f;if(this.options.layoutRoot||this.resumeFrom||p||h&&(m||!this.currentAnimation)){this.resumeFrom&&(this.resumingFrom=this.resumeFrom,this.resumingFrom.resumingFrom=void 0);const g={...pu(v,"layout"),onPlay:x,onComplete:P};(u.shouldReduceMotion||this.options.layoutRoot)&&(g.delay=0,g.type=!1),this.startAnimation(g),this.setAnimationOrigin(c,p)}else h||Wd(this),this.isLead()&&this.options.onExitComplete&&this.options.onExitComplete();this.targetLayout=y})}unmount(){this.options.layoutId&&this.willUpdate(),this.root.nodes.remove(this);const o=this.getStack();o&&o.remove(this),this.parent&&this.parent.children.delete(this),this.instance=void 0,this.eventHandlers.clear(),Kt(this.updateProjection)}blockUpdate(){this.updateManuallyBlocked=!0}unblockUpdate(){this.updateManuallyBlocked=!1}isUpdateBlocked(){return this.updateManuallyBlocked||this.updateBlockedByResize}isTreeAnimationBlocked(){return this.isAnimationBlocked||this.parent&&this.parent.isTreeAnimationBlocked()||!1}startUpdate(){this.isUpdateBlocked()||(this.isUpdating=!0,this.nodes&&this.nodes.forEach(Y2),this.animationId++)}getTransformTemplate(){const{visualElement:o}=this.options;return o&&o.getProps().transformTemplate}willUpdate(o=!0){if(this.root.hasTreeAnimated=!0,this.root.isUpdateBlocked()){this.options.onExitComplete&&this.options.onExitComplete();return}if(window.MotionCancelOptimisedAnimation&&!this.hasCheckedOptimisedAppear&&Up(this),!this.root.isUpdating&&this.root.startUpdate(),this.isLayoutDirty)return;this.isLayoutDirty=!0;for(let c=0;c{this.isLayoutDirty?this.root.didUpdate():this.root.checkUpdateFailed()})}updateSnapshot(){this.snapshot||!this.instance||(this.snapshot=this.measure(),this.snapshot&&!Te(this.snapshot.measuredBox.x)&&!Te(this.snapshot.measuredBox.y)&&(this.snapshot=void 0))}updateLayout(){if(!this.instance||(this.updateScroll(),!(this.options.alwaysMeasureLayout&&this.isLead())&&!this.isLayoutDirty))return;if(this.resumeFrom&&!this.resumeFrom.instance)for(let l=0;l{const S=k/1e3;Hd(h.x,o.x,S),Hd(h.y,o.y,S),this.setTargetDelta(h),this.relativeTarget&&this.relativeTargetOrigin&&this.layout&&this.relativeParent&&this.relativeParent.layout&&(Es(f,this.layout.layoutBox,this.relativeParent.layout.layoutBox),X2(this.relativeTarget,this.relativeTargetOrigin,f,S),g&&V2(this.relativeTarget,g)&&(this.isProjectionDirty=!1),g||(g=ae()),qe(g,this.relativeTarget)),x&&(this.animationValues=c,M2(c,u,this.latestValues,S,p,m)),this.root.scheduleUpdateProjection(),this.scheduleRender(),this.animationProgress=S},this.mixTargetDelta(this.options.layoutRoot?1e3:0)}startAnimation(o){var a,l,u;this.notifyListeners("animationStart"),(a=this.currentAnimation)==null||a.stop(),(u=(l=this.resumingFrom)==null?void 0:l.currentAnimation)==null||u.stop(),this.pendingAnimation&&(Kt(this.pendingAnimation),this.pendingAnimation=void 0),this.pendingAnimation=Q.update(()=>{qi.hasAnimatedSinceResize=!0,this.motionValue||(this.motionValue=er(0)),this.currentAnimation=j2(this.motionValue,[0,1e3],{...o,velocity:0,isSync:!0,onUpdate:c=>{this.mixTargetDelta(c),o.onUpdate&&o.onUpdate(c)},onStop:()=>{},onComplete:()=>{o.onComplete&&o.onComplete(),this.completeAnimation()}}),this.resumingFrom&&(this.resumingFrom.currentAnimation=this.currentAnimation),this.pendingAnimation=void 0})}completeAnimation(){this.resumingFrom&&(this.resumingFrom.currentAnimation=void 0,this.resumingFrom.preserveOpacity=void 0);const o=this.getStack();o&&o.exitAnimationComplete(),this.resumingFrom=this.currentAnimation=this.animationValues=void 0,this.notifyListeners("animationComplete")}finishAnimation(){this.currentAnimation&&(this.mixTargetDelta&&this.mixTargetDelta(F2),this.currentAnimation.stop()),this.completeAnimation()}applyTransformsToTarget(){const o=this.getLead();let{targetWithTransforms:a,target:l,layout:u,latestValues:c}=o;if(!(!a||!l||!u)){if(this!==o&&this.layout&&u&&Wp(this.options.animationType,this.layout.layoutBox,u.layoutBox)){l=this.target||ae();const h=Te(this.layout.layoutBox.x);l.x.min=o.target.x.min,l.x.max=l.x.min+h;const f=Te(this.layout.layoutBox.y);l.y.min=o.target.y.min,l.y.max=l.y.min+f}qe(a,l),Fn(a,c),Ir(this.projectionDeltaWithTransform,this.layoutCorrected,a,c)}}registerSharedNode(o,a){this.sharedNodes.has(o)||this.sharedNodes.set(o,new I2),this.sharedNodes.get(o).add(a);const u=a.options.initialPromotionConfig;a.promote({transition:u?u.transition:void 0,preserveFollowOpacity:u&&u.shouldPreserveFollowOpacity?u.shouldPreserveFollowOpacity(a):void 0})}isLead(){const o=this.getStack();return o?o.lead===this:!0}getLead(){var a;const{layoutId:o}=this.options;return o?((a=this.getStack())==null?void 0:a.lead)||this:this}getPrevLead(){var a;const{layoutId:o}=this.options;return o?(a=this.getStack())==null?void 0:a.prevLead:void 0}getStack(){const{layoutId:o}=this.options;if(o)return this.root.sharedNodes.get(o)}promote({needsReset:o,transition:a,preserveFollowOpacity:l}={}){const u=this.getStack();u&&u.promote(this,l),o&&(this.projectionDelta=void 0,this.needsReset=!0),a&&this.setOptions({transition:a})}relegate(){const o=this.getStack();return o?o.relegate(this):!1}resetSkewAndRotation(){const{visualElement:o}=this.options;if(!o)return;let a=!1;const{latestValues:l}=o;if((l.z||l.rotate||l.rotateX||l.rotateY||l.rotateZ||l.skewX||l.skewY)&&(a=!0),!a)return;const u={};l.z&&Ro("z",o,u,this.animationValues);for(let c=0;c{var a;return(a=o.currentAnimation)==null?void 0:a.stop()}),this.root.nodes.forEach(Ud),this.root.sharedNodes.clear()}}}function B2(e){e.updateLayout()}function z2(e){var n;const t=((n=e.resumeFrom)==null?void 0:n.snapshot)||e.snapshot;if(e.isLead()&&e.layout&&t&&e.hasListeners("didUpdate")){const{layoutBox:r,measuredBox:i}=e.layout,{animationType:s}=e.options,o=t.source!==e.layout.source;s==="size"?Ue(h=>{const f=o?t.measuredBox[h]:t.layoutBox[h],y=Te(f);f.min=r[h].min,f.max=f.min+y}):Wp(s,t.layoutBox,r)&&Ue(h=>{const f=o?t.measuredBox[h]:t.layoutBox[h],y=Te(r[h]);f.max=f.min+y,e.relativeTarget&&!e.currentAnimation&&(e.isProjectionDirty=!0,e.relativeTarget[h].max=e.relativeTarget[h].min+y)});const a=On();Ir(a,r,t.layoutBox);const l=On();o?Ir(l,e.applyTransform(i,!0),t.measuredBox):Ir(l,r,t.layoutBox);const u=!Bp(a);let c=!1;if(!e.resumeFrom){const h=e.getClosestProjectingParent();if(h&&!h.resumeFrom){const{snapshot:f,layout:y}=h;if(f&&y){const v=ae();Es(v,t.layoutBox,f.layoutBox);const x=ae();Es(x,r,y.layoutBox),zp(v,x)||(c=!0),h.options.layoutRoot&&(e.relativeTarget=x,e.relativeTargetOrigin=v,e.relativeParent=h)}}}e.notifyListeners("didUpdate",{layout:r,snapshot:t,delta:l,layoutDelta:a,hasLayoutChanged:u,hasRelativeLayoutChanged:c})}else if(e.isLead()){const{onExitComplete:r}=e.options;r&&r()}e.options.transition=void 0}function U2(e){e.parent&&(e.isProjecting()||(e.isProjectionDirty=e.parent.isProjectionDirty),e.isSharedProjectionDirty||(e.isSharedProjectionDirty=!!(e.isProjectionDirty||e.parent.isProjectionDirty||e.parent.isSharedProjectionDirty)),e.isTransformDirty||(e.isTransformDirty=e.parent.isTransformDirty))}function $2(e){e.isProjectionDirty=e.isSharedProjectionDirty=e.isTransformDirty=!1}function W2(e){e.clearSnapshot()}function Ud(e){e.clearMeasurements()}function $d(e){e.isLayoutDirty=!1}function H2(e){const{visualElement:t}=e.options;t&&t.getProps().onBeforeLayoutMeasure&&t.notify("BeforeLayoutMeasure"),e.resetTransform()}function Wd(e){e.finishAnimation(),e.targetDelta=e.relativeTarget=e.target=void 0,e.isProjectionDirty=!0}function K2(e){e.resolveTargetDelta()}function G2(e){e.calcProjection()}function Y2(e){e.resetSkewAndRotation()}function Q2(e){e.removeLeadSnapshot()}function Hd(e,t,n){e.translate=q(t.translate,0,n),e.scale=q(t.scale,1,n),e.origin=t.origin,e.originPoint=t.originPoint}function Kd(e,t,n,r){e.min=q(t.min,n.min,r),e.max=q(t.max,n.max,r)}function X2(e,t,n,r){Kd(e.x,t.x,n.x,r),Kd(e.y,t.y,n.y,r)}function Z2(e){return e.animationValues&&e.animationValues.opacityExit!==void 0}const q2={duration:.45,ease:[.4,0,.1,1]},Gd=e=>typeof navigator<"u"&&navigator.userAgent&&navigator.userAgent.toLowerCase().includes(e),Yd=Gd("applewebkit/")&&!Gd("chrome/")?Math.round:Ye;function Qd(e){e.min=Yd(e.min),e.max=Yd(e.max)}function J2(e){Qd(e.x),Qd(e.y)}function Wp(e,t,n){return e==="position"||e==="preserve-aspect"&&!s2(Bd(t),Bd(n),.2)}function e3(e){var t;return e!==e.root&&((t=e.scroll)==null?void 0:t.wasRoot)}const t3=$p({attachResizeListener:(e,t)=>si(e,"resize",t),measureScroll:()=>({x:document.documentElement.scrollLeft||document.body.scrollLeft,y:document.documentElement.scrollTop||document.body.scrollTop}),checkIsScrollRoot:()=>!0}),Vo={current:void 0},Hp=$p({measureScroll:e=>({x:e.scrollLeft,y:e.scrollTop}),defaultParent:()=>{if(!Vo.current){const e=new t3({});e.mount(window),e.setOptions({layoutScroll:!0}),Vo.current=e}return Vo.current},resetTransform:(e,t)=>{e.style.transform=t!==void 0?t:"none"},checkIsScrollRoot:e=>window.getComputedStyle(e).position==="fixed"}),n3={pan:{Feature:w2},drag:{Feature:x2,ProjectionNode:Hp,MeasureLayout:_p}};function Xd(e,t,n){const{props:r}=e;e.animationState&&r.whileHover&&e.animationState.setActive("whileHover",n==="Start");const i="onHover"+n,s=r[i];s&&Q.postRender(()=>s(t,pi(t)))}class r3 extends Zt{mount(){const{current:t}=this.node;t&&(this.unmount=jv(t,(n,r)=>(Xd(this.node,r,"Start"),i=>Xd(this.node,i,"End"))))}unmount(){}}class i3 extends Zt{constructor(){super(...arguments),this.isActive=!1}onFocus(){let t=!1;try{t=this.node.current.matches(":focus-visible")}catch{t=!0}!t||!this.node.animationState||(this.node.animationState.setActive("whileFocus",!0),this.isActive=!0)}onBlur(){!this.isActive||!this.node.animationState||(this.node.animationState.setActive("whileFocus",!1),this.isActive=!1)}mount(){this.unmount=di(si(this.node.current,"focus",()=>this.onFocus()),si(this.node.current,"blur",()=>this.onBlur()))}unmount(){}}function Zd(e,t,n){const{props:r}=e;if(e.current instanceof HTMLButtonElement&&e.current.disabled)return;e.animationState&&r.whileTap&&e.animationState.setActive("whileTap",n==="Start");const i="onTap"+(n==="End"?"":n),s=r[i];s&&Q.postRender(()=>s(t,pi(t)))}class s3 extends Zt{mount(){const{current:t}=this.node;t&&(this.unmount=Ev(t,(n,r)=>(Zd(this.node,r,"Start"),(i,{success:s})=>Zd(this.node,i,s?"End":"Cancel")),{useGlobalTarget:this.node.props.globalTapTarget}))}unmount(){}}const Ja=new WeakMap,Io=new WeakMap,o3=e=>{const t=Ja.get(e.target);t&&t(e)},a3=e=>{e.forEach(o3)};function l3({root:e,...t}){const n=e||document;Io.has(n)||Io.set(n,{});const r=Io.get(n),i=JSON.stringify(t);return r[i]||(r[i]=new IntersectionObserver(a3,{root:e,...t})),r[i]}function u3(e,t,n){const r=l3(t);return Ja.set(e,n),r.observe(e),()=>{Ja.delete(e),r.unobserve(e)}}const c3={some:0,all:1};class d3 extends Zt{constructor(){super(...arguments),this.hasEnteredView=!1,this.isInView=!1}startObserver(){this.unmount();const{viewport:t={}}=this.node.getProps(),{root:n,margin:r,amount:i="some",once:s}=t,o={root:n?n.current:void 0,rootMargin:r,threshold:typeof i=="number"?i:c3[i]},a=l=>{const{isIntersecting:u}=l;if(this.isInView===u||(this.isInView=u,s&&!u&&this.hasEnteredView))return;u&&(this.hasEnteredView=!0),this.node.animationState&&this.node.animationState.setActive("whileInView",u);const{onViewportEnter:c,onViewportLeave:h}=this.node.getProps(),f=u?c:h;f&&f(l)};return u3(this.node.current,o,a)}mount(){this.startObserver()}update(){if(typeof IntersectionObserver>"u")return;const{props:t,prevProps:n}=this.node;["amount","margin","root"].some(f3(t,n))&&this.startObserver()}unmount(){}}function f3({viewport:e={}},{viewport:t={}}={}){return n=>e[n]!==t[n]}const h3={inView:{Feature:d3},tap:{Feature:s3},focus:{Feature:i3},hover:{Feature:r3}},p3={layout:{ProjectionNode:Hp,MeasureLayout:_p}},m3={...Jx,...h3,...n3,...p3},B=mx(m3,Ex),ht="/api";async function g3(){return(await fetch(`${ht}/state`)).json()}async function qd(){return(await fetch(`${ht}/dependencies/check`)).json()}async function Jd(){return(await fetch(`${ht}/docker/status`)).json()}function _o(e){let t=null,n=!1;const r=()=>{n||(t=new EventSource(`${ht}/docker/status/stream`),t.onmessage=i=>{try{const s=JSON.parse(i.data);e(s)}catch(s){console.error("Failed to parse docker status:",s)}},t.onerror=()=>{t==null||t.close(),n||setTimeout(r,1e3)})};return r(),()=>{n=!0,t==null||t.close()}}async function y3(){return(await fetch(`${ht}/docker/build`,{method:"POST"})).json()}async function Ii(){return(await fetch(`${ht}/defaults`)).json()}async function ef(e){return(await fetch(`${ht}/defaults`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify(e)})).json()}async function v3(){return(await fetch(`${ht}/signing/status`)).json()}async function x3(){return(await fetch(`${ht}/signing`)).json()}async function w3(e){return(await fetch(`${ht}/signing`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify(e)})).json()}const Kp="/assets/wails-logo-white-text-B284k7fX.svg",Gp="/assets/wails-logo-black-text-Cx-vsZ4W.svg",k3={initial:{opacity:0},animate:{opacity:1},exit:{opacity:0}};function S3({onNext:e,onSkip:t,onBack:n,canGoBack:r}){const[i,s]=C.useState(null),[o,a]=C.useState(null),[l,u]=C.useState(!0),[c,h]=C.useState("darwin"),[f,y]=C.useState(!1),[v,x]=C.useState(!1),P=C.useRef(null);C.useEffect(()=>{var w;(w=P.current)==null||w.focus(),m()},[]);const m=async()=>{try{const[w,j]=await Promise.all([v3(),x3()]);s(w),a(j||{darwin:{},windows:{},linux:{}})}catch(w){console.error("Failed to load signing data:",w)}finally{u(!1)}},p=async()=>{if(o){x(!0);try{await w3(o),await m(),y(!1)}catch(w){console.error("Failed to save signing config:",w)}finally{x(!1)}}},g=()=>{var w,j,V,D,W,Ce,ze,U;return o?c==="darwin"?d.jsxs("div",{className:"space-y-4",children:[d.jsxs("div",{children:[d.jsx("label",{className:"block text-sm font-medium text-gray-700 dark:text-gray-300 mb-1",children:"Signing Identity"}),d.jsx("input",{type:"text",value:((w=o.darwin)==null?void 0:w.identity)||"",onChange:O=>a({...o,darwin:{...o.darwin,identity:O.target.value}}),placeholder:"Developer ID Application: Your Name (TEAMID)",className:"w-full px-3 py-2 rounded-lg border border-gray-300 dark:border-gray-600 bg-white dark:bg-gray-800 text-gray-900 dark:text-white text-sm focus:outline-none focus:ring-2 focus:ring-red-500"}),d.jsxs("p",{className:"text-xs text-gray-500 dark:text-gray-400 mt-1",children:["Find with: ",d.jsx("code",{className:"bg-gray-100 dark:bg-gray-800 px-1 rounded",children:"security find-identity -v -p codesigning"})]})]}),d.jsxs("div",{children:[d.jsx("label",{className:"block text-sm font-medium text-gray-700 dark:text-gray-300 mb-1",children:"Team ID"}),d.jsx("input",{type:"text",value:((j=o.darwin)==null?void 0:j.teamID)||"",onChange:O=>a({...o,darwin:{...o.darwin,teamID:O.target.value}}),placeholder:"ABCD1234EF",className:"w-full px-3 py-2 rounded-lg border border-gray-300 dark:border-gray-600 bg-white dark:bg-gray-800 text-gray-900 dark:text-white text-sm focus:outline-none focus:ring-2 focus:ring-red-500"})]}),d.jsxs("div",{children:[d.jsx("label",{className:"block text-sm font-medium text-gray-700 dark:text-gray-300 mb-1",children:"Notarization Profile (optional)"}),d.jsx("input",{type:"text",value:((V=o.darwin)==null?void 0:V.keychainProfile)||"",onChange:O=>a({...o,darwin:{...o.darwin,keychainProfile:O.target.value}}),placeholder:"notarytool-profile",className:"w-full px-3 py-2 rounded-lg border border-gray-300 dark:border-gray-600 bg-white dark:bg-gray-800 text-gray-900 dark:text-white text-sm focus:outline-none focus:ring-2 focus:ring-red-500"}),d.jsxs("p",{className:"text-xs text-gray-500 dark:text-gray-400 mt-1",children:["Create with: ",d.jsx("code",{className:"bg-gray-100 dark:bg-gray-800 px-1 rounded",children:"xcrun notarytool store-credentials"})]})]})]}):c==="windows"?d.jsxs("div",{className:"space-y-4",children:[d.jsxs("div",{children:[d.jsx("label",{className:"block text-sm font-medium text-gray-700 dark:text-gray-300 mb-1",children:"Certificate Path (PFX/P12)"}),d.jsx("input",{type:"text",value:((D=o.windows)==null?void 0:D.certificatePath)||"",onChange:O=>a({...o,windows:{...o.windows,certificatePath:O.target.value}}),placeholder:"/path/to/certificate.pfx",className:"w-full px-3 py-2 rounded-lg border border-gray-300 dark:border-gray-600 bg-white dark:bg-gray-800 text-gray-900 dark:text-white text-sm focus:outline-none focus:ring-2 focus:ring-red-500"})]}),d.jsx("div",{className:"text-center text-xs text-gray-500 dark:text-gray-400",children:"— or —"}),d.jsxs("div",{children:[d.jsx("label",{className:"block text-sm font-medium text-gray-700 dark:text-gray-300 mb-1",children:"Certificate Thumbprint (Windows Store)"}),d.jsx("input",{type:"text",value:((W=o.windows)==null?void 0:W.thumbprint)||"",onChange:O=>a({...o,windows:{...o.windows,thumbprint:O.target.value}}),placeholder:"ABC123DEF456...",className:"w-full px-3 py-2 rounded-lg border border-gray-300 dark:border-gray-600 bg-white dark:bg-gray-800 text-gray-900 dark:text-white text-sm focus:outline-none focus:ring-2 focus:ring-red-500"})]}),d.jsxs("div",{children:[d.jsx("label",{className:"block text-sm font-medium text-gray-700 dark:text-gray-300 mb-1",children:"Timestamp Server"}),d.jsx("input",{type:"text",value:((Ce=o.windows)==null?void 0:Ce.timestampServer)||"http://timestamp.digicert.com",onChange:O=>a({...o,windows:{...o.windows,timestampServer:O.target.value}}),className:"w-full px-3 py-2 rounded-lg border border-gray-300 dark:border-gray-600 bg-white dark:bg-gray-800 text-gray-900 dark:text-white text-sm focus:outline-none focus:ring-2 focus:ring-red-500"})]})]}):c==="linux"?d.jsxs("div",{className:"space-y-4",children:[d.jsxs("div",{children:[d.jsx("label",{className:"block text-sm font-medium text-gray-700 dark:text-gray-300 mb-1",children:"GPG Key ID"}),d.jsx("input",{type:"text",value:((ze=o.linux)==null?void 0:ze.gpgKeyID)||"",onChange:O=>a({...o,linux:{...o.linux,gpgKeyID:O.target.value}}),placeholder:"ABCD1234EFGH5678",className:"w-full px-3 py-2 rounded-lg border border-gray-300 dark:border-gray-600 bg-white dark:bg-gray-800 text-gray-900 dark:text-white text-sm focus:outline-none focus:ring-2 focus:ring-red-500"}),d.jsxs("p",{className:"text-xs text-gray-500 dark:text-gray-400 mt-1",children:["Find with: ",d.jsx("code",{className:"bg-gray-100 dark:bg-gray-800 px-1 rounded",children:"gpg --list-secret-keys --keyid-format long"})]})]}),d.jsxs("div",{children:[d.jsx("label",{className:"block text-sm font-medium text-gray-700 dark:text-gray-300 mb-1",children:"GPG Key Path (optional)"}),d.jsx("input",{type:"text",value:((U=o.linux)==null?void 0:U.gpgKeyPath)||"",onChange:O=>a({...o,linux:{...o.linux,gpgKeyPath:O.target.value}}),placeholder:"~/.gnupg/private-key.asc",className:"w-full px-3 py-2 rounded-lg border border-gray-300 dark:border-gray-600 bg-white dark:bg-gray-800 text-gray-900 dark:text-white text-sm focus:outline-none focus:ring-2 focus:ring-red-500"})]})]}):null:null},k=()=>{if(!i)return null;if(c==="darwin"){const w=i.darwin;return d.jsxs("div",{className:"space-y-4",children:[d.jsx(vr,{label:"Code Signing Identity",configured:w.hasIdentity,value:w.hasIdentity?w.identity||"Configured":"Not configured",source:w.configSource}),d.jsx(vr,{label:"Notarization",configured:w.hasNotarization,value:w.hasNotarization?`Team ID: ${w.teamID||"Configured"}`:"Not configured"}),w.identities&&w.identities.length>1&&d.jsxs("div",{className:"text-xs text-gray-500 dark:text-gray-400 p-3 rounded-lg bg-blue-50 dark:bg-blue-900/20 border border-blue-200 dark:border-blue-800",children:[d.jsxs("span",{className:"font-medium",children:[w.identities.length," signing identities"]})," found in keychain"]})]})}if(c==="windows"){const w=i.windows;return d.jsxs("div",{className:"space-y-4",children:[d.jsx(vr,{label:"Code Signing Certificate",configured:w.hasCertificate,value:w.hasCertificate?`Type: ${w.certificateType}`:"Not configured",source:w.configSource}),d.jsx(vr,{label:"SignTool",configured:w.hasSignTool,value:w.hasSignTool?"Available":"Not found (Windows SDK required)"}),w.timestampServer&&d.jsxs("div",{className:"text-xs text-gray-500 dark:text-gray-400 p-3 rounded-lg bg-gray-50 dark:bg-gray-800/50",children:["Timestamp server: ",d.jsx("code",{className:"font-mono",children:w.timestampServer})]})]})}if(c==="linux"){const w=i.linux;return d.jsx("div",{className:"space-y-4",children:d.jsx(vr,{label:"GPG Signing Key",configured:w.hasGpgKey,value:w.hasGpgKey?`Key ID: ${w.gpgKeyID}`:"Not configured",source:w.configSource})})}return null},T=(()=>{if(!i)return{configured:0,total:3};let w=0;return i.darwin.hasIdentity&&w++,i.windows.hasCertificate&&w++,i.linux.hasGpgKey&&w++,{configured:w,total:3}})();return d.jsxs(B.main,{variants:k3,initial:"initial",animate:"animate",exit:"exit",transition:{duration:.3},className:"flex-1 flex flex-col","aria-labelledby":"signing-title",children:[d.jsxs("header",{className:"text-center mb-6 flex-shrink-0 px-10 pt-10",children:[d.jsx("h1",{ref:P,id:"signing-title",className:"text-2xl font-semibold text-gray-900 dark:text-white mb-1.5 tracking-tight focus:outline-none",tabIndex:-1,children:"Code Signing"}),d.jsx("p",{className:"text-base text-gray-500 dark:text-gray-400",children:T.configured>0?`${T.configured} of ${T.total} platforms configured`:"Sign your apps for distribution"})]}),d.jsx("div",{className:"flex-1 overflow-y-auto scrollbar-thin min-h-0 px-10",children:l?d.jsx("div",{className:"flex items-center justify-center h-48",children:d.jsx(B.div,{className:"w-8 h-8 border-2 border-gray-300 dark:border-gray-600 border-t-red-500 rounded-full",animate:{rotate:360},transition:{duration:1,repeat:1/0,ease:"linear"}})}):d.jsxs("div",{className:"max-w-xl mx-auto",children:[d.jsxs("div",{className:"flex gap-2 mb-6",role:"tablist",children:[d.jsx(Fo,{platform:"darwin",label:"macOS",isActive:c==="darwin",hasConfig:i==null?void 0:i.darwin.hasIdentity,onClick:()=>{h("darwin"),y(!1)}}),d.jsx(Fo,{platform:"windows",label:"Windows",isActive:c==="windows",hasConfig:i==null?void 0:i.windows.hasCertificate,onClick:()=>{h("windows"),y(!1)}}),d.jsx(Fo,{platform:"linux",label:"Linux",isActive:c==="linux",hasConfig:i==null?void 0:i.linux.hasGpgKey,onClick:()=>{h("linux"),y(!1)}})]}),d.jsx(Ha,{mode:"wait",children:f?d.jsxs(B.div,{initial:{opacity:0,y:10},animate:{opacity:1,y:0},exit:{opacity:0,y:-10},transition:{duration:.2},children:[g(),d.jsxs("div",{className:"flex gap-3 mt-6",children:[d.jsx("button",{onClick:()=>y(!1),className:"flex-1 px-4 py-2 rounded-lg text-sm font-medium border border-gray-300 dark:border-gray-600 text-gray-600 dark:text-gray-400 hover:bg-gray-100 dark:hover:bg-gray-800",children:"Cancel"}),d.jsx("button",{onClick:p,disabled:v,className:"flex-1 px-4 py-2 rounded-lg text-sm font-medium bg-red-500 text-white hover:bg-red-600 disabled:opacity-50",children:v?"Saving...":"Save"})]})]},"config"):d.jsxs(B.div,{initial:{opacity:0,y:10},animate:{opacity:1,y:0},exit:{opacity:0,y:-10},transition:{duration:.2},role:"tabpanel",children:[k(),d.jsxs("button",{onClick:()=>y(!0),className:"w-full mt-4 px-4 py-2 rounded-lg text-sm font-medium border border-gray-300 dark:border-gray-600 text-gray-600 dark:text-gray-400 hover:bg-gray-100 dark:hover:bg-gray-800 transition-colors",children:["Configure ",c==="darwin"?"macOS":c==="windows"?"Windows":"Linux"," Signing"]})]},"status")}),d.jsx("p",{className:"text-xs text-gray-500 dark:text-gray-400 mt-6 text-center",children:"Code signing ensures your app is trusted and hasn't been tampered with"})]})}),d.jsxs("div",{className:"flex-shrink-0 pt-4 pb-6 flex flex-col items-center gap-1.5",children:[d.jsxs("div",{className:"flex items-center gap-3",children:[r&&n&&d.jsx("button",{onClick:n,className:"px-4 py-2 rounded-lg text-sm font-medium transition-colors border border-gray-300 dark:border-gray-600 text-gray-600 dark:text-gray-400 hover:bg-gray-100 dark:hover:bg-gray-800 focus:outline-none focus:ring-2 focus:ring-gray-500 focus:ring-offset-2 dark:focus:ring-offset-gray-900",children:"Back"}),d.jsx("button",{onClick:e,className:"px-5 py-2 rounded-lg text-sm font-medium transition-colors border border-red-500 text-red-600 dark:text-red-400 hover:bg-red-500/10 focus:outline-none focus:ring-2 focus:ring-red-500 focus:ring-offset-2 dark:focus:ring-offset-gray-900",children:"Continue"})]}),d.jsx("button",{onClick:t,className:"text-xs text-gray-500 dark:text-gray-400 hover:text-gray-700 dark:hover:text-gray-300 transition-colors focus:outline-none focus:ring-2 focus:ring-gray-500 focus:ring-offset-2 dark:focus:ring-offset-gray-900 rounded",children:"Set up later"})]})]})}function vr({label:e,configured:t,value:n,source:r}){return d.jsxs("div",{className:"flex items-center gap-3 p-4 rounded-lg bg-gray-100 dark:bg-gray-900/50",children:[d.jsx("div",{className:`w-8 h-8 rounded-full flex items-center justify-center ${t?"bg-green-500/20":"bg-gray-200 dark:bg-gray-800"}`,children:t?d.jsx("svg",{className:"w-4 h-4 text-green-500",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",children:d.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2.5,d:"M5 13l4 4L19 7"})}):d.jsx("svg",{className:"w-4 h-4 text-gray-400",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",children:d.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M6 18L18 6M6 6l12 12"})})}),d.jsxs("div",{className:"flex-1",children:[d.jsx("div",{className:"text-sm font-medium text-gray-900 dark:text-white",children:e}),d.jsx("div",{className:"text-xs text-gray-500 dark:text-gray-400",children:n})]}),r&&d.jsx("span",{className:"text-xs px-2 py-1 rounded-full bg-gray-200 dark:bg-gray-800 text-gray-600 dark:text-gray-400",children:r})]})}function Fo({platform:e,label:t,isActive:n,hasConfig:r,onClick:i}){const s=`w-5 h-5 ${n?"text-gray-900 dark:text-white":"text-gray-400 dark:text-gray-500"}`;return d.jsxs("button",{role:"tab","aria-selected":n,onClick:i,className:`flex-1 flex items-center justify-center gap-2 px-4 py-3 rounded-lg text-sm font-medium transition-all ${n?"bg-gray-100 dark:bg-gray-800 text-gray-900 dark:text-white":"text-gray-500 dark:text-gray-400 hover:bg-gray-50 dark:hover:bg-gray-800/50"}`,children:[e==="darwin"&&d.jsx("svg",{className:s,viewBox:"0 0 24 24",fill:"currentColor",children:d.jsx("path",{d:"M18.71 19.5c-.83 1.24-1.71 2.45-3.05 2.47-1.34.03-1.77-.79-3.29-.79-1.53 0-2 .77-3.27.82-1.31.05-2.3-1.32-3.14-2.53C4.25 17 2.94 12.45 4.7 9.39c.87-1.52 2.43-2.48 4.12-2.51 1.28-.02 2.5.87 3.29.87.78 0 2.26-1.07 3.81-.91.65.03 2.47.26 3.64 1.98-.09.06-2.17 1.28-2.15 3.81.03 3.02 2.65 4.03 2.68 4.04-.03.07-.42 1.44-1.38 2.83M13 3.5c.73-.83 1.94-1.46 2.94-1.5.13 1.17-.34 2.35-1.04 3.19-.69.85-1.83 1.51-2.95 1.42-.15-1.15.41-2.35 1.05-3.11z"})}),e==="windows"&&d.jsx("svg",{className:s,viewBox:"0 0 24 24",fill:"currentColor",children:d.jsx("path",{d:"M0 3.449L9.75 2.1v9.451H0m10.949-9.602L24 0v11.4H10.949M0 12.6h9.75v9.451L0 20.699M10.949 12.6H24V24l-12.9-1.801"})}),e==="linux"&&d.jsx("svg",{className:s,viewBox:"0 0 24 24",fill:"currentColor",children:d.jsx("path",{d:"M12.504 0c-.155 0-.315.008-.48.021-4.226.333-3.105 4.807-3.17 6.298-.076 1.092-.3 1.953-1.05 3.02-.885 1.051-2.127 2.75-2.716 4.521-.278.832-.41 1.684-.287 2.489a.424.424 0 00-.11.135c-.26.268-.45.6-.663.839-.199.199-.485.267-.797.4-.313.136-.658.269-.864.68-.09.189-.136.394-.132.602 0 .199.027.4.055.536.058.399.116.728.04.97-.249.68-.28 1.145-.106 1.484.174.334.535.47.94.601.81.2 1.91.135 2.774.6.926.466 1.866.67 2.616.47.526-.116.97-.464 1.208-.946.587-.003 1.23-.269 2.26-.334.699-.058 1.574.267 2.577.2.025.134.063.198.114.333l.003.003c.391.778 1.113 1.132 1.884 1.071.771-.06 1.592-.536 2.257-1.306.631-.765 1.683-1.084 2.378-1.503.348-.199.629-.469.649-.853.023-.4-.2-.811-.714-1.376v-.097l-.003-.003c-.17-.2-.25-.535-.338-.926-.085-.401-.182-.786-.492-1.046h-.003c-.059-.054-.123-.067-.188-.135a.357.357 0 00-.19-.064c.431-1.278.264-2.55-.173-3.694-.533-1.41-1.465-2.638-2.175-3.483-.796-1.005-1.576-1.957-1.56-3.368.026-2.152.236-6.133-3.544-6.139zm.529 3.405h.013c.213 0 .396.062.584.198.19.135.33.332.438.533.105.259.158.459.166.724 0-.02.006-.04.006-.06v.105a.086.086 0 01-.004-.021l-.004-.024a1.807 1.807 0 01-.15.706.953.953 0 01-.213.335.71.71 0 00-.088-.042c-.104-.045-.198-.064-.284-.133a1.312 1.312 0 00-.22-.066c.05-.06.146-.133.183-.198.053-.128.082-.264.088-.402v-.02a1.21 1.21 0 00-.061-.4c-.045-.134-.101-.2-.183-.333-.084-.066-.167-.132-.267-.132h-.016c-.093 0-.176.03-.262.132a.8.8 0 00-.205.334 1.18 1.18 0 00-.09.4v.019c.002.089.008.179.02.267-.193-.067-.438-.135-.607-.202a1.635 1.635 0 01-.018-.2v-.02a1.772 1.772 0 01.15-.768c.082-.22.232-.406.43-.533a.985.985 0 01.594-.2zm-2.962.059h.036c.142 0 .27.048.399.135.146.129.264.288.344.465.09.199.14.4.153.667v.004c.007.134.006.2-.002.266v.08c-.03.007-.056.018-.083.024-.152.055-.274.135-.393.2.012-.09.013-.18.003-.267v-.015c-.012-.133-.04-.2-.082-.333a.613.613 0 00-.166-.267.248.248 0 00-.183-.064h-.021c-.071.006-.13.04-.186.132a.552.552 0 00-.12.27.944.944 0 00-.023.33v.015c.012.135.037.2.08.267a.86.86 0 00.153.2c.071.085.178.135.305.178l.056.02a.398.398 0 00-.104.078c-.09.088-.198.2-.318.267-.145.085-.232.135-.39.135a1.04 1.04 0 01-.507-.151c-.106-.067-.199-.135-.285-.202l-.072-.053c-.239-.2-.439-.401-.618-.535a2.494 2.494 0 01-.393-.4c-.078-.1-.143-.199-.2-.298l-.06-.135-.048.066c-.078.133-.127.266-.127.465 0 .2.049.4.127.535.078.133.2.265.35.331.148.068.313.135.47.202.234.1.438.2.59.331.15.135.234.27.234.402 0 .135-.063.265-.198.332-.142.065-.32.102-.578.102-.232 0-.465-.037-.67-.1-.204-.068-.378-.17-.51-.301-.135-.135-.237-.301-.305-.5-.066-.199-.103-.432-.103-.699 0-.265.037-.5.106-.698.068-.2.166-.366.3-.5.135-.135.301-.234.5-.3.2-.067.432-.1.699-.1.266 0 .5.033.699.1.199.066.365.165.5.3.135.134.233.3.3.5.068.198.101.433.101.698 0 .267-.033.5-.1.7-.068.199-.166.365-.301.5-.135.134-.301.233-.5.3-.199.067-.433.1-.699.1-.267 0-.5-.033-.7-.1a1.379 1.379 0 01-.5-.3c-.134-.135-.233-.301-.3-.5-.066-.2-.1-.433-.1-.7 0-.266.034-.5.1-.698.067-.2.166-.366.3-.5.135-.135.301-.234.5-.3.2-.067.433-.1.7-.1z"})}),d.jsx("span",{children:t}),r&&d.jsx("span",{className:"w-2 h-2 rounded-full bg-green-500"})]})}function C3(e){switch(e){case"splash":case"checking":return"welcome";case"deps-ready":case"deps-missing":return"dependencies";case"cross-platform":case"docker-setup":return"platform";case"projects":case"signing":return"identity";case"language-select":case"binding-style":case"template-select":return"templates";case"complete":return"complete";default:return"welcome"}}function j3(e){return["welcome","dependencies","platform","identity","templates","complete"].indexOf(e)+1}const Yp=C.createContext({theme:"dark",toggleTheme:()=>{}}),Qp=()=>C.useContext(Yp),we={initial:{opacity:0},animate:{opacity:1},exit:{opacity:0}};function T3({currentStep:e,dockerStatus:t,buildingDocker:n}){const{theme:r,toggleTheme:i}=Qp(),s=C3(e),o=j3(s),a=[{key:"welcome",label:"Welcome"},{key:"dependencies",label:"Dependencies"},{key:"platform",label:"Platform"},{key:"identity",label:"Projects"},{key:"templates",label:"Templates"},{key:"complete",label:"Complete"}],l=()=>{window.open("https://github.com/sponsors/leaanthony","_blank","noopener,noreferrer")},u=n;return d.jsxs("aside",{className:"w-48 flex-shrink-0 bg-gray-100/80 dark:bg-transparent dark:glass-sidebar border-r border-gray-200 dark:border-transparent flex flex-col","aria-label":"Setup progress",children:[d.jsx("div",{className:"p-6 flex justify-center",children:d.jsx("img",{src:r==="dark"?Kp:Gp,alt:"Wails logo",className:"h-24 object-contain"})}),d.jsx("nav",{className:"flex-1 px-4 py-2","aria-label":"Setup steps",children:d.jsx("ol",{className:"space-y-1",children:a.map((c,h)=>{const f=h+1,y=c.key===s,v=f{var f;(f=c.current)==null||f.focus()},[e]);const h=r||s?d.jsxs("div",{className:"flex-shrink-0 pt-4 pb-6 flex flex-col items-center gap-1.5",role:"group","aria-label":"Page actions",children:[d.jsxs("div",{className:"flex items-center gap-3",children:[u&&l&&d.jsx("button",{onClick:l,className:"px-4 py-2 rounded-lg text-sm font-medium transition-colors border border-gray-300 dark:border-gray-600 text-gray-600 dark:text-gray-400 hover:bg-gray-100 dark:hover:bg-gray-800 focus:outline-none focus:ring-2 focus:ring-gray-500 focus:ring-offset-2 dark:focus:ring-offset-gray-900",children:"Back"}),r&&i&&d.jsx("button",{onClick:r,disabled:a,className:`px-5 py-2 rounded-lg text-sm font-medium transition-colors border focus:outline-none focus:ring-2 focus:ring-red-500 focus:ring-offset-2 dark:focus:ring-offset-gray-900 ${a?"border-gray-300 dark:border-gray-700 text-gray-400 cursor-not-allowed":"border-red-500 text-red-600 dark:text-red-400 hover:bg-red-500/10"}`,"aria-disabled":a,children:i})]}),s&&o&&d.jsx("button",{onClick:s,className:"text-xs text-gray-500 dark:text-gray-400 hover:text-gray-700 dark:hover:text-gray-300 transition-colors focus:outline-none focus:ring-2 focus:ring-gray-500 focus:ring-offset-2 dark:focus:ring-offset-gray-900 rounded",children:o})]}):null;return d.jsxs(B.main,{variants:we,initial:"initial",animate:"animate",exit:"exit",transition:{duration:.3},className:"flex-1 flex flex-col","aria-labelledby":"page-title",children:[d.jsxs("header",{className:"text-center mb-6 flex-shrink-0 px-10 pt-10",children:[d.jsx("h1",{ref:c,id:"page-title",className:"text-2xl font-semibold text-gray-900 dark:text-white mb-1.5 tracking-tight focus:outline-none",tabIndex:-1,children:e}),d.jsx("p",{className:"text-base text-gray-500 dark:text-gray-400",children:t})]}),d.jsx("div",{className:"flex-1 overflow-y-auto scrollbar-thin min-h-0 px-10",children:n}),h]})}function P3({onNext:e}){const{theme:t}=Qp(),n=C.useRef(null),r=C.useRef(null);C.useEffect(()=>{var s;(s=n.current)==null||s.focus()},[]);const i=s=>{s.key==="Enter"&&document.activeElement===r.current&&e()};return d.jsxs(B.main,{variants:we,initial:"initial",animate:"animate",exit:"exit",transition:{duration:.3},className:"flex-1 flex flex-col items-center justify-center","aria-labelledby":"splash-title",onKeyDown:i,children:[d.jsx(B.div,{className:"text-center mb-10",initial:{opacity:0,scale:.9},animate:{opacity:1,scale:1},transition:{duration:.6,ease:"easeOut"},children:d.jsx("div",{className:"flex justify-center",children:d.jsx("img",{src:t==="dark"?Kp:Gp,alt:"",width:280,className:"object-contain",style:{filter:"drop-shadow(0 0 60px rgba(239, 68, 68, 0.4))"},"aria-hidden":"true"})})}),d.jsxs(B.div,{className:"text-center px-8 max-w-lg",initial:{opacity:0,y:20},animate:{opacity:1,y:0},transition:{duration:.5,delay:.2},children:[d.jsxs("div",{className:"flex items-center justify-center gap-2 mb-3",children:[d.jsx("h1",{ref:n,id:"splash-title",className:"text-2xl font-semibold text-gray-900 dark:text-white tracking-tight focus:outline-none",tabIndex:-1,children:"Welcome to Wails"}),d.jsx("span",{className:"px-2 py-0.5 text-[10px] font-medium uppercase tracking-wide rounded-full bg-amber-500/20 text-amber-600 dark:text-amber-400 border border-amber-500/30",role:"status","aria-label":"This setup wizard is experimental",children:"Experimental"})]}),d.jsx("p",{className:"text-base text-gray-600 dark:text-gray-300 leading-relaxed mb-8",children:"Build beautiful cross-platform apps using Go and web technologies"})]}),d.jsx(B.button,{ref:r,onClick:e,className:"px-6 py-2.5 rounded-lg border border-red-500 text-red-600 dark:text-red-400 text-sm font-medium hover:bg-red-500/10 transition-colors focus:outline-none focus:ring-2 focus:ring-red-500 focus:ring-offset-2 dark:focus:ring-offset-gray-900",initial:{opacity:0},animate:{opacity:1},transition:{duration:.5,delay:.4},children:"Let's Start"})]})}function N3(){const e=C.useRef(null);return C.useEffect(()=>{var t;(t=e.current)==null||t.focus()},[]),d.jsxs(B.main,{variants:we,initial:"initial",animate:"animate",exit:"exit",transition:{duration:.3},className:"flex-1 flex flex-col items-center justify-start pt-[15%]","aria-labelledby":"checking-title","aria-busy":"true",children:[d.jsx(B.div,{className:"w-12 h-12 border-3 border-gray-300 dark:border-gray-600 border-t-red-500 rounded-full mb-6",animate:{rotate:360},transition:{duration:1,repeat:1/0,ease:"linear"},role:"status","aria-label":"Loading"}),d.jsx("h2",{ref:e,id:"checking-title",className:"text-xl font-semibold text-gray-900 dark:text-white mb-2 focus:outline-none",tabIndex:-1,children:"Checking your system..."}),d.jsx("p",{className:"text-gray-500 dark:text-gray-400","aria-live":"polite",children:"This will only take a moment"})]})}function E3({onNext:e,onBack:t,canGoBack:n}){const r=C.useRef(null);return C.useEffect(()=>{var i;(i=r.current)==null||i.focus()},[]),d.jsxs(B.main,{variants:we,initial:"initial",animate:"animate",exit:"exit",transition:{duration:.3},className:"flex-1 flex flex-col items-center justify-center","aria-labelledby":"deps-ready-title",children:[d.jsx(B.div,{initial:{scale:0},animate:{scale:1},transition:{type:"spring",stiffness:200,damping:15},className:"w-20 h-20 rounded-full bg-green-500/20 flex items-center justify-center mb-6","aria-hidden":"true",children:d.jsx("svg",{className:"w-10 h-10 text-green-500",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",children:d.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2.5,d:"M5 13l4 4L19 7"})})}),d.jsx("h2",{ref:r,id:"deps-ready-title",className:"text-2xl font-semibold text-gray-900 dark:text-white mb-2 focus:outline-none",tabIndex:-1,children:"All dependencies installed"}),d.jsx("p",{className:"text-gray-500 dark:text-gray-400 mb-8 text-center max-w-sm",children:"Your system has everything needed to build Wails apps"}),d.jsxs("div",{className:"flex items-center gap-3",role:"group","aria-label":"Navigation",children:[n&&t&&d.jsx("button",{onClick:t,className:"px-4 py-2 rounded-lg text-sm font-medium transition-colors border border-gray-300 dark:border-gray-600 text-gray-600 dark:text-gray-400 hover:bg-gray-100 dark:hover:bg-gray-800 focus:outline-none focus:ring-2 focus:ring-gray-500 focus:ring-offset-2 dark:focus:ring-offset-gray-900",children:"Back"}),d.jsx("button",{onClick:e,className:"px-5 py-2 rounded-lg border border-red-500 text-red-600 dark:text-red-400 text-sm font-medium hover:bg-red-500/10 transition-colors focus:outline-none focus:ring-2 focus:ring-red-500 focus:ring-offset-2 dark:focus:ring-offset-gray-900",children:"Continue"})]})]})}function M3({dependencies:e,onRetry:t,onContinue:n,onBack:r,canGoBack:i}){const[s,o]=C.useState(!1),a=e.filter(c=>!c.installed&&c.required),l=(()=>{const c=a.filter(v=>{var x;return(x=v.installCommand)==null?void 0:x.startsWith("sudo ")}).map(v=>v.installCommand);if(c.length===0)return null;const h=[],f=[],y=[];for(const v of c)if(v.includes("pacman -S")){const x=v.match(/pacman -S\s+(.+)/);x&&h.push(...x[1].split(/\s+/))}else if(v.includes("apt install")){const x=v.match(/apt install\s+(.+)/);x&&f.push(...x[1].split(/\s+/))}else if(v.includes("dnf install")){const x=v.match(/dnf install\s+(.+)/);x&&y.push(...x[1].split(/\s+/))}return h.length>0?`sudo pacman -S ${h.join(" ")}`:f.length>0?`sudo apt install ${f.join(" ")}`:y.length>0?`sudo dnf install ${y.join(" ")}`:null})(),u=()=>{l&&(navigator.clipboard.writeText(l),o(!0),setTimeout(()=>o(!1),2e3))};return d.jsxs(Eu,{title:"Almost there!",subtitle:"A few things need to be installed first",primaryAction:t,primaryLabel:"Check Again",secondaryAction:n,secondaryLabel:"Continue anyway",onBack:r,canGoBack:i,children:[d.jsx("div",{className:"bg-gray-100 dark:bg-gray-900/50 rounded-lg p-4 mb-4",children:a.map(c=>d.jsxs("div",{className:"flex items-start gap-3 py-2 border-b border-gray-200/50 dark:border-gray-800/50 last:border-0",children:[d.jsx("div",{className:"w-5 h-5 rounded-full bg-red-500/20 flex items-center justify-center flex-shrink-0 mt-0.5",children:d.jsx("svg",{className:"w-3 h-3 text-red-500",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",children:d.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:3,d:"M6 18L18 6M6 6l12 12"})})}),d.jsxs("div",{children:[d.jsx("div",{className:"text-sm font-medium text-gray-900 dark:text-white",children:c.name}),c.message&&d.jsx("p",{className:"text-xs text-gray-500 mt-0.5",children:c.message}),c.helpUrl&&d.jsxs("a",{href:c.helpUrl,target:"_blank",rel:"noopener noreferrer",className:"inline-flex items-center gap-1 text-xs text-blue-500 dark:text-blue-400 hover:text-blue-600 dark:hover:text-blue-300 mt-1",children:["Install instructions",d.jsx("svg",{className:"w-3 h-3",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",children:d.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M10 6H6a2 2 0 00-2 2v10a2 2 0 002 2h10a2 2 0 002-2v-4M14 4h6m0 0v6m0-6L10 14"})})]})]})]},c.name))}),l&&d.jsxs("div",{className:"bg-gray-100 dark:bg-gray-900/50 rounded-lg p-4",children:[d.jsx("p",{className:"text-sm text-gray-600 dark:text-gray-300 mb-2",children:"Run this command to install everything:"}),d.jsxs("div",{className:"flex items-center gap-2",children:[d.jsx("code",{className:"flex-1 text-xs bg-gray-200 dark:bg-gray-900 text-gray-700 dark:text-gray-300 px-3 py-2 rounded font-mono overflow-x-auto",children:l}),d.jsx("button",{onClick:u,className:"text-gray-500 hover:text-gray-700 dark:hover:text-gray-300 transition-colors p-2",title:"Copy command",children:s?d.jsx("svg",{className:"w-5 h-5 text-green-500",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",children:d.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M5 13l4 4L19 7"})}):d.jsx("svg",{className:"w-5 h-5",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",children:d.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M8 16H6a2 2 0 01-2-2V6a2 2 0 012-2h8a2 2 0 012 2v2m-6 12h8a2 2 0 002-2v-8a2 2 0 00-2-2h-8a2 2 0 00-2 2v8a2 2 0 002 2z"})})})]})]})]})}function D3({dockerDep:e,onYes:t,onSkip:n,onBack:r,canGoBack:i}){const s=(e==null?void 0:e.installed)&&(e==null?void 0:e.imageBuilt)===!0;return d.jsx(B.div,{variants:we,initial:"initial",animate:"animate",exit:"exit",transition:{duration:.3},className:"flex-1 flex flex-col items-center justify-center",children:s?d.jsxs(d.Fragment,{children:[d.jsx(B.div,{initial:{scale:0},animate:{scale:1},transition:{type:"spring",stiffness:200,damping:15},className:"w-20 h-20 rounded-full bg-green-500/20 flex items-center justify-center mb-6",children:d.jsx("svg",{className:"w-10 h-10 text-green-500",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",children:d.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2.5,d:"M5 13l4 4L19 7"})})}),d.jsxs("div",{className:"flex items-center gap-4 mb-4",children:[d.jsx("svg",{className:"w-8 h-8 text-gray-600 dark:text-gray-400",viewBox:"0 0 24 24",fill:"currentColor",children:d.jsx("path",{d:"M0 3.449L9.75 2.1v9.451H0m10.949-9.602L24 0v11.4H10.949M0 12.6h9.75v9.451L0 20.699M10.949 12.6H24V24l-12.9-1.801"})}),d.jsx("svg",{className:"w-8 h-8 text-gray-600 dark:text-gray-400",viewBox:"0 0 24 24",fill:"currentColor",children:d.jsx("path",{d:"M18.71 19.5c-.83 1.24-1.71 2.45-3.05 2.47-1.34.03-1.77-.79-3.29-.79-1.53 0-2 .77-3.27.82-1.31.05-2.3-1.32-3.14-2.53C4.25 17 2.94 12.45 4.7 9.39c.87-1.52 2.43-2.48 4.12-2.51 1.28-.02 2.5.87 3.29.87.78 0 2.26-1.07 3.81-.91.65.03 2.47.26 3.64 1.98-.09.06-2.17 1.28-2.15 3.81.03 3.02 2.65 4.03 2.68 4.04-.03.07-.42 1.44-1.38 2.83M13 3.5c.73-.83 1.94-1.46 2.94-1.5.13 1.17-.34 2.35-1.04 3.19-.69.85-1.83 1.51-2.95 1.42-.15-1.15.41-2.35 1.05-3.11z"})}),d.jsx("svg",{className:"w-8 h-8 text-gray-600 dark:text-gray-400",viewBox:"0 0 24 24",fill:"currentColor",children:d.jsx("path",{d:"M12.504 0c-.155 0-.315.008-.48.021-4.226.333-3.105 4.807-3.17 6.298-.076 1.092-.3 1.953-1.05 3.02-.885 1.051-2.127 2.75-2.716 4.521-.278.832-.41 1.684-.287 2.489a.424.424 0 00-.11.135c-.26.268-.45.6-.663.839-.199.199-.485.267-.797.4-.313.136-.658.269-.864.68-.09.189-.136.394-.132.602 0 .199.027.4.055.536.058.399.116.728.04.97-.249.68-.28 1.145-.106 1.484.174.334.535.47.94.601.81.2 1.91.135 2.774.6.926.466 1.866.67 2.616.47.526-.116.97-.464 1.208-.946.587-.003 1.23-.269 2.26-.334.699-.058 1.574.267 2.577.2.025.134.063.198.114.333l.003.003c.391.778 1.113 1.132 1.884 1.071.771-.06 1.592-.536 2.257-1.306.631-.765 1.683-1.084 2.378-1.503.348-.199.629-.469.649-.853.023-.4-.2-.811-.714-1.376v-.097l-.003-.003c-.17-.2-.25-.535-.338-.926-.085-.401-.182-.786-.492-1.046h-.003c-.059-.054-.123-.067-.188-.135a.357.357 0 00-.19-.064c.431-1.278.264-2.55-.173-3.694-.533-1.41-1.465-2.638-2.175-3.483-.796-1.005-1.576-1.957-1.56-3.368.026-2.152.236-6.133-3.544-6.139zm.529 3.405h.013c.213 0 .396.062.584.198.19.135.33.332.438.533.105.259.158.459.166.724 0-.02.006-.04.006-.06v.105a.086.086 0 01-.004-.021l-.004-.024a1.807 1.807 0 01-.15.706.953.953 0 01-.213.335.71.71 0 00-.088-.042c-.104-.045-.198-.064-.284-.133a1.312 1.312 0 00-.22-.066c.05-.06.146-.133.183-.198.053-.128.082-.264.088-.402v-.02a1.21 1.21 0 00-.061-.4c-.045-.134-.101-.2-.183-.333-.084-.066-.167-.132-.267-.132h-.016c-.093 0-.176.03-.262.132a.8.8 0 00-.205.334 1.18 1.18 0 00-.09.4v.019c.002.089.008.179.02.267-.193-.067-.438-.135-.607-.202a1.635 1.635 0 01-.018-.2v-.02a1.772 1.772 0 01.15-.768c.082-.22.232-.406.43-.533a.985.985 0 01.594-.2zm-2.962.059h.036c.142 0 .27.048.399.135.146.129.264.288.344.465.09.199.14.4.153.667v.004c.007.134.006.2-.002.266v.08c-.03.007-.056.018-.083.024-.152.055-.274.135-.393.2.012-.09.013-.18.003-.267v-.015c-.012-.133-.04-.2-.082-.333a.613.613 0 00-.166-.267.248.248 0 00-.183-.064h-.021c-.071.006-.13.04-.186.132a.552.552 0 00-.12.27.944.944 0 00-.023.33v.015c.012.135.037.2.08.334.046.134.098.2.166.268.01.009.02.018.034.024-.07.057-.117.07-.176.136a.304.304 0 01-.131.068 2.62 2.62 0 01-.275-.402 1.772 1.772 0 01-.155-.667 1.759 1.759 0 01.08-.668 1.43 1.43 0 01.283-.535c.128-.133.26-.2.418-.2zm1.37 1.706c.332 0 .733.065 1.216.399.293.2.523.269 1.052.468h.003c.255.136.405.266.478.399v-.131a.571.571 0 01.016.47c-.123.31-.516.643-1.063.842v.002c-.268.135-.501.333-.775.465-.276.135-.588.292-1.012.267a1.139 1.139 0 01-.448-.067 3.566 3.566 0 01-.322-.198c-.195-.135-.363-.332-.612-.465v-.005h-.005c-.4-.246-.616-.512-.686-.71-.07-.268-.005-.47.193-.6.224-.135.38-.271.483-.336.104-.074.143-.102.176-.131h.002v-.003c.169-.202.436-.47.839-.601.139-.036.294-.065.466-.065zm2.8 2.142c.358 1.417 1.196 3.475 1.735 4.473.286.534.855 1.659 1.102 3.024.156-.005.33.018.513.064.646-1.671-.546-3.467-1.089-3.966-.22-.2-.232-.335-.123-.335.59.534 1.365 1.572 1.646 2.757.13.535.16 1.104.021 1.67.067.028.135.06.205.067 1.032.534 1.413.938 1.23 1.537v-.002c-.06-.135-.12-.2-.09-.267.046-.134.078-.333-.201-.465-.57-.267-.96-.4-1.18-.535a.98.98 0 01-.36-.4c-.298.533-.648.868-.94 1.002-.04-.2-.021-.4.09-.6a.71.71 0 01.381-.267c.376-.202.559-.47.646-.869.067-.399.024-.733-.135-1.135-.15-.4-.396-.665-.794-.933a2.01 2.01 0 00-.92-.267c-.435-.064-.747.048-.988.135-.075.022-.155.04-.239.054a2.56 2.56 0 01.106-.858c.09-.335.2-.6.323-.868a.262.262 0 01-.09-.134c-.067-.267-.2-.2-.33-.002a1.763 1.763 0 00-.172.535 2.114 2.114 0 00-.038.467c-.065.065-.132.135-.198.199-.257.193-.52.398-.737.601a2.71 2.71 0 01-.18-.202c-.27-.332-.393-.667-.354-1.067a.89.89 0 01.11-.334c.031-.053.067-.067.1-.135a.065.065 0 01.016-.023.09.09 0 01.015-.023v-.003a5.59 5.59 0 01.166-.267c.126-.2.27-.4.461-.602.14-.134.274-.267.41-.4.069-.066.14-.135.21-.2.07-.066.136-.135.203-.2.069-.134.202-.2.37-.266a.33.33 0 00.14-.067c-.12-.067-.137-.2-.061-.336.134-.332.453-.668.785-.933.332-.265.66-.4.875-.4.232.003.325.068.227.403z"})})]}),d.jsx("h2",{className:"text-2xl font-semibold text-gray-900 dark:text-white mb-2 text-center",children:"Cross-platform builds ready!"}),d.jsx("p",{className:"text-gray-500 dark:text-gray-400 mb-8 text-center max-w-md",children:"You can build for Windows, macOS, and Linux from this machine"}),d.jsxs("div",{className:"flex items-center gap-3",children:[i&&r&&d.jsx("button",{onClick:r,className:"px-4 py-2 rounded-lg text-sm font-medium transition-colors border border-gray-300 dark:border-gray-600 text-gray-600 dark:text-gray-400 hover:bg-gray-100 dark:hover:bg-gray-800",children:"Back"}),d.jsx("button",{onClick:n,className:"px-5 py-2 rounded-lg border border-red-500 text-red-600 dark:text-red-400 text-sm font-medium hover:bg-red-500/10 transition-colors",children:"Continue"})]})]}):d.jsxs(d.Fragment,{children:[d.jsxs("div",{className:"flex items-center gap-6 mb-8",children:[d.jsx("svg",{className:"w-12 h-12 text-gray-600 dark:text-gray-400",viewBox:"0 0 24 24",fill:"currentColor",children:d.jsx("path",{d:"M0 3.449L9.75 2.1v9.451H0m10.949-9.602L24 0v11.4H10.949M0 12.6h9.75v9.451L0 20.699M10.949 12.6H24V24l-12.9-1.801"})}),d.jsx("svg",{className:"w-12 h-12 text-gray-600 dark:text-gray-400",viewBox:"0 0 24 24",fill:"currentColor",children:d.jsx("path",{d:"M18.71 19.5c-.83 1.24-1.71 2.45-3.05 2.47-1.34.03-1.77-.79-3.29-.79-1.53 0-2 .77-3.27.82-1.31.05-2.3-1.32-3.14-2.53C4.25 17 2.94 12.45 4.7 9.39c.87-1.52 2.43-2.48 4.12-2.51 1.28-.02 2.5.87 3.29.87.78 0 2.26-1.07 3.81-.91.65.03 2.47.26 3.64 1.98-.09.06-2.17 1.28-2.15 3.81.03 3.02 2.65 4.03 2.68 4.04-.03.07-.42 1.44-1.38 2.83M13 3.5c.73-.83 1.94-1.46 2.94-1.5.13 1.17-.34 2.35-1.04 3.19-.69.85-1.83 1.51-2.95 1.42-.15-1.15.41-2.35 1.05-3.11z"})}),d.jsx("svg",{className:"w-12 h-12 text-gray-600 dark:text-gray-400",viewBox:"0 0 24 24",fill:"currentColor",children:d.jsx("path",{d:"M12.504 0c-.155 0-.315.008-.48.021-4.226.333-3.105 4.807-3.17 6.298-.076 1.092-.3 1.953-1.05 3.02-.885 1.051-2.127 2.75-2.716 4.521-.278.832-.41 1.684-.287 2.489a.424.424 0 00-.11.135c-.26.268-.45.6-.663.839-.199.199-.485.267-.797.4-.313.136-.658.269-.864.68-.09.189-.136.394-.132.602 0 .199.027.4.055.536.058.399.116.728.04.97-.249.68-.28 1.145-.106 1.484.174.334.535.47.94.601.81.2 1.91.135 2.774.6.926.466 1.866.67 2.616.47.526-.116.97-.464 1.208-.946.587-.003 1.23-.269 2.26-.334.699-.058 1.574.267 2.577.2.025.134.063.198.114.333l.003.003c.391.778 1.113 1.132 1.884 1.071.771-.06 1.592-.536 2.257-1.306.631-.765 1.683-1.084 2.378-1.503.348-.199.629-.469.649-.853.023-.4-.2-.811-.714-1.376v-.097l-.003-.003c-.17-.2-.25-.535-.338-.926-.085-.401-.182-.786-.492-1.046h-.003c-.059-.054-.123-.067-.188-.135a.357.357 0 00-.19-.064c.431-1.278.264-2.55-.173-3.694-.533-1.41-1.465-2.638-2.175-3.483-.796-1.005-1.576-1.957-1.56-3.368.026-2.152.236-6.133-3.544-6.139zm.529 3.405h.013c.213 0 .396.062.584.198.19.135.33.332.438.533.105.259.158.459.166.724 0-.02.006-.04.006-.06v.105a.086.086 0 01-.004-.021l-.004-.024a1.807 1.807 0 01-.15.706.953.953 0 01-.213.335.71.71 0 00-.088-.042c-.104-.045-.198-.064-.284-.133a1.312 1.312 0 00-.22-.066c.05-.06.146-.133.183-.198.053-.128.082-.264.088-.402v-.02a1.21 1.21 0 00-.061-.4c-.045-.134-.101-.2-.183-.333-.084-.066-.167-.132-.267-.132h-.016c-.093 0-.176.03-.262.132a.8.8 0 00-.205.334 1.18 1.18 0 00-.09.4v.019c.002.089.008.179.02.267-.193-.067-.438-.135-.607-.202a1.635 1.635 0 01-.018-.2v-.02a1.772 1.772 0 01.15-.768c.082-.22.232-.406.43-.533a.985.985 0 01.594-.2zm-2.962.059h.036c.142 0 .27.048.399.135.146.129.264.288.344.465.09.199.14.4.153.667v.004c.007.134.006.2-.002.266v.08c-.03.007-.056.018-.083.024-.152.055-.274.135-.393.2.012-.09.013-.18.003-.267v-.015c-.012-.133-.04-.2-.082-.333a.613.613 0 00-.166-.267.248.248 0 00-.183-.064h-.021c-.071.006-.13.04-.186.132a.552.552 0 00-.12.27.944.944 0 00-.023.33v.015c.012.135.037.2.08.334.046.134.098.2.166.268.01.009.02.018.034.024-.07.057-.117.07-.176.136a.304.304 0 01-.131.068 2.62 2.62 0 01-.275-.402 1.772 1.772 0 01-.155-.667 1.759 1.759 0 01.08-.668 1.43 1.43 0 01.283-.535c.128-.133.26-.2.418-.2zm1.37 1.706c.332 0 .733.065 1.216.399.293.2.523.269 1.052.468h.003c.255.136.405.266.478.399v-.131a.571.571 0 01.016.47c-.123.31-.516.643-1.063.842v.002c-.268.135-.501.333-.775.465-.276.135-.588.292-1.012.267a1.139 1.139 0 01-.448-.067 3.566 3.566 0 01-.322-.198c-.195-.135-.363-.332-.612-.465v-.005h-.005c-.4-.246-.616-.512-.686-.71-.07-.268-.005-.47.193-.6.224-.135.38-.271.483-.336.104-.074.143-.102.176-.131h.002v-.003c.169-.202.436-.47.839-.601.139-.036.294-.065.466-.065zm2.8 2.142c.358 1.417 1.196 3.475 1.735 4.473.286.534.855 1.659 1.102 3.024.156-.005.33.018.513.064.646-1.671-.546-3.467-1.089-3.966-.22-.2-.232-.335-.123-.335.59.534 1.365 1.572 1.646 2.757.13.535.16 1.104.021 1.67.067.028.135.06.205.067 1.032.534 1.413.938 1.23 1.537v-.002c-.06-.135-.12-.2-.09-.267.046-.134.078-.333-.201-.465-.57-.267-.96-.4-1.18-.535a.98.98 0 01-.36-.4c-.298.533-.648.868-.94 1.002-.04-.2-.021-.4.09-.6a.71.71 0 01.381-.267c.376-.202.559-.47.646-.869.067-.399.024-.733-.135-1.135-.15-.4-.396-.665-.794-.933a2.01 2.01 0 00-.92-.267c-.435-.064-.747.048-.988.135-.075.022-.155.04-.239.054a2.56 2.56 0 01.106-.858c.09-.335.2-.6.323-.868a.262.262 0 01-.09-.134c-.067-.267-.2-.2-.33-.002a1.763 1.763 0 00-.172.535 2.114 2.114 0 00-.038.467c-.065.065-.132.135-.198.199-.257.193-.52.398-.737.601a2.71 2.71 0 01-.18-.202c-.27-.332-.393-.667-.354-1.067a.89.89 0 01.11-.334c.031-.053.067-.067.1-.135a.065.065 0 01.016-.023.09.09 0 01.015-.023v-.003a5.59 5.59 0 01.166-.267c.126-.2.27-.4.461-.602.14-.134.274-.267.41-.4.069-.066.14-.135.21-.2.07-.066.136-.135.203-.2.069-.134.202-.2.37-.266a.33.33 0 00.14-.067c-.12-.067-.137-.2-.061-.336.134-.332.453-.668.785-.933.332-.265.66-.4.875-.4.232.003.325.068.227.403z"})})]}),d.jsx("h2",{className:"text-2xl font-semibold text-gray-900 dark:text-white mb-2 text-center",children:"Build for multiple platforms?"}),d.jsx("p",{className:"text-gray-500 dark:text-gray-400 mb-2 text-center max-w-md",children:"Wails can compile your app for Windows, macOS, and Linux from a single machine"}),d.jsx("p",{className:"text-xs text-gray-400 dark:text-gray-500 mb-8 text-center",children:"Requires Docker for cross-compilation"}),d.jsxs("div",{className:"flex flex-col items-center gap-2",children:[d.jsxs("div",{className:"flex items-center gap-3",children:[i&&r&&d.jsx("button",{onClick:r,className:"px-4 py-2 rounded-lg text-sm font-medium transition-colors border border-gray-300 dark:border-gray-600 text-gray-600 dark:text-gray-400 hover:bg-gray-100 dark:hover:bg-gray-800",children:"Back"}),d.jsx("button",{onClick:t,className:"px-5 py-2 rounded-lg border border-red-500 text-red-600 dark:text-red-400 text-sm font-medium hover:bg-red-500/10 transition-colors",children:"Yes, set this up"})]}),d.jsx("button",{onClick:n,className:"text-xs text-gray-500 dark:text-gray-400 hover:text-gray-700 dark:hover:text-gray-300 transition-colors",children:"Not right now"})]})]})})}function b3({onBuildImage:e,onUseLocalSDK:t,onSkip:n}){const[r,i]=C.useState(!1),[s,o]=C.useState(null),a=async()=>{if(!s){const u=await(await fetch("/api/docker/logs")).text();o(u)}i(!0)};return r?d.jsxs(B.div,{variants:we,initial:"initial",animate:"animate",exit:"exit",transition:{duration:.3},className:"flex-1 flex flex-col items-center justify-center max-w-4xl mx-auto w-full",children:[d.jsxs("div",{className:"w-full flex items-center justify-between mb-4",children:[d.jsx("h2",{className:"text-lg font-semibold text-gray-900 dark:text-white",children:"Build Logs"}),d.jsx("button",{onClick:()=>i(!1),className:"text-sm text-gray-500 hover:text-gray-700 dark:text-gray-400 dark:hover:text-gray-200",children:"Back"})]}),d.jsx("pre",{className:"w-full h-96 overflow-auto bg-gray-900 text-gray-100 p-4 rounded-lg text-xs font-mono whitespace-pre-wrap",children:s||"No logs available"})]}):d.jsxs(B.div,{variants:we,initial:"initial",animate:"animate",exit:"exit",transition:{duration:.3},className:"flex-1 flex flex-col items-center justify-center",children:[d.jsx("div",{className:"w-16 h-16 rounded-2xl bg-amber-500/20 flex items-center justify-center mb-6",children:d.jsx("svg",{className:"w-8 h-8 text-amber-500",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",children:d.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,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"})})}),d.jsx("h2",{className:"text-xl font-semibold text-gray-900 dark:text-white mb-2",children:"Build failed"}),d.jsx("p",{className:"text-sm text-gray-500 dark:text-gray-400 mb-2 text-center max-w-sm",children:"Check your internet connection and try again, or download the SDK manually."}),d.jsx("button",{onClick:a,className:"text-sm text-blue-500 hover:text-blue-600 mb-6",children:"View logs"}),d.jsxs("div",{className:"flex flex-col gap-3 items-center",children:[d.jsxs("div",{className:"flex gap-3",children:[d.jsx("button",{onClick:e,className:"px-5 py-2.5 rounded-lg bg-blue-500 text-white text-sm font-medium hover:bg-blue-600 transition-colors",children:"Try again"}),d.jsxs("label",{className:"px-5 py-2.5 rounded-lg border border-blue-500 text-blue-600 dark:text-blue-400 text-sm font-medium hover:bg-blue-500/10 transition-colors cursor-pointer",children:["Use local file",d.jsx("input",{type:"file",accept:".tar.xz",className:"hidden",onChange:l=>{var c;const u=(c=l.target.files)==null?void 0:c[0];u&&t(u)}})]})]}),d.jsx("a",{href:"https://github.com/wailsapp/macosx-sdks/releases/download/26.1/MacOSX26.1.sdk.tar.xz",download:!0,className:"text-xs text-gray-500 dark:text-gray-400 hover:text-gray-700 dark:hover:text-gray-300 transition-colors",children:"Download SDK manually"}),d.jsx("button",{onClick:n,className:"text-xs text-gray-500 dark:text-gray-400 hover:text-gray-700 dark:hover:text-gray-300 transition-colors",children:"Skip for now"})]})]})}function L3({onAgree:e,onDecline:t,onBack:n,canGoBack:r}){const[i,s]=C.useState(!1);return d.jsxs(B.div,{variants:we,initial:"initial",animate:"animate",exit:"exit",transition:{duration:.3},className:"flex-1 flex flex-col items-center justify-center",children:[r&&n&&d.jsx("button",{onClick:n,className:"absolute top-4 left-4 p-2 rounded-lg text-gray-500 hover:text-gray-700 dark:text-gray-400 dark:hover:text-gray-200 hover:bg-gray-100 dark:hover:bg-gray-800 transition-colors","aria-label":"Go back",children:d.jsx("svg",{className:"w-5 h-5",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",children:d.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M15 19l-7-7 7-7"})})}),d.jsx("div",{className:"w-12 h-12 rounded-xl bg-gray-100 dark:bg-gray-800 flex items-center justify-center mb-4",children:d.jsx("svg",{className:"w-6 h-6 text-gray-600 dark:text-gray-300",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",children:d.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M9 12h6m-6 4h6m2 5H7a2 2 0 01-2-2V5a2 2 0 012-2h5.586a1 1 0 01.707.293l5.414 5.414a1 1 0 01.293.707V19a2 2 0 01-2 2z"})})}),d.jsx("h2",{className:"text-lg font-semibold text-gray-900 dark:text-white mb-1",children:"Apple SDK License Agreement"}),d.jsx("p",{className:"text-sm text-gray-500 dark:text-gray-400 mb-4 text-center max-w-md",children:"Cross-platform builds for macOS require the Apple SDK. Please review and accept the license terms."}),d.jsx("div",{className:"w-full max-w-2xl h-72 mb-4 rounded-lg overflow-hidden border border-gray-200 dark:border-gray-700 bg-white",children:d.jsx("iframe",{src:"/assets/apple-sdk-license.pdf#view=FitH&navpanes=0&toolbar=0",className:"w-full h-full",title:"Apple Xcode and SDK License Agreement"})}),d.jsxs("label",{className:"flex items-center gap-2 mb-5 cursor-pointer",children:[d.jsx("input",{type:"checkbox",checked:i,onChange:o=>s(o.target.checked),className:"w-4 h-4 rounded border-gray-300 text-blue-500 focus:ring-blue-500"}),d.jsx("span",{className:"text-sm text-gray-600 dark:text-gray-300",children:"I agree to Apple's Xcode and SDK License Agreement"})]}),d.jsxs("div",{className:"flex gap-3",children:[d.jsx("button",{onClick:t,className:"px-5 py-2.5 rounded-lg border border-gray-300 dark:border-gray-600 text-gray-700 dark:text-gray-300 text-sm font-medium hover:bg-gray-50 dark:hover:bg-gray-800 transition-colors",children:"Skip cross-platform"}),d.jsx("button",{onClick:e,disabled:!i,className:`px-5 py-2.5 rounded-lg text-sm font-medium transition-colors ${i?"bg-blue-500 text-white hover:bg-blue-600":"bg-gray-200 text-gray-400 cursor-not-allowed"}`,children:"Continue"})]})]})}function A3({dockerStatus:e,buildingImage:t,onBuildImage:n,onCheckAgain:r,onContinueBackground:i,onUseLocalSDK:s,onSkip:o,onBack:a,canGoBack:l}){if(!e||!e.installed)return d.jsxs(B.div,{variants:we,initial:"initial",animate:"animate",exit:"exit",transition:{duration:.3},className:"flex-1 flex flex-col items-center justify-center",children:[d.jsx("div",{className:"w-16 h-16 rounded-2xl bg-blue-500/20 flex items-center justify-center mb-6",children:d.jsx("svg",{className:"w-10 h-10",viewBox:"0 0 756.26 596.9",children:d.jsx("path",{fill:"#1d63ed",d:"M743.96,245.25c-18.54-12.48-67.26-17.81-102.68-8.27-1.91-35.28-20.1-65.01-53.38-90.95l-12.32-8.27-8.21,12.4c-16.14,24.5-22.94,57.14-20.53,86.81,1.9,18.28,8.26,38.83,20.53,53.74-46.1,26.74-88.59,20.67-276.77,20.67H.06c-.85,42.49,5.98,124.23,57.96,190.77,5.74,7.35,12.04,14.46,18.87,21.31,42.26,42.32,106.11,73.35,201.59,73.44,145.66.13,270.46-78.6,346.37-268.97,24.98.41,90.92,4.48,123.19-57.88.79-1.05,8.21-16.54,8.21-16.54l-12.3-8.27ZM189.67,206.39h-81.7v81.7h81.7v-81.7ZM295.22,206.39h-81.7v81.7h81.7v-81.7ZM400.77,206.39h-81.7v81.7h81.7v-81.7ZM506.32,206.39h-81.7v81.7h81.7v-81.7ZM84.12,206.39H2.42v81.7h81.7v-81.7ZM189.67,103.2h-81.7v81.7h81.7v-81.7ZM295.22,103.2h-81.7v81.7h81.7v-81.7ZM400.77,103.2h-81.7v81.7h81.7v-81.7ZM400.77,0h-81.7v81.7h81.7V0Z"})})}),d.jsx("h2",{className:"text-xl font-semibold text-gray-900 dark:text-white mb-2",children:"Install Docker"}),d.jsx("p",{className:"text-gray-500 dark:text-gray-400 mb-6 text-center max-w-sm",children:"Cross-platform builds require Docker Desktop"}),d.jsxs("a",{href:"https://docs.docker.com/get-docker/",target:"_blank",rel:"noopener noreferrer",className:"px-5 py-2 rounded-lg bg-blue-600 text-white text-sm font-medium hover:bg-blue-500 transition-colors inline-flex items-center gap-2 mb-4",children:["Download Docker Desktop",d.jsx("svg",{className:"w-4 h-4",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",children:d.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M10 6H6a2 2 0 00-2 2v10a2 2 0 002 2h10a2 2 0 002-2v-4M14 4h6m0 0v6m0-6L10 14"})})]}),d.jsx("p",{className:"text-xs text-gray-400 dark:text-gray-500 mb-6 text-center max-w-xs",children:"After installing, come back and we'll continue setting up. Some platforms may require a reboot."}),d.jsxs("div",{className:"flex flex-col items-center gap-1.5",children:[d.jsxs("div",{className:"flex items-center gap-3",children:[l&&a&&d.jsx("button",{onClick:a,className:"px-4 py-2 rounded-lg text-sm font-medium transition-colors border border-gray-300 dark:border-gray-600 text-gray-600 dark:text-gray-400 hover:bg-gray-100 dark:hover:bg-gray-800",children:"Back"}),d.jsx("button",{onClick:r,className:"px-5 py-1.5 rounded-lg bg-gray-100 dark:bg-gray-800 text-gray-700 dark:text-gray-300 text-sm font-medium hover:bg-gray-200 dark:hover:bg-gray-700 transition-colors",children:"Check Again"})]}),d.jsx("button",{onClick:o,className:"text-xs text-gray-500 dark:text-gray-400 hover:text-gray-700 dark:hover:text-gray-300 transition-colors",children:"Skip for now"})]})]});if(!e.running)return d.jsxs(B.div,{variants:we,initial:"initial",animate:"animate",exit:"exit",transition:{duration:.3},className:"flex-1 flex flex-col items-center justify-center",children:[d.jsx("div",{className:"w-16 h-16 rounded-2xl bg-gray-200 dark:bg-gray-800 flex items-center justify-center mb-6 opacity-50",children:d.jsx("svg",{className:"w-10 h-10",viewBox:"0 0 756.26 596.9",children:d.jsx("path",{fill:"#6b7280",d:"M743.96,245.25c-18.54-12.48-67.26-17.81-102.68-8.27-1.91-35.28-20.1-65.01-53.38-90.95l-12.32-8.27-8.21,12.4c-16.14,24.5-22.94,57.14-20.53,86.81,1.9,18.28,8.26,38.83,20.53,53.74-46.1,26.74-88.59,20.67-276.77,20.67H.06c-.85,42.49,5.98,124.23,57.96,190.77,5.74,7.35,12.04,14.46,18.87,21.31,42.26,42.32,106.11,73.35,201.59,73.44,145.66.13,270.46-78.6,346.37-268.97,24.98.41,90.92,4.48,123.19-57.88.79-1.05,8.21-16.54,8.21-16.54l-12.3-8.27ZM189.67,206.39h-81.7v81.7h81.7v-81.7ZM295.22,206.39h-81.7v81.7h81.7v-81.7ZM400.77,206.39h-81.7v81.7h81.7v-81.7ZM506.32,206.39h-81.7v81.7h81.7v-81.7ZM84.12,206.39H2.42v81.7h81.7v-81.7ZM189.67,103.2h-81.7v81.7h81.7v-81.7ZM295.22,103.2h-81.7v81.7h81.7v-81.7ZM400.77,103.2h-81.7v81.7h81.7v-81.7ZM400.77,0h-81.7v81.7h81.7V0Z"})})}),d.jsx("h2",{className:"text-xl font-semibold text-gray-900 dark:text-white mb-2",children:"Start Docker"}),d.jsx("p",{className:"text-gray-500 dark:text-gray-400 mb-8 text-center max-w-sm",children:"Please start Docker Desktop to continue"}),d.jsxs("div",{className:"flex flex-col items-center gap-1.5",children:[d.jsxs("div",{className:"flex items-center gap-3",children:[l&&a&&d.jsx("button",{onClick:a,className:"px-4 py-2 rounded-lg text-sm font-medium transition-colors border border-gray-300 dark:border-gray-600 text-gray-600 dark:text-gray-400 hover:bg-gray-100 dark:hover:bg-gray-800",children:"Back"}),d.jsx("button",{onClick:r,className:"px-5 py-2 rounded-lg border border-red-500 text-red-600 dark:text-red-400 text-sm font-medium hover:bg-red-500/10 transition-colors",children:"Check Again"})]}),d.jsx("button",{onClick:o,className:"text-xs text-gray-500 dark:text-gray-400 hover:text-gray-700 dark:hover:text-gray-300 transition-colors",children:"Skip for now"})]})]});if(t||e.pullStatus==="pulling"){const u=e.pullProgress||0,c=e.pullMessage||"Connecting";return d.jsxs(B.div,{variants:we,initial:"initial",animate:"animate",exit:"exit",transition:{duration:.3},className:"flex-1 flex flex-col items-center justify-center",children:[d.jsx("div",{className:"w-16 h-16 rounded-2xl bg-blue-500/20 flex items-center justify-center mb-6",children:d.jsx("svg",{className:"w-10 h-10",viewBox:"0 0 756.26 596.9",children:d.jsx("path",{fill:"#1d63ed",d:"M743.96,245.25c-18.54-12.48-67.26-17.81-102.68-8.27-1.91-35.28-20.1-65.01-53.38-90.95l-12.32-8.27-8.21,12.4c-16.14,24.5-22.94,57.14-20.53,86.81,1.9,18.28,8.26,38.83,20.53,53.74-46.1,26.74-88.59,20.67-276.77,20.67H.06c-.85,42.49,5.98,124.23,57.96,190.77,5.74,7.35,12.04,14.46,18.87,21.31,42.26,42.32,106.11,73.35,201.59,73.44,145.66.13,270.46-78.6,346.37-268.97,24.98.41,90.92,4.48,123.19-57.88.79-1.05,8.21-16.54,8.21-16.54l-12.3-8.27ZM189.67,206.39h-81.7v81.7h81.7v-81.7ZM295.22,206.39h-81.7v81.7h81.7v-81.7ZM400.77,206.39h-81.7v81.7h81.7v-81.7ZM506.32,206.39h-81.7v81.7h81.7v-81.7ZM84.12,206.39H2.42v81.7h81.7v-81.7ZM189.67,103.2h-81.7v81.7h81.7v-81.7ZM295.22,103.2h-81.7v81.7h81.7v-81.7ZM400.77,103.2h-81.7v81.7h81.7v-81.7ZM400.77,0h-81.7v81.7h81.7V0Z"})})}),d.jsx("h2",{className:"text-xl font-semibold text-gray-900 dark:text-white mb-2",children:"Downloading cross-compiler image"}),d.jsxs("div",{className:"w-64 mb-4",children:[d.jsxs("div",{className:"flex items-center justify-between text-sm text-gray-500 mb-1",children:[d.jsx("span",{children:c}),d.jsxs("span",{children:[u,"%"]})]}),d.jsx("div",{className:"h-2 bg-gray-200 dark:bg-gray-700 rounded-full overflow-hidden",children:d.jsx(B.div,{className:"h-full bg-blue-500",animate:{width:`${u}%`}})})]}),d.jsx("p",{className:"text-xs text-gray-400 dark:text-gray-500 mb-8 text-center",children:"This may take several minutes"}),d.jsx("button",{onClick:i,className:"px-5 py-2 rounded-lg border border-red-500 text-red-600 dark:text-red-400 text-sm font-medium hover:bg-red-500/10 transition-colors",children:"Continue in background"})]})}return e.pullStatus==="error"?d.jsx(b3,{onBuildImage:n,onUseLocalSDK:s,onSkip:o}):e.imageBuilt?d.jsxs(B.div,{variants:we,initial:"initial",animate:"animate",exit:"exit",transition:{duration:.3},className:"flex-1 flex flex-col items-center justify-center",children:[d.jsx(B.div,{initial:{scale:0},animate:{scale:1},transition:{type:"spring",stiffness:200,damping:15},className:"w-16 h-16 rounded-2xl bg-green-500/20 flex items-center justify-center mb-6",children:d.jsx("svg",{className:"w-8 h-8 text-green-500",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",children:d.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2.5,d:"M5 13l4 4L19 7"})})}),d.jsx("h2",{className:"text-xl font-semibold text-gray-900 dark:text-white mb-2",children:"Cross-platform builds ready!"}),d.jsx("p",{className:"text-gray-500 dark:text-gray-400 mb-8 text-center max-w-sm",children:"You can now build for Windows, macOS, and Linux"}),d.jsxs("div",{className:"flex items-center gap-3",children:[l&&a&&d.jsx("button",{onClick:a,className:"px-4 py-2 rounded-lg text-sm font-medium transition-colors border border-gray-300 dark:border-gray-600 text-gray-600 dark:text-gray-400 hover:bg-gray-100 dark:hover:bg-gray-800",children:"Back"}),d.jsx("button",{onClick:i,className:"px-5 py-2 rounded-lg border border-red-500 text-red-600 dark:text-red-400 text-sm font-medium hover:bg-red-500/10 transition-colors",children:"Continue"})]})]}):d.jsxs(B.div,{variants:we,initial:"initial",animate:"animate",exit:"exit",transition:{duration:.3},className:"flex-1 flex flex-col items-center justify-center",children:[d.jsx("div",{className:"w-16 h-16 rounded-2xl bg-blue-500/20 flex items-center justify-center mb-6",children:d.jsx("svg",{className:"w-10 h-10",viewBox:"0 0 756.26 596.9",children:d.jsx("path",{fill:"#1d63ed",d:"M743.96,245.25c-18.54-12.48-67.26-17.81-102.68-8.27-1.91-35.28-20.1-65.01-53.38-90.95l-12.32-8.27-8.21,12.4c-16.14,24.5-22.94,57.14-20.53,86.81,1.9,18.28,8.26,38.83,20.53,53.74-46.1,26.74-88.59,20.67-276.77,20.67H.06c-.85,42.49,5.98,124.23,57.96,190.77,5.74,7.35,12.04,14.46,18.87,21.31,42.26,42.32,106.11,73.35,201.59,73.44,145.66.13,270.46-78.6,346.37-268.97,24.98.41,90.92,4.48,123.19-57.88.79-1.05,8.21-16.54,8.21-16.54l-12.3-8.27ZM189.67,206.39h-81.7v81.7h81.7v-81.7ZM295.22,206.39h-81.7v81.7h81.7v-81.7ZM400.77,206.39h-81.7v81.7h81.7v-81.7ZM506.32,206.39h-81.7v81.7h81.7v-81.7ZM84.12,206.39H2.42v81.7h81.7v-81.7ZM189.67,103.2h-81.7v81.7h81.7v-81.7ZM295.22,103.2h-81.7v81.7h81.7v-81.7ZM400.77,103.2h-81.7v81.7h81.7v-81.7ZM400.77,0h-81.7v81.7h81.7V0Z"})})}),d.jsx("h2",{className:"text-xl font-semibold text-gray-900 dark:text-white mb-2",children:"Docker is ready!"}),d.jsx("p",{className:"text-gray-500 dark:text-gray-400 mb-2 text-center max-w-sm",children:"Download the cross-compilation image to enable building for all platforms"}),d.jsx("p",{className:"text-xs text-gray-400 dark:text-gray-500 mb-8 text-center",children:"This will download ~800MB and may take several minutes"}),d.jsxs("div",{className:"flex flex-col items-center gap-2",children:[d.jsxs("div",{className:"flex items-center gap-3",children:[l&&a&&d.jsx("button",{onClick:a,className:"px-4 py-2 rounded-lg text-sm font-medium transition-colors border border-gray-300 dark:border-gray-600 text-gray-600 dark:text-gray-400 hover:bg-gray-100 dark:hover:bg-gray-800",children:"Back"}),d.jsx("button",{onClick:n,className:"px-5 py-2 rounded-lg bg-blue-600 text-white text-sm font-medium hover:bg-blue-500 transition-colors",children:"Download Image"})]}),d.jsx("button",{onClick:o,className:"text-xs text-gray-500 dark:text-gray-400 hover:text-gray-700 dark:hover:text-gray-300 transition-colors",children:"Skip, I'll do it later"})]})]})}const R3=[{id:"vanilla",name:"Vanilla",description:"Plain JavaScript/TypeScript",color:"#f7df1e",icon:"javascript"},{id:"react",name:"React",description:"React with Vite",color:"#61dafb",icon:"react"},{id:"vue",name:"Vue",description:"Vue 3 with Vite",color:"#42b883",icon:"vue"},{id:"svelte",name:"Svelte",description:"Svelte with Vite",color:"#ff3e00",icon:"svelte"},{id:"preact",name:"Preact",description:"Lightweight React alternative",color:"#673ab8",icon:"preact"},{id:"lit",name:"Lit",description:"Web Components with Lit",color:"#324fff",icon:"lit"},{id:"solid",name:"Solid",description:"Solid.js with Vite",color:"#2c4f7c",icon:"solid"},{id:"qwik",name:"Qwik",description:"Qwik with Vite",color:"#18b6f6",icon:"qwik"}];function V3({preferTypeScript:e,onSelect:t,onNext:n,onBack:r,canGoBack:i}){const s=C.useRef(null);return C.useEffect(()=>{var o;(o=s.current)==null||o.focus()},[]),d.jsxs(B.main,{variants:we,initial:"initial",animate:"animate",exit:"exit",transition:{duration:.3},className:"flex-1 flex flex-col items-center justify-center","aria-labelledby":"language-title",children:[d.jsx("h2",{ref:s,id:"language-title",className:"text-2xl font-semibold text-gray-900 dark:text-white mb-2 text-center focus:outline-none",tabIndex:-1,children:"Language Preference"}),d.jsx("p",{className:"text-gray-500 dark:text-gray-400 mb-8 text-center max-w-md",children:"Choose your preferred language for new projects"}),d.jsxs("div",{className:"flex gap-4 mb-8",role:"radiogroup","aria-label":"Programming language",children:[d.jsxs("button",{onClick:()=>t(!1),role:"radio","aria-checked":!e,className:`w-40 h-48 rounded-xl p-5 flex flex-col items-center justify-center gap-3 transition-all border-2 focus:outline-none focus:ring-2 focus:ring-yellow-400 focus:ring-offset-2 dark:focus:ring-offset-gray-900 ${e?"border-gray-200 dark:border-white/10 bg-gray-100 dark:bg-white/5 hover:bg-gray-200 dark:hover:bg-white/10":"border-yellow-400 bg-yellow-400/10 shadow-lg shadow-yellow-400/20"}`,children:[d.jsx("div",{className:"w-16 h-16 flex items-center justify-center","aria-hidden":"true",children:d.jsx("img",{src:"/logos/javascript.svg",alt:"",className:"w-14 h-14"})}),d.jsx("span",{className:"text-lg font-semibold text-gray-900 dark:text-white",children:"JavaScript"}),d.jsx("span",{className:"text-xs text-gray-500 dark:text-white/50",children:"Dynamic typing"})]}),d.jsxs("button",{onClick:()=>t(!0),role:"radio","aria-checked":e,className:`w-40 h-48 rounded-xl p-5 flex flex-col items-center justify-center gap-3 transition-all border-2 focus:outline-none focus:ring-2 focus:ring-blue-400 focus:ring-offset-2 dark:focus:ring-offset-gray-900 ${e?"border-blue-400 bg-blue-400/10 shadow-lg shadow-blue-400/20":"border-gray-200 dark:border-white/10 bg-gray-100 dark:bg-white/5 hover:bg-gray-200 dark:hover:bg-white/10"}`,children:[d.jsx("div",{className:"w-16 h-16 flex items-center justify-center","aria-hidden":"true",children:d.jsx("img",{src:"/logos/typescript.svg",alt:"",className:"w-14 h-14"})}),d.jsx("span",{className:"text-lg font-semibold text-gray-900 dark:text-white",children:"TypeScript"}),d.jsx("span",{className:"text-xs text-gray-500 dark:text-white/50",children:"Type safety"})]})]}),d.jsxs("div",{className:"flex items-center gap-3",role:"group","aria-label":"Navigation",children:[i&&r&&d.jsx("button",{onClick:r,className:"px-4 py-2 rounded-lg text-sm font-medium transition-colors border border-gray-300 dark:border-gray-600 text-gray-600 dark:text-gray-400 hover:bg-gray-100 dark:hover:bg-gray-800 focus:outline-none focus:ring-2 focus:ring-gray-500 focus:ring-offset-2 dark:focus:ring-offset-gray-900",children:"Back"}),d.jsx("button",{onClick:n,className:"px-6 py-2.5 rounded-lg border border-red-500 text-red-600 dark:text-red-400 text-sm font-medium hover:bg-red-500/10 transition-colors focus:outline-none focus:ring-2 focus:ring-red-500 focus:ring-offset-2 dark:focus:ring-offset-gray-900",children:"Continue"})]})]})}function I3({useInterfaces:e,onSelect:t,onNext:n,onBack:r,canGoBack:i}){const s=C.useRef(null);return C.useEffect(()=>{var o;(o=s.current)==null||o.focus()},[]),d.jsxs(B.main,{variants:we,initial:"initial",animate:"animate",exit:"exit",transition:{duration:.3},className:"flex-1 flex flex-col items-center justify-center px-4 overflow-hidden","aria-labelledby":"binding-title",children:[d.jsx("h2",{ref:s,id:"binding-title",className:"text-2xl font-semibold text-gray-900 dark:text-white mb-2 text-center focus:outline-none",tabIndex:-1,children:"TypeScript Binding Style"}),d.jsx("p",{className:"text-gray-500 dark:text-gray-400 mb-6 text-center max-w-lg",children:"Choose how Go structs are represented in TypeScript"}),d.jsxs("div",{className:"flex gap-4 mb-8 max-w-full overflow-x-auto p-1",role:"radiogroup","aria-label":"Binding style",children:[d.jsxs("button",{onClick:()=>t(!0),role:"radio","aria-checked":e,className:`w-56 shrink-0 rounded-xl p-4 flex flex-col items-start gap-2 transition-all border-2 text-left focus:outline-none focus:ring-2 focus:ring-blue-400 focus:ring-offset-2 dark:focus:ring-offset-gray-900 ${e?"border-blue-400 bg-blue-400/10 shadow-lg shadow-blue-400/20":"border-white/10 bg-white/5 hover:bg-white/10"}`,children:[d.jsx("span",{className:"text-base font-semibold text-gray-900 dark:text-white",children:"Interfaces"}),d.jsx("pre",{className:"text-[10px] leading-tight text-gray-700 dark:text-white/70 font-mono bg-gray-100 dark:bg-black/30 p-2 rounded-lg w-full overflow-x-auto","aria-hidden":"true",children:`interface Person { + name: string; + age: number; +}`}),d.jsxs("ul",{className:"text-[10px] text-gray-500 dark:text-white/50 space-y-0.5","aria-label":"Features",children:[d.jsx("li",{children:"Lightweight types"}),d.jsx("li",{children:"No runtime code"}),d.jsx("li",{children:"Simpler output"})]})]}),d.jsxs("button",{onClick:()=>t(!1),role:"radio","aria-checked":!e,className:`w-56 shrink-0 rounded-xl p-4 flex flex-col items-start gap-2 transition-all border-2 text-left focus:outline-none focus:ring-2 focus:ring-purple-400 focus:ring-offset-2 dark:focus:ring-offset-gray-900 ${e?"border-white/10 bg-white/5 hover:bg-white/10":"border-purple-400 bg-purple-400/10 shadow-lg shadow-purple-400/20"}`,children:[d.jsx("span",{className:"text-base font-semibold text-gray-900 dark:text-white",children:"Classes"}),d.jsx("pre",{className:"text-[10px] leading-tight text-gray-700 dark:text-white/70 font-mono bg-gray-100 dark:bg-black/30 p-2 rounded-lg w-full overflow-x-auto","aria-hidden":"true",children:`class Person { + name: string; + age: number; + constructor(src) { + Object.assign(this, src); + } + static createFrom(src) { + return new Person(src); + } +}`}),d.jsxs("ul",{className:"text-[10px] text-gray-500 dark:text-white/50 space-y-0.5","aria-label":"Features",children:[d.jsx("li",{children:"Factory methods"}),d.jsx("li",{children:"Default initialization"}),d.jsx("li",{children:"More verbose"})]})]})]}),d.jsxs("div",{className:"flex items-center gap-3",role:"group","aria-label":"Navigation",children:[i&&r&&d.jsx("button",{onClick:r,className:"px-4 py-2 rounded-lg text-sm font-medium transition-colors border border-gray-300 dark:border-gray-600 text-gray-600 dark:text-gray-400 hover:bg-gray-100 dark:hover:bg-gray-800 focus:outline-none focus:ring-2 focus:ring-gray-500 focus:ring-offset-2 dark:focus:ring-offset-gray-900",children:"Back"}),d.jsx("button",{onClick:n,className:"px-6 py-2.5 rounded-lg border border-red-500 text-red-600 dark:text-red-400 text-sm font-medium hover:bg-red-500/10 transition-colors focus:outline-none focus:ring-2 focus:ring-red-500 focus:ring-offset-2 dark:focus:ring-offset-gray-900",children:"Continue"})]})]})}function _3({selectedFramework:e,preferTypeScript:t,onSelect:n,onNext:r,onSkip:i,onBack:s,canGoBack:o}){return d.jsx(Eu,{title:"Default Template",subtitle:"Choose a framework for new projects",primaryAction:r,primaryLabel:"Continue",secondaryAction:i,secondaryLabel:"Skip",onBack:s,canGoBack:o,children:d.jsx("div",{className:"grid grid-cols-4 gap-3 max-w-2xl mx-auto p-1",role:"radiogroup","aria-label":"Framework templates",children:R3.map(a=>d.jsxs("button",{onClick:()=>n(a.id),role:"radio","aria-checked":e===a.id,className:`aspect-square rounded-xl p-4 flex flex-col items-center justify-center gap-2 transition-all border-2 focus:outline-none focus:ring-2 focus:ring-red-500 focus:ring-offset-2 dark:focus:ring-offset-gray-900 ${e===a.id?"border-red-500 bg-red-500/10 shadow-lg shadow-red-500/10":"border-gray-200 dark:border-white/10 bg-gray-100 dark:bg-white/5 hover:bg-gray-200 dark:hover:bg-white/10"}`,children:[d.jsx("img",{src:`/logos/${a.id==="vanilla"?t?"typescript":"javascript":a.icon}.svg`,alt:"","aria-hidden":"true",className:"w-12 h-12"}),d.jsx("span",{className:"text-sm font-medium text-gray-900 dark:text-white",children:a.name})]},a.id))})})}function F3({defaults:e,onDefaultsChange:t,onNext:n,onSkip:r,saving:i,onBack:s,canGoBack:o}){const[a,l]=C.useState(null),[u,c]=C.useState(""),h=v=>{v==="name"?c(e.author.name):v==="company"?c(e.author.company):v==="bundleId"&&c(e.project.productIdentifierPrefix),l(v)},f=()=>{a==="name"?t({...e,author:{...e.author,name:u}}):a==="company"?t({...e,author:{...e.author,company:u}}):a==="bundleId"&&t({...e,project:{...e.project,productIdentifierPrefix:u}}),l(null)},y=v=>{v.key==="Enter"?f():v.key==="Escape"&&l(null)};return d.jsx(Eu,{title:"Project Defaults",subtitle:"Set defaults for new Wails projects",primaryAction:n,primaryLabel:i?"Saving...":"Continue",primaryDisabled:i,secondaryAction:r,secondaryLabel:"Skip",onBack:s,canGoBack:o,children:d.jsxs("div",{className:"max-w-xl mx-auto",children:[d.jsxs("div",{className:"settings-group",role:"group","aria-label":"Project default settings",children:[a==="name"?d.jsxs("div",{className:"settings-row",children:[d.jsx("label",{htmlFor:"author-input",className:"sr-only",children:"Author name"}),d.jsx("div",{className:"flex-1",children:d.jsx("input",{id:"author-input",type:"text",value:u,onChange:v=>c(v.target.value),onKeyDown:y,onBlur:f,autoFocus:!0,placeholder:"Your Name","aria-label":"Author name",className:"w-full bg-transparent border-none text-sm text-gray-900 dark:text-white placeholder-gray-400 dark:placeholder-gray-500 focus:outline-none focus:ring-2 focus:ring-red-500 rounded px-1"})})]}):d.jsxs("button",{className:"settings-row w-full text-left focus:outline-none focus:ring-2 focus:ring-inset focus:ring-red-500",onClick:()=>h("name"),"aria-label":`Author: ${e.author.name||"Not set"}. Click to edit.`,children:[d.jsx("span",{className:"text-sm font-medium text-gray-800 dark:text-white/90",children:"Author"}),d.jsxs("div",{className:"flex items-center gap-2 text-sm text-gray-600 dark:text-white/65",children:[d.jsx("span",{children:e.author.name||"Not set"}),d.jsx("span",{className:"text-gray-400 dark:text-white/40 text-xs","aria-hidden":"true",children:"▸"})]})]}),a==="company"?d.jsxs("div",{className:"settings-row",children:[d.jsx("label",{htmlFor:"company-input",className:"sr-only",children:"Company name"}),d.jsx("div",{className:"flex-1",children:d.jsx("input",{id:"company-input",type:"text",value:u,onChange:v=>c(v.target.value),onKeyDown:y,onBlur:f,autoFocus:!0,placeholder:"Acme Corp","aria-label":"Company name",className:"w-full bg-transparent border-none text-sm text-gray-900 dark:text-white placeholder-gray-400 dark:placeholder-gray-500 focus:outline-none focus:ring-2 focus:ring-red-500 rounded px-1"})})]}):d.jsxs("button",{className:"settings-row w-full text-left focus:outline-none focus:ring-2 focus:ring-inset focus:ring-red-500",onClick:()=>h("company"),"aria-label":`Company: ${e.author.company||"Not set"}. Click to edit.`,children:[d.jsx("span",{className:"text-sm font-medium text-gray-800 dark:text-white/90",children:"Company"}),d.jsxs("div",{className:"flex items-center gap-2 text-sm text-gray-600 dark:text-white/65",children:[d.jsx("span",{children:e.author.company||"Not set"}),d.jsx("span",{className:"text-gray-400 dark:text-white/40 text-xs","aria-hidden":"true",children:"▸"})]})]}),a==="bundleId"?d.jsxs("div",{className:"settings-row",children:[d.jsx("label",{htmlFor:"bundle-input",className:"sr-only",children:"Bundle identifier"}),d.jsx("div",{className:"flex-1",children:d.jsx("input",{id:"bundle-input",type:"text",value:u,onChange:v=>c(v.target.value),onKeyDown:y,onBlur:f,autoFocus:!0,placeholder:"com.example","aria-label":"Bundle identifier",className:"w-full bg-transparent border-none text-sm text-gray-900 dark:text-white placeholder-gray-400 dark:placeholder-gray-500 focus:outline-none focus:ring-2 focus:ring-red-500 rounded px-1 font-mono"})})]}):d.jsxs("button",{className:"settings-row w-full text-left focus:outline-none focus:ring-2 focus:ring-inset focus:ring-red-500",onClick:()=>h("bundleId"),"aria-label":`Bundle identifier: ${e.project.productIdentifierPrefix||"com.example"}. Click to edit.`,children:[d.jsx("span",{className:"text-sm font-medium text-gray-800 dark:text-white/90",children:"Bundle identifier"}),d.jsxs("div",{className:"flex items-center gap-2 text-sm text-gray-600 dark:text-white/65",children:[d.jsx("span",{className:"font-mono",children:e.project.productIdentifierPrefix||"com.example"}),d.jsx("span",{className:"text-gray-400 dark:text-white/40 text-xs","aria-hidden":"true",children:"▸"})]})]})]}),d.jsx("p",{className:"text-xs text-gray-500 dark:text-white/40 mt-3 text-center",id:"settings-description",children:"These defaults are used when creating new projects"})]})})}function O3(){const e=C.useRef(null);C.useEffect(()=>{var n;(n=e.current)==null||n.focus()},[]);const t=()=>{window.open("https://v3alpha.wails.io/quick-start/first-app/","_blank","noopener,noreferrer")};return d.jsxs(B.main,{variants:we,initial:"initial",animate:"animate",exit:"exit",transition:{duration:.3},"aria-labelledby":"complete-title",className:"flex-1 flex flex-col items-center justify-center px-8",children:[d.jsx(B.div,{initial:{scale:0},animate:{scale:1},transition:{type:"spring",stiffness:200,damping:15},className:"w-16 h-16 rounded-full bg-green-500/20 flex items-center justify-center mb-4","aria-hidden":"true",children:d.jsx("svg",{className:"w-8 h-8 text-green-500",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",children:d.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2.5,d:"M5 13l4 4L19 7"})})}),d.jsx("h2",{ref:e,id:"complete-title",className:"text-xl font-semibold text-gray-900 dark:text-white mb-6 focus:outline-none",tabIndex:-1,children:"You're ready to build!"}),d.jsx("button",{onClick:t,className:"px-5 py-2 rounded-lg border border-red-500 text-red-600 dark:text-red-400 text-sm font-medium hover:bg-red-500/10 transition-colors focus:outline-none focus:ring-2 focus:ring-red-500 focus:ring-offset-2 dark:focus:ring-offset-gray-900",children:"Start Building"})]})}function B3(){const[e,t]=C.useState("splash"),[n,r]=C.useState([]),[i,s]=C.useState([]),[o,a]=C.useState(null),[l,u]=C.useState(null),[c,h]=C.useState(!1),[f,y]=C.useState({author:{name:"",company:""},project:{productIdentifierPrefix:"com.example",defaultTemplate:"vanilla",copyrightTemplate:"(c) {year}, {company}",descriptionTemplate:"A {name} application",defaultVersion:"0.1.0",useInterfaces:!0}}),[v,x]=C.useState(!1),[P,m]=C.useState(!1),[p,g]=C.useState(!0),[k,S]=C.useState("vanilla"),[T,w]=C.useState(!0),[j,V]=C.useState(!1),[D,W]=C.useState(null),[Ce,ze]=C.useState(()=>{if(typeof window<"u"){const b=localStorage.getItem("wails-setup-theme");if(b==="light"||b==="dark")return b;if(window.matchMedia("(prefers-color-scheme: light)").matches)return"light"}return"dark"}),U=b=>{r(I=>[...I,e]),t(b)},O=()=>{if(n.length===0)return;const b=[...n];let I=b.pop();for(;I==="checking"&&b.length>0;)I=b.pop();r(b),t(I)},fe=n.length>0&&e!=="splash"&&e!=="checking",X=()=>{ze(b=>{const I=b==="dark"?"light":"dark";return localStorage.setItem("wails-setup-theme",I),I})};C.useEffect(()=>{Ce==="dark"?document.documentElement.classList.add("dark"):document.documentElement.classList.remove("dark")},[Ce]),C.useEffect(()=>{E()},[]),C.useEffect(()=>{const b=I=>{I.target instanceof HTMLInputElement||I.target instanceof HTMLTextAreaElement||I.key==="Escape"&&fe&&(I.preventDefault(),O())};return window.addEventListener("keydown",b),()=>window.removeEventListener("keydown",b)},[fe,e]);const E=async()=>{const b=await g3();a(b.system)},L=async()=>{U("checking");const b=await qd();s(b),b.filter(qt=>qt.required&&!qt.installed).length===0?t("deps-ready"):t("deps-missing")},R=async()=>{U("cross-platform")},H=async()=>{t("checking");const b=await qd();s(b),b.filter(qt=>qt.required&&!qt.installed).length===0?t("deps-ready"):t("deps-missing")},ie=async()=>{U("cross-platform")},wn=async()=>{U("sdk-license")},pt=async()=>{const b=await Jd();u(b),U("docker-setup")},lr=async()=>{var I;const b=await Ii();y(b),w(((I=b.project)==null?void 0:I.useInterfaces)??!0),U("projects")},mt=async()=>{var I;const b=await Ii();y(b),w(((I=b.project)==null?void 0:I.useInterfaces)??!0),U("projects")},kn=async()=>{const b=await Jd();u(b)},Xp=async()=>{h(!0),await y3();const b=_o(I=>{u(I),I.pullStatus!=="pulling"&&(h(!1),b())})},Zp=async()=>{var I;(c||l&&l.pullStatus==="pulling")&&m(!0);const b=await Ii();y(b),w(((I=b.project)==null?void 0:I.useInterfaces)??!0),U("projects")},qp=async()=>{var I;const b=await Ii();y(b),w(((I=b.project)==null?void 0:I.useInterfaces)??!0),U("projects")},Jp=async b=>{h(!0);const I=new FormData;I.append("sdk",b),await fetch("/api/docker/build-with-sdk",{method:"POST",body:I});const qt=_o(Mu=>{u(Mu),Mu.pullStatus!=="pulling"&&(h(!1),qt())})},em=()=>{U("signing")},tm=()=>{U("signing")},nm=()=>{U("language-select")},rm=()=>{U("language-select")},im=()=>{U(p?"binding-style":"template-select")},sm=()=>{U("template-select")},om=async()=>{const b=p&&k!=="vanilla"?`${k}-ts`:p&&k==="vanilla"?"vanilla-ts":k,I={...f,project:{...f.project,defaultTemplate:b,useInterfaces:p?T:!0}};x(!0),await ef(I),x(!1),U("complete")},am=async()=>{const b={...f,project:{...f.project,useInterfaces:p?T:!0}};x(!0),await ef(b),x(!1),U("complete")};return C.useEffect(()=>{if(P&&(c||l&&l.pullStatus==="pulling"))return _o(I=>{u(I),I.pullStatus!=="pulling"&&h(!1)})},[P,c,l==null?void 0:l.pullStatus]),C.useEffect(()=>{if(D==="pulling"&&(l==null?void 0:l.pullStatus)==="complete"&&e!=="docker-setup"){V(!0);const b=setTimeout(()=>V(!1),3e3);return()=>clearTimeout(b)}W((l==null?void 0:l.pullStatus)||null)},[l==null?void 0:l.pullStatus,e]),d.jsx(Yp.Provider,{value:{theme:Ce,toggleTheme:X},children:d.jsxs("div",{className:"min-h-screen bg-gray-50 dark:bg-[#0f0f0f] flex items-center justify-center p-4 transition-colors relative overflow-hidden",children:[d.jsx("div",{className:"absolute inset-0 overflow-hidden pointer-events-none",children:d.jsxs("div",{className:"scrolling-bg w-full h-[200%] opacity-[0.08] dark:opacity-[0.06]",children:[d.jsx("img",{src:"/showcase/montage.png",alt:"",className:"w-full h-1/2 object-cover object-center"}),d.jsx("img",{src:"/showcase/montage.png",alt:"",className:"w-full h-1/2 object-cover object-center"})]})}),d.jsxs("div",{className:"w-[75vw] max-w-[1200px] h-[75vh] max-h-[800px] glass-card rounded-2xl flex overflow-hidden relative z-10",children:[d.jsx(T3,{currentStep:e,dockerStatus:l,buildingDocker:P&&(c||(l==null?void 0:l.pullStatus)==="pulling")}),d.jsxs("div",{className:"flex-1 flex flex-col min-w-0 bg-white/50 dark:bg-white/[0.03] relative",children:[d.jsx(Ha,{children:j&&d.jsxs(B.div,{initial:{opacity:0,y:-20,scale:.95},animate:{opacity:1,y:0,scale:1},exit:{opacity:0,y:-10,scale:.95},transition:{duration:.15,ease:"easeOut"},className:"absolute top-4 right-4 z-50 flex items-center gap-2 px-3 py-2 bg-green-500 text-white rounded-lg shadow-lg",children:[d.jsx("svg",{className:"w-4 h-4",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",strokeWidth:2.5,children:d.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M5 13l4 4L19 7"})}),d.jsx("span",{className:"text-sm font-medium",children:"Docker image ready"})]})}),d.jsx("div",{className:"flex-1 flex flex-col min-h-0",children:d.jsxs(Ha,{mode:"wait",children:[e==="splash"&&d.jsx(P3,{onNext:L},"splash"),e==="checking"&&d.jsx(N3,{},"checking"),e==="deps-ready"&&d.jsx(E3,{onNext:R,onBack:O,canGoBack:fe},"deps-ready"),e==="deps-missing"&&d.jsx(M3,{dependencies:i,onRetry:H,onContinue:ie,onBack:O,canGoBack:fe},"deps-missing"),e==="cross-platform"&&d.jsx(D3,{dockerDep:i.find(b=>b.name==="docker"),onYes:wn,onSkip:mt,onBack:O,canGoBack:fe},"cross-platform"),e==="sdk-license"&&d.jsx(L3,{onAgree:pt,onDecline:lr,onBack:O,canGoBack:fe},"sdk-license"),e==="docker-setup"&&d.jsx(A3,{dockerStatus:l,buildingImage:c,onBuildImage:Xp,onCheckAgain:kn,onContinueBackground:Zp,onUseLocalSDK:Jp,onSkip:qp,onBack:O,canGoBack:fe},"docker-setup"),e==="projects"&&d.jsx(F3,{defaults:f,onDefaultsChange:y,onNext:em,onSkip:tm,saving:v,onBack:O,canGoBack:fe},"projects"),e==="signing"&&d.jsx(S3,{onNext:nm,onSkip:rm,onBack:O,canGoBack:fe},"signing"),e==="language-select"&&d.jsx(V3,{preferTypeScript:p,onSelect:g,onNext:im,onBack:O,canGoBack:fe},"language-select"),e==="binding-style"&&d.jsx(I3,{useInterfaces:T,onSelect:w,onNext:sm,onBack:O,canGoBack:fe},"binding-style"),e==="template-select"&&d.jsx(_3,{selectedFramework:k,preferTypeScript:p,onSelect:S,onNext:om,onSkip:am,onBack:O,canGoBack:fe},"template-select"),e==="complete"&&d.jsx(O3,{},"complete")]})})]})]})]})})}Oo.createRoot(document.getElementById("root")).render(d.jsx(jm.StrictMode,{children:d.jsx(B3,{})})); diff --git a/v3/internal/setupwizard/frontend/dist/assets/index-Dq6tbWrr.css b/v3/internal/setupwizard/frontend/dist/assets/index-Dq6tbWrr.css new file mode 100644 index 000000000..d88dd9cae --- /dev/null +++ b/v3/internal/setupwizard/frontend/dist/assets/index-Dq6tbWrr.css @@ -0,0 +1 @@ +*,:before,:after{--tw-border-spacing-x: 0;--tw-border-spacing-y: 0;--tw-translate-x: 0;--tw-translate-y: 0;--tw-rotate: 0;--tw-skew-x: 0;--tw-skew-y: 0;--tw-scale-x: 1;--tw-scale-y: 1;--tw-pan-x: ;--tw-pan-y: ;--tw-pinch-zoom: ;--tw-scroll-snap-strictness: proximity;--tw-gradient-from-position: ;--tw-gradient-via-position: ;--tw-gradient-to-position: ;--tw-ordinal: ;--tw-slashed-zero: ;--tw-numeric-figure: ;--tw-numeric-spacing: ;--tw-numeric-fraction: ;--tw-ring-inset: ;--tw-ring-offset-width: 0px;--tw-ring-offset-color: #fff;--tw-ring-color: rgb(59 130 246 / .5);--tw-ring-offset-shadow: 0 0 #0000;--tw-ring-shadow: 0 0 #0000;--tw-shadow: 0 0 #0000;--tw-shadow-colored: 0 0 #0000;--tw-blur: ;--tw-brightness: ;--tw-contrast: ;--tw-grayscale: ;--tw-hue-rotate: ;--tw-invert: ;--tw-saturate: ;--tw-sepia: ;--tw-drop-shadow: ;--tw-backdrop-blur: ;--tw-backdrop-brightness: ;--tw-backdrop-contrast: ;--tw-backdrop-grayscale: ;--tw-backdrop-hue-rotate: ;--tw-backdrop-invert: ;--tw-backdrop-opacity: ;--tw-backdrop-saturate: ;--tw-backdrop-sepia: ;--tw-contain-size: ;--tw-contain-layout: ;--tw-contain-paint: ;--tw-contain-style: }::backdrop{--tw-border-spacing-x: 0;--tw-border-spacing-y: 0;--tw-translate-x: 0;--tw-translate-y: 0;--tw-rotate: 0;--tw-skew-x: 0;--tw-skew-y: 0;--tw-scale-x: 1;--tw-scale-y: 1;--tw-pan-x: ;--tw-pan-y: ;--tw-pinch-zoom: ;--tw-scroll-snap-strictness: proximity;--tw-gradient-from-position: ;--tw-gradient-via-position: ;--tw-gradient-to-position: ;--tw-ordinal: ;--tw-slashed-zero: ;--tw-numeric-figure: ;--tw-numeric-spacing: ;--tw-numeric-fraction: ;--tw-ring-inset: ;--tw-ring-offset-width: 0px;--tw-ring-offset-color: #fff;--tw-ring-color: rgb(59 130 246 / .5);--tw-ring-offset-shadow: 0 0 #0000;--tw-ring-shadow: 0 0 #0000;--tw-shadow: 0 0 #0000;--tw-shadow-colored: 0 0 #0000;--tw-blur: ;--tw-brightness: ;--tw-contrast: ;--tw-grayscale: ;--tw-hue-rotate: ;--tw-invert: ;--tw-saturate: ;--tw-sepia: ;--tw-drop-shadow: ;--tw-backdrop-blur: ;--tw-backdrop-brightness: ;--tw-backdrop-contrast: ;--tw-backdrop-grayscale: ;--tw-backdrop-hue-rotate: ;--tw-backdrop-invert: ;--tw-backdrop-opacity: ;--tw-backdrop-saturate: ;--tw-backdrop-sepia: ;--tw-contain-size: ;--tw-contain-layout: ;--tw-contain-paint: ;--tw-contain-style: }*,:before,:after{box-sizing:border-box;border-width:0;border-style:solid;border-color:#e5e7eb}:before,:after{--tw-content: ""}html,:host{line-height:1.5;-webkit-text-size-adjust:100%;-moz-tab-size:4;-o-tab-size:4;tab-size:4;font-family:Inter,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen,Ubuntu,Cantarell,sans-serif;font-feature-settings:normal;font-variation-settings:normal;-webkit-tap-highlight-color:transparent}body{margin:0;line-height:inherit}hr{height:0;color:inherit;border-top-width:1px}abbr:where([title]){-webkit-text-decoration:underline dotted;text-decoration:underline dotted}h1,h2,h3,h4,h5,h6{font-size:inherit;font-weight:inherit}a{color:inherit;text-decoration:inherit}b,strong{font-weight:bolder}code,kbd,samp,pre{font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace;font-feature-settings:normal;font-variation-settings:normal;font-size:1em}small{font-size:80%}sub,sup{font-size:75%;line-height:0;position:relative;vertical-align:baseline}sub{bottom:-.25em}sup{top:-.5em}table{text-indent:0;border-color:inherit;border-collapse:collapse}button,input,optgroup,select,textarea{font-family:inherit;font-feature-settings:inherit;font-variation-settings:inherit;font-size:100%;font-weight:inherit;line-height:inherit;letter-spacing:inherit;color:inherit;margin:0;padding:0}button,select{text-transform:none}button,input:where([type=button]),input:where([type=reset]),input:where([type=submit]){-webkit-appearance:button;background-color:transparent;background-image:none}:-moz-focusring{outline:auto}:-moz-ui-invalid{box-shadow:none}progress{vertical-align:baseline}::-webkit-inner-spin-button,::-webkit-outer-spin-button{height:auto}[type=search]{-webkit-appearance:textfield;outline-offset:-2px}::-webkit-search-decoration{-webkit-appearance:none}::-webkit-file-upload-button{-webkit-appearance:button;font:inherit}summary{display:list-item}blockquote,dl,dd,h1,h2,h3,h4,h5,h6,hr,figure,p,pre{margin:0}fieldset{margin:0;padding:0}legend{padding:0}ol,ul,menu{list-style:none;margin:0;padding:0}dialog{padding:0}textarea{resize:vertical}input::-moz-placeholder,textarea::-moz-placeholder{opacity:1;color:#9ca3af}input::placeholder,textarea::placeholder{opacity:1;color:#9ca3af}button,[role=button]{cursor:pointer}:disabled{cursor:default}img,svg,video,canvas,audio,iframe,embed,object{display:block;vertical-align:middle}img,video{max-width:100%;height:auto}[hidden]:where(:not([hidden=until-found])){display:none}.sr-only{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border-width:0}.pointer-events-none{pointer-events:none}.static{position:static}.absolute{position:absolute}.relative{position:relative}.inset-0{top:0;right:0;bottom:0;left:0}.left-4{left:1rem}.right-4{right:1rem}.top-4{top:1rem}.z-10{z-index:10}.z-50{z-index:50}.mx-auto{margin-left:auto;margin-right:auto}.mb-1{margin-bottom:.25rem}.mb-1\.5{margin-bottom:.375rem}.mb-10{margin-bottom:2.5rem}.mb-2{margin-bottom:.5rem}.mb-3{margin-bottom:.75rem}.mb-4{margin-bottom:1rem}.mb-5{margin-bottom:1.25rem}.mb-6{margin-bottom:1.5rem}.mb-8{margin-bottom:2rem}.ml-9{margin-left:2.25rem}.mt-0\.5{margin-top:.125rem}.mt-1{margin-top:.25rem}.mt-3{margin-top:.75rem}.mt-4{margin-top:1rem}.mt-6{margin-top:1.5rem}.block{display:block}.flex{display:flex}.inline-flex{display:inline-flex}.grid{display:grid}.hidden{display:none}.aspect-square{aspect-ratio:1 / 1}.h-1{height:.25rem}.h-1\/2{height:50%}.h-10{height:2.5rem}.h-12{height:3rem}.h-14{height:3.5rem}.h-16{height:4rem}.h-2{height:.5rem}.h-20{height:5rem}.h-24{height:6rem}.h-3{height:.75rem}.h-3\.5{height:.875rem}.h-4{height:1rem}.h-48{height:12rem}.h-5{height:1.25rem}.h-6{height:1.5rem}.h-72{height:18rem}.h-8{height:2rem}.h-96{height:24rem}.h-\[200\%\]{height:200%}.h-\[75vh\]{height:75vh}.h-full{height:100%}.max-h-\[800px\]{max-height:800px}.min-h-0{min-height:0px}.min-h-screen{min-height:100vh}.w-10{width:2.5rem}.w-12{width:3rem}.w-14{width:3.5rem}.w-16{width:4rem}.w-2{width:.5rem}.w-20{width:5rem}.w-3{width:.75rem}.w-3\.5{width:.875rem}.w-4{width:1rem}.w-40{width:10rem}.w-48{width:12rem}.w-5{width:1.25rem}.w-56{width:14rem}.w-6{width:1.5rem}.w-64{width:16rem}.w-8{width:2rem}.w-\[75vw\]{width:75vw}.w-full{width:100%}.min-w-0{min-width:0px}.max-w-2xl{max-width:42rem}.max-w-4xl{max-width:56rem}.max-w-\[1200px\]{max-width:1200px}.max-w-full{max-width:100%}.max-w-lg{max-width:32rem}.max-w-md{max-width:28rem}.max-w-sm{max-width:24rem}.max-w-xl{max-width:36rem}.max-w-xs{max-width:20rem}.flex-1{flex:1 1 0%}.flex-shrink-0,.shrink-0{flex-shrink:0}.cursor-not-allowed{cursor:not-allowed}.cursor-pointer{cursor:pointer}.grid-cols-4{grid-template-columns:repeat(4,minmax(0,1fr))}.flex-col{flex-direction:column}.items-start{align-items:flex-start}.items-center{align-items:center}.justify-start{justify-content:flex-start}.justify-center{justify-content:center}.justify-between{justify-content:space-between}.gap-1{gap:.25rem}.gap-1\.5{gap:.375rem}.gap-2{gap:.5rem}.gap-3{gap:.75rem}.gap-4{gap:1rem}.gap-6{gap:1.5rem}.space-y-0\.5>:not([hidden])~:not([hidden]){--tw-space-y-reverse: 0;margin-top:calc(.125rem * calc(1 - var(--tw-space-y-reverse)));margin-bottom:calc(.125rem * var(--tw-space-y-reverse))}.space-y-1>:not([hidden])~:not([hidden]){--tw-space-y-reverse: 0;margin-top:calc(.25rem * calc(1 - var(--tw-space-y-reverse)));margin-bottom:calc(.25rem * var(--tw-space-y-reverse))}.space-y-4>:not([hidden])~:not([hidden]){--tw-space-y-reverse: 0;margin-top:calc(1rem * calc(1 - var(--tw-space-y-reverse)));margin-bottom:calc(1rem * var(--tw-space-y-reverse))}.overflow-auto{overflow:auto}.overflow-hidden{overflow:hidden}.overflow-x-auto{overflow-x:auto}.overflow-y-auto{overflow-y:auto}.whitespace-pre-wrap{white-space:pre-wrap}.rounded{border-radius:.25rem}.rounded-2xl{border-radius:1rem}.rounded-full{border-radius:9999px}.rounded-lg{border-radius:.5rem}.rounded-xl{border-radius:.75rem}.border{border-width:1px}.border-2{border-width:2px}.border-b{border-bottom-width:1px}.border-r{border-right-width:1px}.border-none{border-style:none}.border-amber-500\/30{border-color:#f59e0b4d}.border-blue-200{--tw-border-opacity: 1;border-color:rgb(191 219 254 / var(--tw-border-opacity, 1))}.border-blue-400{--tw-border-opacity: 1;border-color:rgb(96 165 250 / var(--tw-border-opacity, 1))}.border-blue-500{--tw-border-opacity: 1;border-color:rgb(59 130 246 / var(--tw-border-opacity, 1))}.border-gray-200{--tw-border-opacity: 1;border-color:rgb(229 231 235 / var(--tw-border-opacity, 1))}.border-gray-200\/50{border-color:#e5e7eb80}.border-gray-300{--tw-border-opacity: 1;border-color:rgb(209 213 219 / var(--tw-border-opacity, 1))}.border-purple-400{--tw-border-opacity: 1;border-color:rgb(192 132 252 / var(--tw-border-opacity, 1))}.border-red-500{--tw-border-opacity: 1;border-color:rgb(239 68 68 / var(--tw-border-opacity, 1))}.border-white\/10{border-color:#ffffff1a}.border-yellow-400{--tw-border-opacity: 1;border-color:rgb(250 204 21 / var(--tw-border-opacity, 1))}.border-t-red-500{--tw-border-opacity: 1;border-top-color:rgb(239 68 68 / var(--tw-border-opacity, 1))}.bg-amber-500\/20{background-color:#f59e0b33}.bg-blue-400\/10{background-color:#60a5fa1a}.bg-blue-50{--tw-bg-opacity: 1;background-color:rgb(239 246 255 / var(--tw-bg-opacity, 1))}.bg-blue-500{--tw-bg-opacity: 1;background-color:rgb(59 130 246 / var(--tw-bg-opacity, 1))}.bg-blue-500\/20{background-color:#3b82f633}.bg-blue-600{--tw-bg-opacity: 1;background-color:rgb(37 99 235 / var(--tw-bg-opacity, 1))}.bg-gray-100{--tw-bg-opacity: 1;background-color:rgb(243 244 246 / var(--tw-bg-opacity, 1))}.bg-gray-100\/80{background-color:#f3f4f6cc}.bg-gray-200{--tw-bg-opacity: 1;background-color:rgb(229 231 235 / var(--tw-bg-opacity, 1))}.bg-gray-300{--tw-bg-opacity: 1;background-color:rgb(209 213 219 / var(--tw-bg-opacity, 1))}.bg-gray-50{--tw-bg-opacity: 1;background-color:rgb(249 250 251 / var(--tw-bg-opacity, 1))}.bg-gray-900{--tw-bg-opacity: 1;background-color:rgb(17 24 39 / var(--tw-bg-opacity, 1))}.bg-green-500{--tw-bg-opacity: 1;background-color:rgb(34 197 94 / var(--tw-bg-opacity, 1))}.bg-green-500\/20{background-color:#22c55e33}.bg-purple-400\/10{background-color:#c084fc1a}.bg-red-500{--tw-bg-opacity: 1;background-color:rgb(239 68 68 / var(--tw-bg-opacity, 1))}.bg-red-500\/10{background-color:#ef44441a}.bg-red-500\/20{background-color:#ef444433}.bg-transparent{background-color:transparent}.bg-white{--tw-bg-opacity: 1;background-color:rgb(255 255 255 / var(--tw-bg-opacity, 1))}.bg-white\/5{background-color:#ffffff0d}.bg-white\/50{background-color:#ffffff80}.bg-yellow-400\/10{background-color:#facc151a}.object-contain{-o-object-fit:contain;object-fit:contain}.object-cover{-o-object-fit:cover;object-fit:cover}.object-center{-o-object-position:center;object-position:center}.p-1{padding:.25rem}.p-2{padding:.5rem}.p-3{padding:.75rem}.p-4{padding:1rem}.p-5{padding:1.25rem}.p-6{padding:1.5rem}.px-1{padding-left:.25rem;padding-right:.25rem}.px-10{padding-left:2.5rem;padding-right:2.5rem}.px-2{padding-left:.5rem;padding-right:.5rem}.px-3{padding-left:.75rem;padding-right:.75rem}.px-4{padding-left:1rem;padding-right:1rem}.px-5{padding-left:1.25rem;padding-right:1.25rem}.px-6{padding-left:1.5rem;padding-right:1.5rem}.px-8{padding-left:2rem;padding-right:2rem}.py-0\.5{padding-top:.125rem;padding-bottom:.125rem}.py-1{padding-top:.25rem;padding-bottom:.25rem}.py-1\.5{padding-top:.375rem;padding-bottom:.375rem}.py-2{padding-top:.5rem;padding-bottom:.5rem}.py-2\.5{padding-top:.625rem;padding-bottom:.625rem}.py-3{padding-top:.75rem;padding-bottom:.75rem}.pb-6{padding-bottom:1.5rem}.pt-10{padding-top:2.5rem}.pt-4{padding-top:1rem}.pt-\[15\%\]{padding-top:15%}.text-left{text-align:left}.text-center{text-align:center}.font-mono{font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace}.text-2xl{font-size:1.5rem;line-height:2rem}.text-\[10px\]{font-size:10px}.text-base{font-size:1rem;line-height:1.5rem}.text-lg{font-size:1.125rem;line-height:1.75rem}.text-sm{font-size:.875rem;line-height:1.25rem}.text-xl{font-size:1.25rem;line-height:1.75rem}.text-xs{font-size:.75rem;line-height:1rem}.font-medium{font-weight:500}.font-semibold{font-weight:600}.uppercase{text-transform:uppercase}.leading-relaxed{line-height:1.625}.leading-tight{line-height:1.25}.tracking-tight{letter-spacing:-.025em}.tracking-wide{letter-spacing:.025em}.text-amber-500{--tw-text-opacity: 1;color:rgb(245 158 11 / var(--tw-text-opacity, 1))}.text-amber-600{--tw-text-opacity: 1;color:rgb(217 119 6 / var(--tw-text-opacity, 1))}.text-blue-500{--tw-text-opacity: 1;color:rgb(59 130 246 / var(--tw-text-opacity, 1))}.text-blue-600{--tw-text-opacity: 1;color:rgb(37 99 235 / var(--tw-text-opacity, 1))}.text-gray-100{--tw-text-opacity: 1;color:rgb(243 244 246 / var(--tw-text-opacity, 1))}.text-gray-400{--tw-text-opacity: 1;color:rgb(156 163 175 / var(--tw-text-opacity, 1))}.text-gray-500{--tw-text-opacity: 1;color:rgb(107 114 128 / var(--tw-text-opacity, 1))}.text-gray-600{--tw-text-opacity: 1;color:rgb(75 85 99 / var(--tw-text-opacity, 1))}.text-gray-700{--tw-text-opacity: 1;color:rgb(55 65 81 / var(--tw-text-opacity, 1))}.text-gray-800{--tw-text-opacity: 1;color:rgb(31 41 55 / var(--tw-text-opacity, 1))}.text-gray-900{--tw-text-opacity: 1;color:rgb(17 24 39 / var(--tw-text-opacity, 1))}.text-green-500{--tw-text-opacity: 1;color:rgb(34 197 94 / var(--tw-text-opacity, 1))}.text-green-700{--tw-text-opacity: 1;color:rgb(21 128 61 / var(--tw-text-opacity, 1))}.text-red-500{--tw-text-opacity: 1;color:rgb(239 68 68 / var(--tw-text-opacity, 1))}.text-red-600{--tw-text-opacity: 1;color:rgb(220 38 38 / var(--tw-text-opacity, 1))}.text-white{--tw-text-opacity: 1;color:rgb(255 255 255 / var(--tw-text-opacity, 1))}.text-yellow-500{--tw-text-opacity: 1;color:rgb(234 179 8 / var(--tw-text-opacity, 1))}.placeholder-gray-400::-moz-placeholder{--tw-placeholder-opacity: 1;color:rgb(156 163 175 / var(--tw-placeholder-opacity, 1))}.placeholder-gray-400::placeholder{--tw-placeholder-opacity: 1;color:rgb(156 163 175 / var(--tw-placeholder-opacity, 1))}.opacity-50{opacity:.5}.opacity-\[0\.08\]{opacity:.08}.shadow-lg{--tw-shadow: 0 10px 15px -3px rgb(0 0 0 / .1), 0 4px 6px -4px rgb(0 0 0 / .1);--tw-shadow-colored: 0 10px 15px -3px var(--tw-shadow-color), 0 4px 6px -4px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}.shadow-blue-400\/20{--tw-shadow-color: rgb(96 165 250 / .2);--tw-shadow: var(--tw-shadow-colored)}.shadow-purple-400\/20{--tw-shadow-color: rgb(192 132 252 / .2);--tw-shadow: var(--tw-shadow-colored)}.shadow-red-500\/10{--tw-shadow-color: rgb(239 68 68 / .1);--tw-shadow: var(--tw-shadow-colored)}.shadow-yellow-400\/20{--tw-shadow-color: rgb(250 204 21 / .2);--tw-shadow: var(--tw-shadow-colored)}.drop-shadow{--tw-drop-shadow: drop-shadow(0 1px 2px rgb(0 0 0 / .1)) drop-shadow(0 1px 1px rgb(0 0 0 / .06));filter:var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow)}.filter{filter:var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow)}.transition{transition-property:color,background-color,border-color,text-decoration-color,fill,stroke,opacity,box-shadow,transform,filter,backdrop-filter;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.transition-all{transition-property:all;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.transition-colors{transition-property:color,background-color,border-color,text-decoration-color,fill,stroke;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.transition-opacity{transition-property:opacity;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.duration-300{transition-duration:.3s}:root{--wails-red: #ef4444;--wails-red-dark: #dc2626;--wails-red-light: #f87171;--wails-blue: #1d63ed;--wails-blue-dark: #1554d0;--wails-blue-light: #3b7dff;--bg-primary: #05070b;--bg-secondary: #0a0e16;--bg-tertiary: #0f1420;--glass-bg: rgba(255, 255, 255, .06);--glass-border: rgba(255, 255, 255, .08)}*{box-sizing:border-box}html,body,#root{margin:0;padding:0;min-height:100vh;background:var(--bg-primary);color:#fff;font-family:Inter,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen,Ubuntu,Cantarell,sans-serif;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}.gradient-text{background:linear-gradient(135deg,#fff,#ef4444);-webkit-background-clip:text;-webkit-text-fill-color:transparent;background-clip:text}.glass-card{background:linear-gradient(180deg,#ffffff14,#ffffff0a);backdrop-filter:blur(20px);-webkit-backdrop-filter:blur(20px);border:1px solid var(--glass-border);box-shadow:0 30px 80px #00000080}.glass-sidebar{background:#05070c8c;backdrop-filter:blur(30px);-webkit-backdrop-filter:blur(30px);border-right:1px solid var(--glass-border)}.settings-row{display:flex;align-items:center;justify-content:space-between;padding:0 20px;height:52px;cursor:pointer;-webkit-user-select:none;-moz-user-select:none;user-select:none;transition:background-color .12s ease}.settings-row:hover{background:#0000000a}.dark .settings-row:hover{background:#ffffff0f}.settings-row+.settings-row{border-top:1px solid rgba(0,0,0,.1)}.dark .settings-row+.settings-row{border-top:1px solid var(--glass-border)}.settings-group{border-radius:12px;background:#0000000a;box-shadow:0 4px 12px #00000014,0 0 0 1px #00000014 inset;overflow:hidden}.dark .settings-group{background:#ffffff1a;box-shadow:0 12px 30px #00000059,0 0 0 1px var(--glass-border) inset;backdrop-filter:blur(10px);-webkit-backdrop-filter:blur(10px)}.grid-bg{background-image:linear-gradient(rgba(239,68,68,.03) 1px,transparent 1px),linear-gradient(90deg,rgba(239,68,68,.03) 1px,transparent 1px);background-size:40px 40px}.radial-glow{background:radial-gradient(ellipse at center,rgba(239,68,68,.1) 0%,transparent 70%)}::-webkit-scrollbar{width:8px}::-webkit-scrollbar-track{background:var(--bg-primary)}::-webkit-scrollbar-thumb{background:var(--bg-tertiary);border-radius:4px}::-webkit-scrollbar-thumb:hover{background:#4b5563}.scrollbar-thin::-webkit-scrollbar{width:4px}.scrollbar-thin::-webkit-scrollbar-track{background:transparent}.scrollbar-thin::-webkit-scrollbar-thumb{background:#9ca3af4d;border-radius:2px}.scrollbar-thin::-webkit-scrollbar-thumb:hover{background:#9ca3af80}.btn-primary{border-radius:.75rem;background-image:linear-gradient(to right,var(--tw-gradient-stops));--tw-gradient-from: #ef4444 var(--tw-gradient-from-position);--tw-gradient-to: rgb(239 68 68 / 0) var(--tw-gradient-to-position);--tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to);--tw-gradient-to: #dc2626 var(--tw-gradient-to-position);padding:.75rem 2rem;font-weight:600;--tw-text-opacity: 1;color:rgb(255 255 255 / var(--tw-text-opacity, 1));--tw-shadow: 0 10px 15px -3px rgb(0 0 0 / .1), 0 4px 6px -4px rgb(0 0 0 / .1);--tw-shadow-colored: 0 10px 15px -3px var(--tw-shadow-color), 0 4px 6px -4px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow);transition-property:all;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.3s}.btn-primary:hover{--tw-scale-x: 1.05;--tw-scale-y: 1.05;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y));--tw-shadow: 0 20px 25px -5px rgb(0 0 0 / .1), 0 8px 10px -6px rgb(0 0 0 / .1);--tw-shadow-colored: 0 20px 25px -5px var(--tw-shadow-color), 0 8px 10px -6px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow);--tw-shadow-color: rgb(239 68 68 / .3);--tw-shadow: var(--tw-shadow-colored)}.btn-primary:active{--tw-scale-x: .95;--tw-scale-y: .95;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.btn-secondary{border-radius:.75rem;border-width:1px;--tw-border-opacity: 1;border-color:rgb(75 85 99 / var(--tw-border-opacity, 1));background-color:transparent;padding:.75rem 2rem;font-weight:500;--tw-text-opacity: 1;color:rgb(209 213 219 / var(--tw-text-opacity, 1));transition-property:all;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.3s}.btn-secondary:hover{--tw-border-opacity: 1;border-color:rgb(107 114 128 / var(--tw-border-opacity, 1));background-color:#1f293780;--tw-text-opacity: 1;color:rgb(255 255 255 / var(--tw-text-opacity, 1))}@keyframes spin{to{transform:rotate(360deg)}}.spinner{animation:spin 1s linear infinite}.check-path{stroke-dasharray:100;stroke-dashoffset:100;animation:drawCheck .5s ease-out forwards}@keyframes scrollBackground{0%{transform:translateY(0)}to{transform:translateY(-50%)}}.scrolling-bg{animation:scrollBackground 60s linear infinite}@media (prefers-reduced-motion: reduce){*:not(.animate-spin):not(.spinner),*:not(.animate-spin):not(.spinner):before,*:not(.animate-spin):not(.spinner):after{animation-duration:.01ms!important;animation-iteration-count:1!important;transition-duration:.01ms!important}}.sr-only{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border:0}.settings-row:focus-visible{outline:2px solid #ef4444;outline-offset:-2px}.last\:border-0:last-child{border-width:0px}.hover\:bg-blue-500:hover{--tw-bg-opacity: 1;background-color:rgb(59 130 246 / var(--tw-bg-opacity, 1))}.hover\:bg-blue-500\/10:hover{background-color:#3b82f61a}.hover\:bg-blue-600:hover{--tw-bg-opacity: 1;background-color:rgb(37 99 235 / var(--tw-bg-opacity, 1))}.hover\:bg-gray-100:hover{--tw-bg-opacity: 1;background-color:rgb(243 244 246 / var(--tw-bg-opacity, 1))}.hover\:bg-gray-200:hover{--tw-bg-opacity: 1;background-color:rgb(229 231 235 / var(--tw-bg-opacity, 1))}.hover\:bg-gray-50:hover{--tw-bg-opacity: 1;background-color:rgb(249 250 251 / var(--tw-bg-opacity, 1))}.hover\:bg-red-500\/10:hover{background-color:#ef44441a}.hover\:bg-red-600:hover{--tw-bg-opacity: 1;background-color:rgb(220 38 38 / var(--tw-bg-opacity, 1))}.hover\:bg-white\/10:hover{background-color:#ffffff1a}.hover\:text-blue-600:hover{--tw-text-opacity: 1;color:rgb(37 99 235 / var(--tw-text-opacity, 1))}.hover\:text-gray-700:hover{--tw-text-opacity: 1;color:rgb(55 65 81 / var(--tw-text-opacity, 1))}.hover\:opacity-70:hover{opacity:.7}.focus\:outline-none:focus{outline:2px solid transparent;outline-offset:2px}.focus\:ring-2:focus{--tw-ring-offset-shadow: var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow: var(--tw-ring-inset) 0 0 0 calc(2px + var(--tw-ring-offset-width)) var(--tw-ring-color);box-shadow:var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow, 0 0 #0000)}.focus\:ring-inset:focus{--tw-ring-inset: inset}.focus\:ring-blue-400:focus{--tw-ring-opacity: 1;--tw-ring-color: rgb(96 165 250 / var(--tw-ring-opacity, 1))}.focus\:ring-blue-500:focus{--tw-ring-opacity: 1;--tw-ring-color: rgb(59 130 246 / var(--tw-ring-opacity, 1))}.focus\:ring-gray-500:focus{--tw-ring-opacity: 1;--tw-ring-color: rgb(107 114 128 / var(--tw-ring-opacity, 1))}.focus\:ring-purple-400:focus{--tw-ring-opacity: 1;--tw-ring-color: rgb(192 132 252 / var(--tw-ring-opacity, 1))}.focus\:ring-red-500:focus{--tw-ring-opacity: 1;--tw-ring-color: rgb(239 68 68 / var(--tw-ring-opacity, 1))}.focus\:ring-yellow-400:focus{--tw-ring-opacity: 1;--tw-ring-color: rgb(250 204 21 / var(--tw-ring-opacity, 1))}.focus\:ring-offset-2:focus{--tw-ring-offset-width: 2px}.disabled\:opacity-50:disabled{opacity:.5}.dark\:border-blue-800:is(.dark *){--tw-border-opacity: 1;border-color:rgb(30 64 175 / var(--tw-border-opacity, 1))}.dark\:border-gray-600:is(.dark *){--tw-border-opacity: 1;border-color:rgb(75 85 99 / var(--tw-border-opacity, 1))}.dark\:border-gray-700:is(.dark *){--tw-border-opacity: 1;border-color:rgb(55 65 81 / var(--tw-border-opacity, 1))}.dark\:border-gray-800\/50:is(.dark *){border-color:#1f293780}.dark\:border-transparent:is(.dark *){border-color:transparent}.dark\:border-white\/10:is(.dark *){border-color:#ffffff1a}.dark\:bg-\[\#0f0f0f\]:is(.dark *){--tw-bg-opacity: 1;background-color:rgb(15 15 15 / var(--tw-bg-opacity, 1))}.dark\:bg-black\/30:is(.dark *){background-color:#0000004d}.dark\:bg-blue-900\/20:is(.dark *){background-color:#1e3a8a33}.dark\:bg-gray-700:is(.dark *){--tw-bg-opacity: 1;background-color:rgb(55 65 81 / var(--tw-bg-opacity, 1))}.dark\:bg-gray-800:is(.dark *){--tw-bg-opacity: 1;background-color:rgb(31 41 55 / var(--tw-bg-opacity, 1))}.dark\:bg-gray-800\/50:is(.dark *){background-color:#1f293780}.dark\:bg-gray-800\/80:is(.dark *){background-color:#1f2937cc}.dark\:bg-gray-900:is(.dark *){--tw-bg-opacity: 1;background-color:rgb(17 24 39 / var(--tw-bg-opacity, 1))}.dark\:bg-gray-900\/50:is(.dark *){background-color:#11182780}.dark\:bg-transparent:is(.dark *){background-color:transparent}.dark\:bg-white\/5:is(.dark *){background-color:#ffffff0d}.dark\:bg-white\/\[0\.03\]:is(.dark *){background-color:#ffffff08}.dark\:text-amber-400:is(.dark *){--tw-text-opacity: 1;color:rgb(251 191 36 / var(--tw-text-opacity, 1))}.dark\:text-blue-400:is(.dark *){--tw-text-opacity: 1;color:rgb(96 165 250 / var(--tw-text-opacity, 1))}.dark\:text-gray-300:is(.dark *){--tw-text-opacity: 1;color:rgb(209 213 219 / var(--tw-text-opacity, 1))}.dark\:text-gray-400:is(.dark *){--tw-text-opacity: 1;color:rgb(156 163 175 / var(--tw-text-opacity, 1))}.dark\:text-gray-500:is(.dark *){--tw-text-opacity: 1;color:rgb(107 114 128 / var(--tw-text-opacity, 1))}.dark\:text-gray-600:is(.dark *){--tw-text-opacity: 1;color:rgb(75 85 99 / var(--tw-text-opacity, 1))}.dark\:text-red-400:is(.dark *){--tw-text-opacity: 1;color:rgb(248 113 113 / var(--tw-text-opacity, 1))}.dark\:text-white:is(.dark *){--tw-text-opacity: 1;color:rgb(255 255 255 / var(--tw-text-opacity, 1))}.dark\:text-white\/40:is(.dark *){color:#fff6}.dark\:text-white\/50:is(.dark *){color:#ffffff80}.dark\:text-white\/65:is(.dark *){color:#ffffffa6}.dark\:text-white\/70:is(.dark *){color:#ffffffb3}.dark\:text-white\/90:is(.dark *){color:#ffffffe6}.dark\:placeholder-gray-500:is(.dark *)::-moz-placeholder{--tw-placeholder-opacity: 1;color:rgb(107 114 128 / var(--tw-placeholder-opacity, 1))}.dark\:placeholder-gray-500:is(.dark *)::placeholder{--tw-placeholder-opacity: 1;color:rgb(107 114 128 / var(--tw-placeholder-opacity, 1))}.dark\:opacity-\[0\.06\]:is(.dark *){opacity:.06}.dark\:hover\:bg-gray-700:hover:is(.dark *){--tw-bg-opacity: 1;background-color:rgb(55 65 81 / var(--tw-bg-opacity, 1))}.dark\:hover\:bg-gray-800:hover:is(.dark *){--tw-bg-opacity: 1;background-color:rgb(31 41 55 / var(--tw-bg-opacity, 1))}.dark\:hover\:bg-gray-800\/50:hover:is(.dark *){background-color:#1f293780}.dark\:hover\:bg-white\/10:hover:is(.dark *){background-color:#ffffff1a}.dark\:hover\:text-blue-300:hover:is(.dark *){--tw-text-opacity: 1;color:rgb(147 197 253 / var(--tw-text-opacity, 1))}.dark\:hover\:text-gray-200:hover:is(.dark *){--tw-text-opacity: 1;color:rgb(229 231 235 / var(--tw-text-opacity, 1))}.dark\:hover\:text-gray-300:hover:is(.dark *){--tw-text-opacity: 1;color:rgb(209 213 219 / var(--tw-text-opacity, 1))}.dark\:focus\:ring-offset-gray-900:focus:is(.dark *){--tw-ring-offset-color: #111827} diff --git a/v3/internal/setupwizard/frontend/dist/index.html b/v3/internal/setupwizard/frontend/dist/index.html index 2efb0608b..02337ddfa 100644 --- a/v3/internal/setupwizard/frontend/dist/index.html +++ b/v3/internal/setupwizard/frontend/dist/index.html @@ -7,8 +7,8 @@ - - + +
diff --git a/v3/internal/setupwizard/frontend/src/components/SigningStep.tsx b/v3/internal/setupwizard/frontend/src/components/SigningStep.tsx index 9dc78fb48..ce9dcf2a6 100644 --- a/v3/internal/setupwizard/frontend/src/components/SigningStep.tsx +++ b/v3/internal/setupwizard/frontend/src/components/SigningStep.tsx @@ -1,7 +1,7 @@ import { useState, useEffect, useRef } from 'react'; -import { motion } from 'framer-motion'; -import type { SigningStatus } from '../types'; -import { getSigningStatus } from '../api'; +import { motion, AnimatePresence } from 'framer-motion'; +import type { SigningStatus, SigningDefaults } from '../types'; +import { getSigningStatus, getSigning, saveSigning } from '../api'; const pageVariants = { initial: { opacity: 0 }, @@ -11,12 +11,6 @@ const pageVariants = { type Platform = 'darwin' | 'windows' | 'linux'; -const platformInfo: Record = { - darwin: { name: 'macOS', icon: '🍎' }, - windows: { name: 'Windows', icon: '🪟' }, - linux: { name: 'Linux', icon: '🐧' } -}; - interface Props { onNext: () => void; onSkip: () => void; @@ -26,26 +20,206 @@ interface Props { export default function SigningStep({ onNext, onSkip, onBack, canGoBack }: Props) { const [status, setStatus] = useState(null); + const [config, setConfig] = useState(null); const [loading, setLoading] = useState(true); const [selectedPlatform, setSelectedPlatform] = useState('darwin'); + const [configuring, setConfiguring] = useState(false); + const [saving, setSaving] = useState(false); const headingRef = useRef(null); useEffect(() => { headingRef.current?.focus(); - loadStatus(); + loadData(); }, []); - const loadStatus = async () => { + const loadData = async () => { try { - const s = await getSigningStatus(); + const [s, c] = await Promise.all([getSigningStatus(), getSigning()]); setStatus(s); + setConfig(c || { darwin: {}, windows: {}, linux: {} }); } catch (e) { - console.error('Failed to load signing status:', e); + console.error('Failed to load signing data:', e); } finally { setLoading(false); } }; + const handleSave = async () => { + if (!config) return; + setSaving(true); + try { + await saveSigning(config); + await loadData(); + setConfiguring(false); + } catch (e) { + console.error('Failed to save signing config:', e); + } finally { + setSaving(false); + } + }; + + const renderConfigForm = () => { + if (!config) return null; + + if (selectedPlatform === 'darwin') { + return ( +
+
+ + setConfig({ + ...config, + darwin: { ...config.darwin, identity: e.target.value } + })} + placeholder="Developer ID Application: Your Name (TEAMID)" + className="w-full px-3 py-2 rounded-lg border border-gray-300 dark:border-gray-600 bg-white dark:bg-gray-800 text-gray-900 dark:text-white text-sm focus:outline-none focus:ring-2 focus:ring-red-500" + /> +

+ Find with: security find-identity -v -p codesigning +

+
+ +
+ + setConfig({ + ...config, + darwin: { ...config.darwin, teamID: e.target.value } + })} + placeholder="ABCD1234EF" + className="w-full px-3 py-2 rounded-lg border border-gray-300 dark:border-gray-600 bg-white dark:bg-gray-800 text-gray-900 dark:text-white text-sm focus:outline-none focus:ring-2 focus:ring-red-500" + /> +
+ +
+ + setConfig({ + ...config, + darwin: { ...config.darwin, keychainProfile: e.target.value } + })} + placeholder="notarytool-profile" + className="w-full px-3 py-2 rounded-lg border border-gray-300 dark:border-gray-600 bg-white dark:bg-gray-800 text-gray-900 dark:text-white text-sm focus:outline-none focus:ring-2 focus:ring-red-500" + /> +

+ Create with: xcrun notarytool store-credentials +

+
+
+ ); + } + + if (selectedPlatform === 'windows') { + return ( +
+
+ + setConfig({ + ...config, + windows: { ...config.windows, certificatePath: e.target.value } + })} + placeholder="/path/to/certificate.pfx" + className="w-full px-3 py-2 rounded-lg border border-gray-300 dark:border-gray-600 bg-white dark:bg-gray-800 text-gray-900 dark:text-white text-sm focus:outline-none focus:ring-2 focus:ring-red-500" + /> +
+ +
— or —
+ +
+ + setConfig({ + ...config, + windows: { ...config.windows, thumbprint: e.target.value } + })} + placeholder="ABC123DEF456..." + className="w-full px-3 py-2 rounded-lg border border-gray-300 dark:border-gray-600 bg-white dark:bg-gray-800 text-gray-900 dark:text-white text-sm focus:outline-none focus:ring-2 focus:ring-red-500" + /> +
+ +
+ + setConfig({ + ...config, + windows: { ...config.windows, timestampServer: e.target.value } + })} + className="w-full px-3 py-2 rounded-lg border border-gray-300 dark:border-gray-600 bg-white dark:bg-gray-800 text-gray-900 dark:text-white text-sm focus:outline-none focus:ring-2 focus:ring-red-500" + /> +
+
+ ); + } + + if (selectedPlatform === 'linux') { + return ( +
+
+ + setConfig({ + ...config, + linux: { ...config.linux, gpgKeyID: e.target.value } + })} + placeholder="ABCD1234EFGH5678" + className="w-full px-3 py-2 rounded-lg border border-gray-300 dark:border-gray-600 bg-white dark:bg-gray-800 text-gray-900 dark:text-white text-sm focus:outline-none focus:ring-2 focus:ring-red-500" + /> +

+ Find with: gpg --list-secret-keys --keyid-format long +

+
+ +
+ + setConfig({ + ...config, + linux: { ...config.linux, gpgKeyPath: e.target.value } + })} + placeholder="~/.gnupg/private-key.asc" + className="w-full px-3 py-2 rounded-lg border border-gray-300 dark:border-gray-600 bg-white dark:bg-gray-800 text-gray-900 dark:text-white text-sm focus:outline-none focus:ring-2 focus:ring-red-500" + /> +
+
+ ); + } + + return null; + }; + const renderPlatformStatus = () => { if (!status) return null; @@ -53,53 +227,17 @@ export default function SigningStep({ onNext, onSkip, onBack, canGoBack }: Props const darwin = status.darwin; return (
-
-
- {darwin.hasIdentity ? ( - - - - ) : ( - - - - )} -
-
-
Code Signing Identity
-
- {darwin.hasIdentity ? darwin.identity : 'Not configured'} -
-
- {darwin.configSource && ( - - {darwin.configSource} - - )} -
- -
-
- {darwin.hasNotarization ? ( - - - - ) : ( - - - - )} -
-
-
Notarization
-
- {darwin.hasNotarization - ? `Team ID: ${darwin.teamID || 'Configured'}` - : 'Not configured'} -
-
-
- + + {darwin.identities && darwin.identities.length > 1 && (
{darwin.identities.length} signing identities found in keychain @@ -113,53 +251,17 @@ export default function SigningStep({ onNext, onSkip, onBack, canGoBack }: Props const windows = status.windows; return (
-
-
- {windows.hasCertificate ? ( - - - - ) : ( - - - - )} -
-
-
Code Signing Certificate
-
- {windows.hasCertificate - ? `Type: ${windows.certificateType}` - : 'Not configured'} -
-
- {windows.configSource && ( - - {windows.configSource} - - )} -
- -
-
- {windows.hasSignTool ? ( - - - - ) : ( - - - - )} -
-
-
SignTool
-
- {windows.hasSignTool ? 'Available' : 'Not found (Windows SDK required)'} -
-
-
- + + {windows.timestampServer && (
Timestamp server: {windows.timestampServer} @@ -173,32 +275,12 @@ export default function SigningStep({ onNext, onSkip, onBack, canGoBack }: Props const linux = status.linux; return (
-
-
- {linux.hasGpgKey ? ( - - - - ) : ( - - - - )} -
-
-
GPG Signing Key
-
- {linux.hasGpgKey - ? `Key ID: ${linux.gpgKeyID}` - : 'Not configured'} -
-
- {linux.configSource && ( - - {linux.configSource} - - )} -
+
); } @@ -255,40 +337,74 @@ export default function SigningStep({ onNext, onSkip, onBack, canGoBack }: Props ) : (
- {(['darwin', 'windows', 'linux'] as Platform[]).map((platform) => { - const info = platformInfo[platform]; - const isActive = selectedPlatform === platform; - const hasConfig = status && ( - (platform === 'darwin' && status.darwin.hasIdentity) || - (platform === 'windows' && status.windows.hasCertificate) || - (platform === 'linux' && status.linux.hasGpgKey) - ); - - return ( - - ); - })} + { setSelectedPlatform('darwin'); setConfiguring(false); }} + /> + { setSelectedPlatform('windows'); setConfiguring(false); }} + /> + { setSelectedPlatform('linux'); setConfiguring(false); }} + />
-
- {renderPlatformStatus()} -
+ + {configuring ? ( + + {renderConfigForm()} +
+ + +
+
+ ) : ( + + {renderPlatformStatus()} + + + )} +

Code signing ensures your app is trusted and hasn't been tampered with @@ -324,3 +440,78 @@ export default function SigningStep({ onNext, onSkip, onBack, canGoBack }: Props ); } + +function StatusRow({ label, configured, value, source }: { + label: string; + configured: boolean; + value: string; + source?: string; +}) { + return ( +

+
+ {configured ? ( + + + + ) : ( + + + + )} +
+
+
{label}
+
{value}
+
+ {source && ( + + {source} + + )} +
+ ); +} + +function PlatformTab({ platform, label, isActive, hasConfig, onClick }: { + platform: 'darwin' | 'windows' | 'linux'; + label: string; + isActive: boolean; + hasConfig?: boolean; + onClick: () => void; +}) { + const iconClass = `w-5 h-5 ${isActive ? 'text-gray-900 dark:text-white' : 'text-gray-400 dark:text-gray-500'}`; + + return ( + + ); +}