digital-rabbit-cl 3.3.11 → 3.3.12

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.
@@ -1,5 +1,5 @@
1
1
  (function(){"use strict";try{if(typeof document<"u"){var e=document.createElement("style");e.appendChild(document.createTextNode('.Button-module__button___2ZuB7{border-style:solid;cursor:pointer;font-weight:700;line-height:1.25;outline:none}.Button-module__button___2ZuB7:disabled{cursor:default}.Button-module__sizeSmall___DRT8P{font-size:var(--dr-button-small-font-size);padding:var(--dr-button-small-padding-v) var(--dr-button-small-padding-h)}.Button-module__sizeLarge___yeZSH{font-size:var(--dr-button-font-size);padding:var(--dr-button-padding-v) var(--dr-button-padding-h)}.Button-module__ghost___1KINV{border-color:transparent;background-color:transparent}.Checkbox-module__container___aV9qz{display:flex;align-items:center;line-height:1.2}.Checkbox-module__svg___kkluC{flex-shrink:0}.Checkbox-module__label___cwRtI{font-weight:700;margin-left:.45em;-webkit-user-select:none;user-select:none}.FormLabel-module__label___0M-fo{display:inline-block;font-size:var(--dr-form-label-font-size);font-weight:700;padding-bottom:var(--dr-form-label-padding-bottom)}.FormLabel-module__label___0M-fo.FormLabel-module__disabled___ktIFp{opacity:.5;cursor:not-allowed}.FormLabel-module__label___0M-fo:not(.FormLabel-module__disabled___ktIFp){cursor:default}:root{--font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;--font-size: 16px;--font-size-md: 15px;--font-size-sm: 14px;--line-height: 1.5;--font-weight-header: 700;--primary-color: #000;--background-color: #fff;--accent-color: #0066cc;--breakpoint-xs: 350px;--breakpoint-sm: 475px;--breakpoint-md: 769px;--breakpoint-lg: 1025px;--layout-max-width: 1280px;--layout-wrapper-padding-sm: .5rem;--layout-wrapper-padding: 1rem;--dr-input-font-size: 1em;--dr-input-padding-v: .25em;--dr-input-padding-h: .4em;--dr-input-small-font-size: 1em;--dr-input-small-padding-v: .1em;--dr-input-small-padding-h: .4em;--dr-button-font-size: 1em;--dr-button-padding-v: .25em;--dr-button-padding-h: .5em;--dr-button-small-font-size: 1em;--dr-button-small-padding-v: .1em;--dr-button-small-padding-h: .5em;--dr-form-label-font-size: .85em;--dr-form-label-padding-bottom: .25em;--dr-checkbox-size: 1em;--dr-radio-size: 1em}html{line-height:var(--line-height);-webkit-text-size-adjust:100%;-ms-text-size-adjust:100%;font-size:var(--font-size);font-family:var(--font-family);box-sizing:border-box}*,*:before,*:after{box-sizing:inherit}body{margin:0;font-family:var(--font-family);font-size:1em;line-height:var(--line-height);color:var(--primary-color);background-color:var(--background-color);-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}main{display:block}h1,h2,h3,h4,h5,h6{margin-top:0;margin-bottom:.5em;font-weight:var(--font-weight-header);overflow-wrap:break-word}hr{box-sizing:content-box;height:0;overflow:visible;border:0;border-top:1px solid rgba(0,0,0,.1);margin:1em 0}pre{font-family:monospace,monospace;font-size:1em;overflow:auto}a{background-color:transparent;font-weight:900;text-decoration:underline;text-underline-offset:3px;text-decoration-thickness:1px}a:link{color:var(--accent-color)}a:visited{color:color-mix(in srgb,var(--accent-color) 55%,transparent)}a:hover{color:var(--accent-color);text-decoration-thickness:2px}abbr[title]{border-bottom:none;text-decoration:underline;text-decoration:underline dotted}b,strong{font-weight:bolder}code,kbd,samp{font-family:monospace,monospace;font-size:1em}small{font-size:80%}sub,sup{font-size:75%;line-height:0;position:relative;vertical-align:baseline}sub{bottom:-.25em}sup{top:-.5em}img{border-style:none;max-width:100%;height:auto;vertical-align:middle}button,input,optgroup,select,textarea{font-family:inherit;font-size:100%;line-height:var(--line-height);margin:0}button,input{overflow:visible}button,select{text-transform:none}button,[type=button],[type=reset],[type=submit]{-webkit-appearance:button;cursor:pointer}button::-moz-focus-inner,[type=button]::-moz-focus-inner,[type=reset]::-moz-focus-inner,[type=submit]::-moz-focus-inner{border-style:none;padding:0}button:-moz-focusring,[type=button]:-moz-focusring,[type=reset]:-moz-focusring,[type=submit]:-moz-focusring{outline:1px dotted ButtonText}fieldset{padding:.35em .75em .625em}legend{box-sizing:border-box;color:inherit;display:table;max-width:100%;padding:0;white-space:normal}progress{vertical-align:baseline}textarea{overflow:auto;resize:vertical}[type=checkbox],[type=radio]{box-sizing:border-box;padding:0}[type=number]::-webkit-inner-spin-button,[type=number]::-webkit-outer-spin-button{height:auto}[type=search]{-webkit-appearance:textfield;outline-offset:-2px}[type=search]::-webkit-search-decoration{-webkit-appearance:none}::-webkit-file-upload-button{-webkit-appearance:button;font:inherit}details{display:block}summary{display:list-item;cursor:pointer}template,[hidden]{display:none}table{border-collapse:collapse;width:100%}ul,ol{padding-left:1.5em}p{margin-top:0;margin-bottom:1em;overflow-wrap:break-word}.FormError-module__formError___kaUBn{font-size:.875em;margin-top:var(--form-error-margin-top);font-weight:400}.FormGroup-module__formGroup___aVI-B{display:flex;flex-direction:column;margin-bottom:var(--form-group-margin-bottom)}.FormGroup-module__inputWrapper___429QE{display:flex;flex-direction:column;gap:.5em}.FormGroup-module__indented___t61iz{padding-left:.5em}.FormGroup-module__formGroup___aVI-B.FormGroup-module__disabled___W-tJ0{opacity:.6;pointer-events:none}.FormGroup-module__required___mO3xA{color:inherit;margin-left:.125em}.FormGroup-module__errorMessage___SHzl3{font-size:.875em;margin-top:.25rem;font-weight:400}.Input-module__input___WjT81{background-color:transparent;border-style:solid;box-sizing:border-box;display:block;font-weight:700;line-height:1.25;outline:none;width:100%}.Input-module__input___WjT81::placeholder{color:inherit;opacity:var(--placeholder-opacity, .3)}.Input-module__input___WjT81:disabled{opacity:.3}.Input-module__sizeSmall___NFvsi{font-size:var(--dr-input-small-font-size);padding:var(--dr-input-small-padding-v) var(--dr-input-small-padding-h)}.Input-module__sizeLarge___4Boj3{font-size:var(--dr-input-font-size);padding:var(--dr-input-padding-v) var(--dr-input-padding-h)}.Textarea-module__textarea___Z-y6g{background-color:transparent;border-style:solid;box-sizing:border-box;display:block;font-weight:700;line-height:1.25;outline:none;width:100%}.Textarea-module__textarea___Z-y6g::placeholder{color:inherit;opacity:var(--placeholder-opacity, .3)}.Textarea-module__textarea___Z-y6g:disabled{opacity:.3}.Textarea-module__sizeSmall___HHFEM{font-size:var(--dr-input-small-font-size);padding:var(--dr-input-small-padding-v) var(--dr-input-small-padding-h)}.Textarea-module__sizeLarge___5a3sf{font-size:var(--dr-input-font-size);padding:var(--dr-input-padding-v) var(--dr-input-padding-h)}.Select-module__select___cjdcr{-webkit-appearance:none;-moz-appearance:none;appearance:none;background-color:transparent;background-position:right center;background-repeat:no-repeat;background-size:auto 85%;border-style:solid;box-sizing:border-box;display:block;font-weight:700;line-height:1.25;outline:none;width:100%}.Select-module__select___cjdcr:disabled{cursor:default;opacity:.3}.Select-module__select___cjdcr:not(:disabled){cursor:pointer}.Select-module__sizeSmall___i1quj{font-size:var(--dr-input-small-font-size);padding:var(--dr-input-small-padding-v) calc(var(--dr-input-small-padding-h) * 3) var(--dr-input-small-padding-v) var(--dr-input-small-padding-h)}.Select-module__sizeLarge___eBA1T{font-size:var(--dr-input-font-size);padding:var(--dr-input-padding-v) calc(var(--dr-input-padding-h) * 3) var(--dr-input-padding-v) var(--dr-input-padding-h)}.Radio-module__container___AQxhk{display:flex;align-items:center;line-height:1.25}.Radio-module__svg___zl5kF{flex-shrink:0}.Radio-module__label___vAFIP{font-weight:700;margin-left:.45em;-webkit-user-select:none;user-select:none}.Hamburger-module__hamburger___Tf4-t{background:transparent;border:none;cursor:pointer;display:none;flex-direction:column;justify-content:space-around;height:2em;outline:none;padding:0;position:relative;width:2em;z-index:11}.Hamburger-module__line___gybZM{background:currentColor;border-radius:var(--hamburger-border-radius, 10px);height:12.5%;position:relative;transform-origin:1px;transition:all .3s linear;width:100%}.Hamburger-module__line___gybZM:first-child{transform:rotate(0)}.Hamburger-module__line___gybZM:nth-child(2){opacity:1;transform:translate(0)}.Hamburger-module__line___gybZM:nth-child(3){transform:rotate(0)}.Hamburger-module__hamburger___Tf4-t.Hamburger-module__open___gRswh .Hamburger-module__line___gybZM:first-child{transform:rotate(45deg)}.Hamburger-module__hamburger___Tf4-t.Hamburger-module__open___gRswh .Hamburger-module__line___gybZM:nth-child(2){opacity:0;transform:translate(20px)}.Hamburger-module__hamburger___Tf4-t.Hamburger-module__open___gRswh .Hamburger-module__line___gybZM:nth-child(3){transform:rotate(-45deg)}.Header-module__header___RUooH{width:100%}.Header-module__container___t68M9{display:flex;align-items:center;justify-content:space-between;margin:0 auto;font-size:var(--header-font-size);max-width:var(--header-max-width);padding:var(--header-padding);position:relative}.ResponsiveNav-module__nav___xOfv5{display:flex}.ResponsiveNav-module__navMobile___h795P{flex-direction:column;min-height:100%;overflow-x:hidden}.ResponsiveNav-module__navHeader___Me8bB{height:3.5em;flex-shrink:0}.ResponsiveNav-module__navMobile___h795P.ResponsiveNav-module__compact___UhuAE .ResponsiveNav-module__navHeader___Me8bB{height:3em}.ResponsiveNav-module__navDesktop___9wscZ{align-items:center;flex-direction:row;height:auto}.ResponsiveNav-module__navDesktop___9wscZ>*{margin-left:1.25rem}.Popover-module__triggerWrapper___dZpf6{display:inline-block}.Popover-module__popup___JAvrb{max-height:60vh;min-width:120px;overflow:auto}.Popover-module__panelOverlay___1xDU5{top:0;right:0;bottom:0;left:0;pointer-events:none;position:fixed;z-index:1000}.Popover-module__panelOverlayVisible___BgtIQ{pointer-events:auto}.Popover-module__backdrop___e8qHL{top:0;right:0;bottom:0;left:0;position:absolute;transition:background-color .3s ease}.Popover-module__panel___eUJ2E{bottom:0;overflow-y:auto;padding:1rem;position:absolute;top:0;transition:transform .3s ease-in-out}.Popover-module__panelLeft___9nSLp{left:0;transform:translate(-100%)}.Popover-module__panelRight___OrQfl{right:0;transform:translate(100%)}.Popover-module__panelOpen___hhvV-{transform:translate(0)}.Popover-module__panelCloseButton___kALaN{align-items:center;background:none;border:none;color:inherit;cursor:pointer;display:flex;height:1.5rem;justify-content:center;padding:0;position:absolute;right:1rem;top:1rem;width:1.5rem}.Popover-module__panelCloseButton___kALaN:hover{opacity:.7}.NavDropdown-module__trigger___1PQZp{align-items:center;background:none;border:none;cursor:pointer;display:inline-flex;font-family:inherit;font-size:inherit;gap:.375rem;padding:0}.NavDropdown-module__chevron___ZLAV7{align-items:center;display:inline-flex;transition:transform .2s ease}.NavDropdown-module__chevronOpen___9mgjr{transform:rotate(180deg)}.Modal-module__backdrop___GVUh4{position:fixed;top:0;left:0;right:0;bottom:0;display:flex;align-items:center;justify-content:center;z-index:1000;padding:1em}.Modal-module__modal___aD7aP{padding:1em;position:relative;display:flex;flex-direction:column;gap:1em;max-height:90vh;box-shadow:0 10px 40px #0003;outline:none}.Modal-module__header___ILG9i{display:flex;align-items:center;justify-content:space-between;flex-shrink:0}.Modal-module__title___A5OeE{margin:0;font-size:1.5rem;font-weight:600;flex:1}.Modal-module__closeButton___3LpSf{background:none;border:none;cursor:pointer;padding:0;width:1.75em;height:1.75em;display:flex;align-items:center;justify-content:center;color:inherit;margin-left:auto;opacity:.6;transition:opacity .2s,transform .2s;flex-shrink:0}.Modal-module__closeButton___3LpSf svg{display:block;flex-shrink:0}.Modal-module__content___dWO-B{overflow-y:auto;flex:1}.Modal-module__actions___hY6zi{flex-shrink:0}@media (max-width: calc(var(--breakpoint-md) - 1px)){.Modal-module__backdrop___GVUh4{padding:.5em}.Modal-module__header___ILG9i,.Modal-module__content___dWO-B,.Modal-module__actions___hY6zi{padding:1rem}.Modal-module__title___A5OeE{font-size:1.25em}}.Stack-module__stack___yUU-B{display:flex}.Stack-module__vertical___sKTyQ{flex-direction:column}.Stack-module__horizontal___YsvtV{flex-direction:row;align-items:center}.ResponsiveSection-module__section___gBESK{width:100%;padding:0}.ResponsiveSection-module__innerDiv___r1bky{max-width:var(--max-width);margin:0 auto;padding:var(--section-padding)}.Hero-module__hero___IB2tg{padding:var(--hero-padding, 3rem 0)}.Hero-module__content___rkkfQ h1{font-size:var(--hero-h1-font-size, 2rem);margin-bottom:var(--hero-h1-margin-bottom)}.Hero-module__content___rkkfQ p{font-size:var(--hero-p-font-size, 1.125rem);line-height:1.6}.Footer-module__footer___A76NF{width:100%;margin-top:auto}.Footer-module__container___QneNs{display:flex;align-items:center;justify-content:space-between;margin:0 auto}.FeatureCard-module__card___XQt66{display:flex;flex-direction:column;align-items:center;text-align:center;padding:var(--feature-card-padding)}.FeatureCard-module__icon___dXJ92{font-size:var(--feature-icon-font-size, 2.5rem);margin-bottom:var(--feature-icon-margin-bottom);color:var(--feature-icon-color, var(--primary-color))}.FeatureCard-module__title___KxXyA{font-size:var(--feature-title-font-size, 1.25rem);font-weight:600;margin-bottom:var(--feature-title-margin-bottom);color:var(--feature-title-color, inherit)}.FeatureCard-module__content___68xkw{font-size:1rem;line-height:1.6;color:var(--feature-content-color, var(--primary-color))}.FeatureGrid-module__grid___6sW6f{display:grid;gap:2rem;grid-template-columns:var(--grid-template-columns, 1fr)}.MediaCard-module__card___9pZ7C{display:flex;overflow:hidden}.MediaCard-module__clickable___Rae9n{cursor:pointer;transition:opacity .15s ease}.MediaCard-module__clickable___Rae9n:hover{opacity:.85}.MediaCard-module__vertical___GWtOA{flex-direction:column}.MediaCard-module__vertical___GWtOA .MediaCard-module__imageWrapper___HUiag{width:100%}.MediaCard-module__horizontal___qlK4y{flex-direction:row;align-items:var(--media-card-align-items, center)}.MediaCard-module__horizontal___qlK4y .MediaCard-module__imageWrapper___HUiag{width:var(--media-card-image-width, 7em);flex-shrink:0;padding-top:var(--media-card-image-padding-top, 0)}.MediaCard-module__content___MlqE4{flex:1;min-width:0}.PageLayout-module__layoutContainer___diLdT{display:flex;flex-direction:column;min-height:100vh}.PageLayout-module__content___h2mBr{flex:1 0 auto;display:flex;flex-direction:column}.PageLayout-module__main___Sw7Pv{flex:1}.FileUpload-module__dropzone___jqua0{border-style:dashed;box-sizing:border-box;cursor:pointer;display:flex;align-items:center;justify-content:center;padding:1rem;position:relative;text-align:center;transition:opacity .15s ease,background-color .15s ease;width:100%}.FileUpload-module__dropzone___jqua0:hover:not(.FileUpload-module__loading___C7PsH){background-color:#00000008}.FileUpload-module__dropzone___jqua0:focus-visible{outline:2px solid var(--upload-color, currentColor);outline-offset:2px}.FileUpload-module__dragOver___q1zPo{background-color:#0000000f}.FileUpload-module__loading___C7PsH{cursor:not-allowed;opacity:.6}.FileUpload-module__hiddenInput___RLLPJ{display:none}.FileUpload-module__content___yCP0l{display:flex;flex-direction:column;align-items:center;gap:.35rem}.FileUpload-module__contentHidden___0Ewoe{visibility:hidden}.FileUpload-module__spinnerOverlay___e3Rle{position:absolute}.FileUpload-module__label___lbMkx{font-weight:600}.FileUpload-module__hint___8dXlk{font-size:.85em;opacity:.7}.FileUpload-module__errorMessage___8HB3n{font-size:.85em;font-weight:600;margin-top:.25rem}.Image-module__container___sVJdZ{position:relative;overflow:hidden;width:100%}.Image-module__img___pKhPw{width:100%;height:100%;object-fit:cover;display:block;position:absolute;top:0;right:0;bottom:0;left:0}.Image-module__fallback___wysuM{position:absolute;top:0;right:0;bottom:0;left:0;display:flex;align-items:center;justify-content:center}@keyframes Skeleton-module__pulse___8RWFn{0%,to{opacity:.4}50%{opacity:1}}.Skeleton-module__skeleton___CB4uF{background-color:var(--skeleton-color, color-mix(in srgb, currentColor 20%, transparent));animation:Skeleton-module__pulse___8RWFn 2s ease-in-out infinite;display:block;width:100%;height:100%}.ImageThumbnail-module__thumbnail___-igbe{box-sizing:border-box;display:flex;align-items:center;justify-content:center;flex-shrink:0;overflow:hidden;position:relative}.ImageThumbnail-module__img___Q7Z4V{width:100%;height:100%;object-fit:cover;display:block}.ImageThumbnail-module__sizeXs___TvSHV{width:1.25em;height:1.25em}.ImageThumbnail-module__sizeSmall___2KnCh{width:3em;height:3em}.ImageThumbnail-module__sizeDefault___laoQk{width:4em;height:4em}.ImageThumbnail-module__sizeLarge___iwz3o{width:5em;height:5em}.ImageThumbnail-module__removeButton___Ceh1Q{position:absolute;top:.25rem;right:.25rem;width:1.1rem;height:1.1rem;border:none;cursor:pointer;display:flex;align-items:center;justify-content:center;padding:0;z-index:1;opacity:.6;transition:opacity .15s ease}.ImageThumbnail-module__removeButton___Ceh1Q:hover{opacity:1}.Tooltip-module__triggerWrapper___wMSun{display:inline-block}.Tooltip-module__tooltip___UA7H9{pointer-events:none;max-width:280px;padding:.4rem .6rem;font-size:.875rem;line-height:1.3;word-wrap:break-word}')),document.head.appendChild(e)}}catch(o){console.error("vite-plugin-css-injected-by-js",o)}})();
2
- (function(L,d){typeof exports=="object"&&typeof module<"u"?d(exports,require("react/jsx-runtime"),require("react"),require("react-dom")):typeof define=="function"&&define.amd?define(["exports","react/jsx-runtime","react","react-dom"],d):(L=typeof globalThis<"u"?globalThis:L||self,d(L.DigitalRabbitCL={},L.jsxRuntime,L.React,L.ReactDOM))})(this,(function(L,d,g,Le){"use strict";const xe={button:"Button-module__button___2ZuB7",sizeSmall:"Button-module__sizeSmall___DRT8P",sizeLarge:"Button-module__sizeLarge___yeZSH",ghost:"Button-module__ghost___1KINV"},Wr=({isActive:e,disabled:r,color:t,hoverColor:o,hoverTextColor:n,outline:s,ghost:a=!1,theme:l})=>{var k;const u=t||l.colors.primary,c=l.buttons.textColor,m=!s&&!t?((k=l.buttons.primary)==null?void 0:k.textColor)??c:c;let h,b,S;a?(h="transparent",b="transparent",S=u,e&&(S=n||u)):s?(h="transparent",b=u,S=u,e&&(h=o||u,b=o||u,S=n||c)):(h=u,b=u,S=m,e&&(h=o||u,b=o||u,S=n||m));let _=1;return r?_=.3:e&&!o&&(_=.75),{backgroundColor:h,borderColor:b,color:S,opacity:_}};function Ct(e,r){const t={...e};return Ne(e)&&Ne(r)&&Object.keys(r).forEach(o=>{const n=r[o],s=e[o];Ne(n)&&Ne(s)?t[o]=Ct(s,n):n!==void 0&&(t[o]=n)}),t}function Ne(e){return e&&typeof e=="object"&&!Array.isArray(e)}function ve(e){const r=e.match(/^(\d+(?:\.\d+)?)(px|em|rem)$/);if(!r){const n=parseInt(e,10),s=e.replace(/[0-9.]/g,"")||"px";return{maxWidth:isNaN(n)?768:n-1,unit:s}}const t=parseFloat(r[1]),o=r[2];return{maxWidth:t-1,unit:o}}const Be={primary:"#000",secondary:"#FFF",secondaryBackground:"#1e1e1f",accent:"#4381C1",error:"#F00",success:"#008000",warning:"#FFEB3B"},Ue={colors:Be,fonts:{color:"#000",lineHeight:1.5,fontFamily:'-apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif',fontWeightHeader:700,size:"22px",sizeMd:"19px",sizeSm:"17px",rhythm:"1.45em"},buttons:{textColor:"#FFF",primary:{textColor:Be.secondary}},border:{radius:"5px",width:"0.15em"},breakpoints:{xs:"350px",sm:"475px",md:"769px",lg:"1025px"},layout:{maxWidth:"1280px",paddingSm:"0.5rem",padding:"1rem"},cards:{backgroundColor:Be.secondaryBackground},modal:{backgroundColor:Be.secondaryBackground,backdropColor:"rgba(0, 0, 0, 0.5)",boxShadow:"0 10px 40px rgba(0, 0, 0, 0.2)"},responsive:{default:{input:{fontSize:"1em",paddingVertical:"0.25em",paddingHorizontal:"0.4em"},inputSmall:{fontSize:"1em",paddingVertical:"0.1em",paddingHorizontal:"0.4em"},button:{fontSize:"1em",paddingVertical:"0.25em",paddingHorizontal:"0.5em"},buttonSmall:{fontSize:"1em",paddingVertical:"0.1em",paddingHorizontal:"0.5em"},formLabel:{fontSize:"0.85em",paddingBottom:"0.25em"},checkbox:{size:"1em"},radio:{size:"1em"}},md:{input:{fontSize:"17px",paddingVertical:"0.35em",paddingHorizontal:"0.5em"},inputSmall:{fontSize:"17px",paddingVertical:"0.2em",paddingHorizontal:"0.5em"},button:{fontSize:"17px",paddingVertical:"0.35em",paddingHorizontal:"0.6em"},buttonSmall:{fontSize:"17px",paddingVertical:"0.2em",paddingHorizontal:"0.6em"},formLabel:{fontSize:"15px",paddingBottom:"0.3em"},checkbox:{size:"18px"},radio:{size:"18px"}},sm:{input:{fontSize:"16px",paddingVertical:"0.4em",paddingHorizontal:"0.55em"},inputSmall:{fontSize:"16px",paddingVertical:"0.25em",paddingHorizontal:"0.55em"},button:{fontSize:"16px",paddingVertical:"0.4em",paddingHorizontal:"0.65em"},buttonSmall:{fontSize:"16px",paddingVertical:"0.25em",paddingHorizontal:"0.65em"},formLabel:{fontSize:"16px",paddingBottom:"0.35em"},checkbox:{size:"20px"},radio:{size:"20px"}}},typography:{heading:{h1:{fontSize:"2.5rem",mdFontSize:"2rem",smFontSize:"1.75rem"},h2:{fontSize:"1.75rem",mdFontSize:"1.5rem",smFontSize:"1.35rem"},h3:{fontSize:"1.38316rem"},h4:{fontSize:"1rem"},h5:{fontSize:"0.85028rem"},h6:{fontSize:"0.78405rem"}},text:{default:{fontSize:"1em"},sm:{fontSize:"0.85em"},xs:{fontSize:"0.75em"},lg:{fontSize:"1.25em"}}}},wt=g.createContext(Ue),jr=({theme:e,children:r})=>{const t=e?Ct(Ue,e):Ue;return d.jsx(wt.Provider,{value:t,children:r})},I=()=>g.useContext(wt),xt=({color:e,hoverColor:r,hoverTextColor:t,disabled:o=!1,size:n="large",outline:s=!1,ghost:a=!1,type:l="button",className:u,style:c,buttonProps:f={},onClick:m,children:h})=>{const b=I(),[S,_]=g.useState(!1),V={...Wr({isActive:S,disabled:o,color:e,hoverColor:r,hoverTextColor:t,outline:s,ghost:a,theme:b}),borderWidth:b.border.width,borderRadius:b.border.radius,...c},v=[xe.button,n==="small"?xe.sizeSmall:xe.sizeLarge,a?xe.ghost:s?xe.outline:"",u].filter(Boolean).join(" ");return d.jsx("button",{...f,className:v,disabled:o,onClick:m,onMouseEnter:()=>_(!0),onMouseLeave:()=>_(!1),type:l,style:V,children:h})};var Ft=typeof crypto<"u"&&crypto.getRandomValues&&crypto.getRandomValues.bind(crypto)||typeof msCrypto<"u"&&typeof msCrypto.getRandomValues=="function"&&msCrypto.getRandomValues.bind(msCrypto),Hr=new Uint8Array(16);function Ur(){if(!Ft)throw new Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");return Ft(Hr)}for(var zt=[],Me=0;Me<256;++Me)zt[Me]=(Me+256).toString(16).substr(1);function qr(e,r){var t=0,o=zt;return[o[e[t++]],o[e[t++]],o[e[t++]],o[e[t++]],"-",o[e[t++]],o[e[t++]],"-",o[e[t++]],o[e[t++]],"-",o[e[t++]],o[e[t++]],"-",o[e[t++]],o[e[t++]],o[e[t++]],o[e[t++]],o[e[t++]],o[e[t++]]].join("")}function Vt(e,r,t){var o=r&&t||0;typeof e=="string"&&(r=e==="binary"?new Array(16):null,e=null),e=e||{};var n=e.random||(e.rng||Ur)();if(n[6]=n[6]&15|64,n[8]=n[8]&63|128,r)for(var s=0;s<16;++s)r[o+s]=n[s];return r||qr(n)}const qe={container:"Checkbox-module__container___aV9qz",svg:"Checkbox-module__svg___kkluC",label:"Checkbox-module__label___cwRtI"},Gr=({color:e="#000",checkmarkColor:r,disabled:t=!1,inverted:o=!1})=>{let n=e;return r?n=r:o&&(n="white"),{checkboxColor:e,checkmarkColor:n,cursor:t?"default":"pointer",opacity:t?.3:1}},Et={label:"FormLabel-module__label___0M-fo",disabled:"FormLabel-module__disabled___ktIFp"},Zr=({color:e="#000",disabled:r=!1,fontSize:t=".85em"})=>({color:e,fontSize:t,opacity:r?.5:1,cursor:r?"not-allowed":"default"}),Ae=({color:e,disabled:r=!1,error:t=!1,htmlFor:o,children:n,className:s,style:a,labelProps:l})=>{const u=I(),c=u.colors.error,f=t?c:e||u.colors.primary,m=Zr({color:f,disabled:r}),h={color:m.color,opacity:m.opacity,cursor:m.cursor,...a},b=[Et.label,r?Et.disabled:"",s].filter(Boolean).join(" ");return d.jsx("label",{...l,className:b,htmlFor:o,style:h,children:n})},Pe=({color:e,checkmarkColor:r,checked:t=!1,inverted:o=!1,disabled:n=!1,error:s=!1,name:a,id:l,onChange:u,label:c,labelStyle:f,className:m,style:h,divProps:b})=>{const S=I(),_=l||Vt(),k=S.colors.error,V=s?k:e||S.colors.primary,v=Gr({color:V,checkmarkColor:r,disabled:n,inverted:o}),z=A=>{n||u(A)},E={cursor:v.cursor,opacity:v.opacity,...h},F={width:"var(--dr-checkbox-size)",height:"var(--dr-checkbox-size)"},N={fill:o&&t?v.checkboxColor:"transparent",strokeWidth:"25",stroke:v.checkboxColor},P={stroke:v.checkmarkColor,strokeWidth:"15",fill:"transparent"},O=[qe.container,m].filter(Boolean).join(" ");return d.jsxs("div",{...b,className:O,style:E,children:[d.jsx("input",{id:_,checked:t,disabled:n,onChange:A=>z({target:{checked:A.target.checked,name:a,type:"checkbox"}}),name:a,style:{display:"none"},type:"checkbox"}),d.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 100 100",onClick:()=>z({target:{checked:!t,name:a,type:"checkbox"}}),style:F,className:qe.svg,children:[d.jsx("rect",{x:"0",y:"0",height:"100",width:"100",style:N}),t&&d.jsx("path",{d:"M 25 45 L 45 65 L 75 30",style:P})]}),c&&d.jsx(Ae,{htmlFor:_,className:qe.label,style:{paddingBottom:0,...f},color:v.checkboxColor,disabled:n,error:s,children:c})]})},Kr=()=>{const e=I();return g.useLayoutEffect(()=>{const r=document.documentElement,t=(l,u)=>{u!=null&&r.style.setProperty(l,String(u))},{fonts:o,colors:n,breakpoints:s,layout:a}=e;o&&(t("--font-family",o.fontFamily),t("--font-size",o.size),t("--font-size-md",o.sizeMd),t("--font-size-sm",o.sizeSm),t("--line-height",o.lineHeight),t("--font-weight-header",o.fontWeightHeader)),n&&(t("--primary-color",n.primary),t("--background-color",n.secondary),t("--accent-color",n.accent)),s&&(t("--breakpoint-xs",s.xs),t("--breakpoint-sm",s.sm),t("--breakpoint-md",s.md),t("--breakpoint-lg",s.lg)),a&&(t("--layout-max-width",a.maxWidth),t("--layout-wrapper-padding-sm",a.paddingSm),t("--layout-wrapper-padding",a.padding))},[e]),g.useLayoutEffect(()=>{const r="dr-cl-responsive-tokens";let t=document.getElementById(r);t||(t=document.createElement("style"),t.id=r,document.head.appendChild(t));const o=(m,h)=>{const b=[];return h.fontSize&&b.push(` --dr-${m}-font-size: ${h.fontSize};`),h.paddingVertical&&b.push(` --dr-${m}-padding-v: ${h.paddingVertical};`),h.paddingHorizontal&&b.push(` --dr-${m}-padding-h: ${h.paddingHorizontal};`),b},n=m=>{var b,S,_,k;const h=[];return m.input&&h.push(...o("input",m.input)),m.inputSmall&&h.push(...o("input-small",m.inputSmall)),m.button&&h.push(...o("button",m.button)),m.buttonSmall&&h.push(...o("button-small",m.buttonSmall)),(b=m.formLabel)!=null&&b.fontSize&&h.push(` --dr-form-label-font-size: ${m.formLabel.fontSize};`),(S=m.formLabel)!=null&&S.paddingBottom&&h.push(` --dr-form-label-padding-bottom: ${m.formLabel.paddingBottom};`),(_=m.checkbox)!=null&&_.size&&h.push(` --dr-checkbox-size: ${m.checkbox.size};`),(k=m.radio)!=null&&k.size&&h.push(` --dr-radio-size: ${m.radio.size};`),h},s=(m,h)=>`@media (max-width: ${m}) {
2
+ (function(L,d){typeof exports=="object"&&typeof module<"u"?d(exports,require("react/jsx-runtime"),require("react"),require("react-dom")):typeof define=="function"&&define.amd?define(["exports","react/jsx-runtime","react","react-dom"],d):(L=typeof globalThis<"u"?globalThis:L||self,d(L.DigitalRabbitCL={},L.jsxRuntime,L.React,L.ReactDOM))})(this,(function(L,d,g,Le){"use strict";const xe={button:"Button-module__button___2ZuB7",sizeSmall:"Button-module__sizeSmall___DRT8P",sizeLarge:"Button-module__sizeLarge___yeZSH",ghost:"Button-module__ghost___1KINV"},Wr=({isActive:e,disabled:r,color:t,hoverColor:o,hoverTextColor:n,outline:s,ghost:a=!1,theme:l})=>{var k;const u=t||l.colors.primary,c=l.buttons.textColor,m=!s&&!t?((k=l.buttons.primary)==null?void 0:k.textColor)??c:c;let h,b,S;a?(h="transparent",b="transparent",S=u,e&&(S=n||u)):s?(h="transparent",b=u,S=u,e&&(h=o||u,b=o||u,S=n||c)):(h=u,b=u,S=m,e&&(h=o||u,b=o||u,S=n||m));let _=1;return r?_=.3:e&&!o&&(_=.75),{backgroundColor:h,borderColor:b,color:S,opacity:_}};function Ct(e,r){const t={...e};return Ne(e)&&Ne(r)&&Object.keys(r).forEach(o=>{const n=r[o],s=e[o];Ne(n)&&Ne(s)?t[o]=Ct(s,n):n!==void 0&&(t[o]=n)}),t}function Ne(e){return e&&typeof e=="object"&&!Array.isArray(e)}function ve(e){const r=e.match(/^(\d+(?:\.\d+)?)(px|em|rem)$/);if(!r){const n=parseInt(e,10),s=e.replace(/[0-9.]/g,"")||"px";return{maxWidth:isNaN(n)?768:n-1,unit:s}}const t=parseFloat(r[1]),o=r[2];return{maxWidth:t-1,unit:o}}const Be={primary:"#000",secondary:"#FFF",secondaryBackground:"#1e1e1f",accent:"#4381C1",error:"#F00",success:"#008000",warning:"#FFEB3B"},Ue={colors:Be,fonts:{color:"#000",lineHeight:1.5,fontFamily:'-apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif',fontWeightHeader:700,size:"22px",sizeMd:"19px",sizeSm:"17px",rhythm:"1.45em"},buttons:{textColor:"#FFF",primary:{textColor:Be.secondary}},border:{radius:"5px",width:"0.15em"},breakpoints:{xs:"350px",sm:"475px",md:"769px",lg:"1025px"},layout:{maxWidth:"1280px",paddingSm:"0.5rem",padding:"1rem"},cards:{backgroundColor:Be.secondaryBackground},modal:{backgroundColor:Be.secondaryBackground,backdropColor:"rgba(0, 0, 0, 0.5)",boxShadow:"0 10px 40px rgba(0, 0, 0, 0.2)"},responsive:{default:{input:{fontSize:"1em",paddingVertical:"0.25em",paddingHorizontal:"0.4em"},inputSmall:{fontSize:"1em",paddingVertical:"0.1em",paddingHorizontal:"0.4em"},button:{fontSize:"1em",paddingVertical:"0.25em",paddingHorizontal:"0.5em"},buttonSmall:{fontSize:"1em",paddingVertical:"0.1em",paddingHorizontal:"0.5em"},formLabel:{fontSize:"0.85em",paddingBottom:"0.25em"},checkbox:{size:"1em"},radio:{size:"1em"}},md:{input:{fontSize:"17px",paddingVertical:"0.35em",paddingHorizontal:"0.5em"},inputSmall:{fontSize:"17px",paddingVertical:"0.2em",paddingHorizontal:"0.5em"},button:{fontSize:"17px",paddingVertical:"0.35em",paddingHorizontal:"0.6em"},buttonSmall:{fontSize:"17px",paddingVertical:"0.2em",paddingHorizontal:"0.6em"},formLabel:{fontSize:"15px",paddingBottom:"0.3em"},checkbox:{size:"18px"},radio:{size:"18px"}},sm:{input:{fontSize:"16px",paddingVertical:"0.4em",paddingHorizontal:"0.55em"},inputSmall:{fontSize:"16px",paddingVertical:"0.25em",paddingHorizontal:"0.55em"},button:{fontSize:"16px",paddingVertical:"0.4em",paddingHorizontal:"0.65em"},buttonSmall:{fontSize:"16px",paddingVertical:"0.25em",paddingHorizontal:"0.65em"},formLabel:{fontSize:"16px",paddingBottom:"0.35em"},checkbox:{size:"20px"},radio:{size:"20px"}}},typography:{heading:{h1:{fontSize:"2.5rem",mdFontSize:"2rem",smFontSize:"1.75rem"},h2:{fontSize:"1.75rem",mdFontSize:"1.5rem",smFontSize:"1.35rem"},h3:{fontSize:"1.38316rem"},h4:{fontSize:"1rem"},h5:{fontSize:"0.85028rem"},h6:{fontSize:"0.78405rem"}},text:{default:{fontSize:"1em"},sm:{fontSize:"0.85em"},xs:{fontSize:"0.75em"},lg:{fontSize:"1.25em"}}}},wt=g.createContext(Ue),Hr=({theme:e,children:r})=>{const t=e?Ct(Ue,e):Ue;return d.jsx(wt.Provider,{value:t,children:r})},I=()=>g.useContext(wt),xt=({color:e,hoverColor:r,hoverTextColor:t,disabled:o=!1,size:n="large",outline:s=!1,ghost:a=!1,type:l="button",className:u,style:c,buttonProps:f={},onClick:m,children:h})=>{const b=I(),[S,_]=g.useState(!1),V={...Wr({isActive:S,disabled:o,color:e,hoverColor:r,hoverTextColor:t,outline:s,ghost:a,theme:b}),borderWidth:b.border.width,borderRadius:b.border.radius,...c},v=[xe.button,n==="small"?xe.sizeSmall:xe.sizeLarge,a?xe.ghost:s?xe.outline:"",u].filter(Boolean).join(" ");return d.jsx("button",{...f,className:v,disabled:o,onClick:m,onMouseEnter:()=>_(!0),onMouseLeave:()=>_(!1),type:l,style:V,children:h})};var Ft=typeof crypto<"u"&&crypto.getRandomValues&&crypto.getRandomValues.bind(crypto)||typeof msCrypto<"u"&&typeof msCrypto.getRandomValues=="function"&&msCrypto.getRandomValues.bind(msCrypto),Ur=new Uint8Array(16);function qr(){if(!Ft)throw new Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");return Ft(Ur)}for(var zt=[],Me=0;Me<256;++Me)zt[Me]=(Me+256).toString(16).substr(1);function Gr(e,r){var t=0,o=zt;return[o[e[t++]],o[e[t++]],o[e[t++]],o[e[t++]],"-",o[e[t++]],o[e[t++]],"-",o[e[t++]],o[e[t++]],"-",o[e[t++]],o[e[t++]],"-",o[e[t++]],o[e[t++]],o[e[t++]],o[e[t++]],o[e[t++]],o[e[t++]]].join("")}function Vt(e,r,t){var o=r&&t||0;typeof e=="string"&&(r=e==="binary"?new Array(16):null,e=null),e=e||{};var n=e.random||(e.rng||qr)();if(n[6]=n[6]&15|64,n[8]=n[8]&63|128,r)for(var s=0;s<16;++s)r[o+s]=n[s];return r||Gr(n)}const qe={container:"Checkbox-module__container___aV9qz",svg:"Checkbox-module__svg___kkluC",label:"Checkbox-module__label___cwRtI"},Zr=({color:e="#000",checkmarkColor:r,disabled:t=!1,inverted:o=!1})=>{let n=e;return r?n=r:o&&(n="white"),{checkboxColor:e,checkmarkColor:n,cursor:t?"default":"pointer",opacity:t?.3:1}},Et={label:"FormLabel-module__label___0M-fo",disabled:"FormLabel-module__disabled___ktIFp"},Kr=({color:e="#000",disabled:r=!1,fontSize:t=".85em"})=>({color:e,fontSize:t,opacity:r?.5:1,cursor:r?"not-allowed":"default"}),Ae=({color:e,disabled:r=!1,error:t=!1,htmlFor:o,children:n,className:s,style:a,labelProps:l})=>{const u=I(),c=u.colors.error,f=t?c:e||u.colors.primary,m=Kr({color:f,disabled:r}),h={color:m.color,opacity:m.opacity,cursor:m.cursor,...a},b=[Et.label,r?Et.disabled:"",s].filter(Boolean).join(" ");return d.jsx("label",{...l,className:b,htmlFor:o,style:h,children:n})},Pe=({color:e,checkmarkColor:r,checked:t=!1,inverted:o=!1,disabled:n=!1,error:s=!1,name:a,id:l,onChange:u,label:c,labelStyle:f,className:m,style:h,divProps:b})=>{const S=I(),_=l||Vt(),k=S.colors.error,V=s?k:e||S.colors.primary,v=Zr({color:V,checkmarkColor:r,disabled:n,inverted:o}),z=A=>{n||u(A)},E={cursor:v.cursor,opacity:v.opacity,...h},F={width:"var(--dr-checkbox-size)",height:"var(--dr-checkbox-size)"},N={fill:o&&t?v.checkboxColor:"transparent",strokeWidth:"25",stroke:v.checkboxColor},P={stroke:v.checkmarkColor,strokeWidth:"15",fill:"transparent"},O=[qe.container,m].filter(Boolean).join(" ");return d.jsxs("div",{...b,className:O,style:E,children:[d.jsx("input",{id:_,checked:t,disabled:n,onChange:A=>z({target:{checked:A.target.checked,name:a,type:"checkbox"}}),name:a,style:{display:"none"},type:"checkbox"}),d.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 100 100",onClick:()=>z({target:{checked:!t,name:a,type:"checkbox"}}),style:F,className:qe.svg,children:[d.jsx("rect",{x:"0",y:"0",height:"100",width:"100",style:N}),t&&d.jsx("path",{d:"M 25 45 L 45 65 L 75 30",style:P})]}),c&&d.jsx(Ae,{htmlFor:_,className:qe.label,style:{paddingBottom:0,...f},color:v.checkboxColor,disabled:n,error:s,children:c})]})},Qr=()=>{const e=I();return g.useLayoutEffect(()=>{const r=document.documentElement,t=(l,u)=>{u!=null&&r.style.setProperty(l,String(u))},{fonts:o,colors:n,breakpoints:s,layout:a}=e;o&&(t("--font-family",o.fontFamily),t("--font-size",o.size),t("--font-size-md",o.sizeMd),t("--font-size-sm",o.sizeSm),t("--line-height",o.lineHeight),t("--font-weight-header",o.fontWeightHeader)),n&&(t("--primary-color",n.primary),t("--background-color",n.secondary),t("--accent-color",n.accent)),s&&(t("--breakpoint-xs",s.xs),t("--breakpoint-sm",s.sm),t("--breakpoint-md",s.md),t("--breakpoint-lg",s.lg)),a&&(t("--layout-max-width",a.maxWidth),t("--layout-wrapper-padding-sm",a.paddingSm),t("--layout-wrapper-padding",a.padding))},[e]),g.useLayoutEffect(()=>{const r="dr-cl-responsive-tokens";let t=document.getElementById(r);t||(t=document.createElement("style"),t.id=r,document.head.appendChild(t));const o=(m,h)=>{const b=[];return h.fontSize&&b.push(` --dr-${m}-font-size: ${h.fontSize};`),h.paddingVertical&&b.push(` --dr-${m}-padding-v: ${h.paddingVertical};`),h.paddingHorizontal&&b.push(` --dr-${m}-padding-h: ${h.paddingHorizontal};`),b},n=m=>{var b,S,_,k;const h=[];return m.input&&h.push(...o("input",m.input)),m.inputSmall&&h.push(...o("input-small",m.inputSmall)),m.button&&h.push(...o("button",m.button)),m.buttonSmall&&h.push(...o("button-small",m.buttonSmall)),(b=m.formLabel)!=null&&b.fontSize&&h.push(` --dr-form-label-font-size: ${m.formLabel.fontSize};`),(S=m.formLabel)!=null&&S.paddingBottom&&h.push(` --dr-form-label-padding-bottom: ${m.formLabel.paddingBottom};`),(_=m.checkbox)!=null&&_.size&&h.push(` --dr-checkbox-size: ${m.checkbox.size};`),(k=m.radio)!=null&&k.size&&h.push(` --dr-radio-size: ${m.radio.size};`),h},s=(m,h)=>`@media (max-width: ${m}) {
3
3
  :root {
4
4
  ${h.split(`
5
5
  `).map(b=>` ${b}`).join(`
@@ -15,7 +15,7 @@ ${n(a.default).join(`
15
15
  }`);const f=[[a.md,u.md],[a.sm,u.sm],[a.xs,u.xs]];for(const[m,h]of f){if(!m)continue;const b=n(m).join(`
16
16
  `);b&&c.push(s(h,b))}return t.textContent=c.join(`
17
17
 
18
- `),()=>{const m=document.getElementById(r);m&&document.head.removeChild(m)}},[e]),null};var Fe=e=>e.type==="checkbox",ye=e=>e instanceof Date,ee=e=>e==null;const $t=e=>typeof e=="object";var K=e=>!ee(e)&&!Array.isArray(e)&&$t(e)&&!ye(e),Lt=e=>K(e)&&e.target?Fe(e.target)?e.target.checked:e.target.value:e,Qr=e=>e.substring(0,e.search(/\.\d+(\.|$)/))||e,Nt=(e,r)=>e.has(Qr(r)),Xr=e=>{const r=e.constructor&&e.constructor.prototype;return K(r)&&r.hasOwnProperty("isPrototypeOf")},Ge=typeof window<"u"&&typeof window.HTMLElement<"u"&&typeof document<"u";function X(e){let r;const t=Array.isArray(e),o=typeof FileList<"u"?e instanceof FileList:!1;if(e instanceof Date)r=new Date(e);else if(!(Ge&&(e instanceof Blob||o))&&(t||K(e)))if(r=t?[]:Object.create(Object.getPrototypeOf(e)),!t&&!Xr(e))r=e;else for(const n in e)e.hasOwnProperty(n)&&(r[n]=X(e[n]));else return e;return r}var De=e=>/^\w*$/.test(e),Z=e=>e===void 0,Ze=e=>Array.isArray(e)?e.filter(Boolean):[],Ke=e=>Ze(e.replace(/["|']|\]/g,"").split(/\.|\[/)),x=(e,r,t)=>{if(!r||!K(e))return t;const o=(De(r)?[r]:Ke(r)).reduce((n,s)=>ee(n)?n:n[s],e);return Z(o)||o===e?Z(e[r])?t:e[r]:o},te=e=>typeof e=="boolean",W=(e,r,t)=>{let o=-1;const n=De(r)?[r]:Ke(r),s=n.length,a=s-1;for(;++o<s;){const l=n[o];let u=t;if(o!==a){const c=e[l];u=K(c)||Array.isArray(c)?c:isNaN(+n[o+1])?{}:[]}if(l==="__proto__"||l==="constructor"||l==="prototype")return;e[l]=u,e=e[l]}};const Oe={BLUR:"blur",FOCUS_OUT:"focusout",CHANGE:"change"},se={onBlur:"onBlur",onChange:"onChange",onSubmit:"onSubmit",onTouched:"onTouched",all:"all"},ue={max:"max",min:"min",maxLength:"maxLength",minLength:"minLength",pattern:"pattern",required:"required",validate:"validate"},Bt=g.createContext(null);Bt.displayName="HookFormContext";const Qe=()=>g.useContext(Bt);var Mt=(e,r,t,o=!0)=>{const n={defaultValues:r._defaultValues};for(const s in e)Object.defineProperty(n,s,{get:()=>{const a=s;return r._proxyFormState[a]!==se.all&&(r._proxyFormState[a]=!o||se.all),t&&(t[a]=!0),e[a]}});return n};const Xe=typeof window<"u"?g.useLayoutEffect:g.useEffect;function Jr(e){const r=Qe(),{control:t=r.control,disabled:o,name:n,exact:s}=e||{},[a,l]=g.useState(t._formState),u=g.useRef({isDirty:!1,isLoading:!1,dirtyFields:!1,touchedFields:!1,validatingFields:!1,isValidating:!1,isValid:!1,errors:!1});return Xe(()=>t._subscribe({name:n,formState:u.current,exact:s,callback:c=>{!o&&l({...t._formState,...c})}}),[n,o,s]),g.useEffect(()=>{u.current.isValid&&t._setValid(!0)},[t]),g.useMemo(()=>Mt(a,t,u.current,!1),[a,t])}var re=e=>typeof e=="string",Je=(e,r,t,o,n)=>re(e)?(o&&r.watch.add(e),x(t,e,n)):Array.isArray(e)?e.map(s=>(o&&r.watch.add(s),x(t,s))):(o&&(r.watchAll=!0),t),Ye=e=>ee(e)||!$t(e);function ae(e,r,t=new WeakSet){if(Ye(e)||Ye(r))return e===r;if(ye(e)&&ye(r))return e.getTime()===r.getTime();const o=Object.keys(e),n=Object.keys(r);if(o.length!==n.length)return!1;if(t.has(e)||t.has(r))return!0;t.add(e),t.add(r);for(const s of o){const a=e[s];if(!n.includes(s))return!1;if(s!=="ref"){const l=r[s];if(ye(a)&&ye(l)||K(a)&&K(l)||Array.isArray(a)&&Array.isArray(l)?!ae(a,l,t):a!==l)return!1}}return!0}function Yr(e){const r=Qe(),{control:t=r.control,name:o,defaultValue:n,disabled:s,exact:a,compute:l}=e||{},u=g.useRef(n),c=g.useRef(l),f=g.useRef(void 0),m=g.useRef(t),h=g.useRef(o);c.current=l;const[b,S]=g.useState(()=>{const E=t._getWatch(o,u.current);return c.current?c.current(E):E}),_=g.useCallback(E=>{const F=Je(o,t._names,E||t._formValues,!1,u.current);return c.current?c.current(F):F},[t._formValues,t._names,o]),k=g.useCallback(E=>{if(!s){const F=Je(o,t._names,E||t._formValues,!1,u.current);if(c.current){const N=c.current(F);ae(N,f.current)||(S(N),f.current=N)}else S(F)}},[t._formValues,t._names,s,o]);Xe(()=>((m.current!==t||!ae(h.current,o))&&(m.current=t,h.current=o,k()),t._subscribe({name:o,formState:{values:!0},exact:a,callback:E=>{k(E.values)}})),[t,a,o,k]),g.useEffect(()=>t._removeUnmounted());const V=m.current!==t,v=h.current,z=g.useMemo(()=>{if(s)return null;const E=!V&&!ae(v,o);return V||E?_():null},[s,V,o,v,_]);return z!==null?z:b}function Rr(e){const r=Qe(),{name:t,disabled:o,control:n=r.control,shouldUnregister:s,defaultValue:a}=e,l=Nt(n._names.array,t),u=g.useMemo(()=>x(n._formValues,t,x(n._defaultValues,t,a)),[n,t,a]),c=Yr({control:n,name:t,defaultValue:u,exact:!0}),f=Jr({control:n,name:t,exact:!0}),m=g.useRef(e),h=g.useRef(void 0),b=g.useRef(n.register(t,{...e.rules,value:c,...te(e.disabled)?{disabled:e.disabled}:{}}));m.current=e;const S=g.useMemo(()=>Object.defineProperties({},{invalid:{enumerable:!0,get:()=>!!x(f.errors,t)},isDirty:{enumerable:!0,get:()=>!!x(f.dirtyFields,t)},isTouched:{enumerable:!0,get:()=>!!x(f.touchedFields,t)},isValidating:{enumerable:!0,get:()=>!!x(f.validatingFields,t)},error:{enumerable:!0,get:()=>x(f.errors,t)}}),[f,t]),_=g.useCallback(z=>b.current.onChange({target:{value:Lt(z),name:t},type:Oe.CHANGE}),[t]),k=g.useCallback(()=>b.current.onBlur({target:{value:x(n._formValues,t),name:t},type:Oe.BLUR}),[t,n._formValues]),V=g.useCallback(z=>{const E=x(n._fields,t);E&&z&&(E._f.ref={focus:()=>z.focus&&z.focus(),select:()=>z.select&&z.select(),setCustomValidity:F=>z.setCustomValidity(F),reportValidity:()=>z.reportValidity()})},[n._fields,t]),v=g.useMemo(()=>({name:t,value:c,...te(o)||f.disabled?{disabled:f.disabled||o}:{},onChange:_,onBlur:k,ref:V}),[t,o,f.disabled,_,k,V,c]);return g.useEffect(()=>{const z=n._options.shouldUnregister||s,E=h.current;E&&E!==t&&!l&&n.unregister(E),n.register(t,{...m.current.rules,...te(m.current.disabled)?{disabled:m.current.disabled}:{}});const F=(N,P)=>{const O=x(n._fields,N);O&&O._f&&(O._f.mount=P)};if(F(t,!0),z){const N=X(x(n._options.defaultValues,t,m.current.defaultValue));W(n._defaultValues,t,N),Z(x(n._formValues,t))&&W(n._formValues,t,N)}return!l&&n.register(t),h.current=t,()=>{(l?z&&!n._state.action:z)?n.unregister(t):F(t,!1)}},[t,n,l,s]),g.useEffect(()=>{n._setDisabledField({disabled:o,name:t})},[o,t,n]),g.useMemo(()=>({field:v,formState:f,fieldState:S}),[v,f,S])}var Re=(e,r,t,o,n)=>r?{...t[e],types:{...t[e]&&t[e].types?t[e].types:{},[o]:n||!0}}:{},ze=e=>Array.isArray(e)?e:[e],At=()=>{let e=[];return{get observers(){return e},next:n=>{for(const s of e)s.next&&s.next(n)},subscribe:n=>(e.push(n),{unsubscribe:()=>{e=e.filter(s=>s!==n)}}),unsubscribe:()=>{e=[]}}};function Pt(e,r){const t={};for(const o in e)if(e.hasOwnProperty(o)){const n=e[o],s=r[o];if(n&&K(n)&&s){const a=Pt(n,s);K(a)&&(t[o]=a)}else e[o]&&(t[o]=s)}return t}var R=e=>K(e)&&!Object.keys(e).length,et=e=>e.type==="file",le=e=>typeof e=="function",Ie=e=>{if(!Ge)return!1;const r=e?e.ownerDocument:0;return e instanceof(r&&r.defaultView?r.defaultView.HTMLElement:HTMLElement)},Dt=e=>e.type==="select-multiple",tt=e=>e.type==="radio",eo=e=>tt(e)||Fe(e),rt=e=>Ie(e)&&e.isConnected;function to(e,r){const t=r.slice(0,-1).length;let o=0;for(;o<t;)e=Z(e)?o++:e[r[o++]];return e}function ro(e){for(const r in e)if(e.hasOwnProperty(r)&&!Z(e[r]))return!1;return!0}function Q(e,r){const t=Array.isArray(r)?r:De(r)?[r]:Ke(r),o=t.length===1?e:to(e,t),n=t.length-1,s=t[n];return o&&delete o[s],n!==0&&(K(o)&&R(o)||Array.isArray(o)&&ro(o))&&Q(e,t.slice(0,-1)),e}var oo=e=>{for(const r in e)if(le(e[r]))return!0;return!1};function Ot(e){return Array.isArray(e)||K(e)&&!oo(e)}function ot(e,r={}){for(const t in e)Ot(e[t])?(r[t]=Array.isArray(e[t])?[]:{},ot(e[t],r[t])):Z(e[t])||(r[t]=!0);return r}function be(e,r,t){t||(t=ot(r));for(const o in e)Ot(e[o])?Z(r)||Ye(t[o])?t[o]=ot(e[o],Array.isArray(e[o])?[]:{}):be(e[o],ee(r)?{}:r[o],t[o]):t[o]=!ae(e[o],r[o]);return t}const It={value:!1,isValid:!1},Tt={value:!0,isValid:!0};var Wt=e=>{if(Array.isArray(e)){if(e.length>1){const r=e.filter(t=>t&&t.checked&&!t.disabled).map(t=>t.value);return{value:r,isValid:!!r.length}}return e[0].checked&&!e[0].disabled?e[0].attributes&&!Z(e[0].attributes.value)?Z(e[0].value)||e[0].value===""?Tt:{value:e[0].value,isValid:!0}:Tt:It}return It},jt=(e,{valueAsNumber:r,valueAsDate:t,setValueAs:o})=>Z(e)?e:r?e===""?NaN:e&&+e:t&&re(e)?new Date(e):o?o(e):e;const Ht={isValid:!1,value:null};var Ut=e=>Array.isArray(e)?e.reduce((r,t)=>t&&t.checked&&!t.disabled?{isValid:!0,value:t.value}:r,Ht):Ht;function qt(e){const r=e.ref;return et(r)?r.files:tt(r)?Ut(e.refs).value:Dt(r)?[...r.selectedOptions].map(({value:t})=>t):Fe(r)?Wt(e.refs).value:jt(Z(r.value)?e.ref.value:r.value,e)}var no=(e,r,t,o)=>{const n={};for(const s of e){const a=x(r,s);a&&W(n,s,a._f)}return{criteriaMode:t,names:[...e],fields:n,shouldUseNativeValidation:o}},Te=e=>e instanceof RegExp,Ve=e=>Z(e)?e:Te(e)?e.source:K(e)?Te(e.value)?e.value.source:e.value:e,Gt=e=>({isOnSubmit:!e||e===se.onSubmit,isOnBlur:e===se.onBlur,isOnChange:e===se.onChange,isOnAll:e===se.all,isOnTouch:e===se.onTouched});const Zt="AsyncFunction";var so=e=>!!e&&!!e.validate&&!!(le(e.validate)&&e.validate.constructor.name===Zt||K(e.validate)&&Object.values(e.validate).find(r=>r.constructor.name===Zt)),ao=e=>e.mount&&(e.required||e.min||e.max||e.maxLength||e.minLength||e.pattern||e.validate),Kt=(e,r,t)=>!t&&(r.watchAll||r.watch.has(e)||[...r.watch].some(o=>e.startsWith(o)&&/^\.\w+/.test(e.slice(o.length))));const Ee=(e,r,t,o)=>{for(const n of t||Object.keys(e)){const s=x(e,n);if(s){const{_f:a,...l}=s;if(a){if(a.refs&&a.refs[0]&&r(a.refs[0],n)&&!o)return!0;if(a.ref&&r(a.ref,a.name)&&!o)return!0;if(Ee(l,r))break}else if(K(l)&&Ee(l,r))break}}};function Qt(e,r,t){const o=x(e,t);if(o||De(t))return{error:o,name:t};const n=t.split(".");for(;n.length;){const s=n.join("."),a=x(r,s),l=x(e,s);if(a&&!Array.isArray(a)&&t!==s)return{name:t};if(l&&l.type)return{name:s,error:l};if(l&&l.root&&l.root.type)return{name:`${s}.root`,error:l.root};n.pop()}return{name:t}}var lo=(e,r,t,o)=>{t(e);const{name:n,...s}=e;return R(s)||Object.keys(s).length>=Object.keys(r).length||Object.keys(s).find(a=>r[a]===(!o||se.all))},io=(e,r,t)=>!e||!r||e===r||ze(e).some(o=>o&&(t?o===r:o.startsWith(r)||r.startsWith(o))),co=(e,r,t,o,n)=>n.isOnAll?!1:!t&&n.isOnTouch?!(r||e):(t?o.isOnBlur:n.isOnBlur)?!e:(t?o.isOnChange:n.isOnChange)?e:!0,uo=(e,r)=>!Ze(x(e,r)).length&&Q(e,r),fo=(e,r,t)=>{const o=ze(x(e,t));return W(o,"root",r[t]),W(e,t,o),e};function Xt(e,r,t="validate"){if(re(e)||Array.isArray(e)&&e.every(re)||te(e)&&!e)return{type:t,message:re(e)?e:"",ref:r}}var Se=e=>K(e)&&!Te(e)?e:{value:e,message:""},Jt=async(e,r,t,o,n,s)=>{const{ref:a,refs:l,required:u,maxLength:c,minLength:f,min:m,max:h,pattern:b,validate:S,name:_,valueAsNumber:k,mount:V}=e._f,v=x(t,_);if(!V||r.has(_))return{};const z=l?l[0]:a,E=B=>{n&&z.reportValidity&&(z.setCustomValidity(te(B)?"":B||""),z.reportValidity())},F={},N=tt(a),P=Fe(a),O=N||P,A=(k||et(a))&&Z(a.value)&&Z(v)||Ie(a)&&a.value===""||v===""||Array.isArray(v)&&!v.length,H=Re.bind(null,_,o,F),G=(B,D,T,J=ue.maxLength,Y=ue.minLength)=>{const q=B?D:T;F[_]={type:B?J:Y,message:q,ref:a,...H(B?J:Y,q)}};if(s?!Array.isArray(v)||!v.length:u&&(!O&&(A||ee(v))||te(v)&&!v||P&&!Wt(l).isValid||N&&!Ut(l).isValid)){const{value:B,message:D}=re(u)?{value:!!u,message:u}:Se(u);if(B&&(F[_]={type:ue.required,message:D,ref:z,...H(ue.required,D)},!o))return E(D),F}if(!A&&(!ee(m)||!ee(h))){let B,D;const T=Se(h),J=Se(m);if(!ee(v)&&!isNaN(v)){const Y=a.valueAsNumber||v&&+v;ee(T.value)||(B=Y>T.value),ee(J.value)||(D=Y<J.value)}else{const Y=a.valueAsDate||new Date(v),q=_e=>new Date(new Date().toDateString()+" "+_e),de=a.type=="time",fe=a.type=="week";re(T.value)&&v&&(B=de?q(v)>q(T.value):fe?v>T.value:Y>new Date(T.value)),re(J.value)&&v&&(D=de?q(v)<q(J.value):fe?v<J.value:Y<new Date(J.value))}if((B||D)&&(G(!!B,T.message,J.message,ue.max,ue.min),!o))return E(F[_].message),F}if((c||f)&&!A&&(re(v)||s&&Array.isArray(v))){const B=Se(c),D=Se(f),T=!ee(B.value)&&v.length>+B.value,J=!ee(D.value)&&v.length<+D.value;if((T||J)&&(G(T,B.message,D.message),!o))return E(F[_].message),F}if(b&&!A&&re(v)){const{value:B,message:D}=Se(b);if(Te(B)&&!v.match(B)&&(F[_]={type:ue.pattern,message:D,ref:a,...H(ue.pattern,D)},!o))return E(D),F}if(S){if(le(S)){const B=await S(v,t),D=Xt(B,z);if(D&&(F[_]={...D,...H(ue.validate,D.message)},!o))return E(D.message),F}else if(K(S)){let B={};for(const D in S){if(!R(B)&&!o)break;const T=Xt(await S[D](v,t),z,D);T&&(B={...T,...H(D,T.message)},E(T.message),o&&(F[_]=B))}if(!R(B)&&(F[_]={ref:z,...B},!o))return F}}return E(!0),F};const mo={mode:se.onSubmit,reValidateMode:se.onChange,shouldFocusError:!0};function ho(e={}){let r={...mo,...e},t={submitCount:0,isDirty:!1,isReady:!1,isLoading:le(r.defaultValues),isValidating:!1,isSubmitted:!1,isSubmitting:!1,isSubmitSuccessful:!1,isValid:!1,touchedFields:{},dirtyFields:{},validatingFields:{},errors:r.errors||{},disabled:r.disabled||!1},o={},n=K(r.defaultValues)||K(r.values)?X(r.defaultValues||r.values)||{}:{},s=r.shouldUnregister?{}:X(n),a={action:!1,mount:!1,watch:!1},l={mount:new Set,disabled:new Set,unMount:new Set,array:new Set,watch:new Set},u,c=0;const f={isDirty:!1,dirtyFields:!1,validatingFields:!1,touchedFields:!1,isValidating:!1,isValid:!1,errors:!1};let m={...f};const h={array:At(),state:At()},b=r.criteriaMode===se.all,S=i=>y=>{clearTimeout(c),c=setTimeout(i,y)},_=async i=>{if(!r.disabled&&(f.isValid||m.isValid||i)){const y=r.resolver?R((await P()).errors):await A(o,!0);y!==t.isValid&&h.state.next({isValid:y})}},k=(i,y)=>{!r.disabled&&(f.isValidating||f.validatingFields||m.isValidating||m.validatingFields)&&((i||Array.from(l.mount)).forEach(p=>{p&&(y?W(t.validatingFields,p,y):Q(t.validatingFields,p))}),h.state.next({validatingFields:t.validatingFields,isValidating:!R(t.validatingFields)}))},V=(i,y=[],p,$,w=!0,C=!0)=>{if($&&p&&!r.disabled){if(a.action=!0,C&&Array.isArray(x(o,i))){const M=p(x(o,i),$.argA,$.argB);w&&W(o,i,M)}if(C&&Array.isArray(x(t.errors,i))){const M=p(x(t.errors,i),$.argA,$.argB);w&&W(t.errors,i,M),uo(t.errors,i)}if((f.touchedFields||m.touchedFields)&&C&&Array.isArray(x(t.touchedFields,i))){const M=p(x(t.touchedFields,i),$.argA,$.argB);w&&W(t.touchedFields,i,M)}(f.dirtyFields||m.dirtyFields)&&(t.dirtyFields=be(n,s)),h.state.next({name:i,isDirty:G(i,y),dirtyFields:t.dirtyFields,errors:t.errors,isValid:t.isValid})}else W(s,i,y)},v=(i,y)=>{W(t.errors,i,y),h.state.next({errors:t.errors})},z=i=>{t.errors=i,h.state.next({errors:t.errors,isValid:!1})},E=(i,y,p,$)=>{const w=x(o,i);if(w){const C=x(s,i,Z(p)?x(n,i):p);Z(C)||$&&$.defaultChecked||y?W(s,i,y?C:qt(w._f)):T(i,C),a.mount&&_()}},F=(i,y,p,$,w)=>{let C=!1,M=!1;const j={name:i};if(!r.disabled){if(!p||$){(f.isDirty||m.isDirty)&&(M=t.isDirty,t.isDirty=j.isDirty=G(),C=M!==j.isDirty);const U=ae(x(n,i),y);M=!!x(t.dirtyFields,i),U?Q(t.dirtyFields,i):W(t.dirtyFields,i,!0),j.dirtyFields=t.dirtyFields,C=C||(f.dirtyFields||m.dirtyFields)&&M!==!U}if(p){const U=x(t.touchedFields,i);U||(W(t.touchedFields,i,p),j.touchedFields=t.touchedFields,C=C||(f.touchedFields||m.touchedFields)&&U!==p)}C&&w&&h.state.next(j)}return C?j:{}},N=(i,y,p,$)=>{const w=x(t.errors,i),C=(f.isValid||m.isValid)&&te(y)&&t.isValid!==y;if(r.delayError&&p?(u=S(()=>v(i,p)),u(r.delayError)):(clearTimeout(c),u=null,p?W(t.errors,i,p):Q(t.errors,i)),(p?!ae(w,p):w)||!R($)||C){const M={...$,...C&&te(y)?{isValid:y}:{},errors:t.errors,name:i};t={...t,...M},h.state.next(M)}},P=async i=>{k(i,!0);const y=await r.resolver(s,r.context,no(i||l.mount,o,r.criteriaMode,r.shouldUseNativeValidation));return k(i),y},O=async i=>{const{errors:y}=await P(i);if(i)for(const p of i){const $=x(y,p);$?W(t.errors,p,$):Q(t.errors,p)}else t.errors=y;return y},A=async(i,y,p={valid:!0})=>{for(const $ in i){const w=i[$];if(w){const{_f:C,...M}=w;if(C){const j=l.array.has(C.name),U=w._f&&so(w._f);U&&f.validatingFields&&k([C.name],!0);const ne=await Jt(w,l.disabled,s,b,r.shouldUseNativeValidation&&!y,j);if(U&&f.validatingFields&&k([C.name]),ne[C.name]&&(p.valid=!1,y))break;!y&&(x(ne,C.name)?j?fo(t.errors,ne,C.name):W(t.errors,C.name,ne[C.name]):Q(t.errors,C.name))}!R(M)&&await A(M,y,p)}}return p.valid},H=()=>{for(const i of l.unMount){const y=x(o,i);y&&(y._f.refs?y._f.refs.every(p=>!rt(p)):!rt(y._f.ref))&&_t(i)}l.unMount=new Set},G=(i,y)=>!r.disabled&&(i&&y&&W(s,i,y),!ae(_e(),n)),B=(i,y,p)=>Je(i,l,{...a.mount?s:Z(y)?n:re(i)?{[i]:y}:y},p,y),D=i=>Ze(x(a.mount?s:n,i,r.shouldUnregister?x(n,i,[]):[])),T=(i,y,p={})=>{const $=x(o,i);let w=y;if($){const C=$._f;C&&(!C.disabled&&W(s,i,jt(y,C)),w=Ie(C.ref)&&ee(y)?"":y,Dt(C.ref)?[...C.ref.options].forEach(M=>M.selected=w.includes(M.value)):C.refs?Fe(C.ref)?C.refs.forEach(M=>{(!M.defaultChecked||!M.disabled)&&(Array.isArray(w)?M.checked=!!w.find(j=>j===M.value):M.checked=w===M.value||!!w)}):C.refs.forEach(M=>M.checked=M.value===w):et(C.ref)?C.ref.value="":(C.ref.value=w,C.ref.type||h.state.next({name:i,values:X(s)})))}(p.shouldDirty||p.shouldTouch)&&F(i,w,p.shouldTouch,p.shouldDirty,!0),p.shouldValidate&&fe(i)},J=(i,y,p)=>{for(const $ in y){if(!y.hasOwnProperty($))return;const w=y[$],C=i+"."+$,M=x(o,C);(l.array.has(i)||K(w)||M&&!M._f)&&!ye(w)?J(C,w,p):T(C,w,p)}},Y=(i,y,p={})=>{const $=x(o,i),w=l.array.has(i),C=X(y);W(s,i,C),w?(h.array.next({name:i,values:X(s)}),(f.isDirty||f.dirtyFields||m.isDirty||m.dirtyFields)&&p.shouldDirty&&h.state.next({name:i,dirtyFields:be(n,s),isDirty:G(i,C)})):$&&!$._f&&!ee(C)?J(i,C,p):T(i,C,p),Kt(i,l)&&h.state.next({...t,name:i}),h.state.next({name:a.mount?i:void 0,values:X(s)})},q=async i=>{a.mount=!0;const y=i.target;let p=y.name,$=!0;const w=x(o,p),C=U=>{$=Number.isNaN(U)||ye(U)&&isNaN(U.getTime())||ae(U,x(s,p,U))},M=Gt(r.mode),j=Gt(r.reValidateMode);if(w){let U,ne;const He=y.type?qt(w._f):Lt(i),he=i.type===Oe.BLUR||i.type===Oe.FOCUS_OUT,Mn=!ao(w._f)&&!r.resolver&&!x(t.errors,p)&&!w._f.deps||co(he,x(t.touchedFields,p),t.isSubmitted,j,M),St=Kt(p,l,he);W(s,p,He),he?(!y||!y.readOnly)&&(w._f.onBlur&&w._f.onBlur(i),u&&u(0)):w._f.onChange&&w._f.onChange(i);const kt=F(p,He,he),An=!R(kt)||St;if(!he&&h.state.next({name:p,type:i.type,values:X(s)}),Mn)return(f.isValid||m.isValid)&&(r.mode==="onBlur"?he&&_():he||_()),An&&h.state.next({name:p,...St?{}:kt});if(!he&&St&&h.state.next({...t}),r.resolver){const{errors:Ir}=await P([p]);if(C(He),$){const Pn=Qt(t.errors,o,p),Tr=Qt(Ir,o,Pn.name||p);U=Tr.error,p=Tr.name,ne=R(Ir)}}else k([p],!0),U=(await Jt(w,l.disabled,s,b,r.shouldUseNativeValidation))[p],k([p]),C(He),$&&(U?ne=!1:(f.isValid||m.isValid)&&(ne=await A(o,!0)));$&&(w._f.deps&&(!Array.isArray(w._f.deps)||w._f.deps.length>0)&&fe(w._f.deps),N(p,ne,U,kt))}},de=(i,y)=>{if(x(t.errors,y)&&i.focus)return i.focus(),1},fe=async(i,y={})=>{let p,$;const w=ze(i);if(r.resolver){const C=await O(Z(i)?i:w);p=R(C),$=i?!w.some(M=>x(C,M)):p}else i?($=(await Promise.all(w.map(async C=>{const M=x(o,C);return await A(M&&M._f?{[C]:M}:M)}))).every(Boolean),!(!$&&!t.isValid)&&_()):$=p=await A(o);return h.state.next({...!re(i)||(f.isValid||m.isValid)&&p!==t.isValid?{}:{name:i},...r.resolver||!i?{isValid:p}:{},errors:t.errors}),y.shouldFocus&&!$&&Ee(o,de,i?w:l.mount),$},_e=(i,y)=>{let p={...a.mount?s:n};return y&&(p=Pt(y.dirtyFields?t.dirtyFields:t.touchedFields,p)),Z(i)?p:re(i)?x(p,i):i.map($=>x(p,$))},Lr=(i,y)=>({invalid:!!x((y||t).errors,i),isDirty:!!x((y||t).dirtyFields,i),error:x((y||t).errors,i),isValidating:!!x(t.validatingFields,i),isTouched:!!x((y||t).touchedFields,i)}),zn=i=>{i&&ze(i).forEach(y=>Q(t.errors,y)),h.state.next({errors:i?t.errors:{}})},Nr=(i,y,p)=>{const $=(x(o,i,{_f:{}})._f||{}).ref,w=x(t.errors,i)||{},{ref:C,message:M,type:j,...U}=w;W(t.errors,i,{...U,...y,ref:$}),h.state.next({name:i,errors:t.errors,isValid:!1}),p&&p.shouldFocus&&$&&$.focus&&$.focus()},Vn=(i,y)=>le(i)?h.state.subscribe({next:p=>"values"in p&&i(B(void 0,y),p)}):B(i,y,!0),Br=i=>h.state.subscribe({next:y=>{io(i.name,y.name,i.exact)&&lo(y,i.formState||f,Bn,i.reRenderRoot)&&i.callback({values:{...s},...t,...y,defaultValues:n})}}).unsubscribe,En=i=>(a.mount=!0,m={...m,...i.formState},Br({...i,formState:m})),_t=(i,y={})=>{for(const p of i?ze(i):l.mount)l.mount.delete(p),l.array.delete(p),y.keepValue||(Q(o,p),Q(s,p)),!y.keepError&&Q(t.errors,p),!y.keepDirty&&Q(t.dirtyFields,p),!y.keepTouched&&Q(t.touchedFields,p),!y.keepIsValidating&&Q(t.validatingFields,p),!r.shouldUnregister&&!y.keepDefaultValue&&Q(n,p);h.state.next({values:X(s)}),h.state.next({...t,...y.keepDirty?{isDirty:G()}:{}}),!y.keepIsValid&&_()},Mr=({disabled:i,name:y})=>{(te(i)&&a.mount||i||l.disabled.has(y))&&(i?l.disabled.add(y):l.disabled.delete(y))},vt=(i,y={})=>{let p=x(o,i);const $=te(y.disabled)||te(r.disabled);return W(o,i,{...p||{},_f:{...p&&p._f?p._f:{ref:{name:i}},name:i,mount:!0,...y}}),l.mount.add(i),p?Mr({disabled:te(y.disabled)?y.disabled:r.disabled,name:i}):E(i,!0,y.value),{...$?{disabled:y.disabled||r.disabled}:{},...r.progressive?{required:!!y.required,min:Ve(y.min),max:Ve(y.max),minLength:Ve(y.minLength),maxLength:Ve(y.maxLength),pattern:Ve(y.pattern)}:{},name:i,onChange:q,onBlur:q,ref:w=>{if(w){vt(i,y),p=x(o,i);const C=Z(w.value)&&w.querySelectorAll&&w.querySelectorAll("input,select,textarea")[0]||w,M=eo(C),j=p._f.refs||[];if(M?j.find(U=>U===C):C===p._f.ref)return;W(o,i,{_f:{...p._f,...M?{refs:[...j.filter(rt),C,...Array.isArray(x(n,i))?[{}]:[]],ref:{type:C.type,name:i}}:{ref:C}}}),E(i,!1,void 0,C)}else p=x(o,i,{}),p._f&&(p._f.mount=!1),(r.shouldUnregister||y.shouldUnregister)&&!(Nt(l.array,i)&&a.action)&&l.unMount.add(i)}}},bt=()=>r.shouldFocusError&&Ee(o,de,l.mount),$n=i=>{te(i)&&(h.state.next({disabled:i}),Ee(o,(y,p)=>{const $=x(o,p);$&&(y.disabled=$._f.disabled||i,Array.isArray($._f.refs)&&$._f.refs.forEach(w=>{w.disabled=$._f.disabled||i}))},0,!1))},Ar=(i,y)=>async p=>{let $;p&&(p.preventDefault&&p.preventDefault(),p.persist&&p.persist());let w=X(s);if(h.state.next({isSubmitting:!0}),r.resolver){const{errors:C,values:M}=await P();t.errors=C,w=X(M)}else await A(o);if(l.disabled.size)for(const C of l.disabled)Q(w,C);if(Q(t.errors,"root"),R(t.errors)){h.state.next({errors:{}});try{await i(w,p)}catch(C){$=C}}else y&&await y({...t.errors},p),bt(),setTimeout(bt);if(h.state.next({isSubmitted:!0,isSubmitting:!1,isSubmitSuccessful:R(t.errors)&&!$,submitCount:t.submitCount+1,errors:t.errors}),$)throw $},Ln=(i,y={})=>{x(o,i)&&(Z(y.defaultValue)?Y(i,X(x(n,i))):(Y(i,y.defaultValue),W(n,i,X(y.defaultValue))),y.keepTouched||Q(t.touchedFields,i),y.keepDirty||(Q(t.dirtyFields,i),t.isDirty=y.defaultValue?G(i,X(x(n,i))):G()),y.keepError||(Q(t.errors,i),f.isValid&&_()),h.state.next({...t}))},Pr=(i,y={})=>{const p=i?X(i):n,$=X(p),w=R(i),C=w?n:$;if(y.keepDefaultValues||(n=p),!y.keepValues){if(y.keepDirtyValues){const M=new Set([...l.mount,...Object.keys(be(n,s))]);for(const j of Array.from(M))x(t.dirtyFields,j)?W(C,j,x(s,j)):Y(j,x(C,j))}else{if(Ge&&Z(i))for(const M of l.mount){const j=x(o,M);if(j&&j._f){const U=Array.isArray(j._f.refs)?j._f.refs[0]:j._f.ref;if(Ie(U)){const ne=U.closest("form");if(ne){ne.reset();break}}}}if(y.keepFieldsRef)for(const M of l.mount)Y(M,x(C,M));else o={}}s=r.shouldUnregister?y.keepDefaultValues?X(n):{}:X(C),h.array.next({values:{...C}}),h.state.next({values:{...C}})}l={mount:y.keepDirtyValues?l.mount:new Set,unMount:new Set,array:new Set,disabled:new Set,watch:new Set,watchAll:!1,focus:""},a.mount=!f.isValid||!!y.keepIsValid||!!y.keepDirtyValues||!r.shouldUnregister&&!R(C),a.watch=!!r.shouldUnregister,h.state.next({submitCount:y.keepSubmitCount?t.submitCount:0,isDirty:w?!1:y.keepDirty?t.isDirty:!!(y.keepDefaultValues&&!ae(i,n)),isSubmitted:y.keepIsSubmitted?t.isSubmitted:!1,dirtyFields:w?{}:y.keepDirtyValues?y.keepDefaultValues&&s?be(n,s):t.dirtyFields:y.keepDefaultValues&&i?be(n,i):y.keepDirty?t.dirtyFields:{},touchedFields:y.keepTouched?t.touchedFields:{},errors:y.keepErrors?t.errors:{},isSubmitSuccessful:y.keepIsSubmitSuccessful?t.isSubmitSuccessful:!1,isSubmitting:!1,defaultValues:n})},Dr=(i,y)=>Pr(le(i)?i(s):i,y),Nn=(i,y={})=>{const p=x(o,i),$=p&&p._f;if($){const w=$.refs?$.refs[0]:$.ref;w.focus&&(w.focus(),y.shouldSelect&&le(w.select)&&w.select())}},Bn=i=>{t={...t,...i}},Or={control:{register:vt,unregister:_t,getFieldState:Lr,handleSubmit:Ar,setError:Nr,_subscribe:Br,_runSchema:P,_focusError:bt,_getWatch:B,_getDirty:G,_setValid:_,_setFieldArray:V,_setDisabledField:Mr,_setErrors:z,_getFieldArray:D,_reset:Pr,_resetDefaultValues:()=>le(r.defaultValues)&&r.defaultValues().then(i=>{Dr(i,r.resetOptions),h.state.next({isLoading:!1})}),_removeUnmounted:H,_disableForm:$n,_subjects:h,_proxyFormState:f,get _fields(){return o},get _formValues(){return s},get _state(){return a},set _state(i){a=i},get _defaultValues(){return n},get _names(){return l},set _names(i){l=i},get _formState(){return t},get _options(){return r},set _options(i){r={...r,...i}}},subscribe:En,trigger:fe,register:vt,handleSubmit:Ar,watch:Vn,setValue:Y,getValues:_e,reset:Dr,resetField:Ln,clearErrors:zn,unregister:_t,setError:Nr,setFocus:Nn,getFieldState:Lr};return{...Or,formControl:Or}}function yo(e={}){const r=g.useRef(void 0),t=g.useRef(void 0),[o,n]=g.useState({isDirty:!1,isValidating:!1,isLoading:le(e.defaultValues),isSubmitted:!1,isSubmitting:!1,isSubmitSuccessful:!1,isValid:!1,submitCount:0,dirtyFields:{},touchedFields:{},validatingFields:{},errors:e.errors||{},disabled:e.disabled||!1,isReady:!1,defaultValues:le(e.defaultValues)?void 0:e.defaultValues});if(!r.current)if(e.formControl)r.current={...e.formControl,formState:o},e.defaultValues&&!le(e.defaultValues)&&e.formControl.reset(e.defaultValues,e.resetOptions);else{const{formControl:a,...l}=ho(e);r.current={...l,formState:o}}const s=r.current.control;return s._options=e,Xe(()=>{const a=s._subscribe({formState:s._proxyFormState,callback:()=>n({...s._formState}),reRenderRoot:!0});return n(l=>({...l,isReady:!0})),s._formState.isReady=!0,a},[s]),g.useEffect(()=>s._disableForm(e.disabled),[s,e.disabled]),g.useEffect(()=>{e.mode&&(s._options.mode=e.mode),e.reValidateMode&&(s._options.reValidateMode=e.reValidateMode)},[s,e.mode,e.reValidateMode]),g.useEffect(()=>{e.errors&&(s._setErrors(e.errors),s._focusError())},[s,e.errors]),g.useEffect(()=>{e.shouldUnregister&&s._subjects.state.next({values:s._getWatch()})},[s,e.shouldUnregister]),g.useEffect(()=>{if(s._proxyFormState.isDirty){const a=s._getDirty();a!==o.isDirty&&s._subjects.state.next({isDirty:a})}},[s,o.isDirty]),g.useEffect(()=>{e.values&&!ae(e.values,t.current)?(s._reset(e.values,{keepFieldsRef:!0,...s._options.resetOptions}),t.current=e.values,n(a=>({...a}))):s._resetDefaultValues()},[s,e.values]),g.useEffect(()=>{s._state.mount||(s._setValid(),s._state.mount=!0),s._state.watch&&(s._state.watch=!1,s._subjects.state.next({...s._formState})),s._removeUnmounted()}),r.current.formState=Mt(o,s),r.current}const Yt=(e,r,t)=>{if(e&&"reportValidity"in e){const o=x(t,r);e.setCustomValidity(o&&o.message||""),e.reportValidity()}},nt=(e,r)=>{for(const t in r.fields){const o=r.fields[t];o&&o.ref&&"reportValidity"in o.ref?Yt(o.ref,t,e):o&&o.refs&&o.refs.forEach(n=>Yt(n,t,e))}},Rt=(e,r)=>{r.shouldUseNativeValidation&&nt(e,r);const t={};for(const o in e){const n=x(r.fields,o),s=Object.assign(e[o]||{},{ref:n&&n.ref});if(go(r.names||Object.keys(e),o)){const a=Object.assign({},x(t,o));W(a,"root",s),W(t,o,a)}else W(t,o,s)}return t},go=(e,r)=>{const t=er(r);return e.some(o=>er(o).match(`^${t}\\.\\d+`))};function er(e){return e.replace(/\]|\[/g,"")}function tr(e,r,t){function o(l,u){var c;Object.defineProperty(l,"_zod",{value:l._zod??{},enumerable:!1}),(c=l._zod).traits??(c.traits=new Set),l._zod.traits.add(e),r(l,u);for(const f in a.prototype)f in l||Object.defineProperty(l,f,{value:a.prototype[f].bind(l)});l._zod.constr=a,l._zod.def=u}const n=(t==null?void 0:t.Parent)??Object;class s extends n{}Object.defineProperty(s,"name",{value:e});function a(l){var u;const c=t!=null&&t.Parent?new s:this;o(c,l),(u=c._zod).deferred??(u.deferred=[]);for(const f of c._zod.deferred)f();return c}return Object.defineProperty(a,"init",{value:o}),Object.defineProperty(a,Symbol.hasInstance,{value:l=>{var u,c;return t!=null&&t.Parent&&l instanceof t.Parent?!0:(c=(u=l==null?void 0:l._zod)==null?void 0:u.traits)==null?void 0:c.has(e)}}),Object.defineProperty(a,"name",{value:e}),a}class po extends Error{constructor(){super("Encountered Promise during synchronous parse. Use .parseAsync() instead.")}}const _o={};function rr(e){return _o}function vo(e,r){return typeof r=="bigint"?r.toString():r}const or="captureStackTrace"in Error?Error.captureStackTrace:(...e)=>{};function We(e){return typeof e=="string"?e:e==null?void 0:e.message}function nr(e,r,t){var n,s,a,l,u,c;const o={...e,path:e.path??[]};if(!e.message){const f=We((a=(s=(n=e.inst)==null?void 0:n._zod.def)==null?void 0:s.error)==null?void 0:a.call(s,e))??We((l=r==null?void 0:r.error)==null?void 0:l.call(r,e))??We((u=t.customError)==null?void 0:u.call(t,e))??We((c=t.localeError)==null?void 0:c.call(t,e))??"Invalid input";o.message=f}return delete o.inst,delete o.continue,r!=null&&r.reportInput||delete o.input,o}const sr=(e,r)=>{e.name="$ZodError",Object.defineProperty(e,"_zod",{value:e._zod,enumerable:!1}),Object.defineProperty(e,"issues",{value:r,enumerable:!1}),e.message=JSON.stringify(r,vo,2),Object.defineProperty(e,"toString",{value:()=>e.message,enumerable:!1})},bo=tr("$ZodError",sr),ar=tr("$ZodError",sr,{Parent:Error}),So=(e=>(r,t,o,n)=>{const s=o?Object.assign(o,{async:!1}):{async:!1},a=r._zod.run({value:t,issues:[]},s);if(a instanceof Promise)throw new po;if(a.issues.length){const l=new((n==null?void 0:n.Err)??e)(a.issues.map(u=>nr(u,s,rr())));throw or(l,n==null?void 0:n.callee),l}return a.value})(ar),ko=(e=>async(r,t,o,n)=>{const s=o?Object.assign(o,{async:!0}):{async:!0};let a=r._zod.run({value:t,issues:[]},s);if(a instanceof Promise&&(a=await a),a.issues.length){const l=new((n==null?void 0:n.Err)??e)(a.issues.map(u=>nr(u,s,rr())));throw or(l,n==null?void 0:n.callee),l}return a.value})(ar);function lr(e,r){try{var t=e()}catch(o){return r(o)}return t&&t.then?t.then(void 0,r):t}function Co(e,r){for(var t={};e.length;){var o=e[0],n=o.code,s=o.message,a=o.path.join(".");if(!t[a])if("unionErrors"in o){var l=o.unionErrors[0].errors[0];t[a]={message:l.message,type:l.code}}else t[a]={message:s,type:n};if("unionErrors"in o&&o.unionErrors.forEach(function(f){return f.errors.forEach(function(m){return e.push(m)})}),r){var u=t[a].types,c=u&&u[o.code];t[a]=Re(a,r,t,n,c?[].concat(c,o.message):o.message)}e.shift()}return t}function wo(e,r){for(var t={};e.length;){var o=e[0],n=o.code,s=o.message,a=o.path.join(".");if(!t[a])if(o.code==="invalid_union"&&o.errors.length>0){var l=o.errors[0][0];t[a]={message:l.message,type:l.code}}else t[a]={message:s,type:n};if(o.code==="invalid_union"&&o.errors.forEach(function(f){return f.forEach(function(m){return e.push(m)})}),r){var u=t[a].types,c=u&&u[o.code];t[a]=Re(a,r,t,n,c?[].concat(c,o.message):o.message)}e.shift()}return t}function xo(e,r,t){if(t===void 0&&(t={}),(function(o){return"_def"in o&&typeof o._def=="object"&&"typeName"in o._def})(e))return function(o,n,s){try{return Promise.resolve(lr(function(){return Promise.resolve(e[t.mode==="sync"?"parse":"parseAsync"](o,r)).then(function(a){return s.shouldUseNativeValidation&&nt({},s),{errors:{},values:t.raw?Object.assign({},o):a}})},function(a){if((function(l){return Array.isArray(l==null?void 0:l.issues)})(a))return{values:{},errors:Rt(Co(a.errors,!s.shouldUseNativeValidation&&s.criteriaMode==="all"),s)};throw a}))}catch(a){return Promise.reject(a)}};if((function(o){return"_zod"in o&&typeof o._zod=="object"})(e))return function(o,n,s){try{return Promise.resolve(lr(function(){return Promise.resolve((t.mode==="sync"?So:ko)(e,o,r)).then(function(a){return s.shouldUseNativeValidation&&nt({},s),{errors:{},values:t.raw?Object.assign({},o):a}})},function(a){if((function(l){return l instanceof bo})(a))return{values:{},errors:Rt(wo(a.issues,!s.shouldUseNativeValidation&&s.criteriaMode==="all"),s)};throw a}))}catch(a){return Promise.reject(a)}};throw new Error("Invalid input: not a Zod schema")}const ir=g.createContext(null);function cr(){const e=g.useContext(ir);if(!e)throw new Error("useFormContext must be used within a Form component");return e}function Fo({onSubmit:e,children:r,schema:t,defaultValues:o,mode:n="onSubmit",reValidateMode:s="onChange",className:a,style:l,formProps:u}){const c=yo({resolver:t?xo(t):void 0,defaultValues:o,mode:n,reValidateMode:s}),f=c.handleSubmit(e);return d.jsx(ir.Provider,{value:c,children:d.jsx("form",{...u,className:a,style:l,onSubmit:f,children:typeof r=="function"?r(c):r})})}const zo=Fo,Vo={formError:"FormError-module__formError___kaUBn"},dr=({color:e,children:r,className:t,style:o,divProps:n})=>{const s=I(),a={"--form-error-margin-top":`calc(${s.fonts.rhythm} * 0.17)`,color:e||s.colors.error,...o},l=[Vo.formError,t].filter(Boolean).join(" ");return d.jsx("div",{...n,className:l,style:a,role:"alert","aria-live":"polite",children:r})},ke={formGroup:"FormGroup-module__formGroup___aVI-B",inputWrapper:"FormGroup-module__inputWrapper___429QE",indented:"FormGroup-module__indented___t61iz",disabled:"FormGroup-module__disabled___W-tJ0",required:"FormGroup-module__required___mO3xA"},ur=({disabled:e=!1,error:r=!1,required:t=!1,indent:o=!1,name:n,label:s,errorMessage:a,labelProps:l,children:u,className:c,style:f,divProps:m})=>{const h=I(),b=[ke.formGroup,r?ke.error:"",e?ke.disabled:"",c].filter(Boolean).join(" "),S={"--form-group-margin-bottom":`calc(${h.fonts.rhythm} * 0.35)`,...f},_=g.Children.map(u,k=>{if(g.isValidElement(k)){const V={};if(e&&k.props.disabled===void 0&&(V.disabled=!0),r&&k.props.error===void 0&&(V.error=!0),n&&k.props.id===void 0&&k.type!==g.Fragment&&(V.id=n),Object.keys(V).length>0)return g.cloneElement(k,V)}return k});return d.jsxs("div",{...m,className:b,style:S,children:[s&&d.jsxs(Ae,{htmlFor:n,disabled:e,error:r,...l,children:[s,t&&d.jsxs("span",{className:ke.required,"aria-label":"required",children:[" ","*"]})]}),d.jsx("div",{className:`${ke.inputWrapper} ${o?ke.indented:""}`,children:_}),r&&a&&d.jsx(dr,{children:a})]})};function me({name:e,label:r,required:t,children:o,rules:n,disabled:s,className:a,style:l,indent:u,labelProps:c}){const{control:f}=cr(),{field:m,fieldState:{error:h}}=Rr({name:e,control:f,rules:n});return d.jsx(ur,{label:r,name:e,error:!!h,errorMessage:h==null?void 0:h.message,disabled:s,required:t,className:a,style:l,indent:u,labelProps:c,children:o({value:m.value,onChange:m.onChange,onBlur:m.onBlur,name:m.name,error:!!h,indent:u})})}const st={input:"Input-module__input___WjT81",sizeSmall:"Input-module__sizeSmall___NFvsi",sizeLarge:"Input-module__sizeLarge___4Boj3"},Eo=({color:e="#000",disabled:r=!1,fontSize:t="1em",placeholderOpacity:o=.3})=>({borderColor:e,color:e,fontSize:t,opacity:r?.3:1,placeholderOpacity:o}),fr=({disabled:e=!1,error:r=!1,color:t,size:o="large",id:n,name:s="",placeholder:a,placeholderOpacity:l=.3,type:u="text",value:c="",onChange:f,onBlur:m,className:h,style:b,inputProps:S})=>{const _=I(),k=_.colors.error,V=r?k:t||_.colors.primary,v=Eo({color:V,disabled:e,placeholderOpacity:l}),z={"--placeholder-opacity":v.placeholderOpacity,borderColor:v.borderColor,borderWidth:_.border.width,borderRadius:_.border.radius,color:v.color,opacity:v.opacity,...b},E=[st.input,o==="small"?st.sizeSmall:st.sizeLarge,h].filter(Boolean).join(" ");return d.jsx("input",{...S,className:E,disabled:e,id:n,name:s,onChange:f,onBlur:m,placeholder:a,type:u,value:c,style:z})};function $o({name:e,label:r,required:t,rules:o,disabled:n,className:s,style:a,...l}){return d.jsx(me,{name:e,label:r,required:t,rules:o,disabled:n,className:s,style:a,children:({value:u,onChange:c,onBlur:f,name:m,error:h})=>d.jsx(fr,{...l,name:m,value:u||"",onChange:b=>c(b.target.value),onBlur:f,error:h})})}const at={textarea:"Textarea-module__textarea___Z-y6g",sizeSmall:"Textarea-module__sizeSmall___HHFEM",sizeLarge:"Textarea-module__sizeLarge___5a3sf"},Lo=({color:e="#000",disabled:r=!1,placeholderOpacity:t=.3})=>({color:e,borderColor:e,opacity:r?.3:1,placeholderOpacity:t}),mr=({disabled:e=!1,error:r=!1,color:t,size:o="large",id:n,name:s="",placeholder:a,placeholderOpacity:l=.3,rows:u=3,value:c="",onChange:f,onBlur:m,className:h,style:b,textareaProps:S})=>{const _=I(),k=_.colors.error,V=r?k:t||_.colors.primary,v=Lo({color:V,disabled:e,placeholderOpacity:l}),z={"--placeholder-opacity":v.placeholderOpacity,borderColor:v.borderColor,borderWidth:_.border.width,borderRadius:_.border.radius,color:v.color,opacity:v.opacity,...b},E=[at.textarea,o==="small"?at.sizeSmall:at.sizeLarge,h].filter(Boolean).join(" ");return d.jsx("textarea",{...S,className:E,disabled:e,id:n,name:s,onChange:f,onBlur:m,placeholder:a,rows:u,value:c,style:z})};function No({name:e,label:r,required:t,rules:o,disabled:n,className:s,style:a,...l}){return d.jsx(me,{name:e,label:r,required:t,rules:o,disabled:n,className:s,style:a,children:({value:u,onChange:c,onBlur:f,name:m,error:h})=>d.jsx(mr,{...l,name:m,value:u||"",onChange:b=>c(b.target.value),onBlur:f,error:h})})}const lt={select:"Select-module__select___cjdcr",sizeSmall:"Select-module__sizeSmall___i1quj",sizeLarge:"Select-module__sizeLarge___eBA1T"},Bo=({color:e="#000",disabled:r=!1})=>({color:e,borderColor:e,cursor:r?"default":"pointer",opacity:r?.3:1,backgroundImage:(s=>{const a=`
18
+ `),()=>{const m=document.getElementById(r);m&&document.head.removeChild(m)}},[e]),null};var Fe=e=>e.type==="checkbox",ye=e=>e instanceof Date,ee=e=>e==null;const $t=e=>typeof e=="object";var K=e=>!ee(e)&&!Array.isArray(e)&&$t(e)&&!ye(e),Lt=e=>K(e)&&e.target?Fe(e.target)?e.target.checked:e.target.value:e,Xr=e=>e.substring(0,e.search(/\.\d+(\.|$)/))||e,Nt=(e,r)=>e.has(Xr(r)),Jr=e=>{const r=e.constructor&&e.constructor.prototype;return K(r)&&r.hasOwnProperty("isPrototypeOf")},Ge=typeof window<"u"&&typeof window.HTMLElement<"u"&&typeof document<"u";function X(e){let r;const t=Array.isArray(e),o=typeof FileList<"u"?e instanceof FileList:!1;if(e instanceof Date)r=new Date(e);else if(!(Ge&&(e instanceof Blob||o))&&(t||K(e)))if(r=t?[]:Object.create(Object.getPrototypeOf(e)),!t&&!Jr(e))r=e;else for(const n in e)e.hasOwnProperty(n)&&(r[n]=X(e[n]));else return e;return r}var De=e=>/^\w*$/.test(e),Z=e=>e===void 0,Ze=e=>Array.isArray(e)?e.filter(Boolean):[],Ke=e=>Ze(e.replace(/["|']|\]/g,"").split(/\.|\[/)),x=(e,r,t)=>{if(!r||!K(e))return t;const o=(De(r)?[r]:Ke(r)).reduce((n,s)=>ee(n)?n:n[s],e);return Z(o)||o===e?Z(e[r])?t:e[r]:o},te=e=>typeof e=="boolean",j=(e,r,t)=>{let o=-1;const n=De(r)?[r]:Ke(r),s=n.length,a=s-1;for(;++o<s;){const l=n[o];let u=t;if(o!==a){const c=e[l];u=K(c)||Array.isArray(c)?c:isNaN(+n[o+1])?{}:[]}if(l==="__proto__"||l==="constructor"||l==="prototype")return;e[l]=u,e=e[l]}};const Oe={BLUR:"blur",FOCUS_OUT:"focusout",CHANGE:"change"},se={onBlur:"onBlur",onChange:"onChange",onSubmit:"onSubmit",onTouched:"onTouched",all:"all"},ue={max:"max",min:"min",maxLength:"maxLength",minLength:"minLength",pattern:"pattern",required:"required",validate:"validate"},Bt=g.createContext(null);Bt.displayName="HookFormContext";const Qe=()=>g.useContext(Bt);var Mt=(e,r,t,o=!0)=>{const n={defaultValues:r._defaultValues};for(const s in e)Object.defineProperty(n,s,{get:()=>{const a=s;return r._proxyFormState[a]!==se.all&&(r._proxyFormState[a]=!o||se.all),t&&(t[a]=!0),e[a]}});return n};const Xe=typeof window<"u"?g.useLayoutEffect:g.useEffect;function Yr(e){const r=Qe(),{control:t=r.control,disabled:o,name:n,exact:s}=e||{},[a,l]=g.useState(t._formState),u=g.useRef({isDirty:!1,isLoading:!1,dirtyFields:!1,touchedFields:!1,validatingFields:!1,isValidating:!1,isValid:!1,errors:!1});return Xe(()=>t._subscribe({name:n,formState:u.current,exact:s,callback:c=>{!o&&l({...t._formState,...c})}}),[n,o,s]),g.useEffect(()=>{u.current.isValid&&t._setValid(!0)},[t]),g.useMemo(()=>Mt(a,t,u.current,!1),[a,t])}var re=e=>typeof e=="string",Je=(e,r,t,o,n)=>re(e)?(o&&r.watch.add(e),x(t,e,n)):Array.isArray(e)?e.map(s=>(o&&r.watch.add(s),x(t,s))):(o&&(r.watchAll=!0),t),Ye=e=>ee(e)||!$t(e);function ae(e,r,t=new WeakSet){if(Ye(e)||Ye(r))return e===r;if(ye(e)&&ye(r))return e.getTime()===r.getTime();const o=Object.keys(e),n=Object.keys(r);if(o.length!==n.length)return!1;if(t.has(e)||t.has(r))return!0;t.add(e),t.add(r);for(const s of o){const a=e[s];if(!n.includes(s))return!1;if(s!=="ref"){const l=r[s];if(ye(a)&&ye(l)||K(a)&&K(l)||Array.isArray(a)&&Array.isArray(l)?!ae(a,l,t):a!==l)return!1}}return!0}function Rr(e){const r=Qe(),{control:t=r.control,name:o,defaultValue:n,disabled:s,exact:a,compute:l}=e||{},u=g.useRef(n),c=g.useRef(l),f=g.useRef(void 0),m=g.useRef(t),h=g.useRef(o);c.current=l;const[b,S]=g.useState(()=>{const E=t._getWatch(o,u.current);return c.current?c.current(E):E}),_=g.useCallback(E=>{const F=Je(o,t._names,E||t._formValues,!1,u.current);return c.current?c.current(F):F},[t._formValues,t._names,o]),k=g.useCallback(E=>{if(!s){const F=Je(o,t._names,E||t._formValues,!1,u.current);if(c.current){const N=c.current(F);ae(N,f.current)||(S(N),f.current=N)}else S(F)}},[t._formValues,t._names,s,o]);Xe(()=>((m.current!==t||!ae(h.current,o))&&(m.current=t,h.current=o,k()),t._subscribe({name:o,formState:{values:!0},exact:a,callback:E=>{k(E.values)}})),[t,a,o,k]),g.useEffect(()=>t._removeUnmounted());const V=m.current!==t,v=h.current,z=g.useMemo(()=>{if(s)return null;const E=!V&&!ae(v,o);return V||E?_():null},[s,V,o,v,_]);return z!==null?z:b}function eo(e){const r=Qe(),{name:t,disabled:o,control:n=r.control,shouldUnregister:s,defaultValue:a}=e,l=Nt(n._names.array,t),u=g.useMemo(()=>x(n._formValues,t,x(n._defaultValues,t,a)),[n,t,a]),c=Rr({control:n,name:t,defaultValue:u,exact:!0}),f=Yr({control:n,name:t,exact:!0}),m=g.useRef(e),h=g.useRef(void 0),b=g.useRef(n.register(t,{...e.rules,value:c,...te(e.disabled)?{disabled:e.disabled}:{}}));m.current=e;const S=g.useMemo(()=>Object.defineProperties({},{invalid:{enumerable:!0,get:()=>!!x(f.errors,t)},isDirty:{enumerable:!0,get:()=>!!x(f.dirtyFields,t)},isTouched:{enumerable:!0,get:()=>!!x(f.touchedFields,t)},isValidating:{enumerable:!0,get:()=>!!x(f.validatingFields,t)},error:{enumerable:!0,get:()=>x(f.errors,t)}}),[f,t]),_=g.useCallback(z=>b.current.onChange({target:{value:Lt(z),name:t},type:Oe.CHANGE}),[t]),k=g.useCallback(()=>b.current.onBlur({target:{value:x(n._formValues,t),name:t},type:Oe.BLUR}),[t,n._formValues]),V=g.useCallback(z=>{const E=x(n._fields,t);E&&z&&(E._f.ref={focus:()=>z.focus&&z.focus(),select:()=>z.select&&z.select(),setCustomValidity:F=>z.setCustomValidity(F),reportValidity:()=>z.reportValidity()})},[n._fields,t]),v=g.useMemo(()=>({name:t,value:c,...te(o)||f.disabled?{disabled:f.disabled||o}:{},onChange:_,onBlur:k,ref:V}),[t,o,f.disabled,_,k,V,c]);return g.useEffect(()=>{const z=n._options.shouldUnregister||s,E=h.current;E&&E!==t&&!l&&n.unregister(E),n.register(t,{...m.current.rules,...te(m.current.disabled)?{disabled:m.current.disabled}:{}});const F=(N,P)=>{const O=x(n._fields,N);O&&O._f&&(O._f.mount=P)};if(F(t,!0),z){const N=X(x(n._options.defaultValues,t,m.current.defaultValue));j(n._defaultValues,t,N),Z(x(n._formValues,t))&&j(n._formValues,t,N)}return!l&&n.register(t),h.current=t,()=>{(l?z&&!n._state.action:z)?n.unregister(t):F(t,!1)}},[t,n,l,s]),g.useEffect(()=>{n._setDisabledField({disabled:o,name:t})},[o,t,n]),g.useMemo(()=>({field:v,formState:f,fieldState:S}),[v,f,S])}var Re=(e,r,t,o,n)=>r?{...t[e],types:{...t[e]&&t[e].types?t[e].types:{},[o]:n||!0}}:{},ze=e=>Array.isArray(e)?e:[e],At=()=>{let e=[];return{get observers(){return e},next:n=>{for(const s of e)s.next&&s.next(n)},subscribe:n=>(e.push(n),{unsubscribe:()=>{e=e.filter(s=>s!==n)}}),unsubscribe:()=>{e=[]}}};function Pt(e,r){const t={};for(const o in e)if(e.hasOwnProperty(o)){const n=e[o],s=r[o];if(n&&K(n)&&s){const a=Pt(n,s);K(a)&&(t[o]=a)}else e[o]&&(t[o]=s)}return t}var R=e=>K(e)&&!Object.keys(e).length,et=e=>e.type==="file",le=e=>typeof e=="function",Ie=e=>{if(!Ge)return!1;const r=e?e.ownerDocument:0;return e instanceof(r&&r.defaultView?r.defaultView.HTMLElement:HTMLElement)},Dt=e=>e.type==="select-multiple",tt=e=>e.type==="radio",to=e=>tt(e)||Fe(e),rt=e=>Ie(e)&&e.isConnected;function ro(e,r){const t=r.slice(0,-1).length;let o=0;for(;o<t;)e=Z(e)?o++:e[r[o++]];return e}function oo(e){for(const r in e)if(e.hasOwnProperty(r)&&!Z(e[r]))return!1;return!0}function Q(e,r){const t=Array.isArray(r)?r:De(r)?[r]:Ke(r),o=t.length===1?e:ro(e,t),n=t.length-1,s=t[n];return o&&delete o[s],n!==0&&(K(o)&&R(o)||Array.isArray(o)&&oo(o))&&Q(e,t.slice(0,-1)),e}var no=e=>{for(const r in e)if(le(e[r]))return!0;return!1};function Ot(e){return Array.isArray(e)||K(e)&&!no(e)}function ot(e,r={}){for(const t in e)Ot(e[t])?(r[t]=Array.isArray(e[t])?[]:{},ot(e[t],r[t])):Z(e[t])||(r[t]=!0);return r}function be(e,r,t){t||(t=ot(r));for(const o in e)Ot(e[o])?Z(r)||Ye(t[o])?t[o]=ot(e[o],Array.isArray(e[o])?[]:{}):be(e[o],ee(r)?{}:r[o],t[o]):t[o]=!ae(e[o],r[o]);return t}const It={value:!1,isValid:!1},Tt={value:!0,isValid:!0};var jt=e=>{if(Array.isArray(e)){if(e.length>1){const r=e.filter(t=>t&&t.checked&&!t.disabled).map(t=>t.value);return{value:r,isValid:!!r.length}}return e[0].checked&&!e[0].disabled?e[0].attributes&&!Z(e[0].attributes.value)?Z(e[0].value)||e[0].value===""?Tt:{value:e[0].value,isValid:!0}:Tt:It}return It},Wt=(e,{valueAsNumber:r,valueAsDate:t,setValueAs:o})=>Z(e)?e:r?e===""?NaN:e&&+e:t&&re(e)?new Date(e):o?o(e):e;const Ht={isValid:!1,value:null};var Ut=e=>Array.isArray(e)?e.reduce((r,t)=>t&&t.checked&&!t.disabled?{isValid:!0,value:t.value}:r,Ht):Ht;function qt(e){const r=e.ref;return et(r)?r.files:tt(r)?Ut(e.refs).value:Dt(r)?[...r.selectedOptions].map(({value:t})=>t):Fe(r)?jt(e.refs).value:Wt(Z(r.value)?e.ref.value:r.value,e)}var so=(e,r,t,o)=>{const n={};for(const s of e){const a=x(r,s);a&&j(n,s,a._f)}return{criteriaMode:t,names:[...e],fields:n,shouldUseNativeValidation:o}},Te=e=>e instanceof RegExp,Ve=e=>Z(e)?e:Te(e)?e.source:K(e)?Te(e.value)?e.value.source:e.value:e,Gt=e=>({isOnSubmit:!e||e===se.onSubmit,isOnBlur:e===se.onBlur,isOnChange:e===se.onChange,isOnAll:e===se.all,isOnTouch:e===se.onTouched});const Zt="AsyncFunction";var ao=e=>!!e&&!!e.validate&&!!(le(e.validate)&&e.validate.constructor.name===Zt||K(e.validate)&&Object.values(e.validate).find(r=>r.constructor.name===Zt)),lo=e=>e.mount&&(e.required||e.min||e.max||e.maxLength||e.minLength||e.pattern||e.validate),Kt=(e,r,t)=>!t&&(r.watchAll||r.watch.has(e)||[...r.watch].some(o=>e.startsWith(o)&&/^\.\w+/.test(e.slice(o.length))));const Ee=(e,r,t,o)=>{for(const n of t||Object.keys(e)){const s=x(e,n);if(s){const{_f:a,...l}=s;if(a){if(a.refs&&a.refs[0]&&r(a.refs[0],n)&&!o)return!0;if(a.ref&&r(a.ref,a.name)&&!o)return!0;if(Ee(l,r))break}else if(K(l)&&Ee(l,r))break}}};function Qt(e,r,t){const o=x(e,t);if(o||De(t))return{error:o,name:t};const n=t.split(".");for(;n.length;){const s=n.join("."),a=x(r,s),l=x(e,s);if(a&&!Array.isArray(a)&&t!==s)return{name:t};if(l&&l.type)return{name:s,error:l};if(l&&l.root&&l.root.type)return{name:`${s}.root`,error:l.root};n.pop()}return{name:t}}var io=(e,r,t,o)=>{t(e);const{name:n,...s}=e;return R(s)||Object.keys(s).length>=Object.keys(r).length||Object.keys(s).find(a=>r[a]===(!o||se.all))},co=(e,r,t)=>!e||!r||e===r||ze(e).some(o=>o&&(t?o===r:o.startsWith(r)||r.startsWith(o))),uo=(e,r,t,o,n)=>n.isOnAll?!1:!t&&n.isOnTouch?!(r||e):(t?o.isOnBlur:n.isOnBlur)?!e:(t?o.isOnChange:n.isOnChange)?e:!0,fo=(e,r)=>!Ze(x(e,r)).length&&Q(e,r),mo=(e,r,t)=>{const o=ze(x(e,t));return j(o,"root",r[t]),j(e,t,o),e};function Xt(e,r,t="validate"){if(re(e)||Array.isArray(e)&&e.every(re)||te(e)&&!e)return{type:t,message:re(e)?e:"",ref:r}}var Se=e=>K(e)&&!Te(e)?e:{value:e,message:""},Jt=async(e,r,t,o,n,s)=>{const{ref:a,refs:l,required:u,maxLength:c,minLength:f,min:m,max:h,pattern:b,validate:S,name:_,valueAsNumber:k,mount:V}=e._f,v=x(t,_);if(!V||r.has(_))return{};const z=l?l[0]:a,E=B=>{n&&z.reportValidity&&(z.setCustomValidity(te(B)?"":B||""),z.reportValidity())},F={},N=tt(a),P=Fe(a),O=N||P,A=(k||et(a))&&Z(a.value)&&Z(v)||Ie(a)&&a.value===""||v===""||Array.isArray(v)&&!v.length,H=Re.bind(null,_,o,F),G=(B,D,T,J=ue.maxLength,Y=ue.minLength)=>{const q=B?D:T;F[_]={type:B?J:Y,message:q,ref:a,...H(B?J:Y,q)}};if(s?!Array.isArray(v)||!v.length:u&&(!O&&(A||ee(v))||te(v)&&!v||P&&!jt(l).isValid||N&&!Ut(l).isValid)){const{value:B,message:D}=re(u)?{value:!!u,message:u}:Se(u);if(B&&(F[_]={type:ue.required,message:D,ref:z,...H(ue.required,D)},!o))return E(D),F}if(!A&&(!ee(m)||!ee(h))){let B,D;const T=Se(h),J=Se(m);if(!ee(v)&&!isNaN(v)){const Y=a.valueAsNumber||v&&+v;ee(T.value)||(B=Y>T.value),ee(J.value)||(D=Y<J.value)}else{const Y=a.valueAsDate||new Date(v),q=_e=>new Date(new Date().toDateString()+" "+_e),de=a.type=="time",fe=a.type=="week";re(T.value)&&v&&(B=de?q(v)>q(T.value):fe?v>T.value:Y>new Date(T.value)),re(J.value)&&v&&(D=de?q(v)<q(J.value):fe?v<J.value:Y<new Date(J.value))}if((B||D)&&(G(!!B,T.message,J.message,ue.max,ue.min),!o))return E(F[_].message),F}if((c||f)&&!A&&(re(v)||s&&Array.isArray(v))){const B=Se(c),D=Se(f),T=!ee(B.value)&&v.length>+B.value,J=!ee(D.value)&&v.length<+D.value;if((T||J)&&(G(T,B.message,D.message),!o))return E(F[_].message),F}if(b&&!A&&re(v)){const{value:B,message:D}=Se(b);if(Te(B)&&!v.match(B)&&(F[_]={type:ue.pattern,message:D,ref:a,...H(ue.pattern,D)},!o))return E(D),F}if(S){if(le(S)){const B=await S(v,t),D=Xt(B,z);if(D&&(F[_]={...D,...H(ue.validate,D.message)},!o))return E(D.message),F}else if(K(S)){let B={};for(const D in S){if(!R(B)&&!o)break;const T=Xt(await S[D](v,t),z,D);T&&(B={...T,...H(D,T.message)},E(T.message),o&&(F[_]=B))}if(!R(B)&&(F[_]={ref:z,...B},!o))return F}}return E(!0),F};const ho={mode:se.onSubmit,reValidateMode:se.onChange,shouldFocusError:!0};function yo(e={}){let r={...ho,...e},t={submitCount:0,isDirty:!1,isReady:!1,isLoading:le(r.defaultValues),isValidating:!1,isSubmitted:!1,isSubmitting:!1,isSubmitSuccessful:!1,isValid:!1,touchedFields:{},dirtyFields:{},validatingFields:{},errors:r.errors||{},disabled:r.disabled||!1},o={},n=K(r.defaultValues)||K(r.values)?X(r.defaultValues||r.values)||{}:{},s=r.shouldUnregister?{}:X(n),a={action:!1,mount:!1,watch:!1},l={mount:new Set,disabled:new Set,unMount:new Set,array:new Set,watch:new Set},u,c=0;const f={isDirty:!1,dirtyFields:!1,validatingFields:!1,touchedFields:!1,isValidating:!1,isValid:!1,errors:!1};let m={...f};const h={array:At(),state:At()},b=r.criteriaMode===se.all,S=i=>y=>{clearTimeout(c),c=setTimeout(i,y)},_=async i=>{if(!r.disabled&&(f.isValid||m.isValid||i)){const y=r.resolver?R((await P()).errors):await A(o,!0);y!==t.isValid&&h.state.next({isValid:y})}},k=(i,y)=>{!r.disabled&&(f.isValidating||f.validatingFields||m.isValidating||m.validatingFields)&&((i||Array.from(l.mount)).forEach(p=>{p&&(y?j(t.validatingFields,p,y):Q(t.validatingFields,p))}),h.state.next({validatingFields:t.validatingFields,isValidating:!R(t.validatingFields)}))},V=(i,y=[],p,$,w=!0,C=!0)=>{if($&&p&&!r.disabled){if(a.action=!0,C&&Array.isArray(x(o,i))){const M=p(x(o,i),$.argA,$.argB);w&&j(o,i,M)}if(C&&Array.isArray(x(t.errors,i))){const M=p(x(t.errors,i),$.argA,$.argB);w&&j(t.errors,i,M),fo(t.errors,i)}if((f.touchedFields||m.touchedFields)&&C&&Array.isArray(x(t.touchedFields,i))){const M=p(x(t.touchedFields,i),$.argA,$.argB);w&&j(t.touchedFields,i,M)}(f.dirtyFields||m.dirtyFields)&&(t.dirtyFields=be(n,s)),h.state.next({name:i,isDirty:G(i,y),dirtyFields:t.dirtyFields,errors:t.errors,isValid:t.isValid})}else j(s,i,y)},v=(i,y)=>{j(t.errors,i,y),h.state.next({errors:t.errors})},z=i=>{t.errors=i,h.state.next({errors:t.errors,isValid:!1})},E=(i,y,p,$)=>{const w=x(o,i);if(w){const C=x(s,i,Z(p)?x(n,i):p);Z(C)||$&&$.defaultChecked||y?j(s,i,y?C:qt(w._f)):T(i,C),a.mount&&_()}},F=(i,y,p,$,w)=>{let C=!1,M=!1;const W={name:i};if(!r.disabled){if(!p||$){(f.isDirty||m.isDirty)&&(M=t.isDirty,t.isDirty=W.isDirty=G(),C=M!==W.isDirty);const U=ae(x(n,i),y);M=!!x(t.dirtyFields,i),U?Q(t.dirtyFields,i):j(t.dirtyFields,i,!0),W.dirtyFields=t.dirtyFields,C=C||(f.dirtyFields||m.dirtyFields)&&M!==!U}if(p){const U=x(t.touchedFields,i);U||(j(t.touchedFields,i,p),W.touchedFields=t.touchedFields,C=C||(f.touchedFields||m.touchedFields)&&U!==p)}C&&w&&h.state.next(W)}return C?W:{}},N=(i,y,p,$)=>{const w=x(t.errors,i),C=(f.isValid||m.isValid)&&te(y)&&t.isValid!==y;if(r.delayError&&p?(u=S(()=>v(i,p)),u(r.delayError)):(clearTimeout(c),u=null,p?j(t.errors,i,p):Q(t.errors,i)),(p?!ae(w,p):w)||!R($)||C){const M={...$,...C&&te(y)?{isValid:y}:{},errors:t.errors,name:i};t={...t,...M},h.state.next(M)}},P=async i=>{k(i,!0);const y=await r.resolver(s,r.context,so(i||l.mount,o,r.criteriaMode,r.shouldUseNativeValidation));return k(i),y},O=async i=>{const{errors:y}=await P(i);if(i)for(const p of i){const $=x(y,p);$?j(t.errors,p,$):Q(t.errors,p)}else t.errors=y;return y},A=async(i,y,p={valid:!0})=>{for(const $ in i){const w=i[$];if(w){const{_f:C,...M}=w;if(C){const W=l.array.has(C.name),U=w._f&&ao(w._f);U&&f.validatingFields&&k([C.name],!0);const ne=await Jt(w,l.disabled,s,b,r.shouldUseNativeValidation&&!y,W);if(U&&f.validatingFields&&k([C.name]),ne[C.name]&&(p.valid=!1,y))break;!y&&(x(ne,C.name)?W?mo(t.errors,ne,C.name):j(t.errors,C.name,ne[C.name]):Q(t.errors,C.name))}!R(M)&&await A(M,y,p)}}return p.valid},H=()=>{for(const i of l.unMount){const y=x(o,i);y&&(y._f.refs?y._f.refs.every(p=>!rt(p)):!rt(y._f.ref))&&_t(i)}l.unMount=new Set},G=(i,y)=>!r.disabled&&(i&&y&&j(s,i,y),!ae(_e(),n)),B=(i,y,p)=>Je(i,l,{...a.mount?s:Z(y)?n:re(i)?{[i]:y}:y},p,y),D=i=>Ze(x(a.mount?s:n,i,r.shouldUnregister?x(n,i,[]):[])),T=(i,y,p={})=>{const $=x(o,i);let w=y;if($){const C=$._f;C&&(!C.disabled&&j(s,i,Wt(y,C)),w=Ie(C.ref)&&ee(y)?"":y,Dt(C.ref)?[...C.ref.options].forEach(M=>M.selected=w.includes(M.value)):C.refs?Fe(C.ref)?C.refs.forEach(M=>{(!M.defaultChecked||!M.disabled)&&(Array.isArray(w)?M.checked=!!w.find(W=>W===M.value):M.checked=w===M.value||!!w)}):C.refs.forEach(M=>M.checked=M.value===w):et(C.ref)?C.ref.value="":(C.ref.value=w,C.ref.type||h.state.next({name:i,values:X(s)})))}(p.shouldDirty||p.shouldTouch)&&F(i,w,p.shouldTouch,p.shouldDirty,!0),p.shouldValidate&&fe(i)},J=(i,y,p)=>{for(const $ in y){if(!y.hasOwnProperty($))return;const w=y[$],C=i+"."+$,M=x(o,C);(l.array.has(i)||K(w)||M&&!M._f)&&!ye(w)?J(C,w,p):T(C,w,p)}},Y=(i,y,p={})=>{const $=x(o,i),w=l.array.has(i),C=X(y);j(s,i,C),w?(h.array.next({name:i,values:X(s)}),(f.isDirty||f.dirtyFields||m.isDirty||m.dirtyFields)&&p.shouldDirty&&h.state.next({name:i,dirtyFields:be(n,s),isDirty:G(i,C)})):$&&!$._f&&!ee(C)?J(i,C,p):T(i,C,p),Kt(i,l)&&h.state.next({...t,name:i}),h.state.next({name:a.mount?i:void 0,values:X(s)})},q=async i=>{a.mount=!0;const y=i.target;let p=y.name,$=!0;const w=x(o,p),C=U=>{$=Number.isNaN(U)||ye(U)&&isNaN(U.getTime())||ae(U,x(s,p,U))},M=Gt(r.mode),W=Gt(r.reValidateMode);if(w){let U,ne;const He=y.type?qt(w._f):Lt(i),he=i.type===Oe.BLUR||i.type===Oe.FOCUS_OUT,An=!lo(w._f)&&!r.resolver&&!x(t.errors,p)&&!w._f.deps||uo(he,x(t.touchedFields,p),t.isSubmitted,W,M),St=Kt(p,l,he);j(s,p,He),he?(!y||!y.readOnly)&&(w._f.onBlur&&w._f.onBlur(i),u&&u(0)):w._f.onChange&&w._f.onChange(i);const kt=F(p,He,he),Pn=!R(kt)||St;if(!he&&h.state.next({name:p,type:i.type,values:X(s)}),An)return(f.isValid||m.isValid)&&(r.mode==="onBlur"?he&&_():he||_()),Pn&&h.state.next({name:p,...St?{}:kt});if(!he&&St&&h.state.next({...t}),r.resolver){const{errors:Tr}=await P([p]);if(C(He),$){const Dn=Qt(t.errors,o,p),jr=Qt(Tr,o,Dn.name||p);U=jr.error,p=jr.name,ne=R(Tr)}}else k([p],!0),U=(await Jt(w,l.disabled,s,b,r.shouldUseNativeValidation))[p],k([p]),C(He),$&&(U?ne=!1:(f.isValid||m.isValid)&&(ne=await A(o,!0)));$&&(w._f.deps&&(!Array.isArray(w._f.deps)||w._f.deps.length>0)&&fe(w._f.deps),N(p,ne,U,kt))}},de=(i,y)=>{if(x(t.errors,y)&&i.focus)return i.focus(),1},fe=async(i,y={})=>{let p,$;const w=ze(i);if(r.resolver){const C=await O(Z(i)?i:w);p=R(C),$=i?!w.some(M=>x(C,M)):p}else i?($=(await Promise.all(w.map(async C=>{const M=x(o,C);return await A(M&&M._f?{[C]:M}:M)}))).every(Boolean),!(!$&&!t.isValid)&&_()):$=p=await A(o);return h.state.next({...!re(i)||(f.isValid||m.isValid)&&p!==t.isValid?{}:{name:i},...r.resolver||!i?{isValid:p}:{},errors:t.errors}),y.shouldFocus&&!$&&Ee(o,de,i?w:l.mount),$},_e=(i,y)=>{let p={...a.mount?s:n};return y&&(p=Pt(y.dirtyFields?t.dirtyFields:t.touchedFields,p)),Z(i)?p:re(i)?x(p,i):i.map($=>x(p,$))},Nr=(i,y)=>({invalid:!!x((y||t).errors,i),isDirty:!!x((y||t).dirtyFields,i),error:x((y||t).errors,i),isValidating:!!x(t.validatingFields,i),isTouched:!!x((y||t).touchedFields,i)}),Vn=i=>{i&&ze(i).forEach(y=>Q(t.errors,y)),h.state.next({errors:i?t.errors:{}})},Br=(i,y,p)=>{const $=(x(o,i,{_f:{}})._f||{}).ref,w=x(t.errors,i)||{},{ref:C,message:M,type:W,...U}=w;j(t.errors,i,{...U,...y,ref:$}),h.state.next({name:i,errors:t.errors,isValid:!1}),p&&p.shouldFocus&&$&&$.focus&&$.focus()},En=(i,y)=>le(i)?h.state.subscribe({next:p=>"values"in p&&i(B(void 0,y),p)}):B(i,y,!0),Mr=i=>h.state.subscribe({next:y=>{co(i.name,y.name,i.exact)&&io(y,i.formState||f,Mn,i.reRenderRoot)&&i.callback({values:{...s},...t,...y,defaultValues:n})}}).unsubscribe,$n=i=>(a.mount=!0,m={...m,...i.formState},Mr({...i,formState:m})),_t=(i,y={})=>{for(const p of i?ze(i):l.mount)l.mount.delete(p),l.array.delete(p),y.keepValue||(Q(o,p),Q(s,p)),!y.keepError&&Q(t.errors,p),!y.keepDirty&&Q(t.dirtyFields,p),!y.keepTouched&&Q(t.touchedFields,p),!y.keepIsValidating&&Q(t.validatingFields,p),!r.shouldUnregister&&!y.keepDefaultValue&&Q(n,p);h.state.next({values:X(s)}),h.state.next({...t,...y.keepDirty?{isDirty:G()}:{}}),!y.keepIsValid&&_()},Ar=({disabled:i,name:y})=>{(te(i)&&a.mount||i||l.disabled.has(y))&&(i?l.disabled.add(y):l.disabled.delete(y))},vt=(i,y={})=>{let p=x(o,i);const $=te(y.disabled)||te(r.disabled);return j(o,i,{...p||{},_f:{...p&&p._f?p._f:{ref:{name:i}},name:i,mount:!0,...y}}),l.mount.add(i),p?Ar({disabled:te(y.disabled)?y.disabled:r.disabled,name:i}):E(i,!0,y.value),{...$?{disabled:y.disabled||r.disabled}:{},...r.progressive?{required:!!y.required,min:Ve(y.min),max:Ve(y.max),minLength:Ve(y.minLength),maxLength:Ve(y.maxLength),pattern:Ve(y.pattern)}:{},name:i,onChange:q,onBlur:q,ref:w=>{if(w){vt(i,y),p=x(o,i);const C=Z(w.value)&&w.querySelectorAll&&w.querySelectorAll("input,select,textarea")[0]||w,M=to(C),W=p._f.refs||[];if(M?W.find(U=>U===C):C===p._f.ref)return;j(o,i,{_f:{...p._f,...M?{refs:[...W.filter(rt),C,...Array.isArray(x(n,i))?[{}]:[]],ref:{type:C.type,name:i}}:{ref:C}}}),E(i,!1,void 0,C)}else p=x(o,i,{}),p._f&&(p._f.mount=!1),(r.shouldUnregister||y.shouldUnregister)&&!(Nt(l.array,i)&&a.action)&&l.unMount.add(i)}}},bt=()=>r.shouldFocusError&&Ee(o,de,l.mount),Ln=i=>{te(i)&&(h.state.next({disabled:i}),Ee(o,(y,p)=>{const $=x(o,p);$&&(y.disabled=$._f.disabled||i,Array.isArray($._f.refs)&&$._f.refs.forEach(w=>{w.disabled=$._f.disabled||i}))},0,!1))},Pr=(i,y)=>async p=>{let $;p&&(p.preventDefault&&p.preventDefault(),p.persist&&p.persist());let w=X(s);if(h.state.next({isSubmitting:!0}),r.resolver){const{errors:C,values:M}=await P();t.errors=C,w=X(M)}else await A(o);if(l.disabled.size)for(const C of l.disabled)Q(w,C);if(Q(t.errors,"root"),R(t.errors)){h.state.next({errors:{}});try{await i(w,p)}catch(C){$=C}}else y&&await y({...t.errors},p),bt(),setTimeout(bt);if(h.state.next({isSubmitted:!0,isSubmitting:!1,isSubmitSuccessful:R(t.errors)&&!$,submitCount:t.submitCount+1,errors:t.errors}),$)throw $},Nn=(i,y={})=>{x(o,i)&&(Z(y.defaultValue)?Y(i,X(x(n,i))):(Y(i,y.defaultValue),j(n,i,X(y.defaultValue))),y.keepTouched||Q(t.touchedFields,i),y.keepDirty||(Q(t.dirtyFields,i),t.isDirty=y.defaultValue?G(i,X(x(n,i))):G()),y.keepError||(Q(t.errors,i),f.isValid&&_()),h.state.next({...t}))},Dr=(i,y={})=>{const p=i?X(i):n,$=X(p),w=R(i),C=w?n:$;if(y.keepDefaultValues||(n=p),!y.keepValues){if(y.keepDirtyValues){const M=new Set([...l.mount,...Object.keys(be(n,s))]);for(const W of Array.from(M))x(t.dirtyFields,W)?j(C,W,x(s,W)):Y(W,x(C,W))}else{if(Ge&&Z(i))for(const M of l.mount){const W=x(o,M);if(W&&W._f){const U=Array.isArray(W._f.refs)?W._f.refs[0]:W._f.ref;if(Ie(U)){const ne=U.closest("form");if(ne){ne.reset();break}}}}if(y.keepFieldsRef)for(const M of l.mount)Y(M,x(C,M));else o={}}s=r.shouldUnregister?y.keepDefaultValues?X(n):{}:X(C),h.array.next({values:{...C}}),h.state.next({values:{...C}})}l={mount:y.keepDirtyValues?l.mount:new Set,unMount:new Set,array:new Set,disabled:new Set,watch:new Set,watchAll:!1,focus:""},a.mount=!f.isValid||!!y.keepIsValid||!!y.keepDirtyValues||!r.shouldUnregister&&!R(C),a.watch=!!r.shouldUnregister,h.state.next({submitCount:y.keepSubmitCount?t.submitCount:0,isDirty:w?!1:y.keepDirty?t.isDirty:!!(y.keepDefaultValues&&!ae(i,n)),isSubmitted:y.keepIsSubmitted?t.isSubmitted:!1,dirtyFields:w?{}:y.keepDirtyValues?y.keepDefaultValues&&s?be(n,s):t.dirtyFields:y.keepDefaultValues&&i?be(n,i):y.keepDirty?t.dirtyFields:{},touchedFields:y.keepTouched?t.touchedFields:{},errors:y.keepErrors?t.errors:{},isSubmitSuccessful:y.keepIsSubmitSuccessful?t.isSubmitSuccessful:!1,isSubmitting:!1,defaultValues:n})},Or=(i,y)=>Dr(le(i)?i(s):i,y),Bn=(i,y={})=>{const p=x(o,i),$=p&&p._f;if($){const w=$.refs?$.refs[0]:$.ref;w.focus&&(w.focus(),y.shouldSelect&&le(w.select)&&w.select())}},Mn=i=>{t={...t,...i}},Ir={control:{register:vt,unregister:_t,getFieldState:Nr,handleSubmit:Pr,setError:Br,_subscribe:Mr,_runSchema:P,_focusError:bt,_getWatch:B,_getDirty:G,_setValid:_,_setFieldArray:V,_setDisabledField:Ar,_setErrors:z,_getFieldArray:D,_reset:Dr,_resetDefaultValues:()=>le(r.defaultValues)&&r.defaultValues().then(i=>{Or(i,r.resetOptions),h.state.next({isLoading:!1})}),_removeUnmounted:H,_disableForm:Ln,_subjects:h,_proxyFormState:f,get _fields(){return o},get _formValues(){return s},get _state(){return a},set _state(i){a=i},get _defaultValues(){return n},get _names(){return l},set _names(i){l=i},get _formState(){return t},get _options(){return r},set _options(i){r={...r,...i}}},subscribe:$n,trigger:fe,register:vt,handleSubmit:Pr,watch:En,setValue:Y,getValues:_e,reset:Or,resetField:Nn,clearErrors:Vn,unregister:_t,setError:Br,setFocus:Bn,getFieldState:Nr};return{...Ir,formControl:Ir}}function go(e={}){const r=g.useRef(void 0),t=g.useRef(void 0),[o,n]=g.useState({isDirty:!1,isValidating:!1,isLoading:le(e.defaultValues),isSubmitted:!1,isSubmitting:!1,isSubmitSuccessful:!1,isValid:!1,submitCount:0,dirtyFields:{},touchedFields:{},validatingFields:{},errors:e.errors||{},disabled:e.disabled||!1,isReady:!1,defaultValues:le(e.defaultValues)?void 0:e.defaultValues});if(!r.current)if(e.formControl)r.current={...e.formControl,formState:o},e.defaultValues&&!le(e.defaultValues)&&e.formControl.reset(e.defaultValues,e.resetOptions);else{const{formControl:a,...l}=yo(e);r.current={...l,formState:o}}const s=r.current.control;return s._options=e,Xe(()=>{const a=s._subscribe({formState:s._proxyFormState,callback:()=>n({...s._formState}),reRenderRoot:!0});return n(l=>({...l,isReady:!0})),s._formState.isReady=!0,a},[s]),g.useEffect(()=>s._disableForm(e.disabled),[s,e.disabled]),g.useEffect(()=>{e.mode&&(s._options.mode=e.mode),e.reValidateMode&&(s._options.reValidateMode=e.reValidateMode)},[s,e.mode,e.reValidateMode]),g.useEffect(()=>{e.errors&&(s._setErrors(e.errors),s._focusError())},[s,e.errors]),g.useEffect(()=>{e.shouldUnregister&&s._subjects.state.next({values:s._getWatch()})},[s,e.shouldUnregister]),g.useEffect(()=>{if(s._proxyFormState.isDirty){const a=s._getDirty();a!==o.isDirty&&s._subjects.state.next({isDirty:a})}},[s,o.isDirty]),g.useEffect(()=>{e.values&&!ae(e.values,t.current)?(s._reset(e.values,{keepFieldsRef:!0,...s._options.resetOptions}),t.current=e.values,n(a=>({...a}))):s._resetDefaultValues()},[s,e.values]),g.useEffect(()=>{s._state.mount||(s._setValid(),s._state.mount=!0),s._state.watch&&(s._state.watch=!1,s._subjects.state.next({...s._formState})),s._removeUnmounted()}),r.current.formState=Mt(o,s),r.current}const Yt=(e,r,t)=>{if(e&&"reportValidity"in e){const o=x(t,r);e.setCustomValidity(o&&o.message||""),e.reportValidity()}},nt=(e,r)=>{for(const t in r.fields){const o=r.fields[t];o&&o.ref&&"reportValidity"in o.ref?Yt(o.ref,t,e):o&&o.refs&&o.refs.forEach(n=>Yt(n,t,e))}},Rt=(e,r)=>{r.shouldUseNativeValidation&&nt(e,r);const t={};for(const o in e){const n=x(r.fields,o),s=Object.assign(e[o]||{},{ref:n&&n.ref});if(po(r.names||Object.keys(e),o)){const a=Object.assign({},x(t,o));j(a,"root",s),j(t,o,a)}else j(t,o,s)}return t},po=(e,r)=>{const t=er(r);return e.some(o=>er(o).match(`^${t}\\.\\d+`))};function er(e){return e.replace(/\]|\[/g,"")}function tr(e,r,t){function o(l,u){var c;Object.defineProperty(l,"_zod",{value:l._zod??{},enumerable:!1}),(c=l._zod).traits??(c.traits=new Set),l._zod.traits.add(e),r(l,u);for(const f in a.prototype)f in l||Object.defineProperty(l,f,{value:a.prototype[f].bind(l)});l._zod.constr=a,l._zod.def=u}const n=(t==null?void 0:t.Parent)??Object;class s extends n{}Object.defineProperty(s,"name",{value:e});function a(l){var u;const c=t!=null&&t.Parent?new s:this;o(c,l),(u=c._zod).deferred??(u.deferred=[]);for(const f of c._zod.deferred)f();return c}return Object.defineProperty(a,"init",{value:o}),Object.defineProperty(a,Symbol.hasInstance,{value:l=>{var u,c;return t!=null&&t.Parent&&l instanceof t.Parent?!0:(c=(u=l==null?void 0:l._zod)==null?void 0:u.traits)==null?void 0:c.has(e)}}),Object.defineProperty(a,"name",{value:e}),a}class _o extends Error{constructor(){super("Encountered Promise during synchronous parse. Use .parseAsync() instead.")}}const vo={};function rr(e){return vo}function bo(e,r){return typeof r=="bigint"?r.toString():r}const or="captureStackTrace"in Error?Error.captureStackTrace:(...e)=>{};function je(e){return typeof e=="string"?e:e==null?void 0:e.message}function nr(e,r,t){var n,s,a,l,u,c;const o={...e,path:e.path??[]};if(!e.message){const f=je((a=(s=(n=e.inst)==null?void 0:n._zod.def)==null?void 0:s.error)==null?void 0:a.call(s,e))??je((l=r==null?void 0:r.error)==null?void 0:l.call(r,e))??je((u=t.customError)==null?void 0:u.call(t,e))??je((c=t.localeError)==null?void 0:c.call(t,e))??"Invalid input";o.message=f}return delete o.inst,delete o.continue,r!=null&&r.reportInput||delete o.input,o}const sr=(e,r)=>{e.name="$ZodError",Object.defineProperty(e,"_zod",{value:e._zod,enumerable:!1}),Object.defineProperty(e,"issues",{value:r,enumerable:!1}),e.message=JSON.stringify(r,bo,2),Object.defineProperty(e,"toString",{value:()=>e.message,enumerable:!1})},So=tr("$ZodError",sr),ar=tr("$ZodError",sr,{Parent:Error}),ko=(e=>(r,t,o,n)=>{const s=o?Object.assign(o,{async:!1}):{async:!1},a=r._zod.run({value:t,issues:[]},s);if(a instanceof Promise)throw new _o;if(a.issues.length){const l=new((n==null?void 0:n.Err)??e)(a.issues.map(u=>nr(u,s,rr())));throw or(l,n==null?void 0:n.callee),l}return a.value})(ar),Co=(e=>async(r,t,o,n)=>{const s=o?Object.assign(o,{async:!0}):{async:!0};let a=r._zod.run({value:t,issues:[]},s);if(a instanceof Promise&&(a=await a),a.issues.length){const l=new((n==null?void 0:n.Err)??e)(a.issues.map(u=>nr(u,s,rr())));throw or(l,n==null?void 0:n.callee),l}return a.value})(ar);function lr(e,r){try{var t=e()}catch(o){return r(o)}return t&&t.then?t.then(void 0,r):t}function wo(e,r){for(var t={};e.length;){var o=e[0],n=o.code,s=o.message,a=o.path.join(".");if(!t[a])if("unionErrors"in o){var l=o.unionErrors[0].errors[0];t[a]={message:l.message,type:l.code}}else t[a]={message:s,type:n};if("unionErrors"in o&&o.unionErrors.forEach(function(f){return f.errors.forEach(function(m){return e.push(m)})}),r){var u=t[a].types,c=u&&u[o.code];t[a]=Re(a,r,t,n,c?[].concat(c,o.message):o.message)}e.shift()}return t}function xo(e,r){for(var t={};e.length;){var o=e[0],n=o.code,s=o.message,a=o.path.join(".");if(!t[a])if(o.code==="invalid_union"&&o.errors.length>0){var l=o.errors[0][0];t[a]={message:l.message,type:l.code}}else t[a]={message:s,type:n};if(o.code==="invalid_union"&&o.errors.forEach(function(f){return f.forEach(function(m){return e.push(m)})}),r){var u=t[a].types,c=u&&u[o.code];t[a]=Re(a,r,t,n,c?[].concat(c,o.message):o.message)}e.shift()}return t}function Fo(e,r,t){if(t===void 0&&(t={}),(function(o){return"_def"in o&&typeof o._def=="object"&&"typeName"in o._def})(e))return function(o,n,s){try{return Promise.resolve(lr(function(){return Promise.resolve(e[t.mode==="sync"?"parse":"parseAsync"](o,r)).then(function(a){return s.shouldUseNativeValidation&&nt({},s),{errors:{},values:t.raw?Object.assign({},o):a}})},function(a){if((function(l){return Array.isArray(l==null?void 0:l.issues)})(a))return{values:{},errors:Rt(wo(a.errors,!s.shouldUseNativeValidation&&s.criteriaMode==="all"),s)};throw a}))}catch(a){return Promise.reject(a)}};if((function(o){return"_zod"in o&&typeof o._zod=="object"})(e))return function(o,n,s){try{return Promise.resolve(lr(function(){return Promise.resolve((t.mode==="sync"?ko:Co)(e,o,r)).then(function(a){return s.shouldUseNativeValidation&&nt({},s),{errors:{},values:t.raw?Object.assign({},o):a}})},function(a){if((function(l){return l instanceof So})(a))return{values:{},errors:Rt(xo(a.issues,!s.shouldUseNativeValidation&&s.criteriaMode==="all"),s)};throw a}))}catch(a){return Promise.reject(a)}};throw new Error("Invalid input: not a Zod schema")}const ir=g.createContext(null);function cr(){const e=g.useContext(ir);if(!e)throw new Error("useFormContext must be used within a Form component");return e}function zo({onSubmit:e,children:r,schema:t,defaultValues:o,mode:n="onSubmit",reValidateMode:s="onChange",className:a,style:l,formProps:u}){const c=go({resolver:t?Fo(t):void 0,defaultValues:o,mode:n,reValidateMode:s}),f=c.handleSubmit(e);return d.jsx(ir.Provider,{value:c,children:d.jsx("form",{...u,className:a,style:l,onSubmit:f,children:typeof r=="function"?r(c):r})})}const Vo=zo,Eo={formError:"FormError-module__formError___kaUBn"},dr=({color:e,children:r,className:t,style:o,divProps:n})=>{const s=I(),a={"--form-error-margin-top":`calc(${s.fonts.rhythm} * 0.17)`,color:e||s.colors.error,...o},l=[Eo.formError,t].filter(Boolean).join(" ");return d.jsx("div",{...n,className:l,style:a,role:"alert","aria-live":"polite",children:r})},ke={formGroup:"FormGroup-module__formGroup___aVI-B",inputWrapper:"FormGroup-module__inputWrapper___429QE",indented:"FormGroup-module__indented___t61iz",disabled:"FormGroup-module__disabled___W-tJ0",required:"FormGroup-module__required___mO3xA"},ur=({disabled:e=!1,error:r=!1,required:t=!1,indent:o=!1,name:n,label:s,errorMessage:a,labelProps:l,children:u,className:c,style:f,divProps:m})=>{const h=I(),b=[ke.formGroup,r?ke.error:"",e?ke.disabled:"",c].filter(Boolean).join(" "),S={"--form-group-margin-bottom":`calc(${h.fonts.rhythm} * 0.35)`,...f},_=g.Children.map(u,k=>{if(g.isValidElement(k)){const V={};if(e&&k.props.disabled===void 0&&(V.disabled=!0),r&&k.props.error===void 0&&(V.error=!0),n&&k.props.id===void 0&&k.type!==g.Fragment&&(V.id=n),Object.keys(V).length>0)return g.cloneElement(k,V)}return k});return d.jsxs("div",{...m,className:b,style:S,children:[s&&d.jsxs(Ae,{htmlFor:n,disabled:e,error:r,...l,children:[s,t&&d.jsxs("span",{className:ke.required,"aria-label":"required",children:[" ","*"]})]}),d.jsx("div",{className:`${ke.inputWrapper} ${o?ke.indented:""}`,children:_}),r&&a&&d.jsx(dr,{children:a})]})};function me({name:e,label:r,required:t,children:o,rules:n,disabled:s,className:a,style:l,indent:u,labelProps:c}){const{control:f}=cr(),{field:m,fieldState:{error:h}}=eo({name:e,control:f,rules:n});return d.jsx(ur,{label:r,name:e,error:!!h,errorMessage:h==null?void 0:h.message,disabled:s,required:t,className:a,style:l,indent:u,labelProps:c,children:o({value:m.value,onChange:m.onChange,onBlur:m.onBlur,name:m.name,error:!!h,indent:u})})}const st={input:"Input-module__input___WjT81",sizeSmall:"Input-module__sizeSmall___NFvsi",sizeLarge:"Input-module__sizeLarge___4Boj3"},$o=({color:e="#000",disabled:r=!1,fontSize:t="1em",placeholderOpacity:o=.3})=>({borderColor:e,color:e,fontSize:t,opacity:r?.3:1,placeholderOpacity:o}),fr=({disabled:e=!1,error:r=!1,color:t,size:o="large",id:n,name:s="",placeholder:a,placeholderOpacity:l=.3,type:u="text",value:c="",onChange:f,onBlur:m,className:h,style:b,inputProps:S})=>{const _=I(),k=_.colors.error,V=r?k:t||_.colors.primary,v=$o({color:V,disabled:e,placeholderOpacity:l}),z={"--placeholder-opacity":v.placeholderOpacity,borderColor:v.borderColor,borderWidth:_.border.width,borderRadius:_.border.radius,color:v.color,opacity:v.opacity,...b},E=[st.input,o==="small"?st.sizeSmall:st.sizeLarge,h].filter(Boolean).join(" ");return d.jsx("input",{...S,className:E,disabled:e,id:n,name:s,onChange:f,onBlur:m,placeholder:a,type:u,value:c,style:z})};function Lo({name:e,label:r,required:t,rules:o,disabled:n,className:s,style:a,...l}){return d.jsx(me,{name:e,label:r,required:t,rules:o,disabled:n,className:s,style:a,children:({value:u,onChange:c,onBlur:f,name:m,error:h})=>d.jsx(fr,{...l,name:m,value:u||"",onChange:b=>c(b.target.value),onBlur:f,error:h})})}const at={textarea:"Textarea-module__textarea___Z-y6g",sizeSmall:"Textarea-module__sizeSmall___HHFEM",sizeLarge:"Textarea-module__sizeLarge___5a3sf"},No=({color:e="#000",disabled:r=!1,placeholderOpacity:t=.3})=>({color:e,borderColor:e,opacity:r?.3:1,placeholderOpacity:t}),mr=({disabled:e=!1,error:r=!1,color:t,size:o="large",id:n,name:s="",placeholder:a,placeholderOpacity:l=.3,rows:u=3,value:c="",onChange:f,onBlur:m,className:h,style:b,textareaProps:S})=>{const _=I(),k=_.colors.error,V=r?k:t||_.colors.primary,v=No({color:V,disabled:e,placeholderOpacity:l}),z={"--placeholder-opacity":v.placeholderOpacity,borderColor:v.borderColor,borderWidth:_.border.width,borderRadius:_.border.radius,color:v.color,opacity:v.opacity,...b},E=[at.textarea,o==="small"?at.sizeSmall:at.sizeLarge,h].filter(Boolean).join(" ");return d.jsx("textarea",{...S,className:E,disabled:e,id:n,name:s,onChange:f,onBlur:m,placeholder:a,rows:u,value:c,style:z})};function Bo({name:e,label:r,required:t,rules:o,disabled:n,className:s,style:a,...l}){return d.jsx(me,{name:e,label:r,required:t,rules:o,disabled:n,className:s,style:a,children:({value:u,onChange:c,onBlur:f,name:m,error:h})=>d.jsx(mr,{...l,name:m,value:u||"",onChange:b=>c(b.target.value),onBlur:f,error:h})})}const lt={select:"Select-module__select___cjdcr",sizeSmall:"Select-module__sizeSmall___i1quj",sizeLarge:"Select-module__sizeLarge___eBA1T"},Mo=({color:e="#000",disabled:r=!1})=>({color:e,borderColor:e,cursor:r?"default":"pointer",opacity:r?.3:1,backgroundImage:(s=>{const a=`
19
19
  <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100">
20
20
  <path
21
21
  d="M 30 42.5 L 50 22.5 L 70 42.5"
@@ -30,10 +30,10 @@ ${n(a.default).join(`
30
30
  fill="transparent"
31
31
  />
32
32
  </svg>
33
- `.trim();return`url("data:image/svg+xml,${encodeURIComponent(a)}")`})(e)}),hr=({disabled:e=!1,error:r=!1,color:t,size:o="large",id:n,name:s="",placeholder:a="",value:l="",onChange:u,onBlur:c,children:f,className:m,style:h,selectProps:b})=>{const S=I(),_=S.colors.error,k=r?_:t||S.colors.primary,V=Bo({color:k,disabled:e}),v={backgroundImage:V.backgroundImage,backgroundPosition:"right center",backgroundRepeat:"no-repeat",backgroundSize:"auto 85%",backgroundColor:"transparent",borderColor:V.borderColor,borderWidth:S.border.width,borderRadius:S.border.radius,color:V.color,cursor:V.cursor,opacity:V.opacity,...h},z=[lt.select,o==="small"?lt.sizeSmall:lt.sizeLarge,m].filter(Boolean).join(" ");return d.jsxs("select",{...b,className:z,disabled:e,id:n,name:s,onChange:u,onBlur:c,value:l,style:v,children:[a!==""&&d.jsx("option",{disabled:!0,value:"",children:a}),f]})};function Mo({name:e,label:r,required:t,rules:o,disabled:n,className:s,style:a,children:l,...u}){return d.jsx(me,{name:e,label:r,required:t,rules:o,disabled:n,className:s,style:a,children:({value:c,onChange:f,onBlur:m,name:h,error:b})=>d.jsx(hr,{...u,name:h,value:c||"",onChange:S=>f(S.target.value),onBlur:m,error:b,children:l})})}function Ao({name:e,required:r,rules:t,disabled:o,className:n,style:s,...a}){return d.jsx(me,{name:e,required:r,rules:t,disabled:o,className:n,style:s,children:({value:l,onChange:u,name:c,error:f})=>d.jsx(Pe,{...a,name:c,checked:!!l,onChange:m=>u(m.target.checked),error:f})})}const it={container:"Radio-module__container___AQxhk",svg:"Radio-module__svg___zl5kF",label:"Radio-module__label___vAFIP"},Po=({color:e="#000",disabled:r=!1})=>({radioColor:e,cursor:r?"default":"pointer",opacity:r?.3:1}),ct=({color:e,checked:r=!1,disabled:t=!1,error:o=!1,name:n,id:s,onChange:a,label:l,labelStyle:u,className:c,style:f,divProps:m})=>{const h=I(),b=s||Vt(),S=h.colors.error,_=o?S:e||h.colors.primary,k=Po({color:_,disabled:t}),V=P=>{t||a(P)},v={cursor:k.cursor,opacity:k.opacity,...f},z={width:"var(--dr-radio-size)",height:"var(--dr-radio-size)"},E={fill:"transparent",strokeWidth:"12.5",stroke:k.radioColor},F={fill:k.radioColor},N=[it.container,c].filter(Boolean).join(" ");return d.jsxs("div",{...m,className:N,style:v,children:[d.jsx("input",{id:b,checked:r,disabled:t,name:n,onChange:P=>V({target:{checked:P.target.checked,name:n,type:"radio"}}),style:{display:"none"},type:"radio"}),d.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 100 100",onClick:()=>V({target:{checked:!r,name:n,type:"radio"}}),className:it.svg,style:z,children:[d.jsx("circle",{cx:"50",cy:"50",r:"42.5",width:"100%",style:E}),r&&d.jsx("circle",{cx:"50",cy:"50",r:"25",style:F})]}),l&&d.jsx(Ae,{htmlFor:b,className:it.label,style:{paddingBottom:0,...u},color:k.radioColor,disabled:t,error:o,children:l})]})};function Do({name:e,label:r,required:t,rules:o,disabled:n,className:s,style:a,value:l,...u}){return d.jsx(me,{name:e,required:t,rules:o,disabled:n,className:s,style:a,children:({value:c,onChange:f,name:m,error:h})=>d.jsx(ct,{...u,name:m,checked:c===l,onChange:()=>f(l),error:h,label:r})})}function Oo({name:e,label:r,required:t,options:o,disabled:n,className:s,style:a,indent:l=!0}){return d.jsx(me,{name:e,label:r,required:t,disabled:n,className:s,style:a,indent:l,labelProps:{style:{marginBottom:".25em"}},children:({value:u,onChange:c,name:f,error:m})=>d.jsx(d.Fragment,{children:o.map(h=>d.jsx(ct,{name:f,checked:u===h.value,onChange:()=>c(h.value),label:h.label,disabled:n||h.disabled,error:m},h.value))})})}function Io({name:e,label:r,required:t,options:o,children:n,disabled:s,className:a,style:l,indent:u=!0}){return d.jsx(me,{name:e,label:r,required:t,disabled:s,className:a,style:l,indent:u,labelProps:{style:{marginBottom:".25em"}},children:({value:c,onChange:f,name:m,error:h})=>{const b=Array.isArray(c)?c:[],S=(_,k)=>{f(k?[...b,_]:b.filter(V=>V!==_))};return d.jsx(d.Fragment,{children:o?o.map(_=>d.jsx(Pe,{name:`${m}[]`,checked:b.includes(_.value),onChange:k=>S(_.value,k.target.checked),label:_.label,disabled:s||_.disabled,error:h},_.value)):g.Children.map(n,_=>{if(g.isValidElement(_)&&_.type===Pe){const k=_.props.value||_.props.name;return g.cloneElement(_,{name:`${m}[]`,checked:b.includes(k),onChange:V=>S(k,V.target.checked),error:h||_.props.error,disabled:s||_.props.disabled})}return _})})}})}const $e={hamburger:"Hamburger-module__hamburger___Tf4-t",line:"Hamburger-module__line___gybZM",open:"Hamburger-module__open___gRswh"},To=({compact:e,color:r,visible:t,border:o})=>{const n=I(),s=e?"1.5em":"2em";return{"--hamburger-border-radius":(o==null?void 0:o.radius)||n.border.radius,color:r||"inherit",display:t?"flex":"none",width:s,height:s}},yr=({color:e,visible:r,compact:t,hamburgerRef:o,open:n=!1,border:s,setOpen:a,className:l,style:u})=>{const c=To({compact:t,color:e,visible:r,border:s}),f=[$e.hamburger,n?$e.open:"",l].filter(Boolean).join(" ");return d.jsxs("button",{ref:o,className:f,onClick:()=>a(!n),style:{...c,...u},"aria-label":"Toggle menu","aria-expanded":n,children:[d.jsx("div",{className:$e.line}),d.jsx("div",{className:$e.line}),d.jsx("div",{className:$e.line})]})},gr={header:"Header-module__header___RUooH",container:"Header-module__container___t68M9"},Wo=({isSmallScreen:e=!1,maxWidth:r,minWidth:t,width:o,height:n,paddingSm:s,padding:a,margin:l,gap:u,backgroundColor:c,color:f}={})=>{const m=I();return{"--header-max-width":r||m.layout.maxWidth,"--header-min-width":t,"--header-width":o,"--header-height":n,"--header-padding":e?s||m.layout.paddingSm:a||m.layout.padding,"--header-margin":l,"--header-gap":u,backgroundColor:c,color:f}},oe=e=>{const r=typeof window<"u"&&typeof window.matchMedia=="function",t=s=>{if(!r)return()=>{};const a=window.matchMedia(e);return a.addEventListener("change",s),()=>a.removeEventListener("change",s)},o=()=>r?window.matchMedia(e).matches:!1,n=()=>!1;return g.useSyncExternalStore(t,o,n)},pr=({backgroundColor:e,color:r,maxWidth:t,minWidth:o,width:n,height:s,padding:a,paddingSm:l,margin:u,gap:c,breakpoint:f,fixed:m=!1,children:h,className:b,style:S,headerProps:_})=>{const k=I(),V=f||k.breakpoints.sm,{maxWidth:v,unit:z}=ve(V),E=oe(`(max-width: ${v}${z})`),F=Wo({isSmallScreen:E,maxWidth:t,minWidth:o,width:n,height:s,paddingSm:l,padding:a,margin:u,gap:c,backgroundColor:e,color:r}),N=[gr.container,b].filter(Boolean).join(" "),P=m?{position:"fixed",top:0,left:0,right:0,zIndex:1e3}:{};return d.jsx("header",{..._,className:gr.header,style:P,children:d.jsx("div",{className:N,style:{...F,...S},children:h})})},Ce={nav:"ResponsiveNav-module__nav___xOfv5",navMobile:"ResponsiveNav-module__navMobile___h795P",navHeader:"ResponsiveNav-module__navHeader___Me8bB",compact:"ResponsiveNav-module__compact___UhuAE",navDesktop:"ResponsiveNav-module__navDesktop___9wscZ"},ce={triggerWrapper:"Popover-module__triggerWrapper___dZpf6",popup:"Popover-module__popup___JAvrb",panelOverlay:"Popover-module__panelOverlay___1xDU5",panelOverlayVisible:"Popover-module__panelOverlayVisible___BgtIQ",backdrop:"Popover-module__backdrop___e8qHL",panel:"Popover-module__panel___eUJ2E",panelLeft:"Popover-module__panelLeft___9nSLp",panelRight:"Popover-module__panelRight___OrQfl",panelOpen:"Popover-module__panelOpen___hhvV-",panelCloseButton:"Popover-module__panelCloseButton___kALaN"};function jo(e,r){const[t,o]=g.useState(!1),[n,s]=g.useState(!1);g.useEffect(()=>{r==="panel"&&(e?o(!0):s(!1))},[e,r]),g.useEffect(()=>{if(r!=="panel"||!t||!e)return;let l,u;return l=requestAnimationFrame(()=>{u=requestAnimationFrame(()=>s(!0))}),()=>{cancelAnimationFrame(l),cancelAnimationFrame(u)}},[t,e,r]);const a=g.useCallback(()=>{n||o(!1)},[n]);return{panelMounted:t,panelVisible:n,handleTransitionEnd:a}}function _r(e){const[r,t]=e.split("-");return{side:r,align:t??"center"}}const Ho={start:0,center:.5,end:1},Uo={start:"0",center:"-50%",end:"-100%"};function qo(e,r,t,o){const n=r==="top"||r==="bottom",s={top:e.top-o,bottom:e.bottom+o,left:e.left-o,right:e.right+o}[r],a=r==="top"||r==="left"?"-100%":"0",l=n?e.left:e.top,u=n?e.width:e.height,c=l+u*Ho[t],f=Uo[t],[m,h,b,S]=n?[c,s,f,a]:[s,c,a,f];return{position:"fixed",zIndex:999,left:m,top:h,transform:`translate(${b}, ${S})`}}function vr({open:e,triggerRef:r,side:t,align:o="center",offset:n=8,enabled:s=!0}){const[a,l]=g.useState({}),u=g.useCallback(()=>{if(!s||!r.current)return;const c=r.current.getBoundingClientRect();l(qo(c,t,o,n))},[s,r,t,o,n]);return g.useEffect(()=>{e&&s&&u()},[e,s,u]),g.useEffect(()=>{if(!(!e||!s))return window.addEventListener("scroll",u,!0),window.addEventListener("resize",u),()=>{window.removeEventListener("scroll",u,!0),window.removeEventListener("resize",u)}},[e,s,u]),{positionStyle:a,updatePosition:u}}const dt=({trigger:e,children:r,variant:t="popup",isOpen:o,onOpenChange:n,placement:s="bottom-start",side:a="left",panelWidth:l="75%",backdropColor:u="rgba(0, 0, 0, 0.5)",hideCloseButton:c=!1,closeOnBackdropClick:f=!0,className:m,style:h,popoverProps:b})=>{const S=I(),_=o!==void 0,[k,V]=g.useState(!1),v=_?o:k,z=g.useRef(null),E=g.useRef(null),F=g.useCallback(q=>{_||V(q),n==null||n(q)},[_,n]),N=g.useCallback(()=>F(!v),[v,F]),P=g.useCallback(()=>F(!1),[F]),{panelMounted:O,panelVisible:A,handleTransitionEnd:H}=jo(v,t),{side:G,align:B}=_r(s),{positionStyle:D}=vr({open:v,triggerRef:z,side:G,align:B,offset:4,enabled:t==="popup"});g.useEffect(()=>{if(!v||t!=="popup")return;const q=de=>{var fe,_e;(fe=E.current)!=null&&fe.contains(de.target)||(_e=z.current)!=null&&_e.contains(de.target)||P()};return document.addEventListener("mousedown",q),()=>document.removeEventListener("mousedown",q)},[v,t,P]),g.useEffect(()=>{if(!v)return;const q=de=>{de.key==="Escape"&&P()};return document.addEventListener("keydown",q),()=>document.removeEventListener("keydown",q)},[v,P]),g.useEffect(()=>{if(!v||t!=="panel")return;const q=window.scrollY;return document.body.style.position="fixed",document.body.style.top=`-${q}px`,document.body.style.width="100%",()=>{document.body.style.position="",document.body.style.top="",document.body.style.width="",window.scrollTo(0,q)}},[v,t]);const T=e?typeof e=="function"?e({onClick:N,isOpen:v}):d.jsx("span",{onClick:N,style:{cursor:"pointer",display:"contents"},children:e}):null,J=e?d.jsx("span",{ref:z,className:ce.triggerWrapper,children:T}):null;if(t==="popup"){const q={backgroundColor:S.colors.secondaryBackground,borderRadius:S.border.radius,boxShadow:"0 4px 6px -1px rgba(0,0,0,0.1), 0 2px 4px -1px rgba(0,0,0,0.06)",...D,...h};return d.jsxs(d.Fragment,{children:[J,v&&Le.createPortal(d.jsx("div",{ref:E,className:[ce.popup,m].filter(Boolean).join(" "),style:q,...b,children:r}),document.body)]})}const Y={width:l,backgroundColor:S.colors.secondaryBackground,...h};return d.jsxs(d.Fragment,{children:[J,O&&Le.createPortal(d.jsxs("div",{className:[ce.panelOverlay,A?ce.panelOverlayVisible:""].filter(Boolean).join(" "),children:[d.jsx("div",{className:ce.backdrop,style:{backgroundColor:A?u:"transparent"},onClick:f?P:void 0,role:"presentation"}),d.jsxs("div",{ref:E,className:[ce.panel,a==="right"?ce.panelRight:ce.panelLeft,A?ce.panelOpen:"",m].filter(Boolean).join(" "),style:Y,role:"dialog","aria-modal":"true",onTransitionEnd:H,...b,children:[!c&&d.jsx("button",{className:ce.panelCloseButton,onClick:P,"aria-label":"Close panel",type:"button",children:d.jsx("svg",{width:"100%",height:"100%",viewBox:"0 0 20 20",fill:"none",xmlns:"http://www.w3.org/2000/svg","aria-hidden":"true",children:d.jsx("path",{d:"M15 5L5 15M5 5L15 15",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round"})})}),r]})]}),document.body)]})},Go=({isMobile:e,isCompact:r,mobile:t,desktop:o})=>{const n=I();return g.useMemo(()=>e?{navStyles:{...(t==null?void 0:t.backgroundColor)&&{backgroundColor:t.backgroundColor},color:(t==null?void 0:t.color)||n.fonts.color,...t==null?void 0:t.style}}:{navStyles:{...(o==null?void 0:o.backgroundColor)&&{backgroundColor:o.backgroundColor},color:(o==null?void 0:o.color)||n.fonts.color,...o==null?void 0:o.style}},[e,r,t,o,n])},br=g.createContext({isMobile:!1,setOpen:()=>{}}),Zo=({open:e,setOpen:r,hamburgerRef:t,isCompact:o,mobile:n,panelWidth:s,side:a,navClassName:l,cssProps:u,navProps:c,content:f,onNavClick:m})=>{const{backgroundColor:h,...b}=u;return d.jsx(dt,{variant:"panel",side:a||"right",panelWidth:s||"75%",isOpen:e,onOpenChange:r,style:h?{backgroundColor:h}:void 0,trigger:({onClick:S})=>d.jsx(yr,{hamburgerRef:t,visible:!0,compact:o,open:!1,setOpen:_=>S(),...n==null?void 0:n.hamburgerProps}),children:d.jsxs("nav",{...c,className:l,style:b,onClickCapture:m,children:[d.jsx("div",{className:Ce.navHeader}),typeof f=="function"?f({setOpen:r}):f]})})},Ko=({setOpen:e,navClassName:r,cssProps:t,navProps:o,content:n})=>d.jsx("nav",{...o,className:r,style:t,children:typeof n=="function"?n({setOpen:e}):n}),Qo=({mobile:e,desktop:r,breakpoints:t,children:o,className:n,style:s,navProps:a,disableMobileTreatment:l=!1})=>{const[u,c]=g.useState(!1),f=g.useRef(null),h={...I().breakpoints,...t},{maxWidth:b,unit:S}=ve(h.md),{maxWidth:_,unit:k}=ve(h.sm),V=oe(`(max-width: ${b}${S})`),v=oe(`(max-width: ${_}${k})`),z=l?!1:V,E=l?!1:v,{navStyles:F}=Go({isMobile:z,isCompact:E,mobile:e,desktop:r}),N={...F,...s},P=H=>{const G=H.target;G.closest("[data-navdropdown-trigger]")||G.closest("a, button")&&c(!1)},O=[Ce.nav,Ce.navMobile,E||e!=null&&e.compact?Ce.compact:"",n].filter(Boolean).join(" "),A=[Ce.nav,Ce.navDesktop,n].filter(Boolean).join(" ");return d.jsx(br.Provider,{value:{isMobile:z,setOpen:c},children:z?d.jsx(Zo,{open:u,setOpen:c,hamburgerRef:f,isCompact:E,mobile:e,panelWidth:e==null?void 0:e.panelWidth,side:e==null?void 0:e.side,navClassName:O,cssProps:N,navProps:a,content:(e==null?void 0:e.content)||o,onNavClick:P}):d.jsx(Ko,{setOpen:c,navClassName:A,cssProps:N,navProps:a,content:(r==null?void 0:r.content)||o})})},ut={trigger:"NavDropdown-module__trigger___1PQZp",chevron:"NavDropdown-module__chevron___ZLAV7",chevronOpen:"NavDropdown-module__chevronOpen___9mgjr"};function ft({isActive:e=!1,hoverOpacity:r=.5,color:t}={}){const o=I(),[n,s]=g.useState(!1);return{style:{color:t||o.fonts.color,fontWeight:700,textDecoration:"none",opacity:e||n?r:1},onMouseEnter:()=>s(!0),onMouseLeave:()=>s(!1)}}const Xo=({label:e,children:r,dropdownVariant:t="popup",side:o="left",panelWidth:n="75%",color:s,hoverOpacity:a,className:l,style:u,buttonProps:c})=>{const[f,m]=g.useState(!1),{style:h,onMouseEnter:b,onMouseLeave:S}=ft({isActive:f,color:s,hoverOpacity:a});return d.jsx(dt,{variant:t,side:o,panelWidth:n,isOpen:f,onOpenChange:m,trigger:({onClick:_})=>d.jsxs("button",{type:"button",className:[ut.trigger,l].filter(Boolean).join(" "),style:{...h,...u},"data-navdropdown-trigger":!0,onClick:_,onMouseEnter:b,onMouseLeave:S,...c,children:[e,d.jsx("span",{className:[ut.chevron,f?ut.chevronOpen:""].filter(Boolean).join(" "),"aria-hidden":"true",children:d.jsx("svg",{width:"12",height:"12",viewBox:"0 0 12 12",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:d.jsx("path",{d:"M2 4L6 8L10 4",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"})})})]}),children:r})},Jo=({isActive:e,hoverOpacity:r,color:t,children:o})=>{const{style:n,onMouseEnter:s,onMouseLeave:a}=ft({isActive:e,hoverOpacity:r,color:t});return g.cloneElement(o,{style:{...n,...o.props.style},onMouseEnter:l=>{var u,c;s(),(c=(u=o.props).onMouseEnter)==null||c.call(u,l)},onMouseLeave:l=>{var u,c;a(),(c=(u=o.props).onMouseLeave)==null||c.call(u,l)}})},mt=({color:e,backgroundColor:r,fullScreen:t=!0,className:o,style:n,divProps:s})=>{const a=I(),l=e||a.colors.primary,u=r||a.colors.secondary,c=d.jsx("div",{...t?void 0:s,className:t?void 0:o,style:{fontSize:"2.5em",borderRadius:"50%",width:"1em",height:"1em",animation:"spin 1s linear infinite",...t?{}:n,border:`0.1em solid ${l}`,borderTop:`0.1em solid ${u}`}}),f=d.jsxs(d.Fragment,{children:[c,d.jsx("style",{children:`
33
+ `.trim();return`url("data:image/svg+xml,${encodeURIComponent(a)}")`})(e)}),hr=({disabled:e=!1,error:r=!1,color:t,size:o="large",id:n,name:s="",placeholder:a="",value:l="",onChange:u,onBlur:c,children:f,className:m,style:h,selectProps:b})=>{const S=I(),_=S.colors.error,k=r?_:t||S.colors.primary,V=Mo({color:k,disabled:e}),v={backgroundImage:V.backgroundImage,backgroundPosition:"right center",backgroundRepeat:"no-repeat",backgroundSize:"auto 85%",backgroundColor:"transparent",borderColor:V.borderColor,borderWidth:S.border.width,borderRadius:S.border.radius,color:V.color,cursor:V.cursor,opacity:V.opacity,...h},z=[lt.select,o==="small"?lt.sizeSmall:lt.sizeLarge,m].filter(Boolean).join(" ");return d.jsxs("select",{...b,className:z,disabled:e,id:n,name:s,onChange:u,onBlur:c,value:l,style:v,children:[a!==""&&d.jsx("option",{disabled:!0,value:"",children:a}),f]})};function Ao({name:e,label:r,required:t,rules:o,disabled:n,className:s,style:a,children:l,...u}){return d.jsx(me,{name:e,label:r,required:t,rules:o,disabled:n,className:s,style:a,children:({value:c,onChange:f,onBlur:m,name:h,error:b})=>d.jsx(hr,{...u,name:h,value:c||"",onChange:S=>f(S.target.value),onBlur:m,error:b,children:l})})}function Po({name:e,required:r,rules:t,disabled:o,className:n,style:s,...a}){return d.jsx(me,{name:e,required:r,rules:t,disabled:o,className:n,style:s,children:({value:l,onChange:u,name:c,error:f})=>d.jsx(Pe,{...a,name:c,checked:!!l,onChange:m=>u(m.target.checked),error:f})})}const it={container:"Radio-module__container___AQxhk",svg:"Radio-module__svg___zl5kF",label:"Radio-module__label___vAFIP"},Do=({color:e="#000",disabled:r=!1})=>({radioColor:e,cursor:r?"default":"pointer",opacity:r?.3:1}),ct=({color:e,checked:r=!1,disabled:t=!1,error:o=!1,name:n,id:s,onChange:a,label:l,labelStyle:u,className:c,style:f,divProps:m})=>{const h=I(),b=s||Vt(),S=h.colors.error,_=o?S:e||h.colors.primary,k=Do({color:_,disabled:t}),V=P=>{t||a(P)},v={cursor:k.cursor,opacity:k.opacity,...f},z={width:"var(--dr-radio-size)",height:"var(--dr-radio-size)"},E={fill:"transparent",strokeWidth:"12.5",stroke:k.radioColor},F={fill:k.radioColor},N=[it.container,c].filter(Boolean).join(" ");return d.jsxs("div",{...m,className:N,style:v,children:[d.jsx("input",{id:b,checked:r,disabled:t,name:n,onChange:P=>V({target:{checked:P.target.checked,name:n,type:"radio"}}),style:{display:"none"},type:"radio"}),d.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 100 100",onClick:()=>V({target:{checked:!r,name:n,type:"radio"}}),className:it.svg,style:z,children:[d.jsx("circle",{cx:"50",cy:"50",r:"42.5",width:"100%",style:E}),r&&d.jsx("circle",{cx:"50",cy:"50",r:"25",style:F})]}),l&&d.jsx(Ae,{htmlFor:b,className:it.label,style:{paddingBottom:0,...u},color:k.radioColor,disabled:t,error:o,children:l})]})};function Oo({name:e,label:r,required:t,rules:o,disabled:n,className:s,style:a,value:l,...u}){return d.jsx(me,{name:e,required:t,rules:o,disabled:n,className:s,style:a,children:({value:c,onChange:f,name:m,error:h})=>d.jsx(ct,{...u,name:m,checked:c===l,onChange:()=>f(l),error:h,label:r})})}function yr({children:e,disabled:r,error:t}){return d.jsx(d.Fragment,{children:e})}function Io({name:e,label:r,required:t,options:o,disabled:n,className:s,style:a,indent:l=!0}){return d.jsx(me,{name:e,label:r,required:t,disabled:n,className:s,style:a,indent:l,labelProps:{style:{marginBottom:".25em"}},children:({value:u,onChange:c,name:f,error:m})=>d.jsx(yr,{children:o.map(h=>d.jsx(ct,{name:f,checked:u===h.value,onChange:()=>c(h.value),label:h.label,disabled:n||h.disabled,error:m},h.value))})})}function To({name:e,label:r,required:t,options:o,children:n,disabled:s,className:a,style:l,indent:u=!0}){return d.jsx(me,{name:e,label:r,required:t,disabled:s,className:a,style:l,indent:u,labelProps:{style:{marginBottom:".25em"}},children:({value:c,onChange:f,name:m,error:h})=>{const b=Array.isArray(c)?c:[],S=(_,k)=>{f(k?[...b,_]:b.filter(V=>V!==_))};return d.jsx(yr,{children:o?o.map(_=>d.jsx(Pe,{name:`${m}[]`,checked:b.includes(_.value),onChange:k=>S(_.value,k.target.checked),label:_.label,disabled:s||_.disabled,error:h},_.value)):g.Children.map(n,_=>{if(g.isValidElement(_)&&_.type===Pe){const k=_.props.name;return g.cloneElement(_,{name:`${m}[]`,checked:b.includes(k),onChange:V=>S(k,V.target.checked),error:h||_.props.error,disabled:s||_.props.disabled})}return _})})}})}const $e={hamburger:"Hamburger-module__hamburger___Tf4-t",line:"Hamburger-module__line___gybZM",open:"Hamburger-module__open___gRswh"},jo=({compact:e,color:r,visible:t,border:o})=>{const n=I(),s=e?"1.5em":"2em";return{"--hamburger-border-radius":(o==null?void 0:o.radius)||n.border.radius,color:r||"inherit",display:t?"flex":"none",width:s,height:s}},gr=({color:e,visible:r,compact:t,hamburgerRef:o,open:n=!1,border:s,setOpen:a,className:l,style:u})=>{const c=jo({compact:t,color:e,visible:r,border:s}),f=[$e.hamburger,n?$e.open:"",l].filter(Boolean).join(" ");return d.jsxs("button",{ref:o,className:f,onClick:()=>a(!n),style:{...c,...u},"aria-label":"Toggle menu","aria-expanded":n,children:[d.jsx("div",{className:$e.line}),d.jsx("div",{className:$e.line}),d.jsx("div",{className:$e.line})]})},pr={header:"Header-module__header___RUooH",container:"Header-module__container___t68M9"},Wo=({isSmallScreen:e=!1,maxWidth:r,minWidth:t,width:o,height:n,paddingSm:s,padding:a,margin:l,gap:u,backgroundColor:c,color:f}={})=>{const m=I();return{"--header-max-width":r||m.layout.maxWidth,"--header-min-width":t,"--header-width":o,"--header-height":n,"--header-padding":e?s||m.layout.paddingSm:a||m.layout.padding,"--header-margin":l,"--header-gap":u,backgroundColor:c,color:f}},oe=e=>{const r=typeof window<"u"&&typeof window.matchMedia=="function",t=s=>{if(!r)return()=>{};const a=window.matchMedia(e);return a.addEventListener("change",s),()=>a.removeEventListener("change",s)},o=()=>r?window.matchMedia(e).matches:!1,n=()=>!1;return g.useSyncExternalStore(t,o,n)},_r=({backgroundColor:e,color:r,maxWidth:t,minWidth:o,width:n,height:s,padding:a,paddingSm:l,margin:u,gap:c,breakpoint:f,fixed:m=!1,children:h,className:b,style:S,headerProps:_})=>{const k=I(),V=f||k.breakpoints.sm,{maxWidth:v,unit:z}=ve(V),E=oe(`(max-width: ${v}${z})`),F=Wo({isSmallScreen:E,maxWidth:t,minWidth:o,width:n,height:s,paddingSm:l,padding:a,margin:u,gap:c,backgroundColor:e,color:r}),N=[pr.container,b].filter(Boolean).join(" "),P=m?{position:"fixed",top:0,left:0,right:0,zIndex:1e3}:{};return d.jsx("header",{..._,className:pr.header,style:P,children:d.jsx("div",{className:N,style:{...F,...S},children:h})})},Ce={nav:"ResponsiveNav-module__nav___xOfv5",navMobile:"ResponsiveNav-module__navMobile___h795P",navHeader:"ResponsiveNav-module__navHeader___Me8bB",compact:"ResponsiveNav-module__compact___UhuAE",navDesktop:"ResponsiveNav-module__navDesktop___9wscZ"},ce={triggerWrapper:"Popover-module__triggerWrapper___dZpf6",popup:"Popover-module__popup___JAvrb",panelOverlay:"Popover-module__panelOverlay___1xDU5",panelOverlayVisible:"Popover-module__panelOverlayVisible___BgtIQ",backdrop:"Popover-module__backdrop___e8qHL",panel:"Popover-module__panel___eUJ2E",panelLeft:"Popover-module__panelLeft___9nSLp",panelRight:"Popover-module__panelRight___OrQfl",panelOpen:"Popover-module__panelOpen___hhvV-",panelCloseButton:"Popover-module__panelCloseButton___kALaN"};function Ho(e,r){const[t,o]=g.useState(!1),[n,s]=g.useState(!1);g.useEffect(()=>{r==="panel"&&(e?o(!0):s(!1))},[e,r]),g.useEffect(()=>{if(r!=="panel"||!t||!e)return;let l,u;return l=requestAnimationFrame(()=>{u=requestAnimationFrame(()=>s(!0))}),()=>{cancelAnimationFrame(l),cancelAnimationFrame(u)}},[t,e,r]);const a=g.useCallback(()=>{n||o(!1)},[n]);return{panelMounted:t,panelVisible:n,handleTransitionEnd:a}}function vr(e){const[r,t]=e.split("-");return{side:r,align:t??"center"}}const Uo={start:0,center:.5,end:1},qo={start:"0",center:"-50%",end:"-100%"};function Go(e,r,t,o){const n=r==="top"||r==="bottom",s={top:e.top-o,bottom:e.bottom+o,left:e.left-o,right:e.right+o}[r],a=r==="top"||r==="left"?"-100%":"0",l=n?e.left:e.top,u=n?e.width:e.height,c=l+u*Uo[t],f=qo[t],[m,h,b,S]=n?[c,s,f,a]:[s,c,a,f];return{position:"fixed",zIndex:999,left:m,top:h,transform:`translate(${b}, ${S})`}}function br({open:e,triggerRef:r,side:t,align:o="center",offset:n=8,enabled:s=!0}){const[a,l]=g.useState({}),u=g.useCallback(()=>{if(!s||!r.current)return;const c=r.current.getBoundingClientRect();l(Go(c,t,o,n))},[s,r,t,o,n]);return g.useEffect(()=>{e&&s&&u()},[e,s,u]),g.useEffect(()=>{if(!(!e||!s))return window.addEventListener("scroll",u,!0),window.addEventListener("resize",u),()=>{window.removeEventListener("scroll",u,!0),window.removeEventListener("resize",u)}},[e,s,u]),{positionStyle:a,updatePosition:u}}const dt=({trigger:e,children:r,variant:t="popup",isOpen:o,onOpenChange:n,placement:s="bottom-start",side:a="left",panelWidth:l="75%",backdropColor:u="rgba(0, 0, 0, 0.5)",hideCloseButton:c=!1,closeOnBackdropClick:f=!0,className:m,style:h,popoverProps:b})=>{const S=I(),_=o!==void 0,[k,V]=g.useState(!1),v=_?o:k,z=g.useRef(null),E=g.useRef(null),F=g.useCallback(q=>{_||V(q),n==null||n(q)},[_,n]),N=g.useCallback(()=>F(!v),[v,F]),P=g.useCallback(()=>F(!1),[F]),{panelMounted:O,panelVisible:A,handleTransitionEnd:H}=Ho(v,t),{side:G,align:B}=vr(s),{positionStyle:D}=br({open:v,triggerRef:z,side:G,align:B,offset:4,enabled:t==="popup"});g.useEffect(()=>{if(!v||t!=="popup")return;const q=de=>{var fe,_e;(fe=E.current)!=null&&fe.contains(de.target)||(_e=z.current)!=null&&_e.contains(de.target)||P()};return document.addEventListener("mousedown",q),()=>document.removeEventListener("mousedown",q)},[v,t,P]),g.useEffect(()=>{if(!v)return;const q=de=>{de.key==="Escape"&&P()};return document.addEventListener("keydown",q),()=>document.removeEventListener("keydown",q)},[v,P]),g.useEffect(()=>{if(!v||t!=="panel")return;const q=window.scrollY;return document.body.style.position="fixed",document.body.style.top=`-${q}px`,document.body.style.width="100%",()=>{document.body.style.position="",document.body.style.top="",document.body.style.width="",window.scrollTo(0,q)}},[v,t]);const T=e?typeof e=="function"?e({onClick:N,isOpen:v}):d.jsx("span",{onClick:N,style:{cursor:"pointer",display:"contents"},children:e}):null,J=e?d.jsx("span",{ref:z,className:ce.triggerWrapper,children:T}):null;if(t==="popup"){const q={backgroundColor:S.colors.secondaryBackground,borderRadius:S.border.radius,boxShadow:"0 4px 6px -1px rgba(0,0,0,0.1), 0 2px 4px -1px rgba(0,0,0,0.06)",...D,...h};return d.jsxs(d.Fragment,{children:[J,v&&Le.createPortal(d.jsx("div",{ref:E,className:[ce.popup,m].filter(Boolean).join(" "),style:q,...b,children:r}),document.body)]})}const Y={width:l,backgroundColor:S.colors.secondaryBackground,...h};return d.jsxs(d.Fragment,{children:[J,O&&Le.createPortal(d.jsxs("div",{className:[ce.panelOverlay,A?ce.panelOverlayVisible:""].filter(Boolean).join(" "),children:[d.jsx("div",{className:ce.backdrop,style:{backgroundColor:A?u:"transparent"},onClick:f?P:void 0,role:"presentation"}),d.jsxs("div",{ref:E,className:[ce.panel,a==="right"?ce.panelRight:ce.panelLeft,A?ce.panelOpen:"",m].filter(Boolean).join(" "),style:Y,role:"dialog","aria-modal":"true",onTransitionEnd:H,...b,children:[!c&&d.jsx("button",{className:ce.panelCloseButton,onClick:P,"aria-label":"Close panel",type:"button",children:d.jsx("svg",{width:"100%",height:"100%",viewBox:"0 0 20 20",fill:"none",xmlns:"http://www.w3.org/2000/svg","aria-hidden":"true",children:d.jsx("path",{d:"M15 5L5 15M5 5L15 15",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round"})})}),r]})]}),document.body)]})},Zo=({isMobile:e,isCompact:r,mobile:t,desktop:o})=>{const n=I();return g.useMemo(()=>e?{navStyles:{...(t==null?void 0:t.backgroundColor)&&{backgroundColor:t.backgroundColor},color:(t==null?void 0:t.color)||n.fonts.color,...t==null?void 0:t.style}}:{navStyles:{...(o==null?void 0:o.backgroundColor)&&{backgroundColor:o.backgroundColor},color:(o==null?void 0:o.color)||n.fonts.color,...o==null?void 0:o.style}},[e,r,t,o,n])},Sr=g.createContext({isMobile:!1,setOpen:()=>{}}),Ko=({open:e,setOpen:r,hamburgerRef:t,isCompact:o,mobile:n,panelWidth:s,side:a,navClassName:l,cssProps:u,navProps:c,content:f,onNavClick:m})=>{const{backgroundColor:h,...b}=u;return d.jsx(dt,{variant:"panel",side:a||"right",panelWidth:s||"75%",isOpen:e,onOpenChange:r,style:h?{backgroundColor:h}:void 0,trigger:({onClick:S})=>d.jsx(gr,{hamburgerRef:t,visible:!0,compact:o,open:!1,setOpen:_=>S(),...n==null?void 0:n.hamburgerProps}),children:d.jsxs("nav",{...c,className:l,style:b,onClickCapture:m,children:[d.jsx("div",{className:Ce.navHeader}),typeof f=="function"?f({setOpen:r}):f]})})},Qo=({setOpen:e,navClassName:r,cssProps:t,navProps:o,content:n})=>d.jsx("nav",{...o,className:r,style:t,children:typeof n=="function"?n({setOpen:e}):n}),Xo=({mobile:e,desktop:r,breakpoints:t,children:o,className:n,style:s,navProps:a,disableMobileTreatment:l=!1})=>{const[u,c]=g.useState(!1),f=g.useRef(null),h={...I().breakpoints,...t},{maxWidth:b,unit:S}=ve(h.md),{maxWidth:_,unit:k}=ve(h.sm),V=oe(`(max-width: ${b}${S})`),v=oe(`(max-width: ${_}${k})`),z=l?!1:V,E=l?!1:v,{navStyles:F}=Zo({isMobile:z,isCompact:E,mobile:e,desktop:r}),N={...F,...s},P=H=>{const G=H.target;G.closest("[data-navdropdown-trigger]")||G.closest("a, button")&&c(!1)},O=[Ce.nav,Ce.navMobile,E||e!=null&&e.compact?Ce.compact:"",n].filter(Boolean).join(" "),A=[Ce.nav,Ce.navDesktop,n].filter(Boolean).join(" ");return d.jsx(Sr.Provider,{value:{isMobile:z,setOpen:c},children:z?d.jsx(Ko,{open:u,setOpen:c,hamburgerRef:f,isCompact:E,mobile:e,panelWidth:e==null?void 0:e.panelWidth,side:e==null?void 0:e.side,navClassName:O,cssProps:N,navProps:a,content:(e==null?void 0:e.content)||o,onNavClick:P}):d.jsx(Qo,{setOpen:c,navClassName:A,cssProps:N,navProps:a,content:(r==null?void 0:r.content)||o})})},ut={trigger:"NavDropdown-module__trigger___1PQZp",chevron:"NavDropdown-module__chevron___ZLAV7",chevronOpen:"NavDropdown-module__chevronOpen___9mgjr"};function ft({isActive:e=!1,hoverOpacity:r=.5,color:t}={}){const o=I(),[n,s]=g.useState(!1);return{style:{color:t||o.fonts.color,fontWeight:700,textDecoration:"none",opacity:e||n?r:1},onMouseEnter:()=>s(!0),onMouseLeave:()=>s(!1)}}const Jo=({label:e,children:r,dropdownVariant:t="popup",side:o="left",panelWidth:n="75%",color:s,hoverOpacity:a,className:l,style:u,buttonProps:c})=>{const[f,m]=g.useState(!1),{style:h,onMouseEnter:b,onMouseLeave:S}=ft({isActive:f,color:s,hoverOpacity:a});return d.jsx(dt,{variant:t,side:o,panelWidth:n,isOpen:f,onOpenChange:m,trigger:({onClick:_})=>d.jsxs("button",{type:"button",className:[ut.trigger,l].filter(Boolean).join(" "),style:{...h,...u},"data-navdropdown-trigger":!0,onClick:_,onMouseEnter:b,onMouseLeave:S,...c,children:[e,d.jsx("span",{className:[ut.chevron,f?ut.chevronOpen:""].filter(Boolean).join(" "),"aria-hidden":"true",children:d.jsx("svg",{width:"12",height:"12",viewBox:"0 0 12 12",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:d.jsx("path",{d:"M2 4L6 8L10 4",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"})})})]}),children:r})},Yo=({isActive:e,hoverOpacity:r,color:t,children:o})=>{const{style:n,onMouseEnter:s,onMouseLeave:a}=ft({isActive:e,hoverOpacity:r,color:t});return g.cloneElement(o,{style:{...n,...o.props.style},onMouseEnter:l=>{var u,c;s(),(c=(u=o.props).onMouseEnter)==null||c.call(u,l)},onMouseLeave:l=>{var u,c;a(),(c=(u=o.props).onMouseLeave)==null||c.call(u,l)}})},mt=({color:e,backgroundColor:r,fullScreen:t=!0,className:o,style:n,divProps:s})=>{const a=I(),l=e||a.colors.primary,u=r||a.colors.secondary,c=d.jsx("div",{...t?void 0:s,className:t?void 0:o,style:{fontSize:"2.5em",borderRadius:"50%",width:"1em",height:"1em",animation:"spin 1s linear infinite",...t?{}:n,border:`0.1em solid ${l}`,borderTop:`0.1em solid ${u}`}}),f=d.jsxs(d.Fragment,{children:[c,d.jsx("style",{children:`
34
34
  @keyframes spin {
35
35
  0% { transform: rotate(0deg); }
36
36
  100% { transform: rotate(360deg); }
37
37
  }
38
- `})]});return t?d.jsx("div",{...s,"data-loading":"true",className:o,style:{display:"flex",justifyContent:"center",alignItems:"center",height:"100vh",width:"100vw",...n},children:f}):f},Yo=({children:e,loadingComponent:r})=>{const[t,o]=g.useState(!1);return g.useEffect(()=>{requestAnimationFrame(()=>{o(!0)})},[]),t?d.jsx(d.Fragment,{children:e}):r||d.jsx(mt,{})},ge={backdrop:"Modal-module__backdrop___GVUh4",modal:"Modal-module__modal___aD7aP",header:"Modal-module__header___ILG9i",title:"Modal-module__title___A5OeE",closeButton:"Modal-module__closeButton___3LpSf",content:"Modal-module__content___dWO-B",actions:"Modal-module__actions___hY6zi"},ht={stack:"Stack-module__stack___yUU-B",vertical:"Stack-module__vertical___sKTyQ",horizontal:"Stack-module__horizontal___YsvtV"},Sr=({direction:e="row",gap:r="0.5em",children:t,className:o,style:n,divProps:s})=>{const a=[ht.stack,e==="column"?ht.vertical:ht.horizontal,o].filter(Boolean).join(" ");return d.jsx("div",{...s,className:a,style:{gap:r,...n},children:t})},kr=({isOpen:e,onClose:r,children:t,title:o,hideCloseButton:n=!1,closeOnBackdropClick:s=!0,closeOnEscape:a=!0,actions:l=[],resolveModal:u,width:c="500px",maxWidth:f="90vw",backgroundColor:m,backdropColor:h="rgba(0, 0, 0, 0.5)",className:b,style:S,divProps:_})=>{const k=I(),V=g.useRef(null),v=g.useRef(null),{maxWidth:z}=ve(k.breakpoints.md),E=oe(`(max-width: ${z-1}px)`);g.useEffect(()=>{if(e)return v.current=document.activeElement,document.body.style.overflow="hidden",V.current&&V.current.focus(),()=>{document.body.style.overflow="",v.current&&v.current.focus()}},[e]),g.useEffect(()=>{if(!e||!a)return;const A=H=>{H.key==="Escape"&&r()};return document.addEventListener("keydown",A),()=>document.removeEventListener("keydown",A)},[e,a,r]);const F=A=>{A.target===A.currentTarget&&s&&r()};if(!e)return null;const N={width:c,maxWidth:f,backgroundColor:m||k.colors.secondary,borderRadius:k.border.radius,...S},P={backgroundColor:h},O=d.jsx("div",{className:ge.backdrop,style:P,onClick:F,role:"presentation",children:d.jsxs("div",{ref:V,className:[ge.modal,b].filter(Boolean).join(" "),style:N,role:"dialog","aria-modal":"true","aria-labelledby":o?"modal-title":void 0,tabIndex:-1,..._,children:[d.jsxs("div",{className:ge.header,children:[o&&d.jsx("h2",{id:"modal-title",className:ge.title,children:o}),!n&&d.jsx("button",{className:ge.closeButton,onClick:r,"aria-label":"Close modal",type:"button",children:d.jsx("svg",{width:"100%",height:"100%",viewBox:"0 0 20 20",fill:"none",xmlns:"http://www.w3.org/2000/svg","aria-hidden":"true",children:d.jsx("path",{d:"M15 5L5 15M5 5L15 15",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round"})})})]}),d.jsx("div",{className:ge.content,children:t}),l.length>0&&d.jsx(Sr,{direction:E?"column":"row",className:ge.actions,children:l.map((A,H)=>d.jsx(xt,{color:A.color,outline:A.variant==="outline",disabled:A.disabled,onClick:()=>{A.onClick?A.onClick(u||r):u?u(A.value):r()},children:A.label},H))})]})});return Le.createPortal(O,document.body)},Cr=g.createContext(null),Ro=({children:e})=>{const[r,t]=g.useState(null),o=g.useCallback(c=>new Promise((f,m)=>{const h=Math.random().toString(36).substr(2,9);t({id:h,content:c.content,title:c.title,actions:c.actions,options:c.options,resolve:f,reject:m})}),[]),n=g.useCallback(c=>{t(f=>(f&&f.resolve(c),null))},[]),s=g.useCallback(c=>o({title:c.title||"Confirm",content:c.message,actions:[{label:c.cancelLabel||"Cancel",variant:"outline",onClick:f=>f(!1)},{label:c.confirmLabel||"Confirm",color:c.confirmColor,onClick:f=>f(!0)}],options:c.options}),[o]),a=g.useCallback(c=>o({title:c.title||"Alert",content:c.message,actions:[{label:c.okLabel||"OK",color:c.okColor,onClick:f=>f()}],options:c.options}),[o]),l=g.useCallback(()=>{n()},[n]),u=g.useMemo(()=>({show:o,resolve:n,confirm:s,alert:a}),[o,n,s,a]);return d.jsxs(Cr.Provider,{value:u,children:[e,r&&d.jsx(kr,{isOpen:!0,onClose:l,title:r.title,actions:r.actions,resolveModal:n,...r.options,children:typeof r.content=="function"?r.content(n):r.content})]})},en=()=>{const e=g.useContext(Cr);if(!e)throw new Error("useModal must be used within a ModalProvider");return e},wr=({children:e,className:r,style:t,padding:o="0.5em",border:n=!1,backgroundColor:s,divProps:a})=>{const l=I();return d.jsx("div",{...a,className:r,style:{padding:o,borderRadius:l.border.radius,fontSize:"1em",backgroundColor:s??l.cards.backgroundColor,...n&&{borderWidth:l.border.width,borderStyle:"solid",borderColor:l.colors.primary},...t},children:e})},tn={xs:{chevronButton:"0.75em",headerPadding:"0.1em 0.25em",bodyPadding:"0 0.5em 0.5em 1.15em"},small:{chevronButton:"1em",headerPadding:"0.25em 0.25em",bodyPadding:"0 0.5em 0.75em 1.4em"},default:{chevronButton:"1.5em",headerPadding:"0.75em 0.25em",bodyPadding:"0 0.5em 1em 1.9em"},large:{chevronButton:"2em",headerPadding:"1em 0.25em",bodyPadding:"0 0.5em 1.25em 2.4em"}},rn=({headerContent:e,children:r,className:t,style:o,defaultOpen:n=!1,open:s,onOpenChange:a,border:l=!1,hideChevron:u=!1,headerPadding:c,headerStyle:f,bodyPadding:m,size:h="default",chevronStyle:b})=>{const S=I(),_=g.useId(),k=`collapsible-header-${_}`,V=`collapsible-body-${_}`,v=tn[h],z=c??v.headerPadding,E=m??v.bodyPadding,F=s!==void 0,[N,P]=g.useState(n),O=F?s:N,A=g.useCallback(()=>{const H=!O;F||P(H),a==null||a(H)},[O,F,a]);return d.jsxs("div",{className:t,style:{borderRadius:S.border.radius,...l&&{borderWidth:S.border.width,borderStyle:"solid",borderColor:`${S.colors.primary}33`},...o},children:[d.jsxs("div",{id:k,style:{display:"flex",alignItems:"center",gap:"0.15em",padding:z,userSelect:"none",...f},children:[!u&&d.jsx("button",{type:"button",onClick:A,"aria-expanded":O,"aria-controls":V,"aria-label":O?"Collapse":"Expand",title:O?"Collapse":"Expand",style:{display:"inline-flex",alignItems:"center",justifyContent:"center",width:v.chevronButton,height:v.chevronButton,background:"transparent",border:"none",padding:0,cursor:"pointer",color:"inherit",flexShrink:0,...b},children:d.jsx(on,{open:O})}),d.jsx("div",{style:{flex:1,display:"flex",alignItems:"center",gap:"0.5em"},children:e})]}),d.jsx("div",{"aria-hidden":!O||void 0,style:{display:"grid",gridTemplateRows:O?"1fr":"0fr",transition:"grid-template-rows 200ms ease"},children:d.jsx("div",{style:{overflow:"hidden",minHeight:0},children:d.jsx("div",{id:V,role:"region","aria-labelledby":k,style:{padding:E},children:r})})})]})},on=({open:e})=>d.jsx("svg",{width:"0.75em",height:"0.75em",viewBox:"0 0 12 12","aria-hidden":"true",style:{transform:e?"rotate(0deg)":"rotate(-90deg)",transition:"transform 200ms ease"},children:d.jsx("path",{d:"M2 4 L6 8 L10 4",fill:"none",stroke:"currentColor",strokeWidth:"1.75",strokeLinecap:"round",strokeLinejoin:"round"})}),xr={section:"ResponsiveSection-module__section___gBESK",innerDiv:"ResponsiveSection-module__innerDiv___r1bky"},Fr=({backgroundColor:e,color:r,maxWidth:t,minWidth:o,width:n,height:s,padding:a,paddingSm:l,margin:u,gap:c,verticalRhythm:f=3,children:m,className:h,style:b,sectionProps:S})=>{const _=I(),k=oe(`(min-width: ${_.breakpoints.sm})`),V={backgroundColor:e,color:r||_.fonts.color,margin:u,...b},v=`calc(${_.fonts.rhythm} * ${f})`,z=k?a||_.layout.padding:l||_.layout.paddingSm,E={"--max-width":t||_.layout.maxWidth,"--min-width":o,"--width":n,"--height":s,"--section-padding":`${v} ${z}`,"--gap":c},F=[xr.section,h].filter(Boolean).join(" ");return d.jsx("section",{...S,className:F,style:V,children:d.jsx("div",{className:xr.innerDiv,style:E,children:m})})},zr={hero:"Hero-module__hero___IB2tg",content:"Hero-module__content___rkkfQ"},nn=({isMd:e=!1,isLg:r=!1,theme:t})=>g.useMemo(()=>{const{rhythm:o}=t.fonts;let n=`calc(${o} * 2) 0`,s="2rem",a="1.125rem";return r?(n=`calc(${o} * 4) 0`,s="3.5rem",a="1.5rem"):e&&(n=`calc(${o} * 3.5) 0`,s="3rem",a="1.25rem"),{"--hero-padding":n,"--hero-h1-font-size":s,"--hero-p-font-size":a,"--hero-h1-margin-bottom":`calc(${o} * 0.7)`}},[e,r,t.fonts]),sn=({color:e,breakpoints:r,children:t,className:o,style:n,...s})=>{const a=I(),l=[zr.hero,o].filter(Boolean).join(" "),u=(r==null?void 0:r.md)||a.breakpoints.md,c=(r==null?void 0:r.lg)||a.breakpoints.lg,f=oe(`(min-width: ${u})`),m=oe(`(min-width: ${c})`),h=nn({isMd:f,isLg:m,theme:a});return d.jsx(Fr,{className:l,color:e||a.fonts.color,style:{...h,...n},...s,children:d.jsx("div",{className:zr.content,children:t})})},Vr={footer:"Footer-module__footer___A76NF",container:"Footer-module__container___QneNs"},an=({isSmallScreen:e=!1,maxWidth:r,minWidth:t,width:o,height:n,paddingSm:s,padding:a,margin:l,gap:u,backgroundColor:c,color:f}={})=>{const m=I();return{maxWidth:r||m.layout.maxWidth,minWidth:t,width:o,height:n,padding:e?s||m.layout.paddingSm:a||m.layout.padding,margin:l,gap:u,backgroundColor:c,color:f||m.fonts.color}},Er=({backgroundColor:e,color:r,maxWidth:t,minWidth:o,width:n,height:s,padding:a,paddingSm:l,margin:u,gap:c,breakPoint:f,children:m,className:h,style:b,footerProps:S})=>{const _=I(),k=f||_.breakpoints.sm,{maxWidth:V,unit:v}=ve(k),z=oe(`(max-width: ${V}${v})`),E=an({isSmallScreen:z,maxWidth:t,minWidth:o,width:n,height:s,paddingSm:l,padding:a,margin:u,gap:c,backgroundColor:e,color:r}),F=[Vr.container,h].filter(Boolean).join(" ");return d.jsx("footer",{...S,className:Vr.footer,children:d.jsx("div",{className:F,style:{...E,...b},children:m})})},je={card:"FeatureCard-module__card___XQt66",icon:"FeatureCard-module__icon___dXJ92",title:"FeatureCard-module__title___KxXyA",content:"FeatureCard-module__content___68xkw"},ln=({isMd:e=!1,theme:r})=>g.useMemo(()=>{const{rhythm:t}=r.fonts;return{"--feature-icon-font-size":e?"3rem":"2.5rem","--feature-title-font-size":e?"1.5rem":"1.25rem","--feature-card-padding":`calc(${t} * 1)`,"--feature-icon-margin-bottom":`calc(${t} * 0.7)`,"--feature-title-margin-bottom":`calc(${t} * 0.5)`}},[e,r.fonts]),cn=({breakpoint:e,icon:r,title:t,children:o,className:n,style:s,divProps:a})=>{const l=I(),u=[je.card,n].filter(Boolean).join(" "),c=e||l.breakpoints.md,f=oe(`(min-width: ${c})`),m=ln({isMd:f,theme:l});return d.jsxs("div",{...a,className:u,style:{...m,...s},children:[r&&d.jsx("div",{className:je.icon,children:r}),d.jsx("h3",{className:je.title,children:t}),d.jsx("div",{className:je.content,children:o})]})},dn={grid:"FeatureGrid-module__grid___6sW6f"},un=({columns:e,isMd:r=!1,isLg:t=!1})=>g.useMemo(()=>r?r&&!t&&(e===3||e===4)?{"--grid-template-columns":"repeat(2, 1fr)"}:{"--grid-template-columns":{1:"1fr",2:"repeat(2, 1fr)",3:"repeat(3, 1fr)",4:"repeat(4, 1fr)"}[e]}:{"--grid-template-columns":"1fr"},[e,r,t]),fn=({columns:e=3,breakpoints:r,gap:t,children:o,className:n,style:s})=>{const a=I(),l=(r==null?void 0:r.md)||a.breakpoints.md,u=(r==null?void 0:r.lg)||a.breakpoints.lg,c=oe(`(min-width: ${l})`),f=oe(`(min-width: ${u})`),h={...un({columns:e,isMd:c,isLg:f}),gap:t,...s};return d.jsx("div",{className:[dn.grid,n].filter(Boolean).join(" "),style:h,children:o})},we={card:"MediaCard-module__card___9pZ7C",clickable:"MediaCard-module__clickable___Rae9n",vertical:"MediaCard-module__vertical___GWtOA",imageWrapper:"MediaCard-module__imageWrapper___HUiag",horizontal:"MediaCard-module__horizontal___qlK4y",content:"MediaCard-module__content___MlqE4"},mn=({direction:e="column",imageSlot:r,imageWidth:t,border:o,backgroundColor:n,padding:s="0",children:a,className:l,style:u,onClick:c,actions:f,divProps:m})=>{const h=[we.card,e==="row"?we.horizontal:we.vertical,c?we.clickable:void 0,l].filter(Boolean).join(" "),b=S=>{c&&(S.key==="Enter"||S.key===" ")&&(S.preventDefault(),c())};return d.jsxs(wr,{border:o,backgroundColor:n,padding:s,className:h,style:{...t&&e==="row"&&{"--media-card-image-width":t},...u},divProps:{...m,onClick:c,onKeyDown:c?b:void 0,role:c?"button":void 0,tabIndex:c?0:void 0},children:[r&&d.jsx("div",{className:we.imageWrapper,children:r}),d.jsx("div",{className:we.content,children:a}),f]})},yt={layoutContainer:"PageLayout-module__layoutContainer___diLdT",content:"PageLayout-module__content___h2mBr",main:"PageLayout-module__main___Sw7Pv"},hn=({header:e,footer:r,children:t,className:o,style:n,headerProps:s,footerProps:a,divProps:l,mainProps:u,contentStyle:c})=>{const f=[yt.layoutContainer,o].filter(Boolean).join(" ");return d.jsxs("div",{...l,className:f,style:n,children:[d.jsxs("div",{className:yt.content,style:c,children:[e&&d.jsx(pr,{...s,children:e}),d.jsx("main",{...u,className:yt.main,children:t})]}),r&&d.jsx(Er,{...a,children:r})]})},ie={dropzone:"FileUpload-module__dropzone___jqua0",loading:"FileUpload-module__loading___C7PsH",dragOver:"FileUpload-module__dragOver___q1zPo",hiddenInput:"FileUpload-module__hiddenInput___RLLPJ",content:"FileUpload-module__content___yCP0l",contentHidden:"FileUpload-module__contentHidden___0Ewoe",spinnerOverlay:"FileUpload-module__spinnerOverlay___e3Rle",label:"FileUpload-module__label___lbMkx",hint:"FileUpload-module__hint___8dXlk",errorMessage:"FileUpload-module__errorMessage___8HB3n"},yn=({color:e})=>d.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:e,width:"48",height:"48","aria-hidden":!0,children:d.jsx("path",{d:"M19.35 10.04C18.67 6.59 15.64 4 12 4 9.11 4 6.6 5.64 5.35 8.04 2.34 8.36 0 10.91 0 14c0 3.31 2.69 6 6 6h13c2.76 0 5-2.24 5-5 0-2.64-2.05-4.78-4.65-4.96zM14 13v4h-4v-4H7l5-5 5 5h-3z"})}),gn=({onUpload:e,accept:r,maxSizeBytes:t,loading:o=!1,error:n,label:s="Click or drag & drop a file here",className:a,style:l,divProps:u,inputProps:c})=>{const f=I(),m=g.useRef(null),[h,b]=g.useState(!1),[S,_]=g.useState(null),k=n||S,V=k?f.colors.error:f.colors.primary,v=k?f.colors.error:f.colors.primary,z=g.useCallback(B=>{if(_(null),t&&B.size>t){const D=(t/1048576).toFixed(1);_(`File exceeds maximum size of ${D} MB`);return}e(B)},[t,e]),E=()=>{var B;o||(B=m.current)==null||B.click()},F=B=>{var D;(B.key==="Enter"||B.key===" ")&&!o&&(B.preventDefault(),(D=m.current)==null||D.click())},N=B=>{var T;const D=(T=B.target.files)==null?void 0:T[0];D&&z(D),B.target.value=""},P=B=>{B.preventDefault(),o||b(!0)},O=()=>b(!1),A=B=>{var T;if(B.preventDefault(),b(!1),o)return;const D=(T=B.dataTransfer.files)==null?void 0:T[0];D&&z(D)},H=[ie.dropzone,h&&ie.dragOver,o&&ie.loading,a].filter(Boolean).join(" "),G={"--upload-color":V,borderColor:V,borderWidth:f.border.width,borderRadius:f.border.radius,fontSize:"1em",color:v,...l};return d.jsxs("div",{...u,className:H,style:G,onClick:E,onKeyDown:F,onDragOver:P,onDragLeave:O,onDrop:A,role:"button",tabIndex:o?-1:0,"aria-disabled":o,"aria-label":s,children:[d.jsx("input",{...c,ref:m,type:"file",accept:r,onChange:N,disabled:o,className:ie.hiddenInput,tabIndex:-1,"aria-hidden":!0}),o&&d.jsx(mt,{fullScreen:!1,className:ie.spinnerOverlay,style:{fontSize:"1.5em"}}),d.jsxs("div",{className:[ie.content,o&&ie.contentHidden].filter(Boolean).join(" "),"aria-hidden":o||void 0,children:[d.jsx(yn,{color:V}),d.jsx("span",{className:ie.label,children:s}),r&&d.jsxs("span",{className:ie.hint,children:["Accepted: ",r]}),t&&d.jsxs("span",{className:ie.hint,children:["Max size: ",(t/(1024*1024)).toFixed(1)," MB"]}),k&&d.jsx("span",{className:ie.errorMessage,role:"alert",children:k})]})]})},gt={container:"Image-module__container___sVJdZ",img:"Image-module__img___pKhPw",fallback:"Image-module__fallback___wysuM"},pn={skeleton:"Skeleton-module__skeleton___CB4uF"},pt=({className:e,style:r,divProps:t})=>{const o=I(),n=[pn.skeleton,e].filter(Boolean).join(" ");return d.jsx("div",{...t,className:n,style:{borderRadius:o.border.radius,...r},"aria-label":"Loading","aria-busy":!0})},_n=({src:e,alt:r="",aspectRatio:t="1 / 1",loading:o=!1,skeletonDelay:n=150,fallback:s,className:a,style:l,imgProps:u})=>{const c=I(),[f,m]=g.useState(null),[h,b]=g.useState(null),[S,_]=g.useState(null),k=f===e,V=h===e,v=S===e;g.useEffect(()=>{if(!e)return;const O=setTimeout(()=>_(e),n);return()=>clearTimeout(O)},[e,n]);const z=o||!!e&&!k&&!V&&v,E=!o&&(!e||V),F=!o&&!!e&&!V,N=[gt.container,a].filter(Boolean).join(" "),P={aspectRatio:t,borderRadius:c.border.radius,...l};return d.jsxs("div",{className:N,style:P,"aria-label":E?r||"Image placeholder":void 0,"aria-busy":z||void 0,children:[z&&d.jsx(pt,{style:{borderRadius:"inherit",position:"absolute",inset:0}}),E&&d.jsx("div",{className:gt.fallback,children:s??null}),F&&d.jsx("img",{...u,src:e,alt:r,className:gt.img,style:{opacity:k?1:0},onLoad:()=>e&&m(e),onError:()=>e&&b(e)})]})},pe={thumbnail:"ImageThumbnail-module__thumbnail___-igbe",img:"ImageThumbnail-module__img___Q7Z4V",sizeXs:"ImageThumbnail-module__sizeXs___TvSHV",sizeSmall:"ImageThumbnail-module__sizeSmall___2KnCh",sizeDefault:"ImageThumbnail-module__sizeDefault___laoQk",sizeLarge:"ImageThumbnail-module__sizeLarge___iwz3o",removeButton:"ImageThumbnail-module__removeButton___Ceh1Q"},vn={xs:pe.sizeXs,small:pe.sizeSmall,default:pe.sizeDefault,large:pe.sizeLarge},bn=({color:e})=>d.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"none",stroke:e,strokeWidth:"1.5",width:"40%",height:"40%","aria-hidden":!0,children:[d.jsx("rect",{x:"3",y:"3",width:"18",height:"18",rx:"2"}),d.jsx("circle",{cx:"8.5",cy:"8.5",r:"1.5"}),d.jsx("polyline",{points:"21 15 16 10 5 21"})]}),Sn=({src:e,alt:r="",size:t="default",loading:o=!1,skeletonDelay:n=500,onRemove:s,removeLabel:a="Remove",fallback:l,className:u,style:c,imgProps:f})=>{const m=I(),[h,b]=g.useState(null),[S,_]=g.useState(null),[k,V]=g.useState(null),v=h===e,z=S===e,E=k===e;g.useEffect(()=>{if(!e)return;const G=setTimeout(()=>V(e),n);return()=>clearTimeout(G)},[e,n]);const F=o||!!e&&!v&&!z&&E,N=!o&&(!e||z),P=!o&&!!e&&!z,O=[pe.thumbnail,vn[t],u].filter(Boolean).join(" "),A={borderRadius:m.border.radius,...c},H={background:m.colors.primary,color:m.buttons.primary.textColor,borderRadius:"50%"};return d.jsxs("div",{className:O,style:A,"aria-label":N?r||"Image placeholder":void 0,"aria-busy":F||void 0,children:[F&&d.jsx(pt,{style:{borderRadius:"inherit",position:"absolute",inset:0}}),N&&(l??d.jsx(bn,{color:m.colors.primary})),P&&d.jsx("img",{...f,src:e,alt:r,className:pe.img,style:{opacity:v?1:0},onLoad:()=>e&&b(e),onError:()=>e&&_(e)}),s&&d.jsx("button",{type:"button",className:pe.removeButton,style:H,onClick:G=>{G.stopPropagation(),s()},"aria-label":a,children:d.jsxs("svg",{viewBox:"0 0 10 10",width:"60%",height:"60%",fill:"none",stroke:"currentColor",strokeWidth:m.fonts.fontWeightHeader>=700?2:1.5,"aria-hidden":!0,children:[d.jsx("line",{x1:"2",y1:"2",x2:"8",y2:"8"}),d.jsx("line",{x1:"8",y1:"2",x2:"2",y2:"8"})]})})]})},kn=({level:e,tag:r,className:t,style:o,children:n})=>{const s=I(),a=r??`h${e}`,l=s.typography.heading[a],c=`dr-heading-${g.useId().replace(/:/g,"")}`,f=g.useMemo(()=>{const S=[];return l.mdFontSize&&S.push(`@media (max-width: ${s.breakpoints.md}) { .${c} { font-size: ${l.mdFontSize}; } }`),l.smFontSize&&S.push(`@media (max-width: ${s.breakpoints.sm}) { .${c} { font-size: ${l.smFontSize}; } }`),S.join(`
39
- `)},[c,l.mdFontSize,l.smFontSize,s.breakpoints.md,s.breakpoints.sm]),m={fontSize:l.fontSize,...l.lineHeight!==void 0&&{lineHeight:l.lineHeight},...l.fontWeight!==void 0&&{fontWeight:l.fontWeight},...o},h=[c,t].filter(Boolean).join(" "),b=`h${e}`;return d.jsxs(d.Fragment,{children:[f&&d.jsx("style",{children:f}),g.createElement(b,{className:h,style:m},n)]})},Cn=({size:e="default",as:r="p",className:t,style:o,children:n})=>{const a=I().typography.text[e],l={fontSize:a.fontSize,...a.lineHeight!==void 0&&{lineHeight:a.lineHeight},...o};return g.createElement(r,{className:t,style:l},n)},wn=({variant:e="default",className:r,style:t,children:o})=>{const n=I();let s,a,l;switch(e){case"caption":s=n.typography.text.xs.fontSize,l=700;break;case"subtle":s=n.typography.text.sm.fontSize,a=.7;break;case"default":default:s=n.typography.text.sm.fontSize,l=700;break}const u={fontSize:s,...a!==void 0&&{opacity:a},...l!==void 0&&{fontWeight:l},...t};return d.jsx("span",{className:r,style:u,children:o})};function xn({steps:e,currentStep:r,color:t,textColor:o,errors:n=[],onStepClick:s,maxStep:a,style:l,className:u}){var z;const c=I(),f=t||c.colors.primary,m=o||(((z=c.buttons.primary)==null?void 0:z.textColor)??c.buttons.textColor),h=c.colors.error,b="#ccc",S="#999",_=!!s,k=E=>_&&(a===void 0||E<=a),V=e.map((E,F)=>F<e.length-1?"3em 1fr":"3em").join(" "),v=`${e.length*3+(e.length-1)*4}em`;return d.jsxs("div",{className:u,style:{display:"grid",gridTemplateColumns:V,rowGap:"0.3em",maxWidth:v,...l},children:[e.map((E,F)=>{const N=F+1,P=n.includes(N),O=N===r&&!P,A=N<r&&!P,H=P?h:O||A?f:"transparent",G=P?h:O||A?f:b,B=P||O||A?m:b,D=A?f:b;return d.jsxs(g.Fragment,{children:[d.jsx("div",{role:k(N)?"button":void 0,tabIndex:k(N)?0:void 0,onClick:k(N)?()=>s(N):void 0,onKeyDown:k(N)?T=>{(T.key==="Enter"||T.key===" ")&&s(N)}:void 0,style:{display:"flex",justifyContent:"center",alignItems:"center",cursor:k(N)?"pointer":"default"},children:d.jsx("div",{style:{width:"1.3em",height:"1.3em",borderRadius:"50%",backgroundColor:H,border:`2px solid ${G}`,display:"flex",alignItems:"center",justifyContent:"center",flexShrink:0,boxSizing:"border-box"},children:d.jsx("span",{style:{fontSize:"0.6em",fontWeight:700,lineHeight:1,color:B,userSelect:"none"},children:P?"!":A?"✓":N})})}),F<e.length-1&&d.jsx("div",{style:{height:"2px",backgroundColor:D,alignSelf:"center",marginLeft:"0.25em",marginRight:"0.25em"}})]},`c-${F}`)}),e.map((E,F)=>{const N=F+1,P=n.includes(N),O=N===r&&!P;return d.jsxs(g.Fragment,{children:[d.jsx("div",{role:k(N)?"button":void 0,tabIndex:k(N)?0:void 0,onClick:k(N)?()=>s(N):void 0,onKeyDown:k(N)?A=>{(A.key==="Enter"||A.key===" ")&&s(N)}:void 0,style:{display:"flex",justifyContent:"center",cursor:k(N)?"pointer":"default"},children:d.jsx("span",{style:{fontSize:"0.7em",color:P?h:O?f:S,fontWeight:P||O?600:400,whiteSpace:"nowrap"},children:E})}),F<e.length-1&&d.jsx("div",{})]},`l-${F}`)})]})}const $r={triggerWrapper:"Tooltip-module__triggerWrapper___wMSun",tooltip:"Tooltip-module__tooltip___UA7H9"},Fn=({children:e,content:r,placement:t="top",openDelay:o=200,closeDelay:n=100,offset:s=8,disabled:a=!1,color:l,backgroundColor:u,className:c,style:f,tooltipProps:m})=>{const h=I(),b=g.useRef(null),S=g.useRef(null),_=g.useRef(null),[k,V]=g.useState(!1),v=g.useId(),z=k&&!a&&!!r,{side:E,align:F}=_r(t),{positionStyle:N}=vr({open:z,triggerRef:b,side:E,align:F,offset:s}),P=()=>{S.current&&clearTimeout(S.current),_.current&&clearTimeout(_.current),S.current=null,_.current=null},O=g.useCallback(()=>{P(),S.current=setTimeout(()=>V(!0),o)},[o]),A=g.useCallback(()=>{P(),_.current=setTimeout(()=>V(!1),n)},[n]),H={backgroundColor:u||h.colors.secondaryBackground,color:l,borderRadius:h.border.radius,...N,...f};return d.jsxs(d.Fragment,{children:[d.jsx("span",{ref:b,className:$r.triggerWrapper,onMouseEnter:O,onMouseLeave:A,onFocus:O,onBlur:A,"aria-describedby":z?v:void 0,children:e}),z&&Le.createPortal(d.jsx("div",{id:v,role:"tooltip",className:[$r.tooltip,c].filter(Boolean).join(" "),style:H,...m,children:r}),document.body)]})};L.Button=xt,L.CSSReset=Kr,L.Card=wr,L.Checkbox=Pe,L.Collapsible=rn,L.FeatureCard=cn,L.FeatureGrid=fn,L.FileUpload=gn,L.Footer=Er,L.Form=zo,L.FormCheckbox=Ao,L.FormCheckboxGroup=Io,L.FormError=dr,L.FormField=me,L.FormGroup=ur,L.FormInput=$o,L.FormLabel=Ae,L.FormRadio=Do,L.FormRadioGroup=Oo,L.FormSelect=Mo,L.FormTextarea=No,L.Hamburger=yr,L.Header=pr,L.Heading=kn,L.Hero=sn,L.Image=_n,L.ImageThumbnail=Sn,L.Input=fr,L.Label=wn,L.LoadingSpinner=mt,L.MediaCard=mn,L.Modal=kr,L.ModalProvider=Ro,L.NavDropdown=Xo,L.NavLink=Jo,L.PageLayout=hn,L.Popover=dt,L.Radio=ct,L.ResponsiveNav=Qo,L.ResponsiveNavContext=br,L.ResponsiveSection=Fr,L.Select=hr,L.Skeleton=pt,L.Stack=Sr,L.Stepper=xn,L.StyleLoader=Yo,L.Text=Cn,L.Textarea=mr,L.ThemeProvider=jr,L.Tooltip=Fn,L.parseBreakpoint=ve,L.useFormContext=cr,L.useMediaQuery=oe,L.useModal=en,L.useNavLinkStyles=ft,L.useTheme=I,Object.defineProperty(L,Symbol.toStringTag,{value:"Module"})}));
38
+ `})]});return t?d.jsx("div",{...s,"data-loading":"true",className:o,style:{display:"flex",justifyContent:"center",alignItems:"center",height:"100vh",width:"100vw",...n},children:f}):f},Ro=({children:e,loadingComponent:r})=>{const[t,o]=g.useState(!1);return g.useEffect(()=>{requestAnimationFrame(()=>{o(!0)})},[]),t?d.jsx(d.Fragment,{children:e}):r||d.jsx(mt,{})},ge={backdrop:"Modal-module__backdrop___GVUh4",modal:"Modal-module__modal___aD7aP",header:"Modal-module__header___ILG9i",title:"Modal-module__title___A5OeE",closeButton:"Modal-module__closeButton___3LpSf",content:"Modal-module__content___dWO-B",actions:"Modal-module__actions___hY6zi"},ht={stack:"Stack-module__stack___yUU-B",vertical:"Stack-module__vertical___sKTyQ",horizontal:"Stack-module__horizontal___YsvtV"},kr=({direction:e="row",gap:r="0.5em",children:t,className:o,style:n,divProps:s})=>{const a=[ht.stack,e==="column"?ht.vertical:ht.horizontal,o].filter(Boolean).join(" ");return d.jsx("div",{...s,className:a,style:{gap:r,...n},children:t})},Cr=({isOpen:e,onClose:r,children:t,title:o,hideCloseButton:n=!1,closeOnBackdropClick:s=!0,closeOnEscape:a=!0,actions:l=[],resolveModal:u,width:c="500px",maxWidth:f="90vw",backgroundColor:m,backdropColor:h="rgba(0, 0, 0, 0.5)",className:b,style:S,divProps:_})=>{const k=I(),V=g.useRef(null),v=g.useRef(null),{maxWidth:z}=ve(k.breakpoints.md),E=oe(`(max-width: ${z-1}px)`);g.useEffect(()=>{if(e)return v.current=document.activeElement,document.body.style.overflow="hidden",V.current&&V.current.focus(),()=>{document.body.style.overflow="",v.current&&v.current.focus()}},[e]),g.useEffect(()=>{if(!e||!a)return;const A=H=>{H.key==="Escape"&&r()};return document.addEventListener("keydown",A),()=>document.removeEventListener("keydown",A)},[e,a,r]);const F=A=>{A.target===A.currentTarget&&s&&r()};if(!e)return null;const N={width:c,maxWidth:f,backgroundColor:m||k.colors.secondary,borderRadius:k.border.radius,...S},P={backgroundColor:h},O=d.jsx("div",{className:ge.backdrop,style:P,onClick:F,role:"presentation",children:d.jsxs("div",{ref:V,className:[ge.modal,b].filter(Boolean).join(" "),style:N,role:"dialog","aria-modal":"true","aria-labelledby":o?"modal-title":void 0,tabIndex:-1,..._,children:[d.jsxs("div",{className:ge.header,children:[o&&d.jsx("h2",{id:"modal-title",className:ge.title,children:o}),!n&&d.jsx("button",{className:ge.closeButton,onClick:r,"aria-label":"Close modal",type:"button",children:d.jsx("svg",{width:"100%",height:"100%",viewBox:"0 0 20 20",fill:"none",xmlns:"http://www.w3.org/2000/svg","aria-hidden":"true",children:d.jsx("path",{d:"M15 5L5 15M5 5L15 15",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round"})})})]}),d.jsx("div",{className:ge.content,children:t}),l.length>0&&d.jsx(kr,{direction:E?"column":"row",className:ge.actions,children:l.map((A,H)=>d.jsx(xt,{color:A.color,outline:A.variant==="outline",disabled:A.disabled,onClick:()=>{A.onClick?A.onClick(u||r):u?u(A.value):r()},children:A.label},H))})]})});return Le.createPortal(O,document.body)},wr=g.createContext(null),en=({children:e})=>{const[r,t]=g.useState(null),o=g.useCallback(c=>new Promise((f,m)=>{const h=Math.random().toString(36).substr(2,9);t({id:h,content:c.content,title:c.title,actions:c.actions,options:c.options,resolve:f,reject:m})}),[]),n=g.useCallback(c=>{t(f=>(f&&f.resolve(c),null))},[]),s=g.useCallback(c=>o({title:c.title||"Confirm",content:c.message,actions:[{label:c.cancelLabel||"Cancel",variant:"outline",onClick:f=>f(!1)},{label:c.confirmLabel||"Confirm",color:c.confirmColor,onClick:f=>f(!0)}],options:c.options}),[o]),a=g.useCallback(c=>o({title:c.title||"Alert",content:c.message,actions:[{label:c.okLabel||"OK",color:c.okColor,onClick:f=>f()}],options:c.options}),[o]),l=g.useCallback(()=>{n()},[n]),u=g.useMemo(()=>({show:o,resolve:n,confirm:s,alert:a}),[o,n,s,a]);return d.jsxs(wr.Provider,{value:u,children:[e,r&&d.jsx(Cr,{isOpen:!0,onClose:l,title:r.title,actions:r.actions,resolveModal:n,...r.options,children:typeof r.content=="function"?r.content(n):r.content})]})},tn=()=>{const e=g.useContext(wr);if(!e)throw new Error("useModal must be used within a ModalProvider");return e},xr=({children:e,className:r,style:t,padding:o="0.5em",border:n=!1,backgroundColor:s,divProps:a})=>{const l=I();return d.jsx("div",{...a,className:r,style:{padding:o,borderRadius:l.border.radius,fontSize:"1em",backgroundColor:s??l.cards.backgroundColor,...n&&{borderWidth:l.border.width,borderStyle:"solid",borderColor:l.colors.primary},...t},children:e})},rn={xs:{chevronButton:"0.75em",headerPadding:"0.1em 0.25em",bodyPadding:"0 0.5em 0.5em 1.15em"},small:{chevronButton:"1em",headerPadding:"0.25em 0.25em",bodyPadding:"0 0.5em 0.75em 1.4em"},default:{chevronButton:"1.5em",headerPadding:"0.75em 0.25em",bodyPadding:"0 0.5em 1em 1.9em"},large:{chevronButton:"2em",headerPadding:"1em 0.25em",bodyPadding:"0 0.5em 1.25em 2.4em"}},on=({headerContent:e,children:r,className:t,style:o,defaultOpen:n=!1,open:s,onOpenChange:a,border:l=!1,hideChevron:u=!1,headerPadding:c,headerStyle:f,bodyPadding:m,size:h="default",chevronStyle:b})=>{const S=I(),_=g.useId(),k=`collapsible-header-${_}`,V=`collapsible-body-${_}`,v=rn[h],z=c??v.headerPadding,E=m??v.bodyPadding,F=s!==void 0,[N,P]=g.useState(n),O=F?s:N,A=g.useCallback(()=>{const H=!O;F||P(H),a==null||a(H)},[O,F,a]);return d.jsxs("div",{className:t,style:{borderRadius:S.border.radius,...l&&{borderWidth:S.border.width,borderStyle:"solid",borderColor:`${S.colors.primary}33`},...o},children:[d.jsxs("div",{id:k,style:{display:"flex",alignItems:"center",gap:"0.15em",padding:z,userSelect:"none",...f},children:[!u&&d.jsx("button",{type:"button",onClick:A,"aria-expanded":O,"aria-controls":V,"aria-label":O?"Collapse":"Expand",title:O?"Collapse":"Expand",style:{display:"inline-flex",alignItems:"center",justifyContent:"center",width:v.chevronButton,height:v.chevronButton,background:"transparent",border:"none",padding:0,cursor:"pointer",color:"inherit",flexShrink:0,...b},children:d.jsx(nn,{open:O})}),d.jsx("div",{style:{flex:1,display:"flex",alignItems:"center",gap:"0.5em"},children:e})]}),d.jsx("div",{"aria-hidden":!O||void 0,style:{display:"grid",gridTemplateRows:O?"1fr":"0fr",transition:"grid-template-rows 200ms ease"},children:d.jsx("div",{style:{overflow:"hidden",minHeight:0},children:d.jsx("div",{id:V,role:"region","aria-labelledby":k,style:{padding:E},children:r})})})]})},nn=({open:e})=>d.jsx("svg",{width:"0.75em",height:"0.75em",viewBox:"0 0 12 12","aria-hidden":"true",style:{transform:e?"rotate(0deg)":"rotate(-90deg)",transition:"transform 200ms ease"},children:d.jsx("path",{d:"M2 4 L6 8 L10 4",fill:"none",stroke:"currentColor",strokeWidth:"1.75",strokeLinecap:"round",strokeLinejoin:"round"})}),Fr={section:"ResponsiveSection-module__section___gBESK",innerDiv:"ResponsiveSection-module__innerDiv___r1bky"},zr=({backgroundColor:e,color:r,maxWidth:t,minWidth:o,width:n,height:s,padding:a,paddingSm:l,margin:u,gap:c,verticalRhythm:f=3,children:m,className:h,style:b,sectionProps:S})=>{const _=I(),k=oe(`(min-width: ${_.breakpoints.sm})`),V={backgroundColor:e,color:r||_.fonts.color,margin:u,...b},v=`calc(${_.fonts.rhythm} * ${f})`,z=k?a||_.layout.padding:l||_.layout.paddingSm,E={"--max-width":t||_.layout.maxWidth,"--min-width":o,"--width":n,"--height":s,"--section-padding":`${v} ${z}`,"--gap":c},F=[Fr.section,h].filter(Boolean).join(" ");return d.jsx("section",{...S,className:F,style:V,children:d.jsx("div",{className:Fr.innerDiv,style:E,children:m})})},Vr={hero:"Hero-module__hero___IB2tg",content:"Hero-module__content___rkkfQ"},sn=({isMd:e=!1,isLg:r=!1,theme:t})=>g.useMemo(()=>{const{rhythm:o}=t.fonts;let n=`calc(${o} * 2) 0`,s="2rem",a="1.125rem";return r?(n=`calc(${o} * 4) 0`,s="3.5rem",a="1.5rem"):e&&(n=`calc(${o} * 3.5) 0`,s="3rem",a="1.25rem"),{"--hero-padding":n,"--hero-h1-font-size":s,"--hero-p-font-size":a,"--hero-h1-margin-bottom":`calc(${o} * 0.7)`}},[e,r,t.fonts]),an=({color:e,breakpoints:r,children:t,className:o,style:n,...s})=>{const a=I(),l=[Vr.hero,o].filter(Boolean).join(" "),u=(r==null?void 0:r.md)||a.breakpoints.md,c=(r==null?void 0:r.lg)||a.breakpoints.lg,f=oe(`(min-width: ${u})`),m=oe(`(min-width: ${c})`),h=sn({isMd:f,isLg:m,theme:a});return d.jsx(zr,{className:l,color:e||a.fonts.color,style:{...h,...n},...s,children:d.jsx("div",{className:Vr.content,children:t})})},Er={footer:"Footer-module__footer___A76NF",container:"Footer-module__container___QneNs"},ln=({isSmallScreen:e=!1,maxWidth:r,minWidth:t,width:o,height:n,paddingSm:s,padding:a,margin:l,gap:u,backgroundColor:c,color:f}={})=>{const m=I();return{maxWidth:r||m.layout.maxWidth,minWidth:t,width:o,height:n,padding:e?s||m.layout.paddingSm:a||m.layout.padding,margin:l,gap:u,backgroundColor:c,color:f||m.fonts.color}},$r=({backgroundColor:e,color:r,maxWidth:t,minWidth:o,width:n,height:s,padding:a,paddingSm:l,margin:u,gap:c,breakPoint:f,children:m,className:h,style:b,footerProps:S})=>{const _=I(),k=f||_.breakpoints.sm,{maxWidth:V,unit:v}=ve(k),z=oe(`(max-width: ${V}${v})`),E=ln({isSmallScreen:z,maxWidth:t,minWidth:o,width:n,height:s,paddingSm:l,padding:a,margin:u,gap:c,backgroundColor:e,color:r}),F=[Er.container,h].filter(Boolean).join(" ");return d.jsx("footer",{...S,className:Er.footer,children:d.jsx("div",{className:F,style:{...E,...b},children:m})})},We={card:"FeatureCard-module__card___XQt66",icon:"FeatureCard-module__icon___dXJ92",title:"FeatureCard-module__title___KxXyA",content:"FeatureCard-module__content___68xkw"},cn=({isMd:e=!1,theme:r})=>g.useMemo(()=>{const{rhythm:t}=r.fonts;return{"--feature-icon-font-size":e?"3rem":"2.5rem","--feature-title-font-size":e?"1.5rem":"1.25rem","--feature-card-padding":`calc(${t} * 1)`,"--feature-icon-margin-bottom":`calc(${t} * 0.7)`,"--feature-title-margin-bottom":`calc(${t} * 0.5)`}},[e,r.fonts]),dn=({breakpoint:e,icon:r,title:t,children:o,className:n,style:s,divProps:a})=>{const l=I(),u=[We.card,n].filter(Boolean).join(" "),c=e||l.breakpoints.md,f=oe(`(min-width: ${c})`),m=cn({isMd:f,theme:l});return d.jsxs("div",{...a,className:u,style:{...m,...s},children:[r&&d.jsx("div",{className:We.icon,children:r}),d.jsx("h3",{className:We.title,children:t}),d.jsx("div",{className:We.content,children:o})]})},un={grid:"FeatureGrid-module__grid___6sW6f"},fn=({columns:e,isMd:r=!1,isLg:t=!1})=>g.useMemo(()=>r?r&&!t&&(e===3||e===4)?{"--grid-template-columns":"repeat(2, 1fr)"}:{"--grid-template-columns":{1:"1fr",2:"repeat(2, 1fr)",3:"repeat(3, 1fr)",4:"repeat(4, 1fr)"}[e]}:{"--grid-template-columns":"1fr"},[e,r,t]),mn=({columns:e=3,breakpoints:r,gap:t,children:o,className:n,style:s})=>{const a=I(),l=(r==null?void 0:r.md)||a.breakpoints.md,u=(r==null?void 0:r.lg)||a.breakpoints.lg,c=oe(`(min-width: ${l})`),f=oe(`(min-width: ${u})`),h={...fn({columns:e,isMd:c,isLg:f}),gap:t,...s};return d.jsx("div",{className:[un.grid,n].filter(Boolean).join(" "),style:h,children:o})},we={card:"MediaCard-module__card___9pZ7C",clickable:"MediaCard-module__clickable___Rae9n",vertical:"MediaCard-module__vertical___GWtOA",imageWrapper:"MediaCard-module__imageWrapper___HUiag",horizontal:"MediaCard-module__horizontal___qlK4y",content:"MediaCard-module__content___MlqE4"},hn=({direction:e="column",imageSlot:r,imageWidth:t,border:o,backgroundColor:n,padding:s="0",children:a,className:l,style:u,onClick:c,actions:f,divProps:m})=>{const h=[we.card,e==="row"?we.horizontal:we.vertical,c?we.clickable:void 0,l].filter(Boolean).join(" "),b=S=>{c&&(S.key==="Enter"||S.key===" ")&&(S.preventDefault(),c())};return d.jsxs(xr,{border:o,backgroundColor:n,padding:s,className:h,style:{...t&&e==="row"&&{"--media-card-image-width":t},...u},divProps:{...m,onClick:c,onKeyDown:c?b:void 0,role:c?"button":void 0,tabIndex:c?0:void 0},children:[r&&d.jsx("div",{className:we.imageWrapper,children:r}),d.jsx("div",{className:we.content,children:a}),f]})},yt={layoutContainer:"PageLayout-module__layoutContainer___diLdT",content:"PageLayout-module__content___h2mBr",main:"PageLayout-module__main___Sw7Pv"},yn=({header:e,footer:r,children:t,className:o,style:n,headerProps:s,footerProps:a,divProps:l,mainProps:u,contentStyle:c})=>{const f=[yt.layoutContainer,o].filter(Boolean).join(" ");return d.jsxs("div",{...l,className:f,style:n,children:[d.jsxs("div",{className:yt.content,style:c,children:[e&&d.jsx(_r,{...s,children:e}),d.jsx("main",{...u,className:yt.main,children:t})]}),r&&d.jsx($r,{...a,children:r})]})},ie={dropzone:"FileUpload-module__dropzone___jqua0",loading:"FileUpload-module__loading___C7PsH",dragOver:"FileUpload-module__dragOver___q1zPo",hiddenInput:"FileUpload-module__hiddenInput___RLLPJ",content:"FileUpload-module__content___yCP0l",contentHidden:"FileUpload-module__contentHidden___0Ewoe",spinnerOverlay:"FileUpload-module__spinnerOverlay___e3Rle",label:"FileUpload-module__label___lbMkx",hint:"FileUpload-module__hint___8dXlk",errorMessage:"FileUpload-module__errorMessage___8HB3n"},gn=({color:e})=>d.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:e,width:"48",height:"48","aria-hidden":!0,children:d.jsx("path",{d:"M19.35 10.04C18.67 6.59 15.64 4 12 4 9.11 4 6.6 5.64 5.35 8.04 2.34 8.36 0 10.91 0 14c0 3.31 2.69 6 6 6h13c2.76 0 5-2.24 5-5 0-2.64-2.05-4.78-4.65-4.96zM14 13v4h-4v-4H7l5-5 5 5h-3z"})}),pn=({onUpload:e,accept:r,maxSizeBytes:t,loading:o=!1,error:n,label:s="Click or drag & drop a file here",className:a,style:l,divProps:u,inputProps:c})=>{const f=I(),m=g.useRef(null),[h,b]=g.useState(!1),[S,_]=g.useState(null),k=n||S,V=k?f.colors.error:f.colors.primary,v=k?f.colors.error:f.colors.primary,z=g.useCallback(B=>{if(_(null),t&&B.size>t){const D=(t/1048576).toFixed(1);_(`File exceeds maximum size of ${D} MB`);return}e(B)},[t,e]),E=()=>{var B;o||(B=m.current)==null||B.click()},F=B=>{var D;(B.key==="Enter"||B.key===" ")&&!o&&(B.preventDefault(),(D=m.current)==null||D.click())},N=B=>{var T;const D=(T=B.target.files)==null?void 0:T[0];D&&z(D),B.target.value=""},P=B=>{B.preventDefault(),o||b(!0)},O=()=>b(!1),A=B=>{var T;if(B.preventDefault(),b(!1),o)return;const D=(T=B.dataTransfer.files)==null?void 0:T[0];D&&z(D)},H=[ie.dropzone,h&&ie.dragOver,o&&ie.loading,a].filter(Boolean).join(" "),G={"--upload-color":V,borderColor:V,borderWidth:f.border.width,borderRadius:f.border.radius,fontSize:"1em",color:v,...l};return d.jsxs("div",{...u,className:H,style:G,onClick:E,onKeyDown:F,onDragOver:P,onDragLeave:O,onDrop:A,role:"button",tabIndex:o?-1:0,"aria-disabled":o,"aria-label":s,children:[d.jsx("input",{...c,ref:m,type:"file",accept:r,onChange:N,disabled:o,className:ie.hiddenInput,tabIndex:-1,"aria-hidden":!0}),o&&d.jsx(mt,{fullScreen:!1,className:ie.spinnerOverlay,style:{fontSize:"1.5em"}}),d.jsxs("div",{className:[ie.content,o&&ie.contentHidden].filter(Boolean).join(" "),"aria-hidden":o||void 0,children:[d.jsx(gn,{color:V}),d.jsx("span",{className:ie.label,children:s}),r&&d.jsxs("span",{className:ie.hint,children:["Accepted: ",r]}),t&&d.jsxs("span",{className:ie.hint,children:["Max size: ",(t/(1024*1024)).toFixed(1)," MB"]}),k&&d.jsx("span",{className:ie.errorMessage,role:"alert",children:k})]})]})},gt={container:"Image-module__container___sVJdZ",img:"Image-module__img___pKhPw",fallback:"Image-module__fallback___wysuM"},_n={skeleton:"Skeleton-module__skeleton___CB4uF"},pt=({className:e,style:r,divProps:t})=>{const o=I(),n=[_n.skeleton,e].filter(Boolean).join(" ");return d.jsx("div",{...t,className:n,style:{borderRadius:o.border.radius,...r},"aria-label":"Loading","aria-busy":!0})},vn=({src:e,alt:r="",aspectRatio:t="1 / 1",loading:o=!1,skeletonDelay:n=150,fallback:s,className:a,style:l,imgProps:u})=>{const c=I(),[f,m]=g.useState(null),[h,b]=g.useState(null),[S,_]=g.useState(null),k=f===e,V=h===e,v=S===e;g.useEffect(()=>{if(!e)return;const O=setTimeout(()=>_(e),n);return()=>clearTimeout(O)},[e,n]);const z=o||!!e&&!k&&!V&&v,E=!o&&(!e||V),F=!o&&!!e&&!V,N=[gt.container,a].filter(Boolean).join(" "),P={aspectRatio:t,borderRadius:c.border.radius,...l};return d.jsxs("div",{className:N,style:P,"aria-label":E?r||"Image placeholder":void 0,"aria-busy":z||void 0,children:[z&&d.jsx(pt,{style:{borderRadius:"inherit",position:"absolute",inset:0}}),E&&d.jsx("div",{className:gt.fallback,children:s??null}),F&&d.jsx("img",{...u,src:e,alt:r,className:gt.img,style:{opacity:k?1:0},onLoad:()=>e&&m(e),onError:()=>e&&b(e)})]})},pe={thumbnail:"ImageThumbnail-module__thumbnail___-igbe",img:"ImageThumbnail-module__img___Q7Z4V",sizeXs:"ImageThumbnail-module__sizeXs___TvSHV",sizeSmall:"ImageThumbnail-module__sizeSmall___2KnCh",sizeDefault:"ImageThumbnail-module__sizeDefault___laoQk",sizeLarge:"ImageThumbnail-module__sizeLarge___iwz3o",removeButton:"ImageThumbnail-module__removeButton___Ceh1Q"},bn={xs:pe.sizeXs,small:pe.sizeSmall,default:pe.sizeDefault,large:pe.sizeLarge},Sn=({color:e})=>d.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"none",stroke:e,strokeWidth:"1.5",width:"40%",height:"40%","aria-hidden":!0,children:[d.jsx("rect",{x:"3",y:"3",width:"18",height:"18",rx:"2"}),d.jsx("circle",{cx:"8.5",cy:"8.5",r:"1.5"}),d.jsx("polyline",{points:"21 15 16 10 5 21"})]}),kn=({src:e,alt:r="",size:t="default",loading:o=!1,skeletonDelay:n=500,onRemove:s,removeLabel:a="Remove",fallback:l,className:u,style:c,imgProps:f})=>{const m=I(),[h,b]=g.useState(null),[S,_]=g.useState(null),[k,V]=g.useState(null),v=h===e,z=S===e,E=k===e;g.useEffect(()=>{if(!e)return;const G=setTimeout(()=>V(e),n);return()=>clearTimeout(G)},[e,n]);const F=o||!!e&&!v&&!z&&E,N=!o&&(!e||z),P=!o&&!!e&&!z,O=[pe.thumbnail,bn[t],u].filter(Boolean).join(" "),A={borderRadius:m.border.radius,...c},H={background:m.colors.primary,color:m.buttons.primary.textColor,borderRadius:"50%"};return d.jsxs("div",{className:O,style:A,"aria-label":N?r||"Image placeholder":void 0,"aria-busy":F||void 0,children:[F&&d.jsx(pt,{style:{borderRadius:"inherit",position:"absolute",inset:0}}),N&&(l??d.jsx(Sn,{color:m.colors.primary})),P&&d.jsx("img",{...f,src:e,alt:r,className:pe.img,style:{opacity:v?1:0},onLoad:()=>e&&b(e),onError:()=>e&&_(e)}),s&&d.jsx("button",{type:"button",className:pe.removeButton,style:H,onClick:G=>{G.stopPropagation(),s()},"aria-label":a,children:d.jsxs("svg",{viewBox:"0 0 10 10",width:"60%",height:"60%",fill:"none",stroke:"currentColor",strokeWidth:m.fonts.fontWeightHeader>=700?2:1.5,"aria-hidden":!0,children:[d.jsx("line",{x1:"2",y1:"2",x2:"8",y2:"8"}),d.jsx("line",{x1:"8",y1:"2",x2:"2",y2:"8"})]})})]})},Cn=({level:e,tag:r,className:t,style:o,children:n})=>{const s=I(),a=r??`h${e}`,l=s.typography.heading[a],c=`dr-heading-${g.useId().replace(/:/g,"")}`,f=g.useMemo(()=>{const S=[];return l.mdFontSize&&S.push(`@media (max-width: ${s.breakpoints.md}) { .${c} { font-size: ${l.mdFontSize}; } }`),l.smFontSize&&S.push(`@media (max-width: ${s.breakpoints.sm}) { .${c} { font-size: ${l.smFontSize}; } }`),S.join(`
39
+ `)},[c,l.mdFontSize,l.smFontSize,s.breakpoints.md,s.breakpoints.sm]),m={fontSize:l.fontSize,...l.lineHeight!==void 0&&{lineHeight:l.lineHeight},...l.fontWeight!==void 0&&{fontWeight:l.fontWeight},...o},h=[c,t].filter(Boolean).join(" "),b=`h${e}`;return d.jsxs(d.Fragment,{children:[f&&d.jsx("style",{children:f}),g.createElement(b,{className:h,style:m},n)]})},wn=({size:e="default",as:r="p",className:t,style:o,children:n})=>{const a=I().typography.text[e],l={fontSize:a.fontSize,...a.lineHeight!==void 0&&{lineHeight:a.lineHeight},...o};return g.createElement(r,{className:t,style:l},n)},xn=({variant:e="default",className:r,style:t,children:o})=>{const n=I();let s,a,l;switch(e){case"caption":s=n.typography.text.xs.fontSize,l=700;break;case"subtle":s=n.typography.text.sm.fontSize,a=.7;break;case"default":default:s=n.typography.text.sm.fontSize,l=700;break}const u={fontSize:s,...a!==void 0&&{opacity:a},...l!==void 0&&{fontWeight:l},...t};return d.jsx("span",{className:r,style:u,children:o})};function Fn({steps:e,currentStep:r,color:t,textColor:o,errors:n=[],onStepClick:s,maxStep:a,style:l,className:u}){var z;const c=I(),f=t||c.colors.primary,m=o||(((z=c.buttons.primary)==null?void 0:z.textColor)??c.buttons.textColor),h=c.colors.error,b="#ccc",S="#999",_=!!s,k=E=>_&&(a===void 0||E<=a),V=e.map((E,F)=>F<e.length-1?"3em 1fr":"3em").join(" "),v=`${e.length*3+(e.length-1)*4}em`;return d.jsxs("div",{className:u,style:{display:"grid",gridTemplateColumns:V,rowGap:"0.3em",maxWidth:v,...l},children:[e.map((E,F)=>{const N=F+1,P=n.includes(N),O=N===r&&!P,A=N<r&&!P,H=P?h:O||A?f:"transparent",G=P?h:O||A?f:b,B=P||O||A?m:b,D=A?f:b;return d.jsxs(g.Fragment,{children:[d.jsx("div",{role:k(N)?"button":void 0,tabIndex:k(N)?0:void 0,onClick:k(N)?()=>s(N):void 0,onKeyDown:k(N)?T=>{(T.key==="Enter"||T.key===" ")&&s(N)}:void 0,style:{display:"flex",justifyContent:"center",alignItems:"center",cursor:k(N)?"pointer":"default"},children:d.jsx("div",{style:{width:"1.3em",height:"1.3em",borderRadius:"50%",backgroundColor:H,border:`2px solid ${G}`,display:"flex",alignItems:"center",justifyContent:"center",flexShrink:0,boxSizing:"border-box"},children:d.jsx("span",{style:{fontSize:"0.6em",fontWeight:700,lineHeight:1,color:B,userSelect:"none"},children:P?"!":A?"✓":N})})}),F<e.length-1&&d.jsx("div",{style:{height:"2px",backgroundColor:D,alignSelf:"center",marginLeft:"0.25em",marginRight:"0.25em"}})]},`c-${F}`)}),e.map((E,F)=>{const N=F+1,P=n.includes(N),O=N===r&&!P;return d.jsxs(g.Fragment,{children:[d.jsx("div",{role:k(N)?"button":void 0,tabIndex:k(N)?0:void 0,onClick:k(N)?()=>s(N):void 0,onKeyDown:k(N)?A=>{(A.key==="Enter"||A.key===" ")&&s(N)}:void 0,style:{display:"flex",justifyContent:"center",cursor:k(N)?"pointer":"default"},children:d.jsx("span",{style:{fontSize:"0.7em",color:P?h:O?f:S,fontWeight:P||O?600:400,whiteSpace:"nowrap"},children:E})}),F<e.length-1&&d.jsx("div",{})]},`l-${F}`)})]})}const Lr={triggerWrapper:"Tooltip-module__triggerWrapper___wMSun",tooltip:"Tooltip-module__tooltip___UA7H9"},zn=({children:e,content:r,placement:t="top",openDelay:o=200,closeDelay:n=100,offset:s=8,disabled:a=!1,color:l,backgroundColor:u,className:c,style:f,tooltipProps:m})=>{const h=I(),b=g.useRef(null),S=g.useRef(null),_=g.useRef(null),[k,V]=g.useState(!1),v=g.useId(),z=k&&!a&&!!r,{side:E,align:F}=vr(t),{positionStyle:N}=br({open:z,triggerRef:b,side:E,align:F,offset:s}),P=()=>{S.current&&clearTimeout(S.current),_.current&&clearTimeout(_.current),S.current=null,_.current=null},O=g.useCallback(()=>{P(),S.current=setTimeout(()=>V(!0),o)},[o]),A=g.useCallback(()=>{P(),_.current=setTimeout(()=>V(!1),n)},[n]),H={backgroundColor:u||h.colors.secondaryBackground,color:l,borderRadius:h.border.radius,...N,...f};return d.jsxs(d.Fragment,{children:[d.jsx("span",{ref:b,className:Lr.triggerWrapper,onMouseEnter:O,onMouseLeave:A,onFocus:O,onBlur:A,"aria-describedby":z?v:void 0,children:e}),z&&Le.createPortal(d.jsx("div",{id:v,role:"tooltip",className:[Lr.tooltip,c].filter(Boolean).join(" "),style:H,...m,children:r}),document.body)]})};L.Button=xt,L.CSSReset=Qr,L.Card=xr,L.Checkbox=Pe,L.Collapsible=on,L.FeatureCard=dn,L.FeatureGrid=mn,L.FileUpload=pn,L.Footer=$r,L.Form=Vo,L.FormCheckbox=Po,L.FormCheckboxGroup=To,L.FormError=dr,L.FormField=me,L.FormGroup=ur,L.FormInput=Lo,L.FormLabel=Ae,L.FormRadio=Oo,L.FormRadioGroup=Io,L.FormSelect=Ao,L.FormTextarea=Bo,L.Hamburger=gr,L.Header=_r,L.Heading=Cn,L.Hero=an,L.Image=vn,L.ImageThumbnail=kn,L.Input=fr,L.Label=xn,L.LoadingSpinner=mt,L.MediaCard=hn,L.Modal=Cr,L.ModalProvider=en,L.NavDropdown=Jo,L.NavLink=Yo,L.PageLayout=yn,L.Popover=dt,L.Radio=ct,L.ResponsiveNav=Xo,L.ResponsiveNavContext=Sr,L.ResponsiveSection=zr,L.Select=hr,L.Skeleton=pt,L.Stack=kr,L.Stepper=Fn,L.StyleLoader=Ro,L.Text=wn,L.Textarea=mr,L.ThemeProvider=Hr,L.Tooltip=zn,L.parseBreakpoint=ve,L.useFormContext=cr,L.useMediaQuery=oe,L.useModal=tn,L.useNavLinkStyles=ft,L.useTheme=I,Object.defineProperty(L,Symbol.toStringTag,{value:"Module"})}));
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "digital-rabbit-cl",
3
- "version": "3.3.11",
3
+ "version": "3.3.12",
4
4
  "dependencies": {
5
5
  "@hookform/resolvers": "^5.2.2",
6
6
  "react-hook-form": "^7.66.0",