digital-rabbit-cl 2.4.8 → 2.4.10
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/components/FeatureGridSection/FeatureGridSection.d.ts.map +1 -1
- package/dist/components/MediaCard/MediaCard.d.ts +17 -0
- package/dist/components/MediaCard/MediaCard.d.ts.map +1 -0
- package/dist/components/MediaCard/index.d.ts +2 -0
- package/dist/components/MediaCard/index.d.ts.map +1 -0
- package/dist/digital-rabbit-cl.es.js +814 -767
- package/dist/digital-rabbit-cl.umd.js +4 -4
- package/dist/index.d.ts +2 -0
- package/dist/index.d.ts.map +1 -1
- package/package.json +1 -1
|
@@ -1,12 +1,12 @@
|
|
|
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{padding:var(--button-padding-small)}.Button-module__sizeLarge___yeZSH{padding:var(--button-padding-large)}.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:.25em;-webkit-user-select:none;user-select:none}.FormLabel-module__label___0M-fo{display:inline-block;font-weight:700;padding-bottom:var(--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;--line-height: 1.5;--font-weight-header: 700;--primary-color: #000;--background-color: #fff;--accent-color: #0066cc;--font-size-h1: 2.5rem;--font-size-h2: 1.75rem;--font-size-h3: 1.38316rem;--font-size-h4: 1rem;--font-size-h5: .85028rem;--font-size-h6: .78405rem;--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}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:var(--font-size);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}h1{font-size:var(--font-size-h1)}h2{font-size:var(--font-size-h2)}h3{font-size:var(--font-size-h3)}h4{font-size:var(--font-size-h4)}h5{font-size:var(--font-size-h5)}h6{font-size:var(--font-size-h6)}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;text-decoration:none}a:link{color:var(--accent-color)}a:hover{text-decoration:underline}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{padding:var(--input-padding-small)}.Input-module__sizeLarge___4Boj3{padding:var(--input-padding-large)}.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{padding:var(--textarea-padding-small)}.Textarea-module__sizeLarge___5a3sf{padding:var(--textarea-padding-large)}.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{padding:var(--select-padding-small)}.Select-module__sizeLarge___eBA1T{padding:var(--select-padding-large)}.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:.25em;-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))}.FeatureGridSection-module__section___wZrbC{padding:var(--section-padding-vertical) 0}.FeatureGridSection-module__grid___iwPJv{display:grid;gap:2rem;grid-template-columns:var(--grid-template-columns, 1fr)}.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}')),document.head.appendChild(e)}}catch(o){console.error("vite-plugin-css-injected-by-js",o)}})();
|
|
2
|
-
import { jsx as p, jsxs as
|
|
3
|
-
import N, { createContext as
|
|
4
|
-
import { createPortal as
|
|
5
|
-
const Ur = "Button-module__button___2ZuB7",
|
|
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{padding:var(--button-padding-small)}.Button-module__sizeLarge___yeZSH{padding:var(--button-padding-large)}.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:.25em;-webkit-user-select:none;user-select:none}.FormLabel-module__label___0M-fo{display:inline-block;font-weight:700;padding-bottom:var(--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;--line-height: 1.5;--font-weight-header: 700;--primary-color: #000;--background-color: #fff;--accent-color: #0066cc;--font-size-h1: 2.5rem;--font-size-h2: 1.75rem;--font-size-h3: 1.38316rem;--font-size-h4: 1rem;--font-size-h5: .85028rem;--font-size-h6: .78405rem;--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}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:var(--font-size);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}h1{font-size:var(--font-size-h1)}h2{font-size:var(--font-size-h2)}h3{font-size:var(--font-size-h3)}h4{font-size:var(--font-size-h4)}h5{font-size:var(--font-size-h5)}h6{font-size:var(--font-size-h6)}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;text-decoration:none}a:link{color:var(--accent-color)}a:hover{text-decoration:underline}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{padding:var(--input-padding-small)}.Input-module__sizeLarge___4Boj3{padding:var(--input-padding-large)}.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{padding:var(--textarea-padding-small)}.Textarea-module__sizeLarge___5a3sf{padding:var(--textarea-padding-large)}.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{padding:var(--select-padding-small)}.Select-module__sizeLarge___eBA1T{padding:var(--select-padding-large)}.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:.25em;-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))}.FeatureGridSection-module__grid___iwPJv{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}')),document.head.appendChild(e)}}catch(o){console.error("vite-plugin-css-injected-by-js",o)}})();
|
|
2
|
+
import { jsx as p, jsxs as D, Fragment as Fe } from "react/jsx-runtime";
|
|
3
|
+
import N, { createContext as ht, useContext as or, useState as J, useLayoutEffect as jr, useSyncExternalStore as Wr, useEffect as ne, useCallback as Ce, useRef as Ve, useMemo as We } from "react";
|
|
4
|
+
import { createPortal as lt } from "react-dom";
|
|
5
|
+
const Ur = "Button-module__button___2ZuB7", qr = "Button-module__sizeSmall___DRT8P", Gr = "Button-module__sizeLarge___yeZSH", Be = {
|
|
6
6
|
button: Ur,
|
|
7
|
-
sizeSmall:
|
|
8
|
-
sizeLarge:
|
|
9
|
-
},
|
|
7
|
+
sizeSmall: qr,
|
|
8
|
+
sizeLarge: Gr
|
|
9
|
+
}, Zr = ({
|
|
10
10
|
isActive: e,
|
|
11
11
|
disabled: r,
|
|
12
12
|
color: t,
|
|
@@ -26,20 +26,20 @@ const Ur = "Button-module__button___2ZuB7", Wr = "Button-module__sizeSmall___DRT
|
|
|
26
26
|
opacity: m
|
|
27
27
|
};
|
|
28
28
|
};
|
|
29
|
-
function
|
|
29
|
+
function sr(e, r) {
|
|
30
30
|
const t = { ...e };
|
|
31
|
-
return
|
|
31
|
+
return De(e) && De(r) && Object.keys(r).forEach((o) => {
|
|
32
32
|
const s = r[o], n = e[o];
|
|
33
|
-
|
|
33
|
+
De(s) && De(n) ? t[o] = sr(
|
|
34
34
|
n,
|
|
35
35
|
s
|
|
36
36
|
) : s !== void 0 && (t[o] = s);
|
|
37
37
|
}), t;
|
|
38
38
|
}
|
|
39
|
-
function
|
|
39
|
+
function De(e) {
|
|
40
40
|
return e && typeof e == "object" && !Array.isArray(e);
|
|
41
41
|
}
|
|
42
|
-
function
|
|
42
|
+
function Le(e) {
|
|
43
43
|
const r = e.match(/^(\d+(?:\.\d+)?)(px|em|rem)$/);
|
|
44
44
|
if (!r) {
|
|
45
45
|
const s = parseInt(e, 10), n = e.replace(/[0-9.]/g, "") || "px";
|
|
@@ -54,15 +54,15 @@ function $e(e) {
|
|
|
54
54
|
unit: o
|
|
55
55
|
};
|
|
56
56
|
}
|
|
57
|
-
const
|
|
57
|
+
const Xe = {
|
|
58
58
|
primary: "#000",
|
|
59
59
|
secondary: "#FFF",
|
|
60
60
|
accent: "#4381C1",
|
|
61
61
|
error: "#F00",
|
|
62
62
|
success: "#008000",
|
|
63
63
|
warning: "#FFEB3B"
|
|
64
|
-
},
|
|
65
|
-
colors:
|
|
64
|
+
}, ct = {
|
|
65
|
+
colors: Xe,
|
|
66
66
|
fonts: {
|
|
67
67
|
color: "#000",
|
|
68
68
|
lineHeight: 1.5,
|
|
@@ -81,7 +81,7 @@ const Ke = {
|
|
|
81
81
|
textColor: "#FFF",
|
|
82
82
|
paddingHorizontal: 0.35,
|
|
83
83
|
primary: {
|
|
84
|
-
textColor:
|
|
84
|
+
textColor: Xe.secondary
|
|
85
85
|
}
|
|
86
86
|
},
|
|
87
87
|
inputs: {
|
|
@@ -111,14 +111,14 @@ const Ke = {
|
|
|
111
111
|
padding: "1rem"
|
|
112
112
|
},
|
|
113
113
|
modal: {
|
|
114
|
-
backgroundColor:
|
|
114
|
+
backgroundColor: Xe.secondary,
|
|
115
115
|
backdropColor: "rgba(0, 0, 0, 0.5)",
|
|
116
116
|
boxShadow: "0 10px 40px rgba(0, 0, 0, 0.2)"
|
|
117
117
|
}
|
|
118
|
-
},
|
|
119
|
-
const t = e ?
|
|
120
|
-
return /* @__PURE__ */ p(
|
|
121
|
-
},
|
|
118
|
+
}, nr = ht(ct), ia = ({ theme: e, children: r }) => {
|
|
119
|
+
const t = e ? sr(ct, e) : ct;
|
|
120
|
+
return /* @__PURE__ */ p(nr.Provider, { value: t, children: r });
|
|
121
|
+
}, R = () => or(nr), Kr = ({
|
|
122
122
|
// Core styling
|
|
123
123
|
color: e,
|
|
124
124
|
hoverColor: r,
|
|
@@ -135,8 +135,8 @@ const Ke = {
|
|
|
135
135
|
onClick: u,
|
|
136
136
|
children: y
|
|
137
137
|
}) => {
|
|
138
|
-
const m =
|
|
139
|
-
...
|
|
138
|
+
const m = R(), [C, b] = J(!1), k = {
|
|
139
|
+
...Zr({
|
|
140
140
|
isActive: C,
|
|
141
141
|
disabled: o,
|
|
142
142
|
color: e,
|
|
@@ -173,33 +173,33 @@ const Ke = {
|
|
|
173
173
|
}
|
|
174
174
|
);
|
|
175
175
|
};
|
|
176
|
-
var
|
|
177
|
-
function
|
|
178
|
-
if (!
|
|
176
|
+
var Mt = typeof crypto < "u" && crypto.getRandomValues && crypto.getRandomValues.bind(crypto) || typeof msCrypto < "u" && typeof msCrypto.getRandomValues == "function" && msCrypto.getRandomValues.bind(msCrypto), Qr = new Uint8Array(16);
|
|
177
|
+
function Xr() {
|
|
178
|
+
if (!Mt)
|
|
179
179
|
throw new Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");
|
|
180
|
-
return
|
|
180
|
+
return Mt(Qr);
|
|
181
181
|
}
|
|
182
|
-
var
|
|
182
|
+
var ar = [];
|
|
183
183
|
for (var Re = 0; Re < 256; ++Re)
|
|
184
|
-
|
|
185
|
-
function
|
|
186
|
-
var t = 0, o =
|
|
184
|
+
ar[Re] = (Re + 256).toString(16).substr(1);
|
|
185
|
+
function Jr(e, r) {
|
|
186
|
+
var t = 0, o = ar;
|
|
187
187
|
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("");
|
|
188
188
|
}
|
|
189
|
-
function
|
|
189
|
+
function ir(e, r, t) {
|
|
190
190
|
var o = r && t || 0;
|
|
191
191
|
typeof e == "string" && (r = e === "binary" ? new Array(16) : null, e = null), e = e || {};
|
|
192
|
-
var s = e.random || (e.rng ||
|
|
192
|
+
var s = e.random || (e.rng || Xr)();
|
|
193
193
|
if (s[6] = s[6] & 15 | 64, s[8] = s[8] & 63 | 128, r)
|
|
194
194
|
for (var n = 0; n < 16; ++n)
|
|
195
195
|
r[o + n] = s[n];
|
|
196
|
-
return r ||
|
|
196
|
+
return r || Jr(s);
|
|
197
197
|
}
|
|
198
|
-
const
|
|
199
|
-
container:
|
|
200
|
-
svg:
|
|
201
|
-
label:
|
|
202
|
-
},
|
|
198
|
+
const Yr = "Checkbox-module__container___aV9qz", eo = "Checkbox-module__svg___kkluC", to = "Checkbox-module__label___cwRtI", Je = {
|
|
199
|
+
container: Yr,
|
|
200
|
+
svg: eo,
|
|
201
|
+
label: to
|
|
202
|
+
}, ro = ({
|
|
203
203
|
color: e = "#000",
|
|
204
204
|
checkmarkColor: r,
|
|
205
205
|
disabled: t = !1,
|
|
@@ -212,10 +212,10 @@ const Jr = "Checkbox-module__container___aV9qz", Yr = "Checkbox-module__svg___kk
|
|
|
212
212
|
cursor: t ? "default" : "pointer",
|
|
213
213
|
opacity: t ? 0.3 : 1
|
|
214
214
|
};
|
|
215
|
-
},
|
|
216
|
-
label:
|
|
217
|
-
disabled:
|
|
218
|
-
},
|
|
215
|
+
}, oo = "FormLabel-module__label___0M-fo", so = "FormLabel-module__disabled___ktIFp", Bt = {
|
|
216
|
+
label: oo,
|
|
217
|
+
disabled: so
|
|
218
|
+
}, no = ({
|
|
219
219
|
color: e = "#000",
|
|
220
220
|
disabled: r = !1,
|
|
221
221
|
fontSize: t = ".85em"
|
|
@@ -224,7 +224,7 @@ const Jr = "Checkbox-module__container___aV9qz", Yr = "Checkbox-module__svg___kk
|
|
|
224
224
|
fontSize: t,
|
|
225
225
|
opacity: r ? 0.5 : 1,
|
|
226
226
|
cursor: r ? "not-allowed" : "default"
|
|
227
|
-
}),
|
|
227
|
+
}), _t = ({
|
|
228
228
|
// Color prop
|
|
229
229
|
color: e,
|
|
230
230
|
// State props
|
|
@@ -240,7 +240,7 @@ const Jr = "Checkbox-module__container___aV9qz", Yr = "Checkbox-module__svg___kk
|
|
|
240
240
|
// Element-specific props
|
|
241
241
|
labelProps: i
|
|
242
242
|
}) => {
|
|
243
|
-
const f =
|
|
243
|
+
const f = R(), c = f.colors.error, u = t ? c : e || f.colors.primary, y = no({
|
|
244
244
|
color: u,
|
|
245
245
|
disabled: r,
|
|
246
246
|
fontSize: ".85em"
|
|
@@ -254,7 +254,7 @@ const Jr = "Checkbox-module__container___aV9qz", Yr = "Checkbox-module__svg___kk
|
|
|
254
254
|
// Top level style prop overrides
|
|
255
255
|
}, C = [Bt.label, r ? Bt.disabled : "", n].filter(Boolean).join(" ");
|
|
256
256
|
return /* @__PURE__ */ p("label", { ...i, className: C, htmlFor: o, style: m, children: s });
|
|
257
|
-
},
|
|
257
|
+
}, ut = ({
|
|
258
258
|
// Color props
|
|
259
259
|
color: e,
|
|
260
260
|
checkmarkColor: r,
|
|
@@ -275,7 +275,7 @@ const Jr = "Checkbox-module__container___aV9qz", Yr = "Checkbox-module__svg___kk
|
|
|
275
275
|
// Element-specific props
|
|
276
276
|
divProps: C
|
|
277
277
|
}) => {
|
|
278
|
-
const b =
|
|
278
|
+
const b = R(), _ = i || ir(), k = b.colors.error, V = n ? k : e || b.colors.primary, g = ro({
|
|
279
279
|
color: V,
|
|
280
280
|
checkmarkColor: r,
|
|
281
281
|
disabled: s,
|
|
@@ -290,16 +290,16 @@ const Jr = "Checkbox-module__container___aV9qz", Yr = "Checkbox-module__svg___kk
|
|
|
290
290
|
// Top-level style prop overrides
|
|
291
291
|
}, E = {
|
|
292
292
|
width: "1em"
|
|
293
|
-
},
|
|
293
|
+
}, B = {
|
|
294
294
|
fill: o && t ? g.checkboxColor : "transparent",
|
|
295
295
|
strokeWidth: "25",
|
|
296
296
|
stroke: g.checkboxColor
|
|
297
|
-
},
|
|
297
|
+
}, M = {
|
|
298
298
|
stroke: g.checkmarkColor,
|
|
299
299
|
strokeWidth: "15",
|
|
300
300
|
fill: "transparent"
|
|
301
|
-
},
|
|
302
|
-
return /* @__PURE__ */
|
|
301
|
+
}, U = [Je.container, y].filter(Boolean).join(" ");
|
|
302
|
+
return /* @__PURE__ */ D("div", { ...C, className: U, style: z, children: [
|
|
303
303
|
/* @__PURE__ */ p(
|
|
304
304
|
"input",
|
|
305
305
|
{
|
|
@@ -312,25 +312,25 @@ const Jr = "Checkbox-module__container___aV9qz", Yr = "Checkbox-module__svg___kk
|
|
|
312
312
|
type: "checkbox"
|
|
313
313
|
}
|
|
314
314
|
),
|
|
315
|
-
/* @__PURE__ */
|
|
315
|
+
/* @__PURE__ */ D(
|
|
316
316
|
"svg",
|
|
317
317
|
{
|
|
318
318
|
xmlns: "http://www.w3.org/2000/svg",
|
|
319
319
|
viewBox: "0 0 100 100",
|
|
320
320
|
onClick: () => F({ target: { checked: !t, name: a, type: "checkbox" } }),
|
|
321
321
|
style: E,
|
|
322
|
-
className:
|
|
322
|
+
className: Je.svg,
|
|
323
323
|
children: [
|
|
324
|
-
/* @__PURE__ */ p("rect", { x: "0", y: "0", height: "100", width: "100", style:
|
|
325
|
-
t && /* @__PURE__ */ p("path", { d: "M 25 45 L 45 65 L 75 30", style:
|
|
324
|
+
/* @__PURE__ */ p("rect", { x: "0", y: "0", height: "100", width: "100", style: B }),
|
|
325
|
+
t && /* @__PURE__ */ p("path", { d: "M 25 45 L 45 65 L 75 30", style: M })
|
|
326
326
|
]
|
|
327
327
|
}
|
|
328
328
|
),
|
|
329
329
|
c && /* @__PURE__ */ p(
|
|
330
|
-
|
|
330
|
+
_t,
|
|
331
331
|
{
|
|
332
332
|
htmlFor: _,
|
|
333
|
-
className:
|
|
333
|
+
className: Je.label,
|
|
334
334
|
style: { paddingBottom: 0, ...u },
|
|
335
335
|
color: g.checkboxColor,
|
|
336
336
|
disabled: s,
|
|
@@ -339,26 +339,26 @@ const Jr = "Checkbox-module__container___aV9qz", Yr = "Checkbox-module__svg___kk
|
|
|
339
339
|
}
|
|
340
340
|
)
|
|
341
341
|
] });
|
|
342
|
-
},
|
|
343
|
-
const e =
|
|
344
|
-
return
|
|
342
|
+
}, la = () => {
|
|
343
|
+
const e = R();
|
|
344
|
+
return jr(() => {
|
|
345
345
|
const r = document.documentElement;
|
|
346
346
|
e.fonts && (e.fonts.fontFamily && r.style.setProperty("--font-family", e.fonts.fontFamily), e.fonts.size && r.style.setProperty("--font-size", e.fonts.size), e.fonts.lineHeight !== void 0 && r.style.setProperty("--line-height", e.fonts.lineHeight.toString()), e.fonts.fontWeightHeader !== void 0 && r.style.setProperty("--font-weight-header", e.fonts.fontWeightHeader.toString()), e.fonts.fontSizeH1 && r.style.setProperty("--font-size-h1", e.fonts.fontSizeH1), e.fonts.fontSizeH2 && r.style.setProperty("--font-size-h2", e.fonts.fontSizeH2), e.fonts.fontSizeH3 && r.style.setProperty("--font-size-h3", e.fonts.fontSizeH3), e.fonts.fontSizeH4 && r.style.setProperty("--font-size-h4", e.fonts.fontSizeH4), e.fonts.fontSizeH5 && r.style.setProperty("--font-size-h5", e.fonts.fontSizeH5), e.fonts.fontSizeH6 && r.style.setProperty("--font-size-h6", e.fonts.fontSizeH6)), e.colors && (e.colors.primary && r.style.setProperty("--primary-color", e.colors.primary), e.colors.secondary && r.style.setProperty("--background-color", e.colors.secondary), e.colors.accent && r.style.setProperty("--accent-color", e.colors.accent)), e.breakpoints && (e.breakpoints.xs && r.style.setProperty("--breakpoint-xs", e.breakpoints.xs), e.breakpoints.sm && r.style.setProperty("--breakpoint-sm", e.breakpoints.sm), e.breakpoints.md && r.style.setProperty("--breakpoint-md", e.breakpoints.md), e.breakpoints.lg && r.style.setProperty("--breakpoint-lg", e.breakpoints.lg)), e.layout && (e.layout.maxWidth && r.style.setProperty("--layout-max-width", e.layout.maxWidth), e.layout.paddingSm && r.style.setProperty("--layout-wrapper-padding-sm", e.layout.paddingSm), e.layout.padding && r.style.setProperty("--layout-wrapper-padding", e.layout.padding));
|
|
347
347
|
}, [e]), null;
|
|
348
348
|
};
|
|
349
|
-
var
|
|
350
|
-
const
|
|
351
|
-
var Z = (e) => !ee(e) && !Array.isArray(e) &&
|
|
349
|
+
var Ae = (e) => e.type === "checkbox", _e = (e) => e instanceof Date, ee = (e) => e == null;
|
|
350
|
+
const lr = (e) => typeof e == "object";
|
|
351
|
+
var Z = (e) => !ee(e) && !Array.isArray(e) && lr(e) && !_e(e), cr = (e) => Z(e) && e.target ? Ae(e.target) ? e.target.checked : e.target.value : e, ao = (e) => e.substring(0, e.search(/\.\d+(\.|$)/)) || e, ur = (e, r) => e.has(ao(r)), io = (e) => {
|
|
352
352
|
const r = e.constructor && e.constructor.prototype;
|
|
353
353
|
return Z(r) && r.hasOwnProperty("isPrototypeOf");
|
|
354
|
-
},
|
|
354
|
+
}, pt = typeof window < "u" && typeof window.HTMLElement < "u" && typeof document < "u";
|
|
355
355
|
function X(e) {
|
|
356
356
|
let r;
|
|
357
357
|
const t = Array.isArray(e), o = typeof FileList < "u" ? e instanceof FileList : !1;
|
|
358
358
|
if (e instanceof Date)
|
|
359
359
|
r = new Date(e);
|
|
360
|
-
else if (!(
|
|
361
|
-
if (r = t ? [] : Object.create(Object.getPrototypeOf(e)), !t && !
|
|
360
|
+
else if (!(pt && (e instanceof Blob || o)) && (t || Z(e)))
|
|
361
|
+
if (r = t ? [] : Object.create(Object.getPrototypeOf(e)), !t && !io(e))
|
|
362
362
|
r = e;
|
|
363
363
|
else
|
|
364
364
|
for (const s in e)
|
|
@@ -367,14 +367,14 @@ function X(e) {
|
|
|
367
367
|
return e;
|
|
368
368
|
return r;
|
|
369
369
|
}
|
|
370
|
-
var Ue = (e) => /^\w*$/.test(e),
|
|
370
|
+
var Ue = (e) => /^\w*$/.test(e), W = (e) => e === void 0, gt = (e) => Array.isArray(e) ? e.filter(Boolean) : [], vt = (e) => gt(e.replace(/["|']|\]/g, "").split(/\.|\[/)), w = (e, r, t) => {
|
|
371
371
|
if (!r || !Z(e))
|
|
372
372
|
return t;
|
|
373
|
-
const o = (Ue(r) ? [r] :
|
|
374
|
-
return
|
|
375
|
-
}, re = (e) => typeof e == "boolean",
|
|
373
|
+
const o = (Ue(r) ? [r] : vt(r)).reduce((s, n) => ee(s) ? s : s[n], e);
|
|
374
|
+
return W(o) || o === e ? W(e[r]) ? t : e[r] : o;
|
|
375
|
+
}, re = (e) => typeof e == "boolean", H = (e, r, t) => {
|
|
376
376
|
let o = -1;
|
|
377
|
-
const s = Ue(r) ? [r] :
|
|
377
|
+
const s = Ue(r) ? [r] : vt(r), n = s.length, a = n - 1;
|
|
378
378
|
for (; ++o < n; ) {
|
|
379
379
|
const i = s[o];
|
|
380
380
|
let f = t;
|
|
@@ -387,7 +387,7 @@ var Ue = (e) => /^\w*$/.test(e), U = (e) => e === void 0, pt = (e) => Array.isAr
|
|
|
387
387
|
e[i] = f, e = e[i];
|
|
388
388
|
}
|
|
389
389
|
};
|
|
390
|
-
const
|
|
390
|
+
const Te = {
|
|
391
391
|
BLUR: "blur",
|
|
392
392
|
FOCUS_OUT: "focusout",
|
|
393
393
|
CHANGE: "change"
|
|
@@ -405,10 +405,10 @@ const Ie = {
|
|
|
405
405
|
pattern: "pattern",
|
|
406
406
|
required: "required",
|
|
407
407
|
validate: "validate"
|
|
408
|
-
},
|
|
409
|
-
|
|
410
|
-
const
|
|
411
|
-
var
|
|
408
|
+
}, dr = N.createContext(null);
|
|
409
|
+
dr.displayName = "HookFormContext";
|
|
410
|
+
const bt = () => N.useContext(dr);
|
|
411
|
+
var fr = (e, r, t, o = !0) => {
|
|
412
412
|
const s = {
|
|
413
413
|
defaultValues: r._defaultValues
|
|
414
414
|
};
|
|
@@ -421,9 +421,9 @@ var dr = (e, r, t, o = !0) => {
|
|
|
421
421
|
});
|
|
422
422
|
return s;
|
|
423
423
|
};
|
|
424
|
-
const
|
|
425
|
-
function
|
|
426
|
-
const r =
|
|
424
|
+
const St = typeof window < "u" ? N.useLayoutEffect : N.useEffect;
|
|
425
|
+
function lo(e) {
|
|
426
|
+
const r = bt(), { control: t = r.control, disabled: o, name: s, exact: n } = e || {}, [a, i] = N.useState(t._formState), f = N.useRef({
|
|
427
427
|
isDirty: !1,
|
|
428
428
|
isLoading: !1,
|
|
429
429
|
dirtyFields: !1,
|
|
@@ -433,7 +433,7 @@ function io(e) {
|
|
|
433
433
|
isValid: !1,
|
|
434
434
|
errors: !1
|
|
435
435
|
});
|
|
436
|
-
return
|
|
436
|
+
return St(() => t._subscribe({
|
|
437
437
|
name: s,
|
|
438
438
|
formState: f.current,
|
|
439
439
|
exact: n,
|
|
@@ -445,11 +445,11 @@ function io(e) {
|
|
|
445
445
|
}
|
|
446
446
|
}), [s, o, n]), N.useEffect(() => {
|
|
447
447
|
f.current.isValid && t._setValid(!0);
|
|
448
|
-
}, [t]), N.useMemo(() =>
|
|
448
|
+
}, [t]), N.useMemo(() => fr(a, t, f.current, !1), [a, t]);
|
|
449
449
|
}
|
|
450
|
-
var oe = (e) => typeof e == "string",
|
|
450
|
+
var oe = (e) => typeof e == "string", dt = (e, r, t, o, s) => oe(e) ? (o && r.watch.add(e), w(t, e, s)) : Array.isArray(e) ? e.map((n) => (o && r.watch.add(n), w(t, n))) : (o && (r.watchAll = !0), t), ft = (e) => ee(e) || !lr(e);
|
|
451
451
|
function le(e, r, t = /* @__PURE__ */ new WeakSet()) {
|
|
452
|
-
if (
|
|
452
|
+
if (ft(e) || ft(r))
|
|
453
453
|
return e === r;
|
|
454
454
|
if (_e(e) && _e(r))
|
|
455
455
|
return e.getTime() === r.getTime();
|
|
@@ -471,26 +471,26 @@ function le(e, r, t = /* @__PURE__ */ new WeakSet()) {
|
|
|
471
471
|
}
|
|
472
472
|
return !0;
|
|
473
473
|
}
|
|
474
|
-
function
|
|
475
|
-
const r =
|
|
474
|
+
function co(e) {
|
|
475
|
+
const r = bt(), { control: t = r.control, name: o, defaultValue: s, disabled: n, exact: a, compute: i } = e || {}, f = N.useRef(s), c = N.useRef(i), u = N.useRef(void 0), y = N.useRef(t), m = N.useRef(o);
|
|
476
476
|
c.current = i;
|
|
477
477
|
const [C, b] = N.useState(() => {
|
|
478
478
|
const z = t._getWatch(o, f.current);
|
|
479
479
|
return c.current ? c.current(z) : z;
|
|
480
480
|
}), _ = N.useCallback((z) => {
|
|
481
|
-
const E =
|
|
481
|
+
const E = dt(o, t._names, z || t._formValues, !1, f.current);
|
|
482
482
|
return c.current ? c.current(E) : E;
|
|
483
483
|
}, [t._formValues, t._names, o]), k = N.useCallback((z) => {
|
|
484
484
|
if (!n) {
|
|
485
|
-
const E =
|
|
485
|
+
const E = dt(o, t._names, z || t._formValues, !1, f.current);
|
|
486
486
|
if (c.current) {
|
|
487
|
-
const
|
|
488
|
-
le(
|
|
487
|
+
const B = c.current(E);
|
|
488
|
+
le(B, u.current) || (b(B), u.current = B);
|
|
489
489
|
} else
|
|
490
490
|
b(E);
|
|
491
491
|
}
|
|
492
492
|
}, [t._formValues, t._names, n, o]);
|
|
493
|
-
|
|
493
|
+
St(() => ((y.current !== t || !le(m.current, o)) && (y.current = t, m.current = o, k()), t._subscribe({
|
|
494
494
|
name: o,
|
|
495
495
|
formState: {
|
|
496
496
|
values: !0
|
|
@@ -508,13 +508,13 @@ function lo(e) {
|
|
|
508
508
|
}, [n, V, o, g, _]);
|
|
509
509
|
return F !== null ? F : C;
|
|
510
510
|
}
|
|
511
|
-
function
|
|
512
|
-
const r =
|
|
511
|
+
function uo(e) {
|
|
512
|
+
const r = bt(), { name: t, disabled: o, control: s = r.control, shouldUnregister: n, defaultValue: a } = e, i = ur(s._names.array, t), f = N.useMemo(() => w(s._formValues, t, w(s._defaultValues, t, a)), [s, t, a]), c = co({
|
|
513
513
|
control: s,
|
|
514
514
|
name: t,
|
|
515
515
|
defaultValue: f,
|
|
516
516
|
exact: !0
|
|
517
|
-
}), u =
|
|
517
|
+
}), u = lo({
|
|
518
518
|
control: s,
|
|
519
519
|
name: t,
|
|
520
520
|
exact: !0
|
|
@@ -547,16 +547,16 @@ function co(e) {
|
|
|
547
547
|
}
|
|
548
548
|
}), [u, t]), _ = N.useCallback((F) => C.current.onChange({
|
|
549
549
|
target: {
|
|
550
|
-
value:
|
|
550
|
+
value: cr(F),
|
|
551
551
|
name: t
|
|
552
552
|
},
|
|
553
|
-
type:
|
|
553
|
+
type: Te.CHANGE
|
|
554
554
|
}), [t]), k = N.useCallback(() => C.current.onBlur({
|
|
555
555
|
target: {
|
|
556
556
|
value: w(s._formValues, t),
|
|
557
557
|
name: t
|
|
558
558
|
},
|
|
559
|
-
type:
|
|
559
|
+
type: Te.BLUR
|
|
560
560
|
}), [t, s._formValues]), V = N.useCallback((F) => {
|
|
561
561
|
const z = w(s._fields, t);
|
|
562
562
|
z && F && (z._f.ref = {
|
|
@@ -579,13 +579,13 @@ function co(e) {
|
|
|
579
579
|
...y.current.rules,
|
|
580
580
|
...re(y.current.disabled) ? { disabled: y.current.disabled } : {}
|
|
581
581
|
});
|
|
582
|
-
const E = (
|
|
583
|
-
const
|
|
584
|
-
|
|
582
|
+
const E = (B, M) => {
|
|
583
|
+
const U = w(s._fields, B);
|
|
584
|
+
U && U._f && (U._f.mount = M);
|
|
585
585
|
};
|
|
586
586
|
if (E(t, !0), F) {
|
|
587
|
-
const
|
|
588
|
-
|
|
587
|
+
const B = X(w(s._options.defaultValues, t, y.current.defaultValue));
|
|
588
|
+
H(s._defaultValues, t, B), W(w(s._formValues, t)) && H(s._formValues, t, B);
|
|
589
589
|
}
|
|
590
590
|
return !i && s.register(t), m.current = t, () => {
|
|
591
591
|
(i ? F && !s._state.action : F) ? s.unregister(t) : E(t, !1);
|
|
@@ -601,13 +601,13 @@ function co(e) {
|
|
|
601
601
|
fieldState: b
|
|
602
602
|
}), [g, u, b]);
|
|
603
603
|
}
|
|
604
|
-
var
|
|
604
|
+
var wt = (e, r, t, o, s) => r ? {
|
|
605
605
|
...t[e],
|
|
606
606
|
types: {
|
|
607
607
|
...t[e] && t[e].types ? t[e].types : {},
|
|
608
608
|
[o]: s || !0
|
|
609
609
|
}
|
|
610
|
-
} : {},
|
|
610
|
+
} : {}, Ne = (e) => Array.isArray(e) ? e : [e], Dt = () => {
|
|
611
611
|
let e = [];
|
|
612
612
|
return {
|
|
613
613
|
get observers() {
|
|
@@ -627,66 +627,66 @@ var St = (e, r, t, o, s) => r ? {
|
|
|
627
627
|
}
|
|
628
628
|
};
|
|
629
629
|
};
|
|
630
|
-
function
|
|
630
|
+
function mr(e, r) {
|
|
631
631
|
const t = {};
|
|
632
632
|
for (const o in e)
|
|
633
633
|
if (e.hasOwnProperty(o)) {
|
|
634
634
|
const s = e[o], n = r[o];
|
|
635
635
|
if (s && Z(s) && n) {
|
|
636
|
-
const a =
|
|
636
|
+
const a = mr(s, n);
|
|
637
637
|
Z(a) && (t[o] = a);
|
|
638
638
|
} else e[o] && (t[o] = n);
|
|
639
639
|
}
|
|
640
640
|
return t;
|
|
641
641
|
}
|
|
642
|
-
var Y = (e) => Z(e) && !Object.keys(e).length,
|
|
643
|
-
if (!
|
|
642
|
+
var Y = (e) => Z(e) && !Object.keys(e).length, kt = (e) => e.type === "file", ce = (e) => typeof e == "function", He = (e) => {
|
|
643
|
+
if (!pt)
|
|
644
644
|
return !1;
|
|
645
645
|
const r = e ? e.ownerDocument : 0;
|
|
646
646
|
return e instanceof (r && r.defaultView ? r.defaultView.HTMLElement : HTMLElement);
|
|
647
|
-
},
|
|
648
|
-
function
|
|
647
|
+
}, yr = (e) => e.type === "select-multiple", xt = (e) => e.type === "radio", fo = (e) => xt(e) || Ae(e), Ye = (e) => He(e) && e.isConnected;
|
|
648
|
+
function mo(e, r) {
|
|
649
649
|
const t = r.slice(0, -1).length;
|
|
650
650
|
let o = 0;
|
|
651
651
|
for (; o < t; )
|
|
652
|
-
e =
|
|
652
|
+
e = W(e) ? o++ : e[r[o++]];
|
|
653
653
|
return e;
|
|
654
654
|
}
|
|
655
|
-
function
|
|
655
|
+
function yo(e) {
|
|
656
656
|
for (const r in e)
|
|
657
|
-
if (e.hasOwnProperty(r) && !
|
|
657
|
+
if (e.hasOwnProperty(r) && !W(e[r]))
|
|
658
658
|
return !1;
|
|
659
659
|
return !0;
|
|
660
660
|
}
|
|
661
661
|
function G(e, r) {
|
|
662
|
-
const t = Array.isArray(r) ? r : Ue(r) ? [r] :
|
|
663
|
-
return o && delete o[n], s !== 0 && (Z(o) && Y(o) || Array.isArray(o) &&
|
|
662
|
+
const t = Array.isArray(r) ? r : Ue(r) ? [r] : vt(r), o = t.length === 1 ? e : mo(e, t), s = t.length - 1, n = t[s];
|
|
663
|
+
return o && delete o[n], s !== 0 && (Z(o) && Y(o) || Array.isArray(o) && yo(o)) && G(e, t.slice(0, -1)), e;
|
|
664
664
|
}
|
|
665
|
-
var
|
|
665
|
+
var ho = (e) => {
|
|
666
666
|
for (const r in e)
|
|
667
667
|
if (ce(e[r]))
|
|
668
668
|
return !0;
|
|
669
669
|
return !1;
|
|
670
670
|
};
|
|
671
|
-
function
|
|
672
|
-
return Array.isArray(e) || Z(e) && !
|
|
671
|
+
function hr(e) {
|
|
672
|
+
return Array.isArray(e) || Z(e) && !ho(e);
|
|
673
673
|
}
|
|
674
|
-
function
|
|
674
|
+
function mt(e, r = {}) {
|
|
675
675
|
for (const t in e)
|
|
676
|
-
|
|
676
|
+
hr(e[t]) ? (r[t] = Array.isArray(e[t]) ? [] : {}, mt(e[t], r[t])) : W(e[t]) || (r[t] = !0);
|
|
677
677
|
return r;
|
|
678
678
|
}
|
|
679
|
-
function
|
|
680
|
-
t || (t =
|
|
679
|
+
function ke(e, r, t) {
|
|
680
|
+
t || (t = mt(r));
|
|
681
681
|
for (const o in e)
|
|
682
|
-
|
|
682
|
+
hr(e[o]) ? W(r) || ft(t[o]) ? t[o] = mt(e[o], Array.isArray(e[o]) ? [] : {}) : ke(e[o], ee(r) ? {} : r[o], t[o]) : t[o] = !le(e[o], r[o]);
|
|
683
683
|
return t;
|
|
684
684
|
}
|
|
685
685
|
const Rt = {
|
|
686
686
|
value: !1,
|
|
687
687
|
isValid: !1
|
|
688
|
-
},
|
|
689
|
-
var
|
|
688
|
+
}, Ot = { value: !0, isValid: !0 };
|
|
689
|
+
var _r = (e) => {
|
|
690
690
|
if (Array.isArray(e)) {
|
|
691
691
|
if (e.length > 1) {
|
|
692
692
|
const r = e.filter((t) => t && t.checked && !t.disabled).map((t) => t.value);
|
|
@@ -694,28 +694,28 @@ var hr = (e) => {
|
|
|
694
694
|
}
|
|
695
695
|
return e[0].checked && !e[0].disabled ? (
|
|
696
696
|
// @ts-expect-error expected to work in the browser
|
|
697
|
-
e[0].attributes && !
|
|
697
|
+
e[0].attributes && !W(e[0].attributes.value) ? W(e[0].value) || e[0].value === "" ? Ot : { value: e[0].value, isValid: !0 } : Ot
|
|
698
698
|
) : Rt;
|
|
699
699
|
}
|
|
700
700
|
return Rt;
|
|
701
|
-
},
|
|
702
|
-
const
|
|
701
|
+
}, pr = (e, { valueAsNumber: r, valueAsDate: t, setValueAs: o }) => W(e) ? e : r ? e === "" ? NaN : e && +e : t && oe(e) ? new Date(e) : o ? o(e) : e;
|
|
702
|
+
const It = {
|
|
703
703
|
isValid: !1,
|
|
704
704
|
value: null
|
|
705
705
|
};
|
|
706
|
-
var
|
|
706
|
+
var gr = (e) => Array.isArray(e) ? e.reduce((r, t) => t && t.checked && !t.disabled ? {
|
|
707
707
|
isValid: !0,
|
|
708
708
|
value: t.value
|
|
709
|
-
} : r,
|
|
710
|
-
function
|
|
709
|
+
} : r, It) : It;
|
|
710
|
+
function Tt(e) {
|
|
711
711
|
const r = e.ref;
|
|
712
|
-
return
|
|
712
|
+
return kt(r) ? r.files : xt(r) ? gr(e.refs).value : yr(r) ? [...r.selectedOptions].map(({ value: t }) => t) : Ae(r) ? _r(e.refs).value : pr(W(r.value) ? e.ref.value : r.value, e);
|
|
713
713
|
}
|
|
714
|
-
var
|
|
714
|
+
var _o = (e, r, t, o) => {
|
|
715
715
|
const s = {};
|
|
716
716
|
for (const n of e) {
|
|
717
717
|
const a = w(r, n);
|
|
718
|
-
a &&
|
|
718
|
+
a && H(s, n, a._f);
|
|
719
719
|
}
|
|
720
720
|
return {
|
|
721
721
|
criteriaMode: t,
|
|
@@ -723,16 +723,16 @@ var ho = (e, r, t, o) => {
|
|
|
723
723
|
fields: s,
|
|
724
724
|
shouldUseNativeValidation: o
|
|
725
725
|
};
|
|
726
|
-
},
|
|
726
|
+
}, je = (e) => e instanceof RegExp, ze = (e) => W(e) ? e : je(e) ? e.source : Z(e) ? je(e.value) ? e.value.source : e.value : e, Ht = (e) => ({
|
|
727
727
|
isOnSubmit: !e || e === ie.onSubmit,
|
|
728
728
|
isOnBlur: e === ie.onBlur,
|
|
729
729
|
isOnChange: e === ie.onChange,
|
|
730
730
|
isOnAll: e === ie.all,
|
|
731
731
|
isOnTouch: e === ie.onTouched
|
|
732
732
|
});
|
|
733
|
-
const
|
|
734
|
-
var
|
|
735
|
-
const
|
|
733
|
+
const jt = "AsyncFunction";
|
|
734
|
+
var po = (e) => !!e && !!e.validate && !!(ce(e.validate) && e.validate.constructor.name === jt || Z(e.validate) && Object.values(e.validate).find((r) => r.constructor.name === jt)), go = (e) => e.mount && (e.required || e.min || e.max || e.maxLength || e.minLength || e.pattern || e.validate), Wt = (e, r, t) => !t && (r.watchAll || r.watch.has(e) || [...r.watch].some((o) => e.startsWith(o) && /^\.\w+/.test(e.slice(o.length))));
|
|
735
|
+
const $e = (e, r, t, o) => {
|
|
736
736
|
for (const s of t || Object.keys(e)) {
|
|
737
737
|
const n = w(e, s);
|
|
738
738
|
if (n) {
|
|
@@ -742,9 +742,9 @@ const Ne = (e, r, t, o) => {
|
|
|
742
742
|
return !0;
|
|
743
743
|
if (a.ref && r(a.ref, a.name) && !o)
|
|
744
744
|
return !0;
|
|
745
|
-
if (
|
|
745
|
+
if ($e(i, r))
|
|
746
746
|
break;
|
|
747
|
-
} else if (Z(i) &&
|
|
747
|
+
} else if (Z(i) && $e(i, r))
|
|
748
748
|
break;
|
|
749
749
|
}
|
|
750
750
|
}
|
|
@@ -777,15 +777,15 @@ function Ut(e, r, t) {
|
|
|
777
777
|
name: t
|
|
778
778
|
};
|
|
779
779
|
}
|
|
780
|
-
var
|
|
780
|
+
var vo = (e, r, t, o) => {
|
|
781
781
|
t(e);
|
|
782
782
|
const { name: s, ...n } = e;
|
|
783
783
|
return Y(n) || Object.keys(n).length >= Object.keys(r).length || Object.keys(n).find((a) => r[a] === (!o || ie.all));
|
|
784
|
-
},
|
|
785
|
-
const o =
|
|
786
|
-
return
|
|
784
|
+
}, bo = (e, r, t) => !e || !r || e === r || Ne(e).some((o) => o && (t ? o === r : o.startsWith(r) || r.startsWith(o))), So = (e, r, t, o, s) => s.isOnAll ? !1 : !t && s.isOnTouch ? !(r || e) : (t ? o.isOnBlur : s.isOnBlur) ? !e : (t ? o.isOnChange : s.isOnChange) ? e : !0, wo = (e, r) => !gt(w(e, r)).length && G(e, r), ko = (e, r, t) => {
|
|
785
|
+
const o = Ne(w(e, t));
|
|
786
|
+
return H(o, "root", r[t]), H(e, t, o), e;
|
|
787
787
|
};
|
|
788
|
-
function
|
|
788
|
+
function qt(e, r, t = "validate") {
|
|
789
789
|
if (oe(e) || Array.isArray(e) && e.every(oe) || re(e) && !e)
|
|
790
790
|
return {
|
|
791
791
|
type: t,
|
|
@@ -793,68 +793,68 @@ function Wt(e, r, t = "validate") {
|
|
|
793
793
|
ref: r
|
|
794
794
|
};
|
|
795
795
|
}
|
|
796
|
-
var be = (e) => Z(e) && !
|
|
796
|
+
var be = (e) => Z(e) && !je(e) ? e : {
|
|
797
797
|
value: e,
|
|
798
798
|
message: ""
|
|
799
|
-
},
|
|
799
|
+
}, Gt = async (e, r, t, o, s, n) => {
|
|
800
800
|
const { ref: a, refs: i, required: f, maxLength: c, minLength: u, min: y, max: m, pattern: C, validate: b, name: _, valueAsNumber: k, mount: V } = e._f, g = w(t, _);
|
|
801
801
|
if (!V || r.has(_))
|
|
802
802
|
return {};
|
|
803
803
|
const F = i ? i[0] : a, z = (L) => {
|
|
804
804
|
s && F.reportValidity && (F.setCustomValidity(re(L) ? "" : L || ""), F.reportValidity());
|
|
805
|
-
}, E = {},
|
|
806
|
-
const te = L ? A :
|
|
805
|
+
}, E = {}, B = xt(a), M = Ae(a), U = B || M, P = (k || kt(a)) && W(a.value) && W(g) || He(a) && a.value === "" || g === "" || Array.isArray(g) && !g.length, K = wt.bind(null, _, o, E), q = (L, A, O, I = fe.maxLength, Q = fe.minLength) => {
|
|
806
|
+
const te = L ? A : O;
|
|
807
807
|
E[_] = {
|
|
808
|
-
type: L ?
|
|
808
|
+
type: L ? I : Q,
|
|
809
809
|
message: te,
|
|
810
810
|
ref: a,
|
|
811
|
-
...
|
|
811
|
+
...K(L ? I : Q, te)
|
|
812
812
|
};
|
|
813
813
|
};
|
|
814
|
-
if (n ? !Array.isArray(g) || !g.length : f && (!
|
|
814
|
+
if (n ? !Array.isArray(g) || !g.length : f && (!U && (P || ee(g)) || re(g) && !g || M && !_r(i).isValid || B && !gr(i).isValid)) {
|
|
815
815
|
const { value: L, message: A } = oe(f) ? { value: !!f, message: f } : be(f);
|
|
816
816
|
if (L && (E[_] = {
|
|
817
817
|
type: fe.required,
|
|
818
818
|
message: A,
|
|
819
819
|
ref: F,
|
|
820
|
-
...
|
|
820
|
+
...K(fe.required, A)
|
|
821
821
|
}, !o))
|
|
822
822
|
return z(A), E;
|
|
823
823
|
}
|
|
824
824
|
if (!P && (!ee(y) || !ee(m))) {
|
|
825
825
|
let L, A;
|
|
826
|
-
const
|
|
826
|
+
const O = be(m), I = be(y);
|
|
827
827
|
if (!ee(g) && !isNaN(g)) {
|
|
828
|
-
const
|
|
829
|
-
ee(
|
|
828
|
+
const Q = a.valueAsNumber || g && +g;
|
|
829
|
+
ee(O.value) || (L = Q > O.value), ee(I.value) || (A = Q < I.value);
|
|
830
830
|
} else {
|
|
831
|
-
const
|
|
832
|
-
oe(
|
|
831
|
+
const Q = a.valueAsDate || new Date(g), te = (Pe) => /* @__PURE__ */ new Date((/* @__PURE__ */ new Date()).toDateString() + " " + Pe), me = a.type == "time", ve = a.type == "week";
|
|
832
|
+
oe(O.value) && g && (L = me ? te(g) > te(O.value) : ve ? g > O.value : Q > new Date(O.value)), oe(I.value) && g && (A = me ? te(g) < te(I.value) : ve ? g < I.value : Q < new Date(I.value));
|
|
833
833
|
}
|
|
834
|
-
if ((L || A) && (q(!!L,
|
|
834
|
+
if ((L || A) && (q(!!L, O.message, I.message, fe.max, fe.min), !o))
|
|
835
835
|
return z(E[_].message), E;
|
|
836
836
|
}
|
|
837
837
|
if ((c || u) && !P && (oe(g) || n && Array.isArray(g))) {
|
|
838
|
-
const L = be(c), A = be(u),
|
|
839
|
-
if ((
|
|
838
|
+
const L = be(c), A = be(u), O = !ee(L.value) && g.length > +L.value, I = !ee(A.value) && g.length < +A.value;
|
|
839
|
+
if ((O || I) && (q(O, L.message, A.message), !o))
|
|
840
840
|
return z(E[_].message), E;
|
|
841
841
|
}
|
|
842
842
|
if (C && !P && oe(g)) {
|
|
843
843
|
const { value: L, message: A } = be(C);
|
|
844
|
-
if (
|
|
844
|
+
if (je(L) && !g.match(L) && (E[_] = {
|
|
845
845
|
type: fe.pattern,
|
|
846
846
|
message: A,
|
|
847
847
|
ref: a,
|
|
848
|
-
...
|
|
848
|
+
...K(fe.pattern, A)
|
|
849
849
|
}, !o))
|
|
850
850
|
return z(A), E;
|
|
851
851
|
}
|
|
852
852
|
if (b) {
|
|
853
853
|
if (ce(b)) {
|
|
854
|
-
const L = await b(g, t), A =
|
|
854
|
+
const L = await b(g, t), A = qt(L, F);
|
|
855
855
|
if (A && (E[_] = {
|
|
856
856
|
...A,
|
|
857
|
-
...
|
|
857
|
+
...K(fe.validate, A.message)
|
|
858
858
|
}, !o))
|
|
859
859
|
return z(A.message), E;
|
|
860
860
|
} else if (Z(b)) {
|
|
@@ -862,11 +862,11 @@ var be = (e) => Z(e) && !He(e) ? e : {
|
|
|
862
862
|
for (const A in b) {
|
|
863
863
|
if (!Y(L) && !o)
|
|
864
864
|
break;
|
|
865
|
-
const
|
|
866
|
-
|
|
867
|
-
...
|
|
868
|
-
...
|
|
869
|
-
}, z(
|
|
865
|
+
const O = qt(await b[A](g, t), F, A);
|
|
866
|
+
O && (L = {
|
|
867
|
+
...O,
|
|
868
|
+
...K(A, O.message)
|
|
869
|
+
}, z(O.message), o && (E[_] = L));
|
|
870
870
|
}
|
|
871
871
|
if (!Y(L) && (E[_] = {
|
|
872
872
|
ref: F,
|
|
@@ -877,14 +877,14 @@ var be = (e) => Z(e) && !He(e) ? e : {
|
|
|
877
877
|
}
|
|
878
878
|
return z(!0), E;
|
|
879
879
|
};
|
|
880
|
-
const
|
|
880
|
+
const xo = {
|
|
881
881
|
mode: ie.onSubmit,
|
|
882
882
|
reValidateMode: ie.onChange,
|
|
883
883
|
shouldFocusError: !0
|
|
884
884
|
};
|
|
885
|
-
function
|
|
885
|
+
function Co(e = {}) {
|
|
886
886
|
let r = {
|
|
887
|
-
...
|
|
887
|
+
...xo,
|
|
888
888
|
...e
|
|
889
889
|
}, t = {
|
|
890
890
|
submitCount: 0,
|
|
@@ -925,20 +925,20 @@ function xo(e = {}) {
|
|
|
925
925
|
...u
|
|
926
926
|
};
|
|
927
927
|
const m = {
|
|
928
|
-
array:
|
|
929
|
-
state:
|
|
928
|
+
array: Dt(),
|
|
929
|
+
state: Dt()
|
|
930
930
|
}, C = r.criteriaMode === ie.all, b = (l) => (d) => {
|
|
931
931
|
clearTimeout(c), c = setTimeout(l, d);
|
|
932
932
|
}, _ = async (l) => {
|
|
933
933
|
if (!r.disabled && (u.isValid || y.isValid || l)) {
|
|
934
|
-
const d = r.resolver ? Y((await
|
|
934
|
+
const d = r.resolver ? Y((await M()).errors) : await P(o, !0);
|
|
935
935
|
d !== t.isValid && m.state.next({
|
|
936
936
|
isValid: d
|
|
937
937
|
});
|
|
938
938
|
}
|
|
939
939
|
}, k = (l, d) => {
|
|
940
940
|
!r.disabled && (u.isValidating || u.validatingFields || y.isValidating || y.validatingFields) && ((l || Array.from(i.mount)).forEach((h) => {
|
|
941
|
-
h && (d ?
|
|
941
|
+
h && (d ? H(t.validatingFields, h, d) : G(t.validatingFields, h));
|
|
942
942
|
}), m.state.next({
|
|
943
943
|
validatingFields: t.validatingFields,
|
|
944
944
|
isValidating: !Y(t.validatingFields)
|
|
@@ -947,17 +947,17 @@ function xo(e = {}) {
|
|
|
947
947
|
if (x && h && !r.disabled) {
|
|
948
948
|
if (a.action = !0, v && Array.isArray(w(o, l))) {
|
|
949
949
|
const $ = h(w(o, l), x.argA, x.argB);
|
|
950
|
-
S &&
|
|
950
|
+
S && H(o, l, $);
|
|
951
951
|
}
|
|
952
952
|
if (v && Array.isArray(w(t.errors, l))) {
|
|
953
953
|
const $ = h(w(t.errors, l), x.argA, x.argB);
|
|
954
|
-
S &&
|
|
954
|
+
S && H(t.errors, l, $), wo(t.errors, l);
|
|
955
955
|
}
|
|
956
956
|
if ((u.touchedFields || y.touchedFields) && v && Array.isArray(w(t.touchedFields, l))) {
|
|
957
957
|
const $ = h(w(t.touchedFields, l), x.argA, x.argB);
|
|
958
|
-
S &&
|
|
958
|
+
S && H(t.touchedFields, l, $);
|
|
959
959
|
}
|
|
960
|
-
(u.dirtyFields || y.dirtyFields) && (t.dirtyFields =
|
|
960
|
+
(u.dirtyFields || y.dirtyFields) && (t.dirtyFields = ke(s, n)), m.state.next({
|
|
961
961
|
name: l,
|
|
962
962
|
isDirty: q(l, d),
|
|
963
963
|
dirtyFields: t.dirtyFields,
|
|
@@ -965,9 +965,9 @@ function xo(e = {}) {
|
|
|
965
965
|
isValid: t.isValid
|
|
966
966
|
});
|
|
967
967
|
} else
|
|
968
|
-
|
|
968
|
+
H(n, l, d);
|
|
969
969
|
}, g = (l, d) => {
|
|
970
|
-
|
|
970
|
+
H(t.errors, l, d), m.state.next({
|
|
971
971
|
errors: t.errors
|
|
972
972
|
});
|
|
973
973
|
}, F = (l) => {
|
|
@@ -978,30 +978,30 @@ function xo(e = {}) {
|
|
|
978
978
|
}, z = (l, d, h, x) => {
|
|
979
979
|
const S = w(o, l);
|
|
980
980
|
if (S) {
|
|
981
|
-
const v = w(n, l,
|
|
982
|
-
|
|
981
|
+
const v = w(n, l, W(h) ? w(s, l) : h);
|
|
982
|
+
W(v) || x && x.defaultChecked || d ? H(n, l, d ? v : Tt(S._f)) : O(l, v), a.mount && _();
|
|
983
983
|
}
|
|
984
984
|
}, E = (l, d, h, x, S) => {
|
|
985
985
|
let v = !1, $ = !1;
|
|
986
|
-
const
|
|
986
|
+
const T = {
|
|
987
987
|
name: l
|
|
988
988
|
};
|
|
989
989
|
if (!r.disabled) {
|
|
990
990
|
if (!h || x) {
|
|
991
|
-
(u.isDirty || y.isDirty) && ($ = t.isDirty, t.isDirty =
|
|
991
|
+
(u.isDirty || y.isDirty) && ($ = t.isDirty, t.isDirty = T.isDirty = q(), v = $ !== T.isDirty);
|
|
992
992
|
const j = le(w(s, l), d);
|
|
993
|
-
$ = !!w(t.dirtyFields, l), j ? G(t.dirtyFields, l) :
|
|
993
|
+
$ = !!w(t.dirtyFields, l), j ? G(t.dirtyFields, l) : H(t.dirtyFields, l, !0), T.dirtyFields = t.dirtyFields, v = v || (u.dirtyFields || y.dirtyFields) && $ !== !j;
|
|
994
994
|
}
|
|
995
995
|
if (h) {
|
|
996
996
|
const j = w(t.touchedFields, l);
|
|
997
|
-
j || (
|
|
997
|
+
j || (H(t.touchedFields, l, h), T.touchedFields = t.touchedFields, v = v || (u.touchedFields || y.touchedFields) && j !== h);
|
|
998
998
|
}
|
|
999
|
-
v && S && m.state.next(
|
|
999
|
+
v && S && m.state.next(T);
|
|
1000
1000
|
}
|
|
1001
|
-
return v ?
|
|
1002
|
-
},
|
|
1001
|
+
return v ? T : {};
|
|
1002
|
+
}, B = (l, d, h, x) => {
|
|
1003
1003
|
const S = w(t.errors, l), v = (u.isValid || y.isValid) && re(d) && t.isValid !== d;
|
|
1004
|
-
if (r.delayError && h ? (f = b(() => g(l, h)), f(r.delayError)) : (clearTimeout(c), f = null, h ?
|
|
1004
|
+
if (r.delayError && h ? (f = b(() => g(l, h)), f(r.delayError)) : (clearTimeout(c), f = null, h ? H(t.errors, l, h) : G(t.errors, l)), (h ? !le(S, h) : S) || !Y(x) || v) {
|
|
1005
1005
|
const $ = {
|
|
1006
1006
|
...x,
|
|
1007
1007
|
...v && re(d) ? { isValid: d } : {},
|
|
@@ -1013,16 +1013,16 @@ function xo(e = {}) {
|
|
|
1013
1013
|
...$
|
|
1014
1014
|
}, m.state.next($);
|
|
1015
1015
|
}
|
|
1016
|
-
},
|
|
1016
|
+
}, M = async (l) => {
|
|
1017
1017
|
k(l, !0);
|
|
1018
|
-
const d = await r.resolver(n, r.context,
|
|
1018
|
+
const d = await r.resolver(n, r.context, _o(l || i.mount, o, r.criteriaMode, r.shouldUseNativeValidation));
|
|
1019
1019
|
return k(l), d;
|
|
1020
|
-
},
|
|
1021
|
-
const { errors: d } = await
|
|
1020
|
+
}, U = async (l) => {
|
|
1021
|
+
const { errors: d } = await M(l);
|
|
1022
1022
|
if (l)
|
|
1023
1023
|
for (const h of l) {
|
|
1024
1024
|
const x = w(d, h);
|
|
1025
|
-
x ?
|
|
1025
|
+
x ? H(t.errors, h, x) : G(t.errors, h);
|
|
1026
1026
|
}
|
|
1027
1027
|
else
|
|
1028
1028
|
t.errors = d;
|
|
@@ -1035,55 +1035,55 @@ function xo(e = {}) {
|
|
|
1035
1035
|
if (S) {
|
|
1036
1036
|
const { _f: v, ...$ } = S;
|
|
1037
1037
|
if (v) {
|
|
1038
|
-
const
|
|
1038
|
+
const T = i.array.has(v.name), j = S._f && po(S._f);
|
|
1039
1039
|
j && u.validatingFields && k([v.name], !0);
|
|
1040
|
-
const se = await
|
|
1040
|
+
const se = await Gt(S, i.disabled, n, C, r.shouldUseNativeValidation && !d, T);
|
|
1041
1041
|
if (j && u.validatingFields && k([v.name]), se[v.name] && (h.valid = !1, d))
|
|
1042
1042
|
break;
|
|
1043
|
-
!d && (w(se, v.name) ?
|
|
1043
|
+
!d && (w(se, v.name) ? T ? ko(t.errors, se, v.name) : H(t.errors, v.name, se[v.name]) : G(t.errors, v.name));
|
|
1044
1044
|
}
|
|
1045
1045
|
!Y($) && await P($, d, h);
|
|
1046
1046
|
}
|
|
1047
1047
|
}
|
|
1048
1048
|
return h.valid;
|
|
1049
|
-
},
|
|
1049
|
+
}, K = () => {
|
|
1050
1050
|
for (const l of i.unMount) {
|
|
1051
1051
|
const d = w(o, l);
|
|
1052
|
-
d && (d._f.refs ? d._f.refs.every((h) => !
|
|
1052
|
+
d && (d._f.refs ? d._f.refs.every((h) => !Ye(h)) : !Ye(d._f.ref)) && qe(l);
|
|
1053
1053
|
}
|
|
1054
1054
|
i.unMount = /* @__PURE__ */ new Set();
|
|
1055
|
-
}, q = (l, d) => !r.disabled && (l && d &&
|
|
1056
|
-
...a.mount ? n :
|
|
1057
|
-
}, h, d), A = (l) =>
|
|
1055
|
+
}, q = (l, d) => !r.disabled && (l && d && H(n, l, d), !le(Pe(), s)), L = (l, d, h) => dt(l, i, {
|
|
1056
|
+
...a.mount ? n : W(d) ? s : oe(l) ? { [l]: d } : d
|
|
1057
|
+
}, h, d), A = (l) => gt(w(a.mount ? n : s, l, r.shouldUnregister ? w(s, l, []) : [])), O = (l, d, h = {}) => {
|
|
1058
1058
|
const x = w(o, l);
|
|
1059
1059
|
let S = d;
|
|
1060
1060
|
if (x) {
|
|
1061
1061
|
const v = x._f;
|
|
1062
|
-
v && (!v.disabled &&
|
|
1063
|
-
(!$.defaultChecked || !$.disabled) && (Array.isArray(S) ? $.checked = !!S.find((
|
|
1064
|
-
}) : v.refs.forEach(($) => $.checked = $.value === S) :
|
|
1062
|
+
v && (!v.disabled && H(n, l, pr(d, v)), S = He(v.ref) && ee(d) ? "" : d, yr(v.ref) ? [...v.ref.options].forEach(($) => $.selected = S.includes($.value)) : v.refs ? Ae(v.ref) ? v.refs.forEach(($) => {
|
|
1063
|
+
(!$.defaultChecked || !$.disabled) && (Array.isArray(S) ? $.checked = !!S.find((T) => T === $.value) : $.checked = S === $.value || !!S);
|
|
1064
|
+
}) : v.refs.forEach(($) => $.checked = $.value === S) : kt(v.ref) ? v.ref.value = "" : (v.ref.value = S, v.ref.type || m.state.next({
|
|
1065
1065
|
name: l,
|
|
1066
1066
|
values: X(n)
|
|
1067
1067
|
})));
|
|
1068
1068
|
}
|
|
1069
1069
|
(h.shouldDirty || h.shouldTouch) && E(l, S, h.shouldTouch, h.shouldDirty, !0), h.shouldValidate && ve(l);
|
|
1070
|
-
},
|
|
1070
|
+
}, I = (l, d, h) => {
|
|
1071
1071
|
for (const x in d) {
|
|
1072
1072
|
if (!d.hasOwnProperty(x))
|
|
1073
1073
|
return;
|
|
1074
1074
|
const S = d[x], v = l + "." + x, $ = w(o, v);
|
|
1075
|
-
(i.array.has(l) || Z(S) || $ && !$._f) && !_e(S) ?
|
|
1075
|
+
(i.array.has(l) || Z(S) || $ && !$._f) && !_e(S) ? I(v, S, h) : O(v, S, h);
|
|
1076
1076
|
}
|
|
1077
|
-
},
|
|
1077
|
+
}, Q = (l, d, h = {}) => {
|
|
1078
1078
|
const x = w(o, l), S = i.array.has(l), v = X(d);
|
|
1079
|
-
|
|
1079
|
+
H(n, l, v), S ? (m.array.next({
|
|
1080
1080
|
name: l,
|
|
1081
1081
|
values: X(n)
|
|
1082
1082
|
}), (u.isDirty || u.dirtyFields || y.isDirty || y.dirtyFields) && h.shouldDirty && m.state.next({
|
|
1083
1083
|
name: l,
|
|
1084
|
-
dirtyFields:
|
|
1084
|
+
dirtyFields: ke(s, n),
|
|
1085
1085
|
isDirty: q(l, v)
|
|
1086
|
-
})) : x && !x._f && !ee(v) ?
|
|
1086
|
+
})) : x && !x._f && !ee(v) ? I(l, v, h) : O(l, v, h), Wt(l, i) && m.state.next({ ...t, name: l }), m.state.next({
|
|
1087
1087
|
name: a.mount ? l : void 0,
|
|
1088
1088
|
values: X(n)
|
|
1089
1089
|
});
|
|
@@ -1093,36 +1093,36 @@ function xo(e = {}) {
|
|
|
1093
1093
|
let h = d.name, x = !0;
|
|
1094
1094
|
const S = w(o, h), v = (j) => {
|
|
1095
1095
|
x = Number.isNaN(j) || _e(j) && isNaN(j.getTime()) || le(j, w(n, h, j));
|
|
1096
|
-
}, $ =
|
|
1096
|
+
}, $ = Ht(r.mode), T = Ht(r.reValidateMode);
|
|
1097
1097
|
if (S) {
|
|
1098
1098
|
let j, se;
|
|
1099
|
-
const
|
|
1100
|
-
|
|
1101
|
-
const Qe = E(h,
|
|
1099
|
+
const Me = d.type ? Tt(S._f) : cr(l), ye = l.type === Te.BLUR || l.type === Te.FOCUS_OUT, Ir = !go(S._f) && !r.resolver && !w(t.errors, h) && !S._f.deps || So(ye, w(t.touchedFields, h), t.isSubmitted, T, $), Ke = Wt(h, i, ye);
|
|
1100
|
+
H(n, h, Me), ye ? (!d || !d.readOnly) && (S._f.onBlur && S._f.onBlur(l), f && f(0)) : S._f.onChange && S._f.onChange(l);
|
|
1101
|
+
const Qe = E(h, Me, ye), Tr = !Y(Qe) || Ke;
|
|
1102
1102
|
if (!ye && m.state.next({
|
|
1103
1103
|
name: h,
|
|
1104
1104
|
type: l.type,
|
|
1105
1105
|
values: X(n)
|
|
1106
|
-
}),
|
|
1107
|
-
return (u.isValid || y.isValid) && (r.mode === "onBlur" ? ye && _() : ye || _()),
|
|
1108
|
-
if (!ye &&
|
|
1109
|
-
const { errors:
|
|
1110
|
-
if (v(
|
|
1111
|
-
const
|
|
1112
|
-
j =
|
|
1106
|
+
}), Ir)
|
|
1107
|
+
return (u.isValid || y.isValid) && (r.mode === "onBlur" ? ye && _() : ye || _()), Tr && m.state.next({ name: h, ...Ke ? {} : Qe });
|
|
1108
|
+
if (!ye && Ke && m.state.next({ ...t }), r.resolver) {
|
|
1109
|
+
const { errors: At } = await M([h]);
|
|
1110
|
+
if (v(Me), x) {
|
|
1111
|
+
const Hr = Ut(t.errors, o, h), Pt = Ut(At, o, Hr.name || h);
|
|
1112
|
+
j = Pt.error, h = Pt.name, se = Y(At);
|
|
1113
1113
|
}
|
|
1114
1114
|
} else
|
|
1115
|
-
k([h], !0), j = (await
|
|
1116
|
-
x && (S._f.deps && (!Array.isArray(S._f.deps) || S._f.deps.length > 0) && ve(S._f.deps),
|
|
1115
|
+
k([h], !0), j = (await Gt(S, i.disabled, n, C, r.shouldUseNativeValidation))[h], k([h]), v(Me), x && (j ? se = !1 : (u.isValid || y.isValid) && (se = await P(o, !0)));
|
|
1116
|
+
x && (S._f.deps && (!Array.isArray(S._f.deps) || S._f.deps.length > 0) && ve(S._f.deps), B(h, se, j, Qe));
|
|
1117
1117
|
}
|
|
1118
1118
|
}, me = (l, d) => {
|
|
1119
1119
|
if (w(t.errors, d) && l.focus)
|
|
1120
1120
|
return l.focus(), 1;
|
|
1121
1121
|
}, ve = async (l, d = {}) => {
|
|
1122
1122
|
let h, x;
|
|
1123
|
-
const S =
|
|
1123
|
+
const S = Ne(l);
|
|
1124
1124
|
if (r.resolver) {
|
|
1125
|
-
const v = await W(
|
|
1125
|
+
const v = await U(W(l) ? l : S);
|
|
1126
1126
|
h = Y(v), x = l ? !S.some(($) => w(v, $)) : h;
|
|
1127
1127
|
} else l ? (x = (await Promise.all(S.map(async (v) => {
|
|
1128
1128
|
const $ = w(o, v);
|
|
@@ -1132,25 +1132,25 @@ function xo(e = {}) {
|
|
|
1132
1132
|
...!oe(l) || (u.isValid || y.isValid) && h !== t.isValid ? {} : { name: l },
|
|
1133
1133
|
...r.resolver || !l ? { isValid: h } : {},
|
|
1134
1134
|
errors: t.errors
|
|
1135
|
-
}), d.shouldFocus && !x &&
|
|
1136
|
-
},
|
|
1135
|
+
}), d.shouldFocus && !x && $e(o, me, l ? S : i.mount), x;
|
|
1136
|
+
}, Pe = (l, d) => {
|
|
1137
1137
|
let h = {
|
|
1138
1138
|
...a.mount ? n : s
|
|
1139
1139
|
};
|
|
1140
|
-
return d && (h =
|
|
1141
|
-
},
|
|
1140
|
+
return d && (h = mr(d.dirtyFields ? t.dirtyFields : t.touchedFields, h)), W(l) ? h : oe(l) ? w(h, l) : l.map((x) => w(h, x));
|
|
1141
|
+
}, Ct = (l, d) => ({
|
|
1142
1142
|
invalid: !!w((d || t).errors, l),
|
|
1143
1143
|
isDirty: !!w((d || t).dirtyFields, l),
|
|
1144
1144
|
error: w((d || t).errors, l),
|
|
1145
1145
|
isValidating: !!w(t.validatingFields, l),
|
|
1146
1146
|
isTouched: !!w((d || t).touchedFields, l)
|
|
1147
|
-
}),
|
|
1148
|
-
l &&
|
|
1147
|
+
}), Ar = (l) => {
|
|
1148
|
+
l && Ne(l).forEach((d) => G(t.errors, d)), m.state.next({
|
|
1149
1149
|
errors: l ? t.errors : {}
|
|
1150
1150
|
});
|
|
1151
|
-
},
|
|
1152
|
-
const x = (w(o, l, { _f: {} })._f || {}).ref, S = w(t.errors, l) || {}, { ref: v, message: $, type:
|
|
1153
|
-
|
|
1151
|
+
}, Ft = (l, d, h) => {
|
|
1152
|
+
const x = (w(o, l, { _f: {} })._f || {}).ref, S = w(t.errors, l) || {}, { ref: v, message: $, type: T, ...j } = S;
|
|
1153
|
+
H(t.errors, l, {
|
|
1154
1154
|
...j,
|
|
1155
1155
|
...d,
|
|
1156
1156
|
ref: x
|
|
@@ -1159,25 +1159,25 @@ function xo(e = {}) {
|
|
|
1159
1159
|
errors: t.errors,
|
|
1160
1160
|
isValid: !1
|
|
1161
1161
|
}), h && h.shouldFocus && x && x.focus && x.focus();
|
|
1162
|
-
},
|
|
1162
|
+
}, Pr = (l, d) => ce(l) ? m.state.subscribe({
|
|
1163
1163
|
next: (h) => "values" in h && l(L(void 0, d), h)
|
|
1164
|
-
}) : L(l, d, !0),
|
|
1164
|
+
}) : L(l, d, !0), Vt = (l) => m.state.subscribe({
|
|
1165
1165
|
next: (d) => {
|
|
1166
|
-
|
|
1166
|
+
bo(l.name, d.name, l.exact) && vo(d, l.formState || u, Or, l.reRenderRoot) && l.callback({
|
|
1167
1167
|
values: { ...n },
|
|
1168
1168
|
...t,
|
|
1169
1169
|
...d,
|
|
1170
1170
|
defaultValues: s
|
|
1171
1171
|
});
|
|
1172
1172
|
}
|
|
1173
|
-
}).unsubscribe,
|
|
1173
|
+
}).unsubscribe, Mr = (l) => (a.mount = !0, y = {
|
|
1174
1174
|
...y,
|
|
1175
1175
|
...l.formState
|
|
1176
|
-
},
|
|
1176
|
+
}, Vt({
|
|
1177
1177
|
...l,
|
|
1178
1178
|
formState: y
|
|
1179
|
-
})),
|
|
1180
|
-
for (const h of l ?
|
|
1179
|
+
})), qe = (l, d = {}) => {
|
|
1180
|
+
for (const h of l ? Ne(l) : i.mount)
|
|
1181
1181
|
i.mount.delete(h), i.array.delete(h), d.keepValue || (G(o, h), G(n, h)), !d.keepError && G(t.errors, h), !d.keepDirty && G(t.dirtyFields, h), !d.keepTouched && G(t.touchedFields, h), !d.keepIsValidating && G(t.validatingFields, h), !r.shouldUnregister && !d.keepDefaultValue && G(s, h);
|
|
1182
1182
|
m.state.next({
|
|
1183
1183
|
values: X(n)
|
|
@@ -1185,12 +1185,12 @@ function xo(e = {}) {
|
|
|
1185
1185
|
...t,
|
|
1186
1186
|
...d.keepDirty ? { isDirty: q() } : {}
|
|
1187
1187
|
}), !d.keepIsValid && _();
|
|
1188
|
-
},
|
|
1188
|
+
}, zt = ({ disabled: l, name: d }) => {
|
|
1189
1189
|
(re(l) && a.mount || l || i.disabled.has(d)) && (l ? i.disabled.add(d) : i.disabled.delete(d));
|
|
1190
|
-
},
|
|
1190
|
+
}, Ge = (l, d = {}) => {
|
|
1191
1191
|
let h = w(o, l);
|
|
1192
1192
|
const x = re(d.disabled) || re(r.disabled);
|
|
1193
|
-
return
|
|
1193
|
+
return H(o, l, {
|
|
1194
1194
|
...h || {},
|
|
1195
1195
|
_f: {
|
|
1196
1196
|
...h && h._f ? h._f : { ref: { name: l } },
|
|
@@ -1198,34 +1198,34 @@ function xo(e = {}) {
|
|
|
1198
1198
|
mount: !0,
|
|
1199
1199
|
...d
|
|
1200
1200
|
}
|
|
1201
|
-
}), i.mount.add(l), h ?
|
|
1201
|
+
}), i.mount.add(l), h ? zt({
|
|
1202
1202
|
disabled: re(d.disabled) ? d.disabled : r.disabled,
|
|
1203
1203
|
name: l
|
|
1204
1204
|
}) : z(l, !0, d.value), {
|
|
1205
1205
|
...x ? { disabled: d.disabled || r.disabled } : {},
|
|
1206
1206
|
...r.progressive ? {
|
|
1207
1207
|
required: !!d.required,
|
|
1208
|
-
min:
|
|
1209
|
-
max:
|
|
1210
|
-
minLength:
|
|
1211
|
-
maxLength:
|
|
1212
|
-
pattern:
|
|
1208
|
+
min: ze(d.min),
|
|
1209
|
+
max: ze(d.max),
|
|
1210
|
+
minLength: ze(d.minLength),
|
|
1211
|
+
maxLength: ze(d.maxLength),
|
|
1212
|
+
pattern: ze(d.pattern)
|
|
1213
1213
|
} : {},
|
|
1214
1214
|
name: l,
|
|
1215
1215
|
onChange: te,
|
|
1216
1216
|
onBlur: te,
|
|
1217
1217
|
ref: (S) => {
|
|
1218
1218
|
if (S) {
|
|
1219
|
-
|
|
1220
|
-
const v =
|
|
1221
|
-
if ($ ?
|
|
1219
|
+
Ge(l, d), h = w(o, l);
|
|
1220
|
+
const v = W(S.value) && S.querySelectorAll && S.querySelectorAll("input,select,textarea")[0] || S, $ = fo(v), T = h._f.refs || [];
|
|
1221
|
+
if ($ ? T.find((j) => j === v) : v === h._f.ref)
|
|
1222
1222
|
return;
|
|
1223
|
-
|
|
1223
|
+
H(o, l, {
|
|
1224
1224
|
_f: {
|
|
1225
1225
|
...h._f,
|
|
1226
1226
|
...$ ? {
|
|
1227
1227
|
refs: [
|
|
1228
|
-
...
|
|
1228
|
+
...T.filter(Ye),
|
|
1229
1229
|
v,
|
|
1230
1230
|
...Array.isArray(w(s, l)) ? [{}] : []
|
|
1231
1231
|
],
|
|
@@ -1234,24 +1234,24 @@ function xo(e = {}) {
|
|
|
1234
1234
|
}
|
|
1235
1235
|
}), z(l, !1, void 0, v);
|
|
1236
1236
|
} else
|
|
1237
|
-
h = w(o, l, {}), h._f && (h._f.mount = !1), (r.shouldUnregister || d.shouldUnregister) && !(
|
|
1237
|
+
h = w(o, l, {}), h._f && (h._f.mount = !1), (r.shouldUnregister || d.shouldUnregister) && !(ur(i.array, l) && a.action) && i.unMount.add(l);
|
|
1238
1238
|
}
|
|
1239
1239
|
};
|
|
1240
|
-
},
|
|
1241
|
-
re(l) && (m.state.next({ disabled: l }),
|
|
1240
|
+
}, Ze = () => r.shouldFocusError && $e(o, me, i.mount), Br = (l) => {
|
|
1241
|
+
re(l) && (m.state.next({ disabled: l }), $e(o, (d, h) => {
|
|
1242
1242
|
const x = w(o, h);
|
|
1243
1243
|
x && (d.disabled = x._f.disabled || l, Array.isArray(x._f.refs) && x._f.refs.forEach((S) => {
|
|
1244
1244
|
S.disabled = x._f.disabled || l;
|
|
1245
1245
|
}));
|
|
1246
1246
|
}, 0, !1));
|
|
1247
|
-
},
|
|
1247
|
+
}, Et = (l, d) => async (h) => {
|
|
1248
1248
|
let x;
|
|
1249
1249
|
h && (h.preventDefault && h.preventDefault(), h.persist && h.persist());
|
|
1250
1250
|
let S = X(n);
|
|
1251
1251
|
if (m.state.next({
|
|
1252
1252
|
isSubmitting: !0
|
|
1253
1253
|
}), r.resolver) {
|
|
1254
|
-
const { errors: v, values: $ } = await
|
|
1254
|
+
const { errors: v, values: $ } = await M();
|
|
1255
1255
|
t.errors = v, S = X($);
|
|
1256
1256
|
} else
|
|
1257
1257
|
await P(o);
|
|
@@ -1268,7 +1268,7 @@ function xo(e = {}) {
|
|
|
1268
1268
|
x = v;
|
|
1269
1269
|
}
|
|
1270
1270
|
} else
|
|
1271
|
-
d && await d({ ...t.errors }, h),
|
|
1271
|
+
d && await d({ ...t.errors }, h), Ze(), setTimeout(Ze);
|
|
1272
1272
|
if (m.state.next({
|
|
1273
1273
|
isSubmitted: !0,
|
|
1274
1274
|
isSubmitting: !1,
|
|
@@ -1277,25 +1277,25 @@ function xo(e = {}) {
|
|
|
1277
1277
|
errors: t.errors
|
|
1278
1278
|
}), x)
|
|
1279
1279
|
throw x;
|
|
1280
|
-
},
|
|
1281
|
-
w(o, l) && (
|
|
1282
|
-
},
|
|
1280
|
+
}, Dr = (l, d = {}) => {
|
|
1281
|
+
w(o, l) && (W(d.defaultValue) ? Q(l, X(w(s, l))) : (Q(l, d.defaultValue), H(s, l, X(d.defaultValue))), d.keepTouched || G(t.touchedFields, l), d.keepDirty || (G(t.dirtyFields, l), t.isDirty = d.defaultValue ? q(l, X(w(s, l))) : q()), d.keepError || (G(t.errors, l), u.isValid && _()), m.state.next({ ...t }));
|
|
1282
|
+
}, Nt = (l, d = {}) => {
|
|
1283
1283
|
const h = l ? X(l) : s, x = X(h), S = Y(l), v = S ? s : x;
|
|
1284
1284
|
if (d.keepDefaultValues || (s = h), !d.keepValues) {
|
|
1285
1285
|
if (d.keepDirtyValues) {
|
|
1286
1286
|
const $ = /* @__PURE__ */ new Set([
|
|
1287
1287
|
...i.mount,
|
|
1288
|
-
...Object.keys(
|
|
1288
|
+
...Object.keys(ke(s, n))
|
|
1289
1289
|
]);
|
|
1290
|
-
for (const
|
|
1291
|
-
w(t.dirtyFields,
|
|
1290
|
+
for (const T of Array.from($))
|
|
1291
|
+
w(t.dirtyFields, T) ? H(v, T, w(n, T)) : Q(T, w(v, T));
|
|
1292
1292
|
} else {
|
|
1293
|
-
if (
|
|
1293
|
+
if (pt && W(l))
|
|
1294
1294
|
for (const $ of i.mount) {
|
|
1295
|
-
const
|
|
1296
|
-
if (
|
|
1297
|
-
const j = Array.isArray(
|
|
1298
|
-
if (
|
|
1295
|
+
const T = w(o, $);
|
|
1296
|
+
if (T && T._f) {
|
|
1297
|
+
const j = Array.isArray(T._f.refs) ? T._f.refs[0] : T._f.ref;
|
|
1298
|
+
if (He(j)) {
|
|
1299
1299
|
const se = j.closest("form");
|
|
1300
1300
|
if (se) {
|
|
1301
1301
|
se.reset();
|
|
@@ -1306,7 +1306,7 @@ function xo(e = {}) {
|
|
|
1306
1306
|
}
|
|
1307
1307
|
if (d.keepFieldsRef)
|
|
1308
1308
|
for (const $ of i.mount)
|
|
1309
|
-
|
|
1309
|
+
Q($, w(v, $));
|
|
1310
1310
|
else
|
|
1311
1311
|
o = {};
|
|
1312
1312
|
}
|
|
@@ -1328,48 +1328,48 @@ function xo(e = {}) {
|
|
|
1328
1328
|
submitCount: d.keepSubmitCount ? t.submitCount : 0,
|
|
1329
1329
|
isDirty: S ? !1 : d.keepDirty ? t.isDirty : !!(d.keepDefaultValues && !le(l, s)),
|
|
1330
1330
|
isSubmitted: d.keepIsSubmitted ? t.isSubmitted : !1,
|
|
1331
|
-
dirtyFields: S ? {} : d.keepDirtyValues ? d.keepDefaultValues && n ?
|
|
1331
|
+
dirtyFields: S ? {} : d.keepDirtyValues ? d.keepDefaultValues && n ? ke(s, n) : t.dirtyFields : d.keepDefaultValues && l ? ke(s, l) : d.keepDirty ? t.dirtyFields : {},
|
|
1332
1332
|
touchedFields: d.keepTouched ? t.touchedFields : {},
|
|
1333
1333
|
errors: d.keepErrors ? t.errors : {},
|
|
1334
1334
|
isSubmitSuccessful: d.keepIsSubmitSuccessful ? t.isSubmitSuccessful : !1,
|
|
1335
1335
|
isSubmitting: !1,
|
|
1336
1336
|
defaultValues: s
|
|
1337
1337
|
});
|
|
1338
|
-
},
|
|
1338
|
+
}, $t = (l, d) => Nt(ce(l) ? l(n) : l, d), Rr = (l, d = {}) => {
|
|
1339
1339
|
const h = w(o, l), x = h && h._f;
|
|
1340
1340
|
if (x) {
|
|
1341
1341
|
const S = x.refs ? x.refs[0] : x.ref;
|
|
1342
1342
|
S.focus && (S.focus(), d.shouldSelect && ce(S.select) && S.select());
|
|
1343
1343
|
}
|
|
1344
|
-
},
|
|
1344
|
+
}, Or = (l) => {
|
|
1345
1345
|
t = {
|
|
1346
1346
|
...t,
|
|
1347
1347
|
...l
|
|
1348
1348
|
};
|
|
1349
|
-
},
|
|
1349
|
+
}, Lt = {
|
|
1350
1350
|
control: {
|
|
1351
|
-
register:
|
|
1352
|
-
unregister:
|
|
1353
|
-
getFieldState:
|
|
1354
|
-
handleSubmit:
|
|
1355
|
-
setError:
|
|
1356
|
-
_subscribe:
|
|
1357
|
-
_runSchema:
|
|
1358
|
-
_focusError:
|
|
1351
|
+
register: Ge,
|
|
1352
|
+
unregister: qe,
|
|
1353
|
+
getFieldState: Ct,
|
|
1354
|
+
handleSubmit: Et,
|
|
1355
|
+
setError: Ft,
|
|
1356
|
+
_subscribe: Vt,
|
|
1357
|
+
_runSchema: M,
|
|
1358
|
+
_focusError: Ze,
|
|
1359
1359
|
_getWatch: L,
|
|
1360
1360
|
_getDirty: q,
|
|
1361
1361
|
_setValid: _,
|
|
1362
1362
|
_setFieldArray: V,
|
|
1363
|
-
_setDisabledField:
|
|
1363
|
+
_setDisabledField: zt,
|
|
1364
1364
|
_setErrors: F,
|
|
1365
1365
|
_getFieldArray: A,
|
|
1366
|
-
_reset:
|
|
1366
|
+
_reset: Nt,
|
|
1367
1367
|
_resetDefaultValues: () => ce(r.defaultValues) && r.defaultValues().then((l) => {
|
|
1368
|
-
|
|
1368
|
+
$t(l, r.resetOptions), m.state.next({
|
|
1369
1369
|
isLoading: !1
|
|
1370
1370
|
});
|
|
1371
1371
|
}),
|
|
1372
|
-
_removeUnmounted:
|
|
1372
|
+
_removeUnmounted: K,
|
|
1373
1373
|
_disableForm: Br,
|
|
1374
1374
|
_subjects: m,
|
|
1375
1375
|
_proxyFormState: u,
|
|
@@ -1407,27 +1407,27 @@ function xo(e = {}) {
|
|
|
1407
1407
|
};
|
|
1408
1408
|
}
|
|
1409
1409
|
},
|
|
1410
|
-
subscribe:
|
|
1410
|
+
subscribe: Mr,
|
|
1411
1411
|
trigger: ve,
|
|
1412
|
-
register:
|
|
1413
|
-
handleSubmit:
|
|
1414
|
-
watch:
|
|
1415
|
-
setValue:
|
|
1416
|
-
getValues:
|
|
1417
|
-
reset:
|
|
1418
|
-
resetField:
|
|
1419
|
-
clearErrors:
|
|
1420
|
-
unregister:
|
|
1421
|
-
setError:
|
|
1412
|
+
register: Ge,
|
|
1413
|
+
handleSubmit: Et,
|
|
1414
|
+
watch: Pr,
|
|
1415
|
+
setValue: Q,
|
|
1416
|
+
getValues: Pe,
|
|
1417
|
+
reset: $t,
|
|
1418
|
+
resetField: Dr,
|
|
1419
|
+
clearErrors: Ar,
|
|
1420
|
+
unregister: qe,
|
|
1421
|
+
setError: Ft,
|
|
1422
1422
|
setFocus: Rr,
|
|
1423
|
-
getFieldState:
|
|
1423
|
+
getFieldState: Ct
|
|
1424
1424
|
};
|
|
1425
1425
|
return {
|
|
1426
|
-
|
|
1427
|
-
formControl:
|
|
1426
|
+
...Lt,
|
|
1427
|
+
formControl: Lt
|
|
1428
1428
|
};
|
|
1429
1429
|
}
|
|
1430
|
-
function
|
|
1430
|
+
function Fo(e = {}) {
|
|
1431
1431
|
const r = N.useRef(void 0), t = N.useRef(void 0), [o, s] = N.useState({
|
|
1432
1432
|
isDirty: !1,
|
|
1433
1433
|
isValidating: !1,
|
|
@@ -1452,14 +1452,14 @@ function Co(e = {}) {
|
|
|
1452
1452
|
formState: o
|
|
1453
1453
|
}, e.defaultValues && !ce(e.defaultValues) && e.formControl.reset(e.defaultValues, e.resetOptions);
|
|
1454
1454
|
else {
|
|
1455
|
-
const { formControl: a, ...i } =
|
|
1455
|
+
const { formControl: a, ...i } = Co(e);
|
|
1456
1456
|
r.current = {
|
|
1457
1457
|
...i,
|
|
1458
1458
|
formState: o
|
|
1459
1459
|
};
|
|
1460
1460
|
}
|
|
1461
1461
|
const n = r.current.control;
|
|
1462
|
-
return n._options = e,
|
|
1462
|
+
return n._options = e, St(() => {
|
|
1463
1463
|
const a = n._subscribe({
|
|
1464
1464
|
formState: n._proxyFormState,
|
|
1465
1465
|
callback: () => s({ ...n._formState }),
|
|
@@ -1491,37 +1491,37 @@ function Co(e = {}) {
|
|
|
1491
1491
|
}), t.current = e.values, s((a) => ({ ...a }))) : n._resetDefaultValues();
|
|
1492
1492
|
}, [n, e.values]), N.useEffect(() => {
|
|
1493
1493
|
n._state.mount || (n._setValid(), n._state.mount = !0), n._state.watch && (n._state.watch = !1, n._subjects.state.next({ ...n._formState })), n._removeUnmounted();
|
|
1494
|
-
}), r.current.formState =
|
|
1494
|
+
}), r.current.formState = fr(o, n), r.current;
|
|
1495
1495
|
}
|
|
1496
|
-
const
|
|
1496
|
+
const Zt = (e, r, t) => {
|
|
1497
1497
|
if (e && "reportValidity" in e) {
|
|
1498
1498
|
const o = w(t, r);
|
|
1499
1499
|
e.setCustomValidity(o && o.message || ""), e.reportValidity();
|
|
1500
1500
|
}
|
|
1501
|
-
},
|
|
1501
|
+
}, yt = (e, r) => {
|
|
1502
1502
|
for (const t in r.fields) {
|
|
1503
1503
|
const o = r.fields[t];
|
|
1504
|
-
o && o.ref && "reportValidity" in o.ref ?
|
|
1504
|
+
o && o.ref && "reportValidity" in o.ref ? Zt(o.ref, t, e) : o && o.refs && o.refs.forEach((s) => Zt(s, t, e));
|
|
1505
1505
|
}
|
|
1506
|
-
},
|
|
1507
|
-
r.shouldUseNativeValidation &&
|
|
1506
|
+
}, Kt = (e, r) => {
|
|
1507
|
+
r.shouldUseNativeValidation && yt(e, r);
|
|
1508
1508
|
const t = {};
|
|
1509
1509
|
for (const o in e) {
|
|
1510
1510
|
const s = w(r.fields, o), n = Object.assign(e[o] || {}, { ref: s && s.ref });
|
|
1511
|
-
if (
|
|
1511
|
+
if (Vo(r.names || Object.keys(e), o)) {
|
|
1512
1512
|
const a = Object.assign({}, w(t, o));
|
|
1513
|
-
|
|
1514
|
-
} else
|
|
1513
|
+
H(a, "root", n), H(t, o, a);
|
|
1514
|
+
} else H(t, o, n);
|
|
1515
1515
|
}
|
|
1516
1516
|
return t;
|
|
1517
|
-
},
|
|
1517
|
+
}, Vo = (e, r) => {
|
|
1518
1518
|
const t = Qt(r);
|
|
1519
1519
|
return e.some((o) => Qt(o).match(`^${t}\\.\\d+`));
|
|
1520
1520
|
};
|
|
1521
1521
|
function Qt(e) {
|
|
1522
1522
|
return e.replace(/\]|\[/g, "");
|
|
1523
1523
|
}
|
|
1524
|
-
function
|
|
1524
|
+
function vr(e, r, t) {
|
|
1525
1525
|
function o(i, f) {
|
|
1526
1526
|
var c;
|
|
1527
1527
|
Object.defineProperty(i, "_zod", {
|
|
@@ -1551,62 +1551,62 @@ function gr(e, r, t) {
|
|
|
1551
1551
|
}
|
|
1552
1552
|
}), Object.defineProperty(a, "name", { value: e }), a;
|
|
1553
1553
|
}
|
|
1554
|
-
class
|
|
1554
|
+
class zo extends Error {
|
|
1555
1555
|
constructor() {
|
|
1556
1556
|
super("Encountered Promise during synchronous parse. Use .parseAsync() instead.");
|
|
1557
1557
|
}
|
|
1558
1558
|
}
|
|
1559
|
-
const
|
|
1560
|
-
function
|
|
1561
|
-
return
|
|
1559
|
+
const Eo = {};
|
|
1560
|
+
function br(e) {
|
|
1561
|
+
return Eo;
|
|
1562
1562
|
}
|
|
1563
|
-
function
|
|
1563
|
+
function No(e, r) {
|
|
1564
1564
|
return typeof r == "bigint" ? r.toString() : r;
|
|
1565
1565
|
}
|
|
1566
|
-
const
|
|
1566
|
+
const Sr = "captureStackTrace" in Error ? Error.captureStackTrace : (...e) => {
|
|
1567
1567
|
};
|
|
1568
|
-
function
|
|
1568
|
+
function Oe(e) {
|
|
1569
1569
|
return typeof e == "string" ? e : e == null ? void 0 : e.message;
|
|
1570
1570
|
}
|
|
1571
|
-
function
|
|
1571
|
+
function wr(e, r, t) {
|
|
1572
1572
|
var s, n, a, i, f, c;
|
|
1573
1573
|
const o = { ...e, path: e.path ?? [] };
|
|
1574
1574
|
if (!e.message) {
|
|
1575
|
-
const u =
|
|
1575
|
+
const u = Oe((a = (n = (s = e.inst) == null ? void 0 : s._zod.def) == null ? void 0 : n.error) == null ? void 0 : a.call(n, e)) ?? Oe((i = r == null ? void 0 : r.error) == null ? void 0 : i.call(r, e)) ?? Oe((f = t.customError) == null ? void 0 : f.call(t, e)) ?? Oe((c = t.localeError) == null ? void 0 : c.call(t, e)) ?? "Invalid input";
|
|
1576
1576
|
o.message = u;
|
|
1577
1577
|
}
|
|
1578
1578
|
return delete o.inst, delete o.continue, r != null && r.reportInput || delete o.input, o;
|
|
1579
1579
|
}
|
|
1580
|
-
const
|
|
1580
|
+
const kr = (e, r) => {
|
|
1581
1581
|
e.name = "$ZodError", Object.defineProperty(e, "_zod", {
|
|
1582
1582
|
value: e._zod,
|
|
1583
1583
|
enumerable: !1
|
|
1584
1584
|
}), Object.defineProperty(e, "issues", {
|
|
1585
1585
|
value: r,
|
|
1586
1586
|
enumerable: !1
|
|
1587
|
-
}), e.message = JSON.stringify(r,
|
|
1587
|
+
}), e.message = JSON.stringify(r, No, 2), Object.defineProperty(e, "toString", {
|
|
1588
1588
|
value: () => e.message,
|
|
1589
1589
|
enumerable: !1
|
|
1590
1590
|
});
|
|
1591
|
-
},
|
|
1591
|
+
}, $o = vr("$ZodError", kr), xr = vr("$ZodError", kr, { Parent: Error }), Lo = (e) => (r, t, o, s) => {
|
|
1592
1592
|
const n = o ? Object.assign(o, { async: !1 }) : { async: !1 }, a = r._zod.run({ value: t, issues: [] }, n);
|
|
1593
1593
|
if (a instanceof Promise)
|
|
1594
|
-
throw new
|
|
1594
|
+
throw new zo();
|
|
1595
1595
|
if (a.issues.length) {
|
|
1596
|
-
const i = new ((s == null ? void 0 : s.Err) ?? e)(a.issues.map((f) =>
|
|
1597
|
-
throw
|
|
1596
|
+
const i = new ((s == null ? void 0 : s.Err) ?? e)(a.issues.map((f) => wr(f, n, br())));
|
|
1597
|
+
throw Sr(i, s == null ? void 0 : s.callee), i;
|
|
1598
1598
|
}
|
|
1599
1599
|
return a.value;
|
|
1600
|
-
},
|
|
1600
|
+
}, Ao = /* @__PURE__ */ Lo(xr), Po = (e) => async (r, t, o, s) => {
|
|
1601
1601
|
const n = o ? Object.assign(o, { async: !0 }) : { async: !0 };
|
|
1602
1602
|
let a = r._zod.run({ value: t, issues: [] }, n);
|
|
1603
1603
|
if (a instanceof Promise && (a = await a), a.issues.length) {
|
|
1604
|
-
const i = new ((s == null ? void 0 : s.Err) ?? e)(a.issues.map((f) =>
|
|
1605
|
-
throw
|
|
1604
|
+
const i = new ((s == null ? void 0 : s.Err) ?? e)(a.issues.map((f) => wr(f, n, br())));
|
|
1605
|
+
throw Sr(i, s == null ? void 0 : s.callee), i;
|
|
1606
1606
|
}
|
|
1607
1607
|
return a.value;
|
|
1608
|
-
},
|
|
1609
|
-
function
|
|
1608
|
+
}, Mo = /* @__PURE__ */ Po(xr);
|
|
1609
|
+
function Xt(e, r) {
|
|
1610
1610
|
try {
|
|
1611
1611
|
var t = e();
|
|
1612
1612
|
} catch (o) {
|
|
@@ -1627,13 +1627,13 @@ function Bo(e, r) {
|
|
|
1627
1627
|
});
|
|
1628
1628
|
}), r) {
|
|
1629
1629
|
var f = t[a].types, c = f && f[o.code];
|
|
1630
|
-
t[a] =
|
|
1630
|
+
t[a] = wt(a, r, t, s, c ? [].concat(c, o.message) : o.message);
|
|
1631
1631
|
}
|
|
1632
1632
|
e.shift();
|
|
1633
1633
|
}
|
|
1634
1634
|
return t;
|
|
1635
1635
|
}
|
|
1636
|
-
function
|
|
1636
|
+
function Do(e, r) {
|
|
1637
1637
|
for (var t = {}; e.length; ) {
|
|
1638
1638
|
var o = e[0], s = o.code, n = o.message, a = o.path.join(".");
|
|
1639
1639
|
if (!t[a]) if (o.code === "invalid_union" && o.errors.length > 0) {
|
|
@@ -1646,7 +1646,7 @@ function Mo(e, r) {
|
|
|
1646
1646
|
});
|
|
1647
1647
|
}), r) {
|
|
1648
1648
|
var f = t[a].types, c = f && f[o.code];
|
|
1649
|
-
t[a] =
|
|
1649
|
+
t[a] = wt(a, r, t, s, c ? [].concat(c, o.message) : o.message);
|
|
1650
1650
|
}
|
|
1651
1651
|
e.shift();
|
|
1652
1652
|
}
|
|
@@ -1657,14 +1657,14 @@ function Ro(e, r, t) {
|
|
|
1657
1657
|
return "_def" in o && typeof o._def == "object" && "typeName" in o._def;
|
|
1658
1658
|
})(e)) return function(o, s, n) {
|
|
1659
1659
|
try {
|
|
1660
|
-
return Promise.resolve(
|
|
1660
|
+
return Promise.resolve(Xt(function() {
|
|
1661
1661
|
return Promise.resolve(e[t.mode === "sync" ? "parse" : "parseAsync"](o, r)).then(function(a) {
|
|
1662
|
-
return n.shouldUseNativeValidation &&
|
|
1662
|
+
return n.shouldUseNativeValidation && yt({}, n), { errors: {}, values: t.raw ? Object.assign({}, o) : a };
|
|
1663
1663
|
});
|
|
1664
1664
|
}, function(a) {
|
|
1665
1665
|
if ((function(i) {
|
|
1666
1666
|
return Array.isArray(i == null ? void 0 : i.issues);
|
|
1667
|
-
})(a)) return { values: {}, errors:
|
|
1667
|
+
})(a)) return { values: {}, errors: Kt(Bo(a.errors, !n.shouldUseNativeValidation && n.criteriaMode === "all"), n) };
|
|
1668
1668
|
throw a;
|
|
1669
1669
|
}));
|
|
1670
1670
|
} catch (a) {
|
|
@@ -1675,14 +1675,14 @@ function Ro(e, r, t) {
|
|
|
1675
1675
|
return "_zod" in o && typeof o._zod == "object";
|
|
1676
1676
|
})(e)) return function(o, s, n) {
|
|
1677
1677
|
try {
|
|
1678
|
-
return Promise.resolve(
|
|
1679
|
-
return Promise.resolve((t.mode === "sync" ?
|
|
1680
|
-
return n.shouldUseNativeValidation &&
|
|
1678
|
+
return Promise.resolve(Xt(function() {
|
|
1679
|
+
return Promise.resolve((t.mode === "sync" ? Ao : Mo)(e, o, r)).then(function(a) {
|
|
1680
|
+
return n.shouldUseNativeValidation && yt({}, n), { errors: {}, values: t.raw ? Object.assign({}, o) : a };
|
|
1681
1681
|
});
|
|
1682
1682
|
}, function(a) {
|
|
1683
1683
|
if ((function(i) {
|
|
1684
|
-
return i instanceof
|
|
1685
|
-
})(a)) return { values: {}, errors:
|
|
1684
|
+
return i instanceof $o;
|
|
1685
|
+
})(a)) return { values: {}, errors: Kt(Do(a.issues, !n.shouldUseNativeValidation && n.criteriaMode === "all"), n) };
|
|
1686
1686
|
throw a;
|
|
1687
1687
|
}));
|
|
1688
1688
|
} catch (a) {
|
|
@@ -1691,14 +1691,14 @@ function Ro(e, r, t) {
|
|
|
1691
1691
|
};
|
|
1692
1692
|
throw new Error("Invalid input: not a Zod schema");
|
|
1693
1693
|
}
|
|
1694
|
-
const
|
|
1695
|
-
function
|
|
1696
|
-
const e = N.useContext(
|
|
1694
|
+
const Cr = N.createContext(null);
|
|
1695
|
+
function Oo() {
|
|
1696
|
+
const e = N.useContext(Cr);
|
|
1697
1697
|
if (!e)
|
|
1698
1698
|
throw new Error("useFormContext must be used within a Form component");
|
|
1699
1699
|
return e;
|
|
1700
1700
|
}
|
|
1701
|
-
function
|
|
1701
|
+
function Io({
|
|
1702
1702
|
onSubmit: e,
|
|
1703
1703
|
children: r,
|
|
1704
1704
|
schema: t,
|
|
@@ -1709,17 +1709,17 @@ function Oo({
|
|
|
1709
1709
|
style: i,
|
|
1710
1710
|
formProps: f
|
|
1711
1711
|
}) {
|
|
1712
|
-
const c =
|
|
1712
|
+
const c = Fo({
|
|
1713
1713
|
resolver: t ? Ro(t) : void 0,
|
|
1714
1714
|
defaultValues: o,
|
|
1715
1715
|
mode: s,
|
|
1716
1716
|
reValidateMode: n
|
|
1717
1717
|
}), u = c.handleSubmit(e);
|
|
1718
|
-
return /* @__PURE__ */ p(
|
|
1718
|
+
return /* @__PURE__ */ p(Cr.Provider, { value: c, children: /* @__PURE__ */ p("form", { ...f, className: a, style: i, onSubmit: u, children: typeof r == "function" ? r(c) : r }) });
|
|
1719
1719
|
}
|
|
1720
|
-
const
|
|
1721
|
-
formError:
|
|
1722
|
-
},
|
|
1720
|
+
const ca = Io, To = "FormError-module__formError___kaUBn", Ho = {
|
|
1721
|
+
formError: To
|
|
1722
|
+
}, jo = ({
|
|
1723
1723
|
// Color prop
|
|
1724
1724
|
color: e,
|
|
1725
1725
|
// Content
|
|
@@ -1730,20 +1730,20 @@ const oa = Oo, Io = "FormError-module__formError___kaUBn", To = {
|
|
|
1730
1730
|
// Element-specific props
|
|
1731
1731
|
divProps: s
|
|
1732
1732
|
}) => {
|
|
1733
|
-
const n =
|
|
1733
|
+
const n = R(), a = {
|
|
1734
1734
|
"--form-error-margin-top": `calc(${n.fonts.rhythm} * 0.17)`,
|
|
1735
1735
|
color: e || n.colors.error,
|
|
1736
1736
|
...o
|
|
1737
1737
|
// Top level style prop overrides
|
|
1738
|
-
}, i = [
|
|
1738
|
+
}, i = [Ho.formError, t].filter(Boolean).join(" ");
|
|
1739
1739
|
return /* @__PURE__ */ p("div", { ...s, className: i, style: a, role: "alert", "aria-live": "polite", children: r });
|
|
1740
|
-
},
|
|
1741
|
-
formGroup:
|
|
1740
|
+
}, Wo = "FormGroup-module__formGroup___aVI-B", Uo = "FormGroup-module__inputWrapper___429QE", qo = "FormGroup-module__indented___t61iz", Go = "FormGroup-module__disabled___W-tJ0", Zo = "FormGroup-module__required___mO3xA", Se = {
|
|
1741
|
+
formGroup: Wo,
|
|
1742
1742
|
inputWrapper: Uo,
|
|
1743
|
-
indented:
|
|
1744
|
-
disabled:
|
|
1745
|
-
required:
|
|
1746
|
-
},
|
|
1743
|
+
indented: qo,
|
|
1744
|
+
disabled: Go,
|
|
1745
|
+
required: Zo
|
|
1746
|
+
}, Ko = ({
|
|
1747
1747
|
// State props
|
|
1748
1748
|
disabled: e = !1,
|
|
1749
1749
|
error: r = !1,
|
|
@@ -1763,7 +1763,7 @@ const oa = Oo, Io = "FormError-module__formError___kaUBn", To = {
|
|
|
1763
1763
|
// Element-specific props
|
|
1764
1764
|
divProps: y
|
|
1765
1765
|
}) => {
|
|
1766
|
-
const m =
|
|
1766
|
+
const m = R(), C = [
|
|
1767
1767
|
Se.formGroup,
|
|
1768
1768
|
r ? Se.error : "",
|
|
1769
1769
|
e ? Se.disabled : "",
|
|
@@ -1779,16 +1779,16 @@ const oa = Oo, Io = "FormError-module__formError___kaUBn", To = {
|
|
|
1779
1779
|
}
|
|
1780
1780
|
return k;
|
|
1781
1781
|
});
|
|
1782
|
-
return /* @__PURE__ */
|
|
1783
|
-
n && /* @__PURE__ */
|
|
1782
|
+
return /* @__PURE__ */ D("div", { ...y, className: C, style: b, children: [
|
|
1783
|
+
n && /* @__PURE__ */ D(_t, { htmlFor: s, disabled: e, error: r, ...i, children: [
|
|
1784
1784
|
n,
|
|
1785
|
-
t && /* @__PURE__ */
|
|
1785
|
+
t && /* @__PURE__ */ D("span", { className: Se.required, "aria-label": "required", children: [
|
|
1786
1786
|
" ",
|
|
1787
1787
|
"*"
|
|
1788
1788
|
] })
|
|
1789
1789
|
] }),
|
|
1790
1790
|
/* @__PURE__ */ p("div", { className: `${Se.inputWrapper} ${o ? Se.indented : ""}`, children: _ }),
|
|
1791
|
-
r && a && /* @__PURE__ */ p(
|
|
1791
|
+
r && a && /* @__PURE__ */ p(jo, { children: a })
|
|
1792
1792
|
] });
|
|
1793
1793
|
};
|
|
1794
1794
|
function ge({
|
|
@@ -1803,16 +1803,16 @@ function ge({
|
|
|
1803
1803
|
indent: f,
|
|
1804
1804
|
labelProps: c
|
|
1805
1805
|
}) {
|
|
1806
|
-
const { control: u } =
|
|
1806
|
+
const { control: u } = Oo(), {
|
|
1807
1807
|
field: y,
|
|
1808
1808
|
fieldState: { error: m }
|
|
1809
|
-
} =
|
|
1809
|
+
} = uo({
|
|
1810
1810
|
name: e,
|
|
1811
1811
|
control: u,
|
|
1812
1812
|
rules: s
|
|
1813
1813
|
});
|
|
1814
1814
|
return /* @__PURE__ */ p(
|
|
1815
|
-
|
|
1815
|
+
Ko,
|
|
1816
1816
|
{
|
|
1817
1817
|
label: r,
|
|
1818
1818
|
name: e,
|
|
@@ -1835,11 +1835,11 @@ function ge({
|
|
|
1835
1835
|
}
|
|
1836
1836
|
);
|
|
1837
1837
|
}
|
|
1838
|
-
const Qo = "Input-module__input___WjT81",
|
|
1838
|
+
const Qo = "Input-module__input___WjT81", Xo = "Input-module__sizeSmall___NFvsi", Jo = "Input-module__sizeLarge___4Boj3", et = {
|
|
1839
1839
|
input: Qo,
|
|
1840
|
-
sizeSmall:
|
|
1841
|
-
sizeLarge:
|
|
1842
|
-
},
|
|
1840
|
+
sizeSmall: Xo,
|
|
1841
|
+
sizeLarge: Jo
|
|
1842
|
+
}, Yo = ({
|
|
1843
1843
|
color: e = "#000",
|
|
1844
1844
|
disabled: r = !1,
|
|
1845
1845
|
fontSize: t = "1em",
|
|
@@ -1850,7 +1850,7 @@ const Qo = "Input-module__input___WjT81", Ko = "Input-module__sizeSmall___NFvsi"
|
|
|
1850
1850
|
fontSize: t,
|
|
1851
1851
|
opacity: r ? 0.3 : 1,
|
|
1852
1852
|
placeholderOpacity: o
|
|
1853
|
-
}),
|
|
1853
|
+
}), es = ({
|
|
1854
1854
|
// State props
|
|
1855
1855
|
disabled: e = !1,
|
|
1856
1856
|
error: r = !1,
|
|
@@ -1874,7 +1874,7 @@ const Qo = "Input-module__input___WjT81", Ko = "Input-module__sizeSmall___NFvsi"
|
|
|
1874
1874
|
// Element-specific props
|
|
1875
1875
|
inputProps: b
|
|
1876
1876
|
}) => {
|
|
1877
|
-
const _ =
|
|
1877
|
+
const _ = R(), k = _.colors.error, V = r ? k : t || _.colors.primary, g = Yo({
|
|
1878
1878
|
color: V,
|
|
1879
1879
|
disabled: e,
|
|
1880
1880
|
fontSize: _.fonts.size,
|
|
@@ -1892,8 +1892,8 @@ const Qo = "Input-module__input___WjT81", Ko = "Input-module__sizeSmall___NFvsi"
|
|
|
1892
1892
|
...C
|
|
1893
1893
|
// Top level style prop overrides
|
|
1894
1894
|
}, z = [
|
|
1895
|
-
|
|
1896
|
-
o === "small" ?
|
|
1895
|
+
et.input,
|
|
1896
|
+
o === "small" ? et.sizeSmall : et.sizeLarge,
|
|
1897
1897
|
m
|
|
1898
1898
|
].filter(Boolean).join(" ");
|
|
1899
1899
|
return /* @__PURE__ */ p(
|
|
@@ -1913,7 +1913,7 @@ const Qo = "Input-module__input___WjT81", Ko = "Input-module__sizeSmall___NFvsi"
|
|
|
1913
1913
|
}
|
|
1914
1914
|
);
|
|
1915
1915
|
};
|
|
1916
|
-
function
|
|
1916
|
+
function ua({
|
|
1917
1917
|
name: e,
|
|
1918
1918
|
label: r,
|
|
1919
1919
|
required: t,
|
|
@@ -1934,7 +1934,7 @@ function sa({
|
|
|
1934
1934
|
className: n,
|
|
1935
1935
|
style: a,
|
|
1936
1936
|
children: ({ value: f, onChange: c, onBlur: u, name: y, error: m }) => /* @__PURE__ */ p(
|
|
1937
|
-
|
|
1937
|
+
es,
|
|
1938
1938
|
{
|
|
1939
1939
|
...i,
|
|
1940
1940
|
name: y,
|
|
@@ -1947,11 +1947,11 @@ function sa({
|
|
|
1947
1947
|
}
|
|
1948
1948
|
);
|
|
1949
1949
|
}
|
|
1950
|
-
const
|
|
1951
|
-
textarea:
|
|
1952
|
-
sizeSmall:
|
|
1953
|
-
sizeLarge:
|
|
1954
|
-
},
|
|
1950
|
+
const ts = "Textarea-module__textarea___Z-y6g", rs = "Textarea-module__sizeSmall___HHFEM", os = "Textarea-module__sizeLarge___5a3sf", tt = {
|
|
1951
|
+
textarea: ts,
|
|
1952
|
+
sizeSmall: rs,
|
|
1953
|
+
sizeLarge: os
|
|
1954
|
+
}, ss = ({
|
|
1955
1955
|
color: e = "#000",
|
|
1956
1956
|
disabled: r = !1,
|
|
1957
1957
|
placeholderOpacity: t = 0.3
|
|
@@ -1960,7 +1960,7 @@ const es = "Textarea-module__textarea___Z-y6g", ts = "Textarea-module__sizeSmall
|
|
|
1960
1960
|
borderColor: e,
|
|
1961
1961
|
opacity: r ? 0.3 : 1,
|
|
1962
1962
|
placeholderOpacity: t
|
|
1963
|
-
}),
|
|
1963
|
+
}), ns = ({
|
|
1964
1964
|
// State props
|
|
1965
1965
|
disabled: e = !1,
|
|
1966
1966
|
error: r = !1,
|
|
@@ -1984,7 +1984,7 @@ const es = "Textarea-module__textarea___Z-y6g", ts = "Textarea-module__sizeSmall
|
|
|
1984
1984
|
// Element-specific props
|
|
1985
1985
|
textareaProps: b
|
|
1986
1986
|
}) => {
|
|
1987
|
-
const _ =
|
|
1987
|
+
const _ = R(), k = _.colors.error, V = r ? k : t || _.colors.primary, g = ss({
|
|
1988
1988
|
color: V,
|
|
1989
1989
|
disabled: e,
|
|
1990
1990
|
placeholderOpacity: i
|
|
@@ -2001,8 +2001,8 @@ const es = "Textarea-module__textarea___Z-y6g", ts = "Textarea-module__sizeSmall
|
|
|
2001
2001
|
...C
|
|
2002
2002
|
// Top level style overrides
|
|
2003
2003
|
}, z = [
|
|
2004
|
-
|
|
2005
|
-
o === "small" ?
|
|
2004
|
+
tt.textarea,
|
|
2005
|
+
o === "small" ? tt.sizeSmall : tt.sizeLarge,
|
|
2006
2006
|
m
|
|
2007
2007
|
].filter(Boolean).join(" ");
|
|
2008
2008
|
return /* @__PURE__ */ p(
|
|
@@ -2022,7 +2022,7 @@ const es = "Textarea-module__textarea___Z-y6g", ts = "Textarea-module__sizeSmall
|
|
|
2022
2022
|
}
|
|
2023
2023
|
);
|
|
2024
2024
|
};
|
|
2025
|
-
function
|
|
2025
|
+
function da({
|
|
2026
2026
|
name: e,
|
|
2027
2027
|
label: r,
|
|
2028
2028
|
required: t,
|
|
@@ -2043,7 +2043,7 @@ function na({
|
|
|
2043
2043
|
className: n,
|
|
2044
2044
|
style: a,
|
|
2045
2045
|
children: ({ value: f, onChange: c, onBlur: u, name: y, error: m }) => /* @__PURE__ */ p(
|
|
2046
|
-
|
|
2046
|
+
ns,
|
|
2047
2047
|
{
|
|
2048
2048
|
...i,
|
|
2049
2049
|
name: y,
|
|
@@ -2056,11 +2056,11 @@ function na({
|
|
|
2056
2056
|
}
|
|
2057
2057
|
);
|
|
2058
2058
|
}
|
|
2059
|
-
const
|
|
2060
|
-
select:
|
|
2061
|
-
sizeSmall:
|
|
2062
|
-
sizeLarge:
|
|
2063
|
-
},
|
|
2059
|
+
const as = "Select-module__select___cjdcr", is = "Select-module__sizeSmall___i1quj", ls = "Select-module__sizeLarge___eBA1T", rt = {
|
|
2060
|
+
select: as,
|
|
2061
|
+
sizeSmall: is,
|
|
2062
|
+
sizeLarge: ls
|
|
2063
|
+
}, cs = ({
|
|
2064
2064
|
color: e = "#000",
|
|
2065
2065
|
disabled: r = !1
|
|
2066
2066
|
}) => ({
|
|
@@ -2087,7 +2087,7 @@ const ns = "Select-module__select___cjdcr", as = "Select-module__sizeSmall___i1q
|
|
|
2087
2087
|
`.trim();
|
|
2088
2088
|
return `url("data:image/svg+xml,${encodeURIComponent(a)}")`;
|
|
2089
2089
|
})(e)
|
|
2090
|
-
}),
|
|
2090
|
+
}), us = ({
|
|
2091
2091
|
// State props
|
|
2092
2092
|
disabled: e = !1,
|
|
2093
2093
|
error: r = !1,
|
|
@@ -2110,7 +2110,7 @@ const ns = "Select-module__select___cjdcr", as = "Select-module__sizeSmall___i1q
|
|
|
2110
2110
|
// Element-specific props
|
|
2111
2111
|
selectProps: C
|
|
2112
2112
|
}) => {
|
|
2113
|
-
const b =
|
|
2113
|
+
const b = R(), _ = b.colors.error, k = r ? _ : t || b.colors.primary, V = cs({
|
|
2114
2114
|
color: k,
|
|
2115
2115
|
disabled: e
|
|
2116
2116
|
}), g = {
|
|
@@ -2131,11 +2131,11 @@ const ns = "Select-module__select___cjdcr", as = "Select-module__sizeSmall___i1q
|
|
|
2131
2131
|
...m
|
|
2132
2132
|
// Top level style overrides
|
|
2133
2133
|
}, F = [
|
|
2134
|
-
|
|
2135
|
-
o === "small" ?
|
|
2134
|
+
rt.select,
|
|
2135
|
+
o === "small" ? rt.sizeSmall : rt.sizeLarge,
|
|
2136
2136
|
y
|
|
2137
2137
|
].filter(Boolean).join(" ");
|
|
2138
|
-
return /* @__PURE__ */
|
|
2138
|
+
return /* @__PURE__ */ D(
|
|
2139
2139
|
"select",
|
|
2140
2140
|
{
|
|
2141
2141
|
...C,
|
|
@@ -2154,7 +2154,7 @@ const ns = "Select-module__select___cjdcr", as = "Select-module__sizeSmall___i1q
|
|
|
2154
2154
|
}
|
|
2155
2155
|
);
|
|
2156
2156
|
};
|
|
2157
|
-
function
|
|
2157
|
+
function fa({
|
|
2158
2158
|
name: e,
|
|
2159
2159
|
label: r,
|
|
2160
2160
|
required: t,
|
|
@@ -2176,7 +2176,7 @@ function aa({
|
|
|
2176
2176
|
className: n,
|
|
2177
2177
|
style: a,
|
|
2178
2178
|
children: ({ value: c, onChange: u, onBlur: y, name: m, error: C }) => /* @__PURE__ */ p(
|
|
2179
|
-
|
|
2179
|
+
us,
|
|
2180
2180
|
{
|
|
2181
2181
|
...f,
|
|
2182
2182
|
name: m,
|
|
@@ -2190,7 +2190,7 @@ function aa({
|
|
|
2190
2190
|
}
|
|
2191
2191
|
);
|
|
2192
2192
|
}
|
|
2193
|
-
function
|
|
2193
|
+
function ma({
|
|
2194
2194
|
name: e,
|
|
2195
2195
|
required: r,
|
|
2196
2196
|
rules: t,
|
|
@@ -2209,7 +2209,7 @@ function ia({
|
|
|
2209
2209
|
className: s,
|
|
2210
2210
|
style: n,
|
|
2211
2211
|
children: ({ value: i, onChange: f, name: c, error: u }) => /* @__PURE__ */ p(
|
|
2212
|
-
|
|
2212
|
+
ut,
|
|
2213
2213
|
{
|
|
2214
2214
|
...a,
|
|
2215
2215
|
name: c,
|
|
@@ -2221,18 +2221,18 @@ function ia({
|
|
|
2221
2221
|
}
|
|
2222
2222
|
);
|
|
2223
2223
|
}
|
|
2224
|
-
const
|
|
2225
|
-
container:
|
|
2226
|
-
svg:
|
|
2227
|
-
label:
|
|
2228
|
-
},
|
|
2224
|
+
const ds = "Radio-module__container___AQxhk", fs = "Radio-module__svg___zl5kF", ms = "Radio-module__label___vAFIP", ot = {
|
|
2225
|
+
container: ds,
|
|
2226
|
+
svg: fs,
|
|
2227
|
+
label: ms
|
|
2228
|
+
}, ys = ({
|
|
2229
2229
|
color: e = "#000",
|
|
2230
2230
|
disabled: r = !1
|
|
2231
2231
|
}) => ({
|
|
2232
2232
|
radioColor: e,
|
|
2233
2233
|
cursor: r ? "default" : "pointer",
|
|
2234
2234
|
opacity: r ? 0.3 : 1
|
|
2235
|
-
}),
|
|
2235
|
+
}), Fr = ({
|
|
2236
2236
|
// Color prop
|
|
2237
2237
|
color: e,
|
|
2238
2238
|
// State props
|
|
@@ -2251,11 +2251,11 @@ const us = "Radio-module__container___AQxhk", ds = "Radio-module__svg___zl5kF",
|
|
|
2251
2251
|
// Element-specific props
|
|
2252
2252
|
divProps: y
|
|
2253
2253
|
}) => {
|
|
2254
|
-
const m =
|
|
2254
|
+
const m = R(), C = n || ir(), b = m.colors.error, _ = o ? b : e || m.colors.primary, k = ys({
|
|
2255
2255
|
color: _,
|
|
2256
2256
|
disabled: t
|
|
2257
|
-
}), V = (
|
|
2258
|
-
t || a(
|
|
2257
|
+
}), V = (M) => {
|
|
2258
|
+
t || a(M);
|
|
2259
2259
|
}, g = {
|
|
2260
2260
|
cursor: k.cursor,
|
|
2261
2261
|
fontSize: m.fonts.size,
|
|
@@ -2270,8 +2270,8 @@ const us = "Radio-module__container___AQxhk", ds = "Radio-module__svg___zl5kF",
|
|
|
2270
2270
|
stroke: k.radioColor
|
|
2271
2271
|
}, E = {
|
|
2272
2272
|
fill: k.radioColor
|
|
2273
|
-
},
|
|
2274
|
-
return /* @__PURE__ */
|
|
2273
|
+
}, B = [ot.container, c].filter(Boolean).join(" ");
|
|
2274
|
+
return /* @__PURE__ */ D("div", { ...y, className: B, style: g, children: [
|
|
2275
2275
|
/* @__PURE__ */ p(
|
|
2276
2276
|
"input",
|
|
2277
2277
|
{
|
|
@@ -2279,18 +2279,18 @@ const us = "Radio-module__container___AQxhk", ds = "Radio-module__svg___zl5kF",
|
|
|
2279
2279
|
checked: r,
|
|
2280
2280
|
disabled: t,
|
|
2281
2281
|
name: s,
|
|
2282
|
-
onChange: (
|
|
2282
|
+
onChange: (M) => V({ target: { checked: M.target.checked, name: s, type: "radio" } }),
|
|
2283
2283
|
style: { display: "none" },
|
|
2284
2284
|
type: "radio"
|
|
2285
2285
|
}
|
|
2286
2286
|
),
|
|
2287
|
-
/* @__PURE__ */
|
|
2287
|
+
/* @__PURE__ */ D(
|
|
2288
2288
|
"svg",
|
|
2289
2289
|
{
|
|
2290
2290
|
xmlns: "http://www.w3.org/2000/svg",
|
|
2291
2291
|
viewBox: "0 0 100 100",
|
|
2292
2292
|
onClick: () => V({ target: { checked: !r, name: s, type: "radio" } }),
|
|
2293
|
-
className:
|
|
2293
|
+
className: ot.svg,
|
|
2294
2294
|
style: F,
|
|
2295
2295
|
children: [
|
|
2296
2296
|
/* @__PURE__ */ p("circle", { cx: "50", cy: "50", r: "42.5", width: "100%", style: z }),
|
|
@@ -2299,10 +2299,10 @@ const us = "Radio-module__container___AQxhk", ds = "Radio-module__svg___zl5kF",
|
|
|
2299
2299
|
}
|
|
2300
2300
|
),
|
|
2301
2301
|
i && /* @__PURE__ */ p(
|
|
2302
|
-
|
|
2302
|
+
_t,
|
|
2303
2303
|
{
|
|
2304
2304
|
htmlFor: C,
|
|
2305
|
-
className:
|
|
2305
|
+
className: ot.label,
|
|
2306
2306
|
style: { paddingBottom: 0, ...f },
|
|
2307
2307
|
color: k.radioColor,
|
|
2308
2308
|
disabled: t,
|
|
@@ -2312,7 +2312,7 @@ const us = "Radio-module__container___AQxhk", ds = "Radio-module__svg___zl5kF",
|
|
|
2312
2312
|
)
|
|
2313
2313
|
] });
|
|
2314
2314
|
};
|
|
2315
|
-
function
|
|
2315
|
+
function ya({
|
|
2316
2316
|
name: e,
|
|
2317
2317
|
label: r,
|
|
2318
2318
|
required: t,
|
|
@@ -2333,7 +2333,7 @@ function la({
|
|
|
2333
2333
|
className: n,
|
|
2334
2334
|
style: a,
|
|
2335
2335
|
children: ({ value: c, onChange: u, name: y, error: m }) => /* @__PURE__ */ p(
|
|
2336
|
-
|
|
2336
|
+
Fr,
|
|
2337
2337
|
{
|
|
2338
2338
|
...f,
|
|
2339
2339
|
name: y,
|
|
@@ -2346,7 +2346,7 @@ function la({
|
|
|
2346
2346
|
}
|
|
2347
2347
|
);
|
|
2348
2348
|
}
|
|
2349
|
-
function
|
|
2349
|
+
function ha({
|
|
2350
2350
|
name: e,
|
|
2351
2351
|
label: r,
|
|
2352
2352
|
required: t,
|
|
@@ -2371,8 +2371,8 @@ function ca({
|
|
|
2371
2371
|
marginBottom: ".25em"
|
|
2372
2372
|
}
|
|
2373
2373
|
},
|
|
2374
|
-
children: ({ value: f, onChange: c, name: u, error: y }) => /* @__PURE__ */ p(
|
|
2375
|
-
|
|
2374
|
+
children: ({ value: f, onChange: c, name: u, error: y }) => /* @__PURE__ */ p(Fe, { children: o.map((m) => /* @__PURE__ */ p(
|
|
2375
|
+
Fr,
|
|
2376
2376
|
{
|
|
2377
2377
|
name: u,
|
|
2378
2378
|
checked: f === m.value,
|
|
@@ -2386,7 +2386,7 @@ function ca({
|
|
|
2386
2386
|
}
|
|
2387
2387
|
);
|
|
2388
2388
|
}
|
|
2389
|
-
function
|
|
2389
|
+
function _a({
|
|
2390
2390
|
name: e,
|
|
2391
2391
|
label: r,
|
|
2392
2392
|
required: t,
|
|
@@ -2416,8 +2416,8 @@ function ua({
|
|
|
2416
2416
|
const C = Array.isArray(c) ? c : [], b = (_, k) => {
|
|
2417
2417
|
u(k ? [...C, _] : C.filter((V) => V !== _));
|
|
2418
2418
|
};
|
|
2419
|
-
return /* @__PURE__ */ p(
|
|
2420
|
-
|
|
2419
|
+
return /* @__PURE__ */ p(Fe, { children: o ? o.map((_) => /* @__PURE__ */ p(
|
|
2420
|
+
ut,
|
|
2421
2421
|
{
|
|
2422
2422
|
name: `${y}[]`,
|
|
2423
2423
|
checked: C.includes(_.value),
|
|
@@ -2428,7 +2428,7 @@ function ua({
|
|
|
2428
2428
|
},
|
|
2429
2429
|
_.value
|
|
2430
2430
|
)) : N.Children.map(s, (_) => {
|
|
2431
|
-
if (N.isValidElement(_) && _.type ===
|
|
2431
|
+
if (N.isValidElement(_) && _.type === ut) {
|
|
2432
2432
|
const k = _.props.value || _.props.name;
|
|
2433
2433
|
return N.cloneElement(_, {
|
|
2434
2434
|
name: `${y}[]`,
|
|
@@ -2444,17 +2444,17 @@ function ua({
|
|
|
2444
2444
|
}
|
|
2445
2445
|
);
|
|
2446
2446
|
}
|
|
2447
|
-
const
|
|
2448
|
-
hamburger:
|
|
2449
|
-
line:
|
|
2450
|
-
open:
|
|
2451
|
-
},
|
|
2447
|
+
const hs = "Hamburger-module__hamburger___Tf4-t", _s = "Hamburger-module__line___gybZM", ps = "Hamburger-module__open___gRswh", Ee = {
|
|
2448
|
+
hamburger: hs,
|
|
2449
|
+
line: _s,
|
|
2450
|
+
open: ps
|
|
2451
|
+
}, gs = ({
|
|
2452
2452
|
compact: e,
|
|
2453
2453
|
color: r,
|
|
2454
2454
|
visible: t,
|
|
2455
2455
|
border: o
|
|
2456
2456
|
}) => {
|
|
2457
|
-
const s =
|
|
2457
|
+
const s = R(), n = e ? "1.5em" : "2em";
|
|
2458
2458
|
return {
|
|
2459
2459
|
"--hamburger-border-radius": (o == null ? void 0 : o.radius) || s.border.radius,
|
|
2460
2460
|
color: r || "inherit",
|
|
@@ -2462,7 +2462,7 @@ const ys = "Hamburger-module__hamburger___Tf4-t", hs = "Hamburger-module__line__
|
|
|
2462
2462
|
width: n,
|
|
2463
2463
|
height: n
|
|
2464
2464
|
};
|
|
2465
|
-
},
|
|
2465
|
+
}, vs = ({
|
|
2466
2466
|
// Color props
|
|
2467
2467
|
color: e,
|
|
2468
2468
|
// State/variant props
|
|
@@ -2478,13 +2478,13 @@ const ys = "Hamburger-module__hamburger___Tf4-t", hs = "Hamburger-module__line__
|
|
|
2478
2478
|
className: i,
|
|
2479
2479
|
style: f
|
|
2480
2480
|
}) => {
|
|
2481
|
-
const c =
|
|
2481
|
+
const c = gs({
|
|
2482
2482
|
compact: t,
|
|
2483
2483
|
color: e,
|
|
2484
2484
|
visible: r,
|
|
2485
2485
|
border: n
|
|
2486
|
-
}), u = [
|
|
2487
|
-
return /* @__PURE__ */
|
|
2486
|
+
}), u = [Ee.hamburger, s ? Ee.open : "", i].filter(Boolean).join(" ");
|
|
2487
|
+
return /* @__PURE__ */ D(
|
|
2488
2488
|
"button",
|
|
2489
2489
|
{
|
|
2490
2490
|
ref: o,
|
|
@@ -2494,16 +2494,16 @@ const ys = "Hamburger-module__hamburger___Tf4-t", hs = "Hamburger-module__line__
|
|
|
2494
2494
|
"aria-label": "Toggle menu",
|
|
2495
2495
|
"aria-expanded": s,
|
|
2496
2496
|
children: [
|
|
2497
|
-
/* @__PURE__ */ p("div", { className:
|
|
2498
|
-
/* @__PURE__ */ p("div", { className:
|
|
2499
|
-
/* @__PURE__ */ p("div", { className:
|
|
2497
|
+
/* @__PURE__ */ p("div", { className: Ee.line }),
|
|
2498
|
+
/* @__PURE__ */ p("div", { className: Ee.line }),
|
|
2499
|
+
/* @__PURE__ */ p("div", { className: Ee.line })
|
|
2500
2500
|
]
|
|
2501
2501
|
}
|
|
2502
2502
|
);
|
|
2503
|
-
},
|
|
2504
|
-
header:
|
|
2505
|
-
container:
|
|
2506
|
-
},
|
|
2503
|
+
}, bs = "Header-module__header___RUooH", Ss = "Header-module__container___t68M9", Jt = {
|
|
2504
|
+
header: bs,
|
|
2505
|
+
container: Ss
|
|
2506
|
+
}, ws = ({
|
|
2507
2507
|
isSmallScreen: e = !1,
|
|
2508
2508
|
maxWidth: r,
|
|
2509
2509
|
minWidth: t,
|
|
@@ -2516,7 +2516,7 @@ const ys = "Hamburger-module__hamburger___Tf4-t", hs = "Hamburger-module__line__
|
|
|
2516
2516
|
backgroundColor: c,
|
|
2517
2517
|
color: u
|
|
2518
2518
|
} = {}) => {
|
|
2519
|
-
const y =
|
|
2519
|
+
const y = R();
|
|
2520
2520
|
return {
|
|
2521
2521
|
"--header-max-width": r || y.layout.maxWidth,
|
|
2522
2522
|
"--header-min-width": t,
|
|
@@ -2530,13 +2530,13 @@ const ys = "Hamburger-module__hamburger___Tf4-t", hs = "Hamburger-module__line__
|
|
|
2530
2530
|
};
|
|
2531
2531
|
}, ue = (e) => {
|
|
2532
2532
|
const r = typeof window < "u" && typeof window.matchMedia == "function";
|
|
2533
|
-
return
|
|
2533
|
+
return Wr((n) => {
|
|
2534
2534
|
if (!r) return () => {
|
|
2535
2535
|
};
|
|
2536
2536
|
const a = window.matchMedia(e);
|
|
2537
2537
|
return a.addEventListener("change", n), () => a.removeEventListener("change", n);
|
|
2538
2538
|
}, () => r ? window.matchMedia(e).matches : !1, () => !1);
|
|
2539
|
-
},
|
|
2539
|
+
}, ks = ({
|
|
2540
2540
|
// Color props
|
|
2541
2541
|
backgroundColor: e,
|
|
2542
2542
|
color: r,
|
|
@@ -2559,7 +2559,7 @@ const ys = "Hamburger-module__hamburger___Tf4-t", hs = "Hamburger-module__line__
|
|
|
2559
2559
|
// Element-specific props
|
|
2560
2560
|
headerProps: _
|
|
2561
2561
|
}) => {
|
|
2562
|
-
const k =
|
|
2562
|
+
const k = R(), V = u || k.breakpoints.sm, { maxWidth: g, unit: F } = Le(V), z = ue(`(max-width: ${g}${F})`), E = ws({
|
|
2563
2563
|
isSmallScreen: z,
|
|
2564
2564
|
maxWidth: t,
|
|
2565
2565
|
minWidth: o,
|
|
@@ -2571,34 +2571,34 @@ const ys = "Hamburger-module__hamburger___Tf4-t", hs = "Hamburger-module__line__
|
|
|
2571
2571
|
gap: c,
|
|
2572
2572
|
backgroundColor: e,
|
|
2573
2573
|
color: r
|
|
2574
|
-
}),
|
|
2575
|
-
return /* @__PURE__ */ p("header", { ..._, className:
|
|
2574
|
+
}), B = [Jt.container, C].filter(Boolean).join(" "), M = y ? { position: "fixed", top: 0, left: 0, right: 0, zIndex: 1e3 } : {};
|
|
2575
|
+
return /* @__PURE__ */ p("header", { ..._, className: Jt.header, style: M, children: /* @__PURE__ */ p(
|
|
2576
2576
|
"div",
|
|
2577
2577
|
{
|
|
2578
|
-
className:
|
|
2578
|
+
className: B,
|
|
2579
2579
|
style: { ...E, ...b },
|
|
2580
2580
|
children: m
|
|
2581
2581
|
}
|
|
2582
2582
|
) });
|
|
2583
|
-
},
|
|
2584
|
-
nav:
|
|
2585
|
-
navMobile:
|
|
2586
|
-
navHeader:
|
|
2587
|
-
compact:
|
|
2588
|
-
navDesktop:
|
|
2589
|
-
},
|
|
2590
|
-
triggerWrapper:
|
|
2591
|
-
popup:
|
|
2592
|
-
panelOverlay:
|
|
2593
|
-
panelOverlayVisible:
|
|
2594
|
-
backdrop:
|
|
2595
|
-
panel:
|
|
2596
|
-
panelLeft:
|
|
2583
|
+
}, xs = "ResponsiveNav-module__nav___xOfv5", Cs = "ResponsiveNav-module__navMobile___h795P", Fs = "ResponsiveNav-module__navHeader___Me8bB", Vs = "ResponsiveNav-module__compact___UhuAE", zs = "ResponsiveNav-module__navDesktop___9wscZ", xe = {
|
|
2584
|
+
nav: xs,
|
|
2585
|
+
navMobile: Cs,
|
|
2586
|
+
navHeader: Fs,
|
|
2587
|
+
compact: Vs,
|
|
2588
|
+
navDesktop: zs
|
|
2589
|
+
}, Es = "Popover-module__triggerWrapper___dZpf6", Ns = "Popover-module__popup___JAvrb", $s = "Popover-module__panelOverlay___1xDU5", Ls = "Popover-module__panelOverlayVisible___BgtIQ", As = "Popover-module__backdrop___e8qHL", Ps = "Popover-module__panel___eUJ2E", Ms = "Popover-module__panelLeft___9nSLp", Bs = "Popover-module__panelRight___OrQfl", Ds = "Popover-module__panelOpen___hhvV-", Rs = "Popover-module__panelCloseButton___kALaN", de = {
|
|
2590
|
+
triggerWrapper: Es,
|
|
2591
|
+
popup: Ns,
|
|
2592
|
+
panelOverlay: $s,
|
|
2593
|
+
panelOverlayVisible: Ls,
|
|
2594
|
+
backdrop: As,
|
|
2595
|
+
panel: Ps,
|
|
2596
|
+
panelLeft: Ms,
|
|
2597
2597
|
panelRight: Bs,
|
|
2598
|
-
panelOpen:
|
|
2598
|
+
panelOpen: Ds,
|
|
2599
2599
|
panelCloseButton: Rs
|
|
2600
2600
|
};
|
|
2601
|
-
function
|
|
2601
|
+
function Os(e, r) {
|
|
2602
2602
|
const [t, o] = J(!1), [s, n] = J(!1);
|
|
2603
2603
|
ne(() => {
|
|
2604
2604
|
r === "panel" && (e ? o(!0) : n(!1));
|
|
@@ -2611,13 +2611,13 @@ function Ds(e, r) {
|
|
|
2611
2611
|
cancelAnimationFrame(i), cancelAnimationFrame(f);
|
|
2612
2612
|
};
|
|
2613
2613
|
}, [t, e, r]);
|
|
2614
|
-
const a =
|
|
2614
|
+
const a = Ce(() => {
|
|
2615
2615
|
s || o(!1);
|
|
2616
2616
|
}, [s]);
|
|
2617
2617
|
return { panelMounted: t, panelVisible: s, handleTransitionEnd: a };
|
|
2618
2618
|
}
|
|
2619
|
-
function
|
|
2620
|
-
const [s, n] = J({}), a =
|
|
2619
|
+
function Is(e, r, t, o) {
|
|
2620
|
+
const [s, n] = J({}), a = Ce(() => {
|
|
2621
2621
|
if (r !== "popup" || !t.current) return;
|
|
2622
2622
|
const i = t.current.getBoundingClientRect(), f = {
|
|
2623
2623
|
position: "fixed",
|
|
@@ -2639,7 +2639,7 @@ function Os(e, r, t, o) {
|
|
|
2639
2639
|
};
|
|
2640
2640
|
}, [e, r, a]), { popupPositionStyle: s };
|
|
2641
2641
|
}
|
|
2642
|
-
const
|
|
2642
|
+
const Vr = ({
|
|
2643
2643
|
trigger: e,
|
|
2644
2644
|
children: r,
|
|
2645
2645
|
variant: t = "popup",
|
|
@@ -2655,55 +2655,55 @@ const Fr = ({
|
|
|
2655
2655
|
style: m,
|
|
2656
2656
|
popoverProps: C
|
|
2657
2657
|
}) => {
|
|
2658
|
-
const b =
|
|
2659
|
-
(
|
|
2660
|
-
_ || V(
|
|
2658
|
+
const b = R(), _ = o !== void 0, [k, V] = J(!1), g = _ ? o : k, F = Ve(null), z = Ve(null), E = Ce(
|
|
2659
|
+
(I) => {
|
|
2660
|
+
_ || V(I), s == null || s(I);
|
|
2661
2661
|
},
|
|
2662
2662
|
[_, s]
|
|
2663
|
-
),
|
|
2663
|
+
), B = Ce(() => E(!g), [g, E]), M = Ce(() => E(!1), [E]), { panelMounted: U, panelVisible: P, handleTransitionEnd: K } = Os(g, t), { popupPositionStyle: q } = Is(g, t, F, n);
|
|
2664
2664
|
ne(() => {
|
|
2665
2665
|
if (!g || t !== "popup") return;
|
|
2666
|
-
const
|
|
2666
|
+
const I = (Q) => {
|
|
2667
2667
|
var te, me;
|
|
2668
|
-
(te = z.current) != null && te.contains(
|
|
2668
|
+
(te = z.current) != null && te.contains(Q.target) || (me = F.current) != null && me.contains(Q.target) || M();
|
|
2669
2669
|
};
|
|
2670
|
-
return document.addEventListener("mousedown",
|
|
2671
|
-
}, [g, t,
|
|
2670
|
+
return document.addEventListener("mousedown", I), () => document.removeEventListener("mousedown", I);
|
|
2671
|
+
}, [g, t, M]), ne(() => {
|
|
2672
2672
|
if (!g) return;
|
|
2673
|
-
const
|
|
2674
|
-
|
|
2673
|
+
const I = (Q) => {
|
|
2674
|
+
Q.key === "Escape" && M();
|
|
2675
2675
|
};
|
|
2676
|
-
return document.addEventListener("keydown",
|
|
2677
|
-
}, [g,
|
|
2676
|
+
return document.addEventListener("keydown", I), () => document.removeEventListener("keydown", I);
|
|
2677
|
+
}, [g, M]), ne(() => {
|
|
2678
2678
|
if (!g || t !== "panel") return;
|
|
2679
|
-
const
|
|
2680
|
-
return document.body.style.position = "fixed", document.body.style.top = `-${
|
|
2681
|
-
document.body.style.position = "", document.body.style.top = "", document.body.style.width = "", window.scrollTo(0,
|
|
2679
|
+
const I = window.scrollY;
|
|
2680
|
+
return document.body.style.position = "fixed", document.body.style.top = `-${I}px`, document.body.style.width = "100%", () => {
|
|
2681
|
+
document.body.style.position = "", document.body.style.top = "", document.body.style.width = "", window.scrollTo(0, I);
|
|
2682
2682
|
};
|
|
2683
2683
|
}, [g, t]);
|
|
2684
|
-
const L = e ? typeof e == "function" ? e({ onClick:
|
|
2684
|
+
const L = e ? typeof e == "function" ? e({ onClick: B, isOpen: g }) : (
|
|
2685
2685
|
// Non-function trigger: wrap in a span that delegates clicks to the trigger element.
|
|
2686
2686
|
// The wrapped element (e.g. <button>) handles its own keyboard accessibility.
|
|
2687
2687
|
// eslint-disable-next-line jsx-a11y/click-events-have-key-events, jsx-a11y/no-static-element-interactions
|
|
2688
|
-
/* @__PURE__ */ p("span", { onClick:
|
|
2688
|
+
/* @__PURE__ */ p("span", { onClick: B, style: { cursor: "pointer", display: "contents" }, children: e })
|
|
2689
2689
|
) : null, A = e ? /* @__PURE__ */ p("span", { ref: F, className: de.triggerWrapper, children: L }) : null;
|
|
2690
2690
|
if (t === "popup") {
|
|
2691
|
-
const
|
|
2691
|
+
const I = {
|
|
2692
2692
|
backgroundColor: b.colors.secondary,
|
|
2693
2693
|
borderRadius: b.border.radius,
|
|
2694
2694
|
boxShadow: "0 4px 6px -1px rgba(0,0,0,0.1), 0 2px 4px -1px rgba(0,0,0,0.06)",
|
|
2695
2695
|
...q,
|
|
2696
2696
|
...m
|
|
2697
2697
|
};
|
|
2698
|
-
return /* @__PURE__ */
|
|
2698
|
+
return /* @__PURE__ */ D(Fe, { children: [
|
|
2699
2699
|
A,
|
|
2700
|
-
g &&
|
|
2700
|
+
g && lt(
|
|
2701
2701
|
/* @__PURE__ */ p(
|
|
2702
2702
|
"div",
|
|
2703
2703
|
{
|
|
2704
2704
|
ref: z,
|
|
2705
2705
|
className: [de.popup, y].filter(Boolean).join(" "),
|
|
2706
|
-
style:
|
|
2706
|
+
style: I,
|
|
2707
2707
|
...C,
|
|
2708
2708
|
children: r
|
|
2709
2709
|
}
|
|
@@ -2712,15 +2712,15 @@ const Fr = ({
|
|
|
2712
2712
|
)
|
|
2713
2713
|
] });
|
|
2714
2714
|
}
|
|
2715
|
-
const
|
|
2715
|
+
const O = {
|
|
2716
2716
|
width: i,
|
|
2717
2717
|
backgroundColor: b.colors.secondary,
|
|
2718
2718
|
...m
|
|
2719
2719
|
};
|
|
2720
|
-
return /* @__PURE__ */
|
|
2720
|
+
return /* @__PURE__ */ D(Fe, { children: [
|
|
2721
2721
|
A,
|
|
2722
|
-
|
|
2723
|
-
/* @__PURE__ */
|
|
2722
|
+
U && lt(
|
|
2723
|
+
/* @__PURE__ */ D(
|
|
2724
2724
|
"div",
|
|
2725
2725
|
{
|
|
2726
2726
|
className: [de.panelOverlay, P ? de.panelOverlayVisible : ""].filter(Boolean).join(" "),
|
|
@@ -2730,11 +2730,11 @@ const Fr = ({
|
|
|
2730
2730
|
{
|
|
2731
2731
|
className: de.backdrop,
|
|
2732
2732
|
style: { backgroundColor: P ? f : "transparent" },
|
|
2733
|
-
onClick: u ?
|
|
2733
|
+
onClick: u ? M : void 0,
|
|
2734
2734
|
role: "presentation"
|
|
2735
2735
|
}
|
|
2736
2736
|
),
|
|
2737
|
-
/* @__PURE__ */
|
|
2737
|
+
/* @__PURE__ */ D(
|
|
2738
2738
|
"div",
|
|
2739
2739
|
{
|
|
2740
2740
|
ref: z,
|
|
@@ -2744,17 +2744,17 @@ const Fr = ({
|
|
|
2744
2744
|
P ? de.panelOpen : "",
|
|
2745
2745
|
y
|
|
2746
2746
|
].filter(Boolean).join(" "),
|
|
2747
|
-
style:
|
|
2747
|
+
style: O,
|
|
2748
2748
|
role: "dialog",
|
|
2749
2749
|
"aria-modal": "true",
|
|
2750
|
-
onTransitionEnd:
|
|
2750
|
+
onTransitionEnd: K,
|
|
2751
2751
|
...C,
|
|
2752
2752
|
children: [
|
|
2753
2753
|
!c && /* @__PURE__ */ p(
|
|
2754
2754
|
"button",
|
|
2755
2755
|
{
|
|
2756
2756
|
className: de.panelCloseButton,
|
|
2757
|
-
onClick:
|
|
2757
|
+
onClick: M,
|
|
2758
2758
|
"aria-label": "Close panel",
|
|
2759
2759
|
type: "button",
|
|
2760
2760
|
children: /* @__PURE__ */ p(
|
|
@@ -2790,14 +2790,14 @@ const Fr = ({
|
|
|
2790
2790
|
document.body
|
|
2791
2791
|
)
|
|
2792
2792
|
] });
|
|
2793
|
-
},
|
|
2793
|
+
}, Ts = ({
|
|
2794
2794
|
isMobile: e,
|
|
2795
2795
|
isCompact: r,
|
|
2796
2796
|
mobile: t,
|
|
2797
2797
|
desktop: o
|
|
2798
2798
|
}) => {
|
|
2799
|
-
const s =
|
|
2800
|
-
return
|
|
2799
|
+
const s = R();
|
|
2800
|
+
return We(() => e ? {
|
|
2801
2801
|
navStyles: {
|
|
2802
2802
|
...(t == null ? void 0 : t.backgroundColor) && { backgroundColor: t.backgroundColor },
|
|
2803
2803
|
color: (t == null ? void 0 : t.color) || s.fonts.color,
|
|
@@ -2810,11 +2810,11 @@ const Fr = ({
|
|
|
2810
2810
|
...o == null ? void 0 : o.style
|
|
2811
2811
|
}
|
|
2812
2812
|
}, [e, r, t, o, s]);
|
|
2813
|
-
},
|
|
2813
|
+
}, Hs = ht({
|
|
2814
2814
|
isMobile: !1,
|
|
2815
2815
|
setOpen: () => {
|
|
2816
2816
|
}
|
|
2817
|
-
}),
|
|
2817
|
+
}), js = ({
|
|
2818
2818
|
open: e,
|
|
2819
2819
|
setOpen: r,
|
|
2820
2820
|
hamburgerRef: t,
|
|
@@ -2830,7 +2830,7 @@ const Fr = ({
|
|
|
2830
2830
|
}) => {
|
|
2831
2831
|
const { backgroundColor: m, ...C } = f;
|
|
2832
2832
|
return /* @__PURE__ */ p(
|
|
2833
|
-
|
|
2833
|
+
Vr,
|
|
2834
2834
|
{
|
|
2835
2835
|
variant: "panel",
|
|
2836
2836
|
side: a || "right",
|
|
@@ -2839,7 +2839,7 @@ const Fr = ({
|
|
|
2839
2839
|
onOpenChange: r,
|
|
2840
2840
|
style: m ? { backgroundColor: m } : void 0,
|
|
2841
2841
|
trigger: ({ onClick: b }) => /* @__PURE__ */ p(
|
|
2842
|
-
|
|
2842
|
+
vs,
|
|
2843
2843
|
{
|
|
2844
2844
|
hamburgerRef: t,
|
|
2845
2845
|
visible: !0,
|
|
@@ -2849,19 +2849,19 @@ const Fr = ({
|
|
|
2849
2849
|
...s == null ? void 0 : s.hamburgerProps
|
|
2850
2850
|
}
|
|
2851
2851
|
),
|
|
2852
|
-
children: /* @__PURE__ */
|
|
2853
|
-
/* @__PURE__ */ p("div", { className:
|
|
2852
|
+
children: /* @__PURE__ */ D("nav", { ...c, className: i, style: C, onClickCapture: y, children: [
|
|
2853
|
+
/* @__PURE__ */ p("div", { className: xe.navHeader }),
|
|
2854
2854
|
typeof u == "function" ? u({ setOpen: r }) : u
|
|
2855
2855
|
] })
|
|
2856
2856
|
}
|
|
2857
2857
|
);
|
|
2858
|
-
},
|
|
2858
|
+
}, Ws = ({
|
|
2859
2859
|
setOpen: e,
|
|
2860
2860
|
navClassName: r,
|
|
2861
2861
|
cssProps: t,
|
|
2862
2862
|
navProps: o,
|
|
2863
2863
|
content: s
|
|
2864
|
-
}) => /* @__PURE__ */ p("nav", { ...o, className: r, style: t, children: typeof s == "function" ? s({ setOpen: e }) : s }),
|
|
2864
|
+
}) => /* @__PURE__ */ p("nav", { ...o, className: r, style: t, children: typeof s == "function" ? s({ setOpen: e }) : s }), pa = ({
|
|
2865
2865
|
mobile: e,
|
|
2866
2866
|
desktop: r,
|
|
2867
2867
|
breakpoints: t,
|
|
@@ -2871,22 +2871,22 @@ const Fr = ({
|
|
|
2871
2871
|
navProps: a,
|
|
2872
2872
|
disableMobileTreatment: i = !1
|
|
2873
2873
|
}) => {
|
|
2874
|
-
const [f, c] = J(!1), u =
|
|
2874
|
+
const [f, c] = J(!1), u = Ve(null), m = { ...R().breakpoints, ...t }, { maxWidth: C, unit: b } = Le(m.md), { maxWidth: _, unit: k } = Le(m.sm), V = ue(`(max-width: ${C}${b})`), g = ue(`(max-width: ${_}${k})`), F = i ? !1 : V, z = i ? !1 : g, { navStyles: E } = Ts({
|
|
2875
2875
|
isMobile: F,
|
|
2876
2876
|
isCompact: z,
|
|
2877
2877
|
mobile: e,
|
|
2878
2878
|
desktop: r
|
|
2879
|
-
}),
|
|
2880
|
-
const q =
|
|
2879
|
+
}), B = { ...E, ...n }, M = (K) => {
|
|
2880
|
+
const q = K.target;
|
|
2881
2881
|
q.closest("[data-navdropdown-trigger]") || q.closest("a, button") && c(!1);
|
|
2882
|
-
},
|
|
2883
|
-
|
|
2884
|
-
|
|
2885
|
-
z || e != null && e.compact ?
|
|
2882
|
+
}, U = [
|
|
2883
|
+
xe.nav,
|
|
2884
|
+
xe.navMobile,
|
|
2885
|
+
z || e != null && e.compact ? xe.compact : "",
|
|
2886
2886
|
s
|
|
2887
|
-
].filter(Boolean).join(" "), P = [
|
|
2888
|
-
return /* @__PURE__ */ p(
|
|
2889
|
-
|
|
2887
|
+
].filter(Boolean).join(" "), P = [xe.nav, xe.navDesktop, s].filter(Boolean).join(" ");
|
|
2888
|
+
return /* @__PURE__ */ p(Hs.Provider, { value: { isMobile: F, setOpen: c }, children: F ? /* @__PURE__ */ p(
|
|
2889
|
+
js,
|
|
2890
2890
|
{
|
|
2891
2891
|
open: f,
|
|
2892
2892
|
setOpen: c,
|
|
@@ -2895,33 +2895,33 @@ const Fr = ({
|
|
|
2895
2895
|
mobile: e,
|
|
2896
2896
|
panelWidth: e == null ? void 0 : e.panelWidth,
|
|
2897
2897
|
side: e == null ? void 0 : e.side,
|
|
2898
|
-
navClassName:
|
|
2899
|
-
cssProps:
|
|
2898
|
+
navClassName: U,
|
|
2899
|
+
cssProps: B,
|
|
2900
2900
|
navProps: a,
|
|
2901
2901
|
content: (e == null ? void 0 : e.content) || o,
|
|
2902
|
-
onNavClick:
|
|
2902
|
+
onNavClick: M
|
|
2903
2903
|
}
|
|
2904
2904
|
) : /* @__PURE__ */ p(
|
|
2905
|
-
|
|
2905
|
+
Ws,
|
|
2906
2906
|
{
|
|
2907
2907
|
setOpen: c,
|
|
2908
2908
|
navClassName: P,
|
|
2909
|
-
cssProps:
|
|
2909
|
+
cssProps: B,
|
|
2910
2910
|
navProps: a,
|
|
2911
2911
|
content: (r == null ? void 0 : r.content) || o
|
|
2912
2912
|
}
|
|
2913
2913
|
) });
|
|
2914
|
-
}, Us = "NavDropdown-module__trigger___1PQZp",
|
|
2914
|
+
}, Us = "NavDropdown-module__trigger___1PQZp", qs = "NavDropdown-module__chevron___ZLAV7", Gs = "NavDropdown-module__chevronOpen___9mgjr", st = {
|
|
2915
2915
|
trigger: Us,
|
|
2916
|
-
chevron:
|
|
2917
|
-
chevronOpen:
|
|
2916
|
+
chevron: qs,
|
|
2917
|
+
chevronOpen: Gs
|
|
2918
2918
|
};
|
|
2919
|
-
function
|
|
2919
|
+
function zr({
|
|
2920
2920
|
isActive: e = !1,
|
|
2921
2921
|
hoverOpacity: r = 0.5,
|
|
2922
2922
|
color: t
|
|
2923
2923
|
} = {}) {
|
|
2924
|
-
const o =
|
|
2924
|
+
const o = R(), [s, n] = J(!1);
|
|
2925
2925
|
return {
|
|
2926
2926
|
style: {
|
|
2927
2927
|
color: t || o.fonts.color,
|
|
@@ -2933,7 +2933,7 @@ function Vr({
|
|
|
2933
2933
|
onMouseLeave: () => n(!1)
|
|
2934
2934
|
};
|
|
2935
2935
|
}
|
|
2936
|
-
const
|
|
2936
|
+
const ga = ({
|
|
2937
2937
|
label: e,
|
|
2938
2938
|
children: r,
|
|
2939
2939
|
dropdownVariant: t = "popup",
|
|
@@ -2949,20 +2949,20 @@ const fa = ({
|
|
|
2949
2949
|
style: m,
|
|
2950
2950
|
onMouseEnter: C,
|
|
2951
2951
|
onMouseLeave: b
|
|
2952
|
-
} =
|
|
2952
|
+
} = zr({ isActive: u, color: n, hoverOpacity: a });
|
|
2953
2953
|
return /* @__PURE__ */ p(
|
|
2954
|
-
|
|
2954
|
+
Vr,
|
|
2955
2955
|
{
|
|
2956
2956
|
variant: t,
|
|
2957
2957
|
side: o,
|
|
2958
2958
|
panelWidth: s,
|
|
2959
2959
|
isOpen: u,
|
|
2960
2960
|
onOpenChange: y,
|
|
2961
|
-
trigger: ({ onClick: _ }) => /* @__PURE__ */
|
|
2961
|
+
trigger: ({ onClick: _ }) => /* @__PURE__ */ D(
|
|
2962
2962
|
"button",
|
|
2963
2963
|
{
|
|
2964
2964
|
type: "button",
|
|
2965
|
-
className: [
|
|
2965
|
+
className: [st.trigger, i].filter(Boolean).join(" "),
|
|
2966
2966
|
style: { ...m, ...f },
|
|
2967
2967
|
"data-navdropdown-trigger": !0,
|
|
2968
2968
|
onClick: _,
|
|
@@ -2974,7 +2974,7 @@ const fa = ({
|
|
|
2974
2974
|
/* @__PURE__ */ p(
|
|
2975
2975
|
"span",
|
|
2976
2976
|
{
|
|
2977
|
-
className: [
|
|
2977
|
+
className: [st.chevron, u ? st.chevronOpen : ""].filter(Boolean).join(" "),
|
|
2978
2978
|
"aria-hidden": "true",
|
|
2979
2979
|
children: /* @__PURE__ */ p(
|
|
2980
2980
|
"svg",
|
|
@@ -3004,8 +3004,8 @@ const fa = ({
|
|
|
3004
3004
|
children: r
|
|
3005
3005
|
}
|
|
3006
3006
|
);
|
|
3007
|
-
},
|
|
3008
|
-
const { style: s, onMouseEnter: n, onMouseLeave: a } =
|
|
3007
|
+
}, va = ({ isActive: e, hoverOpacity: r, color: t, children: o }) => {
|
|
3008
|
+
const { style: s, onMouseEnter: n, onMouseLeave: a } = zr({
|
|
3009
3009
|
isActive: e,
|
|
3010
3010
|
hoverOpacity: r,
|
|
3011
3011
|
color: t
|
|
@@ -3021,7 +3021,7 @@ const fa = ({
|
|
|
3021
3021
|
a(), (c = (f = o.props).onMouseLeave) == null || c.call(f, i);
|
|
3022
3022
|
}
|
|
3023
3023
|
});
|
|
3024
|
-
},
|
|
3024
|
+
}, Er = ({
|
|
3025
3025
|
// Color props
|
|
3026
3026
|
color: e,
|
|
3027
3027
|
backgroundColor: r,
|
|
@@ -3033,7 +3033,7 @@ const fa = ({
|
|
|
3033
3033
|
// Element-specific props
|
|
3034
3034
|
divProps: n
|
|
3035
3035
|
}) => {
|
|
3036
|
-
const a =
|
|
3036
|
+
const a = R(), i = e || a.colors.primary, f = r || a.colors.secondary, c = /* @__PURE__ */ p(
|
|
3037
3037
|
"div",
|
|
3038
3038
|
{
|
|
3039
3039
|
...t ? void 0 : n,
|
|
@@ -3052,7 +3052,7 @@ const fa = ({
|
|
|
3052
3052
|
borderTop: `0.1em solid ${f}`
|
|
3053
3053
|
}
|
|
3054
3054
|
}
|
|
3055
|
-
), u = /* @__PURE__ */
|
|
3055
|
+
), u = /* @__PURE__ */ D(Fe, { children: [
|
|
3056
3056
|
c,
|
|
3057
3057
|
/* @__PURE__ */ p("style", { children: `
|
|
3058
3058
|
@keyframes spin {
|
|
@@ -3078,26 +3078,26 @@ const fa = ({
|
|
|
3078
3078
|
children: u
|
|
3079
3079
|
}
|
|
3080
3080
|
) : u;
|
|
3081
|
-
},
|
|
3081
|
+
}, ba = ({ children: e, loadingComponent: r }) => {
|
|
3082
3082
|
const [t, o] = J(!1);
|
|
3083
3083
|
return ne(() => {
|
|
3084
3084
|
requestAnimationFrame(() => {
|
|
3085
3085
|
o(!0);
|
|
3086
3086
|
});
|
|
3087
|
-
}, []), t ? /* @__PURE__ */ p(
|
|
3088
|
-
},
|
|
3089
|
-
backdrop:
|
|
3090
|
-
modal:
|
|
3087
|
+
}, []), t ? /* @__PURE__ */ p(Fe, { children: e }) : r || /* @__PURE__ */ p(Er, {});
|
|
3088
|
+
}, Zs = "Modal-module__backdrop___GVUh4", Ks = "Modal-module__modal___aD7aP", Qs = "Modal-module__header___ILG9i", Xs = "Modal-module__title___A5OeE", Js = "Modal-module__closeButton___3LpSf", Ys = "Modal-module__content___dWO-B", en = "Modal-module__actions___hY6zi", he = {
|
|
3089
|
+
backdrop: Zs,
|
|
3090
|
+
modal: Ks,
|
|
3091
3091
|
header: Qs,
|
|
3092
|
-
title:
|
|
3093
|
-
closeButton:
|
|
3094
|
-
content:
|
|
3095
|
-
actions:
|
|
3096
|
-
},
|
|
3097
|
-
stack:
|
|
3098
|
-
vertical:
|
|
3099
|
-
horizontal:
|
|
3100
|
-
},
|
|
3092
|
+
title: Xs,
|
|
3093
|
+
closeButton: Js,
|
|
3094
|
+
content: Ys,
|
|
3095
|
+
actions: en
|
|
3096
|
+
}, tn = "Stack-module__stack___yUU-B", rn = "Stack-module__vertical___sKTyQ", on = "Stack-module__horizontal___YsvtV", nt = {
|
|
3097
|
+
stack: tn,
|
|
3098
|
+
vertical: rn,
|
|
3099
|
+
horizontal: on
|
|
3100
|
+
}, sn = ({
|
|
3101
3101
|
// Layout props
|
|
3102
3102
|
direction: e = "row",
|
|
3103
3103
|
gap: r = "0.5em",
|
|
@@ -3110,12 +3110,12 @@ const fa = ({
|
|
|
3110
3110
|
divProps: n
|
|
3111
3111
|
}) => {
|
|
3112
3112
|
const a = [
|
|
3113
|
-
|
|
3114
|
-
e === "column" ?
|
|
3113
|
+
nt.stack,
|
|
3114
|
+
e === "column" ? nt.vertical : nt.horizontal,
|
|
3115
3115
|
o
|
|
3116
3116
|
].filter(Boolean).join(" ");
|
|
3117
3117
|
return /* @__PURE__ */ p("div", { ...n, className: a, style: { gap: r, ...s }, children: t });
|
|
3118
|
-
},
|
|
3118
|
+
}, nn = ({
|
|
3119
3119
|
isOpen: e,
|
|
3120
3120
|
onClose: r,
|
|
3121
3121
|
children: t,
|
|
@@ -3133,7 +3133,7 @@ const fa = ({
|
|
|
3133
3133
|
style: b,
|
|
3134
3134
|
divProps: _
|
|
3135
3135
|
}) => {
|
|
3136
|
-
const k =
|
|
3136
|
+
const k = R(), V = Ve(null), g = Ve(null), { maxWidth: F } = Le(k.breakpoints.md), z = ue(`(max-width: ${F - 1}px)`);
|
|
3137
3137
|
ne(() => {
|
|
3138
3138
|
if (e)
|
|
3139
3139
|
return g.current = document.activeElement, document.body.style.overflow = "hidden", V.current && V.current.focus(), () => {
|
|
@@ -3141,8 +3141,8 @@ const fa = ({
|
|
|
3141
3141
|
};
|
|
3142
3142
|
}, [e]), ne(() => {
|
|
3143
3143
|
if (!e || !a) return;
|
|
3144
|
-
const P = (
|
|
3145
|
-
|
|
3144
|
+
const P = (K) => {
|
|
3145
|
+
K.key === "Escape" && r();
|
|
3146
3146
|
};
|
|
3147
3147
|
return document.addEventListener("keydown", P), () => document.removeEventListener("keydown", P);
|
|
3148
3148
|
}, [e, a, r]);
|
|
@@ -3150,34 +3150,34 @@ const fa = ({
|
|
|
3150
3150
|
P.target === P.currentTarget && n && r();
|
|
3151
3151
|
};
|
|
3152
3152
|
if (!e) return null;
|
|
3153
|
-
const
|
|
3153
|
+
const B = {
|
|
3154
3154
|
width: c,
|
|
3155
3155
|
maxWidth: u,
|
|
3156
3156
|
backgroundColor: y || k.colors.secondary,
|
|
3157
3157
|
borderRadius: k.border.radius,
|
|
3158
3158
|
...b
|
|
3159
|
-
},
|
|
3159
|
+
}, M = {
|
|
3160
3160
|
backgroundColor: m
|
|
3161
|
-
},
|
|
3161
|
+
}, U = /* @__PURE__ */ p(
|
|
3162
3162
|
"div",
|
|
3163
3163
|
{
|
|
3164
3164
|
className: he.backdrop,
|
|
3165
|
-
style:
|
|
3165
|
+
style: M,
|
|
3166
3166
|
onClick: E,
|
|
3167
3167
|
role: "presentation",
|
|
3168
|
-
children: /* @__PURE__ */
|
|
3168
|
+
children: /* @__PURE__ */ D(
|
|
3169
3169
|
"div",
|
|
3170
3170
|
{
|
|
3171
3171
|
ref: V,
|
|
3172
3172
|
className: [he.modal, C].filter(Boolean).join(" "),
|
|
3173
|
-
style:
|
|
3173
|
+
style: B,
|
|
3174
3174
|
role: "dialog",
|
|
3175
3175
|
"aria-modal": "true",
|
|
3176
3176
|
"aria-labelledby": o ? "modal-title" : void 0,
|
|
3177
3177
|
tabIndex: -1,
|
|
3178
3178
|
..._,
|
|
3179
3179
|
children: [
|
|
3180
|
-
/* @__PURE__ */
|
|
3180
|
+
/* @__PURE__ */ D("div", { className: he.header, children: [
|
|
3181
3181
|
o && /* @__PURE__ */ p("h2", { id: "modal-title", className: he.title, children: o }),
|
|
3182
3182
|
!s && /* @__PURE__ */ p(
|
|
3183
3183
|
"button",
|
|
@@ -3211,8 +3211,8 @@ const fa = ({
|
|
|
3211
3211
|
)
|
|
3212
3212
|
] }),
|
|
3213
3213
|
/* @__PURE__ */ p("div", { className: he.content, children: t }),
|
|
3214
|
-
i.length > 0 && /* @__PURE__ */ p(
|
|
3215
|
-
|
|
3214
|
+
i.length > 0 && /* @__PURE__ */ p(sn, { direction: z ? "column" : "row", className: he.actions, children: i.map((P, K) => /* @__PURE__ */ p(
|
|
3215
|
+
Kr,
|
|
3216
3216
|
{
|
|
3217
3217
|
color: P.color,
|
|
3218
3218
|
outline: P.variant === "outline",
|
|
@@ -3222,15 +3222,15 @@ const fa = ({
|
|
|
3222
3222
|
},
|
|
3223
3223
|
children: P.label
|
|
3224
3224
|
},
|
|
3225
|
-
|
|
3225
|
+
K
|
|
3226
3226
|
)) })
|
|
3227
3227
|
]
|
|
3228
3228
|
}
|
|
3229
3229
|
)
|
|
3230
3230
|
}
|
|
3231
3231
|
);
|
|
3232
|
-
return
|
|
3233
|
-
},
|
|
3232
|
+
return lt(U, document.body);
|
|
3233
|
+
}, Nr = ht(null), Sa = ({ children: e }) => {
|
|
3234
3234
|
const [r, t] = J(null), o = N.useCallback((c) => new Promise((u, y) => {
|
|
3235
3235
|
const m = Math.random().toString(36).substr(2, 9);
|
|
3236
3236
|
t({
|
|
@@ -3288,10 +3288,10 @@ const fa = ({
|
|
|
3288
3288
|
}),
|
|
3289
3289
|
[o, s, n, a]
|
|
3290
3290
|
);
|
|
3291
|
-
return /* @__PURE__ */
|
|
3291
|
+
return /* @__PURE__ */ D(Nr.Provider, { value: f, children: [
|
|
3292
3292
|
e,
|
|
3293
3293
|
r && /* @__PURE__ */ p(
|
|
3294
|
-
|
|
3294
|
+
nn,
|
|
3295
3295
|
{
|
|
3296
3296
|
isOpen: !0,
|
|
3297
3297
|
onClose: i,
|
|
@@ -3303,15 +3303,15 @@ const fa = ({
|
|
|
3303
3303
|
}
|
|
3304
3304
|
)
|
|
3305
3305
|
] });
|
|
3306
|
-
},
|
|
3307
|
-
const e =
|
|
3306
|
+
}, wa = () => {
|
|
3307
|
+
const e = or(Nr);
|
|
3308
3308
|
if (!e)
|
|
3309
3309
|
throw new Error("useModal must be used within a ModalProvider");
|
|
3310
3310
|
return e;
|
|
3311
|
-
},
|
|
3312
|
-
section:
|
|
3313
|
-
innerDiv:
|
|
3314
|
-
},
|
|
3311
|
+
}, an = "ResponsiveSection-module__section___gBESK", ln = "ResponsiveSection-module__innerDiv___r1bky", Yt = {
|
|
3312
|
+
section: an,
|
|
3313
|
+
innerDiv: ln
|
|
3314
|
+
}, $r = ({
|
|
3315
3315
|
// Color props
|
|
3316
3316
|
backgroundColor: e,
|
|
3317
3317
|
color: r,
|
|
@@ -3333,7 +3333,7 @@ const fa = ({
|
|
|
3333
3333
|
// Element-specific props
|
|
3334
3334
|
sectionProps: b
|
|
3335
3335
|
}) => {
|
|
3336
|
-
const _ =
|
|
3336
|
+
const _ = R(), k = ue(`(min-width: ${_.breakpoints.sm})`), V = {
|
|
3337
3337
|
backgroundColor: e,
|
|
3338
3338
|
color: r || _.fonts.color,
|
|
3339
3339
|
margin: f,
|
|
@@ -3346,16 +3346,16 @@ const fa = ({
|
|
|
3346
3346
|
"--height": n,
|
|
3347
3347
|
"--section-padding": `${g} ${F}`,
|
|
3348
3348
|
"--gap": c
|
|
3349
|
-
}, E = [
|
|
3350
|
-
return /* @__PURE__ */ p("section", { ...b, className: E, style: V, children: /* @__PURE__ */ p("div", { className:
|
|
3351
|
-
},
|
|
3352
|
-
hero:
|
|
3353
|
-
content:
|
|
3354
|
-
},
|
|
3349
|
+
}, E = [Yt.section, m].filter(Boolean).join(" ");
|
|
3350
|
+
return /* @__PURE__ */ p("section", { ...b, className: E, style: V, children: /* @__PURE__ */ p("div", { className: Yt.innerDiv, style: z, children: y }) });
|
|
3351
|
+
}, cn = "Hero-module__hero___IB2tg", un = "Hero-module__content___rkkfQ", er = {
|
|
3352
|
+
hero: cn,
|
|
3353
|
+
content: un
|
|
3354
|
+
}, dn = ({
|
|
3355
3355
|
isMd: e = !1,
|
|
3356
3356
|
isLg: r = !1,
|
|
3357
3357
|
theme: t
|
|
3358
|
-
}) =>
|
|
3358
|
+
}) => We(() => {
|
|
3359
3359
|
const { rhythm: o } = t.fonts;
|
|
3360
3360
|
let s = `calc(${o} * 2) 0`, n = "2rem", a = "1.125rem";
|
|
3361
3361
|
return r ? (s = `calc(${o} * 4) 0`, n = "3.5rem", a = "1.5rem") : e && (s = `calc(${o} * 3.5) 0`, n = "3rem", a = "1.25rem"), {
|
|
@@ -3364,7 +3364,7 @@ const fa = ({
|
|
|
3364
3364
|
"--hero-p-font-size": a,
|
|
3365
3365
|
"--hero-h1-margin-bottom": `calc(${o} * 0.7)`
|
|
3366
3366
|
};
|
|
3367
|
-
}, [e, r, t.fonts]),
|
|
3367
|
+
}, [e, r, t.fonts]), ka = ({
|
|
3368
3368
|
// Color props
|
|
3369
3369
|
color: e,
|
|
3370
3370
|
// Layout props
|
|
@@ -3376,21 +3376,21 @@ const fa = ({
|
|
|
3376
3376
|
style: s,
|
|
3377
3377
|
...n
|
|
3378
3378
|
}) => {
|
|
3379
|
-
const a =
|
|
3379
|
+
const a = R(), i = [er.hero, o].filter(Boolean).join(" "), f = (r == null ? void 0 : r.md) || a.breakpoints.md, c = (r == null ? void 0 : r.lg) || a.breakpoints.lg, u = ue(`(min-width: ${f})`), y = ue(`(min-width: ${c})`), m = dn({ isMd: u, isLg: y, theme: a });
|
|
3380
3380
|
return /* @__PURE__ */ p(
|
|
3381
|
-
|
|
3381
|
+
$r,
|
|
3382
3382
|
{
|
|
3383
3383
|
className: i,
|
|
3384
3384
|
color: e || a.fonts.color,
|
|
3385
3385
|
style: { ...m, ...s },
|
|
3386
3386
|
...n,
|
|
3387
|
-
children: /* @__PURE__ */ p("div", { className:
|
|
3387
|
+
children: /* @__PURE__ */ p("div", { className: er.content, children: t })
|
|
3388
3388
|
}
|
|
3389
3389
|
);
|
|
3390
|
-
},
|
|
3391
|
-
footer:
|
|
3392
|
-
container:
|
|
3393
|
-
},
|
|
3390
|
+
}, fn = "Footer-module__footer___A76NF", mn = "Footer-module__container___QneNs", tr = {
|
|
3391
|
+
footer: fn,
|
|
3392
|
+
container: mn
|
|
3393
|
+
}, yn = ({
|
|
3394
3394
|
isSmallScreen: e = !1,
|
|
3395
3395
|
maxWidth: r,
|
|
3396
3396
|
minWidth: t,
|
|
@@ -3403,7 +3403,7 @@ const fa = ({
|
|
|
3403
3403
|
backgroundColor: c,
|
|
3404
3404
|
color: u
|
|
3405
3405
|
} = {}) => {
|
|
3406
|
-
const y =
|
|
3406
|
+
const y = R();
|
|
3407
3407
|
return {
|
|
3408
3408
|
maxWidth: r || y.layout.maxWidth,
|
|
3409
3409
|
minWidth: t,
|
|
@@ -3415,7 +3415,7 @@ const fa = ({
|
|
|
3415
3415
|
backgroundColor: c,
|
|
3416
3416
|
color: u || y.fonts.color
|
|
3417
3417
|
};
|
|
3418
|
-
},
|
|
3418
|
+
}, hn = ({
|
|
3419
3419
|
// Color props
|
|
3420
3420
|
backgroundColor: e,
|
|
3421
3421
|
color: r,
|
|
@@ -3437,7 +3437,7 @@ const fa = ({
|
|
|
3437
3437
|
// Element-specific props
|
|
3438
3438
|
footerProps: b
|
|
3439
3439
|
}) => {
|
|
3440
|
-
const _ =
|
|
3440
|
+
const _ = R(), k = u || _.breakpoints.sm, { maxWidth: V, unit: g } = Le(k), F = ue(`(max-width: ${V}${g})`), z = yn({
|
|
3441
3441
|
isSmallScreen: F,
|
|
3442
3442
|
maxWidth: t,
|
|
3443
3443
|
minWidth: o,
|
|
@@ -3449,17 +3449,17 @@ const fa = ({
|
|
|
3449
3449
|
gap: c,
|
|
3450
3450
|
backgroundColor: e,
|
|
3451
3451
|
color: r
|
|
3452
|
-
}), E = [
|
|
3453
|
-
return /* @__PURE__ */ p("footer", { ...b, className:
|
|
3454
|
-
},
|
|
3455
|
-
card:
|
|
3456
|
-
icon:
|
|
3457
|
-
title:
|
|
3458
|
-
content:
|
|
3459
|
-
},
|
|
3452
|
+
}), E = [tr.container, m].filter(Boolean).join(" ");
|
|
3453
|
+
return /* @__PURE__ */ p("footer", { ...b, className: tr.footer, children: /* @__PURE__ */ p("div", { className: E, style: { ...z, ...C }, children: y }) });
|
|
3454
|
+
}, _n = "FeatureCard-module__card___XQt66", pn = "FeatureCard-module__icon___dXJ92", gn = "FeatureCard-module__title___KxXyA", vn = "FeatureCard-module__content___68xkw", Ie = {
|
|
3455
|
+
card: _n,
|
|
3456
|
+
icon: pn,
|
|
3457
|
+
title: gn,
|
|
3458
|
+
content: vn
|
|
3459
|
+
}, bn = ({
|
|
3460
3460
|
isMd: e = !1,
|
|
3461
3461
|
theme: r
|
|
3462
|
-
}) =>
|
|
3462
|
+
}) => We(() => {
|
|
3463
3463
|
const { rhythm: t } = r.fonts;
|
|
3464
3464
|
return {
|
|
3465
3465
|
"--feature-icon-font-size": e ? "3rem" : "2.5rem",
|
|
@@ -3468,7 +3468,7 @@ const fa = ({
|
|
|
3468
3468
|
"--feature-icon-margin-bottom": `calc(${t} * 0.7)`,
|
|
3469
3469
|
"--feature-title-margin-bottom": `calc(${t} * 0.5)`
|
|
3470
3470
|
};
|
|
3471
|
-
}, [e, r.fonts]),
|
|
3471
|
+
}, [e, r.fonts]), xa = ({
|
|
3472
3472
|
// Layout props
|
|
3473
3473
|
breakpoint: e,
|
|
3474
3474
|
// Content
|
|
@@ -3481,28 +3481,27 @@ const fa = ({
|
|
|
3481
3481
|
// Element-specific props
|
|
3482
3482
|
divProps: a
|
|
3483
3483
|
}) => {
|
|
3484
|
-
const i =
|
|
3485
|
-
return /* @__PURE__ */
|
|
3484
|
+
const i = R(), f = [Ie.card, s].filter(Boolean).join(" "), c = e || i.breakpoints.md, u = ue(`(min-width: ${c})`), y = bn({ isMd: u, theme: i });
|
|
3485
|
+
return /* @__PURE__ */ D(
|
|
3486
3486
|
"div",
|
|
3487
3487
|
{
|
|
3488
3488
|
...a,
|
|
3489
3489
|
className: f,
|
|
3490
3490
|
style: { ...y, ...n },
|
|
3491
3491
|
children: [
|
|
3492
|
-
r && /* @__PURE__ */ p("div", { className:
|
|
3493
|
-
/* @__PURE__ */ p("h3", { className:
|
|
3494
|
-
/* @__PURE__ */ p("div", { className:
|
|
3492
|
+
r && /* @__PURE__ */ p("div", { className: Ie.icon, children: r }),
|
|
3493
|
+
/* @__PURE__ */ p("h3", { className: Ie.title, children: t }),
|
|
3494
|
+
/* @__PURE__ */ p("div", { className: Ie.content, children: o })
|
|
3495
3495
|
]
|
|
3496
3496
|
}
|
|
3497
3497
|
);
|
|
3498
|
-
},
|
|
3499
|
-
section: bn,
|
|
3498
|
+
}, Sn = "FeatureGridSection-module__grid___iwPJv", rr = {
|
|
3500
3499
|
grid: Sn
|
|
3501
3500
|
}, wn = ({
|
|
3502
3501
|
columns: e,
|
|
3503
3502
|
isMd: r = !1,
|
|
3504
3503
|
isLg: t = !1
|
|
3505
|
-
}) =>
|
|
3504
|
+
}) => We(() => r ? r && !t && (e === 3 || e === 4) ? {
|
|
3506
3505
|
"--grid-template-columns": "repeat(2, 1fr)"
|
|
3507
3506
|
} : {
|
|
3508
3507
|
"--grid-template-columns": {
|
|
@@ -3513,7 +3512,7 @@ const fa = ({
|
|
|
3513
3512
|
}[e]
|
|
3514
3513
|
} : {
|
|
3515
3514
|
"--grid-template-columns": "1fr"
|
|
3516
|
-
}, [e, r, t]),
|
|
3515
|
+
}, [e, r, t]), Ca = ({
|
|
3517
3516
|
// Layout props
|
|
3518
3517
|
columns: e = 3,
|
|
3519
3518
|
breakpoints: r,
|
|
@@ -3525,19 +3524,66 @@ const fa = ({
|
|
|
3525
3524
|
style: n,
|
|
3526
3525
|
...a
|
|
3527
3526
|
}) => {
|
|
3528
|
-
const i =
|
|
3529
|
-
|
|
3530
|
-
}, _ = {
|
|
3531
|
-
...C,
|
|
3527
|
+
const i = R(), f = [rr.section, s].filter(Boolean).join(" "), c = (r == null ? void 0 : r.md) || i.breakpoints.md, u = (r == null ? void 0 : r.lg) || i.breakpoints.lg, y = ue(`(min-width: ${c})`), m = ue(`(min-width: ${u})`), b = {
|
|
3528
|
+
...wn({ columns: e, isMd: y, isLg: m }),
|
|
3532
3529
|
gap: t,
|
|
3533
3530
|
...n
|
|
3534
3531
|
};
|
|
3535
|
-
return /* @__PURE__ */ p(
|
|
3536
|
-
}, kn = "
|
|
3537
|
-
|
|
3538
|
-
|
|
3539
|
-
|
|
3540
|
-
|
|
3532
|
+
return /* @__PURE__ */ p($r, { className: f, ...a, children: /* @__PURE__ */ p("div", { className: rr.grid, style: b, children: o }) });
|
|
3533
|
+
}, kn = "MediaCard-module__card___9pZ7C", xn = "MediaCard-module__clickable___Rae9n", Cn = "MediaCard-module__vertical___GWtOA", Fn = "MediaCard-module__imageWrapper___HUiag", Vn = "MediaCard-module__horizontal___qlK4y", zn = "MediaCard-module__content___MlqE4", we = {
|
|
3534
|
+
card: kn,
|
|
3535
|
+
clickable: xn,
|
|
3536
|
+
vertical: Cn,
|
|
3537
|
+
imageWrapper: Fn,
|
|
3538
|
+
horizontal: Vn,
|
|
3539
|
+
content: zn
|
|
3540
|
+
}, Fa = ({
|
|
3541
|
+
direction: e = "column",
|
|
3542
|
+
imageSlot: r,
|
|
3543
|
+
imageWidth: t,
|
|
3544
|
+
backgroundColor: o,
|
|
3545
|
+
children: s,
|
|
3546
|
+
className: n,
|
|
3547
|
+
style: a,
|
|
3548
|
+
onClick: i,
|
|
3549
|
+
actions: f,
|
|
3550
|
+
divProps: c
|
|
3551
|
+
}) => {
|
|
3552
|
+
const u = R(), y = [
|
|
3553
|
+
we.card,
|
|
3554
|
+
e === "row" ? we.horizontal : we.vertical,
|
|
3555
|
+
i ? we.clickable : void 0,
|
|
3556
|
+
n
|
|
3557
|
+
].filter(Boolean).join(" "), m = {
|
|
3558
|
+
borderRadius: u.border.radius,
|
|
3559
|
+
...o && { backgroundColor: o },
|
|
3560
|
+
...t && e === "row" && { "--media-card-image-width": t },
|
|
3561
|
+
...a
|
|
3562
|
+
};
|
|
3563
|
+
return /* @__PURE__ */ D(
|
|
3564
|
+
"div",
|
|
3565
|
+
{
|
|
3566
|
+
...c,
|
|
3567
|
+
className: y,
|
|
3568
|
+
style: m,
|
|
3569
|
+
onClick: i,
|
|
3570
|
+
onKeyDown: i ? (b) => {
|
|
3571
|
+
i && (b.key === "Enter" || b.key === " ") && (b.preventDefault(), i());
|
|
3572
|
+
} : void 0,
|
|
3573
|
+
role: i ? "button" : void 0,
|
|
3574
|
+
tabIndex: i ? 0 : void 0,
|
|
3575
|
+
children: [
|
|
3576
|
+
r && /* @__PURE__ */ p("div", { className: we.imageWrapper, children: r }),
|
|
3577
|
+
/* @__PURE__ */ p("div", { className: we.content, children: s }),
|
|
3578
|
+
f
|
|
3579
|
+
]
|
|
3580
|
+
}
|
|
3581
|
+
);
|
|
3582
|
+
}, En = "PageLayout-module__layoutContainer___diLdT", Nn = "PageLayout-module__content___h2mBr", $n = "PageLayout-module__main___Sw7Pv", at = {
|
|
3583
|
+
layoutContainer: En,
|
|
3584
|
+
content: Nn,
|
|
3585
|
+
main: $n
|
|
3586
|
+
}, Va = ({
|
|
3541
3587
|
// Content
|
|
3542
3588
|
header: e,
|
|
3543
3589
|
footer: r,
|
|
@@ -3551,26 +3597,26 @@ const fa = ({
|
|
|
3551
3597
|
divProps: i,
|
|
3552
3598
|
mainProps: f
|
|
3553
3599
|
}) => {
|
|
3554
|
-
const c = [
|
|
3555
|
-
return /* @__PURE__ */
|
|
3556
|
-
/* @__PURE__ */
|
|
3557
|
-
e && /* @__PURE__ */ p(
|
|
3558
|
-
/* @__PURE__ */ p("main", { ...f, className:
|
|
3600
|
+
const c = [at.layoutContainer, o].filter(Boolean).join(" ");
|
|
3601
|
+
return /* @__PURE__ */ D("div", { ...i, className: c, style: s, children: [
|
|
3602
|
+
/* @__PURE__ */ D("div", { className: at.content, children: [
|
|
3603
|
+
e && /* @__PURE__ */ p(ks, { ...n, children: e }),
|
|
3604
|
+
/* @__PURE__ */ p("main", { ...f, className: at.main, children: t })
|
|
3559
3605
|
] }),
|
|
3560
|
-
r && /* @__PURE__ */ p(
|
|
3606
|
+
r && /* @__PURE__ */ p(hn, { ...a, children: r })
|
|
3561
3607
|
] });
|
|
3562
|
-
},
|
|
3563
|
-
dropzone:
|
|
3564
|
-
loading:
|
|
3565
|
-
dragOver:
|
|
3566
|
-
hiddenInput:
|
|
3567
|
-
content:
|
|
3568
|
-
contentHidden:
|
|
3569
|
-
spinnerOverlay:
|
|
3570
|
-
label:
|
|
3571
|
-
hint:
|
|
3572
|
-
errorMessage:
|
|
3573
|
-
},
|
|
3608
|
+
}, Ln = "FileUpload-module__dropzone___jqua0", An = "FileUpload-module__loading___C7PsH", Pn = "FileUpload-module__dragOver___q1zPo", Mn = "FileUpload-module__hiddenInput___RLLPJ", Bn = "FileUpload-module__content___yCP0l", Dn = "FileUpload-module__contentHidden___0Ewoe", Rn = "FileUpload-module__spinnerOverlay___e3Rle", On = "FileUpload-module__label___lbMkx", In = "FileUpload-module__hint___8dXlk", Tn = "FileUpload-module__errorMessage___8HB3n", ae = {
|
|
3609
|
+
dropzone: Ln,
|
|
3610
|
+
loading: An,
|
|
3611
|
+
dragOver: Pn,
|
|
3612
|
+
hiddenInput: Mn,
|
|
3613
|
+
content: Bn,
|
|
3614
|
+
contentHidden: Dn,
|
|
3615
|
+
spinnerOverlay: Rn,
|
|
3616
|
+
label: On,
|
|
3617
|
+
hint: In,
|
|
3618
|
+
errorMessage: Tn
|
|
3619
|
+
}, Hn = ({ color: e }) => /* @__PURE__ */ p(
|
|
3574
3620
|
"svg",
|
|
3575
3621
|
{
|
|
3576
3622
|
xmlns: "http://www.w3.org/2000/svg",
|
|
@@ -3581,7 +3627,7 @@ const fa = ({
|
|
|
3581
3627
|
"aria-hidden": !0,
|
|
3582
3628
|
children: /* @__PURE__ */ p("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" })
|
|
3583
3629
|
}
|
|
3584
|
-
),
|
|
3630
|
+
), za = ({
|
|
3585
3631
|
onUpload: e,
|
|
3586
3632
|
accept: r,
|
|
3587
3633
|
maxSizeBytes: t,
|
|
@@ -3593,7 +3639,7 @@ const fa = ({
|
|
|
3593
3639
|
divProps: f,
|
|
3594
3640
|
inputProps: c
|
|
3595
3641
|
}) => {
|
|
3596
|
-
const u =
|
|
3642
|
+
const u = R(), y = Ve(null), [m, C] = J(!1), [b, _] = J(null), k = s || b, V = k ? u.colors.error : u.colors.primary, g = k ? u.colors.error : u.colors.primary, F = Ce(
|
|
3597
3643
|
(L) => {
|
|
3598
3644
|
if (_(null), t && L.size > t) {
|
|
3599
3645
|
const A = (t / 1048576).toFixed(1);
|
|
@@ -3609,18 +3655,18 @@ const fa = ({
|
|
|
3609
3655
|
}, E = (L) => {
|
|
3610
3656
|
var A;
|
|
3611
3657
|
(L.key === "Enter" || L.key === " ") && !o && (L.preventDefault(), (A = y.current) == null || A.click());
|
|
3612
|
-
}, M = (L) => {
|
|
3613
|
-
var D;
|
|
3614
|
-
const A = (D = L.target.files) == null ? void 0 : D[0];
|
|
3615
|
-
A && F(A), L.target.value = "";
|
|
3616
3658
|
}, B = (L) => {
|
|
3659
|
+
var O;
|
|
3660
|
+
const A = (O = L.target.files) == null ? void 0 : O[0];
|
|
3661
|
+
A && F(A), L.target.value = "";
|
|
3662
|
+
}, M = (L) => {
|
|
3617
3663
|
L.preventDefault(), o || C(!0);
|
|
3618
|
-
},
|
|
3619
|
-
var
|
|
3664
|
+
}, U = () => C(!1), P = (L) => {
|
|
3665
|
+
var O;
|
|
3620
3666
|
if (L.preventDefault(), C(!1), o) return;
|
|
3621
|
-
const A = (
|
|
3667
|
+
const A = (O = L.dataTransfer.files) == null ? void 0 : O[0];
|
|
3622
3668
|
A && F(A);
|
|
3623
|
-
},
|
|
3669
|
+
}, K = [
|
|
3624
3670
|
ae.dropzone,
|
|
3625
3671
|
m && ae.dragOver,
|
|
3626
3672
|
o && ae.loading,
|
|
@@ -3634,16 +3680,16 @@ const fa = ({
|
|
|
3634
3680
|
color: g,
|
|
3635
3681
|
...i
|
|
3636
3682
|
};
|
|
3637
|
-
return /* @__PURE__ */
|
|
3683
|
+
return /* @__PURE__ */ D(
|
|
3638
3684
|
"div",
|
|
3639
3685
|
{
|
|
3640
3686
|
...f,
|
|
3641
|
-
className:
|
|
3687
|
+
className: K,
|
|
3642
3688
|
style: q,
|
|
3643
3689
|
onClick: z,
|
|
3644
3690
|
onKeyDown: E,
|
|
3645
|
-
onDragOver:
|
|
3646
|
-
onDragLeave:
|
|
3691
|
+
onDragOver: M,
|
|
3692
|
+
onDragLeave: U,
|
|
3647
3693
|
onDrop: P,
|
|
3648
3694
|
role: "button",
|
|
3649
3695
|
tabIndex: o ? -1 : 0,
|
|
@@ -3657,7 +3703,7 @@ const fa = ({
|
|
|
3657
3703
|
ref: y,
|
|
3658
3704
|
type: "file",
|
|
3659
3705
|
accept: r,
|
|
3660
|
-
onChange:
|
|
3706
|
+
onChange: B,
|
|
3661
3707
|
disabled: o,
|
|
3662
3708
|
className: ae.hiddenInput,
|
|
3663
3709
|
tabIndex: -1,
|
|
@@ -3665,26 +3711,26 @@ const fa = ({
|
|
|
3665
3711
|
}
|
|
3666
3712
|
),
|
|
3667
3713
|
o && /* @__PURE__ */ p(
|
|
3668
|
-
|
|
3714
|
+
Er,
|
|
3669
3715
|
{
|
|
3670
3716
|
fullScreen: !1,
|
|
3671
3717
|
className: ae.spinnerOverlay,
|
|
3672
3718
|
style: { fontSize: "1.5em" }
|
|
3673
3719
|
}
|
|
3674
3720
|
),
|
|
3675
|
-
/* @__PURE__ */
|
|
3721
|
+
/* @__PURE__ */ D(
|
|
3676
3722
|
"div",
|
|
3677
3723
|
{
|
|
3678
3724
|
className: [ae.content, o && ae.contentHidden].filter(Boolean).join(" "),
|
|
3679
3725
|
"aria-hidden": o || void 0,
|
|
3680
3726
|
children: [
|
|
3681
|
-
/* @__PURE__ */ p(
|
|
3727
|
+
/* @__PURE__ */ p(Hn, { color: V }),
|
|
3682
3728
|
/* @__PURE__ */ p("span", { className: ae.label, children: n }),
|
|
3683
|
-
r && /* @__PURE__ */
|
|
3729
|
+
r && /* @__PURE__ */ D("span", { className: ae.hint, children: [
|
|
3684
3730
|
"Accepted: ",
|
|
3685
3731
|
r
|
|
3686
3732
|
] }),
|
|
3687
|
-
t && /* @__PURE__ */
|
|
3733
|
+
t && /* @__PURE__ */ D("span", { className: ae.hint, children: [
|
|
3688
3734
|
"Max size: ",
|
|
3689
3735
|
(t / (1024 * 1024)).toFixed(1),
|
|
3690
3736
|
" MB"
|
|
@@ -3696,14 +3742,14 @@ const fa = ({
|
|
|
3696
3742
|
]
|
|
3697
3743
|
}
|
|
3698
3744
|
);
|
|
3699
|
-
},
|
|
3700
|
-
container:
|
|
3701
|
-
img:
|
|
3702
|
-
fallback:
|
|
3703
|
-
},
|
|
3704
|
-
skeleton:
|
|
3705
|
-
},
|
|
3706
|
-
const o =
|
|
3745
|
+
}, jn = "Image-module__container___sVJdZ", Wn = "Image-module__img___pKhPw", Un = "Image-module__fallback___wysuM", it = {
|
|
3746
|
+
container: jn,
|
|
3747
|
+
img: Wn,
|
|
3748
|
+
fallback: Un
|
|
3749
|
+
}, qn = "Skeleton-module__skeleton___CB4uF", Gn = {
|
|
3750
|
+
skeleton: qn
|
|
3751
|
+
}, Lr = ({ className: e, style: r, divProps: t }) => {
|
|
3752
|
+
const o = R(), s = [Gn.skeleton, e].filter(Boolean).join(" ");
|
|
3707
3753
|
return /* @__PURE__ */ p(
|
|
3708
3754
|
"div",
|
|
3709
3755
|
{
|
|
@@ -3714,7 +3760,7 @@ const fa = ({
|
|
|
3714
3760
|
"aria-busy": !0
|
|
3715
3761
|
}
|
|
3716
3762
|
);
|
|
3717
|
-
},
|
|
3763
|
+
}, Ea = ({
|
|
3718
3764
|
src: e,
|
|
3719
3765
|
alt: r = "",
|
|
3720
3766
|
aspectRatio: t = "1 / 1",
|
|
@@ -3725,34 +3771,34 @@ const fa = ({
|
|
|
3725
3771
|
style: i,
|
|
3726
3772
|
imgProps: f
|
|
3727
3773
|
}) => {
|
|
3728
|
-
const c =
|
|
3774
|
+
const c = R(), [u, y] = J(null), [m, C] = J(null), [b, _] = J(null), k = u === e, V = m === e, g = b === e;
|
|
3729
3775
|
ne(() => {
|
|
3730
3776
|
if (!e) return;
|
|
3731
|
-
const
|
|
3732
|
-
return () => clearTimeout(
|
|
3777
|
+
const U = setTimeout(() => _(e), s);
|
|
3778
|
+
return () => clearTimeout(U);
|
|
3733
3779
|
}, [e, s]);
|
|
3734
|
-
const F = o || !!e && !k && !V && g, z = !o && (!e || V), E = !o && !!e && !V,
|
|
3780
|
+
const F = o || !!e && !k && !V && g, z = !o && (!e || V), E = !o && !!e && !V, B = [it.container, a].filter(Boolean).join(" "), M = {
|
|
3735
3781
|
aspectRatio: t,
|
|
3736
3782
|
borderRadius: c.border.radius,
|
|
3737
3783
|
...i
|
|
3738
3784
|
};
|
|
3739
|
-
return /* @__PURE__ */
|
|
3785
|
+
return /* @__PURE__ */ D(
|
|
3740
3786
|
"div",
|
|
3741
3787
|
{
|
|
3742
|
-
className:
|
|
3743
|
-
style:
|
|
3788
|
+
className: B,
|
|
3789
|
+
style: M,
|
|
3744
3790
|
"aria-label": z ? r || "Image placeholder" : void 0,
|
|
3745
3791
|
"aria-busy": F || void 0,
|
|
3746
3792
|
children: [
|
|
3747
|
-
F && /* @__PURE__ */ p(
|
|
3748
|
-
z && /* @__PURE__ */ p("div", { className:
|
|
3793
|
+
F && /* @__PURE__ */ p(Lr, { style: { borderRadius: "inherit", position: "absolute", inset: 0 } }),
|
|
3794
|
+
z && /* @__PURE__ */ p("div", { className: it.fallback, children: n ?? null }),
|
|
3749
3795
|
E && /* @__PURE__ */ p(
|
|
3750
3796
|
"img",
|
|
3751
3797
|
{
|
|
3752
3798
|
...f,
|
|
3753
3799
|
src: e,
|
|
3754
3800
|
alt: r,
|
|
3755
|
-
className:
|
|
3801
|
+
className: it.img,
|
|
3756
3802
|
style: { opacity: k ? 1 : 0 },
|
|
3757
3803
|
onLoad: () => e && y(e),
|
|
3758
3804
|
onError: () => e && C(e)
|
|
@@ -3761,20 +3807,20 @@ const fa = ({
|
|
|
3761
3807
|
]
|
|
3762
3808
|
}
|
|
3763
3809
|
);
|
|
3764
|
-
},
|
|
3765
|
-
thumbnail:
|
|
3766
|
-
img:
|
|
3767
|
-
sizeXs:
|
|
3768
|
-
sizeSmall:
|
|
3769
|
-
sizeDefault:
|
|
3770
|
-
sizeLarge:
|
|
3771
|
-
removeButton:
|
|
3772
|
-
},
|
|
3810
|
+
}, Zn = "ImageThumbnail-module__thumbnail___-igbe", Kn = "ImageThumbnail-module__img___Q7Z4V", Qn = "ImageThumbnail-module__sizeXs___TvSHV", Xn = "ImageThumbnail-module__sizeSmall___2KnCh", Jn = "ImageThumbnail-module__sizeDefault___laoQk", Yn = "ImageThumbnail-module__sizeLarge___iwz3o", ea = "ImageThumbnail-module__removeButton___Ceh1Q", pe = {
|
|
3811
|
+
thumbnail: Zn,
|
|
3812
|
+
img: Kn,
|
|
3813
|
+
sizeXs: Qn,
|
|
3814
|
+
sizeSmall: Xn,
|
|
3815
|
+
sizeDefault: Jn,
|
|
3816
|
+
sizeLarge: Yn,
|
|
3817
|
+
removeButton: ea
|
|
3818
|
+
}, ta = {
|
|
3773
3819
|
xs: pe.sizeXs,
|
|
3774
3820
|
small: pe.sizeSmall,
|
|
3775
3821
|
default: pe.sizeDefault,
|
|
3776
3822
|
large: pe.sizeLarge
|
|
3777
|
-
},
|
|
3823
|
+
}, ra = ({ color: e }) => /* @__PURE__ */ D(
|
|
3778
3824
|
"svg",
|
|
3779
3825
|
{
|
|
3780
3826
|
xmlns: "http://www.w3.org/2000/svg",
|
|
@@ -3791,7 +3837,7 @@ const fa = ({
|
|
|
3791
3837
|
/* @__PURE__ */ p("polyline", { points: "21 15 16 10 5 21" })
|
|
3792
3838
|
]
|
|
3793
3839
|
}
|
|
3794
|
-
),
|
|
3840
|
+
), Na = ({
|
|
3795
3841
|
src: e,
|
|
3796
3842
|
alt: r = "",
|
|
3797
3843
|
size: t = "default",
|
|
@@ -3804,31 +3850,31 @@ const fa = ({
|
|
|
3804
3850
|
style: c,
|
|
3805
3851
|
imgProps: u
|
|
3806
3852
|
}) => {
|
|
3807
|
-
const y =
|
|
3853
|
+
const y = R(), [m, C] = J(null), [b, _] = J(null), [k, V] = J(null), g = m === e, F = b === e, z = k === e;
|
|
3808
3854
|
ne(() => {
|
|
3809
3855
|
if (!e) return;
|
|
3810
3856
|
const q = setTimeout(() => V(e), s);
|
|
3811
3857
|
return () => clearTimeout(q);
|
|
3812
3858
|
}, [e, s]);
|
|
3813
|
-
const E = o || !!e && !g && !F && z,
|
|
3859
|
+
const E = o || !!e && !g && !F && z, B = !o && (!e || F), M = !o && !!e && !F, U = [pe.thumbnail, ta[t], f].filter(Boolean).join(" "), P = {
|
|
3814
3860
|
borderRadius: y.border.radius,
|
|
3815
3861
|
...c
|
|
3816
|
-
},
|
|
3862
|
+
}, K = {
|
|
3817
3863
|
background: y.colors.primary,
|
|
3818
3864
|
color: y.buttons.primary.textColor,
|
|
3819
3865
|
borderRadius: "50%"
|
|
3820
3866
|
};
|
|
3821
|
-
return /* @__PURE__ */
|
|
3867
|
+
return /* @__PURE__ */ D(
|
|
3822
3868
|
"div",
|
|
3823
3869
|
{
|
|
3824
|
-
className:
|
|
3870
|
+
className: U,
|
|
3825
3871
|
style: P,
|
|
3826
|
-
"aria-label":
|
|
3872
|
+
"aria-label": B ? r || "Image placeholder" : void 0,
|
|
3827
3873
|
"aria-busy": E || void 0,
|
|
3828
3874
|
children: [
|
|
3829
|
-
E && /* @__PURE__ */ p(
|
|
3830
|
-
|
|
3831
|
-
|
|
3875
|
+
E && /* @__PURE__ */ p(Lr, { style: { borderRadius: "inherit", position: "absolute", inset: 0 } }),
|
|
3876
|
+
B && (i ?? /* @__PURE__ */ p(ra, { color: y.colors.primary })),
|
|
3877
|
+
M && /* @__PURE__ */ p(
|
|
3832
3878
|
"img",
|
|
3833
3879
|
{
|
|
3834
3880
|
...u,
|
|
@@ -3845,12 +3891,12 @@ const fa = ({
|
|
|
3845
3891
|
{
|
|
3846
3892
|
type: "button",
|
|
3847
3893
|
className: pe.removeButton,
|
|
3848
|
-
style:
|
|
3894
|
+
style: K,
|
|
3849
3895
|
onClick: (q) => {
|
|
3850
3896
|
q.stopPropagation(), n();
|
|
3851
3897
|
},
|
|
3852
3898
|
"aria-label": a,
|
|
3853
|
-
children: /* @__PURE__ */
|
|
3899
|
+
children: /* @__PURE__ */ D(
|
|
3854
3900
|
"svg",
|
|
3855
3901
|
{
|
|
3856
3902
|
viewBox: "0 0 10 10",
|
|
@@ -3873,52 +3919,53 @@ const fa = ({
|
|
|
3873
3919
|
);
|
|
3874
3920
|
};
|
|
3875
3921
|
export {
|
|
3876
|
-
|
|
3877
|
-
|
|
3878
|
-
|
|
3879
|
-
|
|
3880
|
-
|
|
3881
|
-
|
|
3882
|
-
|
|
3883
|
-
|
|
3884
|
-
|
|
3885
|
-
|
|
3886
|
-
|
|
3922
|
+
Kr as Button,
|
|
3923
|
+
la as CSSReset,
|
|
3924
|
+
ut as Checkbox,
|
|
3925
|
+
xa as FeatureCard,
|
|
3926
|
+
Ca as FeatureGridSection,
|
|
3927
|
+
za as FileUpload,
|
|
3928
|
+
hn as Footer,
|
|
3929
|
+
ca as Form,
|
|
3930
|
+
ma as FormCheckbox,
|
|
3931
|
+
_a as FormCheckboxGroup,
|
|
3932
|
+
jo as FormError,
|
|
3887
3933
|
ge as FormField,
|
|
3888
|
-
|
|
3889
|
-
|
|
3890
|
-
|
|
3891
|
-
|
|
3892
|
-
|
|
3893
|
-
|
|
3894
|
-
|
|
3895
|
-
|
|
3896
|
-
|
|
3897
|
-
|
|
3898
|
-
|
|
3899
|
-
|
|
3900
|
-
|
|
3901
|
-
|
|
3902
|
-
|
|
3903
|
-
|
|
3904
|
-
|
|
3905
|
-
|
|
3906
|
-
|
|
3907
|
-
|
|
3908
|
-
|
|
3909
|
-
|
|
3910
|
-
|
|
3911
|
-
|
|
3912
|
-
|
|
3913
|
-
|
|
3914
|
-
|
|
3915
|
-
|
|
3916
|
-
|
|
3917
|
-
|
|
3918
|
-
|
|
3919
|
-
|
|
3934
|
+
Ko as FormGroup,
|
|
3935
|
+
ua as FormInput,
|
|
3936
|
+
_t as FormLabel,
|
|
3937
|
+
ya as FormRadio,
|
|
3938
|
+
ha as FormRadioGroup,
|
|
3939
|
+
fa as FormSelect,
|
|
3940
|
+
da as FormTextarea,
|
|
3941
|
+
vs as Hamburger,
|
|
3942
|
+
ks as Header,
|
|
3943
|
+
ka as Hero,
|
|
3944
|
+
Ea as Image,
|
|
3945
|
+
Na as ImageThumbnail,
|
|
3946
|
+
es as Input,
|
|
3947
|
+
Er as LoadingSpinner,
|
|
3948
|
+
Fa as MediaCard,
|
|
3949
|
+
nn as Modal,
|
|
3950
|
+
Sa as ModalProvider,
|
|
3951
|
+
ga as NavDropdown,
|
|
3952
|
+
va as NavLink,
|
|
3953
|
+
Va as PageLayout,
|
|
3954
|
+
Vr as Popover,
|
|
3955
|
+
Fr as Radio,
|
|
3956
|
+
pa as ResponsiveNav,
|
|
3957
|
+
Hs as ResponsiveNavContext,
|
|
3958
|
+
$r as ResponsiveSection,
|
|
3959
|
+
us as Select,
|
|
3960
|
+
Lr as Skeleton,
|
|
3961
|
+
sn as Stack,
|
|
3962
|
+
ba as StyleLoader,
|
|
3963
|
+
ns as Textarea,
|
|
3964
|
+
ia as ThemeProvider,
|
|
3965
|
+
Le as parseBreakpoint,
|
|
3966
|
+
Oo as useFormContext,
|
|
3920
3967
|
ue as useMediaQuery,
|
|
3921
|
-
|
|
3922
|
-
|
|
3923
|
-
|
|
3968
|
+
wa as useModal,
|
|
3969
|
+
zr as useNavLinkStyles,
|
|
3970
|
+
R as useTheme
|
|
3924
3971
|
};
|