From dc77a7441999414c3a43bc5ad0f5602c83df232a Mon Sep 17 00:00:00 2001 From: Dziad Borowy Date: Wed, 22 May 2024 22:18:16 +0100 Subject: [PATCH] merge master --- CHANGELOG.md | 4 + docs/docs.css | 629 +- docs/docs.js | 83672 +++++++++++++++++++++++++++++++++++++++++++++++- docs/ui.css | 2745 +- 4 files changed, 86867 insertions(+), 183 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 8166222..4e1501d 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,6 +2,10 @@ Changelog ========= +## v10.0.0 *(2024-05-15)* +- Breaking change: Dropped `deepCopy` in favour of the native (and unwrapped) `structuredClone`. +- New component: `Grid`. + ## v9.5.3 *(2024-05-18)* - Fix `Combobox` issue for some edge cases. diff --git a/docs/docs.css b/docs/docs.css index 78fc13f..ad68c02 100644 --- a/docs/docs.css +++ b/docs/docs.css @@ -1 +1,628 @@ -.api-table{height:unset;overflow:auto visible;overscroll-behavior-y:unset}.api-table table{min-width:900px}.api-table tr td{vertical-align:top;padding-block:0.5rem}.api-table tr td:first-child,.api-table tr th:first-child{width:200px}.api-table tr td:nth-child(2),.api-table tr th:nth-child(2){width:200px}.api-table tr td:last-child,.api-table tr th:last-child{min-width:400px}body,html{margin:0;background-color:var(--ui-color-background);color:var(--ui-color-text);--sidebar-width:220px}@font-face{font-family:'Prime Light';src:url('prime_light-webfont.woff2') format('woff2'),url('prime_light-webfont.woff') format('woff');font-weight:light;font-style:normal}a{color:inherit}a:hover{text-decoration-color:var(--ui-color-accent);text-decoration-thickness:2px;text-underline-offset:0.3rem}main{padding:0 2rem 8rem;margin-left:var(--sidebar-width)}h1,h2,h3{font-weight:500;margin:2rem 0 1.2rem;width:100%}h1:first-child,h2:first-child,h3:first-of-type{margin-top:0}p{line-height:1.7;margin-block:1.5rem;max-width:120ch}p b{font-weight:700;letter-spacing:.5px}ul{line-height:1.7;margin:0;padding-left:2rem}ul li{margin-block:0.5rem}p+ul{margin-top:-1rem}em{color:var(--ui-color-accent);font-style:normal}hr{width:100%;height:0;border:0;border-top:1px solid var(--ui-color-border-2);margin:3em 0 2em}.docs-overflow-box{border:2px dotted var(--ui-color-accent);background-color:var(--ui-color-background);padding:1em;overflow:hidden;z-index:1;position:relative}.docs-buttons-row{display:flex;flex-flow:wrap row;align-items:flex-start;justify-content:flex-start;gap:.5rem;flex-shrink:0}@media (1px <= width <= 700px){main{margin-left:0}}code,main pre[class]{background-color:#1a1a1a;color:#ccc;border-radius:var(--ui-border-radius);font-size:var(--ui-font-s)}code{display:block;width:100%;padding:1em;margin-block:1em;line-height:2;white-space:pre;overflow:auto}code[class*=language-]{padding:0;margin:0}.dark-mode-switch{min-width:7rem;position:fixed;top:.5rem;right:.6rem;z-index:55}aside{border-right:1px solid var(--ui-color-border-2);overflow-y:auto;background:var(--ui-color-background);position:fixed;width:var(--sidebar-width);left:0;top:0;height:100lvh;padding:0 1rem calc(100lvh - 100svh);overscroll-behavior:contain}menu{width:100%;display:flex;flex-flow:column;padding:1rem 0 0;margin:0 0 2rem}menu h3{margin:0 -1rem;padding:var(--ui-margin-m) var(--ui-margin-l);white-space:nowrap;font-family:'Prime Light','Helvetica Neue',Helvetica,Arial,sans-serif;font-size:var(--ui-font-xl)}menu h3:not(:first-child){margin-top:var(--ui-margin-l)}menu a{color:var(--ui-color-text);text-decoration:none;display:block;margin:var(--ui-margin-s) 0;padding:var(--ui-margin-m) 1.4rem;border-radius:var(--ui-border-radius);white-space:nowrap;touch-action:manipulation}menu a:hover{background-color:var(--ui-color-highlight-1)}menu a.active{background-color:var(--ui-color-highlight)}.nav-toggler{--ui-button-size:1.1em;position:fixed;left:0;top:.4rem;z-index:65;color:var(--ui-color-text-1);display:none;transform:translateX(10px)}.nav-toggler:hover{color:var(--ui-color-text);background:0 0}.btn-scroll-top{position:fixed;bottom:1rem;right:1rem;z-index:999}.btn-scroll-top.hidden{display:none}@media (1px <= width <= 700px){.nav-toggler{display:flex}.nav-toggler.expanded{transform:translateX(calc(var(--sidebar-width) - 40px))}aside{box-shadow:2px 1px 10px #0006;transform:translateX(calc(var(--sidebar-width) * -1));z-index:60;--sidebar-elastic-padding:80px;width:calc(var(--sidebar-width) + var(--sidebar-elastic-padding));left:calc(var(--sidebar-elastic-padding) * -1);padding-left:calc(var(--sidebar-elastic-padding) + 1rem)}aside.expanded{transform:translateX(0)}.nav-toggler:not(.swiping),aside:not(.swiping){transition:transform .3s cubic-bezier(.5, .2, .5, 1.2)}}.banner{height:clamp(100px,40vw,360px);padding-top:60px;display:flex;align-items:flex-start;justify-content:center}.banner a{display:inline-flex;align-items:center;justify-content:center;gap:2vw;margin:auto;padding:0;text-decoration:none}.logo{width:clamp(42px,10vw,160px);height:clamp(42px,10vw,160px);opacity:.9;filter:drop-shadow(0 1px 1px #000)}.logotype{font-family:'Prime Light','Helvetica Neue',Helvetica,Arial,sans-serif;font-size:clamp(28px, 6vw, 90px);font-weight:100;margin:0;padding:0 4px 0 0;display:flex;flex-flow:row;white-space:nowrap;line-height:1;width:auto}.logotype em{font-weight:500}.logotype sub{font-size:var(--ui-font-m);font-weight:300;color:var(--ui-color-text-semi);margin:-1rem 0 0 -63px;width:60px;text-align:right}.banner a:hover .logotype em,.banner a:hover .logotype span{text-decoration:underline;text-decoration-thickness:1px;text-decoration-skip-ink:none;text-underline-offset:8px}.banner a:hover .logotype span{text-decoration-color:var(--ui-color-accent)}.banner a:hover .logotype em{text-decoration-color:var(--ui-color-text)}.footer-links{display:flex;align-items:center;justify-content:center;gap:5vw;margin:6rem 0 0;height:2rem}.footer-links a,.footer-links a:hover{text-decoration:none;height:100%;display:flex;align-items:center;color:var(--ui-color-text-semi);transition:color .1s}.footer-links a:hover{color:var(--ui-color-text)}.footer-links a svg{height:2rem;width:2rem;margin:0}.footer-links a.npm svg{width:5rem}.sticky-block{background:var(--ui-color-background);margin:0;padding:0}.sticky-block>h1,.sticky-block>h2,main>h1,main>h2{font-family:'Prime Light','Helvetica Neue',Helvetica,Arial,sans-serif;margin:2rem -2rem 1rem;padding:.5rem 100px .5rem 2rem}.prime-light{font-family:'Prime Light','Helvetica Neue',Helvetica,Arial,sans-serif}.sticky-block>h2,main>h2{font-size:1.8rem;width:auto;border-bottom:1px solid var(--ui-color-border-2);position:sticky;top:0;z-index:50;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;-webkit-backdrop-filter:blur(15px);backdrop-filter:blur(15px)}main>h2 em{color:var(--ui-color-text-semi);font-size:1.2rem;line-height:1.8rem;margin-left:.5rem;vertical-align:text-top}main>p code,main>ul li code{display:inline;padding:0;margin:0;background:0 0;color:var(--ui-color-accent);font:inherit;white-space:break-spaces}@media (1px <= width <= 700px){.sticky-block>h1,.sticky-block>h2,main>h1,main>h2{padding-left:54px}}.button-demo-props{display:flex;flex-flow:column;align-items:flex-start;justify-content:flex-start;gap:.5rem;width:clamp(300px,600px,100%)}.button-demo-props .input{display:flex;flex-flow:row;width:100%}.button-demo-props .input .label{width:5rem;flex-shrink:0}.button-demo-props .input .input-text-inner{flex:1}.button-demo-props .toggle{display:flex;flex-flow:row;width:100%}.button-demo-props .toggle .label{width:5rem;flex-shrink:0}@media (1px <= width <= 700px){.button-demo-props{width:100%}}.group{background:var(--ui-color-background-2);padding:6px;display:grid;grid-template-columns:repeat(auto-fill,minmax(320px,1fr));grid-gap:6px;border-radius:var(--ui-border-radius-m)}.palette-box{padding:10px 0;display:flex;align-items:center;justify-content:center;overflow:hidden;border-radius:calc(var(--ui-border-radius-m) - 3px);background-color:var(--ui-color-background-2)}.table-viewport{width:500px;max-width:100%;height:500px;border:2px dashed red;padding:5px}.icons{margin-bottom:2em}.icon-block{float:left;width:128px;height:128px;margin:0 1em 1em 0;display:flex;flex-flow:column;align-items:stretch;justify-content:stretch;background-color:var(--ui-color-background-semi);padding:0 10px 10px;border-radius:5px;border:1px solid var(--ui-color-border)}.icon-block-icon{flex:1;display:flex;align-items:center;justify-content:center}.icon-block-icon svg{width:32px;height:32px}.icon-block-name{height:20px;text-align:center;overflow-wrap:break-word;font-size:var(--ui-font-s)}.div{border:1px dashed red;height:100px;width:200px;display:inline-grid;place-items:center;margin:1rem 1rem 1rem 0;-webkit-user-select:none;user-select:none}.docs-menu-align-right{padding:2rem 0;border:1px dashed var(--ui-color-accent);text-align:right}.notification-center-header{margin-bottom:1rem;display:flex;flex-flow:row;align-items:center;justify-content:flex-start;gap:2rem}.notification-center-header h2{display:inline-block;width:auto;padding:0;margin:0}.prop-row{padding:1rem 0;display:flex;align-items:center;justify-content:flex-start;gap:1rem}.panel p{margin:0}.tooltip-box{display:inline-block;margin:10px 0 0;line-height:2.4em;padding:1em;border:1px solid #ccc;min-width:6em;text-align:center}.tooltip-html h1,.tooltip-html p{margin:0}.tooltip-html b{color:var(--ui-color-accent)}.tooltip-html a:hover{text-decoration:none}.split-wrap{width:400px;height:200px;border:1px solid red;display:flex;flex-flow:row;position:relative}.split-wrap-v{flex-flow:column}.split-box{border:1px solid green;flex:1}.min-w{min-width:20px;max-width:220px}.min-h{min-height:50px;max-height:150px}.table-viewport{width:500px;max-width:100%;height:500px;border:2px dashed red;padding:5px}.tooltip-box{display:inline-block;margin:10px 0 0;line-height:2.4em;padding:1em;border:1px solid #ccc;min-width:6em;text-align:center}.tooltip-html h1,.tooltip-html p{margin:0}.tooltip-html b{color:var(--ui-color-accent)}.tooltip-html a:hover{text-decoration:none}.section-utils{--nav-sidebar-width:240px}.section-utils .dark-mode-switch{right:calc(var(--nav-sidebar-width) + 20px)}.section-utils .sticky-block{padding-bottom:3rem;margin-right:var(--nav-sidebar-width)}.section-utils .sticky-block .utility h3{scroll-margin-top:4.2rem;font-size:1.1rem;color:var(--ui-color-accent);font-family:Consolas,Monaco,'Andale Mono','Ubuntu Mono',monospace}.section-utils .utilities-nav{position:fixed;right:0;top:0;bottom:0;z-index:52;margin:0;padding:1rem 2rem;overflow-y:auto;width:var(--nav-sidebar-width);border-left:1px solid var(--ui-color-border-2);background-color:var(--ui-color-background-input)}.section-utils .utility{margin:0 -2rem;padding:1rem 2rem;border-bottom:1px solid var(--ui-color-border-2)}.section-utils .btn-scroll-top{right:calc(var(--nav-sidebar-width) + 20px)}@media (1px <= width <= 900px){.section-utils .dark-mode-switch{right:.6rem}.section-utils .btn-scroll-top{right:1rem}.section-utils .sticky-block{margin-right:0}.section-utils .utilities-nav{position:static;border-left:none;width:auto;z-index:initial;margin-top:2rem;background-color:unset}}.button-toggle-wrapper-wide{width:400px;max-width:100%}.button-toggle-wrapper-wide .button-toggle{width:100%}.toggle-box{margin:10px 0 0;line-height:2.4em;display:none}.toggle-box.visible{display:block} \ No newline at end of file +.api-table { + height: unset; + overflow: auto visible; + overscroll-behavior-y: unset; +} +.api-table table { min-width: 900px; } + +.api-table tr td { vertical-align: top; padding-block: 0.5rem;} + +.api-table tr th:first-child, +.api-table tr td:first-child { width: 200px; } + +.api-table tr th:nth-child(2), +.api-table tr td:nth-child(2) { width: 200px; } + +.api-table tr th:last-child, +.api-table tr td:last-child { min-width: 400px; } + +html, +body { + margin: 0; + background-color: var(--ui-color-background); + color: var(--ui-color-text); + + --sidebar-width: 220px; +} + + +@font-face { + font-family: 'Prime Light'; + src: url('prime_light-webfont.woff2') format('woff2'), + url('prime_light-webfont.woff') format('woff'); + font-weight: light; + font-style: normal; +} + + +a { color: inherit; } +a:hover { + text-decoration-color: var(--ui-color-accent); + text-decoration-thickness: 2px; + text-underline-offset: 0.3rem; +} + +main { + padding: 0 2rem 8rem; + margin-left: var(--sidebar-width); +} + +h1, +h2, +h3 { font-weight: 500; margin: 2rem 0 1.2rem; width: 100%; } + +h1:first-child, +h2:first-child, +h3:first-of-type { margin-top: 0; } + +p { line-height: 1.7; margin-block: 1.5rem; max-width: 120ch; } +p b { font-weight: 700; letter-spacing: 0.5px; } + +ul { line-height: 1.7; margin: 0; padding-left: 2rem; } +ul li { margin-block: 0.5rem; } + +p + ul { margin-top: -1rem } + +em { color: var(--ui-color-accent); font-style: normal; } + + +hr { + width: 100%; + height: 0; + border: 0; + border-top: 1px solid var(--ui-color-border-2); + margin: 3em 0 2em; +} + + +.docs-overflow-box { + border: 2px dotted var(--ui-color-accent); + background-color: var(--ui-color-background); + padding: 1em; + overflow: hidden; + z-index: 1; + position: relative; +} + +.docs-buttons-row { + display: flex; + flex-flow: wrap row; + align-items: flex-start; + justify-content: flex-start; + gap: 0.5rem; + flex-shrink: 0; +} + + + +@media (1px <= width <= 700px) { + main { margin-left: 0; } +} + +main pre[class], +code { + background-color: #1a1a1a; + color: #ccc; + border-radius: var(--ui-border-radius); + font-size: var(--ui-font-s) +} + +code { + display: block; + width: 100%; + padding: 1em; + margin-block: 1em; + line-height: 2; + white-space: pre; + overflow: auto; +} + +code[class*=language-] { padding: 0; margin: 0; } + +.dark-mode-switch { + min-width: 7rem; + position: fixed; + top: 0.5rem; + right: 0.6rem; + z-index: 55; +} + +aside { + border-right: 1px solid var(--ui-color-border-2); + overflow-y: auto; + background: var(--ui-color-background); + position: fixed; + width: var(--sidebar-width); + + left: 0; + top: 0; + height: 100lvh; + padding: 0 1rem calc(100lvh - 100svh); + + overscroll-behavior: contain; +} + +menu { + width: 100%; + display: flex; + flex-flow: column; + padding: 1rem 0 0; + margin: 0 0 2rem; +} + +menu h3 { + margin: 0 -1rem; + padding: var(--ui-margin-m) var(--ui-margin-l); + white-space: nowrap; + font-family: 'Prime Light', 'Helvetica Neue', Helvetica, Arial, sans-serif; + font-size: var(--ui-font-xl); +} + +menu h3:not(:first-child) { margin-top: var(--ui-margin-l); } + +menu a { + color: var(--ui-color-text); + text-decoration: none; + display: block; + margin: var(--ui-margin-s) 0; + padding: var(--ui-margin-m) 1.4rem; + border-radius: var(--ui-border-radius); + white-space: nowrap; + touch-action: manipulation; +} + +menu a:hover { background-color: var(--ui-color-highlight-1); } +menu a.active { background-color: var(--ui-color-highlight); } + + +.nav-toggler { + --ui-button-size: 1.1em; + position: fixed; + left: 0; + top: 0.4rem; + z-index: 65; + color: var(--ui-color-text-1); + display: none; + transform: translateX(10px); +} +.nav-toggler:hover { color: var(--ui-color-text); background: none; } + +.btn-scroll-top { + position: fixed; + bottom: 1rem; + right: 1rem; + z-index: 999; +} +.btn-scroll-top.hidden { display: none; } + + +@media (1px <= width <= 700px) { + .nav-toggler { display: flex; } + .nav-toggler.expanded { transform: translateX(calc(var(--sidebar-width) - 40px)); } + + aside { + box-shadow: 2px 1px 10px #0006; + transform: translateX(calc(var(--sidebar-width) * -1)); + z-index: 60; + + --sidebar-elastic-padding: 80px; + width: calc(var(--sidebar-width) + var(--sidebar-elastic-padding)); + left: calc(var(--sidebar-elastic-padding) * -1); + padding-left: calc(var(--sidebar-elastic-padding) + 1rem); + + } + aside.expanded { transform: translateX(0); } + + .nav-toggler:not(.swiping), + aside:not(.swiping) { transition: transform .3s cubic-bezier(.5, .2, .5, 1.2); } +} + +.banner { + height: clamp(100px, 40vw, 360px); + padding-top: 60px; + display: flex; + align-items: flex-start; + justify-content: center; +} + +.banner a { + display: inline-flex; + align-items: center; + justify-content: center; + gap: 2vw; + margin: auto; + padding: 0; + text-decoration: none; +} + +.logo { + width: clamp(42px, 10vw, 160px); + height: clamp(42px, 10vw, 160px); + opacity: 0.9; + filter: drop-shadow(0 1px 1px #000); +} + + +.logotype { + font-family: 'Prime Light', 'Helvetica Neue', Helvetica, Arial, sans-serif; + font-size: clamp(28px, 6vw, 90px); + font-weight: 100; + margin: 0; + padding: 0 4px 0 0; + display: flex; + flex-flow: row; + white-space: nowrap; + line-height: 1; + width: auto; +} + +.logotype em { font-weight: 500; } +.logotype sub { + font-size: var(--ui-font-m); + font-weight: 300; + color: var(--ui-color-text-semi); + margin: -1rem 0 0 -63px; + width: 60px; + text-align: right; +} + + +.banner a:hover .logotype span, +.banner a:hover .logotype em { + text-decoration: underline; + text-decoration-thickness: 1px; + text-decoration-skip-ink: none; + text-underline-offset: 8px; +} +.banner a:hover .logotype span { text-decoration-color: var(--ui-color-accent); } +.banner a:hover .logotype em { text-decoration-color: var(--ui-color-text); } + + + + + +.footer-links { + display: flex; + align-items: center; + justify-content: center; + gap: 5vw; + margin: 6rem 0 0; + height: 2rem; +} + +.footer-links a, +.footer-links a:hover { + text-decoration: none; + height: 100%; + display: flex; + align-items: center; + color: var(--ui-color-text-semi); + transition: color 0.1s; +} + +.footer-links a:hover { color: var(--ui-color-text); } + +.footer-links a svg { height: 2rem; width: 2rem; margin: 0; } +.footer-links a.npm svg { width: 5rem; } + + + + +.sticky-block { + background: var(--ui-color-background); + margin: 0; + padding: 0; +} + +main>h1, +main>h2, +.sticky-block>h1, +.sticky-block>h2 { + font-family: 'Prime Light', 'Helvetica Neue', Helvetica, Arial, sans-serif; + margin: 2rem -2rem 1rem; + padding: 0.5rem 100px 0.5rem 2rem; +} + +.prime-light { + font-family: 'Prime Light', 'Helvetica Neue', Helvetica, Arial, sans-serif; +} + +/* stylelint-disable-next-line no-descending-specificity */ +main>h2, +.sticky-block>h2 { + font-size: 1.8rem; + width: auto; + border-bottom: 1px solid var(--ui-color-border-2); + position: sticky; + top: 0; + z-index: 50; + white-space: nowrap; + overflow: hidden; + text-overflow: ellipsis; + + -webkit-backdrop-filter: blur(15px); + backdrop-filter: blur(15px); +} + + + +/* stylelint-disable-next-line no-descending-specificity */ +main>h2 em { + color: var(--ui-color-text-semi); + font-size: 1.2rem; + line-height: 1.8rem; + margin-left: 0.5rem; + vertical-align: text-top; +} + +main>p code, +main>ul li code { + display: inline; + padding: 0; + margin: 0; + background: none; + color: var(--ui-color-accent); + font: inherit; + white-space: break-spaces; +} + + +@media (1px <= width <= 700px) { + main>h1, + main>h2, + .sticky-block>h1, + .sticky-block>h2 { padding-left: 54px; } +} + +.button-demo-props { + display: flex; + flex-flow: column; + align-items: flex-start; + justify-content: flex-start; + gap: 0.5rem; + width: clamp(300px, 600px, 100%); +} + +.button-demo-props .input { display: flex; flex-flow: row; width: 100%; } +.button-demo-props .input .label { width: 5rem; flex-shrink: 0; } +.button-demo-props .input .input-text-inner { flex: 1; } + + +.button-demo-props .toggle { display: flex; flex-flow: row; width: 100%; } +.button-demo-props .toggle .label { width: 5rem; flex-shrink: 0; } + +@media (1px <= width <= 700px) { + .button-demo-props { + width: 100%; + } +} + +.group { + background: var(--ui-color-background-2); + padding: 6px; + display: grid; + grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); + grid-gap: 6px; + border-radius: var(--ui-border-radius-m); +} + +.palette-box { + padding: 10px 0; + display: flex; + align-items: center; + justify-content: center; + overflow: hidden; + border-radius: calc(var(--ui-border-radius-m) - 3px); + background-color: var(--ui-color-background-2); +} + +.table-viewport { + width: 500px; + max-width: 100%; + height: 500px; + border: 2px dashed red; + padding: 5px; +} + +.icons { margin-bottom: 2em; } + +.icon-block { + float: left; + width: 128px; + height: 128px; + margin: 0 1em 1em 0; + display: flex; + flex-flow: column; + align-items: stretch; + justify-content: stretch; + background-color: var(--ui-color-background-semi); + padding: 0 10px 10px; + border-radius: 5px; + border: 1px solid var(--ui-color-border); +} + +.icon-block-icon { + flex: 1; + display: flex; + align-items: center; + justify-content: center; +} + +.icon-block-icon svg { + width: 32px; + height: 32px; +} + +.icon-block-name { + height: 20px; + text-align: center; + overflow-wrap: break-word; + font-size: var(--ui-font-s) +} + +.div { + border: 1px dashed red; + height: 100px; + width: 200px; + display: inline-grid; + place-items: center; + margin: 1rem 1rem 1rem 0; + -webkit-user-select: none; + user-select: none; +} + + +.docs-menu-align-right { + padding: 2rem 0; + border: 1px dashed var(--ui-color-accent); + text-align: right; +} + +.notification-center-header { + margin-bottom: 1rem; + display: flex; + flex-flow: row; + align-items: center; + justify-content: flex-start; + gap: 2rem; +} + +.notification-center-header h2 { + display: inline-block; + width: auto; + padding: 0; + margin: 0; +} + + +.prop-row { + padding: 1rem 0; + display: flex; + align-items: center; + justify-content: flex-start; + gap: 1rem; +} + +.panel p { margin: 0; } + +.tooltip-box { + display: inline-block; + margin: 10px 0 0; + line-height: 2.4em; + padding: 1em; + border: 1px solid #ccc; + min-width: 6em; + text-align: center; +} + +.tooltip-html h1, +.tooltip-html p { margin: 0; } +.tooltip-html b { color: var(--ui-color-accent); } +.tooltip-html a:hover { text-decoration: none; } + +.split-wrap { + width: 400px; + height: 200px; + border: 1px solid red; + display: flex; + flex-flow: row; + position: relative; +} + +.split-wrap-v { flex-flow: column; } +.split-box { border: 1px solid green; flex: 1; } + +.min-w { min-width: 20px; max-width: 220px; } +.min-h { min-height: 50px; max-height: 150px; } + +.table-viewport { + width: 500px; + max-width: 100%; + height: 500px; + border: 2px dashed red; + padding: 5px; +} + +.tooltip-box { + display: inline-block; + margin: 10px 0 0; + line-height: 2.4em; + padding: 1em; + border: 1px solid #ccc; + min-width: 6em; + text-align: center; +} + +.tooltip-html h1, +.tooltip-html p { margin: 0; } +.tooltip-html b { color: var(--ui-color-accent); } +.tooltip-html a:hover { text-decoration: none; } + +.section-utils { + --nav-sidebar-width: 240px; +} +.section-utils .dark-mode-switch { right: calc(var(--nav-sidebar-width) + 20px); } + +.section-utils .sticky-block { padding-bottom: 3rem; margin-right: var(--nav-sidebar-width); } + + +.section-utils .sticky-block .utility h3 { + scroll-margin-top: 4.2rem; + font-size: 1.1rem; + color: var(--ui-color-accent); + font-family: Consolas,Monaco,'Andale Mono','Ubuntu Mono',monospace; +} + + +.section-utils .utilities-nav { + position: fixed; + right: 0; + top: 0; + bottom: 0; + z-index: 52; + margin: 0; + padding: 1rem 2rem; + overflow-y: auto; + width: var(--nav-sidebar-width); + border-left: 1px solid var(--ui-color-border-2); + background-color: var(--ui-color-background-input); +} + +.section-utils .utility { + margin: 0 -2rem; + padding: 1rem 2rem; + border-bottom: 1px solid var(--ui-color-border-2); +} + + +.section-utils .btn-scroll-top { right: calc(var(--nav-sidebar-width) + 20px); } + + +@media (1px <= width <= 900px) { + .section-utils .dark-mode-switch { right: 0.6rem; } + .section-utils .btn-scroll-top { right: 1rem; } + .section-utils .sticky-block { margin-right: 0; } + .section-utils .utilities-nav { + position: static; + border-left: none; + width: auto; + z-index: initial; + margin-top: 2rem; + background-color: unset; + } + +} + +.button-toggle-wrapper-wide { width: 400px; max-width: 100%; } +.button-toggle-wrapper-wide .button-toggle { width: 100%; } + +.toggle-box { + margin: 10px 0 0; + line-height: 2.4em; + display: none; +} + +.toggle-box.visible { + display: block; +} +/*# sourceMappingURL=docs.css.map */ diff --git a/docs/docs.js b/docs/docs.js index 39c392d..c5f1d4c 100644 --- a/docs/docs.js +++ b/docs/docs.js @@ -1,68 +1,50965 @@ -var X2=Object.create;var vc=Object.defineProperty;var J2=Object.getOwnPropertyDescriptor;var Z2=Object.getOwnPropertyNames;var Q2=Object.getPrototypeOf,ev=Object.prototype.hasOwnProperty;var Kt=(t,e)=>()=>(e||t((e={exports:{}}).exports,e),e.exports),wc=(t,e)=>{for(var n in e)vc(t,n,{get:e[n],enumerable:!0})},tv=(t,e,n,i)=>{if(e&&typeof e=="object"||typeof e=="function")for(let o of Z2(e))!ev.call(t,o)&&o!==n&&vc(t,o,{get:()=>e[o],enumerable:!(i=J2(e,o))||i.enumerable});return t};var $c=(t,e,n)=>(n=t!=null?X2(Q2(t)):{},tv(e||!t||!t.__esModule?vc(n,"default",{value:t,enumerable:!0}):n,t));var Wi=Kt(ni=>{"use strict";Object.defineProperty(ni,"__esModule",{value:!0});ni.TraceDirectionKey=ni.Direction=ni.Axis=void 0;var lp;ni.TraceDirectionKey=lp;(function(t){t.NEGATIVE="NEGATIVE",t.POSITIVE="POSITIVE",t.NONE="NONE"})(lp||(ni.TraceDirectionKey=lp={}));var rp;ni.Direction=rp;(function(t){t.TOP="TOP",t.LEFT="LEFT",t.RIGHT="RIGHT",t.BOTTOM="BOTTOM",t.NONE="NONE"})(rp||(ni.Direction=rp={}));var ap;ni.Axis=ap;(function(t){t.X="x",t.Y="y"})(ap||(ni.Axis=ap={}))});var mp=Kt(fp=>{"use strict";Object.defineProperty(fp,"__esModule",{value:!0});fp.calculateDirection=f3;var up=Wi();function f3(t){var e,n=up.TraceDirectionKey.NEGATIVE,i=up.TraceDirectionKey.POSITIVE,o=t[t.length-1],r=t[t.length-2]||0;return t.every(function(a){return a===0})?up.TraceDirectionKey.NONE:(e=o>r?i:n,o===0&&(e=r<0?i:n),e)}});var eu=Kt(pi=>{"use strict";Object.defineProperty(pi,"__esModule",{value:!0});pi.resolveAxisDirection=pi.getDirectionValue=pi.getDirectionKey=pi.getDifference=void 0;var xn=Wi(),m3=function(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},n=Object.keys(e).toString();switch(n){case xn.TraceDirectionKey.POSITIVE:return xn.TraceDirectionKey.POSITIVE;case xn.TraceDirectionKey.NEGATIVE:return xn.TraceDirectionKey.NEGATIVE;default:return xn.TraceDirectionKey.NONE}};pi.getDirectionKey=m3;var c3=function(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[];return e[e.length-1]||0};pi.getDirectionValue=c3;var d3=function(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:0,n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0;return Math.abs(e-n)};pi.getDifference=d3;var p3=function(e,n){var i=xn.Direction.LEFT,o=xn.Direction.RIGHT,r=xn.Direction.NONE;return e===xn.Axis.Y&&(i=xn.Direction.BOTTOM,o=xn.Direction.TOP),n===xn.TraceDirectionKey.NEGATIVE&&(r=i),n===xn.TraceDirectionKey.POSITIVE&&(r=o),r};pi.resolveAxisDirection=p3});var dp=Kt(cp=>{"use strict";Object.defineProperty(cp,"__esModule",{value:!0});cp.calculateDirectionDelta=g3;var h3=Wi(),hs=eu();function g3(t){for(var e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0,n=t.length,i=n-1,o=h3.TraceDirectionKey.NONE;i>=0;i--){var r=t[i],a=(0,hs.getDirectionKey)(r),u=(0,hs.getDirectionValue)(r[a]),m=t[i-1]||{},f=(0,hs.getDirectionKey)(m),d=(0,hs.getDirectionValue)(m[f]),g=(0,hs.getDifference)(u,d);if(g>=e){o=a;break}else o=f}return o}});var hp=Kt(pp=>{"use strict";Object.defineProperty(pp,"__esModule",{value:!0});pp.calculateDuration=b3;function b3(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:0,e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0;return t?e-t:0}});var a0=Kt(gp=>{"use strict";Object.defineProperty(gp,"__esModule",{value:!0});gp.calculateMovingPosition=_3;function _3(t){if("changedTouches"in t){var e=t.changedTouches&&t.changedTouches[0];return{x:e&&e.clientX,y:e&&e.clientY}}return{x:t.clientX,y:t.clientY}}});var _p=Kt(bp=>{"use strict";Object.defineProperty(bp,"__esModule",{value:!0});bp.updateTrace=v3;function v3(t,e){var n=t[t.length-1];return n!==e&&t.push(e),t}});var wp=Kt(vp=>{"use strict";Object.defineProperty(vp,"__esModule",{value:!0});vp.calculateTraceDirections=w3;var tu=Wi();function u0(t,e,n){return e in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function w3(){for(var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[],e=[],n=tu.TraceDirectionKey.POSITIVE,i=tu.TraceDirectionKey.NEGATIVE,o=0,r=[],a=tu.TraceDirectionKey.NONE;om?n:i;a===tu.TraceDirectionKey.NONE&&(a=f),f===a?r.push(u):(e.push(u0({},a,r.slice())),r=[],r.push(u),a=f)}else u!==0&&(a=u>0?n:i),r.push(u)}return r.length&&e.push(u0({},a,r)),e}});var yp=Kt($p=>{"use strict";Object.defineProperty($p,"__esModule",{value:!0});$p.resolveDirection=M3;var $3=mp(),y3=wp(),k3=dp(),f0=eu(),T3=Wi();function M3(t){var e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:T3.Axis.X,n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:0;if(n){var i=(0,y3.calculateTraceDirections)(t),o=(0,k3.calculateDirectionDelta)(i,n);return(0,f0.resolveAxisDirection)(e,o)}var r=(0,$3.calculateDirection)(t);return(0,f0.resolveAxisDirection)(e,r)}});var Tp=Kt(kp=>{"use strict";Object.defineProperty(kp,"__esModule",{value:!0});kp.calculateVelocity=C3;function C3(t,e,n){var i=Math.sqrt(t*t+e*e);return i/(n||1)}});var p0=Kt(Mp=>{"use strict";Object.defineProperty(Mp,"__esModule",{value:!0});Mp.calculatePosition=L3;var m0=_p(),c0=yp(),E3=hp(),S3=Tp(),d0=Wi();function L3(t,e){var n=t.start,i=t.x,o=t.y,r=t.traceX,a=t.traceY,u=e.rotatePosition,m=e.directionDelta,f=u.x-i,d=o-u.y,g=Math.abs(f),_=Math.abs(d);(0,m0.updateTrace)(r,f),(0,m0.updateTrace)(a,d);var h=(0,c0.resolveDirection)(r,d0.Axis.X,m),b=(0,c0.resolveDirection)(a,d0.Axis.Y,m),$=(0,E3.calculateDuration)(n,Date.now()),k=(0,S3.calculateVelocity)(g,_,$);return{absX:g,absY:_,deltaX:f,deltaY:d,directionX:h,directionY:b,duration:$,positionX:u.x,positionY:u.y,velocity:k}}});var h0=Kt(nu=>{"use strict";Object.defineProperty(nu,"__esModule",{value:!0});nu.checkIsMoreThanSingleTouches=void 0;var D3=function(e){return!!(e.touches&&e.touches.length>1)};nu.checkIsMoreThanSingleTouches=D3});var Ep=Kt(Cp=>{"use strict";Object.defineProperty(Cp,"__esModule",{value:!0});Cp.createOptions=A3;function A3(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};return Object.defineProperty(t,"passive",{get:function(){return this.isPassiveSupported=!0,!0},enumerable:!0}),t}});var g0=Kt(gs=>{"use strict";Object.defineProperty(gs,"__esModule",{value:!0});gs.checkIsPassiveSupported=O3;gs.noop=void 0;var I3=Ep();function O3(t){if(typeof t=="boolean")return t;var e={isPassiveSupported:t};try{var n=(0,I3.createOptions)(e);window.addEventListener("checkIsPassiveSupported",Sp,n),window.removeEventListener("checkIsPassiveSupported",Sp,n)}catch{}return e.isPassiveSupported}var Sp=function(){};gs.noop=Sp});var b0=Kt(iu=>{"use strict";Object.defineProperty(iu,"__esModule",{value:!0});iu.checkIsTouchEventsSupported=void 0;function Lp(t){"@babel/helpers - typeof";return Lp=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(e){return typeof e}:function(e){return e&&typeof Symbol=="function"&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Lp(t)}var H3=function(){return(typeof window>"u"?"undefined":Lp(window))==="object"&&("ontouchstart"in window||!!window.navigator.maxTouchPoints)};iu.checkIsTouchEventsSupported=H3});var v0=Kt(ou=>{"use strict";Object.defineProperty(ou,"__esModule",{value:!0});ou.getInitialState=void 0;function _0(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(t);e&&(i=i.filter(function(o){return Object.getOwnPropertyDescriptor(t,o).enumerable})),n.push.apply(n,i)}return n}function x3(t){for(var e=1;e0&&arguments[0]!==void 0?arguments[0]:{};return x3({x:0,y:0,start:0,isSwiping:!1,traceX:[],traceY:[]},e)};ou.getInitialState=N3});var $0=Kt(su=>{"use strict";Object.defineProperty(su,"__esModule",{value:!0});su.getInitialProps=void 0;function w0(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(t);e&&(i=i.filter(function(o){return Object.getOwnPropertyDescriptor(t,o).enumerable})),n.push.apply(n,i)}return n}function F3(t){for(var e=1;e0&&arguments[0]!==void 0?arguments[0]:{};return F3({element:null,target:null,delta:10,directionDelta:0,rotationAngle:0,mouseTrackingEnabled:!1,touchTrackingEnabled:!0,preventDefaultTouchmoveEvent:!1,preventTrackingOnMouseleave:!1},e)};su.getInitialProps=B3});var y0=Kt(Dp=>{"use strict";Object.defineProperty(Dp,"__esModule",{value:!0});Dp.getOptions=R3;function R3(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!1;return t?{passive:!1}:{}}});var k0=Kt(Ap=>{"use strict";Object.defineProperty(Ap,"__esModule",{value:!0});Ap.rotateByAngle=z3;function z3(t){var e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0;if(e===0)return t;var n=t.x,i=t.y,o=Math.PI/180*e,r=n*Math.cos(o)+i*Math.sin(o),a=i*Math.cos(o)-n*Math.sin(o);return{x:r,y:a}}});var T0=Kt(et=>{"use strict";Object.defineProperty(et,"__esModule",{value:!0});var Ip=mp();Object.keys(Ip).forEach(function(t){t==="default"||t==="__esModule"||t in et&&et[t]===Ip[t]||Object.defineProperty(et,t,{enumerable:!0,get:function(){return Ip[t]}})});var Op=dp();Object.keys(Op).forEach(function(t){t==="default"||t==="__esModule"||t in et&&et[t]===Op[t]||Object.defineProperty(et,t,{enumerable:!0,get:function(){return Op[t]}})});var Hp=hp();Object.keys(Hp).forEach(function(t){t==="default"||t==="__esModule"||t in et&&et[t]===Hp[t]||Object.defineProperty(et,t,{enumerable:!0,get:function(){return Hp[t]}})});var xp=a0();Object.keys(xp).forEach(function(t){t==="default"||t==="__esModule"||t in et&&et[t]===xp[t]||Object.defineProperty(et,t,{enumerable:!0,get:function(){return xp[t]}})});var Pp=p0();Object.keys(Pp).forEach(function(t){t==="default"||t==="__esModule"||t in et&&et[t]===Pp[t]||Object.defineProperty(et,t,{enumerable:!0,get:function(){return Pp[t]}})});var Np=wp();Object.keys(Np).forEach(function(t){t==="default"||t==="__esModule"||t in et&&et[t]===Np[t]||Object.defineProperty(et,t,{enumerable:!0,get:function(){return Np[t]}})});var Fp=Tp();Object.keys(Fp).forEach(function(t){t==="default"||t==="__esModule"||t in et&&et[t]===Fp[t]||Object.defineProperty(et,t,{enumerable:!0,get:function(){return Fp[t]}})});var qp=h0();Object.keys(qp).forEach(function(t){t==="default"||t==="__esModule"||t in et&&et[t]===qp[t]||Object.defineProperty(et,t,{enumerable:!0,get:function(){return qp[t]}})});var Bp=g0();Object.keys(Bp).forEach(function(t){t==="default"||t==="__esModule"||t in et&&et[t]===Bp[t]||Object.defineProperty(et,t,{enumerable:!0,get:function(){return Bp[t]}})});var Rp=b0();Object.keys(Rp).forEach(function(t){t==="default"||t==="__esModule"||t in et&&et[t]===Rp[t]||Object.defineProperty(et,t,{enumerable:!0,get:function(){return Rp[t]}})});var zp=eu();Object.keys(zp).forEach(function(t){t==="default"||t==="__esModule"||t in et&&et[t]===zp[t]||Object.defineProperty(et,t,{enumerable:!0,get:function(){return zp[t]}})});var jp=Ep();Object.keys(jp).forEach(function(t){t==="default"||t==="__esModule"||t in et&&et[t]===jp[t]||Object.defineProperty(et,t,{enumerable:!0,get:function(){return jp[t]}})});var Wp=v0();Object.keys(Wp).forEach(function(t){t==="default"||t==="__esModule"||t in et&&et[t]===Wp[t]||Object.defineProperty(et,t,{enumerable:!0,get:function(){return Wp[t]}})});var Vp=$0();Object.keys(Vp).forEach(function(t){t==="default"||t==="__esModule"||t in et&&et[t]===Vp[t]||Object.defineProperty(et,t,{enumerable:!0,get:function(){return Vp[t]}})});var Up=y0();Object.keys(Up).forEach(function(t){t==="default"||t==="__esModule"||t in et&&et[t]===Up[t]||Object.defineProperty(et,t,{enumerable:!0,get:function(){return Up[t]}})});var Yp=yp();Object.keys(Yp).forEach(function(t){t==="default"||t==="__esModule"||t in et&&et[t]===Yp[t]||Object.defineProperty(et,t,{enumerable:!0,get:function(){return Yp[t]}})});var Gp=k0();Object.keys(Gp).forEach(function(t){t==="default"||t==="__esModule"||t in et&&et[t]===Gp[t]||Object.defineProperty(et,t,{enumerable:!0,get:function(){return Gp[t]}})});var Kp=_p();Object.keys(Kp).forEach(function(t){t==="default"||t==="__esModule"||t in et&&et[t]===Kp[t]||Object.defineProperty(et,t,{enumerable:!0,get:function(){return Kp[t]}})})});var S0=Kt(go=>{"use strict";function Jp(t){"@babel/helpers - typeof";return Jp=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(e){return typeof e}:function(e){return e&&typeof Symbol=="function"&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Jp(t)}Object.defineProperty(go,"__esModule",{value:!0});var j3={};go.default=void 0;var pn=W3(T0()),Xp=Wi();Object.keys(Xp).forEach(function(t){t==="default"||t==="__esModule"||Object.prototype.hasOwnProperty.call(j3,t)||t in go&&go[t]===Xp[t]||Object.defineProperty(go,t,{enumerable:!0,get:function(){return Xp[t]}})});function E0(t){if(typeof WeakMap!="function")return null;var e=new WeakMap,n=new WeakMap;return(E0=function(o){return o?n:e})(t)}function W3(t,e){if(!e&&t&&t.__esModule)return t;if(t===null||Jp(t)!=="object"&&typeof t!="function")return{default:t};var n=E0(e);if(n&&n.has(t))return n.get(t);var i={},o=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var r in t)if(r!=="default"&&Object.prototype.hasOwnProperty.call(t,r)){var a=o?Object.getOwnPropertyDescriptor(t,r):null;a&&(a.get||a.set)?Object.defineProperty(i,r,a):i[r]=t[r]}return i.default=t,n&&n.set(t,i),i}function V3(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function M0(t,e){for(var n=0;n1&&arguments[1]!==void 0?arguments[1]:{directionDelta:0},o=this.props.rotationAngle,r=i.directionDelta,a=pn.calculateMovingPosition(n),u=pn.rotateByAngle(a,o);return pn.calculatePosition(this.state,{rotatePosition:u,directionDelta:r})}},{key:"handleSwipeStart",value:function(n){if(!pn.checkIsMoreThanSingleTouches(n)){var i=this.props.rotationAngle,o=pn.calculateMovingPosition(n),r=pn.rotateByAngle(o,i),a=r.x,u=r.y;this.state=pn.getInitialState({isSwiping:!1,start:Date.now(),x:a,y:u})}}},{key:"handleSwipeMove",value:function(n){var i=this.state,o=i.x,r=i.y,a=i.isSwiping;if(!(!o||!r||pn.checkIsMoreThanSingleTouches(n))){var u=this.props.directionDelta||0,m=this.getEventData(n,{directionDelta:u}),f=m.absX,d=m.absY,g=m.deltaX,_=m.deltaY,h=m.directionX,b=m.directionY,$=m.duration,k=m.velocity,v=this.props,T=v.delta,I=v.preventDefaultTouchmoveEvent,D=v.onSwipeStart,L=v.onSwiping;n.cancelable&&I&&n.preventDefault(),!(f{var XM=typeof window<"u"?window:typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope?self:{};var Je=function(t){var e=/(?:^|\s)lang(?:uage)?-([\w-]+)(?=\s|$)/i,n=0,i={},o={manual:t.Prism&&t.Prism.manual,disableWorkerMessageHandler:t.Prism&&t.Prism.disableWorkerMessageHandler,util:{encode:function $(k){return k instanceof r?new r(k.type,$(k.content),k.alias):Array.isArray(k)?k.map($):k.replace(/&/g,"&").replace(/"u")return null;if("currentScript"in document&&1<2)return document.currentScript;try{throw new Error}catch(T){var $=(/at [^(\r\n]*\((.*):[^:]+:[^:]+\)$/i.exec(T.stack)||[])[1];if($){var k=document.getElementsByTagName("script");for(var v in k)if(k[v].src==$)return k[v]}return null}},isActive:function($,k,v){for(var T="no-"+k;$;){var I=$.classList;if(I.contains(k))return!0;if(I.contains(T))return!1;$=$.parentElement}return!!v}},languages:{plain:i,plaintext:i,text:i,txt:i,extend:function($,k){var v=o.util.clone(o.languages[$]);for(var T in k)v[T]=k[T];return v},insertBefore:function($,k,v,T){T=T||o.languages;var I=T[$],D={};for(var L in I)if(I.hasOwnProperty(L)){if(L==k)for(var M in v)v.hasOwnProperty(M)&&(D[M]=v[M]);v.hasOwnProperty(L)||(D[L]=I[L])}var A=T[$];return T[$]=D,o.languages.DFS(o.languages,function(x,O){O===A&&x!=$&&(this[x]=D)}),D},DFS:function $(k,v,T,I){I=I||{};var D=o.util.objId;for(var L in k)if(k.hasOwnProperty(L)){v.call(k,L,k[L],T||L);var M=k[L],A=o.util.type(M);A==="Object"&&!I[D(M)]?(I[D(M)]=!0,$(M,v,null,I)):A==="Array"&&!I[D(M)]&&(I[D(M)]=!0,$(M,v,L,I))}}},plugins:{},highlightAll:function($,k){o.highlightAllUnder(document,$,k)},highlightAllUnder:function($,k,v){var T={callback:v,container:$,selector:'code[class*="language-"], [class*="language-"] code, code[class*="lang-"], [class*="lang-"] code'};o.hooks.run("before-highlightall",T),T.elements=Array.prototype.slice.apply(T.container.querySelectorAll(T.selector)),o.hooks.run("before-all-elements-highlight",T);for(var I=0,D;D=T.elements[I++];)o.highlightElement(D,k===!0,T.callback)},highlightElement:function($,k,v){var T=o.util.getLanguage($),I=o.languages[T];o.util.setLanguage($,T);var D=$.parentElement;D&&D.nodeName.toLowerCase()==="pre"&&o.util.setLanguage(D,T);var L=$.textContent,M={element:$,language:T,grammar:I,code:L};function A(O){M.highlightedCode=O,o.hooks.run("before-insert",M),M.element.innerHTML=M.highlightedCode,o.hooks.run("after-highlight",M),o.hooks.run("complete",M),v&&v.call(M.element)}if(o.hooks.run("before-sanity-check",M),D=M.element.parentElement,D&&D.nodeName.toLowerCase()==="pre"&&!D.hasAttribute("tabindex")&&D.setAttribute("tabindex","0"),!M.code){o.hooks.run("complete",M),v&&v.call(M.element);return}if(o.hooks.run("before-highlight",M),!M.grammar){A(o.util.encode(M.code));return}if(k&&t.Worker){var x=new Worker(o.filename);x.onmessage=function(O){A(O.data)},x.postMessage(JSON.stringify({language:M.language,code:M.code,immediateClose:!0}))}else A(o.highlight(M.code,M.grammar,M.language))},highlight:function($,k,v){var T={code:$,grammar:k,language:v};if(o.hooks.run("before-tokenize",T),!T.grammar)throw new Error('The language "'+T.language+'" has no grammar.');return T.tokens=o.tokenize(T.code,T.grammar),o.hooks.run("after-tokenize",T),r.stringify(o.util.encode(T.tokens),T.language)},tokenize:function($,k){var v=k.rest;if(v){for(var T in v)k[T]=v[T];delete k.rest}var I=new m;return f(I,I.head,$),u($,I,k,I.head,0),g(I)},hooks:{all:{},add:function($,k){var v=o.hooks.all;v[$]=v[$]||[],v[$].push(k)},run:function($,k){var v=o.hooks.all[$];if(!(!v||!v.length))for(var T=0,I;I=v[T++];)I(k)}},Token:r};t.Prism=o;function r($,k,v,T){this.type=$,this.content=k,this.alias=v,this.length=(T||"").length|0}r.stringify=function $(k,v){if(typeof k=="string")return k;if(Array.isArray(k)){var T="";return k.forEach(function(A){T+=$(A,v)}),T}var I={type:k.type,content:$(k.content,v),tag:"span",classes:["token",k.type],attributes:{},language:v},D=k.alias;D&&(Array.isArray(D)?Array.prototype.push.apply(I.classes,D):I.classes.push(D)),o.hooks.run("wrap",I);var L="";for(var M in I.attributes)L+=" "+M+'="'+(I.attributes[M]||"").replace(/"/g,""")+'"';return"<"+I.tag+' class="'+I.classes.join(" ")+'"'+L+">"+I.content+""};function a($,k,v,T){$.lastIndex=k;var I=$.exec(v);if(I&&T&&I[1]){var D=I[1].length;I.index+=D,I[0]=I[0].slice(D)}return I}function u($,k,v,T,I,D){for(var L in v)if(!(!v.hasOwnProperty(L)||!v[L])){var M=v[L];M=Array.isArray(M)?M:[M];for(var A=0;A=D.reach);P+=U.value.length,U=U.next){var j=U.value;if(k.length>$.length)return;if(!(j instanceof r)){var Y=1,Z;if(F){if(Z=a(z,P,$,N),!Z||Z.index>=$.length)break;var J=Z.index,le=Z.index+Z[0].length,ee=P;for(ee+=U.value.length;J>=ee;)U=U.next,ee+=U.value.length;if(ee-=U.value.length,P=ee,U.value instanceof r)continue;for(var X=U;X!==k.tail&&(eeD.reach&&(D.reach=G);var Q=U.prev;he&&(Q=f(k,Q,he),P+=he.length),d(k,Q,Y);var pe=new r(L,O?o.tokenize(ge,O):ge,W,ge);if(U=f(k,Q,pe),V&&f(k,U,V),Y>1){var ye={cause:L+","+A,reach:G};u($,k,v,U.prev,P,ye),D&&ye.reach>D.reach&&(D.reach=ye.reach)}}}}}}function m(){var $={value:null,prev:null,next:null},k={value:null,prev:$,next:null};$.next=k,this.head=$,this.tail=k,this.length=0}function f($,k,v){var T=k.next,I={value:v,prev:k,next:T};return k.next=I,T.prev=I,$.length++,I}function d($,k,v){for(var T=k.next,I=0;I/,greedy:!0},prolog:{pattern:/<\?[\s\S]+?\?>/,greedy:!0},doctype:{pattern:/"'[\]]|"[^"]*"|'[^']*')+(?:\[(?:[^<"'\]]|"[^"]*"|'[^']*'|<(?!!--)|)*\]\s*)?>/i,greedy:!0,inside:{"internal-subset":{pattern:/(^[^\[]*\[)[\s\S]+(?=\]>$)/,lookbehind:!0,greedy:!0,inside:null},string:{pattern:/"[^"]*"|'[^']*'/,greedy:!0},punctuation:/^$|[[\]]/,"doctype-tag":/^DOCTYPE/i,name:/[^\s<>'"]+/}},cdata:{pattern://i,greedy:!0},tag:{pattern:/<\/?(?!\d)[^\s>\/=$<%]+(?:\s(?:\s*[^\s>\/=]+(?:\s*=\s*(?:"[^"]*"|'[^']*'|[^\s'">=]+(?=[\s>]))|(?=[\s/>])))+)?\s*\/?>/,greedy:!0,inside:{tag:{pattern:/^<\/?[^\s>\/]+/,inside:{punctuation:/^<\/?/,namespace:/^[^\s>\/:]+:/}},"special-attr":[],"attr-value":{pattern:/=\s*(?:"[^"]*"|'[^']*'|[^\s'">=]+)/,inside:{punctuation:[{pattern:/^=/,alias:"attr-equals"},{pattern:/^(\s*)["']|["']$/,lookbehind:!0}]}},punctuation:/\/?>/,"attr-name":{pattern:/[^\s>\/]+/,inside:{namespace:/^[^\s>\/:]+:/}}}},entity:[{pattern:/&[\da-z]{1,8};/i,alias:"named-entity"},/&#x?[\da-f]{1,8};/i]};Je.languages.markup.tag.inside["attr-value"].inside.entity=Je.languages.markup.entity;Je.languages.markup.doctype.inside["internal-subset"].inside=Je.languages.markup;Je.hooks.add("wrap",function(t){t.type==="entity"&&(t.attributes.title=t.content.replace(/&/,"&"))});Object.defineProperty(Je.languages.markup.tag,"addInlined",{value:function(e,n){var i={};i["language-"+n]={pattern:/(^$)/i,lookbehind:!0,inside:Je.languages[n]},i.cdata=/^$/i;var o={"included-cdata":{pattern://i,inside:i}};o["language-"+n]={pattern:/[\s\S]+/,inside:Je.languages[n]};var r={};r[e]={pattern:RegExp(/(<__[^>]*>)(?:))*\]\]>|(?!)/.source.replace(/__/g,function(){return e}),"i"),lookbehind:!0,greedy:!0,inside:o},Je.languages.insertBefore("markup","cdata",r)}});Object.defineProperty(Je.languages.markup.tag,"addAttribute",{value:function(t,e){Je.languages.markup.tag.inside["special-attr"].push({pattern:RegExp(/(^|["'\s])/.source+"(?:"+t+")"+/\s*=\s*(?:"[^"]*"|'[^']*'|[^\s'">=]+(?=[\s>]))/.source,"i"),lookbehind:!0,inside:{"attr-name":/^[^\s=]+/,"attr-value":{pattern:/=[\s\S]+/,inside:{value:{pattern:/(^=\s*(["']|(?!["'])))\S[\s\S]*(?=\2$)/,lookbehind:!0,alias:[e,"language-"+e],inside:Je.languages[e]},punctuation:[{pattern:/^=/,alias:"attr-equals"},/"|'/]}}}})}});Je.languages.html=Je.languages.markup;Je.languages.mathml=Je.languages.markup;Je.languages.svg=Je.languages.markup;Je.languages.xml=Je.languages.extend("markup",{});Je.languages.ssml=Je.languages.xml;Je.languages.atom=Je.languages.xml;Je.languages.rss=Je.languages.xml;(function(t){var e=/(?:"(?:\\(?:\r\n|[\s\S])|[^"\\\r\n])*"|'(?:\\(?:\r\n|[\s\S])|[^'\\\r\n])*')/;t.languages.css={comment:/\/\*[\s\S]*?\*\//,atrule:{pattern:RegExp("@[\\w-](?:"+/[^;{\s"']|\s+(?!\s)/.source+"|"+e.source+")*?"+/(?:;|(?=\s*\{))/.source),inside:{rule:/^@[\w-]+/,"selector-function-argument":{pattern:/(\bselector\s*\(\s*(?![\s)]))(?:[^()\s]|\s+(?![\s)])|\((?:[^()]|\([^()]*\))*\))+(?=\s*\))/,lookbehind:!0,alias:"selector"},keyword:{pattern:/(^|[^\w-])(?:and|not|only|or)(?![\w-])/,lookbehind:!0}}},url:{pattern:RegExp("\\burl\\((?:"+e.source+"|"+/(?:[^\\\r\n()"']|\\[\s\S])*/.source+")\\)","i"),greedy:!0,inside:{function:/^url/i,punctuation:/^\(|\)$/,string:{pattern:RegExp("^"+e.source+"$"),alias:"url"}}},selector:{pattern:RegExp(`(^|[{}\\s])[^{}\\s](?:[^{};"'\\s]|\\s+(?![\\s{])|`+e.source+")*(?=\\s*\\{)"),lookbehind:!0},string:{pattern:e,greedy:!0},property:{pattern:/(^|[^-\w\xA0-\uFFFF])(?!\s)[-_a-z\xA0-\uFFFF](?:(?!\s)[-\w\xA0-\uFFFF])*(?=\s*:)/i,lookbehind:!0},important:/!important\b/i,function:{pattern:/(^|[^-a-z0-9])[-a-z0-9]+(?=\()/i,lookbehind:!0},punctuation:/[(){};:,]/},t.languages.css.atrule.inside.rest=t.languages.css;var n=t.languages.markup;n&&(n.tag.addInlined("style","css"),n.tag.addAttribute("style","css"))})(Je);Je.languages.clike={comment:[{pattern:/(^|[^\\])\/\*[\s\S]*?(?:\*\/|$)/,lookbehind:!0,greedy:!0},{pattern:/(^|[^\\:])\/\/.*/,lookbehind:!0,greedy:!0}],string:{pattern:/(["'])(?:\\(?:\r\n|[\s\S])|(?!\1)[^\\\r\n])*\1/,greedy:!0},"class-name":{pattern:/(\b(?:class|extends|implements|instanceof|interface|new|trait)\s+|\bcatch\s+\()[\w.\\]+/i,lookbehind:!0,inside:{punctuation:/[.\\]/}},keyword:/\b(?:break|catch|continue|do|else|finally|for|function|if|in|instanceof|new|null|return|throw|try|while)\b/,boolean:/\b(?:false|true)\b/,function:/\b\w+(?=\()/,number:/\b0x[\da-f]+\b|(?:\b\d+(?:\.\d*)?|\B\.\d+)(?:e[+-]?\d+)?/i,operator:/[<>]=?|[!=]=?=?|--?|\+\+?|&&?|\|\|?|[?*/~^%]/,punctuation:/[{}[\];(),.:]/};Je.languages.javascript=Je.languages.extend("clike",{"class-name":[Je.languages.clike["class-name"],{pattern:/(^|[^$\w\xA0-\uFFFF])(?!\s)[_$A-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\.(?:constructor|prototype))/,lookbehind:!0}],keyword:[{pattern:/((?:^|\})\s*)catch\b/,lookbehind:!0},{pattern:/(^|[^.]|\.\.\.\s*)\b(?:as|assert(?=\s*\{)|async(?=\s*(?:function\b|\(|[$\w\xA0-\uFFFF]|$))|await|break|case|class|const|continue|debugger|default|delete|do|else|enum|export|extends|finally(?=\s*(?:\{|$))|for|from(?=\s*(?:['"]|$))|function|(?:get|set)(?=\s*(?:[#\[$\w\xA0-\uFFFF]|$))|if|implements|import|in|instanceof|interface|let|new|null|of|package|private|protected|public|return|static|super|switch|this|throw|try|typeof|undefined|var|void|while|with|yield)\b/,lookbehind:!0}],function:/#?(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*(?:\.\s*(?:apply|bind|call)\s*)?\()/,number:{pattern:RegExp(/(^|[^\w$])/.source+"(?:"+(/NaN|Infinity/.source+"|"+/0[bB][01]+(?:_[01]+)*n?/.source+"|"+/0[oO][0-7]+(?:_[0-7]+)*n?/.source+"|"+/0[xX][\dA-Fa-f]+(?:_[\dA-Fa-f]+)*n?/.source+"|"+/\d+(?:_\d+)*n/.source+"|"+/(?:\d+(?:_\d+)*(?:\.(?:\d+(?:_\d+)*)?)?|\.\d+(?:_\d+)*)(?:[Ee][+-]?\d+(?:_\d+)*)?/.source)+")"+/(?![\w$])/.source),lookbehind:!0},operator:/--|\+\+|\*\*=?|=>|&&=?|\|\|=?|[!=]==|<<=?|>>>?=?|[-+*/%&|^!=<>]=?|\.{3}|\?\?=?|\?\.?|[~:]/});Je.languages.javascript["class-name"][0].pattern=/(\b(?:class|extends|implements|instanceof|interface|new)\s+)[\w.\\]+/;Je.languages.insertBefore("javascript","keyword",{regex:{pattern:RegExp(/((?:^|[^$\w\xA0-\uFFFF."'\])\s]|\b(?:return|yield))\s*)/.source+/\//.source+"(?:"+/(?:\[(?:[^\]\\\r\n]|\\.)*\]|\\.|[^/\\\[\r\n])+\/[dgimyus]{0,7}/.source+"|"+/(?:\[(?:[^[\]\\\r\n]|\\.|\[(?:[^[\]\\\r\n]|\\.|\[(?:[^[\]\\\r\n]|\\.)*\])*\])*\]|\\.|[^/\\\[\r\n])+\/[dgimyus]{0,7}v[dgimyus]{0,7}/.source+")"+/(?=(?:\s|\/\*(?:[^*]|\*(?!\/))*\*\/)*(?:$|[\r\n,.;:})\]]|\/\/))/.source),lookbehind:!0,greedy:!0,inside:{"regex-source":{pattern:/^(\/)[\s\S]+(?=\/[a-z]*$)/,lookbehind:!0,alias:"language-regex",inside:Je.languages.regex},"regex-delimiter":/^\/|\/$/,"regex-flags":/^[a-z]+$/}},"function-variable":{pattern:/#?(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*[=:]\s*(?:async\s*)?(?:\bfunction\b|(?:\((?:[^()]|\([^()]*\))*\)|(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*)\s*=>))/,alias:"function"},parameter:[{pattern:/(function(?:\s+(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*)?\s*\(\s*)(?!\s)(?:[^()\s]|\s+(?![\s)])|\([^()]*\))+(?=\s*\))/,lookbehind:!0,inside:Je.languages.javascript},{pattern:/(^|[^$\w\xA0-\uFFFF])(?!\s)[_$a-z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*=>)/i,lookbehind:!0,inside:Je.languages.javascript},{pattern:/(\(\s*)(?!\s)(?:[^()\s]|\s+(?![\s)])|\([^()]*\))+(?=\s*\)\s*=>)/,lookbehind:!0,inside:Je.languages.javascript},{pattern:/((?:\b|\s|^)(?!(?:as|async|await|break|case|catch|class|const|continue|debugger|default|delete|do|else|enum|export|extends|finally|for|from|function|get|if|implements|import|in|instanceof|interface|let|new|null|of|package|private|protected|public|return|set|static|super|switch|this|throw|try|typeof|undefined|var|void|while|with|yield)(?![$\w\xA0-\uFFFF]))(?:(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*\s*)\(\s*|\]\s*\(\s*)(?!\s)(?:[^()\s]|\s+(?![\s)])|\([^()]*\))+(?=\s*\)\s*\{)/,lookbehind:!0,inside:Je.languages.javascript}],constant:/\b[A-Z](?:[A-Z_]|\dx?)*\b/});Je.languages.insertBefore("javascript","string",{hashbang:{pattern:/^#!.*/,greedy:!0,alias:"comment"},"template-string":{pattern:/`(?:\\[\s\S]|\$\{(?:[^{}]|\{(?:[^{}]|\{[^}]*\})*\})+\}|(?!\$\{)[^\\`])*`/,greedy:!0,inside:{"template-punctuation":{pattern:/^`|`$/,alias:"string"},interpolation:{pattern:/((?:^|[^\\])(?:\\{2})*)\$\{(?:[^{}]|\{(?:[^{}]|\{[^}]*\})*\})+\}/,lookbehind:!0,inside:{"interpolation-punctuation":{pattern:/^\$\{|\}$/,alias:"punctuation"},rest:Je.languages.javascript}},string:/[\s\S]+/}},"string-property":{pattern:/((?:^|[,{])[ \t]*)(["'])(?:\\(?:\r\n|[\s\S])|(?!\2)[^\\\r\n])*\2(?=\s*:)/m,lookbehind:!0,greedy:!0,alias:"property"}});Je.languages.insertBefore("javascript","operator",{"literal-property":{pattern:/((?:^|[,{])[ \t]*)(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*:)/m,lookbehind:!0,alias:"property"}});Je.languages.markup&&(Je.languages.markup.tag.addInlined("script","javascript"),Je.languages.markup.tag.addAttribute(/on(?:abort|blur|change|click|composition(?:end|start|update)|dblclick|error|focus(?:in|out)?|key(?:down|up)|load|mouse(?:down|enter|leave|move|out|over|up)|reset|resize|scroll|select|slotchange|submit|unload|wheel)/.source,"javascript"));Je.languages.js=Je.languages.javascript;(function(){if(typeof Je>"u"||typeof document>"u")return;Element.prototype.matches||(Element.prototype.matches=Element.prototype.msMatchesSelector||Element.prototype.webkitMatchesSelector);var t="Loading\u2026",e=function(_,h){return"\u2716 Error "+_+" while fetching file: "+h},n="\u2716 Error: File does not exist or is empty",i={js:"javascript",py:"python",rb:"ruby",ps1:"powershell",psm1:"powershell",sh:"bash",bat:"batch",h:"c",tex:"latex"},o="data-src-status",r="loading",a="loaded",u="failed",m="pre[data-src]:not(["+o+'="'+a+'"]):not(['+o+'="'+r+'"])';function f(_,h,b){var $=new XMLHttpRequest;$.open("GET",_,!0),$.onreadystatechange=function(){$.readyState==4&&($.status<400&&$.responseText?h($.responseText):$.status>=400?b(e($.status,$.statusText)):b(n))},$.send(null)}function d(_){var h=/^\s*(\d+)\s*(?:(,)\s*(?:(\d+)\s*)?)?$/.exec(_||"");if(h){var b=Number(h[1]),$=h[2],k=h[3];return $?k?[b,Number(k)]:[b,void 0]:[b,b]}}Je.hooks.add("before-highlightall",function(_){_.selector+=", "+m}),Je.hooks.add("before-sanity-check",function(_){var h=_.element;if(h.matches(m)){_.code="",h.setAttribute(o,r);var b=h.appendChild(document.createElement("CODE"));b.textContent=t;var $=h.getAttribute("data-src"),k=_.language;if(k==="none"){var v=(/\.(\w+)$/.exec($)||[,"none"])[1];k=i[v]||v}Je.util.setLanguage(b,k),Je.util.setLanguage(h,k);var T=Je.plugins.autoloader;T&&T.loadLanguages(k),f($,function(I){h.setAttribute(o,a);var D=d(h.getAttribute("data-range"));if(D){var L=I.split(/\r\n?|\n/g),M=D[0],A=D[1]==null?L.length:D[1];M<0&&(M+=L.length),M=Math.max(0,Math.min(M-1,L.length)),A<0&&(A+=L.length),A=Math.max(0,Math.min(A,L.length)),I=L.slice(M,A).join(` -`),h.hasAttribute("data-start")||h.setAttribute("data-start",String(M+1))}b.textContent=I,Je.highlightElement(b)},function(I){h.setAttribute(o,u),b.textContent=I})}}),Je.plugins.fileHighlight={highlight:function(h){for(var b=(h||document).querySelectorAll(m),$=0,k;k=b[$++];)Je.highlightElement(k)}};var g=!1;Je.fileHighlight=function(){g||(console.warn("Prism.fileHighlight is deprecated. Use `Prism.plugins.fileHighlight.highlight` instead."),g=!0),Je.plugins.fileHighlight.highlight.apply(this,arguments)}})()});var K2=Kt((sV,ru)=>{(function(){if(typeof Prism>"u")return;var t=Object.assign||function(r,a){for(var u in a)a.hasOwnProperty(u)&&(r[u]=a[u]);return r};function e(r){this.defaults=t({},r)}function n(r){return r.replace(/-(\w)/g,function(a,u){return u.toUpperCase()})}function i(r){for(var a=0,u=0;ua&&(f[g]=` -`+f[g],d=_)}u[m]=f.join("")}return u.join(` -`)}},typeof ru<"u"&&ru.exports&&(ru.exports=e),Prism.plugins.NormalizeWhitespace=new e({"remove-trailing":!0,"remove-indent":!0,"left-trim":!0,"right-trim":!0}),Prism.hooks.add("before-sanity-check",function(r){var a=Prism.plugins.NormalizeWhitespace;if(!(r.settings&&r.settings["whitespace-normalization"]===!1)&&Prism.util.isActive(r.element,"whitespace-normalization",!0)){if((!r.element||!r.element.parentNode)&&r.code){r.code=a.normalize(r.code,r.settings);return}var u=r.element.parentNode;if(!(!r.code||!u||u.nodeName.toLowerCase()!=="pre")){r.settings==null&&(r.settings={});for(var m in o)if(Object.hasOwnProperty.call(o,m)){var f=o[m];if(u.hasAttribute("data-"+m))try{var d=JSON.parse(u.getAttribute("data-"+m)||"true");typeof d===f&&(r.settings[m]=d)}catch{}}for(var g=u.childNodes,_="",h="",b=!1,$=0;$t;function tt(t,e){for(let n in e)t[n]=e[n];return t}function yc(t){return t()}function ga(){return Object.create(null)}function qe(t){t.forEach(yc)}function vt(t){return typeof t=="function"}function fe(t,e){return t!=t?e==e:t!==e||t&&typeof t=="object"||typeof t=="function"}var ha;function jg(t,e){return t===e?!0:(ha||(ha=document.createElement("a")),ha.href=e,t===ha.href)}function Wg(t){return Object.keys(t).length===0}function on(t,...e){if(t==null){for(let i of e)i(void 0);return Te}let n=t.subscribe(...e);return n.unsubscribe?()=>n.unsubscribe():n}function tn(t){let e;return on(t,n=>e=n)(),e}function dn(t,e,n){t.$$.on_destroy.push(on(e,n))}function At(t,e,n,i){if(t){let o=Vg(t,e,n,i);return t[0](o)}}function Vg(t,e,n,i){return t[1]&&i?tt(n.ctx.slice(),t[1](i(e))):n.ctx}function It(t,e,n,i){if(t[2]&&i){let o=t[2](i(n));if(e.dirty===void 0)return o;if(typeof o=="object"){let r=[],a=Math.max(e.dirty.length,o.length);for(let u=0;u32){let e=[],n=t.ctx.length/32;for(let i=0;iwindow.performance.now():()=>Date.now(),Wo=Yg?t=>requestAnimationFrame(t):Te;var ko=new Set;function Gg(t){ko.forEach(e=>{e.c(t)||(ko.delete(e),e.f())}),ko.size!==0&&Wo(Gg)}function To(t){let e;return ko.size===0&&Wo(Gg),{promise:new Promise(n=>{ko.add(e={c:t,f:n})}),abort(){ko.delete(e)}}}var Vo=typeof window<"u"?window:typeof globalThis<"u"?globalThis:global;var _a=class t{_listeners="WeakMap"in Vo?new WeakMap:void 0;_observer=void 0;options;constructor(e){this.options=e}observe(e,n){return this._listeners.set(e,n),this._getObserver().observe(e,this.options),()=>{this._listeners.delete(e),this._observer.unobserve(e)}}_getObserver(){return this._observer??(this._observer=new ResizeObserver(e=>{for(let n of e)t.entries.set(n.target,n),this._listeners.get(n.target)?.(n)}))}};_a.entries="WeakMap"in Vo?new WeakMap:void 0;var Kg=!1;function Xg(){Kg=!0}function Jg(){Kg=!1}function q(t,e){t.appendChild(e)}function Tc(t){if(!t)return document;let e=t.getRootNode?t.getRootNode():t.ownerDocument;return e&&e.host?e:t.ownerDocument}function Zg(t){let e=p("style");return e.textContent="/* empty */",iv(Tc(t),e),e.sheet}function iv(t,e){return q(t.head||t,e),e.sheet}function l(t,e,n){t.insertBefore(e,n||null)}function s(t){t.parentNode&&t.parentNode.removeChild(t)}function bt(t,e){for(let n=0;nt.removeEventListener(e,n,i)}function Xn(t){return function(e){return e.preventDefault(),t.call(this,e)}}function va(t){return function(e){return e.stopPropagation(),t.call(this,e)}}function H(t,e,n){n==null?t.removeAttribute(e):t.getAttribute(e)!==n&&t.setAttribute(e,n)}var ov=["width","height"];function St(t,e){let n=Object.getOwnPropertyDescriptors(t.__proto__);for(let i in e)e[i]==null?t.removeAttribute(i):i==="style"?t.style.cssText=e[i]:i==="__value"?t.value=t[i]=e[i]:n[i]&&n[i].set&&ov.indexOf(i)===-1?t[i]=e[i]:H(t,i,e[i])}function Qg(t){return t===""?null:+t}function e1(t){return Array.from(t.childNodes)}function Be(t,e){e=""+e,t.data!==e&&(t.data=e)}function pt(t,e){t.value=e??""}function Pt(t,e,n,i){n==null?t.style.removeProperty(e):t.style.setProperty(e,n,i?"important":"")}function Mc(t,e,n){for(let i=0;i{e[n.slot||"default"]=!0}),e}function Ii(t,e){return new t(e)}var wa=new Map,$a=0;function sv(t){let e=5381,n=t.length;for(;n--;)e=(e<<5)-e^t.charCodeAt(n);return e>>>0}function lv(t,e){let n={stylesheet:Zg(e),rules:{}};return wa.set(t,n),n}function Ki(t,e,n,i,o,r,a,u=0){let m=16.666/i,f=`{ -`;for(let k=0;k<=1;k+=m){let v=e+(n-e)*r(k);f+=k*100+`%{${a(v,1-v)}} -`}let d=f+`100% {${a(n,1-n)}} -}`,g=`__svelte_${sv(d)}_${u}`,_=Tc(t),{stylesheet:h,rules:b}=wa.get(_)||lv(_,t);b[g]||(b[g]=!0,h.insertRule(`@keyframes ${g} ${d}`,h.cssRules.length));let $=t.style.animation||"";return t.style.animation=`${$?`${$}, `:""}${g} ${i}ms linear ${o}ms 1 both`,$a+=1,g}function Xi(t,e){let n=(t.style.animation||"").split(", "),i=n.filter(e?r=>r.indexOf(e)<0:r=>r.indexOf("__svelte")===-1),o=n.length-i.length;o&&(t.style.animation=i.join(", "),$a-=o,$a||rv())}function rv(){Wo(()=>{$a||(wa.forEach(t=>{let{ownerNode:e}=t.stylesheet;e&&s(e)}),wa.clear())})}function ya(t,e,n,i){if(!e)return Te;let o=t.getBoundingClientRect();if(e.left===o.left&&e.right===o.right&&e.top===o.top&&e.bottom===o.bottom)return Te;let{delay:r=0,duration:a=300,easing:u=Di,start:m=yo()+r,end:f=m+a,tick:d=Te,css:g}=n(t,{from:e,to:o},i),_=!0,h=!1,b;function $(){g&&(b=Ki(t,0,1,a,r,u,g)),r||(h=!0)}function k(){g&&Xi(t,b),_=!1}return To(v=>{if(!h&&v>=m&&(h=!0),h&&v>=f&&(d(1,0),k()),!_)return!1;if(h){let T=v-m,I=0+1*u(T/a);d(I,1-I)}return!0}),$(),d(0,1),k}function ka(t){let e=getComputedStyle(t);if(e.position!=="absolute"&&e.position!=="fixed"){let{width:n,height:i}=e,o=t.getBoundingClientRect();t.style.position="absolute",t.style.width=n,t.style.height=i,Go(t,o)}}function Go(t,e){let n=t.getBoundingClientRect();if(e.left!==n.left||e.top!==n.top){let i=getComputedStyle(t),o=i.transform==="none"?"":i.transform;t.style.transform=`${o} translate(${e.left-n.left}px, ${e.top-n.top}px)`}}var Oi;function wi(t){Oi=t}function Hi(){if(!Oi)throw new Error("Function called outside component initialization");return Oi}function Ko(t){Hi().$$.before_update.push(t)}function Nt(t){Hi().$$.on_mount.push(t)}function In(t){Hi().$$.after_update.push(t)}function an(t){Hi().$$.on_destroy.push(t)}function lt(){let t=Hi();return(e,n,{cancelable:i=!1}={})=>{let o=t.$$.callbacks[e];if(o){let r=Yo(e,n,{cancelable:i});return o.slice().forEach(a=>{a.call(t,r)}),!r.defaultPrevented}return!0}}function Cc(t,e){return Hi().$$.context.set(t,e),e}function Ec(t){return Hi().$$.context.get(t)}function Qe(t,e){let n=t.$$.callbacks[e.type];n&&n.slice().forEach(i=>i.call(this,e))}var Ji=[];var be=[],Co=[],Lc=[],av=Promise.resolve(),Dc=!1;function i1(){Dc||(Dc=!0,av.then(Ct))}function nn(t){Co.push(t)}function Ye(t){Lc.push(t)}var Sc=new Set,Mo=0;function Ct(){if(Mo!==0)return;let t=Oi;do{try{for(;Mot.indexOf(i)===-1?e.push(i):n.push(i)),n.forEach(i=>i()),Co=e}var Xo;function Ac(){return Xo||(Xo=Promise.resolve(),Xo.then(()=>{Xo=null})),Xo}function Zi(t,e,n){t.dispatchEvent(Yo(`${e?"intro":"outro"}${n}`))}var Ta=new Set,ri;function We(){ri={r:0,c:[],p:ri}}function Ve(){ri.r||qe(ri.c),ri=ri.p}function w(t,e){t&&t.i&&(Ta.delete(t),t.i(e))}function y(t,e,n,i){if(t&&t.o){if(Ta.has(t))return;Ta.add(t),ri.c.push(()=>{Ta.delete(t),i&&(n&&t.d(1),i())}),t.o(e)}else i&&i()}var Ic={duration:0};function Eo(t,e,n){let i={direction:"in"},o=e(t,n,i),r=!1,a,u,m=0;function f(){a&&Xi(t,a)}function d(){let{delay:_=0,duration:h=300,easing:b=Di,tick:$=Te,css:k}=o||Ic;k&&(a=Ki(t,0,1,h,_,b,k,m++)),$(0,1);let v=yo()+_,T=v+h;u&&u.abort(),r=!0,nn(()=>Zi(t,!0,"start")),u=To(I=>{if(r){if(I>=T)return $(1,0),Zi(t,!0,"end"),f(),r=!1;if(I>=v){let D=b((I-v)/h);$(D,1-D)}}return r})}let g=!1;return{start(){g||(g=!0,Xi(t),vt(o)?(o=o(i),Ac().then(d)):d())},invalidate(){g=!1},end(){r&&(f(),r=!1)}}}function So(t,e,n){let i={direction:"out"},o=e(t,n,i),r=!0,a,u=ri;u.r+=1;let m;function f(){let{delay:d=0,duration:g=300,easing:_=Di,tick:h=Te,css:b}=o||Ic;b&&(a=Ki(t,1,0,g,d,_,b));let $=yo()+d,k=$+g;nn(()=>Zi(t,!1,"start")),"inert"in t&&(m=t.inert,t.inert=!0),To(v=>{if(r){if(v>=k)return h(0,1),Zi(t,!1,"end"),--u.r||qe(u.c),!1;if(v>=$){let T=_((v-$)/g);h(1-T,T)}}return r})}return vt(o)?Ac().then(()=>{o=o(i),f()}):f(),{end(d){d&&"inert"in t&&(t.inert=m),d&&o.tick&&o.tick(1,0),r&&(a&&Xi(t,a),r=!1)}}}function Oc(t,e,n,i){let r=e(t,n,{direction:"both"}),a=i?0:1,u=null,m=null,f=null,d;function g(){f&&Xi(t,f)}function _(b,$){let k=b.b-a;return $*=Math.abs(k),{a,b:b.b,d:k,duration:$,start:b.start,end:b.start+$,group:b.group}}function h(b){let{delay:$=0,duration:k=300,easing:v=Di,tick:T=Te,css:I}=r||Ic,D={start:yo()+$,b};b||(D.group=ri,ri.r+=1),"inert"in t&&(b?d!==void 0&&(t.inert=d):(d=t.inert,t.inert=!0)),u||m?m=D:(I&&(g(),f=Ki(t,a,b,k,$,v,I)),b&&T(0,1),u=_(D,k),nn(()=>Zi(t,b,"start")),To(L=>{if(m&&L>m.start&&(u=_(m,k),m=null,Zi(t,u.b,"start"),I&&(g(),f=Ki(t,a,u.b,u.duration,0,v,r.css))),u){if(L>=u.end)T(a=u.b,1-a),Zi(t,u.b,"end"),m||(u.b?g():--u.group.r||qe(u.group.c)),u=null;else if(L>=u.start){let M=L-u.start;a=u.a+u.d*v(M/u.duration),T(a,1-a)}}return!!(u||m)}))}return{run(b){vt(r)?Ac().then(()=>{r=r({direction:b?"in":"out"}),h(b)}):h(b)},end(){g(),u=m=null}}}function je(t){return t?.length!==void 0?t:Array.from(t)}function s1(t,e){t.d(1),e.delete(t.key)}function Jo(t,e){y(t,1,1,()=>{e.delete(t.key)})}function Ma(t,e){t.f(),Jo(t,e)}function ai(t,e,n,i,o,r,a,u,m,f,d,g){let _=t.length,h=r.length,b=_,$={};for(;b--;)$[t[b].key]=b;let k=[],v=new Map,T=new Map,I=[];for(b=h;b--;){let A=g(o,r,b),x=n(A),O=a.get(x);O?i&&I.push(()=>O.p(A,e)):(O=f(x,A),O.c()),v.set(x,k[b]=O),x in $&&T.set(x,Math.abs(b-$[x]))}let D=new Set,L=new Set;function M(A){w(A,1),A.m(u,d),a.set(A.key,A),d=A.first,h--}for(;_&&h;){let A=k[h-1],x=t[_-1],O=A.key,N=x.key;A===x?(d=A.first,_--,h--):v.has(N)?!a.has(O)||D.has(O)?M(A):L.has(N)?_--:T.get(O)>T.get(N)?(L.add(O),M(A)):(D.add(N),_--):(m(x,a),_--)}for(;_--;){let A=t[_];v.has(A.key)||m(A,a)}for(;h;)M(k[h-1]);return qe(I),k}function zt(t,e){let n={},i={},o={$$scope:1},r=t.length;for(;r--;){let a=t[r],u=e[r];if(u){for(let m in a)m in u||(i[m]=1);for(let m in u)o[m]||(n[m]=u[m],o[m]=1);t[r]=u}else for(let m in a)o[m]=1}for(let a in i)a in n||(n[a]=void 0);return n}function Lo(t){return typeof t=="object"&&t!==null?t:{}}var fv=["allowfullscreen","allowpaymentrequest","async","autofocus","autoplay","checked","controls","default","defer","disabled","formnovalidate","hidden","inert","ismap","loop","multiple","muted","nomodule","novalidate","open","playsinline","readonly","required","reversed","selected"],mv=new Set([...fv]);function Ge(t,e,n){let i=t.$$.props[e];i!==void 0&&(t.$$.bound[i]=n,n(t.$$.ctx[i]))}function S(t){t&&t.c()}function C(t,e,n){let{fragment:i,after_update:o}=t.$$;i&&i.m(e,n),nn(()=>{let r=t.$$.on_mount.map(yc).filter(vt);t.$$.on_destroy?t.$$.on_destroy.push(...r):qe(r),t.$$.on_mount=[]}),o.forEach(nn)}function E(t,e){let n=t.$$;n.fragment!==null&&(o1(n.after_update),qe(n.on_destroy),n.fragment&&n.fragment.d(e),n.on_destroy=n.fragment=null,n.ctx=[])}function dv(t,e){t.$$.dirty[0]===-1&&(Ji.push(t),i1(),t.$$.dirty.fill(0)),t.$$.dirty[e/31|0]|=1<{let b=h.length?h[0]:_;return f.ctx&&o(f.ctx[g],f.ctx[g]=b)&&(!f.skip_bound&&f.bound[g]&&f.bound[g](b),d&&dv(t,g)),_}):[],f.update(),d=!0,qe(f.before_update),f.fragment=i?i(f.ctx):!1,e.target){if(e.hydrate){Xg();let g=e1(e.target);f.fragment&&f.fragment.l(g),g.forEach(s)}else f.fragment&&f.fragment.c();e.intro&&w(t.$$.fragment),C(t,e.target,e.anchor),Jg(),Ct()}wi(m)}var pv;typeof HTMLElement=="function"&&(pv=class extends HTMLElement{$$ctor;$$s;$$c;$$cn=!1;$$d={};$$r=!1;$$p_d={};$$l={};$$l_u=new Map;constructor(t,e,n){super(),this.$$ctor=t,this.$$s=e,n&&this.attachShadow({mode:"open"})}addEventListener(t,e,n){if(this.$$l[t]=this.$$l[t]||[],this.$$l[t].push(e),this.$$c){let i=this.$$c.$on(t,e);this.$$l_u.set(e,i)}super.addEventListener(t,e,n)}removeEventListener(t,e,n){if(super.removeEventListener(t,e,n),this.$$c){let i=this.$$l_u.get(e);i&&(i(),this.$$l_u.delete(e))}}async connectedCallback(){if(this.$$cn=!0,!this.$$c){let t=function(o){return()=>{let r;return{c:function(){r=p("slot"),o!=="default"&&H(r,"name",o)},m:function(m,f){l(m,r,f)},d:function(m){m&&s(r)}}}};if(await Promise.resolve(),!this.$$cn||this.$$c)return;let e={},n=n1(this);for(let o of this.$$s)o in n&&(e[o]=[t(o)]);for(let o of this.attributes){let r=this.$$g_p(o.name);r in this.$$d||(this.$$d[r]=Hc(r,o.value,this.$$p_d,"toProp"))}for(let o in this.$$p_d)!(o in this.$$d)&&this[o]!==void 0&&(this.$$d[o]=this[o],delete this[o]);this.$$c=new this.$$ctor({target:this.shadowRoot||this,props:{...this.$$d,$$slots:e,$$scope:{ctx:[]}}});let i=()=>{this.$$r=!0;for(let o in this.$$p_d)if(this.$$d[o]=this.$$c.$$.ctx[this.$$c.$$.props[o]],this.$$p_d[o].reflect){let r=Hc(o,this.$$d[o],this.$$p_d,"toAttribute");r==null?this.removeAttribute(this.$$p_d[o].attribute||o):this.setAttribute(this.$$p_d[o].attribute||o,r)}this.$$r=!1};this.$$c.$$.after_update.push(i),i();for(let o in this.$$l)for(let r of this.$$l[o]){let a=this.$$c.$on(o,r);this.$$l_u.set(r,a)}this.$$l={}}}attributeChangedCallback(t,e,n){this.$$r||(t=this.$$g_p(t),this.$$d[t]=Hc(t,n,this.$$p_d,"toProp"),this.$$c?.$set({[t]:this.$$d[t]}))}disconnectedCallback(){this.$$cn=!1,Promise.resolve().then(()=>{!this.$$cn&&this.$$c&&(this.$$c.$destroy(),this.$$c=void 0)})}$$g_p(t){return Object.keys(this.$$p_d).find(e=>this.$$p_d[e].attribute===t||!this.$$p_d[e].attribute&&e.toLowerCase()===t)||t}});function Hc(t,e,n,i){let o=n[t]?.type;if(e=o==="Boolean"&&typeof e!="boolean"?e!=null:e,!i||!n[t])return e;if(i==="toAttribute")switch(o){case"Object":case"Array":return e==null?null:JSON.stringify(e);case"Boolean":return e?"":null;case"Number":return e??null;default:return e}else switch(o){case"Object":case"Array":return e&&JSON.parse(e);case"Boolean":return e;case"Number":return e!=null?+e:e;default:return e}}var ue=class{$$=void 0;$$set=void 0;$destroy(){E(this,1),this.$destroy=Te}$on(e,n){if(!vt(n))return Te;let i=this.$$.callbacks[e]||(this.$$.callbacks[e]=[]);return i.push(n),()=>{let o=i.indexOf(n);o!==-1&&i.splice(o,1)}}$set(e){this.$$set&&!Wg(e)&&(this.$$.skip_bound=!0,this.$$set(e),this.$$.skip_bound=!1)}};var l1="4";typeof window<"u"&&(window.__svelte||(window.__svelte={v:new Set})).v.add(l1);function hv(t){let e,n,i,o,r,a=t[4].default,u=At(a,t,t[3],null);return{c(){e=p("div"),n=p("div"),i=p("div"),u&&u.c(),H(i,"class","button-group-inner"),H(i,"role","group"),H(n,"class","button-group-scroller"),H(e,"class",o="button-group "+t[1]),te(e,"round",t[2])},m(m,f){l(m,e,f),q(e,n),q(n,i),u&&u.m(i,null),t[5](e),r=!0},p(m,[f]){u&&u.p&&(!r||f&8)&&Ot(u,a,m,m[3],r?It(a,m[3],f,null):Ht(m[3]),null),(!r||f&2&&o!==(o="button-group "+m[1]))&&H(e,"class",o),(!r||f&6)&&te(e,"round",m[2])},i(m){r||(w(u,m),r=!0)},o(m){y(u,m),r=!1},d(m){m&&s(e),u&&u.d(m),t[5](null)}}}function gv(t,e,n){let{$$slots:i={},$$scope:o}=e,{class:r=""}=e,{round:a=void 0}=e,{element:u=void 0}=e;function m(f){be[f?"unshift":"push"](()=>{u=f,n(0,u)})}return t.$$set=f=>{"class"in f&&n(1,r=f.class),"round"in f&&n(2,a=f.round),"element"in f&&n(0,u=f.element),"$$scope"in f&&n(3,o=f.$$scope)},[u,r,a,o,i,m]}var xc=class extends ue{constructor(e){super(),me(this,e,gv,hv,fe,{class:1,round:2,element:0})}},Un=xc;var bv='",Zo={adjustments:'adjustments-horizontal">`}function a1(t,e){Qi[t]||(Qi[t]=e)}function vv(t){let e,n;return{c(){e=new Ai(!1),n=wt(),e.a=n},m(i,o){e.m(t[0],i,o),l(i,n,o)},p(i,[o]){o&1&&e.p(i[0])},i:Te,o:Te,d(i){i&&(s(n),e.d())}}}function wv(t,e,n){let i,{name:o=""}=e;return t.$$set=r=>{"name"in r&&n(1,o=r.name)},t.$$.update=()=>{t.$$.dirty&2&&n(0,i=eo(o))},[i,o]}var Pc=class extends ue{constructor(e){super(),me(this,e,wv,vv,fe,{name:1})}},Lt=Pc;function u1(t){let e,n;return e=new Lt({props:{name:t[10]}}),{c(){S(e.$$.fragment)},m(i,o){C(e,i,o),n=!0},p(i,o){let r={};o&1024&&(r.name=i[10]),e.$set(r)},i(i){n||(w(e.$$.fragment,i),n=!0)},o(i){y(e.$$.fragment,i),n=!1},d(i){E(e,i)}}}function $v(t){let e,n,i,o,r,a,u,m=t[10]&&u1(t),f=t[17].default,d=At(f,t,t[16],null),g=[{type:i=t[6]?"submit":"button"},{class:o="button "+t[12]},t[15]],_={};for(let h=0;h{m=null}),Ve()),d&&d.p&&(!r||b&65536)&&Ot(d,f,h,h[16],r?It(f,h[16],b,null):Ht(h[16]),null),St(e,_=zt(g,[(!r||b&64&&i!==(i=h[6]?"submit":"button"))&&{type:i},(!r||b&4096&&o!==(o="button "+h[12]))&&{class:o},b&32768&&h[15]])),te(e,"button-normal",!h[8]&&!h[9]&&!h[7]),te(e,"button-outline",h[7]),te(e,"button-link",h[8]),te(e,"button-text",h[9]),te(e,"button-has-text",h[14].default),te(e,"round",h[11]),te(e,"info",h[1]),te(e,"success",h[2]),te(e,"warning",h[3]),te(e,"danger",h[4]),te(e,"error",h[5]),te(e,"touching",h[13])},i(h){r||(w(m),w(d,h),r=!0)},o(h){y(m),y(d,h),r=!1},d(h){h&&s(e),m&&m.d(),d&&d.d(h),t[26](null),a=!1,qe(u)}}}function yv(t,e,n){let i=["element","info","success","warning","danger","error","submit","outline","link","text","icon","round","class"],o=Mt(e,i),{$$slots:r={},$$scope:a}=e,u=ba(r),{element:m=void 0}=e,{info:f=!1}=e,{success:d=!1}=e,{warning:g=!1}=e,{danger:_=!1}=e,{error:h=!1}=e,{submit:b=!1}=e,{outline:$=!1}=e,{link:k=!1}=e,{text:v=!1}=e,{icon:T=void 0}=e,{round:I=void 0}=e,{class:D=""}=e,L=!1;function M(j){Qe.call(this,t,j)}function A(j){Qe.call(this,t,j)}function x(j){Qe.call(this,t,j)}function O(j){Qe.call(this,t,j)}function N(j){Qe.call(this,t,j)}function F(j){Qe.call(this,t,j)}function W(j){Qe.call(this,t,j)}function K(j){Qe.call(this,t,j)}function z(j){be[j?"unshift":"push"](()=>{m=j,n(0,m)})}let U=()=>n(13,L=!0),P=()=>n(13,L=!1);return t.$$set=j=>{e=tt(tt({},e),Zt(j)),n(15,o=Mt(e,i)),"element"in j&&n(0,m=j.element),"info"in j&&n(1,f=j.info),"success"in j&&n(2,d=j.success),"warning"in j&&n(3,g=j.warning),"danger"in j&&n(4,_=j.danger),"error"in j&&n(5,h=j.error),"submit"in j&&n(6,b=j.submit),"outline"in j&&n(7,$=j.outline),"link"in j&&n(8,k=j.link),"text"in j&&n(9,v=j.text),"icon"in j&&n(10,T=j.icon),"round"in j&&n(11,I=j.round),"class"in j&&n(12,D=j.class),"$$scope"in j&&n(16,a=j.$$scope)},[m,f,d,g,_,h,b,$,k,v,T,I,D,L,u,o,a,r,M,A,x,O,N,F,W,K,z,U,P]}var Nc=class extends ue{constructor(e){super(),me(this,e,yv,$v,fe,{element:0,info:1,success:2,warning:3,danger:4,error:5,submit:6,outline:7,link:8,text:9,icon:10,round:11,class:12})}},De=Nc;var Do=[];function sn(t,e=Te){let n,i=new Set;function o(u){if(fe(t,u)&&(t=u,n)){let m=!Do.length;for(let f of i)f[1](),Do.push(f,t);if(m){for(let f=0;f{i.delete(f),i.size===0&&n&&(n(),n=null)}}return{set:o,update:r,subscribe:a}}var to=["a[href]:not([disabled])","button:not([disabled])","iframe:not([disabled])","input:not([disabled])","select:not([disabled])","textarea:not([disabled])","[contentEditable]","[tabindex]:not(.focus-trap)"].join(","),un=sn(300),Fc=sn(!1),f1=t=>un.set(!t||t.matches?0:200),m1=t=>Fc.set(t&&t.matches);if(window.matchMedia){let t=window.matchMedia("(prefers-reduced-motion: reduce)");f1(t),t.addEventListener("change",f1);let e=window.matchMedia("(prefers-color-scheme: dark)");m1(e),e.addEventListener("change",m1)}function Ca(t,e,n,i={}){let o={duration:tn(un),easing:"ease-out",fill:"forwards"},r=Object.assign({},o,i);return new Promise(a=>{requestAnimationFrame(()=>{let u=t.animate([e,n],r);u.oncancel=a,u.onfinish=a})})}function d1(t,e=160){return Ca(t,{opacity:1},{opacity:.5},{duration:e/2,fill:"backwards"})}function Ao(t,e=300){let n;return(...i)=>{n&&clearTimeout(n),n=setTimeout(()=>t.apply(this,i),e)}}function Ea(t,e=300){let n=0;return(...i)=>{let o=new Date().getTime();if(!(o-nt.length)return!1;if(e===t)return!0;t=t.toLowerCase(),e=e.toLowerCase();let n=-1;for(let i of e)if(!~(n=t.indexOf(i,n+1)))return!1;return!0}function Xe(){return"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,t=>{let e=Math.random()*16|0;return(t==="x"?e:e&3|8).toString(16)})}function xi(t){return t.type.includes("touch")?t.changedTouches[0].clientX:t.clientX}function Qo(t){return t.type.includes("touch")?t.changedTouches[0].clientY:t.clientY}function Jn(){let t=navigator.userAgent,e=/(android|bb\d+|meego).+mobile|avantgo|bada\/|blackberry|blazer|compal|elaine|fennec|hiptop|iemobile|ip(hone|od)|iris|kindle|lge |maemo|midp|mmp|mobile.+firefox|netfront|opera m(ob|in)i|palm( os)?|phone|p(ixi|re)\/|plucker|pocket|psp|series(4|6)0|symbian|treo|up\.(browser|link)|vodafone|wap|windows ce|xda|xiino/i;return!!(e.test(t)||(e=/1207|6310|6590|3gso|4thp|50[1-6]i|770s|802s|a wa|abac|ac(er|oo|s-)|ai(ko|rn)|al(av|ca|co)|amoi|an(ex|ny|yw)|aptu|ar(ch|go)|as(te|us)|attw|au(di|-m|r |s )|avan|be(ck|ll|nq)|bi(lb|rd)|bl(ac|az)|br(e|v)w|bumb|bw-(n|u)|c55\/|capi|ccwa|cdm-|cell|chtm|cldc|cmd-|co(mp|nd)|craw|da(it|ll|ng)|dbte|dc-s|devi|dica|dmob|do(c|p)o|ds(12|-d)|el(49|ai)|em(l2|ul)|er(ic|k0)|esl8|ez([4-7]0|os|wa|ze)|fetc|fly(-|_)|g1 u|g560|gene|gf-5|g-mo|go(\.w|od)|gr(ad|un)|haie|hcit|hd-(m|p|t)|hei-|hi(pt|ta)|hp( i|ip)|hs-c|ht(c(-| |_|a|g|p|s|t)|tp)|hu(aw|tc)|i-(20|go|ma)|i230|iac( |-|\/)|ibro|idea|ig01|ikom|im1k|inno|ipaq|iris|ja(t|v)a|jbro|jemu|jigs|kddi|keji|kgt( |\/)|klon|kpt |kwc-|kyo(c|k)|le(no|xi)|lg( g|\/(k|l|u)|50|54|-[a-w])|libw|lynx|m1-w|m3ga|m50\/|ma(te|ui|xo)|mc(01|21|ca)|m-cr|me(rc|ri)|mi(o8|oa|ts)|mmef|mo(01|02|bi|de|do|t(-| |o|v)|zz)|mt(50|p1|v )|mwbp|mywa|n10[0-2]|n20[2-3]|n30(0|2)|n50(0|2|5)|n7(0(0|1)|10)|ne((c|m)-|on|tf|wf|wg|wt)|nok(6|i)|nzph|o2im|op(ti|wv)|oran|owg1|p800|pan(a|d|t)|pdxg|pg(13|-([1-8]|c))|phil|pire|pl(ay|uc)|pn-2|po(ck|rt|se)|prox|psio|pt-g|qa-a|qc(07|12|21|32|60|-[2-7]|i-)|qtek|r380|r600|raks|rim9|ro(ve|zo)|s55\/|sa(ge|ma|mm|ms|ny|va)|sc(01|h-|oo|p-)|sdk\/|se(c(-|0|1)|47|mc|nd|ri)|sgh-|shar|sie(-|m)|sk-0|sl(45|id)|sm(al|ar|b3|it|t5)|so(ft|ny)|sp(01|h-|v-|v )|sy(01|mb)|t2(18|50)|t6(00|10|18)|ta(gt|lk)|tcl-|tdg-|tel(i|m)|tim-|t-mo|to(pl|sh)|ts(70|m-|m3|m5)|tx-9|up(\.b|g1|si)|utst|v400|v750|veri|vi(rg|te)|vk(40|5[0-3]|-v)|vm40|voda|vulc|vx(52|53|60|61|70|80|81|83|85|98)|w3c(-| )|webc|whit|wi(g |nc|nw)|wmlb|wonu|x700|yas-|your|zeto|zte-/i,e.test(t.slice(0,4))))}function kv(t,e){if(e in t)return t[e]}function Tv(t,e){let n={};return e.forEach(i=>{i in t&&(n[i]=t[i])}),n}function g1(t,e){return t?Array.isArray(e)?Tv(t,e):kv(t,e):{}}function b1(t,e=2){let n=Math.pow(10,e);return Math.round(t*n)/n}function Mv(t){let e=t.getFullYear(),n=("0"+(t.getMonth()+1)).slice(-2),i=("0"+t.getDate()).slice(-2),o=("0"+t.getHours()).slice(-2),r=("0"+t.getMinutes()).slice(-2);return`${e}-${n}-${i} ${o}:${r}`}function qc(t,e){if(!t)return"";e=e||new Date().getTime();let n=(e-+t)/1e3,i=[{label:"year",seconds:31536e3},{label:"month",seconds:2592e3},{label:"day",seconds:86400},{label:"hour",seconds:3600},{label:"minute",seconds:60}],o=[];for(;n>60;){let r=i.find(u=>u.seconds$.height||b<$.height)&&(g=m-$.height-a,(o==="top"||g<$.y)&&(g=d.top-$.height-r),t.style.top=g+window.scrollY+"px");let k=n==="center"?a*2:a;return f<$.x+$.width+k&&(_=f-$.width-k,_<0&&(_=a),_=_+window.scrollX),$.xd.top?"bottom":"top"}function Cv(t,e){let n=e.getBoundingClientRect(),i=t.left+t.width/2,o=n.left+n.width/2,r=n.width?n.width/100:1,a=50+(i-o)/r,u=Math.max(8,Math.min(93,a));return`${Math.round(u*r-1)}px`}function c1(t){let e=getComputedStyle(t,null),n=e.overflowX||e.overflow;return/(auto|scroll)/.test(n)?t.scrollWidth>t.clientWidth:!1}function _1(t){if(!(t instanceof HTMLElement||t instanceof SVGElement))return!1;if(c1(t))return!0;let e=t.parentElement;for(;e;){if(c1(e))return!0;e=e.parentElement}return!1}function es(t){if(t=t[0]==="#"?t.slice(1):t,t.length===3&&(t=t[0]+t[0]+t[1]+t[1]+t[2]+t[2]),t.length!==6)return!1;let e=parseInt(t.substring(0,2),16),n=parseInt(t.substring(2,4),16),i=parseInt(t.substring(4,6),16);if(isNaN(e)||isNaN(n)||isNaN(i))return!1;let o=(e*299+n*587+i*114)/1e3;return isNaN(o)?!1:o<140}var Ev=t=>({}),v1=t=>({});function Sv(t){let e,n,i,o,r,a,u,m,f,d,g,_,h,b,$,k,v=t[16].default,T=At(v,t,t[15],null),I=t[16].footer,D=At(I,t,t[15],v1);return{c(){e=p("div"),n=p("div"),i=p("div"),o=c(),r=p("h1"),a=ne(t[3]),u=c(),m=p("div"),T&&T.c(),f=c(),d=p("div"),D&&D.c(),g=c(),_=p("div"),H(i,"tabindex","0"),H(i,"class","focus-trap focus-trap-top"),H(r,"class","dialog-header"),H(m,"class","dialog-content"),H(d,"class","dialog-footer"),H(_,"tabindex","0"),H(_,"class","focus-trap focus-trap-bottom"),H(n,"class","dialog"),te(n,"no-title",!t[3]),H(e,"role","dialog"),H(e,"aria-modal","true"),H(e,"aria-label",t[3]),H(e,"class",h="dialog-backdrop "+t[2]),te(e,"opened",t[0])},m(L,M){l(L,e,M),q(e,n),q(n,i),q(n,o),q(n,r),q(r,a),q(n,u),q(n,m),T&&T.m(m,null),t[17](m),q(n,f),q(n,d),D&&D.m(d,null),t[18](d),q(n,g),q(n,_),t[19](n),t[20](e),b=!0,$||(k=[we(i,"focus",t[8]),we(_,"focus",t[7]),we(e,"mousedown",t[9]),we(e,"click",t[10])],$=!0)},p(L,[M]){(!b||M&8)&&Be(a,L[3]),T&&T.p&&(!b||M&32768)&&Ot(T,v,L,L[15],b?It(v,L[15],M,null):Ht(L[15]),null),D&&D.p&&(!b||M&32768)&&Ot(D,I,L,L[15],b?It(I,L[15],M,Ev):Ht(L[15]),v1),(!b||M&8)&&te(n,"no-title",!L[3]),(!b||M&8)&&H(e,"aria-label",L[3]),(!b||M&4&&h!==(h="dialog-backdrop "+L[2]))&&H(e,"class",h),(!b||M&5)&&te(e,"opened",L[0])},i(L){b||(w(T,L),w(D,L),b=!0)},o(L){y(T,L),y(D,L),b=!1},d(L){L&&s(e),T&&T.d(L),t[17](null),D&&D.d(L),t[18](null),t[19](null),t[20](null),$=!1,qe(k)}}}function Lv(t,e){let i={ArrowLeft:"nextElementSibling",ArrowRight:"previousElementSibling"}[e],o=t[i];for(;o&&o.tagName!=="BUTTON";)o=o[i];o&&o.focus()}function Dv(t,e,n){let i;dn(t,un,j=>n(25,i=j));let{$$slots:o={},$$scope:r}=e,{class:a=""}=e,{title:u=""}=e,{opened:m=!1}=e,{skipFirstFocus:f=!1}=e,{modal:d=!1}=e,{element:g}=e,_=lt(),h,b,$,k,v,T,I;Nt(()=>{document.body.appendChild(g)});function D(){let j=M().shift(),Y=M().pop();!j&&!Y&&(b.setAttribute("tabindex",0),j=b),Y&&Y.scrollIntoView({block:"end"}),j&&j.focus()}function L(){let j=M().shift(),Y=M().pop();!j&&!Y&&(b.setAttribute("tabindex",0),Y=b),j&&j.scrollIntoView({block:"end"}),Y&&Y.focus()}function M(){let j=Array.from(b.querySelectorAll(to)),Y=Array.from($.querySelectorAll(to));return[...j,...Y]}function A(j){d&&(j.stopPropagation(),j.preventDefault())}function x(j){!h.contains(j.target)&&!d&&(j.stopPropagation(),W())}function O(j){if(!m)return;let Y=g.contains(document.activeElement);if(j.key==="Tab"&&!Y)return D();if(j.key==="Escape"&&!d)return j.stopPropagation(),W();let Z=j.target?.closest("button");Z&&(j.key==="ArrowLeft"||j.key==="ArrowRight")&&Lv(Z,j.key)}function N(j){j?(I=window.scrollY,document.body.classList.add("has-dialog"),document.body.style.top=`-${I}px`):(document.body.classList.remove("has-dialog"),document.scrollingElement.scrollTop=I,document.body.style.top="")}function F(j){m||(j instanceof Event&&(j=j.target),k=j||document.activeElement,k&&k!==document.body&&(k.setAttribute("aria-haspopup","true"),k.setAttribute("aria-expanded","true")),n(1,g.style.display="flex",g),v&&clearTimeout(v),v=setTimeout(()=>{n(0,m=!0),n(1,g.style.display="flex",g),f!==!0&&f!=="true"&&D(),document.addEventListener("keydown",O),N(!0),_("open")},100))}function W(){m&&(n(0,m=!1),k&&k.focus&&k.focus(),T&&clearTimeout(T),T=setTimeout(()=>{n(0,m=!1),n(1,g.style.display="none",g),document.removeEventListener("keydown",O),k&&k!==document.body&&k.removeAttribute("aria-expanded"),N(!1),_("close")},i))}function K(j){be[j?"unshift":"push"](()=>{b=j,n(5,b)})}function z(j){be[j?"unshift":"push"](()=>{$=j,n(6,$)})}function U(j){be[j?"unshift":"push"](()=>{h=j,n(4,h)})}function P(j){be[j?"unshift":"push"](()=>{g=j,n(1,g)})}return t.$$set=j=>{"class"in j&&n(2,a=j.class),"title"in j&&n(3,u=j.title),"opened"in j&&n(0,m=j.opened),"skipFirstFocus"in j&&n(11,f=j.skipFirstFocus),"modal"in j&&n(12,d=j.modal),"element"in j&&n(1,g=j.element),"$$scope"in j&&n(15,r=j.$$scope)},[m,g,a,u,h,b,$,D,L,A,x,f,d,F,W,r,o,K,z,U,P]}var Bc=class extends ue{constructor(e){super(),me(this,e,Dv,Sv,fe,{class:2,title:3,opened:0,skipFirstFocus:11,modal:12,element:1,open:13,close:14})}get class(){return this.$$.ctx[2]}set class(e){this.$$set({class:e}),Ct()}get title(){return this.$$.ctx[3]}set title(e){this.$$set({title:e}),Ct()}get opened(){return this.$$.ctx[0]}set opened(e){this.$$set({opened:e}),Ct()}get skipFirstFocus(){return this.$$.ctx[11]}set skipFirstFocus(e){this.$$set({skipFirstFocus:e}),Ct()}get modal(){return this.$$.ctx[12]}set modal(e){this.$$set({modal:e}),Ct()}get element(){return this.$$.ctx[1]}set element(e){this.$$set({element:e}),Ct()}get open(){return this.$$.ctx[13]}get close(){return this.$$.ctx[14]}},$i=Bc;function ts(t){let e=t-1;return e*e*e+1}function no(t,{delay:e=0,duration:n=400,easing:i=ts,x:o=0,y:r=0,opacity:a=0}={}){let u=getComputedStyle(t),m=+u.opacity,f=u.transform==="none"?"":u.transform,d=m*(1-a),[g,_]=kc(o),[h,b]=kc(r);return{delay:e,duration:n,easing:i,css:($,k)=>` - transform: ${f} translate(${(1-$)*g}${_}, ${(1-$)*h}${b}); - opacity: ${m-d*k}`}}function w1({fallback:t,...e}){let n=new Map,i=new Map;function o(a,u,m){let{delay:f=0,duration:d=M=>Math.sqrt(M)*30,easing:g=ts}=tt(tt({},e),m),_=a.getBoundingClientRect(),h=u.getBoundingClientRect(),b=_.left-h.left,$=_.top-h.top,k=_.width/h.width,v=_.height/h.height,T=Math.sqrt(b*b+$*$),I=getComputedStyle(u),D=I.transform==="none"?"":I.transform,L=+I.opacity;return{delay:f,duration:vt(d)?d(T):d,easing:g,css:(M,A)=>` - opacity: ${M*L}; +var __create = Object.create; +var __defProp = Object.defineProperty; +var __getOwnPropDesc = Object.getOwnPropertyDescriptor; +var __getOwnPropNames = Object.getOwnPropertyNames; +var __getProtoOf = Object.getPrototypeOf; +var __hasOwnProp = Object.prototype.hasOwnProperty; +var __commonJS = (cb, mod) => function __require() { + return mod || (0, cb[__getOwnPropNames(cb)[0]])((mod = { exports: {} }).exports, mod), mod.exports; +}; +var __export = (target, all) => { + for (var name2 in all) + __defProp(target, name2, { get: all[name2], enumerable: true }); +}; +var __copyProps = (to, from, except, desc) => { + if (from && typeof from === "object" || typeof from === "function") { + for (let key of __getOwnPropNames(from)) + if (!__hasOwnProp.call(to, key) && key !== except) + __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable }); + } + return to; +}; +var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps( + // If the importer is in node compatibility mode or this is not an ESM + // file that has been converted to a CommonJS file using a Babel- + // compatible transform (i.e. "__esModule" has not been set), then set + // "default" to the CommonJS "module.exports" for node compatibility. + isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target, + mod +)); + +// node_modules/vanilla-swipe/lib/types/index.js +var require_types = __commonJS({ + "node_modules/vanilla-swipe/lib/types/index.js"(exports) { + "use strict"; + Object.defineProperty(exports, "__esModule", { + value: true + }); + exports.TraceDirectionKey = exports.Direction = exports.Axis = void 0; + var TraceDirectionKey; + exports.TraceDirectionKey = TraceDirectionKey; + (function(TraceDirectionKey2) { + TraceDirectionKey2["NEGATIVE"] = "NEGATIVE"; + TraceDirectionKey2["POSITIVE"] = "POSITIVE"; + TraceDirectionKey2["NONE"] = "NONE"; + })(TraceDirectionKey || (exports.TraceDirectionKey = TraceDirectionKey = {})); + var Direction; + exports.Direction = Direction; + (function(Direction2) { + Direction2["TOP"] = "TOP"; + Direction2["LEFT"] = "LEFT"; + Direction2["RIGHT"] = "RIGHT"; + Direction2["BOTTOM"] = "BOTTOM"; + Direction2["NONE"] = "NONE"; + })(Direction || (exports.Direction = Direction = {})); + var Axis; + exports.Axis = Axis; + (function(Axis2) { + Axis2["X"] = "x"; + Axis2["Y"] = "y"; + })(Axis || (exports.Axis = Axis = {})); + } +}); + +// node_modules/vanilla-swipe/lib/utils/calculateDirection.js +var require_calculateDirection = __commonJS({ + "node_modules/vanilla-swipe/lib/utils/calculateDirection.js"(exports) { + "use strict"; + Object.defineProperty(exports, "__esModule", { + value: true + }); + exports.calculateDirection = calculateDirection; + var _types = require_types(); + function calculateDirection(trace) { + var direction; + var negative = _types.TraceDirectionKey.NEGATIVE; + var positive = _types.TraceDirectionKey.POSITIVE; + var current = trace[trace.length - 1]; + var previous = trace[trace.length - 2] || 0; + if (trace.every(function(i) { + return i === 0; + })) { + return _types.TraceDirectionKey.NONE; + } + direction = current > previous ? positive : negative; + if (current === 0) { + direction = previous < 0 ? positive : negative; + } + return direction; + } + } +}); + +// node_modules/vanilla-swipe/lib/utils/common.js +var require_common = __commonJS({ + "node_modules/vanilla-swipe/lib/utils/common.js"(exports) { + "use strict"; + Object.defineProperty(exports, "__esModule", { + value: true + }); + exports.resolveAxisDirection = exports.getDirectionValue = exports.getDirectionKey = exports.getDifference = void 0; + var _types = require_types(); + var getDirectionKey = function getDirectionKey2() { + var object = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : {}; + var key = Object.keys(object).toString(); + switch (key) { + case _types.TraceDirectionKey.POSITIVE: + return _types.TraceDirectionKey.POSITIVE; + case _types.TraceDirectionKey.NEGATIVE: + return _types.TraceDirectionKey.NEGATIVE; + default: + return _types.TraceDirectionKey.NONE; + } + }; + exports.getDirectionKey = getDirectionKey; + var getDirectionValue = function getDirectionValue2() { + var values = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : []; + return values[values.length - 1] || 0; + }; + exports.getDirectionValue = getDirectionValue; + var getDifference = function getDifference2() { + var x = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : 0; + var y = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : 0; + return Math.abs(x - y); + }; + exports.getDifference = getDifference; + var resolveAxisDirection = function resolveAxisDirection2(axis, key) { + var negative = _types.Direction.LEFT; + var positive = _types.Direction.RIGHT; + var direction = _types.Direction.NONE; + if (axis === _types.Axis.Y) { + negative = _types.Direction.BOTTOM; + positive = _types.Direction.TOP; + } + if (key === _types.TraceDirectionKey.NEGATIVE) { + direction = negative; + } + if (key === _types.TraceDirectionKey.POSITIVE) { + direction = positive; + } + return direction; + }; + exports.resolveAxisDirection = resolveAxisDirection; + } +}); + +// node_modules/vanilla-swipe/lib/utils/calculateDirectionDelta.js +var require_calculateDirectionDelta = __commonJS({ + "node_modules/vanilla-swipe/lib/utils/calculateDirectionDelta.js"(exports) { + "use strict"; + Object.defineProperty(exports, "__esModule", { + value: true + }); + exports.calculateDirectionDelta = calculateDirectionDelta; + var _types = require_types(); + var _common = require_common(); + function calculateDirectionDelta(traceDirections) { + var delta = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : 0; + var length = traceDirections.length; + var i = length - 1; + var direction = _types.TraceDirectionKey.NONE; + for (; i >= 0; i--) { + var current = traceDirections[i]; + var currentKey = (0, _common.getDirectionKey)(current); + var currentValue = (0, _common.getDirectionValue)(current[currentKey]); + var prev = traceDirections[i - 1] || {}; + var prevKey = (0, _common.getDirectionKey)(prev); + var prevValue = (0, _common.getDirectionValue)(prev[prevKey]); + var difference = (0, _common.getDifference)(currentValue, prevValue); + if (difference >= delta) { + direction = currentKey; + break; + } else { + direction = prevKey; + } + } + return direction; + } + } +}); + +// node_modules/vanilla-swipe/lib/utils/calculateDuration.js +var require_calculateDuration = __commonJS({ + "node_modules/vanilla-swipe/lib/utils/calculateDuration.js"(exports) { + "use strict"; + Object.defineProperty(exports, "__esModule", { + value: true + }); + exports.calculateDuration = calculateDuration; + function calculateDuration() { + var prevTime = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : 0; + var nextTime = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : 0; + return prevTime ? nextTime - prevTime : 0; + } + } +}); + +// node_modules/vanilla-swipe/lib/utils/calculateMovingPosition.js +var require_calculateMovingPosition = __commonJS({ + "node_modules/vanilla-swipe/lib/utils/calculateMovingPosition.js"(exports) { + "use strict"; + Object.defineProperty(exports, "__esModule", { + value: true + }); + exports.calculateMovingPosition = calculateMovingPosition; + function calculateMovingPosition(e) { + if ("changedTouches" in e) { + var touches = e.changedTouches && e.changedTouches[0]; + return { + x: touches && touches.clientX, + y: touches && touches.clientY + }; + } + return { + x: e.clientX, + y: e.clientY + }; + } + } +}); + +// node_modules/vanilla-swipe/lib/utils/updateTrace.js +var require_updateTrace = __commonJS({ + "node_modules/vanilla-swipe/lib/utils/updateTrace.js"(exports) { + "use strict"; + Object.defineProperty(exports, "__esModule", { + value: true + }); + exports.updateTrace = updateTrace; + function updateTrace(trace, value2) { + var last = trace[trace.length - 1]; + if (last !== value2) { + trace.push(value2); + } + return trace; + } + } +}); + +// node_modules/vanilla-swipe/lib/utils/calculateTraceDirections.js +var require_calculateTraceDirections = __commonJS({ + "node_modules/vanilla-swipe/lib/utils/calculateTraceDirections.js"(exports) { + "use strict"; + Object.defineProperty(exports, "__esModule", { + value: true + }); + exports.calculateTraceDirections = calculateTraceDirections; + var _types = require_types(); + function _defineProperty(obj, key, value2) { + if (key in obj) { + Object.defineProperty(obj, key, { value: value2, enumerable: true, configurable: true, writable: true }); + } else { + obj[key] = value2; + } + return obj; + } + function calculateTraceDirections() { + var trace = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : []; + var ticks = []; + var positive = _types.TraceDirectionKey.POSITIVE; + var negative = _types.TraceDirectionKey.NEGATIVE; + var i = 0; + var tick2 = []; + var direction = _types.TraceDirectionKey.NONE; + for (; i < trace.length; i++) { + var current = trace[i]; + var prev = trace[i - 1]; + if (tick2.length) { + var currentDirection = current > prev ? positive : negative; + if (direction === _types.TraceDirectionKey.NONE) { + direction = currentDirection; + } + if (currentDirection === direction) { + tick2.push(current); + } else { + ticks.push(_defineProperty({}, direction, tick2.slice())); + tick2 = []; + tick2.push(current); + direction = currentDirection; + } + } else { + if (current !== 0) { + direction = current > 0 ? positive : negative; + } + tick2.push(current); + } + } + if (tick2.length) { + ticks.push(_defineProperty({}, direction, tick2)); + } + return ticks; + } + } +}); + +// node_modules/vanilla-swipe/lib/utils/resolveDirection.js +var require_resolveDirection = __commonJS({ + "node_modules/vanilla-swipe/lib/utils/resolveDirection.js"(exports) { + "use strict"; + Object.defineProperty(exports, "__esModule", { + value: true + }); + exports.resolveDirection = resolveDirection; + var _calculateDirection = require_calculateDirection(); + var _calculateTraceDirections = require_calculateTraceDirections(); + var _calculateDirectionDelta = require_calculateDirectionDelta(); + var _common = require_common(); + var _types = require_types(); + function resolveDirection(trace) { + var axis = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : _types.Axis.X; + var directionDelta = arguments.length > 2 && arguments[2] !== void 0 ? arguments[2] : 0; + if (directionDelta) { + var directions = (0, _calculateTraceDirections.calculateTraceDirections)(trace); + var _direction = (0, _calculateDirectionDelta.calculateDirectionDelta)(directions, directionDelta); + return (0, _common.resolveAxisDirection)(axis, _direction); + } + var direction = (0, _calculateDirection.calculateDirection)(trace); + return (0, _common.resolveAxisDirection)(axis, direction); + } + } +}); + +// node_modules/vanilla-swipe/lib/utils/calculateVelocity.js +var require_calculateVelocity = __commonJS({ + "node_modules/vanilla-swipe/lib/utils/calculateVelocity.js"(exports) { + "use strict"; + Object.defineProperty(exports, "__esModule", { + value: true + }); + exports.calculateVelocity = calculateVelocity; + function calculateVelocity(x, y, time) { + var magnitude = Math.sqrt(x * x + y * y); + return magnitude / (time || 1); + } + } +}); + +// node_modules/vanilla-swipe/lib/utils/calculatePosition.js +var require_calculatePosition = __commonJS({ + "node_modules/vanilla-swipe/lib/utils/calculatePosition.js"(exports) { + "use strict"; + Object.defineProperty(exports, "__esModule", { + value: true + }); + exports.calculatePosition = calculatePosition; + var _updateTrace = require_updateTrace(); + var _resolveDirection = require_resolveDirection(); + var _calculateDuration = require_calculateDuration(); + var _calculateVelocity = require_calculateVelocity(); + var _types = require_types(); + function calculatePosition(state, options) { + var start = state.start, x = state.x, y = state.y, traceX = state.traceX, traceY = state.traceY; + var rotatePosition = options.rotatePosition, directionDelta = options.directionDelta; + var deltaX = rotatePosition.x - x; + var deltaY = y - rotatePosition.y; + var absX = Math.abs(deltaX); + var absY = Math.abs(deltaY); + (0, _updateTrace.updateTrace)(traceX, deltaX); + (0, _updateTrace.updateTrace)(traceY, deltaY); + var directionX = (0, _resolveDirection.resolveDirection)(traceX, _types.Axis.X, directionDelta); + var directionY = (0, _resolveDirection.resolveDirection)(traceY, _types.Axis.Y, directionDelta); + var duration2 = (0, _calculateDuration.calculateDuration)(start, Date.now()); + var velocity = (0, _calculateVelocity.calculateVelocity)(absX, absY, duration2); + return { + absX, + absY, + deltaX, + deltaY, + directionX, + directionY, + duration: duration2, + positionX: rotatePosition.x, + positionY: rotatePosition.y, + velocity + }; + } + } +}); + +// node_modules/vanilla-swipe/lib/utils/checkIsMoreThanSingleTouches.js +var require_checkIsMoreThanSingleTouches = __commonJS({ + "node_modules/vanilla-swipe/lib/utils/checkIsMoreThanSingleTouches.js"(exports) { + "use strict"; + Object.defineProperty(exports, "__esModule", { + value: true + }); + exports.checkIsMoreThanSingleTouches = void 0; + var checkIsMoreThanSingleTouches = function checkIsMoreThanSingleTouches2(e) { + return Boolean(e.touches && e.touches.length > 1); + }; + exports.checkIsMoreThanSingleTouches = checkIsMoreThanSingleTouches; + } +}); + +// node_modules/vanilla-swipe/lib/utils/createOptions.js +var require_createOptions = __commonJS({ + "node_modules/vanilla-swipe/lib/utils/createOptions.js"(exports) { + "use strict"; + Object.defineProperty(exports, "__esModule", { + value: true + }); + exports.createOptions = createOptions; + function createOptions() { + var proxy = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : {}; + Object.defineProperty(proxy, "passive", { + get: function get() { + this.isPassiveSupported = true; + return true; + }, + enumerable: true + }); + return proxy; + } + } +}); + +// node_modules/vanilla-swipe/lib/utils/checkIsPassiveSupported.js +var require_checkIsPassiveSupported = __commonJS({ + "node_modules/vanilla-swipe/lib/utils/checkIsPassiveSupported.js"(exports) { + "use strict"; + Object.defineProperty(exports, "__esModule", { + value: true + }); + exports.checkIsPassiveSupported = checkIsPassiveSupported; + exports.noop = void 0; + var _createOptions = require_createOptions(); + function checkIsPassiveSupported(isPassiveSupported) { + if (typeof isPassiveSupported === "boolean") { + return isPassiveSupported; + } + var proxy = { + isPassiveSupported + }; + try { + var options = (0, _createOptions.createOptions)(proxy); + window.addEventListener("checkIsPassiveSupported", noop2, options); + window.removeEventListener("checkIsPassiveSupported", noop2, options); + } catch (err) { + } + return proxy.isPassiveSupported; + } + var noop2 = function noop3() { + }; + exports.noop = noop2; + } +}); + +// node_modules/vanilla-swipe/lib/utils/checkIsTouchEventsSupported.js +var require_checkIsTouchEventsSupported = __commonJS({ + "node_modules/vanilla-swipe/lib/utils/checkIsTouchEventsSupported.js"(exports) { + "use strict"; + Object.defineProperty(exports, "__esModule", { + value: true + }); + exports.checkIsTouchEventsSupported = void 0; + function _typeof(obj) { + "@babel/helpers - typeof"; + return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function(obj2) { + return typeof obj2; + } : function(obj2) { + return obj2 && "function" == typeof Symbol && obj2.constructor === Symbol && obj2 !== Symbol.prototype ? "symbol" : typeof obj2; + }, _typeof(obj); + } + var checkIsTouchEventsSupported = function checkIsTouchEventsSupported2() { + return (typeof window === "undefined" ? "undefined" : _typeof(window)) === "object" && ("ontouchstart" in window || Boolean(window.navigator.maxTouchPoints)); + }; + exports.checkIsTouchEventsSupported = checkIsTouchEventsSupported; + } +}); + +// node_modules/vanilla-swipe/lib/utils/getInitialState.js +var require_getInitialState = __commonJS({ + "node_modules/vanilla-swipe/lib/utils/getInitialState.js"(exports) { + "use strict"; + Object.defineProperty(exports, "__esModule", { + value: true + }); + exports.getInitialState = void 0; + function ownKeys(object, enumerableOnly) { + var keys = Object.keys(object); + if (Object.getOwnPropertySymbols) { + var symbols = Object.getOwnPropertySymbols(object); + enumerableOnly && (symbols = symbols.filter(function(sym) { + return Object.getOwnPropertyDescriptor(object, sym).enumerable; + })), keys.push.apply(keys, symbols); + } + return keys; + } + function _objectSpread(target) { + for (var i = 1; i < arguments.length; i++) { + var source = null != arguments[i] ? arguments[i] : {}; + i % 2 ? ownKeys(Object(source), true).forEach(function(key) { + _defineProperty(target, key, source[key]); + }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function(key) { + Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); + }); + } + return target; + } + function _defineProperty(obj, key, value2) { + if (key in obj) { + Object.defineProperty(obj, key, { value: value2, enumerable: true, configurable: true, writable: true }); + } else { + obj[key] = value2; + } + return obj; + } + var getInitialState = function getInitialState2() { + var options = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : {}; + return _objectSpread({ + x: 0, + y: 0, + start: 0, + isSwiping: false, + traceX: [], + traceY: [] + }, options); + }; + exports.getInitialState = getInitialState; + } +}); + +// node_modules/vanilla-swipe/lib/utils/getInitialProps.js +var require_getInitialProps = __commonJS({ + "node_modules/vanilla-swipe/lib/utils/getInitialProps.js"(exports) { + "use strict"; + Object.defineProperty(exports, "__esModule", { + value: true + }); + exports.getInitialProps = void 0; + function ownKeys(object, enumerableOnly) { + var keys = Object.keys(object); + if (Object.getOwnPropertySymbols) { + var symbols = Object.getOwnPropertySymbols(object); + enumerableOnly && (symbols = symbols.filter(function(sym) { + return Object.getOwnPropertyDescriptor(object, sym).enumerable; + })), keys.push.apply(keys, symbols); + } + return keys; + } + function _objectSpread(target) { + for (var i = 1; i < arguments.length; i++) { + var source = null != arguments[i] ? arguments[i] : {}; + i % 2 ? ownKeys(Object(source), true).forEach(function(key) { + _defineProperty(target, key, source[key]); + }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function(key) { + Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); + }); + } + return target; + } + function _defineProperty(obj, key, value2) { + if (key in obj) { + Object.defineProperty(obj, key, { value: value2, enumerable: true, configurable: true, writable: true }); + } else { + obj[key] = value2; + } + return obj; + } + var getInitialProps = function getInitialProps2() { + var props = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : {}; + return _objectSpread({ + element: null, + target: null, + delta: 10, + directionDelta: 0, + rotationAngle: 0, + mouseTrackingEnabled: false, + touchTrackingEnabled: true, + preventDefaultTouchmoveEvent: false, + preventTrackingOnMouseleave: false + }, props); + }; + exports.getInitialProps = getInitialProps; + } +}); + +// node_modules/vanilla-swipe/lib/utils/getOptions.js +var require_getOptions = __commonJS({ + "node_modules/vanilla-swipe/lib/utils/getOptions.js"(exports) { + "use strict"; + Object.defineProperty(exports, "__esModule", { + value: true + }); + exports.getOptions = getOptions; + function getOptions() { + var isPassiveSupported = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : false; + if (isPassiveSupported) { + return { + passive: false + }; + } + return {}; + } + } +}); + +// node_modules/vanilla-swipe/lib/utils/rotateByAngle.js +var require_rotateByAngle = __commonJS({ + "node_modules/vanilla-swipe/lib/utils/rotateByAngle.js"(exports) { + "use strict"; + Object.defineProperty(exports, "__esModule", { + value: true + }); + exports.rotateByAngle = rotateByAngle; + function rotateByAngle(position) { + var angle = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : 0; + if (angle === 0) { + return position; + } + var x = position.x, y = position.y; + var angleInRadians = Math.PI / 180 * angle; + var rotatedX = x * Math.cos(angleInRadians) + y * Math.sin(angleInRadians); + var rotatedY = y * Math.cos(angleInRadians) - x * Math.sin(angleInRadians); + return { + x: rotatedX, + y: rotatedY + }; + } + } +}); + +// node_modules/vanilla-swipe/lib/utils/index.js +var require_utils = __commonJS({ + "node_modules/vanilla-swipe/lib/utils/index.js"(exports) { + "use strict"; + Object.defineProperty(exports, "__esModule", { + value: true + }); + var _calculateDirection = require_calculateDirection(); + Object.keys(_calculateDirection).forEach(function(key) { + if (key === "default" || key === "__esModule") + return; + if (key in exports && exports[key] === _calculateDirection[key]) + return; + Object.defineProperty(exports, key, { + enumerable: true, + get: function get() { + return _calculateDirection[key]; + } + }); + }); + var _calculateDirectionDelta = require_calculateDirectionDelta(); + Object.keys(_calculateDirectionDelta).forEach(function(key) { + if (key === "default" || key === "__esModule") + return; + if (key in exports && exports[key] === _calculateDirectionDelta[key]) + return; + Object.defineProperty(exports, key, { + enumerable: true, + get: function get() { + return _calculateDirectionDelta[key]; + } + }); + }); + var _calculateDuration = require_calculateDuration(); + Object.keys(_calculateDuration).forEach(function(key) { + if (key === "default" || key === "__esModule") + return; + if (key in exports && exports[key] === _calculateDuration[key]) + return; + Object.defineProperty(exports, key, { + enumerable: true, + get: function get() { + return _calculateDuration[key]; + } + }); + }); + var _calculateMovingPosition = require_calculateMovingPosition(); + Object.keys(_calculateMovingPosition).forEach(function(key) { + if (key === "default" || key === "__esModule") + return; + if (key in exports && exports[key] === _calculateMovingPosition[key]) + return; + Object.defineProperty(exports, key, { + enumerable: true, + get: function get() { + return _calculateMovingPosition[key]; + } + }); + }); + var _calculatePosition = require_calculatePosition(); + Object.keys(_calculatePosition).forEach(function(key) { + if (key === "default" || key === "__esModule") + return; + if (key in exports && exports[key] === _calculatePosition[key]) + return; + Object.defineProperty(exports, key, { + enumerable: true, + get: function get() { + return _calculatePosition[key]; + } + }); + }); + var _calculateTraceDirections = require_calculateTraceDirections(); + Object.keys(_calculateTraceDirections).forEach(function(key) { + if (key === "default" || key === "__esModule") + return; + if (key in exports && exports[key] === _calculateTraceDirections[key]) + return; + Object.defineProperty(exports, key, { + enumerable: true, + get: function get() { + return _calculateTraceDirections[key]; + } + }); + }); + var _calculateVelocity = require_calculateVelocity(); + Object.keys(_calculateVelocity).forEach(function(key) { + if (key === "default" || key === "__esModule") + return; + if (key in exports && exports[key] === _calculateVelocity[key]) + return; + Object.defineProperty(exports, key, { + enumerable: true, + get: function get() { + return _calculateVelocity[key]; + } + }); + }); + var _checkIsMoreThanSingleTouches = require_checkIsMoreThanSingleTouches(); + Object.keys(_checkIsMoreThanSingleTouches).forEach(function(key) { + if (key === "default" || key === "__esModule") + return; + if (key in exports && exports[key] === _checkIsMoreThanSingleTouches[key]) + return; + Object.defineProperty(exports, key, { + enumerable: true, + get: function get() { + return _checkIsMoreThanSingleTouches[key]; + } + }); + }); + var _checkIsPassiveSupported = require_checkIsPassiveSupported(); + Object.keys(_checkIsPassiveSupported).forEach(function(key) { + if (key === "default" || key === "__esModule") + return; + if (key in exports && exports[key] === _checkIsPassiveSupported[key]) + return; + Object.defineProperty(exports, key, { + enumerable: true, + get: function get() { + return _checkIsPassiveSupported[key]; + } + }); + }); + var _checkIsTouchEventsSupported = require_checkIsTouchEventsSupported(); + Object.keys(_checkIsTouchEventsSupported).forEach(function(key) { + if (key === "default" || key === "__esModule") + return; + if (key in exports && exports[key] === _checkIsTouchEventsSupported[key]) + return; + Object.defineProperty(exports, key, { + enumerable: true, + get: function get() { + return _checkIsTouchEventsSupported[key]; + } + }); + }); + var _common = require_common(); + Object.keys(_common).forEach(function(key) { + if (key === "default" || key === "__esModule") + return; + if (key in exports && exports[key] === _common[key]) + return; + Object.defineProperty(exports, key, { + enumerable: true, + get: function get() { + return _common[key]; + } + }); + }); + var _createOptions = require_createOptions(); + Object.keys(_createOptions).forEach(function(key) { + if (key === "default" || key === "__esModule") + return; + if (key in exports && exports[key] === _createOptions[key]) + return; + Object.defineProperty(exports, key, { + enumerable: true, + get: function get() { + return _createOptions[key]; + } + }); + }); + var _getInitialState = require_getInitialState(); + Object.keys(_getInitialState).forEach(function(key) { + if (key === "default" || key === "__esModule") + return; + if (key in exports && exports[key] === _getInitialState[key]) + return; + Object.defineProperty(exports, key, { + enumerable: true, + get: function get() { + return _getInitialState[key]; + } + }); + }); + var _getInitialProps = require_getInitialProps(); + Object.keys(_getInitialProps).forEach(function(key) { + if (key === "default" || key === "__esModule") + return; + if (key in exports && exports[key] === _getInitialProps[key]) + return; + Object.defineProperty(exports, key, { + enumerable: true, + get: function get() { + return _getInitialProps[key]; + } + }); + }); + var _getOptions = require_getOptions(); + Object.keys(_getOptions).forEach(function(key) { + if (key === "default" || key === "__esModule") + return; + if (key in exports && exports[key] === _getOptions[key]) + return; + Object.defineProperty(exports, key, { + enumerable: true, + get: function get() { + return _getOptions[key]; + } + }); + }); + var _resolveDirection = require_resolveDirection(); + Object.keys(_resolveDirection).forEach(function(key) { + if (key === "default" || key === "__esModule") + return; + if (key in exports && exports[key] === _resolveDirection[key]) + return; + Object.defineProperty(exports, key, { + enumerable: true, + get: function get() { + return _resolveDirection[key]; + } + }); + }); + var _rotateByAngle = require_rotateByAngle(); + Object.keys(_rotateByAngle).forEach(function(key) { + if (key === "default" || key === "__esModule") + return; + if (key in exports && exports[key] === _rotateByAngle[key]) + return; + Object.defineProperty(exports, key, { + enumerable: true, + get: function get() { + return _rotateByAngle[key]; + } + }); + }); + var _updateTrace = require_updateTrace(); + Object.keys(_updateTrace).forEach(function(key) { + if (key === "default" || key === "__esModule") + return; + if (key in exports && exports[key] === _updateTrace[key]) + return; + Object.defineProperty(exports, key, { + enumerable: true, + get: function get() { + return _updateTrace[key]; + } + }); + }); + } +}); + +// node_modules/vanilla-swipe/lib/index.js +var require_lib = __commonJS({ + "node_modules/vanilla-swipe/lib/index.js"(exports) { + "use strict"; + function _typeof(obj) { + "@babel/helpers - typeof"; + return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function(obj2) { + return typeof obj2; + } : function(obj2) { + return obj2 && "function" == typeof Symbol && obj2.constructor === Symbol && obj2 !== Symbol.prototype ? "symbol" : typeof obj2; + }, _typeof(obj); + } + Object.defineProperty(exports, "__esModule", { + value: true + }); + var _exportNames = {}; + exports["default"] = void 0; + var Utils2 = _interopRequireWildcard(require_utils()); + var _types = require_types(); + Object.keys(_types).forEach(function(key) { + if (key === "default" || key === "__esModule") + return; + if (Object.prototype.hasOwnProperty.call(_exportNames, key)) + return; + if (key in exports && exports[key] === _types[key]) + return; + Object.defineProperty(exports, key, { + enumerable: true, + get: function get() { + return _types[key]; + } + }); + }); + function _getRequireWildcardCache(nodeInterop) { + if (typeof WeakMap !== "function") + return null; + var cacheBabelInterop = /* @__PURE__ */ new WeakMap(); + var cacheNodeInterop = /* @__PURE__ */ new WeakMap(); + return (_getRequireWildcardCache = function _getRequireWildcardCache2(nodeInterop2) { + return nodeInterop2 ? cacheNodeInterop : cacheBabelInterop; + })(nodeInterop); + } + function _interopRequireWildcard(obj, nodeInterop) { + if (!nodeInterop && obj && obj.__esModule) { + return obj; + } + if (obj === null || _typeof(obj) !== "object" && typeof obj !== "function") { + return { "default": obj }; + } + var cache = _getRequireWildcardCache(nodeInterop); + if (cache && cache.has(obj)) { + return cache.get(obj); + } + var newObj = {}; + var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; + for (var key in obj) { + if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { + var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; + if (desc && (desc.get || desc.set)) { + Object.defineProperty(newObj, key, desc); + } else { + newObj[key] = obj[key]; + } + } + } + newObj["default"] = obj; + if (cache) { + cache.set(obj, newObj); + } + return newObj; + } + function _classCallCheck(instance122, Constructor) { + if (!(instance122 instanceof Constructor)) { + throw new TypeError("Cannot call a class as a function"); + } + } + function _defineProperties(target, props) { + for (var i = 0; i < props.length; i++) { + var descriptor = props[i]; + descriptor.enumerable = descriptor.enumerable || false; + descriptor.configurable = true; + if ("value" in descriptor) + descriptor.writable = true; + Object.defineProperty(target, descriptor.key, descriptor); + } + } + function _createClass(Constructor, protoProps, staticProps) { + if (protoProps) + _defineProperties(Constructor.prototype, protoProps); + if (staticProps) + _defineProperties(Constructor, staticProps); + Object.defineProperty(Constructor, "prototype", { writable: false }); + return Constructor; + } + function _defineProperty(obj, key, value2) { + if (key in obj) { + Object.defineProperty(obj, key, { value: value2, enumerable: true, configurable: true, writable: true }); + } else { + obj[key] = value2; + } + return obj; + } + var VanillaSwipe2 = /* @__PURE__ */ function() { + function VanillaSwipe3(props) { + _classCallCheck(this, VanillaSwipe3); + _defineProperty(this, "state", void 0); + _defineProperty(this, "props", void 0); + this.state = Utils2.getInitialState(); + this.props = Utils2.getInitialProps(props); + this.handleSwipeStart = this.handleSwipeStart.bind(this); + this.handleSwipeMove = this.handleSwipeMove.bind(this); + this.handleSwipeEnd = this.handleSwipeEnd.bind(this); + this.handleMouseDown = this.handleMouseDown.bind(this); + this.handleMouseMove = this.handleMouseMove.bind(this); + this.handleMouseUp = this.handleMouseUp.bind(this); + this.handleMouseLeave = this.handleMouseLeave.bind(this); + } + _createClass(VanillaSwipe3, [{ + key: "init", + value: function init3() { + this.setupTouchListeners(); + this.setupMouseListeners(); + } + }, { + key: "update", + value: function update2(props) { + var prevProps = this.props; + var nextProps = Object.assign({}, prevProps, props); + if (prevProps.element !== nextProps.element || prevProps.target !== nextProps.target) { + this.destroy(); + this.props = nextProps; + this.init(); + return; + } + this.props = nextProps; + if (prevProps.mouseTrackingEnabled !== nextProps.mouseTrackingEnabled || prevProps.preventTrackingOnMouseleave !== nextProps.preventTrackingOnMouseleave) { + this.cleanupMouseListeners(); + nextProps.mouseTrackingEnabled ? this.setupMouseListeners() : this.cleanupMouseListeners(); + } + if (prevProps.touchTrackingEnabled !== nextProps.touchTrackingEnabled) { + this.cleanupTouchListeners(); + nextProps.touchTrackingEnabled ? this.setupTouchListeners() : this.cleanupTouchListeners(); + } + } + }, { + key: "destroy", + value: function destroy() { + this.cleanupMouseListeners(); + this.cleanupTouchListeners(); + this.state = Utils2.getInitialState(); + this.props = Utils2.getInitialProps(); + } + }, { + key: "setupTouchListeners", + value: function setupTouchListeners() { + var _this$props = this.props, element3 = _this$props.element, target = _this$props.target, touchTrackingEnabled = _this$props.touchTrackingEnabled; + if (element3 && touchTrackingEnabled) { + var listener = target || element3; + var isPassiveSupported = Utils2.checkIsPassiveSupported(); + var options = Utils2.getOptions(isPassiveSupported); + listener.addEventListener("touchstart", this.handleSwipeStart, options); + listener.addEventListener("touchmove", this.handleSwipeMove, options); + listener.addEventListener("touchend", this.handleSwipeEnd, options); + } + } + }, { + key: "cleanupTouchListeners", + value: function cleanupTouchListeners() { + var _this$props2 = this.props, element3 = _this$props2.element, target = _this$props2.target; + var listener = target || element3; + if (listener) { + listener.removeEventListener("touchstart", this.handleSwipeStart); + listener.removeEventListener("touchmove", this.handleSwipeMove); + listener.removeEventListener("touchend", this.handleSwipeEnd); + } + } + }, { + key: "setupMouseListeners", + value: function setupMouseListeners() { + var _this$props3 = this.props, element3 = _this$props3.element, mouseTrackingEnabled = _this$props3.mouseTrackingEnabled, preventTrackingOnMouseleave = _this$props3.preventTrackingOnMouseleave; + if (mouseTrackingEnabled && element3) { + element3.addEventListener("mousedown", this.handleMouseDown); + element3.addEventListener("mousemove", this.handleMouseMove); + element3.addEventListener("mouseup", this.handleMouseUp); + if (preventTrackingOnMouseleave) { + element3.addEventListener("mouseleave", this.handleMouseLeave); + } + } + } + }, { + key: "cleanupMouseListeners", + value: function cleanupMouseListeners() { + var element3 = this.props.element; + if (element3) { + element3.removeEventListener("mousedown", this.handleMouseDown); + element3.removeEventListener("mousemove", this.handleMouseMove); + element3.removeEventListener("mouseup", this.handleMouseUp); + element3.removeEventListener("mouseleave", this.handleMouseLeave); + } + } + }, { + key: "getEventData", + value: function getEventData(e) { + var options = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : { + directionDelta: 0 + }; + var rotationAngle = this.props.rotationAngle; + var directionDelta = options.directionDelta; + var movingPosition = Utils2.calculateMovingPosition(e); + var rotatePosition = Utils2.rotateByAngle(movingPosition, rotationAngle); + return Utils2.calculatePosition(this.state, { + rotatePosition, + directionDelta + }); + } + }, { + key: "handleSwipeStart", + value: function handleSwipeStart(e) { + if (Utils2.checkIsMoreThanSingleTouches(e)) + return; + var rotationAngle = this.props.rotationAngle; + var movingPosition = Utils2.calculateMovingPosition(e); + var _Utils$rotateByAngle = Utils2.rotateByAngle(movingPosition, rotationAngle), x = _Utils$rotateByAngle.x, y = _Utils$rotateByAngle.y; + this.state = Utils2.getInitialState({ + isSwiping: false, + start: Date.now(), + x, + y + }); + } + }, { + key: "handleSwipeMove", + value: function handleSwipeMove(e) { + var _this$state = this.state, x = _this$state.x, y = _this$state.y, isSwiping = _this$state.isSwiping; + if (!x || !y || Utils2.checkIsMoreThanSingleTouches(e)) + return; + var directionDelta = this.props.directionDelta || 0; + var _this$getEventData = this.getEventData(e, { + directionDelta + }), absX = _this$getEventData.absX, absY = _this$getEventData.absY, deltaX = _this$getEventData.deltaX, deltaY = _this$getEventData.deltaY, directionX = _this$getEventData.directionX, directionY = _this$getEventData.directionY, duration2 = _this$getEventData.duration, velocity = _this$getEventData.velocity; + var _this$props4 = this.props, delta = _this$props4.delta, preventDefaultTouchmoveEvent = _this$props4.preventDefaultTouchmoveEvent, onSwipeStart = _this$props4.onSwipeStart, onSwiping = _this$props4.onSwiping; + if (e.cancelable && preventDefaultTouchmoveEvent) + e.preventDefault(); + if (absX < Number(delta) && absY < Number(delta) && !isSwiping) + return; + if (onSwipeStart && !isSwiping) { + onSwipeStart(e, { + deltaX, + deltaY, + absX, + absY, + directionX, + directionY, + duration: duration2, + velocity + }); + } + this.state.isSwiping = true; + if (onSwiping) { + onSwiping(e, { + deltaX, + deltaY, + absX, + absY, + directionX, + directionY, + duration: duration2, + velocity + }); + } + } + }, { + key: "handleSwipeEnd", + value: function handleSwipeEnd(e) { + var _this$props5 = this.props, onSwiped = _this$props5.onSwiped, onTap = _this$props5.onTap; + if (this.state.isSwiping) { + var directionDelta = this.props.directionDelta || 0; + var position = this.getEventData(e, { + directionDelta + }); + onSwiped && onSwiped(e, position); + } else { + var _position = this.getEventData(e); + onTap && onTap(e, _position); + } + this.state = Utils2.getInitialState(); + } + }, { + key: "handleMouseDown", + value: function handleMouseDown(e) { + var target = this.props.target; + if (target) { + if (target === e.target) { + this.handleSwipeStart(e); + } + } else { + this.handleSwipeStart(e); + } + } + }, { + key: "handleMouseMove", + value: function handleMouseMove(e) { + this.handleSwipeMove(e); + } + }, { + key: "handleMouseUp", + value: function handleMouseUp(e) { + var isSwiping = this.state.isSwiping; + var target = this.props.target; + if (target) { + if (target === e.target || isSwiping) { + this.handleSwipeEnd(e); + } + } else { + this.handleSwipeEnd(e); + } + } + }, { + key: "handleMouseLeave", + value: function handleMouseLeave(e) { + var isSwiping = this.state.isSwiping; + if (isSwiping) { + this.handleSwipeEnd(e); + } + } + }], [{ + key: "isTouchEventsSupported", + value: function isTouchEventsSupported() { + return Utils2.checkIsTouchEventsSupported(); + } + }]); + return VanillaSwipe3; + }(); + exports["default"] = VanillaSwipe2; + } +}); + +// node_modules/prismjs/prism.js +var require_prism = __commonJS({ + "node_modules/prismjs/prism.js"(exports, module) { + var _self = typeof window !== "undefined" ? window : typeof WorkerGlobalScope !== "undefined" && self instanceof WorkerGlobalScope ? self : {}; + var Prism2 = function(_self2) { + var lang = /(?:^|\s)lang(?:uage)?-([\w-]+)(?=\s|$)/i; + var uniqueId = 0; + var plainTextGrammar = {}; + var _ = { + /** + * By default, Prism will attempt to highlight all code elements (by calling {@link Prism.highlightAll}) on the + * current page after the page finished loading. This might be a problem if e.g. you wanted to asynchronously load + * additional languages or plugins yourself. + * + * By setting this value to `true`, Prism will not automatically highlight all code elements on the page. + * + * You obviously have to change this value before the automatic highlighting started. To do this, you can add an + * empty Prism object into the global scope before loading the Prism script like this: + * + * ```js + * window.Prism = window.Prism || {}; + * Prism.manual = true; + * // add a new