digital-rabbit-cl 1.3.4 → 1.3.6
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/Hamburger/useHamburgerStyles.d.ts +0 -1
- package/dist/components/Hamburger/useHamburgerStyles.d.ts.map +1 -1
- package/dist/components/Header/Header.d.ts +4 -0
- package/dist/components/Header/Header.d.ts.map +1 -1
- package/dist/components/ResponsiveNav/ResponsiveNav.d.ts.map +1 -1
- package/dist/digital-rabbit-cl.es.js +1005 -1101
- package/dist/digital-rabbit-cl.umd.js +4 -4
- package/dist/index.d.ts +2 -2
- package/dist/index.d.ts.map +1 -1
- package/package.json +1 -1
|
@@ -1,11 +1,11 @@
|
|
|
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)}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}.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:fixed;right:1em;width:2em;z-index:11}.Hamburger-module__line___gybZM{background:currentColor;border-radius:var(--hamburger-border-radius, 10px);height:.25em;position:relative;transform-origin:1px;transition:all .3s linear;width:2em}.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)}.ResponsiveNav-module__nav___xOfv5{display:flex}.ResponsiveNav-module__nav___xOfv5>*,.ResponsiveNav-module__nav___xOfv5>a{color:inherit;font-weight:700;text-decoration:none}.ResponsiveNav-module__navMobile___h795P{background:var(--mobile-nav-background, var(--accent-color));color:var(--mobile-nav-color, var(--primary-color));flex-direction:column;font-size:2rem;height:100vh;padding-top:var(--nav-padding-top);position:fixed;top:0;right:0;text-align:left;text-transform:uppercase;transition:transform .3s ease-in-out;width:100%;z-index:10;transform:translate(100%)}.ResponsiveNav-module__navMobile___h795P.ResponsiveNav-module__open___WDCAf{transform:translate(0)}.ResponsiveNav-module__navMobile___h795P>a{padding:var(--nav-link-padding);text-align:center;width:100%}.ResponsiveNav-module__navMobile___h795P>a.active,.ResponsiveNav-module__navMobile___h795P>a:hover{background:var(--mobile-nav-active-background, var(--primary-color));color:var(--mobile-nav-active-color, var(--accent-color))}.ResponsiveNav-module__navMobile___h795P>button{align-self:center;margin:var(--nav-button-margin)}.ResponsiveNav-module__navMobile___h795P>button:hover{color:var(--mobile-nav-button-hover-text-color, var(--accent-color))!important}.ResponsiveNav-module__navDesktop___9wscZ{align-items:center;flex-direction:row;height:auto}.ResponsiveNav-module__navDesktop___9wscZ>*{margin-left:1.25rem}.ResponsiveNav-module__navDesktop___9wscZ>a.active,.ResponsiveNav-module__navDesktop___9wscZ>a:hover{opacity:.5}.Stack-module__stack___yUU-B{display:flex;gap:.5em}.Stack-module__vertical___sKTyQ{flex-direction:column;margin-bottom:.5em}.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}')),document.head.appendChild(e)}}catch(o){console.error("vite-plugin-css-injected-by-js",o)}})();
|
|
2
|
-
import { jsx as
|
|
3
|
-
import
|
|
4
|
-
const
|
|
5
|
-
button:
|
|
6
|
-
sizeSmall:
|
|
7
|
-
sizeLarge:
|
|
8
|
-
},
|
|
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)}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}.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:.25em;position:relative;transform-origin:1px;transition:all .3s linear;width:2em}.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)}.ResponsiveNav-module__nav___xOfv5{display:flex}.ResponsiveNav-module__nav___xOfv5>*,.ResponsiveNav-module__nav___xOfv5>a{color:inherit;font-weight:700;text-decoration:none}.ResponsiveNav-module__navMobile___h795P{background:var(--mobile-nav-background, var(--accent-color));color:var(--mobile-nav-color, var(--primary-color));flex-direction:column;font-size:2rem;height:100vh;padding-top:var(--nav-padding-top);position:fixed;top:0;right:0;text-align:left;text-transform:uppercase;transition:transform .3s ease-in-out;width:100%;z-index:10;transform:translate(100%)}.ResponsiveNav-module__navMobile___h795P.ResponsiveNav-module__open___WDCAf{transform:translate(0)}.ResponsiveNav-module__navMobile___h795P>a{padding:var(--nav-link-padding);text-align:center;width:100%}.ResponsiveNav-module__navMobile___h795P>a.active,.ResponsiveNav-module__navMobile___h795P>a:hover{background:var(--mobile-nav-active-background, var(--primary-color));color:var(--mobile-nav-active-color, var(--accent-color))}.ResponsiveNav-module__navMobile___h795P>button{align-self:center;margin:var(--nav-button-margin)}.ResponsiveNav-module__navMobile___h795P>button:hover{color:var(--mobile-nav-button-hover-text-color, var(--accent-color))!important}.ResponsiveNav-module__navDesktop___9wscZ{align-items:center;flex-direction:row;height:auto}.ResponsiveNav-module__navDesktop___9wscZ>*{margin-left:1.25rem}.ResponsiveNav-module__navDesktop___9wscZ>a.active,.ResponsiveNav-module__navDesktop___9wscZ>a:hover{opacity:.5}.Stack-module__stack___yUU-B{display:flex;gap:.5em}.Stack-module__vertical___sKTyQ{flex-direction:column;margin-bottom:.5em}.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}')),document.head.appendChild(e)}}catch(o){console.error("vite-plugin-css-injected-by-js",o)}})();
|
|
2
|
+
import { jsx as V, jsxs as K, Fragment as et } from "react/jsx-runtime";
|
|
3
|
+
import $, { createContext as wr, useContext as kr, useState as tt, useLayoutEffect as Cr, useSyncExternalStore as zr, useMemo as De, useRef as St, useEffect as Wt } from "react";
|
|
4
|
+
const $r = "Button-module__button___2ZuB7", Er = "Button-module__sizeSmall___DRT8P", Ar = "Button-module__sizeLarge___yeZSH", Ve = {
|
|
5
|
+
button: $r,
|
|
6
|
+
sizeSmall: Er,
|
|
7
|
+
sizeLarge: Ar
|
|
8
|
+
}, Nr = ({
|
|
9
9
|
isActive: e,
|
|
10
10
|
disabled: r,
|
|
11
11
|
buttonColor: t = "#FFF",
|
|
@@ -14,30 +14,30 @@ const Ar = "Button-module__button___2ZuB7", Nr = "Button-module__sizeSmall___DRT
|
|
|
14
14
|
hoverTextColor: n,
|
|
15
15
|
outline: i
|
|
16
16
|
}) => {
|
|
17
|
-
let l, d,
|
|
18
|
-
i ? (l = "transparent", d = t,
|
|
17
|
+
let l, d, y;
|
|
18
|
+
i ? (l = "transparent", d = t, y = t, e && (l = o || t, d = o || t, y = n || s)) : (l = t, d = t, y = s, e && (l = o || t, d = o || t, y = n || s));
|
|
19
19
|
let f = 1;
|
|
20
20
|
return r ? f = 0.3 : e && (f = o ? 1 : 0.75), {
|
|
21
21
|
backgroundColor: l,
|
|
22
22
|
borderColor: d,
|
|
23
|
-
color:
|
|
23
|
+
color: y,
|
|
24
24
|
opacity: f
|
|
25
25
|
};
|
|
26
26
|
};
|
|
27
|
-
function
|
|
27
|
+
function qt(e, r) {
|
|
28
28
|
const t = { ...e };
|
|
29
|
-
return
|
|
29
|
+
return we(e) && we(r) && Object.keys(r).forEach((s) => {
|
|
30
30
|
const o = r[s], n = e[s];
|
|
31
|
-
|
|
31
|
+
we(o) && we(n) ? t[s] = qt(
|
|
32
32
|
n,
|
|
33
33
|
o
|
|
34
34
|
) : o !== void 0 && (t[s] = o);
|
|
35
35
|
}), t;
|
|
36
36
|
}
|
|
37
|
-
function
|
|
37
|
+
function we(e) {
|
|
38
38
|
return e && typeof e == "object" && !Array.isArray(e);
|
|
39
39
|
}
|
|
40
|
-
function
|
|
40
|
+
function Ee(e) {
|
|
41
41
|
const r = e.match(/^(\d+(?:\.\d+)?)(px|em|rem)$/);
|
|
42
42
|
if (!r) {
|
|
43
43
|
const o = parseInt(e, 10), n = e.replace(/[0-9.]/g, "") || "px";
|
|
@@ -59,7 +59,7 @@ const xt = {
|
|
|
59
59
|
error: "#F00",
|
|
60
60
|
success: "#008000",
|
|
61
61
|
warning: "#FFEB3B"
|
|
62
|
-
},
|
|
62
|
+
}, Qe = {
|
|
63
63
|
colors: xt,
|
|
64
64
|
fonts: {
|
|
65
65
|
color: "#000",
|
|
@@ -108,10 +108,10 @@ const xt = {
|
|
|
108
108
|
paddingSm: "0.5rem",
|
|
109
109
|
padding: "1rem"
|
|
110
110
|
}
|
|
111
|
-
},
|
|
112
|
-
const t = e ?
|
|
113
|
-
return /* @__PURE__ */
|
|
114
|
-
}, O = () =>
|
|
111
|
+
}, Gt = wr(Qe), Mo = ({ theme: e, children: r }) => {
|
|
112
|
+
const t = e ? qt(Qe, e) : Qe;
|
|
113
|
+
return /* @__PURE__ */ V(Gt.Provider, { value: t, children: r });
|
|
114
|
+
}, O = () => kr(Gt), jo = ({
|
|
115
115
|
// Color props
|
|
116
116
|
backgroundColor: e,
|
|
117
117
|
color: r,
|
|
@@ -124,79 +124,79 @@ const xt = {
|
|
|
124
124
|
type: l = "button",
|
|
125
125
|
// Standard React props
|
|
126
126
|
className: d,
|
|
127
|
-
style:
|
|
127
|
+
style: y,
|
|
128
128
|
buttonProps: f = {},
|
|
129
|
-
onClick:
|
|
130
|
-
children:
|
|
129
|
+
onClick: m,
|
|
130
|
+
children: h
|
|
131
131
|
}) => {
|
|
132
|
-
const
|
|
133
|
-
let
|
|
134
|
-
r ?
|
|
135
|
-
const
|
|
136
|
-
...
|
|
137
|
-
isActive:
|
|
132
|
+
const x = O(), [F, _] = tt(!1);
|
|
133
|
+
let C;
|
|
134
|
+
r ? C = r : C = e ? x.buttons.textColor : x.buttons.primary.textColor;
|
|
135
|
+
const A = e || x.colors.primary, z = {
|
|
136
|
+
...Nr({
|
|
137
|
+
isActive: F,
|
|
138
138
|
disabled: o,
|
|
139
|
-
buttonColor:
|
|
140
|
-
textColor:
|
|
139
|
+
buttonColor: A,
|
|
140
|
+
textColor: C,
|
|
141
141
|
hoverBackgroundColor: t,
|
|
142
142
|
hoverTextColor: s,
|
|
143
143
|
outline: i
|
|
144
144
|
}),
|
|
145
|
-
fontSize:
|
|
146
|
-
borderWidth:
|
|
147
|
-
borderRadius:
|
|
148
|
-
"--button-padding-small": `calc(${
|
|
149
|
-
"--button-padding-large": `calc(${
|
|
150
|
-
...
|
|
145
|
+
fontSize: x.fonts.size,
|
|
146
|
+
borderWidth: x.border.width,
|
|
147
|
+
borderRadius: x.border.radius,
|
|
148
|
+
"--button-padding-small": `calc(${x.fonts.rhythm} * ${x.sizes.small.paddingVertical}) calc(${x.fonts.rhythm} * ${x.buttons.paddingHorizontal})`,
|
|
149
|
+
"--button-padding-large": `calc(${x.fonts.rhythm} * ${x.sizes.large.paddingVertical}) calc(${x.fonts.rhythm} * ${x.buttons.paddingHorizontal})`,
|
|
150
|
+
...y
|
|
151
151
|
// Top-level style overrides
|
|
152
|
-
},
|
|
153
|
-
|
|
154
|
-
n === "small" ?
|
|
155
|
-
i ?
|
|
152
|
+
}, k = [
|
|
153
|
+
Ve.button,
|
|
154
|
+
n === "small" ? Ve.sizeSmall : Ve.sizeLarge,
|
|
155
|
+
i ? Ve.outline : "",
|
|
156
156
|
d
|
|
157
157
|
].filter(Boolean).join(" ");
|
|
158
|
-
return /* @__PURE__ */
|
|
158
|
+
return /* @__PURE__ */ V(
|
|
159
159
|
"button",
|
|
160
160
|
{
|
|
161
161
|
...f,
|
|
162
|
-
className:
|
|
162
|
+
className: k,
|
|
163
163
|
disabled: o,
|
|
164
|
-
onClick:
|
|
165
|
-
onMouseEnter: () =>
|
|
166
|
-
onMouseLeave: () =>
|
|
164
|
+
onClick: m,
|
|
165
|
+
onMouseEnter: () => _(!0),
|
|
166
|
+
onMouseLeave: () => _(!1),
|
|
167
167
|
type: l,
|
|
168
|
-
style:
|
|
169
|
-
children:
|
|
168
|
+
style: z,
|
|
169
|
+
children: h
|
|
170
170
|
}
|
|
171
171
|
);
|
|
172
172
|
};
|
|
173
|
-
var
|
|
174
|
-
function
|
|
175
|
-
if (!
|
|
173
|
+
var Ft = typeof crypto < "u" && crypto.getRandomValues && crypto.getRandomValues.bind(crypto) || typeof msCrypto < "u" && typeof msCrypto.getRandomValues == "function" && msCrypto.getRandomValues.bind(msCrypto), Rr = new Uint8Array(16);
|
|
174
|
+
function Dr() {
|
|
175
|
+
if (!Ft)
|
|
176
176
|
throw new Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");
|
|
177
|
-
return
|
|
177
|
+
return Ft(Rr);
|
|
178
178
|
}
|
|
179
|
-
var
|
|
180
|
-
for (var
|
|
181
|
-
|
|
182
|
-
function
|
|
183
|
-
var t = 0, s =
|
|
179
|
+
var Zt = [];
|
|
180
|
+
for (var ke = 0; ke < 256; ++ke)
|
|
181
|
+
Zt[ke] = (ke + 256).toString(16).substr(1);
|
|
182
|
+
function Pr(e, r) {
|
|
183
|
+
var t = 0, s = Zt;
|
|
184
184
|
return [s[e[t++]], s[e[t++]], s[e[t++]], s[e[t++]], "-", s[e[t++]], s[e[t++]], "-", s[e[t++]], s[e[t++]], "-", s[e[t++]], s[e[t++]], "-", s[e[t++]], s[e[t++]], s[e[t++]], s[e[t++]], s[e[t++]], s[e[t++]]].join("");
|
|
185
185
|
}
|
|
186
|
-
function
|
|
186
|
+
function Qt(e, r, t) {
|
|
187
187
|
var s = r && t || 0;
|
|
188
188
|
typeof e == "string" && (r = e === "binary" ? new Array(16) : null, e = null), e = e || {};
|
|
189
|
-
var o = e.random || (e.rng ||
|
|
189
|
+
var o = e.random || (e.rng || Dr)();
|
|
190
190
|
if (o[6] = o[6] & 15 | 64, o[8] = o[8] & 63 | 128, r)
|
|
191
191
|
for (var n = 0; n < 16; ++n)
|
|
192
192
|
r[s + n] = o[n];
|
|
193
|
-
return r ||
|
|
193
|
+
return r || Pr(o);
|
|
194
194
|
}
|
|
195
|
-
const
|
|
196
|
-
container:
|
|
197
|
-
svg:
|
|
198
|
-
label:
|
|
199
|
-
},
|
|
195
|
+
const Lr = "Checkbox-module__container___aV9qz", Br = "Checkbox-module__svg___kkluC", Or = "Checkbox-module__label___cwRtI", Me = {
|
|
196
|
+
container: Lr,
|
|
197
|
+
svg: Br,
|
|
198
|
+
label: Or
|
|
199
|
+
}, Hr = ({
|
|
200
200
|
color: e = "#000",
|
|
201
201
|
checkmarkColor: r,
|
|
202
202
|
disabled: t = !1,
|
|
@@ -209,10 +209,10 @@ const Or = "Checkbox-module__container___aV9qz", Hr = "Checkbox-module__svg___kk
|
|
|
209
209
|
cursor: t ? "default" : "pointer",
|
|
210
210
|
opacity: t ? 0.3 : 1
|
|
211
211
|
};
|
|
212
|
-
},
|
|
213
|
-
label:
|
|
214
|
-
disabled:
|
|
215
|
-
},
|
|
212
|
+
}, Tr = "FormLabel-module__label___0M-fo", Mr = "FormLabel-module__disabled___ktIFp", Vt = {
|
|
213
|
+
label: Tr,
|
|
214
|
+
disabled: Mr
|
|
215
|
+
}, jr = ({
|
|
216
216
|
color: e = "#000",
|
|
217
217
|
disabled: r = !1,
|
|
218
218
|
fontSize: t = ".85em"
|
|
@@ -221,7 +221,7 @@ const Or = "Checkbox-module__container___aV9qz", Hr = "Checkbox-module__svg___kk
|
|
|
221
221
|
fontSize: t,
|
|
222
222
|
opacity: r ? 0.5 : 1,
|
|
223
223
|
cursor: r ? "not-allowed" : "default"
|
|
224
|
-
}),
|
|
224
|
+
}), rt = ({
|
|
225
225
|
// Color prop
|
|
226
226
|
color: e,
|
|
227
227
|
// State props
|
|
@@ -237,21 +237,21 @@ const Or = "Checkbox-module__container___aV9qz", Hr = "Checkbox-module__svg___kk
|
|
|
237
237
|
// Element-specific props
|
|
238
238
|
labelProps: l
|
|
239
239
|
}) => {
|
|
240
|
-
const d = O(),
|
|
240
|
+
const d = O(), y = d.colors.error, f = t ? y : e || d.colors.primary, m = jr({
|
|
241
241
|
color: f,
|
|
242
242
|
disabled: r,
|
|
243
243
|
fontSize: ".85em"
|
|
244
|
-
}),
|
|
244
|
+
}), h = {
|
|
245
245
|
"--form-label-padding-bottom": `calc(${d.fonts.rhythm} * 0.17)`,
|
|
246
|
-
color:
|
|
247
|
-
fontSize:
|
|
248
|
-
opacity:
|
|
249
|
-
cursor:
|
|
246
|
+
color: m.color,
|
|
247
|
+
fontSize: m.fontSize,
|
|
248
|
+
opacity: m.opacity,
|
|
249
|
+
cursor: m.cursor,
|
|
250
250
|
...i
|
|
251
251
|
// Top level style prop overrides
|
|
252
|
-
},
|
|
253
|
-
return /* @__PURE__ */
|
|
254
|
-
},
|
|
252
|
+
}, x = [Vt.label, r ? Vt.disabled : "", n].filter(Boolean).join(" ");
|
|
253
|
+
return /* @__PURE__ */ V("label", { ...l, className: x, htmlFor: s, style: h, children: o });
|
|
254
|
+
}, Ir = ({
|
|
255
255
|
// Color props
|
|
256
256
|
color: e,
|
|
257
257
|
checkmarkColor: r,
|
|
@@ -264,46 +264,46 @@ const Or = "Checkbox-module__container___aV9qz", Hr = "Checkbox-module__svg___kk
|
|
|
264
264
|
name: i,
|
|
265
265
|
id: l,
|
|
266
266
|
onChange: d,
|
|
267
|
-
label:
|
|
267
|
+
label: y,
|
|
268
268
|
labelStyle: f,
|
|
269
269
|
// Style overrides
|
|
270
|
-
className:
|
|
271
|
-
style:
|
|
270
|
+
className: m,
|
|
271
|
+
style: h,
|
|
272
272
|
// Element-specific props
|
|
273
|
-
divProps:
|
|
273
|
+
divProps: x
|
|
274
274
|
}) => {
|
|
275
|
-
const
|
|
276
|
-
color:
|
|
275
|
+
const F = O(), _ = l || Qt(), C = F.colors.error, A = n ? C : e || F.colors.primary, S = Hr({
|
|
276
|
+
color: A,
|
|
277
277
|
checkmarkColor: r,
|
|
278
278
|
disabled: o,
|
|
279
279
|
inverted: s
|
|
280
|
-
}),
|
|
281
|
-
o || d(
|
|
282
|
-
},
|
|
280
|
+
}), z = (j) => {
|
|
281
|
+
o || d(j);
|
|
282
|
+
}, k = {
|
|
283
283
|
cursor: S.cursor,
|
|
284
|
-
fontSize:
|
|
284
|
+
fontSize: F.fonts.size,
|
|
285
285
|
opacity: S.opacity,
|
|
286
|
-
...
|
|
286
|
+
...h
|
|
287
287
|
// Top-level style prop overrides
|
|
288
|
-
},
|
|
288
|
+
}, E = {
|
|
289
289
|
width: "1em"
|
|
290
|
-
},
|
|
290
|
+
}, H = {
|
|
291
291
|
fill: s && t ? S.checkboxColor : "transparent",
|
|
292
292
|
strokeWidth: "25",
|
|
293
293
|
stroke: S.checkboxColor
|
|
294
|
-
},
|
|
294
|
+
}, M = {
|
|
295
295
|
stroke: S.checkmarkColor,
|
|
296
296
|
strokeWidth: "15",
|
|
297
297
|
fill: "transparent"
|
|
298
|
-
},
|
|
299
|
-
return /* @__PURE__ */ K("div", { ...
|
|
300
|
-
/* @__PURE__ */
|
|
298
|
+
}, ee = [Me.container, m].filter(Boolean).join(" ");
|
|
299
|
+
return /* @__PURE__ */ K("div", { ...x, className: ee, style: k, children: [
|
|
300
|
+
/* @__PURE__ */ V(
|
|
301
301
|
"input",
|
|
302
302
|
{
|
|
303
|
-
id:
|
|
303
|
+
id: _,
|
|
304
304
|
checked: t,
|
|
305
305
|
disabled: o,
|
|
306
|
-
onChange: (
|
|
306
|
+
onChange: (j) => z({ target: { checked: j.target.checked, name: i, type: "checkbox" } }),
|
|
307
307
|
name: i,
|
|
308
308
|
style: { display: "none" },
|
|
309
309
|
type: "checkbox"
|
|
@@ -314,87 +314,87 @@ const Or = "Checkbox-module__container___aV9qz", Hr = "Checkbox-module__svg___kk
|
|
|
314
314
|
{
|
|
315
315
|
xmlns: "http://www.w3.org/2000/svg",
|
|
316
316
|
viewBox: "0 0 100 100",
|
|
317
|
-
onClick: () =>
|
|
318
|
-
style:
|
|
319
|
-
className:
|
|
317
|
+
onClick: () => z({ target: { checked: !t, name: i, type: "checkbox" } }),
|
|
318
|
+
style: E,
|
|
319
|
+
className: Me.svg,
|
|
320
320
|
children: [
|
|
321
|
-
/* @__PURE__ */
|
|
322
|
-
t && /* @__PURE__ */
|
|
321
|
+
/* @__PURE__ */ V("rect", { x: "0", y: "0", height: "100", width: "100", style: H }),
|
|
322
|
+
t && /* @__PURE__ */ V("path", { d: "M 25 45 L 45 65 L 75 30", style: M })
|
|
323
323
|
]
|
|
324
324
|
}
|
|
325
325
|
),
|
|
326
|
-
|
|
327
|
-
|
|
326
|
+
y && /* @__PURE__ */ V(
|
|
327
|
+
rt,
|
|
328
328
|
{
|
|
329
|
-
htmlFor:
|
|
330
|
-
className:
|
|
329
|
+
htmlFor: _,
|
|
330
|
+
className: Me.label,
|
|
331
331
|
style: { paddingBottom: 0, ...f },
|
|
332
332
|
color: S.checkboxColor,
|
|
333
333
|
disabled: o,
|
|
334
334
|
error: n,
|
|
335
|
-
children:
|
|
335
|
+
children: y
|
|
336
336
|
}
|
|
337
337
|
)
|
|
338
338
|
] });
|
|
339
339
|
}, Io = () => {
|
|
340
340
|
const e = O();
|
|
341
|
-
return
|
|
341
|
+
return Cr(() => {
|
|
342
342
|
const r = document.documentElement;
|
|
343
343
|
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));
|
|
344
344
|
}, [e]), null;
|
|
345
345
|
};
|
|
346
|
-
var
|
|
347
|
-
const
|
|
348
|
-
var
|
|
346
|
+
var be = (e) => e.type === "checkbox", ue = (e) => e instanceof Date, Q = (e) => e == null;
|
|
347
|
+
const Kt = (e) => typeof e == "object";
|
|
348
|
+
var U = (e) => !Q(e) && !Array.isArray(e) && Kt(e) && !ue(e), Jt = (e) => U(e) && e.target ? be(e.target) ? e.target.checked : e.target.value : e, Ur = (e) => e.substring(0, e.search(/\.\d+(\.|$)/)) || e, Xt = (e, r) => e.has(Ur(r)), Wr = (e) => {
|
|
349
349
|
const r = e.constructor && e.constructor.prototype;
|
|
350
|
-
return
|
|
351
|
-
},
|
|
352
|
-
function
|
|
350
|
+
return U(r) && r.hasOwnProperty("isPrototypeOf");
|
|
351
|
+
}, st = typeof window < "u" && typeof window.HTMLElement < "u" && typeof document < "u";
|
|
352
|
+
function W(e) {
|
|
353
353
|
let r;
|
|
354
354
|
const t = Array.isArray(e), s = typeof FileList < "u" ? e instanceof FileList : !1;
|
|
355
355
|
if (e instanceof Date)
|
|
356
356
|
r = new Date(e);
|
|
357
|
-
else if (!(
|
|
358
|
-
if (r = t ? [] : Object.create(Object.getPrototypeOf(e)), !t && !
|
|
357
|
+
else if (!(st && (e instanceof Blob || s)) && (t || U(e)))
|
|
358
|
+
if (r = t ? [] : Object.create(Object.getPrototypeOf(e)), !t && !Wr(e))
|
|
359
359
|
r = e;
|
|
360
360
|
else
|
|
361
361
|
for (const o in e)
|
|
362
|
-
e.hasOwnProperty(o) && (r[o] =
|
|
362
|
+
e.hasOwnProperty(o) && (r[o] = W(e[o]));
|
|
363
363
|
else
|
|
364
364
|
return e;
|
|
365
365
|
return r;
|
|
366
366
|
}
|
|
367
|
-
var
|
|
368
|
-
if (!r || !
|
|
367
|
+
var Pe = (e) => /^\w*$/.test(e), B = (e) => e === void 0, ot = (e) => Array.isArray(e) ? e.filter(Boolean) : [], nt = (e) => ot(e.replace(/["|']|\]/g, "").split(/\.|\[/)), v = (e, r, t) => {
|
|
368
|
+
if (!r || !U(e))
|
|
369
369
|
return t;
|
|
370
|
-
const s = (
|
|
370
|
+
const s = (Pe(r) ? [r] : nt(r)).reduce((o, n) => Q(o) ? o : o[n], e);
|
|
371
371
|
return B(s) || s === e ? B(e[r]) ? t : e[r] : s;
|
|
372
372
|
}, J = (e) => typeof e == "boolean", D = (e, r, t) => {
|
|
373
373
|
let s = -1;
|
|
374
|
-
const o =
|
|
374
|
+
const o = Pe(r) ? [r] : nt(r), n = o.length, i = n - 1;
|
|
375
375
|
for (; ++s < n; ) {
|
|
376
376
|
const l = o[s];
|
|
377
377
|
let d = t;
|
|
378
378
|
if (s !== i) {
|
|
379
|
-
const
|
|
380
|
-
d =
|
|
379
|
+
const y = e[l];
|
|
380
|
+
d = U(y) || Array.isArray(y) ? y : isNaN(+o[s + 1]) ? {} : [];
|
|
381
381
|
}
|
|
382
382
|
if (l === "__proto__" || l === "constructor" || l === "prototype")
|
|
383
383
|
return;
|
|
384
384
|
e[l] = d, e = e[l];
|
|
385
385
|
}
|
|
386
386
|
};
|
|
387
|
-
const
|
|
387
|
+
const Ae = {
|
|
388
388
|
BLUR: "blur",
|
|
389
389
|
FOCUS_OUT: "focusout",
|
|
390
390
|
CHANGE: "change"
|
|
391
|
-
},
|
|
391
|
+
}, re = {
|
|
392
392
|
onBlur: "onBlur",
|
|
393
393
|
onChange: "onChange",
|
|
394
394
|
onSubmit: "onSubmit",
|
|
395
395
|
onTouched: "onTouched",
|
|
396
396
|
all: "all"
|
|
397
|
-
},
|
|
397
|
+
}, le = {
|
|
398
398
|
max: "max",
|
|
399
399
|
min: "min",
|
|
400
400
|
maxLength: "maxLength",
|
|
@@ -402,10 +402,10 @@ const Ne = {
|
|
|
402
402
|
pattern: "pattern",
|
|
403
403
|
required: "required",
|
|
404
404
|
validate: "validate"
|
|
405
|
-
},
|
|
406
|
-
|
|
407
|
-
const
|
|
408
|
-
var
|
|
405
|
+
}, Yt = $.createContext(null);
|
|
406
|
+
Yt.displayName = "HookFormContext";
|
|
407
|
+
const it = () => $.useContext(Yt);
|
|
408
|
+
var er = (e, r, t, s = !0) => {
|
|
409
409
|
const o = {
|
|
410
410
|
defaultValues: r._defaultValues
|
|
411
411
|
};
|
|
@@ -413,14 +413,14 @@ var tr = (e, r, t, s = !0) => {
|
|
|
413
413
|
Object.defineProperty(o, n, {
|
|
414
414
|
get: () => {
|
|
415
415
|
const i = n;
|
|
416
|
-
return r._proxyFormState[i] !==
|
|
416
|
+
return r._proxyFormState[i] !== re.all && (r._proxyFormState[i] = !s || re.all), t && (t[i] = !0), e[i];
|
|
417
417
|
}
|
|
418
418
|
});
|
|
419
419
|
return o;
|
|
420
420
|
};
|
|
421
|
-
const
|
|
422
|
-
function
|
|
423
|
-
const r =
|
|
421
|
+
const at = typeof window < "u" ? $.useLayoutEffect : $.useEffect;
|
|
422
|
+
function qr(e) {
|
|
423
|
+
const r = it(), { control: t = r.control, disabled: s, name: o, exact: n } = e || {}, [i, l] = $.useState(t._formState), d = $.useRef({
|
|
424
424
|
isDirty: !1,
|
|
425
425
|
isLoading: !1,
|
|
426
426
|
dirtyFields: !1,
|
|
@@ -430,23 +430,23 @@ function Gr(e) {
|
|
|
430
430
|
isValid: !1,
|
|
431
431
|
errors: !1
|
|
432
432
|
});
|
|
433
|
-
return
|
|
433
|
+
return at(() => t._subscribe({
|
|
434
434
|
name: o,
|
|
435
435
|
formState: d.current,
|
|
436
436
|
exact: n,
|
|
437
|
-
callback: (
|
|
437
|
+
callback: (y) => {
|
|
438
438
|
!s && l({
|
|
439
439
|
...t._formState,
|
|
440
|
-
...
|
|
440
|
+
...y
|
|
441
441
|
});
|
|
442
442
|
}
|
|
443
|
-
}), [o, s, n]),
|
|
443
|
+
}), [o, s, n]), $.useEffect(() => {
|
|
444
444
|
d.current.isValid && t._setValid(!0);
|
|
445
|
-
}, [t]),
|
|
445
|
+
}, [t]), $.useMemo(() => er(i, t, d.current, !1), [i, t]);
|
|
446
446
|
}
|
|
447
|
-
var X = (e) => typeof e == "string",
|
|
448
|
-
function
|
|
449
|
-
if (
|
|
447
|
+
var X = (e) => typeof e == "string", Ke = (e, r, t, s, o) => X(e) ? (s && r.watch.add(e), v(t, e, o)) : Array.isArray(e) ? e.map((n) => (s && r.watch.add(n), v(t, n))) : (s && (r.watchAll = !0), t), Je = (e) => Q(e) || !Kt(e);
|
|
448
|
+
function se(e, r, t = /* @__PURE__ */ new WeakSet()) {
|
|
449
|
+
if (Je(e) || Je(r))
|
|
450
450
|
return e === r;
|
|
451
451
|
if (ue(e) && ue(r))
|
|
452
452
|
return e.getTime() === r.getTime();
|
|
@@ -462,66 +462,66 @@ function re(e, r, t = /* @__PURE__ */ new WeakSet()) {
|
|
|
462
462
|
return !1;
|
|
463
463
|
if (n !== "ref") {
|
|
464
464
|
const l = r[n];
|
|
465
|
-
if (ue(i) && ue(l) ||
|
|
465
|
+
if (ue(i) && ue(l) || U(i) && U(l) || Array.isArray(i) && Array.isArray(l) ? !se(i, l, t) : i !== l)
|
|
466
466
|
return !1;
|
|
467
467
|
}
|
|
468
468
|
}
|
|
469
469
|
return !0;
|
|
470
470
|
}
|
|
471
|
-
function
|
|
472
|
-
const r =
|
|
473
|
-
|
|
474
|
-
const [
|
|
475
|
-
const
|
|
476
|
-
return
|
|
477
|
-
}),
|
|
478
|
-
const
|
|
479
|
-
return
|
|
480
|
-
}, [t._formValues, t._names, s]),
|
|
471
|
+
function Gr(e) {
|
|
472
|
+
const r = it(), { control: t = r.control, name: s, defaultValue: o, disabled: n, exact: i, compute: l } = e || {}, d = $.useRef(o), y = $.useRef(l), f = $.useRef(void 0), m = $.useRef(t), h = $.useRef(s);
|
|
473
|
+
y.current = l;
|
|
474
|
+
const [x, F] = $.useState(() => {
|
|
475
|
+
const k = t._getWatch(s, d.current);
|
|
476
|
+
return y.current ? y.current(k) : k;
|
|
477
|
+
}), _ = $.useCallback((k) => {
|
|
478
|
+
const E = Ke(s, t._names, k || t._formValues, !1, d.current);
|
|
479
|
+
return y.current ? y.current(E) : E;
|
|
480
|
+
}, [t._formValues, t._names, s]), C = $.useCallback((k) => {
|
|
481
481
|
if (!n) {
|
|
482
|
-
const
|
|
483
|
-
if (
|
|
484
|
-
const
|
|
485
|
-
|
|
482
|
+
const E = Ke(s, t._names, k || t._formValues, !1, d.current);
|
|
483
|
+
if (y.current) {
|
|
484
|
+
const H = y.current(E);
|
|
485
|
+
se(H, f.current) || (F(H), f.current = H);
|
|
486
486
|
} else
|
|
487
|
-
|
|
487
|
+
F(E);
|
|
488
488
|
}
|
|
489
489
|
}, [t._formValues, t._names, n, s]);
|
|
490
|
-
|
|
490
|
+
at(() => ((m.current !== t || !se(h.current, s)) && (m.current = t, h.current = s, C()), t._subscribe({
|
|
491
491
|
name: s,
|
|
492
492
|
formState: {
|
|
493
493
|
values: !0
|
|
494
494
|
},
|
|
495
495
|
exact: i,
|
|
496
|
-
callback: (
|
|
497
|
-
|
|
496
|
+
callback: (k) => {
|
|
497
|
+
C(k.values);
|
|
498
498
|
}
|
|
499
|
-
})), [t, i, s,
|
|
500
|
-
const
|
|
499
|
+
})), [t, i, s, C]), $.useEffect(() => t._removeUnmounted());
|
|
500
|
+
const A = m.current !== t, S = h.current, z = $.useMemo(() => {
|
|
501
501
|
if (n)
|
|
502
502
|
return null;
|
|
503
|
-
const
|
|
504
|
-
return
|
|
505
|
-
}, [n,
|
|
506
|
-
return
|
|
503
|
+
const k = !A && !se(S, s);
|
|
504
|
+
return A || k ? _() : null;
|
|
505
|
+
}, [n, A, s, S, _]);
|
|
506
|
+
return z !== null ? z : x;
|
|
507
507
|
}
|
|
508
|
-
function
|
|
509
|
-
const r =
|
|
508
|
+
function Zr(e) {
|
|
509
|
+
const r = it(), { name: t, disabled: s, control: o = r.control, shouldUnregister: n, defaultValue: i } = e, l = Xt(o._names.array, t), d = $.useMemo(() => v(o._formValues, t, v(o._defaultValues, t, i)), [o, t, i]), y = Gr({
|
|
510
510
|
control: o,
|
|
511
511
|
name: t,
|
|
512
512
|
defaultValue: d,
|
|
513
513
|
exact: !0
|
|
514
|
-
}), f =
|
|
514
|
+
}), f = qr({
|
|
515
515
|
control: o,
|
|
516
516
|
name: t,
|
|
517
517
|
exact: !0
|
|
518
|
-
}),
|
|
518
|
+
}), m = $.useRef(e), h = $.useRef(void 0), x = $.useRef(o.register(t, {
|
|
519
519
|
...e.rules,
|
|
520
|
-
value:
|
|
520
|
+
value: y,
|
|
521
521
|
...J(e.disabled) ? { disabled: e.disabled } : {}
|
|
522
522
|
}));
|
|
523
|
-
|
|
524
|
-
const
|
|
523
|
+
m.current = e;
|
|
524
|
+
const F = $.useMemo(() => Object.defineProperties({}, {
|
|
525
525
|
invalid: {
|
|
526
526
|
enumerable: !0,
|
|
527
527
|
get: () => !!v(f.errors, t)
|
|
@@ -542,69 +542,69 @@ function Qr(e) {
|
|
|
542
542
|
enumerable: !0,
|
|
543
543
|
get: () => v(f.errors, t)
|
|
544
544
|
}
|
|
545
|
-
}), [f, t]),
|
|
545
|
+
}), [f, t]), _ = $.useCallback((z) => x.current.onChange({
|
|
546
546
|
target: {
|
|
547
|
-
value:
|
|
547
|
+
value: Jt(z),
|
|
548
548
|
name: t
|
|
549
549
|
},
|
|
550
|
-
type:
|
|
551
|
-
}), [t]),
|
|
550
|
+
type: Ae.CHANGE
|
|
551
|
+
}), [t]), C = $.useCallback(() => x.current.onBlur({
|
|
552
552
|
target: {
|
|
553
553
|
value: v(o._formValues, t),
|
|
554
554
|
name: t
|
|
555
555
|
},
|
|
556
|
-
type:
|
|
557
|
-
}), [t, o._formValues]),
|
|
558
|
-
const
|
|
559
|
-
|
|
560
|
-
focus: () =>
|
|
561
|
-
select: () =>
|
|
562
|
-
setCustomValidity: (
|
|
563
|
-
reportValidity: () =>
|
|
556
|
+
type: Ae.BLUR
|
|
557
|
+
}), [t, o._formValues]), A = $.useCallback((z) => {
|
|
558
|
+
const k = v(o._fields, t);
|
|
559
|
+
k && z && (k._f.ref = {
|
|
560
|
+
focus: () => z.focus && z.focus(),
|
|
561
|
+
select: () => z.select && z.select(),
|
|
562
|
+
setCustomValidity: (E) => z.setCustomValidity(E),
|
|
563
|
+
reportValidity: () => z.reportValidity()
|
|
564
564
|
});
|
|
565
|
-
}, [o._fields, t]), S =
|
|
565
|
+
}, [o._fields, t]), S = $.useMemo(() => ({
|
|
566
566
|
name: t,
|
|
567
|
-
value:
|
|
567
|
+
value: y,
|
|
568
568
|
...J(s) || f.disabled ? { disabled: f.disabled || s } : {},
|
|
569
|
-
onChange:
|
|
570
|
-
onBlur:
|
|
571
|
-
ref:
|
|
572
|
-
}), [t, s, f.disabled,
|
|
573
|
-
return
|
|
574
|
-
const
|
|
575
|
-
|
|
576
|
-
...
|
|
577
|
-
...J(
|
|
569
|
+
onChange: _,
|
|
570
|
+
onBlur: C,
|
|
571
|
+
ref: A
|
|
572
|
+
}), [t, s, f.disabled, _, C, A, y]);
|
|
573
|
+
return $.useEffect(() => {
|
|
574
|
+
const z = o._options.shouldUnregister || n, k = h.current;
|
|
575
|
+
k && k !== t && !l && o.unregister(k), o.register(t, {
|
|
576
|
+
...m.current.rules,
|
|
577
|
+
...J(m.current.disabled) ? { disabled: m.current.disabled } : {}
|
|
578
578
|
});
|
|
579
|
-
const
|
|
580
|
-
const
|
|
581
|
-
|
|
579
|
+
const E = (H, M) => {
|
|
580
|
+
const ee = v(o._fields, H);
|
|
581
|
+
ee && ee._f && (ee._f.mount = M);
|
|
582
582
|
};
|
|
583
|
-
if (
|
|
584
|
-
const
|
|
585
|
-
D(o._defaultValues, t,
|
|
583
|
+
if (E(t, !0), z) {
|
|
584
|
+
const H = W(v(o._options.defaultValues, t, m.current.defaultValue));
|
|
585
|
+
D(o._defaultValues, t, H), B(v(o._formValues, t)) && D(o._formValues, t, H);
|
|
586
586
|
}
|
|
587
|
-
return !l && o.register(t),
|
|
588
|
-
(l ?
|
|
587
|
+
return !l && o.register(t), h.current = t, () => {
|
|
588
|
+
(l ? z && !o._state.action : z) ? o.unregister(t) : E(t, !1);
|
|
589
589
|
};
|
|
590
|
-
}, [t, o, l, n]),
|
|
590
|
+
}, [t, o, l, n]), $.useEffect(() => {
|
|
591
591
|
o._setDisabledField({
|
|
592
592
|
disabled: s,
|
|
593
593
|
name: t
|
|
594
594
|
});
|
|
595
|
-
}, [s, t, o]),
|
|
595
|
+
}, [s, t, o]), $.useMemo(() => ({
|
|
596
596
|
field: S,
|
|
597
597
|
formState: f,
|
|
598
|
-
fieldState:
|
|
599
|
-
}), [S, f,
|
|
598
|
+
fieldState: F
|
|
599
|
+
}), [S, f, F]);
|
|
600
600
|
}
|
|
601
|
-
var
|
|
601
|
+
var lt = (e, r, t, s, o) => r ? {
|
|
602
602
|
...t[e],
|
|
603
603
|
types: {
|
|
604
604
|
...t[e] && t[e].types ? t[e].types : {},
|
|
605
605
|
[s]: o || !0
|
|
606
606
|
}
|
|
607
|
-
} : {},
|
|
607
|
+
} : {}, pe = (e) => Array.isArray(e) ? e : [e], wt = () => {
|
|
608
608
|
let e = [];
|
|
609
609
|
return {
|
|
610
610
|
get observers() {
|
|
@@ -624,66 +624,66 @@ var ct = (e, r, t, s, o) => r ? {
|
|
|
624
624
|
}
|
|
625
625
|
};
|
|
626
626
|
};
|
|
627
|
-
function
|
|
627
|
+
function tr(e, r) {
|
|
628
628
|
const t = {};
|
|
629
629
|
for (const s in e)
|
|
630
630
|
if (e.hasOwnProperty(s)) {
|
|
631
631
|
const o = e[s], n = r[s];
|
|
632
|
-
if (o &&
|
|
633
|
-
const i =
|
|
634
|
-
|
|
632
|
+
if (o && U(o) && n) {
|
|
633
|
+
const i = tr(o, n);
|
|
634
|
+
U(i) && (t[s] = i);
|
|
635
635
|
} else e[s] && (t[s] = n);
|
|
636
636
|
}
|
|
637
637
|
return t;
|
|
638
638
|
}
|
|
639
|
-
var G = (e) =>
|
|
640
|
-
if (!
|
|
639
|
+
var G = (e) => U(e) && !Object.keys(e).length, ct = (e) => e.type === "file", oe = (e) => typeof e == "function", Ne = (e) => {
|
|
640
|
+
if (!st)
|
|
641
641
|
return !1;
|
|
642
642
|
const r = e ? e.ownerDocument : 0;
|
|
643
643
|
return e instanceof (r && r.defaultView ? r.defaultView.HTMLElement : HTMLElement);
|
|
644
|
-
},
|
|
645
|
-
function
|
|
644
|
+
}, rr = (e) => e.type === "select-multiple", ut = (e) => e.type === "radio", Qr = (e) => ut(e) || be(e), je = (e) => Ne(e) && e.isConnected;
|
|
645
|
+
function Kr(e, r) {
|
|
646
646
|
const t = r.slice(0, -1).length;
|
|
647
647
|
let s = 0;
|
|
648
648
|
for (; s < t; )
|
|
649
649
|
e = B(e) ? s++ : e[r[s++]];
|
|
650
650
|
return e;
|
|
651
651
|
}
|
|
652
|
-
function
|
|
652
|
+
function Jr(e) {
|
|
653
653
|
for (const r in e)
|
|
654
654
|
if (e.hasOwnProperty(r) && !B(e[r]))
|
|
655
655
|
return !1;
|
|
656
656
|
return !0;
|
|
657
657
|
}
|
|
658
|
-
function
|
|
659
|
-
const t = Array.isArray(r) ? r :
|
|
660
|
-
return s && delete s[n], o !== 0 && (
|
|
658
|
+
function I(e, r) {
|
|
659
|
+
const t = Array.isArray(r) ? r : Pe(r) ? [r] : nt(r), s = t.length === 1 ? e : Kr(e, t), o = t.length - 1, n = t[o];
|
|
660
|
+
return s && delete s[n], o !== 0 && (U(s) && G(s) || Array.isArray(s) && Jr(s)) && I(e, t.slice(0, -1)), e;
|
|
661
661
|
}
|
|
662
|
-
var
|
|
662
|
+
var Xr = (e) => {
|
|
663
663
|
for (const r in e)
|
|
664
|
-
if (
|
|
664
|
+
if (oe(e[r]))
|
|
665
665
|
return !0;
|
|
666
666
|
return !1;
|
|
667
667
|
};
|
|
668
|
-
function
|
|
669
|
-
return Array.isArray(e) ||
|
|
668
|
+
function sr(e) {
|
|
669
|
+
return Array.isArray(e) || U(e) && !Xr(e);
|
|
670
670
|
}
|
|
671
|
-
function
|
|
671
|
+
function Xe(e, r = {}) {
|
|
672
672
|
for (const t in e)
|
|
673
|
-
|
|
673
|
+
sr(e[t]) ? (r[t] = Array.isArray(e[t]) ? [] : {}, Xe(e[t], r[t])) : B(e[t]) || (r[t] = !0);
|
|
674
674
|
return r;
|
|
675
675
|
}
|
|
676
|
-
function
|
|
677
|
-
t || (t =
|
|
676
|
+
function me(e, r, t) {
|
|
677
|
+
t || (t = Xe(r));
|
|
678
678
|
for (const s in e)
|
|
679
|
-
|
|
679
|
+
sr(e[s]) ? B(r) || Je(t[s]) ? t[s] = Xe(e[s], Array.isArray(e[s]) ? [] : {}) : me(e[s], Q(r) ? {} : r[s], t[s]) : t[s] = !se(e[s], r[s]);
|
|
680
680
|
return t;
|
|
681
681
|
}
|
|
682
|
-
const
|
|
682
|
+
const kt = {
|
|
683
683
|
value: !1,
|
|
684
684
|
isValid: !1
|
|
685
|
-
},
|
|
686
|
-
var
|
|
685
|
+
}, Ct = { value: !0, isValid: !0 };
|
|
686
|
+
var or = (e) => {
|
|
687
687
|
if (Array.isArray(e)) {
|
|
688
688
|
if (e.length > 1) {
|
|
689
689
|
const r = e.filter((t) => t && t.checked && !t.disabled).map((t) => t.value);
|
|
@@ -691,24 +691,24 @@ var nr = (e) => {
|
|
|
691
691
|
}
|
|
692
692
|
return e[0].checked && !e[0].disabled ? (
|
|
693
693
|
// @ts-expect-error expected to work in the browser
|
|
694
|
-
e[0].attributes && !B(e[0].attributes.value) ? B(e[0].value) || e[0].value === "" ?
|
|
695
|
-
) :
|
|
694
|
+
e[0].attributes && !B(e[0].attributes.value) ? B(e[0].value) || e[0].value === "" ? Ct : { value: e[0].value, isValid: !0 } : Ct
|
|
695
|
+
) : kt;
|
|
696
696
|
}
|
|
697
|
-
return
|
|
698
|
-
},
|
|
699
|
-
const
|
|
697
|
+
return kt;
|
|
698
|
+
}, nr = (e, { valueAsNumber: r, valueAsDate: t, setValueAs: s }) => B(e) ? e : r ? e === "" ? NaN : e && +e : t && X(e) ? new Date(e) : s ? s(e) : e;
|
|
699
|
+
const zt = {
|
|
700
700
|
isValid: !1,
|
|
701
701
|
value: null
|
|
702
702
|
};
|
|
703
|
-
var
|
|
703
|
+
var ir = (e) => Array.isArray(e) ? e.reduce((r, t) => t && t.checked && !t.disabled ? {
|
|
704
704
|
isValid: !0,
|
|
705
705
|
value: t.value
|
|
706
|
-
} : r,
|
|
707
|
-
function
|
|
706
|
+
} : r, zt) : zt;
|
|
707
|
+
function $t(e) {
|
|
708
708
|
const r = e.ref;
|
|
709
|
-
return
|
|
709
|
+
return ct(r) ? r.files : ut(r) ? ir(e.refs).value : rr(r) ? [...r.selectedOptions].map(({ value: t }) => t) : be(r) ? or(e.refs).value : nr(B(r.value) ? e.ref.value : r.value, e);
|
|
710
710
|
}
|
|
711
|
-
var
|
|
711
|
+
var Yr = (e, r, t, s) => {
|
|
712
712
|
const o = {};
|
|
713
713
|
for (const n of e) {
|
|
714
714
|
const i = v(r, n);
|
|
@@ -720,16 +720,16 @@ var es = (e, r, t, s) => {
|
|
|
720
720
|
fields: o,
|
|
721
721
|
shouldUseNativeValidation: s
|
|
722
722
|
};
|
|
723
|
-
},
|
|
724
|
-
isOnSubmit: !e || e ===
|
|
725
|
-
isOnBlur: e ===
|
|
726
|
-
isOnChange: e ===
|
|
727
|
-
isOnAll: e ===
|
|
728
|
-
isOnTouch: e ===
|
|
723
|
+
}, Re = (e) => e instanceof RegExp, ge = (e) => B(e) ? e : Re(e) ? e.source : U(e) ? Re(e.value) ? e.value.source : e.value : e, Et = (e) => ({
|
|
724
|
+
isOnSubmit: !e || e === re.onSubmit,
|
|
725
|
+
isOnBlur: e === re.onBlur,
|
|
726
|
+
isOnChange: e === re.onChange,
|
|
727
|
+
isOnAll: e === re.all,
|
|
728
|
+
isOnTouch: e === re.onTouched
|
|
729
729
|
});
|
|
730
|
-
const
|
|
731
|
-
var
|
|
732
|
-
const
|
|
730
|
+
const At = "AsyncFunction";
|
|
731
|
+
var es = (e) => !!e && !!e.validate && !!(oe(e.validate) && e.validate.constructor.name === At || U(e.validate) && Object.values(e.validate).find((r) => r.constructor.name === At)), ts = (e) => e.mount && (e.required || e.min || e.max || e.maxLength || e.minLength || e.pattern || e.validate), Nt = (e, r, t) => !t && (r.watchAll || r.watch.has(e) || [...r.watch].some((s) => e.startsWith(s) && /^\.\w+/.test(e.slice(s.length))));
|
|
732
|
+
const ve = (e, r, t, s) => {
|
|
733
733
|
for (const o of t || Object.keys(e)) {
|
|
734
734
|
const n = v(e, o);
|
|
735
735
|
if (n) {
|
|
@@ -739,16 +739,16 @@ const be = (e, r, t, s) => {
|
|
|
739
739
|
return !0;
|
|
740
740
|
if (i.ref && r(i.ref, i.name) && !s)
|
|
741
741
|
return !0;
|
|
742
|
-
if (
|
|
742
|
+
if (ve(l, r))
|
|
743
743
|
break;
|
|
744
|
-
} else if (
|
|
744
|
+
} else if (U(l) && ve(l, r))
|
|
745
745
|
break;
|
|
746
746
|
}
|
|
747
747
|
}
|
|
748
748
|
};
|
|
749
|
-
function
|
|
749
|
+
function Rt(e, r, t) {
|
|
750
750
|
const s = v(e, t);
|
|
751
|
-
if (s ||
|
|
751
|
+
if (s || Pe(t))
|
|
752
752
|
return {
|
|
753
753
|
error: s,
|
|
754
754
|
name: t
|
|
@@ -774,15 +774,15 @@ function Dt(e, r, t) {
|
|
|
774
774
|
name: t
|
|
775
775
|
};
|
|
776
776
|
}
|
|
777
|
-
var
|
|
777
|
+
var rs = (e, r, t, s) => {
|
|
778
778
|
t(e);
|
|
779
779
|
const { name: o, ...n } = e;
|
|
780
|
-
return G(n) || Object.keys(n).length >= Object.keys(r).length || Object.keys(n).find((i) => r[i] === (!s ||
|
|
781
|
-
},
|
|
782
|
-
const s =
|
|
780
|
+
return G(n) || Object.keys(n).length >= Object.keys(r).length || Object.keys(n).find((i) => r[i] === (!s || re.all));
|
|
781
|
+
}, ss = (e, r, t) => !e || !r || e === r || pe(e).some((s) => s && (t ? s === r : s.startsWith(r) || r.startsWith(s))), os = (e, r, t, s, o) => o.isOnAll ? !1 : !t && o.isOnTouch ? !(r || e) : (t ? s.isOnBlur : o.isOnBlur) ? !e : (t ? s.isOnChange : o.isOnChange) ? e : !0, ns = (e, r) => !ot(v(e, r)).length && I(e, r), is = (e, r, t) => {
|
|
782
|
+
const s = pe(v(e, t));
|
|
783
783
|
return D(s, "root", r[t]), D(e, t, s), e;
|
|
784
784
|
};
|
|
785
|
-
function
|
|
785
|
+
function Dt(e, r, t = "validate") {
|
|
786
786
|
if (X(e) || Array.isArray(e) && e.every(X) || J(e) && !e)
|
|
787
787
|
return {
|
|
788
788
|
type: t,
|
|
@@ -790,104 +790,104 @@ function Pt(e, r, t = "validate") {
|
|
|
790
790
|
ref: r
|
|
791
791
|
};
|
|
792
792
|
}
|
|
793
|
-
var
|
|
793
|
+
var fe = (e) => U(e) && !Re(e) ? e : {
|
|
794
794
|
value: e,
|
|
795
795
|
message: ""
|
|
796
|
-
},
|
|
797
|
-
const { ref: i, refs: l, required: d, maxLength:
|
|
798
|
-
if (!
|
|
796
|
+
}, Pt = async (e, r, t, s, o, n) => {
|
|
797
|
+
const { ref: i, refs: l, required: d, maxLength: y, minLength: f, min: m, max: h, pattern: x, validate: F, name: _, valueAsNumber: C, mount: A } = e._f, S = v(t, _);
|
|
798
|
+
if (!A || r.has(_))
|
|
799
799
|
return {};
|
|
800
|
-
const
|
|
801
|
-
o &&
|
|
802
|
-
},
|
|
803
|
-
const
|
|
804
|
-
|
|
800
|
+
const z = l ? l[0] : i, k = (N) => {
|
|
801
|
+
o && z.reportValidity && (z.setCustomValidity(J(N) ? "" : N || ""), z.reportValidity());
|
|
802
|
+
}, E = {}, H = ut(i), M = be(i), ee = H || M, j = (C || ct(i)) && B(i.value) && B(S) || Ne(i) && i.value === "" || S === "" || Array.isArray(S) && !S.length, te = lt.bind(null, _, s, E), ne = (N, P, T, q = le.maxLength, Z = le.minLength) => {
|
|
803
|
+
const ie = N ? P : T;
|
|
804
|
+
E[_] = {
|
|
805
805
|
type: N ? q : Z,
|
|
806
|
-
message:
|
|
806
|
+
message: ie,
|
|
807
807
|
ref: i,
|
|
808
|
-
...
|
|
808
|
+
...te(N ? q : Z, ie)
|
|
809
809
|
};
|
|
810
810
|
};
|
|
811
|
-
if (n ? !Array.isArray(S) || !S.length : d && (!
|
|
812
|
-
const { value: N, message: P } = X(d) ? { value: !!d, message: d } :
|
|
813
|
-
if (N && (
|
|
814
|
-
type:
|
|
811
|
+
if (n ? !Array.isArray(S) || !S.length : d && (!ee && (j || Q(S)) || J(S) && !S || M && !or(l).isValid || H && !ir(l).isValid)) {
|
|
812
|
+
const { value: N, message: P } = X(d) ? { value: !!d, message: d } : fe(d);
|
|
813
|
+
if (N && (E[_] = {
|
|
814
|
+
type: le.required,
|
|
815
815
|
message: P,
|
|
816
|
-
ref:
|
|
817
|
-
...
|
|
816
|
+
ref: z,
|
|
817
|
+
...te(le.required, P)
|
|
818
818
|
}, !s))
|
|
819
|
-
return
|
|
819
|
+
return k(P), E;
|
|
820
820
|
}
|
|
821
|
-
if (!
|
|
821
|
+
if (!j && (!Q(m) || !Q(h))) {
|
|
822
822
|
let N, P;
|
|
823
|
-
const
|
|
823
|
+
const T = fe(h), q = fe(m);
|
|
824
824
|
if (!Q(S) && !isNaN(S)) {
|
|
825
825
|
const Z = i.valueAsNumber || S && +S;
|
|
826
|
-
Q(
|
|
826
|
+
Q(T.value) || (N = Z > T.value), Q(q.value) || (P = Z < q.value);
|
|
827
827
|
} else {
|
|
828
|
-
const Z = i.valueAsDate || new Date(S),
|
|
829
|
-
X(
|
|
828
|
+
const Z = i.valueAsDate || new Date(S), ie = (xe) => /* @__PURE__ */ new Date((/* @__PURE__ */ new Date()).toDateString() + " " + xe), he = i.type == "time", de = i.type == "week";
|
|
829
|
+
X(T.value) && S && (N = he ? ie(S) > ie(T.value) : de ? S > T.value : Z > new Date(T.value)), X(q.value) && S && (P = he ? ie(S) < ie(q.value) : de ? S < q.value : Z < new Date(q.value));
|
|
830
830
|
}
|
|
831
|
-
if ((N || P) && (
|
|
832
|
-
return
|
|
831
|
+
if ((N || P) && (ne(!!N, T.message, q.message, le.max, le.min), !s))
|
|
832
|
+
return k(E[_].message), E;
|
|
833
833
|
}
|
|
834
|
-
if ((
|
|
835
|
-
const N =
|
|
836
|
-
if ((
|
|
837
|
-
return
|
|
834
|
+
if ((y || f) && !j && (X(S) || n && Array.isArray(S))) {
|
|
835
|
+
const N = fe(y), P = fe(f), T = !Q(N.value) && S.length > +N.value, q = !Q(P.value) && S.length < +P.value;
|
|
836
|
+
if ((T || q) && (ne(T, N.message, P.message), !s))
|
|
837
|
+
return k(E[_].message), E;
|
|
838
838
|
}
|
|
839
|
-
if (
|
|
840
|
-
const { value: N, message: P } =
|
|
841
|
-
if (
|
|
842
|
-
type:
|
|
839
|
+
if (x && !j && X(S)) {
|
|
840
|
+
const { value: N, message: P } = fe(x);
|
|
841
|
+
if (Re(N) && !S.match(N) && (E[_] = {
|
|
842
|
+
type: le.pattern,
|
|
843
843
|
message: P,
|
|
844
844
|
ref: i,
|
|
845
|
-
...
|
|
845
|
+
...te(le.pattern, P)
|
|
846
846
|
}, !s))
|
|
847
|
-
return
|
|
847
|
+
return k(P), E;
|
|
848
848
|
}
|
|
849
|
-
if (
|
|
850
|
-
if (
|
|
851
|
-
const N = await
|
|
852
|
-
if (P && (
|
|
849
|
+
if (F) {
|
|
850
|
+
if (oe(F)) {
|
|
851
|
+
const N = await F(S, t), P = Dt(N, z);
|
|
852
|
+
if (P && (E[_] = {
|
|
853
853
|
...P,
|
|
854
|
-
...
|
|
854
|
+
...te(le.validate, P.message)
|
|
855
855
|
}, !s))
|
|
856
|
-
return
|
|
857
|
-
} else if (
|
|
856
|
+
return k(P.message), E;
|
|
857
|
+
} else if (U(F)) {
|
|
858
858
|
let N = {};
|
|
859
|
-
for (const P in
|
|
859
|
+
for (const P in F) {
|
|
860
860
|
if (!G(N) && !s)
|
|
861
861
|
break;
|
|
862
|
-
const
|
|
863
|
-
|
|
864
|
-
...
|
|
865
|
-
...
|
|
866
|
-
},
|
|
862
|
+
const T = Dt(await F[P](S, t), z, P);
|
|
863
|
+
T && (N = {
|
|
864
|
+
...T,
|
|
865
|
+
...te(P, T.message)
|
|
866
|
+
}, k(T.message), s && (E[_] = N));
|
|
867
867
|
}
|
|
868
|
-
if (!G(N) && (
|
|
869
|
-
ref:
|
|
868
|
+
if (!G(N) && (E[_] = {
|
|
869
|
+
ref: z,
|
|
870
870
|
...N
|
|
871
871
|
}, !s))
|
|
872
|
-
return
|
|
872
|
+
return E;
|
|
873
873
|
}
|
|
874
874
|
}
|
|
875
|
-
return
|
|
875
|
+
return k(!0), E;
|
|
876
876
|
};
|
|
877
|
-
const
|
|
878
|
-
mode:
|
|
879
|
-
reValidateMode:
|
|
877
|
+
const as = {
|
|
878
|
+
mode: re.onSubmit,
|
|
879
|
+
reValidateMode: re.onChange,
|
|
880
880
|
shouldFocusError: !0
|
|
881
881
|
};
|
|
882
|
-
function
|
|
882
|
+
function ls(e = {}) {
|
|
883
883
|
let r = {
|
|
884
|
-
...
|
|
884
|
+
...as,
|
|
885
885
|
...e
|
|
886
886
|
}, t = {
|
|
887
887
|
submitCount: 0,
|
|
888
888
|
isDirty: !1,
|
|
889
889
|
isReady: !1,
|
|
890
|
-
isLoading:
|
|
890
|
+
isLoading: oe(r.defaultValues),
|
|
891
891
|
isValidating: !1,
|
|
892
892
|
isSubmitted: !1,
|
|
893
893
|
isSubmitting: !1,
|
|
@@ -898,7 +898,7 @@ function cs(e = {}) {
|
|
|
898
898
|
validatingFields: {},
|
|
899
899
|
errors: r.errors || {},
|
|
900
900
|
disabled: r.disabled || !1
|
|
901
|
-
}, s = {}, o =
|
|
901
|
+
}, s = {}, o = U(r.defaultValues) || U(r.values) ? W(r.defaultValues || r.values) || {} : {}, n = r.shouldUnregister ? {} : W(o), i = {
|
|
902
902
|
action: !1,
|
|
903
903
|
mount: !1,
|
|
904
904
|
watch: !1
|
|
@@ -908,7 +908,7 @@ function cs(e = {}) {
|
|
|
908
908
|
unMount: /* @__PURE__ */ new Set(),
|
|
909
909
|
array: /* @__PURE__ */ new Set(),
|
|
910
910
|
watch: /* @__PURE__ */ new Set()
|
|
911
|
-
}, d,
|
|
911
|
+
}, d, y = 0;
|
|
912
912
|
const f = {
|
|
913
913
|
isDirty: !1,
|
|
914
914
|
dirtyFields: !1,
|
|
@@ -918,45 +918,45 @@ function cs(e = {}) {
|
|
|
918
918
|
isValid: !1,
|
|
919
919
|
errors: !1
|
|
920
920
|
};
|
|
921
|
-
let
|
|
921
|
+
let m = {
|
|
922
922
|
...f
|
|
923
923
|
};
|
|
924
|
-
const
|
|
925
|
-
array:
|
|
926
|
-
state:
|
|
927
|
-
},
|
|
928
|
-
clearTimeout(
|
|
929
|
-
},
|
|
930
|
-
if (!r.disabled && (f.isValid ||
|
|
931
|
-
const c = r.resolver ? G((await
|
|
932
|
-
c !== t.isValid &&
|
|
924
|
+
const h = {
|
|
925
|
+
array: wt(),
|
|
926
|
+
state: wt()
|
|
927
|
+
}, x = r.criteriaMode === re.all, F = (a) => (c) => {
|
|
928
|
+
clearTimeout(y), y = setTimeout(a, c);
|
|
929
|
+
}, _ = async (a) => {
|
|
930
|
+
if (!r.disabled && (f.isValid || m.isValid || a)) {
|
|
931
|
+
const c = r.resolver ? G((await M()).errors) : await j(s, !0);
|
|
932
|
+
c !== t.isValid && h.state.next({
|
|
933
933
|
isValid: c
|
|
934
934
|
});
|
|
935
935
|
}
|
|
936
|
-
},
|
|
937
|
-
!r.disabled && (f.isValidating || f.validatingFields ||
|
|
938
|
-
u && (c ? D(t.validatingFields, u, c) :
|
|
939
|
-
}),
|
|
936
|
+
}, C = (a, c) => {
|
|
937
|
+
!r.disabled && (f.isValidating || f.validatingFields || m.isValidating || m.validatingFields) && ((a || Array.from(l.mount)).forEach((u) => {
|
|
938
|
+
u && (c ? D(t.validatingFields, u, c) : I(t.validatingFields, u));
|
|
939
|
+
}), h.state.next({
|
|
940
940
|
validatingFields: t.validatingFields,
|
|
941
941
|
isValidating: !G(t.validatingFields)
|
|
942
942
|
}));
|
|
943
|
-
},
|
|
943
|
+
}, A = (a, c = [], u, b, p = !0, g = !0) => {
|
|
944
944
|
if (b && u && !r.disabled) {
|
|
945
|
-
if (i.action = !0,
|
|
946
|
-
const
|
|
947
|
-
p && D(s, a,
|
|
945
|
+
if (i.action = !0, g && Array.isArray(v(s, a))) {
|
|
946
|
+
const w = u(v(s, a), b.argA, b.argB);
|
|
947
|
+
p && D(s, a, w);
|
|
948
948
|
}
|
|
949
|
-
if (
|
|
950
|
-
const
|
|
951
|
-
p && D(t.errors, a,
|
|
949
|
+
if (g && Array.isArray(v(t.errors, a))) {
|
|
950
|
+
const w = u(v(t.errors, a), b.argA, b.argB);
|
|
951
|
+
p && D(t.errors, a, w), ns(t.errors, a);
|
|
952
952
|
}
|
|
953
|
-
if ((f.touchedFields ||
|
|
954
|
-
const
|
|
955
|
-
p && D(t.touchedFields, a,
|
|
953
|
+
if ((f.touchedFields || m.touchedFields) && g && Array.isArray(v(t.touchedFields, a))) {
|
|
954
|
+
const w = u(v(t.touchedFields, a), b.argA, b.argB);
|
|
955
|
+
p && D(t.touchedFields, a, w);
|
|
956
956
|
}
|
|
957
|
-
(f.dirtyFields ||
|
|
957
|
+
(f.dirtyFields || m.dirtyFields) && (t.dirtyFields = me(o, n)), h.state.next({
|
|
958
958
|
name: a,
|
|
959
|
-
isDirty:
|
|
959
|
+
isDirty: ne(a, c),
|
|
960
960
|
dirtyFields: t.dirtyFields,
|
|
961
961
|
errors: t.errors,
|
|
962
962
|
isValid: t.isValid
|
|
@@ -964,227 +964,227 @@ function cs(e = {}) {
|
|
|
964
964
|
} else
|
|
965
965
|
D(n, a, c);
|
|
966
966
|
}, S = (a, c) => {
|
|
967
|
-
D(t.errors, a, c),
|
|
967
|
+
D(t.errors, a, c), h.state.next({
|
|
968
968
|
errors: t.errors
|
|
969
969
|
});
|
|
970
|
-
},
|
|
971
|
-
t.errors = a,
|
|
970
|
+
}, z = (a) => {
|
|
971
|
+
t.errors = a, h.state.next({
|
|
972
972
|
errors: t.errors,
|
|
973
973
|
isValid: !1
|
|
974
974
|
});
|
|
975
|
-
},
|
|
975
|
+
}, k = (a, c, u, b) => {
|
|
976
976
|
const p = v(s, a);
|
|
977
977
|
if (p) {
|
|
978
|
-
const
|
|
979
|
-
B(
|
|
978
|
+
const g = v(n, a, B(u) ? v(o, a) : u);
|
|
979
|
+
B(g) || b && b.defaultChecked || c ? D(n, a, c ? g : $t(p._f)) : T(a, g), i.mount && _();
|
|
980
980
|
}
|
|
981
|
-
},
|
|
982
|
-
let
|
|
981
|
+
}, E = (a, c, u, b, p) => {
|
|
982
|
+
let g = !1, w = !1;
|
|
983
983
|
const R = {
|
|
984
984
|
name: a
|
|
985
985
|
};
|
|
986
986
|
if (!r.disabled) {
|
|
987
987
|
if (!u || b) {
|
|
988
|
-
(f.isDirty ||
|
|
989
|
-
const L =
|
|
990
|
-
|
|
988
|
+
(f.isDirty || m.isDirty) && (w = t.isDirty, t.isDirty = R.isDirty = ne(), g = w !== R.isDirty);
|
|
989
|
+
const L = se(v(o, a), c);
|
|
990
|
+
w = !!v(t.dirtyFields, a), L ? I(t.dirtyFields, a) : D(t.dirtyFields, a, !0), R.dirtyFields = t.dirtyFields, g = g || (f.dirtyFields || m.dirtyFields) && w !== !L;
|
|
991
991
|
}
|
|
992
992
|
if (u) {
|
|
993
993
|
const L = v(t.touchedFields, a);
|
|
994
|
-
L || (D(t.touchedFields, a, u), R.touchedFields = t.touchedFields,
|
|
994
|
+
L || (D(t.touchedFields, a, u), R.touchedFields = t.touchedFields, g = g || (f.touchedFields || m.touchedFields) && L !== u);
|
|
995
995
|
}
|
|
996
|
-
|
|
996
|
+
g && p && h.state.next(R);
|
|
997
997
|
}
|
|
998
|
-
return
|
|
999
|
-
},
|
|
1000
|
-
const p = v(t.errors, a),
|
|
1001
|
-
if (r.delayError && u ? (d =
|
|
1002
|
-
const
|
|
998
|
+
return g ? R : {};
|
|
999
|
+
}, H = (a, c, u, b) => {
|
|
1000
|
+
const p = v(t.errors, a), g = (f.isValid || m.isValid) && J(c) && t.isValid !== c;
|
|
1001
|
+
if (r.delayError && u ? (d = F(() => S(a, u)), d(r.delayError)) : (clearTimeout(y), d = null, u ? D(t.errors, a, u) : I(t.errors, a)), (u ? !se(p, u) : p) || !G(b) || g) {
|
|
1002
|
+
const w = {
|
|
1003
1003
|
...b,
|
|
1004
|
-
...
|
|
1004
|
+
...g && J(c) ? { isValid: c } : {},
|
|
1005
1005
|
errors: t.errors,
|
|
1006
1006
|
name: a
|
|
1007
1007
|
};
|
|
1008
1008
|
t = {
|
|
1009
1009
|
...t,
|
|
1010
|
-
...
|
|
1011
|
-
},
|
|
1010
|
+
...w
|
|
1011
|
+
}, h.state.next(w);
|
|
1012
1012
|
}
|
|
1013
|
-
},
|
|
1014
|
-
|
|
1015
|
-
const c = await r.resolver(n, r.context,
|
|
1016
|
-
return
|
|
1017
|
-
},
|
|
1018
|
-
const { errors: c } = await
|
|
1013
|
+
}, M = async (a) => {
|
|
1014
|
+
C(a, !0);
|
|
1015
|
+
const c = await r.resolver(n, r.context, Yr(a || l.mount, s, r.criteriaMode, r.shouldUseNativeValidation));
|
|
1016
|
+
return C(a), c;
|
|
1017
|
+
}, ee = async (a) => {
|
|
1018
|
+
const { errors: c } = await M(a);
|
|
1019
1019
|
if (a)
|
|
1020
1020
|
for (const u of a) {
|
|
1021
1021
|
const b = v(c, u);
|
|
1022
|
-
b ? D(t.errors, u, b) :
|
|
1022
|
+
b ? D(t.errors, u, b) : I(t.errors, u);
|
|
1023
1023
|
}
|
|
1024
1024
|
else
|
|
1025
1025
|
t.errors = c;
|
|
1026
1026
|
return c;
|
|
1027
|
-
},
|
|
1027
|
+
}, j = async (a, c, u = {
|
|
1028
1028
|
valid: !0
|
|
1029
1029
|
}) => {
|
|
1030
1030
|
for (const b in a) {
|
|
1031
1031
|
const p = a[b];
|
|
1032
1032
|
if (p) {
|
|
1033
|
-
const { _f:
|
|
1034
|
-
if (
|
|
1035
|
-
const R = l.array.has(
|
|
1036
|
-
L && f.validatingFields &&
|
|
1037
|
-
const
|
|
1038
|
-
if (L && f.validatingFields &&
|
|
1033
|
+
const { _f: g, ...w } = p;
|
|
1034
|
+
if (g) {
|
|
1035
|
+
const R = l.array.has(g.name), L = p._f && es(p._f);
|
|
1036
|
+
L && f.validatingFields && C([g.name], !0);
|
|
1037
|
+
const Y = await Pt(p, l.disabled, n, x, r.shouldUseNativeValidation && !c, R);
|
|
1038
|
+
if (L && f.validatingFields && C([g.name]), Y[g.name] && (u.valid = !1, c))
|
|
1039
1039
|
break;
|
|
1040
|
-
!c && (v(
|
|
1040
|
+
!c && (v(Y, g.name) ? R ? is(t.errors, Y, g.name) : D(t.errors, g.name, Y[g.name]) : I(t.errors, g.name));
|
|
1041
1041
|
}
|
|
1042
|
-
!G(
|
|
1042
|
+
!G(w) && await j(w, c, u);
|
|
1043
1043
|
}
|
|
1044
1044
|
}
|
|
1045
1045
|
return u.valid;
|
|
1046
|
-
},
|
|
1046
|
+
}, te = () => {
|
|
1047
1047
|
for (const a of l.unMount) {
|
|
1048
1048
|
const c = v(s, a);
|
|
1049
|
-
c && (c._f.refs ? c._f.refs.every((u) => !
|
|
1049
|
+
c && (c._f.refs ? c._f.refs.every((u) => !je(u)) : !je(c._f.ref)) && Le(a);
|
|
1050
1050
|
}
|
|
1051
1051
|
l.unMount = /* @__PURE__ */ new Set();
|
|
1052
|
-
},
|
|
1052
|
+
}, ne = (a, c) => !r.disabled && (a && c && D(n, a, c), !se(xe(), o)), N = (a, c, u) => Ke(a, l, {
|
|
1053
1053
|
...i.mount ? n : B(c) ? o : X(a) ? { [a]: c } : c
|
|
1054
|
-
}, u, c), P = (a) =>
|
|
1054
|
+
}, u, c), P = (a) => ot(v(i.mount ? n : o, a, r.shouldUnregister ? v(o, a, []) : [])), T = (a, c, u = {}) => {
|
|
1055
1055
|
const b = v(s, a);
|
|
1056
1056
|
let p = c;
|
|
1057
1057
|
if (b) {
|
|
1058
|
-
const
|
|
1059
|
-
|
|
1060
|
-
(!
|
|
1061
|
-
}) :
|
|
1058
|
+
const g = b._f;
|
|
1059
|
+
g && (!g.disabled && D(n, a, nr(c, g)), p = Ne(g.ref) && Q(c) ? "" : c, rr(g.ref) ? [...g.ref.options].forEach((w) => w.selected = p.includes(w.value)) : g.refs ? be(g.ref) ? g.refs.forEach((w) => {
|
|
1060
|
+
(!w.defaultChecked || !w.disabled) && (Array.isArray(p) ? w.checked = !!p.find((R) => R === w.value) : w.checked = p === w.value || !!p);
|
|
1061
|
+
}) : g.refs.forEach((w) => w.checked = w.value === p) : ct(g.ref) ? g.ref.value = "" : (g.ref.value = p, g.ref.type || h.state.next({
|
|
1062
1062
|
name: a,
|
|
1063
|
-
values:
|
|
1063
|
+
values: W(n)
|
|
1064
1064
|
})));
|
|
1065
1065
|
}
|
|
1066
|
-
(u.shouldDirty || u.shouldTouch) &&
|
|
1066
|
+
(u.shouldDirty || u.shouldTouch) && E(a, p, u.shouldTouch, u.shouldDirty, !0), u.shouldValidate && de(a);
|
|
1067
1067
|
}, q = (a, c, u) => {
|
|
1068
1068
|
for (const b in c) {
|
|
1069
1069
|
if (!c.hasOwnProperty(b))
|
|
1070
1070
|
return;
|
|
1071
|
-
const p = c[b],
|
|
1072
|
-
(l.array.has(a) ||
|
|
1071
|
+
const p = c[b], g = a + "." + b, w = v(s, g);
|
|
1072
|
+
(l.array.has(a) || U(p) || w && !w._f) && !ue(p) ? q(g, p, u) : T(g, p, u);
|
|
1073
1073
|
}
|
|
1074
1074
|
}, Z = (a, c, u = {}) => {
|
|
1075
|
-
const b = v(s, a), p = l.array.has(a),
|
|
1076
|
-
D(n, a,
|
|
1075
|
+
const b = v(s, a), p = l.array.has(a), g = W(c);
|
|
1076
|
+
D(n, a, g), p ? (h.array.next({
|
|
1077
1077
|
name: a,
|
|
1078
|
-
values:
|
|
1079
|
-
}), (f.isDirty || f.dirtyFields ||
|
|
1078
|
+
values: W(n)
|
|
1079
|
+
}), (f.isDirty || f.dirtyFields || m.isDirty || m.dirtyFields) && u.shouldDirty && h.state.next({
|
|
1080
1080
|
name: a,
|
|
1081
|
-
dirtyFields:
|
|
1082
|
-
isDirty:
|
|
1083
|
-
})) : b && !b._f && !Q(
|
|
1081
|
+
dirtyFields: me(o, n),
|
|
1082
|
+
isDirty: ne(a, g)
|
|
1083
|
+
})) : b && !b._f && !Q(g) ? q(a, g, u) : T(a, g, u), Nt(a, l) && h.state.next({ ...t, name: a }), h.state.next({
|
|
1084
1084
|
name: i.mount ? a : void 0,
|
|
1085
|
-
values:
|
|
1085
|
+
values: W(n)
|
|
1086
1086
|
});
|
|
1087
|
-
},
|
|
1087
|
+
}, ie = async (a) => {
|
|
1088
1088
|
i.mount = !0;
|
|
1089
1089
|
const c = a.target;
|
|
1090
1090
|
let u = c.name, b = !0;
|
|
1091
|
-
const p = v(s, u),
|
|
1092
|
-
b = Number.isNaN(L) || ue(L) && isNaN(L.getTime()) ||
|
|
1093
|
-
},
|
|
1091
|
+
const p = v(s, u), g = (L) => {
|
|
1092
|
+
b = Number.isNaN(L) || ue(L) && isNaN(L.getTime()) || se(L, v(n, u, L));
|
|
1093
|
+
}, w = Et(r.mode), R = Et(r.reValidateMode);
|
|
1094
1094
|
if (p) {
|
|
1095
|
-
let L,
|
|
1096
|
-
const
|
|
1097
|
-
D(n, u,
|
|
1098
|
-
const
|
|
1099
|
-
if (!
|
|
1095
|
+
let L, Y;
|
|
1096
|
+
const Fe = c.type ? $t(p._f) : Jt(a), ce = a.type === Ae.BLUR || a.type === Ae.FOCUS_OUT, xr = !ts(p._f) && !r.resolver && !v(t.errors, u) && !p._f.deps || os(ce, v(t.touchedFields, u), t.isSubmitted, R, w), He = Nt(u, l, ce);
|
|
1097
|
+
D(n, u, Fe), ce ? (!c || !c.readOnly) && (p._f.onBlur && p._f.onBlur(a), d && d(0)) : p._f.onChange && p._f.onChange(a);
|
|
1098
|
+
const Te = E(u, Fe, ce), Fr = !G(Te) || He;
|
|
1099
|
+
if (!ce && h.state.next({
|
|
1100
1100
|
name: u,
|
|
1101
1101
|
type: a.type,
|
|
1102
|
-
values:
|
|
1103
|
-
}),
|
|
1104
|
-
return (f.isValid ||
|
|
1105
|
-
if (!
|
|
1106
|
-
const { errors:
|
|
1107
|
-
if (
|
|
1108
|
-
const
|
|
1109
|
-
L =
|
|
1102
|
+
values: W(n)
|
|
1103
|
+
}), xr)
|
|
1104
|
+
return (f.isValid || m.isValid) && (r.mode === "onBlur" ? ce && _() : ce || _()), Fr && h.state.next({ name: u, ...He ? {} : Te });
|
|
1105
|
+
if (!ce && He && h.state.next({ ...t }), r.resolver) {
|
|
1106
|
+
const { errors: vt } = await M([u]);
|
|
1107
|
+
if (g(Fe), b) {
|
|
1108
|
+
const Vr = Rt(t.errors, s, u), bt = Rt(vt, s, Vr.name || u);
|
|
1109
|
+
L = bt.error, u = bt.name, Y = G(vt);
|
|
1110
1110
|
}
|
|
1111
1111
|
} else
|
|
1112
|
-
|
|
1113
|
-
b && (p._f.deps && (!Array.isArray(p._f.deps) || p._f.deps.length > 0) &&
|
|
1112
|
+
C([u], !0), L = (await Pt(p, l.disabled, n, x, r.shouldUseNativeValidation))[u], C([u]), g(Fe), b && (L ? Y = !1 : (f.isValid || m.isValid) && (Y = await j(s, !0)));
|
|
1113
|
+
b && (p._f.deps && (!Array.isArray(p._f.deps) || p._f.deps.length > 0) && de(p._f.deps), H(u, Y, L, Te));
|
|
1114
1114
|
}
|
|
1115
|
-
},
|
|
1115
|
+
}, he = (a, c) => {
|
|
1116
1116
|
if (v(t.errors, c) && a.focus)
|
|
1117
1117
|
return a.focus(), 1;
|
|
1118
|
-
},
|
|
1118
|
+
}, de = async (a, c = {}) => {
|
|
1119
1119
|
let u, b;
|
|
1120
|
-
const p =
|
|
1120
|
+
const p = pe(a);
|
|
1121
1121
|
if (r.resolver) {
|
|
1122
|
-
const
|
|
1123
|
-
u = G(
|
|
1124
|
-
} else a ? (b = (await Promise.all(p.map(async (
|
|
1125
|
-
const
|
|
1126
|
-
return await
|
|
1127
|
-
}))).every(Boolean), !(!b && !t.isValid) &&
|
|
1128
|
-
return
|
|
1129
|
-
...!X(a) || (f.isValid ||
|
|
1122
|
+
const g = await ee(B(a) ? a : p);
|
|
1123
|
+
u = G(g), b = a ? !p.some((w) => v(g, w)) : u;
|
|
1124
|
+
} else a ? (b = (await Promise.all(p.map(async (g) => {
|
|
1125
|
+
const w = v(s, g);
|
|
1126
|
+
return await j(w && w._f ? { [g]: w } : w);
|
|
1127
|
+
}))).every(Boolean), !(!b && !t.isValid) && _()) : b = u = await j(s);
|
|
1128
|
+
return h.state.next({
|
|
1129
|
+
...!X(a) || (f.isValid || m.isValid) && u !== t.isValid ? {} : { name: a },
|
|
1130
1130
|
...r.resolver || !a ? { isValid: u } : {},
|
|
1131
1131
|
errors: t.errors
|
|
1132
|
-
}), c.shouldFocus && !b &&
|
|
1132
|
+
}), c.shouldFocus && !b && ve(s, he, a ? p : l.mount), b;
|
|
1133
1133
|
}, xe = (a, c) => {
|
|
1134
1134
|
let u = {
|
|
1135
1135
|
...i.mount ? n : o
|
|
1136
1136
|
};
|
|
1137
|
-
return c && (u =
|
|
1138
|
-
},
|
|
1137
|
+
return c && (u = tr(c.dirtyFields ? t.dirtyFields : t.touchedFields, u)), B(a) ? u : X(a) ? v(u, a) : a.map((b) => v(u, b));
|
|
1138
|
+
}, dt = (a, c) => ({
|
|
1139
1139
|
invalid: !!v((c || t).errors, a),
|
|
1140
1140
|
isDirty: !!v((c || t).dirtyFields, a),
|
|
1141
1141
|
error: v((c || t).errors, a),
|
|
1142
1142
|
isValidating: !!v(t.validatingFields, a),
|
|
1143
1143
|
isTouched: !!v((c || t).touchedFields, a)
|
|
1144
|
-
}),
|
|
1145
|
-
a &&
|
|
1144
|
+
}), hr = (a) => {
|
|
1145
|
+
a && pe(a).forEach((c) => I(t.errors, c)), h.state.next({
|
|
1146
1146
|
errors: a ? t.errors : {}
|
|
1147
1147
|
});
|
|
1148
|
-
},
|
|
1149
|
-
const b = (v(s, a, { _f: {} })._f || {}).ref, p = v(t.errors, a) || {}, { ref:
|
|
1148
|
+
}, ft = (a, c, u) => {
|
|
1149
|
+
const b = (v(s, a, { _f: {} })._f || {}).ref, p = v(t.errors, a) || {}, { ref: g, message: w, type: R, ...L } = p;
|
|
1150
1150
|
D(t.errors, a, {
|
|
1151
1151
|
...L,
|
|
1152
1152
|
...c,
|
|
1153
1153
|
ref: b
|
|
1154
|
-
}),
|
|
1154
|
+
}), h.state.next({
|
|
1155
1155
|
name: a,
|
|
1156
1156
|
errors: t.errors,
|
|
1157
1157
|
isValid: !1
|
|
1158
1158
|
}), u && u.shouldFocus && b && b.focus && b.focus();
|
|
1159
|
-
},
|
|
1159
|
+
}, gr = (a, c) => oe(a) ? h.state.subscribe({
|
|
1160
1160
|
next: (u) => "values" in u && a(N(void 0, c), u)
|
|
1161
|
-
}) : N(a, c, !0), yt = (a) =>
|
|
1161
|
+
}) : N(a, c, !0), yt = (a) => h.state.subscribe({
|
|
1162
1162
|
next: (c) => {
|
|
1163
|
-
|
|
1163
|
+
ss(a.name, c.name, a.exact) && rs(c, a.formState || f, Sr, a.reRenderRoot) && a.callback({
|
|
1164
1164
|
values: { ...n },
|
|
1165
1165
|
...t,
|
|
1166
1166
|
...c,
|
|
1167
1167
|
defaultValues: o
|
|
1168
1168
|
});
|
|
1169
1169
|
}
|
|
1170
|
-
}).unsubscribe,
|
|
1171
|
-
...
|
|
1170
|
+
}).unsubscribe, _r = (a) => (i.mount = !0, m = {
|
|
1171
|
+
...m,
|
|
1172
1172
|
...a.formState
|
|
1173
1173
|
}, yt({
|
|
1174
1174
|
...a,
|
|
1175
|
-
formState:
|
|
1176
|
-
})),
|
|
1177
|
-
for (const u of a ?
|
|
1178
|
-
l.mount.delete(u), l.array.delete(u), c.keepValue || (
|
|
1179
|
-
|
|
1180
|
-
values:
|
|
1181
|
-
}),
|
|
1175
|
+
formState: m
|
|
1176
|
+
})), Le = (a, c = {}) => {
|
|
1177
|
+
for (const u of a ? pe(a) : l.mount)
|
|
1178
|
+
l.mount.delete(u), l.array.delete(u), c.keepValue || (I(s, u), I(n, u)), !c.keepError && I(t.errors, u), !c.keepDirty && I(t.dirtyFields, u), !c.keepTouched && I(t.touchedFields, u), !c.keepIsValidating && I(t.validatingFields, u), !r.shouldUnregister && !c.keepDefaultValue && I(o, u);
|
|
1179
|
+
h.state.next({
|
|
1180
|
+
values: W(n)
|
|
1181
|
+
}), h.state.next({
|
|
1182
1182
|
...t,
|
|
1183
|
-
...c.keepDirty ? { isDirty:
|
|
1184
|
-
}), !c.keepIsValid &&
|
|
1185
|
-
},
|
|
1183
|
+
...c.keepDirty ? { isDirty: ne() } : {}
|
|
1184
|
+
}), !c.keepIsValid && _();
|
|
1185
|
+
}, mt = ({ disabled: a, name: c }) => {
|
|
1186
1186
|
(J(a) && i.mount || a || l.disabled.has(c)) && (a ? l.disabled.add(c) : l.disabled.delete(c));
|
|
1187
|
-
},
|
|
1187
|
+
}, Be = (a, c = {}) => {
|
|
1188
1188
|
let u = v(s, a);
|
|
1189
1189
|
const b = J(c.disabled) || J(r.disabled);
|
|
1190
1190
|
return D(s, a, {
|
|
@@ -1195,78 +1195,78 @@ function cs(e = {}) {
|
|
|
1195
1195
|
mount: !0,
|
|
1196
1196
|
...c
|
|
1197
1197
|
}
|
|
1198
|
-
}), l.mount.add(a), u ?
|
|
1198
|
+
}), l.mount.add(a), u ? mt({
|
|
1199
1199
|
disabled: J(c.disabled) ? c.disabled : r.disabled,
|
|
1200
1200
|
name: a
|
|
1201
|
-
}) :
|
|
1201
|
+
}) : k(a, !0, c.value), {
|
|
1202
1202
|
...b ? { disabled: c.disabled || r.disabled } : {},
|
|
1203
1203
|
...r.progressive ? {
|
|
1204
1204
|
required: !!c.required,
|
|
1205
|
-
min:
|
|
1206
|
-
max:
|
|
1207
|
-
minLength:
|
|
1208
|
-
maxLength:
|
|
1209
|
-
pattern:
|
|
1205
|
+
min: ge(c.min),
|
|
1206
|
+
max: ge(c.max),
|
|
1207
|
+
minLength: ge(c.minLength),
|
|
1208
|
+
maxLength: ge(c.maxLength),
|
|
1209
|
+
pattern: ge(c.pattern)
|
|
1210
1210
|
} : {},
|
|
1211
1211
|
name: a,
|
|
1212
|
-
onChange:
|
|
1213
|
-
onBlur:
|
|
1212
|
+
onChange: ie,
|
|
1213
|
+
onBlur: ie,
|
|
1214
1214
|
ref: (p) => {
|
|
1215
1215
|
if (p) {
|
|
1216
|
-
|
|
1217
|
-
const
|
|
1218
|
-
if (
|
|
1216
|
+
Be(a, c), u = v(s, a);
|
|
1217
|
+
const g = B(p.value) && p.querySelectorAll && p.querySelectorAll("input,select,textarea")[0] || p, w = Qr(g), R = u._f.refs || [];
|
|
1218
|
+
if (w ? R.find((L) => L === g) : g === u._f.ref)
|
|
1219
1219
|
return;
|
|
1220
1220
|
D(s, a, {
|
|
1221
1221
|
_f: {
|
|
1222
1222
|
...u._f,
|
|
1223
|
-
...
|
|
1223
|
+
...w ? {
|
|
1224
1224
|
refs: [
|
|
1225
|
-
...R.filter(
|
|
1226
|
-
|
|
1225
|
+
...R.filter(je),
|
|
1226
|
+
g,
|
|
1227
1227
|
...Array.isArray(v(o, a)) ? [{}] : []
|
|
1228
1228
|
],
|
|
1229
|
-
ref: { type:
|
|
1230
|
-
} : { ref:
|
|
1229
|
+
ref: { type: g.type, name: a }
|
|
1230
|
+
} : { ref: g }
|
|
1231
1231
|
}
|
|
1232
|
-
}),
|
|
1232
|
+
}), k(a, !1, void 0, g);
|
|
1233
1233
|
} else
|
|
1234
|
-
u = v(s, a, {}), u._f && (u._f.mount = !1), (r.shouldUnregister || c.shouldUnregister) && !(
|
|
1234
|
+
u = v(s, a, {}), u._f && (u._f.mount = !1), (r.shouldUnregister || c.shouldUnregister) && !(Xt(l.array, a) && i.action) && l.unMount.add(a);
|
|
1235
1235
|
}
|
|
1236
1236
|
};
|
|
1237
|
-
},
|
|
1238
|
-
J(a) && (
|
|
1237
|
+
}, Oe = () => r.shouldFocusError && ve(s, he, l.mount), pr = (a) => {
|
|
1238
|
+
J(a) && (h.state.next({ disabled: a }), ve(s, (c, u) => {
|
|
1239
1239
|
const b = v(s, u);
|
|
1240
1240
|
b && (c.disabled = b._f.disabled || a, Array.isArray(b._f.refs) && b._f.refs.forEach((p) => {
|
|
1241
1241
|
p.disabled = b._f.disabled || a;
|
|
1242
1242
|
}));
|
|
1243
1243
|
}, 0, !1));
|
|
1244
|
-
},
|
|
1244
|
+
}, ht = (a, c) => async (u) => {
|
|
1245
1245
|
let b;
|
|
1246
1246
|
u && (u.preventDefault && u.preventDefault(), u.persist && u.persist());
|
|
1247
|
-
let p =
|
|
1248
|
-
if (
|
|
1247
|
+
let p = W(n);
|
|
1248
|
+
if (h.state.next({
|
|
1249
1249
|
isSubmitting: !0
|
|
1250
1250
|
}), r.resolver) {
|
|
1251
|
-
const { errors:
|
|
1252
|
-
t.errors =
|
|
1251
|
+
const { errors: g, values: w } = await M();
|
|
1252
|
+
t.errors = g, p = W(w);
|
|
1253
1253
|
} else
|
|
1254
|
-
await
|
|
1254
|
+
await j(s);
|
|
1255
1255
|
if (l.disabled.size)
|
|
1256
|
-
for (const
|
|
1257
|
-
|
|
1258
|
-
if (
|
|
1259
|
-
|
|
1256
|
+
for (const g of l.disabled)
|
|
1257
|
+
I(p, g);
|
|
1258
|
+
if (I(t.errors, "root"), G(t.errors)) {
|
|
1259
|
+
h.state.next({
|
|
1260
1260
|
errors: {}
|
|
1261
1261
|
});
|
|
1262
1262
|
try {
|
|
1263
1263
|
await a(p, u);
|
|
1264
|
-
} catch (
|
|
1265
|
-
b =
|
|
1264
|
+
} catch (g) {
|
|
1265
|
+
b = g;
|
|
1266
1266
|
}
|
|
1267
1267
|
} else
|
|
1268
|
-
c && await c({ ...t.errors }, u),
|
|
1269
|
-
if (
|
|
1268
|
+
c && await c({ ...t.errors }, u), Oe(), setTimeout(Oe);
|
|
1269
|
+
if (h.state.next({
|
|
1270
1270
|
isSubmitted: !0,
|
|
1271
1271
|
isSubmitting: !1,
|
|
1272
1272
|
isSubmitSuccessful: G(t.errors) && !b,
|
|
@@ -1274,43 +1274,43 @@ function cs(e = {}) {
|
|
|
1274
1274
|
errors: t.errors
|
|
1275
1275
|
}), b)
|
|
1276
1276
|
throw b;
|
|
1277
|
-
},
|
|
1278
|
-
v(s, a) && (B(c.defaultValue) ? Z(a,
|
|
1279
|
-
},
|
|
1280
|
-
const u = a ?
|
|
1277
|
+
}, vr = (a, c = {}) => {
|
|
1278
|
+
v(s, a) && (B(c.defaultValue) ? Z(a, W(v(o, a))) : (Z(a, c.defaultValue), D(o, a, W(c.defaultValue))), c.keepTouched || I(t.touchedFields, a), c.keepDirty || (I(t.dirtyFields, a), t.isDirty = c.defaultValue ? ne(a, W(v(o, a))) : ne()), c.keepError || (I(t.errors, a), f.isValid && _()), h.state.next({ ...t }));
|
|
1279
|
+
}, gt = (a, c = {}) => {
|
|
1280
|
+
const u = a ? W(a) : o, b = W(u), p = G(a), g = p ? o : b;
|
|
1281
1281
|
if (c.keepDefaultValues || (o = u), !c.keepValues) {
|
|
1282
1282
|
if (c.keepDirtyValues) {
|
|
1283
|
-
const
|
|
1283
|
+
const w = /* @__PURE__ */ new Set([
|
|
1284
1284
|
...l.mount,
|
|
1285
|
-
...Object.keys(
|
|
1285
|
+
...Object.keys(me(o, n))
|
|
1286
1286
|
]);
|
|
1287
|
-
for (const R of Array.from(
|
|
1288
|
-
v(t.dirtyFields, R) ? D(
|
|
1287
|
+
for (const R of Array.from(w))
|
|
1288
|
+
v(t.dirtyFields, R) ? D(g, R, v(n, R)) : Z(R, v(g, R));
|
|
1289
1289
|
} else {
|
|
1290
|
-
if (
|
|
1291
|
-
for (const
|
|
1292
|
-
const R = v(s,
|
|
1290
|
+
if (st && B(a))
|
|
1291
|
+
for (const w of l.mount) {
|
|
1292
|
+
const R = v(s, w);
|
|
1293
1293
|
if (R && R._f) {
|
|
1294
1294
|
const L = Array.isArray(R._f.refs) ? R._f.refs[0] : R._f.ref;
|
|
1295
|
-
if (
|
|
1296
|
-
const
|
|
1297
|
-
if (
|
|
1298
|
-
|
|
1295
|
+
if (Ne(L)) {
|
|
1296
|
+
const Y = L.closest("form");
|
|
1297
|
+
if (Y) {
|
|
1298
|
+
Y.reset();
|
|
1299
1299
|
break;
|
|
1300
1300
|
}
|
|
1301
1301
|
}
|
|
1302
1302
|
}
|
|
1303
1303
|
}
|
|
1304
1304
|
if (c.keepFieldsRef)
|
|
1305
|
-
for (const
|
|
1306
|
-
Z(
|
|
1305
|
+
for (const w of l.mount)
|
|
1306
|
+
Z(w, v(g, w));
|
|
1307
1307
|
else
|
|
1308
1308
|
s = {};
|
|
1309
1309
|
}
|
|
1310
|
-
n = r.shouldUnregister ? c.keepDefaultValues ?
|
|
1311
|
-
values: { ...
|
|
1312
|
-
}),
|
|
1313
|
-
values: { ...
|
|
1310
|
+
n = r.shouldUnregister ? c.keepDefaultValues ? W(o) : {} : W(g), h.array.next({
|
|
1311
|
+
values: { ...g }
|
|
1312
|
+
}), h.state.next({
|
|
1313
|
+
values: { ...g }
|
|
1314
1314
|
});
|
|
1315
1315
|
}
|
|
1316
1316
|
l = {
|
|
@@ -1321,54 +1321,54 @@ function cs(e = {}) {
|
|
|
1321
1321
|
watch: /* @__PURE__ */ new Set(),
|
|
1322
1322
|
watchAll: !1,
|
|
1323
1323
|
focus: ""
|
|
1324
|
-
}, i.mount = !f.isValid || !!c.keepIsValid || !!c.keepDirtyValues || !r.shouldUnregister && !G(
|
|
1324
|
+
}, i.mount = !f.isValid || !!c.keepIsValid || !!c.keepDirtyValues || !r.shouldUnregister && !G(g), i.watch = !!r.shouldUnregister, h.state.next({
|
|
1325
1325
|
submitCount: c.keepSubmitCount ? t.submitCount : 0,
|
|
1326
|
-
isDirty: p ? !1 : c.keepDirty ? t.isDirty : !!(c.keepDefaultValues && !
|
|
1326
|
+
isDirty: p ? !1 : c.keepDirty ? t.isDirty : !!(c.keepDefaultValues && !se(a, o)),
|
|
1327
1327
|
isSubmitted: c.keepIsSubmitted ? t.isSubmitted : !1,
|
|
1328
|
-
dirtyFields: p ? {} : c.keepDirtyValues ? c.keepDefaultValues && n ?
|
|
1328
|
+
dirtyFields: p ? {} : c.keepDirtyValues ? c.keepDefaultValues && n ? me(o, n) : t.dirtyFields : c.keepDefaultValues && a ? me(o, a) : c.keepDirty ? t.dirtyFields : {},
|
|
1329
1329
|
touchedFields: c.keepTouched ? t.touchedFields : {},
|
|
1330
1330
|
errors: c.keepErrors ? t.errors : {},
|
|
1331
1331
|
isSubmitSuccessful: c.keepIsSubmitSuccessful ? t.isSubmitSuccessful : !1,
|
|
1332
1332
|
isSubmitting: !1,
|
|
1333
1333
|
defaultValues: o
|
|
1334
1334
|
});
|
|
1335
|
-
},
|
|
1335
|
+
}, _t = (a, c) => gt(oe(a) ? a(n) : a, c), br = (a, c = {}) => {
|
|
1336
1336
|
const u = v(s, a), b = u && u._f;
|
|
1337
1337
|
if (b) {
|
|
1338
1338
|
const p = b.refs ? b.refs[0] : b.ref;
|
|
1339
|
-
p.focus && (p.focus(), c.shouldSelect &&
|
|
1339
|
+
p.focus && (p.focus(), c.shouldSelect && oe(p.select) && p.select());
|
|
1340
1340
|
}
|
|
1341
|
-
},
|
|
1341
|
+
}, Sr = (a) => {
|
|
1342
1342
|
t = {
|
|
1343
1343
|
...t,
|
|
1344
1344
|
...a
|
|
1345
1345
|
};
|
|
1346
|
-
},
|
|
1346
|
+
}, pt = {
|
|
1347
1347
|
control: {
|
|
1348
|
-
register:
|
|
1349
|
-
unregister:
|
|
1350
|
-
getFieldState:
|
|
1351
|
-
handleSubmit:
|
|
1352
|
-
setError:
|
|
1348
|
+
register: Be,
|
|
1349
|
+
unregister: Le,
|
|
1350
|
+
getFieldState: dt,
|
|
1351
|
+
handleSubmit: ht,
|
|
1352
|
+
setError: ft,
|
|
1353
1353
|
_subscribe: yt,
|
|
1354
|
-
_runSchema:
|
|
1355
|
-
_focusError:
|
|
1354
|
+
_runSchema: M,
|
|
1355
|
+
_focusError: Oe,
|
|
1356
1356
|
_getWatch: N,
|
|
1357
|
-
_getDirty:
|
|
1358
|
-
_setValid:
|
|
1359
|
-
_setFieldArray:
|
|
1360
|
-
_setDisabledField:
|
|
1361
|
-
_setErrors:
|
|
1357
|
+
_getDirty: ne,
|
|
1358
|
+
_setValid: _,
|
|
1359
|
+
_setFieldArray: A,
|
|
1360
|
+
_setDisabledField: mt,
|
|
1361
|
+
_setErrors: z,
|
|
1362
1362
|
_getFieldArray: P,
|
|
1363
|
-
_reset:
|
|
1364
|
-
_resetDefaultValues: () =>
|
|
1365
|
-
|
|
1363
|
+
_reset: gt,
|
|
1364
|
+
_resetDefaultValues: () => oe(r.defaultValues) && r.defaultValues().then((a) => {
|
|
1365
|
+
_t(a, r.resetOptions), h.state.next({
|
|
1366
1366
|
isLoading: !1
|
|
1367
1367
|
});
|
|
1368
1368
|
}),
|
|
1369
|
-
_removeUnmounted:
|
|
1370
|
-
_disableForm:
|
|
1371
|
-
_subjects:
|
|
1369
|
+
_removeUnmounted: te,
|
|
1370
|
+
_disableForm: pr,
|
|
1371
|
+
_subjects: h,
|
|
1372
1372
|
_proxyFormState: f,
|
|
1373
1373
|
get _fields() {
|
|
1374
1374
|
return s;
|
|
@@ -1404,31 +1404,31 @@ function cs(e = {}) {
|
|
|
1404
1404
|
};
|
|
1405
1405
|
}
|
|
1406
1406
|
},
|
|
1407
|
-
subscribe:
|
|
1408
|
-
trigger:
|
|
1409
|
-
register:
|
|
1410
|
-
handleSubmit:
|
|
1411
|
-
watch:
|
|
1407
|
+
subscribe: _r,
|
|
1408
|
+
trigger: de,
|
|
1409
|
+
register: Be,
|
|
1410
|
+
handleSubmit: ht,
|
|
1411
|
+
watch: gr,
|
|
1412
1412
|
setValue: Z,
|
|
1413
1413
|
getValues: xe,
|
|
1414
|
-
reset:
|
|
1415
|
-
resetField:
|
|
1416
|
-
clearErrors:
|
|
1417
|
-
unregister:
|
|
1418
|
-
setError:
|
|
1419
|
-
setFocus:
|
|
1420
|
-
getFieldState:
|
|
1414
|
+
reset: _t,
|
|
1415
|
+
resetField: vr,
|
|
1416
|
+
clearErrors: hr,
|
|
1417
|
+
unregister: Le,
|
|
1418
|
+
setError: ft,
|
|
1419
|
+
setFocus: br,
|
|
1420
|
+
getFieldState: dt
|
|
1421
1421
|
};
|
|
1422
1422
|
return {
|
|
1423
|
-
...
|
|
1424
|
-
formControl:
|
|
1423
|
+
...pt,
|
|
1424
|
+
formControl: pt
|
|
1425
1425
|
};
|
|
1426
1426
|
}
|
|
1427
|
-
function
|
|
1428
|
-
const r =
|
|
1427
|
+
function cs(e = {}) {
|
|
1428
|
+
const r = $.useRef(void 0), t = $.useRef(void 0), [s, o] = $.useState({
|
|
1429
1429
|
isDirty: !1,
|
|
1430
1430
|
isValidating: !1,
|
|
1431
|
-
isLoading:
|
|
1431
|
+
isLoading: oe(e.defaultValues),
|
|
1432
1432
|
isSubmitted: !1,
|
|
1433
1433
|
isSubmitting: !1,
|
|
1434
1434
|
isSubmitSuccessful: !1,
|
|
@@ -1440,23 +1440,23 @@ function us(e = {}) {
|
|
|
1440
1440
|
errors: e.errors || {},
|
|
1441
1441
|
disabled: e.disabled || !1,
|
|
1442
1442
|
isReady: !1,
|
|
1443
|
-
defaultValues:
|
|
1443
|
+
defaultValues: oe(e.defaultValues) ? void 0 : e.defaultValues
|
|
1444
1444
|
});
|
|
1445
1445
|
if (!r.current)
|
|
1446
1446
|
if (e.formControl)
|
|
1447
1447
|
r.current = {
|
|
1448
1448
|
...e.formControl,
|
|
1449
1449
|
formState: s
|
|
1450
|
-
}, e.defaultValues && !
|
|
1450
|
+
}, e.defaultValues && !oe(e.defaultValues) && e.formControl.reset(e.defaultValues, e.resetOptions);
|
|
1451
1451
|
else {
|
|
1452
|
-
const { formControl: i, ...l } =
|
|
1452
|
+
const { formControl: i, ...l } = ls(e);
|
|
1453
1453
|
r.current = {
|
|
1454
1454
|
...l,
|
|
1455
1455
|
formState: s
|
|
1456
1456
|
};
|
|
1457
1457
|
}
|
|
1458
1458
|
const n = r.current.control;
|
|
1459
|
-
return n._options = e,
|
|
1459
|
+
return n._options = e, at(() => {
|
|
1460
1460
|
const i = n._subscribe({
|
|
1461
1461
|
formState: n._proxyFormState,
|
|
1462
1462
|
callback: () => o({ ...n._formState }),
|
|
@@ -1466,65 +1466,65 @@ function us(e = {}) {
|
|
|
1466
1466
|
...l,
|
|
1467
1467
|
isReady: !0
|
|
1468
1468
|
})), n._formState.isReady = !0, i;
|
|
1469
|
-
}, [n]),
|
|
1469
|
+
}, [n]), $.useEffect(() => n._disableForm(e.disabled), [n, e.disabled]), $.useEffect(() => {
|
|
1470
1470
|
e.mode && (n._options.mode = e.mode), e.reValidateMode && (n._options.reValidateMode = e.reValidateMode);
|
|
1471
|
-
}, [n, e.mode, e.reValidateMode]),
|
|
1471
|
+
}, [n, e.mode, e.reValidateMode]), $.useEffect(() => {
|
|
1472
1472
|
e.errors && (n._setErrors(e.errors), n._focusError());
|
|
1473
|
-
}, [n, e.errors]),
|
|
1473
|
+
}, [n, e.errors]), $.useEffect(() => {
|
|
1474
1474
|
e.shouldUnregister && n._subjects.state.next({
|
|
1475
1475
|
values: n._getWatch()
|
|
1476
1476
|
});
|
|
1477
|
-
}, [n, e.shouldUnregister]),
|
|
1477
|
+
}, [n, e.shouldUnregister]), $.useEffect(() => {
|
|
1478
1478
|
if (n._proxyFormState.isDirty) {
|
|
1479
1479
|
const i = n._getDirty();
|
|
1480
1480
|
i !== s.isDirty && n._subjects.state.next({
|
|
1481
1481
|
isDirty: i
|
|
1482
1482
|
});
|
|
1483
1483
|
}
|
|
1484
|
-
}, [n, s.isDirty]),
|
|
1485
|
-
e.values && !
|
|
1484
|
+
}, [n, s.isDirty]), $.useEffect(() => {
|
|
1485
|
+
e.values && !se(e.values, t.current) ? (n._reset(e.values, {
|
|
1486
1486
|
keepFieldsRef: !0,
|
|
1487
1487
|
...n._options.resetOptions
|
|
1488
1488
|
}), t.current = e.values, o((i) => ({ ...i }))) : n._resetDefaultValues();
|
|
1489
|
-
}, [n, e.values]),
|
|
1489
|
+
}, [n, e.values]), $.useEffect(() => {
|
|
1490
1490
|
n._state.mount || (n._setValid(), n._state.mount = !0), n._state.watch && (n._state.watch = !1, n._subjects.state.next({ ...n._formState })), n._removeUnmounted();
|
|
1491
|
-
}), r.current.formState =
|
|
1491
|
+
}), r.current.formState = er(s, n), r.current;
|
|
1492
1492
|
}
|
|
1493
|
-
const
|
|
1493
|
+
const Lt = (e, r, t) => {
|
|
1494
1494
|
if (e && "reportValidity" in e) {
|
|
1495
1495
|
const s = v(t, r);
|
|
1496
1496
|
e.setCustomValidity(s && s.message || ""), e.reportValidity();
|
|
1497
1497
|
}
|
|
1498
|
-
},
|
|
1498
|
+
}, Ye = (e, r) => {
|
|
1499
1499
|
for (const t in r.fields) {
|
|
1500
1500
|
const s = r.fields[t];
|
|
1501
|
-
s && s.ref && "reportValidity" in s.ref ?
|
|
1501
|
+
s && s.ref && "reportValidity" in s.ref ? Lt(s.ref, t, e) : s && s.refs && s.refs.forEach((o) => Lt(o, t, e));
|
|
1502
1502
|
}
|
|
1503
|
-
},
|
|
1504
|
-
r.shouldUseNativeValidation &&
|
|
1503
|
+
}, Bt = (e, r) => {
|
|
1504
|
+
r.shouldUseNativeValidation && Ye(e, r);
|
|
1505
1505
|
const t = {};
|
|
1506
1506
|
for (const s in e) {
|
|
1507
1507
|
const o = v(r.fields, s), n = Object.assign(e[s] || {}, { ref: o && o.ref });
|
|
1508
|
-
if (
|
|
1508
|
+
if (us(r.names || Object.keys(e), s)) {
|
|
1509
1509
|
const i = Object.assign({}, v(t, s));
|
|
1510
1510
|
D(i, "root", n), D(t, s, i);
|
|
1511
1511
|
} else D(t, s, n);
|
|
1512
1512
|
}
|
|
1513
1513
|
return t;
|
|
1514
|
-
},
|
|
1515
|
-
const t =
|
|
1516
|
-
return e.some((s) =>
|
|
1514
|
+
}, us = (e, r) => {
|
|
1515
|
+
const t = Ot(r);
|
|
1516
|
+
return e.some((s) => Ot(s).match(`^${t}\\.\\d+`));
|
|
1517
1517
|
};
|
|
1518
|
-
function
|
|
1518
|
+
function Ot(e) {
|
|
1519
1519
|
return e.replace(/\]|\[/g, "");
|
|
1520
1520
|
}
|
|
1521
|
-
function
|
|
1521
|
+
function ar(e, r, t) {
|
|
1522
1522
|
function s(l, d) {
|
|
1523
|
-
var
|
|
1523
|
+
var y;
|
|
1524
1524
|
Object.defineProperty(l, "_zod", {
|
|
1525
1525
|
value: l._zod ?? {},
|
|
1526
1526
|
enumerable: !1
|
|
1527
|
-
}), (
|
|
1527
|
+
}), (y = l._zod).traits ?? (y.traits = /* @__PURE__ */ new Set()), l._zod.traits.add(e), r(l, d);
|
|
1528
1528
|
for (const f in i.prototype)
|
|
1529
1529
|
f in l || Object.defineProperty(l, f, { value: i.prototype[f].bind(l) });
|
|
1530
1530
|
l._zod.constr = i, l._zod.def = d;
|
|
@@ -1535,46 +1535,46 @@ function lr(e, r, t) {
|
|
|
1535
1535
|
Object.defineProperty(n, "name", { value: e });
|
|
1536
1536
|
function i(l) {
|
|
1537
1537
|
var d;
|
|
1538
|
-
const
|
|
1539
|
-
s(
|
|
1540
|
-
for (const f of
|
|
1538
|
+
const y = t != null && t.Parent ? new n() : this;
|
|
1539
|
+
s(y, l), (d = y._zod).deferred ?? (d.deferred = []);
|
|
1540
|
+
for (const f of y._zod.deferred)
|
|
1541
1541
|
f();
|
|
1542
|
-
return
|
|
1542
|
+
return y;
|
|
1543
1543
|
}
|
|
1544
1544
|
return Object.defineProperty(i, "init", { value: s }), Object.defineProperty(i, Symbol.hasInstance, {
|
|
1545
1545
|
value: (l) => {
|
|
1546
|
-
var d,
|
|
1547
|
-
return t != null && t.Parent && l instanceof t.Parent ? !0 : (
|
|
1546
|
+
var d, y;
|
|
1547
|
+
return t != null && t.Parent && l instanceof t.Parent ? !0 : (y = (d = l == null ? void 0 : l._zod) == null ? void 0 : d.traits) == null ? void 0 : y.has(e);
|
|
1548
1548
|
}
|
|
1549
1549
|
}), Object.defineProperty(i, "name", { value: e }), i;
|
|
1550
1550
|
}
|
|
1551
|
-
class
|
|
1551
|
+
class ds extends Error {
|
|
1552
1552
|
constructor() {
|
|
1553
1553
|
super("Encountered Promise during synchronous parse. Use .parseAsync() instead.");
|
|
1554
1554
|
}
|
|
1555
1555
|
}
|
|
1556
|
-
const
|
|
1557
|
-
function
|
|
1558
|
-
return
|
|
1556
|
+
const fs = {};
|
|
1557
|
+
function lr(e) {
|
|
1558
|
+
return fs;
|
|
1559
1559
|
}
|
|
1560
1560
|
function ys(e, r) {
|
|
1561
1561
|
return typeof r == "bigint" ? r.toString() : r;
|
|
1562
1562
|
}
|
|
1563
|
-
const
|
|
1563
|
+
const cr = "captureStackTrace" in Error ? Error.captureStackTrace : (...e) => {
|
|
1564
1564
|
};
|
|
1565
|
-
function
|
|
1565
|
+
function Ce(e) {
|
|
1566
1566
|
return typeof e == "string" ? e : e == null ? void 0 : e.message;
|
|
1567
1567
|
}
|
|
1568
|
-
function
|
|
1569
|
-
var o, n, i, l, d,
|
|
1568
|
+
function ur(e, r, t) {
|
|
1569
|
+
var o, n, i, l, d, y;
|
|
1570
1570
|
const s = { ...e, path: e.path ?? [] };
|
|
1571
1571
|
if (!e.message) {
|
|
1572
|
-
const f =
|
|
1572
|
+
const f = Ce((i = (n = (o = e.inst) == null ? void 0 : o._zod.def) == null ? void 0 : n.error) == null ? void 0 : i.call(n, e)) ?? Ce((l = r == null ? void 0 : r.error) == null ? void 0 : l.call(r, e)) ?? Ce((d = t.customError) == null ? void 0 : d.call(t, e)) ?? Ce((y = t.localeError) == null ? void 0 : y.call(t, e)) ?? "Invalid input";
|
|
1573
1573
|
s.message = f;
|
|
1574
1574
|
}
|
|
1575
1575
|
return delete s.inst, delete s.continue, r != null && r.reportInput || delete s.input, s;
|
|
1576
1576
|
}
|
|
1577
|
-
const
|
|
1577
|
+
const dr = (e, r) => {
|
|
1578
1578
|
e.name = "$ZodError", Object.defineProperty(e, "_zod", {
|
|
1579
1579
|
value: e._zod,
|
|
1580
1580
|
enumerable: !1
|
|
@@ -1585,25 +1585,25 @@ const fr = (e, r) => {
|
|
|
1585
1585
|
value: () => e.message,
|
|
1586
1586
|
enumerable: !1
|
|
1587
1587
|
});
|
|
1588
|
-
},
|
|
1588
|
+
}, ms = ar("$ZodError", dr), fr = ar("$ZodError", dr, { Parent: Error }), hs = (e) => (r, t, s, o) => {
|
|
1589
1589
|
const n = s ? Object.assign(s, { async: !1 }) : { async: !1 }, i = r._zod.run({ value: t, issues: [] }, n);
|
|
1590
1590
|
if (i instanceof Promise)
|
|
1591
|
-
throw new
|
|
1591
|
+
throw new ds();
|
|
1592
1592
|
if (i.issues.length) {
|
|
1593
|
-
const l = new ((o == null ? void 0 : o.Err) ?? e)(i.issues.map((d) =>
|
|
1594
|
-
throw
|
|
1593
|
+
const l = new ((o == null ? void 0 : o.Err) ?? e)(i.issues.map((d) => ur(d, n, lr())));
|
|
1594
|
+
throw cr(l, o == null ? void 0 : o.callee), l;
|
|
1595
1595
|
}
|
|
1596
1596
|
return i.value;
|
|
1597
|
-
},
|
|
1597
|
+
}, gs = /* @__PURE__ */ hs(fr), _s = (e) => async (r, t, s, o) => {
|
|
1598
1598
|
const n = s ? Object.assign(s, { async: !0 }) : { async: !0 };
|
|
1599
1599
|
let i = r._zod.run({ value: t, issues: [] }, n);
|
|
1600
1600
|
if (i instanceof Promise && (i = await i), i.issues.length) {
|
|
1601
|
-
const l = new ((o == null ? void 0 : o.Err) ?? e)(i.issues.map((d) =>
|
|
1602
|
-
throw
|
|
1601
|
+
const l = new ((o == null ? void 0 : o.Err) ?? e)(i.issues.map((d) => ur(d, n, lr())));
|
|
1602
|
+
throw cr(l, o == null ? void 0 : o.callee), l;
|
|
1603
1603
|
}
|
|
1604
1604
|
return i.value;
|
|
1605
|
-
},
|
|
1606
|
-
function
|
|
1605
|
+
}, ps = /* @__PURE__ */ _s(fr);
|
|
1606
|
+
function Ht(e, r) {
|
|
1607
1607
|
try {
|
|
1608
1608
|
var t = e();
|
|
1609
1609
|
} catch (s) {
|
|
@@ -1611,7 +1611,7 @@ function Tt(e, r) {
|
|
|
1611
1611
|
}
|
|
1612
1612
|
return t && t.then ? t.then(void 0, r) : t;
|
|
1613
1613
|
}
|
|
1614
|
-
function
|
|
1614
|
+
function vs(e, r) {
|
|
1615
1615
|
for (var t = {}; e.length; ) {
|
|
1616
1616
|
var s = e[0], o = s.code, n = s.message, i = s.path.join(".");
|
|
1617
1617
|
if (!t[i]) if ("unionErrors" in s) {
|
|
@@ -1619,18 +1619,18 @@ function bs(e, r) {
|
|
|
1619
1619
|
t[i] = { message: l.message, type: l.code };
|
|
1620
1620
|
} else t[i] = { message: n, type: o };
|
|
1621
1621
|
if ("unionErrors" in s && s.unionErrors.forEach(function(f) {
|
|
1622
|
-
return f.errors.forEach(function(
|
|
1623
|
-
return e.push(
|
|
1622
|
+
return f.errors.forEach(function(m) {
|
|
1623
|
+
return e.push(m);
|
|
1624
1624
|
});
|
|
1625
1625
|
}), r) {
|
|
1626
|
-
var d = t[i].types,
|
|
1627
|
-
t[i] =
|
|
1626
|
+
var d = t[i].types, y = d && d[s.code];
|
|
1627
|
+
t[i] = lt(i, r, t, o, y ? [].concat(y, s.message) : s.message);
|
|
1628
1628
|
}
|
|
1629
1629
|
e.shift();
|
|
1630
1630
|
}
|
|
1631
1631
|
return t;
|
|
1632
1632
|
}
|
|
1633
|
-
function
|
|
1633
|
+
function bs(e, r) {
|
|
1634
1634
|
for (var t = {}; e.length; ) {
|
|
1635
1635
|
var s = e[0], o = s.code, n = s.message, i = s.path.join(".");
|
|
1636
1636
|
if (!t[i]) if (s.code === "invalid_union" && s.errors.length > 0) {
|
|
@@ -1638,30 +1638,30 @@ function Ss(e, r) {
|
|
|
1638
1638
|
t[i] = { message: l.message, type: l.code };
|
|
1639
1639
|
} else t[i] = { message: n, type: o };
|
|
1640
1640
|
if (s.code === "invalid_union" && s.errors.forEach(function(f) {
|
|
1641
|
-
return f.forEach(function(
|
|
1642
|
-
return e.push(
|
|
1641
|
+
return f.forEach(function(m) {
|
|
1642
|
+
return e.push(m);
|
|
1643
1643
|
});
|
|
1644
1644
|
}), r) {
|
|
1645
|
-
var d = t[i].types,
|
|
1646
|
-
t[i] =
|
|
1645
|
+
var d = t[i].types, y = d && d[s.code];
|
|
1646
|
+
t[i] = lt(i, r, t, o, y ? [].concat(y, s.message) : s.message);
|
|
1647
1647
|
}
|
|
1648
1648
|
e.shift();
|
|
1649
1649
|
}
|
|
1650
1650
|
return t;
|
|
1651
1651
|
}
|
|
1652
|
-
function
|
|
1652
|
+
function Ss(e, r, t) {
|
|
1653
1653
|
if (t === void 0 && (t = {}), (function(s) {
|
|
1654
1654
|
return "_def" in s && typeof s._def == "object" && "typeName" in s._def;
|
|
1655
1655
|
})(e)) return function(s, o, n) {
|
|
1656
1656
|
try {
|
|
1657
|
-
return Promise.resolve(
|
|
1657
|
+
return Promise.resolve(Ht(function() {
|
|
1658
1658
|
return Promise.resolve(e[t.mode === "sync" ? "parse" : "parseAsync"](s, r)).then(function(i) {
|
|
1659
|
-
return n.shouldUseNativeValidation &&
|
|
1659
|
+
return n.shouldUseNativeValidation && Ye({}, n), { errors: {}, values: t.raw ? Object.assign({}, s) : i };
|
|
1660
1660
|
});
|
|
1661
1661
|
}, function(i) {
|
|
1662
1662
|
if ((function(l) {
|
|
1663
1663
|
return Array.isArray(l == null ? void 0 : l.issues);
|
|
1664
|
-
})(i)) return { values: {}, errors:
|
|
1664
|
+
})(i)) return { values: {}, errors: Bt(vs(i.errors, !n.shouldUseNativeValidation && n.criteriaMode === "all"), n) };
|
|
1665
1665
|
throw i;
|
|
1666
1666
|
}));
|
|
1667
1667
|
} catch (i) {
|
|
@@ -1672,14 +1672,14 @@ function Fs(e, r, t) {
|
|
|
1672
1672
|
return "_zod" in s && typeof s._zod == "object";
|
|
1673
1673
|
})(e)) return function(s, o, n) {
|
|
1674
1674
|
try {
|
|
1675
|
-
return Promise.resolve(
|
|
1676
|
-
return Promise.resolve((t.mode === "sync" ?
|
|
1677
|
-
return n.shouldUseNativeValidation &&
|
|
1675
|
+
return Promise.resolve(Ht(function() {
|
|
1676
|
+
return Promise.resolve((t.mode === "sync" ? gs : ps)(e, s, r)).then(function(i) {
|
|
1677
|
+
return n.shouldUseNativeValidation && Ye({}, n), { errors: {}, values: t.raw ? Object.assign({}, s) : i };
|
|
1678
1678
|
});
|
|
1679
1679
|
}, function(i) {
|
|
1680
1680
|
if ((function(l) {
|
|
1681
|
-
return l instanceof
|
|
1682
|
-
})(i)) return { values: {}, errors:
|
|
1681
|
+
return l instanceof ms;
|
|
1682
|
+
})(i)) return { values: {}, errors: Bt(bs(i.issues, !n.shouldUseNativeValidation && n.criteriaMode === "all"), n) };
|
|
1683
1683
|
throw i;
|
|
1684
1684
|
}));
|
|
1685
1685
|
} catch (i) {
|
|
@@ -1688,14 +1688,14 @@ function Fs(e, r, t) {
|
|
|
1688
1688
|
};
|
|
1689
1689
|
throw new Error("Invalid input: not a Zod schema");
|
|
1690
1690
|
}
|
|
1691
|
-
const yr =
|
|
1691
|
+
const yr = $.createContext(null);
|
|
1692
1692
|
function xs() {
|
|
1693
|
-
const e =
|
|
1693
|
+
const e = $.useContext(yr);
|
|
1694
1694
|
if (!e)
|
|
1695
1695
|
throw new Error("useFormContext must be used within a Form component");
|
|
1696
1696
|
return e;
|
|
1697
1697
|
}
|
|
1698
|
-
function
|
|
1698
|
+
function Fs({
|
|
1699
1699
|
onSubmit: e,
|
|
1700
1700
|
children: r,
|
|
1701
1701
|
schema: t,
|
|
@@ -1706,17 +1706,17 @@ function Vs({
|
|
|
1706
1706
|
style: l,
|
|
1707
1707
|
formProps: d
|
|
1708
1708
|
}) {
|
|
1709
|
-
const
|
|
1710
|
-
resolver: t ?
|
|
1709
|
+
const y = cs({
|
|
1710
|
+
resolver: t ? Ss(t) : void 0,
|
|
1711
1711
|
defaultValues: s,
|
|
1712
1712
|
mode: o,
|
|
1713
1713
|
reValidateMode: n
|
|
1714
|
-
}), f =
|
|
1715
|
-
return /* @__PURE__ */
|
|
1714
|
+
}), f = y.handleSubmit(e);
|
|
1715
|
+
return /* @__PURE__ */ V(yr.Provider, { value: y, children: /* @__PURE__ */ V("form", { ...d, className: i, style: l, onSubmit: f, children: typeof r == "function" ? r(y) : r }) });
|
|
1716
1716
|
}
|
|
1717
|
-
const Uo =
|
|
1718
|
-
formError:
|
|
1719
|
-
},
|
|
1717
|
+
const Uo = Fs, Vs = "FormError-module__formError___kaUBn", ws = {
|
|
1718
|
+
formError: Vs
|
|
1719
|
+
}, ks = ({
|
|
1720
1720
|
// Color prop
|
|
1721
1721
|
color: e,
|
|
1722
1722
|
// Content
|
|
@@ -1732,15 +1732,15 @@ const Uo = Vs, ws = "FormError-module__formError___kaUBn", ks = {
|
|
|
1732
1732
|
color: e || n.colors.error,
|
|
1733
1733
|
...s
|
|
1734
1734
|
// Top level style prop overrides
|
|
1735
|
-
}, l = [
|
|
1736
|
-
return /* @__PURE__ */
|
|
1737
|
-
},
|
|
1738
|
-
formGroup:
|
|
1739
|
-
inputWrapper:
|
|
1740
|
-
indented:
|
|
1741
|
-
disabled:
|
|
1742
|
-
required:
|
|
1743
|
-
},
|
|
1735
|
+
}, l = [ws.formError, t].filter(Boolean).join(" ");
|
|
1736
|
+
return /* @__PURE__ */ V("div", { ...o, className: l, style: i, role: "alert", "aria-live": "polite", children: r });
|
|
1737
|
+
}, Cs = "FormGroup-module__formGroup___aVI-B", zs = "FormGroup-module__inputWrapper___429QE", $s = "FormGroup-module__indented___t61iz", Es = "FormGroup-module__disabled___W-tJ0", As = "FormGroup-module__required___mO3xA", ye = {
|
|
1738
|
+
formGroup: Cs,
|
|
1739
|
+
inputWrapper: zs,
|
|
1740
|
+
indented: $s,
|
|
1741
|
+
disabled: Es,
|
|
1742
|
+
required: As
|
|
1743
|
+
}, Ns = ({
|
|
1744
1744
|
// State props
|
|
1745
1745
|
disabled: e = !1,
|
|
1746
1746
|
error: r = !1,
|
|
@@ -1755,40 +1755,40 @@ const Uo = Vs, ws = "FormError-module__formError___kaUBn", ks = {
|
|
|
1755
1755
|
// Content
|
|
1756
1756
|
children: d,
|
|
1757
1757
|
// Style overrides
|
|
1758
|
-
className:
|
|
1758
|
+
className: y,
|
|
1759
1759
|
style: f,
|
|
1760
1760
|
// Element-specific props
|
|
1761
|
-
divProps:
|
|
1761
|
+
divProps: m
|
|
1762
1762
|
}) => {
|
|
1763
|
-
const
|
|
1763
|
+
const h = O(), x = [
|
|
1764
1764
|
ye.formGroup,
|
|
1765
1765
|
r ? ye.error : "",
|
|
1766
1766
|
e ? ye.disabled : "",
|
|
1767
|
-
|
|
1768
|
-
].filter(Boolean).join(" "),
|
|
1769
|
-
"--form-group-margin-bottom": `calc(${
|
|
1767
|
+
y
|
|
1768
|
+
].filter(Boolean).join(" "), F = {
|
|
1769
|
+
"--form-group-margin-bottom": `calc(${h.fonts.rhythm} * 0.35)`,
|
|
1770
1770
|
...f
|
|
1771
|
-
},
|
|
1772
|
-
if (
|
|
1773
|
-
const
|
|
1774
|
-
if (e &&
|
|
1775
|
-
return
|
|
1771
|
+
}, _ = $.Children.map(d, (C) => {
|
|
1772
|
+
if ($.isValidElement(C)) {
|
|
1773
|
+
const A = {};
|
|
1774
|
+
if (e && C.props.disabled === void 0 && (A.disabled = !0), r && C.props.error === void 0 && (A.error = !0), o && C.props.id === void 0 && (A.id = o), Object.keys(A).length > 0)
|
|
1775
|
+
return $.cloneElement(C, A);
|
|
1776
1776
|
}
|
|
1777
|
-
return
|
|
1777
|
+
return C;
|
|
1778
1778
|
});
|
|
1779
|
-
return /* @__PURE__ */ K("div", { ...
|
|
1780
|
-
n && /* @__PURE__ */ K(
|
|
1779
|
+
return /* @__PURE__ */ K("div", { ...m, className: x, style: F, children: [
|
|
1780
|
+
n && /* @__PURE__ */ K(rt, { htmlFor: o, disabled: e, error: r, ...l, children: [
|
|
1781
1781
|
n,
|
|
1782
1782
|
t && /* @__PURE__ */ K("span", { className: ye.required, "aria-label": "required", children: [
|
|
1783
1783
|
" ",
|
|
1784
1784
|
"*"
|
|
1785
1785
|
] })
|
|
1786
1786
|
] }),
|
|
1787
|
-
/* @__PURE__ */
|
|
1788
|
-
r && i && /* @__PURE__ */
|
|
1787
|
+
/* @__PURE__ */ V("div", { className: `${ye.inputWrapper} ${s ? ye.indented : ""}`, children: _ }),
|
|
1788
|
+
r && i && /* @__PURE__ */ V(ks, { children: i })
|
|
1789
1789
|
] });
|
|
1790
1790
|
};
|
|
1791
|
-
function
|
|
1791
|
+
function Se({
|
|
1792
1792
|
name: e,
|
|
1793
1793
|
label: r,
|
|
1794
1794
|
required: t,
|
|
@@ -1798,45 +1798,45 @@ function de({
|
|
|
1798
1798
|
className: i,
|
|
1799
1799
|
style: l,
|
|
1800
1800
|
indent: d,
|
|
1801
|
-
labelProps:
|
|
1801
|
+
labelProps: y
|
|
1802
1802
|
}) {
|
|
1803
1803
|
const { control: f } = xs(), {
|
|
1804
|
-
field:
|
|
1805
|
-
fieldState: { error:
|
|
1806
|
-
} =
|
|
1804
|
+
field: m,
|
|
1805
|
+
fieldState: { error: h }
|
|
1806
|
+
} = Zr({
|
|
1807
1807
|
name: e,
|
|
1808
1808
|
control: f,
|
|
1809
1809
|
rules: o
|
|
1810
1810
|
});
|
|
1811
|
-
return /* @__PURE__ */
|
|
1812
|
-
|
|
1811
|
+
return /* @__PURE__ */ V(
|
|
1812
|
+
Ns,
|
|
1813
1813
|
{
|
|
1814
1814
|
label: r,
|
|
1815
1815
|
name: e,
|
|
1816
|
-
error: !!
|
|
1817
|
-
errorMessage:
|
|
1816
|
+
error: !!h,
|
|
1817
|
+
errorMessage: h == null ? void 0 : h.message,
|
|
1818
1818
|
disabled: n,
|
|
1819
1819
|
required: t,
|
|
1820
1820
|
className: i,
|
|
1821
1821
|
style: l,
|
|
1822
1822
|
indent: d,
|
|
1823
|
-
labelProps:
|
|
1823
|
+
labelProps: y,
|
|
1824
1824
|
children: s({
|
|
1825
|
-
value:
|
|
1826
|
-
onChange:
|
|
1827
|
-
onBlur:
|
|
1828
|
-
name:
|
|
1829
|
-
error: !!
|
|
1825
|
+
value: m.value,
|
|
1826
|
+
onChange: m.onChange,
|
|
1827
|
+
onBlur: m.onBlur,
|
|
1828
|
+
name: m.name,
|
|
1829
|
+
error: !!h,
|
|
1830
1830
|
indent: d
|
|
1831
1831
|
})
|
|
1832
1832
|
}
|
|
1833
1833
|
);
|
|
1834
1834
|
}
|
|
1835
|
-
const
|
|
1836
|
-
input:
|
|
1837
|
-
sizeSmall:
|
|
1838
|
-
sizeLarge:
|
|
1839
|
-
},
|
|
1835
|
+
const Rs = "Input-module__input___WjT81", Ds = "Input-module__sizeSmall___NFvsi", Ps = "Input-module__sizeLarge___4Boj3", Ie = {
|
|
1836
|
+
input: Rs,
|
|
1837
|
+
sizeSmall: Ds,
|
|
1838
|
+
sizeLarge: Ps
|
|
1839
|
+
}, Ls = ({
|
|
1840
1840
|
color: e = "#000",
|
|
1841
1841
|
disabled: r = !1,
|
|
1842
1842
|
fontSize: t = "1em",
|
|
@@ -1847,7 +1847,7 @@ const Ds = "Input-module__input___WjT81", Ps = "Input-module__sizeSmall___NFvsi"
|
|
|
1847
1847
|
fontSize: t,
|
|
1848
1848
|
opacity: r ? 0.3 : 1,
|
|
1849
1849
|
placeholderOpacity: s
|
|
1850
|
-
}),
|
|
1850
|
+
}), Bs = ({
|
|
1851
1851
|
// State props
|
|
1852
1852
|
disabled: e = !1,
|
|
1853
1853
|
error: r = !1,
|
|
@@ -1861,52 +1861,52 @@ const Ds = "Input-module__input___WjT81", Ps = "Input-module__sizeSmall___NFvsi"
|
|
|
1861
1861
|
placeholder: i,
|
|
1862
1862
|
placeholderOpacity: l = 0.3,
|
|
1863
1863
|
type: d = "text",
|
|
1864
|
-
value:
|
|
1864
|
+
value: y = "",
|
|
1865
1865
|
// Event handlers
|
|
1866
1866
|
onChange: f,
|
|
1867
|
-
onBlur:
|
|
1867
|
+
onBlur: m,
|
|
1868
1868
|
// Standard React props
|
|
1869
|
-
className:
|
|
1870
|
-
style:
|
|
1869
|
+
className: h,
|
|
1870
|
+
style: x,
|
|
1871
1871
|
// Element-specific props
|
|
1872
|
-
inputProps:
|
|
1872
|
+
inputProps: F
|
|
1873
1873
|
}) => {
|
|
1874
|
-
const
|
|
1875
|
-
color:
|
|
1874
|
+
const _ = O(), C = _.colors.error, A = r ? C : t || _.colors.primary, S = Ls({
|
|
1875
|
+
color: A,
|
|
1876
1876
|
disabled: e,
|
|
1877
|
-
fontSize:
|
|
1877
|
+
fontSize: _.fonts.size,
|
|
1878
1878
|
placeholderOpacity: l
|
|
1879
|
-
}),
|
|
1879
|
+
}), z = {
|
|
1880
1880
|
"--placeholder-opacity": S.placeholderOpacity,
|
|
1881
|
-
"--input-padding-small": `calc(${
|
|
1882
|
-
"--input-padding-large": `calc(${
|
|
1881
|
+
"--input-padding-small": `calc(${_.fonts.rhythm} * ${_.sizes.small.paddingVertical}) calc(${_.fonts.rhythm} * ${_.inputs.paddingHorizontal})`,
|
|
1882
|
+
"--input-padding-large": `calc(${_.fonts.rhythm} * ${_.sizes.large.paddingVertical}) calc(${_.fonts.rhythm} * ${_.inputs.paddingHorizontal})`,
|
|
1883
1883
|
borderColor: S.borderColor,
|
|
1884
|
-
borderWidth:
|
|
1885
|
-
borderRadius:
|
|
1884
|
+
borderWidth: _.border.width,
|
|
1885
|
+
borderRadius: _.border.radius,
|
|
1886
1886
|
color: S.color,
|
|
1887
1887
|
fontSize: S.fontSize,
|
|
1888
1888
|
opacity: S.opacity,
|
|
1889
|
-
...
|
|
1889
|
+
...x
|
|
1890
1890
|
// Top level style prop overrides
|
|
1891
|
-
},
|
|
1892
|
-
|
|
1893
|
-
s === "small" ?
|
|
1894
|
-
|
|
1891
|
+
}, k = [
|
|
1892
|
+
Ie.input,
|
|
1893
|
+
s === "small" ? Ie.sizeSmall : Ie.sizeLarge,
|
|
1894
|
+
h
|
|
1895
1895
|
].filter(Boolean).join(" ");
|
|
1896
|
-
return /* @__PURE__ */
|
|
1896
|
+
return /* @__PURE__ */ V(
|
|
1897
1897
|
"input",
|
|
1898
1898
|
{
|
|
1899
|
-
...
|
|
1900
|
-
className:
|
|
1899
|
+
...F,
|
|
1900
|
+
className: k,
|
|
1901
1901
|
disabled: e,
|
|
1902
1902
|
id: o,
|
|
1903
1903
|
name: n,
|
|
1904
1904
|
onChange: f,
|
|
1905
|
-
onBlur:
|
|
1905
|
+
onBlur: m,
|
|
1906
1906
|
placeholder: i,
|
|
1907
1907
|
type: d,
|
|
1908
|
-
value:
|
|
1909
|
-
style:
|
|
1908
|
+
value: y,
|
|
1909
|
+
style: z
|
|
1910
1910
|
}
|
|
1911
1911
|
);
|
|
1912
1912
|
};
|
|
@@ -1920,8 +1920,8 @@ function Wo({
|
|
|
1920
1920
|
style: i,
|
|
1921
1921
|
...l
|
|
1922
1922
|
}) {
|
|
1923
|
-
return /* @__PURE__ */
|
|
1924
|
-
|
|
1923
|
+
return /* @__PURE__ */ V(
|
|
1924
|
+
Se,
|
|
1925
1925
|
{
|
|
1926
1926
|
name: e,
|
|
1927
1927
|
label: r,
|
|
@@ -1930,25 +1930,25 @@ function Wo({
|
|
|
1930
1930
|
disabled: o,
|
|
1931
1931
|
className: n,
|
|
1932
1932
|
style: i,
|
|
1933
|
-
children: ({ value: d, onChange:
|
|
1934
|
-
|
|
1933
|
+
children: ({ value: d, onChange: y, onBlur: f, name: m, error: h }) => /* @__PURE__ */ V(
|
|
1934
|
+
Bs,
|
|
1935
1935
|
{
|
|
1936
1936
|
...l,
|
|
1937
|
-
name:
|
|
1937
|
+
name: m,
|
|
1938
1938
|
value: d || "",
|
|
1939
|
-
onChange: (
|
|
1939
|
+
onChange: (x) => y(x.target.value),
|
|
1940
1940
|
inputProps: { onBlur: f },
|
|
1941
|
-
error:
|
|
1941
|
+
error: h
|
|
1942
1942
|
}
|
|
1943
1943
|
)
|
|
1944
1944
|
}
|
|
1945
1945
|
);
|
|
1946
1946
|
}
|
|
1947
|
-
const
|
|
1948
|
-
textarea:
|
|
1949
|
-
sizeSmall:
|
|
1950
|
-
sizeLarge:
|
|
1951
|
-
},
|
|
1947
|
+
const Os = "Textarea-module__textarea___Z-y6g", Hs = "Textarea-module__sizeSmall___HHFEM", Ts = "Textarea-module__sizeLarge___5a3sf", Ue = {
|
|
1948
|
+
textarea: Os,
|
|
1949
|
+
sizeSmall: Hs,
|
|
1950
|
+
sizeLarge: Ts
|
|
1951
|
+
}, Ms = ({
|
|
1952
1952
|
color: e = "#000",
|
|
1953
1953
|
disabled: r = !1,
|
|
1954
1954
|
placeholderOpacity: t = 0.3
|
|
@@ -1957,7 +1957,7 @@ const Hs = "Textarea-module__textarea___Z-y6g", Ts = "Textarea-module__sizeSmall
|
|
|
1957
1957
|
borderColor: e,
|
|
1958
1958
|
opacity: r ? 0.3 : 1,
|
|
1959
1959
|
placeholderOpacity: t
|
|
1960
|
-
}),
|
|
1960
|
+
}), js = ({
|
|
1961
1961
|
// State props
|
|
1962
1962
|
disabled: e = !1,
|
|
1963
1963
|
error: r = !1,
|
|
@@ -1971,51 +1971,51 @@ const Hs = "Textarea-module__textarea___Z-y6g", Ts = "Textarea-module__sizeSmall
|
|
|
1971
1971
|
placeholder: i,
|
|
1972
1972
|
placeholderOpacity: l = 0.3,
|
|
1973
1973
|
rows: d = 3,
|
|
1974
|
-
value:
|
|
1974
|
+
value: y = "",
|
|
1975
1975
|
// Event handlers
|
|
1976
1976
|
onChange: f,
|
|
1977
|
-
onBlur:
|
|
1977
|
+
onBlur: m,
|
|
1978
1978
|
// Standard React props
|
|
1979
|
-
className:
|
|
1980
|
-
style:
|
|
1979
|
+
className: h,
|
|
1980
|
+
style: x,
|
|
1981
1981
|
// Element-specific props
|
|
1982
|
-
textareaProps:
|
|
1982
|
+
textareaProps: F
|
|
1983
1983
|
}) => {
|
|
1984
|
-
const
|
|
1985
|
-
color:
|
|
1984
|
+
const _ = O(), C = _.colors.error, A = r ? C : t || _.colors.primary, S = Ms({
|
|
1985
|
+
color: A,
|
|
1986
1986
|
disabled: e,
|
|
1987
1987
|
placeholderOpacity: l
|
|
1988
|
-
}),
|
|
1988
|
+
}), z = {
|
|
1989
1989
|
"--placeholder-opacity": S.placeholderOpacity,
|
|
1990
|
-
"--textarea-padding-small": `calc(${
|
|
1991
|
-
"--textarea-padding-large": `calc(${
|
|
1990
|
+
"--textarea-padding-small": `calc(${_.fonts.rhythm} * ${_.sizes.small.paddingVertical}) calc(${_.fonts.rhythm} * ${_.inputs.paddingHorizontal})`,
|
|
1991
|
+
"--textarea-padding-large": `calc(${_.fonts.rhythm} * ${_.sizes.large.paddingVertical}) calc(${_.fonts.rhythm} * ${_.inputs.paddingHorizontal})`,
|
|
1992
1992
|
borderColor: S.borderColor,
|
|
1993
|
-
borderWidth:
|
|
1994
|
-
borderRadius:
|
|
1993
|
+
borderWidth: _.border.width,
|
|
1994
|
+
borderRadius: _.border.radius,
|
|
1995
1995
|
color: S.color,
|
|
1996
|
-
fontSize:
|
|
1996
|
+
fontSize: _.fonts.size,
|
|
1997
1997
|
opacity: S.opacity,
|
|
1998
|
-
...
|
|
1998
|
+
...x
|
|
1999
1999
|
// Top level style overrides
|
|
2000
|
-
},
|
|
2001
|
-
|
|
2002
|
-
s === "small" ?
|
|
2003
|
-
|
|
2000
|
+
}, k = [
|
|
2001
|
+
Ue.textarea,
|
|
2002
|
+
s === "small" ? Ue.sizeSmall : Ue.sizeLarge,
|
|
2003
|
+
h
|
|
2004
2004
|
].filter(Boolean).join(" ");
|
|
2005
|
-
return /* @__PURE__ */
|
|
2005
|
+
return /* @__PURE__ */ V(
|
|
2006
2006
|
"textarea",
|
|
2007
2007
|
{
|
|
2008
|
-
...
|
|
2009
|
-
className:
|
|
2008
|
+
...F,
|
|
2009
|
+
className: k,
|
|
2010
2010
|
disabled: e,
|
|
2011
2011
|
id: o,
|
|
2012
2012
|
name: n,
|
|
2013
2013
|
onChange: f,
|
|
2014
|
-
onBlur:
|
|
2014
|
+
onBlur: m,
|
|
2015
2015
|
placeholder: i,
|
|
2016
2016
|
rows: d,
|
|
2017
|
-
value:
|
|
2018
|
-
style:
|
|
2017
|
+
value: y,
|
|
2018
|
+
style: z
|
|
2019
2019
|
}
|
|
2020
2020
|
);
|
|
2021
2021
|
};
|
|
@@ -2029,8 +2029,8 @@ function qo({
|
|
|
2029
2029
|
style: i,
|
|
2030
2030
|
...l
|
|
2031
2031
|
}) {
|
|
2032
|
-
return /* @__PURE__ */
|
|
2033
|
-
|
|
2032
|
+
return /* @__PURE__ */ V(
|
|
2033
|
+
Se,
|
|
2034
2034
|
{
|
|
2035
2035
|
name: e,
|
|
2036
2036
|
label: r,
|
|
@@ -2039,25 +2039,25 @@ function qo({
|
|
|
2039
2039
|
disabled: o,
|
|
2040
2040
|
className: n,
|
|
2041
2041
|
style: i,
|
|
2042
|
-
children: ({ value: d, onChange:
|
|
2043
|
-
|
|
2042
|
+
children: ({ value: d, onChange: y, onBlur: f, name: m, error: h }) => /* @__PURE__ */ V(
|
|
2043
|
+
js,
|
|
2044
2044
|
{
|
|
2045
2045
|
...l,
|
|
2046
|
-
name:
|
|
2046
|
+
name: m,
|
|
2047
2047
|
value: d || "",
|
|
2048
|
-
onChange: (
|
|
2048
|
+
onChange: (x) => y(x.target.value),
|
|
2049
2049
|
onBlur: f,
|
|
2050
|
-
error:
|
|
2050
|
+
error: h
|
|
2051
2051
|
}
|
|
2052
2052
|
)
|
|
2053
2053
|
}
|
|
2054
2054
|
);
|
|
2055
2055
|
}
|
|
2056
|
-
const
|
|
2057
|
-
select:
|
|
2058
|
-
sizeSmall:
|
|
2059
|
-
sizeLarge:
|
|
2060
|
-
},
|
|
2056
|
+
const Is = "Select-module__select___cjdcr", Us = "Select-module__sizeSmall___i1quj", Ws = "Select-module__sizeLarge___eBA1T", We = {
|
|
2057
|
+
select: Is,
|
|
2058
|
+
sizeSmall: Us,
|
|
2059
|
+
sizeLarge: Ws
|
|
2060
|
+
}, qs = ({
|
|
2061
2061
|
color: e = "#000",
|
|
2062
2062
|
disabled: r = !1
|
|
2063
2063
|
}) => ({
|
|
@@ -2084,7 +2084,7 @@ const Us = "Select-module__select___cjdcr", Ws = "Select-module__sizeSmall___i1q
|
|
|
2084
2084
|
`.trim();
|
|
2085
2085
|
return `url("data:image/svg+xml,${encodeURIComponent(i)}")`;
|
|
2086
2086
|
})(e)
|
|
2087
|
-
}),
|
|
2087
|
+
}), Gs = ({
|
|
2088
2088
|
// State props
|
|
2089
2089
|
disabled: e = !1,
|
|
2090
2090
|
error: r = !1,
|
|
@@ -2099,53 +2099,53 @@ const Us = "Select-module__select___cjdcr", Ws = "Select-module__sizeSmall___i1q
|
|
|
2099
2099
|
value: l = "",
|
|
2100
2100
|
// Event handlers
|
|
2101
2101
|
onChange: d,
|
|
2102
|
-
onBlur:
|
|
2102
|
+
onBlur: y,
|
|
2103
2103
|
// Standard React props
|
|
2104
2104
|
children: f,
|
|
2105
|
-
className:
|
|
2106
|
-
style:
|
|
2105
|
+
className: m,
|
|
2106
|
+
style: h,
|
|
2107
2107
|
// Element-specific props
|
|
2108
|
-
selectProps:
|
|
2108
|
+
selectProps: x
|
|
2109
2109
|
}) => {
|
|
2110
|
-
const
|
|
2111
|
-
color:
|
|
2110
|
+
const F = O(), _ = F.colors.error, C = r ? _ : t || F.colors.primary, A = qs({
|
|
2111
|
+
color: C,
|
|
2112
2112
|
disabled: e
|
|
2113
2113
|
}), S = {
|
|
2114
|
-
"--select-padding-small": `calc(${
|
|
2115
|
-
"--select-padding-large": `calc(${
|
|
2116
|
-
backgroundImage:
|
|
2114
|
+
"--select-padding-small": `calc(${F.fonts.rhythm} * ${F.sizes.small.paddingVertical}) calc(${F.fonts.rhythm} * 1.2) calc(${F.fonts.rhythm} * ${F.sizes.small.paddingVertical}) calc(${F.fonts.rhythm} * ${F.inputs.paddingHorizontal})`,
|
|
2115
|
+
"--select-padding-large": `calc(${F.fonts.rhythm} * ${F.sizes.large.paddingVertical}) calc(${F.fonts.rhythm} * 1.4) calc(${F.fonts.rhythm} * ${F.sizes.large.paddingVertical}) calc(${F.fonts.rhythm} * ${F.inputs.paddingHorizontal})`,
|
|
2116
|
+
backgroundImage: A.backgroundImage,
|
|
2117
2117
|
backgroundPosition: "right center",
|
|
2118
2118
|
backgroundRepeat: "no-repeat",
|
|
2119
2119
|
backgroundSize: "auto 85%",
|
|
2120
2120
|
backgroundColor: "transparent",
|
|
2121
|
-
borderColor:
|
|
2122
|
-
borderWidth:
|
|
2123
|
-
borderRadius:
|
|
2124
|
-
color:
|
|
2125
|
-
cursor:
|
|
2126
|
-
fontSize:
|
|
2127
|
-
opacity:
|
|
2128
|
-
...
|
|
2121
|
+
borderColor: A.borderColor,
|
|
2122
|
+
borderWidth: F.border.width,
|
|
2123
|
+
borderRadius: F.border.radius,
|
|
2124
|
+
color: A.color,
|
|
2125
|
+
cursor: A.cursor,
|
|
2126
|
+
fontSize: F.fonts.size,
|
|
2127
|
+
opacity: A.opacity,
|
|
2128
|
+
...h
|
|
2129
2129
|
// Top level style overrides
|
|
2130
|
-
},
|
|
2131
|
-
|
|
2132
|
-
s === "small" ?
|
|
2133
|
-
|
|
2130
|
+
}, z = [
|
|
2131
|
+
We.select,
|
|
2132
|
+
s === "small" ? We.sizeSmall : We.sizeLarge,
|
|
2133
|
+
m
|
|
2134
2134
|
].filter(Boolean).join(" ");
|
|
2135
2135
|
return /* @__PURE__ */ K(
|
|
2136
2136
|
"select",
|
|
2137
2137
|
{
|
|
2138
|
-
...
|
|
2139
|
-
className:
|
|
2138
|
+
...x,
|
|
2139
|
+
className: z,
|
|
2140
2140
|
disabled: e,
|
|
2141
2141
|
id: o,
|
|
2142
2142
|
name: n,
|
|
2143
2143
|
onChange: d,
|
|
2144
|
-
onBlur:
|
|
2144
|
+
onBlur: y,
|
|
2145
2145
|
value: l,
|
|
2146
2146
|
style: S,
|
|
2147
2147
|
children: [
|
|
2148
|
-
i !== "" && /* @__PURE__ */
|
|
2148
|
+
i !== "" && /* @__PURE__ */ V("option", { disabled: !0, value: "", children: i }),
|
|
2149
2149
|
f
|
|
2150
2150
|
]
|
|
2151
2151
|
}
|
|
@@ -2162,8 +2162,8 @@ function Go({
|
|
|
2162
2162
|
children: l,
|
|
2163
2163
|
...d
|
|
2164
2164
|
}) {
|
|
2165
|
-
return /* @__PURE__ */
|
|
2166
|
-
|
|
2165
|
+
return /* @__PURE__ */ V(
|
|
2166
|
+
Se,
|
|
2167
2167
|
{
|
|
2168
2168
|
name: e,
|
|
2169
2169
|
label: r,
|
|
@@ -2172,15 +2172,15 @@ function Go({
|
|
|
2172
2172
|
disabled: o,
|
|
2173
2173
|
className: n,
|
|
2174
2174
|
style: i,
|
|
2175
|
-
children: ({ value:
|
|
2176
|
-
|
|
2175
|
+
children: ({ value: y, onChange: f, onBlur: m, name: h, error: x }) => /* @__PURE__ */ V(
|
|
2176
|
+
Gs,
|
|
2177
2177
|
{
|
|
2178
2178
|
...d,
|
|
2179
|
-
name:
|
|
2180
|
-
value:
|
|
2181
|
-
onChange: (
|
|
2182
|
-
onBlur:
|
|
2183
|
-
error:
|
|
2179
|
+
name: h,
|
|
2180
|
+
value: y || "",
|
|
2181
|
+
onChange: (F) => f(F.target.value),
|
|
2182
|
+
onBlur: m,
|
|
2183
|
+
error: x,
|
|
2184
2184
|
children: l
|
|
2185
2185
|
}
|
|
2186
2186
|
)
|
|
@@ -2196,8 +2196,8 @@ function Zo({
|
|
|
2196
2196
|
style: n,
|
|
2197
2197
|
...i
|
|
2198
2198
|
}) {
|
|
2199
|
-
return /* @__PURE__ */
|
|
2200
|
-
|
|
2199
|
+
return /* @__PURE__ */ V(
|
|
2200
|
+
Se,
|
|
2201
2201
|
{
|
|
2202
2202
|
name: e,
|
|
2203
2203
|
required: r,
|
|
@@ -2205,31 +2205,31 @@ function Zo({
|
|
|
2205
2205
|
disabled: s,
|
|
2206
2206
|
className: o,
|
|
2207
2207
|
style: n,
|
|
2208
|
-
children: ({ value: l, onChange: d, name:
|
|
2209
|
-
|
|
2208
|
+
children: ({ value: l, onChange: d, name: y, error: f }) => /* @__PURE__ */ V(
|
|
2209
|
+
Ir,
|
|
2210
2210
|
{
|
|
2211
2211
|
...i,
|
|
2212
|
-
name:
|
|
2212
|
+
name: y,
|
|
2213
2213
|
checked: !!l,
|
|
2214
|
-
onChange: (
|
|
2214
|
+
onChange: (m) => d(m.target.checked),
|
|
2215
2215
|
error: f
|
|
2216
2216
|
}
|
|
2217
2217
|
)
|
|
2218
2218
|
}
|
|
2219
2219
|
);
|
|
2220
2220
|
}
|
|
2221
|
-
const
|
|
2222
|
-
container:
|
|
2223
|
-
svg:
|
|
2224
|
-
label:
|
|
2225
|
-
},
|
|
2221
|
+
const Zs = "Radio-module__container___AQxhk", Qs = "Radio-module__svg___zl5kF", Ks = "Radio-module__label___vAFIP", qe = {
|
|
2222
|
+
container: Zs,
|
|
2223
|
+
svg: Qs,
|
|
2224
|
+
label: Ks
|
|
2225
|
+
}, Js = ({
|
|
2226
2226
|
color: e = "#000",
|
|
2227
2227
|
disabled: r = !1
|
|
2228
2228
|
}) => ({
|
|
2229
2229
|
radioColor: e,
|
|
2230
2230
|
cursor: r ? "default" : "pointer",
|
|
2231
2231
|
opacity: r ? 0.3 : 1
|
|
2232
|
-
}),
|
|
2232
|
+
}), Xs = ({
|
|
2233
2233
|
// Color prop
|
|
2234
2234
|
color: e,
|
|
2235
2235
|
// State props
|
|
@@ -2243,40 +2243,40 @@ const Qs = "Radio-module__container___AQxhk", Ks = "Radio-module__svg___zl5kF",
|
|
|
2243
2243
|
label: l,
|
|
2244
2244
|
labelStyle: d,
|
|
2245
2245
|
// Style overrides
|
|
2246
|
-
className:
|
|
2246
|
+
className: y,
|
|
2247
2247
|
style: f,
|
|
2248
2248
|
// Element-specific props
|
|
2249
|
-
divProps:
|
|
2249
|
+
divProps: m
|
|
2250
2250
|
}) => {
|
|
2251
|
-
const
|
|
2252
|
-
color:
|
|
2251
|
+
const h = O(), x = n || Qt(), F = h.colors.error, _ = s ? F : e || h.colors.primary, C = Js({
|
|
2252
|
+
color: _,
|
|
2253
2253
|
disabled: t
|
|
2254
|
-
}),
|
|
2255
|
-
t || i(
|
|
2254
|
+
}), A = (M) => {
|
|
2255
|
+
t || i(M);
|
|
2256
2256
|
}, S = {
|
|
2257
|
-
cursor:
|
|
2258
|
-
fontSize:
|
|
2259
|
-
opacity:
|
|
2257
|
+
cursor: C.cursor,
|
|
2258
|
+
fontSize: h.fonts.size,
|
|
2259
|
+
opacity: C.opacity,
|
|
2260
2260
|
...f
|
|
2261
2261
|
// Top level style overrides
|
|
2262
|
-
},
|
|
2262
|
+
}, z = {
|
|
2263
2263
|
width: "1em"
|
|
2264
|
-
},
|
|
2264
|
+
}, k = {
|
|
2265
2265
|
fill: "transparent",
|
|
2266
2266
|
strokeWidth: "12.5",
|
|
2267
|
-
stroke:
|
|
2268
|
-
},
|
|
2269
|
-
fill:
|
|
2270
|
-
},
|
|
2271
|
-
return /* @__PURE__ */ K("div", { ...
|
|
2272
|
-
/* @__PURE__ */
|
|
2267
|
+
stroke: C.radioColor
|
|
2268
|
+
}, E = {
|
|
2269
|
+
fill: C.radioColor
|
|
2270
|
+
}, H = [qe.container, y].filter(Boolean).join(" ");
|
|
2271
|
+
return /* @__PURE__ */ K("div", { ...m, className: H, style: S, children: [
|
|
2272
|
+
/* @__PURE__ */ V(
|
|
2273
2273
|
"input",
|
|
2274
2274
|
{
|
|
2275
|
-
id:
|
|
2275
|
+
id: x,
|
|
2276
2276
|
checked: r,
|
|
2277
2277
|
disabled: t,
|
|
2278
2278
|
name: o,
|
|
2279
|
-
onChange: (
|
|
2279
|
+
onChange: (M) => A({ target: { checked: M.target.checked, name: o, type: "radio" } }),
|
|
2280
2280
|
style: { display: "none" },
|
|
2281
2281
|
type: "radio"
|
|
2282
2282
|
}
|
|
@@ -2286,22 +2286,22 @@ const Qs = "Radio-module__container___AQxhk", Ks = "Radio-module__svg___zl5kF",
|
|
|
2286
2286
|
{
|
|
2287
2287
|
xmlns: "http://www.w3.org/2000/svg",
|
|
2288
2288
|
viewBox: "0 0 100 100",
|
|
2289
|
-
onClick: () =>
|
|
2290
|
-
className:
|
|
2291
|
-
style:
|
|
2289
|
+
onClick: () => A({ target: { checked: !r, name: o, type: "radio" } }),
|
|
2290
|
+
className: qe.svg,
|
|
2291
|
+
style: z,
|
|
2292
2292
|
children: [
|
|
2293
|
-
/* @__PURE__ */
|
|
2294
|
-
r && /* @__PURE__ */
|
|
2293
|
+
/* @__PURE__ */ V("circle", { cx: "50", cy: "50", r: "42.5", width: "100%", style: k }),
|
|
2294
|
+
r && /* @__PURE__ */ V("circle", { cx: "50", cy: "50", r: "25", style: E })
|
|
2295
2295
|
]
|
|
2296
2296
|
}
|
|
2297
2297
|
),
|
|
2298
|
-
l && /* @__PURE__ */
|
|
2299
|
-
|
|
2298
|
+
l && /* @__PURE__ */ V(
|
|
2299
|
+
rt,
|
|
2300
2300
|
{
|
|
2301
|
-
htmlFor:
|
|
2302
|
-
className:
|
|
2301
|
+
htmlFor: x,
|
|
2302
|
+
className: qe.label,
|
|
2303
2303
|
style: { paddingBottom: 0, ...d },
|
|
2304
|
-
color:
|
|
2304
|
+
color: C.radioColor,
|
|
2305
2305
|
disabled: t,
|
|
2306
2306
|
error: s,
|
|
2307
2307
|
children: l
|
|
@@ -2320,8 +2320,8 @@ function Qo({
|
|
|
2320
2320
|
value: l,
|
|
2321
2321
|
...d
|
|
2322
2322
|
}) {
|
|
2323
|
-
return /* @__PURE__ */
|
|
2324
|
-
|
|
2323
|
+
return /* @__PURE__ */ V(
|
|
2324
|
+
Se,
|
|
2325
2325
|
{
|
|
2326
2326
|
name: e,
|
|
2327
2327
|
required: t,
|
|
@@ -2329,119 +2329,21 @@ function Qo({
|
|
|
2329
2329
|
disabled: o,
|
|
2330
2330
|
className: n,
|
|
2331
2331
|
style: i,
|
|
2332
|
-
children: ({ value:
|
|
2333
|
-
|
|
2332
|
+
children: ({ value: y, onChange: f, name: m, error: h }) => /* @__PURE__ */ V(
|
|
2333
|
+
Xs,
|
|
2334
2334
|
{
|
|
2335
2335
|
...d,
|
|
2336
|
-
name:
|
|
2337
|
-
checked:
|
|
2336
|
+
name: m,
|
|
2337
|
+
checked: y === l,
|
|
2338
2338
|
onChange: () => f(l),
|
|
2339
|
-
error:
|
|
2339
|
+
error: h,
|
|
2340
2340
|
label: r
|
|
2341
2341
|
}
|
|
2342
2342
|
)
|
|
2343
2343
|
}
|
|
2344
2344
|
);
|
|
2345
2345
|
}
|
|
2346
|
-
|
|
2347
|
-
name: e,
|
|
2348
|
-
label: r,
|
|
2349
|
-
required: t,
|
|
2350
|
-
options: s,
|
|
2351
|
-
disabled: o,
|
|
2352
|
-
className: n,
|
|
2353
|
-
style: i,
|
|
2354
|
-
indent: l = !0
|
|
2355
|
-
}) {
|
|
2356
|
-
return /* @__PURE__ */ x(
|
|
2357
|
-
de,
|
|
2358
|
-
{
|
|
2359
|
-
name: e,
|
|
2360
|
-
label: r,
|
|
2361
|
-
required: t,
|
|
2362
|
-
disabled: o,
|
|
2363
|
-
className: n,
|
|
2364
|
-
style: i,
|
|
2365
|
-
indent: l,
|
|
2366
|
-
labelProps: {
|
|
2367
|
-
style: {
|
|
2368
|
-
marginBottom: ".25em"
|
|
2369
|
-
}
|
|
2370
|
-
},
|
|
2371
|
-
children: ({ value: d, onChange: m, name: f, error: y }) => /* @__PURE__ */ x(Se, { children: s.map((g) => /* @__PURE__ */ x(
|
|
2372
|
-
hr,
|
|
2373
|
-
{
|
|
2374
|
-
name: f,
|
|
2375
|
-
checked: d === g.value,
|
|
2376
|
-
onChange: () => m(g.value),
|
|
2377
|
-
label: g.label,
|
|
2378
|
-
disabled: o || g.disabled,
|
|
2379
|
-
error: y
|
|
2380
|
-
},
|
|
2381
|
-
g.value
|
|
2382
|
-
)) })
|
|
2383
|
-
}
|
|
2384
|
-
);
|
|
2385
|
-
}
|
|
2386
|
-
function Jo({
|
|
2387
|
-
name: e,
|
|
2388
|
-
label: r,
|
|
2389
|
-
required: t,
|
|
2390
|
-
options: s,
|
|
2391
|
-
children: o,
|
|
2392
|
-
disabled: n,
|
|
2393
|
-
className: i,
|
|
2394
|
-
style: l,
|
|
2395
|
-
indent: d = !0
|
|
2396
|
-
}) {
|
|
2397
|
-
return /* @__PURE__ */ x(
|
|
2398
|
-
de,
|
|
2399
|
-
{
|
|
2400
|
-
name: e,
|
|
2401
|
-
label: r,
|
|
2402
|
-
required: t,
|
|
2403
|
-
disabled: n,
|
|
2404
|
-
className: i,
|
|
2405
|
-
style: l,
|
|
2406
|
-
indent: d,
|
|
2407
|
-
labelProps: {
|
|
2408
|
-
style: {
|
|
2409
|
-
marginBottom: ".25em"
|
|
2410
|
-
}
|
|
2411
|
-
},
|
|
2412
|
-
children: ({ value: m, onChange: f, name: y, error: g }) => {
|
|
2413
|
-
const F = Array.isArray(m) ? m : [], V = (h, w) => {
|
|
2414
|
-
f(w ? [...F, h] : F.filter((E) => E !== h));
|
|
2415
|
-
};
|
|
2416
|
-
return /* @__PURE__ */ x(Se, { children: s ? s.map((h) => /* @__PURE__ */ x(
|
|
2417
|
-
Je,
|
|
2418
|
-
{
|
|
2419
|
-
name: `${y}[]`,
|
|
2420
|
-
checked: F.includes(h.value),
|
|
2421
|
-
onChange: (w) => V(h.value, w.target.checked),
|
|
2422
|
-
label: h.label,
|
|
2423
|
-
disabled: n || h.disabled,
|
|
2424
|
-
error: g
|
|
2425
|
-
},
|
|
2426
|
-
h.value
|
|
2427
|
-
)) : z.Children.map(o, (h) => {
|
|
2428
|
-
if (z.isValidElement(h) && h.type === Je) {
|
|
2429
|
-
const w = h.props.value || h.props.name;
|
|
2430
|
-
return z.cloneElement(h, {
|
|
2431
|
-
name: `${y}[]`,
|
|
2432
|
-
checked: F.includes(w),
|
|
2433
|
-
onChange: (E) => V(w, E.target.checked),
|
|
2434
|
-
error: g || h.props.error,
|
|
2435
|
-
disabled: n || h.props.disabled
|
|
2436
|
-
});
|
|
2437
|
-
}
|
|
2438
|
-
return h;
|
|
2439
|
-
}) });
|
|
2440
|
-
}
|
|
2441
|
-
}
|
|
2442
|
-
);
|
|
2443
|
-
}
|
|
2444
|
-
const Ys = "Hamburger-module__hamburger___Tf4-t", eo = "Hamburger-module__line___gybZM", to = "Hamburger-module__open___gRswh", pe = {
|
|
2346
|
+
const Ys = "Hamburger-module__hamburger___Tf4-t", eo = "Hamburger-module__line___gybZM", to = "Hamburger-module__open___gRswh", _e = {
|
|
2445
2347
|
hamburger: Ys,
|
|
2446
2348
|
line: eo,
|
|
2447
2349
|
open: to
|
|
@@ -2451,12 +2353,11 @@ const Ys = "Hamburger-module__hamburger___Tf4-t", eo = "Hamburger-module__line__
|
|
|
2451
2353
|
visible: t,
|
|
2452
2354
|
border: s
|
|
2453
2355
|
}) => {
|
|
2454
|
-
const o = O()
|
|
2356
|
+
const o = O();
|
|
2455
2357
|
return {
|
|
2456
2358
|
"--hamburger-border-radius": (s == null ? void 0 : s.radius) || o.border.radius,
|
|
2457
2359
|
color: r || "inherit",
|
|
2458
|
-
display: t ? "flex" : "none"
|
|
2459
|
-
...n
|
|
2360
|
+
display: t ? "flex" : "none"
|
|
2460
2361
|
};
|
|
2461
2362
|
}, so = ({
|
|
2462
2363
|
// Color props
|
|
@@ -2474,29 +2375,29 @@ const Ys = "Hamburger-module__hamburger___Tf4-t", eo = "Hamburger-module__line__
|
|
|
2474
2375
|
className: l,
|
|
2475
2376
|
style: d
|
|
2476
2377
|
}) => {
|
|
2477
|
-
const
|
|
2378
|
+
const y = ro({
|
|
2478
2379
|
compact: t,
|
|
2479
2380
|
color: e,
|
|
2480
2381
|
visible: r,
|
|
2481
2382
|
border: n
|
|
2482
|
-
}), f = [
|
|
2383
|
+
}), f = [_e.hamburger, o ? _e.open : "", l].filter(Boolean).join(" ");
|
|
2483
2384
|
return /* @__PURE__ */ K(
|
|
2484
2385
|
"button",
|
|
2485
2386
|
{
|
|
2486
2387
|
ref: s,
|
|
2487
2388
|
className: f,
|
|
2488
2389
|
onClick: () => i(!o),
|
|
2489
|
-
style: { ...
|
|
2390
|
+
style: { ...y, ...d },
|
|
2490
2391
|
"aria-label": "Toggle menu",
|
|
2491
2392
|
"aria-expanded": o,
|
|
2492
2393
|
children: [
|
|
2493
|
-
/* @__PURE__ */
|
|
2494
|
-
/* @__PURE__ */
|
|
2495
|
-
/* @__PURE__ */
|
|
2394
|
+
/* @__PURE__ */ V("div", { className: _e.line }),
|
|
2395
|
+
/* @__PURE__ */ V("div", { className: _e.line }),
|
|
2396
|
+
/* @__PURE__ */ V("div", { className: _e.line })
|
|
2496
2397
|
]
|
|
2497
2398
|
}
|
|
2498
2399
|
);
|
|
2499
|
-
}, oo = "Header-module__header___RUooH", no = "Header-module__container___t68M9",
|
|
2400
|
+
}, oo = "Header-module__header___RUooH", no = "Header-module__container___t68M9", Tt = {
|
|
2500
2401
|
header: oo,
|
|
2501
2402
|
container: no
|
|
2502
2403
|
}, io = ({
|
|
@@ -2509,24 +2410,24 @@ const Ys = "Hamburger-module__hamburger___Tf4-t", eo = "Hamburger-module__line__
|
|
|
2509
2410
|
padding: i,
|
|
2510
2411
|
margin: l,
|
|
2511
2412
|
gap: d,
|
|
2512
|
-
backgroundColor:
|
|
2413
|
+
backgroundColor: y,
|
|
2513
2414
|
color: f
|
|
2514
2415
|
} = {}) => {
|
|
2515
|
-
const
|
|
2416
|
+
const m = O();
|
|
2516
2417
|
return {
|
|
2517
|
-
"--header-max-width": r ||
|
|
2418
|
+
"--header-max-width": r || m.layout.maxWidth,
|
|
2518
2419
|
"--header-min-width": t,
|
|
2519
2420
|
"--header-width": s,
|
|
2520
2421
|
"--header-height": o,
|
|
2521
|
-
"--header-padding": e ? n ||
|
|
2422
|
+
"--header-padding": e ? n || m.layout.paddingSm : i || m.layout.padding,
|
|
2522
2423
|
"--header-margin": l,
|
|
2523
2424
|
"--header-gap": d,
|
|
2524
|
-
backgroundColor:
|
|
2425
|
+
backgroundColor: y,
|
|
2525
2426
|
color: f
|
|
2526
2427
|
};
|
|
2527
|
-
},
|
|
2428
|
+
}, ae = (e) => {
|
|
2528
2429
|
const r = typeof window < "u" && typeof window.matchMedia == "function";
|
|
2529
|
-
return
|
|
2430
|
+
return zr((n) => {
|
|
2530
2431
|
if (!r) return () => {
|
|
2531
2432
|
};
|
|
2532
2433
|
const i = window.matchMedia(e);
|
|
@@ -2544,18 +2445,19 @@ const Ys = "Hamburger-module__hamburger___Tf4-t", eo = "Hamburger-module__line__
|
|
|
2544
2445
|
padding: i,
|
|
2545
2446
|
paddingSm: l,
|
|
2546
2447
|
margin: d,
|
|
2547
|
-
gap:
|
|
2448
|
+
gap: y,
|
|
2548
2449
|
breakpoint: f,
|
|
2450
|
+
fixed: m = !1,
|
|
2549
2451
|
// Content
|
|
2550
|
-
children:
|
|
2452
|
+
children: h,
|
|
2551
2453
|
// Style overrides
|
|
2552
|
-
className:
|
|
2454
|
+
className: x,
|
|
2553
2455
|
style: F,
|
|
2554
2456
|
// Element-specific props
|
|
2555
|
-
headerProps:
|
|
2457
|
+
headerProps: _
|
|
2556
2458
|
}) => {
|
|
2557
|
-
const
|
|
2558
|
-
isSmallScreen:
|
|
2459
|
+
const C = O(), A = f || C.breakpoints.sm, { maxWidth: S, unit: z } = Ee(A), k = ae(`(max-width: ${S}${z})`), E = io({
|
|
2460
|
+
isSmallScreen: k,
|
|
2559
2461
|
maxWidth: t,
|
|
2560
2462
|
minWidth: s,
|
|
2561
2463
|
width: o,
|
|
@@ -2563,24 +2465,24 @@ const Ys = "Hamburger-module__hamburger___Tf4-t", eo = "Hamburger-module__line__
|
|
|
2563
2465
|
paddingSm: l,
|
|
2564
2466
|
padding: i,
|
|
2565
2467
|
margin: d,
|
|
2566
|
-
gap:
|
|
2468
|
+
gap: y,
|
|
2567
2469
|
backgroundColor: e,
|
|
2568
2470
|
color: r
|
|
2569
|
-
}),
|
|
2570
|
-
return /* @__PURE__ */
|
|
2471
|
+
}), H = [Tt.container, x].filter(Boolean).join(" "), M = m ? { position: "fixed", top: 0, left: 0, right: 0, zIndex: 1e3 } : {};
|
|
2472
|
+
return /* @__PURE__ */ V("header", { ..._, className: Tt.header, style: M, children: /* @__PURE__ */ V(
|
|
2571
2473
|
"div",
|
|
2572
2474
|
{
|
|
2573
|
-
className:
|
|
2574
|
-
style: { ...
|
|
2575
|
-
children:
|
|
2475
|
+
className: H,
|
|
2476
|
+
style: { ...E, ...F },
|
|
2477
|
+
children: h
|
|
2576
2478
|
}
|
|
2577
2479
|
) });
|
|
2578
|
-
}, lo = "ResponsiveNav-module__nav___xOfv5", co = "ResponsiveNav-module__navMobile___h795P", uo = "ResponsiveNav-module__open___WDCAf", fo = "ResponsiveNav-module__navDesktop___9wscZ",
|
|
2480
|
+
}, lo = "ResponsiveNav-module__nav___xOfv5", co = "ResponsiveNav-module__navMobile___h795P", uo = "ResponsiveNav-module__open___WDCAf", fo = "ResponsiveNav-module__navDesktop___9wscZ", ze = {
|
|
2579
2481
|
nav: lo,
|
|
2580
2482
|
navMobile: co,
|
|
2581
2483
|
open: uo,
|
|
2582
2484
|
navDesktop: fo
|
|
2583
|
-
},
|
|
2485
|
+
}, yo = ({
|
|
2584
2486
|
isMobile: e,
|
|
2585
2487
|
isCompact: r,
|
|
2586
2488
|
mobileBackground: t,
|
|
@@ -2590,7 +2492,7 @@ const Ys = "Hamburger-module__hamburger___Tf4-t", eo = "Hamburger-module__line__
|
|
|
2590
2492
|
mobileButtonHoverColor: i
|
|
2591
2493
|
}) => {
|
|
2592
2494
|
const l = O();
|
|
2593
|
-
return
|
|
2495
|
+
return De(() => {
|
|
2594
2496
|
const { rhythm: d } = l.fonts;
|
|
2595
2497
|
return {
|
|
2596
2498
|
...e ? {
|
|
@@ -2616,7 +2518,7 @@ const Ys = "Hamburger-module__hamburger___Tf4-t", eo = "Hamburger-module__line__
|
|
|
2616
2518
|
e,
|
|
2617
2519
|
r
|
|
2618
2520
|
]);
|
|
2619
|
-
},
|
|
2521
|
+
}, Ko = ({
|
|
2620
2522
|
// Color props
|
|
2621
2523
|
mobileBackground: e,
|
|
2622
2524
|
mobileColor: r,
|
|
@@ -2631,54 +2533,58 @@ const Ys = "Hamburger-module__hamburger___Tf4-t", eo = "Hamburger-module__line__
|
|
|
2631
2533
|
className: l,
|
|
2632
2534
|
style: d,
|
|
2633
2535
|
// Element-specific props
|
|
2634
|
-
navProps:
|
|
2536
|
+
navProps: y
|
|
2635
2537
|
}) => {
|
|
2636
|
-
const [f,
|
|
2637
|
-
isMobile:
|
|
2638
|
-
isCompact:
|
|
2538
|
+
const [f, m] = tt(!1), h = St(null), x = St(null), _ = { ...O().breakpoints, ...n }, { maxWidth: C, unit: A } = Ee(_.md), { maxWidth: S, unit: z } = Ee(_.sm), k = ae(`(max-width: ${C}${A})`), E = ae(`(max-width: ${S}${z})`), H = yo({
|
|
2539
|
+
isMobile: k,
|
|
2540
|
+
isCompact: E,
|
|
2639
2541
|
mobileBackground: e,
|
|
2640
2542
|
mobileColor: r,
|
|
2641
2543
|
mobileActiveBackground: t,
|
|
2642
2544
|
mobileActiveColor: s,
|
|
2643
2545
|
mobileButtonHoverColor: o
|
|
2644
2546
|
});
|
|
2645
|
-
|
|
2646
|
-
const
|
|
2647
|
-
!
|
|
2547
|
+
Wt(() => {
|
|
2548
|
+
const j = (te) => {
|
|
2549
|
+
!x.current || x.current.contains(te.target) || h.current && h.current.contains(te.target) || m(!1);
|
|
2648
2550
|
};
|
|
2649
|
-
return document.addEventListener("mousedown",
|
|
2650
|
-
document.removeEventListener("mousedown",
|
|
2551
|
+
return document.addEventListener("mousedown", j), () => {
|
|
2552
|
+
document.removeEventListener("mousedown", j);
|
|
2651
2553
|
};
|
|
2652
|
-
}, [
|
|
2653
|
-
const
|
|
2654
|
-
|
|
2655
|
-
|
|
2656
|
-
|
|
2554
|
+
}, [h, x, m]);
|
|
2555
|
+
const M = [
|
|
2556
|
+
ze.nav,
|
|
2557
|
+
k ? ze.navMobile : ze.navDesktop,
|
|
2558
|
+
k && f ? ze.open : "",
|
|
2657
2559
|
l
|
|
2658
|
-
].filter(Boolean).join(" ")
|
|
2659
|
-
|
|
2660
|
-
|
|
2560
|
+
].filter(Boolean).join(" "), ee = (j) => {
|
|
2561
|
+
if (!k) return;
|
|
2562
|
+
j.target.closest("a, button") && m(!1);
|
|
2563
|
+
};
|
|
2564
|
+
return /* @__PURE__ */ K(et, { children: [
|
|
2565
|
+
/* @__PURE__ */ V(
|
|
2661
2566
|
so,
|
|
2662
2567
|
{
|
|
2663
|
-
hamburgerRef:
|
|
2664
|
-
visible:
|
|
2665
|
-
compact:
|
|
2568
|
+
hamburgerRef: h,
|
|
2569
|
+
visible: k,
|
|
2570
|
+
compact: E,
|
|
2666
2571
|
open: f,
|
|
2667
|
-
setOpen:
|
|
2572
|
+
setOpen: m
|
|
2668
2573
|
}
|
|
2669
2574
|
),
|
|
2670
|
-
/* @__PURE__ */
|
|
2575
|
+
/* @__PURE__ */ V(
|
|
2671
2576
|
"nav",
|
|
2672
2577
|
{
|
|
2673
|
-
...
|
|
2674
|
-
ref:
|
|
2675
|
-
className:
|
|
2676
|
-
style: { ...
|
|
2677
|
-
|
|
2578
|
+
...y,
|
|
2579
|
+
ref: x,
|
|
2580
|
+
className: M,
|
|
2581
|
+
style: { ...H, ...d },
|
|
2582
|
+
onClickCapture: ee,
|
|
2583
|
+
children: typeof i == "function" ? i({ setOpen: m }) : i
|
|
2678
2584
|
}
|
|
2679
2585
|
)
|
|
2680
2586
|
] });
|
|
2681
|
-
},
|
|
2587
|
+
}, mo = ({
|
|
2682
2588
|
// Color props
|
|
2683
2589
|
color: e,
|
|
2684
2590
|
backgroundColor: r,
|
|
@@ -2690,7 +2596,7 @@ const Ys = "Hamburger-module__hamburger___Tf4-t", eo = "Hamburger-module__line__
|
|
|
2690
2596
|
// Element-specific props
|
|
2691
2597
|
divProps: n
|
|
2692
2598
|
}) => {
|
|
2693
|
-
const i = O(), l = e || i.colors.primary, d = r || i.colors.secondary,
|
|
2599
|
+
const i = O(), l = e || i.colors.primary, d = r || i.colors.secondary, y = /* @__PURE__ */ V(
|
|
2694
2600
|
"div",
|
|
2695
2601
|
{
|
|
2696
2602
|
...t ? void 0 : n,
|
|
@@ -2709,16 +2615,16 @@ const Ys = "Hamburger-module__hamburger___Tf4-t", eo = "Hamburger-module__line__
|
|
|
2709
2615
|
borderTop: `0.1em solid ${d}`
|
|
2710
2616
|
}
|
|
2711
2617
|
}
|
|
2712
|
-
), f = /* @__PURE__ */ K(
|
|
2713
|
-
|
|
2714
|
-
/* @__PURE__ */
|
|
2618
|
+
), f = /* @__PURE__ */ K(et, { children: [
|
|
2619
|
+
y,
|
|
2620
|
+
/* @__PURE__ */ V("style", { children: `
|
|
2715
2621
|
@keyframes spin {
|
|
2716
2622
|
0% { transform: rotate(0deg); }
|
|
2717
2623
|
100% { transform: rotate(360deg); }
|
|
2718
2624
|
}
|
|
2719
2625
|
` })
|
|
2720
2626
|
] });
|
|
2721
|
-
return t ? /* @__PURE__ */
|
|
2627
|
+
return t ? /* @__PURE__ */ V(
|
|
2722
2628
|
"div",
|
|
2723
2629
|
{
|
|
2724
2630
|
...n,
|
|
@@ -2735,18 +2641,18 @@ const Ys = "Hamburger-module__hamburger___Tf4-t", eo = "Hamburger-module__line__
|
|
|
2735
2641
|
children: f
|
|
2736
2642
|
}
|
|
2737
2643
|
) : f;
|
|
2738
|
-
},
|
|
2739
|
-
const [t, s] =
|
|
2740
|
-
return
|
|
2644
|
+
}, Jo = ({ children: e, loadingComponent: r }) => {
|
|
2645
|
+
const [t, s] = tt(!1);
|
|
2646
|
+
return Wt(() => {
|
|
2741
2647
|
requestAnimationFrame(() => {
|
|
2742
2648
|
s(!0);
|
|
2743
2649
|
});
|
|
2744
|
-
}, []), t ? /* @__PURE__ */
|
|
2745
|
-
}, ho = "Stack-module__stack___yUU-B", go = "Stack-module__vertical___sKTyQ", _o = "Stack-module__horizontal___YsvtV",
|
|
2650
|
+
}, []), t ? /* @__PURE__ */ V(et, { children: e }) : r || /* @__PURE__ */ V(mo, {});
|
|
2651
|
+
}, ho = "Stack-module__stack___yUU-B", go = "Stack-module__vertical___sKTyQ", _o = "Stack-module__horizontal___YsvtV", Ge = {
|
|
2746
2652
|
stack: ho,
|
|
2747
2653
|
vertical: go,
|
|
2748
2654
|
horizontal: _o
|
|
2749
|
-
},
|
|
2655
|
+
}, Xo = ({
|
|
2750
2656
|
// Layout props
|
|
2751
2657
|
direction: e = "column",
|
|
2752
2658
|
// Content
|
|
@@ -2758,15 +2664,15 @@ const Ys = "Hamburger-module__hamburger___Tf4-t", eo = "Hamburger-module__line__
|
|
|
2758
2664
|
divProps: o
|
|
2759
2665
|
}) => {
|
|
2760
2666
|
const n = [
|
|
2761
|
-
|
|
2762
|
-
e === "row" ?
|
|
2667
|
+
Ge.stack,
|
|
2668
|
+
e === "row" ? Ge.horizontal : Ge.vertical,
|
|
2763
2669
|
t
|
|
2764
2670
|
].filter(Boolean).join(" ");
|
|
2765
|
-
return /* @__PURE__ */
|
|
2766
|
-
}, po = "ResponsiveSection-module__section___gBESK", vo = "ResponsiveSection-module__innerDiv___r1bky",
|
|
2671
|
+
return /* @__PURE__ */ V("div", { ...o, className: n, style: s, children: r });
|
|
2672
|
+
}, po = "ResponsiveSection-module__section___gBESK", vo = "ResponsiveSection-module__innerDiv___r1bky", Mt = {
|
|
2767
2673
|
section: po,
|
|
2768
2674
|
innerDiv: vo
|
|
2769
|
-
},
|
|
2675
|
+
}, mr = ({
|
|
2770
2676
|
// Color props
|
|
2771
2677
|
backgroundColor: e,
|
|
2772
2678
|
color: r,
|
|
@@ -2778,39 +2684,39 @@ const Ys = "Hamburger-module__hamburger___Tf4-t", eo = "Hamburger-module__line__
|
|
|
2778
2684
|
padding: i,
|
|
2779
2685
|
paddingSm: l,
|
|
2780
2686
|
margin: d,
|
|
2781
|
-
gap:
|
|
2687
|
+
gap: y,
|
|
2782
2688
|
verticalRhythm: f = 3,
|
|
2783
2689
|
// Content
|
|
2784
|
-
children:
|
|
2690
|
+
children: m,
|
|
2785
2691
|
// Style overrides
|
|
2786
|
-
className:
|
|
2787
|
-
style:
|
|
2692
|
+
className: h,
|
|
2693
|
+
style: x,
|
|
2788
2694
|
// Element-specific props
|
|
2789
|
-
sectionProps:
|
|
2695
|
+
sectionProps: F
|
|
2790
2696
|
}) => {
|
|
2791
|
-
const
|
|
2697
|
+
const _ = O(), C = ae(`(min-width: ${_.breakpoints.sm})`), A = {
|
|
2792
2698
|
backgroundColor: e,
|
|
2793
|
-
color: r ||
|
|
2699
|
+
color: r || _.fonts.color,
|
|
2794
2700
|
margin: d,
|
|
2795
|
-
...
|
|
2701
|
+
...x
|
|
2796
2702
|
// Top level style prop overrides
|
|
2797
|
-
}, S = `calc(${
|
|
2798
|
-
"--max-width": t ||
|
|
2703
|
+
}, S = `calc(${_.fonts.rhythm} * ${f})`, z = C ? i || _.layout.padding : l || _.layout.paddingSm, k = {
|
|
2704
|
+
"--max-width": t || _.layout.maxWidth,
|
|
2799
2705
|
"--min-width": s,
|
|
2800
2706
|
"--width": o,
|
|
2801
2707
|
"--height": n,
|
|
2802
|
-
"--section-padding": `${S} ${
|
|
2803
|
-
"--gap":
|
|
2804
|
-
},
|
|
2805
|
-
return /* @__PURE__ */
|
|
2806
|
-
}, bo = "Hero-module__hero___IB2tg", So = "Hero-module__content___rkkfQ",
|
|
2708
|
+
"--section-padding": `${S} ${z}`,
|
|
2709
|
+
"--gap": y
|
|
2710
|
+
}, E = [Mt.section, h].filter(Boolean).join(" ");
|
|
2711
|
+
return /* @__PURE__ */ V("section", { ...F, className: E, style: A, children: /* @__PURE__ */ V("div", { className: Mt.innerDiv, style: k, children: m }) });
|
|
2712
|
+
}, bo = "Hero-module__hero___IB2tg", So = "Hero-module__content___rkkfQ", jt = {
|
|
2807
2713
|
hero: bo,
|
|
2808
2714
|
content: So
|
|
2809
|
-
},
|
|
2715
|
+
}, xo = ({
|
|
2810
2716
|
isMd: e = !1,
|
|
2811
2717
|
isLg: r = !1,
|
|
2812
2718
|
theme: t
|
|
2813
|
-
}) =>
|
|
2719
|
+
}) => De(() => {
|
|
2814
2720
|
const { rhythm: s } = t.fonts;
|
|
2815
2721
|
let o = `calc(${s} * 2) 0`, n = "2rem", i = "1.125rem";
|
|
2816
2722
|
return r ? (o = `calc(${s} * 4) 0`, n = "3.5rem", i = "1.5rem") : e && (o = `calc(${s} * 3.5) 0`, n = "3rem", i = "1.25rem"), {
|
|
@@ -2819,7 +2725,7 @@ const Ys = "Hamburger-module__hamburger___Tf4-t", eo = "Hamburger-module__line__
|
|
|
2819
2725
|
"--hero-p-font-size": i,
|
|
2820
2726
|
"--hero-h1-margin-bottom": `calc(${s} * 0.7)`
|
|
2821
2727
|
};
|
|
2822
|
-
}, [e, r, t.fonts]),
|
|
2728
|
+
}, [e, r, t.fonts]), Yo = ({
|
|
2823
2729
|
// Color props
|
|
2824
2730
|
color: e,
|
|
2825
2731
|
// Layout props
|
|
@@ -2831,19 +2737,19 @@ const Ys = "Hamburger-module__hamburger___Tf4-t", eo = "Hamburger-module__line__
|
|
|
2831
2737
|
style: o,
|
|
2832
2738
|
...n
|
|
2833
2739
|
}) => {
|
|
2834
|
-
const i = O(), l = [
|
|
2835
|
-
return /* @__PURE__ */
|
|
2836
|
-
|
|
2740
|
+
const i = O(), l = [jt.hero, s].filter(Boolean).join(" "), d = (r == null ? void 0 : r.md) || i.breakpoints.md, y = (r == null ? void 0 : r.lg) || i.breakpoints.lg, f = ae(`(min-width: ${d})`), m = ae(`(min-width: ${y})`), h = xo({ isMd: f, isLg: m, theme: i });
|
|
2741
|
+
return /* @__PURE__ */ V(
|
|
2742
|
+
mr,
|
|
2837
2743
|
{
|
|
2838
2744
|
className: l,
|
|
2839
2745
|
color: e || i.fonts.color,
|
|
2840
|
-
style: { ...
|
|
2746
|
+
style: { ...h, ...o },
|
|
2841
2747
|
...n,
|
|
2842
|
-
children: /* @__PURE__ */
|
|
2748
|
+
children: /* @__PURE__ */ V("div", { className: jt.content, children: t })
|
|
2843
2749
|
}
|
|
2844
2750
|
);
|
|
2845
|
-
},
|
|
2846
|
-
footer:
|
|
2751
|
+
}, Fo = "Footer-module__footer___A76NF", Vo = "Footer-module__container___QneNs", It = {
|
|
2752
|
+
footer: Fo,
|
|
2847
2753
|
container: Vo
|
|
2848
2754
|
}, wo = ({
|
|
2849
2755
|
isSmallScreen: e = !1,
|
|
@@ -2855,20 +2761,20 @@ const Ys = "Hamburger-module__hamburger___Tf4-t", eo = "Hamburger-module__line__
|
|
|
2855
2761
|
padding: i,
|
|
2856
2762
|
margin: l,
|
|
2857
2763
|
gap: d,
|
|
2858
|
-
backgroundColor:
|
|
2764
|
+
backgroundColor: y,
|
|
2859
2765
|
color: f
|
|
2860
2766
|
} = {}) => {
|
|
2861
|
-
const
|
|
2767
|
+
const m = O();
|
|
2862
2768
|
return {
|
|
2863
|
-
maxWidth: r ||
|
|
2769
|
+
maxWidth: r || m.layout.maxWidth,
|
|
2864
2770
|
minWidth: t,
|
|
2865
2771
|
width: s,
|
|
2866
2772
|
height: o,
|
|
2867
|
-
padding: e ? n ||
|
|
2773
|
+
padding: e ? n || m.layout.paddingSm : i || m.layout.padding,
|
|
2868
2774
|
margin: l,
|
|
2869
2775
|
gap: d,
|
|
2870
|
-
backgroundColor:
|
|
2871
|
-
color: f ||
|
|
2776
|
+
backgroundColor: y,
|
|
2777
|
+
color: f || m.fonts.color
|
|
2872
2778
|
};
|
|
2873
2779
|
}, ko = ({
|
|
2874
2780
|
// Color props
|
|
@@ -2882,18 +2788,18 @@ const Ys = "Hamburger-module__hamburger___Tf4-t", eo = "Hamburger-module__line__
|
|
|
2882
2788
|
padding: i,
|
|
2883
2789
|
paddingSm: l,
|
|
2884
2790
|
margin: d,
|
|
2885
|
-
gap:
|
|
2791
|
+
gap: y,
|
|
2886
2792
|
breakPoint: f,
|
|
2887
2793
|
// Content
|
|
2888
|
-
children:
|
|
2794
|
+
children: m,
|
|
2889
2795
|
// Style overrides
|
|
2890
|
-
className:
|
|
2891
|
-
style:
|
|
2796
|
+
className: h,
|
|
2797
|
+
style: x,
|
|
2892
2798
|
// Element-specific props
|
|
2893
|
-
footerProps:
|
|
2799
|
+
footerProps: F
|
|
2894
2800
|
}) => {
|
|
2895
|
-
const
|
|
2896
|
-
isSmallScreen:
|
|
2801
|
+
const _ = O(), C = f || _.breakpoints.sm, { maxWidth: A, unit: S } = Ee(C), z = ae(`(max-width: ${A}${S})`), k = wo({
|
|
2802
|
+
isSmallScreen: z,
|
|
2897
2803
|
maxWidth: t,
|
|
2898
2804
|
minWidth: s,
|
|
2899
2805
|
width: o,
|
|
@@ -2901,12 +2807,12 @@ const Ys = "Hamburger-module__hamburger___Tf4-t", eo = "Hamburger-module__line__
|
|
|
2901
2807
|
paddingSm: l,
|
|
2902
2808
|
padding: i,
|
|
2903
2809
|
margin: d,
|
|
2904
|
-
gap:
|
|
2810
|
+
gap: y,
|
|
2905
2811
|
backgroundColor: e,
|
|
2906
2812
|
color: r
|
|
2907
|
-
}),
|
|
2908
|
-
return /* @__PURE__ */
|
|
2909
|
-
}, Co = "FeatureCard-module__card___XQt66", zo = "FeatureCard-module__icon___dXJ92", $o = "FeatureCard-module__title___KxXyA", Eo = "FeatureCard-module__content___68xkw",
|
|
2813
|
+
}), E = [It.container, h].filter(Boolean).join(" ");
|
|
2814
|
+
return /* @__PURE__ */ V("footer", { ...F, className: It.footer, children: /* @__PURE__ */ V("div", { className: E, style: { ...k, ...x }, children: m }) });
|
|
2815
|
+
}, Co = "FeatureCard-module__card___XQt66", zo = "FeatureCard-module__icon___dXJ92", $o = "FeatureCard-module__title___KxXyA", Eo = "FeatureCard-module__content___68xkw", $e = {
|
|
2910
2816
|
card: Co,
|
|
2911
2817
|
icon: zo,
|
|
2912
2818
|
title: $o,
|
|
@@ -2914,7 +2820,7 @@ const Ys = "Hamburger-module__hamburger___Tf4-t", eo = "Hamburger-module__line__
|
|
|
2914
2820
|
}, Ao = ({
|
|
2915
2821
|
isMd: e = !1,
|
|
2916
2822
|
theme: r
|
|
2917
|
-
}) =>
|
|
2823
|
+
}) => De(() => {
|
|
2918
2824
|
const { rhythm: t } = r.fonts;
|
|
2919
2825
|
return {
|
|
2920
2826
|
"--feature-icon-font-size": e ? "3rem" : "2.5rem",
|
|
@@ -2923,7 +2829,7 @@ const Ys = "Hamburger-module__hamburger___Tf4-t", eo = "Hamburger-module__line__
|
|
|
2923
2829
|
"--feature-icon-margin-bottom": `calc(${t} * 0.7)`,
|
|
2924
2830
|
"--feature-title-margin-bottom": `calc(${t} * 0.5)`
|
|
2925
2831
|
};
|
|
2926
|
-
}, [e, r.fonts]),
|
|
2832
|
+
}, [e, r.fonts]), en = ({
|
|
2927
2833
|
// Layout props
|
|
2928
2834
|
breakpoint: e,
|
|
2929
2835
|
// Content
|
|
@@ -2936,28 +2842,28 @@ const Ys = "Hamburger-module__hamburger___Tf4-t", eo = "Hamburger-module__line__
|
|
|
2936
2842
|
// Element-specific props
|
|
2937
2843
|
divProps: i
|
|
2938
2844
|
}) => {
|
|
2939
|
-
const l = O(), d = [
|
|
2845
|
+
const l = O(), d = [$e.card, o].filter(Boolean).join(" "), y = e || l.breakpoints.md, f = ae(`(min-width: ${y})`), m = Ao({ isMd: f, theme: l });
|
|
2940
2846
|
return /* @__PURE__ */ K(
|
|
2941
2847
|
"div",
|
|
2942
2848
|
{
|
|
2943
2849
|
...i,
|
|
2944
2850
|
className: d,
|
|
2945
|
-
style: { ...
|
|
2851
|
+
style: { ...m, ...n },
|
|
2946
2852
|
children: [
|
|
2947
|
-
r && /* @__PURE__ */
|
|
2948
|
-
/* @__PURE__ */
|
|
2949
|
-
/* @__PURE__ */
|
|
2853
|
+
r && /* @__PURE__ */ V("div", { className: $e.icon, children: r }),
|
|
2854
|
+
/* @__PURE__ */ V("h3", { className: $e.title, children: t }),
|
|
2855
|
+
/* @__PURE__ */ V("div", { className: $e.content, children: s })
|
|
2950
2856
|
]
|
|
2951
2857
|
}
|
|
2952
2858
|
);
|
|
2953
|
-
}, No = "FeatureGridSection-module__section___wZrbC", Ro = "FeatureGridSection-module__grid___iwPJv",
|
|
2859
|
+
}, No = "FeatureGridSection-module__section___wZrbC", Ro = "FeatureGridSection-module__grid___iwPJv", Ut = {
|
|
2954
2860
|
section: No,
|
|
2955
2861
|
grid: Ro
|
|
2956
2862
|
}, Do = ({
|
|
2957
2863
|
columns: e,
|
|
2958
2864
|
isMd: r = !1,
|
|
2959
2865
|
isLg: t = !1
|
|
2960
|
-
}) =>
|
|
2866
|
+
}) => De(() => r ? r && !t && (e === 3 || e === 4) ? {
|
|
2961
2867
|
"--grid-template-columns": "repeat(2, 1fr)"
|
|
2962
2868
|
} : {
|
|
2963
2869
|
"--grid-template-columns": {
|
|
@@ -2968,7 +2874,7 @@ const Ys = "Hamburger-module__hamburger___Tf4-t", eo = "Hamburger-module__line__
|
|
|
2968
2874
|
}[e]
|
|
2969
2875
|
} : {
|
|
2970
2876
|
"--grid-template-columns": "1fr"
|
|
2971
|
-
}, [e, r, t]),
|
|
2877
|
+
}, [e, r, t]), tn = ({
|
|
2972
2878
|
// Layout props
|
|
2973
2879
|
columns: e = 3,
|
|
2974
2880
|
breakpoints: r,
|
|
@@ -2980,19 +2886,19 @@ const Ys = "Hamburger-module__hamburger___Tf4-t", eo = "Hamburger-module__line__
|
|
|
2980
2886
|
style: n,
|
|
2981
2887
|
...i
|
|
2982
2888
|
}) => {
|
|
2983
|
-
const l = O(), d = [
|
|
2889
|
+
const l = O(), d = [Ut.section, o].filter(Boolean).join(" "), y = (r == null ? void 0 : r.md) || l.breakpoints.md, f = (r == null ? void 0 : r.lg) || l.breakpoints.lg, m = ae(`(min-width: ${y})`), h = ae(`(min-width: ${f})`), x = Do({ columns: e, isMd: m, isLg: h }), F = {
|
|
2984
2890
|
"--section-padding-vertical": `calc(${l.fonts.rhythm} * 2)`
|
|
2985
|
-
},
|
|
2986
|
-
...
|
|
2891
|
+
}, _ = {
|
|
2892
|
+
...x,
|
|
2987
2893
|
gap: t,
|
|
2988
2894
|
...n
|
|
2989
2895
|
};
|
|
2990
|
-
return /* @__PURE__ */
|
|
2991
|
-
}, Po = "PageLayout-module__layoutContainer___diLdT", Lo = "PageLayout-module__content___h2mBr", Bo = "PageLayout-module__main___Sw7Pv",
|
|
2896
|
+
return /* @__PURE__ */ V(mr, { className: d, style: F, ...i, children: /* @__PURE__ */ V("div", { className: Ut.grid, style: _, children: s }) });
|
|
2897
|
+
}, Po = "PageLayout-module__layoutContainer___diLdT", Lo = "PageLayout-module__content___h2mBr", Bo = "PageLayout-module__main___Sw7Pv", Ze = {
|
|
2992
2898
|
layoutContainer: Po,
|
|
2993
2899
|
content: Lo,
|
|
2994
2900
|
main: Bo
|
|
2995
|
-
},
|
|
2901
|
+
}, rn = ({
|
|
2996
2902
|
// Content
|
|
2997
2903
|
header: e,
|
|
2998
2904
|
footer: r,
|
|
@@ -3004,49 +2910,47 @@ const Ys = "Hamburger-module__hamburger___Tf4-t", eo = "Hamburger-module__line__
|
|
|
3004
2910
|
divProps: n,
|
|
3005
2911
|
mainProps: i
|
|
3006
2912
|
}) => {
|
|
3007
|
-
const l = [
|
|
2913
|
+
const l = [Ze.layoutContainer, s].filter(Boolean).join(" ");
|
|
3008
2914
|
return /* @__PURE__ */ K("div", { ...n, className: l, style: o, children: [
|
|
3009
|
-
/* @__PURE__ */ K("div", { className:
|
|
3010
|
-
e && /* @__PURE__ */
|
|
3011
|
-
/* @__PURE__ */
|
|
2915
|
+
/* @__PURE__ */ K("div", { className: Ze.content, children: [
|
|
2916
|
+
e && /* @__PURE__ */ V(ao, { children: e }),
|
|
2917
|
+
/* @__PURE__ */ V("main", { ...i, className: Ze.main, children: t })
|
|
3012
2918
|
] }),
|
|
3013
|
-
r && /* @__PURE__ */
|
|
2919
|
+
r && /* @__PURE__ */ V(ko, { children: r })
|
|
3014
2920
|
] });
|
|
3015
2921
|
};
|
|
3016
2922
|
export {
|
|
3017
2923
|
jo as Button,
|
|
3018
2924
|
Io as CSSReset,
|
|
3019
|
-
|
|
3020
|
-
|
|
3021
|
-
|
|
2925
|
+
Ir as Checkbox,
|
|
2926
|
+
en as FeatureCard,
|
|
2927
|
+
tn as FeatureGridSection,
|
|
3022
2928
|
ko as Footer,
|
|
3023
2929
|
Uo as Form,
|
|
3024
2930
|
Zo as FormCheckbox,
|
|
3025
|
-
|
|
3026
|
-
|
|
3027
|
-
|
|
3028
|
-
Rs as FormGroup,
|
|
2931
|
+
ks as FormError,
|
|
2932
|
+
Se as FormField,
|
|
2933
|
+
Ns as FormGroup,
|
|
3029
2934
|
Wo as FormInput,
|
|
3030
|
-
|
|
2935
|
+
rt as FormLabel,
|
|
3031
2936
|
Qo as FormRadio,
|
|
3032
|
-
Ko as FormRadioGroup,
|
|
3033
2937
|
Go as FormSelect,
|
|
3034
2938
|
qo as FormTextarea,
|
|
3035
2939
|
so as Hamburger,
|
|
3036
2940
|
ao as Header,
|
|
3037
|
-
|
|
3038
|
-
|
|
3039
|
-
|
|
3040
|
-
|
|
3041
|
-
|
|
3042
|
-
|
|
3043
|
-
|
|
3044
|
-
|
|
3045
|
-
|
|
3046
|
-
|
|
3047
|
-
|
|
2941
|
+
Yo as Hero,
|
|
2942
|
+
Bs as Input,
|
|
2943
|
+
mo as LoadingSpinner,
|
|
2944
|
+
rn as PageLayout,
|
|
2945
|
+
Xs as Radio,
|
|
2946
|
+
Ko as ResponsiveNav,
|
|
2947
|
+
mr as ResponsiveSection,
|
|
2948
|
+
Gs as Select,
|
|
2949
|
+
Xo as Stack,
|
|
2950
|
+
Jo as StyleLoader,
|
|
2951
|
+
js as Textarea,
|
|
3048
2952
|
Mo as ThemeProvider,
|
|
3049
|
-
|
|
2953
|
+
Ee as parseBreakpoint,
|
|
3050
2954
|
xs as useFormContext,
|
|
3051
2955
|
O as useTheme
|
|
3052
2956
|
};
|