diff options
author | href <href@random.sh> | 2021-09-03 04:02:43 +0200 |
---|---|---|
committer | href <href@random.sh> | 2021-09-03 04:02:43 +0200 |
commit | 5fc45a0e3b144b5e87845d068940afb90c3646a6 (patch) | |
tree | 364e9276a63bd23d8033cdae4a9e3e4d5fd755c1 /priv/static | |
parent | improve puppets, fix uploads (diff) |
assets..
Diffstat (limited to 'priv/static')
-rw-r--r-- | priv/static/assets/alcoolog.js.gz | bin | 44 -> 44 bytes | |||
-rw-r--r-- | priv/static/assets/site.css | 2 | ||||
-rw-r--r-- | priv/static/assets/site.css.br | bin | 4100 -> 7957 bytes | |||
-rw-r--r-- | priv/static/assets/site.css.gz | bin | 4697 -> 9187 bytes | |||
-rw-r--r-- | priv/static/assets/site.js | 33 | ||||
-rw-r--r-- | priv/static/assets/site.js.br | bin | 20930 -> 61103 bytes | |||
-rw-r--r-- | priv/static/assets/site.js.gz | bin | 23492 -> 68949 bytes |
7 files changed, 26 insertions, 9 deletions
diff --git a/priv/static/assets/alcoolog.js.gz b/priv/static/assets/alcoolog.js.gz Binary files differindex 0cd1b70..95c3f94 100644 --- a/priv/static/assets/alcoolog.js.gz +++ b/priv/static/assets/alcoolog.js.gz diff --git a/priv/static/assets/site.css b/priv/static/assets/site.css index 6d25d3f..4753c8b 100644 --- a/priv/static/assets/site.css +++ b/priv/static/assets/site.css @@ -1 +1 @@ -/*! tailwindcss v2.2.9 | MIT License | https://tailwindcss.com*//*! modern-normalize v1.1.0 | MIT License | https://github.com/sindresorhus/modern-normalize */html{-webkit-text-size-adjust:100%;line-height:1.15;-moz-tab-size:4;-o-tab-size:4;tab-size:4}body{font-family:system-ui,-apple-system,Segoe UI,Roboto,Helvetica,Arial,sans-serif,Apple Color Emoji,Segoe UI Emoji;margin:0}hr{color:inherit;height:0}abbr[title]{-webkit-text-decoration:underline dotted;text-decoration:underline dotted}b,strong{font-weight:bolder}code,kbd,pre,samp{font-family:ui-monospace,SFMono-Regular,Consolas,Liberation Mono,Menlo,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}table{border-color:inherit;text-indent:0}button,input,optgroup,select,textarea{font-family:inherit;font-size:100%;line-height:1.15;margin:0}button,select{text-transform:none}[type=button],button{-webkit-appearance:button}legend{padding:0}progress{vertical-align:baseline}summary{display:list-item}blockquote,dd,dl,figure,h1,h2,h3,h4,h5,h6,hr,p,pre{margin:0}button{background-color:transparent;background-image:none}fieldset,ol,ul{margin:0;padding:0}ol,ul{list-style:none}html{font-family:ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica Neue,Arial,Noto Sans,sans-serif,Apple Color Emoji,Segoe UI Emoji,Segoe UI Symbol,Noto Color Emoji;line-height:1.5}body{font-family:inherit;line-height:inherit}*,:after,:before{border:0 solid;box-sizing:border-box}hr{border-top-width:1px}img{border-style:solid}textarea{resize:vertical}input::-moz-placeholder,textarea::-moz-placeholder{color:#a8a29e;opacity:1}input:-ms-input-placeholder,textarea:-ms-input-placeholder{color:#a8a29e;opacity:1}input::placeholder,textarea::placeholder{color:#a8a29e;opacity:1}[role=button],button{cursor:pointer}table{border-collapse:collapse}h1,h2,h3,h4,h5,h6{font-size:inherit;font-weight:inherit}a{color:inherit;text-decoration:inherit}button,input,optgroup,select,textarea{color:inherit;line-height:inherit;padding:0}code,kbd,pre,samp{font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace}audio,canvas,embed,iframe,img,object,svg,video{display:block;vertical-align:middle}img,video{height:auto;max-width:100%}[hidden]{display:none}*,:after,:before{--tw-border-opacity:1;border-color:rgba(231,229,228,var(--tw-border-opacity))}.prose{color:#44403c;max-width:65ch}.prose [class~=lead]{color:#57534e;font-size:1.25em;line-height:1.6;margin-bottom:1.2em;margin-top:1.2em}.prose a{color:#1c1917;font-weight:500;text-decoration:underline}.prose strong{color:#1c1917;font-weight:600}.prose ol[type=A]{--list-counter-style:upper-alpha}.prose ol[type=a]{--list-counter-style:lower-alpha}.prose ol[type=A s]{--list-counter-style:upper-alpha}.prose ol[type=a s]{--list-counter-style:lower-alpha}.prose ol[type=i],.prose ol[type=i s]{--list-counter-style:lower-roman}.prose ol[type="1"]{--list-counter-style:decimal}.prose ol>li{padding-left:1.75em;position:relative}.prose ol>li:before{color:#78716c;content:counter(list-item,var(--list-counter-style,decimal)) ".";font-weight:400;left:0;position:absolute}.prose ul>li{padding-left:1.75em;position:relative}.prose ul>li:before{background-color:#d6d3d1;border-radius:50%;content:"";height:.375em;left:.25em;position:absolute;top:.6875em;width:.375em}.prose hr{border-color:#e7e5e4;border-top-width:1px;margin-bottom:3em;margin-top:3em}.prose blockquote{border-left-color:#e7e5e4;border-left-width:.25rem;color:#1c1917;font-style:italic;font-weight:500;margin-bottom:1.6em;margin-top:1.6em;padding-left:1em;quotes:"\201C""\201D""\2018""\2019"}.prose blockquote p:first-of-type:before{content:open-quote}.prose blockquote p:last-of-type:after{content:close-quote}.prose h1{color:#1c1917;font-size:2.25em;font-weight:800;line-height:1.1111111;margin-bottom:.8888889em;margin-top:0}.prose h2{color:#1c1917;font-size:1.5em;font-weight:700;line-height:1.3333333;margin-bottom:1em;margin-top:2em}.prose h3{color:#1c1917;font-size:1.25em;font-weight:600;line-height:1.6;margin-bottom:.6em;margin-top:1.6em}.prose h4{color:#1c1917;font-weight:600;line-height:1.5;margin-bottom:.5em;margin-top:1.5em}.prose figure figcaption{color:#78716c;font-size:.875em;line-height:1.4285714;margin-top:.8571429em}.prose code{color:#1c1917;font-size:.875em;font-weight:600}.prose code:after,.prose code:before{content:"`"}.prose a code{color:#1c1917}.prose pre{background-color:#292524;border-radius:.375rem;color:#e7e5e4;font-size:.875em;line-height:1.7142857;margin-bottom:1.7142857em;margin-top:1.7142857em;overflow-x:auto;padding:.8571429em 1.1428571em}.prose pre code{background-color:transparent;border-radius:0;border-width:0;color:inherit;font-family:inherit;font-size:inherit;font-weight:400;line-height:inherit;padding:0}.prose pre code:after,.prose pre code:before{content:none}.prose table{font-size:.875em;line-height:1.7142857;margin-bottom:2em;margin-top:2em;table-layout:auto;text-align:left;width:100%}.prose thead{border-bottom-color:#d6d3d1;border-bottom-width:1px;color:#1c1917;font-weight:600}.prose thead th{padding-bottom:.5714286em;padding-left:.5714286em;padding-right:.5714286em;vertical-align:bottom}.prose tbody tr{border-bottom-color:#e7e5e4;border-bottom-width:1px}.prose tbody tr:last-child{border-bottom-width:0}.prose tbody td{padding:.5714286em;vertical-align:top}.prose{font-size:1rem;line-height:1.75}.prose p{margin-bottom:1.25em;margin-top:1.25em}.prose figure,.prose img,.prose video{margin-bottom:2em;margin-top:2em}.prose figure>*{margin-bottom:0;margin-top:0}.prose h2 code{font-size:.875em}.prose h3 code{font-size:.9em}.prose ol,.prose ul{margin-bottom:1.25em;margin-top:1.25em}.prose li{margin-bottom:.5em;margin-top:.5em}.prose>ul>li p{margin-bottom:.75em;margin-top:.75em}.prose>ul>li>:first-child{margin-top:1.25em}.prose>ul>li>:last-child{margin-bottom:1.25em}.prose>ol>li>:first-child{margin-top:1.25em}.prose>ol>li>:last-child{margin-bottom:1.25em}.prose ol ol,.prose ol ul,.prose ul ol,.prose ul ul{margin-bottom:.75em;margin-top:.75em}.prose h2+*,.prose h3+*,.prose h4+*,.prose hr+*{margin-top:0}.prose thead th:first-child{padding-left:0}.prose thead th:last-child{padding-right:0}.prose tbody td:first-child{padding-left:0}.prose tbody td:last-child{padding-right:0}.prose>:first-child{margin-top:0}.prose>:last-child{margin-bottom:0}.prose-lg{font-size:1.125rem;line-height:1.7777778}.prose-lg p{margin-bottom:1.3333333em;margin-top:1.3333333em}.prose-lg [class~=lead]{font-size:1.2222222em;line-height:1.4545455;margin-bottom:1.0909091em;margin-top:1.0909091em}.prose-lg blockquote{margin-bottom:1.6666667em;margin-top:1.6666667em;padding-left:1em}.prose-lg h1{font-size:2.6666667em;line-height:1;margin-bottom:.8333333em;margin-top:0}.prose-lg h2{font-size:1.6666667em;line-height:1.3333333;margin-bottom:1.0666667em;margin-top:1.8666667em}.prose-lg h3{font-size:1.3333333em;line-height:1.5;margin-bottom:.6666667em;margin-top:1.6666667em}.prose-lg h4{line-height:1.5555556;margin-bottom:.4444444em;margin-top:1.7777778em}.prose-lg figure,.prose-lg img,.prose-lg video{margin-bottom:1.7777778em;margin-top:1.7777778em}.prose-lg figure>*{margin-bottom:0;margin-top:0}.prose-lg figure figcaption{font-size:.8888889em;line-height:1.5;margin-top:1em}.prose-lg code{font-size:.8888889em}.prose-lg h2 code{font-size:.8666667em}.prose-lg h3 code{font-size:.875em}.prose-lg pre{border-radius:.375rem;font-size:.8888889em;line-height:1.75;margin-bottom:2em;margin-top:2em;padding:1em 1.5em}.prose-lg ol,.prose-lg ul{margin-bottom:1.3333333em;margin-top:1.3333333em}.prose-lg li{margin-bottom:.6666667em;margin-top:.6666667em}.prose-lg ol>li{padding-left:1.6666667em}.prose-lg ol>li:before{left:0}.prose-lg ul>li{padding-left:1.6666667em}.prose-lg ul>li:before{height:.3333333em;left:.2222222em;top:.72222em;width:.3333333em}.prose-lg>ul>li p{margin-bottom:.8888889em;margin-top:.8888889em}.prose-lg>ul>li>:first-child{margin-top:1.3333333em}.prose-lg>ul>li>:last-child{margin-bottom:1.3333333em}.prose-lg>ol>li>:first-child{margin-top:1.3333333em}.prose-lg>ol>li>:last-child{margin-bottom:1.3333333em}.prose-lg ol ol,.prose-lg ol ul,.prose-lg ul ol,.prose-lg ul ul{margin-bottom:.8888889em;margin-top:.8888889em}.prose-lg hr{margin-bottom:3.1111111em;margin-top:3.1111111em}.prose-lg h2+*,.prose-lg h3+*,.prose-lg h4+*,.prose-lg hr+*{margin-top:0}.prose-lg table{font-size:.8888889em;line-height:1.5}.prose-lg thead th{padding-bottom:.75em;padding-left:.75em;padding-right:.75em}.prose-lg thead th:first-child{padding-left:0}.prose-lg thead th:last-child{padding-right:0}.prose-lg tbody td{padding:.75em}.prose-lg tbody td:first-child{padding-left:0}.prose-lg tbody td:last-child{padding-right:0}.prose-lg>:first-child{margin-top:0}.prose-lg>:last-child{margin-bottom:0}.static{position:static}.absolute{position:absolute}.relative{position:relative}.right-0{right:0}.col-span-1{grid-column:span 1/span 1}.m-4{margin:1rem}.mx-auto{margin-left:auto;margin-right:auto}.-my-2{margin-bottom:-.5rem;margin-top:-.5rem}.mt-1{margin-top:.25rem}.mt-2{margin-top:.5rem}.mt-3{margin-top:.75rem}.mt-12{margin-top:3rem}.mt-24{margin-top:6rem}.-mt-32{margin-top:-8rem}.-mr-2{margin-right:-.5rem}.ml-3{margin-left:.75rem}.ml-4{margin-left:1rem}.ml-10{margin-left:2.5rem}.block{display:block}.inline-block{display:inline-block}.flex{display:flex}.inline-flex{display:inline-flex}.table{display:table}.grid{display:grid}.contents{display:contents}.hidden{display:none}.h-5{height:1.25rem}.h-6{height:1.5rem}.h-8{height:2rem}.h-10{height:2.5rem}.h-16{height:4rem}.w-1{width:.25rem}.w-5{width:1.25rem}.w-6{width:1.5rem}.w-8{width:2rem}.w-10{width:2.5rem}.w-48{width:12rem}.w-auto{width:auto}.w-full{width:100%}.min-w-full{min-width:100%}.max-w-xs{max-width:20rem}.max-w-7xl{max-width:80rem}.max-w-full{max-width:100%}.flex-1{flex:1 1 0%}.flex-shrink-0{flex-shrink:0}.origin-top-right{transform-origin:top right}.transform{--tw-translate-x:0;--tw-translate-y:0;--tw-rotate:0;--tw-skew-x:0;--tw-skew-y:0;--tw-scale-x:1;--tw-scale-y:1;transform:translateX(var(--tw-translate-x)) translateY(var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.scale-95{--tw-scale-x:.95;--tw-scale-y:.95}.scale-100{--tw-scale-x:1;--tw-scale-y:1}@-webkit-keyframes spin{to{transform:rotate(1turn)}}@keyframes spin{to{transform:rotate(1turn)}}@-webkit-keyframes ping{75%,to{opacity:0;transform:scale(2)}}@keyframes ping{75%,to{opacity:0;transform:scale(2)}}@-webkit-keyframes pulse{50%{opacity:.5}}@keyframes pulse{50%{opacity:.5}}@-webkit-keyframes bounce{0%,to{-webkit-animation-timing-function:cubic-bezier(.8,0,1,1);animation-timing-function:cubic-bezier(.8,0,1,1);transform:translateY(-25%)}50%{-webkit-animation-timing-function:cubic-bezier(0,0,.2,1);animation-timing-function:cubic-bezier(0,0,.2,1);transform:none}}@keyframes bounce{0%,to{-webkit-animation-timing-function:cubic-bezier(.8,0,1,1);animation-timing-function:cubic-bezier(.8,0,1,1);transform:translateY(-25%)}50%{-webkit-animation-timing-function:cubic-bezier(0,0,.2,1);animation-timing-function:cubic-bezier(0,0,.2,1);transform:none}}.list-outside{list-style-position:outside}.list-decimal{list-style-type:decimal}.grid-cols-1{grid-template-columns:repeat(1,minmax(0,1fr))}.flex-col{flex-direction:column}.flex-wrap{flex-wrap:wrap}.content-center{align-content:center}.items-center{align-items:center}.items-baseline{align-items:baseline}.justify-center{justify-content:center}.justify-between{justify-content:space-between}.gap-5{gap:1.25rem}.gap-6{gap:1.5rem}.space-x-3>:not([hidden])~:not([hidden]){--tw-space-x-reverse:0;margin-left:calc(.75rem*(1 - var(--tw-space-x-reverse)));margin-right:calc(.75rem*var(--tw-space-x-reverse))}.space-x-6>:not([hidden])~:not([hidden]){--tw-space-x-reverse:0;margin-left:calc(1.5rem*(1 - var(--tw-space-x-reverse)));margin-right:calc(1.5rem*var(--tw-space-x-reverse))}.space-y-3>:not([hidden])~:not([hidden]){--tw-space-y-reverse:0;margin-bottom:calc(.75rem*var(--tw-space-y-reverse));margin-top:calc(.75rem*(1 - var(--tw-space-y-reverse)))}.space-y-6>:not([hidden])~:not([hidden]){--tw-space-y-reverse:0;margin-bottom:calc(1.5rem*var(--tw-space-y-reverse));margin-top:calc(1.5rem*(1 - var(--tw-space-y-reverse)))}.divide-y>:not([hidden])~:not([hidden]){--tw-divide-y-reverse:0;border-bottom-width:calc(1px*var(--tw-divide-y-reverse));border-top-width:calc(1px*(1 - var(--tw-divide-y-reverse)))}.divide-gray-200>:not([hidden])~:not([hidden]){--tw-divide-opacity:1;border-color:rgba(231,229,228,var(--tw-divide-opacity))}.overflow-hidden{overflow:hidden}.overflow-x-auto{overflow-x:auto}.truncate{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.rounded-md{border-radius:.375rem}.rounded-lg{border-radius:.5rem}.rounded-full{border-radius:9999px}.border-2{border-width:2px}.border-t{border-top-width:1px}.border-r{border-right-width:1px}.border-b{border-bottom-width:1px}.border-l{border-left-width:1px}.border-transparent{border-color:transparent}.border-gray-200{--tw-border-opacity:1;border-color:rgba(231,229,228,var(--tw-border-opacity))}.border-gray-700{--tw-border-opacity:1;border-color:rgba(68,64,60,var(--tw-border-opacity))}.bg-white{--tw-bg-opacity:1;background-color:rgba(255,255,255,var(--tw-bg-opacity))}.bg-gray-50{--tw-bg-opacity:1;background-color:rgba(250,250,249,var(--tw-bg-opacity))}.bg-gray-800{--tw-bg-opacity:1;background-color:rgba(41,37,36,var(--tw-bg-opacity))}.bg-gray-900{--tw-bg-opacity:1;background-color:rgba(28,25,23,var(--tw-bg-opacity))}.bg-red-50{--tw-bg-opacity:1;background-color:rgba(255,241,242,var(--tw-bg-opacity))}.hover\:bg-gray-100:hover{--tw-bg-opacity:1;background-color:rgba(245,245,244,var(--tw-bg-opacity))}.focus\:bg-gray-700:focus,.hover\:bg-gray-700:hover{--tw-bg-opacity:1;background-color:rgba(68,64,60,var(--tw-bg-opacity))}.focus\:bg-indigo-50:focus{--tw-bg-opacity:1;background-color:rgba(238,242,255,var(--tw-bg-opacity))}.p-1{padding:.25rem}.p-2{padding:.5rem}.p-4{padding:1rem}.p-6{padding:1.5rem}.px-2{padding-left:.5rem;padding-right:.5rem}.px-3{padding-left:.75rem;padding-right:.75rem}.px-4{padding-left:1rem;padding-right:1rem}.px-5{padding-left:1.25rem;padding-right:1.25rem}.px-6{padding-left:1.5rem;padding-right:1.5rem}.py-0{padding-bottom:0;padding-top:0}.py-1{padding-bottom:.25rem;padding-top:.25rem}.py-2{padding-bottom:.5rem;padding-top:.5rem}.py-3{padding-bottom:.75rem;padding-top:.75rem}.py-4{padding-bottom:1rem;padding-top:1rem}.py-6{padding-bottom:1.5rem;padding-top:1.5rem}.py-10{padding-bottom:2.5rem;padding-top:2.5rem}.py-0\.5{padding-bottom:.125rem;padding-top:.125rem}.pt-4{padding-top:1rem}.pb-3{padding-bottom:.75rem}.pb-12{padding-bottom:3rem}.pb-32{padding-bottom:8rem}.text-left{text-align:left}.text-center{text-align:center}.align-middle{vertical-align:middle}.text-xs{font-size:.75rem;line-height:1rem}.text-sm{font-size:.875rem;line-height:1.25rem}.text-base{font-size:1rem;line-height:1.5rem}.text-lg{font-size:1.125rem;line-height:1.75rem}.text-xl{font-size:1.25rem;line-height:1.75rem}.text-2xl{font-size:1.5rem;line-height:2rem}.text-3xl{font-size:1.875rem;line-height:2.25rem}.font-thin{font-weight:100}.font-medium{font-weight:500}.font-semibold{font-weight:600}.font-bold{font-weight:700}.uppercase{text-transform:uppercase}.leading-4{line-height:1rem}.leading-5{line-height:1.25rem}.leading-8{line-height:2rem}.leading-9{line-height:2.25rem}.leading-none{line-height:1}.leading-loose{line-height:2}.tracking-wide{letter-spacing:.025em}.tracking-wider{letter-spacing:.05em}.text-white{--tw-text-opacity:1;color:rgba(255,255,255,var(--tw-text-opacity))}.text-gray-300{--tw-text-opacity:1;color:rgba(214,211,209,var(--tw-text-opacity))}.text-gray-400{--tw-text-opacity:1;color:rgba(168,162,158,var(--tw-text-opacity))}.text-gray-500{--tw-text-opacity:1;color:rgba(120,113,108,var(--tw-text-opacity))}.text-gray-600{--tw-text-opacity:1;color:rgba(87,83,78,var(--tw-text-opacity))}.text-gray-700{--tw-text-opacity:1;color:rgba(68,64,60,var(--tw-text-opacity))}.text-gray-900{--tw-text-opacity:1;color:rgba(28,25,23,var(--tw-text-opacity))}.text-red-400{--tw-text-opacity:1;color:rgba(251,113,133,var(--tw-text-opacity))}.text-red-800{--tw-text-opacity:1;color:rgba(159,18,57,var(--tw-text-opacity))}.hover\:text-white:hover{--tw-text-opacity:1;color:rgba(255,255,255,var(--tw-text-opacity))}.hover\:text-gray-600:hover{--tw-text-opacity:1;color:rgba(87,83,78,var(--tw-text-opacity))}.hover\:text-gray-700:hover{--tw-text-opacity:1;color:rgba(68,64,60,var(--tw-text-opacity))}.focus\:text-white:focus{--tw-text-opacity:1;color:rgba(255,255,255,var(--tw-text-opacity))}.focus\:text-indigo-600:focus{--tw-text-opacity:1;color:rgba(79,70,229,var(--tw-text-opacity))}.opacity-0{opacity:0}.opacity-100{opacity:1}*,:after,:before{--tw-shadow:0 0 #0000}.shadow-sm{--tw-shadow:0 1px 2px 0 rgba(0,0,0,0.05)}.shadow,.shadow-sm{box-shadow:var(--tw-ring-offset-shadow,0 0 #0000),var(--tw-ring-shadow,0 0 #0000),var(--tw-shadow)}.shadow{--tw-shadow:0 1px 3px 0 rgba(0,0,0,0.1),0 1px 2px 0 rgba(0,0,0,0.06)}.shadow-lg{--tw-shadow:0 10px 15px -3px rgba(0,0,0,0.1),0 4px 6px -2px rgba(0,0,0,0.05);box-shadow:var(--tw-ring-offset-shadow,0 0 #0000),var(--tw-ring-shadow,0 0 #0000),var(--tw-shadow)}.focus\:outline-none:focus{outline:2px solid transparent;outline-offset:2px}*,:after,:before{--tw-ring-inset:var(--tw-empty,/*!*/ /*!*/);--tw-ring-offset-width:0px;--tw-ring-offset-color:#fff;--tw-ring-color:rgba(59,130,246,0.5);--tw-ring-offset-shadow:0 0 #0000;--tw-ring-shadow:0 0 #0000}.filter{--tw-blur:var(--tw-empty,/*!*/ /*!*/);--tw-brightness:var(--tw-empty,/*!*/ /*!*/);--tw-contrast:var(--tw-empty,/*!*/ /*!*/);--tw-grayscale:var(--tw-empty,/*!*/ /*!*/);--tw-hue-rotate:var(--tw-empty,/*!*/ /*!*/);--tw-invert:var(--tw-empty,/*!*/ /*!*/);--tw-saturate:var(--tw-empty,/*!*/ /*!*/);--tw-sepia:var(--tw-empty,/*!*/ /*!*/);--tw-drop-shadow:var(--tw-empty,/*!*/ /*!*/);filter:var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow)}.transition{transition-duration:.15s;transition-property:background-color,border-color,color,fill,stroke,opacity,box-shadow,transform,filter,-webkit-backdrop-filter;transition-property:background-color,border-color,color,fill,stroke,opacity,box-shadow,transform,filter,backdrop-filter;transition-property:background-color,border-color,color,fill,stroke,opacity,box-shadow,transform,filter,backdrop-filter,-webkit-backdrop-filter;transition-timing-function:cubic-bezier(.4,0,.2,1)}.duration-75{transition-duration:75ms}.duration-100{transition-duration:.1s}.duration-150{transition-duration:.15s}.ease-in{transition-timing-function:cubic-bezier(.4,0,1,1)}.ease-out{transition-timing-function:cubic-bezier(0,0,.2,1)}.ease-in-out{transition-timing-function:cubic-bezier(.4,0,.2,1)}@media (min-width:640px){.sm\:-mx-6{margin-left:-1.5rem;margin-right:-1.5rem}.sm\:block{display:block}.sm\:grid-cols-2{grid-template-columns:repeat(2,minmax(0,1fr))}.sm\:grid-cols-4{grid-template-columns:repeat(4,minmax(0,1fr))}.sm\:grid-cols-5{grid-template-columns:repeat(5,minmax(0,1fr))}.sm\:gap-6{gap:1.5rem}.sm\:rounded-lg{border-radius:.5rem}.sm\:px-0{padding-left:0;padding-right:0}.sm\:px-3{padding-left:.75rem;padding-right:.75rem}.sm\:px-6{padding-left:1.5rem;padding-right:1.5rem}}@media (min-width:768px){.md\:ml-6{margin-left:1.5rem}.md\:block{display:block}.md\:hidden{display:none}}@media (min-width:1024px){.lg\:-mx-8{margin-left:-2rem;margin-right:-2rem}.lg\:grid-cols-3{grid-template-columns:repeat(3,minmax(0,1fr))}.lg\:grid-cols-5{grid-template-columns:repeat(5,minmax(0,1fr))}.lg\:grid-cols-6{grid-template-columns:repeat(6,minmax(0,1fr))}.lg\:px-8{padding-left:2rem;padding-right:2rem}}
\ No newline at end of file +/*! tailwindcss v2.2.9 | MIT License | https://tailwindcss.com*//*! modern-normalize v1.1.0 | MIT License | https://github.com/sindresorhus/modern-normalize */html{-webkit-text-size-adjust:100%;line-height:1.15;-moz-tab-size:4;-o-tab-size:4;tab-size:4}body{font-family:system-ui,-apple-system,Segoe UI,Roboto,Helvetica,Arial,sans-serif,Apple Color Emoji,Segoe UI Emoji;margin:0}hr{color:inherit;height:0}abbr[title]{-webkit-text-decoration:underline dotted;text-decoration:underline dotted}b,strong{font-weight:bolder}code,kbd,pre,samp{font-family:ui-monospace,SFMono-Regular,Consolas,Liberation Mono,Menlo,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}table{border-color:inherit;text-indent:0}button,input,optgroup,select,textarea{font-family:inherit;font-size:100%;line-height:1.15;margin:0}button,select{text-transform:none}[type=button],[type=reset],[type=submit],button{-webkit-appearance:button}legend{padding:0}progress{vertical-align:baseline}[type=search]{-webkit-appearance:textfield;outline-offset:-2px}summary{display:list-item}blockquote,dd,dl,figure,h1,h2,h3,h4,h5,h6,hr,p,pre{margin:0}button{background-color:transparent;background-image:none}fieldset,ol,ul{margin:0;padding:0}ol,ul{list-style:none}html{font-family:ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica Neue,Arial,Noto Sans,sans-serif,Apple Color Emoji,Segoe UI Emoji,Segoe UI Symbol,Noto Color Emoji;line-height:1.5}body{font-family:inherit;line-height:inherit}*,:after,:before{border:0 solid;box-sizing:border-box}hr{border-top-width:1px}img{border-style:solid}textarea{resize:vertical}input::-moz-placeholder,textarea::-moz-placeholder{color:#a8a29e;opacity:1}input:-ms-input-placeholder,textarea:-ms-input-placeholder{color:#a8a29e;opacity:1}input::placeholder,textarea::placeholder{color:#a8a29e;opacity:1}[role=button],button{cursor:pointer}table{border-collapse:collapse}h1,h2,h3,h4,h5,h6{font-size:inherit;font-weight:inherit}a{color:inherit;text-decoration:inherit}button,input,optgroup,select,textarea{color:inherit;line-height:inherit;padding:0}code,kbd,pre,samp{font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace}audio,canvas,embed,iframe,img,object,svg,video{display:block;vertical-align:middle}img,video{height:auto;max-width:100%}[hidden]{display:none}*,:after,:before{--tw-border-opacity:1;border-color:rgba(231,229,228,var(--tw-border-opacity))}.container{width:100%}@media (min-width:640px){.container{max-width:640px}}@media (min-width:768px){.container{max-width:768px}}@media (min-width:1024px){.container{max-width:1024px}}@media (min-width:1280px){.container{max-width:1280px}}@media (min-width:1536px){.container{max-width:1536px}}.prose{color:#44403c;max-width:65ch}.prose [class~=lead]{color:#57534e;font-size:1.25em;line-height:1.6;margin-bottom:1.2em;margin-top:1.2em}.prose a{color:#1c1917;font-weight:500;text-decoration:underline}.prose strong{color:#1c1917;font-weight:600}.prose ol[type=A]{--list-counter-style:upper-alpha}.prose ol[type=a]{--list-counter-style:lower-alpha}.prose ol[type=A s]{--list-counter-style:upper-alpha}.prose ol[type=a s]{--list-counter-style:lower-alpha}.prose ol[type=I]{--list-counter-style:upper-roman}.prose ol[type=i]{--list-counter-style:lower-roman}.prose ol[type=I s]{--list-counter-style:upper-roman}.prose ol[type=i s]{--list-counter-style:lower-roman}.prose ol[type="1"]{--list-counter-style:decimal}.prose ol>li{padding-left:1.75em;position:relative}.prose ol>li:before{color:#78716c;content:counter(list-item,var(--list-counter-style,decimal)) ".";font-weight:400;left:0;position:absolute}.prose ul>li{padding-left:1.75em;position:relative}.prose ul>li:before{background-color:#d6d3d1;border-radius:50%;content:"";height:.375em;left:.25em;position:absolute;top:.6875em;width:.375em}.prose hr{border-color:#e7e5e4;border-top-width:1px;margin-bottom:3em;margin-top:3em}.prose blockquote{border-left-color:#e7e5e4;border-left-width:.25rem;color:#1c1917;font-style:italic;font-weight:500;margin-bottom:1.6em;margin-top:1.6em;padding-left:1em;quotes:"\201C""\201D""\2018""\2019"}.prose blockquote p:first-of-type:before{content:open-quote}.prose blockquote p:last-of-type:after{content:close-quote}.prose h1{color:#1c1917;font-size:2.25em;font-weight:800;line-height:1.1111111;margin-bottom:.8888889em;margin-top:0}.prose h2{color:#1c1917;font-size:1.5em;font-weight:700;line-height:1.3333333;margin-bottom:1em;margin-top:2em}.prose h3{color:#1c1917;font-size:1.25em;font-weight:600;line-height:1.6;margin-bottom:.6em;margin-top:1.6em}.prose h4{color:#1c1917;font-weight:600;line-height:1.5;margin-bottom:.5em;margin-top:1.5em}.prose figure figcaption{color:#78716c;font-size:.875em;line-height:1.4285714;margin-top:.8571429em}.prose code{color:#1c1917;font-size:.875em;font-weight:600}.prose code:after,.prose code:before{content:"`"}.prose a code{color:#1c1917}.prose pre{background-color:#292524;border-radius:.375rem;color:#e7e5e4;font-size:.875em;line-height:1.7142857;margin-bottom:1.7142857em;margin-top:1.7142857em;overflow-x:auto;padding:.8571429em 1.1428571em}.prose pre code{background-color:transparent;border-radius:0;border-width:0;color:inherit;font-family:inherit;font-size:inherit;font-weight:400;line-height:inherit;padding:0}.prose pre code:after,.prose pre code:before{content:none}.prose table{font-size:.875em;line-height:1.7142857;margin-bottom:2em;margin-top:2em;table-layout:auto;text-align:left;width:100%}.prose thead{border-bottom-color:#d6d3d1;border-bottom-width:1px;color:#1c1917;font-weight:600}.prose thead th{padding-bottom:.5714286em;padding-left:.5714286em;padding-right:.5714286em;vertical-align:bottom}.prose tbody tr{border-bottom-color:#e7e5e4;border-bottom-width:1px}.prose tbody tr:last-child{border-bottom-width:0}.prose tbody td{padding:.5714286em;vertical-align:top}.prose{font-size:1rem;line-height:1.75}.prose p{margin-bottom:1.25em;margin-top:1.25em}.prose figure,.prose img,.prose video{margin-bottom:2em;margin-top:2em}.prose figure>*{margin-bottom:0;margin-top:0}.prose h2 code{font-size:.875em}.prose h3 code{font-size:.9em}.prose ol,.prose ul{margin-bottom:1.25em;margin-top:1.25em}.prose li{margin-bottom:.5em;margin-top:.5em}.prose>ul>li p{margin-bottom:.75em;margin-top:.75em}.prose>ul>li>:first-child{margin-top:1.25em}.prose>ul>li>:last-child{margin-bottom:1.25em}.prose>ol>li>:first-child{margin-top:1.25em}.prose>ol>li>:last-child{margin-bottom:1.25em}.prose ol ol,.prose ol ul,.prose ul ol,.prose ul ul{margin-bottom:.75em;margin-top:.75em}.prose h2+*,.prose h3+*,.prose h4+*,.prose hr+*{margin-top:0}.prose thead th:first-child{padding-left:0}.prose thead th:last-child{padding-right:0}.prose tbody td:first-child{padding-left:0}.prose tbody td:last-child{padding-right:0}.prose>:first-child{margin-top:0}.prose>:last-child{margin-bottom:0}.prose-sm{font-size:.875rem;line-height:1.7142857}.prose-sm p{margin-bottom:1.1428571em;margin-top:1.1428571em}.prose-sm [class~=lead]{font-size:1.2857143em;line-height:1.5555556;margin-bottom:.8888889em;margin-top:.8888889em}.prose-sm blockquote{margin-bottom:1.3333333em;margin-top:1.3333333em;padding-left:1.1111111em}.prose-sm h1{font-size:2.1428571em;line-height:1.2;margin-bottom:.8em;margin-top:0}.prose-sm h2{font-size:1.4285714em;line-height:1.4;margin-bottom:.8em;margin-top:1.6em}.prose-sm h3{font-size:1.2857143em;line-height:1.5555556;margin-bottom:.4444444em;margin-top:1.5555556em}.prose-sm h4{line-height:1.4285714;margin-bottom:.5714286em;margin-top:1.4285714em}.prose-sm figure,.prose-sm img,.prose-sm video{margin-bottom:1.7142857em;margin-top:1.7142857em}.prose-sm figure>*{margin-bottom:0;margin-top:0}.prose-sm figure figcaption{font-size:.8571429em;line-height:1.3333333;margin-top:.6666667em}.prose-sm code{font-size:.8571429em}.prose-sm h2 code{font-size:.9em}.prose-sm h3 code{font-size:.8888889em}.prose-sm pre{border-radius:.25rem;font-size:.8571429em;line-height:1.6666667;margin-bottom:1.6666667em;margin-top:1.6666667em;padding:.6666667em 1em}.prose-sm ol,.prose-sm ul{margin-bottom:1.1428571em;margin-top:1.1428571em}.prose-sm li{margin-bottom:.2857143em;margin-top:.2857143em}.prose-sm ol>li{padding-left:1.5714286em}.prose-sm ol>li:before{left:0}.prose-sm ul>li{padding-left:1.5714286em}.prose-sm ul>li:before{height:.3571429em;left:.2142857em;top:.67857em;width:.3571429em}.prose-sm>ul>li p{margin-bottom:.5714286em;margin-top:.5714286em}.prose-sm>ul>li>:first-child{margin-top:1.1428571em}.prose-sm>ul>li>:last-child{margin-bottom:1.1428571em}.prose-sm>ol>li>:first-child{margin-top:1.1428571em}.prose-sm>ol>li>:last-child{margin-bottom:1.1428571em}.prose-sm ol ol,.prose-sm ol ul,.prose-sm ul ol,.prose-sm ul ul{margin-bottom:.5714286em;margin-top:.5714286em}.prose-sm hr{margin-bottom:2.8571429em;margin-top:2.8571429em}.prose-sm h2+*,.prose-sm h3+*,.prose-sm h4+*,.prose-sm hr+*{margin-top:0}.prose-sm table{font-size:.8571429em;line-height:1.5}.prose-sm thead th{padding-bottom:.6666667em;padding-left:1em;padding-right:1em}.prose-sm thead th:first-child{padding-left:0}.prose-sm thead th:last-child{padding-right:0}.prose-sm tbody td{padding:.6666667em 1em}.prose-sm tbody td:first-child{padding-left:0}.prose-sm tbody td:last-child{padding-right:0}.prose-sm>:first-child{margin-top:0}.prose-sm>:last-child{margin-bottom:0}.prose-lg{font-size:1.125rem;line-height:1.7777778}.prose-lg p{margin-bottom:1.3333333em;margin-top:1.3333333em}.prose-lg [class~=lead]{font-size:1.2222222em;line-height:1.4545455;margin-bottom:1.0909091em;margin-top:1.0909091em}.prose-lg blockquote{margin-bottom:1.6666667em;margin-top:1.6666667em;padding-left:1em}.prose-lg h1{font-size:2.6666667em;line-height:1;margin-bottom:.8333333em;margin-top:0}.prose-lg h2{font-size:1.6666667em;line-height:1.3333333;margin-bottom:1.0666667em;margin-top:1.8666667em}.prose-lg h3{font-size:1.3333333em;line-height:1.5;margin-bottom:.6666667em;margin-top:1.6666667em}.prose-lg h4{line-height:1.5555556;margin-bottom:.4444444em;margin-top:1.7777778em}.prose-lg figure,.prose-lg img,.prose-lg video{margin-bottom:1.7777778em;margin-top:1.7777778em}.prose-lg figure>*{margin-bottom:0;margin-top:0}.prose-lg figure figcaption{font-size:.8888889em;line-height:1.5;margin-top:1em}.prose-lg code{font-size:.8888889em}.prose-lg h2 code{font-size:.8666667em}.prose-lg h3 code{font-size:.875em}.prose-lg pre{border-radius:.375rem;font-size:.8888889em;line-height:1.75;margin-bottom:2em;margin-top:2em;padding:1em 1.5em}.prose-lg ol,.prose-lg ul{margin-bottom:1.3333333em;margin-top:1.3333333em}.prose-lg li{margin-bottom:.6666667em;margin-top:.6666667em}.prose-lg ol>li{padding-left:1.6666667em}.prose-lg ol>li:before{left:0}.prose-lg ul>li{padding-left:1.6666667em}.prose-lg ul>li:before{height:.3333333em;left:.2222222em;top:.72222em;width:.3333333em}.prose-lg>ul>li p{margin-bottom:.8888889em;margin-top:.8888889em}.prose-lg>ul>li>:first-child{margin-top:1.3333333em}.prose-lg>ul>li>:last-child{margin-bottom:1.3333333em}.prose-lg>ol>li>:first-child{margin-top:1.3333333em}.prose-lg>ol>li>:last-child{margin-bottom:1.3333333em}.prose-lg ol ol,.prose-lg ol ul,.prose-lg ul ol,.prose-lg ul ul{margin-bottom:.8888889em;margin-top:.8888889em}.prose-lg hr{margin-bottom:3.1111111em;margin-top:3.1111111em}.prose-lg h2+*,.prose-lg h3+*,.prose-lg h4+*,.prose-lg hr+*{margin-top:0}.prose-lg table{font-size:.8888889em;line-height:1.5}.prose-lg thead th{padding-bottom:.75em;padding-left:.75em;padding-right:.75em}.prose-lg thead th:first-child{padding-left:0}.prose-lg thead th:last-child{padding-right:0}.prose-lg tbody td{padding:.75em}.prose-lg tbody td:first-child{padding-left:0}.prose-lg tbody td:last-child{padding-right:0}.prose-lg>:first-child{margin-top:0}.prose-lg>:last-child{margin-bottom:0}.prose-xl{font-size:1.25rem;line-height:1.8}.prose-xl p{margin-bottom:1.2em;margin-top:1.2em}.prose-xl [class~=lead]{font-size:1.2em;line-height:1.5;margin-bottom:1em;margin-top:1em}.prose-xl blockquote{margin-bottom:1.6em;margin-top:1.6em;padding-left:1.0666667em}.prose-xl h1{font-size:2.8em;line-height:1;margin-bottom:.8571429em;margin-top:0}.prose-xl h2{font-size:1.8em;line-height:1.1111111;margin-bottom:.8888889em;margin-top:1.5555556em}.prose-xl h3{font-size:1.5em;line-height:1.3333333;margin-bottom:.6666667em;margin-top:1.6em}.prose-xl h4{line-height:1.6;margin-bottom:.6em;margin-top:1.8em}.prose-xl figure,.prose-xl img,.prose-xl video{margin-bottom:2em;margin-top:2em}.prose-xl figure>*{margin-bottom:0;margin-top:0}.prose-xl figure figcaption{font-size:.9em;line-height:1.5555556;margin-top:1em}.prose-xl code{font-size:.9em}.prose-xl h2 code{font-size:.8611111em}.prose-xl h3 code{font-size:.9em}.prose-xl pre{border-radius:.5rem;font-size:.9em;line-height:1.7777778;margin-bottom:2em;margin-top:2em;padding:1.1111111em 1.3333333em}.prose-xl ol,.prose-xl ul{margin-bottom:1.2em;margin-top:1.2em}.prose-xl li{margin-bottom:.6em;margin-top:.6em}.prose-xl ol>li{padding-left:1.8em}.prose-xl ol>li:before{left:0}.prose-xl ul>li{padding-left:1.8em}.prose-xl ul>li:before{height:.35em;left:.25em;top:.725em;width:.35em}.prose-xl>ul>li p{margin-bottom:.8em;margin-top:.8em}.prose-xl>ul>li>:first-child{margin-top:1.2em}.prose-xl>ul>li>:last-child{margin-bottom:1.2em}.prose-xl>ol>li>:first-child{margin-top:1.2em}.prose-xl>ol>li>:last-child{margin-bottom:1.2em}.prose-xl ol ol,.prose-xl ol ul,.prose-xl ul ol,.prose-xl ul ul{margin-bottom:.8em;margin-top:.8em}.prose-xl hr{margin-bottom:2.8em;margin-top:2.8em}.prose-xl h2+*,.prose-xl h3+*,.prose-xl h4+*,.prose-xl hr+*{margin-top:0}.prose-xl table{font-size:.9em;line-height:1.5555556}.prose-xl thead th{padding-bottom:.8888889em;padding-left:.6666667em;padding-right:.6666667em}.prose-xl thead th:first-child{padding-left:0}.prose-xl thead th:last-child{padding-right:0}.prose-xl tbody td{padding:.8888889em .6666667em}.prose-xl tbody td:first-child{padding-left:0}.prose-xl tbody td:last-child{padding-right:0}.prose-xl>:first-child{margin-top:0}.prose-xl>:last-child{margin-bottom:0}.prose-2xl{font-size:1.5rem;line-height:1.6666667}.prose-2xl p{margin-bottom:1.3333333em;margin-top:1.3333333em}.prose-2xl [class~=lead]{font-size:1.25em;line-height:1.4666667;margin-bottom:1.0666667em;margin-top:1.0666667em}.prose-2xl blockquote{margin-bottom:1.7777778em;margin-top:1.7777778em;padding-left:1.1111111em}.prose-2xl h1{font-size:2.6666667em;line-height:1;margin-bottom:.875em;margin-top:0}.prose-2xl h2{font-size:2em;line-height:1.0833333;margin-bottom:.8333333em;margin-top:1.5em}.prose-2xl h3{font-size:1.5em;line-height:1.2222222;margin-bottom:.6666667em;margin-top:1.5555556em}.prose-2xl h4{line-height:1.5;margin-bottom:.6666667em;margin-top:1.6666667em}.prose-2xl figure,.prose-2xl img,.prose-2xl video{margin-bottom:2em;margin-top:2em}.prose-2xl figure>*{margin-bottom:0;margin-top:0}.prose-2xl figure figcaption{font-size:.8333333em;line-height:1.6;margin-top:1em}.prose-2xl code{font-size:.8333333em}.prose-2xl h2 code{font-size:.875em}.prose-2xl h3 code{font-size:.8888889em}.prose-2xl pre{border-radius:.5rem;font-size:.8333333em;line-height:1.8;margin-bottom:2em;margin-top:2em;padding:1.2em 1.6em}.prose-2xl ol,.prose-2xl ul{margin-bottom:1.3333333em;margin-top:1.3333333em}.prose-2xl li{margin-bottom:.5em;margin-top:.5em}.prose-2xl ol>li{padding-left:1.6666667em}.prose-2xl ol>li:before{left:0}.prose-2xl ul>li{padding-left:1.6666667em}.prose-2xl ul>li:before{height:.3333333em;left:.25em;top:.66667em;width:.3333333em}.prose-2xl>ul>li p{margin-bottom:.8333333em;margin-top:.8333333em}.prose-2xl>ul>li>:first-child{margin-top:1.3333333em}.prose-2xl>ul>li>:last-child{margin-bottom:1.3333333em}.prose-2xl>ol>li>:first-child{margin-top:1.3333333em}.prose-2xl>ol>li>:last-child{margin-bottom:1.3333333em}.prose-2xl ol ol,.prose-2xl ol ul,.prose-2xl ul ol,.prose-2xl ul ul{margin-bottom:.6666667em;margin-top:.6666667em}.prose-2xl hr{margin-bottom:3em;margin-top:3em}.prose-2xl h2+*,.prose-2xl h3+*,.prose-2xl h4+*,.prose-2xl hr+*{margin-top:0}.prose-2xl table{font-size:.8333333em;line-height:1.4}.prose-2xl thead th{padding-bottom:.8em;padding-left:.6em;padding-right:.6em}.prose-2xl thead th:first-child{padding-left:0}.prose-2xl thead th:last-child{padding-right:0}.prose-2xl tbody td{padding:.8em .6em}.prose-2xl tbody td:first-child{padding-left:0}.prose-2xl tbody td:last-child{padding-right:0}.prose-2xl>:first-child{margin-top:0}.prose-2xl>:last-child{margin-bottom:0}.prose-indigo a,.prose-indigo a code{color:#4f46e5}.prose-red a,.prose-red a code{color:#e11d48}.prose-yellow a,.prose-yellow a code{color:#d97706}.prose-blue a,.prose-blue a code{color:#2563eb}.prose-purple a,.prose-purple a code{color:#9333ea}.aspect-none{padding-bottom:0;position:static}.aspect-none>*{bottom:auto;height:auto;left:auto;position:static;right:auto;top:auto;width:auto}.sr-only{clip:rect(0,0,0,0);border-width:0;height:1px;margin:-1px;overflow:hidden;padding:0;position:absolute;white-space:nowrap;width:1px}.not-sr-only{clip:auto;height:auto;margin:0;overflow:visible;padding:0;position:static;white-space:normal;width:auto}.pointer-events-none{pointer-events:none}.pointer-events-auto{pointer-events:auto}.visible{visibility:visible}.invisible{visibility:hidden}.static{position:static}.fixed{position:fixed}.absolute{position:absolute}.relative{position:relative}.sticky{position:sticky}.right-0{right:0}.isolate{isolation:isolate}.isolation-auto{isolation:auto}.col-span-1{grid-column:span 1/span 1}.float-right{float:right}.float-left{float:left}.float-none{float:none}.clear-left{clear:left}.clear-right{clear:right}.clear-both{clear:both}.clear-none{clear:none}.m-3{margin:.75rem}.m-4{margin:1rem}.m-8{margin:2rem}.m-14{margin:3.5rem}.m-16{margin:4rem}.mx-auto{margin-left:auto;margin-right:auto}.my-24{margin-bottom:6rem;margin-top:6rem}.-my-2{margin-bottom:-.5rem;margin-top:-.5rem}.mt-1{margin-top:.25rem}.mt-2{margin-top:.5rem}.mt-3{margin-top:.75rem}.mt-4{margin-top:1rem}.mt-12{margin-top:3rem}.mt-24{margin-top:6rem}.-mt-32{margin-top:-8rem}.-mr-2{margin-right:-.5rem}.ml-3{margin-left:.75rem}.ml-4{margin-left:1rem}.ml-10{margin-left:2.5rem}.-ml-px{margin-left:-1px}.box-border{box-sizing:border-box}.box-content{box-sizing:content-box}.block{display:block}.inline-block{display:inline-block}.inline{display:inline}.flex{display:flex}.inline-flex{display:inline-flex}.table{display:table}.inline-table{display:inline-table}.table-caption{display:table-caption}.table-cell{display:table-cell}.table-column{display:table-column}.table-column-group{display:table-column-group}.table-footer-group{display:table-footer-group}.table-header-group{display:table-header-group}.table-row-group{display:table-row-group}.table-row{display:table-row}.flow-root{display:flow-root}.grid{display:grid}.inline-grid{display:inline-grid}.contents{display:contents}.list-item{display:list-item}.hidden{display:none}.h-5{height:1.25rem}.h-6{height:1.5rem}.h-8{height:2rem}.h-10{height:2.5rem}.h-16{height:4rem}.h-full{height:100%}.w-1{width:.25rem}.w-5{width:1.25rem}.w-6{width:1.5rem}.w-8{width:2rem}.w-10{width:2.5rem}.w-48{width:12rem}.w-auto{width:auto}.w-1\/2{width:50%}.w-full{width:100%}.min-w-full{min-width:100%}.max-w-xs{max-width:20rem}.max-w-7xl{max-width:80rem}.max-w-full{max-width:100%}.flex-1{flex:1 1 0%}.flex-none{flex:none}.flex-shrink-0{flex-shrink:0}.flex-shrink{flex-shrink:1}.flex-grow{flex-grow:1}.table-auto{table-layout:auto}.table-fixed{table-layout:fixed}.border-collapse{border-collapse:collapse}.border-separate{border-collapse:separate}.origin-top-right{transform-origin:top right}.transform{transform:translateX(var(--tw-translate-x)) translateY(var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.transform,.transform-gpu{--tw-translate-x:0;--tw-translate-y:0;--tw-rotate:0;--tw-skew-x:0;--tw-skew-y:0;--tw-scale-x:1;--tw-scale-y:1}.transform-gpu{transform:translate3d(var(--tw-translate-x),var(--tw-translate-y),0) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.transform-none{transform:none}.rotate-90{--tw-rotate:90deg}.rotate-180{--tw-rotate:180deg}.scale-95{--tw-scale-x:.95;--tw-scale-y:.95}.scale-100{--tw-scale-x:1;--tw-scale-y:1}@-webkit-keyframes spin{to{transform:rotate(1turn)}}@keyframes spin{to{transform:rotate(1turn)}}@-webkit-keyframes ping{75%,to{opacity:0;transform:scale(2)}}@keyframes ping{75%,to{opacity:0;transform:scale(2)}}@-webkit-keyframes pulse{50%{opacity:.5}}@keyframes pulse{50%{opacity:.5}}@-webkit-keyframes bounce{0%,to{-webkit-animation-timing-function:cubic-bezier(.8,0,1,1);animation-timing-function:cubic-bezier(.8,0,1,1);transform:translateY(-25%)}50%{-webkit-animation-timing-function:cubic-bezier(0,0,.2,1);animation-timing-function:cubic-bezier(0,0,.2,1);transform:none}}@keyframes bounce{0%,to{-webkit-animation-timing-function:cubic-bezier(.8,0,1,1);animation-timing-function:cubic-bezier(.8,0,1,1);transform:translateY(-25%)}50%{-webkit-animation-timing-function:cubic-bezier(0,0,.2,1);animation-timing-function:cubic-bezier(0,0,.2,1);transform:none}}.cursor-default{cursor:default}.select-none{-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}.select-text{-webkit-user-select:text;-moz-user-select:text;-ms-user-select:text;user-select:text}.select-all{-webkit-user-select:all;-moz-user-select:all;user-select:all}.select-auto{-webkit-user-select:auto;-moz-user-select:auto;-ms-user-select:auto;user-select:auto}.resize-none{resize:none}.resize-y{resize:vertical}.resize-x{resize:horizontal}.resize{resize:both}.list-inside{list-style-position:inside}.list-outside{list-style-position:outside}.list-decimal{list-style-type:decimal}.appearance-none{-webkit-appearance:none;-moz-appearance:none;appearance:none}.grid-flow-row{grid-auto-flow:row}.grid-flow-col{grid-auto-flow:column}.grid-flow-row-dense{grid-auto-flow:row dense}.grid-flow-col-dense{grid-auto-flow:column dense}.grid-cols-1{grid-template-columns:repeat(1,minmax(0,1fr))}.grid-cols-2{grid-template-columns:repeat(2,minmax(0,1fr))}.flex-row{flex-direction:row}.flex-row-reverse{flex-direction:row-reverse}.flex-col{flex-direction:column}.flex-col-reverse{flex-direction:column-reverse}.flex-wrap{flex-wrap:wrap}.flex-wrap-reverse{flex-wrap:wrap-reverse}.flex-nowrap{flex-wrap:nowrap}.place-content-center{place-content:center}.place-content-start{place-content:start}.place-content-end{place-content:end}.place-content-between{place-content:space-between}.place-content-around{place-content:space-around}.place-content-evenly{place-content:space-evenly}.place-content-stretch{place-content:stretch}.place-items-start{place-items:start}.place-items-end{place-items:end}.place-items-center{place-items:center}.place-items-stretch{place-items:stretch}.content-center{align-content:center}.content-start{align-content:flex-start}.content-end{align-content:flex-end}.content-between{align-content:space-between}.content-around{align-content:space-around}.content-evenly{align-content:space-evenly}.items-start{align-items:flex-start}.items-end{align-items:flex-end}.items-center{align-items:center}.items-baseline{align-items:baseline}.items-stretch{align-items:stretch}.justify-start{justify-content:flex-start}.justify-end{justify-content:flex-end}.justify-center{justify-content:center}.justify-between{justify-content:space-between}.justify-around{justify-content:space-around}.justify-evenly{justify-content:space-evenly}.justify-items-start{justify-items:start}.justify-items-end{justify-items:end}.justify-items-center{justify-items:center}.justify-items-stretch{justify-items:stretch}.gap-2{gap:.5rem}.gap-5{gap:1.25rem}.gap-6{gap:1.5rem}.space-x-2>:not([hidden])~:not([hidden]){--tw-space-x-reverse:0;margin-left:calc(.5rem*(1 - var(--tw-space-x-reverse)));margin-right:calc(.5rem*var(--tw-space-x-reverse))}.space-x-3>:not([hidden])~:not([hidden]){--tw-space-x-reverse:0;margin-left:calc(.75rem*(1 - var(--tw-space-x-reverse)));margin-right:calc(.75rem*var(--tw-space-x-reverse))}.space-x-6>:not([hidden])~:not([hidden]){--tw-space-x-reverse:0;margin-left:calc(1.5rem*(1 - var(--tw-space-x-reverse)));margin-right:calc(1.5rem*var(--tw-space-x-reverse))}.space-y-2>:not([hidden])~:not([hidden]){--tw-space-y-reverse:0;margin-bottom:calc(.5rem*var(--tw-space-y-reverse));margin-top:calc(.5rem*(1 - var(--tw-space-y-reverse)))}.space-y-3>:not([hidden])~:not([hidden]){--tw-space-y-reverse:0;margin-bottom:calc(.75rem*var(--tw-space-y-reverse));margin-top:calc(.75rem*(1 - var(--tw-space-y-reverse)))}.space-y-6>:not([hidden])~:not([hidden]){--tw-space-y-reverse:0;margin-bottom:calc(1.5rem*var(--tw-space-y-reverse));margin-top:calc(1.5rem*(1 - var(--tw-space-y-reverse)))}.space-y-reverse>:not([hidden])~:not([hidden]){--tw-space-y-reverse:1}.space-x-reverse>:not([hidden])~:not([hidden]){--tw-space-x-reverse:1}.divide-x>:not([hidden])~:not([hidden]){--tw-divide-x-reverse:0;border-left-width:calc(1px*(1 - var(--tw-divide-x-reverse)));border-right-width:calc(1px*var(--tw-divide-x-reverse))}.divide-y>:not([hidden])~:not([hidden]){--tw-divide-y-reverse:0;border-bottom-width:calc(1px*var(--tw-divide-y-reverse));border-top-width:calc(1px*(1 - var(--tw-divide-y-reverse)))}.divide-y-reverse>:not([hidden])~:not([hidden]){--tw-divide-y-reverse:1}.divide-x-reverse>:not([hidden])~:not([hidden]){--tw-divide-x-reverse:1}.divide-solid>:not([hidden])~:not([hidden]){border-style:solid}.divide-dashed>:not([hidden])~:not([hidden]){border-style:dashed}.divide-dotted>:not([hidden])~:not([hidden]){border-style:dotted}.divide-double>:not([hidden])~:not([hidden]){border-style:double}.divide-none>:not([hidden])~:not([hidden]){border-style:none}.divide-gray-200>:not([hidden])~:not([hidden]){--tw-divide-opacity:1;border-color:rgba(231,229,228,var(--tw-divide-opacity))}.place-self-auto{place-self:auto}.place-self-start{place-self:start}.place-self-end{place-self:end}.place-self-center{place-self:center}.place-self-stretch{place-self:stretch}.self-auto{align-self:auto}.self-start{align-self:flex-start}.self-end{align-self:flex-end}.self-center{align-self:center}.self-stretch{align-self:stretch}.self-baseline{align-self:baseline}.justify-self-auto{justify-self:auto}.justify-self-start{justify-self:start}.justify-self-end{justify-self:end}.justify-self-center{justify-self:center}.justify-self-stretch{justify-self:stretch}.overflow-auto{overflow:auto}.overflow-hidden{overflow:hidden}.overflow-visible{overflow:visible}.overflow-scroll{overflow:scroll}.overflow-x-auto{overflow-x:auto}.overflow-y-auto{overflow-y:auto}.overflow-x-hidden{overflow-x:hidden}.overflow-y-hidden{overflow-y:hidden}.overflow-x-visible{overflow-x:visible}.overflow-y-visible{overflow-y:visible}.overflow-x-scroll{overflow-x:scroll}.overflow-y-scroll{overflow-y:scroll}.overscroll-auto{-ms-scroll-chaining:chained;overscroll-behavior:auto}.overscroll-contain{-ms-scroll-chaining:none;overscroll-behavior:contain}.overscroll-none{-ms-scroll-chaining:none;overscroll-behavior:none}.overscroll-y-auto{overscroll-behavior-y:auto}.overscroll-y-contain{overscroll-behavior-y:contain}.overscroll-y-none{overscroll-behavior-y:none}.overscroll-x-auto{overscroll-behavior-x:auto}.overscroll-x-contain{overscroll-behavior-x:contain}.overscroll-x-none{overscroll-behavior-x:none}.truncate{overflow:hidden;white-space:nowrap}.overflow-ellipsis,.truncate{text-overflow:ellipsis}.overflow-clip{text-overflow:clip}.whitespace-normal{white-space:normal}.whitespace-nowrap{white-space:nowrap}.whitespace-pre{white-space:pre}.whitespace-pre-line{white-space:pre-line}.whitespace-pre-wrap{white-space:pre-wrap}.break-normal{overflow-wrap:normal;word-break:normal}.break-words{overflow-wrap:break-word}.break-all{word-break:break-all}.rounded{border-radius:.25rem}.rounded-md{border-radius:.375rem}.rounded-lg{border-radius:.5rem}.rounded-full{border-radius:9999px}.rounded-t{border-top-left-radius:.25rem}.rounded-r,.rounded-t{border-top-right-radius:.25rem}.rounded-r{border-bottom-right-radius:.25rem}.rounded-r-md{border-bottom-right-radius:.375rem;border-top-right-radius:.375rem}.rounded-b{border-bottom-right-radius:.25rem}.rounded-b,.rounded-l{border-bottom-left-radius:.25rem}.rounded-l,.rounded-tl{border-top-left-radius:.25rem}.rounded-tr{border-top-right-radius:.25rem}.rounded-br{border-bottom-right-radius:.25rem}.rounded-bl{border-bottom-left-radius:.25rem}.border-2{border-width:2px}.border{border-width:1px}.border-t{border-top-width:1px}.border-r{border-right-width:1px}.border-b{border-bottom-width:1px}.border-l{border-left-width:1px}.border-solid{border-style:solid}.border-dashed{border-style:dashed}.border-dotted{border-style:dotted}.border-double{border-style:double}.border-none{border-style:none}.border-transparent{border-color:transparent}.border-gray-200{--tw-border-opacity:1;border-color:rgba(231,229,228,var(--tw-border-opacity))}.border-gray-300{--tw-border-opacity:1;border-color:rgba(214,211,209,var(--tw-border-opacity))}.border-gray-700{--tw-border-opacity:1;border-color:rgba(68,64,60,var(--tw-border-opacity))}.focus\:border-indigo-500:focus{--tw-border-opacity:1;border-color:rgba(99,102,241,var(--tw-border-opacity))}.bg-white{--tw-bg-opacity:1;background-color:rgba(255,255,255,var(--tw-bg-opacity))}.bg-gray-50{--tw-bg-opacity:1;background-color:rgba(250,250,249,var(--tw-bg-opacity))}.bg-gray-800{--tw-bg-opacity:1;background-color:rgba(41,37,36,var(--tw-bg-opacity))}.bg-gray-900{--tw-bg-opacity:1;background-color:rgba(28,25,23,var(--tw-bg-opacity))}.bg-red-50{--tw-bg-opacity:1;background-color:rgba(255,241,242,var(--tw-bg-opacity))}.hover\:bg-gray-100:hover{--tw-bg-opacity:1;background-color:rgba(245,245,244,var(--tw-bg-opacity))}.focus\:bg-gray-700:focus,.hover\:bg-gray-700:hover{--tw-bg-opacity:1;background-color:rgba(68,64,60,var(--tw-bg-opacity))}.focus\:bg-indigo-50:focus{--tw-bg-opacity:1;background-color:rgba(238,242,255,var(--tw-bg-opacity))}.bg-gradient-to-b{background-image:linear-gradient(to bottom,var(--tw-gradient-stops))}.from-black{--tw-gradient-from:#000;--tw-gradient-stops:var(--tw-gradient-from),var(--tw-gradient-to,transparent)}.to-gray-900{--tw-gradient-to:#1c1917}.decoration-slice{-webkit-box-decoration-break:slice;box-decoration-break:slice}.decoration-clone{-webkit-box-decoration-break:clone;box-decoration-break:clone}.bg-fixed{background-attachment:fixed}.bg-local{background-attachment:local}.bg-scroll{background-attachment:scroll}.bg-clip-border{background-clip:border-box}.bg-clip-padding{background-clip:padding-box}.bg-clip-content{background-clip:content-box}.bg-clip-text{-webkit-background-clip:text;background-clip:text}.bg-repeat{background-repeat:repeat}.bg-no-repeat{background-repeat:no-repeat}.bg-repeat-x{background-repeat:repeat-x}.bg-repeat-y{background-repeat:repeat-y}.bg-repeat-round{background-repeat:round}.bg-repeat-space{background-repeat:space}.bg-origin-border{background-origin:border-box}.bg-origin-padding{background-origin:padding-box}.bg-origin-content{background-origin:content-box}.object-contain{-o-object-fit:contain;object-fit:contain}.object-cover{-o-object-fit:cover;object-fit:cover}.object-fill{-o-object-fit:fill;object-fit:fill}.object-none{-o-object-fit:none;object-fit:none}.object-scale-down{-o-object-fit:scale-down;object-fit:scale-down}.p-1{padding:.25rem}.p-2{padding:.5rem}.p-4{padding:1rem}.p-6{padding:1.5rem}.px-1{padding-left:.25rem;padding-right:.25rem}.px-2{padding-left:.5rem;padding-right:.5rem}.px-3{padding-left:.75rem;padding-right:.75rem}.px-4{padding-left:1rem;padding-right:1rem}.px-5{padding-left:1.25rem;padding-right:1.25rem}.px-6{padding-left:1.5rem;padding-right:1.5rem}.px-1\.5{padding-left:.375rem;padding-right:.375rem}.py-0{padding-bottom:0;padding-top:0}.py-1{padding-bottom:.25rem;padding-top:.25rem}.py-2{padding-bottom:.5rem;padding-top:.5rem}.py-3{padding-bottom:.75rem;padding-top:.75rem}.py-4{padding-bottom:1rem;padding-top:1rem}.py-6{padding-bottom:1.5rem;padding-top:1.5rem}.py-10{padding-bottom:2.5rem;padding-top:2.5rem}.py-0\.5{padding-bottom:.125rem;padding-top:.125rem}.pt-4{padding-top:1rem}.pb-3{padding-bottom:.75rem}.pb-12{padding-bottom:3rem}.pb-32{padding-bottom:8rem}.pl-4{padding-left:1rem}.text-left{text-align:left}.text-center{text-align:center}.text-right{text-align:right}.text-justify{text-align:justify}.align-baseline{vertical-align:baseline}.align-top{vertical-align:top}.align-middle{vertical-align:middle}.align-bottom{vertical-align:bottom}.align-text-top{vertical-align:text-top}.align-text-bottom{vertical-align:text-bottom}.font-mono{font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace}.text-xs{font-size:.75rem;line-height:1rem}.text-sm{font-size:.875rem;line-height:1.25rem}.text-base{font-size:1rem;line-height:1.5rem}.text-lg{font-size:1.125rem;line-height:1.75rem}.text-xl{font-size:1.25rem;line-height:1.75rem}.text-2xl{font-size:1.5rem;line-height:2rem}.text-3xl{font-size:1.875rem;line-height:2.25rem}.text-6xl{font-size:3.75rem;line-height:1}.font-thin{font-weight:100}.font-medium{font-weight:500}.font-semibold{font-weight:600}.font-bold{font-weight:700}.font-extrabold{font-weight:800}.uppercase{text-transform:uppercase}.lowercase{text-transform:lowercase}.capitalize{text-transform:capitalize}.normal-case{text-transform:none}.italic{font-style:italic}.not-italic{font-style:normal}.diagonal-fractions,.lining-nums,.oldstyle-nums,.ordinal,.proportional-nums,.slashed-zero,.stacked-fractions,.tabular-nums{--tw-ordinal:var(--tw-empty,/*!*/ /*!*/);--tw-slashed-zero:var(--tw-empty,/*!*/ /*!*/);--tw-numeric-figure:var(--tw-empty,/*!*/ /*!*/);--tw-numeric-spacing:var(--tw-empty,/*!*/ /*!*/);--tw-numeric-fraction:var(--tw-empty,/*!*/ /*!*/);font-variant-numeric:var(--tw-ordinal) var(--tw-slashed-zero) var(--tw-numeric-figure) var(--tw-numeric-spacing) var(--tw-numeric-fraction)}.normal-nums{font-variant-numeric:normal}.ordinal{--tw-ordinal:ordinal}.slashed-zero{--tw-slashed-zero:slashed-zero}.lining-nums{--tw-numeric-figure:lining-nums}.oldstyle-nums{--tw-numeric-figure:oldstyle-nums}.proportional-nums{--tw-numeric-spacing:proportional-nums}.tabular-nums{--tw-numeric-spacing:tabular-nums}.diagonal-fractions{--tw-numeric-fraction:diagonal-fractions}.stacked-fractions{--tw-numeric-fraction:stacked-fractions}.leading-4{line-height:1rem}.leading-5{line-height:1.25rem}.leading-8{line-height:2rem}.leading-9{line-height:2.25rem}.leading-none{line-height:1}.leading-loose{line-height:2}.tracking-tight{letter-spacing:-.025em}.tracking-wide{letter-spacing:.025em}.tracking-wider{letter-spacing:.05em}.text-white{--tw-text-opacity:1;color:rgba(255,255,255,var(--tw-text-opacity))}.text-gray-50{--tw-text-opacity:1;color:rgba(250,250,249,var(--tw-text-opacity))}.text-gray-300{--tw-text-opacity:1;color:rgba(214,211,209,var(--tw-text-opacity))}.text-gray-400{--tw-text-opacity:1;color:rgba(168,162,158,var(--tw-text-opacity))}.text-gray-500{--tw-text-opacity:1;color:rgba(120,113,108,var(--tw-text-opacity))}.text-gray-600{--tw-text-opacity:1;color:rgba(87,83,78,var(--tw-text-opacity))}.text-gray-700{--tw-text-opacity:1;color:rgba(68,64,60,var(--tw-text-opacity))}.text-gray-900{--tw-text-opacity:1;color:rgba(28,25,23,var(--tw-text-opacity))}.text-red-400{--tw-text-opacity:1;color:rgba(251,113,133,var(--tw-text-opacity))}.text-red-800{--tw-text-opacity:1;color:rgba(159,18,57,var(--tw-text-opacity))}.hover\:text-white:hover{--tw-text-opacity:1;color:rgba(255,255,255,var(--tw-text-opacity))}.hover\:text-gray-600:hover{--tw-text-opacity:1;color:rgba(87,83,78,var(--tw-text-opacity))}.hover\:text-gray-700:hover{--tw-text-opacity:1;color:rgba(68,64,60,var(--tw-text-opacity))}.focus\:text-white:focus{--tw-text-opacity:1;color:rgba(255,255,255,var(--tw-text-opacity))}.focus\:text-indigo-600:focus{--tw-text-opacity:1;color:rgba(79,70,229,var(--tw-text-opacity))}.underline{text-decoration:underline}.line-through{text-decoration:line-through}.no-underline{text-decoration:none}.antialiased{-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}.subpixel-antialiased{-webkit-font-smoothing:auto;-moz-osx-font-smoothing:auto}.opacity-0{opacity:0}.opacity-100{opacity:1}.bg-blend-normal{background-blend-mode:normal}.bg-blend-multiply{background-blend-mode:multiply}.bg-blend-screen{background-blend-mode:screen}.bg-blend-overlay{background-blend-mode:overlay}.bg-blend-darken{background-blend-mode:darken}.bg-blend-lighten{background-blend-mode:lighten}.bg-blend-color-dodge{background-blend-mode:color-dodge}.bg-blend-color-burn{background-blend-mode:color-burn}.bg-blend-hard-light{background-blend-mode:hard-light}.bg-blend-soft-light{background-blend-mode:soft-light}.bg-blend-difference{background-blend-mode:difference}.bg-blend-exclusion{background-blend-mode:exclusion}.bg-blend-hue{background-blend-mode:hue}.bg-blend-saturation{background-blend-mode:saturation}.bg-blend-color{background-blend-mode:color}.bg-blend-luminosity{background-blend-mode:luminosity}.mix-blend-normal{mix-blend-mode:normal}.mix-blend-multiply{mix-blend-mode:multiply}.mix-blend-screen{mix-blend-mode:screen}.mix-blend-overlay{mix-blend-mode:overlay}.mix-blend-darken{mix-blend-mode:darken}.mix-blend-lighten{mix-blend-mode:lighten}.mix-blend-color-dodge{mix-blend-mode:color-dodge}.mix-blend-color-burn{mix-blend-mode:color-burn}.mix-blend-hard-light{mix-blend-mode:hard-light}.mix-blend-soft-light{mix-blend-mode:soft-light}.mix-blend-difference{mix-blend-mode:difference}.mix-blend-exclusion{mix-blend-mode:exclusion}.mix-blend-hue{mix-blend-mode:hue}.mix-blend-saturation{mix-blend-mode:saturation}.mix-blend-color{mix-blend-mode:color}.mix-blend-luminosity{mix-blend-mode:luminosity}*,:after,:before{--tw-shadow:0 0 #0000}.shadow-sm{--tw-shadow:0 1px 2px 0 rgba(0,0,0,0.05)}.shadow,.shadow-sm{box-shadow:var(--tw-ring-offset-shadow,0 0 #0000),var(--tw-ring-shadow,0 0 #0000),var(--tw-shadow)}.shadow{--tw-shadow:0 1px 3px 0 rgba(0,0,0,0.1),0 1px 2px 0 rgba(0,0,0,0.06)}.shadow-lg{--tw-shadow:0 10px 15px -3px rgba(0,0,0,0.1),0 4px 6px -2px rgba(0,0,0,0.05);box-shadow:var(--tw-ring-offset-shadow,0 0 #0000),var(--tw-ring-shadow,0 0 #0000),var(--tw-shadow)}.focus\:outline-none:focus{outline:2px solid transparent;outline-offset:2px}*,:after,:before{--tw-ring-inset:var(--tw-empty,/*!*/ /*!*/);--tw-ring-offset-width:0px;--tw-ring-offset-color:#fff;--tw-ring-color:rgba(59,130,246,0.5);--tw-ring-offset-shadow:0 0 #0000;--tw-ring-shadow:0 0 #0000}.ring{--tw-ring-offset-shadow:var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow:var(--tw-ring-inset) 0 0 0 calc(3px + var(--tw-ring-offset-width)) var(--tw-ring-color)}.focus\:ring-1:focus,.ring{box-shadow:var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow,0 0 #0000)}.focus\:ring-1:focus{--tw-ring-offset-shadow:var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow:var(--tw-ring-inset) 0 0 0 calc(1px + var(--tw-ring-offset-width)) var(--tw-ring-color)}.ring-inset{--tw-ring-inset:inset}.focus\:ring-indigo-500:focus{--tw-ring-opacity:1;--tw-ring-color:rgba(99,102,241,var(--tw-ring-opacity))}.filter{--tw-blur:var(--tw-empty,/*!*/ /*!*/);--tw-brightness:var(--tw-empty,/*!*/ /*!*/);--tw-contrast:var(--tw-empty,/*!*/ /*!*/);--tw-grayscale:var(--tw-empty,/*!*/ /*!*/);--tw-hue-rotate:var(--tw-empty,/*!*/ /*!*/);--tw-invert:var(--tw-empty,/*!*/ /*!*/);--tw-saturate:var(--tw-empty,/*!*/ /*!*/);--tw-sepia:var(--tw-empty,/*!*/ /*!*/);--tw-drop-shadow:var(--tw-empty,/*!*/ /*!*/);filter:var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow)}.filter-none{filter:none}.blur{--tw-blur:blur(8px)}.drop-shadow{--tw-drop-shadow:drop-shadow(0 1px 2px rgba(0,0,0,0.1)) drop-shadow(0 1px 1px rgba(0,0,0,0.06))}.grayscale{--tw-grayscale:grayscale(100%)}.invert{--tw-invert:invert(100%)}.sepia{--tw-sepia:sepia(100%)}.backdrop-filter{--tw-backdrop-blur:var(--tw-empty,/*!*/ /*!*/);--tw-backdrop-brightness:var(--tw-empty,/*!*/ /*!*/);--tw-backdrop-contrast:var(--tw-empty,/*!*/ /*!*/);--tw-backdrop-grayscale:var(--tw-empty,/*!*/ /*!*/);--tw-backdrop-hue-rotate:var(--tw-empty,/*!*/ /*!*/);--tw-backdrop-invert:var(--tw-empty,/*!*/ /*!*/);--tw-backdrop-opacity:var(--tw-empty,/*!*/ /*!*/);--tw-backdrop-saturate:var(--tw-empty,/*!*/ /*!*/);--tw-backdrop-sepia:var(--tw-empty,/*!*/ /*!*/);-webkit-backdrop-filter:var(--tw-backdrop-blur) var(--tw-backdrop-brightness) var(--tw-backdrop-contrast) var(--tw-backdrop-grayscale) var(--tw-backdrop-hue-rotate) var(--tw-backdrop-invert) var(--tw-backdrop-opacity) var(--tw-backdrop-saturate) var(--tw-backdrop-sepia);backdrop-filter:var(--tw-backdrop-blur) var(--tw-backdrop-brightness) var(--tw-backdrop-contrast) var(--tw-backdrop-grayscale) var(--tw-backdrop-hue-rotate) var(--tw-backdrop-invert) var(--tw-backdrop-opacity) var(--tw-backdrop-saturate) var(--tw-backdrop-sepia)}.backdrop-filter-none{-webkit-backdrop-filter:none;backdrop-filter:none}.backdrop-blur{--tw-backdrop-blur:blur(8px)}.backdrop-grayscale{--tw-backdrop-grayscale:grayscale(100%)}.backdrop-invert{--tw-backdrop-invert:invert(100%)}.backdrop-sepia{--tw-backdrop-sepia:sepia(100%)}.transition{transition-duration:.15s;transition-property:background-color,border-color,color,fill,stroke,opacity,box-shadow,transform,filter,-webkit-backdrop-filter;transition-property:background-color,border-color,color,fill,stroke,opacity,box-shadow,transform,filter,backdrop-filter;transition-property:background-color,border-color,color,fill,stroke,opacity,box-shadow,transform,filter,backdrop-filter,-webkit-backdrop-filter;transition-timing-function:cubic-bezier(.4,0,.2,1)}.duration-75{transition-duration:75ms}.duration-100{transition-duration:.1s}.duration-150{transition-duration:.15s}.ease-in{transition-timing-function:cubic-bezier(.4,0,1,1)}.ease-out{transition-timing-function:cubic-bezier(0,0,.2,1)}.ease-in-out{transition-timing-function:cubic-bezier(.4,0,.2,1)}.dropdown{position:relative}.dropdown summary{cursor:pointer;list-style:none}.dropdown summary::-webkit-details-marker{display:none}.dropdown summary .content{position:absolute}.dropdown summary details[open] summary:before{bottom:0;content:"";cursor:default;left:0;position:fixed;right:0;top:0}.phx-disconnected>.chat .disconnected,.phx-error>.chat .phx-errored{@display block}.chat{height:100vh;max-height:100vh}.chat .disconnected,.chat .phx-errored{display:none}.chat .body{display:grid;grid-template-columns:repeat(10,minmax(0,1fr));height:75%}.chat .body .log{gap:1rem;grid-column:span 9/span 9;height:24rem;height:100%;max-width:100%}.chat .body .log .time-component{cursor:default;display:inline-block;flex:none;font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace;font-size:.875rem;line-height:1.25rem}.chat .body .log li.event .time-component{--tw-text-opacity:1;color:rgba(68,64,60,var(--tw-text-opacity))};@media (prefers-color-scheme:dark){.chat .body .log li.event .time-component{--tw-text-opacity:1;color:rgba(214,211,209,var(--tw-text-opacity))}}.chat .body .log li.event .nick{--tw-text-opacity:1;color:rgba(68,64,60,var(--tw-text-opacity))}@media (prefers-color-scheme:dark){.chat .body .log li.event .nick{--tw-text-opacity:1;color:rgba(68,64,60,var(--tw-text-opacity))}}.chat .body aside{--tw-bg-opacity:1;background-color:rgba(245,245,244,var(--tw-bg-opacity));font-size:.875rem;line-height:1.25rem;padding-left:1rem;padding-right:1rem;padding-top:1rem}.chat .body aside .user.dropdown .content{--tw-bg-opacity:1;--tw-shadow:0 20px 25px -5px rgba(0,0,0,0.1),0 10px 10px -5px rgba(0,0,0,0.04);background-color:rgba(250,250,249,var(--tw-bg-opacity));border-radius:.375rem;box-shadow:var(--tw-ring-offset-shadow,0 0 #0000),var(--tw-ring-shadow,0 0 #0000),var(--tw-shadow);margin-right:1rem;margin-top:-1rem;padding:1rem;position:absolute;right:100%;transform-origin:top right;width:20rem;z-index:40}.chat .body aside .user.dropdown .content:focus{outline:2px solid transparent;outline-offset:2px}.chat .body aside .user.dropdown .content{--tw-ring-offset-shadow:var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow:var(--tw-ring-inset) 0 0 0 calc(1px + var(--tw-ring-offset-width)) var(--tw-ring-color);--tw-ring-opacity:1;--tw-ring-color:rgba(0,0,0,var(--tw-ring-opacity));--tw-ring-opacity:0.05;box-shadow:var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow,0 0 #0000)}@media (min-width:640px){.sm\:-mx-6{margin-left:-1.5rem;margin-right:-1.5rem}.sm\:block{display:block}.sm\:grid-cols-2{grid-template-columns:repeat(2,minmax(0,1fr))}.sm\:grid-cols-4{grid-template-columns:repeat(4,minmax(0,1fr))}.sm\:grid-cols-5{grid-template-columns:repeat(5,minmax(0,1fr))}.sm\:gap-6{gap:1.5rem}.sm\:rounded-lg{border-radius:.5rem}.sm\:px-0{padding-left:0;padding-right:0}.sm\:px-3{padding-left:.75rem;padding-right:.75rem}.sm\:px-6{padding-left:1.5rem;padding-right:1.5rem}.sm\:text-sm{font-size:.875rem;line-height:1.25rem}}@media (min-width:768px){.md\:ml-6{margin-left:1.5rem}.md\:block{display:block}.md\:hidden{display:none}}@media (min-width:1024px){.lg\:-mx-8{margin-left:-2rem;margin-right:-2rem}.lg\:grid-cols-3{grid-template-columns:repeat(3,minmax(0,1fr))}.lg\:grid-cols-5{grid-template-columns:repeat(5,minmax(0,1fr))}.lg\:grid-cols-6{grid-template-columns:repeat(6,minmax(0,1fr))}.lg\:px-8{padding-left:2rem;padding-right:2rem}}
\ No newline at end of file diff --git a/priv/static/assets/site.css.br b/priv/static/assets/site.css.br Binary files differindex fee2dc3..ef02918 100644 --- a/priv/static/assets/site.css.br +++ b/priv/static/assets/site.css.br diff --git a/priv/static/assets/site.css.gz b/priv/static/assets/site.css.gz Binary files differindex 9ae5119..f9dd920 100644 --- a/priv/static/assets/site.css.gz +++ b/priv/static/assets/site.css.gz diff --git a/priv/static/assets/site.js b/priv/static/assets/site.js index 971f9fa..e0bdc79 100644 --- a/priv/static/assets/site.js +++ b/priv/static/assets/site.js @@ -1,6 +1,7 @@ -(()=>{(function(){if(window.Reflect===void 0||window.customElements===void 0||window.customElements.polyfillWrapFlushCallback)return;let r=HTMLElement,e={HTMLElement:function(){return Reflect.construct(r,[],this.constructor)}};window.HTMLElement=e.HTMLElement,HTMLElement.prototype=r.prototype,HTMLElement.prototype.constructor=HTMLElement,Object.setPrototypeOf(HTMLElement,r)})();var Z=new WeakMap;function dt(r){let e=r instanceof Element?r:r instanceof Node?r.parentElement:null,t=e?e.closest("input, button"):null;return(t==null?void 0:t.type)=="submit"?t:null}function ft(r){let e=dt(r.target);e&&e.form&&Z.set(e.form,e)}(function(){"SubmitEvent"in window||(addEventListener("click",ft,!0),Object.defineProperty(Event.prototype,"submitter",{get(){if(this.type=="submit"&&this.target instanceof HTMLFormElement)return Z.get(this.target)}}))})();var w;(function(r){r.eager="eager",r.lazy="lazy"})(w||(w={}));var v=class extends HTMLElement{constructor(){super();this.loaded=Promise.resolve(),this.delegate=new v.delegateConstructor(this)}static get observedAttributes(){return["disabled","loading","src"]}connectedCallback(){this.delegate.connect()}disconnectedCallback(){this.delegate.disconnect()}reload(){let{src:e}=this;this.src=null,this.src=e}attributeChangedCallback(e){e=="loading"?this.delegate.loadingStyleChanged():e=="src"?this.delegate.sourceURLChanged():this.delegate.disabledChanged()}get src(){return this.getAttribute("src")}set src(e){e?this.setAttribute("src",e):this.removeAttribute("src")}get loading(){return pt(this.getAttribute("loading")||"")}set loading(e){e?this.setAttribute("loading",e):this.removeAttribute("loading")}get disabled(){return this.hasAttribute("disabled")}set disabled(e){e?this.setAttribute("disabled",""):this.removeAttribute("disabled")}get autoscroll(){return this.hasAttribute("autoscroll")}set autoscroll(e){e?this.setAttribute("autoscroll",""):this.removeAttribute("autoscroll")}get complete(){return!this.delegate.isLoading}get isActive(){return this.ownerDocument===document&&!this.isPreview}get isPreview(){var e,t;return(t=(e=this.ownerDocument)===null||e===void 0?void 0:e.documentElement)===null||t===void 0?void 0:t.hasAttribute("data-turbo-preview")}};function pt(r){switch(r.toLowerCase()){case"lazy":return w.lazy;default:return w.eager}}function m(r){return new URL(r.toString(),document.baseURI)}function P(r){let e;if(r.hash)return r.hash.slice(1);if(e=r.href.match(/#(.*)$/))return e[1]}function mt(r){return(wt(r).match(/\.[^.]*$/)||[])[0]||""}function gt(r){return!!mt(r).match(/^(?:|\.(?:htm|html|xhtml))$/)}function vt(r,e){let t=Et(e);return r.href===m(t).href||r.href.startsWith(t)}function _(r){let e=P(r);return e!=null?r.href.slice(0,-(e.length+1)):r.href}function F(r){return _(r)}function bt(r,e){return m(r).href==m(e).href}function yt(r){return r.pathname.split("/").slice(1)}function wt(r){return yt(r).slice(-1)[0]}function Et(r){return St(r.origin+r.pathname)}function St(r){return r.endsWith("/")?r:r+"/"}var W=class{constructor(e){this.response=e}get succeeded(){return this.response.ok}get failed(){return!this.succeeded}get clientError(){return this.statusCode>=400&&this.statusCode<=499}get serverError(){return this.statusCode>=500&&this.statusCode<=599}get redirected(){return this.response.redirected}get location(){return m(this.response.url)}get isHTML(){return this.contentType&&this.contentType.match(/^(?:text\/([^\s;,]+\b)?html|application\/xhtml\+xml)\b/)}get statusCode(){return this.response.status}get contentType(){return this.header("Content-Type")}get responseText(){return this.response.text()}get responseHTML(){return this.isHTML?this.response.text():Promise.resolve(void 0)}header(e){return this.response.headers.get(e)}};function u(r,{target:e,cancelable:t,detail:n}={}){let i=new CustomEvent(r,{cancelable:t,bubbles:!0,detail:n});return(e||document.documentElement).dispatchEvent(i),i}function B(){return new Promise(r=>requestAnimationFrame(()=>r()))}function At(){return new Promise(r=>setTimeout(()=>r(),0))}function Pt(){return Promise.resolve()}function ee(r=""){return new DOMParser().parseFromString(r,"text/html")}function te(r,...e){let t=Lt(r,e).replace(/^\n/,"").split(` -`),n=t[0].match(/^\s+/),i=n?n[0].length:0;return t.map(s=>s.slice(i)).join(` -`)}function Lt(r,e){return r.reduce((t,n,i)=>{let s=e[i]==null?"":e[i];return t+n+s},"")}function k(){return Array.apply(null,{length:36}).map((r,e)=>e==8||e==13||e==18||e==23?"-":e==14?"4":e==19?(Math.floor(Math.random()*4)+8).toString(16):Math.floor(Math.random()*15).toString(16)).join("")}var h;(function(r){r[r.get=0]="get",r[r.post=1]="post",r[r.put=2]="put",r[r.patch=3]="patch",r[r.delete=4]="delete"})(h||(h={}));function Tt(r){switch(r.toLowerCase()){case"get":return h.get;case"post":return h.post;case"put":return h.put;case"patch":return h.patch;case"delete":return h.delete}}var I=class{constructor(e,t,n,i=new URLSearchParams){this.abortController=new AbortController,this.resolveRequestPromise=s=>{},this.delegate=e,this.method=t,this.headers=this.defaultHeaders,this.isIdempotent?this.url=Ct(n,[...i.entries()]):(this.body=i,this.url=n)}get location(){return this.url}get params(){return this.url.searchParams}get entries(){return this.body?Array.from(this.body.entries()):[]}cancel(){this.abortController.abort()}async perform(){var e,t;let{fetchOptions:n}=this;(t=(e=this.delegate).prepareHeadersForRequest)===null||t===void 0||t.call(e,this.headers,this),await this.allowRequestToBeIntercepted(n);try{this.delegate.requestStarted(this);let i=await fetch(this.url.href,n);return await this.receive(i)}catch(i){if(i.name!=="AbortError")throw this.delegate.requestErrored(this,i),i}finally{this.delegate.requestFinished(this)}}async receive(e){let t=new W(e);return u("turbo:before-fetch-response",{cancelable:!0,detail:{fetchResponse:t}}).defaultPrevented?this.delegate.requestPreventedHandlingResponse(this,t):t.succeeded?this.delegate.requestSucceededWithResponse(this,t):this.delegate.requestFailedWithResponse(this,t),t}get fetchOptions(){var e;return{method:h[this.method].toUpperCase(),credentials:"same-origin",headers:this.headers,redirect:"follow",body:this.body,signal:this.abortSignal,referrer:(e=this.delegate.referrer)===null||e===void 0?void 0:e.href}}get defaultHeaders(){return{Accept:"text/html, application/xhtml+xml"}}get isIdempotent(){return this.method==h.get}get abortSignal(){return this.abortController.signal}async allowRequestToBeIntercepted(e){let t=new Promise(i=>this.resolveRequestPromise=i);u("turbo:before-fetch-request",{cancelable:!0,detail:{fetchOptions:e,url:this.url.href,resume:this.resolveRequestPromise}}).defaultPrevented&&await t}};function Ct(r,e){let t=new URLSearchParams(r.search);for(let[n,i]of e)i instanceof File||(t.has(n)?(t.delete(n),r.searchParams.set(n,i)):r.searchParams.append(n,i));return r}var re=class{constructor(e,t){this.started=!1,this.intersect=n=>{let i=n.slice(-1)[0];(i==null?void 0:i.isIntersecting)&&this.delegate.elementAppearedInViewport(this.element)},this.delegate=e,this.element=t,this.intersectionObserver=new IntersectionObserver(this.intersect)}start(){this.started||(this.started=!0,this.intersectionObserver.observe(this.element))}stop(){this.started&&(this.started=!1,this.intersectionObserver.unobserve(this.element))}},L=class{constructor(e){this.templateElement=document.createElement("template"),this.templateElement.innerHTML=e}static wrap(e){return typeof e=="string"?new this(e):e}get fragment(){let e=document.createDocumentFragment();for(let t of this.foreignElements)e.appendChild(document.importNode(t,!0));return e}get foreignElements(){return this.templateChildren.reduce((e,t)=>t.tagName.toLowerCase()=="turbo-stream"?[...e,t]:e,[])}get templateChildren(){return Array.from(this.templateElement.content.children)}};L.contentType="text/vnd.turbo-stream.html";var E;(function(r){r[r.initialized=0]="initialized",r[r.requesting=1]="requesting",r[r.waiting=2]="waiting",r[r.receiving=3]="receiving",r[r.stopping=4]="stopping",r[r.stopped=5]="stopped"})(E||(E={}));var S;(function(r){r.urlEncoded="application/x-www-form-urlencoded",r.multipart="multipart/form-data",r.plain="text/plain"})(S||(S={}));function Ot(r){switch(r.toLowerCase()){case S.multipart:return S.multipart;case S.plain:return S.plain;default:return S.urlEncoded}}var U=class{constructor(e,t,n,i=!1){this.state=E.initialized,this.delegate=e,this.formElement=t,this.submitter=n,this.formData=Rt(t,n),this.fetchRequest=new I(this,this.method,this.location,this.body),this.mustRedirect=i}get method(){var e;let t=((e=this.submitter)===null||e===void 0?void 0:e.getAttribute("formmethod"))||this.formElement.getAttribute("method")||"";return Tt(t.toLowerCase())||h.get}get action(){var e;let t=typeof this.formElement.action=="string"?this.formElement.action:null;return((e=this.submitter)===null||e===void 0?void 0:e.getAttribute("formaction"))||this.formElement.getAttribute("action")||t||""}get location(){return m(this.action)}get body(){return this.enctype==S.urlEncoded||this.method==h.get?new URLSearchParams(this.stringFormData):this.formData}get enctype(){var e;return Ot(((e=this.submitter)===null||e===void 0?void 0:e.getAttribute("formenctype"))||this.formElement.enctype)}get isIdempotent(){return this.fetchRequest.isIdempotent}get stringFormData(){return[...this.formData].reduce((e,[t,n])=>e.concat(typeof n=="string"?[[t,n]]:[]),[])}async start(){let{initialized:e,requesting:t}=E;if(this.state==e)return this.state=t,this.fetchRequest.perform()}stop(){let{stopping:e,stopped:t}=E;if(this.state!=e&&this.state!=t)return this.state=e,this.fetchRequest.cancel(),!0}prepareHeadersForRequest(e,t){if(!t.isIdempotent){let n=kt(ne("csrf-param"))||ne("csrf-token");n&&(e["X-CSRF-Token"]=n),e.Accept=[L.contentType,e.Accept].join(", ")}}requestStarted(e){this.state=E.waiting,u("turbo:submit-start",{target:this.formElement,detail:{formSubmission:this}}),this.delegate.formSubmissionStarted(this)}requestPreventedHandlingResponse(e,t){this.result={success:t.succeeded,fetchResponse:t}}requestSucceededWithResponse(e,t){if(t.clientError||t.serverError)this.delegate.formSubmissionFailedWithResponse(this,t);else if(this.requestMustRedirect(e)&&Mt(t)){let n=new Error("Form responses must redirect to another location");this.delegate.formSubmissionErrored(this,n)}else this.state=E.receiving,this.result={success:!0,fetchResponse:t},this.delegate.formSubmissionSucceededWithResponse(this,t)}requestFailedWithResponse(e,t){this.result={success:!1,fetchResponse:t},this.delegate.formSubmissionFailedWithResponse(this,t)}requestErrored(e,t){this.result={success:!1,error:t},this.delegate.formSubmissionErrored(this,t)}requestFinished(e){this.state=E.stopped,u("turbo:submit-end",{target:this.formElement,detail:Object.assign({formSubmission:this},this.result)}),this.delegate.formSubmissionFinished(this)}requestMustRedirect(e){return!e.isIdempotent&&this.mustRedirect}};function Rt(r,e){let t=new FormData(r),n=e==null?void 0:e.getAttribute("name"),i=e==null?void 0:e.getAttribute("value");return n&&i!=null&&t.get(n)!=i&&t.append(n,i),t}function kt(r){if(r!=null){let t=(document.cookie?document.cookie.split("; "):[]).find(n=>n.startsWith(r));if(t){let n=t.split("=").slice(1).join("=");return n?decodeURIComponent(n):void 0}}}function ne(r){let e=document.querySelector(`meta[name="${r}"]`);return e&&e.content}function Mt(r){return r.statusCode==200&&!r.redirected}var M=class{constructor(e){this.element=e}get children(){return[...this.element.children]}hasAnchor(e){return this.getElementForAnchor(e)!=null}getElementForAnchor(e){return e?this.element.querySelector(`[id='${e}'], a[name='${e}']`):null}get isConnected(){return this.element.isConnected}get firstAutofocusableElement(){return this.element.querySelector("[autofocus]")}get permanentElements(){return[...this.element.querySelectorAll("[id][data-turbo-permanent]")]}getPermanentElementById(e){return this.element.querySelector(`#${e}[data-turbo-permanent]`)}getPermanentElementMapForSnapshot(e){let t={};for(let n of this.permanentElements){let{id:i}=n,s=e.getPermanentElementById(i);s&&(t[i]=[n,s])}return t}},K=class{constructor(e,t){this.submitBubbled=n=>{if(n.target instanceof HTMLFormElement){let i=n.target,s=n.submitter||void 0;this.delegate.shouldInterceptFormSubmission(i,s)&&(n.preventDefault(),n.stopImmediatePropagation(),this.delegate.formSubmissionIntercepted(i,s))}},this.delegate=e,this.element=t}start(){this.element.addEventListener("submit",this.submitBubbled)}stop(){this.element.removeEventListener("submit",this.submitBubbled)}},z=class{constructor(e,t){this.resolveRenderPromise=n=>{},this.resolveInterceptionPromise=n=>{},this.delegate=e,this.element=t}scrollToAnchor(e){let t=this.snapshot.getElementForAnchor(e);t?(this.scrollToElement(t),this.focusElement(t)):this.scrollToPosition({x:0,y:0})}scrollToAnchorFromLocation(e){this.scrollToAnchor(P(e))}scrollToElement(e){e.scrollIntoView()}focusElement(e){e instanceof HTMLElement&&(e.hasAttribute("tabindex")?e.focus():(e.setAttribute("tabindex","-1"),e.focus(),e.removeAttribute("tabindex")))}scrollToPosition({x:e,y:t}){this.scrollRoot.scrollTo(e,t)}scrollToTop(){this.scrollToPosition({x:0,y:0})}get scrollRoot(){return window}async render(e){let{isPreview:t,shouldRender:n,newSnapshot:i}=e;if(n)try{this.renderPromise=new Promise(c=>this.resolveRenderPromise=c),this.renderer=e,this.prepareToRenderSnapshot(e);let s=new Promise(c=>this.resolveInterceptionPromise=c);this.delegate.allowsImmediateRender(i,this.resolveInterceptionPromise)||await s,await this.renderSnapshot(e),this.delegate.viewRenderedSnapshot(i,t),this.finishRenderingSnapshot(e)}finally{delete this.renderer,this.resolveRenderPromise(void 0),delete this.renderPromise}else this.invalidate()}invalidate(){this.delegate.viewInvalidated()}prepareToRenderSnapshot(e){this.markAsPreview(e.isPreview),e.prepareToRender()}markAsPreview(e){e?this.element.setAttribute("data-turbo-preview",""):this.element.removeAttribute("data-turbo-preview")}async renderSnapshot(e){await e.render()}finishRenderingSnapshot(e){e.finishRendering()}},ie=class extends z{invalidate(){this.element.innerHTML=""}get snapshot(){return new M(this.element)}},$=class{constructor(e,t){this.clickBubbled=n=>{this.respondsToEventTarget(n.target)?this.clickEvent=n:delete this.clickEvent},this.linkClicked=n=>{this.clickEvent&&this.respondsToEventTarget(n.target)&&n.target instanceof Element&&this.delegate.shouldInterceptLinkClick(n.target,n.detail.url)&&(this.clickEvent.preventDefault(),n.preventDefault(),this.delegate.linkClickIntercepted(n.target,n.detail.url)),delete this.clickEvent},this.willVisit=()=>{delete this.clickEvent},this.delegate=e,this.element=t}start(){this.element.addEventListener("click",this.clickBubbled),document.addEventListener("turbo:click",this.linkClicked),document.addEventListener("turbo:before-visit",this.willVisit)}stop(){this.element.removeEventListener("click",this.clickBubbled),document.removeEventListener("turbo:click",this.linkClicked),document.removeEventListener("turbo:before-visit",this.willVisit)}respondsToEventTarget(e){let t=e instanceof Element?e:e instanceof Node?e.parentElement:null;return t&&t.closest("turbo-frame, html")==this.element}},se=class{constructor(e){this.permanentElementMap=e}static preservingPermanentElements(e,t){let n=new this(e);n.enter(),t(),n.leave()}enter(){for(let e in this.permanentElementMap){let[,t]=this.permanentElementMap[e];this.replaceNewPermanentElementWithPlaceholder(t)}}leave(){for(let e in this.permanentElementMap){let[t]=this.permanentElementMap[e];this.replaceCurrentPermanentElementWithClone(t),this.replacePlaceholderWithPermanentElement(t)}}replaceNewPermanentElementWithPlaceholder(e){let t=xt(e);e.replaceWith(t)}replaceCurrentPermanentElementWithClone(e){let t=e.cloneNode(!0);e.replaceWith(t)}replacePlaceholderWithPermanentElement(e){let t=this.getPlaceholderById(e.id);t==null||t.replaceWith(e)}getPlaceholderById(e){return this.placeholders.find(t=>t.content==e)}get placeholders(){return[...document.querySelectorAll("meta[name=turbo-permanent-placeholder][content]")]}};function xt(r){let e=document.createElement("meta");return e.setAttribute("name","turbo-permanent-placeholder"),e.setAttribute("content",r.id),e}var N=class{constructor(e,t,n){this.currentSnapshot=e,this.newSnapshot=t,this.isPreview=n,this.promise=new Promise((i,s)=>this.resolvingFunctions={resolve:i,reject:s})}get shouldRender(){return!0}prepareToRender(){}finishRendering(){this.resolvingFunctions&&(this.resolvingFunctions.resolve(),delete this.resolvingFunctions)}createScriptElement(e){if(e.getAttribute("data-turbo-eval")=="false")return e;{let t=document.createElement("script");return this.cspNonce&&(t.nonce=this.cspNonce),t.textContent=e.textContent,t.async=!1,Ft(t,e),t}}preservingPermanentElements(e){se.preservingPermanentElements(this.permanentElementMap,e)}focusFirstAutofocusableElement(){let e=this.connectedSnapshot.firstAutofocusableElement;Bt(e)&&e.focus()}get connectedSnapshot(){return this.newSnapshot.isConnected?this.newSnapshot:this.currentSnapshot}get currentElement(){return this.currentSnapshot.element}get newElement(){return this.newSnapshot.element}get permanentElementMap(){return this.currentSnapshot.getPermanentElementMapForSnapshot(this.newSnapshot)}get cspNonce(){var e;return(e=document.head.querySelector('meta[name="csp-nonce"]'))===null||e===void 0?void 0:e.getAttribute("content")}};function Ft(r,e){for(let{name:t,value:n}of[...e.attributes])r.setAttribute(t,n)}function Bt(r){return r&&typeof r.focus=="function"}var oe=class extends N{get shouldRender(){return!0}async render(){await B(),this.preservingPermanentElements(()=>{this.loadFrameElement()}),this.scrollFrameIntoView(),await B(),this.focusFirstAutofocusableElement(),await B(),this.activateScriptElements()}loadFrameElement(){var e;let t=document.createRange();t.selectNodeContents(this.currentElement),t.deleteContents();let n=this.newElement,i=(e=n.ownerDocument)===null||e===void 0?void 0:e.createRange();i&&(i.selectNodeContents(n),this.currentElement.appendChild(i.extractContents()))}scrollFrameIntoView(){if(this.currentElement.autoscroll||this.newElement.autoscroll){let e=this.currentElement.firstElementChild,t=It(this.currentElement.getAttribute("data-autoscroll-block"),"end");if(e)return e.scrollIntoView({block:t}),!0}return!1}activateScriptElements(){for(let e of this.newScriptElements){let t=this.createScriptElement(e);e.replaceWith(t)}}get newScriptElements(){return this.currentElement.querySelectorAll("script")}};function It(r,e){return r=="end"||r=="start"||r=="center"||r=="nearest"?r:e}var g=class{constructor(){this.hiding=!1,this.value=0,this.visible=!1,this.trickle=()=>{this.setValue(this.value+Math.random()/100)},this.stylesheetElement=this.createStylesheetElement(),this.progressElement=this.createProgressElement(),this.installStylesheetElement(),this.setValue(0)}static get defaultCSS(){return te` +(()=>{var zo=Object.create;var Ht=Object.defineProperty;var Zo=Object.getOwnPropertyDescriptor;var Jo=Object.getOwnPropertyNames;var Ko=Object.getPrototypeOf,Go=Object.prototype.hasOwnProperty;var Yo=(t,e,r)=>e in t?Ht(t,e,{enumerable:!0,configurable:!0,writable:!0,value:r}):t[e]=r;var Xo=t=>Ht(t,"__esModule",{value:!0});var Qo=(t,e)=>()=>(e||t((e={exports:{}}).exports,e),e.exports);var ea=(t,e,r)=>{if(e&&typeof e=="object"||typeof e=="function")for(let i of Jo(e))!Go.call(t,i)&&i!=="default"&&Ht(t,i,{get:()=>e[i],enumerable:!(r=Zo(e,i))||r.enumerable});return t},ki=t=>ea(Xo(Ht(t!=null?zo(Ko(t)):{},"default",t&&t.__esModule&&"default"in t?{get:()=>t.default,enumerable:!0}:{value:t,enumerable:!0})),t);var Ai=(t,e,r)=>(Yo(t,typeof e!="symbol"?e+"":e,r),r);var ii=Qo(U=>{"use strict";Object.defineProperty(U,"__esModule",{value:!0});function Vn(t,e){for(var r=0;r<e.length;r++){var i=e[r];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(t,i.key,i)}}function oe(t,e,r){return e&&Vn(t.prototype,e),r&&Vn(t,r),t}function k(){return k=Object.assign||function(t){for(var e=1;e<arguments.length;e++){var r=arguments[e];for(var i in r)Object.prototype.hasOwnProperty.call(r,i)&&(t[i]=r[i])}return t},k.apply(this,arguments)}function W(t,e){t.prototype=Object.create(e.prototype),t.prototype.constructor=t,mt(t,e)}function xr(t){return xr=Object.setPrototypeOf?Object.getPrototypeOf:function(r){return r.__proto__||Object.getPrototypeOf(r)},xr(t)}function mt(t,e){return mt=Object.setPrototypeOf||function(i,n){return i.__proto__=n,i},mt(t,e)}function kl(){if(typeof Reflect=="undefined"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(t){return!1}}function Zt(t,e,r){return kl()?Zt=Reflect.construct:Zt=function(n,s,o){var a=[null];a.push.apply(a,s);var l=Function.bind.apply(n,a),u=new l;return o&&mt(u,o.prototype),u},Zt.apply(null,arguments)}function Al(t){return Function.toString.call(t).indexOf("[native code]")!==-1}function Nr(t){var e=typeof Map=="function"?new Map:void 0;return Nr=function(i){if(i===null||!Al(i))return i;if(typeof i!="function")throw new TypeError("Super expression must either be null or a function");if(typeof e!="undefined"){if(e.has(i))return e.get(i);e.set(i,n)}function n(){return Zt(i,arguments,xr(this).constructor)}return n.prototype=Object.create(i.prototype,{constructor:{value:n,enumerable:!1,writable:!0,configurable:!0}}),mt(n,i)},Nr(t)}function Ol(t,e){if(t==null)return{};var r={},i=Object.keys(t),n,s;for(s=0;s<i.length;s++)n=i[s],!(e.indexOf(n)>=0)&&(r[n]=t[n]);return r}function Cl(t,e){if(!!t){if(typeof t=="string")return Bn(t,e);var r=Object.prototype.toString.call(t).slice(8,-1);if(r==="Object"&&t.constructor&&(r=t.constructor.name),r==="Map"||r==="Set")return Array.from(t);if(r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return Bn(t,e)}}function Bn(t,e){(e==null||e>t.length)&&(e=t.length);for(var r=0,i=new Array(e);r<e;r++)i[r]=t[r];return i}function Ce(t,e){var r=typeof Symbol!="undefined"&&t[Symbol.iterator]||t["@@iterator"];if(r)return(r=r.call(t)).next.bind(r);if(Array.isArray(t)||(r=Cl(t))||e&&t&&typeof t.length=="number"){r&&(t=r);var i=0;return function(){return i>=t.length?{done:!0}:{done:!1,value:t[i++]}}}throw new TypeError(`Invalid attempt to iterate non-iterable instance. +In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}var Ne=function(t){W(e,t);function e(){return t.apply(this,arguments)||this}return e}(Nr(Error)),Ll=function(t){W(e,t);function e(r){return t.call(this,"Invalid DateTime: "+r.toMessage())||this}return e}(Ne),Il=function(t){W(e,t);function e(r){return t.call(this,"Invalid Interval: "+r.toMessage())||this}return e}(Ne),Pl=function(t){W(e,t);function e(r){return t.call(this,"Invalid Duration: "+r.toMessage())||this}return e}(Ne),pt=function(t){W(e,t);function e(){return t.apply(this,arguments)||this}return e}(Ne),jn=function(t){W(e,t);function e(r){return t.call(this,"Invalid unit "+r)||this}return e}(Ne),z=function(t){W(e,t);function e(){return t.apply(this,arguments)||this}return e}(Ne),Le=function(t){W(e,t);function e(){return t.call(this,"Zone is an abstract class")||this}return e}(Ne),v="numeric",Q="short",j="long",_r={year:v,month:v,day:v},Un={year:v,month:Q,day:v},Ml={year:v,month:Q,day:v,weekday:Q},qn={year:v,month:j,day:v},$n={year:v,month:j,day:v,weekday:j},Wn={hour:v,minute:v},zn={hour:v,minute:v,second:v},Zn={hour:v,minute:v,second:v,timeZoneName:Q},Jn={hour:v,minute:v,second:v,timeZoneName:j},Kn={hour:v,minute:v,hourCycle:"h23"},Gn={hour:v,minute:v,second:v,hourCycle:"h23"},Yn={hour:v,minute:v,second:v,hourCycle:"h23",timeZoneName:Q},Xn={hour:v,minute:v,second:v,hourCycle:"h23",timeZoneName:j},Qn={year:v,month:v,day:v,hour:v,minute:v},es={year:v,month:v,day:v,hour:v,minute:v,second:v},ts={year:v,month:Q,day:v,hour:v,minute:v},rs={year:v,month:Q,day:v,hour:v,minute:v,second:v},Rl={year:v,month:Q,day:v,weekday:Q,hour:v,minute:v},is={year:v,month:j,day:v,hour:v,minute:v,timeZoneName:Q},ns={year:v,month:j,day:v,hour:v,minute:v,second:v,timeZoneName:Q},ss={year:v,month:j,day:v,weekday:j,hour:v,minute:v,timeZoneName:j},os={year:v,month:j,day:v,weekday:j,hour:v,minute:v,second:v,timeZoneName:j};function A(t){return typeof t=="undefined"}function _e(t){return typeof t=="number"}function Jt(t){return typeof t=="number"&&t%1==0}function Dl(t){return typeof t=="string"}function xl(t){return Object.prototype.toString.call(t)==="[object Date]"}function as(){try{return typeof Intl!="undefined"&&!!Intl.RelativeTimeFormat}catch(t){return!1}}function Nl(t){return Array.isArray(t)?t:[t]}function ls(t,e,r){if(t.length!==0)return t.reduce(function(i,n){var s=[e(n),n];return i&&r(i[0],s[0])===i[0]?i:s},null)[1]}function _l(t,e){return e.reduce(function(r,i){return r[i]=t[i],r},{})}function Xe(t,e){return Object.prototype.hasOwnProperty.call(t,e)}function ge(t,e,r){return Jt(t)&&t>=e&&t<=r}function Fl(t,e){return t-e*Math.floor(t/e)}function Qe(t,e){e===void 0&&(e=2);var r=t<0?"-":"",i=r?t*-1:t,n;return i.toString().length<e?n=("0".repeat(e)+i).slice(-e):n=i.toString(),""+r+n}function x(t){if(!(A(t)||t===null||t===""))return parseInt(t,10)}function Fr(t){if(!(A(t)||t===null||t==="")){var e=parseFloat("0."+t)*1e3;return Math.floor(e)}}function Hr(t,e,r){r===void 0&&(r=!1);var i=Math.pow(10,e),n=r?Math.trunc:Math.round;return n(t*i)/i}function gt(t){return t%4==0&&(t%100!=0||t%400==0)}function vt(t){return gt(t)?366:365}function Kt(t,e){var r=Fl(e-1,12)+1,i=t+(e-r)/12;return r===2?gt(i)?29:28:[31,null,31,30,31,30,31,31,30,31,30,31][r-1]}function Vr(t){var e=Date.UTC(t.year,t.month-1,t.day,t.hour,t.minute,t.second,t.millisecond);return t.year<100&&t.year>=0&&(e=new Date(e),e.setUTCFullYear(e.getUTCFullYear()-1900)),+e}function Gt(t){var e=(t+Math.floor(t/4)-Math.floor(t/100)+Math.floor(t/400))%7,r=t-1,i=(r+Math.floor(r/4)-Math.floor(r/100)+Math.floor(r/400))%7;return e===4||i===3?53:52}function Br(t){return t>99?t:t>60?1900+t:2e3+t}function us(t,e,r,i){i===void 0&&(i=null);var n=new Date(t),s={hourCycle:"h23",year:"numeric",month:"2-digit",day:"2-digit",hour:"2-digit",minute:"2-digit"};i&&(s.timeZone=i);var o=k({timeZoneName:e},s),a=new Intl.DateTimeFormat(r,o).formatToParts(n).find(function(l){return l.type.toLowerCase()==="timezonename"});return a?a.value:null}function Yt(t,e){var r=parseInt(t,10);Number.isNaN(r)&&(r=0);var i=parseInt(e,10)||0,n=r<0||Object.is(r,-0)?-i:i;return r*60+n}function cs(t){var e=Number(t);if(typeof t=="boolean"||t===""||Number.isNaN(e))throw new z("Invalid unit value "+t);return e}function Xt(t,e){var r={};for(var i in t)if(Xe(t,i)){var n=t[i];if(n==null)continue;r[e(i)]=cs(n)}return r}function Qt(t,e){var r=Math.trunc(Math.abs(t/60)),i=Math.trunc(Math.abs(t%60)),n=t>=0?"+":"-";switch(e){case"short":return""+n+Qe(r,2)+":"+Qe(i,2);case"narrow":return""+n+r+(i>0?":"+i:"");case"techie":return""+n+Qe(r,2)+Qe(i,2);default:throw new RangeError("Value format "+e+" is out of range for property format")}}function er(t){return _l(t,["hour","minute","second","millisecond"])}var hs=/[A-Za-z_+-]{1,256}(:?\/[A-Za-z_+-]{1,256}(\/[A-Za-z_+-]{1,256})?)?/,Hl=["January","February","March","April","May","June","July","August","September","October","November","December"],ds=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],Vl=["J","F","M","A","M","J","J","A","S","O","N","D"];function fs(t){switch(t){case"narrow":return[].concat(Vl);case"short":return[].concat(ds);case"long":return[].concat(Hl);case"numeric":return["1","2","3","4","5","6","7","8","9","10","11","12"];case"2-digit":return["01","02","03","04","05","06","07","08","09","10","11","12"];default:return null}}var ms=["Monday","Tuesday","Wednesday","Thursday","Friday","Saturday","Sunday"],ps=["Mon","Tue","Wed","Thu","Fri","Sat","Sun"],Bl=["M","T","W","T","F","S","S"];function gs(t){switch(t){case"narrow":return[].concat(Bl);case"short":return[].concat(ps);case"long":return[].concat(ms);case"numeric":return["1","2","3","4","5","6","7"];default:return null}}var vs=["AM","PM"],jl=["Before Christ","Anno Domini"],Ul=["BC","AD"],ql=["B","A"];function ys(t){switch(t){case"narrow":return[].concat(ql);case"short":return[].concat(Ul);case"long":return[].concat(jl);default:return null}}function $l(t){return vs[t.hour<12?0:1]}function Wl(t,e){return gs(e)[t.weekday-1]}function zl(t,e){return fs(e)[t.month-1]}function Zl(t,e){return ys(e)[t.year<0?0:1]}function Jl(t,e,r,i){r===void 0&&(r="always"),i===void 0&&(i=!1);var n={years:["year","yr."],quarters:["quarter","qtr."],months:["month","mo."],weeks:["week","wk."],days:["day","day","days"],hours:["hour","hr."],minutes:["minute","min."],seconds:["second","sec."]},s=["hours","minutes","seconds"].indexOf(t)===-1;if(r==="auto"&&s){var o=t==="days";switch(e){case 1:return o?"tomorrow":"next "+n[t][0];case-1:return o?"yesterday":"last "+n[t][0];case 0:return o?"today":"this "+n[t][0]}}var a=Object.is(e,-0)||e<0,l=Math.abs(e),u=l===1,c=n[t],h=i?u?c[1]:c[2]||c[1]:u?n[t][0]:t;return a?l+" "+h+" ago":"in "+l+" "+h}function bs(t,e){for(var r="",i=Ce(t),n;!(n=i()).done;){var s=n.value;s.literal?r+=s.val:r+=e(s.val)}return r}var Kl={D:_r,DD:Un,DDD:qn,DDDD:$n,t:Wn,tt:zn,ttt:Zn,tttt:Jn,T:Kn,TT:Gn,TTT:Yn,TTTT:Xn,f:Qn,ff:ts,fff:is,ffff:ss,F:es,FF:rs,FFF:ns,FFFF:os},ve=function(){t.create=function(i,n){return n===void 0&&(n={}),new t(i,n)},t.parseFormat=function(i){for(var n=null,s="",o=!1,a=[],l=0;l<i.length;l++){var u=i.charAt(l);u==="'"?(s.length>0&&a.push({literal:o,val:s}),n=null,s="",o=!o):o||u===n?s+=u:(s.length>0&&a.push({literal:!1,val:s}),s=u,n=u)}return s.length>0&&a.push({literal:o,val:s}),a},t.macroTokenToFormatOpts=function(i){return Kl[i]};function t(r,i){this.opts=i,this.loc=r,this.systemLoc=null}var e=t.prototype;return e.formatWithSystemDefault=function(i,n){this.systemLoc===null&&(this.systemLoc=this.loc.redefaultToSystem());var s=this.systemLoc.dtFormatter(i,k({},this.opts,n));return s.format()},e.formatDateTime=function(i,n){n===void 0&&(n={});var s=this.loc.dtFormatter(i,k({},this.opts,n));return s.format()},e.formatDateTimeParts=function(i,n){n===void 0&&(n={});var s=this.loc.dtFormatter(i,k({},this.opts,n));return s.formatToParts()},e.resolvedOptions=function(i,n){n===void 0&&(n={});var s=this.loc.dtFormatter(i,k({},this.opts,n));return s.resolvedOptions()},e.num=function(i,n){if(n===void 0&&(n=0),this.opts.forceSimple)return Qe(i,n);var s=k({},this.opts);return n>0&&(s.padTo=n),this.loc.numberFormatter(s).format(i)},e.formatDateTimeFromString=function(i,n){var s=this,o=this.loc.listingMode()==="en",a=this.loc.outputCalendar&&this.loc.outputCalendar!=="gregory",l=function(f,S){return s.loc.extract(i,f,S)},u=function(f){return i.isOffsetFixed&&i.offset===0&&f.allowZ?"Z":i.isValid?i.zone.formatOffset(i.ts,f.format):""},c=function(){return o?$l(i):l({hour:"numeric",hourCycle:"h12"},"dayperiod")},h=function(f,S){return o?zl(i,f):l(S?{month:f}:{month:f,day:"numeric"},"month")},d=function(f,S){return o?Wl(i,f):l(S?{weekday:f}:{weekday:f,month:"long",day:"numeric"},"weekday")},m=function(f){var S=t.macroTokenToFormatOpts(f);return S?s.formatWithSystemDefault(i,S):f},p=function(f){return o?Zl(i,f):l({era:f},"era")},y=function(f){switch(f){case"S":return s.num(i.millisecond);case"u":case"SSS":return s.num(i.millisecond,3);case"s":return s.num(i.second);case"ss":return s.num(i.second,2);case"m":return s.num(i.minute);case"mm":return s.num(i.minute,2);case"h":return s.num(i.hour%12==0?12:i.hour%12);case"hh":return s.num(i.hour%12==0?12:i.hour%12,2);case"H":return s.num(i.hour);case"HH":return s.num(i.hour,2);case"Z":return u({format:"narrow",allowZ:s.opts.allowZ});case"ZZ":return u({format:"short",allowZ:s.opts.allowZ});case"ZZZ":return u({format:"techie",allowZ:s.opts.allowZ});case"ZZZZ":return i.zone.offsetName(i.ts,{format:"short",locale:s.loc.locale});case"ZZZZZ":return i.zone.offsetName(i.ts,{format:"long",locale:s.loc.locale});case"z":return i.zoneName;case"a":return c();case"d":return a?l({day:"numeric"},"day"):s.num(i.day);case"dd":return a?l({day:"2-digit"},"day"):s.num(i.day,2);case"c":return s.num(i.weekday);case"ccc":return d("short",!0);case"cccc":return d("long",!0);case"ccccc":return d("narrow",!0);case"E":return s.num(i.weekday);case"EEE":return d("short",!1);case"EEEE":return d("long",!1);case"EEEEE":return d("narrow",!1);case"L":return a?l({month:"numeric",day:"numeric"},"month"):s.num(i.month);case"LL":return a?l({month:"2-digit",day:"numeric"},"month"):s.num(i.month,2);case"LLL":return h("short",!0);case"LLLL":return h("long",!0);case"LLLLL":return h("narrow",!0);case"M":return a?l({month:"numeric"},"month"):s.num(i.month);case"MM":return a?l({month:"2-digit"},"month"):s.num(i.month,2);case"MMM":return h("short",!1);case"MMMM":return h("long",!1);case"MMMMM":return h("narrow",!1);case"y":return a?l({year:"numeric"},"year"):s.num(i.year);case"yy":return a?l({year:"2-digit"},"year"):s.num(i.year.toString().slice(-2),2);case"yyyy":return a?l({year:"numeric"},"year"):s.num(i.year,4);case"yyyyyy":return a?l({year:"numeric"},"year"):s.num(i.year,6);case"G":return p("short");case"GG":return p("long");case"GGGGG":return p("narrow");case"kk":return s.num(i.weekYear.toString().slice(-2),2);case"kkkk":return s.num(i.weekYear,4);case"W":return s.num(i.weekNumber);case"WW":return s.num(i.weekNumber,2);case"o":return s.num(i.ordinal);case"ooo":return s.num(i.ordinal,3);case"q":return s.num(i.quarter);case"qq":return s.num(i.quarter,2);case"X":return s.num(Math.floor(i.ts/1e3));case"x":return s.num(i.ts);default:return m(f)}};return bs(t.parseFormat(n),y)},e.formatDurationFromString=function(i,n){var s=this,o=function(d){switch(d[0]){case"S":return"millisecond";case"s":return"second";case"m":return"minute";case"h":return"hour";case"d":return"day";case"M":return"month";case"y":return"year";default:return null}},a=function(d){return function(m){var p=o(m);return p?s.num(d.get(p),m.length):m}},l=t.parseFormat(n),u=l.reduce(function(h,d){var m=d.literal,p=d.val;return m?h:h.concat(p)},[]),c=i.shiftTo.apply(i,u.map(o).filter(function(h){return h}));return bs(l,a(c))},t}(),ee=function(){function t(r,i){this.reason=r,this.explanation=i}var e=t.prototype;return e.toMessage=function(){return this.explanation?this.reason+": "+this.explanation:this.reason},t}(),et=function(){function t(){}var e=t.prototype;return e.offsetName=function(i,n){throw new Le},e.formatOffset=function(i,n){throw new Le},e.offset=function(i){throw new Le},e.equals=function(i){throw new Le},oe(t,[{key:"type",get:function(){throw new Le}},{key:"name",get:function(){throw new Le}},{key:"isUniversal",get:function(){throw new Le}},{key:"isValid",get:function(){throw new Le}}]),t}(),jr=null,ws=function(t){W(e,t);function e(){return t.apply(this,arguments)||this}var r=e.prototype;return r.offsetName=function(n,s){var o=s.format,a=s.locale;return us(n,o,a)},r.formatOffset=function(n,s){return Qt(this.offset(n),s)},r.offset=function(n){return-new Date(n).getTimezoneOffset()},r.equals=function(n){return n.type==="system"},oe(e,[{key:"type",get:function(){return"system"}},{key:"name",get:function(){return new Intl.DateTimeFormat().resolvedOptions().timeZone}},{key:"isUniversal",get:function(){return!1}},{key:"isValid",get:function(){return!0}}],[{key:"instance",get:function(){return jr===null&&(jr=new e),jr}}]),e}(et),Gl=RegExp("^"+hs.source+"$"),tr={};function Yl(t){return tr[t]||(tr[t]=new Intl.DateTimeFormat("en-US",{hourCycle:"h23",timeZone:t,year:"numeric",month:"2-digit",day:"2-digit",hour:"2-digit",minute:"2-digit",second:"2-digit"})),tr[t]}var Xl={year:0,month:1,day:2,hour:3,minute:4,second:5};function Ql(t,e){var r=t.format(e).replace(/\u200E/g,""),i=/(\d+)\/(\d+)\/(\d+),? (\d+):(\d+):(\d+)/.exec(r),n=i[1],s=i[2],o=i[3],a=i[4],l=i[5],u=i[6];return[o,n,s,a,l,u]}function eu(t,e){for(var r=t.formatToParts(e),i=[],n=0;n<r.length;n++){var s=r[n],o=s.type,a=s.value,l=Xl[o];A(l)||(i[l]=parseInt(a,10))}return i}var rr={},ae=function(t){W(e,t),e.create=function(n){return rr[n]||(rr[n]=new e(n)),rr[n]},e.resetCache=function(){rr={},tr={}},e.isValidSpecifier=function(n){return!!(n&&n.match(Gl))},e.isValidZone=function(n){try{return new Intl.DateTimeFormat("en-US",{timeZone:n}).format(),!0}catch(s){return!1}},e.parseGMTOffset=function(n){if(n){var s=n.match(/^Etc\/GMT(0|[+-]\d{1,2})$/i);if(s)return-60*parseInt(s[1])}return null};function e(i){var n;return n=t.call(this)||this,n.zoneName=i,n.valid=e.isValidZone(i),n}var r=e.prototype;return r.offsetName=function(n,s){var o=s.format,a=s.locale;return us(n,o,a,this.name)},r.formatOffset=function(n,s){return Qt(this.offset(n),s)},r.offset=function(n){var s=new Date(n);if(isNaN(s))return NaN;var o=Yl(this.name),a=o.formatToParts?eu(o,s):Ql(o,s),l=a[0],u=a[1],c=a[2],h=a[3],d=a[4],m=a[5],p=Vr({year:l,month:u,day:c,hour:h,minute:d,second:m,millisecond:0}),y=+s,b=y%1e3;return y-=b>=0?b:1e3+b,(p-y)/(60*1e3)},r.equals=function(n){return n.type==="iana"&&n.name===this.name},oe(e,[{key:"type",get:function(){return"iana"}},{key:"name",get:function(){return this.zoneName}},{key:"isUniversal",get:function(){return!1}},{key:"isValid",get:function(){return this.valid}}]),e}(et),Ur=null,Z=function(t){W(e,t),e.instance=function(n){return n===0?e.utcInstance:new e(n)},e.parseSpecifier=function(n){if(n){var s=n.match(/^utc(?:([+-]\d{1,2})(?::(\d{2}))?)?$/i);if(s)return new e(Yt(s[1],s[2]))}return null};function e(i){var n;return n=t.call(this)||this,n.fixed=i,n}var r=e.prototype;return r.offsetName=function(){return this.name},r.formatOffset=function(n,s){return Qt(this.fixed,s)},r.offset=function(){return this.fixed},r.equals=function(n){return n.type==="fixed"&&n.fixed===this.fixed},oe(e,[{key:"type",get:function(){return"fixed"}},{key:"name",get:function(){return this.fixed===0?"UTC":"UTC"+Qt(this.fixed,"narrow")}},{key:"isUniversal",get:function(){return!0}},{key:"isValid",get:function(){return!0}}],[{key:"utcInstance",get:function(){return Ur===null&&(Ur=new e(0)),Ur}}]),e}(et),qr=function(t){W(e,t);function e(i){var n;return n=t.call(this)||this,n.zoneName=i,n}var r=e.prototype;return r.offsetName=function(){return null},r.formatOffset=function(){return""},r.offset=function(){return NaN},r.equals=function(){return!1},oe(e,[{key:"type",get:function(){return"invalid"}},{key:"name",get:function(){return this.zoneName}},{key:"isUniversal",get:function(){return!1}},{key:"isValid",get:function(){return!1}}]),e}(et);function Ie(t,e){var r;if(A(t)||t===null)return e;if(t instanceof et)return t;if(Dl(t)){var i=t.toLowerCase();return i==="local"||i==="system"?e:i==="utc"||i==="gmt"?Z.utcInstance:(r=ae.parseGMTOffset(t))!=null?Z.instance(r):ae.isValidSpecifier(i)?ae.create(t):Z.parseSpecifier(i)||new qr(t)}else return _e(t)?Z.instance(t):typeof t=="object"&&t.offset&&typeof t.offset=="number"?t:new qr(t)}var Ss=function(){return Date.now()},Es="system",Ts=null,ks=null,As=null,Os,L=function(){function t(){}return t.resetCaches=function(){M.resetCache(),ae.resetCache()},oe(t,null,[{key:"now",get:function(){return Ss},set:function(r){Ss=r}},{key:"defaultZone",get:function(){return Ie(Es,ws.instance)},set:function(r){Es=r}},{key:"defaultLocale",get:function(){return Ts},set:function(r){Ts=r}},{key:"defaultNumberingSystem",get:function(){return ks},set:function(r){ks=r}},{key:"defaultOutputCalendar",get:function(){return As},set:function(r){As=r}},{key:"throwOnInvalid",get:function(){return Os},set:function(r){Os=r}}]),t}(),tu=["base"],$r={};function Wr(t,e){e===void 0&&(e={});var r=JSON.stringify([t,e]),i=$r[r];return i||(i=new Intl.DateTimeFormat(t,e),$r[r]=i),i}var zr={};function ru(t,e){e===void 0&&(e={});var r=JSON.stringify([t,e]),i=zr[r];return i||(i=new Intl.NumberFormat(t,e),zr[r]=i),i}var Zr={};function iu(t,e){e===void 0&&(e={});var r=e;r.base;var i=Ol(r,tu),n=JSON.stringify([t,i]),s=Zr[n];return s||(s=new Intl.RelativeTimeFormat(t,e),Zr[n]=s),s}var yt=null;function nu(){return yt||(yt=new Intl.DateTimeFormat().resolvedOptions().locale,yt)}function su(t){var e=t.indexOf("-u-");if(e===-1)return[t];var r,i=t.substring(0,e);try{r=Wr(t).resolvedOptions()}catch(a){r=Wr(i).resolvedOptions()}var n=r,s=n.numberingSystem,o=n.calendar;return[i,s,o]}function ou(t,e,r){return(r||e)&&(t+="-u",r&&(t+="-ca-"+r),e&&(t+="-nu-"+e)),t}function au(t){for(var e=[],r=1;r<=12;r++){var i=I.utc(2016,r,1);e.push(t(i))}return e}function lu(t){for(var e=[],r=1;r<=7;r++){var i=I.utc(2016,11,13+r);e.push(t(i))}return e}function ir(t,e,r,i,n){var s=t.listingMode(r);return s==="error"?null:s==="en"?i(e):n(e)}function uu(t){return t.numberingSystem&&t.numberingSystem!=="latn"?!1:t.numberingSystem==="latn"||!t.locale||t.locale.startsWith("en")||new Intl.DateTimeFormat(t.intl).resolvedOptions().numberingSystem==="latn"}var cu=function(){function t(r,i,n){if(this.padTo=n.padTo||0,this.floor=n.floor||!1,!i){var s={useGrouping:!1};n.padTo>0&&(s.minimumIntegerDigits=n.padTo),this.inf=ru(r,s)}}var e=t.prototype;return e.format=function(i){if(this.inf){var n=this.floor?Math.floor(i):i;return this.inf.format(n)}else{var s=this.floor?Math.floor(i):Hr(i,3);return Qe(s,this.padTo)}},t}(),hu=function(){function t(r,i,n){this.opts=n;var s;if(r.zone.isUniversal){var o=-1*(r.offset/60),a=o>=0?"Etc/GMT+"+o:"Etc/GMT"+o,l=ae.isValidZone(a);r.offset!==0&&l?(s=a,this.dt=r):(s="UTC",n.timeZoneName?this.dt=r:this.dt=r.offset===0?r:I.fromMillis(r.ts+r.offset*60*1e3))}else r.zone.type==="system"?this.dt=r:(this.dt=r,s=r.zone.name);var u=k({},this.opts);s&&(u.timeZone=s),this.dtf=Wr(i,u)}var e=t.prototype;return e.format=function(){return this.dtf.format(this.dt.toJSDate())},e.formatToParts=function(){return this.dtf.formatToParts(this.dt.toJSDate())},e.resolvedOptions=function(){return this.dtf.resolvedOptions()},t}(),du=function(){function t(r,i,n){this.opts=k({style:"long"},n),!i&&as()&&(this.rtf=iu(r,n))}var e=t.prototype;return e.format=function(i,n){return this.rtf?this.rtf.format(i,n):Jl(n,i,this.opts.numeric,this.opts.style!=="long")},e.formatToParts=function(i,n){return this.rtf?this.rtf.formatToParts(i,n):[]},t}(),M=function(){t.fromOpts=function(i){return t.create(i.locale,i.numberingSystem,i.outputCalendar,i.defaultToEN)},t.create=function(i,n,s,o){o===void 0&&(o=!1);var a=i||L.defaultLocale,l=a||(o?"en-US":nu()),u=n||L.defaultNumberingSystem,c=s||L.defaultOutputCalendar;return new t(l,u,c,a)},t.resetCache=function(){yt=null,$r={},zr={},Zr={}},t.fromObject=function(i){var n=i===void 0?{}:i,s=n.locale,o=n.numberingSystem,a=n.outputCalendar;return t.create(s,o,a)};function t(r,i,n,s){var o=su(r),a=o[0],l=o[1],u=o[2];this.locale=a,this.numberingSystem=i||l||null,this.outputCalendar=n||u||null,this.intl=ou(this.locale,this.numberingSystem,this.outputCalendar),this.weekdaysCache={format:{},standalone:{}},this.monthsCache={format:{},standalone:{}},this.meridiemCache=null,this.eraCache={},this.specifiedLocale=s,this.fastNumbersCached=null}var e=t.prototype;return e.listingMode=function(i){var n=this.isEnglish(),s=(this.numberingSystem===null||this.numberingSystem==="latn")&&(this.outputCalendar===null||this.outputCalendar==="gregory");return n&&s?"en":"intl"},e.clone=function(i){return!i||Object.getOwnPropertyNames(i).length===0?this:t.create(i.locale||this.specifiedLocale,i.numberingSystem||this.numberingSystem,i.outputCalendar||this.outputCalendar,i.defaultToEN||!1)},e.redefaultToEN=function(i){return i===void 0&&(i={}),this.clone(k({},i,{defaultToEN:!0}))},e.redefaultToSystem=function(i){return i===void 0&&(i={}),this.clone(k({},i,{defaultToEN:!1}))},e.months=function(i,n,s){var o=this;return n===void 0&&(n=!1),s===void 0&&(s=!0),ir(this,i,s,fs,function(){var a=n?{month:i,day:"numeric"}:{month:i},l=n?"format":"standalone";return o.monthsCache[l][i]||(o.monthsCache[l][i]=au(function(u){return o.extract(u,a,"month")})),o.monthsCache[l][i]})},e.weekdays=function(i,n,s){var o=this;return n===void 0&&(n=!1),s===void 0&&(s=!0),ir(this,i,s,gs,function(){var a=n?{weekday:i,year:"numeric",month:"long",day:"numeric"}:{weekday:i},l=n?"format":"standalone";return o.weekdaysCache[l][i]||(o.weekdaysCache[l][i]=lu(function(u){return o.extract(u,a,"weekday")})),o.weekdaysCache[l][i]})},e.meridiems=function(i){var n=this;return i===void 0&&(i=!0),ir(this,void 0,i,function(){return vs},function(){if(!n.meridiemCache){var s={hour:"numeric",hourCycle:"h12"};n.meridiemCache=[I.utc(2016,11,13,9),I.utc(2016,11,13,19)].map(function(o){return n.extract(o,s,"dayperiod")})}return n.meridiemCache})},e.eras=function(i,n){var s=this;return n===void 0&&(n=!0),ir(this,i,n,ys,function(){var o={era:i};return s.eraCache[i]||(s.eraCache[i]=[I.utc(-40,1,1),I.utc(2017,1,1)].map(function(a){return s.extract(a,o,"era")})),s.eraCache[i]})},e.extract=function(i,n,s){var o=this.dtFormatter(i,n),a=o.formatToParts(),l=a.find(function(u){return u.type.toLowerCase()===s});return l?l.value:null},e.numberFormatter=function(i){return i===void 0&&(i={}),new cu(this.intl,i.forceSimple||this.fastNumbers,i)},e.dtFormatter=function(i,n){return n===void 0&&(n={}),new hu(i,this.intl,n)},e.relFormatter=function(i){return i===void 0&&(i={}),new du(this.intl,this.isEnglish(),i)},e.isEnglish=function(){return this.locale==="en"||this.locale.toLowerCase()==="en-us"||new Intl.DateTimeFormat(this.intl).resolvedOptions().locale.startsWith("en-us")},e.equals=function(i){return this.locale===i.locale&&this.numberingSystem===i.numberingSystem&&this.outputCalendar===i.outputCalendar},oe(t,[{key:"fastNumbers",get:function(){return this.fastNumbersCached==null&&(this.fastNumbersCached=uu(this)),this.fastNumbersCached}}]),t}();function tt(){for(var t=arguments.length,e=new Array(t),r=0;r<t;r++)e[r]=arguments[r];var i=e.reduce(function(n,s){return n+s.source},"");return RegExp("^"+i+"$")}function Fe(){for(var t=arguments.length,e=new Array(t),r=0;r<t;r++)e[r]=arguments[r];return function(i){return e.reduce(function(n,s){var o=n[0],a=n[1],l=n[2],u=s(i,l),c=u[0],h=u[1],d=u[2];return[k({},o,c),a||h,d]},[{},null,1]).slice(0,2)}}function rt(t){if(t==null)return[null,null];for(var e=arguments.length,r=new Array(e>1?e-1:0),i=1;i<e;i++)r[i-1]=arguments[i];for(var n=0,s=r;n<s.length;n++){var o=s[n],a=o[0],l=o[1],u=a.exec(t);if(u)return l(u)}return[null,null]}function Cs(){for(var t=arguments.length,e=new Array(t),r=0;r<t;r++)e[r]=arguments[r];return function(i,n){var s={},o;for(o=0;o<e.length;o++)s[e[o]]=x(i[n+o]);return[s,null,n+o]}}var Ls=/(?:(Z)|([+-]\d\d)(?::?(\d\d))?)/,Jr=/(\d\d)(?::?(\d\d)(?::?(\d\d)(?:[.,](\d{1,30}))?)?)?/,Is=RegExp(""+Jr.source+Ls.source+"?"),Kr=RegExp("(?:T"+Is.source+")?"),fu=/([+-]\d{6}|\d{4})(?:-?(\d\d)(?:-?(\d\d))?)?/,mu=/(\d{4})-?W(\d\d)(?:-?(\d))?/,pu=/(\d{4})-?(\d{3})/,gu=Cs("weekYear","weekNumber","weekDay"),vu=Cs("year","ordinal"),yu=/(\d{4})-(\d\d)-(\d\d)/,Ps=RegExp(Jr.source+" ?(?:"+Ls.source+"|("+hs.source+"))?"),bu=RegExp("(?: "+Ps.source+")?");function it(t,e,r){var i=t[e];return A(i)?r:x(i)}function Ms(t,e){var r={year:it(t,e),month:it(t,e+1,1),day:it(t,e+2,1)};return[r,null,e+3]}function He(t,e){var r={hours:it(t,e,0),minutes:it(t,e+1,0),seconds:it(t,e+2,0),milliseconds:Fr(t[e+3])};return[r,null,e+4]}function nt(t,e){var r=!t[e]&&!t[e+1],i=Yt(t[e+1],t[e+2]),n=r?null:Z.instance(i);return[{},n,e+3]}function Rs(t,e){var r=t[e]?ae.create(t[e]):null;return[{},r,e+1]}var wu=RegExp("^T?"+Jr.source+"$"),Su=/^-?P(?:(?:(-?\d{1,9})Y)?(?:(-?\d{1,9})M)?(?:(-?\d{1,9})W)?(?:(-?\d{1,9})D)?(?:T(?:(-?\d{1,9})H)?(?:(-?\d{1,9})M)?(?:(-?\d{1,20})(?:[.,](-?\d{1,9}))?S)?)?)$/;function Eu(t){var e=t[0],r=t[1],i=t[2],n=t[3],s=t[4],o=t[5],a=t[6],l=t[7],u=t[8],c=e[0]==="-",h=l&&l[0]==="-",d=function(p,y){return y===void 0&&(y=!1),p!==void 0&&(y||p&&c)?-p:p};return[{years:d(x(r)),months:d(x(i)),weeks:d(x(n)),days:d(x(s)),hours:d(x(o)),minutes:d(x(a)),seconds:d(x(l),l==="-0"),milliseconds:d(Fr(u),h)}]}var Tu={GMT:0,EDT:-4*60,EST:-5*60,CDT:-5*60,CST:-6*60,MDT:-6*60,MST:-7*60,PDT:-7*60,PST:-8*60};function Gr(t,e,r,i,n,s,o){var a={year:e.length===2?Br(x(e)):x(e),month:ds.indexOf(r)+1,day:x(i),hour:x(n),minute:x(s)};return o&&(a.second=x(o)),t&&(a.weekday=t.length>3?ms.indexOf(t)+1:ps.indexOf(t)+1),a}var ku=/^(?:(Mon|Tue|Wed|Thu|Fri|Sat|Sun),\s)?(\d{1,2})\s(Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec)\s(\d{2,4})\s(\d\d):(\d\d)(?::(\d\d))?\s(?:(UT|GMT|[ECMP][SD]T)|([Zz])|(?:([+-]\d\d)(\d\d)))$/;function Au(t){var e=t[1],r=t[2],i=t[3],n=t[4],s=t[5],o=t[6],a=t[7],l=t[8],u=t[9],c=t[10],h=t[11],d=Gr(e,n,i,r,s,o,a),m;return l?m=Tu[l]:u?m=0:m=Yt(c,h),[d,new Z(m)]}function Ou(t){return t.replace(/\([^)]*\)|[\n\t]/g," ").replace(/(\s\s+)/g," ").trim()}var Cu=/^(Mon|Tue|Wed|Thu|Fri|Sat|Sun), (\d\d) (Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec) (\d{4}) (\d\d):(\d\d):(\d\d) GMT$/,Lu=/^(Monday|Tuesday|Wedsday|Thursday|Friday|Saturday|Sunday), (\d\d)-(Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec)-(\d\d) (\d\d):(\d\d):(\d\d) GMT$/,Iu=/^(Mon|Tue|Wed|Thu|Fri|Sat|Sun) (Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec) ( \d|\d\d) (\d\d):(\d\d):(\d\d) (\d{4})$/;function Ds(t){var e=t[1],r=t[2],i=t[3],n=t[4],s=t[5],o=t[6],a=t[7],l=Gr(e,n,i,r,s,o,a);return[l,Z.utcInstance]}function Pu(t){var e=t[1],r=t[2],i=t[3],n=t[4],s=t[5],o=t[6],a=t[7],l=Gr(e,a,r,i,n,s,o);return[l,Z.utcInstance]}var Mu=tt(fu,Kr),Ru=tt(mu,Kr),Du=tt(pu,Kr),xu=tt(Is),Nu=Fe(Ms,He,nt),_u=Fe(gu,He,nt),Fu=Fe(vu,He,nt),Hu=Fe(He,nt);function Vu(t){return rt(t,[Mu,Nu],[Ru,_u],[Du,Fu],[xu,Hu])}function Bu(t){return rt(Ou(t),[ku,Au])}function ju(t){return rt(t,[Cu,Ds],[Lu,Ds],[Iu,Pu])}function Uu(t){return rt(t,[Su,Eu])}var qu=Fe(He);function $u(t){return rt(t,[wu,qu])}var Wu=tt(yu,bu),zu=tt(Ps),Zu=Fe(Ms,He,nt,Rs),Ju=Fe(He,nt,Rs);function Ku(t){return rt(t,[Wu,Zu],[zu,Ju])}var Gu="Invalid Duration",xs={weeks:{days:7,hours:7*24,minutes:7*24*60,seconds:7*24*60*60,milliseconds:7*24*60*60*1e3},days:{hours:24,minutes:24*60,seconds:24*60*60,milliseconds:24*60*60*1e3},hours:{minutes:60,seconds:60*60,milliseconds:60*60*1e3},minutes:{seconds:60,milliseconds:60*1e3},seconds:{milliseconds:1e3}},Yu=k({years:{quarters:4,months:12,weeks:52,days:365,hours:365*24,minutes:365*24*60,seconds:365*24*60*60,milliseconds:365*24*60*60*1e3},quarters:{months:3,weeks:13,days:91,hours:91*24,minutes:91*24*60,seconds:91*24*60*60,milliseconds:91*24*60*60*1e3},months:{weeks:4,days:30,hours:30*24,minutes:30*24*60,seconds:30*24*60*60,milliseconds:30*24*60*60*1e3}},xs),J=146097/400,st=146097/4800,Xu=k({years:{quarters:4,months:12,weeks:J/7,days:J,hours:J*24,minutes:J*24*60,seconds:J*24*60*60,milliseconds:J*24*60*60*1e3},quarters:{months:3,weeks:J/28,days:J/4,hours:J*24/4,minutes:J*24*60/4,seconds:J*24*60*60/4,milliseconds:J*24*60*60*1e3/4},months:{weeks:st/7,days:st,hours:st*24,minutes:st*24*60,seconds:st*24*60*60,milliseconds:st*24*60*60*1e3}},xs),ot=["years","quarters","months","weeks","days","hours","minutes","seconds","milliseconds"],Qu=ot.slice(0).reverse();function Ve(t,e,r){r===void 0&&(r=!1);var i={values:r?e.values:k({},t.values,e.values||{}),loc:t.loc.clone(e.loc),conversionAccuracy:e.conversionAccuracy||t.conversionAccuracy};return new N(i)}function ec(t){return t<0?Math.floor(t):Math.ceil(t)}function Ns(t,e,r,i,n){var s=t[n][r],o=e[r]/s,a=Math.sign(o)===Math.sign(i[n]),l=!a&&i[n]!==0&&Math.abs(o)<=1?ec(o):Math.trunc(o);i[n]+=l,e[r]-=l*s}function tc(t,e){Qu.reduce(function(r,i){return A(e[i])?r:(r&&Ns(t,e,r,e,i),i)},null)}var N=function(){function t(r){var i=r.conversionAccuracy==="longterm"||!1;this.values=r.values,this.loc=r.loc||M.create(),this.conversionAccuracy=i?"longterm":"casual",this.invalid=r.invalid||null,this.matrix=i?Xu:Yu,this.isLuxonDuration=!0}t.fromMillis=function(i,n){return t.fromObject({milliseconds:i},n)},t.fromObject=function(i,n){if(n===void 0&&(n={}),i==null||typeof i!="object")throw new z("Duration.fromObject: argument expected to be an object, got "+(i===null?"null":typeof i));return new t({values:Xt(i,t.normalizeUnit),loc:M.fromObject(n),conversionAccuracy:n.conversionAccuracy})},t.fromISO=function(i,n){var s=Uu(i),o=s[0];return o?t.fromObject(o,n):t.invalid("unparsable",'the input "'+i+`" can't be parsed as ISO 8601`)},t.fromISOTime=function(i,n){var s=$u(i),o=s[0];return o?t.fromObject(o,n):t.invalid("unparsable",'the input "'+i+`" can't be parsed as ISO 8601`)},t.invalid=function(i,n){if(n===void 0&&(n=null),!i)throw new z("need to specify a reason the Duration is invalid");var s=i instanceof ee?i:new ee(i,n);if(L.throwOnInvalid)throw new Pl(s);return new t({invalid:s})},t.normalizeUnit=function(i){var n={year:"years",years:"years",quarter:"quarters",quarters:"quarters",month:"months",months:"months",week:"weeks",weeks:"weeks",day:"days",days:"days",hour:"hours",hours:"hours",minute:"minutes",minutes:"minutes",second:"seconds",seconds:"seconds",millisecond:"milliseconds",milliseconds:"milliseconds"}[i&&i.toLowerCase()];if(!n)throw new jn(i);return n},t.isDuration=function(i){return i&&i.isLuxonDuration||!1};var e=t.prototype;return e.toFormat=function(i,n){n===void 0&&(n={});var s=k({},n,{floor:n.round!==!1&&n.floor!==!1});return this.isValid?ve.create(this.loc,s).formatDurationFromString(this,i):Gu},e.toObject=function(){return this.isValid?k({},this.values):{}},e.toISO=function(){if(!this.isValid)return null;var i="P";return this.years!==0&&(i+=this.years+"Y"),(this.months!==0||this.quarters!==0)&&(i+=this.months+this.quarters*3+"M"),this.weeks!==0&&(i+=this.weeks+"W"),this.days!==0&&(i+=this.days+"D"),(this.hours!==0||this.minutes!==0||this.seconds!==0||this.milliseconds!==0)&&(i+="T"),this.hours!==0&&(i+=this.hours+"H"),this.minutes!==0&&(i+=this.minutes+"M"),(this.seconds!==0||this.milliseconds!==0)&&(i+=Hr(this.seconds+this.milliseconds/1e3,3)+"S"),i==="P"&&(i+="T0S"),i},e.toISOTime=function(i){if(i===void 0&&(i={}),!this.isValid)return null;var n=this.toMillis();if(n<0||n>=864e5)return null;i=k({suppressMilliseconds:!1,suppressSeconds:!1,includePrefix:!1,format:"extended"},i);var s=this.shiftTo("hours","minutes","seconds","milliseconds"),o=i.format==="basic"?"hhmm":"hh:mm";(!i.suppressSeconds||s.seconds!==0||s.milliseconds!==0)&&(o+=i.format==="basic"?"ss":":ss",(!i.suppressMilliseconds||s.milliseconds!==0)&&(o+=".SSS"));var a=s.toFormat(o);return i.includePrefix&&(a="T"+a),a},e.toJSON=function(){return this.toISO()},e.toString=function(){return this.toISO()},e.toMillis=function(){return this.as("milliseconds")},e.valueOf=function(){return this.toMillis()},e.plus=function(i){if(!this.isValid)return this;for(var n=Be(i),s={},o=Ce(ot),a;!(a=o()).done;){var l=a.value;(Xe(n.values,l)||Xe(this.values,l))&&(s[l]=n.get(l)+this.get(l))}return Ve(this,{values:s},!0)},e.minus=function(i){if(!this.isValid)return this;var n=Be(i);return this.plus(n.negate())},e.mapUnits=function(i){if(!this.isValid)return this;for(var n={},s=0,o=Object.keys(this.values);s<o.length;s++){var a=o[s];n[a]=cs(i(this.values[a],a))}return Ve(this,{values:n},!0)},e.get=function(i){return this[t.normalizeUnit(i)]},e.set=function(i){if(!this.isValid)return this;var n=k({},this.values,Xt(i,t.normalizeUnit));return Ve(this,{values:n})},e.reconfigure=function(i){var n=i===void 0?{}:i,s=n.locale,o=n.numberingSystem,a=n.conversionAccuracy,l=this.loc.clone({locale:s,numberingSystem:o}),u={loc:l};return a&&(u.conversionAccuracy=a),Ve(this,u)},e.as=function(i){return this.isValid?this.shiftTo(i).get(i):NaN},e.normalize=function(){if(!this.isValid)return this;var i=this.toObject();return tc(this.matrix,i),Ve(this,{values:i},!0)},e.shiftTo=function(){for(var i=arguments.length,n=new Array(i),s=0;s<i;s++)n[s]=arguments[s];if(!this.isValid)return this;if(n.length===0)return this;n=n.map(function(S){return t.normalizeUnit(S)});for(var o={},a={},l=this.toObject(),u,c=Ce(ot),h;!(h=c()).done;){var d=h.value;if(n.indexOf(d)>=0){u=d;var m=0;for(var p in a)m+=this.matrix[p][d]*a[p],a[p]=0;_e(l[d])&&(m+=l[d]);var y=Math.trunc(m);o[d]=y,a[d]=m-y;for(var b in l)ot.indexOf(b)>ot.indexOf(d)&&Ns(this.matrix,l,b,o,d)}else _e(l[d])&&(a[d]=l[d])}for(var f in a)a[f]!==0&&(o[u]+=f===u?a[f]:a[f]/this.matrix[u][f]);return Ve(this,{values:o},!0).normalize()},e.negate=function(){if(!this.isValid)return this;for(var i={},n=0,s=Object.keys(this.values);n<s.length;n++){var o=s[n];i[o]=-this.values[o]}return Ve(this,{values:i},!0)},e.equals=function(i){if(!this.isValid||!i.isValid||!this.loc.equals(i.loc))return!1;function n(l,u){return l===void 0||l===0?u===void 0||u===0:l===u}for(var s=Ce(ot),o;!(o=s()).done;){var a=o.value;if(!n(this.values[a],i.values[a]))return!1}return!0},oe(t,[{key:"locale",get:function(){return this.isValid?this.loc.locale:null}},{key:"numberingSystem",get:function(){return this.isValid?this.loc.numberingSystem:null}},{key:"years",get:function(){return this.isValid?this.values.years||0:NaN}},{key:"quarters",get:function(){return this.isValid?this.values.quarters||0:NaN}},{key:"months",get:function(){return this.isValid?this.values.months||0:NaN}},{key:"weeks",get:function(){return this.isValid?this.values.weeks||0:NaN}},{key:"days",get:function(){return this.isValid?this.values.days||0:NaN}},{key:"hours",get:function(){return this.isValid?this.values.hours||0:NaN}},{key:"minutes",get:function(){return this.isValid?this.values.minutes||0:NaN}},{key:"seconds",get:function(){return this.isValid?this.values.seconds||0:NaN}},{key:"milliseconds",get:function(){return this.isValid?this.values.milliseconds||0:NaN}},{key:"isValid",get:function(){return this.invalid===null}},{key:"invalidReason",get:function(){return this.invalid?this.invalid.reason:null}},{key:"invalidExplanation",get:function(){return this.invalid?this.invalid.explanation:null}}]),t}();function Be(t){if(_e(t))return N.fromMillis(t);if(N.isDuration(t))return t;if(typeof t=="object")return N.fromObject(t);throw new z("Unknown duration argument "+t+" of type "+typeof t)}var bt="Invalid Interval";function rc(t,e){return!t||!t.isValid?wt.invalid("missing or invalid start"):!e||!e.isValid?wt.invalid("missing or invalid end"):e<t?wt.invalid("end before start","The end of an interval must be after its start, but you had start="+t.toISO()+" and end="+e.toISO()):null}var wt=function(){function t(r){this.s=r.start,this.e=r.end,this.invalid=r.invalid||null,this.isLuxonInterval=!0}t.invalid=function(i,n){if(n===void 0&&(n=null),!i)throw new z("need to specify a reason the Interval is invalid");var s=i instanceof ee?i:new ee(i,n);if(L.throwOnInvalid)throw new Il(s);return new t({invalid:s})},t.fromDateTimes=function(i,n){var s=kt(i),o=kt(n),a=rc(s,o);return a??new t({start:s,end:o})},t.after=function(i,n){var s=Be(n),o=kt(i);return t.fromDateTimes(o,o.plus(s))},t.before=function(i,n){var s=Be(n),o=kt(i);return t.fromDateTimes(o.minus(s),o)},t.fromISO=function(i,n){var s=(i||"").split("/",2),o=s[0],a=s[1];if(o&&a){var l,u;try{l=I.fromISO(o,n),u=l.isValid}catch(p){u=!1}var c,h;try{c=I.fromISO(a,n),h=c.isValid}catch(p){h=!1}if(u&&h)return t.fromDateTimes(l,c);if(u){var d=N.fromISO(a,n);if(d.isValid)return t.after(l,d)}else if(h){var m=N.fromISO(o,n);if(m.isValid)return t.before(c,m)}}return t.invalid("unparsable",'the input "'+i+`" can't be parsed as ISO 8601`)},t.isInterval=function(i){return i&&i.isLuxonInterval||!1};var e=t.prototype;return e.length=function(i){return i===void 0&&(i="milliseconds"),this.isValid?this.toDuration.apply(this,[i]).get(i):NaN},e.count=function(i){if(i===void 0&&(i="milliseconds"),!this.isValid)return NaN;var n=this.start.startOf(i),s=this.end.startOf(i);return Math.floor(s.diff(n,i).get(i))+1},e.hasSame=function(i){return this.isValid?this.isEmpty()||this.e.minus(1).hasSame(this.s,i):!1},e.isEmpty=function(){return this.s.valueOf()===this.e.valueOf()},e.isAfter=function(i){return this.isValid?this.s>i:!1},e.isBefore=function(i){return this.isValid?this.e<=i:!1},e.contains=function(i){return this.isValid?this.s<=i&&this.e>i:!1},e.set=function(i){var n=i===void 0?{}:i,s=n.start,o=n.end;return this.isValid?t.fromDateTimes(s||this.s,o||this.e):this},e.splitAt=function(){var i=this;if(!this.isValid)return[];for(var n=arguments.length,s=new Array(n),o=0;o<n;o++)s[o]=arguments[o];for(var a=s.map(kt).filter(function(m){return i.contains(m)}).sort(),l=[],u=this.s,c=0;u<this.e;){var h=a[c]||this.e,d=+h>+this.e?this.e:h;l.push(t.fromDateTimes(u,d)),u=d,c+=1}return l},e.splitBy=function(i){var n=Be(i);if(!this.isValid||!n.isValid||n.as("milliseconds")===0)return[];for(var s=this.s,o=1,a,l=[];s<this.e;){var u=this.start.plus(n.mapUnits(function(c){return c*o}));a=+u>+this.e?this.e:u,l.push(t.fromDateTimes(s,a)),s=a,o+=1}return l},e.divideEqually=function(i){return this.isValid?this.splitBy(this.length()/i).slice(0,i):[]},e.overlaps=function(i){return this.e>i.s&&this.s<i.e},e.abutsStart=function(i){return this.isValid?+this.e==+i.s:!1},e.abutsEnd=function(i){return this.isValid?+i.e==+this.s:!1},e.engulfs=function(i){return this.isValid?this.s<=i.s&&this.e>=i.e:!1},e.equals=function(i){return!this.isValid||!i.isValid?!1:this.s.equals(i.s)&&this.e.equals(i.e)},e.intersection=function(i){if(!this.isValid)return this;var n=this.s>i.s?this.s:i.s,s=this.e<i.e?this.e:i.e;return n>=s?null:t.fromDateTimes(n,s)},e.union=function(i){if(!this.isValid)return this;var n=this.s<i.s?this.s:i.s,s=this.e>i.e?this.e:i.e;return t.fromDateTimes(n,s)},t.merge=function(i){var n=i.sort(function(a,l){return a.s-l.s}).reduce(function(a,l){var u=a[0],c=a[1];return c?c.overlaps(l)||c.abutsStart(l)?[u,c.union(l)]:[u.concat([c]),l]:[u,l]},[[],null]),s=n[0],o=n[1];return o&&s.push(o),s},t.xor=function(i){for(var n,s=null,o=0,a=[],l=i.map(function(p){return[{time:p.s,type:"s"},{time:p.e,type:"e"}]}),u=(n=Array.prototype).concat.apply(n,l),c=u.sort(function(p,y){return p.time-y.time}),h=Ce(c),d;!(d=h()).done;){var m=d.value;o+=m.type==="s"?1:-1,o===1?s=m.time:(s&&+s!=+m.time&&a.push(t.fromDateTimes(s,m.time)),s=null)}return t.merge(a)},e.difference=function(){for(var i=this,n=arguments.length,s=new Array(n),o=0;o<n;o++)s[o]=arguments[o];return t.xor([this].concat(s)).map(function(a){return i.intersection(a)}).filter(function(a){return a&&!a.isEmpty()})},e.toString=function(){return this.isValid?"["+this.s.toISO()+" \u2013 "+this.e.toISO()+")":bt},e.toISO=function(i){return this.isValid?this.s.toISO(i)+"/"+this.e.toISO(i):bt},e.toISODate=function(){return this.isValid?this.s.toISODate()+"/"+this.e.toISODate():bt},e.toISOTime=function(i){return this.isValid?this.s.toISOTime(i)+"/"+this.e.toISOTime(i):bt},e.toFormat=function(i,n){var s=n===void 0?{}:n,o=s.separator,a=o===void 0?" \u2013 ":o;return this.isValid?""+this.s.toFormat(i)+a+this.e.toFormat(i):bt},e.toDuration=function(i,n){return this.isValid?this.e.diff(this.s,i,n):N.invalid(this.invalidReason)},e.mapEndpoints=function(i){return t.fromDateTimes(i(this.s),i(this.e))},oe(t,[{key:"start",get:function(){return this.isValid?this.s:null}},{key:"end",get:function(){return this.isValid?this.e:null}},{key:"isValid",get:function(){return this.invalidReason===null}},{key:"invalidReason",get:function(){return this.invalid?this.invalid.reason:null}},{key:"invalidExplanation",get:function(){return this.invalid?this.invalid.explanation:null}}]),t}(),St=function(){function t(){}return t.hasDST=function(r){r===void 0&&(r=L.defaultZone);var i=I.now().setZone(r).set({month:12});return!r.isUniversal&&i.offset!==i.set({month:6}).offset},t.isValidIANAZone=function(r){return ae.isValidSpecifier(r)&&ae.isValidZone(r)},t.normalizeZone=function(r){return Ie(r,L.defaultZone)},t.months=function(r,i){r===void 0&&(r="long");var n=i===void 0?{}:i,s=n.locale,o=s===void 0?null:s,a=n.numberingSystem,l=a===void 0?null:a,u=n.locObj,c=u===void 0?null:u,h=n.outputCalendar,d=h===void 0?"gregory":h;return(c||M.create(o,l,d)).months(r)},t.monthsFormat=function(r,i){r===void 0&&(r="long");var n=i===void 0?{}:i,s=n.locale,o=s===void 0?null:s,a=n.numberingSystem,l=a===void 0?null:a,u=n.locObj,c=u===void 0?null:u,h=n.outputCalendar,d=h===void 0?"gregory":h;return(c||M.create(o,l,d)).months(r,!0)},t.weekdays=function(r,i){r===void 0&&(r="long");var n=i===void 0?{}:i,s=n.locale,o=s===void 0?null:s,a=n.numberingSystem,l=a===void 0?null:a,u=n.locObj,c=u===void 0?null:u;return(c||M.create(o,l,null)).weekdays(r)},t.weekdaysFormat=function(r,i){r===void 0&&(r="long");var n=i===void 0?{}:i,s=n.locale,o=s===void 0?null:s,a=n.numberingSystem,l=a===void 0?null:a,u=n.locObj,c=u===void 0?null:u;return(c||M.create(o,l,null)).weekdays(r,!0)},t.meridiems=function(r){var i=r===void 0?{}:r,n=i.locale,s=n===void 0?null:n;return M.create(s).meridiems()},t.eras=function(r,i){r===void 0&&(r="short");var n=i===void 0?{}:i,s=n.locale,o=s===void 0?null:s;return M.create(o,null,"gregory").eras(r)},t.features=function(){return{relative:as()}},t}();function _s(t,e){var r=function(s){return s.toUTC(0,{keepLocalTime:!0}).startOf("day").valueOf()},i=r(e)-r(t);return Math.floor(N.fromMillis(i).as("days"))}function ic(t,e,r){for(var i=[["years",function(y,b){return b.year-y.year}],["quarters",function(y,b){return b.quarter-y.quarter}],["months",function(y,b){return b.month-y.month+(b.year-y.year)*12}],["weeks",function(y,b){var f=_s(y,b);return(f-f%7)/7}],["days",_s]],n={},s,o,a=0,l=i;a<l.length;a++){var u=l[a],c=u[0],h=u[1];if(r.indexOf(c)>=0){var d;s=c;var m=h(t,e);if(o=t.plus((d={},d[c]=m,d)),o>e){var p;t=t.plus((p={},p[c]=m-1,p)),m-=1}else t=o;n[c]=m}}return[t,n,o,s]}function nc(t,e,r,i){var n=ic(t,e,r),s=n[0],o=n[1],a=n[2],l=n[3],u=e-s,c=r.filter(function(p){return["hours","minutes","seconds","milliseconds"].indexOf(p)>=0});if(c.length===0){if(a<e){var h;a=s.plus((h={},h[l]=1,h))}a!==s&&(o[l]=(o[l]||0)+u/(a-s))}var d=N.fromObject(o,i);if(c.length>0){var m;return(m=N.fromMillis(u,i)).shiftTo.apply(m,c).plus(d)}else return d}var Yr={arab:"[\u0660-\u0669]",arabext:"[\u06F0-\u06F9]",bali:"[\u1B50-\u1B59]",beng:"[\u09E6-\u09EF]",deva:"[\u0966-\u096F]",fullwide:"[\uFF10-\uFF19]",gujr:"[\u0AE6-\u0AEF]",hanidec:"[\u3007|\u4E00|\u4E8C|\u4E09|\u56DB|\u4E94|\u516D|\u4E03|\u516B|\u4E5D]",khmr:"[\u17E0-\u17E9]",knda:"[\u0CE6-\u0CEF]",laoo:"[\u0ED0-\u0ED9]",limb:"[\u1946-\u194F]",mlym:"[\u0D66-\u0D6F]",mong:"[\u1810-\u1819]",mymr:"[\u1040-\u1049]",orya:"[\u0B66-\u0B6F]",tamldec:"[\u0BE6-\u0BEF]",telu:"[\u0C66-\u0C6F]",thai:"[\u0E50-\u0E59]",tibt:"[\u0F20-\u0F29]",latn:"\\d"},Fs={arab:[1632,1641],arabext:[1776,1785],bali:[6992,7001],beng:[2534,2543],deva:[2406,2415],fullwide:[65296,65303],gujr:[2790,2799],khmr:[6112,6121],knda:[3302,3311],laoo:[3792,3801],limb:[6470,6479],mlym:[3430,3439],mong:[6160,6169],mymr:[4160,4169],orya:[2918,2927],tamldec:[3046,3055],telu:[3174,3183],thai:[3664,3673],tibt:[3872,3881]},sc=Yr.hanidec.replace(/[\[|\]]/g,"").split("");function oc(t){var e=parseInt(t,10);if(isNaN(e)){e="";for(var r=0;r<t.length;r++){var i=t.charCodeAt(r);if(t[r].search(Yr.hanidec)!==-1)e+=sc.indexOf(t[r]);else for(var n in Fs){var s=Fs[n],o=s[0],a=s[1];i>=o&&i<=a&&(e+=i-o)}}return parseInt(e,10)}else return e}function te(t,e){var r=t.numberingSystem;return e===void 0&&(e=""),new RegExp(""+Yr[r||"latn"]+e)}var ac="missing Intl.DateTimeFormat.formatToParts support";function O(t,e){return e===void 0&&(e=function(i){return i}),{regex:t,deser:function(i){var n=i[0];return e(oc(n))}}}var lc=String.fromCharCode(160),Hs="( |"+lc+")",Vs=new RegExp(Hs,"g");function uc(t){return t.replace(/\./g,"\\.?").replace(Vs,Hs)}function Bs(t){return t.replace(/\./g,"").replace(Vs," ").toLowerCase()}function re(t,e){return t===null?null:{regex:RegExp(t.map(uc).join("|")),deser:function(i){var n=i[0];return t.findIndex(function(s){return Bs(n)===Bs(s)})+e}}}function js(t,e){return{regex:t,deser:function(i){var n=i[1],s=i[2];return Yt(n,s)},groups:e}}function Us(t){return{regex:t,deser:function(r){var i=r[0];return i}}}function cc(t){return t.replace(/[\-\[\]{}()*+?.,\\\^$|#\s]/g,"\\$&")}function hc(t,e){var r=te(e),i=te(e,"{2}"),n=te(e,"{3}"),s=te(e,"{4}"),o=te(e,"{6}"),a=te(e,"{1,2}"),l=te(e,"{1,3}"),u=te(e,"{1,6}"),c=te(e,"{1,9}"),h=te(e,"{2,4}"),d=te(e,"{4,6}"),m=function(f){return{regex:RegExp(cc(f.val)),deser:function(ie){var de=ie[0];return de},literal:!0}},p=function(f){if(t.literal)return m(f);switch(f.val){case"G":return re(e.eras("short",!1),0);case"GG":return re(e.eras("long",!1),0);case"y":return O(u);case"yy":return O(h,Br);case"yyyy":return O(s);case"yyyyy":return O(d);case"yyyyyy":return O(o);case"M":return O(a);case"MM":return O(i);case"MMM":return re(e.months("short",!0,!1),1);case"MMMM":return re(e.months("long",!0,!1),1);case"L":return O(a);case"LL":return O(i);case"LLL":return re(e.months("short",!1,!1),1);case"LLLL":return re(e.months("long",!1,!1),1);case"d":return O(a);case"dd":return O(i);case"o":return O(l);case"ooo":return O(n);case"HH":return O(i);case"H":return O(a);case"hh":return O(i);case"h":return O(a);case"mm":return O(i);case"m":return O(a);case"q":return O(a);case"qq":return O(i);case"s":return O(a);case"ss":return O(i);case"S":return O(l);case"SSS":return O(n);case"u":return Us(c);case"a":return re(e.meridiems(),0);case"kkkk":return O(s);case"kk":return O(h,Br);case"W":return O(a);case"WW":return O(i);case"E":case"c":return O(r);case"EEE":return re(e.weekdays("short",!1,!1),1);case"EEEE":return re(e.weekdays("long",!1,!1),1);case"ccc":return re(e.weekdays("short",!0,!1),1);case"cccc":return re(e.weekdays("long",!0,!1),1);case"Z":case"ZZ":return js(new RegExp("([+-]"+a.source+")(?::("+i.source+"))?"),2);case"ZZZ":return js(new RegExp("([+-]"+a.source+")("+i.source+")?"),2);case"z":return Us(/[a-z_+-/]{1,256}?/i);default:return m(f)}},y=p(t)||{invalidReason:ac};return y.token=t,y}var dc={year:{"2-digit":"yy",numeric:"yyyyy"},month:{numeric:"M","2-digit":"MM",short:"MMM",long:"MMMM"},day:{numeric:"d","2-digit":"dd"},weekday:{short:"EEE",long:"EEEE"},dayperiod:"a",dayPeriod:"a",hour:{numeric:"h","2-digit":"hh"},minute:{numeric:"m","2-digit":"mm"},second:{numeric:"s","2-digit":"ss"}};function fc(t,e,r){var i=t.type,n=t.value;if(i==="literal")return{literal:!0,val:n};var s=r[i],o=dc[i];if(typeof o=="object"&&(o=o[s]),o)return{literal:!1,val:o}}function mc(t){var e=t.map(function(r){return r.regex}).reduce(function(r,i){return r+"("+i.source+")"},"");return["^"+e+"$",t]}function pc(t,e,r){var i=t.match(e);if(i){var n={},s=1;for(var o in r)if(Xe(r,o)){var a=r[o],l=a.groups?a.groups+1:1;!a.literal&&a.token&&(n[a.token.val[0]]=a.deser(i.slice(s,s+l))),s+=l}return[i,n]}else return[i,{}]}function gc(t){var e=function(s){switch(s){case"S":return"millisecond";case"s":return"second";case"m":return"minute";case"h":case"H":return"hour";case"d":return"day";case"o":return"ordinal";case"L":case"M":return"month";case"y":return"year";case"E":case"c":return"weekday";case"W":return"weekNumber";case"k":return"weekYear";case"q":return"quarter";default:return null}},r;A(t.Z)?A(t.z)?r=null:r=ae.create(t.z):r=new Z(t.Z),A(t.q)||(t.M=(t.q-1)*3+1),A(t.h)||(t.h<12&&t.a===1?t.h+=12:t.h===12&&t.a===0&&(t.h=0)),t.G===0&&t.y&&(t.y=-t.y),A(t.u)||(t.S=Fr(t.u));var i=Object.keys(t).reduce(function(n,s){var o=e(s);return o&&(n[o]=t[s]),n},{});return[i,r]}var Xr=null;function vc(){return Xr||(Xr=I.fromMillis(1555555555555)),Xr}function yc(t,e){if(t.literal)return t;var r=ve.macroTokenToFormatOpts(t.val);if(!r)return t;var i=ve.create(e,r),n=i.formatDateTimeParts(vc()),s=n.map(function(o){return fc(o,e,r)});return s.includes(void 0)?t:s}function bc(t,e){var r;return(r=Array.prototype).concat.apply(r,t.map(function(i){return yc(i,e)}))}function qs(t,e,r){var i=bc(ve.parseFormat(r),t),n=i.map(function(b){return hc(b,t)}),s=n.find(function(b){return b.invalidReason});if(s)return{input:e,tokens:i,invalidReason:s.invalidReason};var o=mc(n),a=o[0],l=o[1],u=RegExp(a,"i"),c=pc(e,u,l),h=c[0],d=c[1],m=d?gc(d):[null,null],p=m[0],y=m[1];if(Xe(d,"a")&&Xe(d,"H"))throw new pt("Can't include meridiem when specifying 24-hour format");return{input:e,tokens:i,regex:u,rawMatches:h,matches:d,result:p,zone:y}}function wc(t,e,r){var i=qs(t,e,r),n=i.result,s=i.zone,o=i.invalidReason;return[n,s,o]}var $s=[0,31,59,90,120,151,181,212,243,273,304,334],Ws=[0,31,60,91,121,152,182,213,244,274,305,335];function K(t,e){return new ee("unit out of range","you specified "+e+" (of type "+typeof e+") as a "+t+", which is invalid")}function zs(t,e,r){var i=new Date(Date.UTC(t,e-1,r)).getUTCDay();return i===0?7:i}function Zs(t,e,r){return r+(gt(t)?Ws:$s)[e-1]}function Js(t,e){var r=gt(t)?Ws:$s,i=r.findIndex(function(s){return s<e}),n=e-r[i];return{month:i+1,day:n}}function Qr(t){var e=t.year,r=t.month,i=t.day,n=Zs(e,r,i),s=zs(e,r,i),o=Math.floor((n-s+10)/7),a;return o<1?(a=e-1,o=Gt(a)):o>Gt(e)?(a=e+1,o=1):a=e,k({weekYear:a,weekNumber:o,weekday:s},er(t))}function Ks(t){var e=t.weekYear,r=t.weekNumber,i=t.weekday,n=zs(e,1,4),s=vt(e),o=r*7+i-n-3,a;o<1?(a=e-1,o+=vt(a)):o>s?(a=e+1,o-=vt(e)):a=e;var l=Js(a,o),u=l.month,c=l.day;return k({year:a,month:u,day:c},er(t))}function ei(t){var e=t.year,r=t.month,i=t.day,n=Zs(e,r,i);return k({year:e,ordinal:n},er(t))}function Gs(t){var e=t.year,r=t.ordinal,i=Js(e,r),n=i.month,s=i.day;return k({year:e,month:n,day:s},er(t))}function Sc(t){var e=Jt(t.weekYear),r=ge(t.weekNumber,1,Gt(t.weekYear)),i=ge(t.weekday,1,7);return e?r?i?!1:K("weekday",t.weekday):K("week",t.week):K("weekYear",t.weekYear)}function Ec(t){var e=Jt(t.year),r=ge(t.ordinal,1,vt(t.year));return e?r?!1:K("ordinal",t.ordinal):K("year",t.year)}function Ys(t){var e=Jt(t.year),r=ge(t.month,1,12),i=ge(t.day,1,Kt(t.year,t.month));return e?r?i?!1:K("day",t.day):K("month",t.month):K("year",t.year)}function Xs(t){var e=t.hour,r=t.minute,i=t.second,n=t.millisecond,s=ge(e,0,23)||e===24&&r===0&&i===0&&n===0,o=ge(r,0,59),a=ge(i,0,59),l=ge(n,0,999);return s?o?a?l?!1:K("millisecond",n):K("second",i):K("minute",r):K("hour",e)}var ti="Invalid DateTime",Qs=864e13;function nr(t){return new ee("unsupported zone",'the zone "'+t.name+'" is not supported')}function ri(t){return t.weekData===null&&(t.weekData=Qr(t.c)),t.weekData}function Et(t,e){var r={ts:t.ts,zone:t.zone,c:t.c,o:t.o,loc:t.loc,invalid:t.invalid};return new I(k({},r,e,{old:r}))}function eo(t,e,r){var i=t-e*60*1e3,n=r.offset(i);if(e===n)return[i,e];i-=(n-e)*60*1e3;var s=r.offset(i);return n===s?[i,n]:[t-Math.min(n,s)*60*1e3,Math.max(n,s)]}function to(t,e){t+=e*60*1e3;var r=new Date(t);return{year:r.getUTCFullYear(),month:r.getUTCMonth()+1,day:r.getUTCDate(),hour:r.getUTCHours(),minute:r.getUTCMinutes(),second:r.getUTCSeconds(),millisecond:r.getUTCMilliseconds()}}function sr(t,e,r){return eo(Vr(t),e,r)}function ro(t,e){var r=t.o,i=t.c.year+Math.trunc(e.years),n=t.c.month+Math.trunc(e.months)+Math.trunc(e.quarters)*3,s=k({},t.c,{year:i,month:n,day:Math.min(t.c.day,Kt(i,n))+Math.trunc(e.days)+Math.trunc(e.weeks)*7}),o=N.fromObject({years:e.years-Math.trunc(e.years),quarters:e.quarters-Math.trunc(e.quarters),months:e.months-Math.trunc(e.months),weeks:e.weeks-Math.trunc(e.weeks),days:e.days-Math.trunc(e.days),hours:e.hours,minutes:e.minutes,seconds:e.seconds,milliseconds:e.milliseconds}).as("milliseconds"),a=Vr(s),l=eo(a,r,t.zone),u=l[0],c=l[1];return o!==0&&(u+=o,c=t.zone.offset(u)),{ts:u,o:c}}function Tt(t,e,r,i,n){var s=r.setZone,o=r.zone;if(t&&Object.keys(t).length!==0){var a=e||o,l=I.fromObject(t,k({},r,{zone:a}));return s?l:l.setZone(o)}else return I.invalid(new ee("unparsable",'the input "'+n+`" can't be parsed as `+i))}function at(t,e,r){return r===void 0&&(r=!0),t.isValid?ve.create(M.create("en-US"),{allowZ:r,forceSimple:!0}).formatDateTimeFromString(t,e):null}function io(t,e){var r=e.suppressSeconds,i=r===void 0?!1:r,n=e.suppressMilliseconds,s=n===void 0?!1:n,o=e.includeOffset,a=e.includePrefix,l=a===void 0?!1:a,u=e.includeZone,c=u===void 0?!1:u,h=e.spaceZone,d=h===void 0?!1:h,m=e.format,p=m===void 0?"extended":m,y=p==="basic"?"HHmm":"HH:mm";(!i||t.second!==0||t.millisecond!==0)&&(y+=p==="basic"?"ss":":ss",(!s||t.millisecond!==0)&&(y+=".SSS")),(c||o)&&d&&(y+=" "),c?y+="z":o&&(y+=p==="basic"?"ZZZ":"ZZ");var b=at(t,y);return l&&(b="T"+b),b}var no={month:1,day:1,hour:0,minute:0,second:0,millisecond:0},Tc={weekNumber:1,weekday:1,hour:0,minute:0,second:0,millisecond:0},kc={ordinal:1,hour:0,minute:0,second:0,millisecond:0},so=["year","month","day","hour","minute","second","millisecond"],Ac=["weekYear","weekNumber","weekday","hour","minute","second","millisecond"],Oc=["year","ordinal","hour","minute","second","millisecond"];function oo(t){var e={year:"year",years:"year",month:"month",months:"month",day:"day",days:"day",hour:"hour",hours:"hour",minute:"minute",minutes:"minute",quarter:"quarter",quarters:"quarter",second:"second",seconds:"second",millisecond:"millisecond",milliseconds:"millisecond",weekday:"weekday",weekdays:"weekday",weeknumber:"weekNumber",weeksnumber:"weekNumber",weeknumbers:"weekNumber",weekyear:"weekYear",weekyears:"weekYear",ordinal:"ordinal"}[t.toLowerCase()];if(!e)throw new jn(t);return e}function ao(t,e){var r=Ie(e.zone,L.defaultZone),i=M.fromObject(e),n=L.now(),s,o;if(A(t.year))s=n;else{for(var a=Ce(so),l;!(l=a()).done;){var u=l.value;A(t[u])&&(t[u]=no[u])}var c=Ys(t)||Xs(t);if(c)return I.invalid(c);var h=r.offset(n),d=sr(t,h,r);s=d[0],o=d[1]}return new I({ts:s,zone:r,loc:i,o})}function lo(t,e,r){var i=A(r.round)?!0:r.round,n=function(h,d){h=Hr(h,i||r.calendary?0:2,!0);var m=e.loc.clone(r).relFormatter(r);return m.format(h,d)},s=function(h){return r.calendary?e.hasSame(t,h)?0:e.startOf(h).diff(t.startOf(h),h).get(h):e.diff(t,h).get(h)};if(r.unit)return n(s(r.unit),r.unit);for(var o=Ce(r.units),a;!(a=o()).done;){var l=a.value,u=s(l);if(Math.abs(u)>=1)return n(u,l)}return n(t>e?-0:0,r.units[r.units.length-1])}function uo(t){var e={},r;return t.length>0&&typeof t[t.length-1]=="object"?(e=t[t.length-1],r=Array.from(t).slice(0,t.length-1)):r=Array.from(t),[e,r]}var I=function(){function t(r){var i=r.zone||L.defaultZone,n=r.invalid||(Number.isNaN(r.ts)?new ee("invalid input"):null)||(i.isValid?null:nr(i));this.ts=A(r.ts)?L.now():r.ts;var s=null,o=null;if(!n){var a=r.old&&r.old.ts===this.ts&&r.old.zone.equals(i);if(a){var l=[r.old.c,r.old.o];s=l[0],o=l[1]}else{var u=i.offset(this.ts);s=to(this.ts,u),n=Number.isNaN(s.year)?new ee("invalid input"):null,s=n?null:s,o=n?null:u}}this._zone=i,this.loc=r.loc||M.create(),this.invalid=n,this.weekData=null,this.c=s,this.o=o,this.isLuxonDateTime=!0}t.now=function(){return new t({})},t.local=function(){var i=uo(arguments),n=i[0],s=i[1],o=s[0],a=s[1],l=s[2],u=s[3],c=s[4],h=s[5],d=s[6];return ao({year:o,month:a,day:l,hour:u,minute:c,second:h,millisecond:d},n)},t.utc=function(){var i=uo(arguments),n=i[0],s=i[1],o=s[0],a=s[1],l=s[2],u=s[3],c=s[4],h=s[5],d=s[6];return n.zone=Z.utcInstance,ao({year:o,month:a,day:l,hour:u,minute:c,second:h,millisecond:d},n)},t.fromJSDate=function(i,n){n===void 0&&(n={});var s=xl(i)?i.valueOf():NaN;if(Number.isNaN(s))return t.invalid("invalid input");var o=Ie(n.zone,L.defaultZone);return o.isValid?new t({ts:s,zone:o,loc:M.fromObject(n)}):t.invalid(nr(o))},t.fromMillis=function(i,n){if(n===void 0&&(n={}),_e(i))return i<-Qs||i>Qs?t.invalid("Timestamp out of range"):new t({ts:i,zone:Ie(n.zone,L.defaultZone),loc:M.fromObject(n)});throw new z("fromMillis requires a numerical input, but received a "+typeof i+" with value "+i)},t.fromSeconds=function(i,n){if(n===void 0&&(n={}),_e(i))return new t({ts:i*1e3,zone:Ie(n.zone,L.defaultZone),loc:M.fromObject(n)});throw new z("fromSeconds requires a numerical input")},t.fromObject=function(i,n){n===void 0&&(n={}),i=i||{};var s=Ie(n.zone,L.defaultZone);if(!s.isValid)return t.invalid(nr(s));var o=L.now(),a=s.offset(o),l=Xt(i,oo),u=!A(l.ordinal),c=!A(l.year),h=!A(l.month)||!A(l.day),d=c||h,m=l.weekYear||l.weekNumber,p=M.fromObject(n);if((d||u)&&m)throw new pt("Can't mix weekYear/weekNumber units with year/month/day or ordinals");if(h&&u)throw new pt("Can't mix ordinal dates with month/day");var y=m||l.weekday&&!d,b,f,S=to(o,a);y?(b=Ac,f=Tc,S=Qr(S)):u?(b=Oc,f=kc,S=ei(S)):(b=so,f=no);for(var ie=!1,de=Ce(b),qe;!(qe=de()).done;){var Re=qe.value,$e=l[Re];A($e)?ie?l[Re]=f[Re]:l[Re]=S[Re]:ie=!0}var br=y?Sc(l):u?Ec(l):Ys(l),P=br||Xs(l);if(P)return t.invalid(P);var We=y?Ks(l):u?Gs(l):l,ut=sr(We,a,s),ct=ut[0],wr=ut[1],De=new t({ts:ct,zone:s,o:wr,loc:p});return l.weekday&&d&&i.weekday!==De.weekday?t.invalid("mismatched weekday","you can't specify both a weekday of "+l.weekday+" and a date of "+De.toISO()):De},t.fromISO=function(i,n){n===void 0&&(n={});var s=Vu(i),o=s[0],a=s[1];return Tt(o,a,n,"ISO 8601",i)},t.fromRFC2822=function(i,n){n===void 0&&(n={});var s=Bu(i),o=s[0],a=s[1];return Tt(o,a,n,"RFC 2822",i)},t.fromHTTP=function(i,n){n===void 0&&(n={});var s=ju(i),o=s[0],a=s[1];return Tt(o,a,n,"HTTP",n)},t.fromFormat=function(i,n,s){if(s===void 0&&(s={}),A(i)||A(n))throw new z("fromFormat requires an input string and a format");var o=s,a=o.locale,l=a===void 0?null:a,u=o.numberingSystem,c=u===void 0?null:u,h=M.fromOpts({locale:l,numberingSystem:c,defaultToEN:!0}),d=wc(h,i,n),m=d[0],p=d[1],y=d[2];return y?t.invalid(y):Tt(m,p,s,"format "+n,i)},t.fromString=function(i,n,s){return s===void 0&&(s={}),t.fromFormat(i,n,s)},t.fromSQL=function(i,n){n===void 0&&(n={});var s=Ku(i),o=s[0],a=s[1];return Tt(o,a,n,"SQL",i)},t.invalid=function(i,n){if(n===void 0&&(n=null),!i)throw new z("need to specify a reason the DateTime is invalid");var s=i instanceof ee?i:new ee(i,n);if(L.throwOnInvalid)throw new Ll(s);return new t({invalid:s})},t.isDateTime=function(i){return i&&i.isLuxonDateTime||!1};var e=t.prototype;return e.get=function(i){return this[i]},e.resolvedLocaleOptions=function(i){i===void 0&&(i={});var n=ve.create(this.loc.clone(i),i).resolvedOptions(this),s=n.locale,o=n.numberingSystem,a=n.calendar;return{locale:s,numberingSystem:o,outputCalendar:a}},e.toUTC=function(i,n){return i===void 0&&(i=0),n===void 0&&(n={}),this.setZone(Z.instance(i),n)},e.toLocal=function(){return this.setZone(L.defaultZone)},e.setZone=function(i,n){var s=n===void 0?{}:n,o=s.keepLocalTime,a=o===void 0?!1:o,l=s.keepCalendarTime,u=l===void 0?!1:l;if(i=Ie(i,L.defaultZone),i.equals(this.zone))return this;if(i.isValid){var c=this.ts;if(a||u){var h=i.offset(this.ts),d=this.toObject(),m=sr(d,h,i);c=m[0]}return Et(this,{ts:c,zone:i})}else return t.invalid(nr(i))},e.reconfigure=function(i){var n=i===void 0?{}:i,s=n.locale,o=n.numberingSystem,a=n.outputCalendar,l=this.loc.clone({locale:s,numberingSystem:o,outputCalendar:a});return Et(this,{loc:l})},e.setLocale=function(i){return this.reconfigure({locale:i})},e.set=function(i){if(!this.isValid)return this;var n=Xt(i,oo),s=!A(n.weekYear)||!A(n.weekNumber)||!A(n.weekday),o=!A(n.ordinal),a=!A(n.year),l=!A(n.month)||!A(n.day),u=a||l,c=n.weekYear||n.weekNumber;if((u||o)&&c)throw new pt("Can't mix weekYear/weekNumber units with year/month/day or ordinals");if(l&&o)throw new pt("Can't mix ordinal dates with month/day");var h;s?h=Ks(k({},Qr(this.c),n)):A(n.ordinal)?(h=k({},this.toObject(),n),A(n.day)&&(h.day=Math.min(Kt(h.year,h.month),h.day))):h=Gs(k({},ei(this.c),n));var d=sr(h,this.o,this.zone),m=d[0],p=d[1];return Et(this,{ts:m,o:p})},e.plus=function(i){if(!this.isValid)return this;var n=Be(i);return Et(this,ro(this,n))},e.minus=function(i){if(!this.isValid)return this;var n=Be(i).negate();return Et(this,ro(this,n))},e.startOf=function(i){if(!this.isValid)return this;var n={},s=N.normalizeUnit(i);switch(s){case"years":n.month=1;case"quarters":case"months":n.day=1;case"weeks":case"days":n.hour=0;case"hours":n.minute=0;case"minutes":n.second=0;case"seconds":n.millisecond=0;break}if(s==="weeks"&&(n.weekday=1),s==="quarters"){var o=Math.ceil(this.month/3);n.month=(o-1)*3+1}return this.set(n)},e.endOf=function(i){var n;return this.isValid?this.plus((n={},n[i]=1,n)).startOf(i).minus(1):this},e.toFormat=function(i,n){return n===void 0&&(n={}),this.isValid?ve.create(this.loc.redefaultToEN(n)).formatDateTimeFromString(this,i):ti},e.toLocaleString=function(i,n){return i===void 0&&(i=_r),n===void 0&&(n={}),this.isValid?ve.create(this.loc.clone(n),i).formatDateTime(this):ti},e.toLocaleParts=function(i){return i===void 0&&(i={}),this.isValid?ve.create(this.loc.clone(i),i).formatDateTimeParts(this):[]},e.toISO=function(i){return i===void 0&&(i={}),this.isValid?this.toISODate(i)+"T"+this.toISOTime(i):null},e.toISODate=function(i){var n=i===void 0?{}:i,s=n.format,o=s===void 0?"extended":s,a=o==="basic"?"yyyyMMdd":"yyyy-MM-dd";return this.year>9999&&(a="+"+a),at(this,a)},e.toISOWeekDate=function(){return at(this,"kkkk-'W'WW-c")},e.toISOTime=function(i){var n=i===void 0?{}:i,s=n.suppressMilliseconds,o=s===void 0?!1:s,a=n.suppressSeconds,l=a===void 0?!1:a,u=n.includeOffset,c=u===void 0?!0:u,h=n.includePrefix,d=h===void 0?!1:h,m=n.format,p=m===void 0?"extended":m;return io(this,{suppressSeconds:l,suppressMilliseconds:o,includeOffset:c,includePrefix:d,format:p})},e.toRFC2822=function(){return at(this,"EEE, dd LLL yyyy HH:mm:ss ZZZ",!1)},e.toHTTP=function(){return at(this.toUTC(),"EEE, dd LLL yyyy HH:mm:ss 'GMT'")},e.toSQLDate=function(){return at(this,"yyyy-MM-dd")},e.toSQLTime=function(i){var n=i===void 0?{}:i,s=n.includeOffset,o=s===void 0?!0:s,a=n.includeZone,l=a===void 0?!1:a;return io(this,{includeOffset:o,includeZone:l,spaceZone:!0})},e.toSQL=function(i){return i===void 0&&(i={}),this.isValid?this.toSQLDate()+" "+this.toSQLTime(i):null},e.toString=function(){return this.isValid?this.toISO():ti},e.valueOf=function(){return this.toMillis()},e.toMillis=function(){return this.isValid?this.ts:NaN},e.toSeconds=function(){return this.isValid?this.ts/1e3:NaN},e.toJSON=function(){return this.toISO()},e.toBSON=function(){return this.toJSDate()},e.toObject=function(i){if(i===void 0&&(i={}),!this.isValid)return{};var n=k({},this.c);return i.includeConfig&&(n.outputCalendar=this.outputCalendar,n.numberingSystem=this.loc.numberingSystem,n.locale=this.loc.locale),n},e.toJSDate=function(){return new Date(this.isValid?this.ts:NaN)},e.diff=function(i,n,s){if(n===void 0&&(n="milliseconds"),s===void 0&&(s={}),!this.isValid||!i.isValid)return N.invalid("created by diffing an invalid DateTime");var o=k({locale:this.locale,numberingSystem:this.numberingSystem},s),a=Nl(n).map(N.normalizeUnit),l=i.valueOf()>this.valueOf(),u=l?this:i,c=l?i:this,h=nc(u,c,a,o);return l?h.negate():h},e.diffNow=function(i,n){return i===void 0&&(i="milliseconds"),n===void 0&&(n={}),this.diff(t.now(),i,n)},e.until=function(i){return this.isValid?wt.fromDateTimes(this,i):this},e.hasSame=function(i,n){if(!this.isValid)return!1;var s=i.valueOf(),o=this.setZone(i.zone,{keepLocalTime:!0});return o.startOf(n)<=s&&s<=o.endOf(n)},e.equals=function(i){return this.isValid&&i.isValid&&this.valueOf()===i.valueOf()&&this.zone.equals(i.zone)&&this.loc.equals(i.loc)},e.toRelative=function(i){if(i===void 0&&(i={}),!this.isValid)return null;var n=i.base||t.fromObject({},{zone:this.zone}),s=i.padding?this<n?-i.padding:i.padding:0,o=["years","months","days","hours","minutes","seconds"],a=i.unit;return Array.isArray(i.unit)&&(o=i.unit,a=void 0),lo(n,this.plus(s),k({},i,{numeric:"always",units:o,unit:a}))},e.toRelativeCalendar=function(i){return i===void 0&&(i={}),this.isValid?lo(i.base||t.fromObject({},{zone:this.zone}),this,k({},i,{numeric:"auto",units:["years","months","days"],calendary:!0})):null},t.min=function(){for(var i=arguments.length,n=new Array(i),s=0;s<i;s++)n[s]=arguments[s];if(!n.every(t.isDateTime))throw new z("min requires all arguments be DateTimes");return ls(n,function(o){return o.valueOf()},Math.min)},t.max=function(){for(var i=arguments.length,n=new Array(i),s=0;s<i;s++)n[s]=arguments[s];if(!n.every(t.isDateTime))throw new z("max requires all arguments be DateTimes");return ls(n,function(o){return o.valueOf()},Math.max)},t.fromFormatExplain=function(i,n,s){s===void 0&&(s={});var o=s,a=o.locale,l=a===void 0?null:a,u=o.numberingSystem,c=u===void 0?null:u,h=M.fromOpts({locale:l,numberingSystem:c,defaultToEN:!0});return qs(h,i,n)},t.fromStringExplain=function(i,n,s){return s===void 0&&(s={}),t.fromFormatExplain(i,n,s)},oe(t,[{key:"isValid",get:function(){return this.invalid===null}},{key:"invalidReason",get:function(){return this.invalid?this.invalid.reason:null}},{key:"invalidExplanation",get:function(){return this.invalid?this.invalid.explanation:null}},{key:"locale",get:function(){return this.isValid?this.loc.locale:null}},{key:"numberingSystem",get:function(){return this.isValid?this.loc.numberingSystem:null}},{key:"outputCalendar",get:function(){return this.isValid?this.loc.outputCalendar:null}},{key:"zone",get:function(){return this._zone}},{key:"zoneName",get:function(){return this.isValid?this.zone.name:null}},{key:"year",get:function(){return this.isValid?this.c.year:NaN}},{key:"quarter",get:function(){return this.isValid?Math.ceil(this.c.month/3):NaN}},{key:"month",get:function(){return this.isValid?this.c.month:NaN}},{key:"day",get:function(){return this.isValid?this.c.day:NaN}},{key:"hour",get:function(){return this.isValid?this.c.hour:NaN}},{key:"minute",get:function(){return this.isValid?this.c.minute:NaN}},{key:"second",get:function(){return this.isValid?this.c.second:NaN}},{key:"millisecond",get:function(){return this.isValid?this.c.millisecond:NaN}},{key:"weekYear",get:function(){return this.isValid?ri(this).weekYear:NaN}},{key:"weekNumber",get:function(){return this.isValid?ri(this).weekNumber:NaN}},{key:"weekday",get:function(){return this.isValid?ri(this).weekday:NaN}},{key:"ordinal",get:function(){return this.isValid?ei(this.c).ordinal:NaN}},{key:"monthShort",get:function(){return this.isValid?St.months("short",{locObj:this.loc})[this.month-1]:null}},{key:"monthLong",get:function(){return this.isValid?St.months("long",{locObj:this.loc})[this.month-1]:null}},{key:"weekdayShort",get:function(){return this.isValid?St.weekdays("short",{locObj:this.loc})[this.weekday-1]:null}},{key:"weekdayLong",get:function(){return this.isValid?St.weekdays("long",{locObj:this.loc})[this.weekday-1]:null}},{key:"offset",get:function(){return this.isValid?+this.o:NaN}},{key:"offsetNameShort",get:function(){return this.isValid?this.zone.offsetName(this.ts,{format:"short",locale:this.locale}):null}},{key:"offsetNameLong",get:function(){return this.isValid?this.zone.offsetName(this.ts,{format:"long",locale:this.locale}):null}},{key:"isOffsetFixed",get:function(){return this.isValid?this.zone.isUniversal:null}},{key:"isInDST",get:function(){return this.isOffsetFixed?!1:this.offset>this.set({month:1}).offset||this.offset>this.set({month:5}).offset}},{key:"isInLeapYear",get:function(){return gt(this.year)}},{key:"daysInMonth",get:function(){return Kt(this.year,this.month)}},{key:"daysInYear",get:function(){return this.isValid?vt(this.year):NaN}},{key:"weeksInWeekYear",get:function(){return this.isValid?Gt(this.weekYear):NaN}}],[{key:"DATE_SHORT",get:function(){return _r}},{key:"DATE_MED",get:function(){return Un}},{key:"DATE_MED_WITH_WEEKDAY",get:function(){return Ml}},{key:"DATE_FULL",get:function(){return qn}},{key:"DATE_HUGE",get:function(){return $n}},{key:"TIME_SIMPLE",get:function(){return Wn}},{key:"TIME_WITH_SECONDS",get:function(){return zn}},{key:"TIME_WITH_SHORT_OFFSET",get:function(){return Zn}},{key:"TIME_WITH_LONG_OFFSET",get:function(){return Jn}},{key:"TIME_24_SIMPLE",get:function(){return Kn}},{key:"TIME_24_WITH_SECONDS",get:function(){return Gn}},{key:"TIME_24_WITH_SHORT_OFFSET",get:function(){return Yn}},{key:"TIME_24_WITH_LONG_OFFSET",get:function(){return Xn}},{key:"DATETIME_SHORT",get:function(){return Qn}},{key:"DATETIME_SHORT_WITH_SECONDS",get:function(){return es}},{key:"DATETIME_MED",get:function(){return ts}},{key:"DATETIME_MED_WITH_SECONDS",get:function(){return rs}},{key:"DATETIME_MED_WITH_WEEKDAY",get:function(){return Rl}},{key:"DATETIME_FULL",get:function(){return is}},{key:"DATETIME_FULL_WITH_SECONDS",get:function(){return ns}},{key:"DATETIME_HUGE",get:function(){return ss}},{key:"DATETIME_HUGE_WITH_SECONDS",get:function(){return os}}]),t}();function kt(t){if(I.isDateTime(t))return t;if(t&&t.valueOf&&_e(t.valueOf()))return I.fromJSDate(t);if(t&&typeof t=="object")return I.fromObject(t);throw new z("Unknown datetime argument: "+t+", of type "+typeof t)}var Cc="2.0.2";U.DateTime=I;U.Duration=N;U.FixedOffsetZone=Z;U.IANAZone=ae;U.Info=St;U.Interval=wt;U.InvalidZone=qr;U.Settings=L;U.SystemZone=ws;U.VERSION=Cc;U.Zone=et});(function(){if(window.Reflect===void 0||window.customElements===void 0||window.customElements.polyfillWrapFlushCallback)return;let t=HTMLElement,e={HTMLElement:function(){return Reflect.construct(t,[],this.constructor)}};window.HTMLElement=e.HTMLElement,HTMLElement.prototype=t.prototype,HTMLElement.prototype.constructor=HTMLElement,Object.setPrototypeOf(HTMLElement,t)})();var Oi=new WeakMap;function ta(t){let e=t instanceof Element?t:t instanceof Node?t.parentElement:null,r=e?e.closest("input, button"):null;return(r==null?void 0:r.type)=="submit"?r:null}function ra(t){let e=ta(t.target);e&&e.form&&Oi.set(e.form,e)}(function(){"SubmitEvent"in window||(addEventListener("click",ra,!0),Object.defineProperty(Event.prototype,"submitter",{get(){if(this.type=="submit"&&this.target instanceof HTMLFormElement)return Oi.get(this.target)}}))})();var Te;(function(t){t.eager="eager",t.lazy="lazy"})(Te||(Te={}));var fe=class extends HTMLElement{constructor(){super();this.loaded=Promise.resolve(),this.delegate=new fe.delegateConstructor(this)}static get observedAttributes(){return["disabled","loading","src"]}connectedCallback(){this.delegate.connect()}disconnectedCallback(){this.delegate.disconnect()}reload(){let{src:e}=this;this.src=null,this.src=e}attributeChangedCallback(e){e=="loading"?this.delegate.loadingStyleChanged():e=="src"?this.delegate.sourceURLChanged():this.delegate.disabledChanged()}get src(){return this.getAttribute("src")}set src(e){e?this.setAttribute("src",e):this.removeAttribute("src")}get loading(){return ia(this.getAttribute("loading")||"")}set loading(e){e?this.setAttribute("loading",e):this.removeAttribute("loading")}get disabled(){return this.hasAttribute("disabled")}set disabled(e){e?this.setAttribute("disabled",""):this.removeAttribute("disabled")}get autoscroll(){return this.hasAttribute("autoscroll")}set autoscroll(e){e?this.setAttribute("autoscroll",""):this.removeAttribute("autoscroll")}get complete(){return!this.delegate.isLoading}get isActive(){return this.ownerDocument===document&&!this.isPreview}get isPreview(){var e,r;return(r=(e=this.ownerDocument)===null||e===void 0?void 0:e.documentElement)===null||r===void 0?void 0:r.hasAttribute("data-turbo-preview")}};function ia(t){switch(t.toLowerCase()){case"lazy":return Te.lazy;default:return Te.eager}}function ne(t){return new URL(t.toString(),document.baseURI)}function xe(t){let e;if(t.hash)return t.hash.slice(1);if(e=t.href.match(/#(.*)$/))return e[1]}function na(t){return(ua(t).match(/\.[^.]*$/)||[])[0]||""}function sa(t){return!!na(t).match(/^(?:|\.(?:htm|html|xhtml))$/)}function oa(t,e){let r=ca(e);return t.href===ne(r).href||t.href.startsWith(r)}function Er(t){let e=xe(t);return e!=null?t.href.slice(0,-(e.length+1)):t.href}function Vt(t){return Er(t)}function aa(t,e){return ne(t).href==ne(e).href}function la(t){return t.pathname.split("/").slice(1)}function ua(t){return la(t).slice(-1)[0]}function ca(t){return ha(t.origin+t.pathname)}function ha(t){return t.endsWith("/")?t:t+"/"}var Tr=class{constructor(e){this.response=e}get succeeded(){return this.response.ok}get failed(){return!this.succeeded}get clientError(){return this.statusCode>=400&&this.statusCode<=499}get serverError(){return this.statusCode>=500&&this.statusCode<=599}get redirected(){return this.response.redirected}get location(){return ne(this.response.url)}get isHTML(){return this.contentType&&this.contentType.match(/^(?:text\/([^\s;,]+\b)?html|application\/xhtml\+xml)\b/)}get statusCode(){return this.response.status}get contentType(){return this.header("Content-Type")}get responseText(){return this.response.text()}get responseHTML(){return this.isHTML?this.response.text():Promise.resolve(void 0)}header(e){return this.response.headers.get(e)}};function _(t,{target:e,cancelable:r,detail:i}={}){let n=new CustomEvent(t,{cancelable:r,bubbles:!0,detail:i});return(e||document.documentElement).dispatchEvent(n),n}function Bt(){return new Promise(t=>requestAnimationFrame(()=>t()))}function da(){return new Promise(t=>setTimeout(()=>t(),0))}function fa(){return Promise.resolve()}function Ci(t=""){return new DOMParser().parseFromString(t,"text/html")}function Li(t,...e){let r=ma(t,e).replace(/^\n/,"").split(` +`),i=r[0].match(/^\s+/),n=i?i[0].length:0;return r.map(s=>s.slice(n)).join(` +`)}function ma(t,e){return t.reduce((r,i,n)=>{let s=e[n]==null?"":e[n];return r+i+s},"")}function ht(){return Array.apply(null,{length:36}).map((t,e)=>e==8||e==13||e==18||e==23?"-":e==14?"4":e==19?(Math.floor(Math.random()*4)+8).toString(16):Math.floor(Math.random()*15).toString(16)).join("")}var F;(function(t){t[t.get=0]="get",t[t.post=1]="post",t[t.put=2]="put",t[t.patch=3]="patch",t[t.delete=4]="delete"})(F||(F={}));function pa(t){switch(t.toLowerCase()){case"get":return F.get;case"post":return F.post;case"put":return F.put;case"patch":return F.patch;case"delete":return F.delete}}var jt=class{constructor(e,r,i,n=new URLSearchParams){this.abortController=new AbortController,this.resolveRequestPromise=s=>{},this.delegate=e,this.method=r,this.headers=this.defaultHeaders,this.isIdempotent?this.url=ga(i,[...n.entries()]):(this.body=n,this.url=i)}get location(){return this.url}get params(){return this.url.searchParams}get entries(){return this.body?Array.from(this.body.entries()):[]}cancel(){this.abortController.abort()}async perform(){var e,r;let{fetchOptions:i}=this;(r=(e=this.delegate).prepareHeadersForRequest)===null||r===void 0||r.call(e,this.headers,this),await this.allowRequestToBeIntercepted(i);try{this.delegate.requestStarted(this);let n=await fetch(this.url.href,i);return await this.receive(n)}catch(n){if(n.name!=="AbortError")throw this.delegate.requestErrored(this,n),n}finally{this.delegate.requestFinished(this)}}async receive(e){let r=new Tr(e);return _("turbo:before-fetch-response",{cancelable:!0,detail:{fetchResponse:r}}).defaultPrevented?this.delegate.requestPreventedHandlingResponse(this,r):r.succeeded?this.delegate.requestSucceededWithResponse(this,r):this.delegate.requestFailedWithResponse(this,r),r}get fetchOptions(){var e;return{method:F[this.method].toUpperCase(),credentials:"same-origin",headers:this.headers,redirect:"follow",body:this.body,signal:this.abortSignal,referrer:(e=this.delegate.referrer)===null||e===void 0?void 0:e.href}}get defaultHeaders(){return{Accept:"text/html, application/xhtml+xml"}}get isIdempotent(){return this.method==F.get}get abortSignal(){return this.abortController.signal}async allowRequestToBeIntercepted(e){let r=new Promise(n=>this.resolveRequestPromise=n);_("turbo:before-fetch-request",{cancelable:!0,detail:{fetchOptions:e,url:this.url.href,resume:this.resolveRequestPromise}}).defaultPrevented&&await r}};function ga(t,e){let r=new URLSearchParams(t.search);for(let[i,n]of e)n instanceof File||(r.has(i)?(r.delete(i),t.searchParams.set(i,n)):t.searchParams.append(i,n));return t}var Ii=class{constructor(e,r){this.started=!1,this.intersect=i=>{let n=i.slice(-1)[0];(n==null?void 0:n.isIntersecting)&&this.delegate.elementAppearedInViewport(this.element)},this.delegate=e,this.element=r,this.intersectionObserver=new IntersectionObserver(this.intersect)}start(){this.started||(this.started=!0,this.intersectionObserver.observe(this.element))}stop(){this.started&&(this.started=!1,this.intersectionObserver.unobserve(this.element))}},Ze=class{constructor(e){this.templateElement=document.createElement("template"),this.templateElement.innerHTML=e}static wrap(e){return typeof e=="string"?new this(e):e}get fragment(){let e=document.createDocumentFragment();for(let r of this.foreignElements)e.appendChild(document.importNode(r,!0));return e}get foreignElements(){return this.templateChildren.reduce((e,r)=>r.tagName.toLowerCase()=="turbo-stream"?[...e,r]:e,[])}get templateChildren(){return Array.from(this.templateElement.content.children)}};Ze.contentType="text/vnd.turbo-stream.html";var ke;(function(t){t[t.initialized=0]="initialized",t[t.requesting=1]="requesting",t[t.waiting=2]="waiting",t[t.receiving=3]="receiving",t[t.stopping=4]="stopping",t[t.stopped=5]="stopped"})(ke||(ke={}));var Ae;(function(t){t.urlEncoded="application/x-www-form-urlencoded",t.multipart="multipart/form-data",t.plain="text/plain"})(Ae||(Ae={}));function va(t){switch(t.toLowerCase()){case Ae.multipart:return Ae.multipart;case Ae.plain:return Ae.plain;default:return Ae.urlEncoded}}var kr=class{constructor(e,r,i,n=!1){this.state=ke.initialized,this.delegate=e,this.formElement=r,this.submitter=i,this.formData=ya(r,i),this.fetchRequest=new jt(this,this.method,this.location,this.body),this.mustRedirect=n}get method(){var e;let r=((e=this.submitter)===null||e===void 0?void 0:e.getAttribute("formmethod"))||this.formElement.getAttribute("method")||"";return pa(r.toLowerCase())||F.get}get action(){var e;let r=typeof this.formElement.action=="string"?this.formElement.action:null;return((e=this.submitter)===null||e===void 0?void 0:e.getAttribute("formaction"))||this.formElement.getAttribute("action")||r||""}get location(){return ne(this.action)}get body(){return this.enctype==Ae.urlEncoded||this.method==F.get?new URLSearchParams(this.stringFormData):this.formData}get enctype(){var e;return va(((e=this.submitter)===null||e===void 0?void 0:e.getAttribute("formenctype"))||this.formElement.enctype)}get isIdempotent(){return this.fetchRequest.isIdempotent}get stringFormData(){return[...this.formData].reduce((e,[r,i])=>e.concat(typeof i=="string"?[[r,i]]:[]),[])}async start(){let{initialized:e,requesting:r}=ke;if(this.state==e)return this.state=r,this.fetchRequest.perform()}stop(){let{stopping:e,stopped:r}=ke;if(this.state!=e&&this.state!=r)return this.state=e,this.fetchRequest.cancel(),!0}prepareHeadersForRequest(e,r){if(!r.isIdempotent){let i=ba(Pi("csrf-param"))||Pi("csrf-token");i&&(e["X-CSRF-Token"]=i),e.Accept=[Ze.contentType,e.Accept].join(", ")}}requestStarted(e){this.state=ke.waiting,_("turbo:submit-start",{target:this.formElement,detail:{formSubmission:this}}),this.delegate.formSubmissionStarted(this)}requestPreventedHandlingResponse(e,r){this.result={success:r.succeeded,fetchResponse:r}}requestSucceededWithResponse(e,r){if(r.clientError||r.serverError)this.delegate.formSubmissionFailedWithResponse(this,r);else if(this.requestMustRedirect(e)&&wa(r)){let i=new Error("Form responses must redirect to another location");this.delegate.formSubmissionErrored(this,i)}else this.state=ke.receiving,this.result={success:!0,fetchResponse:r},this.delegate.formSubmissionSucceededWithResponse(this,r)}requestFailedWithResponse(e,r){this.result={success:!1,fetchResponse:r},this.delegate.formSubmissionFailedWithResponse(this,r)}requestErrored(e,r){this.result={success:!1,error:r},this.delegate.formSubmissionErrored(this,r)}requestFinished(e){this.state=ke.stopped,_("turbo:submit-end",{target:this.formElement,detail:Object.assign({formSubmission:this},this.result)}),this.delegate.formSubmissionFinished(this)}requestMustRedirect(e){return!e.isIdempotent&&this.mustRedirect}};function ya(t,e){let r=new FormData(t),i=e==null?void 0:e.getAttribute("name"),n=e==null?void 0:e.getAttribute("value");return i&&n!=null&&r.get(i)!=n&&r.append(i,n),r}function ba(t){if(t!=null){let r=(document.cookie?document.cookie.split("; "):[]).find(i=>i.startsWith(t));if(r){let i=r.split("=").slice(1).join("=");return i?decodeURIComponent(i):void 0}}}function Pi(t){let e=document.querySelector(`meta[name="${t}"]`);return e&&e.content}function wa(t){return t.statusCode==200&&!t.redirected}var dt=class{constructor(e){this.element=e}get children(){return[...this.element.children]}hasAnchor(e){return this.getElementForAnchor(e)!=null}getElementForAnchor(e){return e?this.element.querySelector(`[id='${e}'], a[name='${e}']`):null}get isConnected(){return this.element.isConnected}get firstAutofocusableElement(){return this.element.querySelector("[autofocus]")}get permanentElements(){return[...this.element.querySelectorAll("[id][data-turbo-permanent]")]}getPermanentElementById(e){return this.element.querySelector(`#${e}[data-turbo-permanent]`)}getPermanentElementMapForSnapshot(e){let r={};for(let i of this.permanentElements){let{id:n}=i,s=e.getPermanentElementById(n);s&&(r[n]=[i,s])}return r}},Ar=class{constructor(e,r){this.submitBubbled=i=>{if(i.target instanceof HTMLFormElement){let n=i.target,s=i.submitter||void 0;this.delegate.shouldInterceptFormSubmission(n,s)&&(i.preventDefault(),i.stopImmediatePropagation(),this.delegate.formSubmissionIntercepted(n,s))}},this.delegate=e,this.element=r}start(){this.element.addEventListener("submit",this.submitBubbled)}stop(){this.element.removeEventListener("submit",this.submitBubbled)}},Or=class{constructor(e,r){this.resolveRenderPromise=i=>{},this.resolveInterceptionPromise=i=>{},this.delegate=e,this.element=r}scrollToAnchor(e){let r=this.snapshot.getElementForAnchor(e);r?(this.scrollToElement(r),this.focusElement(r)):this.scrollToPosition({x:0,y:0})}scrollToAnchorFromLocation(e){this.scrollToAnchor(xe(e))}scrollToElement(e){e.scrollIntoView()}focusElement(e){e instanceof HTMLElement&&(e.hasAttribute("tabindex")?e.focus():(e.setAttribute("tabindex","-1"),e.focus(),e.removeAttribute("tabindex")))}scrollToPosition({x:e,y:r}){this.scrollRoot.scrollTo(e,r)}scrollToTop(){this.scrollToPosition({x:0,y:0})}get scrollRoot(){return window}async render(e){let{isPreview:r,shouldRender:i,newSnapshot:n}=e;if(i)try{this.renderPromise=new Promise(a=>this.resolveRenderPromise=a),this.renderer=e,this.prepareToRenderSnapshot(e);let s=new Promise(a=>this.resolveInterceptionPromise=a);this.delegate.allowsImmediateRender(n,this.resolveInterceptionPromise)||await s,await this.renderSnapshot(e),this.delegate.viewRenderedSnapshot(n,r),this.finishRenderingSnapshot(e)}finally{delete this.renderer,this.resolveRenderPromise(void 0),delete this.renderPromise}else this.invalidate()}invalidate(){this.delegate.viewInvalidated()}prepareToRenderSnapshot(e){this.markAsPreview(e.isPreview),e.prepareToRender()}markAsPreview(e){e?this.element.setAttribute("data-turbo-preview",""):this.element.removeAttribute("data-turbo-preview")}async renderSnapshot(e){await e.render()}finishRenderingSnapshot(e){e.finishRendering()}},Mi=class extends Or{invalidate(){this.element.innerHTML=""}get snapshot(){return new dt(this.element)}},Cr=class{constructor(e,r){this.clickBubbled=i=>{this.respondsToEventTarget(i.target)?this.clickEvent=i:delete this.clickEvent},this.linkClicked=i=>{this.clickEvent&&this.respondsToEventTarget(i.target)&&i.target instanceof Element&&this.delegate.shouldInterceptLinkClick(i.target,i.detail.url)&&(this.clickEvent.preventDefault(),i.preventDefault(),this.delegate.linkClickIntercepted(i.target,i.detail.url)),delete this.clickEvent},this.willVisit=()=>{delete this.clickEvent},this.delegate=e,this.element=r}start(){this.element.addEventListener("click",this.clickBubbled),document.addEventListener("turbo:click",this.linkClicked),document.addEventListener("turbo:before-visit",this.willVisit)}stop(){this.element.removeEventListener("click",this.clickBubbled),document.removeEventListener("turbo:click",this.linkClicked),document.removeEventListener("turbo:before-visit",this.willVisit)}respondsToEventTarget(e){let r=e instanceof Element?e:e instanceof Node?e.parentElement:null;return r&&r.closest("turbo-frame, html")==this.element}},Ri=class{constructor(e){this.permanentElementMap=e}static preservingPermanentElements(e,r){let i=new this(e);i.enter(),r(),i.leave()}enter(){for(let e in this.permanentElementMap){let[,r]=this.permanentElementMap[e];this.replaceNewPermanentElementWithPlaceholder(r)}}leave(){for(let e in this.permanentElementMap){let[r]=this.permanentElementMap[e];this.replaceCurrentPermanentElementWithClone(r),this.replacePlaceholderWithPermanentElement(r)}}replaceNewPermanentElementWithPlaceholder(e){let r=Sa(e);e.replaceWith(r)}replaceCurrentPermanentElementWithClone(e){let r=e.cloneNode(!0);e.replaceWith(r)}replacePlaceholderWithPermanentElement(e){let r=this.getPlaceholderById(e.id);r==null||r.replaceWith(e)}getPlaceholderById(e){return this.placeholders.find(r=>r.content==e)}get placeholders(){return[...document.querySelectorAll("meta[name=turbo-permanent-placeholder][content]")]}};function Sa(t){let e=document.createElement("meta");return e.setAttribute("name","turbo-permanent-placeholder"),e.setAttribute("content",t.id),e}var Ut=class{constructor(e,r,i){this.currentSnapshot=e,this.newSnapshot=r,this.isPreview=i,this.promise=new Promise((n,s)=>this.resolvingFunctions={resolve:n,reject:s})}get shouldRender(){return!0}prepareToRender(){}finishRendering(){this.resolvingFunctions&&(this.resolvingFunctions.resolve(),delete this.resolvingFunctions)}createScriptElement(e){if(e.getAttribute("data-turbo-eval")=="false")return e;{let r=document.createElement("script");return this.cspNonce&&(r.nonce=this.cspNonce),r.textContent=e.textContent,r.async=!1,Ea(r,e),r}}preservingPermanentElements(e){Ri.preservingPermanentElements(this.permanentElementMap,e)}focusFirstAutofocusableElement(){let e=this.connectedSnapshot.firstAutofocusableElement;Ta(e)&&e.focus()}get connectedSnapshot(){return this.newSnapshot.isConnected?this.newSnapshot:this.currentSnapshot}get currentElement(){return this.currentSnapshot.element}get newElement(){return this.newSnapshot.element}get permanentElementMap(){return this.currentSnapshot.getPermanentElementMapForSnapshot(this.newSnapshot)}get cspNonce(){var e;return(e=document.head.querySelector('meta[name="csp-nonce"]'))===null||e===void 0?void 0:e.getAttribute("content")}};function Ea(t,e){for(let{name:r,value:i}of[...e.attributes])t.setAttribute(r,i)}function Ta(t){return t&&typeof t.focus=="function"}var Di=class extends Ut{get shouldRender(){return!0}async render(){await Bt(),this.preservingPermanentElements(()=>{this.loadFrameElement()}),this.scrollFrameIntoView(),await Bt(),this.focusFirstAutofocusableElement(),await Bt(),this.activateScriptElements()}loadFrameElement(){var e;let r=document.createRange();r.selectNodeContents(this.currentElement),r.deleteContents();let i=this.newElement,n=(e=i.ownerDocument)===null||e===void 0?void 0:e.createRange();n&&(n.selectNodeContents(i),this.currentElement.appendChild(n.extractContents()))}scrollFrameIntoView(){if(this.currentElement.autoscroll||this.newElement.autoscroll){let e=this.currentElement.firstElementChild,r=ka(this.currentElement.getAttribute("data-autoscroll-block"),"end");if(e)return e.scrollIntoView({block:r}),!0}return!1}activateScriptElements(){for(let e of this.newScriptElements){let r=this.createScriptElement(e);e.replaceWith(r)}}get newScriptElements(){return this.currentElement.querySelectorAll("script")}};function ka(t,e){return t=="end"||t=="start"||t=="center"||t=="nearest"?t:e}var se=class{constructor(){this.hiding=!1,this.value=0,this.visible=!1,this.trickle=()=>{this.setValue(this.value+Math.random()/100)},this.stylesheetElement=this.createStylesheetElement(),this.progressElement=this.createProgressElement(),this.installStylesheetElement(),this.setValue(0)}static get defaultCSS(){return Li` .turbo-progress-bar { position: fixed; display: block; @@ -10,11 +11,11 @@ background: #0076ff; z-index: 9999; transition: - width ${g.animationDuration}ms ease-out, - opacity ${g.animationDuration/2}ms ${g.animationDuration/2}ms ease-in; + width ${se.animationDuration}ms ease-out, + opacity ${se.animationDuration/2}ms ${se.animationDuration/2}ms ease-in; transform: translate3d(0, 0, 0); } - `}show(){this.visible||(this.visible=!0,this.installProgressElement(),this.startTrickling())}hide(){this.visible&&!this.hiding&&(this.hiding=!0,this.fadeProgressElement(()=>{this.uninstallProgressElement(),this.stopTrickling(),this.visible=!1,this.hiding=!1}))}setValue(e){this.value=e,this.refresh()}installStylesheetElement(){document.head.insertBefore(this.stylesheetElement,document.head.firstChild)}installProgressElement(){this.progressElement.style.width="0",this.progressElement.style.opacity="1",document.documentElement.insertBefore(this.progressElement,document.body),this.refresh()}fadeProgressElement(e){this.progressElement.style.opacity="0",setTimeout(e,g.animationDuration*1.5)}uninstallProgressElement(){this.progressElement.parentNode&&document.documentElement.removeChild(this.progressElement)}startTrickling(){this.trickleInterval||(this.trickleInterval=window.setInterval(this.trickle,g.animationDuration))}stopTrickling(){window.clearInterval(this.trickleInterval),delete this.trickleInterval}refresh(){requestAnimationFrame(()=>{this.progressElement.style.width=`${10+this.value*90}%`})}createStylesheetElement(){let e=document.createElement("style");return e.type="text/css",e.textContent=g.defaultCSS,e}createProgressElement(){let e=document.createElement("div");return e.className="turbo-progress-bar",e}};g.animationDuration=300;var ae=class extends M{constructor(){super(...arguments);this.detailsByOuterHTML=this.children.filter(e=>!jt(e)).reduce((e,t)=>{let{outerHTML:n}=t,i=n in e?e[n]:{type:Nt(t),tracked:qt(t),elements:[]};return Object.assign(Object.assign({},e),{[n]:Object.assign(Object.assign({},i),{elements:[...i.elements,t]})})},{})}get trackedElementSignature(){return Object.keys(this.detailsByOuterHTML).filter(e=>this.detailsByOuterHTML[e].tracked).join("")}getScriptElementsNotInSnapshot(e){return this.getElementsMatchingTypeNotInSnapshot("script",e)}getStylesheetElementsNotInSnapshot(e){return this.getElementsMatchingTypeNotInSnapshot("stylesheet",e)}getElementsMatchingTypeNotInSnapshot(e,t){return Object.keys(this.detailsByOuterHTML).filter(n=>!(n in t.detailsByOuterHTML)).map(n=>this.detailsByOuterHTML[n]).filter(({type:n})=>n==e).map(({elements:[n]})=>n)}get provisionalElements(){return Object.keys(this.detailsByOuterHTML).reduce((e,t)=>{let{type:n,tracked:i,elements:s}=this.detailsByOuterHTML[t];return n==null&&!i?[...e,...s]:s.length>1?[...e,...s.slice(1)]:e},[])}getMetaValue(e){let t=this.findMetaElementByName(e);return t?t.getAttribute("content"):null}findMetaElementByName(e){return Object.keys(this.detailsByOuterHTML).reduce((t,n)=>{let{elements:[i]}=this.detailsByOuterHTML[n];return Ht(i,e)?i:t},void 0)}};function Nt(r){if(Vt(r))return"script";if(Dt(r))return"stylesheet"}function qt(r){return r.getAttribute("data-turbo-track")=="reload"}function Vt(r){return r.tagName.toLowerCase()=="script"}function jt(r){return r.tagName.toLowerCase()=="noscript"}function Dt(r){let e=r.tagName.toLowerCase();return e=="style"||e=="link"&&r.getAttribute("rel")=="stylesheet"}function Ht(r,e){return r.tagName.toLowerCase()=="meta"&&r.getAttribute("name")==e}var b=class extends M{constructor(e,t){super(e);this.headSnapshot=t}static fromHTMLString(e=""){return this.fromDocument(ee(e))}static fromElement(e){return this.fromDocument(e.ownerDocument)}static fromDocument({head:e,body:t}){return new this(t,new ae(e))}clone(){return new b(this.element.cloneNode(!0),this.headSnapshot)}get headElement(){return this.headSnapshot.element}get rootLocation(){var e;let t=(e=this.getSetting("root"))!==null&&e!==void 0?e:"/";return m(t)}get cacheControlValue(){return this.getSetting("cache-control")}get isPreviewable(){return this.cacheControlValue!="no-preview"}get isCacheable(){return this.cacheControlValue!="no-cache"}get isVisitable(){return this.getSetting("visit-control")!="reload"}getSetting(e){return this.headSnapshot.getMetaValue(`turbo-${e}`)}},T;(function(r){r.visitStart="visitStart",r.requestStart="requestStart",r.requestEnd="requestEnd",r.visitEnd="visitEnd"})(T||(T={}));var p;(function(r){r.initialized="initialized",r.started="started",r.canceled="canceled",r.failed="failed",r.completed="completed"})(p||(p={}));var _t={action:"advance",historyChanged:!1},A;(function(r){r[r.networkFailure=0]="networkFailure",r[r.timeoutFailure=-1]="timeoutFailure",r[r.contentTypeMismatch=-2]="contentTypeMismatch"})(A||(A={}));var ce=class{constructor(e,t,n,i={}){this.identifier=k(),this.timingMetrics={},this.followedRedirect=!1,this.historyChanged=!1,this.scrolled=!1,this.snapshotCached=!1,this.state=p.initialized,this.delegate=e,this.location=t,this.restorationIdentifier=n||k();let{action:s,historyChanged:o,referrer:c,snapshotHTML:l,response:a}=Object.assign(Object.assign({},_t),i);this.action=s,this.historyChanged=o,this.referrer=c,this.snapshotHTML=l,this.response=a,this.isSamePage=this.delegate.locationWithActionIsSamePage(this.location,this.action)}get adapter(){return this.delegate.adapter}get view(){return this.delegate.view}get history(){return this.delegate.history}get restorationData(){return this.history.getRestorationDataForIdentifier(this.restorationIdentifier)}get silent(){return this.isSamePage}start(){this.state==p.initialized&&(this.recordTimingMetric(T.visitStart),this.state=p.started,this.adapter.visitStarted(this),this.delegate.visitStarted(this))}cancel(){this.state==p.started&&(this.request&&this.request.cancel(),this.cancelRender(),this.state=p.canceled)}complete(){this.state==p.started&&(this.recordTimingMetric(T.visitEnd),this.state=p.completed,this.adapter.visitCompleted(this),this.delegate.visitCompleted(this),this.followRedirect())}fail(){this.state==p.started&&(this.state=p.failed,this.adapter.visitFailed(this))}changeHistory(){var e;if(!this.historyChanged){let t=this.location.href===((e=this.referrer)===null||e===void 0?void 0:e.href)?"replace":this.action,n=this.getHistoryMethodForAction(t);this.history.update(n,this.location,this.restorationIdentifier),this.historyChanged=!0}}issueRequest(){this.hasPreloadedResponse()?this.simulateRequest():this.shouldIssueRequest()&&!this.request&&(this.request=new I(this,h.get,this.location),this.request.perform())}simulateRequest(){this.response&&(this.startRequest(),this.recordResponse(),this.finishRequest())}startRequest(){this.recordTimingMetric(T.requestStart),this.adapter.visitRequestStarted(this)}recordResponse(e=this.response){if(this.response=e,e){let{statusCode:t}=e;le(t)?this.adapter.visitRequestCompleted(this):this.adapter.visitRequestFailedWithStatusCode(this,t)}}finishRequest(){this.recordTimingMetric(T.requestEnd),this.adapter.visitRequestFinished(this)}loadResponse(){if(this.response){let{statusCode:e,responseHTML:t}=this.response;this.render(async()=>{this.cacheSnapshot(),this.view.renderPromise&&await this.view.renderPromise,le(e)&&t!=null?(await this.view.renderPage(b.fromHTMLString(t)),this.adapter.visitRendered(this),this.complete()):(await this.view.renderError(b.fromHTMLString(t)),this.adapter.visitRendered(this),this.fail())})}}getCachedSnapshot(){let e=this.view.getCachedSnapshotForLocation(this.location)||this.getPreloadedSnapshot();if(e&&(!P(this.location)||e.hasAnchor(P(this.location)))&&(this.action=="restore"||e.isPreviewable))return e}getPreloadedSnapshot(){if(this.snapshotHTML)return b.fromHTMLString(this.snapshotHTML)}hasCachedSnapshot(){return this.getCachedSnapshot()!=null}loadCachedSnapshot(){let e=this.getCachedSnapshot();if(e){let t=this.shouldIssueRequest();this.render(async()=>{this.cacheSnapshot(),this.isSamePage?this.adapter.visitRendered(this):(this.view.renderPromise&&await this.view.renderPromise,await this.view.renderPage(e,t),this.adapter.visitRendered(this),t||this.complete())})}}followRedirect(){this.redirectedToLocation&&!this.followedRedirect&&(this.adapter.visitProposedToLocation(this.redirectedToLocation,{action:"replace",response:this.response}),this.followedRedirect=!0)}goToSamePageAnchor(){this.isSamePage&&this.render(async()=>{this.cacheSnapshot(),this.adapter.visitRendered(this)})}requestStarted(){this.startRequest()}requestPreventedHandlingResponse(e,t){}async requestSucceededWithResponse(e,t){let n=await t.responseHTML;n==null?this.recordResponse({statusCode:A.contentTypeMismatch}):(this.redirectedToLocation=t.redirected?t.location:void 0,this.recordResponse({statusCode:t.statusCode,responseHTML:n}))}async requestFailedWithResponse(e,t){let n=await t.responseHTML;n==null?this.recordResponse({statusCode:A.contentTypeMismatch}):this.recordResponse({statusCode:t.statusCode,responseHTML:n})}requestErrored(e,t){this.recordResponse({statusCode:A.networkFailure})}requestFinished(){this.finishRequest()}performScroll(){this.scrolled||(this.action=="restore"?this.scrollToRestoredPosition()||this.scrollToAnchor()||this.view.scrollToTop():this.scrollToAnchor()||this.view.scrollToTop(),this.isSamePage&&this.delegate.visitScrolledToSamePageLocation(this.view.lastRenderedLocation,this.location),this.scrolled=!0)}scrollToRestoredPosition(){let{scrollPosition:e}=this.restorationData;if(e)return this.view.scrollToPosition(e),!0}scrollToAnchor(){let e=P(this.location);if(e!=null)return this.view.scrollToAnchor(e),!0}recordTimingMetric(e){this.timingMetrics[e]=new Date().getTime()}getTimingMetrics(){return Object.assign({},this.timingMetrics)}getHistoryMethodForAction(e){switch(e){case"replace":return history.replaceState;case"advance":case"restore":return history.pushState}}hasPreloadedResponse(){return typeof this.response=="object"}shouldIssueRequest(){return this.isSamePage?!1:this.action=="restore"?!this.hasCachedSnapshot():!0}cacheSnapshot(){this.snapshotCached||(this.view.cacheSnapshot(),this.snapshotCached=!0)}async render(e){this.cancelRender(),await new Promise(t=>{this.frame=requestAnimationFrame(()=>t())}),await e(),delete this.frame,this.performScroll()}cancelRender(){this.frame&&(cancelAnimationFrame(this.frame),delete this.frame)}};function le(r){return r>=200&&r<300}var ue=class{constructor(e){this.progressBar=new g,this.showProgressBar=()=>{this.progressBar.show()},this.session=e}visitProposedToLocation(e,t){this.navigator.startVisit(e,k(),t)}visitStarted(e){e.issueRequest(),e.changeHistory(),e.goToSamePageAnchor(),e.loadCachedSnapshot()}visitRequestStarted(e){this.progressBar.setValue(0),e.hasCachedSnapshot()||e.action!="restore"?this.showVisitProgressBarAfterDelay():this.showProgressBar()}visitRequestCompleted(e){e.loadResponse()}visitRequestFailedWithStatusCode(e,t){switch(t){case A.networkFailure:case A.timeoutFailure:case A.contentTypeMismatch:return this.reload();default:return e.loadResponse()}}visitRequestFinished(e){this.progressBar.setValue(1),this.hideVisitProgressBar()}visitCompleted(e){}pageInvalidated(){this.reload()}visitFailed(e){}visitRendered(e){}formSubmissionStarted(e){this.progressBar.setValue(0),this.showFormProgressBarAfterDelay()}formSubmissionFinished(e){this.progressBar.setValue(1),this.hideFormProgressBar()}showVisitProgressBarAfterDelay(){this.visitProgressBarTimeout=window.setTimeout(this.showProgressBar,this.session.progressBarDelay)}hideVisitProgressBar(){this.progressBar.hide(),this.visitProgressBarTimeout!=null&&(window.clearTimeout(this.visitProgressBarTimeout),delete this.visitProgressBarTimeout)}showFormProgressBarAfterDelay(){this.formProgressBarTimeout==null&&(this.formProgressBarTimeout=window.setTimeout(this.showProgressBar,this.session.progressBarDelay))}hideFormProgressBar(){this.progressBar.hide(),this.formProgressBarTimeout!=null&&(window.clearTimeout(this.formProgressBarTimeout),delete this.formProgressBarTimeout)}reload(){window.location.reload()}get navigator(){return this.session.navigator}},he=class{constructor(){this.started=!1}start(){this.started||(this.started=!0,addEventListener("turbo:before-cache",this.removeStaleElements,!1))}stop(){this.started&&(this.started=!1,removeEventListener("turbo:before-cache",this.removeStaleElements,!1))}removeStaleElements(){let e=[...document.querySelectorAll('[data-turbo-cache="false"]')];for(let t of e)t.remove()}},de=class{constructor(e){this.started=!1,this.submitCaptured=()=>{removeEventListener("submit",this.submitBubbled,!1),addEventListener("submit",this.submitBubbled,!1)},this.submitBubbled=t=>{if(!t.defaultPrevented){let n=t.target instanceof HTMLFormElement?t.target:void 0,i=t.submitter||void 0;n&&((i==null?void 0:i.getAttribute("formmethod"))||n.method)!="dialog"&&this.delegate.willSubmitForm(n,i)&&(t.preventDefault(),this.delegate.formSubmitted(n,i))}},this.delegate=e}start(){this.started||(addEventListener("submit",this.submitCaptured,!0),this.started=!0)}stop(){this.started&&(removeEventListener("submit",this.submitCaptured,!0),this.started=!1)}},fe=class{constructor(e){this.element=e,this.linkInterceptor=new $(this,e),this.formInterceptor=new K(this,e)}start(){this.linkInterceptor.start(),this.formInterceptor.start()}stop(){this.linkInterceptor.stop(),this.formInterceptor.stop()}shouldInterceptLinkClick(e,t){return this.shouldRedirect(e)}linkClickIntercepted(e,t){let n=this.findFrameElement(e);n&&(n.setAttribute("reloadable",""),n.src=t)}shouldInterceptFormSubmission(e,t){return this.shouldRedirect(e,t)}formSubmissionIntercepted(e,t){let n=this.findFrameElement(e);n&&(n.removeAttribute("reloadable"),n.delegate.formSubmissionIntercepted(e,t))}shouldRedirect(e,t){let n=this.findFrameElement(e);return n?n!=e.closest("turbo-frame"):!1}findFrameElement(e){let t=e.getAttribute("data-turbo-frame");if(t&&t!="_top"){let n=this.element.querySelector(`#${t}:not([disabled])`);if(n instanceof v)return n}}},pe=class{constructor(e){this.restorationIdentifier=k(),this.restorationData={},this.started=!1,this.pageLoaded=!1,this.onPopState=t=>{if(this.shouldHandlePopState()){let{turbo:n}=t.state||{};if(n){this.location=new URL(window.location.href);let{restorationIdentifier:i}=n;this.restorationIdentifier=i,this.delegate.historyPoppedToLocationWithRestorationIdentifier(this.location,i)}}},this.onPageLoad=async t=>{await Pt(),this.pageLoaded=!0},this.delegate=e}start(){this.started||(addEventListener("popstate",this.onPopState,!1),addEventListener("load",this.onPageLoad,!1),this.started=!0,this.replace(new URL(window.location.href)))}stop(){this.started&&(removeEventListener("popstate",this.onPopState,!1),removeEventListener("load",this.onPageLoad,!1),this.started=!1)}push(e,t){this.update(history.pushState,e,t)}replace(e,t){this.update(history.replaceState,e,t)}update(e,t,n=k()){let i={turbo:{restorationIdentifier:n}};e.call(history,i,"",t.href),this.location=t,this.restorationIdentifier=n}getRestorationDataForIdentifier(e){return this.restorationData[e]||{}}updateRestorationData(e){let{restorationIdentifier:t}=this,n=this.restorationData[t];this.restorationData[t]=Object.assign(Object.assign({},n),e)}assumeControlOfScrollRestoration(){var e;this.previousScrollRestoration||(this.previousScrollRestoration=(e=history.scrollRestoration)!==null&&e!==void 0?e:"auto",history.scrollRestoration="manual")}relinquishControlOfScrollRestoration(){this.previousScrollRestoration&&(history.scrollRestoration=this.previousScrollRestoration,delete this.previousScrollRestoration)}shouldHandlePopState(){return this.pageIsLoaded()}pageIsLoaded(){return this.pageLoaded||document.readyState=="complete"}},me=class{constructor(e){this.started=!1,this.clickCaptured=()=>{removeEventListener("click",this.clickBubbled,!1),addEventListener("click",this.clickBubbled,!1)},this.clickBubbled=t=>{if(this.clickEventIsSignificant(t)){let n=t.composedPath&&t.composedPath()[0]||t.target,i=this.findLinkFromClickTarget(n);if(i){let s=this.getLocationForLink(i);this.delegate.willFollowLinkToLocation(i,s)&&(t.preventDefault(),this.delegate.followedLinkToLocation(i,s))}}},this.delegate=e}start(){this.started||(addEventListener("click",this.clickCaptured,!0),this.started=!0)}stop(){this.started&&(removeEventListener("click",this.clickCaptured,!0),this.started=!1)}clickEventIsSignificant(e){return!(e.target&&e.target.isContentEditable||e.defaultPrevented||e.which>1||e.altKey||e.ctrlKey||e.metaKey||e.shiftKey)}findLinkFromClickTarget(e){if(e instanceof Element)return e.closest("a[href]:not([target^=_]):not([download])")}getLocationForLink(e){return m(e.getAttribute("href")||"")}};function ge(r){return r=="advance"||r=="replace"||r=="restore"}var ve=class{constructor(e){this.delegate=e}proposeVisit(e,t={}){this.delegate.allowsVisitingLocationWithAction(e,t.action)&&this.delegate.visitProposedToLocation(e,t)}startVisit(e,t,n={}){this.stop(),this.currentVisit=new ce(this,m(e),t,Object.assign({referrer:this.location},n)),this.currentVisit.start()}submitForm(e,t){this.stop(),this.formSubmission=new U(this,e,t,!0),this.formSubmission.isIdempotent?this.proposeVisit(this.formSubmission.fetchRequest.url,{action:this.getActionForFormSubmission(this.formSubmission)}):this.formSubmission.start()}stop(){this.formSubmission&&(this.formSubmission.stop(),delete this.formSubmission),this.currentVisit&&(this.currentVisit.cancel(),delete this.currentVisit)}get adapter(){return this.delegate.adapter}get view(){return this.delegate.view}get history(){return this.delegate.history}formSubmissionStarted(e){typeof this.adapter.formSubmissionStarted=="function"&&this.adapter.formSubmissionStarted(e)}async formSubmissionSucceededWithResponse(e,t){if(e==this.formSubmission){let n=await t.responseHTML;if(n){e.method!=h.get&&this.view.clearSnapshotCache();let{statusCode:i}=t,s={response:{statusCode:i,responseHTML:n}};this.proposeVisit(t.location,s)}}}async formSubmissionFailedWithResponse(e,t){let n=await t.responseHTML;if(n){let i=b.fromHTMLString(n);t.serverError?await this.view.renderError(i):await this.view.renderPage(i),this.view.scrollToTop(),this.view.clearSnapshotCache()}}formSubmissionErrored(e,t){console.error(t)}formSubmissionFinished(e){typeof this.adapter.formSubmissionFinished=="function"&&this.adapter.formSubmissionFinished(e)}visitStarted(e){this.delegate.visitStarted(e)}visitCompleted(e){this.delegate.visitCompleted(e)}locationWithActionIsSamePage(e,t){let n=P(e),i=P(this.view.lastRenderedLocation),s=t==="restore"&&typeof n=="undefined";return t!=="replace"&&_(e)===_(this.view.lastRenderedLocation)&&(s||n!=null&&n!==i)}visitScrolledToSamePageLocation(e,t){this.delegate.visitScrolledToSamePageLocation(e,t)}get location(){return this.history.location}get restorationIdentifier(){return this.history.restorationIdentifier}getActionForFormSubmission(e){let{formElement:t,submitter:n}=e,i=(n==null?void 0:n.getAttribute("data-turbo-action"))||t.getAttribute("data-turbo-action");return ge(i)?i:"advance"}},y;(function(r){r[r.initial=0]="initial",r[r.loading=1]="loading",r[r.interactive=2]="interactive",r[r.complete=3]="complete"})(y||(y={}));var be=class{constructor(e){this.stage=y.initial,this.started=!1,this.interpretReadyState=()=>{let{readyState:t}=this;t=="interactive"?this.pageIsInteractive():t=="complete"&&this.pageIsComplete()},this.pageWillUnload=()=>{this.delegate.pageWillUnload()},this.delegate=e}start(){this.started||(this.stage==y.initial&&(this.stage=y.loading),document.addEventListener("readystatechange",this.interpretReadyState,!1),addEventListener("pagehide",this.pageWillUnload,!1),this.started=!0)}stop(){this.started&&(document.removeEventListener("readystatechange",this.interpretReadyState,!1),removeEventListener("pagehide",this.pageWillUnload,!1),this.started=!1)}pageIsInteractive(){this.stage==y.loading&&(this.stage=y.interactive,this.delegate.pageBecameInteractive())}pageIsComplete(){this.pageIsInteractive(),this.stage==y.interactive&&(this.stage=y.complete,this.delegate.pageLoaded())}get readyState(){return document.readyState}},ye=class{constructor(e){this.started=!1,this.onScroll=()=>{this.updatePosition({x:window.pageXOffset,y:window.pageYOffset})},this.delegate=e}start(){this.started||(addEventListener("scroll",this.onScroll,!1),this.onScroll(),this.started=!0)}stop(){this.started&&(removeEventListener("scroll",this.onScroll,!1),this.started=!1)}updatePosition(e){this.delegate.scrollPositionChanged(e)}},we=class{constructor(e){this.sources=new Set,this.started=!1,this.inspectFetchResponse=t=>{let n=Wt(t);n&&Ut(n)&&(t.preventDefault(),this.receiveMessageResponse(n))},this.receiveMessageEvent=t=>{this.started&&typeof t.data=="string"&&this.receiveMessageHTML(t.data)},this.delegate=e}start(){this.started||(this.started=!0,addEventListener("turbo:before-fetch-response",this.inspectFetchResponse,!1))}stop(){this.started&&(this.started=!1,removeEventListener("turbo:before-fetch-response",this.inspectFetchResponse,!1))}connectStreamSource(e){this.streamSourceIsConnected(e)||(this.sources.add(e),e.addEventListener("message",this.receiveMessageEvent,!1))}disconnectStreamSource(e){this.streamSourceIsConnected(e)&&(this.sources.delete(e),e.removeEventListener("message",this.receiveMessageEvent,!1))}streamSourceIsConnected(e){return this.sources.has(e)}async receiveMessageResponse(e){let t=await e.responseHTML;t&&this.receiveMessageHTML(t)}receiveMessageHTML(e){this.delegate.receivedMessageFromStream(new L(e))}};function Wt(r){var e;let t=(e=r.detail)===null||e===void 0?void 0:e.fetchResponse;if(t instanceof W)return t}function Ut(r){var e;return((e=r.contentType)!==null&&e!==void 0?e:"").startsWith(L.contentType)}var Ee=class extends N{async render(){this.replaceHeadAndBody(),this.activateScriptElements()}replaceHeadAndBody(){let{documentElement:e,head:t,body:n}=document;e.replaceChild(this.newHead,t),e.replaceChild(this.newElement,n)}activateScriptElements(){for(let e of this.scriptElements){let t=e.parentNode;if(t){let n=this.createScriptElement(e);t.replaceChild(n,e)}}}get newHead(){return this.newSnapshot.headSnapshot.element}get scriptElements(){return[...document.documentElement.querySelectorAll("script")]}},J=class extends N{get shouldRender(){return this.newSnapshot.isVisitable&&this.trackedElementsAreIdentical}prepareToRender(){this.mergeHead()}async render(){this.replaceBody()}finishRendering(){super.finishRendering(),this.isPreview||this.focusFirstAutofocusableElement()}get currentHeadSnapshot(){return this.currentSnapshot.headSnapshot}get newHeadSnapshot(){return this.newSnapshot.headSnapshot}get newElement(){return this.newSnapshot.element}mergeHead(){this.copyNewHeadStylesheetElements(),this.copyNewHeadScriptElements(),this.removeCurrentHeadProvisionalElements(),this.copyNewHeadProvisionalElements()}replaceBody(){this.preservingPermanentElements(()=>{this.activateNewBody(),this.assignNewBody()})}get trackedElementsAreIdentical(){return this.currentHeadSnapshot.trackedElementSignature==this.newHeadSnapshot.trackedElementSignature}copyNewHeadStylesheetElements(){for(let e of this.newHeadStylesheetElements)document.head.appendChild(e)}copyNewHeadScriptElements(){for(let e of this.newHeadScriptElements)document.head.appendChild(this.createScriptElement(e))}removeCurrentHeadProvisionalElements(){for(let e of this.currentHeadProvisionalElements)document.head.removeChild(e)}copyNewHeadProvisionalElements(){for(let e of this.newHeadProvisionalElements)document.head.appendChild(e)}activateNewBody(){document.adoptNode(this.newElement),this.activateNewBodyScriptElements()}activateNewBodyScriptElements(){for(let e of this.newBodyScriptElements){let t=this.createScriptElement(e);e.replaceWith(t)}}assignNewBody(){document.body&&this.newElement instanceof HTMLBodyElement?document.body.replaceWith(this.newElement):document.documentElement.appendChild(this.newElement)}get newHeadStylesheetElements(){return this.newHeadSnapshot.getStylesheetElementsNotInSnapshot(this.currentHeadSnapshot)}get newHeadScriptElements(){return this.newHeadSnapshot.getScriptElementsNotInSnapshot(this.currentHeadSnapshot)}get currentHeadProvisionalElements(){return this.currentHeadSnapshot.provisionalElements}get newHeadProvisionalElements(){return this.newHeadSnapshot.provisionalElements}get newBodyScriptElements(){return this.newElement.querySelectorAll("script")}},Se=class{constructor(e){this.keys=[],this.snapshots={},this.size=e}has(e){return F(e)in this.snapshots}get(e){if(this.has(e)){let t=this.read(e);return this.touch(e),t}}put(e,t){return this.write(e,t),this.touch(e),t}clear(){this.snapshots={}}read(e){return this.snapshots[F(e)]}write(e,t){this.snapshots[F(e)]=t}touch(e){let t=F(e),n=this.keys.indexOf(t);n>-1&&this.keys.splice(n,1),this.keys.unshift(t),this.trim()}trim(){for(let e of this.keys.splice(this.size))delete this.snapshots[e]}},Ae=class extends z{constructor(){super(...arguments);this.snapshotCache=new Se(10),this.lastRenderedLocation=new URL(location.href)}renderPage(e,t=!1){let n=new J(this.snapshot,e,t);return this.render(n)}renderError(e){let t=new Ee(this.snapshot,e,!1);return this.render(t)}clearSnapshotCache(){this.snapshotCache.clear()}async cacheSnapshot(){if(this.shouldCacheSnapshot){this.delegate.viewWillCacheSnapshot();let{snapshot:e,lastRenderedLocation:t}=this;await At(),this.snapshotCache.put(t,e.clone())}}getCachedSnapshotForLocation(e){return this.snapshotCache.get(e)}get snapshot(){return b.fromElement(this.element)}get shouldCacheSnapshot(){return this.snapshot.isCacheable}},Pe=class{constructor(){this.navigator=new ve(this),this.history=new pe(this),this.view=new Ae(this,document.documentElement),this.adapter=new ue(this),this.pageObserver=new be(this),this.cacheObserver=new he,this.linkClickObserver=new me(this),this.formSubmitObserver=new de(this),this.scrollObserver=new ye(this),this.streamObserver=new we(this),this.frameRedirector=new fe(document.documentElement),this.drive=!0,this.enabled=!0,this.progressBarDelay=500,this.started=!1}start(){this.started||(this.pageObserver.start(),this.cacheObserver.start(),this.linkClickObserver.start(),this.formSubmitObserver.start(),this.scrollObserver.start(),this.streamObserver.start(),this.frameRedirector.start(),this.history.start(),this.started=!0,this.enabled=!0)}disable(){this.enabled=!1}stop(){this.started&&(this.pageObserver.stop(),this.cacheObserver.stop(),this.linkClickObserver.stop(),this.formSubmitObserver.stop(),this.scrollObserver.stop(),this.streamObserver.stop(),this.frameRedirector.stop(),this.history.stop(),this.started=!1)}registerAdapter(e){this.adapter=e}visit(e,t={}){this.navigator.proposeVisit(m(e),t)}connectStreamSource(e){this.streamObserver.connectStreamSource(e)}disconnectStreamSource(e){this.streamObserver.disconnectStreamSource(e)}renderStreamMessage(e){document.documentElement.appendChild(L.wrap(e).fragment)}clearCache(){this.view.clearSnapshotCache()}setProgressBarDelay(e){this.progressBarDelay=e}get location(){return this.history.location}get restorationIdentifier(){return this.history.restorationIdentifier}historyPoppedToLocationWithRestorationIdentifier(e,t){this.enabled?this.navigator.startVisit(e,t,{action:"restore",historyChanged:!0}):this.adapter.pageInvalidated()}scrollPositionChanged(e){this.history.updateRestorationData({scrollPosition:e})}willFollowLinkToLocation(e,t){return this.elementDriveEnabled(e)&&this.locationIsVisitable(t)&&this.applicationAllowsFollowingLinkToLocation(e,t)}followedLinkToLocation(e,t){let n=this.getActionForLink(e);this.convertLinkWithMethodClickToFormSubmission(e)||this.visit(t.href,{action:n})}convertLinkWithMethodClickToFormSubmission(e){let t=e.getAttribute("data-turbo-method");if(t){let n=document.createElement("form");return n.method=t,n.action=e.getAttribute("href")||"undefined",document.body.appendChild(n),u("submit",{cancelable:!0,target:n})}else return!1}allowsVisitingLocationWithAction(e,t){return this.locationWithActionIsSamePage(e,t)||this.applicationAllowsVisitingLocation(e)}visitProposedToLocation(e,t){Le(e),this.adapter.visitProposedToLocation(e,t)}visitStarted(e){Le(e.location),e.silent||this.notifyApplicationAfterVisitingLocation(e.location,e.action)}visitCompleted(e){this.notifyApplicationAfterPageLoad(e.getTimingMetrics())}locationWithActionIsSamePage(e,t){return this.navigator.locationWithActionIsSamePage(e,t)}visitScrolledToSamePageLocation(e,t){this.notifyApplicationAfterVisitingSamePageLocation(e,t)}willSubmitForm(e,t){return this.elementDriveEnabled(e)&&this.elementDriveEnabled(t)}formSubmitted(e,t){this.navigator.submitForm(e,t)}pageBecameInteractive(){this.view.lastRenderedLocation=this.location,this.notifyApplicationAfterPageLoad()}pageLoaded(){this.history.assumeControlOfScrollRestoration()}pageWillUnload(){this.history.relinquishControlOfScrollRestoration()}receivedMessageFromStream(e){this.renderStreamMessage(e)}viewWillCacheSnapshot(){var e;((e=this.navigator.currentVisit)===null||e===void 0?void 0:e.silent)||this.notifyApplicationBeforeCachingSnapshot()}allowsImmediateRender({element:e},t){return!this.notifyApplicationBeforeRender(e,t).defaultPrevented}viewRenderedSnapshot(e,t){this.view.lastRenderedLocation=this.history.location,this.notifyApplicationAfterRender()}viewInvalidated(){this.adapter.pageInvalidated()}frameLoaded(e){this.notifyApplicationAfterFrameLoad(e)}frameRendered(e,t){this.notifyApplicationAfterFrameRender(e,t)}applicationAllowsFollowingLinkToLocation(e,t){return!this.notifyApplicationAfterClickingLinkToLocation(e,t).defaultPrevented}applicationAllowsVisitingLocation(e){return!this.notifyApplicationBeforeVisitingLocation(e).defaultPrevented}notifyApplicationAfterClickingLinkToLocation(e,t){return u("turbo:click",{target:e,detail:{url:t.href},cancelable:!0})}notifyApplicationBeforeVisitingLocation(e){return u("turbo:before-visit",{detail:{url:e.href},cancelable:!0})}notifyApplicationAfterVisitingLocation(e,t){return u("turbo:visit",{detail:{url:e.href,action:t}})}notifyApplicationBeforeCachingSnapshot(){return u("turbo:before-cache")}notifyApplicationBeforeRender(e,t){return u("turbo:before-render",{detail:{newBody:e,resume:t},cancelable:!0})}notifyApplicationAfterRender(){return u("turbo:render")}notifyApplicationAfterPageLoad(e={}){return u("turbo:load",{detail:{url:this.location.href,timing:e}})}notifyApplicationAfterVisitingSamePageLocation(e,t){dispatchEvent(new HashChangeEvent("hashchange",{oldURL:e.toString(),newURL:t.toString()}))}notifyApplicationAfterFrameLoad(e){return u("turbo:frame-load",{target:e})}notifyApplicationAfterFrameRender(e,t){return u("turbo:frame-render",{detail:{fetchResponse:e},target:t,cancelable:!0})}elementDriveEnabled(e){let t=e==null?void 0:e.closest("[data-turbo]");return this.drive?t?t.getAttribute("data-turbo")!="false":!0:t?t.getAttribute("data-turbo")=="true":!1}getActionForLink(e){let t=e.getAttribute("data-turbo-action");return ge(t)?t:"advance"}locationIsVisitable(e){return vt(e,this.snapshot.rootLocation)&>(e)}get snapshot(){return this.view.snapshot}};function Le(r){Object.defineProperties(r,Kt)}var Kt={absoluteURL:{get(){return this.toString()}}},d=new Pe,{navigator:zt}=d;function Te(){d.start()}function $t(r){d.registerAdapter(r)}function Jt(r,e){d.visit(r,e)}function Gt(r){d.connectStreamSource(r)}function Qt(r){d.disconnectStreamSource(r)}function Xt(r){d.renderStreamMessage(r)}function Yt(){d.clearCache()}function Zt(r){d.setProgressBarDelay(r)}var er=Object.freeze({__proto__:null,navigator:zt,session:d,PageRenderer:J,PageSnapshot:b,start:Te,registerAdapter:$t,visit:Jt,connectStreamSource:Gt,disconnectStreamSource:Qt,renderStreamMessage:Xt,clearCache:Yt,setProgressBarDelay:Zt}),Ce=class{constructor(e){this.resolveVisitPromise=()=>{},this.connected=!1,this.hasBeenLoaded=!1,this.settingSourceURL=!1,this.element=e,this.view=new ie(this,this.element),this.appearanceObserver=new re(this,this.element),this.linkInterceptor=new $(this,this.element),this.formInterceptor=new K(this,this.element)}connect(){this.connected||(this.connected=!0,this.reloadable=!1,this.loadingStyle==w.lazy&&this.appearanceObserver.start(),this.linkInterceptor.start(),this.formInterceptor.start(),this.sourceURLChanged())}disconnect(){this.connected&&(this.connected=!1,this.appearanceObserver.stop(),this.linkInterceptor.stop(),this.formInterceptor.stop())}disabledChanged(){this.loadingStyle==w.eager&&this.loadSourceURL()}sourceURLChanged(){(this.loadingStyle==w.eager||this.hasBeenLoaded)&&this.loadSourceURL()}loadingStyleChanged(){this.loadingStyle==w.lazy?this.appearanceObserver.start():(this.appearanceObserver.stop(),this.loadSourceURL())}async loadSourceURL(){if(!this.settingSourceURL&&this.enabled&&this.isActive&&(this.reloadable||this.sourceURL!=this.currentURL)){let e=this.currentURL;if(this.currentURL=this.sourceURL,this.sourceURL)try{this.element.loaded=this.visit(this.sourceURL),this.appearanceObserver.stop(),await this.element.loaded,this.hasBeenLoaded=!0,d.frameLoaded(this.element)}catch(t){throw this.currentURL=e,t}}}async loadResponse(e){e.redirected&&(this.sourceURL=e.response.url);try{let t=await e.responseHTML;if(t){let{body:n}=ee(t),i=new M(await this.extractForeignFrameElement(n)),s=new oe(this.view.snapshot,i,!1);this.view.renderPromise&&await this.view.renderPromise,await this.view.render(s),d.frameRendered(e,this.element)}}catch(t){console.error(t),this.view.invalidate()}}elementAppearedInViewport(e){this.loadSourceURL()}shouldInterceptLinkClick(e,t){return e.hasAttribute("data-turbo-method")?!1:this.shouldInterceptNavigation(e)}linkClickIntercepted(e,t){this.reloadable=!0,this.navigateFrame(e,t)}shouldInterceptFormSubmission(e,t){return this.shouldInterceptNavigation(e,t)}formSubmissionIntercepted(e,t){if(this.formSubmission&&this.formSubmission.stop(),this.reloadable=!1,this.formSubmission=new U(this,e,t),this.formSubmission.fetchRequest.isIdempotent)this.navigateFrame(e,this.formSubmission.fetchRequest.url.href);else{let{fetchRequest:n}=this.formSubmission;this.prepareHeadersForRequest(n.headers,n),this.formSubmission.start()}}prepareHeadersForRequest(e,t){e["Turbo-Frame"]=this.id}requestStarted(e){this.element.setAttribute("busy","")}requestPreventedHandlingResponse(e,t){this.resolveVisitPromise()}async requestSucceededWithResponse(e,t){await this.loadResponse(t),this.resolveVisitPromise()}requestFailedWithResponse(e,t){console.error(t),this.resolveVisitPromise()}requestErrored(e,t){console.error(t),this.resolveVisitPromise()}requestFinished(e){this.element.removeAttribute("busy")}formSubmissionStarted(e){this.findFrameElement(e.formElement).setAttribute("busy","")}formSubmissionSucceededWithResponse(e,t){this.findFrameElement(e.formElement).delegate.loadResponse(t)}formSubmissionFailedWithResponse(e,t){this.element.delegate.loadResponse(t)}formSubmissionErrored(e,t){console.error(t)}formSubmissionFinished(e){this.findFrameElement(e.formElement).removeAttribute("busy")}allowsImmediateRender(e,t){return!0}viewRenderedSnapshot(e,t){}viewInvalidated(){}async visit(e){let t=new I(this,h.get,m(e));return new Promise(n=>{this.resolveVisitPromise=()=>{this.resolveVisitPromise=()=>{},n()},t.perform()})}navigateFrame(e,t){let n=this.findFrameElement(e);n.src=t}findFrameElement(e){var t;let n=e.getAttribute("data-turbo-frame")||this.element.getAttribute("target");return(t=Oe(n))!==null&&t!==void 0?t:this.element}async extractForeignFrameElement(e){let t,n=CSS.escape(this.id);try{if(t=Re(e.querySelector(`turbo-frame#${n}`),this.currentURL))return t;if(t=Re(e.querySelector(`turbo-frame[src][recurse~=${n}]`),this.currentURL))return await t.loaded,await this.extractForeignFrameElement(t);console.error(`Response has no matching <turbo-frame id="${n}"> element`)}catch(i){console.error(i)}return new v}shouldInterceptNavigation(e,t){let n=e.getAttribute("data-turbo-frame")||this.element.getAttribute("target");if(!this.enabled||n=="_top")return!1;if(n){let i=Oe(n);if(i)return!i.disabled}return!(!d.elementDriveEnabled(e)||t&&!d.elementDriveEnabled(t))}get id(){return this.element.id}get enabled(){return!this.element.disabled}get sourceURL(){if(this.element.src)return this.element.src}get reloadable(){return this.findFrameElement(this.element).hasAttribute("reloadable")}set reloadable(e){let t=this.findFrameElement(this.element);e?t.setAttribute("reloadable",""):t.removeAttribute("reloadable")}set sourceURL(e){this.settingSourceURL=!0,this.element.src=e??null,this.currentURL=this.element.src,this.settingSourceURL=!1}get loadingStyle(){return this.element.loading}get isLoading(){return this.formSubmission!==void 0||this.resolveVisitPromise()!==void 0}get isActive(){return this.element.isActive&&this.connected}};function Oe(r){if(r!=null){let e=document.getElementById(r);if(e instanceof v)return e}}function Re(r,e){if(r){let t=r.getAttribute("src");if(t!=null&&e!=null&&bt(t,e))throw new Error(`Matching <turbo-frame id="${r.id}"> element has a source URL which references itself`);if(r.ownerDocument!==document&&(r=document.importNode(r,!0)),r instanceof v)return r.connectedCallback(),r}}var tr={after(){this.targetElements.forEach(r=>{var e;return(e=r.parentElement)===null||e===void 0?void 0:e.insertBefore(this.templateContent,r.nextSibling)})},append(){this.removeDuplicateTargetChildren(),this.targetElements.forEach(r=>r.append(this.templateContent))},before(){this.targetElements.forEach(r=>{var e;return(e=r.parentElement)===null||e===void 0?void 0:e.insertBefore(this.templateContent,r)})},prepend(){this.removeDuplicateTargetChildren(),this.targetElements.forEach(r=>r.prepend(this.templateContent))},remove(){this.targetElements.forEach(r=>r.remove())},replace(){this.targetElements.forEach(r=>r.replaceWith(this.templateContent))},update(){this.targetElements.forEach(r=>{r.innerHTML="",r.append(this.templateContent)})}},ke=class extends HTMLElement{async connectedCallback(){try{await this.render()}catch(e){console.error(e)}finally{this.disconnect()}}async render(){var e;return(e=this.renderPromise)!==null&&e!==void 0?e:this.renderPromise=(async()=>{this.dispatchEvent(this.beforeRenderEvent)&&(await B(),this.performAction())})()}disconnect(){try{this.remove()}catch(e){}}removeDuplicateTargetChildren(){this.duplicateChildren.forEach(e=>e.remove())}get duplicateChildren(){var e;let t=this.targetElements.flatMap(i=>[...i.children]).filter(i=>!!i.id),n=[...(e=this.templateContent)===null||e===void 0?void 0:e.children].filter(i=>!!i.id).map(i=>i.id);return t.filter(i=>n.includes(i.id))}get performAction(){if(this.action){let e=tr[this.action];if(e)return e;this.raise("unknown action")}this.raise("action attribute is missing")}get targetElements(){if(this.target)return this.targetElementsById;if(this.targets)return this.targetElementsByQuery;this.raise("target or targets attribute is missing")}get templateContent(){return this.templateElement.content.cloneNode(!0)}get templateElement(){if(this.firstElementChild instanceof HTMLTemplateElement)return this.firstElementChild;this.raise("first child element must be a <template> element")}get action(){return this.getAttribute("action")}get target(){return this.getAttribute("target")}get targets(){return this.getAttribute("targets")}raise(e){throw new Error(`${this.description}: ${e}`)}get description(){var e,t;return(t=((e=this.outerHTML.match(/<[^>]+>/))!==null&&e!==void 0?e:[])[0])!==null&&t!==void 0?t:"<turbo-stream>"}get beforeRenderEvent(){return new CustomEvent("turbo:before-stream-render",{bubbles:!0,cancelable:!0})}get targetElementsById(){var e;let t=(e=this.ownerDocument)===null||e===void 0?void 0:e.getElementById(this.target);return t!==null?[t]:[]}get targetElementsByQuery(){var e;let t=(e=this.ownerDocument)===null||e===void 0?void 0:e.querySelectorAll(this.targets);return t.length!==0?Array.prototype.slice.call(t):[]}};v.delegateConstructor=Ce;customElements.define("turbo-frame",v);customElements.define("turbo-stream",ke);(()=>{let r=document.currentScript;if(!!r&&!r.hasAttribute("data-turbo-suppress-warning")){for(;r=r.parentElement;)if(r==document.body)return console.warn(te` + `}show(){this.visible||(this.visible=!0,this.installProgressElement(),this.startTrickling())}hide(){this.visible&&!this.hiding&&(this.hiding=!0,this.fadeProgressElement(()=>{this.uninstallProgressElement(),this.stopTrickling(),this.visible=!1,this.hiding=!1}))}setValue(e){this.value=e,this.refresh()}installStylesheetElement(){document.head.insertBefore(this.stylesheetElement,document.head.firstChild)}installProgressElement(){this.progressElement.style.width="0",this.progressElement.style.opacity="1",document.documentElement.insertBefore(this.progressElement,document.body),this.refresh()}fadeProgressElement(e){this.progressElement.style.opacity="0",setTimeout(e,se.animationDuration*1.5)}uninstallProgressElement(){this.progressElement.parentNode&&document.documentElement.removeChild(this.progressElement)}startTrickling(){this.trickleInterval||(this.trickleInterval=window.setInterval(this.trickle,se.animationDuration))}stopTrickling(){window.clearInterval(this.trickleInterval),delete this.trickleInterval}refresh(){requestAnimationFrame(()=>{this.progressElement.style.width=`${10+this.value*90}%`})}createStylesheetElement(){let e=document.createElement("style");return e.type="text/css",e.textContent=se.defaultCSS,e}createProgressElement(){let e=document.createElement("div");return e.className="turbo-progress-bar",e}};se.animationDuration=300;var xi=class extends dt{constructor(){super(...arguments);this.detailsByOuterHTML=this.children.filter(e=>!La(e)).reduce((e,r)=>{let{outerHTML:i}=r,n=i in e?e[i]:{type:Aa(r),tracked:Oa(r),elements:[]};return Object.assign(Object.assign({},e),{[i]:Object.assign(Object.assign({},n),{elements:[...n.elements,r]})})},{})}get trackedElementSignature(){return Object.keys(this.detailsByOuterHTML).filter(e=>this.detailsByOuterHTML[e].tracked).join("")}getScriptElementsNotInSnapshot(e){return this.getElementsMatchingTypeNotInSnapshot("script",e)}getStylesheetElementsNotInSnapshot(e){return this.getElementsMatchingTypeNotInSnapshot("stylesheet",e)}getElementsMatchingTypeNotInSnapshot(e,r){return Object.keys(this.detailsByOuterHTML).filter(i=>!(i in r.detailsByOuterHTML)).map(i=>this.detailsByOuterHTML[i]).filter(({type:i})=>i==e).map(({elements:[i]})=>i)}get provisionalElements(){return Object.keys(this.detailsByOuterHTML).reduce((e,r)=>{let{type:i,tracked:n,elements:s}=this.detailsByOuterHTML[r];return i==null&&!n?[...e,...s]:s.length>1?[...e,...s.slice(1)]:e},[])}getMetaValue(e){let r=this.findMetaElementByName(e);return r?r.getAttribute("content"):null}findMetaElementByName(e){return Object.keys(this.detailsByOuterHTML).reduce((r,i)=>{let{elements:[n]}=this.detailsByOuterHTML[i];return Pa(n,e)?n:r},void 0)}};function Aa(t){if(Ca(t))return"script";if(Ia(t))return"stylesheet"}function Oa(t){return t.getAttribute("data-turbo-track")=="reload"}function Ca(t){return t.tagName.toLowerCase()=="script"}function La(t){return t.tagName.toLowerCase()=="noscript"}function Ia(t){let e=t.tagName.toLowerCase();return e=="style"||e=="link"&&t.getAttribute("rel")=="stylesheet"}function Pa(t,e){return t.tagName.toLowerCase()=="meta"&&t.getAttribute("name")==e}var me=class extends dt{constructor(e,r){super(e);this.headSnapshot=r}static fromHTMLString(e=""){return this.fromDocument(Ci(e))}static fromElement(e){return this.fromDocument(e.ownerDocument)}static fromDocument({head:e,body:r}){return new this(r,new xi(e))}clone(){return new me(this.element.cloneNode(!0),this.headSnapshot)}get headElement(){return this.headSnapshot.element}get rootLocation(){var e;let r=(e=this.getSetting("root"))!==null&&e!==void 0?e:"/";return ne(r)}get cacheControlValue(){return this.getSetting("cache-control")}get isPreviewable(){return this.cacheControlValue!="no-preview"}get isCacheable(){return this.cacheControlValue!="no-cache"}get isVisitable(){return this.getSetting("visit-control")!="reload"}getSetting(e){return this.headSnapshot.getMetaValue(`turbo-${e}`)}},Je;(function(t){t.visitStart="visitStart",t.requestStart="requestStart",t.requestEnd="requestEnd",t.visitEnd="visitEnd"})(Je||(Je={}));var X;(function(t){t.initialized="initialized",t.started="started",t.canceled="canceled",t.failed="failed",t.completed="completed"})(X||(X={}));var Ma={action:"advance",historyChanged:!1},Oe;(function(t){t[t.networkFailure=0]="networkFailure",t[t.timeoutFailure=-1]="timeoutFailure",t[t.contentTypeMismatch=-2]="contentTypeMismatch"})(Oe||(Oe={}));var Ni=class{constructor(e,r,i,n={}){this.identifier=ht(),this.timingMetrics={},this.followedRedirect=!1,this.historyChanged=!1,this.scrolled=!1,this.snapshotCached=!1,this.state=X.initialized,this.delegate=e,this.location=r,this.restorationIdentifier=i||ht();let{action:s,historyChanged:o,referrer:a,snapshotHTML:l,response:u}=Object.assign(Object.assign({},Ma),n);this.action=s,this.historyChanged=o,this.referrer=a,this.snapshotHTML=l,this.response=u,this.isSamePage=this.delegate.locationWithActionIsSamePage(this.location,this.action)}get adapter(){return this.delegate.adapter}get view(){return this.delegate.view}get history(){return this.delegate.history}get restorationData(){return this.history.getRestorationDataForIdentifier(this.restorationIdentifier)}get silent(){return this.isSamePage}start(){this.state==X.initialized&&(this.recordTimingMetric(Je.visitStart),this.state=X.started,this.adapter.visitStarted(this),this.delegate.visitStarted(this))}cancel(){this.state==X.started&&(this.request&&this.request.cancel(),this.cancelRender(),this.state=X.canceled)}complete(){this.state==X.started&&(this.recordTimingMetric(Je.visitEnd),this.state=X.completed,this.adapter.visitCompleted(this),this.delegate.visitCompleted(this),this.followRedirect())}fail(){this.state==X.started&&(this.state=X.failed,this.adapter.visitFailed(this))}changeHistory(){var e;if(!this.historyChanged){let r=this.location.href===((e=this.referrer)===null||e===void 0?void 0:e.href)?"replace":this.action,i=this.getHistoryMethodForAction(r);this.history.update(i,this.location,this.restorationIdentifier),this.historyChanged=!0}}issueRequest(){this.hasPreloadedResponse()?this.simulateRequest():this.shouldIssueRequest()&&!this.request&&(this.request=new jt(this,F.get,this.location),this.request.perform())}simulateRequest(){this.response&&(this.startRequest(),this.recordResponse(),this.finishRequest())}startRequest(){this.recordTimingMetric(Je.requestStart),this.adapter.visitRequestStarted(this)}recordResponse(e=this.response){if(this.response=e,e){let{statusCode:r}=e;_i(r)?this.adapter.visitRequestCompleted(this):this.adapter.visitRequestFailedWithStatusCode(this,r)}}finishRequest(){this.recordTimingMetric(Je.requestEnd),this.adapter.visitRequestFinished(this)}loadResponse(){if(this.response){let{statusCode:e,responseHTML:r}=this.response;this.render(async()=>{this.cacheSnapshot(),this.view.renderPromise&&await this.view.renderPromise,_i(e)&&r!=null?(await this.view.renderPage(me.fromHTMLString(r)),this.adapter.visitRendered(this),this.complete()):(await this.view.renderError(me.fromHTMLString(r)),this.adapter.visitRendered(this),this.fail())})}}getCachedSnapshot(){let e=this.view.getCachedSnapshotForLocation(this.location)||this.getPreloadedSnapshot();if(e&&(!xe(this.location)||e.hasAnchor(xe(this.location)))&&(this.action=="restore"||e.isPreviewable))return e}getPreloadedSnapshot(){if(this.snapshotHTML)return me.fromHTMLString(this.snapshotHTML)}hasCachedSnapshot(){return this.getCachedSnapshot()!=null}loadCachedSnapshot(){let e=this.getCachedSnapshot();if(e){let r=this.shouldIssueRequest();this.render(async()=>{this.cacheSnapshot(),this.isSamePage?this.adapter.visitRendered(this):(this.view.renderPromise&&await this.view.renderPromise,await this.view.renderPage(e,r),this.adapter.visitRendered(this),r||this.complete())})}}followRedirect(){this.redirectedToLocation&&!this.followedRedirect&&(this.adapter.visitProposedToLocation(this.redirectedToLocation,{action:"replace",response:this.response}),this.followedRedirect=!0)}goToSamePageAnchor(){this.isSamePage&&this.render(async()=>{this.cacheSnapshot(),this.adapter.visitRendered(this)})}requestStarted(){this.startRequest()}requestPreventedHandlingResponse(e,r){}async requestSucceededWithResponse(e,r){let i=await r.responseHTML;i==null?this.recordResponse({statusCode:Oe.contentTypeMismatch}):(this.redirectedToLocation=r.redirected?r.location:void 0,this.recordResponse({statusCode:r.statusCode,responseHTML:i}))}async requestFailedWithResponse(e,r){let i=await r.responseHTML;i==null?this.recordResponse({statusCode:Oe.contentTypeMismatch}):this.recordResponse({statusCode:r.statusCode,responseHTML:i})}requestErrored(e,r){this.recordResponse({statusCode:Oe.networkFailure})}requestFinished(){this.finishRequest()}performScroll(){this.scrolled||(this.action=="restore"?this.scrollToRestoredPosition()||this.scrollToAnchor()||this.view.scrollToTop():this.scrollToAnchor()||this.view.scrollToTop(),this.isSamePage&&this.delegate.visitScrolledToSamePageLocation(this.view.lastRenderedLocation,this.location),this.scrolled=!0)}scrollToRestoredPosition(){let{scrollPosition:e}=this.restorationData;if(e)return this.view.scrollToPosition(e),!0}scrollToAnchor(){let e=xe(this.location);if(e!=null)return this.view.scrollToAnchor(e),!0}recordTimingMetric(e){this.timingMetrics[e]=new Date().getTime()}getTimingMetrics(){return Object.assign({},this.timingMetrics)}getHistoryMethodForAction(e){switch(e){case"replace":return history.replaceState;case"advance":case"restore":return history.pushState}}hasPreloadedResponse(){return typeof this.response=="object"}shouldIssueRequest(){return this.isSamePage?!1:this.action=="restore"?!this.hasCachedSnapshot():!0}cacheSnapshot(){this.snapshotCached||(this.view.cacheSnapshot(),this.snapshotCached=!0)}async render(e){this.cancelRender(),await new Promise(r=>{this.frame=requestAnimationFrame(()=>r())}),await e(),delete this.frame,this.performScroll()}cancelRender(){this.frame&&(cancelAnimationFrame(this.frame),delete this.frame)}};function _i(t){return t>=200&&t<300}var Fi=class{constructor(e){this.progressBar=new se,this.showProgressBar=()=>{this.progressBar.show()},this.session=e}visitProposedToLocation(e,r){this.navigator.startVisit(e,ht(),r)}visitStarted(e){e.issueRequest(),e.changeHistory(),e.goToSamePageAnchor(),e.loadCachedSnapshot()}visitRequestStarted(e){this.progressBar.setValue(0),e.hasCachedSnapshot()||e.action!="restore"?this.showVisitProgressBarAfterDelay():this.showProgressBar()}visitRequestCompleted(e){e.loadResponse()}visitRequestFailedWithStatusCode(e,r){switch(r){case Oe.networkFailure:case Oe.timeoutFailure:case Oe.contentTypeMismatch:return this.reload();default:return e.loadResponse()}}visitRequestFinished(e){this.progressBar.setValue(1),this.hideVisitProgressBar()}visitCompleted(e){}pageInvalidated(){this.reload()}visitFailed(e){}visitRendered(e){}formSubmissionStarted(e){this.progressBar.setValue(0),this.showFormProgressBarAfterDelay()}formSubmissionFinished(e){this.progressBar.setValue(1),this.hideFormProgressBar()}showVisitProgressBarAfterDelay(){this.visitProgressBarTimeout=window.setTimeout(this.showProgressBar,this.session.progressBarDelay)}hideVisitProgressBar(){this.progressBar.hide(),this.visitProgressBarTimeout!=null&&(window.clearTimeout(this.visitProgressBarTimeout),delete this.visitProgressBarTimeout)}showFormProgressBarAfterDelay(){this.formProgressBarTimeout==null&&(this.formProgressBarTimeout=window.setTimeout(this.showProgressBar,this.session.progressBarDelay))}hideFormProgressBar(){this.progressBar.hide(),this.formProgressBarTimeout!=null&&(window.clearTimeout(this.formProgressBarTimeout),delete this.formProgressBarTimeout)}reload(){window.location.reload()}get navigator(){return this.session.navigator}},Hi=class{constructor(){this.started=!1}start(){this.started||(this.started=!0,addEventListener("turbo:before-cache",this.removeStaleElements,!1))}stop(){this.started&&(this.started=!1,removeEventListener("turbo:before-cache",this.removeStaleElements,!1))}removeStaleElements(){let e=[...document.querySelectorAll('[data-turbo-cache="false"]')];for(let r of e)r.remove()}},Vi=class{constructor(e){this.started=!1,this.submitCaptured=()=>{removeEventListener("submit",this.submitBubbled,!1),addEventListener("submit",this.submitBubbled,!1)},this.submitBubbled=r=>{if(!r.defaultPrevented){let i=r.target instanceof HTMLFormElement?r.target:void 0,n=r.submitter||void 0;i&&((n==null?void 0:n.getAttribute("formmethod"))||i.method)!="dialog"&&this.delegate.willSubmitForm(i,n)&&(r.preventDefault(),this.delegate.formSubmitted(i,n))}},this.delegate=e}start(){this.started||(addEventListener("submit",this.submitCaptured,!0),this.started=!0)}stop(){this.started&&(removeEventListener("submit",this.submitCaptured,!0),this.started=!1)}},Bi=class{constructor(e){this.element=e,this.linkInterceptor=new Cr(this,e),this.formInterceptor=new Ar(this,e)}start(){this.linkInterceptor.start(),this.formInterceptor.start()}stop(){this.linkInterceptor.stop(),this.formInterceptor.stop()}shouldInterceptLinkClick(e,r){return this.shouldRedirect(e)}linkClickIntercepted(e,r){let i=this.findFrameElement(e);i&&(i.setAttribute("reloadable",""),i.src=r)}shouldInterceptFormSubmission(e,r){return this.shouldRedirect(e,r)}formSubmissionIntercepted(e,r){let i=this.findFrameElement(e);i&&(i.removeAttribute("reloadable"),i.delegate.formSubmissionIntercepted(e,r))}shouldRedirect(e,r){let i=this.findFrameElement(e);return i?i!=e.closest("turbo-frame"):!1}findFrameElement(e){let r=e.getAttribute("data-turbo-frame");if(r&&r!="_top"){let i=this.element.querySelector(`#${r}:not([disabled])`);if(i instanceof fe)return i}}},ji=class{constructor(e){this.restorationIdentifier=ht(),this.restorationData={},this.started=!1,this.pageLoaded=!1,this.onPopState=r=>{if(this.shouldHandlePopState()){let{turbo:i}=r.state||{};if(i){this.location=new URL(window.location.href);let{restorationIdentifier:n}=i;this.restorationIdentifier=n,this.delegate.historyPoppedToLocationWithRestorationIdentifier(this.location,n)}}},this.onPageLoad=async r=>{await fa(),this.pageLoaded=!0},this.delegate=e}start(){this.started||(addEventListener("popstate",this.onPopState,!1),addEventListener("load",this.onPageLoad,!1),this.started=!0,this.replace(new URL(window.location.href)))}stop(){this.started&&(removeEventListener("popstate",this.onPopState,!1),removeEventListener("load",this.onPageLoad,!1),this.started=!1)}push(e,r){this.update(history.pushState,e,r)}replace(e,r){this.update(history.replaceState,e,r)}update(e,r,i=ht()){let n={turbo:{restorationIdentifier:i}};e.call(history,n,"",r.href),this.location=r,this.restorationIdentifier=i}getRestorationDataForIdentifier(e){return this.restorationData[e]||{}}updateRestorationData(e){let{restorationIdentifier:r}=this,i=this.restorationData[r];this.restorationData[r]=Object.assign(Object.assign({},i),e)}assumeControlOfScrollRestoration(){var e;this.previousScrollRestoration||(this.previousScrollRestoration=(e=history.scrollRestoration)!==null&&e!==void 0?e:"auto",history.scrollRestoration="manual")}relinquishControlOfScrollRestoration(){this.previousScrollRestoration&&(history.scrollRestoration=this.previousScrollRestoration,delete this.previousScrollRestoration)}shouldHandlePopState(){return this.pageIsLoaded()}pageIsLoaded(){return this.pageLoaded||document.readyState=="complete"}},Ui=class{constructor(e){this.started=!1,this.clickCaptured=()=>{removeEventListener("click",this.clickBubbled,!1),addEventListener("click",this.clickBubbled,!1)},this.clickBubbled=r=>{if(this.clickEventIsSignificant(r)){let i=r.composedPath&&r.composedPath()[0]||r.target,n=this.findLinkFromClickTarget(i);if(n){let s=this.getLocationForLink(n);this.delegate.willFollowLinkToLocation(n,s)&&(r.preventDefault(),this.delegate.followedLinkToLocation(n,s))}}},this.delegate=e}start(){this.started||(addEventListener("click",this.clickCaptured,!0),this.started=!0)}stop(){this.started&&(removeEventListener("click",this.clickCaptured,!0),this.started=!1)}clickEventIsSignificant(e){return!(e.target&&e.target.isContentEditable||e.defaultPrevented||e.which>1||e.altKey||e.ctrlKey||e.metaKey||e.shiftKey)}findLinkFromClickTarget(e){if(e instanceof Element)return e.closest("a[href]:not([target^=_]):not([download])")}getLocationForLink(e){return ne(e.getAttribute("href")||"")}};function qi(t){return t=="advance"||t=="replace"||t=="restore"}var $i=class{constructor(e){this.delegate=e}proposeVisit(e,r={}){this.delegate.allowsVisitingLocationWithAction(e,r.action)&&this.delegate.visitProposedToLocation(e,r)}startVisit(e,r,i={}){this.stop(),this.currentVisit=new Ni(this,ne(e),r,Object.assign({referrer:this.location},i)),this.currentVisit.start()}submitForm(e,r){this.stop(),this.formSubmission=new kr(this,e,r,!0),this.formSubmission.isIdempotent?this.proposeVisit(this.formSubmission.fetchRequest.url,{action:this.getActionForFormSubmission(this.formSubmission)}):this.formSubmission.start()}stop(){this.formSubmission&&(this.formSubmission.stop(),delete this.formSubmission),this.currentVisit&&(this.currentVisit.cancel(),delete this.currentVisit)}get adapter(){return this.delegate.adapter}get view(){return this.delegate.view}get history(){return this.delegate.history}formSubmissionStarted(e){typeof this.adapter.formSubmissionStarted=="function"&&this.adapter.formSubmissionStarted(e)}async formSubmissionSucceededWithResponse(e,r){if(e==this.formSubmission){let i=await r.responseHTML;if(i){e.method!=F.get&&this.view.clearSnapshotCache();let{statusCode:n}=r,s={response:{statusCode:n,responseHTML:i}};this.proposeVisit(r.location,s)}}}async formSubmissionFailedWithResponse(e,r){let i=await r.responseHTML;if(i){let n=me.fromHTMLString(i);r.serverError?await this.view.renderError(n):await this.view.renderPage(n),this.view.scrollToTop(),this.view.clearSnapshotCache()}}formSubmissionErrored(e,r){console.error(r)}formSubmissionFinished(e){typeof this.adapter.formSubmissionFinished=="function"&&this.adapter.formSubmissionFinished(e)}visitStarted(e){this.delegate.visitStarted(e)}visitCompleted(e){this.delegate.visitCompleted(e)}locationWithActionIsSamePage(e,r){let i=xe(e),n=xe(this.view.lastRenderedLocation),s=r==="restore"&&typeof i=="undefined";return r!=="replace"&&Er(e)===Er(this.view.lastRenderedLocation)&&(s||i!=null&&i!==n)}visitScrolledToSamePageLocation(e,r){this.delegate.visitScrolledToSamePageLocation(e,r)}get location(){return this.history.location}get restorationIdentifier(){return this.history.restorationIdentifier}getActionForFormSubmission(e){let{formElement:r,submitter:i}=e,n=(i==null?void 0:i.getAttribute("data-turbo-action"))||r.getAttribute("data-turbo-action");return qi(n)?n:"advance"}},pe;(function(t){t[t.initial=0]="initial",t[t.loading=1]="loading",t[t.interactive=2]="interactive",t[t.complete=3]="complete"})(pe||(pe={}));var Wi=class{constructor(e){this.stage=pe.initial,this.started=!1,this.interpretReadyState=()=>{let{readyState:r}=this;r=="interactive"?this.pageIsInteractive():r=="complete"&&this.pageIsComplete()},this.pageWillUnload=()=>{this.delegate.pageWillUnload()},this.delegate=e}start(){this.started||(this.stage==pe.initial&&(this.stage=pe.loading),document.addEventListener("readystatechange",this.interpretReadyState,!1),addEventListener("pagehide",this.pageWillUnload,!1),this.started=!0)}stop(){this.started&&(document.removeEventListener("readystatechange",this.interpretReadyState,!1),removeEventListener("pagehide",this.pageWillUnload,!1),this.started=!1)}pageIsInteractive(){this.stage==pe.loading&&(this.stage=pe.interactive,this.delegate.pageBecameInteractive())}pageIsComplete(){this.pageIsInteractive(),this.stage==pe.interactive&&(this.stage=pe.complete,this.delegate.pageLoaded())}get readyState(){return document.readyState}},zi=class{constructor(e){this.started=!1,this.onScroll=()=>{this.updatePosition({x:window.pageXOffset,y:window.pageYOffset})},this.delegate=e}start(){this.started||(addEventListener("scroll",this.onScroll,!1),this.onScroll(),this.started=!0)}stop(){this.started&&(removeEventListener("scroll",this.onScroll,!1),this.started=!1)}updatePosition(e){this.delegate.scrollPositionChanged(e)}},Zi=class{constructor(e){this.sources=new Set,this.started=!1,this.inspectFetchResponse=r=>{let i=Ra(r);i&&Da(i)&&(r.preventDefault(),this.receiveMessageResponse(i))},this.receiveMessageEvent=r=>{this.started&&typeof r.data=="string"&&this.receiveMessageHTML(r.data)},this.delegate=e}start(){this.started||(this.started=!0,addEventListener("turbo:before-fetch-response",this.inspectFetchResponse,!1))}stop(){this.started&&(this.started=!1,removeEventListener("turbo:before-fetch-response",this.inspectFetchResponse,!1))}connectStreamSource(e){this.streamSourceIsConnected(e)||(this.sources.add(e),e.addEventListener("message",this.receiveMessageEvent,!1))}disconnectStreamSource(e){this.streamSourceIsConnected(e)&&(this.sources.delete(e),e.removeEventListener("message",this.receiveMessageEvent,!1))}streamSourceIsConnected(e){return this.sources.has(e)}async receiveMessageResponse(e){let r=await e.responseHTML;r&&this.receiveMessageHTML(r)}receiveMessageHTML(e){this.delegate.receivedMessageFromStream(new Ze(e))}};function Ra(t){var e;let r=(e=t.detail)===null||e===void 0?void 0:e.fetchResponse;if(r instanceof Tr)return r}function Da(t){var e;return((e=t.contentType)!==null&&e!==void 0?e:"").startsWith(Ze.contentType)}var Ji=class extends Ut{async render(){this.replaceHeadAndBody(),this.activateScriptElements()}replaceHeadAndBody(){let{documentElement:e,head:r,body:i}=document;e.replaceChild(this.newHead,r),e.replaceChild(this.newElement,i)}activateScriptElements(){for(let e of this.scriptElements){let r=e.parentNode;if(r){let i=this.createScriptElement(e);r.replaceChild(i,e)}}}get newHead(){return this.newSnapshot.headSnapshot.element}get scriptElements(){return[...document.documentElement.querySelectorAll("script")]}},Lr=class extends Ut{get shouldRender(){return this.newSnapshot.isVisitable&&this.trackedElementsAreIdentical}prepareToRender(){this.mergeHead()}async render(){this.replaceBody()}finishRendering(){super.finishRendering(),this.isPreview||this.focusFirstAutofocusableElement()}get currentHeadSnapshot(){return this.currentSnapshot.headSnapshot}get newHeadSnapshot(){return this.newSnapshot.headSnapshot}get newElement(){return this.newSnapshot.element}mergeHead(){this.copyNewHeadStylesheetElements(),this.copyNewHeadScriptElements(),this.removeCurrentHeadProvisionalElements(),this.copyNewHeadProvisionalElements()}replaceBody(){this.preservingPermanentElements(()=>{this.activateNewBody(),this.assignNewBody()})}get trackedElementsAreIdentical(){return this.currentHeadSnapshot.trackedElementSignature==this.newHeadSnapshot.trackedElementSignature}copyNewHeadStylesheetElements(){for(let e of this.newHeadStylesheetElements)document.head.appendChild(e)}copyNewHeadScriptElements(){for(let e of this.newHeadScriptElements)document.head.appendChild(this.createScriptElement(e))}removeCurrentHeadProvisionalElements(){for(let e of this.currentHeadProvisionalElements)document.head.removeChild(e)}copyNewHeadProvisionalElements(){for(let e of this.newHeadProvisionalElements)document.head.appendChild(e)}activateNewBody(){document.adoptNode(this.newElement),this.activateNewBodyScriptElements()}activateNewBodyScriptElements(){for(let e of this.newBodyScriptElements){let r=this.createScriptElement(e);e.replaceWith(r)}}assignNewBody(){document.body&&this.newElement instanceof HTMLBodyElement?document.body.replaceWith(this.newElement):document.documentElement.appendChild(this.newElement)}get newHeadStylesheetElements(){return this.newHeadSnapshot.getStylesheetElementsNotInSnapshot(this.currentHeadSnapshot)}get newHeadScriptElements(){return this.newHeadSnapshot.getScriptElementsNotInSnapshot(this.currentHeadSnapshot)}get currentHeadProvisionalElements(){return this.currentHeadSnapshot.provisionalElements}get newHeadProvisionalElements(){return this.newHeadSnapshot.provisionalElements}get newBodyScriptElements(){return this.newElement.querySelectorAll("script")}},Ki=class{constructor(e){this.keys=[],this.snapshots={},this.size=e}has(e){return Vt(e)in this.snapshots}get(e){if(this.has(e)){let r=this.read(e);return this.touch(e),r}}put(e,r){return this.write(e,r),this.touch(e),r}clear(){this.snapshots={}}read(e){return this.snapshots[Vt(e)]}write(e,r){this.snapshots[Vt(e)]=r}touch(e){let r=Vt(e),i=this.keys.indexOf(r);i>-1&&this.keys.splice(i,1),this.keys.unshift(r),this.trim()}trim(){for(let e of this.keys.splice(this.size))delete this.snapshots[e]}},Gi=class extends Or{constructor(){super(...arguments);this.snapshotCache=new Ki(10),this.lastRenderedLocation=new URL(location.href)}renderPage(e,r=!1){let i=new Lr(this.snapshot,e,r);return this.render(i)}renderError(e){let r=new Ji(this.snapshot,e,!1);return this.render(r)}clearSnapshotCache(){this.snapshotCache.clear()}async cacheSnapshot(){if(this.shouldCacheSnapshot){this.delegate.viewWillCacheSnapshot();let{snapshot:e,lastRenderedLocation:r}=this;await da(),this.snapshotCache.put(r,e.clone())}}getCachedSnapshotForLocation(e){return this.snapshotCache.get(e)}get snapshot(){return me.fromElement(this.element)}get shouldCacheSnapshot(){return this.snapshot.isCacheable}},Yi=class{constructor(){this.navigator=new $i(this),this.history=new ji(this),this.view=new Gi(this,document.documentElement),this.adapter=new Fi(this),this.pageObserver=new Wi(this),this.cacheObserver=new Hi,this.linkClickObserver=new Ui(this),this.formSubmitObserver=new Vi(this),this.scrollObserver=new zi(this),this.streamObserver=new Zi(this),this.frameRedirector=new Bi(document.documentElement),this.drive=!0,this.enabled=!0,this.progressBarDelay=500,this.started=!1}start(){this.started||(this.pageObserver.start(),this.cacheObserver.start(),this.linkClickObserver.start(),this.formSubmitObserver.start(),this.scrollObserver.start(),this.streamObserver.start(),this.frameRedirector.start(),this.history.start(),this.started=!0,this.enabled=!0)}disable(){this.enabled=!1}stop(){this.started&&(this.pageObserver.stop(),this.cacheObserver.stop(),this.linkClickObserver.stop(),this.formSubmitObserver.stop(),this.scrollObserver.stop(),this.streamObserver.stop(),this.frameRedirector.stop(),this.history.stop(),this.started=!1)}registerAdapter(e){this.adapter=e}visit(e,r={}){this.navigator.proposeVisit(ne(e),r)}connectStreamSource(e){this.streamObserver.connectStreamSource(e)}disconnectStreamSource(e){this.streamObserver.disconnectStreamSource(e)}renderStreamMessage(e){document.documentElement.appendChild(Ze.wrap(e).fragment)}clearCache(){this.view.clearSnapshotCache()}setProgressBarDelay(e){this.progressBarDelay=e}get location(){return this.history.location}get restorationIdentifier(){return this.history.restorationIdentifier}historyPoppedToLocationWithRestorationIdentifier(e,r){this.enabled?this.navigator.startVisit(e,r,{action:"restore",historyChanged:!0}):this.adapter.pageInvalidated()}scrollPositionChanged(e){this.history.updateRestorationData({scrollPosition:e})}willFollowLinkToLocation(e,r){return this.elementDriveEnabled(e)&&this.locationIsVisitable(r)&&this.applicationAllowsFollowingLinkToLocation(e,r)}followedLinkToLocation(e,r){let i=this.getActionForLink(e);this.convertLinkWithMethodClickToFormSubmission(e)||this.visit(r.href,{action:i})}convertLinkWithMethodClickToFormSubmission(e){let r=e.getAttribute("data-turbo-method");if(r){let i=document.createElement("form");return i.method=r,i.action=e.getAttribute("href")||"undefined",document.body.appendChild(i),_("submit",{cancelable:!0,target:i})}else return!1}allowsVisitingLocationWithAction(e,r){return this.locationWithActionIsSamePage(e,r)||this.applicationAllowsVisitingLocation(e)}visitProposedToLocation(e,r){Xi(e),this.adapter.visitProposedToLocation(e,r)}visitStarted(e){Xi(e.location),e.silent||this.notifyApplicationAfterVisitingLocation(e.location,e.action)}visitCompleted(e){this.notifyApplicationAfterPageLoad(e.getTimingMetrics())}locationWithActionIsSamePage(e,r){return this.navigator.locationWithActionIsSamePage(e,r)}visitScrolledToSamePageLocation(e,r){this.notifyApplicationAfterVisitingSamePageLocation(e,r)}willSubmitForm(e,r){return this.elementDriveEnabled(e)&&this.elementDriveEnabled(r)}formSubmitted(e,r){this.navigator.submitForm(e,r)}pageBecameInteractive(){this.view.lastRenderedLocation=this.location,this.notifyApplicationAfterPageLoad()}pageLoaded(){this.history.assumeControlOfScrollRestoration()}pageWillUnload(){this.history.relinquishControlOfScrollRestoration()}receivedMessageFromStream(e){this.renderStreamMessage(e)}viewWillCacheSnapshot(){var e;((e=this.navigator.currentVisit)===null||e===void 0?void 0:e.silent)||this.notifyApplicationBeforeCachingSnapshot()}allowsImmediateRender({element:e},r){return!this.notifyApplicationBeforeRender(e,r).defaultPrevented}viewRenderedSnapshot(e,r){this.view.lastRenderedLocation=this.history.location,this.notifyApplicationAfterRender()}viewInvalidated(){this.adapter.pageInvalidated()}frameLoaded(e){this.notifyApplicationAfterFrameLoad(e)}frameRendered(e,r){this.notifyApplicationAfterFrameRender(e,r)}applicationAllowsFollowingLinkToLocation(e,r){return!this.notifyApplicationAfterClickingLinkToLocation(e,r).defaultPrevented}applicationAllowsVisitingLocation(e){return!this.notifyApplicationBeforeVisitingLocation(e).defaultPrevented}notifyApplicationAfterClickingLinkToLocation(e,r){return _("turbo:click",{target:e,detail:{url:r.href},cancelable:!0})}notifyApplicationBeforeVisitingLocation(e){return _("turbo:before-visit",{detail:{url:e.href},cancelable:!0})}notifyApplicationAfterVisitingLocation(e,r){return _("turbo:visit",{detail:{url:e.href,action:r}})}notifyApplicationBeforeCachingSnapshot(){return _("turbo:before-cache")}notifyApplicationBeforeRender(e,r){return _("turbo:before-render",{detail:{newBody:e,resume:r},cancelable:!0})}notifyApplicationAfterRender(){return _("turbo:render")}notifyApplicationAfterPageLoad(e={}){return _("turbo:load",{detail:{url:this.location.href,timing:e}})}notifyApplicationAfterVisitingSamePageLocation(e,r){dispatchEvent(new HashChangeEvent("hashchange",{oldURL:e.toString(),newURL:r.toString()}))}notifyApplicationAfterFrameLoad(e){return _("turbo:frame-load",{target:e})}notifyApplicationAfterFrameRender(e,r){return _("turbo:frame-render",{detail:{fetchResponse:e},target:r,cancelable:!0})}elementDriveEnabled(e){let r=e==null?void 0:e.closest("[data-turbo]");return this.drive?r?r.getAttribute("data-turbo")!="false":!0:r?r.getAttribute("data-turbo")=="true":!1}getActionForLink(e){let r=e.getAttribute("data-turbo-action");return qi(r)?r:"advance"}locationIsVisitable(e){return oa(e,this.snapshot.rootLocation)&&sa(e)}get snapshot(){return this.view.snapshot}};function Xi(t){Object.defineProperties(t,xa)}var xa={absoluteURL:{get(){return this.toString()}}},H=new Yi,{navigator:Na}=H;function Qi(){H.start()}function _a(t){H.registerAdapter(t)}function Fa(t,e){H.visit(t,e)}function Ha(t){H.connectStreamSource(t)}function Va(t){H.disconnectStreamSource(t)}function Ba(t){H.renderStreamMessage(t)}function ja(){H.clearCache()}function Ua(t){H.setProgressBarDelay(t)}var qa=Object.freeze({__proto__:null,navigator:Na,session:H,PageRenderer:Lr,PageSnapshot:me,start:Qi,registerAdapter:_a,visit:Fa,connectStreamSource:Ha,disconnectStreamSource:Va,renderStreamMessage:Ba,clearCache:ja,setProgressBarDelay:Ua}),en=class{constructor(e){this.resolveVisitPromise=()=>{},this.connected=!1,this.hasBeenLoaded=!1,this.settingSourceURL=!1,this.element=e,this.view=new Mi(this,this.element),this.appearanceObserver=new Ii(this,this.element),this.linkInterceptor=new Cr(this,this.element),this.formInterceptor=new Ar(this,this.element)}connect(){this.connected||(this.connected=!0,this.reloadable=!1,this.loadingStyle==Te.lazy&&this.appearanceObserver.start(),this.linkInterceptor.start(),this.formInterceptor.start(),this.sourceURLChanged())}disconnect(){this.connected&&(this.connected=!1,this.appearanceObserver.stop(),this.linkInterceptor.stop(),this.formInterceptor.stop())}disabledChanged(){this.loadingStyle==Te.eager&&this.loadSourceURL()}sourceURLChanged(){(this.loadingStyle==Te.eager||this.hasBeenLoaded)&&this.loadSourceURL()}loadingStyleChanged(){this.loadingStyle==Te.lazy?this.appearanceObserver.start():(this.appearanceObserver.stop(),this.loadSourceURL())}async loadSourceURL(){if(!this.settingSourceURL&&this.enabled&&this.isActive&&(this.reloadable||this.sourceURL!=this.currentURL)){let e=this.currentURL;if(this.currentURL=this.sourceURL,this.sourceURL)try{this.element.loaded=this.visit(this.sourceURL),this.appearanceObserver.stop(),await this.element.loaded,this.hasBeenLoaded=!0,H.frameLoaded(this.element)}catch(r){throw this.currentURL=e,r}}}async loadResponse(e){e.redirected&&(this.sourceURL=e.response.url);try{let r=await e.responseHTML;if(r){let{body:i}=Ci(r),n=new dt(await this.extractForeignFrameElement(i)),s=new Di(this.view.snapshot,n,!1);this.view.renderPromise&&await this.view.renderPromise,await this.view.render(s),H.frameRendered(e,this.element)}}catch(r){console.error(r),this.view.invalidate()}}elementAppearedInViewport(e){this.loadSourceURL()}shouldInterceptLinkClick(e,r){return e.hasAttribute("data-turbo-method")?!1:this.shouldInterceptNavigation(e)}linkClickIntercepted(e,r){this.reloadable=!0,this.navigateFrame(e,r)}shouldInterceptFormSubmission(e,r){return this.shouldInterceptNavigation(e,r)}formSubmissionIntercepted(e,r){if(this.formSubmission&&this.formSubmission.stop(),this.reloadable=!1,this.formSubmission=new kr(this,e,r),this.formSubmission.fetchRequest.isIdempotent)this.navigateFrame(e,this.formSubmission.fetchRequest.url.href);else{let{fetchRequest:i}=this.formSubmission;this.prepareHeadersForRequest(i.headers,i),this.formSubmission.start()}}prepareHeadersForRequest(e,r){e["Turbo-Frame"]=this.id}requestStarted(e){this.element.setAttribute("busy","")}requestPreventedHandlingResponse(e,r){this.resolveVisitPromise()}async requestSucceededWithResponse(e,r){await this.loadResponse(r),this.resolveVisitPromise()}requestFailedWithResponse(e,r){console.error(r),this.resolveVisitPromise()}requestErrored(e,r){console.error(r),this.resolveVisitPromise()}requestFinished(e){this.element.removeAttribute("busy")}formSubmissionStarted(e){this.findFrameElement(e.formElement).setAttribute("busy","")}formSubmissionSucceededWithResponse(e,r){this.findFrameElement(e.formElement).delegate.loadResponse(r)}formSubmissionFailedWithResponse(e,r){this.element.delegate.loadResponse(r)}formSubmissionErrored(e,r){console.error(r)}formSubmissionFinished(e){this.findFrameElement(e.formElement).removeAttribute("busy")}allowsImmediateRender(e,r){return!0}viewRenderedSnapshot(e,r){}viewInvalidated(){}async visit(e){let r=new jt(this,F.get,ne(e));return new Promise(i=>{this.resolveVisitPromise=()=>{this.resolveVisitPromise=()=>{},i()},r.perform()})}navigateFrame(e,r){let i=this.findFrameElement(e);i.src=r}findFrameElement(e){var r;let i=e.getAttribute("data-turbo-frame")||this.element.getAttribute("target");return(r=tn(i))!==null&&r!==void 0?r:this.element}async extractForeignFrameElement(e){let r,i=CSS.escape(this.id);try{if(r=rn(e.querySelector(`turbo-frame#${i}`),this.currentURL))return r;if(r=rn(e.querySelector(`turbo-frame[src][recurse~=${i}]`),this.currentURL))return await r.loaded,await this.extractForeignFrameElement(r);console.error(`Response has no matching <turbo-frame id="${i}"> element`)}catch(n){console.error(n)}return new fe}shouldInterceptNavigation(e,r){let i=e.getAttribute("data-turbo-frame")||this.element.getAttribute("target");if(!this.enabled||i=="_top")return!1;if(i){let n=tn(i);if(n)return!n.disabled}return!(!H.elementDriveEnabled(e)||r&&!H.elementDriveEnabled(r))}get id(){return this.element.id}get enabled(){return!this.element.disabled}get sourceURL(){if(this.element.src)return this.element.src}get reloadable(){return this.findFrameElement(this.element).hasAttribute("reloadable")}set reloadable(e){let r=this.findFrameElement(this.element);e?r.setAttribute("reloadable",""):r.removeAttribute("reloadable")}set sourceURL(e){this.settingSourceURL=!0,this.element.src=e??null,this.currentURL=this.element.src,this.settingSourceURL=!1}get loadingStyle(){return this.element.loading}get isLoading(){return this.formSubmission!==void 0||this.resolveVisitPromise()!==void 0}get isActive(){return this.element.isActive&&this.connected}};function tn(t){if(t!=null){let e=document.getElementById(t);if(e instanceof fe)return e}}function rn(t,e){if(t){let r=t.getAttribute("src");if(r!=null&&e!=null&&aa(r,e))throw new Error(`Matching <turbo-frame id="${t.id}"> element has a source URL which references itself`);if(t.ownerDocument!==document&&(t=document.importNode(t,!0)),t instanceof fe)return t.connectedCallback(),t}}var $a={after(){this.targetElements.forEach(t=>{var e;return(e=t.parentElement)===null||e===void 0?void 0:e.insertBefore(this.templateContent,t.nextSibling)})},append(){this.removeDuplicateTargetChildren(),this.targetElements.forEach(t=>t.append(this.templateContent))},before(){this.targetElements.forEach(t=>{var e;return(e=t.parentElement)===null||e===void 0?void 0:e.insertBefore(this.templateContent,t)})},prepend(){this.removeDuplicateTargetChildren(),this.targetElements.forEach(t=>t.prepend(this.templateContent))},remove(){this.targetElements.forEach(t=>t.remove())},replace(){this.targetElements.forEach(t=>t.replaceWith(this.templateContent))},update(){this.targetElements.forEach(t=>{t.innerHTML="",t.append(this.templateContent)})}},nn=class extends HTMLElement{async connectedCallback(){try{await this.render()}catch(e){console.error(e)}finally{this.disconnect()}}async render(){var e;return(e=this.renderPromise)!==null&&e!==void 0?e:this.renderPromise=(async()=>{this.dispatchEvent(this.beforeRenderEvent)&&(await Bt(),this.performAction())})()}disconnect(){try{this.remove()}catch(e){}}removeDuplicateTargetChildren(){this.duplicateChildren.forEach(e=>e.remove())}get duplicateChildren(){var e;let r=this.targetElements.flatMap(n=>[...n.children]).filter(n=>!!n.id),i=[...(e=this.templateContent)===null||e===void 0?void 0:e.children].filter(n=>!!n.id).map(n=>n.id);return r.filter(n=>i.includes(n.id))}get performAction(){if(this.action){let e=$a[this.action];if(e)return e;this.raise("unknown action")}this.raise("action attribute is missing")}get targetElements(){if(this.target)return this.targetElementsById;if(this.targets)return this.targetElementsByQuery;this.raise("target or targets attribute is missing")}get templateContent(){return this.templateElement.content.cloneNode(!0)}get templateElement(){if(this.firstElementChild instanceof HTMLTemplateElement)return this.firstElementChild;this.raise("first child element must be a <template> element")}get action(){return this.getAttribute("action")}get target(){return this.getAttribute("target")}get targets(){return this.getAttribute("targets")}raise(e){throw new Error(`${this.description}: ${e}`)}get description(){var e,r;return(r=((e=this.outerHTML.match(/<[^>]+>/))!==null&&e!==void 0?e:[])[0])!==null&&r!==void 0?r:"<turbo-stream>"}get beforeRenderEvent(){return new CustomEvent("turbo:before-stream-render",{bubbles:!0,cancelable:!0})}get targetElementsById(){var e;let r=(e=this.ownerDocument)===null||e===void 0?void 0:e.getElementById(this.target);return r!==null?[r]:[]}get targetElementsByQuery(){var e;let r=(e=this.ownerDocument)===null||e===void 0?void 0:e.querySelectorAll(this.targets);return r.length!==0?Array.prototype.slice.call(r):[]}};fe.delegateConstructor=en;customElements.define("turbo-frame",fe);customElements.define("turbo-stream",nn);(()=>{let t=document.currentScript;if(!!t&&!t.hasAttribute("data-turbo-suppress-warning")){for(;t=t.parentElement;)if(t==document.body)return console.warn(Li` You are loading Turbo from a <script> element inside the <body> element. This is probably not what you meant to do! Load your application’s JavaScript bundle inside the <head> element instead. <script> elements in <body> are evaluated with each page change. @@ -23,8 +24,24 @@ —— Suppress this warning by adding a "data-turbo-suppress-warning" attribute to: %s - `,r.outerHTML)}})();window.Turbo=er;Te();var Me=function(){function r(e,t,n){this.eventTarget=e,this.eventName=t,this.eventOptions=n,this.unorderedBindings=new Set}return r.prototype.connect=function(){this.eventTarget.addEventListener(this.eventName,this,this.eventOptions)},r.prototype.disconnect=function(){this.eventTarget.removeEventListener(this.eventName,this,this.eventOptions)},r.prototype.bindingConnected=function(e){this.unorderedBindings.add(e)},r.prototype.bindingDisconnected=function(e){this.unorderedBindings.delete(e)},r.prototype.handleEvent=function(e){for(var t=rr(e),n=0,i=this.bindings;n<i.length;n++){var s=i[n];if(t.immediatePropagationStopped)break;s.handleEvent(t)}},Object.defineProperty(r.prototype,"bindings",{get:function(){return Array.from(this.unorderedBindings).sort(function(e,t){var n=e.index,i=t.index;return n<i?-1:n>i?1:0})},enumerable:!1,configurable:!0}),r}();function rr(r){if("immediatePropagationStopped"in r)return r;var e=r.stopImmediatePropagation;return Object.assign(r,{immediatePropagationStopped:!1,stopImmediatePropagation:function(){this.immediatePropagationStopped=!0,e.call(this)}})}var xe=function(){function r(e){this.application=e,this.eventListenerMaps=new Map,this.started=!1}return r.prototype.start=function(){this.started||(this.started=!0,this.eventListeners.forEach(function(e){return e.connect()}))},r.prototype.stop=function(){this.started&&(this.started=!1,this.eventListeners.forEach(function(e){return e.disconnect()}))},Object.defineProperty(r.prototype,"eventListeners",{get:function(){return Array.from(this.eventListenerMaps.values()).reduce(function(e,t){return e.concat(Array.from(t.values()))},[])},enumerable:!1,configurable:!0}),r.prototype.bindingConnected=function(e){this.fetchEventListenerForBinding(e).bindingConnected(e)},r.prototype.bindingDisconnected=function(e){this.fetchEventListenerForBinding(e).bindingDisconnected(e)},r.prototype.handleError=function(e,t,n){n===void 0&&(n={}),this.application.handleError(e,"Error "+t,n)},r.prototype.fetchEventListenerForBinding=function(e){var t=e.eventTarget,n=e.eventName,i=e.eventOptions;return this.fetchEventListener(t,n,i)},r.prototype.fetchEventListener=function(e,t,n){var i=this.fetchEventListenerMapForEventTarget(e),s=this.cacheKey(t,n),o=i.get(s);return o||(o=this.createEventListener(e,t,n),i.set(s,o)),o},r.prototype.createEventListener=function(e,t,n){var i=new Me(e,t,n);return this.started&&i.connect(),i},r.prototype.fetchEventListenerMapForEventTarget=function(e){var t=this.eventListenerMaps.get(e);return t||(t=new Map,this.eventListenerMaps.set(e,t)),t},r.prototype.cacheKey=function(e,t){var n=[e];return Object.keys(t).sort().forEach(function(i){n.push(""+(t[i]?"":"!")+i)}),n.join(":")},r}();var nr=/^((.+?)(@(window|document))?->)?(.+?)(#([^:]+?))(:(.+))?$/;function Fe(r){var e=r.trim(),t=e.match(nr)||[];return{eventTarget:ir(t[4]),eventName:t[2],eventOptions:t[9]?sr(t[9]):{},identifier:t[5],methodName:t[7]}}function ir(r){if(r=="window")return window;if(r=="document")return document}function sr(r){return r.split(":").reduce(function(e,t){var n;return Object.assign(e,(n={},n[t.replace(/^!/,"")]=!/^!/.test(t),n))},{})}function Be(r){if(r==window)return"window";if(r==document)return"document"}var Ie=function(){function r(e,t,n){this.element=e,this.index=t,this.eventTarget=n.eventTarget||e,this.eventName=n.eventName||or(e)||G("missing event name"),this.eventOptions=n.eventOptions||{},this.identifier=n.identifier||G("missing identifier"),this.methodName=n.methodName||G("missing method name")}return r.forToken=function(e){return new this(e.element,e.index,Fe(e.content))},r.prototype.toString=function(){var e=this.eventTargetName?"@"+this.eventTargetName:"";return""+this.eventName+e+"->"+this.identifier+"#"+this.methodName},Object.defineProperty(r.prototype,"eventTargetName",{get:function(){return Be(this.eventTarget)},enumerable:!1,configurable:!0}),r}();var Ne={a:function(r){return"click"},button:function(r){return"click"},form:function(r){return"submit"},input:function(r){return r.getAttribute("type")=="submit"?"click":"input"},select:function(r){return"change"},textarea:function(r){return"input"}};function or(r){var e=r.tagName.toLowerCase();if(e in Ne)return Ne[e](r)}function G(r){throw new Error(r)}var qe=function(){function r(e,t){this.context=e,this.action=t}return Object.defineProperty(r.prototype,"index",{get:function(){return this.action.index},enumerable:!1,configurable:!0}),Object.defineProperty(r.prototype,"eventTarget",{get:function(){return this.action.eventTarget},enumerable:!1,configurable:!0}),Object.defineProperty(r.prototype,"eventOptions",{get:function(){return this.action.eventOptions},enumerable:!1,configurable:!0}),Object.defineProperty(r.prototype,"identifier",{get:function(){return this.context.identifier},enumerable:!1,configurable:!0}),r.prototype.handleEvent=function(e){this.willBeInvokedByEvent(e)&&this.invokeWithEvent(e)},Object.defineProperty(r.prototype,"eventName",{get:function(){return this.action.eventName},enumerable:!1,configurable:!0}),Object.defineProperty(r.prototype,"method",{get:function(){var e=this.controller[this.methodName];if(typeof e=="function")return e;throw new Error('Action "'+this.action+'" references undefined method "'+this.methodName+'"')},enumerable:!1,configurable:!0}),r.prototype.invokeWithEvent=function(e){try{this.method.call(this.controller,e)}catch(l){var t=this,n=t.identifier,i=t.controller,s=t.element,o=t.index,c={identifier:n,controller:i,element:s,index:o,event:e};this.context.handleError(l,'invoking action "'+this.action+'"',c)}},r.prototype.willBeInvokedByEvent=function(e){var t=e.target;return this.element===t?!0:t instanceof Element&&this.element.contains(t)?this.scope.containsElement(t):this.scope.containsElement(this.action.element)},Object.defineProperty(r.prototype,"controller",{get:function(){return this.context.controller},enumerable:!1,configurable:!0}),Object.defineProperty(r.prototype,"methodName",{get:function(){return this.action.methodName},enumerable:!1,configurable:!0}),Object.defineProperty(r.prototype,"element",{get:function(){return this.scope.element},enumerable:!1,configurable:!0}),Object.defineProperty(r.prototype,"scope",{get:function(){return this.context.scope},enumerable:!1,configurable:!0}),r}();var Ve=function(){function r(e,t){var n=this;this.element=e,this.started=!1,this.delegate=t,this.elements=new Set,this.mutationObserver=new MutationObserver(function(i){return n.processMutations(i)})}return r.prototype.start=function(){this.started||(this.started=!0,this.mutationObserver.observe(this.element,{attributes:!0,childList:!0,subtree:!0}),this.refresh())},r.prototype.stop=function(){this.started&&(this.mutationObserver.takeRecords(),this.mutationObserver.disconnect(),this.started=!1)},r.prototype.refresh=function(){if(this.started){for(var e=new Set(this.matchElementsInTree()),t=0,n=Array.from(this.elements);t<n.length;t++){var i=n[t];e.has(i)||this.removeElement(i)}for(var s=0,o=Array.from(e);s<o.length;s++){var i=o[s];this.addElement(i)}}},r.prototype.processMutations=function(e){if(this.started)for(var t=0,n=e;t<n.length;t++){var i=n[t];this.processMutation(i)}},r.prototype.processMutation=function(e){e.type=="attributes"?this.processAttributeChange(e.target,e.attributeName):e.type=="childList"&&(this.processRemovedNodes(e.removedNodes),this.processAddedNodes(e.addedNodes))},r.prototype.processAttributeChange=function(e,t){var n=e;this.elements.has(n)?this.delegate.elementAttributeChanged&&this.matchElement(n)?this.delegate.elementAttributeChanged(n,t):this.removeElement(n):this.matchElement(n)&&this.addElement(n)},r.prototype.processRemovedNodes=function(e){for(var t=0,n=Array.from(e);t<n.length;t++){var i=n[t],s=this.elementFromNode(i);s&&this.processTree(s,this.removeElement)}},r.prototype.processAddedNodes=function(e){for(var t=0,n=Array.from(e);t<n.length;t++){var i=n[t],s=this.elementFromNode(i);s&&this.elementIsActive(s)&&this.processTree(s,this.addElement)}},r.prototype.matchElement=function(e){return this.delegate.matchElement(e)},r.prototype.matchElementsInTree=function(e){return e===void 0&&(e=this.element),this.delegate.matchElementsInTree(e)},r.prototype.processTree=function(e,t){for(var n=0,i=this.matchElementsInTree(e);n<i.length;n++){var s=i[n];t.call(this,s)}},r.prototype.elementFromNode=function(e){if(e.nodeType==Node.ELEMENT_NODE)return e},r.prototype.elementIsActive=function(e){return e.isConnected!=this.element.isConnected?!1:this.element.contains(e)},r.prototype.addElement=function(e){this.elements.has(e)||this.elementIsActive(e)&&(this.elements.add(e),this.delegate.elementMatched&&this.delegate.elementMatched(e))},r.prototype.removeElement=function(e){this.elements.has(e)&&(this.elements.delete(e),this.delegate.elementUnmatched&&this.delegate.elementUnmatched(e))},r}();var je=function(){function r(e,t,n){this.attributeName=t,this.delegate=n,this.elementObserver=new Ve(e,this)}return Object.defineProperty(r.prototype,"element",{get:function(){return this.elementObserver.element},enumerable:!1,configurable:!0}),Object.defineProperty(r.prototype,"selector",{get:function(){return"["+this.attributeName+"]"},enumerable:!1,configurable:!0}),r.prototype.start=function(){this.elementObserver.start()},r.prototype.stop=function(){this.elementObserver.stop()},r.prototype.refresh=function(){this.elementObserver.refresh()},Object.defineProperty(r.prototype,"started",{get:function(){return this.elementObserver.started},enumerable:!1,configurable:!0}),r.prototype.matchElement=function(e){return e.hasAttribute(this.attributeName)},r.prototype.matchElementsInTree=function(e){var t=this.matchElement(e)?[e]:[],n=Array.from(e.querySelectorAll(this.selector));return t.concat(n)},r.prototype.elementMatched=function(e){this.delegate.elementMatchedAttribute&&this.delegate.elementMatchedAttribute(e,this.attributeName)},r.prototype.elementUnmatched=function(e){this.delegate.elementUnmatchedAttribute&&this.delegate.elementUnmatchedAttribute(e,this.attributeName)},r.prototype.elementAttributeChanged=function(e,t){this.delegate.elementAttributeValueChanged&&this.attributeName==t&&this.delegate.elementAttributeValueChanged(e,t)},r}();var De=function(){function r(e,t){var n=this;this.element=e,this.delegate=t,this.started=!1,this.stringMap=new Map,this.mutationObserver=new MutationObserver(function(i){return n.processMutations(i)})}return r.prototype.start=function(){this.started||(this.started=!0,this.mutationObserver.observe(this.element,{attributes:!0}),this.refresh())},r.prototype.stop=function(){this.started&&(this.mutationObserver.takeRecords(),this.mutationObserver.disconnect(),this.started=!1)},r.prototype.refresh=function(){if(this.started)for(var e=0,t=this.knownAttributeNames;e<t.length;e++){var n=t[e];this.refreshAttribute(n)}},r.prototype.processMutations=function(e){if(this.started)for(var t=0,n=e;t<n.length;t++){var i=n[t];this.processMutation(i)}},r.prototype.processMutation=function(e){var t=e.attributeName;t&&this.refreshAttribute(t)},r.prototype.refreshAttribute=function(e){var t=this.delegate.getStringMapKeyForAttribute(e);if(t!=null){this.stringMap.has(e)||this.stringMapKeyAdded(t,e);var n=this.element.getAttribute(e);this.stringMap.get(e)!=n&&this.stringMapValueChanged(n,t),n==null?(this.stringMap.delete(e),this.stringMapKeyRemoved(t,e)):this.stringMap.set(e,n)}},r.prototype.stringMapKeyAdded=function(e,t){this.delegate.stringMapKeyAdded&&this.delegate.stringMapKeyAdded(e,t)},r.prototype.stringMapValueChanged=function(e,t){this.delegate.stringMapValueChanged&&this.delegate.stringMapValueChanged(e,t)},r.prototype.stringMapKeyRemoved=function(e,t){this.delegate.stringMapKeyRemoved&&this.delegate.stringMapKeyRemoved(e,t)},Object.defineProperty(r.prototype,"knownAttributeNames",{get:function(){return Array.from(new Set(this.currentAttributeNames.concat(this.recordedAttributeNames)))},enumerable:!1,configurable:!0}),Object.defineProperty(r.prototype,"currentAttributeNames",{get:function(){return Array.from(this.element.attributes).map(function(e){return e.name})},enumerable:!1,configurable:!0}),Object.defineProperty(r.prototype,"recordedAttributeNames",{get:function(){return Array.from(this.stringMap.keys())},enumerable:!1,configurable:!0}),r}();function q(r,e,t){He(r,e).add(t)}function V(r,e,t){He(r,e).delete(t),ar(r,e)}function He(r,e){var t=r.get(e);return t||(t=new Set,r.set(e,t)),t}function ar(r,e){var t=r.get(e);t!=null&&t.size==0&&r.delete(e)}var C=function(){function r(){this.valuesByKey=new Map}return Object.defineProperty(r.prototype,"values",{get:function(){var e=Array.from(this.valuesByKey.values());return e.reduce(function(t,n){return t.concat(Array.from(n))},[])},enumerable:!1,configurable:!0}),Object.defineProperty(r.prototype,"size",{get:function(){var e=Array.from(this.valuesByKey.values());return e.reduce(function(t,n){return t+n.size},0)},enumerable:!1,configurable:!0}),r.prototype.add=function(e,t){q(this.valuesByKey,e,t)},r.prototype.delete=function(e,t){V(this.valuesByKey,e,t)},r.prototype.has=function(e,t){var n=this.valuesByKey.get(e);return n!=null&&n.has(t)},r.prototype.hasKey=function(e){return this.valuesByKey.has(e)},r.prototype.hasValue=function(e){var t=Array.from(this.valuesByKey.values());return t.some(function(n){return n.has(e)})},r.prototype.getValuesForKey=function(e){var t=this.valuesByKey.get(e);return t?Array.from(t):[]},r.prototype.getKeysForValue=function(e){return Array.from(this.valuesByKey).filter(function(t){var n=t[0],i=t[1];return i.has(e)}).map(function(t){var n=t[0],i=t[1];return n})},r}();var cr=function(){var r=function(e,t){return r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,i){n.__proto__=i}||function(n,i){for(var s in i)i.hasOwnProperty(s)&&(n[s]=i[s])},r(e,t)};return function(e,t){r(e,t);function n(){this.constructor=e}e.prototype=t===null?Object.create(t):(n.prototype=t.prototype,new n)}}(),en=function(r){cr(e,r);function e(){var t=r.call(this)||this;return t.keysByValue=new Map,t}return Object.defineProperty(e.prototype,"values",{get:function(){return Array.from(this.keysByValue.keys())},enumerable:!1,configurable:!0}),e.prototype.add=function(t,n){r.prototype.add.call(this,t,n),q(this.keysByValue,n,t)},e.prototype.delete=function(t,n){r.prototype.delete.call(this,t,n),V(this.keysByValue,n,t)},e.prototype.hasValue=function(t){return this.keysByValue.has(t)},e.prototype.getKeysForValue=function(t){var n=this.keysByValue.get(t);return n?Array.from(n):[]},e}(C);var _e=function(){function r(e,t,n){this.attributeObserver=new je(e,t,this),this.delegate=n,this.tokensByElement=new C}return Object.defineProperty(r.prototype,"started",{get:function(){return this.attributeObserver.started},enumerable:!1,configurable:!0}),r.prototype.start=function(){this.attributeObserver.start()},r.prototype.stop=function(){this.attributeObserver.stop()},r.prototype.refresh=function(){this.attributeObserver.refresh()},Object.defineProperty(r.prototype,"element",{get:function(){return this.attributeObserver.element},enumerable:!1,configurable:!0}),Object.defineProperty(r.prototype,"attributeName",{get:function(){return this.attributeObserver.attributeName},enumerable:!1,configurable:!0}),r.prototype.elementMatchedAttribute=function(e){this.tokensMatched(this.readTokensForElement(e))},r.prototype.elementAttributeValueChanged=function(e){var t=this.refreshTokensForElement(e),n=t[0],i=t[1];this.tokensUnmatched(n),this.tokensMatched(i)},r.prototype.elementUnmatchedAttribute=function(e){this.tokensUnmatched(this.tokensByElement.getValuesForKey(e))},r.prototype.tokensMatched=function(e){var t=this;e.forEach(function(n){return t.tokenMatched(n)})},r.prototype.tokensUnmatched=function(e){var t=this;e.forEach(function(n){return t.tokenUnmatched(n)})},r.prototype.tokenMatched=function(e){this.delegate.tokenMatched(e),this.tokensByElement.add(e.element,e)},r.prototype.tokenUnmatched=function(e){this.delegate.tokenUnmatched(e),this.tokensByElement.delete(e.element,e)},r.prototype.refreshTokensForElement=function(e){var t=this.tokensByElement.getValuesForKey(e),n=this.readTokensForElement(e),i=ur(t,n).findIndex(function(s){var o=s[0],c=s[1];return!hr(o,c)});return i==-1?[[],[]]:[t.slice(i),n.slice(i)]},r.prototype.readTokensForElement=function(e){var t=this.attributeName,n=e.getAttribute(t)||"";return lr(n,e,t)},r}();function lr(r,e,t){return r.trim().split(/\s+/).filter(function(n){return n.length}).map(function(n,i){return{element:e,attributeName:t,content:n,index:i}})}function ur(r,e){var t=Math.max(r.length,e.length);return Array.from({length:t},function(n,i){return[r[i],e[i]]})}function hr(r,e){return r&&e&&r.index==e.index&&r.content==e.content}var j=function(){function r(e,t,n){this.tokenListObserver=new _e(e,t,this),this.delegate=n,this.parseResultsByToken=new WeakMap,this.valuesByTokenByElement=new WeakMap}return Object.defineProperty(r.prototype,"started",{get:function(){return this.tokenListObserver.started},enumerable:!1,configurable:!0}),r.prototype.start=function(){this.tokenListObserver.start()},r.prototype.stop=function(){this.tokenListObserver.stop()},r.prototype.refresh=function(){this.tokenListObserver.refresh()},Object.defineProperty(r.prototype,"element",{get:function(){return this.tokenListObserver.element},enumerable:!1,configurable:!0}),Object.defineProperty(r.prototype,"attributeName",{get:function(){return this.tokenListObserver.attributeName},enumerable:!1,configurable:!0}),r.prototype.tokenMatched=function(e){var t=e.element,n=this.fetchParseResultForToken(e).value;n&&(this.fetchValuesByTokenForElement(t).set(e,n),this.delegate.elementMatchedValue(t,n))},r.prototype.tokenUnmatched=function(e){var t=e.element,n=this.fetchParseResultForToken(e).value;n&&(this.fetchValuesByTokenForElement(t).delete(e),this.delegate.elementUnmatchedValue(t,n))},r.prototype.fetchParseResultForToken=function(e){var t=this.parseResultsByToken.get(e);return t||(t=this.parseToken(e),this.parseResultsByToken.set(e,t)),t},r.prototype.fetchValuesByTokenForElement=function(e){var t=this.valuesByTokenByElement.get(e);return t||(t=new Map,this.valuesByTokenByElement.set(e,t)),t},r.prototype.parseToken=function(e){try{var t=this.delegate.parseValueForToken(e);return{value:t}}catch(n){return{error:n}}},r}();var We=function(){function r(e,t){this.context=e,this.delegate=t,this.bindingsByAction=new Map}return r.prototype.start=function(){this.valueListObserver||(this.valueListObserver=new j(this.element,this.actionAttribute,this),this.valueListObserver.start())},r.prototype.stop=function(){this.valueListObserver&&(this.valueListObserver.stop(),delete this.valueListObserver,this.disconnectAllActions())},Object.defineProperty(r.prototype,"element",{get:function(){return this.context.element},enumerable:!1,configurable:!0}),Object.defineProperty(r.prototype,"identifier",{get:function(){return this.context.identifier},enumerable:!1,configurable:!0}),Object.defineProperty(r.prototype,"actionAttribute",{get:function(){return this.schema.actionAttribute},enumerable:!1,configurable:!0}),Object.defineProperty(r.prototype,"schema",{get:function(){return this.context.schema},enumerable:!1,configurable:!0}),Object.defineProperty(r.prototype,"bindings",{get:function(){return Array.from(this.bindingsByAction.values())},enumerable:!1,configurable:!0}),r.prototype.connectAction=function(e){var t=new qe(this.context,e);this.bindingsByAction.set(e,t),this.delegate.bindingConnected(t)},r.prototype.disconnectAction=function(e){var t=this.bindingsByAction.get(e);t&&(this.bindingsByAction.delete(e),this.delegate.bindingDisconnected(t))},r.prototype.disconnectAllActions=function(){var e=this;this.bindings.forEach(function(t){return e.delegate.bindingDisconnected(t)}),this.bindingsByAction.clear()},r.prototype.parseValueForToken=function(e){var t=Ie.forToken(e);if(t.identifier==this.identifier)return t},r.prototype.elementMatchedValue=function(e,t){this.connectAction(t)},r.prototype.elementUnmatchedValue=function(e,t){this.disconnectAction(t)},r}();var Ue=function(){function r(e,t){this.context=e,this.receiver=t,this.stringMapObserver=new De(this.element,this),this.valueDescriptorMap=this.controller.valueDescriptorMap,this.invokeChangedCallbacksForDefaultValues()}return r.prototype.start=function(){this.stringMapObserver.start()},r.prototype.stop=function(){this.stringMapObserver.stop()},Object.defineProperty(r.prototype,"element",{get:function(){return this.context.element},enumerable:!1,configurable:!0}),Object.defineProperty(r.prototype,"controller",{get:function(){return this.context.controller},enumerable:!1,configurable:!0}),r.prototype.getStringMapKeyForAttribute=function(e){if(e in this.valueDescriptorMap)return this.valueDescriptorMap[e].name},r.prototype.stringMapValueChanged=function(e,t){this.invokeChangedCallbackForValue(t)},r.prototype.invokeChangedCallbacksForDefaultValues=function(){for(var e=0,t=this.valueDescriptors;e<t.length;e++){var n=t[e],i=n.key,s=n.name,o=n.defaultValue;o!=null&&!this.controller.data.has(i)&&this.invokeChangedCallbackForValue(s)}},r.prototype.invokeChangedCallbackForValue=function(e){var t=e+"Changed",n=this.receiver[t];if(typeof n=="function"){var i=this.receiver[e];n.call(this.receiver,i)}},Object.defineProperty(r.prototype,"valueDescriptors",{get:function(){var e=this.valueDescriptorMap;return Object.keys(e).map(function(t){return e[t]})},enumerable:!1,configurable:!0}),r}();var Q=function(){function r(e,t){this.module=e,this.scope=t,this.controller=new e.controllerConstructor(this),this.bindingObserver=new We(this,this.dispatcher),this.valueObserver=new Ue(this,this.controller);try{this.controller.initialize()}catch(n){this.handleError(n,"initializing controller")}}return r.prototype.connect=function(){this.bindingObserver.start(),this.valueObserver.start();try{this.controller.connect()}catch(e){this.handleError(e,"connecting controller")}},r.prototype.disconnect=function(){try{this.controller.disconnect()}catch(e){this.handleError(e,"disconnecting controller")}this.valueObserver.stop(),this.bindingObserver.stop()},Object.defineProperty(r.prototype,"application",{get:function(){return this.module.application},enumerable:!1,configurable:!0}),Object.defineProperty(r.prototype,"identifier",{get:function(){return this.module.identifier},enumerable:!1,configurable:!0}),Object.defineProperty(r.prototype,"schema",{get:function(){return this.application.schema},enumerable:!1,configurable:!0}),Object.defineProperty(r.prototype,"dispatcher",{get:function(){return this.application.dispatcher},enumerable:!1,configurable:!0}),Object.defineProperty(r.prototype,"element",{get:function(){return this.scope.element},enumerable:!1,configurable:!0}),Object.defineProperty(r.prototype,"parentElement",{get:function(){return this.element.parentElement},enumerable:!1,configurable:!0}),r.prototype.handleError=function(e,t,n){n===void 0&&(n={});var i=this,s=i.identifier,o=i.controller,c=i.element;n=Object.assign({identifier:s,controller:o,element:c},n),this.application.handleError(e,"Error "+t,n)},r}();function O(r,e){var t=ze(r);return Array.from(t.reduce(function(n,i){return dr(i,e).forEach(function(s){return n.add(s)}),n},new Set))}function Ke(r,e){var t=ze(r);return t.reduce(function(n,i){return n.push.apply(n,fr(i,e)),n},[])}function ze(r){for(var e=[];r;)e.push(r),r=Object.getPrototypeOf(r);return e.reverse()}function dr(r,e){var t=r[e];return Array.isArray(t)?t:[]}function fr(r,e){var t=r[e];return t?Object.keys(t).map(function(n){return[n,t[n]]}):[]}var pr=function(){var r=function(e,t){return r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,i){n.__proto__=i}||function(n,i){for(var s in i)i.hasOwnProperty(s)&&(n[s]=i[s])},r(e,t)};return function(e,t){r(e,t);function n(){this.constructor=e}e.prototype=t===null?Object.create(t):(n.prototype=t.prototype,new n)}}(),mr=function(){for(var r=0,e=0,t=arguments.length;e<t;e++)r+=arguments[e].length;for(var n=Array(r),i=0,e=0;e<t;e++)for(var s=arguments[e],o=0,c=s.length;o<c;o++,i++)n[i]=s[o];return n};function $e(r){return gr(r,vr(r))}function gr(r,e){var t=Er(r),n=br(r.prototype,e);return Object.defineProperties(t.prototype,n),t}function vr(r){var e=O(r,"blessings");return e.reduce(function(t,n){var i=n(r);for(var s in i){var o=t[s]||{};t[s]=Object.assign(o,i[s])}return t},{})}function br(r,e){return wr(e).reduce(function(t,n){var i,s=yr(r,e,n);return s&&Object.assign(t,(i={},i[n]=s,i)),t},{})}function yr(r,e,t){var n=Object.getOwnPropertyDescriptor(r,t),i=n&&"value"in n;if(!i){var s=Object.getOwnPropertyDescriptor(e,t).value;return n&&(s.get=n.get||s.get,s.set=n.set||s.set),s}}var wr=function(){return typeof Object.getOwnPropertySymbols=="function"?function(r){return mr(Object.getOwnPropertyNames(r),Object.getOwnPropertySymbols(r))}:Object.getOwnPropertyNames}(),Er=function(){function r(t){function n(){var i=this&&this instanceof n?this.constructor:void 0;return Reflect.construct(t,arguments,i)}return n.prototype=Object.create(t.prototype,{constructor:{value:n}}),Reflect.setPrototypeOf(n,t),n}function e(){var t=function(){this.a.call(this)},n=r(t);return n.prototype.a=function(){},new n}try{return e(),r}catch(t){return function(n){return function(i){pr(s,i);function s(){return i!==null&&i.apply(this,arguments)||this}return s}(n)}}}();function Je(r){return{identifier:r.identifier,controllerConstructor:$e(r.controllerConstructor)}}var Ge=function(){function r(e,t){this.application=e,this.definition=Je(t),this.contextsByScope=new WeakMap,this.connectedContexts=new Set}return Object.defineProperty(r.prototype,"identifier",{get:function(){return this.definition.identifier},enumerable:!1,configurable:!0}),Object.defineProperty(r.prototype,"controllerConstructor",{get:function(){return this.definition.controllerConstructor},enumerable:!1,configurable:!0}),Object.defineProperty(r.prototype,"contexts",{get:function(){return Array.from(this.connectedContexts)},enumerable:!1,configurable:!0}),r.prototype.connectContextForScope=function(e){var t=this.fetchContextForScope(e);this.connectedContexts.add(t),t.connect()},r.prototype.disconnectContextForScope=function(e){var t=this.contextsByScope.get(e);t&&(this.connectedContexts.delete(t),t.disconnect())},r.prototype.fetchContextForScope=function(e){var t=this.contextsByScope.get(e);return t||(t=new Q(this,e),this.contextsByScope.set(e,t)),t},r}();var Qe=function(){function r(e){this.scope=e}return r.prototype.has=function(e){return this.data.has(this.getDataKey(e))},r.prototype.get=function(e){return this.data.get(this.getDataKey(e))},r.prototype.getAttributeName=function(e){return this.data.getAttributeNameForKey(this.getDataKey(e))},r.prototype.getDataKey=function(e){return e+"-class"},Object.defineProperty(r.prototype,"data",{get:function(){return this.scope.data},enumerable:!1,configurable:!0}),r}();function Xe(r){return r.replace(/(?:[_-])([a-z0-9])/g,function(e,t){return t.toUpperCase()})}function R(r){return r.charAt(0).toUpperCase()+r.slice(1)}function D(r){return r.replace(/([A-Z])/g,function(e,t){return"-"+t.toLowerCase()})}var Ye=function(){function r(e){this.scope=e}return Object.defineProperty(r.prototype,"element",{get:function(){return this.scope.element},enumerable:!1,configurable:!0}),Object.defineProperty(r.prototype,"identifier",{get:function(){return this.scope.identifier},enumerable:!1,configurable:!0}),r.prototype.get=function(e){var t=this.getAttributeNameForKey(e);return this.element.getAttribute(t)},r.prototype.set=function(e,t){var n=this.getAttributeNameForKey(e);return this.element.setAttribute(n,t),this.get(e)},r.prototype.has=function(e){var t=this.getAttributeNameForKey(e);return this.element.hasAttribute(t)},r.prototype.delete=function(e){if(this.has(e)){var t=this.getAttributeNameForKey(e);return this.element.removeAttribute(t),!0}else return!1},r.prototype.getAttributeNameForKey=function(e){return"data-"+this.identifier+"-"+D(e)},r}();var Ze=function(){function r(e){this.warnedKeysByObject=new WeakMap,this.logger=e}return r.prototype.warn=function(e,t,n){var i=this.warnedKeysByObject.get(e);i||(i=new Set,this.warnedKeysByObject.set(e,i)),i.has(t)||(i.add(t),this.logger.warn(n,e))},r}();function x(r,e){return"["+r+'~="'+e+'"]'}var Sr=function(){for(var r=0,e=0,t=arguments.length;e<t;e++)r+=arguments[e].length;for(var n=Array(r),i=0,e=0;e<t;e++)for(var s=arguments[e],o=0,c=s.length;o<c;o++,i++)n[i]=s[o];return n},et=function(){function r(e){this.scope=e}return Object.defineProperty(r.prototype,"element",{get:function(){return this.scope.element},enumerable:!1,configurable:!0}),Object.defineProperty(r.prototype,"identifier",{get:function(){return this.scope.identifier},enumerable:!1,configurable:!0}),Object.defineProperty(r.prototype,"schema",{get:function(){return this.scope.schema},enumerable:!1,configurable:!0}),r.prototype.has=function(e){return this.find(e)!=null},r.prototype.find=function(){for(var e=this,t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];return t.reduce(function(i,s){return i||e.findTarget(s)||e.findLegacyTarget(s)},void 0)},r.prototype.findAll=function(){for(var e=this,t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];return t.reduce(function(i,s){return Sr(i,e.findAllTargets(s),e.findAllLegacyTargets(s))},[])},r.prototype.findTarget=function(e){var t=this.getSelectorForTargetName(e);return this.scope.findElement(t)},r.prototype.findAllTargets=function(e){var t=this.getSelectorForTargetName(e);return this.scope.findAllElements(t)},r.prototype.getSelectorForTargetName=function(e){var t="data-"+this.identifier+"-target";return x(t,e)},r.prototype.findLegacyTarget=function(e){var t=this.getLegacySelectorForTargetName(e);return this.deprecate(this.scope.findElement(t),e)},r.prototype.findAllLegacyTargets=function(e){var t=this,n=this.getLegacySelectorForTargetName(e);return this.scope.findAllElements(n).map(function(i){return t.deprecate(i,e)})},r.prototype.getLegacySelectorForTargetName=function(e){var t=this.identifier+"."+e;return x(this.schema.targetAttribute,t)},r.prototype.deprecate=function(e,t){if(e){var n=this.identifier,i=this.schema.targetAttribute;this.guide.warn(e,"target:"+t,"Please replace "+i+'="'+n+"."+t+'" with data-'+n+'-target="'+t+'". '+("The "+i+" attribute is deprecated and will be removed in a future version of Stimulus."))}return e},Object.defineProperty(r.prototype,"guide",{get:function(){return this.scope.guide},enumerable:!1,configurable:!0}),r}();var Ar=function(){for(var r=0,e=0,t=arguments.length;e<t;e++)r+=arguments[e].length;for(var n=Array(r),i=0,e=0;e<t;e++)for(var s=arguments[e],o=0,c=s.length;o<c;o++,i++)n[i]=s[o];return n},tt=function(){function r(e,t,n,i){var s=this;this.targets=new et(this),this.classes=new Qe(this),this.data=new Ye(this),this.containsElement=function(o){return o.closest(s.controllerSelector)===s.element},this.schema=e,this.element=t,this.identifier=n,this.guide=new Ze(i)}return r.prototype.findElement=function(e){return this.element.matches(e)?this.element:this.queryElements(e).find(this.containsElement)},r.prototype.findAllElements=function(e){return Ar(this.element.matches(e)?[this.element]:[],this.queryElements(e).filter(this.containsElement))},r.prototype.queryElements=function(e){return Array.from(this.element.querySelectorAll(e))},Object.defineProperty(r.prototype,"controllerSelector",{get:function(){return x(this.schema.controllerAttribute,this.identifier)},enumerable:!1,configurable:!0}),r}();var rt=function(){function r(e,t,n){this.element=e,this.schema=t,this.delegate=n,this.valueListObserver=new j(this.element,this.controllerAttribute,this),this.scopesByIdentifierByElement=new WeakMap,this.scopeReferenceCounts=new WeakMap}return r.prototype.start=function(){this.valueListObserver.start()},r.prototype.stop=function(){this.valueListObserver.stop()},Object.defineProperty(r.prototype,"controllerAttribute",{get:function(){return this.schema.controllerAttribute},enumerable:!1,configurable:!0}),r.prototype.parseValueForToken=function(e){var t=e.element,n=e.content,i=this.fetchScopesByIdentifierForElement(t),s=i.get(n);return s||(s=this.delegate.createScopeForElementAndIdentifier(t,n),i.set(n,s)),s},r.prototype.elementMatchedValue=function(e,t){var n=(this.scopeReferenceCounts.get(t)||0)+1;this.scopeReferenceCounts.set(t,n),n==1&&this.delegate.scopeConnected(t)},r.prototype.elementUnmatchedValue=function(e,t){var n=this.scopeReferenceCounts.get(t);n&&(this.scopeReferenceCounts.set(t,n-1),n==1&&this.delegate.scopeDisconnected(t))},r.prototype.fetchScopesByIdentifierForElement=function(e){var t=this.scopesByIdentifierByElement.get(e);return t||(t=new Map,this.scopesByIdentifierByElement.set(e,t)),t},r}();var nt=function(){function r(e){this.application=e,this.scopeObserver=new rt(this.element,this.schema,this),this.scopesByIdentifier=new C,this.modulesByIdentifier=new Map}return Object.defineProperty(r.prototype,"element",{get:function(){return this.application.element},enumerable:!1,configurable:!0}),Object.defineProperty(r.prototype,"schema",{get:function(){return this.application.schema},enumerable:!1,configurable:!0}),Object.defineProperty(r.prototype,"logger",{get:function(){return this.application.logger},enumerable:!1,configurable:!0}),Object.defineProperty(r.prototype,"controllerAttribute",{get:function(){return this.schema.controllerAttribute},enumerable:!1,configurable:!0}),Object.defineProperty(r.prototype,"modules",{get:function(){return Array.from(this.modulesByIdentifier.values())},enumerable:!1,configurable:!0}),Object.defineProperty(r.prototype,"contexts",{get:function(){return this.modules.reduce(function(e,t){return e.concat(t.contexts)},[])},enumerable:!1,configurable:!0}),r.prototype.start=function(){this.scopeObserver.start()},r.prototype.stop=function(){this.scopeObserver.stop()},r.prototype.loadDefinition=function(e){this.unloadIdentifier(e.identifier);var t=new Ge(this.application,e);this.connectModule(t)},r.prototype.unloadIdentifier=function(e){var t=this.modulesByIdentifier.get(e);t&&this.disconnectModule(t)},r.prototype.getContextForElementAndIdentifier=function(e,t){var n=this.modulesByIdentifier.get(t);if(n)return n.contexts.find(function(i){return i.element==e})},r.prototype.handleError=function(e,t,n){this.application.handleError(e,t,n)},r.prototype.createScopeForElementAndIdentifier=function(e,t){return new tt(this.schema,e,t,this.logger)},r.prototype.scopeConnected=function(e){this.scopesByIdentifier.add(e.identifier,e);var t=this.modulesByIdentifier.get(e.identifier);t&&t.connectContextForScope(e)},r.prototype.scopeDisconnected=function(e){this.scopesByIdentifier.delete(e.identifier,e);var t=this.modulesByIdentifier.get(e.identifier);t&&t.disconnectContextForScope(e)},r.prototype.connectModule=function(e){this.modulesByIdentifier.set(e.identifier,e);var t=this.scopesByIdentifier.getValuesForKey(e.identifier);t.forEach(function(n){return e.connectContextForScope(n)})},r.prototype.disconnectModule=function(e){this.modulesByIdentifier.delete(e.identifier);var t=this.scopesByIdentifier.getValuesForKey(e.identifier);t.forEach(function(n){return e.disconnectContextForScope(n)})},r}();var X={controllerAttribute:"data-controller",actionAttribute:"data-action",targetAttribute:"data-target"};var Pr=function(r,e,t,n){function i(s){return s instanceof t?s:new t(function(o){o(s)})}return new(t||(t=Promise))(function(s,o){function c(f){try{a(n.next(f))}catch(H){o(H)}}function l(f){try{a(n.throw(f))}catch(H){o(H)}}function a(f){f.done?s(f.value):i(f.value).then(c,l)}a((n=n.apply(r,e||[])).next())})},Lr=function(r,e){var t={label:0,sent:function(){if(s[0]&1)throw s[1];return s[1]},trys:[],ops:[]},n,i,s,o;return o={next:c(0),throw:c(1),return:c(2)},typeof Symbol=="function"&&(o[Symbol.iterator]=function(){return this}),o;function c(a){return function(f){return l([a,f])}}function l(a){if(n)throw new TypeError("Generator is already executing.");for(;t;)try{if(n=1,i&&(s=a[0]&2?i.return:a[0]?i.throw||((s=i.return)&&s.call(i),0):i.next)&&!(s=s.call(i,a[1])).done)return s;switch(i=0,s&&(a=[a[0]&2,s.value]),a[0]){case 0:case 1:s=a;break;case 4:return t.label++,{value:a[1],done:!1};case 5:t.label++,i=a[1],a=[0];continue;case 7:a=t.ops.pop(),t.trys.pop();continue;default:if(s=t.trys,!(s=s.length>0&&s[s.length-1])&&(a[0]===6||a[0]===2)){t=0;continue}if(a[0]===3&&(!s||a[1]>s[0]&&a[1]<s[3])){t.label=a[1];break}if(a[0]===6&&t.label<s[1]){t.label=s[1],s=a;break}if(s&&t.label<s[2]){t.label=s[2],t.ops.push(a);break}s[2]&&t.ops.pop(),t.trys.pop();continue}a=e.call(r,t)}catch(f){a=[6,f],i=0}finally{n=s=0}if(a[0]&5)throw a[1];return{value:a[0]?a[1]:void 0,done:!0}}},it=function(){for(var r=0,e=0,t=arguments.length;e<t;e++)r+=arguments[e].length;for(var n=Array(r),i=0,e=0;e<t;e++)for(var s=arguments[e],o=0,c=s.length;o<c;o++,i++)n[i]=s[o];return n},Y=function(){function r(e,t){e===void 0&&(e=document.documentElement),t===void 0&&(t=X),this.logger=console,this.element=e,this.schema=t,this.dispatcher=new xe(this),this.router=new nt(this)}return r.start=function(e,t){var n=new r(e,t);return n.start(),n},r.prototype.start=function(){return Pr(this,void 0,void 0,function(){return Lr(this,function(e){switch(e.label){case 0:return[4,Tr()];case 1:return e.sent(),this.dispatcher.start(),this.router.start(),[2]}})})},r.prototype.stop=function(){this.dispatcher.stop(),this.router.stop()},r.prototype.register=function(e,t){this.load({identifier:e,controllerConstructor:t})},r.prototype.load=function(e){for(var t=this,n=[],i=1;i<arguments.length;i++)n[i-1]=arguments[i];var s=Array.isArray(e)?e:it([e],n);s.forEach(function(o){return t.router.loadDefinition(o)})},r.prototype.unload=function(e){for(var t=this,n=[],i=1;i<arguments.length;i++)n[i-1]=arguments[i];var s=Array.isArray(e)?e:it([e],n);s.forEach(function(o){return t.router.unloadIdentifier(o)})},Object.defineProperty(r.prototype,"controllers",{get:function(){return this.router.contexts.map(function(e){return e.controller})},enumerable:!1,configurable:!0}),r.prototype.getControllerForElementAndIdentifier=function(e,t){var n=this.router.getContextForElementAndIdentifier(e,t);return n?n.controller:null},r.prototype.handleError=function(e,t,n){this.logger.error(`%s + `,t.outerHTML)}})();window.Turbo=qa;Qi();var sn=function(){function t(e,r,i){this.eventTarget=e,this.eventName=r,this.eventOptions=i,this.unorderedBindings=new Set}return t.prototype.connect=function(){this.eventTarget.addEventListener(this.eventName,this,this.eventOptions)},t.prototype.disconnect=function(){this.eventTarget.removeEventListener(this.eventName,this,this.eventOptions)},t.prototype.bindingConnected=function(e){this.unorderedBindings.add(e)},t.prototype.bindingDisconnected=function(e){this.unorderedBindings.delete(e)},t.prototype.handleEvent=function(e){for(var r=Wa(e),i=0,n=this.bindings;i<n.length;i++){var s=n[i];if(r.immediatePropagationStopped)break;s.handleEvent(r)}},Object.defineProperty(t.prototype,"bindings",{get:function(){return Array.from(this.unorderedBindings).sort(function(e,r){var i=e.index,n=r.index;return i<n?-1:i>n?1:0})},enumerable:!1,configurable:!0}),t}();function Wa(t){if("immediatePropagationStopped"in t)return t;var e=t.stopImmediatePropagation;return Object.assign(t,{immediatePropagationStopped:!1,stopImmediatePropagation:function(){this.immediatePropagationStopped=!0,e.call(this)}})}var on=function(){function t(e){this.application=e,this.eventListenerMaps=new Map,this.started=!1}return t.prototype.start=function(){this.started||(this.started=!0,this.eventListeners.forEach(function(e){return e.connect()}))},t.prototype.stop=function(){this.started&&(this.started=!1,this.eventListeners.forEach(function(e){return e.disconnect()}))},Object.defineProperty(t.prototype,"eventListeners",{get:function(){return Array.from(this.eventListenerMaps.values()).reduce(function(e,r){return e.concat(Array.from(r.values()))},[])},enumerable:!1,configurable:!0}),t.prototype.bindingConnected=function(e){this.fetchEventListenerForBinding(e).bindingConnected(e)},t.prototype.bindingDisconnected=function(e){this.fetchEventListenerForBinding(e).bindingDisconnected(e)},t.prototype.handleError=function(e,r,i){i===void 0&&(i={}),this.application.handleError(e,"Error "+r,i)},t.prototype.fetchEventListenerForBinding=function(e){var r=e.eventTarget,i=e.eventName,n=e.eventOptions;return this.fetchEventListener(r,i,n)},t.prototype.fetchEventListener=function(e,r,i){var n=this.fetchEventListenerMapForEventTarget(e),s=this.cacheKey(r,i),o=n.get(s);return o||(o=this.createEventListener(e,r,i),n.set(s,o)),o},t.prototype.createEventListener=function(e,r,i){var n=new sn(e,r,i);return this.started&&n.connect(),n},t.prototype.fetchEventListenerMapForEventTarget=function(e){var r=this.eventListenerMaps.get(e);return r||(r=new Map,this.eventListenerMaps.set(e,r)),r},t.prototype.cacheKey=function(e,r){var i=[e];return Object.keys(r).sort().forEach(function(n){i.push(""+(r[n]?"":"!")+n)}),i.join(":")},t}();var za=/^((.+?)(@(window|document))?->)?(.+?)(#([^:]+?))(:(.+))?$/;function an(t){var e=t.trim(),r=e.match(za)||[];return{eventTarget:Za(r[4]),eventName:r[2],eventOptions:r[9]?Ja(r[9]):{},identifier:r[5],methodName:r[7]}}function Za(t){if(t=="window")return window;if(t=="document")return document}function Ja(t){return t.split(":").reduce(function(e,r){var i;return Object.assign(e,(i={},i[r.replace(/^!/,"")]=!/^!/.test(r),i))},{})}function ln(t){if(t==window)return"window";if(t==document)return"document"}var un=function(){function t(e,r,i){this.element=e,this.index=r,this.eventTarget=i.eventTarget||e,this.eventName=i.eventName||Ka(e)||Ir("missing event name"),this.eventOptions=i.eventOptions||{},this.identifier=i.identifier||Ir("missing identifier"),this.methodName=i.methodName||Ir("missing method name")}return t.forToken=function(e){return new this(e.element,e.index,an(e.content))},t.prototype.toString=function(){var e=this.eventTargetName?"@"+this.eventTargetName:"";return""+this.eventName+e+"->"+this.identifier+"#"+this.methodName},Object.defineProperty(t.prototype,"eventTargetName",{get:function(){return ln(this.eventTarget)},enumerable:!1,configurable:!0}),t}();var cn={a:function(t){return"click"},button:function(t){return"click"},form:function(t){return"submit"},input:function(t){return t.getAttribute("type")=="submit"?"click":"input"},select:function(t){return"change"},textarea:function(t){return"input"}};function Ka(t){var e=t.tagName.toLowerCase();if(e in cn)return cn[e](t)}function Ir(t){throw new Error(t)}var hn=function(){function t(e,r){this.context=e,this.action=r}return Object.defineProperty(t.prototype,"index",{get:function(){return this.action.index},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"eventTarget",{get:function(){return this.action.eventTarget},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"eventOptions",{get:function(){return this.action.eventOptions},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"identifier",{get:function(){return this.context.identifier},enumerable:!1,configurable:!0}),t.prototype.handleEvent=function(e){this.willBeInvokedByEvent(e)&&this.invokeWithEvent(e)},Object.defineProperty(t.prototype,"eventName",{get:function(){return this.action.eventName},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"method",{get:function(){var e=this.controller[this.methodName];if(typeof e=="function")return e;throw new Error('Action "'+this.action+'" references undefined method "'+this.methodName+'"')},enumerable:!1,configurable:!0}),t.prototype.invokeWithEvent=function(e){try{this.method.call(this.controller,e)}catch(l){var r=this,i=r.identifier,n=r.controller,s=r.element,o=r.index,a={identifier:i,controller:n,element:s,index:o,event:e};this.context.handleError(l,'invoking action "'+this.action+'"',a)}},t.prototype.willBeInvokedByEvent=function(e){var r=e.target;return this.element===r?!0:r instanceof Element&&this.element.contains(r)?this.scope.containsElement(r):this.scope.containsElement(this.action.element)},Object.defineProperty(t.prototype,"controller",{get:function(){return this.context.controller},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"methodName",{get:function(){return this.action.methodName},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"element",{get:function(){return this.scope.element},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"scope",{get:function(){return this.context.scope},enumerable:!1,configurable:!0}),t}();var dn=function(){function t(e,r){var i=this;this.element=e,this.started=!1,this.delegate=r,this.elements=new Set,this.mutationObserver=new MutationObserver(function(n){return i.processMutations(n)})}return t.prototype.start=function(){this.started||(this.started=!0,this.mutationObserver.observe(this.element,{attributes:!0,childList:!0,subtree:!0}),this.refresh())},t.prototype.stop=function(){this.started&&(this.mutationObserver.takeRecords(),this.mutationObserver.disconnect(),this.started=!1)},t.prototype.refresh=function(){if(this.started){for(var e=new Set(this.matchElementsInTree()),r=0,i=Array.from(this.elements);r<i.length;r++){var n=i[r];e.has(n)||this.removeElement(n)}for(var s=0,o=Array.from(e);s<o.length;s++){var n=o[s];this.addElement(n)}}},t.prototype.processMutations=function(e){if(this.started)for(var r=0,i=e;r<i.length;r++){var n=i[r];this.processMutation(n)}},t.prototype.processMutation=function(e){e.type=="attributes"?this.processAttributeChange(e.target,e.attributeName):e.type=="childList"&&(this.processRemovedNodes(e.removedNodes),this.processAddedNodes(e.addedNodes))},t.prototype.processAttributeChange=function(e,r){var i=e;this.elements.has(i)?this.delegate.elementAttributeChanged&&this.matchElement(i)?this.delegate.elementAttributeChanged(i,r):this.removeElement(i):this.matchElement(i)&&this.addElement(i)},t.prototype.processRemovedNodes=function(e){for(var r=0,i=Array.from(e);r<i.length;r++){var n=i[r],s=this.elementFromNode(n);s&&this.processTree(s,this.removeElement)}},t.prototype.processAddedNodes=function(e){for(var r=0,i=Array.from(e);r<i.length;r++){var n=i[r],s=this.elementFromNode(n);s&&this.elementIsActive(s)&&this.processTree(s,this.addElement)}},t.prototype.matchElement=function(e){return this.delegate.matchElement(e)},t.prototype.matchElementsInTree=function(e){return e===void 0&&(e=this.element),this.delegate.matchElementsInTree(e)},t.prototype.processTree=function(e,r){for(var i=0,n=this.matchElementsInTree(e);i<n.length;i++){var s=n[i];r.call(this,s)}},t.prototype.elementFromNode=function(e){if(e.nodeType==Node.ELEMENT_NODE)return e},t.prototype.elementIsActive=function(e){return e.isConnected!=this.element.isConnected?!1:this.element.contains(e)},t.prototype.addElement=function(e){this.elements.has(e)||this.elementIsActive(e)&&(this.elements.add(e),this.delegate.elementMatched&&this.delegate.elementMatched(e))},t.prototype.removeElement=function(e){this.elements.has(e)&&(this.elements.delete(e),this.delegate.elementUnmatched&&this.delegate.elementUnmatched(e))},t}();var fn=function(){function t(e,r,i){this.attributeName=r,this.delegate=i,this.elementObserver=new dn(e,this)}return Object.defineProperty(t.prototype,"element",{get:function(){return this.elementObserver.element},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"selector",{get:function(){return"["+this.attributeName+"]"},enumerable:!1,configurable:!0}),t.prototype.start=function(){this.elementObserver.start()},t.prototype.stop=function(){this.elementObserver.stop()},t.prototype.refresh=function(){this.elementObserver.refresh()},Object.defineProperty(t.prototype,"started",{get:function(){return this.elementObserver.started},enumerable:!1,configurable:!0}),t.prototype.matchElement=function(e){return e.hasAttribute(this.attributeName)},t.prototype.matchElementsInTree=function(e){var r=this.matchElement(e)?[e]:[],i=Array.from(e.querySelectorAll(this.selector));return r.concat(i)},t.prototype.elementMatched=function(e){this.delegate.elementMatchedAttribute&&this.delegate.elementMatchedAttribute(e,this.attributeName)},t.prototype.elementUnmatched=function(e){this.delegate.elementUnmatchedAttribute&&this.delegate.elementUnmatchedAttribute(e,this.attributeName)},t.prototype.elementAttributeChanged=function(e,r){this.delegate.elementAttributeValueChanged&&this.attributeName==r&&this.delegate.elementAttributeValueChanged(e,r)},t}();var mn=function(){function t(e,r){var i=this;this.element=e,this.delegate=r,this.started=!1,this.stringMap=new Map,this.mutationObserver=new MutationObserver(function(n){return i.processMutations(n)})}return t.prototype.start=function(){this.started||(this.started=!0,this.mutationObserver.observe(this.element,{attributes:!0}),this.refresh())},t.prototype.stop=function(){this.started&&(this.mutationObserver.takeRecords(),this.mutationObserver.disconnect(),this.started=!1)},t.prototype.refresh=function(){if(this.started)for(var e=0,r=this.knownAttributeNames;e<r.length;e++){var i=r[e];this.refreshAttribute(i)}},t.prototype.processMutations=function(e){if(this.started)for(var r=0,i=e;r<i.length;r++){var n=i[r];this.processMutation(n)}},t.prototype.processMutation=function(e){var r=e.attributeName;r&&this.refreshAttribute(r)},t.prototype.refreshAttribute=function(e){var r=this.delegate.getStringMapKeyForAttribute(e);if(r!=null){this.stringMap.has(e)||this.stringMapKeyAdded(r,e);var i=this.element.getAttribute(e);this.stringMap.get(e)!=i&&this.stringMapValueChanged(i,r),i==null?(this.stringMap.delete(e),this.stringMapKeyRemoved(r,e)):this.stringMap.set(e,i)}},t.prototype.stringMapKeyAdded=function(e,r){this.delegate.stringMapKeyAdded&&this.delegate.stringMapKeyAdded(e,r)},t.prototype.stringMapValueChanged=function(e,r){this.delegate.stringMapValueChanged&&this.delegate.stringMapValueChanged(e,r)},t.prototype.stringMapKeyRemoved=function(e,r){this.delegate.stringMapKeyRemoved&&this.delegate.stringMapKeyRemoved(e,r)},Object.defineProperty(t.prototype,"knownAttributeNames",{get:function(){return Array.from(new Set(this.currentAttributeNames.concat(this.recordedAttributeNames)))},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"currentAttributeNames",{get:function(){return Array.from(this.element.attributes).map(function(e){return e.name})},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"recordedAttributeNames",{get:function(){return Array.from(this.stringMap.keys())},enumerable:!1,configurable:!0}),t}();function qt(t,e,r){pn(t,e).add(r)}function $t(t,e,r){pn(t,e).delete(r),Ga(t,e)}function pn(t,e){var r=t.get(e);return r||(r=new Set,t.set(e,r)),r}function Ga(t,e){var r=t.get(e);r!=null&&r.size==0&&t.delete(e)}var Ke=function(){function t(){this.valuesByKey=new Map}return Object.defineProperty(t.prototype,"values",{get:function(){var e=Array.from(this.valuesByKey.values());return e.reduce(function(r,i){return r.concat(Array.from(i))},[])},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"size",{get:function(){var e=Array.from(this.valuesByKey.values());return e.reduce(function(r,i){return r+i.size},0)},enumerable:!1,configurable:!0}),t.prototype.add=function(e,r){qt(this.valuesByKey,e,r)},t.prototype.delete=function(e,r){$t(this.valuesByKey,e,r)},t.prototype.has=function(e,r){var i=this.valuesByKey.get(e);return i!=null&&i.has(r)},t.prototype.hasKey=function(e){return this.valuesByKey.has(e)},t.prototype.hasValue=function(e){var r=Array.from(this.valuesByKey.values());return r.some(function(i){return i.has(e)})},t.prototype.getValuesForKey=function(e){var r=this.valuesByKey.get(e);return r?Array.from(r):[]},t.prototype.getKeysForValue=function(e){return Array.from(this.valuesByKey).filter(function(r){var i=r[0],n=r[1];return n.has(e)}).map(function(r){var i=r[0],n=r[1];return i})},t}();var Ya=function(){var t=function(e,r){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,n){i.__proto__=n}||function(i,n){for(var s in n)n.hasOwnProperty(s)&&(i[s]=n[s])},t(e,r)};return function(e,r){t(e,r);function i(){this.constructor=e}e.prototype=r===null?Object.create(r):(i.prototype=r.prototype,new i)}}(),jh=function(t){Ya(e,t);function e(){var r=t.call(this)||this;return r.keysByValue=new Map,r}return Object.defineProperty(e.prototype,"values",{get:function(){return Array.from(this.keysByValue.keys())},enumerable:!1,configurable:!0}),e.prototype.add=function(r,i){t.prototype.add.call(this,r,i),qt(this.keysByValue,i,r)},e.prototype.delete=function(r,i){t.prototype.delete.call(this,r,i),$t(this.keysByValue,i,r)},e.prototype.hasValue=function(r){return this.keysByValue.has(r)},e.prototype.getKeysForValue=function(r){var i=this.keysByValue.get(r);return i?Array.from(i):[]},e}(Ke);var gn=function(){function t(e,r,i){this.attributeObserver=new fn(e,r,this),this.delegate=i,this.tokensByElement=new Ke}return Object.defineProperty(t.prototype,"started",{get:function(){return this.attributeObserver.started},enumerable:!1,configurable:!0}),t.prototype.start=function(){this.attributeObserver.start()},t.prototype.stop=function(){this.attributeObserver.stop()},t.prototype.refresh=function(){this.attributeObserver.refresh()},Object.defineProperty(t.prototype,"element",{get:function(){return this.attributeObserver.element},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"attributeName",{get:function(){return this.attributeObserver.attributeName},enumerable:!1,configurable:!0}),t.prototype.elementMatchedAttribute=function(e){this.tokensMatched(this.readTokensForElement(e))},t.prototype.elementAttributeValueChanged=function(e){var r=this.refreshTokensForElement(e),i=r[0],n=r[1];this.tokensUnmatched(i),this.tokensMatched(n)},t.prototype.elementUnmatchedAttribute=function(e){this.tokensUnmatched(this.tokensByElement.getValuesForKey(e))},t.prototype.tokensMatched=function(e){var r=this;e.forEach(function(i){return r.tokenMatched(i)})},t.prototype.tokensUnmatched=function(e){var r=this;e.forEach(function(i){return r.tokenUnmatched(i)})},t.prototype.tokenMatched=function(e){this.delegate.tokenMatched(e),this.tokensByElement.add(e.element,e)},t.prototype.tokenUnmatched=function(e){this.delegate.tokenUnmatched(e),this.tokensByElement.delete(e.element,e)},t.prototype.refreshTokensForElement=function(e){var r=this.tokensByElement.getValuesForKey(e),i=this.readTokensForElement(e),n=Qa(r,i).findIndex(function(s){var o=s[0],a=s[1];return!el(o,a)});return n==-1?[[],[]]:[r.slice(n),i.slice(n)]},t.prototype.readTokensForElement=function(e){var r=this.attributeName,i=e.getAttribute(r)||"";return Xa(i,e,r)},t}();function Xa(t,e,r){return t.trim().split(/\s+/).filter(function(i){return i.length}).map(function(i,n){return{element:e,attributeName:r,content:i,index:n}})}function Qa(t,e){var r=Math.max(t.length,e.length);return Array.from({length:r},function(i,n){return[t[n],e[n]]})}function el(t,e){return t&&e&&t.index==e.index&&t.content==e.content}var Wt=function(){function t(e,r,i){this.tokenListObserver=new gn(e,r,this),this.delegate=i,this.parseResultsByToken=new WeakMap,this.valuesByTokenByElement=new WeakMap}return Object.defineProperty(t.prototype,"started",{get:function(){return this.tokenListObserver.started},enumerable:!1,configurable:!0}),t.prototype.start=function(){this.tokenListObserver.start()},t.prototype.stop=function(){this.tokenListObserver.stop()},t.prototype.refresh=function(){this.tokenListObserver.refresh()},Object.defineProperty(t.prototype,"element",{get:function(){return this.tokenListObserver.element},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"attributeName",{get:function(){return this.tokenListObserver.attributeName},enumerable:!1,configurable:!0}),t.prototype.tokenMatched=function(e){var r=e.element,i=this.fetchParseResultForToken(e).value;i&&(this.fetchValuesByTokenForElement(r).set(e,i),this.delegate.elementMatchedValue(r,i))},t.prototype.tokenUnmatched=function(e){var r=e.element,i=this.fetchParseResultForToken(e).value;i&&(this.fetchValuesByTokenForElement(r).delete(e),this.delegate.elementUnmatchedValue(r,i))},t.prototype.fetchParseResultForToken=function(e){var r=this.parseResultsByToken.get(e);return r||(r=this.parseToken(e),this.parseResultsByToken.set(e,r)),r},t.prototype.fetchValuesByTokenForElement=function(e){var r=this.valuesByTokenByElement.get(e);return r||(r=new Map,this.valuesByTokenByElement.set(e,r)),r},t.prototype.parseToken=function(e){try{var r=this.delegate.parseValueForToken(e);return{value:r}}catch(i){return{error:i}}},t}();var vn=function(){function t(e,r){this.context=e,this.delegate=r,this.bindingsByAction=new Map}return t.prototype.start=function(){this.valueListObserver||(this.valueListObserver=new Wt(this.element,this.actionAttribute,this),this.valueListObserver.start())},t.prototype.stop=function(){this.valueListObserver&&(this.valueListObserver.stop(),delete this.valueListObserver,this.disconnectAllActions())},Object.defineProperty(t.prototype,"element",{get:function(){return this.context.element},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"identifier",{get:function(){return this.context.identifier},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"actionAttribute",{get:function(){return this.schema.actionAttribute},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"schema",{get:function(){return this.context.schema},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"bindings",{get:function(){return Array.from(this.bindingsByAction.values())},enumerable:!1,configurable:!0}),t.prototype.connectAction=function(e){var r=new hn(this.context,e);this.bindingsByAction.set(e,r),this.delegate.bindingConnected(r)},t.prototype.disconnectAction=function(e){var r=this.bindingsByAction.get(e);r&&(this.bindingsByAction.delete(e),this.delegate.bindingDisconnected(r))},t.prototype.disconnectAllActions=function(){var e=this;this.bindings.forEach(function(r){return e.delegate.bindingDisconnected(r)}),this.bindingsByAction.clear()},t.prototype.parseValueForToken=function(e){var r=un.forToken(e);if(r.identifier==this.identifier)return r},t.prototype.elementMatchedValue=function(e,r){this.connectAction(r)},t.prototype.elementUnmatchedValue=function(e,r){this.disconnectAction(r)},t}();var yn=function(){function t(e,r){this.context=e,this.receiver=r,this.stringMapObserver=new mn(this.element,this),this.valueDescriptorMap=this.controller.valueDescriptorMap,this.invokeChangedCallbacksForDefaultValues()}return t.prototype.start=function(){this.stringMapObserver.start()},t.prototype.stop=function(){this.stringMapObserver.stop()},Object.defineProperty(t.prototype,"element",{get:function(){return this.context.element},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"controller",{get:function(){return this.context.controller},enumerable:!1,configurable:!0}),t.prototype.getStringMapKeyForAttribute=function(e){if(e in this.valueDescriptorMap)return this.valueDescriptorMap[e].name},t.prototype.stringMapValueChanged=function(e,r){this.invokeChangedCallbackForValue(r)},t.prototype.invokeChangedCallbacksForDefaultValues=function(){for(var e=0,r=this.valueDescriptors;e<r.length;e++){var i=r[e],n=i.key,s=i.name,o=i.defaultValue;o!=null&&!this.controller.data.has(n)&&this.invokeChangedCallbackForValue(s)}},t.prototype.invokeChangedCallbackForValue=function(e){var r=e+"Changed",i=this.receiver[r];if(typeof i=="function"){var n=this.receiver[e];i.call(this.receiver,n)}},Object.defineProperty(t.prototype,"valueDescriptors",{get:function(){var e=this.valueDescriptorMap;return Object.keys(e).map(function(r){return e[r]})},enumerable:!1,configurable:!0}),t}();var Pr=function(){function t(e,r){this.module=e,this.scope=r,this.controller=new e.controllerConstructor(this),this.bindingObserver=new vn(this,this.dispatcher),this.valueObserver=new yn(this,this.controller);try{this.controller.initialize()}catch(i){this.handleError(i,"initializing controller")}}return t.prototype.connect=function(){this.bindingObserver.start(),this.valueObserver.start();try{this.controller.connect()}catch(e){this.handleError(e,"connecting controller")}},t.prototype.disconnect=function(){try{this.controller.disconnect()}catch(e){this.handleError(e,"disconnecting controller")}this.valueObserver.stop(),this.bindingObserver.stop()},Object.defineProperty(t.prototype,"application",{get:function(){return this.module.application},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"identifier",{get:function(){return this.module.identifier},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"schema",{get:function(){return this.application.schema},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"dispatcher",{get:function(){return this.application.dispatcher},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"element",{get:function(){return this.scope.element},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"parentElement",{get:function(){return this.element.parentElement},enumerable:!1,configurable:!0}),t.prototype.handleError=function(e,r,i){i===void 0&&(i={});var n=this,s=n.identifier,o=n.controller,a=n.element;i=Object.assign({identifier:s,controller:o,element:a},i),this.application.handleError(e,"Error "+r,i)},t}();function Ge(t,e){var r=wn(t);return Array.from(r.reduce(function(i,n){return tl(n,e).forEach(function(s){return i.add(s)}),i},new Set))}function bn(t,e){var r=wn(t);return r.reduce(function(i,n){return i.push.apply(i,rl(n,e)),i},[])}function wn(t){for(var e=[];t;)e.push(t),t=Object.getPrototypeOf(t);return e.reverse()}function tl(t,e){var r=t[e];return Array.isArray(r)?r:[]}function rl(t,e){var r=t[e];return r?Object.keys(r).map(function(i){return[i,r[i]]}):[]}var il=function(){var t=function(e,r){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,n){i.__proto__=n}||function(i,n){for(var s in n)n.hasOwnProperty(s)&&(i[s]=n[s])},t(e,r)};return function(e,r){t(e,r);function i(){this.constructor=e}e.prototype=r===null?Object.create(r):(i.prototype=r.prototype,new i)}}(),nl=function(){for(var t=0,e=0,r=arguments.length;e<r;e++)t+=arguments[e].length;for(var i=Array(t),n=0,e=0;e<r;e++)for(var s=arguments[e],o=0,a=s.length;o<a;o++,n++)i[n]=s[o];return i};function Sn(t){return sl(t,ol(t))}function sl(t,e){var r=cl(t),i=al(t.prototype,e);return Object.defineProperties(r.prototype,i),r}function ol(t){var e=Ge(t,"blessings");return e.reduce(function(r,i){var n=i(t);for(var s in n){var o=r[s]||{};r[s]=Object.assign(o,n[s])}return r},{})}function al(t,e){return ul(e).reduce(function(r,i){var n,s=ll(t,e,i);return s&&Object.assign(r,(n={},n[i]=s,n)),r},{})}function ll(t,e,r){var i=Object.getOwnPropertyDescriptor(t,r),n=i&&"value"in i;if(!n){var s=Object.getOwnPropertyDescriptor(e,r).value;return i&&(s.get=i.get||s.get,s.set=i.set||s.set),s}}var ul=function(){return typeof Object.getOwnPropertySymbols=="function"?function(t){return nl(Object.getOwnPropertyNames(t),Object.getOwnPropertySymbols(t))}:Object.getOwnPropertyNames}(),cl=function(){function t(r){function i(){var n=this&&this instanceof i?this.constructor:void 0;return Reflect.construct(r,arguments,n)}return i.prototype=Object.create(r.prototype,{constructor:{value:i}}),Reflect.setPrototypeOf(i,r),i}function e(){var r=function(){this.a.call(this)},i=t(r);return i.prototype.a=function(){},new i}try{return e(),t}catch(r){return function(i){return function(n){il(s,n);function s(){return n!==null&&n.apply(this,arguments)||this}return s}(i)}}}();function En(t){return{identifier:t.identifier,controllerConstructor:Sn(t.controllerConstructor)}}var Tn=function(){function t(e,r){this.application=e,this.definition=En(r),this.contextsByScope=new WeakMap,this.connectedContexts=new Set}return Object.defineProperty(t.prototype,"identifier",{get:function(){return this.definition.identifier},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"controllerConstructor",{get:function(){return this.definition.controllerConstructor},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"contexts",{get:function(){return Array.from(this.connectedContexts)},enumerable:!1,configurable:!0}),t.prototype.connectContextForScope=function(e){var r=this.fetchContextForScope(e);this.connectedContexts.add(r),r.connect()},t.prototype.disconnectContextForScope=function(e){var r=this.contextsByScope.get(e);r&&(this.connectedContexts.delete(r),r.disconnect())},t.prototype.fetchContextForScope=function(e){var r=this.contextsByScope.get(e);return r||(r=new Pr(this,e),this.contextsByScope.set(e,r)),r},t}();var kn=function(){function t(e){this.scope=e}return t.prototype.has=function(e){return this.data.has(this.getDataKey(e))},t.prototype.get=function(e){return this.data.get(this.getDataKey(e))},t.prototype.getAttributeName=function(e){return this.data.getAttributeNameForKey(this.getDataKey(e))},t.prototype.getDataKey=function(e){return e+"-class"},Object.defineProperty(t.prototype,"data",{get:function(){return this.scope.data},enumerable:!1,configurable:!0}),t}();function An(t){return t.replace(/(?:[_-])([a-z0-9])/g,function(e,r){return r.toUpperCase()})}function Ye(t){return t.charAt(0).toUpperCase()+t.slice(1)}function zt(t){return t.replace(/([A-Z])/g,function(e,r){return"-"+r.toLowerCase()})}var On=function(){function t(e){this.scope=e}return Object.defineProperty(t.prototype,"element",{get:function(){return this.scope.element},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"identifier",{get:function(){return this.scope.identifier},enumerable:!1,configurable:!0}),t.prototype.get=function(e){var r=this.getAttributeNameForKey(e);return this.element.getAttribute(r)},t.prototype.set=function(e,r){var i=this.getAttributeNameForKey(e);return this.element.setAttribute(i,r),this.get(e)},t.prototype.has=function(e){var r=this.getAttributeNameForKey(e);return this.element.hasAttribute(r)},t.prototype.delete=function(e){if(this.has(e)){var r=this.getAttributeNameForKey(e);return this.element.removeAttribute(r),!0}else return!1},t.prototype.getAttributeNameForKey=function(e){return"data-"+this.identifier+"-"+zt(e)},t}();var Cn=function(){function t(e){this.warnedKeysByObject=new WeakMap,this.logger=e}return t.prototype.warn=function(e,r,i){var n=this.warnedKeysByObject.get(e);n||(n=new Set,this.warnedKeysByObject.set(e,n)),n.has(r)||(n.add(r),this.logger.warn(i,e))},t}();function ft(t,e){return"["+t+'~="'+e+'"]'}var hl=function(){for(var t=0,e=0,r=arguments.length;e<r;e++)t+=arguments[e].length;for(var i=Array(t),n=0,e=0;e<r;e++)for(var s=arguments[e],o=0,a=s.length;o<a;o++,n++)i[n]=s[o];return i},Ln=function(){function t(e){this.scope=e}return Object.defineProperty(t.prototype,"element",{get:function(){return this.scope.element},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"identifier",{get:function(){return this.scope.identifier},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"schema",{get:function(){return this.scope.schema},enumerable:!1,configurable:!0}),t.prototype.has=function(e){return this.find(e)!=null},t.prototype.find=function(){for(var e=this,r=[],i=0;i<arguments.length;i++)r[i]=arguments[i];return r.reduce(function(n,s){return n||e.findTarget(s)||e.findLegacyTarget(s)},void 0)},t.prototype.findAll=function(){for(var e=this,r=[],i=0;i<arguments.length;i++)r[i]=arguments[i];return r.reduce(function(n,s){return hl(n,e.findAllTargets(s),e.findAllLegacyTargets(s))},[])},t.prototype.findTarget=function(e){var r=this.getSelectorForTargetName(e);return this.scope.findElement(r)},t.prototype.findAllTargets=function(e){var r=this.getSelectorForTargetName(e);return this.scope.findAllElements(r)},t.prototype.getSelectorForTargetName=function(e){var r="data-"+this.identifier+"-target";return ft(r,e)},t.prototype.findLegacyTarget=function(e){var r=this.getLegacySelectorForTargetName(e);return this.deprecate(this.scope.findElement(r),e)},t.prototype.findAllLegacyTargets=function(e){var r=this,i=this.getLegacySelectorForTargetName(e);return this.scope.findAllElements(i).map(function(n){return r.deprecate(n,e)})},t.prototype.getLegacySelectorForTargetName=function(e){var r=this.identifier+"."+e;return ft(this.schema.targetAttribute,r)},t.prototype.deprecate=function(e,r){if(e){var i=this.identifier,n=this.schema.targetAttribute;this.guide.warn(e,"target:"+r,"Please replace "+n+'="'+i+"."+r+'" with data-'+i+'-target="'+r+'". '+("The "+n+" attribute is deprecated and will be removed in a future version of Stimulus."))}return e},Object.defineProperty(t.prototype,"guide",{get:function(){return this.scope.guide},enumerable:!1,configurable:!0}),t}();var dl=function(){for(var t=0,e=0,r=arguments.length;e<r;e++)t+=arguments[e].length;for(var i=Array(t),n=0,e=0;e<r;e++)for(var s=arguments[e],o=0,a=s.length;o<a;o++,n++)i[n]=s[o];return i},In=function(){function t(e,r,i,n){var s=this;this.targets=new Ln(this),this.classes=new kn(this),this.data=new On(this),this.containsElement=function(o){return o.closest(s.controllerSelector)===s.element},this.schema=e,this.element=r,this.identifier=i,this.guide=new Cn(n)}return t.prototype.findElement=function(e){return this.element.matches(e)?this.element:this.queryElements(e).find(this.containsElement)},t.prototype.findAllElements=function(e){return dl(this.element.matches(e)?[this.element]:[],this.queryElements(e).filter(this.containsElement))},t.prototype.queryElements=function(e){return Array.from(this.element.querySelectorAll(e))},Object.defineProperty(t.prototype,"controllerSelector",{get:function(){return ft(this.schema.controllerAttribute,this.identifier)},enumerable:!1,configurable:!0}),t}();var Pn=function(){function t(e,r,i){this.element=e,this.schema=r,this.delegate=i,this.valueListObserver=new Wt(this.element,this.controllerAttribute,this),this.scopesByIdentifierByElement=new WeakMap,this.scopeReferenceCounts=new WeakMap}return t.prototype.start=function(){this.valueListObserver.start()},t.prototype.stop=function(){this.valueListObserver.stop()},Object.defineProperty(t.prototype,"controllerAttribute",{get:function(){return this.schema.controllerAttribute},enumerable:!1,configurable:!0}),t.prototype.parseValueForToken=function(e){var r=e.element,i=e.content,n=this.fetchScopesByIdentifierForElement(r),s=n.get(i);return s||(s=this.delegate.createScopeForElementAndIdentifier(r,i),n.set(i,s)),s},t.prototype.elementMatchedValue=function(e,r){var i=(this.scopeReferenceCounts.get(r)||0)+1;this.scopeReferenceCounts.set(r,i),i==1&&this.delegate.scopeConnected(r)},t.prototype.elementUnmatchedValue=function(e,r){var i=this.scopeReferenceCounts.get(r);i&&(this.scopeReferenceCounts.set(r,i-1),i==1&&this.delegate.scopeDisconnected(r))},t.prototype.fetchScopesByIdentifierForElement=function(e){var r=this.scopesByIdentifierByElement.get(e);return r||(r=new Map,this.scopesByIdentifierByElement.set(e,r)),r},t}();var Mn=function(){function t(e){this.application=e,this.scopeObserver=new Pn(this.element,this.schema,this),this.scopesByIdentifier=new Ke,this.modulesByIdentifier=new Map}return Object.defineProperty(t.prototype,"element",{get:function(){return this.application.element},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"schema",{get:function(){return this.application.schema},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"logger",{get:function(){return this.application.logger},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"controllerAttribute",{get:function(){return this.schema.controllerAttribute},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"modules",{get:function(){return Array.from(this.modulesByIdentifier.values())},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"contexts",{get:function(){return this.modules.reduce(function(e,r){return e.concat(r.contexts)},[])},enumerable:!1,configurable:!0}),t.prototype.start=function(){this.scopeObserver.start()},t.prototype.stop=function(){this.scopeObserver.stop()},t.prototype.loadDefinition=function(e){this.unloadIdentifier(e.identifier);var r=new Tn(this.application,e);this.connectModule(r)},t.prototype.unloadIdentifier=function(e){var r=this.modulesByIdentifier.get(e);r&&this.disconnectModule(r)},t.prototype.getContextForElementAndIdentifier=function(e,r){var i=this.modulesByIdentifier.get(r);if(i)return i.contexts.find(function(n){return n.element==e})},t.prototype.handleError=function(e,r,i){this.application.handleError(e,r,i)},t.prototype.createScopeForElementAndIdentifier=function(e,r){return new In(this.schema,e,r,this.logger)},t.prototype.scopeConnected=function(e){this.scopesByIdentifier.add(e.identifier,e);var r=this.modulesByIdentifier.get(e.identifier);r&&r.connectContextForScope(e)},t.prototype.scopeDisconnected=function(e){this.scopesByIdentifier.delete(e.identifier,e);var r=this.modulesByIdentifier.get(e.identifier);r&&r.disconnectContextForScope(e)},t.prototype.connectModule=function(e){this.modulesByIdentifier.set(e.identifier,e);var r=this.scopesByIdentifier.getValuesForKey(e.identifier);r.forEach(function(i){return e.connectContextForScope(i)})},t.prototype.disconnectModule=function(e){this.modulesByIdentifier.delete(e.identifier);var r=this.scopesByIdentifier.getValuesForKey(e.identifier);r.forEach(function(i){return e.disconnectContextForScope(i)})},t}();var Mr={controllerAttribute:"data-controller",actionAttribute:"data-action",targetAttribute:"data-target"};var fl=function(t,e,r,i){function n(s){return s instanceof r?s:new r(function(o){o(s)})}return new(r||(r=Promise))(function(s,o){function a(c){try{u(i.next(c))}catch(h){o(h)}}function l(c){try{u(i.throw(c))}catch(h){o(h)}}function u(c){c.done?s(c.value):n(c.value).then(a,l)}u((i=i.apply(t,e||[])).next())})},ml=function(t,e){var r={label:0,sent:function(){if(s[0]&1)throw s[1];return s[1]},trys:[],ops:[]},i,n,s,o;return o={next:a(0),throw:a(1),return:a(2)},typeof Symbol=="function"&&(o[Symbol.iterator]=function(){return this}),o;function a(u){return function(c){return l([u,c])}}function l(u){if(i)throw new TypeError("Generator is already executing.");for(;r;)try{if(i=1,n&&(s=u[0]&2?n.return:u[0]?n.throw||((s=n.return)&&s.call(n),0):n.next)&&!(s=s.call(n,u[1])).done)return s;switch(n=0,s&&(u=[u[0]&2,s.value]),u[0]){case 0:case 1:s=u;break;case 4:return r.label++,{value:u[1],done:!1};case 5:r.label++,n=u[1],u=[0];continue;case 7:u=r.ops.pop(),r.trys.pop();continue;default:if(s=r.trys,!(s=s.length>0&&s[s.length-1])&&(u[0]===6||u[0]===2)){r=0;continue}if(u[0]===3&&(!s||u[1]>s[0]&&u[1]<s[3])){r.label=u[1];break}if(u[0]===6&&r.label<s[1]){r.label=s[1],s=u;break}if(s&&r.label<s[2]){r.label=s[2],r.ops.push(u);break}s[2]&&r.ops.pop(),r.trys.pop();continue}u=e.call(t,r)}catch(c){u=[6,c],n=0}finally{i=s=0}if(u[0]&5)throw u[1];return{value:u[0]?u[1]:void 0,done:!0}}},Rn=function(){for(var t=0,e=0,r=arguments.length;e<r;e++)t+=arguments[e].length;for(var i=Array(t),n=0,e=0;e<r;e++)for(var s=arguments[e],o=0,a=s.length;o<a;o++,n++)i[n]=s[o];return i},Rr=function(){function t(e,r){e===void 0&&(e=document.documentElement),r===void 0&&(r=Mr),this.logger=console,this.element=e,this.schema=r,this.dispatcher=new on(this),this.router=new Mn(this)}return t.start=function(e,r){var i=new t(e,r);return i.start(),i},t.prototype.start=function(){return fl(this,void 0,void 0,function(){return ml(this,function(e){switch(e.label){case 0:return[4,pl()];case 1:return e.sent(),this.dispatcher.start(),this.router.start(),[2]}})})},t.prototype.stop=function(){this.dispatcher.stop(),this.router.stop()},t.prototype.register=function(e,r){this.load({identifier:e,controllerConstructor:r})},t.prototype.load=function(e){for(var r=this,i=[],n=1;n<arguments.length;n++)i[n-1]=arguments[n];var s=Array.isArray(e)?e:Rn([e],i);s.forEach(function(o){return r.router.loadDefinition(o)})},t.prototype.unload=function(e){for(var r=this,i=[],n=1;n<arguments.length;n++)i[n-1]=arguments[n];var s=Array.isArray(e)?e:Rn([e],i);s.forEach(function(o){return r.router.unloadIdentifier(o)})},Object.defineProperty(t.prototype,"controllers",{get:function(){return this.router.contexts.map(function(e){return e.controller})},enumerable:!1,configurable:!0}),t.prototype.getControllerForElementAndIdentifier=function(e,r){var i=this.router.getContextForElementAndIdentifier(e,r);return i?i.controller:null},t.prototype.handleError=function(e,r,i){this.logger.error(`%s %o -%o`,t,e,n)},r}();function Tr(){return new Promise(function(r){document.readyState=="loading"?document.addEventListener("DOMContentLoaded",r):r()})}function st(r){var e=O(r,"classes");return e.reduce(function(t,n){return Object.assign(t,Cr(n))},{})}function Cr(r){var e,t=r+"Class";return e={},e[t]={get:function(){var n=this.classes;if(n.has(r))return n.get(r);var i=n.getAttributeName(r);throw new Error('Missing attribute "'+i+'"')}},e["has"+R(t)]={get:function(){return this.classes.has(r)}},e}function ot(r){var e=O(r,"targets");return e.reduce(function(t,n){return Object.assign(t,Or(n))},{})}function Or(r){var e;return e={},e[r+"Target"]={get:function(){var t=this.targets.find(r);if(t)return t;throw new Error('Missing target element "'+this.identifier+"."+r+'"')}},e[r+"Targets"]={get:function(){return this.targets.findAll(r)}},e["has"+R(r)+"Target"]={get:function(){return this.targets.has(r)}},e}function at(r){var e=Ke(r,"values"),t={valueDescriptorMap:{get:function(){var n=this;return e.reduce(function(i,s){var o,c=ct(s),l=n.data.getAttributeNameForKey(c.key);return Object.assign(i,(o={},o[l]=c,o))},{})}}};return e.reduce(function(n,i){return Object.assign(n,Rr(i))},t)}function Rr(r){var e,t=ct(r),n=t.type,i=t.key,s=t.name,o=Fr[n],c=lt[n]||lt.default;return e={},e[s]={get:function(){var l=this.data.get(i);return l!==null?o(l):t.defaultValue},set:function(l){l===void 0?this.data.delete(i):this.data.set(i,c(l))}},e["has"+R(s)]={get:function(){return this.data.has(i)}},e}function ct(r){var e=r[0],t=r[1],n=kr(t);return Mr(e,n)}function kr(r){switch(r){case Array:return"array";case Boolean:return"boolean";case Number:return"number";case Object:return"object";case String:return"string"}throw new Error('Unknown value type constant "'+r+'"')}function Mr(r,e){var t=D(r)+"-value";return{type:e,key:t,name:Xe(t),get defaultValue(){return xr[e]}}}var xr={get array(){return[]},boolean:!1,number:0,get object(){return{}},string:""},Fr={array:function(r){var e=JSON.parse(r);if(!Array.isArray(e))throw new TypeError("Expected array");return e},boolean:function(r){return!(r=="0"||r=="false")},number:function(r){return parseFloat(r)},object:function(r){var e=JSON.parse(r);if(e===null||typeof e!="object"||Array.isArray(e))throw new TypeError("Expected object");return e},string:function(r){return r}},lt={default:Br,array:ut,object:ut};function ut(r){return JSON.stringify(r)}function Br(r){return""+r}var Ir=function(){function r(e){this.context=e}return Object.defineProperty(r.prototype,"application",{get:function(){return this.context.application},enumerable:!1,configurable:!0}),Object.defineProperty(r.prototype,"scope",{get:function(){return this.context.scope},enumerable:!1,configurable:!0}),Object.defineProperty(r.prototype,"element",{get:function(){return this.scope.element},enumerable:!1,configurable:!0}),Object.defineProperty(r.prototype,"identifier",{get:function(){return this.scope.identifier},enumerable:!1,configurable:!0}),Object.defineProperty(r.prototype,"targets",{get:function(){return this.scope.targets},enumerable:!1,configurable:!0}),Object.defineProperty(r.prototype,"classes",{get:function(){return this.scope.classes},enumerable:!1,configurable:!0}),Object.defineProperty(r.prototype,"data",{get:function(){return this.scope.data},enumerable:!1,configurable:!0}),r.prototype.initialize=function(){},r.prototype.connect=function(){},r.prototype.disconnect=function(){},r.blessings=[st,ot,at],r.targets=[],r.values={},r}();var ht=[];var Nr=Y.start();Nr.load(ht);})(); +%o`,r,e,i)},t}();function pl(){return new Promise(function(t){document.readyState=="loading"?document.addEventListener("DOMContentLoaded",t):t()})}function Dn(t){var e=Ge(t,"classes");return e.reduce(function(r,i){return Object.assign(r,gl(i))},{})}function gl(t){var e,r=t+"Class";return e={},e[r]={get:function(){var i=this.classes;if(i.has(t))return i.get(t);var n=i.getAttributeName(t);throw new Error('Missing attribute "'+n+'"')}},e["has"+Ye(r)]={get:function(){return this.classes.has(t)}},e}function xn(t){var e=Ge(t,"targets");return e.reduce(function(r,i){return Object.assign(r,vl(i))},{})}function vl(t){var e;return e={},e[t+"Target"]={get:function(){var r=this.targets.find(t);if(r)return r;throw new Error('Missing target element "'+this.identifier+"."+t+'"')}},e[t+"Targets"]={get:function(){return this.targets.findAll(t)}},e["has"+Ye(t)+"Target"]={get:function(){return this.targets.has(t)}},e}function Nn(t){var e=bn(t,"values"),r={valueDescriptorMap:{get:function(){var i=this;return e.reduce(function(n,s){var o,a=_n(s),l=i.data.getAttributeNameForKey(a.key);return Object.assign(n,(o={},o[l]=a,o))},{})}}};return e.reduce(function(i,n){return Object.assign(i,yl(n))},r)}function yl(t){var e,r=_n(t),i=r.type,n=r.key,s=r.name,o=El[i],a=Fn[i]||Fn.default;return e={},e[s]={get:function(){var l=this.data.get(n);return l!==null?o(l):r.defaultValue},set:function(l){l===void 0?this.data.delete(n):this.data.set(n,a(l))}},e["has"+Ye(s)]={get:function(){return this.data.has(n)}},e}function _n(t){var e=t[0],r=t[1],i=bl(r);return wl(e,i)}function bl(t){switch(t){case Array:return"array";case Boolean:return"boolean";case Number:return"number";case Object:return"object";case String:return"string"}throw new Error('Unknown value type constant "'+t+'"')}function wl(t,e){var r=zt(t)+"-value";return{type:e,key:r,name:An(r),get defaultValue(){return Sl[e]}}}var Sl={get array(){return[]},boolean:!1,number:0,get object(){return{}},string:""},El={array:function(t){var e=JSON.parse(t);if(!Array.isArray(e))throw new TypeError("Expected array");return e},boolean:function(t){return!(t=="0"||t=="false")},number:function(t){return parseFloat(t)},object:function(t){var e=JSON.parse(t);if(e===null||typeof e!="object"||Array.isArray(e))throw new TypeError("Expected object");return e},string:function(t){return t}},Fn={default:Tl,array:Hn,object:Hn};function Hn(t){return JSON.stringify(t)}function Tl(t){return""+t}var Dr=function(){function t(e){this.context=e}return Object.defineProperty(t.prototype,"application",{get:function(){return this.context.application},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"scope",{get:function(){return this.context.scope},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"element",{get:function(){return this.scope.element},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"identifier",{get:function(){return this.scope.identifier},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"targets",{get:function(){return this.scope.targets},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"classes",{get:function(){return this.scope.classes},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"data",{get:function(){return this.scope.data},enumerable:!1,configurable:!0}),t.prototype.initialize=function(){},t.prototype.connect=function(){},t.prototype.disconnect=function(){},t.blessings=[Dn,xn,Nn],t.targets=[],t.values={},t}();var ni=ki(ii()),or=class extends Dr{connect(){var t=Intl.DateTimeFormat().resolvedOptions().timeZone,e=Intl.DateTimeFormat().resolvedOptions().locale,r=document.body.dataset.locale||e||"en",i=document.body.dataset.tz||t||"UTC",n=ni.DateTime[this.formatValue];console.log(r,i,n),this.date=ni.DateTime.fromISO(this.element.dateTime).setZone(i).setLocale(r),this.element.innerText=this.date.toLocaleString(n)}};Ai(or,"values",{format:String});var co=[{identifier:"time",controllerConstructor:or}];var At=t=>typeof t=="function"?t:function(){return t},Lc=typeof self!="undefined"?self:null,Ot=typeof window!="undefined"?window:null,ar=Lc||Ot||void 0,Ic="2.0.0",le={connecting:0,open:1,closing:2,closed:3},Pc=1e4,Mc=1e3,q={closed:"closed",errored:"errored",joined:"joined",joining:"joining",leaving:"leaving"},V={close:"phx_close",error:"phx_error",join:"phx_join",reply:"phx_reply",leave:"phx_leave"},Rc=[V.close,V.error,V.join,V.reply,V.leave],si={longpoll:"longpoll",websocket:"websocket"},lr=class{constructor(t,e,r,i){this.channel=t,this.event=e,this.payload=r||function(){return{}},this.receivedResp=null,this.timeout=i,this.timeoutTimer=null,this.recHooks=[],this.sent=!1}resend(t){this.timeout=t,this.reset(),this.send()}send(){this.hasReceived("timeout")||(this.startTimeout(),this.sent=!0,this.channel.socket.push({topic:this.channel.topic,event:this.event,payload:this.payload(),ref:this.ref,join_ref:this.channel.joinRef()}))}receive(t,e){return this.hasReceived(t)&&e(this.receivedResp.response),this.recHooks.push({status:t,callback:e}),this}reset(){this.cancelRefEvent(),this.ref=null,this.refEvent=null,this.receivedResp=null,this.sent=!1}matchReceive({status:t,response:e,_ref:r}){this.recHooks.filter(i=>i.status===t).forEach(i=>i.callback(e))}cancelRefEvent(){!this.refEvent||this.channel.off(this.refEvent)}cancelTimeout(){clearTimeout(this.timeoutTimer),this.timeoutTimer=null}startTimeout(){this.timeoutTimer&&this.cancelTimeout(),this.ref=this.channel.socket.makeRef(),this.refEvent=this.channel.replyEventName(this.ref),this.channel.on(this.refEvent,t=>{this.cancelRefEvent(),this.cancelTimeout(),this.receivedResp=t,this.matchReceive(t)}),this.timeoutTimer=setTimeout(()=>{this.trigger("timeout",{})},this.timeout)}hasReceived(t){return this.receivedResp&&this.receivedResp.status===t}trigger(t,e){this.channel.trigger(this.refEvent,{status:t,response:e})}},ho=class{constructor(t,e){this.callback=t,this.timerCalc=e,this.timer=null,this.tries=0}reset(){this.tries=0,clearTimeout(this.timer)}scheduleTimeout(){clearTimeout(this.timer),this.timer=setTimeout(()=>{this.tries=this.tries+1,this.callback()},this.timerCalc(this.tries+1))}},Dc=class{constructor(t,e,r){this.state=q.closed,this.topic=t,this.params=At(e||{}),this.socket=r,this.bindings=[],this.bindingRef=0,this.timeout=this.socket.timeout,this.joinedOnce=!1,this.joinPush=new lr(this,V.join,this.params,this.timeout),this.pushBuffer=[],this.stateChangeRefs=[],this.rejoinTimer=new ho(()=>{this.socket.isConnected()&&this.rejoin()},this.socket.rejoinAfterMs),this.stateChangeRefs.push(this.socket.onError(()=>this.rejoinTimer.reset())),this.stateChangeRefs.push(this.socket.onOpen(()=>{this.rejoinTimer.reset(),this.isErrored()&&this.rejoin()})),this.joinPush.receive("ok",()=>{this.state=q.joined,this.rejoinTimer.reset(),this.pushBuffer.forEach(i=>i.send()),this.pushBuffer=[]}),this.joinPush.receive("error",()=>{this.state=q.errored,this.socket.isConnected()&&this.rejoinTimer.scheduleTimeout()}),this.onClose(()=>{this.rejoinTimer.reset(),this.socket.hasLogger()&&this.socket.log("channel",`close ${this.topic} ${this.joinRef()}`),this.state=q.closed,this.socket.remove(this)}),this.onError(i=>{this.socket.hasLogger()&&this.socket.log("channel",`error ${this.topic}`,i),this.isJoining()&&this.joinPush.reset(),this.state=q.errored,this.socket.isConnected()&&this.rejoinTimer.scheduleTimeout()}),this.joinPush.receive("timeout",()=>{this.socket.hasLogger()&&this.socket.log("channel",`timeout ${this.topic} (${this.joinRef()})`,this.joinPush.timeout),new lr(this,V.leave,At({}),this.timeout).send(),this.state=q.errored,this.joinPush.reset(),this.socket.isConnected()&&this.rejoinTimer.scheduleTimeout()}),this.on(V.reply,(i,n)=>{this.trigger(this.replyEventName(n),i)})}join(t=this.timeout){if(this.joinedOnce)throw new Error("tried to join multiple times. 'join' can only be called a single time per channel instance");return this.timeout=t,this.joinedOnce=!0,this.rejoin(),this.joinPush}onClose(t){this.on(V.close,t)}onError(t){return this.on(V.error,e=>t(e))}on(t,e){let r=this.bindingRef++;return this.bindings.push({event:t,ref:r,callback:e}),r}off(t,e){this.bindings=this.bindings.filter(r=>!(r.event===t&&(typeof e=="undefined"||e===r.ref)))}canPush(){return this.socket.isConnected()&&this.isJoined()}push(t,e,r=this.timeout){if(e=e||{},!this.joinedOnce)throw new Error(`tried to push '${t}' to '${this.topic}' before joining. Use channel.join() before pushing events`);let i=new lr(this,t,function(){return e},r);return this.canPush()?i.send():(i.startTimeout(),this.pushBuffer.push(i)),i}leave(t=this.timeout){this.rejoinTimer.reset(),this.joinPush.cancelTimeout(),this.state=q.leaving;let e=()=>{this.socket.hasLogger()&&this.socket.log("channel",`leave ${this.topic}`),this.trigger(V.close,"leave")},r=new lr(this,V.leave,At({}),t);return r.receive("ok",()=>e()).receive("timeout",()=>e()),r.send(),this.canPush()||r.trigger("ok",{}),r}onMessage(t,e,r){return e}isLifecycleEvent(t){return Rc.indexOf(t)>=0}isMember(t,e,r,i){return this.topic!==t?!1:i&&i!==this.joinRef()&&this.isLifecycleEvent(e)?(this.socket.hasLogger()&&this.socket.log("channel","dropping outdated message",{topic:t,event:e,payload:r,joinRef:i}),!1):!0}joinRef(){return this.joinPush.ref}rejoin(t=this.timeout){this.isLeaving()||(this.socket.leaveOpenTopic(this.topic),this.state=q.joining,this.joinPush.resend(t))}trigger(t,e,r,i){let n=this.onMessage(t,e,r,i);if(e&&!n)throw new Error("channel onMessage callbacks must return the payload, modified or unmodified");let s=this.bindings.filter(o=>o.event===t);for(let o=0;o<s.length;o++)s[o].callback(n,r,i||this.joinRef())}replyEventName(t){return`chan_reply_${t}`}isClosed(){return this.state===q.closed}isErrored(){return this.state===q.errored}isJoined(){return this.state===q.joined}isJoining(){return this.state===q.joining}isLeaving(){return this.state===q.leaving}},Ct=class{constructor(){this.states={complete:4}}static request(t,e,r,i,n,s,o){if(ar.XDomainRequest){let a=new ar.XDomainRequest;this.xdomainRequest(a,t,e,i,n,s,o)}else{let a=new ar.XMLHttpRequest;this.xhrRequest(a,t,e,r,i,n,s,o)}}static xdomainRequest(t,e,r,i,n,s,o){t.timeout=n,t.open(e,r),t.onload=()=>{let a=this.parseJSON(t.responseText);o&&o(a)},s&&(t.ontimeout=s),t.onprogress=()=>{},t.send(i)}static xhrRequest(t,e,r,i,n,s,o,a){t.open(e,r,!0),t.timeout=s,t.setRequestHeader("Content-Type",i),t.onerror=()=>{a&&a(null)},t.onreadystatechange=()=>{if(t.readyState===this.states.complete&&a){let l=this.parseJSON(t.responseText);a(l)}},o&&(t.ontimeout=o),t.send(n)}static parseJSON(t){if(!t||t==="")return null;try{return JSON.parse(t)}catch(e){return console&&console.log("failed to parse JSON response",t),null}}static serialize(t,e){let r=[];for(var i in t){if(!Object.prototype.hasOwnProperty.call(t,i))continue;let n=e?`${e}[${i}]`:i,s=t[i];typeof s=="object"?r.push(this.serialize(s,n)):r.push(encodeURIComponent(n)+"="+encodeURIComponent(s))}return r.join("&")}static appendParams(t,e){if(Object.keys(e).length===0)return t;let r=t.match(/\?/)?"&":"?";return`${t}${r}${this.serialize(e)}`}},fo=class{constructor(t){this.endPoint=null,this.token=null,this.skipHeartbeat=!0,this.onopen=function(){},this.onerror=function(){},this.onmessage=function(){},this.onclose=function(){},this.pollEndpoint=this.normalizeEndpoint(t),this.readyState=le.connecting,this.poll()}normalizeEndpoint(t){return t.replace("ws://","http://").replace("wss://","https://").replace(new RegExp("(.*)/"+si.websocket),"$1/"+si.longpoll)}endpointURL(){return Ct.appendParams(this.pollEndpoint,{token:this.token})}closeAndRetry(){this.close(),this.readyState=le.connecting}ontimeout(){this.onerror("timeout"),this.closeAndRetry()}poll(){(this.readyState===le.open||this.readyState===le.connecting)&&Ct.request("GET",this.endpointURL(),"application/json",null,this.timeout,this.ontimeout.bind(this),t=>{if(t){var{status:e,token:r,messages:i}=t;this.token=r}else e=0;switch(e){case 200:i.forEach(n=>{setTimeout(()=>{this.onmessage({data:n})},0)}),this.poll();break;case 204:this.poll();break;case 410:this.readyState=le.open,this.onopen(),this.poll();break;case 403:this.onerror(),this.close();break;case 0:case 500:this.onerror(),this.closeAndRetry();break;default:throw new Error(`unhandled poll status ${e}`)}})}send(t){Ct.request("POST",this.endpointURL(),"application/json",t,this.timeout,this.onerror.bind(this,"timeout"),e=>{(!e||e.status!==200)&&(this.onerror(e&&e.status),this.closeAndRetry())})}close(t,e){this.readyState=le.closed,this.onclose()}};var ur={HEADER_LENGTH:1,META_LENGTH:4,KINDS:{push:0,reply:1,broadcast:2},encode(t,e){if(t.payload.constructor===ArrayBuffer)return e(this.binaryEncode(t));{let r=[t.join_ref,t.ref,t.topic,t.event,t.payload];return e(JSON.stringify(r))}},decode(t,e){if(t.constructor===ArrayBuffer)return e(this.binaryDecode(t));{let[r,i,n,s,o]=JSON.parse(t);return e({join_ref:r,ref:i,topic:n,event:s,payload:o})}},binaryEncode(t){let{join_ref:e,ref:r,event:i,topic:n,payload:s}=t,o=this.META_LENGTH+e.length+r.length+n.length+i.length,a=new ArrayBuffer(this.HEADER_LENGTH+o),l=new DataView(a),u=0;l.setUint8(u++,this.KINDS.push),l.setUint8(u++,e.length),l.setUint8(u++,r.length),l.setUint8(u++,n.length),l.setUint8(u++,i.length),Array.from(e,h=>l.setUint8(u++,h.charCodeAt(0))),Array.from(r,h=>l.setUint8(u++,h.charCodeAt(0))),Array.from(n,h=>l.setUint8(u++,h.charCodeAt(0))),Array.from(i,h=>l.setUint8(u++,h.charCodeAt(0)));var c=new Uint8Array(a.byteLength+s.byteLength);return c.set(new Uint8Array(a),0),c.set(new Uint8Array(s),a.byteLength),c.buffer},binaryDecode(t){let e=new DataView(t),r=e.getUint8(0),i=new TextDecoder;switch(r){case this.KINDS.push:return this.decodePush(t,e,i);case this.KINDS.reply:return this.decodeReply(t,e,i);case this.KINDS.broadcast:return this.decodeBroadcast(t,e,i)}},decodePush(t,e,r){let i=e.getUint8(1),n=e.getUint8(2),s=e.getUint8(3),o=this.HEADER_LENGTH+this.META_LENGTH-1,a=r.decode(t.slice(o,o+i));o=o+i;let l=r.decode(t.slice(o,o+n));o=o+n;let u=r.decode(t.slice(o,o+s));o=o+s;let c=t.slice(o,t.byteLength);return{join_ref:a,ref:null,topic:l,event:u,payload:c}},decodeReply(t,e,r){let i=e.getUint8(1),n=e.getUint8(2),s=e.getUint8(3),o=e.getUint8(4),a=this.HEADER_LENGTH+this.META_LENGTH,l=r.decode(t.slice(a,a+i));a=a+i;let u=r.decode(t.slice(a,a+n));a=a+n;let c=r.decode(t.slice(a,a+s));a=a+s;let h=r.decode(t.slice(a,a+o));a=a+o;let d=t.slice(a,t.byteLength),m={status:h,response:d};return{join_ref:l,ref:u,topic:c,event:V.reply,payload:m}},decodeBroadcast(t,e,r){let i=e.getUint8(1),n=e.getUint8(2),s=this.HEADER_LENGTH+2,o=r.decode(t.slice(s,s+i));s=s+i;let a=r.decode(t.slice(s,s+n));s=s+n;let l=t.slice(s,t.byteLength);return{join_ref:null,ref:null,topic:o,event:a,payload:l}}},mo=class{constructor(t,e={}){this.stateChangeCallbacks={open:[],close:[],error:[],message:[]},this.channels=[],this.sendBuffer=[],this.ref=0,this.timeout=e.timeout||Pc,this.transport=e.transport||ar.WebSocket||fo,this.establishedConnections=0,this.defaultEncoder=ur.encode.bind(ur),this.defaultDecoder=ur.decode.bind(ur),this.closeWasClean=!1,this.binaryType=e.binaryType||"arraybuffer",this.connectClock=1,this.transport!==fo?(this.encode=e.encode||this.defaultEncoder,this.decode=e.decode||this.defaultDecoder):(this.encode=this.defaultEncoder,this.decode=this.defaultDecoder);let r=null;Ot&&Ot.addEventListener&&(Ot.addEventListener("pagehide",i=>{this.conn&&(this.disconnect(),r=this.connectClock)}),Ot.addEventListener("pageshow",i=>{r===this.connectClock&&(r=null,this.connect())})),this.heartbeatIntervalMs=e.heartbeatIntervalMs||3e4,this.rejoinAfterMs=i=>e.rejoinAfterMs?e.rejoinAfterMs(i):[1e3,2e3,5e3][i-1]||1e4,this.reconnectAfterMs=i=>e.reconnectAfterMs?e.reconnectAfterMs(i):[10,50,100,150,200,250,500,1e3,2e3][i-1]||5e3,this.logger=e.logger||null,this.longpollerTimeout=e.longpollerTimeout||2e4,this.params=At(e.params||{}),this.endPoint=`${t}/${si.websocket}`,this.vsn=e.vsn||Ic,this.heartbeatTimer=null,this.pendingHeartbeatRef=null,this.reconnectTimer=new ho(()=>{this.teardown(()=>this.connect())},this.reconnectAfterMs)}replaceTransport(t){this.disconnect(),this.transport=t}protocol(){return location.protocol.match(/^https/)?"wss":"ws"}endPointURL(){let t=Ct.appendParams(Ct.appendParams(this.endPoint,this.params()),{vsn:this.vsn});return t.charAt(0)!=="/"?t:t.charAt(1)==="/"?`${this.protocol()}:${t}`:`${this.protocol()}://${location.host}${t}`}disconnect(t,e,r){this.connectClock++,this.closeWasClean=!0,this.reconnectTimer.reset(),this.teardown(t,e,r)}connect(t){this.connectClock++,t&&(console&&console.log("passing params to connect is deprecated. Instead pass :params to the Socket constructor"),this.params=At(t)),!this.conn&&(this.closeWasClean=!1,this.conn=new this.transport(this.endPointURL()),this.conn.binaryType=this.binaryType,this.conn.timeout=this.longpollerTimeout,this.conn.onopen=()=>this.onConnOpen(),this.conn.onerror=e=>this.onConnError(e),this.conn.onmessage=e=>this.onConnMessage(e),this.conn.onclose=e=>this.onConnClose(e))}log(t,e,r){this.logger(t,e,r)}hasLogger(){return this.logger!==null}onOpen(t){let e=this.makeRef();return this.stateChangeCallbacks.open.push([e,t]),e}onClose(t){let e=this.makeRef();return this.stateChangeCallbacks.close.push([e,t]),e}onError(t){let e=this.makeRef();return this.stateChangeCallbacks.error.push([e,t]),e}onMessage(t){let e=this.makeRef();return this.stateChangeCallbacks.message.push([e,t]),e}onConnOpen(){this.hasLogger()&&this.log("transport",`connected to ${this.endPointURL()}`),this.closeWasClean=!1,this.establishedConnections++,this.flushSendBuffer(),this.reconnectTimer.reset(),this.resetHeartbeat(),this.stateChangeCallbacks.open.forEach(([,t])=>t())}heartbeatTimeout(){this.pendingHeartbeatRef&&(this.pendingHeartbeatRef=null,this.hasLogger()&&this.log("transport","heartbeat timeout. Attempting to re-establish connection"),this.abnormalClose("heartbeat timeout"))}resetHeartbeat(){this.conn&&this.conn.skipHeartbeat||(this.pendingHeartbeatRef=null,clearTimeout(this.heartbeatTimer),setTimeout(()=>this.sendHeartbeat(),this.heartbeatIntervalMs))}teardown(t,e,r){if(!this.conn)return t&&t();this.waitForBufferDone(()=>{this.conn&&(e?this.conn.close(e,r||""):this.conn.close()),this.waitForSocketClosed(()=>{this.conn&&(this.conn.onclose=function(){},this.conn=null),t&&t()})})}waitForBufferDone(t,e=1){if(e===5||!this.conn||!this.conn.bufferedAmount){t();return}setTimeout(()=>{this.waitForBufferDone(t,e+1)},150*e)}waitForSocketClosed(t,e=1){if(e===5||!this.conn||this.conn.readyState===le.closed){t();return}setTimeout(()=>{this.waitForSocketClosed(t,e+1)},150*e)}onConnClose(t){this.hasLogger()&&this.log("transport","close",t),this.triggerChanError(),clearTimeout(this.heartbeatTimer),this.closeWasClean||this.reconnectTimer.scheduleTimeout(),this.stateChangeCallbacks.close.forEach(([,e])=>e(t))}onConnError(t){this.hasLogger()&&this.log("transport",t);let e=this.transport,r=this.establishedConnections;this.stateChangeCallbacks.error.forEach(([,i])=>{i(t,e,r)}),(e===this.transport||r>0)&&this.triggerChanError()}triggerChanError(){this.channels.forEach(t=>{t.isErrored()||t.isLeaving()||t.isClosed()||t.trigger(V.error)})}connectionState(){switch(this.conn&&this.conn.readyState){case le.connecting:return"connecting";case le.open:return"open";case le.closing:return"closing";default:return"closed"}}isConnected(){return this.connectionState()==="open"}remove(t){this.off(t.stateChangeRefs),this.channels=this.channels.filter(e=>e.joinRef()!==t.joinRef())}off(t){for(let e in this.stateChangeCallbacks)this.stateChangeCallbacks[e]=this.stateChangeCallbacks[e].filter(([r])=>t.indexOf(r)===-1)}channel(t,e={}){let r=new Dc(t,e,this);return this.channels.push(r),r}push(t){if(this.hasLogger()){let{topic:e,event:r,payload:i,ref:n,join_ref:s}=t;this.log("push",`${e} ${r} (${s}, ${n})`,i)}this.isConnected()?this.encode(t,e=>this.conn.send(e)):this.sendBuffer.push(()=>this.encode(t,e=>this.conn.send(e)))}makeRef(){let t=this.ref+1;return t===this.ref?this.ref=0:this.ref=t,this.ref.toString()}sendHeartbeat(){this.pendingHeartbeatRef&&!this.isConnected()||(this.pendingHeartbeatRef=this.makeRef(),this.push({topic:"phoenix",event:"heartbeat",payload:{},ref:this.pendingHeartbeatRef}),this.heartbeatTimer=setTimeout(()=>this.heartbeatTimeout(),this.heartbeatIntervalMs))}abnormalClose(t){this.closeWasClean=!1,this.isConnected()&&this.conn.close(Mc,t)}flushSendBuffer(){this.isConnected()&&this.sendBuffer.length>0&&(this.sendBuffer.forEach(t=>t()),this.sendBuffer=[])}onConnMessage(t){this.decode(t.data,e=>{let{topic:r,event:i,payload:n,ref:s,join_ref:o}=e;s&&s===this.pendingHeartbeatRef&&(clearTimeout(this.heartbeatTimer),this.pendingHeartbeatRef=null,setTimeout(()=>this.sendHeartbeat(),this.heartbeatIntervalMs)),this.hasLogger()&&this.log("receive",`${n.status||""} ${r} ${i} ${s&&"("+s+")"||""}`,n);for(let a=0;a<this.channels.length;a++){let l=this.channels[a];!l.isMember(r,i,n,o)||l.trigger(i,n,s,o)}for(let a=0;a<this.stateChangeCallbacks.message.length;a++){let[,l]=this.stateChangeCallbacks.message[a];l(e)}})}leaveOpenTopic(t){let e=this.channels.find(r=>r.topic===t&&(r.isJoined()||r.isJoining()));e&&(this.hasLogger()&&this.log("transport",`leaving duplicate topic "${t}"`),e.leave())}};var po="consecutive-reloads",go=10,xc=[1e3,3e3],Nc=3e4,vo=["phx-click-loading","phx-change-loading","phx-submit-loading","phx-keydown-loading","phx-keyup-loading","phx-blur-loading","phx-focus-loading"],G="data-phx-component",oi="data-phx-link",_c="track-static",Fc="data-phx-link-state",ue="data-phx-ref",yo="track-uploads",je="data-phx-upload-ref",ai="data-phx-preflighted-refs",Hc="data-phx-done-refs",bo="drop-target",li="data-phx-active-refs",ui="phx:live-file:updated",ci="data-phx-skip",wo="data-phx-remove",So="page-loading",Eo="phx-connected",cr="phx-disconnected",To="phx-no-feedback",ko="phx-error",Lt="data-phx-parent-id",Ao="data-phx-main",hr="data-phx-root-id",Vc="trigger-action",Oo="feedback-for",Co="phx-has-focused",Bc=["text","textarea","number","email","password","search","tel","url","date","time"],Lo=["checkbox","radio"],Io="phx-has-submitted",Pe="data-phx-session",lt=`[${Pe}]`,It="data-phx-static",hi="data-phx-readonly",dr="data-phx-disabled",di="disable-with",fr="data-phx-disable-with-restore",mr="hook",jc="debounce",Uc="throttle",fi="update",qc="key",ce="phxPrivate",Po="auto-recover",mi="phx:live-socket:debug",pi="phx:live-socket:profiling",gi="phx:live-socket:latency-sim",$c="progress",Wc=1,zc=200,Zc="phx-",Jc=3e4,Pt="debounce-trigger",pr="throttled",Mo="debounce-prev-key",Kc={debounce:300,throttle:300},Ro="d",he="s",$="c",Do="e",xo="r",No="t",Gc=class{constructor(t,e,r){this.liveSocket=r,this.entry=t,this.offset=0,this.chunkSize=e,this.chunkTimer=null,this.uploadChannel=r.channel(`lvu:${t.ref}`,{token:t.metadata()})}error(t){clearTimeout(this.chunkTimer),this.uploadChannel.leave(),this.entry.error(t)}upload(){this.uploadChannel.onError(t=>this.error(t)),this.uploadChannel.join().receive("ok",t=>this.readNextChunk()).receive("error",t=>this.error(t))}isDone(){return this.offset>=this.entry.file.size}readNextChunk(){let t=new window.FileReader,e=this.entry.file.slice(this.offset,this.chunkSize+this.offset);t.onload=r=>{if(r.target.error===null)this.offset+=r.target.result.byteLength,this.pushChunk(r.target.result);else return R("Read error: "+r.target.error)},t.readAsArrayBuffer(e)}pushChunk(t){!this.uploadChannel.isJoined()||this.uploadChannel.push("chunk",t).receive("ok",()=>{this.entry.progress(this.offset/this.entry.file.size*100),this.isDone()||(this.chunkTimer=setTimeout(()=>this.readNextChunk(),this.liveSocket.getLatencySim()||0))})}},R=(t,e)=>console.error&&console.error(t,e);function Yc(){let t=new Set,e=document.querySelectorAll("*[id]");for(let r=0,i=e.length;r<i;r++)t.has(e[r].id)?console.error(`Multiple IDs detected: ${e[r].id}. Ensure unique element ids.`):t.add(e[r].id)}var Xc=(t,e,r,i)=>{t.liveSocket.isDebugEnabled()&&console.log(`${t.id} ${e}: ${r} - `,i)},vi=t=>typeof t=="function"?t:function(){return t},Mt=t=>JSON.parse(JSON.stringify(t)),Rt=(t,e,r)=>{do{if(t.matches(`[${e}]`))return t;t=t.parentElement||t.parentNode}while(t!==null&&t.nodeType===1&&!(r&&r.isSameNode(t)||t.matches(lt)));return null},Dt=t=>t!==null&&typeof t=="object"&&!(t instanceof Array),Qc=(t,e)=>JSON.stringify(t)===JSON.stringify(e),_o=t=>{for(let e in t)return!1;return!0},ye=(t,e)=>t&&e(t),eh=function(t,e,r,i){t.forEach(n=>{new Gc(n,r.config.chunk_size,i).upload()})},Fo={canPushState(){return typeof history.pushState!="undefined"},dropLocal(t,e,r){return t.removeItem(this.localKey(e,r))},updateLocal(t,e,r,i,n){let s=this.getLocal(t,e,r),o=this.localKey(e,r),a=s===null?i:n(s);return t.setItem(o,JSON.stringify(a)),a},getLocal(t,e,r){return JSON.parse(t.getItem(this.localKey(e,r)))},updateCurrentState(t){!this.canPushState()||history.replaceState(t(history.state||{}),"",window.location.href)},pushState(t,e,r){if(this.canPushState()){if(r!==window.location.href){if(e.type=="redirect"&&e.scroll){let n=history.state||{};n.scroll=e.scroll,history.replaceState(n,"",window.location.href)}delete e.scroll,history[t+"State"](e,"",r||null);let i=this.getHashTargetEl(window.location.hash);i?i.scrollIntoView():e.type==="redirect"&&window.scroll(0,0)}}else this.redirect(r)},setCookie(t,e){document.cookie=`${t}=${e}`},getCookie(t){return document.cookie.replace(new RegExp(`(?:(?:^|.*;s*)${t}s*=s*([^;]*).*$)|^.*$`),"$1")},redirect(t,e){e&&Fo.setCookie("__phoenix_flash__",e+"; max-age=60000; path=/"),window.location=t},localKey(t,e){return`${t}-${e}`},getHashTargetEl(t){let e=t.toString().substring(1);if(e!=="")return document.getElementById(e)||document.querySelector(`a[name="${e}"]`)}},Me=Fo,be={byId(t){return document.getElementById(t)||R(`no id found for ${t}`)},removeClass(t,e){t.classList.remove(e),t.classList.length===0&&t.removeAttribute("class")},all(t,e,r){if(!t)return[];let i=Array.from(t.querySelectorAll(e));return r?i.forEach(r):i},childNodeLength(t){let e=document.createElement("template");return e.innerHTML=t,e.content.childElementCount},isUploadInput(t){return t.type==="file"&&t.getAttribute(je)!==null},findUploadInputs(t){return this.all(t,`input[type="file"][${je}]`)},findComponentNodeList(t,e){return this.filterWithinSameLiveView(this.all(t,`[${G}="${e}"]`),t)},isPhxDestroyed(t){return!!(t.id&&be.private(t,"destroyed"))},markPhxChildDestroyed(t){t.setAttribute(Pe,""),this.putPrivate(t,"destroyed",!0)},findPhxChildrenInFragment(t,e){let r=document.createElement("template");return r.innerHTML=t,this.findPhxChildren(r.content,e)},isIgnored(t,e){return(t.getAttribute(e)||t.getAttribute("data-phx-update"))==="ignore"},isPhxUpdate(t,e,r){return t.getAttribute&&r.indexOf(t.getAttribute(e))>=0},findPhxChildren(t,e){return this.all(t,`${lt}[${Lt}="${e}"]`)},findParentCIDs(t,e){let r=new Set(e);return e.reduce((i,n)=>{let s=`[${G}="${n}"] [${G}]`;return this.filterWithinSameLiveView(this.all(t,s),t).map(o=>parseInt(o.getAttribute(G))).forEach(o=>i.delete(o)),i},r)},filterWithinSameLiveView(t,e){return e.querySelector(lt)?t.filter(r=>this.withinSameLiveView(r,e)):t},withinSameLiveView(t,e){for(;t=t.parentNode;){if(t.isSameNode(e))return!0;if(t.getAttribute(Pe)!==null)return!1}},private(t,e){return t[ce]&&t[ce][e]},deletePrivate(t,e){t[ce]&&delete t[ce][e]},putPrivate(t,e,r){t[ce]||(t[ce]={}),t[ce][e]=r},copyPrivates(t,e){e[ce]&&(t[ce]=Mt(e[ce]))},putTitle(t){let e=document.querySelector("title"),{prefix:r,suffix:i}=e.dataset;document.title=`${r||""}${t}${i||""}`},debounce(t,e,r,i,n,s,o){let a=t.getAttribute(r),l=t.getAttribute(n);a===""&&(a=i),l===""&&(l=s);let u=a||l;switch(u){case null:return o();case"blur":this.once(t,"debounce-blur")&&t.addEventListener("blur",()=>o());return;default:let c=parseInt(u),h=()=>l?this.deletePrivate(t,pr):o(),d=this.incCycle(t,Pt,h);if(isNaN(c))return R(`invalid throttle/debounce value: ${u}`);if(l){let p=!1;if(e.type==="keydown"){let y=this.private(t,Mo);this.putPrivate(t,Mo,e.key),p=y!==e.key}if(!p&&this.private(t,pr))return!1;o(),this.putPrivate(t,pr,!0),setTimeout(()=>this.triggerCycle(t,Pt),c)}else setTimeout(()=>this.triggerCycle(t,Pt,d),c);let m=t.form;m&&this.once(m,"bind-debounce")&&m.addEventListener("submit",()=>{Array.from(new FormData(m).entries(),([p])=>{let y=m.querySelector(`[name="${p}"]`);this.incCycle(y,Pt),this.deletePrivate(y,pr)})}),this.once(t,"bind-debounce")&&t.addEventListener("blur",()=>this.triggerCycle(t,Pt))}},triggerCycle(t,e,r){let[i,n]=this.private(t,e);r||(r=i),r===i&&(this.incCycle(t,e),n())},once(t,e){return this.private(t,e)===!0?!1:(this.putPrivate(t,e,!0),!0)},incCycle(t,e,r=function(){}){let[i]=this.private(t,e)||[0,r];return i++,this.putPrivate(t,e,[i,r]),i},discardError(t,e,r){let i=e.getAttribute&&e.getAttribute(r),n=i&&t.querySelector(`[id="${i}"], [name="${i}"]`);!n||this.private(n,Co)||this.private(n.form,Io)||e.classList.add(To)},showError(t,e){(t.id||t.name)&&this.all(t.form,`[${e}="${t.id}"], [${e}="${t.name}"]`,r=>{this.removeClass(r,To)})},isPhxChild(t){return t.getAttribute&&t.getAttribute(Lt)},dispatchEvent(t,e,r={}){let i=new CustomEvent(e,{bubbles:!0,cancelable:!0,detail:r});t.dispatchEvent(i)},cloneNode(t,e){if(typeof e=="undefined")return t.cloneNode(!0);{let r=t.cloneNode(!1);return r.innerHTML=e,r}},mergeAttrs(t,e,r={}){let i=r.exclude||[],n=r.isIgnored,s=e.attributes;for(let a=s.length-1;a>=0;a--){let l=s[a].name;i.indexOf(l)<0&&t.setAttribute(l,e.getAttribute(l))}let o=t.attributes;for(let a=o.length-1;a>=0;a--){let l=o[a].name;n?l.startsWith("data-")&&!e.hasAttribute(l)&&t.removeAttribute(l):e.hasAttribute(l)||t.removeAttribute(l)}},mergeFocusedInput(t,e){t instanceof HTMLSelectElement||be.mergeAttrs(t,e,{except:["value"]}),e.readOnly?t.setAttribute("readonly",!0):t.removeAttribute("readonly")},hasSelectionRange(t){return t.setSelectionRange&&(t.type==="text"||t.type==="textarea")},restoreFocus(t,e,r){if(!be.isTextualInput(t))return;let i=t.matches(":focus");t.readOnly&&t.blur(),i||t.focus(),this.hasSelectionRange(t)&&t.setSelectionRange(e,r)},isFormInput(t){return/^(?:input|select|textarea)$/i.test(t.tagName)&&t.type!=="button"},syncAttrsToProps(t){t instanceof HTMLInputElement&&Lo.indexOf(t.type.toLocaleLowerCase())>=0&&(t.checked=t.getAttribute("checked")!==null)},syncPropsToAttrs(t){if(t instanceof HTMLSelectElement){let e=t.options.item(t.selectedIndex);e&&e.getAttribute("selected")===null&&e.setAttribute("selected","")}},isTextualInput(t){return Bc.indexOf(t.type)>=0},isNowTriggerFormExternal(t,e){return t.getAttribute&&t.getAttribute(e)!==null},syncPendingRef(t,e,r){let i=t.getAttribute(ue);return i===null?!0:be.isFormInput(t)||t.getAttribute(r)!==null?(be.isUploadInput(t)&&be.mergeAttrs(t,e,{isIgnored:!0}),be.putPrivate(t,ue,e),!1):(vo.forEach(n=>{t.classList.contains(n)&&e.classList.add(n)}),e.setAttribute(ue,i),!0)},cleanChildNodes(t,e){if(be.isPhxUpdate(t,e,["append","prepend"])){let r=[];t.childNodes.forEach(i=>{i.id||(i.nodeType===Node.TEXT_NODE&&i.nodeValue.trim()===""||R(`only HTML element tags with an id are allowed inside containers with phx-update. + +removing illegal node: "${(i.outerHTML||i.nodeValue).trim()}" + +`),r.push(i))}),r.forEach(i=>i.remove())}},replaceRootContainer(t,e,r){let i=new Set(["id",Pe,It,Ao]);if(t.tagName.toLowerCase()===e.toLowerCase())return Array.from(t.attributes).filter(n=>!i.has(n.name.toLowerCase())).forEach(n=>t.removeAttribute(n.name)),Object.keys(r).filter(n=>!i.has(n.toLowerCase())).forEach(n=>t.setAttribute(n,r[n])),t;{let n=document.createElement(e);return Object.keys(r).forEach(s=>n.setAttribute(s,r[s])),i.forEach(s=>n.setAttribute(s,t.getAttribute(s))),n.innerHTML=t.innerHTML,t.replaceWith(n),n}}},g=be,yi=class{static isActive(t,e){let r=e._phxRef===void 0,n=t.getAttribute(li).split(",").indexOf(D.genFileRef(e))>=0;return e.size>0&&(r||n)}static isPreflighted(t,e){return t.getAttribute(ai).split(",").indexOf(D.genFileRef(e))>=0&&this.isActive(t,e)}constructor(t,e,r){this.ref=D.genFileRef(e),this.fileEl=t,this.file=e,this.view=r,this.meta=null,this._isCancelled=!1,this._isDone=!1,this._progress=0,this._lastProgressSent=-1,this._onDone=function(){},this._onElUpdated=this.onElUpdated.bind(this),this.fileEl.addEventListener(ui,this._onElUpdated)}metadata(){return this.meta}progress(t){this._progress=Math.floor(t),this._progress>this._lastProgressSent&&(this._progress>=100?(this._progress=100,this._lastProgressSent=100,this._isDone=!0,this.view.pushFileProgress(this.fileEl,this.ref,100,()=>{D.untrackFile(this.fileEl,this.file),this._onDone()})):(this._lastProgressSent=this._progress,this.view.pushFileProgress(this.fileEl,this.ref,this._progress)))}cancel(){this._isCancelled=!0,this._isDone=!0,this._onDone()}isDone(){return this._isDone}error(t="failed"){this.view.pushFileProgress(this.fileEl,this.ref,{error:t}),D.clearFiles(this.fileEl)}onDone(t){this._onDone=()=>{this.fileEl.removeEventListener(ui,this._onElUpdated),t()}}onElUpdated(){this.fileEl.getAttribute(li).split(",").indexOf(this.ref)===-1&&this.cancel()}toPreflightPayload(){return{last_modified:this.file.lastModified,name:this.file.name,size:this.file.size,type:this.file.type,ref:this.ref}}uploader(t){if(this.meta.uploader){let e=t[this.meta.uploader]||R(`no uploader configured for ${this.meta.uploader}`);return{name:this.meta.uploader,callback:e}}else return{name:"channel",callback:eh}}zipPostFlight(t){this.meta=t.entries[this.ref],this.meta||R(`no preflight upload response returned with ref ${this.ref}`,{input:this.fileEl,response:t})}},th=0,D=class{static genFileRef(t){let e=t._phxRef;return e!==void 0?e:(t._phxRef=(th++).toString(),t._phxRef)}static getEntryDataURL(t,e,r){let i=this.activeFiles(t).find(n=>this.genFileRef(n)===e);r(URL.createObjectURL(i))}static hasUploadsInProgress(t){let e=0;return g.findUploadInputs(t).forEach(r=>{r.getAttribute(ai)!==r.getAttribute(Hc)&&e++}),e>0}static serializeUploads(t){let e=this.activeFiles(t),r={};return e.forEach(i=>{let n={path:t.name},s=t.getAttribute(je);r[s]=r[s]||[],n.ref=this.genFileRef(i),n.name=i.name||n.ref,n.type=i.type,n.size=i.size,r[s].push(n)}),r}static clearFiles(t){t.value=null,t.removeAttribute(je),g.putPrivate(t,"files",[])}static untrackFile(t,e){g.putPrivate(t,"files",g.private(t,"files").filter(r=>!Object.is(r,e)))}static trackFiles(t,e){if(t.getAttribute("multiple")!==null){let r=e.filter(i=>!this.activeFiles(t).find(n=>Object.is(n,i)));g.putPrivate(t,"files",this.activeFiles(t).concat(r)),t.value=null}else g.putPrivate(t,"files",e)}static activeFileInputs(t){let e=g.findUploadInputs(t);return Array.from(e).filter(r=>r.files&&this.activeFiles(r).length>0)}static activeFiles(t){return(g.private(t,"files")||[]).filter(e=>yi.isActive(t,e))}static inputsAwaitingPreflight(t){let e=g.findUploadInputs(t);return Array.from(e).filter(r=>this.filesAwaitingPreflight(r).length>0)}static filesAwaitingPreflight(t){return this.activeFiles(t).filter(e=>!yi.isPreflighted(t,e))}constructor(t,e,r){this.view=e,this.onComplete=r,this._entries=Array.from(D.filesAwaitingPreflight(t)||[]).map(i=>new yi(t,i,e)),this.numEntriesInProgress=this._entries.length}entries(){return this._entries}initAdapterUpload(t,e,r){this._entries=this._entries.map(n=>(n.zipPostFlight(t),n.onDone(()=>{this.numEntriesInProgress--,this.numEntriesInProgress===0&&this.onComplete()}),n));let i=this._entries.reduce((n,s)=>{let{name:o,callback:a}=s.uploader(r.uploaders);return n[o]=n[o]||{callback:a,entries:[]},n[o].entries.push(s),n},{});for(let n in i){let{callback:s,entries:o}=i[n];s(o,e,t,r)}}},rh={LiveFileUpload:{activeRefs(){return this.el.getAttribute(li)},preflightedRefs(){return this.el.getAttribute(ai)},mounted(){this.preflightedWas=this.preflightedRefs()},updated(){let t=this.preflightedRefs();this.preflightedWas!==t&&(this.preflightedWas=t,t===""&&this.__view.cancelSubmit(this.el.form)),this.activeRefs()===""&&(this.el.value=null),this.el.dispatchEvent(new CustomEvent(ui))}},LiveImgPreview:{mounted(){this.ref=this.el.getAttribute("data-phx-entry-ref"),this.inputEl=document.getElementById(this.el.getAttribute(je)),D.getEntryDataURL(this.inputEl,this.ref,t=>{this.url=t,this.el.src=t})},destroyed(){URL.revokeObjectURL(this.url)}}},ih=rh,nh=class{constructor(t,e,r){let i=new Set,n=new Set([...e.children].map(o=>o.id)),s=[];Array.from(t.children).forEach(o=>{if(o.id&&(i.add(o.id),n.has(o.id))){let a=o.previousElementSibling&&o.previousElementSibling.id;s.push({elementId:o.id,previousElementId:a})}}),this.containerId=e.id,this.updateType=r,this.elementsToModify=s,this.elementIdsToAdd=[...n].filter(o=>!i.has(o))}perform(){let t=g.byId(this.containerId);this.elementsToModify.forEach(e=>{e.previousElementId?ye(document.getElementById(e.previousElementId),r=>{ye(document.getElementById(e.elementId),i=>{i.previousElementSibling&&i.previousElementSibling.id==r.id||r.insertAdjacentElement("afterend",i)})}):ye(document.getElementById(e.elementId),r=>{r.previousElementSibling==null||t.insertAdjacentElement("afterbegin",r)})}),this.updateType=="prepend"&&this.elementIdsToAdd.reverse().forEach(e=>{ye(document.getElementById(e),r=>t.insertAdjacentElement("afterbegin",r))})}},Ho=11;function sh(t,e){var r=e.attributes,i,n,s,o,a;if(!(e.nodeType===Ho||t.nodeType===Ho)){for(var l=r.length-1;l>=0;l--)i=r[l],n=i.name,s=i.namespaceURI,o=i.value,s?(n=i.localName||n,a=t.getAttributeNS(s,n),a!==o&&(i.prefix==="xmlns"&&(n=i.name),t.setAttributeNS(s,n,o))):(a=t.getAttribute(n),a!==o&&t.setAttribute(n,o));for(var u=t.attributes,c=u.length-1;c>=0;c--)i=u[c],n=i.name,s=i.namespaceURI,s?(n=i.localName||n,e.hasAttributeNS(s,n)||t.removeAttributeNS(s,n)):e.hasAttribute(n)||t.removeAttribute(n)}}var gr,oh="http://www.w3.org/1999/xhtml",B=typeof document=="undefined"?void 0:document,ah=!!B&&"content"in B.createElement("template"),lh=!!B&&B.createRange&&"createContextualFragment"in B.createRange();function uh(t){var e=B.createElement("template");return e.innerHTML=t,e.content.childNodes[0]}function ch(t){gr||(gr=B.createRange(),gr.selectNode(B.body));var e=gr.createContextualFragment(t);return e.childNodes[0]}function hh(t){var e=B.createElement("body");return e.innerHTML=t,e.childNodes[0]}function dh(t){return t=t.trim(),ah?uh(t):lh?ch(t):hh(t)}function vr(t,e){var r=t.nodeName,i=e.nodeName,n,s;return r===i?!0:(n=r.charCodeAt(0),s=i.charCodeAt(0),n<=90&&s>=97?r===i.toUpperCase():s<=90&&n>=97?i===r.toUpperCase():!1)}function fh(t,e){return!e||e===oh?B.createElement(t):B.createElementNS(e,t)}function mh(t,e){for(var r=t.firstChild;r;){var i=r.nextSibling;e.appendChild(r),r=i}return e}function bi(t,e,r){t[r]!==e[r]&&(t[r]=e[r],t[r]?t.setAttribute(r,""):t.removeAttribute(r))}var Vo={OPTION:function(t,e){var r=t.parentNode;if(r){var i=r.nodeName.toUpperCase();i==="OPTGROUP"&&(r=r.parentNode,i=r&&r.nodeName.toUpperCase()),i==="SELECT"&&!r.hasAttribute("multiple")&&(t.hasAttribute("selected")&&!e.selected&&(t.setAttribute("selected","selected"),t.removeAttribute("selected")),r.selectedIndex=-1)}bi(t,e,"selected")},INPUT:function(t,e){bi(t,e,"checked"),bi(t,e,"disabled"),t.value!==e.value&&(t.value=e.value),e.hasAttribute("value")||t.removeAttribute("value")},TEXTAREA:function(t,e){var r=e.value;t.value!==r&&(t.value=r);var i=t.firstChild;if(i){var n=i.nodeValue;if(n==r||!r&&n==t.placeholder)return;i.nodeValue=r}},SELECT:function(t,e){if(!e.hasAttribute("multiple")){for(var r=-1,i=0,n=t.firstChild,s,o;n;)if(o=n.nodeName&&n.nodeName.toUpperCase(),o==="OPTGROUP")s=n,n=s.firstChild;else{if(o==="OPTION"){if(n.hasAttribute("selected")){r=i;break}i++}n=n.nextSibling,!n&&s&&(n=s.nextSibling,s=null)}t.selectedIndex=r}}},xt=1,ph=11,Bo=3,jo=8;function Ue(){}function gh(t){if(t)return t.getAttribute&&t.getAttribute("id")||t.id}function vh(t){return function(r,i,n){if(n||(n={}),typeof i=="string")if(r.nodeName==="#document"||r.nodeName==="HTML"||r.nodeName==="BODY"){var s=i;i=B.createElement("html"),i.innerHTML=s}else i=dh(i);var o=n.getNodeKey||gh,a=n.onBeforeNodeAdded||Ue,l=n.onNodeAdded||Ue,u=n.onBeforeElUpdated||Ue,c=n.onElUpdated||Ue,h=n.onBeforeNodeDiscarded||Ue,d=n.onNodeDiscarded||Ue,m=n.onBeforeElChildrenUpdated||Ue,p=n.childrenOnly===!0,y=Object.create(null),b=[];function f(T){b.push(T)}function S(T,E){if(T.nodeType===xt)for(var w=T.firstChild;w;){var C=void 0;E&&(C=o(w))?f(C):(d(w),w.firstChild&&S(w,E)),w=w.nextSibling}}function ie(T,E,w){h(T)!==!1&&(E&&E.removeChild(T),d(T),S(T,w))}function de(T){if(T.nodeType===xt||T.nodeType===ph)for(var E=T.firstChild;E;){var w=o(E);w&&(y[w]=E),de(E),E=E.nextSibling}}de(r);function qe(T){l(T);for(var E=T.firstChild;E;){var w=E.nextSibling,C=o(E);if(C){var Y=y[C];Y&&vr(E,Y)?(E.parentNode.replaceChild(Y,E),$e(Y,E)):qe(E)}else qe(E);E=w}}function Re(T,E,w){for(;E;){var C=E.nextSibling;(w=o(E))?f(w):ie(E,T,!0),E=C}}function $e(T,E,w){var C=o(E);C&&delete y[C],!(!w&&(u(T,E)===!1||(t(T,E),c(T),m(T,E)===!1)))&&(T.nodeName!=="TEXTAREA"?br(T,E):Vo.TEXTAREA(T,E))}function br(T,E){var w=E.firstChild,C=T.firstChild,Y,we,ze,_t,Se;e:for(;w;){for(_t=w.nextSibling,Y=o(w);C;){if(ze=C.nextSibling,w.isSameNode&&w.isSameNode(C)){w=_t,C=ze;continue e}we=o(C);var Ft=C.nodeType,Ee=void 0;if(Ft===w.nodeType&&(Ft===xt?(Y?Y!==we&&((Se=y[Y])?ze===Se?Ee=!1:(T.insertBefore(Se,C),we?f(we):ie(C,T,!0),C=Se):Ee=!1):we&&(Ee=!1),Ee=Ee!==!1&&vr(C,w),Ee&&$e(C,w)):(Ft===Bo||Ft==jo)&&(Ee=!0,C.nodeValue!==w.nodeValue&&(C.nodeValue=w.nodeValue))),Ee){w=_t,C=ze;continue e}we?f(we):ie(C,T,!0),C=ze}if(Y&&(Se=y[Y])&&vr(Se,w))T.appendChild(Se),$e(Se,w);else{var Sr=a(w);Sr!==!1&&(Sr&&(w=Sr),w.actualize&&(w=w.actualize(T.ownerDocument||B)),T.appendChild(w),qe(w))}w=_t,C=ze}Re(T,C,we);var Ti=Vo[T.nodeName];Ti&&Ti(T,E)}var P=r,We=P.nodeType,ut=i.nodeType;if(!p){if(We===xt)ut===xt?vr(r,i)||(d(r),P=mh(r,fh(i.nodeName,i.namespaceURI))):P=i;else if(We===Bo||We===jo){if(ut===We)return P.nodeValue!==i.nodeValue&&(P.nodeValue=i.nodeValue),P;P=i}}if(P===i)d(r);else{if(i.isSameNode&&i.isSameNode(P))return;if($e(P,i,p),b)for(var ct=0,wr=b.length;ct<wr;ct++){var De=y[b[ct]];De&&ie(De,De.parentNode,!1)}}return!p&&P!==r&&r.parentNode&&(P.actualize&&(P=P.actualize(r.ownerDocument||B)),r.parentNode.replaceChild(P,r)),P}}var yh=vh(sh),Uo=yh,yr=class{static patchEl(t,e,r){Uo(t,e,{childrenOnly:!1,onBeforeElUpdated:(i,n)=>{if(r&&r.isSameNode(i)&&g.isFormInput(i))return g.mergeFocusedInput(i,n),!1}})}constructor(t,e,r,i,n){this.view=t,this.liveSocket=t.liveSocket,this.container=e,this.id=r,this.rootID=t.root.id,this.html=i,this.targetCID=n,this.cidPatch=typeof this.targetCID=="number",this.callbacks={beforeadded:[],beforeupdated:[],beforephxChildAdded:[],afteradded:[],afterupdated:[],afterdiscarded:[],afterphxChildAdded:[]}}before(t,e){this.callbacks[`before${t}`].push(e)}after(t,e){this.callbacks[`after${t}`].push(e)}trackBefore(t,...e){this.callbacks[`before${t}`].forEach(r=>r(...e))}trackAfter(t,...e){this.callbacks[`after${t}`].forEach(r=>r(...e))}markPrunableContentForRemoval(){g.all(this.container,"[phx-update=append] > *, [phx-update=prepend] > *",t=>{t.setAttribute(wo,"")})}perform(){let{view:t,liveSocket:e,container:r,html:i}=this,n=this.isCIDPatch()?this.targetCIDContainer(i):r;if(this.isCIDPatch()&&!n)return;let s=e.getActiveElement(),{selectionStart:o,selectionEnd:a}=s&&g.hasSelectionRange(s)?s:{},l=e.binding(fi),u=e.binding(Oo),c=e.binding(di),h=e.binding(Vc),d=[],m=[],p=[],y=null,b=e.time("premorph container prep",()=>this.buildDiffHTML(r,i,l,n));return this.trackBefore("added",r),this.trackBefore("updated",r,r),e.time("morphdom",()=>{Uo(n,b,{childrenOnly:n.getAttribute(G)===null,getNodeKey:f=>g.isPhxDestroyed(f)?null:f.id,onBeforeNodeAdded:f=>(this.trackBefore("added",f),f),onNodeAdded:f=>{g.isNowTriggerFormExternal(f,h)&&(y=f),g.discardError(n,f,u),g.isPhxChild(f)&&t.ownsElement(f)&&this.trackAfter("phxChildAdded",f),d.push(f)},onNodeDiscarded:f=>{g.isPhxChild(f)&&e.destroyViewByEl(f),this.trackAfter("discarded",f)},onBeforeNodeDiscarded:f=>f.getAttribute&&f.getAttribute(wo)!==null?!0:!(f.parentNode!==null&&g.isPhxUpdate(f.parentNode,l,["append","prepend"])&&f.id||this.skipCIDSibling(f)),onElUpdated:f=>{g.isNowTriggerFormExternal(f,h)&&(y=f),m.push(f)},onBeforeElUpdated:(f,S)=>{if(g.cleanChildNodes(S,l),this.skipCIDSibling(S))return!1;if(g.isIgnored(f,l))return this.trackBefore("updated",f,S),g.mergeAttrs(f,S,{isIgnored:!0}),m.push(f),!1;if(f.type==="number"&&f.validity&&f.validity.badInput)return!1;if(!g.syncPendingRef(f,S,c))return g.isUploadInput(f)&&(this.trackBefore("updated",f,S),m.push(f)),!1;if(g.isPhxChild(S)){let de=f.getAttribute(Pe);return g.mergeAttrs(f,S,{exclude:[It]}),de!==""&&f.setAttribute(Pe,de),f.setAttribute(hr,this.rootID),!1}return g.copyPrivates(S,f),g.discardError(n,S,u),g.syncPropsToAttrs(S),s&&f.isSameNode(s)&&g.isFormInput(f)&&!this.forceFocusedSelectUpdate(f,S)?(this.trackBefore("updated",f,S),g.mergeFocusedInput(f,S),g.syncAttrsToProps(f),m.push(f),!1):(g.isPhxUpdate(S,l,["append","prepend"])&&p.push(new nh(f,S,S.getAttribute(l))),g.syncAttrsToProps(S),this.trackBefore("updated",f,S),!0)}})}),e.isDebugEnabled()&&Yc(),p.length>0&&e.time("post-morph append/prepend restoration",()=>{p.forEach(f=>f.perform())}),e.silenceEvents(()=>g.restoreFocus(s,o,a)),g.dispatchEvent(document,"phx:update"),d.forEach(f=>this.trackAfter("added",f)),m.forEach(f=>this.trackAfter("updated",f)),y&&(e.disconnect(),y.submit()),!0}forceFocusedSelectUpdate(t,e){let r=["select","select-one","select-multiple"].find(i=>i===t.type);return t.multiple===!0||r&&t.innerHTML!=e.innerHTML}isCIDPatch(){return this.cidPatch}skipCIDSibling(t){return t.nodeType===Node.ELEMENT_NODE&&t.getAttribute(ci)!==null}targetCIDContainer(t){if(!this.isCIDPatch())return;let[e,...r]=g.findComponentNodeList(this.container,this.targetCID);return r.length===0&&g.childNodeLength(t)===1?e:e&&e.parentNode}buildDiffHTML(t,e,r,i){let n=this.isCIDPatch(),s=n&&i.getAttribute(G)===this.targetCID.toString();if(!n||s)return e;{let o=null,a=document.createElement("template");o=g.cloneNode(i);let[l,...u]=g.findComponentNodeList(o,this.targetCID);return a.innerHTML=e,u.forEach(c=>c.remove()),Array.from(o.childNodes).forEach(c=>{c.id&&c.nodeType===Node.ELEMENT_NODE&&c.getAttribute(G)!==this.targetCID.toString()&&(c.setAttribute(ci,""),c.innerHTML="")}),Array.from(a.content.childNodes).forEach(c=>o.insertBefore(c,l)),l.remove(),o.outerHTML}}},qo=class{static extract(t){let{[xo]:e,[Do]:r,[No]:i}=t;return delete t[xo],delete t[Do],delete t[No],{diff:t,title:i,reply:e||null,events:r||[]}}constructor(t,e){this.viewId=t,this.rendered={},this.mergeDiff(e)}parentViewId(){return this.viewId}toString(t){return this.recursiveToString(this.rendered,this.rendered[$],t)}recursiveToString(t,e=t[$],r){r=r?new Set(r):null;let i={buffer:"",components:e,onlyCids:r};return this.toOutputBuffer(t,i),i.buffer}componentCIDs(t){return Object.keys(t[$]||{}).map(e=>parseInt(e))}isComponentOnlyDiff(t){return t[$]?Object.keys(t).length===1:!1}getComponent(t,e){return t[$][e]}mergeDiff(t){let e=t[$],r={};if(delete t[$],this.rendered=this.mutableMerge(this.rendered,t),this.rendered[$]=this.rendered[$]||{},e){let n=this.rendered[$];for(let s in e)e[s]=this.cachedFindComponent(s,e[s],n,e,r);for(var i in e)n[i]=e[i];t[$]=e}}cachedFindComponent(t,e,r,i,n){if(n[t])return n[t];{let s,o,a=e[he];if(typeof a=="number"){let l;a>0?l=this.cachedFindComponent(a,i[a],r,i,n):l=r[-a],o=l[he],s=this.cloneMerge(l,e),s[he]=o}else s=e[he]!==void 0?e:this.cloneMerge(r[t]||{},e);return n[t]=s,s}}mutableMerge(t,e){return e[he]!==void 0?e:(this.doMutableMerge(t,e),t)}doMutableMerge(t,e){for(let r in e){let i=e[r],n=t[r];Dt(i)&&i[he]===void 0&&Dt(n)?this.doMutableMerge(n,i):t[r]=i}}cloneMerge(t,e){let r={...t,...e};for(let i in r){let n=e[i],s=t[i];Dt(n)&&n[he]===void 0&&Dt(s)&&(r[i]=this.cloneMerge(s,n))}return r}componentToString(t){return this.recursiveCIDToString(this.rendered[$],t)}pruneCIDs(t){t.forEach(e=>delete this.rendered[$][e])}get(){return this.rendered}isNewFingerprint(t={}){return!!t[he]}toOutputBuffer(t,e){if(t[Ro])return this.comprehensionToBuffer(t,e);let{[he]:r}=t;e.buffer+=r[0];for(let i=1;i<r.length;i++)this.dynamicToBuffer(t[i-1],e),e.buffer+=r[i]}comprehensionToBuffer(t,e){let{[Ro]:r,[he]:i}=t;for(let n=0;n<r.length;n++){let s=r[n];e.buffer+=i[0];for(let o=1;o<i.length;o++)this.dynamicToBuffer(s[o-1],e),e.buffer+=i[o]}}dynamicToBuffer(t,e){typeof t=="number"?e.buffer+=this.recursiveCIDToString(e.components,t,e.onlyCids):Dt(t)?this.toOutputBuffer(t,e):e.buffer+=t}recursiveCIDToString(t,e,r){let i=t[e]||R(`no component for CID ${e}`,t),n=document.createElement("template");n.innerHTML=this.recursiveToString(i,t,r);let s=n.content,o=r&&!r.has(e),[a,l]=Array.from(s.childNodes).reduce(([u,c],h,d)=>h.nodeType===Node.ELEMENT_NODE?h.getAttribute(G)?[u,!0]:(h.setAttribute(G,e),h.id||(h.id=`${this.parentViewId()}-${e}-${d}`),o&&(h.setAttribute(ci,""),h.innerHTML=""),[!0,c]):h.nodeValue.trim()!==""?(R(`only HTML element tags are allowed at the root of components. + +got: "${h.nodeValue.trim()}" + +within: +`,n.innerHTML.trim()),h.replaceWith(this.createSpan(h.nodeValue,e)),[!0,c]):(h.remove(),[u,c]),[!1,!1]);return!a&&!l?(R(`expected at least one HTML element tag inside a component, but the component is empty: +`,n.innerHTML.trim()),this.createSpan("",e).outerHTML):(!a&&l&&R("expected at least one HTML element tag directly inside a component, but only subcomponents were found. A component must render at least one HTML tag directly inside itself.",n.innerHTML.trim()),n.innerHTML)}createSpan(t,e){let r=document.createElement("span");return r.innerText=t,r.setAttribute(G,e),r}},bh=1,Nt=class{static makeID(){return bh++}static elementID(t){return t.phxHookId}constructor(t,e,r){this.__view=t,this.__liveSocket=t.liveSocket,this.__callbacks=r,this.__listeners=new Set,this.__isDisconnected=!1,this.el=e,this.el.phxHookId=this.constructor.makeID();for(let i in this.__callbacks)this[i]=this.__callbacks[i]}__mounted(){this.mounted&&this.mounted()}__updated(){this.updated&&this.updated()}__beforeUpdate(){this.beforeUpdate&&this.beforeUpdate()}__destroyed(){this.destroyed&&this.destroyed()}__reconnected(){this.__isDisconnected&&(this.__isDisconnected=!1,this.reconnected&&this.reconnected())}__disconnected(){this.__isDisconnected=!0,this.disconnected&&this.disconnected()}pushEvent(t,e={},r=function(){}){return this.__view.pushHookEvent(null,t,e,r)}pushEventTo(t,e,r={},i=function(){}){return this.__view.withinTargets(t,(n,s)=>n.pushHookEvent(s,e,r,i))}handleEvent(t,e){let r=(i,n)=>n?t:e(i.detail);return window.addEventListener(`phx:hook:${t}`,r),this.__listeners.add(r),r}removeHandleEvent(t){let e=t(null,!0);window.removeEventListener(`phx:hook:${e}`,t),this.__listeners.delete(t)}upload(t,e){return this.__view.dispatchUploads(t,e)}uploadTo(t,e,r){return this.__view.withinTargets(t,i=>i.dispatchUploads(e,r))}__cleanup__(){this.__listeners.forEach(t=>this.removeHandleEvent(t))}},wi=(t,e={})=>{let r=new FormData(t),i=[];r.forEach((s,o,a)=>{s instanceof File&&i.push(o)}),i.forEach(s=>r.delete(s));let n=new URLSearchParams;for(let[s,o]of r.entries())n.append(s,o);for(let s in e)n.append(s,e[s]);return n.toString()},$o=class{constructor(t,e,r,i){this.liveSocket=e,this.flash=i,this.parent=r,this.root=r?r.root:this,this.el=t,this.id=this.el.id,this.ref=0,this.childJoins=0,this.loaderTimer=null,this.pendingDiffs=[],this.pruningCIDs=[],this.redirect=!1,this.href=null,this.joinCount=this.parent?this.parent.joinCount-1:0,this.joinPending=!0,this.destroyed=!1,this.joinCallback=function(){},this.stopCallback=function(){},this.pendingJoinOps=this.parent?null:[],this.viewHooks={},this.uploaders={},this.formSubmits=[],this.children=this.parent?null:{},this.root.children[this.id]={},this.channel=this.liveSocket.channel(`lv:${this.id}`,()=>({redirect:this.redirect?this.href:void 0,url:this.redirect?void 0:this.href||void 0,params:this.connectParams(),session:this.getSession(),static:this.getStatic(),flash:this.flash})),this.showLoader(this.liveSocket.loaderTimeout),this.bindChannel()}setHref(t){this.href=t}setRedirect(t){this.redirect=!0,this.href=t}isMain(){return this.liveSocket.main===this}connectParams(){let t=this.liveSocket.params(this.el),e=g.all(document,`[${this.binding(_c)}]`).map(r=>r.src||r.href).filter(r=>typeof r=="string");return e.length>0&&(t._track_static=e),t._mounts=this.joinCount,t}isConnected(){return this.channel.canPush()}getSession(){return this.el.getAttribute(Pe)}getStatic(){let t=this.el.getAttribute(It);return t===""?null:t}destroy(t=function(){}){this.destroyAllChildren(),this.destroyed=!0,delete this.root.children[this.id],this.parent&&delete this.root.children[this.parent.id][this.id],clearTimeout(this.loaderTimer);let e=()=>{t();for(let r in this.viewHooks)this.destroyHook(this.viewHooks[r])};g.markPhxChildDestroyed(this.el),this.log("destroyed",()=>["the child has been removed from the parent"]),this.channel.leave().receive("ok",e).receive("error",e).receive("timeout",e)}setContainerClasses(...t){this.el.classList.remove(Eo,cr,ko),this.el.classList.add(...t)}isLoading(){return this.el.classList.contains(cr)}showLoader(t){if(clearTimeout(this.loaderTimer),t)this.loaderTimer=setTimeout(()=>this.showLoader(),t);else{for(let e in this.viewHooks)this.viewHooks[e].__disconnected();this.setContainerClasses(cr)}}hideLoader(){clearTimeout(this.loaderTimer),this.setContainerClasses(Eo)}triggerReconnected(){for(let t in this.viewHooks)this.viewHooks[t].__reconnected()}log(t,e){this.liveSocket.log(this,t,e)}withinTargets(t,e){if(t instanceof HTMLElement)return this.liveSocket.owner(t,r=>e(r,t));if(/^(0|[1-9]\d*)$/.test(t)){let r=g.findComponentNodeList(this.el,t);r.length===0?R(`no component found matching phx-target of ${t}`):e(this,r[0])}else{let r=Array.from(document.querySelectorAll(t));r.length===0&&R(`nothing found matching the phx-target selector "${t}"`),r.forEach(i=>this.liveSocket.owner(i,n=>e(n,i)))}}applyDiff(t,e,r){this.log(t,()=>["",Mt(e)]);let{diff:i,reply:n,events:s,title:o}=qo.extract(e);return o&&g.putTitle(o),r({diff:i,reply:n,events:s}),n}onJoin(t){let{rendered:e,container:r}=t;if(r){let[i,n]=r;this.el=g.replaceRootContainer(this.el,i,n)}this.childJoins=0,this.joinPending=!0,this.flash=null,Me.dropLocal(this.liveSocket.localStorage,window.location.pathname,po),this.applyDiff("mount",e,({diff:i,events:n})=>{this.rendered=new qo(this.id,i);let s=this.renderContainer(null,"join");this.dropPendingRefs();let o=this.formsForRecovery(s);this.joinCount++,o.length>0?o.forEach((a,l)=>{this.pushFormRecovery(a,u=>{l===o.length-1&&this.onJoinComplete(u,s,n)})}):this.onJoinComplete(t,s,n)})}dropPendingRefs(){g.all(this.el,`[${ue}]`,t=>t.removeAttribute(ue))}onJoinComplete({live_patch:t},e,r){if(this.joinCount>1||this.parent&&!this.parent.isJoinPending())return this.applyJoinPatch(t,e,r);g.findPhxChildrenInFragment(e,this.id).filter(n=>{let s=n.id&&this.el.querySelector(`[id="${n.id}"]`),o=s&&s.getAttribute(It);return o&&n.setAttribute(It,o),this.joinChild(n)}).length===0?this.parent?(this.root.pendingJoinOps.push([this,()=>this.applyJoinPatch(t,e,r)]),this.parent.ackJoin(this)):(this.onAllChildJoinsComplete(),this.applyJoinPatch(t,e,r)):this.root.pendingJoinOps.push([this,()=>this.applyJoinPatch(t,e,r)])}attachTrueDocEl(){this.el=g.byId(this.id),this.el.setAttribute(hr,this.root.id)}dispatchEvents(t){t.forEach(([e,r])=>{window.dispatchEvent(new CustomEvent(`phx:hook:${e}`,{detail:r}))})}applyJoinPatch(t,e,r){this.attachTrueDocEl();let i=new yr(this,this.el,this.id,e,null);if(i.markPrunableContentForRemoval(),this.performPatch(i,!1),this.joinNewChildren(),g.all(this.el,`[${this.binding(mr)}], [data-phx-${mr}]`,n=>{let s=this.addHook(n);s&&s.__mounted()}),this.joinPending=!1,this.dispatchEvents(r),this.applyPendingUpdates(),t){let{kind:n,to:s}=t;this.liveSocket.historyPatch(s,n)}this.hideLoader(),this.joinCount>1&&this.triggerReconnected(),this.stopCallback()}triggerBeforeUpdateHook(t,e){this.liveSocket.triggerDOM("onBeforeElUpdated",[t,e]);let r=this.getHook(t),i=r&&g.isIgnored(t,this.binding(fi));if(r&&!t.isEqualNode(e)&&!(i&&Qc(t.dataset,e.dataset)))return r.__beforeUpdate(),r}performPatch(t,e){let r=[],i=!1,n=new Set;return t.after("added",s=>{this.liveSocket.triggerDOM("onNodeAdded",[s]);let o=this.addHook(s);o&&o.__mounted()}),t.after("phxChildAdded",s=>i=!0),t.before("updated",(s,o)=>{this.triggerBeforeUpdateHook(s,o)&&n.add(s.id)}),t.after("updated",s=>{n.has(s.id)&&this.getHook(s).__updated()}),t.after("discarded",s=>{let o=this.componentID(s);typeof o=="number"&&r.indexOf(o)===-1&&r.push(o);let a=this.getHook(s);a&&this.destroyHook(a)}),t.perform(),e&&this.maybePushComponentsDestroyed(r),i}joinNewChildren(){g.findPhxChildren(this.el,this.id).forEach(t=>this.joinChild(t))}getChildById(t){return this.root.children[this.id][t]}getDescendentByEl(t){return t.id===this.id?this:this.children[t.getAttribute(Lt)][t.id]}destroyDescendent(t){for(let e in this.root.children)for(let r in this.root.children[e])if(r===t)return this.root.children[e][r].destroy()}joinChild(t){if(!this.getChildById(t.id)){let r=new $o(t,this.liveSocket,this);return this.root.children[this.id][r.id]=r,r.join(),this.childJoins++,!0}}isJoinPending(){return this.joinPending}ackJoin(t){this.childJoins--,this.childJoins===0&&(this.parent?this.parent.ackJoin(this):this.onAllChildJoinsComplete())}onAllChildJoinsComplete(){this.joinCallback(),this.pendingJoinOps.forEach(([t,e])=>{t.isDestroyed()||e()}),this.pendingJoinOps=[]}update(t,e){if(this.isJoinPending()||this.liveSocket.hasPendingLink())return this.pendingDiffs.push({diff:t,events:e});this.rendered.mergeDiff(t);let r=!1;this.rendered.isComponentOnlyDiff(t)?this.liveSocket.time("component patch complete",()=>{g.findParentCIDs(this.el,this.rendered.componentCIDs(t)).forEach(n=>{this.componentPatch(this.rendered.getComponent(t,n),n)&&(r=!0)})}):_o(t)||this.liveSocket.time("full patch complete",()=>{let i=this.renderContainer(t,"update"),n=new yr(this,this.el,this.id,i,null);r=this.performPatch(n,!0)}),this.dispatchEvents(e),r&&this.joinNewChildren()}renderContainer(t,e){return this.liveSocket.time(`toString diff (${e})`,()=>{let r=this.el.tagName,i=t?this.rendered.componentCIDs(t).concat(this.pruningCIDs):null,n=this.rendered.toString(i);return`<${r}>${n}</${r}>`})}componentPatch(t,e){if(_o(t))return!1;let r=this.rendered.componentToString(e),i=new yr(this,this.el,this.id,r,e);return this.performPatch(i,!0)}getHook(t){return this.viewHooks[Nt.elementID(t)]}addHook(t){if(Nt.elementID(t)||!t.getAttribute)return;let e=t.getAttribute(`data-phx-${mr}`)||t.getAttribute(this.binding(mr));if(e&&!this.ownsElement(t))return;let r=this.liveSocket.getHookCallbacks(e);if(r){t.id||R(`no DOM ID for hook "${e}". Hooks require a unique ID on each element.`,t);let i=new Nt(this,t,r);return this.viewHooks[Nt.elementID(i.el)]=i,i}else e!==null&&R(`unknown hook found for "${e}"`,t)}destroyHook(t){t.__destroyed(),t.__cleanup__(),delete this.viewHooks[Nt.elementID(t.el)]}applyPendingUpdates(){this.pendingDiffs.forEach(({diff:t,events:e})=>this.update(t,e)),this.pendingDiffs=[]}onChannel(t,e){this.liveSocket.onChannel(this.channel,t,r=>{this.isJoinPending()?this.root.pendingJoinOps.push([this,()=>e(r)]):e(r)})}bindChannel(){this.liveSocket.onChannel(this.channel,"diff",t=>{this.applyDiff("update",t,({diff:e,events:r})=>this.update(e,r))}),this.onChannel("redirect",({to:t,flash:e})=>this.onRedirect({to:t,flash:e})),this.onChannel("live_patch",t=>this.onLivePatch(t)),this.onChannel("live_redirect",t=>this.onLiveRedirect(t)),this.channel.onError(t=>this.onError(t)),this.channel.onClose(t=>this.onClose(t))}destroyAllChildren(){for(let t in this.root.children[this.id])this.getChildById(t).destroy()}onLiveRedirect(t){let{to:e,kind:r,flash:i}=t,n=this.expandURL(e);this.liveSocket.historyRedirect(n,r,i)}onLivePatch(t){let{to:e,kind:r}=t;this.href=this.expandURL(e),this.liveSocket.historyPatch(e,r)}expandURL(t){return t.startsWith("/")?`${window.location.protocol}//${window.location.host}${t}`:t}onRedirect({to:t,flash:e}){this.liveSocket.redirect(t,e)}isDestroyed(){return this.destroyed}join(t){this.parent||(this.stopCallback=this.liveSocket.withPageLoading({to:this.href,kind:"initial"})),this.joinCallback=()=>t&&t(this.joinCount),this.liveSocket.wrapPush(this,{timeout:!1},()=>this.channel.join().receive("ok",e=>!this.isDestroyed()&&this.onJoin(e)).receive("error",e=>!this.isDestroyed()&&this.onJoinError(e)).receive("timeout",()=>!this.isDestroyed()&&this.onJoinError({reason:"timeout"})))}onJoinError(t){return t.reason==="unauthorized"||t.reason==="stale"?(this.log("error",()=>["unauthorized live_redirect. Falling back to page request",t]),this.onRedirect({to:this.href})):((t.redirect||t.live_redirect)&&(this.joinPending=!1,this.channel.leave()),t.redirect?this.onRedirect(t.redirect):t.live_redirect?this.onLiveRedirect(t.live_redirect):(this.log("error",()=>["unable to join",t]),this.liveSocket.reloadWithJitter(this)))}onClose(t){if(!this.isDestroyed()){if(this.isJoinPending()&&document.visibilityState!=="hidden"||this.liveSocket.hasPendingLink()&&t!=="leave")return this.liveSocket.reloadWithJitter(this);this.destroyAllChildren(),this.liveSocket.dropActiveElement(this),document.activeElement&&document.activeElement.blur(),this.liveSocket.isUnloaded()&&this.showLoader(zc)}}onError(t){this.onClose(t),this.log("error",()=>["view crashed",t]),this.liveSocket.isUnloaded()||this.displayError()}displayError(){this.isMain()&&g.dispatchEvent(window,"phx:page-loading-start",{to:this.href,kind:"error"}),this.showLoader(),this.setContainerClasses(cr,ko)}pushWithReply(t,e,r,i=function(){}){if(!this.isConnected())return;let[n,[s]]=t?t():[null,[]],o=function(){};return s&&s.getAttribute(this.binding(So))!==null&&(o=this.liveSocket.withPageLoading({kind:"element",target:s})),typeof r.cid!="number"&&delete r.cid,this.liveSocket.wrapPush(this,{timeout:!0},()=>this.channel.push(e,r,Jc).receive("ok",a=>{let l=null;n!==null&&this.undoRefs(n),a.diff&&(l=this.applyDiff("update",a.diff,({diff:u,events:c})=>{this.update(u,c)})),a.redirect&&this.onRedirect(a.redirect),a.live_patch&&this.onLivePatch(a.live_patch),a.live_redirect&&this.onLiveRedirect(a.live_redirect),o(),i(a,l)}))}undoRefs(t){g.all(this.el,`[${ue}="${t}"]`,e=>{let r=e.getAttribute(dr);e.removeAttribute(ue),e.getAttribute(hi)!==null&&(e.readOnly=!1,e.removeAttribute(hi)),r!==null&&(e.disabled=r==="true",e.removeAttribute(dr)),vo.forEach(s=>g.removeClass(e,s));let i=e.getAttribute(fr);i!==null&&(e.innerText=i,e.removeAttribute(fr));let n=g.private(e,ue);if(n){let s=this.triggerBeforeUpdateHook(e,n);yr.patchEl(e,n,this.liveSocket.getActiveElement()),s&&s.__updated(),g.deletePrivate(e,ue)}})}putRef(t,e){let r=this.ref++,i=this.binding(di);return t.forEach(n=>{n.classList.add(`phx-${e}-loading`),n.setAttribute(ue,r);let s=n.getAttribute(i);s!==null&&(n.getAttribute(fr)||n.setAttribute(fr,n.innerText),n.innerText=s)}),[r,t]}componentID(t){let e=t.getAttribute&&t.getAttribute(G);return e?parseInt(e):null}targetComponentID(t,e){return t.getAttribute(this.binding("target"))?this.closestComponentID(e):null}closestComponentID(t){return t?ye(t.closest(`[${G}]`),e=>this.ownsElement(e)&&this.componentID(e)):null}pushHookEvent(t,e,r,i){if(!this.isConnected())return this.log("hook",()=>["unable to push hook event. LiveView not connected",e,r]),!1;let[n,s]=this.putRef([],"hook");return this.pushWithReply(()=>[n,s],"event",{type:"hook",event:e,value:r,cid:this.closestComponentID(t)},(o,a)=>i(a,n)),n}extractMeta(t,e){let r=this.binding("value-");for(let i=0;i<t.attributes.length;i++){let n=t.attributes[i].name;n.startsWith(r)&&(e[n.replace(r,"")]=t.getAttribute(n))}return t.value!==void 0&&(e.value=t.value,t.tagName==="INPUT"&&Lo.indexOf(t.type)>=0&&!t.checked&&delete e.value),e}pushEvent(t,e,r,i,n){this.pushWithReply(()=>this.putRef([e],t),"event",{type:t,event:i,value:this.extractMeta(e,n),cid:this.targetComponentID(e,r)})}pushKey(t,e,r,i,n){this.pushWithReply(()=>this.putRef([t],r),"event",{type:r,event:i,value:this.extractMeta(t,n),cid:this.targetComponentID(t,e)})}pushFileProgress(t,e,r,i=function(){}){this.liveSocket.withinOwners(t.form,(n,s)=>{n.pushWithReply(null,"progress",{event:t.getAttribute(n.binding($c)),ref:t.getAttribute(je),entry_ref:e,progress:r,cid:n.targetComponentID(t.form,s)},i)})}pushInput(t,e,r,i,n){let s,o=this.targetComponentID(t.form,e),a=()=>this.putRef([t,t.form],"change"),l=wi(t.form,{_target:i.name});t.files&&t.files.length>0&&D.trackFiles(t,Array.from(t.files)),s=D.serializeUploads(t);let u={type:"form",event:r,value:l,uploads:s,cid:o};this.pushWithReply(a,"event",u,c=>{if(g.showError(t,this.liveSocket.binding(Oo)),g.isUploadInput(t)&&t.getAttribute("data-phx-auto-upload")!==null){if(D.filesAwaitingPreflight(t).length>0){let[h,d]=a();this.uploadFiles(t.form,e,h,o,m=>{n&&n(c),this.triggerAwaitingSubmit(t.form)})}}else n&&n(c)})}triggerAwaitingSubmit(t){let e=this.getScheduledSubmit(t);if(e){let[r,i,n]=e;this.cancelSubmit(t),n()}}getScheduledSubmit(t){return this.formSubmits.find(([e,r])=>e.isSameNode(t))}scheduleSubmit(t,e,r){if(this.getScheduledSubmit(t))return!0;this.formSubmits.push([t,e,r])}cancelSubmit(t){this.formSubmits=this.formSubmits.filter(([e,r,i])=>e.isSameNode(t)?(this.undoRefs(r),!1):!0)}pushFormSubmit(t,e,r,i){let n=c=>!(Rt(c,`${this.binding(fi)}=ignore`,c.form)||Rt(c,"data-phx-update=ignore",c.form)),s=c=>c.hasAttribute(this.binding(di)),o=c=>c.tagName=="BUTTON",a=c=>["INPUT","TEXTAREA","SELECT"].includes(c.tagName),l=()=>{let c=Array.from(t.elements),h=c.filter(s),d=c.filter(o).filter(n),m=c.filter(a).filter(n);return d.forEach(p=>{p.setAttribute(dr,p.disabled),p.disabled=!0}),m.forEach(p=>{p.setAttribute(hi,p.readOnly),p.readOnly=!0,p.files&&(p.setAttribute(dr,p.disabled),p.disabled=!0)}),t.setAttribute(this.binding(So),""),this.putRef([t].concat(h).concat(d).concat(m),"submit")},u=this.targetComponentID(t,e);if(D.hasUploadsInProgress(t)){let[c,h]=l();return this.scheduleSubmit(t,c,()=>this.pushFormSubmit(t,e,r,i))}else if(D.inputsAwaitingPreflight(t).length>0){let[c,h]=l(),d=()=>[c,h];this.uploadFiles(t,e,c,u,m=>{let p=wi(t,{});this.pushWithReply(d,"event",{type:"form",event:r,value:p,cid:u},i)})}else{let c=wi(t);this.pushWithReply(l,"event",{type:"form",event:r,value:c,cid:u},i)}}uploadFiles(t,e,r,i,n){let s=this.joinCount,o=D.activeFileInputs(t),a=o.length;o.forEach(l=>{let u=new D(l,this,()=>{a--,a===0&&n()});this.uploaders[l]=u;let c=u.entries().map(d=>d.toPreflightPayload()),h={ref:l.getAttribute(je),entries:c,cid:this.targetComponentID(l.form,e)};this.log("upload",()=>["sending preflight request",h]),this.pushWithReply(null,"allow_upload",h,d=>{if(this.log("upload",()=>["got preflight response",d]),d.error){this.undoRefs(r);let[m,p]=d.error;this.log("upload",()=>[`error for entry ${m}`,p])}else{let m=p=>{this.channel.onError(()=>{this.joinCount===s&&p()})};u.initAdapterUpload(d,m,this.liveSocket)}})})}dispatchUploads(t,e){let r=g.findUploadInputs(this.el).filter(i=>i.name===t);r.length===0?R(`no live file inputs found matching the name "${t}"`):r.length>1?R(`duplicate live file inputs found matching the name "${t}"`):g.dispatchEvent(r[0],yo,{files:e})}pushFormRecovery(t,e){this.liveSocket.withinOwners(t,(r,i)=>{let n=t.elements[0],s=t.getAttribute(this.binding(Po))||t.getAttribute(this.binding("change"));r.pushInput(n,i,s,n,e)})}pushLinkPatch(t,e,r){let i=this.liveSocket.setPendingLink(t),n=e?()=>this.putRef([e],"click"):null;this.pushWithReply(n,"live_patch",{url:t},s=>{s.link_redirect?this.liveSocket.replaceMain(t,null,r,i):(this.liveSocket.commitPendingLink(i)&&(this.href=t),this.applyPendingUpdates(),r&&r(i))}).receive("timeout",()=>this.liveSocket.redirect(window.location.href))}formsForRecovery(t){if(this.joinCount===0)return[];let e=this.binding("change"),r=document.createElement("template");return r.innerHTML=t,g.all(this.el,`form[${e}]`).filter(i=>this.ownsElement(i)).filter(i=>i.elements.length>0).filter(i=>i.getAttribute(this.binding(Po))!=="ignore").filter(i=>r.content.querySelector(`form[${e}="${i.getAttribute(e)}"]`))}maybePushComponentsDestroyed(t){let e=t.filter(r=>g.findComponentNodeList(this.el,r).length===0);e.length>0&&(this.pruningCIDs.push(...e),this.pushWithReply(null,"cids_will_destroy",{cids:e},()=>{this.pruningCIDs=this.pruningCIDs.filter(i=>e.indexOf(i)!==-1);let r=e.filter(i=>g.findComponentNodeList(this.el,i).length===0);r.length>0&&this.pushWithReply(null,"cids_destroyed",{cids:r},i=>{this.rendered.pruneCIDs(i.cids)})}))}ownsElement(t){return t.getAttribute(Lt)===this.id||ye(t.closest(lt),e=>e.id)===this.id}submitForm(t,e,r){g.putPrivate(t,Io,!0),this.liveSocket.blurActiveElement(this),this.pushFormSubmit(t,e,r,()=>{this.liveSocket.restorePreviouslyActiveFocus()})}binding(t){return this.liveSocket.binding(t)}},Wo=class{constructor(t,e,r={}){if(this.unloaded=!1,!e||e.constructor.name==="Object")throw new Error(` + a phoenix Socket must be provided as the second argument to the LiveSocket constructor. For example: + + import {Socket} from "phoenix" + import LiveSocket from "phoenix_live_view" + let liveSocket = new LiveSocket("/live", Socket, {...}) + `);this.socket=new e(t,r),this.bindingPrefix=r.bindingPrefix||Zc,this.opts=r,this.params=vi(r.params||{}),this.viewLogger=r.viewLogger,this.metadataCallbacks=r.metadata||{},this.defaults=Object.assign(Mt(Kc),r.defaults||{}),this.activeElement=null,this.prevActive=null,this.silenced=!1,this.main=null,this.linkRef=1,this.roots={},this.href=window.location.href,this.pendingLink=null,this.currentLocation=Mt(window.location),this.hooks=r.hooks||{},this.uploaders=r.uploaders||{},this.loaderTimeout=r.loaderTimeout||Wc,this.localStorage=r.localStorage||window.localStorage,this.sessionStorage=r.sessionStorage||window.sessionStorage,this.boundTopLevelEvents=!1,this.domCallbacks=Object.assign({onNodeAdded:vi(),onBeforeElUpdated:vi()},r.dom||{}),window.addEventListener("pagehide",i=>{this.unloaded=!0}),this.socket.onOpen(()=>{this.isUnloaded()&&window.location.reload()})}isProfileEnabled(){return this.sessionStorage.getItem(pi)==="true"}isDebugEnabled(){return this.sessionStorage.getItem(mi)==="true"}enableDebug(){this.sessionStorage.setItem(mi,"true")}enableProfiling(){this.sessionStorage.setItem(pi,"true")}disableDebug(){this.sessionStorage.removeItem(mi)}disableProfiling(){this.sessionStorage.removeItem(pi)}enableLatencySim(t){this.enableDebug(),console.log("latency simulator enabled for the duration of this browser session. Call disableLatencySim() to disable"),this.sessionStorage.setItem(gi,t)}disableLatencySim(){this.sessionStorage.removeItem(gi)}getLatencySim(){let t=this.sessionStorage.getItem(gi);return t?parseInt(t):null}getSocket(){return this.socket}connect(){let t=()=>{this.joinRootViews()&&(this.bindTopLevelEvents(),this.socket.connect())};["complete","loaded","interactive"].indexOf(document.readyState)>=0?t():document.addEventListener("DOMContentLoaded",()=>t())}disconnect(t){this.socket.disconnect(t)}triggerDOM(t,e){this.domCallbacks[t](...e)}time(t,e){if(!this.isProfileEnabled()||!console.time)return e();console.time(t);let r=e();return console.timeEnd(t),r}log(t,e,r){if(this.viewLogger){let[i,n]=r();this.viewLogger(t,e,i,n)}else if(this.isDebugEnabled()){let[i,n]=r();Xc(t,e,i,n)}}onChannel(t,e,r){t.on(e,i=>{let n=this.getLatencySim();n?(console.log(`simulating ${n}ms of latency from server to client`),setTimeout(()=>r(i),n)):r(i)})}wrapPush(t,e,r){let i=this.getLatencySim(),n=t.joinCount;if(!i)return e.timeout?r().receive("timeout",()=>{t.joinCount===n&&!t.isDestroyed()&&this.reloadWithJitter(t,()=>{this.log(t,"timeout",()=>["received timeout while communicating with server. Falling back to hard refresh for recovery"])})}):r();console.log(`simulating ${i}ms of latency from client to server`);let s={receives:[],receive(o,a){this.receives.push([o,a])}};return setTimeout(()=>{t.isDestroyed()||s.receives.reduce((o,[a,l])=>o.receive(a,l),r())},i),s}reloadWithJitter(t,e){t.destroy(),this.disconnect();let[r,i]=xc,n=Math.floor(Math.random()*(i-r+1))+r,s=Me.updateLocal(this.localStorage,window.location.pathname,po,0,o=>o+1);e?e():this.log(t,"join",()=>[`encountered ${s} consecutive reloads`]),s>go&&(this.log(t,"join",()=>[`exceeded ${go} consecutive reloads. Entering failsafe mode`]),n=Nc),setTimeout(()=>{this.hasPendingLink()?window.location=this.pendingLink:window.location.reload()},n)}getHookCallbacks(t){return t&&t.startsWith("Phoenix.")?ih[t.split(".")[1]]:this.hooks[t]}isUnloaded(){return this.unloaded}isConnected(){return this.socket.isConnected()}getBindingPrefix(){return this.bindingPrefix}binding(t){return`${this.getBindingPrefix()}${t}`}channel(t,e){return this.socket.channel(t,e)}joinRootViews(){let t=!1;return g.all(document,`${lt}:not([${Lt}])`,e=>{if(!this.getRootById(e.id)){let r=this.newRootView(e);r.setHref(this.getHref()),r.join(),e.getAttribute(Ao)&&(this.main=r)}t=!0}),t}redirect(t,e){this.disconnect(),Me.redirect(t,e)}replaceMain(t,e,r=null,i=this.setPendingLink(t)){let n=this.main.el,s=g.cloneNode(n,"");this.main.showLoader(this.loaderTimeout),this.main.destroy(),this.main=this.newRootView(s,e),this.main.setRedirect(t),this.main.join(o=>{o===1&&this.commitPendingLink(i)&&(n.replaceWith(s),r&&r())})}isPhxView(t){return t.getAttribute&&t.getAttribute(Pe)!==null}newRootView(t,e){let r=new $o(t,this,null,e);return this.roots[r.id]=r,r}owner(t,e){let r=ye(t.closest(lt),i=>this.getViewByEl(i));r&&e(r)}withinOwners(t,e){this.owner(t,r=>{let i=t.getAttribute(this.binding("target"));i===null?e(r,t):r.withinTargets(i,e)})}getViewByEl(t){let e=t.getAttribute(hr);return ye(this.getRootById(e),r=>r.getDescendentByEl(t))}getRootById(t){return this.roots[t]}destroyAllViews(){for(let t in this.roots)this.roots[t].destroy(),delete this.roots[t]}destroyViewByEl(t){let e=this.getRootById(t.getAttribute(hr));e&&e.destroyDescendent(t.id)}setActiveElement(t){if(this.activeElement===t)return;this.activeElement=t;let e=()=>{t===this.activeElement&&(this.activeElement=null),t.removeEventListener("mouseup",this),t.removeEventListener("touchend",this)};t.addEventListener("mouseup",e),t.addEventListener("touchend",e)}getActiveElement(){return document.activeElement===document.body?this.activeElement||document.activeElement:document.activeElement||document.body}dropActiveElement(t){this.prevActive&&t.ownsElement(this.prevActive)&&(this.prevActive=null)}restorePreviouslyActiveFocus(){this.prevActive&&this.prevActive!==document.body&&this.prevActive.focus()}blurActiveElement(){this.prevActive=this.getActiveElement(),this.prevActive!==document.body&&this.prevActive.blur()}bindTopLevelEvents(){this.boundTopLevelEvents||(this.boundTopLevelEvents=!0,document.body.addEventListener("click",function(){}),window.addEventListener("pageshow",t=>{t.persisted&&(this.getSocket().disconnect(),this.withPageLoading({to:window.location.href,kind:"redirect"}),window.location.reload())},!0),this.bindNav(),this.bindClicks(),this.bindForms(),this.bind({keyup:"keyup",keydown:"keydown"},(t,e,r,i,n,s,o)=>{let a=i.getAttribute(this.binding(qc)),l=t.key&&t.key.toLowerCase();a&&a.toLowerCase()!==l||r.pushKey(i,n,e,s,{key:t.key,...this.eventMeta(e,t,i)})}),this.bind({blur:"focusout",focus:"focusin"},(t,e,r,i,n,s,o)=>{o||r.pushEvent(e,i,n,s,this.eventMeta(e,t,i))}),this.bind({blur:"blur",focus:"focus"},(t,e,r,i,n,s,o)=>{o&&!o!=="window"&&r.pushEvent(e,i,n,s,this.eventMeta(e,t,i))}),window.addEventListener("dragover",t=>t.preventDefault()),window.addEventListener("drop",t=>{t.preventDefault();let e=ye(Rt(t.target,this.binding(bo)),n=>n.getAttribute(this.binding(bo))),r=e&&document.getElementById(e),i=Array.from(t.dataTransfer.files||[]);!r||r.disabled||i.length===0||!(r.files instanceof FileList)||(D.trackFiles(r,i),r.dispatchEvent(new Event("input",{bubbles:!0})))}),this.on(yo,t=>{let e=t.target;if(!g.isUploadInput(e))return;let r=Array.from(t.detail.files||[]).filter(i=>i instanceof File||i instanceof Blob);D.trackFiles(e,r),e.dispatchEvent(new Event("input",{bubbles:!0}))}))}eventMeta(t,e,r){let i=this.metadataCallbacks[t];return i?i(e,r):{}}setPendingLink(t){return this.linkRef++,this.pendingLink=t,this.linkRef}commitPendingLink(t){return this.linkRef!==t?!1:(this.href=this.pendingLink,this.pendingLink=null,!0)}getHref(){return this.href}hasPendingLink(){return!!this.pendingLink}bind(t,e){for(let r in t){let i=t[r];this.on(i,n=>{let s=this.binding(r),o=this.binding(`window-${r}`),a=n.target.getAttribute&&n.target.getAttribute(s);a?this.debounce(n.target,n,()=>{this.withinOwners(n.target,(l,u)=>{e(n,r,l,n.target,u,a,null)})}):g.all(document,`[${o}]`,l=>{let u=l.getAttribute(o);this.debounce(l,n,()=>{this.withinOwners(l,(c,h)=>{e(n,r,c,l,h,u,"window")})})})})}}bindClicks(){this.bindClick("click","click",!1),this.bindClick("mousedown","capture-click",!0)}bindClick(t,e,r){let i=this.binding(e);window.addEventListener(t,n=>{if(!this.isConnected())return;let s=null;r?s=n.target.matches(`[${i}]`)?n.target:n.target.querySelector(`[${i}]`):s=Rt(n.target,i);let o=s&&s.getAttribute(i);!o||(s.getAttribute("href")==="#"&&n.preventDefault(),this.debounce(s,n,()=>{this.withinOwners(s,(a,l)=>{a.pushEvent("click",s,l,o,this.eventMeta("click",n,s))})}))},r)}bindNav(){if(!Me.canPushState())return;history.scrollRestoration&&(history.scrollRestoration="manual");let t=null;window.addEventListener("scroll",e=>{clearTimeout(t),t=setTimeout(()=>{Me.updateCurrentState(r=>Object.assign(r,{scroll:window.scrollY}))},100)}),window.addEventListener("popstate",e=>{if(!this.registerNewLocation(window.location))return;let{type:r,id:i,root:n,scroll:s}=e.state||{},o=window.location.href;this.main.isConnected()&&r==="patch"&&i===this.main.id?this.main.pushLinkPatch(o,null):this.replaceMain(o,null,()=>{n&&this.replaceRootHistory(),typeof s=="number"&&setTimeout(()=>{window.scrollTo(0,s)},0)})},!1),window.addEventListener("click",e=>{let r=Rt(e.target,oi),i=r&&r.getAttribute(oi),n=e.metaKey||e.ctrlKey||e.button===1;if(!i||!this.isConnected()||!this.main||n)return;let s=r.href,o=r.getAttribute(Fc);if(e.preventDefault(),this.pendingLink!==s)if(i==="patch")this.pushHistoryPatch(s,o,r);else if(i==="redirect")this.historyRedirect(s,o);else throw new Error(`expected ${oi} to be "patch" or "redirect", got: ${i}`)},!1)}withPageLoading(t,e){g.dispatchEvent(window,"phx:page-loading-start",t);let r=()=>g.dispatchEvent(window,"phx:page-loading-stop",t);return e?e(r):r}pushHistoryPatch(t,e,r){this.withPageLoading({to:t,kind:"patch"},i=>{this.main.pushLinkPatch(t,r,n=>{this.historyPatch(t,e,n),i()})})}historyPatch(t,e,r=this.setPendingLink(t)){!this.commitPendingLink(r)||(Me.pushState(e,{type:"patch",id:this.main.id},t),this.registerNewLocation(window.location))}historyRedirect(t,e,r){let i=window.scrollY;this.withPageLoading({to:t,kind:"redirect"},n=>{this.replaceMain(t,r,()=>{Me.pushState(e,{type:"redirect",id:this.main.id,scroll:i},t),this.registerNewLocation(window.location),n()})})}replaceRootHistory(){Me.pushState("replace",{root:!0,type:"patch",id:this.main.id})}registerNewLocation(t){let{pathname:e,search:r}=this.currentLocation;return e+r===t.pathname+t.search?!1:(this.currentLocation=Mt(t),!0)}bindForms(){let t=0;this.on("submit",e=>{let r=e.target.getAttribute(this.binding("submit"));!r||(e.preventDefault(),e.target.disabled=!0,this.withinOwners(e.target,(i,n)=>i.submitForm(e.target,n,r)))},!1);for(let e of["change","input"])this.on(e,r=>{let i=r.target,n=i.form&&i.form.getAttribute(this.binding("change"));if(!n||i.type==="number"&&i.validity&&i.validity.badInput)return;let s=t;t++;let{at:o,type:a}=g.private(i,"prev-iteration")||{};o===s-1&&e!==a||(g.putPrivate(i,"prev-iteration",{at:s,type:e}),this.debounce(i,r,()=>{this.withinOwners(i.form,(l,u)=>{g.putPrivate(i,Co,!0),g.isTextualInput(i)||this.setActiveElement(i),l.pushInput(i,u,n,r.target)})}))},!1)}debounce(t,e,r){let i=this.binding(jc),n=this.binding(Uc),s=this.defaults.debounce.toString(),o=this.defaults.throttle.toString();g.debounce(t,e,i,s,n,o,r)}silenceEvents(t){this.silenced=!0,t(),this.silenced=!1}on(t,e){window.addEventListener(t,r=>{this.silenced||e(r)})}};var Si=ki(ii()),wh=Rr.start();wh.load(co);var Ei={};Ei.AutoFocus={mounted(){this.el.focus()}};Ei.NaiveDateTimeUTC={mounted(){var t=Intl.DateTimeFormat().resolvedOptions(),e=document.body.dataset.tz||t.timeZone||"UTC",r=document.body.dataset.locale||t.locale||"en",i=Si.DateTime[this.el.dataset.timeFormat],n=Si.DateTime.fromISO(this.el.dateTime,{zone:"utc"}).setZone(e).setLocale(r);this.el.innerText=n.toLocaleString(i)}};var Sh=document.querySelector("meta[name='csrf-token']").getAttribute("content"),Eh=new Wo("/live",mo,{hooks:Ei,params:{_csrf_token:Sh}});Eh.connect();})(); diff --git a/priv/static/assets/site.js.br b/priv/static/assets/site.js.br Binary files differindex c4fc486..0ef0117 100644 --- a/priv/static/assets/site.js.br +++ b/priv/static/assets/site.js.br diff --git a/priv/static/assets/site.js.gz b/priv/static/assets/site.js.gz Binary files differindex ef81dcf..5e0bb00 100644 --- a/priv/static/assets/site.js.gz +++ b/priv/static/assets/site.js.gz |