@ws-ui/roles-editor 1.11.2 → 1.11.3-rc1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/Sidebar/Roles/RolePrivileges.d.ts +2 -2
- package/dist/Standalone/index.d.ts +2 -2
- package/dist/Standalone/style.css +1 -1
- package/dist/Tabs/Privileges/Graph/graph.d.ts +1 -1
- package/dist/Tabs/Privileges/Includes.d.ts +1 -1
- package/dist/Tabs/Privileges/Sidebar.d.ts +1 -1
- package/dist/Tabs/Privileges/Table.d.ts +1 -1
- package/dist/Tabs/Privileges/helpers.d.ts +2 -2
- package/dist/Tabs/Roles/Card.d.ts +1 -1
- package/dist/Tabs/Roles/Row.d.ts +1 -1
- package/dist/Tabs/Roles/RowContainer.d.ts +1 -1
- package/dist/Tabs/Roles/utils.d.ts +1 -1
- package/dist/adapter/index.d.ts +8 -0
- package/dist/adapter/provider.d.ts +19 -0
- package/dist/adapter/reducer/adapter.d.ts +103 -0
- package/dist/adapter/reducer/use-modals.d.ts +18 -0
- package/dist/adapter/redux/adapter.d.ts +8 -0
- package/dist/adapter/types.d.ts +36 -0
- package/dist/common.cjs.js.map +1 -1
- package/dist/common.es.js.map +1 -1
- package/dist/index.cjs.js +85 -31
- package/dist/index.cjs.js.map +1 -1
- package/dist/index.d.ts +1 -0
- package/dist/index.es.js +38227 -25300
- package/dist/index.es.js.map +1 -1
- package/dist/roles-editor.css +1 -1
- package/package.json +4 -4
package/dist/index.cjs.js
CHANGED
|
@@ -1,72 +1,126 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const C=require("react/jsx-runtime"),Z=require("@ws-ui/store"),A=require("react"),Te=require("@ws-ui/shared"),wr=require("@headlessui/react"),aD=require("react-dom"),ye=require("@ws-ui/icons"),sD=require("./common.cjs.js");function uD(e){const t=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const r in e)if(r!=="default"){const n=Object.getOwnPropertyDescriptor(e,r);Object.defineProperty(t,r,n.get?n:{enumerable:!0,get:()=>e[r]})}}return t.default=e,Object.freeze(t)}const ve=uD(A),Yb=uD(aD);var ht=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function Un(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var Wf={exports:{}};/*!
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const O=require("react/jsx-runtime"),R=require("react"),he=require("@ws-ui/shared"),mo=require("react-dom"),un=require("@headlessui/react"),_e=require("@ws-ui/icons"),Xe=require("@ws-ui/store"),kL=require("./common.cjs.js");function DL(e){const t=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const r in e)if(r!=="default"){const n=Object.getOwnPropertyDescriptor(e,r);Object.defineProperty(t,r,n.get?n:{enumerable:!0,get:()=>e[r]})}}return t.default=e,Object.freeze(t)}const ue=DL(R),W_=DL(mo);(function(){try{const e=document.createElement("style");e.setAttribute("data-vite-dev-id","ui-components.css"),e.textContent=`/*! tailwindcss v4.1.18 | MIT License | https://tailwindcss.com */@supports (((-webkit-hyphens:none)) and (not (margin-trim:inline))) or ((-moz-orient:inline) and (not (color:rgb(from red r g b)))){*,:before,:after,::backdrop{--tw-translate-x:0;--tw-translate-y:0;--tw-translate-z:0;--tw-scale-x:1;--tw-scale-y:1;--tw-scale-z:1;--tw-rotate-x:initial;--tw-rotate-y:initial;--tw-rotate-z:initial;--tw-skew-x:initial;--tw-skew-y:initial;--tw-space-y-reverse:0;--tw-space-x-reverse:0;--tw-border-style:solid;--tw-gradient-position:initial;--tw-gradient-from:#0000;--tw-gradient-via:#0000;--tw-gradient-to:#0000;--tw-gradient-stops:initial;--tw-gradient-via-stops:initial;--tw-gradient-from-position:0%;--tw-gradient-via-position:50%;--tw-gradient-to-position:100%;--tw-leading:initial;--tw-font-weight:initial;--tw-shadow:0 0 #0000;--tw-shadow-color:initial;--tw-shadow-alpha:100%;--tw-inset-shadow:0 0 #0000;--tw-inset-shadow-color:initial;--tw-inset-shadow-alpha:100%;--tw-ring-color:initial;--tw-ring-shadow:0 0 #0000;--tw-inset-ring-color:initial;--tw-inset-ring-shadow:0 0 #0000;--tw-ring-inset:initial;--tw-ring-offset-width:0px;--tw-ring-offset-color:#fff;--tw-ring-offset-shadow:0 0 #0000;--tw-outline-style:solid;--tw-blur:initial;--tw-brightness:initial;--tw-contrast:initial;--tw-grayscale:initial;--tw-hue-rotate:initial;--tw-invert:initial;--tw-opacity:initial;--tw-saturate:initial;--tw-sepia:initial;--tw-drop-shadow:initial;--tw-drop-shadow-color:initial;--tw-drop-shadow-alpha:100%;--tw-drop-shadow-size:initial;--tw-duration:initial;--tw-ease:initial}}:root:not(#\\#),:host:not(#\\#){--color-green-500:oklch(72.3% .219 149.579);--color-blue-500:oklch(62.3% .214 259.815);--color-pink-500:oklch(65.6% .241 354.308);--color-gray-50:oklch(98.5% .002 247.839);--color-gray-100:oklch(96.7% .003 264.542);--color-gray-400:oklch(70.7% .022 261.325);--color-gray-500:oklch(55.1% .027 264.364);--color-gray-800:oklch(27.8% .033 256.848);--color-black:#000;--color-white:#fff;--spacing:.25rem;--container-md:28rem;--text-xs:.65rem;--text-xs--line-height:calc(1/.75);--text-sm:.875rem;--text-sm--line-height:calc(1.25/.875);--text-base:1rem;--text-base--line-height: 1.5 ;--text-lg:1.125rem;--text-lg--line-height:calc(1.75/1.125);--text-xl:1.25rem;--text-xl--line-height:calc(1.75/1.25);--text-2xl:1.5rem;--text-2xl--line-height:calc(2/1.5);--text-3xl:1.875rem;--text-3xl--line-height: 1.2 ;--text-4xl:2.25rem;--text-4xl--line-height:calc(2.5/2.25);--text-5xl:3rem;--text-5xl--line-height:1;--text-6xl:3.75rem;--text-6xl--line-height:1;--text-7xl:4.5rem;--text-7xl--line-height:1;--text-8xl:6rem;--text-8xl--line-height:1;--text-9xl:8rem;--text-9xl--line-height:1;--font-weight-thin:100;--font-weight-medium:500;--font-weight-semibold:600;--font-weight-bold:700;--radius-xs:.125rem;--radius-md:.375rem;--radius-lg:.5rem;--ease-out:cubic-bezier(0,0,.2,1);--ease-in-out:cubic-bezier(.4,0,.2,1);--animate-bounce:bounce 1s infinite;--default-transition-duration:.15s;--default-transition-timing-function:cubic-bezier(.4,0,.2,1);--color-grey-50:var(--ws-grey-50);--color-grey-100:var(--ws-grey-100);--color-grey-200:var(--ws-grey-200);--color-grey-300:var(--ws-grey-300);--color-grey-400:var(--ws-grey-400);--color-grey-500:var(--ws-grey-500);--color-grey-600:var(--ws-grey-600);--color-grey-700:var(--ws-grey-700);--color-grey-800:var(--ws-grey-800);--color-primary-500:var(--ws-primary-500);--color-primary-600:var(--ws-primary-600);--color-primary-700:var(--ws-primary-700);--color-positive-200:var(--ws-positive-200);--color-positive-400:var(--ws-positive-400);--color-positive-500:var(--ws-positive-500);--color-positive-600:var(--ws-positive-600);--color-warning-500:var(--ws-warning-500);--color-warning-600:var(--ws-warning-600);--color-negative-400:var(--ws-negative-400);--color-negative-500:var(--ws-negative-500);--color-negative-600:var(--ws-negative-600);--text-xxs:.55rem;--text-s:.75rem;--min-height-6:1.5rem;--color-canvas-default:var(--ws-bg-default);--color-canvas-subtle:var(--ws-grey-100);--color-panel:var(--ws-grey-300);--color-panel-subtle:var(--ws-grey-200);--color-card:var(--ws-card-bg);--color-card-border:var(--ws-card-border);--color-body:var(--ws-bg-foreground);--color-body-bg:var(--ws-bg-default);--color-body-light:var(--ws-grey-100);--color-muted:var(--ws-grey-200);--color-neutral:var(--ws-grey-200);--color-button-text:var(--ws-button-fg);--color-primary:var(--ws-primary-default);--color-primary-hover:var(--ws-primary-hover);--color-primary-light:var(--ws-primary-light);--color-primary-dark:var(--ws-primary-dark);--color-positive:var(--ws-positive-500);--color-positive-hover:var(--ws-positive-hover);--color-positive-text:var(--ws-positive-text);--color-positive-bg:var(--ws-positive-bg);--color-positive-light:var(--ws-positive-light);--color-positive-dark:var(--ws-positive-dark);--color-negative:var(--ws-negative-500);--color-negative-hover:var(--ws-negative-hover);--color-negative-text:var(--ws-negative-text);--color-negative-bg:var(--ws-negative-bg);--color-negative-light:var(--ws-negative-light);--color-negative-dark:var(--ws-negative-dark);--color-warning:var(--ws-warning-500);--color-warning-hover:var(--ws-warning-hover);--color-warning-text:var(--ws-warning-text);--color-warning-bg:var(--ws-warning-bg);--color-warning-light:var(--ws-warning-light);--color-warning-dark:var(--ws-warning-dark);--color-input-bg:var(--ws-input-bg);--color-input-border:var(--ws-input-border);--color-input-text:var(--ws-input-text);--color-input-placeholder:var(--ws-input-placeholder);--color-input-focus-border:var(--ws-input-focus-border);--color-select-bg:var(--ws-select-bg);--color-select-border:var(--ws-select-border);--color-select-text:var(--ws-select-text);--color-select-list-bg:var(--ws-select-list-bg);--color-input-option-hover-bg:var(--ws-input-option-hover-bg);--color-input-option-active-bg:var(--ws-input-option-active-bg);--color-input-option-active-text:var(--ws-input-option-active-text);--color-input-error-border:var(--ws-input-error-border);--color-input-error-bg:var(--ws-input-error-bg);--color-input-warning-border:var(--ws-input-warning-border);--color-input-warning-bg:var(--ws-input-warning-bg);--color-input-message-bg:var(--ws-input-message-bg);--color-input-message-text:var(--ws-input-message-text);--color-input-disable:var(--ws-disable-input);--color-inactive-text:var(--ws-inactive-text);--color-panel-0:var(--ws-panel-0);--color-panel-1:var(--ws-panel-1);--color-panel-2:var(--ws-panel-2);--color-panel-3:var(--ws-panel-3);--color-panel-4:var(--ws-panel-4);--color-panel-5:var(--ws-panel-5);--color-panel-border-subtle:var(--ws-panel-border-subtle);--color-tab-bg-default:var(--ws-tab-bg-default);--color-tab-border:var(--ws-tab-border);--color-tab-active-bg:var(--ws-tab-active-bg);--color-tab-active-fg:var(--ws-tab-active-fg);--color-tab-inactive-bg:var(--ws-tab-inactive-bg);--color-tab-inactive-fg:var(--ws-tab-inactive-fg);--color-panel-border:var(--ws-panel-border)}.pointer-events-auto:not(#\\#){pointer-events:auto}.pointer-events-none:not(#\\#){pointer-events:none}.visible:not(#\\#){visibility:visible}.sr-only:not(#\\#){clip-path:inset(50%);white-space:nowrap;border-width:0;width:1px;height:1px;margin:-1px;padding:0;position:absolute;overflow:hidden}.absolute:not(#\\#){position:absolute}.fixed:not(#\\#){position:fixed}.relative:not(#\\#){position:relative}.static:not(#\\#){position:static}.inset-0:not(#\\#){inset:calc(var(--spacing)*0)}.-top-1\\/5:not(#\\#){top:-20%}.top-0:not(#\\#){top:calc(var(--spacing)*0)}.top-1:not(#\\#){top:calc(var(--spacing)*1)}.top-full:not(#\\#){top:100%}.-right-12:not(#\\#){right:calc(var(--spacing)*-12)}.right-0:not(#\\#){right:calc(var(--spacing)*0)}.right-1:not(#\\#){right:calc(var(--spacing)*1)}.bottom-0:not(#\\#){bottom:calc(var(--spacing)*0)}.bottom-full:not(#\\#){bottom:100%}.left-0:not(#\\#){left:calc(var(--spacing)*0)}.left-0\\.5:not(#\\#){left:calc(var(--spacing)*.5)}.left-1\\/2:not(#\\#){left:50%}.left-3\\.5:not(#\\#){left:calc(var(--spacing)*3.5)}.left-4:not(#\\#){left:calc(var(--spacing)*4)}.left-4\\.5:not(#\\#){left:calc(var(--spacing)*4.5)}.left-5\\.5:not(#\\#){left:calc(var(--spacing)*5.5)}.left-full:not(#\\#){left:100%}.z-1:not(#\\#){z-index:1}.z-2:not(#\\#){z-index:2}.z-10:not(#\\#){z-index:10}.z-40:not(#\\#){z-index:40}.z-50:not(#\\#){z-index:50}.z-60:not(#\\#){z-index:60}.z-9999:not(#\\#){z-index:9999}.container:not(#\\#){width:100%}@media(min-width:40rem){.container:not(#\\#){max-width:40rem}}@media(min-width:48rem){.container:not(#\\#){max-width:48rem}}@media(min-width:64rem){.container:not(#\\#){max-width:64rem}}@media(min-width:80rem){.container:not(#\\#){max-width:80rem}}@media(min-width:96rem){.container:not(#\\#){max-width:96rem}}.m-0:not(#\\#){margin:calc(var(--spacing)*0)}.m-0\\.5:not(#\\#){margin:calc(var(--spacing)*.5)}.m-px:not(#\\#){margin:1px}.mx-1:not(#\\#){margin-inline:calc(var(--spacing)*1)}.-my-1:not(#\\#){margin-block:calc(var(--spacing)*-1)}.my-1:not(#\\#){margin-block:calc(var(--spacing)*1)}.mt-1:not(#\\#){margin-top:calc(var(--spacing)*1)}.mt-2:not(#\\#){margin-top:calc(var(--spacing)*2)}.mt-4:not(#\\#){margin-top:calc(var(--spacing)*4)}.mt-8:not(#\\#){margin-top:calc(var(--spacing)*8)}.mr-1:not(#\\#){margin-right:calc(var(--spacing)*1)}.mr-2:not(#\\#){margin-right:calc(var(--spacing)*2)}.mb-1:not(#\\#){margin-bottom:calc(var(--spacing)*1)}.mb-2:not(#\\#){margin-bottom:calc(var(--spacing)*2)}.mb-4:not(#\\#){margin-bottom:calc(var(--spacing)*4)}.ml-1:not(#\\#){margin-left:calc(var(--spacing)*1)}.ml-1\\.5:not(#\\#){margin-left:calc(var(--spacing)*1.5)}.ml-2:not(#\\#){margin-left:calc(var(--spacing)*2)}.box-border:not(#\\#){box-sizing:border-box}.flex:not(#\\#){display:flex}.grid:not(#\\#){display:grid}.hidden:not(#\\#){display:none}.inline:not(#\\#){display:inline}.inline-block:not(#\\#){display:inline-block}.inline-flex:not(#\\#){display:inline-flex}.table:not(#\\#){display:table}.size-1\\.5:not(#\\#){width:calc(var(--spacing)*1.5);height:calc(var(--spacing)*1.5)}.size-1\\.75:not(#\\#){width:calc(var(--spacing)*1.75);height:calc(var(--spacing)*1.75)}.size-2:not(#\\#){width:calc(var(--spacing)*2);height:calc(var(--spacing)*2)}.size-2\\.5:not(#\\#){width:calc(var(--spacing)*2.5);height:calc(var(--spacing)*2.5)}.size-3:not(#\\#){width:calc(var(--spacing)*3);height:calc(var(--spacing)*3)}.size-3\\.5:not(#\\#){width:calc(var(--spacing)*3.5);height:calc(var(--spacing)*3.5)}.size-3\\.25:not(#\\#){width:calc(var(--spacing)*3.25);height:calc(var(--spacing)*3.25)}.size-4:not(#\\#){width:calc(var(--spacing)*4);height:calc(var(--spacing)*4)}.size-5:not(#\\#){width:calc(var(--spacing)*5);height:calc(var(--spacing)*5)}.size-6:not(#\\#){width:calc(var(--spacing)*6);height:calc(var(--spacing)*6)}.size-fit:not(#\\#){width:fit-content;height:fit-content}.h-2:not(#\\#){height:calc(var(--spacing)*2)}.h-3:not(#\\#){height:calc(var(--spacing)*3)}.h-3\\.5:not(#\\#){height:calc(var(--spacing)*3.5)}.h-4:not(#\\#){height:calc(var(--spacing)*4)}.h-4\\.5:not(#\\#){height:calc(var(--spacing)*4.5)}.h-5:not(#\\#){height:calc(var(--spacing)*5)}.h-5\\.5:not(#\\#){height:calc(var(--spacing)*5.5)}.h-6:not(#\\#){height:calc(var(--spacing)*6)}.h-7:not(#\\#){height:calc(var(--spacing)*7)}.h-7\\.5:not(#\\#){height:calc(var(--spacing)*7.5)}.h-8:not(#\\#){height:calc(var(--spacing)*8)}.h-10:not(#\\#){height:calc(var(--spacing)*10)}.h-14:not(#\\#){height:calc(var(--spacing)*14)}.h-20:not(#\\#){height:calc(var(--spacing)*20)}.h-100:not(#\\#){height:calc(var(--spacing)*100)}.h-fit:not(#\\#){height:fit-content}.h-full:not(#\\#){height:100%}.max-h-\\[400px\\]:not(#\\#){max-height:400px}.max-h-full:not(#\\#){max-height:100%}.min-h-5:not(#\\#){min-height:calc(var(--spacing)*5)}.min-h-6:not(#\\#){min-height:var(--min-height-6)}.min-h-7:not(#\\#){min-height:calc(var(--spacing)*7)}.min-h-\\[100px\\]:not(#\\#){min-height:100px}.min-h-fit:not(#\\#){min-height:fit-content}.min-h-screen:not(#\\#){min-height:100vh}.w-0\\.5:not(#\\#){width:calc(var(--spacing)*.5)}.w-1\\/2:not(#\\#){width:50%}.w-3:not(#\\#){width:calc(var(--spacing)*3)}.w-3\\.5:not(#\\#){width:calc(var(--spacing)*3.5)}.w-4:not(#\\#){width:calc(var(--spacing)*4)}.w-5:not(#\\#){width:calc(var(--spacing)*5)}.w-6:not(#\\#){width:calc(var(--spacing)*6)}.w-7:not(#\\#){width:calc(var(--spacing)*7)}.w-8:not(#\\#){width:calc(var(--spacing)*8)}.w-9:not(#\\#){width:calc(var(--spacing)*9)}.w-11:not(#\\#){width:calc(var(--spacing)*11)}.w-16:not(#\\#){width:calc(var(--spacing)*16)}.w-20:not(#\\#){width:calc(var(--spacing)*20)}.w-32:not(#\\#){width:calc(var(--spacing)*32)}.w-48:not(#\\#){width:calc(var(--spacing)*48)}.w-52:not(#\\#){width:calc(var(--spacing)*52)}.w-60:not(#\\#){width:calc(var(--spacing)*60)}.w-64:not(#\\#){width:calc(var(--spacing)*64)}.w-80:not(#\\#){width:calc(var(--spacing)*80)}.w-96:not(#\\#){width:calc(var(--spacing)*96)}.w-auto:not(#\\#){width:auto}.w-fit:not(#\\#){width:fit-content}.w-full:not(#\\#){width:100%}.w-px:not(#\\#){width:1px}.max-w-100:not(#\\#){max-width:calc(var(--spacing)*100)}.max-w-\\[300px\\]:not(#\\#){max-width:300px}.max-w-md:not(#\\#){max-width:var(--container-md)}.min-w-0:not(#\\#){min-width:calc(var(--spacing)*0)}.min-w-3\\.5:not(#\\#){min-width:calc(var(--spacing)*3.5)}.min-w-4\\.5:not(#\\#){min-width:calc(var(--spacing)*4.5)}.min-w-5:not(#\\#){min-width:calc(var(--spacing)*5)}.min-w-7\\.5:not(#\\#){min-width:calc(var(--spacing)*7.5)}.min-w-50:not(#\\#){min-width:calc(var(--spacing)*50)}.min-w-\\[150px\\]:not(#\\#){min-width:150px}.min-w-fit:not(#\\#){min-width:fit-content}.min-w-full:not(#\\#){min-width:100%}.flex-1:not(#\\#){flex:1}.flex-3:not(#\\#){flex:3}.flex-none:not(#\\#){flex:none}.shrink-0:not(#\\#){flex-shrink:0}.origin-top-right:not(#\\#){transform-origin:100% 0}.-translate-x-1\\/2:not(#\\#){--tw-translate-x: -50% ;translate:var(--tw-translate-x)var(--tw-translate-y)}.-translate-x-full:not(#\\#){--tw-translate-x:-100%;translate:var(--tw-translate-x)var(--tw-translate-y)}.translate-x-0:not(#\\#){--tw-translate-x:calc(var(--spacing)*0);translate:var(--tw-translate-x)var(--tw-translate-y)}.translate-x-full:not(#\\#){--tw-translate-x:100%;translate:var(--tw-translate-x)var(--tw-translate-y)}.-translate-y-full:not(#\\#){--tw-translate-y:-100%;translate:var(--tw-translate-x)var(--tw-translate-y)}.translate-y-0:not(#\\#){--tw-translate-y:calc(var(--spacing)*0);translate:var(--tw-translate-x)var(--tw-translate-y)}.translate-y-1\\/2:not(#\\#){--tw-translate-y: 50% ;translate:var(--tw-translate-x)var(--tw-translate-y)}.translate-y-full:not(#\\#){--tw-translate-y:100%;translate:var(--tw-translate-x)var(--tw-translate-y)}.scale-0:not(#\\#){--tw-scale-x:0%;--tw-scale-y:0%;--tw-scale-z:0%;scale:var(--tw-scale-x)var(--tw-scale-y)}.scale-95:not(#\\#){--tw-scale-x:95%;--tw-scale-y:95%;--tw-scale-z:95%;scale:var(--tw-scale-x)var(--tw-scale-y)}.scale-100:not(#\\#){--tw-scale-x:100%;--tw-scale-y:100%;--tw-scale-z:100%;scale:var(--tw-scale-x)var(--tw-scale-y)}.scale-110:not(#\\#){--tw-scale-x:110%;--tw-scale-y:110%;--tw-scale-z:110%;scale:var(--tw-scale-x)var(--tw-scale-y)}.-rotate-45:not(#\\#){rotate:-45deg}.rotate-45:not(#\\#){rotate:45deg}.rotate-90:not(#\\#){rotate:90deg}.rotate-180:not(#\\#){rotate:180deg}.transform:not(#\\#){transform:var(--tw-rotate-x,)var(--tw-rotate-y,)var(--tw-rotate-z,)var(--tw-skew-x,)var(--tw-skew-y,)}.animate-bounce:not(#\\#){animation:var(--animate-bounce)}.cursor-auto:not(#\\#){cursor:auto}.cursor-not-allowed:not(#\\#){cursor:not-allowed}.cursor-pointer:not(#\\#){cursor:pointer}.cursor-se-resize:not(#\\#){cursor:se-resize}.resize:not(#\\#){resize:both}.resize-none:not(#\\#){resize:none}.list-disc:not(#\\#){list-style-type:disc}.appearance-none:not(#\\#){-webkit-appearance:none;-moz-appearance:none;appearance:none}.grid-cols-2:not(#\\#){grid-template-columns:repeat(2,minmax(0,1fr))}.grid-cols-3:not(#\\#){grid-template-columns:repeat(3,minmax(0,1fr))}.flex-col:not(#\\#){flex-direction:column}.flex-row:not(#\\#){flex-direction:row}.flex-wrap:not(#\\#){flex-wrap:wrap}.place-content-center:not(#\\#){place-content:center}.place-items-center:not(#\\#){place-items:center}.content-center:not(#\\#){align-content:center}.items-center:not(#\\#){align-items:center}.items-end:not(#\\#){align-items:flex-end}.items-start:not(#\\#){align-items:flex-start}.justify-around:not(#\\#){justify-content:space-around}.justify-between:not(#\\#){justify-content:space-between}.justify-center:not(#\\#){justify-content:center}.gap-0\\.5:not(#\\#){gap:calc(var(--spacing)*.5)}.gap-1:not(#\\#){gap:calc(var(--spacing)*1)}.gap-1\\.5:not(#\\#){gap:calc(var(--spacing)*1.5)}.gap-2:not(#\\#){gap:calc(var(--spacing)*2)}.gap-2\\.5:not(#\\#){gap:calc(var(--spacing)*2.5)}.gap-3:not(#\\#){gap:calc(var(--spacing)*3)}.gap-4:not(#\\#){gap:calc(var(--spacing)*4)}.gap-6:not(#\\#){gap:calc(var(--spacing)*6)}.gap-8:not(#\\#){gap:calc(var(--spacing)*8)}.gap-10:not(#\\#){gap:calc(var(--spacing)*10)}.gap-14:not(#\\#){gap:calc(var(--spacing)*14)}:where(.space-y-1>:not(:last-child)):not(#\\#){--tw-space-y-reverse:0;margin-block-start:calc(calc(var(--spacing)*1)*var(--tw-space-y-reverse));margin-block-end:calc(calc(var(--spacing)*1)*calc(1 - var(--tw-space-y-reverse)))}:where(.space-y-2>:not(:last-child)):not(#\\#){--tw-space-y-reverse:0;margin-block-start:calc(calc(var(--spacing)*2)*var(--tw-space-y-reverse));margin-block-end:calc(calc(var(--spacing)*2)*calc(1 - var(--tw-space-y-reverse)))}:where(.space-y-3>:not(:last-child)):not(#\\#){--tw-space-y-reverse:0;margin-block-start:calc(calc(var(--spacing)*3)*var(--tw-space-y-reverse));margin-block-end:calc(calc(var(--spacing)*3)*calc(1 - var(--tw-space-y-reverse)))}:where(.space-y-4>:not(:last-child)):not(#\\#){--tw-space-y-reverse:0;margin-block-start:calc(calc(var(--spacing)*4)*var(--tw-space-y-reverse));margin-block-end:calc(calc(var(--spacing)*4)*calc(1 - var(--tw-space-y-reverse)))}:where(.space-y-5>:not(:last-child)):not(#\\#){--tw-space-y-reverse:0;margin-block-start:calc(calc(var(--spacing)*5)*var(--tw-space-y-reverse));margin-block-end:calc(calc(var(--spacing)*5)*calc(1 - var(--tw-space-y-reverse)))}:where(.space-y-6>:not(:last-child)):not(#\\#){--tw-space-y-reverse:0;margin-block-start:calc(calc(var(--spacing)*6)*var(--tw-space-y-reverse));margin-block-end:calc(calc(var(--spacing)*6)*calc(1 - var(--tw-space-y-reverse)))}:where(.space-y-8>:not(:last-child)):not(#\\#){--tw-space-y-reverse:0;margin-block-start:calc(calc(var(--spacing)*8)*var(--tw-space-y-reverse));margin-block-end:calc(calc(var(--spacing)*8)*calc(1 - var(--tw-space-y-reverse)))}.gap-x-1:not(#\\#){column-gap:calc(var(--spacing)*1)}.gap-x-2:not(#\\#){column-gap:calc(var(--spacing)*2)}.gap-x-3:not(#\\#){column-gap:calc(var(--spacing)*3)}.gap-x-4:not(#\\#){column-gap:calc(var(--spacing)*4)}.gap-x-20:not(#\\#){column-gap:calc(var(--spacing)*20)}:where(.space-x-4>:not(:last-child)):not(#\\#){--tw-space-x-reverse:0;margin-inline-start:calc(calc(var(--spacing)*4)*var(--tw-space-x-reverse));margin-inline-end:calc(calc(var(--spacing)*4)*calc(1 - var(--tw-space-x-reverse)))}.truncate:not(#\\#){text-overflow:ellipsis;white-space:nowrap;overflow:hidden}.overflow-hidden:not(#\\#){overflow:hidden}.overflow-y-auto:not(#\\#){overflow-y:auto}.rounded:not(#\\#){border-radius:.25rem}.rounded-full:not(#\\#){border-radius:3.40282e38px}.rounded-lg:not(#\\#){border-radius:var(--radius-lg)}.rounded-md:not(#\\#){border-radius:var(--radius-md)}.rounded-xs:not(#\\#){border-radius:var(--radius-xs)}.rounded-t:not(#\\#){border-top-left-radius:.25rem;border-top-right-radius:.25rem}.rounded-t-none:not(#\\#){border-top-left-radius:0;border-top-right-radius:0}.rounded-b-none:not(#\\#){border-bottom-right-radius:0;border-bottom-left-radius:0}.border:not(#\\#){border-style:var(--tw-border-style);border-width:1px}.border-0:not(#\\#){border-style:var(--tw-border-style);border-width:0}.border-2:not(#\\#){border-style:var(--tw-border-style);border-width:2px}.border-px:not(#\\#){border-width:1px}.divide:not(#\\#){border-width:.5px}.border-t:not(#\\#){border-top-style:var(--tw-border-style);border-top-width:1px}.border-t-0:not(#\\#){border-top-style:var(--tw-border-style);border-top-width:0}.border-r:not(#\\#){border-right-style:var(--tw-border-style);border-right-width:1px}.border-b:not(#\\#){border-bottom-style:var(--tw-border-style);border-bottom-width:1px}.border-b-0:not(#\\#){border-bottom-style:var(--tw-border-style);border-bottom-width:0}.border-dashed:not(#\\#){--tw-border-style:dashed;border-style:dashed}.border-body:not(#\\#){border-color:var(--color-body)}.border-body-light:not(#\\#){border-color:var(--color-body-light)}.border-canvas-default:not(#\\#){border-color:var(--color-canvas-default)}.border-card-border:not(#\\#){border-color:var(--color-card-border)}.border-grey-100:not(#\\#){border-color:var(--color-grey-100)}.border-grey-200:not(#\\#){border-color:var(--color-grey-200)}.border-input-border:not(#\\#){border-color:var(--color-input-border)}.border-input-disable:not(#\\#){border-color:var(--color-input-disable)}.border-input-error-border:not(#\\#){border-color:var(--color-input-error-border)}.border-input-focus-border:not(#\\#){border-color:var(--color-input-focus-border)}.border-input-warning-border:not(#\\#){border-color:var(--color-input-warning-border)}.border-negative:not(#\\#){border-color:var(--color-negative)}.border-negative-400:not(#\\#){border-color:var(--color-negative-400)}.border-negative-500:not(#\\#){border-color:var(--color-negative-500)}.border-neutral:not(#\\#){border-color:var(--color-neutral)}.border-panel:not(#\\#){border-color:var(--color-panel)}.border-panel-border:not(#\\#){border-color:var(--color-panel-border)}.border-panel-border-subtle:not(#\\#){border-color:var(--color-panel-border-subtle)}.border-panel-subtle:not(#\\#){border-color:var(--color-panel-subtle)}.border-positive:not(#\\#){border-color:var(--color-positive)}.border-positive-500:not(#\\#){border-color:var(--color-positive-500)}.border-positive-text:not(#\\#){border-color:var(--color-positive-text)}.border-primary:not(#\\#){border-color:var(--color-primary)}.border-primary-700:not(#\\#){border-color:var(--color-primary-700)}.border-primary-hover:not(#\\#){border-color:var(--color-primary-hover)}.border-select-border:not(#\\#){border-color:var(--color-select-border)}.border-tab-border:not(#\\#){border-color:var(--color-tab-border)}.border-transparent:not(#\\#){border-color:#0000}.border-warning:not(#\\#){border-color:var(--color-warning)}.border-warning-500:not(#\\#){border-color:var(--color-warning-500)}.border-warning-bg:not(#\\#){border-color:var(--color-warning-bg)}.border-white:not(#\\#){border-color:var(--color-white)}.bg-blue-500:not(#\\#){background-color:var(--color-blue-500)}.bg-body:not(#\\#){background-color:var(--color-body)}.bg-body-bg:not(#\\#){background-color:var(--color-body-bg)}.bg-canvas-default:not(#\\#){background-color:var(--color-canvas-default)}.bg-canvas-subtle:not(#\\#){background-color:var(--color-canvas-subtle)}.bg-card:not(#\\#){background-color:var(--color-card)}.bg-gray-100:not(#\\#){background-color:var(--color-gray-100)}.bg-grey-50:not(#\\#){background-color:var(--color-grey-50)}.bg-grey-200:not(#\\#){background-color:var(--color-grey-200)}.bg-grey-300:not(#\\#){background-color:var(--color-grey-300)}.bg-grey-400:not(#\\#){background-color:var(--color-grey-400)}.bg-grey-500:not(#\\#){background-color:var(--color-grey-500)}.bg-grey-600:not(#\\#){background-color:var(--color-grey-600)}.bg-grey-700:not(#\\#){background-color:var(--color-grey-700)}.bg-grey-800:not(#\\#){background-color:var(--color-grey-800)}.bg-input-bg:not(#\\#){background-color:var(--color-input-bg)}.bg-input-border:not(#\\#){background-color:var(--color-input-border)}.bg-input-disable:not(#\\#){background-color:var(--color-input-disable)}.bg-input-error-bg:not(#\\#){background-color:var(--color-input-error-bg)}.bg-input-message-bg:not(#\\#){background-color:var(--color-input-message-bg)}.bg-input-option-active-bg:not(#\\#){background-color:var(--color-input-option-active-bg)}.bg-input-option-hover-bg:not(#\\#){background-color:var(--color-input-option-hover-bg)}.bg-input-warning-bg:not(#\\#){background-color:var(--color-input-warning-bg)}.bg-negative:not(#\\#){background-color:var(--color-negative)}.bg-negative-400:not(#\\#){background-color:var(--color-negative-400)}.bg-negative-500:not(#\\#){background-color:var(--color-negative-500)}.bg-negative-bg:not(#\\#){background-color:var(--color-negative-bg)}.bg-negative-hover:not(#\\#){background-color:var(--color-negative-hover)}.bg-negative-light:not(#\\#){background-color:var(--color-negative-light)}.bg-panel:not(#\\#){background-color:var(--color-panel)}.bg-panel-0:not(#\\#){background-color:var(--color-panel-0)}.bg-panel-1:not(#\\#){background-color:var(--color-panel-1)}.bg-panel-2:not(#\\#){background-color:var(--color-panel-2)}.bg-panel-3:not(#\\#){background-color:var(--color-panel-3)}.bg-panel-4:not(#\\#){background-color:var(--color-panel-4)}.bg-panel-5:not(#\\#){background-color:var(--color-panel-5)}.bg-panel-subtle:not(#\\#){background-color:var(--color-panel-subtle)}.bg-positive:not(#\\#){background-color:var(--color-positive)}.bg-positive-200:not(#\\#){background-color:var(--color-positive-200)}.bg-positive-500:not(#\\#){background-color:var(--color-positive-500)}.bg-positive-bg:not(#\\#){background-color:var(--color-positive-bg)}.bg-positive-hover:not(#\\#){background-color:var(--color-positive-hover)}.bg-positive-light:not(#\\#){background-color:var(--color-positive-light)}.bg-primary:not(#\\#){background-color:var(--color-primary)}.bg-primary-500:not(#\\#){background-color:var(--color-primary-500)}.bg-primary-600:not(#\\#){background-color:var(--color-primary-600)}.bg-primary-hover:not(#\\#){background-color:var(--color-primary-hover)}.bg-primary-light:not(#\\#){background-color:var(--color-primary-light)}.bg-primary\\/30:not(#\\#){background-color:var(--color-primary)}@supports (color:color-mix(in lab,red,red)){.bg-primary\\/30:not(#\\#){background-color:color-mix(in oklab,var(--color-primary)30%,transparent)}}.bg-select-bg:not(#\\#){background-color:var(--color-select-bg)}.bg-select-list-bg:not(#\\#){background-color:var(--color-select-list-bg)}.bg-tab-active-bg:not(#\\#){background-color:var(--color-tab-active-bg)}.bg-tab-bg-default:not(#\\#){background-color:var(--color-tab-bg-default)}.bg-tab-inactive-bg:not(#\\#){background-color:var(--color-tab-inactive-bg)}.bg-transparent:not(#\\#){background-color:#0000}.bg-warning:not(#\\#){background-color:var(--color-warning)}.bg-warning-500:not(#\\#){background-color:var(--color-warning-500)}.bg-warning-bg:not(#\\#){background-color:var(--color-warning-bg)}.bg-warning-hover:not(#\\#){background-color:var(--color-warning-hover)}.bg-warning-light:not(#\\#){background-color:var(--color-warning-light)}.bg-white:not(#\\#){background-color:var(--color-white)}.bg-linear-to-r:not(#\\#){--tw-gradient-position:to right}@supports (background-image:linear-gradient(in lab,red,red)){.bg-linear-to-r:not(#\\#){--tw-gradient-position:to right in oklab}}.bg-linear-to-r:not(#\\#){background-image:linear-gradient(var(--tw-gradient-stops))}.from-green-500:not(#\\#){--tw-gradient-from:var(--color-green-500);--tw-gradient-stops:var(--tw-gradient-via-stops,var(--tw-gradient-position),var(--tw-gradient-from)var(--tw-gradient-from-position),var(--tw-gradient-to)var(--tw-gradient-to-position))}.from-primary:not(#\\#){--tw-gradient-from:var(--color-primary);--tw-gradient-stops:var(--tw-gradient-via-stops,var(--tw-gradient-position),var(--tw-gradient-from)var(--tw-gradient-from-position),var(--tw-gradient-to)var(--tw-gradient-to-position))}.to-blue-500:not(#\\#){--tw-gradient-to:var(--color-blue-500);--tw-gradient-stops:var(--tw-gradient-via-stops,var(--tw-gradient-position),var(--tw-gradient-from)var(--tw-gradient-from-position),var(--tw-gradient-to)var(--tw-gradient-to-position))}.to-pink-500:not(#\\#){--tw-gradient-to:var(--color-pink-500);--tw-gradient-stops:var(--tw-gradient-via-stops,var(--tw-gradient-position),var(--tw-gradient-from)var(--tw-gradient-from-position),var(--tw-gradient-to)var(--tw-gradient-to-position))}.stroke-current:not(#\\#){stroke:currentColor}.p-0:not(#\\#){padding:calc(var(--spacing)*0)}.p-0\\.5:not(#\\#){padding:calc(var(--spacing)*.5)}.p-1:not(#\\#){padding:calc(var(--spacing)*1)}.p-1\\!{padding:calc(var(--spacing)*1)!important}.p-1\\.5:not(#\\#){padding:calc(var(--spacing)*1.5)}.p-2:not(#\\#){padding:calc(var(--spacing)*2)}.p-2\\.5:not(#\\#){padding:calc(var(--spacing)*2.5)}.p-3:not(#\\#){padding:calc(var(--spacing)*3)}.p-4:not(#\\#){padding:calc(var(--spacing)*4)}.p-6:not(#\\#){padding:calc(var(--spacing)*6)}.p-8:not(#\\#){padding:calc(var(--spacing)*8)}.p-10:not(#\\#){padding:calc(var(--spacing)*10)}.p-50:not(#\\#){padding:calc(var(--spacing)*50)}.p-px:not(#\\#){padding:1px}.px-0\\.5:not(#\\#){padding-inline:calc(var(--spacing)*.5)}.px-1:not(#\\#){padding-inline:calc(var(--spacing)*1)}.px-1\\.5:not(#\\#){padding-inline:calc(var(--spacing)*1.5)}.px-2:not(#\\#){padding-inline:calc(var(--spacing)*2)}.px-3:not(#\\#){padding-inline:calc(var(--spacing)*3)}.px-4:not(#\\#){padding-inline:calc(var(--spacing)*4)}.px-6:not(#\\#){padding-inline:calc(var(--spacing)*6)}.px-7:not(#\\#){padding-inline:calc(var(--spacing)*7)}.px-8:not(#\\#){padding-inline:calc(var(--spacing)*8)}.py-0\\.5:not(#\\#){padding-block:calc(var(--spacing)*.5)}.py-1:not(#\\#){padding-block:calc(var(--spacing)*1)}.py-1\\.5:not(#\\#){padding-block:calc(var(--spacing)*1.5)}.py-2:not(#\\#){padding-block:calc(var(--spacing)*2)}.py-3:not(#\\#){padding-block:calc(var(--spacing)*3)}.pt-0\\.5:not(#\\#){padding-top:calc(var(--spacing)*.5)}.pt-1:not(#\\#){padding-top:calc(var(--spacing)*1)}.pt-1\\.5:not(#\\#){padding-top:calc(var(--spacing)*1.5)}.pt-2:not(#\\#){padding-top:calc(var(--spacing)*2)}.pl-1:not(#\\#){padding-left:calc(var(--spacing)*1)}.pl-4:not(#\\#){padding-left:calc(var(--spacing)*4)}.text-center:not(#\\#){text-align:center}.text-left:not(#\\#){text-align:left}.text-2xl:not(#\\#){font-size:var(--text-2xl);line-height:var(--tw-leading,var(--text-2xl--line-height))}.text-3xl:not(#\\#){font-size:var(--text-3xl);line-height:var(--tw-leading,var(--text-3xl--line-height))}.text-4xl:not(#\\#){font-size:var(--text-4xl);line-height:var(--tw-leading,var(--text-4xl--line-height))}.text-5xl:not(#\\#){font-size:var(--text-5xl);line-height:var(--tw-leading,var(--text-5xl--line-height))}.text-6xl:not(#\\#){font-size:var(--text-6xl);line-height:var(--tw-leading,var(--text-6xl--line-height))}.text-7xl:not(#\\#){font-size:var(--text-7xl);line-height:var(--tw-leading,var(--text-7xl--line-height))}.text-8xl:not(#\\#){font-size:var(--text-8xl);line-height:var(--tw-leading,var(--text-8xl--line-height))}.text-9xl:not(#\\#){font-size:var(--text-9xl);line-height:var(--tw-leading,var(--text-9xl--line-height))}.text-base:not(#\\#){font-size:var(--text-base);line-height:var(--tw-leading,var(--text-base--line-height))}.text-lg:not(#\\#){font-size:var(--text-lg);line-height:var(--tw-leading,var(--text-lg--line-height))}.text-sm:not(#\\#){font-size:var(--text-sm);line-height:var(--tw-leading,var(--text-sm--line-height))}.text-xl:not(#\\#){font-size:var(--text-xl);line-height:var(--tw-leading,var(--text-xl--line-height))}.text-xs:not(#\\#){font-size:var(--text-xs);line-height:var(--tw-leading,var(--text-xs--line-height))}.text-s:not(#\\#){font-size:var(--text-s)}.text-xxs:not(#\\#){font-size:var(--text-xxs)}.leading-3:not(#\\#){--tw-leading:calc(var(--spacing)*3);line-height:calc(var(--spacing)*3)}.leading-4:not(#\\#){--tw-leading:calc(var(--spacing)*4);line-height:calc(var(--spacing)*4)}.leading-5:not(#\\#){--tw-leading:calc(var(--spacing)*5);line-height:calc(var(--spacing)*5)}.leading-none:not(#\\#){--tw-leading:1;line-height:1}.font-bold:not(#\\#){--tw-font-weight:var(--font-weight-bold);font-weight:var(--font-weight-bold)}.font-medium:not(#\\#){--tw-font-weight:var(--font-weight-medium);font-weight:var(--font-weight-medium)}.font-semibold:not(#\\#){--tw-font-weight:var(--font-weight-semibold);font-weight:var(--font-weight-semibold)}.font-thin:not(#\\#){--tw-font-weight:var(--font-weight-thin);font-weight:var(--font-weight-thin)}.whitespace-nowrap:not(#\\#){white-space:nowrap}.text-body:not(#\\#){color:var(--color-body)}.text-button-text:not(#\\#){color:var(--color-button-text)}.text-gray-50:not(#\\#){color:var(--color-gray-50)}.text-gray-400:not(#\\#){color:var(--color-gray-400)}.text-gray-500:not(#\\#){color:var(--color-gray-500)}.text-gray-800:not(#\\#){color:var(--color-gray-800)}.text-grey-100:not(#\\#){color:var(--color-grey-100)}.text-grey-200:not(#\\#){color:var(--color-grey-200)}.text-grey-300:not(#\\#){color:var(--color-grey-300)}.text-grey-700:not(#\\#){color:var(--color-grey-700)}.text-inactive-text:not(#\\#){color:var(--color-inactive-text)}.text-inherit:not(#\\#){color:inherit}.text-input-disable:not(#\\#){color:var(--color-input-disable)}.text-input-message-text:not(#\\#){color:var(--color-input-message-text)}.text-input-option-active-text:not(#\\#){color:var(--color-input-option-active-text)}.text-input-placeholder:not(#\\#){color:var(--color-input-placeholder)}.text-input-text:not(#\\#){color:var(--color-input-text)}.text-muted:not(#\\#){color:var(--color-muted)}.text-negative:not(#\\#){color:var(--color-negative)}.text-negative-500:not(#\\#){color:var(--color-negative-500)}.text-negative-dark:not(#\\#){color:var(--color-negative-dark)}.text-negative-text:not(#\\#){color:var(--color-negative-text)}.text-panel-subtle:not(#\\#){color:var(--color-panel-subtle)}.text-positive:not(#\\#){color:var(--color-positive)}.text-positive-500:not(#\\#){color:var(--color-positive-500)}.text-positive-600:not(#\\#){color:var(--color-positive-600)}.text-positive-dark:not(#\\#){color:var(--color-positive-dark)}.text-positive-text:not(#\\#),.text-positive-text\\/70:not(#\\#){color:var(--color-positive-text)}@supports (color:color-mix(in lab,red,red)){.text-positive-text\\/70:not(#\\#){color:color-mix(in oklab,var(--color-positive-text)70%,transparent)}}.text-primary:not(#\\#){color:var(--color-primary)}.text-primary-dark:not(#\\#){color:var(--color-primary-dark)}.text-primary-hover:not(#\\#){color:var(--color-primary-hover)}.text-select-text:not(#\\#){color:var(--color-select-text)}.text-tab-active-fg:not(#\\#){color:var(--color-tab-active-fg)}.text-tab-inactive-fg:not(#\\#){color:var(--color-tab-inactive-fg)}.text-warning:not(#\\#){color:var(--color-warning)}.text-warning-dark:not(#\\#){color:var(--color-warning-dark)}.text-warning-text:not(#\\#){color:var(--color-warning-text)}.capitalize:not(#\\#){text-transform:capitalize}.italic:not(#\\#){font-style:italic}.decoration-transparent:not(#\\#){text-decoration-color:#0000}.opacity-0:not(#\\#){opacity:0}.opacity-50:not(#\\#){opacity:.5}.opacity-60:not(#\\#){opacity:.6}.opacity-80:not(#\\#){opacity:.8}.opacity-100:not(#\\#){opacity:1}.shadow:not(#\\#){--tw-shadow:0 1px 3px 0 var(--tw-shadow-color,#0000001a),0 1px 2px -1px var(--tw-shadow-color,#0000001a);box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.shadow-inner:not(#\\#){--tw-shadow:inset 0 2px 4px 0 var(--tw-shadow-color,#0000000d);box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.shadow-lg:not(#\\#){--tw-shadow:0 10px 15px -3px var(--tw-shadow-color,#0000001a),0 4px 6px -4px var(--tw-shadow-color,#0000001a);box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.shadow-md:not(#\\#){--tw-shadow:0 4px 6px -1px var(--tw-shadow-color,#0000001a),0 2px 4px -2px var(--tw-shadow-color,#0000001a);box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.shadow-xs:not(#\\#){--tw-shadow:0 1px 2px 0 var(--tw-shadow-color,#0000000d);box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.ring-0:not(#\\#){--tw-ring-shadow:var(--tw-ring-inset,)0 0 0 calc(0px + var(--tw-ring-offset-width))var(--tw-ring-color,currentcolor);box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.ring-1:not(#\\#){--tw-ring-shadow:var(--tw-ring-inset,)0 0 0 calc(1px + var(--tw-ring-offset-width))var(--tw-ring-color,currentcolor);box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.ring-input-error-border:not(#\\#){--tw-ring-color:var(--color-input-error-border)}.ring-input-focus-border:not(#\\#){--tw-ring-color:var(--color-input-focus-border)}.ring-input-warning-border:not(#\\#){--tw-ring-color:var(--color-input-warning-border)}.ring-positive:not(#\\#){--tw-ring-color:var(--color-positive)}.outline-hidden:not(#\\#){--tw-outline-style:none;outline-style:none}@media(forced-colors:active){.outline-hidden:not(#\\#){outline-offset:2px;outline:2px solid #0000}}.outline:not(#\\#),.outline-1:not(#\\#){outline-style:var(--tw-outline-style);outline-width:1px}.outline-s:not(#\\#){outline-width:.5px}.outline-xs:not(#\\#){outline-width:.3px}.outline-xxs:not(#\\#){outline-width:.1px}.outline-canvas-default:not(#\\#){outline-color:var(--color-canvas-default)}.outline-primary:not(#\\#){outline-color:var(--color-primary)}.blur:not(#\\#){--tw-blur:blur(8px);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:not(#\\#){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:not(#\\#){transition-property:color,background-color,border-color,outline-color,text-decoration-color,fill,stroke,--tw-gradient-from,--tw-gradient-via,--tw-gradient-to,opacity,box-shadow,transform,translate,scale,rotate,filter,-webkit-backdrop-filter,backdrop-filter,display,content-visibility,overlay,pointer-events;transition-timing-function:var(--tw-ease,var(--default-transition-timing-function));transition-duration:var(--tw-duration,var(--default-transition-duration))}.transition-all:not(#\\#){transition-property:all;transition-timing-function:var(--tw-ease,var(--default-transition-timing-function));transition-duration:var(--tw-duration,var(--default-transition-duration))}.transition-colors:not(#\\#){transition-property:color,background-color,border-color,outline-color,text-decoration-color,fill,stroke,--tw-gradient-from,--tw-gradient-via,--tw-gradient-to;transition-timing-function:var(--tw-ease,var(--default-transition-timing-function));transition-duration:var(--tw-duration,var(--default-transition-duration))}.transition-transform:not(#\\#){transition-property:transform,translate,scale,rotate;transition-timing-function:var(--tw-ease,var(--default-transition-timing-function));transition-duration:var(--tw-duration,var(--default-transition-duration))}.duration-150:not(#\\#){--tw-duration:.15s;transition-duration:.15s}.duration-200:not(#\\#){--tw-duration:.2s;transition-duration:.2s}.duration-300:not(#\\#){--tw-duration:.3s;transition-duration:.3s}.ease-in-out:not(#\\#){--tw-ease:var(--ease-in-out);transition-timing-function:var(--ease-in-out)}.ease-out:not(#\\#){--tw-ease:var(--ease-out);transition-timing-function:var(--ease-out)}.outline-solid:not(#\\#){--tw-outline-style:solid;outline-style:solid}.select-none:not(#\\#){-webkit-user-select:none;user-select:none}@media(hover:hover){.group-hover\\:flex:is(:where(.group):hover *):not(#\\#){display:flex}.group-hover\\:grid:is(:where(.group):hover *):not(#\\#){display:grid}.group-hover\\:border-body:is(:where(.group):hover *):not(#\\#){border-color:var(--color-body)}.group-hover\\:border-negative-text:is(:where(.group):hover *):not(#\\#){border-color:var(--color-negative-text)}.group-hover\\:border-positive-text:is(:where(.group):hover *):not(#\\#){border-color:var(--color-positive-text)}.group-hover\\:border-warning-text:is(:where(.group):hover *):not(#\\#){border-color:var(--color-warning-text)}.group-hover\\:bg-grey-400:is(:where(.group):hover *):not(#\\#){background-color:var(--color-grey-400)}.group-hover\\:bg-negative-hover:is(:where(.group):hover *):not(#\\#){background-color:var(--color-negative-hover)}.group-hover\\:bg-negative-light:is(:where(.group):hover *):not(#\\#){background-color:var(--color-negative-light)}.group-hover\\:bg-positive-hover:is(:where(.group):hover *):not(#\\#){background-color:var(--color-positive-hover)}.group-hover\\:bg-positive-light:is(:where(.group):hover *):not(#\\#){background-color:var(--color-positive-light)}.group-hover\\:bg-primary-hover:is(:where(.group):hover *):not(#\\#){background-color:var(--color-primary-hover)}.group-hover\\:bg-primary-light:is(:where(.group):hover *):not(#\\#){background-color:var(--color-primary-light)}.group-hover\\:bg-warning-hover:is(:where(.group):hover *):not(#\\#){background-color:var(--color-warning-hover)}.group-hover\\:bg-warning-light:is(:where(.group):hover *):not(#\\#){background-color:var(--color-warning-light)}.group-hover\\:opacity-100:is(:where(.group):hover *):not(#\\#){opacity:1}}.placeholder\\:text-input-placeholder:not(#\\#)::placeholder{color:var(--color-input-placeholder)}.placeholder\\:opacity-60:not(#\\#)::placeholder{opacity:.6}.first\\:-ml-1\\.5:first-child:not(#\\#){margin-left:calc(var(--spacing)*-1.5)}.first\\:rounded-t:first-child:not(#\\#){border-top-left-radius:.25rem;border-top-right-radius:.25rem}.first\\:rounded-l:first-child:not(#\\#){border-top-left-radius:.25rem;border-bottom-left-radius:.25rem}.last\\:-mr-1\\.5:last-child:not(#\\#){margin-right:calc(var(--spacing)*-1.5)}.last\\:rounded-r:last-child:not(#\\#){border-top-right-radius:.25rem;border-bottom-right-radius:.25rem}.last\\:rounded-b:last-child:not(#\\#){border-bottom-right-radius:.25rem;border-bottom-left-radius:.25rem}.only\\:-mx-0\\.5:only-child:not(#\\#){margin-inline:calc(var(--spacing)*-.5)}.only\\:rounded:only-child:not(#\\#){border-radius:.25rem}.focus-within\\:border-input-error-border:focus-within:not(#\\#){border-color:var(--color-input-error-border)}.focus-within\\:border-input-focus-border:focus-within:not(#\\#){border-color:var(--color-input-focus-border)}.focus-within\\:border-input-warning-border:focus-within:not(#\\#){border-color:var(--color-input-warning-border)}.focus-within\\:border-positive:focus-within:not(#\\#){border-color:var(--color-positive)}@media(hover:hover){.hover\\:border-black:hover:not(#\\#){border-color:var(--color-black)}.hover\\:border-canvas-subtle:hover:not(#\\#){border-color:var(--color-canvas-subtle)}.hover\\:border-negative-hover:hover:not(#\\#){border-color:var(--color-negative-hover)}.hover\\:border-positive-hover:hover:not(#\\#){border-color:var(--color-positive-hover)}.hover\\:border-primary-hover:hover:not(#\\#){border-color:var(--color-primary-hover)}.hover\\:border-warning-hover:hover:not(#\\#){border-color:var(--color-warning-hover)}.hover\\:bg-canvas-subtle:hover:not(#\\#){background-color:var(--color-canvas-subtle)}.hover\\:bg-grey-500:hover:not(#\\#){background-color:var(--color-grey-500)}.hover\\:bg-grey-700:hover:not(#\\#){background-color:var(--color-grey-700)}.hover\\:bg-input-option-hover-bg:hover:not(#\\#){background-color:var(--color-input-option-hover-bg)}.hover\\:bg-negative:hover:not(#\\#){background-color:var(--color-negative)}.hover\\:bg-negative-600:hover:not(#\\#){background-color:var(--color-negative-600)}.hover\\:bg-negative-hover:hover:not(#\\#){background-color:var(--color-negative-hover)}.hover\\:bg-positive:hover:not(#\\#){background-color:var(--color-positive)}.hover\\:bg-positive-600:hover:not(#\\#){background-color:var(--color-positive-600)}.hover\\:bg-positive-hover:hover:not(#\\#){background-color:var(--color-positive-hover)}.hover\\:bg-primary-600:hover:not(#\\#){background-color:var(--color-primary-600)}.hover\\:bg-primary-hover:hover:not(#\\#){background-color:var(--color-primary-hover)}.hover\\:bg-primary\\/20:hover:not(#\\#){background-color:var(--color-primary)}@supports (color:color-mix(in lab,red,red)){.hover\\:bg-primary\\/20:hover:not(#\\#){background-color:color-mix(in oklab,var(--color-primary)20%,transparent)}}.hover\\:bg-transparent:hover:not(#\\#){background-color:#0000}.hover\\:bg-warning:hover:not(#\\#){background-color:var(--color-warning)}.hover\\:bg-warning-600:hover:not(#\\#){background-color:var(--color-warning-600)}.hover\\:bg-warning-hover:hover:not(#\\#){background-color:var(--color-warning-hover)}.hover\\:text-body:hover:not(#\\#){color:var(--color-body)}.hover\\:text-button-text:hover:not(#\\#){color:var(--color-button-text)}.hover\\:text-gray-50:hover:not(#\\#){color:var(--color-gray-50)}.hover\\:text-grey-200:hover:not(#\\#){color:var(--color-grey-200)}.hover\\:text-negative-400:hover:not(#\\#){color:var(--color-negative-400)}.hover\\:text-negative-hover:hover:not(#\\#){color:var(--color-negative-hover)}.hover\\:text-positive-400:hover:not(#\\#){color:var(--color-positive-400)}.hover\\:text-positive-hover:hover:not(#\\#){color:var(--color-positive-hover)}.hover\\:text-positive-text:hover:not(#\\#){color:var(--color-positive-text)}.hover\\:text-primary-hover:hover:not(#\\#){color:var(--color-primary-hover)}.hover\\:text-tab-active-fg:hover:not(#\\#){color:var(--color-tab-active-fg)}.hover\\:text-warning-hover:hover:not(#\\#){color:var(--color-warning-hover)}.hover\\:decoration-current:hover:not(#\\#){text-decoration-color:currentColor}}.focus\\:bg-transparent:focus:not(#\\#){background-color:#0000}.focus\\:ring-2:focus:not(#\\#){--tw-ring-shadow:var(--tw-ring-inset,)0 0 0 calc(2px + var(--tw-ring-offset-width))var(--tw-ring-color,currentcolor);box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.focus\\:ring-negative:focus:not(#\\#){--tw-ring-color:var(--color-negative)}.focus\\:ring-positive:focus:not(#\\#){--tw-ring-color:var(--color-positive)}.focus\\:ring-primary:focus:not(#\\#){--tw-ring-color:var(--color-primary)}.focus\\:ring-warning:focus:not(#\\#){--tw-ring-color:var(--color-warning)}.focus\\:ring-offset-0:focus:not(#\\#){--tw-ring-offset-width:0px;--tw-ring-offset-shadow:var(--tw-ring-inset,)0 0 0 var(--tw-ring-offset-width)var(--tw-ring-offset-color)}.focus\\:ring-offset-2:focus:not(#\\#){--tw-ring-offset-width:2px;--tw-ring-offset-shadow:var(--tw-ring-inset,)0 0 0 var(--tw-ring-offset-width)var(--tw-ring-offset-color)}.focus\\:outline-hidden:focus:not(#\\#){--tw-outline-style:none;outline-style:none}@media(forced-colors:active){.focus\\:outline-hidden:focus:not(#\\#){outline-offset:2px;outline:2px solid #0000}}.focus-visible\\:ring-2:focus-visible:not(#\\#){--tw-ring-shadow:var(--tw-ring-inset,)0 0 0 calc(2px + var(--tw-ring-offset-width))var(--tw-ring-color,currentcolor);box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.focus-visible\\:ring-primary:focus-visible:not(#\\#){--tw-ring-color:var(--color-primary)}.focus-visible\\:ring-offset-2:focus-visible:not(#\\#){--tw-ring-offset-width:2px;--tw-ring-offset-shadow:var(--tw-ring-inset,)0 0 0 var(--tw-ring-offset-width)var(--tw-ring-offset-color)}:root:not(#\\#){--ws-primary-50:#f2ddff;--ws-primary-100:#edd0ff;--ws-primary-300:#d0acef;--ws-primary-400:#c190ea;--ws-primary-600:#935ebf;--ws-primary-800:#563374;--ws-primary-900:#381e4f;--ws-primary-950:#29133c;--ws-positive-50:#ecf9f2;--ws-positive-100:#d9f2e6;--ws-positive-300:#8ed9b3;--ws-positive-400:#68cd99;--ws-positive-700:#28734d;--ws-positive-800:#28734d;--ws-positive-900:#0d261a;--ws-positive-950:#07130d;--ws-warning-50:#fff7e6;--ws-warning-100:#ffefcc;--ws-warning-300:#fed066;--ws-warning-400:#fdc133;--ws-warning-700:#986a00;--ws-warning-800:#654700;--ws-warning-900:#332300;--ws-warning-950:#191200;--ws-negative-50:#feeeee;--ws-negative-100:#fcdcdc;--ws-negative-300:#f69797;--ws-negative-400:#f37575;--ws-negative-700:#9a3232;--ws-negative-800:#6e2222;--ws-negative-900:#431212;--ws-negative-950:#2e0a0a;--ws-grey-300:#535353;--ws-grey-400:#484848;--ws-grey-600:#3f3f3f;--ws-palette-primary-200:#e0c7f5;--ws-palette-primary-500:#b174e5;--ws-palette-primary-700:#75499a;--ws-button-bg:var(--vscode-button-background,var(--theia-button-background,var(--ws-palette-primary-500)));--ws-button-fg:var(--vscode-button-foreground,var(--theia-button-foreground,var(--ws-palette-white)));--ws-primary-default:var(--ws-button-bg);--ws-button-text:var(--ws-button-fg);--ws-primary-hover:var(--vscode-button-hoverBackground,var(--theia-button-hoverBackground,var(--ws-palette-primary-700)));--ws-primary-light:var(--vscode-editorInfo-foreground,var(--theia-button-hoverBackground,var(--ws-palette-primary-200)));--ws-primary-dark:var(--vscode-editor-lineHighlightBackground,var(--theia-button-hoverBackground,var(--ws-palette-primary-700)));--ws-primary-200:var(--ws-primary-light);--ws-primary-500:var(--ws-primary-default);--ws-primary-700:var(--ws-primary-hover);--ws-palette-positive-200:#b3e6cc;--ws-palette-positive-500:#42c080;--ws-palette-positive-600:#359a66;--ws-positive-dark:var(--vscode-gitDecoration-addedResourceForeground,var(--ws-palette-positive-600));--ws-positive-hover:var(--ws-positive-dark);--ws-positive-bg:var(--ws-palette-positive-100);--ws-positive-light:var(--ws-palette-positive-200);--ws-positive-border:var(--ws-positive-500);--ws-positive-text:var(--ws-positive-500);--ws-positive-500:var(--vscode-testing-iconPassed,var(--ws-palette-positive-500));--ws-positive-200:var(--ws-positive-light);--ws-positive-600:var(--ws-positive-dark);--ws-palette-warning-200:#fee099;--ws-palette-warning-500:#fdb100;--ws-palette-warning-600:#ca8e00;--ws-warning-hover:var(--ws-warning-600);--ws-warning-text:var(--ws-warning-500);--ws-warning-border:var(--ws-warning-500);--ws-warning-500:var(--vscode-list-warningForeground,var(--ws-palette-warning-500));--ws-warning-bg:var(--vscode-inputValidation-warningBackground,var(--ws-palette-warning-500));--ws-warning-light:var(--vscode-inputValidation-warningBackground,var(--ws-palette-warning-200));--ws-warning-dark:var(--vscode-inputValidation-warningBackground,var(--ws-palette-warning-600));--ws-warning-200:var(--ws-warning-light);--ws-warning-600:var(--ws-warning-dark);--ws-palette-negative-200:#f9baba;--ws-palette-negative-500:#f05252;--ws-palette-negative-600:#c54242;--ws-negative-hover:var(--ws-negative-600);--ws-negative-text:var(--ws-negative-500);--ws-negative-500:var(--vscode-errorForeground,var(--ws-palette-negative-500));--ws-negative-light:var(--vscode-inputValidation-errorBackground,var(--ws-palette-negative-200));--ws-negative-dark:var(--vscode-inputValidation-errorBackground,var(--ws-palette-negative-600));--ws-negative-200:var(--ws-negative-light);--ws-negative-600:var(--ws-negative-dark);--ws-palette-white:#fff;--ws-palette-grey-50:#f1f5f9;--ws-palette-grey-100:#ccc;--ws-palette-grey-200:#888;--ws-palette-grey-300:#535353;--ws-palette-grey-400:#484848;--ws-palette-grey-500:#444;--ws-palette-grey-600:#3f3f3f;--ws-palette-grey-700:#393939;--ws-palette-grey-800:#383838;--ws-palette-grey-900:#262626;--ws-palette-grey-950:#151515;--ws-bg-default:var(--vscode-editor-background,var(--theia-editor-background,var(--ws-palette-white)));--ws-bg-foreground:var(--vscode-editor-foreground,var(--theia-panel-foreground,var(--ws-palette-grey-50)));--ws-grey-50:var(--ws-bg-foreground);--ws-grey-100:var(--vscode-panel-background,var(--theia-panel-background,var(--ws-palette-grey-100)));--ws-grey-200:var(--vscode-editor-background,var(--theia-editor-background,var(--ws-palette-grey-200)));--ws-grey-950:var(--vscode-panel-border,var(--theia-border-color,var(--ws-palette-grey-950)));--ws-grey-500:var(--vscode-descriptionForeground,var(--ws-palette-grey-500));--ws-grey-800:var(--vscode-descriptionForeground,var(--ws-palette-grey-800));--ws-card-bg:var(--vscode-editorGroupHeader-tabsBackground,var(--theia-editor-group-header-background,var(--ws-palette-grey-900)));--ws-card-border:var(--vscode-editorGroupHeader-tabsBorder,var(--theia-editor-group-header-background,var(--ws-palette-grey-50)));--ws-palette-input-bg:var(--ws-palette-grey-300);--ws-palette-input-border:var(--ws-palette-grey-300);--ws-palette-input-text:var(--ws-palette-grey-50);--ws-palette-input-placeholder:var(--ws-palette-grey-200);--ws-palette-input-focus-border:var(--ws-palette-grey-50);--ws-input-bg:var(--vscode-input-background,var(--theia-input-background,var(--ws-palette-input-bg)));--ws-input-border:var(--vscode-input-border,var(--theia-input-border,var(--ws-palette-input-border)));--ws-input-text:var(--vscode-input-foreground,var(--theia-input-foreground,var(--ws-palette-input-text)));--ws-input-placeholder:var(--vscode-input-placeholderForeground,var(--theia-input-placeholderForeground,var(--ws-palette-input-placeholder)));--ws-input-focus-border:var(--vscode-focusBorder,var(--theia-focusBorder,var(--ws-palette-primary-500)));--ws-select-bg:var(--vscode-dropdown-background,var(--theia-dropdown-background,var(--ws-input-bg)));--ws-select-border:var(--vscode-dropdown-border,var(--theia-dropdown-border,var(--ws-input-border)));--ws-select-text:var(--vscode-dropdown-foreground,var(--theia-dropdown-foreground,var(--ws-input-text)));--ws-select-list-bg:var(--vscode-dropdown-listBackground,var(--theia-dropdown-listBackground,var(--ws-palette-grey-900)));--ws-input-option-hover-bg:var(--vscode-list-hoverBackground,var(--theia-list-hoverBackground,var(--ws-palette-primary-700)));--ws-input-option-active-bg:var(--vscode-list-activeSelectionBackground,var(--theia-list-activeSelectionBackground,var(--ws-palette-primary-500)));--ws-input-option-active-text:var(--vscode-list-activeSelectionForeground,var(--theia-list-activeSelectionForeground,var(--ws-palette-white)));--ws-input-error-border:var(--vscode-inputValidation-errorBorder,var(--theia-inputValidation-errorBorder,var(--ws-palette-negative-500)));--ws-input-error-bg:var(--vscode-inputValidation-errorBackground,var(--theia-inputValidation-errorBackground,var(--ws-palette-negative-200)));--ws-input-warning-border:var(--vscode-inputValidation-warningBorder,var(--theia-inputValidation-warningBorder,var(--ws-palette-warning-500)));--ws-input-warning-bg:var(--vscode-inputValidation-warningBackground,var(--theia-inputValidation-warningBackground,var(--ws-palette-warning-200)));--ws-input-info-bg:var(--vscode-panel-background,var(--theia-inputValidation-infoBackground,var(--ws-palette-primary-200)));--ws-input-message-bg:var(--vscode-editor-lineHighlightBackground,var(--theia-inputValidation-infoBackground,var(--ws-palette-primary-200)));--ws-input-message-text:var(--vscode-editorInfo-foreground,var(--theia-inputValidation-infoForeground,var(--ws-palette-primary-500)));--ws-inactive-text:var(--vscode-disabledForeground,var(--theia-disabled-foreground,var(--ws-palette-grey-200)));--ws-disable-bg:var(--vscode-button-disabledBackground,var(--theia-button-disabledBackground,var(--ws-palette-grey-300)));--ws-disable-input:var(--vscode-button-disabledBackground,var(--theia-button-disabledBackground,var(--ws-palette-grey-200)));--ws-panel-0:var(--vscode-editor-background,var(--theia-editor-background,var(--ws-palette-grey-900)));--ws-panel-1:var(--vscode-sideBar-background,var(--theia-sideBar-background,var(--ws-palette-grey-700)));--ws-panel-2:var(--vscode-panel-background,var(--theia-panel-background,var(--ws-palette-grey-900)));--ws-panel-3:var(--vscode-editorGroupHeader-tabsBackground,var(--theia-editor-group-header-background,var(--ws-palette-grey-900)));--ws-panel-4:var(--vscode-editorWidget-background,var(--theia-editorWidget-background,var(--ws-palette-grey-300)));--ws-panel-5:var(--vscode-editorWidget-background,var(--theia-editorWidget-background,var(--ws-palette-grey-950)));--ws-panel-border-subtle:var(--vscode-panel-border,var(--theia-border-color,var(--ws-palette-grey-100)));--ws-panel-border-strong:var(--vscode-contrastBorder,var(--theia-contrastBorder,var(--ws-palette-grey-300)));--ws-tab-bg-default:var(--vscode-editorGroupHeader-tabsBackground,var(--ws-palette-grey-900));--ws-tab-border:var(--vscode-tab-border,var(--ws-palette-grey-950));--ws-tab-active-bg:var(--vscode-tab-activeBackground,var(--ws-palette-grey-800));--ws-tab-active-fg:var(--vscode-tab-activeForeground,var(--ws-bg-foreground));--ws-tab-inactive-bg:var(--vscode-tab-inactiveBackground,var(--ws-palette-grey-900));--ws-tab-inactive-fg:var(--vscode-tab-inactiveForeground,var(--ws-palette-grey-200));--ws-tab-hover-bg:var(--vscode-tab-hoverBackground,var(--ws-palette-grey-700));--ws-panel-header-bg:var(--vscode-sideBarSectionHeader-background,var(--ws-palette-grey-800));--ws-panel-header-fg:var(--vscode-sideBarSectionHeader-foreground,var(--ws-bg-foreground));--ws-panel-bg:var(--vscode-panel-background,var(--ws-bg-default));--ws-panel-border:var(--vscode-panel-border,var(--ws-palette-grey-950));--ws-panel-title-active-border:var(--vscode-panelTitle-activeBorder,var(--ws-palette-primary-500));--ws-panel-title-active-fg:var(--vscode-panelTitle-activeForeground,var(--ws-bg-foreground));--ws-panel-title-inactive-fg:var(--vscode-panelTitle-inactiveForeground,var(--ws-palette-grey-100))}.center-absolute:not(#\\#){--tw-translate-x: -50% ;--tw-translate-y: -50% ;translate:var(--tw-translate-x)var(--tw-translate-y);transform:var(--tw-rotate-x,)var(--tw-rotate-y,)var(--tw-rotate-z,)var(--tw-skew-x,)var(--tw-skew-y,);position:absolute;top:50%;left:50%}.ws-group:hover .ws-checkbox-hover-target{opacity:1!important}.simplebar-scrollbar:not(#\\#):before{background-color:#ccc}@property --tw-translate-x{syntax:"*";inherits:false;initial-value:0}@property --tw-translate-y{syntax:"*";inherits:false;initial-value:0}@property --tw-translate-z{syntax:"*";inherits:false;initial-value:0}@property --tw-scale-x{syntax:"*";inherits:false;initial-value:1}@property --tw-scale-y{syntax:"*";inherits:false;initial-value:1}@property --tw-scale-z{syntax:"*";inherits:false;initial-value:1}@property --tw-rotate-x{syntax:"*";inherits:false}@property --tw-rotate-y{syntax:"*";inherits:false}@property --tw-rotate-z{syntax:"*";inherits:false}@property --tw-skew-x{syntax:"*";inherits:false}@property --tw-skew-y{syntax:"*";inherits:false}@property --tw-space-y-reverse{syntax:"*";inherits:false;initial-value:0}@property --tw-space-x-reverse{syntax:"*";inherits:false;initial-value:0}@property --tw-border-style{syntax:"*";inherits:false;initial-value:solid}@property --tw-gradient-position{syntax:"*";inherits:false}@property --tw-gradient-from{syntax:"<color>";inherits:false;initial-value:#0000}@property --tw-gradient-via{syntax:"<color>";inherits:false;initial-value:#0000}@property --tw-gradient-to{syntax:"<color>";inherits:false;initial-value:#0000}@property --tw-gradient-stops{syntax:"*";inherits:false}@property --tw-gradient-via-stops{syntax:"*";inherits:false}@property --tw-gradient-from-position{syntax:"<length-percentage>";inherits:false;initial-value:0%}@property --tw-gradient-via-position{syntax:"<length-percentage>";inherits:false;initial-value:50%}@property --tw-gradient-to-position{syntax:"<length-percentage>";inherits:false;initial-value:100%}@property --tw-leading{syntax:"*";inherits:false}@property --tw-font-weight{syntax:"*";inherits:false}@property --tw-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-shadow-color{syntax:"*";inherits:false}@property --tw-shadow-alpha{syntax:"<percentage>";inherits:false;initial-value:100%}@property --tw-inset-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-inset-shadow-color{syntax:"*";inherits:false}@property --tw-inset-shadow-alpha{syntax:"<percentage>";inherits:false;initial-value:100%}@property --tw-ring-color{syntax:"*";inherits:false}@property --tw-ring-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-inset-ring-color{syntax:"*";inherits:false}@property --tw-inset-ring-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-ring-inset{syntax:"*";inherits:false}@property --tw-ring-offset-width{syntax:"<length>";inherits:false;initial-value:0}@property --tw-ring-offset-color{syntax:"*";inherits:false;initial-value:#fff}@property --tw-ring-offset-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-outline-style{syntax:"*";inherits:false;initial-value:solid}@property --tw-blur{syntax:"*";inherits:false}@property --tw-brightness{syntax:"*";inherits:false}@property --tw-contrast{syntax:"*";inherits:false}@property --tw-grayscale{syntax:"*";inherits:false}@property --tw-hue-rotate{syntax:"*";inherits:false}@property --tw-invert{syntax:"*";inherits:false}@property --tw-opacity{syntax:"*";inherits:false}@property --tw-saturate{syntax:"*";inherits:false}@property --tw-sepia{syntax:"*";inherits:false}@property --tw-drop-shadow{syntax:"*";inherits:false}@property --tw-drop-shadow-color{syntax:"*";inherits:false}@property --tw-drop-shadow-alpha{syntax:"<percentage>";inherits:false;initial-value:100%}@property --tw-drop-shadow-size{syntax:"*";inherits:false}@property --tw-duration{syntax:"*";inherits:false}@property --tw-ease{syntax:"*";inherits:false}@keyframes bounce{0%,to{animation-timing-function:cubic-bezier(.8,0,1,1);transform:translateY(-25%)}50%{animation-timing-function:cubic-bezier(0,0,.2,1);transform:none}}[data-simplebar]{position:relative;flex-direction:column;flex-wrap:wrap;justify-content:flex-start;align-content:flex-start;align-items:flex-start}.simplebar-wrapper{overflow:hidden;width:inherit;height:inherit;max-width:inherit;max-height:inherit}.simplebar-mask{direction:inherit;position:absolute;overflow:hidden;padding:0;margin:0;left:0;top:0;bottom:0;right:0;width:auto!important;height:auto!important;z-index:0}.simplebar-offset{direction:inherit!important;box-sizing:inherit!important;resize:none!important;position:absolute;top:0;left:0;bottom:0;right:0;padding:0;margin:0;-webkit-overflow-scrolling:touch}.simplebar-content-wrapper{direction:inherit;box-sizing:border-box!important;position:relative;display:block;height:100%;width:auto;max-width:100%;max-height:100%;overflow:auto;scrollbar-width:none;-ms-overflow-style:none}.simplebar-content-wrapper::-webkit-scrollbar,.simplebar-hide-scrollbar::-webkit-scrollbar{display:none;width:0;height:0}.simplebar-content:after,.simplebar-content:before{content:" ";display:table}.simplebar-placeholder{max-height:100%;max-width:100%;width:100%;pointer-events:none}.simplebar-height-auto-observer-wrapper{box-sizing:inherit!important;height:100%;width:100%;max-width:1px;position:relative;float:left;max-height:1px;overflow:hidden;z-index:-1;padding:0;margin:0;pointer-events:none;flex-grow:inherit;flex-shrink:0;flex-basis:0}.simplebar-height-auto-observer{box-sizing:inherit;display:block;opacity:0;position:absolute;top:0;left:0;height:1000%;width:1000%;min-height:1px;min-width:1px;overflow:hidden;pointer-events:none;z-index:-1}.simplebar-track{z-index:1;position:absolute;right:0;bottom:0;pointer-events:none;overflow:hidden}[data-simplebar].simplebar-dragging,[data-simplebar].simplebar-dragging .simplebar-content{pointer-events:none;-webkit-touch-callout:none;-webkit-user-select:none;-khtml-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}[data-simplebar].simplebar-dragging .simplebar-track{pointer-events:all}.simplebar-scrollbar{position:absolute;left:0;right:0;min-height:10px}.simplebar-scrollbar:before{position:absolute;content:"";background:#000;border-radius:7px;left:2px;right:2px;opacity:0;transition:opacity .2s .5s linear}.simplebar-scrollbar.simplebar-visible:before{opacity:.5;transition-delay:0s;transition-duration:0s}.simplebar-track.simplebar-vertical{top:0;width:11px}.simplebar-scrollbar:before{top:2px;bottom:2px;left:2px;right:2px}.simplebar-track.simplebar-horizontal{left:0;height:11px}.simplebar-track.simplebar-horizontal .simplebar-scrollbar{right:auto;left:0;top:0;bottom:0;min-height:0;min-width:10px;width:auto}[data-simplebar-direction=rtl] .simplebar-track.simplebar-vertical{right:auto;left:0}.simplebar-dummy-scrollbar-size{direction:rtl;position:fixed;opacity:0;visibility:hidden;height:500px;width:500px;overflow-y:hidden;overflow-x:scroll;-ms-overflow-style:scrollbar!important}.simplebar-dummy-scrollbar-size>div{width:200%;height:200%;margin:10px 0}.simplebar-hide-scrollbar{position:fixed;left:0;visibility:hidden;overflow-y:scroll;scrollbar-width:none;-ms-overflow-style:none}
|
|
2
|
+
`,document.head.appendChild(e)}catch(e){console.error("vite-plugin-inject-css: failed to inject css",e)}})();const y8=e=>O.jsx("svg",{width:"1em",height:"1em",viewBox:"0 0 24 24",...e,children:O.jsx("path",{d:"M21.66 6.28a.5.5 0 0 0 0-.697l-.967-.993a.5.5 0 0 0-.716 0L8.499 16.373 4.023 11.78a.5.5 0 0 0-.716 0l-.967.993a.5.5 0 0 0 0 .697l5.889 6.046.014-.014a.377.377 0 0 0 .54 0L21.66 6.28Z",fill:"currentColor"})}),x8=e=>O.jsx("svg",{width:"1em",height:"1em",viewBox:"0 0 24 24",...e,children:O.jsx("path",{d:"M10.84 2.714c0-.394.346-.714.773-.714h.774c.427 0 .773.32.773.714V9.5h5.025c.427 0 .773.32.773.714v3.572H5.042v-3.572c0-.394.346-.714.773-.714h5.025V2.714ZM5.042 14.5h13.916l1.034 6.685c.067.43-.295.815-.765.815h-2.1l-.681-5.929L15.764 22h-3.236l-.721-2.143L11.086 22h-2.85l-.682-3.929L6.872 22H4.773c-.47 0-.832-.385-.765-.815L5.042 14.5Z",fill:"currentColor"})}),Td=e=>O.jsx("svg",{width:"1em",height:"1em",viewBox:"0 0 24 24",...e,children:O.jsx("path",{d:"M4.497 5.361a.5.5 0 0 0 0 .707L10.429 12l-5.932 5.932a.5.5 0 0 0 0 .707l.864.864a.5.5 0 0 0 .707 0L12 13.571l5.932 5.932a.5.5 0 0 0 .707 0l.864-.864a.5.5 0 0 0 0-.707L13.571 12l5.932-5.932a.5.5 0 0 0 0-.707l-.864-.864a.5.5 0 0 0-.707 0L12 10.429 6.068 4.497a.5.5 0 0 0-.707 0l-.864.864Z",fill:"currentColor"})}),w8=e=>O.jsx("svg",{width:"1em",height:"1em",viewBox:"0 0 24 24",...e,children:O.jsx("path",{d:"M11.701 18.797c.206.195.52.195.726 0l2.487-2.349-.008-.007 6.973-6.585a.58.58 0 0 0 0-.835l-2.045-1.932a.524.524 0 0 0-.726 0l-7.052 6.66-7.051-6.66a.524.524 0 0 0-.726 0L2.234 9.021a.58.58 0 0 0 0 .835l9.467 8.941Z",fill:"currentColor"})}),_8=e=>O.jsx("svg",{width:"1em",height:"1em",viewBox:"0 0 24 24",...e,children:O.jsx("path",{d:"M20.673 5.133c.136.24.053.55-.185.69l-16.25 9.623a.487.487 0 0 1-.676-.18l-.497-.884a.513.513 0 0 1 .185-.69L19.5 4.069c.238-.141.54-.06.676.18l.497.884ZM20.938 9.657c.136.24.053.55-.185.69L7.925 17.944a.487.487 0 0 1-.676-.181l-.497-.884a.513.513 0 0 1 .185-.69l12.829-7.597c.237-.14.54-.06.675.181l.497.884ZM20.16 15.376c.237-.14.32-.45.184-.69l-.497-.884a.487.487 0 0 0-.676-.18l-7.695 4.556a.513.513 0 0 0-.185.69l.498.884c.135.24.437.322.675.181l7.695-4.557Z",fill:"currentColor"})}),E8=(e,t)=>{const r=new Array(e.length+t.length);for(let n=0;n<e.length;n++)r[n]=e[n];for(let n=0;n<t.length;n++)r[e.length+n]=t[n];return r},S8=(e,t)=>({classGroupId:e,validator:t}),ML=(e=new Map,t=null,r)=>({nextPart:e,validators:t,classGroupId:r}),Hu="-",tC=[],O8="arbitrary..",C8=e=>{const t=N8(e),{conflictingClassGroups:r,conflictingClassGroupModifiers:n}=e;return{getClassGroupId:o=>{if(o.startsWith("[")&&o.endsWith("]"))return R8(o);const i=o.split(Hu),a=i[0]===""&&i.length>1?1:0;return jL(i,a,t)},getConflictingClassGroupIds:(o,i)=>{if(i){const a=n[o],s=r[o];return a?s?E8(s,a):a:s||tC}return r[o]||tC}}},jL=(e,t,r)=>{if(e.length-t===0)return r.classGroupId;const n=e[t],o=r.nextPart.get(n);if(o){const c=jL(e,t+1,o);if(c)return c}const i=r.validators;if(i===null)return;const a=t===0?e.join(Hu):e.slice(t).join(Hu),s=i.length;for(let c=0;c<s;c++){const u=i[c];if(u.validator(a))return u.classGroupId}},R8=e=>e.slice(1,-1).indexOf(":")===-1?void 0:(()=>{const t=e.slice(1,-1),r=t.indexOf(":"),n=t.slice(0,r);return n?O8+n:void 0})(),N8=e=>{const{theme:t,classGroups:r}=e;return I8(r,t)},I8=(e,t)=>{const r=ML();for(const n in e){const o=e[n];U_(o,r,n,t)}return r},U_=(e,t,r,n)=>{const o=e.length;for(let i=0;i<o;i++){const a=e[i];P8(a,t,r,n)}},P8=(e,t,r,n)=>{if(typeof e=="string"){T8(e,t,r);return}if(typeof e=="function"){A8(e,t,r,n);return}k8(e,t,r,n)},T8=(e,t,r)=>{const n=e===""?t:LL(t,e);n.classGroupId=r},A8=(e,t,r,n)=>{if(D8(e)){U_(e(n),t,r,n);return}t.validators===null&&(t.validators=[]),t.validators.push(S8(r,e))},k8=(e,t,r,n)=>{const o=Object.entries(e),i=o.length;for(let a=0;a<i;a++){const[s,c]=o[a];U_(c,LL(t,s),r,n)}},LL=(e,t)=>{let r=e;const n=t.split(Hu),o=n.length;for(let i=0;i<o;i++){const a=n[i];let s=r.nextPart.get(a);s||(s=ML(),r.nextPart.set(a,s)),r=s}return r},D8=e=>"isThemeGetter"in e&&e.isThemeGetter===!0,M8=e=>{if(e<1)return{get:()=>{},set:()=>{}};let t=0,r=Object.create(null),n=Object.create(null);const o=(i,a)=>{r[i]=a,t++,t>e&&(t=0,n=r,r=Object.create(null))};return{get(i){let a=r[i];if(a!==void 0)return a;if((a=n[i])!==void 0)return o(i,a),a},set(i,a){i in r?r[i]=a:o(i,a)}}},o_="!",rC=":",j8=[],nC=(e,t,r,n,o)=>({modifiers:e,hasImportantModifier:t,baseClassName:r,maybePostfixModifierPosition:n,isExternal:o}),L8=e=>{const{prefix:t,experimentalParseClassName:r}=e;let n=o=>{const i=[];let a=0,s=0,c=0,u;const d=o.length;for(let g=0;g<d;g++){const m=o[g];if(a===0&&s===0){if(m===rC){i.push(o.slice(c,g)),c=g+1;continue}if(m==="/"){u=g;continue}}m==="["?a++:m==="]"?a--:m==="("?s++:m===")"&&s--}const f=i.length===0?o:o.slice(c);let h=f,v=!1;f.endsWith(o_)?(h=f.slice(0,-1),v=!0):f.startsWith(o_)&&(h=f.slice(1),v=!0);const b=u&&u>c?u-c:void 0;return nC(i,v,h,b)};if(t){const o=t+rC,i=n;n=a=>a.startsWith(o)?i(a.slice(o.length)):nC(j8,!1,a,void 0,!0)}if(r){const o=n;n=i=>r({className:i,parseClassName:o})}return n},q8=e=>{const t=new Map;return e.orderSensitiveModifiers.forEach((r,n)=>{t.set(r,1e6+n)}),r=>{const n=[];let o=[];for(let i=0;i<r.length;i++){const a=r[i],s=a[0]==="[",c=t.has(a);s||c?(o.length>0&&(o.sort(),n.push(...o),o=[]),n.push(a)):o.push(a)}return o.length>0&&(o.sort(),n.push(...o)),n}},z8=e=>({cache:M8(e.cacheSize),parseClassName:L8(e),sortModifiers:q8(e),...C8(e)}),B8=/\s+/,F8=(e,t)=>{const{parseClassName:r,getClassGroupId:n,getConflictingClassGroupIds:o,sortModifiers:i}=t,a=[],s=e.trim().split(B8);let c="";for(let u=s.length-1;u>=0;u-=1){const d=s[u],{isExternal:f,modifiers:h,hasImportantModifier:v,baseClassName:b,maybePostfixModifierPosition:g}=r(d);if(f){c=d+(c.length>0?" "+c:c);continue}let m=!!g,x=n(m?b.substring(0,g):b);if(!x){if(!m){c=d+(c.length>0?" "+c:c);continue}if(x=n(b),!x){c=d+(c.length>0?" "+c:c);continue}m=!1}const w=h.length===0?"":h.length===1?h[0]:i(h).join(":"),E=v?w+o_:w,S=E+x;if(a.indexOf(S)>-1)continue;a.push(S);const _=o(x,m);for(let C=0;C<_.length;++C){const N=_[C];a.push(E+N)}c=d+(c.length>0?" "+c:c)}return c},$8=(...e)=>{let t=0,r,n,o="";for(;t<e.length;)(r=e[t++])&&(n=qL(r))&&(o&&(o+=" "),o+=n);return o},qL=e=>{if(typeof e=="string")return e;let t,r="";for(let n=0;n<e.length;n++)e[n]&&(t=qL(e[n]))&&(r&&(r+=" "),r+=t);return r},oC=(e,...t)=>{let r,n,o,i;const a=c=>{const u=t.reduce((d,f)=>f(d),e());return r=z8(u),n=r.cache.get,o=r.cache.set,i=s,s(c)},s=c=>{const u=n(c);if(u)return u;const d=F8(c,r);return o(c,d),d};return i=a,(...c)=>i($8(...c))},V8=[],Ut=e=>{const t=r=>r[e]||V8;return t.isThemeGetter=!0,t},zL=/^\[(?:(\w[\w-]*):)?(.+)\]$/i,BL=/^\((?:(\w[\w-]*):)?(.+)\)$/i,H8=/^\d+\/\d+$/,W8=/^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/,U8=/\d+(%|px|r?em|[sdl]?v([hwib]|min|max)|pt|pc|in|cm|mm|cap|ch|ex|r?lh|cq(w|h|i|b|min|max))|\b(calc|min|max|clamp)\(.+\)|^0$/,G8=/^(rgba?|hsla?|hwb|(ok)?(lab|lch)|color-mix)\(.+\)$/,Y8=/^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/,K8=/^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/,Qi=e=>H8.test(e),He=e=>!!e&&!Number.isNaN(Number(e)),jo=e=>!!e&&Number.isInteger(Number(e)),sh=e=>e.endsWith("%")&&He(e.slice(0,-1)),ho=e=>W8.test(e),X8=()=>!0,Z8=e=>U8.test(e)&&!G8.test(e),FL=()=>!1,J8=e=>Y8.test(e),Q8=e=>K8.test(e),eG=e=>!Ie(e)&&!Pe(e),tG=e=>Ta(e,HL,FL),Ie=e=>zL.test(e),fi=e=>Ta(e,WL,Z8),lh=e=>Ta(e,aG,He),iC=e=>Ta(e,$L,FL),rG=e=>Ta(e,VL,Q8),qc=e=>Ta(e,UL,J8),Pe=e=>BL.test(e),hs=e=>Aa(e,WL),nG=e=>Aa(e,sG),aC=e=>Aa(e,$L),oG=e=>Aa(e,HL),iG=e=>Aa(e,VL),zc=e=>Aa(e,UL,!0),Ta=(e,t,r)=>{const n=zL.exec(e);return n?n[1]?t(n[1]):r(n[2]):!1},Aa=(e,t,r=!1)=>{const n=BL.exec(e);return n?n[1]?t(n[1]):r:!1},$L=e=>e==="position"||e==="percentage",VL=e=>e==="image"||e==="url",HL=e=>e==="length"||e==="size"||e==="bg-size",WL=e=>e==="length",aG=e=>e==="number",sG=e=>e==="family-name",UL=e=>e==="shadow",sC=()=>{const e=Ut("color"),t=Ut("font"),r=Ut("text"),n=Ut("font-weight"),o=Ut("tracking"),i=Ut("leading"),a=Ut("breakpoint"),s=Ut("container"),c=Ut("spacing"),u=Ut("radius"),d=Ut("shadow"),f=Ut("inset-shadow"),h=Ut("text-shadow"),v=Ut("drop-shadow"),b=Ut("blur"),g=Ut("perspective"),m=Ut("aspect"),x=Ut("ease"),w=Ut("animate"),E=()=>["auto","avoid","all","avoid-page","page","left","right","column"],S=()=>["center","top","bottom","left","right","top-left","left-top","top-right","right-top","bottom-right","right-bottom","bottom-left","left-bottom"],_=()=>[...S(),Pe,Ie],C=()=>["auto","hidden","clip","visible","scroll"],N=()=>["auto","contain","none"],P=()=>[Pe,Ie,c],A=()=>[Qi,"full","auto",...P()],j=()=>[jo,"none","subgrid",Pe,Ie],M=()=>["auto",{span:["full",jo,Pe,Ie]},jo,Pe,Ie],L=()=>[jo,"auto",Pe,Ie],D=()=>["auto","min","max","fr",Pe,Ie],T=()=>["start","end","center","between","around","evenly","stretch","baseline","center-safe","end-safe"],W=()=>["start","end","center","stretch","center-safe","end-safe"],q=()=>["auto",...P()],G=()=>[Qi,"auto","full","dvw","dvh","lvw","lvh","svw","svh","min","max","fit",...P()],F=()=>[e,Pe,Ie],J=()=>[...S(),aC,iC,{position:[Pe,Ie]}],z=()=>["no-repeat",{repeat:["","x","y","space","round"]}],U=()=>["auto","cover","contain",oG,tG,{size:[Pe,Ie]}],oe=()=>[sh,hs,fi],re=()=>["","none","full",u,Pe,Ie],$=()=>["",He,hs,fi],Y=()=>["solid","dashed","dotted","double"],X=()=>["normal","multiply","screen","overlay","darken","lighten","color-dodge","color-burn","hard-light","soft-light","difference","exclusion","hue","saturation","color","luminosity"],H=()=>[He,sh,aC,iC],K=()=>["","none",b,Pe,Ie],Q=()=>["none",He,Pe,Ie],ne=()=>["none",He,Pe,Ie],se=()=>[He,Pe,Ie],te=()=>[Qi,"full",...P()];return{cacheSize:500,theme:{animate:["spin","ping","pulse","bounce"],aspect:["video"],blur:[ho],breakpoint:[ho],color:[X8],container:[ho],"drop-shadow":[ho],ease:["in","out","in-out"],font:[eG],"font-weight":["thin","extralight","light","normal","medium","semibold","bold","extrabold","black"],"inset-shadow":[ho],leading:["none","tight","snug","normal","relaxed","loose"],perspective:["dramatic","near","normal","midrange","distant","none"],radius:[ho],shadow:[ho],spacing:["px",He],text:[ho],"text-shadow":[ho],tracking:["tighter","tight","normal","wide","wider","widest"]},classGroups:{aspect:[{aspect:["auto","square",Qi,Ie,Pe,m]}],container:["container"],columns:[{columns:[He,Ie,Pe,s]}],"break-after":[{"break-after":E()}],"break-before":[{"break-before":E()}],"break-inside":[{"break-inside":["auto","avoid","avoid-page","avoid-column"]}],"box-decoration":[{"box-decoration":["slice","clone"]}],box:[{box:["border","content"]}],display:["block","inline-block","inline","flex","inline-flex","table","inline-table","table-caption","table-cell","table-column","table-column-group","table-footer-group","table-header-group","table-row-group","table-row","flow-root","grid","inline-grid","contents","list-item","hidden"],sr:["sr-only","not-sr-only"],float:[{float:["right","left","none","start","end"]}],clear:[{clear:["left","right","both","none","start","end"]}],isolation:["isolate","isolation-auto"],"object-fit":[{object:["contain","cover","fill","none","scale-down"]}],"object-position":[{object:_()}],overflow:[{overflow:C()}],"overflow-x":[{"overflow-x":C()}],"overflow-y":[{"overflow-y":C()}],overscroll:[{overscroll:N()}],"overscroll-x":[{"overscroll-x":N()}],"overscroll-y":[{"overscroll-y":N()}],position:["static","fixed","absolute","relative","sticky"],inset:[{inset:A()}],"inset-x":[{"inset-x":A()}],"inset-y":[{"inset-y":A()}],start:[{start:A()}],end:[{end:A()}],top:[{top:A()}],right:[{right:A()}],bottom:[{bottom:A()}],left:[{left:A()}],visibility:["visible","invisible","collapse"],z:[{z:[jo,"auto",Pe,Ie]}],basis:[{basis:[Qi,"full","auto",s,...P()]}],"flex-direction":[{flex:["row","row-reverse","col","col-reverse"]}],"flex-wrap":[{flex:["nowrap","wrap","wrap-reverse"]}],flex:[{flex:[He,Qi,"auto","initial","none",Ie]}],grow:[{grow:["",He,Pe,Ie]}],shrink:[{shrink:["",He,Pe,Ie]}],order:[{order:[jo,"first","last","none",Pe,Ie]}],"grid-cols":[{"grid-cols":j()}],"col-start-end":[{col:M()}],"col-start":[{"col-start":L()}],"col-end":[{"col-end":L()}],"grid-rows":[{"grid-rows":j()}],"row-start-end":[{row:M()}],"row-start":[{"row-start":L()}],"row-end":[{"row-end":L()}],"grid-flow":[{"grid-flow":["row","col","dense","row-dense","col-dense"]}],"auto-cols":[{"auto-cols":D()}],"auto-rows":[{"auto-rows":D()}],gap:[{gap:P()}],"gap-x":[{"gap-x":P()}],"gap-y":[{"gap-y":P()}],"justify-content":[{justify:[...T(),"normal"]}],"justify-items":[{"justify-items":[...W(),"normal"]}],"justify-self":[{"justify-self":["auto",...W()]}],"align-content":[{content:["normal",...T()]}],"align-items":[{items:[...W(),{baseline:["","last"]}]}],"align-self":[{self:["auto",...W(),{baseline:["","last"]}]}],"place-content":[{"place-content":T()}],"place-items":[{"place-items":[...W(),"baseline"]}],"place-self":[{"place-self":["auto",...W()]}],p:[{p:P()}],px:[{px:P()}],py:[{py:P()}],ps:[{ps:P()}],pe:[{pe:P()}],pt:[{pt:P()}],pr:[{pr:P()}],pb:[{pb:P()}],pl:[{pl:P()}],m:[{m:q()}],mx:[{mx:q()}],my:[{my:q()}],ms:[{ms:q()}],me:[{me:q()}],mt:[{mt:q()}],mr:[{mr:q()}],mb:[{mb:q()}],ml:[{ml:q()}],"space-x":[{"space-x":P()}],"space-x-reverse":["space-x-reverse"],"space-y":[{"space-y":P()}],"space-y-reverse":["space-y-reverse"],size:[{size:G()}],w:[{w:[s,"screen",...G()]}],"min-w":[{"min-w":[s,"screen","none",...G()]}],"max-w":[{"max-w":[s,"screen","none","prose",{screen:[a]},...G()]}],h:[{h:["screen","lh",...G()]}],"min-h":[{"min-h":["screen","lh","none",...G()]}],"max-h":[{"max-h":["screen","lh",...G()]}],"font-size":[{text:["base",r,hs,fi]}],"font-smoothing":["antialiased","subpixel-antialiased"],"font-style":["italic","not-italic"],"font-weight":[{font:[n,Pe,lh]}],"font-stretch":[{"font-stretch":["ultra-condensed","extra-condensed","condensed","semi-condensed","normal","semi-expanded","expanded","extra-expanded","ultra-expanded",sh,Ie]}],"font-family":[{font:[nG,Ie,t]}],"fvn-normal":["normal-nums"],"fvn-ordinal":["ordinal"],"fvn-slashed-zero":["slashed-zero"],"fvn-figure":["lining-nums","oldstyle-nums"],"fvn-spacing":["proportional-nums","tabular-nums"],"fvn-fraction":["diagonal-fractions","stacked-fractions"],tracking:[{tracking:[o,Pe,Ie]}],"line-clamp":[{"line-clamp":[He,"none",Pe,lh]}],leading:[{leading:[i,...P()]}],"list-image":[{"list-image":["none",Pe,Ie]}],"list-style-position":[{list:["inside","outside"]}],"list-style-type":[{list:["disc","decimal","none",Pe,Ie]}],"text-alignment":[{text:["left","center","right","justify","start","end"]}],"placeholder-color":[{placeholder:F()}],"text-color":[{text:F()}],"text-decoration":["underline","overline","line-through","no-underline"],"text-decoration-style":[{decoration:[...Y(),"wavy"]}],"text-decoration-thickness":[{decoration:[He,"from-font","auto",Pe,fi]}],"text-decoration-color":[{decoration:F()}],"underline-offset":[{"underline-offset":[He,"auto",Pe,Ie]}],"text-transform":["uppercase","lowercase","capitalize","normal-case"],"text-overflow":["truncate","text-ellipsis","text-clip"],"text-wrap":[{text:["wrap","nowrap","balance","pretty"]}],indent:[{indent:P()}],"vertical-align":[{align:["baseline","top","middle","bottom","text-top","text-bottom","sub","super",Pe,Ie]}],whitespace:[{whitespace:["normal","nowrap","pre","pre-line","pre-wrap","break-spaces"]}],break:[{break:["normal","words","all","keep"]}],wrap:[{wrap:["break-word","anywhere","normal"]}],hyphens:[{hyphens:["none","manual","auto"]}],content:[{content:["none",Pe,Ie]}],"bg-attachment":[{bg:["fixed","local","scroll"]}],"bg-clip":[{"bg-clip":["border","padding","content","text"]}],"bg-origin":[{"bg-origin":["border","padding","content"]}],"bg-position":[{bg:J()}],"bg-repeat":[{bg:z()}],"bg-size":[{bg:U()}],"bg-image":[{bg:["none",{linear:[{to:["t","tr","r","br","b","bl","l","tl"]},jo,Pe,Ie],radial:["",Pe,Ie],conic:[jo,Pe,Ie]},iG,rG]}],"bg-color":[{bg:F()}],"gradient-from-pos":[{from:oe()}],"gradient-via-pos":[{via:oe()}],"gradient-to-pos":[{to:oe()}],"gradient-from":[{from:F()}],"gradient-via":[{via:F()}],"gradient-to":[{to:F()}],rounded:[{rounded:re()}],"rounded-s":[{"rounded-s":re()}],"rounded-e":[{"rounded-e":re()}],"rounded-t":[{"rounded-t":re()}],"rounded-r":[{"rounded-r":re()}],"rounded-b":[{"rounded-b":re()}],"rounded-l":[{"rounded-l":re()}],"rounded-ss":[{"rounded-ss":re()}],"rounded-se":[{"rounded-se":re()}],"rounded-ee":[{"rounded-ee":re()}],"rounded-es":[{"rounded-es":re()}],"rounded-tl":[{"rounded-tl":re()}],"rounded-tr":[{"rounded-tr":re()}],"rounded-br":[{"rounded-br":re()}],"rounded-bl":[{"rounded-bl":re()}],"border-w":[{border:$()}],"border-w-x":[{"border-x":$()}],"border-w-y":[{"border-y":$()}],"border-w-s":[{"border-s":$()}],"border-w-e":[{"border-e":$()}],"border-w-t":[{"border-t":$()}],"border-w-r":[{"border-r":$()}],"border-w-b":[{"border-b":$()}],"border-w-l":[{"border-l":$()}],"divide-x":[{"divide-x":$()}],"divide-x-reverse":["divide-x-reverse"],"divide-y":[{"divide-y":$()}],"divide-y-reverse":["divide-y-reverse"],"border-style":[{border:[...Y(),"hidden","none"]}],"divide-style":[{divide:[...Y(),"hidden","none"]}],"border-color":[{border:F()}],"border-color-x":[{"border-x":F()}],"border-color-y":[{"border-y":F()}],"border-color-s":[{"border-s":F()}],"border-color-e":[{"border-e":F()}],"border-color-t":[{"border-t":F()}],"border-color-r":[{"border-r":F()}],"border-color-b":[{"border-b":F()}],"border-color-l":[{"border-l":F()}],"divide-color":[{divide:F()}],"outline-style":[{outline:[...Y(),"none","hidden"]}],"outline-offset":[{"outline-offset":[He,Pe,Ie]}],"outline-w":[{outline:["",He,hs,fi]}],"outline-color":[{outline:F()}],shadow:[{shadow:["","none",d,zc,qc]}],"shadow-color":[{shadow:F()}],"inset-shadow":[{"inset-shadow":["none",f,zc,qc]}],"inset-shadow-color":[{"inset-shadow":F()}],"ring-w":[{ring:$()}],"ring-w-inset":["ring-inset"],"ring-color":[{ring:F()}],"ring-offset-w":[{"ring-offset":[He,fi]}],"ring-offset-color":[{"ring-offset":F()}],"inset-ring-w":[{"inset-ring":$()}],"inset-ring-color":[{"inset-ring":F()}],"text-shadow":[{"text-shadow":["none",h,zc,qc]}],"text-shadow-color":[{"text-shadow":F()}],opacity:[{opacity:[He,Pe,Ie]}],"mix-blend":[{"mix-blend":[...X(),"plus-darker","plus-lighter"]}],"bg-blend":[{"bg-blend":X()}],"mask-clip":[{"mask-clip":["border","padding","content","fill","stroke","view"]},"mask-no-clip"],"mask-composite":[{mask:["add","subtract","intersect","exclude"]}],"mask-image-linear-pos":[{"mask-linear":[He]}],"mask-image-linear-from-pos":[{"mask-linear-from":H()}],"mask-image-linear-to-pos":[{"mask-linear-to":H()}],"mask-image-linear-from-color":[{"mask-linear-from":F()}],"mask-image-linear-to-color":[{"mask-linear-to":F()}],"mask-image-t-from-pos":[{"mask-t-from":H()}],"mask-image-t-to-pos":[{"mask-t-to":H()}],"mask-image-t-from-color":[{"mask-t-from":F()}],"mask-image-t-to-color":[{"mask-t-to":F()}],"mask-image-r-from-pos":[{"mask-r-from":H()}],"mask-image-r-to-pos":[{"mask-r-to":H()}],"mask-image-r-from-color":[{"mask-r-from":F()}],"mask-image-r-to-color":[{"mask-r-to":F()}],"mask-image-b-from-pos":[{"mask-b-from":H()}],"mask-image-b-to-pos":[{"mask-b-to":H()}],"mask-image-b-from-color":[{"mask-b-from":F()}],"mask-image-b-to-color":[{"mask-b-to":F()}],"mask-image-l-from-pos":[{"mask-l-from":H()}],"mask-image-l-to-pos":[{"mask-l-to":H()}],"mask-image-l-from-color":[{"mask-l-from":F()}],"mask-image-l-to-color":[{"mask-l-to":F()}],"mask-image-x-from-pos":[{"mask-x-from":H()}],"mask-image-x-to-pos":[{"mask-x-to":H()}],"mask-image-x-from-color":[{"mask-x-from":F()}],"mask-image-x-to-color":[{"mask-x-to":F()}],"mask-image-y-from-pos":[{"mask-y-from":H()}],"mask-image-y-to-pos":[{"mask-y-to":H()}],"mask-image-y-from-color":[{"mask-y-from":F()}],"mask-image-y-to-color":[{"mask-y-to":F()}],"mask-image-radial":[{"mask-radial":[Pe,Ie]}],"mask-image-radial-from-pos":[{"mask-radial-from":H()}],"mask-image-radial-to-pos":[{"mask-radial-to":H()}],"mask-image-radial-from-color":[{"mask-radial-from":F()}],"mask-image-radial-to-color":[{"mask-radial-to":F()}],"mask-image-radial-shape":[{"mask-radial":["circle","ellipse"]}],"mask-image-radial-size":[{"mask-radial":[{closest:["side","corner"],farthest:["side","corner"]}]}],"mask-image-radial-pos":[{"mask-radial-at":S()}],"mask-image-conic-pos":[{"mask-conic":[He]}],"mask-image-conic-from-pos":[{"mask-conic-from":H()}],"mask-image-conic-to-pos":[{"mask-conic-to":H()}],"mask-image-conic-from-color":[{"mask-conic-from":F()}],"mask-image-conic-to-color":[{"mask-conic-to":F()}],"mask-mode":[{mask:["alpha","luminance","match"]}],"mask-origin":[{"mask-origin":["border","padding","content","fill","stroke","view"]}],"mask-position":[{mask:J()}],"mask-repeat":[{mask:z()}],"mask-size":[{mask:U()}],"mask-type":[{"mask-type":["alpha","luminance"]}],"mask-image":[{mask:["none",Pe,Ie]}],filter:[{filter:["","none",Pe,Ie]}],blur:[{blur:K()}],brightness:[{brightness:[He,Pe,Ie]}],contrast:[{contrast:[He,Pe,Ie]}],"drop-shadow":[{"drop-shadow":["","none",v,zc,qc]}],"drop-shadow-color":[{"drop-shadow":F()}],grayscale:[{grayscale:["",He,Pe,Ie]}],"hue-rotate":[{"hue-rotate":[He,Pe,Ie]}],invert:[{invert:["",He,Pe,Ie]}],saturate:[{saturate:[He,Pe,Ie]}],sepia:[{sepia:["",He,Pe,Ie]}],"backdrop-filter":[{"backdrop-filter":["","none",Pe,Ie]}],"backdrop-blur":[{"backdrop-blur":K()}],"backdrop-brightness":[{"backdrop-brightness":[He,Pe,Ie]}],"backdrop-contrast":[{"backdrop-contrast":[He,Pe,Ie]}],"backdrop-grayscale":[{"backdrop-grayscale":["",He,Pe,Ie]}],"backdrop-hue-rotate":[{"backdrop-hue-rotate":[He,Pe,Ie]}],"backdrop-invert":[{"backdrop-invert":["",He,Pe,Ie]}],"backdrop-opacity":[{"backdrop-opacity":[He,Pe,Ie]}],"backdrop-saturate":[{"backdrop-saturate":[He,Pe,Ie]}],"backdrop-sepia":[{"backdrop-sepia":["",He,Pe,Ie]}],"border-collapse":[{border:["collapse","separate"]}],"border-spacing":[{"border-spacing":P()}],"border-spacing-x":[{"border-spacing-x":P()}],"border-spacing-y":[{"border-spacing-y":P()}],"table-layout":[{table:["auto","fixed"]}],caption:[{caption:["top","bottom"]}],transition:[{transition:["","all","colors","opacity","shadow","transform","none",Pe,Ie]}],"transition-behavior":[{transition:["normal","discrete"]}],duration:[{duration:[He,"initial",Pe,Ie]}],ease:[{ease:["linear","initial",x,Pe,Ie]}],delay:[{delay:[He,Pe,Ie]}],animate:[{animate:["none",w,Pe,Ie]}],backface:[{backface:["hidden","visible"]}],perspective:[{perspective:[g,Pe,Ie]}],"perspective-origin":[{"perspective-origin":_()}],rotate:[{rotate:Q()}],"rotate-x":[{"rotate-x":Q()}],"rotate-y":[{"rotate-y":Q()}],"rotate-z":[{"rotate-z":Q()}],scale:[{scale:ne()}],"scale-x":[{"scale-x":ne()}],"scale-y":[{"scale-y":ne()}],"scale-z":[{"scale-z":ne()}],"scale-3d":["scale-3d"],skew:[{skew:se()}],"skew-x":[{"skew-x":se()}],"skew-y":[{"skew-y":se()}],transform:[{transform:[Pe,Ie,"","none","gpu","cpu"]}],"transform-origin":[{origin:_()}],"transform-style":[{transform:["3d","flat"]}],translate:[{translate:te()}],"translate-x":[{"translate-x":te()}],"translate-y":[{"translate-y":te()}],"translate-z":[{"translate-z":te()}],"translate-none":["translate-none"],accent:[{accent:F()}],appearance:[{appearance:["none","auto"]}],"caret-color":[{caret:F()}],"color-scheme":[{scheme:["normal","dark","light","light-dark","only-dark","only-light"]}],cursor:[{cursor:["auto","default","pointer","wait","text","move","help","not-allowed","none","context-menu","progress","cell","crosshair","vertical-text","alias","copy","no-drop","grab","grabbing","all-scroll","col-resize","row-resize","n-resize","e-resize","s-resize","w-resize","ne-resize","nw-resize","se-resize","sw-resize","ew-resize","ns-resize","nesw-resize","nwse-resize","zoom-in","zoom-out",Pe,Ie]}],"field-sizing":[{"field-sizing":["fixed","content"]}],"pointer-events":[{"pointer-events":["auto","none"]}],resize:[{resize:["none","","y","x"]}],"scroll-behavior":[{scroll:["auto","smooth"]}],"scroll-m":[{"scroll-m":P()}],"scroll-mx":[{"scroll-mx":P()}],"scroll-my":[{"scroll-my":P()}],"scroll-ms":[{"scroll-ms":P()}],"scroll-me":[{"scroll-me":P()}],"scroll-mt":[{"scroll-mt":P()}],"scroll-mr":[{"scroll-mr":P()}],"scroll-mb":[{"scroll-mb":P()}],"scroll-ml":[{"scroll-ml":P()}],"scroll-p":[{"scroll-p":P()}],"scroll-px":[{"scroll-px":P()}],"scroll-py":[{"scroll-py":P()}],"scroll-ps":[{"scroll-ps":P()}],"scroll-pe":[{"scroll-pe":P()}],"scroll-pt":[{"scroll-pt":P()}],"scroll-pr":[{"scroll-pr":P()}],"scroll-pb":[{"scroll-pb":P()}],"scroll-pl":[{"scroll-pl":P()}],"snap-align":[{snap:["start","end","center","align-none"]}],"snap-stop":[{snap:["normal","always"]}],"snap-type":[{snap:["none","x","y","both"]}],"snap-strictness":[{snap:["mandatory","proximity"]}],touch:[{touch:["auto","none","manipulation"]}],"touch-x":[{"touch-pan":["x","left","right"]}],"touch-y":[{"touch-pan":["y","up","down"]}],"touch-pz":["touch-pinch-zoom"],select:[{select:["none","text","all","auto"]}],"will-change":[{"will-change":["auto","scroll","contents","transform",Pe,Ie]}],fill:[{fill:["none",...F()]}],"stroke-w":[{stroke:[He,hs,fi,lh]}],stroke:[{stroke:["none",...F()]}],"forced-color-adjust":[{"forced-color-adjust":["auto","none"]}]},conflictingClassGroups:{overflow:["overflow-x","overflow-y"],overscroll:["overscroll-x","overscroll-y"],inset:["inset-x","inset-y","start","end","top","right","bottom","left"],"inset-x":["right","left"],"inset-y":["top","bottom"],flex:["basis","grow","shrink"],gap:["gap-x","gap-y"],p:["px","py","ps","pe","pt","pr","pb","pl"],px:["pr","pl"],py:["pt","pb"],m:["mx","my","ms","me","mt","mr","mb","ml"],mx:["mr","ml"],my:["mt","mb"],size:["w","h"],"font-size":["leading"],"fvn-normal":["fvn-ordinal","fvn-slashed-zero","fvn-figure","fvn-spacing","fvn-fraction"],"fvn-ordinal":["fvn-normal"],"fvn-slashed-zero":["fvn-normal"],"fvn-figure":["fvn-normal"],"fvn-spacing":["fvn-normal"],"fvn-fraction":["fvn-normal"],"line-clamp":["display","overflow"],rounded:["rounded-s","rounded-e","rounded-t","rounded-r","rounded-b","rounded-l","rounded-ss","rounded-se","rounded-ee","rounded-es","rounded-tl","rounded-tr","rounded-br","rounded-bl"],"rounded-s":["rounded-ss","rounded-es"],"rounded-e":["rounded-se","rounded-ee"],"rounded-t":["rounded-tl","rounded-tr"],"rounded-r":["rounded-tr","rounded-br"],"rounded-b":["rounded-br","rounded-bl"],"rounded-l":["rounded-tl","rounded-bl"],"border-spacing":["border-spacing-x","border-spacing-y"],"border-w":["border-w-x","border-w-y","border-w-s","border-w-e","border-w-t","border-w-r","border-w-b","border-w-l"],"border-w-x":["border-w-r","border-w-l"],"border-w-y":["border-w-t","border-w-b"],"border-color":["border-color-x","border-color-y","border-color-s","border-color-e","border-color-t","border-color-r","border-color-b","border-color-l"],"border-color-x":["border-color-r","border-color-l"],"border-color-y":["border-color-t","border-color-b"],translate:["translate-x","translate-y","translate-none"],"translate-none":["translate","translate-x","translate-y","translate-z"],"scroll-m":["scroll-mx","scroll-my","scroll-ms","scroll-me","scroll-mt","scroll-mr","scroll-mb","scroll-ml"],"scroll-mx":["scroll-mr","scroll-ml"],"scroll-my":["scroll-mt","scroll-mb"],"scroll-p":["scroll-px","scroll-py","scroll-ps","scroll-pe","scroll-pt","scroll-pr","scroll-pb","scroll-pl"],"scroll-px":["scroll-pr","scroll-pl"],"scroll-py":["scroll-pt","scroll-pb"],touch:["touch-x","touch-y","touch-pz"],"touch-x":["touch"],"touch-y":["touch"],"touch-pz":["touch"]},conflictingClassGroupModifiers:{"font-size":["leading"]},orderSensitiveModifiers:["*","**","after","backdrop","before","details-content","file","first-letter","first-line","marker","placeholder","selection"]}},lG=(e,{cacheSize:t,prefix:r,experimentalParseClassName:n,extend:o={},override:i={}})=>(zs(e,"cacheSize",t),zs(e,"prefix",r),zs(e,"experimentalParseClassName",n),Bc(e.theme,i.theme),Bc(e.classGroups,i.classGroups),Bc(e.conflictingClassGroups,i.conflictingClassGroups),Bc(e.conflictingClassGroupModifiers,i.conflictingClassGroupModifiers),zs(e,"orderSensitiveModifiers",i.orderSensitiveModifiers),Fc(e.theme,o.theme),Fc(e.classGroups,o.classGroups),Fc(e.conflictingClassGroups,o.conflictingClassGroups),Fc(e.conflictingClassGroupModifiers,o.conflictingClassGroupModifiers),GL(e,o,"orderSensitiveModifiers"),e),zs=(e,t,r)=>{r!==void 0&&(e[t]=r)},Bc=(e,t)=>{if(t)for(const r in t)zs(e,r,t[r])},Fc=(e,t)=>{if(t)for(const r in t)GL(e,t,r)},GL=(e,t,r)=>{const n=t[r];n!==void 0&&(e[r]=e[r]?e[r].concat(n):n)},cG=(e,...t)=>typeof e=="function"?oC(sC,e,...t):oC(()=>lG(sC(),e),...t);function YL(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var lC={exports:{}};/*!
|
|
2
3
|
Copyright (c) 2018 Jed Watson.
|
|
3
4
|
Licensed under the MIT License (MIT), see
|
|
4
5
|
http://jedwatson.github.io/classnames
|
|
5
|
-
*/var L1;function Yz(){return L1||(L1=1,(function(e){(function(){var t={}.hasOwnProperty;function r(){for(var o="",a=0;a<arguments.length;a++){var u=arguments[a];u&&(o=i(o,n(u)))}return o}function n(o){if(typeof o=="string"||typeof o=="number")return o;if(typeof o!="object")return"";if(Array.isArray(o))return r.apply(null,o);if(o.toString!==Object.prototype.toString&&!o.toString.toString().includes("[native code]"))return o.toString();var a="";for(var u in o)t.call(o,u)&&o[u]&&(a=i(a,u));return a}function i(o,a){return a?o?o+" "+a:o+a:o}e.exports?(r.default=r,e.exports=r):window.classNames=r})()})(Wf)),Wf.exports}var Xz=Yz();const Ve=Un(Xz);function Zz({qodly:e,activeTab:t,forceLogin:r,onTabChange:n,restrictedByDefault:i,onRestrictedByDefaultChange:o,onForceLoginChange:a}){return C.jsx(C.Fragment,{children:C.jsx("nav",{className:"relative mb-0 flex h-auto flex-wrap items-center justify-between border-b border-grey-900 bg-grey-800 px-4 py-3",children:C.jsx("div",{className:"flex w-full flex-wrap items-center justify-between",children:C.jsxs("div",{className:"relative flex w-full justify-between",children:[C.jsx("span",{className:"inline-block whitespace-nowrap text-sm leading-relaxed text-white",children:C.jsxs("div",{className:"flex items-center justify-center",children:[C.jsx("button",{"data-cy":"roles_btn_navbar",className:Ve(" min-w-[110px] rounded-l px-4 py-2 text-xs text-white outline-none transition-all duration-150 ease-linear focus:bg-primary-dark focus:text-white focus:outline-none",t==="roles"?"bg-primary-dark font-bold":"bg-grey-300 hover:bg-primary-hover hover:text-white"),type:"button",onClick:()=>n("roles"),children:"Roles"}),C.jsx("button",{"data-cy":"privileges_btn_navbar",className:Ve(" min-w-[110px] rounded-r px-4 py-2 text-xs text-white outline-none transition-all duration-150 ease-linear focus:bg-primary-dark focus:text-white focus:outline-none",t==="privileges"?"bg-primary-dark font-bold":"bg-grey-300 hover:bg-primary-hover hover:text-white"),type:"button",onClick:()=>n("privileges"),children:"Privileges"})]})}),C.jsxs("div",{className:"flex gap-2 justify-between",children:[C.jsxs("span",{className:"flex items-center gap-1 whitespace-nowrap",children:[C.jsx(Te.ControlledSwitch,{size:"sm",value:i||!1,onChange:u=>{o(u)}}),C.jsx("span",{className:"px-1 text-xs text-white",children:"Restrict Access By Default"}),C.jsx(Te.Tip,{tipKey:"editors:roles:toolbar:restrictedByDefault",alwaysOn:!0,side:"left"})]}),e===!1&&C.jsxs("span",{className:"flex items-center gap-1 whitespace-nowrap",children:[C.jsx(Te.ControlledSwitch,{size:"sm",value:r||!1,onChange:u=>{a(u)}}),C.jsx("span",{className:"px-1 text-xs text-white",children:"Force login"}),C.jsx(Te.Tip,{tipKey:"editors:roles:toolbar:forceLogin",alwaysOn:!0,side:"left"})]})]})]})})})})}const cD=A.createContext(void 0),Jz=({children:e})=>{const[t,r]=A.useState(null);function n(o){r(o)}const i={selectedRole:t,selectRole:n};return C.jsx(cD.Provider,{value:i,children:e})};function Xb(){const e=A.useContext(cD);if(e===void 0)throw new Error("useSelectedRole must be used within a SelectedRoleProvider");return e}var B1=function(t){return t.reduce(function(r,n){var i=n[0],o=n[1];return r[i]=o,r},{})},F1=typeof window<"u"&&window.document&&window.document.createElement?ve.useLayoutEffect:ve.useEffect,Gt="top",Er="bottom",Sr="right",Kt="left",Zb="auto",Fa=[Gt,Er,Sr,Kt],lo="start",Na="end",Qz="clippingParents",lD="viewport",Zo="popper",eH="reference",$1=Fa.reduce(function(e,t){return e.concat([t+"-"+lo,t+"-"+Na])},[]),fD=[].concat(Fa,[Zb]).reduce(function(e,t){return e.concat([t,t+"-"+lo,t+"-"+Na])},[]),tH="beforeRead",rH="read",nH="afterRead",iH="beforeMain",oH="main",aH="afterMain",sH="beforeWrite",uH="write",cH="afterWrite",lH=[tH,rH,nH,iH,oH,aH,sH,uH,cH];function rn(e){return e?(e.nodeName||"").toLowerCase():null}function sr(e){if(e==null)return window;if(e.toString()!=="[object Window]"){var t=e.ownerDocument;return t&&t.defaultView||window}return e}function vi(e){var t=sr(e).Element;return e instanceof t||e instanceof Element}function _r(e){var t=sr(e).HTMLElement;return e instanceof t||e instanceof HTMLElement}function Jb(e){if(typeof ShadowRoot>"u")return!1;var t=sr(e).ShadowRoot;return e instanceof t||e instanceof ShadowRoot}function fH(e){var t=e.state;Object.keys(t.elements).forEach(function(r){var n=t.styles[r]||{},i=t.attributes[r]||{},o=t.elements[r];!_r(o)||!rn(o)||(Object.assign(o.style,n),Object.keys(i).forEach(function(a){var u=i[a];u===!1?o.removeAttribute(a):o.setAttribute(a,u===!0?"":u)}))})}function dH(e){var t=e.state,r={popper:{position:t.options.strategy,left:"0",top:"0",margin:"0"},arrow:{position:"absolute"},reference:{}};return Object.assign(t.elements.popper.style,r.popper),t.styles=r,t.elements.arrow&&Object.assign(t.elements.arrow.style,r.arrow),function(){Object.keys(t.elements).forEach(function(n){var i=t.elements[n],o=t.attributes[n]||{},a=Object.keys(t.styles.hasOwnProperty(n)?t.styles[n]:r[n]),u=a.reduce(function(c,d){return c[d]="",c},{});!_r(i)||!rn(i)||(Object.assign(i.style,u),Object.keys(o).forEach(function(c){i.removeAttribute(c)}))})}}const hH={name:"applyStyles",enabled:!0,phase:"write",fn:fH,effect:dH,requires:["computeStyles"]};function Qr(e){return e.split("-")[0]}var ci=Math.max,Hu=Math.min,fo=Math.round;function Eb(){var e=navigator.userAgentData;return e!=null&&e.brands&&Array.isArray(e.brands)?e.brands.map(function(t){return t.brand+"/"+t.version}).join(" "):navigator.userAgent}function dD(){return!/^((?!chrome|android).)*safari/i.test(Eb())}function ho(e,t,r){t===void 0&&(t=!1),r===void 0&&(r=!1);var n=e.getBoundingClientRect(),i=1,o=1;t&&_r(e)&&(i=e.offsetWidth>0&&fo(n.width)/e.offsetWidth||1,o=e.offsetHeight>0&&fo(n.height)/e.offsetHeight||1);var a=vi(e)?sr(e):window,u=a.visualViewport,c=!dD()&&r,d=(n.left+(c&&u?u.offsetLeft:0))/i,f=(n.top+(c&&u?u.offsetTop:0))/o,h=n.width/i,p=n.height/o;return{width:h,height:p,top:f,right:d+h,bottom:f+p,left:d,x:d,y:f}}function Qb(e){var t=ho(e),r=e.offsetWidth,n=e.offsetHeight;return Math.abs(t.width-r)<=1&&(r=t.width),Math.abs(t.height-n)<=1&&(n=t.height),{x:e.offsetLeft,y:e.offsetTop,width:r,height:n}}function hD(e,t){var r=t.getRootNode&&t.getRootNode();if(e.contains(t))return!0;if(r&&Jb(r)){var n=t;do{if(n&&e.isSameNode(n))return!0;n=n.parentNode||n.host}while(n)}return!1}function bn(e){return sr(e).getComputedStyle(e)}function pH(e){return["table","td","th"].indexOf(rn(e))>=0}function Vn(e){return((vi(e)?e.ownerDocument:e.document)||window.document).documentElement}function xc(e){return rn(e)==="html"?e:e.assignedSlot||e.parentNode||(Jb(e)?e.host:null)||Vn(e)}function z1(e){return!_r(e)||bn(e).position==="fixed"?null:e.offsetParent}function vH(e){var t=/firefox/i.test(Eb()),r=/Trident/i.test(Eb());if(r&&_r(e)){var n=bn(e);if(n.position==="fixed")return null}var i=xc(e);for(Jb(i)&&(i=i.host);_r(i)&&["html","body"].indexOf(rn(i))<0;){var o=bn(i);if(o.transform!=="none"||o.perspective!=="none"||o.contain==="paint"||["transform","perspective"].indexOf(o.willChange)!==-1||t&&o.willChange==="filter"||t&&o.filter&&o.filter!=="none")return i;i=i.parentNode}return null}function $a(e){for(var t=sr(e),r=z1(e);r&&pH(r)&&bn(r).position==="static";)r=z1(r);return r&&(rn(r)==="html"||rn(r)==="body"&&bn(r).position==="static")?t:r||vH(e)||t}function ex(e){return["top","bottom"].indexOf(e)>=0?"x":"y"}function Oa(e,t,r){return ci(e,Hu(t,r))}function gH(e,t,r){var n=Oa(e,t,r);return n>r?r:n}function pD(){return{top:0,right:0,bottom:0,left:0}}function vD(e){return Object.assign({},pD(),e)}function gD(e,t){return t.reduce(function(r,n){return r[n]=e,r},{})}var mH=function(t,r){return t=typeof t=="function"?t(Object.assign({},r.rects,{placement:r.placement})):t,vD(typeof t!="number"?t:gD(t,Fa))};function yH(e){var t,r=e.state,n=e.name,i=e.options,o=r.elements.arrow,a=r.modifiersData.popperOffsets,u=Qr(r.placement),c=ex(u),d=[Kt,Sr].indexOf(u)>=0,f=d?"height":"width";if(!(!o||!a)){var h=mH(i.padding,r),p=Qb(o),v=c==="y"?Gt:Kt,m=c==="y"?Er:Sr,y=r.rects.reference[f]+r.rects.reference[c]-a[c]-r.rects.popper[f],x=a[c]-r.rects.reference[c],b=$a(o),w=b?c==="y"?b.clientHeight||0:b.clientWidth||0:0,S=y/2-x/2,E=h[v],_=w-p[f]-h[m],R=w/2-p[f]/2+S,I=Oa(E,R,_),N=c;r.modifiersData[n]=(t={},t[N]=I,t.centerOffset=I-R,t)}}function bH(e){var t=e.state,r=e.options,n=r.element,i=n===void 0?"[data-popper-arrow]":n;i!=null&&(typeof i=="string"&&(i=t.elements.popper.querySelector(i),!i)||hD(t.elements.popper,i)&&(t.elements.arrow=i))}const xH={name:"arrow",enabled:!0,phase:"main",fn:yH,effect:bH,requires:["popperOffsets"],requiresIfExists:["preventOverflow"]};function po(e){return e.split("-")[1]}var wH={top:"auto",right:"auto",bottom:"auto",left:"auto"};function _H(e,t){var r=e.x,n=e.y,i=t.devicePixelRatio||1;return{x:fo(r*i)/i||0,y:fo(n*i)/i||0}}function H1(e){var t,r=e.popper,n=e.popperRect,i=e.placement,o=e.variation,a=e.offsets,u=e.position,c=e.gpuAcceleration,d=e.adaptive,f=e.roundOffsets,h=e.isFixed,p=a.x,v=p===void 0?0:p,m=a.y,y=m===void 0?0:m,x=typeof f=="function"?f({x:v,y}):{x:v,y};v=x.x,y=x.y;var b=a.hasOwnProperty("x"),w=a.hasOwnProperty("y"),S=Kt,E=Gt,_=window;if(d){var R=$a(r),I="clientHeight",N="clientWidth";if(R===sr(r)&&(R=Vn(r),bn(R).position!=="static"&&u==="absolute"&&(I="scrollHeight",N="scrollWidth")),R=R,i===Gt||(i===Kt||i===Sr)&&o===Na){E=Er;var D=h&&R===_&&_.visualViewport?_.visualViewport.height:R[I];y-=D-n.height,y*=c?1:-1}if(i===Kt||(i===Gt||i===Er)&&o===Na){S=Sr;var k=h&&R===_&&_.visualViewport?_.visualViewport.width:R[N];v-=k-n.width,v*=c?1:-1}}var B=Object.assign({position:u},d&&wH),L=f===!0?_H({x:v,y},sr(r)):{x:v,y};if(v=L.x,y=L.y,c){var j;return Object.assign({},B,(j={},j[E]=w?"0":"",j[S]=b?"0":"",j.transform=(_.devicePixelRatio||1)<=1?"translate("+v+"px, "+y+"px)":"translate3d("+v+"px, "+y+"px, 0)",j))}return Object.assign({},B,(t={},t[E]=w?y+"px":"",t[S]=b?v+"px":"",t.transform="",t))}function EH(e){var t=e.state,r=e.options,n=r.gpuAcceleration,i=n===void 0?!0:n,o=r.adaptive,a=o===void 0?!0:o,u=r.roundOffsets,c=u===void 0?!0:u,d={placement:Qr(t.placement),variation:po(t.placement),popper:t.elements.popper,popperRect:t.rects.popper,gpuAcceleration:i,isFixed:t.options.strategy==="fixed"};t.modifiersData.popperOffsets!=null&&(t.styles.popper=Object.assign({},t.styles.popper,H1(Object.assign({},d,{offsets:t.modifiersData.popperOffsets,position:t.options.strategy,adaptive:a,roundOffsets:c})))),t.modifiersData.arrow!=null&&(t.styles.arrow=Object.assign({},t.styles.arrow,H1(Object.assign({},d,{offsets:t.modifiersData.arrow,position:"absolute",adaptive:!1,roundOffsets:c})))),t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-placement":t.placement})}const SH={name:"computeStyles",enabled:!0,phase:"beforeWrite",fn:EH,data:{}};var uu={passive:!0};function OH(e){var t=e.state,r=e.instance,n=e.options,i=n.scroll,o=i===void 0?!0:i,a=n.resize,u=a===void 0?!0:a,c=sr(t.elements.popper),d=[].concat(t.scrollParents.reference,t.scrollParents.popper);return o&&d.forEach(function(f){f.addEventListener("scroll",r.update,uu)}),u&&c.addEventListener("resize",r.update,uu),function(){o&&d.forEach(function(f){f.removeEventListener("scroll",r.update,uu)}),u&&c.removeEventListener("resize",r.update,uu)}}const CH={name:"eventListeners",enabled:!0,phase:"write",fn:function(){},effect:OH,data:{}};var RH={left:"right",right:"left",bottom:"top",top:"bottom"};function Mu(e){return e.replace(/left|right|bottom|top/g,function(t){return RH[t]})}var IH={start:"end",end:"start"};function U1(e){return e.replace(/start|end/g,function(t){return IH[t]})}function tx(e){var t=sr(e),r=t.pageXOffset,n=t.pageYOffset;return{scrollLeft:r,scrollTop:n}}function rx(e){return ho(Vn(e)).left+tx(e).scrollLeft}function PH(e,t){var r=sr(e),n=Vn(e),i=r.visualViewport,o=n.clientWidth,a=n.clientHeight,u=0,c=0;if(i){o=i.width,a=i.height;var d=dD();(d||!d&&t==="fixed")&&(u=i.offsetLeft,c=i.offsetTop)}return{width:o,height:a,x:u+rx(e),y:c}}function NH(e){var t,r=Vn(e),n=tx(e),i=(t=e.ownerDocument)==null?void 0:t.body,o=ci(r.scrollWidth,r.clientWidth,i?i.scrollWidth:0,i?i.clientWidth:0),a=ci(r.scrollHeight,r.clientHeight,i?i.scrollHeight:0,i?i.clientHeight:0),u=-n.scrollLeft+rx(e),c=-n.scrollTop;return bn(i||r).direction==="rtl"&&(u+=ci(r.clientWidth,i?i.clientWidth:0)-o),{width:o,height:a,x:u,y:c}}function nx(e){var t=bn(e),r=t.overflow,n=t.overflowX,i=t.overflowY;return/auto|scroll|overlay|hidden/.test(r+i+n)}function mD(e){return["html","body","#document"].indexOf(rn(e))>=0?e.ownerDocument.body:_r(e)&&nx(e)?e:mD(xc(e))}function Ca(e,t){var r;t===void 0&&(t=[]);var n=mD(e),i=n===((r=e.ownerDocument)==null?void 0:r.body),o=sr(n),a=i?[o].concat(o.visualViewport||[],nx(n)?n:[]):n,u=t.concat(a);return i?u:u.concat(Ca(xc(a)))}function Sb(e){return Object.assign({},e,{left:e.x,top:e.y,right:e.x+e.width,bottom:e.y+e.height})}function TH(e,t){var r=ho(e,!1,t==="fixed");return r.top=r.top+e.clientTop,r.left=r.left+e.clientLeft,r.bottom=r.top+e.clientHeight,r.right=r.left+e.clientWidth,r.width=e.clientWidth,r.height=e.clientHeight,r.x=r.left,r.y=r.top,r}function V1(e,t,r){return t===lD?Sb(PH(e,r)):vi(t)?TH(t,r):Sb(NH(Vn(e)))}function AH(e){var t=Ca(xc(e)),r=["absolute","fixed"].indexOf(bn(e).position)>=0,n=r&&_r(e)?$a(e):e;return vi(n)?t.filter(function(i){return vi(i)&&hD(i,n)&&rn(i)!=="body"}):[]}function MH(e,t,r,n){var i=t==="clippingParents"?AH(e):[].concat(t),o=[].concat(i,[r]),a=o[0],u=o.reduce(function(c,d){var f=V1(e,d,n);return c.top=ci(f.top,c.top),c.right=Hu(f.right,c.right),c.bottom=Hu(f.bottom,c.bottom),c.left=ci(f.left,c.left),c},V1(e,a,n));return u.width=u.right-u.left,u.height=u.bottom-u.top,u.x=u.left,u.y=u.top,u}function yD(e){var t=e.reference,r=e.element,n=e.placement,i=n?Qr(n):null,o=n?po(n):null,a=t.x+t.width/2-r.width/2,u=t.y+t.height/2-r.height/2,c;switch(i){case Gt:c={x:a,y:t.y-r.height};break;case Er:c={x:a,y:t.y+t.height};break;case Sr:c={x:t.x+t.width,y:u};break;case Kt:c={x:t.x-r.width,y:u};break;default:c={x:t.x,y:t.y}}var d=i?ex(i):null;if(d!=null){var f=d==="y"?"height":"width";switch(o){case lo:c[d]=c[d]-(t[f]/2-r[f]/2);break;case Na:c[d]=c[d]+(t[f]/2-r[f]/2);break}}return c}function Ta(e,t){t===void 0&&(t={});var r=t,n=r.placement,i=n===void 0?e.placement:n,o=r.strategy,a=o===void 0?e.strategy:o,u=r.boundary,c=u===void 0?Qz:u,d=r.rootBoundary,f=d===void 0?lD:d,h=r.elementContext,p=h===void 0?Zo:h,v=r.altBoundary,m=v===void 0?!1:v,y=r.padding,x=y===void 0?0:y,b=vD(typeof x!="number"?x:gD(x,Fa)),w=p===Zo?eH:Zo,S=e.rects.popper,E=e.elements[m?w:p],_=MH(vi(E)?E:E.contextElement||Vn(e.elements.popper),c,f,a),R=ho(e.elements.reference),I=yD({reference:R,element:S,placement:i}),N=Sb(Object.assign({},S,I)),D=p===Zo?N:R,k={top:_.top-D.top+b.top,bottom:D.bottom-_.bottom+b.bottom,left:_.left-D.left+b.left,right:D.right-_.right+b.right},B=e.modifiersData.offset;if(p===Zo&&B){var L=B[i];Object.keys(k).forEach(function(j){var T=[Sr,Er].indexOf(j)>=0?1:-1,F=[Gt,Er].indexOf(j)>=0?"y":"x";k[j]+=L[F]*T})}return k}function DH(e,t){t===void 0&&(t={});var r=t,n=r.placement,i=r.boundary,o=r.rootBoundary,a=r.padding,u=r.flipVariations,c=r.allowedAutoPlacements,d=c===void 0?fD:c,f=po(n),h=f?u?$1:$1.filter(function(m){return po(m)===f}):Fa,p=h.filter(function(m){return d.indexOf(m)>=0});p.length===0&&(p=h);var v=p.reduce(function(m,y){return m[y]=Ta(e,{placement:y,boundary:i,rootBoundary:o,padding:a})[Qr(y)],m},{});return Object.keys(v).sort(function(m,y){return v[m]-v[y]})}function jH(e){if(Qr(e)===Zb)return[];var t=Mu(e);return[U1(e),t,U1(t)]}function qH(e){var t=e.state,r=e.options,n=e.name;if(!t.modifiersData[n]._skip){for(var i=r.mainAxis,o=i===void 0?!0:i,a=r.altAxis,u=a===void 0?!0:a,c=r.fallbackPlacements,d=r.padding,f=r.boundary,h=r.rootBoundary,p=r.altBoundary,v=r.flipVariations,m=v===void 0?!0:v,y=r.allowedAutoPlacements,x=t.options.placement,b=Qr(x),w=b===x,S=c||(w||!m?[Mu(x)]:jH(x)),E=[x].concat(S).reduce(function(z,G){return z.concat(Qr(G)===Zb?DH(t,{placement:G,boundary:f,rootBoundary:h,padding:d,flipVariations:m,allowedAutoPlacements:y}):G)},[]),_=t.rects.reference,R=t.rects.popper,I=new Map,N=!0,D=E[0],k=0;k<E.length;k++){var B=E[k],L=Qr(B),j=po(B)===lo,T=[Gt,Er].indexOf(L)>=0,F=T?"width":"height",$=Ta(t,{placement:B,boundary:f,rootBoundary:h,altBoundary:p,padding:d}),W=T?j?Sr:Kt:j?Er:Gt;_[F]>R[F]&&(W=Mu(W));var Y=Mu(W),ee=[];if(o&&ee.push($[L]<=0),u&&ee.push($[W]<=0,$[Y]<=0),ee.every(function(z){return z})){D=B,N=!1;break}I.set(B,ee)}if(N)for(var H=m?3:1,Q=function(G){var J=E.find(function(V){var K=I.get(V);if(K)return K.slice(0,G).every(function(ie){return ie})});if(J)return D=J,"break"},ce=H;ce>0;ce--){var se=Q(ce);if(se==="break")break}t.placement!==D&&(t.modifiersData[n]._skip=!0,t.placement=D,t.reset=!0)}}const kH={name:"flip",enabled:!0,phase:"main",fn:qH,requiresIfExists:["offset"],data:{_skip:!1}};function W1(e,t,r){return r===void 0&&(r={x:0,y:0}),{top:e.top-t.height-r.y,right:e.right-t.width+r.x,bottom:e.bottom-t.height+r.y,left:e.left-t.width-r.x}}function G1(e){return[Gt,Sr,Er,Kt].some(function(t){return e[t]>=0})}function LH(e){var t=e.state,r=e.name,n=t.rects.reference,i=t.rects.popper,o=t.modifiersData.preventOverflow,a=Ta(t,{elementContext:"reference"}),u=Ta(t,{altBoundary:!0}),c=W1(a,n),d=W1(u,i,o),f=G1(c),h=G1(d);t.modifiersData[r]={referenceClippingOffsets:c,popperEscapeOffsets:d,isReferenceHidden:f,hasPopperEscaped:h},t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-reference-hidden":f,"data-popper-escaped":h})}const BH={name:"hide",enabled:!0,phase:"main",requiresIfExists:["preventOverflow"],fn:LH};function FH(e,t,r){var n=Qr(e),i=[Kt,Gt].indexOf(n)>=0?-1:1,o=typeof r=="function"?r(Object.assign({},t,{placement:e})):r,a=o[0],u=o[1];return a=a||0,u=(u||0)*i,[Kt,Sr].indexOf(n)>=0?{x:u,y:a}:{x:a,y:u}}function $H(e){var t=e.state,r=e.options,n=e.name,i=r.offset,o=i===void 0?[0,0]:i,a=fD.reduce(function(f,h){return f[h]=FH(h,t.rects,o),f},{}),u=a[t.placement],c=u.x,d=u.y;t.modifiersData.popperOffsets!=null&&(t.modifiersData.popperOffsets.x+=c,t.modifiersData.popperOffsets.y+=d),t.modifiersData[n]=a}const zH={name:"offset",enabled:!0,phase:"main",requires:["popperOffsets"],fn:$H};function HH(e){var t=e.state,r=e.name;t.modifiersData[r]=yD({reference:t.rects.reference,element:t.rects.popper,placement:t.placement})}const UH={name:"popperOffsets",enabled:!0,phase:"read",fn:HH,data:{}};function VH(e){return e==="x"?"y":"x"}function WH(e){var t=e.state,r=e.options,n=e.name,i=r.mainAxis,o=i===void 0?!0:i,a=r.altAxis,u=a===void 0?!1:a,c=r.boundary,d=r.rootBoundary,f=r.altBoundary,h=r.padding,p=r.tether,v=p===void 0?!0:p,m=r.tetherOffset,y=m===void 0?0:m,x=Ta(t,{boundary:c,rootBoundary:d,padding:h,altBoundary:f}),b=Qr(t.placement),w=po(t.placement),S=!w,E=ex(b),_=VH(E),R=t.modifiersData.popperOffsets,I=t.rects.reference,N=t.rects.popper,D=typeof y=="function"?y(Object.assign({},t.rects,{placement:t.placement})):y,k=typeof D=="number"?{mainAxis:D,altAxis:D}:Object.assign({mainAxis:0,altAxis:0},D),B=t.modifiersData.offset?t.modifiersData.offset[t.placement]:null,L={x:0,y:0};if(R){if(o){var j,T=E==="y"?Gt:Kt,F=E==="y"?Er:Sr,$=E==="y"?"height":"width",W=R[E],Y=W+x[T],ee=W-x[F],H=v?-N[$]/2:0,Q=w===lo?I[$]:N[$],ce=w===lo?-N[$]:-I[$],se=t.elements.arrow,z=v&&se?Qb(se):{width:0,height:0},G=t.modifiersData["arrow#persistent"]?t.modifiersData["arrow#persistent"].padding:pD(),J=G[T],V=G[F],K=Oa(0,I[$],z[$]),ie=S?I[$]/2-H-K-J-k.mainAxis:Q-K-J-k.mainAxis,ne=S?-I[$]/2+H+K+V+k.mainAxis:ce+K+V+k.mainAxis,ue=t.elements.arrow&&$a(t.elements.arrow),de=ue?E==="y"?ue.clientTop||0:ue.clientLeft||0:0,we=(j=B==null?void 0:B[E])!=null?j:0,Se=W+ie-we-de,_e=W+ne-we,he=Oa(v?Hu(Y,Se):Y,W,v?ci(ee,_e):ee);R[E]=he,L[E]=he-W}if(u){var ae,Oe=E==="x"?Gt:Kt,Ne=E==="x"?Er:Sr,He=R[_],qe=_==="y"?"height":"width",Xe=He+x[Oe],We=He-x[Ne],mt=[Gt,Kt].indexOf(b)!==-1,et=(ae=B==null?void 0:B[_])!=null?ae:0,Tt=mt?Xe:He-I[qe]-N[qe]-et+k.altAxis,ut=mt?He+I[qe]+N[qe]-et-k.altAxis:We,tt=v&&mt?gH(Tt,He,ut):Oa(v?Tt:Xe,He,v?ut:We);R[_]=tt,L[_]=tt-He}t.modifiersData[n]=L}}const GH={name:"preventOverflow",enabled:!0,phase:"main",fn:WH,requiresIfExists:["offset"]};function KH(e){return{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}}function YH(e){return e===sr(e)||!_r(e)?tx(e):KH(e)}function XH(e){var t=e.getBoundingClientRect(),r=fo(t.width)/e.offsetWidth||1,n=fo(t.height)/e.offsetHeight||1;return r!==1||n!==1}function ZH(e,t,r){r===void 0&&(r=!1);var n=_r(t),i=_r(t)&&XH(t),o=Vn(t),a=ho(e,i,r),u={scrollLeft:0,scrollTop:0},c={x:0,y:0};return(n||!n&&!r)&&((rn(t)!=="body"||nx(o))&&(u=YH(t)),_r(t)?(c=ho(t,!0),c.x+=t.clientLeft,c.y+=t.clientTop):o&&(c.x=rx(o))),{x:a.left+u.scrollLeft-c.x,y:a.top+u.scrollTop-c.y,width:a.width,height:a.height}}function JH(e){var t=new Map,r=new Set,n=[];e.forEach(function(o){t.set(o.name,o)});function i(o){r.add(o.name);var a=[].concat(o.requires||[],o.requiresIfExists||[]);a.forEach(function(u){if(!r.has(u)){var c=t.get(u);c&&i(c)}}),n.push(o)}return e.forEach(function(o){r.has(o.name)||i(o)}),n}function QH(e){var t=JH(e);return lH.reduce(function(r,n){return r.concat(t.filter(function(i){return i.phase===n}))},[])}function e4(e){var t;return function(){return t||(t=new Promise(function(r){Promise.resolve().then(function(){t=void 0,r(e())})})),t}}function t4(e){var t=e.reduce(function(r,n){var i=r[n.name];return r[n.name]=i?Object.assign({},i,n,{options:Object.assign({},i.options,n.options),data:Object.assign({},i.data,n.data)}):n,r},{});return Object.keys(t).map(function(r){return t[r]})}var K1={placement:"bottom",modifiers:[],strategy:"absolute"};function Y1(){for(var e=arguments.length,t=new Array(e),r=0;r<e;r++)t[r]=arguments[r];return!t.some(function(n){return!(n&&typeof n.getBoundingClientRect=="function")})}function r4(e){e===void 0&&(e={});var t=e,r=t.defaultModifiers,n=r===void 0?[]:r,i=t.defaultOptions,o=i===void 0?K1:i;return function(u,c,d){d===void 0&&(d=o);var f={placement:"bottom",orderedModifiers:[],options:Object.assign({},K1,o),modifiersData:{},elements:{reference:u,popper:c},attributes:{},styles:{}},h=[],p=!1,v={state:f,setOptions:function(b){var w=typeof b=="function"?b(f.options):b;y(),f.options=Object.assign({},o,f.options,w),f.scrollParents={reference:vi(u)?Ca(u):u.contextElement?Ca(u.contextElement):[],popper:Ca(c)};var S=QH(t4([].concat(n,f.options.modifiers)));return f.orderedModifiers=S.filter(function(E){return E.enabled}),m(),v.update()},forceUpdate:function(){if(!p){var b=f.elements,w=b.reference,S=b.popper;if(Y1(w,S)){f.rects={reference:ZH(w,$a(S),f.options.strategy==="fixed"),popper:Qb(S)},f.reset=!1,f.placement=f.options.placement,f.orderedModifiers.forEach(function(k){return f.modifiersData[k.name]=Object.assign({},k.data)});for(var E=0;E<f.orderedModifiers.length;E++){if(f.reset===!0){f.reset=!1,E=-1;continue}var _=f.orderedModifiers[E],R=_.fn,I=_.options,N=I===void 0?{}:I,D=_.name;typeof R=="function"&&(f=R({state:f,options:N,name:D,instance:v})||f)}}}},update:e4(function(){return new Promise(function(x){v.forceUpdate(),x(f)})}),destroy:function(){y(),p=!0}};if(!Y1(u,c))return v;v.setOptions(d).then(function(x){!p&&d.onFirstUpdate&&d.onFirstUpdate(x)});function m(){f.orderedModifiers.forEach(function(x){var b=x.name,w=x.options,S=w===void 0?{}:w,E=x.effect;if(typeof E=="function"){var _=E({state:f,name:b,instance:v,options:S}),R=function(){};h.push(_||R)}})}function y(){h.forEach(function(x){return x()}),h=[]}return v}}var n4=[CH,UH,SH,hH,zH,kH,GH,xH,BH],i4=r4({defaultModifiers:n4}),Gf,X1;function o4(){if(X1)return Gf;X1=1;var e=typeof Element<"u",t=typeof Map=="function",r=typeof Set=="function",n=typeof ArrayBuffer=="function"&&!!ArrayBuffer.isView;function i(o,a){if(o===a)return!0;if(o&&a&&typeof o=="object"&&typeof a=="object"){if(o.constructor!==a.constructor)return!1;var u,c,d;if(Array.isArray(o)){if(u=o.length,u!=a.length)return!1;for(c=u;c--!==0;)if(!i(o[c],a[c]))return!1;return!0}var f;if(t&&o instanceof Map&&a instanceof Map){if(o.size!==a.size)return!1;for(f=o.entries();!(c=f.next()).done;)if(!a.has(c.value[0]))return!1;for(f=o.entries();!(c=f.next()).done;)if(!i(c.value[1],a.get(c.value[0])))return!1;return!0}if(r&&o instanceof Set&&a instanceof Set){if(o.size!==a.size)return!1;for(f=o.entries();!(c=f.next()).done;)if(!a.has(c.value[0]))return!1;return!0}if(n&&ArrayBuffer.isView(o)&&ArrayBuffer.isView(a)){if(u=o.length,u!=a.length)return!1;for(c=u;c--!==0;)if(o[c]!==a[c])return!1;return!0}if(o.constructor===RegExp)return o.source===a.source&&o.flags===a.flags;if(o.valueOf!==Object.prototype.valueOf&&typeof o.valueOf=="function"&&typeof a.valueOf=="function")return o.valueOf()===a.valueOf();if(o.toString!==Object.prototype.toString&&typeof o.toString=="function"&&typeof a.toString=="function")return o.toString()===a.toString();if(d=Object.keys(o),u=d.length,u!==Object.keys(a).length)return!1;for(c=u;c--!==0;)if(!Object.prototype.hasOwnProperty.call(a,d[c]))return!1;if(e&&o instanceof Element)return!1;for(c=u;c--!==0;)if(!((d[c]==="_owner"||d[c]==="__v"||d[c]==="__o")&&o.$$typeof)&&!i(o[d[c]],a[d[c]]))return!1;return!0}return o!==o&&a!==a}return Gf=function(a,u){try{return i(a,u)}catch(c){if((c.message||"").match(/stack|recursion/i))return console.warn("react-fast-compare cannot handle circular refs"),!1;throw c}},Gf}var a4=o4();const s4=Un(a4);var u4=[],wc=function(t,r,n){n===void 0&&(n={});var i=ve.useRef(null),o={onFirstUpdate:n.onFirstUpdate,placement:n.placement||"bottom",strategy:n.strategy||"absolute",modifiers:n.modifiers||u4},a=ve.useState({styles:{popper:{position:o.strategy,left:"0",top:"0"},arrow:{position:"absolute"}},attributes:{}}),u=a[0],c=a[1],d=ve.useMemo(function(){return{name:"updateState",enabled:!0,phase:"write",fn:function(v){var m=v.state,y=Object.keys(m.elements);Yb.flushSync(function(){c({styles:B1(y.map(function(x){return[x,m.styles[x]||{}]})),attributes:B1(y.map(function(x){return[x,m.attributes[x]]}))})})},requires:["computeStyles"]}},[]),f=ve.useMemo(function(){var p={onFirstUpdate:o.onFirstUpdate,placement:o.placement,strategy:o.strategy,modifiers:[].concat(o.modifiers,[d,{name:"applyStyles",enabled:!1}])};return s4(i.current,p)?i.current||p:(i.current=p,p)},[o.onFirstUpdate,o.placement,o.strategy,o.modifiers,d]),h=ve.useRef();return F1(function(){h.current&&h.current.setOptions(f)},[f]),F1(function(){if(!(t==null||r==null)){var p=n.createPopper||i4,v=p(t,r,f);return h.current=v,function(){v.destroy(),h.current=null}}},[t,r,n.createPopper]),{state:h.current?h.current.state:null,styles:u.styles,attributes:u.attributes,update:h.current?h.current.update:null,forceUpdate:h.current?h.current.forceUpdate:null}};const bD=({tab:e})=>C.jsx("div",{className:"flex flex-1 items-center justify-center border-l-[0.5px] border-grey-900 bg-grey-800",children:C.jsxs("div",{className:"flex flex-col items-center justify-center space-y-4 text-grey-200",children:[C.jsx(ye.FdInfoBold,{className:"h-10 w-10"}),C.jsxs("div",{className:"font-semibold",children:["No ",e," Selected"]}),C.jsxs("div",{className:"text-sm",children:["Click on a ",e," in the Sidebar to select it."]})]})});function ix(e){throw new Error('Could not dynamically require "'+e+'". Please configure the dynamicRequireTargets or/and ignoreDynamicRequires option of @rollup/plugin-commonjs appropriately for this require call to work.')}var Kf,Z1;function c4(){if(Z1)return Kf;Z1=1;function e(){this.__data__=[],this.size=0}return Kf=e,Kf}var Yf,J1;function bo(){if(J1)return Yf;J1=1;function e(t,r){return t===r||t!==t&&r!==r}return Yf=e,Yf}var Xf,Q1;function _c(){if(Q1)return Xf;Q1=1;var e=bo();function t(r,n){for(var i=r.length;i--;)if(e(r[i][0],n))return i;return-1}return Xf=t,Xf}var Zf,eE;function l4(){if(eE)return Zf;eE=1;var e=_c(),t=Array.prototype,r=t.splice;function n(i){var o=this.__data__,a=e(o,i);if(a<0)return!1;var u=o.length-1;return a==u?o.pop():r.call(o,a,1),--this.size,!0}return Zf=n,Zf}var Jf,tE;function f4(){if(tE)return Jf;tE=1;var e=_c();function t(r){var n=this.__data__,i=e(n,r);return i<0?void 0:n[i][1]}return Jf=t,Jf}var Qf,rE;function d4(){if(rE)return Qf;rE=1;var e=_c();function t(r){return e(this.__data__,r)>-1}return Qf=t,Qf}var ed,nE;function h4(){if(nE)return ed;nE=1;var e=_c();function t(r,n){var i=this.__data__,o=e(i,r);return o<0?(++this.size,i.push([r,n])):i[o][1]=n,this}return ed=t,ed}var td,iE;function Ec(){if(iE)return td;iE=1;var e=c4(),t=l4(),r=f4(),n=d4(),i=h4();function o(a){var u=-1,c=a==null?0:a.length;for(this.clear();++u<c;){var d=a[u];this.set(d[0],d[1])}}return o.prototype.clear=e,o.prototype.delete=t,o.prototype.get=r,o.prototype.has=n,o.prototype.set=i,td=o,td}var rd,oE;function p4(){if(oE)return rd;oE=1;var e=Ec();function t(){this.__data__=new e,this.size=0}return rd=t,rd}var nd,aE;function v4(){if(aE)return nd;aE=1;function e(t){var r=this.__data__,n=r.delete(t);return this.size=r.size,n}return nd=e,nd}var id,sE;function g4(){if(sE)return id;sE=1;function e(t){return this.__data__.get(t)}return id=e,id}var od,uE;function m4(){if(uE)return od;uE=1;function e(t){return this.__data__.has(t)}return od=e,od}var ad,cE;function xD(){if(cE)return ad;cE=1;var e=typeof ht=="object"&&ht&&ht.Object===Object&&ht;return ad=e,ad}var sd,lE;function Fr(){if(lE)return sd;lE=1;var e=xD(),t=typeof self=="object"&&self&&self.Object===Object&&self,r=e||t||Function("return this")();return sd=r,sd}var ud,fE;function xo(){if(fE)return ud;fE=1;var e=Fr(),t=e.Symbol;return ud=t,ud}var cd,dE;function y4(){if(dE)return cd;dE=1;var e=xo(),t=Object.prototype,r=t.hasOwnProperty,n=t.toString,i=e?e.toStringTag:void 0;function o(a){var u=r.call(a,i),c=a[i];try{a[i]=void 0;var d=!0}catch{}var f=n.call(a);return d&&(u?a[i]=c:delete a[i]),f}return cd=o,cd}var ld,hE;function b4(){if(hE)return ld;hE=1;var e=Object.prototype,t=e.toString;function r(n){return t.call(n)}return ld=r,ld}var fd,pE;function wi(){if(pE)return fd;pE=1;var e=xo(),t=y4(),r=b4(),n="[object Null]",i="[object Undefined]",o=e?e.toStringTag:void 0;function a(u){return u==null?u===void 0?i:n:o&&o in Object(u)?t(u):r(u)}return fd=a,fd}var dd,vE;function Or(){if(vE)return dd;vE=1;function e(t){var r=typeof t;return t!=null&&(r=="object"||r=="function")}return dd=e,dd}var hd,gE;function za(){if(gE)return hd;gE=1;var e=wi(),t=Or(),r="[object AsyncFunction]",n="[object Function]",i="[object GeneratorFunction]",o="[object Proxy]";function a(u){if(!t(u))return!1;var c=e(u);return c==n||c==i||c==r||c==o}return hd=a,hd}var pd,mE;function x4(){if(mE)return pd;mE=1;var e=Fr(),t=e["__core-js_shared__"];return pd=t,pd}var vd,yE;function w4(){if(yE)return vd;yE=1;var e=x4(),t=(function(){var n=/[^.]+$/.exec(e&&e.keys&&e.keys.IE_PROTO||"");return n?"Symbol(src)_1."+n:""})();function r(n){return!!t&&t in n}return vd=r,vd}var gd,bE;function wD(){if(bE)return gd;bE=1;var e=Function.prototype,t=e.toString;function r(n){if(n!=null){try{return t.call(n)}catch{}try{return n+""}catch{}}return""}return gd=r,gd}var md,xE;function _4(){if(xE)return md;xE=1;var e=za(),t=w4(),r=Or(),n=wD(),i=/[\\^$.*+?()[\]{}|]/g,o=/^\[object .+?Constructor\]$/,a=Function.prototype,u=Object.prototype,c=a.toString,d=u.hasOwnProperty,f=RegExp("^"+c.call(d).replace(i,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function h(p){if(!r(p)||t(p))return!1;var v=e(p)?f:o;return v.test(n(p))}return md=h,md}var yd,wE;function E4(){if(wE)return yd;wE=1;function e(t,r){return t==null?void 0:t[r]}return yd=e,yd}var bd,_E;function _i(){if(_E)return bd;_E=1;var e=_4(),t=E4();function r(n,i){var o=t(n,i);return e(o)?o:void 0}return bd=r,bd}var xd,EE;function ox(){if(EE)return xd;EE=1;var e=_i(),t=Fr(),r=e(t,"Map");return xd=r,xd}var wd,SE;function Sc(){if(SE)return wd;SE=1;var e=_i(),t=e(Object,"create");return wd=t,wd}var _d,OE;function S4(){if(OE)return _d;OE=1;var e=Sc();function t(){this.__data__=e?e(null):{},this.size=0}return _d=t,_d}var Ed,CE;function O4(){if(CE)return Ed;CE=1;function e(t){var r=this.has(t)&&delete this.__data__[t];return this.size-=r?1:0,r}return Ed=e,Ed}var Sd,RE;function C4(){if(RE)return Sd;RE=1;var e=Sc(),t="__lodash_hash_undefined__",r=Object.prototype,n=r.hasOwnProperty;function i(o){var a=this.__data__;if(e){var u=a[o];return u===t?void 0:u}return n.call(a,o)?a[o]:void 0}return Sd=i,Sd}var Od,IE;function R4(){if(IE)return Od;IE=1;var e=Sc(),t=Object.prototype,r=t.hasOwnProperty;function n(i){var o=this.__data__;return e?o[i]!==void 0:r.call(o,i)}return Od=n,Od}var Cd,PE;function I4(){if(PE)return Cd;PE=1;var e=Sc(),t="__lodash_hash_undefined__";function r(n,i){var o=this.__data__;return this.size+=this.has(n)?0:1,o[n]=e&&i===void 0?t:i,this}return Cd=r,Cd}var Rd,NE;function P4(){if(NE)return Rd;NE=1;var e=S4(),t=O4(),r=C4(),n=R4(),i=I4();function o(a){var u=-1,c=a==null?0:a.length;for(this.clear();++u<c;){var d=a[u];this.set(d[0],d[1])}}return o.prototype.clear=e,o.prototype.delete=t,o.prototype.get=r,o.prototype.has=n,o.prototype.set=i,Rd=o,Rd}var Id,TE;function N4(){if(TE)return Id;TE=1;var e=P4(),t=Ec(),r=ox();function n(){this.size=0,this.__data__={hash:new e,map:new(r||t),string:new e}}return Id=n,Id}var Pd,AE;function T4(){if(AE)return Pd;AE=1;function e(t){var r=typeof t;return r=="string"||r=="number"||r=="symbol"||r=="boolean"?t!=="__proto__":t===null}return Pd=e,Pd}var Nd,ME;function Oc(){if(ME)return Nd;ME=1;var e=T4();function t(r,n){var i=r.__data__;return e(n)?i[typeof n=="string"?"string":"hash"]:i.map}return Nd=t,Nd}var Td,DE;function A4(){if(DE)return Td;DE=1;var e=Oc();function t(r){var n=e(this,r).delete(r);return this.size-=n?1:0,n}return Td=t,Td}var Ad,jE;function M4(){if(jE)return Ad;jE=1;var e=Oc();function t(r){return e(this,r).get(r)}return Ad=t,Ad}var Md,qE;function D4(){if(qE)return Md;qE=1;var e=Oc();function t(r){return e(this,r).has(r)}return Md=t,Md}var Dd,kE;function j4(){if(kE)return Dd;kE=1;var e=Oc();function t(r,n){var i=e(this,r),o=i.size;return i.set(r,n),this.size+=i.size==o?0:1,this}return Dd=t,Dd}var jd,LE;function ax(){if(LE)return jd;LE=1;var e=N4(),t=A4(),r=M4(),n=D4(),i=j4();function o(a){var u=-1,c=a==null?0:a.length;for(this.clear();++u<c;){var d=a[u];this.set(d[0],d[1])}}return o.prototype.clear=e,o.prototype.delete=t,o.prototype.get=r,o.prototype.has=n,o.prototype.set=i,jd=o,jd}var qd,BE;function q4(){if(BE)return qd;BE=1;var e=Ec(),t=ox(),r=ax(),n=200;function i(o,a){var u=this.__data__;if(u instanceof e){var c=u.__data__;if(!t||c.length<n-1)return c.push([o,a]),this.size=++u.size,this;u=this.__data__=new r(c)}return u.set(o,a),this.size=u.size,this}return qd=i,qd}var kd,FE;function Cc(){if(FE)return kd;FE=1;var e=Ec(),t=p4(),r=v4(),n=g4(),i=m4(),o=q4();function a(u){var c=this.__data__=new e(u);this.size=c.size}return a.prototype.clear=t,a.prototype.delete=r,a.prototype.get=n,a.prototype.has=i,a.prototype.set=o,kd=a,kd}var Ld,$E;function sx(){if($E)return Ld;$E=1;function e(t,r){for(var n=-1,i=t==null?0:t.length;++n<i&&r(t[n],n,t)!==!1;);return t}return Ld=e,Ld}var Bd,zE;function _D(){if(zE)return Bd;zE=1;var e=_i(),t=(function(){try{var r=e(Object,"defineProperty");return r({},"",{}),r}catch{}})();return Bd=t,Bd}var Fd,HE;function Rc(){if(HE)return Fd;HE=1;var e=_D();function t(r,n,i){n=="__proto__"&&e?e(r,n,{configurable:!0,enumerable:!0,value:i,writable:!0}):r[n]=i}return Fd=t,Fd}var $d,UE;function Ic(){if(UE)return $d;UE=1;var e=Rc(),t=bo(),r=Object.prototype,n=r.hasOwnProperty;function i(o,a,u){var c=o[a];(!(n.call(o,a)&&t(c,u))||u===void 0&&!(a in o))&&e(o,a,u)}return $d=i,$d}var zd,VE;function Ha(){if(VE)return zd;VE=1;var e=Ic(),t=Rc();function r(n,i,o,a){var u=!o;o||(o={});for(var c=-1,d=i.length;++c<d;){var f=i[c],h=a?a(o[f],n[f],f,o,n):void 0;h===void 0&&(h=n[f]),u?t(o,f,h):e(o,f,h)}return o}return zd=r,zd}var Hd,WE;function k4(){if(WE)return Hd;WE=1;function e(t,r){for(var n=-1,i=Array(t);++n<t;)i[n]=r(n);return i}return Hd=e,Hd}var Ud,GE;function on(){if(GE)return Ud;GE=1;function e(t){return t!=null&&typeof t=="object"}return Ud=e,Ud}var Vd,KE;function L4(){if(KE)return Vd;KE=1;var e=wi(),t=on(),r="[object Arguments]";function n(i){return t(i)&&e(i)==r}return Vd=n,Vd}var Wd,YE;function Ua(){if(YE)return Wd;YE=1;var e=L4(),t=on(),r=Object.prototype,n=r.hasOwnProperty,i=r.propertyIsEnumerable,o=e((function(){return arguments})())?e:function(a){return t(a)&&n.call(a,"callee")&&!i.call(a,"callee")};return Wd=o,Wd}var Gd,XE;function yt(){if(XE)return Gd;XE=1;var e=Array.isArray;return Gd=e,Gd}var ya={exports:{}},Kd,ZE;function B4(){if(ZE)return Kd;ZE=1;function e(){return!1}return Kd=e,Kd}ya.exports;var JE;function wo(){return JE||(JE=1,(function(e,t){var r=Fr(),n=B4(),i=t&&!t.nodeType&&t,o=i&&!0&&e&&!e.nodeType&&e,a=o&&o.exports===i,u=a?r.Buffer:void 0,c=u?u.isBuffer:void 0,d=c||n;e.exports=d})(ya,ya.exports)),ya.exports}var Yd,QE;function Pc(){if(QE)return Yd;QE=1;var e=9007199254740991,t=/^(?:0|[1-9]\d*)$/;function r(n,i){var o=typeof n;return i=i??e,!!i&&(o=="number"||o!="symbol"&&t.test(n))&&n>-1&&n%1==0&&n<i}return Yd=r,Yd}var Xd,eS;function ux(){if(eS)return Xd;eS=1;var e=9007199254740991;function t(r){return typeof r=="number"&&r>-1&&r%1==0&&r<=e}return Xd=t,Xd}var Zd,tS;function F4(){if(tS)return Zd;tS=1;var e=wi(),t=ux(),r=on(),n="[object Arguments]",i="[object Array]",o="[object Boolean]",a="[object Date]",u="[object Error]",c="[object Function]",d="[object Map]",f="[object Number]",h="[object Object]",p="[object RegExp]",v="[object Set]",m="[object String]",y="[object WeakMap]",x="[object ArrayBuffer]",b="[object DataView]",w="[object Float32Array]",S="[object Float64Array]",E="[object Int8Array]",_="[object Int16Array]",R="[object Int32Array]",I="[object Uint8Array]",N="[object Uint8ClampedArray]",D="[object Uint16Array]",k="[object Uint32Array]",B={};B[w]=B[S]=B[E]=B[_]=B[R]=B[I]=B[N]=B[D]=B[k]=!0,B[n]=B[i]=B[x]=B[o]=B[b]=B[a]=B[u]=B[c]=B[d]=B[f]=B[h]=B[p]=B[v]=B[m]=B[y]=!1;function L(j){return r(j)&&t(j.length)&&!!B[e(j)]}return Zd=L,Zd}var Jd,rS;function Nc(){if(rS)return Jd;rS=1;function e(t){return function(r){return t(r)}}return Jd=e,Jd}var ba={exports:{}};ba.exports;var nS;function cx(){return nS||(nS=1,(function(e,t){var r=xD(),n=t&&!t.nodeType&&t,i=n&&!0&&e&&!e.nodeType&&e,o=i&&i.exports===n,a=o&&r.process,u=(function(){try{var c=i&&i.require&&i.require("util").types;return c||a&&a.binding&&a.binding("util")}catch{}})();e.exports=u})(ba,ba.exports)),ba.exports}var Qd,iS;function Va(){if(iS)return Qd;iS=1;var e=F4(),t=Nc(),r=cx(),n=r&&r.isTypedArray,i=n?t(n):e;return Qd=i,Qd}var eh,oS;function ED(){if(oS)return eh;oS=1;var e=k4(),t=Ua(),r=yt(),n=wo(),i=Pc(),o=Va(),a=Object.prototype,u=a.hasOwnProperty;function c(d,f){var h=r(d),p=!h&&t(d),v=!h&&!p&&n(d),m=!h&&!p&&!v&&o(d),y=h||p||v||m,x=y?e(d.length,String):[],b=x.length;for(var w in d)(f||u.call(d,w))&&!(y&&(w=="length"||v&&(w=="offset"||w=="parent")||m&&(w=="buffer"||w=="byteLength"||w=="byteOffset")||i(w,b)))&&x.push(w);return x}return eh=c,eh}var th,aS;function Tc(){if(aS)return th;aS=1;var e=Object.prototype;function t(r){var n=r&&r.constructor,i=typeof n=="function"&&n.prototype||e;return r===i}return th=t,th}var rh,sS;function SD(){if(sS)return rh;sS=1;function e(t,r){return function(n){return t(r(n))}}return rh=e,rh}var nh,uS;function $4(){if(uS)return nh;uS=1;var e=SD(),t=e(Object.keys,Object);return nh=t,nh}var ih,cS;function lx(){if(cS)return ih;cS=1;var e=Tc(),t=$4(),r=Object.prototype,n=r.hasOwnProperty;function i(o){if(!e(o))return t(o);var a=[];for(var u in Object(o))n.call(o,u)&&u!="constructor"&&a.push(u);return a}return ih=i,ih}var oh,lS;function En(){if(lS)return oh;lS=1;var e=za(),t=ux();function r(n){return n!=null&&t(n.length)&&!e(n)}return oh=r,oh}var ah,fS;function Wn(){if(fS)return ah;fS=1;var e=ED(),t=lx(),r=En();function n(i){return r(i)?e(i):t(i)}return ah=n,ah}var sh,dS;function z4(){if(dS)return sh;dS=1;var e=Ha(),t=Wn();function r(n,i){return n&&e(i,t(i),n)}return sh=r,sh}var uh,hS;function H4(){if(hS)return uh;hS=1;function e(t){var r=[];if(t!=null)for(var n in Object(t))r.push(n);return r}return uh=e,uh}var ch,pS;function U4(){if(pS)return ch;pS=1;var e=Or(),t=Tc(),r=H4(),n=Object.prototype,i=n.hasOwnProperty;function o(a){if(!e(a))return r(a);var u=t(a),c=[];for(var d in a)d=="constructor"&&(u||!i.call(a,d))||c.push(d);return c}return ch=o,ch}var lh,vS;function Ei(){if(vS)return lh;vS=1;var e=ED(),t=U4(),r=En();function n(i){return r(i)?e(i,!0):t(i)}return lh=n,lh}var fh,gS;function V4(){if(gS)return fh;gS=1;var e=Ha(),t=Ei();function r(n,i){return n&&e(i,t(i),n)}return fh=r,fh}var xa={exports:{}};xa.exports;var mS;function OD(){return mS||(mS=1,(function(e,t){var r=Fr(),n=t&&!t.nodeType&&t,i=n&&!0&&e&&!e.nodeType&&e,o=i&&i.exports===n,a=o?r.Buffer:void 0,u=a?a.allocUnsafe:void 0;function c(d,f){if(f)return d.slice();var h=d.length,p=u?u(h):new d.constructor(h);return d.copy(p),p}e.exports=c})(xa,xa.exports)),xa.exports}var dh,yS;function CD(){if(yS)return dh;yS=1;function e(t,r){var n=-1,i=t.length;for(r||(r=Array(i));++n<i;)r[n]=t[n];return r}return dh=e,dh}var hh,bS;function RD(){if(bS)return hh;bS=1;function e(t,r){for(var n=-1,i=t==null?0:t.length,o=0,a=[];++n<i;){var u=t[n];r(u,n,t)&&(a[o++]=u)}return a}return hh=e,hh}var ph,xS;function ID(){if(xS)return ph;xS=1;function e(){return[]}return ph=e,ph}var vh,wS;function fx(){if(wS)return vh;wS=1;var e=RD(),t=ID(),r=Object.prototype,n=r.propertyIsEnumerable,i=Object.getOwnPropertySymbols,o=i?function(a){return a==null?[]:(a=Object(a),e(i(a),function(u){return n.call(a,u)}))}:t;return vh=o,vh}var gh,_S;function W4(){if(_S)return gh;_S=1;var e=Ha(),t=fx();function r(n,i){return e(n,t(n),i)}return gh=r,gh}var mh,ES;function dx(){if(ES)return mh;ES=1;function e(t,r){for(var n=-1,i=r.length,o=t.length;++n<i;)t[o+n]=r[n];return t}return mh=e,mh}var yh,SS;function Ac(){if(SS)return yh;SS=1;var e=SD(),t=e(Object.getPrototypeOf,Object);return yh=t,yh}var bh,OS;function PD(){if(OS)return bh;OS=1;var e=dx(),t=Ac(),r=fx(),n=ID(),i=Object.getOwnPropertySymbols,o=i?function(a){for(var u=[];a;)e(u,r(a)),a=t(a);return u}:n;return bh=o,bh}var xh,CS;function G4(){if(CS)return xh;CS=1;var e=Ha(),t=PD();function r(n,i){return e(n,t(n),i)}return xh=r,xh}var wh,RS;function ND(){if(RS)return wh;RS=1;var e=dx(),t=yt();function r(n,i,o){var a=i(n);return t(n)?a:e(a,o(n))}return wh=r,wh}var _h,IS;function TD(){if(IS)return _h;IS=1;var e=ND(),t=fx(),r=Wn();function n(i){return e(i,r,t)}return _h=n,_h}var Eh,PS;function K4(){if(PS)return Eh;PS=1;var e=ND(),t=PD(),r=Ei();function n(i){return e(i,r,t)}return Eh=n,Eh}var Sh,NS;function Y4(){if(NS)return Sh;NS=1;var e=_i(),t=Fr(),r=e(t,"DataView");return Sh=r,Sh}var Oh,TS;function X4(){if(TS)return Oh;TS=1;var e=_i(),t=Fr(),r=e(t,"Promise");return Oh=r,Oh}var Ch,AS;function AD(){if(AS)return Ch;AS=1;var e=_i(),t=Fr(),r=e(t,"Set");return Ch=r,Ch}var Rh,MS;function Z4(){if(MS)return Rh;MS=1;var e=_i(),t=Fr(),r=e(t,"WeakMap");return Rh=r,Rh}var Ih,DS;function _o(){if(DS)return Ih;DS=1;var e=Y4(),t=ox(),r=X4(),n=AD(),i=Z4(),o=wi(),a=wD(),u="[object Map]",c="[object Object]",d="[object Promise]",f="[object Set]",h="[object WeakMap]",p="[object DataView]",v=a(e),m=a(t),y=a(r),x=a(n),b=a(i),w=o;return(e&&w(new e(new ArrayBuffer(1)))!=p||t&&w(new t)!=u||r&&w(r.resolve())!=d||n&&w(new n)!=f||i&&w(new i)!=h)&&(w=function(S){var E=o(S),_=E==c?S.constructor:void 0,R=_?a(_):"";if(R)switch(R){case v:return p;case m:return u;case y:return d;case x:return f;case b:return h}return E}),Ih=w,Ih}var Ph,jS;function J4(){if(jS)return Ph;jS=1;var e=Object.prototype,t=e.hasOwnProperty;function r(n){var i=n.length,o=new n.constructor(i);return i&&typeof n[0]=="string"&&t.call(n,"index")&&(o.index=n.index,o.input=n.input),o}return Ph=r,Ph}var Nh,qS;function MD(){if(qS)return Nh;qS=1;var e=Fr(),t=e.Uint8Array;return Nh=t,Nh}var Th,kS;function hx(){if(kS)return Th;kS=1;var e=MD();function t(r){var n=new r.constructor(r.byteLength);return new e(n).set(new e(r)),n}return Th=t,Th}var Ah,LS;function Q4(){if(LS)return Ah;LS=1;var e=hx();function t(r,n){var i=n?e(r.buffer):r.buffer;return new r.constructor(i,r.byteOffset,r.byteLength)}return Ah=t,Ah}var Mh,BS;function eU(){if(BS)return Mh;BS=1;var e=/\w*$/;function t(r){var n=new r.constructor(r.source,e.exec(r));return n.lastIndex=r.lastIndex,n}return Mh=t,Mh}var Dh,FS;function tU(){if(FS)return Dh;FS=1;var e=xo(),t=e?e.prototype:void 0,r=t?t.valueOf:void 0;function n(i){return r?Object(r.call(i)):{}}return Dh=n,Dh}var jh,$S;function DD(){if($S)return jh;$S=1;var e=hx();function t(r,n){var i=n?e(r.buffer):r.buffer;return new r.constructor(i,r.byteOffset,r.length)}return jh=t,jh}var qh,zS;function rU(){if(zS)return qh;zS=1;var e=hx(),t=Q4(),r=eU(),n=tU(),i=DD(),o="[object Boolean]",a="[object Date]",u="[object Map]",c="[object Number]",d="[object RegExp]",f="[object Set]",h="[object String]",p="[object Symbol]",v="[object ArrayBuffer]",m="[object DataView]",y="[object Float32Array]",x="[object Float64Array]",b="[object Int8Array]",w="[object Int16Array]",S="[object Int32Array]",E="[object Uint8Array]",_="[object Uint8ClampedArray]",R="[object Uint16Array]",I="[object Uint32Array]";function N(D,k,B){var L=D.constructor;switch(k){case v:return e(D);case o:case a:return new L(+D);case m:return t(D,B);case y:case x:case b:case w:case S:case E:case _:case R:case I:return i(D,B);case u:return new L;case c:case h:return new L(D);case d:return r(D);case f:return new L;case p:return n(D)}}return qh=N,qh}var kh,HS;function jD(){if(HS)return kh;HS=1;var e=Or(),t=Object.create,r=(function(){function n(){}return function(i){if(!e(i))return{};if(t)return t(i);n.prototype=i;var o=new n;return n.prototype=void 0,o}})();return kh=r,kh}var Lh,US;function qD(){if(US)return Lh;US=1;var e=jD(),t=Ac(),r=Tc();function n(i){return typeof i.constructor=="function"&&!r(i)?e(t(i)):{}}return Lh=n,Lh}var Bh,VS;function nU(){if(VS)return Bh;VS=1;var e=_o(),t=on(),r="[object Map]";function n(i){return t(i)&&e(i)==r}return Bh=n,Bh}var Fh,WS;function iU(){if(WS)return Fh;WS=1;var e=nU(),t=Nc(),r=cx(),n=r&&r.isMap,i=n?t(n):e;return Fh=i,Fh}var $h,GS;function oU(){if(GS)return $h;GS=1;var e=_o(),t=on(),r="[object Set]";function n(i){return t(i)&&e(i)==r}return $h=n,$h}var zh,KS;function aU(){if(KS)return zh;KS=1;var e=oU(),t=Nc(),r=cx(),n=r&&r.isSet,i=n?t(n):e;return zh=i,zh}var Hh,YS;function kD(){if(YS)return Hh;YS=1;var e=Cc(),t=sx(),r=Ic(),n=z4(),i=V4(),o=OD(),a=CD(),u=W4(),c=G4(),d=TD(),f=K4(),h=_o(),p=J4(),v=rU(),m=qD(),y=yt(),x=wo(),b=iU(),w=Or(),S=aU(),E=Wn(),_=Ei(),R=1,I=2,N=4,D="[object Arguments]",k="[object Array]",B="[object Boolean]",L="[object Date]",j="[object Error]",T="[object Function]",F="[object GeneratorFunction]",$="[object Map]",W="[object Number]",Y="[object Object]",ee="[object RegExp]",H="[object Set]",Q="[object String]",ce="[object Symbol]",se="[object WeakMap]",z="[object ArrayBuffer]",G="[object DataView]",J="[object Float32Array]",V="[object Float64Array]",K="[object Int8Array]",ie="[object Int16Array]",ne="[object Int32Array]",ue="[object Uint8Array]",de="[object Uint8ClampedArray]",we="[object Uint16Array]",Se="[object Uint32Array]",_e={};_e[D]=_e[k]=_e[z]=_e[G]=_e[B]=_e[L]=_e[J]=_e[V]=_e[K]=_e[ie]=_e[ne]=_e[$]=_e[W]=_e[Y]=_e[ee]=_e[H]=_e[Q]=_e[ce]=_e[ue]=_e[de]=_e[we]=_e[Se]=!0,_e[j]=_e[T]=_e[se]=!1;function he(ae,Oe,Ne,He,qe,Xe){var We,mt=Oe&R,et=Oe&I,Tt=Oe&N;if(Ne&&(We=qe?Ne(ae,He,qe,Xe):Ne(ae)),We!==void 0)return We;if(!w(ae))return ae;var ut=y(ae);if(ut){if(We=p(ae),!mt)return a(ae,We)}else{var tt=h(ae),Ct=tt==T||tt==F;if(x(ae))return o(ae,mt);if(tt==Y||tt==D||Ct&&!qe){if(We=et||Ct?{}:m(ae),!mt)return et?c(ae,i(We,ae)):u(ae,n(We,ae))}else{if(!_e[tt])return qe?ae:{};We=v(ae,tt,mt)}}Xe||(Xe=new e);var Jt=Xe.get(ae);if(Jt)return Jt;Xe.set(ae,We),S(ae)?ae.forEach(function(xt){We.add(he(xt,Oe,Ne,xt,ae,Xe))}):b(ae)&&ae.forEach(function(xt,jt){We.set(jt,he(xt,Oe,Ne,jt,ae,Xe))});var lr=Tt?et?f:d:et?_:E,Dt=ut?void 0:lr(ae);return t(Dt||ae,function(xt,jt){Dt&&(jt=xt,xt=ae[jt]),r(We,jt,he(xt,Oe,Ne,jt,ae,Xe))}),We}return Hh=he,Hh}var Uh,XS;function sU(){if(XS)return Uh;XS=1;var e=kD(),t=4;function r(n){return e(n,t)}return Uh=r,Uh}var Vh,ZS;function px(){if(ZS)return Vh;ZS=1;function e(t){return function(){return t}}return Vh=e,Vh}var Wh,JS;function uU(){if(JS)return Wh;JS=1;function e(t){return function(r,n,i){for(var o=-1,a=Object(r),u=i(r),c=u.length;c--;){var d=u[t?c:++o];if(n(a[d],d,a)===!1)break}return r}}return Wh=e,Wh}var Gh,QS;function vx(){if(QS)return Gh;QS=1;var e=uU(),t=e();return Gh=t,Gh}var Kh,eO;function gx(){if(eO)return Kh;eO=1;var e=vx(),t=Wn();function r(n,i){return n&&e(n,i,t)}return Kh=r,Kh}var Yh,tO;function cU(){if(tO)return Yh;tO=1;var e=En();function t(r,n){return function(i,o){if(i==null)return i;if(!e(i))return r(i,o);for(var a=i.length,u=n?a:-1,c=Object(i);(n?u--:++u<a)&&o(c[u],u,c)!==!1;);return i}}return Yh=t,Yh}var Xh,rO;function Mc(){if(rO)return Xh;rO=1;var e=gx(),t=cU(),r=t(e);return Xh=r,Xh}var Zh,nO;function Si(){if(nO)return Zh;nO=1;function e(t){return t}return Zh=e,Zh}var Jh,iO;function LD(){if(iO)return Jh;iO=1;var e=Si();function t(r){return typeof r=="function"?r:e}return Jh=t,Jh}var Qh,oO;function BD(){if(oO)return Qh;oO=1;var e=sx(),t=Mc(),r=LD(),n=yt();function i(o,a){var u=n(o)?e:t;return u(o,r(a))}return Qh=i,Qh}var ep,aO;function FD(){return aO||(aO=1,ep=BD()),ep}var tp,sO;function lU(){if(sO)return tp;sO=1;var e=Mc();function t(r,n){var i=[];return e(r,function(o,a,u){n(o,a,u)&&i.push(o)}),i}return tp=t,tp}var rp,uO;function fU(){if(uO)return rp;uO=1;var e="__lodash_hash_undefined__";function t(r){return this.__data__.set(r,e),this}return rp=t,rp}var np,cO;function dU(){if(cO)return np;cO=1;function e(t){return this.__data__.has(t)}return np=e,np}var ip,lO;function $D(){if(lO)return ip;lO=1;var e=ax(),t=fU(),r=dU();function n(i){var o=-1,a=i==null?0:i.length;for(this.__data__=new e;++o<a;)this.add(i[o])}return n.prototype.add=n.prototype.push=t,n.prototype.has=r,ip=n,ip}var op,fO;function hU(){if(fO)return op;fO=1;function e(t,r){for(var n=-1,i=t==null?0:t.length;++n<i;)if(r(t[n],n,t))return!0;return!1}return op=e,op}var ap,dO;function zD(){if(dO)return ap;dO=1;function e(t,r){return t.has(r)}return ap=e,ap}var sp,hO;function HD(){if(hO)return sp;hO=1;var e=$D(),t=hU(),r=zD(),n=1,i=2;function o(a,u,c,d,f,h){var p=c&n,v=a.length,m=u.length;if(v!=m&&!(p&&m>v))return!1;var y=h.get(a),x=h.get(u);if(y&&x)return y==u&&x==a;var b=-1,w=!0,S=c&i?new e:void 0;for(h.set(a,u),h.set(u,a);++b<v;){var E=a[b],_=u[b];if(d)var R=p?d(_,E,b,u,a,h):d(E,_,b,a,u,h);if(R!==void 0){if(R)continue;w=!1;break}if(S){if(!t(u,function(I,N){if(!r(S,N)&&(E===I||f(E,I,c,d,h)))return S.push(N)})){w=!1;break}}else if(!(E===_||f(E,_,c,d,h))){w=!1;break}}return h.delete(a),h.delete(u),w}return sp=o,sp}var up,pO;function pU(){if(pO)return up;pO=1;function e(t){var r=-1,n=Array(t.size);return t.forEach(function(i,o){n[++r]=[o,i]}),n}return up=e,up}var cp,vO;function mx(){if(vO)return cp;vO=1;function e(t){var r=-1,n=Array(t.size);return t.forEach(function(i){n[++r]=i}),n}return cp=e,cp}var lp,gO;function vU(){if(gO)return lp;gO=1;var e=xo(),t=MD(),r=bo(),n=HD(),i=pU(),o=mx(),a=1,u=2,c="[object Boolean]",d="[object Date]",f="[object Error]",h="[object Map]",p="[object Number]",v="[object RegExp]",m="[object Set]",y="[object String]",x="[object Symbol]",b="[object ArrayBuffer]",w="[object DataView]",S=e?e.prototype:void 0,E=S?S.valueOf:void 0;function _(R,I,N,D,k,B,L){switch(N){case w:if(R.byteLength!=I.byteLength||R.byteOffset!=I.byteOffset)return!1;R=R.buffer,I=I.buffer;case b:return!(R.byteLength!=I.byteLength||!B(new t(R),new t(I)));case c:case d:case p:return r(+R,+I);case f:return R.name==I.name&&R.message==I.message;case v:case y:return R==I+"";case h:var j=i;case m:var T=D&a;if(j||(j=o),R.size!=I.size&&!T)return!1;var F=L.get(R);if(F)return F==I;D|=u,L.set(R,I);var $=n(j(R),j(I),D,k,B,L);return L.delete(R),$;case x:if(E)return E.call(R)==E.call(I)}return!1}return lp=_,lp}var fp,mO;function gU(){if(mO)return fp;mO=1;var e=TD(),t=1,r=Object.prototype,n=r.hasOwnProperty;function i(o,a,u,c,d,f){var h=u&t,p=e(o),v=p.length,m=e(a),y=m.length;if(v!=y&&!h)return!1;for(var x=v;x--;){var b=p[x];if(!(h?b in a:n.call(a,b)))return!1}var w=f.get(o),S=f.get(a);if(w&&S)return w==a&&S==o;var E=!0;f.set(o,a),f.set(a,o);for(var _=h;++x<v;){b=p[x];var R=o[b],I=a[b];if(c)var N=h?c(I,R,b,a,o,f):c(R,I,b,o,a,f);if(!(N===void 0?R===I||d(R,I,u,c,f):N)){E=!1;break}_||(_=b=="constructor")}if(E&&!_){var D=o.constructor,k=a.constructor;D!=k&&"constructor"in o&&"constructor"in a&&!(typeof D=="function"&&D instanceof D&&typeof k=="function"&&k instanceof k)&&(E=!1)}return f.delete(o),f.delete(a),E}return fp=i,fp}var dp,yO;function mU(){if(yO)return dp;yO=1;var e=Cc(),t=HD(),r=vU(),n=gU(),i=_o(),o=yt(),a=wo(),u=Va(),c=1,d="[object Arguments]",f="[object Array]",h="[object Object]",p=Object.prototype,v=p.hasOwnProperty;function m(y,x,b,w,S,E){var _=o(y),R=o(x),I=_?f:i(y),N=R?f:i(x);I=I==d?h:I,N=N==d?h:N;var D=I==h,k=N==h,B=I==N;if(B&&a(y)){if(!a(x))return!1;_=!0,D=!1}if(B&&!D)return E||(E=new e),_||u(y)?t(y,x,b,w,S,E):r(y,x,I,b,w,S,E);if(!(b&c)){var L=D&&v.call(y,"__wrapped__"),j=k&&v.call(x,"__wrapped__");if(L||j){var T=L?y.value():y,F=j?x.value():x;return E||(E=new e),S(T,F,b,w,E)}}return B?(E||(E=new e),n(y,x,b,w,S,E)):!1}return dp=m,dp}var hp,bO;function UD(){if(bO)return hp;bO=1;var e=mU(),t=on();function r(n,i,o,a,u){return n===i?!0:n==null||i==null||!t(n)&&!t(i)?n!==n&&i!==i:e(n,i,o,a,r,u)}return hp=r,hp}var pp,xO;function yU(){if(xO)return pp;xO=1;var e=Cc(),t=UD(),r=1,n=2;function i(o,a,u,c){var d=u.length,f=d,h=!c;if(o==null)return!f;for(o=Object(o);d--;){var p=u[d];if(h&&p[2]?p[1]!==o[p[0]]:!(p[0]in o))return!1}for(;++d<f;){p=u[d];var v=p[0],m=o[v],y=p[1];if(h&&p[2]){if(m===void 0&&!(v in o))return!1}else{var x=new e;if(c)var b=c(m,y,v,o,a,x);if(!(b===void 0?t(y,m,r|n,c,x):b))return!1}}return!0}return pp=i,pp}var vp,wO;function VD(){if(wO)return vp;wO=1;var e=Or();function t(r){return r===r&&!e(r)}return vp=t,vp}var gp,_O;function bU(){if(_O)return gp;_O=1;var e=VD(),t=Wn();function r(n){for(var i=t(n),o=i.length;o--;){var a=i[o],u=n[a];i[o]=[a,u,e(u)]}return i}return gp=r,gp}var mp,EO;function WD(){if(EO)return mp;EO=1;function e(t,r){return function(n){return n==null?!1:n[t]===r&&(r!==void 0||t in Object(n))}}return mp=e,mp}var yp,SO;function xU(){if(SO)return yp;SO=1;var e=yU(),t=bU(),r=WD();function n(i){var o=t(i);return o.length==1&&o[0][2]?r(o[0][0],o[0][1]):function(a){return a===i||e(a,i,o)}}return yp=n,yp}var bp,OO;function Eo(){if(OO)return bp;OO=1;var e=wi(),t=on(),r="[object Symbol]";function n(i){return typeof i=="symbol"||t(i)&&e(i)==r}return bp=n,bp}var xp,CO;function yx(){if(CO)return xp;CO=1;var e=yt(),t=Eo(),r=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,n=/^\w*$/;function i(o,a){if(e(o))return!1;var u=typeof o;return u=="number"||u=="symbol"||u=="boolean"||o==null||t(o)?!0:n.test(o)||!r.test(o)||a!=null&&o in Object(a)}return xp=i,xp}var wp,RO;function wU(){if(RO)return wp;RO=1;var e=ax(),t="Expected a function";function r(n,i){if(typeof n!="function"||i!=null&&typeof i!="function")throw new TypeError(t);var o=function(){var a=arguments,u=i?i.apply(this,a):a[0],c=o.cache;if(c.has(u))return c.get(u);var d=n.apply(this,a);return o.cache=c.set(u,d)||c,d};return o.cache=new(r.Cache||e),o}return r.Cache=e,wp=r,wp}var _p,IO;function _U(){if(IO)return _p;IO=1;var e=wU(),t=500;function r(n){var i=e(n,function(a){return o.size===t&&o.clear(),a}),o=i.cache;return i}return _p=r,_p}var Ep,PO;function EU(){if(PO)return Ep;PO=1;var e=_U(),t=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,r=/\\(\\)?/g,n=e(function(i){var o=[];return i.charCodeAt(0)===46&&o.push(""),i.replace(t,function(a,u,c,d){o.push(c?d.replace(r,"$1"):u||a)}),o});return Ep=n,Ep}var Sp,NO;function Dc(){if(NO)return Sp;NO=1;function e(t,r){for(var n=-1,i=t==null?0:t.length,o=Array(i);++n<i;)o[n]=r(t[n],n,t);return o}return Sp=e,Sp}var Op,TO;function SU(){if(TO)return Op;TO=1;var e=xo(),t=Dc(),r=yt(),n=Eo(),i=e?e.prototype:void 0,o=i?i.toString:void 0;function a(u){if(typeof u=="string")return u;if(r(u))return t(u,a)+"";if(n(u))return o?o.call(u):"";var c=u+"";return c=="0"&&1/u==-1/0?"-0":c}return Op=a,Op}var Cp,AO;function GD(){if(AO)return Cp;AO=1;var e=SU();function t(r){return r==null?"":e(r)}return Cp=t,Cp}var Rp,MO;function jc(){if(MO)return Rp;MO=1;var e=yt(),t=yx(),r=EU(),n=GD();function i(o,a){return e(o)?o:t(o,a)?[o]:r(n(o))}return Rp=i,Rp}var Ip,DO;function Wa(){if(DO)return Ip;DO=1;var e=Eo();function t(r){if(typeof r=="string"||e(r))return r;var n=r+"";return n=="0"&&1/r==-1/0?"-0":n}return Ip=t,Ip}var Pp,jO;function qc(){if(jO)return Pp;jO=1;var e=jc(),t=Wa();function r(n,i){i=e(i,n);for(var o=0,a=i.length;n!=null&&o<a;)n=n[t(i[o++])];return o&&o==a?n:void 0}return Pp=r,Pp}var Np,qO;function OU(){if(qO)return Np;qO=1;var e=qc();function t(r,n,i){var o=r==null?void 0:e(r,n);return o===void 0?i:o}return Np=t,Np}var Tp,kO;function CU(){if(kO)return Tp;kO=1;function e(t,r){return t!=null&&r in Object(t)}return Tp=e,Tp}var Ap,LO;function KD(){if(LO)return Ap;LO=1;var e=jc(),t=Ua(),r=yt(),n=Pc(),i=ux(),o=Wa();function a(u,c,d){c=e(c,u);for(var f=-1,h=c.length,p=!1;++f<h;){var v=o(c[f]);if(!(p=u!=null&&d(u,v)))break;u=u[v]}return p||++f!=h?p:(h=u==null?0:u.length,!!h&&i(h)&&n(v,h)&&(r(u)||t(u)))}return Ap=a,Ap}var Mp,BO;function YD(){if(BO)return Mp;BO=1;var e=CU(),t=KD();function r(n,i){return n!=null&&t(n,i,e)}return Mp=r,Mp}var Dp,FO;function RU(){if(FO)return Dp;FO=1;var e=UD(),t=OU(),r=YD(),n=yx(),i=VD(),o=WD(),a=Wa(),u=1,c=2;function d(f,h){return n(f)&&i(h)?o(a(f),h):function(p){var v=t(p,f);return v===void 0&&v===h?r(p,f):e(h,v,u|c)}}return Dp=d,Dp}var jp,$O;function XD(){if($O)return jp;$O=1;function e(t){return function(r){return r==null?void 0:r[t]}}return jp=e,jp}var qp,zO;function IU(){if(zO)return qp;zO=1;var e=qc();function t(r){return function(n){return e(n,r)}}return qp=t,qp}var kp,HO;function PU(){if(HO)return kp;HO=1;var e=XD(),t=IU(),r=yx(),n=Wa();function i(o){return r(o)?e(n(o)):t(o)}return kp=i,kp}var Lp,UO;function Sn(){if(UO)return Lp;UO=1;var e=xU(),t=RU(),r=Si(),n=yt(),i=PU();function o(a){return typeof a=="function"?a:a==null?r:typeof a=="object"?n(a)?t(a[0],a[1]):e(a):i(a)}return Lp=o,Lp}var Bp,VO;function ZD(){if(VO)return Bp;VO=1;var e=RD(),t=lU(),r=Sn(),n=yt();function i(o,a){var u=n(o)?e:t;return u(o,r(a,3))}return Bp=i,Bp}var Fp,WO;function NU(){if(WO)return Fp;WO=1;var e=Object.prototype,t=e.hasOwnProperty;function r(n,i){return n!=null&&t.call(n,i)}return Fp=r,Fp}var $p,GO;function JD(){if(GO)return $p;GO=1;var e=NU(),t=KD();function r(n,i){return n!=null&&t(n,i,e)}return $p=r,$p}var zp,KO;function TU(){if(KO)return zp;KO=1;var e=lx(),t=_o(),r=Ua(),n=yt(),i=En(),o=wo(),a=Tc(),u=Va(),c="[object Map]",d="[object Set]",f=Object.prototype,h=f.hasOwnProperty;function p(v){if(v==null)return!0;if(i(v)&&(n(v)||typeof v=="string"||typeof v.splice=="function"||o(v)||u(v)||r(v)))return!v.length;var m=t(v);if(m==c||m==d)return!v.size;if(a(v))return!e(v).length;for(var y in v)if(h.call(v,y))return!1;return!0}return zp=p,zp}var Hp,YO;function QD(){if(YO)return Hp;YO=1;function e(t){return t===void 0}return Hp=e,Hp}var Up,XO;function ej(){if(XO)return Up;XO=1;var e=Mc(),t=En();function r(n,i){var o=-1,a=t(n)?Array(n.length):[];return e(n,function(u,c,d){a[++o]=i(u,c,d)}),a}return Up=r,Up}var Vp,ZO;function tj(){if(ZO)return Vp;ZO=1;var e=Dc(),t=Sn(),r=ej(),n=yt();function i(o,a){var u=n(o)?e:r;return u(o,t(a,3))}return Vp=i,Vp}var Wp,JO;function AU(){if(JO)return Wp;JO=1;function e(t,r,n,i){var o=-1,a=t==null?0:t.length;for(i&&a&&(n=t[++o]);++o<a;)n=r(n,t[o],o,t);return n}return Wp=e,Wp}var Gp,QO;function MU(){if(QO)return Gp;QO=1;function e(t,r,n,i,o){return o(t,function(a,u,c){n=i?(i=!1,a):r(n,a,u,c)}),n}return Gp=e,Gp}var Kp,eC;function rj(){if(eC)return Kp;eC=1;var e=AU(),t=Mc(),r=Sn(),n=MU(),i=yt();function o(a,u,c){var d=i(a)?e:n,f=arguments.length<3;return d(a,r(u,4),c,f,t)}return Kp=o,Kp}var Yp,tC;function DU(){if(tC)return Yp;tC=1;var e=wi(),t=yt(),r=on(),n="[object String]";function i(o){return typeof o=="string"||!t(o)&&r(o)&&e(o)==n}return Yp=i,Yp}var Xp,rC;function jU(){if(rC)return Xp;rC=1;var e=XD(),t=e("length");return Xp=t,Xp}var Zp,nC;function qU(){if(nC)return Zp;nC=1;var e="\\ud800-\\udfff",t="\\u0300-\\u036f",r="\\ufe20-\\ufe2f",n="\\u20d0-\\u20ff",i=t+r+n,o="\\ufe0e\\ufe0f",a="\\u200d",u=RegExp("["+a+e+i+o+"]");function c(d){return u.test(d)}return Zp=c,Zp}var Jp,iC;function kU(){if(iC)return Jp;iC=1;var e="\\ud800-\\udfff",t="\\u0300-\\u036f",r="\\ufe20-\\ufe2f",n="\\u20d0-\\u20ff",i=t+r+n,o="\\ufe0e\\ufe0f",a="["+e+"]",u="["+i+"]",c="\\ud83c[\\udffb-\\udfff]",d="(?:"+u+"|"+c+")",f="[^"+e+"]",h="(?:\\ud83c[\\udde6-\\uddff]){2}",p="[\\ud800-\\udbff][\\udc00-\\udfff]",v="\\u200d",m=d+"?",y="["+o+"]?",x="(?:"+v+"(?:"+[f,h,p].join("|")+")"+y+m+")*",b=y+m+x,w="(?:"+[f+u+"?",u,h,p,a].join("|")+")",S=RegExp(c+"(?="+c+")|"+w+b,"g");function E(_){for(var R=S.lastIndex=0;S.test(_);)++R;return R}return Jp=E,Jp}var Qp,oC;function LU(){if(oC)return Qp;oC=1;var e=jU(),t=qU(),r=kU();function n(i){return t(i)?r(i):e(i)}return Qp=n,Qp}var ev,aC;function BU(){if(aC)return ev;aC=1;var e=lx(),t=_o(),r=En(),n=DU(),i=LU(),o="[object Map]",a="[object Set]";function u(c){if(c==null)return 0;if(r(c))return n(c)?i(c):c.length;var d=t(c);return d==o||d==a?c.size:e(c).length}return ev=u,ev}var tv,sC;function FU(){if(sC)return tv;sC=1;var e=sx(),t=jD(),r=gx(),n=Sn(),i=Ac(),o=yt(),a=wo(),u=za(),c=Or(),d=Va();function f(h,p,v){var m=o(h),y=m||a(h)||d(h);if(p=n(p,4),v==null){var x=h&&h.constructor;y?v=m?new x:[]:c(h)?v=u(x)?t(i(h)):{}:v={}}return(y?e:r)(h,function(b,w,S){return p(v,b,w,S)}),v}return tv=f,tv}var rv,uC;function $U(){if(uC)return rv;uC=1;var e=xo(),t=Ua(),r=yt(),n=e?e.isConcatSpreadable:void 0;function i(o){return r(o)||t(o)||!!(n&&o&&o[n])}return rv=i,rv}var nv,cC;function bx(){if(cC)return nv;cC=1;var e=dx(),t=$U();function r(n,i,o,a,u){var c=-1,d=n.length;for(o||(o=t),u||(u=[]);++c<d;){var f=n[c];i>0&&o(f)?i>1?r(f,i-1,o,a,u):e(u,f):a||(u[u.length]=f)}return u}return nv=r,nv}var iv,lC;function zU(){if(lC)return iv;lC=1;function e(t,r,n){switch(n.length){case 0:return t.call(r);case 1:return t.call(r,n[0]);case 2:return t.call(r,n[0],n[1]);case 3:return t.call(r,n[0],n[1],n[2])}return t.apply(r,n)}return iv=e,iv}var ov,fC;function nj(){if(fC)return ov;fC=1;var e=zU(),t=Math.max;function r(n,i,o){return i=t(i===void 0?n.length-1:i,0),function(){for(var a=arguments,u=-1,c=t(a.length-i,0),d=Array(c);++u<c;)d[u]=a[i+u];u=-1;for(var f=Array(i+1);++u<i;)f[u]=a[u];return f[i]=o(d),e(n,this,f)}}return ov=r,ov}var av,dC;function HU(){if(dC)return av;dC=1;var e=px(),t=_D(),r=Si(),n=t?function(i,o){return t(i,"toString",{configurable:!0,enumerable:!1,value:e(o),writable:!0})}:r;return av=n,av}var sv,hC;function UU(){if(hC)return sv;hC=1;var e=800,t=16,r=Date.now;function n(i){var o=0,a=0;return function(){var u=r(),c=t-(u-a);if(a=u,c>0){if(++o>=e)return arguments[0]}else o=0;return i.apply(void 0,arguments)}}return sv=n,sv}var uv,pC;function ij(){if(pC)return uv;pC=1;var e=HU(),t=UU(),r=t(e);return uv=r,uv}var cv,vC;function kc(){if(vC)return cv;vC=1;var e=Si(),t=nj(),r=ij();function n(i,o){return r(t(i,o,e),i+"")}return cv=n,cv}var lv,gC;function oj(){if(gC)return lv;gC=1;function e(t,r,n,i){for(var o=t.length,a=n+(i?1:-1);i?a--:++a<o;)if(r(t[a],a,t))return a;return-1}return lv=e,lv}var fv,mC;function VU(){if(mC)return fv;mC=1;function e(t){return t!==t}return fv=e,fv}var dv,yC;function WU(){if(yC)return dv;yC=1;function e(t,r,n){for(var i=n-1,o=t.length;++i<o;)if(t[i]===r)return i;return-1}return dv=e,dv}var hv,bC;function GU(){if(bC)return hv;bC=1;var e=oj(),t=VU(),r=WU();function n(i,o,a){return o===o?r(i,o,a):e(i,t,a)}return hv=n,hv}var pv,xC;function KU(){if(xC)return pv;xC=1;var e=GU();function t(r,n){var i=r==null?0:r.length;return!!i&&e(r,n,0)>-1}return pv=t,pv}var vv,wC;function YU(){if(wC)return vv;wC=1;function e(t,r,n){for(var i=-1,o=t==null?0:t.length;++i<o;)if(n(r,t[i]))return!0;return!1}return vv=e,vv}var gv,_C;function XU(){if(_C)return gv;_C=1;function e(){}return gv=e,gv}var mv,EC;function ZU(){if(EC)return mv;EC=1;var e=AD(),t=XU(),r=mx(),n=1/0,i=e&&1/r(new e([,-0]))[1]==n?function(o){return new e(o)}:t;return mv=i,mv}var yv,SC;function JU(){if(SC)return yv;SC=1;var e=$D(),t=KU(),r=YU(),n=zD(),i=ZU(),o=mx(),a=200;function u(c,d,f){var h=-1,p=t,v=c.length,m=!0,y=[],x=y;if(f)m=!1,p=r;else if(v>=a){var b=d?null:i(c);if(b)return o(b);m=!1,p=n,x=new e}else x=d?[]:y;e:for(;++h<v;){var w=c[h],S=d?d(w):w;if(w=f||w!==0?w:0,m&&S===S){for(var E=x.length;E--;)if(x[E]===S)continue e;d&&x.push(S),y.push(w)}else p(x,S,f)||(x!==y&&x.push(S),y.push(w))}return y}return yv=u,yv}var bv,OC;function aj(){if(OC)return bv;OC=1;var e=En(),t=on();function r(n){return t(n)&&e(n)}return bv=r,bv}var xv,CC;function QU(){if(CC)return xv;CC=1;var e=bx(),t=kc(),r=JU(),n=aj(),i=t(function(o){return r(e(o,1,n,!0))});return xv=i,xv}var wv,RC;function eV(){if(RC)return wv;RC=1;var e=Dc();function t(r,n){return e(n,function(i){return r[i]})}return wv=t,wv}var _v,IC;function sj(){if(IC)return _v;IC=1;var e=eV(),t=Wn();function r(n){return n==null?[]:e(n,t(n))}return _v=r,_v}var Ev,PC;function Cr(){if(PC)return Ev;PC=1;var e;if(typeof ix=="function")try{e={clone:sU(),constant:px(),each:FD(),filter:ZD(),has:JD(),isArray:yt(),isEmpty:TU(),isFunction:za(),isUndefined:QD(),keys:Wn(),map:tj(),reduce:rj(),size:BU(),transform:FU(),union:QU(),values:sj()}}catch{}return e||(e=window._),Ev=e,Ev}var Sv,NC;function xx(){if(NC)return Sv;NC=1;var e=Cr();Sv=i;var t="\0",r="\0",n="";function i(f){this._isDirected=e.has(f,"directed")?f.directed:!0,this._isMultigraph=e.has(f,"multigraph")?f.multigraph:!1,this._isCompound=e.has(f,"compound")?f.compound:!1,this._label=void 0,this._defaultNodeLabelFn=e.constant(void 0),this._defaultEdgeLabelFn=e.constant(void 0),this._nodes={},this._isCompound&&(this._parent={},this._children={},this._children[r]={}),this._in={},this._preds={},this._out={},this._sucs={},this._edgeObjs={},this._edgeLabels={}}i.prototype._nodeCount=0,i.prototype._edgeCount=0,i.prototype.isDirected=function(){return this._isDirected},i.prototype.isMultigraph=function(){return this._isMultigraph},i.prototype.isCompound=function(){return this._isCompound},i.prototype.setGraph=function(f){return this._label=f,this},i.prototype.graph=function(){return this._label},i.prototype.setDefaultNodeLabel=function(f){return e.isFunction(f)||(f=e.constant(f)),this._defaultNodeLabelFn=f,this},i.prototype.nodeCount=function(){return this._nodeCount},i.prototype.nodes=function(){return e.keys(this._nodes)},i.prototype.sources=function(){var f=this;return e.filter(this.nodes(),function(h){return e.isEmpty(f._in[h])})},i.prototype.sinks=function(){var f=this;return e.filter(this.nodes(),function(h){return e.isEmpty(f._out[h])})},i.prototype.setNodes=function(f,h){var p=arguments,v=this;return e.each(f,function(m){p.length>1?v.setNode(m,h):v.setNode(m)}),this},i.prototype.setNode=function(f,h){return e.has(this._nodes,f)?(arguments.length>1&&(this._nodes[f]=h),this):(this._nodes[f]=arguments.length>1?h:this._defaultNodeLabelFn(f),this._isCompound&&(this._parent[f]=r,this._children[f]={},this._children[r][f]=!0),this._in[f]={},this._preds[f]={},this._out[f]={},this._sucs[f]={},++this._nodeCount,this)},i.prototype.node=function(f){return this._nodes[f]},i.prototype.hasNode=function(f){return e.has(this._nodes,f)},i.prototype.removeNode=function(f){var h=this;if(e.has(this._nodes,f)){var p=function(v){h.removeEdge(h._edgeObjs[v])};delete this._nodes[f],this._isCompound&&(this._removeFromParentsChildList(f),delete this._parent[f],e.each(this.children(f),function(v){h.setParent(v)}),delete this._children[f]),e.each(e.keys(this._in[f]),p),delete this._in[f],delete this._preds[f],e.each(e.keys(this._out[f]),p),delete this._out[f],delete this._sucs[f],--this._nodeCount}return this},i.prototype.setParent=function(f,h){if(!this._isCompound)throw new Error("Cannot set parent in a non-compound graph");if(e.isUndefined(h))h=r;else{h+="";for(var p=h;!e.isUndefined(p);p=this.parent(p))if(p===f)throw new Error("Setting "+h+" as parent of "+f+" would create a cycle");this.setNode(h)}return this.setNode(f),this._removeFromParentsChildList(f),this._parent[f]=h,this._children[h][f]=!0,this},i.prototype._removeFromParentsChildList=function(f){delete this._children[this._parent[f]][f]},i.prototype.parent=function(f){if(this._isCompound){var h=this._parent[f];if(h!==r)return h}},i.prototype.children=function(f){if(e.isUndefined(f)&&(f=r),this._isCompound){var h=this._children[f];if(h)return e.keys(h)}else{if(f===r)return this.nodes();if(this.hasNode(f))return[]}},i.prototype.predecessors=function(f){var h=this._preds[f];if(h)return e.keys(h)},i.prototype.successors=function(f){var h=this._sucs[f];if(h)return e.keys(h)},i.prototype.neighbors=function(f){var h=this.predecessors(f);if(h)return e.union(h,this.successors(f))},i.prototype.isLeaf=function(f){var h;return this.isDirected()?h=this.successors(f):h=this.neighbors(f),h.length===0},i.prototype.filterNodes=function(f){var h=new this.constructor({directed:this._isDirected,multigraph:this._isMultigraph,compound:this._isCompound});h.setGraph(this.graph());var p=this;e.each(this._nodes,function(y,x){f(x)&&h.setNode(x,y)}),e.each(this._edgeObjs,function(y){h.hasNode(y.v)&&h.hasNode(y.w)&&h.setEdge(y,p.edge(y))});var v={};function m(y){var x=p.parent(y);return x===void 0||h.hasNode(x)?(v[y]=x,x):x in v?v[x]:m(x)}return this._isCompound&&e.each(h.nodes(),function(y){h.setParent(y,m(y))}),h},i.prototype.setDefaultEdgeLabel=function(f){return e.isFunction(f)||(f=e.constant(f)),this._defaultEdgeLabelFn=f,this},i.prototype.edgeCount=function(){return this._edgeCount},i.prototype.edges=function(){return e.values(this._edgeObjs)},i.prototype.setPath=function(f,h){var p=this,v=arguments;return e.reduce(f,function(m,y){return v.length>1?p.setEdge(m,y,h):p.setEdge(m,y),y}),this},i.prototype.setEdge=function(){var f,h,p,v,m=!1,y=arguments[0];typeof y=="object"&&y!==null&&"v"in y?(f=y.v,h=y.w,p=y.name,arguments.length===2&&(v=arguments[1],m=!0)):(f=y,h=arguments[1],p=arguments[3],arguments.length>2&&(v=arguments[2],m=!0)),f=""+f,h=""+h,e.isUndefined(p)||(p=""+p);var x=u(this._isDirected,f,h,p);if(e.has(this._edgeLabels,x))return m&&(this._edgeLabels[x]=v),this;if(!e.isUndefined(p)&&!this._isMultigraph)throw new Error("Cannot set a named edge when isMultigraph = false");this.setNode(f),this.setNode(h),this._edgeLabels[x]=m?v:this._defaultEdgeLabelFn(f,h,p);var b=c(this._isDirected,f,h,p);return f=b.v,h=b.w,Object.freeze(b),this._edgeObjs[x]=b,o(this._preds[h],f),o(this._sucs[f],h),this._in[h][x]=b,this._out[f][x]=b,this._edgeCount++,this},i.prototype.edge=function(f,h,p){var v=arguments.length===1?d(this._isDirected,arguments[0]):u(this._isDirected,f,h,p);return this._edgeLabels[v]},i.prototype.hasEdge=function(f,h,p){var v=arguments.length===1?d(this._isDirected,arguments[0]):u(this._isDirected,f,h,p);return e.has(this._edgeLabels,v)},i.prototype.removeEdge=function(f,h,p){var v=arguments.length===1?d(this._isDirected,arguments[0]):u(this._isDirected,f,h,p),m=this._edgeObjs[v];return m&&(f=m.v,h=m.w,delete this._edgeLabels[v],delete this._edgeObjs[v],a(this._preds[h],f),a(this._sucs[f],h),delete this._in[h][v],delete this._out[f][v],this._edgeCount--),this},i.prototype.inEdges=function(f,h){var p=this._in[f];if(p){var v=e.values(p);return h?e.filter(v,function(m){return m.v===h}):v}},i.prototype.outEdges=function(f,h){var p=this._out[f];if(p){var v=e.values(p);return h?e.filter(v,function(m){return m.w===h}):v}},i.prototype.nodeEdges=function(f,h){var p=this.inEdges(f,h);if(p)return p.concat(this.outEdges(f,h))};function o(f,h){f[h]?f[h]++:f[h]=1}function a(f,h){--f[h]||delete f[h]}function u(f,h,p,v){var m=""+h,y=""+p;if(!f&&m>y){var x=m;m=y,y=x}return m+n+y+n+(e.isUndefined(v)?t:v)}function c(f,h,p,v){var m=""+h,y=""+p;if(!f&&m>y){var x=m;m=y,y=x}var b={v:m,w:y};return v&&(b.name=v),b}function d(f,h){return u(f,h.v,h.w,h.name)}return Sv}var Ov,TC;function tV(){return TC||(TC=1,Ov="2.1.8"),Ov}var Cv,AC;function rV(){return AC||(AC=1,Cv={Graph:xx(),version:tV()}),Cv}var Rv,MC;function nV(){if(MC)return Rv;MC=1;var e=Cr(),t=xx();Rv={write:r,read:o};function r(a){var u={options:{directed:a.isDirected(),multigraph:a.isMultigraph(),compound:a.isCompound()},nodes:n(a),edges:i(a)};return e.isUndefined(a.graph())||(u.value=e.clone(a.graph())),u}function n(a){return e.map(a.nodes(),function(u){var c=a.node(u),d=a.parent(u),f={v:u};return e.isUndefined(c)||(f.value=c),e.isUndefined(d)||(f.parent=d),f})}function i(a){return e.map(a.edges(),function(u){var c=a.edge(u),d={v:u.v,w:u.w};return e.isUndefined(u.name)||(d.name=u.name),e.isUndefined(c)||(d.value=c),d})}function o(a){var u=new t(a.options).setGraph(a.value);return e.each(a.nodes,function(c){u.setNode(c.v,c.value),c.parent&&u.setParent(c.v,c.parent)}),e.each(a.edges,function(c){u.setEdge({v:c.v,w:c.w,name:c.name},c.value)}),u}return Rv}var Iv,DC;function iV(){if(DC)return Iv;DC=1;var e=Cr();Iv=t;function t(r){var n={},i=[],o;function a(u){e.has(n,u)||(n[u]=!0,o.push(u),e.each(r.successors(u),a),e.each(r.predecessors(u),a))}return e.each(r.nodes(),function(u){o=[],a(u),o.length&&i.push(o)}),i}return Iv}var Pv,jC;function uj(){if(jC)return Pv;jC=1;var e=Cr();Pv=t;function t(){this._arr=[],this._keyIndices={}}return t.prototype.size=function(){return this._arr.length},t.prototype.keys=function(){return this._arr.map(function(r){return r.key})},t.prototype.has=function(r){return e.has(this._keyIndices,r)},t.prototype.priority=function(r){var n=this._keyIndices[r];if(n!==void 0)return this._arr[n].priority},t.prototype.min=function(){if(this.size()===0)throw new Error("Queue underflow");return this._arr[0].key},t.prototype.add=function(r,n){var i=this._keyIndices;if(r=String(r),!e.has(i,r)){var o=this._arr,a=o.length;return i[r]=a,o.push({key:r,priority:n}),this._decrease(a),!0}return!1},t.prototype.removeMin=function(){this._swap(0,this._arr.length-1);var r=this._arr.pop();return delete this._keyIndices[r.key],this._heapify(0),r.key},t.prototype.decrease=function(r,n){var i=this._keyIndices[r];if(n>this._arr[i].priority)throw new Error("New priority is greater than current priority. Key: "+r+" Old: "+this._arr[i].priority+" New: "+n);this._arr[i].priority=n,this._decrease(i)},t.prototype._heapify=function(r){var n=this._arr,i=2*r,o=i+1,a=r;i<n.length&&(a=n[i].priority<n[a].priority?i:a,o<n.length&&(a=n[o].priority<n[a].priority?o:a),a!==r&&(this._swap(r,a),this._heapify(a)))},t.prototype._decrease=function(r){for(var n=this._arr,i=n[r].priority,o;r!==0&&(o=r>>1,!(n[o].priority<i));)this._swap(r,o),r=o},t.prototype._swap=function(r,n){var i=this._arr,o=this._keyIndices,a=i[r],u=i[n];i[r]=u,i[n]=a,o[u.key]=r,o[a.key]=n},Pv}var Nv,qC;function cj(){if(qC)return Nv;qC=1;var e=Cr(),t=uj();Nv=n;var r=e.constant(1);function n(o,a,u,c){return i(o,String(a),u||r,c||function(d){return o.outEdges(d)})}function i(o,a,u,c){var d={},f=new t,h,p,v=function(m){var y=m.v!==h?m.v:m.w,x=d[y],b=u(m),w=p.distance+b;if(b<0)throw new Error("dijkstra does not allow negative edge weights. Bad edge: "+m+" Weight: "+b);w<x.distance&&(x.distance=w,x.predecessor=h,f.decrease(y,w))};for(o.nodes().forEach(function(m){var y=m===a?0:Number.POSITIVE_INFINITY;d[m]={distance:y},f.add(m,y)});f.size()>0&&(h=f.removeMin(),p=d[h],p.distance!==Number.POSITIVE_INFINITY);)c(h).forEach(v);return d}return Nv}var Tv,kC;function oV(){if(kC)return Tv;kC=1;var e=cj(),t=Cr();Tv=r;function r(n,i,o){return t.transform(n.nodes(),function(a,u){a[u]=e(n,u,i,o)},{})}return Tv}var Av,LC;function lj(){if(LC)return Av;LC=1;var e=Cr();Av=t;function t(r){var n=0,i=[],o={},a=[];function u(c){var d=o[c]={onStack:!0,lowlink:n,index:n++};if(i.push(c),r.successors(c).forEach(function(p){e.has(o,p)?o[p].onStack&&(d.lowlink=Math.min(d.lowlink,o[p].index)):(u(p),d.lowlink=Math.min(d.lowlink,o[p].lowlink))}),d.lowlink===d.index){var f=[],h;do h=i.pop(),o[h].onStack=!1,f.push(h);while(c!==h);a.push(f)}}return r.nodes().forEach(function(c){e.has(o,c)||u(c)}),a}return Av}var Mv,BC;function aV(){if(BC)return Mv;BC=1;var e=Cr(),t=lj();Mv=r;function r(n){return e.filter(t(n),function(i){return i.length>1||i.length===1&&n.hasEdge(i[0],i[0])})}return Mv}var Dv,FC;function sV(){if(FC)return Dv;FC=1;var e=Cr();Dv=r;var t=e.constant(1);function r(i,o,a){return n(i,o||t,a||function(u){return i.outEdges(u)})}function n(i,o,a){var u={},c=i.nodes();return c.forEach(function(d){u[d]={},u[d][d]={distance:0},c.forEach(function(f){d!==f&&(u[d][f]={distance:Number.POSITIVE_INFINITY})}),a(d).forEach(function(f){var h=f.v===d?f.w:f.v,p=o(f);u[d][h]={distance:p,predecessor:d}})}),c.forEach(function(d){var f=u[d];c.forEach(function(h){var p=u[h];c.forEach(function(v){var m=p[d],y=f[v],x=p[v],b=m.distance+y.distance;b<x.distance&&(x.distance=b,x.predecessor=y.predecessor)})})}),u}return Dv}var jv,$C;function fj(){if($C)return jv;$C=1;var e=Cr();jv=t,t.CycleException=r;function t(n){var i={},o={},a=[];function u(c){if(e.has(o,c))throw new r;e.has(i,c)||(o[c]=!0,i[c]=!0,e.each(n.predecessors(c),u),delete o[c],a.push(c))}if(e.each(n.sinks(),u),e.size(i)!==n.nodeCount())throw new r;return a}function r(){}return r.prototype=new Error,jv}var qv,zC;function uV(){if(zC)return qv;zC=1;var e=fj();qv=t;function t(r){try{e(r)}catch(n){if(n instanceof e.CycleException)return!1;throw n}return!0}return qv}var kv,HC;function dj(){if(HC)return kv;HC=1;var e=Cr();kv=t;function t(n,i,o){e.isArray(i)||(i=[i]);var a=(n.isDirected()?n.successors:n.neighbors).bind(n),u=[],c={};return e.each(i,function(d){if(!n.hasNode(d))throw new Error("Graph does not have node: "+d);r(n,d,o==="post",c,a,u)}),u}function r(n,i,o,a,u,c){e.has(a,i)||(a[i]=!0,o||c.push(i),e.each(u(i),function(d){r(n,d,o,a,u,c)}),o&&c.push(i))}return kv}var Lv,UC;function cV(){if(UC)return Lv;UC=1;var e=dj();Lv=t;function t(r,n){return e(r,n,"post")}return Lv}var Bv,VC;function lV(){if(VC)return Bv;VC=1;var e=dj();Bv=t;function t(r,n){return e(r,n,"pre")}return Bv}var Fv,WC;function fV(){if(WC)return Fv;WC=1;var e=Cr(),t=xx(),r=uj();Fv=n;function n(i,o){var a=new t,u={},c=new r,d;function f(p){var v=p.v===d?p.w:p.v,m=c.priority(v);if(m!==void 0){var y=o(p);y<m&&(u[v]=d,c.decrease(v,y))}}if(i.nodeCount()===0)return a;e.each(i.nodes(),function(p){c.add(p,Number.POSITIVE_INFINITY),a.setNode(p)}),c.decrease(i.nodes()[0],0);for(var h=!1;c.size()>0;){if(d=c.removeMin(),e.has(u,d))a.setEdge(d,u[d]);else{if(h)throw new Error("Input graph is not connected: "+i);h=!0}i.nodeEdges(d).forEach(f)}return a}return Fv}var $v,GC;function dV(){return GC||(GC=1,$v={components:iV(),dijkstra:cj(),dijkstraAll:oV(),findCycles:aV(),floydWarshall:sV(),isAcyclic:uV(),postorder:cV(),preorder:lV(),prim:fV(),tarjan:lj(),topsort:fj()}),$v}var zv,KC;function hV(){if(KC)return zv;KC=1;var e=rV();return zv={Graph:e.Graph,json:nV(),alg:dV(),version:e.version},zv}var Hv,YC;function kr(){if(YC)return Hv;YC=1;var e;if(typeof ix=="function")try{e=hV()}catch{}return e||(e=window.graphlib),Hv=e,Hv}var Uv,XC;function pV(){if(XC)return Uv;XC=1;var e=kD(),t=1,r=4;function n(i){return e(i,t|r)}return Uv=n,Uv}var Vv,ZC;function Lc(){if(ZC)return Vv;ZC=1;var e=bo(),t=En(),r=Pc(),n=Or();function i(o,a,u){if(!n(u))return!1;var c=typeof a;return(c=="number"?t(u)&&r(a,u.length):c=="string"&&a in u)?e(u[a],o):!1}return Vv=i,Vv}var Wv,JC;function vV(){if(JC)return Wv;JC=1;var e=kc(),t=bo(),r=Lc(),n=Ei(),i=Object.prototype,o=i.hasOwnProperty,a=e(function(u,c){u=Object(u);var d=-1,f=c.length,h=f>2?c[2]:void 0;for(h&&r(c[0],c[1],h)&&(f=1);++d<f;)for(var p=c[d],v=n(p),m=-1,y=v.length;++m<y;){var x=v[m],b=u[x];(b===void 0||t(b,i[x])&&!o.call(u,x))&&(u[x]=p[x])}return u});return Wv=a,Wv}var Gv,QC;function gV(){if(QC)return Gv;QC=1;var e=Sn(),t=En(),r=Wn();function n(i){return function(o,a,u){var c=Object(o);if(!t(o)){var d=e(a,3);o=r(o),a=function(h){return d(c[h],h,c)}}var f=i(o,a,u);return f>-1?c[d?o[f]:f]:void 0}}return Gv=n,Gv}var Kv,eR;function mV(){if(eR)return Kv;eR=1;var e=/\s/;function t(r){for(var n=r.length;n--&&e.test(r.charAt(n)););return n}return Kv=t,Kv}var Yv,tR;function yV(){if(tR)return Yv;tR=1;var e=mV(),t=/^\s+/;function r(n){return n&&n.slice(0,e(n)+1).replace(t,"")}return Yv=r,Yv}var Xv,rR;function bV(){if(rR)return Xv;rR=1;var e=yV(),t=Or(),r=Eo(),n=NaN,i=/^[-+]0x[0-9a-f]+$/i,o=/^0b[01]+$/i,a=/^0o[0-7]+$/i,u=parseInt;function c(d){if(typeof d=="number")return d;if(r(d))return n;if(t(d)){var f=typeof d.valueOf=="function"?d.valueOf():d;d=t(f)?f+"":f}if(typeof d!="string")return d===0?d:+d;d=e(d);var h=o.test(d);return h||a.test(d)?u(d.slice(2),h?2:8):i.test(d)?n:+d}return Xv=c,Xv}var Zv,nR;function hj(){if(nR)return Zv;nR=1;var e=bV(),t=1/0,r=17976931348623157e292;function n(i){if(!i)return i===0?i:0;if(i=e(i),i===t||i===-t){var o=i<0?-1:1;return o*r}return i===i?i:0}return Zv=n,Zv}var Jv,iR;function xV(){if(iR)return Jv;iR=1;var e=hj();function t(r){var n=e(r),i=n%1;return n===n?i?n-i:n:0}return Jv=t,Jv}var Qv,oR;function wV(){if(oR)return Qv;oR=1;var e=oj(),t=Sn(),r=xV(),n=Math.max;function i(o,a,u){var c=o==null?0:o.length;if(!c)return-1;var d=u==null?0:r(u);return d<0&&(d=n(c+d,0)),e(o,t(a,3),d)}return Qv=i,Qv}var eg,aR;function _V(){if(aR)return eg;aR=1;var e=gV(),t=wV(),r=e(t);return eg=r,eg}var tg,sR;function pj(){if(sR)return tg;sR=1;var e=bx();function t(r){var n=r==null?0:r.length;return n?e(r,1):[]}return tg=t,tg}var rg,uR;function EV(){if(uR)return rg;uR=1;var e=vx(),t=LD(),r=Ei();function n(i,o){return i==null?i:e(i,t(o),r)}return rg=n,rg}var ng,cR;function SV(){if(cR)return ng;cR=1;function e(t){var r=t==null?0:t.length;return r?t[r-1]:void 0}return ng=e,ng}var ig,lR;function OV(){if(lR)return ig;lR=1;var e=Rc(),t=gx(),r=Sn();function n(i,o){var a={};return o=r(o,3),t(i,function(u,c,d){e(a,c,o(u,c,d))}),a}return ig=n,ig}var og,fR;function wx(){if(fR)return og;fR=1;var e=Eo();function t(r,n,i){for(var o=-1,a=r.length;++o<a;){var u=r[o],c=n(u);if(c!=null&&(d===void 0?c===c&&!e(c):i(c,d)))var d=c,f=u}return f}return og=t,og}var ag,dR;function CV(){if(dR)return ag;dR=1;function e(t,r){return t>r}return ag=e,ag}var sg,hR;function RV(){if(hR)return sg;hR=1;var e=wx(),t=CV(),r=Si();function n(i){return i&&i.length?e(i,r,t):void 0}return sg=n,sg}var ug,pR;function vj(){if(pR)return ug;pR=1;var e=Rc(),t=bo();function r(n,i,o){(o!==void 0&&!t(n[i],o)||o===void 0&&!(i in n))&&e(n,i,o)}return ug=r,ug}var cg,vR;function IV(){if(vR)return cg;vR=1;var e=wi(),t=Ac(),r=on(),n="[object Object]",i=Function.prototype,o=Object.prototype,a=i.toString,u=o.hasOwnProperty,c=a.call(Object);function d(f){if(!r(f)||e(f)!=n)return!1;var h=t(f);if(h===null)return!0;var p=u.call(h,"constructor")&&h.constructor;return typeof p=="function"&&p instanceof p&&a.call(p)==c}return cg=d,cg}var lg,gR;function gj(){if(gR)return lg;gR=1;function e(t,r){if(!(r==="constructor"&&typeof t[r]=="function")&&r!="__proto__")return t[r]}return lg=e,lg}var fg,mR;function PV(){if(mR)return fg;mR=1;var e=Ha(),t=Ei();function r(n){return e(n,t(n))}return fg=r,fg}var dg,yR;function NV(){if(yR)return dg;yR=1;var e=vj(),t=OD(),r=DD(),n=CD(),i=qD(),o=Ua(),a=yt(),u=aj(),c=wo(),d=za(),f=Or(),h=IV(),p=Va(),v=gj(),m=PV();function y(x,b,w,S,E,_,R){var I=v(x,w),N=v(b,w),D=R.get(N);if(D){e(x,w,D);return}var k=_?_(I,N,w+"",x,b,R):void 0,B=k===void 0;if(B){var L=a(N),j=!L&&c(N),T=!L&&!j&&p(N);k=N,L||j||T?a(I)?k=I:u(I)?k=n(I):j?(B=!1,k=t(N,!0)):T?(B=!1,k=r(N,!0)):k=[]:h(N)||o(N)?(k=I,o(I)?k=m(I):(!f(I)||d(I))&&(k=i(N))):B=!1}B&&(R.set(N,k),E(k,N,S,_,R),R.delete(N)),e(x,w,k)}return dg=y,dg}var hg,bR;function TV(){if(bR)return hg;bR=1;var e=Cc(),t=vj(),r=vx(),n=NV(),i=Or(),o=Ei(),a=gj();function u(c,d,f,h,p){c!==d&&r(d,function(v,m){if(p||(p=new e),i(v))n(c,d,m,f,u,h,p);else{var y=h?h(a(c,m),v,m+"",c,d,p):void 0;y===void 0&&(y=v),t(c,m,y)}},o)}return hg=u,hg}var pg,xR;function AV(){if(xR)return pg;xR=1;var e=kc(),t=Lc();function r(n){return e(function(i,o){var a=-1,u=o.length,c=u>1?o[u-1]:void 0,d=u>2?o[2]:void 0;for(c=n.length>3&&typeof c=="function"?(u--,c):void 0,d&&t(o[0],o[1],d)&&(c=u<3?void 0:c,u=1),i=Object(i);++a<u;){var f=o[a];f&&n(i,f,a,c)}return i})}return pg=r,pg}var vg,wR;function MV(){if(wR)return vg;wR=1;var e=TV(),t=AV(),r=t(function(n,i,o){e(n,i,o)});return vg=r,vg}var gg,_R;function mj(){if(_R)return gg;_R=1;function e(t,r){return t<r}return gg=e,gg}var mg,ER;function DV(){if(ER)return mg;ER=1;var e=wx(),t=mj(),r=Si();function n(i){return i&&i.length?e(i,r,t):void 0}return mg=n,mg}var yg,SR;function jV(){if(SR)return yg;SR=1;var e=wx(),t=Sn(),r=mj();function n(i,o){return i&&i.length?e(i,t(o,2),r):void 0}return yg=n,yg}var bg,OR;function qV(){if(OR)return bg;OR=1;var e=Fr(),t=function(){return e.Date.now()};return bg=t,bg}var xg,CR;function kV(){if(CR)return xg;CR=1;var e=Ic(),t=jc(),r=Pc(),n=Or(),i=Wa();function o(a,u,c,d){if(!n(a))return a;u=t(u,a);for(var f=-1,h=u.length,p=h-1,v=a;v!=null&&++f<h;){var m=i(u[f]),y=c;if(m==="__proto__"||m==="constructor"||m==="prototype")return a;if(f!=p){var x=v[m];y=d?d(x,m,v):void 0,y===void 0&&(y=n(x)?x:r(u[f+1])?[]:{})}e(v,m,y),v=v[m]}return a}return xg=o,xg}var wg,RR;function LV(){if(RR)return wg;RR=1;var e=qc(),t=kV(),r=jc();function n(i,o,a){for(var u=-1,c=o.length,d={};++u<c;){var f=o[u],h=e(i,f);a(h,f)&&t(d,r(f,i),h)}return d}return wg=n,wg}var _g,IR;function BV(){if(IR)return _g;IR=1;var e=LV(),t=YD();function r(n,i){return e(n,i,function(o,a){return t(n,a)})}return _g=r,_g}var Eg,PR;function FV(){if(PR)return Eg;PR=1;var e=pj(),t=nj(),r=ij();function n(i){return r(t(i,void 0,e),i+"")}return Eg=n,Eg}var Sg,NR;function $V(){if(NR)return Sg;NR=1;var e=BV(),t=FV(),r=t(function(n,i){return n==null?{}:e(n,i)});return Sg=r,Sg}var Og,TR;function zV(){if(TR)return Og;TR=1;var e=Math.ceil,t=Math.max;function r(n,i,o,a){for(var u=-1,c=t(e((i-n)/(o||1)),0),d=Array(c);c--;)d[a?c:++u]=n,n+=o;return d}return Og=r,Og}var Cg,AR;function HV(){if(AR)return Cg;AR=1;var e=zV(),t=Lc(),r=hj();function n(i){return function(o,a,u){return u&&typeof u!="number"&&t(o,a,u)&&(a=u=void 0),o=r(o),a===void 0?(a=o,o=0):a=r(a),u=u===void 0?o<a?1:-1:r(u),e(o,a,u,i)}}return Cg=n,Cg}var Rg,MR;function UV(){if(MR)return Rg;MR=1;var e=HV(),t=e();return Rg=t,Rg}var Ig,DR;function VV(){if(DR)return Ig;DR=1;function e(t,r){var n=t.length;for(t.sort(r);n--;)t[n]=t[n].value;return t}return Ig=e,Ig}var Pg,jR;function WV(){if(jR)return Pg;jR=1;var e=Eo();function t(r,n){if(r!==n){var i=r!==void 0,o=r===null,a=r===r,u=e(r),c=n!==void 0,d=n===null,f=n===n,h=e(n);if(!d&&!h&&!u&&r>n||u&&c&&f&&!d&&!h||o&&c&&f||!i&&f||!a)return 1;if(!o&&!u&&!h&&r<n||h&&i&&a&&!o&&!u||d&&i&&a||!c&&a||!f)return-1}return 0}return Pg=t,Pg}var Ng,qR;function GV(){if(qR)return Ng;qR=1;var e=WV();function t(r,n,i){for(var o=-1,a=r.criteria,u=n.criteria,c=a.length,d=i.length;++o<c;){var f=e(a[o],u[o]);if(f){if(o>=d)return f;var h=i[o];return f*(h=="desc"?-1:1)}}return r.index-n.index}return Ng=t,Ng}var Tg,kR;function KV(){if(kR)return Tg;kR=1;var e=Dc(),t=qc(),r=Sn(),n=ej(),i=VV(),o=Nc(),a=GV(),u=Si(),c=yt();function d(f,h,p){h.length?h=e(h,function(y){return c(y)?function(x){return t(x,y.length===1?y[0]:y)}:y}):h=[u];var v=-1;h=e(h,o(r));var m=n(f,function(y,x,b){var w=e(h,function(S){return S(y)});return{criteria:w,index:++v,value:y}});return i(m,function(y,x){return a(y,x,p)})}return Tg=d,Tg}var Ag,LR;function YV(){if(LR)return Ag;LR=1;var e=bx(),t=KV(),r=kc(),n=Lc(),i=r(function(o,a){if(o==null)return[];var u=a.length;return u>1&&n(o,a[0],a[1])?a=[]:u>2&&n(a[0],a[1],a[2])&&(a=[a[0]]),t(o,e(a,1),[])});return Ag=i,Ag}var Mg,BR;function XV(){if(BR)return Mg;BR=1;var e=GD(),t=0;function r(n){var i=++t;return e(n)+i}return Mg=r,Mg}var Dg,FR;function ZV(){if(FR)return Dg;FR=1;function e(t,r,n){for(var i=-1,o=t.length,a=r.length,u={};++i<o;){var c=i<a?r[i]:void 0;n(u,t[i],c)}return u}return Dg=e,Dg}var jg,$R;function JV(){if($R)return jg;$R=1;var e=Ic(),t=ZV();function r(n,i){return t(n||[],i||[],e)}return jg=r,jg}var qg,zR;function lt(){if(zR)return qg;zR=1;var e;if(typeof ix=="function")try{e={cloneDeep:pV(),constant:px(),defaults:vV(),each:FD(),filter:ZD(),find:_V(),flatten:pj(),forEach:BD(),forIn:EV(),has:JD(),isUndefined:QD(),last:SV(),map:tj(),mapValues:OV(),max:RV(),merge:MV(),min:DV(),minBy:jV(),now:qV(),pick:$V(),range:UV(),reduce:rj(),sortBy:YV(),uniqueId:XV(),values:sj(),zipObject:JV()}}catch{}return e||(e=window._),qg=e,qg}var kg,HR;function QV(){if(HR)return kg;HR=1,kg=e;function e(){var n={};n._next=n._prev=n,this._sentinel=n}e.prototype.dequeue=function(){var n=this._sentinel,i=n._prev;if(i!==n)return t(i),i},e.prototype.enqueue=function(n){var i=this._sentinel;n._prev&&n._next&&t(n),n._next=i._next,i._next._prev=n,i._next=n,n._prev=i},e.prototype.toString=function(){for(var n=[],i=this._sentinel,o=i._prev;o!==i;)n.push(JSON.stringify(o,r)),o=o._prev;return"["+n.join(", ")+"]"};function t(n){n._prev._next=n._next,n._next._prev=n._prev,delete n._next,delete n._prev}function r(n,i){if(n!=="_next"&&n!=="_prev")return i}return kg}var Lg,UR;function eW(){if(UR)return Lg;UR=1;var e=lt(),t=kr().Graph,r=QV();Lg=i;var n=e.constant(1);function i(d,f){if(d.nodeCount()<=1)return[];var h=u(d,f||n),p=o(h.graph,h.buckets,h.zeroIdx);return e.flatten(e.map(p,function(v){return d.outEdges(v.v,v.w)}),!0)}function o(d,f,h){for(var p=[],v=f[f.length-1],m=f[0],y;d.nodeCount();){for(;y=m.dequeue();)a(d,f,h,y);for(;y=v.dequeue();)a(d,f,h,y);if(d.nodeCount()){for(var x=f.length-2;x>0;--x)if(y=f[x].dequeue(),y){p=p.concat(a(d,f,h,y,!0));break}}}return p}function a(d,f,h,p,v){var m=v?[]:void 0;return e.forEach(d.inEdges(p.v),function(y){var x=d.edge(y),b=d.node(y.v);v&&m.push({v:y.v,w:y.w}),b.out-=x,c(f,h,b)}),e.forEach(d.outEdges(p.v),function(y){var x=d.edge(y),b=y.w,w=d.node(b);w.in-=x,c(f,h,w)}),d.removeNode(p.v),m}function u(d,f){var h=new t,p=0,v=0;e.forEach(d.nodes(),function(x){h.setNode(x,{v:x,in:0,out:0})}),e.forEach(d.edges(),function(x){var b=h.edge(x.v,x.w)||0,w=f(x),S=b+w;h.setEdge(x.v,x.w,S),v=Math.max(v,h.node(x.v).out+=w),p=Math.max(p,h.node(x.w).in+=w)});var m=e.range(v+p+3).map(function(){return new r}),y=p+1;return e.forEach(h.nodes(),function(x){c(m,y,h.node(x))}),{graph:h,buckets:m,zeroIdx:y}}function c(d,f,h){h.out?h.in?d[h.out-h.in+f].enqueue(h):d[d.length-1].enqueue(h):d[0].enqueue(h)}return Lg}var Bg,VR;function tW(){if(VR)return Bg;VR=1;var e=lt(),t=eW();Bg={run:r,undo:i};function r(o){var a=o.graph().acyclicer==="greedy"?t(o,u(o)):n(o);e.forEach(a,function(c){var d=o.edge(c);o.removeEdge(c),d.forwardName=c.name,d.reversed=!0,o.setEdge(c.w,c.v,d,e.uniqueId("rev"))});function u(c){return function(d){return c.edge(d).weight}}}function n(o){var a=[],u={},c={};function d(f){e.has(c,f)||(c[f]=!0,u[f]=!0,e.forEach(o.outEdges(f),function(h){e.has(u,h.w)?a.push(h):d(h.w)}),delete u[f])}return e.forEach(o.nodes(),d),a}function i(o){e.forEach(o.edges(),function(a){var u=o.edge(a);if(u.reversed){o.removeEdge(a);var c=u.forwardName;delete u.reversed,delete u.forwardName,o.setEdge(a.w,a.v,u,c)}})}return Bg}var Fg,WR;function Yt(){if(WR)return Fg;WR=1;var e=lt(),t=kr().Graph;Fg={addDummyNode:r,simplify:n,asNonCompoundGraph:i,successorWeights:o,predecessorWeights:a,intersectRect:u,buildLayerMatrix:c,normalizeRanks:d,removeEmptyRanks:f,addBorderNode:h,maxRank:p,partition:v,time:m,notime:y};function r(x,b,w,S){var E;do E=e.uniqueId(S);while(x.hasNode(E));return w.dummy=b,x.setNode(E,w),E}function n(x){var b=new t().setGraph(x.graph());return e.forEach(x.nodes(),function(w){b.setNode(w,x.node(w))}),e.forEach(x.edges(),function(w){var S=b.edge(w.v,w.w)||{weight:0,minlen:1},E=x.edge(w);b.setEdge(w.v,w.w,{weight:S.weight+E.weight,minlen:Math.max(S.minlen,E.minlen)})}),b}function i(x){var b=new t({multigraph:x.isMultigraph()}).setGraph(x.graph());return e.forEach(x.nodes(),function(w){x.children(w).length||b.setNode(w,x.node(w))}),e.forEach(x.edges(),function(w){b.setEdge(w,x.edge(w))}),b}function o(x){var b=e.map(x.nodes(),function(w){var S={};return e.forEach(x.outEdges(w),function(E){S[E.w]=(S[E.w]||0)+x.edge(E).weight}),S});return e.zipObject(x.nodes(),b)}function a(x){var b=e.map(x.nodes(),function(w){var S={};return e.forEach(x.inEdges(w),function(E){S[E.v]=(S[E.v]||0)+x.edge(E).weight}),S});return e.zipObject(x.nodes(),b)}function u(x,b){var w=x.x,S=x.y,E=b.x-w,_=b.y-S,R=x.width/2,I=x.height/2;if(!E&&!_)throw new Error("Not possible to find intersection inside of the rectangle");var N,D;return Math.abs(_)*R>Math.abs(E)*I?(_<0&&(I=-I),N=I*E/_,D=I):(E<0&&(R=-R),N=R,D=R*_/E),{x:w+N,y:S+D}}function c(x){var b=e.map(e.range(p(x)+1),function(){return[]});return e.forEach(x.nodes(),function(w){var S=x.node(w),E=S.rank;e.isUndefined(E)||(b[E][S.order]=w)}),b}function d(x){var b=e.min(e.map(x.nodes(),function(w){return x.node(w).rank}));e.forEach(x.nodes(),function(w){var S=x.node(w);e.has(S,"rank")&&(S.rank-=b)})}function f(x){var b=e.min(e.map(x.nodes(),function(_){return x.node(_).rank})),w=[];e.forEach(x.nodes(),function(_){var R=x.node(_).rank-b;w[R]||(w[R]=[]),w[R].push(_)});var S=0,E=x.graph().nodeRankFactor;e.forEach(w,function(_,R){e.isUndefined(_)&&R%E!==0?--S:S&&e.forEach(_,function(I){x.node(I).rank+=S})})}function h(x,b,w,S){var E={width:0,height:0};return arguments.length>=4&&(E.rank=w,E.order=S),r(x,"border",E,b)}function p(x){return e.max(e.map(x.nodes(),function(b){var w=x.node(b).rank;if(!e.isUndefined(w))return w}))}function v(x,b){var w={lhs:[],rhs:[]};return e.forEach(x,function(S){b(S)?w.lhs.push(S):w.rhs.push(S)}),w}function m(x,b){var w=e.now();try{return b()}finally{console.log(x+" time: "+(e.now()-w)+"ms")}}function y(x,b){return b()}return Fg}var $g,GR;function rW(){if(GR)return $g;GR=1;var e=lt(),t=Yt();$g={run:r,undo:i};function r(o){o.graph().dummyChains=[],e.forEach(o.edges(),function(a){n(o,a)})}function n(o,a){var u=a.v,c=o.node(u).rank,d=a.w,f=o.node(d).rank,h=a.name,p=o.edge(a),v=p.labelRank;if(f!==c+1){o.removeEdge(a);var m,y,x;for(x=0,++c;c<f;++x,++c)p.points=[],y={width:0,height:0,edgeLabel:p,edgeObj:a,rank:c},m=t.addDummyNode(o,"edge",y,"_d"),c===v&&(y.width=p.width,y.height=p.height,y.dummy="edge-label",y.labelpos=p.labelpos),o.setEdge(u,m,{weight:p.weight},h),x===0&&o.graph().dummyChains.push(m),u=m;o.setEdge(u,d,{weight:p.weight},h)}}function i(o){e.forEach(o.graph().dummyChains,function(a){var u=o.node(a),c=u.edgeLabel,d;for(o.setEdge(u.edgeObj,c);u.dummy;)d=o.successors(a)[0],o.removeNode(a),c.points.push({x:u.x,y:u.y}),u.dummy==="edge-label"&&(c.x=u.x,c.y=u.y,c.width=u.width,c.height=u.height),a=d,u=o.node(a)})}return $g}var zg,KR;function Uu(){if(KR)return zg;KR=1;var e=lt();zg={longestPath:t,slack:r};function t(n){var i={};function o(a){var u=n.node(a);if(e.has(i,a))return u.rank;i[a]=!0;var c=e.min(e.map(n.outEdges(a),function(d){return o(d.w)-n.edge(d).minlen}));return(c===Number.POSITIVE_INFINITY||c===void 0||c===null)&&(c=0),u.rank=c}e.forEach(n.sources(),o)}function r(n,i){return n.node(i.w).rank-n.node(i.v).rank-n.edge(i).minlen}return zg}var Hg,YR;function yj(){if(YR)return Hg;YR=1;var e=lt(),t=kr().Graph,r=Uu().slack;Hg=n;function n(u){var c=new t({directed:!1}),d=u.nodes()[0],f=u.nodeCount();c.setNode(d,{});for(var h,p;i(c,u)<f;)h=o(c,u),p=c.hasNode(h.v)?r(u,h):-r(u,h),a(c,u,p);return c}function i(u,c){function d(f){e.forEach(c.nodeEdges(f),function(h){var p=h.v,v=f===p?h.w:p;!u.hasNode(v)&&!r(c,h)&&(u.setNode(v,{}),u.setEdge(f,v,{}),d(v))})}return e.forEach(u.nodes(),d),u.nodeCount()}function o(u,c){return e.minBy(c.edges(),function(d){if(u.hasNode(d.v)!==u.hasNode(d.w))return r(c,d)})}function a(u,c,d){e.forEach(u.nodes(),function(f){c.node(f).rank+=d})}return Hg}var Ug,XR;function nW(){if(XR)return Ug;XR=1;var e=lt(),t=yj(),r=Uu().slack,n=Uu().longestPath,i=kr().alg.preorder,o=kr().alg.postorder,a=Yt().simplify;Ug=u,u.initLowLimValues=h,u.initCutValues=c,u.calcCutValue=f,u.leaveEdge=v,u.enterEdge=m,u.exchangeEdges=y;function u(S){S=a(S),n(S);var E=t(S);h(E),c(E,S);for(var _,R;_=v(E);)R=m(E,S,_),y(E,S,_,R)}function c(S,E){var _=o(S,S.nodes());_=_.slice(0,_.length-1),e.forEach(_,function(R){d(S,E,R)})}function d(S,E,_){var R=S.node(_),I=R.parent;S.edge(_,I).cutvalue=f(S,E,_)}function f(S,E,_){var R=S.node(_),I=R.parent,N=!0,D=E.edge(_,I),k=0;return D||(N=!1,D=E.edge(I,_)),k=D.weight,e.forEach(E.nodeEdges(_),function(B){var L=B.v===_,j=L?B.w:B.v;if(j!==I){var T=L===N,F=E.edge(B).weight;if(k+=T?F:-F,b(S,_,j)){var $=S.edge(_,j).cutvalue;k+=T?-$:$}}}),k}function h(S,E){arguments.length<2&&(E=S.nodes()[0]),p(S,{},1,E)}function p(S,E,_,R,I){var N=_,D=S.node(R);return E[R]=!0,e.forEach(S.neighbors(R),function(k){e.has(E,k)||(_=p(S,E,_,k,R))}),D.low=N,D.lim=_++,I?D.parent=I:delete D.parent,_}function v(S){return e.find(S.edges(),function(E){return S.edge(E).cutvalue<0})}function m(S,E,_){var R=_.v,I=_.w;E.hasEdge(R,I)||(R=_.w,I=_.v);var N=S.node(R),D=S.node(I),k=N,B=!1;N.lim>D.lim&&(k=D,B=!0);var L=e.filter(E.edges(),function(j){return B===w(S,S.node(j.v),k)&&B!==w(S,S.node(j.w),k)});return e.minBy(L,function(j){return r(E,j)})}function y(S,E,_,R){var I=_.v,N=_.w;S.removeEdge(I,N),S.setEdge(R.v,R.w,{}),h(S),c(S,E),x(S,E)}function x(S,E){var _=e.find(S.nodes(),function(I){return!E.node(I).parent}),R=i(S,_);R=R.slice(1),e.forEach(R,function(I){var N=S.node(I).parent,D=E.edge(I,N),k=!1;D||(D=E.edge(N,I),k=!0),E.node(I).rank=E.node(N).rank+(k?D.minlen:-D.minlen)})}function b(S,E,_){return S.hasEdge(E,_)}function w(S,E,_){return _.low<=E.lim&&E.lim<=_.lim}return Ug}var Vg,ZR;function iW(){if(ZR)return Vg;ZR=1;var e=Uu(),t=e.longestPath,r=yj(),n=nW();Vg=i;function i(c){switch(c.graph().ranker){case"network-simplex":u(c);break;case"tight-tree":a(c);break;case"longest-path":o(c);break;default:u(c)}}var o=t;function a(c){t(c),r(c)}function u(c){n(c)}return Vg}var Wg,JR;function oW(){if(JR)return Wg;JR=1;var e=lt();Wg=t;function t(i){var o=n(i);e.forEach(i.graph().dummyChains,function(a){for(var u=i.node(a),c=u.edgeObj,d=r(i,o,c.v,c.w),f=d.path,h=d.lca,p=0,v=f[p],m=!0;a!==c.w;){if(u=i.node(a),m){for(;(v=f[p])!==h&&i.node(v).maxRank<u.rank;)p++;v===h&&(m=!1)}if(!m){for(;p<f.length-1&&i.node(v=f[p+1]).minRank<=u.rank;)p++;v=f[p]}i.setParent(a,v),a=i.successors(a)[0]}})}function r(i,o,a,u){var c=[],d=[],f=Math.min(o[a].low,o[u].low),h=Math.max(o[a].lim,o[u].lim),p,v;p=a;do p=i.parent(p),c.push(p);while(p&&(o[p].low>f||h>o[p].lim));for(v=p,p=u;(p=i.parent(p))!==v;)d.push(p);return{path:c.concat(d.reverse()),lca:v}}function n(i){var o={},a=0;function u(c){var d=a;e.forEach(i.children(c),u),o[c]={low:d,lim:a++}}return e.forEach(i.children(),u),o}return Wg}var Gg,QR;function aW(){if(QR)return Gg;QR=1;var e=lt(),t=Yt();Gg={run:r,cleanup:a};function r(u){var c=t.addDummyNode(u,"root",{},"_root"),d=i(u),f=e.max(e.values(d))-1,h=2*f+1;u.graph().nestingRoot=c,e.forEach(u.edges(),function(v){u.edge(v).minlen*=h});var p=o(u)+1;e.forEach(u.children(),function(v){n(u,c,h,p,f,d,v)}),u.graph().nodeRankFactor=h}function n(u,c,d,f,h,p,v){var m=u.children(v);if(!m.length){v!==c&&u.setEdge(c,v,{weight:0,minlen:d});return}var y=t.addBorderNode(u,"_bt"),x=t.addBorderNode(u,"_bb"),b=u.node(v);u.setParent(y,v),b.borderTop=y,u.setParent(x,v),b.borderBottom=x,e.forEach(m,function(w){n(u,c,d,f,h,p,w);var S=u.node(w),E=S.borderTop?S.borderTop:w,_=S.borderBottom?S.borderBottom:w,R=S.borderTop?f:2*f,I=E!==_?1:h-p[v]+1;u.setEdge(y,E,{weight:R,minlen:I,nestingEdge:!0}),u.setEdge(_,x,{weight:R,minlen:I,nestingEdge:!0})}),u.parent(v)||u.setEdge(c,y,{weight:0,minlen:h+p[v]})}function i(u){var c={};function d(f,h){var p=u.children(f);p&&p.length&&e.forEach(p,function(v){d(v,h+1)}),c[f]=h}return e.forEach(u.children(),function(f){d(f,1)}),c}function o(u){return e.reduce(u.edges(),function(c,d){return c+u.edge(d).weight},0)}function a(u){var c=u.graph();u.removeNode(c.nestingRoot),delete c.nestingRoot,e.forEach(u.edges(),function(d){var f=u.edge(d);f.nestingEdge&&u.removeEdge(d)})}return Gg}var Kg,eI;function sW(){if(eI)return Kg;eI=1;var e=lt(),t=Yt();Kg=r;function r(i){function o(a){var u=i.children(a),c=i.node(a);if(u.length&&e.forEach(u,o),e.has(c,"minRank")){c.borderLeft=[],c.borderRight=[];for(var d=c.minRank,f=c.maxRank+1;d<f;++d)n(i,"borderLeft","_bl",a,c,d),n(i,"borderRight","_br",a,c,d)}}e.forEach(i.children(),o)}function n(i,o,a,u,c,d){var f={width:0,height:0,rank:d,borderType:o},h=c[o][d-1],p=t.addDummyNode(i,"border",f,a);c[o][d]=p,i.setParent(p,u),h&&i.setEdge(h,p,{weight:1})}return Kg}var Yg,tI;function uW(){if(tI)return Yg;tI=1;var e=lt();Yg={adjust:t,undo:r};function t(d){var f=d.graph().rankdir.toLowerCase();(f==="lr"||f==="rl")&&n(d)}function r(d){var f=d.graph().rankdir.toLowerCase();(f==="bt"||f==="rl")&&o(d),(f==="lr"||f==="rl")&&(u(d),n(d))}function n(d){e.forEach(d.nodes(),function(f){i(d.node(f))}),e.forEach(d.edges(),function(f){i(d.edge(f))})}function i(d){var f=d.width;d.width=d.height,d.height=f}function o(d){e.forEach(d.nodes(),function(f){a(d.node(f))}),e.forEach(d.edges(),function(f){var h=d.edge(f);e.forEach(h.points,a),e.has(h,"y")&&a(h)})}function a(d){d.y=-d.y}function u(d){e.forEach(d.nodes(),function(f){c(d.node(f))}),e.forEach(d.edges(),function(f){var h=d.edge(f);e.forEach(h.points,c),e.has(h,"x")&&c(h)})}function c(d){var f=d.x;d.x=d.y,d.y=f}return Yg}var Xg,rI;function cW(){if(rI)return Xg;rI=1;var e=lt();Xg=t;function t(r){var n={},i=e.filter(r.nodes(),function(d){return!r.children(d).length}),o=e.max(e.map(i,function(d){return r.node(d).rank})),a=e.map(e.range(o+1),function(){return[]});function u(d){if(!e.has(n,d)){n[d]=!0;var f=r.node(d);a[f.rank].push(d),e.forEach(r.successors(d),u)}}var c=e.sortBy(i,function(d){return r.node(d).rank});return e.forEach(c,u),a}return Xg}var Zg,nI;function lW(){if(nI)return Zg;nI=1;var e=lt();Zg=t;function t(n,i){for(var o=0,a=1;a<i.length;++a)o+=r(n,i[a-1],i[a]);return o}function r(n,i,o){for(var a=e.zipObject(o,e.map(o,function(p,v){return v})),u=e.flatten(e.map(i,function(p){return e.sortBy(e.map(n.outEdges(p),function(v){return{pos:a[v.w],weight:n.edge(v).weight}}),"pos")}),!0),c=1;c<o.length;)c<<=1;var d=2*c-1;c-=1;var f=e.map(new Array(d),function(){return 0}),h=0;return e.forEach(u.forEach(function(p){var v=p.pos+c;f[v]+=p.weight;for(var m=0;v>0;)v%2&&(m+=f[v+1]),v=v-1>>1,f[v]+=p.weight;h+=p.weight*m})),h}return Zg}var Jg,iI;function fW(){if(iI)return Jg;iI=1;var e=lt();Jg=t;function t(r,n){return e.map(n,function(i){var o=r.inEdges(i);if(o.length){var a=e.reduce(o,function(u,c){var d=r.edge(c),f=r.node(c.v);return{sum:u.sum+d.weight*f.order,weight:u.weight+d.weight}},{sum:0,weight:0});return{v:i,barycenter:a.sum/a.weight,weight:a.weight}}else return{v:i}})}return Jg}var Qg,oI;function dW(){if(oI)return Qg;oI=1;var e=lt();Qg=t;function t(i,o){var a={};e.forEach(i,function(c,d){var f=a[c.v]={indegree:0,in:[],out:[],vs:[c.v],i:d};e.isUndefined(c.barycenter)||(f.barycenter=c.barycenter,f.weight=c.weight)}),e.forEach(o.edges(),function(c){var d=a[c.v],f=a[c.w];!e.isUndefined(d)&&!e.isUndefined(f)&&(f.indegree++,d.out.push(a[c.w]))});var u=e.filter(a,function(c){return!c.indegree});return r(u)}function r(i){var o=[];function a(d){return function(f){f.merged||(e.isUndefined(f.barycenter)||e.isUndefined(d.barycenter)||f.barycenter>=d.barycenter)&&n(d,f)}}function u(d){return function(f){f.in.push(d),--f.indegree===0&&i.push(f)}}for(;i.length;){var c=i.pop();o.push(c),e.forEach(c.in.reverse(),a(c)),e.forEach(c.out,u(c))}return e.map(e.filter(o,function(d){return!d.merged}),function(d){return e.pick(d,["vs","i","barycenter","weight"])})}function n(i,o){var a=0,u=0;i.weight&&(a+=i.barycenter*i.weight,u+=i.weight),o.weight&&(a+=o.barycenter*o.weight,u+=o.weight),i.vs=o.vs.concat(i.vs),i.barycenter=a/u,i.weight=u,i.i=Math.min(o.i,i.i),o.merged=!0}return Qg}var em,aI;function hW(){if(aI)return em;aI=1;var e=lt(),t=Yt();em=r;function r(o,a){var u=t.partition(o,function(y){return e.has(y,"barycenter")}),c=u.lhs,d=e.sortBy(u.rhs,function(y){return-y.i}),f=[],h=0,p=0,v=0;c.sort(i(!!a)),v=n(f,d,v),e.forEach(c,function(y){v+=y.vs.length,f.push(y.vs),h+=y.barycenter*y.weight,p+=y.weight,v=n(f,d,v)});var m={vs:e.flatten(f,!0)};return p&&(m.barycenter=h/p,m.weight=p),m}function n(o,a,u){for(var c;a.length&&(c=e.last(a)).i<=u;)a.pop(),o.push(c.vs),u++;return u}function i(o){return function(a,u){return a.barycenter<u.barycenter?-1:a.barycenter>u.barycenter?1:o?u.i-a.i:a.i-u.i}}return em}var tm,sI;function pW(){if(sI)return tm;sI=1;var e=lt(),t=fW(),r=dW(),n=hW();tm=i;function i(u,c,d,f){var h=u.children(c),p=u.node(c),v=p?p.borderLeft:void 0,m=p?p.borderRight:void 0,y={};v&&(h=e.filter(h,function(_){return _!==v&&_!==m}));var x=t(u,h);e.forEach(x,function(_){if(u.children(_.v).length){var R=i(u,_.v,d,f);y[_.v]=R,e.has(R,"barycenter")&&a(_,R)}});var b=r(x,d);o(b,y);var w=n(b,f);if(v&&(w.vs=e.flatten([v,w.vs,m],!0),u.predecessors(v).length)){var S=u.node(u.predecessors(v)[0]),E=u.node(u.predecessors(m)[0]);e.has(w,"barycenter")||(w.barycenter=0,w.weight=0),w.barycenter=(w.barycenter*w.weight+S.order+E.order)/(w.weight+2),w.weight+=2}return w}function o(u,c){e.forEach(u,function(d){d.vs=e.flatten(d.vs.map(function(f){return c[f]?c[f].vs:f}),!0)})}function a(u,c){e.isUndefined(u.barycenter)?(u.barycenter=c.barycenter,u.weight=c.weight):(u.barycenter=(u.barycenter*u.weight+c.barycenter*c.weight)/(u.weight+c.weight),u.weight+=c.weight)}return tm}var rm,uI;function vW(){if(uI)return rm;uI=1;var e=lt(),t=kr().Graph;rm=r;function r(i,o,a){var u=n(i),c=new t({compound:!0}).setGraph({root:u}).setDefaultNodeLabel(function(d){return i.node(d)});return e.forEach(i.nodes(),function(d){var f=i.node(d),h=i.parent(d);(f.rank===o||f.minRank<=o&&o<=f.maxRank)&&(c.setNode(d),c.setParent(d,h||u),e.forEach(i[a](d),function(p){var v=p.v===d?p.w:p.v,m=c.edge(v,d),y=e.isUndefined(m)?0:m.weight;c.setEdge(v,d,{weight:i.edge(p).weight+y})}),e.has(f,"minRank")&&c.setNode(d,{borderLeft:f.borderLeft[o],borderRight:f.borderRight[o]}))}),c}function n(i){for(var o;i.hasNode(o=e.uniqueId("_root")););return o}return rm}var nm,cI;function gW(){if(cI)return nm;cI=1;var e=lt();nm=t;function t(r,n,i){var o={},a;e.forEach(i,function(u){for(var c=r.parent(u),d,f;c;){if(d=r.parent(c),d?(f=o[d],o[d]=c):(f=a,a=c),f&&f!==c){n.setEdge(f,c);return}c=d}})}return nm}var im,lI;function mW(){if(lI)return im;lI=1;var e=lt(),t=cW(),r=lW(),n=pW(),i=vW(),o=gW(),a=kr().Graph,u=Yt();im=c;function c(p){var v=u.maxRank(p),m=d(p,e.range(1,v+1),"inEdges"),y=d(p,e.range(v-1,-1,-1),"outEdges"),x=t(p);h(p,x);for(var b=Number.POSITIVE_INFINITY,w,S=0,E=0;E<4;++S,++E){f(S%2?m:y,S%4>=2),x=u.buildLayerMatrix(p);var _=r(p,x);_<b&&(E=0,w=e.cloneDeep(x),b=_)}h(p,w)}function d(p,v,m){return e.map(v,function(y){return i(p,y,m)})}function f(p,v){var m=new a;e.forEach(p,function(y){var x=y.graph().root,b=n(y,x,m,v);e.forEach(b.vs,function(w,S){y.node(w).order=S}),o(y,m,b.vs)})}function h(p,v){e.forEach(v,function(m){e.forEach(m,function(y,x){p.node(y).order=x})})}return im}var om,fI;function yW(){if(fI)return om;fI=1;var e=lt(),t=kr().Graph,r=Yt();om={positionX:m,findType1Conflicts:n,findType2Conflicts:i,addConflict:a,hasConflict:u,verticalAlignment:c,horizontalCompaction:d,alignCoordinates:p,findSmallestWidthAlignment:h,balance:v};function n(b,w){var S={};function E(_,R){var I=0,N=0,D=_.length,k=e.last(R);return e.forEach(R,function(B,L){var j=o(b,B),T=j?b.node(j).order:D;(j||B===k)&&(e.forEach(R.slice(N,L+1),function(F){e.forEach(b.predecessors(F),function($){var W=b.node($),Y=W.order;(Y<I||T<Y)&&!(W.dummy&&b.node(F).dummy)&&a(S,$,F)})}),N=L+1,I=T)}),R}return e.reduce(w,E),S}function i(b,w){var S={};function E(R,I,N,D,k){var B;e.forEach(e.range(I,N),function(L){B=R[L],b.node(B).dummy&&e.forEach(b.predecessors(B),function(j){var T=b.node(j);T.dummy&&(T.order<D||T.order>k)&&a(S,j,B)})})}function _(R,I){var N=-1,D,k=0;return e.forEach(I,function(B,L){if(b.node(B).dummy==="border"){var j=b.predecessors(B);j.length&&(D=b.node(j[0]).order,E(I,k,L,N,D),k=L,N=D)}E(I,k,I.length,D,R.length)}),I}return e.reduce(w,_),S}function o(b,w){if(b.node(w).dummy)return e.find(b.predecessors(w),function(S){return b.node(S).dummy})}function a(b,w,S){if(w>S){var E=w;w=S,S=E}var _=b[w];_||(b[w]=_={}),_[S]=!0}function u(b,w,S){if(w>S){var E=w;w=S,S=E}return e.has(b[w],S)}function c(b,w,S,E){var _={},R={},I={};return e.forEach(w,function(N){e.forEach(N,function(D,k){_[D]=D,R[D]=D,I[D]=k})}),e.forEach(w,function(N){var D=-1;e.forEach(N,function(k){var B=E(k);if(B.length){B=e.sortBy(B,function($){return I[$]});for(var L=(B.length-1)/2,j=Math.floor(L),T=Math.ceil(L);j<=T;++j){var F=B[j];R[k]===k&&D<I[F]&&!u(S,k,F)&&(R[F]=k,R[k]=_[k]=_[F],D=I[F])}}})}),{root:_,align:R}}function d(b,w,S,E,_){var R={},I=f(b,w,S,_),N=_?"borderLeft":"borderRight";function D(L,j){for(var T=I.nodes(),F=T.pop(),$={};F;)$[F]?L(F):($[F]=!0,T.push(F),T=T.concat(j(F))),F=T.pop()}function k(L){R[L]=I.inEdges(L).reduce(function(j,T){return Math.max(j,R[T.v]+I.edge(T))},0)}function B(L){var j=I.outEdges(L).reduce(function(F,$){return Math.min(F,R[$.w]-I.edge($))},Number.POSITIVE_INFINITY),T=b.node(L);j!==Number.POSITIVE_INFINITY&&T.borderType!==N&&(R[L]=Math.max(R[L],j))}return D(k,I.predecessors.bind(I)),D(B,I.successors.bind(I)),e.forEach(E,function(L){R[L]=R[S[L]]}),R}function f(b,w,S,E){var _=new t,R=b.graph(),I=y(R.nodesep,R.edgesep,E);return e.forEach(w,function(N){var D;e.forEach(N,function(k){var B=S[k];if(_.setNode(B),D){var L=S[D],j=_.edge(L,B);_.setEdge(L,B,Math.max(I(b,k,D),j||0))}D=k})}),_}function h(b,w){return e.minBy(e.values(w),function(S){var E=Number.NEGATIVE_INFINITY,_=Number.POSITIVE_INFINITY;return e.forIn(S,function(R,I){var N=x(b,I)/2;E=Math.max(R+N,E),_=Math.min(R-N,_)}),E-_})}function p(b,w){var S=e.values(w),E=e.min(S),_=e.max(S);e.forEach(["u","d"],function(R){e.forEach(["l","r"],function(I){var N=R+I,D=b[N],k;if(D!==w){var B=e.values(D);k=I==="l"?E-e.min(B):_-e.max(B),k&&(b[N]=e.mapValues(D,function(L){return L+k}))}})})}function v(b,w){return e.mapValues(b.ul,function(S,E){if(w)return b[w.toLowerCase()][E];var _=e.sortBy(e.map(b,E));return(_[1]+_[2])/2})}function m(b){var w=r.buildLayerMatrix(b),S=e.merge(n(b,w),i(b,w)),E={},_;e.forEach(["u","d"],function(I){_=I==="u"?w:e.values(w).reverse(),e.forEach(["l","r"],function(N){N==="r"&&(_=e.map(_,function(L){return e.values(L).reverse()}));var D=(I==="u"?b.predecessors:b.successors).bind(b),k=c(b,_,S,D),B=d(b,_,k.root,k.align,N==="r");N==="r"&&(B=e.mapValues(B,function(L){return-L})),E[I+N]=B})});var R=h(b,E);return p(E,R),v(E,b.graph().align)}function y(b,w,S){return function(E,_,R){var I=E.node(_),N=E.node(R),D=0,k;if(D+=I.width/2,e.has(I,"labelpos"))switch(I.labelpos.toLowerCase()){case"l":k=-I.width/2;break;case"r":k=I.width/2;break}if(k&&(D+=S?k:-k),k=0,D+=(I.dummy?w:b)/2,D+=(N.dummy?w:b)/2,D+=N.width/2,e.has(N,"labelpos"))switch(N.labelpos.toLowerCase()){case"l":k=N.width/2;break;case"r":k=-N.width/2;break}return k&&(D+=S?k:-k),k=0,D}}function x(b,w){return b.node(w).width}return om}var am,dI;function bW(){if(dI)return am;dI=1;var e=lt(),t=Yt(),r=yW().positionX;am=n;function n(o){o=t.asNonCompoundGraph(o),i(o),e.forEach(r(o),function(a,u){o.node(u).x=a})}function i(o){var a=t.buildLayerMatrix(o),u=o.graph().ranksep,c=0;e.forEach(a,function(d){var f=e.max(e.map(d,function(h){return o.node(h).height}));e.forEach(d,function(h){o.node(h).y=c+f/2}),c+=f+u})}return am}var sm,hI;function xW(){if(hI)return sm;hI=1;var e=lt(),t=tW(),r=rW(),n=iW(),i=Yt().normalizeRanks,o=oW(),a=Yt().removeEmptyRanks,u=aW(),c=sW(),d=uW(),f=mW(),h=bW(),p=Yt(),v=kr().Graph;sm=m;function m(z,G){var J=G&&G.debugTiming?p.time:p.notime;J("layout",function(){var V=J(" buildLayoutGraph",function(){return D(z)});J(" runLayout",function(){y(V,J)}),J(" updateInputGraph",function(){x(z,V)})})}function y(z,G){G(" makeSpaceForEdgeLabels",function(){k(z)}),G(" removeSelfEdges",function(){ee(z)}),G(" acyclic",function(){t.run(z)}),G(" nestingGraph.run",function(){u.run(z)}),G(" rank",function(){n(p.asNonCompoundGraph(z))}),G(" injectEdgeLabelProxies",function(){B(z)}),G(" removeEmptyRanks",function(){a(z)}),G(" nestingGraph.cleanup",function(){u.cleanup(z)}),G(" normalizeRanks",function(){i(z)}),G(" assignRankMinMax",function(){L(z)}),G(" removeEdgeLabelProxies",function(){j(z)}),G(" normalize.run",function(){r.run(z)}),G(" parentDummyChains",function(){o(z)}),G(" addBorderSegments",function(){c(z)}),G(" order",function(){f(z)}),G(" insertSelfEdges",function(){H(z)}),G(" adjustCoordinateSystem",function(){d.adjust(z)}),G(" position",function(){h(z)}),G(" positionSelfEdges",function(){Q(z)}),G(" removeBorderNodes",function(){Y(z)}),G(" normalize.undo",function(){r.undo(z)}),G(" fixupEdgeLabelCoords",function(){$(z)}),G(" undoCoordinateSystem",function(){d.undo(z)}),G(" translateGraph",function(){T(z)}),G(" assignNodeIntersects",function(){F(z)}),G(" reversePoints",function(){W(z)}),G(" acyclic.undo",function(){t.undo(z)})}function x(z,G){e.forEach(z.nodes(),function(J){var V=z.node(J),K=G.node(J);V&&(V.x=K.x,V.y=K.y,G.children(J).length&&(V.width=K.width,V.height=K.height))}),e.forEach(z.edges(),function(J){var V=z.edge(J),K=G.edge(J);V.points=K.points,e.has(K,"x")&&(V.x=K.x,V.y=K.y)}),z.graph().width=G.graph().width,z.graph().height=G.graph().height}var b=["nodesep","edgesep","ranksep","marginx","marginy"],w={ranksep:50,edgesep:20,nodesep:50,rankdir:"tb"},S=["acyclicer","ranker","rankdir","align"],E=["width","height"],_={width:0,height:0},R=["minlen","weight","width","height","labeloffset"],I={minlen:1,weight:1,width:0,height:0,labeloffset:10,labelpos:"r"},N=["labelpos"];function D(z){var G=new v({multigraph:!0,compound:!0}),J=se(z.graph());return G.setGraph(e.merge({},w,ce(J,b),e.pick(J,S))),e.forEach(z.nodes(),function(V){var K=se(z.node(V));G.setNode(V,e.defaults(ce(K,E),_)),G.setParent(V,z.parent(V))}),e.forEach(z.edges(),function(V){var K=se(z.edge(V));G.setEdge(V,e.merge({},I,ce(K,R),e.pick(K,N)))}),G}function k(z){var G=z.graph();G.ranksep/=2,e.forEach(z.edges(),function(J){var V=z.edge(J);V.minlen*=2,V.labelpos.toLowerCase()!=="c"&&(G.rankdir==="TB"||G.rankdir==="BT"?V.width+=V.labeloffset:V.height+=V.labeloffset)})}function B(z){e.forEach(z.edges(),function(G){var J=z.edge(G);if(J.width&&J.height){var V=z.node(G.v),K=z.node(G.w),ie={rank:(K.rank-V.rank)/2+V.rank,e:G};p.addDummyNode(z,"edge-proxy",ie,"_ep")}})}function L(z){var G=0;e.forEach(z.nodes(),function(J){var V=z.node(J);V.borderTop&&(V.minRank=z.node(V.borderTop).rank,V.maxRank=z.node(V.borderBottom).rank,G=e.max(G,V.maxRank))}),z.graph().maxRank=G}function j(z){e.forEach(z.nodes(),function(G){var J=z.node(G);J.dummy==="edge-proxy"&&(z.edge(J.e).labelRank=J.rank,z.removeNode(G))})}function T(z){var G=Number.POSITIVE_INFINITY,J=0,V=Number.POSITIVE_INFINITY,K=0,ie=z.graph(),ne=ie.marginx||0,ue=ie.marginy||0;function de(we){var Se=we.x,_e=we.y,he=we.width,ae=we.height;G=Math.min(G,Se-he/2),J=Math.max(J,Se+he/2),V=Math.min(V,_e-ae/2),K=Math.max(K,_e+ae/2)}e.forEach(z.nodes(),function(we){de(z.node(we))}),e.forEach(z.edges(),function(we){var Se=z.edge(we);e.has(Se,"x")&&de(Se)}),G-=ne,V-=ue,e.forEach(z.nodes(),function(we){var Se=z.node(we);Se.x-=G,Se.y-=V}),e.forEach(z.edges(),function(we){var Se=z.edge(we);e.forEach(Se.points,function(_e){_e.x-=G,_e.y-=V}),e.has(Se,"x")&&(Se.x-=G),e.has(Se,"y")&&(Se.y-=V)}),ie.width=J-G+ne,ie.height=K-V+ue}function F(z){e.forEach(z.edges(),function(G){var J=z.edge(G),V=z.node(G.v),K=z.node(G.w),ie,ne;J.points?(ie=J.points[0],ne=J.points[J.points.length-1]):(J.points=[],ie=K,ne=V),J.points.unshift(p.intersectRect(V,ie)),J.points.push(p.intersectRect(K,ne))})}function $(z){e.forEach(z.edges(),function(G){var J=z.edge(G);if(e.has(J,"x"))switch((J.labelpos==="l"||J.labelpos==="r")&&(J.width-=J.labeloffset),J.labelpos){case"l":J.x-=J.width/2+J.labeloffset;break;case"r":J.x+=J.width/2+J.labeloffset;break}})}function W(z){e.forEach(z.edges(),function(G){var J=z.edge(G);J.reversed&&J.points.reverse()})}function Y(z){e.forEach(z.nodes(),function(G){if(z.children(G).length){var J=z.node(G),V=z.node(J.borderTop),K=z.node(J.borderBottom),ie=z.node(e.last(J.borderLeft)),ne=z.node(e.last(J.borderRight));J.width=Math.abs(ne.x-ie.x),J.height=Math.abs(K.y-V.y),J.x=ie.x+J.width/2,J.y=V.y+J.height/2}}),e.forEach(z.nodes(),function(G){z.node(G).dummy==="border"&&z.removeNode(G)})}function ee(z){e.forEach(z.edges(),function(G){if(G.v===G.w){var J=z.node(G.v);J.selfEdges||(J.selfEdges=[]),J.selfEdges.push({e:G,label:z.edge(G)}),z.removeEdge(G)}})}function H(z){var G=p.buildLayerMatrix(z);e.forEach(G,function(J){var V=0;e.forEach(J,function(K,ie){var ne=z.node(K);ne.order=ie+V,e.forEach(ne.selfEdges,function(ue){p.addDummyNode(z,"selfedge",{width:ue.label.width,height:ue.label.height,rank:ne.rank,order:ie+ ++V,e:ue.e,label:ue.label},"_se")}),delete ne.selfEdges})})}function Q(z){e.forEach(z.nodes(),function(G){var J=z.node(G);if(J.dummy==="selfedge"){var V=z.node(J.e.v),K=V.x+V.width/2,ie=V.y,ne=J.x-K,ue=V.height/2;z.setEdge(J.e,J.label),z.removeNode(G),J.label.points=[{x:K+2*ne/3,y:ie-ue},{x:K+5*ne/6,y:ie-ue},{x:K+ne,y:ie},{x:K+5*ne/6,y:ie+ue},{x:K+2*ne/3,y:ie+ue}],J.label.x=J.x,J.label.y=J.y}})}function ce(z,G){return e.mapValues(e.pick(z,G),Number)}function se(z){var G={};return e.forEach(z,function(J,V){G[V.toLowerCase()]=J}),G}return sm}var um,pI;function wW(){if(pI)return um;pI=1;var e=lt(),t=Yt(),r=kr().Graph;um={debugOrdering:n};function n(i){var o=t.buildLayerMatrix(i),a=new r({compound:!0,multigraph:!0}).setGraph({});return e.forEach(i.nodes(),function(u){a.setNode(u,{label:u}),a.setParent(u,"layer"+i.node(u).rank)}),e.forEach(i.edges(),function(u){a.setEdge(u.v,u.w,{},u.name)}),e.forEach(o,function(u,c){var d="layer"+c;a.setNode(d,{rank:"same"}),e.reduce(u,function(f,h){return a.setEdge(f,h,{style:"invis"}),h})}),a}return um}var cm,vI;function _W(){return vI||(vI=1,cm="0.8.5"),cm}var lm,gI;function EW(){return gI||(gI=1,lm={graphlib:kr(),layout:xW(),debug:wW(),util:{time:Yt().time,notime:Yt().notime},version:_W()}),lm}var SW=EW();const mI=Un(SW);function OW(e){let t;const r=new Set,n=(d,f)=>{const h=typeof d=="function"?d(t):d;if(h!==t){const p=t;t=f?h:Object.assign({},t,h),r.forEach(v=>v(t,p))}},i=()=>t,o=(d,f=i,h=Object.is)=>{console.warn("[DEPRECATED] Please use `subscribeWithSelector` middleware");let p=f(t);function v(){const m=f(t);if(!h(p,m)){const y=p;d(p=m,y)}}return r.add(v),()=>r.delete(v)},c={setState:n,getState:i,subscribe:(d,f,h)=>f||h?o(d,f,h):(r.add(d),()=>r.delete(d)),destroy:()=>r.clear()};return t=e(n,i,c),c}const CW=typeof window>"u"||!window.navigator||/ServerSideRendering|^Deno\//.test(window.navigator.userAgent),yI=CW?A.useEffect:A.useLayoutEffect;function RW(e){const t=typeof e=="function"?OW(e):e,r=(n=t.getState,i=Object.is)=>{const[,o]=A.useReducer(x=>x+1,0),a=t.getState(),u=A.useRef(a),c=A.useRef(n),d=A.useRef(i),f=A.useRef(!1),h=A.useRef();h.current===void 0&&(h.current=n(a));let p,v=!1;(u.current!==a||c.current!==n||d.current!==i||f.current)&&(p=n(a),v=!i(h.current,p)),yI(()=>{v&&(h.current=p),u.current=a,c.current=n,d.current=i,f.current=!1});const m=A.useRef(a);yI(()=>{const x=()=>{try{const w=t.getState(),S=c.current(w);d.current(h.current,S)||(u.current=w,h.current=S,o())}catch{f.current=!0,o()}},b=t.subscribe(x);return t.getState()!==m.current&&x(),b},[]);const y=v?p:h.current;return A.useDebugValue(y),y};return Object.assign(r,t),r[Symbol.iterator]=function(){console.warn("[useStore, api] = create() is deprecated and will be removed in v4");const n=[r,t];return{next(){const i=n.length<=0;return{value:n.shift(),done:i}}}},r}function IW(){const e=A.createContext(void 0);return{Provider:({initialStore:i,createStore:o,children:a})=>{const u=A.useRef();return u.current||(i&&(console.warn("Provider initialStore is deprecated and will be removed in the next version."),o||(o=()=>i)),u.current=o()),A.createElement(e.Provider,{value:u.current},a)},useStore:(i,o=Object.is)=>{const a=A.useContext(e);if(!a)throw new Error("Seems like you have not used zustand provider as an ancestor.");return a(i,o)},useStoreApi:()=>{const i=A.useContext(e);if(!i)throw new Error("Seems like you have not used zustand provider as an ancestor.");return A.useMemo(()=>({getState:i.getState,setState:i.setState,subscribe:i.subscribe,destroy:i.destroy}),[i])}}}var PW={value:()=>{}};function Bc(){for(var e=0,t=arguments.length,r={},n;e<t;++e){if(!(n=arguments[e]+"")||n in r||/[\s.]/.test(n))throw new Error("illegal type: "+n);r[n]=[]}return new Du(r)}function Du(e){this._=e}function NW(e,t){return e.trim().split(/^|\s+/).map(function(r){var n="",i=r.indexOf(".");if(i>=0&&(n=r.slice(i+1),r=r.slice(0,i)),r&&!t.hasOwnProperty(r))throw new Error("unknown type: "+r);return{type:r,name:n}})}Du.prototype=Bc.prototype={constructor:Du,on:function(e,t){var r=this._,n=NW(e+"",r),i,o=-1,a=n.length;if(arguments.length<2){for(;++o<a;)if((i=(e=n[o]).type)&&(i=TW(r[i],e.name)))return i;return}if(t!=null&&typeof t!="function")throw new Error("invalid callback: "+t);for(;++o<a;)if(i=(e=n[o]).type)r[i]=bI(r[i],e.name,t);else if(t==null)for(i in r)r[i]=bI(r[i],e.name,null);return this},copy:function(){var e={},t=this._;for(var r in t)e[r]=t[r].slice();return new Du(e)},call:function(e,t){if((i=arguments.length-2)>0)for(var r=new Array(i),n=0,i,o;n<i;++n)r[n]=arguments[n+2];if(!this._.hasOwnProperty(e))throw new Error("unknown type: "+e);for(o=this._[e],n=0,i=o.length;n<i;++n)o[n].value.apply(t,r)},apply:function(e,t,r){if(!this._.hasOwnProperty(e))throw new Error("unknown type: "+e);for(var n=this._[e],i=0,o=n.length;i<o;++i)n[i].value.apply(t,r)}};function TW(e,t){for(var r=0,n=e.length,i;r<n;++r)if((i=e[r]).name===t)return i.value}function bI(e,t,r){for(var n=0,i=e.length;n<i;++n)if(e[n].name===t){e[n]=PW,e=e.slice(0,n).concat(e.slice(n+1));break}return r!=null&&e.push({name:t,value:r}),e}var Ob="http://www.w3.org/1999/xhtml";const xI={svg:"http://www.w3.org/2000/svg",xhtml:Ob,xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/"};function Fc(e){var t=e+="",r=t.indexOf(":");return r>=0&&(t=e.slice(0,r))!=="xmlns"&&(e=e.slice(r+1)),xI.hasOwnProperty(t)?{space:xI[t],local:e}:e}function AW(e){return function(){var t=this.ownerDocument,r=this.namespaceURI;return r===Ob&&t.documentElement.namespaceURI===Ob?t.createElement(e):t.createElementNS(r,e)}}function MW(e){return function(){return this.ownerDocument.createElementNS(e.space,e.local)}}function bj(e){var t=Fc(e);return(t.local?MW:AW)(t)}function DW(){}function _x(e){return e==null?DW:function(){return this.querySelector(e)}}function jW(e){typeof e!="function"&&(e=_x(e));for(var t=this._groups,r=t.length,n=new Array(r),i=0;i<r;++i)for(var o=t[i],a=o.length,u=n[i]=new Array(a),c,d,f=0;f<a;++f)(c=o[f])&&(d=e.call(c,c.__data__,f,o))&&("__data__"in c&&(d.__data__=c.__data__),u[f]=d);return new ur(n,this._parents)}function qW(e){return e==null?[]:Array.isArray(e)?e:Array.from(e)}function kW(){return[]}function xj(e){return e==null?kW:function(){return this.querySelectorAll(e)}}function LW(e){return function(){return qW(e.apply(this,arguments))}}function BW(e){typeof e=="function"?e=LW(e):e=xj(e);for(var t=this._groups,r=t.length,n=[],i=[],o=0;o<r;++o)for(var a=t[o],u=a.length,c,d=0;d<u;++d)(c=a[d])&&(n.push(e.call(c,c.__data__,d,a)),i.push(c));return new ur(n,i)}function wj(e){return function(){return this.matches(e)}}function _j(e){return function(t){return t.matches(e)}}var FW=Array.prototype.find;function $W(e){return function(){return FW.call(this.children,e)}}function zW(){return this.firstElementChild}function HW(e){return this.select(e==null?zW:$W(typeof e=="function"?e:_j(e)))}var UW=Array.prototype.filter;function VW(){return Array.from(this.children)}function WW(e){return function(){return UW.call(this.children,e)}}function GW(e){return this.selectAll(e==null?VW:WW(typeof e=="function"?e:_j(e)))}function KW(e){typeof e!="function"&&(e=wj(e));for(var t=this._groups,r=t.length,n=new Array(r),i=0;i<r;++i)for(var o=t[i],a=o.length,u=n[i]=[],c,d=0;d<a;++d)(c=o[d])&&e.call(c,c.__data__,d,o)&&u.push(c);return new ur(n,this._parents)}function Ej(e){return new Array(e.length)}function YW(){return new ur(this._enter||this._groups.map(Ej),this._parents)}function Vu(e,t){this.ownerDocument=e.ownerDocument,this.namespaceURI=e.namespaceURI,this._next=null,this._parent=e,this.__data__=t}Vu.prototype={constructor:Vu,appendChild:function(e){return this._parent.insertBefore(e,this._next)},insertBefore:function(e,t){return this._parent.insertBefore(e,t)},querySelector:function(e){return this._parent.querySelector(e)},querySelectorAll:function(e){return this._parent.querySelectorAll(e)}};function XW(e){return function(){return e}}function ZW(e,t,r,n,i,o){for(var a=0,u,c=t.length,d=o.length;a<d;++a)(u=t[a])?(u.__data__=o[a],n[a]=u):r[a]=new Vu(e,o[a]);for(;a<c;++a)(u=t[a])&&(i[a]=u)}function JW(e,t,r,n,i,o,a){var u,c,d=new Map,f=t.length,h=o.length,p=new Array(f),v;for(u=0;u<f;++u)(c=t[u])&&(p[u]=v=a.call(c,c.__data__,u,t)+"",d.has(v)?i[u]=c:d.set(v,c));for(u=0;u<h;++u)v=a.call(e,o[u],u,o)+"",(c=d.get(v))?(n[u]=c,c.__data__=o[u],d.delete(v)):r[u]=new Vu(e,o[u]);for(u=0;u<f;++u)(c=t[u])&&d.get(p[u])===c&&(i[u]=c)}function QW(e){return e.__data__}function e6(e,t){if(!arguments.length)return Array.from(this,QW);var r=t?JW:ZW,n=this._parents,i=this._groups;typeof e!="function"&&(e=XW(e));for(var o=i.length,a=new Array(o),u=new Array(o),c=new Array(o),d=0;d<o;++d){var f=n[d],h=i[d],p=h.length,v=t6(e.call(f,f&&f.__data__,d,n)),m=v.length,y=u[d]=new Array(m),x=a[d]=new Array(m),b=c[d]=new Array(p);r(f,h,y,x,b,v,t);for(var w=0,S=0,E,_;w<m;++w)if(E=y[w]){for(w>=S&&(S=w+1);!(_=x[S])&&++S<m;);E._next=_||null}}return a=new ur(a,n),a._enter=u,a._exit=c,a}function t6(e){return typeof e=="object"&&"length"in e?e:Array.from(e)}function r6(){return new ur(this._exit||this._groups.map(Ej),this._parents)}function n6(e,t,r){var n=this.enter(),i=this,o=this.exit();return typeof e=="function"?(n=e(n),n&&(n=n.selection())):n=n.append(e+""),t!=null&&(i=t(i),i&&(i=i.selection())),r==null?o.remove():r(o),n&&i?n.merge(i).order():i}function i6(e){for(var t=e.selection?e.selection():e,r=this._groups,n=t._groups,i=r.length,o=n.length,a=Math.min(i,o),u=new Array(i),c=0;c<a;++c)for(var d=r[c],f=n[c],h=d.length,p=u[c]=new Array(h),v,m=0;m<h;++m)(v=d[m]||f[m])&&(p[m]=v);for(;c<i;++c)u[c]=r[c];return new ur(u,this._parents)}function o6(){for(var e=this._groups,t=-1,r=e.length;++t<r;)for(var n=e[t],i=n.length-1,o=n[i],a;--i>=0;)(a=n[i])&&(o&&a.compareDocumentPosition(o)^4&&o.parentNode.insertBefore(a,o),o=a);return this}function a6(e){e||(e=s6);function t(h,p){return h&&p?e(h.__data__,p.__data__):!h-!p}for(var r=this._groups,n=r.length,i=new Array(n),o=0;o<n;++o){for(var a=r[o],u=a.length,c=i[o]=new Array(u),d,f=0;f<u;++f)(d=a[f])&&(c[f]=d);c.sort(t)}return new ur(i,this._parents).order()}function s6(e,t){return e<t?-1:e>t?1:e>=t?0:NaN}function u6(){var e=arguments[0];return arguments[0]=this,e.apply(null,arguments),this}function c6(){return Array.from(this)}function l6(){for(var e=this._groups,t=0,r=e.length;t<r;++t)for(var n=e[t],i=0,o=n.length;i<o;++i){var a=n[i];if(a)return a}return null}function f6(){let e=0;for(const t of this)++e;return e}function d6(){return!this.node()}function h6(e){for(var t=this._groups,r=0,n=t.length;r<n;++r)for(var i=t[r],o=0,a=i.length,u;o<a;++o)(u=i[o])&&e.call(u,u.__data__,o,i);return this}function p6(e){return function(){this.removeAttribute(e)}}function v6(e){return function(){this.removeAttributeNS(e.space,e.local)}}function g6(e,t){return function(){this.setAttribute(e,t)}}function m6(e,t){return function(){this.setAttributeNS(e.space,e.local,t)}}function y6(e,t){return function(){var r=t.apply(this,arguments);r==null?this.removeAttribute(e):this.setAttribute(e,r)}}function b6(e,t){return function(){var r=t.apply(this,arguments);r==null?this.removeAttributeNS(e.space,e.local):this.setAttributeNS(e.space,e.local,r)}}function x6(e,t){var r=Fc(e);if(arguments.length<2){var n=this.node();return r.local?n.getAttributeNS(r.space,r.local):n.getAttribute(r)}return this.each((t==null?r.local?v6:p6:typeof t=="function"?r.local?b6:y6:r.local?m6:g6)(r,t))}function Sj(e){return e.ownerDocument&&e.ownerDocument.defaultView||e.document&&e||e.defaultView}function w6(e){return function(){this.style.removeProperty(e)}}function _6(e,t,r){return function(){this.style.setProperty(e,t,r)}}function E6(e,t,r){return function(){var n=t.apply(this,arguments);n==null?this.style.removeProperty(e):this.style.setProperty(e,n,r)}}function S6(e,t,r){return arguments.length>1?this.each((t==null?w6:typeof t=="function"?E6:_6)(e,t,r??"")):vo(this.node(),e)}function vo(e,t){return e.style.getPropertyValue(t)||Sj(e).getComputedStyle(e,null).getPropertyValue(t)}function O6(e){return function(){delete this[e]}}function C6(e,t){return function(){this[e]=t}}function R6(e,t){return function(){var r=t.apply(this,arguments);r==null?delete this[e]:this[e]=r}}function I6(e,t){return arguments.length>1?this.each((t==null?O6:typeof t=="function"?R6:C6)(e,t)):this.node()[e]}function Oj(e){return e.trim().split(/^|\s+/)}function Ex(e){return e.classList||new Cj(e)}function Cj(e){this._node=e,this._names=Oj(e.getAttribute("class")||"")}Cj.prototype={add:function(e){var t=this._names.indexOf(e);t<0&&(this._names.push(e),this._node.setAttribute("class",this._names.join(" ")))},remove:function(e){var t=this._names.indexOf(e);t>=0&&(this._names.splice(t,1),this._node.setAttribute("class",this._names.join(" ")))},contains:function(e){return this._names.indexOf(e)>=0}};function Rj(e,t){for(var r=Ex(e),n=-1,i=t.length;++n<i;)r.add(t[n])}function Ij(e,t){for(var r=Ex(e),n=-1,i=t.length;++n<i;)r.remove(t[n])}function P6(e){return function(){Rj(this,e)}}function N6(e){return function(){Ij(this,e)}}function T6(e,t){return function(){(t.apply(this,arguments)?Rj:Ij)(this,e)}}function A6(e,t){var r=Oj(e+"");if(arguments.length<2){for(var n=Ex(this.node()),i=-1,o=r.length;++i<o;)if(!n.contains(r[i]))return!1;return!0}return this.each((typeof t=="function"?T6:t?P6:N6)(r,t))}function M6(){this.textContent=""}function D6(e){return function(){this.textContent=e}}function j6(e){return function(){var t=e.apply(this,arguments);this.textContent=t??""}}function q6(e){return arguments.length?this.each(e==null?M6:(typeof e=="function"?j6:D6)(e)):this.node().textContent}function k6(){this.innerHTML=""}function L6(e){return function(){this.innerHTML=e}}function B6(e){return function(){var t=e.apply(this,arguments);this.innerHTML=t??""}}function F6(e){return arguments.length?this.each(e==null?k6:(typeof e=="function"?B6:L6)(e)):this.node().innerHTML}function $6(){this.nextSibling&&this.parentNode.appendChild(this)}function z6(){return this.each($6)}function H6(){this.previousSibling&&this.parentNode.insertBefore(this,this.parentNode.firstChild)}function U6(){return this.each(H6)}function V6(e){var t=typeof e=="function"?e:bj(e);return this.select(function(){return this.appendChild(t.apply(this,arguments))})}function W6(){return null}function G6(e,t){var r=typeof e=="function"?e:bj(e),n=t==null?W6:typeof t=="function"?t:_x(t);return this.select(function(){return this.insertBefore(r.apply(this,arguments),n.apply(this,arguments)||null)})}function K6(){var e=this.parentNode;e&&e.removeChild(this)}function Y6(){return this.each(K6)}function X6(){var e=this.cloneNode(!1),t=this.parentNode;return t?t.insertBefore(e,this.nextSibling):e}function Z6(){var e=this.cloneNode(!0),t=this.parentNode;return t?t.insertBefore(e,this.nextSibling):e}function J6(e){return this.select(e?Z6:X6)}function Q6(e){return arguments.length?this.property("__data__",e):this.node().__data__}function e8(e){return function(t){e.call(this,t,this.__data__)}}function t8(e){return e.trim().split(/^|\s+/).map(function(t){var r="",n=t.indexOf(".");return n>=0&&(r=t.slice(n+1),t=t.slice(0,n)),{type:t,name:r}})}function r8(e){return function(){var t=this.__on;if(t){for(var r=0,n=-1,i=t.length,o;r<i;++r)o=t[r],(!e.type||o.type===e.type)&&o.name===e.name?this.removeEventListener(o.type,o.listener,o.options):t[++n]=o;++n?t.length=n:delete this.__on}}}function n8(e,t,r){return function(){var n=this.__on,i,o=e8(t);if(n){for(var a=0,u=n.length;a<u;++a)if((i=n[a]).type===e.type&&i.name===e.name){this.removeEventListener(i.type,i.listener,i.options),this.addEventListener(i.type,i.listener=o,i.options=r),i.value=t;return}}this.addEventListener(e.type,o,r),i={type:e.type,name:e.name,value:t,listener:o,options:r},n?n.push(i):this.__on=[i]}}function i8(e,t,r){var n=t8(e+""),i,o=n.length,a;if(arguments.length<2){var u=this.node().__on;if(u){for(var c=0,d=u.length,f;c<d;++c)for(i=0,f=u[c];i<o;++i)if((a=n[i]).type===f.type&&a.name===f.name)return f.value}return}for(u=t?n8:r8,i=0;i<o;++i)this.each(u(n[i],t,r));return this}function Pj(e,t,r){var n=Sj(e),i=n.CustomEvent;typeof i=="function"?i=new i(t,r):(i=n.document.createEvent("Event"),r?(i.initEvent(t,r.bubbles,r.cancelable),i.detail=r.detail):i.initEvent(t,!1,!1)),e.dispatchEvent(i)}function o8(e,t){return function(){return Pj(this,e,t)}}function a8(e,t){return function(){return Pj(this,e,t.apply(this,arguments))}}function s8(e,t){return this.each((typeof t=="function"?a8:o8)(e,t))}function*u8(){for(var e=this._groups,t=0,r=e.length;t<r;++t)for(var n=e[t],i=0,o=n.length,a;i<o;++i)(a=n[i])&&(yield a)}var Nj=[null];function ur(e,t){this._groups=e,this._parents=t}function Ga(){return new ur([[document.documentElement]],Nj)}function c8(){return this}ur.prototype=Ga.prototype={constructor:ur,select:jW,selectAll:BW,selectChild:HW,selectChildren:GW,filter:KW,data:e6,enter:YW,exit:r6,join:n6,merge:i6,selection:c8,order:o6,sort:a6,call:u6,nodes:c6,node:l6,size:f6,empty:d6,each:h6,attr:x6,style:S6,property:I6,classed:A6,text:q6,html:F6,raise:z6,lower:U6,append:V6,insert:G6,remove:Y6,clone:J6,datum:Q6,on:i8,dispatch:s8,[Symbol.iterator]:u8};function Mr(e){return typeof e=="string"?new ur([[document.querySelector(e)]],[document.documentElement]):new ur([[e]],Nj)}function l8(e){let t;for(;t=e.sourceEvent;)e=t;return e}function Xr(e,t){if(e=l8(e),t===void 0&&(t=e.currentTarget),t){var r=t.ownerSVGElement||t;if(r.createSVGPoint){var n=r.createSVGPoint();return n.x=e.clientX,n.y=e.clientY,n=n.matrixTransform(t.getScreenCTM().inverse()),[n.x,n.y]}if(t.getBoundingClientRect){var i=t.getBoundingClientRect();return[e.clientX-i.left-t.clientLeft,e.clientY-i.top-t.clientTop]}}return[e.pageX,e.pageY]}const f8={passive:!1},Aa={capture:!0,passive:!1};function fm(e){e.stopImmediatePropagation()}function ro(e){e.preventDefault(),e.stopImmediatePropagation()}function Tj(e){var t=e.document.documentElement,r=Mr(e).on("dragstart.drag",ro,Aa);"onselectstart"in t?r.on("selectstart.drag",ro,Aa):(t.__noselect=t.style.MozUserSelect,t.style.MozUserSelect="none")}function Aj(e,t){var r=e.document.documentElement,n=Mr(e).on("dragstart.drag",null);t&&(n.on("click.drag",ro,Aa),setTimeout(function(){n.on("click.drag",null)},0)),"onselectstart"in r?n.on("selectstart.drag",null):(r.style.MozUserSelect=r.__noselect,delete r.__noselect)}const cu=e=>()=>e;function Cb(e,{sourceEvent:t,subject:r,target:n,identifier:i,active:o,x:a,y:u,dx:c,dy:d,dispatch:f}){Object.defineProperties(this,{type:{value:e,enumerable:!0,configurable:!0},sourceEvent:{value:t,enumerable:!0,configurable:!0},subject:{value:r,enumerable:!0,configurable:!0},target:{value:n,enumerable:!0,configurable:!0},identifier:{value:i,enumerable:!0,configurable:!0},active:{value:o,enumerable:!0,configurable:!0},x:{value:a,enumerable:!0,configurable:!0},y:{value:u,enumerable:!0,configurable:!0},dx:{value:c,enumerable:!0,configurable:!0},dy:{value:d,enumerable:!0,configurable:!0},_:{value:f}})}Cb.prototype.on=function(){var e=this._.on.apply(this._,arguments);return e===this._?this:e};function d8(e){return!e.ctrlKey&&!e.button}function h8(){return this.parentNode}function p8(e,t){return t??{x:e.x,y:e.y}}function v8(){return navigator.maxTouchPoints||"ontouchstart"in this}function g8(){var e=d8,t=h8,r=p8,n=v8,i={},o=Bc("start","drag","end"),a=0,u,c,d,f,h=0;function p(E){E.on("mousedown.drag",v).filter(n).on("touchstart.drag",x).on("touchmove.drag",b,f8).on("touchend.drag touchcancel.drag",w).style("touch-action","none").style("-webkit-tap-highlight-color","rgba(0,0,0,0)")}function v(E,_){if(!(f||!e.call(this,E,_))){var R=S(this,t.call(this,E,_),E,_,"mouse");R&&(Mr(E.view).on("mousemove.drag",m,Aa).on("mouseup.drag",y,Aa),Tj(E.view),fm(E),d=!1,u=E.clientX,c=E.clientY,R("start",E))}}function m(E){if(ro(E),!d){var _=E.clientX-u,R=E.clientY-c;d=_*_+R*R>h}i.mouse("drag",E)}function y(E){Mr(E.view).on("mousemove.drag mouseup.drag",null),Aj(E.view,d),ro(E),i.mouse("end",E)}function x(E,_){if(e.call(this,E,_)){var R=E.changedTouches,I=t.call(this,E,_),N=R.length,D,k;for(D=0;D<N;++D)(k=S(this,I,E,_,R[D].identifier,R[D]))&&(fm(E),k("start",E,R[D]))}}function b(E){var _=E.changedTouches,R=_.length,I,N;for(I=0;I<R;++I)(N=i[_[I].identifier])&&(ro(E),N("drag",E,_[I]))}function w(E){var _=E.changedTouches,R=_.length,I,N;for(f&&clearTimeout(f),f=setTimeout(function(){f=null},500),I=0;I<R;++I)(N=i[_[I].identifier])&&(fm(E),N("end",E,_[I]))}function S(E,_,R,I,N,D){var k=o.copy(),B=Xr(D||R,_),L,j,T;if((T=r.call(E,new Cb("beforestart",{sourceEvent:R,target:p,identifier:N,active:a,x:B[0],y:B[1],dx:0,dy:0,dispatch:k}),I))!=null)return L=T.x-B[0]||0,j=T.y-B[1]||0,function F($,W,Y){var ee=B,H;switch($){case"start":i[N]=F,H=a++;break;case"end":delete i[N],--a;case"drag":B=Xr(Y||W,_),H=a;break}k.call($,E,new Cb($,{sourceEvent:W,subject:T,target:p,identifier:N,active:H,x:B[0]+L,y:B[1]+j,dx:B[0]-ee[0],dy:B[1]-ee[1],dispatch:k}),I)}}return p.filter=function(E){return arguments.length?(e=typeof E=="function"?E:cu(!!E),p):e},p.container=function(E){return arguments.length?(t=typeof E=="function"?E:cu(E),p):t},p.subject=function(E){return arguments.length?(r=typeof E=="function"?E:cu(E),p):r},p.touchable=function(E){return arguments.length?(n=typeof E=="function"?E:cu(!!E),p):n},p.on=function(){var E=o.on.apply(o,arguments);return E===o?p:E},p.clickDistance=function(E){return arguments.length?(h=(E=+E)*E,p):Math.sqrt(h)},p}function Sx(e,t,r){e.prototype=t.prototype=r,r.constructor=e}function Mj(e,t){var r=Object.create(e.prototype);for(var n in t)r[n]=t[n];return r}function Ka(){}var Ma=.7,Wu=1/Ma,no="\\s*([+-]?\\d+)\\s*",Da="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)\\s*",en="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)%\\s*",m8=/^#([0-9a-f]{3,8})$/,y8=new RegExp(`^rgb\\(${no},${no},${no}\\)$`),b8=new RegExp(`^rgb\\(${en},${en},${en}\\)$`),x8=new RegExp(`^rgba\\(${no},${no},${no},${Da}\\)$`),w8=new RegExp(`^rgba\\(${en},${en},${en},${Da}\\)$`),_8=new RegExp(`^hsl\\(${Da},${en},${en}\\)$`),E8=new RegExp(`^hsla\\(${Da},${en},${en},${Da}\\)$`),wI={aliceblue:15792383,antiquewhite:16444375,aqua:65535,aquamarine:8388564,azure:15794175,beige:16119260,bisque:16770244,black:0,blanchedalmond:16772045,blue:255,blueviolet:9055202,brown:10824234,burlywood:14596231,cadetblue:6266528,chartreuse:8388352,chocolate:13789470,coral:16744272,cornflowerblue:6591981,cornsilk:16775388,crimson:14423100,cyan:65535,darkblue:139,darkcyan:35723,darkgoldenrod:12092939,darkgray:11119017,darkgreen:25600,darkgrey:11119017,darkkhaki:12433259,darkmagenta:9109643,darkolivegreen:5597999,darkorange:16747520,darkorchid:10040012,darkred:9109504,darksalmon:15308410,darkseagreen:9419919,darkslateblue:4734347,darkslategray:3100495,darkslategrey:3100495,darkturquoise:52945,darkviolet:9699539,deeppink:16716947,deepskyblue:49151,dimgray:6908265,dimgrey:6908265,dodgerblue:2003199,firebrick:11674146,floralwhite:16775920,forestgreen:2263842,fuchsia:16711935,gainsboro:14474460,ghostwhite:16316671,gold:16766720,goldenrod:14329120,gray:8421504,green:32768,greenyellow:11403055,grey:8421504,honeydew:15794160,hotpink:16738740,indianred:13458524,indigo:4915330,ivory:16777200,khaki:15787660,lavender:15132410,lavenderblush:16773365,lawngreen:8190976,lemonchiffon:16775885,lightblue:11393254,lightcoral:15761536,lightcyan:14745599,lightgoldenrodyellow:16448210,lightgray:13882323,lightgreen:9498256,lightgrey:13882323,lightpink:16758465,lightsalmon:16752762,lightseagreen:2142890,lightskyblue:8900346,lightslategray:7833753,lightslategrey:7833753,lightsteelblue:11584734,lightyellow:16777184,lime:65280,limegreen:3329330,linen:16445670,magenta:16711935,maroon:8388608,mediumaquamarine:6737322,mediumblue:205,mediumorchid:12211667,mediumpurple:9662683,mediumseagreen:3978097,mediumslateblue:8087790,mediumspringgreen:64154,mediumturquoise:4772300,mediumvioletred:13047173,midnightblue:1644912,mintcream:16121850,mistyrose:16770273,moccasin:16770229,navajowhite:16768685,navy:128,oldlace:16643558,olive:8421376,olivedrab:7048739,orange:16753920,orangered:16729344,orchid:14315734,palegoldenrod:15657130,palegreen:10025880,paleturquoise:11529966,palevioletred:14381203,papayawhip:16773077,peachpuff:16767673,peru:13468991,pink:16761035,plum:14524637,powderblue:11591910,purple:8388736,rebeccapurple:6697881,red:16711680,rosybrown:12357519,royalblue:4286945,saddlebrown:9127187,salmon:16416882,sandybrown:16032864,seagreen:3050327,seashell:16774638,sienna:10506797,silver:12632256,skyblue:8900331,slateblue:6970061,slategray:7372944,slategrey:7372944,snow:16775930,springgreen:65407,steelblue:4620980,tan:13808780,teal:32896,thistle:14204888,tomato:16737095,turquoise:4251856,violet:15631086,wheat:16113331,white:16777215,whitesmoke:16119285,yellow:16776960,yellowgreen:10145074};Sx(Ka,ja,{copy(e){return Object.assign(new this.constructor,this,e)},displayable(){return this.rgb().displayable()},hex:_I,formatHex:_I,formatHex8:S8,formatHsl:O8,formatRgb:EI,toString:EI});function _I(){return this.rgb().formatHex()}function S8(){return this.rgb().formatHex8()}function O8(){return Dj(this).formatHsl()}function EI(){return this.rgb().formatRgb()}function ja(e){var t,r;return e=(e+"").trim().toLowerCase(),(t=m8.exec(e))?(r=t[1].length,t=parseInt(t[1],16),r===6?SI(t):r===3?new Wt(t>>8&15|t>>4&240,t>>4&15|t&240,(t&15)<<4|t&15,1):r===8?lu(t>>24&255,t>>16&255,t>>8&255,(t&255)/255):r===4?lu(t>>12&15|t>>8&240,t>>8&15|t>>4&240,t>>4&15|t&240,((t&15)<<4|t&15)/255):null):(t=y8.exec(e))?new Wt(t[1],t[2],t[3],1):(t=b8.exec(e))?new Wt(t[1]*255/100,t[2]*255/100,t[3]*255/100,1):(t=x8.exec(e))?lu(t[1],t[2],t[3],t[4]):(t=w8.exec(e))?lu(t[1]*255/100,t[2]*255/100,t[3]*255/100,t[4]):(t=_8.exec(e))?RI(t[1],t[2]/100,t[3]/100,1):(t=E8.exec(e))?RI(t[1],t[2]/100,t[3]/100,t[4]):wI.hasOwnProperty(e)?SI(wI[e]):e==="transparent"?new Wt(NaN,NaN,NaN,0):null}function SI(e){return new Wt(e>>16&255,e>>8&255,e&255,1)}function lu(e,t,r,n){return n<=0&&(e=t=r=NaN),new Wt(e,t,r,n)}function C8(e){return e instanceof Ka||(e=ja(e)),e?(e=e.rgb(),new Wt(e.r,e.g,e.b,e.opacity)):new Wt}function Rb(e,t,r,n){return arguments.length===1?C8(e):new Wt(e,t,r,n??1)}function Wt(e,t,r,n){this.r=+e,this.g=+t,this.b=+r,this.opacity=+n}Sx(Wt,Rb,Mj(Ka,{brighter(e){return e=e==null?Wu:Math.pow(Wu,e),new Wt(this.r*e,this.g*e,this.b*e,this.opacity)},darker(e){return e=e==null?Ma:Math.pow(Ma,e),new Wt(this.r*e,this.g*e,this.b*e,this.opacity)},rgb(){return this},clamp(){return new Wt(li(this.r),li(this.g),li(this.b),Gu(this.opacity))},displayable(){return-.5<=this.r&&this.r<255.5&&-.5<=this.g&&this.g<255.5&&-.5<=this.b&&this.b<255.5&&0<=this.opacity&&this.opacity<=1},hex:OI,formatHex:OI,formatHex8:R8,formatRgb:CI,toString:CI}));function OI(){return`#${ui(this.r)}${ui(this.g)}${ui(this.b)}`}function R8(){return`#${ui(this.r)}${ui(this.g)}${ui(this.b)}${ui((isNaN(this.opacity)?1:this.opacity)*255)}`}function CI(){const e=Gu(this.opacity);return`${e===1?"rgb(":"rgba("}${li(this.r)}, ${li(this.g)}, ${li(this.b)}${e===1?")":`, ${e})`}`}function Gu(e){return isNaN(e)?1:Math.max(0,Math.min(1,e))}function li(e){return Math.max(0,Math.min(255,Math.round(e)||0))}function ui(e){return e=li(e),(e<16?"0":"")+e.toString(16)}function RI(e,t,r,n){return n<=0?e=t=r=NaN:r<=0||r>=1?e=t=NaN:t<=0&&(e=NaN),new Dr(e,t,r,n)}function Dj(e){if(e instanceof Dr)return new Dr(e.h,e.s,e.l,e.opacity);if(e instanceof Ka||(e=ja(e)),!e)return new Dr;if(e instanceof Dr)return e;e=e.rgb();var t=e.r/255,r=e.g/255,n=e.b/255,i=Math.min(t,r,n),o=Math.max(t,r,n),a=NaN,u=o-i,c=(o+i)/2;return u?(t===o?a=(r-n)/u+(r<n)*6:r===o?a=(n-t)/u+2:a=(t-r)/u+4,u/=c<.5?o+i:2-o-i,a*=60):u=c>0&&c<1?0:a,new Dr(a,u,c,e.opacity)}function I8(e,t,r,n){return arguments.length===1?Dj(e):new Dr(e,t,r,n??1)}function Dr(e,t,r,n){this.h=+e,this.s=+t,this.l=+r,this.opacity=+n}Sx(Dr,I8,Mj(Ka,{brighter(e){return e=e==null?Wu:Math.pow(Wu,e),new Dr(this.h,this.s,this.l*e,this.opacity)},darker(e){return e=e==null?Ma:Math.pow(Ma,e),new Dr(this.h,this.s,this.l*e,this.opacity)},rgb(){var e=this.h%360+(this.h<0)*360,t=isNaN(e)||isNaN(this.s)?0:this.s,r=this.l,n=r+(r<.5?r:1-r)*t,i=2*r-n;return new Wt(dm(e>=240?e-240:e+120,i,n),dm(e,i,n),dm(e<120?e+240:e-120,i,n),this.opacity)},clamp(){return new Dr(II(this.h),fu(this.s),fu(this.l),Gu(this.opacity))},displayable(){return(0<=this.s&&this.s<=1||isNaN(this.s))&&0<=this.l&&this.l<=1&&0<=this.opacity&&this.opacity<=1},formatHsl(){const e=Gu(this.opacity);return`${e===1?"hsl(":"hsla("}${II(this.h)}, ${fu(this.s)*100}%, ${fu(this.l)*100}%${e===1?")":`, ${e})`}`}}));function II(e){return e=(e||0)%360,e<0?e+360:e}function fu(e){return Math.max(0,Math.min(1,e||0))}function dm(e,t,r){return(e<60?t+(r-t)*e/60:e<180?r:e<240?t+(r-t)*(240-e)/60:t)*255}const jj=e=>()=>e;function P8(e,t){return function(r){return e+r*t}}function N8(e,t,r){return e=Math.pow(e,r),t=Math.pow(t,r)-e,r=1/r,function(n){return Math.pow(e+n*t,r)}}function T8(e){return(e=+e)==1?qj:function(t,r){return r-t?N8(t,r,e):jj(isNaN(t)?r:t)}}function qj(e,t){var r=t-e;return r?P8(e,r):jj(isNaN(e)?t:e)}const PI=(function e(t){var r=T8(t);function n(i,o){var a=r((i=Rb(i)).r,(o=Rb(o)).r),u=r(i.g,o.g),c=r(i.b,o.b),d=qj(i.opacity,o.opacity);return function(f){return i.r=a(f),i.g=u(f),i.b=c(f),i.opacity=d(f),i+""}}return n.gamma=e,n})(1);function Bn(e,t){return e=+e,t=+t,function(r){return e*(1-r)+t*r}}var Ib=/[-+]?(?:\d+\.?\d*|\.?\d+)(?:[eE][-+]?\d+)?/g,hm=new RegExp(Ib.source,"g");function A8(e){return function(){return e}}function M8(e){return function(t){return e(t)+""}}function D8(e,t){var r=Ib.lastIndex=hm.lastIndex=0,n,i,o,a=-1,u=[],c=[];for(e=e+"",t=t+"";(n=Ib.exec(e))&&(i=hm.exec(t));)(o=i.index)>r&&(o=t.slice(r,o),u[a]?u[a]+=o:u[++a]=o),(n=n[0])===(i=i[0])?u[a]?u[a]+=i:u[++a]=i:(u[++a]=null,c.push({i:a,x:Bn(n,i)})),r=hm.lastIndex;return r<t.length&&(o=t.slice(r),u[a]?u[a]+=o:u[++a]=o),u.length<2?c[0]?M8(c[0].x):A8(t):(t=c.length,function(d){for(var f=0,h;f<t;++f)u[(h=c[f]).i]=h.x(d);return u.join("")})}var NI=180/Math.PI,Pb={translateX:0,translateY:0,rotate:0,skewX:0,scaleX:1,scaleY:1};function kj(e,t,r,n,i,o){var a,u,c;return(a=Math.sqrt(e*e+t*t))&&(e/=a,t/=a),(c=e*r+t*n)&&(r-=e*c,n-=t*c),(u=Math.sqrt(r*r+n*n))&&(r/=u,n/=u,c/=u),e*n<t*r&&(e=-e,t=-t,c=-c,a=-a),{translateX:i,translateY:o,rotate:Math.atan2(t,e)*NI,skewX:Math.atan(c)*NI,scaleX:a,scaleY:u}}var du;function j8(e){const t=new(typeof DOMMatrix=="function"?DOMMatrix:WebKitCSSMatrix)(e+"");return t.isIdentity?Pb:kj(t.a,t.b,t.c,t.d,t.e,t.f)}function q8(e){return e==null||(du||(du=document.createElementNS("http://www.w3.org/2000/svg","g")),du.setAttribute("transform",e),!(e=du.transform.baseVal.consolidate()))?Pb:(e=e.matrix,kj(e.a,e.b,e.c,e.d,e.e,e.f))}function Lj(e,t,r,n){function i(d){return d.length?d.pop()+" ":""}function o(d,f,h,p,v,m){if(d!==h||f!==p){var y=v.push("translate(",null,t,null,r);m.push({i:y-4,x:Bn(d,h)},{i:y-2,x:Bn(f,p)})}else(h||p)&&v.push("translate("+h+t+p+r)}function a(d,f,h,p){d!==f?(d-f>180?f+=360:f-d>180&&(d+=360),p.push({i:h.push(i(h)+"rotate(",null,n)-2,x:Bn(d,f)})):f&&h.push(i(h)+"rotate("+f+n)}function u(d,f,h,p){d!==f?p.push({i:h.push(i(h)+"skewX(",null,n)-2,x:Bn(d,f)}):f&&h.push(i(h)+"skewX("+f+n)}function c(d,f,h,p,v,m){if(d!==h||f!==p){var y=v.push(i(v)+"scale(",null,",",null,")");m.push({i:y-4,x:Bn(d,h)},{i:y-2,x:Bn(f,p)})}else(h!==1||p!==1)&&v.push(i(v)+"scale("+h+","+p+")")}return function(d,f){var h=[],p=[];return d=e(d),f=e(f),o(d.translateX,d.translateY,f.translateX,f.translateY,h,p),a(d.rotate,f.rotate,h,p),u(d.skewX,f.skewX,h,p),c(d.scaleX,d.scaleY,f.scaleX,f.scaleY,h,p),d=f=null,function(v){for(var m=-1,y=p.length,x;++m<y;)h[(x=p[m]).i]=x.x(v);return h.join("")}}}var k8=Lj(j8,"px, ","px)","deg)"),L8=Lj(q8,", ",")",")"),B8=1e-12;function TI(e){return((e=Math.exp(e))+1/e)/2}function F8(e){return((e=Math.exp(e))-1/e)/2}function $8(e){return((e=Math.exp(2*e))-1)/(e+1)}const z8=(function e(t,r,n){function i(o,a){var u=o[0],c=o[1],d=o[2],f=a[0],h=a[1],p=a[2],v=f-u,m=h-c,y=v*v+m*m,x,b;if(y<B8)b=Math.log(p/d)/t,x=function(I){return[u+I*v,c+I*m,d*Math.exp(t*I*b)]};else{var w=Math.sqrt(y),S=(p*p-d*d+n*y)/(2*d*r*w),E=(p*p-d*d-n*y)/(2*p*r*w),_=Math.log(Math.sqrt(S*S+1)-S),R=Math.log(Math.sqrt(E*E+1)-E);b=(R-_)/t,x=function(I){var N=I*b,D=TI(_),k=d/(r*w)*(D*$8(t*N+_)-F8(_));return[u+k*v,c+k*m,d*D/TI(t*N+_)]}}return x.duration=b*1e3*t/Math.SQRT2,x}return i.rho=function(o){var a=Math.max(.001,+o),u=a*a,c=u*u;return e(a,u,c)},i})(Math.SQRT2,2,4);var go=0,wa=0,Jo=0,Bj=1e3,Ku,_a,Yu=0,gi=0,$c=0,qa=typeof performance=="object"&&performance.now?performance:Date,Fj=typeof window=="object"&&window.requestAnimationFrame?window.requestAnimationFrame.bind(window):function(e){setTimeout(e,17)};function Ox(){return gi||(Fj(H8),gi=qa.now()+$c)}function H8(){gi=0}function Xu(){this._call=this._time=this._next=null}Xu.prototype=$j.prototype={constructor:Xu,restart:function(e,t,r){if(typeof e!="function")throw new TypeError("callback is not a function");r=(r==null?Ox():+r)+(t==null?0:+t),!this._next&&_a!==this&&(_a?_a._next=this:Ku=this,_a=this),this._call=e,this._time=r,Nb()},stop:function(){this._call&&(this._call=null,this._time=1/0,Nb())}};function $j(e,t,r){var n=new Xu;return n.restart(e,t,r),n}function U8(){Ox(),++go;for(var e=Ku,t;e;)(t=gi-e._time)>=0&&e._call.call(void 0,t),e=e._next;--go}function AI(){gi=(Yu=qa.now())+$c,go=wa=0;try{U8()}finally{go=0,W8(),gi=0}}function V8(){var e=qa.now(),t=e-Yu;t>Bj&&($c-=t,Yu=e)}function W8(){for(var e,t=Ku,r,n=1/0;t;)t._call?(n>t._time&&(n=t._time),e=t,t=t._next):(r=t._next,t._next=null,t=e?e._next=r:Ku=r);_a=e,Nb(n)}function Nb(e){if(!go){wa&&(wa=clearTimeout(wa));var t=e-gi;t>24?(e<1/0&&(wa=setTimeout(AI,e-qa.now()-$c)),Jo&&(Jo=clearInterval(Jo))):(Jo||(Yu=qa.now(),Jo=setInterval(V8,Bj)),go=1,Fj(AI))}}function MI(e,t,r){var n=new Xu;return t=t==null?0:+t,n.restart(i=>{n.stop(),e(i+t)},t,r),n}var G8=Bc("start","end","cancel","interrupt"),K8=[],zj=0,DI=1,Tb=2,ju=3,jI=4,Ab=5,qu=6;function zc(e,t,r,n,i,o){var a=e.__transition;if(!a)e.__transition={};else if(r in a)return;Y8(e,r,{name:t,index:n,group:i,on:G8,tween:K8,time:o.time,delay:o.delay,duration:o.duration,ease:o.ease,timer:null,state:zj})}function Cx(e,t){var r=$r(e,t);if(r.state>zj)throw new Error("too late; already scheduled");return r}function an(e,t){var r=$r(e,t);if(r.state>ju)throw new Error("too late; already running");return r}function $r(e,t){var r=e.__transition;if(!r||!(r=r[t]))throw new Error("transition not found");return r}function Y8(e,t,r){var n=e.__transition,i;n[t]=r,r.timer=$j(o,0,r.time);function o(d){r.state=DI,r.timer.restart(a,r.delay,r.time),r.delay<=d&&a(d-r.delay)}function a(d){var f,h,p,v;if(r.state!==DI)return c();for(f in n)if(v=n[f],v.name===r.name){if(v.state===ju)return MI(a);v.state===jI?(v.state=qu,v.timer.stop(),v.on.call("interrupt",e,e.__data__,v.index,v.group),delete n[f]):+f<t&&(v.state=qu,v.timer.stop(),v.on.call("cancel",e,e.__data__,v.index,v.group),delete n[f])}if(MI(function(){r.state===ju&&(r.state=jI,r.timer.restart(u,r.delay,r.time),u(d))}),r.state=Tb,r.on.call("start",e,e.__data__,r.index,r.group),r.state===Tb){for(r.state=ju,i=new Array(p=r.tween.length),f=0,h=-1;f<p;++f)(v=r.tween[f].value.call(e,e.__data__,r.index,r.group))&&(i[++h]=v);i.length=h+1}}function u(d){for(var f=d<r.duration?r.ease.call(null,d/r.duration):(r.timer.restart(c),r.state=Ab,1),h=-1,p=i.length;++h<p;)i[h].call(e,f);r.state===Ab&&(r.on.call("end",e,e.__data__,r.index,r.group),c())}function c(){r.state=qu,r.timer.stop(),delete n[t];for(var d in n)return;delete e.__transition}}function ku(e,t){var r=e.__transition,n,i,o=!0,a;if(r){t=t==null?null:t+"";for(a in r){if((n=r[a]).name!==t){o=!1;continue}i=n.state>Tb&&n.state<Ab,n.state=qu,n.timer.stop(),n.on.call(i?"interrupt":"cancel",e,e.__data__,n.index,n.group),delete r[a]}o&&delete e.__transition}}function X8(e){return this.each(function(){ku(this,e)})}function Z8(e,t){var r,n;return function(){var i=an(this,e),o=i.tween;if(o!==r){n=r=o;for(var a=0,u=n.length;a<u;++a)if(n[a].name===t){n=n.slice(),n.splice(a,1);break}}i.tween=n}}function J8(e,t,r){var n,i;if(typeof r!="function")throw new Error;return function(){var o=an(this,e),a=o.tween;if(a!==n){i=(n=a).slice();for(var u={name:t,value:r},c=0,d=i.length;c<d;++c)if(i[c].name===t){i[c]=u;break}c===d&&i.push(u)}o.tween=i}}function Q8(e,t){var r=this._id;if(e+="",arguments.length<2){for(var n=$r(this.node(),r).tween,i=0,o=n.length,a;i<o;++i)if((a=n[i]).name===e)return a.value;return null}return this.each((t==null?Z8:J8)(r,e,t))}function Rx(e,t,r){var n=e._id;return e.each(function(){var i=an(this,n);(i.value||(i.value={}))[t]=r.apply(this,arguments)}),function(i){return $r(i,n).value[t]}}function Hj(e,t){var r;return(typeof t=="number"?Bn:t instanceof ja?PI:(r=ja(t))?(t=r,PI):D8)(e,t)}function eG(e){return function(){this.removeAttribute(e)}}function tG(e){return function(){this.removeAttributeNS(e.space,e.local)}}function rG(e,t,r){var n,i=r+"",o;return function(){var a=this.getAttribute(e);return a===i?null:a===n?o:o=t(n=a,r)}}function nG(e,t,r){var n,i=r+"",o;return function(){var a=this.getAttributeNS(e.space,e.local);return a===i?null:a===n?o:o=t(n=a,r)}}function iG(e,t,r){var n,i,o;return function(){var a,u=r(this),c;return u==null?void this.removeAttribute(e):(a=this.getAttribute(e),c=u+"",a===c?null:a===n&&c===i?o:(i=c,o=t(n=a,u)))}}function oG(e,t,r){var n,i,o;return function(){var a,u=r(this),c;return u==null?void this.removeAttributeNS(e.space,e.local):(a=this.getAttributeNS(e.space,e.local),c=u+"",a===c?null:a===n&&c===i?o:(i=c,o=t(n=a,u)))}}function aG(e,t){var r=Fc(e),n=r==="transform"?L8:Hj;return this.attrTween(e,typeof t=="function"?(r.local?oG:iG)(r,n,Rx(this,"attr."+e,t)):t==null?(r.local?tG:eG)(r):(r.local?nG:rG)(r,n,t))}function sG(e,t){return function(r){this.setAttribute(e,t.call(this,r))}}function uG(e,t){return function(r){this.setAttributeNS(e.space,e.local,t.call(this,r))}}function cG(e,t){var r,n;function i(){var o=t.apply(this,arguments);return o!==n&&(r=(n=o)&&uG(e,o)),r}return i._value=t,i}function lG(e,t){var r,n;function i(){var o=t.apply(this,arguments);return o!==n&&(r=(n=o)&&sG(e,o)),r}return i._value=t,i}function fG(e,t){var r="attr."+e;if(arguments.length<2)return(r=this.tween(r))&&r._value;if(t==null)return this.tween(r,null);if(typeof t!="function")throw new Error;var n=Fc(e);return this.tween(r,(n.local?cG:lG)(n,t))}function dG(e,t){return function(){Cx(this,e).delay=+t.apply(this,arguments)}}function hG(e,t){return t=+t,function(){Cx(this,e).delay=t}}function pG(e){var t=this._id;return arguments.length?this.each((typeof e=="function"?dG:hG)(t,e)):$r(this.node(),t).delay}function vG(e,t){return function(){an(this,e).duration=+t.apply(this,arguments)}}function gG(e,t){return t=+t,function(){an(this,e).duration=t}}function mG(e){var t=this._id;return arguments.length?this.each((typeof e=="function"?vG:gG)(t,e)):$r(this.node(),t).duration}function yG(e,t){if(typeof t!="function")throw new Error;return function(){an(this,e).ease=t}}function bG(e){var t=this._id;return arguments.length?this.each(yG(t,e)):$r(this.node(),t).ease}function xG(e,t){return function(){var r=t.apply(this,arguments);if(typeof r!="function")throw new Error;an(this,e).ease=r}}function wG(e){if(typeof e!="function")throw new Error;return this.each(xG(this._id,e))}function _G(e){typeof e!="function"&&(e=wj(e));for(var t=this._groups,r=t.length,n=new Array(r),i=0;i<r;++i)for(var o=t[i],a=o.length,u=n[i]=[],c,d=0;d<a;++d)(c=o[d])&&e.call(c,c.__data__,d,o)&&u.push(c);return new xn(n,this._parents,this._name,this._id)}function EG(e){if(e._id!==this._id)throw new Error;for(var t=this._groups,r=e._groups,n=t.length,i=r.length,o=Math.min(n,i),a=new Array(n),u=0;u<o;++u)for(var c=t[u],d=r[u],f=c.length,h=a[u]=new Array(f),p,v=0;v<f;++v)(p=c[v]||d[v])&&(h[v]=p);for(;u<n;++u)a[u]=t[u];return new xn(a,this._parents,this._name,this._id)}function SG(e){return(e+"").trim().split(/^|\s+/).every(function(t){var r=t.indexOf(".");return r>=0&&(t=t.slice(0,r)),!t||t==="start"})}function OG(e,t,r){var n,i,o=SG(t)?Cx:an;return function(){var a=o(this,e),u=a.on;u!==n&&(i=(n=u).copy()).on(t,r),a.on=i}}function CG(e,t){var r=this._id;return arguments.length<2?$r(this.node(),r).on.on(e):this.each(OG(r,e,t))}function RG(e){return function(){var t=this.parentNode;for(var r in this.__transition)if(+r!==e)return;t&&t.removeChild(this)}}function IG(){return this.on("end.remove",RG(this._id))}function PG(e){var t=this._name,r=this._id;typeof e!="function"&&(e=_x(e));for(var n=this._groups,i=n.length,o=new Array(i),a=0;a<i;++a)for(var u=n[a],c=u.length,d=o[a]=new Array(c),f,h,p=0;p<c;++p)(f=u[p])&&(h=e.call(f,f.__data__,p,u))&&("__data__"in f&&(h.__data__=f.__data__),d[p]=h,zc(d[p],t,r,p,d,$r(f,r)));return new xn(o,this._parents,t,r)}function NG(e){var t=this._name,r=this._id;typeof e!="function"&&(e=xj(e));for(var n=this._groups,i=n.length,o=[],a=[],u=0;u<i;++u)for(var c=n[u],d=c.length,f,h=0;h<d;++h)if(f=c[h]){for(var p=e.call(f,f.__data__,h,c),v,m=$r(f,r),y=0,x=p.length;y<x;++y)(v=p[y])&&zc(v,t,r,y,p,m);o.push(p),a.push(f)}return new xn(o,a,t,r)}var TG=Ga.prototype.constructor;function AG(){return new TG(this._groups,this._parents)}function MG(e,t){var r,n,i;return function(){var o=vo(this,e),a=(this.style.removeProperty(e),vo(this,e));return o===a?null:o===r&&a===n?i:i=t(r=o,n=a)}}function Uj(e){return function(){this.style.removeProperty(e)}}function DG(e,t,r){var n,i=r+"",o;return function(){var a=vo(this,e);return a===i?null:a===n?o:o=t(n=a,r)}}function jG(e,t,r){var n,i,o;return function(){var a=vo(this,e),u=r(this),c=u+"";return u==null&&(c=u=(this.style.removeProperty(e),vo(this,e))),a===c?null:a===n&&c===i?o:(i=c,o=t(n=a,u))}}function qG(e,t){var r,n,i,o="style."+t,a="end."+o,u;return function(){var c=an(this,e),d=c.on,f=c.value[o]==null?u||(u=Uj(t)):void 0;(d!==r||i!==f)&&(n=(r=d).copy()).on(a,i=f),c.on=n}}function kG(e,t,r){var n=(e+="")=="transform"?k8:Hj;return t==null?this.styleTween(e,MG(e,n)).on("end.style."+e,Uj(e)):typeof t=="function"?this.styleTween(e,jG(e,n,Rx(this,"style."+e,t))).each(qG(this._id,e)):this.styleTween(e,DG(e,n,t),r).on("end.style."+e,null)}function LG(e,t,r){return function(n){this.style.setProperty(e,t.call(this,n),r)}}function BG(e,t,r){var n,i;function o(){var a=t.apply(this,arguments);return a!==i&&(n=(i=a)&&LG(e,a,r)),n}return o._value=t,o}function FG(e,t,r){var n="style."+(e+="");if(arguments.length<2)return(n=this.tween(n))&&n._value;if(t==null)return this.tween(n,null);if(typeof t!="function")throw new Error;return this.tween(n,BG(e,t,r??""))}function $G(e){return function(){this.textContent=e}}function zG(e){return function(){var t=e(this);this.textContent=t??""}}function HG(e){return this.tween("text",typeof e=="function"?zG(Rx(this,"text",e)):$G(e==null?"":e+""))}function UG(e){return function(t){this.textContent=e.call(this,t)}}function VG(e){var t,r;function n(){var i=e.apply(this,arguments);return i!==r&&(t=(r=i)&&UG(i)),t}return n._value=e,n}function WG(e){var t="text";if(arguments.length<1)return(t=this.tween(t))&&t._value;if(e==null)return this.tween(t,null);if(typeof e!="function")throw new Error;return this.tween(t,VG(e))}function GG(){for(var e=this._name,t=this._id,r=Vj(),n=this._groups,i=n.length,o=0;o<i;++o)for(var a=n[o],u=a.length,c,d=0;d<u;++d)if(c=a[d]){var f=$r(c,t);zc(c,e,r,d,a,{time:f.time+f.delay+f.duration,delay:0,duration:f.duration,ease:f.ease})}return new xn(n,this._parents,e,r)}function KG(){var e,t,r=this,n=r._id,i=r.size();return new Promise(function(o,a){var u={value:a},c={value:function(){--i===0&&o()}};r.each(function(){var d=an(this,n),f=d.on;f!==e&&(t=(e=f).copy(),t._.cancel.push(u),t._.interrupt.push(u),t._.end.push(c)),d.on=t}),i===0&&o()})}var YG=0;function xn(e,t,r,n){this._groups=e,this._parents=t,this._name=r,this._id=n}function Vj(){return++YG}var mn=Ga.prototype;xn.prototype={constructor:xn,select:PG,selectAll:NG,selectChild:mn.selectChild,selectChildren:mn.selectChildren,filter:_G,merge:EG,selection:AG,transition:GG,call:mn.call,nodes:mn.nodes,node:mn.node,size:mn.size,empty:mn.empty,each:mn.each,on:CG,attr:aG,attrTween:fG,style:kG,styleTween:FG,text:HG,textTween:WG,remove:IG,tween:Q8,delay:pG,duration:mG,ease:bG,easeVarying:wG,end:KG,[Symbol.iterator]:mn[Symbol.iterator]};function XG(e){return((e*=2)<=1?e*e*e:(e-=2)*e*e+2)/2}var ZG={time:null,delay:0,duration:250,ease:XG};function JG(e,t){for(var r;!(r=e.__transition)||!(r=r[t]);)if(!(e=e.parentNode))throw new Error(`transition ${t} not found`);return r}function QG(e){var t,r;e instanceof xn?(t=e._id,e=e._name):(t=Vj(),(r=ZG).time=Ox(),e=e==null?null:e+"");for(var n=this._groups,i=n.length,o=0;o<i;++o)for(var a=n[o],u=a.length,c,d=0;d<u;++d)(c=a[d])&&zc(c,e,t,d,a,r||JG(c,t));return new xn(n,this._parents,e,t)}Ga.prototype.interrupt=X8;Ga.prototype.transition=QG;const hu=e=>()=>e;function eK(e,{sourceEvent:t,target:r,transform:n,dispatch:i}){Object.defineProperties(this,{type:{value:e,enumerable:!0,configurable:!0},sourceEvent:{value:t,enumerable:!0,configurable:!0},target:{value:r,enumerable:!0,configurable:!0},transform:{value:n,enumerable:!0,configurable:!0},_:{value:i}})}function yn(e,t,r){this.k=e,this.x=t,this.y=r}yn.prototype={constructor:yn,scale:function(e){return e===1?this:new yn(this.k*e,this.x,this.y)},translate:function(e,t){return e===0&t===0?this:new yn(this.k,this.x+this.k*e,this.y+this.k*t)},apply:function(e){return[e[0]*this.k+this.x,e[1]*this.k+this.y]},applyX:function(e){return e*this.k+this.x},applyY:function(e){return e*this.k+this.y},invert:function(e){return[(e[0]-this.x)/this.k,(e[1]-this.y)/this.k]},invertX:function(e){return(e-this.x)/this.k},invertY:function(e){return(e-this.y)/this.k},rescaleX:function(e){return e.copy().domain(e.range().map(this.invertX,this).map(e.invert,e))},rescaleY:function(e){return e.copy().domain(e.range().map(this.invertY,this).map(e.invert,e))},toString:function(){return"translate("+this.x+","+this.y+") scale("+this.k+")"}};var fi=new yn(1,0,0);yn.prototype;function pm(e){e.stopImmediatePropagation()}function Qo(e){e.preventDefault(),e.stopImmediatePropagation()}function tK(e){return(!e.ctrlKey||e.type==="wheel")&&!e.button}function rK(){var e=this;return e instanceof SVGElement?(e=e.ownerSVGElement||e,e.hasAttribute("viewBox")?(e=e.viewBox.baseVal,[[e.x,e.y],[e.x+e.width,e.y+e.height]]):[[0,0],[e.width.baseVal.value,e.height.baseVal.value]]):[[0,0],[e.clientWidth,e.clientHeight]]}function qI(){return this.__zoom||fi}function nK(e){return-e.deltaY*(e.deltaMode===1?.05:e.deltaMode?1:.002)*(e.ctrlKey?10:1)}function iK(){return navigator.maxTouchPoints||"ontouchstart"in this}function oK(e,t,r){var n=e.invertX(t[0][0])-r[0][0],i=e.invertX(t[1][0])-r[1][0],o=e.invertY(t[0][1])-r[0][1],a=e.invertY(t[1][1])-r[1][1];return e.translate(i>n?(n+i)/2:Math.min(0,n)||Math.max(0,i),a>o?(o+a)/2:Math.min(0,o)||Math.max(0,a))}function aK(){var e=tK,t=rK,r=oK,n=nK,i=iK,o=[0,1/0],a=[[-1/0,-1/0],[1/0,1/0]],u=250,c=z8,d=Bc("start","zoom","end"),f,h,p,v=500,m=150,y=0,x=10;function b(T){T.property("__zoom",qI).on("wheel.zoom",N,{passive:!1}).on("mousedown.zoom",D).on("dblclick.zoom",k).filter(i).on("touchstart.zoom",B).on("touchmove.zoom",L).on("touchend.zoom touchcancel.zoom",j).style("-webkit-tap-highlight-color","rgba(0,0,0,0)")}b.transform=function(T,F,$,W){var Y=T.selection?T.selection():T;Y.property("__zoom",qI),T!==Y?_(T,F,$,W):Y.interrupt().each(function(){R(this,arguments).event(W).start().zoom(null,typeof F=="function"?F.apply(this,arguments):F).end()})},b.scaleBy=function(T,F,$,W){b.scaleTo(T,function(){var Y=this.__zoom.k,ee=typeof F=="function"?F.apply(this,arguments):F;return Y*ee},$,W)},b.scaleTo=function(T,F,$,W){b.transform(T,function(){var Y=t.apply(this,arguments),ee=this.__zoom,H=$==null?E(Y):typeof $=="function"?$.apply(this,arguments):$,Q=ee.invert(H),ce=typeof F=="function"?F.apply(this,arguments):F;return r(S(w(ee,ce),H,Q),Y,a)},$,W)},b.translateBy=function(T,F,$,W){b.transform(T,function(){return r(this.__zoom.translate(typeof F=="function"?F.apply(this,arguments):F,typeof $=="function"?$.apply(this,arguments):$),t.apply(this,arguments),a)},null,W)},b.translateTo=function(T,F,$,W,Y){b.transform(T,function(){var ee=t.apply(this,arguments),H=this.__zoom,Q=W==null?E(ee):typeof W=="function"?W.apply(this,arguments):W;return r(fi.translate(Q[0],Q[1]).scale(H.k).translate(typeof F=="function"?-F.apply(this,arguments):-F,typeof $=="function"?-$.apply(this,arguments):-$),ee,a)},W,Y)};function w(T,F){return F=Math.max(o[0],Math.min(o[1],F)),F===T.k?T:new yn(F,T.x,T.y)}function S(T,F,$){var W=F[0]-$[0]*T.k,Y=F[1]-$[1]*T.k;return W===T.x&&Y===T.y?T:new yn(T.k,W,Y)}function E(T){return[(+T[0][0]+ +T[1][0])/2,(+T[0][1]+ +T[1][1])/2]}function _(T,F,$,W){T.on("start.zoom",function(){R(this,arguments).event(W).start()}).on("interrupt.zoom end.zoom",function(){R(this,arguments).event(W).end()}).tween("zoom",function(){var Y=this,ee=arguments,H=R(Y,ee).event(W),Q=t.apply(Y,ee),ce=$==null?E(Q):typeof $=="function"?$.apply(Y,ee):$,se=Math.max(Q[1][0]-Q[0][0],Q[1][1]-Q[0][1]),z=Y.__zoom,G=typeof F=="function"?F.apply(Y,ee):F,J=c(z.invert(ce).concat(se/z.k),G.invert(ce).concat(se/G.k));return function(V){if(V===1)V=G;else{var K=J(V),ie=se/K[2];V=new yn(ie,ce[0]-K[0]*ie,ce[1]-K[1]*ie)}H.zoom(null,V)}})}function R(T,F,$){return!$&&T.__zooming||new I(T,F)}function I(T,F){this.that=T,this.args=F,this.active=0,this.sourceEvent=null,this.extent=t.apply(T,F),this.taps=0}I.prototype={event:function(T){return T&&(this.sourceEvent=T),this},start:function(){return++this.active===1&&(this.that.__zooming=this,this.emit("start")),this},zoom:function(T,F){return this.mouse&&T!=="mouse"&&(this.mouse[1]=F.invert(this.mouse[0])),this.touch0&&T!=="touch"&&(this.touch0[1]=F.invert(this.touch0[0])),this.touch1&&T!=="touch"&&(this.touch1[1]=F.invert(this.touch1[0])),this.that.__zoom=F,this.emit("zoom"),this},end:function(){return--this.active===0&&(delete this.that.__zooming,this.emit("end")),this},emit:function(T){var F=Mr(this.that).datum();d.call(T,this.that,new eK(T,{sourceEvent:this.sourceEvent,target:b,transform:this.that.__zoom,dispatch:d}),F)}};function N(T,...F){if(!e.apply(this,arguments))return;var $=R(this,F).event(T),W=this.__zoom,Y=Math.max(o[0],Math.min(o[1],W.k*Math.pow(2,n.apply(this,arguments)))),ee=Xr(T);if($.wheel)($.mouse[0][0]!==ee[0]||$.mouse[0][1]!==ee[1])&&($.mouse[1]=W.invert($.mouse[0]=ee)),clearTimeout($.wheel);else{if(W.k===Y)return;$.mouse=[ee,W.invert(ee)],ku(this),$.start()}Qo(T),$.wheel=setTimeout(H,m),$.zoom("mouse",r(S(w(W,Y),$.mouse[0],$.mouse[1]),$.extent,a));function H(){$.wheel=null,$.end()}}function D(T,...F){if(p||!e.apply(this,arguments))return;var $=T.currentTarget,W=R(this,F,!0).event(T),Y=Mr(T.view).on("mousemove.zoom",ce,!0).on("mouseup.zoom",se,!0),ee=Xr(T,$),H=T.clientX,Q=T.clientY;Tj(T.view),pm(T),W.mouse=[ee,this.__zoom.invert(ee)],ku(this),W.start();function ce(z){if(Qo(z),!W.moved){var G=z.clientX-H,J=z.clientY-Q;W.moved=G*G+J*J>y}W.event(z).zoom("mouse",r(S(W.that.__zoom,W.mouse[0]=Xr(z,$),W.mouse[1]),W.extent,a))}function se(z){Y.on("mousemove.zoom mouseup.zoom",null),Aj(z.view,W.moved),Qo(z),W.event(z).end()}}function k(T,...F){if(e.apply(this,arguments)){var $=this.__zoom,W=Xr(T.changedTouches?T.changedTouches[0]:T,this),Y=$.invert(W),ee=$.k*(T.shiftKey?.5:2),H=r(S(w($,ee),W,Y),t.apply(this,F),a);Qo(T),u>0?Mr(this).transition().duration(u).call(_,H,W,T):Mr(this).call(b.transform,H,W,T)}}function B(T,...F){if(e.apply(this,arguments)){var $=T.touches,W=$.length,Y=R(this,F,T.changedTouches.length===W).event(T),ee,H,Q,ce;for(pm(T),H=0;H<W;++H)Q=$[H],ce=Xr(Q,this),ce=[ce,this.__zoom.invert(ce),Q.identifier],Y.touch0?!Y.touch1&&Y.touch0[2]!==ce[2]&&(Y.touch1=ce,Y.taps=0):(Y.touch0=ce,ee=!0,Y.taps=1+!!f);f&&(f=clearTimeout(f)),ee&&(Y.taps<2&&(h=ce[0],f=setTimeout(function(){f=null},v)),ku(this),Y.start())}}function L(T,...F){if(this.__zooming){var $=R(this,F).event(T),W=T.changedTouches,Y=W.length,ee,H,Q,ce;for(Qo(T),ee=0;ee<Y;++ee)H=W[ee],Q=Xr(H,this),$.touch0&&$.touch0[2]===H.identifier?$.touch0[0]=Q:$.touch1&&$.touch1[2]===H.identifier&&($.touch1[0]=Q);if(H=$.that.__zoom,$.touch1){var se=$.touch0[0],z=$.touch0[1],G=$.touch1[0],J=$.touch1[1],V=(V=G[0]-se[0])*V+(V=G[1]-se[1])*V,K=(K=J[0]-z[0])*K+(K=J[1]-z[1])*K;H=w(H,Math.sqrt(V/K)),Q=[(se[0]+G[0])/2,(se[1]+G[1])/2],ce=[(z[0]+J[0])/2,(z[1]+J[1])/2]}else if($.touch0)Q=$.touch0[0],ce=$.touch0[1];else return;$.zoom("touch",r(S(H,Q,ce),$.extent,a))}}function j(T,...F){if(this.__zooming){var $=R(this,F).event(T),W=T.changedTouches,Y=W.length,ee,H;for(pm(T),p&&clearTimeout(p),p=setTimeout(function(){p=null},v),ee=0;ee<Y;++ee)H=W[ee],$.touch0&&$.touch0[2]===H.identifier?delete $.touch0:$.touch1&&$.touch1[2]===H.identifier&&delete $.touch1;if($.touch1&&!$.touch0&&($.touch0=$.touch1,delete $.touch1),$.touch0)$.touch0[1]=this.__zoom.invert($.touch0[0]);else if($.end(),$.taps===2&&(H=Xr(H,this),Math.hypot(h[0]-H[0],h[1]-H[1])<x)){var Q=Mr(this).on("dblclick.zoom");Q&&Q.apply(this,arguments)}}}return b.wheelDelta=function(T){return arguments.length?(n=typeof T=="function"?T:hu(+T),b):n},b.filter=function(T){return arguments.length?(e=typeof T=="function"?T:hu(!!T),b):e},b.touchable=function(T){return arguments.length?(i=typeof T=="function"?T:hu(!!T),b):i},b.extent=function(T){return arguments.length?(t=typeof T=="function"?T:hu([[+T[0][0],+T[0][1]],[+T[1][0],+T[1][1]]]),b):t},b.scaleExtent=function(T){return arguments.length?(o[0]=+T[0],o[1]=+T[1],b):[o[0],o[1]]},b.translateExtent=function(T){return arguments.length?(a[0][0]=+T[0][0],a[1][0]=+T[1][0],a[0][1]=+T[0][1],a[1][1]=+T[1][1],b):[[a[0][0],a[0][1]],[a[1][0],a[1][1]]]},b.constrain=function(T){return arguments.length?(r=T,b):r},b.duration=function(T){return arguments.length?(u=+T,b):u},b.interpolate=function(T){return arguments.length?(c=T,b):c},b.on=function(){var T=d.on.apply(d,arguments);return T===d?b:T},b.clickDistance=function(T){return arguments.length?(y=(T=+T)*T,b):Math.sqrt(y)},b.tapDistance=function(T){return arguments.length?(x=+T,b):x},b}function ze(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function Mb(e,t){(t==null||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r<t;r++)n[r]=e[r];return n}function Wj(e,t){if(e){if(typeof e=="string")return Mb(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if(r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set")return Array.from(e);if(r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return Mb(e,t)}}function sK(e){if(Array.isArray(e))return e}function uK(e,t){var r=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(r!=null){var n=[],i=!0,o=!1,a,u;try{for(r=r.call(e);!(i=(a=r.next()).done)&&(n.push(a.value),!(t&&n.length===t));i=!0);}catch(c){o=!0,u=c}finally{try{!i&&r.return!=null&&r.return()}finally{if(o)throw u}}return n}}function cK(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
6
|
-
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Be(e,t){return sK(e)||uK(e,t)||Wj(e,t)||cK()}var mo;(function(e){e.Strict="strict",e.Loose="loose"})(mo||(mo={}));var mi;(function(e){e.Lines="lines",e.Dots="dots"})(mi||(mi={}));var io;(function(e){e.Free="free",e.Vertical="vertical",e.Horizontal="horizontal"})(io||(io={}));var $n;(function(e){e.Bezier="default",e.Straight="straight",e.Step="step",e.SmoothStep="smoothstep",e.SimpleBezier="simplebezier"})($n||($n={}));var Zu;(function(e){e.Arrow="arrow",e.ArrowClosed="arrowclosed"})(Zu||(Zu={}));var xe;(function(e){e.Left="left",e.Top="top",e.Right="right",e.Bottom="bottom"})(xe||(xe={}));var Ix=function(t){return{width:t.offsetWidth,height:t.offsetHeight}},oo=function(t){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0,n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:1;return Math.min(Math.max(t,r),n)},Gj=function(t,r){return{x:oo(t.x,r[0][0],r[1][0]),y:oo(t.y,r[0][1],r[1][1])}},Kj=function(t){var r,n;return((r=t.getRootNode)===null||r===void 0?void 0:r.call(t))||((n=window)===null||n===void 0?void 0:n.document)},lK=function(t,r){return{x:Math.min(t.x,r.x),y:Math.min(t.y,r.y),x2:Math.max(t.x2,r.x2),y2:Math.max(t.y2,r.y2)}},Ju=function(t){var r=t.x,n=t.y,i=t.width,o=t.height;return{x:r,y:n,x2:r+i,y2:n+o}},fK=function(t){var r=t.x,n=t.y,i=t.x2,o=t.y2;return{x:r,y:n,width:i-r,height:o-n}},Yj=function(t){return!isNaN(t)&&isFinite(t)},Pt=Symbol("internals");function kI(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function Ea(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?kI(Object(r),!0).forEach(function(n){ze(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):kI(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function LI(e,t){var r=e.find(function(d){return d.id===t.parentNode});if(r){var n=t.position.x+t.width-r.width,i=t.position.y+t.height-r.height;if(n>0||i>0||t.position.x<0||t.position.y<0){var o,a;if(r.style=Ea({},r.style)||{},r.style.width=(o=r.style.width)!==null&&o!==void 0?o:r.width,r.style.height=(a=r.style.height)!==null&&a!==void 0?a:r.height,n>0&&(r.style.width+=n),i>0&&(r.style.height+=i),t.position.x<0){var u=Math.abs(t.position.x);r.position.x=r.position.x-u,r.style.width+=u,t.position.x=0}if(t.position.y<0){var c=Math.abs(t.position.y);r.position.y=r.position.y-c,r.style.height+=c,t.position.y=0}r.width=r.style.width,r.height=r.style.height}}}function Xj(e,t){if(e.some(function(n){return n.type==="reset"}))return e.filter(function(n){return n.type==="reset"}).map(function(n){return n.item});var r=e.filter(function(n){return n.type==="add"}).map(function(n){return n.item});return t.reduce(function(n,i){var o=e.find(function(c){return c.id===i.id});if(o)switch(o.type){case"select":return n.push(Ea(Ea({},i),{},{selected:o.selected})),n;case"position":{var a=Ea({},i);return typeof o.position<"u"&&(a.position=o.position),typeof o.positionAbsolute<"u"&&(a.positionAbsolute=o.positionAbsolute),typeof o.dragging<"u"&&(a.dragging=o.dragging),a.expandParent&&LI(n,a),n.push(a),n}case"dimensions":{var u=Ea({},i);return typeof o.dimensions<"u"&&(u.width=o.dimensions.width,u.height=o.dimensions.height),u.expandParent&&LI(n,u),n.push(u),n}case"remove":return n}return n.push(i),n},r)}function Zj(e,t){return Xj(e,t)}function dK(e,t){return Xj(e,t)}var Fn=function(t,r){return{id:t,type:"select",selected:r}};function Qi(e,t){return e.reduce(function(r,n){var i=t.includes(n.id);return!n.selected&&i?(n.selected=!0,r.push(Fn(n.id,!0))):n.selected&&!i&&(n.selected=!1,r.push(Fn(n.id,!1))),r},[])}function BI(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function Jj(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?BI(Object(r),!0).forEach(function(n){ze(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):BI(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}var FI=function(t,r,n){var i=r.querySelectorAll(t);if(!i||!i.length)return null;var o=Array.from(i),a=r.getBoundingClientRect();return o.map(function(u){var c=u.getBoundingClientRect();return Jj({id:u.getAttribute("data-handleid"),position:u.getAttribute("data-handlepos"),x:(c.left-a.left)/n,y:(c.top-a.top)/n},Ix(u))})};function ea(e,t,r){return r===void 0?r:function(n){var i=t().nodeInternals.get(e);r(n,Jj({},i))}}function Qj(e){var t=e.id,r=e.store,n=r.getState(),i=n.addSelectedNodes,o=n.unselectNodesAndEdges,a=n.multiSelectionActive,u=n.nodeInternals,c=u.get(t);r.setState({nodesSelectionActive:!1}),c.selected?c.selected&&a&&o({nodes:[c]}):i([t])}function $I(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function Ra(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?$I(Object(r),!0).forEach(function(n){ze(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):$I(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}var hK=function(t){return"id"in t&&"source"in t&&"target"in t},pK=function(t){var r=t.source,n=t.sourceHandle,i=t.target,o=t.targetHandle;return"reactflow__edge-".concat(r).concat(n||"","-").concat(i).concat(o||"")},Db=function(t,r){if(typeof t>"u")return"";if(typeof t=="string")return t;var n=r?"".concat(r,"__"):"";return"".concat(n).concat(Object.keys(t).sort().map(function(i){return"".concat(i,"=").concat(t[i])}).join("&"))},vK=function(t,r){return r.some(function(n){return n.source===t.source&&n.target===t.target&&(n.sourceHandle===t.sourceHandle||!n.sourceHandle&&!t.sourceHandle)&&(n.targetHandle===t.targetHandle||!n.targetHandle&&!t.targetHandle)})},gK=function(t,r){if(!t.source||!t.target)return process.env.NODE_ENV==="development"&&console.warn("[React Flow]: Can't create edge. An edge needs a source and a target. Help: https://reactflow.dev/error#600"),r;var n;return hK(t)?n=Ra({},t):n=Ra(Ra({},t),{},{id:pK(t)}),vK(n,r)?r:r.concat(n)},eq=function(t,r,n,i){var o=t.x,a=t.y,u=Be(r,3),c=u[0],d=u[1],f=u[2],h=Be(i,2),p=h[0],v=h[1],m={x:(o-c)/f,y:(a-d)/f};return n?{x:p*Math.round(m.x/p),y:v*Math.round(m.y/v)}:m},Px=function(t){if(t.length===0)return{x:0,y:0,width:0,height:0};var r=t.reduce(function(n,i){var o=i.positionAbsolute,a=i.position,u=i.width,c=i.height;return lK(n,Ju({x:o?o.x:a.x,y:o?o.y:a.y,width:u||0,height:c||0}))},{x:1/0,y:1/0,x2:-1/0,y2:-1/0});return fK(r)},tq=function(t,r){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:[0,0,1],i=Be(n,3),o=i[0],a=i[1],u=i[2],c=arguments.length>3&&arguments[3]!==void 0?arguments[3]:!1,d=arguments.length>4&&arguments[4]!==void 0?arguments[4]:!1,f=Ju({x:(r.x-o)/u,y:(r.y-a)/u,width:r.width/u,height:r.height/u}),h=[];return t.forEach(function(p){var v=p.positionAbsolute,m=p.width,y=p.height,x=p.selectable,b=x===void 0?!0:x;if(d&&!b)return!1;var w=Ju(Ra(Ra({},v),{},{width:m||0,height:y||0})),S=Math.max(0,Math.min(f.x2,w.x2)-Math.max(f.x,w.x)),E=Math.max(0,Math.min(f.y2,w.y2)-Math.max(f.y,w.y)),_=Math.ceil(S*E),R=typeof m>"u"||typeof y>"u"||m===null||y===null,I=c&&_>0,N=(m||0)*(y||0),D=R||I||_>=N;D&&h.push(p)}),h},rq=function(t,r){var n=t.map(function(i){return i.id});return r.filter(function(i){return n.includes(i.source)||n.includes(i.target)})},nq=function(t,r,n,i,o){var a=arguments.length>5&&arguments[5]!==void 0?arguments[5]:.1,u=r/(t.width*(1+a)),c=n/(t.height*(1+a)),d=Math.min(u,c),f=oo(d,i,o),h=t.x+t.width/2,p=t.y+t.height/2,v=r/2-h*f,m=n/2-p*f;return[v,m,f]},ai=function(t){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0;return t.transition().duration(r)};function zI(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function eo(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?zI(Object(r),!0).forEach(function(n){ze(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):zI(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function iq(e,t,r,n){var i,o,a,u,c,d,f,h,p,v,m,y;if(!e.parentNode)return n;var x=t.get(e.parentNode);return iq(x,t,r,{x:((i=n.x)!==null&&i!==void 0?i:0)+((o=(a=x.position)===null||a===void 0?void 0:a.x)!==null&&o!==void 0?o:0),y:((u=n.y)!==null&&u!==void 0?u:0)+((c=(d=x.position)===null||d===void 0?void 0:d.y)!==null&&c!==void 0?c:0),z:((f=(h=x[Pt])===null||h===void 0?void 0:h.z)!==null&&f!==void 0?f:0)>((p=n.z)!==null&&p!==void 0?p:0)?(v=(m=x[Pt])===null||m===void 0?void 0:m.z)!==null&&v!==void 0?v:0:(y=n.z)!==null&&y!==void 0?y:0})}function vm(e,t){var r=new Map,n={};return e.forEach(function(i){var o,a=Yj(i.zIndex)?i.zIndex:i.selected?1e3:0,u=t.get(i.id),c=eo(eo({width:u==null?void 0:u.width,height:u==null?void 0:u.height},i),{},{positionAbsolute:{x:i.position.x,y:i.position.y}});i.parentNode&&(c.parentNode=i.parentNode,n[i.parentNode]=!0),Object.defineProperty(c,Pt,{enumerable:!1,value:{handleBounds:u==null||(o=u[Pt])===null||o===void 0?void 0:o.handleBounds,z:a}}),r.set(i.id,c)}),r.forEach(function(i){if(i.parentNode&&!r.has(i.parentNode))throw new Error("Parent node ".concat(i.parentNode," not found"));if(i.parentNode||n[i.id]){var o,a,u=iq(i,r,n,eo(eo({},i.position),{},{z:(o=(a=i[Pt])===null||a===void 0?void 0:a.z)!==null&&o!==void 0?o:0})),c=u.x,d=u.y,f=u.z;i.positionAbsolute={x:c,y:d},i[Pt].z=f,n[i.id]&&(i[Pt].isParent=!0)}}),r}function oq(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},r=e(),n=r.nodeInternals,i=r.width,o=r.height,a=r.minZoom,u=r.maxZoom,c=r.d3Zoom,d=r.d3Selection,f=r.fitViewOnInitDone,h=r.fitViewOnInit;if((t.initial&&!f&&h||!t.initial)&&c&&d){var p=Array.from(n.values()).filter(function(N){return t.includeHiddenNodes?N.width&&N.height:!N.hidden}),v=p.every(function(N){return N.width&&N.height});if(p.length>0&&v){var m,y,x,b=Px(p),w=nq(b,i,o,(m=t.minZoom)!==null&&m!==void 0?m:a,(y=t.maxZoom)!==null&&y!==void 0?y:u,(x=t.padding)!==null&&x!==void 0?x:.1),S=Be(w,3),E=S[0],_=S[1],R=S[2],I=fi.translate(E,_).scale(R);return typeof t.duration=="number"&&t.duration>0?c.transform(ai(d,t.duration),I):c.transform(d,I),!0}}return!1}function mK(e,t){return e.forEach(function(r){var n=t.get(r.id);if(n){var i;t.set(n.id,eo(eo({},n),{},(i={},ze(i,Pt,n[Pt]),ze(i,"selected",r.selected),i)))}}),new Map(t)}function yK(e,t){return t.map(function(r){var n=e.find(function(i){return i.id===r.id});return n&&(r.selected=n.selected),r})}function pu(e){var t=e.changedNodes,r=e.changedEdges,n=e.get,i=e.set,o=n(),a=o.nodeInternals,u=o.edges,c=o.onNodesChange,d=o.onEdgesChange,f=o.hasDefaultNodes,h=o.hasDefaultEdges;t!=null&&t.length&&(f&&i({nodeInternals:mK(t,a)}),c==null||c(t)),r!=null&&r.length&&(h&&i({edges:yK(r,u)}),d==null||d(r))}var jb=[[Number.NEGATIVE_INFINITY,Number.NEGATIVE_INFINITY],[Number.POSITIVE_INFINITY,Number.POSITIVE_INFINITY]],HI={width:0,height:0,transform:[0,0,1],nodeInternals:new Map,edges:[],onNodesChange:null,onEdgesChange:null,hasDefaultNodes:!1,hasDefaultEdges:!1,d3Zoom:null,d3Selection:null,d3ZoomHandler:void 0,minZoom:.5,maxZoom:2,translateExtent:jb,nodeExtent:jb,nodesSelectionActive:!1,userSelectionActive:!1,connectionNodeId:null,connectionHandleId:null,connectionHandleType:"source",connectionPosition:{x:0,y:0},connectionMode:mo.Strict,domNode:null,snapGrid:[15,15],snapToGrid:!1,nodesDraggable:!0,nodesConnectable:!0,elementsSelectable:!0,fitViewOnInit:!1,fitViewOnInitDone:!1,fitViewOnInitOptions:void 0,multiSelectionActive:!1,reactFlowVersion:"10.3.17",connectionStartHandle:null,connectOnClick:!0};function UI(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function Kr(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?UI(Object(r),!0).forEach(function(n){ze(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):UI(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}var Nx=IW(),bK=Nx.Provider,gt=Nx.useStore,Ft=Nx.useStoreApi,xK=function(){return RW(function(t,r){return Kr(Kr({},HI),{},{setNodes:function(i){t({nodeInternals:vm(i,r().nodeInternals)})},setEdges:function(i){var o=r(),a=o.defaultEdgeOptions,u=a===void 0?{}:a;t({edges:i.map(function(c){return Kr(Kr({},u),c)})})},setDefaultNodesAndEdges:function(i,o){var a=typeof i<"u",u=typeof o<"u",c=a?vm(i,new Map):new Map,d=u?o:[];t({nodeInternals:c,edges:d,hasDefaultNodes:a,hasDefaultEdges:u})},updateNodeDimensions:function(i){var o=r(),a=o.onNodesChange,u=o.nodeInternals,c=o.fitViewOnInit,d=o.fitViewOnInitDone,f=o.fitViewOnInitOptions,h=o.domNode,p=h==null?void 0:h.querySelector(".react-flow__viewport");if(p){var v=window.getComputedStyle(p),m=new window.DOMMatrixReadOnly(v.transform),y=m.m22,x=i.reduce(function(w,S){var E=u.get(S.id);if(E){var _=Ix(S.nodeElement),R=!!(_.width&&_.height&&(E.width!==_.width||E.height!==_.height||S.forceUpdate));R&&(u.set(E.id,Kr(Kr({},E),{},ze({},Pt,Kr(Kr({},E[Pt]),{},{handleBounds:{source:FI(".source",S.nodeElement,y),target:FI(".target",S.nodeElement,y)}})),_)),w.push({id:E.id,type:"dimensions",dimensions:_}))}return w},[]),b=d||c&&!d&&oq(r,Kr({initial:!0},f));t({nodeInternals:new Map(u),fitViewOnInitDone:b}),(x==null?void 0:x.length)>0&&(a==null||a(x))}},updateNodePositions:function(i){var o=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!0,a=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!1,u=r(),c=u.onNodesChange,d=u.nodeInternals,f=u.hasDefaultNodes;if(f||c){var h=i.map(function(m){var y={id:m.id,type:"position",dragging:a};return o&&(y.positionAbsolute=m.positionAbsolute,y.position=m.position),y});if(h!=null&&h.length){if(f){var p=Zj(h,Array.from(d.values())),v=vm(p,d);t({nodeInternals:v})}c==null||c(h)}}},addSelectedNodes:function(i){var o=r(),a=o.multiSelectionActive,u=o.nodeInternals,c=o.edges,d,f=null;a?d=i.map(function(h){return Fn(h,!0)}):(d=Qi(Array.from(u.values()),i),f=Qi(c,[])),pu({changedNodes:d,changedEdges:f,get:r,set:t})},addSelectedEdges:function(i){var o=r(),a=o.multiSelectionActive,u=o.edges,c=o.nodeInternals,d,f=null;a?d=i.map(function(h){return Fn(h,!0)}):(d=Qi(u,i),f=Qi(Array.from(c.values()),[])),pu({changedNodes:f,changedEdges:d,get:r,set:t})},unselectNodesAndEdges:function(){var i=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},o=i.nodes,a=i.edges,u=r(),c=u.nodeInternals,d=u.edges,f=o||Array.from(c.values()),h=a||d,p=f.map(function(m){return m.selected=!1,Fn(m.id,!1)}),v=h.map(function(m){return Fn(m.id,!1)});pu({changedNodes:p,changedEdges:v,get:r,set:t})},setMinZoom:function(i){var o=r(),a=o.d3Zoom,u=o.maxZoom;a==null||a.scaleExtent([i,u]),t({minZoom:i})},setMaxZoom:function(i){var o=r(),a=o.d3Zoom,u=o.minZoom;a==null||a.scaleExtent([u,i]),t({maxZoom:i})},setTranslateExtent:function(i){var o=r(),a=o.d3Zoom;a==null||a.translateExtent(i),t({translateExtent:i})},resetSelectedElements:function(){var i=r(),o=i.nodeInternals,a=i.edges,u=Array.from(o.values()),c=u.filter(function(f){return f.selected}).map(function(f){return Fn(f.id,!1)}),d=a.filter(function(f){return f.selected}).map(function(f){return Fn(f.id,!1)});pu({changedNodes:c,changedEdges:d,get:r,set:t})},setNodeExtent:function(i){var o=r(),a=o.nodeInternals;a.forEach(function(u){u.positionAbsolute=Gj(u.position,i)}),t({nodeExtent:i,nodeInternals:new Map(a)})},reset:function(){return t(Kr({},HI))}})})};function cr(e){if(typeof e=="string"||typeof e=="number")return""+e;let t="";if(Array.isArray(e))for(let r=0,n;r<e.length;r++)(n=cr(e[r]))!==""&&(t+=(t&&" ")+n);else for(let r in e)e[r]&&(t+=(t&&" ")+r);return t}function Xt(e,t){if(Object.is(e,t))return!0;if(typeof e!="object"||e===null||typeof t!="object"||t===null)return!1;const r=Object.keys(e);if(r.length!==Object.keys(t).length)return!1;for(let n=0;n<r.length;n++)if(!Object.prototype.hasOwnProperty.call(t,r[n])||!Object.is(e[r[n]],t[r[n]]))return!1;return!0}function wK(e){if(Array.isArray(e))return Mb(e)}function _K(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function EK(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
|
|
7
|
-
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function di(e){return wK(e)||_K(e)||Wj(e)||EK()}var SK={zoomIn:function(){},zoomOut:function(){},zoomTo:function(t){},getZoom:function(){return 1},setViewport:function(t){},getViewport:function(){return{x:0,y:0,zoom:1}},fitView:function(){},setCenter:function(t,r){},fitBounds:function(t){},project:function(t){return t},viewportInitialized:!1},OK=function(t){return{d3Zoom:t.d3Zoom,d3Selection:t.d3Selection}},CK=function(){var t=Ft(),r=gt(OK,Xt),n=r.d3Zoom,i=r.d3Selection,o=A.useMemo(function(){return i&&n?{zoomIn:function(u){return n.scaleBy(ai(i,u==null?void 0:u.duration),1.2)},zoomOut:function(u){return n.scaleBy(ai(i,u==null?void 0:u.duration),1/1.2)},zoomTo:function(u,c){return n.scaleTo(ai(i,c==null?void 0:c.duration),u)},getZoom:function(){return t.getState().transform[2]},setViewport:function(u,c){var d,f,h,p=Be(t.getState().transform,3),v=p[0],m=p[1],y=p[2],x=fi.translate((d=u.x)!==null&&d!==void 0?d:v,(f=u.y)!==null&&f!==void 0?f:m).scale((h=u.zoom)!==null&&h!==void 0?h:y);n.transform(ai(i,c==null?void 0:c.duration),x)},getViewport:function(){var u=Be(t.getState().transform,3),c=u[0],d=u[1],f=u[2];return{x:c,y:d,zoom:f}},fitView:function(u){return oq(t.getState,u)},setCenter:function(u,c,d){var f=t.getState(),h=f.width,p=f.height,v=f.maxZoom,m=typeof(d==null?void 0:d.zoom)<"u"?d.zoom:v,y=h/2-u*m,x=p/2-c*m,b=fi.translate(y,x).scale(m);n.transform(ai(i,d==null?void 0:d.duration),b)},fitBounds:function(u,c){var d,f=t.getState(),h=f.width,p=f.height,v=f.minZoom,m=f.maxZoom,y=nq(u,h,p,v,m,(d=c==null?void 0:c.padding)!==null&&d!==void 0?d:.1),x=Be(y,3),b=x[0],w=x[1],S=x[2],E=fi.translate(b,w).scale(S);n.transform(ai(i,c==null?void 0:c.duration),E)},project:function(u){var c=t.getState(),d=c.transform,f=c.snapToGrid,h=c.snapGrid;return eq(u,d,f,h)},viewportInitialized:!0}:SK},[n,i]);return o};function VI(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function Gi(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?VI(Object(r),!0).forEach(function(n){ze(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):VI(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function aq(){var e=CK(),t=Ft(),r=A.useCallback(function(){var h=t.getState(),p=h.nodeInternals,v=Array.from(p.values());return v.map(function(m){return Gi({},m)})},[]),n=A.useCallback(function(h){var p=t.getState(),v=p.nodeInternals;return v.get(h)},[]),i=A.useCallback(function(){var h=t.getState(),p=h.edges,v=p===void 0?[]:p;return v.map(function(m){return Gi({},m)})},[]),o=A.useCallback(function(h){var p=t.getState(),v=p.edges,m=v===void 0?[]:v;return m.find(function(y){return y.id===h})},[]),a=A.useCallback(function(h){var p=t.getState(),v=p.nodeInternals,m=p.setNodes,y=p.hasDefaultNodes,x=p.onNodesChange,b=Array.from(v.values()),w=typeof h=="function"?h(b):h;if(y)m(w);else if(x){var S=w.length===0?b.map(function(E){return{type:"remove",id:E.id}}):w.map(function(E){return{item:E,type:"reset"}});x(S)}},[]),u=A.useCallback(function(h){var p=t.getState(),v=p.edges,m=v===void 0?[]:v,y=p.setEdges,x=p.hasDefaultEdges,b=p.onEdgesChange,w=typeof h=="function"?h(m):h;if(x)y(w);else if(b){var S=w.length===0?m.map(function(E){return{type:"remove",id:E.id}}):w.map(function(E){return{item:E,type:"reset"}});b(S)}},[]),c=A.useCallback(function(h){var p=Array.isArray(h)?h:[h],v=t.getState(),m=v.nodeInternals,y=v.setNodes,x=v.hasDefaultNodes,b=v.onNodesChange;if(x){var w=Array.from(m.values()),S=[].concat(w,di(p));y(S)}else if(b){var E=p.map(function(_){return{item:_,type:"add"}});b(E)}},[]),d=A.useCallback(function(h){var p=Array.isArray(h)?h:[h],v=t.getState(),m=v.edges,y=m===void 0?[]:m,x=v.setEdges,b=v.hasDefaultEdges,w=v.onEdgesChange;if(b)x([].concat(di(y),di(p)));else if(w){var S=p.map(function(E){return{item:E,type:"add"}});w(S)}},[]),f=A.useCallback(function(){var h=t.getState(),p=h.nodeInternals,v=h.edges,m=v===void 0?[]:v,y=h.transform,x=Array.from(p.values()),b=Be(y,3),w=b[0],S=b[1],E=b[2];return{nodes:x.map(function(_){return Gi({},_)}),edges:m.map(function(_){return Gi({},_)}),viewport:{x:w,y:S,zoom:E}}},[]);return A.useMemo(function(){return Gi(Gi({},e),{},{getNodes:r,getNode:n,getEdges:i,getEdge:o,setNodes:a,setEdges:u,addNodes:c,addEdges:d,toObject:f})},[e,r,n,i,o,a,u,c,d,f])}function RK(e,t){if(e==null)return{};var r={},n=Object.keys(e),i,o;for(o=0;o<n.length;o++)i=n[o],!(t.indexOf(i)>=0)&&(r[i]=e[i]);return r}function Hc(e,t){if(e==null)return{};var r=RK(e,t),n,i;if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(i=0;i<o.length;i++)n=o[i],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(r[n]=e[n])}return r}function IK(){return A.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32"},A.createElement("path",{d:"M32 18.133H18.133V32h-4.266V18.133H0v-4.266h13.867V0h4.266v13.867H32z"}))}function PK(){return A.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 5"},A.createElement("path",{d:"M0 0h32v4.2H0z"}))}function NK(){return A.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 30"},A.createElement("path",{d:"M3.692 4.63c0-.53.4-.938.939-.938h5.215V0H4.708C2.13 0 0 2.054 0 4.63v5.216h3.692V4.631zM27.354 0h-5.2v3.692h5.17c.53 0 .984.4.984.939v5.215H32V4.631A4.624 4.624 0 0027.354 0zm.954 24.83c0 .532-.4.94-.939.94h-5.215v3.768h5.215c2.577 0 4.631-2.13 4.631-4.707v-5.139h-3.692v5.139zm-23.677.94c-.531 0-.939-.4-.939-.94v-5.138H0v5.139c0 2.577 2.13 4.707 4.708 4.707h5.138V25.77H4.631z"}))}function TK(){return A.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 25 32"},A.createElement("path",{d:"M21.333 10.667H19.81V7.619C19.81 3.429 16.38 0 12.19 0 8 0 4.571 3.429 4.571 7.619v3.048H3.048A3.056 3.056 0 000 13.714v15.238A3.056 3.056 0 003.048 32h18.285a3.056 3.056 0 003.048-3.048V13.714a3.056 3.056 0 00-3.048-3.047zM12.19 24.533a3.056 3.056 0 01-3.047-3.047 3.056 3.056 0 013.047-3.048 3.056 3.056 0 013.048 3.048 3.056 3.056 0 01-3.048 3.047zm4.724-13.866H7.467V7.619c0-2.59 2.133-4.724 4.723-4.724 2.591 0 4.724 2.133 4.724 4.724v3.048z"}))}function AK(){return A.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 25 32"},A.createElement("path",{d:"M21.333 10.667H19.81V7.619C19.81 3.429 16.38 0 12.19 0c-4.114 1.828-1.37 2.133.305 2.438 1.676.305 4.42 2.59 4.42 5.181v3.048H3.047A3.056 3.056 0 000 13.714v15.238A3.056 3.056 0 003.048 32h18.285a3.056 3.056 0 003.048-3.048V13.714a3.056 3.056 0 00-3.048-3.047zM12.19 24.533a3.056 3.056 0 01-3.047-3.047 3.056 3.056 0 013.047-3.048 3.056 3.056 0 013.048 3.048 3.056 3.056 0 01-3.048 3.047z"}))}var MK=["children","className"];function WI(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function DK(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?WI(Object(r),!0).forEach(function(n){ze(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):WI(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}var vu=function(t){var r=t.children,n=t.className,i=Hc(t,MK);return A.createElement("button",DK({type:"button",className:cr(["react-flow__controls-button",n])},i),r)},jK=function(t){return t.nodesDraggable&&t.nodesConnectable&&t.elementsSelectable},qK=function(t){var r=t.style,n=t.showZoom,i=n===void 0?!0:n,o=t.showFitView,a=o===void 0?!0:o,u=t.showInteractive,c=u===void 0?!0:u,d=t.fitViewOptions,f=t.onZoomIn,h=t.onZoomOut,p=t.onFitView,v=t.onInteractiveChange,m=t.className,y=t.children,x=Ft(),b=A.useState(!1),w=Be(b,2),S=w[0],E=w[1],_=gt(jK),R=aq(),I=R.zoomIn,N=R.zoomOut,D=R.fitView;if(A.useEffect(function(){E(!0)},[]),!S)return null;var k=function(){I==null||I(),f==null||f()},B=function(){N==null||N(),h==null||h()},L=function(){D==null||D(d),p==null||p()},j=function(){x.setState({nodesDraggable:!_,nodesConnectable:!_,elementsSelectable:!_}),v==null||v(!_)};return A.createElement("div",{className:cr(["react-flow__controls",m]),style:r},i&&A.createElement(A.Fragment,null,A.createElement(vu,{onClick:k,className:"react-flow__controls-zoomin",title:"zoom in","aria-label":"zoom in"},A.createElement(IK,null)),A.createElement(vu,{onClick:B,className:"react-flow__controls-zoomout",title:"zoom out","aria-label":"zoom out"},A.createElement(PK,null))),a&&A.createElement(vu,{className:"react-flow__controls-fitview",onClick:L,title:"fit view","aria-label":"fit view"},A.createElement(NK,null)),c&&A.createElement(vu,{className:"react-flow__controls-interactive",onClick:j,title:"toggle interactivity","aria-label":"toggle interactivity"},_?A.createElement(AK,null):A.createElement(TK,null)),y)};qK.displayName="Controls";var kK=function(t,r,n){return A.createElement("path",{stroke:n,strokeWidth:r,d:"M".concat(t/2," 0 V").concat(t," M0 ").concat(t/2," H").concat(t)})},LK=function(t,r){return A.createElement("circle",{cx:t,cy:t,r:t,fill:r})},gu;function GI(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function KI(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?GI(Object(r),!0).forEach(function(n){ze(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):GI(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}var BK=(gu={},ze(gu,mi.Dots,"#81818a"),ze(gu,mi.Lines,"#eee"),gu),FK=function(t){return t.transform},sq=function(t){var r=t.variant,n=r===void 0?mi.Dots:r,i=t.gap,o=i===void 0?15:i,a=t.size,u=a===void 0?.4:a,c=t.color,d=t.style,f=t.className,h=A.useRef(null),p=A.useState(null),v=Be(p,2),m=v[0],y=v[1],x=gt(FK),b=Be(x,3),w=b[0],S=b[1],E=b[2];A.useEffect(function(){var B=document.querySelectorAll(".react-flow__background"),L=Array.from(B).findIndex(function(j){return j===h.current});y("pattern-".concat(L))},[]);var _=o*E||1,R=w%_,I=S%_,N=n===mi.Lines,D=c||BK[n],k=N?kK(_,u,D):LK(u*E,D);return A.createElement("svg",{className:cr(["react-flow__background","react-flow__container",f]),style:KI(KI({},d),{},{width:"100%",height:"100%"}),ref:h},m&&A.createElement(A.Fragment,null,A.createElement("pattern",{id:m,x:R,y:I,width:_,height:_,patternUnits:"userSpaceOnUse"},k),A.createElement("rect",{x:"0",y:"0",width:"100%",height:"100%",fill:"url(#".concat(m,")")})))};sq.displayName="Background";var $K=A.memo(sq),zK=["paid-pro","paid-sponsor","paid-enterprise","paid-custom"];function HK(e){var t=e.proOptions,r=e.position,n=r===void 0?"bottom-right":r;if(t!=null&&t.account&&zK.includes(t==null?void 0:t.account)&&t!==null&&t!==void 0&&t.hideAttribution)return null;var i="".concat(n).split("-");return A.createElement("div",{className:cr(["react-flow__attribution"].concat(di(i))),"data-message":"Please only hide this attribution when you are subscribed to React Flow Pro: https://pro.reactflow.dev/pricing"},A.createElement("a",{href:"https://reactflow.dev",target:"_blank",rel:"noopener noreferrer"},"React Flow"))}var UK=["x","y","label","labelStyle","labelShowBg","labelBgStyle","labelBgPadding","labelBgBorderRadius","children","className"];function YI(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function VK(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?YI(Object(r),!0).forEach(function(n){ze(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):YI(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}var WK=function(t){var r=t.x,n=t.y,i=t.label,o=t.labelStyle,a=o===void 0?{}:o,u=t.labelShowBg,c=u===void 0?!0:u,d=t.labelBgStyle,f=d===void 0?{}:d,h=t.labelBgPadding,p=h===void 0?[2,4]:h,v=t.labelBgBorderRadius,m=v===void 0?2:v,y=t.children,x=t.className,b=Hc(t,UK),w=A.useRef(null),S=A.useState({x:0,y:0,width:0,height:0}),E=Be(S,2),_=E[0],R=E[1],I=cr(["react-flow__edge-textwrapper",x]);return A.useEffect(function(){if(w.current){var N=w.current.getBBox();R({x:N.x,y:N.y,width:N.width,height:N.height})}},[i]),typeof i>"u"||!i?null:A.createElement("g",VK({transform:"translate(".concat(r-_.width/2," ").concat(n-_.height/2,")"),className:I},b),c&&A.createElement("rect",{width:_.width+2*p[0],x:-p[0],y:-p[1],height:_.height+2*p[1],className:"react-flow__edge-textbg",style:f,rx:m,ry:m}),A.createElement("text",{className:"react-flow__edge-text",y:_.height/2,dy:"0.3em",ref:w,style:a},i),y)},GK=A.memo(WK),Uc=(function(e){var t=e.path,r=e.centerX,n=e.centerY,i=e.label,o=e.labelStyle,a=e.labelShowBg,u=e.labelBgStyle,c=e.labelBgPadding,d=e.labelBgBorderRadius,f=e.style,h=e.markerEnd,p=e.markerStart,v=i?A.createElement(GK,{x:r,y:n,label:i,labelStyle:o,labelShowBg:a,labelBgStyle:u,labelBgPadding:c,labelBgBorderRadius:d}):null;return A.createElement(A.Fragment,null,A.createElement("path",{style:f,d:t,className:"react-flow__edge-path",markerEnd:h,markerStart:p}),v)});function Qu(e){var t=e.pos,r=e.x1,n=e.y1,i=e.x2,o=e.y2,a,u;switch(t){case xe.Left:case xe.Right:a=.5*(r+i),u=n;break;case xe.Top:case xe.Bottom:a=r,u=.5*(n+o);break}return[a,u]}function uq(e){var t=e.sourceX,r=e.sourceY,n=e.sourcePosition,i=n===void 0?xe.Bottom:n,o=e.targetX,a=e.targetY,u=e.targetPosition,c=u===void 0?xe.Top:u,d=Qu({pos:i,x1:t,y1:r,x2:o,y2:a}),f=Be(d,2),h=f[0],p=f[1],v=Qu({pos:c,x1:o,y1:a,x2:t,y2:r}),m=Be(v,2),y=m[0],x=m[1];return"M".concat(t,",").concat(r," C").concat(h,",").concat(p," ").concat(y,",").concat(x," ").concat(o,",").concat(a)}function KK(e){var t=e.sourceX,r=e.sourceY,n=e.sourcePosition,i=n===void 0?xe.Bottom:n,o=e.targetX,a=e.targetY,u=e.targetPosition,c=u===void 0?xe.Top:u,d=Qu({pos:i,x1:t,y1:r,x2:o,y2:a}),f=Be(d,2),h=f[0],p=f[1],v=Qu({pos:c,x1:o,y1:a,x2:t,y2:r}),m=Be(v,2),y=m[0],x=m[1],b=t*.125+h*.375+y*.375+o*.125,w=r*.125+p*.375+x*.375+a*.125,S=Math.abs(b-t),E=Math.abs(w-r);return[b,w,S,E]}var cq=A.memo(function(e){var t=e.sourceX,r=e.sourceY,n=e.targetX,i=e.targetY,o=e.sourcePosition,a=o===void 0?xe.Bottom:o,u=e.targetPosition,c=u===void 0?xe.Top:u,d=e.label,f=e.labelStyle,h=e.labelShowBg,p=e.labelBgStyle,v=e.labelBgPadding,m=e.labelBgBorderRadius,y=e.style,x=e.markerEnd,b=e.markerStart,w={sourceX:t,sourceY:r,sourcePosition:a,targetX:n,targetY:i,targetPosition:c},S=uq(w),E=KK(w),_=Be(E,2),R=_[0],I=_[1];return A.createElement(Uc,{path:S,centerX:R,centerY:I,label:d,labelStyle:f,labelShowBg:h,labelBgStyle:p,labelBgPadding:v,labelBgBorderRadius:m,style:y,markerEnd:x,markerStart:b})});function XI(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function YK(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?XI(Object(r),!0).forEach(function(n){ze(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):XI(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}var ZI=[xe.Left,xe.Right],lq=function(t){var r=t.sourceX,n=t.sourceY,i=t.targetX,o=t.targetY,a=t.sourcePosition,u=a===void 0?xe.Bottom:a,c=t.targetPosition,d=c===void 0?xe.Top:c,f=ZI.includes(u),h=ZI.includes(d),p=f&&!h||h&&!f;if(p){var v=f?Math.abs(i-r):0,m=r>i?r-v:r+v,y=f?0:Math.abs(o-n),x=n<o?n+y:n-y;return[m,x,v,y]}var b=Math.abs(i-r)/2,w=i<r?i+b:i-b,S=Math.abs(o-n)/2,E=o<n?o+S:o-S;return[w,E,b,S]};function ta(e,t,r){return r===void 0?r:function(n){var i=t().edges.find(function(o){return o.id===e});r(n,YK({},i))}}var gm=function(t,r,n){return"L ".concat(t,",").concat(r-n,"Q ").concat(t,",").concat(r," ").concat(t+n,",").concat(r)},mm=function(t,r,n){return"L ".concat(t+n,",").concat(r,"Q ").concat(t,",").concat(r," ").concat(t,",").concat(r-n)},ym=function(t,r,n){return"L ".concat(t,",").concat(r-n,"Q ").concat(t,",").concat(r," ").concat(t-n,",").concat(r)},bm=function(t,r,n){return"L ".concat(t-n,",").concat(r,"Q ").concat(t,",").concat(r," ").concat(t,",").concat(r-n)},xm=function(t,r,n){return"L ".concat(t+n,",").concat(r,"Q ").concat(t,",").concat(r," ").concat(t,",").concat(r+n)},wm=function(t,r,n){return"L ".concat(t,",").concat(r+n,"Q ").concat(t,",").concat(r," ").concat(t+n,",").concat(r)},_m=function(t,r,n){return"L ".concat(t,",").concat(r+n,"Q ").concat(t,",").concat(r," ").concat(t-n,",").concat(r)},Em=function(t,r,n){return"L ".concat(t-n,",").concat(r,"Q ").concat(t,",").concat(r," ").concat(t,",").concat(r+n)};function qb(e){var t=e.sourceX,r=e.sourceY,n=e.sourcePosition,i=n===void 0?xe.Bottom:n,o=e.targetX,a=e.targetY,u=e.targetPosition,c=u===void 0?xe.Top:u,d=e.borderRadius,f=d===void 0?5:d,h=e.centerX,p=e.centerY,v=lq({sourceX:t,sourceY:r,targetX:o,targetY:a}),m=Be(v,4),y=m[0],x=m[1],b=m[2],w=m[3],S=Math.min(f,Math.abs(o-t)),E=Math.min(f,Math.abs(a-r)),_=Math.min(S,E,b,w),R=[xe.Left,xe.Right],I=typeof h<"u"?h:y,N=typeof p<"u"?p:x,D=null,k=null;return t<=o?(D=r<=a?gm(t,N,_):wm(t,N,_),k=r<=a?Em(o,N,_):bm(o,N,_)):(D=r<a?ym(t,N,_):_m(t,N,_),k=r<a?xm(o,N,_):mm(o,N,_)),R.includes(i)&&R.includes(c)?t<=o?(D=r<=a?Em(I,r,_):bm(I,r,_),k=r<=a?gm(I,a,_):wm(I,a,_)):(i===xe.Right&&c===xe.Left||i===xe.Left&&c===xe.Right||i===xe.Left&&c===xe.Left)&&(D=r<=a?xm(I,r,_):mm(I,r,_),k=r<=a?ym(I,a,_):_m(I,a,_)):R.includes(i)&&!R.includes(c)?(t<=o?D=r<=a?Em(o,r,_):bm(o,r,_):D=r<=a?xm(o,r,_):mm(o,r,_),k=""):!R.includes(i)&&R.includes(c)&&(t<=o?D=r<=a?gm(t,a,_):wm(t,a,_):D=r<=a?ym(t,a,_):_m(t,a,_),k=""),"M ".concat(t,",").concat(r).concat(D).concat(k,"L ").concat(o,",").concat(a)}var Tx=A.memo(function(e){var t=e.sourceX,r=e.sourceY,n=e.targetX,i=e.targetY,o=e.label,a=e.labelStyle,u=e.labelShowBg,c=e.labelBgStyle,d=e.labelBgPadding,f=e.labelBgBorderRadius,h=e.style,p=e.sourcePosition,v=p===void 0?xe.Bottom:p,m=e.targetPosition,y=m===void 0?xe.Top:m,x=e.markerEnd,b=e.markerStart,w=e.borderRadius,S=w===void 0?5:w,E=lq({sourceX:t,sourceY:r,targetX:n,targetY:i,sourcePosition:v,targetPosition:y}),_=Be(E,2),R=_[0],I=_[1],N=qb({sourceX:t,sourceY:r,sourcePosition:v,targetX:n,targetY:i,targetPosition:y,borderRadius:S});return A.createElement(Uc,{path:N,centerX:R,centerY:I,label:o,labelStyle:a,labelShowBg:u,labelBgStyle:c,labelBgPadding:d,labelBgBorderRadius:f,style:h,markerEnd:x,markerStart:b})});function JI(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function QI(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?JI(Object(r),!0).forEach(function(n){ze(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):JI(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}var fq=A.memo(function(e){return A.createElement(Tx,QI(QI({},e),{},{borderRadius:0}))}),dq=A.memo(function(e){var t=e.sourceX,r=e.sourceY,n=e.targetX,i=e.targetY,o=e.label,a=e.labelStyle,u=e.labelShowBg,c=e.labelBgStyle,d=e.labelBgPadding,f=e.labelBgBorderRadius,h=e.style,p=e.markerEnd,v=e.markerStart,m=Math.abs(i-r)/2,y=i<r?i+m:i-m,x=Math.abs(n-t)/2,b=n<t?n+x:n-x,w="M ".concat(t,",").concat(r,"L ").concat(n,",").concat(i);return A.createElement(Uc,{path:w,centerX:b,centerY:y,label:o,labelStyle:a,labelShowBg:u,labelBgStyle:c,labelBgPadding:d,labelBgBorderRadius:f,style:h,markerEnd:p,markerStart:v})});function mu(e,t){return e>=0?.5*e:t*25*Math.sqrt(-e)}function ec(e){var t=e.pos,r=e.x1,n=e.y1,i=e.x2,o=e.y2,a=e.c,u,c;switch(t){case xe.Left:u=r-mu(r-i,a),c=n;break;case xe.Right:u=r+mu(i-r,a),c=n;break;case xe.Top:u=r,c=n-mu(n-o,a);break;case xe.Bottom:u=r,c=n+mu(o-n,a);break}return[u,c]}function Vc(e){var t=e.sourceX,r=e.sourceY,n=e.sourcePosition,i=n===void 0?xe.Bottom:n,o=e.targetX,a=e.targetY,u=e.targetPosition,c=u===void 0?xe.Top:u,d=e.curvature,f=d===void 0?.25:d,h=ec({pos:i,x1:t,y1:r,x2:o,y2:a,c:f}),p=Be(h,2),v=p[0],m=p[1],y=ec({pos:c,x1:o,y1:a,x2:t,y2:r,c:f}),x=Be(y,2),b=x[0],w=x[1];return"M".concat(t,",").concat(r," C").concat(v,",").concat(m," ").concat(b,",").concat(w," ").concat(o,",").concat(a)}function XK(e){var t=e.sourceX,r=e.sourceY,n=e.sourcePosition,i=n===void 0?xe.Bottom:n,o=e.targetX,a=e.targetY,u=e.targetPosition,c=u===void 0?xe.Top:u,d=e.curvature,f=d===void 0?.25:d,h=ec({pos:i,x1:t,y1:r,x2:o,y2:a,c:f}),p=Be(h,2),v=p[0],m=p[1],y=ec({pos:c,x1:o,y1:a,x2:t,y2:r,c:f}),x=Be(y,2),b=x[0],w=x[1],S=t*.125+v*.375+b*.375+o*.125,E=r*.125+m*.375+w*.375+a*.125,_=Math.abs(S-t),R=Math.abs(E-r);return[S,E,_,R]}var kb=A.memo(function(e){var t=e.sourceX,r=e.sourceY,n=e.targetX,i=e.targetY,o=e.sourcePosition,a=o===void 0?xe.Bottom:o,u=e.targetPosition,c=u===void 0?xe.Top:u,d=e.label,f=e.labelStyle,h=e.labelShowBg,p=e.labelBgStyle,v=e.labelBgPadding,m=e.labelBgBorderRadius,y=e.style,x=e.markerEnd,b=e.markerStart,w=e.curvature,S={sourceX:t,sourceY:r,sourcePosition:a,targetX:n,targetY:i,targetPosition:c,curvature:w},E=Vc(S),_=XK(S),R=Be(_,2),I=R[0],N=R[1];return A.createElement(Uc,{path:E,centerX:I,centerY:N,label:d,labelStyle:f,labelShowBg:h,labelBgStyle:p,labelBgPadding:v,labelBgBorderRadius:m,style:y,markerEnd:x,markerStart:b})}),Ax=A.createContext(null),ZK=Ax.Provider;Ax.Consumer;function Lb(e,t,r,n,i,o,a){var u=a.elementFromPoint(e.clientX,e.clientY),c=(u==null?void 0:u.classList.contains("target"))||!1,d=(u==null?void 0:u.classList.contains("source"))||!1,f={elementBelow:u,isValid:!1,connection:{source:null,target:null,sourceHandle:null,targetHandle:null},isHoveringHandle:!1};if(u&&(c||d)){f.isHoveringHandle=!0;var h=u.getAttribute("data-nodeid"),p=u.getAttribute("data-handleid"),v=r?{source:h,sourceHandle:p,target:n,targetHandle:i}:{source:n,sourceHandle:i,target:h,targetHandle:p};f.connection=v;var m=t===mo.Strict?r&&d||!r&&c:!0;m&&(f.isValid=o(v))}return f}function Sm(e){e==null||e.classList.remove("react-flow__handle-valid"),e==null||e.classList.remove("react-flow__handle-connecting")}function hq(e){var t=e.event,r=e.handleId,n=e.nodeId,i=e.onConnect,o=e.isTarget,a=e.getState,u=e.setState,c=e.isValidConnection,d=e.elementEdgeUpdaterType,f=e.onEdgeUpdateEnd,h=t.target.closest(".react-flow"),p=Kj(t.target);if(!p)return;var v=p.elementFromPoint(t.clientX,t.clientY),m=v==null?void 0:v.classList.contains("target"),y=v==null?void 0:v.classList.contains("source");if(!h||!m&&!y&&!d)return;var x=a(),b=x.onConnectStart,w=x.connectionMode,S=d||(m?"target":"source"),E=h.getBoundingClientRect(),_;u({connectionPosition:{x:t.clientX-E.left,y:t.clientY-E.top},connectionNodeId:n,connectionHandleId:r,connectionHandleType:S}),b==null||b(t,{nodeId:n,handleId:r,handleType:S});function R(N){u({connectionPosition:{x:N.clientX-E.left,y:N.clientY-E.top}});var D=Lb(N,w,o,n,r,c,p),k=D.connection,B=D.elementBelow,L=D.isValid,j=D.isHoveringHandle;if(!j)return Sm(_);k.source!==k.target&&B&&(Sm(_),_=B,B.classList.add("react-flow__handle-connecting"),B.classList.toggle("react-flow__handle-valid",L))}function I(N){var D=a(),k=D.onConnectStop,B=D.onConnectEnd,L=Lb(N,w,o,n,r,c,p),j=L.connection,T=L.isValid;k==null||k(N),T&&(i==null||i(j)),B==null||B(N),d&&f&&f(N),Sm(_),u({connectionNodeId:null,connectionHandleId:null,connectionHandleType:null}),p.removeEventListener("mousemove",R),p.removeEventListener("mouseup",I)}p.addEventListener("mousemove",R),p.addEventListener("mouseup",I)}var JK=["type","position","isValidConnection","isConnectable","id","onConnect","children","className","onMouseDown"];function eP(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function Om(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?eP(Object(r),!0).forEach(function(n){ze(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):eP(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}var QK=function(){return!0},eY=function(t){return{connectionStartHandle:t.connectionStartHandle,connectOnClick:t.connectOnClick}},pq=A.forwardRef(function(e,t){var r=e.type,n=r===void 0?"source":r,i=e.position,o=i===void 0?xe.Top:i,a=e.isValidConnection,u=a===void 0?QK:a,c=e.isConnectable,d=c===void 0?!0:c,f=e.id,h=e.onConnect,p=e.children,v=e.className,m=e.onMouseDown,y=Hc(e,JK),x=Ft(),b=A.useContext(Ax),w=gt(eY,Xt),S=w.connectionStartHandle,E=w.connectOnClick,_=f||null,R=n==="target",I=function(B){var L=x.getState(),j=L.defaultEdgeOptions,T=L.onConnect,F=L.hasDefaultEdges,$=Om(Om({},j),B);if(F){var W=x.getState(),Y=W.edges;x.setState({edges:gK($,Y)})}T==null||T($),h==null||h($)},N=function(B){B.button===0&&hq({event:B,handleId:_,nodeId:b,onConnect:I,isTarget:R,getState:x.getState,setState:x.setState,isValidConnection:u}),m==null||m(B)},D=function(B){var L=x.getState(),j=L.onClickConnectStart,T=L.onClickConnectStop,F=L.onClickConnectEnd,$=L.connectionMode;if(!S){j==null||j(B,{nodeId:b,handleId:_,handleType:n}),x.setState({connectionStartHandle:{nodeId:b,type:n,handleId:_}});return}var W=Kj(B.target),Y=Lb(B,$,S.type==="target",S.nodeId,S.handleId||null,u,W),ee=Y.connection,H=Y.isValid;T==null||T(B),H&&I(ee),F==null||F(B),x.setState({connectionStartHandle:null})};return A.createElement("div",Om({"data-handleid":_,"data-nodeid":b,"data-handlepos":o,className:cr(["react-flow__handle","react-flow__handle-".concat(o),"nodrag",v,{source:!R,target:R,connectable:d,connecting:(S==null?void 0:S.nodeId)===b&&(S==null?void 0:S.handleId)===_&&(S==null?void 0:S.type)===n}]),onMouseDown:N,onClick:E?D:void 0,ref:t},y),p)});pq.displayName="Handle";var tc=A.memo(pq),vq=function(t){var r=t.data,n=t.isConnectable,i=t.targetPosition,o=i===void 0?xe.Top:i,a=t.sourcePosition,u=a===void 0?xe.Bottom:a;return A.createElement(A.Fragment,null,A.createElement(tc,{type:"target",position:o,isConnectable:n}),r==null?void 0:r.label,A.createElement(tc,{type:"source",position:u,isConnectable:n}))};vq.displayName="DefaultNode";var Bb=A.memo(vq),gq=function(t){var r=t.data,n=t.isConnectable,i=t.sourcePosition,o=i===void 0?xe.Bottom:i;return A.createElement(A.Fragment,null,r==null?void 0:r.label,A.createElement(tc,{type:"source",position:o,isConnectable:n}))};gq.displayName="InputNode";var mq=A.memo(gq),yq=function(t){var r=t.data,n=t.isConnectable,i=t.targetPosition,o=i===void 0?xe.Top:i;return A.createElement(A.Fragment,null,A.createElement(tc,{type:"target",position:o,isConnectable:n}),r==null?void 0:r.label)};yq.displayName="OutputNode";var bq=A.memo(yq),tY=function(t){return{selectedNodes:Array.from(t.nodeInternals.values()).filter(function(r){return r.selected}),selectedEdges:t.edges.filter(function(r){return r.selected})}},rY=function(t,r){var n=t.selectedNodes.map(function(u){return u.id}),i=r.selectedNodes.map(function(u){return u.id}),o=t.selectedEdges.map(function(u){return u.id}),a=r.selectedEdges.map(function(u){return u.id});return Xt(n,i)&&Xt(o,a)};function nY(e){var t=e.onSelectionChange,r=gt(tY,rY),n=r.selectedNodes,i=r.selectedEdges;return A.useEffect(function(){t({nodes:n,edges:i})},[n,i]),null}var iY=A.memo(nY),oY=function(t){return{setNodes:t.setNodes,setEdges:t.setEdges,setDefaultNodesAndEdges:t.setDefaultNodesAndEdges,setMinZoom:t.setMinZoom,setMaxZoom:t.setMaxZoom,setTranslateExtent:t.setTranslateExtent,setNodeExtent:t.setNodeExtent,reset:t.reset}};function qn(e,t){A.useEffect(function(){typeof e<"u"&&t(e)},[e])}function nt(e,t,r){A.useEffect(function(){typeof t<"u"&&r(ze({},e,t))},[t])}var aY=function(t){var r=t.nodes,n=t.edges,i=t.defaultNodes,o=t.defaultEdges,a=t.onConnect,u=t.onConnectStart,c=t.onConnectStop,d=t.onConnectEnd,f=t.onClickConnectStart,h=t.onClickConnectStop,p=t.onClickConnectEnd,v=t.nodesDraggable,m=t.nodesConnectable,y=t.minZoom,x=t.maxZoom,b=t.nodeExtent,w=t.onNodesChange,S=t.onEdgesChange,E=t.elementsSelectable,_=t.connectionMode,R=t.snapGrid,I=t.snapToGrid,N=t.translateExtent,D=t.connectOnClick,k=t.defaultEdgeOptions,B=t.fitView,L=t.fitViewOptions,j=t.onNodesDelete,T=t.onEdgesDelete,F=t.onNodeDrag,$=t.onNodeDragStart,W=t.onNodeDragStop,Y=t.onSelectionDrag,ee=t.onSelectionDragStart,H=t.onSelectionDragStop,Q=gt(oY,Xt),ce=Q.setNodes,se=Q.setEdges,z=Q.setDefaultNodesAndEdges,G=Q.setMinZoom,J=Q.setMaxZoom,V=Q.setTranslateExtent,K=Q.setNodeExtent,ie=Q.reset,ne=Ft();return A.useEffect(function(){return z(i,o),function(){ie()}},[]),nt("defaultEdgeOptions",k,ne.setState),nt("connectionMode",_,ne.setState),nt("onConnect",a,ne.setState),nt("onConnectStart",u,ne.setState),nt("onConnectStop",c,ne.setState),nt("onConnectEnd",d,ne.setState),nt("onClickConnectStart",f,ne.setState),nt("onClickConnectStop",h,ne.setState),nt("onClickConnectEnd",p,ne.setState),nt("nodesDraggable",v,ne.setState),nt("nodesConnectable",m,ne.setState),nt("elementsSelectable",E,ne.setState),nt("snapToGrid",I,ne.setState),nt("snapGrid",R,ne.setState),nt("onNodesChange",w,ne.setState),nt("onEdgesChange",S,ne.setState),nt("connectOnClick",D,ne.setState),nt("fitViewOnInit",B,ne.setState),nt("fitViewOnInitOptions",L,ne.setState),nt("onNodesDelete",j,ne.setState),nt("onEdgesDelete",T,ne.setState),nt("onNodeDrag",F,ne.setState),nt("onNodeDragStart",$,ne.setState),nt("onNodeDragStop",W,ne.setState),nt("onSelectionDrag",Y,ne.setState),nt("onSelectionDragStart",ee,ne.setState),nt("onSelectionDragStop",H,ne.setState),qn(r,ce),qn(n,se),qn(i,ce),qn(o,se),qn(y,G),qn(x,J),qn(N,V),qn(b,K),null},sY=".react-flow{height:100%;overflow:hidden;position:relative;width:100%}.react-flow__container{height:100%;left:0;position:absolute;top:0;width:100%}.react-flow__pane{z-index:1}.react-flow__viewport{pointer-events:none;transform-origin:0 0;z-index:2}.react-flow__renderer{z-index:4}.react-flow__selectionpane{z-index:5}.react-flow .react-flow__edges{overflow:visible;pointer-events:none}.react-flow .react-flow__connectionline{z-index:1001}.react-flow__edge{pointer-events:visibleStroke}.react-flow__edge.inactive{pointer-events:none}@-webkit-keyframes dashdraw{0%{stroke-dashoffset:10}}@keyframes dashdraw{0%{stroke-dashoffset:10}}.react-flow__edge-path{fill:none}.react-flow__edge-textwrapper{pointer-events:all}.react-flow__edge-text{pointer-events:none;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}.react-flow__connection{pointer-events:none}.react-flow__connection .animated{stroke-dasharray:5;-webkit-animation:dashdraw .5s linear infinite;animation:dashdraw .5s linear infinite}.react-flow__connection-path{fill:none}.react-flow__nodes{pointer-events:none;transform-origin:0 0}.react-flow__node{box-sizing:border-box;pointer-events:all;position:absolute;transform-origin:0 0;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}.react-flow__nodesselection{pointer-events:none;transform-origin:left top;z-index:3}.react-flow__nodesselection-rect{cursor:-webkit-grab;cursor:grab;pointer-events:all;position:absolute}.react-flow__handle{pointer-events:none;position:absolute}.react-flow__handle.connectable{pointer-events:all}.react-flow__handle-bottom{bottom:-4px;left:50%;top:auto;transform:translate(-50%)}.react-flow__handle-top{left:50%;top:-4px;transform:translate(-50%)}.react-flow__handle-left{left:-4px;top:50%;transform:translateY(-50%)}.react-flow__handle-right{right:-4px;top:50%;transform:translateY(-50%)}.react-flow__edgeupdater{cursor:move;pointer-events:all}.react-flow__controls{bottom:20px;left:15px;position:absolute;z-index:5}.react-flow__controls-button{border:none;height:24px;width:24px}.react-flow__controls-button svg{width:100%}.react-flow__minimap{bottom:20px;position:absolute;right:15px;z-index:5}.react-flow__attribution{background:hsla(0,0%,100%,.5);color:#999;font-size:10px;padding:2px 3px;position:absolute;z-index:1000}.react-flow__attribution a{color:#555;text-decoration:none}.react-flow__attribution.top{top:0}.react-flow__attribution.bottom{bottom:0}.react-flow__attribution.left{left:0}.react-flow__attribution.right{right:0}.react-flow__attribution.center{left:50%;transform:translateX(-50%)}",uY=sY,cY=".react-flow__edge.selected .react-flow__edge-path{stroke:#555}.react-flow__edge.animated path{stroke-dasharray:5;-webkit-animation:dashdraw .5s linear infinite;animation:dashdraw .5s linear infinite}.react-flow__edge.updating .react-flow__edge-path{stroke:#777}.react-flow__edge-path{stroke:#b1b1b7;stroke-width:1}.react-flow__edge-text{font-size:10px}.react-flow__edge-textbg{fill:#fff}.react-flow__connection-path{stroke:#b1b1b7;stroke-width:1}.react-flow__node{cursor:-webkit-grab;cursor:grab}.react-flow__node-default,.react-flow__node-group,.react-flow__node-input,.react-flow__node-output{background:#fff;border:1px solid #1a192b;border-radius:3px;color:#222;font-size:12px;padding:10px;text-align:center;width:150px}.react-flow__node-default.selected,.react-flow__node-group.selected,.react-flow__node-input.selected,.react-flow__node-output.selected{box-shadow:0 0 0 .5px #1a192b}.react-flow__node-default .react-flow__handle,.react-flow__node-group .react-flow__handle,.react-flow__node-input .react-flow__handle,.react-flow__node-output .react-flow__handle{background:#1a192b}.react-flow__node-default.selectable:hover,.react-flow__node-group.selectable:hover,.react-flow__node-input.selectable:hover,.react-flow__node-output.selectable:hover{box-shadow:0 1px 4px 1px rgba(0,0,0,.08)}.react-flow__node-default.selectable.selected,.react-flow__node-group.selectable.selected,.react-flow__node-input.selectable.selected,.react-flow__node-output.selectable.selected{box-shadow:0 0 0 .5px #1a192b}.react-flow__node-group{background:hsla(0,0%,94%,.25);border-color:#1a192b}.react-flow__nodesselection-rect,.react-flow__selection{background:rgba(0,89,220,.08);border:1px dotted rgba(0,89,220,.8)}.react-flow__handle{background:#555;border:1px solid #fff;border-radius:100%;height:6px;width:6px}.react-flow__handle.connectable{cursor:crosshair}.react-flow__minimap{background-color:#fff}.react-flow__controls{box-shadow:0 0 2px 1px rgba(0,0,0,.08)}.react-flow__controls-button{align-items:center;background:#fefefe;border-bottom:1px solid #eee;box-sizing:content-box;cursor:pointer;display:flex;height:16px;justify-content:center;padding:5px;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;width:16px}.react-flow__controls-button svg{max-height:12px;max-width:12px}.react-flow__controls-button:hover{background:#f4f4f4}",lY=cY,fY=function(t,r,n){return n===xe.Left?t-r:n===xe.Right?t+r:t},dY=function(t,r,n){return n===xe.Top?t-r:n===xe.Bottom?t+r:t},tP=function(t){var r=t.className,n=t.position,i=t.centerX,o=t.centerY,a=t.radius,u=a===void 0?10:a;return A.createElement("circle",{className:cr(["react-flow__edgeupdater",r]),cx:fY(i,u,n),cy:dY(o,u,n),r:u,stroke:"transparent",fill:"transparent"})},Ki=(function(e){var t=function(n){var i=n.id,o=n.className,a=n.type,u=n.data,c=n.onClick,d=n.onEdgeDoubleClick,f=n.selected,h=n.animated,p=n.label,v=n.labelStyle,m=n.labelShowBg,y=n.labelBgStyle,x=n.labelBgPadding,b=n.labelBgBorderRadius,w=n.style,S=n.source,E=n.target,_=n.sourceX,R=n.sourceY,I=n.targetX,N=n.targetY,D=n.sourcePosition,k=n.targetPosition,B=n.elementsSelectable,L=n.hidden,j=n.sourceHandleId,T=n.targetHandleId,F=n.onContextMenu,$=n.onMouseEnter,W=n.onMouseMove,Y=n.onMouseLeave,ee=n.edgeUpdaterRadius,H=n.onEdgeUpdate,Q=n.onEdgeUpdateStart,ce=n.onEdgeUpdateEnd,se=n.markerEnd,z=n.markerStart,G=n.rfId,J=A.useState(!1),V=Be(J,2),K=V[0],ie=V[1],ne=Ft(),ue=function(tt){var Ct=ne.getState(),Jt=Ct.edges,lr=Ct.addSelectedEdges,Dt=Jt.find(function(xt){return xt.id===i});B&&(ne.setState({nodesSelectionActive:!1}),lr([i])),c==null||c(tt,Dt)},de=ta(i,ne.getState,d),we=ta(i,ne.getState,F),Se=ta(i,ne.getState,$),_e=ta(i,ne.getState,W),he=ta(i,ne.getState,Y),ae=function(tt,Ct){var Jt=Ct?E:S,lr=(Ct?T:j)||null,Dt=Ct?"target":"source",xt=function(){return!0},jt=Ct,Hr=ne.getState().edges.find(function(Ur){return Ur.id===i});Q==null||Q(tt,Hr,Dt);var Yn=ce?function(Ur){return ce(Ur,Hr,Dt)}:void 0,Cn=function(Pi){return H==null?void 0:H(Hr,Pi)};hq({event:tt,handleId:lr,nodeId:Jt,onConnect:Cn,isTarget:jt,getState:ne.getState,setState:ne.setState,isValidConnection:xt,elementEdgeUpdaterType:Dt,onEdgeUpdateEnd:Yn})},Oe=function(tt){return ae(tt,!0)},Ne=function(tt){return ae(tt,!1)},He=function(){return ie(!0)},qe=function(){return ie(!1)},Xe=A.useMemo(function(){return"url(#".concat(Db(z,G),")")},[z,G]),We=A.useMemo(function(){return"url(#".concat(Db(se,G),")")},[se,G]);if(L)return null;var mt=!B&&!c,et=typeof H<"u",Tt=cr(["react-flow__edge","react-flow__edge-".concat(a),o,{selected:f,animated:h,inactive:mt,updating:K}]);return A.createElement("g",{className:Tt,onClick:ue,onDoubleClick:de,onContextMenu:we,onMouseEnter:Se,onMouseMove:_e,onMouseLeave:he},A.createElement(e,{id:i,source:S,target:E,selected:f,animated:h,label:p,labelStyle:v,labelShowBg:m,labelBgStyle:y,labelBgPadding:x,labelBgBorderRadius:b,data:u,style:w,sourceX:_,sourceY:R,targetX:I,targetY:N,sourcePosition:D,targetPosition:k,sourceHandleId:j,targetHandleId:T,markerStart:Xe,markerEnd:We,"data-testid":"rf__edge-".concat(i)}),et&&A.createElement("g",{onMouseDown:Oe,onMouseEnter:He,onMouseOut:qe},A.createElement(tP,{position:D,centerX:_,centerY:R,radius:ee})),et&&A.createElement("g",{onMouseDown:Ne,onMouseEnter:He,onMouseOut:qe},A.createElement(tP,{position:k,centerX:I,centerY:N,radius:ee})))};return t.displayName="EdgeWrapper",A.memo(t)});function rP(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function nP(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?rP(Object(r),!0).forEach(function(n){ze(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):rP(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function hY(e){var t={default:Ki(e.default||kb),straight:Ki(e.bezier||dq),step:Ki(e.step||fq),smoothstep:Ki(e.step||Tx),simplebezier:Ki(e.simplebezier||cq)},r={},n=Object.keys(e).filter(function(i){return!["default","bezier"].includes(i)}).reduce(function(i,o){return i[o]=Ki(e[o]||kb),i},r);return nP(nP({},t),n)}function iP(e,t){var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:null,n=((r==null?void 0:r.x)||0)+t.x,i=((r==null?void 0:r.y)||0)+t.y,o=(r==null?void 0:r.width)||t.width,a=(r==null?void 0:r.height)||t.height;switch(e){case xe.Top:return{x:n+o/2,y:i};case xe.Right:return{x:n+o,y:i+a/2};case xe.Bottom:return{x:n+o/2,y:i+a};case xe.Left:return{x:n,y:i+a/2}}}function oP(e,t){if(!e)return null;var r=null;return e.length===1||!t?r=e[0]:t&&(r=e.find(function(n){return n.id===t})),typeof r>"u"?null:r}var pY=function(t,r,n,i,o,a){var u=iP(n,t,r),c=iP(a,i,o);return{sourceX:u.x,sourceY:u.y,targetX:c.x,targetY:c.y}};function vY(e){var t=e.sourcePos,r=e.targetPos,n=e.sourceWidth,i=e.sourceHeight,o=e.targetWidth,a=e.targetHeight,u=e.width,c=e.height,d=e.transform,f={x:Math.min(t.x,r.x),y:Math.min(t.y,r.y),x2:Math.max(t.x+n,r.x+o),y2:Math.max(t.y+i,r.y+a)};f.x===f.x2&&(f.x2+=1),f.y===f.y2&&(f.y2+=1);var h=Ju({x:(0-d[0])/d[2],y:(0-d[1])/d[2],width:u/d[2],height:c/d[2]}),p=Math.max(0,Math.min(h.x2,f.x2)-Math.max(h.x,f.x)),v=Math.max(0,Math.min(h.y2,f.y2)-Math.max(h.y,f.y)),m=Math.ceil(p*v);return m>0}function aP(e,t){var r,n,i,o,a,u=e.get(t),c=(u==null||(r=u[Pt])===null||r===void 0?void 0:r.handleBounds)||null,d=!u||!c||!u.width||!u.height||typeof((n=u.positionAbsolute)===null||n===void 0?void 0:n.x)>"u"||typeof((i=u.positionAbsolute)===null||i===void 0?void 0:i.y)>"u";return[{x:(u==null||(o=u.positionAbsolute)===null||o===void 0?void 0:o.x)||0,y:(u==null||(a=u.positionAbsolute)===null||a===void 0?void 0:a.y)||0,width:(u==null?void 0:u.width)||0,height:(u==null?void 0:u.height)||0},c,!d]}var gY=typeof document<"u"?document:null,rc=(function(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:null,t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{target:gY},r=A.useState(!1),n=Be(r,2),i=n[0],o=n[1],a=A.useRef(new Set([])),u=A.useMemo(function(){if(e!==null){var h=Array.isArray(e)?e:[e],p=h.filter(function(m){return typeof m=="string"}).map(function(m){return m.split("+")}),v=p.reduce(function(m,y){return m.concat.apply(m,di(y))},[]);return[p,v]}return[[],[]]},[e]),c=Be(u,2),d=c[0],f=c[1];return A.useEffect(function(){if(e!==null){var h,p,v=function(b){if(cP(b))return!1;var w=uP(b.code,f);a.current.add(b[w]),sP(d,a.current,!1)&&(b.preventDefault(),o(!0))},m=function(b){if(cP(b))return!1;var w=uP(b.code,f);sP(d,a.current,!0)?(o(!1),a.current.clear()):a.current.delete(b[w])},y=function(){a.current.clear(),o(!1)};return t==null||(h=t.target)===null||h===void 0||h.addEventListener("keydown",v),t==null||(p=t.target)===null||p===void 0||p.addEventListener("keyup",m),window.addEventListener("blur",y),function(){var x,b;t==null||(x=t.target)===null||x===void 0||x.removeEventListener("keydown",v),t==null||(b=t.target)===null||b===void 0||b.removeEventListener("keyup",m),window.removeEventListener("blur",y)}}},[e,o]),i});function sP(e,t,r){return e.filter(function(n){return r||n.length===t.size}).some(function(n){return n.every(function(i){return t.has(i)})})}function uP(e,t){return t.includes(e)?"code":"key"}function cP(e){var t,r=((t=e.composedPath)===null||t===void 0?void 0:t.call(e)[0])||e.target;return["INPUT","SELECT","TEXTAREA"].includes(r==null?void 0:r.nodeName)||(r==null?void 0:r.hasAttribute("contenteditable"))}var mY=function(t){return{onNodesChange:t.onNodesChange,onEdgesChange:t.onEdgesChange}},yY=(function(e){var t=e.deleteKeyCode,r=e.multiSelectionKeyCode,n=Ft(),i=gt(mY,Xt),o=i.onNodesChange,a=i.onEdgesChange,u=rc(t),c=rc(r);A.useEffect(function(){var d=n.getState(),f=d.nodeInternals,h=d.edges,p=d.hasDefaultNodes,v=d.hasDefaultEdges,m=d.onNodesDelete,y=d.onEdgesDelete,x=Array.from(f.values()),b=x.reduce(function(N,D){return(!D.selected&&D.parentNode&&N.find(function(k){return k.id===D.parentNode})||D.selected)&&N.push(D),N},[]),w=h.filter(function(N){return N.selected});if(u&&(b||w)){var S=rq(b,h),E=[].concat(di(w),di(S)),_=E.reduce(function(N,D){return N.includes(D.id)||N.push(D.id),N},[]);if((v||p)&&(v&&n.setState({edges:h.filter(function(N){return!_.includes(N.id)})}),p&&(b.forEach(function(N){f.delete(N.id)}),n.setState({nodeInternals:new Map(f)}))),_.length>0&&(y==null||y(E),a)){var R=_.map(function(N){return{id:N,type:"remove"}});a(R)}if(b.length>0&&(m==null||m(b),o)){var I=b.map(function(N){return{id:N.id,type:"remove"}});o(I)}n.setState({nodesSelectionActive:!1})}},[u,o,a]),A.useEffect(function(){n.setState({multiSelectionActive:c})},[c])});function bY(e){var t=Ft();A.useEffect(function(){var r,n=function(){if(e.current){var o=Ix(e.current);process.env.NODE_ENV==="development"&&(o.height===0||o.width===0)&&console.warn("[React Flow]: The React Flow parent container needs a width and a height to render the graph. Help: https://reactflow.dev/error#400"),t.setState({width:o.width||500,height:o.height||500})}};return n(),window.onresize=n,e.current&&(r=new ResizeObserver(function(){return n()}),r.observe(e.current)),function(){window.onresize=null,r&&e.current&&r.unobserve(e.current)}},[])}var xY=function(t,r){return t.x!==r.x||t.y!==r.y||t.zoom!==r.k},Cm=function(t){return{x:t.x,y:t.y,zoom:t.k}},yu=function(t,r){return t.target.closest(".".concat(r))},wY=function(t){return{d3Zoom:t.d3Zoom,d3Selection:t.d3Selection,d3ZoomHandler:t.d3ZoomHandler}},_Y=function(t){var r=t.onMove,n=t.onMoveStart,i=t.onMoveEnd,o=t.zoomOnScroll,a=o===void 0?!0:o,u=t.zoomOnPinch,c=u===void 0?!0:u,d=t.panOnScroll,f=d===void 0?!1:d,h=t.panOnScrollSpeed,p=h===void 0?.5:h,v=t.panOnScrollMode,m=v===void 0?io.Free:v,y=t.zoomOnDoubleClick,x=y===void 0?!0:y,b=t.selectionKeyPressed,w=t.elementsSelectable,S=t.panOnDrag,E=S===void 0?!0:S,_=t.translateExtent,R=t.minZoom,I=t.maxZoom,N=t.defaultZoom,D=N===void 0?1:N,k=t.defaultPosition,B=k===void 0?[0,0]:k,L=t.zoomActivationKeyCode,j=t.preventScrolling,T=j===void 0?!0:j,F=t.children,$=t.noWheelClassName,W=t.noPanClassName,Y=Ft(),ee=A.useRef(!1),H=A.useRef(null),Q=A.useRef({x:0,y:0,zoom:0}),ce=gt(wY,Xt),se=ce.d3Zoom,z=ce.d3Selection,G=ce.d3ZoomHandler,J=rc(L);return bY(H),A.useEffect(function(){if(H.current){var V,K=aK().scaleExtent([R,I]).translateExtent(_),ie=Mr(H.current).call(K),ne=oo(B[0],_[0][0],_[1][0]),ue=oo(B[1],_[0][1],_[1][1]),de=oo(D,R,I),we=fi.translate(ne,ue).scale(de);K.transform(ie,we),Y.setState({d3Zoom:K,d3Selection:ie,d3ZoomHandler:ie.on("wheel.zoom"),transform:[ne,ue,de],domNode:(V=ie.node())===null||V===void 0?void 0:V.closest(".react-flow")})}},[]),A.useEffect(function(){z&&se&&(f&&!J?z.on("wheel",function(V){if(yu(V,$))return!1;V.preventDefault(),V.stopImmediatePropagation();var K=z.property("__zoom").k||1;if(V.ctrlKey&&c){var ie=Xr(V),ne=-V.deltaY*(V.deltaMode===1?.05:V.deltaMode?1:.002)*10,ue=K*Math.pow(2,ne);se.scaleTo(z,ue,ie);return}var de=V.deltaMode===1?20:1,we=m===io.Vertical?0:V.deltaX*de,Se=m===io.Horizontal?0:V.deltaY*de;se.translateBy(z,-(we/K)*p,-(Se/K)*p)}).on("wheel.zoom",null):typeof G<"u"&&z.on("wheel",function(V){if(!T||yu(V,$))return null;V.preventDefault()}).on("wheel.zoom",G))},[f,m,z,se,G,J,c,T,$]),A.useEffect(function(){se&&(b&&!ee.current?se.on("zoom",null):b||se.on("zoom",function(V){if(Y.setState({transform:[V.transform.x,V.transform.y,V.transform.k]}),r){var K=Cm(V.transform);r(V.sourceEvent,K)}}))},[b,se,r]),A.useEffect(function(){se&&se.on("start",function(V){if(ee.current=!0,n){var K=Cm(V.transform);Q.current=K,n(V.sourceEvent,K)}})},[se,n]),A.useEffect(function(){se&&se.on("end",function(V){if(ee.current=!1,i&&xY(Q.current,V.transform)){var K=Cm(V.transform);Q.current=K,i(V.sourceEvent,K)}})},[se,i]),A.useEffect(function(){se&&se.filter(function(V){var K=J||a,ie=c&&V.ctrlKey;return!E&&!K&&!f&&!x&&!c||b||!x&&V.type==="dblclick"||yu(V,$)&&V.type==="wheel"||yu(V,W)&&V.type!=="wheel"||!c&&V.ctrlKey&&V.type==="wheel"||!K&&!f&&!ie&&V.type==="wheel"||!E&&(V.type==="mousedown"||V.type==="touchstart")?!1:(!V.ctrlKey||V.type==="wheel")&&!V.button})},[se,a,c,f,x,E,b,w,J]),A.createElement("div",{className:"react-flow__renderer react-flow__container",ref:H},F)};function lP(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function fP(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?lP(Object(r),!0).forEach(function(n){ze(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):lP(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function dP(e,t){return{x:e.clientX-t.left,y:e.clientY-t.top}}var EY=function(t){return{userSelectionActive:t.userSelectionActive,elementsSelectable:t.elementsSelectable}},hP={startX:0,startY:0,x:0,y:0,width:0,height:0,draw:!1},SY=A.memo(function(e){var t=e.selectionKeyPressed,r=Ft(),n=A.useRef(0),i=A.useRef(0),o=A.useRef(),a=A.useState(hP),u=Be(a,2),c=u[0],d=u[1],f=gt(EY,Xt),h=f.userSelectionActive,p=f.elementsSelectable,v=h||t;if(!p||!v)return null;var m=function(){d(hP),r.setState({userSelectionActive:!1}),n.current=0,i.current=0},y=function(E){var _=E.target.closest(".react-flow");o.current=_.getBoundingClientRect();var R=dP(E,o.current);d({width:0,height:0,startX:R.x,startY:R.y,x:R.x,y:R.y,draw:!0}),r.setState({userSelectionActive:!0,nodesSelectionActive:!1})},x=function(E){var _,R;if(!(!t||!c.draw||!o.current)){var I=dP(E,o.current),N=(_=c.startX)!==null&&_!==void 0?_:0,D=(R=c.startY)!==null&&R!==void 0?R:0,k=fP(fP({},c),{},{x:I.x<N?I.x:N,y:I.y<D?I.y:D,width:Math.abs(I.x-N),height:Math.abs(I.y-D)}),B=r.getState(),L=B.nodeInternals,j=B.edges,T=B.transform,F=B.onNodesChange,$=B.onEdgesChange,W=Array.from(L.values()),Y=tq(L,k,T,!1,!0),ee=rq(Y,j).map(function(se){return se.id}),H=Y.map(function(se){return se.id});if(n.current!==H.length){n.current=H.length;var Q=Qi(W,H);Q.length&&(F==null||F(Q))}if(i.current!==ee.length){i.current=ee.length;var ce=Qi(j,ee);ce.length&&($==null||$(ce))}d(k)}},b=function(){r.setState({nodesSelectionActive:n.current>0}),m()},w=function(){r.setState({nodesSelectionActive:!1}),m()};return A.createElement("div",{className:"react-flow__selectionpane react-flow__container",onMouseDown:y,onMouseMove:x,onMouseUp:b,onMouseLeave:w},c.draw&&A.createElement("div",{className:"react-flow__selection react-flow__container",style:{width:c.width,height:c.height,transform:"translate(".concat(c.x,"px, ").concat(c.y,"px)")}}))});function pP(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function vP(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?pP(Object(r),!0).forEach(function(n){ze(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):pP(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function xq(e,t){if(!e.parentNode)return!1;var r=t.get(e.parentNode);return r?r.selected?!0:xq(r,t):!1}function gP(e,t,r){var n=e;do{var i;if((i=n)!==null&&i!==void 0&&i.matches(t))return!0;if(n===r.current)return!1;n=n.parentElement}while(n);return!1}function OY(e,t,r){return Array.from(e.values()).filter(function(n){return(n.selected||n.id===r)&&(!n.parentNode||!xq(n,e))}).map(function(n){var i,o,a,u;return{id:n.id,position:n.position||{x:0,y:0},positionAbsolute:n.positionAbsolute||{x:0,y:0},distance:{x:t.x-((i=(o=n.positionAbsolute)===null||o===void 0?void 0:o.x)!==null&&i!==void 0?i:0),y:t.y-((a=(u=n.positionAbsolute)===null||u===void 0?void 0:u.y)!==null&&a!==void 0?a:0)},delta:{x:0,y:0},extent:n.extent,parentNode:n.parentNode,width:n.width,height:n.height}})}function CY(e,t,r,n,i,o){var a=Be(n,2),u=a[0],c=a[1],d=e.extent||o,f={x:t.x-e.distance.x,y:t.y-e.distance.y};if(r&&(f.x=u*Math.round(f.x/u),f.y=c*Math.round(f.y/c)),e.extent==="parent")if(e.parentNode&&e.width&&e.height){var h=i.get(e.parentNode);d=h!=null&&h.positionAbsolute&&h!==null&&h!==void 0&&h.width&&h!==null&&h!==void 0&&h.height?[[h.positionAbsolute.x,h.positionAbsolute.y],[h.positionAbsolute.x+h.width-e.width,h.positionAbsolute.y+h.height-e.height]]:d}else process.env.NODE_ENV==="development"&&console.warn("[React Flow]: Only child nodes can use a parent extent. Help: https://reactflow.dev/error#500"),d=o;else if(e.extent&&e.parentNode){var p,v,m,y,x=i.get(e.parentNode),b=(p=x==null||(v=x.positionAbsolute)===null||v===void 0?void 0:v.x)!==null&&p!==void 0?p:0,w=(m=x==null||(y=x.positionAbsolute)===null||y===void 0?void 0:y.y)!==null&&m!==void 0?m:0;d=[[e.extent[0][0]+b,e.extent[0][1]+w],[e.extent[1][0]+b,e.extent[1][1]+w]]}var S={x:0,y:0};if(e.parentNode){var E,_,R,I,N=i.get(e.parentNode);S={x:(E=N==null||(_=N.positionAbsolute)===null||_===void 0?void 0:_.x)!==null&&E!==void 0?E:0,y:(R=N==null||(I=N.positionAbsolute)===null||I===void 0?void 0:I.y)!==null&&R!==void 0?R:0}}return e.positionAbsolute=d?Gj(f,d):f,e.position={x:e.positionAbsolute.x-S.x,y:e.positionAbsolute.y-S.y},e}function Rm(e){var t=e.nodeId,r=e.dragItems,n=e.nodeInternals,i=r.map(function(o){var a=n.get(o.id);return vP(vP({},a),{},{position:o.position,positionAbsolute:o.positionAbsolute})});return[t?i.find(function(o){return o.id===t}):i[0],i]}function Im(e){return function(t,r,n){return e==null?void 0:e(t,n)}}function wq(e){var t=e.nodeRef,r=e.disabled,n=r===void 0?!1:r,i=e.noDragClassName,o=e.handleSelector,a=e.nodeId,u=e.isSelectable,c=e.selectNodesOnDrag,d=A.useState(!1),f=Be(d,2),h=f[0],p=f[1],v=Ft(),m=A.useRef(),y=A.useRef({x:null,y:null}),x=A.useCallback(function(b){var w=b.sourceEvent,S=v.getState(),E=S.transform,_=S.snapGrid,R=S.snapToGrid,I=w.touches?w.touches[0].clientX:w.clientX,N=w.touches?w.touches[0].clientY:w.clientY,D=eq({x:I,y:N},E,R,_);return D},[]);return A.useEffect(function(){if(t!=null&&t.current){var b=Mr(t.current);if(n)b.on(".drag",null);else{var w=g8().on("start",function(S){var E=v.getState(),_=E.nodeInternals,R=E.multiSelectionActive,I=E.unselectNodesAndEdges,N=E.onNodeDragStart,D=E.onSelectionDragStart,k=a?N:Im(D);if(!c&&!R&&a){var B;(B=_.get(a))!==null&&B!==void 0&&B.selected||I()}a&&u&&c&&Qj({id:a,store:v});var L=x(S);if(y.current=L,m.current=OY(_,L,a),k&&m.current){var j=Rm({nodeId:a,dragItems:m.current,nodeInternals:_}),T=Be(j,2),F=T[0],$=T[1];k(S.sourceEvent,F,$)}}).on("drag",function(S){var E=v.getState(),_=E.updateNodePositions,R=E.snapToGrid,I=E.snapGrid,N=E.nodeInternals,D=E.nodeExtent,k=E.onNodeDrag,B=E.onSelectionDrag,L=x(S);if((y.current.x!==L.x||y.current.y!==L.y)&&m.current){y.current=L,m.current=m.current.map(function(Y){return CY(Y,L,R,I,N,D)});var j=a?k:Im(B);if(_(m.current,!0,!0),p(!0),j){var T=Rm({nodeId:a,dragItems:m.current,nodeInternals:N}),F=Be(T,2),$=F[0],W=F[1];j(S.sourceEvent,$,W)}}S.on("end",function(Y){if(p(!1),m.current){var ee=v.getState(),H=ee.updateNodePositions,Q=ee.nodeInternals,ce=ee.onNodeDragStop,se=ee.onSelectionDragStop,z=a?ce:Im(se);if(H(m.current,!1,!1),z){var G=Rm({nodeId:a,dragItems:m.current,nodeInternals:Q}),J=Be(G,2),V=J[0],K=J[1];z(Y.sourceEvent,V,K)}}})}).filter(function(S){var E=S.target,_=!S.button&&(!i||!gP(E,".".concat(i),t))&&(!o||gP(E,o,t));return _});return b.call(w),function(){b.on(".drag",null)}}}},[t,n,i,o,u,v,a,c,x]),h}function mP(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function RY(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?mP(Object(r),!0).forEach(function(n){ze(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):mP(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}var IY=function(t){return RY({transformString:"translate(".concat(t.transform[0],"px,").concat(t.transform[1],"px) scale(").concat(t.transform[2],")"),userSelectionActive:t.userSelectionActive},Px(Array.from(t.nodeInternals.values()).filter(function(r){return r.selected})))},PY=function(t){var r=Array.from(t.nodeInternals.values()).filter(function(n){return n.selected});return Px(r)};function NY(e){var t=e.onSelectionContextMenu,r=e.noPanClassName,n=Ft(),i=gt(IY,Xt),o=i.transformString,a=i.userSelectionActive,u=gt(PY,Xt),c=u.width,d=u.height,f=u.x,h=u.y,p=A.useRef(null);if(wq({nodeRef:p}),a||!c||!d)return null;var v=t?function(m){var y=Array.from(n.getState().nodeInternals.values()).filter(function(x){return x.selected});t(m,y)}:void 0;return A.createElement("div",{className:cr(["react-flow__nodesselection","react-flow__container",r]),style:{transform:o}},A.createElement("div",{ref:p,className:"react-flow__nodesselection-rect",onContextMenu:v,style:{width:c,height:d,top:h,left:f}}))}var TY=A.memo(NY),AY=function(t){return t.nodesSelectionActive},_q=function(t){var r=t.children,n=t.onPaneClick,i=t.onPaneContextMenu,o=t.onPaneScroll,a=t.deleteKeyCode,u=t.onMove,c=t.onMoveStart,d=t.onMoveEnd,f=t.selectionKeyCode,h=t.multiSelectionKeyCode,p=t.zoomActivationKeyCode,v=t.elementsSelectable,m=t.zoomOnScroll,y=t.zoomOnPinch,x=t.panOnScroll,b=t.panOnScrollSpeed,w=t.panOnScrollMode,S=t.zoomOnDoubleClick,E=t.panOnDrag,_=t.translateExtent,R=t.minZoom,I=t.maxZoom,N=t.defaultZoom,D=t.defaultPosition,k=t.preventScrolling,B=t.onSelectionContextMenu,L=t.noWheelClassName,j=t.noPanClassName,T=Ft(),F=gt(AY),$=rc(f);yY({deleteKeyCode:a,multiSelectionKeyCode:h});var W=function(Q){n==null||n(Q),T.getState().resetSelectedElements(),T.setState({nodesSelectionActive:!1})},Y=i?function(H){return i(H)}:void 0,ee=o?function(H){return o(H)}:void 0;return A.createElement(_Y,{onMove:u,onMoveStart:c,onMoveEnd:d,selectionKeyPressed:$,elementsSelectable:v,zoomOnScroll:m,zoomOnPinch:y,panOnScroll:x,panOnScrollSpeed:b,panOnScrollMode:w,zoomOnDoubleClick:S,panOnDrag:E,translateExtent:_,minZoom:R,maxZoom:I,defaultZoom:N,defaultPosition:D,zoomActivationKeyCode:p,preventScrolling:k,noWheelClassName:L,noPanClassName:j},r,A.createElement(SY,{selectionKeyPressed:$}),F&&A.createElement(TY,{onSelectionContextMenu:B,noPanClassName:j}),A.createElement("div",{className:"react-flow__pane react-flow__container",onClick:W,onContextMenu:Y,onWheel:ee}))};_q.displayName="FlowRenderer";var MY=A.memo(_q);function DY(e){var t=gt(A.useCallback(function(r){return e?tq(r.nodeInternals,{x:0,y:0,width:r.width,height:r.height},r.transform,!0):Array.from(r.nodeInternals.values())},[e]));return t}var jY=function(t){return{nodesDraggable:t.nodesDraggable,nodesConnectable:t.nodesConnectable,elementsSelectable:t.elementsSelectable,updateNodeDimensions:t.updateNodeDimensions}},Eq=function(t){var r=gt(jY,Xt),n=r.nodesDraggable,i=r.nodesConnectable,o=r.elementsSelectable,a=r.updateNodeDimensions,u=DY(t.onlyRenderVisibleElements),c=A.useRef(),d=A.useMemo(function(){if(typeof ResizeObserver>"u")return null;var f=new ResizeObserver(function(h){var p=h.map(function(v){return{id:v.target.getAttribute("data-id"),nodeElement:v.target,forceUpdate:!0}});a(p)});return c.current=f,f},[]);return A.useEffect(function(){return function(){var f;c==null||(f=c.current)===null||f===void 0||f.disconnect()}},[]),A.createElement("div",{className:"react-flow__nodes react-flow__container"},u.map(function(f){var h,p,v,m,y,x,b,w=f.type||"default";t.nodeTypes[w]||(process.env.NODE_ENV==="development"&&console.warn('[React Flow]: Node type "'.concat(w,'" not found. Using fallback type "default". Help: https://reactflow.dev/error#300')),w="default");var S=t.nodeTypes[w]||t.nodeTypes.default,E=!!(f.draggable||n&&typeof f.draggable>"u"),_=!!(f.selectable||o&&typeof f.selectable>"u"),R=!!(f.connectable||i&&typeof f.connectable>"u");return A.createElement(S,{key:f.id,id:f.id,className:f.className,style:f.style,type:w,data:f.data,sourcePosition:f.sourcePosition||xe.Bottom,targetPosition:f.targetPosition||xe.Top,hidden:f.hidden,xPos:(h=(p=f.positionAbsolute)===null||p===void 0?void 0:p.x)!==null&&h!==void 0?h:0,yPos:(v=(m=f.positionAbsolute)===null||m===void 0?void 0:m.y)!==null&&v!==void 0?v:0,selectNodesOnDrag:t.selectNodesOnDrag,onClick:t.onNodeClick,onMouseEnter:t.onNodeMouseEnter,onMouseMove:t.onNodeMouseMove,onMouseLeave:t.onNodeMouseLeave,onContextMenu:t.onNodeContextMenu,onDoubleClick:t.onNodeDoubleClick,selected:!!f.selected,isDraggable:E,isSelectable:_,isConnectable:R,resizeObserver:d,dragHandle:f.dragHandle,zIndex:(y=(x=f[Pt])===null||x===void 0?void 0:x.z)!==null&&y!==void 0?y:0,isParent:!!((b=f[Pt])!==null&&b!==void 0&&b.isParent),noDragClassName:t.noDragClassName,noPanClassName:t.noPanClassName,initialized:!!f.width&&!!f.height})}))};Eq.displayName="NodeRenderer";var qY=A.memo(Eq),Yi;function yP(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function bP(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?yP(Object(r),!0).forEach(function(n){ze(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):yP(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}var kY=(Yi={},ze(Yi,xe.Left,xe.Right),ze(Yi,xe.Right,xe.Left),ze(Yi,xe.Top,xe.Bottom),ze(Yi,xe.Bottom,xe.Top),Yi),LY=(function(e){var t,r,n,i,o,a=e.connectionNodeId,u=e.connectionHandleType,c=e.connectionLineStyle,d=e.connectionLineType,f=d===void 0?$n.Bezier:d,h=e.isConnectable,p=e.CustomConnectionLineComponent,v=gt(A.useCallback(function(ee){return{fromNode:ee.nodeInternals.get(a),handleId:ee.connectionHandleId,toX:(ee.connectionPosition.x-ee.transform[0])/ee.transform[2],toY:(ee.connectionPosition.y-ee.transform[1])/ee.transform[2]}},[a]),Xt),m=v.fromNode,y=v.handleId,x=v.toX,b=v.toY,w=m==null||(t=m[Pt])===null||t===void 0?void 0:t.handleBounds;if(!m||!h||!(w!=null&&w[u]))return null;var S=w[u],E=y?S.find(function(ee){return ee.id===y}):S[0],_=E?E.x+E.width/2:((r=m==null?void 0:m.width)!==null&&r!==void 0?r:0)/2,R=E?E.y+E.height/2:(n=m==null?void 0:m.height)!==null&&n!==void 0?n:0,I=((m==null||(i=m.positionAbsolute)===null||i===void 0?void 0:i.x)||0)+_,N=((m==null||(o=m.positionAbsolute)===null||o===void 0?void 0:o.y)||0)+R,D=E==null?void 0:E.position;if(!D)return null;var k=kY[D],B,L,j,T,F,$;switch(u){case"source":B=I,L=N,j=D,T=x,F=b,$=k;break;case"target":B=x,L=b,j=k,T=I,F=N,$=D;break}if(p)return A.createElement("g",{className:"react-flow__connection"},A.createElement(p,{connectionLineType:f,connectionLineStyle:c,fromNode:m,fromHandle:E,fromX:I,fromY:N,toX:x,toY:b,fromPosition:D,toPosition:k,sourcePosition:j,targetPosition:$,sourceNode:m,sourceHandle:E,targetX:T,targetY:F,sourceX:B,sourceY:L}));var W="",Y={sourceX:B,sourceY:L,sourcePosition:j,targetX:T,targetY:F,targetPosition:$};return f===$n.Bezier?W=Vc(Y):f===$n.Step?W=qb(bP(bP({},Y),{},{borderRadius:0})):f===$n.SmoothStep?W=qb(Y):f===$n.SimpleBezier?W=uq(Y):W="M".concat(B,",").concat(L," ").concat(T,",").concat(F),A.createElement("g",{className:"react-flow__connection"},A.createElement("path",{d:W,className:"react-flow__connection-path",style:c}))});function Fb(e){"@babel/helpers - typeof";return Fb=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Fb(e)}var bu,BY=function(t){var r=t.color,n=r===void 0?"none":r,i=t.strokeWidth,o=i===void 0?1:i;return A.createElement("polyline",{stroke:n,strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:o,fill:"none",points:"-5,-4 0,0 -5,4"})},FY=function(t){var r=t.color,n=r===void 0?"none":r,i=t.strokeWidth,o=i===void 0?1:i;return A.createElement("polyline",{stroke:n,strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:o,fill:n,points:"-5,-4 0,0 -5,4 -5,-4"})},xP=(bu={},ze(bu,Zu.Arrow,BY),ze(bu,Zu.ArrowClosed,FY),bu);function $Y(e){var t=A.useMemo(function(){var r=xP.hasOwnProperty(e);return r?xP[e]:(process.env.NODE_ENV==="development"&&console.warn('[React Flow]: Marker type "'.concat(e,`" doesn't exist. Help: https://reactflow.dev/error#900`)),function(){return null})},[e]);return t}function wP(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function zY(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?wP(Object(r),!0).forEach(function(n){ze(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):wP(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}var HY=function(t){var r=t.id,n=t.type,i=t.color,o=t.width,a=o===void 0?12.5:o,u=t.height,c=u===void 0?12.5:u,d=t.markerUnits,f=d===void 0?"strokeWidth":d,h=t.strokeWidth,p=t.orient,v=p===void 0?"auto":p,m=$Y(n);return A.createElement("marker",{className:"react-flow__arrowhead",id:r,markerWidth:"".concat(a),markerHeight:"".concat(c),viewBox:"-10 -10 20 20",markerUnits:f,orient:v,refX:"0",refY:"0"},A.createElement(m,{color:i,strokeWidth:h}))},UY=function(t){var r=t.defaultColor,n=t.rfId;return function(i){var o=[];return i.edges.reduce(function(a,u){return[u.markerStart,u.markerEnd].forEach(function(c){if(c&&Fb(c)==="object"){var d=Db(c,n);o.includes(d)||(a.push(zY({id:d,color:c.color||r},c)),o.push(d))}}),a},[]).sort(function(a,u){return a.id.localeCompare(u.id)})}},Sq=function(t){var r=t.defaultColor,n=t.rfId,i=gt(A.useCallback(UY({defaultColor:r,rfId:n}),[r,n]),function(o,a){return!(o.length!==a.length||o.some(function(u,c){return u.id!==a[c].id}))});return A.createElement("defs",null,i.map(function(o){return A.createElement(HY,{id:o.id,key:o.id,type:o.type,color:o.color,width:o.width,height:o.height,markerUnits:o.markerUnits,strokeWidth:o.strokeWidth,orient:o.orient})}))};Sq.displayName="MarkerDefinitions";var VY=A.memo(Sq),WY=[{level:0,isMaxLevel:!0,edges:[]}];function GY(e,t){var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!1,n=-1,i=e.reduce(function(a,u){var c=Yj(u.zIndex),d=c?u.zIndex:0;if(r){var f,h,p,v;d=c?u.zIndex:Math.max(((f=t.get(u.source))===null||f===void 0||(h=f[Pt])===null||h===void 0?void 0:h.z)||0,((p=t.get(u.target))===null||p===void 0||(v=p[Pt])===null||v===void 0?void 0:v.z)||0)}return a[d]?a[d].push(u):a[d]=[u],n=d>n?d:n,a},{}),o=Object.entries(i).map(function(a){var u=Be(a,2),c=u[0],d=u[1],f=+c;return{edges:d,level:f,isMaxLevel:f===n}});return o.length===0?WY:o}function KY(e,t,r){var n=gt(A.useCallback(function(i){return e?i.edges.filter(function(o){var a=t.get(o.source),u=t.get(o.target);return(a==null?void 0:a.width)&&(a==null?void 0:a.height)&&(u==null?void 0:u.width)&&(u==null?void 0:u.height)&&vY({sourcePos:a.positionAbsolute||{x:0,y:0},targetPos:u.positionAbsolute||{x:0,y:0},sourceWidth:a.width,sourceHeight:a.height,targetWidth:u.width,targetHeight:u.height,width:i.width,height:i.height,transform:i.transform})}):i.edges},[e,t]));return GY(n,t,r)}var YY=function(t){return{connectionNodeId:t.connectionNodeId,connectionHandleType:t.connectionHandleType,nodesConnectable:t.nodesConnectable,elementsSelectable:t.elementsSelectable,width:t.width,height:t.height,connectionMode:t.connectionMode,nodeInternals:t.nodeInternals}},Oq=function(t){var r=gt(YY,Xt),n=r.connectionNodeId,i=r.connectionHandleType,o=r.nodesConnectable,a=r.elementsSelectable,u=r.width,c=r.height,d=r.connectionMode,f=r.nodeInternals,h=KY(t.onlyRenderVisibleElements,f,t.elevateEdgesOnSelect);if(!u)return null;var p=t.connectionLineType,v=t.defaultMarkerColor,m=t.connectionLineStyle,y=t.connectionLineComponent,x=t.connectionLineContainerStyle,b=n&&i;return A.createElement(A.Fragment,null,h.map(function(w){var S=w.level,E=w.edges,_=w.isMaxLevel;return A.createElement("svg",{key:S,style:{zIndex:S},width:u,height:c,className:"react-flow__edges react-flow__container"},_&&A.createElement(VY,{defaultColor:v,rfId:t.rfId}),A.createElement("g",null,E.map(function(R){var I=aP(f,R.source),N=Be(I,3),D=N[0],k=N[1],B=N[2],L=aP(f,R.target),j=Be(L,3),T=j[0],F=j[1],$=j[2];if(!B||!$)return null;var W=R.type||"default";t.edgeTypes[W]||(console.warn('[React Flow]: Edge type "'.concat(W,'" not found. Using fallback type "default". Help: https://reactflow.dev/error#300')),W="default");var Y=t.edgeTypes[W]||t.edgeTypes.default,ee=d===mo.Strict?F.target:F.target||F.source,H=oP(k.source,R.sourceHandle||null),Q=oP(ee,R.targetHandle||null),ce=(H==null?void 0:H.position)||xe.Bottom,se=(Q==null?void 0:Q.position)||xe.Top;if(!H)return process.env.NODE_ENV==="development"&&console.warn("[React Flow]: Couldn't create edge for source handle id: ".concat(R.sourceHandle,"; edge id: ").concat(R.id,". Help: https://reactflow.dev/error#800")),null;if(!Q)return process.env.NODE_ENV==="development"&&console.warn("[React Flow]: Couldn't create edge for target handle id: ".concat(R.targetHandle,"; edge id: ").concat(R.id,". Help: https://reactflow.dev/error#800")),null;var z=pY(D,H,ce,T,Q,se),G=z.sourceX,J=z.sourceY,V=z.targetX,K=z.targetY;return A.createElement(Y,{key:R.id,id:R.id,className:cr([R.className,t.noPanClassName]),type:W,data:R.data,selected:!!R.selected,animated:!!R.animated,hidden:!!R.hidden,label:R.label,labelStyle:R.labelStyle,labelShowBg:R.labelShowBg,labelBgStyle:R.labelBgStyle,labelBgPadding:R.labelBgPadding,labelBgBorderRadius:R.labelBgBorderRadius,style:R.style,source:R.source,target:R.target,sourceHandleId:R.sourceHandle,targetHandleId:R.targetHandle,markerEnd:R.markerEnd,markerStart:R.markerStart,sourceX:G,sourceY:J,targetX:V,targetY:K,sourcePosition:ce,targetPosition:se,elementsSelectable:a,onEdgeUpdate:t.onEdgeUpdate,onContextMenu:t.onEdgeContextMenu,onMouseEnter:t.onEdgeMouseEnter,onMouseMove:t.onEdgeMouseMove,onMouseLeave:t.onEdgeMouseLeave,onClick:t.onEdgeClick,edgeUpdaterRadius:t.edgeUpdaterRadius,onEdgeDoubleClick:t.onEdgeDoubleClick,onEdgeUpdateStart:t.onEdgeUpdateStart,onEdgeUpdateEnd:t.onEdgeUpdateEnd,rfId:t.rfId})})))}),b&&A.createElement("svg",{style:x,width:u,height:c,className:"react-flow__edges react-flow__connectionline react-flow__container"},A.createElement(LY,{connectionNodeId:n,connectionHandleType:i,connectionLineStyle:m,connectionLineType:p,isConnectable:o,CustomConnectionLineComponent:y})))};Oq.displayName="EdgeRenderer";var XY=A.memo(Oq),ZY=function(t){return"translate(".concat(t.transform[0],"px,").concat(t.transform[1],"px) scale(").concat(t.transform[2],")")};function JY(e){var t=e.children,r=gt(ZY);return A.createElement("div",{className:"react-flow__viewport react-flow__container",style:{transform:r}},t)}function QY(e){var t=aq(),r=A.useRef(!1);A.useEffect(function(){!r.current&&t.viewportInitialized&&e&&(setTimeout(function(){return e(t)},1),r.current=!0)},[e,t.viewportInitialized])}var Cq=function(t){var r=t.nodeTypes,n=t.edgeTypes,i=t.onMove,o=t.onMoveStart,a=t.onMoveEnd,u=t.onInit,c=t.onNodeClick,d=t.onEdgeClick,f=t.onNodeDoubleClick,h=t.onEdgeDoubleClick,p=t.onNodeMouseEnter,v=t.onNodeMouseMove,m=t.onNodeMouseLeave,y=t.onNodeContextMenu,x=t.onSelectionContextMenu,b=t.connectionLineType,w=t.connectionLineStyle,S=t.connectionLineComponent,E=t.connectionLineContainerStyle,_=t.selectionKeyCode,R=t.multiSelectionKeyCode,I=t.zoomActivationKeyCode,N=t.deleteKeyCode,D=t.onlyRenderVisibleElements,k=t.elementsSelectable,B=t.selectNodesOnDrag,L=t.translateExtent,j=t.minZoom,T=t.maxZoom,F=t.defaultZoom,$=t.defaultPosition,W=t.preventScrolling,Y=t.defaultMarkerColor,ee=t.zoomOnScroll,H=t.zoomOnPinch,Q=t.panOnScroll,ce=t.panOnScrollSpeed,se=t.panOnScrollMode,z=t.zoomOnDoubleClick,G=t.panOnDrag,J=t.onPaneClick,V=t.onPaneScroll,K=t.onPaneContextMenu,ie=t.onEdgeUpdate,ne=t.onEdgeContextMenu,ue=t.onEdgeMouseEnter,de=t.onEdgeMouseMove,we=t.onEdgeMouseLeave,Se=t.edgeUpdaterRadius,_e=t.onEdgeUpdateStart,he=t.onEdgeUpdateEnd,ae=t.noDragClassName,Oe=t.noWheelClassName,Ne=t.noPanClassName,He=t.elevateEdgesOnSelect,qe=t.id;return QY(u),A.createElement(MY,{onPaneClick:J,onPaneContextMenu:K,onPaneScroll:V,deleteKeyCode:N,selectionKeyCode:_,multiSelectionKeyCode:R,zoomActivationKeyCode:I,elementsSelectable:k,onMove:i,onMoveStart:o,onMoveEnd:a,zoomOnScroll:ee,zoomOnPinch:H,zoomOnDoubleClick:z,panOnScroll:Q,panOnScrollSpeed:ce,panOnScrollMode:se,panOnDrag:G,translateExtent:L,minZoom:j,maxZoom:T,defaultZoom:F,defaultPosition:$,onSelectionContextMenu:x,preventScrolling:W,noDragClassName:ae,noWheelClassName:Oe,noPanClassName:Ne},A.createElement(JY,null,A.createElement(XY,{edgeTypes:n,onEdgeClick:d,onEdgeDoubleClick:h,connectionLineType:b,connectionLineStyle:w,connectionLineComponent:S,connectionLineContainerStyle:E,onEdgeUpdate:ie,onlyRenderVisibleElements:D,onEdgeContextMenu:ne,onEdgeMouseEnter:ue,onEdgeMouseMove:de,onEdgeMouseLeave:we,onEdgeUpdateStart:_e,onEdgeUpdateEnd:he,edgeUpdaterRadius:Se,defaultMarkerColor:Y,noPanClassName:Ne,elevateEdgesOnSelect:!!He,rfId:qe}),A.createElement(qY,{nodeTypes:r,onNodeClick:c,onNodeDoubleClick:f,onNodeMouseEnter:p,onNodeMouseMove:v,onNodeMouseLeave:m,onNodeContextMenu:y,selectNodesOnDrag:B,onlyRenderVisibleElements:D,noPanClassName:Ne,noDragClassName:ae})))};Cq.displayName="GraphView";var e9=A.memo(Cq),Rq=function(){return null};Rq.displayName="GroupNode";function _P(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function EP(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?_P(Object(r),!0).forEach(function(n){ze(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):_P(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}var ra=(function(e){var t=function(n){var i=n.id,o=n.type,a=n.data,u=n.xPos,c=n.yPos,d=n.selected,f=n.onClick,h=n.onMouseEnter,p=n.onMouseMove,v=n.onMouseLeave,m=n.onContextMenu,y=n.onDoubleClick,x=n.style,b=n.className,w=n.isDraggable,S=n.isSelectable,E=n.isConnectable,_=n.selectNodesOnDrag,R=n.sourcePosition,I=n.targetPosition,N=n.hidden,D=n.resizeObserver,k=n.dragHandle,B=n.zIndex,L=n.isParent,j=n.noPanClassName,T=n.noDragClassName,F=n.initialized,$=Ft(),W=A.useRef(null),Y=A.useRef(R),ee=A.useRef(I),H=A.useRef(o),Q=S||w||f||h||p||v,ce=ea(i,$.getState,h),se=ea(i,$.getState,p),z=ea(i,$.getState,v),G=ea(i,$.getState,m),J=ea(i,$.getState,y),V=function(ne){if(S&&(!_||!w)&&Qj({id:i,store:$}),f){var ue=$.getState().nodeInternals.get(i);f(ne,EP({},ue))}};A.useEffect(function(){if(W.current&&!N){var ie=W.current;return D==null||D.observe(ie),function(){return D==null?void 0:D.unobserve(ie)}}},[N]),A.useEffect(function(){var ie=H.current!==o,ne=Y.current!==R,ue=ee.current!==I;W.current&&(ie||ne||ue)&&(ie&&(H.current=o),ne&&(Y.current=R),ue&&(ee.current=I),$.getState().updateNodeDimensions([{id:i,nodeElement:W.current,forceUpdate:!0}]))},[i,o,R,I]);var K=wq({nodeRef:W,disabled:N||!w,noDragClassName:T,handleSelector:k,nodeId:i,isSelectable:S,selectNodesOnDrag:_});return N?null:A.createElement("div",{className:cr(["react-flow__node","react-flow__node-".concat(o),j,b,{selected:d,selectable:S,parent:L}]),ref:W,style:EP({zIndex:B,transform:"translate(".concat(u,"px,").concat(c,"px)"),pointerEvents:Q?"all":"none",visibility:F?"visible":"hidden"},x),onMouseEnter:ce,onMouseMove:se,onMouseLeave:z,onContextMenu:G,onClick:V,onDoubleClick:J,"data-testid":"rf__node-".concat(i),"data-id":i},A.createElement(ZK,{value:i},A.createElement(e,{id:i,data:a,type:o,xPos:u,yPos:c,selected:d,isConnectable:E,sourcePosition:R,targetPosition:I,dragging:K,dragHandle:k,zIndex:B})))};return t.displayName="NodeWrapper",A.memo(t)});function SP(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function OP(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?SP(Object(r),!0).forEach(function(n){ze(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):SP(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function t9(e){var t={input:ra(e.input||mq),default:ra(e.default||Bb),output:ra(e.output||bq),group:ra(e.group||Rq)},r={},n=Object.keys(e).filter(function(i){return!["input","default","output","group"].includes(i)}).reduce(function(i,o){return i[o]=ra(e[o]||Bb),i},r);return OP(OP({},t),n)}function CP(e,t){var r=A.useRef(null),n=A.useMemo(function(){if(process.env.NODE_ENV==="development"){var i=Object.keys(e);Xt(r.current,i)&&console.warn("[React Flow]: It looks like you have created a new nodeTypes or edgeTypes object. If this wasn't on purpose please define the nodeTypes/edgeTypes outside of the component or memoize them. Help: https://reactflow.dev/error#200"),r.current=i}return t(e)},[e]);return n}function RP(e){if(!(!e||typeof document>"u")){var t=document.head||document.getElementsByTagName("head")[0],r=document.createElement("style");t.appendChild(r),r.appendChild(document.createTextNode(e))}}var Iq=function(t){var r=t.children,n=!0;try{Ft()}catch{n=!1}return n?A.createElement(A.Fragment,null,r):A.createElement(bK,{createStore:xK},r)};Iq.displayName="ReactFlowWrapper";var r9=["nodes","edges","defaultNodes","defaultEdges","className","nodeTypes","edgeTypes","onNodeClick","onEdgeClick","onInit","onMove","onMoveStart","onMoveEnd","onConnect","onConnectStart","onConnectStop","onConnectEnd","onClickConnectStart","onClickConnectStop","onClickConnectEnd","onNodeMouseEnter","onNodeMouseMove","onNodeMouseLeave","onNodeContextMenu","onNodeDoubleClick","onNodeDragStart","onNodeDrag","onNodeDragStop","onNodesDelete","onEdgesDelete","onSelectionChange","onSelectionDragStart","onSelectionDrag","onSelectionDragStop","onSelectionContextMenu","connectionMode","connectionLineType","connectionLineStyle","connectionLineComponent","connectionLineContainerStyle","deleteKeyCode","selectionKeyCode","multiSelectionKeyCode","zoomActivationKeyCode","snapToGrid","snapGrid","onlyRenderVisibleElements","selectNodesOnDrag","nodesDraggable","nodesConnectable","elementsSelectable","minZoom","maxZoom","defaultZoom","defaultPosition","translateExtent","preventScrolling","nodeExtent","defaultMarkerColor","zoomOnScroll","zoomOnPinch","panOnScroll","panOnScrollSpeed","panOnScrollMode","zoomOnDoubleClick","panOnDrag","onPaneClick","onPaneScroll","onPaneContextMenu","children","onEdgeUpdate","onEdgeContextMenu","onEdgeDoubleClick","onEdgeMouseEnter","onEdgeMouseMove","onEdgeMouseLeave","onEdgeUpdateStart","onEdgeUpdateEnd","edgeUpdaterRadius","onNodesChange","onEdgesChange","noDragClassName","noWheelClassName","noPanClassName","fitView","fitViewOptions","connectOnClick","attributionPosition","proOptions","defaultEdgeOptions","elevateEdgesOnSelect"];function IP(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function PP(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?IP(Object(r),!0).forEach(function(n){ze(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):IP(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}RP(uY),RP(lY);var n9={input:mq,default:Bb,output:bq},i9={default:kb,straight:dq,step:fq,smoothstep:Tx,simplebezier:cq},o9=[15,15],a9=[0,0],Pq=A.forwardRef(function(e,t){var r=e.nodes,n=e.edges,i=e.defaultNodes,o=e.defaultEdges,a=e.className,u=e.nodeTypes,c=u===void 0?n9:u,d=e.edgeTypes,f=d===void 0?i9:d,h=e.onNodeClick,p=e.onEdgeClick,v=e.onInit,m=e.onMove,y=e.onMoveStart,x=e.onMoveEnd,b=e.onConnect,w=e.onConnectStart,S=e.onConnectStop,E=e.onConnectEnd,_=e.onClickConnectStart,R=e.onClickConnectStop,I=e.onClickConnectEnd,N=e.onNodeMouseEnter,D=e.onNodeMouseMove,k=e.onNodeMouseLeave,B=e.onNodeContextMenu,L=e.onNodeDoubleClick,j=e.onNodeDragStart,T=e.onNodeDrag,F=e.onNodeDragStop,$=e.onNodesDelete,W=e.onEdgesDelete,Y=e.onSelectionChange,ee=e.onSelectionDragStart,H=e.onSelectionDrag,Q=e.onSelectionDragStop,ce=e.onSelectionContextMenu,se=e.connectionMode,z=se===void 0?mo.Strict:se,G=e.connectionLineType,J=G===void 0?$n.Bezier:G,V=e.connectionLineStyle,K=e.connectionLineComponent,ie=e.connectionLineContainerStyle,ne=e.deleteKeyCode,ue=ne===void 0?"Backspace":ne,de=e.selectionKeyCode,we=de===void 0?"Shift":de,Se=e.multiSelectionKeyCode,_e=Se===void 0?"Meta":Se,he=e.zoomActivationKeyCode,ae=he===void 0?"Meta":he,Oe=e.snapToGrid,Ne=Oe===void 0?!1:Oe,He=e.snapGrid,qe=He===void 0?o9:He,Xe=e.onlyRenderVisibleElements,We=Xe===void 0?!1:Xe,mt=e.selectNodesOnDrag,et=mt===void 0?!0:mt,Tt=e.nodesDraggable,ut=e.nodesConnectable,tt=e.elementsSelectable,Ct=e.minZoom,Jt=Ct===void 0?.5:Ct,lr=e.maxZoom,Dt=lr===void 0?2:lr,xt=e.defaultZoom,jt=xt===void 0?1:xt,Hr=e.defaultPosition,Yn=Hr===void 0?a9:Hr,Cn=e.translateExtent,Ur=Cn===void 0?jb:Cn,Pi=e.preventScrolling,vl=Pi===void 0?!0:Pi,ts=e.nodeExtent,No=e.defaultMarkerColor,gl=No===void 0?"#b1b1b7":No,rs=e.zoomOnScroll,ml=rs===void 0?!0:rs,ns=e.zoomOnPinch,is=ns===void 0?!0:ns,os=e.panOnScroll,yl=os===void 0?!1:os,as=e.panOnScrollSpeed,To=as===void 0?.5:as,ss=e.panOnScrollMode,Ao=ss===void 0?io.Free:ss,us=e.zoomOnDoubleClick,bl=us===void 0?!0:us,cs=e.panOnDrag,xl=cs===void 0?!0:cs,wl=e.onPaneClick,_l=e.onPaneScroll,El=e.onPaneContextMenu,Sl=e.children,ls=e.onEdgeUpdate,Ol=e.onEdgeContextMenu,Cl=e.onEdgeDoubleClick,Rl=e.onEdgeMouseEnter,Il=e.onEdgeMouseMove,Pl=e.onEdgeMouseLeave,Nl=e.onEdgeUpdateStart,Ni=e.onEdgeUpdateEnd,fs=e.edgeUpdaterRadius,Ti=fs===void 0?10:fs,Tl=e.onNodesChange,Al=e.onEdgesChange,ds=e.noDragClassName,hs=ds===void 0?"nodrag":ds,Mo=e.noWheelClassName,ps=Mo===void 0?"nowheel":Mo,vs=e.noPanClassName,Ml=vs===void 0?"nopan":vs,gs=e.fitView,Dl=gs===void 0?!1:gs,ms=e.fitViewOptions,Do=e.connectOnClick,ys=Do===void 0?!0:Do,jo=e.attributionPosition,jl=e.proOptions,bs=e.defaultEdgeOptions,Xn=e.elevateEdgesOnSelect,xs=Xn===void 0?!1:Xn,Ai=Hc(e,r9),ws=CP(c,t9),_s=CP(f,hY);return A.createElement("div",PP(PP({},Ai),{},{ref:t,className:cr(["react-flow",a])}),A.createElement(Iq,null,A.createElement(e9,{onInit:v,onMove:m,onMoveStart:y,onMoveEnd:x,onNodeClick:h,onEdgeClick:p,onNodeMouseEnter:N,onNodeMouseMove:D,onNodeMouseLeave:k,onNodeContextMenu:B,onNodeDoubleClick:L,nodeTypes:ws,edgeTypes:_s,connectionLineType:J,connectionLineStyle:V,connectionLineComponent:K,connectionLineContainerStyle:ie,selectionKeyCode:we,deleteKeyCode:ue,multiSelectionKeyCode:_e,zoomActivationKeyCode:ae,onlyRenderVisibleElements:We,selectNodesOnDrag:et,translateExtent:Ur,minZoom:Jt,maxZoom:Dt,defaultZoom:jt,defaultPosition:Yn,preventScrolling:vl,zoomOnScroll:ml,zoomOnPinch:is,zoomOnDoubleClick:bl,panOnScroll:yl,panOnScrollSpeed:To,panOnScrollMode:Ao,panOnDrag:xl,onPaneClick:wl,onPaneScroll:_l,onPaneContextMenu:El,onSelectionContextMenu:ce,onEdgeUpdate:ls,onEdgeContextMenu:Ol,onEdgeDoubleClick:Cl,onEdgeMouseEnter:Rl,onEdgeMouseMove:Il,onEdgeMouseLeave:Pl,onEdgeUpdateStart:Nl,onEdgeUpdateEnd:Ni,edgeUpdaterRadius:Ti,defaultMarkerColor:gl,noDragClassName:hs,noWheelClassName:ps,noPanClassName:Ml,elevateEdgesOnSelect:xs,id:Ai==null?void 0:Ai.id}),A.createElement(aY,{nodes:r,edges:n,defaultNodes:i,defaultEdges:o,onConnect:b,onConnectStart:w,onConnectStop:S,onConnectEnd:E,onClickConnectStart:_,onClickConnectStop:R,onClickConnectEnd:I,nodesDraggable:Tt,nodesConnectable:ut,elementsSelectable:tt,minZoom:Jt,maxZoom:Dt,nodeExtent:ts,onNodesChange:Tl,onEdgesChange:Al,snapToGrid:Ne,snapGrid:qe,connectionMode:z,translateExtent:Ur,connectOnClick:ys,defaultEdgeOptions:bs,fitView:Dl,fitViewOptions:ms,onNodesDelete:$,onEdgesDelete:W,onNodeDragStart:j,onNodeDrag:T,onNodeDragStop:F,onSelectionDrag:H,onSelectionDragStart:ee,onSelectionDragStop:Q}),Y&&A.createElement(iY,{onSelectionChange:Y}),Sl,A.createElement(HK,{proOptions:jl,position:jo})))});Pq.displayName="ReactFlow";function Nq(e){return function(t){var r=A.useState(t),n=Be(r,2),i=n[0],o=n[1],a=A.useCallback(function(u){return o(function(c){return e(u,c)})},[]);return[i,o,a]}}var s9=Nq(Zj),u9=Nq(dK);function NP(e,t){const{width:r,height:n,positionAbsolute:i}=e,o=t.positionAbsolute,a=r/2,u=n/2,c=i.x+a,d=i.y+u,f=o.x+a,h=o.y+u,p=(f-c)/(2*a)-(h-d)/(2*u),v=(f-c)/(2*a)+(h-d)/(2*u),m=1/(Math.abs(p)+Math.abs(v)),y=m*p,x=m*v,b=a*(y+x)+c,w=u*(-y+x)+d;return{x:b,y:w}}function TP(e,t){const r={...e.positionAbsolute,...e},n=Math.round(r.x),i=Math.round(r.y),o=Math.round(t.x),a=Math.round(t.y);return o<=n+1?xe.Left:o>=n+r.width-1?xe.Right:a<=i+1?xe.Top:a>=r.y+r.height-1?xe.Bottom:xe.Top}function Tq(e,t){const r=NP(e,t),n=NP(t,e),i=TP(e,r),o=TP(t,n);return{sx:r.x,sy:r.y,tx:n.x,ty:n.y,sourcePos:i,targetPos:o}}const c9=({targetX:e,targetY:t,sourcePosition:r,targetPosition:n,sourceNode:i})=>{if(!i)return null;const o={id:"connection-target",width:1,height:1,position:{x:e,y:t}},{sx:a,sy:u}=Tq(i,o),c=Vc({sourceX:a,sourceY:u,sourcePosition:r,targetPosition:n,targetX:e,targetY:t});return C.jsxs("g",{children:[C.jsx("path",{fill:"none",stroke:"#222",strokeWidth:1.5,className:"animated",d:c}),C.jsx("circle",{cx:e,cy:t,fill:"#fff",r:3,stroke:"#222",strokeWidth:1.5})]})},l9=({id:e,source:t,target:r,markerEnd:n,style:i})=>{const o=gt(A.useCallback(m=>m.nodeInternals.get(t),[t])),a=gt(A.useCallback(m=>m.nodeInternals.get(r),[r]));if(!o||!a)return null;const{sx:u,sy:c,tx:d,ty:f,sourcePos:h,targetPos:p}=Tq(o,a),v=Vc({sourceX:u,sourceY:c,sourcePosition:h,targetPosition:p,targetX:d,targetY:f});return C.jsx("path",{id:e,className:"react-flow__edge-path",d:v,markerEnd:n,style:i})},AP=172,MP=36,f9={custom:l9},d9=(e,t,r="LR")=>{const n=new mI.graphlib.Graph;n.setDefaultEdgeLabel(()=>({}));const i=r==="LR";return n.setGraph({rankdir:r}),e.forEach(o=>{n.setNode(o.id,{width:AP,height:MP})}),t.forEach(o=>{n.setEdge(o.source,o.target)}),mI.layout(n),e.forEach(o=>{const a=n.node(o.id);return o.targetPosition=i?xe.Left:xe.Top,o.sourcePosition=i?xe.Right:xe.Bottom,o.position={x:a.x-AP/2,y:a.y-MP/2},o}),{nodes:e,edges:t}},h9=()=>{},p9=({data:e,dict:t,onSelect:r=h9})=>{const{nodes:n,edges:i}=d9(Object.values(t).filter(h=>h.id===e.selected||e.parents.flat().includes(h.id)||e.children.flat().includes(h.id)).map(h=>({id:h.id,type:h.parents.length===0?"input":h.includes.length===0?"output":"default",sourcePosition:xe.Right,targetPosition:xe.Left,data:{label:h.privilege},position:{x:0,y:0},className:h.id===e.selected?"highlighted":"",selected:h.id===e.selected})),e.links.map(({source:h,target:p})=>({id:`e${h}-${p}`,source:h,target:p}))),[o,a,u]=s9(n),[c,d,f]=u9(i);return A.useEffect(()=>{a([...n]),d([...i])},[e]),C.jsx(Pq,{nodes:o,edges:c,fitView:!0,onNodesChange:u,onEdgesChange:f,onNodeClick:(h,p)=>{r(p.id)},defaultZoom:.5,edgeTypes:f9,connectionLineComponent:c9,children:C.jsx($K,{variant:mi.Dots,color:"#81818140",gap:18,size:1})})};var Aq=(e=>(e.method="methods",e.entityCollection="entityselMethod",e.dataClass="dataclassMethod",e.dataStore="dsMethod",e.entity="entityMethod",e.attribute="attributes",e.singletonMethod="singletonMethod",e))(Aq||{});const Mq=e=>{switch(e){case"entityCollection":return Z.ESubPermissionType.ENTITY_SEL_METHOD;case"dataClass":return Z.ESubPermissionType.DATACLASS_METHOD;case"dataStore":return Z.ESubPermissionType.DS_METHOD;case"entity":return Z.ESubPermissionType.ENTITY_METHOD;default:return Z.EPermissionType.METHOD}},DP=(e=[],t,r)=>{var i;const n=[];for(const o of e)(i=o[Aq[r]])==null||i.forEach(a=>{if(`${o.name.toLowerCase()}.${a.name.toLowerCase()}`.includes(t)||!t){const c={applyTo:`${o.name}.${a.name}`,type:r};r===Z.EPermissionType.METHOD&&(c.subType=Mq(a.applyTo)),n.push(c)}});return n},v9=(e=[],t)=>{var n;const r=[];for(const i of e)(n=i.methods)==null||n.forEach(o=>{(`${i.name.toLowerCase()}.${o.name.toLowerCase()}`.includes(t)||!t)&&r.push({applyTo:`${i.name}.${o.name}`,type:Z.EPermissionType.SINGLETON_METHOD})});return r};function Mx(e,t=[],r=[],n=[]){const i=DP(r,e,Z.EPermissionType.ATTRIBUTE),o=DP(r,e,Z.EPermissionType.METHOD),a=v9(n,e),u=t.filter(h=>!e||`ds.${h.name.toLowerCase()}`.includes(e)).map(h=>({applyTo:`ds.${h.name}`,type:Z.ESubPermissionType.DS_METHOD})),c=[],d=[];return r.filter(h=>h.name.toLowerCase().includes(e)).forEach(h=>{c.push({applyTo:h.name,type:Z.EPermissionType.DATACLASS})}),n.filter(h=>h.name.toLowerCase().includes(e)).forEach(h=>{d.push({applyTo:h.name,type:Z.EPermissionType.SINGLETON})}),[...[{applyTo:"ds",type:Z.EPermissionType.DATASTORE}].filter(h=>!e||`ds.${h.applyTo.toLowerCase()}`.includes(e)),...u,...c,...i,...o,...d,...a].reduce((h,p)=>{const v=["datastore","singleton","dataclass","attribute","dsMethod","dataclassMethod","entityMethod","entityselMethod","singletonMethod"],[m,y]=p.applyTo.split("."),x=h.find(b=>b.prefix===m);return x?(x.resources=[...x.resources,p].sort((b,w)=>{const S=v.indexOf(b.type),E=v.indexOf(w.type);return S>E?1:-1}),x.type=y?x.type:p.type,[...h].sort((b,w)=>{const S=v.indexOf(b.type),E=v.indexOf(w.type);return S>E?1:-1})):[...h,{prefix:m,type:y?null:p.type,resources:[p]}]},[]).reduce((h,p)=>[...h,...p.resources],[])}const g9=(e=[],t=[],r=[])=>{const n=Mx("",e,t,r),i={ds:{applyTo:"ds",type:Z.EPermissionType.DATASTORE,methods:[],dataClasses:[],singletons:[]}},o=(u,c)=>u.applyTo.localeCompare(c.applyTo);n.forEach(u=>{const[c,d]=u.applyTo.split(".");if(d||(u.type===Z.EPermissionType.DATACLASS?i.ds.dataClasses.push({applyTo:c,type:Z.EPermissionType.DATACLASS,methods:[],attributes:[]}):u.type===Z.EPermissionType.SINGLETON&&i.ds.singletons.push({applyTo:c,type:Z.EPermissionType.SINGLETON,methods:[],attributes:[]})),d){const f=(h,p,v)=>{h.forEach(m=>{m.applyTo===c&&m[p].push(v)})};[Z.ESubPermissionType.DS_METHOD,Z.ESubPermissionType.DATACLASS_METHOD,Z.ESubPermissionType.ENTITY_METHOD,Z.ESubPermissionType.ENTITY_SEL_METHOD].includes(u.type)?c==="ds"?i.ds.methods.push(u):f(i.ds.dataClasses,"methods",u):u.type===Z.EPermissionType.ATTRIBUTE?(f(i.ds.dataClasses,"attributes",u),f(i.ds.singletons,"attributes",u)):u.type===Z.EPermissionType.SINGLETON_METHOD&&f(i.ds.singletons,"methods",u)}});const a=u=>{u.forEach(c=>{c.methods&&c.methods.sort(o),c.attributes&&c.attributes.sort(o)})};return i.ds.methods.sort(o),i.ds.dataClasses.sort(o),i.ds.singletons.sort(o),a(i.ds.dataClasses),a(i.ds.singletons),i},Dq=(e,t=[])=>{const r={};return Object.entries(e).forEach(([n,i])=>{r[n]={...i,resources:i.resources.map(o=>{var a,u,c;if(o.type===Z.EPermissionType.METHOD&&t.length){const[d,f]=o.resource.split("."),h=d==="ds"?"dataStore":((c=(u=(a=t.find(p=>p.name===d))==null?void 0:a.methods)==null?void 0:u.find(p=>p.name===f))==null?void 0:c.applyTo)||"dataClass";return{...o,type:o.type,subType:Mq(h)}}return o})}}),r},jq=(e,t)=>Object.entries(e).map(([r,n])=>{const i=n.resources.map(o=>{var d,f,h,p,v,m,y,x;const[a,u]=o.resource.split(".");let c=!0;switch(o.type){case Z.EPermissionType.DATASTORE:c=!!t;break;case Z.EPermissionType.METHOD:a==="ds"?c=!!t.methods.find(b=>b.name===u&&b.applyTo==="dataStore"):c=!!((f=(d=t.dataClasses[a])==null?void 0:d.methods)!=null&&f.find(b=>b.name===u));break;case Z.ESubPermissionType.DS_METHOD:c=!!t.methods.find(b=>b.name===u&&b.applyTo==="dataStore");break;case Z.EPermissionType.DATACLASS:c=!!t.dataClasses[a];break;case Z.EPermissionType.ATTRIBUTE:c=!!((p=(h=t.dataClasses[a])==null?void 0:h.attributes)!=null&&p.find(b=>b.name===u));break;case Z.ESubPermissionType.ENTITY_SEL_METHOD:c=!!((v=t.dataClasses[a])!=null&&v.methods.find(b=>b.name===u&&b.applyTo==="entityCollection"));break;case Z.ESubPermissionType.DATACLASS_METHOD:c=!!((m=t.dataClasses[a])!=null&&m.methods.find(b=>b.name===u&&b.applyTo==="dataClass"));break;case Z.ESubPermissionType.ENTITY_METHOD:c=!!((y=t.dataClasses[a])!=null&&y.methods.find(b=>b.name===u&&b.applyTo==="entity"));break;case Z.EPermissionType.SINGLETON_METHOD:c=!!((x=t.singletons[a])!=null&&x.methods.find(b=>b.name===u));break;case Z.EPermissionType.SINGLETON:c=!!t.singletons[a];break;default:c=!0}return{...o,exists:c}});return{[r]:{...n,resources:i}}}).reduce((r,n)=>({...r,...n}),{}),Pm=({child:e,parent:t,status:r,onSelect:n,currentPrivilegeId:i})=>{const o=Z.useAppDispatch(),a=Z.useAppSelector(Z.selectPrivileges);function u(){const d=Z.addIn(t.id,e.id,a);o(Z.updatePrivileges(d))}function c(){const d=Z.removeFrom(t.id,e.id,a);o(Z.updatePrivileges(d))}return C.jsxs("div",{className:Ve("inline-flex cursor-pointer items-center gap-1 space-x-1 rounded px-2 py-0.5",{"bg-primary-dark text-white":r==="included","bg-grey-300 text-grey-100":r!=="included","opacity-40":r==="disabled"}),children:[C.jsx("span",{onClick:()=>n(i),className:"text-xs hover:underline",children:e.privilege}),r==="included"?C.jsx("button",{onClick:c,children:C.jsx("span",{className:"text-[13px]",children:C.jsx(ye.FdPlus,{className:"rotate-45 transform text-white"})})}):C.jsx("button",{disabled:r==="disabled",onClick:u,className:"opacity-70 disabled:cursor-not-allowed",children:C.jsx("span",{className:"text-[13px]",children:C.jsx(ye.FdPlus,{className:"text-white"})})})]})},m9=({selectedPrivilege:e,privileges:t,onSelect:r,setShowIncluded:n,showIncluded:i})=>{const o=Object.values(t),a=Z.getPrivilegeById(e.id,t);let u=a?Z.populateShallow(a.includes,t):[],c=a?Z.populateShallow(Z.parents(a.id,t),t):[],d=a?Z.populateShallow(Z.allowed(a.id,t),t):[];return[u,c,d]=[u,c,d].map(f=>f.filter(h=>(h==null?void 0:h.privilege)!=="guest")),o.length<2&&u.length+c.length+d.length===0?null:C.jsxs("div",{className:"w-full border-b border-grey-900 p-4",children:[C.jsxs("div",{className:"mb-4 flex items-center justify-between",children:[" ",o.length>2?C.jsx("h4",{className:"text-[13px] font-semibold text-white",children:"Include a privilege"}):C.jsx("div",{}),C.jsxs("div",{className:"flex items-center gap-2",children:[C.jsx(Te.ControlledSwitch,{onChange:()=>n(!i),value:i}),C.jsxs("label",{className:"text-xs text-[#F6F6F6]",children:[" ","Show inherited permissions"]})]})]}),C.jsxs("div",{className:"flex flex-wrap items-start justify-start gap-1",children:[u.map(f=>C.jsx(Pm,{child:f,parent:e,status:"included",onSelect:r,currentPrivilegeId:f.id},f.id)),d.map(f=>C.jsx(Pm,{child:f,parent:e,status:"available",onSelect:r,currentPrivilegeId:f.id},f.id)),c.map(f=>C.jsx(Pm,{child:f,parent:e,status:"disabled",onSelect:r,currentPrivilegeId:f.id},f.id))]})]})};function xr(e,t,{checkForDefaultPrevented:r=!0}={}){return function(i){if(e==null||e(i),r===!1||!i.defaultPrevented)return t==null?void 0:t(i)}}function qq(e,t=[]){let r=[];function n(o,a){const u=ve.createContext(a),c=r.length;r=[...r,a];const d=h=>{var b;const{scope:p,children:v,...m}=h,y=((b=p==null?void 0:p[e])==null?void 0:b[c])||u,x=ve.useMemo(()=>m,Object.values(m));return C.jsx(y.Provider,{value:x,children:v})};d.displayName=o+"Provider";function f(h,p){var y;const v=((y=p==null?void 0:p[e])==null?void 0:y[c])||u,m=ve.useContext(v);if(m)return m;if(a!==void 0)return a;throw new Error(`\`${h}\` must be used within \`${o}\``)}return[d,f]}const i=()=>{const o=r.map(a=>ve.createContext(a));return function(u){const c=(u==null?void 0:u[e])||o;return ve.useMemo(()=>({[`__scope${e}`]:{...u,[e]:c}}),[u,c])}};return i.scopeName=e,[n,y9(i,...t)]}function y9(...e){const t=e[0];if(e.length===1)return t;const r=()=>{const n=e.map(i=>({useScope:i(),scopeName:i.scopeName}));return function(o){const a=n.reduce((u,{useScope:c,scopeName:d})=>{const h=c(o)[`__scope${d}`];return{...u,...h}},{});return ve.useMemo(()=>({[`__scope${t.scopeName}`]:a}),[a])}};return r.scopeName=t.scopeName,r}var yi=globalThis!=null&&globalThis.document?ve.useLayoutEffect:()=>{},b9=ve[" useInsertionEffect ".trim().toString()]||yi;function x9({prop:e,defaultProp:t,onChange:r=()=>{},caller:n}){const[i,o,a]=w9({defaultProp:t,onChange:r}),u=e!==void 0,c=u?e:i;{const f=ve.useRef(e!==void 0);ve.useEffect(()=>{const h=f.current;h!==u&&console.warn(`${n} is changing from ${h?"controlled":"uncontrolled"} to ${u?"controlled":"uncontrolled"}. Components should not switch from controlled to uncontrolled (or vice versa). Decide between using a controlled or uncontrolled value for the lifetime of the component.`),f.current=u},[u,n])}const d=ve.useCallback(f=>{var h;if(u){const p=_9(f)?f(e):f;p!==e&&((h=a.current)==null||h.call(a,p))}else o(f)},[u,e,o,a]);return[c,d]}function w9({defaultProp:e,onChange:t}){const[r,n]=ve.useState(e),i=ve.useRef(r),o=ve.useRef(t);return b9(()=>{o.current=t},[t]),ve.useEffect(()=>{var a;i.current!==r&&((a=o.current)==null||a.call(o,r),i.current=r)},[r,i]),[r,n,o]}function _9(e){return typeof e=="function"}function jP(e,t){if(typeof e=="function")return e(t);e!=null&&(e.current=t)}function kq(...e){return t=>{let r=!1;const n=e.map(i=>{const o=jP(i,t);return!r&&typeof o=="function"&&(r=!0),o});if(r)return()=>{for(let i=0;i<n.length;i++){const o=n[i];typeof o=="function"?o():jP(e[i],null)}}}}function So(...e){return ve.useCallback(kq(...e),e)}const E9=["top","right","bottom","left"],zn=Math.min,or=Math.max,nc=Math.round,xu=Math.floor,tn=e=>({x:e,y:e}),S9={left:"right",right:"left",bottom:"top",top:"bottom"},O9={start:"end",end:"start"};function $b(e,t,r){return or(e,zn(t,r))}function wn(e,t){return typeof e=="function"?e(t):e}function _n(e){return e.split("-")[0]}function Oo(e){return e.split("-")[1]}function Dx(e){return e==="x"?"y":"x"}function jx(e){return e==="y"?"height":"width"}const C9=new Set(["top","bottom"]);function Jr(e){return C9.has(_n(e))?"y":"x"}function qx(e){return Dx(Jr(e))}function R9(e,t,r){r===void 0&&(r=!1);const n=Oo(e),i=qx(e),o=jx(i);let a=i==="x"?n===(r?"end":"start")?"right":"left":n==="start"?"bottom":"top";return t.reference[o]>t.floating[o]&&(a=ic(a)),[a,ic(a)]}function I9(e){const t=ic(e);return[zb(e),t,zb(t)]}function zb(e){return e.replace(/start|end/g,t=>O9[t])}const qP=["left","right"],kP=["right","left"],P9=["top","bottom"],N9=["bottom","top"];function T9(e,t,r){switch(e){case"top":case"bottom":return r?t?kP:qP:t?qP:kP;case"left":case"right":return t?P9:N9;default:return[]}}function A9(e,t,r,n){const i=Oo(e);let o=T9(_n(e),r==="start",n);return i&&(o=o.map(a=>a+"-"+i),t&&(o=o.concat(o.map(zb)))),o}function ic(e){return e.replace(/left|right|bottom|top/g,t=>S9[t])}function M9(e){return{top:0,right:0,bottom:0,left:0,...e}}function Lq(e){return typeof e!="number"?M9(e):{top:e,right:e,bottom:e,left:e}}function oc(e){const{x:t,y:r,width:n,height:i}=e;return{width:n,height:i,top:r,left:t,right:t+n,bottom:r+i,x:t,y:r}}function LP(e,t,r){let{reference:n,floating:i}=e;const o=Jr(t),a=qx(t),u=jx(a),c=_n(t),d=o==="y",f=n.x+n.width/2-i.width/2,h=n.y+n.height/2-i.height/2,p=n[u]/2-i[u]/2;let v;switch(c){case"top":v={x:f,y:n.y-i.height};break;case"bottom":v={x:f,y:n.y+n.height};break;case"right":v={x:n.x+n.width,y:h};break;case"left":v={x:n.x-i.width,y:h};break;default:v={x:n.x,y:n.y}}switch(Oo(t)){case"start":v[a]-=p*(r&&d?-1:1);break;case"end":v[a]+=p*(r&&d?-1:1);break}return v}const D9=async(e,t,r)=>{const{placement:n="bottom",strategy:i="absolute",middleware:o=[],platform:a}=r,u=o.filter(Boolean),c=await(a.isRTL==null?void 0:a.isRTL(t));let d=await a.getElementRects({reference:e,floating:t,strategy:i}),{x:f,y:h}=LP(d,n,c),p=n,v={},m=0;for(let y=0;y<u.length;y++){const{name:x,fn:b}=u[y],{x:w,y:S,data:E,reset:_}=await b({x:f,y:h,initialPlacement:n,placement:p,strategy:i,middlewareData:v,rects:d,platform:a,elements:{reference:e,floating:t}});f=w??f,h=S??h,v={...v,[x]:{...v[x],...E}},_&&m<=50&&(m++,typeof _=="object"&&(_.placement&&(p=_.placement),_.rects&&(d=_.rects===!0?await a.getElementRects({reference:e,floating:t,strategy:i}):_.rects),{x:f,y:h}=LP(d,p,c)),y=-1)}return{x:f,y:h,placement:p,strategy:i,middlewareData:v}};async function ka(e,t){var r;t===void 0&&(t={});const{x:n,y:i,platform:o,rects:a,elements:u,strategy:c}=e,{boundary:d="clippingAncestors",rootBoundary:f="viewport",elementContext:h="floating",altBoundary:p=!1,padding:v=0}=wn(t,e),m=Lq(v),x=u[p?h==="floating"?"reference":"floating":h],b=oc(await o.getClippingRect({element:(r=await(o.isElement==null?void 0:o.isElement(x)))==null||r?x:x.contextElement||await(o.getDocumentElement==null?void 0:o.getDocumentElement(u.floating)),boundary:d,rootBoundary:f,strategy:c})),w=h==="floating"?{x:n,y:i,width:a.floating.width,height:a.floating.height}:a.reference,S=await(o.getOffsetParent==null?void 0:o.getOffsetParent(u.floating)),E=await(o.isElement==null?void 0:o.isElement(S))?await(o.getScale==null?void 0:o.getScale(S))||{x:1,y:1}:{x:1,y:1},_=oc(o.convertOffsetParentRelativeRectToViewportRelativeRect?await o.convertOffsetParentRelativeRectToViewportRelativeRect({elements:u,rect:w,offsetParent:S,strategy:c}):w);return{top:(b.top-_.top+m.top)/E.y,bottom:(_.bottom-b.bottom+m.bottom)/E.y,left:(b.left-_.left+m.left)/E.x,right:(_.right-b.right+m.right)/E.x}}const j9=e=>({name:"arrow",options:e,async fn(t){const{x:r,y:n,placement:i,rects:o,platform:a,elements:u,middlewareData:c}=t,{element:d,padding:f=0}=wn(e,t)||{};if(d==null)return{};const h=Lq(f),p={x:r,y:n},v=qx(i),m=jx(v),y=await a.getDimensions(d),x=v==="y",b=x?"top":"left",w=x?"bottom":"right",S=x?"clientHeight":"clientWidth",E=o.reference[m]+o.reference[v]-p[v]-o.floating[m],_=p[v]-o.reference[v],R=await(a.getOffsetParent==null?void 0:a.getOffsetParent(d));let I=R?R[S]:0;(!I||!await(a.isElement==null?void 0:a.isElement(R)))&&(I=u.floating[S]||o.floating[m]);const N=E/2-_/2,D=I/2-y[m]/2-1,k=zn(h[b],D),B=zn(h[w],D),L=k,j=I-y[m]-B,T=I/2-y[m]/2+N,F=$b(L,T,j),$=!c.arrow&&Oo(i)!=null&&T!==F&&o.reference[m]/2-(T<L?k:B)-y[m]/2<0,W=$?T<L?T-L:T-j:0;return{[v]:p[v]+W,data:{[v]:F,centerOffset:T-F-W,...$&&{alignmentOffset:W}},reset:$}}}),q9=function(e){return e===void 0&&(e={}),{name:"flip",options:e,async fn(t){var r,n;const{placement:i,middlewareData:o,rects:a,initialPlacement:u,platform:c,elements:d}=t,{mainAxis:f=!0,crossAxis:h=!0,fallbackPlacements:p,fallbackStrategy:v="bestFit",fallbackAxisSideDirection:m="none",flipAlignment:y=!0,...x}=wn(e,t);if((r=o.arrow)!=null&&r.alignmentOffset)return{};const b=_n(i),w=Jr(u),S=_n(u)===u,E=await(c.isRTL==null?void 0:c.isRTL(d.floating)),_=p||(S||!y?[ic(u)]:I9(u)),R=m!=="none";!p&&R&&_.push(...A9(u,y,m,E));const I=[u,..._],N=await ka(t,x),D=[];let k=((n=o.flip)==null?void 0:n.overflows)||[];if(f&&D.push(N[b]),h){const T=R9(i,a,E);D.push(N[T[0]],N[T[1]])}if(k=[...k,{placement:i,overflows:D}],!D.every(T=>T<=0)){var B,L;const T=(((B=o.flip)==null?void 0:B.index)||0)+1,F=I[T];if(F&&(!(h==="alignment"?w!==Jr(F):!1)||k.every(Y=>Jr(Y.placement)===w?Y.overflows[0]>0:!0)))return{data:{index:T,overflows:k},reset:{placement:F}};let $=(L=k.filter(W=>W.overflows[0]<=0).sort((W,Y)=>W.overflows[1]-Y.overflows[1])[0])==null?void 0:L.placement;if(!$)switch(v){case"bestFit":{var j;const W=(j=k.filter(Y=>{if(R){const ee=Jr(Y.placement);return ee===w||ee==="y"}return!0}).map(Y=>[Y.placement,Y.overflows.filter(ee=>ee>0).reduce((ee,H)=>ee+H,0)]).sort((Y,ee)=>Y[1]-ee[1])[0])==null?void 0:j[0];W&&($=W);break}case"initialPlacement":$=u;break}if(i!==$)return{reset:{placement:$}}}return{}}}};function BP(e,t){return{top:e.top-t.height,right:e.right-t.width,bottom:e.bottom-t.height,left:e.left-t.width}}function FP(e){return E9.some(t=>e[t]>=0)}const k9=function(e){return e===void 0&&(e={}),{name:"hide",options:e,async fn(t){const{rects:r}=t,{strategy:n="referenceHidden",...i}=wn(e,t);switch(n){case"referenceHidden":{const o=await ka(t,{...i,elementContext:"reference"}),a=BP(o,r.reference);return{data:{referenceHiddenOffsets:a,referenceHidden:FP(a)}}}case"escaped":{const o=await ka(t,{...i,altBoundary:!0}),a=BP(o,r.floating);return{data:{escapedOffsets:a,escaped:FP(a)}}}default:return{}}}}},Bq=new Set(["left","top"]);async function L9(e,t){const{placement:r,platform:n,elements:i}=e,o=await(n.isRTL==null?void 0:n.isRTL(i.floating)),a=_n(r),u=Oo(r),c=Jr(r)==="y",d=Bq.has(a)?-1:1,f=o&&c?-1:1,h=wn(t,e);let{mainAxis:p,crossAxis:v,alignmentAxis:m}=typeof h=="number"?{mainAxis:h,crossAxis:0,alignmentAxis:null}:{mainAxis:h.mainAxis||0,crossAxis:h.crossAxis||0,alignmentAxis:h.alignmentAxis};return u&&typeof m=="number"&&(v=u==="end"?m*-1:m),c?{x:v*f,y:p*d}:{x:p*d,y:v*f}}const B9=function(e){return e===void 0&&(e=0),{name:"offset",options:e,async fn(t){var r,n;const{x:i,y:o,placement:a,middlewareData:u}=t,c=await L9(t,e);return a===((r=u.offset)==null?void 0:r.placement)&&(n=u.arrow)!=null&&n.alignmentOffset?{}:{x:i+c.x,y:o+c.y,data:{...c,placement:a}}}}},F9=function(e){return e===void 0&&(e={}),{name:"shift",options:e,async fn(t){const{x:r,y:n,placement:i}=t,{mainAxis:o=!0,crossAxis:a=!1,limiter:u={fn:x=>{let{x:b,y:w}=x;return{x:b,y:w}}},...c}=wn(e,t),d={x:r,y:n},f=await ka(t,c),h=Jr(_n(i)),p=Dx(h);let v=d[p],m=d[h];if(o){const x=p==="y"?"top":"left",b=p==="y"?"bottom":"right",w=v+f[x],S=v-f[b];v=$b(w,v,S)}if(a){const x=h==="y"?"top":"left",b=h==="y"?"bottom":"right",w=m+f[x],S=m-f[b];m=$b(w,m,S)}const y=u.fn({...t,[p]:v,[h]:m});return{...y,data:{x:y.x-r,y:y.y-n,enabled:{[p]:o,[h]:a}}}}}},$9=function(e){return e===void 0&&(e={}),{options:e,fn(t){const{x:r,y:n,placement:i,rects:o,middlewareData:a}=t,{offset:u=0,mainAxis:c=!0,crossAxis:d=!0}=wn(e,t),f={x:r,y:n},h=Jr(i),p=Dx(h);let v=f[p],m=f[h];const y=wn(u,t),x=typeof y=="number"?{mainAxis:y,crossAxis:0}:{mainAxis:0,crossAxis:0,...y};if(c){const S=p==="y"?"height":"width",E=o.reference[p]-o.floating[S]+x.mainAxis,_=o.reference[p]+o.reference[S]-x.mainAxis;v<E?v=E:v>_&&(v=_)}if(d){var b,w;const S=p==="y"?"width":"height",E=Bq.has(_n(i)),_=o.reference[h]-o.floating[S]+(E&&((b=a.offset)==null?void 0:b[h])||0)+(E?0:x.crossAxis),R=o.reference[h]+o.reference[S]+(E?0:((w=a.offset)==null?void 0:w[h])||0)-(E?x.crossAxis:0);m<_?m=_:m>R&&(m=R)}return{[p]:v,[h]:m}}}},z9=function(e){return e===void 0&&(e={}),{name:"size",options:e,async fn(t){var r,n;const{placement:i,rects:o,platform:a,elements:u}=t,{apply:c=()=>{},...d}=wn(e,t),f=await ka(t,d),h=_n(i),p=Oo(i),v=Jr(i)==="y",{width:m,height:y}=o.floating;let x,b;h==="top"||h==="bottom"?(x=h,b=p===(await(a.isRTL==null?void 0:a.isRTL(u.floating))?"start":"end")?"left":"right"):(b=h,x=p==="end"?"top":"bottom");const w=y-f.top-f.bottom,S=m-f.left-f.right,E=zn(y-f[x],w),_=zn(m-f[b],S),R=!t.middlewareData.shift;let I=E,N=_;if((r=t.middlewareData.shift)!=null&&r.enabled.x&&(N=S),(n=t.middlewareData.shift)!=null&&n.enabled.y&&(I=w),R&&!p){const k=or(f.left,0),B=or(f.right,0),L=or(f.top,0),j=or(f.bottom,0);v?N=m-2*(k!==0||B!==0?k+B:or(f.left,f.right)):I=y-2*(L!==0||j!==0?L+j:or(f.top,f.bottom))}await c({...t,availableWidth:N,availableHeight:I});const D=await a.getDimensions(u.floating);return m!==D.width||y!==D.height?{reset:{rects:!0}}:{}}}};function Wc(){return typeof window<"u"}function Co(e){return Fq(e)?(e.nodeName||"").toLowerCase():"#document"}function ar(e){var t;return(e==null||(t=e.ownerDocument)==null?void 0:t.defaultView)||window}function sn(e){var t;return(t=(Fq(e)?e.ownerDocument:e.document)||window.document)==null?void 0:t.documentElement}function Fq(e){return Wc()?e instanceof Node||e instanceof ar(e).Node:!1}function Lr(e){return Wc()?e instanceof Element||e instanceof ar(e).Element:!1}function nn(e){return Wc()?e instanceof HTMLElement||e instanceof ar(e).HTMLElement:!1}function $P(e){return!Wc()||typeof ShadowRoot>"u"?!1:e instanceof ShadowRoot||e instanceof ar(e).ShadowRoot}const H9=new Set(["inline","contents"]);function Ya(e){const{overflow:t,overflowX:r,overflowY:n,display:i}=Br(e);return/auto|scroll|overlay|hidden|clip/.test(t+n+r)&&!H9.has(i)}const U9=new Set(["table","td","th"]);function V9(e){return U9.has(Co(e))}const W9=[":popover-open",":modal"];function Gc(e){return W9.some(t=>{try{return e.matches(t)}catch{return!1}})}const G9=["transform","translate","scale","rotate","perspective"],K9=["transform","translate","scale","rotate","perspective","filter"],Y9=["paint","layout","strict","content"];function kx(e){const t=Lx(),r=Lr(e)?Br(e):e;return G9.some(n=>r[n]?r[n]!=="none":!1)||(r.containerType?r.containerType!=="normal":!1)||!t&&(r.backdropFilter?r.backdropFilter!=="none":!1)||!t&&(r.filter?r.filter!=="none":!1)||K9.some(n=>(r.willChange||"").includes(n))||Y9.some(n=>(r.contain||"").includes(n))}function X9(e){let t=Hn(e);for(;nn(t)&&!yo(t);){if(kx(t))return t;if(Gc(t))return null;t=Hn(t)}return null}function Lx(){return typeof CSS>"u"||!CSS.supports?!1:CSS.supports("-webkit-backdrop-filter","none")}const Z9=new Set(["html","body","#document"]);function yo(e){return Z9.has(Co(e))}function Br(e){return ar(e).getComputedStyle(e)}function Kc(e){return Lr(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.scrollX,scrollTop:e.scrollY}}function Hn(e){if(Co(e)==="html")return e;const t=e.assignedSlot||e.parentNode||$P(e)&&e.host||sn(e);return $P(t)?t.host:t}function $q(e){const t=Hn(e);return yo(t)?e.ownerDocument?e.ownerDocument.body:e.body:nn(t)&&Ya(t)?t:$q(t)}function La(e,t,r){var n;t===void 0&&(t=[]),r===void 0&&(r=!0);const i=$q(e),o=i===((n=e.ownerDocument)==null?void 0:n.body),a=ar(i);if(o){const u=Hb(a);return t.concat(a,a.visualViewport||[],Ya(i)?i:[],u&&r?La(u):[])}return t.concat(i,La(i,[],r))}function Hb(e){return e.parent&&Object.getPrototypeOf(e.parent)?e.frameElement:null}function zq(e){const t=Br(e);let r=parseFloat(t.width)||0,n=parseFloat(t.height)||0;const i=nn(e),o=i?e.offsetWidth:r,a=i?e.offsetHeight:n,u=nc(r)!==o||nc(n)!==a;return u&&(r=o,n=a),{width:r,height:n,$:u}}function Bx(e){return Lr(e)?e:e.contextElement}function ao(e){const t=Bx(e);if(!nn(t))return tn(1);const r=t.getBoundingClientRect(),{width:n,height:i,$:o}=zq(t);let a=(o?nc(r.width):r.width)/n,u=(o?nc(r.height):r.height)/i;return(!a||!Number.isFinite(a))&&(a=1),(!u||!Number.isFinite(u))&&(u=1),{x:a,y:u}}const J9=tn(0);function Hq(e){const t=ar(e);return!Lx()||!t.visualViewport?J9:{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}}function Q9(e,t,r){return t===void 0&&(t=!1),!r||t&&r!==ar(e)?!1:t}function bi(e,t,r,n){t===void 0&&(t=!1),r===void 0&&(r=!1);const i=e.getBoundingClientRect(),o=Bx(e);let a=tn(1);t&&(n?Lr(n)&&(a=ao(n)):a=ao(e));const u=Q9(o,r,n)?Hq(o):tn(0);let c=(i.left+u.x)/a.x,d=(i.top+u.y)/a.y,f=i.width/a.x,h=i.height/a.y;if(o){const p=ar(o),v=n&&Lr(n)?ar(n):n;let m=p,y=Hb(m);for(;y&&n&&v!==m;){const x=ao(y),b=y.getBoundingClientRect(),w=Br(y),S=b.left+(y.clientLeft+parseFloat(w.paddingLeft))*x.x,E=b.top+(y.clientTop+parseFloat(w.paddingTop))*x.y;c*=x.x,d*=x.y,f*=x.x,h*=x.y,c+=S,d+=E,m=ar(y),y=Hb(m)}}return oc({width:f,height:h,x:c,y:d})}function Yc(e,t){const r=Kc(e).scrollLeft;return t?t.left+r:bi(sn(e)).left+r}function Uq(e,t){const r=e.getBoundingClientRect(),n=r.left+t.scrollLeft-Yc(e,r),i=r.top+t.scrollTop;return{x:n,y:i}}function e7(e){let{elements:t,rect:r,offsetParent:n,strategy:i}=e;const o=i==="fixed",a=sn(n),u=t?Gc(t.floating):!1;if(n===a||u&&o)return r;let c={scrollLeft:0,scrollTop:0},d=tn(1);const f=tn(0),h=nn(n);if((h||!h&&!o)&&((Co(n)!=="body"||Ya(a))&&(c=Kc(n)),nn(n))){const v=bi(n);d=ao(n),f.x=v.x+n.clientLeft,f.y=v.y+n.clientTop}const p=a&&!h&&!o?Uq(a,c):tn(0);return{width:r.width*d.x,height:r.height*d.y,x:r.x*d.x-c.scrollLeft*d.x+f.x+p.x,y:r.y*d.y-c.scrollTop*d.y+f.y+p.y}}function t7(e){return Array.from(e.getClientRects())}function r7(e){const t=sn(e),r=Kc(e),n=e.ownerDocument.body,i=or(t.scrollWidth,t.clientWidth,n.scrollWidth,n.clientWidth),o=or(t.scrollHeight,t.clientHeight,n.scrollHeight,n.clientHeight);let a=-r.scrollLeft+Yc(e);const u=-r.scrollTop;return Br(n).direction==="rtl"&&(a+=or(t.clientWidth,n.clientWidth)-i),{width:i,height:o,x:a,y:u}}const zP=25;function n7(e,t){const r=ar(e),n=sn(e),i=r.visualViewport;let o=n.clientWidth,a=n.clientHeight,u=0,c=0;if(i){o=i.width,a=i.height;const f=Lx();(!f||f&&t==="fixed")&&(u=i.offsetLeft,c=i.offsetTop)}const d=Yc(n);if(d<=0){const f=n.ownerDocument,h=f.body,p=getComputedStyle(h),v=f.compatMode==="CSS1Compat"&&parseFloat(p.marginLeft)+parseFloat(p.marginRight)||0,m=Math.abs(n.clientWidth-h.clientWidth-v);m<=zP&&(o-=m)}else d<=zP&&(o+=d);return{width:o,height:a,x:u,y:c}}const i7=new Set(["absolute","fixed"]);function o7(e,t){const r=bi(e,!0,t==="fixed"),n=r.top+e.clientTop,i=r.left+e.clientLeft,o=nn(e)?ao(e):tn(1),a=e.clientWidth*o.x,u=e.clientHeight*o.y,c=i*o.x,d=n*o.y;return{width:a,height:u,x:c,y:d}}function HP(e,t,r){let n;if(t==="viewport")n=n7(e,r);else if(t==="document")n=r7(sn(e));else if(Lr(t))n=o7(t,r);else{const i=Hq(e);n={x:t.x-i.x,y:t.y-i.y,width:t.width,height:t.height}}return oc(n)}function Vq(e,t){const r=Hn(e);return r===t||!Lr(r)||yo(r)?!1:Br(r).position==="fixed"||Vq(r,t)}function a7(e,t){const r=t.get(e);if(r)return r;let n=La(e,[],!1).filter(u=>Lr(u)&&Co(u)!=="body"),i=null;const o=Br(e).position==="fixed";let a=o?Hn(e):e;for(;Lr(a)&&!yo(a);){const u=Br(a),c=kx(a);!c&&u.position==="fixed"&&(i=null),(o?!c&&!i:!c&&u.position==="static"&&!!i&&i7.has(i.position)||Ya(a)&&!c&&Vq(e,a))?n=n.filter(f=>f!==a):i=u,a=Hn(a)}return t.set(e,n),n}function s7(e){let{element:t,boundary:r,rootBoundary:n,strategy:i}=e;const a=[...r==="clippingAncestors"?Gc(t)?[]:a7(t,this._c):[].concat(r),n],u=a[0],c=a.reduce((d,f)=>{const h=HP(t,f,i);return d.top=or(h.top,d.top),d.right=zn(h.right,d.right),d.bottom=zn(h.bottom,d.bottom),d.left=or(h.left,d.left),d},HP(t,u,i));return{width:c.right-c.left,height:c.bottom-c.top,x:c.left,y:c.top}}function u7(e){const{width:t,height:r}=zq(e);return{width:t,height:r}}function c7(e,t,r){const n=nn(t),i=sn(t),o=r==="fixed",a=bi(e,!0,o,t);let u={scrollLeft:0,scrollTop:0};const c=tn(0);function d(){c.x=Yc(i)}if(n||!n&&!o)if((Co(t)!=="body"||Ya(i))&&(u=Kc(t)),n){const v=bi(t,!0,o,t);c.x=v.x+t.clientLeft,c.y=v.y+t.clientTop}else i&&d();o&&!n&&i&&d();const f=i&&!n&&!o?Uq(i,u):tn(0),h=a.left+u.scrollLeft-c.x-f.x,p=a.top+u.scrollTop-c.y-f.y;return{x:h,y:p,width:a.width,height:a.height}}function Nm(e){return Br(e).position==="static"}function UP(e,t){if(!nn(e)||Br(e).position==="fixed")return null;if(t)return t(e);let r=e.offsetParent;return sn(e)===r&&(r=r.ownerDocument.body),r}function Wq(e,t){const r=ar(e);if(Gc(e))return r;if(!nn(e)){let i=Hn(e);for(;i&&!yo(i);){if(Lr(i)&&!Nm(i))return i;i=Hn(i)}return r}let n=UP(e,t);for(;n&&V9(n)&&Nm(n);)n=UP(n,t);return n&&yo(n)&&Nm(n)&&!kx(n)?r:n||X9(e)||r}const l7=async function(e){const t=this.getOffsetParent||Wq,r=this.getDimensions,n=await r(e.floating);return{reference:c7(e.reference,await t(e.floating),e.strategy),floating:{x:0,y:0,width:n.width,height:n.height}}};function f7(e){return Br(e).direction==="rtl"}const d7={convertOffsetParentRelativeRectToViewportRelativeRect:e7,getDocumentElement:sn,getClippingRect:s7,getOffsetParent:Wq,getElementRects:l7,getClientRects:t7,getDimensions:u7,getScale:ao,isElement:Lr,isRTL:f7};function Gq(e,t){return e.x===t.x&&e.y===t.y&&e.width===t.width&&e.height===t.height}function h7(e,t){let r=null,n;const i=sn(e);function o(){var u;clearTimeout(n),(u=r)==null||u.disconnect(),r=null}function a(u,c){u===void 0&&(u=!1),c===void 0&&(c=1),o();const d=e.getBoundingClientRect(),{left:f,top:h,width:p,height:v}=d;if(u||t(),!p||!v)return;const m=xu(h),y=xu(i.clientWidth-(f+p)),x=xu(i.clientHeight-(h+v)),b=xu(f),S={rootMargin:-m+"px "+-y+"px "+-x+"px "+-b+"px",threshold:or(0,zn(1,c))||1};let E=!0;function _(R){const I=R[0].intersectionRatio;if(I!==c){if(!E)return a();I?a(!1,I):n=setTimeout(()=>{a(!1,1e-7)},1e3)}I===1&&!Gq(d,e.getBoundingClientRect())&&a(),E=!1}try{r=new IntersectionObserver(_,{...S,root:i.ownerDocument})}catch{r=new IntersectionObserver(_,S)}r.observe(e)}return a(!0),o}function p7(e,t,r,n){n===void 0&&(n={});const{ancestorScroll:i=!0,ancestorResize:o=!0,elementResize:a=typeof ResizeObserver=="function",layoutShift:u=typeof IntersectionObserver=="function",animationFrame:c=!1}=n,d=Bx(e),f=i||o?[...d?La(d):[],...La(t)]:[];f.forEach(b=>{i&&b.addEventListener("scroll",r,{passive:!0}),o&&b.addEventListener("resize",r)});const h=d&&u?h7(d,r):null;let p=-1,v=null;a&&(v=new ResizeObserver(b=>{let[w]=b;w&&w.target===d&&v&&(v.unobserve(t),cancelAnimationFrame(p),p=requestAnimationFrame(()=>{var S;(S=v)==null||S.observe(t)})),r()}),d&&!c&&v.observe(d),v.observe(t));let m,y=c?bi(e):null;c&&x();function x(){const b=bi(e);y&&!Gq(y,b)&&r(),y=b,m=requestAnimationFrame(x)}return r(),()=>{var b;f.forEach(w=>{i&&w.removeEventListener("scroll",r),o&&w.removeEventListener("resize",r)}),h==null||h(),(b=v)==null||b.disconnect(),v=null,c&&cancelAnimationFrame(m)}}const v7=B9,g7=F9,m7=q9,y7=z9,b7=k9,VP=j9,x7=$9,w7=(e,t,r)=>{const n=new Map,i={platform:d7,...r},o={...i.platform,_c:n};return D9(e,t,{...i,platform:o})};var _7=typeof document<"u",E7=function(){},Lu=_7?A.useLayoutEffect:E7;function ac(e,t){if(e===t)return!0;if(typeof e!=typeof t)return!1;if(typeof e=="function"&&e.toString()===t.toString())return!0;let r,n,i;if(e&&t&&typeof e=="object"){if(Array.isArray(e)){if(r=e.length,r!==t.length)return!1;for(n=r;n--!==0;)if(!ac(e[n],t[n]))return!1;return!0}if(i=Object.keys(e),r=i.length,r!==Object.keys(t).length)return!1;for(n=r;n--!==0;)if(!{}.hasOwnProperty.call(t,i[n]))return!1;for(n=r;n--!==0;){const o=i[n];if(!(o==="_owner"&&e.$$typeof)&&!ac(e[o],t[o]))return!1}return!0}return e!==e&&t!==t}function Kq(e){return typeof window>"u"?1:(e.ownerDocument.defaultView||window).devicePixelRatio||1}function WP(e,t){const r=Kq(e);return Math.round(t*r)/r}function Tm(e){const t=ve.useRef(e);return Lu(()=>{t.current=e}),t}function S7(e){e===void 0&&(e={});const{placement:t="bottom",strategy:r="absolute",middleware:n=[],platform:i,elements:{reference:o,floating:a}={},transform:u=!0,whileElementsMounted:c,open:d}=e,[f,h]=ve.useState({x:0,y:0,strategy:r,placement:t,middlewareData:{},isPositioned:!1}),[p,v]=ve.useState(n);ac(p,n)||v(n);const[m,y]=ve.useState(null),[x,b]=ve.useState(null),w=ve.useCallback(Y=>{Y!==R.current&&(R.current=Y,y(Y))},[]),S=ve.useCallback(Y=>{Y!==I.current&&(I.current=Y,b(Y))},[]),E=o||m,_=a||x,R=ve.useRef(null),I=ve.useRef(null),N=ve.useRef(f),D=c!=null,k=Tm(c),B=Tm(i),L=Tm(d),j=ve.useCallback(()=>{if(!R.current||!I.current)return;const Y={placement:t,strategy:r,middleware:p};B.current&&(Y.platform=B.current),w7(R.current,I.current,Y).then(ee=>{const H={...ee,isPositioned:L.current!==!1};T.current&&!ac(N.current,H)&&(N.current=H,Yb.flushSync(()=>{h(H)}))})},[p,t,r,B,L]);Lu(()=>{d===!1&&N.current.isPositioned&&(N.current.isPositioned=!1,h(Y=>({...Y,isPositioned:!1})))},[d]);const T=ve.useRef(!1);Lu(()=>(T.current=!0,()=>{T.current=!1}),[]),Lu(()=>{if(E&&(R.current=E),_&&(I.current=_),E&&_){if(k.current)return k.current(E,_,j);j()}},[E,_,j,k,D]);const F=ve.useMemo(()=>({reference:R,floating:I,setReference:w,setFloating:S}),[w,S]),$=ve.useMemo(()=>({reference:E,floating:_}),[E,_]),W=ve.useMemo(()=>{const Y={position:r,left:0,top:0};if(!$.floating)return Y;const ee=WP($.floating,f.x),H=WP($.floating,f.y);return u?{...Y,transform:"translate("+ee+"px, "+H+"px)",...Kq($.floating)>=1.5&&{willChange:"transform"}}:{position:r,left:ee,top:H}},[r,u,$.floating,f.x,f.y]);return ve.useMemo(()=>({...f,update:j,refs:F,elements:$,floatingStyles:W}),[f,j,F,$,W])}const O7=e=>{function t(r){return{}.hasOwnProperty.call(r,"current")}return{name:"arrow",options:e,fn(r){const{element:n,padding:i}=typeof e=="function"?e(r):e;return n&&t(n)?n.current!=null?VP({element:n.current,padding:i}).fn(r):{}:n?VP({element:n,padding:i}).fn(r):{}}}},C7=(e,t)=>({...v7(e),options:[e,t]}),R7=(e,t)=>({...g7(e),options:[e,t]}),I7=(e,t)=>({...x7(e),options:[e,t]}),P7=(e,t)=>({...m7(e),options:[e,t]}),N7=(e,t)=>({...y7(e),options:[e,t]}),T7=(e,t)=>({...b7(e),options:[e,t]}),A7=(e,t)=>({...O7(e),options:[e,t]});function M7(e){const t=D7(e),r=ve.forwardRef((n,i)=>{const{children:o,...a}=n,u=ve.Children.toArray(o),c=u.find(q7);if(c){const d=c.props.children,f=u.map(h=>h===c?ve.Children.count(d)>1?ve.Children.only(null):ve.isValidElement(d)?d.props.children:null:h);return C.jsx(t,{...a,ref:i,children:ve.isValidElement(d)?ve.cloneElement(d,void 0,f):null})}return C.jsx(t,{...a,ref:i,children:o})});return r.displayName=`${e}.Slot`,r}function D7(e){const t=ve.forwardRef((r,n)=>{const{children:i,...o}=r;if(ve.isValidElement(i)){const a=L7(i),u=k7(o,i.props);return i.type!==ve.Fragment&&(u.ref=n?kq(n,a):a),ve.cloneElement(i,u)}return ve.Children.count(i)>1?ve.Children.only(null):null});return t.displayName=`${e}.SlotClone`,t}var j7=Symbol("radix.slottable");function q7(e){return ve.isValidElement(e)&&typeof e.type=="function"&&"__radixId"in e.type&&e.type.__radixId===j7}function k7(e,t){const r={...t};for(const n in t){const i=e[n],o=t[n];/^on[A-Z]/.test(n)?i&&o?r[n]=(...u)=>{const c=o(...u);return i(...u),c}:i&&(r[n]=i):n==="style"?r[n]={...i,...o}:n==="className"&&(r[n]=[i,o].filter(Boolean).join(" "))}return{...e,...r}}function L7(e){var n,i;let t=(n=Object.getOwnPropertyDescriptor(e.props,"ref"))==null?void 0:n.get,r=t&&"isReactWarning"in t&&t.isReactWarning;return r?e.ref:(t=(i=Object.getOwnPropertyDescriptor(e,"ref"))==null?void 0:i.get,r=t&&"isReactWarning"in t&&t.isReactWarning,r?e.props.ref:e.props.ref||e.ref)}var B7=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","select","span","svg","ul"],Oi=B7.reduce((e,t)=>{const r=M7(`Primitive.${t}`),n=ve.forwardRef((i,o)=>{const{asChild:a,...u}=i,c=a?r:t;return typeof window<"u"&&(window[Symbol.for("radix-ui")]=!0),C.jsx(c,{...u,ref:o})});return n.displayName=`Primitive.${t}`,{...e,[t]:n}},{});function F7(e,t){e&&Yb.flushSync(()=>e.dispatchEvent(t))}var $7="Arrow",Yq=ve.forwardRef((e,t)=>{const{children:r,width:n=10,height:i=5,...o}=e;return C.jsx(Oi.svg,{...o,ref:t,width:n,height:i,viewBox:"0 0 30 10",preserveAspectRatio:"none",children:e.asChild?r:C.jsx("polygon",{points:"0,0 30,0 15,10"})})});Yq.displayName=$7;var z7=Yq;function Xc(e){const t=ve.useRef(e);return ve.useEffect(()=>{t.current=e}),ve.useMemo(()=>(...r)=>{var n;return(n=t.current)==null?void 0:n.call(t,...r)},[])}function H7(e){const[t,r]=ve.useState(void 0);return yi(()=>{if(e){r({width:e.offsetWidth,height:e.offsetHeight});const n=new ResizeObserver(i=>{if(!Array.isArray(i)||!i.length)return;const o=i[0];let a,u;if("borderBoxSize"in o){const c=o.borderBoxSize,d=Array.isArray(c)?c[0]:c;a=d.inlineSize,u=d.blockSize}else a=e.offsetWidth,u=e.offsetHeight;r({width:a,height:u})});return n.observe(e,{box:"border-box"}),()=>n.unobserve(e)}else r(void 0)},[e]),t}var Fx="Popper",[Xq,Zq]=qq(Fx),[U7,Jq]=Xq(Fx),Qq=e=>{const{__scopePopper:t,children:r}=e,[n,i]=ve.useState(null);return C.jsx(U7,{scope:t,anchor:n,onAnchorChange:i,children:r})};Qq.displayName=Fx;var e2="PopperAnchor",t2=ve.forwardRef((e,t)=>{const{__scopePopper:r,virtualRef:n,...i}=e,o=Jq(e2,r),a=ve.useRef(null),u=So(t,a),c=ve.useRef(null);return ve.useEffect(()=>{const d=c.current;c.current=(n==null?void 0:n.current)||a.current,d!==c.current&&o.onAnchorChange(c.current)}),n?null:C.jsx(Oi.div,{...i,ref:u})});t2.displayName=e2;var $x="PopperContent",[V7,W7]=Xq($x),r2=ve.forwardRef((e,t)=>{var V,K,ie,ne,ue,de;const{__scopePopper:r,side:n="bottom",sideOffset:i=0,align:o="center",alignOffset:a=0,arrowPadding:u=0,avoidCollisions:c=!0,collisionBoundary:d=[],collisionPadding:f=0,sticky:h="partial",hideWhenDetached:p=!1,updatePositionStrategy:v="optimized",onPlaced:m,...y}=e,x=Jq($x,r),[b,w]=ve.useState(null),S=So(t,we=>w(we)),[E,_]=ve.useState(null),R=H7(E),I=(R==null?void 0:R.width)??0,N=(R==null?void 0:R.height)??0,D=n+(o!=="center"?"-"+o:""),k=typeof f=="number"?f:{top:0,right:0,bottom:0,left:0,...f},B=Array.isArray(d)?d:[d],L=B.length>0,j={padding:k,boundary:B.filter(K7),altBoundary:L},{refs:T,floatingStyles:F,placement:$,isPositioned:W,middlewareData:Y}=S7({strategy:"fixed",placement:D,whileElementsMounted:(...we)=>p7(...we,{animationFrame:v==="always"}),elements:{reference:x.anchor},middleware:[C7({mainAxis:i+N,alignmentAxis:a}),c&&R7({mainAxis:!0,crossAxis:!1,limiter:h==="partial"?I7():void 0,...j}),c&&P7({...j}),N7({...j,apply:({elements:we,rects:Se,availableWidth:_e,availableHeight:he})=>{const{width:ae,height:Oe}=Se.reference,Ne=we.floating.style;Ne.setProperty("--radix-popper-available-width",`${_e}px`),Ne.setProperty("--radix-popper-available-height",`${he}px`),Ne.setProperty("--radix-popper-anchor-width",`${ae}px`),Ne.setProperty("--radix-popper-anchor-height",`${Oe}px`)}}),E&&A7({element:E,padding:u}),Y7({arrowWidth:I,arrowHeight:N}),p&&T7({strategy:"referenceHidden",...j})]}),[ee,H]=o2($),Q=Xc(m);yi(()=>{W&&(Q==null||Q())},[W,Q]);const ce=(V=Y.arrow)==null?void 0:V.x,se=(K=Y.arrow)==null?void 0:K.y,z=((ie=Y.arrow)==null?void 0:ie.centerOffset)!==0,[G,J]=ve.useState();return yi(()=>{b&&J(window.getComputedStyle(b).zIndex)},[b]),C.jsx("div",{ref:T.setFloating,"data-radix-popper-content-wrapper":"",style:{...F,transform:W?F.transform:"translate(0, -200%)",minWidth:"max-content",zIndex:G,"--radix-popper-transform-origin":[(ne=Y.transformOrigin)==null?void 0:ne.x,(ue=Y.transformOrigin)==null?void 0:ue.y].join(" "),...((de=Y.hide)==null?void 0:de.referenceHidden)&&{visibility:"hidden",pointerEvents:"none"}},dir:e.dir,children:C.jsx(V7,{scope:r,placedSide:ee,onArrowChange:_,arrowX:ce,arrowY:se,shouldHideArrow:z,children:C.jsx(Oi.div,{"data-side":ee,"data-align":H,...y,ref:S,style:{...y.style,animation:W?void 0:"none"}})})})});r2.displayName=$x;var n2="PopperArrow",G7={top:"bottom",right:"left",bottom:"top",left:"right"},i2=ve.forwardRef(function(t,r){const{__scopePopper:n,...i}=t,o=W7(n2,n),a=G7[o.placedSide];return C.jsx("span",{ref:o.onArrowChange,style:{position:"absolute",left:o.arrowX,top:o.arrowY,[a]:0,transformOrigin:{top:"",right:"0 0",bottom:"center 0",left:"100% 0"}[o.placedSide],transform:{top:"translateY(100%)",right:"translateY(50%) rotate(90deg) translateX(-50%)",bottom:"rotate(180deg)",left:"translateY(50%) rotate(-90deg) translateX(50%)"}[o.placedSide],visibility:o.shouldHideArrow?"hidden":void 0},children:C.jsx(z7,{...i,ref:r,style:{...i.style,display:"block"}})})});i2.displayName=n2;function K7(e){return e!==null}var Y7=e=>({name:"transformOrigin",options:e,fn(t){var x,b,w;const{placement:r,rects:n,middlewareData:i}=t,a=((x=i.arrow)==null?void 0:x.centerOffset)!==0,u=a?0:e.arrowWidth,c=a?0:e.arrowHeight,[d,f]=o2(r),h={start:"0%",center:"50%",end:"100%"}[f],p=(((b=i.arrow)==null?void 0:b.x)??0)+u/2,v=(((w=i.arrow)==null?void 0:w.y)??0)+c/2;let m="",y="";return d==="bottom"?(m=a?h:`${p}px`,y=`${-c}px`):d==="top"?(m=a?h:`${p}px`,y=`${n.floating.height+c}px`):d==="right"?(m=`${-c}px`,y=a?h:`${v}px`):d==="left"&&(m=`${n.floating.width+c}px`,y=a?h:`${v}px`),{data:{x:m,y}}}});function o2(e){const[t,r="center"]=e.split("-");return[t,r]}var X7=Qq,Z7=t2,J7=r2,Q7=i2,eX="Portal",a2=ve.forwardRef((e,t)=>{var u;const{container:r,...n}=e,[i,o]=ve.useState(!1);yi(()=>o(!0),[]);const a=r||i&&((u=globalThis==null?void 0:globalThis.document)==null?void 0:u.body);return a?aD.createPortal(C.jsx(Oi.div,{...n,ref:t}),a):null});a2.displayName=eX;function tX(e,t){return ve.useReducer((r,n)=>t[r][n]??r,e)}var zx=e=>{const{present:t,children:r}=e,n=rX(t),i=typeof r=="function"?r({present:n.isPresent}):ve.Children.only(r),o=So(n.ref,nX(i));return typeof r=="function"||n.isPresent?ve.cloneElement(i,{ref:o}):null};zx.displayName="Presence";function rX(e){const[t,r]=ve.useState(),n=ve.useRef(null),i=ve.useRef(e),o=ve.useRef("none"),a=e?"mounted":"unmounted",[u,c]=tX(a,{mounted:{UNMOUNT:"unmounted",ANIMATION_OUT:"unmountSuspended"},unmountSuspended:{MOUNT:"mounted",ANIMATION_END:"unmounted"},unmounted:{MOUNT:"mounted"}});return ve.useEffect(()=>{const d=wu(n.current);o.current=u==="mounted"?d:"none"},[u]),yi(()=>{const d=n.current,f=i.current;if(f!==e){const p=o.current,v=wu(d);e?c("MOUNT"):v==="none"||(d==null?void 0:d.display)==="none"?c("UNMOUNT"):c(f&&p!==v?"ANIMATION_OUT":"UNMOUNT"),i.current=e}},[e,c]),yi(()=>{if(t){let d;const f=t.ownerDocument.defaultView??window,h=v=>{const y=wu(n.current).includes(CSS.escape(v.animationName));if(v.target===t&&y&&(c("ANIMATION_END"),!i.current)){const x=t.style.animationFillMode;t.style.animationFillMode="forwards",d=f.setTimeout(()=>{t.style.animationFillMode==="forwards"&&(t.style.animationFillMode=x)})}},p=v=>{v.target===t&&(o.current=wu(n.current))};return t.addEventListener("animationstart",p),t.addEventListener("animationcancel",h),t.addEventListener("animationend",h),()=>{f.clearTimeout(d),t.removeEventListener("animationstart",p),t.removeEventListener("animationcancel",h),t.removeEventListener("animationend",h)}}else c("ANIMATION_END")},[t,c]),{isPresent:["mounted","unmountSuspended"].includes(u),ref:ve.useCallback(d=>{n.current=d?getComputedStyle(d):null,r(d)},[])}}function wu(e){return(e==null?void 0:e.animationName)||"none"}function nX(e){var n,i;let t=(n=Object.getOwnPropertyDescriptor(e.props,"ref"))==null?void 0:n.get,r=t&&"isReactWarning"in t&&t.isReactWarning;return r?e.ref:(t=(i=Object.getOwnPropertyDescriptor(e,"ref"))==null?void 0:i.get,r=t&&"isReactWarning"in t&&t.isReactWarning,r?e.props.ref:e.props.ref||e.ref)}function iX(e,t=globalThis==null?void 0:globalThis.document){const r=Xc(e);ve.useEffect(()=>{const n=i=>{i.key==="Escape"&&r(i)};return t.addEventListener("keydown",n,{capture:!0}),()=>t.removeEventListener("keydown",n,{capture:!0})},[r,t])}var oX="DismissableLayer",Ub="dismissableLayer.update",aX="dismissableLayer.pointerDownOutside",sX="dismissableLayer.focusOutside",GP,s2=ve.createContext({layers:new Set,layersWithOutsidePointerEventsDisabled:new Set,branches:new Set}),u2=ve.forwardRef((e,t)=>{const{disableOutsidePointerEvents:r=!1,onEscapeKeyDown:n,onPointerDownOutside:i,onFocusOutside:o,onInteractOutside:a,onDismiss:u,...c}=e,d=ve.useContext(s2),[f,h]=ve.useState(null),p=(f==null?void 0:f.ownerDocument)??(globalThis==null?void 0:globalThis.document),[,v]=ve.useState({}),m=So(t,I=>h(I)),y=Array.from(d.layers),[x]=[...d.layersWithOutsidePointerEventsDisabled].slice(-1),b=y.indexOf(x),w=f?y.indexOf(f):-1,S=d.layersWithOutsidePointerEventsDisabled.size>0,E=w>=b,_=lX(I=>{const N=I.target,D=[...d.branches].some(k=>k.contains(N));!E||D||(i==null||i(I),a==null||a(I),I.defaultPrevented||u==null||u())},p),R=fX(I=>{const N=I.target;[...d.branches].some(k=>k.contains(N))||(o==null||o(I),a==null||a(I),I.defaultPrevented||u==null||u())},p);return iX(I=>{w===d.layers.size-1&&(n==null||n(I),!I.defaultPrevented&&u&&(I.preventDefault(),u()))},p),ve.useEffect(()=>{if(f)return r&&(d.layersWithOutsidePointerEventsDisabled.size===0&&(GP=p.body.style.pointerEvents,p.body.style.pointerEvents="none"),d.layersWithOutsidePointerEventsDisabled.add(f)),d.layers.add(f),KP(),()=>{r&&d.layersWithOutsidePointerEventsDisabled.size===1&&(p.body.style.pointerEvents=GP)}},[f,p,r,d]),ve.useEffect(()=>()=>{f&&(d.layers.delete(f),d.layersWithOutsidePointerEventsDisabled.delete(f),KP())},[f,d]),ve.useEffect(()=>{const I=()=>v({});return document.addEventListener(Ub,I),()=>document.removeEventListener(Ub,I)},[]),C.jsx(Oi.div,{...c,ref:m,style:{pointerEvents:S?E?"auto":"none":void 0,...e.style},onFocusCapture:xr(e.onFocusCapture,R.onFocusCapture),onBlurCapture:xr(e.onBlurCapture,R.onBlurCapture),onPointerDownCapture:xr(e.onPointerDownCapture,_.onPointerDownCapture)})});u2.displayName=oX;var uX="DismissableLayerBranch",cX=ve.forwardRef((e,t)=>{const r=ve.useContext(s2),n=ve.useRef(null),i=So(t,n);return ve.useEffect(()=>{const o=n.current;if(o)return r.branches.add(o),()=>{r.branches.delete(o)}},[r.branches]),C.jsx(Oi.div,{...e,ref:i})});cX.displayName=uX;function lX(e,t=globalThis==null?void 0:globalThis.document){const r=Xc(e),n=ve.useRef(!1),i=ve.useRef(()=>{});return ve.useEffect(()=>{const o=u=>{if(u.target&&!n.current){let c=function(){c2(aX,r,d,{discrete:!0})};const d={originalEvent:u};u.pointerType==="touch"?(t.removeEventListener("click",i.current),i.current=c,t.addEventListener("click",i.current,{once:!0})):c()}else t.removeEventListener("click",i.current);n.current=!1},a=window.setTimeout(()=>{t.addEventListener("pointerdown",o)},0);return()=>{window.clearTimeout(a),t.removeEventListener("pointerdown",o),t.removeEventListener("click",i.current)}},[t,r]),{onPointerDownCapture:()=>n.current=!0}}function fX(e,t=globalThis==null?void 0:globalThis.document){const r=Xc(e),n=ve.useRef(!1);return ve.useEffect(()=>{const i=o=>{o.target&&!n.current&&c2(sX,r,{originalEvent:o},{discrete:!1})};return t.addEventListener("focusin",i),()=>t.removeEventListener("focusin",i)},[t,r]),{onFocusCapture:()=>n.current=!0,onBlurCapture:()=>n.current=!1}}function KP(){const e=new CustomEvent(Ub);document.dispatchEvent(e)}function c2(e,t,r,{discrete:n}){const i=r.originalEvent.target,o=new CustomEvent(e,{bubbles:!1,cancelable:!0,detail:r});t&&i.addEventListener(e,t,{once:!0}),n?F7(i,o):i.dispatchEvent(o)}var Am,Zc="HoverCard",[l2]=qq(Zc,[Zq]),Jc=Zq(),[dX,Qc]=l2(Zc),f2=e=>{const{__scopeHoverCard:t,children:r,open:n,defaultOpen:i,onOpenChange:o,openDelay:a=700,closeDelay:u=300}=e,c=Jc(t),d=ve.useRef(0),f=ve.useRef(0),h=ve.useRef(!1),p=ve.useRef(!1),[v,m]=x9({prop:n,defaultProp:i??!1,onChange:o,caller:Zc}),y=ve.useCallback(()=>{clearTimeout(f.current),d.current=window.setTimeout(()=>m(!0),a)},[a,m]),x=ve.useCallback(()=>{clearTimeout(d.current),!h.current&&!p.current&&(f.current=window.setTimeout(()=>m(!1),u))},[u,m]),b=ve.useCallback(()=>m(!1),[m]);return ve.useEffect(()=>()=>{clearTimeout(d.current),clearTimeout(f.current)},[]),C.jsx(dX,{scope:t,open:v,onOpenChange:m,onOpen:y,onClose:x,onDismiss:b,hasSelectionRef:h,isPointerDownOnContentRef:p,children:C.jsx(X7,{...c,children:r})})};f2.displayName=Zc;var d2="HoverCardTrigger",h2=ve.forwardRef((e,t)=>{const{__scopeHoverCard:r,...n}=e,i=Qc(d2,r),o=Jc(r);return C.jsx(Z7,{asChild:!0,...o,children:C.jsx(Oi.a,{"data-state":i.open?"open":"closed",...n,ref:t,onPointerEnter:xr(e.onPointerEnter,uc(i.onOpen)),onPointerLeave:xr(e.onPointerLeave,uc(i.onClose)),onFocus:xr(e.onFocus,i.onOpen),onBlur:xr(e.onBlur,i.onClose),onTouchStart:xr(e.onTouchStart,a=>a.preventDefault())})})});h2.displayName=d2;var Hx="HoverCardPortal",[hX,pX]=l2(Hx,{forceMount:void 0}),p2=e=>{const{__scopeHoverCard:t,forceMount:r,children:n,container:i}=e,o=Qc(Hx,t);return C.jsx(hX,{scope:t,forceMount:r,children:C.jsx(zx,{present:r||o.open,children:C.jsx(a2,{asChild:!0,container:i,children:n})})})};p2.displayName=Hx;var sc="HoverCardContent",v2=ve.forwardRef((e,t)=>{const r=pX(sc,e.__scopeHoverCard),{forceMount:n=r.forceMount,...i}=e,o=Qc(sc,e.__scopeHoverCard);return C.jsx(zx,{present:n||o.open,children:C.jsx(vX,{"data-state":o.open?"open":"closed",...i,onPointerEnter:xr(e.onPointerEnter,uc(o.onOpen)),onPointerLeave:xr(e.onPointerLeave,uc(o.onClose)),ref:t})})});v2.displayName=sc;var vX=ve.forwardRef((e,t)=>{const{__scopeHoverCard:r,onEscapeKeyDown:n,onPointerDownOutside:i,onFocusOutside:o,onInteractOutside:a,...u}=e,c=Qc(sc,r),d=Jc(r),f=ve.useRef(null),h=So(t,f),[p,v]=ve.useState(!1);return ve.useEffect(()=>{if(p){const m=document.body;return Am=m.style.userSelect||m.style.webkitUserSelect,m.style.userSelect="none",m.style.webkitUserSelect="none",()=>{m.style.userSelect=Am,m.style.webkitUserSelect=Am}}},[p]),ve.useEffect(()=>{if(f.current){const m=()=>{v(!1),c.isPointerDownOnContentRef.current=!1,setTimeout(()=>{var x;((x=document.getSelection())==null?void 0:x.toString())!==""&&(c.hasSelectionRef.current=!0)})};return document.addEventListener("pointerup",m),()=>{document.removeEventListener("pointerup",m),c.hasSelectionRef.current=!1,c.isPointerDownOnContentRef.current=!1}}},[c.isPointerDownOnContentRef,c.hasSelectionRef]),ve.useEffect(()=>{f.current&&yX(f.current).forEach(y=>y.setAttribute("tabindex","-1"))}),C.jsx(u2,{asChild:!0,disableOutsidePointerEvents:!1,onInteractOutside:a,onEscapeKeyDown:n,onPointerDownOutside:i,onFocusOutside:xr(o,m=>{m.preventDefault()}),onDismiss:c.onDismiss,children:C.jsx(J7,{...d,...u,onPointerDown:xr(u.onPointerDown,m=>{m.currentTarget.contains(m.target)&&v(!0),c.hasSelectionRef.current=!1,c.isPointerDownOnContentRef.current=!0}),ref:h,style:{...u.style,userSelect:p?"text":void 0,WebkitUserSelect:p?"text":void 0,"--radix-hover-card-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-hover-card-content-available-width":"var(--radix-popper-available-width)","--radix-hover-card-content-available-height":"var(--radix-popper-available-height)","--radix-hover-card-trigger-width":"var(--radix-popper-anchor-width)","--radix-hover-card-trigger-height":"var(--radix-popper-anchor-height)"}})})}),gX="HoverCardArrow",mX=ve.forwardRef((e,t)=>{const{__scopeHoverCard:r,...n}=e,i=Jc(r);return C.jsx(Q7,{...i,...n,ref:t})});mX.displayName=gX;function uc(e){return t=>t.pointerType==="touch"?void 0:e()}function yX(e){const t=[],r=document.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,{acceptNode:n=>n.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP});for(;r.nextNode();)t.push(r.currentNode);return t}var Ux=f2,Vx=h2,jr=p2,qr=v2;const bX=({item:e,depth:t})=>{const[r,n]=A.useState(!1),i=Z.useAppSelector(Z.selectPrivileges),o=Z.populateShallow(e.includes,i);return C.jsxs("div",{className:"py-1 text-xs text-white",children:[C.jsxs("div",{className:"flex items-center",children:[C.jsx("button",{className:"-ml-1",onClick:a=>{a.stopPropagation(),n(!r)},children:C.jsx(ye.FdRight,{className:Ve("h-4 w-4",{"tranform rotate-90":r})})})," ",C.jsx("div",{children:e.privilege})]}),C.jsx("div",{className:"border-l pl-2",style:{marginLeft:t?t*4:3},children:r&&C.jsx(g2,{depth:t+1,data:o})})]})},g2=({data:e,depth:t=0})=>e.map(r=>r.includes.length?C.jsx(bX,{item:r,depth:t},r.id):C.jsx("div",{className:Ve("py-1 text-xs text-white",{}),children:r.privilege},r.id)),Bt=()=>document.querySelector(`.${sD.ROLES_EDITOR_SCOPE_CLASS}`)||document.body,el=({container:e,...t})=>C.jsx(Te.Portal,{...t,container:e||Bt()}),YP=Ux,XP=Vx,ZP=({privilege:e,selectedPrivilege:t,onSelect:r,isGuest:n=!1})=>{const i=Z.useAppDispatch(),o=Z.useAppSelector(Z.selectPrivileges),a=Z.populateShallow(e.includes,o),[u,c]=A.useState(!1),[d,f]=A.useState(e.privilege),[h,p]=A.useState(null),v=Te.useOutsideClick(()=>{u&&x()});Te.useDidMountEffect(()=>{e.privilege!==d&&f(e.privilege)},[e.privilege]);function m(){c(!0),p(null)}function y(){c(!1),f(e.privilege)}function x(){p(null);try{Te.validateName(d);const S=Z.rename(d,e.id,o);i(Z.updatePrivileges(S)),c(!1)}catch(S){p(S.message)}}const b=async S=>{S.stopPropagation();const{confirmed:E}=await i(Z.openModal({title:"Delete Privilege",type:Te.ModalType.CONFIRM,color:Te.ModalColor.DANGER,message:"Are you sure you want to remove this Privilege?",icon:"FdWarningDanger"})).unwrap();if(E){const _=Z.remove(e.id,o);if((t==null?void 0:t.id)!==e.id){i(Z.updatePrivileges(_));return}const R=Object.keys(_).filter(I=>_[I].privilege!=="guest");if(R.length===0)r(null);else{const I=Object.keys(o).filter(B=>o[B].privilege!=="guest"),N=I.indexOf(e.id),D=Math.max(0,N-1),k=I[D];N===0?r(_[R[0]]):_[k]?r(_[k]):r(_[R[0]])}i(Z.updatePrivileges(_))}},w=A.useMemo(()=>e.resources.some(S=>S.exists===!1),[e]);return C.jsxs(YP,{openDelay:0,closeDelay:0,children:[C.jsx(XP,{asChild:!0,children:C.jsxs("div",{className:Ve("rounded border bg-grey-300 p-2",{"border-grey-100":(t==null?void 0:t.id)!==e.id,"border-primary-dark":(t==null?void 0:t.id)===e.id,"border-red-400":w&&(t==null?void 0:t.id)!==e.id}),role:"button","data-cy":"privilegeCard",onClick:()=>{r(e)},ref:v,children:[C.jsxs("div",{className:"flex items-center justify-between",children:[C.jsxs("div",{className:"flex flex-1 items-center text-white",children:[C.jsx("span",{className:"mr-4",children:n?C.jsx(ye.FdGuest,{className:"h-6 w-6"}):C.jsx(ye.FdGroup,{className:"h-6 w-6"})}),u?C.jsxs("div",{className:"relative h-6 flex-1 mr-2",children:[C.jsx("input",{autoFocus:!0,onKeyDown:S=>{S.key==="Enter"&&x(),S.key==="Escape"&&y()},type:"text",className:Ve("absolute inset-0 h-6 min-w-0 rounded border border-grey-200 bg-grey-300 p-1 text-xs focus:outline-none",{"border-b border-red-400 rounded-b-none":h,"focus:border-primary-dark":!h}),value:d,onChange:S=>f(S.target.value)}),h&&C.jsx("p",{className:"absolute top-5 mt-1 w-full rounded rounded-t-none bg-red-400 p-1 text-xs text-white shadow-md",children:h})]}):C.jsx("span",{className:"inline-block grow overflow-hidden truncate whitespace-nowrap text-xs font-bold",children:d})]}),n?C.jsx("div",{className:"flex items-center justify-center",children:C.jsxs(YP,{openDelay:0,closeDelay:0,children:[C.jsx(XP,{asChild:!0,children:C.jsx("span",{children:C.jsx(ye.FdInfoBold,{className:"h-4 w-4 text-grey-50"})})}),C.jsx(jr,{container:Bt(),children:C.jsx(qr,{style:{zIndex:50},avoidCollisions:!0,side:"top",className:"max-w-xs rounded bg-primary-light py-2 text-sm font-semibold text-primary",children:C.jsx("div",{className:"space-y-1 px-2",children:C.jsxs("div",{className:"flex items-start text-s",children:[C.jsx(ye.FdBulb,{className:"mr-2 mt-0.5 h-4 w-4 flex-shrink-0"}),C.jsx("p",{children:"the guest privilege must be used to indicate resources accessible without any permission required (e.g. an authenticate function)"})]})})})})]})}):C.jsx("div",{className:"flex items-center space-x-2",children:u?C.jsxs(C.Fragment,{children:[C.jsx("button",{className:"rounded p-1 hover:bg-primary-hover hover:text-white",onClick:y,children:C.jsx("span",{children:C.jsx(ye.FdClose,{className:"h-4 w-4 text-grey-50"})})}),C.jsx("button",{className:"rounded p-1 hover:bg-primary-hover hover:text-white",onClick:x,children:C.jsx("span",{children:C.jsx(ye.FdCheckCircle,{className:"h-4 w-4 text-grey-50"})})})]}):C.jsxs(C.Fragment,{children:[C.jsx("button",{className:"rounded p-1 hover:bg-primary-hover hover:text-white",onClick:m,children:C.jsx("span",{children:C.jsx(ye.FdPen,{className:"h-4 w-4 text-grey-50"})})}),C.jsx("button",{className:"rounded p-1 hover:bg-primary-hover hover:text-white",onClick:b,children:C.jsx("span",{children:C.jsx(ye.FdTrash,{className:"h-4 w-4 text-grey-50"})})})]})})]}),a.length?C.jsx("div",{className:"ml-[43px]",children:C.jsx(g2,{data:a})}):null]})}),C.jsx(jr,{container:Bt(),children:C.jsxs(qr,{hidden:!w,style:{zIndex:50},avoidCollisions:!0,side:"top",className:"text-red-500 mb-1 flex max-w-xs items-center gap-x-1 rounded bg-negative-200 px-2 py-2 text-s font-semibold",children:[C.jsx(ye.FdBulb,{className:"m-0.5 h-4 w-4 flex-shrink-0"}),C.jsx("p",{children:"This privilege uses non-existing resources"})]})})]})},xX=({privileges:e,selectPrivilege:t,selectedPrivilege:r})=>{const n=Z.useAppSelector(Z.selectGuestPrivilege),i=Z.useAppSelector(Z.selectCatalog),o=A.useMemo(()=>{if(i===null||!n)return n;const a=Dq({guest:n},Object.values((i==null?void 0:i.dataClasses)??{}));return jq(a,i).guest},[e,i]);return C.jsxs("div",{className:"flex flex-1 flex-col gap-y-4 overflow-auto p-4 pb-10 pt-1",children:[o?C.jsx(ZP,{privilege:o,onSelect:t,selectedPrivilege:r,isGuest:!0}):null,Object.entries(e).length?Object.entries(e).filter(([,a])=>a.privilege!=="guest").sort(([,a],[,u])=>Te.localeCompare(a.privilege,u.privilege)).map(([a,u])=>C.jsx(ZP,{privilege:u,onSelect:t,selectedPrivilege:r},a)):C.jsx("div",{className:"flex h-full items-center justify-center",children:C.jsx("div",{className:"flex flex-1 items-center justify-center bg-grey-800",children:C.jsxs("div",{className:"flex flex-col items-center justify-center space-y-4 text-grey-200",children:[C.jsx(ye.FdInfoBold,{className:"h-10 w-10"}),C.jsx("div",{className:"font-semibold",children:"There are no privileges"}),C.jsxs("div",{className:"flex items-center text-sm",children:["Create a new Privilege by clicking on the"," ",C.jsx(ye.FdPlus,{className:"ml-2 inline h-4 w-4 text-white"})]})]})})})]})};var _u={exports:{}},Eu={exports:{}},Ke={};/** @license React v16.13.1
|
|
6
|
+
*/var cC;function uG(){return cC||(cC=1,(function(e){(function(){var t={}.hasOwnProperty;function r(){for(var i="",a=0;a<arguments.length;a++){var s=arguments[a];s&&(i=o(i,n(s)))}return i}function n(i){if(typeof i=="string"||typeof i=="number")return i;if(typeof i!="object")return"";if(Array.isArray(i))return r.apply(null,i);if(i.toString!==Object.prototype.toString&&!i.toString.toString().includes("[native code]"))return i.toString();var a="";for(var s in i)t.call(i,s)&&i[s]&&(a=o(a,s));return a}function o(i,a){return a?i?i+" "+a:i+a:i}e.exports?(r.default=r,e.exports=r):window.classNames=r})()})(lC)),lC.exports}var dG=uG();const ka=YL(dG),fG=cG({extend:{classGroups:{"font-size":["text-xxs","text-xs","text-s","text-sm","text-base","text-lg","text-xl","text-2xl","text-3xl","text-4xl","text-5xl","text-6xl","text-7xl","text-8xl","text-9xl"],"text-color":["text-body","text-muted","text-inactive-text","text-button-text","text-positive-text","text-negative-text","text-negative","text-warning-text","text-input-text","text-select-text","text-input-message-text","text-placeholder"]}}});function xe(...e){return fG(ka(e))}const gl={sm:{checkbox:"size-4",hoverSquare:"size-2.5",text:"text-xs",spacing:"gap-1",icon:"size-3.25"},md:{checkbox:"size-5",hoverSquare:"size-3.5",text:"text-sm",spacing:"gap-1.5",icon:"size-4"},lg:{checkbox:"size-6",hoverSquare:"size-4",text:"text-base",spacing:"gap-2",icon:"size-5"}},an={primary:{checked:"bg-primary border-primary",unchecked:"border border-body bg-transparent",checkedHover:"hover:bg-primary-hover hover:border-primary-hover",hoverSquare:"bg-primary-hover",focus:"focus:ring-primary",label:"text-body"},positive:{checked:"bg-positive border-positive",unchecked:"border border-positive bg-transparent",checkedHover:"hover:bg-positive-hover hover:border-positive-hover",hoverSquare:"bg-positive-hover",focus:"focus:ring-positive",label:"text-positive"},warning:{checked:"bg-warning border-warning",unchecked:"border border-warning bg-transparent",checkedHover:"hover:bg-warning-hover hover:border-warning-hover",hoverSquare:"bg-warning-hover",focus:"focus:ring-warning",label:"text-warning"},negative:{checked:"bg-negative border-negative",unchecked:"border border-negative bg-transparent",checkedHover:"hover:bg-negative-hover hover:border-negative-hover",hoverSquare:"bg-negative-hover",focus:"focus:ring-negative",label:"text-negative"}},pG=`
|
|
7
|
+
appearance-none border rounded transition-all duration-200
|
|
8
|
+
focus:ring-2 focus:ring-offset-2 focus:outline-hidden
|
|
9
|
+
relative
|
|
10
|
+
`,hG=(e,t,r)=>{const{isChecked:n,isIndeterminate:o,isDisabled:i,isInvalid:a}=r,s=n||o;return xe(pG,gl[e].checkbox,{"cursor-pointer":!i},a?{[an.negative.checked]:s,[an.negative.unchecked]:!s,[an.negative.checkedHover]:!i&&s,[an.negative.focus]:!i,"border-input-disable":i}:{[an[t].checked]:s&&!i,[an[t].unchecked]:!s&&!i,[an[t].checkedHover]:!i&&s,[an[t].focus]:!i,"border-input-disable":i,"bg-input-disable text-inactive-text":i&&s})},vG=(e,t,r)=>{const{isDisabled:n,isInvalid:o}=r;return xe(gl[e].text,o?{[an.negative.label]:o}:{"text-input-disable":n,[an[t].label]:!n,"cursor-pointer":!n})},gG=e=>xe("inline-flex items-center ws-group",gl[e].spacing),mG=(e,t,r)=>xe("center-absolute rounded-xs transition-all duration-200 opacity-0 ws-checkbox-hover-target",gl[e].hoverSquare,{[an.negative.hoverSquare]:r,[an[t].hoverSquare]:!r}),bG=e=>`${gl[e].icon}`,yG=e=>O.jsx("svg",{className:`absolute inset-0 ${e.className}`,fill:"none",viewBox:"0 0 24 24","aria-hidden":"true",focusable:"false",xmlns:"http://www.w3.org/2000/svg",...e,children:O.jsx("circle",{cx:"12",cy:"12",r:"10",stroke:"currentColor",strokeWidth:"2",fill:"none"})}),or=R.forwardRef(({label:e,isDisabled:t=!1,isInvalid:r=!1,isRequired:n=!1,size:o="md",color:i="primary",onChange:a,onFocus:s,onBlur:c,value:u,defaultValue:d,name:f,id:h,...v},b)=>{const[g,m]=R.useState(d),x=u===!0||g===!0,w=u===null,E=x||w,S={isChecked:x,isIndeterminate:w,isDisabled:t,isInvalid:r},_=hG(o,i,S),C=vG(o,i,S),N=gG(o),P=mG(o,i,r),A=bG(o);return O.jsxs("label",{"data-qui":"Checkbox",className:N,children:[O.jsxs("div",{className:_,children:[O.jsx("input",{ref:b,type:"checkbox",className:"sr-only",checked:x,disabled:t,required:n,onChange:j=>{u===void 0&&m(j.target.checked),a==null||a(j)},onFocus:s,onBlur:c,name:f,id:h,...v}),E&&O.jsx("div",{className:"center-absolute",children:w?O.jsx(yG,{className:A}):O.jsx(y8,{className:A})}),!E&&!t&&O.jsx("div",{className:P})]}),e&&O.jsxs("span",{className:C,children:[e,n&&O.jsx("span",{className:"text-negative ml-1",children:"*"})]})]})});or.displayName="Checkbox";const ml={sm:{container:"gap-2",radio:"size-3",label:"text-xs",dot:"size-2",hoverDot:"size-1.5"},md:{container:"gap-2.5",radio:"size-4",label:"text-sm",dot:"size-2.5",hoverDot:"size-2"},lg:{container:"gap-3",radio:"size-6",label:"text-base",dot:"size-4",hoverDot:"size-3"}},rl={primary:{radio:"border-body-light group-hover:border-body",radioInvalid:"border-negative",dot:"bg-primary group-hover:bg-primary-hover",hoverDot:"bg-primary-hover",label:"text-body"},positive:{radio:"border-positive group-hover:border-positive-text",radioInvalid:"border-negative",dot:"bg-positive group-hover:bg-positive-hover",hoverDot:"bg-positive-bg",label:"text-positive-text"},warning:{radio:"border-warning group-hover:border-warning-text",radioInvalid:"border-negative",dot:"bg-warning group-hover:bg-warning-hover",hoverDot:"bg-warning-bg",label:"text-warning-text"},negative:{radio:"border-negative group-hover:border-negative-text",radioInvalid:"border-negative",dot:"bg-negative group-hover:bg-negative-hover",hoverDot:"bg-negative-bg",label:"text-negative"}},xG=`
|
|
11
|
+
relative rounded-full border transition-all duration-200 ease-in-out bg-transparent
|
|
12
|
+
focus:outline-hidden focus:ring-2 focus:ring-offset-0
|
|
13
|
+
cursor-pointer peer
|
|
14
|
+
`,wG=(e,t,r)=>{const{isDisabled:n,isInvalid:o}=r;return ka(xG,ml[e].radio,o?rl[t].radioInvalid:{[rl[t].radio]:!n,"cursor-not-allowed opacity-60":n})},_G=(e,t,r)=>{const{checked:n,isDisabled:o,isInvalid:i}=r;return ka("center-absolute rounded-full transition-all duration-200 ease-in-out",ml[e].dot,i?"bg-negative":{[rl[t].dot]:!o,"border-neutral":o,"opacity-0 scale-0":!n,"opacity-100 scale-100":n&&!o})},EG=(e,t,r)=>ka("center-absolute rounded-full transition-all duration-200 opacity-0 group-hover:opacity-100",ml[e].hoverDot,{[rl[t].hoverDot]:!r,"bg-negative-bg":r}),SG=(e,t,r)=>{const{isDisabled:n,isInvalid:o}=r;return ka("cursor-pointer select-none transition-colors duration-200",ml[e].label,o?{"text-negative":o}:{[rl[t].label]:!n,"text-muted":n})},OG=(e,t)=>ka("inline-flex items-center group",ml[e].container,t),CG=R.createContext(null),RG=()=>{const e=R.useContext(CG);if(!e)throw new Error("Radio.Item must be used within Radio.Group");return e},NG=R.forwardRef(({value:e,label:t,size:r,color:n,isDisabled:o,isInvalid:i,isRequired:a,className:s,...c},u)=>{const d=RG(),f=r??d.size,h=n??d.color,v=o??d.isDisabled,b=i??d.isInvalid,g=a??d.isRequired,m=d.value===e,x={checked:m,isDisabled:v,isInvalid:b},w=wG(f,h,x),E=_G(f,h,x),S=EG(f,h,b),_=SG(f,h,x),C=OG(f,s),N=()=>{v||d.onChange(e)};return O.jsxs("label",{"data-qui":"RadioItem",className:C,children:[O.jsxs("div",{className:"relative",children:[O.jsx("input",{ref:u,type:"radio",value:e,checked:m,disabled:v,required:g,"aria-invalid":b,"aria-label":t?void 0:c["aria-label"],name:d.name,onChange:N,className:"sr-only",...c}),O.jsxs("div",{className:w,children:[O.jsx("div",{className:E}),!m&&!v&&O.jsx("div",{className:S})]})]}),t&&O.jsxs("span",{className:_,children:[t,g&&O.jsx("span",{className:"text-negative ml-1",children:"*"})]})]})});NG.displayName="RadioItem";const KL={sm:{container:"h-4.5 p-1 rounded",text:"text-xxs"},md:{container:"h-6 p-1 rounded",text:"text-s"},lg:{container:"h-7 p-1 rounded",text:"text-sm"},xl:{container:"h-7.5 p-1 rounded",text:"text-lg"}},IG={primary:{bg:{solid:"bg-primary",outline:"bg-transparent",ghost:"bg-transparent"},text:{solid:"text-button-text",outline:"text-primary",ghost:"text-primary"},border:{solid:"border-primary",outline:"border-primary",ghost:"border-transparent"},hover:{solid:"hover:bg-primary-hover hover:border-primary-hover",outline:"hover:border-black hover:text-primary-hover",ghost:"hover:bg-primary-hover hover:text-body"}},white:{bg:{solid:"bg-white",outline:"bg-transparent",ghost:"bg-transparent"},text:{solid:"text-primary",outline:"text-body",ghost:"text-body"},border:{solid:"border-white",outline:"border-white",ghost:"border-transparent"},hover:{solid:"hover:bg-canvas-subtle hover:border-canvas-subtle",outline:"hover:border-canvas hover:text-canvas",ghost:"hover:bg-primary-hover hover:text-body"}},positive:{bg:{solid:"bg-positive",outline:"bg-transparent",ghost:"bg-transparent"},text:{solid:"text-button-text",outline:"text-positive-text",ghost:"text-positive-text"},border:{solid:"border-positive",outline:"border-positive",ghost:"border-transparent"},hover:{solid:"hover:bg-positive-hover hover:border-positive-hover",outline:"hover:border-positive-hover hover:text-positive-hover",ghost:"hover:bg-positive-hover hover:text-body"}},warning:{bg:{solid:"bg-warning",outline:"bg-transparent",ghost:"bg-transparent"},text:{solid:"text-button-text",outline:"text-warning-text",ghost:"text-warning-text"},border:{solid:"border-warning",outline:"border-warning",ghost:"border-transparent"},hover:{solid:"hover:bg-warning-hover hover:border-warning-hover",outline:"hover:border-warning-hover hover:text-warning-hover",ghost:"hover:bg-warning-hover hover:text-body"}},negative:{bg:{solid:"bg-negative",outline:"bg-transparent",ghost:"bg-transparent"},text:{solid:"text-button-text",outline:"text-negative",ghost:"text-negative"},border:{solid:"border-negative",outline:"border-negative",ghost:"border-transparent"},hover:{solid:"hover:bg-negative-hover hover:border-negative-hover",outline:"hover:border-negative-hover hover:text-negative-hover",ghost:"hover:bg-negative-hover hover:text-body"}}},PG=(e,t,r,n)=>{const o=KL[e],i=IG[r],a=xe("inline-flex items-center justify-center font-medium transition-colors duration-200 focus:outline-hidden border",{"cursor-pointer":!n},o.container);return n?xe(a,"text-inactive-text",{"border-panel":t!=="ghost"&&t==="solid","border-panel-subtle":t==="outline","bg-panel":t==="solid","bg-transparent ":t==="outline"||t==="ghost","border-transparent":t==="ghost"}):xe(a,i.bg[t],i.text[t],i.hover[t],i.border[t])},TG=e=>xe("flex items-center justify-center gap-1",KL[e].text),AG=R.forwardRef(({size:e="md",variant:t="solid",color:r="primary",className:n,children:o,disabled:i,...a},s)=>O.jsx("button",{"data-qui":"Button",ref:s,type:"button",className:xe(PG(e,t,r,i),TG(e),n),disabled:i,...a,children:o}));AG.displayName="Button";const XL=R.createContext(null),bl=()=>{const e=R.useContext(XL);if(!e)throw new Error("Input components must be used within Input.Root");return e},Da={sm:{group:"h-5 min-h-fit",input:"text-2.25",message:"text-2.25 p-1.5",icon:"text-sm"},md:{group:"h-6 min-h-fit",input:"text-xs",message:"text-xs p-2",icon:"text-base"},lg:{group:"h-7 min-h-fit",input:"text-s",message:"text-s p-2.5",icon:"text-lg"}},Nn={primary:{border:"border border-input-border focus-within:border-input-focus-border",borderInvalid:"ring-input-error-border",borderMessage:"ring-input-focus-border",text:"text-input-text",placeholder:"placeholder:text-input-placeholder",messageText:"text-input-message-text",messageBackground:"bg-input-message-bg",icon:"text-input-text",action:"text-input-text",actionHover:"hover:text-body hover:bg-primary-hover"},positive:{border:"border border-input-border focus-within:border-positive",borderInvalid:"ring-input-error-border",borderMessage:"ring-positive",text:"text-input-text",placeholder:"placeholder:text-input-placeholder",messageText:"text-positive-dark",messageBackground:"bg-positive-light",icon:"text-positive-text",action:"text-input-text",actionHover:"hover:text-body hover:bg-primary-hover"},warning:{border:"border border-input-border focus-within:border-input-warning-border",borderInvalid:"ring-input-error-border",borderMessage:"ring-input-warning-border",text:"text-input-text",placeholder:"placeholder:text-input-placeholder",messageText:"text-warning-dark",messageBackground:"bg-input-warning-bg",icon:"text-warning-text",action:"text-input-text",actionHover:"hover:text-body hover:bg-primary-hover"},negative:{border:"border border-input-border focus-within:border-input-error-border",borderInvalid:"ring-input-error-border",borderMessage:"ring-input-error-border",text:"text-input-text",placeholder:"placeholder:text-input-placeholder",messageText:"text-negative-dark",messageBackground:"bg-input-error-bg",icon:"text-negative",action:"text-input-text",actionHover:"hover:text-body hover:bg-primary-hover"}},kG=()=>xe("flex flex-col"),DG=({size:e,color:t,isDisabled:r,isReadOnly:n,hasMessage:o,hasArea:i})=>xe("bg-input-bg flex gap-1 relative px-1 transition-all duration-200 ease-in-out only:rounded first:rounded-t last:rounded-b",Nn[t].text,o?Nn[t].borderMessage:!n&&Nn[t].border,Da[e].group,{"ring-1":o,"opacity-60":r,"items-center":!i}),MG=({size:e,color:t})=>xe("bg-transparent ring-0 w-full","focus:outline-hidden",[Da[e].input],Nn[t].placeholder),uC=({size:e,color:t})=>xe("bg-transparent ring-0 w-full h-fit resize-none py-0.5","focus:outline-hidden",Da[e].input,Nn[t].placeholder),jG=({size:e,color:t,isDisabled:r,isAction:n})=>xe("transition-colors duration-200 rounded max-h-full h-fit",Da[e].icon,e==="sm"?"m-px":"m-0.5",r?"text-muted opacity-60 pointer-events-none":n?Nn[t].action:Nn[t].icon,{"cursor-pointer p-0.5":n&&!r,[Nn[t].actionHover]:n&&!r,"pointer-events-none":!n}),LG=({size:e,color:t,isDisabled:r})=>xe("flex items-start gap-x-2 ring-1 ring-t-0 only:rounded first:rounded-t last:rounded-b",r?"text-muted":Nn[t].messageText,Nn[t].borderMessage,Nn[t].messageBackground,Da[e].message,{"opacity-60":r}),qG=({size:e})=>xe(Da[e].icon);function Wu(e){var t=typeof e;return e!=null&&(t=="object"||t=="function")}var zG=typeof global=="object"&&global&&global.Object===Object&&global,BG=typeof self=="object"&&self&&self.Object===Object&&self,ZL=zG||BG||Function("return this")(),ch=function(){return ZL.Date.now()},FG=/\s/;function $G(e){for(var t=e.length;t--&&FG.test(e.charAt(t)););return t}var VG=/^\s+/;function HG(e){return e&&e.slice(0,$G(e)+1).replace(VG,"")}var Uu=ZL.Symbol,JL=Object.prototype,WG=JL.hasOwnProperty,UG=JL.toString,vs=Uu?Uu.toStringTag:void 0;function GG(e){var t=WG.call(e,vs),r=e[vs];try{e[vs]=void 0;var n=!0}catch{}var o=UG.call(e);return n&&(t?e[vs]=r:delete e[vs]),o}var YG=Object.prototype,KG=YG.toString;function XG(e){return KG.call(e)}var ZG="[object Null]",JG="[object Undefined]",dC=Uu?Uu.toStringTag:void 0;function QG(e){return e==null?e===void 0?JG:ZG:dC&&dC in Object(e)?GG(e):XG(e)}function e7(e){return e!=null&&typeof e=="object"}var t7="[object Symbol]";function r7(e){return typeof e=="symbol"||e7(e)&&QG(e)==t7}var fC=NaN,n7=/^[-+]0x[0-9a-f]+$/i,o7=/^0b[01]+$/i,i7=/^0o[0-7]+$/i,a7=parseInt;function pC(e){if(typeof e=="number")return e;if(r7(e))return fC;if(Wu(e)){var t=typeof e.valueOf=="function"?e.valueOf():e;e=Wu(t)?t+"":t}if(typeof e!="string")return e===0?e:+e;e=HG(e);var r=o7.test(e);return r||i7.test(e)?a7(e.slice(2),r?2:8):n7.test(e)?fC:+e}var s7="Expected a function",l7=Math.max,c7=Math.min;function Ou(e,t,r){var n,o,i,a,s,c,u=0,d=!1,f=!1,h=!0;if(typeof e!="function")throw new TypeError(s7);t=pC(t)||0,Wu(r)&&(d=!!r.leading,f="maxWait"in r,i=f?l7(pC(r.maxWait)||0,t):i,h="trailing"in r?!!r.trailing:h);function v(C){var N=n,P=o;return n=o=void 0,u=C,a=e.apply(P,N),a}function b(C){return u=C,s=setTimeout(x,t),d?v(C):a}function g(C){var N=C-c,P=C-u,A=t-N;return f?c7(A,i-P):A}function m(C){var N=C-c,P=C-u;return c===void 0||N>=t||N<0||f&&P>=i}function x(){var C=ch();if(m(C))return w(C);s=setTimeout(x,g(C))}function w(C){return s=void 0,h&&n?v(C):(n=o=void 0,a)}function E(){s!==void 0&&clearTimeout(s),u=0,n=c=o=s=void 0}function S(){return s===void 0?a:w(ch())}function _(){var C=ch(),N=m(C);if(n=arguments,o=this,c=C,N){if(s===void 0)return b(c);if(f)return clearTimeout(s),s=setTimeout(x,t),v(c)}return s===void 0&&(s=setTimeout(x,t)),a}return _.cancel=E,_.flush=S,_}var u7="Expected a function";function d7(e,t,r){var n=!0,o=!0;if(typeof e!="function")throw new TypeError(u7);return Wu(r)&&(n="leading"in r?!!r.leading:n,o="trailing"in r?!!r.trailing:o),Ou(e,t,{leading:n,maxWait:t,trailing:o})}var ca=function(){return ca=Object.assign||function(e){for(var t,r=1,n=arguments.length;r<n;r++){t=arguments[r];for(var o in t)Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o])}return e},ca.apply(this,arguments)};function QL(e){return!e||!e.ownerDocument||!e.ownerDocument.defaultView?window:e.ownerDocument.defaultView}function eq(e){return!e||!e.ownerDocument?document:e.ownerDocument}var tq=function(e){var t={},r=Array.prototype.reduce.call(e,function(n,o){var i=o.name.match(/data-simplebar-(.+)/);if(i){var a=i[1].replace(/\W+(.)/g,function(s,c){return c.toUpperCase()});switch(o.value){case"true":n[a]=!0;break;case"false":n[a]=!1;break;case void 0:n[a]=!0;break;default:n[a]=o.value}}return n},t);return r};function rq(e,t){var r;e&&(r=e.classList).add.apply(r,t.split(" "))}function nq(e,t){e&&t.split(" ").forEach(function(r){e.classList.remove(r)})}function oq(e){return".".concat(e.split(" ").join("."))}var G_=!!(typeof window<"u"&&window.document&&window.document.createElement),f7=Object.freeze({__proto__:null,addClasses:rq,canUseDOM:G_,classNamesToQuery:oq,getElementDocument:eq,getElementWindow:QL,getOptions:tq,removeClasses:nq}),sa=null,hC=null;G_&&window.addEventListener("resize",function(){hC!==window.devicePixelRatio&&(hC=window.devicePixelRatio,sa=null)});function vC(){if(sa===null){if(typeof document>"u")return sa=0,sa;var e=document.body,t=document.createElement("div");t.classList.add("simplebar-hide-scrollbar"),e.appendChild(t);var r=t.getBoundingClientRect().right;e.removeChild(t),sa=r}return sa}var Lo=QL,uh=eq,p7=tq,qo=rq,zo=nq,Ir=oq,gs=(function(){function e(t,r){r===void 0&&(r={});var n=this;if(this.removePreventClickId=null,this.minScrollbarWidth=20,this.stopScrollDelay=175,this.isScrolling=!1,this.isMouseEntering=!1,this.isDragging=!1,this.scrollXTicking=!1,this.scrollYTicking=!1,this.wrapperEl=null,this.contentWrapperEl=null,this.contentEl=null,this.offsetEl=null,this.maskEl=null,this.placeholderEl=null,this.heightAutoObserverWrapperEl=null,this.heightAutoObserverEl=null,this.rtlHelpers=null,this.scrollbarWidth=0,this.resizeObserver=null,this.mutationObserver=null,this.elStyles=null,this.isRtl=null,this.mouseX=0,this.mouseY=0,this.onMouseMove=function(){},this.onWindowResize=function(){},this.onStopScrolling=function(){},this.onMouseEntered=function(){},this.onScroll=function(){var o=Lo(n.el);n.scrollXTicking||(o.requestAnimationFrame(n.scrollX),n.scrollXTicking=!0),n.scrollYTicking||(o.requestAnimationFrame(n.scrollY),n.scrollYTicking=!0),n.isScrolling||(n.isScrolling=!0,qo(n.el,n.classNames.scrolling)),n.showScrollbar("x"),n.showScrollbar("y"),n.onStopScrolling()},this.scrollX=function(){n.axis.x.isOverflowing&&n.positionScrollbar("x"),n.scrollXTicking=!1},this.scrollY=function(){n.axis.y.isOverflowing&&n.positionScrollbar("y"),n.scrollYTicking=!1},this._onStopScrolling=function(){zo(n.el,n.classNames.scrolling),n.options.autoHide&&(n.hideScrollbar("x"),n.hideScrollbar("y")),n.isScrolling=!1},this.onMouseEnter=function(){n.isMouseEntering||(qo(n.el,n.classNames.mouseEntered),n.showScrollbar("x"),n.showScrollbar("y"),n.isMouseEntering=!0),n.onMouseEntered()},this._onMouseEntered=function(){zo(n.el,n.classNames.mouseEntered),n.options.autoHide&&(n.hideScrollbar("x"),n.hideScrollbar("y")),n.isMouseEntering=!1},this._onMouseMove=function(o){n.mouseX=o.clientX,n.mouseY=o.clientY,(n.axis.x.isOverflowing||n.axis.x.forceVisible)&&n.onMouseMoveForAxis("x"),(n.axis.y.isOverflowing||n.axis.y.forceVisible)&&n.onMouseMoveForAxis("y")},this.onMouseLeave=function(){n.onMouseMove.cancel(),(n.axis.x.isOverflowing||n.axis.x.forceVisible)&&n.onMouseLeaveForAxis("x"),(n.axis.y.isOverflowing||n.axis.y.forceVisible)&&n.onMouseLeaveForAxis("y"),n.mouseX=-1,n.mouseY=-1},this._onWindowResize=function(){n.scrollbarWidth=n.getScrollbarWidth(),n.hideNativeScrollbar()},this.onPointerEvent=function(o){if(!(!n.axis.x.track.el||!n.axis.y.track.el||!n.axis.x.scrollbar.el||!n.axis.y.scrollbar.el)){var i,a;n.axis.x.track.rect=n.axis.x.track.el.getBoundingClientRect(),n.axis.y.track.rect=n.axis.y.track.el.getBoundingClientRect(),(n.axis.x.isOverflowing||n.axis.x.forceVisible)&&(i=n.isWithinBounds(n.axis.x.track.rect)),(n.axis.y.isOverflowing||n.axis.y.forceVisible)&&(a=n.isWithinBounds(n.axis.y.track.rect)),(i||a)&&(o.stopPropagation(),o.type==="pointerdown"&&o.pointerType!=="touch"&&(i&&(n.axis.x.scrollbar.rect=n.axis.x.scrollbar.el.getBoundingClientRect(),n.isWithinBounds(n.axis.x.scrollbar.rect)?n.onDragStart(o,"x"):n.onTrackClick(o,"x")),a&&(n.axis.y.scrollbar.rect=n.axis.y.scrollbar.el.getBoundingClientRect(),n.isWithinBounds(n.axis.y.scrollbar.rect)?n.onDragStart(o,"y"):n.onTrackClick(o,"y"))))}},this.drag=function(o){var i,a,s,c,u,d,f,h,v,b,g;if(!(!n.draggedAxis||!n.contentWrapperEl)){var m,x=n.axis[n.draggedAxis].track,w=(a=(i=x.rect)===null||i===void 0?void 0:i[n.axis[n.draggedAxis].sizeAttr])!==null&&a!==void 0?a:0,E=n.axis[n.draggedAxis].scrollbar,S=(c=(s=n.contentWrapperEl)===null||s===void 0?void 0:s[n.axis[n.draggedAxis].scrollSizeAttr])!==null&&c!==void 0?c:0,_=parseInt((d=(u=n.elStyles)===null||u===void 0?void 0:u[n.axis[n.draggedAxis].sizeAttr])!==null&&d!==void 0?d:"0px",10);o.preventDefault(),o.stopPropagation(),n.draggedAxis==="y"?m=o.pageY:m=o.pageX;var C=m-((h=(f=x.rect)===null||f===void 0?void 0:f[n.axis[n.draggedAxis].offsetAttr])!==null&&h!==void 0?h:0)-n.axis[n.draggedAxis].dragOffset;C=n.draggedAxis==="x"&&n.isRtl?((b=(v=x.rect)===null||v===void 0?void 0:v[n.axis[n.draggedAxis].sizeAttr])!==null&&b!==void 0?b:0)-E.size-C:C;var N=C/(w-E.size),P=N*(S-_);n.draggedAxis==="x"&&n.isRtl&&(P=!((g=e.getRtlHelpers())===null||g===void 0)&&g.isScrollingToNegative?-P:P),n.contentWrapperEl[n.axis[n.draggedAxis].scrollOffsetAttr]=P}},this.onEndDrag=function(o){n.isDragging=!1;var i=uh(n.el),a=Lo(n.el);o.preventDefault(),o.stopPropagation(),zo(n.el,n.classNames.dragging),n.onStopScrolling(),i.removeEventListener("mousemove",n.drag,!0),i.removeEventListener("mouseup",n.onEndDrag,!0),n.removePreventClickId=a.setTimeout(function(){i.removeEventListener("click",n.preventClick,!0),i.removeEventListener("dblclick",n.preventClick,!0),n.removePreventClickId=null})},this.preventClick=function(o){o.preventDefault(),o.stopPropagation()},this.el=t,this.options=ca(ca({},e.defaultOptions),r),this.classNames=ca(ca({},e.defaultOptions.classNames),r.classNames),this.axis={x:{scrollOffsetAttr:"scrollLeft",sizeAttr:"width",scrollSizeAttr:"scrollWidth",offsetSizeAttr:"offsetWidth",offsetAttr:"left",overflowAttr:"overflowX",dragOffset:0,isOverflowing:!0,forceVisible:!1,track:{size:null,el:null,rect:null,isVisible:!1},scrollbar:{size:null,el:null,rect:null,isVisible:!1}},y:{scrollOffsetAttr:"scrollTop",sizeAttr:"height",scrollSizeAttr:"scrollHeight",offsetSizeAttr:"offsetHeight",offsetAttr:"top",overflowAttr:"overflowY",dragOffset:0,isOverflowing:!0,forceVisible:!1,track:{size:null,el:null,rect:null,isVisible:!1},scrollbar:{size:null,el:null,rect:null,isVisible:!1}}},typeof this.el!="object"||!this.el.nodeName)throw new Error("Argument passed to SimpleBar must be an HTML element instead of ".concat(this.el));this.onMouseMove=d7(this._onMouseMove,64),this.onWindowResize=Ou(this._onWindowResize,64,{leading:!0}),this.onStopScrolling=Ou(this._onStopScrolling,this.stopScrollDelay),this.onMouseEntered=Ou(this._onMouseEntered,this.stopScrollDelay),this.init()}return e.getRtlHelpers=function(){if(e.rtlHelpers)return e.rtlHelpers;var t=document.createElement("div");t.innerHTML='<div class="simplebar-dummy-scrollbar-size"><div></div></div>';var r=t.firstElementChild,n=r==null?void 0:r.firstElementChild;if(!n)return null;document.body.appendChild(r),r.scrollLeft=0;var o=e.getOffset(r),i=e.getOffset(n);r.scrollLeft=-999;var a=e.getOffset(n);return document.body.removeChild(r),e.rtlHelpers={isScrollOriginAtZero:o.left!==i.left,isScrollingToNegative:i.left!==a.left},e.rtlHelpers},e.prototype.getScrollbarWidth=function(){try{return this.contentWrapperEl&&getComputedStyle(this.contentWrapperEl,"::-webkit-scrollbar").display==="none"||"scrollbarWidth"in document.documentElement.style||"-ms-overflow-style"in document.documentElement.style?0:vC()}catch{return vC()}},e.getOffset=function(t){var r=t.getBoundingClientRect(),n=uh(t),o=Lo(t);return{top:r.top+(o.pageYOffset||n.documentElement.scrollTop),left:r.left+(o.pageXOffset||n.documentElement.scrollLeft)}},e.prototype.init=function(){G_&&(this.initDOM(),this.rtlHelpers=e.getRtlHelpers(),this.scrollbarWidth=this.getScrollbarWidth(),this.recalculate(),this.initListeners())},e.prototype.initDOM=function(){var t,r;this.wrapperEl=this.el.querySelector(Ir(this.classNames.wrapper)),this.contentWrapperEl=this.options.scrollableNode||this.el.querySelector(Ir(this.classNames.contentWrapper)),this.contentEl=this.options.contentNode||this.el.querySelector(Ir(this.classNames.contentEl)),this.offsetEl=this.el.querySelector(Ir(this.classNames.offset)),this.maskEl=this.el.querySelector(Ir(this.classNames.mask)),this.placeholderEl=this.findChild(this.wrapperEl,Ir(this.classNames.placeholder)),this.heightAutoObserverWrapperEl=this.el.querySelector(Ir(this.classNames.heightAutoObserverWrapperEl)),this.heightAutoObserverEl=this.el.querySelector(Ir(this.classNames.heightAutoObserverEl)),this.axis.x.track.el=this.findChild(this.el,"".concat(Ir(this.classNames.track)).concat(Ir(this.classNames.horizontal))),this.axis.y.track.el=this.findChild(this.el,"".concat(Ir(this.classNames.track)).concat(Ir(this.classNames.vertical))),this.axis.x.scrollbar.el=((t=this.axis.x.track.el)===null||t===void 0?void 0:t.querySelector(Ir(this.classNames.scrollbar)))||null,this.axis.y.scrollbar.el=((r=this.axis.y.track.el)===null||r===void 0?void 0:r.querySelector(Ir(this.classNames.scrollbar)))||null,this.options.autoHide||(qo(this.axis.x.scrollbar.el,this.classNames.visible),qo(this.axis.y.scrollbar.el,this.classNames.visible))},e.prototype.initListeners=function(){var t=this,r,n=Lo(this.el);if(this.el.addEventListener("mouseenter",this.onMouseEnter),this.el.addEventListener("pointerdown",this.onPointerEvent,!0),this.el.addEventListener("mousemove",this.onMouseMove),this.el.addEventListener("mouseleave",this.onMouseLeave),(r=this.contentWrapperEl)===null||r===void 0||r.addEventListener("scroll",this.onScroll),n.addEventListener("resize",this.onWindowResize),!!this.contentEl){if(window.ResizeObserver){var o=!1,i=n.ResizeObserver||ResizeObserver;this.resizeObserver=new i(function(){o&&n.requestAnimationFrame(function(){t.recalculate()})}),this.resizeObserver.observe(this.el),this.resizeObserver.observe(this.contentEl),n.requestAnimationFrame(function(){o=!0})}this.mutationObserver=new n.MutationObserver(function(){n.requestAnimationFrame(function(){t.recalculate()})}),this.mutationObserver.observe(this.contentEl,{childList:!0,subtree:!0,characterData:!0})}},e.prototype.recalculate=function(){if(!(!this.heightAutoObserverEl||!this.contentEl||!this.contentWrapperEl||!this.wrapperEl||!this.placeholderEl)){var t=Lo(this.el);this.elStyles=t.getComputedStyle(this.el),this.isRtl=this.elStyles.direction==="rtl";var r=this.contentEl.offsetWidth,n=this.heightAutoObserverEl.offsetHeight<=1,o=this.heightAutoObserverEl.offsetWidth<=1||r>0,i=this.contentWrapperEl.offsetWidth,a=this.elStyles.overflowX,s=this.elStyles.overflowY;this.contentEl.style.padding="".concat(this.elStyles.paddingTop," ").concat(this.elStyles.paddingRight," ").concat(this.elStyles.paddingBottom," ").concat(this.elStyles.paddingLeft),this.wrapperEl.style.margin="-".concat(this.elStyles.paddingTop," -").concat(this.elStyles.paddingRight," -").concat(this.elStyles.paddingBottom," -").concat(this.elStyles.paddingLeft);var c=this.contentEl.scrollHeight,u=this.contentEl.scrollWidth;this.contentWrapperEl.style.height=n?"auto":"100%",this.placeholderEl.style.width=o?"".concat(r||u,"px"):"auto",this.placeholderEl.style.height="".concat(c,"px");var d=this.contentWrapperEl.offsetHeight;this.axis.x.isOverflowing=r!==0&&u>r,this.axis.y.isOverflowing=c>d,this.axis.x.isOverflowing=a==="hidden"?!1:this.axis.x.isOverflowing,this.axis.y.isOverflowing=s==="hidden"?!1:this.axis.y.isOverflowing,this.axis.x.forceVisible=this.options.forceVisible==="x"||this.options.forceVisible===!0,this.axis.y.forceVisible=this.options.forceVisible==="y"||this.options.forceVisible===!0,this.hideNativeScrollbar();var f=this.axis.x.isOverflowing?this.scrollbarWidth:0,h=this.axis.y.isOverflowing?this.scrollbarWidth:0;this.axis.x.isOverflowing=this.axis.x.isOverflowing&&u>i-h,this.axis.y.isOverflowing=this.axis.y.isOverflowing&&c>d-f,this.axis.x.scrollbar.size=this.getScrollbarSize("x"),this.axis.y.scrollbar.size=this.getScrollbarSize("y"),this.axis.x.scrollbar.el&&(this.axis.x.scrollbar.el.style.width="".concat(this.axis.x.scrollbar.size,"px")),this.axis.y.scrollbar.el&&(this.axis.y.scrollbar.el.style.height="".concat(this.axis.y.scrollbar.size,"px")),this.positionScrollbar("x"),this.positionScrollbar("y"),this.toggleTrackVisibility("x"),this.toggleTrackVisibility("y")}},e.prototype.getScrollbarSize=function(t){var r,n;if(t===void 0&&(t="y"),!this.axis[t].isOverflowing||!this.contentEl)return 0;var o=this.contentEl[this.axis[t].scrollSizeAttr],i=(n=(r=this.axis[t].track.el)===null||r===void 0?void 0:r[this.axis[t].offsetSizeAttr])!==null&&n!==void 0?n:0,a=i/o,s;return s=Math.max(~~(a*i),this.options.scrollbarMinSize),this.options.scrollbarMaxSize&&(s=Math.min(s,this.options.scrollbarMaxSize)),s},e.prototype.positionScrollbar=function(t){var r,n,o;t===void 0&&(t="y");var i=this.axis[t].scrollbar;if(!(!this.axis[t].isOverflowing||!this.contentWrapperEl||!i.el||!this.elStyles)){var a=this.contentWrapperEl[this.axis[t].scrollSizeAttr],s=((r=this.axis[t].track.el)===null||r===void 0?void 0:r[this.axis[t].offsetSizeAttr])||0,c=parseInt(this.elStyles[this.axis[t].sizeAttr],10),u=this.contentWrapperEl[this.axis[t].scrollOffsetAttr];u=t==="x"&&this.isRtl&&!((n=e.getRtlHelpers())===null||n===void 0)&&n.isScrollOriginAtZero?-u:u,t==="x"&&this.isRtl&&(u=!((o=e.getRtlHelpers())===null||o===void 0)&&o.isScrollingToNegative?u:-u);var d=u/(a-c),f=~~((s-i.size)*d);f=t==="x"&&this.isRtl?-f+(s-i.size):f,i.el.style.transform=t==="x"?"translate3d(".concat(f,"px, 0, 0)"):"translate3d(0, ".concat(f,"px, 0)")}},e.prototype.toggleTrackVisibility=function(t){t===void 0&&(t="y");var r=this.axis[t].track.el,n=this.axis[t].scrollbar.el;!r||!n||!this.contentWrapperEl||(this.axis[t].isOverflowing||this.axis[t].forceVisible?(r.style.visibility="visible",this.contentWrapperEl.style[this.axis[t].overflowAttr]="scroll",this.el.classList.add("".concat(this.classNames.scrollable,"-").concat(t))):(r.style.visibility="hidden",this.contentWrapperEl.style[this.axis[t].overflowAttr]="hidden",this.el.classList.remove("".concat(this.classNames.scrollable,"-").concat(t))),this.axis[t].isOverflowing?n.style.display="block":n.style.display="none")},e.prototype.showScrollbar=function(t){t===void 0&&(t="y"),this.axis[t].isOverflowing&&!this.axis[t].scrollbar.isVisible&&(qo(this.axis[t].scrollbar.el,this.classNames.visible),this.axis[t].scrollbar.isVisible=!0)},e.prototype.hideScrollbar=function(t){t===void 0&&(t="y"),!this.isDragging&&this.axis[t].isOverflowing&&this.axis[t].scrollbar.isVisible&&(zo(this.axis[t].scrollbar.el,this.classNames.visible),this.axis[t].scrollbar.isVisible=!1)},e.prototype.hideNativeScrollbar=function(){this.offsetEl&&(this.offsetEl.style[this.isRtl?"left":"right"]=this.axis.y.isOverflowing||this.axis.y.forceVisible?"-".concat(this.scrollbarWidth,"px"):"0px",this.offsetEl.style.bottom=this.axis.x.isOverflowing||this.axis.x.forceVisible?"-".concat(this.scrollbarWidth,"px"):"0px")},e.prototype.onMouseMoveForAxis=function(t){t===void 0&&(t="y");var r=this.axis[t];!r.track.el||!r.scrollbar.el||(r.track.rect=r.track.el.getBoundingClientRect(),r.scrollbar.rect=r.scrollbar.el.getBoundingClientRect(),this.isWithinBounds(r.track.rect)?(this.showScrollbar(t),qo(r.track.el,this.classNames.hover),this.isWithinBounds(r.scrollbar.rect)?qo(r.scrollbar.el,this.classNames.hover):zo(r.scrollbar.el,this.classNames.hover)):(zo(r.track.el,this.classNames.hover),this.options.autoHide&&this.hideScrollbar(t)))},e.prototype.onMouseLeaveForAxis=function(t){t===void 0&&(t="y"),zo(this.axis[t].track.el,this.classNames.hover),zo(this.axis[t].scrollbar.el,this.classNames.hover),this.options.autoHide&&this.hideScrollbar(t)},e.prototype.onDragStart=function(t,r){var n;r===void 0&&(r="y"),this.isDragging=!0;var o=uh(this.el),i=Lo(this.el),a=this.axis[r].scrollbar,s=r==="y"?t.pageY:t.pageX;this.axis[r].dragOffset=s-(((n=a.rect)===null||n===void 0?void 0:n[this.axis[r].offsetAttr])||0),this.draggedAxis=r,qo(this.el,this.classNames.dragging),o.addEventListener("mousemove",this.drag,!0),o.addEventListener("mouseup",this.onEndDrag,!0),this.removePreventClickId===null?(o.addEventListener("click",this.preventClick,!0),o.addEventListener("dblclick",this.preventClick,!0)):(i.clearTimeout(this.removePreventClickId),this.removePreventClickId=null)},e.prototype.onTrackClick=function(t,r){var n=this,o,i,a,s;r===void 0&&(r="y");var c=this.axis[r];if(!(!this.options.clickOnTrack||!c.scrollbar.el||!this.contentWrapperEl)){t.preventDefault();var u=Lo(this.el);this.axis[r].scrollbar.rect=c.scrollbar.el.getBoundingClientRect();var d=this.axis[r].scrollbar,f=(i=(o=d.rect)===null||o===void 0?void 0:o[this.axis[r].offsetAttr])!==null&&i!==void 0?i:0,h=parseInt((s=(a=this.elStyles)===null||a===void 0?void 0:a[this.axis[r].sizeAttr])!==null&&s!==void 0?s:"0px",10),v=this.contentWrapperEl[this.axis[r].scrollOffsetAttr],b=r==="y"?this.mouseY-f:this.mouseX-f,g=b<0?-1:1,m=g===-1?v-h:v+h,x=40,w=function(){n.contentWrapperEl&&(g===-1?v>m&&(v-=x,n.contentWrapperEl[n.axis[r].scrollOffsetAttr]=v,u.requestAnimationFrame(w)):v<m&&(v+=x,n.contentWrapperEl[n.axis[r].scrollOffsetAttr]=v,u.requestAnimationFrame(w)))};w()}},e.prototype.getContentElement=function(){return this.contentEl},e.prototype.getScrollElement=function(){return this.contentWrapperEl},e.prototype.removeListeners=function(){var t=Lo(this.el);this.el.removeEventListener("mouseenter",this.onMouseEnter),this.el.removeEventListener("pointerdown",this.onPointerEvent,!0),this.el.removeEventListener("mousemove",this.onMouseMove),this.el.removeEventListener("mouseleave",this.onMouseLeave),this.contentWrapperEl&&this.contentWrapperEl.removeEventListener("scroll",this.onScroll),t.removeEventListener("resize",this.onWindowResize),this.mutationObserver&&this.mutationObserver.disconnect(),this.resizeObserver&&this.resizeObserver.disconnect(),this.onMouseMove.cancel(),this.onWindowResize.cancel(),this.onStopScrolling.cancel(),this.onMouseEntered.cancel()},e.prototype.unMount=function(){this.removeListeners()},e.prototype.isWithinBounds=function(t){return this.mouseX>=t.left&&this.mouseX<=t.left+t.width&&this.mouseY>=t.top&&this.mouseY<=t.top+t.height},e.prototype.findChild=function(t,r){var n=t.matches||t.webkitMatchesSelector||t.mozMatchesSelector||t.msMatchesSelector;return Array.prototype.filter.call(t.children,function(o){return n.call(o,r)})[0]},e.rtlHelpers=null,e.defaultOptions={forceVisible:!1,clickOnTrack:!0,scrollbarMinSize:25,scrollbarMaxSize:0,ariaLabel:"scrollable content",tabIndex:0,classNames:{contentEl:"simplebar-content",contentWrapper:"simplebar-content-wrapper",offset:"simplebar-offset",mask:"simplebar-mask",wrapper:"simplebar-wrapper",placeholder:"simplebar-placeholder",scrollbar:"simplebar-scrollbar",track:"simplebar-track",heightAutoObserverWrapperEl:"simplebar-height-auto-observer-wrapper",heightAutoObserverEl:"simplebar-height-auto-observer",visible:"simplebar-visible",horizontal:"simplebar-horizontal",vertical:"simplebar-vertical",hover:"simplebar-hover",dragging:"simplebar-dragging",scrolling:"simplebar-scrolling",scrollable:"simplebar-scrollable",mouseEntered:"simplebar-mouse-entered"},scrollableNode:null,contentNode:null,autoHide:!0},e.getOptions=p7,e.helpers=f7,e})(),Hr=function(){return Hr=Object.assign||function(e){for(var t,r=1,n=arguments.length;r<n;r++){t=arguments[r];for(var o in t)Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o])}return e},Hr.apply(this,arguments)};function h7(e,t){var r={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,n=Object.getOwnPropertySymbols(e);o<n.length;o++)t.indexOf(n[o])<0&&Object.prototype.propertyIsEnumerable.call(e,n[o])&&(r[n[o]]=e[n[o]]);return r}var Y_=ue.forwardRef(function(e,t){var r=e.children,n=e.scrollableNodeProps,o=n===void 0?{}:n,i=h7(e,["children","scrollableNodeProps"]),a=ue.useRef(),s=ue.useRef(),c=ue.useRef(),u={},d={};Object.keys(i).forEach(function(v){Object.prototype.hasOwnProperty.call(gs.defaultOptions,v)?u[v]=i[v]:d[v]=i[v]});var f=Hr(Hr({},gs.defaultOptions.classNames),u.classNames),h=Hr(Hr({},o),{className:"".concat(f.contentWrapper).concat(o.className?" ".concat(o.className):""),tabIndex:u.tabIndex||gs.defaultOptions.tabIndex,role:"region","aria-label":u.ariaLabel||gs.defaultOptions.ariaLabel});return ue.useEffect(function(){var v;return s.current=h.ref?h.ref.current:s.current,a.current&&(v=new gs(a.current,Hr(Hr(Hr({},u),s.current&&{scrollableNode:s.current}),c.current&&{contentNode:c.current})),typeof t=="function"?t(v):t&&(t.current=v)),function(){v==null||v.unMount(),v=null,typeof t=="function"&&t(null)}},[]),ue.createElement("div",Hr({"data-simplebar":"init",ref:a},d),ue.createElement("div",{className:f.wrapper},ue.createElement("div",{className:f.heightAutoObserverWrapperEl},ue.createElement("div",{className:f.heightAutoObserverEl})),ue.createElement("div",{className:f.mask},ue.createElement("div",{className:f.offset},typeof r=="function"?r({scrollableNodeRef:s,scrollableNodeProps:Hr(Hr({},h),{ref:s}),contentNodeRef:c,contentNodeProps:{className:f.contentEl,ref:c}}):ue.createElement("div",Hr({},h),ue.createElement("div",{className:f.contentEl},r)))),ue.createElement("div",{className:f.placeholder})),ue.createElement("div",{className:"".concat(f.track," ").concat(f.horizontal)},ue.createElement("div",{className:f.scrollbar})),ue.createElement("div",{className:"".concat(f.track," ").concat(f.vertical)},ue.createElement("div",{className:f.scrollbar})))});Y_.displayName="SimpleBar";const iq=R.forwardRef(({size:e="md",color:t="primary",isInvalid:r=!1,isDisabled:n=!1,isReadOnly:o=!1,className:i,children:a,...s},c)=>{const[u,d]=R.useState(!1),[f,h]=R.useState(!1),v={size:e,color:t,isInvalid:r,isDisabled:n,isReadOnly:o,hasMessage:u,setHasMessage:d,hasArea:f,setHasArea:h};return O.jsx(XL.Provider,{value:v,children:O.jsx("div",{ref:c,"data-qui":"Input",className:xe(kG(),i),...s,children:a})})}),aq=R.forwardRef(({className:e,children:t,...r},n)=>{const{size:o,color:i,isDisabled:a,isReadOnly:s,hasMessage:c,hasArea:u}=bl();return O.jsx("div",{ref:n,"data-qui":"InputGroup",className:xe(DG({size:o,color:i,isDisabled:a,isReadOnly:s,hasMessage:c,hasArea:u}),e),...r,children:t})}),sq=R.forwardRef(({className:e,...t},r)=>{const{size:n,color:o,isInvalid:i,isDisabled:a,isReadOnly:s}=bl(),{isDisabled:c,isReadOnly:u,...d}=t;return O.jsx("input",{ref:r,disabled:a||c,readOnly:u||s||!1,"aria-invalid":i,className:xe(MG({size:n,color:o}),e),...d})}),v7=R.forwardRef(({className:e,autoHeight:t,...r},n)=>{const{size:o,color:i,isInvalid:a,isDisabled:s,setHasArea:c}=bl(),u=R.useRef(null),d=n||u,f=R.useRef(null);R.useEffect(()=>(c(!0),()=>{c(!1)}),[c]);const h=R.useCallback(()=>{if(u.current){const w=u.current;w.style.height="auto",w.style.height=`${w.scrollHeight}px`}},[]),v=w=>{var E;h(),(E=r.onInput)==null||E.call(r,w)};R.useEffect(()=>{h()},[h,r.value]);const b=w=>{w.preventDefault();const E=f.current;if(!E)return;const S=w.clientY,_=E.offsetHeight,C=P=>{const A=_+(P.clientY-S);A>30&&(E.style.height=A+"px")},N=()=>{document.removeEventListener("mousemove",C),document.removeEventListener("mouseup",N)};document.addEventListener("mousemove",C),document.addEventListener("mouseup",N)},{isDisabled:g,isReadOnly:m,...x}=r;return O.jsxs("div",{ref:f,className:"w-full relative",style:t?void 0:{height:"120px"},children:[t?O.jsx("textarea",{ref:d,rows:1,className:xe(uC({size:o,color:i}),e),disabled:s||g,onInput:v,readOnly:m||!1,"aria-invalid":a,style:{overflow:"hidden"},...x}):O.jsx(Y_,{style:{height:"100%"},children:O.jsx("textarea",{ref:d,rows:1,className:xe(uC({size:o,color:i}),e),disabled:s||g,onInput:v,readOnly:m||!1,"aria-invalid":a,style:{height:"auto",overflow:"hidden",width:"100%"},...x})}),!t&&O.jsx("div",{className:"absolute right-0 bottom-0 -translate-x-full -translate-y-full size-1.75 text-sm cursor-se-resize z-10",onMouseDown:b,children:O.jsx(_8,{})})]})}),lq=R.forwardRef(({isAction:e=!1,className:t,isDisabled:r=!1,style:n,children:o,...i},a)=>{const{size:s,color:c,isDisabled:u}=bl(),d=r||u,f=jG({size:s,color:c,isDisabled:d,isAction:e});return O.jsx("div",{ref:a,"data-qui":"InputIcon",className:xe(f,t),style:n,role:e||i.onClick?"button":void 0,tabIndex:(e||i.onClick)&&!d?0:void 0,"aria-disabled":d,...i,children:o})}),cq=R.forwardRef(({icon:e,className:t,children:r,...n},o)=>{const{size:i,color:a,setHasMessage:s,isDisabled:c}=bl();return R.useEffect(()=>(s(!0),()=>{s(!1)}),[s]),O.jsxs("div",{ref:o,"data-qui":"InputMessage",role:"alert",className:xe(LG({size:i,color:a,isDisabled:c}),t),...n,children:[e!==void 0&&O.jsx("div",{className:xe(qG({size:i}),t),children:e}),O.jsx("p",{children:r})]})});iq.displayName="InputRoot";aq.displayName="InputGroup";sq.displayName="InputField";v7.displayName="InputArea";lq.displayName="InputIcon";cq.displayName="InputMessage";const yt={Root:iq,Group:aq,Field:sq,Icon:lq,Message:cq},nl={primary:{container:"bg-primary-light",text:"text-primary-dark",icon:"text-primary-dark",button:"hover:bg-primary-hover hover:text-body"},positive:{container:"bg-positive-light",text:"text-positive-dark",icon:"text-positive-dark",button:"hover:bg-positive hover:text-body"},negative:{container:"bg-negative-light",text:"text-negative-dark",icon:"text-negative-dark",button:"hover:bg-negative hover:text-body"},warning:{container:"bg-warning-light",text:"text-warning-dark",icon:"text-warning-dark",button:"hover:bg-warning hover:text-body"}},g7=({color:e})=>xe("h-6 absolute py-0.5 px-1 rounded whitespace-nowrap flex items-center gap-1",nl[e].container,nl[e].icon),m7=({color:e})=>xe("text-xs font-medium leading-3",nl[e].text),b7=({color:e})=>xe("p-0.5 rounded cursor-pointer",nl[e].button,nl[e].icon),y7=({label:e,color:t="primary",position:r="up",showCloseButton:n=!1,icon:o,children:i,delay:a=2e3,trigger:s="hover"})=>{const[c,u]=R.useState(!1),[d,f]=R.useState(!1),[h,v]=R.useState({position:r,transform:""}),b=R.useRef(null),g=R.useRef(null),m=R.useRef(null),x=R.useCallback(()=>{if(!b.current||!g.current)return;const P=b.current.getBoundingClientRect(),A=g.current.getBoundingClientRect(),j=window.innerWidth,M=window.innerHeight,L=Math.max(document.documentElement.scrollWidth,document.body.scrollWidth,j),D=Math.max(document.documentElement.scrollHeight,document.body.scrollHeight,M),T=4;let W=r,q={position:W,transform:""};const G={up:{fits:P.top-A.height-T>=0,styles:{bottom:`calc(100% + ${T}px)`,left:"50%",transform:"translateX(-50%)"}},"up-start":{fits:P.top-A.height-T>=0&&P.left+A.width<=j,styles:{bottom:`calc(100% + ${T}px)`,left:"0",transform:"translateX(0)"}},"up-end":{fits:P.top-A.height-T>=0&&P.right-A.width>=0,styles:{bottom:`calc(100% + ${T}px)`,right:"0",transform:"translateX(0)"}},down:{fits:P.bottom+A.height+T<=M&&P.bottom+A.height+T<=D,styles:{top:`calc(100% + ${T}px)`,left:"50%",transform:"translateX(-50%)"}},"down-start":{fits:P.bottom+A.height+T<=M&&P.bottom+A.height+T<=D&&P.left+A.width<=j,styles:{top:`calc(100% + ${T}px)`,left:"0",transform:"translateX(0)"}},"down-end":{fits:P.bottom+A.height+T<=M&&P.bottom+A.height+T<=D&&P.right-A.width>=0,styles:{top:`calc(100% + ${T}px)`,right:"0",transform:"translateX(0)"}},left:{fits:P.left-A.width-T>=0,styles:{right:`calc(100% + ${T}px)`,top:"50%",transform:"translateY(-50%)"}},"left-start":{fits:P.left-A.width-T>=0&&P.top+A.height<=M,styles:{right:`calc(100% + ${T}px)`,top:"0",transform:"translateY(0)"}},"left-end":{fits:P.left-A.width-T>=0&&P.bottom-A.height>=0,styles:{right:`calc(100% + ${T}px)`,bottom:"0",transform:"translateY(0)"}},right:{fits:P.right+A.width+T<=j&&P.right+A.width+T<=L,styles:{left:`calc(100% + ${T}px)`,top:"50%",transform:"translateY(-50%)"}},"right-start":{fits:P.right+A.width+T<=j&&P.right+A.width+T<=L&&P.top+A.height<=M,styles:{left:`calc(100% + ${T}px)`,top:"0",transform:"translateY(0)"}},"right-end":{fits:P.right+A.width+T<=j&&P.right+A.width+T<=L&&P.bottom-A.height>=0,styles:{left:`calc(100% + ${T}px)`,bottom:"0",transform:"translateY(0)"}}},F=P.left+P.width/2-A.width/2,J=P.left+P.width/2+A.width/2;if((r==="up"||r==="down")&&(F<0||J>j)&&(G[r].fits=!1),G[r].fits)q={position:r,...G[r].styles};else{const z=["up","up-start","up-end","down","down-start","down-end","right","right-start","right-end","left","left-start","left-end"].find(U=>G[U].fits);if(z)W=z,q={position:W,...G[z].styles};else{const U={up:P.top,"up-start":P.top,"up-end":P.top,down:Math.min(M-P.bottom,D-P.bottom),"down-start":Math.min(M-P.bottom,D-P.bottom),"down-end":Math.min(M-P.bottom,D-P.bottom),left:P.left,"left-start":P.left,"left-end":P.left,right:Math.min(j-P.right,L-P.right),"right-start":Math.min(j-P.right,L-P.right),"right-end":Math.min(j-P.right,L-P.right)},oe=Object.entries(U).reduce((re,[$,Y])=>Y>re.space?{position:$,space:Y}:re,{position:"up",space:0}).position;W=oe,q={position:W,...G[oe].styles}}}v(q)},[r]),w=()=>{s==="click"&&(u(!0),m.current&&clearTimeout(m.current),m.current=setTimeout(()=>{d||u(!1)},a))},E=P=>{P.stopPropagation(),u(!1),m.current&&clearTimeout(m.current)},S=()=>{f(!0),m.current&&clearTimeout(m.current)},_=()=>{f(!1),c&&(m.current=setTimeout(()=>{u(!1)},a))},C=()=>{s==="hover"&&u(!0)},N=()=>{s==="hover"&&u(!1)};return R.useEffect(()=>{if(c&&g.current){const P=requestAnimationFrame(()=>{x()});return()=>cancelAnimationFrame(P)}},[c,e,x]),R.useEffect(()=>{const P=()=>{c&&x()},A=()=>{c&&x()};return window.addEventListener("resize",P),window.addEventListener("scroll",A,!0),()=>{window.removeEventListener("resize",P),window.removeEventListener("scroll",A,!0),m.current&&clearTimeout(m.current)}},[c,x]),O.jsxs("div",{"data-qui":"Tooltip",ref:b,onClick:w,onMouseEnter:C,onMouseLeave:N,className:"relative h-full flex items-center",children:[i,c&&O.jsxs("div",{ref:g,role:"tooltip",className:g7({color:t}),style:{position:"absolute",left:h.left,right:h.right,top:h.top,bottom:h.bottom,transform:h.transform,zIndex:1e3},onMouseEnter:S,onMouseLeave:_,children:[o&&O.jsx("span",{children:o}),O.jsx("p",{className:m7({color:t}),children:e}),n&&O.jsx("div",{onClick:E,className:b7({color:t}),role:"button",children:O.jsx(Td,{})})]})]})};function x7(){for(var e=arguments.length,t=new Array(e),r=0;r<e;r++)t[r]=arguments[r];return R.useMemo(()=>n=>{t.forEach(o=>o(n))},t)}const Ad=typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u";function Ma(e){const t=Object.prototype.toString.call(e);return t==="[object Window]"||t==="[object global]"}function K_(e){return"nodeType"in e}function xr(e){var t,r;return e?Ma(e)?e:K_(e)&&(t=(r=e.ownerDocument)==null?void 0:r.defaultView)!=null?t:window:window}function X_(e){const{Document:t}=xr(e);return e instanceof t}function yl(e){return Ma(e)?!1:e instanceof xr(e).HTMLElement}function uq(e){return e instanceof xr(e).SVGElement}function ja(e){return e?Ma(e)?e.document:K_(e)?X_(e)?e:yl(e)||uq(e)?e.ownerDocument:document:document:document}const In=Ad?R.useLayoutEffect:R.useEffect;function kd(e){const t=R.useRef(e);return In(()=>{t.current=e}),R.useCallback(function(){for(var r=arguments.length,n=new Array(r),o=0;o<r;o++)n[o]=arguments[o];return t.current==null?void 0:t.current(...n)},[])}function w7(){const e=R.useRef(null),t=R.useCallback((n,o)=>{e.current=setInterval(n,o)},[]),r=R.useCallback(()=>{e.current!==null&&(clearInterval(e.current),e.current=null)},[]);return[t,r]}function ol(e,t){t===void 0&&(t=[e]);const r=R.useRef(e);return In(()=>{r.current!==e&&(r.current=e)},t),r}function xl(e,t){const r=R.useRef();return R.useMemo(()=>{const n=e(r.current);return r.current=n,n},[...t])}function Gu(e){const t=kd(e),r=R.useRef(null),n=R.useCallback(o=>{o!==r.current&&(t==null||t(o,r.current)),r.current=o},[]);return[r,n]}function Yu(e){const t=R.useRef();return R.useEffect(()=>{t.current=e},[e]),t.current}let dh={};function wl(e,t){return R.useMemo(()=>{if(t)return t;const r=dh[e]==null?0:dh[e]+1;return dh[e]=r,e+"-"+r},[e,t])}function dq(e){return function(t){for(var r=arguments.length,n=new Array(r>1?r-1:0),o=1;o<r;o++)n[o-1]=arguments[o];return n.reduce((i,a)=>{const s=Object.entries(a);for(const[c,u]of s){const d=i[c];d!=null&&(i[c]=d+e*u)}return i},{...t})}}const pa=dq(1),Ku=dq(-1);function _7(e){return"clientX"in e&&"clientY"in e}function Dd(e){if(!e)return!1;const{KeyboardEvent:t}=xr(e.target);return t&&e instanceof t}function E7(e){if(!e)return!1;const{TouchEvent:t}=xr(e.target);return t&&e instanceof t}function Xu(e){if(E7(e)){if(e.touches&&e.touches.length){const{clientX:t,clientY:r}=e.touches[0];return{x:t,y:r}}else if(e.changedTouches&&e.changedTouches.length){const{clientX:t,clientY:r}=e.changedTouches[0];return{x:t,y:r}}}return _7(e)?{x:e.clientX,y:e.clientY}:null}const Go=Object.freeze({Translate:{toString(e){if(!e)return;const{x:t,y:r}=e;return"translate3d("+(t?Math.round(t):0)+"px, "+(r?Math.round(r):0)+"px, 0)"}},Scale:{toString(e){if(!e)return;const{scaleX:t,scaleY:r}=e;return"scaleX("+t+") scaleY("+r+")"}},Transform:{toString(e){if(e)return[Go.Translate.toString(e),Go.Scale.toString(e)].join(" ")}},Transition:{toString(e){let{property:t,duration:r,easing:n}=e;return t+" "+r+"ms "+n}}}),gC="a,frame,iframe,input:not([type=hidden]):not(:disabled),select:not(:disabled),textarea:not(:disabled),button:not(:disabled),*[tabindex]";function S7(e){return e.matches(gC)?e:e.querySelector(gC)}const O7={display:"none"};function C7(e){let{id:t,value:r}=e;return R.createElement("div",{id:t,style:O7},r)}function R7(e){let{id:t,announcement:r,ariaLiveType:n="assertive"}=e;const o={position:"fixed",top:0,left:0,width:1,height:1,margin:-1,border:0,padding:0,overflow:"hidden",clip:"rect(0 0 0 0)",clipPath:"inset(100%)",whiteSpace:"nowrap"};return R.createElement("div",{id:t,style:o,role:"status","aria-live":n,"aria-atomic":!0},r)}function N7(){const[e,t]=R.useState("");return{announce:R.useCallback(r=>{r!=null&&t(r)},[]),announcement:e}}const fq=R.createContext(null);function I7(e){const t=R.useContext(fq);R.useEffect(()=>{if(!t)throw new Error("useDndMonitor must be used within a children of <DndContext>");return t(e)},[e,t])}function P7(){const[e]=R.useState(()=>new Set),t=R.useCallback(r=>(e.add(r),()=>e.delete(r)),[e]);return[R.useCallback(r=>{let{type:n,event:o}=r;e.forEach(i=>{var a;return(a=i[n])==null?void 0:a.call(i,o)})},[e]),t]}const T7={draggable:`
|
|
15
|
+
To pick up a draggable item, press the space bar.
|
|
16
|
+
While dragging, use the arrow keys to move the item.
|
|
17
|
+
Press space again to drop the item in its new position, or press escape to cancel.
|
|
18
|
+
`},A7={onDragStart(e){let{active:t}=e;return"Picked up draggable item "+t.id+"."},onDragOver(e){let{active:t,over:r}=e;return r?"Draggable item "+t.id+" was moved over droppable area "+r.id+".":"Draggable item "+t.id+" is no longer over a droppable area."},onDragEnd(e){let{active:t,over:r}=e;return r?"Draggable item "+t.id+" was dropped over droppable area "+r.id:"Draggable item "+t.id+" was dropped."},onDragCancel(e){let{active:t}=e;return"Dragging was cancelled. Draggable item "+t.id+" was dropped."}};function k7(e){let{announcements:t=A7,container:r,hiddenTextDescribedById:n,screenReaderInstructions:o=T7}=e;const{announce:i,announcement:a}=N7(),s=wl("DndLiveRegion"),[c,u]=R.useState(!1);if(R.useEffect(()=>{u(!0)},[]),I7(R.useMemo(()=>({onDragStart(f){let{active:h}=f;i(t.onDragStart({active:h}))},onDragMove(f){let{active:h,over:v}=f;t.onDragMove&&i(t.onDragMove({active:h,over:v}))},onDragOver(f){let{active:h,over:v}=f;i(t.onDragOver({active:h,over:v}))},onDragEnd(f){let{active:h,over:v}=f;i(t.onDragEnd({active:h,over:v}))},onDragCancel(f){let{active:h,over:v}=f;i(t.onDragCancel({active:h,over:v}))}}),[i,t])),!c)return null;const d=R.createElement(R.Fragment,null,R.createElement(C7,{id:n,value:o.draggable}),R.createElement(R7,{id:s,announcement:a}));return r?mo.createPortal(d,r):d}var Gt;(function(e){e.DragStart="dragStart",e.DragMove="dragMove",e.DragEnd="dragEnd",e.DragCancel="dragCancel",e.DragOver="dragOver",e.RegisterDroppable="registerDroppable",e.SetDroppableDisabled="setDroppableDisabled",e.UnregisterDroppable="unregisterDroppable"})(Gt||(Gt={}));function Zu(){}function D7(e,t){return R.useMemo(()=>({sensor:e,options:t??{}}),[e,t])}function M7(){for(var e=arguments.length,t=new Array(e),r=0;r<e;r++)t[r]=arguments[r];return R.useMemo(()=>[...t].filter(n=>n!=null),[...t])}const Pn=Object.freeze({x:0,y:0});function j7(e,t){return Math.sqrt(Math.pow(e.x-t.x,2)+Math.pow(e.y-t.y,2))}function L7(e,t){const r=Xu(e);if(!r)return"0 0";const n={x:(r.x-t.left)/t.width*100,y:(r.y-t.top)/t.height*100};return n.x+"% "+n.y+"%"}function q7(e,t){let{data:{value:r}}=e,{data:{value:n}}=t;return r-n}function z7(e,t){let{data:{value:r}}=e,{data:{value:n}}=t;return n-r}function B7(e,t){if(!e||e.length===0)return null;const[r]=e;return r[t]}function mC(e,t,r){return t===void 0&&(t=e.left),r===void 0&&(r=e.top),{x:t+e.width*.5,y:r+e.height*.5}}const F7=e=>{let{collisionRect:t,droppableRects:r,droppableContainers:n}=e;const o=mC(t,t.left,t.top),i=[];for(const a of n){const{id:s}=a,c=r.get(s);if(c){const u=j7(mC(c),o);i.push({id:s,data:{droppableContainer:a,value:u}})}}return i.sort(q7)};function $7(e,t){const r=Math.max(t.top,e.top),n=Math.max(t.left,e.left),o=Math.min(t.left+t.width,e.left+e.width),i=Math.min(t.top+t.height,e.top+e.height),a=o-n,s=i-r;if(n<o&&r<i){const c=t.width*t.height,u=e.width*e.height,d=a*s,f=d/(c+u-d);return Number(f.toFixed(4))}return 0}const V7=e=>{let{collisionRect:t,droppableRects:r,droppableContainers:n}=e;const o=[];for(const i of n){const{id:a}=i,s=r.get(a);if(s){const c=$7(s,t);c>0&&o.push({id:a,data:{droppableContainer:i,value:c}})}}return o.sort(z7)};function H7(e,t,r){return{...e,scaleX:t&&r?t.width/r.width:1,scaleY:t&&r?t.height/r.height:1}}function pq(e,t){return e&&t?{x:e.left-t.left,y:e.top-t.top}:Pn}function W7(e){return function(t){for(var r=arguments.length,n=new Array(r>1?r-1:0),o=1;o<r;o++)n[o-1]=arguments[o];return n.reduce((i,a)=>({...i,top:i.top+e*a.y,bottom:i.bottom+e*a.y,left:i.left+e*a.x,right:i.right+e*a.x}),{...t})}}const U7=W7(1);function hq(e){if(e.startsWith("matrix3d(")){const t=e.slice(9,-1).split(/, /);return{x:+t[12],y:+t[13],scaleX:+t[0],scaleY:+t[5]}}else if(e.startsWith("matrix(")){const t=e.slice(7,-1).split(/, /);return{x:+t[4],y:+t[5],scaleX:+t[0],scaleY:+t[3]}}return null}function G7(e,t,r){const n=hq(t);if(!n)return e;const{scaleX:o,scaleY:i,x:a,y:s}=n,c=e.left-a-(1-o)*parseFloat(r),u=e.top-s-(1-i)*parseFloat(r.slice(r.indexOf(" ")+1)),d=o?e.width/o:e.width,f=i?e.height/i:e.height;return{width:d,height:f,top:u,right:c+d,bottom:u+f,left:c}}const Y7={ignoreTransform:!1};function La(e,t){t===void 0&&(t=Y7);let r=e.getBoundingClientRect();if(t.ignoreTransform){const{transform:u,transformOrigin:d}=xr(e).getComputedStyle(e);u&&(r=G7(r,u,d))}const{top:n,left:o,width:i,height:a,bottom:s,right:c}=r;return{top:n,left:o,width:i,height:a,bottom:s,right:c}}function bC(e){return La(e,{ignoreTransform:!0})}function K7(e){const t=e.innerWidth,r=e.innerHeight;return{top:0,left:0,right:t,bottom:r,width:t,height:r}}function X7(e,t){return t===void 0&&(t=xr(e).getComputedStyle(e)),t.position==="fixed"}function Z7(e,t){t===void 0&&(t=xr(e).getComputedStyle(e));const r=/(auto|scroll|overlay)/;return["overflow","overflowX","overflowY"].some(n=>{const o=t[n];return typeof o=="string"?r.test(o):!1})}function Z_(e,t){const r=[];function n(o){if(t!=null&&r.length>=t||!o)return r;if(X_(o)&&o.scrollingElement!=null&&!r.includes(o.scrollingElement))return r.push(o.scrollingElement),r;if(!yl(o)||uq(o)||r.includes(o))return r;const i=xr(e).getComputedStyle(o);return o!==e&&Z7(o,i)&&r.push(o),X7(o,i)?r:n(o.parentNode)}return e?n(e):r}function vq(e){const[t]=Z_(e,1);return t??null}function fh(e){return!Ad||!e?null:Ma(e)?e:K_(e)?X_(e)||e===ja(e).scrollingElement?window:yl(e)?e:null:null}function gq(e){return Ma(e)?e.scrollX:e.scrollLeft}function mq(e){return Ma(e)?e.scrollY:e.scrollTop}function i_(e){return{x:gq(e),y:mq(e)}}var Jt;(function(e){e[e.Forward=1]="Forward",e[e.Backward=-1]="Backward"})(Jt||(Jt={}));function bq(e){return!Ad||!e?!1:e===document.scrollingElement}function yq(e){const t={x:0,y:0},r=bq(e)?{height:window.innerHeight,width:window.innerWidth}:{height:e.clientHeight,width:e.clientWidth},n={x:e.scrollWidth-r.width,y:e.scrollHeight-r.height},o=e.scrollTop<=t.y,i=e.scrollLeft<=t.x,a=e.scrollTop>=n.y,s=e.scrollLeft>=n.x;return{isTop:o,isLeft:i,isBottom:a,isRight:s,maxScroll:n,minScroll:t}}const J7={x:.2,y:.2};function Q7(e,t,r,n,o){let{top:i,left:a,right:s,bottom:c}=r;n===void 0&&(n=10),o===void 0&&(o=J7);const{isTop:u,isBottom:d,isLeft:f,isRight:h}=yq(e),v={x:0,y:0},b={x:0,y:0},g={height:t.height*o.y,width:t.width*o.x};return!u&&i<=t.top+g.height?(v.y=Jt.Backward,b.y=n*Math.abs((t.top+g.height-i)/g.height)):!d&&c>=t.bottom-g.height&&(v.y=Jt.Forward,b.y=n*Math.abs((t.bottom-g.height-c)/g.height)),!h&&s>=t.right-g.width?(v.x=Jt.Forward,b.x=n*Math.abs((t.right-g.width-s)/g.width)):!f&&a<=t.left+g.width&&(v.x=Jt.Backward,b.x=n*Math.abs((t.left+g.width-a)/g.width)),{direction:v,speed:b}}function e9(e){if(e===document.scrollingElement){const{innerWidth:i,innerHeight:a}=window;return{top:0,left:0,right:i,bottom:a,width:i,height:a}}const{top:t,left:r,right:n,bottom:o}=e.getBoundingClientRect();return{top:t,left:r,right:n,bottom:o,width:e.clientWidth,height:e.clientHeight}}function xq(e){return e.reduce((t,r)=>pa(t,i_(r)),Pn)}function t9(e){return e.reduce((t,r)=>t+gq(r),0)}function r9(e){return e.reduce((t,r)=>t+mq(r),0)}function wq(e,t){if(t===void 0&&(t=La),!e)return;const{top:r,left:n,bottom:o,right:i}=t(e);vq(e)&&(o<=0||i<=0||r>=window.innerHeight||n>=window.innerWidth)&&e.scrollIntoView({block:"center",inline:"center"})}const n9=[["x",["left","right"],t9],["y",["top","bottom"],r9]];class J_{constructor(t,r){this.rect=void 0,this.width=void 0,this.height=void 0,this.top=void 0,this.bottom=void 0,this.right=void 0,this.left=void 0;const n=Z_(r),o=xq(n);this.rect={...t},this.width=t.width,this.height=t.height;for(const[i,a,s]of n9)for(const c of a)Object.defineProperty(this,c,{get:()=>{const u=s(n),d=o[i]-u;return this.rect[c]+d},enumerable:!0});Object.defineProperty(this,"rect",{enumerable:!1})}}class Gs{constructor(t){this.target=void 0,this.listeners=[],this.removeAll=()=>{this.listeners.forEach(r=>{var n;return(n=this.target)==null?void 0:n.removeEventListener(...r)})},this.target=t}add(t,r,n){var o;(o=this.target)==null||o.addEventListener(t,r,n),this.listeners.push([t,r,n])}}function o9(e){const{EventTarget:t}=xr(e);return e instanceof t?e:ja(e)}function ph(e,t){const r=Math.abs(e.x),n=Math.abs(e.y);return typeof t=="number"?Math.sqrt(r**2+n**2)>t:"x"in t&&"y"in t?r>t.x&&n>t.y:"x"in t?r>t.x:"y"in t?n>t.y:!1}var sn;(function(e){e.Click="click",e.DragStart="dragstart",e.Keydown="keydown",e.ContextMenu="contextmenu",e.Resize="resize",e.SelectionChange="selectionchange",e.VisibilityChange="visibilitychange"})(sn||(sn={}));function yC(e){e.preventDefault()}function i9(e){e.stopPropagation()}var nt;(function(e){e.Space="Space",e.Down="ArrowDown",e.Right="ArrowRight",e.Left="ArrowLeft",e.Up="ArrowUp",e.Esc="Escape",e.Enter="Enter",e.Tab="Tab"})(nt||(nt={}));const _q={start:[nt.Space,nt.Enter],cancel:[nt.Esc],end:[nt.Space,nt.Enter,nt.Tab]},a9=(e,t)=>{let{currentCoordinates:r}=t;switch(e.code){case nt.Right:return{...r,x:r.x+25};case nt.Left:return{...r,x:r.x-25};case nt.Down:return{...r,y:r.y+25};case nt.Up:return{...r,y:r.y-25}}};class Eq{constructor(t){this.props=void 0,this.autoScrollEnabled=!1,this.referenceCoordinates=void 0,this.listeners=void 0,this.windowListeners=void 0,this.props=t;const{event:{target:r}}=t;this.props=t,this.listeners=new Gs(ja(r)),this.windowListeners=new Gs(xr(r)),this.handleKeyDown=this.handleKeyDown.bind(this),this.handleCancel=this.handleCancel.bind(this),this.attach()}attach(){this.handleStart(),this.windowListeners.add(sn.Resize,this.handleCancel),this.windowListeners.add(sn.VisibilityChange,this.handleCancel),setTimeout(()=>this.listeners.add(sn.Keydown,this.handleKeyDown))}handleStart(){const{activeNode:t,onStart:r}=this.props,n=t.node.current;n&&wq(n),r(Pn)}handleKeyDown(t){if(Dd(t)){const{active:r,context:n,options:o}=this.props,{keyboardCodes:i=_q,coordinateGetter:a=a9,scrollBehavior:s="smooth"}=o,{code:c}=t;if(i.end.includes(c)){this.handleEnd(t);return}if(i.cancel.includes(c)){this.handleCancel(t);return}const{collisionRect:u}=n.current,d=u?{x:u.left,y:u.top}:Pn;this.referenceCoordinates||(this.referenceCoordinates=d);const f=a(t,{active:r,context:n.current,currentCoordinates:d});if(f){const h=Ku(f,d),v={x:0,y:0},{scrollableAncestors:b}=n.current;for(const g of b){const m=t.code,{isTop:x,isRight:w,isLeft:E,isBottom:S,maxScroll:_,minScroll:C}=yq(g),N=e9(g),P={x:Math.min(m===nt.Right?N.right-N.width/2:N.right,Math.max(m===nt.Right?N.left:N.left+N.width/2,f.x)),y:Math.min(m===nt.Down?N.bottom-N.height/2:N.bottom,Math.max(m===nt.Down?N.top:N.top+N.height/2,f.y))},A=m===nt.Right&&!w||m===nt.Left&&!E,j=m===nt.Down&&!S||m===nt.Up&&!x;if(A&&P.x!==f.x){const M=g.scrollLeft+h.x,L=m===nt.Right&&M<=_.x||m===nt.Left&&M>=C.x;if(L&&!h.y){g.scrollTo({left:M,behavior:s});return}L?v.x=g.scrollLeft-M:v.x=m===nt.Right?g.scrollLeft-_.x:g.scrollLeft-C.x,v.x&&g.scrollBy({left:-v.x,behavior:s});break}else if(j&&P.y!==f.y){const M=g.scrollTop+h.y,L=m===nt.Down&&M<=_.y||m===nt.Up&&M>=C.y;if(L&&!h.x){g.scrollTo({top:M,behavior:s});return}L?v.y=g.scrollTop-M:v.y=m===nt.Down?g.scrollTop-_.y:g.scrollTop-C.y,v.y&&g.scrollBy({top:-v.y,behavior:s});break}}this.handleMove(t,pa(Ku(f,this.referenceCoordinates),v))}}}handleMove(t,r){const{onMove:n}=this.props;t.preventDefault(),n(r)}handleEnd(t){const{onEnd:r}=this.props;t.preventDefault(),this.detach(),r()}handleCancel(t){const{onCancel:r}=this.props;t.preventDefault(),this.detach(),r()}detach(){this.listeners.removeAll(),this.windowListeners.removeAll()}}Eq.activators=[{eventName:"onKeyDown",handler:(e,t,r)=>{let{keyboardCodes:n=_q,onActivation:o}=t,{active:i}=r;const{code:a}=e.nativeEvent;if(n.start.includes(a)){const s=i.activatorNode.current;return s&&e.target!==s?!1:(e.preventDefault(),o==null||o({event:e.nativeEvent}),!0)}return!1}}];function xC(e){return!!(e&&"distance"in e)}function wC(e){return!!(e&&"delay"in e)}class Q_{constructor(t,r,n){var o;n===void 0&&(n=o9(t.event.target)),this.props=void 0,this.events=void 0,this.autoScrollEnabled=!0,this.document=void 0,this.activated=!1,this.initialCoordinates=void 0,this.timeoutId=null,this.listeners=void 0,this.documentListeners=void 0,this.windowListeners=void 0,this.props=t,this.events=r;const{event:i}=t,{target:a}=i;this.props=t,this.events=r,this.document=ja(a),this.documentListeners=new Gs(this.document),this.listeners=new Gs(n),this.windowListeners=new Gs(xr(a)),this.initialCoordinates=(o=Xu(i))!=null?o:Pn,this.handleStart=this.handleStart.bind(this),this.handleMove=this.handleMove.bind(this),this.handleEnd=this.handleEnd.bind(this),this.handleCancel=this.handleCancel.bind(this),this.handleKeydown=this.handleKeydown.bind(this),this.removeTextSelection=this.removeTextSelection.bind(this),this.attach()}attach(){const{events:t,props:{options:{activationConstraint:r,bypassActivationConstraint:n}}}=this;if(this.listeners.add(t.move.name,this.handleMove,{passive:!1}),this.listeners.add(t.end.name,this.handleEnd),t.cancel&&this.listeners.add(t.cancel.name,this.handleCancel),this.windowListeners.add(sn.Resize,this.handleCancel),this.windowListeners.add(sn.DragStart,yC),this.windowListeners.add(sn.VisibilityChange,this.handleCancel),this.windowListeners.add(sn.ContextMenu,yC),this.documentListeners.add(sn.Keydown,this.handleKeydown),r){if(n!=null&&n({event:this.props.event,activeNode:this.props.activeNode,options:this.props.options}))return this.handleStart();if(wC(r)){this.timeoutId=setTimeout(this.handleStart,r.delay),this.handlePending(r);return}if(xC(r)){this.handlePending(r);return}}this.handleStart()}detach(){this.listeners.removeAll(),this.windowListeners.removeAll(),setTimeout(this.documentListeners.removeAll,50),this.timeoutId!==null&&(clearTimeout(this.timeoutId),this.timeoutId=null)}handlePending(t,r){const{active:n,onPending:o}=this.props;o(n,t,this.initialCoordinates,r)}handleStart(){const{initialCoordinates:t}=this,{onStart:r}=this.props;t&&(this.activated=!0,this.documentListeners.add(sn.Click,i9,{capture:!0}),this.removeTextSelection(),this.documentListeners.add(sn.SelectionChange,this.removeTextSelection),r(t))}handleMove(t){var r;const{activated:n,initialCoordinates:o,props:i}=this,{onMove:a,options:{activationConstraint:s}}=i;if(!o)return;const c=(r=Xu(t))!=null?r:Pn,u=Ku(o,c);if(!n&&s){if(xC(s)){if(s.tolerance!=null&&ph(u,s.tolerance))return this.handleCancel();if(ph(u,s.distance))return this.handleStart()}if(wC(s)&&ph(u,s.tolerance))return this.handleCancel();this.handlePending(s,u);return}t.cancelable&&t.preventDefault(),a(c)}handleEnd(){const{onAbort:t,onEnd:r}=this.props;this.detach(),this.activated||t(this.props.active),r()}handleCancel(){const{onAbort:t,onCancel:r}=this.props;this.detach(),this.activated||t(this.props.active),r()}handleKeydown(t){t.code===nt.Esc&&this.handleCancel()}removeTextSelection(){var t;(t=this.document.getSelection())==null||t.removeAllRanges()}}const s9={cancel:{name:"pointercancel"},move:{name:"pointermove"},end:{name:"pointerup"}};class e1 extends Q_{constructor(t){const{event:r}=t,n=ja(r.target);super(t,s9,n)}}e1.activators=[{eventName:"onPointerDown",handler:(e,t)=>{let{nativeEvent:r}=e,{onActivation:n}=t;return!r.isPrimary||r.button!==0?!1:(n==null||n({event:r}),!0)}}];const l9={move:{name:"mousemove"},end:{name:"mouseup"}};var a_;(function(e){e[e.RightClick=2]="RightClick"})(a_||(a_={}));class c9 extends Q_{constructor(t){super(t,l9,ja(t.event.target))}}c9.activators=[{eventName:"onMouseDown",handler:(e,t)=>{let{nativeEvent:r}=e,{onActivation:n}=t;return r.button===a_.RightClick?!1:(n==null||n({event:r}),!0)}}];const hh={cancel:{name:"touchcancel"},move:{name:"touchmove"},end:{name:"touchend"}};class u9 extends Q_{constructor(t){super(t,hh)}static setup(){return window.addEventListener(hh.move.name,t,{capture:!1,passive:!1}),function(){window.removeEventListener(hh.move.name,t)};function t(){}}}u9.activators=[{eventName:"onTouchStart",handler:(e,t)=>{let{nativeEvent:r}=e,{onActivation:n}=t;const{touches:o}=r;return o.length>1?!1:(n==null||n({event:r}),!0)}}];var Ys;(function(e){e[e.Pointer=0]="Pointer",e[e.DraggableRect=1]="DraggableRect"})(Ys||(Ys={}));var Ju;(function(e){e[e.TreeOrder=0]="TreeOrder",e[e.ReversedTreeOrder=1]="ReversedTreeOrder"})(Ju||(Ju={}));function d9(e){let{acceleration:t,activator:r=Ys.Pointer,canScroll:n,draggingRect:o,enabled:i,interval:a=5,order:s=Ju.TreeOrder,pointerCoordinates:c,scrollableAncestors:u,scrollableAncestorRects:d,delta:f,threshold:h}=e;const v=p9({delta:f,disabled:!i}),[b,g]=w7(),m=R.useRef({x:0,y:0}),x=R.useRef({x:0,y:0}),w=R.useMemo(()=>{switch(r){case Ys.Pointer:return c?{top:c.y,bottom:c.y,left:c.x,right:c.x}:null;case Ys.DraggableRect:return o}},[r,o,c]),E=R.useRef(null),S=R.useCallback(()=>{const C=E.current;if(!C)return;const N=m.current.x*x.current.x,P=m.current.y*x.current.y;C.scrollBy(N,P)},[]),_=R.useMemo(()=>s===Ju.TreeOrder?[...u].reverse():u,[s,u]);R.useEffect(()=>{if(!i||!u.length||!w){g();return}for(const C of _){if((n==null?void 0:n(C))===!1)continue;const N=u.indexOf(C),P=d[N];if(!P)continue;const{direction:A,speed:j}=Q7(C,P,w,t,h);for(const M of["x","y"])v[M][A[M]]||(j[M]=0,A[M]=0);if(j.x>0||j.y>0){g(),E.current=C,b(S,a),m.current=j,x.current=A;return}}m.current={x:0,y:0},x.current={x:0,y:0},g()},[t,S,n,g,i,a,JSON.stringify(w),JSON.stringify(v),b,u,_,d,JSON.stringify(h)])}const f9={x:{[Jt.Backward]:!1,[Jt.Forward]:!1},y:{[Jt.Backward]:!1,[Jt.Forward]:!1}};function p9(e){let{delta:t,disabled:r}=e;const n=Yu(t);return xl(o=>{if(r||!n||!o)return f9;const i={x:Math.sign(t.x-n.x),y:Math.sign(t.y-n.y)};return{x:{[Jt.Backward]:o.x[Jt.Backward]||i.x===-1,[Jt.Forward]:o.x[Jt.Forward]||i.x===1},y:{[Jt.Backward]:o.y[Jt.Backward]||i.y===-1,[Jt.Forward]:o.y[Jt.Forward]||i.y===1}}},[r,t,n])}function h9(e,t){const r=t!=null?e.get(t):void 0,n=r?r.node.current:null;return xl(o=>{var i;return t==null?null:(i=n??o)!=null?i:null},[n,t])}function v9(e,t){return R.useMemo(()=>e.reduce((r,n)=>{const{sensor:o}=n,i=o.activators.map(a=>({eventName:a.eventName,handler:t(a.handler,n)}));return[...r,...i]},[]),[e,t])}var il;(function(e){e[e.Always=0]="Always",e[e.BeforeDragging=1]="BeforeDragging",e[e.WhileDragging=2]="WhileDragging"})(il||(il={}));var s_;(function(e){e.Optimized="optimized"})(s_||(s_={}));const _C=new Map;function g9(e,t){let{dragging:r,dependencies:n,config:o}=t;const[i,a]=R.useState(null),{frequency:s,measure:c,strategy:u}=o,d=R.useRef(e),f=m(),h=ol(f),v=R.useCallback(function(x){x===void 0&&(x=[]),!h.current&&a(w=>w===null?x:w.concat(x.filter(E=>!w.includes(E))))},[h]),b=R.useRef(null),g=xl(x=>{if(f&&!r)return _C;if(!x||x===_C||d.current!==e||i!=null){const w=new Map;for(let E of e){if(!E)continue;if(i&&i.length>0&&!i.includes(E.id)&&E.rect.current){w.set(E.id,E.rect.current);continue}const S=E.node.current,_=S?new J_(c(S),S):null;E.rect.current=_,_&&w.set(E.id,_)}return w}return x},[e,i,r,f,c]);return R.useEffect(()=>{d.current=e},[e]),R.useEffect(()=>{f||v()},[r,f]),R.useEffect(()=>{i&&i.length>0&&a(null)},[JSON.stringify(i)]),R.useEffect(()=>{f||typeof s!="number"||b.current!==null||(b.current=setTimeout(()=>{v(),b.current=null},s))},[s,f,v,...n]),{droppableRects:g,measureDroppableContainers:v,measuringScheduled:i!=null};function m(){switch(u){case il.Always:return!1;case il.BeforeDragging:return r;default:return!r}}}function t1(e,t){return xl(r=>e?r||(typeof t=="function"?t(e):e):null,[t,e])}function m9(e,t){return t1(e,t)}function b9(e){let{callback:t,disabled:r}=e;const n=kd(t),o=R.useMemo(()=>{if(r||typeof window>"u"||typeof window.MutationObserver>"u")return;const{MutationObserver:i}=window;return new i(n)},[n,r]);return R.useEffect(()=>()=>o==null?void 0:o.disconnect(),[o]),o}function Md(e){let{callback:t,disabled:r}=e;const n=kd(t),o=R.useMemo(()=>{if(r||typeof window>"u"||typeof window.ResizeObserver>"u")return;const{ResizeObserver:i}=window;return new i(n)},[r]);return R.useEffect(()=>()=>o==null?void 0:o.disconnect(),[o]),o}function y9(e){return new J_(La(e),e)}function EC(e,t,r){t===void 0&&(t=y9);const[n,o]=R.useState(null);function i(){o(c=>{if(!e)return null;if(e.isConnected===!1){var u;return(u=c??r)!=null?u:null}const d=t(e);return JSON.stringify(c)===JSON.stringify(d)?c:d})}const a=b9({callback(c){if(e)for(const u of c){const{type:d,target:f}=u;if(d==="childList"&&f instanceof HTMLElement&&f.contains(e)){i();break}}}}),s=Md({callback:i});return In(()=>{i(),e?(s==null||s.observe(e),a==null||a.observe(document.body,{childList:!0,subtree:!0})):(s==null||s.disconnect(),a==null||a.disconnect())},[e]),n}function x9(e){const t=t1(e);return pq(e,t)}const SC=[];function w9(e){const t=R.useRef(e),r=xl(n=>e?n&&n!==SC&&e&&t.current&&e.parentNode===t.current.parentNode?n:Z_(e):SC,[e]);return R.useEffect(()=>{t.current=e},[e]),r}function _9(e){const[t,r]=R.useState(null),n=R.useRef(e),o=R.useCallback(i=>{const a=fh(i.target);a&&r(s=>s?(s.set(a,i_(a)),new Map(s)):null)},[]);return R.useEffect(()=>{const i=n.current;if(e!==i){a(i);const s=e.map(c=>{const u=fh(c);return u?(u.addEventListener("scroll",o,{passive:!0}),[u,i_(u)]):null}).filter(c=>c!=null);r(s.length?new Map(s):null),n.current=e}return()=>{a(e),a(i)};function a(s){s.forEach(c=>{const u=fh(c);u==null||u.removeEventListener("scroll",o)})}},[o,e]),R.useMemo(()=>e.length?t?Array.from(t.values()).reduce((i,a)=>pa(i,a),Pn):xq(e):Pn,[e,t])}function OC(e,t){t===void 0&&(t=[]);const r=R.useRef(null);return R.useEffect(()=>{r.current=null},t),R.useEffect(()=>{const n=e!==Pn;n&&!r.current&&(r.current=e),!n&&r.current&&(r.current=null)},[e]),r.current?Ku(e,r.current):Pn}function E9(e){R.useEffect(()=>{if(!Ad)return;const t=e.map(r=>{let{sensor:n}=r;return n.setup==null?void 0:n.setup()});return()=>{for(const r of t)r==null||r()}},e.map(t=>{let{sensor:r}=t;return r}))}function S9(e,t){return R.useMemo(()=>e.reduce((r,n)=>{let{eventName:o,handler:i}=n;return r[o]=a=>{i(a,t)},r},{}),[e,t])}function Sq(e){return R.useMemo(()=>e?K7(e):null,[e])}const CC=[];function O9(e,t){t===void 0&&(t=La);const[r]=e,n=Sq(r?xr(r):null),[o,i]=R.useState(CC);function a(){i(()=>e.length?e.map(c=>bq(c)?n:new J_(t(c),c)):CC)}const s=Md({callback:a});return In(()=>{s==null||s.disconnect(),a(),e.forEach(c=>s==null?void 0:s.observe(c))},[e]),o}function Oq(e){if(!e)return null;if(e.children.length>1)return e;const t=e.children[0];return yl(t)?t:e}function C9(e){let{measure:t}=e;const[r,n]=R.useState(null),o=R.useCallback(u=>{for(const{target:d}of u)if(yl(d)){n(f=>{const h=t(d);return f?{...f,width:h.width,height:h.height}:h});break}},[t]),i=Md({callback:o}),a=R.useCallback(u=>{const d=Oq(u);i==null||i.disconnect(),d&&(i==null||i.observe(d)),n(d?t(d):null)},[t,i]),[s,c]=Gu(a);return R.useMemo(()=>({nodeRef:s,rect:r,setRef:c}),[r,s,c])}const R9=[{sensor:e1,options:{}},{sensor:Eq,options:{}}],N9={current:{}},Cu={draggable:{measure:bC},droppable:{measure:bC,strategy:il.WhileDragging,frequency:s_.Optimized},dragOverlay:{measure:La}};class Ks extends Map{get(t){var r;return t!=null&&(r=super.get(t))!=null?r:void 0}toArray(){return Array.from(this.values())}getEnabled(){return this.toArray().filter(t=>{let{disabled:r}=t;return!r})}getNodeFor(t){var r,n;return(r=(n=this.get(t))==null?void 0:n.node.current)!=null?r:void 0}}const I9={activatorEvent:null,active:null,activeNode:null,activeNodeRect:null,collisions:null,containerNodeRect:null,draggableNodes:new Map,droppableRects:new Map,droppableContainers:new Ks,over:null,dragOverlay:{nodeRef:{current:null},rect:null,setRef:Zu},scrollableAncestors:[],scrollableAncestorRects:[],measuringConfiguration:Cu,measureDroppableContainers:Zu,windowRect:null,measuringScheduled:!1},Cq={activatorEvent:null,activators:[],active:null,activeNodeRect:null,ariaDescribedById:{draggable:""},dispatch:Zu,draggableNodes:new Map,over:null,measureDroppableContainers:Zu},_l=R.createContext(Cq),Rq=R.createContext(I9);function P9(){return{draggable:{active:null,initialCoordinates:{x:0,y:0},nodes:new Map,translate:{x:0,y:0}},droppable:{containers:new Ks}}}function T9(e,t){switch(t.type){case Gt.DragStart:return{...e,draggable:{...e.draggable,initialCoordinates:t.initialCoordinates,active:t.active}};case Gt.DragMove:return e.draggable.active==null?e:{...e,draggable:{...e.draggable,translate:{x:t.coordinates.x-e.draggable.initialCoordinates.x,y:t.coordinates.y-e.draggable.initialCoordinates.y}}};case Gt.DragEnd:case Gt.DragCancel:return{...e,draggable:{...e.draggable,active:null,initialCoordinates:{x:0,y:0},translate:{x:0,y:0}}};case Gt.RegisterDroppable:{const{element:r}=t,{id:n}=r,o=new Ks(e.droppable.containers);return o.set(n,r),{...e,droppable:{...e.droppable,containers:o}}}case Gt.SetDroppableDisabled:{const{id:r,key:n,disabled:o}=t,i=e.droppable.containers.get(r);if(!i||n!==i.key)return e;const a=new Ks(e.droppable.containers);return a.set(r,{...i,disabled:o}),{...e,droppable:{...e.droppable,containers:a}}}case Gt.UnregisterDroppable:{const{id:r,key:n}=t,o=e.droppable.containers.get(r);if(!o||n!==o.key)return e;const i=new Ks(e.droppable.containers);return i.delete(r),{...e,droppable:{...e.droppable,containers:i}}}default:return e}}function A9(e){let{disabled:t}=e;const{active:r,activatorEvent:n,draggableNodes:o}=R.useContext(_l),i=Yu(n),a=Yu(r==null?void 0:r.id);return R.useEffect(()=>{if(!t&&!n&&i&&a!=null){if(!Dd(i)||document.activeElement===i.target)return;const s=o.get(a);if(!s)return;const{activatorNode:c,node:u}=s;if(!c.current&&!u.current)return;requestAnimationFrame(()=>{for(const d of[c.current,u.current]){if(!d)continue;const f=S7(d);if(f){f.focus();break}}})}},[n,t,o,a,i]),null}function Nq(e,t){let{transform:r,...n}=t;return e!=null&&e.length?e.reduce((o,i)=>i({transform:o,...n}),r):r}function k9(e){return R.useMemo(()=>({draggable:{...Cu.draggable,...e==null?void 0:e.draggable},droppable:{...Cu.droppable,...e==null?void 0:e.droppable},dragOverlay:{...Cu.dragOverlay,...e==null?void 0:e.dragOverlay}}),[e==null?void 0:e.draggable,e==null?void 0:e.droppable,e==null?void 0:e.dragOverlay])}function D9(e){let{activeNode:t,measure:r,initialRect:n,config:o=!0}=e;const i=R.useRef(!1),{x:a,y:s}=typeof o=="boolean"?{x:o,y:o}:o;In(()=>{if(!a&&!s||!t){i.current=!1;return}if(i.current||!n)return;const c=t==null?void 0:t.node.current;if(!c||c.isConnected===!1)return;const u=r(c),d=pq(u,n);if(a||(d.x=0),s||(d.y=0),i.current=!0,Math.abs(d.x)>0||Math.abs(d.y)>0){const f=vq(c);f&&f.scrollBy({top:d.y,left:d.x})}},[t,a,s,n,r])}const jd=R.createContext({...Pn,scaleX:1,scaleY:1});var Vo;(function(e){e[e.Uninitialized=0]="Uninitialized",e[e.Initializing=1]="Initializing",e[e.Initialized=2]="Initialized"})(Vo||(Vo={}));const M9=R.memo(function(e){var t,r,n,o;let{id:i,accessibility:a,autoScroll:s=!0,children:c,sensors:u=R9,collisionDetection:d=V7,measuring:f,modifiers:h,...v}=e;const b=R.useReducer(T9,void 0,P9),[g,m]=b,[x,w]=P7(),[E,S]=R.useState(Vo.Uninitialized),_=E===Vo.Initialized,{draggable:{active:C,nodes:N,translate:P},droppable:{containers:A}}=g,j=C!=null?N.get(C):null,M=R.useRef({initial:null,translated:null}),L=R.useMemo(()=>{var $t;return C!=null?{id:C,data:($t=j==null?void 0:j.data)!=null?$t:N9,rect:M}:null},[C,j]),D=R.useRef(null),[T,W]=R.useState(null),[q,G]=R.useState(null),F=ol(v,Object.values(v)),J=wl("DndDescribedBy",i),z=R.useMemo(()=>A.getEnabled(),[A]),U=k9(f),{droppableRects:oe,measureDroppableContainers:re,measuringScheduled:$}=g9(z,{dragging:_,dependencies:[P.x,P.y],config:U.droppable}),Y=h9(N,C),X=R.useMemo(()=>q?Xu(q):null,[q]),H=Ka(),K=m9(Y,U.draggable.measure);D9({activeNode:C!=null?N.get(C):null,config:H.layoutShiftCompensation,initialRect:K,measure:U.draggable.measure});const Q=EC(Y,U.draggable.measure,K),ne=EC(Y?Y.parentElement:null),se=R.useRef({activatorEvent:null,active:null,activeNode:Y,collisionRect:null,collisions:null,droppableRects:oe,draggableNodes:N,draggingNode:null,draggingNodeRect:null,droppableContainers:A,over:null,scrollableAncestors:[],scrollAdjustedTranslate:null}),te=A.getNodeFor((t=se.current.over)==null?void 0:t.id),be=C9({measure:U.dragOverlay.measure}),de=(r=be.nodeRef.current)!=null?r:Y,Ee=_?(n=be.rect)!=null?n:Q:null,fe=!!(be.nodeRef.current&&be.rect),le=x9(fe?null:Q),Ce=Sq(de?xr(de):null),Te=w9(_?te??Y:null),Fe=O9(Te),Le=Nq(h,{transform:{x:P.x-le.x,y:P.y-le.y,scaleX:1,scaleY:1},activatorEvent:q,active:L,activeNodeRect:Q,containerNodeRect:ne,draggingNodeRect:Ee,over:se.current.over,overlayNodeRect:be.rect,scrollableAncestors:Te,scrollableAncestorRects:Fe,windowRect:Ce}),Ze=X?pa(X,P):null,We=_9(Te),St=OC(We),tt=OC(We,[Q]),wt=pa(Le,St),Je=Ee?U7(Ee,Le):null,Ne=L&&Je?d({active:L,collisionRect:Je,droppableRects:oe,droppableContainers:z,pointerCoordinates:Ze}):null,je=B7(Ne,"id"),[Qe,At]=R.useState(null),It=fe?Le:pa(Le,tt),mt=H7(It,(o=Qe==null?void 0:Qe.rect)!=null?o:null,Q),Rt=R.useRef(null),Qt=R.useCallback(($t,Vt)=>{let{sensor:er,options:jr}=Vt;if(D.current==null)return;const sr=N.get(D.current);if(!sr)return;const Kt=$t.nativeEvent,hr=new er({active:D.current,activeNode:sr,event:Kt,options:jr,context:se,onAbort(kt){if(!N.get(kt))return;const{onDragAbort:tr}=F.current,vr={id:kt};tr==null||tr(vr),x({type:"onDragAbort",event:vr})},onPending(kt,tr,vr,yn){if(!N.get(kt))return;const{onDragPending:Sr}=F.current,Lr={id:kt,constraint:tr,initialCoordinates:vr,offset:yn};Sr==null||Sr(Lr),x({type:"onDragPending",event:Lr})},onStart(kt){const tr=D.current;if(tr==null)return;const vr=N.get(tr);if(!vr)return;const{onDragStart:yn}=F.current,Sr={activatorEvent:Kt,active:{id:tr,data:vr.data,rect:M}};mo.unstable_batchedUpdates(()=>{yn==null||yn(Sr),S(Vo.Initializing),m({type:Gt.DragStart,initialCoordinates:kt,active:tr}),x({type:"onDragStart",event:Sr}),W(Rt.current),G(Kt)})},onMove(kt){m({type:Gt.DragMove,coordinates:kt})},onEnd:Ln(Gt.DragEnd),onCancel:Ln(Gt.DragCancel)});Rt.current=hr;function Ln(kt){return async function(){const{active:tr,collisions:vr,over:yn,scrollAdjustedTranslate:Sr}=se.current;let Lr=null;if(tr&&Sr){const{cancelDrop:no}=F.current;Lr={activatorEvent:Kt,active:tr,collisions:vr,delta:Sr,over:yn},kt===Gt.DragEnd&&typeof no=="function"&&await Promise.resolve(no(Lr))&&(kt=Gt.DragCancel)}D.current=null,mo.unstable_batchedUpdates(()=>{m({type:kt}),S(Vo.Uninitialized),At(null),W(null),G(null),Rt.current=null;const no=kt===Gt.DragEnd?"onDragEnd":"onDragCancel";if(Lr){const ti=F.current[no];ti==null||ti(Lr),x({type:no,event:Lr})}})}}},[N]),fr=R.useCallback(($t,Vt)=>(er,jr)=>{const sr=er.nativeEvent,Kt=N.get(jr);if(D.current!==null||!Kt||sr.dndKit||sr.defaultPrevented)return;const hr={active:Kt};$t(er,Vt.options,hr)===!0&&(sr.dndKit={capturedBy:Vt.sensor},D.current=jr,Qt(er,Vt))},[N,Qt]),pr=v9(u,fr);E9(u),In(()=>{Q&&E===Vo.Initializing&&S(Vo.Initialized)},[Q,E]),R.useEffect(()=>{const{onDragMove:$t}=F.current,{active:Vt,activatorEvent:er,collisions:jr,over:sr}=se.current;if(!Vt||!er)return;const Kt={active:Vt,activatorEvent:er,collisions:jr,delta:{x:wt.x,y:wt.y},over:sr};mo.unstable_batchedUpdates(()=>{$t==null||$t(Kt),x({type:"onDragMove",event:Kt})})},[wt.x,wt.y]),R.useEffect(()=>{const{active:$t,activatorEvent:Vt,collisions:er,droppableContainers:jr,scrollAdjustedTranslate:sr}=se.current;if(!$t||D.current==null||!Vt||!sr)return;const{onDragOver:Kt}=F.current,hr=jr.get(je),Ln=hr&&hr.rect.current?{id:hr.id,rect:hr.rect.current,data:hr.data,disabled:hr.disabled}:null,kt={active:$t,activatorEvent:Vt,collisions:er,delta:{x:sr.x,y:sr.y},over:Ln};mo.unstable_batchedUpdates(()=>{At(Ln),Kt==null||Kt(kt),x({type:"onDragOver",event:kt})})},[je]),In(()=>{se.current={activatorEvent:q,active:L,activeNode:Y,collisionRect:Je,collisions:Ne,droppableRects:oe,draggableNodes:N,draggingNode:de,draggingNodeRect:Ee,droppableContainers:A,over:Qe,scrollableAncestors:Te,scrollAdjustedTranslate:wt},M.current={initial:Ee,translated:Je}},[L,Y,Ne,Je,N,de,Ee,oe,A,Qe,Te,wt]),d9({...H,delta:P,draggingRect:Je,pointerCoordinates:Ze,scrollableAncestors:Te,scrollableAncestorRects:Fe});const Xr=R.useMemo(()=>({active:L,activeNode:Y,activeNodeRect:Q,activatorEvent:q,collisions:Ne,containerNodeRect:ne,dragOverlay:be,draggableNodes:N,droppableContainers:A,droppableRects:oe,over:Qe,measureDroppableContainers:re,scrollableAncestors:Te,scrollableAncestorRects:Fe,measuringConfiguration:U,measuringScheduled:$,windowRect:Ce}),[L,Y,Q,q,Ne,ne,be,N,A,oe,Qe,re,Te,Fe,U,$,Ce]),Co=R.useMemo(()=>({activatorEvent:q,activators:pr,active:L,activeNodeRect:Q,ariaDescribedById:{draggable:J},dispatch:m,draggableNodes:N,over:Qe,measureDroppableContainers:re}),[q,pr,L,Q,m,J,N,Qe,re]);return R.createElement(fq.Provider,{value:w},R.createElement(_l.Provider,{value:Co},R.createElement(Rq.Provider,{value:Xr},R.createElement(jd.Provider,{value:mt},c)),R.createElement(A9,{disabled:(a==null?void 0:a.restoreFocus)===!1})),R.createElement(k7,{...a,hiddenTextDescribedById:J}));function Ka(){const $t=(T==null?void 0:T.autoScrollEnabled)===!1,Vt=typeof s=="object"?s.enabled===!1:s===!1,er=_&&!$t&&!Vt;return typeof s=="object"?{...s,enabled:er}:{enabled:er}}}),j9=R.createContext(null),RC="button",L9="Draggable";function q9(e){let{id:t,data:r,disabled:n=!1,attributes:o}=e;const i=wl(L9),{activators:a,activatorEvent:s,active:c,activeNodeRect:u,ariaDescribedById:d,draggableNodes:f,over:h}=R.useContext(_l),{role:v=RC,roleDescription:b="draggable",tabIndex:g=0}=o??{},m=(c==null?void 0:c.id)===t,x=R.useContext(m?jd:j9),[w,E]=Gu(),[S,_]=Gu(),C=S9(a,t),N=ol(r);In(()=>(f.set(t,{id:t,key:i,node:w,activatorNode:S,data:N}),()=>{const A=f.get(t);A&&A.key===i&&f.delete(t)}),[f,t]);const P=R.useMemo(()=>({role:v,tabIndex:g,"aria-disabled":n,"aria-pressed":m&&v===RC?!0:void 0,"aria-roledescription":b,"aria-describedby":d.draggable}),[n,v,g,m,b,d.draggable]);return{active:c,activatorEvent:s,activeNodeRect:u,attributes:P,isDragging:m,listeners:n?void 0:C,node:w,over:h,setNodeRef:E,setActivatorNodeRef:_,transform:x}}function Iq(){return R.useContext(Rq)}const z9="Droppable",B9={timeout:25};function F9(e){let{data:t,disabled:r=!1,id:n,resizeObserverConfig:o}=e;const i=wl(z9),{active:a,dispatch:s,over:c,measureDroppableContainers:u}=R.useContext(_l),d=R.useRef({disabled:r}),f=R.useRef(!1),h=R.useRef(null),v=R.useRef(null),{disabled:b,updateMeasurementsFor:g,timeout:m}={...B9,...o},x=ol(g??n),w=R.useCallback(()=>{if(!f.current){f.current=!0;return}v.current!=null&&clearTimeout(v.current),v.current=setTimeout(()=>{u(Array.isArray(x.current)?x.current:[x.current]),v.current=null},m)},[m]),E=Md({callback:w,disabled:b||!a}),S=R.useCallback((P,A)=>{E&&(A&&(E.unobserve(A),f.current=!1),P&&E.observe(P))},[E]),[_,C]=Gu(S),N=ol(t);return R.useEffect(()=>{!E||!_.current||(E.disconnect(),f.current=!1,E.observe(_.current))},[_,E]),R.useEffect(()=>(s({type:Gt.RegisterDroppable,element:{id:n,key:i,disabled:r,node:_,rect:h,data:N}}),()=>s({type:Gt.UnregisterDroppable,key:i,id:n})),[n]),R.useEffect(()=>{r!==d.current.disabled&&(s({type:Gt.SetDroppableDisabled,id:n,key:i,disabled:r}),d.current.disabled=r)},[n,i,r,s]),{active:a,rect:h,isOver:(c==null?void 0:c.id)===n,node:_,over:c,setNodeRef:C}}function $9(e){let{animation:t,children:r}=e;const[n,o]=R.useState(null),[i,a]=R.useState(null),s=Yu(r);return!r&&!n&&s&&o(s),In(()=>{if(!i)return;const c=n==null?void 0:n.key,u=n==null?void 0:n.props.id;if(c==null||u==null){o(null);return}Promise.resolve(t(u,i)).then(()=>{o(null)})},[t,n,i]),R.createElement(R.Fragment,null,r,n?R.cloneElement(n,{ref:a}):null)}const V9={x:0,y:0,scaleX:1,scaleY:1};function H9(e){let{children:t}=e;return R.createElement(_l.Provider,{value:Cq},R.createElement(jd.Provider,{value:V9},t))}const W9={position:"fixed",touchAction:"none"},U9=e=>Dd(e)?"transform 250ms ease":void 0,G9=R.forwardRef((e,t)=>{let{as:r,activatorEvent:n,adjustScale:o,children:i,className:a,rect:s,style:c,transform:u,transition:d=U9}=e;if(!s)return null;const f=o?u:{...u,scaleX:1,scaleY:1},h={...W9,width:s.width,height:s.height,top:s.top,left:s.left,transform:Go.Transform.toString(f),transformOrigin:o&&n?L7(n,s):void 0,transition:typeof d=="function"?d(n):d,...c};return R.createElement(r,{className:a,style:h,ref:t},i)}),Y9=e=>t=>{let{active:r,dragOverlay:n}=t;const o={},{styles:i,className:a}=e;if(i!=null&&i.active)for(const[s,c]of Object.entries(i.active))c!==void 0&&(o[s]=r.node.style.getPropertyValue(s),r.node.style.setProperty(s,c));if(i!=null&&i.dragOverlay)for(const[s,c]of Object.entries(i.dragOverlay))c!==void 0&&n.node.style.setProperty(s,c);return a!=null&&a.active&&r.node.classList.add(a.active),a!=null&&a.dragOverlay&&n.node.classList.add(a.dragOverlay),function(){for(const[s,c]of Object.entries(o))r.node.style.setProperty(s,c);a!=null&&a.active&&r.node.classList.remove(a.active)}},K9=e=>{let{transform:{initial:t,final:r}}=e;return[{transform:Go.Transform.toString(t)},{transform:Go.Transform.toString(r)}]},X9={duration:250,easing:"ease",keyframes:K9,sideEffects:Y9({styles:{active:{opacity:"0"}}})};function Z9(e){let{config:t,draggableNodes:r,droppableContainers:n,measuringConfiguration:o}=e;return kd((i,a)=>{if(t===null)return;const s=r.get(i);if(!s)return;const c=s.node.current;if(!c)return;const u=Oq(a);if(!u)return;const{transform:d}=xr(a).getComputedStyle(a),f=hq(d);if(!f)return;const h=typeof t=="function"?t:J9(t);return wq(c,o.draggable.measure),h({active:{id:i,data:s.data,node:c,rect:o.draggable.measure(c)},draggableNodes:r,dragOverlay:{node:a,rect:o.dragOverlay.measure(u)},droppableContainers:n,measuringConfiguration:o,transform:f})})}function J9(e){const{duration:t,easing:r,sideEffects:n,keyframes:o}={...X9,...e};return i=>{let{active:a,dragOverlay:s,transform:c,...u}=i;if(!t)return;const d={x:s.rect.left-a.rect.left,y:s.rect.top-a.rect.top},f={scaleX:c.scaleX!==1?a.rect.width*c.scaleX/s.rect.width:1,scaleY:c.scaleY!==1?a.rect.height*c.scaleY/s.rect.height:1},h={x:c.x-d.x,y:c.y-d.y,...f},v=o({...u,active:a,dragOverlay:s,transform:{initial:c,final:h}}),[b]=v,g=v[v.length-1];if(JSON.stringify(b)===JSON.stringify(g))return;const m=n==null?void 0:n({active:a,dragOverlay:s,...u}),x=s.node.animate(v,{duration:t,easing:r,fill:"forwards"});return new Promise(w=>{x.onfinish=()=>{m==null||m(),w()}})}}let NC=0;function Q9(e){return R.useMemo(()=>{if(e!=null)return NC++,NC},[e])}const eY=R.memo(e=>{let{adjustScale:t=!1,children:r,dropAnimation:n,style:o,transition:i,modifiers:a,wrapperElement:s="div",className:c,zIndex:u=999}=e;const{activatorEvent:d,active:f,activeNodeRect:h,containerNodeRect:v,draggableNodes:b,droppableContainers:g,dragOverlay:m,over:x,measuringConfiguration:w,scrollableAncestors:E,scrollableAncestorRects:S,windowRect:_}=Iq(),C=R.useContext(jd),N=Q9(f==null?void 0:f.id),P=Nq(a,{activatorEvent:d,active:f,activeNodeRect:h,containerNodeRect:v,draggingNodeRect:m.rect,over:x,overlayNodeRect:m.rect,scrollableAncestors:E,scrollableAncestorRects:S,transform:C,windowRect:_}),A=t1(h),j=Z9({config:n,draggableNodes:b,droppableContainers:g,measuringConfiguration:w}),M=A?m.setRef:void 0;return R.createElement(H9,null,R.createElement($9,{animation:j},f&&N?R.createElement(G9,{key:N,id:f.id,ref:M,as:s,activatorEvent:d,adjustScale:t,className:c,transition:i,rect:A,style:{zIndex:u,...o},transform:P},r):null))});function r1(e,t,r){const n=e.slice();return n.splice(r<0?n.length+r:r,0,n.splice(t,1)[0]),n}function tY(e,t){return e.reduce((r,n,o)=>{const i=t.get(n);return i&&(r[o]=i),r},Array(e.length))}function $c(e){return e!==null&&e>=0}function rY(e,t){if(e===t)return!0;if(e.length!==t.length)return!1;for(let r=0;r<e.length;r++)if(e[r]!==t[r])return!1;return!0}function nY(e){return typeof e=="boolean"?{draggable:e,droppable:e}:e}const Vc={scaleX:1,scaleY:1},oY=e=>{var t;let{rects:r,activeNodeRect:n,activeIndex:o,overIndex:i,index:a}=e;const s=(t=r[o])!=null?t:n;if(!s)return null;const c=iY(r,a,o);if(a===o){const u=r[i];return u?{x:o<i?u.left+u.width-(s.left+s.width):u.left-s.left,y:0,...Vc}:null}return a>o&&a<=i?{x:-s.width-c,y:0,...Vc}:a<o&&a>=i?{x:s.width+c,y:0,...Vc}:{x:0,y:0,...Vc}};function iY(e,t,r){const n=e[t],o=e[t-1],i=e[t+1];return!n||!o&&!i?0:r<t?o?n.left-(o.left+o.width):i.left-(n.left+n.width):i?i.left-(n.left+n.width):n.left-(o.left+o.width)}const Pq=e=>{let{rects:t,activeIndex:r,overIndex:n,index:o}=e;const i=r1(t,n,r),a=t[o],s=i[o];return!s||!a?null:{x:s.left-a.left,y:s.top-a.top,scaleX:s.width/a.width,scaleY:s.height/a.height}},Tq="Sortable",Aq=R.createContext({activeIndex:-1,containerId:Tq,disableTransforms:!1,items:[],overIndex:-1,useDragOverlay:!1,sortedRects:[],strategy:Pq,disabled:{draggable:!1,droppable:!1}});function aY(e){let{children:t,id:r,items:n,strategy:o=Pq,disabled:i=!1}=e;const{active:a,dragOverlay:s,droppableRects:c,over:u,measureDroppableContainers:d}=Iq(),f=wl(Tq,r),h=s.rect!==null,v=R.useMemo(()=>n.map(C=>typeof C=="object"&&"id"in C?C.id:C),[n]),b=a!=null,g=a?v.indexOf(a.id):-1,m=u?v.indexOf(u.id):-1,x=R.useRef(v),w=!rY(v,x.current),E=m!==-1&&g===-1||w,S=nY(i);In(()=>{w&&b&&d(v)},[w,v,b,d]),R.useEffect(()=>{x.current=v},[v]);const _=R.useMemo(()=>({activeIndex:g,containerId:f,disabled:S,disableTransforms:E,items:v,overIndex:m,useDragOverlay:h,sortedRects:tY(v,c),strategy:o}),[g,f,S.draggable,S.droppable,E,v,m,c,h,o]);return R.createElement(Aq.Provider,{value:_},t)}const sY=e=>{let{id:t,items:r,activeIndex:n,overIndex:o}=e;return r1(r,n,o).indexOf(t)},lY=e=>{let{containerId:t,isSorting:r,wasDragging:n,index:o,items:i,newIndex:a,previousItems:s,previousContainerId:c,transition:u}=e;return!u||!n||s!==i&&o===a?!1:r?!0:a!==o&&t===c},cY={duration:200,easing:"ease"},kq="transform",uY=Go.Transition.toString({property:kq,duration:0,easing:"linear"}),dY={roleDescription:"sortable"};function fY(e){let{disabled:t,index:r,node:n,rect:o}=e;const[i,a]=R.useState(null),s=R.useRef(r);return In(()=>{if(!t&&r!==s.current&&n.current){const c=o.current;if(c){const u=La(n.current,{ignoreTransform:!0}),d={x:c.left-u.left,y:c.top-u.top,scaleX:c.width/u.width,scaleY:c.height/u.height};(d.x||d.y)&&a(d)}}r!==s.current&&(s.current=r)},[t,r,n,o]),R.useEffect(()=>{i&&a(null)},[i]),i}function pY(e){let{animateLayoutChanges:t=lY,attributes:r,disabled:n,data:o,getNewIndex:i=sY,id:a,strategy:s,resizeObserverConfig:c,transition:u=cY}=e;const{items:d,containerId:f,activeIndex:h,disabled:v,disableTransforms:b,sortedRects:g,overIndex:m,useDragOverlay:x,strategy:w}=R.useContext(Aq),E=hY(n,v),S=d.indexOf(a),_=R.useMemo(()=>({sortable:{containerId:f,index:S,items:d},...o}),[f,o,S,d]),C=R.useMemo(()=>d.slice(d.indexOf(a)),[d,a]),{rect:N,node:P,isOver:A,setNodeRef:j}=F9({id:a,data:_,disabled:E.droppable,resizeObserverConfig:{updateMeasurementsFor:C,...c}}),{active:M,activatorEvent:L,activeNodeRect:D,attributes:T,setNodeRef:W,listeners:q,isDragging:G,over:F,setActivatorNodeRef:J,transform:z}=q9({id:a,data:_,attributes:{...dY,...r},disabled:E.draggable}),U=x7(j,W),oe=!!M,re=oe&&!b&&$c(h)&&$c(m),$=!x&&G,Y=$&&re?z:null,X=re?Y??(s??w)({rects:g,activeNodeRect:D,activeIndex:h,overIndex:m,index:S}):null,H=$c(h)&&$c(m)?i({id:a,items:d,activeIndex:h,overIndex:m}):S,K=M==null?void 0:M.id,Q=R.useRef({activeId:K,items:d,newIndex:H,containerId:f}),ne=d!==Q.current.items,se=t({active:M,containerId:f,isDragging:G,isSorting:oe,id:a,index:S,items:d,newIndex:Q.current.newIndex,previousItems:Q.current.items,previousContainerId:Q.current.containerId,transition:u,wasDragging:Q.current.activeId!=null}),te=fY({disabled:!se,index:S,node:P,rect:N});return R.useEffect(()=>{oe&&Q.current.newIndex!==H&&(Q.current.newIndex=H),f!==Q.current.containerId&&(Q.current.containerId=f),d!==Q.current.items&&(Q.current.items=d)},[oe,H,f,d]),R.useEffect(()=>{if(K===Q.current.activeId)return;if(K!=null&&Q.current.activeId==null){Q.current.activeId=K;return}const de=setTimeout(()=>{Q.current.activeId=K},50);return()=>clearTimeout(de)},[K]),{active:M,activeIndex:h,attributes:T,data:_,rect:N,index:S,newIndex:H,items:d,isOver:A,isSorting:oe,isDragging:G,listeners:q,node:P,overIndex:m,over:F,setNodeRef:U,setActivatorNodeRef:J,setDroppableNodeRef:j,setDraggableNodeRef:W,transform:te??X,transition:be()};function be(){if(te||ne&&Q.current.newIndex===S)return uY;if(!($&&!Dd(L)||!u)&&(oe||se))return Go.Transition.toString({...u,property:kq})}}function hY(e,t){var r,n;return typeof e=="boolean"?{draggable:e,droppable:!1}:{draggable:(r=e==null?void 0:e.draggable)!=null?r:t.draggable,droppable:(n=e==null?void 0:e.droppable)!=null?n:t.droppable}}nt.Down,nt.Right,nt.Up,nt.Left;const vY=e=>{let{transform:t}=e;return{...t,y:0}};function gY(e,t,r){const n={...e};return t.top+e.y<=r.top?n.y=r.top-t.top:t.bottom+e.y>=r.top+r.height&&(n.y=r.top+r.height-t.bottom),t.left+e.x<=r.left?n.x=r.left-t.left:t.right+e.x>=r.left+r.width&&(n.x=r.left+r.width-t.right),n}const mY=e=>{let{draggingNodeRect:t,transform:r,scrollableAncestorRects:n}=e;const o=n[0];return!t||!o?r:gY(r,t,o)},IC=({tab:e,value:t,isActive:r,onTabClick:n,dragOverlay:o=!1})=>{const{onClose:i,renderTab:a}=e,{attributes:s,listeners:c,setNodeRef:u,transform:d,transition:f,isDragging:h}=pY({id:t}),v={transform:Go.Transform.toString(d),transition:f||"transform 200ms cubic-bezier(0.2, 0, 0, 1) 0s",opacity:h&&!o?.5:1,cursor:"pointer"},b=()=>{n(t)},g=m=>{m==null||m.stopPropagation(),i&&i(t)};return a?O.jsx("div",{ref:u,style:v,...s,...c,className:"flex h-full shrink-0 select-none focus:outline-hidden","aria-roledescription":"sortable",children:a({tab:e,isActive:r,onClick:b,onClose:i?g:void 0})}):null},Dq={sm:{padding:"px-4 py-0.5",text:"text-xxs",icon:"w-3 h-3",gap:"gap-0.5",badge:"min-w-3.5 h-3.5 text-2"},md:{padding:"px-6 py-1",text:"text-s",icon:"w-4 h-4",gap:"gap-1",badge:"min-w-4.5 h-4.5 text-xxs"},lg:{padding:"px-8 py-1.5",text:"text-base",icon:"w-5 h-5",gap:"gap-1.5",badge:"min-w-5 h-5 text-xs"}},bY={primary:{active:{bg:"bg-primary",text:"text-tab-active-fg",border:"border-primary"},inactive:{bg:"bg-input-bg",text:"text-inactive-text",border:"border-transparent"},hover:{bg:"hover:bg-primary-hover",text:"hover:text-tab-active-fg"}},positive:{active:{bg:"bg-positive-500",text:"text-gray-50",border:"border-positive-500"},inactive:{bg:"bg-input-bg",text:"text-inactive-text",border:"border-transparent"},hover:{bg:"hover:bg-positive-600",text:"hover:text-gray-50"}},negative:{active:{bg:"bg-negative-400",text:"text-gray-50",border:"border-negative-400"},inactive:{bg:"bg-input-bg",text:"text-inactive-text",border:"border-transparent"},hover:{bg:"hover:bg-negative-600",text:"hover:text-gray-50"}},warning:{active:{bg:"bg-warning-500",text:"text-gray-50",border:"border-warning-500"},inactive:{bg:"bg-input-bg",text:"text-inactive-text",border:"border-transparent"},hover:{bg:"hover:bg-warning-600",text:"hover:text-gray-50"}}},PC=()=>xe("inline-flex items-center rounded overflow-hidden"),Mq=(e,t,r,n)=>{const o=bY[e],i=Dq[t],a="relative inline-flex items-center font-medium cursor-pointer transition-all duration-200";return n?xe(a,i.padding,i.text,i.gap,"pointer-events-none cursor-not-allowed opacity-50","bg-card","text-inactive-text"):r?xe(a,i.padding,i.text,i.gap,o.active.bg,o.active.text,"shadow-xs"):xe(a,i.padding,i.text,i.gap,o.inactive.bg,o.inactive.text,o.hover.bg,o.hover.text)},jq=(e,t)=>xe("flex items-center justify-center",Dq[e].icon,{"opacity-50":t}),Lq=()=>xe("whitespace-nowrap"),vh=()=>xe("min-w-full flex h-8 bg-tab-bg-default pt-0.5"),qq=(e,t)=>{const r=xe("group flex items-center justify-between space-x-4","rounded-t px-2 text-xs","focus:outline-hidden");return e&&!t?xe(r,"z-2 border border-b-0 border-tab-border","bg-tab-active-bg font-semibold text-tab-active-fg"):t&&!e?xe(r,"border border-transparent bg-tab-inactive-bg text-inactive-text"):xe(r,"border border-transparent bg-tab-inactive-bg text-tab-inactive-fg","hover:text-tab-active-fg")},l_=R.createContext(void 0),zq=R.forwardRef(({value:e,label:t,icon:r,disabled:n,children:o,className:i,onClick:a,active:s,content:c,...u},d)=>{const f=R.useContext(l_);if(!f)return null;const{activeTab:h,onTabChange:v,variant:b,color:g,size:m,showIcons:x,disabled:w}=f,E=s!==void 0?s:h===e,S=n||w,_=C=>{S||(v(e),a==null||a(C))};return b==="file"?O.jsx("div",{"data-qui":"FileTabItem",className:xe(qq(E,!1),"cursor-pointer",i),onClick:C=>!S&&_(C),children:o||O.jsx(O.Fragment,{children:O.jsxs("span",{className:"flex items-center gap-2",children:[r,O.jsx("span",{children:t})]})})}):O.jsxs("button",{ref:d,"data-qui":"TabItem",type:"button",role:"tab","aria-selected":E,"aria-disabled":S,className:xe(Mq(g,m,E,S||!1),i),onClick:_,disabled:S,...u,children:[x&&r&&O.jsx("span",{className:jq(m,S||!1),children:r}),O.jsx("span",{className:Lq(),children:o||t})]})});zq.displayName="TabItem";const yY=({tab:e,value:t,label:r,isActive:n,color:o="primary",size:i="md",showIcons:a,onTabClick:s})=>{const{icon:c,disabled:u=!1,onClose:d,renderTab:f}=e,h=()=>{u||s(t)},v=b=>{b==null||b.stopPropagation(),!u&&d&&d(t)};return f?O.jsx(O.Fragment,{children:f({tab:e,isActive:n,onClick:h,onClose:d?v:void 0})}):O.jsxs("button",{"data-qui":"TabItem",type:"button",role:"tab","aria-selected":n,"aria-disabled":u,className:Mq(o,i,n,u),onClick:h,disabled:u,children:[a&&c&&O.jsx("span",{className:jq(i,u),children:c}),O.jsx("span",{className:Lq(),children:r})]})},xY=({tab:e,value:t,isActive:r,onTabClick:n})=>{const{onClose:o,renderTab:i}=e,a=()=>{n(t)},s=c=>{c==null||c.stopPropagation(),o&&o(t)};return i?O.jsx("div",{"data-qui":"FileTabItem",className:"flex h-full shrink-0 select-none focus:outline-hidden",children:i({tab:e,isActive:r,onClick:a,onClose:o?s:void 0})}):null},wY=[],n1=({tabs:e=wY,valueKey:t="value",labelKey:r="label",activeTab:n,defaultValue:o,variant:i="default",color:a="primary",size:s="md",draggable:c=!1,showIcons:u=!0,disabled:d=!1,className:f,tabListClassName:h,onTabChange:v,onReorder:b,renderTab:g,children:m})=>{const x=F=>{const J=F[t]??F.value??F.key;return J!==void 0?String(J):""},w=F=>F[r]??F.label,E=o||(e[0]?x(e[0]):""),[S,_]=R.useState(E),[C,N]=R.useState(null),[P,A]=R.useState(e),j=n!==void 0?n:S,M=P,L=M7(D7(e1,{activationConstraint:{distance:10}})),D=F=>{n===void 0&&_(F),v==null||v(F)},T=F=>M.findIndex(J=>x(J)===F),W=C?T(C):-1;R.useEffect(()=>{A(e)},[e]);const q={activeTab:j,onTabChange:D,variant:i,color:a,size:s,showIcons:u,disabled:d};if(m)return O.jsxs(l_.Provider,{value:q,children:[O.jsx("div",{"data-qui":"Tabs",role:"tablist",className:xe(i==="file"?vh():PC(),f,h),children:m}),i==="file"&&O.jsx("hr",{className:"absolute bottom-0 z-1 w-full border-tab-border"})]});const G=i==="file"&&c?O.jsxs("div",{className:"relative h-full w-full",children:[O.jsxs(M9,{collisionDetection:F7,modifiers:[vY,mY],sensors:L,onDragStart:({active:F})=>{F&&N(F.id)},onDragEnd:({over:F})=>{if(N(null),F){const J=T(F.id);if(W!==J&&W!==-1){const z=r1(M,W,J);A(z),b&&b(z,z[J]),D(x(z[J]))}}},onDragCancel:()=>{N(null)},children:[O.jsx(aY,{items:M.map(F=>x(F)),strategy:oY,children:O.jsx("div",{role:"tablist",className:xe(vh(),h),children:M.map(F=>{const J=x(F);return O.jsx(IC,{value:J,tab:{...F,renderTab:F.renderTab||g},isActive:j===J,onTabClick:D,className:f},J)})})}),O.jsx(eY,{children:C&&W!==-1?O.jsx(IC,{value:x(M[W]),tab:{...M[W],renderTab:M[W].renderTab||g},isActive:j===x(M[W]),onTabClick:D,dragOverlay:!0,className:f}):null})]}),O.jsx("hr",{className:"absolute bottom-0 z-1 w-full border-tab-border"})]}):i==="file"?O.jsxs("div",{className:"relative",children:[O.jsx("div",{role:"tablist",className:xe(vh(),h),children:e.map(F=>{const J=x(F);return O.jsx(xY,{value:J,tab:{...F,renderTab:F.renderTab||g},isActive:j===J,onTabClick:D},J)})}),O.jsx("hr",{className:"absolute bottom-0 z-1 w-full border-tab-border"})]}):O.jsx("div",{role:"tablist",className:xe(PC(),h),children:e.map(F=>{const J=x(F);return O.jsx(yY,{value:J,label:w(F),tab:{...F,renderTab:F.renderTab||g},isActive:j===J,color:a,size:s,showIcons:u,onTabClick:D},J)})});return O.jsx(l_.Provider,{value:q,children:O.jsx("div",{"data-qui":"Tabs",className:f,children:G})})},_Y=R.forwardRef(({isActive:e=!1,isDesactive:t=!1,children:r,...n},o)=>O.jsx("div",{"data-qui":"TabNavContainer",className:qq(e,t),ref:o,...n,children:r}));_Y.displayName="TabNavContainer";n1.displayName="Tabs";n1.Item=zq;const gh=n1;var qt=function(){return qt=Object.assign||function(e){for(var t,r=1,n=arguments.length;r<n;r++){t=arguments[r];for(var o in t)Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o])}return e},qt.apply(this,arguments)},TC={width:"100%",height:"10px",top:"0px",left:"0px",cursor:"row-resize"},AC={width:"10px",height:"100%",top:"0px",left:"0px",cursor:"col-resize"},Hc={width:"20px",height:"20px",position:"absolute",zIndex:1},EY={top:qt(qt({},TC),{top:"-5px"}),right:qt(qt({},AC),{left:void 0,right:"-5px"}),bottom:qt(qt({},TC),{top:void 0,bottom:"-5px"}),left:qt(qt({},AC),{left:"-5px"}),topRight:qt(qt({},Hc),{right:"-10px",top:"-10px",cursor:"ne-resize"}),bottomRight:qt(qt({},Hc),{right:"-10px",bottom:"-10px",cursor:"se-resize"}),bottomLeft:qt(qt({},Hc),{left:"-10px",bottom:"-10px",cursor:"sw-resize"}),topLeft:qt(qt({},Hc),{left:"-10px",top:"-10px",cursor:"nw-resize"})},SY=R.memo(function(e){var t=e.onResizeStart,r=e.direction,n=e.children,o=e.replaceStyles,i=e.className,a=R.useCallback(function(u){t(u,r)},[t,r]),s=R.useCallback(function(u){t(u,r)},[t,r]),c=R.useMemo(function(){return qt(qt({position:"absolute",userSelect:"none"},EY[r]),o??{})},[o,r]);return O.jsx("div",{className:i||void 0,style:c,onMouseDown:a,onTouchStart:s,children:n})}),OY=(function(){var e=function(t,r){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,o){n.__proto__=o}||function(n,o){for(var i in o)Object.prototype.hasOwnProperty.call(o,i)&&(n[i]=o[i])},e(t,r)};return function(t,r){if(typeof r!="function"&&r!==null)throw new TypeError("Class extends value "+String(r)+" is not a constructor or null");e(t,r);function n(){this.constructor=t}t.prototype=r===null?Object.create(r):(n.prototype=r.prototype,new n)}})(),Hn=function(){return Hn=Object.assign||function(e){for(var t,r=1,n=arguments.length;r<n;r++){t=arguments[r];for(var o in t)Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o])}return e},Hn.apply(this,arguments)},CY={width:"auto",height:"auto"},Wc=function(e,t,r){return Math.max(Math.min(e,r),t)},kC=function(e,t,r){var n=Math.round(e/t);return n*t+r*(n-1)},ea=function(e,t){return new RegExp(e,"i").test(t)},Uc=function(e){return!!(e.touches&&e.touches.length)},RY=function(e){return!!((e.clientX||e.clientX===0)&&(e.clientY||e.clientY===0))},DC=function(e,t,r){r===void 0&&(r=0);var n=t.reduce(function(i,a,s){return Math.abs(a-e)<Math.abs(t[i]-e)?s:i},0),o=Math.abs(t[n]-e);return r===0||o<r?t[n]:e},mh=function(e){return e=e.toString(),e==="auto"||e.endsWith("px")||e.endsWith("%")||e.endsWith("vh")||e.endsWith("vw")||e.endsWith("vmax")||e.endsWith("vmin")?e:"".concat(e,"px")},Gc=function(e,t,r,n){if(e&&typeof e=="string"){if(e.endsWith("px"))return Number(e.replace("px",""));if(e.endsWith("%")){var o=Number(e.replace("%",""))/100;return t*o}if(e.endsWith("vw")){var o=Number(e.replace("vw",""))/100;return r*o}if(e.endsWith("vh")){var o=Number(e.replace("vh",""))/100;return n*o}}return e},NY=function(e,t,r,n,o,i,a){return n=Gc(n,e.width,t,r),o=Gc(o,e.height,t,r),i=Gc(i,e.width,t,r),a=Gc(a,e.height,t,r),{maxWidth:typeof n>"u"?void 0:Number(n),maxHeight:typeof o>"u"?void 0:Number(o),minWidth:typeof i>"u"?void 0:Number(i),minHeight:typeof a>"u"?void 0:Number(a)}},IY=function(e){return Array.isArray(e)?e:[e,e]},PY=["as","ref","style","className","grid","gridGap","snap","bounds","boundsByDirection","size","defaultSize","minWidth","minHeight","maxWidth","maxHeight","lockAspectRatio","lockAspectRatioExtraWidth","lockAspectRatioExtraHeight","enable","handleStyles","handleClasses","handleWrapperStyle","handleWrapperClass","children","onResizeStart","onResize","onResizeStop","handleComponent","scale","resizeRatio","snapGap"],MC="__resizable_base__",TY=(function(e){OY(t,e);function t(r){var n,o,i,a,s=e.call(this,r)||this;return s.ratio=1,s.resizable=null,s.parentLeft=0,s.parentTop=0,s.resizableLeft=0,s.resizableRight=0,s.resizableTop=0,s.resizableBottom=0,s.targetLeft=0,s.targetTop=0,s.delta={width:0,height:0},s.appendBase=function(){if(!s.resizable||!s.window)return null;var c=s.parentNode;if(!c)return null;var u=s.window.document.createElement("div");return u.style.width="100%",u.style.height="100%",u.style.position="absolute",u.style.transform="scale(0, 0)",u.style.left="0",u.style.flex="0 0 100%",u.classList?u.classList.add(MC):u.className+=MC,c.appendChild(u),u},s.removeBase=function(c){var u=s.parentNode;u&&u.removeChild(c)},s.state={isResizing:!1,width:(o=(n=s.propsSize)===null||n===void 0?void 0:n.width)!==null&&o!==void 0?o:"auto",height:(a=(i=s.propsSize)===null||i===void 0?void 0:i.height)!==null&&a!==void 0?a:"auto",direction:"right",original:{x:0,y:0,width:0,height:0},backgroundStyle:{height:"100%",width:"100%",backgroundColor:"rgba(0,0,0,0)",cursor:"auto",opacity:0,position:"fixed",zIndex:9999,top:"0",left:"0",bottom:"0",right:"0"},flexBasis:void 0},s.onResizeStart=s.onResizeStart.bind(s),s.onMouseMove=s.onMouseMove.bind(s),s.onMouseUp=s.onMouseUp.bind(s),s}return Object.defineProperty(t.prototype,"parentNode",{get:function(){return this.resizable?this.resizable.parentNode:null},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"window",{get:function(){return!this.resizable||!this.resizable.ownerDocument?null:this.resizable.ownerDocument.defaultView},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"propsSize",{get:function(){return this.props.size||this.props.defaultSize||CY},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"size",{get:function(){var r=0,n=0;if(this.resizable&&this.window){var o=this.resizable.offsetWidth,i=this.resizable.offsetHeight,a=this.resizable.style.position;a!=="relative"&&(this.resizable.style.position="relative"),r=this.resizable.style.width!=="auto"?this.resizable.offsetWidth:o,n=this.resizable.style.height!=="auto"?this.resizable.offsetHeight:i,this.resizable.style.position=a}return{width:r,height:n}},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"sizeStyle",{get:function(){var r=this,n=this.props.size,o=function(s){var c;if(typeof r.state[s]>"u"||r.state[s]==="auto")return"auto";if(r.propsSize&&r.propsSize[s]&&!((c=r.propsSize[s])===null||c===void 0)&&c.toString().endsWith("%")){if(r.state[s].toString().endsWith("%"))return r.state[s].toString();var u=r.getParentSize(),d=Number(r.state[s].toString().replace("px","")),f=d/u[s]*100;return"".concat(f,"%")}return mh(r.state[s])},i=n&&typeof n.width<"u"&&!this.state.isResizing?mh(n.width):o("width"),a=n&&typeof n.height<"u"&&!this.state.isResizing?mh(n.height):o("height");return{width:i,height:a}},enumerable:!1,configurable:!0}),t.prototype.getParentSize=function(){if(!this.parentNode)return this.window?{width:this.window.innerWidth,height:this.window.innerHeight}:{width:0,height:0};var r=this.appendBase();if(!r)return{width:0,height:0};var n=!1,o=this.parentNode.style.flexWrap;o!=="wrap"&&(n=!0,this.parentNode.style.flexWrap="wrap"),r.style.position="relative",r.style.minWidth="100%",r.style.minHeight="100%";var i={width:r.offsetWidth,height:r.offsetHeight};return n&&(this.parentNode.style.flexWrap=o),this.removeBase(r),i},t.prototype.bindEvents=function(){this.window&&(this.window.addEventListener("mouseup",this.onMouseUp),this.window.addEventListener("mousemove",this.onMouseMove),this.window.addEventListener("mouseleave",this.onMouseUp),this.window.addEventListener("touchmove",this.onMouseMove,{capture:!0,passive:!1}),this.window.addEventListener("touchend",this.onMouseUp))},t.prototype.unbindEvents=function(){this.window&&(this.window.removeEventListener("mouseup",this.onMouseUp),this.window.removeEventListener("mousemove",this.onMouseMove),this.window.removeEventListener("mouseleave",this.onMouseUp),this.window.removeEventListener("touchmove",this.onMouseMove,!0),this.window.removeEventListener("touchend",this.onMouseUp))},t.prototype.componentDidMount=function(){if(!(!this.resizable||!this.window)){var r=this.window.getComputedStyle(this.resizable);this.setState({width:this.state.width||this.size.width,height:this.state.height||this.size.height,flexBasis:r.flexBasis!=="auto"?r.flexBasis:void 0})}},t.prototype.componentWillUnmount=function(){this.window&&this.unbindEvents()},t.prototype.createSizeForCssProperty=function(r,n){var o=this.propsSize&&this.propsSize[n];return this.state[n]==="auto"&&this.state.original[n]===r&&(typeof o>"u"||o==="auto")?"auto":r},t.prototype.calculateNewMaxFromBoundary=function(r,n){var o=this.props.boundsByDirection,i=this.state.direction,a=o&&ea("left",i),s=o&&ea("top",i),c,u;if(this.props.bounds==="parent"){var d=this.parentNode;d&&(c=a?this.resizableRight-this.parentLeft:d.offsetWidth+(this.parentLeft-this.resizableLeft),u=s?this.resizableBottom-this.parentTop:d.offsetHeight+(this.parentTop-this.resizableTop))}else this.props.bounds==="window"?this.window&&(c=a?this.resizableRight:this.window.innerWidth-this.resizableLeft,u=s?this.resizableBottom:this.window.innerHeight-this.resizableTop):this.props.bounds&&(c=a?this.resizableRight-this.targetLeft:this.props.bounds.offsetWidth+(this.targetLeft-this.resizableLeft),u=s?this.resizableBottom-this.targetTop:this.props.bounds.offsetHeight+(this.targetTop-this.resizableTop));return c&&Number.isFinite(c)&&(r=r&&r<c?r:c),u&&Number.isFinite(u)&&(n=n&&n<u?n:u),{maxWidth:r,maxHeight:n}},t.prototype.calculateNewSizeFromDirection=function(r,n){var o=this.props.scale||1,i=IY(this.props.resizeRatio||1),a=i[0],s=i[1],c=this.state,u=c.direction,d=c.original,f=this.props,h=f.lockAspectRatio,v=f.lockAspectRatioExtraHeight,b=f.lockAspectRatioExtraWidth,g=d.width,m=d.height,x=v||0,w=b||0;return ea("right",u)&&(g=d.width+(r-d.x)*a/o,h&&(m=(g-w)/this.ratio+x)),ea("left",u)&&(g=d.width-(r-d.x)*a/o,h&&(m=(g-w)/this.ratio+x)),ea("bottom",u)&&(m=d.height+(n-d.y)*s/o,h&&(g=(m-x)*this.ratio+w)),ea("top",u)&&(m=d.height-(n-d.y)*s/o,h&&(g=(m-x)*this.ratio+w)),{newWidth:g,newHeight:m}},t.prototype.calculateNewSizeFromAspectRatio=function(r,n,o,i){var a=this.props,s=a.lockAspectRatio,c=a.lockAspectRatioExtraHeight,u=a.lockAspectRatioExtraWidth,d=typeof i.width>"u"?10:i.width,f=typeof o.width>"u"||o.width<0?r:o.width,h=typeof i.height>"u"?10:i.height,v=typeof o.height>"u"||o.height<0?n:o.height,b=c||0,g=u||0;if(s){var m=(h-b)*this.ratio+g,x=(v-b)*this.ratio+g,w=(d-g)/this.ratio+b,E=(f-g)/this.ratio+b,S=Math.max(d,m),_=Math.min(f,x),C=Math.max(h,w),N=Math.min(v,E);r=Wc(r,S,_),n=Wc(n,C,N)}else r=Wc(r,d,f),n=Wc(n,h,v);return{newWidth:r,newHeight:n}},t.prototype.setBoundingClientRect=function(){var r=1/(this.props.scale||1);if(this.props.bounds==="parent"){var n=this.parentNode;if(n){var o=n.getBoundingClientRect();this.parentLeft=o.left*r,this.parentTop=o.top*r}}if(this.props.bounds&&typeof this.props.bounds!="string"){var i=this.props.bounds.getBoundingClientRect();this.targetLeft=i.left*r,this.targetTop=i.top*r}if(this.resizable){var a=this.resizable.getBoundingClientRect(),s=a.left,c=a.top,u=a.right,d=a.bottom;this.resizableLeft=s*r,this.resizableRight=u*r,this.resizableTop=c*r,this.resizableBottom=d*r}},t.prototype.onResizeStart=function(r,n){if(!(!this.resizable||!this.window)){var o=0,i=0;if(r.nativeEvent&&RY(r.nativeEvent)?(o=r.nativeEvent.clientX,i=r.nativeEvent.clientY):r.nativeEvent&&Uc(r.nativeEvent)&&(o=r.nativeEvent.touches[0].clientX,i=r.nativeEvent.touches[0].clientY),this.props.onResizeStart&&this.resizable){var a=this.props.onResizeStart(r,n,this.resizable);if(a===!1)return}this.props.size&&(typeof this.props.size.height<"u"&&this.props.size.height!==this.state.height&&this.setState({height:this.props.size.height}),typeof this.props.size.width<"u"&&this.props.size.width!==this.state.width&&this.setState({width:this.props.size.width})),this.ratio=typeof this.props.lockAspectRatio=="number"?this.props.lockAspectRatio:this.size.width/this.size.height;var s,c=this.window.getComputedStyle(this.resizable);if(c.flexBasis!=="auto"){var u=this.parentNode;if(u){var d=this.window.getComputedStyle(u).flexDirection;this.flexDir=d.startsWith("row")?"row":"column",s=c.flexBasis}}this.setBoundingClientRect(),this.bindEvents();var f={original:{x:o,y:i,width:this.size.width,height:this.size.height},isResizing:!0,backgroundStyle:Hn(Hn({},this.state.backgroundStyle),{cursor:this.window.getComputedStyle(r.target).cursor||"auto"}),direction:n,flexBasis:s};this.setState(f)}},t.prototype.onMouseMove=function(r){var n=this;if(!(!this.state.isResizing||!this.resizable||!this.window)){if(this.window.TouchEvent&&Uc(r))try{r.preventDefault(),r.stopPropagation()}catch{}var o=this.props,i=o.maxWidth,a=o.maxHeight,s=o.minWidth,c=o.minHeight,u=Uc(r)?r.touches[0].clientX:r.clientX,d=Uc(r)?r.touches[0].clientY:r.clientY,f=this.state,h=f.direction,v=f.original,b=f.width,g=f.height,m=this.getParentSize(),x=NY(m,this.window.innerWidth,this.window.innerHeight,i,a,s,c);i=x.maxWidth,a=x.maxHeight,s=x.minWidth,c=x.minHeight;var w=this.calculateNewSizeFromDirection(u,d),E=w.newHeight,S=w.newWidth,_=this.calculateNewMaxFromBoundary(i,a);this.props.snap&&this.props.snap.x&&(S=DC(S,this.props.snap.x,this.props.snapGap)),this.props.snap&&this.props.snap.y&&(E=DC(E,this.props.snap.y,this.props.snapGap));var C=this.calculateNewSizeFromAspectRatio(S,E,{width:_.maxWidth,height:_.maxHeight},{width:s,height:c});if(S=C.newWidth,E=C.newHeight,this.props.grid){var N=kC(S,this.props.grid[0],this.props.gridGap?this.props.gridGap[0]:0),P=kC(E,this.props.grid[1],this.props.gridGap?this.props.gridGap[1]:0),A=this.props.snapGap||0,j=A===0||Math.abs(N-S)<=A?N:S,M=A===0||Math.abs(P-E)<=A?P:E;S=j,E=M}var L={width:S-v.width,height:E-v.height};if(this.delta=L,b&&typeof b=="string"){if(b.endsWith("%")){var D=S/m.width*100;S="".concat(D,"%")}else if(b.endsWith("vw")){var T=S/this.window.innerWidth*100;S="".concat(T,"vw")}else if(b.endsWith("vh")){var W=S/this.window.innerHeight*100;S="".concat(W,"vh")}}if(g&&typeof g=="string"){if(g.endsWith("%")){var D=E/m.height*100;E="".concat(D,"%")}else if(g.endsWith("vw")){var T=E/this.window.innerWidth*100;E="".concat(T,"vw")}else if(g.endsWith("vh")){var W=E/this.window.innerHeight*100;E="".concat(W,"vh")}}var q={width:this.createSizeForCssProperty(S,"width"),height:this.createSizeForCssProperty(E,"height")};this.flexDir==="row"?q.flexBasis=q.width:this.flexDir==="column"&&(q.flexBasis=q.height);var G=this.state.width!==q.width,F=this.state.height!==q.height,J=this.state.flexBasis!==q.flexBasis,z=G||F||J;z&&mo.flushSync(function(){n.setState(q)}),this.props.onResize&&z&&this.props.onResize(r,h,this.resizable,L)}},t.prototype.onMouseUp=function(r){var n,o,i=this.state,a=i.isResizing,s=i.direction;i.original,!(!a||!this.resizable)&&(this.props.onResizeStop&&this.props.onResizeStop(r,s,this.resizable,this.delta),this.props.size&&this.setState({width:(n=this.props.size.width)!==null&&n!==void 0?n:"auto",height:(o=this.props.size.height)!==null&&o!==void 0?o:"auto"}),this.unbindEvents(),this.setState({isResizing:!1,backgroundStyle:Hn(Hn({},this.state.backgroundStyle),{cursor:"auto"})}))},t.prototype.updateSize=function(r){var n,o;this.setState({width:(n=r.width)!==null&&n!==void 0?n:"auto",height:(o=r.height)!==null&&o!==void 0?o:"auto"})},t.prototype.renderResizer=function(){var r=this,n=this.props,o=n.enable,i=n.handleStyles,a=n.handleClasses,s=n.handleWrapperStyle,c=n.handleWrapperClass,u=n.handleComponent;if(!o)return null;var d=Object.keys(o).map(function(f){return o[f]!==!1?O.jsx(SY,{direction:f,onResizeStart:r.onResizeStart,replaceStyles:i&&i[f],className:a&&a[f],children:u&&u[f]?u[f]:null},f):null});return O.jsx("div",{className:c,style:s,children:d})},t.prototype.render=function(){var r=this,n=Object.keys(this.props).reduce(function(a,s){return PY.indexOf(s)!==-1||(a[s]=r.props[s]),a},{}),o=Hn(Hn(Hn({position:"relative",userSelect:this.state.isResizing?"none":"auto"},this.props.style),this.sizeStyle),{maxWidth:this.props.maxWidth,maxHeight:this.props.maxHeight,minWidth:this.props.minWidth,minHeight:this.props.minHeight,boxSizing:"border-box",flexShrink:0});this.state.flexBasis&&(o.flexBasis=this.state.flexBasis);var i=this.props.as||"div";return O.jsxs(i,Hn({style:o,className:this.props.className},n,{ref:function(a){a&&(r.resizable=a)},children:[this.state.isResizing&&O.jsx("div",{style:this.state.backgroundStyle}),this.props.children,this.renderResizer()]}))},t.defaultProps={as:"div",onResizeStart:function(){},onResize:function(){},onResizeStop:function(){},enable:{top:!0,right:!0,bottom:!0,left:!0,topRight:!0,bottomRight:!0,bottomLeft:!0,topLeft:!0},style:{},grid:[1,1],gridGap:[0,0],lockAspectRatio:!1,lockAspectRatioExtraWidth:0,lockAspectRatioExtraHeight:0,scale:1,resizeRatio:1,snapGap:0},t})(R.PureComponent);const AY={0:"bg-panel-0",1:"bg-panel-1",2:"bg-panel-2",3:"bg-panel-3",4:"bg-panel-4",5:"bg-panel-5"},kY={tabs:"border-tab-border",primary:"border-primary",negative:"border-input-error-border",positive:"border-positive",light:"border-panel-border-subtle",default:"border-panel-border"},Bq=({depth:e=0,className:t,borderType:r,disabled:n})=>xe("transition-colors duration-200",{"text-body":!n,"text-inactive-text":n},r?kY[r]:"border-panel-border",AY[e],t),DY=e=>{if(!e)return{};const t={},r=e.match(/min-w-\[(\d+)px\]/);r&&(t.minWidth=parseInt(r[1],10));const n=e.match(/max-w-\[(\d+)px\]/);n&&(t.maxWidth=parseInt(n[1],10));const o=e.match(/min-h-\[(\d+)px\]/);o&&(t.minHeight=parseInt(o[1],10));const i=e.match(/max-h-\[(\d+)px\]/);return i&&(t.maxHeight=parseInt(i[1],10)),t},MY=R.forwardRef(({children:e,width:t,height:r,minWidth:n=10,minHeight:o=10,maxWidth:i,maxHeight:a,defaultWidth:s,defaultHeight:c,defaultSize:u,size:d,grid:f,snap:h,lockAspectRatio:v=!1,enable:b,handleStyles:g={},handleClasses:m={},handleComponent:x={},style:w={},className:E,onResizeStart:S,onResize:_,onResizeStop:C,scale:N=1,bounds:P,snapGap:A,as:j="div",depth:M,disabled:L},D)=>{const T=Bq({depth:M,className:E,disabled:L}),W=DY(E),q=d?{size:d}:t!==void 0||r!==void 0?{size:{width:t??"auto",height:r??"auto"}}:{},G=u?{defaultSize:u}:s!==void 0||c!==void 0?{defaultSize:{width:s??"auto",height:c??"auto"}}:{},F=R.useRef(null);return R.useImperativeHandle(D,()=>{var J;return(J=F.current)==null?void 0:J.resizable}),O.jsx(TY,{"data-qui":"Resizable",ref:F,...q,...G,minWidth:n??W.minWidth,minHeight:o??W.minHeight,maxWidth:i??W.maxWidth,maxHeight:a??W.maxHeight,grid:f,snap:h,lockAspectRatio:v,enable:b,handleStyles:g,handleClasses:m,handleComponent:x,style:w,className:xe("relative box-border",T),onResizeStart:S,onResize:_,onResizeStop:C,scale:N,bounds:P,snapGap:A,as:j,children:e})});MY.displayName="Resizable";const ta={sm:{track:"h-4 w-7",thumb:"size-3",thumbUnchecked:"left-0.5",thumbChecked:"left-3.5",label:"text-xs",gap:"gap-2"},md:{track:"h-5 w-9",thumb:"size-4",thumbUnchecked:"left-0.5",thumbChecked:"left-4.5",label:"text-sm",gap:"gap-2.5"},lg:{track:"h-6 w-11",thumb:"size-5",thumbUnchecked:"left-0.5",thumbChecked:"left-5.5",label:"text-base",gap:"gap-3"}},Yc={primary:{bg:"bg-primary",thumb:"bg-white group-hover:bg-primary-light",icon:"text-primary"},positive:{bg:"bg-positive",thumb:"bg-white group-hover:bg-positive-light",icon:"text-positive"},warning:{bg:"bg-warning",thumb:"bg-white group-hover:bg-warning-light",icon:"text-warning"},negative:{bg:"bg-negative",thumb:"bg-white group-hover:bg-negative-light",icon:"text-negative"}},jY=(e,t,r,n,o,i)=>({container:xe("inline-flex items-center",ta[e].gap,i),track:xe("relative inline-flex items-center shrink-0 group","transition-colors duration-200 ease-in-out","focus:outline-hidden focus-visible:ring-2 focus-visible:ring-primary focus-visible:ring-offset-2","rounded-full justify-between px-0.5",ta[e].track,{[Yc[t].bg]:r&&!n&&!o,"bg-panel":!r&&!n||o,"bg-panel cursor-not-allowed":n,"cursor-pointer":!n}),thumb:xe("pointer-events-none inline-flex items-center justify-center shadow-xs","transition-all duration-200 ease-in-out","rounded-full absolute",ta[e].thumb,r?ta[e].thumbChecked:ta[e].thumbUnchecked,{[Yc[t].thumb]:!n,"bg-canvas-subtle":n}),iconLeft:xe("flex items-center justify-center z-10 w-1/2 p-0.5",{[Yc[t].icon]:!r&&!n,"text-panel-subtle":n||r}),iconRight:xe("flex items-center justify-center z-10 w-1/2 p-0.5",{[Yc[t].icon]:r&&!n,"text-panel-subtle":n||!r}),label:xe("font-medium text-body",ta[e].label,{"cursor-pointer":!n,"cursor-not-allowed text-muted":n})}),Qu=R.forwardRef(({label:e,checked:t,defaultChecked:r=!1,disabled:n=!1,size:o="md",color:i="primary",icons:a,onChange:s,className:c,id:u,name:d,...f},h)=>{const[v,b]=R.useState(r),g=t!==void 0,m=g?t:v,x=()=>{const E=!m;g||b(E),s==null||s(E)},w=jY(o,i,m,n,!!a,c);return O.jsxs("div",{"data-qui":"Toggle",className:w.container,children:[e&&O.jsx("label",{htmlFor:u,className:w.label,children:e}),O.jsxs("button",{ref:h,...f,type:"button",role:"switch","aria-checked":m,"aria-label":e,disabled:n,onClick:x,name:d,id:u,className:w.track,children:[a&&O.jsx("span",{className:w.iconLeft,children:a.unchecked}),O.jsx("span",{className:w.thumb,"aria-hidden":"true"}),a&&O.jsx("span",{className:w.iconRight,children:a.checked})]})]})});Qu.displayName="Toggle";R.createContext(null);const fn=R.forwardRef(({depth:e=0,className:t,children:r,borderType:n,disabled:o,...i},a)=>{const s=Bq({depth:e,className:t,borderType:n,disabled:o});return O.jsx("div",{"data-qui":"Panel",ref:a,className:s,"aria-disabled":o,...i,children:r})});fn.displayName="Panel";const Ld={sm:{container:"h-5 px-0.5 gap-1 rounded",text:"text-xxs leading-3",icon:"text-s",iconButton:"text-s p-0.5 cursor-pointer"},md:{container:"h-5.5 px-1 gap-1 rounded",text:"text-xs leading-4",icon:"text-sm",iconButton:" text-sm p-0.5 cursor-pointer"},lg:{container:"h-6 px-1.5 gap-1.5 rounded",text:"text-s leading-none",icon:"text-base",iconButton:"text-base p-0.5 cursor-pointer"}},Ru={primary:{bg:"bg-primary",text:"text-body",border:"border-primary",buttonHover:"hover:bg-primary-hover"},white:{bg:"bg-canvas-default",text:"text-primary",border:"border-canvas-default",buttonHover:"hover:bg-primary-hover hover:text-body"},positive:{bg:"bg-positive",text:"text-body",border:"border-positive",buttonHover:"hover:bg-positive-hover"},warning:{bg:"bg-warning",text:"text-body",border:"border-warning",buttonHover:"hover:bg-warning-hover"},negative:{bg:"bg-negative",text:"text-body",border:"border-negative",buttonHover:"hover:bg-negative-hover"}},LY=(e,t)=>xe("inline-flex items-center justify-center font-medium border",Ld[e].container,Ru[t].bg,Ru[t].text,Ru[t].border),qY=(e,t,r)=>xe({[Ld[e].icon]:!r,"bg-canvas-default outline-canvas-default text-primary":r&&t!=="white"||r,"bg-primary outline-primary text-body":r&&t==="white"&&!r,"outline-solid outline-1 h-full py-0.5 grid place-items-center -my-1 only:-mx-0.5 first:-ml-1.5 last:-mr-1.5 only:rounded first:rounded-l last:rounded-r":r||r}),zY=e=>xe(Ld[e].text),Fq=(e,t)=>xe("inline-flex items-center justify-center rounded transition-colors duration-200 focus:outline-hidden ",Ld[e].iconButton,Ru[t].buttonHover),$q=R.createContext(null),qd=()=>{const e=R.useContext($q);if(!e)throw new Error("Pill components must be used within a Pill.Root");return e},o1=R.forwardRef(({size:e="md",color:t="primary",className:r,children:n,...o},i)=>{const a={size:e,color:t};return O.jsx($q.Provider,{value:a,children:O.jsx("div",{"data-qui":"Pill",ref:i,className:xe(LY(e,t),r),...o,children:n})})});o1.displayName="Pill.Root";const i1=R.forwardRef(({className:e,children:t,...r},n)=>{const{size:o}=qd();return O.jsx("span",{ref:n,className:xe(zY(o),e),...r,children:t})});i1.displayName="Pill.Text";const a1=R.forwardRef(({className:e,children:t,label:r,position:n,...o},i)=>{const{size:a,color:s}=qd(),c=!!r,u=O.jsx("span",{ref:i,className:xe(qY(a,s,c),e),...o,children:t});return c?O.jsx(y7,{label:r||"",position:n||"up",children:u}):u});a1.displayName="Pill.Icon";const Vq=R.forwardRef(({className:e,children:t,...r},n)=>{const{size:o,color:i}=qd();return O.jsx("button",{ref:n,type:"button",className:xe(Fq(o,i),e),...r,children:t})});Vq.displayName="Pill.Button";const s1=R.forwardRef(({className:e,onClose:t,"aria-label":r="Remove pill",children:n,...o},i)=>{const{size:a,color:s}=qd();return O.jsx("button",{ref:i,type:"button",className:xe(Fq(a,s),e),onClick:t,"aria-label":r,...o,children:n||O.jsx(Td,{})})});s1.displayName="Pill.Close";const Hq=R.forwardRef(({size:e="md",color:t="primary",label:r,icon:n,onClose:o,closable:i=!1,className:a,...s},c)=>O.jsxs(o1,{ref:c,size:e,color:t,className:a,...s,children:[n&&O.jsx(a1,{children:n}),O.jsx(i1,{children:r}),i&&O.jsx(s1,{onClose:o})]}));Hq.displayName="Pill";Object.assign(Hq,{Root:o1,Text:i1,Icon:a1,Button:Vq,Close:s1});const BY=R.createContext(null),wr=()=>{const e=R.useContext(BY);if(!e)throw new Error("Select compound components must be used within Select.Root");return e},ur={sm:{trigger:"h-5 min-h-fit",control:"min-h-5 p-0.5 gap-1",input:"text-2.25 h-3.5",placeholder:"text-2.25",singleValue:"text-2.25",multiValue:"h-3.5 px-0.5 gap-1 text-2",multiValueLabel:"text-2",multiValueRemove:"w-3 h-3",indicatorsContainer:"gap-1",clearIndicator:"p-0.5 size-3",dropdownIndicator:"p-0.5 size-3",indicatorSeparator:"h-3",loadingIndicator:"w-3 h-3",menu:"m-0",menuList:"py-1",option:"px-1 py-0.5 text-xs",group:"pt-1",groupHeading:"px-2 py-0.5 text-2",noOptionsMessage:"px-2 py-1 text-2.25",loadingMessage:"px-2 py-1 text-2.25",message:"text-2.25 p-1.5",icon:"text-sm"},md:{trigger:"h-6 min-h-fit",control:"min-h-6 p-1 gap-1.5",input:"text-xs h-4",placeholder:"text-xs",singleValue:"text-xs",multiValue:"h-4 p-1 gap-1 text-2.5",multiValueLabel:"text-2.5",multiValueRemove:"w-3.5 h-3.5",indicatorsContainer:"gap-1",clearIndicator:"p-0.5 size-4",dropdownIndicator:"p-0.5 size-4",indicatorSeparator:"h-4",loadingIndicator:"w-4 h-4",menu:"m-0",menuList:"my-1",option:"px-2 py-1 text-s",group:"pt-1.5",groupHeading:"px-3 py-1 text-2.5",noOptionsMessage:"px-2 py-1.5 text-xs",loadingMessage:"px-3 py-1.5 text-xs",message:"text-xs p-2",icon:"text-base"},lg:{trigger:"h-7 min-h-fit",control:"min-h-7 p-1.5 gap-2",input:"text-s h-5",placeholder:"text-s",singleValue:"text-s",multiValue:"h-5 px-1.5 gap-1.5 text-xs",multiValueLabel:"text-xs",multiValueRemove:"w-4 h-4",indicatorsContainer:"gap-1.5",clearIndicator:"p-0.5 size-5",dropdownIndicator:"p-1 size-5",indicatorSeparator:"h-5",loadingIndicator:"w-5 h-5",menu:"m-0",menuList:"py-1.5",option:"px-3 py-2 text-sm",group:"pt-2",groupHeading:"px-4 py-1.5 text-xs",noOptionsMessage:"px-4 py-2 text-s",loadingMessage:"px-4 py-2 text-s",message:"text-s p-2.5",icon:"text-lg"}},Et={primary:{control:"cursor-pointer bg-select-bg text-select-text",controlFocused:"border-input-focus-border",controlDisabled:"opacity-60",controlInvalid:"bg-select-bg border-input-error-border text-select-text",placeholder:"text-input-placeholder placeholder:opacity-60",singleValue:"text-select-text",singleValueDisabled:"text-input-placeholder",multiValue:"bg-input-option-active-bg text-input-option-active-text",multiValueLabel:"text-input-option-active-text",multiValueRemove:"text-input-option-active-text hover:bg-input-option-hover-bg hover:text-body rounded-xs p-px",multiValueRemoveHover:"hover:bg-input-option-hover-bg",multiValueDisabled:"bg-canvas-subtle text-muted",clearIndicator:"text-input-text hover:text-body cursor-pointer",clearIndicatorHover:"hover:text-body hover:bg-input-option-hover-bg",dropdownIndicator:"text-input-text",dropdownIndicatorHover:"hover:text-body hover:bg-input-option-hover-bg",indicatorSeparator:"bg-input-border",loadingIndicator:"text-primary",menu:"bg-select-list-bg border-select-border shadow-lg",menuList:"scrollbar-thin scrollbar-thumb-input-border scrollbar-track-transparent",option:"text-select-text cursor-pointer",optionFocused:"bg-input-option-hover-bg text-body",optionSelected:"bg-input-option-active-bg text-input-option-active-text",optionDisabled:"text-input-placeholder cursor-not-allowed",group:"",groupHeading:"text-input-placeholder font-semibold",noOptionsMessage:"text-input-placeholder",loadingMessage:"text-input-placeholder",message:"text-primary-dark",messageBackground:"bg-input-message-bg",messageBorder:"border-input-info-border",icon:"text-input-text",iconAction:"text-input-text hover:text-body",iconActionHover:"hover:text-body hover:bg-input-option-hover-bg"},positive:{control:"cursor-pointer bg-select-bg text-select-text",controlFocused:"border-positive",controlDisabled:"opacity-60",controlInvalid:"bg-select-bg border-input-error-border text-select-text",placeholder:"text-input-placeholder placeholder:opacity-60",singleValue:"text-select-text",singleValueDisabled:"text-input-placeholder",multiValue:"bg-input-option-active-bg text-input-option-active-text",multiValueLabel:"text-input-option-active-text",multiValueRemove:"text-input-option-active-text hover:bg-input-option-hover-bg hover:text-body rounded-xs p-px",multiValueRemoveHover:"hover:bg-input-option-hover-bg",multiValueDisabled:"bg-canvas-subtle text-muted",clearIndicator:"text-input-text hover:text-body cursor-pointer",clearIndicatorHover:"hover:text-body hover:bg-input-option-hover-bg",dropdownIndicator:"text-input-text",dropdownIndicatorHover:"hover:text-body hover:bg-input-option-hover-bg",indicatorSeparator:"bg-input-border",loadingIndicator:"text-positive",menu:"bg-select-list-bg border-select-border shadow-lg",menuList:"",option:"text-select-text cursor-pointer",optionFocused:"bg-input-option-hover-bg text-body",optionSelected:"bg-input-option-active-bg text-input-option-active-text",optionDisabled:"text-input-placeholder cursor-not-allowed",group:"",groupHeading:"text-input-placeholder font-semibold",noOptionsMessage:"text-input-placeholder",loadingMessage:"text-input-placeholder",message:"text-positive-dark",messageBackground:"bg-positive-light",messageBorder:"border-positive",icon:"text-input-text",iconAction:"text-input-text hover:text-body",iconActionHover:"hover:text-body hover:bg-input-option-hover-bg"},warning:{control:"cursor-pointer bg-select-bg text-select-text",controlFocused:"border-input-warning-border",controlDisabled:"opacity-60",controlInvalid:"bg-select-bg border-input-error-border text-select-text",placeholder:"text-input-placeholder placeholder:opacity-60",singleValue:"text-select-text",singleValueDisabled:"text-input-placeholder",multiValue:"bg-input-option-active-bg text-input-option-active-text",multiValueLabel:"text-input-option-active-text",multiValueRemove:"text-input-option-active-text hover:bg-input-option-hover-bg hover:text-body rounded-xs p-px",multiValueRemoveHover:"hover:bg-input-option-hover-bg",multiValueDisabled:"bg-canvas-subtle text-muted",clearIndicator:"text-input-text hover:text-body cursor-pointer",clearIndicatorHover:"hover:text-body hover:bg-input-option-hover-bg",dropdownIndicator:"text-input-text",dropdownIndicatorHover:"hover:text-body hover:bg-input-option-hover-bg",indicatorSeparator:"bg-input-border",loadingIndicator:"text-warning",menu:"bg-select-list-bg border-select-border shadow-lg",menuList:"bg-select-list-bg border-select-border shadow-lg",option:"text-select-text cursor-pointer",optionFocused:"bg-input-option-hover-bg text-body",optionSelected:"bg-input-option-active-bg text-input-option-active-text",optionDisabled:"text-input-placeholder cursor-not-allowed",group:"",groupHeading:"text-input-placeholder font-semibold",noOptionsMessage:"text-input-placeholder",loadingMessage:"text-input-placeholder",message:"text-warning-dark",messageBackground:"bg-input-warning-bg",messageBorder:"border-input-warning-border",icon:"text-input-text",iconAction:"text-input-text hover:text-body",iconActionHover:"hover:text-body hover:bg-input-option-hover-bg"},negative:{control:"cursor-pointer bg-select-bg text-select-text",controlFocused:"border-input-error-border",controlDisabled:"opacity-60",controlInvalid:"bg-select-bg border-input-error-border text-select-text",placeholder:"text-input-placeholder placeholder:opacity-60",singleValue:"text-select-text",singleValueDisabled:"text-input-placeholder",multiValue:"bg-input-option-active-bg text-input-option-active-text",multiValueLabel:"text-input-option-active-text",multiValueRemove:"text-input-option-active-text hover:bg-input-option-hover-bg hover:text-body rounded-xs p-px",multiValueRemoveHover:"hover:bg-input-option-hover-bg",multiValueDisabled:"bg-canvas-subtle text-muted",clearIndicator:"text-input-text hover:text-body cursor-pointer",clearIndicatorHover:"hover:text-body hover:bg-input-option-hover-bg",dropdownIndicator:"text-input-text",dropdownIndicatorHover:"hover:text-body hover:bg-input-option-hover-bg",indicatorSeparator:"bg-input-border",loadingIndicator:"text-negative",menu:"bg-select-list-bg border-select-border shadow-lg",menuList:"scrollbar-thin scrollbar-thumb-input-border scrollbar-track-transparent",option:"text-select-text cursor-pointer",optionFocused:"bg-input-option-hover-bg text-body",optionSelected:"bg-input-option-active-bg text-input-option-active-text",optionDisabled:"text-input-placeholder cursor-not-allowed",group:"",groupHeading:"text-input-placeholder font-semibold",noOptionsMessage:"text-input-placeholder",loadingMessage:"text-input-placeholder",message:"text-negative-dark",messageBackground:"bg-input-error-bg",messageBorder:"border-input-error-border",icon:"text-input-text",iconAction:"text-input-text hover:text-body",iconActionHover:"hover:text-body hover:bg-input-option-hover-bg"}},FY=({size:e,color:t,isDisabled:r,isFocused:n,isInvalid:o,hasMessage:i})=>xe("flex items-center justify-between border border-select-border only:rounded first:rounded-t last:rounded-b",ur[e].control,o&&!n?Et[t].controlInvalid:Et[t].control,{[Et[t].controlFocused]:n&&!i,[Et[t].controlDisabled]:r,"border-0 ring-1":i,[Et[t].messageBorder]:i}),$Y=({isMulti:e})=>xe("flex items-center gap-1 flex-1 min-w-0 overflow-hidden",{"flex-wrap":e,"px-0.5":!e}),VY=({size:e,color:t})=>xe("bg-transparent border-0 outline-hidden flex-1 min-w-7.5 px-1",ur[e].input,Et[t].placeholder),HY=({size:e,color:t})=>xe("select-none truncate",ur[e].placeholder,Et[t].placeholder),WY=({size:e,color:t,isDisabled:r})=>xe("truncate",ur[e].singleValue,r?Et[t].singleValueDisabled:Et[t].singleValue),UY=({size:e,color:t,isDisabled:r,isFocused:n})=>xe("inline-flex items-center rounded-xs",ur[e].multiValue,r?Et[t].multiValueDisabled:Et[t].multiValue,{"border border-white":n&&!r}),GY=({size:e})=>xe("truncate",ur[e].multiValueLabel),YY=({size:e,color:t,isDisabled:r})=>xe("flex items-center justify-center cursor-pointer transition-colors",ur[e].multiValueRemove,Et[t].multiValueRemove),Wq=({size:e,color:t,isDisabled:r})=>xe("flex items-center justify-center transition-colors rounded",ur[e].clearIndicator,r?"hidden":[Et[t].clearIndicator,Et[t].clearIndicatorHover]),KY=({size:e,color:t,isDisabled:r})=>xe("flex items-center justify-center transition-colors rounded",ur[e].dropdownIndicator,r?"text-grey-200":[Et[t].dropdownIndicator,Et[t].dropdownIndicatorHover]),XY=({size:e,placement:t,hasMessage:r,color:n})=>{const o={auto:"top-full rounded-t-none",bottom:"top-full rounded-t-none",top:"bottom-full rounded-b-none"};return xe("absolute w-full z-50 rounded overflow-hidden border border-t-0",Et.primary.menu,{[Et[n].messageBorder]:r},o[t||"auto"],ur[e].menu)},ZY=({size:e})=>xe("overflow-y-auto",ur[e].menuList,Et.primary.menuList),JY=({size:e,color:t,isDisabled:r,isFocused:n,isSelected:o})=>xe("transition-colors duration-150 cursor-pointer mx-1 rounded",ur[e].option,{[Et[t].optionDisabled]:r,[Et[t].optionSelected]:o&&!r,[Et[t].optionFocused]:n&&!o&&!r,[Et[t].option]:!o&&!n&&!r}),QY=({size:e})=>xe(ur[e].group),eK=({size:e,color:t})=>xe(ur[e].groupHeading,Et[t].groupHeading),tK=({size:e})=>xe("text-grey-100",ur[e].loadingMessage),rK=({size:e})=>xe(ur[e].noOptionsMessage,Et.primary.noOptionsMessage),nK=e=>e.length>0&&"options"in e[0];function ms(e,t){if(e==null)return{};var r={};for(var n in e)if({}.hasOwnProperty.call(e,n)){if(t.indexOf(n)!==-1)continue;r[n]=e[n]}return r}function jt(){return jt=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)({}).hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},jt.apply(null,arguments)}function c_(e,t){return c_=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,n){return r.__proto__=n,r},c_(e,t)}function oK(e,t){e.prototype=Object.create(t.prototype),e.prototype.constructor=e,c_(e,t)}var Kc={exports:{}},bh={exports:{}},it={};/** @license React v16.13.1
|
|
8
19
|
* react-is.production.min.js
|
|
9
20
|
*
|
|
10
21
|
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
11
22
|
*
|
|
12
23
|
* This source code is licensed under the MIT license found in the
|
|
13
24
|
* LICENSE file in the root directory of this source tree.
|
|
14
|
-
*/var
|
|
25
|
+
*/var jC;function iK(){if(jC)return it;jC=1;var e=typeof Symbol=="function"&&Symbol.for,t=e?Symbol.for("react.element"):60103,r=e?Symbol.for("react.portal"):60106,n=e?Symbol.for("react.fragment"):60107,o=e?Symbol.for("react.strict_mode"):60108,i=e?Symbol.for("react.profiler"):60114,a=e?Symbol.for("react.provider"):60109,s=e?Symbol.for("react.context"):60110,c=e?Symbol.for("react.async_mode"):60111,u=e?Symbol.for("react.concurrent_mode"):60111,d=e?Symbol.for("react.forward_ref"):60112,f=e?Symbol.for("react.suspense"):60113,h=e?Symbol.for("react.suspense_list"):60120,v=e?Symbol.for("react.memo"):60115,b=e?Symbol.for("react.lazy"):60116,g=e?Symbol.for("react.block"):60121,m=e?Symbol.for("react.fundamental"):60117,x=e?Symbol.for("react.responder"):60118,w=e?Symbol.for("react.scope"):60119;function E(_){if(typeof _=="object"&&_!==null){var C=_.$$typeof;switch(C){case t:switch(_=_.type,_){case c:case u:case n:case i:case o:case f:return _;default:switch(_=_&&_.$$typeof,_){case s:case d:case b:case v:case a:return _;default:return C}}case r:return C}}}function S(_){return E(_)===u}return it.AsyncMode=c,it.ConcurrentMode=u,it.ContextConsumer=s,it.ContextProvider=a,it.Element=t,it.ForwardRef=d,it.Fragment=n,it.Lazy=b,it.Memo=v,it.Portal=r,it.Profiler=i,it.StrictMode=o,it.Suspense=f,it.isAsyncMode=function(_){return S(_)||E(_)===c},it.isConcurrentMode=S,it.isContextConsumer=function(_){return E(_)===s},it.isContextProvider=function(_){return E(_)===a},it.isElement=function(_){return typeof _=="object"&&_!==null&&_.$$typeof===t},it.isForwardRef=function(_){return E(_)===d},it.isFragment=function(_){return E(_)===n},it.isLazy=function(_){return E(_)===b},it.isMemo=function(_){return E(_)===v},it.isPortal=function(_){return E(_)===r},it.isProfiler=function(_){return E(_)===i},it.isStrictMode=function(_){return E(_)===o},it.isSuspense=function(_){return E(_)===f},it.isValidElementType=function(_){return typeof _=="string"||typeof _=="function"||_===n||_===u||_===i||_===o||_===f||_===h||typeof _=="object"&&_!==null&&(_.$$typeof===b||_.$$typeof===v||_.$$typeof===a||_.$$typeof===s||_.$$typeof===d||_.$$typeof===m||_.$$typeof===x||_.$$typeof===w||_.$$typeof===g)},it.typeOf=E,it}var ut={};/** @license React v16.13.1
|
|
15
26
|
* react-is.development.js
|
|
16
27
|
*
|
|
17
28
|
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
18
29
|
*
|
|
19
30
|
* This source code is licensed under the MIT license found in the
|
|
20
31
|
* LICENSE file in the root directory of this source tree.
|
|
21
|
-
*/var
|
|
32
|
+
*/var LC;function aK(){return LC||(LC=1,process.env.NODE_ENV!=="production"&&(function(){var e=typeof Symbol=="function"&&Symbol.for,t=e?Symbol.for("react.element"):60103,r=e?Symbol.for("react.portal"):60106,n=e?Symbol.for("react.fragment"):60107,o=e?Symbol.for("react.strict_mode"):60108,i=e?Symbol.for("react.profiler"):60114,a=e?Symbol.for("react.provider"):60109,s=e?Symbol.for("react.context"):60110,c=e?Symbol.for("react.async_mode"):60111,u=e?Symbol.for("react.concurrent_mode"):60111,d=e?Symbol.for("react.forward_ref"):60112,f=e?Symbol.for("react.suspense"):60113,h=e?Symbol.for("react.suspense_list"):60120,v=e?Symbol.for("react.memo"):60115,b=e?Symbol.for("react.lazy"):60116,g=e?Symbol.for("react.block"):60121,m=e?Symbol.for("react.fundamental"):60117,x=e?Symbol.for("react.responder"):60118,w=e?Symbol.for("react.scope"):60119;function E(te){return typeof te=="string"||typeof te=="function"||te===n||te===u||te===i||te===o||te===f||te===h||typeof te=="object"&&te!==null&&(te.$$typeof===b||te.$$typeof===v||te.$$typeof===a||te.$$typeof===s||te.$$typeof===d||te.$$typeof===m||te.$$typeof===x||te.$$typeof===w||te.$$typeof===g)}function S(te){if(typeof te=="object"&&te!==null){var be=te.$$typeof;switch(be){case t:var de=te.type;switch(de){case c:case u:case n:case i:case o:case f:return de;default:var Ee=de&&de.$$typeof;switch(Ee){case s:case d:case b:case v:case a:return Ee;default:return be}}case r:return be}}}var _=c,C=u,N=s,P=a,A=t,j=d,M=n,L=b,D=v,T=r,W=i,q=o,G=f,F=!1;function J(te){return F||(F=!0,console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 17+. Update your code to use ReactIs.isConcurrentMode() instead. It has the exact same API.")),z(te)||S(te)===c}function z(te){return S(te)===u}function U(te){return S(te)===s}function oe(te){return S(te)===a}function re(te){return typeof te=="object"&&te!==null&&te.$$typeof===t}function $(te){return S(te)===d}function Y(te){return S(te)===n}function X(te){return S(te)===b}function H(te){return S(te)===v}function K(te){return S(te)===r}function Q(te){return S(te)===i}function ne(te){return S(te)===o}function se(te){return S(te)===f}ut.AsyncMode=_,ut.ConcurrentMode=C,ut.ContextConsumer=N,ut.ContextProvider=P,ut.Element=A,ut.ForwardRef=j,ut.Fragment=M,ut.Lazy=L,ut.Memo=D,ut.Portal=T,ut.Profiler=W,ut.StrictMode=q,ut.Suspense=G,ut.isAsyncMode=J,ut.isConcurrentMode=z,ut.isContextConsumer=U,ut.isContextProvider=oe,ut.isElement=re,ut.isForwardRef=$,ut.isFragment=Y,ut.isLazy=X,ut.isMemo=H,ut.isPortal=K,ut.isProfiler=Q,ut.isStrictMode=ne,ut.isSuspense=se,ut.isValidElementType=E,ut.typeOf=S})()),ut}var qC;function Uq(){return qC||(qC=1,process.env.NODE_ENV==="production"?bh.exports=iK():bh.exports=aK()),bh.exports}/*
|
|
22
33
|
object-assign
|
|
23
34
|
(c) Sindre Sorhus
|
|
24
35
|
@license MIT
|
|
25
|
-
*/var
|
|
26
|
-
Valid keys: `+JSON.stringify(Object.keys(
|
|
36
|
+
*/var yh,zC;function sK(){if(zC)return yh;zC=1;var e=Object.getOwnPropertySymbols,t=Object.prototype.hasOwnProperty,r=Object.prototype.propertyIsEnumerable;function n(i){if(i==null)throw new TypeError("Object.assign cannot be called with null or undefined");return Object(i)}function o(){try{if(!Object.assign)return!1;var i=new String("abc");if(i[5]="de",Object.getOwnPropertyNames(i)[0]==="5")return!1;for(var a={},s=0;s<10;s++)a["_"+String.fromCharCode(s)]=s;var c=Object.getOwnPropertyNames(a).map(function(d){return a[d]});if(c.join("")!=="0123456789")return!1;var u={};return"abcdefghijklmnopqrst".split("").forEach(function(d){u[d]=d}),Object.keys(Object.assign({},u)).join("")==="abcdefghijklmnopqrst"}catch{return!1}}return yh=o()?Object.assign:function(i,a){for(var s,c=n(i),u,d=1;d<arguments.length;d++){s=Object(arguments[d]);for(var f in s)t.call(s,f)&&(c[f]=s[f]);if(e){u=e(s);for(var h=0;h<u.length;h++)r.call(s,u[h])&&(c[u[h]]=s[u[h]])}}return c},yh}var xh,BC;function l1(){if(BC)return xh;BC=1;var e="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED";return xh=e,xh}var FC,$C;function Gq(){return $C||($C=1,FC=Function.call.bind(Object.prototype.hasOwnProperty)),FC}var wh,VC;function lK(){if(VC)return wh;VC=1;var e=function(){};if(process.env.NODE_ENV!=="production"){var t=l1(),r={},n=Gq();e=function(i){var a="Warning: "+i;typeof console<"u"&&console.error(a);try{throw new Error(a)}catch{}}}function o(i,a,s,c,u){if(process.env.NODE_ENV!=="production"){for(var d in i)if(n(i,d)){var f;try{if(typeof i[d]!="function"){var h=Error((c||"React class")+": "+s+" type `"+d+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+typeof i[d]+"`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");throw h.name="Invariant Violation",h}f=i[d](a,d,c,s,null,t)}catch(b){f=b}if(f&&!(f instanceof Error)&&e((c||"React class")+": type specification of "+s+" `"+d+"` is invalid; the type checker function must return `null` or an `Error` but returned a "+typeof f+". You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument)."),f instanceof Error&&!(f.message in r)){r[f.message]=!0;var v=u?u():"";e("Failed "+s+" type: "+f.message+(v??""))}}}}return o.resetWarningCache=function(){process.env.NODE_ENV!=="production"&&(r={})},wh=o,wh}var _h,HC;function cK(){if(HC)return _h;HC=1;var e=Uq(),t=sK(),r=l1(),n=Gq(),o=lK(),i=function(){};process.env.NODE_ENV!=="production"&&(i=function(s){var c="Warning: "+s;typeof console<"u"&&console.error(c);try{throw new Error(c)}catch{}});function a(){return null}return _h=function(s,c){var u=typeof Symbol=="function"&&Symbol.iterator,d="@@iterator";function f(z){var U=z&&(u&&z[u]||z[d]);if(typeof U=="function")return U}var h="<<anonymous>>",v={array:x("array"),bigint:x("bigint"),bool:x("boolean"),func:x("function"),number:x("number"),object:x("object"),string:x("string"),symbol:x("symbol"),any:w(),arrayOf:E,element:S(),elementType:_(),instanceOf:C,node:j(),objectOf:P,oneOf:N,oneOfType:A,shape:L,exact:D};function b(z,U){return z===U?z!==0||1/z===1/U:z!==z&&U!==U}function g(z,U){this.message=z,this.data=U&&typeof U=="object"?U:{},this.stack=""}g.prototype=Error.prototype;function m(z){if(process.env.NODE_ENV!=="production")var U={},oe=0;function re(Y,X,H,K,Q,ne,se){if(K=K||h,ne=ne||H,se!==r){if(c){var te=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use `PropTypes.checkPropTypes()` to call them. Read more at http://fb.me/use-check-prop-types");throw te.name="Invariant Violation",te}else if(process.env.NODE_ENV!=="production"&&typeof console<"u"){var be=K+":"+H;!U[be]&&oe<3&&(i("You are manually calling a React.PropTypes validation function for the `"+ne+"` prop on `"+K+"`. This is deprecated and will throw in the standalone `prop-types` package. You may be seeing this warning due to a third-party PropTypes library. See https://fb.me/react-warning-dont-call-proptypes for details."),U[be]=!0,oe++)}}return X[H]==null?Y?X[H]===null?new g("The "+Q+" `"+ne+"` is marked as required "+("in `"+K+"`, but its value is `null`.")):new g("The "+Q+" `"+ne+"` is marked as required in "+("`"+K+"`, but its value is `undefined`.")):null:z(X,H,K,Q,ne)}var $=re.bind(null,!1);return $.isRequired=re.bind(null,!0),$}function x(z){function U(oe,re,$,Y,X,H){var K=oe[re],Q=q(K);if(Q!==z){var ne=G(K);return new g("Invalid "+Y+" `"+X+"` of type "+("`"+ne+"` supplied to `"+$+"`, expected ")+("`"+z+"`."),{expectedType:z})}return null}return m(U)}function w(){return m(a)}function E(z){function U(oe,re,$,Y,X){if(typeof z!="function")return new g("Property `"+X+"` of component `"+$+"` has invalid PropType notation inside arrayOf.");var H=oe[re];if(!Array.isArray(H)){var K=q(H);return new g("Invalid "+Y+" `"+X+"` of type "+("`"+K+"` supplied to `"+$+"`, expected an array."))}for(var Q=0;Q<H.length;Q++){var ne=z(H,Q,$,Y,X+"["+Q+"]",r);if(ne instanceof Error)return ne}return null}return m(U)}function S(){function z(U,oe,re,$,Y){var X=U[oe];if(!s(X)){var H=q(X);return new g("Invalid "+$+" `"+Y+"` of type "+("`"+H+"` supplied to `"+re+"`, expected a single ReactElement."))}return null}return m(z)}function _(){function z(U,oe,re,$,Y){var X=U[oe];if(!e.isValidElementType(X)){var H=q(X);return new g("Invalid "+$+" `"+Y+"` of type "+("`"+H+"` supplied to `"+re+"`, expected a single ReactElement type."))}return null}return m(z)}function C(z){function U(oe,re,$,Y,X){if(!(oe[re]instanceof z)){var H=z.name||h,K=J(oe[re]);return new g("Invalid "+Y+" `"+X+"` of type "+("`"+K+"` supplied to `"+$+"`, expected ")+("instance of `"+H+"`."))}return null}return m(U)}function N(z){if(!Array.isArray(z))return process.env.NODE_ENV!=="production"&&(arguments.length>1?i("Invalid arguments supplied to oneOf, expected an array, got "+arguments.length+" arguments. A common mistake is to write oneOf(x, y, z) instead of oneOf([x, y, z])."):i("Invalid argument supplied to oneOf, expected an array.")),a;function U(oe,re,$,Y,X){for(var H=oe[re],K=0;K<z.length;K++)if(b(H,z[K]))return null;var Q=JSON.stringify(z,function(ne,se){var te=G(se);return te==="symbol"?String(se):se});return new g("Invalid "+Y+" `"+X+"` of value `"+String(H)+"` "+("supplied to `"+$+"`, expected one of "+Q+"."))}return m(U)}function P(z){function U(oe,re,$,Y,X){if(typeof z!="function")return new g("Property `"+X+"` of component `"+$+"` has invalid PropType notation inside objectOf.");var H=oe[re],K=q(H);if(K!=="object")return new g("Invalid "+Y+" `"+X+"` of type "+("`"+K+"` supplied to `"+$+"`, expected an object."));for(var Q in H)if(n(H,Q)){var ne=z(H,Q,$,Y,X+"."+Q,r);if(ne instanceof Error)return ne}return null}return m(U)}function A(z){if(!Array.isArray(z))return process.env.NODE_ENV!=="production"&&i("Invalid argument supplied to oneOfType, expected an instance of array."),a;for(var U=0;U<z.length;U++){var oe=z[U];if(typeof oe!="function")return i("Invalid argument supplied to oneOfType. Expected an array of check functions, but received "+F(oe)+" at index "+U+"."),a}function re($,Y,X,H,K){for(var Q=[],ne=0;ne<z.length;ne++){var se=z[ne],te=se($,Y,X,H,K,r);if(te==null)return null;te.data&&n(te.data,"expectedType")&&Q.push(te.data.expectedType)}var be=Q.length>0?", expected one of type ["+Q.join(", ")+"]":"";return new g("Invalid "+H+" `"+K+"` supplied to "+("`"+X+"`"+be+"."))}return m(re)}function j(){function z(U,oe,re,$,Y){return T(U[oe])?null:new g("Invalid "+$+" `"+Y+"` supplied to "+("`"+re+"`, expected a ReactNode."))}return m(z)}function M(z,U,oe,re,$){return new g((z||"React class")+": "+U+" type `"+oe+"."+re+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+$+"`.")}function L(z){function U(oe,re,$,Y,X){var H=oe[re],K=q(H);if(K!=="object")return new g("Invalid "+Y+" `"+X+"` of type `"+K+"` "+("supplied to `"+$+"`, expected `object`."));for(var Q in z){var ne=z[Q];if(typeof ne!="function")return M($,Y,X,Q,G(ne));var se=ne(H,Q,$,Y,X+"."+Q,r);if(se)return se}return null}return m(U)}function D(z){function U(oe,re,$,Y,X){var H=oe[re],K=q(H);if(K!=="object")return new g("Invalid "+Y+" `"+X+"` of type `"+K+"` "+("supplied to `"+$+"`, expected `object`."));var Q=t({},oe[re],z);for(var ne in Q){var se=z[ne];if(n(z,ne)&&typeof se!="function")return M($,Y,X,ne,G(se));if(!se)return new g("Invalid "+Y+" `"+X+"` key `"+ne+"` supplied to `"+$+"`.\nBad object: "+JSON.stringify(oe[re],null," ")+`
|
|
37
|
+
Valid keys: `+JSON.stringify(Object.keys(z),null," "));var te=se(H,ne,$,Y,X+"."+ne,r);if(te)return te}return null}return m(U)}function T(z){switch(typeof z){case"number":case"string":case"undefined":return!0;case"boolean":return!z;case"object":if(Array.isArray(z))return z.every(T);if(z===null||s(z))return!0;var U=f(z);if(U){var oe=U.call(z),re;if(U!==z.entries){for(;!(re=oe.next()).done;)if(!T(re.value))return!1}else for(;!(re=oe.next()).done;){var $=re.value;if($&&!T($[1]))return!1}}else return!1;return!0;default:return!1}}function W(z,U){return z==="symbol"?!0:U?U["@@toStringTag"]==="Symbol"||typeof Symbol=="function"&&U instanceof Symbol:!1}function q(z){var U=typeof z;return Array.isArray(z)?"array":z instanceof RegExp?"object":W(U,z)?"symbol":U}function G(z){if(typeof z>"u"||z===null)return""+z;var U=q(z);if(U==="object"){if(z instanceof Date)return"date";if(z instanceof RegExp)return"regexp"}return U}function F(z){var U=G(z);switch(U){case"array":case"object":return"an "+U;case"boolean":case"date":case"regexp":return"a "+U;default:return U}}function J(z){return!z.constructor||!z.constructor.name?h:z.constructor.name}return v.checkPropTypes=o,v.resetWarningCache=o.resetWarningCache,v.PropTypes=v,v},_h}var Eh,WC;function uK(){if(WC)return Eh;WC=1;var e=l1();function t(){}function r(){}return r.resetWarningCache=t,Eh=function(){function n(a,s,c,u,d,f){if(f!==e){var h=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw h.name="Invariant Violation",h}}n.isRequired=n;function o(){return n}var i={array:n,bigint:n,bool:n,func:n,number:n,object:n,string:n,symbol:n,any:n,arrayOf:o,element:n,elementType:n,instanceOf:o,node:n,objectOf:o,oneOf:o,oneOfType:o,shape:o,exact:o,checkPropTypes:r,resetWarningCache:t};return i.PropTypes=i,i},Eh}var UC;function dK(){if(UC)return Kc.exports;if(UC=1,process.env.NODE_ENV!=="production"){var e=Uq(),t=!0;Kc.exports=cK()(e.isElement,t)}else Kc.exports=uK()();return Kc.exports}var fK=dK();const we=YL(fK);var Sh={exports:{}},at={};/**
|
|
38
|
+
* @license React
|
|
27
39
|
* react-is.production.min.js
|
|
28
40
|
*
|
|
29
41
|
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
30
42
|
*
|
|
31
43
|
* This source code is licensed under the MIT license found in the
|
|
32
44
|
* LICENSE file in the root directory of this source tree.
|
|
33
|
-
*/var
|
|
45
|
+
*/var GC;function pK(){if(GC)return at;GC=1;var e=Symbol.for("react.element"),t=Symbol.for("react.portal"),r=Symbol.for("react.fragment"),n=Symbol.for("react.strict_mode"),o=Symbol.for("react.profiler"),i=Symbol.for("react.provider"),a=Symbol.for("react.context"),s=Symbol.for("react.server_context"),c=Symbol.for("react.forward_ref"),u=Symbol.for("react.suspense"),d=Symbol.for("react.suspense_list"),f=Symbol.for("react.memo"),h=Symbol.for("react.lazy"),v=Symbol.for("react.offscreen"),b;b=Symbol.for("react.module.reference");function g(m){if(typeof m=="object"&&m!==null){var x=m.$$typeof;switch(x){case e:switch(m=m.type,m){case r:case o:case n:case u:case d:return m;default:switch(m=m&&m.$$typeof,m){case s:case a:case c:case h:case f:case i:return m;default:return x}}case t:return x}}}return at.ContextConsumer=a,at.ContextProvider=i,at.Element=e,at.ForwardRef=c,at.Fragment=r,at.Lazy=h,at.Memo=f,at.Portal=t,at.Profiler=o,at.StrictMode=n,at.Suspense=u,at.SuspenseList=d,at.isAsyncMode=function(){return!1},at.isConcurrentMode=function(){return!1},at.isContextConsumer=function(m){return g(m)===a},at.isContextProvider=function(m){return g(m)===i},at.isElement=function(m){return typeof m=="object"&&m!==null&&m.$$typeof===e},at.isForwardRef=function(m){return g(m)===c},at.isFragment=function(m){return g(m)===r},at.isLazy=function(m){return g(m)===h},at.isMemo=function(m){return g(m)===f},at.isPortal=function(m){return g(m)===t},at.isProfiler=function(m){return g(m)===o},at.isStrictMode=function(m){return g(m)===n},at.isSuspense=function(m){return g(m)===u},at.isSuspenseList=function(m){return g(m)===d},at.isValidElementType=function(m){return typeof m=="string"||typeof m=="function"||m===r||m===o||m===n||m===u||m===d||m===v||typeof m=="object"&&m!==null&&(m.$$typeof===h||m.$$typeof===f||m.$$typeof===i||m.$$typeof===a||m.$$typeof===c||m.$$typeof===b||m.getModuleId!==void 0)},at.typeOf=g,at}var dt={};/**
|
|
46
|
+
* @license React
|
|
34
47
|
* react-is.development.js
|
|
35
48
|
*
|
|
36
49
|
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
37
50
|
*
|
|
38
51
|
* This source code is licensed under the MIT license found in the
|
|
39
52
|
* LICENSE file in the root directory of this source tree.
|
|
40
|
-
*/var cN;function NX(){return cN||(cN=1,process.env.NODE_ENV!=="production"&&(function(){var e=60103,t=60106,r=60107,n=60108,i=60114,o=60109,a=60110,u=60112,c=60113,d=60120,f=60115,h=60116,p=60121,v=60122,m=60117,y=60129,x=60131;if(typeof Symbol=="function"&&Symbol.for){var b=Symbol.for;e=b("react.element"),t=b("react.portal"),r=b("react.fragment"),n=b("react.strict_mode"),i=b("react.profiler"),o=b("react.provider"),a=b("react.context"),u=b("react.forward_ref"),c=b("react.suspense"),d=b("react.suspense_list"),f=b("react.memo"),h=b("react.lazy"),p=b("react.block"),v=b("react.server.block"),m=b("react.fundamental"),b("react.scope"),b("react.opaque.id"),y=b("react.debug_trace_mode"),b("react.offscreen"),x=b("react.legacy_hidden")}var w=!1;function S(ue){return!!(typeof ue=="string"||typeof ue=="function"||ue===r||ue===i||ue===y||ue===n||ue===c||ue===d||ue===x||w||typeof ue=="object"&&ue!==null&&(ue.$$typeof===h||ue.$$typeof===f||ue.$$typeof===o||ue.$$typeof===a||ue.$$typeof===u||ue.$$typeof===m||ue.$$typeof===p||ue[0]===v))}function E(ue){if(typeof ue=="object"&&ue!==null){var de=ue.$$typeof;switch(de){case e:var we=ue.type;switch(we){case r:case i:case n:case c:case d:return we;default:var Se=we&&we.$$typeof;switch(Se){case a:case u:case h:case f:case o:return Se;default:return de}}case t:return de}}}var _=a,R=o,I=e,N=u,D=r,k=h,B=f,L=t,j=i,T=n,F=c,$=!1,W=!1;function Y(ue){return $||($=!0,console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 18+.")),!1}function ee(ue){return W||(W=!0,console.warn("The ReactIs.isConcurrentMode() alias has been deprecated, and will be removed in React 18+.")),!1}function H(ue){return E(ue)===a}function Q(ue){return E(ue)===o}function ce(ue){return typeof ue=="object"&&ue!==null&&ue.$$typeof===e}function se(ue){return E(ue)===u}function z(ue){return E(ue)===r}function G(ue){return E(ue)===h}function J(ue){return E(ue)===f}function V(ue){return E(ue)===t}function K(ue){return E(ue)===i}function ie(ue){return E(ue)===n}function ne(ue){return E(ue)===c}Qe.ContextConsumer=_,Qe.ContextProvider=R,Qe.Element=I,Qe.ForwardRef=N,Qe.Fragment=D,Qe.Lazy=k,Qe.Memo=B,Qe.Portal=L,Qe.Profiler=j,Qe.StrictMode=T,Qe.Suspense=F,Qe.isAsyncMode=Y,Qe.isConcurrentMode=ee,Qe.isContextConsumer=H,Qe.isContextProvider=Q,Qe.isElement=ce,Qe.isForwardRef=se,Qe.isFragment=z,Qe.isLazy=G,Qe.isMemo=J,Qe.isPortal=V,Qe.isProfiler=K,Qe.isStrictMode=ie,Qe.isSuspense=ne,Qe.isValidElementType=S,Qe.typeOf=E})()),Qe}var lN;function TX(){return lN||(lN=1,process.env.NODE_ENV==="production"?Su.exports=PX():Su.exports=NX()),Su.exports}var fN=TX();function dN(e){return typeof e=="object"&&e!=null&&e.nodeType===1}function hN(e,t){return(!t||e!=="hidden")&&e!=="visible"&&e!=="clip"}function Bm(e,t){if(e.clientHeight<e.scrollHeight||e.clientWidth<e.scrollWidth){var r=getComputedStyle(e,null);return hN(r.overflowY,t)||hN(r.overflowX,t)||(function(n){var i=(function(o){if(!o.ownerDocument||!o.ownerDocument.defaultView)return null;try{return o.ownerDocument.defaultView.frameElement}catch{return null}})(n);return!!i&&(i.clientHeight<n.scrollHeight||i.clientWidth<n.scrollWidth)})(e)}return!1}function Ou(e,t,r,n,i,o,a,u){return o<e&&a>t||o>e&&a<t?0:o<=e&&u<=r||a>=t&&u>=r?o-e-n:a>t&&u<r||o<e&&u>r?a-t+i:0}var AX=function(e,t){var r=window,n=t.inline,i=t.boundary,o=t.skipOverflowHiddenElements,a=typeof i=="function"?i:function(de){return de!==i};if(!dN(e))throw new TypeError("Invalid target");for(var u,c,d=document.scrollingElement||document.documentElement,f=[],h=e;dN(h)&&a(h);){if((h=(c=(u=h).parentElement)==null?u.getRootNode().host||null:c)===d){f.push(h);break}h!=null&&h===document.body&&Bm(h)&&!Bm(document.documentElement)||h!=null&&Bm(h,o)&&f.push(h)}for(var p=r.visualViewport?r.visualViewport.width:innerWidth,v=r.visualViewport?r.visualViewport.height:innerHeight,m=window.scrollX||pageXOffset,y=window.scrollY||pageYOffset,x=e.getBoundingClientRect(),b=x.height,w=x.width,S=x.top,E=x.right,_=x.bottom,R=x.left,I=S,N=n==="center"?R+w/2:n==="end"?E:R,D=[],k=0;k<f.length;k++){var B=f[k],L=B.getBoundingClientRect(),j=L.height,T=L.width,F=L.top,$=L.right,W=L.bottom,Y=L.left;if(S>=0&&R>=0&&_<=v&&E<=p&&S>=F&&_<=W&&R>=Y&&E<=$)return D;var ee=getComputedStyle(B),H=parseInt(ee.borderLeftWidth,10),Q=parseInt(ee.borderTopWidth,10),ce=parseInt(ee.borderRightWidth,10),se=parseInt(ee.borderBottomWidth,10),z=0,G=0,J="offsetWidth"in B?B.offsetWidth-B.clientWidth-H-ce:0,V="offsetHeight"in B?B.offsetHeight-B.clientHeight-Q-se:0,K="offsetWidth"in B?B.offsetWidth===0?0:T/B.offsetWidth:0,ie="offsetHeight"in B?B.offsetHeight===0?0:j/B.offsetHeight:0;if(d===B)z=Ou(y,y+v,v,Q,se,y+I,y+I+b,b),G=n==="start"?N:n==="center"?N-p/2:n==="end"?N-p:Ou(m,m+p,p,H,ce,m+N,m+N+w,w),z=Math.max(0,z+y),G=Math.max(0,G+m);else{z=Ou(F,W,j,Q,se+V,I,I+b,b),G=n==="start"?N-Y-H:n==="center"?N-(Y+T/2)+J/2:n==="end"?N-$+ce+J:Ou(Y,$,T,H,ce+J,N,N+w,w);var ne=B.scrollLeft,ue=B.scrollTop;I+=ue-(z=Math.max(0,Math.min(ue+z/ie,B.scrollHeight-j/ie+V))),N+=ne-(G=Math.max(0,Math.min(ne+G/K,B.scrollWidth-T/K+J)))}D.push({el:B,top:z,left:G})}return D},cc=function(){return cc=Object.assign||function(t){for(var r,n=1,i=arguments.length;n<i;n++){r=arguments[n];for(var o in r)Object.prototype.hasOwnProperty.call(r,o)&&(t[o]=r[o])}return t},cc.apply(this,arguments)};let MX=0;function pN(e){return typeof e=="function"?e:br}function br(){}function b2(e,t){if(!e)return;AX(e,{boundary:t}).forEach(n=>{let{el:i,top:o,left:a}=n;i.scrollTop=o,i.scrollLeft=a})}function vN(e,t,r){return e===t||t instanceof r.Node&&e.contains&&e.contains(t)}function Gx(e,t){let r;function n(){r&&clearTimeout(r)}function i(){for(var o=arguments.length,a=new Array(o),u=0;u<o;u++)a[u]=arguments[u];n(),r=setTimeout(()=>{r=null,e(...a)},t)}return i.cancel=n,i}function Ot(){for(var e=arguments.length,t=new Array(e),r=0;r<e;r++)t[r]=arguments[r];return function(n){for(var i=arguments.length,o=new Array(i>1?i-1:0),a=1;a<i;a++)o[a-1]=arguments[a];return t.some(u=>(u&&u(n,...o),n.preventDownshiftDefault||n.hasOwnProperty("nativeEvent")&&n.nativeEvent.preventDownshiftDefault))}}function si(){for(var e=arguments.length,t=new Array(e),r=0;r<e;r++)t[r]=arguments[r];return n=>{t.forEach(i=>{typeof i=="function"?i(n):i&&(i.current=n)})}}function x2(){return String(MX++)}function w2(e){let{isOpen:t,resultCount:r,previousResultCount:n}=e;return t?r?r!==n?`${r} result${r===1?" is":"s are"} available, use up and down arrow keys to navigate. Press Enter key to select.`:"":"No results are available.":""}function gN(e,t){return e=Array.isArray(e)?e[0]:e,!e&&t?t:e}function _2(e){return typeof e.type=="string"}function E2(e){return e.props}function DX(e,t){console.error(`The property "${t}" is required in "${e}"`)}const jX=["highlightedIndex","inputValue","isOpen","selectedItem","type"];function Cu(e){e===void 0&&(e={});const t={};return jX.forEach(r=>{e.hasOwnProperty(r)&&(t[r]=e[r])}),t}function lc(e,t){return Object.keys(e).reduce((r,n)=>(r[n]=fc(t,n)?t[n]:e[n],r),{})}function fc(e,t){return e[t]!==void 0}function Vb(e){const{key:t,keyCode:r}=e;return r>=37&&r<=40&&t.indexOf("Arrow")!==0?`Arrow${t}`:t}function qX(e){return Object.prototype.toString.call(e)==="[object Object]"}function so(e,t,r,n,i){if(i===void 0&&(i=!0),r===0)return-1;const o=r-1;(typeof t!="number"||t<0||t>=r)&&(t=e>0?-1:o+1);let a=t+e;a<0?a=i?o:0:a>o&&(a=i?0:o);const u=xi(e,a,r,n,i);return u===-1?t>=r?-1:t:u}function xi(e,t,r,n,i){const o=n(t);if(!o||!o.hasAttribute("disabled"))return t;if(e>0){for(let a=t+1;a<r;a++)if(!n(a).hasAttribute("disabled"))return a}else for(let a=t-1;a>=0;a--)if(!n(a).hasAttribute("disabled"))return a;return i?e>0?xi(1,0,r,n,!1):xi(-1,r-1,r,n,!1):-1}function dc(e,t,r,n){return n===void 0&&(n=!0),t.some(i=>i&&(vN(i,e,r)||n&&vN(i,r.document.activeElement,r)))}let Kx=br;process.env.NODE_ENV!=="production"&&(Kx=(e,t,r)=>{const n="This prop should not switch from controlled to uncontrolled (or vice versa). Decide between using a controlled or uncontrolled Downshift element for the lifetime of the component. More info: https://github.com/downshift-js/downshift#control-props";Object.keys(e).forEach(i=>{t[i]!==void 0&&r[i]===void 0?console.error(`downshift: A component has changed the controlled prop "${i}" to be uncontrolled. ${n}`):t[i]===void 0&&r[i]!==void 0&&console.error(`downshift: A component has changed the uncontrolled prop "${i}" to be controlled. ${n}`)})});const kX=Gx(e=>{O2(e).textContent=""},500);function S2(e,t){const r=O2(t);e&&(r.textContent=e,kX(t))}function O2(e){e===void 0&&(e=document);let t=e.getElementById("a11y-status-message");return t||(t=e.createElement("div"),t.setAttribute("id","a11y-status-message"),t.setAttribute("role","status"),t.setAttribute("aria-live","polite"),t.setAttribute("aria-relevant","additions text"),Object.assign(t.style,{border:"0",clip:"rect(0 0 0 0)",height:"1px",margin:"-1px",overflow:"hidden",padding:"0",position:"absolute",width:"1px"}),e.body.appendChild(t),t)}const C2=process.env.NODE_ENV!=="production"?"__autocomplete_unknown__":0,R2=process.env.NODE_ENV!=="production"?"__autocomplete_mouseup__":1,I2=process.env.NODE_ENV!=="production"?"__autocomplete_item_mouseenter__":2,Bu=process.env.NODE_ENV!=="production"?"__autocomplete_keydown_arrow_up__":3,Fu=process.env.NODE_ENV!=="production"?"__autocomplete_keydown_arrow_down__":4,P2=process.env.NODE_ENV!=="production"?"__autocomplete_keydown_escape__":5,N2=process.env.NODE_ENV!=="production"?"__autocomplete_keydown_enter__":6,T2=process.env.NODE_ENV!=="production"?"__autocomplete_keydown_home__":7,A2=process.env.NODE_ENV!=="production"?"__autocomplete_keydown_end__":8,M2=process.env.NODE_ENV!=="production"?"__autocomplete_click_item__":9,D2=process.env.NODE_ENV!=="production"?"__autocomplete_blur_input__":10,j2=process.env.NODE_ENV!=="production"?"__autocomplete_change_input__":11,q2=process.env.NODE_ENV!=="production"?"__autocomplete_keydown_space_button__":12,Wb=process.env.NODE_ENV!=="production"?"__autocomplete_click_button__":13,k2=process.env.NODE_ENV!=="production"?"__autocomplete_blur_button__":14,L2=process.env.NODE_ENV!=="production"?"__autocomplete_controlled_prop_updated_selected_item__":15,B2=process.env.NODE_ENV!=="production"?"__autocomplete_touchend__":16;var LX=Object.freeze({__proto__:null,unknown:C2,mouseUp:R2,itemMouseEnter:I2,keyDownArrowUp:Bu,keyDownArrowDown:Fu,keyDownEscape:P2,keyDownEnter:N2,keyDownHome:T2,keyDownEnd:A2,clickItem:M2,blurInput:D2,changeInput:j2,keyDownSpaceButton:q2,clickButton:Wb,blurButton:k2,controlledPropUpdatedSelectedItem:L2,touchEnd:B2});const BX=(()=>{class e extends A.Component{constructor(r){var n;super(r),n=this,this.id=this.props.id||`downshift-${x2()}`,this.menuId=this.props.menuId||`${this.id}-menu`,this.labelId=this.props.labelId||`${this.id}-label`,this.inputId=this.props.inputId||`${this.id}-input`,this.getItemId=this.props.getItemId||(h=>`${this.id}-item-${h}`),this.input=null,this.items=[],this.itemCount=null,this.previousResultCount=0,this.timeoutIds=[],this.internalSetTimeout=(h,p)=>{const v=setTimeout(()=>{this.timeoutIds=this.timeoutIds.filter(m=>m!==v),h()},p);this.timeoutIds.push(v)},this.setItemCount=h=>{this.itemCount=h},this.unsetItemCount=()=>{this.itemCount=null},this.setHighlightedIndex=function(h,p){h===void 0&&(h=n.props.defaultHighlightedIndex),p===void 0&&(p={}),p=Cu(p),n.internalSetState({highlightedIndex:h,...p})},this.clearSelection=h=>{this.internalSetState({selectedItem:null,inputValue:"",highlightedIndex:this.props.defaultHighlightedIndex,isOpen:this.props.defaultIsOpen},h)},this.selectItem=(h,p,v)=>{p=Cu(p),this.internalSetState({isOpen:this.props.defaultIsOpen,highlightedIndex:this.props.defaultHighlightedIndex,selectedItem:h,inputValue:this.props.itemToString(h),...p},v)},this.selectItemAtIndex=(h,p,v)=>{const m=this.items[h];m!=null&&this.selectItem(m,p,v)},this.selectHighlightedItem=(h,p)=>this.selectItemAtIndex(this.getState().highlightedIndex,h,p),this.internalSetState=(h,p)=>{let v,m;const y={},x=typeof h=="function";return!x&&h.hasOwnProperty("inputValue")&&this.props.onInputValueChange(h.inputValue,{...this.getStateAndHelpers(),...h}),this.setState(b=>{b=this.getState(b);let w=x?h(b):h;w=this.props.stateReducer(b,w),v=w.hasOwnProperty("selectedItem");const S={};return v&&w.selectedItem!==b.selectedItem&&(m=w.selectedItem),w.type=w.type||C2,Object.keys(w).forEach(E=>{b[E]!==w[E]&&(y[E]=w[E]),E!=="type"&&(w[E],fc(this.props,E)||(S[E]=w[E]))}),x&&w.hasOwnProperty("inputValue")&&this.props.onInputValueChange(w.inputValue,{...this.getStateAndHelpers(),...w}),S},()=>{pN(p)(),Object.keys(y).length>1&&this.props.onStateChange(y,this.getStateAndHelpers()),v&&this.props.onSelect(h.selectedItem,this.getStateAndHelpers()),m!==void 0&&this.props.onChange(m,this.getStateAndHelpers()),this.props.onUserAction(y,this.getStateAndHelpers())})},this.rootRef=h=>this._rootNode=h,this.getRootProps=function(h,p){let{refKey:v="ref",ref:m,...y}=h===void 0?{}:h,{suppressRefError:x=!1}=p===void 0?{}:p;n.getRootProps.called=!0,n.getRootProps.refKey=v,n.getRootProps.suppressRefError=x;const{isOpen:b}=n.getState();return{[v]:si(m,n.rootRef),role:"combobox","aria-expanded":b,"aria-haspopup":"listbox","aria-owns":b?n.menuId:null,"aria-labelledby":n.labelId,...y}},this.keyDownHandlers={ArrowDown(h){if(h.preventDefault(),this.getState().isOpen){const p=h.shiftKey?5:1;this.moveHighlightedIndex(p,{type:Fu})}else this.internalSetState({isOpen:!0,type:Fu},()=>{const p=this.getItemCount();if(p>0){const{highlightedIndex:v}=this.getState(),m=so(1,v,p,y=>this.getItemNodeFromIndex(y));this.setHighlightedIndex(m,{type:Fu})}})},ArrowUp(h){if(h.preventDefault(),this.getState().isOpen){const p=h.shiftKey?-5:-1;this.moveHighlightedIndex(p,{type:Bu})}else this.internalSetState({isOpen:!0,type:Bu},()=>{const p=this.getItemCount();if(p>0){const{highlightedIndex:v}=this.getState(),m=so(-1,v,p,y=>this.getItemNodeFromIndex(y));this.setHighlightedIndex(m,{type:Bu})}})},Enter(h){if(h.which===229)return;const{isOpen:p,highlightedIndex:v}=this.getState();if(p&&v!=null){h.preventDefault();const m=this.items[v],y=this.getItemNodeFromIndex(v);if(m==null||y&&y.hasAttribute("disabled"))return;this.selectHighlightedItem({type:N2})}},Escape(h){h.preventDefault(),this.reset({type:P2,...!this.state.isOpen&&{selectedItem:null,inputValue:""}})}},this.buttonKeyDownHandlers={...this.keyDownHandlers," "(h){h.preventDefault(),this.toggleMenu({type:q2})}},this.inputKeyDownHandlers={...this.keyDownHandlers,Home(h){const{isOpen:p}=this.getState();if(!p)return;h.preventDefault();const v=this.getItemCount();if(v<=0||!p)return;const m=xi(1,0,v,y=>this.getItemNodeFromIndex(y),!1);this.setHighlightedIndex(m,{type:T2})},End(h){const{isOpen:p}=this.getState();if(!p)return;h.preventDefault();const v=this.getItemCount();if(v<=0||!p)return;const m=xi(-1,v-1,v,y=>this.getItemNodeFromIndex(y),!1);this.setHighlightedIndex(m,{type:A2})}},this.getToggleButtonProps=function(h){let{onClick:p,onPress:v,onKeyDown:m,onKeyUp:y,onBlur:x,...b}=h===void 0?{}:h;const{isOpen:w}=n.getState(),S={onClick:Ot(p,n.buttonHandleClick),onKeyDown:Ot(m,n.buttonHandleKeyDown),onKeyUp:Ot(y,n.buttonHandleKeyUp),onBlur:Ot(x,n.buttonHandleBlur)},E=b.disabled?{}:S;return{type:"button",role:"button","aria-label":w?"close menu":"open menu","aria-haspopup":!0,"data-toggle":!0,...E,...b}},this.buttonHandleKeyUp=h=>{h.preventDefault()},this.buttonHandleKeyDown=h=>{const p=Vb(h);this.buttonKeyDownHandlers[p]&&this.buttonKeyDownHandlers[p].call(this,h)},this.buttonHandleClick=h=>{h.preventDefault(),this.props.environment.document.activeElement===this.props.environment.document.body&&h.target.focus(),process.env.NODE_ENV==="test"?this.toggleMenu({type:Wb}):this.internalSetTimeout(()=>this.toggleMenu({type:Wb}))},this.buttonHandleBlur=h=>{const p=h.target;this.internalSetTimeout(()=>{!this.isMouseDown&&(this.props.environment.document.activeElement==null||this.props.environment.document.activeElement.id!==this.inputId)&&this.props.environment.document.activeElement!==p&&this.reset({type:k2})})},this.getLabelProps=h=>({htmlFor:this.inputId,id:this.labelId,...h}),this.getInputProps=function(h){let{onKeyDown:p,onBlur:v,onChange:m,onInput:y,onChangeText:x,...b}=h===void 0?{}:h,w,S={};w="onChange";const{inputValue:E,isOpen:_,highlightedIndex:R}=n.getState();return b.disabled||(S={[w]:Ot(m,y,n.inputHandleChange),onKeyDown:Ot(p,n.inputHandleKeyDown),onBlur:Ot(v,n.inputHandleBlur)}),{"aria-autocomplete":"list","aria-activedescendant":_&&typeof R=="number"&&R>=0?n.getItemId(R):null,"aria-controls":_?n.menuId:null,"aria-labelledby":n.labelId,autoComplete:"off",value:E,id:n.inputId,...S,...b}},this.inputHandleKeyDown=h=>{const p=Vb(h);p&&this.inputKeyDownHandlers[p]&&this.inputKeyDownHandlers[p].call(this,h)},this.inputHandleChange=h=>{this.internalSetState({type:j2,isOpen:!0,inputValue:h.target.value,highlightedIndex:this.props.defaultHighlightedIndex})},this.inputHandleBlur=()=>{this.internalSetTimeout(()=>{const h=this.props.environment.document&&!!this.props.environment.document.activeElement&&!!this.props.environment.document.activeElement.dataset&&this.props.environment.document.activeElement.dataset.toggle&&this._rootNode&&this._rootNode.contains(this.props.environment.document.activeElement);!this.isMouseDown&&!h&&this.reset({type:D2})})},this.menuRef=h=>{this._menuNode=h},this.getMenuProps=function(h,p){let{refKey:v="ref",ref:m,...y}=h===void 0?{}:h,{suppressRefError:x=!1}=p===void 0?{}:p;return n.getMenuProps.called=!0,n.getMenuProps.refKey=v,n.getMenuProps.suppressRefError=x,{[v]:si(m,n.menuRef),role:"listbox","aria-labelledby":y&&y["aria-label"]?null:n.labelId,id:n.menuId,...y}},this.getItemProps=function(h){let{onMouseMove:p,onMouseDown:v,onClick:m,onPress:y,index:x,item:b=process.env.NODE_ENV==="production"?void 0:DX("getItemProps","item"),...w}=h===void 0?{}:h;x===void 0?(n.items.push(b),x=n.items.indexOf(b)):n.items[x]=b;const S="onClick",E=m,_={onMouseMove:Ot(p,()=>{x!==n.getState().highlightedIndex&&(n.setHighlightedIndex(x,{type:I2}),n.avoidScrolling=!0,n.internalSetTimeout(()=>n.avoidScrolling=!1,250))}),onMouseDown:Ot(v,I=>{I.preventDefault()}),[S]:Ot(E,()=>{n.selectItemAtIndex(x,{type:M2})})},R=w.disabled?{onMouseDown:_.onMouseDown}:_;return{id:n.getItemId(x),role:"option","aria-selected":n.getState().highlightedIndex===x,...R,...w}},this.clearItems=()=>{this.items=[]},this.reset=function(h,p){h===void 0&&(h={}),h=Cu(h),n.internalSetState(v=>{let{selectedItem:m}=v;return{isOpen:n.props.defaultIsOpen,highlightedIndex:n.props.defaultHighlightedIndex,inputValue:n.props.itemToString(m),...h}},p)},this.toggleMenu=function(h,p){h===void 0&&(h={}),h=Cu(h),n.internalSetState(v=>{let{isOpen:m}=v;return{isOpen:!m,...m&&{highlightedIndex:n.props.defaultHighlightedIndex},...h}},()=>{const{isOpen:v,highlightedIndex:m}=n.getState();v&&n.getItemCount()>0&&typeof m=="number"&&n.setHighlightedIndex(m,h),pN(p)()})},this.openMenu=h=>{this.internalSetState({isOpen:!0},h)},this.closeMenu=h=>{this.internalSetState({isOpen:!1},h)},this.updateStatus=Gx(()=>{const h=this.getState(),p=this.items[h.highlightedIndex],v=this.getItemCount(),m=this.props.getA11yStatusMessage({itemToString:this.props.itemToString,previousResultCount:this.previousResultCount,resultCount:v,highlightedItem:p,...h});this.previousResultCount=v,S2(m,this.props.environment.document)},200);const{defaultHighlightedIndex:i,initialHighlightedIndex:o=i,defaultIsOpen:a,initialIsOpen:u=a,initialInputValue:c="",initialSelectedItem:d=null}=this.props,f=this.getState({highlightedIndex:o,isOpen:u,inputValue:c,selectedItem:d});f.selectedItem!=null&&this.props.initialInputValue===void 0&&(f.inputValue=this.props.itemToString(f.selectedItem)),this.state=f}internalClearTimeouts(){this.timeoutIds.forEach(r=>{clearTimeout(r)}),this.timeoutIds=[]}getState(r){return r===void 0&&(r=this.state),lc(r,this.props)}getItemCount(){let r=this.items.length;return this.itemCount!=null?r=this.itemCount:this.props.itemCount!==void 0&&(r=this.props.itemCount),r}getItemNodeFromIndex(r){return this.props.environment.document.getElementById(this.getItemId(r))}scrollHighlightedItemIntoView(){{const r=this.getItemNodeFromIndex(this.getState().highlightedIndex);this.props.scrollIntoView(r,this._menuNode)}}moveHighlightedIndex(r,n){const i=this.getItemCount(),{highlightedIndex:o}=this.getState();if(i>0){const a=so(r,o,i,u=>this.getItemNodeFromIndex(u));this.setHighlightedIndex(a,n)}}getStateAndHelpers(){const{highlightedIndex:r,inputValue:n,selectedItem:i,isOpen:o}=this.getState(),{itemToString:a}=this.props,{id:u}=this,{getRootProps:c,getToggleButtonProps:d,getLabelProps:f,getMenuProps:h,getInputProps:p,getItemProps:v,openMenu:m,closeMenu:y,toggleMenu:x,selectItem:b,selectItemAtIndex:w,selectHighlightedItem:S,setHighlightedIndex:E,clearSelection:_,clearItems:R,reset:I,setItemCount:N,unsetItemCount:D,internalSetState:k}=this;return{getRootProps:c,getToggleButtonProps:d,getLabelProps:f,getMenuProps:h,getInputProps:p,getItemProps:v,reset:I,openMenu:m,closeMenu:y,toggleMenu:x,selectItem:b,selectItemAtIndex:w,selectHighlightedItem:S,setHighlightedIndex:E,clearSelection:_,clearItems:R,setItemCount:N,unsetItemCount:D,setState:k,itemToString:a,id:u,highlightedIndex:r,inputValue:n,isOpen:o,selectedItem:i}}componentDidMount(){process.env.NODE_ENV!=="production"&&this.getMenuProps.called&&!this.getMenuProps.suppressRefError&&mN(this._menuNode,this.getMenuProps);{const r=()=>{this.isMouseDown=!0},n=c=>{this.isMouseDown=!1,!dc(c.target,[this._rootNode,this._menuNode],this.props.environment)&&this.getState().isOpen&&this.reset({type:R2},()=>this.props.onOuterClick(this.getStateAndHelpers()))},i=()=>{this.isTouchMove=!1},o=()=>{this.isTouchMove=!0},a=c=>{const d=dc(c.target,[this._rootNode,this._menuNode],this.props.environment,!1);!this.isTouchMove&&!d&&this.getState().isOpen&&this.reset({type:B2},()=>this.props.onOuterClick(this.getStateAndHelpers()))},{environment:u}=this.props;u.addEventListener("mousedown",r),u.addEventListener("mouseup",n),u.addEventListener("touchstart",i),u.addEventListener("touchmove",o),u.addEventListener("touchend",a),this.cleanup=()=>{this.internalClearTimeouts(),this.updateStatus.cancel(),u.removeEventListener("mousedown",r),u.removeEventListener("mouseup",n),u.removeEventListener("touchstart",i),u.removeEventListener("touchmove",o),u.removeEventListener("touchend",a)}}}shouldScroll(r,n){const{highlightedIndex:i}=this.props.highlightedIndex===void 0?this.getState():this.props,{highlightedIndex:o}=n.highlightedIndex===void 0?r:n;return i&&this.getState().isOpen&&!r.isOpen||i!==o}componentDidUpdate(r,n){process.env.NODE_ENV!=="production"&&(Kx(this.state,r,this.props),this.getMenuProps.called&&!this.getMenuProps.suppressRefError&&mN(this._menuNode,this.getMenuProps)),fc(this.props,"selectedItem")&&this.props.selectedItemChanged(r.selectedItem,this.props.selectedItem)&&this.internalSetState({type:L2,inputValue:this.props.itemToString(this.props.selectedItem)}),!this.avoidScrolling&&this.shouldScroll(n,r)&&this.scrollHighlightedItemIntoView(),this.updateStatus()}componentWillUnmount(){this.cleanup()}render(){const r=gN(this.props.children,br);this.clearItems(),this.getRootProps.called=!1,this.getRootProps.refKey=void 0,this.getRootProps.suppressRefError=void 0,this.getMenuProps.called=!1,this.getMenuProps.refKey=void 0,this.getMenuProps.suppressRefError=void 0,this.getLabelProps.called=!1,this.getInputProps.called=!1;const n=gN(r(this.getStateAndHelpers()));if(!n)return null;if(this.getRootProps.called||this.props.suppressRefError)return process.env.NODE_ENV!=="production"&&!this.getRootProps.suppressRefError&&!this.props.suppressRefError&&FX(n,this.getRootProps),n;if(_2(n))return A.cloneElement(n,this.getRootProps(E2(n)));if(process.env.NODE_ENV!=="production")throw new Error("downshift: If you return a non-DOM element, you must apply the getRootProps function")}}return e.defaultProps={defaultHighlightedIndex:null,defaultIsOpen:!1,getA11yStatusMessage:w2,itemToString:t=>t==null?"":(process.env.NODE_ENV!=="production"&&qX(t)&&!t.hasOwnProperty("toString")&&console.warn("downshift: An object was passed to the default implementation of `itemToString`. You should probably provide your own `itemToString` implementation. Please refer to the `itemToString` API documentation.","The object that was passed:",t),String(t)),onStateChange:br,onInputValueChange:br,onUserAction:br,onChange:br,onSelect:br,onOuterClick:br,selectedItemChanged:(t,r)=>t!==r,environment:typeof window>"u"?{}:window,stateReducer:(t,r)=>r,suppressRefError:!1,scrollIntoView:b2},e.stateChangeTypes=LX,e})();process.env.NODE_ENV!=="production"&&(BX.propTypes={children:le.func,defaultHighlightedIndex:le.number,defaultIsOpen:le.bool,initialHighlightedIndex:le.number,initialSelectedItem:le.any,initialInputValue:le.string,initialIsOpen:le.bool,getA11yStatusMessage:le.func,itemToString:le.func,onChange:le.func,onSelect:le.func,onStateChange:le.func,onInputValueChange:le.func,onUserAction:le.func,onOuterClick:le.func,selectedItemChanged:le.func,stateReducer:le.func,itemCount:le.number,id:le.string,environment:le.shape({addEventListener:le.func,removeEventListener:le.func,document:le.shape({getElementById:le.func,activeElement:le.any,body:le.any})}),suppressRefError:le.bool,scrollIntoView:le.func,selectedItem:le.any,isOpen:le.bool,inputValue:le.string,highlightedIndex:le.number,labelId:le.string,inputId:le.string,menuId:le.string,getItemId:le.func});function mN(e,t){let{refKey:r}=t;e||console.error(`downshift: The ref prop "${r}" from getMenuProps was not applied correctly on your menu element.`)}function FX(e,t){let{refKey:r}=t;const n=r!=="ref",i=!_2(e);i&&!n&&!fN.isForwardRef(e)?console.error("downshift: You returned a non-DOM element. You must specify a refKey in getRootProps"):!i&&n&&console.error(`downshift: You returned a DOM element. You should not specify a refKey in getRootProps. You specified "${r}"`),!fN.isForwardRef(e)&&!E2(e)[r]&&console.error(`downshift: You must apply the ref prop "${r}" from getRootProps onto your root element.`)}const F2={highlightedIndex:-1,isOpen:!1,selectedItem:null,inputValue:""};function $X(e,t,r){const{props:n,type:i}=e,o={};Object.keys(t).forEach(a=>{zX(a,e,t,r),r[a]!==t[a]&&(o[a]=r[a])}),n.onStateChange&&Object.keys(o).length&&n.onStateChange({type:i,...o})}function zX(e,t,r,n){const{props:i,type:o}=t,a=`on${Yx(e)}Change`;i[a]&&n[e]!==void 0&&n[e]!==r[e]&&i[a]({type:o,...n})}function HX(e,t){return t.changes}function UX(e){const{selectedItem:t,itemToString:r}=e;return t?`${r(t)} has been selected.`:""}const VX=Gx((e,t)=>{S2(e(),t)},200),WX=typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u"?A.useLayoutEffect:A.useEffect;function GX(e){let{id:t=`downshift-${x2()}`,labelId:r,menuId:n,getItemId:i,toggleButtonId:o,inputId:a}=e;return A.useRef({labelId:r||`${t}-label`,menuId:n||`${t}-menu`,getItemId:i||(c=>`${t}-item-${c}`),toggleButtonId:o||`${t}-toggle-button`,inputId:a||`${t}-input`}).current}function KX(e,t,r){return e!==void 0?e:r.length===0?-1:r.indexOf(t)}function YX(e){return e?String(e):""}function Yx(e){return`${e.slice(0,1).toUpperCase()}${e.slice(1)}`}function $2(e){const t=A.useRef(e);return t.current=e,t}function XX(e,t,r){const n=A.useRef(),i=A.useRef(),o=A.useCallback((h,p)=>{i.current=p,h=lc(h,p.props);const v=e(h,p);return p.props.stateReducer(h,{...p,changes:v})},[e]),[a,u]=A.useReducer(o,t),c=$2(r),d=A.useCallback(h=>u({props:c.current,...h}),[c]),f=i.current;return A.useEffect(()=>{f&&n.current&&n.current!==a&&$X(f,lc(n.current,f.props),a),n.current=a},[a,r,f]),[a,d]}const Ia={itemToString:YX,stateReducer:HX,getA11ySelectionMessage:UX,scrollIntoView:b2,circularNavigation:!1,environment:typeof window>"u"?{}:window};function Zr(e,t,r){r===void 0&&(r=F2);const n=e[`default${Yx(t)}`];return n!==void 0?n:r[t]}function Ru(e,t,r){r===void 0&&(r=F2);const n=e[t];if(n!==void 0)return n;const i=e[`initial${Yx(t)}`];return i!==void 0?i:Zr(e,t,r)}function ZX(e){const t=Ru(e,"selectedItem"),r=Ru(e,"isOpen"),n=Ru(e,"highlightedIndex"),i=Ru(e,"inputValue");return{highlightedIndex:n<0&&t&&r?e.items.indexOf(t):n,isOpen:r,selectedItem:t,inputValue:i}}function hc(e,t,r,n){const{items:i,initialHighlightedIndex:o,defaultHighlightedIndex:a}=e,{selectedItem:u,highlightedIndex:c}=t;return i.length===0?-1:o!==void 0&&c===o?o:a!==void 0?a:u?r===0?i.indexOf(u):so(r,i.indexOf(u),i.length,n,!1):r===0?-1:r<0?i.length-1:0}function JX(e,t,r,n){const i=A.useRef({isMouseDown:!1,isTouchMove:!1});return A.useEffect(()=>{const o=()=>{i.current.isMouseDown=!0},a=f=>{i.current.isMouseDown=!1,e&&!dc(f.target,t.map(h=>h.current),r)&&n()},u=()=>{i.current.isTouchMove=!1},c=()=>{i.current.isTouchMove=!0},d=f=>{e&&!i.current.isTouchMove&&!dc(f.target,t.map(h=>h.current),r,!1)&&n()};return r.addEventListener("mousedown",o),r.addEventListener("mouseup",a),r.addEventListener("touchstart",u),r.addEventListener("touchmove",c),r.addEventListener("touchend",d),function(){r.removeEventListener("mousedown",o),r.removeEventListener("mouseup",a),r.removeEventListener("touchstart",u),r.removeEventListener("touchmove",c),r.removeEventListener("touchend",d)}},[e,r]),i}let z2=()=>br;process.env.NODE_ENV!=="production"&&(z2=function(){const e=A.useRef(!0);for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];const i=A.useRef(r.reduce((a,u)=>(a[u]={},a),{}));return A.useEffect(()=>{Object.keys(i.current).forEach(a=>{const u=i.current[a];if(e.current&&!Object.keys(u).length){console.error(`downshift: You forgot to call the ${a} getter function on your component / element.`);return}const{suppressRefError:c,refKey:d,elementRef:f}=u;(!f||!f.current)&&!c&&console.error(`downshift: The ref prop "${d}" from ${a} was not applied correctly on your element.`)}),e.current=!1}),A.useCallback((a,u,c,d)=>{i.current[a]={suppressRefError:u,refKey:c,elementRef:d}},[])});function yN(e,t,r){let{isInitialMount:n,highlightedIndex:i,items:o,environment:a,...u}=r;A.useEffect(()=>{n||VX(()=>e({highlightedIndex:i,highlightedItem:o[i],resultCount:o.length,...u}),a.document)},t)}function QX(e){let{highlightedIndex:t,isOpen:r,itemRefs:n,getItemNodeFromIndex:i,menuElement:o,scrollIntoView:a}=e;const u=A.useRef(!0);return WX(()=>{t<0||!r||!Object.keys(n.current).length||(u.current===!1?u.current=!0:a(i(t),o))},[t]),u}let H2=br;process.env.NODE_ENV!=="production"&&(H2=e=>{let{isInitialMount:t,props:r,state:n}=e;const i=A.useRef(r);A.useEffect(()=>{t||(Kx(n,i.current,r),i.current=r)},[n,r,t])});function eZ(e,t,r){const{type:n,props:i}=t;let o;switch(n){case r.ItemMouseMove:o={highlightedIndex:t.disabled?-1:t.index};break;case r.MenuMouseLeave:o={highlightedIndex:-1};break;case r.ToggleButtonClick:case r.FunctionToggleMenu:o={isOpen:!e.isOpen,highlightedIndex:e.isOpen?-1:hc(i,e,0)};break;case r.FunctionOpenMenu:o={isOpen:!0,highlightedIndex:hc(i,e,0)};break;case r.FunctionCloseMenu:o={isOpen:!1};break;case r.FunctionSetHighlightedIndex:o={highlightedIndex:t.highlightedIndex};break;case r.FunctionSetInputValue:o={inputValue:t.inputValue};break;case r.FunctionReset:o={highlightedIndex:Zr(i,"highlightedIndex"),isOpen:Zr(i,"isOpen"),selectedItem:Zr(i,"selectedItem"),inputValue:Zr(i,"inputValue")};break;default:throw new Error("Reducer called without proper action type.")}return{...e,...o}}le.array.isRequired,le.func,le.func,le.func,le.bool,le.number,le.number,le.number,le.bool,le.bool,le.bool,le.any,le.any,le.any,le.string,le.string,le.string,le.func,le.string,le.func,le.func,le.func,le.func,le.func,le.shape({addEventListener:le.func,removeEventListener:le.func,document:le.shape({getElementById:le.func,activeElement:le.any,body:le.any})});function tZ(e){var t=e.isOpen,r=e.resultCount,n=e.previousResultCount;return t?r?r!==n?"".concat(r," result").concat(r===1?" is":"s are"," available, use up and down arrow keys to navigate. Press Enter or Space Bar keys to select."):"":"No results are available.":""}cc(cc({},Ia),{getA11yStatusMessage:tZ});process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;const Xx=process.env.NODE_ENV!=="production"?"__input_keydown_arrow_down__":0,Zx=process.env.NODE_ENV!=="production"?"__input_keydown_arrow_up__":1,Jx=process.env.NODE_ENV!=="production"?"__input_keydown_escape__":2,Qx=process.env.NODE_ENV!=="production"?"__input_keydown_home__":3,ew=process.env.NODE_ENV!=="production"?"__input_keydown_end__":4,tw=process.env.NODE_ENV!=="production"?"__input_keydown_enter__":5,rw=process.env.NODE_ENV!=="production"?"__input_change__":6,pc=process.env.NODE_ENV!=="production"?"__input_blur__":7,U2=process.env.NODE_ENV!=="production"?"__menu_mouse_leave__":8,V2=process.env.NODE_ENV!=="production"?"__item_mouse_move__":9,nw=process.env.NODE_ENV!=="production"?"__item_click__":10,W2=process.env.NODE_ENV!=="production"?"__togglebutton_click__":11,G2=process.env.NODE_ENV!=="production"?"__function_toggle_menu__":12,K2=process.env.NODE_ENV!=="production"?"__function_open_menu__":13,Y2=process.env.NODE_ENV!=="production"?"__function_close_menu__":14,X2=process.env.NODE_ENV!=="production"?"__function_set_highlighted_index__":15,iw=process.env.NODE_ENV!=="production"?"__function_select_item__":16,Z2=process.env.NODE_ENV!=="production"?"__function_set_input_value__":17,J2=process.env.NODE_ENV!=="production"?"__function_reset__":18,ow=process.env.NODE_ENV!=="production"?"__controlled_prop_updated_selected_item__":19;var Q2=Object.freeze({__proto__:null,InputKeyDownArrowDown:Xx,InputKeyDownArrowUp:Zx,InputKeyDownEscape:Jx,InputKeyDownHome:Qx,InputKeyDownEnd:ew,InputKeyDownEnter:tw,InputChange:rw,InputBlur:pc,MenuMouseLeave:U2,ItemMouseMove:V2,ItemClick:nw,ToggleButtonClick:W2,FunctionToggleMenu:G2,FunctionOpenMenu:K2,FunctionCloseMenu:Y2,FunctionSetHighlightedIndex:X2,FunctionSelectItem:iw,FunctionSetInputValue:Z2,FunctionReset:J2,ControlledPropUpdatedSelectedItem:ow});function rZ(e){const t=ZX(e),{selectedItem:r}=t;let{inputValue:n}=t;return n===""&&r&&e.defaultInputValue===void 0&&e.initialInputValue===void 0&&e.inputValue===void 0&&(n=e.itemToString(r)),{...t,inputValue:n}}const nZ={items:le.array.isRequired,itemToString:le.func,getA11yStatusMessage:le.func,getA11ySelectionMessage:le.func,circularNavigation:le.bool,highlightedIndex:le.number,defaultHighlightedIndex:le.number,initialHighlightedIndex:le.number,isOpen:le.bool,defaultIsOpen:le.bool,initialIsOpen:le.bool,selectedItem:le.any,initialSelectedItem:le.any,defaultSelectedItem:le.any,inputValue:le.string,defaultInputValue:le.string,initialInputValue:le.string,id:le.string,labelId:le.string,menuId:le.string,getItemId:le.func,inputId:le.string,toggleButtonId:le.string,stateReducer:le.func,onSelectedItemChange:le.func,onHighlightedIndexChange:le.func,onStateChange:le.func,onIsOpenChange:le.func,onInputValueChange:le.func,environment:le.shape({addEventListener:le.func,removeEventListener:le.func,document:le.shape({getElementById:le.func,activeElement:le.any,body:le.any})})};function iZ(e,t,r){const n=A.useRef(),[i,o]=XX(e,t,r);return A.useEffect(()=>{fc(r,"selectedItem")&&(n.current!==r.selectedItem&&o({type:ow,inputValue:r.itemToString(r.selectedItem)}),n.current=i.selectedItem===n.current?r.selectedItem:i.selectedItem)}),[lc(i,r),o]}let ek=br;process.env.NODE_ENV!=="production"&&(ek=(e,t)=>{le.checkPropTypes(nZ,e,"prop",t.name)});const oZ={...Ia,getA11yStatusMessage:w2,circularNavigation:!0};function aZ(e,t){const{type:r,props:n,shiftKey:i}=t;let o;switch(r){case nw:o={isOpen:Zr(n,"isOpen"),highlightedIndex:Zr(n,"highlightedIndex"),selectedItem:n.items[t.index],inputValue:n.itemToString(n.items[t.index])};break;case Xx:e.isOpen?o={highlightedIndex:so(i?5:1,e.highlightedIndex,n.items.length,t.getItemNodeFromIndex,n.circularNavigation)}:o={highlightedIndex:hc(n,e,1,t.getItemNodeFromIndex),isOpen:n.items.length>=0};break;case Zx:e.isOpen?o={highlightedIndex:so(i?-5:-1,e.highlightedIndex,n.items.length,t.getItemNodeFromIndex,n.circularNavigation)}:o={highlightedIndex:hc(n,e,-1,t.getItemNodeFromIndex),isOpen:n.items.length>=0};break;case tw:o={...e.isOpen&&e.highlightedIndex>=0&&{selectedItem:n.items[e.highlightedIndex],isOpen:Zr(n,"isOpen"),highlightedIndex:Zr(n,"highlightedIndex"),inputValue:n.itemToString(n.items[e.highlightedIndex])}};break;case Jx:o={isOpen:!1,highlightedIndex:-1,...!e.isOpen&&{selectedItem:null,inputValue:""}};break;case Qx:o={highlightedIndex:xi(1,0,n.items.length,t.getItemNodeFromIndex,!1)};break;case ew:o={highlightedIndex:xi(-1,n.items.length-1,n.items.length,t.getItemNodeFromIndex,!1)};break;case pc:o={isOpen:!1,highlightedIndex:-1,...e.highlightedIndex>=0&&t.selectItem&&{selectedItem:n.items[e.highlightedIndex],inputValue:n.itemToString(n.items[e.highlightedIndex])}};break;case rw:o={isOpen:!0,highlightedIndex:Zr(n,"highlightedIndex"),inputValue:t.inputValue};break;case iw:o={selectedItem:t.selectedItem,inputValue:n.itemToString(t.selectedItem)};break;case ow:o={inputValue:t.inputValue};break;default:return eZ(e,t,Q2)}return{...e,...o}}to.stateChangeTypes=Q2;function to(e){e===void 0&&(e={}),ek(e,to);const t={...oZ,...e},{initialIsOpen:r,defaultIsOpen:n,items:i,scrollIntoView:o,environment:a,getA11yStatusMessage:u,getA11ySelectionMessage:c,itemToString:d}=t,f=rZ(t),[h,p]=iZ(aZ,f,t),{isOpen:v,highlightedIndex:m,selectedItem:y,inputValue:x}=h,b=A.useRef(null),w=A.useRef({}),S=A.useRef(null),E=A.useRef(null),_=A.useRef(null),R=A.useRef(!0),I=GX(t),N=A.useRef(),D=$2({state:h,props:t}),k=A.useCallback(K=>w.current[I.getItemId(K)],[I]);yN(u,[v,m,x,i],{isInitialMount:R.current,previousResultCount:N.current,items:i,environment:a,itemToString:d,...h}),yN(c,[y],{isInitialMount:R.current,previousResultCount:N.current,items:i,environment:a,itemToString:d,...h});const B=QX({menuElement:b.current,highlightedIndex:m,isOpen:v,itemRefs:w,scrollIntoView:o,getItemNodeFromIndex:k});H2({isInitialMount:R.current,props:t,state:h}),A.useEffect(()=>{(r||n||v)&&S.current&&S.current.focus()},[]),A.useEffect(()=>{R.current||(N.current=i.length)});const L=JX(v,[_,b,E],a,()=>{p({type:pc,selectItem:!1})}),j=z2("getInputProps","getComboboxProps","getMenuProps");A.useEffect(()=>{R.current=!1},[]),A.useEffect(()=>{v||(w.current={})},[v]);const T=A.useMemo(()=>({ArrowDown(K){K.preventDefault(),p({type:Xx,shiftKey:K.shiftKey,getItemNodeFromIndex:k})},ArrowUp(K){K.preventDefault(),p({type:Zx,shiftKey:K.shiftKey,getItemNodeFromIndex:k})},Home(K){D.current.state.isOpen&&(K.preventDefault(),p({type:Qx,getItemNodeFromIndex:k}))},End(K){D.current.state.isOpen&&(K.preventDefault(),p({type:ew,getItemNodeFromIndex:k}))},Escape(K){const ie=D.current.state;(ie.isOpen||ie.inputValue||ie.selectedItem||ie.highlightedIndex>-1)&&(K.preventDefault(),p({type:Jx}))},Enter(K){const ie=D.current.state;!ie.isOpen||ie.highlightedIndex<0||K.which===229||(K.preventDefault(),p({type:tw,getItemNodeFromIndex:k}))}}),[p,D,k]),F=A.useCallback(K=>({id:I.labelId,htmlFor:I.inputId,...K}),[I]),$=A.useCallback(function(K,ie){let{onMouseLeave:ne,refKey:ue="ref",ref:de,...we}=K===void 0?{}:K,{suppressRefError:Se=!1}=ie===void 0?{}:ie;return j("getMenuProps",Se,ue,b),{[ue]:si(de,_e=>{b.current=_e}),id:I.menuId,role:"listbox","aria-labelledby":I.labelId,onMouseLeave:Ot(ne,()=>{p({type:U2})}),...we}},[p,j,I]),W=A.useCallback(function(K){let{item:ie,index:ne,refKey:ue="ref",ref:de,onMouseMove:we,onMouseDown:Se,onClick:_e,onPress:he,disabled:ae,...Oe}=K===void 0?{}:K;const{props:Ne,state:He}=D.current,qe=KX(ne,ie,Ne.items);if(qe<0)throw new Error("Pass either item or item index in getItemProps!");const Xe="onClick",We=_e,mt=()=>{ne!==He.highlightedIndex&&(B.current=!1,p({type:V2,index:ne,disabled:ae}))},et=()=>{p({type:nw,index:ne})},Tt=ut=>ut.preventDefault();return{[ue]:si(de,ut=>{ut&&(w.current[I.getItemId(qe)]=ut)}),disabled:ae,role:"option","aria-selected":`${qe===He.highlightedIndex}`,id:I.getItemId(qe),...!ae&&{[Xe]:Ot(We,et)},onMouseMove:Ot(we,mt),onMouseDown:Ot(Se,Tt),...Oe}},[p,D,B,I]),Y=A.useCallback(function(K){let{onClick:ie,onPress:ne,refKey:ue="ref",ref:de,...we}=K===void 0?{}:K;const Se=()=>{p({type:W2}),!D.current.state.isOpen&&S.current&&S.current.focus()};return{[ue]:si(de,_e=>{E.current=_e}),id:I.toggleButtonId,tabIndex:-1,...!we.disabled&&{onClick:Ot(ie,Se)},...we}},[p,D,I]),ee=A.useCallback(function(K,ie){let{onKeyDown:ne,onChange:ue,onInput:de,onBlur:we,onChangeText:Se,refKey:_e="ref",ref:he,...ae}=K===void 0?{}:K,{suppressRefError:Oe=!1}=ie===void 0?{}:ie;j("getInputProps",Oe,_e,S);const Ne=D.current.state,He=et=>{const Tt=Vb(et);Tt&&T[Tt]&&T[Tt](et)},qe=et=>{p({type:rw,inputValue:et.target.value})},Xe=()=>{Ne.isOpen&&!L.current.isMouseDown&&p({type:pc,selectItem:!0})},We="onChange";let mt={};return ae.disabled||(mt={[We]:Ot(ue,de,qe),onKeyDown:Ot(ne,He),onBlur:Ot(we,Xe)}),{[_e]:si(he,et=>{S.current=et}),id:I.inputId,"aria-autocomplete":"list","aria-controls":I.menuId,...Ne.isOpen&&Ne.highlightedIndex>-1&&{"aria-activedescendant":I.getItemId(Ne.highlightedIndex)},"aria-labelledby":I.labelId,autoComplete:"off",value:Ne.inputValue,...mt,...ae}},[p,T,D,L,j,I]),H=A.useCallback(function(K,ie){let{refKey:ne="ref",ref:ue,...de}=K===void 0?{}:K,{suppressRefError:we=!1}=ie===void 0?{}:ie;return j("getComboboxProps",we,ne,_),{[ne]:si(ue,Se=>{_.current=Se}),role:"combobox","aria-haspopup":"listbox","aria-owns":I.menuId,"aria-expanded":D.current.state.isOpen,...de}},[D,j,I]),Q=A.useCallback(()=>{p({type:G2})},[p]),ce=A.useCallback(()=>{p({type:Y2})},[p]),se=A.useCallback(()=>{p({type:K2})},[p]),z=A.useCallback(K=>{p({type:X2,highlightedIndex:K})},[p]),G=A.useCallback(K=>{p({type:iw,selectedItem:K})},[p]),J=A.useCallback(K=>{p({type:Z2,inputValue:K})},[p]),V=A.useCallback(()=>{p({type:J2})},[p]);return{getItemProps:W,getLabelProps:F,getMenuProps:$,getInputProps:ee,getComboboxProps:H,getToggleButtonProps:Y,toggleMenu:Q,openMenu:se,closeMenu:ce,setHighlightedIndex:z,setInputValue:J,selectItem:G,reset:V,highlightedIndex:m,isOpen:v,selectedItem:y,inputValue:x}}le.array,le.array,le.array,le.func,le.func,le.func,le.number,le.number,le.number,le.func,le.func,le.string,le.string,le.shape({addEventListener:le.func,removeEventListener:le.func,document:le.shape({getElementById:le.func,activeElement:le.any,body:le.any})});Ia.itemToString,Ia.stateReducer,Ia.environment;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;var Sa={exports:{}};/**
|
|
53
|
+
*/var YC;function hK(){return YC||(YC=1,process.env.NODE_ENV!=="production"&&(function(){var e=Symbol.for("react.element"),t=Symbol.for("react.portal"),r=Symbol.for("react.fragment"),n=Symbol.for("react.strict_mode"),o=Symbol.for("react.profiler"),i=Symbol.for("react.provider"),a=Symbol.for("react.context"),s=Symbol.for("react.server_context"),c=Symbol.for("react.forward_ref"),u=Symbol.for("react.suspense"),d=Symbol.for("react.suspense_list"),f=Symbol.for("react.memo"),h=Symbol.for("react.lazy"),v=Symbol.for("react.offscreen"),b=!1,g=!1,m=!1,x=!1,w=!1,E;E=Symbol.for("react.module.reference");function S(de){return!!(typeof de=="string"||typeof de=="function"||de===r||de===o||w||de===n||de===u||de===d||x||de===v||b||g||m||typeof de=="object"&&de!==null&&(de.$$typeof===h||de.$$typeof===f||de.$$typeof===i||de.$$typeof===a||de.$$typeof===c||de.$$typeof===E||de.getModuleId!==void 0))}function _(de){if(typeof de=="object"&&de!==null){var Ee=de.$$typeof;switch(Ee){case e:var fe=de.type;switch(fe){case r:case o:case n:case u:case d:return fe;default:var le=fe&&fe.$$typeof;switch(le){case s:case a:case c:case h:case f:case i:return le;default:return Ee}}case t:return Ee}}}var C=a,N=i,P=e,A=c,j=r,M=h,L=f,D=t,T=o,W=n,q=u,G=d,F=!1,J=!1;function z(de){return F||(F=!0,console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 18+.")),!1}function U(de){return J||(J=!0,console.warn("The ReactIs.isConcurrentMode() alias has been deprecated, and will be removed in React 18+.")),!1}function oe(de){return _(de)===a}function re(de){return _(de)===i}function $(de){return typeof de=="object"&&de!==null&&de.$$typeof===e}function Y(de){return _(de)===c}function X(de){return _(de)===r}function H(de){return _(de)===h}function K(de){return _(de)===f}function Q(de){return _(de)===t}function ne(de){return _(de)===o}function se(de){return _(de)===n}function te(de){return _(de)===u}function be(de){return _(de)===d}dt.ContextConsumer=C,dt.ContextProvider=N,dt.Element=P,dt.ForwardRef=A,dt.Fragment=j,dt.Lazy=M,dt.Memo=L,dt.Portal=D,dt.Profiler=T,dt.StrictMode=W,dt.Suspense=q,dt.SuspenseList=G,dt.isAsyncMode=z,dt.isConcurrentMode=U,dt.isContextConsumer=oe,dt.isContextProvider=re,dt.isElement=$,dt.isForwardRef=Y,dt.isFragment=X,dt.isLazy=H,dt.isMemo=K,dt.isPortal=Q,dt.isProfiler=ne,dt.isStrictMode=se,dt.isSuspense=te,dt.isSuspenseList=be,dt.isValidElementType=S,dt.typeOf=_})()),dt}var KC;function vK(){return KC||(KC=1,process.env.NODE_ENV==="production"?Sh.exports=pK():Sh.exports=hK()),Sh.exports}var XC=vK();const ZC=e=>typeof e=="object"&&e!=null&&e.nodeType===1,JC=(e,t)=>(!t||e!=="hidden")&&e!=="visible"&&e!=="clip",Xc=(e,t)=>{if(e.clientHeight<e.scrollHeight||e.clientWidth<e.scrollWidth){const r=getComputedStyle(e,null);return JC(r.overflowY,t)||JC(r.overflowX,t)||(n=>{const o=(i=>{if(!i.ownerDocument||!i.ownerDocument.defaultView)return null;try{return i.ownerDocument.defaultView.frameElement}catch{return null}})(n);return!!o&&(o.clientHeight<n.scrollHeight||o.clientWidth<n.scrollWidth)})(e)}return!1},Zc=(e,t,r,n,o,i,a,s)=>i<e&&a>t||i>e&&a<t?0:i<=e&&s<=r||a>=t&&s>=r?i-e-n:a>t&&s<r||i<e&&s>r?a-t+o:0,gK=e=>e.parentElement??(e.getRootNode().host||null),mK=(e,t)=>{var r,n,o,i;if(typeof document>"u")return[];const{inline:a,boundary:s,skipOverflowHiddenElements:c}=t,u=typeof s=="function"?s:D=>D!==s;if(!ZC(e))throw new TypeError("Invalid target");const d=document.scrollingElement||document.documentElement,f=[];let h=e;for(;ZC(h)&&u(h);){if(h=gK(h),h===d){f.push(h);break}h!=null&&h===document.body&&Xc(h)&&!Xc(document.documentElement)||h!=null&&Xc(h,c)&&f.push(h)}const v=(n=(r=window.visualViewport)==null?void 0:r.width)!=null?n:innerWidth,b=(i=(o=window.visualViewport)==null?void 0:o.height)!=null?i:innerHeight,{scrollX:g,scrollY:m}=window,{height:x,width:w,top:E,right:S,bottom:_,left:C}=e.getBoundingClientRect(),{top:N,right:P,left:A}=(D=>{const T=window.getComputedStyle(D);return{top:parseFloat(T.scrollMarginTop)||0,right:parseFloat(T.scrollMarginRight)||0,bottom:parseFloat(T.scrollMarginBottom)||0,left:parseFloat(T.scrollMarginLeft)||0}})(e);let j=E-N,M=a==="center"?C+w/2-A+P:a==="end"?S+P:C-A;const L=[];for(let D=0;D<f.length;D++){const T=f[D],{height:W,width:q,top:G,right:F,bottom:J,left:z}=T.getBoundingClientRect();if(E>=0&&C>=0&&_<=b&&S<=v&&(T===d&&!Xc(T)||E>=G&&_<=J&&C>=z&&S<=F))return L;const U=getComputedStyle(T),oe=parseInt(U.borderLeftWidth,10),re=parseInt(U.borderTopWidth,10),$=parseInt(U.borderRightWidth,10),Y=parseInt(U.borderBottomWidth,10);let X=0,H=0;const K="offsetWidth"in T?T.offsetWidth-T.clientWidth-oe-$:0,Q="offsetHeight"in T?T.offsetHeight-T.clientHeight-re-Y:0,ne="offsetWidth"in T?T.offsetWidth===0?0:q/T.offsetWidth:0,se="offsetHeight"in T?T.offsetHeight===0?0:W/T.offsetHeight:0;if(d===T)X=Zc(m,m+b,b,re,Y,m+j,m+j+x,x),H=a==="start"?M:a==="center"?M-v/2:a==="end"?M-v:Zc(g,g+v,v,oe,$,g+M,g+M+w,w),X=Math.max(0,X+m),H=Math.max(0,H+g);else{X=Zc(G,J,W,re,Y+Q,j,j+x,x),H=a==="start"?M-z-oe:a==="center"?M-(z+q/2)+K/2:a==="end"?M-F+$+K:Zc(z,F,q,oe,$+K,M,M+w,w);const{scrollLeft:te,scrollTop:be}=T;X=se===0?0:Math.max(0,Math.min(be+X/se,T.scrollHeight-W/se+Q)),H=ne===0?0:Math.max(0,Math.min(te+H/ne,T.scrollWidth-q/ne+K)),j+=be-X,M+=te-H}L.push({el:T,top:X,left:H})}return L};var _a=function(){return _a=Object.assign||function(e){for(var t,r=1,n=arguments.length;r<n;r++){t=arguments[r];for(var o in t)Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o])}return e},_a.apply(this,arguments)},bK=0;function QC(e){return typeof e=="function"?e:go}function go(){}function Yq(e,t){if(e){var r=mK(e,{boundary:t});r.forEach(function(n){var o=n.el,i=n.top,a=n.left;o.scrollTop=i,o.scrollLeft=a})}}function eR(e,t,r){var n=e===t||t instanceof r.Node&&e.contains&&e.contains(t);return n}function c1(e,t){var r;function n(){r&&clearTimeout(r)}function o(){for(var i=arguments.length,a=new Array(i),s=0;s<i;s++)a[s]=arguments[s];n(),r=setTimeout(function(){r=null,e.apply(void 0,a)},t)}return o.cancel=n,o}function Fn(){for(var e=arguments.length,t=new Array(e),r=0;r<e;r++)t[r]=arguments[r];return function(n){for(var o=arguments.length,i=new Array(o>1?o-1:0),a=1;a<o;a++)i[a-1]=arguments[a];return t.some(function(s){return s&&s.apply(void 0,[n].concat(i)),n.preventDownshiftDefault||n.hasOwnProperty("nativeEvent")&&n.nativeEvent.preventDownshiftDefault})}}function tR(){for(var e=arguments.length,t=new Array(e),r=0;r<e;r++)t[r]=arguments[r];return function(n){t.forEach(function(o){typeof o=="function"?o(n):o&&(o.current=n)})}}function yK(){return String(bK++)}function xK(e){var t=e.isOpen,r=e.resultCount,n=e.previousResultCount;return t?r?r!==n?r+" result"+(r===1?" is":"s are")+" available, use up and down arrow keys to navigate. Press Enter key to select.":"":"No results are available.":""}function rR(e,t){return e=Array.isArray(e)?e[0]:e,!e&&t?t:e}function Kq(e){return typeof e.type=="string"}function Xq(e){return e.props}function wK(e,t){console.error('The property "'+t+'" is required in "'+e+'"')}var _K=["highlightedIndex","inputValue","isOpen","selectedItem","type"];function Jc(e){e===void 0&&(e={});var t={};return _K.forEach(function(r){e.hasOwnProperty(r)&&(t[r]=e[r])}),t}function EK(e,t){return!e||!t?e:Object.keys(e).reduce(function(r,n){return r[n]=u_(t,n)?t[n]:e[n],r},{})}function u_(e,t){return e[t]!==void 0}function nR(e){var t=e.key,r=e.keyCode;return r>=37&&r<=40&&t.indexOf("Arrow")!==0?"Arrow"+t:t}function SK(e){return Object.prototype.toString.call(e)==="[object Object]"}function Oh(e,t,r,n,o){var i=r.length;if(i===0)return-1;var a=i-1;(typeof e!="number"||e<0||e>a)&&(e=t>0?-1:a+1);var s=e+t;s<0?s=a:s>a&&(s=0);var c=ed(s,t<0,r,n,o);return c===-1?e>=i?-1:e:c}function ed(e,t,r,n,o){o===void 0&&(o=!1);var i=r.length;if(t){for(var a=e;a>=0;a--)if(!n(r[a],a))return a}else for(var s=e;s<i;s++)if(!n(r[s],s))return s;return o?ed(t?i-1:0,t,r,n):-1}function oR(e,t,r,n){return n===void 0&&(n=!0),r&&t.some(function(o){return o&&(eR(o,e,r)||n&&eR(o,r.document.activeElement,r))})}var u1=go;process.env.NODE_ENV!=="production"&&(u1=function(e,t,r){var n="This prop should not switch from controlled to uncontrolled (or vice versa). Decide between using a controlled or uncontrolled Downshift element for the lifetime of the component. More info: https://github.com/downshift-js/downshift#control-props";Object.keys(e).forEach(function(o){t[o]!==void 0&&r[o]===void 0?console.error('downshift: A component has changed the controlled prop "'+o+'" to be uncontrolled. '+n):t[o]===void 0&&r[o]!==void 0&&console.error('downshift: A component has changed the uncontrolled prop "'+o+'" to be controlled. '+n)})});var OK=c1(function(e){Zq(e).textContent=""},500);function Zq(e){var t=e.getElementById("a11y-status-message");return t||(t=e.createElement("div"),t.setAttribute("id","a11y-status-message"),t.setAttribute("role","status"),t.setAttribute("aria-live","polite"),t.setAttribute("aria-relevant","additions text"),Object.assign(t.style,{border:"0",clip:"rect(0 0 0 0)",height:"1px",margin:"-1px",overflow:"hidden",padding:"0",position:"absolute",width:"1px"}),e.body.appendChild(t),t)}function Jq(e,t){if(!(!e||!t)){var r=Zq(t);r.textContent=e,OK(t)}}var Qq=process.env.NODE_ENV!=="production"?"__autocomplete_unknown__":0,e5=process.env.NODE_ENV!=="production"?"__autocomplete_mouseup__":1,t5=process.env.NODE_ENV!=="production"?"__autocomplete_item_mouseenter__":2,Nu=process.env.NODE_ENV!=="production"?"__autocomplete_keydown_arrow_up__":3,Iu=process.env.NODE_ENV!=="production"?"__autocomplete_keydown_arrow_down__":4,r5=process.env.NODE_ENV!=="production"?"__autocomplete_keydown_escape__":5,n5=process.env.NODE_ENV!=="production"?"__autocomplete_keydown_enter__":6,o5=process.env.NODE_ENV!=="production"?"__autocomplete_keydown_home__":7,i5=process.env.NODE_ENV!=="production"?"__autocomplete_keydown_end__":8,a5=process.env.NODE_ENV!=="production"?"__autocomplete_click_item__":9,s5=process.env.NODE_ENV!=="production"?"__autocomplete_blur_input__":10,l5=process.env.NODE_ENV!=="production"?"__autocomplete_change_input__":11,c5=process.env.NODE_ENV!=="production"?"__autocomplete_keydown_space_button__":12,d_=process.env.NODE_ENV!=="production"?"__autocomplete_click_button__":13,u5=process.env.NODE_ENV!=="production"?"__autocomplete_blur_button__":14,d5=process.env.NODE_ENV!=="production"?"__autocomplete_controlled_prop_updated_selected_item__":15,f5=process.env.NODE_ENV!=="production"?"__autocomplete_touchend__":16,CK=Object.freeze({__proto__:null,blurButton:u5,blurInput:s5,changeInput:l5,clickButton:d_,clickItem:a5,controlledPropUpdatedSelectedItem:d5,itemMouseEnter:t5,keyDownArrowDown:Iu,keyDownArrowUp:Nu,keyDownEnd:i5,keyDownEnter:n5,keyDownEscape:r5,keyDownHome:o5,keyDownSpaceButton:c5,mouseUp:e5,touchEnd:f5,unknown:Qq}),RK=["refKey","ref"],NK=["onClick","onPress","onKeyDown","onKeyUp","onBlur"],IK=["onKeyDown","onBlur","onChange","onInput","onChangeText"],PK=["refKey","ref"],TK=["onMouseMove","onMouseDown","onClick","onPress","index","item"],AK=(function(){var e=(function(t){function r(o){var i;i=t.call(this,o)||this,i.id=i.props.id||"downshift-"+yK(),i.menuId=i.props.menuId||i.id+"-menu",i.labelId=i.props.labelId||i.id+"-label",i.inputId=i.props.inputId||i.id+"-input",i.getItemId=i.props.getItemId||function(w){return i.id+"-item-"+w},i.items=[],i.itemCount=null,i.previousResultCount=0,i.timeoutIds=[],i.internalSetTimeout=function(w,E){var S=setTimeout(function(){i.timeoutIds=i.timeoutIds.filter(function(_){return _!==S}),w()},E);i.timeoutIds.push(S)},i.setItemCount=function(w){i.itemCount=w},i.unsetItemCount=function(){i.itemCount=null},i.isItemDisabled=function(w,E){var S=i.getItemNodeFromIndex(E);return S&&S.hasAttribute("disabled")},i.setHighlightedIndex=function(w,E){w===void 0&&(w=i.props.defaultHighlightedIndex),E===void 0&&(E={}),E=Jc(E),i.internalSetState(jt({highlightedIndex:w},E))},i.clearSelection=function(w){i.internalSetState({selectedItem:null,inputValue:"",highlightedIndex:i.props.defaultHighlightedIndex,isOpen:i.props.defaultIsOpen},w)},i.selectItem=function(w,E,S){E=Jc(E),i.internalSetState(jt({isOpen:i.props.defaultIsOpen,highlightedIndex:i.props.defaultHighlightedIndex,selectedItem:w,inputValue:i.props.itemToString(w)},E),S)},i.selectItemAtIndex=function(w,E,S){var _=i.items[w];_!=null&&i.selectItem(_,E,S)},i.selectHighlightedItem=function(w,E){return i.selectItemAtIndex(i.getState().highlightedIndex,w,E)},i.internalSetState=function(w,E){var S,_,C={},N=typeof w=="function";return!N&&w.hasOwnProperty("inputValue")&&i.props.onInputValueChange(w.inputValue,jt({},i.getStateAndHelpers(),w)),i.setState(function(P){var A;P=i.getState(P);var j=N?w(P):w;j=i.props.stateReducer(P,j),S=j.hasOwnProperty("selectedItem");var M={};return S&&j.selectedItem!==P.selectedItem&&(_=j.selectedItem),(A=j).type||(A.type=Qq),Object.keys(j).forEach(function(L){P[L]!==j[L]&&(C[L]=j[L]),L!=="type"&&(j[L],u_(i.props,L)||(M[L]=j[L]))}),N&&j.hasOwnProperty("inputValue")&&i.props.onInputValueChange(j.inputValue,jt({},i.getStateAndHelpers(),j)),M},function(){QC(E)();var P=Object.keys(C).length>1;P&&i.props.onStateChange(C,i.getStateAndHelpers()),S&&i.props.onSelect(w.selectedItem,i.getStateAndHelpers()),_!==void 0&&i.props.onChange(_,i.getStateAndHelpers()),i.props.onUserAction(C,i.getStateAndHelpers())})},i.rootRef=function(w){return i._rootNode=w},i.getRootProps=function(w,E){var S,_=w===void 0?{}:w,C=_.refKey,N=C===void 0?"ref":C,P=_.ref,A=ms(_,RK),j=E===void 0?{}:E,M=j.suppressRefError,L=M===void 0?!1:M;i.getRootProps.called=!0,i.getRootProps.refKey=N,i.getRootProps.suppressRefError=L;var D=i.getState(),T=D.isOpen;return jt((S={},S[N]=tR(P,i.rootRef),S.role="combobox",S["aria-expanded"]=T,S["aria-haspopup"]="listbox",S["aria-owns"]=T?i.menuId:void 0,S["aria-labelledby"]=i.labelId,S),A)},i.keyDownHandlers={ArrowDown:function(w){var E=this;if(w.preventDefault(),this.getState().isOpen){var S=w.shiftKey?5:1;this.moveHighlightedIndex(S,{type:Iu})}else this.internalSetState({isOpen:!0,type:Iu},function(){var _=E.getItemCount();if(_>0){var C=E.getState(),N=C.highlightedIndex,P=Oh(N,1,{length:_},E.isItemDisabled,!0);E.setHighlightedIndex(P,{type:Iu})}})},ArrowUp:function(w){var E=this;if(w.preventDefault(),this.getState().isOpen){var S=w.shiftKey?-5:-1;this.moveHighlightedIndex(S,{type:Nu})}else this.internalSetState({isOpen:!0,type:Nu},function(){var _=E.getItemCount();if(_>0){var C=E.getState(),N=C.highlightedIndex,P=Oh(N,-1,{length:_},E.isItemDisabled,!0);E.setHighlightedIndex(P,{type:Nu})}})},Enter:function(w){if(w.which!==229){var E=this.getState(),S=E.isOpen,_=E.highlightedIndex;if(S&&_!=null){w.preventDefault();var C=this.items[_],N=this.getItemNodeFromIndex(_);if(C==null||N&&N.hasAttribute("disabled"))return;this.selectHighlightedItem({type:n5})}}},Escape:function(w){w.preventDefault(),this.reset(jt({type:r5},!this.state.isOpen&&{selectedItem:null,inputValue:""}))}},i.buttonKeyDownHandlers=jt({},i.keyDownHandlers,{" ":function(w){w.preventDefault(),this.toggleMenu({type:c5})}}),i.inputKeyDownHandlers=jt({},i.keyDownHandlers,{Home:function(w){var E=this.getState(),S=E.isOpen;if(S){w.preventDefault();var _=this.getItemCount();if(!(_<=0||!S)){var C=ed(0,!1,{length:_},this.isItemDisabled);this.setHighlightedIndex(C,{type:o5})}}},End:function(w){var E=this.getState(),S=E.isOpen;if(S){w.preventDefault();var _=this.getItemCount();if(!(_<=0||!S)){var C=ed(_-1,!0,{length:_},this.isItemDisabled);this.setHighlightedIndex(C,{type:i5})}}}}),i.getToggleButtonProps=function(w){var E=w===void 0?{}:w,S=E.onClick;E.onPress;var _=E.onKeyDown,C=E.onKeyUp,N=E.onBlur,P=ms(E,NK),A=i.getState(),j=A.isOpen,M={onClick:Fn(S,i.buttonHandleClick),onKeyDown:Fn(_,i.buttonHandleKeyDown),onKeyUp:Fn(C,i.buttonHandleKeyUp),onBlur:Fn(N,i.buttonHandleBlur)},L=P.disabled?{}:M;return jt({type:"button",role:"button","aria-label":j?"close menu":"open menu","aria-haspopup":!0,"data-toggle":!0},L,P)},i.buttonHandleKeyUp=function(w){w.preventDefault()},i.buttonHandleKeyDown=function(w){var E=nR(w);i.buttonKeyDownHandlers[E]&&i.buttonKeyDownHandlers[E].call(i,w)},i.buttonHandleClick=function(w){if(w.preventDefault(),i.props.environment){var E=i.props.environment.document,S=E.body,_=E.activeElement;S&&S===_&&w.target.focus()}process.env.NODE_ENV==="test"?i.toggleMenu({type:d_}):i.internalSetTimeout(function(){return i.toggleMenu({type:d_})})},i.buttonHandleBlur=function(w){var E=w.target;i.internalSetTimeout(function(){if(!(i.isMouseDown||!i.props.environment)){var S=i.props.environment.document.activeElement;(S==null||S.id!==i.inputId)&&S!==E&&i.reset({type:u5})}})},i.getLabelProps=function(w){return jt({htmlFor:i.inputId,id:i.labelId},w)},i.getInputProps=function(w){var E=w===void 0?{}:w,S=E.onKeyDown,_=E.onBlur,C=E.onChange,N=E.onInput;E.onChangeText;var P=ms(E,IK),A,j={};A="onChange";var M=i.getState(),L=M.inputValue,D=M.isOpen,T=M.highlightedIndex;if(!P.disabled){var W;j=(W={},W[A]=Fn(C,N,i.inputHandleChange),W.onKeyDown=Fn(S,i.inputHandleKeyDown),W.onBlur=Fn(_,i.inputHandleBlur),W)}return jt({"aria-autocomplete":"list","aria-activedescendant":D&&typeof T=="number"&&T>=0?i.getItemId(T):void 0,"aria-controls":D?i.menuId:void 0,"aria-labelledby":P&&P["aria-label"]?void 0:i.labelId,autoComplete:"off",value:L,id:i.inputId},j,P)},i.inputHandleKeyDown=function(w){var E=nR(w);E&&i.inputKeyDownHandlers[E]&&i.inputKeyDownHandlers[E].call(i,w)},i.inputHandleChange=function(w){i.internalSetState({type:l5,isOpen:!0,inputValue:w.target.value,highlightedIndex:i.props.defaultHighlightedIndex})},i.inputHandleBlur=function(){i.internalSetTimeout(function(){var w;if(!(i.isMouseDown||!i.props.environment)){var E=i.props.environment.document.activeElement,S=(E==null||(w=E.dataset)==null?void 0:w.toggle)&&i._rootNode&&i._rootNode.contains(E);S||i.reset({type:s5})}})},i.menuRef=function(w){i._menuNode=w},i.getMenuProps=function(w,E){var S,_=w===void 0?{}:w,C=_.refKey,N=C===void 0?"ref":C,P=_.ref,A=ms(_,PK),j=E===void 0?{}:E,M=j.suppressRefError,L=M===void 0?!1:M;return i.getMenuProps.called=!0,i.getMenuProps.refKey=N,i.getMenuProps.suppressRefError=L,jt((S={},S[N]=tR(P,i.menuRef),S.role="listbox",S["aria-labelledby"]=A&&A["aria-label"]?void 0:i.labelId,S.id=i.menuId,S),A)},i.getItemProps=function(w){var E,S=w===void 0?{}:w,_=S.onMouseMove,C=S.onMouseDown,N=S.onClick;S.onPress;var P=S.index,A=S.item,j=A===void 0?process.env.NODE_ENV==="production"?void 0:wK("getItemProps","item"):A,M=ms(S,TK);P===void 0?(i.items.push(j),P=i.items.indexOf(j)):i.items[P]=j;var L="onClick",D=N,T=(E={onMouseMove:Fn(_,function(){P!==i.getState().highlightedIndex&&(i.setHighlightedIndex(P,{type:t5}),i.avoidScrolling=!0,i.internalSetTimeout(function(){return i.avoidScrolling=!1},250))}),onMouseDown:Fn(C,function(q){q.preventDefault()})},E[L]=Fn(D,function(){i.selectItemAtIndex(P,{type:a5})}),E),W=M.disabled?{onMouseDown:T.onMouseDown}:T;return jt({id:i.getItemId(P),role:"option","aria-selected":i.getState().highlightedIndex===P},W,M)},i.clearItems=function(){i.items=[]},i.reset=function(w,E){w===void 0&&(w={}),w=Jc(w),i.internalSetState(function(S){var _=S.selectedItem;return jt({isOpen:i.props.defaultIsOpen,highlightedIndex:i.props.defaultHighlightedIndex,inputValue:i.props.itemToString(_)},w)},E)},i.toggleMenu=function(w,E){w===void 0&&(w={}),w=Jc(w),i.internalSetState(function(S){var _=S.isOpen;return jt({isOpen:!_},_&&{highlightedIndex:i.props.defaultHighlightedIndex},w)},function(){var S=i.getState(),_=S.isOpen,C=S.highlightedIndex;_&&i.getItemCount()>0&&typeof C=="number"&&i.setHighlightedIndex(C,w),QC(E)()})},i.openMenu=function(w){i.internalSetState({isOpen:!0},w)},i.closeMenu=function(w){i.internalSetState({isOpen:!1},w)},i.updateStatus=c1(function(){var w;if((w=i.props)!=null&&(w=w.environment)!=null&&w.document){var E=i.getState(),S=i.items[E.highlightedIndex],_=i.getItemCount(),C=i.props.getA11yStatusMessage(jt({itemToString:i.props.itemToString,previousResultCount:i.previousResultCount,resultCount:_,highlightedItem:S},E));i.previousResultCount=_,Jq(C,i.props.environment.document)}},200);var a=i.props,s=a.defaultHighlightedIndex,c=a.initialHighlightedIndex,u=c===void 0?s:c,d=a.defaultIsOpen,f=a.initialIsOpen,h=f===void 0?d:f,v=a.initialInputValue,b=v===void 0?"":v,g=a.initialSelectedItem,m=g===void 0?null:g,x=i.getState({highlightedIndex:u,isOpen:h,inputValue:b,selectedItem:m});return x.selectedItem!=null&&i.props.initialInputValue===void 0&&(x.inputValue=i.props.itemToString(x.selectedItem)),i.state=x,i}oK(r,t);var n=r.prototype;return n.internalClearTimeouts=function(){this.timeoutIds.forEach(function(o){clearTimeout(o)}),this.timeoutIds=[]},n.getState=function(o){return o===void 0&&(o=this.state),EK(o,this.props)},n.getItemCount=function(){var o=this.items.length;return this.itemCount!=null?o=this.itemCount:this.props.itemCount!==void 0&&(o=this.props.itemCount),o},n.getItemNodeFromIndex=function(o){return this.props.environment?this.props.environment.document.getElementById(this.getItemId(o)):null},n.scrollHighlightedItemIntoView=function(){{var o=this.getItemNodeFromIndex(this.getState().highlightedIndex);this.props.scrollIntoView(o,this._menuNode)}},n.moveHighlightedIndex=function(o,i){var a=this.getItemCount(),s=this.getState(),c=s.highlightedIndex;if(a>0){var u=Oh(c,o,{length:a},this.isItemDisabled,!0);this.setHighlightedIndex(u,i)}},n.getStateAndHelpers=function(){var o=this.getState(),i=o.highlightedIndex,a=o.inputValue,s=o.selectedItem,c=o.isOpen,u=this.props.itemToString,d=this.id,f=this.getRootProps,h=this.getToggleButtonProps,v=this.getLabelProps,b=this.getMenuProps,g=this.getInputProps,m=this.getItemProps,x=this.openMenu,w=this.closeMenu,E=this.toggleMenu,S=this.selectItem,_=this.selectItemAtIndex,C=this.selectHighlightedItem,N=this.setHighlightedIndex,P=this.clearSelection,A=this.clearItems,j=this.reset,M=this.setItemCount,L=this.unsetItemCount,D=this.internalSetState;return{getRootProps:f,getToggleButtonProps:h,getLabelProps:v,getMenuProps:b,getInputProps:g,getItemProps:m,reset:j,openMenu:x,closeMenu:w,toggleMenu:E,selectItem:S,selectItemAtIndex:_,selectHighlightedItem:C,setHighlightedIndex:N,clearSelection:P,clearItems:A,setItemCount:M,unsetItemCount:L,setState:D,itemToString:u,id:d,highlightedIndex:i,inputValue:a,isOpen:c,selectedItem:s}},n.componentDidMount=function(){var o=this;if(process.env.NODE_ENV!=="production"&&this.getMenuProps.called&&!this.getMenuProps.suppressRefError&&iR(this._menuNode,this.getMenuProps),!this.props.environment)this.cleanup=function(){o.internalClearTimeouts()};else{var i=function(){o.isMouseDown=!0},a=function(f){o.isMouseDown=!1;var h=oR(f.target,[o._rootNode,o._menuNode],o.props.environment);!h&&o.getState().isOpen&&o.reset({type:e5},function(){return o.props.onOuterClick(o.getStateAndHelpers())})},s=function(){o.isTouchMove=!1},c=function(){o.isTouchMove=!0},u=function(f){var h=oR(f.target,[o._rootNode,o._menuNode],o.props.environment,!1);!o.isTouchMove&&!h&&o.getState().isOpen&&o.reset({type:f5},function(){return o.props.onOuterClick(o.getStateAndHelpers())})},d=this.props.environment;d.addEventListener("mousedown",i),d.addEventListener("mouseup",a),d.addEventListener("touchstart",s),d.addEventListener("touchmove",c),d.addEventListener("touchend",u),this.cleanup=function(){o.internalClearTimeouts(),o.updateStatus.cancel(),d.removeEventListener("mousedown",i),d.removeEventListener("mouseup",a),d.removeEventListener("touchstart",s),d.removeEventListener("touchmove",c),d.removeEventListener("touchend",u)}}},n.shouldScroll=function(o,i){var a=this.props.highlightedIndex===void 0?this.getState():this.props,s=a.highlightedIndex,c=i.highlightedIndex===void 0?o:i,u=c.highlightedIndex,d=s&&this.getState().isOpen&&!o.isOpen,f=s!==u;return d||f},n.componentDidUpdate=function(o,i){process.env.NODE_ENV!=="production"&&(u1(this.state,o,this.props),this.getMenuProps.called&&!this.getMenuProps.suppressRefError&&iR(this._menuNode,this.getMenuProps)),u_(this.props,"selectedItem")&&this.props.selectedItemChanged(o.selectedItem,this.props.selectedItem)&&this.internalSetState({type:d5,inputValue:this.props.itemToString(this.props.selectedItem)}),!this.avoidScrolling&&this.shouldScroll(i,o)&&this.scrollHighlightedItemIntoView(),this.updateStatus()},n.componentWillUnmount=function(){this.cleanup()},n.render=function(){var o=rR(this.props.children,go);this.clearItems(),this.getRootProps.called=!1,this.getRootProps.refKey=void 0,this.getRootProps.suppressRefError=void 0,this.getMenuProps.called=!1,this.getMenuProps.refKey=void 0,this.getMenuProps.suppressRefError=void 0,this.getLabelProps.called=!1,this.getInputProps.called=!1;var i=rR(o(this.getStateAndHelpers()));if(!i)return null;if(this.getRootProps.called||this.props.suppressRefError)return process.env.NODE_ENV!=="production"&&!this.getRootProps.suppressRefError&&!this.props.suppressRefError&&kK(i,this.getRootProps),i;if(Kq(i))return R.cloneElement(i,this.getRootProps(Xq(i)));if(process.env.NODE_ENV!=="production")throw new Error("downshift: If you return a non-DOM element, you must apply the getRootProps function")},r})(R.Component);return e.defaultProps={defaultHighlightedIndex:null,defaultIsOpen:!1,getA11yStatusMessage:xK,itemToString:function(t){return t==null?"":(process.env.NODE_ENV!=="production"&&SK(t)&&!t.hasOwnProperty("toString")&&console.warn("downshift: An object was passed to the default implementation of `itemToString`. You should probably provide your own `itemToString` implementation. Please refer to the `itemToString` API documentation.","The object that was passed:",t),String(t))},onStateChange:go,onInputValueChange:go,onUserAction:go,onChange:go,onSelect:go,onOuterClick:go,selectedItemChanged:function(t,r){return t!==r},environment:typeof window>"u"?void 0:window,stateReducer:function(t,r){return r},suppressRefError:!1,scrollIntoView:Yq},e.stateChangeTypes=CK,e})();process.env.NODE_ENV!=="production"&&(AK.propTypes={children:we.func,defaultHighlightedIndex:we.number,defaultIsOpen:we.bool,initialHighlightedIndex:we.number,initialSelectedItem:we.any,initialInputValue:we.string,initialIsOpen:we.bool,getA11yStatusMessage:we.func,itemToString:we.func,onChange:we.func,onSelect:we.func,onStateChange:we.func,onInputValueChange:we.func,onUserAction:we.func,onOuterClick:we.func,selectedItemChanged:we.func,stateReducer:we.func,itemCount:we.number,id:we.string,environment:we.shape({addEventListener:we.func.isRequired,removeEventListener:we.func.isRequired,document:we.shape({createElement:we.func.isRequired,getElementById:we.func.isRequired,activeElement:we.any.isRequired,body:we.any.isRequired}).isRequired,Node:we.func.isRequired}),suppressRefError:we.bool,scrollIntoView:we.func,selectedItem:we.any,isOpen:we.bool,inputValue:we.string,highlightedIndex:we.number,labelId:we.string,inputId:we.string,menuId:we.string,getItemId:we.func});function iR(e,t){var r=t.refKey;e||console.error('downshift: The ref prop "'+r+'" from getMenuProps was not applied correctly on your menu element.')}function kK(e,t){var r=t.refKey,n=r!=="ref",o=!Kq(e);o&&!n&&!XC.isForwardRef(e)?console.error("downshift: You returned a non-DOM element. You must specify a refKey in getRootProps"):!o&&n&&console.error('downshift: You returned a DOM element. You should not specify a refKey in getRootProps. You specified "'+r+'"'),!XC.isForwardRef(e)&&!Xq(e)[r]&&console.error('downshift: You must apply the ref prop "'+r+'" from getRootProps onto your root element.')}function DK(e,t){return t.changes}c1(function(e,t){Jq(e,t)},200);var Xs={itemToString:function(e){return e?String(e):""},itemToKey:function(e){return e},stateReducer:DK,scrollIntoView:Yq,environment:typeof window>"u"?void 0:window};process.env.NODE_ENV;process.env.NODE_ENV;function MK(){var e=R.useRef(!0);return R.useEffect(function(){return e.current=!1,function(){e.current=!0}},[]),e.current}var Pu={environment:we.shape({addEventListener:we.func.isRequired,removeEventListener:we.func.isRequired,document:we.shape({createElement:we.func.isRequired,getElementById:we.func.isRequired,activeElement:we.any.isRequired,body:we.any.isRequired}).isRequired,Node:we.func.isRequired}),itemToString:we.func,itemToKey:we.func,stateReducer:we.func},p5=jt({},Pu,{getA11yStatusMessage:we.func,highlightedIndex:we.number,defaultHighlightedIndex:we.number,initialHighlightedIndex:we.number,isOpen:we.bool,defaultIsOpen:we.bool,initialIsOpen:we.bool,selectedItem:we.any,initialSelectedItem:we.any,defaultSelectedItem:we.any,id:we.string,labelId:we.string,menuId:we.string,getItemId:we.func,toggleButtonId:we.string,onSelectedItemChange:we.func,onHighlightedIndexChange:we.func,onStateChange:we.func,onIsOpenChange:we.func,scrollIntoView:we.func}),jK=_a(_a({},p5),{items:we.array.isRequired,isItemDisabled:we.func});_a(_a({},Xs),{isItemDisabled:function(){return!1}});process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;var LK=jt({},p5,{items:we.array.isRequired,isItemDisabled:we.func,inputValue:we.string,defaultInputValue:we.string,initialInputValue:we.string,inputId:we.string,onInputValueChange:we.func});process.env.NODE_ENV;jt({},Xs,{isItemDisabled:function(){return!1}});var qK={stateReducer:Pu.stateReducer,itemToKey:Pu.itemToKey,environment:Pu.environment,selectedItems:we.array,initialSelectedItems:we.array,defaultSelectedItems:we.array,getA11yStatusMessage:we.func,activeIndex:we.number,initialActiveIndex:we.number,defaultActiveIndex:we.number,onActiveIndexChange:we.func,onSelectedItemsChange:we.func,keyNavigationNext:we.string,keyNavigationPrevious:we.string};Xs.itemToKey,Xs.stateReducer,Xs.environment;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;const h5=R.forwardRef(({className:e,children:t,isFocused:r,isDisabled:n,...o},i)=>{const{size:a,color:s,isDisabled:c,hasMessage:u,downshift:d,isInvalid:f}=wr(),h=n??c,v=r??d.isOpen;return O.jsx("div",{ref:i,className:xe(FY({size:a,color:s,isDisabled:h,isFocused:!!v,isInvalid:f&&!d.isOpen,hasMessage:u}),e),"aria-disabled":h,"aria-invalid":f,role:"combobox",tabIndex:h?-1:0,...o,children:t})}),v5=({className:e,children:t,isMulti:r})=>O.jsx("div",{className:xe($Y({isMulti:r}),e),children:t}),Tu=R.forwardRef(({isHidden:e,inputClassName:t,...r},n)=>{const{size:o,color:i}=wr();return e?O.jsx("input",{ref:n,type:"text",style:{position:"absolute",top:0,left:0,opacity:0,width:"100%",height:"100%",pointerEvents:"none"},tabIndex:-1,...r}):O.jsx("input",{ref:n,type:"text",className:xe(VY({size:o,color:i}),t),...r})}),g5=({className:e,children:t})=>{const{size:r,color:n}=wr();return O.jsx("div",{className:xe(HY({size:r,color:n}),e),children:t})},m5=({className:e,children:t,data:r,isDisabled:n})=>{const{size:o,color:i}=wr();return O.jsx("div",{className:xe(WY({size:o,color:i,isDisabled:n}),e),children:t||r.label})},b5=({className:e,children:t,data:r,isDisabled:n,isFocused:o,onRemove:i})=>{const{size:a,color:s,downshift:c}=wr(),u=()=>{i?i(r):c.removeItem(r)};return O.jsxs("div",{className:xe(UY({size:a,color:s,isDisabled:n,isFocused:o}),e),children:[O.jsx("div",{className:GY({size:a}),children:t||r.label}),!n&&O.jsx("div",{className:YY({size:a,color:s,isDisabled:!1}),onClick:u,children:O.jsx(Td,{className:"w-3 h-3"})})]})},y5=({color:e,className:t,children:r,onClick:n,isDisabled:o,...i})=>{const{size:a,color:s,isDisabled:c,downshift:u}=wr(),d=o??c,f=u.selectedItems.length>0;if(d||!f)return null;const h=v=>{v.stopPropagation(),n?n(v):u.clearSelection()};return O.jsx("div",{className:xe(Wq({size:a,color:e||s,isDisabled:d}),t),onClick:h,role:"button",tabIndex:0,"aria-label":"Clear selection",...i,children:r||O.jsx(x8,{})})},zK=({className:e,children:t,onClick:r,isDisabled:n,...o})=>{const{size:i,color:a,isDisabled:s,downshift:c}=wr(),u=n??s,d=c.inputValue.length>0&&c.isSearchable;if(u||!d)return null;const f=h=>{h.stopPropagation(),r?r(h):c.setInputValue("")};return O.jsx("div",{className:xe(Wq({size:i,color:a,isDisabled:u}),e),onClick:f,role:"button",tabIndex:0,"aria-label":"Clear selection",...o,children:t||O.jsx(Td,{})})},x5=({color:e,className:t,children:r,onClick:n,isDisabled:o,...i})=>{const{size:a,color:s,isDisabled:c,downshift:u}=wr(),d=o??c,f=u.isOpen,h=v=>{v.stopPropagation(),d||(n?n(v):u.toggleMenu())};return O.jsx("div",{className:xe(KY({size:a,color:e||s,isDisabled:d}),"cursor-pointer",t),onClick:h,role:"button",tabIndex:d?-1:0,"aria-label":f?"Close menu":"Open menu","aria-expanded":f,"aria-disabled":d,...i,children:r||O.jsx(w8,{className:xe("transition-transform duration-200",{"rotate-180":f})})})},w5=R.forwardRef(({className:e,children:t,placement:r,...n},o)=>{const{size:i,hasMessage:a,color:s}=wr();return O.jsx("div",{"data-qui":"SelectMenu",ref:o,className:xe(XY({size:i,placement:r,hasMessage:a,color:s}),e),...n,children:t})}),_5=R.forwardRef(({className:e,children:t,maxHeight:r=300,...n},o)=>{const{size:i}=wr();return O.jsx(Y_,{scrollableNodeProps:{ref:o},className:xe(ZY({size:i}),e),style:{maxHeight:r},...n,children:t})}),f_=({className:e,children:t,data:r,isDisabled:n,isFocused:o,isSelected:i,innerProps:a,...s})=>{const{size:c,color:u}=wr();return O.jsx("div",{"data-qui":"SelectOption",className:xe(JY({size:c,color:u,isDisabled:n,isFocused:o,isSelected:i}),e),...a,...s,children:t||r.label})},E5=({className:e,children:t,data:r,label:n})=>{const{size:o}=wr();return O.jsxs("div",{"data-qui":"SelectGroup",className:xe(QY({size:o}),e),children:[O.jsx(S5,{children:n||r.label}),t]})},S5=({className:e,children:t})=>{const{size:r,color:n}=wr();return O.jsx("div",{className:xe(eK({size:r,color:n}),e),children:t})},Au=({className:e,children:t,inputValue:r})=>{const{size:n}=wr();return O.jsx("div",{className:xe(rK({size:n}),e),children:t||`No options found${r?` for "${r}"`:""}`})},BK=({isOpen:e,usePortal:t,controlRef:r,children:n})=>{const[o,i]=R.useState(null);return R.useLayoutEffect(()=>{if(t&&e&&r.current){const a=()=>{var s;const c=(s=r.current)==null?void 0:s.getBoundingClientRect();c&&i({top:c.top+window.scrollY,left:c.left+window.scrollX,width:c.width,height:c.height})};return a(),window.addEventListener("resize",a),window.addEventListener("scroll",a,!0),()=>{window.removeEventListener("resize",a),window.removeEventListener("scroll",a,!0)}}},[e,t,r]),e?t&&o?mo.createPortal(O.jsx("div",{className:"absolute z-50",style:{top:o.top,left:o.left,width:o.width,height:o.height,pointerEvents:"none"},children:O.jsx("div",{className:"relative w-full h-full",children:O.jsx("div",{style:{pointerEvents:"auto"},children:n})})}),document.body):O.jsx(O.Fragment,{children:n}):null},FK=e=>t=>{e.forEach(r=>{typeof r=="function"?r(t):r!=null&&(r.current=t)})},$K=R.forwardRef(({placeholder:e,noOptionsMessage:t="",hideNoOptions:r=!1,loadingMessage:n="Loading...",isClearable:o=!1,isSearchClearable:i=!1,isLoading:a=!1,isRequired:s=!1,hideIndicators:c=!1,hideDropdownIndicator:u=!1,searchPlacement:d="trigger",hideSelectedOptions:f=!1,onFocus:h,onBlur:v,renderMenuHeader:b,formatOptionLabel:g,displayFormattedOption:m=!1,isOptionDisabled:x=T=>T.isDisabled||!1,inputRef:w,controlShouldRenderValue:E=!0,name:S,id:_,onSelectionComplete:C,"aria-label":N,"aria-labelledby":P,"aria-describedby":A,children:j,usePortal:M=!1,...L},D)=>{const{size:T,isInvalid:W,isDisabled:q,downshift:G,options:F=[]}=wr(),J=R.useRef(null),z=w||J,U=R.useRef(null),{isOpen:oe,openMenu:re,selectedItem:$,inputValue:Y,highlightedIndex:X,getToggleButtonProps:H,getMenuProps:K,getInputProps:Q,getItemProps:ne,isMulti:se,isSearchable:te}=G,be=se?G.selectedItems??[]:$?[$]:[],de=be.length>0,Ee=i&&!q&&!c,fe=o&&de&&!q&&!c,le=!u&&!c,Ce=!de&&(!te||!Y)||!E,Te={},Fe={};Object.entries(L).forEach(([Ne,je])=>{Ne.startsWith("data-")||Ne.startsWith("aria-")||Ne==="role"?Te[Ne]=je:Fe[Ne]=je});const Le=R.useMemo(()=>FK([U,D]),[D]),Ze=H({disabled:q,ref:Le}),We=(Q==null?void 0:Q({disabled:q,required:s,name:S,id:_,"aria-label":N,"aria-labelledby":P,"aria-describedby":A,"aria-invalid":W,onFocus:h,onBlur:v,...Fe}))??{},St=Ne=>be.some(je=>je.value===Ne.value),tt=Ne=>f?Ne.filter(je=>!St(je)):Ne,wt=Ne=>f?Ne.map(je=>({...je,options:tt(je.options)})).filter(je=>je.options.length>0):Ne,Je=Ne=>{C==null||C(Ne.value,Ne)};return O.jsxs("div",{className:"relative",children:[O.jsxs(h5,{...te?{ref:Le}:Ze,...Te,isFocused:oe,isDisabled:q,onClick:Ne=>{Ne.stopPropagation(),re()},children:[j||O.jsxs(v5,{isMulti:se,children:[se&&E&&be.map((Ne,je)=>O.jsx(b5,{data:Ne,index:je,isDisabled:q},Ne.value)),!se&&de&&E&&O.jsx("div",{className:"flex items-center gap-2",children:O.jsx(m5,{data:be[0],isDisabled:q,children:g&&m?g(be[0]):be[0].label})}),te&&d==="trigger"?O.jsx(Tu,{ref:z,...We,placeholder:e}):O.jsxs(O.Fragment,{children:[O.jsx(Tu,{ref:z,isHidden:!0,value:be.map(Ne=>Ne.value).join(","),...We}),Ce&&O.jsx(g5,{children:e})]})]}),O.jsxs("div",{className:xe("flex items-center size-fit gap-1",{hidden:!fe&&!le}),children:[Ee&&O.jsx(zK,{}),fe&&O.jsx(y5,{}),le&&O.jsx(x5,{})]})]}),O.jsx(BK,{isOpen:oe,usePortal:M,controlRef:U,children:r&&G.filteredItems.length===0?null:O.jsxs(w5,{...K(),children:[b&&b(G),te&&d==="menu"&&O.jsx("div",{className:"p-2",children:O.jsx(Tu,{ref:z,...We,autoFocus:!0,placeholder:e,onClick:Ne=>Ne.stopPropagation()})}),O.jsx(_5,{children:a?O.jsx("div",{className:tK({size:T}),children:n}):G.filteredItems.length===0?O.jsx(Au,{inputValue:Y,children:typeof t=="function"?t(Y):t}):nK(F)?(()=>{const Ne=wt(F);return Ne.length===0?O.jsx(Au,{inputValue:Y,children:typeof t=="function"?t(Y):t}):Ne.map(je=>O.jsx(E5,{data:je,label:je.label,options:je.options,children:je.options.map(Qe=>{const At=Qe.value,It=be.some(pr=>pr.value===At),mt=G.filteredItems.findIndex(pr=>pr.value===At),Rt=X===mt,Qt=x(Qe),fr=ne({item:Qe,index:mt,onClick:()=>Je(Qe)});return O.jsx(f_,{...fr,data:Qe,isDisabled:Qt,isFocused:Rt,isSelected:It,children:g?g(Qe):Qe.label},At)})},je.label))})():(()=>{const Ne=tt(G.filteredItems);return Ne.length===0?O.jsx(Au,{inputValue:Y,children:typeof t=="function"?t(Y):t}):Ne.map(je=>{const Qe=je.value,At=be.some(fr=>fr.value===Qe),It=G.filteredItems.findIndex(fr=>fr.value===Qe),mt=X===It,Rt=x(je),Qt=ne({item:je,index:It,onClick:()=>Je(je)});return O.jsx(f_,{...Qt,data:je,isDisabled:Rt,isFocused:mt,isSelected:At,children:g?g(je):je.label},Qe)})})()})]})})]})});h5.displayName="Select.Control";v5.displayName="Select.ValueContainer";Tu.displayName="Select.Input";g5.displayName="Select.Placeholder";m5.displayName="Select.SingleValue";b5.displayName="Select.MultiValue";y5.displayName="Select.ClearIndicator";x5.displayName="Select.DropdownIndicator";w5.displayName="Select.Menu";_5.displayName="Select.MenuList";f_.displayName="Select.Option";E5.displayName="Select.Group";S5.displayName="Select.GroupHeading";Au.displayName="Select.NoOptionsMessage";$K.displayName="Select.Field";R.createContext(void 0);const VK=({active:e,disabled:t,error:r,isOpen:n,className:o})=>xe("flex w-full items-center justify-between text-left leading-5 transition-colors duration-200",{"cursor-pointer":!t,"text-inactive-text":t,"bg-primary hover:bg-primary-hover text-tab-active-fg":e&&!t,"text-negative":r&&!e&&!t,"bg-primary":n&&!e&&!t,"text-tab-inactive-fg":!e&&!t&&!r,"hover:bg-primary-hover hover:text-tab-active-fg":!t&&!e},o),HK=R.forwardRef(({active:e,disabled:t,error:r,isOpen:n,className:o,children:i,as:a="div",...s},c)=>{const u=VK({active:e,disabled:t,error:r,isOpen:n,className:o});return O.jsx(a,{"data-qui":"ListItem",ref:c,className:u,"aria-disabled":t,"aria-selected":e,"aria-invalid":r,"aria-expanded":n,role:s.onClick?"button":"listitem",...s,children:i})});HK.displayName="ListItem";function WK({qodly:e,activeTab:t,forceLogin:r,onTabChange:n,restrictedByDefault:o,onRestrictedByDefaultChange:i,onForceLoginChange:a}){return O.jsx(O.Fragment,{children:O.jsx(fn,{depth:1,className:"relative mb-0 flex h-auto flex-wrap items-center justify-between border-b px-4 py-3",children:O.jsx("div",{className:"flex w-full flex-wrap items-center justify-between",children:O.jsxs("div",{className:"relative flex w-full justify-between",children:[O.jsxs(gh,{defaultValue:t,onTabChange:s=>n(s),children:[O.jsx(gh.Item,{label:"Roles",value:"roles","data-cy":"roles_btn_navbar"}),O.jsx(gh.Item,{label:"Privileges",value:"privileges","data-cy":"privileges_btn_navbar"})]}),O.jsxs("div",{className:"flex gap-2 justify-between",children:[O.jsxs("span",{className:"flex items-center gap-1 whitespace-nowrap",children:[O.jsx(Qu,{checked:o||!1,onChange:s=>{i(s)}}),O.jsx("span",{className:"px-1 text-xs text-white",children:"Restrict Access By Default"}),O.jsx(he.Tip,{tipKey:"editors:roles:toolbar:restrictedByDefault",alwaysOn:!0,side:"left"})]}),e===!1&&O.jsxs("span",{className:"flex items-center gap-1 whitespace-nowrap",children:[O.jsx(Qu,{checked:r||!1,onChange:s=>{a(s)}}),O.jsx("span",{className:"px-1 text-xs text-white",children:"Force login"}),O.jsx(he.Tip,{tipKey:"editors:roles:toolbar:forceLogin",alwaysOn:!0,side:"left"})]})]})]})})})})}const O5=R.createContext(void 0),UK=({children:e})=>{const[t,r]=R.useState(null);function n(i){r(i)}const o={selectedRole:t,selectRole:n};return O.jsx(O5.Provider,{value:o,children:e})};function d1(){const e=R.useContext(O5);if(e===void 0)throw new Error("useSelectedRole must be used within a SelectedRoleProvider");return e}var aR=function(t){return t.reduce(function(r,n){var o=n[0],i=n[1];return r[o]=i,r},{})},sR=typeof window<"u"&&window.document&&window.document.createElement?ue.useLayoutEffect:ue.useEffect,Tr="top",pn="bottom",hn="right",Ar="left",f1="auto",El=[Tr,pn,hn,Ar],Ea="start",al="end",GK="clippingParents",C5="viewport",bs="popper",YK="reference",lR=El.reduce(function(e,t){return e.concat([t+"-"+Ea,t+"-"+al])},[]),R5=[].concat(El,[f1]).reduce(function(e,t){return e.concat([t,t+"-"+Ea,t+"-"+al])},[]),KK="beforeRead",XK="read",ZK="afterRead",JK="beforeMain",QK="main",eX="afterMain",tX="beforeWrite",rX="write",nX="afterWrite",oX=[KK,XK,ZK,JK,QK,eX,tX,rX,nX];function Jn(e){return e?(e.nodeName||"").toLowerCase():null}function Gr(e){if(e==null)return window;if(e.toString()!=="[object Window]"){var t=e.ownerDocument;return t&&t.defaultView||window}return e}function _i(e){var t=Gr(e).Element;return e instanceof t||e instanceof Element}function dn(e){var t=Gr(e).HTMLElement;return e instanceof t||e instanceof HTMLElement}function p1(e){if(typeof ShadowRoot>"u")return!1;var t=Gr(e).ShadowRoot;return e instanceof t||e instanceof ShadowRoot}function iX(e){var t=e.state;Object.keys(t.elements).forEach(function(r){var n=t.styles[r]||{},o=t.attributes[r]||{},i=t.elements[r];!dn(i)||!Jn(i)||(Object.assign(i.style,n),Object.keys(o).forEach(function(a){var s=o[a];s===!1?i.removeAttribute(a):i.setAttribute(a,s===!0?"":s)}))})}function aX(e){var t=e.state,r={popper:{position:t.options.strategy,left:"0",top:"0",margin:"0"},arrow:{position:"absolute"},reference:{}};return Object.assign(t.elements.popper.style,r.popper),t.styles=r,t.elements.arrow&&Object.assign(t.elements.arrow.style,r.arrow),function(){Object.keys(t.elements).forEach(function(n){var o=t.elements[n],i=t.attributes[n]||{},a=Object.keys(t.styles.hasOwnProperty(n)?t.styles[n]:r[n]),s=a.reduce(function(c,u){return c[u]="",c},{});!dn(o)||!Jn(o)||(Object.assign(o.style,s),Object.keys(i).forEach(function(c){o.removeAttribute(c)}))})}}const sX={name:"applyStyles",enabled:!0,phase:"write",fn:iX,effect:aX,requires:["computeStyles"]};function Yn(e){return e.split("-")[0]}var gi=Math.max,td=Math.min,Sa=Math.round;function p_(){var e=navigator.userAgentData;return e!=null&&e.brands&&Array.isArray(e.brands)?e.brands.map(function(t){return t.brand+"/"+t.version}).join(" "):navigator.userAgent}function N5(){return!/^((?!chrome|android).)*safari/i.test(p_())}function Oa(e,t,r){t===void 0&&(t=!1),r===void 0&&(r=!1);var n=e.getBoundingClientRect(),o=1,i=1;t&&dn(e)&&(o=e.offsetWidth>0&&Sa(n.width)/e.offsetWidth||1,i=e.offsetHeight>0&&Sa(n.height)/e.offsetHeight||1);var a=_i(e)?Gr(e):window,s=a.visualViewport,c=!N5()&&r,u=(n.left+(c&&s?s.offsetLeft:0))/o,d=(n.top+(c&&s?s.offsetTop:0))/i,f=n.width/o,h=n.height/i;return{width:f,height:h,top:d,right:u+f,bottom:d+h,left:u,x:u,y:d}}function h1(e){var t=Oa(e),r=e.offsetWidth,n=e.offsetHeight;return Math.abs(t.width-r)<=1&&(r=t.width),Math.abs(t.height-n)<=1&&(n=t.height),{x:e.offsetLeft,y:e.offsetTop,width:r,height:n}}function I5(e,t){var r=t.getRootNode&&t.getRootNode();if(e.contains(t))return!0;if(r&&p1(r)){var n=t;do{if(n&&e.isSameNode(n))return!0;n=n.parentNode||n.host}while(n)}return!1}function yo(e){return Gr(e).getComputedStyle(e)}function lX(e){return["table","td","th"].indexOf(Jn(e))>=0}function Xo(e){return((_i(e)?e.ownerDocument:e.document)||window.document).documentElement}function zd(e){return Jn(e)==="html"?e:e.assignedSlot||e.parentNode||(p1(e)?e.host:null)||Xo(e)}function cR(e){return!dn(e)||yo(e).position==="fixed"?null:e.offsetParent}function cX(e){var t=/firefox/i.test(p_()),r=/Trident/i.test(p_());if(r&&dn(e)){var n=yo(e);if(n.position==="fixed")return null}var o=zd(e);for(p1(o)&&(o=o.host);dn(o)&&["html","body"].indexOf(Jn(o))<0;){var i=yo(o);if(i.transform!=="none"||i.perspective!=="none"||i.contain==="paint"||["transform","perspective"].indexOf(i.willChange)!==-1||t&&i.willChange==="filter"||t&&i.filter&&i.filter!=="none")return o;o=o.parentNode}return null}function Sl(e){for(var t=Gr(e),r=cR(e);r&&lX(r)&&yo(r).position==="static";)r=cR(r);return r&&(Jn(r)==="html"||Jn(r)==="body"&&yo(r).position==="static")?t:r||cX(e)||t}function v1(e){return["top","bottom"].indexOf(e)>=0?"x":"y"}function Zs(e,t,r){return gi(e,td(t,r))}function uX(e,t,r){var n=Zs(e,t,r);return n>r?r:n}function P5(){return{top:0,right:0,bottom:0,left:0}}function T5(e){return Object.assign({},P5(),e)}function A5(e,t){return t.reduce(function(r,n){return r[n]=e,r},{})}var dX=function(t,r){return t=typeof t=="function"?t(Object.assign({},r.rects,{placement:r.placement})):t,T5(typeof t!="number"?t:A5(t,El))};function fX(e){var t,r=e.state,n=e.name,o=e.options,i=r.elements.arrow,a=r.modifiersData.popperOffsets,s=Yn(r.placement),c=v1(s),u=[Ar,hn].indexOf(s)>=0,d=u?"height":"width";if(!(!i||!a)){var f=dX(o.padding,r),h=h1(i),v=c==="y"?Tr:Ar,b=c==="y"?pn:hn,g=r.rects.reference[d]+r.rects.reference[c]-a[c]-r.rects.popper[d],m=a[c]-r.rects.reference[c],x=Sl(i),w=x?c==="y"?x.clientHeight||0:x.clientWidth||0:0,E=g/2-m/2,S=f[v],_=w-h[d]-f[b],C=w/2-h[d]/2+E,N=Zs(S,C,_),P=c;r.modifiersData[n]=(t={},t[P]=N,t.centerOffset=N-C,t)}}function pX(e){var t=e.state,r=e.options,n=r.element,o=n===void 0?"[data-popper-arrow]":n;o!=null&&(typeof o=="string"&&(o=t.elements.popper.querySelector(o),!o)||I5(t.elements.popper,o)&&(t.elements.arrow=o))}const hX={name:"arrow",enabled:!0,phase:"main",fn:fX,effect:pX,requires:["popperOffsets"],requiresIfExists:["preventOverflow"]};function Ca(e){return e.split("-")[1]}var vX={top:"auto",right:"auto",bottom:"auto",left:"auto"};function gX(e,t){var r=e.x,n=e.y,o=t.devicePixelRatio||1;return{x:Sa(r*o)/o||0,y:Sa(n*o)/o||0}}function uR(e){var t,r=e.popper,n=e.popperRect,o=e.placement,i=e.variation,a=e.offsets,s=e.position,c=e.gpuAcceleration,u=e.adaptive,d=e.roundOffsets,f=e.isFixed,h=a.x,v=h===void 0?0:h,b=a.y,g=b===void 0?0:b,m=typeof d=="function"?d({x:v,y:g}):{x:v,y:g};v=m.x,g=m.y;var x=a.hasOwnProperty("x"),w=a.hasOwnProperty("y"),E=Ar,S=Tr,_=window;if(u){var C=Sl(r),N="clientHeight",P="clientWidth";if(C===Gr(r)&&(C=Xo(r),yo(C).position!=="static"&&s==="absolute"&&(N="scrollHeight",P="scrollWidth")),C=C,o===Tr||(o===Ar||o===hn)&&i===al){S=pn;var A=f&&C===_&&_.visualViewport?_.visualViewport.height:C[N];g-=A-n.height,g*=c?1:-1}if(o===Ar||(o===Tr||o===pn)&&i===al){E=hn;var j=f&&C===_&&_.visualViewport?_.visualViewport.width:C[P];v-=j-n.width,v*=c?1:-1}}var M=Object.assign({position:s},u&&vX),L=d===!0?gX({x:v,y:g},Gr(r)):{x:v,y:g};if(v=L.x,g=L.y,c){var D;return Object.assign({},M,(D={},D[S]=w?"0":"",D[E]=x?"0":"",D.transform=(_.devicePixelRatio||1)<=1?"translate("+v+"px, "+g+"px)":"translate3d("+v+"px, "+g+"px, 0)",D))}return Object.assign({},M,(t={},t[S]=w?g+"px":"",t[E]=x?v+"px":"",t.transform="",t))}function mX(e){var t=e.state,r=e.options,n=r.gpuAcceleration,o=n===void 0?!0:n,i=r.adaptive,a=i===void 0?!0:i,s=r.roundOffsets,c=s===void 0?!0:s,u={placement:Yn(t.placement),variation:Ca(t.placement),popper:t.elements.popper,popperRect:t.rects.popper,gpuAcceleration:o,isFixed:t.options.strategy==="fixed"};t.modifiersData.popperOffsets!=null&&(t.styles.popper=Object.assign({},t.styles.popper,uR(Object.assign({},u,{offsets:t.modifiersData.popperOffsets,position:t.options.strategy,adaptive:a,roundOffsets:c})))),t.modifiersData.arrow!=null&&(t.styles.arrow=Object.assign({},t.styles.arrow,uR(Object.assign({},u,{offsets:t.modifiersData.arrow,position:"absolute",adaptive:!1,roundOffsets:c})))),t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-placement":t.placement})}const bX={name:"computeStyles",enabled:!0,phase:"beforeWrite",fn:mX,data:{}};var Qc={passive:!0};function yX(e){var t=e.state,r=e.instance,n=e.options,o=n.scroll,i=o===void 0?!0:o,a=n.resize,s=a===void 0?!0:a,c=Gr(t.elements.popper),u=[].concat(t.scrollParents.reference,t.scrollParents.popper);return i&&u.forEach(function(d){d.addEventListener("scroll",r.update,Qc)}),s&&c.addEventListener("resize",r.update,Qc),function(){i&&u.forEach(function(d){d.removeEventListener("scroll",r.update,Qc)}),s&&c.removeEventListener("resize",r.update,Qc)}}const xX={name:"eventListeners",enabled:!0,phase:"write",fn:function(){},effect:yX,data:{}};var wX={left:"right",right:"left",bottom:"top",top:"bottom"};function ku(e){return e.replace(/left|right|bottom|top/g,function(t){return wX[t]})}var _X={start:"end",end:"start"};function dR(e){return e.replace(/start|end/g,function(t){return _X[t]})}function g1(e){var t=Gr(e),r=t.pageXOffset,n=t.pageYOffset;return{scrollLeft:r,scrollTop:n}}function m1(e){return Oa(Xo(e)).left+g1(e).scrollLeft}function EX(e,t){var r=Gr(e),n=Xo(e),o=r.visualViewport,i=n.clientWidth,a=n.clientHeight,s=0,c=0;if(o){i=o.width,a=o.height;var u=N5();(u||!u&&t==="fixed")&&(s=o.offsetLeft,c=o.offsetTop)}return{width:i,height:a,x:s+m1(e),y:c}}function SX(e){var t,r=Xo(e),n=g1(e),o=(t=e.ownerDocument)==null?void 0:t.body,i=gi(r.scrollWidth,r.clientWidth,o?o.scrollWidth:0,o?o.clientWidth:0),a=gi(r.scrollHeight,r.clientHeight,o?o.scrollHeight:0,o?o.clientHeight:0),s=-n.scrollLeft+m1(e),c=-n.scrollTop;return yo(o||r).direction==="rtl"&&(s+=gi(r.clientWidth,o?o.clientWidth:0)-i),{width:i,height:a,x:s,y:c}}function b1(e){var t=yo(e),r=t.overflow,n=t.overflowX,o=t.overflowY;return/auto|scroll|overlay|hidden/.test(r+o+n)}function k5(e){return["html","body","#document"].indexOf(Jn(e))>=0?e.ownerDocument.body:dn(e)&&b1(e)?e:k5(zd(e))}function Js(e,t){var r;t===void 0&&(t=[]);var n=k5(e),o=n===((r=e.ownerDocument)==null?void 0:r.body),i=Gr(n),a=o?[i].concat(i.visualViewport||[],b1(n)?n:[]):n,s=t.concat(a);return o?s:s.concat(Js(zd(a)))}function h_(e){return Object.assign({},e,{left:e.x,top:e.y,right:e.x+e.width,bottom:e.y+e.height})}function OX(e,t){var r=Oa(e,!1,t==="fixed");return r.top=r.top+e.clientTop,r.left=r.left+e.clientLeft,r.bottom=r.top+e.clientHeight,r.right=r.left+e.clientWidth,r.width=e.clientWidth,r.height=e.clientHeight,r.x=r.left,r.y=r.top,r}function fR(e,t,r){return t===C5?h_(EX(e,r)):_i(t)?OX(t,r):h_(SX(Xo(e)))}function CX(e){var t=Js(zd(e)),r=["absolute","fixed"].indexOf(yo(e).position)>=0,n=r&&dn(e)?Sl(e):e;return _i(n)?t.filter(function(o){return _i(o)&&I5(o,n)&&Jn(o)!=="body"}):[]}function RX(e,t,r,n){var o=t==="clippingParents"?CX(e):[].concat(t),i=[].concat(o,[r]),a=i[0],s=i.reduce(function(c,u){var d=fR(e,u,n);return c.top=gi(d.top,c.top),c.right=td(d.right,c.right),c.bottom=td(d.bottom,c.bottom),c.left=gi(d.left,c.left),c},fR(e,a,n));return s.width=s.right-s.left,s.height=s.bottom-s.top,s.x=s.left,s.y=s.top,s}function D5(e){var t=e.reference,r=e.element,n=e.placement,o=n?Yn(n):null,i=n?Ca(n):null,a=t.x+t.width/2-r.width/2,s=t.y+t.height/2-r.height/2,c;switch(o){case Tr:c={x:a,y:t.y-r.height};break;case pn:c={x:a,y:t.y+t.height};break;case hn:c={x:t.x+t.width,y:s};break;case Ar:c={x:t.x-r.width,y:s};break;default:c={x:t.x,y:t.y}}var u=o?v1(o):null;if(u!=null){var d=u==="y"?"height":"width";switch(i){case Ea:c[u]=c[u]-(t[d]/2-r[d]/2);break;case al:c[u]=c[u]+(t[d]/2-r[d]/2);break}}return c}function sl(e,t){t===void 0&&(t={});var r=t,n=r.placement,o=n===void 0?e.placement:n,i=r.strategy,a=i===void 0?e.strategy:i,s=r.boundary,c=s===void 0?GK:s,u=r.rootBoundary,d=u===void 0?C5:u,f=r.elementContext,h=f===void 0?bs:f,v=r.altBoundary,b=v===void 0?!1:v,g=r.padding,m=g===void 0?0:g,x=T5(typeof m!="number"?m:A5(m,El)),w=h===bs?YK:bs,E=e.rects.popper,S=e.elements[b?w:h],_=RX(_i(S)?S:S.contextElement||Xo(e.elements.popper),c,d,a),C=Oa(e.elements.reference),N=D5({reference:C,element:E,placement:o}),P=h_(Object.assign({},E,N)),A=h===bs?P:C,j={top:_.top-A.top+x.top,bottom:A.bottom-_.bottom+x.bottom,left:_.left-A.left+x.left,right:A.right-_.right+x.right},M=e.modifiersData.offset;if(h===bs&&M){var L=M[o];Object.keys(j).forEach(function(D){var T=[hn,pn].indexOf(D)>=0?1:-1,W=[Tr,pn].indexOf(D)>=0?"y":"x";j[D]+=L[W]*T})}return j}function NX(e,t){t===void 0&&(t={});var r=t,n=r.placement,o=r.boundary,i=r.rootBoundary,a=r.padding,s=r.flipVariations,c=r.allowedAutoPlacements,u=c===void 0?R5:c,d=Ca(n),f=d?s?lR:lR.filter(function(b){return Ca(b)===d}):El,h=f.filter(function(b){return u.indexOf(b)>=0});h.length===0&&(h=f);var v=h.reduce(function(b,g){return b[g]=sl(e,{placement:g,boundary:o,rootBoundary:i,padding:a})[Yn(g)],b},{});return Object.keys(v).sort(function(b,g){return v[b]-v[g]})}function IX(e){if(Yn(e)===f1)return[];var t=ku(e);return[dR(e),t,dR(t)]}function PX(e){var t=e.state,r=e.options,n=e.name;if(!t.modifiersData[n]._skip){for(var o=r.mainAxis,i=o===void 0?!0:o,a=r.altAxis,s=a===void 0?!0:a,c=r.fallbackPlacements,u=r.padding,d=r.boundary,f=r.rootBoundary,h=r.altBoundary,v=r.flipVariations,b=v===void 0?!0:v,g=r.allowedAutoPlacements,m=t.options.placement,x=Yn(m),w=x===m,E=c||(w||!b?[ku(m)]:IX(m)),S=[m].concat(E).reduce(function($,Y){return $.concat(Yn(Y)===f1?NX(t,{placement:Y,boundary:d,rootBoundary:f,padding:u,flipVariations:b,allowedAutoPlacements:g}):Y)},[]),_=t.rects.reference,C=t.rects.popper,N=new Map,P=!0,A=S[0],j=0;j<S.length;j++){var M=S[j],L=Yn(M),D=Ca(M)===Ea,T=[Tr,pn].indexOf(L)>=0,W=T?"width":"height",q=sl(t,{placement:M,boundary:d,rootBoundary:f,altBoundary:h,padding:u}),G=T?D?hn:Ar:D?pn:Tr;_[W]>C[W]&&(G=ku(G));var F=ku(G),J=[];if(i&&J.push(q[L]<=0),s&&J.push(q[G]<=0,q[F]<=0),J.every(function($){return $})){A=M,P=!1;break}N.set(M,J)}if(P)for(var z=b?3:1,U=function(Y){var X=S.find(function(H){var K=N.get(H);if(K)return K.slice(0,Y).every(function(Q){return Q})});if(X)return A=X,"break"},oe=z;oe>0;oe--){var re=U(oe);if(re==="break")break}t.placement!==A&&(t.modifiersData[n]._skip=!0,t.placement=A,t.reset=!0)}}const TX={name:"flip",enabled:!0,phase:"main",fn:PX,requiresIfExists:["offset"],data:{_skip:!1}};function pR(e,t,r){return r===void 0&&(r={x:0,y:0}),{top:e.top-t.height-r.y,right:e.right-t.width+r.x,bottom:e.bottom-t.height+r.y,left:e.left-t.width-r.x}}function hR(e){return[Tr,hn,pn,Ar].some(function(t){return e[t]>=0})}function AX(e){var t=e.state,r=e.name,n=t.rects.reference,o=t.rects.popper,i=t.modifiersData.preventOverflow,a=sl(t,{elementContext:"reference"}),s=sl(t,{altBoundary:!0}),c=pR(a,n),u=pR(s,o,i),d=hR(c),f=hR(u);t.modifiersData[r]={referenceClippingOffsets:c,popperEscapeOffsets:u,isReferenceHidden:d,hasPopperEscaped:f},t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-reference-hidden":d,"data-popper-escaped":f})}const kX={name:"hide",enabled:!0,phase:"main",requiresIfExists:["preventOverflow"],fn:AX};function DX(e,t,r){var n=Yn(e),o=[Ar,Tr].indexOf(n)>=0?-1:1,i=typeof r=="function"?r(Object.assign({},t,{placement:e})):r,a=i[0],s=i[1];return a=a||0,s=(s||0)*o,[Ar,hn].indexOf(n)>=0?{x:s,y:a}:{x:a,y:s}}function MX(e){var t=e.state,r=e.options,n=e.name,o=r.offset,i=o===void 0?[0,0]:o,a=R5.reduce(function(d,f){return d[f]=DX(f,t.rects,i),d},{}),s=a[t.placement],c=s.x,u=s.y;t.modifiersData.popperOffsets!=null&&(t.modifiersData.popperOffsets.x+=c,t.modifiersData.popperOffsets.y+=u),t.modifiersData[n]=a}const jX={name:"offset",enabled:!0,phase:"main",requires:["popperOffsets"],fn:MX};function LX(e){var t=e.state,r=e.name;t.modifiersData[r]=D5({reference:t.rects.reference,element:t.rects.popper,placement:t.placement})}const qX={name:"popperOffsets",enabled:!0,phase:"read",fn:LX,data:{}};function zX(e){return e==="x"?"y":"x"}function BX(e){var t=e.state,r=e.options,n=e.name,o=r.mainAxis,i=o===void 0?!0:o,a=r.altAxis,s=a===void 0?!1:a,c=r.boundary,u=r.rootBoundary,d=r.altBoundary,f=r.padding,h=r.tether,v=h===void 0?!0:h,b=r.tetherOffset,g=b===void 0?0:b,m=sl(t,{boundary:c,rootBoundary:u,padding:f,altBoundary:d}),x=Yn(t.placement),w=Ca(t.placement),E=!w,S=v1(x),_=zX(S),C=t.modifiersData.popperOffsets,N=t.rects.reference,P=t.rects.popper,A=typeof g=="function"?g(Object.assign({},t.rects,{placement:t.placement})):g,j=typeof A=="number"?{mainAxis:A,altAxis:A}:Object.assign({mainAxis:0,altAxis:0},A),M=t.modifiersData.offset?t.modifiersData.offset[t.placement]:null,L={x:0,y:0};if(C){if(i){var D,T=S==="y"?Tr:Ar,W=S==="y"?pn:hn,q=S==="y"?"height":"width",G=C[S],F=G+m[T],J=G-m[W],z=v?-P[q]/2:0,U=w===Ea?N[q]:P[q],oe=w===Ea?-P[q]:-N[q],re=t.elements.arrow,$=v&&re?h1(re):{width:0,height:0},Y=t.modifiersData["arrow#persistent"]?t.modifiersData["arrow#persistent"].padding:P5(),X=Y[T],H=Y[W],K=Zs(0,N[q],$[q]),Q=E?N[q]/2-z-K-X-j.mainAxis:U-K-X-j.mainAxis,ne=E?-N[q]/2+z+K+H+j.mainAxis:oe+K+H+j.mainAxis,se=t.elements.arrow&&Sl(t.elements.arrow),te=se?S==="y"?se.clientTop||0:se.clientLeft||0:0,be=(D=M==null?void 0:M[S])!=null?D:0,de=G+Q-be-te,Ee=G+ne-be,fe=Zs(v?td(F,de):F,G,v?gi(J,Ee):J);C[S]=fe,L[S]=fe-G}if(s){var le,Ce=S==="x"?Tr:Ar,Te=S==="x"?pn:hn,Fe=C[_],Le=_==="y"?"height":"width",Ze=Fe+m[Ce],We=Fe-m[Te],St=[Tr,Ar].indexOf(x)!==-1,tt=(le=M==null?void 0:M[_])!=null?le:0,wt=St?Ze:Fe-N[Le]-P[Le]-tt+j.altAxis,Je=St?Fe+N[Le]+P[Le]-tt-j.altAxis:We,Ne=v&&St?uX(wt,Fe,Je):Zs(v?wt:Ze,Fe,v?Je:We);C[_]=Ne,L[_]=Ne-Fe}t.modifiersData[n]=L}}const FX={name:"preventOverflow",enabled:!0,phase:"main",fn:BX,requiresIfExists:["offset"]};function $X(e){return{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}}function VX(e){return e===Gr(e)||!dn(e)?g1(e):$X(e)}function HX(e){var t=e.getBoundingClientRect(),r=Sa(t.width)/e.offsetWidth||1,n=Sa(t.height)/e.offsetHeight||1;return r!==1||n!==1}function WX(e,t,r){r===void 0&&(r=!1);var n=dn(t),o=dn(t)&&HX(t),i=Xo(t),a=Oa(e,o,r),s={scrollLeft:0,scrollTop:0},c={x:0,y:0};return(n||!n&&!r)&&((Jn(t)!=="body"||b1(i))&&(s=VX(t)),dn(t)?(c=Oa(t,!0),c.x+=t.clientLeft,c.y+=t.clientTop):i&&(c.x=m1(i))),{x:a.left+s.scrollLeft-c.x,y:a.top+s.scrollTop-c.y,width:a.width,height:a.height}}function UX(e){var t=new Map,r=new Set,n=[];e.forEach(function(i){t.set(i.name,i)});function o(i){r.add(i.name);var a=[].concat(i.requires||[],i.requiresIfExists||[]);a.forEach(function(s){if(!r.has(s)){var c=t.get(s);c&&o(c)}}),n.push(i)}return e.forEach(function(i){r.has(i.name)||o(i)}),n}function GX(e){var t=UX(e);return oX.reduce(function(r,n){return r.concat(t.filter(function(o){return o.phase===n}))},[])}function YX(e){var t;return function(){return t||(t=new Promise(function(r){Promise.resolve().then(function(){t=void 0,r(e())})})),t}}function KX(e){var t=e.reduce(function(r,n){var o=r[n.name];return r[n.name]=o?Object.assign({},o,n,{options:Object.assign({},o.options,n.options),data:Object.assign({},o.data,n.data)}):n,r},{});return Object.keys(t).map(function(r){return t[r]})}var vR={placement:"bottom",modifiers:[],strategy:"absolute"};function gR(){for(var e=arguments.length,t=new Array(e),r=0;r<e;r++)t[r]=arguments[r];return!t.some(function(n){return!(n&&typeof n.getBoundingClientRect=="function")})}function XX(e){e===void 0&&(e={});var t=e,r=t.defaultModifiers,n=r===void 0?[]:r,o=t.defaultOptions,i=o===void 0?vR:o;return function(s,c,u){u===void 0&&(u=i);var d={placement:"bottom",orderedModifiers:[],options:Object.assign({},vR,i),modifiersData:{},elements:{reference:s,popper:c},attributes:{},styles:{}},f=[],h=!1,v={state:d,setOptions:function(x){var w=typeof x=="function"?x(d.options):x;g(),d.options=Object.assign({},i,d.options,w),d.scrollParents={reference:_i(s)?Js(s):s.contextElement?Js(s.contextElement):[],popper:Js(c)};var E=GX(KX([].concat(n,d.options.modifiers)));return d.orderedModifiers=E.filter(function(S){return S.enabled}),b(),v.update()},forceUpdate:function(){if(!h){var x=d.elements,w=x.reference,E=x.popper;if(gR(w,E)){d.rects={reference:WX(w,Sl(E),d.options.strategy==="fixed"),popper:h1(E)},d.reset=!1,d.placement=d.options.placement,d.orderedModifiers.forEach(function(j){return d.modifiersData[j.name]=Object.assign({},j.data)});for(var S=0;S<d.orderedModifiers.length;S++){if(d.reset===!0){d.reset=!1,S=-1;continue}var _=d.orderedModifiers[S],C=_.fn,N=_.options,P=N===void 0?{}:N,A=_.name;typeof C=="function"&&(d=C({state:d,options:P,name:A,instance:v})||d)}}}},update:YX(function(){return new Promise(function(m){v.forceUpdate(),m(d)})}),destroy:function(){g(),h=!0}};if(!gR(s,c))return v;v.setOptions(u).then(function(m){!h&&u.onFirstUpdate&&u.onFirstUpdate(m)});function b(){d.orderedModifiers.forEach(function(m){var x=m.name,w=m.options,E=w===void 0?{}:w,S=m.effect;if(typeof S=="function"){var _=S({state:d,name:x,instance:v,options:E}),C=function(){};f.push(_||C)}})}function g(){f.forEach(function(m){return m()}),f=[]}return v}}var ZX=[xX,qX,bX,sX,jX,TX,FX,hX,kX],JX=XX({defaultModifiers:ZX}),Tt=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function Zo(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var Ch,mR;function QX(){if(mR)return Ch;mR=1;var e=typeof Element<"u",t=typeof Map=="function",r=typeof Set=="function",n=typeof ArrayBuffer=="function"&&!!ArrayBuffer.isView;function o(i,a){if(i===a)return!0;if(i&&a&&typeof i=="object"&&typeof a=="object"){if(i.constructor!==a.constructor)return!1;var s,c,u;if(Array.isArray(i)){if(s=i.length,s!=a.length)return!1;for(c=s;c--!==0;)if(!o(i[c],a[c]))return!1;return!0}var d;if(t&&i instanceof Map&&a instanceof Map){if(i.size!==a.size)return!1;for(d=i.entries();!(c=d.next()).done;)if(!a.has(c.value[0]))return!1;for(d=i.entries();!(c=d.next()).done;)if(!o(c.value[1],a.get(c.value[0])))return!1;return!0}if(r&&i instanceof Set&&a instanceof Set){if(i.size!==a.size)return!1;for(d=i.entries();!(c=d.next()).done;)if(!a.has(c.value[0]))return!1;return!0}if(n&&ArrayBuffer.isView(i)&&ArrayBuffer.isView(a)){if(s=i.length,s!=a.length)return!1;for(c=s;c--!==0;)if(i[c]!==a[c])return!1;return!0}if(i.constructor===RegExp)return i.source===a.source&&i.flags===a.flags;if(i.valueOf!==Object.prototype.valueOf&&typeof i.valueOf=="function"&&typeof a.valueOf=="function")return i.valueOf()===a.valueOf();if(i.toString!==Object.prototype.toString&&typeof i.toString=="function"&&typeof a.toString=="function")return i.toString()===a.toString();if(u=Object.keys(i),s=u.length,s!==Object.keys(a).length)return!1;for(c=s;c--!==0;)if(!Object.prototype.hasOwnProperty.call(a,u[c]))return!1;if(e&&i instanceof Element)return!1;for(c=s;c--!==0;)if(!((u[c]==="_owner"||u[c]==="__v"||u[c]==="__o")&&i.$$typeof)&&!o(i[u[c]],a[u[c]]))return!1;return!0}return i!==i&&a!==a}return Ch=function(a,s){try{return o(a,s)}catch(c){if((c.message||"").match(/stack|recursion/i))return console.warn("react-fast-compare cannot handle circular refs"),!1;throw c}},Ch}var eZ=QX();const tZ=Zo(eZ);var rZ=[],Bd=function(t,r,n){n===void 0&&(n={});var o=ue.useRef(null),i={onFirstUpdate:n.onFirstUpdate,placement:n.placement||"bottom",strategy:n.strategy||"absolute",modifiers:n.modifiers||rZ},a=ue.useState({styles:{popper:{position:i.strategy,left:"0",top:"0"},arrow:{position:"absolute"}},attributes:{}}),s=a[0],c=a[1],u=ue.useMemo(function(){return{name:"updateState",enabled:!0,phase:"write",fn:function(v){var b=v.state,g=Object.keys(b.elements);W_.flushSync(function(){c({styles:aR(g.map(function(m){return[m,b.styles[m]||{}]})),attributes:aR(g.map(function(m){return[m,b.attributes[m]]}))})})},requires:["computeStyles"]}},[]),d=ue.useMemo(function(){var h={onFirstUpdate:i.onFirstUpdate,placement:i.placement,strategy:i.strategy,modifiers:[].concat(i.modifiers,[u,{name:"applyStyles",enabled:!1}])};return tZ(o.current,h)?o.current||h:(o.current=h,h)},[i.onFirstUpdate,i.placement,i.strategy,i.modifiers,u]),f=ue.useRef();return sR(function(){f.current&&f.current.setOptions(d)},[d]),sR(function(){if(!(t==null||r==null)){var h=n.createPopper||JX,v=h(t,r,d);return f.current=v,function(){v.destroy(),f.current=null}}},[t,r,n.createPopper]),{state:f.current?f.current.state:null,styles:s.styles,attributes:s.attributes,update:f.current?f.current.update:null,forceUpdate:f.current?f.current.forceUpdate:null}};const M5=({tab:e})=>O.jsx(fn,{depth:1,className:"flex flex-1 items-center justify-center border-l-[0.5px]",children:O.jsxs("div",{className:"flex flex-col items-center justify-center space-y-4",children:[O.jsx(_e.FdInfoBold,{className:"h-10 w-10"}),O.jsxs("div",{className:"font-semibold",children:["No ",e," Selected"]}),O.jsxs("div",{className:"text-sm",children:["Click on a ",e," in the Sidebar to select it."]})]})});function y1(e){throw new Error('Could not dynamically require "'+e+'". Please configure the dynamicRequireTargets or/and ignoreDynamicRequires option of @rollup/plugin-commonjs appropriately for this require call to work.')}var Rh,bR;function nZ(){if(bR)return Rh;bR=1;function e(){this.__data__=[],this.size=0}return Rh=e,Rh}var Nh,yR;function qa(){if(yR)return Nh;yR=1;function e(t,r){return t===r||t!==t&&r!==r}return Nh=e,Nh}var Ih,xR;function Fd(){if(xR)return Ih;xR=1;var e=qa();function t(r,n){for(var o=r.length;o--;)if(e(r[o][0],n))return o;return-1}return Ih=t,Ih}var Ph,wR;function oZ(){if(wR)return Ph;wR=1;var e=Fd(),t=Array.prototype,r=t.splice;function n(o){var i=this.__data__,a=e(i,o);if(a<0)return!1;var s=i.length-1;return a==s?i.pop():r.call(i,a,1),--this.size,!0}return Ph=n,Ph}var Th,_R;function iZ(){if(_R)return Th;_R=1;var e=Fd();function t(r){var n=this.__data__,o=e(n,r);return o<0?void 0:n[o][1]}return Th=t,Th}var Ah,ER;function aZ(){if(ER)return Ah;ER=1;var e=Fd();function t(r){return e(this.__data__,r)>-1}return Ah=t,Ah}var kh,SR;function sZ(){if(SR)return kh;SR=1;var e=Fd();function t(r,n){var o=this.__data__,i=e(o,r);return i<0?(++this.size,o.push([r,n])):o[i][1]=n,this}return kh=t,kh}var Dh,OR;function $d(){if(OR)return Dh;OR=1;var e=nZ(),t=oZ(),r=iZ(),n=aZ(),o=sZ();function i(a){var s=-1,c=a==null?0:a.length;for(this.clear();++s<c;){var u=a[s];this.set(u[0],u[1])}}return i.prototype.clear=e,i.prototype.delete=t,i.prototype.get=r,i.prototype.has=n,i.prototype.set=o,Dh=i,Dh}var Mh,CR;function lZ(){if(CR)return Mh;CR=1;var e=$d();function t(){this.__data__=new e,this.size=0}return Mh=t,Mh}var jh,RR;function cZ(){if(RR)return jh;RR=1;function e(t){var r=this.__data__,n=r.delete(t);return this.size=r.size,n}return jh=e,jh}var Lh,NR;function uZ(){if(NR)return Lh;NR=1;function e(t){return this.__data__.get(t)}return Lh=e,Lh}var qh,IR;function dZ(){if(IR)return qh;IR=1;function e(t){return this.__data__.has(t)}return qh=e,qh}var zh,PR;function j5(){if(PR)return zh;PR=1;var e=typeof Tt=="object"&&Tt&&Tt.Object===Object&&Tt;return zh=e,zh}var Bh,TR;function Dn(){if(TR)return Bh;TR=1;var e=j5(),t=typeof self=="object"&&self&&self.Object===Object&&self,r=e||t||Function("return this")();return Bh=r,Bh}var Fh,AR;function za(){if(AR)return Fh;AR=1;var e=Dn(),t=e.Symbol;return Fh=t,Fh}var $h,kR;function fZ(){if(kR)return $h;kR=1;var e=za(),t=Object.prototype,r=t.hasOwnProperty,n=t.toString,o=e?e.toStringTag:void 0;function i(a){var s=r.call(a,o),c=a[o];try{a[o]=void 0;var u=!0}catch{}var d=n.call(a);return u&&(s?a[o]=c:delete a[o]),d}return $h=i,$h}var Vh,DR;function pZ(){if(DR)return Vh;DR=1;var e=Object.prototype,t=e.toString;function r(n){return t.call(n)}return Vh=r,Vh}var Hh,MR;function Ni(){if(MR)return Hh;MR=1;var e=za(),t=fZ(),r=pZ(),n="[object Null]",o="[object Undefined]",i=e?e.toStringTag:void 0;function a(s){return s==null?s===void 0?o:n:i&&i in Object(s)?t(s):r(s)}return Hh=a,Hh}var Wh,jR;function vn(){if(jR)return Wh;jR=1;function e(t){var r=typeof t;return t!=null&&(r=="object"||r=="function")}return Wh=e,Wh}var Uh,LR;function Ol(){if(LR)return Uh;LR=1;var e=Ni(),t=vn(),r="[object AsyncFunction]",n="[object Function]",o="[object GeneratorFunction]",i="[object Proxy]";function a(s){if(!t(s))return!1;var c=e(s);return c==n||c==o||c==r||c==i}return Uh=a,Uh}var Gh,qR;function hZ(){if(qR)return Gh;qR=1;var e=Dn(),t=e["__core-js_shared__"];return Gh=t,Gh}var Yh,zR;function vZ(){if(zR)return Yh;zR=1;var e=hZ(),t=(function(){var n=/[^.]+$/.exec(e&&e.keys&&e.keys.IE_PROTO||"");return n?"Symbol(src)_1."+n:""})();function r(n){return!!t&&t in n}return Yh=r,Yh}var Kh,BR;function L5(){if(BR)return Kh;BR=1;var e=Function.prototype,t=e.toString;function r(n){if(n!=null){try{return t.call(n)}catch{}try{return n+""}catch{}}return""}return Kh=r,Kh}var Xh,FR;function gZ(){if(FR)return Xh;FR=1;var e=Ol(),t=vZ(),r=vn(),n=L5(),o=/[\\^$.*+?()[\]{}|]/g,i=/^\[object .+?Constructor\]$/,a=Function.prototype,s=Object.prototype,c=a.toString,u=s.hasOwnProperty,d=RegExp("^"+c.call(u).replace(o,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function f(h){if(!r(h)||t(h))return!1;var v=e(h)?d:i;return v.test(n(h))}return Xh=f,Xh}var Zh,$R;function mZ(){if($R)return Zh;$R=1;function e(t,r){return t==null?void 0:t[r]}return Zh=e,Zh}var Jh,VR;function Ii(){if(VR)return Jh;VR=1;var e=gZ(),t=mZ();function r(n,o){var i=t(n,o);return e(i)?i:void 0}return Jh=r,Jh}var Qh,HR;function x1(){if(HR)return Qh;HR=1;var e=Ii(),t=Dn(),r=e(t,"Map");return Qh=r,Qh}var ev,WR;function Vd(){if(WR)return ev;WR=1;var e=Ii(),t=e(Object,"create");return ev=t,ev}var tv,UR;function bZ(){if(UR)return tv;UR=1;var e=Vd();function t(){this.__data__=e?e(null):{},this.size=0}return tv=t,tv}var rv,GR;function yZ(){if(GR)return rv;GR=1;function e(t){var r=this.has(t)&&delete this.__data__[t];return this.size-=r?1:0,r}return rv=e,rv}var nv,YR;function xZ(){if(YR)return nv;YR=1;var e=Vd(),t="__lodash_hash_undefined__",r=Object.prototype,n=r.hasOwnProperty;function o(i){var a=this.__data__;if(e){var s=a[i];return s===t?void 0:s}return n.call(a,i)?a[i]:void 0}return nv=o,nv}var ov,KR;function wZ(){if(KR)return ov;KR=1;var e=Vd(),t=Object.prototype,r=t.hasOwnProperty;function n(o){var i=this.__data__;return e?i[o]!==void 0:r.call(i,o)}return ov=n,ov}var iv,XR;function _Z(){if(XR)return iv;XR=1;var e=Vd(),t="__lodash_hash_undefined__";function r(n,o){var i=this.__data__;return this.size+=this.has(n)?0:1,i[n]=e&&o===void 0?t:o,this}return iv=r,iv}var av,ZR;function EZ(){if(ZR)return av;ZR=1;var e=bZ(),t=yZ(),r=xZ(),n=wZ(),o=_Z();function i(a){var s=-1,c=a==null?0:a.length;for(this.clear();++s<c;){var u=a[s];this.set(u[0],u[1])}}return i.prototype.clear=e,i.prototype.delete=t,i.prototype.get=r,i.prototype.has=n,i.prototype.set=o,av=i,av}var sv,JR;function SZ(){if(JR)return sv;JR=1;var e=EZ(),t=$d(),r=x1();function n(){this.size=0,this.__data__={hash:new e,map:new(r||t),string:new e}}return sv=n,sv}var lv,QR;function OZ(){if(QR)return lv;QR=1;function e(t){var r=typeof t;return r=="string"||r=="number"||r=="symbol"||r=="boolean"?t!=="__proto__":t===null}return lv=e,lv}var cv,eN;function Hd(){if(eN)return cv;eN=1;var e=OZ();function t(r,n){var o=r.__data__;return e(n)?o[typeof n=="string"?"string":"hash"]:o.map}return cv=t,cv}var uv,tN;function CZ(){if(tN)return uv;tN=1;var e=Hd();function t(r){var n=e(this,r).delete(r);return this.size-=n?1:0,n}return uv=t,uv}var dv,rN;function RZ(){if(rN)return dv;rN=1;var e=Hd();function t(r){return e(this,r).get(r)}return dv=t,dv}var fv,nN;function NZ(){if(nN)return fv;nN=1;var e=Hd();function t(r){return e(this,r).has(r)}return fv=t,fv}var pv,oN;function IZ(){if(oN)return pv;oN=1;var e=Hd();function t(r,n){var o=e(this,r),i=o.size;return o.set(r,n),this.size+=o.size==i?0:1,this}return pv=t,pv}var hv,iN;function w1(){if(iN)return hv;iN=1;var e=SZ(),t=CZ(),r=RZ(),n=NZ(),o=IZ();function i(a){var s=-1,c=a==null?0:a.length;for(this.clear();++s<c;){var u=a[s];this.set(u[0],u[1])}}return i.prototype.clear=e,i.prototype.delete=t,i.prototype.get=r,i.prototype.has=n,i.prototype.set=o,hv=i,hv}var vv,aN;function PZ(){if(aN)return vv;aN=1;var e=$d(),t=x1(),r=w1(),n=200;function o(i,a){var s=this.__data__;if(s instanceof e){var c=s.__data__;if(!t||c.length<n-1)return c.push([i,a]),this.size=++s.size,this;s=this.__data__=new r(c)}return s.set(i,a),this.size=s.size,this}return vv=o,vv}var gv,sN;function Wd(){if(sN)return gv;sN=1;var e=$d(),t=lZ(),r=cZ(),n=uZ(),o=dZ(),i=PZ();function a(s){var c=this.__data__=new e(s);this.size=c.size}return a.prototype.clear=t,a.prototype.delete=r,a.prototype.get=n,a.prototype.has=o,a.prototype.set=i,gv=a,gv}var mv,lN;function _1(){if(lN)return mv;lN=1;function e(t,r){for(var n=-1,o=t==null?0:t.length;++n<o&&r(t[n],n,t)!==!1;);return t}return mv=e,mv}var bv,cN;function q5(){if(cN)return bv;cN=1;var e=Ii(),t=(function(){try{var r=e(Object,"defineProperty");return r({},"",{}),r}catch{}})();return bv=t,bv}var yv,uN;function Ud(){if(uN)return yv;uN=1;var e=q5();function t(r,n,o){n=="__proto__"&&e?e(r,n,{configurable:!0,enumerable:!0,value:o,writable:!0}):r[n]=o}return yv=t,yv}var xv,dN;function Gd(){if(dN)return xv;dN=1;var e=Ud(),t=qa(),r=Object.prototype,n=r.hasOwnProperty;function o(i,a,s){var c=i[a];(!(n.call(i,a)&&t(c,s))||s===void 0&&!(a in i))&&e(i,a,s)}return xv=o,xv}var wv,fN;function Cl(){if(fN)return wv;fN=1;var e=Gd(),t=Ud();function r(n,o,i,a){var s=!i;i||(i={});for(var c=-1,u=o.length;++c<u;){var d=o[c],f=a?a(i[d],n[d],d,i,n):void 0;f===void 0&&(f=n[d]),s?t(i,d,f):e(i,d,f)}return i}return wv=r,wv}var _v,pN;function TZ(){if(pN)return _v;pN=1;function e(t,r){for(var n=-1,o=Array(t);++n<t;)o[n]=r(n);return o}return _v=e,_v}var Ev,hN;function eo(){if(hN)return Ev;hN=1;function e(t){return t!=null&&typeof t=="object"}return Ev=e,Ev}var Sv,vN;function AZ(){if(vN)return Sv;vN=1;var e=Ni(),t=eo(),r="[object Arguments]";function n(o){return t(o)&&e(o)==r}return Sv=n,Sv}var Ov,gN;function Rl(){if(gN)return Ov;gN=1;var e=AZ(),t=eo(),r=Object.prototype,n=r.hasOwnProperty,o=r.propertyIsEnumerable,i=e((function(){return arguments})())?e:function(a){return t(a)&&n.call(a,"callee")&&!o.call(a,"callee")};return Ov=i,Ov}var Cv,mN;function Bt(){if(mN)return Cv;mN=1;var e=Array.isArray;return Cv=e,Cv}var Bs={exports:{}},Rv,bN;function kZ(){if(bN)return Rv;bN=1;function e(){return!1}return Rv=e,Rv}Bs.exports;var yN;function Ba(){return yN||(yN=1,(function(e,t){var r=Dn(),n=kZ(),o=t&&!t.nodeType&&t,i=o&&!0&&e&&!e.nodeType&&e,a=i&&i.exports===o,s=a?r.Buffer:void 0,c=s?s.isBuffer:void 0,u=c||n;e.exports=u})(Bs,Bs.exports)),Bs.exports}var Nv,xN;function Yd(){if(xN)return Nv;xN=1;var e=9007199254740991,t=/^(?:0|[1-9]\d*)$/;function r(n,o){var i=typeof n;return o=o??e,!!o&&(i=="number"||i!="symbol"&&t.test(n))&&n>-1&&n%1==0&&n<o}return Nv=r,Nv}var Iv,wN;function E1(){if(wN)return Iv;wN=1;var e=9007199254740991;function t(r){return typeof r=="number"&&r>-1&&r%1==0&&r<=e}return Iv=t,Iv}var Pv,_N;function DZ(){if(_N)return Pv;_N=1;var e=Ni(),t=E1(),r=eo(),n="[object Arguments]",o="[object Array]",i="[object Boolean]",a="[object Date]",s="[object Error]",c="[object Function]",u="[object Map]",d="[object Number]",f="[object Object]",h="[object RegExp]",v="[object Set]",b="[object String]",g="[object WeakMap]",m="[object ArrayBuffer]",x="[object DataView]",w="[object Float32Array]",E="[object Float64Array]",S="[object Int8Array]",_="[object Int16Array]",C="[object Int32Array]",N="[object Uint8Array]",P="[object Uint8ClampedArray]",A="[object Uint16Array]",j="[object Uint32Array]",M={};M[w]=M[E]=M[S]=M[_]=M[C]=M[N]=M[P]=M[A]=M[j]=!0,M[n]=M[o]=M[m]=M[i]=M[x]=M[a]=M[s]=M[c]=M[u]=M[d]=M[f]=M[h]=M[v]=M[b]=M[g]=!1;function L(D){return r(D)&&t(D.length)&&!!M[e(D)]}return Pv=L,Pv}var Tv,EN;function Kd(){if(EN)return Tv;EN=1;function e(t){return function(r){return t(r)}}return Tv=e,Tv}var Fs={exports:{}};Fs.exports;var SN;function S1(){return SN||(SN=1,(function(e,t){var r=j5(),n=t&&!t.nodeType&&t,o=n&&!0&&e&&!e.nodeType&&e,i=o&&o.exports===n,a=i&&r.process,s=(function(){try{var c=o&&o.require&&o.require("util").types;return c||a&&a.binding&&a.binding("util")}catch{}})();e.exports=s})(Fs,Fs.exports)),Fs.exports}var Av,ON;function Nl(){if(ON)return Av;ON=1;var e=DZ(),t=Kd(),r=S1(),n=r&&r.isTypedArray,o=n?t(n):e;return Av=o,Av}var kv,CN;function z5(){if(CN)return kv;CN=1;var e=TZ(),t=Rl(),r=Bt(),n=Ba(),o=Yd(),i=Nl(),a=Object.prototype,s=a.hasOwnProperty;function c(u,d){var f=r(u),h=!f&&t(u),v=!f&&!h&&n(u),b=!f&&!h&&!v&&i(u),g=f||h||v||b,m=g?e(u.length,String):[],x=m.length;for(var w in u)(d||s.call(u,w))&&!(g&&(w=="length"||v&&(w=="offset"||w=="parent")||b&&(w=="buffer"||w=="byteLength"||w=="byteOffset")||o(w,x)))&&m.push(w);return m}return kv=c,kv}var Dv,RN;function Xd(){if(RN)return Dv;RN=1;var e=Object.prototype;function t(r){var n=r&&r.constructor,o=typeof n=="function"&&n.prototype||e;return r===o}return Dv=t,Dv}var Mv,NN;function B5(){if(NN)return Mv;NN=1;function e(t,r){return function(n){return t(r(n))}}return Mv=e,Mv}var jv,IN;function MZ(){if(IN)return jv;IN=1;var e=B5(),t=e(Object.keys,Object);return jv=t,jv}var Lv,PN;function O1(){if(PN)return Lv;PN=1;var e=Xd(),t=MZ(),r=Object.prototype,n=r.hasOwnProperty;function o(i){if(!e(i))return t(i);var a=[];for(var s in Object(i))n.call(i,s)&&s!="constructor"&&a.push(s);return a}return Lv=o,Lv}var qv,TN;function Eo(){if(TN)return qv;TN=1;var e=Ol(),t=E1();function r(n){return n!=null&&t(n.length)&&!e(n)}return qv=r,qv}var zv,AN;function Jo(){if(AN)return zv;AN=1;var e=z5(),t=O1(),r=Eo();function n(o){return r(o)?e(o):t(o)}return zv=n,zv}var Bv,kN;function jZ(){if(kN)return Bv;kN=1;var e=Cl(),t=Jo();function r(n,o){return n&&e(o,t(o),n)}return Bv=r,Bv}var Fv,DN;function LZ(){if(DN)return Fv;DN=1;function e(t){var r=[];if(t!=null)for(var n in Object(t))r.push(n);return r}return Fv=e,Fv}var $v,MN;function qZ(){if(MN)return $v;MN=1;var e=vn(),t=Xd(),r=LZ(),n=Object.prototype,o=n.hasOwnProperty;function i(a){if(!e(a))return r(a);var s=t(a),c=[];for(var u in a)u=="constructor"&&(s||!o.call(a,u))||c.push(u);return c}return $v=i,$v}var Vv,jN;function Pi(){if(jN)return Vv;jN=1;var e=z5(),t=qZ(),r=Eo();function n(o){return r(o)?e(o,!0):t(o)}return Vv=n,Vv}var Hv,LN;function zZ(){if(LN)return Hv;LN=1;var e=Cl(),t=Pi();function r(n,o){return n&&e(o,t(o),n)}return Hv=r,Hv}var $s={exports:{}};$s.exports;var qN;function F5(){return qN||(qN=1,(function(e,t){var r=Dn(),n=t&&!t.nodeType&&t,o=n&&!0&&e&&!e.nodeType&&e,i=o&&o.exports===n,a=i?r.Buffer:void 0,s=a?a.allocUnsafe:void 0;function c(u,d){if(d)return u.slice();var f=u.length,h=s?s(f):new u.constructor(f);return u.copy(h),h}e.exports=c})($s,$s.exports)),$s.exports}var Wv,zN;function $5(){if(zN)return Wv;zN=1;function e(t,r){var n=-1,o=t.length;for(r||(r=Array(o));++n<o;)r[n]=t[n];return r}return Wv=e,Wv}var Uv,BN;function V5(){if(BN)return Uv;BN=1;function e(t,r){for(var n=-1,o=t==null?0:t.length,i=0,a=[];++n<o;){var s=t[n];r(s,n,t)&&(a[i++]=s)}return a}return Uv=e,Uv}var Gv,FN;function H5(){if(FN)return Gv;FN=1;function e(){return[]}return Gv=e,Gv}var Yv,$N;function C1(){if($N)return Yv;$N=1;var e=V5(),t=H5(),r=Object.prototype,n=r.propertyIsEnumerable,o=Object.getOwnPropertySymbols,i=o?function(a){return a==null?[]:(a=Object(a),e(o(a),function(s){return n.call(a,s)}))}:t;return Yv=i,Yv}var Kv,VN;function BZ(){if(VN)return Kv;VN=1;var e=Cl(),t=C1();function r(n,o){return e(n,t(n),o)}return Kv=r,Kv}var Xv,HN;function R1(){if(HN)return Xv;HN=1;function e(t,r){for(var n=-1,o=r.length,i=t.length;++n<o;)t[i+n]=r[n];return t}return Xv=e,Xv}var Zv,WN;function Zd(){if(WN)return Zv;WN=1;var e=B5(),t=e(Object.getPrototypeOf,Object);return Zv=t,Zv}var Jv,UN;function W5(){if(UN)return Jv;UN=1;var e=R1(),t=Zd(),r=C1(),n=H5(),o=Object.getOwnPropertySymbols,i=o?function(a){for(var s=[];a;)e(s,r(a)),a=t(a);return s}:n;return Jv=i,Jv}var Qv,GN;function FZ(){if(GN)return Qv;GN=1;var e=Cl(),t=W5();function r(n,o){return e(n,t(n),o)}return Qv=r,Qv}var eg,YN;function U5(){if(YN)return eg;YN=1;var e=R1(),t=Bt();function r(n,o,i){var a=o(n);return t(n)?a:e(a,i(n))}return eg=r,eg}var tg,KN;function G5(){if(KN)return tg;KN=1;var e=U5(),t=C1(),r=Jo();function n(o){return e(o,r,t)}return tg=n,tg}var rg,XN;function $Z(){if(XN)return rg;XN=1;var e=U5(),t=W5(),r=Pi();function n(o){return e(o,r,t)}return rg=n,rg}var ng,ZN;function VZ(){if(ZN)return ng;ZN=1;var e=Ii(),t=Dn(),r=e(t,"DataView");return ng=r,ng}var og,JN;function HZ(){if(JN)return og;JN=1;var e=Ii(),t=Dn(),r=e(t,"Promise");return og=r,og}var ig,QN;function Y5(){if(QN)return ig;QN=1;var e=Ii(),t=Dn(),r=e(t,"Set");return ig=r,ig}var ag,eI;function WZ(){if(eI)return ag;eI=1;var e=Ii(),t=Dn(),r=e(t,"WeakMap");return ag=r,ag}var sg,tI;function Fa(){if(tI)return sg;tI=1;var e=VZ(),t=x1(),r=HZ(),n=Y5(),o=WZ(),i=Ni(),a=L5(),s="[object Map]",c="[object Object]",u="[object Promise]",d="[object Set]",f="[object WeakMap]",h="[object DataView]",v=a(e),b=a(t),g=a(r),m=a(n),x=a(o),w=i;return(e&&w(new e(new ArrayBuffer(1)))!=h||t&&w(new t)!=s||r&&w(r.resolve())!=u||n&&w(new n)!=d||o&&w(new o)!=f)&&(w=function(E){var S=i(E),_=S==c?E.constructor:void 0,C=_?a(_):"";if(C)switch(C){case v:return h;case b:return s;case g:return u;case m:return d;case x:return f}return S}),sg=w,sg}var lg,rI;function UZ(){if(rI)return lg;rI=1;var e=Object.prototype,t=e.hasOwnProperty;function r(n){var o=n.length,i=new n.constructor(o);return o&&typeof n[0]=="string"&&t.call(n,"index")&&(i.index=n.index,i.input=n.input),i}return lg=r,lg}var cg,nI;function K5(){if(nI)return cg;nI=1;var e=Dn(),t=e.Uint8Array;return cg=t,cg}var ug,oI;function N1(){if(oI)return ug;oI=1;var e=K5();function t(r){var n=new r.constructor(r.byteLength);return new e(n).set(new e(r)),n}return ug=t,ug}var dg,iI;function GZ(){if(iI)return dg;iI=1;var e=N1();function t(r,n){var o=n?e(r.buffer):r.buffer;return new r.constructor(o,r.byteOffset,r.byteLength)}return dg=t,dg}var fg,aI;function YZ(){if(aI)return fg;aI=1;var e=/\w*$/;function t(r){var n=new r.constructor(r.source,e.exec(r));return n.lastIndex=r.lastIndex,n}return fg=t,fg}var pg,sI;function KZ(){if(sI)return pg;sI=1;var e=za(),t=e?e.prototype:void 0,r=t?t.valueOf:void 0;function n(o){return r?Object(r.call(o)):{}}return pg=n,pg}var hg,lI;function X5(){if(lI)return hg;lI=1;var e=N1();function t(r,n){var o=n?e(r.buffer):r.buffer;return new r.constructor(o,r.byteOffset,r.length)}return hg=t,hg}var vg,cI;function XZ(){if(cI)return vg;cI=1;var e=N1(),t=GZ(),r=YZ(),n=KZ(),o=X5(),i="[object Boolean]",a="[object Date]",s="[object Map]",c="[object Number]",u="[object RegExp]",d="[object Set]",f="[object String]",h="[object Symbol]",v="[object ArrayBuffer]",b="[object DataView]",g="[object Float32Array]",m="[object Float64Array]",x="[object Int8Array]",w="[object Int16Array]",E="[object Int32Array]",S="[object Uint8Array]",_="[object Uint8ClampedArray]",C="[object Uint16Array]",N="[object Uint32Array]";function P(A,j,M){var L=A.constructor;switch(j){case v:return e(A);case i:case a:return new L(+A);case b:return t(A,M);case g:case m:case x:case w:case E:case S:case _:case C:case N:return o(A,M);case s:return new L;case c:case f:return new L(A);case u:return r(A);case d:return new L;case h:return n(A)}}return vg=P,vg}var gg,uI;function Z5(){if(uI)return gg;uI=1;var e=vn(),t=Object.create,r=(function(){function n(){}return function(o){if(!e(o))return{};if(t)return t(o);n.prototype=o;var i=new n;return n.prototype=void 0,i}})();return gg=r,gg}var mg,dI;function J5(){if(dI)return mg;dI=1;var e=Z5(),t=Zd(),r=Xd();function n(o){return typeof o.constructor=="function"&&!r(o)?e(t(o)):{}}return mg=n,mg}var bg,fI;function ZZ(){if(fI)return bg;fI=1;var e=Fa(),t=eo(),r="[object Map]";function n(o){return t(o)&&e(o)==r}return bg=n,bg}var yg,pI;function JZ(){if(pI)return yg;pI=1;var e=ZZ(),t=Kd(),r=S1(),n=r&&r.isMap,o=n?t(n):e;return yg=o,yg}var xg,hI;function QZ(){if(hI)return xg;hI=1;var e=Fa(),t=eo(),r="[object Set]";function n(o){return t(o)&&e(o)==r}return xg=n,xg}var wg,vI;function eJ(){if(vI)return wg;vI=1;var e=QZ(),t=Kd(),r=S1(),n=r&&r.isSet,o=n?t(n):e;return wg=o,wg}var _g,gI;function Q5(){if(gI)return _g;gI=1;var e=Wd(),t=_1(),r=Gd(),n=jZ(),o=zZ(),i=F5(),a=$5(),s=BZ(),c=FZ(),u=G5(),d=$Z(),f=Fa(),h=UZ(),v=XZ(),b=J5(),g=Bt(),m=Ba(),x=JZ(),w=vn(),E=eJ(),S=Jo(),_=Pi(),C=1,N=2,P=4,A="[object Arguments]",j="[object Array]",M="[object Boolean]",L="[object Date]",D="[object Error]",T="[object Function]",W="[object GeneratorFunction]",q="[object Map]",G="[object Number]",F="[object Object]",J="[object RegExp]",z="[object Set]",U="[object String]",oe="[object Symbol]",re="[object WeakMap]",$="[object ArrayBuffer]",Y="[object DataView]",X="[object Float32Array]",H="[object Float64Array]",K="[object Int8Array]",Q="[object Int16Array]",ne="[object Int32Array]",se="[object Uint8Array]",te="[object Uint8ClampedArray]",be="[object Uint16Array]",de="[object Uint32Array]",Ee={};Ee[A]=Ee[j]=Ee[$]=Ee[Y]=Ee[M]=Ee[L]=Ee[X]=Ee[H]=Ee[K]=Ee[Q]=Ee[ne]=Ee[q]=Ee[G]=Ee[F]=Ee[J]=Ee[z]=Ee[U]=Ee[oe]=Ee[se]=Ee[te]=Ee[be]=Ee[de]=!0,Ee[D]=Ee[T]=Ee[re]=!1;function fe(le,Ce,Te,Fe,Le,Ze){var We,St=Ce&C,tt=Ce&N,wt=Ce&P;if(Te&&(We=Le?Te(le,Fe,Le,Ze):Te(le)),We!==void 0)return We;if(!w(le))return le;var Je=g(le);if(Je){if(We=h(le),!St)return a(le,We)}else{var Ne=f(le),je=Ne==T||Ne==W;if(m(le))return i(le,St);if(Ne==F||Ne==A||je&&!Le){if(We=tt||je?{}:b(le),!St)return tt?c(le,o(We,le)):s(le,n(We,le))}else{if(!Ee[Ne])return Le?le:{};We=v(le,Ne,St)}}Ze||(Ze=new e);var Qe=Ze.get(le);if(Qe)return Qe;Ze.set(le,We),E(le)?le.forEach(function(mt){We.add(fe(mt,Ce,Te,mt,le,Ze))}):x(le)&&le.forEach(function(mt,Rt){We.set(Rt,fe(mt,Ce,Te,Rt,le,Ze))});var At=wt?tt?d:u:tt?_:S,It=Je?void 0:At(le);return t(It||le,function(mt,Rt){It&&(Rt=mt,mt=le[Rt]),r(We,Rt,fe(mt,Ce,Te,Rt,le,Ze))}),We}return _g=fe,_g}var Eg,mI;function tJ(){if(mI)return Eg;mI=1;var e=Q5(),t=4;function r(n){return e(n,t)}return Eg=r,Eg}var Sg,bI;function I1(){if(bI)return Sg;bI=1;function e(t){return function(){return t}}return Sg=e,Sg}var Og,yI;function rJ(){if(yI)return Og;yI=1;function e(t){return function(r,n,o){for(var i=-1,a=Object(r),s=o(r),c=s.length;c--;){var u=s[t?c:++i];if(n(a[u],u,a)===!1)break}return r}}return Og=e,Og}var Cg,xI;function P1(){if(xI)return Cg;xI=1;var e=rJ(),t=e();return Cg=t,Cg}var Rg,wI;function T1(){if(wI)return Rg;wI=1;var e=P1(),t=Jo();function r(n,o){return n&&e(n,o,t)}return Rg=r,Rg}var Ng,_I;function nJ(){if(_I)return Ng;_I=1;var e=Eo();function t(r,n){return function(o,i){if(o==null)return o;if(!e(o))return r(o,i);for(var a=o.length,s=n?a:-1,c=Object(o);(n?s--:++s<a)&&i(c[s],s,c)!==!1;);return o}}return Ng=t,Ng}var Ig,EI;function Jd(){if(EI)return Ig;EI=1;var e=T1(),t=nJ(),r=t(e);return Ig=r,Ig}var Pg,SI;function Ti(){if(SI)return Pg;SI=1;function e(t){return t}return Pg=e,Pg}var Tg,OI;function ez(){if(OI)return Tg;OI=1;var e=Ti();function t(r){return typeof r=="function"?r:e}return Tg=t,Tg}var Ag,CI;function tz(){if(CI)return Ag;CI=1;var e=_1(),t=Jd(),r=ez(),n=Bt();function o(i,a){var s=n(i)?e:t;return s(i,r(a))}return Ag=o,Ag}var kg,RI;function rz(){return RI||(RI=1,kg=tz()),kg}var Dg,NI;function oJ(){if(NI)return Dg;NI=1;var e=Jd();function t(r,n){var o=[];return e(r,function(i,a,s){n(i,a,s)&&o.push(i)}),o}return Dg=t,Dg}var Mg,II;function iJ(){if(II)return Mg;II=1;var e="__lodash_hash_undefined__";function t(r){return this.__data__.set(r,e),this}return Mg=t,Mg}var jg,PI;function aJ(){if(PI)return jg;PI=1;function e(t){return this.__data__.has(t)}return jg=e,jg}var Lg,TI;function nz(){if(TI)return Lg;TI=1;var e=w1(),t=iJ(),r=aJ();function n(o){var i=-1,a=o==null?0:o.length;for(this.__data__=new e;++i<a;)this.add(o[i])}return n.prototype.add=n.prototype.push=t,n.prototype.has=r,Lg=n,Lg}var qg,AI;function sJ(){if(AI)return qg;AI=1;function e(t,r){for(var n=-1,o=t==null?0:t.length;++n<o;)if(r(t[n],n,t))return!0;return!1}return qg=e,qg}var zg,kI;function oz(){if(kI)return zg;kI=1;function e(t,r){return t.has(r)}return zg=e,zg}var Bg,DI;function iz(){if(DI)return Bg;DI=1;var e=nz(),t=sJ(),r=oz(),n=1,o=2;function i(a,s,c,u,d,f){var h=c&n,v=a.length,b=s.length;if(v!=b&&!(h&&b>v))return!1;var g=f.get(a),m=f.get(s);if(g&&m)return g==s&&m==a;var x=-1,w=!0,E=c&o?new e:void 0;for(f.set(a,s),f.set(s,a);++x<v;){var S=a[x],_=s[x];if(u)var C=h?u(_,S,x,s,a,f):u(S,_,x,a,s,f);if(C!==void 0){if(C)continue;w=!1;break}if(E){if(!t(s,function(N,P){if(!r(E,P)&&(S===N||d(S,N,c,u,f)))return E.push(P)})){w=!1;break}}else if(!(S===_||d(S,_,c,u,f))){w=!1;break}}return f.delete(a),f.delete(s),w}return Bg=i,Bg}var Fg,MI;function lJ(){if(MI)return Fg;MI=1;function e(t){var r=-1,n=Array(t.size);return t.forEach(function(o,i){n[++r]=[i,o]}),n}return Fg=e,Fg}var $g,jI;function A1(){if(jI)return $g;jI=1;function e(t){var r=-1,n=Array(t.size);return t.forEach(function(o){n[++r]=o}),n}return $g=e,$g}var Vg,LI;function cJ(){if(LI)return Vg;LI=1;var e=za(),t=K5(),r=qa(),n=iz(),o=lJ(),i=A1(),a=1,s=2,c="[object Boolean]",u="[object Date]",d="[object Error]",f="[object Map]",h="[object Number]",v="[object RegExp]",b="[object Set]",g="[object String]",m="[object Symbol]",x="[object ArrayBuffer]",w="[object DataView]",E=e?e.prototype:void 0,S=E?E.valueOf:void 0;function _(C,N,P,A,j,M,L){switch(P){case w:if(C.byteLength!=N.byteLength||C.byteOffset!=N.byteOffset)return!1;C=C.buffer,N=N.buffer;case x:return!(C.byteLength!=N.byteLength||!M(new t(C),new t(N)));case c:case u:case h:return r(+C,+N);case d:return C.name==N.name&&C.message==N.message;case v:case g:return C==N+"";case f:var D=o;case b:var T=A&a;if(D||(D=i),C.size!=N.size&&!T)return!1;var W=L.get(C);if(W)return W==N;A|=s,L.set(C,N);var q=n(D(C),D(N),A,j,M,L);return L.delete(C),q;case m:if(S)return S.call(C)==S.call(N)}return!1}return Vg=_,Vg}var Hg,qI;function uJ(){if(qI)return Hg;qI=1;var e=G5(),t=1,r=Object.prototype,n=r.hasOwnProperty;function o(i,a,s,c,u,d){var f=s&t,h=e(i),v=h.length,b=e(a),g=b.length;if(v!=g&&!f)return!1;for(var m=v;m--;){var x=h[m];if(!(f?x in a:n.call(a,x)))return!1}var w=d.get(i),E=d.get(a);if(w&&E)return w==a&&E==i;var S=!0;d.set(i,a),d.set(a,i);for(var _=f;++m<v;){x=h[m];var C=i[x],N=a[x];if(c)var P=f?c(N,C,x,a,i,d):c(C,N,x,i,a,d);if(!(P===void 0?C===N||u(C,N,s,c,d):P)){S=!1;break}_||(_=x=="constructor")}if(S&&!_){var A=i.constructor,j=a.constructor;A!=j&&"constructor"in i&&"constructor"in a&&!(typeof A=="function"&&A instanceof A&&typeof j=="function"&&j instanceof j)&&(S=!1)}return d.delete(i),d.delete(a),S}return Hg=o,Hg}var Wg,zI;function dJ(){if(zI)return Wg;zI=1;var e=Wd(),t=iz(),r=cJ(),n=uJ(),o=Fa(),i=Bt(),a=Ba(),s=Nl(),c=1,u="[object Arguments]",d="[object Array]",f="[object Object]",h=Object.prototype,v=h.hasOwnProperty;function b(g,m,x,w,E,S){var _=i(g),C=i(m),N=_?d:o(g),P=C?d:o(m);N=N==u?f:N,P=P==u?f:P;var A=N==f,j=P==f,M=N==P;if(M&&a(g)){if(!a(m))return!1;_=!0,A=!1}if(M&&!A)return S||(S=new e),_||s(g)?t(g,m,x,w,E,S):r(g,m,N,x,w,E,S);if(!(x&c)){var L=A&&v.call(g,"__wrapped__"),D=j&&v.call(m,"__wrapped__");if(L||D){var T=L?g.value():g,W=D?m.value():m;return S||(S=new e),E(T,W,x,w,S)}}return M?(S||(S=new e),n(g,m,x,w,E,S)):!1}return Wg=b,Wg}var Ug,BI;function az(){if(BI)return Ug;BI=1;var e=dJ(),t=eo();function r(n,o,i,a,s){return n===o?!0:n==null||o==null||!t(n)&&!t(o)?n!==n&&o!==o:e(n,o,i,a,r,s)}return Ug=r,Ug}var Gg,FI;function fJ(){if(FI)return Gg;FI=1;var e=Wd(),t=az(),r=1,n=2;function o(i,a,s,c){var u=s.length,d=u,f=!c;if(i==null)return!d;for(i=Object(i);u--;){var h=s[u];if(f&&h[2]?h[1]!==i[h[0]]:!(h[0]in i))return!1}for(;++u<d;){h=s[u];var v=h[0],b=i[v],g=h[1];if(f&&h[2]){if(b===void 0&&!(v in i))return!1}else{var m=new e;if(c)var x=c(b,g,v,i,a,m);if(!(x===void 0?t(g,b,r|n,c,m):x))return!1}}return!0}return Gg=o,Gg}var Yg,$I;function sz(){if($I)return Yg;$I=1;var e=vn();function t(r){return r===r&&!e(r)}return Yg=t,Yg}var Kg,VI;function pJ(){if(VI)return Kg;VI=1;var e=sz(),t=Jo();function r(n){for(var o=t(n),i=o.length;i--;){var a=o[i],s=n[a];o[i]=[a,s,e(s)]}return o}return Kg=r,Kg}var Xg,HI;function lz(){if(HI)return Xg;HI=1;function e(t,r){return function(n){return n==null?!1:n[t]===r&&(r!==void 0||t in Object(n))}}return Xg=e,Xg}var Zg,WI;function hJ(){if(WI)return Zg;WI=1;var e=fJ(),t=pJ(),r=lz();function n(o){var i=t(o);return i.length==1&&i[0][2]?r(i[0][0],i[0][1]):function(a){return a===o||e(a,o,i)}}return Zg=n,Zg}var Jg,UI;function $a(){if(UI)return Jg;UI=1;var e=Ni(),t=eo(),r="[object Symbol]";function n(o){return typeof o=="symbol"||t(o)&&e(o)==r}return Jg=n,Jg}var Qg,GI;function k1(){if(GI)return Qg;GI=1;var e=Bt(),t=$a(),r=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,n=/^\w*$/;function o(i,a){if(e(i))return!1;var s=typeof i;return s=="number"||s=="symbol"||s=="boolean"||i==null||t(i)?!0:n.test(i)||!r.test(i)||a!=null&&i in Object(a)}return Qg=o,Qg}var em,YI;function vJ(){if(YI)return em;YI=1;var e=w1(),t="Expected a function";function r(n,o){if(typeof n!="function"||o!=null&&typeof o!="function")throw new TypeError(t);var i=function(){var a=arguments,s=o?o.apply(this,a):a[0],c=i.cache;if(c.has(s))return c.get(s);var u=n.apply(this,a);return i.cache=c.set(s,u)||c,u};return i.cache=new(r.Cache||e),i}return r.Cache=e,em=r,em}var tm,KI;function gJ(){if(KI)return tm;KI=1;var e=vJ(),t=500;function r(n){var o=e(n,function(a){return i.size===t&&i.clear(),a}),i=o.cache;return o}return tm=r,tm}var rm,XI;function mJ(){if(XI)return rm;XI=1;var e=gJ(),t=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,r=/\\(\\)?/g,n=e(function(o){var i=[];return o.charCodeAt(0)===46&&i.push(""),o.replace(t,function(a,s,c,u){i.push(c?u.replace(r,"$1"):s||a)}),i});return rm=n,rm}var nm,ZI;function Qd(){if(ZI)return nm;ZI=1;function e(t,r){for(var n=-1,o=t==null?0:t.length,i=Array(o);++n<o;)i[n]=r(t[n],n,t);return i}return nm=e,nm}var om,JI;function bJ(){if(JI)return om;JI=1;var e=za(),t=Qd(),r=Bt(),n=$a(),o=e?e.prototype:void 0,i=o?o.toString:void 0;function a(s){if(typeof s=="string")return s;if(r(s))return t(s,a)+"";if(n(s))return i?i.call(s):"";var c=s+"";return c=="0"&&1/s==-1/0?"-0":c}return om=a,om}var im,QI;function cz(){if(QI)return im;QI=1;var e=bJ();function t(r){return r==null?"":e(r)}return im=t,im}var am,eP;function ef(){if(eP)return am;eP=1;var e=Bt(),t=k1(),r=mJ(),n=cz();function o(i,a){return e(i)?i:t(i,a)?[i]:r(n(i))}return am=o,am}var sm,tP;function Il(){if(tP)return sm;tP=1;var e=$a();function t(r){if(typeof r=="string"||e(r))return r;var n=r+"";return n=="0"&&1/r==-1/0?"-0":n}return sm=t,sm}var lm,rP;function tf(){if(rP)return lm;rP=1;var e=ef(),t=Il();function r(n,o){o=e(o,n);for(var i=0,a=o.length;n!=null&&i<a;)n=n[t(o[i++])];return i&&i==a?n:void 0}return lm=r,lm}var cm,nP;function yJ(){if(nP)return cm;nP=1;var e=tf();function t(r,n,o){var i=r==null?void 0:e(r,n);return i===void 0?o:i}return cm=t,cm}var um,oP;function xJ(){if(oP)return um;oP=1;function e(t,r){return t!=null&&r in Object(t)}return um=e,um}var dm,iP;function uz(){if(iP)return dm;iP=1;var e=ef(),t=Rl(),r=Bt(),n=Yd(),o=E1(),i=Il();function a(s,c,u){c=e(c,s);for(var d=-1,f=c.length,h=!1;++d<f;){var v=i(c[d]);if(!(h=s!=null&&u(s,v)))break;s=s[v]}return h||++d!=f?h:(f=s==null?0:s.length,!!f&&o(f)&&n(v,f)&&(r(s)||t(s)))}return dm=a,dm}var fm,aP;function dz(){if(aP)return fm;aP=1;var e=xJ(),t=uz();function r(n,o){return n!=null&&t(n,o,e)}return fm=r,fm}var pm,sP;function wJ(){if(sP)return pm;sP=1;var e=az(),t=yJ(),r=dz(),n=k1(),o=sz(),i=lz(),a=Il(),s=1,c=2;function u(d,f){return n(d)&&o(f)?i(a(d),f):function(h){var v=t(h,d);return v===void 0&&v===f?r(h,d):e(f,v,s|c)}}return pm=u,pm}var hm,lP;function fz(){if(lP)return hm;lP=1;function e(t){return function(r){return r==null?void 0:r[t]}}return hm=e,hm}var vm,cP;function _J(){if(cP)return vm;cP=1;var e=tf();function t(r){return function(n){return e(n,r)}}return vm=t,vm}var gm,uP;function EJ(){if(uP)return gm;uP=1;var e=fz(),t=_J(),r=k1(),n=Il();function o(i){return r(i)?e(n(i)):t(i)}return gm=o,gm}var mm,dP;function So(){if(dP)return mm;dP=1;var e=hJ(),t=wJ(),r=Ti(),n=Bt(),o=EJ();function i(a){return typeof a=="function"?a:a==null?r:typeof a=="object"?n(a)?t(a[0],a[1]):e(a):o(a)}return mm=i,mm}var bm,fP;function pz(){if(fP)return bm;fP=1;var e=V5(),t=oJ(),r=So(),n=Bt();function o(i,a){var s=n(i)?e:t;return s(i,r(a,3))}return bm=o,bm}var ym,pP;function SJ(){if(pP)return ym;pP=1;var e=Object.prototype,t=e.hasOwnProperty;function r(n,o){return n!=null&&t.call(n,o)}return ym=r,ym}var xm,hP;function hz(){if(hP)return xm;hP=1;var e=SJ(),t=uz();function r(n,o){return n!=null&&t(n,o,e)}return xm=r,xm}var wm,vP;function OJ(){if(vP)return wm;vP=1;var e=O1(),t=Fa(),r=Rl(),n=Bt(),o=Eo(),i=Ba(),a=Xd(),s=Nl(),c="[object Map]",u="[object Set]",d=Object.prototype,f=d.hasOwnProperty;function h(v){if(v==null)return!0;if(o(v)&&(n(v)||typeof v=="string"||typeof v.splice=="function"||i(v)||s(v)||r(v)))return!v.length;var b=t(v);if(b==c||b==u)return!v.size;if(a(v))return!e(v).length;for(var g in v)if(f.call(v,g))return!1;return!0}return wm=h,wm}var _m,gP;function vz(){if(gP)return _m;gP=1;function e(t){return t===void 0}return _m=e,_m}var Em,mP;function gz(){if(mP)return Em;mP=1;var e=Jd(),t=Eo();function r(n,o){var i=-1,a=t(n)?Array(n.length):[];return e(n,function(s,c,u){a[++i]=o(s,c,u)}),a}return Em=r,Em}var Sm,bP;function mz(){if(bP)return Sm;bP=1;var e=Qd(),t=So(),r=gz(),n=Bt();function o(i,a){var s=n(i)?e:r;return s(i,t(a,3))}return Sm=o,Sm}var Om,yP;function CJ(){if(yP)return Om;yP=1;function e(t,r,n,o){var i=-1,a=t==null?0:t.length;for(o&&a&&(n=t[++i]);++i<a;)n=r(n,t[i],i,t);return n}return Om=e,Om}var Cm,xP;function RJ(){if(xP)return Cm;xP=1;function e(t,r,n,o,i){return i(t,function(a,s,c){n=o?(o=!1,a):r(n,a,s,c)}),n}return Cm=e,Cm}var Rm,wP;function bz(){if(wP)return Rm;wP=1;var e=CJ(),t=Jd(),r=So(),n=RJ(),o=Bt();function i(a,s,c){var u=o(a)?e:n,d=arguments.length<3;return u(a,r(s,4),c,d,t)}return Rm=i,Rm}var Nm,_P;function NJ(){if(_P)return Nm;_P=1;var e=Ni(),t=Bt(),r=eo(),n="[object String]";function o(i){return typeof i=="string"||!t(i)&&r(i)&&e(i)==n}return Nm=o,Nm}var Im,EP;function IJ(){if(EP)return Im;EP=1;var e=fz(),t=e("length");return Im=t,Im}var Pm,SP;function PJ(){if(SP)return Pm;SP=1;var e="\\ud800-\\udfff",t="\\u0300-\\u036f",r="\\ufe20-\\ufe2f",n="\\u20d0-\\u20ff",o=t+r+n,i="\\ufe0e\\ufe0f",a="\\u200d",s=RegExp("["+a+e+o+i+"]");function c(u){return s.test(u)}return Pm=c,Pm}var Tm,OP;function TJ(){if(OP)return Tm;OP=1;var e="\\ud800-\\udfff",t="\\u0300-\\u036f",r="\\ufe20-\\ufe2f",n="\\u20d0-\\u20ff",o=t+r+n,i="\\ufe0e\\ufe0f",a="["+e+"]",s="["+o+"]",c="\\ud83c[\\udffb-\\udfff]",u="(?:"+s+"|"+c+")",d="[^"+e+"]",f="(?:\\ud83c[\\udde6-\\uddff]){2}",h="[\\ud800-\\udbff][\\udc00-\\udfff]",v="\\u200d",b=u+"?",g="["+i+"]?",m="(?:"+v+"(?:"+[d,f,h].join("|")+")"+g+b+")*",x=g+b+m,w="(?:"+[d+s+"?",s,f,h,a].join("|")+")",E=RegExp(c+"(?="+c+")|"+w+x,"g");function S(_){for(var C=E.lastIndex=0;E.test(_);)++C;return C}return Tm=S,Tm}var Am,CP;function AJ(){if(CP)return Am;CP=1;var e=IJ(),t=PJ(),r=TJ();function n(o){return t(o)?r(o):e(o)}return Am=n,Am}var km,RP;function kJ(){if(RP)return km;RP=1;var e=O1(),t=Fa(),r=Eo(),n=NJ(),o=AJ(),i="[object Map]",a="[object Set]";function s(c){if(c==null)return 0;if(r(c))return n(c)?o(c):c.length;var u=t(c);return u==i||u==a?c.size:e(c).length}return km=s,km}var Dm,NP;function DJ(){if(NP)return Dm;NP=1;var e=_1(),t=Z5(),r=T1(),n=So(),o=Zd(),i=Bt(),a=Ba(),s=Ol(),c=vn(),u=Nl();function d(f,h,v){var b=i(f),g=b||a(f)||u(f);if(h=n(h,4),v==null){var m=f&&f.constructor;g?v=b?new m:[]:c(f)?v=s(m)?t(o(f)):{}:v={}}return(g?e:r)(f,function(x,w,E){return h(v,x,w,E)}),v}return Dm=d,Dm}var Mm,IP;function MJ(){if(IP)return Mm;IP=1;var e=za(),t=Rl(),r=Bt(),n=e?e.isConcatSpreadable:void 0;function o(i){return r(i)||t(i)||!!(n&&i&&i[n])}return Mm=o,Mm}var jm,PP;function D1(){if(PP)return jm;PP=1;var e=R1(),t=MJ();function r(n,o,i,a,s){var c=-1,u=n.length;for(i||(i=t),s||(s=[]);++c<u;){var d=n[c];o>0&&i(d)?o>1?r(d,o-1,i,a,s):e(s,d):a||(s[s.length]=d)}return s}return jm=r,jm}var Lm,TP;function jJ(){if(TP)return Lm;TP=1;function e(t,r,n){switch(n.length){case 0:return t.call(r);case 1:return t.call(r,n[0]);case 2:return t.call(r,n[0],n[1]);case 3:return t.call(r,n[0],n[1],n[2])}return t.apply(r,n)}return Lm=e,Lm}var qm,AP;function yz(){if(AP)return qm;AP=1;var e=jJ(),t=Math.max;function r(n,o,i){return o=t(o===void 0?n.length-1:o,0),function(){for(var a=arguments,s=-1,c=t(a.length-o,0),u=Array(c);++s<c;)u[s]=a[o+s];s=-1;for(var d=Array(o+1);++s<o;)d[s]=a[s];return d[o]=i(u),e(n,this,d)}}return qm=r,qm}var zm,kP;function LJ(){if(kP)return zm;kP=1;var e=I1(),t=q5(),r=Ti(),n=t?function(o,i){return t(o,"toString",{configurable:!0,enumerable:!1,value:e(i),writable:!0})}:r;return zm=n,zm}var Bm,DP;function qJ(){if(DP)return Bm;DP=1;var e=800,t=16,r=Date.now;function n(o){var i=0,a=0;return function(){var s=r(),c=t-(s-a);if(a=s,c>0){if(++i>=e)return arguments[0]}else i=0;return o.apply(void 0,arguments)}}return Bm=n,Bm}var Fm,MP;function xz(){if(MP)return Fm;MP=1;var e=LJ(),t=qJ(),r=t(e);return Fm=r,Fm}var $m,jP;function rf(){if(jP)return $m;jP=1;var e=Ti(),t=yz(),r=xz();function n(o,i){return r(t(o,i,e),o+"")}return $m=n,$m}var Vm,LP;function wz(){if(LP)return Vm;LP=1;function e(t,r,n,o){for(var i=t.length,a=n+(o?1:-1);o?a--:++a<i;)if(r(t[a],a,t))return a;return-1}return Vm=e,Vm}var Hm,qP;function zJ(){if(qP)return Hm;qP=1;function e(t){return t!==t}return Hm=e,Hm}var Wm,zP;function BJ(){if(zP)return Wm;zP=1;function e(t,r,n){for(var o=n-1,i=t.length;++o<i;)if(t[o]===r)return o;return-1}return Wm=e,Wm}var Um,BP;function FJ(){if(BP)return Um;BP=1;var e=wz(),t=zJ(),r=BJ();function n(o,i,a){return i===i?r(o,i,a):e(o,t,a)}return Um=n,Um}var Gm,FP;function $J(){if(FP)return Gm;FP=1;var e=FJ();function t(r,n){var o=r==null?0:r.length;return!!o&&e(r,n,0)>-1}return Gm=t,Gm}var Ym,$P;function VJ(){if($P)return Ym;$P=1;function e(t,r,n){for(var o=-1,i=t==null?0:t.length;++o<i;)if(n(r,t[o]))return!0;return!1}return Ym=e,Ym}var Km,VP;function HJ(){if(VP)return Km;VP=1;function e(){}return Km=e,Km}var Xm,HP;function WJ(){if(HP)return Xm;HP=1;var e=Y5(),t=HJ(),r=A1(),n=1/0,o=e&&1/r(new e([,-0]))[1]==n?function(i){return new e(i)}:t;return Xm=o,Xm}var Zm,WP;function UJ(){if(WP)return Zm;WP=1;var e=nz(),t=$J(),r=VJ(),n=oz(),o=WJ(),i=A1(),a=200;function s(c,u,d){var f=-1,h=t,v=c.length,b=!0,g=[],m=g;if(d)b=!1,h=r;else if(v>=a){var x=u?null:o(c);if(x)return i(x);b=!1,h=n,m=new e}else m=u?[]:g;e:for(;++f<v;){var w=c[f],E=u?u(w):w;if(w=d||w!==0?w:0,b&&E===E){for(var S=m.length;S--;)if(m[S]===E)continue e;u&&m.push(E),g.push(w)}else h(m,E,d)||(m!==g&&m.push(E),g.push(w))}return g}return Zm=s,Zm}var Jm,UP;function _z(){if(UP)return Jm;UP=1;var e=Eo(),t=eo();function r(n){return t(n)&&e(n)}return Jm=r,Jm}var Qm,GP;function GJ(){if(GP)return Qm;GP=1;var e=D1(),t=rf(),r=UJ(),n=_z(),o=t(function(i){return r(e(i,1,n,!0))});return Qm=o,Qm}var eb,YP;function YJ(){if(YP)return eb;YP=1;var e=Qd();function t(r,n){return e(n,function(o){return r[o]})}return eb=t,eb}var tb,KP;function Ez(){if(KP)return tb;KP=1;var e=YJ(),t=Jo();function r(n){return n==null?[]:e(n,t(n))}return tb=r,tb}var rb,XP;function gn(){if(XP)return rb;XP=1;var e;if(typeof y1=="function")try{e={clone:tJ(),constant:I1(),each:rz(),filter:pz(),has:hz(),isArray:Bt(),isEmpty:OJ(),isFunction:Ol(),isUndefined:vz(),keys:Jo(),map:mz(),reduce:bz(),size:kJ(),transform:DJ(),union:GJ(),values:Ez()}}catch{}return e||(e=window._),rb=e,rb}var nb,ZP;function M1(){if(ZP)return nb;ZP=1;var e=gn();nb=o;var t="\0",r="\0",n="";function o(d){this._isDirected=e.has(d,"directed")?d.directed:!0,this._isMultigraph=e.has(d,"multigraph")?d.multigraph:!1,this._isCompound=e.has(d,"compound")?d.compound:!1,this._label=void 0,this._defaultNodeLabelFn=e.constant(void 0),this._defaultEdgeLabelFn=e.constant(void 0),this._nodes={},this._isCompound&&(this._parent={},this._children={},this._children[r]={}),this._in={},this._preds={},this._out={},this._sucs={},this._edgeObjs={},this._edgeLabels={}}o.prototype._nodeCount=0,o.prototype._edgeCount=0,o.prototype.isDirected=function(){return this._isDirected},o.prototype.isMultigraph=function(){return this._isMultigraph},o.prototype.isCompound=function(){return this._isCompound},o.prototype.setGraph=function(d){return this._label=d,this},o.prototype.graph=function(){return this._label},o.prototype.setDefaultNodeLabel=function(d){return e.isFunction(d)||(d=e.constant(d)),this._defaultNodeLabelFn=d,this},o.prototype.nodeCount=function(){return this._nodeCount},o.prototype.nodes=function(){return e.keys(this._nodes)},o.prototype.sources=function(){var d=this;return e.filter(this.nodes(),function(f){return e.isEmpty(d._in[f])})},o.prototype.sinks=function(){var d=this;return e.filter(this.nodes(),function(f){return e.isEmpty(d._out[f])})},o.prototype.setNodes=function(d,f){var h=arguments,v=this;return e.each(d,function(b){h.length>1?v.setNode(b,f):v.setNode(b)}),this},o.prototype.setNode=function(d,f){return e.has(this._nodes,d)?(arguments.length>1&&(this._nodes[d]=f),this):(this._nodes[d]=arguments.length>1?f:this._defaultNodeLabelFn(d),this._isCompound&&(this._parent[d]=r,this._children[d]={},this._children[r][d]=!0),this._in[d]={},this._preds[d]={},this._out[d]={},this._sucs[d]={},++this._nodeCount,this)},o.prototype.node=function(d){return this._nodes[d]},o.prototype.hasNode=function(d){return e.has(this._nodes,d)},o.prototype.removeNode=function(d){var f=this;if(e.has(this._nodes,d)){var h=function(v){f.removeEdge(f._edgeObjs[v])};delete this._nodes[d],this._isCompound&&(this._removeFromParentsChildList(d),delete this._parent[d],e.each(this.children(d),function(v){f.setParent(v)}),delete this._children[d]),e.each(e.keys(this._in[d]),h),delete this._in[d],delete this._preds[d],e.each(e.keys(this._out[d]),h),delete this._out[d],delete this._sucs[d],--this._nodeCount}return this},o.prototype.setParent=function(d,f){if(!this._isCompound)throw new Error("Cannot set parent in a non-compound graph");if(e.isUndefined(f))f=r;else{f+="";for(var h=f;!e.isUndefined(h);h=this.parent(h))if(h===d)throw new Error("Setting "+f+" as parent of "+d+" would create a cycle");this.setNode(f)}return this.setNode(d),this._removeFromParentsChildList(d),this._parent[d]=f,this._children[f][d]=!0,this},o.prototype._removeFromParentsChildList=function(d){delete this._children[this._parent[d]][d]},o.prototype.parent=function(d){if(this._isCompound){var f=this._parent[d];if(f!==r)return f}},o.prototype.children=function(d){if(e.isUndefined(d)&&(d=r),this._isCompound){var f=this._children[d];if(f)return e.keys(f)}else{if(d===r)return this.nodes();if(this.hasNode(d))return[]}},o.prototype.predecessors=function(d){var f=this._preds[d];if(f)return e.keys(f)},o.prototype.successors=function(d){var f=this._sucs[d];if(f)return e.keys(f)},o.prototype.neighbors=function(d){var f=this.predecessors(d);if(f)return e.union(f,this.successors(d))},o.prototype.isLeaf=function(d){var f;return this.isDirected()?f=this.successors(d):f=this.neighbors(d),f.length===0},o.prototype.filterNodes=function(d){var f=new this.constructor({directed:this._isDirected,multigraph:this._isMultigraph,compound:this._isCompound});f.setGraph(this.graph());var h=this;e.each(this._nodes,function(g,m){d(m)&&f.setNode(m,g)}),e.each(this._edgeObjs,function(g){f.hasNode(g.v)&&f.hasNode(g.w)&&f.setEdge(g,h.edge(g))});var v={};function b(g){var m=h.parent(g);return m===void 0||f.hasNode(m)?(v[g]=m,m):m in v?v[m]:b(m)}return this._isCompound&&e.each(f.nodes(),function(g){f.setParent(g,b(g))}),f},o.prototype.setDefaultEdgeLabel=function(d){return e.isFunction(d)||(d=e.constant(d)),this._defaultEdgeLabelFn=d,this},o.prototype.edgeCount=function(){return this._edgeCount},o.prototype.edges=function(){return e.values(this._edgeObjs)},o.prototype.setPath=function(d,f){var h=this,v=arguments;return e.reduce(d,function(b,g){return v.length>1?h.setEdge(b,g,f):h.setEdge(b,g),g}),this},o.prototype.setEdge=function(){var d,f,h,v,b=!1,g=arguments[0];typeof g=="object"&&g!==null&&"v"in g?(d=g.v,f=g.w,h=g.name,arguments.length===2&&(v=arguments[1],b=!0)):(d=g,f=arguments[1],h=arguments[3],arguments.length>2&&(v=arguments[2],b=!0)),d=""+d,f=""+f,e.isUndefined(h)||(h=""+h);var m=s(this._isDirected,d,f,h);if(e.has(this._edgeLabels,m))return b&&(this._edgeLabels[m]=v),this;if(!e.isUndefined(h)&&!this._isMultigraph)throw new Error("Cannot set a named edge when isMultigraph = false");this.setNode(d),this.setNode(f),this._edgeLabels[m]=b?v:this._defaultEdgeLabelFn(d,f,h);var x=c(this._isDirected,d,f,h);return d=x.v,f=x.w,Object.freeze(x),this._edgeObjs[m]=x,i(this._preds[f],d),i(this._sucs[d],f),this._in[f][m]=x,this._out[d][m]=x,this._edgeCount++,this},o.prototype.edge=function(d,f,h){var v=arguments.length===1?u(this._isDirected,arguments[0]):s(this._isDirected,d,f,h);return this._edgeLabels[v]},o.prototype.hasEdge=function(d,f,h){var v=arguments.length===1?u(this._isDirected,arguments[0]):s(this._isDirected,d,f,h);return e.has(this._edgeLabels,v)},o.prototype.removeEdge=function(d,f,h){var v=arguments.length===1?u(this._isDirected,arguments[0]):s(this._isDirected,d,f,h),b=this._edgeObjs[v];return b&&(d=b.v,f=b.w,delete this._edgeLabels[v],delete this._edgeObjs[v],a(this._preds[f],d),a(this._sucs[d],f),delete this._in[f][v],delete this._out[d][v],this._edgeCount--),this},o.prototype.inEdges=function(d,f){var h=this._in[d];if(h){var v=e.values(h);return f?e.filter(v,function(b){return b.v===f}):v}},o.prototype.outEdges=function(d,f){var h=this._out[d];if(h){var v=e.values(h);return f?e.filter(v,function(b){return b.w===f}):v}},o.prototype.nodeEdges=function(d,f){var h=this.inEdges(d,f);if(h)return h.concat(this.outEdges(d,f))};function i(d,f){d[f]?d[f]++:d[f]=1}function a(d,f){--d[f]||delete d[f]}function s(d,f,h,v){var b=""+f,g=""+h;if(!d&&b>g){var m=b;b=g,g=m}return b+n+g+n+(e.isUndefined(v)?t:v)}function c(d,f,h,v){var b=""+f,g=""+h;if(!d&&b>g){var m=b;b=g,g=m}var x={v:b,w:g};return v&&(x.name=v),x}function u(d,f){return s(d,f.v,f.w,f.name)}return nb}var ob,JP;function KJ(){return JP||(JP=1,ob="2.1.8"),ob}var ib,QP;function XJ(){return QP||(QP=1,ib={Graph:M1(),version:KJ()}),ib}var ab,eT;function ZJ(){if(eT)return ab;eT=1;var e=gn(),t=M1();ab={write:r,read:i};function r(a){var s={options:{directed:a.isDirected(),multigraph:a.isMultigraph(),compound:a.isCompound()},nodes:n(a),edges:o(a)};return e.isUndefined(a.graph())||(s.value=e.clone(a.graph())),s}function n(a){return e.map(a.nodes(),function(s){var c=a.node(s),u=a.parent(s),d={v:s};return e.isUndefined(c)||(d.value=c),e.isUndefined(u)||(d.parent=u),d})}function o(a){return e.map(a.edges(),function(s){var c=a.edge(s),u={v:s.v,w:s.w};return e.isUndefined(s.name)||(u.name=s.name),e.isUndefined(c)||(u.value=c),u})}function i(a){var s=new t(a.options).setGraph(a.value);return e.each(a.nodes,function(c){s.setNode(c.v,c.value),c.parent&&s.setParent(c.v,c.parent)}),e.each(a.edges,function(c){s.setEdge({v:c.v,w:c.w,name:c.name},c.value)}),s}return ab}var sb,tT;function JJ(){if(tT)return sb;tT=1;var e=gn();sb=t;function t(r){var n={},o=[],i;function a(s){e.has(n,s)||(n[s]=!0,i.push(s),e.each(r.successors(s),a),e.each(r.predecessors(s),a))}return e.each(r.nodes(),function(s){i=[],a(s),i.length&&o.push(i)}),o}return sb}var lb,rT;function Sz(){if(rT)return lb;rT=1;var e=gn();lb=t;function t(){this._arr=[],this._keyIndices={}}return t.prototype.size=function(){return this._arr.length},t.prototype.keys=function(){return this._arr.map(function(r){return r.key})},t.prototype.has=function(r){return e.has(this._keyIndices,r)},t.prototype.priority=function(r){var n=this._keyIndices[r];if(n!==void 0)return this._arr[n].priority},t.prototype.min=function(){if(this.size()===0)throw new Error("Queue underflow");return this._arr[0].key},t.prototype.add=function(r,n){var o=this._keyIndices;if(r=String(r),!e.has(o,r)){var i=this._arr,a=i.length;return o[r]=a,i.push({key:r,priority:n}),this._decrease(a),!0}return!1},t.prototype.removeMin=function(){this._swap(0,this._arr.length-1);var r=this._arr.pop();return delete this._keyIndices[r.key],this._heapify(0),r.key},t.prototype.decrease=function(r,n){var o=this._keyIndices[r];if(n>this._arr[o].priority)throw new Error("New priority is greater than current priority. Key: "+r+" Old: "+this._arr[o].priority+" New: "+n);this._arr[o].priority=n,this._decrease(o)},t.prototype._heapify=function(r){var n=this._arr,o=2*r,i=o+1,a=r;o<n.length&&(a=n[o].priority<n[a].priority?o:a,i<n.length&&(a=n[i].priority<n[a].priority?i:a),a!==r&&(this._swap(r,a),this._heapify(a)))},t.prototype._decrease=function(r){for(var n=this._arr,o=n[r].priority,i;r!==0&&(i=r>>1,!(n[i].priority<o));)this._swap(r,i),r=i},t.prototype._swap=function(r,n){var o=this._arr,i=this._keyIndices,a=o[r],s=o[n];o[r]=s,o[n]=a,i[s.key]=r,i[a.key]=n},lb}var cb,nT;function Oz(){if(nT)return cb;nT=1;var e=gn(),t=Sz();cb=n;var r=e.constant(1);function n(i,a,s,c){return o(i,String(a),s||r,c||function(u){return i.outEdges(u)})}function o(i,a,s,c){var u={},d=new t,f,h,v=function(b){var g=b.v!==f?b.v:b.w,m=u[g],x=s(b),w=h.distance+x;if(x<0)throw new Error("dijkstra does not allow negative edge weights. Bad edge: "+b+" Weight: "+x);w<m.distance&&(m.distance=w,m.predecessor=f,d.decrease(g,w))};for(i.nodes().forEach(function(b){var g=b===a?0:Number.POSITIVE_INFINITY;u[b]={distance:g},d.add(b,g)});d.size()>0&&(f=d.removeMin(),h=u[f],h.distance!==Number.POSITIVE_INFINITY);)c(f).forEach(v);return u}return cb}var ub,oT;function QJ(){if(oT)return ub;oT=1;var e=Oz(),t=gn();ub=r;function r(n,o,i){return t.transform(n.nodes(),function(a,s){a[s]=e(n,s,o,i)},{})}return ub}var db,iT;function Cz(){if(iT)return db;iT=1;var e=gn();db=t;function t(r){var n=0,o=[],i={},a=[];function s(c){var u=i[c]={onStack:!0,lowlink:n,index:n++};if(o.push(c),r.successors(c).forEach(function(h){e.has(i,h)?i[h].onStack&&(u.lowlink=Math.min(u.lowlink,i[h].index)):(s(h),u.lowlink=Math.min(u.lowlink,i[h].lowlink))}),u.lowlink===u.index){var d=[],f;do f=o.pop(),i[f].onStack=!1,d.push(f);while(c!==f);a.push(d)}}return r.nodes().forEach(function(c){e.has(i,c)||s(c)}),a}return db}var fb,aT;function eQ(){if(aT)return fb;aT=1;var e=gn(),t=Cz();fb=r;function r(n){return e.filter(t(n),function(o){return o.length>1||o.length===1&&n.hasEdge(o[0],o[0])})}return fb}var pb,sT;function tQ(){if(sT)return pb;sT=1;var e=gn();pb=r;var t=e.constant(1);function r(o,i,a){return n(o,i||t,a||function(s){return o.outEdges(s)})}function n(o,i,a){var s={},c=o.nodes();return c.forEach(function(u){s[u]={},s[u][u]={distance:0},c.forEach(function(d){u!==d&&(s[u][d]={distance:Number.POSITIVE_INFINITY})}),a(u).forEach(function(d){var f=d.v===u?d.w:d.v,h=i(d);s[u][f]={distance:h,predecessor:u}})}),c.forEach(function(u){var d=s[u];c.forEach(function(f){var h=s[f];c.forEach(function(v){var b=h[u],g=d[v],m=h[v],x=b.distance+g.distance;x<m.distance&&(m.distance=x,m.predecessor=g.predecessor)})})}),s}return pb}var hb,lT;function Rz(){if(lT)return hb;lT=1;var e=gn();hb=t,t.CycleException=r;function t(n){var o={},i={},a=[];function s(c){if(e.has(i,c))throw new r;e.has(o,c)||(i[c]=!0,o[c]=!0,e.each(n.predecessors(c),s),delete i[c],a.push(c))}if(e.each(n.sinks(),s),e.size(o)!==n.nodeCount())throw new r;return a}function r(){}return r.prototype=new Error,hb}var vb,cT;function rQ(){if(cT)return vb;cT=1;var e=Rz();vb=t;function t(r){try{e(r)}catch(n){if(n instanceof e.CycleException)return!1;throw n}return!0}return vb}var gb,uT;function Nz(){if(uT)return gb;uT=1;var e=gn();gb=t;function t(n,o,i){e.isArray(o)||(o=[o]);var a=(n.isDirected()?n.successors:n.neighbors).bind(n),s=[],c={};return e.each(o,function(u){if(!n.hasNode(u))throw new Error("Graph does not have node: "+u);r(n,u,i==="post",c,a,s)}),s}function r(n,o,i,a,s,c){e.has(a,o)||(a[o]=!0,i||c.push(o),e.each(s(o),function(u){r(n,u,i,a,s,c)}),i&&c.push(o))}return gb}var mb,dT;function nQ(){if(dT)return mb;dT=1;var e=Nz();mb=t;function t(r,n){return e(r,n,"post")}return mb}var bb,fT;function oQ(){if(fT)return bb;fT=1;var e=Nz();bb=t;function t(r,n){return e(r,n,"pre")}return bb}var yb,pT;function iQ(){if(pT)return yb;pT=1;var e=gn(),t=M1(),r=Sz();yb=n;function n(o,i){var a=new t,s={},c=new r,u;function d(h){var v=h.v===u?h.w:h.v,b=c.priority(v);if(b!==void 0){var g=i(h);g<b&&(s[v]=u,c.decrease(v,g))}}if(o.nodeCount()===0)return a;e.each(o.nodes(),function(h){c.add(h,Number.POSITIVE_INFINITY),a.setNode(h)}),c.decrease(o.nodes()[0],0);for(var f=!1;c.size()>0;){if(u=c.removeMin(),e.has(s,u))a.setEdge(u,s[u]);else{if(f)throw new Error("Input graph is not connected: "+o);f=!0}o.nodeEdges(u).forEach(d)}return a}return yb}var xb,hT;function aQ(){return hT||(hT=1,xb={components:JJ(),dijkstra:Oz(),dijkstraAll:QJ(),findCycles:eQ(),floydWarshall:tQ(),isAcyclic:rQ(),postorder:nQ(),preorder:oQ(),prim:iQ(),tarjan:Cz(),topsort:Rz()}),xb}var wb,vT;function sQ(){if(vT)return wb;vT=1;var e=XJ();return wb={Graph:e.Graph,json:ZJ(),alg:aQ(),version:e.version},wb}var _b,gT;function Tn(){if(gT)return _b;gT=1;var e;if(typeof y1=="function")try{e=sQ()}catch{}return e||(e=window.graphlib),_b=e,_b}var Eb,mT;function lQ(){if(mT)return Eb;mT=1;var e=Q5(),t=1,r=4;function n(o){return e(o,t|r)}return Eb=n,Eb}var Sb,bT;function nf(){if(bT)return Sb;bT=1;var e=qa(),t=Eo(),r=Yd(),n=vn();function o(i,a,s){if(!n(s))return!1;var c=typeof a;return(c=="number"?t(s)&&r(a,s.length):c=="string"&&a in s)?e(s[a],i):!1}return Sb=o,Sb}var Ob,yT;function cQ(){if(yT)return Ob;yT=1;var e=rf(),t=qa(),r=nf(),n=Pi(),o=Object.prototype,i=o.hasOwnProperty,a=e(function(s,c){s=Object(s);var u=-1,d=c.length,f=d>2?c[2]:void 0;for(f&&r(c[0],c[1],f)&&(d=1);++u<d;)for(var h=c[u],v=n(h),b=-1,g=v.length;++b<g;){var m=v[b],x=s[m];(x===void 0||t(x,o[m])&&!i.call(s,m))&&(s[m]=h[m])}return s});return Ob=a,Ob}var Cb,xT;function uQ(){if(xT)return Cb;xT=1;var e=So(),t=Eo(),r=Jo();function n(o){return function(i,a,s){var c=Object(i);if(!t(i)){var u=e(a,3);i=r(i),a=function(f){return u(c[f],f,c)}}var d=o(i,a,s);return d>-1?c[u?i[d]:d]:void 0}}return Cb=n,Cb}var Rb,wT;function dQ(){if(wT)return Rb;wT=1;var e=/\s/;function t(r){for(var n=r.length;n--&&e.test(r.charAt(n)););return n}return Rb=t,Rb}var Nb,_T;function fQ(){if(_T)return Nb;_T=1;var e=dQ(),t=/^\s+/;function r(n){return n&&n.slice(0,e(n)+1).replace(t,"")}return Nb=r,Nb}var Ib,ET;function pQ(){if(ET)return Ib;ET=1;var e=fQ(),t=vn(),r=$a(),n=NaN,o=/^[-+]0x[0-9a-f]+$/i,i=/^0b[01]+$/i,a=/^0o[0-7]+$/i,s=parseInt;function c(u){if(typeof u=="number")return u;if(r(u))return n;if(t(u)){var d=typeof u.valueOf=="function"?u.valueOf():u;u=t(d)?d+"":d}if(typeof u!="string")return u===0?u:+u;u=e(u);var f=i.test(u);return f||a.test(u)?s(u.slice(2),f?2:8):o.test(u)?n:+u}return Ib=c,Ib}var Pb,ST;function Iz(){if(ST)return Pb;ST=1;var e=pQ(),t=1/0,r=17976931348623157e292;function n(o){if(!o)return o===0?o:0;if(o=e(o),o===t||o===-t){var i=o<0?-1:1;return i*r}return o===o?o:0}return Pb=n,Pb}var Tb,OT;function hQ(){if(OT)return Tb;OT=1;var e=Iz();function t(r){var n=e(r),o=n%1;return n===n?o?n-o:n:0}return Tb=t,Tb}var Ab,CT;function vQ(){if(CT)return Ab;CT=1;var e=wz(),t=So(),r=hQ(),n=Math.max;function o(i,a,s){var c=i==null?0:i.length;if(!c)return-1;var u=s==null?0:r(s);return u<0&&(u=n(c+u,0)),e(i,t(a,3),u)}return Ab=o,Ab}var kb,RT;function gQ(){if(RT)return kb;RT=1;var e=uQ(),t=vQ(),r=e(t);return kb=r,kb}var Db,NT;function Pz(){if(NT)return Db;NT=1;var e=D1();function t(r){var n=r==null?0:r.length;return n?e(r,1):[]}return Db=t,Db}var Mb,IT;function mQ(){if(IT)return Mb;IT=1;var e=P1(),t=ez(),r=Pi();function n(o,i){return o==null?o:e(o,t(i),r)}return Mb=n,Mb}var jb,PT;function bQ(){if(PT)return jb;PT=1;function e(t){var r=t==null?0:t.length;return r?t[r-1]:void 0}return jb=e,jb}var Lb,TT;function yQ(){if(TT)return Lb;TT=1;var e=Ud(),t=T1(),r=So();function n(o,i){var a={};return i=r(i,3),t(o,function(s,c,u){e(a,c,i(s,c,u))}),a}return Lb=n,Lb}var qb,AT;function j1(){if(AT)return qb;AT=1;var e=$a();function t(r,n,o){for(var i=-1,a=r.length;++i<a;){var s=r[i],c=n(s);if(c!=null&&(u===void 0?c===c&&!e(c):o(c,u)))var u=c,d=s}return d}return qb=t,qb}var zb,kT;function xQ(){if(kT)return zb;kT=1;function e(t,r){return t>r}return zb=e,zb}var Bb,DT;function wQ(){if(DT)return Bb;DT=1;var e=j1(),t=xQ(),r=Ti();function n(o){return o&&o.length?e(o,r,t):void 0}return Bb=n,Bb}var Fb,MT;function Tz(){if(MT)return Fb;MT=1;var e=Ud(),t=qa();function r(n,o,i){(i!==void 0&&!t(n[o],i)||i===void 0&&!(o in n))&&e(n,o,i)}return Fb=r,Fb}var $b,jT;function _Q(){if(jT)return $b;jT=1;var e=Ni(),t=Zd(),r=eo(),n="[object Object]",o=Function.prototype,i=Object.prototype,a=o.toString,s=i.hasOwnProperty,c=a.call(Object);function u(d){if(!r(d)||e(d)!=n)return!1;var f=t(d);if(f===null)return!0;var h=s.call(f,"constructor")&&f.constructor;return typeof h=="function"&&h instanceof h&&a.call(h)==c}return $b=u,$b}var Vb,LT;function Az(){if(LT)return Vb;LT=1;function e(t,r){if(!(r==="constructor"&&typeof t[r]=="function")&&r!="__proto__")return t[r]}return Vb=e,Vb}var Hb,qT;function EQ(){if(qT)return Hb;qT=1;var e=Cl(),t=Pi();function r(n){return e(n,t(n))}return Hb=r,Hb}var Wb,zT;function SQ(){if(zT)return Wb;zT=1;var e=Tz(),t=F5(),r=X5(),n=$5(),o=J5(),i=Rl(),a=Bt(),s=_z(),c=Ba(),u=Ol(),d=vn(),f=_Q(),h=Nl(),v=Az(),b=EQ();function g(m,x,w,E,S,_,C){var N=v(m,w),P=v(x,w),A=C.get(P);if(A){e(m,w,A);return}var j=_?_(N,P,w+"",m,x,C):void 0,M=j===void 0;if(M){var L=a(P),D=!L&&c(P),T=!L&&!D&&h(P);j=P,L||D||T?a(N)?j=N:s(N)?j=n(N):D?(M=!1,j=t(P,!0)):T?(M=!1,j=r(P,!0)):j=[]:f(P)||i(P)?(j=N,i(N)?j=b(N):(!d(N)||u(N))&&(j=o(P))):M=!1}M&&(C.set(P,j),S(j,P,E,_,C),C.delete(P)),e(m,w,j)}return Wb=g,Wb}var Ub,BT;function OQ(){if(BT)return Ub;BT=1;var e=Wd(),t=Tz(),r=P1(),n=SQ(),o=vn(),i=Pi(),a=Az();function s(c,u,d,f,h){c!==u&&r(u,function(v,b){if(h||(h=new e),o(v))n(c,u,b,d,s,f,h);else{var g=f?f(a(c,b),v,b+"",c,u,h):void 0;g===void 0&&(g=v),t(c,b,g)}},i)}return Ub=s,Ub}var Gb,FT;function CQ(){if(FT)return Gb;FT=1;var e=rf(),t=nf();function r(n){return e(function(o,i){var a=-1,s=i.length,c=s>1?i[s-1]:void 0,u=s>2?i[2]:void 0;for(c=n.length>3&&typeof c=="function"?(s--,c):void 0,u&&t(i[0],i[1],u)&&(c=s<3?void 0:c,s=1),o=Object(o);++a<s;){var d=i[a];d&&n(o,d,a,c)}return o})}return Gb=r,Gb}var Yb,$T;function RQ(){if($T)return Yb;$T=1;var e=OQ(),t=CQ(),r=t(function(n,o,i){e(n,o,i)});return Yb=r,Yb}var Kb,VT;function kz(){if(VT)return Kb;VT=1;function e(t,r){return t<r}return Kb=e,Kb}var Xb,HT;function NQ(){if(HT)return Xb;HT=1;var e=j1(),t=kz(),r=Ti();function n(o){return o&&o.length?e(o,r,t):void 0}return Xb=n,Xb}var Zb,WT;function IQ(){if(WT)return Zb;WT=1;var e=j1(),t=So(),r=kz();function n(o,i){return o&&o.length?e(o,t(i,2),r):void 0}return Zb=n,Zb}var Jb,UT;function PQ(){if(UT)return Jb;UT=1;var e=Dn(),t=function(){return e.Date.now()};return Jb=t,Jb}var Qb,GT;function TQ(){if(GT)return Qb;GT=1;var e=Gd(),t=ef(),r=Yd(),n=vn(),o=Il();function i(a,s,c,u){if(!n(a))return a;s=t(s,a);for(var d=-1,f=s.length,h=f-1,v=a;v!=null&&++d<f;){var b=o(s[d]),g=c;if(b==="__proto__"||b==="constructor"||b==="prototype")return a;if(d!=h){var m=v[b];g=u?u(m,b,v):void 0,g===void 0&&(g=n(m)?m:r(s[d+1])?[]:{})}e(v,b,g),v=v[b]}return a}return Qb=i,Qb}var ey,YT;function AQ(){if(YT)return ey;YT=1;var e=tf(),t=TQ(),r=ef();function n(o,i,a){for(var s=-1,c=i.length,u={};++s<c;){var d=i[s],f=e(o,d);a(f,d)&&t(u,r(d,o),f)}return u}return ey=n,ey}var ty,KT;function kQ(){if(KT)return ty;KT=1;var e=AQ(),t=dz();function r(n,o){return e(n,o,function(i,a){return t(n,a)})}return ty=r,ty}var ry,XT;function DQ(){if(XT)return ry;XT=1;var e=Pz(),t=yz(),r=xz();function n(o){return r(t(o,void 0,e),o+"")}return ry=n,ry}var ny,ZT;function MQ(){if(ZT)return ny;ZT=1;var e=kQ(),t=DQ(),r=t(function(n,o){return n==null?{}:e(n,o)});return ny=r,ny}var oy,JT;function jQ(){if(JT)return oy;JT=1;var e=Math.ceil,t=Math.max;function r(n,o,i,a){for(var s=-1,c=t(e((o-n)/(i||1)),0),u=Array(c);c--;)u[a?c:++s]=n,n+=i;return u}return oy=r,oy}var iy,QT;function LQ(){if(QT)return iy;QT=1;var e=jQ(),t=nf(),r=Iz();function n(o){return function(i,a,s){return s&&typeof s!="number"&&t(i,a,s)&&(a=s=void 0),i=r(i),a===void 0?(a=i,i=0):a=r(a),s=s===void 0?i<a?1:-1:r(s),e(i,a,s,o)}}return iy=n,iy}var ay,eA;function qQ(){if(eA)return ay;eA=1;var e=LQ(),t=e();return ay=t,ay}var sy,tA;function zQ(){if(tA)return sy;tA=1;function e(t,r){var n=t.length;for(t.sort(r);n--;)t[n]=t[n].value;return t}return sy=e,sy}var ly,rA;function BQ(){if(rA)return ly;rA=1;var e=$a();function t(r,n){if(r!==n){var o=r!==void 0,i=r===null,a=r===r,s=e(r),c=n!==void 0,u=n===null,d=n===n,f=e(n);if(!u&&!f&&!s&&r>n||s&&c&&d&&!u&&!f||i&&c&&d||!o&&d||!a)return 1;if(!i&&!s&&!f&&r<n||f&&o&&a&&!i&&!s||u&&o&&a||!c&&a||!d)return-1}return 0}return ly=t,ly}var cy,nA;function FQ(){if(nA)return cy;nA=1;var e=BQ();function t(r,n,o){for(var i=-1,a=r.criteria,s=n.criteria,c=a.length,u=o.length;++i<c;){var d=e(a[i],s[i]);if(d){if(i>=u)return d;var f=o[i];return d*(f=="desc"?-1:1)}}return r.index-n.index}return cy=t,cy}var uy,oA;function $Q(){if(oA)return uy;oA=1;var e=Qd(),t=tf(),r=So(),n=gz(),o=zQ(),i=Kd(),a=FQ(),s=Ti(),c=Bt();function u(d,f,h){f.length?f=e(f,function(g){return c(g)?function(m){return t(m,g.length===1?g[0]:g)}:g}):f=[s];var v=-1;f=e(f,i(r));var b=n(d,function(g,m,x){var w=e(f,function(E){return E(g)});return{criteria:w,index:++v,value:g}});return o(b,function(g,m){return a(g,m,h)})}return uy=u,uy}var dy,iA;function VQ(){if(iA)return dy;iA=1;var e=D1(),t=$Q(),r=rf(),n=nf(),o=r(function(i,a){if(i==null)return[];var s=a.length;return s>1&&n(i,a[0],a[1])?a=[]:s>2&&n(a[0],a[1],a[2])&&(a=[a[0]]),t(i,e(a,1),[])});return dy=o,dy}var fy,aA;function HQ(){if(aA)return fy;aA=1;var e=cz(),t=0;function r(n){var o=++t;return e(n)+o}return fy=r,fy}var py,sA;function WQ(){if(sA)return py;sA=1;function e(t,r,n){for(var o=-1,i=t.length,a=r.length,s={};++o<i;){var c=o<a?r[o]:void 0;n(s,t[o],c)}return s}return py=e,py}var hy,lA;function UQ(){if(lA)return hy;lA=1;var e=Gd(),t=WQ();function r(n,o){return t(n||[],o||[],e)}return hy=r,hy}var vy,cA;function Ct(){if(cA)return vy;cA=1;var e;if(typeof y1=="function")try{e={cloneDeep:lQ(),constant:I1(),defaults:cQ(),each:rz(),filter:pz(),find:gQ(),flatten:Pz(),forEach:tz(),forIn:mQ(),has:hz(),isUndefined:vz(),last:bQ(),map:mz(),mapValues:yQ(),max:wQ(),merge:RQ(),min:NQ(),minBy:IQ(),now:PQ(),pick:MQ(),range:qQ(),reduce:bz(),sortBy:VQ(),uniqueId:HQ(),values:Ez(),zipObject:UQ()}}catch{}return e||(e=window._),vy=e,vy}var gy,uA;function GQ(){if(uA)return gy;uA=1,gy=e;function e(){var n={};n._next=n._prev=n,this._sentinel=n}e.prototype.dequeue=function(){var n=this._sentinel,o=n._prev;if(o!==n)return t(o),o},e.prototype.enqueue=function(n){var o=this._sentinel;n._prev&&n._next&&t(n),n._next=o._next,o._next._prev=n,o._next=n,n._prev=o},e.prototype.toString=function(){for(var n=[],o=this._sentinel,i=o._prev;i!==o;)n.push(JSON.stringify(i,r)),i=i._prev;return"["+n.join(", ")+"]"};function t(n){n._prev._next=n._next,n._next._prev=n._prev,delete n._next,delete n._prev}function r(n,o){if(n!=="_next"&&n!=="_prev")return o}return gy}var my,dA;function YQ(){if(dA)return my;dA=1;var e=Ct(),t=Tn().Graph,r=GQ();my=o;var n=e.constant(1);function o(u,d){if(u.nodeCount()<=1)return[];var f=s(u,d||n),h=i(f.graph,f.buckets,f.zeroIdx);return e.flatten(e.map(h,function(v){return u.outEdges(v.v,v.w)}),!0)}function i(u,d,f){for(var h=[],v=d[d.length-1],b=d[0],g;u.nodeCount();){for(;g=b.dequeue();)a(u,d,f,g);for(;g=v.dequeue();)a(u,d,f,g);if(u.nodeCount()){for(var m=d.length-2;m>0;--m)if(g=d[m].dequeue(),g){h=h.concat(a(u,d,f,g,!0));break}}}return h}function a(u,d,f,h,v){var b=v?[]:void 0;return e.forEach(u.inEdges(h.v),function(g){var m=u.edge(g),x=u.node(g.v);v&&b.push({v:g.v,w:g.w}),x.out-=m,c(d,f,x)}),e.forEach(u.outEdges(h.v),function(g){var m=u.edge(g),x=g.w,w=u.node(x);w.in-=m,c(d,f,w)}),u.removeNode(h.v),b}function s(u,d){var f=new t,h=0,v=0;e.forEach(u.nodes(),function(m){f.setNode(m,{v:m,in:0,out:0})}),e.forEach(u.edges(),function(m){var x=f.edge(m.v,m.w)||0,w=d(m),E=x+w;f.setEdge(m.v,m.w,E),v=Math.max(v,f.node(m.v).out+=w),h=Math.max(h,f.node(m.w).in+=w)});var b=e.range(v+h+3).map(function(){return new r}),g=h+1;return e.forEach(f.nodes(),function(m){c(b,g,f.node(m))}),{graph:f,buckets:b,zeroIdx:g}}function c(u,d,f){f.out?f.in?u[f.out-f.in+d].enqueue(f):u[u.length-1].enqueue(f):u[0].enqueue(f)}return my}var by,fA;function KQ(){if(fA)return by;fA=1;var e=Ct(),t=YQ();by={run:r,undo:o};function r(i){var a=i.graph().acyclicer==="greedy"?t(i,s(i)):n(i);e.forEach(a,function(c){var u=i.edge(c);i.removeEdge(c),u.forwardName=c.name,u.reversed=!0,i.setEdge(c.w,c.v,u,e.uniqueId("rev"))});function s(c){return function(u){return c.edge(u).weight}}}function n(i){var a=[],s={},c={};function u(d){e.has(c,d)||(c[d]=!0,s[d]=!0,e.forEach(i.outEdges(d),function(f){e.has(s,f.w)?a.push(f):u(f.w)}),delete s[d])}return e.forEach(i.nodes(),u),a}function o(i){e.forEach(i.edges(),function(a){var s=i.edge(a);if(s.reversed){i.removeEdge(a);var c=s.forwardName;delete s.reversed,delete s.forwardName,i.setEdge(a.w,a.v,s,c)}})}return by}var yy,pA;function kr(){if(pA)return yy;pA=1;var e=Ct(),t=Tn().Graph;yy={addDummyNode:r,simplify:n,asNonCompoundGraph:o,successorWeights:i,predecessorWeights:a,intersectRect:s,buildLayerMatrix:c,normalizeRanks:u,removeEmptyRanks:d,addBorderNode:f,maxRank:h,partition:v,time:b,notime:g};function r(m,x,w,E){var S;do S=e.uniqueId(E);while(m.hasNode(S));return w.dummy=x,m.setNode(S,w),S}function n(m){var x=new t().setGraph(m.graph());return e.forEach(m.nodes(),function(w){x.setNode(w,m.node(w))}),e.forEach(m.edges(),function(w){var E=x.edge(w.v,w.w)||{weight:0,minlen:1},S=m.edge(w);x.setEdge(w.v,w.w,{weight:E.weight+S.weight,minlen:Math.max(E.minlen,S.minlen)})}),x}function o(m){var x=new t({multigraph:m.isMultigraph()}).setGraph(m.graph());return e.forEach(m.nodes(),function(w){m.children(w).length||x.setNode(w,m.node(w))}),e.forEach(m.edges(),function(w){x.setEdge(w,m.edge(w))}),x}function i(m){var x=e.map(m.nodes(),function(w){var E={};return e.forEach(m.outEdges(w),function(S){E[S.w]=(E[S.w]||0)+m.edge(S).weight}),E});return e.zipObject(m.nodes(),x)}function a(m){var x=e.map(m.nodes(),function(w){var E={};return e.forEach(m.inEdges(w),function(S){E[S.v]=(E[S.v]||0)+m.edge(S).weight}),E});return e.zipObject(m.nodes(),x)}function s(m,x){var w=m.x,E=m.y,S=x.x-w,_=x.y-E,C=m.width/2,N=m.height/2;if(!S&&!_)throw new Error("Not possible to find intersection inside of the rectangle");var P,A;return Math.abs(_)*C>Math.abs(S)*N?(_<0&&(N=-N),P=N*S/_,A=N):(S<0&&(C=-C),P=C,A=C*_/S),{x:w+P,y:E+A}}function c(m){var x=e.map(e.range(h(m)+1),function(){return[]});return e.forEach(m.nodes(),function(w){var E=m.node(w),S=E.rank;e.isUndefined(S)||(x[S][E.order]=w)}),x}function u(m){var x=e.min(e.map(m.nodes(),function(w){return m.node(w).rank}));e.forEach(m.nodes(),function(w){var E=m.node(w);e.has(E,"rank")&&(E.rank-=x)})}function d(m){var x=e.min(e.map(m.nodes(),function(_){return m.node(_).rank})),w=[];e.forEach(m.nodes(),function(_){var C=m.node(_).rank-x;w[C]||(w[C]=[]),w[C].push(_)});var E=0,S=m.graph().nodeRankFactor;e.forEach(w,function(_,C){e.isUndefined(_)&&C%S!==0?--E:E&&e.forEach(_,function(N){m.node(N).rank+=E})})}function f(m,x,w,E){var S={width:0,height:0};return arguments.length>=4&&(S.rank=w,S.order=E),r(m,"border",S,x)}function h(m){return e.max(e.map(m.nodes(),function(x){var w=m.node(x).rank;if(!e.isUndefined(w))return w}))}function v(m,x){var w={lhs:[],rhs:[]};return e.forEach(m,function(E){x(E)?w.lhs.push(E):w.rhs.push(E)}),w}function b(m,x){var w=e.now();try{return x()}finally{console.log(m+" time: "+(e.now()-w)+"ms")}}function g(m,x){return x()}return yy}var xy,hA;function XQ(){if(hA)return xy;hA=1;var e=Ct(),t=kr();xy={run:r,undo:o};function r(i){i.graph().dummyChains=[],e.forEach(i.edges(),function(a){n(i,a)})}function n(i,a){var s=a.v,c=i.node(s).rank,u=a.w,d=i.node(u).rank,f=a.name,h=i.edge(a),v=h.labelRank;if(d!==c+1){i.removeEdge(a);var b,g,m;for(m=0,++c;c<d;++m,++c)h.points=[],g={width:0,height:0,edgeLabel:h,edgeObj:a,rank:c},b=t.addDummyNode(i,"edge",g,"_d"),c===v&&(g.width=h.width,g.height=h.height,g.dummy="edge-label",g.labelpos=h.labelpos),i.setEdge(s,b,{weight:h.weight},f),m===0&&i.graph().dummyChains.push(b),s=b;i.setEdge(s,u,{weight:h.weight},f)}}function o(i){e.forEach(i.graph().dummyChains,function(a){var s=i.node(a),c=s.edgeLabel,u;for(i.setEdge(s.edgeObj,c);s.dummy;)u=i.successors(a)[0],i.removeNode(a),c.points.push({x:s.x,y:s.y}),s.dummy==="edge-label"&&(c.x=s.x,c.y=s.y,c.width=s.width,c.height=s.height),a=u,s=i.node(a)})}return xy}var wy,vA;function rd(){if(vA)return wy;vA=1;var e=Ct();wy={longestPath:t,slack:r};function t(n){var o={};function i(a){var s=n.node(a);if(e.has(o,a))return s.rank;o[a]=!0;var c=e.min(e.map(n.outEdges(a),function(u){return i(u.w)-n.edge(u).minlen}));return(c===Number.POSITIVE_INFINITY||c===void 0||c===null)&&(c=0),s.rank=c}e.forEach(n.sources(),i)}function r(n,o){return n.node(o.w).rank-n.node(o.v).rank-n.edge(o).minlen}return wy}var _y,gA;function Dz(){if(gA)return _y;gA=1;var e=Ct(),t=Tn().Graph,r=rd().slack;_y=n;function n(s){var c=new t({directed:!1}),u=s.nodes()[0],d=s.nodeCount();c.setNode(u,{});for(var f,h;o(c,s)<d;)f=i(c,s),h=c.hasNode(f.v)?r(s,f):-r(s,f),a(c,s,h);return c}function o(s,c){function u(d){e.forEach(c.nodeEdges(d),function(f){var h=f.v,v=d===h?f.w:h;!s.hasNode(v)&&!r(c,f)&&(s.setNode(v,{}),s.setEdge(d,v,{}),u(v))})}return e.forEach(s.nodes(),u),s.nodeCount()}function i(s,c){return e.minBy(c.edges(),function(u){if(s.hasNode(u.v)!==s.hasNode(u.w))return r(c,u)})}function a(s,c,u){e.forEach(s.nodes(),function(d){c.node(d).rank+=u})}return _y}var Ey,mA;function ZQ(){if(mA)return Ey;mA=1;var e=Ct(),t=Dz(),r=rd().slack,n=rd().longestPath,o=Tn().alg.preorder,i=Tn().alg.postorder,a=kr().simplify;Ey=s,s.initLowLimValues=f,s.initCutValues=c,s.calcCutValue=d,s.leaveEdge=v,s.enterEdge=b,s.exchangeEdges=g;function s(E){E=a(E),n(E);var S=t(E);f(S),c(S,E);for(var _,C;_=v(S);)C=b(S,E,_),g(S,E,_,C)}function c(E,S){var _=i(E,E.nodes());_=_.slice(0,_.length-1),e.forEach(_,function(C){u(E,S,C)})}function u(E,S,_){var C=E.node(_),N=C.parent;E.edge(_,N).cutvalue=d(E,S,_)}function d(E,S,_){var C=E.node(_),N=C.parent,P=!0,A=S.edge(_,N),j=0;return A||(P=!1,A=S.edge(N,_)),j=A.weight,e.forEach(S.nodeEdges(_),function(M){var L=M.v===_,D=L?M.w:M.v;if(D!==N){var T=L===P,W=S.edge(M).weight;if(j+=T?W:-W,x(E,_,D)){var q=E.edge(_,D).cutvalue;j+=T?-q:q}}}),j}function f(E,S){arguments.length<2&&(S=E.nodes()[0]),h(E,{},1,S)}function h(E,S,_,C,N){var P=_,A=E.node(C);return S[C]=!0,e.forEach(E.neighbors(C),function(j){e.has(S,j)||(_=h(E,S,_,j,C))}),A.low=P,A.lim=_++,N?A.parent=N:delete A.parent,_}function v(E){return e.find(E.edges(),function(S){return E.edge(S).cutvalue<0})}function b(E,S,_){var C=_.v,N=_.w;S.hasEdge(C,N)||(C=_.w,N=_.v);var P=E.node(C),A=E.node(N),j=P,M=!1;P.lim>A.lim&&(j=A,M=!0);var L=e.filter(S.edges(),function(D){return M===w(E,E.node(D.v),j)&&M!==w(E,E.node(D.w),j)});return e.minBy(L,function(D){return r(S,D)})}function g(E,S,_,C){var N=_.v,P=_.w;E.removeEdge(N,P),E.setEdge(C.v,C.w,{}),f(E),c(E,S),m(E,S)}function m(E,S){var _=e.find(E.nodes(),function(N){return!S.node(N).parent}),C=o(E,_);C=C.slice(1),e.forEach(C,function(N){var P=E.node(N).parent,A=S.edge(N,P),j=!1;A||(A=S.edge(P,N),j=!0),S.node(N).rank=S.node(P).rank+(j?A.minlen:-A.minlen)})}function x(E,S,_){return E.hasEdge(S,_)}function w(E,S,_){return _.low<=S.lim&&S.lim<=_.lim}return Ey}var Sy,bA;function JQ(){if(bA)return Sy;bA=1;var e=rd(),t=e.longestPath,r=Dz(),n=ZQ();Sy=o;function o(c){switch(c.graph().ranker){case"network-simplex":s(c);break;case"tight-tree":a(c);break;case"longest-path":i(c);break;default:s(c)}}var i=t;function a(c){t(c),r(c)}function s(c){n(c)}return Sy}var Oy,yA;function QQ(){if(yA)return Oy;yA=1;var e=Ct();Oy=t;function t(o){var i=n(o);e.forEach(o.graph().dummyChains,function(a){for(var s=o.node(a),c=s.edgeObj,u=r(o,i,c.v,c.w),d=u.path,f=u.lca,h=0,v=d[h],b=!0;a!==c.w;){if(s=o.node(a),b){for(;(v=d[h])!==f&&o.node(v).maxRank<s.rank;)h++;v===f&&(b=!1)}if(!b){for(;h<d.length-1&&o.node(v=d[h+1]).minRank<=s.rank;)h++;v=d[h]}o.setParent(a,v),a=o.successors(a)[0]}})}function r(o,i,a,s){var c=[],u=[],d=Math.min(i[a].low,i[s].low),f=Math.max(i[a].lim,i[s].lim),h,v;h=a;do h=o.parent(h),c.push(h);while(h&&(i[h].low>d||f>i[h].lim));for(v=h,h=s;(h=o.parent(h))!==v;)u.push(h);return{path:c.concat(u.reverse()),lca:v}}function n(o){var i={},a=0;function s(c){var u=a;e.forEach(o.children(c),s),i[c]={low:u,lim:a++}}return e.forEach(o.children(),s),i}return Oy}var Cy,xA;function eee(){if(xA)return Cy;xA=1;var e=Ct(),t=kr();Cy={run:r,cleanup:a};function r(s){var c=t.addDummyNode(s,"root",{},"_root"),u=o(s),d=e.max(e.values(u))-1,f=2*d+1;s.graph().nestingRoot=c,e.forEach(s.edges(),function(v){s.edge(v).minlen*=f});var h=i(s)+1;e.forEach(s.children(),function(v){n(s,c,f,h,d,u,v)}),s.graph().nodeRankFactor=f}function n(s,c,u,d,f,h,v){var b=s.children(v);if(!b.length){v!==c&&s.setEdge(c,v,{weight:0,minlen:u});return}var g=t.addBorderNode(s,"_bt"),m=t.addBorderNode(s,"_bb"),x=s.node(v);s.setParent(g,v),x.borderTop=g,s.setParent(m,v),x.borderBottom=m,e.forEach(b,function(w){n(s,c,u,d,f,h,w);var E=s.node(w),S=E.borderTop?E.borderTop:w,_=E.borderBottom?E.borderBottom:w,C=E.borderTop?d:2*d,N=S!==_?1:f-h[v]+1;s.setEdge(g,S,{weight:C,minlen:N,nestingEdge:!0}),s.setEdge(_,m,{weight:C,minlen:N,nestingEdge:!0})}),s.parent(v)||s.setEdge(c,g,{weight:0,minlen:f+h[v]})}function o(s){var c={};function u(d,f){var h=s.children(d);h&&h.length&&e.forEach(h,function(v){u(v,f+1)}),c[d]=f}return e.forEach(s.children(),function(d){u(d,1)}),c}function i(s){return e.reduce(s.edges(),function(c,u){return c+s.edge(u).weight},0)}function a(s){var c=s.graph();s.removeNode(c.nestingRoot),delete c.nestingRoot,e.forEach(s.edges(),function(u){var d=s.edge(u);d.nestingEdge&&s.removeEdge(u)})}return Cy}var Ry,wA;function tee(){if(wA)return Ry;wA=1;var e=Ct(),t=kr();Ry=r;function r(o){function i(a){var s=o.children(a),c=o.node(a);if(s.length&&e.forEach(s,i),e.has(c,"minRank")){c.borderLeft=[],c.borderRight=[];for(var u=c.minRank,d=c.maxRank+1;u<d;++u)n(o,"borderLeft","_bl",a,c,u),n(o,"borderRight","_br",a,c,u)}}e.forEach(o.children(),i)}function n(o,i,a,s,c,u){var d={width:0,height:0,rank:u,borderType:i},f=c[i][u-1],h=t.addDummyNode(o,"border",d,a);c[i][u]=h,o.setParent(h,s),f&&o.setEdge(f,h,{weight:1})}return Ry}var Ny,_A;function ree(){if(_A)return Ny;_A=1;var e=Ct();Ny={adjust:t,undo:r};function t(u){var d=u.graph().rankdir.toLowerCase();(d==="lr"||d==="rl")&&n(u)}function r(u){var d=u.graph().rankdir.toLowerCase();(d==="bt"||d==="rl")&&i(u),(d==="lr"||d==="rl")&&(s(u),n(u))}function n(u){e.forEach(u.nodes(),function(d){o(u.node(d))}),e.forEach(u.edges(),function(d){o(u.edge(d))})}function o(u){var d=u.width;u.width=u.height,u.height=d}function i(u){e.forEach(u.nodes(),function(d){a(u.node(d))}),e.forEach(u.edges(),function(d){var f=u.edge(d);e.forEach(f.points,a),e.has(f,"y")&&a(f)})}function a(u){u.y=-u.y}function s(u){e.forEach(u.nodes(),function(d){c(u.node(d))}),e.forEach(u.edges(),function(d){var f=u.edge(d);e.forEach(f.points,c),e.has(f,"x")&&c(f)})}function c(u){var d=u.x;u.x=u.y,u.y=d}return Ny}var Iy,EA;function nee(){if(EA)return Iy;EA=1;var e=Ct();Iy=t;function t(r){var n={},o=e.filter(r.nodes(),function(u){return!r.children(u).length}),i=e.max(e.map(o,function(u){return r.node(u).rank})),a=e.map(e.range(i+1),function(){return[]});function s(u){if(!e.has(n,u)){n[u]=!0;var d=r.node(u);a[d.rank].push(u),e.forEach(r.successors(u),s)}}var c=e.sortBy(o,function(u){return r.node(u).rank});return e.forEach(c,s),a}return Iy}var Py,SA;function oee(){if(SA)return Py;SA=1;var e=Ct();Py=t;function t(n,o){for(var i=0,a=1;a<o.length;++a)i+=r(n,o[a-1],o[a]);return i}function r(n,o,i){for(var a=e.zipObject(i,e.map(i,function(h,v){return v})),s=e.flatten(e.map(o,function(h){return e.sortBy(e.map(n.outEdges(h),function(v){return{pos:a[v.w],weight:n.edge(v).weight}}),"pos")}),!0),c=1;c<i.length;)c<<=1;var u=2*c-1;c-=1;var d=e.map(new Array(u),function(){return 0}),f=0;return e.forEach(s.forEach(function(h){var v=h.pos+c;d[v]+=h.weight;for(var b=0;v>0;)v%2&&(b+=d[v+1]),v=v-1>>1,d[v]+=h.weight;f+=h.weight*b})),f}return Py}var Ty,OA;function iee(){if(OA)return Ty;OA=1;var e=Ct();Ty=t;function t(r,n){return e.map(n,function(o){var i=r.inEdges(o);if(i.length){var a=e.reduce(i,function(s,c){var u=r.edge(c),d=r.node(c.v);return{sum:s.sum+u.weight*d.order,weight:s.weight+u.weight}},{sum:0,weight:0});return{v:o,barycenter:a.sum/a.weight,weight:a.weight}}else return{v:o}})}return Ty}var Ay,CA;function aee(){if(CA)return Ay;CA=1;var e=Ct();Ay=t;function t(o,i){var a={};e.forEach(o,function(c,u){var d=a[c.v]={indegree:0,in:[],out:[],vs:[c.v],i:u};e.isUndefined(c.barycenter)||(d.barycenter=c.barycenter,d.weight=c.weight)}),e.forEach(i.edges(),function(c){var u=a[c.v],d=a[c.w];!e.isUndefined(u)&&!e.isUndefined(d)&&(d.indegree++,u.out.push(a[c.w]))});var s=e.filter(a,function(c){return!c.indegree});return r(s)}function r(o){var i=[];function a(u){return function(d){d.merged||(e.isUndefined(d.barycenter)||e.isUndefined(u.barycenter)||d.barycenter>=u.barycenter)&&n(u,d)}}function s(u){return function(d){d.in.push(u),--d.indegree===0&&o.push(d)}}for(;o.length;){var c=o.pop();i.push(c),e.forEach(c.in.reverse(),a(c)),e.forEach(c.out,s(c))}return e.map(e.filter(i,function(u){return!u.merged}),function(u){return e.pick(u,["vs","i","barycenter","weight"])})}function n(o,i){var a=0,s=0;o.weight&&(a+=o.barycenter*o.weight,s+=o.weight),i.weight&&(a+=i.barycenter*i.weight,s+=i.weight),o.vs=i.vs.concat(o.vs),o.barycenter=a/s,o.weight=s,o.i=Math.min(i.i,o.i),i.merged=!0}return Ay}var ky,RA;function see(){if(RA)return ky;RA=1;var e=Ct(),t=kr();ky=r;function r(i,a){var s=t.partition(i,function(g){return e.has(g,"barycenter")}),c=s.lhs,u=e.sortBy(s.rhs,function(g){return-g.i}),d=[],f=0,h=0,v=0;c.sort(o(!!a)),v=n(d,u,v),e.forEach(c,function(g){v+=g.vs.length,d.push(g.vs),f+=g.barycenter*g.weight,h+=g.weight,v=n(d,u,v)});var b={vs:e.flatten(d,!0)};return h&&(b.barycenter=f/h,b.weight=h),b}function n(i,a,s){for(var c;a.length&&(c=e.last(a)).i<=s;)a.pop(),i.push(c.vs),s++;return s}function o(i){return function(a,s){return a.barycenter<s.barycenter?-1:a.barycenter>s.barycenter?1:i?s.i-a.i:a.i-s.i}}return ky}var Dy,NA;function lee(){if(NA)return Dy;NA=1;var e=Ct(),t=iee(),r=aee(),n=see();Dy=o;function o(s,c,u,d){var f=s.children(c),h=s.node(c),v=h?h.borderLeft:void 0,b=h?h.borderRight:void 0,g={};v&&(f=e.filter(f,function(_){return _!==v&&_!==b}));var m=t(s,f);e.forEach(m,function(_){if(s.children(_.v).length){var C=o(s,_.v,u,d);g[_.v]=C,e.has(C,"barycenter")&&a(_,C)}});var x=r(m,u);i(x,g);var w=n(x,d);if(v&&(w.vs=e.flatten([v,w.vs,b],!0),s.predecessors(v).length)){var E=s.node(s.predecessors(v)[0]),S=s.node(s.predecessors(b)[0]);e.has(w,"barycenter")||(w.barycenter=0,w.weight=0),w.barycenter=(w.barycenter*w.weight+E.order+S.order)/(w.weight+2),w.weight+=2}return w}function i(s,c){e.forEach(s,function(u){u.vs=e.flatten(u.vs.map(function(d){return c[d]?c[d].vs:d}),!0)})}function a(s,c){e.isUndefined(s.barycenter)?(s.barycenter=c.barycenter,s.weight=c.weight):(s.barycenter=(s.barycenter*s.weight+c.barycenter*c.weight)/(s.weight+c.weight),s.weight+=c.weight)}return Dy}var My,IA;function cee(){if(IA)return My;IA=1;var e=Ct(),t=Tn().Graph;My=r;function r(o,i,a){var s=n(o),c=new t({compound:!0}).setGraph({root:s}).setDefaultNodeLabel(function(u){return o.node(u)});return e.forEach(o.nodes(),function(u){var d=o.node(u),f=o.parent(u);(d.rank===i||d.minRank<=i&&i<=d.maxRank)&&(c.setNode(u),c.setParent(u,f||s),e.forEach(o[a](u),function(h){var v=h.v===u?h.w:h.v,b=c.edge(v,u),g=e.isUndefined(b)?0:b.weight;c.setEdge(v,u,{weight:o.edge(h).weight+g})}),e.has(d,"minRank")&&c.setNode(u,{borderLeft:d.borderLeft[i],borderRight:d.borderRight[i]}))}),c}function n(o){for(var i;o.hasNode(i=e.uniqueId("_root")););return i}return My}var jy,PA;function uee(){if(PA)return jy;PA=1;var e=Ct();jy=t;function t(r,n,o){var i={},a;e.forEach(o,function(s){for(var c=r.parent(s),u,d;c;){if(u=r.parent(c),u?(d=i[u],i[u]=c):(d=a,a=c),d&&d!==c){n.setEdge(d,c);return}c=u}})}return jy}var Ly,TA;function dee(){if(TA)return Ly;TA=1;var e=Ct(),t=nee(),r=oee(),n=lee(),o=cee(),i=uee(),a=Tn().Graph,s=kr();Ly=c;function c(h){var v=s.maxRank(h),b=u(h,e.range(1,v+1),"inEdges"),g=u(h,e.range(v-1,-1,-1),"outEdges"),m=t(h);f(h,m);for(var x=Number.POSITIVE_INFINITY,w,E=0,S=0;S<4;++E,++S){d(E%2?b:g,E%4>=2),m=s.buildLayerMatrix(h);var _=r(h,m);_<x&&(S=0,w=e.cloneDeep(m),x=_)}f(h,w)}function u(h,v,b){return e.map(v,function(g){return o(h,g,b)})}function d(h,v){var b=new a;e.forEach(h,function(g){var m=g.graph().root,x=n(g,m,b,v);e.forEach(x.vs,function(w,E){g.node(w).order=E}),i(g,b,x.vs)})}function f(h,v){e.forEach(v,function(b){e.forEach(b,function(g,m){h.node(g).order=m})})}return Ly}var qy,AA;function fee(){if(AA)return qy;AA=1;var e=Ct(),t=Tn().Graph,r=kr();qy={positionX:b,findType1Conflicts:n,findType2Conflicts:o,addConflict:a,hasConflict:s,verticalAlignment:c,horizontalCompaction:u,alignCoordinates:h,findSmallestWidthAlignment:f,balance:v};function n(x,w){var E={};function S(_,C){var N=0,P=0,A=_.length,j=e.last(C);return e.forEach(C,function(M,L){var D=i(x,M),T=D?x.node(D).order:A;(D||M===j)&&(e.forEach(C.slice(P,L+1),function(W){e.forEach(x.predecessors(W),function(q){var G=x.node(q),F=G.order;(F<N||T<F)&&!(G.dummy&&x.node(W).dummy)&&a(E,q,W)})}),P=L+1,N=T)}),C}return e.reduce(w,S),E}function o(x,w){var E={};function S(C,N,P,A,j){var M;e.forEach(e.range(N,P),function(L){M=C[L],x.node(M).dummy&&e.forEach(x.predecessors(M),function(D){var T=x.node(D);T.dummy&&(T.order<A||T.order>j)&&a(E,D,M)})})}function _(C,N){var P=-1,A,j=0;return e.forEach(N,function(M,L){if(x.node(M).dummy==="border"){var D=x.predecessors(M);D.length&&(A=x.node(D[0]).order,S(N,j,L,P,A),j=L,P=A)}S(N,j,N.length,A,C.length)}),N}return e.reduce(w,_),E}function i(x,w){if(x.node(w).dummy)return e.find(x.predecessors(w),function(E){return x.node(E).dummy})}function a(x,w,E){if(w>E){var S=w;w=E,E=S}var _=x[w];_||(x[w]=_={}),_[E]=!0}function s(x,w,E){if(w>E){var S=w;w=E,E=S}return e.has(x[w],E)}function c(x,w,E,S){var _={},C={},N={};return e.forEach(w,function(P){e.forEach(P,function(A,j){_[A]=A,C[A]=A,N[A]=j})}),e.forEach(w,function(P){var A=-1;e.forEach(P,function(j){var M=S(j);if(M.length){M=e.sortBy(M,function(q){return N[q]});for(var L=(M.length-1)/2,D=Math.floor(L),T=Math.ceil(L);D<=T;++D){var W=M[D];C[j]===j&&A<N[W]&&!s(E,j,W)&&(C[W]=j,C[j]=_[j]=_[W],A=N[W])}}})}),{root:_,align:C}}function u(x,w,E,S,_){var C={},N=d(x,w,E,_),P=_?"borderLeft":"borderRight";function A(L,D){for(var T=N.nodes(),W=T.pop(),q={};W;)q[W]?L(W):(q[W]=!0,T.push(W),T=T.concat(D(W))),W=T.pop()}function j(L){C[L]=N.inEdges(L).reduce(function(D,T){return Math.max(D,C[T.v]+N.edge(T))},0)}function M(L){var D=N.outEdges(L).reduce(function(W,q){return Math.min(W,C[q.w]-N.edge(q))},Number.POSITIVE_INFINITY),T=x.node(L);D!==Number.POSITIVE_INFINITY&&T.borderType!==P&&(C[L]=Math.max(C[L],D))}return A(j,N.predecessors.bind(N)),A(M,N.successors.bind(N)),e.forEach(S,function(L){C[L]=C[E[L]]}),C}function d(x,w,E,S){var _=new t,C=x.graph(),N=g(C.nodesep,C.edgesep,S);return e.forEach(w,function(P){var A;e.forEach(P,function(j){var M=E[j];if(_.setNode(M),A){var L=E[A],D=_.edge(L,M);_.setEdge(L,M,Math.max(N(x,j,A),D||0))}A=j})}),_}function f(x,w){return e.minBy(e.values(w),function(E){var S=Number.NEGATIVE_INFINITY,_=Number.POSITIVE_INFINITY;return e.forIn(E,function(C,N){var P=m(x,N)/2;S=Math.max(C+P,S),_=Math.min(C-P,_)}),S-_})}function h(x,w){var E=e.values(w),S=e.min(E),_=e.max(E);e.forEach(["u","d"],function(C){e.forEach(["l","r"],function(N){var P=C+N,A=x[P],j;if(A!==w){var M=e.values(A);j=N==="l"?S-e.min(M):_-e.max(M),j&&(x[P]=e.mapValues(A,function(L){return L+j}))}})})}function v(x,w){return e.mapValues(x.ul,function(E,S){if(w)return x[w.toLowerCase()][S];var _=e.sortBy(e.map(x,S));return(_[1]+_[2])/2})}function b(x){var w=r.buildLayerMatrix(x),E=e.merge(n(x,w),o(x,w)),S={},_;e.forEach(["u","d"],function(N){_=N==="u"?w:e.values(w).reverse(),e.forEach(["l","r"],function(P){P==="r"&&(_=e.map(_,function(L){return e.values(L).reverse()}));var A=(N==="u"?x.predecessors:x.successors).bind(x),j=c(x,_,E,A),M=u(x,_,j.root,j.align,P==="r");P==="r"&&(M=e.mapValues(M,function(L){return-L})),S[N+P]=M})});var C=f(x,S);return h(S,C),v(S,x.graph().align)}function g(x,w,E){return function(S,_,C){var N=S.node(_),P=S.node(C),A=0,j;if(A+=N.width/2,e.has(N,"labelpos"))switch(N.labelpos.toLowerCase()){case"l":j=-N.width/2;break;case"r":j=N.width/2;break}if(j&&(A+=E?j:-j),j=0,A+=(N.dummy?w:x)/2,A+=(P.dummy?w:x)/2,A+=P.width/2,e.has(P,"labelpos"))switch(P.labelpos.toLowerCase()){case"l":j=P.width/2;break;case"r":j=-P.width/2;break}return j&&(A+=E?j:-j),j=0,A}}function m(x,w){return x.node(w).width}return qy}var zy,kA;function pee(){if(kA)return zy;kA=1;var e=Ct(),t=kr(),r=fee().positionX;zy=n;function n(i){i=t.asNonCompoundGraph(i),o(i),e.forEach(r(i),function(a,s){i.node(s).x=a})}function o(i){var a=t.buildLayerMatrix(i),s=i.graph().ranksep,c=0;e.forEach(a,function(u){var d=e.max(e.map(u,function(f){return i.node(f).height}));e.forEach(u,function(f){i.node(f).y=c+d/2}),c+=d+s})}return zy}var By,DA;function hee(){if(DA)return By;DA=1;var e=Ct(),t=KQ(),r=XQ(),n=JQ(),o=kr().normalizeRanks,i=QQ(),a=kr().removeEmptyRanks,s=eee(),c=tee(),u=ree(),d=dee(),f=pee(),h=kr(),v=Tn().Graph;By=b;function b($,Y){var X=Y&&Y.debugTiming?h.time:h.notime;X("layout",function(){var H=X(" buildLayoutGraph",function(){return A($)});X(" runLayout",function(){g(H,X)}),X(" updateInputGraph",function(){m($,H)})})}function g($,Y){Y(" makeSpaceForEdgeLabels",function(){j($)}),Y(" removeSelfEdges",function(){J($)}),Y(" acyclic",function(){t.run($)}),Y(" nestingGraph.run",function(){s.run($)}),Y(" rank",function(){n(h.asNonCompoundGraph($))}),Y(" injectEdgeLabelProxies",function(){M($)}),Y(" removeEmptyRanks",function(){a($)}),Y(" nestingGraph.cleanup",function(){s.cleanup($)}),Y(" normalizeRanks",function(){o($)}),Y(" assignRankMinMax",function(){L($)}),Y(" removeEdgeLabelProxies",function(){D($)}),Y(" normalize.run",function(){r.run($)}),Y(" parentDummyChains",function(){i($)}),Y(" addBorderSegments",function(){c($)}),Y(" order",function(){d($)}),Y(" insertSelfEdges",function(){z($)}),Y(" adjustCoordinateSystem",function(){u.adjust($)}),Y(" position",function(){f($)}),Y(" positionSelfEdges",function(){U($)}),Y(" removeBorderNodes",function(){F($)}),Y(" normalize.undo",function(){r.undo($)}),Y(" fixupEdgeLabelCoords",function(){q($)}),Y(" undoCoordinateSystem",function(){u.undo($)}),Y(" translateGraph",function(){T($)}),Y(" assignNodeIntersects",function(){W($)}),Y(" reversePoints",function(){G($)}),Y(" acyclic.undo",function(){t.undo($)})}function m($,Y){e.forEach($.nodes(),function(X){var H=$.node(X),K=Y.node(X);H&&(H.x=K.x,H.y=K.y,Y.children(X).length&&(H.width=K.width,H.height=K.height))}),e.forEach($.edges(),function(X){var H=$.edge(X),K=Y.edge(X);H.points=K.points,e.has(K,"x")&&(H.x=K.x,H.y=K.y)}),$.graph().width=Y.graph().width,$.graph().height=Y.graph().height}var x=["nodesep","edgesep","ranksep","marginx","marginy"],w={ranksep:50,edgesep:20,nodesep:50,rankdir:"tb"},E=["acyclicer","ranker","rankdir","align"],S=["width","height"],_={width:0,height:0},C=["minlen","weight","width","height","labeloffset"],N={minlen:1,weight:1,width:0,height:0,labeloffset:10,labelpos:"r"},P=["labelpos"];function A($){var Y=new v({multigraph:!0,compound:!0}),X=re($.graph());return Y.setGraph(e.merge({},w,oe(X,x),e.pick(X,E))),e.forEach($.nodes(),function(H){var K=re($.node(H));Y.setNode(H,e.defaults(oe(K,S),_)),Y.setParent(H,$.parent(H))}),e.forEach($.edges(),function(H){var K=re($.edge(H));Y.setEdge(H,e.merge({},N,oe(K,C),e.pick(K,P)))}),Y}function j($){var Y=$.graph();Y.ranksep/=2,e.forEach($.edges(),function(X){var H=$.edge(X);H.minlen*=2,H.labelpos.toLowerCase()!=="c"&&(Y.rankdir==="TB"||Y.rankdir==="BT"?H.width+=H.labeloffset:H.height+=H.labeloffset)})}function M($){e.forEach($.edges(),function(Y){var X=$.edge(Y);if(X.width&&X.height){var H=$.node(Y.v),K=$.node(Y.w),Q={rank:(K.rank-H.rank)/2+H.rank,e:Y};h.addDummyNode($,"edge-proxy",Q,"_ep")}})}function L($){var Y=0;e.forEach($.nodes(),function(X){var H=$.node(X);H.borderTop&&(H.minRank=$.node(H.borderTop).rank,H.maxRank=$.node(H.borderBottom).rank,Y=e.max(Y,H.maxRank))}),$.graph().maxRank=Y}function D($){e.forEach($.nodes(),function(Y){var X=$.node(Y);X.dummy==="edge-proxy"&&($.edge(X.e).labelRank=X.rank,$.removeNode(Y))})}function T($){var Y=Number.POSITIVE_INFINITY,X=0,H=Number.POSITIVE_INFINITY,K=0,Q=$.graph(),ne=Q.marginx||0,se=Q.marginy||0;function te(be){var de=be.x,Ee=be.y,fe=be.width,le=be.height;Y=Math.min(Y,de-fe/2),X=Math.max(X,de+fe/2),H=Math.min(H,Ee-le/2),K=Math.max(K,Ee+le/2)}e.forEach($.nodes(),function(be){te($.node(be))}),e.forEach($.edges(),function(be){var de=$.edge(be);e.has(de,"x")&&te(de)}),Y-=ne,H-=se,e.forEach($.nodes(),function(be){var de=$.node(be);de.x-=Y,de.y-=H}),e.forEach($.edges(),function(be){var de=$.edge(be);e.forEach(de.points,function(Ee){Ee.x-=Y,Ee.y-=H}),e.has(de,"x")&&(de.x-=Y),e.has(de,"y")&&(de.y-=H)}),Q.width=X-Y+ne,Q.height=K-H+se}function W($){e.forEach($.edges(),function(Y){var X=$.edge(Y),H=$.node(Y.v),K=$.node(Y.w),Q,ne;X.points?(Q=X.points[0],ne=X.points[X.points.length-1]):(X.points=[],Q=K,ne=H),X.points.unshift(h.intersectRect(H,Q)),X.points.push(h.intersectRect(K,ne))})}function q($){e.forEach($.edges(),function(Y){var X=$.edge(Y);if(e.has(X,"x"))switch((X.labelpos==="l"||X.labelpos==="r")&&(X.width-=X.labeloffset),X.labelpos){case"l":X.x-=X.width/2+X.labeloffset;break;case"r":X.x+=X.width/2+X.labeloffset;break}})}function G($){e.forEach($.edges(),function(Y){var X=$.edge(Y);X.reversed&&X.points.reverse()})}function F($){e.forEach($.nodes(),function(Y){if($.children(Y).length){var X=$.node(Y),H=$.node(X.borderTop),K=$.node(X.borderBottom),Q=$.node(e.last(X.borderLeft)),ne=$.node(e.last(X.borderRight));X.width=Math.abs(ne.x-Q.x),X.height=Math.abs(K.y-H.y),X.x=Q.x+X.width/2,X.y=H.y+X.height/2}}),e.forEach($.nodes(),function(Y){$.node(Y).dummy==="border"&&$.removeNode(Y)})}function J($){e.forEach($.edges(),function(Y){if(Y.v===Y.w){var X=$.node(Y.v);X.selfEdges||(X.selfEdges=[]),X.selfEdges.push({e:Y,label:$.edge(Y)}),$.removeEdge(Y)}})}function z($){var Y=h.buildLayerMatrix($);e.forEach(Y,function(X){var H=0;e.forEach(X,function(K,Q){var ne=$.node(K);ne.order=Q+H,e.forEach(ne.selfEdges,function(se){h.addDummyNode($,"selfedge",{width:se.label.width,height:se.label.height,rank:ne.rank,order:Q+ ++H,e:se.e,label:se.label},"_se")}),delete ne.selfEdges})})}function U($){e.forEach($.nodes(),function(Y){var X=$.node(Y);if(X.dummy==="selfedge"){var H=$.node(X.e.v),K=H.x+H.width/2,Q=H.y,ne=X.x-K,se=H.height/2;$.setEdge(X.e,X.label),$.removeNode(Y),X.label.points=[{x:K+2*ne/3,y:Q-se},{x:K+5*ne/6,y:Q-se},{x:K+ne,y:Q},{x:K+5*ne/6,y:Q+se},{x:K+2*ne/3,y:Q+se}],X.label.x=X.x,X.label.y=X.y}})}function oe($,Y){return e.mapValues(e.pick($,Y),Number)}function re($){var Y={};return e.forEach($,function(X,H){Y[H.toLowerCase()]=X}),Y}return By}var Fy,MA;function vee(){if(MA)return Fy;MA=1;var e=Ct(),t=kr(),r=Tn().Graph;Fy={debugOrdering:n};function n(o){var i=t.buildLayerMatrix(o),a=new r({compound:!0,multigraph:!0}).setGraph({});return e.forEach(o.nodes(),function(s){a.setNode(s,{label:s}),a.setParent(s,"layer"+o.node(s).rank)}),e.forEach(o.edges(),function(s){a.setEdge(s.v,s.w,{},s.name)}),e.forEach(i,function(s,c){var u="layer"+c;a.setNode(u,{rank:"same"}),e.reduce(s,function(d,f){return a.setEdge(d,f,{style:"invis"}),f})}),a}return Fy}var $y,jA;function gee(){return jA||(jA=1,$y="0.8.5"),$y}var Vy,LA;function mee(){return LA||(LA=1,Vy={graphlib:Tn(),layout:hee(),debug:vee(),util:{time:kr().time,notime:kr().notime},version:gee()}),Vy}var bee=mee();const qA=Zo(bee);function yee(e){let t;const r=new Set,n=(u,d)=>{const f=typeof u=="function"?u(t):u;if(f!==t){const h=t;t=d?f:Object.assign({},t,f),r.forEach(v=>v(t,h))}},o=()=>t,i=(u,d=o,f=Object.is)=>{console.warn("[DEPRECATED] Please use `subscribeWithSelector` middleware");let h=d(t);function v(){const b=d(t);if(!f(h,b)){const g=h;u(h=b,g)}}return r.add(v),()=>r.delete(v)},c={setState:n,getState:o,subscribe:(u,d,f)=>d||f?i(u,d,f):(r.add(u),()=>r.delete(u)),destroy:()=>r.clear()};return t=e(n,o,c),c}const xee=typeof window>"u"||!window.navigator||/ServerSideRendering|^Deno\//.test(window.navigator.userAgent),zA=xee?R.useEffect:R.useLayoutEffect;function wee(e){const t=typeof e=="function"?yee(e):e,r=(n=t.getState,o=Object.is)=>{const[,i]=R.useReducer(m=>m+1,0),a=t.getState(),s=R.useRef(a),c=R.useRef(n),u=R.useRef(o),d=R.useRef(!1),f=R.useRef();f.current===void 0&&(f.current=n(a));let h,v=!1;(s.current!==a||c.current!==n||u.current!==o||d.current)&&(h=n(a),v=!o(f.current,h)),zA(()=>{v&&(f.current=h),s.current=a,c.current=n,u.current=o,d.current=!1});const b=R.useRef(a);zA(()=>{const m=()=>{try{const w=t.getState(),E=c.current(w);u.current(f.current,E)||(s.current=w,f.current=E,i())}catch{d.current=!0,i()}},x=t.subscribe(m);return t.getState()!==b.current&&m(),x},[]);const g=v?h:f.current;return R.useDebugValue(g),g};return Object.assign(r,t),r[Symbol.iterator]=function(){console.warn("[useStore, api] = create() is deprecated and will be removed in v4");const n=[r,t];return{next(){const o=n.length<=0;return{value:n.shift(),done:o}}}},r}function _ee(){const e=R.createContext(void 0);return{Provider:({initialStore:o,createStore:i,children:a})=>{const s=R.useRef();return s.current||(o&&(console.warn("Provider initialStore is deprecated and will be removed in the next version."),i||(i=()=>o)),s.current=i()),R.createElement(e.Provider,{value:s.current},a)},useStore:(o,i=Object.is)=>{const a=R.useContext(e);if(!a)throw new Error("Seems like you have not used zustand provider as an ancestor.");return a(o,i)},useStoreApi:()=>{const o=R.useContext(e);if(!o)throw new Error("Seems like you have not used zustand provider as an ancestor.");return R.useMemo(()=>({getState:o.getState,setState:o.setState,subscribe:o.subscribe,destroy:o.destroy}),[o])}}}var Eee={value:()=>{}};function of(){for(var e=0,t=arguments.length,r={},n;e<t;++e){if(!(n=arguments[e]+"")||n in r||/[\s.]/.test(n))throw new Error("illegal type: "+n);r[n]=[]}return new Du(r)}function Du(e){this._=e}function See(e,t){return e.trim().split(/^|\s+/).map(function(r){var n="",o=r.indexOf(".");if(o>=0&&(n=r.slice(o+1),r=r.slice(0,o)),r&&!t.hasOwnProperty(r))throw new Error("unknown type: "+r);return{type:r,name:n}})}Du.prototype=of.prototype={constructor:Du,on:function(e,t){var r=this._,n=See(e+"",r),o,i=-1,a=n.length;if(arguments.length<2){for(;++i<a;)if((o=(e=n[i]).type)&&(o=Oee(r[o],e.name)))return o;return}if(t!=null&&typeof t!="function")throw new Error("invalid callback: "+t);for(;++i<a;)if(o=(e=n[i]).type)r[o]=BA(r[o],e.name,t);else if(t==null)for(o in r)r[o]=BA(r[o],e.name,null);return this},copy:function(){var e={},t=this._;for(var r in t)e[r]=t[r].slice();return new Du(e)},call:function(e,t){if((o=arguments.length-2)>0)for(var r=new Array(o),n=0,o,i;n<o;++n)r[n]=arguments[n+2];if(!this._.hasOwnProperty(e))throw new Error("unknown type: "+e);for(i=this._[e],n=0,o=i.length;n<o;++n)i[n].value.apply(t,r)},apply:function(e,t,r){if(!this._.hasOwnProperty(e))throw new Error("unknown type: "+e);for(var n=this._[e],o=0,i=n.length;o<i;++o)n[o].value.apply(t,r)}};function Oee(e,t){for(var r=0,n=e.length,o;r<n;++r)if((o=e[r]).name===t)return o.value}function BA(e,t,r){for(var n=0,o=e.length;n<o;++n)if(e[n].name===t){e[n]=Eee,e=e.slice(0,n).concat(e.slice(n+1));break}return r!=null&&e.push({name:t,value:r}),e}var v_="http://www.w3.org/1999/xhtml";const FA={svg:"http://www.w3.org/2000/svg",xhtml:v_,xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/"};function af(e){var t=e+="",r=t.indexOf(":");return r>=0&&(t=e.slice(0,r))!=="xmlns"&&(e=e.slice(r+1)),FA.hasOwnProperty(t)?{space:FA[t],local:e}:e}function Cee(e){return function(){var t=this.ownerDocument,r=this.namespaceURI;return r===v_&&t.documentElement.namespaceURI===v_?t.createElement(e):t.createElementNS(r,e)}}function Ree(e){return function(){return this.ownerDocument.createElementNS(e.space,e.local)}}function Mz(e){var t=af(e);return(t.local?Ree:Cee)(t)}function Nee(){}function L1(e){return e==null?Nee:function(){return this.querySelector(e)}}function Iee(e){typeof e!="function"&&(e=L1(e));for(var t=this._groups,r=t.length,n=new Array(r),o=0;o<r;++o)for(var i=t[o],a=i.length,s=n[o]=new Array(a),c,u,d=0;d<a;++d)(c=i[d])&&(u=e.call(c,c.__data__,d,i))&&("__data__"in c&&(u.__data__=c.__data__),s[d]=u);return new Yr(n,this._parents)}function Pee(e){return e==null?[]:Array.isArray(e)?e:Array.from(e)}function Tee(){return[]}function jz(e){return e==null?Tee:function(){return this.querySelectorAll(e)}}function Aee(e){return function(){return Pee(e.apply(this,arguments))}}function kee(e){typeof e=="function"?e=Aee(e):e=jz(e);for(var t=this._groups,r=t.length,n=[],o=[],i=0;i<r;++i)for(var a=t[i],s=a.length,c,u=0;u<s;++u)(c=a[u])&&(n.push(e.call(c,c.__data__,u,a)),o.push(c));return new Yr(n,o)}function Lz(e){return function(){return this.matches(e)}}function qz(e){return function(t){return t.matches(e)}}var Dee=Array.prototype.find;function Mee(e){return function(){return Dee.call(this.children,e)}}function jee(){return this.firstElementChild}function Lee(e){return this.select(e==null?jee:Mee(typeof e=="function"?e:qz(e)))}var qee=Array.prototype.filter;function zee(){return Array.from(this.children)}function Bee(e){return function(){return qee.call(this.children,e)}}function Fee(e){return this.selectAll(e==null?zee:Bee(typeof e=="function"?e:qz(e)))}function $ee(e){typeof e!="function"&&(e=Lz(e));for(var t=this._groups,r=t.length,n=new Array(r),o=0;o<r;++o)for(var i=t[o],a=i.length,s=n[o]=[],c,u=0;u<a;++u)(c=i[u])&&e.call(c,c.__data__,u,i)&&s.push(c);return new Yr(n,this._parents)}function zz(e){return new Array(e.length)}function Vee(){return new Yr(this._enter||this._groups.map(zz),this._parents)}function nd(e,t){this.ownerDocument=e.ownerDocument,this.namespaceURI=e.namespaceURI,this._next=null,this._parent=e,this.__data__=t}nd.prototype={constructor:nd,appendChild:function(e){return this._parent.insertBefore(e,this._next)},insertBefore:function(e,t){return this._parent.insertBefore(e,t)},querySelector:function(e){return this._parent.querySelector(e)},querySelectorAll:function(e){return this._parent.querySelectorAll(e)}};function Hee(e){return function(){return e}}function Wee(e,t,r,n,o,i){for(var a=0,s,c=t.length,u=i.length;a<u;++a)(s=t[a])?(s.__data__=i[a],n[a]=s):r[a]=new nd(e,i[a]);for(;a<c;++a)(s=t[a])&&(o[a]=s)}function Uee(e,t,r,n,o,i,a){var s,c,u=new Map,d=t.length,f=i.length,h=new Array(d),v;for(s=0;s<d;++s)(c=t[s])&&(h[s]=v=a.call(c,c.__data__,s,t)+"",u.has(v)?o[s]=c:u.set(v,c));for(s=0;s<f;++s)v=a.call(e,i[s],s,i)+"",(c=u.get(v))?(n[s]=c,c.__data__=i[s],u.delete(v)):r[s]=new nd(e,i[s]);for(s=0;s<d;++s)(c=t[s])&&u.get(h[s])===c&&(o[s]=c)}function Gee(e){return e.__data__}function Yee(e,t){if(!arguments.length)return Array.from(this,Gee);var r=t?Uee:Wee,n=this._parents,o=this._groups;typeof e!="function"&&(e=Hee(e));for(var i=o.length,a=new Array(i),s=new Array(i),c=new Array(i),u=0;u<i;++u){var d=n[u],f=o[u],h=f.length,v=Kee(e.call(d,d&&d.__data__,u,n)),b=v.length,g=s[u]=new Array(b),m=a[u]=new Array(b),x=c[u]=new Array(h);r(d,f,g,m,x,v,t);for(var w=0,E=0,S,_;w<b;++w)if(S=g[w]){for(w>=E&&(E=w+1);!(_=m[E])&&++E<b;);S._next=_||null}}return a=new Yr(a,n),a._enter=s,a._exit=c,a}function Kee(e){return typeof e=="object"&&"length"in e?e:Array.from(e)}function Xee(){return new Yr(this._exit||this._groups.map(zz),this._parents)}function Zee(e,t,r){var n=this.enter(),o=this,i=this.exit();return typeof e=="function"?(n=e(n),n&&(n=n.selection())):n=n.append(e+""),t!=null&&(o=t(o),o&&(o=o.selection())),r==null?i.remove():r(i),n&&o?n.merge(o).order():o}function Jee(e){for(var t=e.selection?e.selection():e,r=this._groups,n=t._groups,o=r.length,i=n.length,a=Math.min(o,i),s=new Array(o),c=0;c<a;++c)for(var u=r[c],d=n[c],f=u.length,h=s[c]=new Array(f),v,b=0;b<f;++b)(v=u[b]||d[b])&&(h[b]=v);for(;c<o;++c)s[c]=r[c];return new Yr(s,this._parents)}function Qee(){for(var e=this._groups,t=-1,r=e.length;++t<r;)for(var n=e[t],o=n.length-1,i=n[o],a;--o>=0;)(a=n[o])&&(i&&a.compareDocumentPosition(i)^4&&i.parentNode.insertBefore(a,i),i=a);return this}function ete(e){e||(e=tte);function t(f,h){return f&&h?e(f.__data__,h.__data__):!f-!h}for(var r=this._groups,n=r.length,o=new Array(n),i=0;i<n;++i){for(var a=r[i],s=a.length,c=o[i]=new Array(s),u,d=0;d<s;++d)(u=a[d])&&(c[d]=u);c.sort(t)}return new Yr(o,this._parents).order()}function tte(e,t){return e<t?-1:e>t?1:e>=t?0:NaN}function rte(){var e=arguments[0];return arguments[0]=this,e.apply(null,arguments),this}function nte(){return Array.from(this)}function ote(){for(var e=this._groups,t=0,r=e.length;t<r;++t)for(var n=e[t],o=0,i=n.length;o<i;++o){var a=n[o];if(a)return a}return null}function ite(){let e=0;for(const t of this)++e;return e}function ate(){return!this.node()}function ste(e){for(var t=this._groups,r=0,n=t.length;r<n;++r)for(var o=t[r],i=0,a=o.length,s;i<a;++i)(s=o[i])&&e.call(s,s.__data__,i,o);return this}function lte(e){return function(){this.removeAttribute(e)}}function cte(e){return function(){this.removeAttributeNS(e.space,e.local)}}function ute(e,t){return function(){this.setAttribute(e,t)}}function dte(e,t){return function(){this.setAttributeNS(e.space,e.local,t)}}function fte(e,t){return function(){var r=t.apply(this,arguments);r==null?this.removeAttribute(e):this.setAttribute(e,r)}}function pte(e,t){return function(){var r=t.apply(this,arguments);r==null?this.removeAttributeNS(e.space,e.local):this.setAttributeNS(e.space,e.local,r)}}function hte(e,t){var r=af(e);if(arguments.length<2){var n=this.node();return r.local?n.getAttributeNS(r.space,r.local):n.getAttribute(r)}return this.each((t==null?r.local?cte:lte:typeof t=="function"?r.local?pte:fte:r.local?dte:ute)(r,t))}function Bz(e){return e.ownerDocument&&e.ownerDocument.defaultView||e.document&&e||e.defaultView}function vte(e){return function(){this.style.removeProperty(e)}}function gte(e,t,r){return function(){this.style.setProperty(e,t,r)}}function mte(e,t,r){return function(){var n=t.apply(this,arguments);n==null?this.style.removeProperty(e):this.style.setProperty(e,n,r)}}function bte(e,t,r){return arguments.length>1?this.each((t==null?vte:typeof t=="function"?mte:gte)(e,t,r??"")):Ra(this.node(),e)}function Ra(e,t){return e.style.getPropertyValue(t)||Bz(e).getComputedStyle(e,null).getPropertyValue(t)}function yte(e){return function(){delete this[e]}}function xte(e,t){return function(){this[e]=t}}function wte(e,t){return function(){var r=t.apply(this,arguments);r==null?delete this[e]:this[e]=r}}function _te(e,t){return arguments.length>1?this.each((t==null?yte:typeof t=="function"?wte:xte)(e,t)):this.node()[e]}function Fz(e){return e.trim().split(/^|\s+/)}function q1(e){return e.classList||new $z(e)}function $z(e){this._node=e,this._names=Fz(e.getAttribute("class")||"")}$z.prototype={add:function(e){var t=this._names.indexOf(e);t<0&&(this._names.push(e),this._node.setAttribute("class",this._names.join(" ")))},remove:function(e){var t=this._names.indexOf(e);t>=0&&(this._names.splice(t,1),this._node.setAttribute("class",this._names.join(" ")))},contains:function(e){return this._names.indexOf(e)>=0}};function Vz(e,t){for(var r=q1(e),n=-1,o=t.length;++n<o;)r.add(t[n])}function Hz(e,t){for(var r=q1(e),n=-1,o=t.length;++n<o;)r.remove(t[n])}function Ete(e){return function(){Vz(this,e)}}function Ste(e){return function(){Hz(this,e)}}function Ote(e,t){return function(){(t.apply(this,arguments)?Vz:Hz)(this,e)}}function Cte(e,t){var r=Fz(e+"");if(arguments.length<2){for(var n=q1(this.node()),o=-1,i=r.length;++o<i;)if(!n.contains(r[o]))return!1;return!0}return this.each((typeof t=="function"?Ote:t?Ete:Ste)(r,t))}function Rte(){this.textContent=""}function Nte(e){return function(){this.textContent=e}}function Ite(e){return function(){var t=e.apply(this,arguments);this.textContent=t??""}}function Pte(e){return arguments.length?this.each(e==null?Rte:(typeof e=="function"?Ite:Nte)(e)):this.node().textContent}function Tte(){this.innerHTML=""}function Ate(e){return function(){this.innerHTML=e}}function kte(e){return function(){var t=e.apply(this,arguments);this.innerHTML=t??""}}function Dte(e){return arguments.length?this.each(e==null?Tte:(typeof e=="function"?kte:Ate)(e)):this.node().innerHTML}function Mte(){this.nextSibling&&this.parentNode.appendChild(this)}function jte(){return this.each(Mte)}function Lte(){this.previousSibling&&this.parentNode.insertBefore(this,this.parentNode.firstChild)}function qte(){return this.each(Lte)}function zte(e){var t=typeof e=="function"?e:Mz(e);return this.select(function(){return this.appendChild(t.apply(this,arguments))})}function Bte(){return null}function Fte(e,t){var r=typeof e=="function"?e:Mz(e),n=t==null?Bte:typeof t=="function"?t:L1(t);return this.select(function(){return this.insertBefore(r.apply(this,arguments),n.apply(this,arguments)||null)})}function $te(){var e=this.parentNode;e&&e.removeChild(this)}function Vte(){return this.each($te)}function Hte(){var e=this.cloneNode(!1),t=this.parentNode;return t?t.insertBefore(e,this.nextSibling):e}function Wte(){var e=this.cloneNode(!0),t=this.parentNode;return t?t.insertBefore(e,this.nextSibling):e}function Ute(e){return this.select(e?Wte:Hte)}function Gte(e){return arguments.length?this.property("__data__",e):this.node().__data__}function Yte(e){return function(t){e.call(this,t,this.__data__)}}function Kte(e){return e.trim().split(/^|\s+/).map(function(t){var r="",n=t.indexOf(".");return n>=0&&(r=t.slice(n+1),t=t.slice(0,n)),{type:t,name:r}})}function Xte(e){return function(){var t=this.__on;if(t){for(var r=0,n=-1,o=t.length,i;r<o;++r)i=t[r],(!e.type||i.type===e.type)&&i.name===e.name?this.removeEventListener(i.type,i.listener,i.options):t[++n]=i;++n?t.length=n:delete this.__on}}}function Zte(e,t,r){return function(){var n=this.__on,o,i=Yte(t);if(n){for(var a=0,s=n.length;a<s;++a)if((o=n[a]).type===e.type&&o.name===e.name){this.removeEventListener(o.type,o.listener,o.options),this.addEventListener(o.type,o.listener=i,o.options=r),o.value=t;return}}this.addEventListener(e.type,i,r),o={type:e.type,name:e.name,value:t,listener:i,options:r},n?n.push(o):this.__on=[o]}}function Jte(e,t,r){var n=Kte(e+""),o,i=n.length,a;if(arguments.length<2){var s=this.node().__on;if(s){for(var c=0,u=s.length,d;c<u;++c)for(o=0,d=s[c];o<i;++o)if((a=n[o]).type===d.type&&a.name===d.name)return d.value}return}for(s=t?Zte:Xte,o=0;o<i;++o)this.each(s(n[o],t,r));return this}function Wz(e,t,r){var n=Bz(e),o=n.CustomEvent;typeof o=="function"?o=new o(t,r):(o=n.document.createEvent("Event"),r?(o.initEvent(t,r.bubbles,r.cancelable),o.detail=r.detail):o.initEvent(t,!1,!1)),e.dispatchEvent(o)}function Qte(e,t){return function(){return Wz(this,e,t)}}function ere(e,t){return function(){return Wz(this,e,t.apply(this,arguments))}}function tre(e,t){return this.each((typeof t=="function"?ere:Qte)(e,t))}function*rre(){for(var e=this._groups,t=0,r=e.length;t<r;++t)for(var n=e[t],o=0,i=n.length,a;o<i;++o)(a=n[o])&&(yield a)}var Uz=[null];function Yr(e,t){this._groups=e,this._parents=t}function Pl(){return new Yr([[document.documentElement]],Uz)}function nre(){return this}Yr.prototype=Pl.prototype={constructor:Yr,select:Iee,selectAll:kee,selectChild:Lee,selectChildren:Fee,filter:$ee,data:Yee,enter:Vee,exit:Xee,join:Zee,merge:Jee,selection:nre,order:Qee,sort:ete,call:rte,nodes:nte,node:ote,size:ite,empty:ate,each:ste,attr:hte,style:bte,property:_te,classed:Cte,text:Pte,html:Dte,raise:jte,lower:qte,append:zte,insert:Fte,remove:Vte,clone:Ute,datum:Gte,on:Jte,dispatch:tre,[Symbol.iterator]:rre};function Sn(e){return typeof e=="string"?new Yr([[document.querySelector(e)]],[document.documentElement]):new Yr([[e]],Uz)}function ore(e){let t;for(;t=e.sourceEvent;)e=t;return e}function Wn(e,t){if(e=ore(e),t===void 0&&(t=e.currentTarget),t){var r=t.ownerSVGElement||t;if(r.createSVGPoint){var n=r.createSVGPoint();return n.x=e.clientX,n.y=e.clientY,n=n.matrixTransform(t.getScreenCTM().inverse()),[n.x,n.y]}if(t.getBoundingClientRect){var o=t.getBoundingClientRect();return[e.clientX-o.left-t.clientLeft,e.clientY-o.top-t.clientTop]}}return[e.pageX,e.pageY]}const ire={passive:!1},ll={capture:!0,passive:!1};function Hy(e){e.stopImmediatePropagation()}function ha(e){e.preventDefault(),e.stopImmediatePropagation()}function Gz(e){var t=e.document.documentElement,r=Sn(e).on("dragstart.drag",ha,ll);"onselectstart"in t?r.on("selectstart.drag",ha,ll):(t.__noselect=t.style.MozUserSelect,t.style.MozUserSelect="none")}function Yz(e,t){var r=e.document.documentElement,n=Sn(e).on("dragstart.drag",null);t&&(n.on("click.drag",ha,ll),setTimeout(function(){n.on("click.drag",null)},0)),"onselectstart"in r?n.on("selectstart.drag",null):(r.style.MozUserSelect=r.__noselect,delete r.__noselect)}const eu=e=>()=>e;function g_(e,{sourceEvent:t,subject:r,target:n,identifier:o,active:i,x:a,y:s,dx:c,dy:u,dispatch:d}){Object.defineProperties(this,{type:{value:e,enumerable:!0,configurable:!0},sourceEvent:{value:t,enumerable:!0,configurable:!0},subject:{value:r,enumerable:!0,configurable:!0},target:{value:n,enumerable:!0,configurable:!0},identifier:{value:o,enumerable:!0,configurable:!0},active:{value:i,enumerable:!0,configurable:!0},x:{value:a,enumerable:!0,configurable:!0},y:{value:s,enumerable:!0,configurable:!0},dx:{value:c,enumerable:!0,configurable:!0},dy:{value:u,enumerable:!0,configurable:!0},_:{value:d}})}g_.prototype.on=function(){var e=this._.on.apply(this._,arguments);return e===this._?this:e};function are(e){return!e.ctrlKey&&!e.button}function sre(){return this.parentNode}function lre(e,t){return t??{x:e.x,y:e.y}}function cre(){return navigator.maxTouchPoints||"ontouchstart"in this}function ure(){var e=are,t=sre,r=lre,n=cre,o={},i=of("start","drag","end"),a=0,s,c,u,d,f=0;function h(S){S.on("mousedown.drag",v).filter(n).on("touchstart.drag",m).on("touchmove.drag",x,ire).on("touchend.drag touchcancel.drag",w).style("touch-action","none").style("-webkit-tap-highlight-color","rgba(0,0,0,0)")}function v(S,_){if(!(d||!e.call(this,S,_))){var C=E(this,t.call(this,S,_),S,_,"mouse");C&&(Sn(S.view).on("mousemove.drag",b,ll).on("mouseup.drag",g,ll),Gz(S.view),Hy(S),u=!1,s=S.clientX,c=S.clientY,C("start",S))}}function b(S){if(ha(S),!u){var _=S.clientX-s,C=S.clientY-c;u=_*_+C*C>f}o.mouse("drag",S)}function g(S){Sn(S.view).on("mousemove.drag mouseup.drag",null),Yz(S.view,u),ha(S),o.mouse("end",S)}function m(S,_){if(e.call(this,S,_)){var C=S.changedTouches,N=t.call(this,S,_),P=C.length,A,j;for(A=0;A<P;++A)(j=E(this,N,S,_,C[A].identifier,C[A]))&&(Hy(S),j("start",S,C[A]))}}function x(S){var _=S.changedTouches,C=_.length,N,P;for(N=0;N<C;++N)(P=o[_[N].identifier])&&(ha(S),P("drag",S,_[N]))}function w(S){var _=S.changedTouches,C=_.length,N,P;for(d&&clearTimeout(d),d=setTimeout(function(){d=null},500),N=0;N<C;++N)(P=o[_[N].identifier])&&(Hy(S),P("end",S,_[N]))}function E(S,_,C,N,P,A){var j=i.copy(),M=Wn(A||C,_),L,D,T;if((T=r.call(S,new g_("beforestart",{sourceEvent:C,target:h,identifier:P,active:a,x:M[0],y:M[1],dx:0,dy:0,dispatch:j}),N))!=null)return L=T.x-M[0]||0,D=T.y-M[1]||0,function W(q,G,F){var J=M,z;switch(q){case"start":o[P]=W,z=a++;break;case"end":delete o[P],--a;case"drag":M=Wn(F||G,_),z=a;break}j.call(q,S,new g_(q,{sourceEvent:G,subject:T,target:h,identifier:P,active:z,x:M[0]+L,y:M[1]+D,dx:M[0]-J[0],dy:M[1]-J[1],dispatch:j}),N)}}return h.filter=function(S){return arguments.length?(e=typeof S=="function"?S:eu(!!S),h):e},h.container=function(S){return arguments.length?(t=typeof S=="function"?S:eu(S),h):t},h.subject=function(S){return arguments.length?(r=typeof S=="function"?S:eu(S),h):r},h.touchable=function(S){return arguments.length?(n=typeof S=="function"?S:eu(!!S),h):n},h.on=function(){var S=i.on.apply(i,arguments);return S===i?h:S},h.clickDistance=function(S){return arguments.length?(f=(S=+S)*S,h):Math.sqrt(f)},h}function z1(e,t,r){e.prototype=t.prototype=r,r.constructor=e}function Kz(e,t){var r=Object.create(e.prototype);for(var n in t)r[n]=t[n];return r}function Tl(){}var cl=.7,od=1/cl,va="\\s*([+-]?\\d+)\\s*",ul="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)\\s*",Kn="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)%\\s*",dre=/^#([0-9a-f]{3,8})$/,fre=new RegExp(`^rgb\\(${va},${va},${va}\\)$`),pre=new RegExp(`^rgb\\(${Kn},${Kn},${Kn}\\)$`),hre=new RegExp(`^rgba\\(${va},${va},${va},${ul}\\)$`),vre=new RegExp(`^rgba\\(${Kn},${Kn},${Kn},${ul}\\)$`),gre=new RegExp(`^hsl\\(${ul},${Kn},${Kn}\\)$`),mre=new RegExp(`^hsla\\(${ul},${Kn},${Kn},${ul}\\)$`),$A={aliceblue:15792383,antiquewhite:16444375,aqua:65535,aquamarine:8388564,azure:15794175,beige:16119260,bisque:16770244,black:0,blanchedalmond:16772045,blue:255,blueviolet:9055202,brown:10824234,burlywood:14596231,cadetblue:6266528,chartreuse:8388352,chocolate:13789470,coral:16744272,cornflowerblue:6591981,cornsilk:16775388,crimson:14423100,cyan:65535,darkblue:139,darkcyan:35723,darkgoldenrod:12092939,darkgray:11119017,darkgreen:25600,darkgrey:11119017,darkkhaki:12433259,darkmagenta:9109643,darkolivegreen:5597999,darkorange:16747520,darkorchid:10040012,darkred:9109504,darksalmon:15308410,darkseagreen:9419919,darkslateblue:4734347,darkslategray:3100495,darkslategrey:3100495,darkturquoise:52945,darkviolet:9699539,deeppink:16716947,deepskyblue:49151,dimgray:6908265,dimgrey:6908265,dodgerblue:2003199,firebrick:11674146,floralwhite:16775920,forestgreen:2263842,fuchsia:16711935,gainsboro:14474460,ghostwhite:16316671,gold:16766720,goldenrod:14329120,gray:8421504,green:32768,greenyellow:11403055,grey:8421504,honeydew:15794160,hotpink:16738740,indianred:13458524,indigo:4915330,ivory:16777200,khaki:15787660,lavender:15132410,lavenderblush:16773365,lawngreen:8190976,lemonchiffon:16775885,lightblue:11393254,lightcoral:15761536,lightcyan:14745599,lightgoldenrodyellow:16448210,lightgray:13882323,lightgreen:9498256,lightgrey:13882323,lightpink:16758465,lightsalmon:16752762,lightseagreen:2142890,lightskyblue:8900346,lightslategray:7833753,lightslategrey:7833753,lightsteelblue:11584734,lightyellow:16777184,lime:65280,limegreen:3329330,linen:16445670,magenta:16711935,maroon:8388608,mediumaquamarine:6737322,mediumblue:205,mediumorchid:12211667,mediumpurple:9662683,mediumseagreen:3978097,mediumslateblue:8087790,mediumspringgreen:64154,mediumturquoise:4772300,mediumvioletred:13047173,midnightblue:1644912,mintcream:16121850,mistyrose:16770273,moccasin:16770229,navajowhite:16768685,navy:128,oldlace:16643558,olive:8421376,olivedrab:7048739,orange:16753920,orangered:16729344,orchid:14315734,palegoldenrod:15657130,palegreen:10025880,paleturquoise:11529966,palevioletred:14381203,papayawhip:16773077,peachpuff:16767673,peru:13468991,pink:16761035,plum:14524637,powderblue:11591910,purple:8388736,rebeccapurple:6697881,red:16711680,rosybrown:12357519,royalblue:4286945,saddlebrown:9127187,salmon:16416882,sandybrown:16032864,seagreen:3050327,seashell:16774638,sienna:10506797,silver:12632256,skyblue:8900331,slateblue:6970061,slategray:7372944,slategrey:7372944,snow:16775930,springgreen:65407,steelblue:4620980,tan:13808780,teal:32896,thistle:14204888,tomato:16737095,turquoise:4251856,violet:15631086,wheat:16113331,white:16777215,whitesmoke:16119285,yellow:16776960,yellowgreen:10145074};z1(Tl,dl,{copy(e){return Object.assign(new this.constructor,this,e)},displayable(){return this.rgb().displayable()},hex:VA,formatHex:VA,formatHex8:bre,formatHsl:yre,formatRgb:HA,toString:HA});function VA(){return this.rgb().formatHex()}function bre(){return this.rgb().formatHex8()}function yre(){return Xz(this).formatHsl()}function HA(){return this.rgb().formatRgb()}function dl(e){var t,r;return e=(e+"").trim().toLowerCase(),(t=dre.exec(e))?(r=t[1].length,t=parseInt(t[1],16),r===6?WA(t):r===3?new Pr(t>>8&15|t>>4&240,t>>4&15|t&240,(t&15)<<4|t&15,1):r===8?tu(t>>24&255,t>>16&255,t>>8&255,(t&255)/255):r===4?tu(t>>12&15|t>>8&240,t>>8&15|t>>4&240,t>>4&15|t&240,((t&15)<<4|t&15)/255):null):(t=fre.exec(e))?new Pr(t[1],t[2],t[3],1):(t=pre.exec(e))?new Pr(t[1]*255/100,t[2]*255/100,t[3]*255/100,1):(t=hre.exec(e))?tu(t[1],t[2],t[3],t[4]):(t=vre.exec(e))?tu(t[1]*255/100,t[2]*255/100,t[3]*255/100,t[4]):(t=gre.exec(e))?YA(t[1],t[2]/100,t[3]/100,1):(t=mre.exec(e))?YA(t[1],t[2]/100,t[3]/100,t[4]):$A.hasOwnProperty(e)?WA($A[e]):e==="transparent"?new Pr(NaN,NaN,NaN,0):null}function WA(e){return new Pr(e>>16&255,e>>8&255,e&255,1)}function tu(e,t,r,n){return n<=0&&(e=t=r=NaN),new Pr(e,t,r,n)}function xre(e){return e instanceof Tl||(e=dl(e)),e?(e=e.rgb(),new Pr(e.r,e.g,e.b,e.opacity)):new Pr}function m_(e,t,r,n){return arguments.length===1?xre(e):new Pr(e,t,r,n??1)}function Pr(e,t,r,n){this.r=+e,this.g=+t,this.b=+r,this.opacity=+n}z1(Pr,m_,Kz(Tl,{brighter(e){return e=e==null?od:Math.pow(od,e),new Pr(this.r*e,this.g*e,this.b*e,this.opacity)},darker(e){return e=e==null?cl:Math.pow(cl,e),new Pr(this.r*e,this.g*e,this.b*e,this.opacity)},rgb(){return this},clamp(){return new Pr(mi(this.r),mi(this.g),mi(this.b),id(this.opacity))},displayable(){return-.5<=this.r&&this.r<255.5&&-.5<=this.g&&this.g<255.5&&-.5<=this.b&&this.b<255.5&&0<=this.opacity&&this.opacity<=1},hex:UA,formatHex:UA,formatHex8:wre,formatRgb:GA,toString:GA}));function UA(){return`#${vi(this.r)}${vi(this.g)}${vi(this.b)}`}function wre(){return`#${vi(this.r)}${vi(this.g)}${vi(this.b)}${vi((isNaN(this.opacity)?1:this.opacity)*255)}`}function GA(){const e=id(this.opacity);return`${e===1?"rgb(":"rgba("}${mi(this.r)}, ${mi(this.g)}, ${mi(this.b)}${e===1?")":`, ${e})`}`}function id(e){return isNaN(e)?1:Math.max(0,Math.min(1,e))}function mi(e){return Math.max(0,Math.min(255,Math.round(e)||0))}function vi(e){return e=mi(e),(e<16?"0":"")+e.toString(16)}function YA(e,t,r,n){return n<=0?e=t=r=NaN:r<=0||r>=1?e=t=NaN:t<=0&&(e=NaN),new On(e,t,r,n)}function Xz(e){if(e instanceof On)return new On(e.h,e.s,e.l,e.opacity);if(e instanceof Tl||(e=dl(e)),!e)return new On;if(e instanceof On)return e;e=e.rgb();var t=e.r/255,r=e.g/255,n=e.b/255,o=Math.min(t,r,n),i=Math.max(t,r,n),a=NaN,s=i-o,c=(i+o)/2;return s?(t===i?a=(r-n)/s+(r<n)*6:r===i?a=(n-t)/s+2:a=(t-r)/s+4,s/=c<.5?i+o:2-i-o,a*=60):s=c>0&&c<1?0:a,new On(a,s,c,e.opacity)}function _re(e,t,r,n){return arguments.length===1?Xz(e):new On(e,t,r,n??1)}function On(e,t,r,n){this.h=+e,this.s=+t,this.l=+r,this.opacity=+n}z1(On,_re,Kz(Tl,{brighter(e){return e=e==null?od:Math.pow(od,e),new On(this.h,this.s,this.l*e,this.opacity)},darker(e){return e=e==null?cl:Math.pow(cl,e),new On(this.h,this.s,this.l*e,this.opacity)},rgb(){var e=this.h%360+(this.h<0)*360,t=isNaN(e)||isNaN(this.s)?0:this.s,r=this.l,n=r+(r<.5?r:1-r)*t,o=2*r-n;return new Pr(Wy(e>=240?e-240:e+120,o,n),Wy(e,o,n),Wy(e<120?e+240:e-120,o,n),this.opacity)},clamp(){return new On(KA(this.h),ru(this.s),ru(this.l),id(this.opacity))},displayable(){return(0<=this.s&&this.s<=1||isNaN(this.s))&&0<=this.l&&this.l<=1&&0<=this.opacity&&this.opacity<=1},formatHsl(){const e=id(this.opacity);return`${e===1?"hsl(":"hsla("}${KA(this.h)}, ${ru(this.s)*100}%, ${ru(this.l)*100}%${e===1?")":`, ${e})`}`}}));function KA(e){return e=(e||0)%360,e<0?e+360:e}function ru(e){return Math.max(0,Math.min(1,e||0))}function Wy(e,t,r){return(e<60?t+(r-t)*e/60:e<180?r:e<240?t+(r-t)*(240-e)/60:t)*255}const Zz=e=>()=>e;function Ere(e,t){return function(r){return e+r*t}}function Sre(e,t,r){return e=Math.pow(e,r),t=Math.pow(t,r)-e,r=1/r,function(n){return Math.pow(e+n*t,r)}}function Ore(e){return(e=+e)==1?Jz:function(t,r){return r-t?Sre(t,r,e):Zz(isNaN(t)?r:t)}}function Jz(e,t){var r=t-e;return r?Ere(e,r):Zz(isNaN(e)?t:e)}const XA=(function e(t){var r=Ore(t);function n(o,i){var a=r((o=m_(o)).r,(i=m_(i)).r),s=r(o.g,i.g),c=r(o.b,i.b),u=Jz(o.opacity,i.opacity);return function(d){return o.r=a(d),o.g=s(d),o.b=c(d),o.opacity=u(d),o+""}}return n.gamma=e,n})(1);function Ho(e,t){return e=+e,t=+t,function(r){return e*(1-r)+t*r}}var b_=/[-+]?(?:\d+\.?\d*|\.?\d+)(?:[eE][-+]?\d+)?/g,Uy=new RegExp(b_.source,"g");function Cre(e){return function(){return e}}function Rre(e){return function(t){return e(t)+""}}function Nre(e,t){var r=b_.lastIndex=Uy.lastIndex=0,n,o,i,a=-1,s=[],c=[];for(e=e+"",t=t+"";(n=b_.exec(e))&&(o=Uy.exec(t));)(i=o.index)>r&&(i=t.slice(r,i),s[a]?s[a]+=i:s[++a]=i),(n=n[0])===(o=o[0])?s[a]?s[a]+=o:s[++a]=o:(s[++a]=null,c.push({i:a,x:Ho(n,o)})),r=Uy.lastIndex;return r<t.length&&(i=t.slice(r),s[a]?s[a]+=i:s[++a]=i),s.length<2?c[0]?Rre(c[0].x):Cre(t):(t=c.length,function(u){for(var d=0,f;d<t;++d)s[(f=c[d]).i]=f.x(u);return s.join("")})}var ZA=180/Math.PI,y_={translateX:0,translateY:0,rotate:0,skewX:0,scaleX:1,scaleY:1};function Qz(e,t,r,n,o,i){var a,s,c;return(a=Math.sqrt(e*e+t*t))&&(e/=a,t/=a),(c=e*r+t*n)&&(r-=e*c,n-=t*c),(s=Math.sqrt(r*r+n*n))&&(r/=s,n/=s,c/=s),e*n<t*r&&(e=-e,t=-t,c=-c,a=-a),{translateX:o,translateY:i,rotate:Math.atan2(t,e)*ZA,skewX:Math.atan(c)*ZA,scaleX:a,scaleY:s}}var nu;function Ire(e){const t=new(typeof DOMMatrix=="function"?DOMMatrix:WebKitCSSMatrix)(e+"");return t.isIdentity?y_:Qz(t.a,t.b,t.c,t.d,t.e,t.f)}function Pre(e){return e==null||(nu||(nu=document.createElementNS("http://www.w3.org/2000/svg","g")),nu.setAttribute("transform",e),!(e=nu.transform.baseVal.consolidate()))?y_:(e=e.matrix,Qz(e.a,e.b,e.c,e.d,e.e,e.f))}function eB(e,t,r,n){function o(u){return u.length?u.pop()+" ":""}function i(u,d,f,h,v,b){if(u!==f||d!==h){var g=v.push("translate(",null,t,null,r);b.push({i:g-4,x:Ho(u,f)},{i:g-2,x:Ho(d,h)})}else(f||h)&&v.push("translate("+f+t+h+r)}function a(u,d,f,h){u!==d?(u-d>180?d+=360:d-u>180&&(u+=360),h.push({i:f.push(o(f)+"rotate(",null,n)-2,x:Ho(u,d)})):d&&f.push(o(f)+"rotate("+d+n)}function s(u,d,f,h){u!==d?h.push({i:f.push(o(f)+"skewX(",null,n)-2,x:Ho(u,d)}):d&&f.push(o(f)+"skewX("+d+n)}function c(u,d,f,h,v,b){if(u!==f||d!==h){var g=v.push(o(v)+"scale(",null,",",null,")");b.push({i:g-4,x:Ho(u,f)},{i:g-2,x:Ho(d,h)})}else(f!==1||h!==1)&&v.push(o(v)+"scale("+f+","+h+")")}return function(u,d){var f=[],h=[];return u=e(u),d=e(d),i(u.translateX,u.translateY,d.translateX,d.translateY,f,h),a(u.rotate,d.rotate,f,h),s(u.skewX,d.skewX,f,h),c(u.scaleX,u.scaleY,d.scaleX,d.scaleY,f,h),u=d=null,function(v){for(var b=-1,g=h.length,m;++b<g;)f[(m=h[b]).i]=m.x(v);return f.join("")}}}var Tre=eB(Ire,"px, ","px)","deg)"),Are=eB(Pre,", ",")",")"),kre=1e-12;function JA(e){return((e=Math.exp(e))+1/e)/2}function Dre(e){return((e=Math.exp(e))-1/e)/2}function Mre(e){return((e=Math.exp(2*e))-1)/(e+1)}const jre=(function e(t,r,n){function o(i,a){var s=i[0],c=i[1],u=i[2],d=a[0],f=a[1],h=a[2],v=d-s,b=f-c,g=v*v+b*b,m,x;if(g<kre)x=Math.log(h/u)/t,m=function(N){return[s+N*v,c+N*b,u*Math.exp(t*N*x)]};else{var w=Math.sqrt(g),E=(h*h-u*u+n*g)/(2*u*r*w),S=(h*h-u*u-n*g)/(2*h*r*w),_=Math.log(Math.sqrt(E*E+1)-E),C=Math.log(Math.sqrt(S*S+1)-S);x=(C-_)/t,m=function(N){var P=N*x,A=JA(_),j=u/(r*w)*(A*Mre(t*P+_)-Dre(_));return[s+j*v,c+j*b,u*A/JA(t*P+_)]}}return m.duration=x*1e3*t/Math.SQRT2,m}return o.rho=function(i){var a=Math.max(.001,+i),s=a*a,c=s*s;return e(a,s,c)},o})(Math.SQRT2,2,4);var Na=0,Vs=0,ys=0,tB=1e3,ad,Hs,sd=0,Ei=0,sf=0,fl=typeof performance=="object"&&performance.now?performance:Date,rB=typeof window=="object"&&window.requestAnimationFrame?window.requestAnimationFrame.bind(window):function(e){setTimeout(e,17)};function B1(){return Ei||(rB(Lre),Ei=fl.now()+sf)}function Lre(){Ei=0}function ld(){this._call=this._time=this._next=null}ld.prototype=nB.prototype={constructor:ld,restart:function(e,t,r){if(typeof e!="function")throw new TypeError("callback is not a function");r=(r==null?B1():+r)+(t==null?0:+t),!this._next&&Hs!==this&&(Hs?Hs._next=this:ad=this,Hs=this),this._call=e,this._time=r,x_()},stop:function(){this._call&&(this._call=null,this._time=1/0,x_())}};function nB(e,t,r){var n=new ld;return n.restart(e,t,r),n}function qre(){B1(),++Na;for(var e=ad,t;e;)(t=Ei-e._time)>=0&&e._call.call(void 0,t),e=e._next;--Na}function QA(){Ei=(sd=fl.now())+sf,Na=Vs=0;try{qre()}finally{Na=0,Bre(),Ei=0}}function zre(){var e=fl.now(),t=e-sd;t>tB&&(sf-=t,sd=e)}function Bre(){for(var e,t=ad,r,n=1/0;t;)t._call?(n>t._time&&(n=t._time),e=t,t=t._next):(r=t._next,t._next=null,t=e?e._next=r:ad=r);Hs=e,x_(n)}function x_(e){if(!Na){Vs&&(Vs=clearTimeout(Vs));var t=e-Ei;t>24?(e<1/0&&(Vs=setTimeout(QA,e-fl.now()-sf)),ys&&(ys=clearInterval(ys))):(ys||(sd=fl.now(),ys=setInterval(zre,tB)),Na=1,rB(QA))}}function ek(e,t,r){var n=new ld;return t=t==null?0:+t,n.restart(o=>{n.stop(),e(o+t)},t,r),n}var Fre=of("start","end","cancel","interrupt"),$re=[],oB=0,tk=1,w_=2,Mu=3,rk=4,__=5,ju=6;function lf(e,t,r,n,o,i){var a=e.__transition;if(!a)e.__transition={};else if(r in a)return;Vre(e,r,{name:t,index:n,group:o,on:Fre,tween:$re,time:i.time,delay:i.delay,duration:i.duration,ease:i.ease,timer:null,state:oB})}function F1(e,t){var r=Mn(e,t);if(r.state>oB)throw new Error("too late; already scheduled");return r}function to(e,t){var r=Mn(e,t);if(r.state>Mu)throw new Error("too late; already running");return r}function Mn(e,t){var r=e.__transition;if(!r||!(r=r[t]))throw new Error("transition not found");return r}function Vre(e,t,r){var n=e.__transition,o;n[t]=r,r.timer=nB(i,0,r.time);function i(u){r.state=tk,r.timer.restart(a,r.delay,r.time),r.delay<=u&&a(u-r.delay)}function a(u){var d,f,h,v;if(r.state!==tk)return c();for(d in n)if(v=n[d],v.name===r.name){if(v.state===Mu)return ek(a);v.state===rk?(v.state=ju,v.timer.stop(),v.on.call("interrupt",e,e.__data__,v.index,v.group),delete n[d]):+d<t&&(v.state=ju,v.timer.stop(),v.on.call("cancel",e,e.__data__,v.index,v.group),delete n[d])}if(ek(function(){r.state===Mu&&(r.state=rk,r.timer.restart(s,r.delay,r.time),s(u))}),r.state=w_,r.on.call("start",e,e.__data__,r.index,r.group),r.state===w_){for(r.state=Mu,o=new Array(h=r.tween.length),d=0,f=-1;d<h;++d)(v=r.tween[d].value.call(e,e.__data__,r.index,r.group))&&(o[++f]=v);o.length=f+1}}function s(u){for(var d=u<r.duration?r.ease.call(null,u/r.duration):(r.timer.restart(c),r.state=__,1),f=-1,h=o.length;++f<h;)o[f].call(e,d);r.state===__&&(r.on.call("end",e,e.__data__,r.index,r.group),c())}function c(){r.state=ju,r.timer.stop(),delete n[t];for(var u in n)return;delete e.__transition}}function Lu(e,t){var r=e.__transition,n,o,i=!0,a;if(r){t=t==null?null:t+"";for(a in r){if((n=r[a]).name!==t){i=!1;continue}o=n.state>w_&&n.state<__,n.state=ju,n.timer.stop(),n.on.call(o?"interrupt":"cancel",e,e.__data__,n.index,n.group),delete r[a]}i&&delete e.__transition}}function Hre(e){return this.each(function(){Lu(this,e)})}function Wre(e,t){var r,n;return function(){var o=to(this,e),i=o.tween;if(i!==r){n=r=i;for(var a=0,s=n.length;a<s;++a)if(n[a].name===t){n=n.slice(),n.splice(a,1);break}}o.tween=n}}function Ure(e,t,r){var n,o;if(typeof r!="function")throw new Error;return function(){var i=to(this,e),a=i.tween;if(a!==n){o=(n=a).slice();for(var s={name:t,value:r},c=0,u=o.length;c<u;++c)if(o[c].name===t){o[c]=s;break}c===u&&o.push(s)}i.tween=o}}function Gre(e,t){var r=this._id;if(e+="",arguments.length<2){for(var n=Mn(this.node(),r).tween,o=0,i=n.length,a;o<i;++o)if((a=n[o]).name===e)return a.value;return null}return this.each((t==null?Wre:Ure)(r,e,t))}function $1(e,t,r){var n=e._id;return e.each(function(){var o=to(this,n);(o.value||(o.value={}))[t]=r.apply(this,arguments)}),function(o){return Mn(o,n).value[t]}}function iB(e,t){var r;return(typeof t=="number"?Ho:t instanceof dl?XA:(r=dl(t))?(t=r,XA):Nre)(e,t)}function Yre(e){return function(){this.removeAttribute(e)}}function Kre(e){return function(){this.removeAttributeNS(e.space,e.local)}}function Xre(e,t,r){var n,o=r+"",i;return function(){var a=this.getAttribute(e);return a===o?null:a===n?i:i=t(n=a,r)}}function Zre(e,t,r){var n,o=r+"",i;return function(){var a=this.getAttributeNS(e.space,e.local);return a===o?null:a===n?i:i=t(n=a,r)}}function Jre(e,t,r){var n,o,i;return function(){var a,s=r(this),c;return s==null?void this.removeAttribute(e):(a=this.getAttribute(e),c=s+"",a===c?null:a===n&&c===o?i:(o=c,i=t(n=a,s)))}}function Qre(e,t,r){var n,o,i;return function(){var a,s=r(this),c;return s==null?void this.removeAttributeNS(e.space,e.local):(a=this.getAttributeNS(e.space,e.local),c=s+"",a===c?null:a===n&&c===o?i:(o=c,i=t(n=a,s)))}}function ene(e,t){var r=af(e),n=r==="transform"?Are:iB;return this.attrTween(e,typeof t=="function"?(r.local?Qre:Jre)(r,n,$1(this,"attr."+e,t)):t==null?(r.local?Kre:Yre)(r):(r.local?Zre:Xre)(r,n,t))}function tne(e,t){return function(r){this.setAttribute(e,t.call(this,r))}}function rne(e,t){return function(r){this.setAttributeNS(e.space,e.local,t.call(this,r))}}function nne(e,t){var r,n;function o(){var i=t.apply(this,arguments);return i!==n&&(r=(n=i)&&rne(e,i)),r}return o._value=t,o}function one(e,t){var r,n;function o(){var i=t.apply(this,arguments);return i!==n&&(r=(n=i)&&tne(e,i)),r}return o._value=t,o}function ine(e,t){var r="attr."+e;if(arguments.length<2)return(r=this.tween(r))&&r._value;if(t==null)return this.tween(r,null);if(typeof t!="function")throw new Error;var n=af(e);return this.tween(r,(n.local?nne:one)(n,t))}function ane(e,t){return function(){F1(this,e).delay=+t.apply(this,arguments)}}function sne(e,t){return t=+t,function(){F1(this,e).delay=t}}function lne(e){var t=this._id;return arguments.length?this.each((typeof e=="function"?ane:sne)(t,e)):Mn(this.node(),t).delay}function cne(e,t){return function(){to(this,e).duration=+t.apply(this,arguments)}}function une(e,t){return t=+t,function(){to(this,e).duration=t}}function dne(e){var t=this._id;return arguments.length?this.each((typeof e=="function"?cne:une)(t,e)):Mn(this.node(),t).duration}function fne(e,t){if(typeof t!="function")throw new Error;return function(){to(this,e).ease=t}}function pne(e){var t=this._id;return arguments.length?this.each(fne(t,e)):Mn(this.node(),t).ease}function hne(e,t){return function(){var r=t.apply(this,arguments);if(typeof r!="function")throw new Error;to(this,e).ease=r}}function vne(e){if(typeof e!="function")throw new Error;return this.each(hne(this._id,e))}function gne(e){typeof e!="function"&&(e=Lz(e));for(var t=this._groups,r=t.length,n=new Array(r),o=0;o<r;++o)for(var i=t[o],a=i.length,s=n[o]=[],c,u=0;u<a;++u)(c=i[u])&&e.call(c,c.__data__,u,i)&&s.push(c);return new xo(n,this._parents,this._name,this._id)}function mne(e){if(e._id!==this._id)throw new Error;for(var t=this._groups,r=e._groups,n=t.length,o=r.length,i=Math.min(n,o),a=new Array(n),s=0;s<i;++s)for(var c=t[s],u=r[s],d=c.length,f=a[s]=new Array(d),h,v=0;v<d;++v)(h=c[v]||u[v])&&(f[v]=h);for(;s<n;++s)a[s]=t[s];return new xo(a,this._parents,this._name,this._id)}function bne(e){return(e+"").trim().split(/^|\s+/).every(function(t){var r=t.indexOf(".");return r>=0&&(t=t.slice(0,r)),!t||t==="start"})}function yne(e,t,r){var n,o,i=bne(t)?F1:to;return function(){var a=i(this,e),s=a.on;s!==n&&(o=(n=s).copy()).on(t,r),a.on=o}}function xne(e,t){var r=this._id;return arguments.length<2?Mn(this.node(),r).on.on(e):this.each(yne(r,e,t))}function wne(e){return function(){var t=this.parentNode;for(var r in this.__transition)if(+r!==e)return;t&&t.removeChild(this)}}function _ne(){return this.on("end.remove",wne(this._id))}function Ene(e){var t=this._name,r=this._id;typeof e!="function"&&(e=L1(e));for(var n=this._groups,o=n.length,i=new Array(o),a=0;a<o;++a)for(var s=n[a],c=s.length,u=i[a]=new Array(c),d,f,h=0;h<c;++h)(d=s[h])&&(f=e.call(d,d.__data__,h,s))&&("__data__"in d&&(f.__data__=d.__data__),u[h]=f,lf(u[h],t,r,h,u,Mn(d,r)));return new xo(i,this._parents,t,r)}function Sne(e){var t=this._name,r=this._id;typeof e!="function"&&(e=jz(e));for(var n=this._groups,o=n.length,i=[],a=[],s=0;s<o;++s)for(var c=n[s],u=c.length,d,f=0;f<u;++f)if(d=c[f]){for(var h=e.call(d,d.__data__,f,c),v,b=Mn(d,r),g=0,m=h.length;g<m;++g)(v=h[g])&&lf(v,t,r,g,h,b);i.push(h),a.push(d)}return new xo(i,a,t,r)}var One=Pl.prototype.constructor;function Cne(){return new One(this._groups,this._parents)}function Rne(e,t){var r,n,o;return function(){var i=Ra(this,e),a=(this.style.removeProperty(e),Ra(this,e));return i===a?null:i===r&&a===n?o:o=t(r=i,n=a)}}function aB(e){return function(){this.style.removeProperty(e)}}function Nne(e,t,r){var n,o=r+"",i;return function(){var a=Ra(this,e);return a===o?null:a===n?i:i=t(n=a,r)}}function Ine(e,t,r){var n,o,i;return function(){var a=Ra(this,e),s=r(this),c=s+"";return s==null&&(c=s=(this.style.removeProperty(e),Ra(this,e))),a===c?null:a===n&&c===o?i:(o=c,i=t(n=a,s))}}function Pne(e,t){var r,n,o,i="style."+t,a="end."+i,s;return function(){var c=to(this,e),u=c.on,d=c.value[i]==null?s||(s=aB(t)):void 0;(u!==r||o!==d)&&(n=(r=u).copy()).on(a,o=d),c.on=n}}function Tne(e,t,r){var n=(e+="")=="transform"?Tre:iB;return t==null?this.styleTween(e,Rne(e,n)).on("end.style."+e,aB(e)):typeof t=="function"?this.styleTween(e,Ine(e,n,$1(this,"style."+e,t))).each(Pne(this._id,e)):this.styleTween(e,Nne(e,n,t),r).on("end.style."+e,null)}function Ane(e,t,r){return function(n){this.style.setProperty(e,t.call(this,n),r)}}function kne(e,t,r){var n,o;function i(){var a=t.apply(this,arguments);return a!==o&&(n=(o=a)&&Ane(e,a,r)),n}return i._value=t,i}function Dne(e,t,r){var n="style."+(e+="");if(arguments.length<2)return(n=this.tween(n))&&n._value;if(t==null)return this.tween(n,null);if(typeof t!="function")throw new Error;return this.tween(n,kne(e,t,r??""))}function Mne(e){return function(){this.textContent=e}}function jne(e){return function(){var t=e(this);this.textContent=t??""}}function Lne(e){return this.tween("text",typeof e=="function"?jne($1(this,"text",e)):Mne(e==null?"":e+""))}function qne(e){return function(t){this.textContent=e.call(this,t)}}function zne(e){var t,r;function n(){var o=e.apply(this,arguments);return o!==r&&(t=(r=o)&&qne(o)),t}return n._value=e,n}function Bne(e){var t="text";if(arguments.length<1)return(t=this.tween(t))&&t._value;if(e==null)return this.tween(t,null);if(typeof e!="function")throw new Error;return this.tween(t,zne(e))}function Fne(){for(var e=this._name,t=this._id,r=sB(),n=this._groups,o=n.length,i=0;i<o;++i)for(var a=n[i],s=a.length,c,u=0;u<s;++u)if(c=a[u]){var d=Mn(c,t);lf(c,e,r,u,a,{time:d.time+d.delay+d.duration,delay:0,duration:d.duration,ease:d.ease})}return new xo(n,this._parents,e,r)}function $ne(){var e,t,r=this,n=r._id,o=r.size();return new Promise(function(i,a){var s={value:a},c={value:function(){--o===0&&i()}};r.each(function(){var u=to(this,n),d=u.on;d!==e&&(t=(e=d).copy(),t._.cancel.push(s),t._.interrupt.push(s),t._.end.push(c)),u.on=t}),o===0&&i()})}var Vne=0;function xo(e,t,r,n){this._groups=e,this._parents=t,this._name=r,this._id=n}function sB(){return++Vne}var vo=Pl.prototype;xo.prototype={constructor:xo,select:Ene,selectAll:Sne,selectChild:vo.selectChild,selectChildren:vo.selectChildren,filter:gne,merge:mne,selection:Cne,transition:Fne,call:vo.call,nodes:vo.nodes,node:vo.node,size:vo.size,empty:vo.empty,each:vo.each,on:xne,attr:ene,attrTween:ine,style:Tne,styleTween:Dne,text:Lne,textTween:Bne,remove:_ne,tween:Gre,delay:lne,duration:dne,ease:pne,easeVarying:vne,end:$ne,[Symbol.iterator]:vo[Symbol.iterator]};function Hne(e){return((e*=2)<=1?e*e*e:(e-=2)*e*e+2)/2}var Wne={time:null,delay:0,duration:250,ease:Hne};function Une(e,t){for(var r;!(r=e.__transition)||!(r=r[t]);)if(!(e=e.parentNode))throw new Error(`transition ${t} not found`);return r}function Gne(e){var t,r;e instanceof xo?(t=e._id,e=e._name):(t=sB(),(r=Wne).time=B1(),e=e==null?null:e+"");for(var n=this._groups,o=n.length,i=0;i<o;++i)for(var a=n[i],s=a.length,c,u=0;u<s;++u)(c=a[u])&&lf(c,e,t,u,a,r||Une(c,t));return new xo(n,this._parents,e,t)}Pl.prototype.interrupt=Hre;Pl.prototype.transition=Gne;const ou=e=>()=>e;function Yne(e,{sourceEvent:t,target:r,transform:n,dispatch:o}){Object.defineProperties(this,{type:{value:e,enumerable:!0,configurable:!0},sourceEvent:{value:t,enumerable:!0,configurable:!0},target:{value:r,enumerable:!0,configurable:!0},transform:{value:n,enumerable:!0,configurable:!0},_:{value:o}})}function bo(e,t,r){this.k=e,this.x=t,this.y=r}bo.prototype={constructor:bo,scale:function(e){return e===1?this:new bo(this.k*e,this.x,this.y)},translate:function(e,t){return e===0&t===0?this:new bo(this.k,this.x+this.k*e,this.y+this.k*t)},apply:function(e){return[e[0]*this.k+this.x,e[1]*this.k+this.y]},applyX:function(e){return e*this.k+this.x},applyY:function(e){return e*this.k+this.y},invert:function(e){return[(e[0]-this.x)/this.k,(e[1]-this.y)/this.k]},invertX:function(e){return(e-this.x)/this.k},invertY:function(e){return(e-this.y)/this.k},rescaleX:function(e){return e.copy().domain(e.range().map(this.invertX,this).map(e.invert,e))},rescaleY:function(e){return e.copy().domain(e.range().map(this.invertY,this).map(e.invert,e))},toString:function(){return"translate("+this.x+","+this.y+") scale("+this.k+")"}};var bi=new bo(1,0,0);bo.prototype;function Gy(e){e.stopImmediatePropagation()}function xs(e){e.preventDefault(),e.stopImmediatePropagation()}function Kne(e){return(!e.ctrlKey||e.type==="wheel")&&!e.button}function Xne(){var e=this;return e instanceof SVGElement?(e=e.ownerSVGElement||e,e.hasAttribute("viewBox")?(e=e.viewBox.baseVal,[[e.x,e.y],[e.x+e.width,e.y+e.height]]):[[0,0],[e.width.baseVal.value,e.height.baseVal.value]]):[[0,0],[e.clientWidth,e.clientHeight]]}function nk(){return this.__zoom||bi}function Zne(e){return-e.deltaY*(e.deltaMode===1?.05:e.deltaMode?1:.002)*(e.ctrlKey?10:1)}function Jne(){return navigator.maxTouchPoints||"ontouchstart"in this}function Qne(e,t,r){var n=e.invertX(t[0][0])-r[0][0],o=e.invertX(t[1][0])-r[1][0],i=e.invertY(t[0][1])-r[0][1],a=e.invertY(t[1][1])-r[1][1];return e.translate(o>n?(n+o)/2:Math.min(0,n)||Math.max(0,o),a>i?(i+a)/2:Math.min(0,i)||Math.max(0,a))}function eoe(){var e=Kne,t=Xne,r=Qne,n=Zne,o=Jne,i=[0,1/0],a=[[-1/0,-1/0],[1/0,1/0]],s=250,c=jre,u=of("start","zoom","end"),d,f,h,v=500,b=150,g=0,m=10;function x(T){T.property("__zoom",nk).on("wheel.zoom",P,{passive:!1}).on("mousedown.zoom",A).on("dblclick.zoom",j).filter(o).on("touchstart.zoom",M).on("touchmove.zoom",L).on("touchend.zoom touchcancel.zoom",D).style("-webkit-tap-highlight-color","rgba(0,0,0,0)")}x.transform=function(T,W,q,G){var F=T.selection?T.selection():T;F.property("__zoom",nk),T!==F?_(T,W,q,G):F.interrupt().each(function(){C(this,arguments).event(G).start().zoom(null,typeof W=="function"?W.apply(this,arguments):W).end()})},x.scaleBy=function(T,W,q,G){x.scaleTo(T,function(){var F=this.__zoom.k,J=typeof W=="function"?W.apply(this,arguments):W;return F*J},q,G)},x.scaleTo=function(T,W,q,G){x.transform(T,function(){var F=t.apply(this,arguments),J=this.__zoom,z=q==null?S(F):typeof q=="function"?q.apply(this,arguments):q,U=J.invert(z),oe=typeof W=="function"?W.apply(this,arguments):W;return r(E(w(J,oe),z,U),F,a)},q,G)},x.translateBy=function(T,W,q,G){x.transform(T,function(){return r(this.__zoom.translate(typeof W=="function"?W.apply(this,arguments):W,typeof q=="function"?q.apply(this,arguments):q),t.apply(this,arguments),a)},null,G)},x.translateTo=function(T,W,q,G,F){x.transform(T,function(){var J=t.apply(this,arguments),z=this.__zoom,U=G==null?S(J):typeof G=="function"?G.apply(this,arguments):G;return r(bi.translate(U[0],U[1]).scale(z.k).translate(typeof W=="function"?-W.apply(this,arguments):-W,typeof q=="function"?-q.apply(this,arguments):-q),J,a)},G,F)};function w(T,W){return W=Math.max(i[0],Math.min(i[1],W)),W===T.k?T:new bo(W,T.x,T.y)}function E(T,W,q){var G=W[0]-q[0]*T.k,F=W[1]-q[1]*T.k;return G===T.x&&F===T.y?T:new bo(T.k,G,F)}function S(T){return[(+T[0][0]+ +T[1][0])/2,(+T[0][1]+ +T[1][1])/2]}function _(T,W,q,G){T.on("start.zoom",function(){C(this,arguments).event(G).start()}).on("interrupt.zoom end.zoom",function(){C(this,arguments).event(G).end()}).tween("zoom",function(){var F=this,J=arguments,z=C(F,J).event(G),U=t.apply(F,J),oe=q==null?S(U):typeof q=="function"?q.apply(F,J):q,re=Math.max(U[1][0]-U[0][0],U[1][1]-U[0][1]),$=F.__zoom,Y=typeof W=="function"?W.apply(F,J):W,X=c($.invert(oe).concat(re/$.k),Y.invert(oe).concat(re/Y.k));return function(H){if(H===1)H=Y;else{var K=X(H),Q=re/K[2];H=new bo(Q,oe[0]-K[0]*Q,oe[1]-K[1]*Q)}z.zoom(null,H)}})}function C(T,W,q){return!q&&T.__zooming||new N(T,W)}function N(T,W){this.that=T,this.args=W,this.active=0,this.sourceEvent=null,this.extent=t.apply(T,W),this.taps=0}N.prototype={event:function(T){return T&&(this.sourceEvent=T),this},start:function(){return++this.active===1&&(this.that.__zooming=this,this.emit("start")),this},zoom:function(T,W){return this.mouse&&T!=="mouse"&&(this.mouse[1]=W.invert(this.mouse[0])),this.touch0&&T!=="touch"&&(this.touch0[1]=W.invert(this.touch0[0])),this.touch1&&T!=="touch"&&(this.touch1[1]=W.invert(this.touch1[0])),this.that.__zoom=W,this.emit("zoom"),this},end:function(){return--this.active===0&&(delete this.that.__zooming,this.emit("end")),this},emit:function(T){var W=Sn(this.that).datum();u.call(T,this.that,new Yne(T,{sourceEvent:this.sourceEvent,target:x,transform:this.that.__zoom,dispatch:u}),W)}};function P(T,...W){if(!e.apply(this,arguments))return;var q=C(this,W).event(T),G=this.__zoom,F=Math.max(i[0],Math.min(i[1],G.k*Math.pow(2,n.apply(this,arguments)))),J=Wn(T);if(q.wheel)(q.mouse[0][0]!==J[0]||q.mouse[0][1]!==J[1])&&(q.mouse[1]=G.invert(q.mouse[0]=J)),clearTimeout(q.wheel);else{if(G.k===F)return;q.mouse=[J,G.invert(J)],Lu(this),q.start()}xs(T),q.wheel=setTimeout(z,b),q.zoom("mouse",r(E(w(G,F),q.mouse[0],q.mouse[1]),q.extent,a));function z(){q.wheel=null,q.end()}}function A(T,...W){if(h||!e.apply(this,arguments))return;var q=T.currentTarget,G=C(this,W,!0).event(T),F=Sn(T.view).on("mousemove.zoom",oe,!0).on("mouseup.zoom",re,!0),J=Wn(T,q),z=T.clientX,U=T.clientY;Gz(T.view),Gy(T),G.mouse=[J,this.__zoom.invert(J)],Lu(this),G.start();function oe($){if(xs($),!G.moved){var Y=$.clientX-z,X=$.clientY-U;G.moved=Y*Y+X*X>g}G.event($).zoom("mouse",r(E(G.that.__zoom,G.mouse[0]=Wn($,q),G.mouse[1]),G.extent,a))}function re($){F.on("mousemove.zoom mouseup.zoom",null),Yz($.view,G.moved),xs($),G.event($).end()}}function j(T,...W){if(e.apply(this,arguments)){var q=this.__zoom,G=Wn(T.changedTouches?T.changedTouches[0]:T,this),F=q.invert(G),J=q.k*(T.shiftKey?.5:2),z=r(E(w(q,J),G,F),t.apply(this,W),a);xs(T),s>0?Sn(this).transition().duration(s).call(_,z,G,T):Sn(this).call(x.transform,z,G,T)}}function M(T,...W){if(e.apply(this,arguments)){var q=T.touches,G=q.length,F=C(this,W,T.changedTouches.length===G).event(T),J,z,U,oe;for(Gy(T),z=0;z<G;++z)U=q[z],oe=Wn(U,this),oe=[oe,this.__zoom.invert(oe),U.identifier],F.touch0?!F.touch1&&F.touch0[2]!==oe[2]&&(F.touch1=oe,F.taps=0):(F.touch0=oe,J=!0,F.taps=1+!!d);d&&(d=clearTimeout(d)),J&&(F.taps<2&&(f=oe[0],d=setTimeout(function(){d=null},v)),Lu(this),F.start())}}function L(T,...W){if(this.__zooming){var q=C(this,W).event(T),G=T.changedTouches,F=G.length,J,z,U,oe;for(xs(T),J=0;J<F;++J)z=G[J],U=Wn(z,this),q.touch0&&q.touch0[2]===z.identifier?q.touch0[0]=U:q.touch1&&q.touch1[2]===z.identifier&&(q.touch1[0]=U);if(z=q.that.__zoom,q.touch1){var re=q.touch0[0],$=q.touch0[1],Y=q.touch1[0],X=q.touch1[1],H=(H=Y[0]-re[0])*H+(H=Y[1]-re[1])*H,K=(K=X[0]-$[0])*K+(K=X[1]-$[1])*K;z=w(z,Math.sqrt(H/K)),U=[(re[0]+Y[0])/2,(re[1]+Y[1])/2],oe=[($[0]+X[0])/2,($[1]+X[1])/2]}else if(q.touch0)U=q.touch0[0],oe=q.touch0[1];else return;q.zoom("touch",r(E(z,U,oe),q.extent,a))}}function D(T,...W){if(this.__zooming){var q=C(this,W).event(T),G=T.changedTouches,F=G.length,J,z;for(Gy(T),h&&clearTimeout(h),h=setTimeout(function(){h=null},v),J=0;J<F;++J)z=G[J],q.touch0&&q.touch0[2]===z.identifier?delete q.touch0:q.touch1&&q.touch1[2]===z.identifier&&delete q.touch1;if(q.touch1&&!q.touch0&&(q.touch0=q.touch1,delete q.touch1),q.touch0)q.touch0[1]=this.__zoom.invert(q.touch0[0]);else if(q.end(),q.taps===2&&(z=Wn(z,this),Math.hypot(f[0]-z[0],f[1]-z[1])<m)){var U=Sn(this).on("dblclick.zoom");U&&U.apply(this,arguments)}}}return x.wheelDelta=function(T){return arguments.length?(n=typeof T=="function"?T:ou(+T),x):n},x.filter=function(T){return arguments.length?(e=typeof T=="function"?T:ou(!!T),x):e},x.touchable=function(T){return arguments.length?(o=typeof T=="function"?T:ou(!!T),x):o},x.extent=function(T){return arguments.length?(t=typeof T=="function"?T:ou([[+T[0][0],+T[0][1]],[+T[1][0],+T[1][1]]]),x):t},x.scaleExtent=function(T){return arguments.length?(i[0]=+T[0],i[1]=+T[1],x):[i[0],i[1]]},x.translateExtent=function(T){return arguments.length?(a[0][0]=+T[0][0],a[1][0]=+T[1][0],a[0][1]=+T[0][1],a[1][1]=+T[1][1],x):[[a[0][0],a[0][1]],[a[1][0],a[1][1]]]},x.constrain=function(T){return arguments.length?(r=T,x):r},x.duration=function(T){return arguments.length?(s=+T,x):s},x.interpolate=function(T){return arguments.length?(c=T,x):c},x.on=function(){var T=u.on.apply(u,arguments);return T===u?x:T},x.clickDistance=function(T){return arguments.length?(g=(T=+T)*T,x):Math.sqrt(g)},x.tapDistance=function(T){return arguments.length?(m=+T,x):m},x}function et(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function E_(e,t){(t==null||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r<t;r++)n[r]=e[r];return n}function lB(e,t){if(e){if(typeof e=="string")return E_(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if(r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set")return Array.from(e);if(r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return E_(e,t)}}function toe(e){if(Array.isArray(e))return e}function roe(e,t){var r=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(r!=null){var n=[],o=!0,i=!1,a,s;try{for(r=r.call(e);!(o=(a=r.next()).done)&&(n.push(a.value),!(t&&n.length===t));o=!0);}catch(c){i=!0,s=c}finally{try{!o&&r.return!=null&&r.return()}finally{if(i)throw s}}return n}}function noe(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
54
|
+
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Ge(e,t){return toe(e)||roe(e,t)||lB(e,t)||noe()}var Ia;(function(e){e.Strict="strict",e.Loose="loose"})(Ia||(Ia={}));var Si;(function(e){e.Lines="lines",e.Dots="dots"})(Si||(Si={}));var ga;(function(e){e.Free="free",e.Vertical="vertical",e.Horizontal="horizontal"})(ga||(ga={}));var Uo;(function(e){e.Bezier="default",e.Straight="straight",e.Step="step",e.SmoothStep="smoothstep",e.SimpleBezier="simplebezier"})(Uo||(Uo={}));var cd;(function(e){e.Arrow="arrow",e.ArrowClosed="arrowclosed"})(cd||(cd={}));var Oe;(function(e){e.Left="left",e.Top="top",e.Right="right",e.Bottom="bottom"})(Oe||(Oe={}));var V1=function(t){return{width:t.offsetWidth,height:t.offsetHeight}},ma=function(t){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0,n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:1;return Math.min(Math.max(t,r),n)},cB=function(t,r){return{x:ma(t.x,r[0][0],r[1][0]),y:ma(t.y,r[0][1],r[1][1])}},uB=function(t){var r,n;return((r=t.getRootNode)===null||r===void 0?void 0:r.call(t))||((n=window)===null||n===void 0?void 0:n.document)},ooe=function(t,r){return{x:Math.min(t.x,r.x),y:Math.min(t.y,r.y),x2:Math.max(t.x2,r.x2),y2:Math.max(t.y2,r.y2)}},ud=function(t){var r=t.x,n=t.y,o=t.width,i=t.height;return{x:r,y:n,x2:r+o,y2:n+i}},ioe=function(t){var r=t.x,n=t.y,o=t.x2,i=t.y2;return{x:r,y:n,width:o-r,height:i-n}},dB=function(t){return!isNaN(t)&&isFinite(t)},ir=Symbol("internals");function ok(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),r.push.apply(r,n)}return r}function Ws(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?ok(Object(r),!0).forEach(function(n){et(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):ok(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function ik(e,t){var r=e.find(function(u){return u.id===t.parentNode});if(r){var n=t.position.x+t.width-r.width,o=t.position.y+t.height-r.height;if(n>0||o>0||t.position.x<0||t.position.y<0){var i,a;if(r.style=Ws({},r.style)||{},r.style.width=(i=r.style.width)!==null&&i!==void 0?i:r.width,r.style.height=(a=r.style.height)!==null&&a!==void 0?a:r.height,n>0&&(r.style.width+=n),o>0&&(r.style.height+=o),t.position.x<0){var s=Math.abs(t.position.x);r.position.x=r.position.x-s,r.style.width+=s,t.position.x=0}if(t.position.y<0){var c=Math.abs(t.position.y);r.position.y=r.position.y-c,r.style.height+=c,t.position.y=0}r.width=r.style.width,r.height=r.style.height}}}function fB(e,t){if(e.some(function(n){return n.type==="reset"}))return e.filter(function(n){return n.type==="reset"}).map(function(n){return n.item});var r=e.filter(function(n){return n.type==="add"}).map(function(n){return n.item});return t.reduce(function(n,o){var i=e.find(function(c){return c.id===o.id});if(i)switch(i.type){case"select":return n.push(Ws(Ws({},o),{},{selected:i.selected})),n;case"position":{var a=Ws({},o);return typeof i.position<"u"&&(a.position=i.position),typeof i.positionAbsolute<"u"&&(a.positionAbsolute=i.positionAbsolute),typeof i.dragging<"u"&&(a.dragging=i.dragging),a.expandParent&&ik(n,a),n.push(a),n}case"dimensions":{var s=Ws({},o);return typeof i.dimensions<"u"&&(s.width=i.dimensions.width,s.height=i.dimensions.height),s.expandParent&&ik(n,s),n.push(s),n}case"remove":return n}return n.push(o),n},r)}function pB(e,t){return fB(e,t)}function aoe(e,t){return fB(e,t)}var Wo=function(t,r){return{id:t,type:"select",selected:r}};function ua(e,t){return e.reduce(function(r,n){var o=t.includes(n.id);return!n.selected&&o?(n.selected=!0,r.push(Wo(n.id,!0))):n.selected&&!o&&(n.selected=!1,r.push(Wo(n.id,!1))),r},[])}function ak(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),r.push.apply(r,n)}return r}function hB(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?ak(Object(r),!0).forEach(function(n){et(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):ak(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}var sk=function(t,r,n){var o=r.querySelectorAll(t);if(!o||!o.length)return null;var i=Array.from(o),a=r.getBoundingClientRect();return i.map(function(s){var c=s.getBoundingClientRect();return hB({id:s.getAttribute("data-handleid"),position:s.getAttribute("data-handlepos"),x:(c.left-a.left)/n,y:(c.top-a.top)/n},V1(s))})};function ws(e,t,r){return r===void 0?r:function(n){var o=t().nodeInternals.get(e);r(n,hB({},o))}}function vB(e){var t=e.id,r=e.store,n=r.getState(),o=n.addSelectedNodes,i=n.unselectNodesAndEdges,a=n.multiSelectionActive,s=n.nodeInternals,c=s.get(t);r.setState({nodesSelectionActive:!1}),c.selected?c.selected&&a&&i({nodes:[c]}):o([t])}function lk(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),r.push.apply(r,n)}return r}function Qs(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?lk(Object(r),!0).forEach(function(n){et(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):lk(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}var soe=function(t){return"id"in t&&"source"in t&&"target"in t},loe=function(t){var r=t.source,n=t.sourceHandle,o=t.target,i=t.targetHandle;return"reactflow__edge-".concat(r).concat(n||"","-").concat(o).concat(i||"")},S_=function(t,r){if(typeof t>"u")return"";if(typeof t=="string")return t;var n=r?"".concat(r,"__"):"";return"".concat(n).concat(Object.keys(t).sort().map(function(o){return"".concat(o,"=").concat(t[o])}).join("&"))},coe=function(t,r){return r.some(function(n){return n.source===t.source&&n.target===t.target&&(n.sourceHandle===t.sourceHandle||!n.sourceHandle&&!t.sourceHandle)&&(n.targetHandle===t.targetHandle||!n.targetHandle&&!t.targetHandle)})},uoe=function(t,r){if(!t.source||!t.target)return process.env.NODE_ENV==="development"&&console.warn("[React Flow]: Can't create edge. An edge needs a source and a target. Help: https://reactflow.dev/error#600"),r;var n;return soe(t)?n=Qs({},t):n=Qs(Qs({},t),{},{id:loe(t)}),coe(n,r)?r:r.concat(n)},gB=function(t,r,n,o){var i=t.x,a=t.y,s=Ge(r,3),c=s[0],u=s[1],d=s[2],f=Ge(o,2),h=f[0],v=f[1],b={x:(i-c)/d,y:(a-u)/d};return n?{x:h*Math.round(b.x/h),y:v*Math.round(b.y/v)}:b},H1=function(t){if(t.length===0)return{x:0,y:0,width:0,height:0};var r=t.reduce(function(n,o){var i=o.positionAbsolute,a=o.position,s=o.width,c=o.height;return ooe(n,ud({x:i?i.x:a.x,y:i?i.y:a.y,width:s||0,height:c||0}))},{x:1/0,y:1/0,x2:-1/0,y2:-1/0});return ioe(r)},mB=function(t,r){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:[0,0,1],o=Ge(n,3),i=o[0],a=o[1],s=o[2],c=arguments.length>3&&arguments[3]!==void 0?arguments[3]:!1,u=arguments.length>4&&arguments[4]!==void 0?arguments[4]:!1,d=ud({x:(r.x-i)/s,y:(r.y-a)/s,width:r.width/s,height:r.height/s}),f=[];return t.forEach(function(h){var v=h.positionAbsolute,b=h.width,g=h.height,m=h.selectable,x=m===void 0?!0:m;if(u&&!x)return!1;var w=ud(Qs(Qs({},v),{},{width:b||0,height:g||0})),E=Math.max(0,Math.min(d.x2,w.x2)-Math.max(d.x,w.x)),S=Math.max(0,Math.min(d.y2,w.y2)-Math.max(d.y,w.y)),_=Math.ceil(E*S),C=typeof b>"u"||typeof g>"u"||b===null||g===null,N=c&&_>0,P=(b||0)*(g||0),A=C||N||_>=P;A&&f.push(h)}),f},bB=function(t,r){var n=t.map(function(o){return o.id});return r.filter(function(o){return n.includes(o.source)||n.includes(o.target)})},yB=function(t,r,n,o,i){var a=arguments.length>5&&arguments[5]!==void 0?arguments[5]:.1,s=r/(t.width*(1+a)),c=n/(t.height*(1+a)),u=Math.min(s,c),d=ma(u,o,i),f=t.x+t.width/2,h=t.y+t.height/2,v=r/2-f*d,b=n/2-h*d;return[v,b,d]},pi=function(t){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0;return t.transition().duration(r)};function ck(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),r.push.apply(r,n)}return r}function da(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?ck(Object(r),!0).forEach(function(n){et(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):ck(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function xB(e,t,r,n){var o,i,a,s,c,u,d,f,h,v,b,g;if(!e.parentNode)return n;var m=t.get(e.parentNode);return xB(m,t,r,{x:((o=n.x)!==null&&o!==void 0?o:0)+((i=(a=m.position)===null||a===void 0?void 0:a.x)!==null&&i!==void 0?i:0),y:((s=n.y)!==null&&s!==void 0?s:0)+((c=(u=m.position)===null||u===void 0?void 0:u.y)!==null&&c!==void 0?c:0),z:((d=(f=m[ir])===null||f===void 0?void 0:f.z)!==null&&d!==void 0?d:0)>((h=n.z)!==null&&h!==void 0?h:0)?(v=(b=m[ir])===null||b===void 0?void 0:b.z)!==null&&v!==void 0?v:0:(g=n.z)!==null&&g!==void 0?g:0})}function Yy(e,t){var r=new Map,n={};return e.forEach(function(o){var i,a=dB(o.zIndex)?o.zIndex:o.selected?1e3:0,s=t.get(o.id),c=da(da({width:s==null?void 0:s.width,height:s==null?void 0:s.height},o),{},{positionAbsolute:{x:o.position.x,y:o.position.y}});o.parentNode&&(c.parentNode=o.parentNode,n[o.parentNode]=!0),Object.defineProperty(c,ir,{enumerable:!1,value:{handleBounds:s==null||(i=s[ir])===null||i===void 0?void 0:i.handleBounds,z:a}}),r.set(o.id,c)}),r.forEach(function(o){if(o.parentNode&&!r.has(o.parentNode))throw new Error("Parent node ".concat(o.parentNode," not found"));if(o.parentNode||n[o.id]){var i,a,s=xB(o,r,n,da(da({},o.position),{},{z:(i=(a=o[ir])===null||a===void 0?void 0:a.z)!==null&&i!==void 0?i:0})),c=s.x,u=s.y,d=s.z;o.positionAbsolute={x:c,y:u},o[ir].z=d,n[o.id]&&(o[ir].isParent=!0)}}),r}function wB(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},r=e(),n=r.nodeInternals,o=r.width,i=r.height,a=r.minZoom,s=r.maxZoom,c=r.d3Zoom,u=r.d3Selection,d=r.fitViewOnInitDone,f=r.fitViewOnInit;if((t.initial&&!d&&f||!t.initial)&&c&&u){var h=Array.from(n.values()).filter(function(P){return t.includeHiddenNodes?P.width&&P.height:!P.hidden}),v=h.every(function(P){return P.width&&P.height});if(h.length>0&&v){var b,g,m,x=H1(h),w=yB(x,o,i,(b=t.minZoom)!==null&&b!==void 0?b:a,(g=t.maxZoom)!==null&&g!==void 0?g:s,(m=t.padding)!==null&&m!==void 0?m:.1),E=Ge(w,3),S=E[0],_=E[1],C=E[2],N=bi.translate(S,_).scale(C);return typeof t.duration=="number"&&t.duration>0?c.transform(pi(u,t.duration),N):c.transform(u,N),!0}}return!1}function doe(e,t){return e.forEach(function(r){var n=t.get(r.id);if(n){var o;t.set(n.id,da(da({},n),{},(o={},et(o,ir,n[ir]),et(o,"selected",r.selected),o)))}}),new Map(t)}function foe(e,t){return t.map(function(r){var n=e.find(function(o){return o.id===r.id});return n&&(r.selected=n.selected),r})}function iu(e){var t=e.changedNodes,r=e.changedEdges,n=e.get,o=e.set,i=n(),a=i.nodeInternals,s=i.edges,c=i.onNodesChange,u=i.onEdgesChange,d=i.hasDefaultNodes,f=i.hasDefaultEdges;t!=null&&t.length&&(d&&o({nodeInternals:doe(t,a)}),c==null||c(t)),r!=null&&r.length&&(f&&o({edges:foe(r,s)}),u==null||u(r))}var O_=[[Number.NEGATIVE_INFINITY,Number.NEGATIVE_INFINITY],[Number.POSITIVE_INFINITY,Number.POSITIVE_INFINITY]],uk={width:0,height:0,transform:[0,0,1],nodeInternals:new Map,edges:[],onNodesChange:null,onEdgesChange:null,hasDefaultNodes:!1,hasDefaultEdges:!1,d3Zoom:null,d3Selection:null,d3ZoomHandler:void 0,minZoom:.5,maxZoom:2,translateExtent:O_,nodeExtent:O_,nodesSelectionActive:!1,userSelectionActive:!1,connectionNodeId:null,connectionHandleId:null,connectionHandleType:"source",connectionPosition:{x:0,y:0},connectionMode:Ia.Strict,domNode:null,snapGrid:[15,15],snapToGrid:!1,nodesDraggable:!0,nodesConnectable:!0,elementsSelectable:!0,fitViewOnInit:!1,fitViewOnInitDone:!1,fitViewOnInitOptions:void 0,multiSelectionActive:!1,reactFlowVersion:"10.3.17",connectionStartHandle:null,connectOnClick:!0};function dk(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),r.push.apply(r,n)}return r}function $n(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?dk(Object(r),!0).forEach(function(n){et(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):dk(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}var W1=_ee(),poe=W1.Provider,Lt=W1.useStore,_r=W1.useStoreApi,hoe=function(){return wee(function(t,r){return $n($n({},uk),{},{setNodes:function(o){t({nodeInternals:Yy(o,r().nodeInternals)})},setEdges:function(o){var i=r(),a=i.defaultEdgeOptions,s=a===void 0?{}:a;t({edges:o.map(function(c){return $n($n({},s),c)})})},setDefaultNodesAndEdges:function(o,i){var a=typeof o<"u",s=typeof i<"u",c=a?Yy(o,new Map):new Map,u=s?i:[];t({nodeInternals:c,edges:u,hasDefaultNodes:a,hasDefaultEdges:s})},updateNodeDimensions:function(o){var i=r(),a=i.onNodesChange,s=i.nodeInternals,c=i.fitViewOnInit,u=i.fitViewOnInitDone,d=i.fitViewOnInitOptions,f=i.domNode,h=f==null?void 0:f.querySelector(".react-flow__viewport");if(h){var v=window.getComputedStyle(h),b=new window.DOMMatrixReadOnly(v.transform),g=b.m22,m=o.reduce(function(w,E){var S=s.get(E.id);if(S){var _=V1(E.nodeElement),C=!!(_.width&&_.height&&(S.width!==_.width||S.height!==_.height||E.forceUpdate));C&&(s.set(S.id,$n($n({},S),{},et({},ir,$n($n({},S[ir]),{},{handleBounds:{source:sk(".source",E.nodeElement,g),target:sk(".target",E.nodeElement,g)}})),_)),w.push({id:S.id,type:"dimensions",dimensions:_}))}return w},[]),x=u||c&&!u&&wB(r,$n({initial:!0},d));t({nodeInternals:new Map(s),fitViewOnInitDone:x}),(m==null?void 0:m.length)>0&&(a==null||a(m))}},updateNodePositions:function(o){var i=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!0,a=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!1,s=r(),c=s.onNodesChange,u=s.nodeInternals,d=s.hasDefaultNodes;if(d||c){var f=o.map(function(b){var g={id:b.id,type:"position",dragging:a};return i&&(g.positionAbsolute=b.positionAbsolute,g.position=b.position),g});if(f!=null&&f.length){if(d){var h=pB(f,Array.from(u.values())),v=Yy(h,u);t({nodeInternals:v})}c==null||c(f)}}},addSelectedNodes:function(o){var i=r(),a=i.multiSelectionActive,s=i.nodeInternals,c=i.edges,u,d=null;a?u=o.map(function(f){return Wo(f,!0)}):(u=ua(Array.from(s.values()),o),d=ua(c,[])),iu({changedNodes:u,changedEdges:d,get:r,set:t})},addSelectedEdges:function(o){var i=r(),a=i.multiSelectionActive,s=i.edges,c=i.nodeInternals,u,d=null;a?u=o.map(function(f){return Wo(f,!0)}):(u=ua(s,o),d=ua(Array.from(c.values()),[])),iu({changedNodes:d,changedEdges:u,get:r,set:t})},unselectNodesAndEdges:function(){var o=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},i=o.nodes,a=o.edges,s=r(),c=s.nodeInternals,u=s.edges,d=i||Array.from(c.values()),f=a||u,h=d.map(function(b){return b.selected=!1,Wo(b.id,!1)}),v=f.map(function(b){return Wo(b.id,!1)});iu({changedNodes:h,changedEdges:v,get:r,set:t})},setMinZoom:function(o){var i=r(),a=i.d3Zoom,s=i.maxZoom;a==null||a.scaleExtent([o,s]),t({minZoom:o})},setMaxZoom:function(o){var i=r(),a=i.d3Zoom,s=i.minZoom;a==null||a.scaleExtent([s,o]),t({maxZoom:o})},setTranslateExtent:function(o){var i=r(),a=i.d3Zoom;a==null||a.translateExtent(o),t({translateExtent:o})},resetSelectedElements:function(){var o=r(),i=o.nodeInternals,a=o.edges,s=Array.from(i.values()),c=s.filter(function(d){return d.selected}).map(function(d){return Wo(d.id,!1)}),u=a.filter(function(d){return d.selected}).map(function(d){return Wo(d.id,!1)});iu({changedNodes:c,changedEdges:u,get:r,set:t})},setNodeExtent:function(o){var i=r(),a=i.nodeInternals;a.forEach(function(s){s.positionAbsolute=cB(s.position,o)}),t({nodeExtent:o,nodeInternals:new Map(a)})},reset:function(){return t($n({},uk))}})})};function Kr(e){if(typeof e=="string"||typeof e=="number")return""+e;let t="";if(Array.isArray(e))for(let r=0,n;r<e.length;r++)(n=Kr(e[r]))!==""&&(t+=(t&&" ")+n);else for(let r in e)e[r]&&(t+=(t&&" ")+r);return t}function Dr(e,t){if(Object.is(e,t))return!0;if(typeof e!="object"||e===null||typeof t!="object"||t===null)return!1;const r=Object.keys(e);if(r.length!==Object.keys(t).length)return!1;for(let n=0;n<r.length;n++)if(!Object.prototype.hasOwnProperty.call(t,r[n])||!Object.is(e[r[n]],t[r[n]]))return!1;return!0}function voe(e){if(Array.isArray(e))return E_(e)}function goe(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function moe(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
|
|
55
|
+
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function yi(e){return voe(e)||goe(e)||lB(e)||moe()}var boe={zoomIn:function(){},zoomOut:function(){},zoomTo:function(t){},getZoom:function(){return 1},setViewport:function(t){},getViewport:function(){return{x:0,y:0,zoom:1}},fitView:function(){},setCenter:function(t,r){},fitBounds:function(t){},project:function(t){return t},viewportInitialized:!1},yoe=function(t){return{d3Zoom:t.d3Zoom,d3Selection:t.d3Selection}},xoe=function(){var t=_r(),r=Lt(yoe,Dr),n=r.d3Zoom,o=r.d3Selection,i=R.useMemo(function(){return o&&n?{zoomIn:function(s){return n.scaleBy(pi(o,s==null?void 0:s.duration),1.2)},zoomOut:function(s){return n.scaleBy(pi(o,s==null?void 0:s.duration),1/1.2)},zoomTo:function(s,c){return n.scaleTo(pi(o,c==null?void 0:c.duration),s)},getZoom:function(){return t.getState().transform[2]},setViewport:function(s,c){var u,d,f,h=Ge(t.getState().transform,3),v=h[0],b=h[1],g=h[2],m=bi.translate((u=s.x)!==null&&u!==void 0?u:v,(d=s.y)!==null&&d!==void 0?d:b).scale((f=s.zoom)!==null&&f!==void 0?f:g);n.transform(pi(o,c==null?void 0:c.duration),m)},getViewport:function(){var s=Ge(t.getState().transform,3),c=s[0],u=s[1],d=s[2];return{x:c,y:u,zoom:d}},fitView:function(s){return wB(t.getState,s)},setCenter:function(s,c,u){var d=t.getState(),f=d.width,h=d.height,v=d.maxZoom,b=typeof(u==null?void 0:u.zoom)<"u"?u.zoom:v,g=f/2-s*b,m=h/2-c*b,x=bi.translate(g,m).scale(b);n.transform(pi(o,u==null?void 0:u.duration),x)},fitBounds:function(s,c){var u,d=t.getState(),f=d.width,h=d.height,v=d.minZoom,b=d.maxZoom,g=yB(s,f,h,v,b,(u=c==null?void 0:c.padding)!==null&&u!==void 0?u:.1),m=Ge(g,3),x=m[0],w=m[1],E=m[2],S=bi.translate(x,w).scale(E);n.transform(pi(o,c==null?void 0:c.duration),S)},project:function(s){var c=t.getState(),u=c.transform,d=c.snapToGrid,f=c.snapGrid;return gB(s,u,d,f)},viewportInitialized:!0}:boe},[n,o]);return i};function fk(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),r.push.apply(r,n)}return r}function ra(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?fk(Object(r),!0).forEach(function(n){et(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):fk(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function _B(){var e=xoe(),t=_r(),r=R.useCallback(function(){var f=t.getState(),h=f.nodeInternals,v=Array.from(h.values());return v.map(function(b){return ra({},b)})},[]),n=R.useCallback(function(f){var h=t.getState(),v=h.nodeInternals;return v.get(f)},[]),o=R.useCallback(function(){var f=t.getState(),h=f.edges,v=h===void 0?[]:h;return v.map(function(b){return ra({},b)})},[]),i=R.useCallback(function(f){var h=t.getState(),v=h.edges,b=v===void 0?[]:v;return b.find(function(g){return g.id===f})},[]),a=R.useCallback(function(f){var h=t.getState(),v=h.nodeInternals,b=h.setNodes,g=h.hasDefaultNodes,m=h.onNodesChange,x=Array.from(v.values()),w=typeof f=="function"?f(x):f;if(g)b(w);else if(m){var E=w.length===0?x.map(function(S){return{type:"remove",id:S.id}}):w.map(function(S){return{item:S,type:"reset"}});m(E)}},[]),s=R.useCallback(function(f){var h=t.getState(),v=h.edges,b=v===void 0?[]:v,g=h.setEdges,m=h.hasDefaultEdges,x=h.onEdgesChange,w=typeof f=="function"?f(b):f;if(m)g(w);else if(x){var E=w.length===0?b.map(function(S){return{type:"remove",id:S.id}}):w.map(function(S){return{item:S,type:"reset"}});x(E)}},[]),c=R.useCallback(function(f){var h=Array.isArray(f)?f:[f],v=t.getState(),b=v.nodeInternals,g=v.setNodes,m=v.hasDefaultNodes,x=v.onNodesChange;if(m){var w=Array.from(b.values()),E=[].concat(w,yi(h));g(E)}else if(x){var S=h.map(function(_){return{item:_,type:"add"}});x(S)}},[]),u=R.useCallback(function(f){var h=Array.isArray(f)?f:[f],v=t.getState(),b=v.edges,g=b===void 0?[]:b,m=v.setEdges,x=v.hasDefaultEdges,w=v.onEdgesChange;if(x)m([].concat(yi(g),yi(h)));else if(w){var E=h.map(function(S){return{item:S,type:"add"}});w(E)}},[]),d=R.useCallback(function(){var f=t.getState(),h=f.nodeInternals,v=f.edges,b=v===void 0?[]:v,g=f.transform,m=Array.from(h.values()),x=Ge(g,3),w=x[0],E=x[1],S=x[2];return{nodes:m.map(function(_){return ra({},_)}),edges:b.map(function(_){return ra({},_)}),viewport:{x:w,y:E,zoom:S}}},[]);return R.useMemo(function(){return ra(ra({},e),{},{getNodes:r,getNode:n,getEdges:o,getEdge:i,setNodes:a,setEdges:s,addNodes:c,addEdges:u,toObject:d})},[e,r,n,o,i,a,s,c,u,d])}function woe(e,t){if(e==null)return{};var r={},n=Object.keys(e),o,i;for(i=0;i<n.length;i++)o=n[i],!(t.indexOf(o)>=0)&&(r[o]=e[o]);return r}function cf(e,t){if(e==null)return{};var r=woe(e,t),n,o;if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(o=0;o<i.length;o++)n=i[o],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(r[n]=e[n])}return r}function _oe(){return R.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32"},R.createElement("path",{d:"M32 18.133H18.133V32h-4.266V18.133H0v-4.266h13.867V0h4.266v13.867H32z"}))}function Eoe(){return R.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 5"},R.createElement("path",{d:"M0 0h32v4.2H0z"}))}function Soe(){return R.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 30"},R.createElement("path",{d:"M3.692 4.63c0-.53.4-.938.939-.938h5.215V0H4.708C2.13 0 0 2.054 0 4.63v5.216h3.692V4.631zM27.354 0h-5.2v3.692h5.17c.53 0 .984.4.984.939v5.215H32V4.631A4.624 4.624 0 0027.354 0zm.954 24.83c0 .532-.4.94-.939.94h-5.215v3.768h5.215c2.577 0 4.631-2.13 4.631-4.707v-5.139h-3.692v5.139zm-23.677.94c-.531 0-.939-.4-.939-.94v-5.138H0v5.139c0 2.577 2.13 4.707 4.708 4.707h5.138V25.77H4.631z"}))}function Ooe(){return R.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 25 32"},R.createElement("path",{d:"M21.333 10.667H19.81V7.619C19.81 3.429 16.38 0 12.19 0 8 0 4.571 3.429 4.571 7.619v3.048H3.048A3.056 3.056 0 000 13.714v15.238A3.056 3.056 0 003.048 32h18.285a3.056 3.056 0 003.048-3.048V13.714a3.056 3.056 0 00-3.048-3.047zM12.19 24.533a3.056 3.056 0 01-3.047-3.047 3.056 3.056 0 013.047-3.048 3.056 3.056 0 013.048 3.048 3.056 3.056 0 01-3.048 3.047zm4.724-13.866H7.467V7.619c0-2.59 2.133-4.724 4.723-4.724 2.591 0 4.724 2.133 4.724 4.724v3.048z"}))}function Coe(){return R.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 25 32"},R.createElement("path",{d:"M21.333 10.667H19.81V7.619C19.81 3.429 16.38 0 12.19 0c-4.114 1.828-1.37 2.133.305 2.438 1.676.305 4.42 2.59 4.42 5.181v3.048H3.047A3.056 3.056 0 000 13.714v15.238A3.056 3.056 0 003.048 32h18.285a3.056 3.056 0 003.048-3.048V13.714a3.056 3.056 0 00-3.048-3.047zM12.19 24.533a3.056 3.056 0 01-3.047-3.047 3.056 3.056 0 013.047-3.048 3.056 3.056 0 013.048 3.048 3.056 3.056 0 01-3.048 3.047z"}))}var Roe=["children","className"];function pk(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),r.push.apply(r,n)}return r}function Noe(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?pk(Object(r),!0).forEach(function(n){et(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):pk(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}var au=function(t){var r=t.children,n=t.className,o=cf(t,Roe);return R.createElement("button",Noe({type:"button",className:Kr(["react-flow__controls-button",n])},o),r)},Ioe=function(t){return t.nodesDraggable&&t.nodesConnectable&&t.elementsSelectable},Poe=function(t){var r=t.style,n=t.showZoom,o=n===void 0?!0:n,i=t.showFitView,a=i===void 0?!0:i,s=t.showInteractive,c=s===void 0?!0:s,u=t.fitViewOptions,d=t.onZoomIn,f=t.onZoomOut,h=t.onFitView,v=t.onInteractiveChange,b=t.className,g=t.children,m=_r(),x=R.useState(!1),w=Ge(x,2),E=w[0],S=w[1],_=Lt(Ioe),C=_B(),N=C.zoomIn,P=C.zoomOut,A=C.fitView;if(R.useEffect(function(){S(!0)},[]),!E)return null;var j=function(){N==null||N(),d==null||d()},M=function(){P==null||P(),f==null||f()},L=function(){A==null||A(u),h==null||h()},D=function(){m.setState({nodesDraggable:!_,nodesConnectable:!_,elementsSelectable:!_}),v==null||v(!_)};return R.createElement("div",{className:Kr(["react-flow__controls",b]),style:r},o&&R.createElement(R.Fragment,null,R.createElement(au,{onClick:j,className:"react-flow__controls-zoomin",title:"zoom in","aria-label":"zoom in"},R.createElement(_oe,null)),R.createElement(au,{onClick:M,className:"react-flow__controls-zoomout",title:"zoom out","aria-label":"zoom out"},R.createElement(Eoe,null))),a&&R.createElement(au,{className:"react-flow__controls-fitview",onClick:L,title:"fit view","aria-label":"fit view"},R.createElement(Soe,null)),c&&R.createElement(au,{className:"react-flow__controls-interactive",onClick:D,title:"toggle interactivity","aria-label":"toggle interactivity"},_?R.createElement(Coe,null):R.createElement(Ooe,null)),g)};Poe.displayName="Controls";var Toe=function(t,r,n){return R.createElement("path",{stroke:n,strokeWidth:r,d:"M".concat(t/2," 0 V").concat(t," M0 ").concat(t/2," H").concat(t)})},Aoe=function(t,r){return R.createElement("circle",{cx:t,cy:t,r:t,fill:r})},su;function hk(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),r.push.apply(r,n)}return r}function vk(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?hk(Object(r),!0).forEach(function(n){et(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):hk(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}var koe=(su={},et(su,Si.Dots,"#81818a"),et(su,Si.Lines,"#eee"),su),Doe=function(t){return t.transform},EB=function(t){var r=t.variant,n=r===void 0?Si.Dots:r,o=t.gap,i=o===void 0?15:o,a=t.size,s=a===void 0?.4:a,c=t.color,u=t.style,d=t.className,f=R.useRef(null),h=R.useState(null),v=Ge(h,2),b=v[0],g=v[1],m=Lt(Doe),x=Ge(m,3),w=x[0],E=x[1],S=x[2];R.useEffect(function(){var M=document.querySelectorAll(".react-flow__background"),L=Array.from(M).findIndex(function(D){return D===f.current});g("pattern-".concat(L))},[]);var _=i*S||1,C=w%_,N=E%_,P=n===Si.Lines,A=c||koe[n],j=P?Toe(_,s,A):Aoe(s*S,A);return R.createElement("svg",{className:Kr(["react-flow__background","react-flow__container",d]),style:vk(vk({},u),{},{width:"100%",height:"100%"}),ref:f},b&&R.createElement(R.Fragment,null,R.createElement("pattern",{id:b,x:C,y:N,width:_,height:_,patternUnits:"userSpaceOnUse"},j),R.createElement("rect",{x:"0",y:"0",width:"100%",height:"100%",fill:"url(#".concat(b,")")})))};EB.displayName="Background";var Moe=R.memo(EB),joe=["paid-pro","paid-sponsor","paid-enterprise","paid-custom"];function Loe(e){var t=e.proOptions,r=e.position,n=r===void 0?"bottom-right":r;if(t!=null&&t.account&&joe.includes(t==null?void 0:t.account)&&t!==null&&t!==void 0&&t.hideAttribution)return null;var o="".concat(n).split("-");return R.createElement("div",{className:Kr(["react-flow__attribution"].concat(yi(o))),"data-message":"Please only hide this attribution when you are subscribed to React Flow Pro: https://pro.reactflow.dev/pricing"},R.createElement("a",{href:"https://reactflow.dev",target:"_blank",rel:"noopener noreferrer"},"React Flow"))}var qoe=["x","y","label","labelStyle","labelShowBg","labelBgStyle","labelBgPadding","labelBgBorderRadius","children","className"];function gk(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),r.push.apply(r,n)}return r}function zoe(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?gk(Object(r),!0).forEach(function(n){et(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):gk(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}var Boe=function(t){var r=t.x,n=t.y,o=t.label,i=t.labelStyle,a=i===void 0?{}:i,s=t.labelShowBg,c=s===void 0?!0:s,u=t.labelBgStyle,d=u===void 0?{}:u,f=t.labelBgPadding,h=f===void 0?[2,4]:f,v=t.labelBgBorderRadius,b=v===void 0?2:v,g=t.children,m=t.className,x=cf(t,qoe),w=R.useRef(null),E=R.useState({x:0,y:0,width:0,height:0}),S=Ge(E,2),_=S[0],C=S[1],N=Kr(["react-flow__edge-textwrapper",m]);return R.useEffect(function(){if(w.current){var P=w.current.getBBox();C({x:P.x,y:P.y,width:P.width,height:P.height})}},[o]),typeof o>"u"||!o?null:R.createElement("g",zoe({transform:"translate(".concat(r-_.width/2," ").concat(n-_.height/2,")"),className:N},x),c&&R.createElement("rect",{width:_.width+2*h[0],x:-h[0],y:-h[1],height:_.height+2*h[1],className:"react-flow__edge-textbg",style:d,rx:b,ry:b}),R.createElement("text",{className:"react-flow__edge-text",y:_.height/2,dy:"0.3em",ref:w,style:a},o),g)},Foe=R.memo(Boe),uf=(function(e){var t=e.path,r=e.centerX,n=e.centerY,o=e.label,i=e.labelStyle,a=e.labelShowBg,s=e.labelBgStyle,c=e.labelBgPadding,u=e.labelBgBorderRadius,d=e.style,f=e.markerEnd,h=e.markerStart,v=o?R.createElement(Foe,{x:r,y:n,label:o,labelStyle:i,labelShowBg:a,labelBgStyle:s,labelBgPadding:c,labelBgBorderRadius:u}):null;return R.createElement(R.Fragment,null,R.createElement("path",{style:d,d:t,className:"react-flow__edge-path",markerEnd:f,markerStart:h}),v)});function dd(e){var t=e.pos,r=e.x1,n=e.y1,o=e.x2,i=e.y2,a,s;switch(t){case Oe.Left:case Oe.Right:a=.5*(r+o),s=n;break;case Oe.Top:case Oe.Bottom:a=r,s=.5*(n+i);break}return[a,s]}function SB(e){var t=e.sourceX,r=e.sourceY,n=e.sourcePosition,o=n===void 0?Oe.Bottom:n,i=e.targetX,a=e.targetY,s=e.targetPosition,c=s===void 0?Oe.Top:s,u=dd({pos:o,x1:t,y1:r,x2:i,y2:a}),d=Ge(u,2),f=d[0],h=d[1],v=dd({pos:c,x1:i,y1:a,x2:t,y2:r}),b=Ge(v,2),g=b[0],m=b[1];return"M".concat(t,",").concat(r," C").concat(f,",").concat(h," ").concat(g,",").concat(m," ").concat(i,",").concat(a)}function $oe(e){var t=e.sourceX,r=e.sourceY,n=e.sourcePosition,o=n===void 0?Oe.Bottom:n,i=e.targetX,a=e.targetY,s=e.targetPosition,c=s===void 0?Oe.Top:s,u=dd({pos:o,x1:t,y1:r,x2:i,y2:a}),d=Ge(u,2),f=d[0],h=d[1],v=dd({pos:c,x1:i,y1:a,x2:t,y2:r}),b=Ge(v,2),g=b[0],m=b[1],x=t*.125+f*.375+g*.375+i*.125,w=r*.125+h*.375+m*.375+a*.125,E=Math.abs(x-t),S=Math.abs(w-r);return[x,w,E,S]}var OB=R.memo(function(e){var t=e.sourceX,r=e.sourceY,n=e.targetX,o=e.targetY,i=e.sourcePosition,a=i===void 0?Oe.Bottom:i,s=e.targetPosition,c=s===void 0?Oe.Top:s,u=e.label,d=e.labelStyle,f=e.labelShowBg,h=e.labelBgStyle,v=e.labelBgPadding,b=e.labelBgBorderRadius,g=e.style,m=e.markerEnd,x=e.markerStart,w={sourceX:t,sourceY:r,sourcePosition:a,targetX:n,targetY:o,targetPosition:c},E=SB(w),S=$oe(w),_=Ge(S,2),C=_[0],N=_[1];return R.createElement(uf,{path:E,centerX:C,centerY:N,label:u,labelStyle:d,labelShowBg:f,labelBgStyle:h,labelBgPadding:v,labelBgBorderRadius:b,style:g,markerEnd:m,markerStart:x})});function mk(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),r.push.apply(r,n)}return r}function Voe(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?mk(Object(r),!0).forEach(function(n){et(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):mk(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}var bk=[Oe.Left,Oe.Right],CB=function(t){var r=t.sourceX,n=t.sourceY,o=t.targetX,i=t.targetY,a=t.sourcePosition,s=a===void 0?Oe.Bottom:a,c=t.targetPosition,u=c===void 0?Oe.Top:c,d=bk.includes(s),f=bk.includes(u),h=d&&!f||f&&!d;if(h){var v=d?Math.abs(o-r):0,b=r>o?r-v:r+v,g=d?0:Math.abs(i-n),m=n<i?n+g:n-g;return[b,m,v,g]}var x=Math.abs(o-r)/2,w=o<r?o+x:o-x,E=Math.abs(i-n)/2,S=i<n?i+E:i-E;return[w,S,x,E]};function _s(e,t,r){return r===void 0?r:function(n){var o=t().edges.find(function(i){return i.id===e});r(n,Voe({},o))}}var Ky=function(t,r,n){return"L ".concat(t,",").concat(r-n,"Q ").concat(t,",").concat(r," ").concat(t+n,",").concat(r)},Xy=function(t,r,n){return"L ".concat(t+n,",").concat(r,"Q ").concat(t,",").concat(r," ").concat(t,",").concat(r-n)},Zy=function(t,r,n){return"L ".concat(t,",").concat(r-n,"Q ").concat(t,",").concat(r," ").concat(t-n,",").concat(r)},Jy=function(t,r,n){return"L ".concat(t-n,",").concat(r,"Q ").concat(t,",").concat(r," ").concat(t,",").concat(r-n)},Qy=function(t,r,n){return"L ".concat(t+n,",").concat(r,"Q ").concat(t,",").concat(r," ").concat(t,",").concat(r+n)},e0=function(t,r,n){return"L ".concat(t,",").concat(r+n,"Q ").concat(t,",").concat(r," ").concat(t+n,",").concat(r)},t0=function(t,r,n){return"L ".concat(t,",").concat(r+n,"Q ").concat(t,",").concat(r," ").concat(t-n,",").concat(r)},r0=function(t,r,n){return"L ".concat(t-n,",").concat(r,"Q ").concat(t,",").concat(r," ").concat(t,",").concat(r+n)};function C_(e){var t=e.sourceX,r=e.sourceY,n=e.sourcePosition,o=n===void 0?Oe.Bottom:n,i=e.targetX,a=e.targetY,s=e.targetPosition,c=s===void 0?Oe.Top:s,u=e.borderRadius,d=u===void 0?5:u,f=e.centerX,h=e.centerY,v=CB({sourceX:t,sourceY:r,targetX:i,targetY:a}),b=Ge(v,4),g=b[0],m=b[1],x=b[2],w=b[3],E=Math.min(d,Math.abs(i-t)),S=Math.min(d,Math.abs(a-r)),_=Math.min(E,S,x,w),C=[Oe.Left,Oe.Right],N=typeof f<"u"?f:g,P=typeof h<"u"?h:m,A=null,j=null;return t<=i?(A=r<=a?Ky(t,P,_):e0(t,P,_),j=r<=a?r0(i,P,_):Jy(i,P,_)):(A=r<a?Zy(t,P,_):t0(t,P,_),j=r<a?Qy(i,P,_):Xy(i,P,_)),C.includes(o)&&C.includes(c)?t<=i?(A=r<=a?r0(N,r,_):Jy(N,r,_),j=r<=a?Ky(N,a,_):e0(N,a,_)):(o===Oe.Right&&c===Oe.Left||o===Oe.Left&&c===Oe.Right||o===Oe.Left&&c===Oe.Left)&&(A=r<=a?Qy(N,r,_):Xy(N,r,_),j=r<=a?Zy(N,a,_):t0(N,a,_)):C.includes(o)&&!C.includes(c)?(t<=i?A=r<=a?r0(i,r,_):Jy(i,r,_):A=r<=a?Qy(i,r,_):Xy(i,r,_),j=""):!C.includes(o)&&C.includes(c)&&(t<=i?A=r<=a?Ky(t,a,_):e0(t,a,_):A=r<=a?Zy(t,a,_):t0(t,a,_),j=""),"M ".concat(t,",").concat(r).concat(A).concat(j,"L ").concat(i,",").concat(a)}var U1=R.memo(function(e){var t=e.sourceX,r=e.sourceY,n=e.targetX,o=e.targetY,i=e.label,a=e.labelStyle,s=e.labelShowBg,c=e.labelBgStyle,u=e.labelBgPadding,d=e.labelBgBorderRadius,f=e.style,h=e.sourcePosition,v=h===void 0?Oe.Bottom:h,b=e.targetPosition,g=b===void 0?Oe.Top:b,m=e.markerEnd,x=e.markerStart,w=e.borderRadius,E=w===void 0?5:w,S=CB({sourceX:t,sourceY:r,targetX:n,targetY:o,sourcePosition:v,targetPosition:g}),_=Ge(S,2),C=_[0],N=_[1],P=C_({sourceX:t,sourceY:r,sourcePosition:v,targetX:n,targetY:o,targetPosition:g,borderRadius:E});return R.createElement(uf,{path:P,centerX:C,centerY:N,label:i,labelStyle:a,labelShowBg:s,labelBgStyle:c,labelBgPadding:u,labelBgBorderRadius:d,style:f,markerEnd:m,markerStart:x})});function yk(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),r.push.apply(r,n)}return r}function xk(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?yk(Object(r),!0).forEach(function(n){et(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):yk(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}var RB=R.memo(function(e){return R.createElement(U1,xk(xk({},e),{},{borderRadius:0}))}),NB=R.memo(function(e){var t=e.sourceX,r=e.sourceY,n=e.targetX,o=e.targetY,i=e.label,a=e.labelStyle,s=e.labelShowBg,c=e.labelBgStyle,u=e.labelBgPadding,d=e.labelBgBorderRadius,f=e.style,h=e.markerEnd,v=e.markerStart,b=Math.abs(o-r)/2,g=o<r?o+b:o-b,m=Math.abs(n-t)/2,x=n<t?n+m:n-m,w="M ".concat(t,",").concat(r,"L ").concat(n,",").concat(o);return R.createElement(uf,{path:w,centerX:x,centerY:g,label:i,labelStyle:a,labelShowBg:s,labelBgStyle:c,labelBgPadding:u,labelBgBorderRadius:d,style:f,markerEnd:h,markerStart:v})});function lu(e,t){return e>=0?.5*e:t*25*Math.sqrt(-e)}function fd(e){var t=e.pos,r=e.x1,n=e.y1,o=e.x2,i=e.y2,a=e.c,s,c;switch(t){case Oe.Left:s=r-lu(r-o,a),c=n;break;case Oe.Right:s=r+lu(o-r,a),c=n;break;case Oe.Top:s=r,c=n-lu(n-i,a);break;case Oe.Bottom:s=r,c=n+lu(i-n,a);break}return[s,c]}function df(e){var t=e.sourceX,r=e.sourceY,n=e.sourcePosition,o=n===void 0?Oe.Bottom:n,i=e.targetX,a=e.targetY,s=e.targetPosition,c=s===void 0?Oe.Top:s,u=e.curvature,d=u===void 0?.25:u,f=fd({pos:o,x1:t,y1:r,x2:i,y2:a,c:d}),h=Ge(f,2),v=h[0],b=h[1],g=fd({pos:c,x1:i,y1:a,x2:t,y2:r,c:d}),m=Ge(g,2),x=m[0],w=m[1];return"M".concat(t,",").concat(r," C").concat(v,",").concat(b," ").concat(x,",").concat(w," ").concat(i,",").concat(a)}function Hoe(e){var t=e.sourceX,r=e.sourceY,n=e.sourcePosition,o=n===void 0?Oe.Bottom:n,i=e.targetX,a=e.targetY,s=e.targetPosition,c=s===void 0?Oe.Top:s,u=e.curvature,d=u===void 0?.25:u,f=fd({pos:o,x1:t,y1:r,x2:i,y2:a,c:d}),h=Ge(f,2),v=h[0],b=h[1],g=fd({pos:c,x1:i,y1:a,x2:t,y2:r,c:d}),m=Ge(g,2),x=m[0],w=m[1],E=t*.125+v*.375+x*.375+i*.125,S=r*.125+b*.375+w*.375+a*.125,_=Math.abs(E-t),C=Math.abs(S-r);return[E,S,_,C]}var R_=R.memo(function(e){var t=e.sourceX,r=e.sourceY,n=e.targetX,o=e.targetY,i=e.sourcePosition,a=i===void 0?Oe.Bottom:i,s=e.targetPosition,c=s===void 0?Oe.Top:s,u=e.label,d=e.labelStyle,f=e.labelShowBg,h=e.labelBgStyle,v=e.labelBgPadding,b=e.labelBgBorderRadius,g=e.style,m=e.markerEnd,x=e.markerStart,w=e.curvature,E={sourceX:t,sourceY:r,sourcePosition:a,targetX:n,targetY:o,targetPosition:c,curvature:w},S=df(E),_=Hoe(E),C=Ge(_,2),N=C[0],P=C[1];return R.createElement(uf,{path:S,centerX:N,centerY:P,label:u,labelStyle:d,labelShowBg:f,labelBgStyle:h,labelBgPadding:v,labelBgBorderRadius:b,style:g,markerEnd:m,markerStart:x})}),G1=R.createContext(null),Woe=G1.Provider;G1.Consumer;function N_(e,t,r,n,o,i,a){var s=a.elementFromPoint(e.clientX,e.clientY),c=(s==null?void 0:s.classList.contains("target"))||!1,u=(s==null?void 0:s.classList.contains("source"))||!1,d={elementBelow:s,isValid:!1,connection:{source:null,target:null,sourceHandle:null,targetHandle:null},isHoveringHandle:!1};if(s&&(c||u)){d.isHoveringHandle=!0;var f=s.getAttribute("data-nodeid"),h=s.getAttribute("data-handleid"),v=r?{source:f,sourceHandle:h,target:n,targetHandle:o}:{source:n,sourceHandle:o,target:f,targetHandle:h};d.connection=v;var b=t===Ia.Strict?r&&u||!r&&c:!0;b&&(d.isValid=i(v))}return d}function n0(e){e==null||e.classList.remove("react-flow__handle-valid"),e==null||e.classList.remove("react-flow__handle-connecting")}function IB(e){var t=e.event,r=e.handleId,n=e.nodeId,o=e.onConnect,i=e.isTarget,a=e.getState,s=e.setState,c=e.isValidConnection,u=e.elementEdgeUpdaterType,d=e.onEdgeUpdateEnd,f=t.target.closest(".react-flow"),h=uB(t.target);if(!h)return;var v=h.elementFromPoint(t.clientX,t.clientY),b=v==null?void 0:v.classList.contains("target"),g=v==null?void 0:v.classList.contains("source");if(!f||!b&&!g&&!u)return;var m=a(),x=m.onConnectStart,w=m.connectionMode,E=u||(b?"target":"source"),S=f.getBoundingClientRect(),_;s({connectionPosition:{x:t.clientX-S.left,y:t.clientY-S.top},connectionNodeId:n,connectionHandleId:r,connectionHandleType:E}),x==null||x(t,{nodeId:n,handleId:r,handleType:E});function C(P){s({connectionPosition:{x:P.clientX-S.left,y:P.clientY-S.top}});var A=N_(P,w,i,n,r,c,h),j=A.connection,M=A.elementBelow,L=A.isValid,D=A.isHoveringHandle;if(!D)return n0(_);j.source!==j.target&&M&&(n0(_),_=M,M.classList.add("react-flow__handle-connecting"),M.classList.toggle("react-flow__handle-valid",L))}function N(P){var A=a(),j=A.onConnectStop,M=A.onConnectEnd,L=N_(P,w,i,n,r,c,h),D=L.connection,T=L.isValid;j==null||j(P),T&&(o==null||o(D)),M==null||M(P),u&&d&&d(P),n0(_),s({connectionNodeId:null,connectionHandleId:null,connectionHandleType:null}),h.removeEventListener("mousemove",C),h.removeEventListener("mouseup",N)}h.addEventListener("mousemove",C),h.addEventListener("mouseup",N)}var Uoe=["type","position","isValidConnection","isConnectable","id","onConnect","children","className","onMouseDown"];function wk(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),r.push.apply(r,n)}return r}function o0(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?wk(Object(r),!0).forEach(function(n){et(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):wk(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}var Goe=function(){return!0},Yoe=function(t){return{connectionStartHandle:t.connectionStartHandle,connectOnClick:t.connectOnClick}},PB=R.forwardRef(function(e,t){var r=e.type,n=r===void 0?"source":r,o=e.position,i=o===void 0?Oe.Top:o,a=e.isValidConnection,s=a===void 0?Goe:a,c=e.isConnectable,u=c===void 0?!0:c,d=e.id,f=e.onConnect,h=e.children,v=e.className,b=e.onMouseDown,g=cf(e,Uoe),m=_r(),x=R.useContext(G1),w=Lt(Yoe,Dr),E=w.connectionStartHandle,S=w.connectOnClick,_=d||null,C=n==="target",N=function(M){var L=m.getState(),D=L.defaultEdgeOptions,T=L.onConnect,W=L.hasDefaultEdges,q=o0(o0({},D),M);if(W){var G=m.getState(),F=G.edges;m.setState({edges:uoe(q,F)})}T==null||T(q),f==null||f(q)},P=function(M){M.button===0&&IB({event:M,handleId:_,nodeId:x,onConnect:N,isTarget:C,getState:m.getState,setState:m.setState,isValidConnection:s}),b==null||b(M)},A=function(M){var L=m.getState(),D=L.onClickConnectStart,T=L.onClickConnectStop,W=L.onClickConnectEnd,q=L.connectionMode;if(!E){D==null||D(M,{nodeId:x,handleId:_,handleType:n}),m.setState({connectionStartHandle:{nodeId:x,type:n,handleId:_}});return}var G=uB(M.target),F=N_(M,q,E.type==="target",E.nodeId,E.handleId||null,s,G),J=F.connection,z=F.isValid;T==null||T(M),z&&N(J),W==null||W(M),m.setState({connectionStartHandle:null})};return R.createElement("div",o0({"data-handleid":_,"data-nodeid":x,"data-handlepos":i,className:Kr(["react-flow__handle","react-flow__handle-".concat(i),"nodrag",v,{source:!C,target:C,connectable:u,connecting:(E==null?void 0:E.nodeId)===x&&(E==null?void 0:E.handleId)===_&&(E==null?void 0:E.type)===n}]),onMouseDown:P,onClick:S?A:void 0,ref:t},g),h)});PB.displayName="Handle";var pd=R.memo(PB),TB=function(t){var r=t.data,n=t.isConnectable,o=t.targetPosition,i=o===void 0?Oe.Top:o,a=t.sourcePosition,s=a===void 0?Oe.Bottom:a;return R.createElement(R.Fragment,null,R.createElement(pd,{type:"target",position:i,isConnectable:n}),r==null?void 0:r.label,R.createElement(pd,{type:"source",position:s,isConnectable:n}))};TB.displayName="DefaultNode";var I_=R.memo(TB),AB=function(t){var r=t.data,n=t.isConnectable,o=t.sourcePosition,i=o===void 0?Oe.Bottom:o;return R.createElement(R.Fragment,null,r==null?void 0:r.label,R.createElement(pd,{type:"source",position:i,isConnectable:n}))};AB.displayName="InputNode";var kB=R.memo(AB),DB=function(t){var r=t.data,n=t.isConnectable,o=t.targetPosition,i=o===void 0?Oe.Top:o;return R.createElement(R.Fragment,null,R.createElement(pd,{type:"target",position:i,isConnectable:n}),r==null?void 0:r.label)};DB.displayName="OutputNode";var MB=R.memo(DB),Koe=function(t){return{selectedNodes:Array.from(t.nodeInternals.values()).filter(function(r){return r.selected}),selectedEdges:t.edges.filter(function(r){return r.selected})}},Xoe=function(t,r){var n=t.selectedNodes.map(function(s){return s.id}),o=r.selectedNodes.map(function(s){return s.id}),i=t.selectedEdges.map(function(s){return s.id}),a=r.selectedEdges.map(function(s){return s.id});return Dr(n,o)&&Dr(i,a)};function Zoe(e){var t=e.onSelectionChange,r=Lt(Koe,Xoe),n=r.selectedNodes,o=r.selectedEdges;return R.useEffect(function(){t({nodes:n,edges:o})},[n,o]),null}var Joe=R.memo(Zoe),Qoe=function(t){return{setNodes:t.setNodes,setEdges:t.setEdges,setDefaultNodesAndEdges:t.setDefaultNodesAndEdges,setMinZoom:t.setMinZoom,setMaxZoom:t.setMaxZoom,setTranslateExtent:t.setTranslateExtent,setNodeExtent:t.setNodeExtent,reset:t.reset}};function Bo(e,t){R.useEffect(function(){typeof e<"u"&&t(e)},[e])}function vt(e,t,r){R.useEffect(function(){typeof t<"u"&&r(et({},e,t))},[t])}var eie=function(t){var r=t.nodes,n=t.edges,o=t.defaultNodes,i=t.defaultEdges,a=t.onConnect,s=t.onConnectStart,c=t.onConnectStop,u=t.onConnectEnd,d=t.onClickConnectStart,f=t.onClickConnectStop,h=t.onClickConnectEnd,v=t.nodesDraggable,b=t.nodesConnectable,g=t.minZoom,m=t.maxZoom,x=t.nodeExtent,w=t.onNodesChange,E=t.onEdgesChange,S=t.elementsSelectable,_=t.connectionMode,C=t.snapGrid,N=t.snapToGrid,P=t.translateExtent,A=t.connectOnClick,j=t.defaultEdgeOptions,M=t.fitView,L=t.fitViewOptions,D=t.onNodesDelete,T=t.onEdgesDelete,W=t.onNodeDrag,q=t.onNodeDragStart,G=t.onNodeDragStop,F=t.onSelectionDrag,J=t.onSelectionDragStart,z=t.onSelectionDragStop,U=Lt(Qoe,Dr),oe=U.setNodes,re=U.setEdges,$=U.setDefaultNodesAndEdges,Y=U.setMinZoom,X=U.setMaxZoom,H=U.setTranslateExtent,K=U.setNodeExtent,Q=U.reset,ne=_r();return R.useEffect(function(){return $(o,i),function(){Q()}},[]),vt("defaultEdgeOptions",j,ne.setState),vt("connectionMode",_,ne.setState),vt("onConnect",a,ne.setState),vt("onConnectStart",s,ne.setState),vt("onConnectStop",c,ne.setState),vt("onConnectEnd",u,ne.setState),vt("onClickConnectStart",d,ne.setState),vt("onClickConnectStop",f,ne.setState),vt("onClickConnectEnd",h,ne.setState),vt("nodesDraggable",v,ne.setState),vt("nodesConnectable",b,ne.setState),vt("elementsSelectable",S,ne.setState),vt("snapToGrid",N,ne.setState),vt("snapGrid",C,ne.setState),vt("onNodesChange",w,ne.setState),vt("onEdgesChange",E,ne.setState),vt("connectOnClick",A,ne.setState),vt("fitViewOnInit",M,ne.setState),vt("fitViewOnInitOptions",L,ne.setState),vt("onNodesDelete",D,ne.setState),vt("onEdgesDelete",T,ne.setState),vt("onNodeDrag",W,ne.setState),vt("onNodeDragStart",q,ne.setState),vt("onNodeDragStop",G,ne.setState),vt("onSelectionDrag",F,ne.setState),vt("onSelectionDragStart",J,ne.setState),vt("onSelectionDragStop",z,ne.setState),Bo(r,oe),Bo(n,re),Bo(o,oe),Bo(i,re),Bo(g,Y),Bo(m,X),Bo(P,H),Bo(x,K),null},tie=".react-flow{height:100%;overflow:hidden;position:relative;width:100%}.react-flow__container{height:100%;left:0;position:absolute;top:0;width:100%}.react-flow__pane{z-index:1}.react-flow__viewport{pointer-events:none;transform-origin:0 0;z-index:2}.react-flow__renderer{z-index:4}.react-flow__selectionpane{z-index:5}.react-flow .react-flow__edges{overflow:visible;pointer-events:none}.react-flow .react-flow__connectionline{z-index:1001}.react-flow__edge{pointer-events:visibleStroke}.react-flow__edge.inactive{pointer-events:none}@-webkit-keyframes dashdraw{0%{stroke-dashoffset:10}}@keyframes dashdraw{0%{stroke-dashoffset:10}}.react-flow__edge-path{fill:none}.react-flow__edge-textwrapper{pointer-events:all}.react-flow__edge-text{pointer-events:none;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}.react-flow__connection{pointer-events:none}.react-flow__connection .animated{stroke-dasharray:5;-webkit-animation:dashdraw .5s linear infinite;animation:dashdraw .5s linear infinite}.react-flow__connection-path{fill:none}.react-flow__nodes{pointer-events:none;transform-origin:0 0}.react-flow__node{box-sizing:border-box;pointer-events:all;position:absolute;transform-origin:0 0;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}.react-flow__nodesselection{pointer-events:none;transform-origin:left top;z-index:3}.react-flow__nodesselection-rect{cursor:-webkit-grab;cursor:grab;pointer-events:all;position:absolute}.react-flow__handle{pointer-events:none;position:absolute}.react-flow__handle.connectable{pointer-events:all}.react-flow__handle-bottom{bottom:-4px;left:50%;top:auto;transform:translate(-50%)}.react-flow__handle-top{left:50%;top:-4px;transform:translate(-50%)}.react-flow__handle-left{left:-4px;top:50%;transform:translateY(-50%)}.react-flow__handle-right{right:-4px;top:50%;transform:translateY(-50%)}.react-flow__edgeupdater{cursor:move;pointer-events:all}.react-flow__controls{bottom:20px;left:15px;position:absolute;z-index:5}.react-flow__controls-button{border:none;height:24px;width:24px}.react-flow__controls-button svg{width:100%}.react-flow__minimap{bottom:20px;position:absolute;right:15px;z-index:5}.react-flow__attribution{background:hsla(0,0%,100%,.5);color:#999;font-size:10px;padding:2px 3px;position:absolute;z-index:1000}.react-flow__attribution a{color:#555;text-decoration:none}.react-flow__attribution.top{top:0}.react-flow__attribution.bottom{bottom:0}.react-flow__attribution.left{left:0}.react-flow__attribution.right{right:0}.react-flow__attribution.center{left:50%;transform:translateX(-50%)}",rie=tie,nie=".react-flow__edge.selected .react-flow__edge-path{stroke:#555}.react-flow__edge.animated path{stroke-dasharray:5;-webkit-animation:dashdraw .5s linear infinite;animation:dashdraw .5s linear infinite}.react-flow__edge.updating .react-flow__edge-path{stroke:#777}.react-flow__edge-path{stroke:#b1b1b7;stroke-width:1}.react-flow__edge-text{font-size:10px}.react-flow__edge-textbg{fill:#fff}.react-flow__connection-path{stroke:#b1b1b7;stroke-width:1}.react-flow__node{cursor:-webkit-grab;cursor:grab}.react-flow__node-default,.react-flow__node-group,.react-flow__node-input,.react-flow__node-output{background:#fff;border:1px solid #1a192b;border-radius:3px;color:#222;font-size:12px;padding:10px;text-align:center;width:150px}.react-flow__node-default.selected,.react-flow__node-group.selected,.react-flow__node-input.selected,.react-flow__node-output.selected{box-shadow:0 0 0 .5px #1a192b}.react-flow__node-default .react-flow__handle,.react-flow__node-group .react-flow__handle,.react-flow__node-input .react-flow__handle,.react-flow__node-output .react-flow__handle{background:#1a192b}.react-flow__node-default.selectable:hover,.react-flow__node-group.selectable:hover,.react-flow__node-input.selectable:hover,.react-flow__node-output.selectable:hover{box-shadow:0 1px 4px 1px rgba(0,0,0,.08)}.react-flow__node-default.selectable.selected,.react-flow__node-group.selectable.selected,.react-flow__node-input.selectable.selected,.react-flow__node-output.selectable.selected{box-shadow:0 0 0 .5px #1a192b}.react-flow__node-group{background:hsla(0,0%,94%,.25);border-color:#1a192b}.react-flow__nodesselection-rect,.react-flow__selection{background:rgba(0,89,220,.08);border:1px dotted rgba(0,89,220,.8)}.react-flow__handle{background:#555;border:1px solid #fff;border-radius:100%;height:6px;width:6px}.react-flow__handle.connectable{cursor:crosshair}.react-flow__minimap{background-color:#fff}.react-flow__controls{box-shadow:0 0 2px 1px rgba(0,0,0,.08)}.react-flow__controls-button{align-items:center;background:#fefefe;border-bottom:1px solid #eee;box-sizing:content-box;cursor:pointer;display:flex;height:16px;justify-content:center;padding:5px;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;width:16px}.react-flow__controls-button svg{max-height:12px;max-width:12px}.react-flow__controls-button:hover{background:#f4f4f4}",oie=nie,iie=function(t,r,n){return n===Oe.Left?t-r:n===Oe.Right?t+r:t},aie=function(t,r,n){return n===Oe.Top?t-r:n===Oe.Bottom?t+r:t},_k=function(t){var r=t.className,n=t.position,o=t.centerX,i=t.centerY,a=t.radius,s=a===void 0?10:a;return R.createElement("circle",{className:Kr(["react-flow__edgeupdater",r]),cx:iie(o,s,n),cy:aie(i,s,n),r:s,stroke:"transparent",fill:"transparent"})},na=(function(e){var t=function(n){var o=n.id,i=n.className,a=n.type,s=n.data,c=n.onClick,u=n.onEdgeDoubleClick,d=n.selected,f=n.animated,h=n.label,v=n.labelStyle,b=n.labelShowBg,g=n.labelBgStyle,m=n.labelBgPadding,x=n.labelBgBorderRadius,w=n.style,E=n.source,S=n.target,_=n.sourceX,C=n.sourceY,N=n.targetX,P=n.targetY,A=n.sourcePosition,j=n.targetPosition,M=n.elementsSelectable,L=n.hidden,D=n.sourceHandleId,T=n.targetHandleId,W=n.onContextMenu,q=n.onMouseEnter,G=n.onMouseMove,F=n.onMouseLeave,J=n.edgeUpdaterRadius,z=n.onEdgeUpdate,U=n.onEdgeUpdateStart,oe=n.onEdgeUpdateEnd,re=n.markerEnd,$=n.markerStart,Y=n.rfId,X=R.useState(!1),H=Ge(X,2),K=H[0],Q=H[1],ne=_r(),se=function(Ne){var je=ne.getState(),Qe=je.edges,At=je.addSelectedEdges,It=Qe.find(function(mt){return mt.id===o});M&&(ne.setState({nodesSelectionActive:!1}),At([o])),c==null||c(Ne,It)},te=_s(o,ne.getState,u),be=_s(o,ne.getState,W),de=_s(o,ne.getState,q),Ee=_s(o,ne.getState,G),fe=_s(o,ne.getState,F),le=function(Ne,je){var Qe=je?S:E,At=(je?T:D)||null,It=je?"target":"source",mt=function(){return!0},Rt=je,Qt=ne.getState().edges.find(function(Xr){return Xr.id===o});U==null||U(Ne,Qt,It);var fr=oe?function(Xr){return oe(Xr,Qt,It)}:void 0,pr=function(Co){return z==null?void 0:z(Qt,Co)};IB({event:Ne,handleId:At,nodeId:Qe,onConnect:pr,isTarget:Rt,getState:ne.getState,setState:ne.setState,isValidConnection:mt,elementEdgeUpdaterType:It,onEdgeUpdateEnd:fr})},Ce=function(Ne){return le(Ne,!0)},Te=function(Ne){return le(Ne,!1)},Fe=function(){return Q(!0)},Le=function(){return Q(!1)},Ze=R.useMemo(function(){return"url(#".concat(S_($,Y),")")},[$,Y]),We=R.useMemo(function(){return"url(#".concat(S_(re,Y),")")},[re,Y]);if(L)return null;var St=!M&&!c,tt=typeof z<"u",wt=Kr(["react-flow__edge","react-flow__edge-".concat(a),i,{selected:d,animated:f,inactive:St,updating:K}]);return R.createElement("g",{className:wt,onClick:se,onDoubleClick:te,onContextMenu:be,onMouseEnter:de,onMouseMove:Ee,onMouseLeave:fe},R.createElement(e,{id:o,source:E,target:S,selected:d,animated:f,label:h,labelStyle:v,labelShowBg:b,labelBgStyle:g,labelBgPadding:m,labelBgBorderRadius:x,data:s,style:w,sourceX:_,sourceY:C,targetX:N,targetY:P,sourcePosition:A,targetPosition:j,sourceHandleId:D,targetHandleId:T,markerStart:Ze,markerEnd:We,"data-testid":"rf__edge-".concat(o)}),tt&&R.createElement("g",{onMouseDown:Ce,onMouseEnter:Fe,onMouseOut:Le},R.createElement(_k,{position:A,centerX:_,centerY:C,radius:J})),tt&&R.createElement("g",{onMouseDown:Te,onMouseEnter:Fe,onMouseOut:Le},R.createElement(_k,{position:j,centerX:N,centerY:P,radius:J})))};return t.displayName="EdgeWrapper",R.memo(t)});function Ek(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),r.push.apply(r,n)}return r}function Sk(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?Ek(Object(r),!0).forEach(function(n){et(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):Ek(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function sie(e){var t={default:na(e.default||R_),straight:na(e.bezier||NB),step:na(e.step||RB),smoothstep:na(e.step||U1),simplebezier:na(e.simplebezier||OB)},r={},n=Object.keys(e).filter(function(o){return!["default","bezier"].includes(o)}).reduce(function(o,i){return o[i]=na(e[i]||R_),o},r);return Sk(Sk({},t),n)}function Ok(e,t){var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:null,n=((r==null?void 0:r.x)||0)+t.x,o=((r==null?void 0:r.y)||0)+t.y,i=(r==null?void 0:r.width)||t.width,a=(r==null?void 0:r.height)||t.height;switch(e){case Oe.Top:return{x:n+i/2,y:o};case Oe.Right:return{x:n+i,y:o+a/2};case Oe.Bottom:return{x:n+i/2,y:o+a};case Oe.Left:return{x:n,y:o+a/2}}}function Ck(e,t){if(!e)return null;var r=null;return e.length===1||!t?r=e[0]:t&&(r=e.find(function(n){return n.id===t})),typeof r>"u"?null:r}var lie=function(t,r,n,o,i,a){var s=Ok(n,t,r),c=Ok(a,o,i);return{sourceX:s.x,sourceY:s.y,targetX:c.x,targetY:c.y}};function cie(e){var t=e.sourcePos,r=e.targetPos,n=e.sourceWidth,o=e.sourceHeight,i=e.targetWidth,a=e.targetHeight,s=e.width,c=e.height,u=e.transform,d={x:Math.min(t.x,r.x),y:Math.min(t.y,r.y),x2:Math.max(t.x+n,r.x+i),y2:Math.max(t.y+o,r.y+a)};d.x===d.x2&&(d.x2+=1),d.y===d.y2&&(d.y2+=1);var f=ud({x:(0-u[0])/u[2],y:(0-u[1])/u[2],width:s/u[2],height:c/u[2]}),h=Math.max(0,Math.min(f.x2,d.x2)-Math.max(f.x,d.x)),v=Math.max(0,Math.min(f.y2,d.y2)-Math.max(f.y,d.y)),b=Math.ceil(h*v);return b>0}function Rk(e,t){var r,n,o,i,a,s=e.get(t),c=(s==null||(r=s[ir])===null||r===void 0?void 0:r.handleBounds)||null,u=!s||!c||!s.width||!s.height||typeof((n=s.positionAbsolute)===null||n===void 0?void 0:n.x)>"u"||typeof((o=s.positionAbsolute)===null||o===void 0?void 0:o.y)>"u";return[{x:(s==null||(i=s.positionAbsolute)===null||i===void 0?void 0:i.x)||0,y:(s==null||(a=s.positionAbsolute)===null||a===void 0?void 0:a.y)||0,width:(s==null?void 0:s.width)||0,height:(s==null?void 0:s.height)||0},c,!u]}var uie=typeof document<"u"?document:null,hd=(function(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:null,t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{target:uie},r=R.useState(!1),n=Ge(r,2),o=n[0],i=n[1],a=R.useRef(new Set([])),s=R.useMemo(function(){if(e!==null){var f=Array.isArray(e)?e:[e],h=f.filter(function(b){return typeof b=="string"}).map(function(b){return b.split("+")}),v=h.reduce(function(b,g){return b.concat.apply(b,yi(g))},[]);return[h,v]}return[[],[]]},[e]),c=Ge(s,2),u=c[0],d=c[1];return R.useEffect(function(){if(e!==null){var f,h,v=function(x){if(Pk(x))return!1;var w=Ik(x.code,d);a.current.add(x[w]),Nk(u,a.current,!1)&&(x.preventDefault(),i(!0))},b=function(x){if(Pk(x))return!1;var w=Ik(x.code,d);Nk(u,a.current,!0)?(i(!1),a.current.clear()):a.current.delete(x[w])},g=function(){a.current.clear(),i(!1)};return t==null||(f=t.target)===null||f===void 0||f.addEventListener("keydown",v),t==null||(h=t.target)===null||h===void 0||h.addEventListener("keyup",b),window.addEventListener("blur",g),function(){var m,x;t==null||(m=t.target)===null||m===void 0||m.removeEventListener("keydown",v),t==null||(x=t.target)===null||x===void 0||x.removeEventListener("keyup",b),window.removeEventListener("blur",g)}}},[e,i]),o});function Nk(e,t,r){return e.filter(function(n){return r||n.length===t.size}).some(function(n){return n.every(function(o){return t.has(o)})})}function Ik(e,t){return t.includes(e)?"code":"key"}function Pk(e){var t,r=((t=e.composedPath)===null||t===void 0?void 0:t.call(e)[0])||e.target;return["INPUT","SELECT","TEXTAREA"].includes(r==null?void 0:r.nodeName)||(r==null?void 0:r.hasAttribute("contenteditable"))}var die=function(t){return{onNodesChange:t.onNodesChange,onEdgesChange:t.onEdgesChange}},fie=(function(e){var t=e.deleteKeyCode,r=e.multiSelectionKeyCode,n=_r(),o=Lt(die,Dr),i=o.onNodesChange,a=o.onEdgesChange,s=hd(t),c=hd(r);R.useEffect(function(){var u=n.getState(),d=u.nodeInternals,f=u.edges,h=u.hasDefaultNodes,v=u.hasDefaultEdges,b=u.onNodesDelete,g=u.onEdgesDelete,m=Array.from(d.values()),x=m.reduce(function(P,A){return(!A.selected&&A.parentNode&&P.find(function(j){return j.id===A.parentNode})||A.selected)&&P.push(A),P},[]),w=f.filter(function(P){return P.selected});if(s&&(x||w)){var E=bB(x,f),S=[].concat(yi(w),yi(E)),_=S.reduce(function(P,A){return P.includes(A.id)||P.push(A.id),P},[]);if((v||h)&&(v&&n.setState({edges:f.filter(function(P){return!_.includes(P.id)})}),h&&(x.forEach(function(P){d.delete(P.id)}),n.setState({nodeInternals:new Map(d)}))),_.length>0&&(g==null||g(S),a)){var C=_.map(function(P){return{id:P,type:"remove"}});a(C)}if(x.length>0&&(b==null||b(x),i)){var N=x.map(function(P){return{id:P.id,type:"remove"}});i(N)}n.setState({nodesSelectionActive:!1})}},[s,i,a]),R.useEffect(function(){n.setState({multiSelectionActive:c})},[c])});function pie(e){var t=_r();R.useEffect(function(){var r,n=function(){if(e.current){var i=V1(e.current);process.env.NODE_ENV==="development"&&(i.height===0||i.width===0)&&console.warn("[React Flow]: The React Flow parent container needs a width and a height to render the graph. Help: https://reactflow.dev/error#400"),t.setState({width:i.width||500,height:i.height||500})}};return n(),window.onresize=n,e.current&&(r=new ResizeObserver(function(){return n()}),r.observe(e.current)),function(){window.onresize=null,r&&e.current&&r.unobserve(e.current)}},[])}var hie=function(t,r){return t.x!==r.x||t.y!==r.y||t.zoom!==r.k},i0=function(t){return{x:t.x,y:t.y,zoom:t.k}},cu=function(t,r){return t.target.closest(".".concat(r))},vie=function(t){return{d3Zoom:t.d3Zoom,d3Selection:t.d3Selection,d3ZoomHandler:t.d3ZoomHandler}},gie=function(t){var r=t.onMove,n=t.onMoveStart,o=t.onMoveEnd,i=t.zoomOnScroll,a=i===void 0?!0:i,s=t.zoomOnPinch,c=s===void 0?!0:s,u=t.panOnScroll,d=u===void 0?!1:u,f=t.panOnScrollSpeed,h=f===void 0?.5:f,v=t.panOnScrollMode,b=v===void 0?ga.Free:v,g=t.zoomOnDoubleClick,m=g===void 0?!0:g,x=t.selectionKeyPressed,w=t.elementsSelectable,E=t.panOnDrag,S=E===void 0?!0:E,_=t.translateExtent,C=t.minZoom,N=t.maxZoom,P=t.defaultZoom,A=P===void 0?1:P,j=t.defaultPosition,M=j===void 0?[0,0]:j,L=t.zoomActivationKeyCode,D=t.preventScrolling,T=D===void 0?!0:D,W=t.children,q=t.noWheelClassName,G=t.noPanClassName,F=_r(),J=R.useRef(!1),z=R.useRef(null),U=R.useRef({x:0,y:0,zoom:0}),oe=Lt(vie,Dr),re=oe.d3Zoom,$=oe.d3Selection,Y=oe.d3ZoomHandler,X=hd(L);return pie(z),R.useEffect(function(){if(z.current){var H,K=eoe().scaleExtent([C,N]).translateExtent(_),Q=Sn(z.current).call(K),ne=ma(M[0],_[0][0],_[1][0]),se=ma(M[1],_[0][1],_[1][1]),te=ma(A,C,N),be=bi.translate(ne,se).scale(te);K.transform(Q,be),F.setState({d3Zoom:K,d3Selection:Q,d3ZoomHandler:Q.on("wheel.zoom"),transform:[ne,se,te],domNode:(H=Q.node())===null||H===void 0?void 0:H.closest(".react-flow")})}},[]),R.useEffect(function(){$&&re&&(d&&!X?$.on("wheel",function(H){if(cu(H,q))return!1;H.preventDefault(),H.stopImmediatePropagation();var K=$.property("__zoom").k||1;if(H.ctrlKey&&c){var Q=Wn(H),ne=-H.deltaY*(H.deltaMode===1?.05:H.deltaMode?1:.002)*10,se=K*Math.pow(2,ne);re.scaleTo($,se,Q);return}var te=H.deltaMode===1?20:1,be=b===ga.Vertical?0:H.deltaX*te,de=b===ga.Horizontal?0:H.deltaY*te;re.translateBy($,-(be/K)*h,-(de/K)*h)}).on("wheel.zoom",null):typeof Y<"u"&&$.on("wheel",function(H){if(!T||cu(H,q))return null;H.preventDefault()}).on("wheel.zoom",Y))},[d,b,$,re,Y,X,c,T,q]),R.useEffect(function(){re&&(x&&!J.current?re.on("zoom",null):x||re.on("zoom",function(H){if(F.setState({transform:[H.transform.x,H.transform.y,H.transform.k]}),r){var K=i0(H.transform);r(H.sourceEvent,K)}}))},[x,re,r]),R.useEffect(function(){re&&re.on("start",function(H){if(J.current=!0,n){var K=i0(H.transform);U.current=K,n(H.sourceEvent,K)}})},[re,n]),R.useEffect(function(){re&&re.on("end",function(H){if(J.current=!1,o&&hie(U.current,H.transform)){var K=i0(H.transform);U.current=K,o(H.sourceEvent,K)}})},[re,o]),R.useEffect(function(){re&&re.filter(function(H){var K=X||a,Q=c&&H.ctrlKey;return!S&&!K&&!d&&!m&&!c||x||!m&&H.type==="dblclick"||cu(H,q)&&H.type==="wheel"||cu(H,G)&&H.type!=="wheel"||!c&&H.ctrlKey&&H.type==="wheel"||!K&&!d&&!Q&&H.type==="wheel"||!S&&(H.type==="mousedown"||H.type==="touchstart")?!1:(!H.ctrlKey||H.type==="wheel")&&!H.button})},[re,a,c,d,m,S,x,w,X]),R.createElement("div",{className:"react-flow__renderer react-flow__container",ref:z},W)};function Tk(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),r.push.apply(r,n)}return r}function Ak(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?Tk(Object(r),!0).forEach(function(n){et(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):Tk(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function kk(e,t){return{x:e.clientX-t.left,y:e.clientY-t.top}}var mie=function(t){return{userSelectionActive:t.userSelectionActive,elementsSelectable:t.elementsSelectable}},Dk={startX:0,startY:0,x:0,y:0,width:0,height:0,draw:!1},bie=R.memo(function(e){var t=e.selectionKeyPressed,r=_r(),n=R.useRef(0),o=R.useRef(0),i=R.useRef(),a=R.useState(Dk),s=Ge(a,2),c=s[0],u=s[1],d=Lt(mie,Dr),f=d.userSelectionActive,h=d.elementsSelectable,v=f||t;if(!h||!v)return null;var b=function(){u(Dk),r.setState({userSelectionActive:!1}),n.current=0,o.current=0},g=function(S){var _=S.target.closest(".react-flow");i.current=_.getBoundingClientRect();var C=kk(S,i.current);u({width:0,height:0,startX:C.x,startY:C.y,x:C.x,y:C.y,draw:!0}),r.setState({userSelectionActive:!0,nodesSelectionActive:!1})},m=function(S){var _,C;if(!(!t||!c.draw||!i.current)){var N=kk(S,i.current),P=(_=c.startX)!==null&&_!==void 0?_:0,A=(C=c.startY)!==null&&C!==void 0?C:0,j=Ak(Ak({},c),{},{x:N.x<P?N.x:P,y:N.y<A?N.y:A,width:Math.abs(N.x-P),height:Math.abs(N.y-A)}),M=r.getState(),L=M.nodeInternals,D=M.edges,T=M.transform,W=M.onNodesChange,q=M.onEdgesChange,G=Array.from(L.values()),F=mB(L,j,T,!1,!0),J=bB(F,D).map(function(re){return re.id}),z=F.map(function(re){return re.id});if(n.current!==z.length){n.current=z.length;var U=ua(G,z);U.length&&(W==null||W(U))}if(o.current!==J.length){o.current=J.length;var oe=ua(D,J);oe.length&&(q==null||q(oe))}u(j)}},x=function(){r.setState({nodesSelectionActive:n.current>0}),b()},w=function(){r.setState({nodesSelectionActive:!1}),b()};return R.createElement("div",{className:"react-flow__selectionpane react-flow__container",onMouseDown:g,onMouseMove:m,onMouseUp:x,onMouseLeave:w},c.draw&&R.createElement("div",{className:"react-flow__selection react-flow__container",style:{width:c.width,height:c.height,transform:"translate(".concat(c.x,"px, ").concat(c.y,"px)")}}))});function Mk(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),r.push.apply(r,n)}return r}function jk(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?Mk(Object(r),!0).forEach(function(n){et(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):Mk(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function jB(e,t){if(!e.parentNode)return!1;var r=t.get(e.parentNode);return r?r.selected?!0:jB(r,t):!1}function Lk(e,t,r){var n=e;do{var o;if((o=n)!==null&&o!==void 0&&o.matches(t))return!0;if(n===r.current)return!1;n=n.parentElement}while(n);return!1}function yie(e,t,r){return Array.from(e.values()).filter(function(n){return(n.selected||n.id===r)&&(!n.parentNode||!jB(n,e))}).map(function(n){var o,i,a,s;return{id:n.id,position:n.position||{x:0,y:0},positionAbsolute:n.positionAbsolute||{x:0,y:0},distance:{x:t.x-((o=(i=n.positionAbsolute)===null||i===void 0?void 0:i.x)!==null&&o!==void 0?o:0),y:t.y-((a=(s=n.positionAbsolute)===null||s===void 0?void 0:s.y)!==null&&a!==void 0?a:0)},delta:{x:0,y:0},extent:n.extent,parentNode:n.parentNode,width:n.width,height:n.height}})}function xie(e,t,r,n,o,i){var a=Ge(n,2),s=a[0],c=a[1],u=e.extent||i,d={x:t.x-e.distance.x,y:t.y-e.distance.y};if(r&&(d.x=s*Math.round(d.x/s),d.y=c*Math.round(d.y/c)),e.extent==="parent")if(e.parentNode&&e.width&&e.height){var f=o.get(e.parentNode);u=f!=null&&f.positionAbsolute&&f!==null&&f!==void 0&&f.width&&f!==null&&f!==void 0&&f.height?[[f.positionAbsolute.x,f.positionAbsolute.y],[f.positionAbsolute.x+f.width-e.width,f.positionAbsolute.y+f.height-e.height]]:u}else process.env.NODE_ENV==="development"&&console.warn("[React Flow]: Only child nodes can use a parent extent. Help: https://reactflow.dev/error#500"),u=i;else if(e.extent&&e.parentNode){var h,v,b,g,m=o.get(e.parentNode),x=(h=m==null||(v=m.positionAbsolute)===null||v===void 0?void 0:v.x)!==null&&h!==void 0?h:0,w=(b=m==null||(g=m.positionAbsolute)===null||g===void 0?void 0:g.y)!==null&&b!==void 0?b:0;u=[[e.extent[0][0]+x,e.extent[0][1]+w],[e.extent[1][0]+x,e.extent[1][1]+w]]}var E={x:0,y:0};if(e.parentNode){var S,_,C,N,P=o.get(e.parentNode);E={x:(S=P==null||(_=P.positionAbsolute)===null||_===void 0?void 0:_.x)!==null&&S!==void 0?S:0,y:(C=P==null||(N=P.positionAbsolute)===null||N===void 0?void 0:N.y)!==null&&C!==void 0?C:0}}return e.positionAbsolute=u?cB(d,u):d,e.position={x:e.positionAbsolute.x-E.x,y:e.positionAbsolute.y-E.y},e}function a0(e){var t=e.nodeId,r=e.dragItems,n=e.nodeInternals,o=r.map(function(i){var a=n.get(i.id);return jk(jk({},a),{},{position:i.position,positionAbsolute:i.positionAbsolute})});return[t?o.find(function(i){return i.id===t}):o[0],o]}function s0(e){return function(t,r,n){return e==null?void 0:e(t,n)}}function LB(e){var t=e.nodeRef,r=e.disabled,n=r===void 0?!1:r,o=e.noDragClassName,i=e.handleSelector,a=e.nodeId,s=e.isSelectable,c=e.selectNodesOnDrag,u=R.useState(!1),d=Ge(u,2),f=d[0],h=d[1],v=_r(),b=R.useRef(),g=R.useRef({x:null,y:null}),m=R.useCallback(function(x){var w=x.sourceEvent,E=v.getState(),S=E.transform,_=E.snapGrid,C=E.snapToGrid,N=w.touches?w.touches[0].clientX:w.clientX,P=w.touches?w.touches[0].clientY:w.clientY,A=gB({x:N,y:P},S,C,_);return A},[]);return R.useEffect(function(){if(t!=null&&t.current){var x=Sn(t.current);if(n)x.on(".drag",null);else{var w=ure().on("start",function(E){var S=v.getState(),_=S.nodeInternals,C=S.multiSelectionActive,N=S.unselectNodesAndEdges,P=S.onNodeDragStart,A=S.onSelectionDragStart,j=a?P:s0(A);if(!c&&!C&&a){var M;(M=_.get(a))!==null&&M!==void 0&&M.selected||N()}a&&s&&c&&vB({id:a,store:v});var L=m(E);if(g.current=L,b.current=yie(_,L,a),j&&b.current){var D=a0({nodeId:a,dragItems:b.current,nodeInternals:_}),T=Ge(D,2),W=T[0],q=T[1];j(E.sourceEvent,W,q)}}).on("drag",function(E){var S=v.getState(),_=S.updateNodePositions,C=S.snapToGrid,N=S.snapGrid,P=S.nodeInternals,A=S.nodeExtent,j=S.onNodeDrag,M=S.onSelectionDrag,L=m(E);if((g.current.x!==L.x||g.current.y!==L.y)&&b.current){g.current=L,b.current=b.current.map(function(F){return xie(F,L,C,N,P,A)});var D=a?j:s0(M);if(_(b.current,!0,!0),h(!0),D){var T=a0({nodeId:a,dragItems:b.current,nodeInternals:P}),W=Ge(T,2),q=W[0],G=W[1];D(E.sourceEvent,q,G)}}E.on("end",function(F){if(h(!1),b.current){var J=v.getState(),z=J.updateNodePositions,U=J.nodeInternals,oe=J.onNodeDragStop,re=J.onSelectionDragStop,$=a?oe:s0(re);if(z(b.current,!1,!1),$){var Y=a0({nodeId:a,dragItems:b.current,nodeInternals:U}),X=Ge(Y,2),H=X[0],K=X[1];$(F.sourceEvent,H,K)}}})}).filter(function(E){var S=E.target,_=!E.button&&(!o||!Lk(S,".".concat(o),t))&&(!i||Lk(S,i,t));return _});return x.call(w),function(){x.on(".drag",null)}}}},[t,n,o,i,s,v,a,c,m]),f}function qk(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),r.push.apply(r,n)}return r}function wie(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?qk(Object(r),!0).forEach(function(n){et(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):qk(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}var _ie=function(t){return wie({transformString:"translate(".concat(t.transform[0],"px,").concat(t.transform[1],"px) scale(").concat(t.transform[2],")"),userSelectionActive:t.userSelectionActive},H1(Array.from(t.nodeInternals.values()).filter(function(r){return r.selected})))},Eie=function(t){var r=Array.from(t.nodeInternals.values()).filter(function(n){return n.selected});return H1(r)};function Sie(e){var t=e.onSelectionContextMenu,r=e.noPanClassName,n=_r(),o=Lt(_ie,Dr),i=o.transformString,a=o.userSelectionActive,s=Lt(Eie,Dr),c=s.width,u=s.height,d=s.x,f=s.y,h=R.useRef(null);if(LB({nodeRef:h}),a||!c||!u)return null;var v=t?function(b){var g=Array.from(n.getState().nodeInternals.values()).filter(function(m){return m.selected});t(b,g)}:void 0;return R.createElement("div",{className:Kr(["react-flow__nodesselection","react-flow__container",r]),style:{transform:i}},R.createElement("div",{ref:h,className:"react-flow__nodesselection-rect",onContextMenu:v,style:{width:c,height:u,top:f,left:d}}))}var Oie=R.memo(Sie),Cie=function(t){return t.nodesSelectionActive},qB=function(t){var r=t.children,n=t.onPaneClick,o=t.onPaneContextMenu,i=t.onPaneScroll,a=t.deleteKeyCode,s=t.onMove,c=t.onMoveStart,u=t.onMoveEnd,d=t.selectionKeyCode,f=t.multiSelectionKeyCode,h=t.zoomActivationKeyCode,v=t.elementsSelectable,b=t.zoomOnScroll,g=t.zoomOnPinch,m=t.panOnScroll,x=t.panOnScrollSpeed,w=t.panOnScrollMode,E=t.zoomOnDoubleClick,S=t.panOnDrag,_=t.translateExtent,C=t.minZoom,N=t.maxZoom,P=t.defaultZoom,A=t.defaultPosition,j=t.preventScrolling,M=t.onSelectionContextMenu,L=t.noWheelClassName,D=t.noPanClassName,T=_r(),W=Lt(Cie),q=hd(d);fie({deleteKeyCode:a,multiSelectionKeyCode:f});var G=function(U){n==null||n(U),T.getState().resetSelectedElements(),T.setState({nodesSelectionActive:!1})},F=o?function(z){return o(z)}:void 0,J=i?function(z){return i(z)}:void 0;return R.createElement(gie,{onMove:s,onMoveStart:c,onMoveEnd:u,selectionKeyPressed:q,elementsSelectable:v,zoomOnScroll:b,zoomOnPinch:g,panOnScroll:m,panOnScrollSpeed:x,panOnScrollMode:w,zoomOnDoubleClick:E,panOnDrag:S,translateExtent:_,minZoom:C,maxZoom:N,defaultZoom:P,defaultPosition:A,zoomActivationKeyCode:h,preventScrolling:j,noWheelClassName:L,noPanClassName:D},r,R.createElement(bie,{selectionKeyPressed:q}),W&&R.createElement(Oie,{onSelectionContextMenu:M,noPanClassName:D}),R.createElement("div",{className:"react-flow__pane react-flow__container",onClick:G,onContextMenu:F,onWheel:J}))};qB.displayName="FlowRenderer";var Rie=R.memo(qB);function Nie(e){var t=Lt(R.useCallback(function(r){return e?mB(r.nodeInternals,{x:0,y:0,width:r.width,height:r.height},r.transform,!0):Array.from(r.nodeInternals.values())},[e]));return t}var Iie=function(t){return{nodesDraggable:t.nodesDraggable,nodesConnectable:t.nodesConnectable,elementsSelectable:t.elementsSelectable,updateNodeDimensions:t.updateNodeDimensions}},zB=function(t){var r=Lt(Iie,Dr),n=r.nodesDraggable,o=r.nodesConnectable,i=r.elementsSelectable,a=r.updateNodeDimensions,s=Nie(t.onlyRenderVisibleElements),c=R.useRef(),u=R.useMemo(function(){if(typeof ResizeObserver>"u")return null;var d=new ResizeObserver(function(f){var h=f.map(function(v){return{id:v.target.getAttribute("data-id"),nodeElement:v.target,forceUpdate:!0}});a(h)});return c.current=d,d},[]);return R.useEffect(function(){return function(){var d;c==null||(d=c.current)===null||d===void 0||d.disconnect()}},[]),R.createElement("div",{className:"react-flow__nodes react-flow__container"},s.map(function(d){var f,h,v,b,g,m,x,w=d.type||"default";t.nodeTypes[w]||(process.env.NODE_ENV==="development"&&console.warn('[React Flow]: Node type "'.concat(w,'" not found. Using fallback type "default". Help: https://reactflow.dev/error#300')),w="default");var E=t.nodeTypes[w]||t.nodeTypes.default,S=!!(d.draggable||n&&typeof d.draggable>"u"),_=!!(d.selectable||i&&typeof d.selectable>"u"),C=!!(d.connectable||o&&typeof d.connectable>"u");return R.createElement(E,{key:d.id,id:d.id,className:d.className,style:d.style,type:w,data:d.data,sourcePosition:d.sourcePosition||Oe.Bottom,targetPosition:d.targetPosition||Oe.Top,hidden:d.hidden,xPos:(f=(h=d.positionAbsolute)===null||h===void 0?void 0:h.x)!==null&&f!==void 0?f:0,yPos:(v=(b=d.positionAbsolute)===null||b===void 0?void 0:b.y)!==null&&v!==void 0?v:0,selectNodesOnDrag:t.selectNodesOnDrag,onClick:t.onNodeClick,onMouseEnter:t.onNodeMouseEnter,onMouseMove:t.onNodeMouseMove,onMouseLeave:t.onNodeMouseLeave,onContextMenu:t.onNodeContextMenu,onDoubleClick:t.onNodeDoubleClick,selected:!!d.selected,isDraggable:S,isSelectable:_,isConnectable:C,resizeObserver:u,dragHandle:d.dragHandle,zIndex:(g=(m=d[ir])===null||m===void 0?void 0:m.z)!==null&&g!==void 0?g:0,isParent:!!((x=d[ir])!==null&&x!==void 0&&x.isParent),noDragClassName:t.noDragClassName,noPanClassName:t.noPanClassName,initialized:!!d.width&&!!d.height})}))};zB.displayName="NodeRenderer";var Pie=R.memo(zB),oa;function zk(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),r.push.apply(r,n)}return r}function Bk(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?zk(Object(r),!0).forEach(function(n){et(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):zk(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}var Tie=(oa={},et(oa,Oe.Left,Oe.Right),et(oa,Oe.Right,Oe.Left),et(oa,Oe.Top,Oe.Bottom),et(oa,Oe.Bottom,Oe.Top),oa),Aie=(function(e){var t,r,n,o,i,a=e.connectionNodeId,s=e.connectionHandleType,c=e.connectionLineStyle,u=e.connectionLineType,d=u===void 0?Uo.Bezier:u,f=e.isConnectable,h=e.CustomConnectionLineComponent,v=Lt(R.useCallback(function(J){return{fromNode:J.nodeInternals.get(a),handleId:J.connectionHandleId,toX:(J.connectionPosition.x-J.transform[0])/J.transform[2],toY:(J.connectionPosition.y-J.transform[1])/J.transform[2]}},[a]),Dr),b=v.fromNode,g=v.handleId,m=v.toX,x=v.toY,w=b==null||(t=b[ir])===null||t===void 0?void 0:t.handleBounds;if(!b||!f||!(w!=null&&w[s]))return null;var E=w[s],S=g?E.find(function(J){return J.id===g}):E[0],_=S?S.x+S.width/2:((r=b==null?void 0:b.width)!==null&&r!==void 0?r:0)/2,C=S?S.y+S.height/2:(n=b==null?void 0:b.height)!==null&&n!==void 0?n:0,N=((b==null||(o=b.positionAbsolute)===null||o===void 0?void 0:o.x)||0)+_,P=((b==null||(i=b.positionAbsolute)===null||i===void 0?void 0:i.y)||0)+C,A=S==null?void 0:S.position;if(!A)return null;var j=Tie[A],M,L,D,T,W,q;switch(s){case"source":M=N,L=P,D=A,T=m,W=x,q=j;break;case"target":M=m,L=x,D=j,T=N,W=P,q=A;break}if(h)return R.createElement("g",{className:"react-flow__connection"},R.createElement(h,{connectionLineType:d,connectionLineStyle:c,fromNode:b,fromHandle:S,fromX:N,fromY:P,toX:m,toY:x,fromPosition:A,toPosition:j,sourcePosition:D,targetPosition:q,sourceNode:b,sourceHandle:S,targetX:T,targetY:W,sourceX:M,sourceY:L}));var G="",F={sourceX:M,sourceY:L,sourcePosition:D,targetX:T,targetY:W,targetPosition:q};return d===Uo.Bezier?G=df(F):d===Uo.Step?G=C_(Bk(Bk({},F),{},{borderRadius:0})):d===Uo.SmoothStep?G=C_(F):d===Uo.SimpleBezier?G=SB(F):G="M".concat(M,",").concat(L," ").concat(T,",").concat(W),R.createElement("g",{className:"react-flow__connection"},R.createElement("path",{d:G,className:"react-flow__connection-path",style:c}))});function P_(e){"@babel/helpers - typeof";return P_=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},P_(e)}var uu,kie=function(t){var r=t.color,n=r===void 0?"none":r,o=t.strokeWidth,i=o===void 0?1:o;return R.createElement("polyline",{stroke:n,strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:i,fill:"none",points:"-5,-4 0,0 -5,4"})},Die=function(t){var r=t.color,n=r===void 0?"none":r,o=t.strokeWidth,i=o===void 0?1:o;return R.createElement("polyline",{stroke:n,strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:i,fill:n,points:"-5,-4 0,0 -5,4 -5,-4"})},Fk=(uu={},et(uu,cd.Arrow,kie),et(uu,cd.ArrowClosed,Die),uu);function Mie(e){var t=R.useMemo(function(){var r=Fk.hasOwnProperty(e);return r?Fk[e]:(process.env.NODE_ENV==="development"&&console.warn('[React Flow]: Marker type "'.concat(e,`" doesn't exist. Help: https://reactflow.dev/error#900`)),function(){return null})},[e]);return t}function $k(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),r.push.apply(r,n)}return r}function jie(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?$k(Object(r),!0).forEach(function(n){et(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):$k(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}var Lie=function(t){var r=t.id,n=t.type,o=t.color,i=t.width,a=i===void 0?12.5:i,s=t.height,c=s===void 0?12.5:s,u=t.markerUnits,d=u===void 0?"strokeWidth":u,f=t.strokeWidth,h=t.orient,v=h===void 0?"auto":h,b=Mie(n);return R.createElement("marker",{className:"react-flow__arrowhead",id:r,markerWidth:"".concat(a),markerHeight:"".concat(c),viewBox:"-10 -10 20 20",markerUnits:d,orient:v,refX:"0",refY:"0"},R.createElement(b,{color:o,strokeWidth:f}))},qie=function(t){var r=t.defaultColor,n=t.rfId;return function(o){var i=[];return o.edges.reduce(function(a,s){return[s.markerStart,s.markerEnd].forEach(function(c){if(c&&P_(c)==="object"){var u=S_(c,n);i.includes(u)||(a.push(jie({id:u,color:c.color||r},c)),i.push(u))}}),a},[]).sort(function(a,s){return a.id.localeCompare(s.id)})}},BB=function(t){var r=t.defaultColor,n=t.rfId,o=Lt(R.useCallback(qie({defaultColor:r,rfId:n}),[r,n]),function(i,a){return!(i.length!==a.length||i.some(function(s,c){return s.id!==a[c].id}))});return R.createElement("defs",null,o.map(function(i){return R.createElement(Lie,{id:i.id,key:i.id,type:i.type,color:i.color,width:i.width,height:i.height,markerUnits:i.markerUnits,strokeWidth:i.strokeWidth,orient:i.orient})}))};BB.displayName="MarkerDefinitions";var zie=R.memo(BB),Bie=[{level:0,isMaxLevel:!0,edges:[]}];function Fie(e,t){var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!1,n=-1,o=e.reduce(function(a,s){var c=dB(s.zIndex),u=c?s.zIndex:0;if(r){var d,f,h,v;u=c?s.zIndex:Math.max(((d=t.get(s.source))===null||d===void 0||(f=d[ir])===null||f===void 0?void 0:f.z)||0,((h=t.get(s.target))===null||h===void 0||(v=h[ir])===null||v===void 0?void 0:v.z)||0)}return a[u]?a[u].push(s):a[u]=[s],n=u>n?u:n,a},{}),i=Object.entries(o).map(function(a){var s=Ge(a,2),c=s[0],u=s[1],d=+c;return{edges:u,level:d,isMaxLevel:d===n}});return i.length===0?Bie:i}function $ie(e,t,r){var n=Lt(R.useCallback(function(o){return e?o.edges.filter(function(i){var a=t.get(i.source),s=t.get(i.target);return(a==null?void 0:a.width)&&(a==null?void 0:a.height)&&(s==null?void 0:s.width)&&(s==null?void 0:s.height)&&cie({sourcePos:a.positionAbsolute||{x:0,y:0},targetPos:s.positionAbsolute||{x:0,y:0},sourceWidth:a.width,sourceHeight:a.height,targetWidth:s.width,targetHeight:s.height,width:o.width,height:o.height,transform:o.transform})}):o.edges},[e,t]));return Fie(n,t,r)}var Vie=function(t){return{connectionNodeId:t.connectionNodeId,connectionHandleType:t.connectionHandleType,nodesConnectable:t.nodesConnectable,elementsSelectable:t.elementsSelectable,width:t.width,height:t.height,connectionMode:t.connectionMode,nodeInternals:t.nodeInternals}},FB=function(t){var r=Lt(Vie,Dr),n=r.connectionNodeId,o=r.connectionHandleType,i=r.nodesConnectable,a=r.elementsSelectable,s=r.width,c=r.height,u=r.connectionMode,d=r.nodeInternals,f=$ie(t.onlyRenderVisibleElements,d,t.elevateEdgesOnSelect);if(!s)return null;var h=t.connectionLineType,v=t.defaultMarkerColor,b=t.connectionLineStyle,g=t.connectionLineComponent,m=t.connectionLineContainerStyle,x=n&&o;return R.createElement(R.Fragment,null,f.map(function(w){var E=w.level,S=w.edges,_=w.isMaxLevel;return R.createElement("svg",{key:E,style:{zIndex:E},width:s,height:c,className:"react-flow__edges react-flow__container"},_&&R.createElement(zie,{defaultColor:v,rfId:t.rfId}),R.createElement("g",null,S.map(function(C){var N=Rk(d,C.source),P=Ge(N,3),A=P[0],j=P[1],M=P[2],L=Rk(d,C.target),D=Ge(L,3),T=D[0],W=D[1],q=D[2];if(!M||!q)return null;var G=C.type||"default";t.edgeTypes[G]||(console.warn('[React Flow]: Edge type "'.concat(G,'" not found. Using fallback type "default". Help: https://reactflow.dev/error#300')),G="default");var F=t.edgeTypes[G]||t.edgeTypes.default,J=u===Ia.Strict?W.target:W.target||W.source,z=Ck(j.source,C.sourceHandle||null),U=Ck(J,C.targetHandle||null),oe=(z==null?void 0:z.position)||Oe.Bottom,re=(U==null?void 0:U.position)||Oe.Top;if(!z)return process.env.NODE_ENV==="development"&&console.warn("[React Flow]: Couldn't create edge for source handle id: ".concat(C.sourceHandle,"; edge id: ").concat(C.id,". Help: https://reactflow.dev/error#800")),null;if(!U)return process.env.NODE_ENV==="development"&&console.warn("[React Flow]: Couldn't create edge for target handle id: ".concat(C.targetHandle,"; edge id: ").concat(C.id,". Help: https://reactflow.dev/error#800")),null;var $=lie(A,z,oe,T,U,re),Y=$.sourceX,X=$.sourceY,H=$.targetX,K=$.targetY;return R.createElement(F,{key:C.id,id:C.id,className:Kr([C.className,t.noPanClassName]),type:G,data:C.data,selected:!!C.selected,animated:!!C.animated,hidden:!!C.hidden,label:C.label,labelStyle:C.labelStyle,labelShowBg:C.labelShowBg,labelBgStyle:C.labelBgStyle,labelBgPadding:C.labelBgPadding,labelBgBorderRadius:C.labelBgBorderRadius,style:C.style,source:C.source,target:C.target,sourceHandleId:C.sourceHandle,targetHandleId:C.targetHandle,markerEnd:C.markerEnd,markerStart:C.markerStart,sourceX:Y,sourceY:X,targetX:H,targetY:K,sourcePosition:oe,targetPosition:re,elementsSelectable:a,onEdgeUpdate:t.onEdgeUpdate,onContextMenu:t.onEdgeContextMenu,onMouseEnter:t.onEdgeMouseEnter,onMouseMove:t.onEdgeMouseMove,onMouseLeave:t.onEdgeMouseLeave,onClick:t.onEdgeClick,edgeUpdaterRadius:t.edgeUpdaterRadius,onEdgeDoubleClick:t.onEdgeDoubleClick,onEdgeUpdateStart:t.onEdgeUpdateStart,onEdgeUpdateEnd:t.onEdgeUpdateEnd,rfId:t.rfId})})))}),x&&R.createElement("svg",{style:m,width:s,height:c,className:"react-flow__edges react-flow__connectionline react-flow__container"},R.createElement(Aie,{connectionNodeId:n,connectionHandleType:o,connectionLineStyle:b,connectionLineType:h,isConnectable:i,CustomConnectionLineComponent:g})))};FB.displayName="EdgeRenderer";var Hie=R.memo(FB),Wie=function(t){return"translate(".concat(t.transform[0],"px,").concat(t.transform[1],"px) scale(").concat(t.transform[2],")")};function Uie(e){var t=e.children,r=Lt(Wie);return R.createElement("div",{className:"react-flow__viewport react-flow__container",style:{transform:r}},t)}function Gie(e){var t=_B(),r=R.useRef(!1);R.useEffect(function(){!r.current&&t.viewportInitialized&&e&&(setTimeout(function(){return e(t)},1),r.current=!0)},[e,t.viewportInitialized])}var $B=function(t){var r=t.nodeTypes,n=t.edgeTypes,o=t.onMove,i=t.onMoveStart,a=t.onMoveEnd,s=t.onInit,c=t.onNodeClick,u=t.onEdgeClick,d=t.onNodeDoubleClick,f=t.onEdgeDoubleClick,h=t.onNodeMouseEnter,v=t.onNodeMouseMove,b=t.onNodeMouseLeave,g=t.onNodeContextMenu,m=t.onSelectionContextMenu,x=t.connectionLineType,w=t.connectionLineStyle,E=t.connectionLineComponent,S=t.connectionLineContainerStyle,_=t.selectionKeyCode,C=t.multiSelectionKeyCode,N=t.zoomActivationKeyCode,P=t.deleteKeyCode,A=t.onlyRenderVisibleElements,j=t.elementsSelectable,M=t.selectNodesOnDrag,L=t.translateExtent,D=t.minZoom,T=t.maxZoom,W=t.defaultZoom,q=t.defaultPosition,G=t.preventScrolling,F=t.defaultMarkerColor,J=t.zoomOnScroll,z=t.zoomOnPinch,U=t.panOnScroll,oe=t.panOnScrollSpeed,re=t.panOnScrollMode,$=t.zoomOnDoubleClick,Y=t.panOnDrag,X=t.onPaneClick,H=t.onPaneScroll,K=t.onPaneContextMenu,Q=t.onEdgeUpdate,ne=t.onEdgeContextMenu,se=t.onEdgeMouseEnter,te=t.onEdgeMouseMove,be=t.onEdgeMouseLeave,de=t.edgeUpdaterRadius,Ee=t.onEdgeUpdateStart,fe=t.onEdgeUpdateEnd,le=t.noDragClassName,Ce=t.noWheelClassName,Te=t.noPanClassName,Fe=t.elevateEdgesOnSelect,Le=t.id;return Gie(s),R.createElement(Rie,{onPaneClick:X,onPaneContextMenu:K,onPaneScroll:H,deleteKeyCode:P,selectionKeyCode:_,multiSelectionKeyCode:C,zoomActivationKeyCode:N,elementsSelectable:j,onMove:o,onMoveStart:i,onMoveEnd:a,zoomOnScroll:J,zoomOnPinch:z,zoomOnDoubleClick:$,panOnScroll:U,panOnScrollSpeed:oe,panOnScrollMode:re,panOnDrag:Y,translateExtent:L,minZoom:D,maxZoom:T,defaultZoom:W,defaultPosition:q,onSelectionContextMenu:m,preventScrolling:G,noDragClassName:le,noWheelClassName:Ce,noPanClassName:Te},R.createElement(Uie,null,R.createElement(Hie,{edgeTypes:n,onEdgeClick:u,onEdgeDoubleClick:f,connectionLineType:x,connectionLineStyle:w,connectionLineComponent:E,connectionLineContainerStyle:S,onEdgeUpdate:Q,onlyRenderVisibleElements:A,onEdgeContextMenu:ne,onEdgeMouseEnter:se,onEdgeMouseMove:te,onEdgeMouseLeave:be,onEdgeUpdateStart:Ee,onEdgeUpdateEnd:fe,edgeUpdaterRadius:de,defaultMarkerColor:F,noPanClassName:Te,elevateEdgesOnSelect:!!Fe,rfId:Le}),R.createElement(Pie,{nodeTypes:r,onNodeClick:c,onNodeDoubleClick:d,onNodeMouseEnter:h,onNodeMouseMove:v,onNodeMouseLeave:b,onNodeContextMenu:g,selectNodesOnDrag:M,onlyRenderVisibleElements:A,noPanClassName:Te,noDragClassName:le})))};$B.displayName="GraphView";var Yie=R.memo($B),VB=function(){return null};VB.displayName="GroupNode";function Vk(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),r.push.apply(r,n)}return r}function Hk(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?Vk(Object(r),!0).forEach(function(n){et(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):Vk(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}var Es=(function(e){var t=function(n){var o=n.id,i=n.type,a=n.data,s=n.xPos,c=n.yPos,u=n.selected,d=n.onClick,f=n.onMouseEnter,h=n.onMouseMove,v=n.onMouseLeave,b=n.onContextMenu,g=n.onDoubleClick,m=n.style,x=n.className,w=n.isDraggable,E=n.isSelectable,S=n.isConnectable,_=n.selectNodesOnDrag,C=n.sourcePosition,N=n.targetPosition,P=n.hidden,A=n.resizeObserver,j=n.dragHandle,M=n.zIndex,L=n.isParent,D=n.noPanClassName,T=n.noDragClassName,W=n.initialized,q=_r(),G=R.useRef(null),F=R.useRef(C),J=R.useRef(N),z=R.useRef(i),U=E||w||d||f||h||v,oe=ws(o,q.getState,f),re=ws(o,q.getState,h),$=ws(o,q.getState,v),Y=ws(o,q.getState,b),X=ws(o,q.getState,g),H=function(ne){if(E&&(!_||!w)&&vB({id:o,store:q}),d){var se=q.getState().nodeInternals.get(o);d(ne,Hk({},se))}};R.useEffect(function(){if(G.current&&!P){var Q=G.current;return A==null||A.observe(Q),function(){return A==null?void 0:A.unobserve(Q)}}},[P]),R.useEffect(function(){var Q=z.current!==i,ne=F.current!==C,se=J.current!==N;G.current&&(Q||ne||se)&&(Q&&(z.current=i),ne&&(F.current=C),se&&(J.current=N),q.getState().updateNodeDimensions([{id:o,nodeElement:G.current,forceUpdate:!0}]))},[o,i,C,N]);var K=LB({nodeRef:G,disabled:P||!w,noDragClassName:T,handleSelector:j,nodeId:o,isSelectable:E,selectNodesOnDrag:_});return P?null:R.createElement("div",{className:Kr(["react-flow__node","react-flow__node-".concat(i),D,x,{selected:u,selectable:E,parent:L}]),ref:G,style:Hk({zIndex:M,transform:"translate(".concat(s,"px,").concat(c,"px)"),pointerEvents:U?"all":"none",visibility:W?"visible":"hidden"},m),onMouseEnter:oe,onMouseMove:re,onMouseLeave:$,onContextMenu:Y,onClick:H,onDoubleClick:X,"data-testid":"rf__node-".concat(o),"data-id":o},R.createElement(Woe,{value:o},R.createElement(e,{id:o,data:a,type:i,xPos:s,yPos:c,selected:u,isConnectable:S,sourcePosition:C,targetPosition:N,dragging:K,dragHandle:j,zIndex:M})))};return t.displayName="NodeWrapper",R.memo(t)});function Wk(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),r.push.apply(r,n)}return r}function Uk(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?Wk(Object(r),!0).forEach(function(n){et(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):Wk(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function Kie(e){var t={input:Es(e.input||kB),default:Es(e.default||I_),output:Es(e.output||MB),group:Es(e.group||VB)},r={},n=Object.keys(e).filter(function(o){return!["input","default","output","group"].includes(o)}).reduce(function(o,i){return o[i]=Es(e[i]||I_),o},r);return Uk(Uk({},t),n)}function Gk(e,t){var r=R.useRef(null),n=R.useMemo(function(){if(process.env.NODE_ENV==="development"){var o=Object.keys(e);Dr(r.current,o)&&console.warn("[React Flow]: It looks like you have created a new nodeTypes or edgeTypes object. If this wasn't on purpose please define the nodeTypes/edgeTypes outside of the component or memoize them. Help: https://reactflow.dev/error#200"),r.current=o}return t(e)},[e]);return n}function Yk(e){if(!(!e||typeof document>"u")){var t=document.head||document.getElementsByTagName("head")[0],r=document.createElement("style");t.appendChild(r),r.appendChild(document.createTextNode(e))}}var HB=function(t){var r=t.children,n=!0;try{_r()}catch{n=!1}return n?R.createElement(R.Fragment,null,r):R.createElement(poe,{createStore:hoe},r)};HB.displayName="ReactFlowWrapper";var Xie=["nodes","edges","defaultNodes","defaultEdges","className","nodeTypes","edgeTypes","onNodeClick","onEdgeClick","onInit","onMove","onMoveStart","onMoveEnd","onConnect","onConnectStart","onConnectStop","onConnectEnd","onClickConnectStart","onClickConnectStop","onClickConnectEnd","onNodeMouseEnter","onNodeMouseMove","onNodeMouseLeave","onNodeContextMenu","onNodeDoubleClick","onNodeDragStart","onNodeDrag","onNodeDragStop","onNodesDelete","onEdgesDelete","onSelectionChange","onSelectionDragStart","onSelectionDrag","onSelectionDragStop","onSelectionContextMenu","connectionMode","connectionLineType","connectionLineStyle","connectionLineComponent","connectionLineContainerStyle","deleteKeyCode","selectionKeyCode","multiSelectionKeyCode","zoomActivationKeyCode","snapToGrid","snapGrid","onlyRenderVisibleElements","selectNodesOnDrag","nodesDraggable","nodesConnectable","elementsSelectable","minZoom","maxZoom","defaultZoom","defaultPosition","translateExtent","preventScrolling","nodeExtent","defaultMarkerColor","zoomOnScroll","zoomOnPinch","panOnScroll","panOnScrollSpeed","panOnScrollMode","zoomOnDoubleClick","panOnDrag","onPaneClick","onPaneScroll","onPaneContextMenu","children","onEdgeUpdate","onEdgeContextMenu","onEdgeDoubleClick","onEdgeMouseEnter","onEdgeMouseMove","onEdgeMouseLeave","onEdgeUpdateStart","onEdgeUpdateEnd","edgeUpdaterRadius","onNodesChange","onEdgesChange","noDragClassName","noWheelClassName","noPanClassName","fitView","fitViewOptions","connectOnClick","attributionPosition","proOptions","defaultEdgeOptions","elevateEdgesOnSelect"];function Kk(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),r.push.apply(r,n)}return r}function Xk(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?Kk(Object(r),!0).forEach(function(n){et(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):Kk(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}Yk(rie),Yk(oie);var Zie={input:kB,default:I_,output:MB},Jie={default:R_,straight:NB,step:RB,smoothstep:U1,simplebezier:OB},Qie=[15,15],eae=[0,0],WB=R.forwardRef(function(e,t){var r=e.nodes,n=e.edges,o=e.defaultNodes,i=e.defaultEdges,a=e.className,s=e.nodeTypes,c=s===void 0?Zie:s,u=e.edgeTypes,d=u===void 0?Jie:u,f=e.onNodeClick,h=e.onEdgeClick,v=e.onInit,b=e.onMove,g=e.onMoveStart,m=e.onMoveEnd,x=e.onConnect,w=e.onConnectStart,E=e.onConnectStop,S=e.onConnectEnd,_=e.onClickConnectStart,C=e.onClickConnectStop,N=e.onClickConnectEnd,P=e.onNodeMouseEnter,A=e.onNodeMouseMove,j=e.onNodeMouseLeave,M=e.onNodeContextMenu,L=e.onNodeDoubleClick,D=e.onNodeDragStart,T=e.onNodeDrag,W=e.onNodeDragStop,q=e.onNodesDelete,G=e.onEdgesDelete,F=e.onSelectionChange,J=e.onSelectionDragStart,z=e.onSelectionDrag,U=e.onSelectionDragStop,oe=e.onSelectionContextMenu,re=e.connectionMode,$=re===void 0?Ia.Strict:re,Y=e.connectionLineType,X=Y===void 0?Uo.Bezier:Y,H=e.connectionLineStyle,K=e.connectionLineComponent,Q=e.connectionLineContainerStyle,ne=e.deleteKeyCode,se=ne===void 0?"Backspace":ne,te=e.selectionKeyCode,be=te===void 0?"Shift":te,de=e.multiSelectionKeyCode,Ee=de===void 0?"Meta":de,fe=e.zoomActivationKeyCode,le=fe===void 0?"Meta":fe,Ce=e.snapToGrid,Te=Ce===void 0?!1:Ce,Fe=e.snapGrid,Le=Fe===void 0?Qie:Fe,Ze=e.onlyRenderVisibleElements,We=Ze===void 0?!1:Ze,St=e.selectNodesOnDrag,tt=St===void 0?!0:St,wt=e.nodesDraggable,Je=e.nodesConnectable,Ne=e.elementsSelectable,je=e.minZoom,Qe=je===void 0?.5:je,At=e.maxZoom,It=At===void 0?2:At,mt=e.defaultZoom,Rt=mt===void 0?1:mt,Qt=e.defaultPosition,fr=Qt===void 0?eae:Qt,pr=e.translateExtent,Xr=pr===void 0?O_:pr,Co=e.preventScrolling,Ka=Co===void 0?!0:Co,$t=e.nodeExtent,Vt=e.defaultMarkerColor,er=Vt===void 0?"#b1b1b7":Vt,jr=e.zoomOnScroll,sr=jr===void 0?!0:jr,Kt=e.zoomOnPinch,hr=Kt===void 0?!0:Kt,Ln=e.panOnScroll,kt=Ln===void 0?!1:Ln,tr=e.panOnScrollSpeed,vr=tr===void 0?.5:tr,yn=e.panOnScrollMode,Sr=yn===void 0?ga.Free:yn,Lr=e.zoomOnDoubleClick,no=Lr===void 0?!0:Lr,ti=e.panOnDrag,jf=ti===void 0?!0:ti,Lf=e.onPaneClick,qf=e.onPaneScroll,zf=e.onPaneContextMenu,Bf=e.children,Bl=e.onEdgeUpdate,Ff=e.onEdgeContextMenu,$f=e.onEdgeDoubleClick,Vf=e.onEdgeMouseEnter,Hf=e.onEdgeMouseMove,Wf=e.onEdgeMouseLeave,Uf=e.onEdgeUpdateStart,ji=e.onEdgeUpdateEnd,Fl=e.edgeUpdaterRadius,Li=Fl===void 0?10:Fl,Gf=e.onNodesChange,Yf=e.onEdgesChange,$l=e.noDragClassName,Vl=$l===void 0?"nodrag":$l,Xa=e.noWheelClassName,Hl=Xa===void 0?"nowheel":Xa,Wl=e.noPanClassName,Kf=Wl===void 0?"nopan":Wl,Ul=e.fitView,Xf=Ul===void 0?!1:Ul,Gl=e.fitViewOptions,Za=e.connectOnClick,Yl=Za===void 0?!0:Za,Ja=e.attributionPosition,Zf=e.proOptions,Kl=e.defaultEdgeOptions,ri=e.elevateEdgesOnSelect,Xl=ri===void 0?!1:ri,qi=cf(e,Xie),Zl=Gk(c,Kie),Jl=Gk(d,sie);return R.createElement("div",Xk(Xk({},qi),{},{ref:t,className:Kr(["react-flow",a])}),R.createElement(HB,null,R.createElement(Yie,{onInit:v,onMove:b,onMoveStart:g,onMoveEnd:m,onNodeClick:f,onEdgeClick:h,onNodeMouseEnter:P,onNodeMouseMove:A,onNodeMouseLeave:j,onNodeContextMenu:M,onNodeDoubleClick:L,nodeTypes:Zl,edgeTypes:Jl,connectionLineType:X,connectionLineStyle:H,connectionLineComponent:K,connectionLineContainerStyle:Q,selectionKeyCode:be,deleteKeyCode:se,multiSelectionKeyCode:Ee,zoomActivationKeyCode:le,onlyRenderVisibleElements:We,selectNodesOnDrag:tt,translateExtent:Xr,minZoom:Qe,maxZoom:It,defaultZoom:Rt,defaultPosition:fr,preventScrolling:Ka,zoomOnScroll:sr,zoomOnPinch:hr,zoomOnDoubleClick:no,panOnScroll:kt,panOnScrollSpeed:vr,panOnScrollMode:Sr,panOnDrag:jf,onPaneClick:Lf,onPaneScroll:qf,onPaneContextMenu:zf,onSelectionContextMenu:oe,onEdgeUpdate:Bl,onEdgeContextMenu:Ff,onEdgeDoubleClick:$f,onEdgeMouseEnter:Vf,onEdgeMouseMove:Hf,onEdgeMouseLeave:Wf,onEdgeUpdateStart:Uf,onEdgeUpdateEnd:ji,edgeUpdaterRadius:Li,defaultMarkerColor:er,noDragClassName:Vl,noWheelClassName:Hl,noPanClassName:Kf,elevateEdgesOnSelect:Xl,id:qi==null?void 0:qi.id}),R.createElement(eie,{nodes:r,edges:n,defaultNodes:o,defaultEdges:i,onConnect:x,onConnectStart:w,onConnectStop:E,onConnectEnd:S,onClickConnectStart:_,onClickConnectStop:C,onClickConnectEnd:N,nodesDraggable:wt,nodesConnectable:Je,elementsSelectable:Ne,minZoom:Qe,maxZoom:It,nodeExtent:$t,onNodesChange:Gf,onEdgesChange:Yf,snapToGrid:Te,snapGrid:Le,connectionMode:$,translateExtent:Xr,connectOnClick:Yl,defaultEdgeOptions:Kl,fitView:Xf,fitViewOptions:Gl,onNodesDelete:q,onEdgesDelete:G,onNodeDragStart:D,onNodeDrag:T,onNodeDragStop:W,onSelectionDrag:z,onSelectionDragStart:J,onSelectionDragStop:U}),F&&R.createElement(Joe,{onSelectionChange:F}),Bf,R.createElement(Loe,{proOptions:Zf,position:Ja})))});WB.displayName="ReactFlow";function UB(e){return function(t){var r=R.useState(t),n=Ge(r,2),o=n[0],i=n[1],a=R.useCallback(function(s){return i(function(c){return e(s,c)})},[]);return[o,i,a]}}var tae=UB(pB),rae=UB(aoe);function Zk(e,t){const{width:r,height:n,positionAbsolute:o}=e,i=t.positionAbsolute,a=r/2,s=n/2,c=o.x+a,u=o.y+s,d=i.x+a,f=i.y+s,h=(d-c)/(2*a)-(f-u)/(2*s),v=(d-c)/(2*a)+(f-u)/(2*s),b=1/(Math.abs(h)+Math.abs(v)),g=b*h,m=b*v,x=a*(g+m)+c,w=s*(-g+m)+u;return{x,y:w}}function Jk(e,t){const r={...e.positionAbsolute,...e},n=Math.round(r.x),o=Math.round(r.y),i=Math.round(t.x),a=Math.round(t.y);return i<=n+1?Oe.Left:i>=n+r.width-1?Oe.Right:a<=o+1?Oe.Top:a>=r.y+r.height-1?Oe.Bottom:Oe.Top}function GB(e,t){const r=Zk(e,t),n=Zk(t,e),o=Jk(e,r),i=Jk(t,n);return{sx:r.x,sy:r.y,tx:n.x,ty:n.y,sourcePos:o,targetPos:i}}const nae=({targetX:e,targetY:t,sourcePosition:r,targetPosition:n,sourceNode:o})=>{if(!o)return null;const i={id:"connection-target",width:1,height:1,position:{x:e,y:t}},{sx:a,sy:s}=GB(o,i),c=df({sourceX:a,sourceY:s,sourcePosition:r,targetPosition:n,targetX:e,targetY:t});return O.jsxs("g",{children:[O.jsx("path",{fill:"none",stroke:"#222",strokeWidth:1.5,className:"animated",d:c}),O.jsx("circle",{cx:e,cy:t,fill:"#fff",r:3,stroke:"#222",strokeWidth:1.5})]})},oae=({id:e,source:t,target:r,markerEnd:n,style:o})=>{const i=Lt(R.useCallback(b=>b.nodeInternals.get(t),[t])),a=Lt(R.useCallback(b=>b.nodeInternals.get(r),[r]));if(!i||!a)return null;const{sx:s,sy:c,tx:u,ty:d,sourcePos:f,targetPos:h}=GB(i,a),v=df({sourceX:s,sourceY:c,sourcePosition:f,targetPosition:h,targetX:u,targetY:d});return O.jsx("path",{id:e,className:"react-flow__edge-path",d:v,markerEnd:n,style:o})},Qk=172,eD=36,iae={custom:oae},aae=(e,t,r="LR")=>{const n=new qA.graphlib.Graph;n.setDefaultEdgeLabel(()=>({}));const o=r==="LR";return n.setGraph({rankdir:r}),e.forEach(i=>{n.setNode(i.id,{width:Qk,height:eD})}),t.forEach(i=>{n.setEdge(i.source,i.target)}),qA.layout(n),e.forEach(i=>{const a=n.node(i.id);return i.targetPosition=o?Oe.Left:Oe.Top,i.sourcePosition=o?Oe.Right:Oe.Bottom,i.position={x:a.x-Qk/2,y:a.y-eD/2},i}),{nodes:e,edges:t}},sae=()=>{},lae=({data:e,dict:t,onSelect:r=sae})=>{const{nodes:n,edges:o}=aae(Object.values(t).filter(f=>f.id===e.selected||e.parents.flat().includes(f.id)||e.children.flat().includes(f.id)).map(f=>({id:f.id,type:f.parents.length===0?"input":f.includes.length===0?"output":"default",sourcePosition:Oe.Right,targetPosition:Oe.Left,data:{label:f.privilege},position:{x:0,y:0},className:f.id===e.selected?"highlighted":"",selected:f.id===e.selected})),e.links.map(({source:f,target:h})=>({id:`e${f}-${h}`,source:f,target:h}))),[i,a,s]=tae(n),[c,u,d]=rae(o);return R.useEffect(()=>{a([...n]),u([...o])},[e]),O.jsx(WB,{nodes:i,edges:c,fitView:!0,onNodesChange:s,onEdgesChange:d,onNodeClick:(f,h)=>{r(h.id)},defaultZoom:.5,edgeTypes:iae,connectionLineComponent:nae,children:O.jsx(Moe,{variant:Si.Dots,color:"#81818140",gap:18,size:1})})};var YB=(e=>(e.method="methods",e.entityCollection="entityselMethod",e.dataClass="dataclassMethod",e.dataStore="dsMethod",e.entity="entityMethod",e.attribute="attributes",e.singletonMethod="singletonMethod",e))(YB||{});const KB=e=>{switch(e){case"entityCollection":return he.ESubPermissionType.ENTITY_SEL_METHOD;case"dataClass":return he.ESubPermissionType.DATACLASS_METHOD;case"dataStore":return he.ESubPermissionType.DS_METHOD;case"entity":return he.ESubPermissionType.ENTITY_METHOD;default:return he.EPermissionType.METHOD}},tD=(e=[],t,r)=>{var o;const n=[];for(const i of e)(o=i[YB[r]])==null||o.forEach(a=>{if(`${i.name.toLowerCase()}.${a.name.toLowerCase()}`.includes(t)||!t){const c={applyTo:`${i.name}.${a.name}`,type:r};r===he.EPermissionType.METHOD&&(c.subType=KB(a.applyTo)),n.push(c)}});return n},cae=(e=[],t)=>{var n;const r=[];for(const o of e)(n=o.methods)==null||n.forEach(i=>{(`${o.name.toLowerCase()}.${i.name.toLowerCase()}`.includes(t)||!t)&&r.push({applyTo:`${o.name}.${i.name}`,type:he.EPermissionType.SINGLETON_METHOD})});return r};function Y1(e,t=[],r=[],n=[]){const o=tD(r,e,he.EPermissionType.ATTRIBUTE),i=tD(r,e,he.EPermissionType.METHOD),a=cae(n,e),s=t.filter(f=>!e||`ds.${f.name.toLowerCase()}`.includes(e)).map(f=>({applyTo:`ds.${f.name}`,type:he.ESubPermissionType.DS_METHOD})),c=[],u=[];return r.filter(f=>f.name.toLowerCase().includes(e)).forEach(f=>{c.push({applyTo:f.name,type:he.EPermissionType.DATACLASS})}),n.filter(f=>f.name.toLowerCase().includes(e)).forEach(f=>{u.push({applyTo:f.name,type:he.EPermissionType.SINGLETON})}),[...[{applyTo:"ds",type:he.EPermissionType.DATASTORE}].filter(f=>!e||`ds.${f.applyTo.toLowerCase()}`.includes(e)),...s,...c,...o,...i,...u,...a].reduce((f,h)=>{const v=["datastore","singleton","dataclass","attribute","dsMethod","dataclassMethod","entityMethod","entityselMethod","singletonMethod"],[b,g]=h.applyTo.split("."),m=f.find(x=>x.prefix===b);return m?(m.resources=[...m.resources,h].sort((x,w)=>{const E=v.indexOf(x.type),S=v.indexOf(w.type);return E>S?1:-1}),m.type=g?m.type:h.type,[...f].sort((x,w)=>{const E=v.indexOf(x.type),S=v.indexOf(w.type);return E>S?1:-1})):[...f,{prefix:b,type:g?null:h.type,resources:[h]}]},[]).reduce((f,h)=>[...f,...h.resources],[])}const uae=(e=[],t=[],r=[])=>{const n=Y1("",e,t,r),o={ds:{applyTo:"ds",type:he.EPermissionType.DATASTORE,methods:[],dataClasses:[],singletons:[]}},i=(s,c)=>s.applyTo.localeCompare(c.applyTo);n.forEach(s=>{const[c,u]=s.applyTo.split(".");if(u||(s.type===he.EPermissionType.DATACLASS?o.ds.dataClasses.push({applyTo:c,type:he.EPermissionType.DATACLASS,methods:[],attributes:[]}):s.type===he.EPermissionType.SINGLETON&&o.ds.singletons.push({applyTo:c,type:he.EPermissionType.SINGLETON,methods:[],attributes:[]})),u){const d=(f,h,v)=>{f.forEach(b=>{b.applyTo===c&&b[h].push(v)})};[he.ESubPermissionType.DS_METHOD,he.ESubPermissionType.DATACLASS_METHOD,he.ESubPermissionType.ENTITY_METHOD,he.ESubPermissionType.ENTITY_SEL_METHOD].includes(s.type)?c==="ds"?o.ds.methods.push(s):d(o.ds.dataClasses,"methods",s):s.type===he.EPermissionType.ATTRIBUTE?(d(o.ds.dataClasses,"attributes",s),d(o.ds.singletons,"attributes",s)):s.type===he.EPermissionType.SINGLETON_METHOD&&d(o.ds.singletons,"methods",s)}});const a=s=>{s.forEach(c=>{c.methods&&c.methods.sort(i),c.attributes&&c.attributes.sort(i)})};return o.ds.methods.sort(i),o.ds.dataClasses.sort(i),o.ds.singletons.sort(i),a(o.ds.dataClasses),a(o.ds.singletons),o},XB=(e,t=[])=>{const r={};return Object.entries(e).forEach(([n,o])=>{r[n]={...o,resources:o.resources.map(i=>{var a,s,c;if(i.type===he.EPermissionType.METHOD&&t.length){const[u,d]=i.resource.split("."),f=u==="ds"?"dataStore":((c=(s=(a=t.find(h=>h.name===u))==null?void 0:a.methods)==null?void 0:s.find(h=>h.name===d))==null?void 0:c.applyTo)||"dataClass";return{...i,type:i.type,subType:KB(f)}}return i})}}),r},ZB=(e,t)=>Object.entries(e).map(([r,n])=>{const o=n.resources.map(i=>{var u,d,f,h,v,b,g,m;const[a,s]=i.resource.split(".");let c=!0;switch(i.type){case he.EPermissionType.DATASTORE:c=!!t;break;case he.EPermissionType.METHOD:a==="ds"?c=!!t.methods.find(x=>x.name===s&&x.applyTo==="dataStore"):c=!!((d=(u=t.dataClasses[a])==null?void 0:u.methods)!=null&&d.find(x=>x.name===s));break;case he.ESubPermissionType.DS_METHOD:c=!!t.methods.find(x=>x.name===s&&x.applyTo==="dataStore");break;case he.EPermissionType.DATACLASS:c=!!t.dataClasses[a];break;case he.EPermissionType.ATTRIBUTE:c=!!((h=(f=t.dataClasses[a])==null?void 0:f.attributes)!=null&&h.find(x=>x.name===s));break;case he.ESubPermissionType.ENTITY_SEL_METHOD:c=!!((v=t.dataClasses[a])!=null&&v.methods.find(x=>x.name===s&&x.applyTo==="entityCollection"));break;case he.ESubPermissionType.DATACLASS_METHOD:c=!!((b=t.dataClasses[a])!=null&&b.methods.find(x=>x.name===s&&x.applyTo==="dataClass"));break;case he.ESubPermissionType.ENTITY_METHOD:c=!!((g=t.dataClasses[a])!=null&&g.methods.find(x=>x.name===s&&x.applyTo==="entity"));break;case he.EPermissionType.SINGLETON_METHOD:c=!!((m=t.singletons[a])!=null&&m.methods.find(x=>x.name===s));break;case he.EPermissionType.SINGLETON:c=!!t.singletons[a];break;default:c=!0}return{...i,exists:c}});return{[r]:{...n,resources:o}}}).reduce((r,n)=>({...r,...n}),{});var l0={exports:{}};/*!
|
|
56
|
+
Copyright (c) 2018 Jed Watson.
|
|
57
|
+
Licensed under the MIT License (MIT), see
|
|
58
|
+
http://jedwatson.github.io/classnames
|
|
59
|
+
*/var rD;function dae(){return rD||(rD=1,(function(e){(function(){var t={}.hasOwnProperty;function r(){for(var i="",a=0;a<arguments.length;a++){var s=arguments[a];s&&(i=o(i,n(s)))}return i}function n(i){if(typeof i=="string"||typeof i=="number")return i;if(typeof i!="object")return"";if(Array.isArray(i))return r.apply(null,i);if(i.toString!==Object.prototype.toString&&!i.toString.toString().includes("[native code]"))return i.toString();var a="";for(var s in i)t.call(i,s)&&i[s]&&(a=o(a,s));return a}function o(i,a){return a?i?i+" "+a:i+a:i}e.exports?(r.default=r,e.exports=r):window.classNames=r})()})(l0)),l0.exports}var fae=dae();const zt=Zo(fae);var Us={exports:{}};/**
|
|
41
60
|
* @license
|
|
42
61
|
* Lodash <https://lodash.com/>
|
|
43
62
|
* Copyright OpenJS Foundation and other contributors <https://openjsf.org/>
|
|
44
63
|
* Released under MIT license <https://lodash.com/license>
|
|
45
64
|
* Based on Underscore.js 1.8.3 <http://underscorejs.org/LICENSE>
|
|
46
65
|
* Copyright Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors
|
|
47
|
-
*/var sZ=Sa.exports,bN;function uZ(){return bN||(bN=1,(function(e,t){(function(){var r,n="4.17.21",i=200,o="Unsupported core-js use. Try https://npms.io/search?q=ponyfill.",a="Expected a function",u="Invalid `variable` option passed into `_.template`",c="__lodash_hash_undefined__",d=500,f="__lodash_placeholder__",h=1,p=2,v=4,m=1,y=2,x=1,b=2,w=4,S=8,E=16,_=32,R=64,I=128,N=256,D=512,k=30,B="...",L=800,j=16,T=1,F=2,$=3,W=1/0,Y=9007199254740991,ee=17976931348623157e292,H=NaN,Q=4294967295,ce=Q-1,se=Q>>>1,z=[["ary",I],["bind",x],["bindKey",b],["curry",S],["curryRight",E],["flip",D],["partial",_],["partialRight",R],["rearg",N]],G="[object Arguments]",J="[object Array]",V="[object AsyncFunction]",K="[object Boolean]",ie="[object Date]",ne="[object DOMException]",ue="[object Error]",de="[object Function]",we="[object GeneratorFunction]",Se="[object Map]",_e="[object Number]",he="[object Null]",ae="[object Object]",Oe="[object Promise]",Ne="[object Proxy]",He="[object RegExp]",qe="[object Set]",Xe="[object String]",We="[object Symbol]",mt="[object Undefined]",et="[object WeakMap]",Tt="[object WeakSet]",ut="[object ArrayBuffer]",tt="[object DataView]",Ct="[object Float32Array]",Jt="[object Float64Array]",lr="[object Int8Array]",Dt="[object Int16Array]",xt="[object Int32Array]",jt="[object Uint8Array]",Hr="[object Uint8ClampedArray]",Yn="[object Uint16Array]",Cn="[object Uint32Array]",Ur=/\b__p \+= '';/g,Pi=/\b(__p \+=) '' \+/g,vl=/(__e\(.*?\)|\b__t\)) \+\n'';/g,ts=/&(?:amp|lt|gt|quot|#39);/g,No=/[&<>"']/g,gl=RegExp(ts.source),rs=RegExp(No.source),ml=/<%-([\s\S]+?)%>/g,ns=/<%([\s\S]+?)%>/g,is=/<%=([\s\S]+?)%>/g,os=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,yl=/^\w*$/,as=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,To=/[\\^$.*+?()[\]{}|]/g,ss=RegExp(To.source),Ao=/^\s+/,us=/\s/,bl=/\{(?:\n\/\* \[wrapped with .+\] \*\/)?\n?/,cs=/\{\n\/\* \[wrapped with (.+)\] \*/,xl=/,? & /,wl=/[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g,_l=/[()=,{}\[\]\/\s]/,El=/\\(\\)?/g,Sl=/\$\{([^\\}]*(?:\\.[^\\}]*)*)\}/g,ls=/\w*$/,Ol=/^[-+]0x[0-9a-f]+$/i,Cl=/^0b[01]+$/i,Rl=/^\[object .+?Constructor\]$/,Il=/^0o[0-7]+$/i,Pl=/^(?:0|[1-9]\d*)$/,Nl=/[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g,Ni=/($^)/,fs=/['\n\r\u2028\u2029\\]/g,Ti="\\ud800-\\udfff",Tl="\\u0300-\\u036f",Al="\\ufe20-\\ufe2f",ds="\\u20d0-\\u20ff",hs=Tl+Al+ds,Mo="\\u2700-\\u27bf",ps="a-z\\xdf-\\xf6\\xf8-\\xff",vs="\\xac\\xb1\\xd7\\xf7",Ml="\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf",gs="\\u2000-\\u206f",Dl=" \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000",ms="A-Z\\xc0-\\xd6\\xd8-\\xde",Do="\\ufe0e\\ufe0f",ys=vs+Ml+gs+Dl,jo="['’]",jl="["+Ti+"]",bs="["+ys+"]",Xn="["+hs+"]",xs="\\d+",Ai="["+Mo+"]",ws="["+ps+"]",_s="[^"+Ti+ys+xs+Mo+ps+ms+"]",ql="\\ud83c[\\udffb-\\udfff]",Zk="(?:"+Xn+"|"+ql+")",Ew="[^"+Ti+"]",kl="(?:\\ud83c[\\udde6-\\uddff]){2}",Ll="[\\ud800-\\udbff][\\udc00-\\udfff]",Mi="["+ms+"]",Sw="\\u200d",Ow="(?:"+ws+"|"+_s+")",Jk="(?:"+Mi+"|"+_s+")",Cw="(?:"+jo+"(?:d|ll|m|re|s|t|ve))?",Rw="(?:"+jo+"(?:D|LL|M|RE|S|T|VE))?",Iw=Zk+"?",Pw="["+Do+"]?",Qk="(?:"+Sw+"(?:"+[Ew,kl,Ll].join("|")+")"+Pw+Iw+")*",eL="\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])",tL="\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])",Nw=Pw+Iw+Qk,rL="(?:"+[Ai,kl,Ll].join("|")+")"+Nw,nL="(?:"+[Ew+Xn+"?",Xn,kl,Ll,jl].join("|")+")",iL=RegExp(jo,"g"),oL=RegExp(Xn,"g"),Bl=RegExp(ql+"(?="+ql+")|"+nL+Nw,"g"),aL=RegExp([Mi+"?"+ws+"+"+Cw+"(?="+[bs,Mi,"$"].join("|")+")",Jk+"+"+Rw+"(?="+[bs,Mi+Ow,"$"].join("|")+")",Mi+"?"+Ow+"+"+Cw,Mi+"+"+Rw,tL,eL,xs,rL].join("|"),"g"),sL=RegExp("["+Sw+Ti+hs+Do+"]"),uL=/[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/,cL=["Array","Buffer","DataView","Date","Error","Float32Array","Float64Array","Function","Int8Array","Int16Array","Int32Array","Map","Math","Object","Promise","RegExp","Set","String","Symbol","TypeError","Uint8Array","Uint8ClampedArray","Uint16Array","Uint32Array","WeakMap","_","clearTimeout","isFinite","parseInt","setTimeout"],lL=-1,st={};st[Ct]=st[Jt]=st[lr]=st[Dt]=st[xt]=st[jt]=st[Hr]=st[Yn]=st[Cn]=!0,st[G]=st[J]=st[ut]=st[K]=st[tt]=st[ie]=st[ue]=st[de]=st[Se]=st[_e]=st[ae]=st[He]=st[qe]=st[Xe]=st[et]=!1;var ot={};ot[G]=ot[J]=ot[ut]=ot[tt]=ot[K]=ot[ie]=ot[Ct]=ot[Jt]=ot[lr]=ot[Dt]=ot[xt]=ot[Se]=ot[_e]=ot[ae]=ot[He]=ot[qe]=ot[Xe]=ot[We]=ot[jt]=ot[Hr]=ot[Yn]=ot[Cn]=!0,ot[ue]=ot[de]=ot[et]=!1;var fL={À:"A",Á:"A",Â:"A",Ã:"A",Ä:"A",Å:"A",à:"a",á:"a",â:"a",ã:"a",ä:"a",å:"a",Ç:"C",ç:"c",Ð:"D",ð:"d",È:"E",É:"E",Ê:"E",Ë:"E",è:"e",é:"e",ê:"e",ë:"e",Ì:"I",Í:"I",Î:"I",Ï:"I",ì:"i",í:"i",î:"i",ï:"i",Ñ:"N",ñ:"n",Ò:"O",Ó:"O",Ô:"O",Õ:"O",Ö:"O",Ø:"O",ò:"o",ó:"o",ô:"o",õ:"o",ö:"o",ø:"o",Ù:"U",Ú:"U",Û:"U",Ü:"U",ù:"u",ú:"u",û:"u",ü:"u",Ý:"Y",ý:"y",ÿ:"y",Æ:"Ae",æ:"ae",Þ:"Th",þ:"th",ß:"ss",Ā:"A",Ă:"A",Ą:"A",ā:"a",ă:"a",ą:"a",Ć:"C",Ĉ:"C",Ċ:"C",Č:"C",ć:"c",ĉ:"c",ċ:"c",č:"c",Ď:"D",Đ:"D",ď:"d",đ:"d",Ē:"E",Ĕ:"E",Ė:"E",Ę:"E",Ě:"E",ē:"e",ĕ:"e",ė:"e",ę:"e",ě:"e",Ĝ:"G",Ğ:"G",Ġ:"G",Ģ:"G",ĝ:"g",ğ:"g",ġ:"g",ģ:"g",Ĥ:"H",Ħ:"H",ĥ:"h",ħ:"h",Ĩ:"I",Ī:"I",Ĭ:"I",Į:"I",İ:"I",ĩ:"i",ī:"i",ĭ:"i",į:"i",ı:"i",Ĵ:"J",ĵ:"j",Ķ:"K",ķ:"k",ĸ:"k",Ĺ:"L",Ļ:"L",Ľ:"L",Ŀ:"L",Ł:"L",ĺ:"l",ļ:"l",ľ:"l",ŀ:"l",ł:"l",Ń:"N",Ņ:"N",Ň:"N",Ŋ:"N",ń:"n",ņ:"n",ň:"n",ŋ:"n",Ō:"O",Ŏ:"O",Ő:"O",ō:"o",ŏ:"o",ő:"o",Ŕ:"R",Ŗ:"R",Ř:"R",ŕ:"r",ŗ:"r",ř:"r",Ś:"S",Ŝ:"S",Ş:"S",Š:"S",ś:"s",ŝ:"s",ş:"s",š:"s",Ţ:"T",Ť:"T",Ŧ:"T",ţ:"t",ť:"t",ŧ:"t",Ũ:"U",Ū:"U",Ŭ:"U",Ů:"U",Ű:"U",Ų:"U",ũ:"u",ū:"u",ŭ:"u",ů:"u",ű:"u",ų:"u",Ŵ:"W",ŵ:"w",Ŷ:"Y",ŷ:"y",Ÿ:"Y",Ź:"Z",Ż:"Z",Ž:"Z",ź:"z",ż:"z",ž:"z",IJ:"IJ",ij:"ij",Œ:"Oe",œ:"oe",ʼn:"'n",ſ:"s"},dL={"&":"&","<":"<",">":">",'"':""","'":"'"},hL={"&":"&","<":"<",">":">",""":'"',"'":"'"},pL={"\\":"\\","'":"'","\n":"n","\r":"r","\u2028":"u2028","\u2029":"u2029"},vL=parseFloat,gL=parseInt,Tw=typeof ht=="object"&&ht&&ht.Object===Object&&ht,mL=typeof self=="object"&&self&&self.Object===Object&&self,Rt=Tw||mL||Function("return this")(),Fl=t&&!t.nodeType&&t,Zn=Fl&&!0&&e&&!e.nodeType&&e,Aw=Zn&&Zn.exports===Fl,$l=Aw&&Tw.process,fr=(function(){try{var te=Zn&&Zn.require&&Zn.require("util").types;return te||$l&&$l.binding&&$l.binding("util")}catch{}})(),Mw=fr&&fr.isArrayBuffer,Dw=fr&&fr.isDate,jw=fr&&fr.isMap,qw=fr&&fr.isRegExp,kw=fr&&fr.isSet,Lw=fr&&fr.isTypedArray;function Qt(te,fe,oe){switch(oe.length){case 0:return te.call(fe);case 1:return te.call(fe,oe[0]);case 2:return te.call(fe,oe[0],oe[1]);case 3:return te.call(fe,oe[0],oe[1],oe[2])}return te.apply(fe,oe)}function yL(te,fe,oe,Ee){for(var Ae=-1,Ue=te==null?0:te.length;++Ae<Ue;){var wt=te[Ae];fe(Ee,wt,oe(wt),te)}return Ee}function dr(te,fe){for(var oe=-1,Ee=te==null?0:te.length;++oe<Ee&&fe(te[oe],oe,te)!==!1;);return te}function bL(te,fe){for(var oe=te==null?0:te.length;oe--&&fe(te[oe],oe,te)!==!1;);return te}function Bw(te,fe){for(var oe=-1,Ee=te==null?0:te.length;++oe<Ee;)if(!fe(te[oe],oe,te))return!1;return!0}function Rn(te,fe){for(var oe=-1,Ee=te==null?0:te.length,Ae=0,Ue=[];++oe<Ee;){var wt=te[oe];fe(wt,oe,te)&&(Ue[Ae++]=wt)}return Ue}function Es(te,fe){var oe=te==null?0:te.length;return!!oe&&Di(te,fe,0)>-1}function zl(te,fe,oe){for(var Ee=-1,Ae=te==null?0:te.length;++Ee<Ae;)if(oe(fe,te[Ee]))return!0;return!1}function ct(te,fe){for(var oe=-1,Ee=te==null?0:te.length,Ae=Array(Ee);++oe<Ee;)Ae[oe]=fe(te[oe],oe,te);return Ae}function In(te,fe){for(var oe=-1,Ee=fe.length,Ae=te.length;++oe<Ee;)te[Ae+oe]=fe[oe];return te}function Hl(te,fe,oe,Ee){var Ae=-1,Ue=te==null?0:te.length;for(Ee&&Ue&&(oe=te[++Ae]);++Ae<Ue;)oe=fe(oe,te[Ae],Ae,te);return oe}function xL(te,fe,oe,Ee){var Ae=te==null?0:te.length;for(Ee&&Ae&&(oe=te[--Ae]);Ae--;)oe=fe(oe,te[Ae],Ae,te);return oe}function Ul(te,fe){for(var oe=-1,Ee=te==null?0:te.length;++oe<Ee;)if(fe(te[oe],oe,te))return!0;return!1}var wL=Vl("length");function _L(te){return te.split("")}function EL(te){return te.match(wl)||[]}function Fw(te,fe,oe){var Ee;return oe(te,function(Ae,Ue,wt){if(fe(Ae,Ue,wt))return Ee=Ue,!1}),Ee}function Ss(te,fe,oe,Ee){for(var Ae=te.length,Ue=oe+(Ee?1:-1);Ee?Ue--:++Ue<Ae;)if(fe(te[Ue],Ue,te))return Ue;return-1}function Di(te,fe,oe){return fe===fe?jL(te,fe,oe):Ss(te,$w,oe)}function SL(te,fe,oe,Ee){for(var Ae=oe-1,Ue=te.length;++Ae<Ue;)if(Ee(te[Ae],fe))return Ae;return-1}function $w(te){return te!==te}function zw(te,fe){var oe=te==null?0:te.length;return oe?Gl(te,fe)/oe:H}function Vl(te){return function(fe){return fe==null?r:fe[te]}}function Wl(te){return function(fe){return te==null?r:te[fe]}}function Hw(te,fe,oe,Ee,Ae){return Ae(te,function(Ue,wt,rt){oe=Ee?(Ee=!1,Ue):fe(oe,Ue,wt,rt)}),oe}function OL(te,fe){var oe=te.length;for(te.sort(fe);oe--;)te[oe]=te[oe].value;return te}function Gl(te,fe){for(var oe,Ee=-1,Ae=te.length;++Ee<Ae;){var Ue=fe(te[Ee]);Ue!==r&&(oe=oe===r?Ue:oe+Ue)}return oe}function Kl(te,fe){for(var oe=-1,Ee=Array(te);++oe<te;)Ee[oe]=fe(oe);return Ee}function CL(te,fe){return ct(fe,function(oe){return[oe,te[oe]]})}function Uw(te){return te&&te.slice(0,Kw(te)+1).replace(Ao,"")}function er(te){return function(fe){return te(fe)}}function Yl(te,fe){return ct(fe,function(oe){return te[oe]})}function qo(te,fe){return te.has(fe)}function Vw(te,fe){for(var oe=-1,Ee=te.length;++oe<Ee&&Di(fe,te[oe],0)>-1;);return oe}function Ww(te,fe){for(var oe=te.length;oe--&&Di(fe,te[oe],0)>-1;);return oe}function RL(te,fe){for(var oe=te.length,Ee=0;oe--;)te[oe]===fe&&++Ee;return Ee}var IL=Wl(fL),PL=Wl(dL);function NL(te){return"\\"+pL[te]}function TL(te,fe){return te==null?r:te[fe]}function ji(te){return sL.test(te)}function AL(te){return uL.test(te)}function ML(te){for(var fe,oe=[];!(fe=te.next()).done;)oe.push(fe.value);return oe}function Xl(te){var fe=-1,oe=Array(te.size);return te.forEach(function(Ee,Ae){oe[++fe]=[Ae,Ee]}),oe}function Gw(te,fe){return function(oe){return te(fe(oe))}}function Pn(te,fe){for(var oe=-1,Ee=te.length,Ae=0,Ue=[];++oe<Ee;){var wt=te[oe];(wt===fe||wt===f)&&(te[oe]=f,Ue[Ae++]=oe)}return Ue}function Os(te){var fe=-1,oe=Array(te.size);return te.forEach(function(Ee){oe[++fe]=Ee}),oe}function DL(te){var fe=-1,oe=Array(te.size);return te.forEach(function(Ee){oe[++fe]=[Ee,Ee]}),oe}function jL(te,fe,oe){for(var Ee=oe-1,Ae=te.length;++Ee<Ae;)if(te[Ee]===fe)return Ee;return-1}function qL(te,fe,oe){for(var Ee=oe+1;Ee--;)if(te[Ee]===fe)return Ee;return Ee}function qi(te){return ji(te)?LL(te):wL(te)}function Pr(te){return ji(te)?BL(te):_L(te)}function Kw(te){for(var fe=te.length;fe--&&us.test(te.charAt(fe)););return fe}var kL=Wl(hL);function LL(te){for(var fe=Bl.lastIndex=0;Bl.test(te);)++fe;return fe}function BL(te){return te.match(Bl)||[]}function FL(te){return te.match(aL)||[]}var $L=(function te(fe){fe=fe==null?Rt:ki.defaults(Rt.Object(),fe,ki.pick(Rt,cL));var oe=fe.Array,Ee=fe.Date,Ae=fe.Error,Ue=fe.Function,wt=fe.Math,rt=fe.Object,Zl=fe.RegExp,zL=fe.String,hr=fe.TypeError,Cs=oe.prototype,HL=Ue.prototype,Li=rt.prototype,Rs=fe["__core-js_shared__"],Is=HL.toString,Ze=Li.hasOwnProperty,UL=0,Yw=(function(){var s=/[^.]+$/.exec(Rs&&Rs.keys&&Rs.keys.IE_PROTO||"");return s?"Symbol(src)_1."+s:""})(),Ps=Li.toString,VL=Is.call(rt),WL=Rt._,GL=Zl("^"+Is.call(Ze).replace(To,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),Ns=Aw?fe.Buffer:r,Nn=fe.Symbol,Ts=fe.Uint8Array,Xw=Ns?Ns.allocUnsafe:r,As=Gw(rt.getPrototypeOf,rt),Zw=rt.create,Jw=Li.propertyIsEnumerable,Ms=Cs.splice,Qw=Nn?Nn.isConcatSpreadable:r,ko=Nn?Nn.iterator:r,Jn=Nn?Nn.toStringTag:r,Ds=(function(){try{var s=ni(rt,"defineProperty");return s({},"",{}),s}catch{}})(),KL=fe.clearTimeout!==Rt.clearTimeout&&fe.clearTimeout,YL=Ee&&Ee.now!==Rt.Date.now&&Ee.now,XL=fe.setTimeout!==Rt.setTimeout&&fe.setTimeout,js=wt.ceil,qs=wt.floor,Jl=rt.getOwnPropertySymbols,ZL=Ns?Ns.isBuffer:r,e_=fe.isFinite,JL=Cs.join,QL=Gw(rt.keys,rt),_t=wt.max,At=wt.min,eB=Ee.now,tB=fe.parseInt,t_=wt.random,rB=Cs.reverse,Ql=ni(fe,"DataView"),Lo=ni(fe,"Map"),ef=ni(fe,"Promise"),Bi=ni(fe,"Set"),Bo=ni(fe,"WeakMap"),Fo=ni(rt,"create"),ks=Bo&&new Bo,Fi={},nB=ii(Ql),iB=ii(Lo),oB=ii(ef),aB=ii(Bi),sB=ii(Bo),Ls=Nn?Nn.prototype:r,$o=Ls?Ls.valueOf:r,r_=Ls?Ls.toString:r;function M(s){if(dt(s)&&!Me(s)&&!(s instanceof Fe)){if(s instanceof pr)return s;if(Ze.call(s,"__wrapped__"))return n1(s)}return new pr(s)}var $i=(function(){function s(){}return function(l){if(!ft(l))return{};if(Zw)return Zw(l);s.prototype=l;var g=new s;return s.prototype=r,g}})();function Bs(){}function pr(s,l){this.__wrapped__=s,this.__actions__=[],this.__chain__=!!l,this.__index__=0,this.__values__=r}M.templateSettings={escape:ml,evaluate:ns,interpolate:is,variable:"",imports:{_:M}},M.prototype=Bs.prototype,M.prototype.constructor=M,pr.prototype=$i(Bs.prototype),pr.prototype.constructor=pr;function Fe(s){this.__wrapped__=s,this.__actions__=[],this.__dir__=1,this.__filtered__=!1,this.__iteratees__=[],this.__takeCount__=Q,this.__views__=[]}function uB(){var s=new Fe(this.__wrapped__);return s.__actions__=zt(this.__actions__),s.__dir__=this.__dir__,s.__filtered__=this.__filtered__,s.__iteratees__=zt(this.__iteratees__),s.__takeCount__=this.__takeCount__,s.__views__=zt(this.__views__),s}function cB(){if(this.__filtered__){var s=new Fe(this);s.__dir__=-1,s.__filtered__=!0}else s=this.clone(),s.__dir__*=-1;return s}function lB(){var s=this.__wrapped__.value(),l=this.__dir__,g=Me(s),O=l<0,P=g?s.length:0,q=_F(0,P,this.__views__),U=q.start,X=q.end,re=X-U,pe=O?X:U-1,ge=this.__iteratees__,me=ge.length,be=0,Ce=At(re,this.__takeCount__);if(!g||!O&&P==re&&Ce==re)return C_(s,this.__actions__);var Ie=[];e:for(;re--&&be<Ce;){pe+=l;for(var je=-1,Pe=s[pe];++je<me;){var Le=ge[je],$e=Le.iteratee,nr=Le.type,Lt=$e(Pe);if(nr==F)Pe=Lt;else if(!Lt){if(nr==T)continue e;break e}}Ie[be++]=Pe}return Ie}Fe.prototype=$i(Bs.prototype),Fe.prototype.constructor=Fe;function Qn(s){var l=-1,g=s==null?0:s.length;for(this.clear();++l<g;){var O=s[l];this.set(O[0],O[1])}}function fB(){this.__data__=Fo?Fo(null):{},this.size=0}function dB(s){var l=this.has(s)&&delete this.__data__[s];return this.size-=l?1:0,l}function hB(s){var l=this.__data__;if(Fo){var g=l[s];return g===c?r:g}return Ze.call(l,s)?l[s]:r}function pB(s){var l=this.__data__;return Fo?l[s]!==r:Ze.call(l,s)}function vB(s,l){var g=this.__data__;return this.size+=this.has(s)?0:1,g[s]=Fo&&l===r?c:l,this}Qn.prototype.clear=fB,Qn.prototype.delete=dB,Qn.prototype.get=hB,Qn.prototype.has=pB,Qn.prototype.set=vB;function un(s){var l=-1,g=s==null?0:s.length;for(this.clear();++l<g;){var O=s[l];this.set(O[0],O[1])}}function gB(){this.__data__=[],this.size=0}function mB(s){var l=this.__data__,g=Fs(l,s);if(g<0)return!1;var O=l.length-1;return g==O?l.pop():Ms.call(l,g,1),--this.size,!0}function yB(s){var l=this.__data__,g=Fs(l,s);return g<0?r:l[g][1]}function bB(s){return Fs(this.__data__,s)>-1}function xB(s,l){var g=this.__data__,O=Fs(g,s);return O<0?(++this.size,g.push([s,l])):g[O][1]=l,this}un.prototype.clear=gB,un.prototype.delete=mB,un.prototype.get=yB,un.prototype.has=bB,un.prototype.set=xB;function cn(s){var l=-1,g=s==null?0:s.length;for(this.clear();++l<g;){var O=s[l];this.set(O[0],O[1])}}function wB(){this.size=0,this.__data__={hash:new Qn,map:new(Lo||un),string:new Qn}}function _B(s){var l=Js(this,s).delete(s);return this.size-=l?1:0,l}function EB(s){return Js(this,s).get(s)}function SB(s){return Js(this,s).has(s)}function OB(s,l){var g=Js(this,s),O=g.size;return g.set(s,l),this.size+=g.size==O?0:1,this}cn.prototype.clear=wB,cn.prototype.delete=_B,cn.prototype.get=EB,cn.prototype.has=SB,cn.prototype.set=OB;function ei(s){var l=-1,g=s==null?0:s.length;for(this.__data__=new cn;++l<g;)this.add(s[l])}function CB(s){return this.__data__.set(s,c),this}function RB(s){return this.__data__.has(s)}ei.prototype.add=ei.prototype.push=CB,ei.prototype.has=RB;function Nr(s){var l=this.__data__=new un(s);this.size=l.size}function IB(){this.__data__=new un,this.size=0}function PB(s){var l=this.__data__,g=l.delete(s);return this.size=l.size,g}function NB(s){return this.__data__.get(s)}function TB(s){return this.__data__.has(s)}function AB(s,l){var g=this.__data__;if(g instanceof un){var O=g.__data__;if(!Lo||O.length<i-1)return O.push([s,l]),this.size=++g.size,this;g=this.__data__=new cn(O)}return g.set(s,l),this.size=g.size,this}Nr.prototype.clear=IB,Nr.prototype.delete=PB,Nr.prototype.get=NB,Nr.prototype.has=TB,Nr.prototype.set=AB;function n_(s,l){var g=Me(s),O=!g&&oi(s),P=!g&&!O&&jn(s),q=!g&&!O&&!P&&Vi(s),U=g||O||P||q,X=U?Kl(s.length,zL):[],re=X.length;for(var pe in s)(l||Ze.call(s,pe))&&!(U&&(pe=="length"||P&&(pe=="offset"||pe=="parent")||q&&(pe=="buffer"||pe=="byteLength"||pe=="byteOffset")||hn(pe,re)))&&X.push(pe);return X}function i_(s){var l=s.length;return l?s[df(0,l-1)]:r}function MB(s,l){return Qs(zt(s),ti(l,0,s.length))}function DB(s){return Qs(zt(s))}function tf(s,l,g){(g!==r&&!Tr(s[l],g)||g===r&&!(l in s))&&ln(s,l,g)}function zo(s,l,g){var O=s[l];(!(Ze.call(s,l)&&Tr(O,g))||g===r&&!(l in s))&&ln(s,l,g)}function Fs(s,l){for(var g=s.length;g--;)if(Tr(s[g][0],l))return g;return-1}function jB(s,l,g,O){return Tn(s,function(P,q,U){l(O,P,g(P),U)}),O}function o_(s,l){return s&&Wr(l,St(l),s)}function qB(s,l){return s&&Wr(l,Ut(l),s)}function ln(s,l,g){l=="__proto__"&&Ds?Ds(s,l,{configurable:!0,enumerable:!0,value:g,writable:!0}):s[l]=g}function rf(s,l){for(var g=-1,O=l.length,P=oe(O),q=s==null;++g<O;)P[g]=q?r:kf(s,l[g]);return P}function ti(s,l,g){return s===s&&(g!==r&&(s=s<=g?s:g),l!==r&&(s=s>=l?s:l)),s}function vr(s,l,g,O,P,q){var U,X=l&h,re=l&p,pe=l&v;if(g&&(U=P?g(s,O,P,q):g(s)),U!==r)return U;if(!ft(s))return s;var ge=Me(s);if(ge){if(U=SF(s),!X)return zt(s,U)}else{var me=Mt(s),be=me==de||me==we;if(jn(s))return P_(s,X);if(me==ae||me==G||be&&!P){if(U=re||be?{}:K_(s),!X)return re?hF(s,qB(U,s)):dF(s,o_(U,s))}else{if(!ot[me])return P?s:{};U=OF(s,me,X)}}q||(q=new Nr);var Ce=q.get(s);if(Ce)return Ce;q.set(s,U),E1(s)?s.forEach(function(Pe){U.add(vr(Pe,l,g,Pe,s,q))}):w1(s)&&s.forEach(function(Pe,Le){U.set(Le,vr(Pe,l,g,Le,s,q))});var Ie=pe?re?Ef:_f:re?Ut:St,je=ge?r:Ie(s);return dr(je||s,function(Pe,Le){je&&(Le=Pe,Pe=s[Le]),zo(U,Le,vr(Pe,l,g,Le,s,q))}),U}function kB(s){var l=St(s);return function(g){return a_(g,s,l)}}function a_(s,l,g){var O=g.length;if(s==null)return!O;for(s=rt(s);O--;){var P=g[O],q=l[P],U=s[P];if(U===r&&!(P in s)||!q(U))return!1}return!0}function s_(s,l,g){if(typeof s!="function")throw new hr(a);return Yo(function(){s.apply(r,g)},l)}function Ho(s,l,g,O){var P=-1,q=Es,U=!0,X=s.length,re=[],pe=l.length;if(!X)return re;g&&(l=ct(l,er(g))),O?(q=zl,U=!1):l.length>=i&&(q=qo,U=!1,l=new ei(l));e:for(;++P<X;){var ge=s[P],me=g==null?ge:g(ge);if(ge=O||ge!==0?ge:0,U&&me===me){for(var be=pe;be--;)if(l[be]===me)continue e;re.push(ge)}else q(l,me,O)||re.push(ge)}return re}var Tn=D_(Vr),u_=D_(of,!0);function LB(s,l){var g=!0;return Tn(s,function(O,P,q){return g=!!l(O,P,q),g}),g}function $s(s,l,g){for(var O=-1,P=s.length;++O<P;){var q=s[O],U=l(q);if(U!=null&&(X===r?U===U&&!rr(U):g(U,X)))var X=U,re=q}return re}function BB(s,l,g,O){var P=s.length;for(g=De(g),g<0&&(g=-g>P?0:P+g),O=O===r||O>P?P:De(O),O<0&&(O+=P),O=g>O?0:O1(O);g<O;)s[g++]=l;return s}function c_(s,l){var g=[];return Tn(s,function(O,P,q){l(O,P,q)&&g.push(O)}),g}function It(s,l,g,O,P){var q=-1,U=s.length;for(g||(g=RF),P||(P=[]);++q<U;){var X=s[q];l>0&&g(X)?l>1?It(X,l-1,g,O,P):In(P,X):O||(P[P.length]=X)}return P}var nf=j_(),l_=j_(!0);function Vr(s,l){return s&&nf(s,l,St)}function of(s,l){return s&&l_(s,l,St)}function zs(s,l){return Rn(l,function(g){return pn(s[g])})}function ri(s,l){l=Mn(l,s);for(var g=0,O=l.length;s!=null&&g<O;)s=s[Gr(l[g++])];return g&&g==O?s:r}function f_(s,l,g){var O=l(s);return Me(s)?O:In(O,g(s))}function qt(s){return s==null?s===r?mt:he:Jn&&Jn in rt(s)?wF(s):DF(s)}function af(s,l){return s>l}function FB(s,l){return s!=null&&Ze.call(s,l)}function $B(s,l){return s!=null&&l in rt(s)}function zB(s,l,g){return s>=At(l,g)&&s<_t(l,g)}function sf(s,l,g){for(var O=g?zl:Es,P=s[0].length,q=s.length,U=q,X=oe(q),re=1/0,pe=[];U--;){var ge=s[U];U&&l&&(ge=ct(ge,er(l))),re=At(ge.length,re),X[U]=!g&&(l||P>=120&&ge.length>=120)?new ei(U&&ge):r}ge=s[0];var me=-1,be=X[0];e:for(;++me<P&&pe.length<re;){var Ce=ge[me],Ie=l?l(Ce):Ce;if(Ce=g||Ce!==0?Ce:0,!(be?qo(be,Ie):O(pe,Ie,g))){for(U=q;--U;){var je=X[U];if(!(je?qo(je,Ie):O(s[U],Ie,g)))continue e}be&&be.push(Ie),pe.push(Ce)}}return pe}function HB(s,l,g,O){return Vr(s,function(P,q,U){l(O,g(P),q,U)}),O}function Uo(s,l,g){l=Mn(l,s),s=J_(s,l);var O=s==null?s:s[Gr(mr(l))];return O==null?r:Qt(O,s,g)}function d_(s){return dt(s)&&qt(s)==G}function UB(s){return dt(s)&&qt(s)==ut}function VB(s){return dt(s)&&qt(s)==ie}function Vo(s,l,g,O,P){return s===l?!0:s==null||l==null||!dt(s)&&!dt(l)?s!==s&&l!==l:WB(s,l,g,O,Vo,P)}function WB(s,l,g,O,P,q){var U=Me(s),X=Me(l),re=U?J:Mt(s),pe=X?J:Mt(l);re=re==G?ae:re,pe=pe==G?ae:pe;var ge=re==ae,me=pe==ae,be=re==pe;if(be&&jn(s)){if(!jn(l))return!1;U=!0,ge=!1}if(be&&!ge)return q||(q=new Nr),U||Vi(s)?V_(s,l,g,O,P,q):bF(s,l,re,g,O,P,q);if(!(g&m)){var Ce=ge&&Ze.call(s,"__wrapped__"),Ie=me&&Ze.call(l,"__wrapped__");if(Ce||Ie){var je=Ce?s.value():s,Pe=Ie?l.value():l;return q||(q=new Nr),P(je,Pe,g,O,q)}}return be?(q||(q=new Nr),xF(s,l,g,O,P,q)):!1}function GB(s){return dt(s)&&Mt(s)==Se}function uf(s,l,g,O){var P=g.length,q=P,U=!O;if(s==null)return!q;for(s=rt(s);P--;){var X=g[P];if(U&&X[2]?X[1]!==s[X[0]]:!(X[0]in s))return!1}for(;++P<q;){X=g[P];var re=X[0],pe=s[re],ge=X[1];if(U&&X[2]){if(pe===r&&!(re in s))return!1}else{var me=new Nr;if(O)var be=O(pe,ge,re,s,l,me);if(!(be===r?Vo(ge,pe,m|y,O,me):be))return!1}}return!0}function h_(s){if(!ft(s)||PF(s))return!1;var l=pn(s)?GL:Rl;return l.test(ii(s))}function KB(s){return dt(s)&&qt(s)==He}function YB(s){return dt(s)&&Mt(s)==qe}function XB(s){return dt(s)&&ou(s.length)&&!!st[qt(s)]}function p_(s){return typeof s=="function"?s:s==null?Vt:typeof s=="object"?Me(s)?m_(s[0],s[1]):g_(s):q1(s)}function cf(s){if(!Ko(s))return QL(s);var l=[];for(var g in rt(s))Ze.call(s,g)&&g!="constructor"&&l.push(g);return l}function ZB(s){if(!ft(s))return MF(s);var l=Ko(s),g=[];for(var O in s)O=="constructor"&&(l||!Ze.call(s,O))||g.push(O);return g}function lf(s,l){return s<l}function v_(s,l){var g=-1,O=Ht(s)?oe(s.length):[];return Tn(s,function(P,q,U){O[++g]=l(P,q,U)}),O}function g_(s){var l=Of(s);return l.length==1&&l[0][2]?X_(l[0][0],l[0][1]):function(g){return g===s||uf(g,s,l)}}function m_(s,l){return Rf(s)&&Y_(l)?X_(Gr(s),l):function(g){var O=kf(g,s);return O===r&&O===l?Lf(g,s):Vo(l,O,m|y)}}function Hs(s,l,g,O,P){s!==l&&nf(l,function(q,U){if(P||(P=new Nr),ft(q))JB(s,l,U,g,Hs,O,P);else{var X=O?O(Pf(s,U),q,U+"",s,l,P):r;X===r&&(X=q),tf(s,U,X)}},Ut)}function JB(s,l,g,O,P,q,U){var X=Pf(s,g),re=Pf(l,g),pe=U.get(re);if(pe){tf(s,g,pe);return}var ge=q?q(X,re,g+"",s,l,U):r,me=ge===r;if(me){var be=Me(re),Ce=!be&&jn(re),Ie=!be&&!Ce&&Vi(re);ge=re,be||Ce||Ie?Me(X)?ge=X:pt(X)?ge=zt(X):Ce?(me=!1,ge=P_(re,!0)):Ie?(me=!1,ge=N_(re,!0)):ge=[]:Xo(re)||oi(re)?(ge=X,oi(X)?ge=C1(X):(!ft(X)||pn(X))&&(ge=K_(re))):me=!1}me&&(U.set(re,ge),P(ge,re,O,q,U),U.delete(re)),tf(s,g,ge)}function y_(s,l){var g=s.length;if(g)return l+=l<0?g:0,hn(l,g)?s[l]:r}function b_(s,l,g){l.length?l=ct(l,function(q){return Me(q)?function(U){return ri(U,q.length===1?q[0]:q)}:q}):l=[Vt];var O=-1;l=ct(l,er(Re()));var P=v_(s,function(q,U,X){var re=ct(l,function(pe){return pe(q)});return{criteria:re,index:++O,value:q}});return OL(P,function(q,U){return fF(q,U,g)})}function QB(s,l){return x_(s,l,function(g,O){return Lf(s,O)})}function x_(s,l,g){for(var O=-1,P=l.length,q={};++O<P;){var U=l[O],X=ri(s,U);g(X,U)&&Wo(q,Mn(U,s),X)}return q}function eF(s){return function(l){return ri(l,s)}}function ff(s,l,g,O){var P=O?SL:Di,q=-1,U=l.length,X=s;for(s===l&&(l=zt(l)),g&&(X=ct(s,er(g)));++q<U;)for(var re=0,pe=l[q],ge=g?g(pe):pe;(re=P(X,ge,re,O))>-1;)X!==s&&Ms.call(X,re,1),Ms.call(s,re,1);return s}function w_(s,l){for(var g=s?l.length:0,O=g-1;g--;){var P=l[g];if(g==O||P!==q){var q=P;hn(P)?Ms.call(s,P,1):vf(s,P)}}return s}function df(s,l){return s+qs(t_()*(l-s+1))}function tF(s,l,g,O){for(var P=-1,q=_t(js((l-s)/(g||1)),0),U=oe(q);q--;)U[O?q:++P]=s,s+=g;return U}function hf(s,l){var g="";if(!s||l<1||l>Y)return g;do l%2&&(g+=s),l=qs(l/2),l&&(s+=s);while(l);return g}function ke(s,l){return Nf(Z_(s,l,Vt),s+"")}function rF(s){return i_(Wi(s))}function nF(s,l){var g=Wi(s);return Qs(g,ti(l,0,g.length))}function Wo(s,l,g,O){if(!ft(s))return s;l=Mn(l,s);for(var P=-1,q=l.length,U=q-1,X=s;X!=null&&++P<q;){var re=Gr(l[P]),pe=g;if(re==="__proto__"||re==="constructor"||re==="prototype")return s;if(P!=U){var ge=X[re];pe=O?O(ge,re,X):r,pe===r&&(pe=ft(ge)?ge:hn(l[P+1])?[]:{})}zo(X,re,pe),X=X[re]}return s}var __=ks?function(s,l){return ks.set(s,l),s}:Vt,iF=Ds?function(s,l){return Ds(s,"toString",{configurable:!0,enumerable:!1,value:Ff(l),writable:!0})}:Vt;function oF(s){return Qs(Wi(s))}function gr(s,l,g){var O=-1,P=s.length;l<0&&(l=-l>P?0:P+l),g=g>P?P:g,g<0&&(g+=P),P=l>g?0:g-l>>>0,l>>>=0;for(var q=oe(P);++O<P;)q[O]=s[O+l];return q}function aF(s,l){var g;return Tn(s,function(O,P,q){return g=l(O,P,q),!g}),!!g}function Us(s,l,g){var O=0,P=s==null?O:s.length;if(typeof l=="number"&&l===l&&P<=se){for(;O<P;){var q=O+P>>>1,U=s[q];U!==null&&!rr(U)&&(g?U<=l:U<l)?O=q+1:P=q}return P}return pf(s,l,Vt,g)}function pf(s,l,g,O){var P=0,q=s==null?0:s.length;if(q===0)return 0;l=g(l);for(var U=l!==l,X=l===null,re=rr(l),pe=l===r;P<q;){var ge=qs((P+q)/2),me=g(s[ge]),be=me!==r,Ce=me===null,Ie=me===me,je=rr(me);if(U)var Pe=O||Ie;else pe?Pe=Ie&&(O||be):X?Pe=Ie&&be&&(O||!Ce):re?Pe=Ie&&be&&!Ce&&(O||!je):Ce||je?Pe=!1:Pe=O?me<=l:me<l;Pe?P=ge+1:q=ge}return At(q,ce)}function E_(s,l){for(var g=-1,O=s.length,P=0,q=[];++g<O;){var U=s[g],X=l?l(U):U;if(!g||!Tr(X,re)){var re=X;q[P++]=U===0?0:U}}return q}function S_(s){return typeof s=="number"?s:rr(s)?H:+s}function tr(s){if(typeof s=="string")return s;if(Me(s))return ct(s,tr)+"";if(rr(s))return r_?r_.call(s):"";var l=s+"";return l=="0"&&1/s==-W?"-0":l}function An(s,l,g){var O=-1,P=Es,q=s.length,U=!0,X=[],re=X;if(g)U=!1,P=zl;else if(q>=i){var pe=l?null:mF(s);if(pe)return Os(pe);U=!1,P=qo,re=new ei}else re=l?[]:X;e:for(;++O<q;){var ge=s[O],me=l?l(ge):ge;if(ge=g||ge!==0?ge:0,U&&me===me){for(var be=re.length;be--;)if(re[be]===me)continue e;l&&re.push(me),X.push(ge)}else P(re,me,g)||(re!==X&&re.push(me),X.push(ge))}return X}function vf(s,l){return l=Mn(l,s),s=J_(s,l),s==null||delete s[Gr(mr(l))]}function O_(s,l,g,O){return Wo(s,l,g(ri(s,l)),O)}function Vs(s,l,g,O){for(var P=s.length,q=O?P:-1;(O?q--:++q<P)&&l(s[q],q,s););return g?gr(s,O?0:q,O?q+1:P):gr(s,O?q+1:0,O?P:q)}function C_(s,l){var g=s;return g instanceof Fe&&(g=g.value()),Hl(l,function(O,P){return P.func.apply(P.thisArg,In([O],P.args))},g)}function gf(s,l,g){var O=s.length;if(O<2)return O?An(s[0]):[];for(var P=-1,q=oe(O);++P<O;)for(var U=s[P],X=-1;++X<O;)X!=P&&(q[P]=Ho(q[P]||U,s[X],l,g));return An(It(q,1),l,g)}function R_(s,l,g){for(var O=-1,P=s.length,q=l.length,U={};++O<P;){var X=O<q?l[O]:r;g(U,s[O],X)}return U}function mf(s){return pt(s)?s:[]}function yf(s){return typeof s=="function"?s:Vt}function Mn(s,l){return Me(s)?s:Rf(s,l)?[s]:r1(Ge(s))}var sF=ke;function Dn(s,l,g){var O=s.length;return g=g===r?O:g,!l&&g>=O?s:gr(s,l,g)}var I_=KL||function(s){return Rt.clearTimeout(s)};function P_(s,l){if(l)return s.slice();var g=s.length,O=Xw?Xw(g):new s.constructor(g);return s.copy(O),O}function bf(s){var l=new s.constructor(s.byteLength);return new Ts(l).set(new Ts(s)),l}function uF(s,l){var g=l?bf(s.buffer):s.buffer;return new s.constructor(g,s.byteOffset,s.byteLength)}function cF(s){var l=new s.constructor(s.source,ls.exec(s));return l.lastIndex=s.lastIndex,l}function lF(s){return $o?rt($o.call(s)):{}}function N_(s,l){var g=l?bf(s.buffer):s.buffer;return new s.constructor(g,s.byteOffset,s.length)}function T_(s,l){if(s!==l){var g=s!==r,O=s===null,P=s===s,q=rr(s),U=l!==r,X=l===null,re=l===l,pe=rr(l);if(!X&&!pe&&!q&&s>l||q&&U&&re&&!X&&!pe||O&&U&&re||!g&&re||!P)return 1;if(!O&&!q&&!pe&&s<l||pe&&g&&P&&!O&&!q||X&&g&&P||!U&&P||!re)return-1}return 0}function fF(s,l,g){for(var O=-1,P=s.criteria,q=l.criteria,U=P.length,X=g.length;++O<U;){var re=T_(P[O],q[O]);if(re){if(O>=X)return re;var pe=g[O];return re*(pe=="desc"?-1:1)}}return s.index-l.index}function A_(s,l,g,O){for(var P=-1,q=s.length,U=g.length,X=-1,re=l.length,pe=_t(q-U,0),ge=oe(re+pe),me=!O;++X<re;)ge[X]=l[X];for(;++P<U;)(me||P<q)&&(ge[g[P]]=s[P]);for(;pe--;)ge[X++]=s[P++];return ge}function M_(s,l,g,O){for(var P=-1,q=s.length,U=-1,X=g.length,re=-1,pe=l.length,ge=_t(q-X,0),me=oe(ge+pe),be=!O;++P<ge;)me[P]=s[P];for(var Ce=P;++re<pe;)me[Ce+re]=l[re];for(;++U<X;)(be||P<q)&&(me[Ce+g[U]]=s[P++]);return me}function zt(s,l){var g=-1,O=s.length;for(l||(l=oe(O));++g<O;)l[g]=s[g];return l}function Wr(s,l,g,O){var P=!g;g||(g={});for(var q=-1,U=l.length;++q<U;){var X=l[q],re=O?O(g[X],s[X],X,g,s):r;re===r&&(re=s[X]),P?ln(g,X,re):zo(g,X,re)}return g}function dF(s,l){return Wr(s,Cf(s),l)}function hF(s,l){return Wr(s,W_(s),l)}function Ws(s,l){return function(g,O){var P=Me(g)?yL:jB,q=l?l():{};return P(g,s,Re(O,2),q)}}function zi(s){return ke(function(l,g){var O=-1,P=g.length,q=P>1?g[P-1]:r,U=P>2?g[2]:r;for(q=s.length>3&&typeof q=="function"?(P--,q):r,U&&kt(g[0],g[1],U)&&(q=P<3?r:q,P=1),l=rt(l);++O<P;){var X=g[O];X&&s(l,X,O,q)}return l})}function D_(s,l){return function(g,O){if(g==null)return g;if(!Ht(g))return s(g,O);for(var P=g.length,q=l?P:-1,U=rt(g);(l?q--:++q<P)&&O(U[q],q,U)!==!1;);return g}}function j_(s){return function(l,g,O){for(var P=-1,q=rt(l),U=O(l),X=U.length;X--;){var re=U[s?X:++P];if(g(q[re],re,q)===!1)break}return l}}function pF(s,l,g){var O=l&x,P=Go(s);function q(){var U=this&&this!==Rt&&this instanceof q?P:s;return U.apply(O?g:this,arguments)}return q}function q_(s){return function(l){l=Ge(l);var g=ji(l)?Pr(l):r,O=g?g[0]:l.charAt(0),P=g?Dn(g,1).join(""):l.slice(1);return O[s]()+P}}function Hi(s){return function(l){return Hl(D1(M1(l).replace(iL,"")),s,"")}}function Go(s){return function(){var l=arguments;switch(l.length){case 0:return new s;case 1:return new s(l[0]);case 2:return new s(l[0],l[1]);case 3:return new s(l[0],l[1],l[2]);case 4:return new s(l[0],l[1],l[2],l[3]);case 5:return new s(l[0],l[1],l[2],l[3],l[4]);case 6:return new s(l[0],l[1],l[2],l[3],l[4],l[5]);case 7:return new s(l[0],l[1],l[2],l[3],l[4],l[5],l[6])}var g=$i(s.prototype),O=s.apply(g,l);return ft(O)?O:g}}function vF(s,l,g){var O=Go(s);function P(){for(var q=arguments.length,U=oe(q),X=q,re=Ui(P);X--;)U[X]=arguments[X];var pe=q<3&&U[0]!==re&&U[q-1]!==re?[]:Pn(U,re);if(q-=pe.length,q<g)return $_(s,l,Gs,P.placeholder,r,U,pe,r,r,g-q);var ge=this&&this!==Rt&&this instanceof P?O:s;return Qt(ge,this,U)}return P}function k_(s){return function(l,g,O){var P=rt(l);if(!Ht(l)){var q=Re(g,3);l=St(l),g=function(X){return q(P[X],X,P)}}var U=s(l,g,O);return U>-1?P[q?l[U]:U]:r}}function L_(s){return dn(function(l){var g=l.length,O=g,P=pr.prototype.thru;for(s&&l.reverse();O--;){var q=l[O];if(typeof q!="function")throw new hr(a);if(P&&!U&&Zs(q)=="wrapper")var U=new pr([],!0)}for(O=U?O:g;++O<g;){q=l[O];var X=Zs(q),re=X=="wrapper"?Sf(q):r;re&&If(re[0])&&re[1]==(I|S|_|N)&&!re[4].length&&re[9]==1?U=U[Zs(re[0])].apply(U,re[3]):U=q.length==1&&If(q)?U[X]():U.thru(q)}return function(){var pe=arguments,ge=pe[0];if(U&&pe.length==1&&Me(ge))return U.plant(ge).value();for(var me=0,be=g?l[me].apply(this,pe):ge;++me<g;)be=l[me].call(this,be);return be}})}function Gs(s,l,g,O,P,q,U,X,re,pe){var ge=l&I,me=l&x,be=l&b,Ce=l&(S|E),Ie=l&D,je=be?r:Go(s);function Pe(){for(var Le=arguments.length,$e=oe(Le),nr=Le;nr--;)$e[nr]=arguments[nr];if(Ce)var Lt=Ui(Pe),ir=RL($e,Lt);if(O&&($e=A_($e,O,P,Ce)),q&&($e=M_($e,q,U,Ce)),Le-=ir,Ce&&Le<pe){var vt=Pn($e,Lt);return $_(s,l,Gs,Pe.placeholder,g,$e,vt,X,re,pe-Le)}var Ar=me?g:this,gn=be?Ar[s]:s;return Le=$e.length,X?$e=jF($e,X):Ie&&Le>1&&$e.reverse(),ge&&re<Le&&($e.length=re),this&&this!==Rt&&this instanceof Pe&&(gn=je||Go(gn)),gn.apply(Ar,$e)}return Pe}function B_(s,l){return function(g,O){return HB(g,s,l(O),{})}}function Ks(s,l){return function(g,O){var P;if(g===r&&O===r)return l;if(g!==r&&(P=g),O!==r){if(P===r)return O;typeof g=="string"||typeof O=="string"?(g=tr(g),O=tr(O)):(g=S_(g),O=S_(O)),P=s(g,O)}return P}}function xf(s){return dn(function(l){return l=ct(l,er(Re())),ke(function(g){var O=this;return s(l,function(P){return Qt(P,O,g)})})})}function Ys(s,l){l=l===r?" ":tr(l);var g=l.length;if(g<2)return g?hf(l,s):l;var O=hf(l,js(s/qi(l)));return ji(l)?Dn(Pr(O),0,s).join(""):O.slice(0,s)}function gF(s,l,g,O){var P=l&x,q=Go(s);function U(){for(var X=-1,re=arguments.length,pe=-1,ge=O.length,me=oe(ge+re),be=this&&this!==Rt&&this instanceof U?q:s;++pe<ge;)me[pe]=O[pe];for(;re--;)me[pe++]=arguments[++X];return Qt(be,P?g:this,me)}return U}function F_(s){return function(l,g,O){return O&&typeof O!="number"&&kt(l,g,O)&&(g=O=r),l=vn(l),g===r?(g=l,l=0):g=vn(g),O=O===r?l<g?1:-1:vn(O),tF(l,g,O,s)}}function Xs(s){return function(l,g){return typeof l=="string"&&typeof g=="string"||(l=yr(l),g=yr(g)),s(l,g)}}function $_(s,l,g,O,P,q,U,X,re,pe){var ge=l&S,me=ge?U:r,be=ge?r:U,Ce=ge?q:r,Ie=ge?r:q;l|=ge?_:R,l&=~(ge?R:_),l&w||(l&=-4);var je=[s,l,P,Ce,me,Ie,be,X,re,pe],Pe=g.apply(r,je);return If(s)&&Q_(Pe,je),Pe.placeholder=O,e1(Pe,s,l)}function wf(s){var l=wt[s];return function(g,O){if(g=yr(g),O=O==null?0:At(De(O),292),O&&e_(g)){var P=(Ge(g)+"e").split("e"),q=l(P[0]+"e"+(+P[1]+O));return P=(Ge(q)+"e").split("e"),+(P[0]+"e"+(+P[1]-O))}return l(g)}}var mF=Bi&&1/Os(new Bi([,-0]))[1]==W?function(s){return new Bi(s)}:Hf;function z_(s){return function(l){var g=Mt(l);return g==Se?Xl(l):g==qe?DL(l):CL(l,s(l))}}function fn(s,l,g,O,P,q,U,X){var re=l&b;if(!re&&typeof s!="function")throw new hr(a);var pe=O?O.length:0;if(pe||(l&=-97,O=P=r),U=U===r?U:_t(De(U),0),X=X===r?X:De(X),pe-=P?P.length:0,l&R){var ge=O,me=P;O=P=r}var be=re?r:Sf(s),Ce=[s,l,g,O,P,ge,me,q,U,X];if(be&&AF(Ce,be),s=Ce[0],l=Ce[1],g=Ce[2],O=Ce[3],P=Ce[4],X=Ce[9]=Ce[9]===r?re?0:s.length:_t(Ce[9]-pe,0),!X&&l&(S|E)&&(l&=-25),!l||l==x)var Ie=pF(s,l,g);else l==S||l==E?Ie=vF(s,l,X):(l==_||l==(x|_))&&!P.length?Ie=gF(s,l,g,O):Ie=Gs.apply(r,Ce);var je=be?__:Q_;return e1(je(Ie,Ce),s,l)}function H_(s,l,g,O){return s===r||Tr(s,Li[g])&&!Ze.call(O,g)?l:s}function U_(s,l,g,O,P,q){return ft(s)&&ft(l)&&(q.set(l,s),Hs(s,l,r,U_,q),q.delete(l)),s}function yF(s){return Xo(s)?r:s}function V_(s,l,g,O,P,q){var U=g&m,X=s.length,re=l.length;if(X!=re&&!(U&&re>X))return!1;var pe=q.get(s),ge=q.get(l);if(pe&&ge)return pe==l&&ge==s;var me=-1,be=!0,Ce=g&y?new ei:r;for(q.set(s,l),q.set(l,s);++me<X;){var Ie=s[me],je=l[me];if(O)var Pe=U?O(je,Ie,me,l,s,q):O(Ie,je,me,s,l,q);if(Pe!==r){if(Pe)continue;be=!1;break}if(Ce){if(!Ul(l,function(Le,$e){if(!qo(Ce,$e)&&(Ie===Le||P(Ie,Le,g,O,q)))return Ce.push($e)})){be=!1;break}}else if(!(Ie===je||P(Ie,je,g,O,q))){be=!1;break}}return q.delete(s),q.delete(l),be}function bF(s,l,g,O,P,q,U){switch(g){case tt:if(s.byteLength!=l.byteLength||s.byteOffset!=l.byteOffset)return!1;s=s.buffer,l=l.buffer;case ut:return!(s.byteLength!=l.byteLength||!q(new Ts(s),new Ts(l)));case K:case ie:case _e:return Tr(+s,+l);case ue:return s.name==l.name&&s.message==l.message;case He:case Xe:return s==l+"";case Se:var X=Xl;case qe:var re=O&m;if(X||(X=Os),s.size!=l.size&&!re)return!1;var pe=U.get(s);if(pe)return pe==l;O|=y,U.set(s,l);var ge=V_(X(s),X(l),O,P,q,U);return U.delete(s),ge;case We:if($o)return $o.call(s)==$o.call(l)}return!1}function xF(s,l,g,O,P,q){var U=g&m,X=_f(s),re=X.length,pe=_f(l),ge=pe.length;if(re!=ge&&!U)return!1;for(var me=re;me--;){var be=X[me];if(!(U?be in l:Ze.call(l,be)))return!1}var Ce=q.get(s),Ie=q.get(l);if(Ce&&Ie)return Ce==l&&Ie==s;var je=!0;q.set(s,l),q.set(l,s);for(var Pe=U;++me<re;){be=X[me];var Le=s[be],$e=l[be];if(O)var nr=U?O($e,Le,be,l,s,q):O(Le,$e,be,s,l,q);if(!(nr===r?Le===$e||P(Le,$e,g,O,q):nr)){je=!1;break}Pe||(Pe=be=="constructor")}if(je&&!Pe){var Lt=s.constructor,ir=l.constructor;Lt!=ir&&"constructor"in s&&"constructor"in l&&!(typeof Lt=="function"&&Lt instanceof Lt&&typeof ir=="function"&&ir instanceof ir)&&(je=!1)}return q.delete(s),q.delete(l),je}function dn(s){return Nf(Z_(s,r,a1),s+"")}function _f(s){return f_(s,St,Cf)}function Ef(s){return f_(s,Ut,W_)}var Sf=ks?function(s){return ks.get(s)}:Hf;function Zs(s){for(var l=s.name+"",g=Fi[l],O=Ze.call(Fi,l)?g.length:0;O--;){var P=g[O],q=P.func;if(q==null||q==s)return P.name}return l}function Ui(s){var l=Ze.call(M,"placeholder")?M:s;return l.placeholder}function Re(){var s=M.iteratee||$f;return s=s===$f?p_:s,arguments.length?s(arguments[0],arguments[1]):s}function Js(s,l){var g=s.__data__;return IF(l)?g[typeof l=="string"?"string":"hash"]:g.map}function Of(s){for(var l=St(s),g=l.length;g--;){var O=l[g],P=s[O];l[g]=[O,P,Y_(P)]}return l}function ni(s,l){var g=TL(s,l);return h_(g)?g:r}function wF(s){var l=Ze.call(s,Jn),g=s[Jn];try{s[Jn]=r;var O=!0}catch{}var P=Ps.call(s);return O&&(l?s[Jn]=g:delete s[Jn]),P}var Cf=Jl?function(s){return s==null?[]:(s=rt(s),Rn(Jl(s),function(l){return Jw.call(s,l)}))}:Uf,W_=Jl?function(s){for(var l=[];s;)In(l,Cf(s)),s=As(s);return l}:Uf,Mt=qt;(Ql&&Mt(new Ql(new ArrayBuffer(1)))!=tt||Lo&&Mt(new Lo)!=Se||ef&&Mt(ef.resolve())!=Oe||Bi&&Mt(new Bi)!=qe||Bo&&Mt(new Bo)!=et)&&(Mt=function(s){var l=qt(s),g=l==ae?s.constructor:r,O=g?ii(g):"";if(O)switch(O){case nB:return tt;case iB:return Se;case oB:return Oe;case aB:return qe;case sB:return et}return l});function _F(s,l,g){for(var O=-1,P=g.length;++O<P;){var q=g[O],U=q.size;switch(q.type){case"drop":s+=U;break;case"dropRight":l-=U;break;case"take":l=At(l,s+U);break;case"takeRight":s=_t(s,l-U);break}}return{start:s,end:l}}function EF(s){var l=s.match(cs);return l?l[1].split(xl):[]}function G_(s,l,g){l=Mn(l,s);for(var O=-1,P=l.length,q=!1;++O<P;){var U=Gr(l[O]);if(!(q=s!=null&&g(s,U)))break;s=s[U]}return q||++O!=P?q:(P=s==null?0:s.length,!!P&&ou(P)&&hn(U,P)&&(Me(s)||oi(s)))}function SF(s){var l=s.length,g=new s.constructor(l);return l&&typeof s[0]=="string"&&Ze.call(s,"index")&&(g.index=s.index,g.input=s.input),g}function K_(s){return typeof s.constructor=="function"&&!Ko(s)?$i(As(s)):{}}function OF(s,l,g){var O=s.constructor;switch(l){case ut:return bf(s);case K:case ie:return new O(+s);case tt:return uF(s,g);case Ct:case Jt:case lr:case Dt:case xt:case jt:case Hr:case Yn:case Cn:return N_(s,g);case Se:return new O;case _e:case Xe:return new O(s);case He:return cF(s);case qe:return new O;case We:return lF(s)}}function CF(s,l){var g=l.length;if(!g)return s;var O=g-1;return l[O]=(g>1?"& ":"")+l[O],l=l.join(g>2?", ":" "),s.replace(bl,`{
|
|
48
|
-
/* [wrapped with `+
|
|
49
|
-
`)}function RF(s){return Me(s)||oi(s)||!!(Qw&&s&&s[Qw])}function hn(s,l){var g=typeof s;return l=l??Y,!!l&&(g=="number"||g!="symbol"&&Pl.test(s))&&s>-1&&s%1==0&&s<l}function kt(s,l,g){if(!ft(g))return!1;var O=typeof l;return(O=="number"?Ht(g)&&hn(l,g.length):O=="string"&&l in g)?Tr(g[l],s):!1}function Rf(s,l){if(Me(s))return!1;var g=typeof s;return g=="number"||g=="symbol"||g=="boolean"||s==null||rr(s)?!0:yl.test(s)||!os.test(s)||l!=null&&s in rt(l)}function IF(s){var l=typeof s;return l=="string"||l=="number"||l=="symbol"||l=="boolean"?s!=="__proto__":s===null}function If(s){var l=Zs(s),g=M[l];if(typeof g!="function"||!(l in Fe.prototype))return!1;if(s===g)return!0;var O=Sf(g);return!!O&&s===O[0]}function PF(s){return!!Yw&&Yw in s}var NF=Rs?pn:Vf;function Ko(s){var l=s&&s.constructor,g=typeof l=="function"&&l.prototype||Li;return s===g}function Y_(s){return s===s&&!ft(s)}function X_(s,l){return function(g){return g==null?!1:g[s]===l&&(l!==r||s in rt(g))}}function TF(s){var l=nu(s,function(O){return g.size===d&&g.clear(),O}),g=l.cache;return l}function AF(s,l){var g=s[1],O=l[1],P=g|O,q=P<(x|b|I),U=O==I&&g==S||O==I&&g==N&&s[7].length<=l[8]||O==(I|N)&&l[7].length<=l[8]&&g==S;if(!(q||U))return s;O&x&&(s[2]=l[2],P|=g&x?0:w);var X=l[3];if(X){var re=s[3];s[3]=re?A_(re,X,l[4]):X,s[4]=re?Pn(s[3],f):l[4]}return X=l[5],X&&(re=s[5],s[5]=re?M_(re,X,l[6]):X,s[6]=re?Pn(s[5],f):l[6]),X=l[7],X&&(s[7]=X),O&I&&(s[8]=s[8]==null?l[8]:At(s[8],l[8])),s[9]==null&&(s[9]=l[9]),s[0]=l[0],s[1]=P,s}function MF(s){var l=[];if(s!=null)for(var g in rt(s))l.push(g);return l}function DF(s){return Ps.call(s)}function Z_(s,l,g){return l=_t(l===r?s.length-1:l,0),function(){for(var O=arguments,P=-1,q=_t(O.length-l,0),U=oe(q);++P<q;)U[P]=O[l+P];P=-1;for(var X=oe(l+1);++P<l;)X[P]=O[P];return X[l]=g(U),Qt(s,this,X)}}function J_(s,l){return l.length<2?s:ri(s,gr(l,0,-1))}function jF(s,l){for(var g=s.length,O=At(l.length,g),P=zt(s);O--;){var q=l[O];s[O]=hn(q,g)?P[q]:r}return s}function Pf(s,l){if(!(l==="constructor"&&typeof s[l]=="function")&&l!="__proto__")return s[l]}var Q_=t1(__),Yo=XL||function(s,l){return Rt.setTimeout(s,l)},Nf=t1(iF);function e1(s,l,g){var O=l+"";return Nf(s,CF(O,qF(EF(O),g)))}function t1(s){var l=0,g=0;return function(){var O=eB(),P=j-(O-g);if(g=O,P>0){if(++l>=L)return arguments[0]}else l=0;return s.apply(r,arguments)}}function Qs(s,l){var g=-1,O=s.length,P=O-1;for(l=l===r?O:l;++g<l;){var q=df(g,P),U=s[q];s[q]=s[g],s[g]=U}return s.length=l,s}var r1=TF(function(s){var l=[];return s.charCodeAt(0)===46&&l.push(""),s.replace(as,function(g,O,P,q){l.push(P?q.replace(El,"$1"):O||g)}),l});function Gr(s){if(typeof s=="string"||rr(s))return s;var l=s+"";return l=="0"&&1/s==-W?"-0":l}function ii(s){if(s!=null){try{return Is.call(s)}catch{}try{return s+""}catch{}}return""}function qF(s,l){return dr(z,function(g){var O="_."+g[0];l&g[1]&&!Es(s,O)&&s.push(O)}),s.sort()}function n1(s){if(s instanceof Fe)return s.clone();var l=new pr(s.__wrapped__,s.__chain__);return l.__actions__=zt(s.__actions__),l.__index__=s.__index__,l.__values__=s.__values__,l}function kF(s,l,g){(g?kt(s,l,g):l===r)?l=1:l=_t(De(l),0);var O=s==null?0:s.length;if(!O||l<1)return[];for(var P=0,q=0,U=oe(js(O/l));P<O;)U[q++]=gr(s,P,P+=l);return U}function LF(s){for(var l=-1,g=s==null?0:s.length,O=0,P=[];++l<g;){var q=s[l];q&&(P[O++]=q)}return P}function BF(){var s=arguments.length;if(!s)return[];for(var l=oe(s-1),g=arguments[0],O=s;O--;)l[O-1]=arguments[O];return In(Me(g)?zt(g):[g],It(l,1))}var FF=ke(function(s,l){return pt(s)?Ho(s,It(l,1,pt,!0)):[]}),$F=ke(function(s,l){var g=mr(l);return pt(g)&&(g=r),pt(s)?Ho(s,It(l,1,pt,!0),Re(g,2)):[]}),zF=ke(function(s,l){var g=mr(l);return pt(g)&&(g=r),pt(s)?Ho(s,It(l,1,pt,!0),r,g):[]});function HF(s,l,g){var O=s==null?0:s.length;return O?(l=g||l===r?1:De(l),gr(s,l<0?0:l,O)):[]}function UF(s,l,g){var O=s==null?0:s.length;return O?(l=g||l===r?1:De(l),l=O-l,gr(s,0,l<0?0:l)):[]}function VF(s,l){return s&&s.length?Vs(s,Re(l,3),!0,!0):[]}function WF(s,l){return s&&s.length?Vs(s,Re(l,3),!0):[]}function GF(s,l,g,O){var P=s==null?0:s.length;return P?(g&&typeof g!="number"&&kt(s,l,g)&&(g=0,O=P),BB(s,l,g,O)):[]}function i1(s,l,g){var O=s==null?0:s.length;if(!O)return-1;var P=g==null?0:De(g);return P<0&&(P=_t(O+P,0)),Ss(s,Re(l,3),P)}function o1(s,l,g){var O=s==null?0:s.length;if(!O)return-1;var P=O-1;return g!==r&&(P=De(g),P=g<0?_t(O+P,0):At(P,O-1)),Ss(s,Re(l,3),P,!0)}function a1(s){var l=s==null?0:s.length;return l?It(s,1):[]}function KF(s){var l=s==null?0:s.length;return l?It(s,W):[]}function YF(s,l){var g=s==null?0:s.length;return g?(l=l===r?1:De(l),It(s,l)):[]}function XF(s){for(var l=-1,g=s==null?0:s.length,O={};++l<g;){var P=s[l];O[P[0]]=P[1]}return O}function s1(s){return s&&s.length?s[0]:r}function ZF(s,l,g){var O=s==null?0:s.length;if(!O)return-1;var P=g==null?0:De(g);return P<0&&(P=_t(O+P,0)),Di(s,l,P)}function JF(s){var l=s==null?0:s.length;return l?gr(s,0,-1):[]}var QF=ke(function(s){var l=ct(s,mf);return l.length&&l[0]===s[0]?sf(l):[]}),e$=ke(function(s){var l=mr(s),g=ct(s,mf);return l===mr(g)?l=r:g.pop(),g.length&&g[0]===s[0]?sf(g,Re(l,2)):[]}),t$=ke(function(s){var l=mr(s),g=ct(s,mf);return l=typeof l=="function"?l:r,l&&g.pop(),g.length&&g[0]===s[0]?sf(g,r,l):[]});function r$(s,l){return s==null?"":JL.call(s,l)}function mr(s){var l=s==null?0:s.length;return l?s[l-1]:r}function n$(s,l,g){var O=s==null?0:s.length;if(!O)return-1;var P=O;return g!==r&&(P=De(g),P=P<0?_t(O+P,0):At(P,O-1)),l===l?qL(s,l,P):Ss(s,$w,P,!0)}function i$(s,l){return s&&s.length?y_(s,De(l)):r}var o$=ke(u1);function u1(s,l){return s&&s.length&&l&&l.length?ff(s,l):s}function a$(s,l,g){return s&&s.length&&l&&l.length?ff(s,l,Re(g,2)):s}function s$(s,l,g){return s&&s.length&&l&&l.length?ff(s,l,r,g):s}var u$=dn(function(s,l){var g=s==null?0:s.length,O=rf(s,l);return w_(s,ct(l,function(P){return hn(P,g)?+P:P}).sort(T_)),O});function c$(s,l){var g=[];if(!(s&&s.length))return g;var O=-1,P=[],q=s.length;for(l=Re(l,3);++O<q;){var U=s[O];l(U,O,s)&&(g.push(U),P.push(O))}return w_(s,P),g}function Tf(s){return s==null?s:rB.call(s)}function l$(s,l,g){var O=s==null?0:s.length;return O?(g&&typeof g!="number"&&kt(s,l,g)?(l=0,g=O):(l=l==null?0:De(l),g=g===r?O:De(g)),gr(s,l,g)):[]}function f$(s,l){return Us(s,l)}function d$(s,l,g){return pf(s,l,Re(g,2))}function h$(s,l){var g=s==null?0:s.length;if(g){var O=Us(s,l);if(O<g&&Tr(s[O],l))return O}return-1}function p$(s,l){return Us(s,l,!0)}function v$(s,l,g){return pf(s,l,Re(g,2),!0)}function g$(s,l){var g=s==null?0:s.length;if(g){var O=Us(s,l,!0)-1;if(Tr(s[O],l))return O}return-1}function m$(s){return s&&s.length?E_(s):[]}function y$(s,l){return s&&s.length?E_(s,Re(l,2)):[]}function b$(s){var l=s==null?0:s.length;return l?gr(s,1,l):[]}function x$(s,l,g){return s&&s.length?(l=g||l===r?1:De(l),gr(s,0,l<0?0:l)):[]}function w$(s,l,g){var O=s==null?0:s.length;return O?(l=g||l===r?1:De(l),l=O-l,gr(s,l<0?0:l,O)):[]}function _$(s,l){return s&&s.length?Vs(s,Re(l,3),!1,!0):[]}function E$(s,l){return s&&s.length?Vs(s,Re(l,3)):[]}var S$=ke(function(s){return An(It(s,1,pt,!0))}),O$=ke(function(s){var l=mr(s);return pt(l)&&(l=r),An(It(s,1,pt,!0),Re(l,2))}),C$=ke(function(s){var l=mr(s);return l=typeof l=="function"?l:r,An(It(s,1,pt,!0),r,l)});function R$(s){return s&&s.length?An(s):[]}function I$(s,l){return s&&s.length?An(s,Re(l,2)):[]}function P$(s,l){return l=typeof l=="function"?l:r,s&&s.length?An(s,r,l):[]}function Af(s){if(!(s&&s.length))return[];var l=0;return s=Rn(s,function(g){if(pt(g))return l=_t(g.length,l),!0}),Kl(l,function(g){return ct(s,Vl(g))})}function c1(s,l){if(!(s&&s.length))return[];var g=Af(s);return l==null?g:ct(g,function(O){return Qt(l,r,O)})}var N$=ke(function(s,l){return pt(s)?Ho(s,l):[]}),T$=ke(function(s){return gf(Rn(s,pt))}),A$=ke(function(s){var l=mr(s);return pt(l)&&(l=r),gf(Rn(s,pt),Re(l,2))}),M$=ke(function(s){var l=mr(s);return l=typeof l=="function"?l:r,gf(Rn(s,pt),r,l)}),D$=ke(Af);function j$(s,l){return R_(s||[],l||[],zo)}function q$(s,l){return R_(s||[],l||[],Wo)}var k$=ke(function(s){var l=s.length,g=l>1?s[l-1]:r;return g=typeof g=="function"?(s.pop(),g):r,c1(s,g)});function l1(s){var l=M(s);return l.__chain__=!0,l}function L$(s,l){return l(s),s}function eu(s,l){return l(s)}var B$=dn(function(s){var l=s.length,g=l?s[0]:0,O=this.__wrapped__,P=function(q){return rf(q,s)};return l>1||this.__actions__.length||!(O instanceof Fe)||!hn(g)?this.thru(P):(O=O.slice(g,+g+(l?1:0)),O.__actions__.push({func:eu,args:[P],thisArg:r}),new pr(O,this.__chain__).thru(function(q){return l&&!q.length&&q.push(r),q}))});function F$(){return l1(this)}function $$(){return new pr(this.value(),this.__chain__)}function z$(){this.__values__===r&&(this.__values__=S1(this.value()));var s=this.__index__>=this.__values__.length,l=s?r:this.__values__[this.__index__++];return{done:s,value:l}}function H$(){return this}function U$(s){for(var l,g=this;g instanceof Bs;){var O=n1(g);O.__index__=0,O.__values__=r,l?P.__wrapped__=O:l=O;var P=O;g=g.__wrapped__}return P.__wrapped__=s,l}function V$(){var s=this.__wrapped__;if(s instanceof Fe){var l=s;return this.__actions__.length&&(l=new Fe(this)),l=l.reverse(),l.__actions__.push({func:eu,args:[Tf],thisArg:r}),new pr(l,this.__chain__)}return this.thru(Tf)}function W$(){return C_(this.__wrapped__,this.__actions__)}var G$=Ws(function(s,l,g){Ze.call(s,g)?++s[g]:ln(s,g,1)});function K$(s,l,g){var O=Me(s)?Bw:LB;return g&&kt(s,l,g)&&(l=r),O(s,Re(l,3))}function Y$(s,l){var g=Me(s)?Rn:c_;return g(s,Re(l,3))}var X$=k_(i1),Z$=k_(o1);function J$(s,l){return It(tu(s,l),1)}function Q$(s,l){return It(tu(s,l),W)}function e3(s,l,g){return g=g===r?1:De(g),It(tu(s,l),g)}function f1(s,l){var g=Me(s)?dr:Tn;return g(s,Re(l,3))}function d1(s,l){var g=Me(s)?bL:u_;return g(s,Re(l,3))}var t3=Ws(function(s,l,g){Ze.call(s,g)?s[g].push(l):ln(s,g,[l])});function r3(s,l,g,O){s=Ht(s)?s:Wi(s),g=g&&!O?De(g):0;var P=s.length;return g<0&&(g=_t(P+g,0)),au(s)?g<=P&&s.indexOf(l,g)>-1:!!P&&Di(s,l,g)>-1}var n3=ke(function(s,l,g){var O=-1,P=typeof l=="function",q=Ht(s)?oe(s.length):[];return Tn(s,function(U){q[++O]=P?Qt(l,U,g):Uo(U,l,g)}),q}),i3=Ws(function(s,l,g){ln(s,g,l)});function tu(s,l){var g=Me(s)?ct:v_;return g(s,Re(l,3))}function o3(s,l,g,O){return s==null?[]:(Me(l)||(l=l==null?[]:[l]),g=O?r:g,Me(g)||(g=g==null?[]:[g]),b_(s,l,g))}var a3=Ws(function(s,l,g){s[g?0:1].push(l)},function(){return[[],[]]});function s3(s,l,g){var O=Me(s)?Hl:Hw,P=arguments.length<3;return O(s,Re(l,4),g,P,Tn)}function u3(s,l,g){var O=Me(s)?xL:Hw,P=arguments.length<3;return O(s,Re(l,4),g,P,u_)}function c3(s,l){var g=Me(s)?Rn:c_;return g(s,iu(Re(l,3)))}function l3(s){var l=Me(s)?i_:rF;return l(s)}function f3(s,l,g){(g?kt(s,l,g):l===r)?l=1:l=De(l);var O=Me(s)?MB:nF;return O(s,l)}function d3(s){var l=Me(s)?DB:oF;return l(s)}function h3(s){if(s==null)return 0;if(Ht(s))return au(s)?qi(s):s.length;var l=Mt(s);return l==Se||l==qe?s.size:cf(s).length}function p3(s,l,g){var O=Me(s)?Ul:aF;return g&&kt(s,l,g)&&(l=r),O(s,Re(l,3))}var v3=ke(function(s,l){if(s==null)return[];var g=l.length;return g>1&&kt(s,l[0],l[1])?l=[]:g>2&&kt(l[0],l[1],l[2])&&(l=[l[0]]),b_(s,It(l,1),[])}),ru=YL||function(){return Rt.Date.now()};function g3(s,l){if(typeof l!="function")throw new hr(a);return s=De(s),function(){if(--s<1)return l.apply(this,arguments)}}function h1(s,l,g){return l=g?r:l,l=s&&l==null?s.length:l,fn(s,I,r,r,r,r,l)}function p1(s,l){var g;if(typeof l!="function")throw new hr(a);return s=De(s),function(){return--s>0&&(g=l.apply(this,arguments)),s<=1&&(l=r),g}}var Mf=ke(function(s,l,g){var O=x;if(g.length){var P=Pn(g,Ui(Mf));O|=_}return fn(s,O,l,g,P)}),v1=ke(function(s,l,g){var O=x|b;if(g.length){var P=Pn(g,Ui(v1));O|=_}return fn(l,O,s,g,P)});function g1(s,l,g){l=g?r:l;var O=fn(s,S,r,r,r,r,r,l);return O.placeholder=g1.placeholder,O}function m1(s,l,g){l=g?r:l;var O=fn(s,E,r,r,r,r,r,l);return O.placeholder=m1.placeholder,O}function y1(s,l,g){var O,P,q,U,X,re,pe=0,ge=!1,me=!1,be=!0;if(typeof s!="function")throw new hr(a);l=yr(l)||0,ft(g)&&(ge=!!g.leading,me="maxWait"in g,q=me?_t(yr(g.maxWait)||0,l):q,be="trailing"in g?!!g.trailing:be);function Ce(vt){var Ar=O,gn=P;return O=P=r,pe=vt,U=s.apply(gn,Ar),U}function Ie(vt){return pe=vt,X=Yo(Le,l),ge?Ce(vt):U}function je(vt){var Ar=vt-re,gn=vt-pe,k1=l-Ar;return me?At(k1,q-gn):k1}function Pe(vt){var Ar=vt-re,gn=vt-pe;return re===r||Ar>=l||Ar<0||me&&gn>=q}function Le(){var vt=ru();if(Pe(vt))return $e(vt);X=Yo(Le,je(vt))}function $e(vt){return X=r,be&&O?Ce(vt):(O=P=r,U)}function nr(){X!==r&&I_(X),pe=0,O=re=P=X=r}function Lt(){return X===r?U:$e(ru())}function ir(){var vt=ru(),Ar=Pe(vt);if(O=arguments,P=this,re=vt,Ar){if(X===r)return Ie(re);if(me)return I_(X),X=Yo(Le,l),Ce(re)}return X===r&&(X=Yo(Le,l)),U}return ir.cancel=nr,ir.flush=Lt,ir}var m3=ke(function(s,l){return s_(s,1,l)}),y3=ke(function(s,l,g){return s_(s,yr(l)||0,g)});function b3(s){return fn(s,D)}function nu(s,l){if(typeof s!="function"||l!=null&&typeof l!="function")throw new hr(a);var g=function(){var O=arguments,P=l?l.apply(this,O):O[0],q=g.cache;if(q.has(P))return q.get(P);var U=s.apply(this,O);return g.cache=q.set(P,U)||q,U};return g.cache=new(nu.Cache||cn),g}nu.Cache=cn;function iu(s){if(typeof s!="function")throw new hr(a);return function(){var l=arguments;switch(l.length){case 0:return!s.call(this);case 1:return!s.call(this,l[0]);case 2:return!s.call(this,l[0],l[1]);case 3:return!s.call(this,l[0],l[1],l[2])}return!s.apply(this,l)}}function x3(s){return p1(2,s)}var w3=sF(function(s,l){l=l.length==1&&Me(l[0])?ct(l[0],er(Re())):ct(It(l,1),er(Re()));var g=l.length;return ke(function(O){for(var P=-1,q=At(O.length,g);++P<q;)O[P]=l[P].call(this,O[P]);return Qt(s,this,O)})}),Df=ke(function(s,l){var g=Pn(l,Ui(Df));return fn(s,_,r,l,g)}),b1=ke(function(s,l){var g=Pn(l,Ui(b1));return fn(s,R,r,l,g)}),_3=dn(function(s,l){return fn(s,N,r,r,r,l)});function E3(s,l){if(typeof s!="function")throw new hr(a);return l=l===r?l:De(l),ke(s,l)}function S3(s,l){if(typeof s!="function")throw new hr(a);return l=l==null?0:_t(De(l),0),ke(function(g){var O=g[l],P=Dn(g,0,l);return O&&In(P,O),Qt(s,this,P)})}function O3(s,l,g){var O=!0,P=!0;if(typeof s!="function")throw new hr(a);return ft(g)&&(O="leading"in g?!!g.leading:O,P="trailing"in g?!!g.trailing:P),y1(s,l,{leading:O,maxWait:l,trailing:P})}function C3(s){return h1(s,1)}function R3(s,l){return Df(yf(l),s)}function I3(){if(!arguments.length)return[];var s=arguments[0];return Me(s)?s:[s]}function P3(s){return vr(s,v)}function N3(s,l){return l=typeof l=="function"?l:r,vr(s,v,l)}function T3(s){return vr(s,h|v)}function A3(s,l){return l=typeof l=="function"?l:r,vr(s,h|v,l)}function M3(s,l){return l==null||a_(s,l,St(l))}function Tr(s,l){return s===l||s!==s&&l!==l}var D3=Xs(af),j3=Xs(function(s,l){return s>=l}),oi=d_((function(){return arguments})())?d_:function(s){return dt(s)&&Ze.call(s,"callee")&&!Jw.call(s,"callee")},Me=oe.isArray,q3=Mw?er(Mw):UB;function Ht(s){return s!=null&&ou(s.length)&&!pn(s)}function pt(s){return dt(s)&&Ht(s)}function k3(s){return s===!0||s===!1||dt(s)&&qt(s)==K}var jn=ZL||Vf,L3=Dw?er(Dw):VB;function B3(s){return dt(s)&&s.nodeType===1&&!Xo(s)}function F3(s){if(s==null)return!0;if(Ht(s)&&(Me(s)||typeof s=="string"||typeof s.splice=="function"||jn(s)||Vi(s)||oi(s)))return!s.length;var l=Mt(s);if(l==Se||l==qe)return!s.size;if(Ko(s))return!cf(s).length;for(var g in s)if(Ze.call(s,g))return!1;return!0}function $3(s,l){return Vo(s,l)}function z3(s,l,g){g=typeof g=="function"?g:r;var O=g?g(s,l):r;return O===r?Vo(s,l,r,g):!!O}function jf(s){if(!dt(s))return!1;var l=qt(s);return l==ue||l==ne||typeof s.message=="string"&&typeof s.name=="string"&&!Xo(s)}function H3(s){return typeof s=="number"&&e_(s)}function pn(s){if(!ft(s))return!1;var l=qt(s);return l==de||l==we||l==V||l==Ne}function x1(s){return typeof s=="number"&&s==De(s)}function ou(s){return typeof s=="number"&&s>-1&&s%1==0&&s<=Y}function ft(s){var l=typeof s;return s!=null&&(l=="object"||l=="function")}function dt(s){return s!=null&&typeof s=="object"}var w1=jw?er(jw):GB;function U3(s,l){return s===l||uf(s,l,Of(l))}function V3(s,l,g){return g=typeof g=="function"?g:r,uf(s,l,Of(l),g)}function W3(s){return _1(s)&&s!=+s}function G3(s){if(NF(s))throw new Ae(o);return h_(s)}function K3(s){return s===null}function Y3(s){return s==null}function _1(s){return typeof s=="number"||dt(s)&&qt(s)==_e}function Xo(s){if(!dt(s)||qt(s)!=ae)return!1;var l=As(s);if(l===null)return!0;var g=Ze.call(l,"constructor")&&l.constructor;return typeof g=="function"&&g instanceof g&&Is.call(g)==VL}var qf=qw?er(qw):KB;function X3(s){return x1(s)&&s>=-Y&&s<=Y}var E1=kw?er(kw):YB;function au(s){return typeof s=="string"||!Me(s)&&dt(s)&&qt(s)==Xe}function rr(s){return typeof s=="symbol"||dt(s)&&qt(s)==We}var Vi=Lw?er(Lw):XB;function Z3(s){return s===r}function J3(s){return dt(s)&&Mt(s)==et}function Q3(s){return dt(s)&&qt(s)==Tt}var e5=Xs(lf),t5=Xs(function(s,l){return s<=l});function S1(s){if(!s)return[];if(Ht(s))return au(s)?Pr(s):zt(s);if(ko&&s[ko])return ML(s[ko]());var l=Mt(s),g=l==Se?Xl:l==qe?Os:Wi;return g(s)}function vn(s){if(!s)return s===0?s:0;if(s=yr(s),s===W||s===-W){var l=s<0?-1:1;return l*ee}return s===s?s:0}function De(s){var l=vn(s),g=l%1;return l===l?g?l-g:l:0}function O1(s){return s?ti(De(s),0,Q):0}function yr(s){if(typeof s=="number")return s;if(rr(s))return H;if(ft(s)){var l=typeof s.valueOf=="function"?s.valueOf():s;s=ft(l)?l+"":l}if(typeof s!="string")return s===0?s:+s;s=Uw(s);var g=Cl.test(s);return g||Il.test(s)?gL(s.slice(2),g?2:8):Ol.test(s)?H:+s}function C1(s){return Wr(s,Ut(s))}function r5(s){return s?ti(De(s),-Y,Y):s===0?s:0}function Ge(s){return s==null?"":tr(s)}var n5=zi(function(s,l){if(Ko(l)||Ht(l)){Wr(l,St(l),s);return}for(var g in l)Ze.call(l,g)&&zo(s,g,l[g])}),R1=zi(function(s,l){Wr(l,Ut(l),s)}),su=zi(function(s,l,g,O){Wr(l,Ut(l),s,O)}),i5=zi(function(s,l,g,O){Wr(l,St(l),s,O)}),o5=dn(rf);function a5(s,l){var g=$i(s);return l==null?g:o_(g,l)}var s5=ke(function(s,l){s=rt(s);var g=-1,O=l.length,P=O>2?l[2]:r;for(P&&kt(l[0],l[1],P)&&(O=1);++g<O;)for(var q=l[g],U=Ut(q),X=-1,re=U.length;++X<re;){var pe=U[X],ge=s[pe];(ge===r||Tr(ge,Li[pe])&&!Ze.call(s,pe))&&(s[pe]=q[pe])}return s}),u5=ke(function(s){return s.push(r,U_),Qt(I1,r,s)});function c5(s,l){return Fw(s,Re(l,3),Vr)}function l5(s,l){return Fw(s,Re(l,3),of)}function f5(s,l){return s==null?s:nf(s,Re(l,3),Ut)}function d5(s,l){return s==null?s:l_(s,Re(l,3),Ut)}function h5(s,l){return s&&Vr(s,Re(l,3))}function p5(s,l){return s&&of(s,Re(l,3))}function v5(s){return s==null?[]:zs(s,St(s))}function g5(s){return s==null?[]:zs(s,Ut(s))}function kf(s,l,g){var O=s==null?r:ri(s,l);return O===r?g:O}function m5(s,l){return s!=null&&G_(s,l,FB)}function Lf(s,l){return s!=null&&G_(s,l,$B)}var y5=B_(function(s,l,g){l!=null&&typeof l.toString!="function"&&(l=Ps.call(l)),s[l]=g},Ff(Vt)),b5=B_(function(s,l,g){l!=null&&typeof l.toString!="function"&&(l=Ps.call(l)),Ze.call(s,l)?s[l].push(g):s[l]=[g]},Re),x5=ke(Uo);function St(s){return Ht(s)?n_(s):cf(s)}function Ut(s){return Ht(s)?n_(s,!0):ZB(s)}function w5(s,l){var g={};return l=Re(l,3),Vr(s,function(O,P,q){ln(g,l(O,P,q),O)}),g}function _5(s,l){var g={};return l=Re(l,3),Vr(s,function(O,P,q){ln(g,P,l(O,P,q))}),g}var E5=zi(function(s,l,g){Hs(s,l,g)}),I1=zi(function(s,l,g,O){Hs(s,l,g,O)}),S5=dn(function(s,l){var g={};if(s==null)return g;var O=!1;l=ct(l,function(q){return q=Mn(q,s),O||(O=q.length>1),q}),Wr(s,Ef(s),g),O&&(g=vr(g,h|p|v,yF));for(var P=l.length;P--;)vf(g,l[P]);return g});function O5(s,l){return P1(s,iu(Re(l)))}var C5=dn(function(s,l){return s==null?{}:QB(s,l)});function P1(s,l){if(s==null)return{};var g=ct(Ef(s),function(O){return[O]});return l=Re(l),x_(s,g,function(O,P){return l(O,P[0])})}function R5(s,l,g){l=Mn(l,s);var O=-1,P=l.length;for(P||(P=1,s=r);++O<P;){var q=s==null?r:s[Gr(l[O])];q===r&&(O=P,q=g),s=pn(q)?q.call(s):q}return s}function I5(s,l,g){return s==null?s:Wo(s,l,g)}function P5(s,l,g,O){return O=typeof O=="function"?O:r,s==null?s:Wo(s,l,g,O)}var N1=z_(St),T1=z_(Ut);function N5(s,l,g){var O=Me(s),P=O||jn(s)||Vi(s);if(l=Re(l,4),g==null){var q=s&&s.constructor;P?g=O?new q:[]:ft(s)?g=pn(q)?$i(As(s)):{}:g={}}return(P?dr:Vr)(s,function(U,X,re){return l(g,U,X,re)}),g}function T5(s,l){return s==null?!0:vf(s,l)}function A5(s,l,g){return s==null?s:O_(s,l,yf(g))}function M5(s,l,g,O){return O=typeof O=="function"?O:r,s==null?s:O_(s,l,yf(g),O)}function Wi(s){return s==null?[]:Yl(s,St(s))}function D5(s){return s==null?[]:Yl(s,Ut(s))}function j5(s,l,g){return g===r&&(g=l,l=r),g!==r&&(g=yr(g),g=g===g?g:0),l!==r&&(l=yr(l),l=l===l?l:0),ti(yr(s),l,g)}function q5(s,l,g){return l=vn(l),g===r?(g=l,l=0):g=vn(g),s=yr(s),zB(s,l,g)}function k5(s,l,g){if(g&&typeof g!="boolean"&&kt(s,l,g)&&(l=g=r),g===r&&(typeof l=="boolean"?(g=l,l=r):typeof s=="boolean"&&(g=s,s=r)),s===r&&l===r?(s=0,l=1):(s=vn(s),l===r?(l=s,s=0):l=vn(l)),s>l){var O=s;s=l,l=O}if(g||s%1||l%1){var P=t_();return At(s+P*(l-s+vL("1e-"+((P+"").length-1))),l)}return df(s,l)}var L5=Hi(function(s,l,g){return l=l.toLowerCase(),s+(g?A1(l):l)});function A1(s){return Bf(Ge(s).toLowerCase())}function M1(s){return s=Ge(s),s&&s.replace(Nl,IL).replace(oL,"")}function B5(s,l,g){s=Ge(s),l=tr(l);var O=s.length;g=g===r?O:ti(De(g),0,O);var P=g;return g-=l.length,g>=0&&s.slice(g,P)==l}function F5(s){return s=Ge(s),s&&rs.test(s)?s.replace(No,PL):s}function $5(s){return s=Ge(s),s&&ss.test(s)?s.replace(To,"\\$&"):s}var z5=Hi(function(s,l,g){return s+(g?"-":"")+l.toLowerCase()}),H5=Hi(function(s,l,g){return s+(g?" ":"")+l.toLowerCase()}),U5=q_("toLowerCase");function V5(s,l,g){s=Ge(s),l=De(l);var O=l?qi(s):0;if(!l||O>=l)return s;var P=(l-O)/2;return Ys(qs(P),g)+s+Ys(js(P),g)}function W5(s,l,g){s=Ge(s),l=De(l);var O=l?qi(s):0;return l&&O<l?s+Ys(l-O,g):s}function G5(s,l,g){s=Ge(s),l=De(l);var O=l?qi(s):0;return l&&O<l?Ys(l-O,g)+s:s}function K5(s,l,g){return g||l==null?l=0:l&&(l=+l),tB(Ge(s).replace(Ao,""),l||0)}function Y5(s,l,g){return(g?kt(s,l,g):l===r)?l=1:l=De(l),hf(Ge(s),l)}function X5(){var s=arguments,l=Ge(s[0]);return s.length<3?l:l.replace(s[1],s[2])}var Z5=Hi(function(s,l,g){return s+(g?"_":"")+l.toLowerCase()});function J5(s,l,g){return g&&typeof g!="number"&&kt(s,l,g)&&(l=g=r),g=g===r?Q:g>>>0,g?(s=Ge(s),s&&(typeof l=="string"||l!=null&&!qf(l))&&(l=tr(l),!l&&ji(s))?Dn(Pr(s),0,g):s.split(l,g)):[]}var Q5=Hi(function(s,l,g){return s+(g?" ":"")+Bf(l)});function ez(s,l,g){return s=Ge(s),g=g==null?0:ti(De(g),0,s.length),l=tr(l),s.slice(g,g+l.length)==l}function tz(s,l,g){var O=M.templateSettings;g&&kt(s,l,g)&&(l=r),s=Ge(s),l=su({},l,O,H_);var P=su({},l.imports,O.imports,H_),q=St(P),U=Yl(P,q),X,re,pe=0,ge=l.interpolate||Ni,me="__p += '",be=Zl((l.escape||Ni).source+"|"+ge.source+"|"+(ge===is?Sl:Ni).source+"|"+(l.evaluate||Ni).source+"|$","g"),Ce="//# sourceURL="+(Ze.call(l,"sourceURL")?(l.sourceURL+"").replace(/\s/g," "):"lodash.templateSources["+ ++lL+"]")+`
|
|
50
|
-
`;
|
|
51
|
-
__e(`+
|
|
52
|
-
'`),
|
|
53
|
-
`+
|
|
54
|
-
__p += '`)
|
|
55
|
-
((__t = (
|
|
56
|
-
'`),
|
|
57
|
-
`;var
|
|
58
|
-
`+
|
|
66
|
+
*/var pae=Us.exports,nD;function hae(){return nD||(nD=1,(function(e,t){(function(){var r,n="4.17.21",o=200,i="Unsupported core-js use. Try https://npms.io/search?q=ponyfill.",a="Expected a function",s="Invalid `variable` option passed into `_.template`",c="__lodash_hash_undefined__",u=500,d="__lodash_placeholder__",f=1,h=2,v=4,b=1,g=2,m=1,x=2,w=4,E=8,S=16,_=32,C=64,N=128,P=256,A=512,j=30,M="...",L=800,D=16,T=1,W=2,q=3,G=1/0,F=9007199254740991,J=17976931348623157e292,z=NaN,U=4294967295,oe=U-1,re=U>>>1,$=[["ary",N],["bind",m],["bindKey",x],["curry",E],["curryRight",S],["flip",A],["partial",_],["partialRight",C],["rearg",P]],Y="[object Arguments]",X="[object Array]",H="[object AsyncFunction]",K="[object Boolean]",Q="[object Date]",ne="[object DOMException]",se="[object Error]",te="[object Function]",be="[object GeneratorFunction]",de="[object Map]",Ee="[object Number]",fe="[object Null]",le="[object Object]",Ce="[object Promise]",Te="[object Proxy]",Fe="[object RegExp]",Le="[object Set]",Ze="[object String]",We="[object Symbol]",St="[object Undefined]",tt="[object WeakMap]",wt="[object WeakSet]",Je="[object ArrayBuffer]",Ne="[object DataView]",je="[object Float32Array]",Qe="[object Float64Array]",At="[object Int8Array]",It="[object Int16Array]",mt="[object Int32Array]",Rt="[object Uint8Array]",Qt="[object Uint8ClampedArray]",fr="[object Uint16Array]",pr="[object Uint32Array]",Xr=/\b__p \+= '';/g,Co=/\b(__p \+=) '' \+/g,Ka=/(__e\(.*?\)|\b__t\)) \+\n'';/g,$t=/&(?:amp|lt|gt|quot|#39);/g,Vt=/[&<>"']/g,er=RegExp($t.source),jr=RegExp(Vt.source),sr=/<%-([\s\S]+?)%>/g,Kt=/<%([\s\S]+?)%>/g,hr=/<%=([\s\S]+?)%>/g,Ln=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,kt=/^\w*$/,tr=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,vr=/[\\^$.*+?()[\]{}|]/g,yn=RegExp(vr.source),Sr=/^\s+/,Lr=/\s/,no=/\{(?:\n\/\* \[wrapped with .+\] \*\/)?\n?/,ti=/\{\n\/\* \[wrapped with (.+)\] \*/,jf=/,? & /,Lf=/[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g,qf=/[()=,{}\[\]\/\s]/,zf=/\\(\\)?/g,Bf=/\$\{([^\\}]*(?:\\.[^\\}]*)*)\}/g,Bl=/\w*$/,Ff=/^[-+]0x[0-9a-f]+$/i,$f=/^0b[01]+$/i,Vf=/^\[object .+?Constructor\]$/,Hf=/^0o[0-7]+$/i,Wf=/^(?:0|[1-9]\d*)$/,Uf=/[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g,ji=/($^)/,Fl=/['\n\r\u2028\u2029\\]/g,Li="\\ud800-\\udfff",Gf="\\u0300-\\u036f",Yf="\\ufe20-\\ufe2f",$l="\\u20d0-\\u20ff",Vl=Gf+Yf+$l,Xa="\\u2700-\\u27bf",Hl="a-z\\xdf-\\xf6\\xf8-\\xff",Wl="\\xac\\xb1\\xd7\\xf7",Kf="\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf",Ul="\\u2000-\\u206f",Xf=" \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000",Gl="A-Z\\xc0-\\xd6\\xd8-\\xde",Za="\\ufe0e\\ufe0f",Yl=Wl+Kf+Ul+Xf,Ja="['’]",Zf="["+Li+"]",Kl="["+Yl+"]",ri="["+Vl+"]",Xl="\\d+",qi="["+Xa+"]",Zl="["+Hl+"]",Jl="[^"+Li+Yl+Xl+Xa+Hl+Gl+"]",Jf="\\ud83c[\\udffb-\\udfff]",w$="(?:"+ri+"|"+Jf+")",BE="[^"+Li+"]",Qf="(?:\\ud83c[\\udde6-\\uddff]){2}",ep="[\\ud800-\\udbff][\\udc00-\\udfff]",zi="["+Gl+"]",FE="\\u200d",$E="(?:"+Zl+"|"+Jl+")",_$="(?:"+zi+"|"+Jl+")",VE="(?:"+Ja+"(?:d|ll|m|re|s|t|ve))?",HE="(?:"+Ja+"(?:D|LL|M|RE|S|T|VE))?",WE=w$+"?",UE="["+Za+"]?",E$="(?:"+FE+"(?:"+[BE,Qf,ep].join("|")+")"+UE+WE+")*",S$="\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])",O$="\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])",GE=UE+WE+E$,C$="(?:"+[qi,Qf,ep].join("|")+")"+GE,R$="(?:"+[BE+ri+"?",ri,Qf,ep,Zf].join("|")+")",N$=RegExp(Ja,"g"),I$=RegExp(ri,"g"),tp=RegExp(Jf+"(?="+Jf+")|"+R$+GE,"g"),P$=RegExp([zi+"?"+Zl+"+"+VE+"(?="+[Kl,zi,"$"].join("|")+")",_$+"+"+HE+"(?="+[Kl,zi+$E,"$"].join("|")+")",zi+"?"+$E+"+"+VE,zi+"+"+HE,O$,S$,Xl,C$].join("|"),"g"),T$=RegExp("["+FE+Li+Vl+Za+"]"),A$=/[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/,k$=["Array","Buffer","DataView","Date","Error","Float32Array","Float64Array","Function","Int8Array","Int16Array","Int32Array","Map","Math","Object","Promise","RegExp","Set","String","Symbol","TypeError","Uint8Array","Uint8ClampedArray","Uint16Array","Uint32Array","WeakMap","_","clearTimeout","isFinite","parseInt","setTimeout"],D$=-1,_t={};_t[je]=_t[Qe]=_t[At]=_t[It]=_t[mt]=_t[Rt]=_t[Qt]=_t[fr]=_t[pr]=!0,_t[Y]=_t[X]=_t[Je]=_t[K]=_t[Ne]=_t[Q]=_t[se]=_t[te]=_t[de]=_t[Ee]=_t[le]=_t[Fe]=_t[Le]=_t[Ze]=_t[tt]=!1;var bt={};bt[Y]=bt[X]=bt[Je]=bt[Ne]=bt[K]=bt[Q]=bt[je]=bt[Qe]=bt[At]=bt[It]=bt[mt]=bt[de]=bt[Ee]=bt[le]=bt[Fe]=bt[Le]=bt[Ze]=bt[We]=bt[Rt]=bt[Qt]=bt[fr]=bt[pr]=!0,bt[se]=bt[te]=bt[tt]=!1;var M$={À:"A",Á:"A",Â:"A",Ã:"A",Ä:"A",Å:"A",à:"a",á:"a",â:"a",ã:"a",ä:"a",å:"a",Ç:"C",ç:"c",Ð:"D",ð:"d",È:"E",É:"E",Ê:"E",Ë:"E",è:"e",é:"e",ê:"e",ë:"e",Ì:"I",Í:"I",Î:"I",Ï:"I",ì:"i",í:"i",î:"i",ï:"i",Ñ:"N",ñ:"n",Ò:"O",Ó:"O",Ô:"O",Õ:"O",Ö:"O",Ø:"O",ò:"o",ó:"o",ô:"o",õ:"o",ö:"o",ø:"o",Ù:"U",Ú:"U",Û:"U",Ü:"U",ù:"u",ú:"u",û:"u",ü:"u",Ý:"Y",ý:"y",ÿ:"y",Æ:"Ae",æ:"ae",Þ:"Th",þ:"th",ß:"ss",Ā:"A",Ă:"A",Ą:"A",ā:"a",ă:"a",ą:"a",Ć:"C",Ĉ:"C",Ċ:"C",Č:"C",ć:"c",ĉ:"c",ċ:"c",č:"c",Ď:"D",Đ:"D",ď:"d",đ:"d",Ē:"E",Ĕ:"E",Ė:"E",Ę:"E",Ě:"E",ē:"e",ĕ:"e",ė:"e",ę:"e",ě:"e",Ĝ:"G",Ğ:"G",Ġ:"G",Ģ:"G",ĝ:"g",ğ:"g",ġ:"g",ģ:"g",Ĥ:"H",Ħ:"H",ĥ:"h",ħ:"h",Ĩ:"I",Ī:"I",Ĭ:"I",Į:"I",İ:"I",ĩ:"i",ī:"i",ĭ:"i",į:"i",ı:"i",Ĵ:"J",ĵ:"j",Ķ:"K",ķ:"k",ĸ:"k",Ĺ:"L",Ļ:"L",Ľ:"L",Ŀ:"L",Ł:"L",ĺ:"l",ļ:"l",ľ:"l",ŀ:"l",ł:"l",Ń:"N",Ņ:"N",Ň:"N",Ŋ:"N",ń:"n",ņ:"n",ň:"n",ŋ:"n",Ō:"O",Ŏ:"O",Ő:"O",ō:"o",ŏ:"o",ő:"o",Ŕ:"R",Ŗ:"R",Ř:"R",ŕ:"r",ŗ:"r",ř:"r",Ś:"S",Ŝ:"S",Ş:"S",Š:"S",ś:"s",ŝ:"s",ş:"s",š:"s",Ţ:"T",Ť:"T",Ŧ:"T",ţ:"t",ť:"t",ŧ:"t",Ũ:"U",Ū:"U",Ŭ:"U",Ů:"U",Ű:"U",Ų:"U",ũ:"u",ū:"u",ŭ:"u",ů:"u",ű:"u",ų:"u",Ŵ:"W",ŵ:"w",Ŷ:"Y",ŷ:"y",Ÿ:"Y",Ź:"Z",Ż:"Z",Ž:"Z",ź:"z",ż:"z",ž:"z",IJ:"IJ",ij:"ij",Œ:"Oe",œ:"oe",ʼn:"'n",ſ:"s"},j$={"&":"&","<":"<",">":">",'"':""","'":"'"},L$={"&":"&","<":"<",">":">",""":'"',"'":"'"},q$={"\\":"\\","'":"'","\n":"n","\r":"r","\u2028":"u2028","\u2029":"u2029"},z$=parseFloat,B$=parseInt,YE=typeof Tt=="object"&&Tt&&Tt.Object===Object&&Tt,F$=typeof self=="object"&&self&&self.Object===Object&&self,rr=YE||F$||Function("return this")(),rp=t&&!t.nodeType&&t,ni=rp&&!0&&e&&!e.nodeType&&e,KE=ni&&ni.exports===rp,np=KE&&YE.process,Zr=(function(){try{var ie=ni&&ni.require&&ni.require("util").types;return ie||np&&np.binding&&np.binding("util")}catch{}})(),XE=Zr&&Zr.isArrayBuffer,ZE=Zr&&Zr.isDate,JE=Zr&&Zr.isMap,QE=Zr&&Zr.isRegExp,eS=Zr&&Zr.isSet,tS=Zr&&Zr.isTypedArray;function qr(ie,ve,ce){switch(ce.length){case 0:return ie.call(ve);case 1:return ie.call(ve,ce[0]);case 2:return ie.call(ve,ce[0],ce[1]);case 3:return ie.call(ve,ce[0],ce[1],ce[2])}return ie.apply(ve,ce)}function $$(ie,ve,ce,Re){for(var qe=-1,rt=ie==null?0:ie.length;++qe<rt;){var Ht=ie[qe];ve(Re,Ht,ce(Ht),ie)}return Re}function Jr(ie,ve){for(var ce=-1,Re=ie==null?0:ie.length;++ce<Re&&ve(ie[ce],ce,ie)!==!1;);return ie}function V$(ie,ve){for(var ce=ie==null?0:ie.length;ce--&&ve(ie[ce],ce,ie)!==!1;);return ie}function rS(ie,ve){for(var ce=-1,Re=ie==null?0:ie.length;++ce<Re;)if(!ve(ie[ce],ce,ie))return!1;return!0}function Ro(ie,ve){for(var ce=-1,Re=ie==null?0:ie.length,qe=0,rt=[];++ce<Re;){var Ht=ie[ce];ve(Ht,ce,ie)&&(rt[qe++]=Ht)}return rt}function Ql(ie,ve){var ce=ie==null?0:ie.length;return!!ce&&Bi(ie,ve,0)>-1}function op(ie,ve,ce){for(var Re=-1,qe=ie==null?0:ie.length;++Re<qe;)if(ce(ve,ie[Re]))return!0;return!1}function Ot(ie,ve){for(var ce=-1,Re=ie==null?0:ie.length,qe=Array(Re);++ce<Re;)qe[ce]=ve(ie[ce],ce,ie);return qe}function No(ie,ve){for(var ce=-1,Re=ve.length,qe=ie.length;++ce<Re;)ie[qe+ce]=ve[ce];return ie}function ip(ie,ve,ce,Re){var qe=-1,rt=ie==null?0:ie.length;for(Re&&rt&&(ce=ie[++qe]);++qe<rt;)ce=ve(ce,ie[qe],qe,ie);return ce}function H$(ie,ve,ce,Re){var qe=ie==null?0:ie.length;for(Re&&qe&&(ce=ie[--qe]);qe--;)ce=ve(ce,ie[qe],qe,ie);return ce}function ap(ie,ve){for(var ce=-1,Re=ie==null?0:ie.length;++ce<Re;)if(ve(ie[ce],ce,ie))return!0;return!1}var W$=sp("length");function U$(ie){return ie.split("")}function G$(ie){return ie.match(Lf)||[]}function nS(ie,ve,ce){var Re;return ce(ie,function(qe,rt,Ht){if(ve(qe,rt,Ht))return Re=rt,!1}),Re}function ec(ie,ve,ce,Re){for(var qe=ie.length,rt=ce+(Re?1:-1);Re?rt--:++rt<qe;)if(ve(ie[rt],rt,ie))return rt;return-1}function Bi(ie,ve,ce){return ve===ve?i4(ie,ve,ce):ec(ie,oS,ce)}function Y$(ie,ve,ce,Re){for(var qe=ce-1,rt=ie.length;++qe<rt;)if(Re(ie[qe],ve))return qe;return-1}function oS(ie){return ie!==ie}function iS(ie,ve){var ce=ie==null?0:ie.length;return ce?cp(ie,ve)/ce:z}function sp(ie){return function(ve){return ve==null?r:ve[ie]}}function lp(ie){return function(ve){return ie==null?r:ie[ve]}}function aS(ie,ve,ce,Re,qe){return qe(ie,function(rt,Ht,ht){ce=Re?(Re=!1,rt):ve(ce,rt,Ht,ht)}),ce}function K$(ie,ve){var ce=ie.length;for(ie.sort(ve);ce--;)ie[ce]=ie[ce].value;return ie}function cp(ie,ve){for(var ce,Re=-1,qe=ie.length;++Re<qe;){var rt=ve(ie[Re]);rt!==r&&(ce=ce===r?rt:ce+rt)}return ce}function up(ie,ve){for(var ce=-1,Re=Array(ie);++ce<ie;)Re[ce]=ve(ce);return Re}function X$(ie,ve){return Ot(ve,function(ce){return[ce,ie[ce]]})}function sS(ie){return ie&&ie.slice(0,dS(ie)+1).replace(Sr,"")}function zr(ie){return function(ve){return ie(ve)}}function dp(ie,ve){return Ot(ve,function(ce){return ie[ce]})}function Qa(ie,ve){return ie.has(ve)}function lS(ie,ve){for(var ce=-1,Re=ie.length;++ce<Re&&Bi(ve,ie[ce],0)>-1;);return ce}function cS(ie,ve){for(var ce=ie.length;ce--&&Bi(ve,ie[ce],0)>-1;);return ce}function Z$(ie,ve){for(var ce=ie.length,Re=0;ce--;)ie[ce]===ve&&++Re;return Re}var J$=lp(M$),Q$=lp(j$);function e4(ie){return"\\"+q$[ie]}function t4(ie,ve){return ie==null?r:ie[ve]}function Fi(ie){return T$.test(ie)}function r4(ie){return A$.test(ie)}function n4(ie){for(var ve,ce=[];!(ve=ie.next()).done;)ce.push(ve.value);return ce}function fp(ie){var ve=-1,ce=Array(ie.size);return ie.forEach(function(Re,qe){ce[++ve]=[qe,Re]}),ce}function uS(ie,ve){return function(ce){return ie(ve(ce))}}function Io(ie,ve){for(var ce=-1,Re=ie.length,qe=0,rt=[];++ce<Re;){var Ht=ie[ce];(Ht===ve||Ht===d)&&(ie[ce]=d,rt[qe++]=ce)}return rt}function tc(ie){var ve=-1,ce=Array(ie.size);return ie.forEach(function(Re){ce[++ve]=Re}),ce}function o4(ie){var ve=-1,ce=Array(ie.size);return ie.forEach(function(Re){ce[++ve]=[Re,Re]}),ce}function i4(ie,ve,ce){for(var Re=ce-1,qe=ie.length;++Re<qe;)if(ie[Re]===ve)return Re;return-1}function a4(ie,ve,ce){for(var Re=ce+1;Re--;)if(ie[Re]===ve)return Re;return Re}function $i(ie){return Fi(ie)?l4(ie):W$(ie)}function xn(ie){return Fi(ie)?c4(ie):U$(ie)}function dS(ie){for(var ve=ie.length;ve--&&Lr.test(ie.charAt(ve)););return ve}var s4=lp(L$);function l4(ie){for(var ve=tp.lastIndex=0;tp.test(ie);)++ve;return ve}function c4(ie){return ie.match(tp)||[]}function u4(ie){return ie.match(P$)||[]}var d4=(function ie(ve){ve=ve==null?rr:Vi.defaults(rr.Object(),ve,Vi.pick(rr,k$));var ce=ve.Array,Re=ve.Date,qe=ve.Error,rt=ve.Function,Ht=ve.Math,ht=ve.Object,pp=ve.RegExp,f4=ve.String,Qr=ve.TypeError,rc=ce.prototype,p4=rt.prototype,Hi=ht.prototype,nc=ve["__core-js_shared__"],oc=p4.toString,ct=Hi.hasOwnProperty,h4=0,fS=(function(){var l=/[^.]+$/.exec(nc&&nc.keys&&nc.keys.IE_PROTO||"");return l?"Symbol(src)_1."+l:""})(),ic=Hi.toString,v4=oc.call(ht),g4=rr._,m4=pp("^"+oc.call(ct).replace(vr,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),ac=KE?ve.Buffer:r,Po=ve.Symbol,sc=ve.Uint8Array,pS=ac?ac.allocUnsafe:r,lc=uS(ht.getPrototypeOf,ht),hS=ht.create,vS=Hi.propertyIsEnumerable,cc=rc.splice,gS=Po?Po.isConcatSpreadable:r,es=Po?Po.iterator:r,oi=Po?Po.toStringTag:r,uc=(function(){try{var l=ci(ht,"defineProperty");return l({},"",{}),l}catch{}})(),b4=ve.clearTimeout!==rr.clearTimeout&&ve.clearTimeout,y4=Re&&Re.now!==rr.Date.now&&Re.now,x4=ve.setTimeout!==rr.setTimeout&&ve.setTimeout,dc=Ht.ceil,fc=Ht.floor,hp=ht.getOwnPropertySymbols,w4=ac?ac.isBuffer:r,mS=ve.isFinite,_4=rc.join,E4=uS(ht.keys,ht),Wt=Ht.max,lr=Ht.min,S4=Re.now,O4=ve.parseInt,bS=Ht.random,C4=rc.reverse,vp=ci(ve,"DataView"),ts=ci(ve,"Map"),gp=ci(ve,"Promise"),Wi=ci(ve,"Set"),rs=ci(ve,"WeakMap"),ns=ci(ht,"create"),pc=rs&&new rs,Ui={},R4=ui(vp),N4=ui(ts),I4=ui(gp),P4=ui(Wi),T4=ui(rs),hc=Po?Po.prototype:r,os=hc?hc.valueOf:r,yS=hc?hc.toString:r;function B(l){if(Pt(l)&&!ze(l)&&!(l instanceof Ye)){if(l instanceof en)return l;if(ct.call(l,"__wrapped__"))return xO(l)}return new en(l)}var Gi=(function(){function l(){}return function(p){if(!Nt(p))return{};if(hS)return hS(p);l.prototype=p;var y=new l;return l.prototype=r,y}})();function vc(){}function en(l,p){this.__wrapped__=l,this.__actions__=[],this.__chain__=!!p,this.__index__=0,this.__values__=r}B.templateSettings={escape:sr,evaluate:Kt,interpolate:hr,variable:"",imports:{_:B}},B.prototype=vc.prototype,B.prototype.constructor=B,en.prototype=Gi(vc.prototype),en.prototype.constructor=en;function Ye(l){this.__wrapped__=l,this.__actions__=[],this.__dir__=1,this.__filtered__=!1,this.__iteratees__=[],this.__takeCount__=U,this.__views__=[]}function A4(){var l=new Ye(this.__wrapped__);return l.__actions__=Or(this.__actions__),l.__dir__=this.__dir__,l.__filtered__=this.__filtered__,l.__iteratees__=Or(this.__iteratees__),l.__takeCount__=this.__takeCount__,l.__views__=Or(this.__views__),l}function k4(){if(this.__filtered__){var l=new Ye(this);l.__dir__=-1,l.__filtered__=!0}else l=this.clone(),l.__dir__*=-1;return l}function D4(){var l=this.__wrapped__.value(),p=this.__dir__,y=ze(l),I=p<0,k=y?l.length:0,V=UV(0,k,this.__views__),Z=V.start,ee=V.end,ae=ee-Z,ge=I?ee:Z-1,me=this.__iteratees__,ye=me.length,Se=0,Ae=lr(ae,this.__takeCount__);if(!y||!I&&k==ae&&Ae==ae)return VS(l,this.__actions__);var De=[];e:for(;ae--&&Se<Ae;){ge+=p;for(var $e=-1,Me=l[ge];++$e<ye;){var Ue=me[$e],Ke=Ue.iteratee,$r=Ue.type,br=Ke(Me);if($r==W)Me=br;else if(!br){if($r==T)continue e;break e}}De[Se++]=Me}return De}Ye.prototype=Gi(vc.prototype),Ye.prototype.constructor=Ye;function ii(l){var p=-1,y=l==null?0:l.length;for(this.clear();++p<y;){var I=l[p];this.set(I[0],I[1])}}function M4(){this.__data__=ns?ns(null):{},this.size=0}function j4(l){var p=this.has(l)&&delete this.__data__[l];return this.size-=p?1:0,p}function L4(l){var p=this.__data__;if(ns){var y=p[l];return y===c?r:y}return ct.call(p,l)?p[l]:r}function q4(l){var p=this.__data__;return ns?p[l]!==r:ct.call(p,l)}function z4(l,p){var y=this.__data__;return this.size+=this.has(l)?0:1,y[l]=ns&&p===r?c:p,this}ii.prototype.clear=M4,ii.prototype.delete=j4,ii.prototype.get=L4,ii.prototype.has=q4,ii.prototype.set=z4;function oo(l){var p=-1,y=l==null?0:l.length;for(this.clear();++p<y;){var I=l[p];this.set(I[0],I[1])}}function B4(){this.__data__=[],this.size=0}function F4(l){var p=this.__data__,y=gc(p,l);if(y<0)return!1;var I=p.length-1;return y==I?p.pop():cc.call(p,y,1),--this.size,!0}function $4(l){var p=this.__data__,y=gc(p,l);return y<0?r:p[y][1]}function V4(l){return gc(this.__data__,l)>-1}function H4(l,p){var y=this.__data__,I=gc(y,l);return I<0?(++this.size,y.push([l,p])):y[I][1]=p,this}oo.prototype.clear=B4,oo.prototype.delete=F4,oo.prototype.get=$4,oo.prototype.has=V4,oo.prototype.set=H4;function io(l){var p=-1,y=l==null?0:l.length;for(this.clear();++p<y;){var I=l[p];this.set(I[0],I[1])}}function W4(){this.size=0,this.__data__={hash:new ii,map:new(ts||oo),string:new ii}}function U4(l){var p=Nc(this,l).delete(l);return this.size-=p?1:0,p}function G4(l){return Nc(this,l).get(l)}function Y4(l){return Nc(this,l).has(l)}function K4(l,p){var y=Nc(this,l),I=y.size;return y.set(l,p),this.size+=y.size==I?0:1,this}io.prototype.clear=W4,io.prototype.delete=U4,io.prototype.get=G4,io.prototype.has=Y4,io.prototype.set=K4;function ai(l){var p=-1,y=l==null?0:l.length;for(this.__data__=new io;++p<y;)this.add(l[p])}function X4(l){return this.__data__.set(l,c),this}function Z4(l){return this.__data__.has(l)}ai.prototype.add=ai.prototype.push=X4,ai.prototype.has=Z4;function wn(l){var p=this.__data__=new oo(l);this.size=p.size}function J4(){this.__data__=new oo,this.size=0}function Q4(l){var p=this.__data__,y=p.delete(l);return this.size=p.size,y}function eV(l){return this.__data__.get(l)}function tV(l){return this.__data__.has(l)}function rV(l,p){var y=this.__data__;if(y instanceof oo){var I=y.__data__;if(!ts||I.length<o-1)return I.push([l,p]),this.size=++y.size,this;y=this.__data__=new io(I)}return y.set(l,p),this.size=y.size,this}wn.prototype.clear=J4,wn.prototype.delete=Q4,wn.prototype.get=eV,wn.prototype.has=tV,wn.prototype.set=rV;function xS(l,p){var y=ze(l),I=!y&&di(l),k=!y&&!I&&Mo(l),V=!y&&!I&&!k&&Zi(l),Z=y||I||k||V,ee=Z?up(l.length,f4):[],ae=ee.length;for(var ge in l)(p||ct.call(l,ge))&&!(Z&&(ge=="length"||k&&(ge=="offset"||ge=="parent")||V&&(ge=="buffer"||ge=="byteLength"||ge=="byteOffset")||co(ge,ae)))&&ee.push(ge);return ee}function wS(l){var p=l.length;return p?l[Rp(0,p-1)]:r}function nV(l,p){return Ic(Or(l),si(p,0,l.length))}function oV(l){return Ic(Or(l))}function mp(l,p,y){(y!==r&&!_n(l[p],y)||y===r&&!(p in l))&&ao(l,p,y)}function is(l,p,y){var I=l[p];(!(ct.call(l,p)&&_n(I,y))||y===r&&!(p in l))&&ao(l,p,y)}function gc(l,p){for(var y=l.length;y--;)if(_n(l[y][0],p))return y;return-1}function iV(l,p,y,I){return To(l,function(k,V,Z){p(I,k,y(k),Z)}),I}function _S(l,p){return l&&zn(p,Xt(p),l)}function aV(l,p){return l&&zn(p,Rr(p),l)}function ao(l,p,y){p=="__proto__"&&uc?uc(l,p,{configurable:!0,enumerable:!0,value:y,writable:!0}):l[p]=y}function bp(l,p){for(var y=-1,I=p.length,k=ce(I),V=l==null;++y<I;)k[y]=V?r:Jp(l,p[y]);return k}function si(l,p,y){return l===l&&(y!==r&&(l=l<=y?l:y),p!==r&&(l=l>=p?l:p)),l}function tn(l,p,y,I,k,V){var Z,ee=p&f,ae=p&h,ge=p&v;if(y&&(Z=k?y(l,I,k,V):y(l)),Z!==r)return Z;if(!Nt(l))return l;var me=ze(l);if(me){if(Z=YV(l),!ee)return Or(l,Z)}else{var ye=cr(l),Se=ye==te||ye==be;if(Mo(l))return US(l,ee);if(ye==le||ye==Y||Se&&!k){if(Z=ae||Se?{}:dO(l),!ee)return ae?LV(l,aV(Z,l)):jV(l,_S(Z,l))}else{if(!bt[ye])return k?l:{};Z=KV(l,ye,ee)}}V||(V=new wn);var Ae=V.get(l);if(Ae)return Ae;V.set(l,Z),BO(l)?l.forEach(function(Me){Z.add(tn(Me,p,y,Me,l,V))}):qO(l)&&l.forEach(function(Me,Ue){Z.set(Ue,tn(Me,p,y,Ue,l,V))});var De=ge?ae?qp:Lp:ae?Rr:Xt,$e=me?r:De(l);return Jr($e||l,function(Me,Ue){$e&&(Ue=Me,Me=l[Ue]),is(Z,Ue,tn(Me,p,y,Ue,l,V))}),Z}function sV(l){var p=Xt(l);return function(y){return ES(y,l,p)}}function ES(l,p,y){var I=y.length;if(l==null)return!I;for(l=ht(l);I--;){var k=y[I],V=p[k],Z=l[k];if(Z===r&&!(k in l)||!V(Z))return!1}return!0}function SS(l,p,y){if(typeof l!="function")throw new Qr(a);return fs(function(){l.apply(r,y)},p)}function as(l,p,y,I){var k=-1,V=Ql,Z=!0,ee=l.length,ae=[],ge=p.length;if(!ee)return ae;y&&(p=Ot(p,zr(y))),I?(V=op,Z=!1):p.length>=o&&(V=Qa,Z=!1,p=new ai(p));e:for(;++k<ee;){var me=l[k],ye=y==null?me:y(me);if(me=I||me!==0?me:0,Z&&ye===ye){for(var Se=ge;Se--;)if(p[Se]===ye)continue e;ae.push(me)}else V(p,ye,I)||ae.push(me)}return ae}var To=ZS(qn),OS=ZS(xp,!0);function lV(l,p){var y=!0;return To(l,function(I,k,V){return y=!!p(I,k,V),y}),y}function mc(l,p,y){for(var I=-1,k=l.length;++I<k;){var V=l[I],Z=p(V);if(Z!=null&&(ee===r?Z===Z&&!Fr(Z):y(Z,ee)))var ee=Z,ae=V}return ae}function cV(l,p,y,I){var k=l.length;for(y=Be(y),y<0&&(y=-y>k?0:k+y),I=I===r||I>k?k:Be(I),I<0&&(I+=k),I=y>I?0:$O(I);y<I;)l[y++]=p;return l}function CS(l,p){var y=[];return To(l,function(I,k,V){p(I,k,V)&&y.push(I)}),y}function nr(l,p,y,I,k){var V=-1,Z=l.length;for(y||(y=ZV),k||(k=[]);++V<Z;){var ee=l[V];p>0&&y(ee)?p>1?nr(ee,p-1,y,I,k):No(k,ee):I||(k[k.length]=ee)}return k}var yp=JS(),RS=JS(!0);function qn(l,p){return l&&yp(l,p,Xt)}function xp(l,p){return l&&RS(l,p,Xt)}function bc(l,p){return Ro(p,function(y){return uo(l[y])})}function li(l,p){p=ko(p,l);for(var y=0,I=p.length;l!=null&&y<I;)l=l[Bn(p[y++])];return y&&y==I?l:r}function NS(l,p,y){var I=p(l);return ze(l)?I:No(I,y(l))}function gr(l){return l==null?l===r?St:fe:oi&&oi in ht(l)?WV(l):oH(l)}function wp(l,p){return l>p}function uV(l,p){return l!=null&&ct.call(l,p)}function dV(l,p){return l!=null&&p in ht(l)}function fV(l,p,y){return l>=lr(p,y)&&l<Wt(p,y)}function _p(l,p,y){for(var I=y?op:Ql,k=l[0].length,V=l.length,Z=V,ee=ce(V),ae=1/0,ge=[];Z--;){var me=l[Z];Z&&p&&(me=Ot(me,zr(p))),ae=lr(me.length,ae),ee[Z]=!y&&(p||k>=120&&me.length>=120)?new ai(Z&&me):r}me=l[0];var ye=-1,Se=ee[0];e:for(;++ye<k&&ge.length<ae;){var Ae=me[ye],De=p?p(Ae):Ae;if(Ae=y||Ae!==0?Ae:0,!(Se?Qa(Se,De):I(ge,De,y))){for(Z=V;--Z;){var $e=ee[Z];if(!($e?Qa($e,De):I(l[Z],De,y)))continue e}Se&&Se.push(De),ge.push(Ae)}}return ge}function pV(l,p,y,I){return qn(l,function(k,V,Z){p(I,y(k),V,Z)}),I}function ss(l,p,y){p=ko(p,l),l=vO(l,p);var I=l==null?l:l[Bn(nn(p))];return I==null?r:qr(I,l,y)}function IS(l){return Pt(l)&&gr(l)==Y}function hV(l){return Pt(l)&&gr(l)==Je}function vV(l){return Pt(l)&&gr(l)==Q}function ls(l,p,y,I,k){return l===p?!0:l==null||p==null||!Pt(l)&&!Pt(p)?l!==l&&p!==p:gV(l,p,y,I,ls,k)}function gV(l,p,y,I,k,V){var Z=ze(l),ee=ze(p),ae=Z?X:cr(l),ge=ee?X:cr(p);ae=ae==Y?le:ae,ge=ge==Y?le:ge;var me=ae==le,ye=ge==le,Se=ae==ge;if(Se&&Mo(l)){if(!Mo(p))return!1;Z=!0,me=!1}if(Se&&!me)return V||(V=new wn),Z||Zi(l)?lO(l,p,y,I,k,V):VV(l,p,ae,y,I,k,V);if(!(y&b)){var Ae=me&&ct.call(l,"__wrapped__"),De=ye&&ct.call(p,"__wrapped__");if(Ae||De){var $e=Ae?l.value():l,Me=De?p.value():p;return V||(V=new wn),k($e,Me,y,I,V)}}return Se?(V||(V=new wn),HV(l,p,y,I,k,V)):!1}function mV(l){return Pt(l)&&cr(l)==de}function Ep(l,p,y,I){var k=y.length,V=k,Z=!I;if(l==null)return!V;for(l=ht(l);k--;){var ee=y[k];if(Z&&ee[2]?ee[1]!==l[ee[0]]:!(ee[0]in l))return!1}for(;++k<V;){ee=y[k];var ae=ee[0],ge=l[ae],me=ee[1];if(Z&&ee[2]){if(ge===r&&!(ae in l))return!1}else{var ye=new wn;if(I)var Se=I(ge,me,ae,l,p,ye);if(!(Se===r?ls(me,ge,b|g,I,ye):Se))return!1}}return!0}function PS(l){if(!Nt(l)||QV(l))return!1;var p=uo(l)?m4:Vf;return p.test(ui(l))}function bV(l){return Pt(l)&&gr(l)==Fe}function yV(l){return Pt(l)&&cr(l)==Le}function xV(l){return Pt(l)&&Mc(l.length)&&!!_t[gr(l)]}function TS(l){return typeof l=="function"?l:l==null?Nr:typeof l=="object"?ze(l)?DS(l[0],l[1]):kS(l):QO(l)}function Sp(l){if(!ds(l))return E4(l);var p=[];for(var y in ht(l))ct.call(l,y)&&y!="constructor"&&p.push(y);return p}function wV(l){if(!Nt(l))return nH(l);var p=ds(l),y=[];for(var I in l)I=="constructor"&&(p||!ct.call(l,I))||y.push(I);return y}function Op(l,p){return l<p}function AS(l,p){var y=-1,I=Cr(l)?ce(l.length):[];return To(l,function(k,V,Z){I[++y]=p(k,V,Z)}),I}function kS(l){var p=Bp(l);return p.length==1&&p[0][2]?pO(p[0][0],p[0][1]):function(y){return y===l||Ep(y,l,p)}}function DS(l,p){return $p(l)&&fO(p)?pO(Bn(l),p):function(y){var I=Jp(y,l);return I===r&&I===p?Qp(y,l):ls(p,I,b|g)}}function yc(l,p,y,I,k){l!==p&&yp(p,function(V,Z){if(k||(k=new wn),Nt(V))_V(l,p,Z,y,yc,I,k);else{var ee=I?I(Hp(l,Z),V,Z+"",l,p,k):r;ee===r&&(ee=V),mp(l,Z,ee)}},Rr)}function _V(l,p,y,I,k,V,Z){var ee=Hp(l,y),ae=Hp(p,y),ge=Z.get(ae);if(ge){mp(l,y,ge);return}var me=V?V(ee,ae,y+"",l,p,Z):r,ye=me===r;if(ye){var Se=ze(ae),Ae=!Se&&Mo(ae),De=!Se&&!Ae&&Zi(ae);me=ae,Se||Ae||De?ze(ee)?me=ee:Dt(ee)?me=Or(ee):Ae?(ye=!1,me=US(ae,!0)):De?(ye=!1,me=GS(ae,!0)):me=[]:ps(ae)||di(ae)?(me=ee,di(ee)?me=VO(ee):(!Nt(ee)||uo(ee))&&(me=dO(ae))):ye=!1}ye&&(Z.set(ae,me),k(me,ae,I,V,Z),Z.delete(ae)),mp(l,y,me)}function MS(l,p){var y=l.length;if(y)return p+=p<0?y:0,co(p,y)?l[p]:r}function jS(l,p,y){p.length?p=Ot(p,function(V){return ze(V)?function(Z){return li(Z,V.length===1?V[0]:V)}:V}):p=[Nr];var I=-1;p=Ot(p,zr(ke()));var k=AS(l,function(V,Z,ee){var ae=Ot(p,function(ge){return ge(V)});return{criteria:ae,index:++I,value:V}});return K$(k,function(V,Z){return MV(V,Z,y)})}function EV(l,p){return LS(l,p,function(y,I){return Qp(l,I)})}function LS(l,p,y){for(var I=-1,k=p.length,V={};++I<k;){var Z=p[I],ee=li(l,Z);y(ee,Z)&&cs(V,ko(Z,l),ee)}return V}function SV(l){return function(p){return li(p,l)}}function Cp(l,p,y,I){var k=I?Y$:Bi,V=-1,Z=p.length,ee=l;for(l===p&&(p=Or(p)),y&&(ee=Ot(l,zr(y)));++V<Z;)for(var ae=0,ge=p[V],me=y?y(ge):ge;(ae=k(ee,me,ae,I))>-1;)ee!==l&&cc.call(ee,ae,1),cc.call(l,ae,1);return l}function qS(l,p){for(var y=l?p.length:0,I=y-1;y--;){var k=p[y];if(y==I||k!==V){var V=k;co(k)?cc.call(l,k,1):Pp(l,k)}}return l}function Rp(l,p){return l+fc(bS()*(p-l+1))}function OV(l,p,y,I){for(var k=-1,V=Wt(dc((p-l)/(y||1)),0),Z=ce(V);V--;)Z[I?V:++k]=l,l+=y;return Z}function Np(l,p){var y="";if(!l||p<1||p>F)return y;do p%2&&(y+=l),p=fc(p/2),p&&(l+=l);while(p);return y}function Ve(l,p){return Wp(hO(l,p,Nr),l+"")}function CV(l){return wS(Ji(l))}function RV(l,p){var y=Ji(l);return Ic(y,si(p,0,y.length))}function cs(l,p,y,I){if(!Nt(l))return l;p=ko(p,l);for(var k=-1,V=p.length,Z=V-1,ee=l;ee!=null&&++k<V;){var ae=Bn(p[k]),ge=y;if(ae==="__proto__"||ae==="constructor"||ae==="prototype")return l;if(k!=Z){var me=ee[ae];ge=I?I(me,ae,ee):r,ge===r&&(ge=Nt(me)?me:co(p[k+1])?[]:{})}is(ee,ae,ge),ee=ee[ae]}return l}var zS=pc?function(l,p){return pc.set(l,p),l}:Nr,NV=uc?function(l,p){return uc(l,"toString",{configurable:!0,enumerable:!1,value:th(p),writable:!0})}:Nr;function IV(l){return Ic(Ji(l))}function rn(l,p,y){var I=-1,k=l.length;p<0&&(p=-p>k?0:k+p),y=y>k?k:y,y<0&&(y+=k),k=p>y?0:y-p>>>0,p>>>=0;for(var V=ce(k);++I<k;)V[I]=l[I+p];return V}function PV(l,p){var y;return To(l,function(I,k,V){return y=p(I,k,V),!y}),!!y}function xc(l,p,y){var I=0,k=l==null?I:l.length;if(typeof p=="number"&&p===p&&k<=re){for(;I<k;){var V=I+k>>>1,Z=l[V];Z!==null&&!Fr(Z)&&(y?Z<=p:Z<p)?I=V+1:k=V}return k}return Ip(l,p,Nr,y)}function Ip(l,p,y,I){var k=0,V=l==null?0:l.length;if(V===0)return 0;p=y(p);for(var Z=p!==p,ee=p===null,ae=Fr(p),ge=p===r;k<V;){var me=fc((k+V)/2),ye=y(l[me]),Se=ye!==r,Ae=ye===null,De=ye===ye,$e=Fr(ye);if(Z)var Me=I||De;else ge?Me=De&&(I||Se):ee?Me=De&&Se&&(I||!Ae):ae?Me=De&&Se&&!Ae&&(I||!$e):Ae||$e?Me=!1:Me=I?ye<=p:ye<p;Me?k=me+1:V=me}return lr(V,oe)}function BS(l,p){for(var y=-1,I=l.length,k=0,V=[];++y<I;){var Z=l[y],ee=p?p(Z):Z;if(!y||!_n(ee,ae)){var ae=ee;V[k++]=Z===0?0:Z}}return V}function FS(l){return typeof l=="number"?l:Fr(l)?z:+l}function Br(l){if(typeof l=="string")return l;if(ze(l))return Ot(l,Br)+"";if(Fr(l))return yS?yS.call(l):"";var p=l+"";return p=="0"&&1/l==-G?"-0":p}function Ao(l,p,y){var I=-1,k=Ql,V=l.length,Z=!0,ee=[],ae=ee;if(y)Z=!1,k=op;else if(V>=o){var ge=p?null:FV(l);if(ge)return tc(ge);Z=!1,k=Qa,ae=new ai}else ae=p?[]:ee;e:for(;++I<V;){var me=l[I],ye=p?p(me):me;if(me=y||me!==0?me:0,Z&&ye===ye){for(var Se=ae.length;Se--;)if(ae[Se]===ye)continue e;p&&ae.push(ye),ee.push(me)}else k(ae,ye,y)||(ae!==ee&&ae.push(ye),ee.push(me))}return ee}function Pp(l,p){return p=ko(p,l),l=vO(l,p),l==null||delete l[Bn(nn(p))]}function $S(l,p,y,I){return cs(l,p,y(li(l,p)),I)}function wc(l,p,y,I){for(var k=l.length,V=I?k:-1;(I?V--:++V<k)&&p(l[V],V,l););return y?rn(l,I?0:V,I?V+1:k):rn(l,I?V+1:0,I?k:V)}function VS(l,p){var y=l;return y instanceof Ye&&(y=y.value()),ip(p,function(I,k){return k.func.apply(k.thisArg,No([I],k.args))},y)}function Tp(l,p,y){var I=l.length;if(I<2)return I?Ao(l[0]):[];for(var k=-1,V=ce(I);++k<I;)for(var Z=l[k],ee=-1;++ee<I;)ee!=k&&(V[k]=as(V[k]||Z,l[ee],p,y));return Ao(nr(V,1),p,y)}function HS(l,p,y){for(var I=-1,k=l.length,V=p.length,Z={};++I<k;){var ee=I<V?p[I]:r;y(Z,l[I],ee)}return Z}function Ap(l){return Dt(l)?l:[]}function kp(l){return typeof l=="function"?l:Nr}function ko(l,p){return ze(l)?l:$p(l,p)?[l]:yO(ot(l))}var TV=Ve;function Do(l,p,y){var I=l.length;return y=y===r?I:y,!p&&y>=I?l:rn(l,p,y)}var WS=b4||function(l){return rr.clearTimeout(l)};function US(l,p){if(p)return l.slice();var y=l.length,I=pS?pS(y):new l.constructor(y);return l.copy(I),I}function Dp(l){var p=new l.constructor(l.byteLength);return new sc(p).set(new sc(l)),p}function AV(l,p){var y=p?Dp(l.buffer):l.buffer;return new l.constructor(y,l.byteOffset,l.byteLength)}function kV(l){var p=new l.constructor(l.source,Bl.exec(l));return p.lastIndex=l.lastIndex,p}function DV(l){return os?ht(os.call(l)):{}}function GS(l,p){var y=p?Dp(l.buffer):l.buffer;return new l.constructor(y,l.byteOffset,l.length)}function YS(l,p){if(l!==p){var y=l!==r,I=l===null,k=l===l,V=Fr(l),Z=p!==r,ee=p===null,ae=p===p,ge=Fr(p);if(!ee&&!ge&&!V&&l>p||V&&Z&&ae&&!ee&&!ge||I&&Z&&ae||!y&&ae||!k)return 1;if(!I&&!V&&!ge&&l<p||ge&&y&&k&&!I&&!V||ee&&y&&k||!Z&&k||!ae)return-1}return 0}function MV(l,p,y){for(var I=-1,k=l.criteria,V=p.criteria,Z=k.length,ee=y.length;++I<Z;){var ae=YS(k[I],V[I]);if(ae){if(I>=ee)return ae;var ge=y[I];return ae*(ge=="desc"?-1:1)}}return l.index-p.index}function KS(l,p,y,I){for(var k=-1,V=l.length,Z=y.length,ee=-1,ae=p.length,ge=Wt(V-Z,0),me=ce(ae+ge),ye=!I;++ee<ae;)me[ee]=p[ee];for(;++k<Z;)(ye||k<V)&&(me[y[k]]=l[k]);for(;ge--;)me[ee++]=l[k++];return me}function XS(l,p,y,I){for(var k=-1,V=l.length,Z=-1,ee=y.length,ae=-1,ge=p.length,me=Wt(V-ee,0),ye=ce(me+ge),Se=!I;++k<me;)ye[k]=l[k];for(var Ae=k;++ae<ge;)ye[Ae+ae]=p[ae];for(;++Z<ee;)(Se||k<V)&&(ye[Ae+y[Z]]=l[k++]);return ye}function Or(l,p){var y=-1,I=l.length;for(p||(p=ce(I));++y<I;)p[y]=l[y];return p}function zn(l,p,y,I){var k=!y;y||(y={});for(var V=-1,Z=p.length;++V<Z;){var ee=p[V],ae=I?I(y[ee],l[ee],ee,y,l):r;ae===r&&(ae=l[ee]),k?ao(y,ee,ae):is(y,ee,ae)}return y}function jV(l,p){return zn(l,Fp(l),p)}function LV(l,p){return zn(l,cO(l),p)}function _c(l,p){return function(y,I){var k=ze(y)?$$:iV,V=p?p():{};return k(y,l,ke(I,2),V)}}function Yi(l){return Ve(function(p,y){var I=-1,k=y.length,V=k>1?y[k-1]:r,Z=k>2?y[2]:r;for(V=l.length>3&&typeof V=="function"?(k--,V):r,Z&&mr(y[0],y[1],Z)&&(V=k<3?r:V,k=1),p=ht(p);++I<k;){var ee=y[I];ee&&l(p,ee,I,V)}return p})}function ZS(l,p){return function(y,I){if(y==null)return y;if(!Cr(y))return l(y,I);for(var k=y.length,V=p?k:-1,Z=ht(y);(p?V--:++V<k)&&I(Z[V],V,Z)!==!1;);return y}}function JS(l){return function(p,y,I){for(var k=-1,V=ht(p),Z=I(p),ee=Z.length;ee--;){var ae=Z[l?ee:++k];if(y(V[ae],ae,V)===!1)break}return p}}function qV(l,p,y){var I=p&m,k=us(l);function V(){var Z=this&&this!==rr&&this instanceof V?k:l;return Z.apply(I?y:this,arguments)}return V}function QS(l){return function(p){p=ot(p);var y=Fi(p)?xn(p):r,I=y?y[0]:p.charAt(0),k=y?Do(y,1).join(""):p.slice(1);return I[l]()+k}}function Ki(l){return function(p){return ip(ZO(XO(p).replace(N$,"")),l,"")}}function us(l){return function(){var p=arguments;switch(p.length){case 0:return new l;case 1:return new l(p[0]);case 2:return new l(p[0],p[1]);case 3:return new l(p[0],p[1],p[2]);case 4:return new l(p[0],p[1],p[2],p[3]);case 5:return new l(p[0],p[1],p[2],p[3],p[4]);case 6:return new l(p[0],p[1],p[2],p[3],p[4],p[5]);case 7:return new l(p[0],p[1],p[2],p[3],p[4],p[5],p[6])}var y=Gi(l.prototype),I=l.apply(y,p);return Nt(I)?I:y}}function zV(l,p,y){var I=us(l);function k(){for(var V=arguments.length,Z=ce(V),ee=V,ae=Xi(k);ee--;)Z[ee]=arguments[ee];var ge=V<3&&Z[0]!==ae&&Z[V-1]!==ae?[]:Io(Z,ae);if(V-=ge.length,V<y)return oO(l,p,Ec,k.placeholder,r,Z,ge,r,r,y-V);var me=this&&this!==rr&&this instanceof k?I:l;return qr(me,this,Z)}return k}function eO(l){return function(p,y,I){var k=ht(p);if(!Cr(p)){var V=ke(y,3);p=Xt(p),y=function(ee){return V(k[ee],ee,k)}}var Z=l(p,y,I);return Z>-1?k[V?p[Z]:Z]:r}}function tO(l){return lo(function(p){var y=p.length,I=y,k=en.prototype.thru;for(l&&p.reverse();I--;){var V=p[I];if(typeof V!="function")throw new Qr(a);if(k&&!Z&&Rc(V)=="wrapper")var Z=new en([],!0)}for(I=Z?I:y;++I<y;){V=p[I];var ee=Rc(V),ae=ee=="wrapper"?zp(V):r;ae&&Vp(ae[0])&&ae[1]==(N|E|_|P)&&!ae[4].length&&ae[9]==1?Z=Z[Rc(ae[0])].apply(Z,ae[3]):Z=V.length==1&&Vp(V)?Z[ee]():Z.thru(V)}return function(){var ge=arguments,me=ge[0];if(Z&&ge.length==1&&ze(me))return Z.plant(me).value();for(var ye=0,Se=y?p[ye].apply(this,ge):me;++ye<y;)Se=p[ye].call(this,Se);return Se}})}function Ec(l,p,y,I,k,V,Z,ee,ae,ge){var me=p&N,ye=p&m,Se=p&x,Ae=p&(E|S),De=p&A,$e=Se?r:us(l);function Me(){for(var Ue=arguments.length,Ke=ce(Ue),$r=Ue;$r--;)Ke[$r]=arguments[$r];if(Ae)var br=Xi(Me),Vr=Z$(Ke,br);if(I&&(Ke=KS(Ke,I,k,Ae)),V&&(Ke=XS(Ke,V,Z,Ae)),Ue-=Vr,Ae&&Ue<ge){var Mt=Io(Ke,br);return oO(l,p,Ec,Me.placeholder,y,Ke,Mt,ee,ae,ge-Ue)}var En=ye?y:this,po=Se?En[l]:l;return Ue=Ke.length,ee?Ke=iH(Ke,ee):De&&Ue>1&&Ke.reverse(),me&&ae<Ue&&(Ke.length=ae),this&&this!==rr&&this instanceof Me&&(po=$e||us(po)),po.apply(En,Ke)}return Me}function rO(l,p){return function(y,I){return pV(y,l,p(I),{})}}function Sc(l,p){return function(y,I){var k;if(y===r&&I===r)return p;if(y!==r&&(k=y),I!==r){if(k===r)return I;typeof y=="string"||typeof I=="string"?(y=Br(y),I=Br(I)):(y=FS(y),I=FS(I)),k=l(y,I)}return k}}function Mp(l){return lo(function(p){return p=Ot(p,zr(ke())),Ve(function(y){var I=this;return l(p,function(k){return qr(k,I,y)})})})}function Oc(l,p){p=p===r?" ":Br(p);var y=p.length;if(y<2)return y?Np(p,l):p;var I=Np(p,dc(l/$i(p)));return Fi(p)?Do(xn(I),0,l).join(""):I.slice(0,l)}function BV(l,p,y,I){var k=p&m,V=us(l);function Z(){for(var ee=-1,ae=arguments.length,ge=-1,me=I.length,ye=ce(me+ae),Se=this&&this!==rr&&this instanceof Z?V:l;++ge<me;)ye[ge]=I[ge];for(;ae--;)ye[ge++]=arguments[++ee];return qr(Se,k?y:this,ye)}return Z}function nO(l){return function(p,y,I){return I&&typeof I!="number"&&mr(p,y,I)&&(y=I=r),p=fo(p),y===r?(y=p,p=0):y=fo(y),I=I===r?p<y?1:-1:fo(I),OV(p,y,I,l)}}function Cc(l){return function(p,y){return typeof p=="string"&&typeof y=="string"||(p=on(p),y=on(y)),l(p,y)}}function oO(l,p,y,I,k,V,Z,ee,ae,ge){var me=p&E,ye=me?Z:r,Se=me?r:Z,Ae=me?V:r,De=me?r:V;p|=me?_:C,p&=~(me?C:_),p&w||(p&=-4);var $e=[l,p,k,Ae,ye,De,Se,ee,ae,ge],Me=y.apply(r,$e);return Vp(l)&&gO(Me,$e),Me.placeholder=I,mO(Me,l,p)}function jp(l){var p=Ht[l];return function(y,I){if(y=on(y),I=I==null?0:lr(Be(I),292),I&&mS(y)){var k=(ot(y)+"e").split("e"),V=p(k[0]+"e"+(+k[1]+I));return k=(ot(V)+"e").split("e"),+(k[0]+"e"+(+k[1]-I))}return p(y)}}var FV=Wi&&1/tc(new Wi([,-0]))[1]==G?function(l){return new Wi(l)}:oh;function iO(l){return function(p){var y=cr(p);return y==de?fp(p):y==Le?o4(p):X$(p,l(p))}}function so(l,p,y,I,k,V,Z,ee){var ae=p&x;if(!ae&&typeof l!="function")throw new Qr(a);var ge=I?I.length:0;if(ge||(p&=-97,I=k=r),Z=Z===r?Z:Wt(Be(Z),0),ee=ee===r?ee:Be(ee),ge-=k?k.length:0,p&C){var me=I,ye=k;I=k=r}var Se=ae?r:zp(l),Ae=[l,p,y,I,k,me,ye,V,Z,ee];if(Se&&rH(Ae,Se),l=Ae[0],p=Ae[1],y=Ae[2],I=Ae[3],k=Ae[4],ee=Ae[9]=Ae[9]===r?ae?0:l.length:Wt(Ae[9]-ge,0),!ee&&p&(E|S)&&(p&=-25),!p||p==m)var De=qV(l,p,y);else p==E||p==S?De=zV(l,p,ee):(p==_||p==(m|_))&&!k.length?De=BV(l,p,y,I):De=Ec.apply(r,Ae);var $e=Se?zS:gO;return mO($e(De,Ae),l,p)}function aO(l,p,y,I){return l===r||_n(l,Hi[y])&&!ct.call(I,y)?p:l}function sO(l,p,y,I,k,V){return Nt(l)&&Nt(p)&&(V.set(p,l),yc(l,p,r,sO,V),V.delete(p)),l}function $V(l){return ps(l)?r:l}function lO(l,p,y,I,k,V){var Z=y&b,ee=l.length,ae=p.length;if(ee!=ae&&!(Z&&ae>ee))return!1;var ge=V.get(l),me=V.get(p);if(ge&&me)return ge==p&&me==l;var ye=-1,Se=!0,Ae=y&g?new ai:r;for(V.set(l,p),V.set(p,l);++ye<ee;){var De=l[ye],$e=p[ye];if(I)var Me=Z?I($e,De,ye,p,l,V):I(De,$e,ye,l,p,V);if(Me!==r){if(Me)continue;Se=!1;break}if(Ae){if(!ap(p,function(Ue,Ke){if(!Qa(Ae,Ke)&&(De===Ue||k(De,Ue,y,I,V)))return Ae.push(Ke)})){Se=!1;break}}else if(!(De===$e||k(De,$e,y,I,V))){Se=!1;break}}return V.delete(l),V.delete(p),Se}function VV(l,p,y,I,k,V,Z){switch(y){case Ne:if(l.byteLength!=p.byteLength||l.byteOffset!=p.byteOffset)return!1;l=l.buffer,p=p.buffer;case Je:return!(l.byteLength!=p.byteLength||!V(new sc(l),new sc(p)));case K:case Q:case Ee:return _n(+l,+p);case se:return l.name==p.name&&l.message==p.message;case Fe:case Ze:return l==p+"";case de:var ee=fp;case Le:var ae=I&b;if(ee||(ee=tc),l.size!=p.size&&!ae)return!1;var ge=Z.get(l);if(ge)return ge==p;I|=g,Z.set(l,p);var me=lO(ee(l),ee(p),I,k,V,Z);return Z.delete(l),me;case We:if(os)return os.call(l)==os.call(p)}return!1}function HV(l,p,y,I,k,V){var Z=y&b,ee=Lp(l),ae=ee.length,ge=Lp(p),me=ge.length;if(ae!=me&&!Z)return!1;for(var ye=ae;ye--;){var Se=ee[ye];if(!(Z?Se in p:ct.call(p,Se)))return!1}var Ae=V.get(l),De=V.get(p);if(Ae&&De)return Ae==p&&De==l;var $e=!0;V.set(l,p),V.set(p,l);for(var Me=Z;++ye<ae;){Se=ee[ye];var Ue=l[Se],Ke=p[Se];if(I)var $r=Z?I(Ke,Ue,Se,p,l,V):I(Ue,Ke,Se,l,p,V);if(!($r===r?Ue===Ke||k(Ue,Ke,y,I,V):$r)){$e=!1;break}Me||(Me=Se=="constructor")}if($e&&!Me){var br=l.constructor,Vr=p.constructor;br!=Vr&&"constructor"in l&&"constructor"in p&&!(typeof br=="function"&&br instanceof br&&typeof Vr=="function"&&Vr instanceof Vr)&&($e=!1)}return V.delete(l),V.delete(p),$e}function lo(l){return Wp(hO(l,r,EO),l+"")}function Lp(l){return NS(l,Xt,Fp)}function qp(l){return NS(l,Rr,cO)}var zp=pc?function(l){return pc.get(l)}:oh;function Rc(l){for(var p=l.name+"",y=Ui[p],I=ct.call(Ui,p)?y.length:0;I--;){var k=y[I],V=k.func;if(V==null||V==l)return k.name}return p}function Xi(l){var p=ct.call(B,"placeholder")?B:l;return p.placeholder}function ke(){var l=B.iteratee||rh;return l=l===rh?TS:l,arguments.length?l(arguments[0],arguments[1]):l}function Nc(l,p){var y=l.__data__;return JV(p)?y[typeof p=="string"?"string":"hash"]:y.map}function Bp(l){for(var p=Xt(l),y=p.length;y--;){var I=p[y],k=l[I];p[y]=[I,k,fO(k)]}return p}function ci(l,p){var y=t4(l,p);return PS(y)?y:r}function WV(l){var p=ct.call(l,oi),y=l[oi];try{l[oi]=r;var I=!0}catch{}var k=ic.call(l);return I&&(p?l[oi]=y:delete l[oi]),k}var Fp=hp?function(l){return l==null?[]:(l=ht(l),Ro(hp(l),function(p){return vS.call(l,p)}))}:ih,cO=hp?function(l){for(var p=[];l;)No(p,Fp(l)),l=lc(l);return p}:ih,cr=gr;(vp&&cr(new vp(new ArrayBuffer(1)))!=Ne||ts&&cr(new ts)!=de||gp&&cr(gp.resolve())!=Ce||Wi&&cr(new Wi)!=Le||rs&&cr(new rs)!=tt)&&(cr=function(l){var p=gr(l),y=p==le?l.constructor:r,I=y?ui(y):"";if(I)switch(I){case R4:return Ne;case N4:return de;case I4:return Ce;case P4:return Le;case T4:return tt}return p});function UV(l,p,y){for(var I=-1,k=y.length;++I<k;){var V=y[I],Z=V.size;switch(V.type){case"drop":l+=Z;break;case"dropRight":p-=Z;break;case"take":p=lr(p,l+Z);break;case"takeRight":l=Wt(l,p-Z);break}}return{start:l,end:p}}function GV(l){var p=l.match(ti);return p?p[1].split(jf):[]}function uO(l,p,y){p=ko(p,l);for(var I=-1,k=p.length,V=!1;++I<k;){var Z=Bn(p[I]);if(!(V=l!=null&&y(l,Z)))break;l=l[Z]}return V||++I!=k?V:(k=l==null?0:l.length,!!k&&Mc(k)&&co(Z,k)&&(ze(l)||di(l)))}function YV(l){var p=l.length,y=new l.constructor(p);return p&&typeof l[0]=="string"&&ct.call(l,"index")&&(y.index=l.index,y.input=l.input),y}function dO(l){return typeof l.constructor=="function"&&!ds(l)?Gi(lc(l)):{}}function KV(l,p,y){var I=l.constructor;switch(p){case Je:return Dp(l);case K:case Q:return new I(+l);case Ne:return AV(l,y);case je:case Qe:case At:case It:case mt:case Rt:case Qt:case fr:case pr:return GS(l,y);case de:return new I;case Ee:case Ze:return new I(l);case Fe:return kV(l);case Le:return new I;case We:return DV(l)}}function XV(l,p){var y=p.length;if(!y)return l;var I=y-1;return p[I]=(y>1?"& ":"")+p[I],p=p.join(y>2?", ":" "),l.replace(no,`{
|
|
67
|
+
/* [wrapped with `+p+`] */
|
|
68
|
+
`)}function ZV(l){return ze(l)||di(l)||!!(gS&&l&&l[gS])}function co(l,p){var y=typeof l;return p=p??F,!!p&&(y=="number"||y!="symbol"&&Wf.test(l))&&l>-1&&l%1==0&&l<p}function mr(l,p,y){if(!Nt(y))return!1;var I=typeof p;return(I=="number"?Cr(y)&&co(p,y.length):I=="string"&&p in y)?_n(y[p],l):!1}function $p(l,p){if(ze(l))return!1;var y=typeof l;return y=="number"||y=="symbol"||y=="boolean"||l==null||Fr(l)?!0:kt.test(l)||!Ln.test(l)||p!=null&&l in ht(p)}function JV(l){var p=typeof l;return p=="string"||p=="number"||p=="symbol"||p=="boolean"?l!=="__proto__":l===null}function Vp(l){var p=Rc(l),y=B[p];if(typeof y!="function"||!(p in Ye.prototype))return!1;if(l===y)return!0;var I=zp(y);return!!I&&l===I[0]}function QV(l){return!!fS&&fS in l}var eH=nc?uo:ah;function ds(l){var p=l&&l.constructor,y=typeof p=="function"&&p.prototype||Hi;return l===y}function fO(l){return l===l&&!Nt(l)}function pO(l,p){return function(y){return y==null?!1:y[l]===p&&(p!==r||l in ht(y))}}function tH(l){var p=kc(l,function(I){return y.size===u&&y.clear(),I}),y=p.cache;return p}function rH(l,p){var y=l[1],I=p[1],k=y|I,V=k<(m|x|N),Z=I==N&&y==E||I==N&&y==P&&l[7].length<=p[8]||I==(N|P)&&p[7].length<=p[8]&&y==E;if(!(V||Z))return l;I&m&&(l[2]=p[2],k|=y&m?0:w);var ee=p[3];if(ee){var ae=l[3];l[3]=ae?KS(ae,ee,p[4]):ee,l[4]=ae?Io(l[3],d):p[4]}return ee=p[5],ee&&(ae=l[5],l[5]=ae?XS(ae,ee,p[6]):ee,l[6]=ae?Io(l[5],d):p[6]),ee=p[7],ee&&(l[7]=ee),I&N&&(l[8]=l[8]==null?p[8]:lr(l[8],p[8])),l[9]==null&&(l[9]=p[9]),l[0]=p[0],l[1]=k,l}function nH(l){var p=[];if(l!=null)for(var y in ht(l))p.push(y);return p}function oH(l){return ic.call(l)}function hO(l,p,y){return p=Wt(p===r?l.length-1:p,0),function(){for(var I=arguments,k=-1,V=Wt(I.length-p,0),Z=ce(V);++k<V;)Z[k]=I[p+k];k=-1;for(var ee=ce(p+1);++k<p;)ee[k]=I[k];return ee[p]=y(Z),qr(l,this,ee)}}function vO(l,p){return p.length<2?l:li(l,rn(p,0,-1))}function iH(l,p){for(var y=l.length,I=lr(p.length,y),k=Or(l);I--;){var V=p[I];l[I]=co(V,y)?k[V]:r}return l}function Hp(l,p){if(!(p==="constructor"&&typeof l[p]=="function")&&p!="__proto__")return l[p]}var gO=bO(zS),fs=x4||function(l,p){return rr.setTimeout(l,p)},Wp=bO(NV);function mO(l,p,y){var I=p+"";return Wp(l,XV(I,aH(GV(I),y)))}function bO(l){var p=0,y=0;return function(){var I=S4(),k=D-(I-y);if(y=I,k>0){if(++p>=L)return arguments[0]}else p=0;return l.apply(r,arguments)}}function Ic(l,p){var y=-1,I=l.length,k=I-1;for(p=p===r?I:p;++y<p;){var V=Rp(y,k),Z=l[V];l[V]=l[y],l[y]=Z}return l.length=p,l}var yO=tH(function(l){var p=[];return l.charCodeAt(0)===46&&p.push(""),l.replace(tr,function(y,I,k,V){p.push(k?V.replace(zf,"$1"):I||y)}),p});function Bn(l){if(typeof l=="string"||Fr(l))return l;var p=l+"";return p=="0"&&1/l==-G?"-0":p}function ui(l){if(l!=null){try{return oc.call(l)}catch{}try{return l+""}catch{}}return""}function aH(l,p){return Jr($,function(y){var I="_."+y[0];p&y[1]&&!Ql(l,I)&&l.push(I)}),l.sort()}function xO(l){if(l instanceof Ye)return l.clone();var p=new en(l.__wrapped__,l.__chain__);return p.__actions__=Or(l.__actions__),p.__index__=l.__index__,p.__values__=l.__values__,p}function sH(l,p,y){(y?mr(l,p,y):p===r)?p=1:p=Wt(Be(p),0);var I=l==null?0:l.length;if(!I||p<1)return[];for(var k=0,V=0,Z=ce(dc(I/p));k<I;)Z[V++]=rn(l,k,k+=p);return Z}function lH(l){for(var p=-1,y=l==null?0:l.length,I=0,k=[];++p<y;){var V=l[p];V&&(k[I++]=V)}return k}function cH(){var l=arguments.length;if(!l)return[];for(var p=ce(l-1),y=arguments[0],I=l;I--;)p[I-1]=arguments[I];return No(ze(y)?Or(y):[y],nr(p,1))}var uH=Ve(function(l,p){return Dt(l)?as(l,nr(p,1,Dt,!0)):[]}),dH=Ve(function(l,p){var y=nn(p);return Dt(y)&&(y=r),Dt(l)?as(l,nr(p,1,Dt,!0),ke(y,2)):[]}),fH=Ve(function(l,p){var y=nn(p);return Dt(y)&&(y=r),Dt(l)?as(l,nr(p,1,Dt,!0),r,y):[]});function pH(l,p,y){var I=l==null?0:l.length;return I?(p=y||p===r?1:Be(p),rn(l,p<0?0:p,I)):[]}function hH(l,p,y){var I=l==null?0:l.length;return I?(p=y||p===r?1:Be(p),p=I-p,rn(l,0,p<0?0:p)):[]}function vH(l,p){return l&&l.length?wc(l,ke(p,3),!0,!0):[]}function gH(l,p){return l&&l.length?wc(l,ke(p,3),!0):[]}function mH(l,p,y,I){var k=l==null?0:l.length;return k?(y&&typeof y!="number"&&mr(l,p,y)&&(y=0,I=k),cV(l,p,y,I)):[]}function wO(l,p,y){var I=l==null?0:l.length;if(!I)return-1;var k=y==null?0:Be(y);return k<0&&(k=Wt(I+k,0)),ec(l,ke(p,3),k)}function _O(l,p,y){var I=l==null?0:l.length;if(!I)return-1;var k=I-1;return y!==r&&(k=Be(y),k=y<0?Wt(I+k,0):lr(k,I-1)),ec(l,ke(p,3),k,!0)}function EO(l){var p=l==null?0:l.length;return p?nr(l,1):[]}function bH(l){var p=l==null?0:l.length;return p?nr(l,G):[]}function yH(l,p){var y=l==null?0:l.length;return y?(p=p===r?1:Be(p),nr(l,p)):[]}function xH(l){for(var p=-1,y=l==null?0:l.length,I={};++p<y;){var k=l[p];I[k[0]]=k[1]}return I}function SO(l){return l&&l.length?l[0]:r}function wH(l,p,y){var I=l==null?0:l.length;if(!I)return-1;var k=y==null?0:Be(y);return k<0&&(k=Wt(I+k,0)),Bi(l,p,k)}function _H(l){var p=l==null?0:l.length;return p?rn(l,0,-1):[]}var EH=Ve(function(l){var p=Ot(l,Ap);return p.length&&p[0]===l[0]?_p(p):[]}),SH=Ve(function(l){var p=nn(l),y=Ot(l,Ap);return p===nn(y)?p=r:y.pop(),y.length&&y[0]===l[0]?_p(y,ke(p,2)):[]}),OH=Ve(function(l){var p=nn(l),y=Ot(l,Ap);return p=typeof p=="function"?p:r,p&&y.pop(),y.length&&y[0]===l[0]?_p(y,r,p):[]});function CH(l,p){return l==null?"":_4.call(l,p)}function nn(l){var p=l==null?0:l.length;return p?l[p-1]:r}function RH(l,p,y){var I=l==null?0:l.length;if(!I)return-1;var k=I;return y!==r&&(k=Be(y),k=k<0?Wt(I+k,0):lr(k,I-1)),p===p?a4(l,p,k):ec(l,oS,k,!0)}function NH(l,p){return l&&l.length?MS(l,Be(p)):r}var IH=Ve(OO);function OO(l,p){return l&&l.length&&p&&p.length?Cp(l,p):l}function PH(l,p,y){return l&&l.length&&p&&p.length?Cp(l,p,ke(y,2)):l}function TH(l,p,y){return l&&l.length&&p&&p.length?Cp(l,p,r,y):l}var AH=lo(function(l,p){var y=l==null?0:l.length,I=bp(l,p);return qS(l,Ot(p,function(k){return co(k,y)?+k:k}).sort(YS)),I});function kH(l,p){var y=[];if(!(l&&l.length))return y;var I=-1,k=[],V=l.length;for(p=ke(p,3);++I<V;){var Z=l[I];p(Z,I,l)&&(y.push(Z),k.push(I))}return qS(l,k),y}function Up(l){return l==null?l:C4.call(l)}function DH(l,p,y){var I=l==null?0:l.length;return I?(y&&typeof y!="number"&&mr(l,p,y)?(p=0,y=I):(p=p==null?0:Be(p),y=y===r?I:Be(y)),rn(l,p,y)):[]}function MH(l,p){return xc(l,p)}function jH(l,p,y){return Ip(l,p,ke(y,2))}function LH(l,p){var y=l==null?0:l.length;if(y){var I=xc(l,p);if(I<y&&_n(l[I],p))return I}return-1}function qH(l,p){return xc(l,p,!0)}function zH(l,p,y){return Ip(l,p,ke(y,2),!0)}function BH(l,p){var y=l==null?0:l.length;if(y){var I=xc(l,p,!0)-1;if(_n(l[I],p))return I}return-1}function FH(l){return l&&l.length?BS(l):[]}function $H(l,p){return l&&l.length?BS(l,ke(p,2)):[]}function VH(l){var p=l==null?0:l.length;return p?rn(l,1,p):[]}function HH(l,p,y){return l&&l.length?(p=y||p===r?1:Be(p),rn(l,0,p<0?0:p)):[]}function WH(l,p,y){var I=l==null?0:l.length;return I?(p=y||p===r?1:Be(p),p=I-p,rn(l,p<0?0:p,I)):[]}function UH(l,p){return l&&l.length?wc(l,ke(p,3),!1,!0):[]}function GH(l,p){return l&&l.length?wc(l,ke(p,3)):[]}var YH=Ve(function(l){return Ao(nr(l,1,Dt,!0))}),KH=Ve(function(l){var p=nn(l);return Dt(p)&&(p=r),Ao(nr(l,1,Dt,!0),ke(p,2))}),XH=Ve(function(l){var p=nn(l);return p=typeof p=="function"?p:r,Ao(nr(l,1,Dt,!0),r,p)});function ZH(l){return l&&l.length?Ao(l):[]}function JH(l,p){return l&&l.length?Ao(l,ke(p,2)):[]}function QH(l,p){return p=typeof p=="function"?p:r,l&&l.length?Ao(l,r,p):[]}function Gp(l){if(!(l&&l.length))return[];var p=0;return l=Ro(l,function(y){if(Dt(y))return p=Wt(y.length,p),!0}),up(p,function(y){return Ot(l,sp(y))})}function CO(l,p){if(!(l&&l.length))return[];var y=Gp(l);return p==null?y:Ot(y,function(I){return qr(p,r,I)})}var e6=Ve(function(l,p){return Dt(l)?as(l,p):[]}),t6=Ve(function(l){return Tp(Ro(l,Dt))}),r6=Ve(function(l){var p=nn(l);return Dt(p)&&(p=r),Tp(Ro(l,Dt),ke(p,2))}),n6=Ve(function(l){var p=nn(l);return p=typeof p=="function"?p:r,Tp(Ro(l,Dt),r,p)}),o6=Ve(Gp);function i6(l,p){return HS(l||[],p||[],is)}function a6(l,p){return HS(l||[],p||[],cs)}var s6=Ve(function(l){var p=l.length,y=p>1?l[p-1]:r;return y=typeof y=="function"?(l.pop(),y):r,CO(l,y)});function RO(l){var p=B(l);return p.__chain__=!0,p}function l6(l,p){return p(l),l}function Pc(l,p){return p(l)}var c6=lo(function(l){var p=l.length,y=p?l[0]:0,I=this.__wrapped__,k=function(V){return bp(V,l)};return p>1||this.__actions__.length||!(I instanceof Ye)||!co(y)?this.thru(k):(I=I.slice(y,+y+(p?1:0)),I.__actions__.push({func:Pc,args:[k],thisArg:r}),new en(I,this.__chain__).thru(function(V){return p&&!V.length&&V.push(r),V}))});function u6(){return RO(this)}function d6(){return new en(this.value(),this.__chain__)}function f6(){this.__values__===r&&(this.__values__=FO(this.value()));var l=this.__index__>=this.__values__.length,p=l?r:this.__values__[this.__index__++];return{done:l,value:p}}function p6(){return this}function h6(l){for(var p,y=this;y instanceof vc;){var I=xO(y);I.__index__=0,I.__values__=r,p?k.__wrapped__=I:p=I;var k=I;y=y.__wrapped__}return k.__wrapped__=l,p}function v6(){var l=this.__wrapped__;if(l instanceof Ye){var p=l;return this.__actions__.length&&(p=new Ye(this)),p=p.reverse(),p.__actions__.push({func:Pc,args:[Up],thisArg:r}),new en(p,this.__chain__)}return this.thru(Up)}function g6(){return VS(this.__wrapped__,this.__actions__)}var m6=_c(function(l,p,y){ct.call(l,y)?++l[y]:ao(l,y,1)});function b6(l,p,y){var I=ze(l)?rS:lV;return y&&mr(l,p,y)&&(p=r),I(l,ke(p,3))}function y6(l,p){var y=ze(l)?Ro:CS;return y(l,ke(p,3))}var x6=eO(wO),w6=eO(_O);function _6(l,p){return nr(Tc(l,p),1)}function E6(l,p){return nr(Tc(l,p),G)}function S6(l,p,y){return y=y===r?1:Be(y),nr(Tc(l,p),y)}function NO(l,p){var y=ze(l)?Jr:To;return y(l,ke(p,3))}function IO(l,p){var y=ze(l)?V$:OS;return y(l,ke(p,3))}var O6=_c(function(l,p,y){ct.call(l,y)?l[y].push(p):ao(l,y,[p])});function C6(l,p,y,I){l=Cr(l)?l:Ji(l),y=y&&!I?Be(y):0;var k=l.length;return y<0&&(y=Wt(k+y,0)),jc(l)?y<=k&&l.indexOf(p,y)>-1:!!k&&Bi(l,p,y)>-1}var R6=Ve(function(l,p,y){var I=-1,k=typeof p=="function",V=Cr(l)?ce(l.length):[];return To(l,function(Z){V[++I]=k?qr(p,Z,y):ss(Z,p,y)}),V}),N6=_c(function(l,p,y){ao(l,y,p)});function Tc(l,p){var y=ze(l)?Ot:AS;return y(l,ke(p,3))}function I6(l,p,y,I){return l==null?[]:(ze(p)||(p=p==null?[]:[p]),y=I?r:y,ze(y)||(y=y==null?[]:[y]),jS(l,p,y))}var P6=_c(function(l,p,y){l[y?0:1].push(p)},function(){return[[],[]]});function T6(l,p,y){var I=ze(l)?ip:aS,k=arguments.length<3;return I(l,ke(p,4),y,k,To)}function A6(l,p,y){var I=ze(l)?H$:aS,k=arguments.length<3;return I(l,ke(p,4),y,k,OS)}function k6(l,p){var y=ze(l)?Ro:CS;return y(l,Dc(ke(p,3)))}function D6(l){var p=ze(l)?wS:CV;return p(l)}function M6(l,p,y){(y?mr(l,p,y):p===r)?p=1:p=Be(p);var I=ze(l)?nV:RV;return I(l,p)}function j6(l){var p=ze(l)?oV:IV;return p(l)}function L6(l){if(l==null)return 0;if(Cr(l))return jc(l)?$i(l):l.length;var p=cr(l);return p==de||p==Le?l.size:Sp(l).length}function q6(l,p,y){var I=ze(l)?ap:PV;return y&&mr(l,p,y)&&(p=r),I(l,ke(p,3))}var z6=Ve(function(l,p){if(l==null)return[];var y=p.length;return y>1&&mr(l,p[0],p[1])?p=[]:y>2&&mr(p[0],p[1],p[2])&&(p=[p[0]]),jS(l,nr(p,1),[])}),Ac=y4||function(){return rr.Date.now()};function B6(l,p){if(typeof p!="function")throw new Qr(a);return l=Be(l),function(){if(--l<1)return p.apply(this,arguments)}}function PO(l,p,y){return p=y?r:p,p=l&&p==null?l.length:p,so(l,N,r,r,r,r,p)}function TO(l,p){var y;if(typeof p!="function")throw new Qr(a);return l=Be(l),function(){return--l>0&&(y=p.apply(this,arguments)),l<=1&&(p=r),y}}var Yp=Ve(function(l,p,y){var I=m;if(y.length){var k=Io(y,Xi(Yp));I|=_}return so(l,I,p,y,k)}),AO=Ve(function(l,p,y){var I=m|x;if(y.length){var k=Io(y,Xi(AO));I|=_}return so(p,I,l,y,k)});function kO(l,p,y){p=y?r:p;var I=so(l,E,r,r,r,r,r,p);return I.placeholder=kO.placeholder,I}function DO(l,p,y){p=y?r:p;var I=so(l,S,r,r,r,r,r,p);return I.placeholder=DO.placeholder,I}function MO(l,p,y){var I,k,V,Z,ee,ae,ge=0,me=!1,ye=!1,Se=!0;if(typeof l!="function")throw new Qr(a);p=on(p)||0,Nt(y)&&(me=!!y.leading,ye="maxWait"in y,V=ye?Wt(on(y.maxWait)||0,p):V,Se="trailing"in y?!!y.trailing:Se);function Ae(Mt){var En=I,po=k;return I=k=r,ge=Mt,Z=l.apply(po,En),Z}function De(Mt){return ge=Mt,ee=fs(Ue,p),me?Ae(Mt):Z}function $e(Mt){var En=Mt-ae,po=Mt-ge,eC=p-En;return ye?lr(eC,V-po):eC}function Me(Mt){var En=Mt-ae,po=Mt-ge;return ae===r||En>=p||En<0||ye&&po>=V}function Ue(){var Mt=Ac();if(Me(Mt))return Ke(Mt);ee=fs(Ue,$e(Mt))}function Ke(Mt){return ee=r,Se&&I?Ae(Mt):(I=k=r,Z)}function $r(){ee!==r&&WS(ee),ge=0,I=ae=k=ee=r}function br(){return ee===r?Z:Ke(Ac())}function Vr(){var Mt=Ac(),En=Me(Mt);if(I=arguments,k=this,ae=Mt,En){if(ee===r)return De(ae);if(ye)return WS(ee),ee=fs(Ue,p),Ae(ae)}return ee===r&&(ee=fs(Ue,p)),Z}return Vr.cancel=$r,Vr.flush=br,Vr}var F6=Ve(function(l,p){return SS(l,1,p)}),$6=Ve(function(l,p,y){return SS(l,on(p)||0,y)});function V6(l){return so(l,A)}function kc(l,p){if(typeof l!="function"||p!=null&&typeof p!="function")throw new Qr(a);var y=function(){var I=arguments,k=p?p.apply(this,I):I[0],V=y.cache;if(V.has(k))return V.get(k);var Z=l.apply(this,I);return y.cache=V.set(k,Z)||V,Z};return y.cache=new(kc.Cache||io),y}kc.Cache=io;function Dc(l){if(typeof l!="function")throw new Qr(a);return function(){var p=arguments;switch(p.length){case 0:return!l.call(this);case 1:return!l.call(this,p[0]);case 2:return!l.call(this,p[0],p[1]);case 3:return!l.call(this,p[0],p[1],p[2])}return!l.apply(this,p)}}function H6(l){return TO(2,l)}var W6=TV(function(l,p){p=p.length==1&&ze(p[0])?Ot(p[0],zr(ke())):Ot(nr(p,1),zr(ke()));var y=p.length;return Ve(function(I){for(var k=-1,V=lr(I.length,y);++k<V;)I[k]=p[k].call(this,I[k]);return qr(l,this,I)})}),Kp=Ve(function(l,p){var y=Io(p,Xi(Kp));return so(l,_,r,p,y)}),jO=Ve(function(l,p){var y=Io(p,Xi(jO));return so(l,C,r,p,y)}),U6=lo(function(l,p){return so(l,P,r,r,r,p)});function G6(l,p){if(typeof l!="function")throw new Qr(a);return p=p===r?p:Be(p),Ve(l,p)}function Y6(l,p){if(typeof l!="function")throw new Qr(a);return p=p==null?0:Wt(Be(p),0),Ve(function(y){var I=y[p],k=Do(y,0,p);return I&&No(k,I),qr(l,this,k)})}function K6(l,p,y){var I=!0,k=!0;if(typeof l!="function")throw new Qr(a);return Nt(y)&&(I="leading"in y?!!y.leading:I,k="trailing"in y?!!y.trailing:k),MO(l,p,{leading:I,maxWait:p,trailing:k})}function X6(l){return PO(l,1)}function Z6(l,p){return Kp(kp(p),l)}function J6(){if(!arguments.length)return[];var l=arguments[0];return ze(l)?l:[l]}function Q6(l){return tn(l,v)}function eW(l,p){return p=typeof p=="function"?p:r,tn(l,v,p)}function tW(l){return tn(l,f|v)}function rW(l,p){return p=typeof p=="function"?p:r,tn(l,f|v,p)}function nW(l,p){return p==null||ES(l,p,Xt(p))}function _n(l,p){return l===p||l!==l&&p!==p}var oW=Cc(wp),iW=Cc(function(l,p){return l>=p}),di=IS((function(){return arguments})())?IS:function(l){return Pt(l)&&ct.call(l,"callee")&&!vS.call(l,"callee")},ze=ce.isArray,aW=XE?zr(XE):hV;function Cr(l){return l!=null&&Mc(l.length)&&!uo(l)}function Dt(l){return Pt(l)&&Cr(l)}function sW(l){return l===!0||l===!1||Pt(l)&&gr(l)==K}var Mo=w4||ah,lW=ZE?zr(ZE):vV;function cW(l){return Pt(l)&&l.nodeType===1&&!ps(l)}function uW(l){if(l==null)return!0;if(Cr(l)&&(ze(l)||typeof l=="string"||typeof l.splice=="function"||Mo(l)||Zi(l)||di(l)))return!l.length;var p=cr(l);if(p==de||p==Le)return!l.size;if(ds(l))return!Sp(l).length;for(var y in l)if(ct.call(l,y))return!1;return!0}function dW(l,p){return ls(l,p)}function fW(l,p,y){y=typeof y=="function"?y:r;var I=y?y(l,p):r;return I===r?ls(l,p,r,y):!!I}function Xp(l){if(!Pt(l))return!1;var p=gr(l);return p==se||p==ne||typeof l.message=="string"&&typeof l.name=="string"&&!ps(l)}function pW(l){return typeof l=="number"&&mS(l)}function uo(l){if(!Nt(l))return!1;var p=gr(l);return p==te||p==be||p==H||p==Te}function LO(l){return typeof l=="number"&&l==Be(l)}function Mc(l){return typeof l=="number"&&l>-1&&l%1==0&&l<=F}function Nt(l){var p=typeof l;return l!=null&&(p=="object"||p=="function")}function Pt(l){return l!=null&&typeof l=="object"}var qO=JE?zr(JE):mV;function hW(l,p){return l===p||Ep(l,p,Bp(p))}function vW(l,p,y){return y=typeof y=="function"?y:r,Ep(l,p,Bp(p),y)}function gW(l){return zO(l)&&l!=+l}function mW(l){if(eH(l))throw new qe(i);return PS(l)}function bW(l){return l===null}function yW(l){return l==null}function zO(l){return typeof l=="number"||Pt(l)&&gr(l)==Ee}function ps(l){if(!Pt(l)||gr(l)!=le)return!1;var p=lc(l);if(p===null)return!0;var y=ct.call(p,"constructor")&&p.constructor;return typeof y=="function"&&y instanceof y&&oc.call(y)==v4}var Zp=QE?zr(QE):bV;function xW(l){return LO(l)&&l>=-F&&l<=F}var BO=eS?zr(eS):yV;function jc(l){return typeof l=="string"||!ze(l)&&Pt(l)&&gr(l)==Ze}function Fr(l){return typeof l=="symbol"||Pt(l)&&gr(l)==We}var Zi=tS?zr(tS):xV;function wW(l){return l===r}function _W(l){return Pt(l)&&cr(l)==tt}function EW(l){return Pt(l)&&gr(l)==wt}var SW=Cc(Op),OW=Cc(function(l,p){return l<=p});function FO(l){if(!l)return[];if(Cr(l))return jc(l)?xn(l):Or(l);if(es&&l[es])return n4(l[es]());var p=cr(l),y=p==de?fp:p==Le?tc:Ji;return y(l)}function fo(l){if(!l)return l===0?l:0;if(l=on(l),l===G||l===-G){var p=l<0?-1:1;return p*J}return l===l?l:0}function Be(l){var p=fo(l),y=p%1;return p===p?y?p-y:p:0}function $O(l){return l?si(Be(l),0,U):0}function on(l){if(typeof l=="number")return l;if(Fr(l))return z;if(Nt(l)){var p=typeof l.valueOf=="function"?l.valueOf():l;l=Nt(p)?p+"":p}if(typeof l!="string")return l===0?l:+l;l=sS(l);var y=$f.test(l);return y||Hf.test(l)?B$(l.slice(2),y?2:8):Ff.test(l)?z:+l}function VO(l){return zn(l,Rr(l))}function CW(l){return l?si(Be(l),-F,F):l===0?l:0}function ot(l){return l==null?"":Br(l)}var RW=Yi(function(l,p){if(ds(p)||Cr(p)){zn(p,Xt(p),l);return}for(var y in p)ct.call(p,y)&&is(l,y,p[y])}),HO=Yi(function(l,p){zn(p,Rr(p),l)}),Lc=Yi(function(l,p,y,I){zn(p,Rr(p),l,I)}),NW=Yi(function(l,p,y,I){zn(p,Xt(p),l,I)}),IW=lo(bp);function PW(l,p){var y=Gi(l);return p==null?y:_S(y,p)}var TW=Ve(function(l,p){l=ht(l);var y=-1,I=p.length,k=I>2?p[2]:r;for(k&&mr(p[0],p[1],k)&&(I=1);++y<I;)for(var V=p[y],Z=Rr(V),ee=-1,ae=Z.length;++ee<ae;){var ge=Z[ee],me=l[ge];(me===r||_n(me,Hi[ge])&&!ct.call(l,ge))&&(l[ge]=V[ge])}return l}),AW=Ve(function(l){return l.push(r,sO),qr(WO,r,l)});function kW(l,p){return nS(l,ke(p,3),qn)}function DW(l,p){return nS(l,ke(p,3),xp)}function MW(l,p){return l==null?l:yp(l,ke(p,3),Rr)}function jW(l,p){return l==null?l:RS(l,ke(p,3),Rr)}function LW(l,p){return l&&qn(l,ke(p,3))}function qW(l,p){return l&&xp(l,ke(p,3))}function zW(l){return l==null?[]:bc(l,Xt(l))}function BW(l){return l==null?[]:bc(l,Rr(l))}function Jp(l,p,y){var I=l==null?r:li(l,p);return I===r?y:I}function FW(l,p){return l!=null&&uO(l,p,uV)}function Qp(l,p){return l!=null&&uO(l,p,dV)}var $W=rO(function(l,p,y){p!=null&&typeof p.toString!="function"&&(p=ic.call(p)),l[p]=y},th(Nr)),VW=rO(function(l,p,y){p!=null&&typeof p.toString!="function"&&(p=ic.call(p)),ct.call(l,p)?l[p].push(y):l[p]=[y]},ke),HW=Ve(ss);function Xt(l){return Cr(l)?xS(l):Sp(l)}function Rr(l){return Cr(l)?xS(l,!0):wV(l)}function WW(l,p){var y={};return p=ke(p,3),qn(l,function(I,k,V){ao(y,p(I,k,V),I)}),y}function UW(l,p){var y={};return p=ke(p,3),qn(l,function(I,k,V){ao(y,k,p(I,k,V))}),y}var GW=Yi(function(l,p,y){yc(l,p,y)}),WO=Yi(function(l,p,y,I){yc(l,p,y,I)}),YW=lo(function(l,p){var y={};if(l==null)return y;var I=!1;p=Ot(p,function(V){return V=ko(V,l),I||(I=V.length>1),V}),zn(l,qp(l),y),I&&(y=tn(y,f|h|v,$V));for(var k=p.length;k--;)Pp(y,p[k]);return y});function KW(l,p){return UO(l,Dc(ke(p)))}var XW=lo(function(l,p){return l==null?{}:EV(l,p)});function UO(l,p){if(l==null)return{};var y=Ot(qp(l),function(I){return[I]});return p=ke(p),LS(l,y,function(I,k){return p(I,k[0])})}function ZW(l,p,y){p=ko(p,l);var I=-1,k=p.length;for(k||(k=1,l=r);++I<k;){var V=l==null?r:l[Bn(p[I])];V===r&&(I=k,V=y),l=uo(V)?V.call(l):V}return l}function JW(l,p,y){return l==null?l:cs(l,p,y)}function QW(l,p,y,I){return I=typeof I=="function"?I:r,l==null?l:cs(l,p,y,I)}var GO=iO(Xt),YO=iO(Rr);function eU(l,p,y){var I=ze(l),k=I||Mo(l)||Zi(l);if(p=ke(p,4),y==null){var V=l&&l.constructor;k?y=I?new V:[]:Nt(l)?y=uo(V)?Gi(lc(l)):{}:y={}}return(k?Jr:qn)(l,function(Z,ee,ae){return p(y,Z,ee,ae)}),y}function tU(l,p){return l==null?!0:Pp(l,p)}function rU(l,p,y){return l==null?l:$S(l,p,kp(y))}function nU(l,p,y,I){return I=typeof I=="function"?I:r,l==null?l:$S(l,p,kp(y),I)}function Ji(l){return l==null?[]:dp(l,Xt(l))}function oU(l){return l==null?[]:dp(l,Rr(l))}function iU(l,p,y){return y===r&&(y=p,p=r),y!==r&&(y=on(y),y=y===y?y:0),p!==r&&(p=on(p),p=p===p?p:0),si(on(l),p,y)}function aU(l,p,y){return p=fo(p),y===r?(y=p,p=0):y=fo(y),l=on(l),fV(l,p,y)}function sU(l,p,y){if(y&&typeof y!="boolean"&&mr(l,p,y)&&(p=y=r),y===r&&(typeof p=="boolean"?(y=p,p=r):typeof l=="boolean"&&(y=l,l=r)),l===r&&p===r?(l=0,p=1):(l=fo(l),p===r?(p=l,l=0):p=fo(p)),l>p){var I=l;l=p,p=I}if(y||l%1||p%1){var k=bS();return lr(l+k*(p-l+z$("1e-"+((k+"").length-1))),p)}return Rp(l,p)}var lU=Ki(function(l,p,y){return p=p.toLowerCase(),l+(y?KO(p):p)});function KO(l){return eh(ot(l).toLowerCase())}function XO(l){return l=ot(l),l&&l.replace(Uf,J$).replace(I$,"")}function cU(l,p,y){l=ot(l),p=Br(p);var I=l.length;y=y===r?I:si(Be(y),0,I);var k=y;return y-=p.length,y>=0&&l.slice(y,k)==p}function uU(l){return l=ot(l),l&&jr.test(l)?l.replace(Vt,Q$):l}function dU(l){return l=ot(l),l&&yn.test(l)?l.replace(vr,"\\$&"):l}var fU=Ki(function(l,p,y){return l+(y?"-":"")+p.toLowerCase()}),pU=Ki(function(l,p,y){return l+(y?" ":"")+p.toLowerCase()}),hU=QS("toLowerCase");function vU(l,p,y){l=ot(l),p=Be(p);var I=p?$i(l):0;if(!p||I>=p)return l;var k=(p-I)/2;return Oc(fc(k),y)+l+Oc(dc(k),y)}function gU(l,p,y){l=ot(l),p=Be(p);var I=p?$i(l):0;return p&&I<p?l+Oc(p-I,y):l}function mU(l,p,y){l=ot(l),p=Be(p);var I=p?$i(l):0;return p&&I<p?Oc(p-I,y)+l:l}function bU(l,p,y){return y||p==null?p=0:p&&(p=+p),O4(ot(l).replace(Sr,""),p||0)}function yU(l,p,y){return(y?mr(l,p,y):p===r)?p=1:p=Be(p),Np(ot(l),p)}function xU(){var l=arguments,p=ot(l[0]);return l.length<3?p:p.replace(l[1],l[2])}var wU=Ki(function(l,p,y){return l+(y?"_":"")+p.toLowerCase()});function _U(l,p,y){return y&&typeof y!="number"&&mr(l,p,y)&&(p=y=r),y=y===r?U:y>>>0,y?(l=ot(l),l&&(typeof p=="string"||p!=null&&!Zp(p))&&(p=Br(p),!p&&Fi(l))?Do(xn(l),0,y):l.split(p,y)):[]}var EU=Ki(function(l,p,y){return l+(y?" ":"")+eh(p)});function SU(l,p,y){return l=ot(l),y=y==null?0:si(Be(y),0,l.length),p=Br(p),l.slice(y,y+p.length)==p}function OU(l,p,y){var I=B.templateSettings;y&&mr(l,p,y)&&(p=r),l=ot(l),p=Lc({},p,I,aO);var k=Lc({},p.imports,I.imports,aO),V=Xt(k),Z=dp(k,V),ee,ae,ge=0,me=p.interpolate||ji,ye="__p += '",Se=pp((p.escape||ji).source+"|"+me.source+"|"+(me===hr?Bf:ji).source+"|"+(p.evaluate||ji).source+"|$","g"),Ae="//# sourceURL="+(ct.call(p,"sourceURL")?(p.sourceURL+"").replace(/\s/g," "):"lodash.templateSources["+ ++D$+"]")+`
|
|
69
|
+
`;l.replace(Se,function(Me,Ue,Ke,$r,br,Vr){return Ke||(Ke=$r),ye+=l.slice(ge,Vr).replace(Fl,e4),Ue&&(ee=!0,ye+=`' +
|
|
70
|
+
__e(`+Ue+`) +
|
|
71
|
+
'`),br&&(ae=!0,ye+=`';
|
|
72
|
+
`+br+`;
|
|
73
|
+
__p += '`),Ke&&(ye+=`' +
|
|
74
|
+
((__t = (`+Ke+`)) == null ? '' : __t) +
|
|
75
|
+
'`),ge=Vr+Me.length,Me}),ye+=`';
|
|
76
|
+
`;var De=ct.call(p,"variable")&&p.variable;if(!De)ye=`with (obj) {
|
|
77
|
+
`+ye+`
|
|
59
78
|
}
|
|
60
|
-
`;else if(
|
|
61
|
-
`+(
|
|
62
|
-
`)+"var __t, __p = ''"+(
|
|
79
|
+
`;else if(qf.test(De))throw new qe(s);ye=(ae?ye.replace(Xr,""):ye).replace(Co,"$1").replace(Ka,"$1;"),ye="function("+(De||"obj")+`) {
|
|
80
|
+
`+(De?"":`obj || (obj = {});
|
|
81
|
+
`)+"var __t, __p = ''"+(ee?", __e = _.escape":"")+(ae?`, __j = Array.prototype.join;
|
|
63
82
|
function print() { __p += __j.call(arguments, '') }
|
|
64
83
|
`:`;
|
|
65
|
-
`)+
|
|
66
|
-
}`;var je=j1(function(){return Ue(q,Ce+"return "+me).apply(r,U)});if(je.source=me,jf(je))throw je;return je}function rz(s){return Ge(s).toLowerCase()}function nz(s){return Ge(s).toUpperCase()}function iz(s,l,g){if(s=Ge(s),s&&(g||l===r))return Uw(s);if(!s||!(l=tr(l)))return s;var O=Pr(s),P=Pr(l),q=Vw(O,P),U=Ww(O,P)+1;return Dn(O,q,U).join("")}function oz(s,l,g){if(s=Ge(s),s&&(g||l===r))return s.slice(0,Kw(s)+1);if(!s||!(l=tr(l)))return s;var O=Pr(s),P=Ww(O,Pr(l))+1;return Dn(O,0,P).join("")}function az(s,l,g){if(s=Ge(s),s&&(g||l===r))return s.replace(Ao,"");if(!s||!(l=tr(l)))return s;var O=Pr(s),P=Vw(O,Pr(l));return Dn(O,P).join("")}function sz(s,l){var g=k,O=B;if(ft(l)){var P="separator"in l?l.separator:P;g="length"in l?De(l.length):g,O="omission"in l?tr(l.omission):O}s=Ge(s);var q=s.length;if(ji(s)){var U=Pr(s);q=U.length}if(g>=q)return s;var X=g-qi(O);if(X<1)return O;var re=U?Dn(U,0,X).join(""):s.slice(0,X);if(P===r)return re+O;if(U&&(X+=re.length-X),qf(P)){if(s.slice(X).search(P)){var pe,ge=re;for(P.global||(P=Zl(P.source,Ge(ls.exec(P))+"g")),P.lastIndex=0;pe=P.exec(ge);)var me=pe.index;re=re.slice(0,me===r?X:me)}}else if(s.indexOf(tr(P),X)!=X){var be=re.lastIndexOf(P);be>-1&&(re=re.slice(0,be))}return re+O}function uz(s){return s=Ge(s),s&&gl.test(s)?s.replace(ts,kL):s}var cz=Hi(function(s,l,g){return s+(g?" ":"")+l.toUpperCase()}),Bf=q_("toUpperCase");function D1(s,l,g){return s=Ge(s),l=g?r:l,l===r?AL(s)?FL(s):EL(s):s.match(l)||[]}var j1=ke(function(s,l){try{return Qt(s,r,l)}catch(g){return jf(g)?g:new Ae(g)}}),lz=dn(function(s,l){return dr(l,function(g){g=Gr(g),ln(s,g,Mf(s[g],s))}),s});function fz(s){var l=s==null?0:s.length,g=Re();return s=l?ct(s,function(O){if(typeof O[1]!="function")throw new hr(a);return[g(O[0]),O[1]]}):[],ke(function(O){for(var P=-1;++P<l;){var q=s[P];if(Qt(q[0],this,O))return Qt(q[1],this,O)}})}function dz(s){return kB(vr(s,h))}function Ff(s){return function(){return s}}function hz(s,l){return s==null||s!==s?l:s}var pz=L_(),vz=L_(!0);function Vt(s){return s}function $f(s){return p_(typeof s=="function"?s:vr(s,h))}function gz(s){return g_(vr(s,h))}function mz(s,l){return m_(s,vr(l,h))}var yz=ke(function(s,l){return function(g){return Uo(g,s,l)}}),bz=ke(function(s,l){return function(g){return Uo(s,g,l)}});function zf(s,l,g){var O=St(l),P=zs(l,O);g==null&&!(ft(l)&&(P.length||!O.length))&&(g=l,l=s,s=this,P=zs(l,St(l)));var q=!(ft(g)&&"chain"in g)||!!g.chain,U=pn(s);return dr(P,function(X){var re=l[X];s[X]=re,U&&(s.prototype[X]=function(){var pe=this.__chain__;if(q||pe){var ge=s(this.__wrapped__),me=ge.__actions__=zt(this.__actions__);return me.push({func:re,args:arguments,thisArg:s}),ge.__chain__=pe,ge}return re.apply(s,In([this.value()],arguments))})}),s}function xz(){return Rt._===this&&(Rt._=WL),this}function Hf(){}function wz(s){return s=De(s),ke(function(l){return y_(l,s)})}var _z=xf(ct),Ez=xf(Bw),Sz=xf(Ul);function q1(s){return Rf(s)?Vl(Gr(s)):eF(s)}function Oz(s){return function(l){return s==null?r:ri(s,l)}}var Cz=F_(),Rz=F_(!0);function Uf(){return[]}function Vf(){return!1}function Iz(){return{}}function Pz(){return""}function Nz(){return!0}function Tz(s,l){if(s=De(s),s<1||s>Y)return[];var g=Q,O=At(s,Q);l=Re(l),s-=Q;for(var P=Kl(O,l);++g<s;)l(g);return P}function Az(s){return Me(s)?ct(s,Gr):rr(s)?[s]:zt(r1(Ge(s)))}function Mz(s){var l=++UL;return Ge(s)+l}var Dz=Ks(function(s,l){return s+l},0),jz=wf("ceil"),qz=Ks(function(s,l){return s/l},1),kz=wf("floor");function Lz(s){return s&&s.length?$s(s,Vt,af):r}function Bz(s,l){return s&&s.length?$s(s,Re(l,2),af):r}function Fz(s){return zw(s,Vt)}function $z(s,l){return zw(s,Re(l,2))}function zz(s){return s&&s.length?$s(s,Vt,lf):r}function Hz(s,l){return s&&s.length?$s(s,Re(l,2),lf):r}var Uz=Ks(function(s,l){return s*l},1),Vz=wf("round"),Wz=Ks(function(s,l){return s-l},0);function Gz(s){return s&&s.length?Gl(s,Vt):0}function Kz(s,l){return s&&s.length?Gl(s,Re(l,2)):0}return M.after=g3,M.ary=h1,M.assign=n5,M.assignIn=R1,M.assignInWith=su,M.assignWith=i5,M.at=o5,M.before=p1,M.bind=Mf,M.bindAll=lz,M.bindKey=v1,M.castArray=I3,M.chain=l1,M.chunk=kF,M.compact=LF,M.concat=BF,M.cond=fz,M.conforms=dz,M.constant=Ff,M.countBy=G$,M.create=a5,M.curry=g1,M.curryRight=m1,M.debounce=y1,M.defaults=s5,M.defaultsDeep=u5,M.defer=m3,M.delay=y3,M.difference=FF,M.differenceBy=$F,M.differenceWith=zF,M.drop=HF,M.dropRight=UF,M.dropRightWhile=VF,M.dropWhile=WF,M.fill=GF,M.filter=Y$,M.flatMap=J$,M.flatMapDeep=Q$,M.flatMapDepth=e3,M.flatten=a1,M.flattenDeep=KF,M.flattenDepth=YF,M.flip=b3,M.flow=pz,M.flowRight=vz,M.fromPairs=XF,M.functions=v5,M.functionsIn=g5,M.groupBy=t3,M.initial=JF,M.intersection=QF,M.intersectionBy=e$,M.intersectionWith=t$,M.invert=y5,M.invertBy=b5,M.invokeMap=n3,M.iteratee=$f,M.keyBy=i3,M.keys=St,M.keysIn=Ut,M.map=tu,M.mapKeys=w5,M.mapValues=_5,M.matches=gz,M.matchesProperty=mz,M.memoize=nu,M.merge=E5,M.mergeWith=I1,M.method=yz,M.methodOf=bz,M.mixin=zf,M.negate=iu,M.nthArg=wz,M.omit=S5,M.omitBy=O5,M.once=x3,M.orderBy=o3,M.over=_z,M.overArgs=w3,M.overEvery=Ez,M.overSome=Sz,M.partial=Df,M.partialRight=b1,M.partition=a3,M.pick=C5,M.pickBy=P1,M.property=q1,M.propertyOf=Oz,M.pull=o$,M.pullAll=u1,M.pullAllBy=a$,M.pullAllWith=s$,M.pullAt=u$,M.range=Cz,M.rangeRight=Rz,M.rearg=_3,M.reject=c3,M.remove=c$,M.rest=E3,M.reverse=Tf,M.sampleSize=f3,M.set=I5,M.setWith=P5,M.shuffle=d3,M.slice=l$,M.sortBy=v3,M.sortedUniq=m$,M.sortedUniqBy=y$,M.split=J5,M.spread=S3,M.tail=b$,M.take=x$,M.takeRight=w$,M.takeRightWhile=_$,M.takeWhile=E$,M.tap=L$,M.throttle=O3,M.thru=eu,M.toArray=S1,M.toPairs=N1,M.toPairsIn=T1,M.toPath=Az,M.toPlainObject=C1,M.transform=N5,M.unary=C3,M.union=S$,M.unionBy=O$,M.unionWith=C$,M.uniq=R$,M.uniqBy=I$,M.uniqWith=P$,M.unset=T5,M.unzip=Af,M.unzipWith=c1,M.update=A5,M.updateWith=M5,M.values=Wi,M.valuesIn=D5,M.without=N$,M.words=D1,M.wrap=R3,M.xor=T$,M.xorBy=A$,M.xorWith=M$,M.zip=D$,M.zipObject=j$,M.zipObjectDeep=q$,M.zipWith=k$,M.entries=N1,M.entriesIn=T1,M.extend=R1,M.extendWith=su,zf(M,M),M.add=Dz,M.attempt=j1,M.camelCase=L5,M.capitalize=A1,M.ceil=jz,M.clamp=j5,M.clone=P3,M.cloneDeep=T3,M.cloneDeepWith=A3,M.cloneWith=N3,M.conformsTo=M3,M.deburr=M1,M.defaultTo=hz,M.divide=qz,M.endsWith=B5,M.eq=Tr,M.escape=F5,M.escapeRegExp=$5,M.every=K$,M.find=X$,M.findIndex=i1,M.findKey=c5,M.findLast=Z$,M.findLastIndex=o1,M.findLastKey=l5,M.floor=kz,M.forEach=f1,M.forEachRight=d1,M.forIn=f5,M.forInRight=d5,M.forOwn=h5,M.forOwnRight=p5,M.get=kf,M.gt=D3,M.gte=j3,M.has=m5,M.hasIn=Lf,M.head=s1,M.identity=Vt,M.includes=r3,M.indexOf=ZF,M.inRange=q5,M.invoke=x5,M.isArguments=oi,M.isArray=Me,M.isArrayBuffer=q3,M.isArrayLike=Ht,M.isArrayLikeObject=pt,M.isBoolean=k3,M.isBuffer=jn,M.isDate=L3,M.isElement=B3,M.isEmpty=F3,M.isEqual=$3,M.isEqualWith=z3,M.isError=jf,M.isFinite=H3,M.isFunction=pn,M.isInteger=x1,M.isLength=ou,M.isMap=w1,M.isMatch=U3,M.isMatchWith=V3,M.isNaN=W3,M.isNative=G3,M.isNil=Y3,M.isNull=K3,M.isNumber=_1,M.isObject=ft,M.isObjectLike=dt,M.isPlainObject=Xo,M.isRegExp=qf,M.isSafeInteger=X3,M.isSet=E1,M.isString=au,M.isSymbol=rr,M.isTypedArray=Vi,M.isUndefined=Z3,M.isWeakMap=J3,M.isWeakSet=Q3,M.join=r$,M.kebabCase=z5,M.last=mr,M.lastIndexOf=n$,M.lowerCase=H5,M.lowerFirst=U5,M.lt=e5,M.lte=t5,M.max=Lz,M.maxBy=Bz,M.mean=Fz,M.meanBy=$z,M.min=zz,M.minBy=Hz,M.stubArray=Uf,M.stubFalse=Vf,M.stubObject=Iz,M.stubString=Pz,M.stubTrue=Nz,M.multiply=Uz,M.nth=i$,M.noConflict=xz,M.noop=Hf,M.now=ru,M.pad=V5,M.padEnd=W5,M.padStart=G5,M.parseInt=K5,M.random=k5,M.reduce=s3,M.reduceRight=u3,M.repeat=Y5,M.replace=X5,M.result=R5,M.round=Vz,M.runInContext=te,M.sample=l3,M.size=h3,M.snakeCase=Z5,M.some=p3,M.sortedIndex=f$,M.sortedIndexBy=d$,M.sortedIndexOf=h$,M.sortedLastIndex=p$,M.sortedLastIndexBy=v$,M.sortedLastIndexOf=g$,M.startCase=Q5,M.startsWith=ez,M.subtract=Wz,M.sum=Gz,M.sumBy=Kz,M.template=tz,M.times=Tz,M.toFinite=vn,M.toInteger=De,M.toLength=O1,M.toLower=rz,M.toNumber=yr,M.toSafeInteger=r5,M.toString=Ge,M.toUpper=nz,M.trim=iz,M.trimEnd=oz,M.trimStart=az,M.truncate=sz,M.unescape=uz,M.uniqueId=Mz,M.upperCase=cz,M.upperFirst=Bf,M.each=f1,M.eachRight=d1,M.first=s1,zf(M,(function(){var s={};return Vr(M,function(l,g){Ze.call(M.prototype,g)||(s[g]=l)}),s})(),{chain:!1}),M.VERSION=n,dr(["bind","bindKey","curry","curryRight","partial","partialRight"],function(s){M[s].placeholder=M}),dr(["drop","take"],function(s,l){Fe.prototype[s]=function(g){g=g===r?1:_t(De(g),0);var O=this.__filtered__&&!l?new Fe(this):this.clone();return O.__filtered__?O.__takeCount__=At(g,O.__takeCount__):O.__views__.push({size:At(g,Q),type:s+(O.__dir__<0?"Right":"")}),O},Fe.prototype[s+"Right"]=function(g){return this.reverse()[s](g).reverse()}}),dr(["filter","map","takeWhile"],function(s,l){var g=l+1,O=g==T||g==$;Fe.prototype[s]=function(P){var q=this.clone();return q.__iteratees__.push({iteratee:Re(P,3),type:g}),q.__filtered__=q.__filtered__||O,q}}),dr(["head","last"],function(s,l){var g="take"+(l?"Right":"");Fe.prototype[s]=function(){return this[g](1).value()[0]}}),dr(["initial","tail"],function(s,l){var g="drop"+(l?"":"Right");Fe.prototype[s]=function(){return this.__filtered__?new Fe(this):this[g](1)}}),Fe.prototype.compact=function(){return this.filter(Vt)},Fe.prototype.find=function(s){return this.filter(s).head()},Fe.prototype.findLast=function(s){return this.reverse().find(s)},Fe.prototype.invokeMap=ke(function(s,l){return typeof s=="function"?new Fe(this):this.map(function(g){return Uo(g,s,l)})}),Fe.prototype.reject=function(s){return this.filter(iu(Re(s)))},Fe.prototype.slice=function(s,l){s=De(s);var g=this;return g.__filtered__&&(s>0||l<0)?new Fe(g):(s<0?g=g.takeRight(-s):s&&(g=g.drop(s)),l!==r&&(l=De(l),g=l<0?g.dropRight(-l):g.take(l-s)),g)},Fe.prototype.takeRightWhile=function(s){return this.reverse().takeWhile(s).reverse()},Fe.prototype.toArray=function(){return this.take(Q)},Vr(Fe.prototype,function(s,l){var g=/^(?:filter|find|map|reject)|While$/.test(l),O=/^(?:head|last)$/.test(l),P=M[O?"take"+(l=="last"?"Right":""):l],q=O||/^find/.test(l);P&&(M.prototype[l]=function(){var U=this.__wrapped__,X=O?[1]:arguments,re=U instanceof Fe,pe=X[0],ge=re||Me(U),me=function(Le){var $e=P.apply(M,In([Le],X));return O&&be?$e[0]:$e};ge&&g&&typeof pe=="function"&&pe.length!=1&&(re=ge=!1);var be=this.__chain__,Ce=!!this.__actions__.length,Ie=q&&!be,je=re&&!Ce;if(!q&&ge){U=je?U:new Fe(this);var Pe=s.apply(U,X);return Pe.__actions__.push({func:eu,args:[me],thisArg:r}),new pr(Pe,be)}return Ie&&je?s.apply(this,X):(Pe=this.thru(me),Ie?O?Pe.value()[0]:Pe.value():Pe)})}),dr(["pop","push","shift","sort","splice","unshift"],function(s){var l=Cs[s],g=/^(?:push|sort|unshift)$/.test(s)?"tap":"thru",O=/^(?:pop|shift)$/.test(s);M.prototype[s]=function(){var P=arguments;if(O&&!this.__chain__){var q=this.value();return l.apply(Me(q)?q:[],P)}return this[g](function(U){return l.apply(Me(U)?U:[],P)})}}),Vr(Fe.prototype,function(s,l){var g=M[l];if(g){var O=g.name+"";Ze.call(Fi,O)||(Fi[O]=[]),Fi[O].push({name:l,func:g})}}),Fi[Gs(r,b).name]=[{name:"wrapper",func:r}],Fe.prototype.clone=uB,Fe.prototype.reverse=cB,Fe.prototype.value=lB,M.prototype.at=B$,M.prototype.chain=F$,M.prototype.commit=$$,M.prototype.next=z$,M.prototype.plant=U$,M.prototype.reverse=V$,M.prototype.toJSON=M.prototype.valueOf=M.prototype.value=W$,M.prototype.first=M.prototype.head,ko&&(M.prototype[ko]=H$),M}),ki=$L();Zn?((Zn.exports=ki)._=ki,Fl._=ki):Rt._=ki}).call(sZ)})(Sa,Sa.exports)),Sa.exports}var vc=uZ(),xN={},na,wN;function bt(){if(wN)return na;wN=1;var e=function(t){return t&&t.Math===Math&&t};return na=e(typeof globalThis=="object"&&globalThis)||e(typeof window=="object"&&window)||e(typeof self=="object"&&self)||e(typeof ht=="object"&&ht)||e(typeof na=="object"&&na)||(function(){return this})()||Function("return this")(),na}var Fm={},$m,_N;function at(){return _N||(_N=1,$m=function(e){try{return!!e()}catch{return!0}}),$m}var zm,EN;function zr(){if(EN)return zm;EN=1;var e=at();return zm=!e(function(){return Object.defineProperty({},1,{get:function(){return 7}})[1]!==7}),zm}var Hm,SN;function tl(){if(SN)return Hm;SN=1;var e=at();return Hm=!e(function(){var t=(function(){}).bind();return typeof t!="function"||t.hasOwnProperty("prototype")}),Hm}var Um,ON;function Zt(){if(ON)return Um;ON=1;var e=tl(),t=Function.prototype.call;return Um=e?t.bind(t):function(){return t.apply(t,arguments)},Um}var Vm={},CN;function tk(){if(CN)return Vm;CN=1;var e={}.propertyIsEnumerable,t=Object.getOwnPropertyDescriptor,r=t&&!e.call({1:2},1);return Vm.f=r?function(i){var o=t(this,i);return!!o&&o.enumerable}:e,Vm}var Wm,RN;function aw(){return RN||(RN=1,Wm=function(e,t){return{enumerable:!(e&1),configurable:!(e&2),writable:!(e&4),value:t}}),Wm}var Gm,IN;function it(){if(IN)return Gm;IN=1;var e=tl(),t=Function.prototype,r=t.call,n=e&&t.bind.bind(r,r);return Gm=e?n:function(i){return function(){return r.apply(i,arguments)}},Gm}var Km,PN;function Gn(){if(PN)return Km;PN=1;var e=it(),t=e({}.toString),r=e("".slice);return Km=function(n){return r(t(n),8,-1)},Km}var Ym,NN;function rl(){if(NN)return Ym;NN=1;var e=it(),t=at(),r=Gn(),n=Object,i=e("".split);return Ym=t(function(){return!n("z").propertyIsEnumerable(0)})?function(o){return r(o)==="String"?i(o,""):n(o)}:n,Ym}var Xm,TN;function Xa(){return TN||(TN=1,Xm=function(e){return e==null}),Xm}var Zm,AN;function Ci(){if(AN)return Zm;AN=1;var e=Xa(),t=TypeError;return Zm=function(r){if(e(r))throw new t("Can't call method on "+r);return r},Zm}var Jm,MN;function Ro(){if(MN)return Jm;MN=1;var e=rl(),t=Ci();return Jm=function(r){return e(t(r))},Jm}var Qm,DN;function Et(){if(DN)return Qm;DN=1;var e=typeof document=="object"&&document.all;return Qm=typeof e>"u"&&e!==void 0?function(t){return typeof t=="function"||t===e}:function(t){return typeof t=="function"},Qm}var ey,jN;function Nt(){if(jN)return ey;jN=1;var e=Et();return ey=function(t){return typeof t=="object"?t!==null:e(t)},ey}var ty,qN;function nl(){if(qN)return ty;qN=1;var e=bt(),t=Et(),r=function(n){return t(n)?n:void 0};return ty=function(n,i){return arguments.length<2?r(e[n]):e[n]&&e[n][i]},ty}var ry,kN;function il(){if(kN)return ry;kN=1;var e=it();return ry=e({}.isPrototypeOf),ry}var ny,LN;function rk(){if(LN)return ny;LN=1;var e=bt(),t=e.navigator,r=t&&t.userAgent;return ny=r?String(r):"",ny}var iy,BN;function sw(){if(BN)return iy;BN=1;var e=bt(),t=rk(),r=e.process,n=e.Deno,i=r&&r.versions||n&&n.version,o=i&&i.v8,a,u;return o&&(a=o.split("."),u=a[0]>0&&a[0]<4?1:+(a[0]+a[1])),!u&&t&&(a=t.match(/Edge\/(\d+)/),(!a||a[1]>=74)&&(a=t.match(/Chrome\/(\d+)/),a&&(u=+a[1]))),iy=u,iy}var oy,FN;function nk(){if(FN)return oy;FN=1;var e=sw(),t=at(),r=bt(),n=r.String;return oy=!!Object.getOwnPropertySymbols&&!t(function(){var i=Symbol("symbol detection");return!n(i)||!(Object(i)instanceof Symbol)||!Symbol.sham&&e&&e<41}),oy}var ay,$N;function ik(){if($N)return ay;$N=1;var e=nk();return ay=e&&!Symbol.sham&&typeof Symbol.iterator=="symbol",ay}var sy,zN;function ok(){if(zN)return sy;zN=1;var e=nl(),t=Et(),r=il(),n=ik(),i=Object;return sy=n?function(o){return typeof o=="symbol"}:function(o){var a=e("Symbol");return t(a)&&r(a.prototype,i(o))},sy}var uy,HN;function uw(){if(HN)return uy;HN=1;var e=String;return uy=function(t){try{return e(t)}catch{return"Object"}},uy}var cy,UN;function Za(){if(UN)return cy;UN=1;var e=Et(),t=uw(),r=TypeError;return cy=function(n){if(e(n))return n;throw new r(t(n)+" is not a function")},cy}var ly,VN;function Ja(){if(VN)return ly;VN=1;var e=Za(),t=Xa();return ly=function(r,n){var i=r[n];return t(i)?void 0:e(i)},ly}var fy,WN;function cZ(){if(WN)return fy;WN=1;var e=Zt(),t=Et(),r=Nt(),n=TypeError;return fy=function(i,o){var a,u;if(o==="string"&&t(a=i.toString)&&!r(u=e(a,i))||t(a=i.valueOf)&&!r(u=e(a,i))||o!=="string"&&t(a=i.toString)&&!r(u=e(a,i)))return u;throw new n("Can't convert object to primitive value")},fy}var dy={exports:{}},hy,GN;function ol(){return GN||(GN=1,hy=!1),hy}var py,KN;function cw(){if(KN)return py;KN=1;var e=bt(),t=Object.defineProperty;return py=function(r,n){try{t(e,r,{value:n,configurable:!0,writable:!0})}catch{e[r]=n}return n},py}var YN;function lw(){if(YN)return dy.exports;YN=1;var e=ol(),t=bt(),r=cw(),n="__core-js_shared__",i=dy.exports=t[n]||r(n,{});return(i.versions||(i.versions=[])).push({version:"3.45.1",mode:e?"pure":"global",copyright:"© 2014-2025 Denis Pushkarev (zloirock.ru)",license:"https://github.com/zloirock/core-js/blob/v3.45.1/LICENSE",source:"https://github.com/zloirock/core-js"}),dy.exports}var vy,XN;function fw(){if(XN)return vy;XN=1;var e=lw();return vy=function(t,r){return e[t]||(e[t]=r||{})},vy}var gy,ZN;function Io(){if(ZN)return gy;ZN=1;var e=Ci(),t=Object;return gy=function(r){return t(e(r))},gy}var my,JN;function Rr(){if(JN)return my;JN=1;var e=it(),t=Io(),r=e({}.hasOwnProperty);return my=Object.hasOwn||function(i,o){return r(t(i),o)},my}var yy,QN;function dw(){if(QN)return yy;QN=1;var e=it(),t=0,r=Math.random(),n=e(1.1.toString);return yy=function(i){return"Symbol("+(i===void 0?"":i)+")_"+n(++t+r,36)},yy}var by,eT;function $t(){if(eT)return by;eT=1;var e=bt(),t=fw(),r=Rr(),n=dw(),i=nk(),o=ik(),a=e.Symbol,u=t("wks"),c=o?a.for||a:a&&a.withoutSetter||n;return by=function(d){return r(u,d)||(u[d]=i&&r(a,d)?a[d]:c("Symbol."+d)),u[d]},by}var xy,tT;function lZ(){if(tT)return xy;tT=1;var e=Zt(),t=Nt(),r=ok(),n=Ja(),i=cZ(),o=$t(),a=TypeError,u=o("toPrimitive");return xy=function(c,d){if(!t(c)||r(c))return c;var f=n(c,u),h;if(f){if(d===void 0&&(d="default"),h=e(f,c,d),!t(h)||r(h))return h;throw new a("Can't convert object to primitive value")}return d===void 0&&(d="number"),i(c,d)},xy}var wy,rT;function ak(){if(rT)return wy;rT=1;var e=lZ(),t=ok();return wy=function(r){var n=e(r,"string");return t(n)?n:n+""},wy}var _y,nT;function hw(){if(nT)return _y;nT=1;var e=bt(),t=Nt(),r=e.document,n=t(r)&&t(r.createElement);return _y=function(i){return n?r.createElement(i):{}},_y}var Ey,iT;function sk(){if(iT)return Ey;iT=1;var e=zr(),t=at(),r=hw();return Ey=!e&&!t(function(){return Object.defineProperty(r("div"),"a",{get:function(){return 7}}).a!==7}),Ey}var oT;function uk(){if(oT)return Fm;oT=1;var e=zr(),t=Zt(),r=tk(),n=aw(),i=Ro(),o=ak(),a=Rr(),u=sk(),c=Object.getOwnPropertyDescriptor;return Fm.f=e?c:function(f,h){if(f=i(f),h=o(h),u)try{return c(f,h)}catch{}if(a(f,h))return n(!t(r.f,f,h),f[h])},Fm}var Sy={},Oy,aT;function ck(){if(aT)return Oy;aT=1;var e=zr(),t=at();return Oy=e&&t(function(){return Object.defineProperty(function(){},"prototype",{value:42,writable:!1}).prototype!==42}),Oy}var Cy,sT;function Ir(){if(sT)return Cy;sT=1;var e=Nt(),t=String,r=TypeError;return Cy=function(n){if(e(n))return n;throw new r(t(n)+" is not an object")},Cy}var uT;function On(){if(uT)return Sy;uT=1;var e=zr(),t=sk(),r=ck(),n=Ir(),i=ak(),o=TypeError,a=Object.defineProperty,u=Object.getOwnPropertyDescriptor,c="enumerable",d="configurable",f="writable";return Sy.f=e?r?function(p,v,m){if(n(p),v=i(v),n(m),typeof p=="function"&&v==="prototype"&&"value"in m&&f in m&&!m[f]){var y=u(p,v);y&&y[f]&&(p[v]=m.value,m={configurable:d in m?m[d]:y[d],enumerable:c in m?m[c]:y[c],writable:!1})}return a(p,v,m)}:a:function(p,v,m){if(n(p),v=i(v),n(m),t)try{return a(p,v,m)}catch{}if("get"in m||"set"in m)throw new o("Accessors not supported");return"value"in m&&(p[v]=m.value),p},Sy}var Ry,cT;function Qa(){if(cT)return Ry;cT=1;var e=zr(),t=On(),r=aw();return Ry=e?function(n,i,o){return t.f(n,i,r(1,o))}:function(n,i,o){return n[i]=o,n},Ry}var Iy={exports:{}},Py,lT;function pw(){if(lT)return Py;lT=1;var e=zr(),t=Rr(),r=Function.prototype,n=e&&Object.getOwnPropertyDescriptor,i=t(r,"name"),o=i&&(function(){}).name==="something",a=i&&(!e||e&&n(r,"name").configurable);return Py={EXISTS:i,PROPER:o,CONFIGURABLE:a},Py}var Ny,fT;function lk(){if(fT)return Ny;fT=1;var e=it(),t=Et(),r=lw(),n=e(Function.toString);return t(r.inspectSource)||(r.inspectSource=function(i){return n(i)}),Ny=r.inspectSource,Ny}var Ty,dT;function fk(){if(dT)return Ty;dT=1;var e=bt(),t=Et(),r=e.WeakMap;return Ty=t(r)&&/native code/.test(String(r)),Ty}var Ay,hT;function vw(){if(hT)return Ay;hT=1;var e=fw(),t=dw(),r=e("keys");return Ay=function(n){return r[n]||(r[n]=t(n))},Ay}var My,pT;function al(){return pT||(pT=1,My={}),My}var Dy,vT;function Po(){if(vT)return Dy;vT=1;var e=fk(),t=bt(),r=Nt(),n=Qa(),i=Rr(),o=lw(),a=vw(),u=al(),c="Object already initialized",d=t.TypeError,f=t.WeakMap,h,p,v,m=function(w){return v(w)?p(w):h(w,{})},y=function(w){return function(S){var E;if(!r(S)||(E=p(S)).type!==w)throw new d("Incompatible receiver, "+w+" required");return E}};if(e||o.state){var x=o.state||(o.state=new f);x.get=x.get,x.has=x.has,x.set=x.set,h=function(w,S){if(x.has(w))throw new d(c);return S.facade=w,x.set(w,S),S},p=function(w){return x.get(w)||{}},v=function(w){return x.has(w)}}else{var b=a("state");u[b]=!0,h=function(w,S){if(i(w,b))throw new d(c);return S.facade=w,n(w,b,S),S},p=function(w){return i(w,b)?w[b]:{}},v=function(w){return i(w,b)}}return Dy={set:h,get:p,has:v,enforce:m,getterFor:y},Dy}var gT;function dk(){if(gT)return Iy.exports;gT=1;var e=it(),t=at(),r=Et(),n=Rr(),i=zr(),o=pw().CONFIGURABLE,a=lk(),u=Po(),c=u.enforce,d=u.get,f=String,h=Object.defineProperty,p=e("".slice),v=e("".replace),m=e([].join),y=i&&!t(function(){return h(function(){},"length",{value:8}).length!==8}),x=String(String).split("String"),b=Iy.exports=function(w,S,E){p(f(S),0,7)==="Symbol("&&(S="["+v(f(S),/^Symbol\(([^)]*)\).*$/,"$1")+"]"),E&&E.getter&&(S="get "+S),E&&E.setter&&(S="set "+S),(!n(w,"name")||o&&w.name!==S)&&(i?h(w,"name",{value:S,configurable:!0}):w.name=S),y&&E&&n(E,"arity")&&w.length!==E.arity&&h(w,"length",{value:E.arity});try{E&&n(E,"constructor")&&E.constructor?i&&h(w,"prototype",{writable:!1}):w.prototype&&(w.prototype=void 0)}catch{}var _=c(w);return n(_,"source")||(_.source=m(x,typeof S=="string"?S:"")),w};return Function.prototype.toString=b(function(){return r(this)&&d(this).source||a(this)},"toString"),Iy.exports}var jy,mT;function Ri(){if(mT)return jy;mT=1;var e=Et(),t=On(),r=dk(),n=cw();return jy=function(i,o,a,u){u||(u={});var c=u.enumerable,d=u.name!==void 0?u.name:o;if(e(a)&&r(a,d,u),u.global)c?i[o]=a:n(o,a);else{try{u.unsafe?i[o]&&(c=!0):delete i[o]}catch{}c?i[o]=a:t.f(i,o,{value:a,enumerable:!1,configurable:!u.nonConfigurable,writable:!u.nonWritable})}return i},jy}var qy={},ky,yT;function fZ(){if(yT)return ky;yT=1;var e=Math.ceil,t=Math.floor;return ky=Math.trunc||function(n){var i=+n;return(i>0?t:e)(i)},ky}var Ly,bT;function sl(){if(bT)return Ly;bT=1;var e=fZ();return Ly=function(t){var r=+t;return r!==r||r===0?0:e(r)},Ly}var By,xT;function dZ(){if(xT)return By;xT=1;var e=sl(),t=Math.max,r=Math.min;return By=function(n,i){var o=e(n);return o<0?t(o+i,0):r(o,i)},By}var Fy,wT;function gw(){if(wT)return Fy;wT=1;var e=sl(),t=Math.min;return Fy=function(r){var n=e(r);return n>0?t(n,9007199254740991):0},Fy}var $y,_T;function ul(){if(_T)return $y;_T=1;var e=gw();return $y=function(t){return e(t.length)},$y}var zy,ET;function hZ(){if(ET)return zy;ET=1;var e=Ro(),t=dZ(),r=ul(),n=function(i){return function(o,a,u){var c=e(o),d=r(c);if(d===0)return!i&&-1;var f=t(u,d),h;if(i&&a!==a){for(;d>f;)if(h=c[f++],h!==h)return!0}else for(;d>f;f++)if((i||f in c)&&c[f]===a)return i||f||0;return!i&&-1}};return zy={includes:n(!0),indexOf:n(!1)},zy}var Hy,ST;function hk(){if(ST)return Hy;ST=1;var e=it(),t=Rr(),r=Ro(),n=hZ().indexOf,i=al(),o=e([].push);return Hy=function(a,u){var c=r(a),d=0,f=[],h;for(h in c)!t(i,h)&&t(c,h)&&o(f,h);for(;u.length>d;)t(c,h=u[d++])&&(~n(f,h)||o(f,h));return f},Hy}var Uy,OT;function mw(){return OT||(OT=1,Uy=["constructor","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","toLocaleString","toString","valueOf"]),Uy}var CT;function yw(){if(CT)return qy;CT=1;var e=hk(),t=mw(),r=t.concat("length","prototype");return qy.f=Object.getOwnPropertyNames||function(i){return e(i,r)},qy}var Vy={},RT;function pk(){return RT||(RT=1,Vy.f=Object.getOwnPropertySymbols),Vy}var Wy,IT;function pZ(){if(IT)return Wy;IT=1;var e=nl(),t=it(),r=yw(),n=pk(),i=Ir(),o=t([].concat);return Wy=e("Reflect","ownKeys")||function(u){var c=r.f(i(u)),d=n.f;return d?o(c,d(u)):c},Wy}var Gy,PT;function vZ(){if(PT)return Gy;PT=1;var e=Rr(),t=pZ(),r=uk(),n=On();return Gy=function(i,o,a){for(var u=t(o),c=n.f,d=r.f,f=0;f<u.length;f++){var h=u[f];!e(i,h)&&!(a&&e(a,h))&&c(i,h,d(o,h))}},Gy}var Ky,NT;function vk(){if(NT)return Ky;NT=1;var e=at(),t=Et(),r=/#|\.prototype\./,n=function(c,d){var f=o[i(c)];return f===u?!0:f===a?!1:t(d)?e(d):!!d},i=n.normalize=function(c){return String(c).replace(r,".").toLowerCase()},o=n.data={},a=n.NATIVE="N",u=n.POLYFILL="P";return Ky=n,Ky}var Yy,TT;function Kn(){if(TT)return Yy;TT=1;var e=bt(),t=uk().f,r=Qa(),n=Ri(),i=cw(),o=vZ(),a=vk();return Yy=function(u,c){var d=u.target,f=u.global,h=u.stat,p,v,m,y,x,b;if(f?v=e:h?v=e[d]||i(d,{}):v=e[d]&&e[d].prototype,v)for(m in c){if(x=c[m],u.dontCallGetSet?(b=t(v,m),y=b&&b.value):y=v[m],p=a(f?m:d+(h?".":"#")+m,u.forced),!p&&y!==void 0){if(typeof x==typeof y)continue;o(x,y)}(u.sham||y&&y.sham)&&r(x,"sham",!0),n(v,m,x,u)}},Yy}var Xy,AT;function bw(){if(AT)return Xy;AT=1;var e=$t(),t=e("toStringTag"),r={};return r[t]="z",Xy=String(r)==="[object z]",Xy}var Zy,MT;function cl(){if(MT)return Zy;MT=1;var e=bw(),t=Et(),r=Gn(),n=$t(),i=n("toStringTag"),o=Object,a=r((function(){return arguments})())==="Arguments",u=function(c,d){try{return c[d]}catch{}};return Zy=e?r:function(c){var d,f,h;return c===void 0?"Undefined":c===null?"Null":typeof(f=u(d=o(c),i))=="string"?f:a?r(d):(h=r(d))==="Object"&&t(d.callee)?"Arguments":h},Zy}var Jy,DT;function Ii(){if(DT)return Jy;DT=1;var e=cl(),t=String;return Jy=function(r){if(e(r)==="Symbol")throw new TypeError("Cannot convert a Symbol value to a string");return t(r)},Jy}var Qy,jT;function gk(){return jT||(jT=1,Qy=`
|
|
67
|
-
\v\f\r \u2028\u2029\uFEFF`),Qy}var e0,qT;function gZ(){if(qT)return e0;qT=1;var e=it(),t=Ci(),r=Ii(),n=gk(),i=e("".replace),o=RegExp("^["+n+"]+"),a=RegExp("(^|[^"+n+"])["+n+"]+$"),u=function(c){return function(d){var f=r(t(d));return c&1&&(f=i(f,o,"")),c&2&&(f=i(f,a,"$1")),f}};return e0={start:u(1),end:u(2),trim:u(3)},e0}var t0,kT;function mZ(){if(kT)return t0;kT=1;var e=bt(),t=at(),r=it(),n=Ii(),i=gZ().trim,o=gk(),a=e.parseInt,u=e.Symbol,c=u&&u.iterator,d=/^[+-]?0x/i,f=r(d.exec),h=a(o+"08")!==8||a(o+"0x16")!==22||c&&!t(function(){a(Object(c))});return t0=h?function(v,m){var y=i(n(v));return a(y,m>>>0||(f(d,y)?16:10))}:a,t0}var LT;function yZ(){if(LT)return xN;LT=1;var e=Kn(),t=mZ();return e({global:!0,forced:parseInt!==t},{parseInt:t}),xN}yZ();var BT={},r0,FT;function mk(){if(FT)return r0;FT=1;var e=hk(),t=mw();return r0=Object.keys||function(n){return e(n,t)},r0}var n0,$T;function bZ(){if($T)return n0;$T=1;var e=zr(),t=it(),r=Zt(),n=at(),i=mk(),o=pk(),a=tk(),u=Io(),c=rl(),d=Object.assign,f=Object.defineProperty,h=t([].concat);return n0=!d||n(function(){if(e&&d({b:1},d(f({},"a",{enumerable:!0,get:function(){f(this,"b",{value:3,enumerable:!1})}}),{b:2})).b!==1)return!0;var p={},v={},m=Symbol("assign detection"),y="abcdefghijklmnopqrst";return p[m]=7,y.split("").forEach(function(x){v[x]=x}),d({},p)[m]!==7||i(d({},v)).join("")!==y})?function(v,m){for(var y=u(v),x=arguments.length,b=1,w=o.f,S=a.f;x>b;)for(var E=c(arguments[b++]),_=w?h(i(E),w(E)):i(E),R=_.length,I=0,N;R>I;)N=_[I++],(!e||r(S,E,N))&&(y[N]=E[N]);return y}:d,n0}var zT;function xZ(){if(zT)return BT;zT=1;var e=Kn(),t=bZ();return e({target:"Object",stat:!0,arity:2,forced:Object.assign!==t},{assign:t}),BT}xZ();var HT={},i0,UT;function wZ(){if(UT)return i0;UT=1;var e=Gn(),t=it();return i0=function(r){if(e(r)==="Function")return t(r)},i0}var o0,VT;function yk(){if(VT)return o0;VT=1;var e=wZ(),t=Za(),r=tl(),n=e(e.bind);return o0=function(i,o){return t(i),o===void 0?i:r?n(i,o):function(){return i.apply(o,arguments)}},o0}var a0,WT;function _Z(){if(WT)return a0;WT=1;var e=Gn();return a0=Array.isArray||function(r){return e(r)==="Array"},a0}var s0,GT;function EZ(){if(GT)return s0;GT=1;var e=it(),t=at(),r=Et(),n=cl(),i=nl(),o=lk(),a=function(){},u=i("Reflect","construct"),c=/^\s*(?:class|function)\b/,d=e(c.exec),f=!c.test(a),h=function(m){if(!r(m))return!1;try{return u(a,[],m),!0}catch{return!1}},p=function(m){if(!r(m))return!1;switch(n(m)){case"AsyncFunction":case"GeneratorFunction":case"AsyncGeneratorFunction":return!1}try{return f||!!d(c,o(m))}catch{return!0}};return p.sham=!0,s0=!u||t(function(){var v;return h(h.call)||!h(Object)||!h(function(){v=!0})||v})?p:h,s0}var u0,KT;function SZ(){if(KT)return u0;KT=1;var e=_Z(),t=EZ(),r=Nt(),n=$t(),i=n("species"),o=Array;return u0=function(a){var u;return e(a)&&(u=a.constructor,t(u)&&(u===o||e(u.prototype))?u=void 0:r(u)&&(u=u[i],u===null&&(u=void 0))),u===void 0?o:u},u0}var c0,YT;function OZ(){if(YT)return c0;YT=1;var e=SZ();return c0=function(t,r){return new(e(t))(r===0?0:r)},c0}var l0,XT;function bk(){if(XT)return l0;XT=1;var e=yk(),t=it(),r=rl(),n=Io(),i=ul(),o=OZ(),a=t([].push),u=function(c){var d=c===1,f=c===2,h=c===3,p=c===4,v=c===6,m=c===7,y=c===5||v;return function(x,b,w,S){for(var E=n(x),_=r(E),R=i(_),I=e(b,w),N=0,D=S||o,k=d?D(x,R):f||m?D(x,0):void 0,B,L;R>N;N++)if((y||N in _)&&(B=_[N],L=I(B,N,E),c))if(d)k[N]=L;else if(L)switch(c){case 3:return!0;case 5:return B;case 6:return N;case 2:a(k,B)}else switch(c){case 4:return!1;case 7:a(k,B)}return v?-1:h||p?p:k}};return l0={forEach:u(0),map:u(1),filter:u(2),some:u(3),every:u(4),find:u(5),findIndex:u(6),filterReject:u(7)},l0}var f0,ZT;function CZ(){if(ZT)return f0;ZT=1;var e=at(),t=$t(),r=sw(),n=t("species");return f0=function(i){return r>=51||!e(function(){var o=[],a=o.constructor={};return a[n]=function(){return{foo:1}},o[i](Boolean).foo!==1})},f0}var JT;function RZ(){if(JT)return HT;JT=1;var e=Kn(),t=bk().filter,r=CZ(),n=r("filter");return e({target:"Array",proto:!0,forced:!n},{filter:function(o){return t(this,o,arguments.length>1?arguments[1]:void 0)}}),HT}RZ();var QT={},d0,eA;function IZ(){if(eA)return d0;eA=1;var e=bw(),t=cl();return d0=e?{}.toString:function(){return"[object "+t(this)+"]"},d0}var tA;function PZ(){if(tA)return QT;tA=1;var e=bw(),t=Ri(),r=IZ();return e||t(Object.prototype,"toString",r,{unsafe:!0}),QT}PZ();var h0={},rA;function NZ(){if(rA)return h0;rA=1;var e=zr(),t=ck(),r=On(),n=Ir(),i=Ro(),o=mk();return h0.f=e&&!t?Object.defineProperties:function(u,c){n(u);for(var d=i(c),f=o(c),h=f.length,p=0,v;h>p;)r.f(u,v=f[p++],d[v]);return u},h0}var p0,nA;function TZ(){if(nA)return p0;nA=1;var e=nl();return p0=e("document","documentElement"),p0}var v0,iA;function ll(){if(iA)return v0;iA=1;var e=Ir(),t=NZ(),r=mw(),n=al(),i=TZ(),o=hw(),a=vw(),u=">",c="<",d="prototype",f="script",h=a("IE_PROTO"),p=function(){},v=function(w){return c+f+u+w+c+"/"+f+u},m=function(w){w.write(v("")),w.close();var S=w.parentWindow.Object;return w=null,S},y=function(){var w=o("iframe"),S="java"+f+":",E;return w.style.display="none",i.appendChild(w),w.src=String(S),E=w.contentWindow.document,E.open(),E.write(v("document.F=Object")),E.close(),E.F},x,b=function(){try{x=new ActiveXObject("htmlfile")}catch{}b=typeof document<"u"?document.domain&&x?m(x):y():m(x);for(var w=r.length;w--;)delete b[d][r[w]];return b()};return n[h]=!0,v0=Object.create||function(S,E){var _;return S!==null?(p[d]=e(S),_=new p,p[d]=null,_[h]=S):_=b(),E===void 0?_:t.f(_,E)},v0}var g0,oA;function AZ(){if(oA)return g0;oA=1;var e=$t(),t=ll(),r=On().f,n=e("unscopables"),i=Array.prototype;return i[n]===void 0&&r(i,n,{configurable:!0,value:t(null)}),g0=function(o){i[n][o]=!0},g0}var m0,aA;function es(){return aA||(aA=1,m0={}),m0}var y0,sA;function MZ(){if(sA)return y0;sA=1;var e=at();return y0=!e(function(){function t(){}return t.prototype.constructor=null,Object.getPrototypeOf(new t)!==t.prototype}),y0}var b0,uA;function xk(){if(uA)return b0;uA=1;var e=Rr(),t=Et(),r=Io(),n=vw(),i=MZ(),o=n("IE_PROTO"),a=Object,u=a.prototype;return b0=i?a.getPrototypeOf:function(c){var d=r(c);if(e(d,o))return d[o];var f=d.constructor;return t(f)&&d instanceof f?f.prototype:d instanceof a?u:null},b0}var x0,cA;function wk(){if(cA)return x0;cA=1;var e=at(),t=Et(),r=Nt(),n=ll(),i=xk(),o=Ri(),a=$t(),u=ol(),c=a("iterator"),d=!1,f,h,p;[].keys&&(p=[].keys(),"next"in p?(h=i(i(p)),h!==Object.prototype&&(f=h)):d=!0);var v=!r(f)||e(function(){var m={};return f[c].call(m)!==m});return v?f={}:u&&(f=n(f)),t(f[c])||o(f,c,function(){return this}),x0={IteratorPrototype:f,BUGGY_SAFARI_ITERATORS:d},x0}var w0,lA;function fl(){if(lA)return w0;lA=1;var e=On().f,t=Rr(),r=$t(),n=r("toStringTag");return w0=function(i,o,a){i&&!a&&(i=i.prototype),i&&!t(i,n)&&e(i,n,{configurable:!0,value:o})},w0}var _0,fA;function DZ(){if(fA)return _0;fA=1;var e=wk().IteratorPrototype,t=ll(),r=aw(),n=fl(),i=es(),o=function(){return this};return _0=function(a,u,c,d){var f=u+" Iterator";return a.prototype=t(e,{next:r(+!d,c)}),n(a,f,!1,!0),i[f]=o,a},_0}var E0,dA;function jZ(){if(dA)return E0;dA=1;var e=it(),t=Za();return E0=function(r,n,i){try{return e(t(Object.getOwnPropertyDescriptor(r,n)[i]))}catch{}},E0}var S0,hA;function qZ(){if(hA)return S0;hA=1;var e=Nt();return S0=function(t){return e(t)||t===null},S0}var O0,pA;function kZ(){if(pA)return O0;pA=1;var e=qZ(),t=String,r=TypeError;return O0=function(n){if(e(n))return n;throw new r("Can't set "+t(n)+" as a prototype")},O0}var C0,vA;function _k(){if(vA)return C0;vA=1;var e=jZ(),t=Nt(),r=Ci(),n=kZ();return C0=Object.setPrototypeOf||("__proto__"in{}?(function(){var i=!1,o={},a;try{a=e(Object.prototype,"__proto__","set"),a(o,[]),i=o instanceof Array}catch{}return function(c,d){return r(c),n(d),t(c)&&(i?a(c,d):c.__proto__=d),c}})():void 0),C0}var R0,gA;function Ek(){if(gA)return R0;gA=1;var e=Kn(),t=Zt(),r=ol(),n=pw(),i=Et(),o=DZ(),a=xk(),u=_k(),c=fl(),d=Qa(),f=Ri(),h=$t(),p=es(),v=wk(),m=n.PROPER,y=n.CONFIGURABLE,x=v.IteratorPrototype,b=v.BUGGY_SAFARI_ITERATORS,w=h("iterator"),S="keys",E="values",_="entries",R=function(){return this};return R0=function(I,N,D,k,B,L,j){o(D,N,k);var T=function(z){if(z===B&&ee)return ee;if(!b&&z&&z in W)return W[z];switch(z){case S:return function(){return new D(this,z)};case E:return function(){return new D(this,z)};case _:return function(){return new D(this,z)}}return function(){return new D(this)}},F=N+" Iterator",$=!1,W=I.prototype,Y=W[w]||W["@@iterator"]||B&&W[B],ee=!b&&Y||T(B),H=N==="Array"&&W.entries||Y,Q,ce,se;if(H&&(Q=a(H.call(new I)),Q!==Object.prototype&&Q.next&&(!r&&a(Q)!==x&&(u?u(Q,x):i(Q[w])||f(Q,w,R)),c(Q,F,!0,!0),r&&(p[F]=R))),m&&B===E&&Y&&Y.name!==E&&(!r&&y?d(W,"name",E):($=!0,ee=function(){return t(Y,this)})),B)if(ce={values:T(E),keys:L?ee:T(S),entries:T(_)},j)for(se in ce)(b||$||!(se in W))&&f(W,se,ce[se]);else e({target:N,proto:!0,forced:b||$},ce);return(!r||j)&&W[w]!==ee&&f(W,w,ee,{name:B}),p[N]=ee,ce},R0}var I0,mA;function Sk(){return mA||(mA=1,I0=function(e,t){return{value:e,done:t}}),I0}var P0,yA;function Ok(){if(yA)return P0;yA=1;var e=Ro(),t=AZ(),r=es(),n=Po(),i=On().f,o=Ek(),a=Sk(),u=ol(),c=zr(),d="Array Iterator",f=n.set,h=n.getterFor(d);P0=o(Array,"Array",function(v,m){f(this,{type:d,target:e(v),index:0,kind:m})},function(){var v=h(this),m=v.target,y=v.index++;if(!m||y>=m.length)return v.target=null,a(void 0,!0);switch(v.kind){case"keys":return a(y,!1);case"values":return a(m[y],!1)}return a([y,m[y]],!1)},"values");var p=r.Arguments=r.Array;if(t("keys"),t("values"),t("entries"),!u&&c&&p.name!=="values")try{i(p,"name",{value:"values"})}catch{}return P0}Ok();var bA={},N0,xA;function Ck(){if(xA)return N0;xA=1;var e=it(),t=sl(),r=Ii(),n=Ci(),i=e("".charAt),o=e("".charCodeAt),a=e("".slice),u=function(c){return function(d,f){var h=r(n(d)),p=t(f),v=h.length,m,y;return p<0||p>=v?c?"":void 0:(m=o(h,p),m<55296||m>56319||p+1===v||(y=o(h,p+1))<56320||y>57343?c?i(h,p):m:c?a(h,p,p+2):(m-55296<<10)+(y-56320)+65536)}};return N0={codeAt:u(!1),charAt:u(!0)},N0}var wA;function LZ(){if(wA)return bA;wA=1;var e=Ck().charAt,t=Ii(),r=Po(),n=Ek(),i=Sk(),o="String Iterator",a=r.set,u=r.getterFor(o);return n(String,"String",function(c){a(this,{type:o,string:t(c),index:0})},function(){var d=u(this),f=d.string,h=d.index,p;return h>=f.length?i(void 0,!0):(p=e(f,h),d.index+=p.length,i(p,!1))}),bA}LZ();var _A={},EA={},T0,SA;function Rk(){if(SA)return T0;SA=1;var e=at();return T0=!e(function(){return Object.isExtensible(Object.preventExtensions({}))}),T0}var A0,OA;function Ik(){if(OA)return A0;OA=1;var e=Ri();return A0=function(t,r,n){for(var i in r)e(t,i,r[i],n);return t},A0}var M0={exports:{}},D0={},j0,CA;function BZ(){if(CA)return j0;CA=1;var e=it();return j0=e([].slice),j0}var RA;function FZ(){if(RA)return D0;RA=1;var e=Gn(),t=Ro(),r=yw().f,n=BZ(),i=typeof window=="object"&&window&&Object.getOwnPropertyNames?Object.getOwnPropertyNames(window):[],o=function(a){try{return r(a)}catch{return n(i)}};return D0.f=function(u){return i&&e(u)==="Window"?o(u):r(t(u))},D0}var q0,IA;function $Z(){if(IA)return q0;IA=1;var e=at();return q0=e(function(){if(typeof ArrayBuffer=="function"){var t=new ArrayBuffer(8);Object.isExtensible(t)&&Object.defineProperty(t,"a",{value:8})}}),q0}var k0,PA;function zZ(){if(PA)return k0;PA=1;var e=at(),t=Nt(),r=Gn(),n=$Z(),i=Object.isExtensible,o=e(function(){});return k0=o||n?function(u){return!t(u)||n&&r(u)==="ArrayBuffer"?!1:i?i(u):!0}:i,k0}var NA;function xw(){if(NA)return M0.exports;NA=1;var e=Kn(),t=it(),r=al(),n=Nt(),i=Rr(),o=On().f,a=yw(),u=FZ(),c=zZ(),d=dw(),f=Rk(),h=!1,p=d("meta"),v=0,m=function(E){o(E,p,{value:{objectID:"O"+v++,weakData:{}}})},y=function(E,_){if(!n(E))return typeof E=="symbol"?E:(typeof E=="string"?"S":"P")+E;if(!i(E,p)){if(!c(E))return"F";if(!_)return"E";m(E)}return E[p].objectID},x=function(E,_){if(!i(E,p)){if(!c(E))return!0;if(!_)return!1;m(E)}return E[p].weakData},b=function(E){return f&&h&&c(E)&&!i(E,p)&&m(E),E},w=function(){S.enable=function(){},h=!0;var E=a.f,_=t([].splice),R={};R[p]=1,E(R).length&&(a.f=function(I){for(var N=E(I),D=0,k=N.length;D<k;D++)if(N[D]===p){_(N,D,1);break}return N},e({target:"Object",stat:!0,forced:!0},{getOwnPropertyNames:u.f}))},S=M0.exports={enable:w,fastKey:y,getWeakData:x,onFreeze:b};return r[p]=!0,M0.exports}var L0,TA;function HZ(){if(TA)return L0;TA=1;var e=$t(),t=es(),r=e("iterator"),n=Array.prototype;return L0=function(i){return i!==void 0&&(t.Array===i||n[r]===i)},L0}var B0,AA;function Pk(){if(AA)return B0;AA=1;var e=cl(),t=Ja(),r=Xa(),n=es(),i=$t(),o=i("iterator");return B0=function(a){if(!r(a))return t(a,o)||t(a,"@@iterator")||n[e(a)]},B0}var F0,MA;function UZ(){if(MA)return F0;MA=1;var e=Zt(),t=Za(),r=Ir(),n=uw(),i=Pk(),o=TypeError;return F0=function(a,u){var c=arguments.length<2?i(a):u;if(t(c))return r(e(c,a));throw new o(n(a)+" is not iterable")},F0}var $0,DA;function VZ(){if(DA)return $0;DA=1;var e=Zt(),t=Ir(),r=Ja();return $0=function(n,i,o){var a,u;t(n);try{if(a=r(n,"return"),!a){if(i==="throw")throw o;return o}a=e(a,n)}catch(c){u=!0,a=c}if(i==="throw")throw o;if(u)throw a;return t(a),o},$0}var z0,jA;function Nk(){if(jA)return z0;jA=1;var e=yk(),t=Zt(),r=Ir(),n=uw(),i=HZ(),o=ul(),a=il(),u=UZ(),c=Pk(),d=VZ(),f=TypeError,h=function(v,m){this.stopped=v,this.result=m},p=h.prototype;return z0=function(v,m,y){var x=y&&y.that,b=!!(y&&y.AS_ENTRIES),w=!!(y&&y.IS_RECORD),S=!!(y&&y.IS_ITERATOR),E=!!(y&&y.INTERRUPTED),_=e(m,x),R,I,N,D,k,B,L,j=function(F){return R&&d(R,"normal"),new h(!0,F)},T=function(F){return b?(r(F),E?_(F[0],F[1],j):_(F[0],F[1])):E?_(F,j):_(F)};if(w)R=v.iterator;else if(S)R=v;else{if(I=c(v),!I)throw new f(n(v)+" is not iterable");if(i(I)){for(N=0,D=o(v);D>N;N++)if(k=T(v[N]),k&&a(p,k))return k;return new h(!1)}R=u(v,I)}for(B=w?v.next:R.next;!(L=t(B,R)).done;){try{k=T(L.value)}catch(F){d(R,"throw",F)}if(typeof k=="object"&&k&&a(p,k))return k}return new h(!1)},z0}var H0,qA;function Tk(){if(qA)return H0;qA=1;var e=il(),t=TypeError;return H0=function(r,n){if(e(n,r))return r;throw new t("Incorrect invocation")},H0}var U0,kA;function WZ(){if(kA)return U0;kA=1;var e=$t(),t=e("iterator"),r=!1;try{var n=0,i={next:function(){return{done:!!n++}},return:function(){r=!0}};i[t]=function(){return this},Array.from(i,function(){throw 2})}catch{}return U0=function(o,a){try{if(!a&&!r)return!1}catch{return!1}var u=!1;try{var c={};c[t]=function(){return{next:function(){return{done:u=!0}}}},o(c)}catch{}return u},U0}var V0,LA;function GZ(){if(LA)return V0;LA=1;var e=Et(),t=Nt(),r=_k();return V0=function(n,i,o){var a,u;return r&&e(a=i.constructor)&&a!==o&&t(u=a.prototype)&&u!==o.prototype&&r(n,u),n},V0}var W0,BA;function KZ(){if(BA)return W0;BA=1;var e=Kn(),t=bt(),r=it(),n=vk(),i=Ri(),o=xw(),a=Nk(),u=Tk(),c=Et(),d=Xa(),f=Nt(),h=at(),p=WZ(),v=fl(),m=GZ();return W0=function(y,x,b){var w=y.indexOf("Map")!==-1,S=y.indexOf("Weak")!==-1,E=w?"set":"add",_=t[y],R=_&&_.prototype,I=_,N={},D=function($){var W=r(R[$]);i(R,$,$==="add"?function(ee){return W(this,ee===0?0:ee),this}:$==="delete"?function(Y){return S&&!f(Y)?!1:W(this,Y===0?0:Y)}:$==="get"?function(ee){return S&&!f(ee)?void 0:W(this,ee===0?0:ee)}:$==="has"?function(ee){return S&&!f(ee)?!1:W(this,ee===0?0:ee)}:function(ee,H){return W(this,ee===0?0:ee,H),this})},k=n(y,!c(_)||!(S||R.forEach&&!h(function(){new _().entries().next()})));if(k)I=b.getConstructor(x,y,w,E),o.enable();else if(n(y,!0)){var B=new I,L=B[E](S?{}:-0,1)!==B,j=h(function(){B.has(1)}),T=p(function($){new _($)}),F=!S&&h(function(){for(var $=new _,W=5;W--;)$[E](W,W);return!$.has(-0)});T||(I=x(function($,W){u($,R);var Y=m(new _,$,I);return d(W)||a(W,Y[E],{that:Y,AS_ENTRIES:w}),Y}),I.prototype=R,R.constructor=I),(j||F)&&(D("delete"),D("has"),w&&D("get")),(F||L)&&D(E),S&&R.clear&&delete R.clear}return N[y]=I,e({global:!0,constructor:!0,forced:I!==_},N),v(I,y),S||b.setStrong(I,y,w),I},W0}var G0,FA;function YZ(){if(FA)return G0;FA=1;var e=it(),t=Ik(),r=xw().getWeakData,n=Tk(),i=Ir(),o=Xa(),a=Nt(),u=Nk(),c=bk(),d=Rr(),f=Po(),h=f.set,p=f.getterFor,v=c.find,m=c.findIndex,y=e([].splice),x=0,b=function(E){return E.frozen||(E.frozen=new w)},w=function(){this.entries=[]},S=function(E,_){return v(E.entries,function(R){return R[0]===_})};return w.prototype={get:function(E){var _=S(this,E);if(_)return _[1]},has:function(E){return!!S(this,E)},set:function(E,_){var R=S(this,E);R?R[1]=_:this.entries.push([E,_])},delete:function(E){var _=m(this.entries,function(R){return R[0]===E});return~_&&y(this.entries,_,1),!!~_}},G0={getConstructor:function(E,_,R,I){var N=E(function(L,j){n(L,D),h(L,{type:_,id:x++,frozen:null}),o(j)||u(j,L[I],{that:L,AS_ENTRIES:R})}),D=N.prototype,k=p(_),B=function(L,j,T){var F=k(L),$=r(i(j),!0);return $===!0?b(F).set(j,T):$[F.id]=T,L};return t(D,{delete:function(L){var j=k(this);if(!a(L))return!1;var T=r(L);return T===!0?b(j).delete(L):T&&d(T,j.id)&&delete T[j.id]},has:function(j){var T=k(this);if(!a(j))return!1;var F=r(j);return F===!0?b(T).has(j):F&&d(F,T.id)}}),t(D,R?{get:function(j){var T=k(this);if(a(j)){var F=r(j);if(F===!0)return b(T).get(j);if(F)return F[T.id]}},set:function(j,T){return B(this,j,T)}}:{add:function(j){return B(this,j,!0)}}),N}},G0}var $A;function XZ(){if($A)return EA;$A=1;var e=Rk(),t=bt(),r=it(),n=Ik(),i=xw(),o=KZ(),a=YZ(),u=Nt(),c=Po().enforce,d=at(),f=fk(),h=Object,p=Array.isArray,v=h.isExtensible,m=h.isFrozen,y=h.isSealed,x=h.freeze,b=h.seal,w=!t.ActiveXObject&&"ActiveXObject"in t,S,E=function(L){return function(){return L(this,arguments.length?arguments[0]:void 0)}},_=o("WeakMap",E,a),R=_.prototype,I=r(R.set),N=function(){return e&&d(function(){var L=x([]);return I(new _,L,1),!m(L)})};if(f)if(w){S=a.getConstructor(E,"WeakMap",!0),i.enable();var D=r(R.delete),k=r(R.has),B=r(R.get);n(R,{delete:function(L){if(u(L)&&!v(L)){var j=c(this);return j.frozen||(j.frozen=new S),D(this,L)||j.frozen.delete(L)}return D(this,L)},has:function(j){if(u(j)&&!v(j)){var T=c(this);return T.frozen||(T.frozen=new S),k(this,j)||T.frozen.has(j)}return k(this,j)},get:function(j){if(u(j)&&!v(j)){var T=c(this);return T.frozen||(T.frozen=new S),k(this,j)?B(this,j):T.frozen.get(j)}return B(this,j)},set:function(j,T){if(u(j)&&!v(j)){var F=c(this);F.frozen||(F.frozen=new S),k(this,j)?I(this,j,T):F.frozen.set(j,T)}else I(this,j,T);return this}})}else N()&&n(R,{set:function(j,T){var F;return p(j)&&(m(j)?F=x:y(j)&&(F=b)),I(this,j,T),F&&F(j),this}});return EA}var zA;function ZZ(){return zA||(zA=1,XZ()),_A}ZZ();var HA={},K0,UA;function JZ(){return UA||(UA=1,K0={CSSRuleList:0,CSSStyleDeclaration:0,CSSValueList:0,ClientRectList:0,DOMRectList:0,DOMStringList:0,DOMTokenList:1,DataTransferItemList:0,FileList:0,HTMLAllCollection:0,HTMLCollection:0,HTMLFormElement:0,HTMLSelectElement:0,MediaList:0,MimeTypeArray:0,NamedNodeMap:0,NodeList:1,PaintRequestList:0,Plugin:0,PluginArray:0,SVGLengthList:0,SVGNumberList:0,SVGPathSegList:0,SVGPointList:0,SVGStringList:0,SVGTransformList:0,SourceBufferList:0,StyleSheetList:0,TextTrackCueList:0,TextTrackList:0,TouchList:0}),K0}var Y0,VA;function QZ(){if(VA)return Y0;VA=1;var e=hw(),t=e("span").classList,r=t&&t.constructor&&t.constructor.prototype;return Y0=r===Object.prototype?void 0:r,Y0}var WA;function eJ(){if(WA)return HA;WA=1;var e=bt(),t=JZ(),r=QZ(),n=Ok(),i=Qa(),o=fl(),a=$t(),u=a("iterator"),c=n.values,d=function(h,p){if(h){if(h[u]!==c)try{i(h,u,c)}catch{h[u]=c}if(o(h,p,!0),t[p]){for(var v in n)if(h[v]!==n[v])try{i(h,v,n[v])}catch{h[v]=n[v]}}}};for(var f in t)d(e[f]&&e[f].prototype,f);return d(r,"DOMTokenList"),HA}eJ();var X0,GA;function tJ(){if(GA)return X0;GA=1;var e="Expected a function",t=NaN,r="[object Symbol]",n=/^\s+|\s+$/g,i=/^[-+]0x[0-9a-f]+$/i,o=/^0b[01]+$/i,a=/^0o[0-7]+$/i,u=parseInt,c=typeof ht=="object"&&ht&&ht.Object===Object&&ht,d=typeof self=="object"&&self&&self.Object===Object&&self,f=c||d||Function("return this")(),h=Object.prototype,p=h.toString,v=Math.max,m=Math.min,y=function(){return f.Date.now()};function x(R,I,N){var D,k,B,L,j,T,F=0,$=!1,W=!1,Y=!0;if(typeof R!="function")throw new TypeError(e);I=_(I)||0,w(N)&&($=!!N.leading,W="maxWait"in N,B=W?v(_(N.maxWait)||0,I):B,Y="trailing"in N?!!N.trailing:Y);function ee(K){var ie=D,ne=k;return D=k=void 0,F=K,L=R.apply(ne,ie),L}function H(K){return F=K,j=setTimeout(se,I),$?ee(K):L}function Q(K){var ie=K-T,ne=K-F,ue=I-ie;return W?m(ue,B-ne):ue}function ce(K){var ie=K-T,ne=K-F;return T===void 0||ie>=I||ie<0||W&&ne>=B}function se(){var K=y();if(ce(K))return z(K);j=setTimeout(se,Q(K))}function z(K){return j=void 0,Y&&D?ee(K):(D=k=void 0,L)}function G(){j!==void 0&&clearTimeout(j),F=0,D=T=k=j=void 0}function J(){return j===void 0?L:z(y())}function V(){var K=y(),ie=ce(K);if(D=arguments,k=this,T=K,ie){if(j===void 0)return H(T);if(W)return j=setTimeout(se,I),ee(T)}return j===void 0&&(j=setTimeout(se,I)),L}return V.cancel=G,V.flush=J,V}function b(R,I,N){var D=!0,k=!0;if(typeof R!="function")throw new TypeError(e);return w(N)&&(D="leading"in N?!!N.leading:D,k="trailing"in N?!!N.trailing:k),x(R,I,{leading:D,maxWait:I,trailing:k})}function w(R){var I=typeof R;return!!R&&(I=="object"||I=="function")}function S(R){return!!R&&typeof R=="object"}function E(R){return typeof R=="symbol"||S(R)&&p.call(R)==r}function _(R){if(typeof R=="number")return R;if(E(R))return t;if(w(R)){var I=typeof R.valueOf=="function"?R.valueOf():R;R=w(I)?I+"":I}if(typeof R!="string")return R===0?R:+R;R=R.replace(n,"");var N=o.test(R);return N||a.test(R)?u(R.slice(2),N?2:8):i.test(R)?t:+R}return X0=b,X0}var rJ=tJ();const KA=Un(rJ);var Z0,YA;function nJ(){if(YA)return Z0;YA=1;var e="Expected a function",t=NaN,r="[object Symbol]",n=/^\s+|\s+$/g,i=/^[-+]0x[0-9a-f]+$/i,o=/^0b[01]+$/i,a=/^0o[0-7]+$/i,u=parseInt,c=typeof ht=="object"&&ht&&ht.Object===Object&&ht,d=typeof self=="object"&&self&&self.Object===Object&&self,f=c||d||Function("return this")(),h=Object.prototype,p=h.toString,v=Math.max,m=Math.min,y=function(){return f.Date.now()};function x(_,R,I){var N,D,k,B,L,j,T=0,F=!1,$=!1,W=!0;if(typeof _!="function")throw new TypeError(e);R=E(R)||0,b(I)&&(F=!!I.leading,$="maxWait"in I,k=$?v(E(I.maxWait)||0,R):k,W="trailing"in I?!!I.trailing:W);function Y(V){var K=N,ie=D;return N=D=void 0,T=V,B=_.apply(ie,K),B}function ee(V){return T=V,L=setTimeout(ce,R),F?Y(V):B}function H(V){var K=V-j,ie=V-T,ne=R-K;return $?m(ne,k-ie):ne}function Q(V){var K=V-j,ie=V-T;return j===void 0||K>=R||K<0||$&&ie>=k}function ce(){var V=y();if(Q(V))return se(V);L=setTimeout(ce,H(V))}function se(V){return L=void 0,W&&N?Y(V):(N=D=void 0,B)}function z(){L!==void 0&&clearTimeout(L),T=0,N=j=D=L=void 0}function G(){return L===void 0?B:se(y())}function J(){var V=y(),K=Q(V);if(N=arguments,D=this,j=V,K){if(L===void 0)return ee(j);if($)return L=setTimeout(ce,R),Y(j)}return L===void 0&&(L=setTimeout(ce,R)),B}return J.cancel=z,J.flush=G,J}function b(_){var R=typeof _;return!!_&&(R=="object"||R=="function")}function w(_){return!!_&&typeof _=="object"}function S(_){return typeof _=="symbol"||w(_)&&p.call(_)==r}function E(_){if(typeof _=="number")return _;if(S(_))return t;if(b(_)){var R=typeof _.valueOf=="function"?_.valueOf():_;_=b(R)?R+"":R}if(typeof _!="string")return _===0?_:+_;_=_.replace(n,"");var I=o.test(_);return I||a.test(_)?u(_.slice(2),I?2:8):i.test(_)?t:+_}return Z0=x,Z0}var iJ=nJ();const XA=Un(iJ);var J0,ZA;function oJ(){if(ZA)return J0;ZA=1;var e="Expected a function",t="__lodash_hash_undefined__",r="[object Function]",n="[object GeneratorFunction]",i=/[\\^$.*+?()[\]{}|]/g,o=/^\[object .+?Constructor\]$/,a=typeof ht=="object"&&ht&&ht.Object===Object&&ht,u=typeof self=="object"&&self&&self.Object===Object&&self,c=a||u||Function("return this")();function d(he,ae){return he==null?void 0:he[ae]}function f(he){var ae=!1;if(he!=null&&typeof he.toString!="function")try{ae=!!(he+"")}catch{}return ae}var h=Array.prototype,p=Function.prototype,v=Object.prototype,m=c["__core-js_shared__"],y=(function(){var he=/[^.]+$/.exec(m&&m.keys&&m.keys.IE_PROTO||"");return he?"Symbol(src)_1."+he:""})(),x=p.toString,b=v.hasOwnProperty,w=v.toString,S=RegExp("^"+x.call(b).replace(i,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),E=h.splice,_=K(c,"Map"),R=K(Object,"create");function I(he){var ae=-1,Oe=he?he.length:0;for(this.clear();++ae<Oe;){var Ne=he[ae];this.set(Ne[0],Ne[1])}}function N(){this.__data__=R?R(null):{}}function D(he){return this.has(he)&&delete this.__data__[he]}function k(he){var ae=this.__data__;if(R){var Oe=ae[he];return Oe===t?void 0:Oe}return b.call(ae,he)?ae[he]:void 0}function B(he){var ae=this.__data__;return R?ae[he]!==void 0:b.call(ae,he)}function L(he,ae){var Oe=this.__data__;return Oe[he]=R&&ae===void 0?t:ae,this}I.prototype.clear=N,I.prototype.delete=D,I.prototype.get=k,I.prototype.has=B,I.prototype.set=L;function j(he){var ae=-1,Oe=he?he.length:0;for(this.clear();++ae<Oe;){var Ne=he[ae];this.set(Ne[0],Ne[1])}}function T(){this.__data__=[]}function F(he){var ae=this.__data__,Oe=G(ae,he);if(Oe<0)return!1;var Ne=ae.length-1;return Oe==Ne?ae.pop():E.call(ae,Oe,1),!0}function $(he){var ae=this.__data__,Oe=G(ae,he);return Oe<0?void 0:ae[Oe][1]}function W(he){return G(this.__data__,he)>-1}function Y(he,ae){var Oe=this.__data__,Ne=G(Oe,he);return Ne<0?Oe.push([he,ae]):Oe[Ne][1]=ae,this}j.prototype.clear=T,j.prototype.delete=F,j.prototype.get=$,j.prototype.has=W,j.prototype.set=Y;function ee(he){var ae=-1,Oe=he?he.length:0;for(this.clear();++ae<Oe;){var Ne=he[ae];this.set(Ne[0],Ne[1])}}function H(){this.__data__={hash:new I,map:new(_||j),string:new I}}function Q(he){return V(this,he).delete(he)}function ce(he){return V(this,he).get(he)}function se(he){return V(this,he).has(he)}function z(he,ae){return V(this,he).set(he,ae),this}ee.prototype.clear=H,ee.prototype.delete=Q,ee.prototype.get=ce,ee.prototype.has=se,ee.prototype.set=z;function G(he,ae){for(var Oe=he.length;Oe--;)if(we(he[Oe][0],ae))return Oe;return-1}function J(he){if(!_e(he)||ne(he))return!1;var ae=Se(he)||f(he)?S:o;return ae.test(ue(he))}function V(he,ae){var Oe=he.__data__;return ie(ae)?Oe[typeof ae=="string"?"string":"hash"]:Oe.map}function K(he,ae){var Oe=d(he,ae);return J(Oe)?Oe:void 0}function ie(he){var ae=typeof he;return ae=="string"||ae=="number"||ae=="symbol"||ae=="boolean"?he!=="__proto__":he===null}function ne(he){return!!y&&y in he}function ue(he){if(he!=null){try{return x.call(he)}catch{}try{return he+""}catch{}}return""}function de(he,ae){if(typeof he!="function"||ae&&typeof ae!="function")throw new TypeError(e);var Oe=function(){var Ne=arguments,He=ae?ae.apply(this,Ne):Ne[0],qe=Oe.cache;if(qe.has(He))return qe.get(He);var Xe=he.apply(this,Ne);return Oe.cache=qe.set(He,Xe),Xe};return Oe.cache=new(de.Cache||ee),Oe}de.Cache=ee;function we(he,ae){return he===ae||he!==he&&ae!==ae}function Se(he){var ae=_e(he)?w.call(he):"";return ae==r||ae==n}function _e(he){var ae=typeof he;return!!he&&(ae=="object"||ae=="function")}return J0=de,J0}var aJ=oJ();const sJ=Un(aJ);var hi=[],uJ=function(){return hi.some(function(e){return e.activeTargets.length>0})},cJ=function(){return hi.some(function(e){return e.skippedTargets.length>0})},JA="ResizeObserver loop completed with undelivered notifications.",lJ=function(){var e;typeof ErrorEvent=="function"?e=new ErrorEvent("error",{message:JA}):(e=document.createEvent("Event"),e.initEvent("error",!1,!1),e.message=JA),window.dispatchEvent(e)},Ba;(function(e){e.BORDER_BOX="border-box",e.CONTENT_BOX="content-box",e.DEVICE_PIXEL_CONTENT_BOX="device-pixel-content-box"})(Ba||(Ba={}));var pi=function(e){return Object.freeze(e)},fJ=(function(){function e(t,r){this.inlineSize=t,this.blockSize=r,pi(this)}return e})(),Ak=(function(){function e(t,r,n,i){return this.x=t,this.y=r,this.width=n,this.height=i,this.top=this.y,this.left=this.x,this.bottom=this.top+this.height,this.right=this.left+this.width,pi(this)}return e.prototype.toJSON=function(){var t=this,r=t.x,n=t.y,i=t.top,o=t.right,a=t.bottom,u=t.left,c=t.width,d=t.height;return{x:r,y:n,top:i,right:o,bottom:a,left:u,width:c,height:d}},e.fromRect=function(t){return new e(t.x,t.y,t.width,t.height)},e})(),ww=function(e){return e instanceof SVGElement&&"getBBox"in e},Mk=function(e){if(ww(e)){var t=e.getBBox(),r=t.width,n=t.height;return!r&&!n}var i=e,o=i.offsetWidth,a=i.offsetHeight;return!(o||a||e.getClientRects().length)},QA=function(e){var t;if(e instanceof Element)return!0;var r=(t=e==null?void 0:e.ownerDocument)===null||t===void 0?void 0:t.defaultView;return!!(r&&e instanceof r.Element)},dJ=function(e){switch(e.tagName){case"INPUT":if(e.type!=="image")break;case"VIDEO":case"AUDIO":case"EMBED":case"OBJECT":case"CANVAS":case"IFRAME":case"IMG":return!0}return!1},Pa=typeof window<"u"?window:{},Iu=new WeakMap,eM=/auto|scroll/,hJ=/^tb|vertical/,pJ=/msie|trident/i.test(Pa.navigator&&Pa.navigator.userAgent),Yr=function(e){return parseFloat(e||"0")},uo=function(e,t,r){return e===void 0&&(e=0),t===void 0&&(t=0),r===void 0&&(r=!1),new fJ((r?t:e)||0,(r?e:t)||0)},tM=pi({devicePixelContentBoxSize:uo(),borderBoxSize:uo(),contentBoxSize:uo(),contentRect:new Ak(0,0,0,0)}),Dk=function(e,t){if(t===void 0&&(t=!1),Iu.has(e)&&!t)return Iu.get(e);if(Mk(e))return Iu.set(e,tM),tM;var r=getComputedStyle(e),n=ww(e)&&e.ownerSVGElement&&e.getBBox(),i=!pJ&&r.boxSizing==="border-box",o=hJ.test(r.writingMode||""),a=!n&&eM.test(r.overflowY||""),u=!n&&eM.test(r.overflowX||""),c=n?0:Yr(r.paddingTop),d=n?0:Yr(r.paddingRight),f=n?0:Yr(r.paddingBottom),h=n?0:Yr(r.paddingLeft),p=n?0:Yr(r.borderTopWidth),v=n?0:Yr(r.borderRightWidth),m=n?0:Yr(r.borderBottomWidth),y=n?0:Yr(r.borderLeftWidth),x=h+d,b=c+f,w=y+v,S=p+m,E=u?e.offsetHeight-S-e.clientHeight:0,_=a?e.offsetWidth-w-e.clientWidth:0,R=i?x+w:0,I=i?b+S:0,N=n?n.width:Yr(r.width)-R-_,D=n?n.height:Yr(r.height)-I-E,k=N+x+_+w,B=D+b+E+S,L=pi({devicePixelContentBoxSize:uo(Math.round(N*devicePixelRatio),Math.round(D*devicePixelRatio),o),borderBoxSize:uo(k,B,o),contentBoxSize:uo(N,D,o),contentRect:new Ak(h,c,N,D)});return Iu.set(e,L),L},jk=function(e,t,r){var n=Dk(e,r),i=n.borderBoxSize,o=n.contentBoxSize,a=n.devicePixelContentBoxSize;switch(t){case Ba.DEVICE_PIXEL_CONTENT_BOX:return a;case Ba.BORDER_BOX:return i;default:return o}},vJ=(function(){function e(t){var r=Dk(t);this.target=t,this.contentRect=r.contentRect,this.borderBoxSize=pi([r.borderBoxSize]),this.contentBoxSize=pi([r.contentBoxSize]),this.devicePixelContentBoxSize=pi([r.devicePixelContentBoxSize])}return e})(),qk=function(e){if(Mk(e))return 1/0;for(var t=0,r=e.parentNode;r;)t+=1,r=r.parentNode;return t},gJ=function(){var e=1/0,t=[];hi.forEach(function(a){if(a.activeTargets.length!==0){var u=[];a.activeTargets.forEach(function(d){var f=new vJ(d.target),h=qk(d.target);u.push(f),d.lastReportedSize=jk(d.target,d.observedBox),h<e&&(e=h)}),t.push(function(){a.callback.call(a.observer,u,a.observer)}),a.activeTargets.splice(0,a.activeTargets.length)}});for(var r=0,n=t;r<n.length;r++){var i=n[r];i()}return e},rM=function(e){hi.forEach(function(r){r.activeTargets.splice(0,r.activeTargets.length),r.skippedTargets.splice(0,r.skippedTargets.length),r.observationTargets.forEach(function(i){i.isActive()&&(qk(i.target)>e?r.activeTargets.push(i):r.skippedTargets.push(i))})})},mJ=function(){var e=0;for(rM(e);uJ();)e=gJ(),rM(e);return cJ()&&lJ(),e>0},Q0,kk=[],yJ=function(){return kk.splice(0).forEach(function(e){return e()})},bJ=function(e){if(!Q0){var t=0,r=document.createTextNode(""),n={characterData:!0};new MutationObserver(function(){return yJ()}).observe(r,n),Q0=function(){r.textContent="".concat(t?t--:t++)}}kk.push(e),Q0()},xJ=function(e){bJ(function(){requestAnimationFrame(e)})},$u=0,wJ=function(){return!!$u},_J=250,EJ={attributes:!0,characterData:!0,childList:!0,subtree:!0},nM=["resize","load","transitionend","animationend","animationstart","animationiteration","keyup","keydown","mouseup","mousedown","mouseover","mouseout","blur","focus"],iM=function(e){return e===void 0&&(e=0),Date.now()+e},eb=!1,SJ=(function(){function e(){var t=this;this.stopped=!0,this.listener=function(){return t.schedule()}}return e.prototype.run=function(t){var r=this;if(t===void 0&&(t=_J),!eb){eb=!0;var n=iM(t);xJ(function(){var i=!1;try{i=mJ()}finally{if(eb=!1,t=n-iM(),!wJ())return;i?r.run(1e3):t>0?r.run(t):r.start()}})}},e.prototype.schedule=function(){this.stop(),this.run()},e.prototype.observe=function(){var t=this,r=function(){return t.observer&&t.observer.observe(document.body,EJ)};document.body?r():Pa.addEventListener("DOMContentLoaded",r)},e.prototype.start=function(){var t=this;this.stopped&&(this.stopped=!1,this.observer=new MutationObserver(this.listener),this.observe(),nM.forEach(function(r){return Pa.addEventListener(r,t.listener,!0)}))},e.prototype.stop=function(){var t=this;this.stopped||(this.observer&&this.observer.disconnect(),nM.forEach(function(r){return Pa.removeEventListener(r,t.listener,!0)}),this.stopped=!0)},e})(),Gb=new SJ,oM=function(e){!$u&&e>0&&Gb.start(),$u+=e,!$u&&Gb.stop()},OJ=function(e){return!ww(e)&&!dJ(e)&&getComputedStyle(e).display==="inline"},CJ=(function(){function e(t,r){this.target=t,this.observedBox=r||Ba.CONTENT_BOX,this.lastReportedSize={inlineSize:0,blockSize:0}}return e.prototype.isActive=function(){var t=jk(this.target,this.observedBox,!0);return OJ(this.target)&&(this.lastReportedSize=t),this.lastReportedSize.inlineSize!==t.inlineSize||this.lastReportedSize.blockSize!==t.blockSize},e})(),RJ=(function(){function e(t,r){this.activeTargets=[],this.skippedTargets=[],this.observationTargets=[],this.observer=t,this.callback=r}return e})(),Pu=new WeakMap,aM=function(e,t){for(var r=0;r<e.length;r+=1)if(e[r].target===t)return r;return-1},Nu=(function(){function e(){}return e.connect=function(t,r){var n=new RJ(t,r);Pu.set(t,n)},e.observe=function(t,r,n){var i=Pu.get(t),o=i.observationTargets.length===0;aM(i.observationTargets,r)<0&&(o&&hi.push(i),i.observationTargets.push(new CJ(r,n&&n.box)),oM(1),Gb.schedule())},e.unobserve=function(t,r){var n=Pu.get(t),i=aM(n.observationTargets,r),o=n.observationTargets.length===1;i>=0&&(o&&hi.splice(hi.indexOf(n),1),n.observationTargets.splice(i,1),oM(-1))},e.disconnect=function(t){var r=this,n=Pu.get(t);n.observationTargets.slice().forEach(function(i){return r.unobserve(t,i.target)}),n.activeTargets.splice(0,n.activeTargets.length)},e})(),IJ=(function(){function e(t){if(arguments.length===0)throw new TypeError("Failed to construct 'ResizeObserver': 1 argument required, but only 0 present.");if(typeof t!="function")throw new TypeError("Failed to construct 'ResizeObserver': The callback provided as parameter 1 is not a function.");Nu.connect(this,t)}return e.prototype.observe=function(t,r){if(arguments.length===0)throw new TypeError("Failed to execute 'observe' on 'ResizeObserver': 1 argument required, but only 0 present.");if(!QA(t))throw new TypeError("Failed to execute 'observe' on 'ResizeObserver': parameter 1 is not of type 'Element");Nu.observe(this,t,r)},e.prototype.unobserve=function(t){if(arguments.length===0)throw new TypeError("Failed to execute 'unobserve' on 'ResizeObserver': 1 argument required, but only 0 present.");if(!QA(t))throw new TypeError("Failed to execute 'unobserve' on 'ResizeObserver': parameter 1 is not of type 'Element");Nu.unobserve(this,t)},e.prototype.disconnect=function(){Nu.disconnect(this)},e.toString=function(){return"function ResizeObserver () { [polyfill code] }"},e})(),tb,sM;function PJ(){if(sM)return tb;sM=1;var e=!!(typeof window<"u"&&window.document&&window.document.createElement);return tb=e,tb}var NJ=PJ();const Lk=Un(NJ);var uM={},rb,cM;function TJ(){if(cM)return rb;cM=1;var e=Za(),t=Io(),r=rl(),n=ul(),i=TypeError,o="Reduce of empty array with no initial value",a=function(u){return function(c,d,f,h){var p=t(c),v=r(p),m=n(p);if(e(d),m===0&&f<2)throw new i(o);var y=u?m-1:0,x=u?-1:1;if(f<2)for(;;){if(y in v){h=v[y],y+=x;break}if(y+=x,u?y<0:m<=y)throw new i(o)}for(;u?y>=0:m>y;y+=x)y in v&&(h=d(h,v[y],y,p));return h}};return rb={left:a(!1),right:a(!0)},rb}var nb,lM;function AJ(){if(lM)return nb;lM=1;var e=at();return nb=function(t,r){var n=[][t];return!!n&&e(function(){n.call(null,r||function(){return 1},1)})},nb}var ib,fM;function MJ(){if(fM)return ib;fM=1;var e=bt(),t=rk(),r=Gn(),n=function(i){return t.slice(0,i.length)===i};return ib=(function(){return n("Bun/")?"BUN":n("Cloudflare-Workers")?"CLOUDFLARE":n("Deno/")?"DENO":n("Node.js/")?"NODE":e.Bun&&typeof Bun.version=="string"?"BUN":e.Deno&&typeof Deno.version=="object"?"DENO":r(e.process)==="process"?"NODE":e.window&&e.document?"BROWSER":"REST"})(),ib}var ob,dM;function DJ(){if(dM)return ob;dM=1;var e=MJ();return ob=e==="NODE",ob}var hM;function jJ(){if(hM)return uM;hM=1;var e=Kn(),t=TJ().left,r=AJ(),n=sw(),i=DJ(),o=!i&&n>79&&n<83,a=o||!r("reduce");return e({target:"Array",proto:!0,forced:a},{reduce:function(c){var d=arguments.length;return t(this,c,d,d>1?arguments[1]:void 0)}}),uM}jJ();var pM={},ab,vM;function Bk(){if(vM)return ab;vM=1;var e=Ir();return ab=function(){var t=e(this),r="";return t.hasIndices&&(r+="d"),t.global&&(r+="g"),t.ignoreCase&&(r+="i"),t.multiline&&(r+="m"),t.dotAll&&(r+="s"),t.unicode&&(r+="u"),t.unicodeSets&&(r+="v"),t.sticky&&(r+="y"),r},ab}var sb,gM;function qJ(){if(gM)return sb;gM=1;var e=at(),t=bt(),r=t.RegExp,n=e(function(){var a=r("a","y");return a.lastIndex=2,a.exec("abcd")!==null}),i=n||e(function(){return!r("a","y").sticky}),o=n||e(function(){var a=r("^r","gy");return a.lastIndex=2,a.exec("str")!==null});return sb={BROKEN_CARET:o,MISSED_STICKY:i,UNSUPPORTED_Y:n},sb}var ub,mM;function kJ(){if(mM)return ub;mM=1;var e=at(),t=bt(),r=t.RegExp;return ub=e(function(){var n=r(".","s");return!(n.dotAll&&n.test(`
|
|
68
|
-
`)&&n.flags==="s")}),ub}var cb,yM;function LJ(){if(yM)return cb;yM=1;var e=at(),t=bt(),r=t.RegExp;return cb=e(function(){var n=r("(?<a>b)","g");return n.exec("b").groups.a!=="b"||"b".replace(n,"$<a>c")!=="bc"}),cb}var lb,bM;function _w(){if(bM)return lb;bM=1;var e=Zt(),t=it(),r=Ii(),n=Bk(),i=qJ(),o=fw(),a=ll(),u=Po().get,c=kJ(),d=LJ(),f=o("native-string-replace",String.prototype.replace),h=RegExp.prototype.exec,p=h,v=t("".charAt),m=t("".indexOf),y=t("".replace),x=t("".slice),b=(function(){var _=/a/,R=/b*/g;return e(h,_,"a"),e(h,R,"a"),_.lastIndex!==0||R.lastIndex!==0})(),w=i.BROKEN_CARET,S=/()??/.exec("")[1]!==void 0,E=b||S||w||c||d;return E&&(p=function(R){var I=this,N=u(I),D=r(R),k=N.raw,B,L,j,T,F,$,W;if(k)return k.lastIndex=I.lastIndex,B=e(p,k,D),I.lastIndex=k.lastIndex,B;var Y=N.groups,ee=w&&I.sticky,H=e(n,I),Q=I.source,ce=0,se=D;if(ee&&(H=y(H,"y",""),m(H,"g")===-1&&(H+="g"),se=x(D,I.lastIndex),I.lastIndex>0&&(!I.multiline||I.multiline&&v(D,I.lastIndex-1)!==`
|
|
69
|
-
`)&&(Q="(?: "+Q+")",se=" "+se,ce++),L=new RegExp("^(?:"+Q+")",H)),S&&(L=new RegExp("^"+Q+"$(?!\\s)",H)),b&&(j=I.lastIndex),T=e(h,ee?L:I,se),ee?T?(T.input=x(T.input,ce),T[0]=x(T[0],ce),T.index=I.lastIndex,I.lastIndex+=T[0].length):I.lastIndex=0:b&&T&&(I.lastIndex=I.global?T.index+T[0].length:j),S&&T&&T.length>1&&e(f,T[0],L,function(){for(F=1;F<arguments.length-2;F++)arguments[F]===void 0&&(T[F]=void 0)}),T&&Y)for(T.groups=$=a(null),F=0;F<Y.length;F++)W=Y[F],$[W[0]]=T[W[1]];return T}),lb=p,lb}var xM;function Fk(){if(xM)return pM;xM=1;var e=Kn(),t=_w();return e({target:"RegExp",proto:!0,forced:/./.exec!==t},{exec:t}),pM}Fk();var wM={},fb,_M;function $k(){if(_M)return fb;_M=1,Fk();var e=Zt(),t=Ri(),r=_w(),n=at(),i=$t(),o=Qa(),a=i("species"),u=RegExp.prototype;return fb=function(c,d,f,h){var p=i(c),v=!n(function(){var b={};return b[p]=function(){return 7},""[c](b)!==7}),m=v&&!n(function(){var b=!1,w=/a/;return c==="split"&&(w={},w.constructor={},w.constructor[a]=function(){return w},w.flags="",w[p]=/./[p]),w.exec=function(){return b=!0,null},w[p](""),!b});if(!v||!m||f){var y=/./[p],x=d(p,""[c],function(b,w,S,E,_){var R=w.exec;return R===r||R===u.exec?v&&!_?{done:!0,value:e(y,w,S,E)}:{done:!0,value:e(b,S,w,E)}:{done:!1}});t(String.prototype,c,x[0]),t(u,p,x[1])}h&&o(u[p],"sham",!0)},fb}var db,EM;function zk(){if(EM)return db;EM=1;var e=Ck().charAt;return db=function(t,r,n){return r+(n?e(t,r).length:1)},db}var hb,SM;function BJ(){if(SM)return hb;SM=1;var e=bt(),t=at(),r=e.RegExp,n=!t(function(){var i=!0;try{r(".","d")}catch{i=!1}var o={},a="",u=i?"dgimsy":"gimsy",c=function(p,v){Object.defineProperty(o,p,{get:function(){return a+=v,!0}})},d={dotAll:"s",global:"g",ignoreCase:"i",multiline:"m",sticky:"y"};i&&(d.hasIndices="d");for(var f in d)c(f,d[f]);var h=Object.getOwnPropertyDescriptor(r.prototype,"flags").get.call(o);return h!==u||a!==u});return hb={correct:n},hb}var pb,OM;function Hk(){if(OM)return pb;OM=1;var e=Zt(),t=Rr(),r=il(),n=BJ(),i=Bk(),o=RegExp.prototype;return pb=n.correct?function(a){return a.flags}:function(a){return!n.correct&&r(o,a)&&!t(a,"flags")?e(i,a):a.flags},pb}var vb,CM;function Uk(){if(CM)return vb;CM=1;var e=Zt(),t=Ir(),r=Et(),n=Gn(),i=_w(),o=TypeError;return vb=function(a,u){var c=a.exec;if(r(c)){var d=e(c,a,u);return d!==null&&t(d),d}if(n(a)==="RegExp")return e(i,a,u);throw new o("RegExp#exec called on incompatible receiver")},vb}var RM;function FJ(){if(RM)return wM;RM=1;var e=Zt(),t=it(),r=$k(),n=Ir(),i=Nt(),o=gw(),a=Ii(),u=Ci(),c=Ja(),d=zk(),f=Hk(),h=Uk(),p=t("".indexOf);return r("match",function(v,m,y){return[function(b){var w=u(this),S=i(b)?c(b,v):void 0;return S?e(S,b,w):new RegExp(b)[v](a(w))},function(x){var b=n(this),w=a(x),S=y(m,b,w);if(S.done)return S.value;var E=a(f(b));if(p(E,"g")===-1)return h(b,w);var _=p(E,"u")!==-1;b.lastIndex=0;for(var R=[],I=0,N;(N=h(b,w))!==null;){var D=a(N[0]);R[I]=D,D===""&&(b.lastIndex=d(w,o(b.lastIndex),_)),I++}return I===0?null:R}]}),wM}FJ();var IM={},gb,PM;function $J(){if(PM)return gb;PM=1;var e=dk(),t=On();return gb=function(r,n,i){return i.get&&e(i.get,n,{getter:!0}),i.set&&e(i.set,n,{setter:!0}),t.f(r,n,i)},gb}var NM;function zJ(){if(NM)return IM;NM=1;var e=zr(),t=pw().EXISTS,r=it(),n=$J(),i=Function.prototype,o=r(i.toString),a=/function\b(?:\s|\/\*[\S\s]*?\*\/|\/\/[^\n\r]*[\n\r]+)*([^\s(/]*)/,u=r(a.exec),c="name";return e&&!t&&n(i,c,{configurable:!0,get:function(){try{return u(a,o(this))[1]}catch{return""}}}),IM}zJ();var TM={},mb,AM;function HJ(){if(AM)return mb;AM=1;var e=tl(),t=Function.prototype,r=t.apply,n=t.call;return mb=typeof Reflect=="object"&&Reflect.apply||(e?n.bind(r):function(){return n.apply(r,arguments)}),mb}var yb,MM;function UJ(){if(MM)return yb;MM=1;var e=it(),t=Io(),r=Math.floor,n=e("".charAt),i=e("".replace),o=e("".slice),a=/\$([$&'`]|\d{1,2}|<[^>]*>)/g,u=/\$([$&'`]|\d{1,2})/g;return yb=function(c,d,f,h,p,v){var m=f+c.length,y=h.length,x=u;return p!==void 0&&(p=t(p),x=a),i(v,x,function(b,w){var S;switch(n(w,0)){case"$":return"$";case"&":return c;case"`":return o(d,0,f);case"'":return o(d,m);case"<":S=p[o(w,1,-1)];break;default:var E=+w;if(E===0)return b;if(E>y){var _=r(E/10);return _===0?b:_<=y?h[_-1]===void 0?n(w,1):h[_-1]+n(w,1):b}S=h[E-1]}return S===void 0?"":S})},yb}var DM;function VJ(){if(DM)return TM;DM=1;var e=HJ(),t=Zt(),r=it(),n=$k(),i=at(),o=Ir(),a=Et(),u=Nt(),c=sl(),d=gw(),f=Ii(),h=Ci(),p=zk(),v=Ja(),m=UJ(),y=Hk(),x=Uk(),b=$t(),w=b("replace"),S=Math.max,E=Math.min,_=r([].concat),R=r([].push),I=r("".indexOf),N=r("".slice),D=function(j){return j===void 0?j:String(j)},k=(function(){return"a".replace(/./,"$0")==="$0"})(),B=(function(){return/./[w]?/./[w]("a","$0")==="":!1})(),L=!i(function(){var j=/./;return j.exec=function(){var T=[];return T.groups={a:"7"},T},"".replace(j,"$<a>")!=="7"});return n("replace",function(j,T,F){var $=B?"$":"$0";return[function(Y,ee){var H=h(this),Q=u(Y)?v(Y,w):void 0;return Q?t(Q,Y,H,ee):t(T,f(H),Y,ee)},function(W,Y){var ee=o(this),H=f(W);if(typeof Y=="string"&&I(Y,$)===-1&&I(Y,"$<")===-1){var Q=F(T,ee,H,Y);if(Q.done)return Q.value}var ce=a(Y);ce||(Y=f(Y));var se=f(y(ee)),z=I(se,"g")!==-1,G;z&&(G=I(se,"u")!==-1,ee.lastIndex=0);for(var J=[],V;V=x(ee,H),!(V===null||(R(J,V),!z));){var K=f(V[0]);K===""&&(ee.lastIndex=p(H,d(ee.lastIndex),G))}for(var ie="",ne=0,ue=0;ue<J.length;ue++){V=J[ue];for(var de=f(V[0]),we=S(E(c(V.index),H.length),0),Se=[],_e,he=1;he<V.length;he++)R(Se,D(V[he]));var ae=V.groups;if(ce){var Oe=_([de],Se,we,H);ae!==void 0&&R(Oe,ae),_e=f(e(Y,void 0,Oe))}else _e=m(de,H,we,Se,ae,Y);we>=ne&&(ie+=N(H,ne,we)+_e,ne=we+de.length)}return ie+N(H,ne)}]},!L||!k||B),TM}VJ();function kn(e){return!e||!e.ownerDocument||!e.ownerDocument.defaultView?window:e.ownerDocument.defaultView}function zu(e){return!e||!e.ownerDocument?document:e.ownerDocument}var Ji=null,jM=null;Lk&&window.addEventListener("resize",function(){jM!==window.devicePixelRatio&&(jM=window.devicePixelRatio,Ji=null)});function qM(e){if(Ji===null){var t=zu(e);if(typeof t>"u")return Ji=0,Ji;var r=t.body,n=t.createElement("div");n.classList.add("simplebar-hide-scrollbar"),r.appendChild(n);var i=n.getBoundingClientRect().right;r.removeChild(n),Ji=i}return Ji}var gc=(function(){function e(r,n){var i=this;this.onScroll=function(){var o=kn(i.el);i.scrollXTicking||(o.requestAnimationFrame(i.scrollX),i.scrollXTicking=!0),i.scrollYTicking||(o.requestAnimationFrame(i.scrollY),i.scrollYTicking=!0)},this.scrollX=function(){i.axis.x.isOverflowing&&(i.showScrollbar("x"),i.positionScrollbar("x")),i.scrollXTicking=!1},this.scrollY=function(){i.axis.y.isOverflowing&&(i.showScrollbar("y"),i.positionScrollbar("y")),i.scrollYTicking=!1},this.onMouseEnter=function(){i.showScrollbar("x"),i.showScrollbar("y")},this.onMouseMove=function(o){i.mouseX=o.clientX,i.mouseY=o.clientY,(i.axis.x.isOverflowing||i.axis.x.forceVisible)&&i.onMouseMoveForAxis("x"),(i.axis.y.isOverflowing||i.axis.y.forceVisible)&&i.onMouseMoveForAxis("y")},this.onMouseLeave=function(){i.onMouseMove.cancel(),(i.axis.x.isOverflowing||i.axis.x.forceVisible)&&i.onMouseLeaveForAxis("x"),(i.axis.y.isOverflowing||i.axis.y.forceVisible)&&i.onMouseLeaveForAxis("y"),i.mouseX=-1,i.mouseY=-1},this.onWindowResize=function(){i.scrollbarWidth=i.getScrollbarWidth(),i.hideNativeScrollbar()},this.hideScrollbars=function(){i.axis.x.track.rect=i.axis.x.track.el.getBoundingClientRect(),i.axis.y.track.rect=i.axis.y.track.el.getBoundingClientRect(),i.isWithinBounds(i.axis.y.track.rect)||(i.axis.y.scrollbar.el.classList.remove(i.classNames.visible),i.axis.y.isVisible=!1),i.isWithinBounds(i.axis.x.track.rect)||(i.axis.x.scrollbar.el.classList.remove(i.classNames.visible),i.axis.x.isVisible=!1)},this.onPointerEvent=function(o){var a,u;i.axis.x.track.rect=i.axis.x.track.el.getBoundingClientRect(),i.axis.y.track.rect=i.axis.y.track.el.getBoundingClientRect(),(i.axis.x.isOverflowing||i.axis.x.forceVisible)&&(a=i.isWithinBounds(i.axis.x.track.rect)),(i.axis.y.isOverflowing||i.axis.y.forceVisible)&&(u=i.isWithinBounds(i.axis.y.track.rect)),(a||u)&&(o.preventDefault(),o.stopPropagation(),o.type==="mousedown"&&(a&&(i.axis.x.scrollbar.rect=i.axis.x.scrollbar.el.getBoundingClientRect(),i.isWithinBounds(i.axis.x.scrollbar.rect)?i.onDragStart(o,"x"):i.onTrackClick(o,"x")),u&&(i.axis.y.scrollbar.rect=i.axis.y.scrollbar.el.getBoundingClientRect(),i.isWithinBounds(i.axis.y.scrollbar.rect)?i.onDragStart(o,"y"):i.onTrackClick(o,"y"))))},this.drag=function(o){var a,u=i.axis[i.draggedAxis].track,c=u.rect[i.axis[i.draggedAxis].sizeAttr],d=i.axis[i.draggedAxis].scrollbar,f=i.contentWrapperEl[i.axis[i.draggedAxis].scrollSizeAttr],h=parseInt(i.elStyles[i.axis[i.draggedAxis].sizeAttr],10);o.preventDefault(),o.stopPropagation(),i.draggedAxis==="y"?a=o.pageY:a=o.pageX;var p=a-u.rect[i.axis[i.draggedAxis].offsetAttr]-i.axis[i.draggedAxis].dragOffset,v=p/(c-d.size),m=v*(f-h);i.draggedAxis==="x"&&(m=i.isRtl&&e.getRtlHelpers().isRtlScrollbarInverted?m-(c+d.size):m,m=i.isRtl&&e.getRtlHelpers().isRtlScrollingInverted?-m:m),i.contentWrapperEl[i.axis[i.draggedAxis].scrollOffsetAttr]=m},this.onEndDrag=function(o){var a=zu(i.el),u=kn(i.el);o.preventDefault(),o.stopPropagation(),i.el.classList.remove(i.classNames.dragging),a.removeEventListener("mousemove",i.drag,!0),a.removeEventListener("mouseup",i.onEndDrag,!0),i.removePreventClickId=u.setTimeout(function(){a.removeEventListener("click",i.preventClick,!0),a.removeEventListener("dblclick",i.preventClick,!0),i.removePreventClickId=null})},this.preventClick=function(o){o.preventDefault(),o.stopPropagation()},this.el=r,this.minScrollbarWidth=20,this.options=Object.assign({},e.defaultOptions,n),this.classNames=Object.assign({},e.defaultOptions.classNames,this.options.classNames),this.axis={x:{scrollOffsetAttr:"scrollLeft",sizeAttr:"width",scrollSizeAttr:"scrollWidth",offsetSizeAttr:"offsetWidth",offsetAttr:"left",overflowAttr:"overflowX",dragOffset:0,isOverflowing:!0,isVisible:!1,forceVisible:!1,track:{},scrollbar:{}},y:{scrollOffsetAttr:"scrollTop",sizeAttr:"height",scrollSizeAttr:"scrollHeight",offsetSizeAttr:"offsetHeight",offsetAttr:"top",overflowAttr:"overflowY",dragOffset:0,isOverflowing:!0,isVisible:!1,forceVisible:!1,track:{},scrollbar:{}}},this.removePreventClickId=null,!e.instances.has(this.el)&&(this.recalculate=KA(this.recalculate.bind(this),64),this.onMouseMove=KA(this.onMouseMove.bind(this),64),this.hideScrollbars=XA(this.hideScrollbars.bind(this),this.options.timeout),this.onWindowResize=XA(this.onWindowResize.bind(this),64,{leading:!0}),e.getRtlHelpers=sJ(e.getRtlHelpers),this.init())}e.getRtlHelpers=function(){var n=document.createElement("div");n.innerHTML='<div class="hs-dummy-scrollbar-size"><div style="height: 200%; width: 200%; margin: 10px 0;"></div></div>';var i=n.firstElementChild;document.body.appendChild(i);var o=i.firstElementChild;i.scrollLeft=0;var a=e.getOffset(i),u=e.getOffset(o);i.scrollLeft=999;var c=e.getOffset(o);return{isRtlScrollingInverted:a.left!==u.left&&u.left-c.left!==0,isRtlScrollbarInverted:a.left!==u.left}},e.getOffset=function(n){var i=n.getBoundingClientRect(),o=zu(n),a=kn(n);return{top:i.top+(a.pageYOffset||o.documentElement.scrollTop),left:i.left+(a.pageXOffset||o.documentElement.scrollLeft)}};var t=e.prototype;return t.init=function(){e.instances.set(this.el,this),Lk&&(this.initDOM(),this.setAccessibilityAttributes(),this.scrollbarWidth=this.getScrollbarWidth(),this.recalculate(),this.initListeners())},t.initDOM=function(){var n=this;if(Array.prototype.filter.call(this.el.children,function(a){return a.classList.contains(n.classNames.wrapper)}).length)this.wrapperEl=this.el.querySelector("."+this.classNames.wrapper),this.contentWrapperEl=this.options.scrollableNode||this.el.querySelector("."+this.classNames.contentWrapper),this.contentEl=this.options.contentNode||this.el.querySelector("."+this.classNames.contentEl),this.offsetEl=this.el.querySelector("."+this.classNames.offset),this.maskEl=this.el.querySelector("."+this.classNames.mask),this.placeholderEl=this.findChild(this.wrapperEl,"."+this.classNames.placeholder),this.heightAutoObserverWrapperEl=this.el.querySelector("."+this.classNames.heightAutoObserverWrapperEl),this.heightAutoObserverEl=this.el.querySelector("."+this.classNames.heightAutoObserverEl),this.axis.x.track.el=this.findChild(this.el,"."+this.classNames.track+"."+this.classNames.horizontal),this.axis.y.track.el=this.findChild(this.el,"."+this.classNames.track+"."+this.classNames.vertical);else{for(this.wrapperEl=document.createElement("div"),this.contentWrapperEl=document.createElement("div"),this.offsetEl=document.createElement("div"),this.maskEl=document.createElement("div"),this.contentEl=document.createElement("div"),this.placeholderEl=document.createElement("div"),this.heightAutoObserverWrapperEl=document.createElement("div"),this.heightAutoObserverEl=document.createElement("div"),this.wrapperEl.classList.add(this.classNames.wrapper),this.contentWrapperEl.classList.add(this.classNames.contentWrapper),this.offsetEl.classList.add(this.classNames.offset),this.maskEl.classList.add(this.classNames.mask),this.contentEl.classList.add(this.classNames.contentEl),this.placeholderEl.classList.add(this.classNames.placeholder),this.heightAutoObserverWrapperEl.classList.add(this.classNames.heightAutoObserverWrapperEl),this.heightAutoObserverEl.classList.add(this.classNames.heightAutoObserverEl);this.el.firstChild;)this.contentEl.appendChild(this.el.firstChild);this.contentWrapperEl.appendChild(this.contentEl),this.offsetEl.appendChild(this.contentWrapperEl),this.maskEl.appendChild(this.offsetEl),this.heightAutoObserverWrapperEl.appendChild(this.heightAutoObserverEl),this.wrapperEl.appendChild(this.heightAutoObserverWrapperEl),this.wrapperEl.appendChild(this.maskEl),this.wrapperEl.appendChild(this.placeholderEl),this.el.appendChild(this.wrapperEl)}if(!this.axis.x.track.el||!this.axis.y.track.el){var i=document.createElement("div"),o=document.createElement("div");i.classList.add(this.classNames.track),o.classList.add(this.classNames.scrollbar),i.appendChild(o),this.axis.x.track.el=i.cloneNode(!0),this.axis.x.track.el.classList.add(this.classNames.horizontal),this.axis.y.track.el=i.cloneNode(!0),this.axis.y.track.el.classList.add(this.classNames.vertical),this.el.appendChild(this.axis.x.track.el),this.el.appendChild(this.axis.y.track.el)}this.axis.x.scrollbar.el=this.axis.x.track.el.querySelector("."+this.classNames.scrollbar),this.axis.y.scrollbar.el=this.axis.y.track.el.querySelector("."+this.classNames.scrollbar),this.options.autoHide||(this.axis.x.scrollbar.el.classList.add(this.classNames.visible),this.axis.y.scrollbar.el.classList.add(this.classNames.visible)),this.el.setAttribute("data-simplebar","init")},t.setAccessibilityAttributes=function(){var n=this.options.ariaLabel||"scrollable content";this.contentWrapperEl.setAttribute("tabindex","0"),this.contentWrapperEl.setAttribute("role","region"),this.contentWrapperEl.setAttribute("aria-label",n)},t.initListeners=function(){var n=this,i=kn(this.el);this.options.autoHide&&this.el.addEventListener("mouseenter",this.onMouseEnter),["mousedown","click","dblclick"].forEach(function(c){n.el.addEventListener(c,n.onPointerEvent,!0)}),["touchstart","touchend","touchmove"].forEach(function(c){n.el.addEventListener(c,n.onPointerEvent,{capture:!0,passive:!0})}),this.el.addEventListener("mousemove",this.onMouseMove),this.el.addEventListener("mouseleave",this.onMouseLeave),this.contentWrapperEl.addEventListener("scroll",this.onScroll),i.addEventListener("resize",this.onWindowResize);var o=!1,a=null,u=i.ResizeObserver||IJ;this.resizeObserver=new u(function(){!o||a!==null||(a=i.requestAnimationFrame(function(){n.recalculate(),a=null}))}),this.resizeObserver.observe(this.el),this.resizeObserver.observe(this.contentEl),i.requestAnimationFrame(function(){o=!0}),this.mutationObserver=new i.MutationObserver(this.recalculate),this.mutationObserver.observe(this.contentEl,{childList:!0,subtree:!0,characterData:!0})},t.recalculate=function(){var n=kn(this.el);this.elStyles=n.getComputedStyle(this.el),this.isRtl=this.elStyles.direction==="rtl";var i=this.heightAutoObserverEl.offsetHeight<=1,o=this.heightAutoObserverEl.offsetWidth<=1,a=this.contentEl.offsetWidth,u=this.contentWrapperEl.offsetWidth,c=this.elStyles.overflowX,d=this.elStyles.overflowY;this.contentEl.style.padding=this.elStyles.paddingTop+" "+this.elStyles.paddingRight+" "+this.elStyles.paddingBottom+" "+this.elStyles.paddingLeft,this.wrapperEl.style.margin="-"+this.elStyles.paddingTop+" -"+this.elStyles.paddingRight+" -"+this.elStyles.paddingBottom+" -"+this.elStyles.paddingLeft;var f=this.contentEl.scrollHeight,h=this.contentEl.scrollWidth;this.contentWrapperEl.style.height=i?"auto":"100%",this.placeholderEl.style.width=o?a+"px":"auto",this.placeholderEl.style.height=f+"px";var p=this.contentWrapperEl.offsetHeight;this.axis.x.isOverflowing=h>a,this.axis.y.isOverflowing=f>p,this.axis.x.isOverflowing=c==="hidden"?!1:this.axis.x.isOverflowing,this.axis.y.isOverflowing=d==="hidden"?!1:this.axis.y.isOverflowing,this.axis.x.forceVisible=this.options.forceVisible==="x"||this.options.forceVisible===!0,this.axis.y.forceVisible=this.options.forceVisible==="y"||this.options.forceVisible===!0,this.hideNativeScrollbar();var v=this.axis.x.isOverflowing?this.scrollbarWidth:0,m=this.axis.y.isOverflowing?this.scrollbarWidth:0;this.axis.x.isOverflowing=this.axis.x.isOverflowing&&h>u-m,this.axis.y.isOverflowing=this.axis.y.isOverflowing&&f>p-v,this.axis.x.scrollbar.size=this.getScrollbarSize("x"),this.axis.y.scrollbar.size=this.getScrollbarSize("y"),this.axis.x.scrollbar.el.style.width=this.axis.x.scrollbar.size+"px",this.axis.y.scrollbar.el.style.height=this.axis.y.scrollbar.size+"px",this.positionScrollbar("x"),this.positionScrollbar("y"),this.toggleTrackVisibility("x"),this.toggleTrackVisibility("y")},t.getScrollbarSize=function(n){if(n===void 0&&(n="y"),!this.axis[n].isOverflowing)return 0;var i=this.contentEl[this.axis[n].scrollSizeAttr],o=this.axis[n].track.el[this.axis[n].offsetSizeAttr],a,u=o/i;return a=Math.max(~~(u*o),this.options.scrollbarMinSize),this.options.scrollbarMaxSize&&(a=Math.min(a,this.options.scrollbarMaxSize)),a},t.positionScrollbar=function(n){if(n===void 0&&(n="y"),!!this.axis[n].isOverflowing){var i=this.contentWrapperEl[this.axis[n].scrollSizeAttr],o=this.axis[n].track.el[this.axis[n].offsetSizeAttr],a=parseInt(this.elStyles[this.axis[n].sizeAttr],10),u=this.axis[n].scrollbar,c=this.contentWrapperEl[this.axis[n].scrollOffsetAttr];c=n==="x"&&this.isRtl&&e.getRtlHelpers().isRtlScrollingInverted?-c:c;var d=c/(i-a),f=~~((o-u.size)*d);f=n==="x"&&this.isRtl&&e.getRtlHelpers().isRtlScrollbarInverted?f+(o-u.size):f,u.el.style.transform=n==="x"?"translate3d("+f+"px, 0, 0)":"translate3d(0, "+f+"px, 0)"}},t.toggleTrackVisibility=function(n){n===void 0&&(n="y");var i=this.axis[n].track.el,o=this.axis[n].scrollbar.el;this.axis[n].isOverflowing||this.axis[n].forceVisible?(i.style.visibility="visible",this.contentWrapperEl.style[this.axis[n].overflowAttr]="scroll"):(i.style.visibility="hidden",this.contentWrapperEl.style[this.axis[n].overflowAttr]="hidden"),this.axis[n].isOverflowing?o.style.display="block":o.style.display="none"},t.hideNativeScrollbar=function(){this.offsetEl.style[this.isRtl?"left":"right"]=this.axis.y.isOverflowing||this.axis.y.forceVisible?"-"+this.scrollbarWidth+"px":0,this.offsetEl.style.bottom=this.axis.x.isOverflowing||this.axis.x.forceVisible?"-"+this.scrollbarWidth+"px":0},t.onMouseMoveForAxis=function(n){n===void 0&&(n="y"),this.axis[n].track.rect=this.axis[n].track.el.getBoundingClientRect(),this.axis[n].scrollbar.rect=this.axis[n].scrollbar.el.getBoundingClientRect();var i=this.isWithinBounds(this.axis[n].scrollbar.rect);i?this.axis[n].scrollbar.el.classList.add(this.classNames.hover):this.axis[n].scrollbar.el.classList.remove(this.classNames.hover),this.isWithinBounds(this.axis[n].track.rect)?(this.showScrollbar(n),this.axis[n].track.el.classList.add(this.classNames.hover)):this.axis[n].track.el.classList.remove(this.classNames.hover)},t.onMouseLeaveForAxis=function(n){n===void 0&&(n="y"),this.axis[n].track.el.classList.remove(this.classNames.hover),this.axis[n].scrollbar.el.classList.remove(this.classNames.hover)},t.showScrollbar=function(n){n===void 0&&(n="y");var i=this.axis[n].scrollbar.el;this.axis[n].isVisible||(i.classList.add(this.classNames.visible),this.axis[n].isVisible=!0),this.options.autoHide&&this.hideScrollbars()},t.onDragStart=function(n,i){i===void 0&&(i="y");var o=zu(this.el),a=kn(this.el),u=this.axis[i].scrollbar,c=i==="y"?n.pageY:n.pageX;this.axis[i].dragOffset=c-u.rect[this.axis[i].offsetAttr],this.draggedAxis=i,this.el.classList.add(this.classNames.dragging),o.addEventListener("mousemove",this.drag,!0),o.addEventListener("mouseup",this.onEndDrag,!0),this.removePreventClickId===null?(o.addEventListener("click",this.preventClick,!0),o.addEventListener("dblclick",this.preventClick,!0)):(a.clearTimeout(this.removePreventClickId),this.removePreventClickId=null)},t.onTrackClick=function(n,i){var o=this;if(i===void 0&&(i="y"),!!this.options.clickOnTrack){var a=kn(this.el);this.axis[i].scrollbar.rect=this.axis[i].scrollbar.el.getBoundingClientRect();var u=this.axis[i].scrollbar,c=u.rect[this.axis[i].offsetAttr],d=parseInt(this.elStyles[this.axis[i].sizeAttr],10),f=this.contentWrapperEl[this.axis[i].scrollOffsetAttr],h=i==="y"?this.mouseY-c:this.mouseX-c,p=h<0?-1:1,v=p===-1?f-d:f+d,m=function y(){if(p===-1){if(f>v){var x;f-=o.options.clickOnTrackSpeed,o.contentWrapperEl.scrollTo((x={},x[o.axis[i].offsetAttr]=f,x)),a.requestAnimationFrame(y)}}else if(f<v){var b;f+=o.options.clickOnTrackSpeed,o.contentWrapperEl.scrollTo((b={},b[o.axis[i].offsetAttr]=f,b)),a.requestAnimationFrame(y)}};m()}},t.getContentElement=function(){return this.contentEl},t.getScrollElement=function(){return this.contentWrapperEl},t.getScrollbarWidth=function(){try{return getComputedStyle(this.contentWrapperEl,"::-webkit-scrollbar").display==="none"||"scrollbarWidth"in document.documentElement.style||"-ms-overflow-style"in document.documentElement.style?0:qM(this.el)}catch{return qM(this.el)}},t.removeListeners=function(){var n=this,i=kn(this.el);this.options.autoHide&&this.el.removeEventListener("mouseenter",this.onMouseEnter),["mousedown","click","dblclick"].forEach(function(o){n.el.removeEventListener(o,n.onPointerEvent,!0)}),["touchstart","touchend","touchmove"].forEach(function(o){n.el.removeEventListener(o,n.onPointerEvent,{capture:!0,passive:!0})}),this.el.removeEventListener("mousemove",this.onMouseMove),this.el.removeEventListener("mouseleave",this.onMouseLeave),this.contentWrapperEl&&this.contentWrapperEl.removeEventListener("scroll",this.onScroll),i.removeEventListener("resize",this.onWindowResize),this.mutationObserver&&this.mutationObserver.disconnect(),this.resizeObserver&&this.resizeObserver.disconnect(),this.recalculate.cancel(),this.onMouseMove.cancel(),this.hideScrollbars.cancel(),this.onWindowResize.cancel()},t.unMount=function(){this.removeListeners(),e.instances.delete(this.el)},t.isWithinBounds=function(n){return this.mouseX>=n.left&&this.mouseX<=n.left+n.width&&this.mouseY>=n.top&&this.mouseY<=n.top+n.height},t.findChild=function(n,i){var o=n.matches||n.webkitMatchesSelector||n.mozMatchesSelector||n.msMatchesSelector;return Array.prototype.filter.call(n.children,function(a){return o.call(a,i)})[0]},e})();gc.defaultOptions={autoHide:!0,forceVisible:!1,clickOnTrack:!0,clickOnTrackSpeed:40,classNames:{contentEl:"simplebar-content",contentWrapper:"simplebar-content-wrapper",offset:"simplebar-offset",mask:"simplebar-mask",wrapper:"simplebar-wrapper",placeholder:"simplebar-placeholder",scrollbar:"simplebar-scrollbar",track:"simplebar-track",heightAutoObserverWrapperEl:"simplebar-height-auto-observer-wrapper",heightAutoObserverEl:"simplebar-height-auto-observer",visible:"simplebar-visible",horizontal:"simplebar-horizontal",vertical:"simplebar-vertical",hover:"simplebar-hover",dragging:"simplebar-dragging"},scrollbarMinSize:25,scrollbarMaxSize:0,timeout:1e3};gc.instances=new WeakMap;function kM(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function Tu(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?kM(Object(r),!0).forEach(function(n){WJ(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):kM(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function WJ(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function mc(){return mc=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},mc.apply(this,arguments)}function GJ(e,t){if(e==null)return{};var r={},n=Object.keys(e),i,o;for(o=0;o<n.length;o++)i=n[o],!(t.indexOf(i)>=0)&&(r[i]=e[i]);return r}function KJ(e,t){if(e==null)return{};var r=GJ(e,t),n,i;if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(i=0;i<o.length;i++)n=o[i],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(r[n]=e[n])}return r}var YJ=["children","scrollableNodeProps","tag"],XJ=function(t){var r=Array.prototype.reduce.call(t,function(n,i){var o=i.name.match(/data-simplebar-(.+)/);if(o){var a=o[1].replace(/\W+(.)/g,function(u,c){return c.toUpperCase()});switch(i.value){case"true":n[a]=!0;break;case"false":n[a]=!1;break;case void 0:n[a]=!0;break;default:n[a]=i.value}}return n},{});return r},dl=A.forwardRef(function(e,t){var r=e.children,n=e.scrollableNodeProps,i=n===void 0?{}:n,o=e.tag,a=o===void 0?"div":o,u=KJ(e,YJ),c=a,d,f=A.useRef(),h=A.useRef(),p=A.useRef(),v={},m={},y=[];return Object.keys(u).forEach(function(x){Object.prototype.hasOwnProperty.call(gc.defaultOptions,x)?v[x]=u[x]:x.match(/data-simplebar-(.+)/)&&x!=="data-simplebar-direction"?y.push({name:x,value:u[x]}):m[x]=u[x]}),y.length&&console.warn(`simplebar-react: this way of passing options is deprecated. Pass it like normal props instead:
|
|
84
|
+
`)+ye+`return __p
|
|
85
|
+
}`;var $e=JO(function(){return rt(V,Ae+"return "+ye).apply(r,Z)});if($e.source=ye,Xp($e))throw $e;return $e}function CU(l){return ot(l).toLowerCase()}function RU(l){return ot(l).toUpperCase()}function NU(l,p,y){if(l=ot(l),l&&(y||p===r))return sS(l);if(!l||!(p=Br(p)))return l;var I=xn(l),k=xn(p),V=lS(I,k),Z=cS(I,k)+1;return Do(I,V,Z).join("")}function IU(l,p,y){if(l=ot(l),l&&(y||p===r))return l.slice(0,dS(l)+1);if(!l||!(p=Br(p)))return l;var I=xn(l),k=cS(I,xn(p))+1;return Do(I,0,k).join("")}function PU(l,p,y){if(l=ot(l),l&&(y||p===r))return l.replace(Sr,"");if(!l||!(p=Br(p)))return l;var I=xn(l),k=lS(I,xn(p));return Do(I,k).join("")}function TU(l,p){var y=j,I=M;if(Nt(p)){var k="separator"in p?p.separator:k;y="length"in p?Be(p.length):y,I="omission"in p?Br(p.omission):I}l=ot(l);var V=l.length;if(Fi(l)){var Z=xn(l);V=Z.length}if(y>=V)return l;var ee=y-$i(I);if(ee<1)return I;var ae=Z?Do(Z,0,ee).join(""):l.slice(0,ee);if(k===r)return ae+I;if(Z&&(ee+=ae.length-ee),Zp(k)){if(l.slice(ee).search(k)){var ge,me=ae;for(k.global||(k=pp(k.source,ot(Bl.exec(k))+"g")),k.lastIndex=0;ge=k.exec(me);)var ye=ge.index;ae=ae.slice(0,ye===r?ee:ye)}}else if(l.indexOf(Br(k),ee)!=ee){var Se=ae.lastIndexOf(k);Se>-1&&(ae=ae.slice(0,Se))}return ae+I}function AU(l){return l=ot(l),l&&er.test(l)?l.replace($t,s4):l}var kU=Ki(function(l,p,y){return l+(y?" ":"")+p.toUpperCase()}),eh=QS("toUpperCase");function ZO(l,p,y){return l=ot(l),p=y?r:p,p===r?r4(l)?u4(l):G$(l):l.match(p)||[]}var JO=Ve(function(l,p){try{return qr(l,r,p)}catch(y){return Xp(y)?y:new qe(y)}}),DU=lo(function(l,p){return Jr(p,function(y){y=Bn(y),ao(l,y,Yp(l[y],l))}),l});function MU(l){var p=l==null?0:l.length,y=ke();return l=p?Ot(l,function(I){if(typeof I[1]!="function")throw new Qr(a);return[y(I[0]),I[1]]}):[],Ve(function(I){for(var k=-1;++k<p;){var V=l[k];if(qr(V[0],this,I))return qr(V[1],this,I)}})}function jU(l){return sV(tn(l,f))}function th(l){return function(){return l}}function LU(l,p){return l==null||l!==l?p:l}var qU=tO(),zU=tO(!0);function Nr(l){return l}function rh(l){return TS(typeof l=="function"?l:tn(l,f))}function BU(l){return kS(tn(l,f))}function FU(l,p){return DS(l,tn(p,f))}var $U=Ve(function(l,p){return function(y){return ss(y,l,p)}}),VU=Ve(function(l,p){return function(y){return ss(l,y,p)}});function nh(l,p,y){var I=Xt(p),k=bc(p,I);y==null&&!(Nt(p)&&(k.length||!I.length))&&(y=p,p=l,l=this,k=bc(p,Xt(p)));var V=!(Nt(y)&&"chain"in y)||!!y.chain,Z=uo(l);return Jr(k,function(ee){var ae=p[ee];l[ee]=ae,Z&&(l.prototype[ee]=function(){var ge=this.__chain__;if(V||ge){var me=l(this.__wrapped__),ye=me.__actions__=Or(this.__actions__);return ye.push({func:ae,args:arguments,thisArg:l}),me.__chain__=ge,me}return ae.apply(l,No([this.value()],arguments))})}),l}function HU(){return rr._===this&&(rr._=g4),this}function oh(){}function WU(l){return l=Be(l),Ve(function(p){return MS(p,l)})}var UU=Mp(Ot),GU=Mp(rS),YU=Mp(ap);function QO(l){return $p(l)?sp(Bn(l)):SV(l)}function KU(l){return function(p){return l==null?r:li(l,p)}}var XU=nO(),ZU=nO(!0);function ih(){return[]}function ah(){return!1}function JU(){return{}}function QU(){return""}function e8(){return!0}function t8(l,p){if(l=Be(l),l<1||l>F)return[];var y=U,I=lr(l,U);p=ke(p),l-=U;for(var k=up(I,p);++y<l;)p(y);return k}function r8(l){return ze(l)?Ot(l,Bn):Fr(l)?[l]:Or(yO(ot(l)))}function n8(l){var p=++h4;return ot(l)+p}var o8=Sc(function(l,p){return l+p},0),i8=jp("ceil"),a8=Sc(function(l,p){return l/p},1),s8=jp("floor");function l8(l){return l&&l.length?mc(l,Nr,wp):r}function c8(l,p){return l&&l.length?mc(l,ke(p,2),wp):r}function u8(l){return iS(l,Nr)}function d8(l,p){return iS(l,ke(p,2))}function f8(l){return l&&l.length?mc(l,Nr,Op):r}function p8(l,p){return l&&l.length?mc(l,ke(p,2),Op):r}var h8=Sc(function(l,p){return l*p},1),v8=jp("round"),g8=Sc(function(l,p){return l-p},0);function m8(l){return l&&l.length?cp(l,Nr):0}function b8(l,p){return l&&l.length?cp(l,ke(p,2)):0}return B.after=B6,B.ary=PO,B.assign=RW,B.assignIn=HO,B.assignInWith=Lc,B.assignWith=NW,B.at=IW,B.before=TO,B.bind=Yp,B.bindAll=DU,B.bindKey=AO,B.castArray=J6,B.chain=RO,B.chunk=sH,B.compact=lH,B.concat=cH,B.cond=MU,B.conforms=jU,B.constant=th,B.countBy=m6,B.create=PW,B.curry=kO,B.curryRight=DO,B.debounce=MO,B.defaults=TW,B.defaultsDeep=AW,B.defer=F6,B.delay=$6,B.difference=uH,B.differenceBy=dH,B.differenceWith=fH,B.drop=pH,B.dropRight=hH,B.dropRightWhile=vH,B.dropWhile=gH,B.fill=mH,B.filter=y6,B.flatMap=_6,B.flatMapDeep=E6,B.flatMapDepth=S6,B.flatten=EO,B.flattenDeep=bH,B.flattenDepth=yH,B.flip=V6,B.flow=qU,B.flowRight=zU,B.fromPairs=xH,B.functions=zW,B.functionsIn=BW,B.groupBy=O6,B.initial=_H,B.intersection=EH,B.intersectionBy=SH,B.intersectionWith=OH,B.invert=$W,B.invertBy=VW,B.invokeMap=R6,B.iteratee=rh,B.keyBy=N6,B.keys=Xt,B.keysIn=Rr,B.map=Tc,B.mapKeys=WW,B.mapValues=UW,B.matches=BU,B.matchesProperty=FU,B.memoize=kc,B.merge=GW,B.mergeWith=WO,B.method=$U,B.methodOf=VU,B.mixin=nh,B.negate=Dc,B.nthArg=WU,B.omit=YW,B.omitBy=KW,B.once=H6,B.orderBy=I6,B.over=UU,B.overArgs=W6,B.overEvery=GU,B.overSome=YU,B.partial=Kp,B.partialRight=jO,B.partition=P6,B.pick=XW,B.pickBy=UO,B.property=QO,B.propertyOf=KU,B.pull=IH,B.pullAll=OO,B.pullAllBy=PH,B.pullAllWith=TH,B.pullAt=AH,B.range=XU,B.rangeRight=ZU,B.rearg=U6,B.reject=k6,B.remove=kH,B.rest=G6,B.reverse=Up,B.sampleSize=M6,B.set=JW,B.setWith=QW,B.shuffle=j6,B.slice=DH,B.sortBy=z6,B.sortedUniq=FH,B.sortedUniqBy=$H,B.split=_U,B.spread=Y6,B.tail=VH,B.take=HH,B.takeRight=WH,B.takeRightWhile=UH,B.takeWhile=GH,B.tap=l6,B.throttle=K6,B.thru=Pc,B.toArray=FO,B.toPairs=GO,B.toPairsIn=YO,B.toPath=r8,B.toPlainObject=VO,B.transform=eU,B.unary=X6,B.union=YH,B.unionBy=KH,B.unionWith=XH,B.uniq=ZH,B.uniqBy=JH,B.uniqWith=QH,B.unset=tU,B.unzip=Gp,B.unzipWith=CO,B.update=rU,B.updateWith=nU,B.values=Ji,B.valuesIn=oU,B.without=e6,B.words=ZO,B.wrap=Z6,B.xor=t6,B.xorBy=r6,B.xorWith=n6,B.zip=o6,B.zipObject=i6,B.zipObjectDeep=a6,B.zipWith=s6,B.entries=GO,B.entriesIn=YO,B.extend=HO,B.extendWith=Lc,nh(B,B),B.add=o8,B.attempt=JO,B.camelCase=lU,B.capitalize=KO,B.ceil=i8,B.clamp=iU,B.clone=Q6,B.cloneDeep=tW,B.cloneDeepWith=rW,B.cloneWith=eW,B.conformsTo=nW,B.deburr=XO,B.defaultTo=LU,B.divide=a8,B.endsWith=cU,B.eq=_n,B.escape=uU,B.escapeRegExp=dU,B.every=b6,B.find=x6,B.findIndex=wO,B.findKey=kW,B.findLast=w6,B.findLastIndex=_O,B.findLastKey=DW,B.floor=s8,B.forEach=NO,B.forEachRight=IO,B.forIn=MW,B.forInRight=jW,B.forOwn=LW,B.forOwnRight=qW,B.get=Jp,B.gt=oW,B.gte=iW,B.has=FW,B.hasIn=Qp,B.head=SO,B.identity=Nr,B.includes=C6,B.indexOf=wH,B.inRange=aU,B.invoke=HW,B.isArguments=di,B.isArray=ze,B.isArrayBuffer=aW,B.isArrayLike=Cr,B.isArrayLikeObject=Dt,B.isBoolean=sW,B.isBuffer=Mo,B.isDate=lW,B.isElement=cW,B.isEmpty=uW,B.isEqual=dW,B.isEqualWith=fW,B.isError=Xp,B.isFinite=pW,B.isFunction=uo,B.isInteger=LO,B.isLength=Mc,B.isMap=qO,B.isMatch=hW,B.isMatchWith=vW,B.isNaN=gW,B.isNative=mW,B.isNil=yW,B.isNull=bW,B.isNumber=zO,B.isObject=Nt,B.isObjectLike=Pt,B.isPlainObject=ps,B.isRegExp=Zp,B.isSafeInteger=xW,B.isSet=BO,B.isString=jc,B.isSymbol=Fr,B.isTypedArray=Zi,B.isUndefined=wW,B.isWeakMap=_W,B.isWeakSet=EW,B.join=CH,B.kebabCase=fU,B.last=nn,B.lastIndexOf=RH,B.lowerCase=pU,B.lowerFirst=hU,B.lt=SW,B.lte=OW,B.max=l8,B.maxBy=c8,B.mean=u8,B.meanBy=d8,B.min=f8,B.minBy=p8,B.stubArray=ih,B.stubFalse=ah,B.stubObject=JU,B.stubString=QU,B.stubTrue=e8,B.multiply=h8,B.nth=NH,B.noConflict=HU,B.noop=oh,B.now=Ac,B.pad=vU,B.padEnd=gU,B.padStart=mU,B.parseInt=bU,B.random=sU,B.reduce=T6,B.reduceRight=A6,B.repeat=yU,B.replace=xU,B.result=ZW,B.round=v8,B.runInContext=ie,B.sample=D6,B.size=L6,B.snakeCase=wU,B.some=q6,B.sortedIndex=MH,B.sortedIndexBy=jH,B.sortedIndexOf=LH,B.sortedLastIndex=qH,B.sortedLastIndexBy=zH,B.sortedLastIndexOf=BH,B.startCase=EU,B.startsWith=SU,B.subtract=g8,B.sum=m8,B.sumBy=b8,B.template=OU,B.times=t8,B.toFinite=fo,B.toInteger=Be,B.toLength=$O,B.toLower=CU,B.toNumber=on,B.toSafeInteger=CW,B.toString=ot,B.toUpper=RU,B.trim=NU,B.trimEnd=IU,B.trimStart=PU,B.truncate=TU,B.unescape=AU,B.uniqueId=n8,B.upperCase=kU,B.upperFirst=eh,B.each=NO,B.eachRight=IO,B.first=SO,nh(B,(function(){var l={};return qn(B,function(p,y){ct.call(B.prototype,y)||(l[y]=p)}),l})(),{chain:!1}),B.VERSION=n,Jr(["bind","bindKey","curry","curryRight","partial","partialRight"],function(l){B[l].placeholder=B}),Jr(["drop","take"],function(l,p){Ye.prototype[l]=function(y){y=y===r?1:Wt(Be(y),0);var I=this.__filtered__&&!p?new Ye(this):this.clone();return I.__filtered__?I.__takeCount__=lr(y,I.__takeCount__):I.__views__.push({size:lr(y,U),type:l+(I.__dir__<0?"Right":"")}),I},Ye.prototype[l+"Right"]=function(y){return this.reverse()[l](y).reverse()}}),Jr(["filter","map","takeWhile"],function(l,p){var y=p+1,I=y==T||y==q;Ye.prototype[l]=function(k){var V=this.clone();return V.__iteratees__.push({iteratee:ke(k,3),type:y}),V.__filtered__=V.__filtered__||I,V}}),Jr(["head","last"],function(l,p){var y="take"+(p?"Right":"");Ye.prototype[l]=function(){return this[y](1).value()[0]}}),Jr(["initial","tail"],function(l,p){var y="drop"+(p?"":"Right");Ye.prototype[l]=function(){return this.__filtered__?new Ye(this):this[y](1)}}),Ye.prototype.compact=function(){return this.filter(Nr)},Ye.prototype.find=function(l){return this.filter(l).head()},Ye.prototype.findLast=function(l){return this.reverse().find(l)},Ye.prototype.invokeMap=Ve(function(l,p){return typeof l=="function"?new Ye(this):this.map(function(y){return ss(y,l,p)})}),Ye.prototype.reject=function(l){return this.filter(Dc(ke(l)))},Ye.prototype.slice=function(l,p){l=Be(l);var y=this;return y.__filtered__&&(l>0||p<0)?new Ye(y):(l<0?y=y.takeRight(-l):l&&(y=y.drop(l)),p!==r&&(p=Be(p),y=p<0?y.dropRight(-p):y.take(p-l)),y)},Ye.prototype.takeRightWhile=function(l){return this.reverse().takeWhile(l).reverse()},Ye.prototype.toArray=function(){return this.take(U)},qn(Ye.prototype,function(l,p){var y=/^(?:filter|find|map|reject)|While$/.test(p),I=/^(?:head|last)$/.test(p),k=B[I?"take"+(p=="last"?"Right":""):p],V=I||/^find/.test(p);k&&(B.prototype[p]=function(){var Z=this.__wrapped__,ee=I?[1]:arguments,ae=Z instanceof Ye,ge=ee[0],me=ae||ze(Z),ye=function(Ue){var Ke=k.apply(B,No([Ue],ee));return I&&Se?Ke[0]:Ke};me&&y&&typeof ge=="function"&&ge.length!=1&&(ae=me=!1);var Se=this.__chain__,Ae=!!this.__actions__.length,De=V&&!Se,$e=ae&&!Ae;if(!V&&me){Z=$e?Z:new Ye(this);var Me=l.apply(Z,ee);return Me.__actions__.push({func:Pc,args:[ye],thisArg:r}),new en(Me,Se)}return De&&$e?l.apply(this,ee):(Me=this.thru(ye),De?I?Me.value()[0]:Me.value():Me)})}),Jr(["pop","push","shift","sort","splice","unshift"],function(l){var p=rc[l],y=/^(?:push|sort|unshift)$/.test(l)?"tap":"thru",I=/^(?:pop|shift)$/.test(l);B.prototype[l]=function(){var k=arguments;if(I&&!this.__chain__){var V=this.value();return p.apply(ze(V)?V:[],k)}return this[y](function(Z){return p.apply(ze(Z)?Z:[],k)})}}),qn(Ye.prototype,function(l,p){var y=B[p];if(y){var I=y.name+"";ct.call(Ui,I)||(Ui[I]=[]),Ui[I].push({name:p,func:y})}}),Ui[Ec(r,x).name]=[{name:"wrapper",func:r}],Ye.prototype.clone=A4,Ye.prototype.reverse=k4,Ye.prototype.value=D4,B.prototype.at=c6,B.prototype.chain=u6,B.prototype.commit=d6,B.prototype.next=f6,B.prototype.plant=h6,B.prototype.reverse=v6,B.prototype.toJSON=B.prototype.valueOf=B.prototype.value=g6,B.prototype.first=B.prototype.head,es&&(B.prototype[es]=p6),B}),Vi=d4();ni?((ni.exports=Vi)._=Vi,rp._=Vi):rr._=Vi}).call(pae)})(Us,Us.exports)),Us.exports}var Al=hae();function vae(){const e=Xe.useAppDispatch(),t=Xe.useAppSelector(Xe.selectRoles),r=Xe.useAppSelector(Xe.selectPrivileges),n=Xe.useAppSelector(Xe.selectRolesFlags),o=Xe.useAppSelector(Xe.selectRolesAndPrivileges,(b,g)=>Al.isEqual(b,g)),i=Xe.useAppSelector(Xe.selectCatalog),a=Xe.useAppSelector(Xe.selectQodly),s=Xe.useAppSelector(Xe.selectSelectedTab),c=Xe.useAppSelector(Xe.selectForceLogin),u=Xe.useAppSelector(Xe.selectRestrictedByDefault),d=Xe.useAppSelector(Xe.selectGuestPrivilege),f=Xe.useAppSelector(Xe.selectCatalogMethods),h=Xe.useAppSelector(Xe.selectDataclasses),v=Xe.useAppSelector(Xe.selectSingletons);return{getRoles:()=>t,getPrivileges:()=>r,getRolesFlags:()=>n,getRolesAndPrivileges:()=>o,getCatalog:()=>i,getQodly:()=>a,getSelectedTab:()=>s,getForceLogin:()=>c??!1,getRestrictedByDefault:()=>u??!1,getGuestPrivilege:()=>d??null,getCatalogMethods:()=>f,getDataclasses:()=>h,getSingletons:()=>v,actions:{updateRoles:b=>{e(Xe.updateRoles(b))},updatePrivileges:b=>{e(Xe.updatePrivileges(b))},setRolesContent:b=>{e(Xe.setRolesContent(b))},toggleTab:b=>{e(Xe.toggleTab(b))},toggleForceLogin:b=>{e(Xe.toggleForceLogin(b))},toggleRestrictedByDefault:b=>{e(Xe.toggleRestrictedByDefault(b))},setTabFlags:(b,g)=>{e(Xe.setTabFlags({path:b,flags:g}))},openModal:async b=>await e(Xe.openModal(b)).unwrap()}}}const JB=R.createContext(null),QB=({children:e,adapter:t})=>O.jsx(JB.Provider,{value:t,children:e});function dr(){const e=R.useContext(JB);if(!e)throw new Error("useEditorStateAdapter must be used within an EditorStateAdapterProvider");return e}var T_=function(e,t){return T_=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,n){r.__proto__=n}||function(r,n){for(var o in n)Object.prototype.hasOwnProperty.call(n,o)&&(r[o]=n[o])},T_(e,t)};function kl(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");T_(e,t);function r(){this.constructor=e}e.prototype=t===null?Object.create(t):(r.prototype=t.prototype,new r)}var vd=function(){return vd=Object.assign||function(t){for(var r,n=1,o=arguments.length;n<o;n++){r=arguments[n];for(var i in r)Object.prototype.hasOwnProperty.call(r,i)&&(t[i]=r[i])}return t},vd.apply(this,arguments)};function A_(e){var t=typeof Symbol=="function"&&Symbol.iterator,r=t&&e[t],n=0;if(r)return r.call(e);if(e&&typeof e.length=="number")return{next:function(){return e&&n>=e.length&&(e=void 0),{value:e&&e[n++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")}function k_(e,t){var r=typeof Symbol=="function"&&e[Symbol.iterator];if(!r)return e;var n=r.call(e),o,i=[],a;try{for(;(t===void 0||t-- >0)&&!(o=n.next()).done;)i.push(o.value)}catch(s){a={error:s}}finally{try{o&&!o.done&&(r=n.return)&&r.call(n)}finally{if(a)throw a.error}}return i}function D_(e,t,r){if(r||arguments.length===2)for(var n=0,o=t.length,i;n<o;n++)(i||!(n in t))&&(i||(i=Array.prototype.slice.call(t,0,n)),i[n]=t[n]);return e.concat(i||Array.prototype.slice.call(t))}function Xn(e){return typeof e=="function"}function eF(e){var t=function(n){Error.call(n),n.stack=new Error().stack},r=e(t);return r.prototype=Object.create(Error.prototype),r.prototype.constructor=r,r}var c0=eF(function(e){return function(r){e(this),this.message=r?r.length+` errors occurred during unsubscription:
|
|
86
|
+
`+r.map(function(n,o){return o+1+") "+n.toString()}).join(`
|
|
87
|
+
`):"",this.name="UnsubscriptionError",this.errors=r}});function M_(e,t){if(e){var r=e.indexOf(t);0<=r&&e.splice(r,1)}}var ff=(function(){function e(t){this.initialTeardown=t,this.closed=!1,this._parentage=null,this._finalizers=null}return e.prototype.unsubscribe=function(){var t,r,n,o,i;if(!this.closed){this.closed=!0;var a=this._parentage;if(a)if(this._parentage=null,Array.isArray(a))try{for(var s=A_(a),c=s.next();!c.done;c=s.next()){var u=c.value;u.remove(this)}}catch(g){t={error:g}}finally{try{c&&!c.done&&(r=s.return)&&r.call(s)}finally{if(t)throw t.error}}else a.remove(this);var d=this.initialTeardown;if(Xn(d))try{d()}catch(g){i=g instanceof c0?g.errors:[g]}var f=this._finalizers;if(f){this._finalizers=null;try{for(var h=A_(f),v=h.next();!v.done;v=h.next()){var b=v.value;try{oD(b)}catch(g){i=i??[],g instanceof c0?i=D_(D_([],k_(i)),k_(g.errors)):i.push(g)}}}catch(g){n={error:g}}finally{try{v&&!v.done&&(o=h.return)&&o.call(h)}finally{if(n)throw n.error}}}if(i)throw new c0(i)}},e.prototype.add=function(t){var r;if(t&&t!==this)if(this.closed)oD(t);else{if(t instanceof e){if(t.closed||t._hasParent(this))return;t._addParent(this)}(this._finalizers=(r=this._finalizers)!==null&&r!==void 0?r:[]).push(t)}},e.prototype._hasParent=function(t){var r=this._parentage;return r===t||Array.isArray(r)&&r.includes(t)},e.prototype._addParent=function(t){var r=this._parentage;this._parentage=Array.isArray(r)?(r.push(t),r):r?[r,t]:t},e.prototype._removeParent=function(t){var r=this._parentage;r===t?this._parentage=null:Array.isArray(r)&&M_(r,t)},e.prototype.remove=function(t){var r=this._finalizers;r&&M_(r,t),t instanceof e&&t._removeParent(this)},e.EMPTY=(function(){var t=new e;return t.closed=!0,t})(),e})(),tF=ff.EMPTY;function rF(e){return e instanceof ff||e&&"closed"in e&&Xn(e.remove)&&Xn(e.add)&&Xn(e.unsubscribe)}function oD(e){Xn(e)?e():e.unsubscribe()}var gae={Promise:void 0},mae={setTimeout:function(e,t){for(var r=[],n=2;n<arguments.length;n++)r[n-2]=arguments[n];return setTimeout.apply(void 0,D_([e,t],k_(r)))},clearTimeout:function(e){return clearTimeout(e)},delegate:void 0};function bae(e){mae.setTimeout(function(){throw e})}function iD(){}function qu(e){e()}var K1=(function(e){kl(t,e);function t(r){var n=e.call(this)||this;return n.isStopped=!1,r?(n.destination=r,rF(r)&&r.add(n)):n.destination=wae,n}return t.create=function(r,n,o){return new j_(r,n,o)},t.prototype.next=function(r){this.isStopped||this._next(r)},t.prototype.error=function(r){this.isStopped||(this.isStopped=!0,this._error(r))},t.prototype.complete=function(){this.isStopped||(this.isStopped=!0,this._complete())},t.prototype.unsubscribe=function(){this.closed||(this.isStopped=!0,e.prototype.unsubscribe.call(this),this.destination=null)},t.prototype._next=function(r){this.destination.next(r)},t.prototype._error=function(r){try{this.destination.error(r)}finally{this.unsubscribe()}},t.prototype._complete=function(){try{this.destination.complete()}finally{this.unsubscribe()}},t})(ff),yae=(function(){function e(t){this.partialObserver=t}return e.prototype.next=function(t){var r=this.partialObserver;if(r.next)try{r.next(t)}catch(n){du(n)}},e.prototype.error=function(t){var r=this.partialObserver;if(r.error)try{r.error(t)}catch(n){du(n)}else du(t)},e.prototype.complete=function(){var t=this.partialObserver;if(t.complete)try{t.complete()}catch(r){du(r)}},e})(),j_=(function(e){kl(t,e);function t(r,n,o){var i=e.call(this)||this,a;return Xn(r)||!r?a={next:r??void 0,error:n??void 0,complete:o??void 0}:a=r,i.destination=new yae(a),i}return t})(K1);function du(e){bae(e)}function xae(e){throw e}var wae={closed:!0,next:iD,error:xae,complete:iD},_ae=(function(){return typeof Symbol=="function"&&Symbol.observable||"@@observable"})();function Eae(e){return e}function Sae(e){return e.length===0?Eae:e.length===1?e[0]:function(r){return e.reduce(function(n,o){return o(n)},r)}}var aD=(function(){function e(t){t&&(this._subscribe=t)}return e.prototype.lift=function(t){var r=new e;return r.source=this,r.operator=t,r},e.prototype.subscribe=function(t,r,n){var o=this,i=Cae(t)?t:new j_(t,r,n);return qu(function(){var a=o,s=a.operator,c=a.source;i.add(s?s.call(i,c):c?o._subscribe(i):o._trySubscribe(i))}),i},e.prototype._trySubscribe=function(t){try{return this._subscribe(t)}catch(r){t.error(r)}},e.prototype.forEach=function(t,r){var n=this;return r=sD(r),new r(function(o,i){var a=new j_({next:function(s){try{t(s)}catch(c){i(c),a.unsubscribe()}},error:i,complete:o});n.subscribe(a)})},e.prototype._subscribe=function(t){var r;return(r=this.source)===null||r===void 0?void 0:r.subscribe(t)},e.prototype[_ae]=function(){return this},e.prototype.pipe=function(){for(var t=[],r=0;r<arguments.length;r++)t[r]=arguments[r];return Sae(t)(this)},e.prototype.toPromise=function(t){var r=this;return t=sD(t),new t(function(n,o){var i;r.subscribe(function(a){return i=a},function(a){return o(a)},function(){return n(i)})})},e.create=function(t){return new e(t)},e})();function sD(e){var t;return(t=e??gae.Promise)!==null&&t!==void 0?t:Promise}function Oae(e){return e&&Xn(e.next)&&Xn(e.error)&&Xn(e.complete)}function Cae(e){return e&&e instanceof K1||Oae(e)&&rF(e)}function Rae(e){return Xn(e==null?void 0:e.lift)}function Nae(e){return function(t){if(Rae(t))return t.lift(function(r){try{return e(r,this)}catch(n){this.error(n)}});throw new TypeError("Unable to lift unknown Observable type")}}function Iae(e,t,r,n,o){return new Pae(e,t,r,n,o)}var Pae=(function(e){kl(t,e);function t(r,n,o,i,a,s){var c=e.call(this,r)||this;return c.onFinalize=a,c.shouldUnsubscribe=s,c._next=n?function(u){try{n(u)}catch(d){r.error(d)}}:e.prototype._next,c._error=i?function(u){try{i(u)}catch(d){r.error(d)}finally{this.unsubscribe()}}:e.prototype._error,c._complete=o?function(){try{o()}catch(u){r.error(u)}finally{this.unsubscribe()}}:e.prototype._complete,c}return t.prototype.unsubscribe=function(){var r;if(!this.shouldUnsubscribe||this.shouldUnsubscribe()){var n=this.closed;e.prototype.unsubscribe.call(this),!n&&((r=this.onFinalize)===null||r===void 0||r.call(this))}},t})(K1),Tae=eF(function(e){return function(){e(this),this.name="ObjectUnsubscribedError",this.message="object unsubscribed"}}),nF=(function(e){kl(t,e);function t(){var r=e.call(this)||this;return r.closed=!1,r.currentObservers=null,r.observers=[],r.isStopped=!1,r.hasError=!1,r.thrownError=null,r}return t.prototype.lift=function(r){var n=new lD(this,this);return n.operator=r,n},t.prototype._throwIfClosed=function(){if(this.closed)throw new Tae},t.prototype.next=function(r){var n=this;qu(function(){var o,i;if(n._throwIfClosed(),!n.isStopped){n.currentObservers||(n.currentObservers=Array.from(n.observers));try{for(var a=A_(n.currentObservers),s=a.next();!s.done;s=a.next()){var c=s.value;c.next(r)}}catch(u){o={error:u}}finally{try{s&&!s.done&&(i=a.return)&&i.call(a)}finally{if(o)throw o.error}}}})},t.prototype.error=function(r){var n=this;qu(function(){if(n._throwIfClosed(),!n.isStopped){n.hasError=n.isStopped=!0,n.thrownError=r;for(var o=n.observers;o.length;)o.shift().error(r)}})},t.prototype.complete=function(){var r=this;qu(function(){if(r._throwIfClosed(),!r.isStopped){r.isStopped=!0;for(var n=r.observers;n.length;)n.shift().complete()}})},t.prototype.unsubscribe=function(){this.isStopped=this.closed=!0,this.observers=this.currentObservers=null},Object.defineProperty(t.prototype,"observed",{get:function(){var r;return((r=this.observers)===null||r===void 0?void 0:r.length)>0},enumerable:!1,configurable:!0}),t.prototype._trySubscribe=function(r){return this._throwIfClosed(),e.prototype._trySubscribe.call(this,r)},t.prototype._subscribe=function(r){return this._throwIfClosed(),this._checkFinalizedStatuses(r),this._innerSubscribe(r)},t.prototype._innerSubscribe=function(r){var n=this,o=this,i=o.hasError,a=o.isStopped,s=o.observers;return i||a?tF:(this.currentObservers=null,s.push(r),new ff(function(){n.currentObservers=null,M_(s,r)}))},t.prototype._checkFinalizedStatuses=function(r){var n=this,o=n.hasError,i=n.thrownError,a=n.isStopped;o?r.error(i):a&&r.complete()},t.prototype.asObservable=function(){var r=new aD;return r.source=this,r},t.create=function(r,n){return new lD(r,n)},t})(aD),lD=(function(e){kl(t,e);function t(r,n){var o=e.call(this)||this;return o.destination=r,o.source=n,o}return t.prototype.next=function(r){var n,o;(o=(n=this.destination)===null||n===void 0?void 0:n.next)===null||o===void 0||o.call(n,r)},t.prototype.error=function(r){var n,o;(o=(n=this.destination)===null||n===void 0?void 0:n.error)===null||o===void 0||o.call(n,r)},t.prototype.complete=function(){var r,n;(n=(r=this.destination)===null||r===void 0?void 0:r.complete)===null||n===void 0||n.call(r)},t.prototype._subscribe=function(r){var n,o;return(o=(n=this.source)===null||n===void 0?void 0:n.subscribe(r))!==null&&o!==void 0?o:tF},t})(nF);function Aae(e,t){return Nae(function(r,n){var o=0;r.subscribe(Iae(n,function(i){return e.call(t,i,o++)&&n.next(i)}))})}var u0={},Ss={},fu={},cD;function oF(){if(cD)return fu;cD=1,Object.defineProperty(fu,"__esModule",{value:!0}),fu.default=r;let e;const t=new Uint8Array(16);function r(){if(!e&&(e=typeof crypto<"u"&&crypto.getRandomValues&&crypto.getRandomValues.bind(crypto),!e))throw new Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");return e(t)}return fu}var ia={},Os={},Cs={},uD;function kae(){if(uD)return Cs;uD=1,Object.defineProperty(Cs,"__esModule",{value:!0}),Cs.default=void 0;var e=/^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000)$/i;return Cs.default=e,Cs}var dD;function pf(){if(dD)return Os;dD=1,Object.defineProperty(Os,"__esModule",{value:!0}),Os.default=void 0;var e=t(kae());function t(o){return o&&o.__esModule?o:{default:o}}function r(o){return typeof o=="string"&&e.default.test(o)}var n=r;return Os.default=n,Os}var fD;function hf(){if(fD)return ia;fD=1,Object.defineProperty(ia,"__esModule",{value:!0}),ia.default=void 0,ia.unsafeStringify=n;var e=t(pf());function t(a){return a&&a.__esModule?a:{default:a}}const r=[];for(let a=0;a<256;++a)r.push((a+256).toString(16).slice(1));function n(a,s=0){return r[a[s+0]]+r[a[s+1]]+r[a[s+2]]+r[a[s+3]]+"-"+r[a[s+4]]+r[a[s+5]]+"-"+r[a[s+6]]+r[a[s+7]]+"-"+r[a[s+8]]+r[a[s+9]]+"-"+r[a[s+10]]+r[a[s+11]]+r[a[s+12]]+r[a[s+13]]+r[a[s+14]]+r[a[s+15]]}function o(a,s=0){const c=n(a,s);if(!(0,e.default)(c))throw TypeError("Stringified UUID is invalid");return c}var i=o;return ia.default=i,ia}var pD;function Dae(){if(pD)return Ss;pD=1,Object.defineProperty(Ss,"__esModule",{value:!0}),Ss.default=void 0;var e=r(oF()),t=hf();function r(u){return u&&u.__esModule?u:{default:u}}let n,o,i=0,a=0;function s(u,d,f){let h=d&&f||0;const v=d||new Array(16);u=u||{};let b=u.node||n,g=u.clockseq!==void 0?u.clockseq:o;if(b==null||g==null){const _=u.random||(u.rng||e.default)();b==null&&(b=n=[_[0]|1,_[1],_[2],_[3],_[4],_[5]]),g==null&&(g=o=(_[6]<<8|_[7])&16383)}let m=u.msecs!==void 0?u.msecs:Date.now(),x=u.nsecs!==void 0?u.nsecs:a+1;const w=m-i+(x-a)/1e4;if(w<0&&u.clockseq===void 0&&(g=g+1&16383),(w<0||m>i)&&u.nsecs===void 0&&(x=0),x>=1e4)throw new Error("uuid.v1(): Can't create more than 10M uuids/sec");i=m,a=x,o=g,m+=122192928e5;const E=((m&268435455)*1e4+x)%4294967296;v[h++]=E>>>24&255,v[h++]=E>>>16&255,v[h++]=E>>>8&255,v[h++]=E&255;const S=m/4294967296*1e4&268435455;v[h++]=S>>>8&255,v[h++]=S&255,v[h++]=S>>>24&15|16,v[h++]=S>>>16&255,v[h++]=g>>>8|128,v[h++]=g&255;for(let _=0;_<6;++_)v[h+_]=b[_];return d||(0,t.unsafeStringify)(v)}var c=s;return Ss.default=c,Ss}var Rs={},Fo={},Ns={},hD;function iF(){if(hD)return Ns;hD=1,Object.defineProperty(Ns,"__esModule",{value:!0}),Ns.default=void 0;var e=t(pf());function t(o){return o&&o.__esModule?o:{default:o}}function r(o){if(!(0,e.default)(o))throw TypeError("Invalid UUID");let i;const a=new Uint8Array(16);return a[0]=(i=parseInt(o.slice(0,8),16))>>>24,a[1]=i>>>16&255,a[2]=i>>>8&255,a[3]=i&255,a[4]=(i=parseInt(o.slice(9,13),16))>>>8,a[5]=i&255,a[6]=(i=parseInt(o.slice(14,18),16))>>>8,a[7]=i&255,a[8]=(i=parseInt(o.slice(19,23),16))>>>8,a[9]=i&255,a[10]=(i=parseInt(o.slice(24,36),16))/1099511627776&255,a[11]=i/4294967296&255,a[12]=i>>>24&255,a[13]=i>>>16&255,a[14]=i>>>8&255,a[15]=i&255,a}var n=r;return Ns.default=n,Ns}var vD;function aF(){if(vD)return Fo;vD=1,Object.defineProperty(Fo,"__esModule",{value:!0}),Fo.URL=Fo.DNS=void 0,Fo.default=a;var e=hf(),t=r(iF());function r(s){return s&&s.__esModule?s:{default:s}}function n(s){s=unescape(encodeURIComponent(s));const c=[];for(let u=0;u<s.length;++u)c.push(s.charCodeAt(u));return c}const o="6ba7b810-9dad-11d1-80b4-00c04fd430c8";Fo.DNS=o;const i="6ba7b811-9dad-11d1-80b4-00c04fd430c8";Fo.URL=i;function a(s,c,u){function d(f,h,v,b){var g;if(typeof f=="string"&&(f=n(f)),typeof h=="string"&&(h=(0,t.default)(h)),((g=h)===null||g===void 0?void 0:g.length)!==16)throw TypeError("Namespace must be array-like (16 iterable integer values, 0-255)");let m=new Uint8Array(16+f.length);if(m.set(h),m.set(f,h.length),m=u(m),m[6]=m[6]&15|c,m[8]=m[8]&63|128,v){b=b||0;for(let x=0;x<16;++x)v[b+x]=m[x];return v}return(0,e.unsafeStringify)(m)}try{d.name=s}catch{}return d.DNS=o,d.URL=i,d}return Fo}var Is={},gD;function Mae(){if(gD)return Is;gD=1,Object.defineProperty(Is,"__esModule",{value:!0}),Is.default=void 0;function e(v){if(typeof v=="string"){const b=unescape(encodeURIComponent(v));v=new Uint8Array(b.length);for(let g=0;g<b.length;++g)v[g]=b.charCodeAt(g)}return t(n(o(v),v.length*8))}function t(v){const b=[],g=v.length*32,m="0123456789abcdef";for(let x=0;x<g;x+=8){const w=v[x>>5]>>>x%32&255,E=parseInt(m.charAt(w>>>4&15)+m.charAt(w&15),16);b.push(E)}return b}function r(v){return(v+64>>>9<<4)+14+1}function n(v,b){v[b>>5]|=128<<b%32,v[r(b)-1]=b;let g=1732584193,m=-271733879,x=-1732584194,w=271733878;for(let E=0;E<v.length;E+=16){const S=g,_=m,C=x,N=w;g=c(g,m,x,w,v[E],7,-680876936),w=c(w,g,m,x,v[E+1],12,-389564586),x=c(x,w,g,m,v[E+2],17,606105819),m=c(m,x,w,g,v[E+3],22,-1044525330),g=c(g,m,x,w,v[E+4],7,-176418897),w=c(w,g,m,x,v[E+5],12,1200080426),x=c(x,w,g,m,v[E+6],17,-1473231341),m=c(m,x,w,g,v[E+7],22,-45705983),g=c(g,m,x,w,v[E+8],7,1770035416),w=c(w,g,m,x,v[E+9],12,-1958414417),x=c(x,w,g,m,v[E+10],17,-42063),m=c(m,x,w,g,v[E+11],22,-1990404162),g=c(g,m,x,w,v[E+12],7,1804603682),w=c(w,g,m,x,v[E+13],12,-40341101),x=c(x,w,g,m,v[E+14],17,-1502002290),m=c(m,x,w,g,v[E+15],22,1236535329),g=u(g,m,x,w,v[E+1],5,-165796510),w=u(w,g,m,x,v[E+6],9,-1069501632),x=u(x,w,g,m,v[E+11],14,643717713),m=u(m,x,w,g,v[E],20,-373897302),g=u(g,m,x,w,v[E+5],5,-701558691),w=u(w,g,m,x,v[E+10],9,38016083),x=u(x,w,g,m,v[E+15],14,-660478335),m=u(m,x,w,g,v[E+4],20,-405537848),g=u(g,m,x,w,v[E+9],5,568446438),w=u(w,g,m,x,v[E+14],9,-1019803690),x=u(x,w,g,m,v[E+3],14,-187363961),m=u(m,x,w,g,v[E+8],20,1163531501),g=u(g,m,x,w,v[E+13],5,-1444681467),w=u(w,g,m,x,v[E+2],9,-51403784),x=u(x,w,g,m,v[E+7],14,1735328473),m=u(m,x,w,g,v[E+12],20,-1926607734),g=d(g,m,x,w,v[E+5],4,-378558),w=d(w,g,m,x,v[E+8],11,-2022574463),x=d(x,w,g,m,v[E+11],16,1839030562),m=d(m,x,w,g,v[E+14],23,-35309556),g=d(g,m,x,w,v[E+1],4,-1530992060),w=d(w,g,m,x,v[E+4],11,1272893353),x=d(x,w,g,m,v[E+7],16,-155497632),m=d(m,x,w,g,v[E+10],23,-1094730640),g=d(g,m,x,w,v[E+13],4,681279174),w=d(w,g,m,x,v[E],11,-358537222),x=d(x,w,g,m,v[E+3],16,-722521979),m=d(m,x,w,g,v[E+6],23,76029189),g=d(g,m,x,w,v[E+9],4,-640364487),w=d(w,g,m,x,v[E+12],11,-421815835),x=d(x,w,g,m,v[E+15],16,530742520),m=d(m,x,w,g,v[E+2],23,-995338651),g=f(g,m,x,w,v[E],6,-198630844),w=f(w,g,m,x,v[E+7],10,1126891415),x=f(x,w,g,m,v[E+14],15,-1416354905),m=f(m,x,w,g,v[E+5],21,-57434055),g=f(g,m,x,w,v[E+12],6,1700485571),w=f(w,g,m,x,v[E+3],10,-1894986606),x=f(x,w,g,m,v[E+10],15,-1051523),m=f(m,x,w,g,v[E+1],21,-2054922799),g=f(g,m,x,w,v[E+8],6,1873313359),w=f(w,g,m,x,v[E+15],10,-30611744),x=f(x,w,g,m,v[E+6],15,-1560198380),m=f(m,x,w,g,v[E+13],21,1309151649),g=f(g,m,x,w,v[E+4],6,-145523070),w=f(w,g,m,x,v[E+11],10,-1120210379),x=f(x,w,g,m,v[E+2],15,718787259),m=f(m,x,w,g,v[E+9],21,-343485551),g=i(g,S),m=i(m,_),x=i(x,C),w=i(w,N)}return[g,m,x,w]}function o(v){if(v.length===0)return[];const b=v.length*8,g=new Uint32Array(r(b));for(let m=0;m<b;m+=8)g[m>>5]|=(v[m/8]&255)<<m%32;return g}function i(v,b){const g=(v&65535)+(b&65535);return(v>>16)+(b>>16)+(g>>16)<<16|g&65535}function a(v,b){return v<<b|v>>>32-b}function s(v,b,g,m,x,w){return i(a(i(i(b,v),i(m,w)),x),g)}function c(v,b,g,m,x,w,E){return s(b&g|~b&m,v,b,x,w,E)}function u(v,b,g,m,x,w,E){return s(b&m|g&~m,v,b,x,w,E)}function d(v,b,g,m,x,w,E){return s(b^g^m,v,b,x,w,E)}function f(v,b,g,m,x,w,E){return s(g^(b|~m),v,b,x,w,E)}var h=e;return Is.default=h,Is}var mD;function jae(){if(mD)return Rs;mD=1,Object.defineProperty(Rs,"__esModule",{value:!0}),Rs.default=void 0;var e=r(aF()),t=r(Mae());function r(i){return i&&i.__esModule?i:{default:i}}var o=(0,e.default)("v3",48,t.default);return Rs.default=o,Rs}var Ps={},Ts={},bD;function Lae(){if(bD)return Ts;bD=1,Object.defineProperty(Ts,"__esModule",{value:!0}),Ts.default=void 0;var t={randomUUID:typeof crypto<"u"&&crypto.randomUUID&&crypto.randomUUID.bind(crypto)};return Ts.default=t,Ts}var yD;function qae(){if(yD)return Ps;yD=1,Object.defineProperty(Ps,"__esModule",{value:!0}),Ps.default=void 0;var e=n(Lae()),t=n(oF()),r=hf();function n(a){return a&&a.__esModule?a:{default:a}}function o(a,s,c){if(e.default.randomUUID&&!s&&!a)return e.default.randomUUID();a=a||{};const u=a.random||(a.rng||t.default)();if(u[6]=u[6]&15|64,u[8]=u[8]&63|128,s){c=c||0;for(let d=0;d<16;++d)s[c+d]=u[d];return s}return(0,r.unsafeStringify)(u)}var i=o;return Ps.default=i,Ps}var As={},ks={},xD;function zae(){if(xD)return ks;xD=1,Object.defineProperty(ks,"__esModule",{value:!0}),ks.default=void 0;function e(o,i,a,s){switch(o){case 0:return i&a^~i&s;case 1:return i^a^s;case 2:return i&a^i&s^a&s;case 3:return i^a^s}}function t(o,i){return o<<i|o>>>32-i}function r(o){const i=[1518500249,1859775393,2400959708,3395469782],a=[1732584193,4023233417,2562383102,271733878,3285377520];if(typeof o=="string"){const d=unescape(encodeURIComponent(o));o=[];for(let f=0;f<d.length;++f)o.push(d.charCodeAt(f))}else Array.isArray(o)||(o=Array.prototype.slice.call(o));o.push(128);const s=o.length/4+2,c=Math.ceil(s/16),u=new Array(c);for(let d=0;d<c;++d){const f=new Uint32Array(16);for(let h=0;h<16;++h)f[h]=o[d*64+h*4]<<24|o[d*64+h*4+1]<<16|o[d*64+h*4+2]<<8|o[d*64+h*4+3];u[d]=f}u[c-1][14]=(o.length-1)*8/Math.pow(2,32),u[c-1][14]=Math.floor(u[c-1][14]),u[c-1][15]=(o.length-1)*8&4294967295;for(let d=0;d<c;++d){const f=new Uint32Array(80);for(let x=0;x<16;++x)f[x]=u[d][x];for(let x=16;x<80;++x)f[x]=t(f[x-3]^f[x-8]^f[x-14]^f[x-16],1);let h=a[0],v=a[1],b=a[2],g=a[3],m=a[4];for(let x=0;x<80;++x){const w=Math.floor(x/20),E=t(h,5)+e(w,v,b,g)+m+i[w]+f[x]>>>0;m=g,g=b,b=t(v,30)>>>0,v=h,h=E}a[0]=a[0]+h>>>0,a[1]=a[1]+v>>>0,a[2]=a[2]+b>>>0,a[3]=a[3]+g>>>0,a[4]=a[4]+m>>>0}return[a[0]>>24&255,a[0]>>16&255,a[0]>>8&255,a[0]&255,a[1]>>24&255,a[1]>>16&255,a[1]>>8&255,a[1]&255,a[2]>>24&255,a[2]>>16&255,a[2]>>8&255,a[2]&255,a[3]>>24&255,a[3]>>16&255,a[3]>>8&255,a[3]&255,a[4]>>24&255,a[4]>>16&255,a[4]>>8&255,a[4]&255]}var n=r;return ks.default=n,ks}var wD;function Bae(){if(wD)return As;wD=1,Object.defineProperty(As,"__esModule",{value:!0}),As.default=void 0;var e=r(aF()),t=r(zae());function r(i){return i&&i.__esModule?i:{default:i}}var o=(0,e.default)("v5",80,t.default);return As.default=o,As}var Ds={},_D;function Fae(){if(_D)return Ds;_D=1,Object.defineProperty(Ds,"__esModule",{value:!0}),Ds.default=void 0;var e="00000000-0000-0000-0000-000000000000";return Ds.default=e,Ds}var Ms={},ED;function $ae(){if(ED)return Ms;ED=1,Object.defineProperty(Ms,"__esModule",{value:!0}),Ms.default=void 0;var e=t(pf());function t(o){return o&&o.__esModule?o:{default:o}}function r(o){if(!(0,e.default)(o))throw TypeError("Invalid UUID");return parseInt(o.slice(14,15),16)}var n=r;return Ms.default=n,Ms}var SD;function Vae(){return SD||(SD=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),Object.defineProperty(e,"NIL",{enumerable:!0,get:function(){return i.default}}),Object.defineProperty(e,"parse",{enumerable:!0,get:function(){return u.default}}),Object.defineProperty(e,"stringify",{enumerable:!0,get:function(){return c.default}}),Object.defineProperty(e,"v1",{enumerable:!0,get:function(){return t.default}}),Object.defineProperty(e,"v3",{enumerable:!0,get:function(){return r.default}}),Object.defineProperty(e,"v4",{enumerable:!0,get:function(){return n.default}}),Object.defineProperty(e,"v5",{enumerable:!0,get:function(){return o.default}}),Object.defineProperty(e,"validate",{enumerable:!0,get:function(){return s.default}}),Object.defineProperty(e,"version",{enumerable:!0,get:function(){return a.default}});var t=d(Dae()),r=d(jae()),n=d(qae()),o=d(Bae()),i=d(Fae()),a=d($ae()),s=d(pf()),c=d(hf()),u=d(iF());function d(f){return f&&f.__esModule?f:{default:f}}})(u0)),u0}var d0,OD;function Hae(){if(OD)return d0;OD=1;function e(t,r){if(!t||!r||!t.length||!r.length)throw new Error("Bad alphabet");this.srcAlphabet=t,this.dstAlphabet=r}return e.prototype.convert=function(t){var r,n,o,i={},a=this.srcAlphabet.length,s=this.dstAlphabet.length,c=t.length,u=typeof t=="string"?"":[];if(!this.isValid(t))throw new Error('Number "'+t+'" contains of non-alphabetic digits ('+this.srcAlphabet+")");if(this.srcAlphabet===this.dstAlphabet)return t;for(r=0;r<c;r++)i[r]=this.srcAlphabet.indexOf(t[r]);do{for(n=0,o=0,r=0;r<c;r++)n=n*a+i[r],n>=s?(i[o++]=parseInt(n/s,10),n=n%s):o>0&&(i[o++]=0);c=o,u=this.dstAlphabet.slice(n,n+1).concat(u)}while(o!==0);return u},e.prototype.isValid=function(t){for(var r=0;r<t.length;++r)if(this.srcAlphabet.indexOf(t[r])===-1)return!1;return!0},d0=e,d0}var f0,CD;function Wae(){if(CD)return f0;CD=1;var e=Hae();function t(r,n){var o=new e(r,n);return function(i){return o.convert(i)}}return t.BIN="01",t.OCT="01234567",t.DEC="0123456789",t.HEX="0123456789abcdef",f0=t,f0}var p0,RD;function Uae(){if(RD)return p0;RD=1;const{v4:e,validate:t}=Vae(),r=Wae(),n={cookieBase90:"0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ!#$%&'()*+-./:<=>?@[]^_`{|}~",flickrBase58:"123456789abcdefghijkmnopqrstuvwxyzABCDEFGHJKLMNPQRSTUVWXYZ",uuid25Base36:"0123456789abcdefghijklmnopqrstuvwxyz"},o={consistentLength:!0};let i;const a=(u,d,f)=>{const h=d(u.toLowerCase().replace(/-/g,""));return!f||!f.consistentLength?h:h.padStart(f.shortIdLength,f.paddingChar)},s=(u,d)=>{const h=d(u).padStart(32,"0").match(/(\w{8})(\w{4})(\w{4})(\w{4})(\w{12})/);return[h[1],h[2],h[3],h[4],h[5]].join("-")},c=u=>Math.ceil(Math.log(2**128)/Math.log(u));return p0=(()=>{const u=(d,f)=>{const h=d||n.flickrBase58,v={...o,...f};if([...new Set(Array.from(h))].length!==h.length)throw new Error("The provided Alphabet has duplicate characters resulting in unreliable results");const b=c(h.length),g={shortIdLength:b,consistentLength:v.consistentLength,paddingChar:h[0]},m=r(r.HEX,h),x=r(h,r.HEX),w=()=>a(e(),m,g),S={alphabet:h,fromUUID:_=>a(_,m,g),maxLength:b,generate:w,new:w,toUUID:_=>s(_,x),uuid:e,validate:(_,C=!1)=>{if(!_||typeof _!="string")return!1;const N=v.consistentLength?_.length===b:_.length<=b,P=_.split("").every(A=>h.includes(A));return C===!1?N&&P:N&&P&&t(s(_,x))}};return Object.freeze(S),S};return u.constants=n,u.uuid=e,u.generate=()=>(i||(i=u(n.flickrBase58).generate),i()),u})(),p0}var sF=Uae();const lF=new nF;function Gae(e,t){switch(t.type){case"UPDATE_ROLES":return{...e,roles:t.payload,flags:{...e.flags,touched:!0}};case"UPDATE_PRIVILEGES":return{...e,privileges:t.payload,flags:{...e.flags,touched:!0}};case"SET_ROLES_CONTENT":{const{content:r,flags:n={},...o}=t.payload,i=he.sanitizeRoles(r),a={...e.flags,...n};return{...e,...i,...o,flags:a}}case"TOGGLE_TAB":return{...e,selectedTab:t.payload};case"TOGGLE_FORCE_LOGIN":return e.forceLogin===t.payload?e:{...e,forceLogin:t.payload,flags:{...e.flags,touched:!0}};case"TOGGLE_RESTRICTED_BY_DEFAULT":return e.restrictedByDefault===t.payload?e:{...e,restrictedByDefault:t.payload,flags:{...e.flags,touched:!0}};case"SET_FLAGS":return{...e,flags:{...e.flags,...t.payload}};case"CREATE_MODAL":return{...e,modals:{...e.modals,list:[...e.modals.list,t.payload]}};case"REMOVE_MODAL":return{...e,modals:{...e.modals,list:e.modals.list.filter(r=>r.id!==t.payload)}};case"CLOSE_MODAL":{const{id:r,reason:n}=t.payload;let o;if(n)if(e.modals.list.find(a=>a.id===r))o={...e,modals:{...e.modals,list:e.modals.list.map(a=>a.id===r?{...a,closeReason:n,isOpen:!1}:a)}};else return e;else o={...e,modals:{...e.modals,list:e.modals.list.filter(i=>i.id!==r)}};return lF.next(o.modals),o}case"EDIT_MODAL":{const{id:r,...n}=t.payload;return e.modals.list.find(i=>i.id===r)?{...e,modals:{...e.modals,list:e.modals.list.map(i=>i.id===r?{...i,...n}:i)}}:e}default:return e}}const X1=R.createContext(null),Yae=()=>({roles:{},privileges:{},flags:{touched:!1},date:void 0,selectedTab:"roles",forceLogin:!1,restrictedByDefault:!1,modals:{list:[]}}),Kae=({children:e,catalog:t=null,qodly:r=!1,catalogMethods:n=[],dataclasses:o={},singletons:i={},onSetTabFlags:a,initialState:s})=>{const[c,u]=R.useReducer(Gae,{...Yae(),...s}),d=R.useMemo(()=>({catalog:t,qodly:r,catalogMethods:n,dataclasses:o,singletons:i,onSetTabFlags:a}),[t,r,n,o,i,a]);return O.jsx(X1.Provider,{value:{state:c,dispatch:u,external:d},children:e})};function Xae(){const e=R.useContext(X1);if(!e)throw new Error("useReducerAdapter must be used within a ReducerAdapterProvider");const{state:t,dispatch:r,external:n}=e,o=R.useMemo(()=>he.rolesToAPI({roles:t.roles,privileges:t.privileges,forceLogin:t.forceLogin,restrictedByDefault:t.restrictedByDefault}),[t.roles,t.privileges,t.forceLogin,t.restrictedByDefault]);return{getRoles:R.useCallback(()=>t.roles,[t.roles]),getPrivileges:R.useCallback(()=>t.privileges,[t.privileges]),getRolesFlags:R.useCallback(()=>t.flags,[t.flags]),getRolesAndPrivileges:R.useCallback(()=>o,[o]),getCatalog:R.useCallback(()=>n.catalog??null,[n.catalog]),getQodly:R.useCallback(()=>n.qodly??!1,[n.qodly]),getSelectedTab:R.useCallback(()=>t.selectedTab,[t.selectedTab]),getForceLogin:R.useCallback(()=>t.forceLogin??!1,[t.forceLogin]),getRestrictedByDefault:R.useCallback(()=>t.restrictedByDefault??!1,[t.restrictedByDefault]),getGuestPrivilege:R.useCallback(()=>Object.values(t.privileges).find(({privilege:i})=>i==="guest")??null,[t.privileges]),getCatalogMethods:R.useCallback(()=>n.catalogMethods??[],[n.catalogMethods]),getDataclasses:R.useCallback(()=>n.dataclasses??{},[n.dataclasses]),getSingletons:R.useCallback(()=>n.singletons??{},[n.singletons]),actions:{updateRoles:R.useCallback(i=>{r({type:"UPDATE_ROLES",payload:i})},[]),updatePrivileges:R.useCallback(i=>{r({type:"UPDATE_PRIVILEGES",payload:i})},[]),setRolesContent:R.useCallback(i=>{r({type:"SET_ROLES_CONTENT",payload:i})},[]),toggleTab:R.useCallback(i=>{r({type:"TOGGLE_TAB",payload:i})},[]),toggleForceLogin:R.useCallback(i=>{r({type:"TOGGLE_FORCE_LOGIN",payload:i})},[]),toggleRestrictedByDefault:R.useCallback(i=>{r({type:"TOGGLE_RESTRICTED_BY_DEFAULT",payload:i})},[]),setTabFlags:R.useCallback((i,a)=>{n.onSetTabFlags&&n.onSetTabFlags(i,a)},[n.onSetTabFlags]),openModal:R.useCallback(async i=>{const{type:a=he.ModalType.ALERT}=i,s=sF.generate();return r({type:"CREATE_MODAL",payload:{id:s,type:a,isOpen:!0,...i}}),a===he.ModalType.CONFIRM?new Promise(c=>{const u=lF.pipe(Aae(d=>{const f=d.list.find(h=>h.id===s);return f!==void 0&&!f.isOpen})).subscribe(d=>{var h;const f=d.list.find(v=>v.id===s);if(f){const v=f.closeReason===he.ModalCloseReason.CONFIRMED,b=Al.entries(((h=f.views)==null?void 0:h.toggles)||{}).reduce((g,m)=>({...g,[m[0]]:m[1].value}),{});r({type:"REMOVE_MODAL",payload:s}),u.unsubscribe(),c({confirmed:v,options:b})}})}):{confirmed:!1}},[r])}}}function Zae(){const e=R.useContext(X1);if(!e)throw new Error("useModals must be used within a ReducerAdapterProvider");const{state:t,dispatch:r}=e;return{modals:t.modals.list,closeModal:R.useCallback(n=>{r({type:"CLOSE_MODAL",payload:n})},[r]),editModal:R.useCallback(n=>{r({type:"EDIT_MODAL",payload:n})},[r]),removeModal:R.useCallback(n=>{r({type:"REMOVE_MODAL",payload:n})},[r])}}const h0=({child:e,parent:t,status:r,onSelect:n,currentPrivilegeId:o})=>{const i=dr(),a=i.getPrivileges();function s(){const u=he.addPrivilegeIn(t.id,e.id,a);i.actions.updatePrivileges(u)}function c(){const u=he.removePrivilegeFrom(t.id,e.id,a);i.actions.updatePrivileges(u)}return O.jsxs("div",{className:zt("inline-flex cursor-pointer items-center gap-1 space-x-1 rounded px-2 py-0.5",{"bg-primary-dark text-white":r==="included","bg-grey-300 text-grey-100":r!=="included","opacity-40":r==="disabled"}),children:[O.jsx("span",{onClick:()=>n(o),className:"text-xs hover:underline",children:e.privilege}),r==="included"?O.jsx("button",{onClick:c,children:O.jsx("span",{className:"text-[13px]",children:O.jsx(_e.FdPlus,{className:"rotate-45 transform text-white"})})}):O.jsx("button",{disabled:r==="disabled",onClick:s,className:"opacity-70 disabled:cursor-not-allowed",children:O.jsx("span",{className:"text-[13px]",children:O.jsx(_e.FdPlus,{className:"text-white"})})})]})},Jae=({selectedPrivilege:e,privileges:t,onSelect:r,setShowIncluded:n,showIncluded:o})=>{const i=Object.values(t),a=he.getPrivilegeById(e.id,t);let s=a?he.populateShallow(a.includes,t):[],c=a?he.populateShallow(he.parents(a.id,t),t):[],u=a?he.populateShallow(he.allowed(a.id,t),t):[];return[s,c,u]=[s,c,u].map(d=>d.filter(f=>(f==null?void 0:f.privilege)!=="guest")),i.length<2&&s.length+c.length+u.length===0?null:O.jsxs("div",{className:"w-full border-b border-grey-900 p-4",children:[O.jsxs("div",{className:"mb-4 flex items-center justify-between",children:[" ",i.length>2?O.jsx("h4",{className:"text-[13px] font-semibold text-white",children:"Include a privilege"}):O.jsx("div",{}),O.jsxs("div",{className:"flex items-center gap-2",children:[O.jsx(Qu,{onChange:()=>n(!o),checked:o}),O.jsxs("label",{className:"text-xs text-[#F6F6F6]",children:[" ","Show inherited permissions"]})]})]}),O.jsxs("div",{className:"flex flex-wrap items-start justify-start gap-1",children:[s.map(d=>O.jsx(h0,{child:d,parent:e,status:"included",onSelect:r,currentPrivilegeId:d.id},d.id)),u.map(d=>O.jsx(h0,{child:d,parent:e,status:"available",onSelect:r,currentPrivilegeId:d.id},d.id)),c.map(d=>O.jsx(h0,{child:d,parent:e,status:"disabled",onSelect:r,currentPrivilegeId:d.id},d.id))]})]})};function cn(e,t,{checkForDefaultPrevented:r=!0}={}){return function(o){if(e==null||e(o),r===!1||!o.defaultPrevented)return t==null?void 0:t(o)}}function cF(e,t=[]){let r=[];function n(i,a){const s=ue.createContext(a),c=r.length;r=[...r,a];const u=f=>{var x;const{scope:h,children:v,...b}=f,g=((x=h==null?void 0:h[e])==null?void 0:x[c])||s,m=ue.useMemo(()=>b,Object.values(b));return O.jsx(g.Provider,{value:m,children:v})};u.displayName=i+"Provider";function d(f,h){var g;const v=((g=h==null?void 0:h[e])==null?void 0:g[c])||s,b=ue.useContext(v);if(b)return b;if(a!==void 0)return a;throw new Error(`\`${f}\` must be used within \`${i}\``)}return[u,d]}const o=()=>{const i=r.map(a=>ue.createContext(a));return function(s){const c=(s==null?void 0:s[e])||i;return ue.useMemo(()=>({[`__scope${e}`]:{...s,[e]:c}}),[s,c])}};return o.scopeName=e,[n,Qae(o,...t)]}function Qae(...e){const t=e[0];if(e.length===1)return t;const r=()=>{const n=e.map(o=>({useScope:o(),scopeName:o.scopeName}));return function(i){const a=n.reduce((s,{useScope:c,scopeName:u})=>{const f=c(i)[`__scope${u}`];return{...s,...f}},{});return ue.useMemo(()=>({[`__scope${t.scopeName}`]:a}),[a])}};return r.scopeName=t.scopeName,r}var Oi=globalThis!=null&&globalThis.document?ue.useLayoutEffect:()=>{},ese=ue[" useInsertionEffect ".trim().toString()]||Oi;function tse({prop:e,defaultProp:t,onChange:r=()=>{},caller:n}){const[o,i,a]=rse({defaultProp:t,onChange:r}),s=e!==void 0,c=s?e:o;{const d=ue.useRef(e!==void 0);ue.useEffect(()=>{const f=d.current;f!==s&&console.warn(`${n} is changing from ${f?"controlled":"uncontrolled"} to ${s?"controlled":"uncontrolled"}. Components should not switch from controlled to uncontrolled (or vice versa). Decide between using a controlled or uncontrolled value for the lifetime of the component.`),d.current=s},[s,n])}const u=ue.useCallback(d=>{var f;if(s){const h=nse(d)?d(e):d;h!==e&&((f=a.current)==null||f.call(a,h))}else i(d)},[s,e,i,a]);return[c,u]}function rse({defaultProp:e,onChange:t}){const[r,n]=ue.useState(e),o=ue.useRef(r),i=ue.useRef(t);return ese(()=>{i.current=t},[t]),ue.useEffect(()=>{var a;o.current!==r&&((a=i.current)==null||a.call(i,r),o.current=r)},[r,o]),[r,n,i]}function nse(e){return typeof e=="function"}function ND(e,t){if(typeof e=="function")return e(t);e!=null&&(e.current=t)}function uF(...e){return t=>{let r=!1;const n=e.map(o=>{const i=ND(o,t);return!r&&typeof i=="function"&&(r=!0),i});if(r)return()=>{for(let o=0;o<n.length;o++){const i=n[o];typeof i=="function"?i():ND(e[o],null)}}}}function Va(...e){return ue.useCallback(uF(...e),e)}const ose=["top","right","bottom","left"],Yo=Math.min,Wr=Math.max,gd=Math.round,pu=Math.floor,Zn=e=>({x:e,y:e}),ise={left:"right",right:"left",bottom:"top",top:"bottom"},ase={start:"end",end:"start"};function L_(e,t,r){return Wr(e,Yo(t,r))}function wo(e,t){return typeof e=="function"?e(t):e}function _o(e){return e.split("-")[0]}function Ha(e){return e.split("-")[1]}function Z1(e){return e==="x"?"y":"x"}function J1(e){return e==="y"?"height":"width"}const sse=new Set(["top","bottom"]);function Gn(e){return sse.has(_o(e))?"y":"x"}function Q1(e){return Z1(Gn(e))}function lse(e,t,r){r===void 0&&(r=!1);const n=Ha(e),o=Q1(e),i=J1(o);let a=o==="x"?n===(r?"end":"start")?"right":"left":n==="start"?"bottom":"top";return t.reference[i]>t.floating[i]&&(a=md(a)),[a,md(a)]}function cse(e){const t=md(e);return[q_(e),t,q_(t)]}function q_(e){return e.replace(/start|end/g,t=>ase[t])}const ID=["left","right"],PD=["right","left"],use=["top","bottom"],dse=["bottom","top"];function fse(e,t,r){switch(e){case"top":case"bottom":return r?t?PD:ID:t?ID:PD;case"left":case"right":return t?use:dse;default:return[]}}function pse(e,t,r,n){const o=Ha(e);let i=fse(_o(e),r==="start",n);return o&&(i=i.map(a=>a+"-"+o),t&&(i=i.concat(i.map(q_)))),i}function md(e){return e.replace(/left|right|bottom|top/g,t=>ise[t])}function hse(e){return{top:0,right:0,bottom:0,left:0,...e}}function dF(e){return typeof e!="number"?hse(e):{top:e,right:e,bottom:e,left:e}}function bd(e){const{x:t,y:r,width:n,height:o}=e;return{width:n,height:o,top:r,left:t,right:t+n,bottom:r+o,x:t,y:r}}function TD(e,t,r){let{reference:n,floating:o}=e;const i=Gn(t),a=Q1(t),s=J1(a),c=_o(t),u=i==="y",d=n.x+n.width/2-o.width/2,f=n.y+n.height/2-o.height/2,h=n[s]/2-o[s]/2;let v;switch(c){case"top":v={x:d,y:n.y-o.height};break;case"bottom":v={x:d,y:n.y+n.height};break;case"right":v={x:n.x+n.width,y:f};break;case"left":v={x:n.x-o.width,y:f};break;default:v={x:n.x,y:n.y}}switch(Ha(t)){case"start":v[a]-=h*(r&&u?-1:1);break;case"end":v[a]+=h*(r&&u?-1:1);break}return v}const vse=async(e,t,r)=>{const{placement:n="bottom",strategy:o="absolute",middleware:i=[],platform:a}=r,s=i.filter(Boolean),c=await(a.isRTL==null?void 0:a.isRTL(t));let u=await a.getElementRects({reference:e,floating:t,strategy:o}),{x:d,y:f}=TD(u,n,c),h=n,v={},b=0;for(let g=0;g<s.length;g++){const{name:m,fn:x}=s[g],{x:w,y:E,data:S,reset:_}=await x({x:d,y:f,initialPlacement:n,placement:h,strategy:o,middlewareData:v,rects:u,platform:a,elements:{reference:e,floating:t}});d=w??d,f=E??f,v={...v,[m]:{...v[m],...S}},_&&b<=50&&(b++,typeof _=="object"&&(_.placement&&(h=_.placement),_.rects&&(u=_.rects===!0?await a.getElementRects({reference:e,floating:t,strategy:o}):_.rects),{x:d,y:f}=TD(u,h,c)),g=-1)}return{x:d,y:f,placement:h,strategy:o,middlewareData:v}};async function pl(e,t){var r;t===void 0&&(t={});const{x:n,y:o,platform:i,rects:a,elements:s,strategy:c}=e,{boundary:u="clippingAncestors",rootBoundary:d="viewport",elementContext:f="floating",altBoundary:h=!1,padding:v=0}=wo(t,e),b=dF(v),m=s[h?f==="floating"?"reference":"floating":f],x=bd(await i.getClippingRect({element:(r=await(i.isElement==null?void 0:i.isElement(m)))==null||r?m:m.contextElement||await(i.getDocumentElement==null?void 0:i.getDocumentElement(s.floating)),boundary:u,rootBoundary:d,strategy:c})),w=f==="floating"?{x:n,y:o,width:a.floating.width,height:a.floating.height}:a.reference,E=await(i.getOffsetParent==null?void 0:i.getOffsetParent(s.floating)),S=await(i.isElement==null?void 0:i.isElement(E))?await(i.getScale==null?void 0:i.getScale(E))||{x:1,y:1}:{x:1,y:1},_=bd(i.convertOffsetParentRelativeRectToViewportRelativeRect?await i.convertOffsetParentRelativeRectToViewportRelativeRect({elements:s,rect:w,offsetParent:E,strategy:c}):w);return{top:(x.top-_.top+b.top)/S.y,bottom:(_.bottom-x.bottom+b.bottom)/S.y,left:(x.left-_.left+b.left)/S.x,right:(_.right-x.right+b.right)/S.x}}const gse=e=>({name:"arrow",options:e,async fn(t){const{x:r,y:n,placement:o,rects:i,platform:a,elements:s,middlewareData:c}=t,{element:u,padding:d=0}=wo(e,t)||{};if(u==null)return{};const f=dF(d),h={x:r,y:n},v=Q1(o),b=J1(v),g=await a.getDimensions(u),m=v==="y",x=m?"top":"left",w=m?"bottom":"right",E=m?"clientHeight":"clientWidth",S=i.reference[b]+i.reference[v]-h[v]-i.floating[b],_=h[v]-i.reference[v],C=await(a.getOffsetParent==null?void 0:a.getOffsetParent(u));let N=C?C[E]:0;(!N||!await(a.isElement==null?void 0:a.isElement(C)))&&(N=s.floating[E]||i.floating[b]);const P=S/2-_/2,A=N/2-g[b]/2-1,j=Yo(f[x],A),M=Yo(f[w],A),L=j,D=N-g[b]-M,T=N/2-g[b]/2+P,W=L_(L,T,D),q=!c.arrow&&Ha(o)!=null&&T!==W&&i.reference[b]/2-(T<L?j:M)-g[b]/2<0,G=q?T<L?T-L:T-D:0;return{[v]:h[v]+G,data:{[v]:W,centerOffset:T-W-G,...q&&{alignmentOffset:G}},reset:q}}}),mse=function(e){return e===void 0&&(e={}),{name:"flip",options:e,async fn(t){var r,n;const{placement:o,middlewareData:i,rects:a,initialPlacement:s,platform:c,elements:u}=t,{mainAxis:d=!0,crossAxis:f=!0,fallbackPlacements:h,fallbackStrategy:v="bestFit",fallbackAxisSideDirection:b="none",flipAlignment:g=!0,...m}=wo(e,t);if((r=i.arrow)!=null&&r.alignmentOffset)return{};const x=_o(o),w=Gn(s),E=_o(s)===s,S=await(c.isRTL==null?void 0:c.isRTL(u.floating)),_=h||(E||!g?[md(s)]:cse(s)),C=b!=="none";!h&&C&&_.push(...pse(s,g,b,S));const N=[s,..._],P=await pl(t,m),A=[];let j=((n=i.flip)==null?void 0:n.overflows)||[];if(d&&A.push(P[x]),f){const T=lse(o,a,S);A.push(P[T[0]],P[T[1]])}if(j=[...j,{placement:o,overflows:A}],!A.every(T=>T<=0)){var M,L;const T=(((M=i.flip)==null?void 0:M.index)||0)+1,W=N[T];if(W&&(!(f==="alignment"?w!==Gn(W):!1)||j.every(F=>Gn(F.placement)===w?F.overflows[0]>0:!0)))return{data:{index:T,overflows:j},reset:{placement:W}};let q=(L=j.filter(G=>G.overflows[0]<=0).sort((G,F)=>G.overflows[1]-F.overflows[1])[0])==null?void 0:L.placement;if(!q)switch(v){case"bestFit":{var D;const G=(D=j.filter(F=>{if(C){const J=Gn(F.placement);return J===w||J==="y"}return!0}).map(F=>[F.placement,F.overflows.filter(J=>J>0).reduce((J,z)=>J+z,0)]).sort((F,J)=>F[1]-J[1])[0])==null?void 0:D[0];G&&(q=G);break}case"initialPlacement":q=s;break}if(o!==q)return{reset:{placement:q}}}return{}}}};function AD(e,t){return{top:e.top-t.height,right:e.right-t.width,bottom:e.bottom-t.height,left:e.left-t.width}}function kD(e){return ose.some(t=>e[t]>=0)}const bse=function(e){return e===void 0&&(e={}),{name:"hide",options:e,async fn(t){const{rects:r}=t,{strategy:n="referenceHidden",...o}=wo(e,t);switch(n){case"referenceHidden":{const i=await pl(t,{...o,elementContext:"reference"}),a=AD(i,r.reference);return{data:{referenceHiddenOffsets:a,referenceHidden:kD(a)}}}case"escaped":{const i=await pl(t,{...o,altBoundary:!0}),a=AD(i,r.floating);return{data:{escapedOffsets:a,escaped:kD(a)}}}default:return{}}}}},fF=new Set(["left","top"]);async function yse(e,t){const{placement:r,platform:n,elements:o}=e,i=await(n.isRTL==null?void 0:n.isRTL(o.floating)),a=_o(r),s=Ha(r),c=Gn(r)==="y",u=fF.has(a)?-1:1,d=i&&c?-1:1,f=wo(t,e);let{mainAxis:h,crossAxis:v,alignmentAxis:b}=typeof f=="number"?{mainAxis:f,crossAxis:0,alignmentAxis:null}:{mainAxis:f.mainAxis||0,crossAxis:f.crossAxis||0,alignmentAxis:f.alignmentAxis};return s&&typeof b=="number"&&(v=s==="end"?b*-1:b),c?{x:v*d,y:h*u}:{x:h*u,y:v*d}}const xse=function(e){return e===void 0&&(e=0),{name:"offset",options:e,async fn(t){var r,n;const{x:o,y:i,placement:a,middlewareData:s}=t,c=await yse(t,e);return a===((r=s.offset)==null?void 0:r.placement)&&(n=s.arrow)!=null&&n.alignmentOffset?{}:{x:o+c.x,y:i+c.y,data:{...c,placement:a}}}}},wse=function(e){return e===void 0&&(e={}),{name:"shift",options:e,async fn(t){const{x:r,y:n,placement:o}=t,{mainAxis:i=!0,crossAxis:a=!1,limiter:s={fn:m=>{let{x,y:w}=m;return{x,y:w}}},...c}=wo(e,t),u={x:r,y:n},d=await pl(t,c),f=Gn(_o(o)),h=Z1(f);let v=u[h],b=u[f];if(i){const m=h==="y"?"top":"left",x=h==="y"?"bottom":"right",w=v+d[m],E=v-d[x];v=L_(w,v,E)}if(a){const m=f==="y"?"top":"left",x=f==="y"?"bottom":"right",w=b+d[m],E=b-d[x];b=L_(w,b,E)}const g=s.fn({...t,[h]:v,[f]:b});return{...g,data:{x:g.x-r,y:g.y-n,enabled:{[h]:i,[f]:a}}}}}},_se=function(e){return e===void 0&&(e={}),{options:e,fn(t){const{x:r,y:n,placement:o,rects:i,middlewareData:a}=t,{offset:s=0,mainAxis:c=!0,crossAxis:u=!0}=wo(e,t),d={x:r,y:n},f=Gn(o),h=Z1(f);let v=d[h],b=d[f];const g=wo(s,t),m=typeof g=="number"?{mainAxis:g,crossAxis:0}:{mainAxis:0,crossAxis:0,...g};if(c){const E=h==="y"?"height":"width",S=i.reference[h]-i.floating[E]+m.mainAxis,_=i.reference[h]+i.reference[E]-m.mainAxis;v<S?v=S:v>_&&(v=_)}if(u){var x,w;const E=h==="y"?"width":"height",S=fF.has(_o(o)),_=i.reference[f]-i.floating[E]+(S&&((x=a.offset)==null?void 0:x[f])||0)+(S?0:m.crossAxis),C=i.reference[f]+i.reference[E]+(S?0:((w=a.offset)==null?void 0:w[f])||0)-(S?m.crossAxis:0);b<_?b=_:b>C&&(b=C)}return{[h]:v,[f]:b}}}},Ese=function(e){return e===void 0&&(e={}),{name:"size",options:e,async fn(t){var r,n;const{placement:o,rects:i,platform:a,elements:s}=t,{apply:c=()=>{},...u}=wo(e,t),d=await pl(t,u),f=_o(o),h=Ha(o),v=Gn(o)==="y",{width:b,height:g}=i.floating;let m,x;f==="top"||f==="bottom"?(m=f,x=h===(await(a.isRTL==null?void 0:a.isRTL(s.floating))?"start":"end")?"left":"right"):(x=f,m=h==="end"?"top":"bottom");const w=g-d.top-d.bottom,E=b-d.left-d.right,S=Yo(g-d[m],w),_=Yo(b-d[x],E),C=!t.middlewareData.shift;let N=S,P=_;if((r=t.middlewareData.shift)!=null&&r.enabled.x&&(P=E),(n=t.middlewareData.shift)!=null&&n.enabled.y&&(N=w),C&&!h){const j=Wr(d.left,0),M=Wr(d.right,0),L=Wr(d.top,0),D=Wr(d.bottom,0);v?P=b-2*(j!==0||M!==0?j+M:Wr(d.left,d.right)):N=g-2*(L!==0||D!==0?L+D:Wr(d.top,d.bottom))}await c({...t,availableWidth:P,availableHeight:N});const A=await a.getDimensions(s.floating);return b!==A.width||g!==A.height?{reset:{rects:!0}}:{}}}};function vf(){return typeof window<"u"}function Wa(e){return pF(e)?(e.nodeName||"").toLowerCase():"#document"}function Ur(e){var t;return(e==null||(t=e.ownerDocument)==null?void 0:t.defaultView)||window}function ro(e){var t;return(t=(pF(e)?e.ownerDocument:e.document)||window.document)==null?void 0:t.documentElement}function pF(e){return vf()?e instanceof Node||e instanceof Ur(e).Node:!1}function An(e){return vf()?e instanceof Element||e instanceof Ur(e).Element:!1}function Qn(e){return vf()?e instanceof HTMLElement||e instanceof Ur(e).HTMLElement:!1}function DD(e){return!vf()||typeof ShadowRoot>"u"?!1:e instanceof ShadowRoot||e instanceof Ur(e).ShadowRoot}const Sse=new Set(["inline","contents"]);function Dl(e){const{overflow:t,overflowX:r,overflowY:n,display:o}=kn(e);return/auto|scroll|overlay|hidden|clip/.test(t+n+r)&&!Sse.has(o)}const Ose=new Set(["table","td","th"]);function Cse(e){return Ose.has(Wa(e))}const Rse=[":popover-open",":modal"];function gf(e){return Rse.some(t=>{try{return e.matches(t)}catch{return!1}})}const Nse=["transform","translate","scale","rotate","perspective"],Ise=["transform","translate","scale","rotate","perspective","filter"],Pse=["paint","layout","strict","content"];function eE(e){const t=tE(),r=An(e)?kn(e):e;return Nse.some(n=>r[n]?r[n]!=="none":!1)||(r.containerType?r.containerType!=="normal":!1)||!t&&(r.backdropFilter?r.backdropFilter!=="none":!1)||!t&&(r.filter?r.filter!=="none":!1)||Ise.some(n=>(r.willChange||"").includes(n))||Pse.some(n=>(r.contain||"").includes(n))}function Tse(e){let t=Ko(e);for(;Qn(t)&&!Pa(t);){if(eE(t))return t;if(gf(t))return null;t=Ko(t)}return null}function tE(){return typeof CSS>"u"||!CSS.supports?!1:CSS.supports("-webkit-backdrop-filter","none")}const Ase=new Set(["html","body","#document"]);function Pa(e){return Ase.has(Wa(e))}function kn(e){return Ur(e).getComputedStyle(e)}function mf(e){return An(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.scrollX,scrollTop:e.scrollY}}function Ko(e){if(Wa(e)==="html")return e;const t=e.assignedSlot||e.parentNode||DD(e)&&e.host||ro(e);return DD(t)?t.host:t}function hF(e){const t=Ko(e);return Pa(t)?e.ownerDocument?e.ownerDocument.body:e.body:Qn(t)&&Dl(t)?t:hF(t)}function hl(e,t,r){var n;t===void 0&&(t=[]),r===void 0&&(r=!0);const o=hF(e),i=o===((n=e.ownerDocument)==null?void 0:n.body),a=Ur(o);if(i){const s=z_(a);return t.concat(a,a.visualViewport||[],Dl(o)?o:[],s&&r?hl(s):[])}return t.concat(o,hl(o,[],r))}function z_(e){return e.parent&&Object.getPrototypeOf(e.parent)?e.frameElement:null}function vF(e){const t=kn(e);let r=parseFloat(t.width)||0,n=parseFloat(t.height)||0;const o=Qn(e),i=o?e.offsetWidth:r,a=o?e.offsetHeight:n,s=gd(r)!==i||gd(n)!==a;return s&&(r=i,n=a),{width:r,height:n,$:s}}function rE(e){return An(e)?e:e.contextElement}function ba(e){const t=rE(e);if(!Qn(t))return Zn(1);const r=t.getBoundingClientRect(),{width:n,height:o,$:i}=vF(t);let a=(i?gd(r.width):r.width)/n,s=(i?gd(r.height):r.height)/o;return(!a||!Number.isFinite(a))&&(a=1),(!s||!Number.isFinite(s))&&(s=1),{x:a,y:s}}const kse=Zn(0);function gF(e){const t=Ur(e);return!tE()||!t.visualViewport?kse:{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}}function Dse(e,t,r){return t===void 0&&(t=!1),!r||t&&r!==Ur(e)?!1:t}function Ci(e,t,r,n){t===void 0&&(t=!1),r===void 0&&(r=!1);const o=e.getBoundingClientRect(),i=rE(e);let a=Zn(1);t&&(n?An(n)&&(a=ba(n)):a=ba(e));const s=Dse(i,r,n)?gF(i):Zn(0);let c=(o.left+s.x)/a.x,u=(o.top+s.y)/a.y,d=o.width/a.x,f=o.height/a.y;if(i){const h=Ur(i),v=n&&An(n)?Ur(n):n;let b=h,g=z_(b);for(;g&&n&&v!==b;){const m=ba(g),x=g.getBoundingClientRect(),w=kn(g),E=x.left+(g.clientLeft+parseFloat(w.paddingLeft))*m.x,S=x.top+(g.clientTop+parseFloat(w.paddingTop))*m.y;c*=m.x,u*=m.y,d*=m.x,f*=m.y,c+=E,u+=S,b=Ur(g),g=z_(b)}}return bd({width:d,height:f,x:c,y:u})}function bf(e,t){const r=mf(e).scrollLeft;return t?t.left+r:Ci(ro(e)).left+r}function mF(e,t){const r=e.getBoundingClientRect(),n=r.left+t.scrollLeft-bf(e,r),o=r.top+t.scrollTop;return{x:n,y:o}}function Mse(e){let{elements:t,rect:r,offsetParent:n,strategy:o}=e;const i=o==="fixed",a=ro(n),s=t?gf(t.floating):!1;if(n===a||s&&i)return r;let c={scrollLeft:0,scrollTop:0},u=Zn(1);const d=Zn(0),f=Qn(n);if((f||!f&&!i)&&((Wa(n)!=="body"||Dl(a))&&(c=mf(n)),Qn(n))){const v=Ci(n);u=ba(n),d.x=v.x+n.clientLeft,d.y=v.y+n.clientTop}const h=a&&!f&&!i?mF(a,c):Zn(0);return{width:r.width*u.x,height:r.height*u.y,x:r.x*u.x-c.scrollLeft*u.x+d.x+h.x,y:r.y*u.y-c.scrollTop*u.y+d.y+h.y}}function jse(e){return Array.from(e.getClientRects())}function Lse(e){const t=ro(e),r=mf(e),n=e.ownerDocument.body,o=Wr(t.scrollWidth,t.clientWidth,n.scrollWidth,n.clientWidth),i=Wr(t.scrollHeight,t.clientHeight,n.scrollHeight,n.clientHeight);let a=-r.scrollLeft+bf(e);const s=-r.scrollTop;return kn(n).direction==="rtl"&&(a+=Wr(t.clientWidth,n.clientWidth)-o),{width:o,height:i,x:a,y:s}}const MD=25;function qse(e,t){const r=Ur(e),n=ro(e),o=r.visualViewport;let i=n.clientWidth,a=n.clientHeight,s=0,c=0;if(o){i=o.width,a=o.height;const d=tE();(!d||d&&t==="fixed")&&(s=o.offsetLeft,c=o.offsetTop)}const u=bf(n);if(u<=0){const d=n.ownerDocument,f=d.body,h=getComputedStyle(f),v=d.compatMode==="CSS1Compat"&&parseFloat(h.marginLeft)+parseFloat(h.marginRight)||0,b=Math.abs(n.clientWidth-f.clientWidth-v);b<=MD&&(i-=b)}else u<=MD&&(i+=u);return{width:i,height:a,x:s,y:c}}const zse=new Set(["absolute","fixed"]);function Bse(e,t){const r=Ci(e,!0,t==="fixed"),n=r.top+e.clientTop,o=r.left+e.clientLeft,i=Qn(e)?ba(e):Zn(1),a=e.clientWidth*i.x,s=e.clientHeight*i.y,c=o*i.x,u=n*i.y;return{width:a,height:s,x:c,y:u}}function jD(e,t,r){let n;if(t==="viewport")n=qse(e,r);else if(t==="document")n=Lse(ro(e));else if(An(t))n=Bse(t,r);else{const o=gF(e);n={x:t.x-o.x,y:t.y-o.y,width:t.width,height:t.height}}return bd(n)}function bF(e,t){const r=Ko(e);return r===t||!An(r)||Pa(r)?!1:kn(r).position==="fixed"||bF(r,t)}function Fse(e,t){const r=t.get(e);if(r)return r;let n=hl(e,[],!1).filter(s=>An(s)&&Wa(s)!=="body"),o=null;const i=kn(e).position==="fixed";let a=i?Ko(e):e;for(;An(a)&&!Pa(a);){const s=kn(a),c=eE(a);!c&&s.position==="fixed"&&(o=null),(i?!c&&!o:!c&&s.position==="static"&&!!o&&zse.has(o.position)||Dl(a)&&!c&&bF(e,a))?n=n.filter(d=>d!==a):o=s,a=Ko(a)}return t.set(e,n),n}function $se(e){let{element:t,boundary:r,rootBoundary:n,strategy:o}=e;const a=[...r==="clippingAncestors"?gf(t)?[]:Fse(t,this._c):[].concat(r),n],s=a[0],c=a.reduce((u,d)=>{const f=jD(t,d,o);return u.top=Wr(f.top,u.top),u.right=Yo(f.right,u.right),u.bottom=Yo(f.bottom,u.bottom),u.left=Wr(f.left,u.left),u},jD(t,s,o));return{width:c.right-c.left,height:c.bottom-c.top,x:c.left,y:c.top}}function Vse(e){const{width:t,height:r}=vF(e);return{width:t,height:r}}function Hse(e,t,r){const n=Qn(t),o=ro(t),i=r==="fixed",a=Ci(e,!0,i,t);let s={scrollLeft:0,scrollTop:0};const c=Zn(0);function u(){c.x=bf(o)}if(n||!n&&!i)if((Wa(t)!=="body"||Dl(o))&&(s=mf(t)),n){const v=Ci(t,!0,i,t);c.x=v.x+t.clientLeft,c.y=v.y+t.clientTop}else o&&u();i&&!n&&o&&u();const d=o&&!n&&!i?mF(o,s):Zn(0),f=a.left+s.scrollLeft-c.x-d.x,h=a.top+s.scrollTop-c.y-d.y;return{x:f,y:h,width:a.width,height:a.height}}function v0(e){return kn(e).position==="static"}function LD(e,t){if(!Qn(e)||kn(e).position==="fixed")return null;if(t)return t(e);let r=e.offsetParent;return ro(e)===r&&(r=r.ownerDocument.body),r}function yF(e,t){const r=Ur(e);if(gf(e))return r;if(!Qn(e)){let o=Ko(e);for(;o&&!Pa(o);){if(An(o)&&!v0(o))return o;o=Ko(o)}return r}let n=LD(e,t);for(;n&&Cse(n)&&v0(n);)n=LD(n,t);return n&&Pa(n)&&v0(n)&&!eE(n)?r:n||Tse(e)||r}const Wse=async function(e){const t=this.getOffsetParent||yF,r=this.getDimensions,n=await r(e.floating);return{reference:Hse(e.reference,await t(e.floating),e.strategy),floating:{x:0,y:0,width:n.width,height:n.height}}};function Use(e){return kn(e).direction==="rtl"}const Gse={convertOffsetParentRelativeRectToViewportRelativeRect:Mse,getDocumentElement:ro,getClippingRect:$se,getOffsetParent:yF,getElementRects:Wse,getClientRects:jse,getDimensions:Vse,getScale:ba,isElement:An,isRTL:Use};function xF(e,t){return e.x===t.x&&e.y===t.y&&e.width===t.width&&e.height===t.height}function Yse(e,t){let r=null,n;const o=ro(e);function i(){var s;clearTimeout(n),(s=r)==null||s.disconnect(),r=null}function a(s,c){s===void 0&&(s=!1),c===void 0&&(c=1),i();const u=e.getBoundingClientRect(),{left:d,top:f,width:h,height:v}=u;if(s||t(),!h||!v)return;const b=pu(f),g=pu(o.clientWidth-(d+h)),m=pu(o.clientHeight-(f+v)),x=pu(d),E={rootMargin:-b+"px "+-g+"px "+-m+"px "+-x+"px",threshold:Wr(0,Yo(1,c))||1};let S=!0;function _(C){const N=C[0].intersectionRatio;if(N!==c){if(!S)return a();N?a(!1,N):n=setTimeout(()=>{a(!1,1e-7)},1e3)}N===1&&!xF(u,e.getBoundingClientRect())&&a(),S=!1}try{r=new IntersectionObserver(_,{...E,root:o.ownerDocument})}catch{r=new IntersectionObserver(_,E)}r.observe(e)}return a(!0),i}function Kse(e,t,r,n){n===void 0&&(n={});const{ancestorScroll:o=!0,ancestorResize:i=!0,elementResize:a=typeof ResizeObserver=="function",layoutShift:s=typeof IntersectionObserver=="function",animationFrame:c=!1}=n,u=rE(e),d=o||i?[...u?hl(u):[],...hl(t)]:[];d.forEach(x=>{o&&x.addEventListener("scroll",r,{passive:!0}),i&&x.addEventListener("resize",r)});const f=u&&s?Yse(u,r):null;let h=-1,v=null;a&&(v=new ResizeObserver(x=>{let[w]=x;w&&w.target===u&&v&&(v.unobserve(t),cancelAnimationFrame(h),h=requestAnimationFrame(()=>{var E;(E=v)==null||E.observe(t)})),r()}),u&&!c&&v.observe(u),v.observe(t));let b,g=c?Ci(e):null;c&&m();function m(){const x=Ci(e);g&&!xF(g,x)&&r(),g=x,b=requestAnimationFrame(m)}return r(),()=>{var x;d.forEach(w=>{o&&w.removeEventListener("scroll",r),i&&w.removeEventListener("resize",r)}),f==null||f(),(x=v)==null||x.disconnect(),v=null,c&&cancelAnimationFrame(b)}}const Xse=xse,Zse=wse,Jse=mse,Qse=Ese,ele=bse,qD=gse,tle=_se,rle=(e,t,r)=>{const n=new Map,o={platform:Gse,...r},i={...o.platform,_c:n};return vse(e,t,{...o,platform:i})};var nle=typeof document<"u",ole=function(){},zu=nle?R.useLayoutEffect:ole;function yd(e,t){if(e===t)return!0;if(typeof e!=typeof t)return!1;if(typeof e=="function"&&e.toString()===t.toString())return!0;let r,n,o;if(e&&t&&typeof e=="object"){if(Array.isArray(e)){if(r=e.length,r!==t.length)return!1;for(n=r;n--!==0;)if(!yd(e[n],t[n]))return!1;return!0}if(o=Object.keys(e),r=o.length,r!==Object.keys(t).length)return!1;for(n=r;n--!==0;)if(!{}.hasOwnProperty.call(t,o[n]))return!1;for(n=r;n--!==0;){const i=o[n];if(!(i==="_owner"&&e.$$typeof)&&!yd(e[i],t[i]))return!1}return!0}return e!==e&&t!==t}function wF(e){return typeof window>"u"?1:(e.ownerDocument.defaultView||window).devicePixelRatio||1}function zD(e,t){const r=wF(e);return Math.round(t*r)/r}function g0(e){const t=ue.useRef(e);return zu(()=>{t.current=e}),t}function ile(e){e===void 0&&(e={});const{placement:t="bottom",strategy:r="absolute",middleware:n=[],platform:o,elements:{reference:i,floating:a}={},transform:s=!0,whileElementsMounted:c,open:u}=e,[d,f]=ue.useState({x:0,y:0,strategy:r,placement:t,middlewareData:{},isPositioned:!1}),[h,v]=ue.useState(n);yd(h,n)||v(n);const[b,g]=ue.useState(null),[m,x]=ue.useState(null),w=ue.useCallback(F=>{F!==C.current&&(C.current=F,g(F))},[]),E=ue.useCallback(F=>{F!==N.current&&(N.current=F,x(F))},[]),S=i||b,_=a||m,C=ue.useRef(null),N=ue.useRef(null),P=ue.useRef(d),A=c!=null,j=g0(c),M=g0(o),L=g0(u),D=ue.useCallback(()=>{if(!C.current||!N.current)return;const F={placement:t,strategy:r,middleware:h};M.current&&(F.platform=M.current),rle(C.current,N.current,F).then(J=>{const z={...J,isPositioned:L.current!==!1};T.current&&!yd(P.current,z)&&(P.current=z,W_.flushSync(()=>{f(z)}))})},[h,t,r,M,L]);zu(()=>{u===!1&&P.current.isPositioned&&(P.current.isPositioned=!1,f(F=>({...F,isPositioned:!1})))},[u]);const T=ue.useRef(!1);zu(()=>(T.current=!0,()=>{T.current=!1}),[]),zu(()=>{if(S&&(C.current=S),_&&(N.current=_),S&&_){if(j.current)return j.current(S,_,D);D()}},[S,_,D,j,A]);const W=ue.useMemo(()=>({reference:C,floating:N,setReference:w,setFloating:E}),[w,E]),q=ue.useMemo(()=>({reference:S,floating:_}),[S,_]),G=ue.useMemo(()=>{const F={position:r,left:0,top:0};if(!q.floating)return F;const J=zD(q.floating,d.x),z=zD(q.floating,d.y);return s?{...F,transform:"translate("+J+"px, "+z+"px)",...wF(q.floating)>=1.5&&{willChange:"transform"}}:{position:r,left:J,top:z}},[r,s,q.floating,d.x,d.y]);return ue.useMemo(()=>({...d,update:D,refs:W,elements:q,floatingStyles:G}),[d,D,W,q,G])}const ale=e=>{function t(r){return{}.hasOwnProperty.call(r,"current")}return{name:"arrow",options:e,fn(r){const{element:n,padding:o}=typeof e=="function"?e(r):e;return n&&t(n)?n.current!=null?qD({element:n.current,padding:o}).fn(r):{}:n?qD({element:n,padding:o}).fn(r):{}}}},sle=(e,t)=>({...Xse(e),options:[e,t]}),lle=(e,t)=>({...Zse(e),options:[e,t]}),cle=(e,t)=>({...tle(e),options:[e,t]}),ule=(e,t)=>({...Jse(e),options:[e,t]}),dle=(e,t)=>({...Qse(e),options:[e,t]}),fle=(e,t)=>({...ele(e),options:[e,t]}),ple=(e,t)=>({...ale(e),options:[e,t]});function hle(e){const t=vle(e),r=ue.forwardRef((n,o)=>{const{children:i,...a}=n,s=ue.Children.toArray(i),c=s.find(mle);if(c){const u=c.props.children,d=s.map(f=>f===c?ue.Children.count(u)>1?ue.Children.only(null):ue.isValidElement(u)?u.props.children:null:f);return O.jsx(t,{...a,ref:o,children:ue.isValidElement(u)?ue.cloneElement(u,void 0,d):null})}return O.jsx(t,{...a,ref:o,children:i})});return r.displayName=`${e}.Slot`,r}function vle(e){const t=ue.forwardRef((r,n)=>{const{children:o,...i}=r;if(ue.isValidElement(o)){const a=yle(o),s=ble(i,o.props);return o.type!==ue.Fragment&&(s.ref=n?uF(n,a):a),ue.cloneElement(o,s)}return ue.Children.count(o)>1?ue.Children.only(null):null});return t.displayName=`${e}.SlotClone`,t}var gle=Symbol("radix.slottable");function mle(e){return ue.isValidElement(e)&&typeof e.type=="function"&&"__radixId"in e.type&&e.type.__radixId===gle}function ble(e,t){const r={...t};for(const n in t){const o=e[n],i=t[n];/^on[A-Z]/.test(n)?o&&i?r[n]=(...s)=>{const c=i(...s);return o(...s),c}:o&&(r[n]=o):n==="style"?r[n]={...o,...i}:n==="className"&&(r[n]=[o,i].filter(Boolean).join(" "))}return{...e,...r}}function yle(e){var n,o;let t=(n=Object.getOwnPropertyDescriptor(e.props,"ref"))==null?void 0:n.get,r=t&&"isReactWarning"in t&&t.isReactWarning;return r?e.ref:(t=(o=Object.getOwnPropertyDescriptor(e,"ref"))==null?void 0:o.get,r=t&&"isReactWarning"in t&&t.isReactWarning,r?e.props.ref:e.props.ref||e.ref)}var xle=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","select","span","svg","ul"],Ai=xle.reduce((e,t)=>{const r=hle(`Primitive.${t}`),n=ue.forwardRef((o,i)=>{const{asChild:a,...s}=o,c=a?r:t;return typeof window<"u"&&(window[Symbol.for("radix-ui")]=!0),O.jsx(c,{...s,ref:i})});return n.displayName=`Primitive.${t}`,{...e,[t]:n}},{});function wle(e,t){e&&W_.flushSync(()=>e.dispatchEvent(t))}var _le="Arrow",_F=ue.forwardRef((e,t)=>{const{children:r,width:n=10,height:o=5,...i}=e;return O.jsx(Ai.svg,{...i,ref:t,width:n,height:o,viewBox:"0 0 30 10",preserveAspectRatio:"none",children:e.asChild?r:O.jsx("polygon",{points:"0,0 30,0 15,10"})})});_F.displayName=_le;var Ele=_F;function yf(e){const t=ue.useRef(e);return ue.useEffect(()=>{t.current=e}),ue.useMemo(()=>(...r)=>{var n;return(n=t.current)==null?void 0:n.call(t,...r)},[])}function Sle(e){const[t,r]=ue.useState(void 0);return Oi(()=>{if(e){r({width:e.offsetWidth,height:e.offsetHeight});const n=new ResizeObserver(o=>{if(!Array.isArray(o)||!o.length)return;const i=o[0];let a,s;if("borderBoxSize"in i){const c=i.borderBoxSize,u=Array.isArray(c)?c[0]:c;a=u.inlineSize,s=u.blockSize}else a=e.offsetWidth,s=e.offsetHeight;r({width:a,height:s})});return n.observe(e,{box:"border-box"}),()=>n.unobserve(e)}else r(void 0)},[e]),t}var nE="Popper",[EF,SF]=cF(nE),[Ole,OF]=EF(nE),CF=e=>{const{__scopePopper:t,children:r}=e,[n,o]=ue.useState(null);return O.jsx(Ole,{scope:t,anchor:n,onAnchorChange:o,children:r})};CF.displayName=nE;var RF="PopperAnchor",NF=ue.forwardRef((e,t)=>{const{__scopePopper:r,virtualRef:n,...o}=e,i=OF(RF,r),a=ue.useRef(null),s=Va(t,a),c=ue.useRef(null);return ue.useEffect(()=>{const u=c.current;c.current=(n==null?void 0:n.current)||a.current,u!==c.current&&i.onAnchorChange(c.current)}),n?null:O.jsx(Ai.div,{...o,ref:s})});NF.displayName=RF;var oE="PopperContent",[Cle,Rle]=EF(oE),IF=ue.forwardRef((e,t)=>{var H,K,Q,ne,se,te;const{__scopePopper:r,side:n="bottom",sideOffset:o=0,align:i="center",alignOffset:a=0,arrowPadding:s=0,avoidCollisions:c=!0,collisionBoundary:u=[],collisionPadding:d=0,sticky:f="partial",hideWhenDetached:h=!1,updatePositionStrategy:v="optimized",onPlaced:b,...g}=e,m=OF(oE,r),[x,w]=ue.useState(null),E=Va(t,be=>w(be)),[S,_]=ue.useState(null),C=Sle(S),N=(C==null?void 0:C.width)??0,P=(C==null?void 0:C.height)??0,A=n+(i!=="center"?"-"+i:""),j=typeof d=="number"?d:{top:0,right:0,bottom:0,left:0,...d},M=Array.isArray(u)?u:[u],L=M.length>0,D={padding:j,boundary:M.filter(Ile),altBoundary:L},{refs:T,floatingStyles:W,placement:q,isPositioned:G,middlewareData:F}=ile({strategy:"fixed",placement:A,whileElementsMounted:(...be)=>Kse(...be,{animationFrame:v==="always"}),elements:{reference:m.anchor},middleware:[sle({mainAxis:o+P,alignmentAxis:a}),c&&lle({mainAxis:!0,crossAxis:!1,limiter:f==="partial"?cle():void 0,...D}),c&&ule({...D}),dle({...D,apply:({elements:be,rects:de,availableWidth:Ee,availableHeight:fe})=>{const{width:le,height:Ce}=de.reference,Te=be.floating.style;Te.setProperty("--radix-popper-available-width",`${Ee}px`),Te.setProperty("--radix-popper-available-height",`${fe}px`),Te.setProperty("--radix-popper-anchor-width",`${le}px`),Te.setProperty("--radix-popper-anchor-height",`${Ce}px`)}}),S&&ple({element:S,padding:s}),Ple({arrowWidth:N,arrowHeight:P}),h&&fle({strategy:"referenceHidden",...D})]}),[J,z]=AF(q),U=yf(b);Oi(()=>{G&&(U==null||U())},[G,U]);const oe=(H=F.arrow)==null?void 0:H.x,re=(K=F.arrow)==null?void 0:K.y,$=((Q=F.arrow)==null?void 0:Q.centerOffset)!==0,[Y,X]=ue.useState();return Oi(()=>{x&&X(window.getComputedStyle(x).zIndex)},[x]),O.jsx("div",{ref:T.setFloating,"data-radix-popper-content-wrapper":"",style:{...W,transform:G?W.transform:"translate(0, -200%)",minWidth:"max-content",zIndex:Y,"--radix-popper-transform-origin":[(ne=F.transformOrigin)==null?void 0:ne.x,(se=F.transformOrigin)==null?void 0:se.y].join(" "),...((te=F.hide)==null?void 0:te.referenceHidden)&&{visibility:"hidden",pointerEvents:"none"}},dir:e.dir,children:O.jsx(Cle,{scope:r,placedSide:J,onArrowChange:_,arrowX:oe,arrowY:re,shouldHideArrow:$,children:O.jsx(Ai.div,{"data-side":J,"data-align":z,...g,ref:E,style:{...g.style,animation:G?void 0:"none"}})})})});IF.displayName=oE;var PF="PopperArrow",Nle={top:"bottom",right:"left",bottom:"top",left:"right"},TF=ue.forwardRef(function(t,r){const{__scopePopper:n,...o}=t,i=Rle(PF,n),a=Nle[i.placedSide];return O.jsx("span",{ref:i.onArrowChange,style:{position:"absolute",left:i.arrowX,top:i.arrowY,[a]:0,transformOrigin:{top:"",right:"0 0",bottom:"center 0",left:"100% 0"}[i.placedSide],transform:{top:"translateY(100%)",right:"translateY(50%) rotate(90deg) translateX(-50%)",bottom:"rotate(180deg)",left:"translateY(50%) rotate(-90deg) translateX(50%)"}[i.placedSide],visibility:i.shouldHideArrow?"hidden":void 0},children:O.jsx(Ele,{...o,ref:r,style:{...o.style,display:"block"}})})});TF.displayName=PF;function Ile(e){return e!==null}var Ple=e=>({name:"transformOrigin",options:e,fn(t){var m,x,w;const{placement:r,rects:n,middlewareData:o}=t,a=((m=o.arrow)==null?void 0:m.centerOffset)!==0,s=a?0:e.arrowWidth,c=a?0:e.arrowHeight,[u,d]=AF(r),f={start:"0%",center:"50%",end:"100%"}[d],h=(((x=o.arrow)==null?void 0:x.x)??0)+s/2,v=(((w=o.arrow)==null?void 0:w.y)??0)+c/2;let b="",g="";return u==="bottom"?(b=a?f:`${h}px`,g=`${-c}px`):u==="top"?(b=a?f:`${h}px`,g=`${n.floating.height+c}px`):u==="right"?(b=`${-c}px`,g=a?f:`${v}px`):u==="left"&&(b=`${n.floating.width+c}px`,g=a?f:`${v}px`),{data:{x:b,y:g}}}});function AF(e){const[t,r="center"]=e.split("-");return[t,r]}var Tle=CF,Ale=NF,kle=IF,Dle=TF,Mle="Portal",kF=ue.forwardRef((e,t)=>{var s;const{container:r,...n}=e,[o,i]=ue.useState(!1);Oi(()=>i(!0),[]);const a=r||o&&((s=globalThis==null?void 0:globalThis.document)==null?void 0:s.body);return a?mo.createPortal(O.jsx(Ai.div,{...n,ref:t}),a):null});kF.displayName=Mle;function jle(e,t){return ue.useReducer((r,n)=>t[r][n]??r,e)}var iE=e=>{const{present:t,children:r}=e,n=Lle(t),o=typeof r=="function"?r({present:n.isPresent}):ue.Children.only(r),i=Va(n.ref,qle(o));return typeof r=="function"||n.isPresent?ue.cloneElement(o,{ref:i}):null};iE.displayName="Presence";function Lle(e){const[t,r]=ue.useState(),n=ue.useRef(null),o=ue.useRef(e),i=ue.useRef("none"),a=e?"mounted":"unmounted",[s,c]=jle(a,{mounted:{UNMOUNT:"unmounted",ANIMATION_OUT:"unmountSuspended"},unmountSuspended:{MOUNT:"mounted",ANIMATION_END:"unmounted"},unmounted:{MOUNT:"mounted"}});return ue.useEffect(()=>{const u=hu(n.current);i.current=s==="mounted"?u:"none"},[s]),Oi(()=>{const u=n.current,d=o.current;if(d!==e){const h=i.current,v=hu(u);e?c("MOUNT"):v==="none"||(u==null?void 0:u.display)==="none"?c("UNMOUNT"):c(d&&h!==v?"ANIMATION_OUT":"UNMOUNT"),o.current=e}},[e,c]),Oi(()=>{if(t){let u;const d=t.ownerDocument.defaultView??window,f=v=>{const g=hu(n.current).includes(CSS.escape(v.animationName));if(v.target===t&&g&&(c("ANIMATION_END"),!o.current)){const m=t.style.animationFillMode;t.style.animationFillMode="forwards",u=d.setTimeout(()=>{t.style.animationFillMode==="forwards"&&(t.style.animationFillMode=m)})}},h=v=>{v.target===t&&(i.current=hu(n.current))};return t.addEventListener("animationstart",h),t.addEventListener("animationcancel",f),t.addEventListener("animationend",f),()=>{d.clearTimeout(u),t.removeEventListener("animationstart",h),t.removeEventListener("animationcancel",f),t.removeEventListener("animationend",f)}}else c("ANIMATION_END")},[t,c]),{isPresent:["mounted","unmountSuspended"].includes(s),ref:ue.useCallback(u=>{n.current=u?getComputedStyle(u):null,r(u)},[])}}function hu(e){return(e==null?void 0:e.animationName)||"none"}function qle(e){var n,o;let t=(n=Object.getOwnPropertyDescriptor(e.props,"ref"))==null?void 0:n.get,r=t&&"isReactWarning"in t&&t.isReactWarning;return r?e.ref:(t=(o=Object.getOwnPropertyDescriptor(e,"ref"))==null?void 0:o.get,r=t&&"isReactWarning"in t&&t.isReactWarning,r?e.props.ref:e.props.ref||e.ref)}function zle(e,t=globalThis==null?void 0:globalThis.document){const r=yf(e);ue.useEffect(()=>{const n=o=>{o.key==="Escape"&&r(o)};return t.addEventListener("keydown",n,{capture:!0}),()=>t.removeEventListener("keydown",n,{capture:!0})},[r,t])}var Ble="DismissableLayer",B_="dismissableLayer.update",Fle="dismissableLayer.pointerDownOutside",$le="dismissableLayer.focusOutside",BD,DF=ue.createContext({layers:new Set,layersWithOutsidePointerEventsDisabled:new Set,branches:new Set}),MF=ue.forwardRef((e,t)=>{const{disableOutsidePointerEvents:r=!1,onEscapeKeyDown:n,onPointerDownOutside:o,onFocusOutside:i,onInteractOutside:a,onDismiss:s,...c}=e,u=ue.useContext(DF),[d,f]=ue.useState(null),h=(d==null?void 0:d.ownerDocument)??(globalThis==null?void 0:globalThis.document),[,v]=ue.useState({}),b=Va(t,N=>f(N)),g=Array.from(u.layers),[m]=[...u.layersWithOutsidePointerEventsDisabled].slice(-1),x=g.indexOf(m),w=d?g.indexOf(d):-1,E=u.layersWithOutsidePointerEventsDisabled.size>0,S=w>=x,_=Wle(N=>{const P=N.target,A=[...u.branches].some(j=>j.contains(P));!S||A||(o==null||o(N),a==null||a(N),N.defaultPrevented||s==null||s())},h),C=Ule(N=>{const P=N.target;[...u.branches].some(j=>j.contains(P))||(i==null||i(N),a==null||a(N),N.defaultPrevented||s==null||s())},h);return zle(N=>{w===u.layers.size-1&&(n==null||n(N),!N.defaultPrevented&&s&&(N.preventDefault(),s()))},h),ue.useEffect(()=>{if(d)return r&&(u.layersWithOutsidePointerEventsDisabled.size===0&&(BD=h.body.style.pointerEvents,h.body.style.pointerEvents="none"),u.layersWithOutsidePointerEventsDisabled.add(d)),u.layers.add(d),FD(),()=>{r&&u.layersWithOutsidePointerEventsDisabled.size===1&&(h.body.style.pointerEvents=BD)}},[d,h,r,u]),ue.useEffect(()=>()=>{d&&(u.layers.delete(d),u.layersWithOutsidePointerEventsDisabled.delete(d),FD())},[d,u]),ue.useEffect(()=>{const N=()=>v({});return document.addEventListener(B_,N),()=>document.removeEventListener(B_,N)},[]),O.jsx(Ai.div,{...c,ref:b,style:{pointerEvents:E?S?"auto":"none":void 0,...e.style},onFocusCapture:cn(e.onFocusCapture,C.onFocusCapture),onBlurCapture:cn(e.onBlurCapture,C.onBlurCapture),onPointerDownCapture:cn(e.onPointerDownCapture,_.onPointerDownCapture)})});MF.displayName=Ble;var Vle="DismissableLayerBranch",Hle=ue.forwardRef((e,t)=>{const r=ue.useContext(DF),n=ue.useRef(null),o=Va(t,n);return ue.useEffect(()=>{const i=n.current;if(i)return r.branches.add(i),()=>{r.branches.delete(i)}},[r.branches]),O.jsx(Ai.div,{...e,ref:o})});Hle.displayName=Vle;function Wle(e,t=globalThis==null?void 0:globalThis.document){const r=yf(e),n=ue.useRef(!1),o=ue.useRef(()=>{});return ue.useEffect(()=>{const i=s=>{if(s.target&&!n.current){let c=function(){jF(Fle,r,u,{discrete:!0})};const u={originalEvent:s};s.pointerType==="touch"?(t.removeEventListener("click",o.current),o.current=c,t.addEventListener("click",o.current,{once:!0})):c()}else t.removeEventListener("click",o.current);n.current=!1},a=window.setTimeout(()=>{t.addEventListener("pointerdown",i)},0);return()=>{window.clearTimeout(a),t.removeEventListener("pointerdown",i),t.removeEventListener("click",o.current)}},[t,r]),{onPointerDownCapture:()=>n.current=!0}}function Ule(e,t=globalThis==null?void 0:globalThis.document){const r=yf(e),n=ue.useRef(!1);return ue.useEffect(()=>{const o=i=>{i.target&&!n.current&&jF($le,r,{originalEvent:i},{discrete:!1})};return t.addEventListener("focusin",o),()=>t.removeEventListener("focusin",o)},[t,r]),{onFocusCapture:()=>n.current=!0,onBlurCapture:()=>n.current=!1}}function FD(){const e=new CustomEvent(B_);document.dispatchEvent(e)}function jF(e,t,r,{discrete:n}){const o=r.originalEvent.target,i=new CustomEvent(e,{bubbles:!1,cancelable:!0,detail:r});t&&o.addEventListener(e,t,{once:!0}),n?wle(o,i):o.dispatchEvent(i)}var m0,xf="HoverCard",[LF]=cF(xf,[SF]),wf=SF(),[Gle,_f]=LF(xf),qF=e=>{const{__scopeHoverCard:t,children:r,open:n,defaultOpen:o,onOpenChange:i,openDelay:a=700,closeDelay:s=300}=e,c=wf(t),u=ue.useRef(0),d=ue.useRef(0),f=ue.useRef(!1),h=ue.useRef(!1),[v,b]=tse({prop:n,defaultProp:o??!1,onChange:i,caller:xf}),g=ue.useCallback(()=>{clearTimeout(d.current),u.current=window.setTimeout(()=>b(!0),a)},[a,b]),m=ue.useCallback(()=>{clearTimeout(u.current),!f.current&&!h.current&&(d.current=window.setTimeout(()=>b(!1),s))},[s,b]),x=ue.useCallback(()=>b(!1),[b]);return ue.useEffect(()=>()=>{clearTimeout(u.current),clearTimeout(d.current)},[]),O.jsx(Gle,{scope:t,open:v,onOpenChange:b,onOpen:g,onClose:m,onDismiss:x,hasSelectionRef:f,isPointerDownOnContentRef:h,children:O.jsx(Tle,{...c,children:r})})};qF.displayName=xf;var zF="HoverCardTrigger",BF=ue.forwardRef((e,t)=>{const{__scopeHoverCard:r,...n}=e,o=_f(zF,r),i=wf(r);return O.jsx(Ale,{asChild:!0,...i,children:O.jsx(Ai.a,{"data-state":o.open?"open":"closed",...n,ref:t,onPointerEnter:cn(e.onPointerEnter,wd(o.onOpen)),onPointerLeave:cn(e.onPointerLeave,wd(o.onClose)),onFocus:cn(e.onFocus,o.onOpen),onBlur:cn(e.onBlur,o.onClose),onTouchStart:cn(e.onTouchStart,a=>a.preventDefault())})})});BF.displayName=zF;var aE="HoverCardPortal",[Yle,Kle]=LF(aE,{forceMount:void 0}),FF=e=>{const{__scopeHoverCard:t,forceMount:r,children:n,container:o}=e,i=_f(aE,t);return O.jsx(Yle,{scope:t,forceMount:r,children:O.jsx(iE,{present:r||i.open,children:O.jsx(kF,{asChild:!0,container:o,children:n})})})};FF.displayName=aE;var xd="HoverCardContent",$F=ue.forwardRef((e,t)=>{const r=Kle(xd,e.__scopeHoverCard),{forceMount:n=r.forceMount,...o}=e,i=_f(xd,e.__scopeHoverCard);return O.jsx(iE,{present:n||i.open,children:O.jsx(Xle,{"data-state":i.open?"open":"closed",...o,onPointerEnter:cn(e.onPointerEnter,wd(i.onOpen)),onPointerLeave:cn(e.onPointerLeave,wd(i.onClose)),ref:t})})});$F.displayName=xd;var Xle=ue.forwardRef((e,t)=>{const{__scopeHoverCard:r,onEscapeKeyDown:n,onPointerDownOutside:o,onFocusOutside:i,onInteractOutside:a,...s}=e,c=_f(xd,r),u=wf(r),d=ue.useRef(null),f=Va(t,d),[h,v]=ue.useState(!1);return ue.useEffect(()=>{if(h){const b=document.body;return m0=b.style.userSelect||b.style.webkitUserSelect,b.style.userSelect="none",b.style.webkitUserSelect="none",()=>{b.style.userSelect=m0,b.style.webkitUserSelect=m0}}},[h]),ue.useEffect(()=>{if(d.current){const b=()=>{v(!1),c.isPointerDownOnContentRef.current=!1,setTimeout(()=>{var m;((m=document.getSelection())==null?void 0:m.toString())!==""&&(c.hasSelectionRef.current=!0)})};return document.addEventListener("pointerup",b),()=>{document.removeEventListener("pointerup",b),c.hasSelectionRef.current=!1,c.isPointerDownOnContentRef.current=!1}}},[c.isPointerDownOnContentRef,c.hasSelectionRef]),ue.useEffect(()=>{d.current&&Qle(d.current).forEach(g=>g.setAttribute("tabindex","-1"))}),O.jsx(MF,{asChild:!0,disableOutsidePointerEvents:!1,onInteractOutside:a,onEscapeKeyDown:n,onPointerDownOutside:o,onFocusOutside:cn(i,b=>{b.preventDefault()}),onDismiss:c.onDismiss,children:O.jsx(kle,{...u,...s,onPointerDown:cn(s.onPointerDown,b=>{b.currentTarget.contains(b.target)&&v(!0),c.hasSelectionRef.current=!1,c.isPointerDownOnContentRef.current=!0}),ref:f,style:{...s.style,userSelect:h?"text":void 0,WebkitUserSelect:h?"text":void 0,"--radix-hover-card-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-hover-card-content-available-width":"var(--radix-popper-available-width)","--radix-hover-card-content-available-height":"var(--radix-popper-available-height)","--radix-hover-card-trigger-width":"var(--radix-popper-anchor-width)","--radix-hover-card-trigger-height":"var(--radix-popper-anchor-height)"}})})}),Zle="HoverCardArrow",Jle=ue.forwardRef((e,t)=>{const{__scopeHoverCard:r,...n}=e,o=wf(r);return O.jsx(Dle,{...o,...n,ref:t})});Jle.displayName=Zle;function wd(e){return t=>t.pointerType==="touch"?void 0:e()}function Qle(e){const t=[],r=document.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,{acceptNode:n=>n.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP});for(;r.nextNode();)t.push(r.currentNode);return t}var sE=qF,lE=BF,Cn=FF,Rn=$F;const ece=({item:e,depth:t})=>{const r=dr(),[n,o]=R.useState(!1),i=r.getPrivileges(),a=he.populateShallow(e.includes,i);return O.jsxs("div",{className:"py-1 text-xs text-white",children:[O.jsxs("div",{className:"flex items-center",children:[O.jsx("button",{className:"-ml-1",onClick:s=>{s.stopPropagation(),o(!n)},children:O.jsx(_e.FdRight,{className:zt("h-4 w-4",{"tranform rotate-90":n})})})," ",O.jsx("div",{children:e.privilege})]}),O.jsx("div",{className:"border-l pl-2",style:{marginLeft:t?t*4:3},children:n&&O.jsx(VF,{depth:t+1,data:a})})]})},VF=({data:e,depth:t=0})=>e.map(r=>r.includes.length?O.jsx(ece,{item:r,depth:t},r.id):O.jsx("div",{className:zt("py-1 text-xs",{}),children:r.privilege},r.id)),yr=()=>document.querySelector(`.${kL.ROLES_EDITOR_SCOPE_CLASS}`)||document.body,Ef=({container:e,...t})=>O.jsx(he.Portal,{...t,container:e||yr()}),$D=sE,VD=lE,HD=({privilege:e,selectedPrivilege:t,onSelect:r,isGuest:n=!1})=>{const o=dr(),i=o.getPrivileges(),a=he.populateShallow(e.includes,i),[s,c]=R.useState(!1),[u,d]=R.useState(e.privilege),[f,h]=R.useState(null),v=he.useOutsideClick(()=>{s&&m()});he.useDidMountEffect(()=>{e.privilege!==u&&d(e.privilege)},[e.privilege]);function b(){c(!0),h(null)}function g(){c(!1),d(e.privilege)}function m(){h(null);try{he.validateName(u);const E=he.renamePrivilege(u,e.id,i);o.actions.updatePrivileges(E),c(!1)}catch(E){h(E.message)}}const x=async E=>{E.stopPropagation();const{confirmed:S}=await o.actions.openModal({title:"Delete Privilege",type:he.ModalType.CONFIRM,color:he.ModalColor.DANGER,message:"Are you sure you want to remove this Privilege?",icon:"FdWarningDanger"});if(S){const _=he.removePrivilege(e.id,i);if((t==null?void 0:t.id)!==e.id){o.actions.updatePrivileges(_);return}const C=Object.keys(_).filter(N=>_[N].privilege!=="guest");if(C.length===0)r(null);else{const N=Object.keys(i).filter(M=>i[M].privilege!=="guest"),P=N.indexOf(e.id),A=Math.max(0,P-1),j=N[A];P===0?r(_[C[0]]):_[j]?r(_[j]):r(_[C[0]])}o.actions.updatePrivileges(_)}},w=R.useMemo(()=>e.resources.some(E=>E.exists===!1),[e]);return O.jsxs($D,{openDelay:0,closeDelay:0,children:[O.jsx(VD,{asChild:!0,children:O.jsxs(fn,{depth:4,borderType:(t==null?void 0:t.id)===e.id?"primary":(t==null?void 0:t.id)!==e.id?"light":"default",className:zt("rounded border p-2",{"border-red-400":w&&(t==null?void 0:t.id)!==e.id}),role:"button","data-cy":"privilegeCard",onClick:()=>{r(e)},ref:v,children:[O.jsxs("div",{className:"flex items-center justify-between",children:[O.jsxs("div",{className:"flex flex-1 items-center",children:[O.jsx("span",{className:"mr-4",children:n?O.jsx(_e.FdGuest,{className:"h-6 w-6"}):O.jsx(_e.FdGroup,{className:"h-6 w-6"})}),s?O.jsxs(yt.Root,{color:f?"negative":"primary",className:"flex-1 mr-2",children:[O.jsx(yt.Group,{children:O.jsx(yt.Field,{autoFocus:!0,value:u,onChange:E=>d(E.target.value),onKeyDown:E=>{E.key==="Enter"&&m(),E.key==="Escape"&&g()},onBlur:g,type:"text"})}),f&&O.jsx(yt.Message,{children:f})]}):O.jsx("span",{className:"inline-block grow overflow-hidden truncate whitespace-nowrap text-xs font-bold",children:u})]}),n?O.jsx("div",{className:"flex items-center justify-center",children:O.jsxs($D,{openDelay:0,closeDelay:0,children:[O.jsx(VD,{asChild:!0,children:O.jsx("span",{children:O.jsx(_e.FdInfoBold,{className:"h-4 w-4 text-grey-50"})})}),O.jsx(Cn,{container:yr(),children:O.jsx(Rn,{style:{zIndex:50},avoidCollisions:!0,side:"top",className:"max-w-xs rounded bg-primary-light py-2 text-sm font-semibold text-primary",children:O.jsx("div",{className:"space-y-1 px-2",children:O.jsxs("div",{className:"flex items-start text-s",children:[O.jsx(_e.FdBulb,{className:"mr-2 mt-0.5 h-4 w-4 flex-shrink-0"}),O.jsx("p",{children:"the guest privilege must be used to indicate resources accessible without any permission required (e.g. an authenticate function)"})]})})})})]})}):O.jsx("div",{className:"flex items-center space-x-2",children:s?O.jsxs(O.Fragment,{children:[O.jsx("button",{className:"rounded p-1 hover:bg-primary-hover hover:text-white",onClick:g,children:O.jsx("span",{children:O.jsx(_e.FdClose,{className:"h-4 w-4 text-grey-50"})})}),O.jsx("button",{className:"rounded p-1 hover:bg-primary-hover hover:text-white",onClick:m,children:O.jsx("span",{children:O.jsx(_e.FdCheckCircle,{className:"h-4 w-4 text-grey-50"})})})]}):O.jsxs(O.Fragment,{children:[O.jsx("button",{className:"rounded p-1 hover:bg-primary-hover hover:text-white",onClick:b,children:O.jsx("span",{children:O.jsx(_e.FdPen,{className:"h-4 w-4 text-grey-50"})})}),O.jsx("button",{className:"rounded p-1 hover:bg-primary-hover hover:text-white",onClick:x,children:O.jsx("span",{children:O.jsx(_e.FdTrash,{className:"h-4 w-4 text-grey-50"})})})]})})]}),a.length?O.jsx("div",{className:"ml-[43px]",children:O.jsx(VF,{data:a})}):null]})}),O.jsx(Cn,{container:yr(),children:O.jsxs(Rn,{hidden:!w,style:{zIndex:50},avoidCollisions:!0,side:"top",className:"text-red-500 mb-1 flex max-w-xs items-center gap-x-1 rounded bg-negative-200 px-2 py-2 text-s font-semibold",children:[O.jsx(_e.FdBulb,{className:"m-0.5 h-4 w-4 flex-shrink-0"}),O.jsx("p",{children:"This privilege uses non-existing resources"})]})})]})},tce=({privileges:e,selectPrivilege:t,selectedPrivilege:r})=>{const n=dr(),o=n.getGuestPrivilege(),i=n.getCatalog(),a=R.useMemo(()=>{if(i===null||!o)return o;const s=XB({guest:o},Object.values((i==null?void 0:i.dataClasses)??{}));return ZB(s,i).guest},[e,i]);return O.jsxs("div",{className:"flex flex-1 flex-col gap-y-4 overflow-auto p-4 pb-10 pt-1",children:[a?O.jsx(HD,{privilege:a,onSelect:t,selectedPrivilege:r,isGuest:!0}):null,Object.entries(e).length?Object.entries(e).filter(([,s])=>s.privilege!=="guest").sort(([,s],[,c])=>he.localeCompare(s.privilege,c.privilege)).map(([s,c])=>O.jsx(HD,{privilege:c,onSelect:t,selectedPrivilege:r},s)):O.jsx("div",{className:"flex h-full items-center justify-center",children:O.jsx("div",{className:"flex flex-1 items-center justify-center",children:O.jsxs("div",{className:"flex flex-col items-center justify-center space-y-4",children:[O.jsx(_e.FdInfoBold,{className:"h-10 w-10"}),O.jsx("div",{className:"font-semibold",children:"There are no privileges"}),O.jsxs("div",{className:"flex items-center text-sm",children:["Create a new Privilege by clicking on the"," ",O.jsx(_e.FdPlus,{className:"ml-2 inline h-4 w-4"})]})]})})})]})};var vu={exports:{}},gu={exports:{}},st={};/** @license React v16.13.1
|
|
88
|
+
* react-is.production.min.js
|
|
89
|
+
*
|
|
90
|
+
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
91
|
+
*
|
|
92
|
+
* This source code is licensed under the MIT license found in the
|
|
93
|
+
* LICENSE file in the root directory of this source tree.
|
|
94
|
+
*/var WD;function rce(){if(WD)return st;WD=1;var e=typeof Symbol=="function"&&Symbol.for,t=e?Symbol.for("react.element"):60103,r=e?Symbol.for("react.portal"):60106,n=e?Symbol.for("react.fragment"):60107,o=e?Symbol.for("react.strict_mode"):60108,i=e?Symbol.for("react.profiler"):60114,a=e?Symbol.for("react.provider"):60109,s=e?Symbol.for("react.context"):60110,c=e?Symbol.for("react.async_mode"):60111,u=e?Symbol.for("react.concurrent_mode"):60111,d=e?Symbol.for("react.forward_ref"):60112,f=e?Symbol.for("react.suspense"):60113,h=e?Symbol.for("react.suspense_list"):60120,v=e?Symbol.for("react.memo"):60115,b=e?Symbol.for("react.lazy"):60116,g=e?Symbol.for("react.block"):60121,m=e?Symbol.for("react.fundamental"):60117,x=e?Symbol.for("react.responder"):60118,w=e?Symbol.for("react.scope"):60119;function E(_){if(typeof _=="object"&&_!==null){var C=_.$$typeof;switch(C){case t:switch(_=_.type,_){case c:case u:case n:case i:case o:case f:return _;default:switch(_=_&&_.$$typeof,_){case s:case d:case b:case v:case a:return _;default:return C}}case r:return C}}}function S(_){return E(_)===u}return st.AsyncMode=c,st.ConcurrentMode=u,st.ContextConsumer=s,st.ContextProvider=a,st.Element=t,st.ForwardRef=d,st.Fragment=n,st.Lazy=b,st.Memo=v,st.Portal=r,st.Profiler=i,st.StrictMode=o,st.Suspense=f,st.isAsyncMode=function(_){return S(_)||E(_)===c},st.isConcurrentMode=S,st.isContextConsumer=function(_){return E(_)===s},st.isContextProvider=function(_){return E(_)===a},st.isElement=function(_){return typeof _=="object"&&_!==null&&_.$$typeof===t},st.isForwardRef=function(_){return E(_)===d},st.isFragment=function(_){return E(_)===n},st.isLazy=function(_){return E(_)===b},st.isMemo=function(_){return E(_)===v},st.isPortal=function(_){return E(_)===r},st.isProfiler=function(_){return E(_)===i},st.isStrictMode=function(_){return E(_)===o},st.isSuspense=function(_){return E(_)===f},st.isValidElementType=function(_){return typeof _=="string"||typeof _=="function"||_===n||_===u||_===i||_===o||_===f||_===h||typeof _=="object"&&_!==null&&(_.$$typeof===b||_.$$typeof===v||_.$$typeof===a||_.$$typeof===s||_.$$typeof===d||_.$$typeof===m||_.$$typeof===x||_.$$typeof===w||_.$$typeof===g)},st.typeOf=E,st}var lt={};/** @license React v16.13.1
|
|
95
|
+
* react-is.development.js
|
|
96
|
+
*
|
|
97
|
+
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
98
|
+
*
|
|
99
|
+
* This source code is licensed under the MIT license found in the
|
|
100
|
+
* LICENSE file in the root directory of this source tree.
|
|
101
|
+
*/var UD;function nce(){return UD||(UD=1,process.env.NODE_ENV!=="production"&&(function(){var e=typeof Symbol=="function"&&Symbol.for,t=e?Symbol.for("react.element"):60103,r=e?Symbol.for("react.portal"):60106,n=e?Symbol.for("react.fragment"):60107,o=e?Symbol.for("react.strict_mode"):60108,i=e?Symbol.for("react.profiler"):60114,a=e?Symbol.for("react.provider"):60109,s=e?Symbol.for("react.context"):60110,c=e?Symbol.for("react.async_mode"):60111,u=e?Symbol.for("react.concurrent_mode"):60111,d=e?Symbol.for("react.forward_ref"):60112,f=e?Symbol.for("react.suspense"):60113,h=e?Symbol.for("react.suspense_list"):60120,v=e?Symbol.for("react.memo"):60115,b=e?Symbol.for("react.lazy"):60116,g=e?Symbol.for("react.block"):60121,m=e?Symbol.for("react.fundamental"):60117,x=e?Symbol.for("react.responder"):60118,w=e?Symbol.for("react.scope"):60119;function E(te){return typeof te=="string"||typeof te=="function"||te===n||te===u||te===i||te===o||te===f||te===h||typeof te=="object"&&te!==null&&(te.$$typeof===b||te.$$typeof===v||te.$$typeof===a||te.$$typeof===s||te.$$typeof===d||te.$$typeof===m||te.$$typeof===x||te.$$typeof===w||te.$$typeof===g)}function S(te){if(typeof te=="object"&&te!==null){var be=te.$$typeof;switch(be){case t:var de=te.type;switch(de){case c:case u:case n:case i:case o:case f:return de;default:var Ee=de&&de.$$typeof;switch(Ee){case s:case d:case b:case v:case a:return Ee;default:return be}}case r:return be}}}var _=c,C=u,N=s,P=a,A=t,j=d,M=n,L=b,D=v,T=r,W=i,q=o,G=f,F=!1;function J(te){return F||(F=!0,console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 17+. Update your code to use ReactIs.isConcurrentMode() instead. It has the exact same API.")),z(te)||S(te)===c}function z(te){return S(te)===u}function U(te){return S(te)===s}function oe(te){return S(te)===a}function re(te){return typeof te=="object"&&te!==null&&te.$$typeof===t}function $(te){return S(te)===d}function Y(te){return S(te)===n}function X(te){return S(te)===b}function H(te){return S(te)===v}function K(te){return S(te)===r}function Q(te){return S(te)===i}function ne(te){return S(te)===o}function se(te){return S(te)===f}lt.AsyncMode=_,lt.ConcurrentMode=C,lt.ContextConsumer=N,lt.ContextProvider=P,lt.Element=A,lt.ForwardRef=j,lt.Fragment=M,lt.Lazy=L,lt.Memo=D,lt.Portal=T,lt.Profiler=W,lt.StrictMode=q,lt.Suspense=G,lt.isAsyncMode=J,lt.isConcurrentMode=z,lt.isContextConsumer=U,lt.isContextProvider=oe,lt.isElement=re,lt.isForwardRef=$,lt.isFragment=Y,lt.isLazy=X,lt.isMemo=H,lt.isPortal=K,lt.isProfiler=Q,lt.isStrictMode=ne,lt.isSuspense=se,lt.isValidElementType=E,lt.typeOf=S})()),lt}var GD;function HF(){return GD||(GD=1,process.env.NODE_ENV==="production"?gu.exports=rce():gu.exports=nce()),gu.exports}/*
|
|
102
|
+
object-assign
|
|
103
|
+
(c) Sindre Sorhus
|
|
104
|
+
@license MIT
|
|
105
|
+
*/var b0,YD;function oce(){if(YD)return b0;YD=1;var e=Object.getOwnPropertySymbols,t=Object.prototype.hasOwnProperty,r=Object.prototype.propertyIsEnumerable;function n(i){if(i==null)throw new TypeError("Object.assign cannot be called with null or undefined");return Object(i)}function o(){try{if(!Object.assign)return!1;var i=new String("abc");if(i[5]="de",Object.getOwnPropertyNames(i)[0]==="5")return!1;for(var a={},s=0;s<10;s++)a["_"+String.fromCharCode(s)]=s;var c=Object.getOwnPropertyNames(a).map(function(d){return a[d]});if(c.join("")!=="0123456789")return!1;var u={};return"abcdefghijklmnopqrst".split("").forEach(function(d){u[d]=d}),Object.keys(Object.assign({},u)).join("")==="abcdefghijklmnopqrst"}catch{return!1}}return b0=o()?Object.assign:function(i,a){for(var s,c=n(i),u,d=1;d<arguments.length;d++){s=Object(arguments[d]);for(var f in s)t.call(s,f)&&(c[f]=s[f]);if(e){u=e(s);for(var h=0;h<u.length;h++)r.call(s,u[h])&&(c[u[h]]=s[u[h]])}}return c},b0}var y0,KD;function cE(){if(KD)return y0;KD=1;var e="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED";return y0=e,y0}var x0,XD;function WF(){return XD||(XD=1,x0=Function.call.bind(Object.prototype.hasOwnProperty)),x0}var w0,ZD;function ice(){if(ZD)return w0;ZD=1;var e=function(){};if(process.env.NODE_ENV!=="production"){var t=cE(),r={},n=WF();e=function(i){var a="Warning: "+i;typeof console<"u"&&console.error(a);try{throw new Error(a)}catch{}}}function o(i,a,s,c,u){if(process.env.NODE_ENV!=="production"){for(var d in i)if(n(i,d)){var f;try{if(typeof i[d]!="function"){var h=Error((c||"React class")+": "+s+" type `"+d+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+typeof i[d]+"`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");throw h.name="Invariant Violation",h}f=i[d](a,d,c,s,null,t)}catch(b){f=b}if(f&&!(f instanceof Error)&&e((c||"React class")+": type specification of "+s+" `"+d+"` is invalid; the type checker function must return `null` or an `Error` but returned a "+typeof f+". You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument)."),f instanceof Error&&!(f.message in r)){r[f.message]=!0;var v=u?u():"";e("Failed "+s+" type: "+f.message+(v??""))}}}}return o.resetWarningCache=function(){process.env.NODE_ENV!=="production"&&(r={})},w0=o,w0}var _0,JD;function ace(){if(JD)return _0;JD=1;var e=HF(),t=oce(),r=cE(),n=WF(),o=ice(),i=function(){};process.env.NODE_ENV!=="production"&&(i=function(s){var c="Warning: "+s;typeof console<"u"&&console.error(c);try{throw new Error(c)}catch{}});function a(){return null}return _0=function(s,c){var u=typeof Symbol=="function"&&Symbol.iterator,d="@@iterator";function f(z){var U=z&&(u&&z[u]||z[d]);if(typeof U=="function")return U}var h="<<anonymous>>",v={array:x("array"),bigint:x("bigint"),bool:x("boolean"),func:x("function"),number:x("number"),object:x("object"),string:x("string"),symbol:x("symbol"),any:w(),arrayOf:E,element:S(),elementType:_(),instanceOf:C,node:j(),objectOf:P,oneOf:N,oneOfType:A,shape:L,exact:D};function b(z,U){return z===U?z!==0||1/z===1/U:z!==z&&U!==U}function g(z,U){this.message=z,this.data=U&&typeof U=="object"?U:{},this.stack=""}g.prototype=Error.prototype;function m(z){if(process.env.NODE_ENV!=="production")var U={},oe=0;function re(Y,X,H,K,Q,ne,se){if(K=K||h,ne=ne||H,se!==r){if(c){var te=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use `PropTypes.checkPropTypes()` to call them. Read more at http://fb.me/use-check-prop-types");throw te.name="Invariant Violation",te}else if(process.env.NODE_ENV!=="production"&&typeof console<"u"){var be=K+":"+H;!U[be]&&oe<3&&(i("You are manually calling a React.PropTypes validation function for the `"+ne+"` prop on `"+K+"`. This is deprecated and will throw in the standalone `prop-types` package. You may be seeing this warning due to a third-party PropTypes library. See https://fb.me/react-warning-dont-call-proptypes for details."),U[be]=!0,oe++)}}return X[H]==null?Y?X[H]===null?new g("The "+Q+" `"+ne+"` is marked as required "+("in `"+K+"`, but its value is `null`.")):new g("The "+Q+" `"+ne+"` is marked as required in "+("`"+K+"`, but its value is `undefined`.")):null:z(X,H,K,Q,ne)}var $=re.bind(null,!1);return $.isRequired=re.bind(null,!0),$}function x(z){function U(oe,re,$,Y,X,H){var K=oe[re],Q=q(K);if(Q!==z){var ne=G(K);return new g("Invalid "+Y+" `"+X+"` of type "+("`"+ne+"` supplied to `"+$+"`, expected ")+("`"+z+"`."),{expectedType:z})}return null}return m(U)}function w(){return m(a)}function E(z){function U(oe,re,$,Y,X){if(typeof z!="function")return new g("Property `"+X+"` of component `"+$+"` has invalid PropType notation inside arrayOf.");var H=oe[re];if(!Array.isArray(H)){var K=q(H);return new g("Invalid "+Y+" `"+X+"` of type "+("`"+K+"` supplied to `"+$+"`, expected an array."))}for(var Q=0;Q<H.length;Q++){var ne=z(H,Q,$,Y,X+"["+Q+"]",r);if(ne instanceof Error)return ne}return null}return m(U)}function S(){function z(U,oe,re,$,Y){var X=U[oe];if(!s(X)){var H=q(X);return new g("Invalid "+$+" `"+Y+"` of type "+("`"+H+"` supplied to `"+re+"`, expected a single ReactElement."))}return null}return m(z)}function _(){function z(U,oe,re,$,Y){var X=U[oe];if(!e.isValidElementType(X)){var H=q(X);return new g("Invalid "+$+" `"+Y+"` of type "+("`"+H+"` supplied to `"+re+"`, expected a single ReactElement type."))}return null}return m(z)}function C(z){function U(oe,re,$,Y,X){if(!(oe[re]instanceof z)){var H=z.name||h,K=J(oe[re]);return new g("Invalid "+Y+" `"+X+"` of type "+("`"+K+"` supplied to `"+$+"`, expected ")+("instance of `"+H+"`."))}return null}return m(U)}function N(z){if(!Array.isArray(z))return process.env.NODE_ENV!=="production"&&(arguments.length>1?i("Invalid arguments supplied to oneOf, expected an array, got "+arguments.length+" arguments. A common mistake is to write oneOf(x, y, z) instead of oneOf([x, y, z])."):i("Invalid argument supplied to oneOf, expected an array.")),a;function U(oe,re,$,Y,X){for(var H=oe[re],K=0;K<z.length;K++)if(b(H,z[K]))return null;var Q=JSON.stringify(z,function(se,te){var be=G(te);return be==="symbol"?String(te):te});return new g("Invalid "+Y+" `"+X+"` of value `"+String(H)+"` "+("supplied to `"+$+"`, expected one of "+Q+"."))}return m(U)}function P(z){function U(oe,re,$,Y,X){if(typeof z!="function")return new g("Property `"+X+"` of component `"+$+"` has invalid PropType notation inside objectOf.");var H=oe[re],K=q(H);if(K!=="object")return new g("Invalid "+Y+" `"+X+"` of type "+("`"+K+"` supplied to `"+$+"`, expected an object."));for(var Q in H)if(n(H,Q)){var ne=z(H,Q,$,Y,X+"."+Q,r);if(ne instanceof Error)return ne}return null}return m(U)}function A(z){if(!Array.isArray(z))return process.env.NODE_ENV!=="production"&&i("Invalid argument supplied to oneOfType, expected an instance of array."),a;for(var U=0;U<z.length;U++){var oe=z[U];if(typeof oe!="function")return i("Invalid argument supplied to oneOfType. Expected an array of check functions, but received "+F(oe)+" at index "+U+"."),a}function re($,Y,X,H,K){for(var Q=[],ne=0;ne<z.length;ne++){var se=z[ne],te=se($,Y,X,H,K,r);if(te==null)return null;te.data&&n(te.data,"expectedType")&&Q.push(te.data.expectedType)}var be=Q.length>0?", expected one of type ["+Q.join(", ")+"]":"";return new g("Invalid "+H+" `"+K+"` supplied to "+("`"+X+"`"+be+"."))}return m(re)}function j(){function z(U,oe,re,$,Y){return T(U[oe])?null:new g("Invalid "+$+" `"+Y+"` supplied to "+("`"+re+"`, expected a ReactNode."))}return m(z)}function M(z,U,oe,re,$){return new g((z||"React class")+": "+U+" type `"+oe+"."+re+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+$+"`.")}function L(z){function U(oe,re,$,Y,X){var H=oe[re],K=q(H);if(K!=="object")return new g("Invalid "+Y+" `"+X+"` of type `"+K+"` "+("supplied to `"+$+"`, expected `object`."));for(var Q in z){var ne=z[Q];if(typeof ne!="function")return M($,Y,X,Q,G(ne));var se=ne(H,Q,$,Y,X+"."+Q,r);if(se)return se}return null}return m(U)}function D(z){function U(oe,re,$,Y,X){var H=oe[re],K=q(H);if(K!=="object")return new g("Invalid "+Y+" `"+X+"` of type `"+K+"` "+("supplied to `"+$+"`, expected `object`."));var Q=t({},oe[re],z);for(var ne in Q){var se=z[ne];if(n(z,ne)&&typeof se!="function")return M($,Y,X,ne,G(se));if(!se)return new g("Invalid "+Y+" `"+X+"` key `"+ne+"` supplied to `"+$+"`.\nBad object: "+JSON.stringify(oe[re],null," ")+`
|
|
106
|
+
Valid keys: `+JSON.stringify(Object.keys(z),null," "));var te=se(H,ne,$,Y,X+"."+ne,r);if(te)return te}return null}return m(U)}function T(z){switch(typeof z){case"number":case"string":case"undefined":return!0;case"boolean":return!z;case"object":if(Array.isArray(z))return z.every(T);if(z===null||s(z))return!0;var U=f(z);if(U){var oe=U.call(z),re;if(U!==z.entries){for(;!(re=oe.next()).done;)if(!T(re.value))return!1}else for(;!(re=oe.next()).done;){var $=re.value;if($&&!T($[1]))return!1}}else return!1;return!0;default:return!1}}function W(z,U){return z==="symbol"?!0:U?U["@@toStringTag"]==="Symbol"||typeof Symbol=="function"&&U instanceof Symbol:!1}function q(z){var U=typeof z;return Array.isArray(z)?"array":z instanceof RegExp?"object":W(U,z)?"symbol":U}function G(z){if(typeof z>"u"||z===null)return""+z;var U=q(z);if(U==="object"){if(z instanceof Date)return"date";if(z instanceof RegExp)return"regexp"}return U}function F(z){var U=G(z);switch(U){case"array":case"object":return"an "+U;case"boolean":case"date":case"regexp":return"a "+U;default:return U}}function J(z){return!z.constructor||!z.constructor.name?h:z.constructor.name}return v.checkPropTypes=o,v.resetWarningCache=o.resetWarningCache,v.PropTypes=v,v},_0}var E0,QD;function sce(){if(QD)return E0;QD=1;var e=cE();function t(){}function r(){}return r.resetWarningCache=t,E0=function(){function n(a,s,c,u,d,f){if(f!==e){var h=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw h.name="Invariant Violation",h}}n.isRequired=n;function o(){return n}var i={array:n,bigint:n,bool:n,func:n,number:n,object:n,string:n,symbol:n,any:n,arrayOf:o,element:n,elementType:n,instanceOf:o,node:n,objectOf:o,oneOf:o,oneOfType:o,shape:o,exact:o,checkPropTypes:r,resetWarningCache:t};return i.PropTypes=i,i},E0}var eM;function lce(){if(eM)return vu.exports;if(eM=1,process.env.NODE_ENV!=="production"){var e=HF(),t=!0;vu.exports=ace()(e.isElement,t)}else vu.exports=sce()();return vu.exports}var cce=lce();const pe=Zo(cce);var mu={exports:{}},ft={};/** @license React v17.0.2
|
|
107
|
+
* react-is.production.min.js
|
|
108
|
+
*
|
|
109
|
+
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
110
|
+
*
|
|
111
|
+
* This source code is licensed under the MIT license found in the
|
|
112
|
+
* LICENSE file in the root directory of this source tree.
|
|
113
|
+
*/var tM;function uce(){if(tM)return ft;tM=1;var e=60103,t=60106,r=60107,n=60108,o=60114,i=60109,a=60110,s=60112,c=60113,u=60120,d=60115,f=60116,h=60121,v=60122,b=60117,g=60129,m=60131;if(typeof Symbol=="function"&&Symbol.for){var x=Symbol.for;e=x("react.element"),t=x("react.portal"),r=x("react.fragment"),n=x("react.strict_mode"),o=x("react.profiler"),i=x("react.provider"),a=x("react.context"),s=x("react.forward_ref"),c=x("react.suspense"),u=x("react.suspense_list"),d=x("react.memo"),f=x("react.lazy"),h=x("react.block"),v=x("react.server.block"),b=x("react.fundamental"),g=x("react.debug_trace_mode"),m=x("react.legacy_hidden")}function w(D){if(typeof D=="object"&&D!==null){var T=D.$$typeof;switch(T){case e:switch(D=D.type,D){case r:case o:case n:case c:case u:return D;default:switch(D=D&&D.$$typeof,D){case a:case s:case f:case d:case i:return D;default:return T}}case t:return T}}}var E=i,S=e,_=s,C=r,N=f,P=d,A=t,j=o,M=n,L=c;return ft.ContextConsumer=a,ft.ContextProvider=E,ft.Element=S,ft.ForwardRef=_,ft.Fragment=C,ft.Lazy=N,ft.Memo=P,ft.Portal=A,ft.Profiler=j,ft.StrictMode=M,ft.Suspense=L,ft.isAsyncMode=function(){return!1},ft.isConcurrentMode=function(){return!1},ft.isContextConsumer=function(D){return w(D)===a},ft.isContextProvider=function(D){return w(D)===i},ft.isElement=function(D){return typeof D=="object"&&D!==null&&D.$$typeof===e},ft.isForwardRef=function(D){return w(D)===s},ft.isFragment=function(D){return w(D)===r},ft.isLazy=function(D){return w(D)===f},ft.isMemo=function(D){return w(D)===d},ft.isPortal=function(D){return w(D)===t},ft.isProfiler=function(D){return w(D)===o},ft.isStrictMode=function(D){return w(D)===n},ft.isSuspense=function(D){return w(D)===c},ft.isValidElementType=function(D){return typeof D=="string"||typeof D=="function"||D===r||D===o||D===g||D===n||D===c||D===u||D===m||typeof D=="object"&&D!==null&&(D.$$typeof===f||D.$$typeof===d||D.$$typeof===i||D.$$typeof===a||D.$$typeof===s||D.$$typeof===b||D.$$typeof===h||D[0]===v)},ft.typeOf=w,ft}var pt={};/** @license React v17.0.2
|
|
114
|
+
* react-is.development.js
|
|
115
|
+
*
|
|
116
|
+
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
117
|
+
*
|
|
118
|
+
* This source code is licensed under the MIT license found in the
|
|
119
|
+
* LICENSE file in the root directory of this source tree.
|
|
120
|
+
*/var rM;function dce(){return rM||(rM=1,process.env.NODE_ENV!=="production"&&(function(){var e=60103,t=60106,r=60107,n=60108,o=60114,i=60109,a=60110,s=60112,c=60113,u=60120,d=60115,f=60116,h=60121,v=60122,b=60117,g=60129,m=60131;if(typeof Symbol=="function"&&Symbol.for){var x=Symbol.for;e=x("react.element"),t=x("react.portal"),r=x("react.fragment"),n=x("react.strict_mode"),o=x("react.profiler"),i=x("react.provider"),a=x("react.context"),s=x("react.forward_ref"),c=x("react.suspense"),u=x("react.suspense_list"),d=x("react.memo"),f=x("react.lazy"),h=x("react.block"),v=x("react.server.block"),b=x("react.fundamental"),x("react.scope"),x("react.opaque.id"),g=x("react.debug_trace_mode"),x("react.offscreen"),m=x("react.legacy_hidden")}var w=!1;function E(se){return!!(typeof se=="string"||typeof se=="function"||se===r||se===o||se===g||se===n||se===c||se===u||se===m||w||typeof se=="object"&&se!==null&&(se.$$typeof===f||se.$$typeof===d||se.$$typeof===i||se.$$typeof===a||se.$$typeof===s||se.$$typeof===b||se.$$typeof===h||se[0]===v))}function S(se){if(typeof se=="object"&&se!==null){var te=se.$$typeof;switch(te){case e:var be=se.type;switch(be){case r:case o:case n:case c:case u:return be;default:var de=be&&be.$$typeof;switch(de){case a:case s:case f:case d:case i:return de;default:return te}}case t:return te}}}var _=a,C=i,N=e,P=s,A=r,j=f,M=d,L=t,D=o,T=n,W=c,q=!1,G=!1;function F(se){return q||(q=!0,console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 18+.")),!1}function J(se){return G||(G=!0,console.warn("The ReactIs.isConcurrentMode() alias has been deprecated, and will be removed in React 18+.")),!1}function z(se){return S(se)===a}function U(se){return S(se)===i}function oe(se){return typeof se=="object"&&se!==null&&se.$$typeof===e}function re(se){return S(se)===s}function $(se){return S(se)===r}function Y(se){return S(se)===f}function X(se){return S(se)===d}function H(se){return S(se)===t}function K(se){return S(se)===o}function Q(se){return S(se)===n}function ne(se){return S(se)===c}pt.ContextConsumer=_,pt.ContextProvider=C,pt.Element=N,pt.ForwardRef=P,pt.Fragment=A,pt.Lazy=j,pt.Memo=M,pt.Portal=L,pt.Profiler=D,pt.StrictMode=T,pt.Suspense=W,pt.isAsyncMode=F,pt.isConcurrentMode=J,pt.isContextConsumer=z,pt.isContextProvider=U,pt.isElement=oe,pt.isForwardRef=re,pt.isFragment=$,pt.isLazy=Y,pt.isMemo=X,pt.isPortal=H,pt.isProfiler=K,pt.isStrictMode=Q,pt.isSuspense=ne,pt.isValidElementType=E,pt.typeOf=S})()),pt}var nM;function fce(){return nM||(nM=1,process.env.NODE_ENV==="production"?mu.exports=uce():mu.exports=dce()),mu.exports}var oM=fce();function iM(e){return typeof e=="object"&&e!=null&&e.nodeType===1}function aM(e,t){return(!t||e!=="hidden")&&e!=="visible"&&e!=="clip"}function S0(e,t){if(e.clientHeight<e.scrollHeight||e.clientWidth<e.scrollWidth){var r=getComputedStyle(e,null);return aM(r.overflowY,t)||aM(r.overflowX,t)||(function(n){var o=(function(i){if(!i.ownerDocument||!i.ownerDocument.defaultView)return null;try{return i.ownerDocument.defaultView.frameElement}catch{return null}})(n);return!!o&&(o.clientHeight<n.scrollHeight||o.clientWidth<n.scrollWidth)})(e)}return!1}function bu(e,t,r,n,o,i,a,s){return i<e&&a>t||i>e&&a<t?0:i<=e&&s<=r||a>=t&&s>=r?i-e-n:a>t&&s<r||i<e&&s>r?a-t+o:0}var pce=function(e,t){var r=window,n=t.inline,o=t.boundary,i=t.skipOverflowHiddenElements,a=typeof o=="function"?o:function(te){return te!==o};if(!iM(e))throw new TypeError("Invalid target");for(var s,c,u=document.scrollingElement||document.documentElement,d=[],f=e;iM(f)&&a(f);){if((f=(c=(s=f).parentElement)==null?s.getRootNode().host||null:c)===u){d.push(f);break}f!=null&&f===document.body&&S0(f)&&!S0(document.documentElement)||f!=null&&S0(f,i)&&d.push(f)}for(var h=r.visualViewport?r.visualViewport.width:innerWidth,v=r.visualViewport?r.visualViewport.height:innerHeight,b=window.scrollX||pageXOffset,g=window.scrollY||pageYOffset,m=e.getBoundingClientRect(),x=m.height,w=m.width,E=m.top,S=m.right,_=m.bottom,C=m.left,N=E,P=n==="center"?C+w/2:n==="end"?S:C,A=[],j=0;j<d.length;j++){var M=d[j],L=M.getBoundingClientRect(),D=L.height,T=L.width,W=L.top,q=L.right,G=L.bottom,F=L.left;if(E>=0&&C>=0&&_<=v&&S<=h&&E>=W&&_<=G&&C>=F&&S<=q)return A;var J=getComputedStyle(M),z=parseInt(J.borderLeftWidth,10),U=parseInt(J.borderTopWidth,10),oe=parseInt(J.borderRightWidth,10),re=parseInt(J.borderBottomWidth,10),$=0,Y=0,X="offsetWidth"in M?M.offsetWidth-M.clientWidth-z-oe:0,H="offsetHeight"in M?M.offsetHeight-M.clientHeight-U-re:0,K="offsetWidth"in M?M.offsetWidth===0?0:T/M.offsetWidth:0,Q="offsetHeight"in M?M.offsetHeight===0?0:D/M.offsetHeight:0;if(u===M)$=bu(g,g+v,v,U,re,g+N,g+N+x,x),Y=n==="start"?P:n==="center"?P-h/2:n==="end"?P-h:bu(b,b+h,h,z,oe,b+P,b+P+w,w),$=Math.max(0,$+g),Y=Math.max(0,Y+b);else{$=bu(W,G,D,U,re+H,N,N+x,x),Y=n==="start"?P-F-z:n==="center"?P-(F+T/2)+X/2:n==="end"?P-q+oe+X:bu(F,q,T,z,oe+X,P,P+w,w);var ne=M.scrollLeft,se=M.scrollTop;N+=se-($=Math.max(0,Math.min(se+$/Q,M.scrollHeight-D/Q+H))),P+=ne-(Y=Math.max(0,Math.min(ne+Y/K,M.scrollWidth-T/K+X)))}A.push({el:M,top:$,left:Y})}return A};let hce=0;function sM(e){return typeof e=="function"?e:ln}function ln(){}function UF(e,t){if(!e)return;pce(e,{boundary:t}).forEach(n=>{let{el:o,top:i,left:a}=n;o.scrollTop=i,o.scrollLeft=a})}function lM(e,t,r){return e===t||t instanceof r.Node&&e.contains&&e.contains(t)}function uE(e,t){let r;function n(){r&&clearTimeout(r)}function o(){for(var i=arguments.length,a=new Array(i),s=0;s<i;s++)a[s]=arguments[s];n(),r=setTimeout(()=>{r=null,e(...a)},t)}return o.cancel=n,o}function Zt(){for(var e=arguments.length,t=new Array(e),r=0;r<e;r++)t[r]=arguments[r];return function(n){for(var o=arguments.length,i=new Array(o>1?o-1:0),a=1;a<o;a++)i[a-1]=arguments[a];return t.some(s=>(s&&s(n,...i),n.preventDownshiftDefault||n.hasOwnProperty("nativeEvent")&&n.nativeEvent.preventDownshiftDefault))}}function hi(){for(var e=arguments.length,t=new Array(e),r=0;r<e;r++)t[r]=arguments[r];return n=>{t.forEach(o=>{typeof o=="function"?o(n):o&&(o.current=n)})}}function GF(){return String(hce++)}function YF(e){let{isOpen:t,resultCount:r,previousResultCount:n}=e;return t?r?r!==n?`${r} result${r===1?" is":"s are"} available, use up and down arrow keys to navigate. Press Enter key to select.`:"":"No results are available.":""}function cM(e,t){return e=Array.isArray(e)?e[0]:e,!e&&t?t:e}function KF(e){return typeof e.type=="string"}function XF(e){return e.props}function vce(e,t){console.error(`The property "${t}" is required in "${e}"`)}const gce=["highlightedIndex","inputValue","isOpen","selectedItem","type"];function yu(e){e===void 0&&(e={});const t={};return gce.forEach(r=>{e.hasOwnProperty(r)&&(t[r]=e[r])}),t}function _d(e,t){return Object.keys(e).reduce((r,n)=>(r[n]=Ed(t,n)?t[n]:e[n],r),{})}function Ed(e,t){return e[t]!==void 0}function F_(e){const{key:t,keyCode:r}=e;return r>=37&&r<=40&&t.indexOf("Arrow")!==0?`Arrow${t}`:t}function mce(e){return Object.prototype.toString.call(e)==="[object Object]"}function ya(e,t,r,n,o){if(o===void 0&&(o=!0),r===0)return-1;const i=r-1;(typeof t!="number"||t<0||t>=r)&&(t=e>0?-1:i+1);let a=t+e;a<0?a=o?i:0:a>i&&(a=o?0:i);const s=Ri(e,a,r,n,o);return s===-1?t>=r?-1:t:s}function Ri(e,t,r,n,o){const i=n(t);if(!i||!i.hasAttribute("disabled"))return t;if(e>0){for(let a=t+1;a<r;a++)if(!n(a).hasAttribute("disabled"))return a}else for(let a=t-1;a>=0;a--)if(!n(a).hasAttribute("disabled"))return a;return o?e>0?Ri(1,0,r,n,!1):Ri(-1,r-1,r,n,!1):-1}function Sd(e,t,r,n){return n===void 0&&(n=!0),t.some(o=>o&&(lM(o,e,r)||n&&lM(o,r.document.activeElement,r)))}let dE=ln;process.env.NODE_ENV!=="production"&&(dE=(e,t,r)=>{const n="This prop should not switch from controlled to uncontrolled (or vice versa). Decide between using a controlled or uncontrolled Downshift element for the lifetime of the component. More info: https://github.com/downshift-js/downshift#control-props";Object.keys(e).forEach(o=>{t[o]!==void 0&&r[o]===void 0?console.error(`downshift: A component has changed the controlled prop "${o}" to be uncontrolled. ${n}`):t[o]===void 0&&r[o]!==void 0&&console.error(`downshift: A component has changed the uncontrolled prop "${o}" to be controlled. ${n}`)})});const bce=uE(e=>{JF(e).textContent=""},500);function ZF(e,t){const r=JF(t);e&&(r.textContent=e,bce(t))}function JF(e){e===void 0&&(e=document);let t=e.getElementById("a11y-status-message");return t||(t=e.createElement("div"),t.setAttribute("id","a11y-status-message"),t.setAttribute("role","status"),t.setAttribute("aria-live","polite"),t.setAttribute("aria-relevant","additions text"),Object.assign(t.style,{border:"0",clip:"rect(0 0 0 0)",height:"1px",margin:"-1px",overflow:"hidden",padding:"0",position:"absolute",width:"1px"}),e.body.appendChild(t),t)}const QF=process.env.NODE_ENV!=="production"?"__autocomplete_unknown__":0,e3=process.env.NODE_ENV!=="production"?"__autocomplete_mouseup__":1,t3=process.env.NODE_ENV!=="production"?"__autocomplete_item_mouseenter__":2,Bu=process.env.NODE_ENV!=="production"?"__autocomplete_keydown_arrow_up__":3,Fu=process.env.NODE_ENV!=="production"?"__autocomplete_keydown_arrow_down__":4,r3=process.env.NODE_ENV!=="production"?"__autocomplete_keydown_escape__":5,n3=process.env.NODE_ENV!=="production"?"__autocomplete_keydown_enter__":6,o3=process.env.NODE_ENV!=="production"?"__autocomplete_keydown_home__":7,i3=process.env.NODE_ENV!=="production"?"__autocomplete_keydown_end__":8,a3=process.env.NODE_ENV!=="production"?"__autocomplete_click_item__":9,s3=process.env.NODE_ENV!=="production"?"__autocomplete_blur_input__":10,l3=process.env.NODE_ENV!=="production"?"__autocomplete_change_input__":11,c3=process.env.NODE_ENV!=="production"?"__autocomplete_keydown_space_button__":12,$_=process.env.NODE_ENV!=="production"?"__autocomplete_click_button__":13,u3=process.env.NODE_ENV!=="production"?"__autocomplete_blur_button__":14,d3=process.env.NODE_ENV!=="production"?"__autocomplete_controlled_prop_updated_selected_item__":15,f3=process.env.NODE_ENV!=="production"?"__autocomplete_touchend__":16;var yce=Object.freeze({__proto__:null,unknown:QF,mouseUp:e3,itemMouseEnter:t3,keyDownArrowUp:Bu,keyDownArrowDown:Fu,keyDownEscape:r3,keyDownEnter:n3,keyDownHome:o3,keyDownEnd:i3,clickItem:a3,blurInput:s3,changeInput:l3,keyDownSpaceButton:c3,clickButton:$_,blurButton:u3,controlledPropUpdatedSelectedItem:d3,touchEnd:f3});const xce=(()=>{class e extends R.Component{constructor(r){var n;super(r),n=this,this.id=this.props.id||`downshift-${GF()}`,this.menuId=this.props.menuId||`${this.id}-menu`,this.labelId=this.props.labelId||`${this.id}-label`,this.inputId=this.props.inputId||`${this.id}-input`,this.getItemId=this.props.getItemId||(f=>`${this.id}-item-${f}`),this.input=null,this.items=[],this.itemCount=null,this.previousResultCount=0,this.timeoutIds=[],this.internalSetTimeout=(f,h)=>{const v=setTimeout(()=>{this.timeoutIds=this.timeoutIds.filter(b=>b!==v),f()},h);this.timeoutIds.push(v)},this.setItemCount=f=>{this.itemCount=f},this.unsetItemCount=()=>{this.itemCount=null},this.setHighlightedIndex=function(f,h){f===void 0&&(f=n.props.defaultHighlightedIndex),h===void 0&&(h={}),h=yu(h),n.internalSetState({highlightedIndex:f,...h})},this.clearSelection=f=>{this.internalSetState({selectedItem:null,inputValue:"",highlightedIndex:this.props.defaultHighlightedIndex,isOpen:this.props.defaultIsOpen},f)},this.selectItem=(f,h,v)=>{h=yu(h),this.internalSetState({isOpen:this.props.defaultIsOpen,highlightedIndex:this.props.defaultHighlightedIndex,selectedItem:f,inputValue:this.props.itemToString(f),...h},v)},this.selectItemAtIndex=(f,h,v)=>{const b=this.items[f];b!=null&&this.selectItem(b,h,v)},this.selectHighlightedItem=(f,h)=>this.selectItemAtIndex(this.getState().highlightedIndex,f,h),this.internalSetState=(f,h)=>{let v,b;const g={},m=typeof f=="function";return!m&&f.hasOwnProperty("inputValue")&&this.props.onInputValueChange(f.inputValue,{...this.getStateAndHelpers(),...f}),this.setState(x=>{x=this.getState(x);let w=m?f(x):f;w=this.props.stateReducer(x,w),v=w.hasOwnProperty("selectedItem");const E={};return v&&w.selectedItem!==x.selectedItem&&(b=w.selectedItem),w.type=w.type||QF,Object.keys(w).forEach(S=>{x[S]!==w[S]&&(g[S]=w[S]),S!=="type"&&(w[S],Ed(this.props,S)||(E[S]=w[S]))}),m&&w.hasOwnProperty("inputValue")&&this.props.onInputValueChange(w.inputValue,{...this.getStateAndHelpers(),...w}),E},()=>{sM(h)(),Object.keys(g).length>1&&this.props.onStateChange(g,this.getStateAndHelpers()),v&&this.props.onSelect(f.selectedItem,this.getStateAndHelpers()),b!==void 0&&this.props.onChange(b,this.getStateAndHelpers()),this.props.onUserAction(g,this.getStateAndHelpers())})},this.rootRef=f=>this._rootNode=f,this.getRootProps=function(f,h){let{refKey:v="ref",ref:b,...g}=f===void 0?{}:f,{suppressRefError:m=!1}=h===void 0?{}:h;n.getRootProps.called=!0,n.getRootProps.refKey=v,n.getRootProps.suppressRefError=m;const{isOpen:x}=n.getState();return{[v]:hi(b,n.rootRef),role:"combobox","aria-expanded":x,"aria-haspopup":"listbox","aria-owns":x?n.menuId:null,"aria-labelledby":n.labelId,...g}},this.keyDownHandlers={ArrowDown(f){if(f.preventDefault(),this.getState().isOpen){const h=f.shiftKey?5:1;this.moveHighlightedIndex(h,{type:Fu})}else this.internalSetState({isOpen:!0,type:Fu},()=>{const h=this.getItemCount();if(h>0){const{highlightedIndex:v}=this.getState(),b=ya(1,v,h,g=>this.getItemNodeFromIndex(g));this.setHighlightedIndex(b,{type:Fu})}})},ArrowUp(f){if(f.preventDefault(),this.getState().isOpen){const h=f.shiftKey?-5:-1;this.moveHighlightedIndex(h,{type:Bu})}else this.internalSetState({isOpen:!0,type:Bu},()=>{const h=this.getItemCount();if(h>0){const{highlightedIndex:v}=this.getState(),b=ya(-1,v,h,g=>this.getItemNodeFromIndex(g));this.setHighlightedIndex(b,{type:Bu})}})},Enter(f){if(f.which===229)return;const{isOpen:h,highlightedIndex:v}=this.getState();if(h&&v!=null){f.preventDefault();const b=this.items[v],g=this.getItemNodeFromIndex(v);if(b==null||g&&g.hasAttribute("disabled"))return;this.selectHighlightedItem({type:n3})}},Escape(f){f.preventDefault(),this.reset({type:r3,...!this.state.isOpen&&{selectedItem:null,inputValue:""}})}},this.buttonKeyDownHandlers={...this.keyDownHandlers," "(f){f.preventDefault(),this.toggleMenu({type:c3})}},this.inputKeyDownHandlers={...this.keyDownHandlers,Home(f){const{isOpen:h}=this.getState();if(!h)return;f.preventDefault();const v=this.getItemCount();if(v<=0||!h)return;const b=Ri(1,0,v,g=>this.getItemNodeFromIndex(g),!1);this.setHighlightedIndex(b,{type:o3})},End(f){const{isOpen:h}=this.getState();if(!h)return;f.preventDefault();const v=this.getItemCount();if(v<=0||!h)return;const b=Ri(-1,v-1,v,g=>this.getItemNodeFromIndex(g),!1);this.setHighlightedIndex(b,{type:i3})}},this.getToggleButtonProps=function(f){let{onClick:h,onPress:v,onKeyDown:b,onKeyUp:g,onBlur:m,...x}=f===void 0?{}:f;const{isOpen:w}=n.getState(),E={onClick:Zt(h,n.buttonHandleClick),onKeyDown:Zt(b,n.buttonHandleKeyDown),onKeyUp:Zt(g,n.buttonHandleKeyUp),onBlur:Zt(m,n.buttonHandleBlur)},S=x.disabled?{}:E;return{type:"button",role:"button","aria-label":w?"close menu":"open menu","aria-haspopup":!0,"data-toggle":!0,...S,...x}},this.buttonHandleKeyUp=f=>{f.preventDefault()},this.buttonHandleKeyDown=f=>{const h=F_(f);this.buttonKeyDownHandlers[h]&&this.buttonKeyDownHandlers[h].call(this,f)},this.buttonHandleClick=f=>{f.preventDefault(),this.props.environment.document.activeElement===this.props.environment.document.body&&f.target.focus(),process.env.NODE_ENV==="test"?this.toggleMenu({type:$_}):this.internalSetTimeout(()=>this.toggleMenu({type:$_}))},this.buttonHandleBlur=f=>{const h=f.target;this.internalSetTimeout(()=>{!this.isMouseDown&&(this.props.environment.document.activeElement==null||this.props.environment.document.activeElement.id!==this.inputId)&&this.props.environment.document.activeElement!==h&&this.reset({type:u3})})},this.getLabelProps=f=>({htmlFor:this.inputId,id:this.labelId,...f}),this.getInputProps=function(f){let{onKeyDown:h,onBlur:v,onChange:b,onInput:g,onChangeText:m,...x}=f===void 0?{}:f,w,E={};w="onChange";const{inputValue:S,isOpen:_,highlightedIndex:C}=n.getState();return x.disabled||(E={[w]:Zt(b,g,n.inputHandleChange),onKeyDown:Zt(h,n.inputHandleKeyDown),onBlur:Zt(v,n.inputHandleBlur)}),{"aria-autocomplete":"list","aria-activedescendant":_&&typeof C=="number"&&C>=0?n.getItemId(C):null,"aria-controls":_?n.menuId:null,"aria-labelledby":n.labelId,autoComplete:"off",value:S,id:n.inputId,...E,...x}},this.inputHandleKeyDown=f=>{const h=F_(f);h&&this.inputKeyDownHandlers[h]&&this.inputKeyDownHandlers[h].call(this,f)},this.inputHandleChange=f=>{this.internalSetState({type:l3,isOpen:!0,inputValue:f.target.value,highlightedIndex:this.props.defaultHighlightedIndex})},this.inputHandleBlur=()=>{this.internalSetTimeout(()=>{const f=this.props.environment.document&&!!this.props.environment.document.activeElement&&!!this.props.environment.document.activeElement.dataset&&this.props.environment.document.activeElement.dataset.toggle&&this._rootNode&&this._rootNode.contains(this.props.environment.document.activeElement);!this.isMouseDown&&!f&&this.reset({type:s3})})},this.menuRef=f=>{this._menuNode=f},this.getMenuProps=function(f,h){let{refKey:v="ref",ref:b,...g}=f===void 0?{}:f,{suppressRefError:m=!1}=h===void 0?{}:h;return n.getMenuProps.called=!0,n.getMenuProps.refKey=v,n.getMenuProps.suppressRefError=m,{[v]:hi(b,n.menuRef),role:"listbox","aria-labelledby":g&&g["aria-label"]?null:n.labelId,id:n.menuId,...g}},this.getItemProps=function(f){let{onMouseMove:h,onMouseDown:v,onClick:b,onPress:g,index:m,item:x=process.env.NODE_ENV==="production"?void 0:vce("getItemProps","item"),...w}=f===void 0?{}:f;m===void 0?(n.items.push(x),m=n.items.indexOf(x)):n.items[m]=x;const E="onClick",S=b,_={onMouseMove:Zt(h,()=>{m!==n.getState().highlightedIndex&&(n.setHighlightedIndex(m,{type:t3}),n.avoidScrolling=!0,n.internalSetTimeout(()=>n.avoidScrolling=!1,250))}),onMouseDown:Zt(v,N=>{N.preventDefault()}),[E]:Zt(S,()=>{n.selectItemAtIndex(m,{type:a3})})},C=w.disabled?{onMouseDown:_.onMouseDown}:_;return{id:n.getItemId(m),role:"option","aria-selected":n.getState().highlightedIndex===m,...C,...w}},this.clearItems=()=>{this.items=[]},this.reset=function(f,h){f===void 0&&(f={}),f=yu(f),n.internalSetState(v=>{let{selectedItem:b}=v;return{isOpen:n.props.defaultIsOpen,highlightedIndex:n.props.defaultHighlightedIndex,inputValue:n.props.itemToString(b),...f}},h)},this.toggleMenu=function(f,h){f===void 0&&(f={}),f=yu(f),n.internalSetState(v=>{let{isOpen:b}=v;return{isOpen:!b,...b&&{highlightedIndex:n.props.defaultHighlightedIndex},...f}},()=>{const{isOpen:v,highlightedIndex:b}=n.getState();v&&n.getItemCount()>0&&typeof b=="number"&&n.setHighlightedIndex(b,f),sM(h)()})},this.openMenu=f=>{this.internalSetState({isOpen:!0},f)},this.closeMenu=f=>{this.internalSetState({isOpen:!1},f)},this.updateStatus=uE(()=>{const f=this.getState(),h=this.items[f.highlightedIndex],v=this.getItemCount(),b=this.props.getA11yStatusMessage({itemToString:this.props.itemToString,previousResultCount:this.previousResultCount,resultCount:v,highlightedItem:h,...f});this.previousResultCount=v,ZF(b,this.props.environment.document)},200);const{defaultHighlightedIndex:o,initialHighlightedIndex:i=o,defaultIsOpen:a,initialIsOpen:s=a,initialInputValue:c="",initialSelectedItem:u=null}=this.props,d=this.getState({highlightedIndex:i,isOpen:s,inputValue:c,selectedItem:u});d.selectedItem!=null&&this.props.initialInputValue===void 0&&(d.inputValue=this.props.itemToString(d.selectedItem)),this.state=d}internalClearTimeouts(){this.timeoutIds.forEach(r=>{clearTimeout(r)}),this.timeoutIds=[]}getState(r){return r===void 0&&(r=this.state),_d(r,this.props)}getItemCount(){let r=this.items.length;return this.itemCount!=null?r=this.itemCount:this.props.itemCount!==void 0&&(r=this.props.itemCount),r}getItemNodeFromIndex(r){return this.props.environment.document.getElementById(this.getItemId(r))}scrollHighlightedItemIntoView(){{const r=this.getItemNodeFromIndex(this.getState().highlightedIndex);this.props.scrollIntoView(r,this._menuNode)}}moveHighlightedIndex(r,n){const o=this.getItemCount(),{highlightedIndex:i}=this.getState();if(o>0){const a=ya(r,i,o,s=>this.getItemNodeFromIndex(s));this.setHighlightedIndex(a,n)}}getStateAndHelpers(){const{highlightedIndex:r,inputValue:n,selectedItem:o,isOpen:i}=this.getState(),{itemToString:a}=this.props,{id:s}=this,{getRootProps:c,getToggleButtonProps:u,getLabelProps:d,getMenuProps:f,getInputProps:h,getItemProps:v,openMenu:b,closeMenu:g,toggleMenu:m,selectItem:x,selectItemAtIndex:w,selectHighlightedItem:E,setHighlightedIndex:S,clearSelection:_,clearItems:C,reset:N,setItemCount:P,unsetItemCount:A,internalSetState:j}=this;return{getRootProps:c,getToggleButtonProps:u,getLabelProps:d,getMenuProps:f,getInputProps:h,getItemProps:v,reset:N,openMenu:b,closeMenu:g,toggleMenu:m,selectItem:x,selectItemAtIndex:w,selectHighlightedItem:E,setHighlightedIndex:S,clearSelection:_,clearItems:C,setItemCount:P,unsetItemCount:A,setState:j,itemToString:a,id:s,highlightedIndex:r,inputValue:n,isOpen:i,selectedItem:o}}componentDidMount(){process.env.NODE_ENV!=="production"&&this.getMenuProps.called&&!this.getMenuProps.suppressRefError&&uM(this._menuNode,this.getMenuProps);{const r=()=>{this.isMouseDown=!0},n=c=>{this.isMouseDown=!1,!Sd(c.target,[this._rootNode,this._menuNode],this.props.environment)&&this.getState().isOpen&&this.reset({type:e3},()=>this.props.onOuterClick(this.getStateAndHelpers()))},o=()=>{this.isTouchMove=!1},i=()=>{this.isTouchMove=!0},a=c=>{const u=Sd(c.target,[this._rootNode,this._menuNode],this.props.environment,!1);!this.isTouchMove&&!u&&this.getState().isOpen&&this.reset({type:f3},()=>this.props.onOuterClick(this.getStateAndHelpers()))},{environment:s}=this.props;s.addEventListener("mousedown",r),s.addEventListener("mouseup",n),s.addEventListener("touchstart",o),s.addEventListener("touchmove",i),s.addEventListener("touchend",a),this.cleanup=()=>{this.internalClearTimeouts(),this.updateStatus.cancel(),s.removeEventListener("mousedown",r),s.removeEventListener("mouseup",n),s.removeEventListener("touchstart",o),s.removeEventListener("touchmove",i),s.removeEventListener("touchend",a)}}}shouldScroll(r,n){const{highlightedIndex:o}=this.props.highlightedIndex===void 0?this.getState():this.props,{highlightedIndex:i}=n.highlightedIndex===void 0?r:n;return o&&this.getState().isOpen&&!r.isOpen||o!==i}componentDidUpdate(r,n){process.env.NODE_ENV!=="production"&&(dE(this.state,r,this.props),this.getMenuProps.called&&!this.getMenuProps.suppressRefError&&uM(this._menuNode,this.getMenuProps)),Ed(this.props,"selectedItem")&&this.props.selectedItemChanged(r.selectedItem,this.props.selectedItem)&&this.internalSetState({type:d3,inputValue:this.props.itemToString(this.props.selectedItem)}),!this.avoidScrolling&&this.shouldScroll(n,r)&&this.scrollHighlightedItemIntoView(),this.updateStatus()}componentWillUnmount(){this.cleanup()}render(){const r=cM(this.props.children,ln);this.clearItems(),this.getRootProps.called=!1,this.getRootProps.refKey=void 0,this.getRootProps.suppressRefError=void 0,this.getMenuProps.called=!1,this.getMenuProps.refKey=void 0,this.getMenuProps.suppressRefError=void 0,this.getLabelProps.called=!1,this.getInputProps.called=!1;const n=cM(r(this.getStateAndHelpers()));if(!n)return null;if(this.getRootProps.called||this.props.suppressRefError)return process.env.NODE_ENV!=="production"&&!this.getRootProps.suppressRefError&&!this.props.suppressRefError&&wce(n,this.getRootProps),n;if(KF(n))return R.cloneElement(n,this.getRootProps(XF(n)));if(process.env.NODE_ENV!=="production")throw new Error("downshift: If you return a non-DOM element, you must apply the getRootProps function")}}return e.defaultProps={defaultHighlightedIndex:null,defaultIsOpen:!1,getA11yStatusMessage:YF,itemToString:t=>t==null?"":(process.env.NODE_ENV!=="production"&&mce(t)&&!t.hasOwnProperty("toString")&&console.warn("downshift: An object was passed to the default implementation of `itemToString`. You should probably provide your own `itemToString` implementation. Please refer to the `itemToString` API documentation.","The object that was passed:",t),String(t)),onStateChange:ln,onInputValueChange:ln,onUserAction:ln,onChange:ln,onSelect:ln,onOuterClick:ln,selectedItemChanged:(t,r)=>t!==r,environment:typeof window>"u"?{}:window,stateReducer:(t,r)=>r,suppressRefError:!1,scrollIntoView:UF},e.stateChangeTypes=yce,e})();process.env.NODE_ENV!=="production"&&(xce.propTypes={children:pe.func,defaultHighlightedIndex:pe.number,defaultIsOpen:pe.bool,initialHighlightedIndex:pe.number,initialSelectedItem:pe.any,initialInputValue:pe.string,initialIsOpen:pe.bool,getA11yStatusMessage:pe.func,itemToString:pe.func,onChange:pe.func,onSelect:pe.func,onStateChange:pe.func,onInputValueChange:pe.func,onUserAction:pe.func,onOuterClick:pe.func,selectedItemChanged:pe.func,stateReducer:pe.func,itemCount:pe.number,id:pe.string,environment:pe.shape({addEventListener:pe.func,removeEventListener:pe.func,document:pe.shape({getElementById:pe.func,activeElement:pe.any,body:pe.any})}),suppressRefError:pe.bool,scrollIntoView:pe.func,selectedItem:pe.any,isOpen:pe.bool,inputValue:pe.string,highlightedIndex:pe.number,labelId:pe.string,inputId:pe.string,menuId:pe.string,getItemId:pe.func});function uM(e,t){let{refKey:r}=t;e||console.error(`downshift: The ref prop "${r}" from getMenuProps was not applied correctly on your menu element.`)}function wce(e,t){let{refKey:r}=t;const n=r!=="ref",o=!KF(e);o&&!n&&!oM.isForwardRef(e)?console.error("downshift: You returned a non-DOM element. You must specify a refKey in getRootProps"):!o&&n&&console.error(`downshift: You returned a DOM element. You should not specify a refKey in getRootProps. You specified "${r}"`),!oM.isForwardRef(e)&&!XF(e)[r]&&console.error(`downshift: You must apply the ref prop "${r}" from getRootProps onto your root element.`)}const p3={highlightedIndex:-1,isOpen:!1,selectedItem:null,inputValue:""};function _ce(e,t,r){const{props:n,type:o}=e,i={};Object.keys(t).forEach(a=>{Ece(a,e,t,r),r[a]!==t[a]&&(i[a]=r[a])}),n.onStateChange&&Object.keys(i).length&&n.onStateChange({type:o,...i})}function Ece(e,t,r,n){const{props:o,type:i}=t,a=`on${fE(e)}Change`;o[a]&&n[e]!==void 0&&n[e]!==r[e]&&o[a]({type:i,...n})}function Sce(e,t){return t.changes}function Oce(e){const{selectedItem:t,itemToString:r}=e;return t?`${r(t)} has been selected.`:""}const Cce=uE((e,t)=>{ZF(e(),t)},200),Rce=typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u"?R.useLayoutEffect:R.useEffect;function Nce(e){let{id:t=`downshift-${GF()}`,labelId:r,menuId:n,getItemId:o,toggleButtonId:i,inputId:a}=e;return R.useRef({labelId:r||`${t}-label`,menuId:n||`${t}-menu`,getItemId:o||(c=>`${t}-item-${c}`),toggleButtonId:i||`${t}-toggle-button`,inputId:a||`${t}-input`}).current}function Ice(e,t,r){return e!==void 0?e:r.length===0?-1:r.indexOf(t)}function Pce(e){return e?String(e):""}function fE(e){return`${e.slice(0,1).toUpperCase()}${e.slice(1)}`}function h3(e){const t=R.useRef(e);return t.current=e,t}function Tce(e,t,r){const n=R.useRef(),o=R.useRef(),i=R.useCallback((f,h)=>{o.current=h,f=_d(f,h.props);const v=e(f,h);return h.props.stateReducer(f,{...h,changes:v})},[e]),[a,s]=R.useReducer(i,t),c=h3(r),u=R.useCallback(f=>s({props:c.current,...f}),[c]),d=o.current;return R.useEffect(()=>{d&&n.current&&n.current!==a&&_ce(d,_d(n.current,d.props),a),n.current=a},[a,r,d]),[a,u]}const el={itemToString:Pce,stateReducer:Sce,getA11ySelectionMessage:Oce,scrollIntoView:UF,circularNavigation:!1,environment:typeof window>"u"?{}:window};function Un(e,t,r){r===void 0&&(r=p3);const n=e[`default${fE(t)}`];return n!==void 0?n:r[t]}function xu(e,t,r){r===void 0&&(r=p3);const n=e[t];if(n!==void 0)return n;const o=e[`initial${fE(t)}`];return o!==void 0?o:Un(e,t,r)}function Ace(e){const t=xu(e,"selectedItem"),r=xu(e,"isOpen"),n=xu(e,"highlightedIndex"),o=xu(e,"inputValue");return{highlightedIndex:n<0&&t&&r?e.items.indexOf(t):n,isOpen:r,selectedItem:t,inputValue:o}}function Od(e,t,r,n){const{items:o,initialHighlightedIndex:i,defaultHighlightedIndex:a}=e,{selectedItem:s,highlightedIndex:c}=t;return o.length===0?-1:i!==void 0&&c===i?i:a!==void 0?a:s?r===0?o.indexOf(s):ya(r,o.indexOf(s),o.length,n,!1):r===0?-1:r<0?o.length-1:0}function kce(e,t,r,n){const o=R.useRef({isMouseDown:!1,isTouchMove:!1});return R.useEffect(()=>{const i=()=>{o.current.isMouseDown=!0},a=d=>{o.current.isMouseDown=!1,e&&!Sd(d.target,t.map(f=>f.current),r)&&n()},s=()=>{o.current.isTouchMove=!1},c=()=>{o.current.isTouchMove=!0},u=d=>{e&&!o.current.isTouchMove&&!Sd(d.target,t.map(f=>f.current),r,!1)&&n()};return r.addEventListener("mousedown",i),r.addEventListener("mouseup",a),r.addEventListener("touchstart",s),r.addEventListener("touchmove",c),r.addEventListener("touchend",u),function(){r.removeEventListener("mousedown",i),r.removeEventListener("mouseup",a),r.removeEventListener("touchstart",s),r.removeEventListener("touchmove",c),r.removeEventListener("touchend",u)}},[e,r]),o}let v3=()=>ln;process.env.NODE_ENV!=="production"&&(v3=function(){const e=R.useRef(!0);for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];const o=R.useRef(r.reduce((a,s)=>(a[s]={},a),{}));return R.useEffect(()=>{Object.keys(o.current).forEach(a=>{const s=o.current[a];if(e.current&&!Object.keys(s).length){console.error(`downshift: You forgot to call the ${a} getter function on your component / element.`);return}const{suppressRefError:c,refKey:u,elementRef:d}=s;(!d||!d.current)&&!c&&console.error(`downshift: The ref prop "${u}" from ${a} was not applied correctly on your element.`)}),e.current=!1}),R.useCallback((a,s,c,u)=>{o.current[a]={suppressRefError:s,refKey:c,elementRef:u}},[])});function dM(e,t,r){let{isInitialMount:n,highlightedIndex:o,items:i,environment:a,...s}=r;R.useEffect(()=>{n||Cce(()=>e({highlightedIndex:o,highlightedItem:i[o],resultCount:i.length,...s}),a.document)},t)}function Dce(e){let{highlightedIndex:t,isOpen:r,itemRefs:n,getItemNodeFromIndex:o,menuElement:i,scrollIntoView:a}=e;const s=R.useRef(!0);return Rce(()=>{t<0||!r||!Object.keys(n.current).length||(s.current===!1?s.current=!0:a(o(t),i))},[t]),s}let g3=ln;process.env.NODE_ENV!=="production"&&(g3=e=>{let{isInitialMount:t,props:r,state:n}=e;const o=R.useRef(r);R.useEffect(()=>{t||(dE(n,o.current,r),o.current=r)},[n,r,t])});function Mce(e,t,r){const{type:n,props:o}=t;let i;switch(n){case r.ItemMouseMove:i={highlightedIndex:t.disabled?-1:t.index};break;case r.MenuMouseLeave:i={highlightedIndex:-1};break;case r.ToggleButtonClick:case r.FunctionToggleMenu:i={isOpen:!e.isOpen,highlightedIndex:e.isOpen?-1:Od(o,e,0)};break;case r.FunctionOpenMenu:i={isOpen:!0,highlightedIndex:Od(o,e,0)};break;case r.FunctionCloseMenu:i={isOpen:!1};break;case r.FunctionSetHighlightedIndex:i={highlightedIndex:t.highlightedIndex};break;case r.FunctionSetInputValue:i={inputValue:t.inputValue};break;case r.FunctionReset:i={highlightedIndex:Un(o,"highlightedIndex"),isOpen:Un(o,"isOpen"),selectedItem:Un(o,"selectedItem"),inputValue:Un(o,"inputValue")};break;default:throw new Error("Reducer called without proper action type.")}return{...e,...i}}pe.array.isRequired,pe.func,pe.func,pe.func,pe.bool,pe.number,pe.number,pe.number,pe.bool,pe.bool,pe.bool,pe.any,pe.any,pe.any,pe.string,pe.string,pe.string,pe.func,pe.string,pe.func,pe.func,pe.func,pe.func,pe.func,pe.shape({addEventListener:pe.func,removeEventListener:pe.func,document:pe.shape({getElementById:pe.func,activeElement:pe.any,body:pe.any})});function jce(e){var t=e.isOpen,r=e.resultCount,n=e.previousResultCount;return t?r?r!==n?"".concat(r," result").concat(r===1?" is":"s are"," available, use up and down arrow keys to navigate. Press Enter or Space Bar keys to select."):"":"No results are available.":""}vd(vd({},el),{getA11yStatusMessage:jce});process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;const pE=process.env.NODE_ENV!=="production"?"__input_keydown_arrow_down__":0,hE=process.env.NODE_ENV!=="production"?"__input_keydown_arrow_up__":1,vE=process.env.NODE_ENV!=="production"?"__input_keydown_escape__":2,gE=process.env.NODE_ENV!=="production"?"__input_keydown_home__":3,mE=process.env.NODE_ENV!=="production"?"__input_keydown_end__":4,bE=process.env.NODE_ENV!=="production"?"__input_keydown_enter__":5,yE=process.env.NODE_ENV!=="production"?"__input_change__":6,Cd=process.env.NODE_ENV!=="production"?"__input_blur__":7,m3=process.env.NODE_ENV!=="production"?"__menu_mouse_leave__":8,b3=process.env.NODE_ENV!=="production"?"__item_mouse_move__":9,xE=process.env.NODE_ENV!=="production"?"__item_click__":10,y3=process.env.NODE_ENV!=="production"?"__togglebutton_click__":11,x3=process.env.NODE_ENV!=="production"?"__function_toggle_menu__":12,w3=process.env.NODE_ENV!=="production"?"__function_open_menu__":13,_3=process.env.NODE_ENV!=="production"?"__function_close_menu__":14,E3=process.env.NODE_ENV!=="production"?"__function_set_highlighted_index__":15,wE=process.env.NODE_ENV!=="production"?"__function_select_item__":16,S3=process.env.NODE_ENV!=="production"?"__function_set_input_value__":17,O3=process.env.NODE_ENV!=="production"?"__function_reset__":18,_E=process.env.NODE_ENV!=="production"?"__controlled_prop_updated_selected_item__":19;var C3=Object.freeze({__proto__:null,InputKeyDownArrowDown:pE,InputKeyDownArrowUp:hE,InputKeyDownEscape:vE,InputKeyDownHome:gE,InputKeyDownEnd:mE,InputKeyDownEnter:bE,InputChange:yE,InputBlur:Cd,MenuMouseLeave:m3,ItemMouseMove:b3,ItemClick:xE,ToggleButtonClick:y3,FunctionToggleMenu:x3,FunctionOpenMenu:w3,FunctionCloseMenu:_3,FunctionSetHighlightedIndex:E3,FunctionSelectItem:wE,FunctionSetInputValue:S3,FunctionReset:O3,ControlledPropUpdatedSelectedItem:_E});function Lce(e){const t=Ace(e),{selectedItem:r}=t;let{inputValue:n}=t;return n===""&&r&&e.defaultInputValue===void 0&&e.initialInputValue===void 0&&e.inputValue===void 0&&(n=e.itemToString(r)),{...t,inputValue:n}}const qce={items:pe.array.isRequired,itemToString:pe.func,getA11yStatusMessage:pe.func,getA11ySelectionMessage:pe.func,circularNavigation:pe.bool,highlightedIndex:pe.number,defaultHighlightedIndex:pe.number,initialHighlightedIndex:pe.number,isOpen:pe.bool,defaultIsOpen:pe.bool,initialIsOpen:pe.bool,selectedItem:pe.any,initialSelectedItem:pe.any,defaultSelectedItem:pe.any,inputValue:pe.string,defaultInputValue:pe.string,initialInputValue:pe.string,id:pe.string,labelId:pe.string,menuId:pe.string,getItemId:pe.func,inputId:pe.string,toggleButtonId:pe.string,stateReducer:pe.func,onSelectedItemChange:pe.func,onHighlightedIndexChange:pe.func,onStateChange:pe.func,onIsOpenChange:pe.func,onInputValueChange:pe.func,environment:pe.shape({addEventListener:pe.func,removeEventListener:pe.func,document:pe.shape({getElementById:pe.func,activeElement:pe.any,body:pe.any})})};function zce(e,t,r){const n=R.useRef(),[o,i]=Tce(e,t,r);return R.useEffect(()=>{Ed(r,"selectedItem")&&(n.current!==r.selectedItem&&i({type:_E,inputValue:r.itemToString(r.selectedItem)}),n.current=o.selectedItem===n.current?r.selectedItem:o.selectedItem)}),[_d(o,r),i]}let R3=ln;process.env.NODE_ENV!=="production"&&(R3=(e,t)=>{pe.checkPropTypes(qce,e,"prop",t.name)});const Bce={...el,getA11yStatusMessage:YF,circularNavigation:!0};function Fce(e,t){const{type:r,props:n,shiftKey:o}=t;let i;switch(r){case xE:i={isOpen:Un(n,"isOpen"),highlightedIndex:Un(n,"highlightedIndex"),selectedItem:n.items[t.index],inputValue:n.itemToString(n.items[t.index])};break;case pE:e.isOpen?i={highlightedIndex:ya(o?5:1,e.highlightedIndex,n.items.length,t.getItemNodeFromIndex,n.circularNavigation)}:i={highlightedIndex:Od(n,e,1,t.getItemNodeFromIndex),isOpen:n.items.length>=0};break;case hE:e.isOpen?i={highlightedIndex:ya(o?-5:-1,e.highlightedIndex,n.items.length,t.getItemNodeFromIndex,n.circularNavigation)}:i={highlightedIndex:Od(n,e,-1,t.getItemNodeFromIndex),isOpen:n.items.length>=0};break;case bE:i={...e.isOpen&&e.highlightedIndex>=0&&{selectedItem:n.items[e.highlightedIndex],isOpen:Un(n,"isOpen"),highlightedIndex:Un(n,"highlightedIndex"),inputValue:n.itemToString(n.items[e.highlightedIndex])}};break;case vE:i={isOpen:!1,highlightedIndex:-1,...!e.isOpen&&{selectedItem:null,inputValue:""}};break;case gE:i={highlightedIndex:Ri(1,0,n.items.length,t.getItemNodeFromIndex,!1)};break;case mE:i={highlightedIndex:Ri(-1,n.items.length-1,n.items.length,t.getItemNodeFromIndex,!1)};break;case Cd:i={isOpen:!1,highlightedIndex:-1,...e.highlightedIndex>=0&&t.selectItem&&{selectedItem:n.items[e.highlightedIndex],inputValue:n.itemToString(n.items[e.highlightedIndex])}};break;case yE:i={isOpen:!0,highlightedIndex:Un(n,"highlightedIndex"),inputValue:t.inputValue};break;case wE:i={selectedItem:t.selectedItem,inputValue:n.itemToString(t.selectedItem)};break;case _E:i={inputValue:t.inputValue};break;default:return Mce(e,t,C3)}return{...e,...i}}fa.stateChangeTypes=C3;function fa(e){e===void 0&&(e={}),R3(e,fa);const t={...Bce,...e},{initialIsOpen:r,defaultIsOpen:n,items:o,scrollIntoView:i,environment:a,getA11yStatusMessage:s,getA11ySelectionMessage:c,itemToString:u}=t,d=Lce(t),[f,h]=zce(Fce,d,t),{isOpen:v,highlightedIndex:b,selectedItem:g,inputValue:m}=f,x=R.useRef(null),w=R.useRef({}),E=R.useRef(null),S=R.useRef(null),_=R.useRef(null),C=R.useRef(!0),N=Nce(t),P=R.useRef(),A=h3({state:f,props:t}),j=R.useCallback(K=>w.current[N.getItemId(K)],[N]);dM(s,[v,b,m,o],{isInitialMount:C.current,previousResultCount:P.current,items:o,environment:a,itemToString:u,...f}),dM(c,[g],{isInitialMount:C.current,previousResultCount:P.current,items:o,environment:a,itemToString:u,...f});const M=Dce({menuElement:x.current,highlightedIndex:b,isOpen:v,itemRefs:w,scrollIntoView:i,getItemNodeFromIndex:j});g3({isInitialMount:C.current,props:t,state:f}),R.useEffect(()=>{(r||n||v)&&E.current&&E.current.focus()},[]),R.useEffect(()=>{C.current||(P.current=o.length)});const L=kce(v,[_,x,S],a,()=>{h({type:Cd,selectItem:!1})}),D=v3("getInputProps","getComboboxProps","getMenuProps");R.useEffect(()=>{C.current=!1},[]),R.useEffect(()=>{v||(w.current={})},[v]);const T=R.useMemo(()=>({ArrowDown(K){K.preventDefault(),h({type:pE,shiftKey:K.shiftKey,getItemNodeFromIndex:j})},ArrowUp(K){K.preventDefault(),h({type:hE,shiftKey:K.shiftKey,getItemNodeFromIndex:j})},Home(K){A.current.state.isOpen&&(K.preventDefault(),h({type:gE,getItemNodeFromIndex:j}))},End(K){A.current.state.isOpen&&(K.preventDefault(),h({type:mE,getItemNodeFromIndex:j}))},Escape(K){const Q=A.current.state;(Q.isOpen||Q.inputValue||Q.selectedItem||Q.highlightedIndex>-1)&&(K.preventDefault(),h({type:vE}))},Enter(K){const Q=A.current.state;!Q.isOpen||Q.highlightedIndex<0||K.which===229||(K.preventDefault(),h({type:bE,getItemNodeFromIndex:j}))}}),[h,A,j]),W=R.useCallback(K=>({id:N.labelId,htmlFor:N.inputId,...K}),[N]),q=R.useCallback(function(K,Q){let{onMouseLeave:ne,refKey:se="ref",ref:te,...be}=K===void 0?{}:K,{suppressRefError:de=!1}=Q===void 0?{}:Q;return D("getMenuProps",de,se,x),{[se]:hi(te,Ee=>{x.current=Ee}),id:N.menuId,role:"listbox","aria-labelledby":N.labelId,onMouseLeave:Zt(ne,()=>{h({type:m3})}),...be}},[h,D,N]),G=R.useCallback(function(K){let{item:Q,index:ne,refKey:se="ref",ref:te,onMouseMove:be,onMouseDown:de,onClick:Ee,onPress:fe,disabled:le,...Ce}=K===void 0?{}:K;const{props:Te,state:Fe}=A.current,Le=Ice(ne,Q,Te.items);if(Le<0)throw new Error("Pass either item or item index in getItemProps!");const Ze="onClick",We=Ee,St=()=>{ne!==Fe.highlightedIndex&&(M.current=!1,h({type:b3,index:ne,disabled:le}))},tt=()=>{h({type:xE,index:ne})},wt=Je=>Je.preventDefault();return{[se]:hi(te,Je=>{Je&&(w.current[N.getItemId(Le)]=Je)}),disabled:le,role:"option","aria-selected":`${Le===Fe.highlightedIndex}`,id:N.getItemId(Le),...!le&&{[Ze]:Zt(We,tt)},onMouseMove:Zt(be,St),onMouseDown:Zt(de,wt),...Ce}},[h,A,M,N]),F=R.useCallback(function(K){let{onClick:Q,onPress:ne,refKey:se="ref",ref:te,...be}=K===void 0?{}:K;const de=()=>{h({type:y3}),!A.current.state.isOpen&&E.current&&E.current.focus()};return{[se]:hi(te,Ee=>{S.current=Ee}),id:N.toggleButtonId,tabIndex:-1,...!be.disabled&&{onClick:Zt(Q,de)},...be}},[h,A,N]),J=R.useCallback(function(K,Q){let{onKeyDown:ne,onChange:se,onInput:te,onBlur:be,onChangeText:de,refKey:Ee="ref",ref:fe,...le}=K===void 0?{}:K,{suppressRefError:Ce=!1}=Q===void 0?{}:Q;D("getInputProps",Ce,Ee,E);const Te=A.current.state,Fe=tt=>{const wt=F_(tt);wt&&T[wt]&&T[wt](tt)},Le=tt=>{h({type:yE,inputValue:tt.target.value})},Ze=()=>{Te.isOpen&&!L.current.isMouseDown&&h({type:Cd,selectItem:!0})},We="onChange";let St={};return le.disabled||(St={[We]:Zt(se,te,Le),onKeyDown:Zt(ne,Fe),onBlur:Zt(be,Ze)}),{[Ee]:hi(fe,tt=>{E.current=tt}),id:N.inputId,"aria-autocomplete":"list","aria-controls":N.menuId,...Te.isOpen&&Te.highlightedIndex>-1&&{"aria-activedescendant":N.getItemId(Te.highlightedIndex)},"aria-labelledby":N.labelId,autoComplete:"off",value:Te.inputValue,...St,...le}},[h,T,A,L,D,N]),z=R.useCallback(function(K,Q){let{refKey:ne="ref",ref:se,...te}=K===void 0?{}:K,{suppressRefError:be=!1}=Q===void 0?{}:Q;return D("getComboboxProps",be,ne,_),{[ne]:hi(se,de=>{_.current=de}),role:"combobox","aria-haspopup":"listbox","aria-owns":N.menuId,"aria-expanded":A.current.state.isOpen,...te}},[A,D,N]),U=R.useCallback(()=>{h({type:x3})},[h]),oe=R.useCallback(()=>{h({type:_3})},[h]),re=R.useCallback(()=>{h({type:w3})},[h]),$=R.useCallback(K=>{h({type:E3,highlightedIndex:K})},[h]),Y=R.useCallback(K=>{h({type:wE,selectedItem:K})},[h]),X=R.useCallback(K=>{h({type:S3,inputValue:K})},[h]),H=R.useCallback(()=>{h({type:O3})},[h]);return{getItemProps:G,getLabelProps:W,getMenuProps:q,getInputProps:J,getComboboxProps:z,getToggleButtonProps:F,toggleMenu:U,openMenu:re,closeMenu:oe,setHighlightedIndex:$,setInputValue:X,selectItem:Y,reset:H,highlightedIndex:b,isOpen:v,selectedItem:g,inputValue:m}}pe.array,pe.array,pe.array,pe.func,pe.func,pe.func,pe.number,pe.number,pe.number,pe.func,pe.func,pe.string,pe.string,pe.shape({addEventListener:pe.func,removeEventListener:pe.func,document:pe.shape({getElementById:pe.func,activeElement:pe.any,body:pe.any})});el.itemToString,el.stateReducer,el.environment;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;var fM={},js,pM;function Ft(){if(pM)return js;pM=1;var e=function(t){return t&&t.Math===Math&&t};return js=e(typeof globalThis=="object"&&globalThis)||e(typeof window=="object"&&window)||e(typeof self=="object"&&self)||e(typeof Tt=="object"&&Tt)||e(typeof js=="object"&&js)||(function(){return this})()||Function("return this")(),js}var O0={},C0,hM;function xt(){return hM||(hM=1,C0=function(e){try{return!!e()}catch{return!0}}),C0}var R0,vM;function jn(){if(vM)return R0;vM=1;var e=xt();return R0=!e(function(){return Object.defineProperty({},1,{get:function(){return 7}})[1]!==7}),R0}var N0,gM;function Sf(){if(gM)return N0;gM=1;var e=xt();return N0=!e(function(){var t=(function(){}).bind();return typeof t!="function"||t.hasOwnProperty("prototype")}),N0}var I0,mM;function Mr(){if(mM)return I0;mM=1;var e=Sf(),t=Function.prototype.call;return I0=e?t.bind(t):function(){return t.apply(t,arguments)},I0}var P0={},bM;function N3(){if(bM)return P0;bM=1;var e={}.propertyIsEnumerable,t=Object.getOwnPropertyDescriptor,r=t&&!e.call({1:2},1);return P0.f=r?function(o){var i=t(this,o);return!!i&&i.enumerable}:e,P0}var T0,yM;function EE(){return yM||(yM=1,T0=function(e,t){return{enumerable:!(e&1),configurable:!(e&2),writable:!(e&4),value:t}}),T0}var A0,xM;function gt(){if(xM)return A0;xM=1;var e=Sf(),t=Function.prototype,r=t.call,n=e&&t.bind.bind(r,r);return A0=e?n:function(o){return function(){return r.apply(o,arguments)}},A0}var k0,wM;function Qo(){if(wM)return k0;wM=1;var e=gt(),t=e({}.toString),r=e("".slice);return k0=function(n){return r(t(n),8,-1)},k0}var D0,_M;function Of(){if(_M)return D0;_M=1;var e=gt(),t=xt(),r=Qo(),n=Object,o=e("".split);return D0=t(function(){return!n("z").propertyIsEnumerable(0)})?function(i){return r(i)==="String"?o(i,""):n(i)}:n,D0}var M0,EM;function Ml(){return EM||(EM=1,M0=function(e){return e==null}),M0}var j0,SM;function ki(){if(SM)return j0;SM=1;var e=Ml(),t=TypeError;return j0=function(r){if(e(r))throw new t("Can't call method on "+r);return r},j0}var L0,OM;function Ua(){if(OM)return L0;OM=1;var e=Of(),t=ki();return L0=function(r){return e(t(r))},L0}var q0,CM;function Yt(){if(CM)return q0;CM=1;var e=typeof document=="object"&&document.all;return q0=typeof e>"u"&&e!==void 0?function(t){return typeof t=="function"||t===e}:function(t){return typeof t=="function"},q0}var z0,RM;function ar(){if(RM)return z0;RM=1;var e=Yt();return z0=function(t){return typeof t=="object"?t!==null:e(t)},z0}var B0,NM;function Cf(){if(NM)return B0;NM=1;var e=Ft(),t=Yt(),r=function(n){return t(n)?n:void 0};return B0=function(n,o){return arguments.length<2?r(e[n]):e[n]&&e[n][o]},B0}var F0,IM;function Rf(){if(IM)return F0;IM=1;var e=gt();return F0=e({}.isPrototypeOf),F0}var $0,PM;function I3(){if(PM)return $0;PM=1;var e=Ft(),t=e.navigator,r=t&&t.userAgent;return $0=r?String(r):"",$0}var V0,TM;function SE(){if(TM)return V0;TM=1;var e=Ft(),t=I3(),r=e.process,n=e.Deno,o=r&&r.versions||n&&n.version,i=o&&o.v8,a,s;return i&&(a=i.split("."),s=a[0]>0&&a[0]<4?1:+(a[0]+a[1])),!s&&t&&(a=t.match(/Edge\/(\d+)/),(!a||a[1]>=74)&&(a=t.match(/Chrome\/(\d+)/),a&&(s=+a[1]))),V0=s,V0}var H0,AM;function P3(){if(AM)return H0;AM=1;var e=SE(),t=xt(),r=Ft(),n=r.String;return H0=!!Object.getOwnPropertySymbols&&!t(function(){var o=Symbol("symbol detection");return!n(o)||!(Object(o)instanceof Symbol)||!Symbol.sham&&e&&e<41}),H0}var W0,kM;function T3(){if(kM)return W0;kM=1;var e=P3();return W0=e&&!Symbol.sham&&typeof Symbol.iterator=="symbol",W0}var U0,DM;function A3(){if(DM)return U0;DM=1;var e=Cf(),t=Yt(),r=Rf(),n=T3(),o=Object;return U0=n?function(i){return typeof i=="symbol"}:function(i){var a=e("Symbol");return t(a)&&r(a.prototype,o(i))},U0}var G0,MM;function OE(){if(MM)return G0;MM=1;var e=String;return G0=function(t){try{return e(t)}catch{return"Object"}},G0}var Y0,jM;function jl(){if(jM)return Y0;jM=1;var e=Yt(),t=OE(),r=TypeError;return Y0=function(n){if(e(n))return n;throw new r(t(n)+" is not a function")},Y0}var K0,LM;function Ll(){if(LM)return K0;LM=1;var e=jl(),t=Ml();return K0=function(r,n){var o=r[n];return t(o)?void 0:e(o)},K0}var X0,qM;function $ce(){if(qM)return X0;qM=1;var e=Mr(),t=Yt(),r=ar(),n=TypeError;return X0=function(o,i){var a,s;if(i==="string"&&t(a=o.toString)&&!r(s=e(a,o))||t(a=o.valueOf)&&!r(s=e(a,o))||i!=="string"&&t(a=o.toString)&&!r(s=e(a,o)))return s;throw new n("Can't convert object to primitive value")},X0}var Z0={exports:{}},J0,zM;function Nf(){return zM||(zM=1,J0=!1),J0}var Q0,BM;function CE(){if(BM)return Q0;BM=1;var e=Ft(),t=Object.defineProperty;return Q0=function(r,n){try{t(e,r,{value:n,configurable:!0,writable:!0})}catch{e[r]=n}return n},Q0}var FM;function RE(){if(FM)return Z0.exports;FM=1;var e=Nf(),t=Ft(),r=CE(),n="__core-js_shared__",o=Z0.exports=t[n]||r(n,{});return(o.versions||(o.versions=[])).push({version:"3.45.1",mode:e?"pure":"global",copyright:"© 2014-2025 Denis Pushkarev (zloirock.ru)",license:"https://github.com/zloirock/core-js/blob/v3.45.1/LICENSE",source:"https://github.com/zloirock/core-js"}),Z0.exports}var ex,$M;function NE(){if($M)return ex;$M=1;var e=RE();return ex=function(t,r){return e[t]||(e[t]=r||{})},ex}var tx,VM;function Ga(){if(VM)return tx;VM=1;var e=ki(),t=Object;return tx=function(r){return t(e(r))},tx}var rx,HM;function mn(){if(HM)return rx;HM=1;var e=gt(),t=Ga(),r=e({}.hasOwnProperty);return rx=Object.hasOwn||function(o,i){return r(t(o),i)},rx}var nx,WM;function IE(){if(WM)return nx;WM=1;var e=gt(),t=0,r=Math.random(),n=e(1.1.toString);return nx=function(o){return"Symbol("+(o===void 0?"":o)+")_"+n(++t+r,36)},nx}var ox,UM;function Er(){if(UM)return ox;UM=1;var e=Ft(),t=NE(),r=mn(),n=IE(),o=P3(),i=T3(),a=e.Symbol,s=t("wks"),c=i?a.for||a:a&&a.withoutSetter||n;return ox=function(u){return r(s,u)||(s[u]=o&&r(a,u)?a[u]:c("Symbol."+u)),s[u]},ox}var ix,GM;function Vce(){if(GM)return ix;GM=1;var e=Mr(),t=ar(),r=A3(),n=Ll(),o=$ce(),i=Er(),a=TypeError,s=i("toPrimitive");return ix=function(c,u){if(!t(c)||r(c))return c;var d=n(c,s),f;if(d){if(u===void 0&&(u="default"),f=e(d,c,u),!t(f)||r(f))return f;throw new a("Can't convert object to primitive value")}return u===void 0&&(u="number"),o(c,u)},ix}var ax,YM;function k3(){if(YM)return ax;YM=1;var e=Vce(),t=A3();return ax=function(r){var n=e(r,"string");return t(n)?n:n+""},ax}var sx,KM;function PE(){if(KM)return sx;KM=1;var e=Ft(),t=ar(),r=e.document,n=t(r)&&t(r.createElement);return sx=function(o){return n?r.createElement(o):{}},sx}var lx,XM;function D3(){if(XM)return lx;XM=1;var e=jn(),t=xt(),r=PE();return lx=!e&&!t(function(){return Object.defineProperty(r("div"),"a",{get:function(){return 7}}).a!==7}),lx}var ZM;function M3(){if(ZM)return O0;ZM=1;var e=jn(),t=Mr(),r=N3(),n=EE(),o=Ua(),i=k3(),a=mn(),s=D3(),c=Object.getOwnPropertyDescriptor;return O0.f=e?c:function(d,f){if(d=o(d),f=i(f),s)try{return c(d,f)}catch{}if(a(d,f))return n(!t(r.f,d,f),d[f])},O0}var cx={},ux,JM;function j3(){if(JM)return ux;JM=1;var e=jn(),t=xt();return ux=e&&t(function(){return Object.defineProperty(function(){},"prototype",{value:42,writable:!1}).prototype!==42}),ux}var dx,QM;function bn(){if(QM)return dx;QM=1;var e=ar(),t=String,r=TypeError;return dx=function(n){if(e(n))return n;throw new r(t(n)+" is not an object")},dx}var ej;function Oo(){if(ej)return cx;ej=1;var e=jn(),t=D3(),r=j3(),n=bn(),o=k3(),i=TypeError,a=Object.defineProperty,s=Object.getOwnPropertyDescriptor,c="enumerable",u="configurable",d="writable";return cx.f=e?r?function(h,v,b){if(n(h),v=o(v),n(b),typeof h=="function"&&v==="prototype"&&"value"in b&&d in b&&!b[d]){var g=s(h,v);g&&g[d]&&(h[v]=b.value,b={configurable:u in b?b[u]:g[u],enumerable:c in b?b[c]:g[c],writable:!1})}return a(h,v,b)}:a:function(h,v,b){if(n(h),v=o(v),n(b),t)try{return a(h,v,b)}catch{}if("get"in b||"set"in b)throw new i("Accessors not supported");return"value"in b&&(h[v]=b.value),h},cx}var fx,tj;function ql(){if(tj)return fx;tj=1;var e=jn(),t=Oo(),r=EE();return fx=e?function(n,o,i){return t.f(n,o,r(1,i))}:function(n,o,i){return n[o]=i,n},fx}var px={exports:{}},hx,rj;function TE(){if(rj)return hx;rj=1;var e=jn(),t=mn(),r=Function.prototype,n=e&&Object.getOwnPropertyDescriptor,o=t(r,"name"),i=o&&(function(){}).name==="something",a=o&&(!e||e&&n(r,"name").configurable);return hx={EXISTS:o,PROPER:i,CONFIGURABLE:a},hx}var vx,nj;function L3(){if(nj)return vx;nj=1;var e=gt(),t=Yt(),r=RE(),n=e(Function.toString);return t(r.inspectSource)||(r.inspectSource=function(o){return n(o)}),vx=r.inspectSource,vx}var gx,oj;function q3(){if(oj)return gx;oj=1;var e=Ft(),t=Yt(),r=e.WeakMap;return gx=t(r)&&/native code/.test(String(r)),gx}var mx,ij;function AE(){if(ij)return mx;ij=1;var e=NE(),t=IE(),r=e("keys");return mx=function(n){return r[n]||(r[n]=t(n))},mx}var bx,aj;function If(){return aj||(aj=1,bx={}),bx}var yx,sj;function Ya(){if(sj)return yx;sj=1;var e=q3(),t=Ft(),r=ar(),n=ql(),o=mn(),i=RE(),a=AE(),s=If(),c="Object already initialized",u=t.TypeError,d=t.WeakMap,f,h,v,b=function(w){return v(w)?h(w):f(w,{})},g=function(w){return function(E){var S;if(!r(E)||(S=h(E)).type!==w)throw new u("Incompatible receiver, "+w+" required");return S}};if(e||i.state){var m=i.state||(i.state=new d);m.get=m.get,m.has=m.has,m.set=m.set,f=function(w,E){if(m.has(w))throw new u(c);return E.facade=w,m.set(w,E),E},h=function(w){return m.get(w)||{}},v=function(w){return m.has(w)}}else{var x=a("state");s[x]=!0,f=function(w,E){if(o(w,x))throw new u(c);return E.facade=w,n(w,x,E),E},h=function(w){return o(w,x)?w[x]:{}},v=function(w){return o(w,x)}}return yx={set:f,get:h,has:v,enforce:b,getterFor:g},yx}var lj;function z3(){if(lj)return px.exports;lj=1;var e=gt(),t=xt(),r=Yt(),n=mn(),o=jn(),i=TE().CONFIGURABLE,a=L3(),s=Ya(),c=s.enforce,u=s.get,d=String,f=Object.defineProperty,h=e("".slice),v=e("".replace),b=e([].join),g=o&&!t(function(){return f(function(){},"length",{value:8}).length!==8}),m=String(String).split("String"),x=px.exports=function(w,E,S){h(d(E),0,7)==="Symbol("&&(E="["+v(d(E),/^Symbol\(([^)]*)\).*$/,"$1")+"]"),S&&S.getter&&(E="get "+E),S&&S.setter&&(E="set "+E),(!n(w,"name")||i&&w.name!==E)&&(o?f(w,"name",{value:E,configurable:!0}):w.name=E),g&&S&&n(S,"arity")&&w.length!==S.arity&&f(w,"length",{value:S.arity});try{S&&n(S,"constructor")&&S.constructor?o&&f(w,"prototype",{writable:!1}):w.prototype&&(w.prototype=void 0)}catch{}var _=c(w);return n(_,"source")||(_.source=b(m,typeof E=="string"?E:"")),w};return Function.prototype.toString=x(function(){return r(this)&&u(this).source||a(this)},"toString"),px.exports}var xx,cj;function Di(){if(cj)return xx;cj=1;var e=Yt(),t=Oo(),r=z3(),n=CE();return xx=function(o,i,a,s){s||(s={});var c=s.enumerable,u=s.name!==void 0?s.name:i;if(e(a)&&r(a,u,s),s.global)c?o[i]=a:n(i,a);else{try{s.unsafe?o[i]&&(c=!0):delete o[i]}catch{}c?o[i]=a:t.f(o,i,{value:a,enumerable:!1,configurable:!s.nonConfigurable,writable:!s.nonWritable})}return o},xx}var wx={},_x,uj;function Hce(){if(uj)return _x;uj=1;var e=Math.ceil,t=Math.floor;return _x=Math.trunc||function(n){var o=+n;return(o>0?t:e)(o)},_x}var Ex,dj;function Pf(){if(dj)return Ex;dj=1;var e=Hce();return Ex=function(t){var r=+t;return r!==r||r===0?0:e(r)},Ex}var Sx,fj;function Wce(){if(fj)return Sx;fj=1;var e=Pf(),t=Math.max,r=Math.min;return Sx=function(n,o){var i=e(n);return i<0?t(i+o,0):r(i,o)},Sx}var Ox,pj;function kE(){if(pj)return Ox;pj=1;var e=Pf(),t=Math.min;return Ox=function(r){var n=e(r);return n>0?t(n,9007199254740991):0},Ox}var Cx,hj;function Tf(){if(hj)return Cx;hj=1;var e=kE();return Cx=function(t){return e(t.length)},Cx}var Rx,vj;function Uce(){if(vj)return Rx;vj=1;var e=Ua(),t=Wce(),r=Tf(),n=function(o){return function(i,a,s){var c=e(i),u=r(c);if(u===0)return!o&&-1;var d=t(s,u),f;if(o&&a!==a){for(;u>d;)if(f=c[d++],f!==f)return!0}else for(;u>d;d++)if((o||d in c)&&c[d]===a)return o||d||0;return!o&&-1}};return Rx={includes:n(!0),indexOf:n(!1)},Rx}var Nx,gj;function B3(){if(gj)return Nx;gj=1;var e=gt(),t=mn(),r=Ua(),n=Uce().indexOf,o=If(),i=e([].push);return Nx=function(a,s){var c=r(a),u=0,d=[],f;for(f in c)!t(o,f)&&t(c,f)&&i(d,f);for(;s.length>u;)t(c,f=s[u++])&&(~n(d,f)||i(d,f));return d},Nx}var Ix,mj;function DE(){return mj||(mj=1,Ix=["constructor","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","toLocaleString","toString","valueOf"]),Ix}var bj;function ME(){if(bj)return wx;bj=1;var e=B3(),t=DE(),r=t.concat("length","prototype");return wx.f=Object.getOwnPropertyNames||function(o){return e(o,r)},wx}var Px={},yj;function F3(){return yj||(yj=1,Px.f=Object.getOwnPropertySymbols),Px}var Tx,xj;function Gce(){if(xj)return Tx;xj=1;var e=Cf(),t=gt(),r=ME(),n=F3(),o=bn(),i=t([].concat);return Tx=e("Reflect","ownKeys")||function(s){var c=r.f(o(s)),u=n.f;return u?i(c,u(s)):c},Tx}var Ax,wj;function Yce(){if(wj)return Ax;wj=1;var e=mn(),t=Gce(),r=M3(),n=Oo();return Ax=function(o,i,a){for(var s=t(i),c=n.f,u=r.f,d=0;d<s.length;d++){var f=s[d];!e(o,f)&&!(a&&e(a,f))&&c(o,f,u(i,f))}},Ax}var kx,_j;function $3(){if(_j)return kx;_j=1;var e=xt(),t=Yt(),r=/#|\.prototype\./,n=function(c,u){var d=i[o(c)];return d===s?!0:d===a?!1:t(u)?e(u):!!u},o=n.normalize=function(c){return String(c).replace(r,".").toLowerCase()},i=n.data={},a=n.NATIVE="N",s=n.POLYFILL="P";return kx=n,kx}var Dx,Ej;function ei(){if(Ej)return Dx;Ej=1;var e=Ft(),t=M3().f,r=ql(),n=Di(),o=CE(),i=Yce(),a=$3();return Dx=function(s,c){var u=s.target,d=s.global,f=s.stat,h,v,b,g,m,x;if(d?v=e:f?v=e[u]||o(u,{}):v=e[u]&&e[u].prototype,v)for(b in c){if(m=c[b],s.dontCallGetSet?(x=t(v,b),g=x&&x.value):g=v[b],h=a(d?b:u+(f?".":"#")+b,s.forced),!h&&g!==void 0){if(typeof m==typeof g)continue;i(m,g)}(s.sham||g&&g.sham)&&r(m,"sham",!0),n(v,b,m,s)}},Dx}var Mx,Sj;function jE(){if(Sj)return Mx;Sj=1;var e=Er(),t=e("toStringTag"),r={};return r[t]="z",Mx=String(r)==="[object z]",Mx}var jx,Oj;function Af(){if(Oj)return jx;Oj=1;var e=jE(),t=Yt(),r=Qo(),n=Er(),o=n("toStringTag"),i=Object,a=r((function(){return arguments})())==="Arguments",s=function(c,u){try{return c[u]}catch{}};return jx=e?r:function(c){var u,d,f;return c===void 0?"Undefined":c===null?"Null":typeof(d=s(u=i(c),o))=="string"?d:a?r(u):(f=r(u))==="Object"&&t(u.callee)?"Arguments":f},jx}var Lx,Cj;function Mi(){if(Cj)return Lx;Cj=1;var e=Af(),t=String;return Lx=function(r){if(e(r)==="Symbol")throw new TypeError("Cannot convert a Symbol value to a string");return t(r)},Lx}var qx,Rj;function V3(){return Rj||(Rj=1,qx=`
|
|
121
|
+
\v\f\r \u2028\u2029\uFEFF`),qx}var zx,Nj;function Kce(){if(Nj)return zx;Nj=1;var e=gt(),t=ki(),r=Mi(),n=V3(),o=e("".replace),i=RegExp("^["+n+"]+"),a=RegExp("(^|[^"+n+"])["+n+"]+$"),s=function(c){return function(u){var d=r(t(u));return c&1&&(d=o(d,i,"")),c&2&&(d=o(d,a,"$1")),d}};return zx={start:s(1),end:s(2),trim:s(3)},zx}var Bx,Ij;function Xce(){if(Ij)return Bx;Ij=1;var e=Ft(),t=xt(),r=gt(),n=Mi(),o=Kce().trim,i=V3(),a=e.parseInt,s=e.Symbol,c=s&&s.iterator,u=/^[+-]?0x/i,d=r(u.exec),f=a(i+"08")!==8||a(i+"0x16")!==22||c&&!t(function(){a(Object(c))});return Bx=f?function(v,b){var g=o(n(v));return a(g,b>>>0||(d(u,g)?16:10))}:a,Bx}var Pj;function Zce(){if(Pj)return fM;Pj=1;var e=ei(),t=Xce();return e({global:!0,forced:parseInt!==t},{parseInt:t}),fM}Zce();var Tj={},Fx,Aj;function H3(){if(Aj)return Fx;Aj=1;var e=B3(),t=DE();return Fx=Object.keys||function(n){return e(n,t)},Fx}var $x,kj;function Jce(){if(kj)return $x;kj=1;var e=jn(),t=gt(),r=Mr(),n=xt(),o=H3(),i=F3(),a=N3(),s=Ga(),c=Of(),u=Object.assign,d=Object.defineProperty,f=t([].concat);return $x=!u||n(function(){if(e&&u({b:1},u(d({},"a",{enumerable:!0,get:function(){d(this,"b",{value:3,enumerable:!1})}}),{b:2})).b!==1)return!0;var h={},v={},b=Symbol("assign detection"),g="abcdefghijklmnopqrst";return h[b]=7,g.split("").forEach(function(m){v[m]=m}),u({},h)[b]!==7||o(u({},v)).join("")!==g})?function(v,b){for(var g=s(v),m=arguments.length,x=1,w=i.f,E=a.f;m>x;)for(var S=c(arguments[x++]),_=w?f(o(S),w(S)):o(S),C=_.length,N=0,P;C>N;)P=_[N++],(!e||r(E,S,P))&&(g[P]=S[P]);return g}:u,$x}var Dj;function Qce(){if(Dj)return Tj;Dj=1;var e=ei(),t=Jce();return e({target:"Object",stat:!0,arity:2,forced:Object.assign!==t},{assign:t}),Tj}Qce();var Mj={},Vx,jj;function eue(){if(jj)return Vx;jj=1;var e=Qo(),t=gt();return Vx=function(r){if(e(r)==="Function")return t(r)},Vx}var Hx,Lj;function W3(){if(Lj)return Hx;Lj=1;var e=eue(),t=jl(),r=Sf(),n=e(e.bind);return Hx=function(o,i){return t(o),i===void 0?o:r?n(o,i):function(){return o.apply(i,arguments)}},Hx}var Wx,qj;function tue(){if(qj)return Wx;qj=1;var e=Qo();return Wx=Array.isArray||function(r){return e(r)==="Array"},Wx}var Ux,zj;function rue(){if(zj)return Ux;zj=1;var e=gt(),t=xt(),r=Yt(),n=Af(),o=Cf(),i=L3(),a=function(){},s=o("Reflect","construct"),c=/^\s*(?:class|function)\b/,u=e(c.exec),d=!c.test(a),f=function(b){if(!r(b))return!1;try{return s(a,[],b),!0}catch{return!1}},h=function(b){if(!r(b))return!1;switch(n(b)){case"AsyncFunction":case"GeneratorFunction":case"AsyncGeneratorFunction":return!1}try{return d||!!u(c,i(b))}catch{return!0}};return h.sham=!0,Ux=!s||t(function(){var v;return f(f.call)||!f(Object)||!f(function(){v=!0})||v})?h:f,Ux}var Gx,Bj;function nue(){if(Bj)return Gx;Bj=1;var e=tue(),t=rue(),r=ar(),n=Er(),o=n("species"),i=Array;return Gx=function(a){var s;return e(a)&&(s=a.constructor,t(s)&&(s===i||e(s.prototype))?s=void 0:r(s)&&(s=s[o],s===null&&(s=void 0))),s===void 0?i:s},Gx}var Yx,Fj;function oue(){if(Fj)return Yx;Fj=1;var e=nue();return Yx=function(t,r){return new(e(t))(r===0?0:r)},Yx}var Kx,$j;function U3(){if($j)return Kx;$j=1;var e=W3(),t=gt(),r=Of(),n=Ga(),o=Tf(),i=oue(),a=t([].push),s=function(c){var u=c===1,d=c===2,f=c===3,h=c===4,v=c===6,b=c===7,g=c===5||v;return function(m,x,w,E){for(var S=n(m),_=r(S),C=o(_),N=e(x,w),P=0,A=E||i,j=u?A(m,C):d||b?A(m,0):void 0,M,L;C>P;P++)if((g||P in _)&&(M=_[P],L=N(M,P,S),c))if(u)j[P]=L;else if(L)switch(c){case 3:return!0;case 5:return M;case 6:return P;case 2:a(j,M)}else switch(c){case 4:return!1;case 7:a(j,M)}return v?-1:f||h?h:j}};return Kx={forEach:s(0),map:s(1),filter:s(2),some:s(3),every:s(4),find:s(5),findIndex:s(6),filterReject:s(7)},Kx}var Xx,Vj;function iue(){if(Vj)return Xx;Vj=1;var e=xt(),t=Er(),r=SE(),n=t("species");return Xx=function(o){return r>=51||!e(function(){var i=[],a=i.constructor={};return a[n]=function(){return{foo:1}},i[o](Boolean).foo!==1})},Xx}var Hj;function aue(){if(Hj)return Mj;Hj=1;var e=ei(),t=U3().filter,r=iue(),n=r("filter");return e({target:"Array",proto:!0,forced:!n},{filter:function(i){return t(this,i,arguments.length>1?arguments[1]:void 0)}}),Mj}aue();var Wj={},Zx,Uj;function sue(){if(Uj)return Zx;Uj=1;var e=jE(),t=Af();return Zx=e?{}.toString:function(){return"[object "+t(this)+"]"},Zx}var Gj;function lue(){if(Gj)return Wj;Gj=1;var e=jE(),t=Di(),r=sue();return e||t(Object.prototype,"toString",r,{unsafe:!0}),Wj}lue();var Jx={},Yj;function cue(){if(Yj)return Jx;Yj=1;var e=jn(),t=j3(),r=Oo(),n=bn(),o=Ua(),i=H3();return Jx.f=e&&!t?Object.defineProperties:function(s,c){n(s);for(var u=o(c),d=i(c),f=d.length,h=0,v;f>h;)r.f(s,v=d[h++],u[v]);return s},Jx}var Qx,Kj;function uue(){if(Kj)return Qx;Kj=1;var e=Cf();return Qx=e("document","documentElement"),Qx}var ew,Xj;function kf(){if(Xj)return ew;Xj=1;var e=bn(),t=cue(),r=DE(),n=If(),o=uue(),i=PE(),a=AE(),s=">",c="<",u="prototype",d="script",f=a("IE_PROTO"),h=function(){},v=function(w){return c+d+s+w+c+"/"+d+s},b=function(w){w.write(v("")),w.close();var E=w.parentWindow.Object;return w=null,E},g=function(){var w=i("iframe"),E="java"+d+":",S;return w.style.display="none",o.appendChild(w),w.src=String(E),S=w.contentWindow.document,S.open(),S.write(v("document.F=Object")),S.close(),S.F},m,x=function(){try{m=new ActiveXObject("htmlfile")}catch{}x=typeof document<"u"?document.domain&&m?b(m):g():b(m);for(var w=r.length;w--;)delete x[u][r[w]];return x()};return n[f]=!0,ew=Object.create||function(E,S){var _;return E!==null?(h[u]=e(E),_=new h,h[u]=null,_[f]=E):_=x(),S===void 0?_:t.f(_,S)},ew}var tw,Zj;function due(){if(Zj)return tw;Zj=1;var e=Er(),t=kf(),r=Oo().f,n=e("unscopables"),o=Array.prototype;return o[n]===void 0&&r(o,n,{configurable:!0,value:t(null)}),tw=function(i){o[n][i]=!0},tw}var rw,Jj;function zl(){return Jj||(Jj=1,rw={}),rw}var nw,Qj;function fue(){if(Qj)return nw;Qj=1;var e=xt();return nw=!e(function(){function t(){}return t.prototype.constructor=null,Object.getPrototypeOf(new t)!==t.prototype}),nw}var ow,e2;function G3(){if(e2)return ow;e2=1;var e=mn(),t=Yt(),r=Ga(),n=AE(),o=fue(),i=n("IE_PROTO"),a=Object,s=a.prototype;return ow=o?a.getPrototypeOf:function(c){var u=r(c);if(e(u,i))return u[i];var d=u.constructor;return t(d)&&u instanceof d?d.prototype:u instanceof a?s:null},ow}var iw,t2;function Y3(){if(t2)return iw;t2=1;var e=xt(),t=Yt(),r=ar(),n=kf(),o=G3(),i=Di(),a=Er(),s=Nf(),c=a("iterator"),u=!1,d,f,h;[].keys&&(h=[].keys(),"next"in h?(f=o(o(h)),f!==Object.prototype&&(d=f)):u=!0);var v=!r(d)||e(function(){var b={};return d[c].call(b)!==b});return v?d={}:s&&(d=n(d)),t(d[c])||i(d,c,function(){return this}),iw={IteratorPrototype:d,BUGGY_SAFARI_ITERATORS:u},iw}var aw,r2;function Df(){if(r2)return aw;r2=1;var e=Oo().f,t=mn(),r=Er(),n=r("toStringTag");return aw=function(o,i,a){o&&!a&&(o=o.prototype),o&&!t(o,n)&&e(o,n,{configurable:!0,value:i})},aw}var sw,n2;function pue(){if(n2)return sw;n2=1;var e=Y3().IteratorPrototype,t=kf(),r=EE(),n=Df(),o=zl(),i=function(){return this};return sw=function(a,s,c,u){var d=s+" Iterator";return a.prototype=t(e,{next:r(+!u,c)}),n(a,d,!1,!0),o[d]=i,a},sw}var lw,o2;function hue(){if(o2)return lw;o2=1;var e=gt(),t=jl();return lw=function(r,n,o){try{return e(t(Object.getOwnPropertyDescriptor(r,n)[o]))}catch{}},lw}var cw,i2;function vue(){if(i2)return cw;i2=1;var e=ar();return cw=function(t){return e(t)||t===null},cw}var uw,a2;function gue(){if(a2)return uw;a2=1;var e=vue(),t=String,r=TypeError;return uw=function(n){if(e(n))return n;throw new r("Can't set "+t(n)+" as a prototype")},uw}var dw,s2;function K3(){if(s2)return dw;s2=1;var e=hue(),t=ar(),r=ki(),n=gue();return dw=Object.setPrototypeOf||("__proto__"in{}?(function(){var o=!1,i={},a;try{a=e(Object.prototype,"__proto__","set"),a(i,[]),o=i instanceof Array}catch{}return function(c,u){return r(c),n(u),t(c)&&(o?a(c,u):c.__proto__=u),c}})():void 0),dw}var fw,l2;function X3(){if(l2)return fw;l2=1;var e=ei(),t=Mr(),r=Nf(),n=TE(),o=Yt(),i=pue(),a=G3(),s=K3(),c=Df(),u=ql(),d=Di(),f=Er(),h=zl(),v=Y3(),b=n.PROPER,g=n.CONFIGURABLE,m=v.IteratorPrototype,x=v.BUGGY_SAFARI_ITERATORS,w=f("iterator"),E="keys",S="values",_="entries",C=function(){return this};return fw=function(N,P,A,j,M,L,D){i(A,P,j);var T=function($){if($===M&&J)return J;if(!x&&$&&$ in G)return G[$];switch($){case E:return function(){return new A(this,$)};case S:return function(){return new A(this,$)};case _:return function(){return new A(this,$)}}return function(){return new A(this)}},W=P+" Iterator",q=!1,G=N.prototype,F=G[w]||G["@@iterator"]||M&&G[M],J=!x&&F||T(M),z=P==="Array"&&G.entries||F,U,oe,re;if(z&&(U=a(z.call(new N)),U!==Object.prototype&&U.next&&(!r&&a(U)!==m&&(s?s(U,m):o(U[w])||d(U,w,C)),c(U,W,!0,!0),r&&(h[W]=C))),b&&M===S&&F&&F.name!==S&&(!r&&g?u(G,"name",S):(q=!0,J=function(){return t(F,this)})),M)if(oe={values:T(S),keys:L?J:T(E),entries:T(_)},D)for(re in oe)(x||q||!(re in G))&&d(G,re,oe[re]);else e({target:P,proto:!0,forced:x||q},oe);return(!r||D)&&G[w]!==J&&d(G,w,J,{name:M}),h[P]=J,oe},fw}var pw,c2;function Z3(){return c2||(c2=1,pw=function(e,t){return{value:e,done:t}}),pw}var hw,u2;function J3(){if(u2)return hw;u2=1;var e=Ua(),t=due(),r=zl(),n=Ya(),o=Oo().f,i=X3(),a=Z3(),s=Nf(),c=jn(),u="Array Iterator",d=n.set,f=n.getterFor(u);hw=i(Array,"Array",function(v,b){d(this,{type:u,target:e(v),index:0,kind:b})},function(){var v=f(this),b=v.target,g=v.index++;if(!b||g>=b.length)return v.target=null,a(void 0,!0);switch(v.kind){case"keys":return a(g,!1);case"values":return a(b[g],!1)}return a([g,b[g]],!1)},"values");var h=r.Arguments=r.Array;if(t("keys"),t("values"),t("entries"),!s&&c&&h.name!=="values")try{o(h,"name",{value:"values"})}catch{}return hw}J3();var d2={},vw,f2;function Q3(){if(f2)return vw;f2=1;var e=gt(),t=Pf(),r=Mi(),n=ki(),o=e("".charAt),i=e("".charCodeAt),a=e("".slice),s=function(c){return function(u,d){var f=r(n(u)),h=t(d),v=f.length,b,g;return h<0||h>=v?c?"":void 0:(b=i(f,h),b<55296||b>56319||h+1===v||(g=i(f,h+1))<56320||g>57343?c?o(f,h):b:c?a(f,h,h+2):(b-55296<<10)+(g-56320)+65536)}};return vw={codeAt:s(!1),charAt:s(!0)},vw}var p2;function mue(){if(p2)return d2;p2=1;var e=Q3().charAt,t=Mi(),r=Ya(),n=X3(),o=Z3(),i="String Iterator",a=r.set,s=r.getterFor(i);return n(String,"String",function(c){a(this,{type:i,string:t(c),index:0})},function(){var u=s(this),d=u.string,f=u.index,h;return f>=d.length?o(void 0,!0):(h=e(d,f),u.index+=h.length,o(h,!1))}),d2}mue();var h2={},v2={},gw,g2;function e$(){if(g2)return gw;g2=1;var e=xt();return gw=!e(function(){return Object.isExtensible(Object.preventExtensions({}))}),gw}var mw,m2;function t$(){if(m2)return mw;m2=1;var e=Di();return mw=function(t,r,n){for(var o in r)e(t,o,r[o],n);return t},mw}var bw={exports:{}},yw={},xw,b2;function bue(){if(b2)return xw;b2=1;var e=gt();return xw=e([].slice),xw}var y2;function yue(){if(y2)return yw;y2=1;var e=Qo(),t=Ua(),r=ME().f,n=bue(),o=typeof window=="object"&&window&&Object.getOwnPropertyNames?Object.getOwnPropertyNames(window):[],i=function(a){try{return r(a)}catch{return n(o)}};return yw.f=function(s){return o&&e(s)==="Window"?i(s):r(t(s))},yw}var ww,x2;function xue(){if(x2)return ww;x2=1;var e=xt();return ww=e(function(){if(typeof ArrayBuffer=="function"){var t=new ArrayBuffer(8);Object.isExtensible(t)&&Object.defineProperty(t,"a",{value:8})}}),ww}var _w,w2;function wue(){if(w2)return _w;w2=1;var e=xt(),t=ar(),r=Qo(),n=xue(),o=Object.isExtensible,i=e(function(){});return _w=i||n?function(s){return!t(s)||n&&r(s)==="ArrayBuffer"?!1:o?o(s):!0}:o,_w}var _2;function LE(){if(_2)return bw.exports;_2=1;var e=ei(),t=gt(),r=If(),n=ar(),o=mn(),i=Oo().f,a=ME(),s=yue(),c=wue(),u=IE(),d=e$(),f=!1,h=u("meta"),v=0,b=function(S){i(S,h,{value:{objectID:"O"+v++,weakData:{}}})},g=function(S,_){if(!n(S))return typeof S=="symbol"?S:(typeof S=="string"?"S":"P")+S;if(!o(S,h)){if(!c(S))return"F";if(!_)return"E";b(S)}return S[h].objectID},m=function(S,_){if(!o(S,h)){if(!c(S))return!0;if(!_)return!1;b(S)}return S[h].weakData},x=function(S){return d&&f&&c(S)&&!o(S,h)&&b(S),S},w=function(){E.enable=function(){},f=!0;var S=a.f,_=t([].splice),C={};C[h]=1,S(C).length&&(a.f=function(N){for(var P=S(N),A=0,j=P.length;A<j;A++)if(P[A]===h){_(P,A,1);break}return P},e({target:"Object",stat:!0,forced:!0},{getOwnPropertyNames:s.f}))},E=bw.exports={enable:w,fastKey:g,getWeakData:m,onFreeze:x};return r[h]=!0,bw.exports}var Ew,E2;function _ue(){if(E2)return Ew;E2=1;var e=Er(),t=zl(),r=e("iterator"),n=Array.prototype;return Ew=function(o){return o!==void 0&&(t.Array===o||n[r]===o)},Ew}var Sw,S2;function r$(){if(S2)return Sw;S2=1;var e=Af(),t=Ll(),r=Ml(),n=zl(),o=Er(),i=o("iterator");return Sw=function(a){if(!r(a))return t(a,i)||t(a,"@@iterator")||n[e(a)]},Sw}var Ow,O2;function Eue(){if(O2)return Ow;O2=1;var e=Mr(),t=jl(),r=bn(),n=OE(),o=r$(),i=TypeError;return Ow=function(a,s){var c=arguments.length<2?o(a):s;if(t(c))return r(e(c,a));throw new i(n(a)+" is not iterable")},Ow}var Cw,C2;function Sue(){if(C2)return Cw;C2=1;var e=Mr(),t=bn(),r=Ll();return Cw=function(n,o,i){var a,s;t(n);try{if(a=r(n,"return"),!a){if(o==="throw")throw i;return i}a=e(a,n)}catch(c){s=!0,a=c}if(o==="throw")throw i;if(s)throw a;return t(a),i},Cw}var Rw,R2;function n$(){if(R2)return Rw;R2=1;var e=W3(),t=Mr(),r=bn(),n=OE(),o=_ue(),i=Tf(),a=Rf(),s=Eue(),c=r$(),u=Sue(),d=TypeError,f=function(v,b){this.stopped=v,this.result=b},h=f.prototype;return Rw=function(v,b,g){var m=g&&g.that,x=!!(g&&g.AS_ENTRIES),w=!!(g&&g.IS_RECORD),E=!!(g&&g.IS_ITERATOR),S=!!(g&&g.INTERRUPTED),_=e(b,m),C,N,P,A,j,M,L,D=function(W){return C&&u(C,"normal"),new f(!0,W)},T=function(W){return x?(r(W),S?_(W[0],W[1],D):_(W[0],W[1])):S?_(W,D):_(W)};if(w)C=v.iterator;else if(E)C=v;else{if(N=c(v),!N)throw new d(n(v)+" is not iterable");if(o(N)){for(P=0,A=i(v);A>P;P++)if(j=T(v[P]),j&&a(h,j))return j;return new f(!1)}C=s(v,N)}for(M=w?v.next:C.next;!(L=t(M,C)).done;){try{j=T(L.value)}catch(W){u(C,"throw",W)}if(typeof j=="object"&&j&&a(h,j))return j}return new f(!1)},Rw}var Nw,N2;function o$(){if(N2)return Nw;N2=1;var e=Rf(),t=TypeError;return Nw=function(r,n){if(e(n,r))return r;throw new t("Incorrect invocation")},Nw}var Iw,I2;function Oue(){if(I2)return Iw;I2=1;var e=Er(),t=e("iterator"),r=!1;try{var n=0,o={next:function(){return{done:!!n++}},return:function(){r=!0}};o[t]=function(){return this},Array.from(o,function(){throw 2})}catch{}return Iw=function(i,a){try{if(!a&&!r)return!1}catch{return!1}var s=!1;try{var c={};c[t]=function(){return{next:function(){return{done:s=!0}}}},i(c)}catch{}return s},Iw}var Pw,P2;function Cue(){if(P2)return Pw;P2=1;var e=Yt(),t=ar(),r=K3();return Pw=function(n,o,i){var a,s;return r&&e(a=o.constructor)&&a!==i&&t(s=a.prototype)&&s!==i.prototype&&r(n,s),n},Pw}var Tw,T2;function Rue(){if(T2)return Tw;T2=1;var e=ei(),t=Ft(),r=gt(),n=$3(),o=Di(),i=LE(),a=n$(),s=o$(),c=Yt(),u=Ml(),d=ar(),f=xt(),h=Oue(),v=Df(),b=Cue();return Tw=function(g,m,x){var w=g.indexOf("Map")!==-1,E=g.indexOf("Weak")!==-1,S=w?"set":"add",_=t[g],C=_&&_.prototype,N=_,P={},A=function(q){var G=r(C[q]);o(C,q,q==="add"?function(J){return G(this,J===0?0:J),this}:q==="delete"?function(F){return E&&!d(F)?!1:G(this,F===0?0:F)}:q==="get"?function(J){return E&&!d(J)?void 0:G(this,J===0?0:J)}:q==="has"?function(J){return E&&!d(J)?!1:G(this,J===0?0:J)}:function(J,z){return G(this,J===0?0:J,z),this})},j=n(g,!c(_)||!(E||C.forEach&&!f(function(){new _().entries().next()})));if(j)N=x.getConstructor(m,g,w,S),i.enable();else if(n(g,!0)){var M=new N,L=M[S](E?{}:-0,1)!==M,D=f(function(){M.has(1)}),T=h(function(q){new _(q)}),W=!E&&f(function(){for(var q=new _,G=5;G--;)q[S](G,G);return!q.has(-0)});T||(N=m(function(q,G){s(q,C);var F=b(new _,q,N);return u(G)||a(G,F[S],{that:F,AS_ENTRIES:w}),F}),N.prototype=C,C.constructor=N),(D||W)&&(A("delete"),A("has"),w&&A("get")),(W||L)&&A(S),E&&C.clear&&delete C.clear}return P[g]=N,e({global:!0,constructor:!0,forced:N!==_},P),v(N,g),E||x.setStrong(N,g,w),N},Tw}var Aw,A2;function Nue(){if(A2)return Aw;A2=1;var e=gt(),t=t$(),r=LE().getWeakData,n=o$(),o=bn(),i=Ml(),a=ar(),s=n$(),c=U3(),u=mn(),d=Ya(),f=d.set,h=d.getterFor,v=c.find,b=c.findIndex,g=e([].splice),m=0,x=function(S){return S.frozen||(S.frozen=new w)},w=function(){this.entries=[]},E=function(S,_){return v(S.entries,function(C){return C[0]===_})};return w.prototype={get:function(S){var _=E(this,S);if(_)return _[1]},has:function(S){return!!E(this,S)},set:function(S,_){var C=E(this,S);C?C[1]=_:this.entries.push([S,_])},delete:function(S){var _=b(this.entries,function(C){return C[0]===S});return~_&&g(this.entries,_,1),!!~_}},Aw={getConstructor:function(S,_,C,N){var P=S(function(L,D){n(L,A),f(L,{type:_,id:m++,frozen:null}),i(D)||s(D,L[N],{that:L,AS_ENTRIES:C})}),A=P.prototype,j=h(_),M=function(L,D,T){var W=j(L),q=r(o(D),!0);return q===!0?x(W).set(D,T):q[W.id]=T,L};return t(A,{delete:function(L){var D=j(this);if(!a(L))return!1;var T=r(L);return T===!0?x(D).delete(L):T&&u(T,D.id)&&delete T[D.id]},has:function(D){var T=j(this);if(!a(D))return!1;var W=r(D);return W===!0?x(T).has(D):W&&u(W,T.id)}}),t(A,C?{get:function(D){var T=j(this);if(a(D)){var W=r(D);if(W===!0)return x(T).get(D);if(W)return W[T.id]}},set:function(D,T){return M(this,D,T)}}:{add:function(D){return M(this,D,!0)}}),P}},Aw}var k2;function Iue(){if(k2)return v2;k2=1;var e=e$(),t=Ft(),r=gt(),n=t$(),o=LE(),i=Rue(),a=Nue(),s=ar(),c=Ya().enforce,u=xt(),d=q3(),f=Object,h=Array.isArray,v=f.isExtensible,b=f.isFrozen,g=f.isSealed,m=f.freeze,x=f.seal,w=!t.ActiveXObject&&"ActiveXObject"in t,E,S=function(L){return function(){return L(this,arguments.length?arguments[0]:void 0)}},_=i("WeakMap",S,a),C=_.prototype,N=r(C.set),P=function(){return e&&u(function(){var L=m([]);return N(new _,L,1),!b(L)})};if(d)if(w){E=a.getConstructor(S,"WeakMap",!0),o.enable();var A=r(C.delete),j=r(C.has),M=r(C.get);n(C,{delete:function(L){if(s(L)&&!v(L)){var D=c(this);return D.frozen||(D.frozen=new E),A(this,L)||D.frozen.delete(L)}return A(this,L)},has:function(D){if(s(D)&&!v(D)){var T=c(this);return T.frozen||(T.frozen=new E),j(this,D)||T.frozen.has(D)}return j(this,D)},get:function(D){if(s(D)&&!v(D)){var T=c(this);return T.frozen||(T.frozen=new E),j(this,D)?M(this,D):T.frozen.get(D)}return M(this,D)},set:function(D,T){if(s(D)&&!v(D)){var W=c(this);W.frozen||(W.frozen=new E),j(this,D)?N(this,D,T):W.frozen.set(D,T)}else N(this,D,T);return this}})}else P()&&n(C,{set:function(D,T){var W;return h(D)&&(b(D)?W=m:g(D)&&(W=x)),N(this,D,T),W&&W(D),this}});return v2}var D2;function Pue(){return D2||(D2=1,Iue()),h2}Pue();var M2={},kw,j2;function Tue(){return j2||(j2=1,kw={CSSRuleList:0,CSSStyleDeclaration:0,CSSValueList:0,ClientRectList:0,DOMRectList:0,DOMStringList:0,DOMTokenList:1,DataTransferItemList:0,FileList:0,HTMLAllCollection:0,HTMLCollection:0,HTMLFormElement:0,HTMLSelectElement:0,MediaList:0,MimeTypeArray:0,NamedNodeMap:0,NodeList:1,PaintRequestList:0,Plugin:0,PluginArray:0,SVGLengthList:0,SVGNumberList:0,SVGPathSegList:0,SVGPointList:0,SVGStringList:0,SVGTransformList:0,SourceBufferList:0,StyleSheetList:0,TextTrackCueList:0,TextTrackList:0,TouchList:0}),kw}var Dw,L2;function Aue(){if(L2)return Dw;L2=1;var e=PE(),t=e("span").classList,r=t&&t.constructor&&t.constructor.prototype;return Dw=r===Object.prototype?void 0:r,Dw}var q2;function kue(){if(q2)return M2;q2=1;var e=Ft(),t=Tue(),r=Aue(),n=J3(),o=ql(),i=Df(),a=Er(),s=a("iterator"),c=n.values,u=function(f,h){if(f){if(f[s]!==c)try{o(f,s,c)}catch{f[s]=c}if(i(f,h,!0),t[h]){for(var v in n)if(f[v]!==n[v])try{o(f,v,n[v])}catch{f[v]=n[v]}}}};for(var d in t)u(e[d]&&e[d].prototype,d);return u(r,"DOMTokenList"),M2}kue();var Mw,z2;function Due(){if(z2)return Mw;z2=1;var e="Expected a function",t=NaN,r="[object Symbol]",n=/^\s+|\s+$/g,o=/^[-+]0x[0-9a-f]+$/i,i=/^0b[01]+$/i,a=/^0o[0-7]+$/i,s=parseInt,c=typeof Tt=="object"&&Tt&&Tt.Object===Object&&Tt,u=typeof self=="object"&&self&&self.Object===Object&&self,d=c||u||Function("return this")(),f=Object.prototype,h=f.toString,v=Math.max,b=Math.min,g=function(){return d.Date.now()};function m(C,N,P){var A,j,M,L,D,T,W=0,q=!1,G=!1,F=!0;if(typeof C!="function")throw new TypeError(e);N=_(N)||0,w(P)&&(q=!!P.leading,G="maxWait"in P,M=G?v(_(P.maxWait)||0,N):M,F="trailing"in P?!!P.trailing:F);function J(K){var Q=A,ne=j;return A=j=void 0,W=K,L=C.apply(ne,Q),L}function z(K){return W=K,D=setTimeout(re,N),q?J(K):L}function U(K){var Q=K-T,ne=K-W,se=N-Q;return G?b(se,M-ne):se}function oe(K){var Q=K-T,ne=K-W;return T===void 0||Q>=N||Q<0||G&&ne>=M}function re(){var K=g();if(oe(K))return $(K);D=setTimeout(re,U(K))}function $(K){return D=void 0,F&&A?J(K):(A=j=void 0,L)}function Y(){D!==void 0&&clearTimeout(D),W=0,A=T=j=D=void 0}function X(){return D===void 0?L:$(g())}function H(){var K=g(),Q=oe(K);if(A=arguments,j=this,T=K,Q){if(D===void 0)return z(T);if(G)return D=setTimeout(re,N),J(T)}return D===void 0&&(D=setTimeout(re,N)),L}return H.cancel=Y,H.flush=X,H}function x(C,N,P){var A=!0,j=!0;if(typeof C!="function")throw new TypeError(e);return w(P)&&(A="leading"in P?!!P.leading:A,j="trailing"in P?!!P.trailing:j),m(C,N,{leading:A,maxWait:N,trailing:j})}function w(C){var N=typeof C;return!!C&&(N=="object"||N=="function")}function E(C){return!!C&&typeof C=="object"}function S(C){return typeof C=="symbol"||E(C)&&h.call(C)==r}function _(C){if(typeof C=="number")return C;if(S(C))return t;if(w(C)){var N=typeof C.valueOf=="function"?C.valueOf():C;C=w(N)?N+"":N}if(typeof C!="string")return C===0?C:+C;C=C.replace(n,"");var P=i.test(C);return P||a.test(C)?s(C.slice(2),P?2:8):o.test(C)?t:+C}return Mw=x,Mw}var Mue=Due();const B2=Zo(Mue);var jw,F2;function jue(){if(F2)return jw;F2=1;var e="Expected a function",t=NaN,r="[object Symbol]",n=/^\s+|\s+$/g,o=/^[-+]0x[0-9a-f]+$/i,i=/^0b[01]+$/i,a=/^0o[0-7]+$/i,s=parseInt,c=typeof Tt=="object"&&Tt&&Tt.Object===Object&&Tt,u=typeof self=="object"&&self&&self.Object===Object&&self,d=c||u||Function("return this")(),f=Object.prototype,h=f.toString,v=Math.max,b=Math.min,g=function(){return d.Date.now()};function m(_,C,N){var P,A,j,M,L,D,T=0,W=!1,q=!1,G=!0;if(typeof _!="function")throw new TypeError(e);C=S(C)||0,x(N)&&(W=!!N.leading,q="maxWait"in N,j=q?v(S(N.maxWait)||0,C):j,G="trailing"in N?!!N.trailing:G);function F(H){var K=P,Q=A;return P=A=void 0,T=H,M=_.apply(Q,K),M}function J(H){return T=H,L=setTimeout(oe,C),W?F(H):M}function z(H){var K=H-D,Q=H-T,ne=C-K;return q?b(ne,j-Q):ne}function U(H){var K=H-D,Q=H-T;return D===void 0||K>=C||K<0||q&&Q>=j}function oe(){var H=g();if(U(H))return re(H);L=setTimeout(oe,z(H))}function re(H){return L=void 0,G&&P?F(H):(P=A=void 0,M)}function $(){L!==void 0&&clearTimeout(L),T=0,P=D=A=L=void 0}function Y(){return L===void 0?M:re(g())}function X(){var H=g(),K=U(H);if(P=arguments,A=this,D=H,K){if(L===void 0)return J(D);if(q)return L=setTimeout(oe,C),F(D)}return L===void 0&&(L=setTimeout(oe,C)),M}return X.cancel=$,X.flush=Y,X}function x(_){var C=typeof _;return!!_&&(C=="object"||C=="function")}function w(_){return!!_&&typeof _=="object"}function E(_){return typeof _=="symbol"||w(_)&&h.call(_)==r}function S(_){if(typeof _=="number")return _;if(E(_))return t;if(x(_)){var C=typeof _.valueOf=="function"?_.valueOf():_;_=x(C)?C+"":C}if(typeof _!="string")return _===0?_:+_;_=_.replace(n,"");var N=i.test(_);return N||a.test(_)?s(_.slice(2),N?2:8):o.test(_)?t:+_}return jw=m,jw}var Lue=jue();const $2=Zo(Lue);var Lw,V2;function que(){if(V2)return Lw;V2=1;var e="Expected a function",t="__lodash_hash_undefined__",r="[object Function]",n="[object GeneratorFunction]",o=/[\\^$.*+?()[\]{}|]/g,i=/^\[object .+?Constructor\]$/,a=typeof Tt=="object"&&Tt&&Tt.Object===Object&&Tt,s=typeof self=="object"&&self&&self.Object===Object&&self,c=a||s||Function("return this")();function u(fe,le){return fe==null?void 0:fe[le]}function d(fe){var le=!1;if(fe!=null&&typeof fe.toString!="function")try{le=!!(fe+"")}catch{}return le}var f=Array.prototype,h=Function.prototype,v=Object.prototype,b=c["__core-js_shared__"],g=(function(){var fe=/[^.]+$/.exec(b&&b.keys&&b.keys.IE_PROTO||"");return fe?"Symbol(src)_1."+fe:""})(),m=h.toString,x=v.hasOwnProperty,w=v.toString,E=RegExp("^"+m.call(x).replace(o,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),S=f.splice,_=K(c,"Map"),C=K(Object,"create");function N(fe){var le=-1,Ce=fe?fe.length:0;for(this.clear();++le<Ce;){var Te=fe[le];this.set(Te[0],Te[1])}}function P(){this.__data__=C?C(null):{}}function A(fe){return this.has(fe)&&delete this.__data__[fe]}function j(fe){var le=this.__data__;if(C){var Ce=le[fe];return Ce===t?void 0:Ce}return x.call(le,fe)?le[fe]:void 0}function M(fe){var le=this.__data__;return C?le[fe]!==void 0:x.call(le,fe)}function L(fe,le){var Ce=this.__data__;return Ce[fe]=C&&le===void 0?t:le,this}N.prototype.clear=P,N.prototype.delete=A,N.prototype.get=j,N.prototype.has=M,N.prototype.set=L;function D(fe){var le=-1,Ce=fe?fe.length:0;for(this.clear();++le<Ce;){var Te=fe[le];this.set(Te[0],Te[1])}}function T(){this.__data__=[]}function W(fe){var le=this.__data__,Ce=Y(le,fe);if(Ce<0)return!1;var Te=le.length-1;return Ce==Te?le.pop():S.call(le,Ce,1),!0}function q(fe){var le=this.__data__,Ce=Y(le,fe);return Ce<0?void 0:le[Ce][1]}function G(fe){return Y(this.__data__,fe)>-1}function F(fe,le){var Ce=this.__data__,Te=Y(Ce,fe);return Te<0?Ce.push([fe,le]):Ce[Te][1]=le,this}D.prototype.clear=T,D.prototype.delete=W,D.prototype.get=q,D.prototype.has=G,D.prototype.set=F;function J(fe){var le=-1,Ce=fe?fe.length:0;for(this.clear();++le<Ce;){var Te=fe[le];this.set(Te[0],Te[1])}}function z(){this.__data__={hash:new N,map:new(_||D),string:new N}}function U(fe){return H(this,fe).delete(fe)}function oe(fe){return H(this,fe).get(fe)}function re(fe){return H(this,fe).has(fe)}function $(fe,le){return H(this,fe).set(fe,le),this}J.prototype.clear=z,J.prototype.delete=U,J.prototype.get=oe,J.prototype.has=re,J.prototype.set=$;function Y(fe,le){for(var Ce=fe.length;Ce--;)if(be(fe[Ce][0],le))return Ce;return-1}function X(fe){if(!Ee(fe)||ne(fe))return!1;var le=de(fe)||d(fe)?E:i;return le.test(se(fe))}function H(fe,le){var Ce=fe.__data__;return Q(le)?Ce[typeof le=="string"?"string":"hash"]:Ce.map}function K(fe,le){var Ce=u(fe,le);return X(Ce)?Ce:void 0}function Q(fe){var le=typeof fe;return le=="string"||le=="number"||le=="symbol"||le=="boolean"?fe!=="__proto__":fe===null}function ne(fe){return!!g&&g in fe}function se(fe){if(fe!=null){try{return m.call(fe)}catch{}try{return fe+""}catch{}}return""}function te(fe,le){if(typeof fe!="function"||le&&typeof le!="function")throw new TypeError(e);var Ce=function(){var Te=arguments,Fe=le?le.apply(this,Te):Te[0],Le=Ce.cache;if(Le.has(Fe))return Le.get(Fe);var Ze=fe.apply(this,Te);return Ce.cache=Le.set(Fe,Ze),Ze};return Ce.cache=new(te.Cache||J),Ce}te.Cache=J;function be(fe,le){return fe===le||fe!==fe&&le!==le}function de(fe){var le=Ee(fe)?w.call(fe):"";return le==r||le==n}function Ee(fe){var le=typeof fe;return!!fe&&(le=="object"||le=="function")}return Lw=te,Lw}var zue=que();const Bue=Zo(zue);var xi=[],Fue=function(){return xi.some(function(e){return e.activeTargets.length>0})},$ue=function(){return xi.some(function(e){return e.skippedTargets.length>0})},H2="ResizeObserver loop completed with undelivered notifications.",Vue=function(){var e;typeof ErrorEvent=="function"?e=new ErrorEvent("error",{message:H2}):(e=document.createEvent("Event"),e.initEvent("error",!1,!1),e.message=H2),window.dispatchEvent(e)},vl;(function(e){e.BORDER_BOX="border-box",e.CONTENT_BOX="content-box",e.DEVICE_PIXEL_CONTENT_BOX="device-pixel-content-box"})(vl||(vl={}));var wi=function(e){return Object.freeze(e)},Hue=(function(){function e(t,r){this.inlineSize=t,this.blockSize=r,wi(this)}return e})(),i$=(function(){function e(t,r,n,o){return this.x=t,this.y=r,this.width=n,this.height=o,this.top=this.y,this.left=this.x,this.bottom=this.top+this.height,this.right=this.left+this.width,wi(this)}return e.prototype.toJSON=function(){var t=this,r=t.x,n=t.y,o=t.top,i=t.right,a=t.bottom,s=t.left,c=t.width,u=t.height;return{x:r,y:n,top:o,right:i,bottom:a,left:s,width:c,height:u}},e.fromRect=function(t){return new e(t.x,t.y,t.width,t.height)},e})(),qE=function(e){return e instanceof SVGElement&&"getBBox"in e},a$=function(e){if(qE(e)){var t=e.getBBox(),r=t.width,n=t.height;return!r&&!n}var o=e,i=o.offsetWidth,a=o.offsetHeight;return!(i||a||e.getClientRects().length)},W2=function(e){var t;if(e instanceof Element)return!0;var r=(t=e==null?void 0:e.ownerDocument)===null||t===void 0?void 0:t.defaultView;return!!(r&&e instanceof r.Element)},Wue=function(e){switch(e.tagName){case"INPUT":if(e.type!=="image")break;case"VIDEO":case"AUDIO":case"EMBED":case"OBJECT":case"CANVAS":case"IFRAME":case"IMG":return!0}return!1},tl=typeof window<"u"?window:{},wu=new WeakMap,U2=/auto|scroll/,Uue=/^tb|vertical/,Gue=/msie|trident/i.test(tl.navigator&&tl.navigator.userAgent),Vn=function(e){return parseFloat(e||"0")},xa=function(e,t,r){return e===void 0&&(e=0),t===void 0&&(t=0),r===void 0&&(r=!1),new Hue((r?t:e)||0,(r?e:t)||0)},G2=wi({devicePixelContentBoxSize:xa(),borderBoxSize:xa(),contentBoxSize:xa(),contentRect:new i$(0,0,0,0)}),s$=function(e,t){if(t===void 0&&(t=!1),wu.has(e)&&!t)return wu.get(e);if(a$(e))return wu.set(e,G2),G2;var r=getComputedStyle(e),n=qE(e)&&e.ownerSVGElement&&e.getBBox(),o=!Gue&&r.boxSizing==="border-box",i=Uue.test(r.writingMode||""),a=!n&&U2.test(r.overflowY||""),s=!n&&U2.test(r.overflowX||""),c=n?0:Vn(r.paddingTop),u=n?0:Vn(r.paddingRight),d=n?0:Vn(r.paddingBottom),f=n?0:Vn(r.paddingLeft),h=n?0:Vn(r.borderTopWidth),v=n?0:Vn(r.borderRightWidth),b=n?0:Vn(r.borderBottomWidth),g=n?0:Vn(r.borderLeftWidth),m=f+u,x=c+d,w=g+v,E=h+b,S=s?e.offsetHeight-E-e.clientHeight:0,_=a?e.offsetWidth-w-e.clientWidth:0,C=o?m+w:0,N=o?x+E:0,P=n?n.width:Vn(r.width)-C-_,A=n?n.height:Vn(r.height)-N-S,j=P+m+_+w,M=A+x+S+E,L=wi({devicePixelContentBoxSize:xa(Math.round(P*devicePixelRatio),Math.round(A*devicePixelRatio),i),borderBoxSize:xa(j,M,i),contentBoxSize:xa(P,A,i),contentRect:new i$(f,c,P,A)});return wu.set(e,L),L},l$=function(e,t,r){var n=s$(e,r),o=n.borderBoxSize,i=n.contentBoxSize,a=n.devicePixelContentBoxSize;switch(t){case vl.DEVICE_PIXEL_CONTENT_BOX:return a;case vl.BORDER_BOX:return o;default:return i}},Yue=(function(){function e(t){var r=s$(t);this.target=t,this.contentRect=r.contentRect,this.borderBoxSize=wi([r.borderBoxSize]),this.contentBoxSize=wi([r.contentBoxSize]),this.devicePixelContentBoxSize=wi([r.devicePixelContentBoxSize])}return e})(),c$=function(e){if(a$(e))return 1/0;for(var t=0,r=e.parentNode;r;)t+=1,r=r.parentNode;return t},Kue=function(){var e=1/0,t=[];xi.forEach(function(a){if(a.activeTargets.length!==0){var s=[];a.activeTargets.forEach(function(u){var d=new Yue(u.target),f=c$(u.target);s.push(d),u.lastReportedSize=l$(u.target,u.observedBox),f<e&&(e=f)}),t.push(function(){a.callback.call(a.observer,s,a.observer)}),a.activeTargets.splice(0,a.activeTargets.length)}});for(var r=0,n=t;r<n.length;r++){var o=n[r];o()}return e},Y2=function(e){xi.forEach(function(r){r.activeTargets.splice(0,r.activeTargets.length),r.skippedTargets.splice(0,r.skippedTargets.length),r.observationTargets.forEach(function(o){o.isActive()&&(c$(o.target)>e?r.activeTargets.push(o):r.skippedTargets.push(o))})})},Xue=function(){var e=0;for(Y2(e);Fue();)e=Kue(),Y2(e);return $ue()&&Vue(),e>0},qw,u$=[],Zue=function(){return u$.splice(0).forEach(function(e){return e()})},Jue=function(e){if(!qw){var t=0,r=document.createTextNode(""),n={characterData:!0};new MutationObserver(function(){return Zue()}).observe(r,n),qw=function(){r.textContent="".concat(t?t--:t++)}}u$.push(e),qw()},Que=function(e){Jue(function(){requestAnimationFrame(e)})},$u=0,ede=function(){return!!$u},tde=250,rde={attributes:!0,characterData:!0,childList:!0,subtree:!0},K2=["resize","load","transitionend","animationend","animationstart","animationiteration","keyup","keydown","mouseup","mousedown","mouseover","mouseout","blur","focus"],X2=function(e){return e===void 0&&(e=0),Date.now()+e},zw=!1,nde=(function(){function e(){var t=this;this.stopped=!0,this.listener=function(){return t.schedule()}}return e.prototype.run=function(t){var r=this;if(t===void 0&&(t=tde),!zw){zw=!0;var n=X2(t);Que(function(){var o=!1;try{o=Xue()}finally{if(zw=!1,t=n-X2(),!ede())return;o?r.run(1e3):t>0?r.run(t):r.start()}})}},e.prototype.schedule=function(){this.stop(),this.run()},e.prototype.observe=function(){var t=this,r=function(){return t.observer&&t.observer.observe(document.body,rde)};document.body?r():tl.addEventListener("DOMContentLoaded",r)},e.prototype.start=function(){var t=this;this.stopped&&(this.stopped=!1,this.observer=new MutationObserver(this.listener),this.observe(),K2.forEach(function(r){return tl.addEventListener(r,t.listener,!0)}))},e.prototype.stop=function(){var t=this;this.stopped||(this.observer&&this.observer.disconnect(),K2.forEach(function(r){return tl.removeEventListener(r,t.listener,!0)}),this.stopped=!0)},e})(),V_=new nde,Z2=function(e){!$u&&e>0&&V_.start(),$u+=e,!$u&&V_.stop()},ode=function(e){return!qE(e)&&!Wue(e)&&getComputedStyle(e).display==="inline"},ide=(function(){function e(t,r){this.target=t,this.observedBox=r||vl.CONTENT_BOX,this.lastReportedSize={inlineSize:0,blockSize:0}}return e.prototype.isActive=function(){var t=l$(this.target,this.observedBox,!0);return ode(this.target)&&(this.lastReportedSize=t),this.lastReportedSize.inlineSize!==t.inlineSize||this.lastReportedSize.blockSize!==t.blockSize},e})(),ade=(function(){function e(t,r){this.activeTargets=[],this.skippedTargets=[],this.observationTargets=[],this.observer=t,this.callback=r}return e})(),_u=new WeakMap,J2=function(e,t){for(var r=0;r<e.length;r+=1)if(e[r].target===t)return r;return-1},Eu=(function(){function e(){}return e.connect=function(t,r){var n=new ade(t,r);_u.set(t,n)},e.observe=function(t,r,n){var o=_u.get(t),i=o.observationTargets.length===0;J2(o.observationTargets,r)<0&&(i&&xi.push(o),o.observationTargets.push(new ide(r,n&&n.box)),Z2(1),V_.schedule())},e.unobserve=function(t,r){var n=_u.get(t),o=J2(n.observationTargets,r),i=n.observationTargets.length===1;o>=0&&(i&&xi.splice(xi.indexOf(n),1),n.observationTargets.splice(o,1),Z2(-1))},e.disconnect=function(t){var r=this,n=_u.get(t);n.observationTargets.slice().forEach(function(o){return r.unobserve(t,o.target)}),n.activeTargets.splice(0,n.activeTargets.length)},e})(),sde=(function(){function e(t){if(arguments.length===0)throw new TypeError("Failed to construct 'ResizeObserver': 1 argument required, but only 0 present.");if(typeof t!="function")throw new TypeError("Failed to construct 'ResizeObserver': The callback provided as parameter 1 is not a function.");Eu.connect(this,t)}return e.prototype.observe=function(t,r){if(arguments.length===0)throw new TypeError("Failed to execute 'observe' on 'ResizeObserver': 1 argument required, but only 0 present.");if(!W2(t))throw new TypeError("Failed to execute 'observe' on 'ResizeObserver': parameter 1 is not of type 'Element");Eu.observe(this,t,r)},e.prototype.unobserve=function(t){if(arguments.length===0)throw new TypeError("Failed to execute 'unobserve' on 'ResizeObserver': 1 argument required, but only 0 present.");if(!W2(t))throw new TypeError("Failed to execute 'unobserve' on 'ResizeObserver': parameter 1 is not of type 'Element");Eu.unobserve(this,t)},e.prototype.disconnect=function(){Eu.disconnect(this)},e.toString=function(){return"function ResizeObserver () { [polyfill code] }"},e})(),Bw,Q2;function lde(){if(Q2)return Bw;Q2=1;var e=!!(typeof window<"u"&&window.document&&window.document.createElement);return Bw=e,Bw}var cde=lde();const d$=Zo(cde);var eL={},Fw,tL;function ude(){if(tL)return Fw;tL=1;var e=jl(),t=Ga(),r=Of(),n=Tf(),o=TypeError,i="Reduce of empty array with no initial value",a=function(s){return function(c,u,d,f){var h=t(c),v=r(h),b=n(h);if(e(u),b===0&&d<2)throw new o(i);var g=s?b-1:0,m=s?-1:1;if(d<2)for(;;){if(g in v){f=v[g],g+=m;break}if(g+=m,s?g<0:b<=g)throw new o(i)}for(;s?g>=0:b>g;g+=m)g in v&&(f=u(f,v[g],g,h));return f}};return Fw={left:a(!1),right:a(!0)},Fw}var $w,rL;function dde(){if(rL)return $w;rL=1;var e=xt();return $w=function(t,r){var n=[][t];return!!n&&e(function(){n.call(null,r||function(){return 1},1)})},$w}var Vw,nL;function fde(){if(nL)return Vw;nL=1;var e=Ft(),t=I3(),r=Qo(),n=function(o){return t.slice(0,o.length)===o};return Vw=(function(){return n("Bun/")?"BUN":n("Cloudflare-Workers")?"CLOUDFLARE":n("Deno/")?"DENO":n("Node.js/")?"NODE":e.Bun&&typeof Bun.version=="string"?"BUN":e.Deno&&typeof Deno.version=="object"?"DENO":r(e.process)==="process"?"NODE":e.window&&e.document?"BROWSER":"REST"})(),Vw}var Hw,oL;function pde(){if(oL)return Hw;oL=1;var e=fde();return Hw=e==="NODE",Hw}var iL;function hde(){if(iL)return eL;iL=1;var e=ei(),t=ude().left,r=dde(),n=SE(),o=pde(),i=!o&&n>79&&n<83,a=i||!r("reduce");return e({target:"Array",proto:!0,forced:a},{reduce:function(c){var u=arguments.length;return t(this,c,u,u>1?arguments[1]:void 0)}}),eL}hde();var aL={},Ww,sL;function f$(){if(sL)return Ww;sL=1;var e=bn();return Ww=function(){var t=e(this),r="";return t.hasIndices&&(r+="d"),t.global&&(r+="g"),t.ignoreCase&&(r+="i"),t.multiline&&(r+="m"),t.dotAll&&(r+="s"),t.unicode&&(r+="u"),t.unicodeSets&&(r+="v"),t.sticky&&(r+="y"),r},Ww}var Uw,lL;function vde(){if(lL)return Uw;lL=1;var e=xt(),t=Ft(),r=t.RegExp,n=e(function(){var a=r("a","y");return a.lastIndex=2,a.exec("abcd")!==null}),o=n||e(function(){return!r("a","y").sticky}),i=n||e(function(){var a=r("^r","gy");return a.lastIndex=2,a.exec("str")!==null});return Uw={BROKEN_CARET:i,MISSED_STICKY:o,UNSUPPORTED_Y:n},Uw}var Gw,cL;function gde(){if(cL)return Gw;cL=1;var e=xt(),t=Ft(),r=t.RegExp;return Gw=e(function(){var n=r(".","s");return!(n.dotAll&&n.test(`
|
|
122
|
+
`)&&n.flags==="s")}),Gw}var Yw,uL;function mde(){if(uL)return Yw;uL=1;var e=xt(),t=Ft(),r=t.RegExp;return Yw=e(function(){var n=r("(?<a>b)","g");return n.exec("b").groups.a!=="b"||"b".replace(n,"$<a>c")!=="bc"}),Yw}var Kw,dL;function zE(){if(dL)return Kw;dL=1;var e=Mr(),t=gt(),r=Mi(),n=f$(),o=vde(),i=NE(),a=kf(),s=Ya().get,c=gde(),u=mde(),d=i("native-string-replace",String.prototype.replace),f=RegExp.prototype.exec,h=f,v=t("".charAt),b=t("".indexOf),g=t("".replace),m=t("".slice),x=(function(){var _=/a/,C=/b*/g;return e(f,_,"a"),e(f,C,"a"),_.lastIndex!==0||C.lastIndex!==0})(),w=o.BROKEN_CARET,E=/()??/.exec("")[1]!==void 0,S=x||E||w||c||u;return S&&(h=function(C){var N=this,P=s(N),A=r(C),j=P.raw,M,L,D,T,W,q,G;if(j)return j.lastIndex=N.lastIndex,M=e(h,j,A),N.lastIndex=j.lastIndex,M;var F=P.groups,J=w&&N.sticky,z=e(n,N),U=N.source,oe=0,re=A;if(J&&(z=g(z,"y",""),b(z,"g")===-1&&(z+="g"),re=m(A,N.lastIndex),N.lastIndex>0&&(!N.multiline||N.multiline&&v(A,N.lastIndex-1)!==`
|
|
123
|
+
`)&&(U="(?: "+U+")",re=" "+re,oe++),L=new RegExp("^(?:"+U+")",z)),E&&(L=new RegExp("^"+U+"$(?!\\s)",z)),x&&(D=N.lastIndex),T=e(f,J?L:N,re),J?T?(T.input=m(T.input,oe),T[0]=m(T[0],oe),T.index=N.lastIndex,N.lastIndex+=T[0].length):N.lastIndex=0:x&&T&&(N.lastIndex=N.global?T.index+T[0].length:D),E&&T&&T.length>1&&e(d,T[0],L,function(){for(W=1;W<arguments.length-2;W++)arguments[W]===void 0&&(T[W]=void 0)}),T&&F)for(T.groups=q=a(null),W=0;W<F.length;W++)G=F[W],q[G[0]]=T[G[1]];return T}),Kw=h,Kw}var fL;function p$(){if(fL)return aL;fL=1;var e=ei(),t=zE();return e({target:"RegExp",proto:!0,forced:/./.exec!==t},{exec:t}),aL}p$();var pL={},Xw,hL;function h$(){if(hL)return Xw;hL=1,p$();var e=Mr(),t=Di(),r=zE(),n=xt(),o=Er(),i=ql(),a=o("species"),s=RegExp.prototype;return Xw=function(c,u,d,f){var h=o(c),v=!n(function(){var x={};return x[h]=function(){return 7},""[c](x)!==7}),b=v&&!n(function(){var x=!1,w=/a/;return c==="split"&&(w={},w.constructor={},w.constructor[a]=function(){return w},w.flags="",w[h]=/./[h]),w.exec=function(){return x=!0,null},w[h](""),!x});if(!v||!b||d){var g=/./[h],m=u(h,""[c],function(x,w,E,S,_){var C=w.exec;return C===r||C===s.exec?v&&!_?{done:!0,value:e(g,w,E,S)}:{done:!0,value:e(x,E,w,S)}:{done:!1}});t(String.prototype,c,m[0]),t(s,h,m[1])}f&&i(s[h],"sham",!0)},Xw}var Zw,vL;function v$(){if(vL)return Zw;vL=1;var e=Q3().charAt;return Zw=function(t,r,n){return r+(n?e(t,r).length:1)},Zw}var Jw,gL;function bde(){if(gL)return Jw;gL=1;var e=Ft(),t=xt(),r=e.RegExp,n=!t(function(){var o=!0;try{r(".","d")}catch{o=!1}var i={},a="",s=o?"dgimsy":"gimsy",c=function(h,v){Object.defineProperty(i,h,{get:function(){return a+=v,!0}})},u={dotAll:"s",global:"g",ignoreCase:"i",multiline:"m",sticky:"y"};o&&(u.hasIndices="d");for(var d in u)c(d,u[d]);var f=Object.getOwnPropertyDescriptor(r.prototype,"flags").get.call(i);return f!==s||a!==s});return Jw={correct:n},Jw}var Qw,mL;function g$(){if(mL)return Qw;mL=1;var e=Mr(),t=mn(),r=Rf(),n=bde(),o=f$(),i=RegExp.prototype;return Qw=n.correct?function(a){return a.flags}:function(a){return!n.correct&&r(i,a)&&!t(a,"flags")?e(o,a):a.flags},Qw}var e_,bL;function m$(){if(bL)return e_;bL=1;var e=Mr(),t=bn(),r=Yt(),n=Qo(),o=zE(),i=TypeError;return e_=function(a,s){var c=a.exec;if(r(c)){var u=e(c,a,s);return u!==null&&t(u),u}if(n(a)==="RegExp")return e(o,a,s);throw new i("RegExp#exec called on incompatible receiver")},e_}var yL;function yde(){if(yL)return pL;yL=1;var e=Mr(),t=gt(),r=h$(),n=bn(),o=ar(),i=kE(),a=Mi(),s=ki(),c=Ll(),u=v$(),d=g$(),f=m$(),h=t("".indexOf);return r("match",function(v,b,g){return[function(x){var w=s(this),E=o(x)?c(x,v):void 0;return E?e(E,x,w):new RegExp(x)[v](a(w))},function(m){var x=n(this),w=a(m),E=g(b,x,w);if(E.done)return E.value;var S=a(d(x));if(h(S,"g")===-1)return f(x,w);var _=h(S,"u")!==-1;x.lastIndex=0;for(var C=[],N=0,P;(P=f(x,w))!==null;){var A=a(P[0]);C[N]=A,A===""&&(x.lastIndex=u(w,i(x.lastIndex),_)),N++}return N===0?null:C}]}),pL}yde();var xL={},t_,wL;function xde(){if(wL)return t_;wL=1;var e=z3(),t=Oo();return t_=function(r,n,o){return o.get&&e(o.get,n,{getter:!0}),o.set&&e(o.set,n,{setter:!0}),t.f(r,n,o)},t_}var _L;function wde(){if(_L)return xL;_L=1;var e=jn(),t=TE().EXISTS,r=gt(),n=xde(),o=Function.prototype,i=r(o.toString),a=/function\b(?:\s|\/\*[\S\s]*?\*\/|\/\/[^\n\r]*[\n\r]+)*([^\s(/]*)/,s=r(a.exec),c="name";return e&&!t&&n(o,c,{configurable:!0,get:function(){try{return s(a,i(this))[1]}catch{return""}}}),xL}wde();var EL={},r_,SL;function _de(){if(SL)return r_;SL=1;var e=Sf(),t=Function.prototype,r=t.apply,n=t.call;return r_=typeof Reflect=="object"&&Reflect.apply||(e?n.bind(r):function(){return n.apply(r,arguments)}),r_}var n_,OL;function Ede(){if(OL)return n_;OL=1;var e=gt(),t=Ga(),r=Math.floor,n=e("".charAt),o=e("".replace),i=e("".slice),a=/\$([$&'`]|\d{1,2}|<[^>]*>)/g,s=/\$([$&'`]|\d{1,2})/g;return n_=function(c,u,d,f,h,v){var b=d+c.length,g=f.length,m=s;return h!==void 0&&(h=t(h),m=a),o(v,m,function(x,w){var E;switch(n(w,0)){case"$":return"$";case"&":return c;case"`":return i(u,0,d);case"'":return i(u,b);case"<":E=h[i(w,1,-1)];break;default:var S=+w;if(S===0)return x;if(S>g){var _=r(S/10);return _===0?x:_<=g?f[_-1]===void 0?n(w,1):f[_-1]+n(w,1):x}E=f[S-1]}return E===void 0?"":E})},n_}var CL;function Sde(){if(CL)return EL;CL=1;var e=_de(),t=Mr(),r=gt(),n=h$(),o=xt(),i=bn(),a=Yt(),s=ar(),c=Pf(),u=kE(),d=Mi(),f=ki(),h=v$(),v=Ll(),b=Ede(),g=g$(),m=m$(),x=Er(),w=x("replace"),E=Math.max,S=Math.min,_=r([].concat),C=r([].push),N=r("".indexOf),P=r("".slice),A=function(D){return D===void 0?D:String(D)},j=(function(){return"a".replace(/./,"$0")==="$0"})(),M=(function(){return/./[w]?/./[w]("a","$0")==="":!1})(),L=!o(function(){var D=/./;return D.exec=function(){var T=[];return T.groups={a:"7"},T},"".replace(D,"$<a>")!=="7"});return n("replace",function(D,T,W){var q=M?"$":"$0";return[function(F,J){var z=f(this),U=s(F)?v(F,w):void 0;return U?t(U,F,z,J):t(T,d(z),F,J)},function(G,F){var J=i(this),z=d(G);if(typeof F=="string"&&N(F,q)===-1&&N(F,"$<")===-1){var U=W(T,J,z,F);if(U.done)return U.value}var oe=a(F);oe||(F=d(F));var re=d(g(J)),$=N(re,"g")!==-1,Y;$&&(Y=N(re,"u")!==-1,J.lastIndex=0);for(var X=[],H;H=m(J,z),!(H===null||(C(X,H),!$));){var K=d(H[0]);K===""&&(J.lastIndex=h(z,u(J.lastIndex),Y))}for(var Q="",ne=0,se=0;se<X.length;se++){H=X[se];for(var te=d(H[0]),be=E(S(c(H.index),z.length),0),de=[],Ee,fe=1;fe<H.length;fe++)C(de,A(H[fe]));var le=H.groups;if(oe){var Ce=_([te],de,be,z);le!==void 0&&C(Ce,le),Ee=d(e(F,void 0,Ce))}else Ee=b(te,z,be,de,le,F);be>=ne&&(Q+=P(z,ne,be)+Ee,ne=be+te.length)}return Q+P(z,ne)}]},!L||!j||M),EL}Sde();function $o(e){return!e||!e.ownerDocument||!e.ownerDocument.defaultView?window:e.ownerDocument.defaultView}function Vu(e){return!e||!e.ownerDocument?document:e.ownerDocument}var la=null,RL=null;d$&&window.addEventListener("resize",function(){RL!==window.devicePixelRatio&&(RL=window.devicePixelRatio,la=null)});function NL(e){if(la===null){var t=Vu(e);if(typeof t>"u")return la=0,la;var r=t.body,n=t.createElement("div");n.classList.add("simplebar-hide-scrollbar"),r.appendChild(n);var o=n.getBoundingClientRect().right;r.removeChild(n),la=o}return la}var Rd=(function(){function e(r,n){var o=this;this.onScroll=function(){var i=$o(o.el);o.scrollXTicking||(i.requestAnimationFrame(o.scrollX),o.scrollXTicking=!0),o.scrollYTicking||(i.requestAnimationFrame(o.scrollY),o.scrollYTicking=!0)},this.scrollX=function(){o.axis.x.isOverflowing&&(o.showScrollbar("x"),o.positionScrollbar("x")),o.scrollXTicking=!1},this.scrollY=function(){o.axis.y.isOverflowing&&(o.showScrollbar("y"),o.positionScrollbar("y")),o.scrollYTicking=!1},this.onMouseEnter=function(){o.showScrollbar("x"),o.showScrollbar("y")},this.onMouseMove=function(i){o.mouseX=i.clientX,o.mouseY=i.clientY,(o.axis.x.isOverflowing||o.axis.x.forceVisible)&&o.onMouseMoveForAxis("x"),(o.axis.y.isOverflowing||o.axis.y.forceVisible)&&o.onMouseMoveForAxis("y")},this.onMouseLeave=function(){o.onMouseMove.cancel(),(o.axis.x.isOverflowing||o.axis.x.forceVisible)&&o.onMouseLeaveForAxis("x"),(o.axis.y.isOverflowing||o.axis.y.forceVisible)&&o.onMouseLeaveForAxis("y"),o.mouseX=-1,o.mouseY=-1},this.onWindowResize=function(){o.scrollbarWidth=o.getScrollbarWidth(),o.hideNativeScrollbar()},this.hideScrollbars=function(){o.axis.x.track.rect=o.axis.x.track.el.getBoundingClientRect(),o.axis.y.track.rect=o.axis.y.track.el.getBoundingClientRect(),o.isWithinBounds(o.axis.y.track.rect)||(o.axis.y.scrollbar.el.classList.remove(o.classNames.visible),o.axis.y.isVisible=!1),o.isWithinBounds(o.axis.x.track.rect)||(o.axis.x.scrollbar.el.classList.remove(o.classNames.visible),o.axis.x.isVisible=!1)},this.onPointerEvent=function(i){var a,s;o.axis.x.track.rect=o.axis.x.track.el.getBoundingClientRect(),o.axis.y.track.rect=o.axis.y.track.el.getBoundingClientRect(),(o.axis.x.isOverflowing||o.axis.x.forceVisible)&&(a=o.isWithinBounds(o.axis.x.track.rect)),(o.axis.y.isOverflowing||o.axis.y.forceVisible)&&(s=o.isWithinBounds(o.axis.y.track.rect)),(a||s)&&(i.preventDefault(),i.stopPropagation(),i.type==="mousedown"&&(a&&(o.axis.x.scrollbar.rect=o.axis.x.scrollbar.el.getBoundingClientRect(),o.isWithinBounds(o.axis.x.scrollbar.rect)?o.onDragStart(i,"x"):o.onTrackClick(i,"x")),s&&(o.axis.y.scrollbar.rect=o.axis.y.scrollbar.el.getBoundingClientRect(),o.isWithinBounds(o.axis.y.scrollbar.rect)?o.onDragStart(i,"y"):o.onTrackClick(i,"y"))))},this.drag=function(i){var a,s=o.axis[o.draggedAxis].track,c=s.rect[o.axis[o.draggedAxis].sizeAttr],u=o.axis[o.draggedAxis].scrollbar,d=o.contentWrapperEl[o.axis[o.draggedAxis].scrollSizeAttr],f=parseInt(o.elStyles[o.axis[o.draggedAxis].sizeAttr],10);i.preventDefault(),i.stopPropagation(),o.draggedAxis==="y"?a=i.pageY:a=i.pageX;var h=a-s.rect[o.axis[o.draggedAxis].offsetAttr]-o.axis[o.draggedAxis].dragOffset,v=h/(c-u.size),b=v*(d-f);o.draggedAxis==="x"&&(b=o.isRtl&&e.getRtlHelpers().isRtlScrollbarInverted?b-(c+u.size):b,b=o.isRtl&&e.getRtlHelpers().isRtlScrollingInverted?-b:b),o.contentWrapperEl[o.axis[o.draggedAxis].scrollOffsetAttr]=b},this.onEndDrag=function(i){var a=Vu(o.el),s=$o(o.el);i.preventDefault(),i.stopPropagation(),o.el.classList.remove(o.classNames.dragging),a.removeEventListener("mousemove",o.drag,!0),a.removeEventListener("mouseup",o.onEndDrag,!0),o.removePreventClickId=s.setTimeout(function(){a.removeEventListener("click",o.preventClick,!0),a.removeEventListener("dblclick",o.preventClick,!0),o.removePreventClickId=null})},this.preventClick=function(i){i.preventDefault(),i.stopPropagation()},this.el=r,this.minScrollbarWidth=20,this.options=Object.assign({},e.defaultOptions,n),this.classNames=Object.assign({},e.defaultOptions.classNames,this.options.classNames),this.axis={x:{scrollOffsetAttr:"scrollLeft",sizeAttr:"width",scrollSizeAttr:"scrollWidth",offsetSizeAttr:"offsetWidth",offsetAttr:"left",overflowAttr:"overflowX",dragOffset:0,isOverflowing:!0,isVisible:!1,forceVisible:!1,track:{},scrollbar:{}},y:{scrollOffsetAttr:"scrollTop",sizeAttr:"height",scrollSizeAttr:"scrollHeight",offsetSizeAttr:"offsetHeight",offsetAttr:"top",overflowAttr:"overflowY",dragOffset:0,isOverflowing:!0,isVisible:!1,forceVisible:!1,track:{},scrollbar:{}}},this.removePreventClickId=null,!e.instances.has(this.el)&&(this.recalculate=B2(this.recalculate.bind(this),64),this.onMouseMove=B2(this.onMouseMove.bind(this),64),this.hideScrollbars=$2(this.hideScrollbars.bind(this),this.options.timeout),this.onWindowResize=$2(this.onWindowResize.bind(this),64,{leading:!0}),e.getRtlHelpers=Bue(e.getRtlHelpers),this.init())}e.getRtlHelpers=function(){var n=document.createElement("div");n.innerHTML='<div class="hs-dummy-scrollbar-size"><div style="height: 200%; width: 200%; margin: 10px 0;"></div></div>';var o=n.firstElementChild;document.body.appendChild(o);var i=o.firstElementChild;o.scrollLeft=0;var a=e.getOffset(o),s=e.getOffset(i);o.scrollLeft=999;var c=e.getOffset(i);return{isRtlScrollingInverted:a.left!==s.left&&s.left-c.left!==0,isRtlScrollbarInverted:a.left!==s.left}},e.getOffset=function(n){var o=n.getBoundingClientRect(),i=Vu(n),a=$o(n);return{top:o.top+(a.pageYOffset||i.documentElement.scrollTop),left:o.left+(a.pageXOffset||i.documentElement.scrollLeft)}};var t=e.prototype;return t.init=function(){e.instances.set(this.el,this),d$&&(this.initDOM(),this.setAccessibilityAttributes(),this.scrollbarWidth=this.getScrollbarWidth(),this.recalculate(),this.initListeners())},t.initDOM=function(){var n=this;if(Array.prototype.filter.call(this.el.children,function(a){return a.classList.contains(n.classNames.wrapper)}).length)this.wrapperEl=this.el.querySelector("."+this.classNames.wrapper),this.contentWrapperEl=this.options.scrollableNode||this.el.querySelector("."+this.classNames.contentWrapper),this.contentEl=this.options.contentNode||this.el.querySelector("."+this.classNames.contentEl),this.offsetEl=this.el.querySelector("."+this.classNames.offset),this.maskEl=this.el.querySelector("."+this.classNames.mask),this.placeholderEl=this.findChild(this.wrapperEl,"."+this.classNames.placeholder),this.heightAutoObserverWrapperEl=this.el.querySelector("."+this.classNames.heightAutoObserverWrapperEl),this.heightAutoObserverEl=this.el.querySelector("."+this.classNames.heightAutoObserverEl),this.axis.x.track.el=this.findChild(this.el,"."+this.classNames.track+"."+this.classNames.horizontal),this.axis.y.track.el=this.findChild(this.el,"."+this.classNames.track+"."+this.classNames.vertical);else{for(this.wrapperEl=document.createElement("div"),this.contentWrapperEl=document.createElement("div"),this.offsetEl=document.createElement("div"),this.maskEl=document.createElement("div"),this.contentEl=document.createElement("div"),this.placeholderEl=document.createElement("div"),this.heightAutoObserverWrapperEl=document.createElement("div"),this.heightAutoObserverEl=document.createElement("div"),this.wrapperEl.classList.add(this.classNames.wrapper),this.contentWrapperEl.classList.add(this.classNames.contentWrapper),this.offsetEl.classList.add(this.classNames.offset),this.maskEl.classList.add(this.classNames.mask),this.contentEl.classList.add(this.classNames.contentEl),this.placeholderEl.classList.add(this.classNames.placeholder),this.heightAutoObserverWrapperEl.classList.add(this.classNames.heightAutoObserverWrapperEl),this.heightAutoObserverEl.classList.add(this.classNames.heightAutoObserverEl);this.el.firstChild;)this.contentEl.appendChild(this.el.firstChild);this.contentWrapperEl.appendChild(this.contentEl),this.offsetEl.appendChild(this.contentWrapperEl),this.maskEl.appendChild(this.offsetEl),this.heightAutoObserverWrapperEl.appendChild(this.heightAutoObserverEl),this.wrapperEl.appendChild(this.heightAutoObserverWrapperEl),this.wrapperEl.appendChild(this.maskEl),this.wrapperEl.appendChild(this.placeholderEl),this.el.appendChild(this.wrapperEl)}if(!this.axis.x.track.el||!this.axis.y.track.el){var o=document.createElement("div"),i=document.createElement("div");o.classList.add(this.classNames.track),i.classList.add(this.classNames.scrollbar),o.appendChild(i),this.axis.x.track.el=o.cloneNode(!0),this.axis.x.track.el.classList.add(this.classNames.horizontal),this.axis.y.track.el=o.cloneNode(!0),this.axis.y.track.el.classList.add(this.classNames.vertical),this.el.appendChild(this.axis.x.track.el),this.el.appendChild(this.axis.y.track.el)}this.axis.x.scrollbar.el=this.axis.x.track.el.querySelector("."+this.classNames.scrollbar),this.axis.y.scrollbar.el=this.axis.y.track.el.querySelector("."+this.classNames.scrollbar),this.options.autoHide||(this.axis.x.scrollbar.el.classList.add(this.classNames.visible),this.axis.y.scrollbar.el.classList.add(this.classNames.visible)),this.el.setAttribute("data-simplebar","init")},t.setAccessibilityAttributes=function(){var n=this.options.ariaLabel||"scrollable content";this.contentWrapperEl.setAttribute("tabindex","0"),this.contentWrapperEl.setAttribute("role","region"),this.contentWrapperEl.setAttribute("aria-label",n)},t.initListeners=function(){var n=this,o=$o(this.el);this.options.autoHide&&this.el.addEventListener("mouseenter",this.onMouseEnter),["mousedown","click","dblclick"].forEach(function(c){n.el.addEventListener(c,n.onPointerEvent,!0)}),["touchstart","touchend","touchmove"].forEach(function(c){n.el.addEventListener(c,n.onPointerEvent,{capture:!0,passive:!0})}),this.el.addEventListener("mousemove",this.onMouseMove),this.el.addEventListener("mouseleave",this.onMouseLeave),this.contentWrapperEl.addEventListener("scroll",this.onScroll),o.addEventListener("resize",this.onWindowResize);var i=!1,a=null,s=o.ResizeObserver||sde;this.resizeObserver=new s(function(){!i||a!==null||(a=o.requestAnimationFrame(function(){n.recalculate(),a=null}))}),this.resizeObserver.observe(this.el),this.resizeObserver.observe(this.contentEl),o.requestAnimationFrame(function(){i=!0}),this.mutationObserver=new o.MutationObserver(this.recalculate),this.mutationObserver.observe(this.contentEl,{childList:!0,subtree:!0,characterData:!0})},t.recalculate=function(){var n=$o(this.el);this.elStyles=n.getComputedStyle(this.el),this.isRtl=this.elStyles.direction==="rtl";var o=this.heightAutoObserverEl.offsetHeight<=1,i=this.heightAutoObserverEl.offsetWidth<=1,a=this.contentEl.offsetWidth,s=this.contentWrapperEl.offsetWidth,c=this.elStyles.overflowX,u=this.elStyles.overflowY;this.contentEl.style.padding=this.elStyles.paddingTop+" "+this.elStyles.paddingRight+" "+this.elStyles.paddingBottom+" "+this.elStyles.paddingLeft,this.wrapperEl.style.margin="-"+this.elStyles.paddingTop+" -"+this.elStyles.paddingRight+" -"+this.elStyles.paddingBottom+" -"+this.elStyles.paddingLeft;var d=this.contentEl.scrollHeight,f=this.contentEl.scrollWidth;this.contentWrapperEl.style.height=o?"auto":"100%",this.placeholderEl.style.width=i?a+"px":"auto",this.placeholderEl.style.height=d+"px";var h=this.contentWrapperEl.offsetHeight;this.axis.x.isOverflowing=f>a,this.axis.y.isOverflowing=d>h,this.axis.x.isOverflowing=c==="hidden"?!1:this.axis.x.isOverflowing,this.axis.y.isOverflowing=u==="hidden"?!1:this.axis.y.isOverflowing,this.axis.x.forceVisible=this.options.forceVisible==="x"||this.options.forceVisible===!0,this.axis.y.forceVisible=this.options.forceVisible==="y"||this.options.forceVisible===!0,this.hideNativeScrollbar();var v=this.axis.x.isOverflowing?this.scrollbarWidth:0,b=this.axis.y.isOverflowing?this.scrollbarWidth:0;this.axis.x.isOverflowing=this.axis.x.isOverflowing&&f>s-b,this.axis.y.isOverflowing=this.axis.y.isOverflowing&&d>h-v,this.axis.x.scrollbar.size=this.getScrollbarSize("x"),this.axis.y.scrollbar.size=this.getScrollbarSize("y"),this.axis.x.scrollbar.el.style.width=this.axis.x.scrollbar.size+"px",this.axis.y.scrollbar.el.style.height=this.axis.y.scrollbar.size+"px",this.positionScrollbar("x"),this.positionScrollbar("y"),this.toggleTrackVisibility("x"),this.toggleTrackVisibility("y")},t.getScrollbarSize=function(n){if(n===void 0&&(n="y"),!this.axis[n].isOverflowing)return 0;var o=this.contentEl[this.axis[n].scrollSizeAttr],i=this.axis[n].track.el[this.axis[n].offsetSizeAttr],a,s=i/o;return a=Math.max(~~(s*i),this.options.scrollbarMinSize),this.options.scrollbarMaxSize&&(a=Math.min(a,this.options.scrollbarMaxSize)),a},t.positionScrollbar=function(n){if(n===void 0&&(n="y"),!!this.axis[n].isOverflowing){var o=this.contentWrapperEl[this.axis[n].scrollSizeAttr],i=this.axis[n].track.el[this.axis[n].offsetSizeAttr],a=parseInt(this.elStyles[this.axis[n].sizeAttr],10),s=this.axis[n].scrollbar,c=this.contentWrapperEl[this.axis[n].scrollOffsetAttr];c=n==="x"&&this.isRtl&&e.getRtlHelpers().isRtlScrollingInverted?-c:c;var u=c/(o-a),d=~~((i-s.size)*u);d=n==="x"&&this.isRtl&&e.getRtlHelpers().isRtlScrollbarInverted?d+(i-s.size):d,s.el.style.transform=n==="x"?"translate3d("+d+"px, 0, 0)":"translate3d(0, "+d+"px, 0)"}},t.toggleTrackVisibility=function(n){n===void 0&&(n="y");var o=this.axis[n].track.el,i=this.axis[n].scrollbar.el;this.axis[n].isOverflowing||this.axis[n].forceVisible?(o.style.visibility="visible",this.contentWrapperEl.style[this.axis[n].overflowAttr]="scroll"):(o.style.visibility="hidden",this.contentWrapperEl.style[this.axis[n].overflowAttr]="hidden"),this.axis[n].isOverflowing?i.style.display="block":i.style.display="none"},t.hideNativeScrollbar=function(){this.offsetEl.style[this.isRtl?"left":"right"]=this.axis.y.isOverflowing||this.axis.y.forceVisible?"-"+this.scrollbarWidth+"px":0,this.offsetEl.style.bottom=this.axis.x.isOverflowing||this.axis.x.forceVisible?"-"+this.scrollbarWidth+"px":0},t.onMouseMoveForAxis=function(n){n===void 0&&(n="y"),this.axis[n].track.rect=this.axis[n].track.el.getBoundingClientRect(),this.axis[n].scrollbar.rect=this.axis[n].scrollbar.el.getBoundingClientRect();var o=this.isWithinBounds(this.axis[n].scrollbar.rect);o?this.axis[n].scrollbar.el.classList.add(this.classNames.hover):this.axis[n].scrollbar.el.classList.remove(this.classNames.hover),this.isWithinBounds(this.axis[n].track.rect)?(this.showScrollbar(n),this.axis[n].track.el.classList.add(this.classNames.hover)):this.axis[n].track.el.classList.remove(this.classNames.hover)},t.onMouseLeaveForAxis=function(n){n===void 0&&(n="y"),this.axis[n].track.el.classList.remove(this.classNames.hover),this.axis[n].scrollbar.el.classList.remove(this.classNames.hover)},t.showScrollbar=function(n){n===void 0&&(n="y");var o=this.axis[n].scrollbar.el;this.axis[n].isVisible||(o.classList.add(this.classNames.visible),this.axis[n].isVisible=!0),this.options.autoHide&&this.hideScrollbars()},t.onDragStart=function(n,o){o===void 0&&(o="y");var i=Vu(this.el),a=$o(this.el),s=this.axis[o].scrollbar,c=o==="y"?n.pageY:n.pageX;this.axis[o].dragOffset=c-s.rect[this.axis[o].offsetAttr],this.draggedAxis=o,this.el.classList.add(this.classNames.dragging),i.addEventListener("mousemove",this.drag,!0),i.addEventListener("mouseup",this.onEndDrag,!0),this.removePreventClickId===null?(i.addEventListener("click",this.preventClick,!0),i.addEventListener("dblclick",this.preventClick,!0)):(a.clearTimeout(this.removePreventClickId),this.removePreventClickId=null)},t.onTrackClick=function(n,o){var i=this;if(o===void 0&&(o="y"),!!this.options.clickOnTrack){var a=$o(this.el);this.axis[o].scrollbar.rect=this.axis[o].scrollbar.el.getBoundingClientRect();var s=this.axis[o].scrollbar,c=s.rect[this.axis[o].offsetAttr],u=parseInt(this.elStyles[this.axis[o].sizeAttr],10),d=this.contentWrapperEl[this.axis[o].scrollOffsetAttr],f=o==="y"?this.mouseY-c:this.mouseX-c,h=f<0?-1:1,v=h===-1?d-u:d+u,b=function g(){if(h===-1){if(d>v){var m;d-=i.options.clickOnTrackSpeed,i.contentWrapperEl.scrollTo((m={},m[i.axis[o].offsetAttr]=d,m)),a.requestAnimationFrame(g)}}else if(d<v){var x;d+=i.options.clickOnTrackSpeed,i.contentWrapperEl.scrollTo((x={},x[i.axis[o].offsetAttr]=d,x)),a.requestAnimationFrame(g)}};b()}},t.getContentElement=function(){return this.contentEl},t.getScrollElement=function(){return this.contentWrapperEl},t.getScrollbarWidth=function(){try{return getComputedStyle(this.contentWrapperEl,"::-webkit-scrollbar").display==="none"||"scrollbarWidth"in document.documentElement.style||"-ms-overflow-style"in document.documentElement.style?0:NL(this.el)}catch{return NL(this.el)}},t.removeListeners=function(){var n=this,o=$o(this.el);this.options.autoHide&&this.el.removeEventListener("mouseenter",this.onMouseEnter),["mousedown","click","dblclick"].forEach(function(i){n.el.removeEventListener(i,n.onPointerEvent,!0)}),["touchstart","touchend","touchmove"].forEach(function(i){n.el.removeEventListener(i,n.onPointerEvent,{capture:!0,passive:!0})}),this.el.removeEventListener("mousemove",this.onMouseMove),this.el.removeEventListener("mouseleave",this.onMouseLeave),this.contentWrapperEl&&this.contentWrapperEl.removeEventListener("scroll",this.onScroll),o.removeEventListener("resize",this.onWindowResize),this.mutationObserver&&this.mutationObserver.disconnect(),this.resizeObserver&&this.resizeObserver.disconnect(),this.recalculate.cancel(),this.onMouseMove.cancel(),this.hideScrollbars.cancel(),this.onWindowResize.cancel()},t.unMount=function(){this.removeListeners(),e.instances.delete(this.el)},t.isWithinBounds=function(n){return this.mouseX>=n.left&&this.mouseX<=n.left+n.width&&this.mouseY>=n.top&&this.mouseY<=n.top+n.height},t.findChild=function(n,o){var i=n.matches||n.webkitMatchesSelector||n.mozMatchesSelector||n.msMatchesSelector;return Array.prototype.filter.call(n.children,function(a){return i.call(a,o)})[0]},e})();Rd.defaultOptions={autoHide:!0,forceVisible:!1,clickOnTrack:!0,clickOnTrackSpeed:40,classNames:{contentEl:"simplebar-content",contentWrapper:"simplebar-content-wrapper",offset:"simplebar-offset",mask:"simplebar-mask",wrapper:"simplebar-wrapper",placeholder:"simplebar-placeholder",scrollbar:"simplebar-scrollbar",track:"simplebar-track",heightAutoObserverWrapperEl:"simplebar-height-auto-observer-wrapper",heightAutoObserverEl:"simplebar-height-auto-observer",visible:"simplebar-visible",horizontal:"simplebar-horizontal",vertical:"simplebar-vertical",hover:"simplebar-hover",dragging:"simplebar-dragging"},scrollbarMinSize:25,scrollbarMaxSize:0,timeout:1e3};Rd.instances=new WeakMap;function IL(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),r.push.apply(r,n)}return r}function Su(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?IL(Object(r),!0).forEach(function(n){Ode(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):IL(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function Ode(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function Nd(){return Nd=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},Nd.apply(this,arguments)}function Cde(e,t){if(e==null)return{};var r={},n=Object.keys(e),o,i;for(i=0;i<n.length;i++)o=n[i],!(t.indexOf(o)>=0)&&(r[o]=e[o]);return r}function Rde(e,t){if(e==null)return{};var r=Cde(e,t),n,o;if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(o=0;o<i.length;o++)n=i[o],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(r[n]=e[n])}return r}var Nde=["children","scrollableNodeProps","tag"],Ide=function(t){var r=Array.prototype.reduce.call(t,function(n,o){var i=o.name.match(/data-simplebar-(.+)/);if(i){var a=i[1].replace(/\W+(.)/g,function(s,c){return c.toUpperCase()});switch(o.value){case"true":n[a]=!0;break;case"false":n[a]=!1;break;case void 0:n[a]=!0;break;default:n[a]=o.value}}return n},{});return r},Mf=R.forwardRef(function(e,t){var r=e.children,n=e.scrollableNodeProps,o=n===void 0?{}:n,i=e.tag,a=i===void 0?"div":i,s=Rde(e,Nde),c=a,u,d=R.useRef(),f=R.useRef(),h=R.useRef(),v={},b={},g=[];return Object.keys(s).forEach(function(m){Object.prototype.hasOwnProperty.call(Rd.defaultOptions,m)?v[m]=s[m]:m.match(/data-simplebar-(.+)/)&&m!=="data-simplebar-direction"?g.push({name:m,value:s[m]}):b[m]=s[m]}),g.length&&console.warn(`simplebar-react: this way of passing options is deprecated. Pass it like normal props instead:
|
|
70
124
|
'data-simplebar-auto-hide="false"' —> 'autoHide="false"'
|
|
71
|
-
`),A.useEffect(function(){return f=i.ref||f,h.current&&(d=new gc(h.current,Tu(Tu(Tu(Tu({},XJ(y)),v),f&&{scrollableNode:f.current}),p.current&&{contentNode:p.current})),typeof t=="function"?t(d):t&&(t.current=d)),function(){d.unMount(),d=null,typeof t=="function"&&t(null)}},[]),A.createElement(c,mc({ref:h,"data-simplebar":!0},m),A.createElement("div",{className:"simplebar-wrapper"},A.createElement("div",{className:"simplebar-height-auto-observer-wrapper"},A.createElement("div",{className:"simplebar-height-auto-observer"})),A.createElement("div",{className:"simplebar-mask"},A.createElement("div",{className:"simplebar-offset"},typeof r=="function"?r({scrollableNodeRef:f,contentNodeRef:p}):A.createElement("div",mc({},i,{className:"simplebar-content-wrapper".concat(i.className?" ".concat(i.className):"")}),A.createElement("div",{className:"simplebar-content"},r)))),A.createElement("div",{className:"simplebar-placeholder"})),A.createElement("div",{className:"simplebar-track simplebar-horizontal"},A.createElement("div",{className:"simplebar-scrollbar"})),A.createElement("div",{className:"simplebar-track simplebar-vertical"},A.createElement("div",{className:"simplebar-scrollbar"})))});dl.displayName="SimpleBar";dl.propTypes={children:le.oneOfType([le.node,le.func]),scrollableNodeProps:le.object,tag:le.string};const yc=Ux,bc=Vx,Vk=e=>{switch(e){case Z.EPermissionType.DATACLASS:return C.jsx(ye.FdTableHeader,{className:"h-6 w-6"});case Z.EPermissionType.SINGLETON:return C.jsx(ye.FdSingleton,{className:"h-6 w-6"});case Z.EPermissionType.DATASTORE:return C.jsx(ye.FdModel3,{className:"h-6 w-6"});case Z.EPermissionType.ATTRIBUTE:return C.jsx(ye.FdTableColumn,{className:"h-6 w-6"});case Z.EPermissionType.METHOD:return C.jsx(ye.FdCode,{className:"h-6 w-6"});case Z.EPermissionType.SINGLETON_METHOD:return C.jsx(ye.FdFunctionSingleton,{className:"h-6 w-6"});case Z.ESubPermissionType.ENTITY_SEL_METHOD:return C.jsx(ye.FdFunctionSelection,{className:"h-6 w-6"});case Z.ESubPermissionType.ENTITY_METHOD:return C.jsx(ye.FdFunctionEntity,{className:"h-6 w-6"});case Z.ESubPermissionType.DS_METHOD:return C.jsx(ye.FdFunctionDatastore,{className:"h-6 w-6"});case Z.ESubPermissionType.DATACLASS_METHOD:return C.jsx(ye.FdFunctionDataclass,{className:"h-6 w-6"});default:return C.jsx(ye.FdTableHeader,{className:"h-6 w-6"})}},LM=({children:e})=>C.jsx("div",{className:"h-full w-full",children:C.jsx("div",{className:"flex h-full w-full flex-1 items-center justify-center bg-grey-800",children:C.jsxs("div",{className:"flex flex-col items-center justify-center space-y-4 py-4 text-grey-200",children:[C.jsx(ye.FdInfoBold,{className:"h-10 w-10"}),C.jsx("div",{className:"text-center text-sm",children:e})]})})});function ZJ(e){const{isIndeterminate:t,isChecked:r,...n}=e,i=t?"M22.5 12C22.5 17.799 17.799 22.5 12 22.5C6.20101 22.5 1.5 17.799 1.5 12C1.5 6.20101 6.20101 1.5 12 1.5C17.799 1.5 22.5 6.20101 22.5 12Z":"M0,12a1.5,1.5,0,0,0,1.5,1.5h8.75a.25.25,0,0,1,.25.25V22.5a1.5,1.5,0,0,0,3,0V13.75a.25.25,0,0,1,.25-.25H22.5a1.5,1.5,0,0,0,0-3H13.75a.25.25,0,0,1-.25-.25V1.5a1.5,1.5,0,0,0-3,0v8.75a.25.25,0,0,1-.25.25H1.5A1.5,1.5,0,0,0,0,12Z";return C.jsx(Te.BaseCheckboxIcon,{viewBox:"0 0 24 24",...n,children:C.jsx("path",{fill:t?"transparent":"currentColor",d:i,stroke:t?"currentColor":void 0,strokeWidth:t?3:void 0})})}function JJ(e){return C.jsx(Te.Checkbox,{icon:C.jsx(ZJ,{}),...e})}const Xi=({permissions:e,label:t,onToggle:r,onSelect:n,promoted:i,showIncluded:o,privileges:a,exists:u})=>{const c=e.find(d=>d.name===t);return c?C.jsxs("div",{className:"relative mx-auto flex w-fit items-center",children:[c.checked||c.from.length===0||t==="promote"?C.jsx(Te.Checkbox,{isChecked:c.checked,onChange:()=>r&&r(c),isInvalid:u===!1}):C.jsx(JJ,{isIndeterminate:o&&c.from.length>0,onChange:()=>r&&r(c),isInvalid:u===!1}),C.jsxs("div",{className:"absolute left-5 top-0 flex cursor-pointer items-center space-x-1",children:[t!=="promote"&&(c.checked&&(c.info||c.from.length>0)||!c.checked&&c.from.length>0)&&C.jsx(C.Fragment,{children:C.jsxs(yc,{openDelay:0,closeDelay:0,children:[C.jsx(bc,{children:C.jsx(ye.FdInfoBold,{className:"h-4 w-4 text-white"})}),C.jsx(jr,{container:Bt(),children:C.jsx(qr,{style:{zIndex:50},avoidCollisions:!0,side:"top",className:"max-w-xs rounded bg-primary-light py-2 text-sm font-semibold text-primary",children:C.jsxs("div",{className:"space-y-1 px-2",children:[c.from.length?C.jsxs("div",{className:"flex items-start text-s",children:[C.jsx(ye.FdBulb,{className:"mr-2 mt-0.5 h-4 w-4 flex-shrink-0"}),C.jsxs("p",{children:[C.jsx("span",{className:"mr-1",children:"Permission inherited from:"}),C.jsx("ul",{children:c.from.map(d=>C.jsx("li",{className:"cursor-pointer list-disc font-bold hover:underline",onClick:()=>n(a[d].id),children:a[d].privilege}))})]})]}):null,c.info&&C.jsxs("div",{className:"flex items-start text-s",children:[C.jsx(ye.FdInfoCircle,{className:"mr-2 mt-0.5 h-4 w-4 flex-shrink-0"})," ",c.info]})]})})})]})}),(c.checked||c.from.length>0)&&["execute"].includes(t)&&!!(i!=null&&i.length)&&C.jsxs(yc,{openDelay:0,closeDelay:0,children:[C.jsx(bc,{children:C.jsx(ye.FdCrown,{className:"h-3 w-3 text-white"})}),C.jsx(jr,{container:Bt(),children:C.jsx(qr,{style:{zIndex:50},avoidCollisions:!0,side:"top",className:"max-w-xs rounded bg-primary-light py-2 text-sm font-semibold text-primary",children:C.jsx("div",{className:"space-y-1 px-2",children:C.jsxs("div",{className:"flex items-start text-s",children:[C.jsx(ye.FdInfoCircle,{className:"mr-2 mt-0.5 h-4 w-4 flex-shrink-0"}),C.jsxs("p",{children:[C.jsxs("span",{className:"mr-1",children:["Function is promoted with:"," "]}),i==null?void 0:i.map(d=>C.jsx("li",{className:"cursor-pointer list-disc font-bold hover:underline",onClick:()=>n(a[d].id),children:a[d].privilege}))]})]})})})})]})]})]}):null},QJ=({privilegeId:e,privileges:t})=>{const r=Z.useAppSelector(Z.selectCatalogMethods),n=Z.useAppSelector(Z.selectDataclasses),i=Z.useAppSelector(Z.selectSingletons),o=t[e],a=Z.useAppDispatch(),[u,c]=A.useState([]),[d,f]=A.useState("");A.useEffect(()=>{f("")},[e]);const{isOpen:h,getMenuProps:p,getInputProps:v,getComboboxProps:m,highlightedIndex:y,getItemProps:x,selectedItem:b,openMenu:w}=to({onInputValueChange(){c([])},items:[],itemToString(_){return _?_.applyTo:""},defaultHighlightedIndex:0,stateReducer:(_,R)=>{const{changes:I,type:N}=R;switch(N){case to.stateChangeTypes.InputKeyDownArrowDown:return{...I,isOpen:!0,highlightedIndex:_.highlightedIndex<=u.length?_.highlightedIndex+1:0};case to.stateChangeTypes.InputKeyDownArrowUp:return{...I,isOpen:!0,highlightedIndex:_.highlightedIndex>=0?_.highlightedIndex-1:u.length};case to.stateChangeTypes.InputKeyDownEnter:const D=u[_.highlightedIndex];if(!D)return I;const k=Z.addPermission(e,D,t);return a(Z.updatePrivileges(k)),{...I,isOpen:!0,highlightedIndex:0}}return I}});A.useEffect(()=>{const _=o.resources.map(({resource:I,type:N,subType:D})=>({type:N,applyTo:I,subType:D})),R=Mx(d.toLowerCase(),r,Object.values(n),Object.values(i));c(R.filter(({applyTo:I,type:N,subType:D})=>!vc.find(_,{applyTo:I,type:N,subType:D})))},[d,o.resources]);const S=p({},{suppressRefError:!0}),E=A.useRef(null);return A.useEffect(()=>{h&&E.current&&E.current.focus()},[h]),C.jsxs("div",{className:"relative w-56 text-white group",...m(),children:[C.jsx("div",{...m(),children:C.jsx("input",{...v({},{suppressRefError:!0}),ref:E,type:"text",className:"block h-6 w-full rounded bg-grey-300 px-1 py-1.5 pl-2 pr-5 text-xs border-grey-500 focus:outline-none focus:ring-1 focus:ring-white focus:rounded-b-none focus:ring-inset",placeholder:"Create a permission",value:d,onChange:({target:{value:_}})=>f(_),onFocus:()=>{w()}})}),C.jsx("div",{className:"absolute inset-y-0 right-0 flex items-center px-1",children:C.jsx(ye.FdDown,{className:"h-4 w-4 cursor-pointer",onMouseDown:_=>{_.preventDefault()},onClick:()=>{w()}})}),h&&C.jsx("ul",{...S,tabIndex:0,className:"absolute max-h-80 inset-x-0 top-full overflow-auto rounded-md border border-grey-50 bg-grey-900 p-0 text-grey-50 shadow-md group-focus-within:rounded-t-none group-focus-within:border-t-0",children:u.map((_,R)=>C.jsxs("li",{className:Ve(b===_&&"font-bold","flex min-w-fit cursor-pointer items-center space-x-2 px-3 py-2 text-xs shadow-sm",{"bg-primary-hover":y===R,"font-bold":b===_}),...x({item:_,index:R}),onClick:()=>{const I=Z.addPermission(e,_,t);a(Z.updatePrivileges(I))},children:[Vk(_.type),C.jsx("span",{children:_.applyTo})]},`${_.applyTo}-${R}`))})]})};function eQ(e){const t=["datastore","singleton","dataclass","attribute","dsMethod","dataclassMethod","entityMethod","entityselMethod","singletonMethod"],r=e.reduce((n,i)=>{const[o]=i.resource.split("."),a=n.find(u=>u.prefix===o.toLowerCase());return a?(a.resources.push(i),n):[...n,{prefix:o.toLowerCase(),type:i.type,resources:[i]}]},[]);return r.sort((n,i)=>n.prefix==="ds"?-1:i.prefix==="ds"||n.prefix>i.prefix?1:-1),r.map(n=>({...n,resources:n.resources.sort((i,o)=>{const a=t.indexOf(i.type),u=t.indexOf(o.type);return a!==u?a-u:i.resource.toLowerCase()>o.resource.toLowerCase()?1:-1})})).reduce((n,i)=>[...n,...i.resources],[])}const tQ=({selectedPrivilege:e,onSelect:t,showIncluded:r,privileges:n})=>{const[i,o]=A.useState(null),[a,u]=A.useState(null),{styles:c,attributes:d}=wc(i,a,{modifiers:[{name:"offset",options:{offset:[0,10]}}]}),[f,h]=A.useState([]),[p,v]=A.useState(""),m=Z.useAppDispatch(),{id:y}=e,x=A.useMemo(()=>Z.getInheritedResources(y,n),[y,n[y].includes,n[y].resources]),b=A.useMemo(()=>Z.getPromotions(y,n),[n[y]]);function w(L){h(j=>j.some(T=>L.includes(T))?j.filter(T=>!L.includes(T)):[...j,...L])}const S=async L=>{const{confirmed:j}=await m(Z.openModal({title:"Delete Privilege",type:Te.ModalType.CONFIRM,color:Te.ModalColor.DANGER,message:"Are you sure you want to remove this Privilege?",icon:"FdWarningDanger"})).unwrap();if(j){const T=Z.removePermission(e.id,L,n);m(Z.updatePrivileges(T))}},E=async()=>{const{confirmed:L}=await m(Z.openModal({title:"Reset Permissions",type:Te.ModalType.CONFIRM,color:Te.ModalColor.DANGER,message:"Are you sure you want to reset permissions for this Privilege?",icon:"FdWarningDanger"})).unwrap();if(L){const j=Z.resetResources(e.id,n);m(Z.updatePrivileges(j))}},R=x.filter(L=>f.length===0?!0:f.includes(L.type)).filter(({resource:L})=>p?new RegExp(vc.escapeRegExp(p),"i").test(L):!0),I=eQ(R),N=I.filter(L=>{const j=L.permissions.every(T=>!T.checked)&&L.permissions.some(T=>T.from.length>0);return r||!j}),D=(L,j)=>{const T=Z.togglePermission(e.id,L,j,n);m(Z.updatePrivileges(T))},k=A.useMemo(()=>N.some(L=>L.exists===!1),[N]),B=async()=>{const{confirmed:L}=await m(Z.openModal({title:"Delete Privilege",type:Te.ModalType.CONFIRM,color:Te.ModalColor.DANGER,message:"Are you sure you want to remove these permissions?",views:{tips:[{type:"warning",message:"This action will remove all permissions that don't exist in the catalog for all privileges"}]},icon:"FdWarningDanger"})).unwrap(),j=Object.entries(n).map(([T,F])=>{const $=F.resources.filter(W=>!W.exists);return{[T]:$.map(W=>({applyTo:W.resource,type:W.type}))}}).reduce((T,F)=>({...T,...F}),{});if(L){const T=Z.removeMultiplePermissions(j,n);m(Z.updatePrivileges(T))}};return C.jsxs(dl,{className:"z-20 h-full flex-1 overflow-auto bg-grey-800 p-[15px] pt-0",style:{maxHeight:"calc(100vh - 5.5rem - 85px - 20px)"},children:[C.jsxs("table",{className:"relative h-full w-full",children:[C.jsx("thead",{className:"sticky top-0 z-20 bg-grey-800",children:C.jsxs("tr",{className:"border-b border-grey-100",children:[C.jsx("td",{className:"py-2",children:C.jsxs("div",{className:"flex items-center space-x-2",children:[C.jsxs("div",{className:"relative w-56 text-white",children:[C.jsx("div",{className:"absolute inset-y-0 left-0 flex items-center px-1",children:C.jsx(ye.FdSearch,{className:"h-4 w-4 text-gray-400"})}),C.jsx("div",{className:"absolute inset-y-0 right-0 flex items-center px-2",children:C.jsx(wr.Popover,{className:"flex items-center",children:({open:L})=>C.jsxs(C.Fragment,{children:[C.jsx(wr.Popover.Button,{ref:o,children:C.jsx(ye.FdAdjust,{className:"h-4 w-4"})}),L&&C.jsx(el,{children:C.jsxs(wr.Popover.Panel,{ref:u,style:c.popper,...d.popper,className:"z-50 rounded-md border border-grey-50 bg-grey-900 px-4 py-2.5 text-xs text-grey-50",static:!0,children:[C.jsx("h5",{className:"mb-2 text-sm",children:"Filter"}),C.jsxs("div",{className:"space-y-2 text-s",children:[C.jsx("div",{className:"flex items-center",children:C.jsx(Te.Checkbox,{isChecked:f.includes("datastore"),onChange:()=>{w(["datastore"])},label:"Datastore"})}),C.jsx("div",{className:"flex items-center",children:C.jsx(Te.Checkbox,{isChecked:f.includes("dataclass"),onChange:()=>{w(["dataclass"])},label:"Dataclass"})}),C.jsx("div",{className:"flex items-center",children:C.jsx(Te.Checkbox,{isChecked:f.includes("singleton"),onChange:()=>{w(["singleton"])},label:"Singleton"})}),C.jsx("div",{className:"flex items-center",children:C.jsx(Te.Checkbox,{isChecked:f.some(j=>["method","singletonMethod","dsMethod","dataclassMethod","entityMethod","entityselMethod"].includes(j)),onChange:()=>{w(["method","singletonMethod","dsMethod","dataclassMethod","entityMethod","entityselMethod"])},label:"Functions"})}),C.jsx("div",{className:"flex items-center",children:C.jsx(Te.Checkbox,{isChecked:f.includes("attribute"),onChange:()=>{w(["attribute"])},label:"Attribute"})})]})]})})]})})}),C.jsx("input",{type:"text",className:"block h-6 w-full rounded bg-grey-300 px-1 py-1.5 pl-6 text-xs focus:outline-none",placeholder:"Search available permissions",value:p,onChange:L=>{v(L.target.value)}})]}),C.jsx(QJ,{privilegeId:y,privileges:n}),C.jsx("div",{children:C.jsxs(yc,{openDelay:0,closeDelay:0,children:[C.jsx(bc,{children:C.jsx("button",{className:"flex h-6 items-center space-x-1 rounded-md px-2 text-sm text-grey-50 hover:bg-primary-hover",onClick:E,children:C.jsx(ye.FdReload,{})})}),C.jsx(jr,{container:Bt(),children:C.jsxs(qr,{style:{zIndex:50},avoidCollisions:!0,side:"top",className:"mb-1 flex max-w-xs items-center gap-x-1 rounded bg-primary-light px-2 py-2 text-s font-semibold text-primary-darker",children:[C.jsx(ye.FdBulb,{className:"m-0.5 h-4 w-4 flex-shrink-0"}),C.jsx("p",{children:"Resetting the privilege will remove all configured ressources"})]})})]})}),C.jsxs(yc,{openDelay:0,closeDelay:0,children:[C.jsx(bc,{children:C.jsx("button",{className:Ve("flex h-6 items-center space-x-1 rounded-md px-2 text-sm text-grey-50 hover:bg-primary-hover disabled:opacity-50 disabled:hover:bg-primary-dark"),onClick:B,disabled:!k,children:C.jsx(ye.FdClean,{className:"h-4 w-4"})})}),C.jsx(jr,{container:Bt(),children:C.jsxs(qr,{style:{zIndex:50},avoidCollisions:!0,side:"top",className:"mb-1 flex max-w-xs items-center gap-x-1 rounded bg-primary-light px-2 py-2 text-s font-semibold text-primary-darker",children:[C.jsx(ye.FdBulb,{className:"m-0.5 h-4 w-4 flex-shrink-0"}),C.jsx("p",{children:"Delete all the non existing resources from privileges"})]})})]})]})}),C.jsx("td",{className:"bg-grey-800 px-4 py-2 text-center text-[12px] text-white",children:"Read"}),C.jsx("td",{className:"bg-grey-800 px-4 py-2 text-center text-[12px] text-white",children:"Create"}),C.jsx("td",{className:"bg-grey-800 px-4 py-2 text-center text-[12px] text-white",children:"Update"}),C.jsx("td",{className:"bg-grey-800 px-4 py-2 text-center text-[12px] text-white",children:"Delete"}),C.jsx("td",{className:"bg-grey-800 px-4 py-2 text-center text-[12px] text-white",children:"Execute"}),C.jsx("td",{className:"bg-grey-800 px-4 py-2 text-center text-[12px] text-white",children:"Promote"})]})}),N.length?C.jsx("tbody",{children:N.map((L,j)=>{const T=L.permissions.some(F=>F.from.length>0);return C.jsxs("tr",{className:Ve("group even:bg-grey-600",{"opacity-60":L.exists===!1}),children:[C.jsxs("td",{className:Ve("group flex items-center gap-3 py-2 text-xs group-hover:rounded-l group-hover:bg-grey-300",L.exists===!1?"text-negative-400":"text-white",{"border-b-[0.5px] border-grey-300":!1}),children:[Vk(L.type),L.resource,C.jsx(Te.Tooltip,{placement:"top",label:"Remove Permission",isDisabled:T,container:Bt(),children:C.jsx("button",{onClick:()=>{T?Te.toastSubject.next({kind:"info",markdown:!0,message:`<div className="flex gap-x-3"><h3 className="font-bold">Info:</h3><p className="font-normal">Inherited permissions can't be removed</p></div>`,customIcon:ye.FdInfoBold}):S({applyTo:L.resource,type:L.type})},className:Ve("flex flex-shrink-0 items-center justify-center rounded p-1 opacity-0 group-hover:opacity-100",T?"hover:bg-grey-300 group-hover:opacity-70":"hover:bg-primary-hover"),children:C.jsx(ye.FdPlus,{className:"h-4 w-4 rotate-45 transform text-white"})})})]}),C.jsx("td",{className:"py-2 text-center group-hover:bg-grey-300",children:C.jsx(Xi,{permissions:L.permissions,showIncluded:r,label:"read",onToggle:F=>D(L,F),onSelect:t,privileges:n,exists:L.exists})}),C.jsx("td",{className:"py-2 text-center group-hover:bg-grey-300",children:C.jsx(Xi,{permissions:L.permissions,showIncluded:r,label:"create",onToggle:F=>D(L,F),onSelect:t,privileges:n,exists:L.exists})}),C.jsx("td",{className:"py-2 text-center group-hover:bg-grey-300",children:C.jsx(Xi,{permissions:L.permissions,showIncluded:r,label:"update",onToggle:F=>D(L,F),onSelect:t,privileges:n,exists:L.exists})}),C.jsx("td",{className:"py-2 text-center group-hover:bg-grey-300",children:C.jsx(Xi,{permissions:L.permissions,showIncluded:r,label:"drop",onToggle:F=>D(L,F),onSelect:t,privileges:n,exists:L.exists})}),C.jsx("td",{className:"py-2 text-center group-hover:bg-grey-300",children:C.jsx(Xi,{promoted:b[L.resource],permissions:L.permissions,showIncluded:r,label:"execute",onToggle:F=>D(L,F),onSelect:t,privileges:n,exists:L.exists})}),C.jsx("td",{className:"py-2 text-center group-hover:rounded-r group-hover:bg-grey-300 ",children:C.jsx(Xi,{permissions:L.permissions,showIncluded:r,label:"promote",onToggle:F=>D(L,F),onSelect:t,privileges:n,exists:L.exists})})]},j)})}):null]}),!I.length&&p?C.jsx(LM,{children:"The Permission you're looking for can't be found "}):null,!I.length&&!p?C.jsxs(LM,{children:["This Privilege has no Permissions configured yet ",C.jsx("br",{}),'Add a new permission by using the "Create a permission" input above']}):null]})},rQ=({onCreate:e})=>{const t=Z.useAppSelector(Z.selectPrivileges),r=Z.useAppDispatch(),[n,i]=A.useState(null),[o,a]=A.useState(null),[u,c]=A.useState(""),[d,f]=A.useState(null),{styles:h,attributes:p}=wc(n,o,{modifiers:[{name:"offset",options:{offset:[-10,10]}}],placement:"right-start"});return A.useEffect(()=>{c(""),f(null)},[o]),C.jsx(wr.Popover,{children:({open:v,close:m})=>C.jsxs(C.Fragment,{children:[C.jsx(wr.Popover.Button,{className:"rounded p-1 hover:bg-primary-hover","data-cy":"New-priv-btn",ref:i,children:C.jsx("span",{children:C.jsx(ye.FdPlus,{className:"h-4 w-4 text-white"})})}),v&&C.jsx(el,{children:C.jsxs(wr.Popover.Panel,{ref:a,style:h.popper,...p.popper,"data-cy":"New-priv-pop-up",className:"z-50 min-w-[256px] rounded border border-grey-50 bg-grey-900 px-4 py-2 text-xs text-grey-50 shadow-md",static:!0,children:[C.jsx("h5",{className:"mb-2 text-xs font-semibold",children:"Create New Privilege"}),C.jsxs("div",{className:"mt-2",children:[C.jsxs("label",{className:"flex items-center space-x-4",children:[C.jsx("span",{className:"text-grey-100",children:"Name"}),C.jsx("input",{autoFocus:!0,value:u,onChange:y=>c(y.target.value),onKeyDown:y=>{if(y.key==="Enter"){f(null);try{const x=Z.create(u,t),b=r(Z.updatePrivileges(x)),w=Object.values(b.payload).find(S=>S.privilege===u);w&&(e(w),m())}catch(x){f(x.message)}}},type:"text",className:Ve("w-full rounded border bg-grey-300 p-1 focus:outline-none",{"border-grey-100":!d,"border-red-400":d})})]}),d&&C.jsx("p",{className:"mt-1 text-xs text-red-400",children:d})]}),C.jsxs("div",{className:"mt-4 flex items-center justify-center space-x-2",children:[C.jsx("button",{className:"rounded border border-primary-dark bg-primary-dark px-4 py-1 hover:border-primary-hover hover:bg-primary-hover",onClick:()=>{f(null);try{const y=Z.create(u,t),x=r(Z.updatePrivileges(y)),b=Object.values(x.payload).find(w=>w.privilege===u);b&&e(b),m()}catch(y){f(y.message)}},children:"Create"}),C.jsx("button",{className:"rounded border border-grey-100 px-4 py-1 text-grey-100 hover:bg-white hover:text-primary-dark",onClick:()=>m(),children:"Cancel"})]})]})})]})})},nQ=()=>{const e=Z.useAppSelector(Z.selectCatalog),t=Z.useAppSelector(Z.selectPrivileges),r=A.useMemo(()=>{if(e===null)return t;const c=Dq(t,Object.values((e==null?void 0:e.dataClasses)??{}));return jq(c,e)},[t,e]),[n,i]=A.useState(null),o=A.useMemo(()=>Object.keys(r),[r]);A.useEffect(()=>{n&&r[n.id]||!o.length||i(r[o[0]])},[r]),A.useEffect(()=>{o.length<2&&u(!0)},[o.length]);const[a,u]=A.useState(!0);return C.jsxs("div",{className:"flex flex-1 h-full",children:[C.jsxs("div",{className:"flex h-full w-[356px] flex-col bg-grey-800",children:[C.jsxs("div",{className:"flex flex-shrink-0 items-center justify-between bg-grey-800 px-3.5 py-[10px]",children:[C.jsxs("div",{className:"flex items-center space-x-1 text-[#DDE1E6]",children:[C.jsx("span",{children:C.jsx(ye.FdGroup,{className:"h-[14px] w-[14px]"})}),C.jsx("span",{className:"text-[11px] font-semibold",children:"Privileges"})]}),C.jsx(rQ,{onCreate:c=>{i(c)}})]}),C.jsx(xX,{privileges:r,selectedPrivilege:n,selectPrivilege:c=>{i(c)}})]}),n&&r[n.id]?C.jsxs("div",{className:"privileges-container relative flex flex-1 flex-col overflow-x-auto border-l-[0.5px] border-grey-900 bg-grey-800",children:[C.jsxs("div",{className:"mb-1 flex h-full w-full flex-col items-stretch",children:[n.privilege!=="guest"?C.jsx(m9,{privileges:r,selectedPrivilege:n,onSelect:c=>i(t[c]),setShowIncluded:u,showIncluded:a}):null,C.jsx(tQ,{privileges:r,selectedPrivilege:n,onSelect:c=>i(t[c]),showIncluded:a})]}),C.jsx(iQ,{privileges:r,selectedPrivilege:n,setSelectedPrivilege:i})]}):C.jsx(bD,{tab:"Privilege"})]})},iQ=({privileges:e,selectedPrivilege:t,setSelectedPrivilege:r})=>{const[n,i]=A.useState(!1);return C.jsx(Te.Panel,{path:Te.ROLES_TAB_PATH,isOpen:n,onOpen:()=>i(!0),onClose:()=>i(!1),children:C.jsx("div",{className:"h-full w-full px-3 pb-3",children:C.jsx("div",{className:"h-full w-full rounded bg-grey-900",children:C.jsx(p9,{dict:e,data:Z.getGraphData(t.id,e),onSelect:o=>r(e[o])})})})})};var bb={},ia={},Au={},BM;function Wk(){if(BM)return Au;BM=1,Object.defineProperty(Au,"__esModule",{value:!0}),Au.default=r;let e;const t=new Uint8Array(16);function r(){if(!e&&(e=typeof crypto<"u"&&crypto.getRandomValues&&crypto.getRandomValues.bind(crypto),!e))throw new Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");return e(t)}return Au}var Zi={},oa={},aa={},FM;function oQ(){if(FM)return aa;FM=1,Object.defineProperty(aa,"__esModule",{value:!0}),aa.default=void 0;var e=/^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000)$/i;return aa.default=e,aa}var $M;function hl(){if($M)return oa;$M=1,Object.defineProperty(oa,"__esModule",{value:!0}),oa.default=void 0;var e=t(oQ());function t(i){return i&&i.__esModule?i:{default:i}}function r(i){return typeof i=="string"&&e.default.test(i)}var n=r;return oa.default=n,oa}var zM;function pl(){if(zM)return Zi;zM=1,Object.defineProperty(Zi,"__esModule",{value:!0}),Zi.default=void 0,Zi.unsafeStringify=n;var e=t(hl());function t(a){return a&&a.__esModule?a:{default:a}}const r=[];for(let a=0;a<256;++a)r.push((a+256).toString(16).slice(1));function n(a,u=0){return r[a[u+0]]+r[a[u+1]]+r[a[u+2]]+r[a[u+3]]+"-"+r[a[u+4]]+r[a[u+5]]+"-"+r[a[u+6]]+r[a[u+7]]+"-"+r[a[u+8]]+r[a[u+9]]+"-"+r[a[u+10]]+r[a[u+11]]+r[a[u+12]]+r[a[u+13]]+r[a[u+14]]+r[a[u+15]]}function i(a,u=0){const c=n(a,u);if(!(0,e.default)(c))throw TypeError("Stringified UUID is invalid");return c}var o=i;return Zi.default=o,Zi}var HM;function aQ(){if(HM)return ia;HM=1,Object.defineProperty(ia,"__esModule",{value:!0}),ia.default=void 0;var e=r(Wk()),t=pl();function r(d){return d&&d.__esModule?d:{default:d}}let n,i,o=0,a=0;function u(d,f,h){let p=f&&h||0;const v=f||new Array(16);d=d||{};let m=d.node||n,y=d.clockseq!==void 0?d.clockseq:i;if(m==null||y==null){const _=d.random||(d.rng||e.default)();m==null&&(m=n=[_[0]|1,_[1],_[2],_[3],_[4],_[5]]),y==null&&(y=i=(_[6]<<8|_[7])&16383)}let x=d.msecs!==void 0?d.msecs:Date.now(),b=d.nsecs!==void 0?d.nsecs:a+1;const w=x-o+(b-a)/1e4;if(w<0&&d.clockseq===void 0&&(y=y+1&16383),(w<0||x>o)&&d.nsecs===void 0&&(b=0),b>=1e4)throw new Error("uuid.v1(): Can't create more than 10M uuids/sec");o=x,a=b,i=y,x+=122192928e5;const S=((x&268435455)*1e4+b)%4294967296;v[p++]=S>>>24&255,v[p++]=S>>>16&255,v[p++]=S>>>8&255,v[p++]=S&255;const E=x/4294967296*1e4&268435455;v[p++]=E>>>8&255,v[p++]=E&255,v[p++]=E>>>24&15|16,v[p++]=E>>>16&255,v[p++]=y>>>8|128,v[p++]=y&255;for(let _=0;_<6;++_)v[p+_]=m[_];return f||(0,t.unsafeStringify)(v)}var c=u;return ia.default=c,ia}var sa={},Ln={},ua={},UM;function Gk(){if(UM)return ua;UM=1,Object.defineProperty(ua,"__esModule",{value:!0}),ua.default=void 0;var e=t(hl());function t(i){return i&&i.__esModule?i:{default:i}}function r(i){if(!(0,e.default)(i))throw TypeError("Invalid UUID");let o;const a=new Uint8Array(16);return a[0]=(o=parseInt(i.slice(0,8),16))>>>24,a[1]=o>>>16&255,a[2]=o>>>8&255,a[3]=o&255,a[4]=(o=parseInt(i.slice(9,13),16))>>>8,a[5]=o&255,a[6]=(o=parseInt(i.slice(14,18),16))>>>8,a[7]=o&255,a[8]=(o=parseInt(i.slice(19,23),16))>>>8,a[9]=o&255,a[10]=(o=parseInt(i.slice(24,36),16))/1099511627776&255,a[11]=o/4294967296&255,a[12]=o>>>24&255,a[13]=o>>>16&255,a[14]=o>>>8&255,a[15]=o&255,a}var n=r;return ua.default=n,ua}var VM;function Kk(){if(VM)return Ln;VM=1,Object.defineProperty(Ln,"__esModule",{value:!0}),Ln.URL=Ln.DNS=void 0,Ln.default=a;var e=pl(),t=r(Gk());function r(u){return u&&u.__esModule?u:{default:u}}function n(u){u=unescape(encodeURIComponent(u));const c=[];for(let d=0;d<u.length;++d)c.push(u.charCodeAt(d));return c}const i="6ba7b810-9dad-11d1-80b4-00c04fd430c8";Ln.DNS=i;const o="6ba7b811-9dad-11d1-80b4-00c04fd430c8";Ln.URL=o;function a(u,c,d){function f(h,p,v,m){var y;if(typeof h=="string"&&(h=n(h)),typeof p=="string"&&(p=(0,t.default)(p)),((y=p)===null||y===void 0?void 0:y.length)!==16)throw TypeError("Namespace must be array-like (16 iterable integer values, 0-255)");let x=new Uint8Array(16+h.length);if(x.set(p),x.set(h,p.length),x=d(x),x[6]=x[6]&15|c,x[8]=x[8]&63|128,v){m=m||0;for(let b=0;b<16;++b)v[m+b]=x[b];return v}return(0,e.unsafeStringify)(x)}try{f.name=u}catch{}return f.DNS=i,f.URL=o,f}return Ln}var ca={},WM;function sQ(){if(WM)return ca;WM=1,Object.defineProperty(ca,"__esModule",{value:!0}),ca.default=void 0;function e(v){if(typeof v=="string"){const m=unescape(encodeURIComponent(v));v=new Uint8Array(m.length);for(let y=0;y<m.length;++y)v[y]=m.charCodeAt(y)}return t(n(i(v),v.length*8))}function t(v){const m=[],y=v.length*32,x="0123456789abcdef";for(let b=0;b<y;b+=8){const w=v[b>>5]>>>b%32&255,S=parseInt(x.charAt(w>>>4&15)+x.charAt(w&15),16);m.push(S)}return m}function r(v){return(v+64>>>9<<4)+14+1}function n(v,m){v[m>>5]|=128<<m%32,v[r(m)-1]=m;let y=1732584193,x=-271733879,b=-1732584194,w=271733878;for(let S=0;S<v.length;S+=16){const E=y,_=x,R=b,I=w;y=c(y,x,b,w,v[S],7,-680876936),w=c(w,y,x,b,v[S+1],12,-389564586),b=c(b,w,y,x,v[S+2],17,606105819),x=c(x,b,w,y,v[S+3],22,-1044525330),y=c(y,x,b,w,v[S+4],7,-176418897),w=c(w,y,x,b,v[S+5],12,1200080426),b=c(b,w,y,x,v[S+6],17,-1473231341),x=c(x,b,w,y,v[S+7],22,-45705983),y=c(y,x,b,w,v[S+8],7,1770035416),w=c(w,y,x,b,v[S+9],12,-1958414417),b=c(b,w,y,x,v[S+10],17,-42063),x=c(x,b,w,y,v[S+11],22,-1990404162),y=c(y,x,b,w,v[S+12],7,1804603682),w=c(w,y,x,b,v[S+13],12,-40341101),b=c(b,w,y,x,v[S+14],17,-1502002290),x=c(x,b,w,y,v[S+15],22,1236535329),y=d(y,x,b,w,v[S+1],5,-165796510),w=d(w,y,x,b,v[S+6],9,-1069501632),b=d(b,w,y,x,v[S+11],14,643717713),x=d(x,b,w,y,v[S],20,-373897302),y=d(y,x,b,w,v[S+5],5,-701558691),w=d(w,y,x,b,v[S+10],9,38016083),b=d(b,w,y,x,v[S+15],14,-660478335),x=d(x,b,w,y,v[S+4],20,-405537848),y=d(y,x,b,w,v[S+9],5,568446438),w=d(w,y,x,b,v[S+14],9,-1019803690),b=d(b,w,y,x,v[S+3],14,-187363961),x=d(x,b,w,y,v[S+8],20,1163531501),y=d(y,x,b,w,v[S+13],5,-1444681467),w=d(w,y,x,b,v[S+2],9,-51403784),b=d(b,w,y,x,v[S+7],14,1735328473),x=d(x,b,w,y,v[S+12],20,-1926607734),y=f(y,x,b,w,v[S+5],4,-378558),w=f(w,y,x,b,v[S+8],11,-2022574463),b=f(b,w,y,x,v[S+11],16,1839030562),x=f(x,b,w,y,v[S+14],23,-35309556),y=f(y,x,b,w,v[S+1],4,-1530992060),w=f(w,y,x,b,v[S+4],11,1272893353),b=f(b,w,y,x,v[S+7],16,-155497632),x=f(x,b,w,y,v[S+10],23,-1094730640),y=f(y,x,b,w,v[S+13],4,681279174),w=f(w,y,x,b,v[S],11,-358537222),b=f(b,w,y,x,v[S+3],16,-722521979),x=f(x,b,w,y,v[S+6],23,76029189),y=f(y,x,b,w,v[S+9],4,-640364487),w=f(w,y,x,b,v[S+12],11,-421815835),b=f(b,w,y,x,v[S+15],16,530742520),x=f(x,b,w,y,v[S+2],23,-995338651),y=h(y,x,b,w,v[S],6,-198630844),w=h(w,y,x,b,v[S+7],10,1126891415),b=h(b,w,y,x,v[S+14],15,-1416354905),x=h(x,b,w,y,v[S+5],21,-57434055),y=h(y,x,b,w,v[S+12],6,1700485571),w=h(w,y,x,b,v[S+3],10,-1894986606),b=h(b,w,y,x,v[S+10],15,-1051523),x=h(x,b,w,y,v[S+1],21,-2054922799),y=h(y,x,b,w,v[S+8],6,1873313359),w=h(w,y,x,b,v[S+15],10,-30611744),b=h(b,w,y,x,v[S+6],15,-1560198380),x=h(x,b,w,y,v[S+13],21,1309151649),y=h(y,x,b,w,v[S+4],6,-145523070),w=h(w,y,x,b,v[S+11],10,-1120210379),b=h(b,w,y,x,v[S+2],15,718787259),x=h(x,b,w,y,v[S+9],21,-343485551),y=o(y,E),x=o(x,_),b=o(b,R),w=o(w,I)}return[y,x,b,w]}function i(v){if(v.length===0)return[];const m=v.length*8,y=new Uint32Array(r(m));for(let x=0;x<m;x+=8)y[x>>5]|=(v[x/8]&255)<<x%32;return y}function o(v,m){const y=(v&65535)+(m&65535);return(v>>16)+(m>>16)+(y>>16)<<16|y&65535}function a(v,m){return v<<m|v>>>32-m}function u(v,m,y,x,b,w){return o(a(o(o(m,v),o(x,w)),b),y)}function c(v,m,y,x,b,w,S){return u(m&y|~m&x,v,m,b,w,S)}function d(v,m,y,x,b,w,S){return u(m&x|y&~x,v,m,b,w,S)}function f(v,m,y,x,b,w,S){return u(m^y^x,v,m,b,w,S)}function h(v,m,y,x,b,w,S){return u(y^(m|~x),v,m,b,w,S)}var p=e;return ca.default=p,ca}var GM;function uQ(){if(GM)return sa;GM=1,Object.defineProperty(sa,"__esModule",{value:!0}),sa.default=void 0;var e=r(Kk()),t=r(sQ());function r(o){return o&&o.__esModule?o:{default:o}}var i=(0,e.default)("v3",48,t.default);return sa.default=i,sa}var la={},fa={},KM;function cQ(){if(KM)return fa;KM=1,Object.defineProperty(fa,"__esModule",{value:!0}),fa.default=void 0;var t={randomUUID:typeof crypto<"u"&&crypto.randomUUID&&crypto.randomUUID.bind(crypto)};return fa.default=t,fa}var YM;function lQ(){if(YM)return la;YM=1,Object.defineProperty(la,"__esModule",{value:!0}),la.default=void 0;var e=n(cQ()),t=n(Wk()),r=pl();function n(a){return a&&a.__esModule?a:{default:a}}function i(a,u,c){if(e.default.randomUUID&&!u&&!a)return e.default.randomUUID();a=a||{};const d=a.random||(a.rng||t.default)();if(d[6]=d[6]&15|64,d[8]=d[8]&63|128,u){c=c||0;for(let f=0;f<16;++f)u[c+f]=d[f];return u}return(0,r.unsafeStringify)(d)}var o=i;return la.default=o,la}var da={},ha={},XM;function fQ(){if(XM)return ha;XM=1,Object.defineProperty(ha,"__esModule",{value:!0}),ha.default=void 0;function e(i,o,a,u){switch(i){case 0:return o&a^~o&u;case 1:return o^a^u;case 2:return o&a^o&u^a&u;case 3:return o^a^u}}function t(i,o){return i<<o|i>>>32-o}function r(i){const o=[1518500249,1859775393,2400959708,3395469782],a=[1732584193,4023233417,2562383102,271733878,3285377520];if(typeof i=="string"){const f=unescape(encodeURIComponent(i));i=[];for(let h=0;h<f.length;++h)i.push(f.charCodeAt(h))}else Array.isArray(i)||(i=Array.prototype.slice.call(i));i.push(128);const u=i.length/4+2,c=Math.ceil(u/16),d=new Array(c);for(let f=0;f<c;++f){const h=new Uint32Array(16);for(let p=0;p<16;++p)h[p]=i[f*64+p*4]<<24|i[f*64+p*4+1]<<16|i[f*64+p*4+2]<<8|i[f*64+p*4+3];d[f]=h}d[c-1][14]=(i.length-1)*8/Math.pow(2,32),d[c-1][14]=Math.floor(d[c-1][14]),d[c-1][15]=(i.length-1)*8&4294967295;for(let f=0;f<c;++f){const h=new Uint32Array(80);for(let b=0;b<16;++b)h[b]=d[f][b];for(let b=16;b<80;++b)h[b]=t(h[b-3]^h[b-8]^h[b-14]^h[b-16],1);let p=a[0],v=a[1],m=a[2],y=a[3],x=a[4];for(let b=0;b<80;++b){const w=Math.floor(b/20),S=t(p,5)+e(w,v,m,y)+x+o[w]+h[b]>>>0;x=y,y=m,m=t(v,30)>>>0,v=p,p=S}a[0]=a[0]+p>>>0,a[1]=a[1]+v>>>0,a[2]=a[2]+m>>>0,a[3]=a[3]+y>>>0,a[4]=a[4]+x>>>0}return[a[0]>>24&255,a[0]>>16&255,a[0]>>8&255,a[0]&255,a[1]>>24&255,a[1]>>16&255,a[1]>>8&255,a[1]&255,a[2]>>24&255,a[2]>>16&255,a[2]>>8&255,a[2]&255,a[3]>>24&255,a[3]>>16&255,a[3]>>8&255,a[3]&255,a[4]>>24&255,a[4]>>16&255,a[4]>>8&255,a[4]&255]}var n=r;return ha.default=n,ha}var ZM;function dQ(){if(ZM)return da;ZM=1,Object.defineProperty(da,"__esModule",{value:!0}),da.default=void 0;var e=r(Kk()),t=r(fQ());function r(o){return o&&o.__esModule?o:{default:o}}var i=(0,e.default)("v5",80,t.default);return da.default=i,da}var pa={},JM;function hQ(){if(JM)return pa;JM=1,Object.defineProperty(pa,"__esModule",{value:!0}),pa.default=void 0;var e="00000000-0000-0000-0000-000000000000";return pa.default=e,pa}var va={},QM;function pQ(){if(QM)return va;QM=1,Object.defineProperty(va,"__esModule",{value:!0}),va.default=void 0;var e=t(hl());function t(i){return i&&i.__esModule?i:{default:i}}function r(i){if(!(0,e.default)(i))throw TypeError("Invalid UUID");return parseInt(i.slice(14,15),16)}var n=r;return va.default=n,va}var eD;function vQ(){return eD||(eD=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),Object.defineProperty(e,"NIL",{enumerable:!0,get:function(){return o.default}}),Object.defineProperty(e,"parse",{enumerable:!0,get:function(){return d.default}}),Object.defineProperty(e,"stringify",{enumerable:!0,get:function(){return c.default}}),Object.defineProperty(e,"v1",{enumerable:!0,get:function(){return t.default}}),Object.defineProperty(e,"v3",{enumerable:!0,get:function(){return r.default}}),Object.defineProperty(e,"v4",{enumerable:!0,get:function(){return n.default}}),Object.defineProperty(e,"v5",{enumerable:!0,get:function(){return i.default}}),Object.defineProperty(e,"validate",{enumerable:!0,get:function(){return u.default}}),Object.defineProperty(e,"version",{enumerable:!0,get:function(){return a.default}});var t=f(aQ()),r=f(uQ()),n=f(lQ()),i=f(dQ()),o=f(hQ()),a=f(pQ()),u=f(hl()),c=f(pl()),d=f(Gk());function f(h){return h&&h.__esModule?h:{default:h}}})(bb)),bb}var xb,tD;function gQ(){if(tD)return xb;tD=1;function e(t,r){if(!t||!r||!t.length||!r.length)throw new Error("Bad alphabet");this.srcAlphabet=t,this.dstAlphabet=r}return e.prototype.convert=function(t){var r,n,i,o={},a=this.srcAlphabet.length,u=this.dstAlphabet.length,c=t.length,d=typeof t=="string"?"":[];if(!this.isValid(t))throw new Error('Number "'+t+'" contains of non-alphabetic digits ('+this.srcAlphabet+")");if(this.srcAlphabet===this.dstAlphabet)return t;for(r=0;r<c;r++)o[r]=this.srcAlphabet.indexOf(t[r]);do{for(n=0,i=0,r=0;r<c;r++)n=n*a+o[r],n>=u?(o[i++]=parseInt(n/u,10),n=n%u):i>0&&(o[i++]=0);c=i,d=this.dstAlphabet.slice(n,n+1).concat(d)}while(i!==0);return d},e.prototype.isValid=function(t){for(var r=0;r<t.length;++r)if(this.srcAlphabet.indexOf(t[r])===-1)return!1;return!0},xb=e,xb}var wb,rD;function mQ(){if(rD)return wb;rD=1;var e=gQ();function t(r,n){var i=new e(r,n);return function(o){return i.convert(o)}}return t.BIN="01",t.OCT="01234567",t.DEC="0123456789",t.HEX="0123456789abcdef",wb=t,wb}var _b,nD;function yQ(){if(nD)return _b;nD=1;const{v4:e,validate:t}=vQ(),r=mQ(),n={cookieBase90:"0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ!#$%&'()*+-./:<=>?@[]^_`{|}~",flickrBase58:"123456789abcdefghijkmnopqrstuvwxyzABCDEFGHJKLMNPQRSTUVWXYZ",uuid25Base36:"0123456789abcdefghijklmnopqrstuvwxyz"},i={consistentLength:!0};let o;const a=(d,f,h)=>{const p=f(d.toLowerCase().replace(/-/g,""));return!h||!h.consistentLength?p:p.padStart(h.shortIdLength,h.paddingChar)},u=(d,f)=>{const p=f(d).padStart(32,"0").match(/(\w{8})(\w{4})(\w{4})(\w{4})(\w{12})/);return[p[1],p[2],p[3],p[4],p[5]].join("-")},c=d=>Math.ceil(Math.log(2**128)/Math.log(d));return _b=(()=>{const d=(f,h)=>{const p=f||n.flickrBase58,v={...i,...h};if([...new Set(Array.from(p))].length!==p.length)throw new Error("The provided Alphabet has duplicate characters resulting in unreliable results");const m=c(p.length),y={shortIdLength:m,consistentLength:v.consistentLength,paddingChar:p[0]},x=r(r.HEX,p),b=r(p,r.HEX),w=()=>a(e(),x,y),E={alphabet:p,fromUUID:_=>a(_,x,y),maxLength:m,generate:w,new:w,toUUID:_=>u(_,b),uuid:e,validate:(_,R=!1)=>{if(!_||typeof _!="string")return!1;const I=v.consistentLength?_.length===m:_.length<=m,N=_.split("").every(D=>p.includes(D));return R===!1?I&&N:I&&N&&t(u(_,b))}};return Object.freeze(E),E};return d.constants=n,d.uuid=e,d.generate=()=>(o||(o=d(n.flickrBase58).generate),o()),d})(),_b}var bQ=yQ();const xQ=({role:e})=>{var R;const[t,r]=A.useState(e),[n,i]=A.useState(e.role),[o,a]=A.useState(null),u=Z.useAppSelector(Z.selectPrivileges),c=((R=t.privileges)==null?void 0:R.filter(I=>u[I]&&u[I].privilege!=="guest").length)||0,d=Z.useAppSelector(Z.selectRoles),f=Z.useAppDispatch(),{selectedRole:h,selectRole:p}=Xb(),[v,m]=A.useState(!1),y=Te.useOutsideClick(()=>{v&&b()});Te.useDidMountEffect(()=>{n!==e.role&&i(e.role)},[e.role]),A.useEffect(()=>{e.role||m(!0)},[]),A.useEffect(()=>{r(e)},[e]);const x=()=>{a(null),m(!0)},b=()=>{a(null),e.role&&e.role===n&&m(!1);try{const I=Z.saveRole({...t,role:n},d);f(Z.updateRoles(I)),m(!1)}catch(I){a(I.message)}},w=Z.useAppDispatch(),S=async I=>{I.stopPropagation();const{confirmed:N}=await w(Z.openModal({title:"Delete Role",type:Te.ModalType.CONFIRM,color:Te.ModalColor.DANGER,message:"Are you sure you want to remove this Role?",icon:"FdWarningDanger"})).unwrap();N&&E()},E=()=>{const I=Z.removeRole(t.id,d),N=Object.keys(I);if(h!==t.id){f(Z.updateRoles(I));return}if(N.length===0)p(null);else{const D=Object.keys(d),k=D.indexOf(t.id),B=Math.max(0,k-1),L=D[B];k===0?p(N[0]):I[L]?p(L):p(N[0])}f(Z.updateRoles(I))},_=(I=null)=>{if(I&&I.stopPropagation(),!e.role){E();return}m(!1),i(e.role)};return C.jsx(C.Fragment,{children:C.jsxs("div",{className:Ve("rounded border bg-grey-300 p-2",{"border-grey-100":h!==t.id,"border-primary-dark":h===t.id}),role:"button","data-cy":"privilegeCard",onClick:()=>{p(t.id)},ref:y,children:[C.jsx("div",{className:"flex items-center justify-between",children:C.jsxs("div",{className:"flex flex-1 items-center text-white",children:[C.jsx("span",{className:"mr-4",children:C.jsx(ye.FdGroup,{className:"h-6 w-6"})}),v?C.jsxs("div",{className:"relative h-6 flex-1 mr-2",children:[C.jsx("input",{type:"text",value:n,onChange:({target:{value:I}})=>{i(I)},onKeyDown:I=>{I.key==="Enter"&&b(),I.key==="Escape"&&_()},className:Ve("absolute inset-0 h-6 min-w-0 rounded border border-grey-200 bg-grey-300 p-1 text-xs focus:outline-none",{"border-b border-red-400 rounded-b-none":o,"focus:border-primary-dark":!o}),placeholder:"role",autoComplete:"off",autoFocus:!0}),o&&C.jsx("p",{className:"absolute top-5 mt-1 w-full rounded rounded-t-none bg-red-400 p-1 text-xs text-white shadow-md",children:o})]}):C.jsx("span",{className:"inline-block grow overflow-hidden truncate whitespace-nowrap text-xs font-bold",title:n,children:t.role}),C.jsx("div",{className:Ve("justify-betwee ml-auto flex w-fit items-center gap-x-2"),children:v?C.jsxs(C.Fragment,{children:[C.jsx("button",{onClick:b,className:"rounded p-1 hover:bg-primary-hover hover:text-white",children:C.jsx(ye.FdSave,{className:"h-4 w-4 text-grey-50"})}),C.jsx("button",{onClick:_,className:"rounded p-1 hover:bg-primary-hover hover:text-white",children:C.jsx(ye.FdClose,{className:"h-4 w-4 text-grey-50"})})]}):C.jsxs(C.Fragment,{children:[C.jsx("button",{onClick:x,className:"rounded p-1 hover:bg-primary-hover hover:text-white",children:C.jsx(ye.FdPen,{className:"h-4 w-4 text-grey-50"})}),C.jsx("button",{onClick:I=>S(I),className:"rounded p-1 hover:bg-primary-hover hover:text-white",children:C.jsx(ye.FdTrash,{className:"h-4 w-4 text-grey-50"})})]})})]})}),C.jsxs("span",{className:Ve("ml-[43px] py-1 text-xs text-white"),children:[c," Privilege",c>1?"s":""]})]})})},Yk=(e,t)=>e?t[e]:null,iD=(e,t,r)=>{const n=Yk(e,r);return n?Object.values(r).reduce((i,o)=>o.id===e?n.privileges.includes(t)?{...i,[n.id]:{...n,privileges:n.privileges.filter(a=>a!==t)}}:{...i,[n.id]:{...n,privileges:[...n.privileges,t]}}:{...i,[o.id]:o},{}):r},wQ=()=>{const e=Z.useAppSelector(Z.selectPrivileges),t=Z.useAppSelector(Z.selectRoles),r=Z.useAppDispatch(),{selectedRole:n}=Xb(),i=Yk(n,t),o=(a,u)=>u&&u.privileges.includes(a.id);return C.jsxs("div",{className:"w-full border-b border-grey-900 p-4 ",children:[C.jsx("div",{className:"mb-4 flex items-center gap-x-5 text-white",children:C.jsx("h4",{className:"text-[13px] font-semibold ",children:"Privileges"})}),C.jsxs("div",{className:"flex flex-wrap items-center gap-1",children:[C.jsx("div",{"data-cy":"item=>Permisions",className:Ve("inline-flex items-center gap-1 space-x-1 rounded bg-primary-darker px-2 py-0.5 text-xs font-semibold italic text-white"),children:"guest"}),Object.values(e).filter(a=>o(a,i)&&a.privilege!=="guest").map((a,u)=>C.jsxs("div",{"data-cy":"item=>Permisions",className:Ve("inline-flex cursor-pointer items-center gap-1 space-x-1 rounded px-2 py-0.5",{"bg-primary-dark text-white":o(a,i),"bg-grey-300 text-grey-100":!o(a,i)}),onClick:()=>{const c=iD(i.id,a.id,t);r(Z.updateRoles(c))},children:[C.jsx("span",{className:"text-xs",children:a.privilege}),C.jsx("button",{className:"focus:outline-none",children:o(a,i)?C.jsx(ye.FdMinus,{className:"h-[14px] w-[14px]"}):C.jsx(ye.FdPlus,{className:"h-[14px] w-[14px]"})})]},u)),Object.values(e).filter(a=>!o(a,i)&&a.privilege!=="guest").map((a,u)=>C.jsxs("div",{"data-cy":"item=>Permisions",className:Ve("inline-flex cursor-pointer items-center gap-1 space-x-1 rounded px-2 py-0.5",{"bg-primary-dark text-white":o(a,i),"bg-grey-300 text-grey-100":!o(a,i)}),onClick:()=>{const c=iD(i.id,a.id,t);r(Z.updateRoles(c))},children:[C.jsx("span",{className:"text-xs",children:a.privilege}),C.jsx("button",{className:"text-white focus:outline-none",children:o(a,i)?C.jsx(ye.FdMinus,{className:"h-[14px] w-[14px]"}):C.jsx(ye.FdPlus,{className:"h-[14px] w-[14px]"})})]},u))]})]})},_Q=({children:e})=>C.jsx("div",{className:"h-full w-full",children:C.jsx("div",{className:"flex h-full w-full flex-1 items-center justify-center bg-grey-800",children:C.jsxs("div",{className:"flex flex-col items-center justify-center space-y-4 py-4 text-grey-200",children:[C.jsx(ye.FdInfoBold,{className:"absolute -right-full h-10 w-10 translate-x-1"}),C.jsx("div",{className:"text-center text-sm",children:e})]})})}),Kb=(e,t,r,n=!1)=>{const i=e.applyTo,o=e.type===Z.EPermissionType.DATACLASS?"ds":i.split(".")[0],a={...t,...r},u=()=>({value:!n,inherited:!1,from:[],explicitly:!1}),c={read:u(),create:u(),update:u(),drop:u(),execute:u(),promote:u()},d=h=>{h.forEach(p=>{a[p]&&(a[p].resources.forEach(v=>{if(v.resource===i||v.resource===o){const m=Kb(e,t,{[p]:a[p]},n);Object.values(v.permissions).forEach(y=>{c[y.name].explicitly||(!c[y.name].from.includes(a[p].privilege)&&y.checked&&c[y.name].from.push(a[p].privilege),c[y.name].inherited=c[y.name].inherited||m[y.name].value||m[y.name].inherited)})}}),a[p].includes.length>0&&d(a[p].includes))})};if(Object.values(r).forEach(h=>{h.resources.forEach(p=>{p.resource===i&&Object.values(p.permissions).forEach(v=>{v.checked&&(c[v.name].explicitly=!0,n&&(c[v.name].value=!0))})}),(h.includes.length>0||h.privilege==="guest")&&d(h.includes)}),Object.values(t).forEach(h=>{h.resources.forEach(p=>{p.resource===i&&(h.privilege==="guest"?Object.values(p.permissions).forEach(v=>{v.checked&&(c[v.name].explicitly=!0,n&&(c[v.name].value=!0))}):Object.values(p.permissions).forEach(v=>{!c[v.name].explicitly&&v.checked&&(n?c[v.name].value=!0:c[v.name].value=!1)}))})}),(n?Object.entries(c).some(([h,p])=>h!=="promote"&&!p.value&&!p.explicitly):Object.entries(c).some(([h,p])=>h!=="promote"&&p.value&&!p.explicitly))&&![Z.EPermissionType.DATASTORE,Z.EPermissionType.SINGLETON].includes(e.type)){const h={applyTo:o,type:e.type===Z.EPermissionType.DATACLASS?Z.EPermissionType.DATASTORE:e.type===Z.EPermissionType.SINGLETON_METHOD?Z.EPermissionType.SINGLETON:Z.EPermissionType.DATACLASS},p=Kb(h,t,r,n),v=m=>{let y=c[m].value;return n?!c[m].value&&!c[m].explicitly&&(y=p[m].value):c[m].value&&!c[m].explicitly&&(y=p[m].value),{value:y,inherited:c[m].inherited||p[m].inherited,from:c[m].from.length>0?c[m].from:p[m].from,explicitly:c[m].explicitly}};return{read:v("read"),create:v("create"),update:v("update"),drop:v("drop"),execute:v("execute"),promote:v("promote")}}return{read:c.read,create:c.create,update:c.update,drop:c.drop,execute:c.execute,promote:c.promote}},EQ=e=>{switch(e){case"dataclass":return C.jsx(ye.FdTableHeader,{className:"h-6 w-6"});case"singleton":return C.jsx(ye.FdSingleton,{className:"h-6 w-6"});case"datastore":return C.jsx(ye.FdModel3,{className:"h-6 w-6"});case"attribute":return C.jsx(ye.FdTableColumn,{className:"h-6 w-6"});case"method":return C.jsx(ye.FdCode,{className:"h-6 w-6"});case"singletonMethod":return C.jsx(ye.FdFunctionSingleton,{className:"h-6 w-6"});case"entityselMethod":return C.jsx(ye.FdFunctionSelection,{className:"h-6 w-6"});case"entityMethod":return C.jsx(ye.FdFunctionEntity,{className:"h-6 w-6"});case"dsMethod":return C.jsx(ye.FdFunctionDatastore,{className:"h-6 w-6"});case"dataclassMethod":return C.jsx(ye.FdFunctionDataclass,{className:"h-6 w-6"});default:return C.jsx(ye.FdTableHeader,{className:"h-6 w-6"})}},ga=Ux,ma=Vx,co=({privileges:e,permission:t,hasChild:r,depth:n,isChild:i=!1,className:o,inSearch:a,toggleCollapse:u,collapsed:c,isRestrictedByDefault:d,toastMessageCallback:f})=>{const[h,p]=t.applyTo.split("."),v=A.useMemo(()=>Kb(t,e.otherPrivs,e.rolePrivs,d),[e,t,d]);return C.jsxs("tr",{className:Ve("group even:bg-grey-600",o),children:[C.jsxs("td",{className:Ve("flex h-full w-full items-center gap-3 p-0 text-xs group-hover:rounded-l group-hover:bg-grey-300",{"px-1":a}),children:[Array(n).fill("").map((m,y)=>C.jsx("div",{className:Ve("ml-1.5 mr-1 h-full w-0.5 border-l-2 border-grey-100",{"mr-0.5":i})},y)),r&&C.jsx("button",{onClick:u,className:"w-3",children:c?C.jsx(ye.FdRight,{className:"inline h-4 w-4"}):C.jsx(ye.FdDown,{className:"inline h-4 w-4"})}),EQ(t.type),a?t.applyTo:p||h]}),C.jsx("td",{className:"py-2 text-center group-hover:bg-grey-300",children:[Z.EPermissionType.ATTRIBUTE,Z.EPermissionType.DATASTORE,Z.EPermissionType.DATACLASS].includes(t.type)&&C.jsxs("div",{className:"relative mx-auto flex w-fit items-center justify-center gap-x-1",children:[C.jsx("div",{className:Ve("h-4 w-4 rounded border-[2px] p-2",{"grid place-content-center border-grey-200 bg-grey-200":v.read.value||v.read.inherited}),onClick:f,children:(v.read.value||v.read.inherited)&&C.jsx(ye.FdCheckNaked,{className:"text-grey-50"})}),C.jsx("div",{className:"absolute left-full top-1/2 flex -translate-y-1/2 translate-x-1/2 cursor-pointer items-center",children:!v.read.value&&v.read.inherited?C.jsxs(ga,{openDelay:0,closeDelay:0,children:[C.jsx(ma,{children:C.jsx(ye.FdInfoBold,{className:"h-4 w-4 text-white"})}),C.jsx(jr,{container:Bt(),children:C.jsx(qr,{style:{zIndex:50},avoidCollisions:!0,side:"top",className:"max-w-xs rounded bg-primary-light py-2 text-sm font-semibold text-primary",children:C.jsx("div",{className:"space-y-1 px-2",children:v.read.from.length?C.jsxs("div",{className:"flex items-start text-s",children:[C.jsx(ye.FdBulb,{className:"mr-2 mt-0.5 h-4 w-4 flex-shrink-0"}),C.jsxs("p",{children:[C.jsx("span",{className:"mr-1",children:"Permission inherited from:"}),C.jsx("ul",{children:v.read.from.map((m,y)=>C.jsx("li",{className:"cursor-pointer list-disc font-bold",children:m},y))})]})]}):null})})})]}):""})]})}),C.jsx("td",{className:"py-2 text-center group-hover:bg-grey-300",children:[Z.EPermissionType.ATTRIBUTE,Z.EPermissionType.DATASTORE,Z.EPermissionType.DATACLASS].includes(t.type)&&C.jsxs("div",{className:"relative mx-auto flex w-fit items-center justify-center gap-x-1",children:[C.jsx("div",{className:Ve("h-4 w-4 rounded border-[2px] p-2",{"grid place-content-center border-grey-200 bg-grey-200":v.create.value||v.create.inherited}),onClick:f,children:(v.create.value||v.create.inherited)&&C.jsx(ye.FdCheckNaked,{className:"text-grey-50"})}),C.jsx("div",{className:"absolute left-full top-1/2 flex -translate-y-1/2 translate-x-1/2 cursor-pointer items-center",children:!v.create.value&&v.create.inherited?C.jsxs(ga,{openDelay:0,closeDelay:0,children:[C.jsx(ma,{children:C.jsx(ye.FdInfoBold,{className:"h-4 w-4 text-white"})}),C.jsx(jr,{container:Bt(),children:C.jsx(qr,{style:{zIndex:50},avoidCollisions:!0,side:"top",className:"max-w-xs rounded bg-primary-light py-2 text-sm font-semibold text-primary",children:C.jsx("div",{className:"space-y-1 px-2",children:v.create.from.length?C.jsxs("div",{className:"flex items-start text-s",children:[C.jsx(ye.FdBulb,{className:"mr-2 mt-0.5 h-4 w-4 flex-shrink-0"}),C.jsxs("p",{children:[C.jsx("span",{className:"mr-1",children:"Permission inherited from:"}),C.jsx("ul",{children:v.create.from.map((m,y)=>C.jsx("li",{className:"cursor-pointer list-disc font-bold",children:m},y))})]})]}):null})})})]}):""})]})}),C.jsx("td",{className:"py-2 text-center group-hover:bg-grey-300",children:[Z.EPermissionType.ATTRIBUTE,Z.EPermissionType.DATASTORE,Z.EPermissionType.DATACLASS].includes(t.type)&&C.jsxs("div",{className:"relative mx-auto flex w-fit items-center justify-center gap-x-1",children:[C.jsx("div",{className:Ve("h-4 w-4 rounded border-[2px] p-2",{"grid place-content-center border-grey-200 bg-grey-200":v.update.value||v.update.inherited}),onClick:f,children:(v.update.value||v.update.inherited)&&C.jsx(ye.FdCheckNaked,{className:"text-grey-50"})}),C.jsx("div",{className:"absolute left-full top-1/2 flex -translate-y-1/2 translate-x-1/2 cursor-pointer items-center",children:!v.update.value&&v.update.inherited?C.jsxs(ga,{openDelay:0,closeDelay:0,children:[C.jsx(ma,{children:C.jsx(ye.FdInfoBold,{className:"h-4 w-4 text-white"})}),C.jsx(jr,{container:Bt(),children:C.jsx(qr,{style:{zIndex:50},avoidCollisions:!0,side:"top",className:"max-w-xs rounded bg-primary-light py-2 text-sm font-semibold text-primary",children:C.jsx("div",{className:"space-y-1 px-2",children:v.update.from.length?C.jsxs("div",{className:"flex items-start text-s",children:[C.jsx(ye.FdBulb,{className:"mr-2 mt-0.5 h-4 w-4 flex-shrink-0"}),C.jsxs("p",{children:[C.jsx("span",{className:"mr-1",children:"Permission inherited from:"}),C.jsx("ul",{children:v.update.from.map((m,y)=>C.jsx("li",{className:"cursor-pointer list-disc font-bold",children:m},y))})]})]}):null})})})]}):""})]})}),C.jsx("td",{className:"py-2 text-center group-hover:bg-grey-300",children:[Z.EPermissionType.ATTRIBUTE,Z.EPermissionType.DATASTORE,Z.EPermissionType.DATACLASS].includes(t.type)&&C.jsxs("div",{className:"relative mx-auto flex w-fit items-center justify-center gap-x-1",children:[C.jsx("div",{className:Ve("h-4 w-4 rounded border-[2px] p-2",{"grid place-content-center border-grey-200 bg-grey-200":v.drop.value||v.drop.inherited}),onClick:f,children:(v.drop.value||v.drop.inherited)&&C.jsx(ye.FdCheckNaked,{className:"text-grey-50"})}),C.jsx("div",{className:"absolute left-full top-1/2 flex -translate-y-1/2 translate-x-1/2 cursor-pointer items-center",children:!v.drop.value&&v.drop.inherited?C.jsxs(ga,{openDelay:0,closeDelay:0,children:[C.jsx(ma,{children:C.jsx(ye.FdInfoBold,{className:"h-4 w-4 text-white"})}),C.jsx(jr,{container:Bt(),children:C.jsx(qr,{style:{zIndex:50},avoidCollisions:!0,side:"top",className:"max-w-xs rounded bg-primary-light py-2 text-sm font-semibold text-primary",children:C.jsx("div",{className:"space-y-1 px-2",children:v.drop.from.length?C.jsxs("div",{className:"flex items-start text-s",children:[C.jsx(ye.FdBulb,{className:"mr-2 mt-0.5 h-4 w-4 flex-shrink-0"}),C.jsxs("p",{children:[C.jsx("span",{className:"mr-1",children:"Permission inherited from:"}),C.jsx("ul",{children:v.drop.from.map((m,y)=>C.jsx("li",{className:"cursor-pointer list-disc font-bold",children:m},y))})]})]}):null})})})]}):""})]})}),C.jsx("td",{className:"py-2 text-center group-hover:rounded-r group-hover:bg-grey-300",children:t.type!=="attribute"&&C.jsxs("div",{className:"relative mx-auto flex w-fit items-center justify-center gap-x-1",children:[C.jsx("div",{className:Ve("h-4 w-4 rounded border-[2px] p-2",{"grid place-content-center border-grey-200 bg-grey-200":v.execute.value||v.execute.inherited}),onClick:f,children:(v.execute.value||v.execute.inherited)&&C.jsx(ye.FdCheckNaked,{className:"text-grey-50"})}),C.jsx("div",{className:"absolute left-full top-1/2 flex -translate-y-1/2 translate-x-1/2 cursor-pointer items-center",children:!v.execute.value&&v.execute.inherited?C.jsxs(ga,{openDelay:0,closeDelay:0,children:[C.jsx(ma,{children:C.jsx(ye.FdInfoBold,{className:"h-4 w-4 text-white"})}),C.jsx(jr,{container:Bt(),children:C.jsx(qr,{style:{zIndex:50},avoidCollisions:!0,side:"top",className:"max-w-xs rounded bg-primary-light py-2 text-sm font-semibold text-primary",children:C.jsx("div",{className:"space-y-1 px-2",children:v.execute.from.length?C.jsxs("div",{className:"flex items-start text-s",children:[C.jsx(ye.FdBulb,{className:"mr-2 mt-0.5 h-4 w-4 flex-shrink-0"}),C.jsxs("p",{children:[C.jsx("span",{className:"mr-1",children:"Permission inherited from:"}),C.jsx("ul",{children:v.execute.from.map((m,y)=>C.jsx("li",{className:"cursor-pointer list-disc font-bold",children:m},y))})]})]}):null})})})]}):""})]})})]})},oD=({depth:e,permission:t,privileges:r,childCollapsed:n,didChildCollapsed:i,toastMessageCallback:o})=>{const[a,u]=A.useState(n),c=Z.useAppSelector(Z.selectRestrictedByDefault),d=Z.useAppSelector(Z.selectPrivileges);return A.useEffect(()=>{n===!0&&u(!0)},[n]),C.jsxs(C.Fragment,{children:[C.jsx(co,{privileges:r,permission:t,isChild:!0,depth:e,hasChild:!0,toggleCollapse:()=>{const f=!a;u(f),i==null||i(f)},isRestrictedByDefault:c,allPrivileges:d,collapsed:a,toastMessageCallback:o}),!a&&C.jsxs(C.Fragment,{children:[t.attributes.map((f,h)=>C.jsx(co,{privileges:r,permission:f,depth:e+1,isRestrictedByDefault:c,allPrivileges:d,toastMessageCallback:o},`${f.type}-${h}`)),t.methods.map((f,h)=>C.jsx(co,{privileges:r,permission:f,depth:e+1,isRestrictedByDefault:c,allPrivileges:d,toastMessageCallback:o},`${f.type}-${h}`))]})]})},SQ=({selectedRole:e})=>{const[t,r]=A.useState(null),[n,i]=A.useState(null),{styles:o,attributes:a}=wc(t,n,{modifiers:[{name:"offset",options:{offset:[0,10]}}]}),u=Z.useAppSelector(Z.selectRestrictedByDefault),c=Z.useAppSelector(Z.selectPrivileges),[d,f]=A.useState([]),[h,p]=A.useState(""),v=Z.useAppSelector(Z.selectCatalogMethods),m=Z.useAppSelector(Z.selectDataclasses),y=Z.useAppSelector(Z.selectSingletons),[x,b]=A.useState({}),[w,S]=A.useState([]);A.useEffect(()=>{const F=g9(v,Object.values(m),Object.values(y));b(F)},[e]);function E(F){const $=["datastore","singleton","dataclass","attribute","dsMethod","dataclassMethod","entityMethod","entityselMethod","singletonMethod"];return F.sort((W,Y)=>{const ee=$.indexOf(W.type),H=$.indexOf(Y.type);return ee!==H?ee-H:W.applyTo.toLowerCase()>Y.applyTo.toLowerCase()?1:-1})}A.useEffect(()=>{S(E(Mx(h,v,Object.values(m),Object.values(y)).filter(F=>d.length?d.includes(F.type):!0)))},[d,h]);const[_,R]=A.useState(!1),I=F=>{f($=>$.some(W=>F.includes(W))?$.filter(W=>!F.includes(W)):[...$,...F])},N=Z.useAppSelector(Z.selectRoles),D={toggleAllCollapsed:F=>{F.allCollapsed=!F.allCollapsed},toggleChildCollapsed:F=>{F.childCollapsed=!F.childCollapsed},setAllCollapsed:(F,$)=>{F.allCollapsed=$},setChildCollapsed:(F,$)=>{F.childCollapsed=$}},k=A.useMemo(()=>{const F=Object.values(c).find(H=>H.privilege==="guest"),$=N[e],W=$?Object.fromEntries($.privileges.map(H=>[H,c[H]]).filter(([,H])=>!!H)):{};if(u)return{rolePrivs:W,otherPrivs:F?{[F.id]:F}:{}};const Y=F?{[F.id]:{...F,active:!0}}:{},ee=Object.fromEntries(Object.entries(c).filter(([H])=>H!==(F==null?void 0:F.id)&&!($!=null&&$.privileges.includes(H))).map(([H,Q])=>[H,{...Q,active:!1}]));return{rolePrivs:W,otherPrivs:{...Y,...ee}}},[c,N,e,u]),{state:{allCollapsed:B,childCollapsed:L},dispatch:j}=Te.useEnhancedState({allCollapsed:!1,childCollapsed:!1},D,"Table Collapse Store"),T=()=>{Te.toastSubject.next({kind:"info",markdown:!0,message:"**Info:** You can add or modify permissions only in the Privilege section.",customIcon:ye.FdInfoCircle})};return C.jsxs(dl,{className:"z-20 h-full flex-1 overflow-auto bg-grey-800 p-[15px] pt-0",style:{maxHeight:"calc(100vh - 5.5rem - 85px - 20px)"},children:[C.jsxs("table",{className:"relative h-full w-full",children:[C.jsx("thead",{className:"sticky top-0 z-20 bg-grey-800",children:C.jsxs("tr",{className:"border-b border-grey-100",children:[C.jsx("td",{className:"py-2",children:C.jsxs("div",{className:"flex items-center space-x-2",children:[C.jsx(Te.Tooltip,{label:"Collapse All",placement:"top",container:Bt(),children:C.jsx("button",{onClick:()=>{L?(j.setAllCollapsed(!0),R(!0)):j.setChildCollapsed(!0)},className:Ve("cursor-pointer rounded-md p-1 hover:bg-primary-hover focus:outline-none",{"pointer-events-none text-grey-200":B,"text-white":!B}),children:C.jsx(ye.FdCollapseAll,{className:"h-4 w-4"})})}),C.jsxs("div",{className:"relative w-56 text-white",children:[C.jsx("div",{className:"absolute inset-y-0 left-0 flex items-center px-1",children:C.jsx(ye.FdSearch,{className:"h-4 w-4 text-gray-400"})}),C.jsx("div",{className:"absolute inset-y-0 right-0 flex items-center px-2",children:C.jsx(wr.Popover,{className:"flex items-center",children:({open:F})=>C.jsxs(C.Fragment,{children:[C.jsx(wr.Popover.Button,{ref:r,children:C.jsx(ye.FdAdjust,{className:"h-4 w-4"})}),F&&C.jsx(el,{children:C.jsxs(wr.Popover.Panel,{ref:i,style:o.popper,...a.popper,className:"z-50 rounded-md border border-grey-50 bg-grey-900 px-4 py-2.5 text-xs text-grey-50",static:!0,children:[C.jsx("h5",{className:"mb-2 text-sm",children:"Filter"}),C.jsxs("div",{className:"space-y-2 text-s",children:[C.jsx("div",{className:"flex items-center",children:C.jsx(Te.Checkbox,{isChecked:d.includes("datastore"),onChange:()=>{I(["datastore"])},label:"Datastore"})}),C.jsx("div",{className:"flex items-center",children:C.jsx(Te.Checkbox,{isChecked:d.includes("dataclass"),onChange:()=>{I(["dataclass"])},label:"Dataclass"})}),C.jsx("div",{className:"flex items-center",children:C.jsx(Te.Checkbox,{isChecked:d.includes("singleton"),onChange:()=>{I(["singleton"])},label:"Singleton"})}),C.jsx("div",{className:"flex items-center",children:C.jsx(Te.Checkbox,{isChecked:d.some($=>["method","singletonMethod","dsMethod","dataclassMethod","entityMethod","entityselMethod"].includes($)),onChange:()=>{I(["method","singletonMethod","dsMethod","dataclassMethod","entityMethod","entityselMethod"])},label:"Functions"})}),C.jsx("div",{className:"flex items-center",children:C.jsx(Te.Checkbox,{isChecked:d.includes("attribute"),onChange:()=>{I(["attribute"])},label:"Attribute"})})]})]})})]})})}),C.jsx("input",{type:"text",className:"block h-6 w-full rounded bg-grey-300 px-1 py-1.5 pl-6 text-xs focus:outline-none",placeholder:"Search",value:h,onChange:F=>{p(F.target.value)}})]})]})}),C.jsx("td",{className:"bg-grey-800 px-4 py-2 text-center text-[12px] text-white",children:"read"}),C.jsx("td",{className:"bg-grey-800 px-4 py-2 text-center text-[12px] text-white",children:"Create"}),C.jsx("td",{className:"bg-grey-800 px-4 py-2 text-center text-[12px] text-white",children:"Update"}),C.jsx("td",{className:"bg-grey-800 px-4 py-2 text-center text-[12px] text-white",children:"Delete"}),C.jsx("td",{className:"bg-grey-800 px-4 py-2 text-center text-[12px] text-white",children:"Execute"})]})}),C.jsx("tbody",{className:"relative bg-grey-800 text-white",children:d.length||h?w.map((F,$)=>C.jsx(co,{privileges:k,permission:F,depth:0,inSearch:!0,isRestrictedByDefault:u,allPrivileges:c,toastMessageCallback:T},`${F.type}-${$}`)):Object.values(x).map((F,$)=>C.jsxs(A.Fragment,{children:[C.jsx(co,{privileges:k,permission:F,isRestrictedByDefault:u,allPrivileges:c,hasChild:!0,depth:0,toggleCollapse:()=>{const W=!_;R(W),j.setAllCollapsed(!W&&B?!1:B)},collapsed:_,toastMessageCallback:T}),F.type==="datastore"&&!_?C.jsxs(C.Fragment,{children:[F.methods.map((W,Y)=>C.jsx(co,{privileges:k,isRestrictedByDefault:u,allPrivileges:c,permission:W,depth:1,collapsed:B||!1,toastMessageCallback:T},`${W.type}-${Y}`)),F.dataClasses.map((W,Y)=>C.jsx(oD,{depth:1,privileges:k,permission:W,childCollapsed:L,didChildCollapsed:ee=>{j.setChildCollapsed(ee?L:!1)},toastMessageCallback:T},`${W.type}-${Y}`))]}):null,F.singletons.map((W,Y)=>C.jsx(oD,{depth:0,privileges:k,permission:W,childCollapsed:B,didChildCollapsed:ee=>{j.setAllCollapsed(ee?B:!1)},toastMessageCallback:T},`${W.type}-${Y}`))]},`${F.type}-${$}`))})]}),(h||d.length)&&!w.length?C.jsx(_Q,{children:"The Permission you're looking for can't be found "}):null]})},OQ=()=>{const e=Z.useAppSelector(Z.selectRoles),t=Z.useAppDispatch(),[r,n]=A.useState(null),[i,o]=A.useState(null),[a,u]=A.useState(""),[c,d]=A.useState(null),{styles:f,attributes:h}=wc(r,i,{modifiers:[{name:"offset",options:{offset:[-10,10]}}],placement:"right-start"});A.useEffect(()=>{u(""),d(null)},[i]);const p=()=>{if(!a)throw new Error("Please enter a valid name");if(Object.values(e).find(x=>x.role.toLowerCase()===a.toLowerCase()))throw new Error(`A role with the name ${a} already exists`);const m=bQ.generate(),y=Z.createRole(m,a,e);t(Z.updateRoles(y))};return C.jsx(wr.Popover,{children:({open:v,close:m})=>{const y=()=>{d(null);try{Te.validateName(a),p(),m()}catch(x){d(x.message)}};return C.jsxs(C.Fragment,{children:[C.jsx(wr.Popover.Button,{className:"rounded p-1 hover:bg-primary-hover","data-cy":"New-priv-btn",ref:n,children:C.jsx("span",{children:C.jsx(ye.FdPlus,{className:"h-4 w-4 text-white"})})}),v&&C.jsx(el,{children:C.jsxs(wr.Popover.Panel,{ref:o,style:f.popper,...h.popper,"data-cy":"New-priv-pop-up",className:"z-50 min-w-[256px] rounded border border-grey-50 bg-grey-900 px-4 py-2 text-xs text-grey-50 shadow-md",static:!0,children:[C.jsx("h5",{className:"mb-2 text-xs font-semibold",children:"Create New Role"}),C.jsxs("div",{className:"mt-2",children:[C.jsxs("label",{className:"flex items-center space-x-4",children:[C.jsx("span",{className:"text-grey-100",children:"Name"}),C.jsx("input",{autoFocus:!0,value:a,onChange:x=>u(x.target.value),onKeyDown:x=>{x.key==="Enter"&&y()},type:"text",className:Ve("w-full rounded border bg-grey-300 p-1 focus:outline-none",{"border-grey-100":!c,"border-red-400":c})})]}),c&&C.jsx("p",{className:"mt-1 text-xs text-red-400",children:c})]}),C.jsxs("div",{className:"mt-4 flex items-center justify-center space-x-2",children:[C.jsx("button",{className:"rounded border border-primary-dark bg-primary-dark px-4 py-1 hover:border-primary-hover hover:bg-primary-hover",onClick:()=>{y()},children:"Create"}),C.jsx("button",{className:"rounded border border-grey-100 px-4 py-1 text-grey-100 hover:bg-white hover:text-primary-dark",onClick:()=>m(),children:"Cancel"})]})]})})]})}})},CQ=()=>{const e=Z.useAppSelector(Z.selectRoles),{selectedRole:t}=Xb();return C.jsxs("div",{className:"flex flex-1 h-full",children:[C.jsxs("div",{className:"flex h-full w-[356px] flex-col bg-grey-800",children:[C.jsxs("div",{className:"flex flex-shrink-0 items-center justify-between bg-grey-800 px-3.5 py-[10px]",children:[C.jsxs("div",{className:"flex items-center space-x-1 text-[#DDE1E6]",children:[C.jsx("span",{children:C.jsx(ye.FdGroup,{className:"h-[14px] w-[14px]"})}),C.jsx("span",{className:"text-[11px] font-semibold",children:"Roles"})]}),C.jsx(OQ,{})]}),C.jsx("div",{className:"flex-1 space-y-4 overflow-auto p-4 pb-10 pt-1",children:Object.values(e).length>0?Object.values(e).sort((r,n)=>Te.localeCompare(r.role,n.role)).map((r,n)=>C.jsx(xQ,{role:r},n)):C.jsx("div",{className:"flex h-full items-center justify-center",children:C.jsx("div",{className:"flex flex-1 items-center justify-center bg-grey-800",children:C.jsxs("div",{className:"flex flex-col items-center justify-center space-y-4 text-grey-200",children:[C.jsx(ye.FdInfoBold,{className:"h-10 w-10"}),C.jsx("div",{className:"font-semibold",children:"There are no roles"}),C.jsxs("div",{className:"flex items-center text-sm",children:["Create a new role by clicking on the"," ",C.jsx(ye.FdPlus,{className:"ml-2 inline h-4 w-4 text-white"})]})]})})})})]}),C.jsx("div",{className:Ve("relative flex h-full w-full flex-1 flex-col items-stretch overflow-x-auto bg-grey-800",{"border-l-[0.5px] border-grey-900":t}),children:C.jsx("div",{className:"flex h-full w-full select-none flex-col bg-grey-800",children:t?C.jsxs(C.Fragment,{children:[C.jsx(wQ,{}),C.jsx(SQ,{selectedRole:t})]}):C.jsx(bD,{tab:"Role"})})})]})},Xk=()=>{const e=Z.useAppSelector(Z.selectQodly),t=Z.useAppSelector(Z.selectSelectedTab),r=Z.useAppSelector(Z.selectForceLogin),n=Z.useAppSelector(Z.selectRestrictedByDefault),i=A.useRef(),o=Z.useAppDispatch();return C.jsx("div",{className:"absolute inset-0 flex flex-1 overflow-hidden",children:C.jsx("div",{className:"relative flex flex-1 overflow-x-auto bg-grey-900","data-cy":"Roles&Privileges-editor-cy",ref:a=>i.current=a,children:C.jsxs("div",{className:"flex w-full flex-col",children:[C.jsx(Zz,{activeTab:t,forceLogin:r,restrictedByDefault:n,onTabChange:a=>{o(Z.toggleTab(a))},onForceLoginChange:a=>{o(Z.toggleForceLogin(a))},onRestrictedByDefaultChange:a=>{o(Z.toggleRestrictedByDefault(a))},qodly:e}),t==="roles"?C.jsx(Jz,{children:C.jsx(CQ,{})}):C.jsx(nQ,{})]})})})},RQ=()=>{const e=Z.useAppSelector(Z.selectModals),t=Z.useAppDispatch();return C.jsx(C.Fragment,{children:e.map((r,n)=>C.jsx(Te.Modal,{hasOverlay:n===0,...r,onClose:i=>t(Z.closeModal(i)),onEdit:i=>t(Z.editModal(i)),container:Bt()},r.id))})},IQ=({initialValue:e,onChange:t,...r})=>{const n=Z.useAppSelector(Z.selectRolesFlags),i=Z.useAppSelector(Z.selectRolesAndPrivileges,(a,u)=>vc.isEqual(a,u)),o=Z.useAppDispatch();return A.useEffect(()=>{if(e)try{const a=JSON.parse(e);if(vc.isEqual(a,i))return;o(Z.setRolesContent({content:a,flags:{touched:!1}}))}catch(a){console.error("[Roles Editor Standalone] Error while parsing the initial value:",a)}},[e]),Te.useDidMountEffect(()=>{if(n.touched&&t)try{const a=JSON.stringify(i,null,2);t(a)}catch(a){console.error("[Roles Editor Standalone] Error on value stringify:",a)}},[i]),C.jsxs(C.Fragment,{children:[C.jsx("div",{className:"relative z-10 overflow-hidden",style:{height:"100vh"},children:C.jsx(Xk,{...r})}),C.jsx(RQ,{})]})},PQ=e=>C.jsx(Z.ReduxProvider,{store:Z.getStore(),children:C.jsx(Te.TipsProvider,{children:C.jsx(IQ,{...e})})});exports.ROLES_EDITOR_SCOPE_CLASS=sD.ROLES_EDITOR_SCOPE_CLASS;exports.Roles=Xk;exports.Standalone=PQ;
|
|
125
|
+
`),R.useEffect(function(){return d=o.ref||d,f.current&&(u=new Rd(f.current,Su(Su(Su(Su({},Ide(g)),v),d&&{scrollableNode:d.current}),h.current&&{contentNode:h.current})),typeof t=="function"?t(u):t&&(t.current=u)),function(){u.unMount(),u=null,typeof t=="function"&&t(null)}},[]),R.createElement(c,Nd({ref:f,"data-simplebar":!0},b),R.createElement("div",{className:"simplebar-wrapper"},R.createElement("div",{className:"simplebar-height-auto-observer-wrapper"},R.createElement("div",{className:"simplebar-height-auto-observer"})),R.createElement("div",{className:"simplebar-mask"},R.createElement("div",{className:"simplebar-offset"},typeof r=="function"?r({scrollableNodeRef:d,contentNodeRef:h}):R.createElement("div",Nd({},o,{className:"simplebar-content-wrapper".concat(o.className?" ".concat(o.className):"")}),R.createElement("div",{className:"simplebar-content"},r)))),R.createElement("div",{className:"simplebar-placeholder"})),R.createElement("div",{className:"simplebar-track simplebar-horizontal"},R.createElement("div",{className:"simplebar-scrollbar"})),R.createElement("div",{className:"simplebar-track simplebar-vertical"},R.createElement("div",{className:"simplebar-scrollbar"})))});Mf.displayName="SimpleBar";Mf.propTypes={children:pe.oneOfType([pe.node,pe.func]),scrollableNodeProps:pe.object,tag:pe.string};const Id=sE,Pd=lE,b$=e=>{switch(e){case he.EPermissionType.DATACLASS:return O.jsx(_e.FdTableHeader,{className:"h-6 w-6"});case he.EPermissionType.SINGLETON:return O.jsx(_e.FdSingleton,{className:"h-6 w-6"});case he.EPermissionType.DATASTORE:return O.jsx(_e.FdModel3,{className:"h-6 w-6"});case he.EPermissionType.ATTRIBUTE:return O.jsx(_e.FdTableColumn,{className:"h-6 w-6"});case he.EPermissionType.METHOD:return O.jsx(_e.FdCode,{className:"h-6 w-6"});case he.EPermissionType.SINGLETON_METHOD:return O.jsx(_e.FdFunctionSingleton,{className:"h-6 w-6"});case he.ESubPermissionType.ENTITY_SEL_METHOD:return O.jsx(_e.FdFunctionSelection,{className:"h-6 w-6"});case he.ESubPermissionType.ENTITY_METHOD:return O.jsx(_e.FdFunctionEntity,{className:"h-6 w-6"});case he.ESubPermissionType.DS_METHOD:return O.jsx(_e.FdFunctionDatastore,{className:"h-6 w-6"});case he.ESubPermissionType.DATACLASS_METHOD:return O.jsx(_e.FdFunctionDataclass,{className:"h-6 w-6"});default:return O.jsx(_e.FdTableHeader,{className:"h-6 w-6"})}},PL=({children:e})=>O.jsx("div",{className:"h-full w-full",children:O.jsx("div",{className:"flex h-full w-full flex-1 items-center justify-center",children:O.jsxs("div",{className:"flex flex-col items-center justify-center space-y-4 py-4 text-grey-200",children:[O.jsx(_e.FdInfoBold,{className:"h-10 w-10"}),O.jsx("div",{className:"text-center text-sm",children:e})]})})}),aa=({permissions:e,label:t,onToggle:r,onSelect:n,promoted:o,showIncluded:i,privileges:a,exists:s})=>{const c=e.find(u=>u.name===t);return c?O.jsxs("div",{className:"relative mx-auto flex w-fit items-center",children:[O.jsx(or,{value:c.checked||c.from.length===0||t==="promote"?c.checked:i&&c.from.length>0?null:!1,onChange:()=>r&&r(c),isInvalid:s===!1}),O.jsxs("div",{className:"absolute left-full translate-x-1/4 top-1/2 -translate-y-1/2 flex cursor-pointer items-center space-x-1",children:[t!=="promote"&&(c.checked&&(c.info||c.from.length>0)||!c.checked&&c.from.length>0)&&O.jsx(O.Fragment,{children:O.jsxs(Id,{openDelay:0,closeDelay:0,children:[O.jsx(Pd,{children:O.jsx(_e.FdInfoBold,{className:"h-4 w-4 text-white"})}),O.jsx(Cn,{container:yr(),children:O.jsx(Rn,{style:{zIndex:50},avoidCollisions:!0,side:"top",className:"max-w-xs rounded bg-primary-light py-2 text-sm font-semibold text-primary",children:O.jsxs("div",{className:"space-y-1 px-2",children:[c.from.length?O.jsxs("div",{className:"flex items-start text-s",children:[O.jsx(_e.FdBulb,{className:"mr-2 mt-0.5 h-4 w-4 flex-shrink-0"}),O.jsxs("p",{children:[O.jsx("span",{className:"mr-1",children:"Permission inherited from:"}),O.jsx("ul",{children:c.from.map(u=>O.jsx("li",{className:"cursor-pointer list-disc font-bold hover:underline",onClick:()=>n(a[u].id),children:a[u].privilege}))})]})]}):null,c.info&&O.jsxs("div",{className:"flex items-start text-s",children:[O.jsx(_e.FdInfoCircle,{className:"mr-2 mt-0.5 h-4 w-4 flex-shrink-0"})," ",c.info]})]})})})]})}),(c.checked||c.from.length>0)&&["execute"].includes(t)&&!!(o!=null&&o.length)&&O.jsxs(Id,{openDelay:0,closeDelay:0,children:[O.jsx(Pd,{children:O.jsx(_e.FdCrown,{className:"h-3 w-3 text-white"})}),O.jsx(Cn,{container:yr(),children:O.jsx(Rn,{style:{zIndex:50},avoidCollisions:!0,side:"top",className:"max-w-xs rounded bg-primary-light py-2 text-sm font-semibold text-primary",children:O.jsx("div",{className:"space-y-1 px-2",children:O.jsxs("div",{className:"flex items-start text-s",children:[O.jsx(_e.FdInfoCircle,{className:"mr-2 mt-0.5 h-4 w-4 flex-shrink-0"}),O.jsxs("p",{children:[O.jsxs("span",{className:"mr-1",children:["Function is promoted with:"," "]}),o==null?void 0:o.map(u=>O.jsx("li",{className:"cursor-pointer list-disc font-bold hover:underline",onClick:()=>n(a[u].id),children:a[u].privilege}))]})]})})})})]})]})]}):null},Pde=({privilegeId:e,privileges:t})=>{const r=dr(),n=r.getCatalogMethods(),o=r.getDataclasses(),i=r.getSingletons(),a=t[e],[s,c]=R.useState([]),[u,d]=R.useState("");R.useEffect(()=>{d("")},[e]);const{isOpen:f,getMenuProps:h,getInputProps:v,getComboboxProps:b,highlightedIndex:g,getItemProps:m,selectedItem:x,openMenu:w}=fa({onInputValueChange(){c([])},items:[],itemToString(_){return _?_.applyTo:""},defaultHighlightedIndex:0,stateReducer:(_,C)=>{const{changes:N,type:P}=C;switch(P){case fa.stateChangeTypes.InputKeyDownArrowDown:return{...N,isOpen:!0,highlightedIndex:_.highlightedIndex<=s.length?_.highlightedIndex+1:0};case fa.stateChangeTypes.InputKeyDownArrowUp:return{...N,isOpen:!0,highlightedIndex:_.highlightedIndex>=0?_.highlightedIndex-1:s.length};case fa.stateChangeTypes.InputKeyDownEnter:const A=s[_.highlightedIndex];if(!A)return N;const j=he.addPermission(e,A,t);return r.actions.updatePrivileges(j),{...N,isOpen:!0,highlightedIndex:0}}return N}});R.useEffect(()=>{const _=a.resources.map(({resource:N,type:P,subType:A})=>({type:P,applyTo:N,subType:A})),C=Y1(u.toLowerCase(),n,Object.values(o),Object.values(i));c(C.filter(({applyTo:N,type:P,subType:A})=>!Al.find(_,{applyTo:N,type:P,subType:A})))},[u,a.resources]);const E=h({},{suppressRefError:!0}),S=R.useRef(null);return R.useEffect(()=>{f&&S.current&&S.current.focus()},[f]),O.jsxs("div",{className:"relative w-56 text-white group",...b(),children:[O.jsx("div",{...b(),children:O.jsx("input",{...v({},{suppressRefError:!0}),ref:S,type:"text",className:"block h-6 w-full rounded bg-grey-300 px-1 py-1.5 pl-2 pr-5 text-xs border-grey-500 focus:outline-none focus:ring-1 focus:ring-white focus:rounded-b-none focus:ring-inset",placeholder:"Create a permission",value:u,onChange:({target:{value:_}})=>d(_),onFocus:()=>{w()}})}),O.jsx("div",{className:"absolute inset-y-0 right-0 flex items-center px-1",children:O.jsx(_e.FdDown,{className:"h-4 w-4 cursor-pointer",onMouseDown:_=>{_.preventDefault()},onClick:()=>{w()}})}),f&&O.jsx("ul",{...E,tabIndex:0,className:"absolute max-h-80 inset-x-0 top-full overflow-auto rounded-md border border-grey-50 bg-grey-900 p-0 text-grey-50 shadow-md group-focus-within:rounded-t-none group-focus-within:border-t-0",children:s.map((_,C)=>O.jsxs("li",{className:zt(x===_&&"font-bold","flex min-w-fit cursor-pointer items-center space-x-2 px-3 py-2 text-xs shadow-sm",{"bg-primary-hover":g===C,"font-bold":x===_}),...m({item:_,index:C}),onClick:()=>{const N=he.addPermission(e,_,t);r.actions.updatePrivileges(N)},children:[b$(_.type),O.jsx("span",{children:_.applyTo})]},`${_.applyTo}-${C}`))})]})};function Tde(e){const t=["datastore","singleton","dataclass","attribute","dsMethod","dataclassMethod","entityMethod","entityselMethod","singletonMethod"],r=e.reduce((n,o)=>{const[i]=o.resource.split("."),a=n.find(s=>s.prefix===i.toLowerCase());return a?(a.resources.push(o),n):[...n,{prefix:i.toLowerCase(),type:o.type,resources:[o]}]},[]);return r.sort((n,o)=>n.prefix==="ds"?-1:o.prefix==="ds"||n.prefix>o.prefix?1:-1),r.map(n=>({...n,resources:n.resources.sort((o,i)=>{const a=t.indexOf(o.type),s=t.indexOf(i.type);return a!==s?a-s:o.resource.toLowerCase()>i.resource.toLowerCase()?1:-1})})).reduce((n,o)=>[...n,...o.resources],[])}const Ade=({selectedPrivilege:e,onSelect:t,showIncluded:r,privileges:n})=>{const[o,i]=R.useState(null),[a,s]=R.useState(null),{styles:c,attributes:u}=Bd(o,a,{modifiers:[{name:"offset",options:{offset:[0,10]}}]}),d=dr(),[f,h]=R.useState([]),[v,b]=R.useState(""),{id:g}=e,m=R.useMemo(()=>he.getInheritedResources(g,n),[g,n[g].includes,n[g].resources]),x=R.useMemo(()=>he.getPromotions(g,n),[n[g]]);function w(L){h(D=>D.some(T=>L.includes(T))?D.filter(T=>!L.includes(T)):[...D,...L])}const E=async L=>{const{confirmed:D}=await d.actions.openModal({title:"Delete Privilege",type:he.ModalType.CONFIRM,color:he.ModalColor.DANGER,message:"Are you sure you want to remove this Privilege?",icon:"FdWarningDanger"});if(D){const T=he.removePermission(e.id,L,n);d.actions.updatePrivileges(T)}},S=async()=>{const{confirmed:L}=await d.actions.openModal({title:"Reset Permissions",type:he.ModalType.CONFIRM,color:he.ModalColor.DANGER,message:"Are you sure you want to reset permissions for this Privilege?",icon:"FdWarningDanger"});if(L){const D=he.resetResources(e.id,n);d.actions.updatePrivileges(D)}},C=m.filter(L=>f.length===0?!0:f.includes(L.type)).filter(({resource:L})=>v?new RegExp(Al.escapeRegExp(v),"i").test(L):!0),N=Tde(C),P=N.filter(L=>{const D=L.permissions.every(T=>!T.checked)&&L.permissions.some(T=>T.from.length>0);return r||!D}),A=(L,D)=>{const T=he.togglePermission(e.id,L,D,n);d.actions.updatePrivileges(T)},j=R.useMemo(()=>P.some(L=>L.exists===!1),[P]),M=async()=>{const{confirmed:L}=await d.actions.openModal({title:"Delete Privilege",type:he.ModalType.CONFIRM,color:he.ModalColor.DANGER,message:"Are you sure you want to remove these permissions?",views:{tips:[{type:"warning",message:"This action will remove all permissions that don't exist in the catalog for all privileges"}]},icon:"FdWarningDanger"}),D=Object.entries(n).map(([T,W])=>{const q=W.resources.filter(G=>!G.exists);return{[T]:q.map(G=>({applyTo:G.resource,type:G.type}))}}).reduce((T,W)=>({...T,...W}),{});if(L){const T=he.removeMultiplePermissions(D,n);d.actions.updatePrivileges(T)}};return O.jsxs(Mf,{className:"z-20 h-full flex-1 overflow-auto p-[15px] pt-0",style:{maxHeight:"calc(100vh - 5.5rem - 85px - 20px)"},children:[O.jsxs("table",{className:"relative h-full w-full",children:[O.jsx("thead",{className:"sticky top-0 z-20",children:O.jsxs("tr",{className:"border-b border-grey-100",children:[O.jsx("td",{className:"py-2",children:O.jsxs("div",{className:"flex items-center space-x-2",children:[O.jsx("div",{className:"relative w-56",children:O.jsx(yt.Root,{children:O.jsxs(yt.Group,{children:[O.jsx(yt.Icon,{children:O.jsx(_e.FdSearch,{})}),O.jsx(yt.Field,{type:"text",placeholder:"Search available permissions",value:v,onChange:L=>{b(L.target.value)}}),O.jsx(un.Popover,{className:"flex items-center",children:({open:L})=>O.jsxs(O.Fragment,{children:[O.jsx(un.Popover.Button,{ref:i,children:O.jsx(yt.Icon,{isAction:!0,children:O.jsx(_e.FdAdjust,{})})}),L&&O.jsx(Ef,{children:O.jsxs(un.Popover.Panel,{ref:s,style:c.popper,...u.popper,className:"z-50 rounded-md border border-grey-50 bg-grey-900 px-4 py-2.5",static:!0,children:[O.jsx("h5",{className:"mb-2 text-sm text-grey-50",children:"Filter"}),O.jsxs("div",{className:"space-y-2 text-s",children:[O.jsx("div",{className:"flex items-center",children:O.jsx(or,{value:f.includes("datastore"),onChange:()=>{w(["datastore"])},label:"Datastore",size:"sm"})}),O.jsx("div",{className:"flex items-center",children:O.jsx(or,{value:f.includes("dataclass"),onChange:()=>{w(["dataclass"])},label:"Dataclass",size:"sm"})}),O.jsx("div",{className:"flex items-center",children:O.jsx(or,{value:f.includes("singleton"),onChange:()=>{w(["singleton"])},label:"Singleton",size:"sm"})}),O.jsx("div",{className:"flex items-center",children:O.jsx(or,{value:f.some(D=>["method","singletonMethod","dsMethod","dataclassMethod","entityMethod","entityselMethod"].includes(D)),onChange:()=>{w(["method","singletonMethod","dsMethod","dataclassMethod","entityMethod","entityselMethod"])},label:"Functions",size:"sm"})}),O.jsx("div",{className:"flex items-center",children:O.jsx(or,{value:f.includes("attribute"),onChange:()=>{w(["attribute"])},label:"Attribute",size:"sm"})})]})]})})]})})]})})}),O.jsx(Pde,{privilegeId:g,privileges:n}),O.jsx("div",{children:O.jsxs(Id,{openDelay:0,closeDelay:0,children:[O.jsx(Pd,{children:O.jsx("button",{className:"flex h-6 items-center space-x-1 rounded-md px-2 text-sm text-grey-50 hover:bg-primary-hover",onClick:S,children:O.jsx(_e.FdReload,{})})}),O.jsx(Cn,{container:yr(),children:O.jsxs(Rn,{style:{zIndex:50},avoidCollisions:!0,side:"top",className:"mb-1 flex max-w-xs items-center gap-x-1 rounded bg-primary-light px-2 py-2 text-s font-semibold text-primary-darker",children:[O.jsx(_e.FdBulb,{className:"m-0.5 h-4 w-4 flex-shrink-0"}),O.jsx("p",{children:"Resetting the privilege will remove all configured ressources"})]})})]})}),O.jsxs(Id,{openDelay:0,closeDelay:0,children:[O.jsx(Pd,{children:O.jsx("button",{className:zt("flex h-6 items-center space-x-1 rounded-md px-2 text-sm text-grey-50 hover:bg-primary-hover disabled:opacity-50 disabled:hover:bg-primary-dark"),onClick:M,disabled:!j,children:O.jsx(_e.FdClean,{className:"h-4 w-4"})})}),O.jsx(Cn,{container:yr(),children:O.jsxs(Rn,{style:{zIndex:50},avoidCollisions:!0,side:"top",className:"mb-1 flex max-w-xs items-center gap-x-1 rounded bg-primary-light px-2 py-2 text-s font-semibold text-primary-darker",children:[O.jsx(_e.FdBulb,{className:"m-0.5 h-4 w-4 flex-shrink-0"}),O.jsx("p",{children:"Delete all the non existing resources from privileges"})]})})]})]})}),O.jsx("td",{className:"px-4 py-2 text-center text-[12px]",children:"Read"}),O.jsx("td",{className:"px-4 py-2 text-center text-[12px]",children:"Create"}),O.jsx("td",{className:"px-4 py-2 text-center text-[12px]",children:"Update"}),O.jsx("td",{className:"px-4 py-2 text-center text-[12px]",children:"Delete"}),O.jsx("td",{className:"px-4 py-2 text-center text-[12px]",children:"Execute"}),O.jsx("td",{className:"px-4 py-2 text-center text-[12px]",children:"Promote"})]})}),P.length?O.jsx("tbody",{children:P.map((L,D)=>{const T=L.permissions.some(W=>W.from.length>0);return O.jsxs("tr",{className:zt("group even:bg-grey-600",{"opacity-60":L.exists===!1}),children:[O.jsxs("td",{className:zt("group flex items-center gap-3 py-2 text-xs group-hover:rounded-l group-hover:bg-grey-300",L.exists===!1?"text-negative-400":"text-white",{"border-b-[0.5px] border-grey-300":!1}),children:[b$(L.type),L.resource,O.jsx(he.Tooltip,{placement:"top",label:"Remove Permission",isDisabled:T,container:yr(),children:O.jsx("button",{onClick:()=>{T?he.toastSubject.next({kind:"info",markdown:!0,message:`<div className="flex gap-x-3"><h3 className="font-bold">Info:</h3><p className="font-normal">Inherited permissions can't be removed</p></div>`,customIcon:_e.FdInfoBold}):E({applyTo:L.resource,type:L.type})},className:zt("flex flex-shrink-0 items-center justify-center rounded p-1 opacity-0 group-hover:opacity-100",T?"hover:bg-grey-300 group-hover:opacity-70":"hover:bg-primary-hover"),children:O.jsx(_e.FdPlus,{className:"h-4 w-4 rotate-45 transform text-white"})})})]}),O.jsx("td",{className:"py-2 text-center group-hover:bg-grey-300",children:O.jsx(aa,{permissions:L.permissions,showIncluded:r,label:"read",onToggle:W=>A(L,W),onSelect:t,privileges:n,exists:L.exists})}),O.jsx("td",{className:"py-2 text-center group-hover:bg-grey-300",children:O.jsx(aa,{permissions:L.permissions,showIncluded:r,label:"create",onToggle:W=>A(L,W),onSelect:t,privileges:n,exists:L.exists})}),O.jsx("td",{className:"py-2 text-center group-hover:bg-grey-300",children:O.jsx(aa,{permissions:L.permissions,showIncluded:r,label:"update",onToggle:W=>A(L,W),onSelect:t,privileges:n,exists:L.exists})}),O.jsx("td",{className:"py-2 text-center group-hover:bg-grey-300",children:O.jsx(aa,{permissions:L.permissions,showIncluded:r,label:"drop",onToggle:W=>A(L,W),onSelect:t,privileges:n,exists:L.exists})}),O.jsx("td",{className:"py-2 text-center group-hover:bg-grey-300",children:O.jsx(aa,{promoted:x[L.resource],permissions:L.permissions,showIncluded:r,label:"execute",onToggle:W=>A(L,W),onSelect:t,privileges:n,exists:L.exists})}),O.jsx("td",{className:"py-2 text-center group-hover:rounded-r group-hover:bg-grey-300 ",children:O.jsx(aa,{permissions:L.permissions,showIncluded:r,label:"promote",onToggle:W=>A(L,W),onSelect:t,privileges:n,exists:L.exists})})]},D)})}):null]}),!N.length&&v?O.jsx(PL,{children:"The Permission you're looking for can't be found "}):null,!N.length&&!v?O.jsxs(PL,{children:["This Privilege has no Permissions configured yet ",O.jsx("br",{}),'Add a new permission by using the "Create a permission" input above']}):null]})},kde=({onCreate:e})=>{const t=dr(),r=t.getPrivileges(),[n,o]=R.useState(null),[i,a]=R.useState(null),[s,c]=R.useState(""),[u,d]=R.useState(null),{styles:f,attributes:h}=Bd(n,i,{modifiers:[{name:"offset",options:{offset:[-10,10]}}],placement:"right-start"});return R.useEffect(()=>{c(""),d(null)},[i]),O.jsx(un.Popover,{children:({open:v,close:b})=>O.jsxs(O.Fragment,{children:[O.jsx(un.Popover.Button,{className:"rounded p-1 hover:bg-primary-hover","data-cy":"New-priv-btn",ref:o,children:O.jsx("span",{children:O.jsx(_e.FdPlus,{className:"h-4 w-4 text-white"})})}),v&&O.jsx(Ef,{children:O.jsx(un.Popover.Panel,{ref:a,style:f.popper,...h.popper,"data-cy":"New-priv-pop-up",className:"z-50",static:!0,children:O.jsxs(fn,{className:"min-w-[256px] border rounded px-4 py-2 text-xs shadow-md",depth:3,borderType:"light",children:[O.jsx("h5",{className:"mb-2 text-xs font-semibold",children:"Create New Privilege"}),O.jsx("div",{className:"mt-2",children:O.jsxs("label",{className:"flex items-center space-x-4",children:[O.jsx("span",{children:"Name"}),O.jsxs(yt.Root,{className:"w-full",color:u?"negative":"primary",children:[O.jsx(yt.Group,{children:O.jsx(yt.Field,{autoFocus:!0,value:s,onChange:g=>c(g.target.value),onKeyDown:g=>{if(g.key==="Enter"){d(null);try{const m=he.createPrivilege(s,r),x=t.actions.updatePrivileges(m),w=Object.values(x.payload).find(E=>E.privilege===s);w&&(e(w),b())}catch(m){d(m.message)}}},type:"text"})}),u&&O.jsx(yt.Message,{children:u})]})]})}),O.jsxs("div",{className:"mt-4 flex items-center justify-center space-x-2",children:[O.jsx("button",{className:"rounded border border-primary-dark bg-primary-dark px-4 py-1 hover:border-primary-hover hover:bg-primary-hover",onClick:()=>{d(null);try{const g=he.createPrivilege(s,r),m=t.actions.updatePrivileges(g),x=Object.values(m.payload).find(w=>w.privilege===s);x&&e(x),b()}catch(g){d(g.message)}},children:"Create"}),O.jsx("button",{className:"rounded border border-grey-100 px-4 py-1 text-grey-100 hover:bg-white hover:text-primary-dark",onClick:()=>b(),children:"Cancel"})]})]})})})]})})},Dde=()=>{const e=dr(),t=e.getCatalog(),r=e.getPrivileges(),n=R.useMemo(()=>{if(t===null)return r;const u=XB(r,Object.values((t==null?void 0:t.dataClasses)??{}));return ZB(u,t)},[r,t]),[o,i]=R.useState(null),a=R.useMemo(()=>Object.keys(n),[n]);R.useEffect(()=>{o&&n[o.id]||!a.length||i(n[a[0]])},[n]),R.useEffect(()=>{a.length<2&&c(!0)},[a.length]);const[s,c]=R.useState(!0);return O.jsxs("div",{className:"flex flex-1 h-full",children:[O.jsxs(fn,{depth:1,className:"flex h-full w-[356px] flex-col",children:[O.jsxs("div",{className:"flex flex-shrink-0 items-center justify-between px-3.5 py-[10px]",children:[O.jsxs("div",{className:"flex items-center space-x-1 text-[#DDE1E6]",children:[O.jsx("span",{children:O.jsx(_e.FdGroup,{className:"h-[14px] w-[14px]"})}),O.jsx("span",{className:"text-[11px] font-semibold",children:"Privileges"})]}),O.jsx(kde,{onCreate:u=>{i(u)}})]}),O.jsx(tce,{privileges:n,selectedPrivilege:o,selectPrivilege:u=>{i(u)}})]}),o&&n[o.id]?O.jsxs(fn,{depth:1,className:"privileges-container relative flex flex-1 flex-col overflow-x-auto border-l-[0.5px]",children:[O.jsxs("div",{className:"mb-1 flex h-full w-full flex-col items-stretch",children:[o.privilege!=="guest"?O.jsx(Jae,{privileges:n,selectedPrivilege:o,onSelect:u=>i(r[u]),setShowIncluded:c,showIncluded:s}):null,O.jsx(Ade,{privileges:n,selectedPrivilege:o,onSelect:u=>i(r[u]),showIncluded:s})]}),O.jsx(Mde,{privileges:n,selectedPrivilege:o,setSelectedPrivilege:i})]}):O.jsx(M5,{tab:"Privilege"})]})},Mde=({privileges:e,selectedPrivilege:t,setSelectedPrivilege:r})=>{const[n,o]=R.useState(!1);return O.jsx(he.Panel,{path:he.ROLES_TAB_PATH,isOpen:n,onOpen:()=>o(!0),onClose:()=>o(!1),children:O.jsx("div",{className:"h-full w-full px-3 pb-3",children:O.jsx(fn,{depth:2,className:"h-full w-full rounded",children:O.jsx(lae,{dict:e,data:he.getGraphData(t.id,e),onSelect:i=>r(e[i])})})})})},jde=({role:e})=>{var _;const t=dr(),[r,n]=R.useState(e),[o,i]=R.useState(e.role),[a,s]=R.useState(null),c=t.getPrivileges(),u=((_=r.privileges)==null?void 0:_.filter(C=>c[C]&&c[C].privilege!=="guest").length)||0,d=t.getRoles(),{selectedRole:f,selectRole:h}=d1(),[v,b]=R.useState(!1),g=he.useOutsideClick(()=>{v&&x()});he.useDidMountEffect(()=>{o!==e.role&&i(e.role)},[e.role]),R.useEffect(()=>{e.role||b(!0)},[]),R.useEffect(()=>{n(e)},[e]);const m=()=>{s(null),b(!0)},x=()=>{s(null),e.role&&e.role===o&&b(!1);try{const C=he.saveRole({...r,role:o},d);t.actions.updateRoles(C),b(!1)}catch(C){s(C.message)}},w=async C=>{C.stopPropagation();const{confirmed:N}=await t.actions.openModal({title:"Delete Role",type:he.ModalType.CONFIRM,color:he.ModalColor.DANGER,message:"Are you sure you want to remove this Role?",icon:"FdWarningDanger"});N&&E()},E=()=>{const C=he.removeRole(r.id,d),N=Object.keys(C);if(f!==r.id){dispatch(updateRoles(C));return}if(N.length===0)h(null);else{const P=Object.keys(d),A=P.indexOf(r.id),j=Math.max(0,A-1),M=P[j];A===0?h(N[0]):C[M]?h(M):h(N[0])}t.actions.updateRoles(C)},S=(C=null)=>{if(C&&C.stopPropagation(),!e.role){E();return}b(!1),i(e.role)};return O.jsx(O.Fragment,{children:O.jsxs(fn,{depth:4,borderType:f===r.id?"primary":f!==r.id?"light":"default",className:zt("rounded border p-2"),role:"button","data-cy":"privilegeCard",onClick:()=>{h(r.id)},ref:g,children:[O.jsx("div",{className:"flex items-center justify-between",children:O.jsxs("div",{className:"flex flex-1 items-center",children:[O.jsx("span",{className:"mr-4",children:O.jsx(_e.FdGroup,{className:"h-6 w-6"})}),v?O.jsxs(yt.Root,{color:a?"negative":"primary",className:"flex-1 mr-2",children:[O.jsx(yt.Group,{children:O.jsx(yt.Field,{type:"text",value:o,onChange:({target:{value:C}})=>{i(C)},onKeyDown:C=>{C.key==="Enter"&&x(),C.key==="Escape"&&S()},onBlur:()=>S(),placeholder:"role",autoComplete:"off",autoFocus:!0})}),a&&O.jsx(yt.Message,{children:a})]}):O.jsx("span",{className:"inline-block grow overflow-hidden truncate whitespace-nowrap text-xs font-bold",title:o,children:r.role}),O.jsx("div",{className:zt("justify-between ml-auto flex w-fit items-center gap-x-2"),children:v?O.jsxs(O.Fragment,{children:[O.jsx("button",{onClick:x,className:"rounded p-1 hover:bg-primary-hover hover:text-white",children:O.jsx(_e.FdSave,{className:"h-4 w-4 text-grey-50"})}),O.jsx("button",{onClick:S,className:"rounded p-1 hover:bg-primary-hover hover:text-white",children:O.jsx(_e.FdClose,{className:"h-4 w-4 text-grey-50"})})]}):O.jsxs(O.Fragment,{children:[O.jsx("button",{onClick:m,className:"rounded p-1 hover:bg-primary-hover hover:text-white",children:O.jsx(_e.FdPen,{className:"h-4 w-4 text-grey-50"})}),O.jsx("button",{onClick:C=>w(C),className:"rounded p-1 hover:bg-primary-hover hover:text-white",children:O.jsx(_e.FdTrash,{className:"h-4 w-4 text-grey-50"})})]})})]})}),O.jsxs("span",{className:zt("ml-[43px] py-1 text-xs"),children:[u," Privilege",u>1?"s":""]})]})})},y$=(e,t)=>e?t[e]:null,TL=(e,t,r)=>{const n=y$(e,r);return n?Object.values(r).reduce((o,i)=>i.id===e?n.privileges.includes(t)?{...o,[n.id]:{...n,privileges:n.privileges.filter(a=>a!==t)}}:{...o,[n.id]:{...n,privileges:[...n.privileges,t]}}:{...o,[i.id]:i},{}):r},Lde=()=>{const e=dr(),t=e.getPrivileges(),r=e.getRoles(),{selectedRole:n}=d1(),o=y$(n,r),i=(a,s)=>s&&s.privileges.includes(a.id);return O.jsxs("div",{className:"w-full border-b border-grey-900 p-4 ",children:[O.jsx("div",{className:"mb-4 flex items-center gap-x-5 text-white",children:O.jsx("h4",{className:"text-[13px] font-semibold ",children:"Privileges"})}),O.jsxs("div",{className:"flex flex-wrap items-center gap-1",children:[O.jsx("div",{"data-cy":"item=>Permisions",className:zt("inline-flex items-center gap-1 space-x-1 rounded bg-primary-darker px-2 py-0.5 text-xs font-semibold italic text-white"),children:"guest"}),Object.values(t).filter(a=>i(a,o)&&a.privilege!=="guest").map((a,s)=>O.jsxs("div",{"data-cy":"item=>Permisions",className:zt("inline-flex cursor-pointer items-center gap-1 space-x-1 rounded px-2 py-0.5",{"bg-primary-dark text-white":i(a,o),"bg-grey-300 text-grey-100":!i(a,o)}),onClick:()=>{const c=TL(o.id,a.id,r);e.actions.updateRoles(c)},children:[O.jsx("span",{className:"text-xs",children:a.privilege}),O.jsx("button",{className:"focus:outline-none",children:i(a,o)?O.jsx(_e.FdMinus,{className:"h-[14px] w-[14px]"}):O.jsx(_e.FdPlus,{className:"h-[14px] w-[14px]"})})]},s)),Object.values(t).filter(a=>!i(a,o)&&a.privilege!=="guest").map((a,s)=>O.jsxs("div",{"data-cy":"item=>Permisions",className:zt("inline-flex cursor-pointer items-center gap-1 space-x-1 rounded px-2 py-0.5",{"bg-primary-dark text-white":i(a,o),"bg-grey-300 text-grey-100":!i(a,o)}),onClick:()=>{const c=TL(o.id,a.id,r);e.actions.updateRoles(c)},children:[O.jsx("span",{className:"text-xs",children:a.privilege}),O.jsx("button",{className:"text-white focus:outline-none",children:i(a,o)?O.jsx(_e.FdMinus,{className:"h-[14px] w-[14px]"}):O.jsx(_e.FdPlus,{className:"h-[14px] w-[14px]"})})]},s))]})]})},qde=({children:e})=>O.jsx("div",{className:"h-full w-full",children:O.jsx("div",{className:"flex h-full w-full flex-1 items-center justify-center",children:O.jsxs("div",{className:"flex flex-col items-center justify-center space-y-4 py-4",children:[O.jsx(_e.FdInfoBold,{className:"absolute -right-full h-10 w-10 translate-x-1"}),O.jsx("div",{className:"text-center text-sm",children:e})]})})}),H_=(e,t,r,n=!1)=>{const o=e.applyTo,i=e.type===he.EPermissionType.DATACLASS?"ds":o.split(".")[0],a={...t,...r},s=()=>({value:!n,inherited:!1,from:[],explicitly:!1}),c={read:s(),create:s(),update:s(),drop:s(),execute:s(),promote:s()},u=f=>{f.forEach(h=>{a[h]&&(a[h].resources.forEach(v=>{if(v.resource===o||v.resource===i){const b=H_(e,t,{[h]:a[h]},n);Object.values(v.permissions).forEach(g=>{c[g.name].explicitly||(!c[g.name].from.includes(a[h].privilege)&&g.checked&&c[g.name].from.push(a[h].privilege),c[g.name].inherited=c[g.name].inherited||b[g.name].value||b[g.name].inherited)})}}),a[h].includes.length>0&&u(a[h].includes))})};if(Object.values(r).forEach(f=>{f.resources.forEach(h=>{h.resource===o&&Object.values(h.permissions).forEach(v=>{v.checked&&(c[v.name].explicitly=!0,n&&(c[v.name].value=!0))})}),(f.includes.length>0||f.privilege==="guest")&&u(f.includes)}),Object.values(t).forEach(f=>{f.resources.forEach(h=>{h.resource===o&&(f.privilege==="guest"?Object.values(h.permissions).forEach(v=>{v.checked&&(c[v.name].explicitly=!0,n&&(c[v.name].value=!0))}):Object.values(h.permissions).forEach(v=>{!c[v.name].explicitly&&v.checked&&(n?c[v.name].value=!0:c[v.name].value=!1)}))})}),(n?Object.entries(c).some(([f,h])=>f!=="promote"&&!h.value&&!h.explicitly):Object.entries(c).some(([f,h])=>f!=="promote"&&h.value&&!h.explicitly))&&![he.EPermissionType.DATASTORE,he.EPermissionType.SINGLETON].includes(e.type)){const f={applyTo:i,type:e.type===he.EPermissionType.DATACLASS?he.EPermissionType.DATASTORE:e.type===he.EPermissionType.SINGLETON_METHOD?he.EPermissionType.SINGLETON:he.EPermissionType.DATACLASS},h=H_(f,t,r,n),v=b=>{let g=c[b].value;return n?!c[b].value&&!c[b].explicitly&&(g=h[b].value):c[b].value&&!c[b].explicitly&&(g=h[b].value),{value:g,inherited:c[b].inherited||h[b].inherited,from:c[b].from.length>0?c[b].from:h[b].from,explicitly:c[b].explicitly}};return{read:v("read"),create:v("create"),update:v("update"),drop:v("drop"),execute:v("execute"),promote:v("promote")}}return{read:c.read,create:c.create,update:c.update,drop:c.drop,execute:c.execute,promote:c.promote}},zde=e=>{switch(e){case"dataclass":return O.jsx(_e.FdTableHeader,{className:"h-6 w-6"});case"singleton":return O.jsx(_e.FdSingleton,{className:"h-6 w-6"});case"datastore":return O.jsx(_e.FdModel3,{className:"h-6 w-6"});case"attribute":return O.jsx(_e.FdTableColumn,{className:"h-6 w-6"});case"method":return O.jsx(_e.FdCode,{className:"h-6 w-6"});case"singletonMethod":return O.jsx(_e.FdFunctionSingleton,{className:"h-6 w-6"});case"entityselMethod":return O.jsx(_e.FdFunctionSelection,{className:"h-6 w-6"});case"entityMethod":return O.jsx(_e.FdFunctionEntity,{className:"h-6 w-6"});case"dsMethod":return O.jsx(_e.FdFunctionDatastore,{className:"h-6 w-6"});case"dataclassMethod":return O.jsx(_e.FdFunctionDataclass,{className:"h-6 w-6"});default:return O.jsx(_e.FdTableHeader,{className:"h-6 w-6"})}},Ls=sE,qs=lE,wa=({privileges:e,permission:t,hasChild:r,depth:n,isChild:o=!1,className:i,inSearch:a,toggleCollapse:s,collapsed:c,isRestrictedByDefault:u,toastMessageCallback:d})=>{const[f,h]=t.applyTo.split("."),v=R.useMemo(()=>H_(t,e.otherPrivs,e.rolePrivs,u),[e,t,u]);return O.jsxs("tr",{className:zt("group even:bg-grey-600",i),children:[O.jsxs("td",{className:zt("flex h-full w-full items-center gap-3 p-0 text-xs group-hover:rounded-l group-hover:bg-grey-300",{"px-1":a}),children:[Array(n).fill("").map((b,g)=>O.jsx("div",{className:zt("ml-1.5 mr-1 h-full w-0.5 border-l-2 border-grey-100",{"mr-0.5":o})},g)),r&&O.jsx("button",{onClick:s,className:"w-3",children:c?O.jsx(_e.FdRight,{className:"inline h-4 w-4"}):O.jsx(_e.FdDown,{className:"inline h-4 w-4"})}),zde(t.type),a?t.applyTo:h||f]}),O.jsx("td",{className:"py-2 text-center group-hover:bg-grey-300",children:[he.EPermissionType.ATTRIBUTE,he.EPermissionType.DATASTORE,he.EPermissionType.DATACLASS].includes(t.type)&&O.jsxs("div",{className:"relative mx-auto flex w-fit items-center justify-center gap-x-1",children:[O.jsx(or,{value:v.read.value||v.read.inherited,onClick:d,isDisabled:!0}),O.jsx("div",{className:"absolute left-full top-1/2 flex -translate-y-1/2 translate-x-1/2 cursor-pointer items-center",children:!v.read.value&&v.read.inherited?O.jsxs(Ls,{openDelay:0,closeDelay:0,children:[O.jsx(qs,{children:O.jsx(_e.FdInfoBold,{className:"h-4 w-4 text-white"})}),O.jsx(Cn,{container:yr(),children:O.jsx(Rn,{style:{zIndex:50},avoidCollisions:!0,side:"top",className:"max-w-xs rounded bg-primary-light py-2 text-sm font-semibold text-primary",children:O.jsx("div",{className:"space-y-1 px-2",children:v.read.from.length?O.jsxs("div",{className:"flex items-start text-s",children:[O.jsx(_e.FdBulb,{className:"mr-2 mt-0.5 h-4 w-4 flex-shrink-0"}),O.jsxs("p",{children:[O.jsx("span",{className:"mr-1",children:"Permission inherited from:"}),O.jsx("ul",{children:v.read.from.map((b,g)=>O.jsx("li",{className:"cursor-pointer list-disc font-bold",children:b},g))})]})]}):null})})})]}):""})]})}),O.jsx("td",{className:"py-2 text-center group-hover:bg-grey-300",children:[he.EPermissionType.ATTRIBUTE,he.EPermissionType.DATASTORE,he.EPermissionType.DATACLASS].includes(t.type)&&O.jsxs("div",{className:"relative mx-auto flex w-fit items-center justify-center gap-x-1",children:[O.jsx(or,{value:v.create.value||v.create.inherited,onClick:d,isDisabled:!0}),O.jsx("div",{className:"absolute left-full top-1/2 flex -translate-y-1/2 translate-x-1/2 cursor-pointer items-center",children:!v.create.value&&v.create.inherited?O.jsxs(Ls,{openDelay:0,closeDelay:0,children:[O.jsx(qs,{children:O.jsx(_e.FdInfoBold,{className:"h-4 w-4 text-white"})}),O.jsx(Cn,{container:yr(),children:O.jsx(Rn,{style:{zIndex:50},avoidCollisions:!0,side:"top",className:"max-w-xs rounded bg-primary-light py-2 text-sm font-semibold text-primary",children:O.jsx("div",{className:"space-y-1 px-2",children:v.create.from.length?O.jsxs("div",{className:"flex items-start text-s",children:[O.jsx(_e.FdBulb,{className:"mr-2 mt-0.5 h-4 w-4 flex-shrink-0"}),O.jsxs("p",{children:[O.jsx("span",{className:"mr-1",children:"Permission inherited from:"}),O.jsx("ul",{children:v.create.from.map((b,g)=>O.jsx("li",{className:"cursor-pointer list-disc font-bold",children:b},g))})]})]}):null})})})]}):""})]})}),O.jsx("td",{className:"py-2 text-center group-hover:bg-grey-300",children:[he.EPermissionType.ATTRIBUTE,he.EPermissionType.DATASTORE,he.EPermissionType.DATACLASS].includes(t.type)&&O.jsxs("div",{className:"relative mx-auto flex w-fit items-center justify-center gap-x-1",children:[O.jsx(or,{value:v.update.value||v.update.inherited,onClick:d,isDisabled:!0}),O.jsx("div",{className:"absolute left-full top-1/2 flex -translate-y-1/2 translate-x-1/2 cursor-pointer items-center",children:!v.update.value&&v.update.inherited?O.jsxs(Ls,{openDelay:0,closeDelay:0,children:[O.jsx(qs,{children:O.jsx(_e.FdInfoBold,{className:"h-4 w-4 text-white"})}),O.jsx(Cn,{container:yr(),children:O.jsx(Rn,{style:{zIndex:50},avoidCollisions:!0,side:"top",className:"max-w-xs rounded bg-primary-light py-2 text-sm font-semibold text-primary",children:O.jsx("div",{className:"space-y-1 px-2",children:v.update.from.length?O.jsxs("div",{className:"flex items-start text-s",children:[O.jsx(_e.FdBulb,{className:"mr-2 mt-0.5 h-4 w-4 flex-shrink-0"}),O.jsxs("p",{children:[O.jsx("span",{className:"mr-1",children:"Permission inherited from:"}),O.jsx("ul",{children:v.update.from.map((b,g)=>O.jsx("li",{className:"cursor-pointer list-disc font-bold",children:b},g))})]})]}):null})})})]}):""})]})}),O.jsx("td",{className:"py-2 text-center group-hover:bg-grey-300",children:[he.EPermissionType.ATTRIBUTE,he.EPermissionType.DATASTORE,he.EPermissionType.DATACLASS].includes(t.type)&&O.jsxs("div",{className:"relative mx-auto flex w-fit items-center justify-center gap-x-1",children:[O.jsx(or,{value:v.drop.value||v.drop.inherited,onClick:d,isDisabled:!0}),O.jsx("div",{className:"absolute left-full top-1/2 flex -translate-y-1/2 translate-x-1/2 cursor-pointer items-center",children:!v.drop.value&&v.drop.inherited?O.jsxs(Ls,{openDelay:0,closeDelay:0,children:[O.jsx(qs,{children:O.jsx(_e.FdInfoBold,{className:"h-4 w-4 text-white"})}),O.jsx(Cn,{container:yr(),children:O.jsx(Rn,{style:{zIndex:50},avoidCollisions:!0,side:"top",className:"max-w-xs rounded bg-primary-light py-2 text-sm font-semibold text-primary",children:O.jsx("div",{className:"space-y-1 px-2",children:v.drop.from.length?O.jsxs("div",{className:"flex items-start text-s",children:[O.jsx(_e.FdBulb,{className:"mr-2 mt-0.5 h-4 w-4 flex-shrink-0"}),O.jsxs("p",{children:[O.jsx("span",{className:"mr-1",children:"Permission inherited from:"}),O.jsx("ul",{children:v.drop.from.map((b,g)=>O.jsx("li",{className:"cursor-pointer list-disc font-bold",children:b},g))})]})]}):null})})})]}):""})]})}),O.jsx("td",{className:"py-2 text-center group-hover:rounded-r group-hover:bg-grey-300",children:t.type!=="attribute"&&O.jsxs("div",{className:"relative mx-auto flex w-fit items-center justify-center gap-x-1",children:[O.jsx(or,{value:v.execute.value||v.execute.inherited,onClick:d,isDisabled:!0}),O.jsx("div",{className:"absolute left-full top-1/2 flex -translate-y-1/2 translate-x-1/2 cursor-pointer items-center",children:!v.execute.value&&v.execute.inherited?O.jsxs(Ls,{openDelay:0,closeDelay:0,children:[O.jsx(qs,{children:O.jsx(_e.FdInfoBold,{className:"h-4 w-4 text-white"})}),O.jsx(Cn,{container:yr(),children:O.jsx(Rn,{style:{zIndex:50},avoidCollisions:!0,side:"top",className:"max-w-xs rounded bg-primary-light py-2 text-sm font-semibold text-primary",children:O.jsx("div",{className:"space-y-1 px-2",children:v.execute.from.length?O.jsxs("div",{className:"flex items-start text-s",children:[O.jsx(_e.FdBulb,{className:"mr-2 mt-0.5 h-4 w-4 flex-shrink-0"}),O.jsxs("p",{children:[O.jsx("span",{className:"mr-1",children:"Permission inherited from:"}),O.jsx("ul",{children:v.execute.from.map((b,g)=>O.jsx("li",{className:"cursor-pointer list-disc font-bold",children:b},g))})]})]}):null})})})]}):""})]})})]})},AL=({depth:e,permission:t,privileges:r,childCollapsed:n,didChildCollapsed:o,toastMessageCallback:i})=>{const[a,s]=R.useState(n),c=dr(),u=c.getRestrictedByDefault(),d=c.getPrivileges();return R.useEffect(()=>{n===!0&&s(!0)},[n]),O.jsxs(O.Fragment,{children:[O.jsx(wa,{privileges:r,permission:t,isChild:!0,depth:e,hasChild:!0,toggleCollapse:()=>{const f=!a;s(f),o==null||o(f)},isRestrictedByDefault:u,allPrivileges:d,collapsed:a,toastMessageCallback:i}),!a&&O.jsxs(O.Fragment,{children:[t.attributes.map((f,h)=>O.jsx(wa,{privileges:r,permission:f,depth:e+1,isRestrictedByDefault:u,allPrivileges:d,toastMessageCallback:i},`${f.type}-${h}`)),t.methods.map((f,h)=>O.jsx(wa,{privileges:r,permission:f,depth:e+1,isRestrictedByDefault:u,allPrivileges:d,toastMessageCallback:i},`${f.type}-${h}`))]})]})},Bde=({selectedRole:e})=>{const[t,r]=R.useState(null),[n,o]=R.useState(null),{styles:i,attributes:a}=Bd(t,n,{modifiers:[{name:"offset",options:{offset:[0,10]}}]}),s=dr(),c=s.getRestrictedByDefault(),u=s.getPrivileges(),[d,f]=R.useState([]),[h,v]=R.useState(""),b=s.getCatalogMethods(),g=s.getDataclasses(),m=s.getSingletons(),[x,w]=R.useState({}),[E,S]=R.useState([]);R.useEffect(()=>{const q=uae(b,Object.values(g),Object.values(m));w(q)},[e]);function _(q){const G=["datastore","singleton","dataclass","attribute","dsMethod","dataclassMethod","entityMethod","entityselMethod","singletonMethod"];return q.sort((F,J)=>{const z=G.indexOf(F.type),U=G.indexOf(J.type);return z!==U?z-U:F.applyTo.toLowerCase()>J.applyTo.toLowerCase()?1:-1})}R.useEffect(()=>{S(_(Y1(h,b,Object.values(g),Object.values(m)).filter(q=>d.length?d.includes(q.type):!0)))},[d,h]);const[C,N]=R.useState(!1),P=q=>{f(G=>G.some(F=>q.includes(F))?G.filter(F=>!q.includes(F)):[...G,...q])},A=s.getRoles(),j={toggleAllCollapsed:q=>{q.allCollapsed=!q.allCollapsed},toggleChildCollapsed:q=>{q.childCollapsed=!q.childCollapsed},setAllCollapsed:(q,G)=>{q.allCollapsed=G},setChildCollapsed:(q,G)=>{q.childCollapsed=G}},M=R.useMemo(()=>{const q=Object.values(u).find(U=>U.privilege==="guest"),G=A[e],F=G?Object.fromEntries(G.privileges.map(U=>[U,u[U]]).filter(([,U])=>!!U)):{};if(c)return{rolePrivs:F,otherPrivs:q?{[q.id]:q}:{}};const J=q?{[q.id]:{...q,active:!0}}:{},z=Object.fromEntries(Object.entries(u).filter(([U])=>U!==(q==null?void 0:q.id)&&!(G!=null&&G.privileges.includes(U))).map(([U,oe])=>[U,{...oe,active:!1}]));return{rolePrivs:F,otherPrivs:{...J,...z}}},[u,A,e,c]),{state:{allCollapsed:L,childCollapsed:D},dispatch:T}=he.useEnhancedState({allCollapsed:!1,childCollapsed:!1},j,"Table Collapse Store"),W=()=>{he.toastSubject.next({kind:"info",markdown:!0,message:"**Info:** You can add or modify permissions only in the Privilege section.",customIcon:_e.FdInfoCircle})};return O.jsxs(Mf,{className:"z-20 h-full flex-1 overflow-auto p-[15px] pt-0",style:{maxHeight:"calc(100vh - 5.5rem - 85px - 20px)"},children:[O.jsxs("table",{className:"relative h-full w-full",children:[O.jsx("thead",{className:"sticky top-0 z-20",children:O.jsxs("tr",{className:"border-b border-grey-100",children:[O.jsx("td",{className:"py-2",children:O.jsxs("div",{className:"flex items-center space-x-2",children:[O.jsx(he.Tooltip,{label:"Collapse All",placement:"top",container:yr(),children:O.jsx("button",{onClick:()=>{D?(T.setAllCollapsed(!0),N(!0)):T.setChildCollapsed(!0)},className:zt("cursor-pointer rounded-md p-1 hover:bg-primary-hover focus:outline-none",{"pointer-events-none text-grey-200":L,"text-white":!L}),children:O.jsx(_e.FdCollapseAll,{className:"h-4 w-4"})})}),O.jsx("div",{className:"relative w-56",children:O.jsx(yt.Root,{children:O.jsxs(yt.Group,{children:[O.jsx(yt.Icon,{children:O.jsx(_e.FdSearch,{})}),O.jsx(yt.Field,{type:"text",placeholder:"Search",value:h,onChange:q=>{v(q.target.value)}}),O.jsx(un.Popover,{className:"flex items-center",children:({open:q})=>O.jsxs(O.Fragment,{children:[O.jsx(un.Popover.Button,{ref:r,children:O.jsx(yt.Icon,{isAction:!0,children:O.jsx(_e.FdAdjust,{})})}),q&&O.jsx(Ef,{children:O.jsxs(un.Popover.Panel,{ref:o,style:i.popper,...a.popper,className:"z-50 rounded-md border border-grey-50 bg-grey-900 px-4 py-2.5 text-xs text-grey-50",static:!0,children:[O.jsx("h5",{className:"mb-2 text-sm",children:"Filter"}),O.jsxs("div",{className:"space-y-2 text-s",children:[O.jsx("div",{className:"flex items-center",children:O.jsx(or,{value:d.includes("datastore"),onChange:()=>{P(["datastore"])},label:"Datastore",size:"sm"})}),O.jsx("div",{className:"flex items-center",children:O.jsx(or,{value:d.includes("dataclass"),onChange:()=>{P(["dataclass"])},label:"Dataclass",size:"sm"})}),O.jsx("div",{className:"flex items-center",children:O.jsx(or,{value:d.includes("singleton"),onChange:()=>{P(["singleton"])},label:"Singleton",size:"sm"})}),O.jsx("div",{className:"flex items-center",children:O.jsx(or,{value:d.some(G=>["method","singletonMethod","dsMethod","dataclassMethod","entityMethod","entityselMethod"].includes(G)),onChange:()=>{P(["method","singletonMethod","dsMethod","dataclassMethod","entityMethod","entityselMethod"])},label:"Functions",size:"sm"})}),O.jsx("div",{className:"flex items-center",children:O.jsx(or,{value:d.includes("attribute"),onChange:()=>{P(["attribute"])},label:"Attribute",size:"sm"})})]})]})})]})})]})})})]})}),O.jsx("td",{className:"px-4 py-2 text-center text-[12px]",children:"read"}),O.jsx("td",{className:"px-4 py-2 text-center text-[12px]",children:"Create"}),O.jsx("td",{className:"px-4 py-2 text-center text-[12px]",children:"Update"}),O.jsx("td",{className:"px-4 py-2 text-center text-[12px]",children:"Delete"}),O.jsx("td",{className:"px-4 py-2 text-center text-[12px]",children:"Execute"})]})}),O.jsx("tbody",{className:"relative",children:d.length||h?E.map((q,G)=>O.jsx(wa,{privileges:M,permission:q,depth:0,inSearch:!0,isRestrictedByDefault:c,allPrivileges:u,toastMessageCallback:W},`${q.type}-${G}`)):Object.values(x).map((q,G)=>O.jsxs(R.Fragment,{children:[O.jsx(wa,{privileges:M,permission:q,isRestrictedByDefault:c,allPrivileges:u,hasChild:!0,depth:0,toggleCollapse:()=>{const F=!C;N(F),T.setAllCollapsed(!F&&L?!1:L)},collapsed:C,toastMessageCallback:W}),q.type==="datastore"&&!C?O.jsxs(O.Fragment,{children:[q.methods.map((F,J)=>O.jsx(wa,{privileges:M,isRestrictedByDefault:c,allPrivileges:u,permission:F,depth:1,collapsed:L||!1,toastMessageCallback:W},`${F.type}-${J}`)),q.dataClasses.map((F,J)=>O.jsx(AL,{depth:1,privileges:M,permission:F,childCollapsed:D,didChildCollapsed:z=>{T.setChildCollapsed(z?D:!1)},toastMessageCallback:W},`${F.type}-${J}`))]}):null,q.singletons.map((F,J)=>O.jsx(AL,{depth:0,privileges:M,permission:F,childCollapsed:L,didChildCollapsed:z=>{T.setAllCollapsed(z?L:!1)},toastMessageCallback:W},`${F.type}-${J}`))]},`${q.type}-${G}`))})]}),(h||d.length)&&!E.length?O.jsx(qde,{children:"The Permission you're looking for can't be found "}):null]})},Fde=()=>{const e=dr(),t=e.getRoles(),[r,n]=R.useState(null),[o,i]=R.useState(null),[a,s]=R.useState(""),[c,u]=R.useState(null),{styles:d,attributes:f}=Bd(r,o,{modifiers:[{name:"offset",options:{offset:[-10,10]}}],placement:"right-start"});R.useEffect(()=>{s(""),u(null)},[o]);const h=()=>{if(!a)throw new Error("Please enter a valid name");if(Object.values(t).find(m=>m.role.toLowerCase()===a.toLowerCase()))throw new Error(`A role with the name ${a} already exists`);const b=sF.generate(),g=he.createRole(b,a,t);e.actions.updateRoles(g)};return O.jsx(un.Popover,{children:({open:v,close:b})=>{const g=()=>{u(null);try{he.validateName(a),h(),b()}catch(m){u(m.message)}};return O.jsxs(O.Fragment,{children:[O.jsx(un.Popover.Button,{className:"rounded p-1 hover:bg-primary-hover","data-cy":"New-priv-btn",ref:n,children:O.jsx("span",{children:O.jsx(_e.FdPlus,{className:"h-4 w-4 text-white"})})}),v&&O.jsx(Ef,{children:O.jsx(un.Popover.Panel,{ref:i,style:d.popper,...f.popper,"data-cy":"New-priv-pop-up",className:"z-50",static:!0,children:O.jsxs(fn,{className:"min-w-[256px] border rounded px-4 py-2 text-xs shadow-md",depth:3,borderType:"light",children:[O.jsx("h5",{className:"mb-2 text-xs font-semibold",children:"Create New Role"}),O.jsx("div",{className:"mt-2",children:O.jsxs("label",{className:"flex items-center space-x-4",children:[O.jsx("span",{className:"text-grey-100",children:"Name"}),O.jsxs(yt.Root,{color:c?"negative":"primary",className:"w-full",children:[O.jsx(yt.Group,{children:O.jsx(yt.Field,{autoFocus:!0,value:a,onChange:m=>s(m.target.value),onKeyDown:m=>{m.key==="Enter"&&g()},type:"text"})}),c&&O.jsx(yt.Message,{children:c})]})]})}),O.jsxs("div",{className:"mt-4 flex items-center justify-center space-x-2",children:[O.jsx("button",{className:"rounded border border-primary-dark bg-primary-dark px-4 py-1 hover:border-primary-hover hover:bg-primary-hover",onClick:()=>{g()},children:"Create"}),O.jsx("button",{className:"rounded border border-grey-100 px-4 py-1 text-grey-100 hover:bg-white hover:text-primary-dark",onClick:()=>b(),children:"Cancel"})]})]})})})]})}})},$de=()=>{const t=dr().getRoles(),{selectedRole:r}=d1();return O.jsxs("div",{className:"flex flex-1 h-full",children:[O.jsxs(fn,{depth:1,className:"flex h-full w-[356px] flex-col",children:[O.jsxs("div",{className:"flex flex-shrink-0 items-center justify-between px-3.5 py-[10px]",children:[O.jsxs("div",{className:"flex items-center space-x-1 text-[#DDE1E6]",children:[O.jsx("span",{children:O.jsx(_e.FdGroup,{className:"h-[14px] w-[14px]"})}),O.jsx("span",{className:"text-[11px] font-semibold",children:"Roles"})]}),O.jsx(Fde,{})]}),O.jsx("div",{className:"flex-1 space-y-4 overflow-auto p-4 pb-10 pt-1",children:Object.values(t).length>0?Object.values(t).sort((n,o)=>he.localeCompare(n.role,o.role)).map((n,o)=>O.jsx(jde,{role:n},o)):O.jsx("div",{className:"flex h-full items-center justify-center",children:O.jsx("div",{className:"flex flex-1 items-center justify-center bg-grey-800",children:O.jsxs("div",{className:"flex flex-col items-center justify-center space-y-4 text-grey-200",children:[O.jsx(_e.FdInfoBold,{className:"h-10 w-10"}),O.jsx("div",{className:"font-semibold",children:"There are no roles"}),O.jsxs("div",{className:"flex items-center text-sm",children:["Create a new role by clicking on the"," ",O.jsx(_e.FdPlus,{className:"ml-2 inline h-4 w-4 text-white"})]})]})})})})]}),O.jsx(fn,{depth:1,className:zt("relative flex h-full w-full flex-1 flex-col items-stretch overflow-x-auto",{"border-l-[0.5px]":r}),children:O.jsx("div",{className:"flex h-full w-full select-none flex-col",children:r?O.jsxs(O.Fragment,{children:[O.jsx(Lde,{}),O.jsx(Bde,{selectedRole:r})]}):O.jsx(M5,{tab:"Role"})})})]})},x$=()=>{const e=dr(),t=e.getQodly(),r=e.getSelectedTab(),n=e.getForceLogin(),o=e.getRestrictedByDefault(),i=R.useRef();return O.jsx("div",{className:"absolute inset-0 flex flex-1 overflow-hidden",children:O.jsx("div",{className:"relative flex flex-1 overflow-x-auto","data-cy":"Roles&Privileges-editor-cy",ref:a=>i.current=a,children:O.jsxs("div",{className:"flex w-full flex-col",children:[O.jsx(WK,{activeTab:r,forceLogin:n,restrictedByDefault:o,onTabChange:a=>{e.actions.toggleTab(a)},onForceLoginChange:a=>{e.actions.toggleForceLogin(a)},onRestrictedByDefaultChange:a=>{e.actions.toggleRestrictedByDefault(a)},qodly:t}),r==="roles"?O.jsx(UK,{children:O.jsx($de,{})}):O.jsx(Dde,{})]})})})},Vde=()=>{const{modals:e,closeModal:t,editModal:r}=Zae();return O.jsx(O.Fragment,{children:e.map((n,o)=>O.jsx(he.Modal,{hasOverlay:o===0,...n,onClose:t,onEdit:r,container:yr()},n.id))})},Hde=({initialValue:e,onChange:t,...r})=>{const n=dr(),o=n.getRolesFlags(),i=n.getRolesAndPrivileges();return R.useEffect(()=>{if(e)try{const a=JSON.parse(e);if(Al.isEqual(a,i))return;n.actions.setRolesContent({content:a,flags:{touched:!1}})}catch(a){console.error("[Roles Editor Standalone] Error while parsing the initial value:",a)}},[e]),he.useDidMountEffect(()=>{if(o.touched&&t)try{const a=JSON.stringify(i,null,2);t(a)}catch(a){console.error("[Roles Editor Standalone] Error on value stringify:",a)}},[i]),O.jsxs(O.Fragment,{children:[O.jsx("div",{className:"relative h-screen z-10 overflow-hidden",children:O.jsx(x$,{...r})}),O.jsx(Vde,{})]})},Wde=e=>{const t=Xae();return O.jsx(QB,{adapter:t,children:O.jsx(he.TipsProvider,{children:O.jsx(Hde,{...e})})})},Ude=e=>O.jsx(Kae,{children:O.jsx(Wde,{...e})});exports.ROLES_EDITOR_SCOPE_CLASS=kL.ROLES_EDITOR_SCOPE_CLASS;exports.EditorStateAdapterProvider=QB;exports.Roles=x$;exports.Standalone=Ude;exports.useReduxAdapter=vae;
|
|
72
126
|
//# sourceMappingURL=index.cjs.js.map
|