From 7d21b01ac38337b59e857ef23b1c7605dbd6db53 Mon Sep 17 00:00:00 2001 From: Cristine Guadelupe Date: Thu, 31 Aug 2023 21:58:52 +0700 Subject: [PATCH] Updates Glide Data Grid (#323) --- assets/data_table/main.js | 23 +---- assets/data_table/package-lock.json | 14 +-- assets/data_table/package.json | 2 +- lib/assets/data_table/build/main.css | 2 +- lib/assets/data_table/build/main.js | 130 +++++++++++++-------------- 5 files changed, 75 insertions(+), 96 deletions(-) diff --git a/assets/data_table/main.js b/assets/data_table/main.js index c21aa688..b4b827cf 100644 --- a/assets/data_table/main.js +++ b/assets/data_table/main.js @@ -393,27 +393,6 @@ function App({ ctx, data }) { [hoverRows] ); - const getCellsForSelection = useCallback( - ({ x, y, width, height }) => { - const selected = []; - const max = content.columns.length; - const offSet = width >= max ? 0 : x + width >= max ? 0 : rowMarkerOffset; - const rows = [...Array.from({ length: height }, (_, index) => index + y)]; - const cols = [ - ...Array.from({ length: width + offSet }, (_, index) => index + x), - ]; - rows.forEach((i) => { - const row = []; - cols.forEach((j) => { - row.push(getCellContent([j, i])); - }); - selected.push(row); - }); - return selected; - }, - [rowMarkerOffset, getCellContent] - ); - useEffect(() => { selection.rows?.items.length > 0 ? setRowMarkerOffset(1) @@ -514,7 +493,7 @@ function App({ ctx, data }) { onHeaderMenuClick={onHeaderMenuClick} onHeaderClicked={onHeaderClicked} showSearch={showSearch} - getCellsForSelection={getCellsForSelection} + getCellsForSelection={true} onSearchClose={toggleSearch} headerIcons={customHeaderIcons} overscrollX={100} diff --git a/assets/data_table/package-lock.json b/assets/data_table/package-lock.json index 994e1432..e1e21adf 100644 --- a/assets/data_table/package-lock.json +++ b/assets/data_table/package-lock.json @@ -5,7 +5,7 @@ "packages": { "": { "dependencies": { - "@glideapps/glide-data-grid": "^5.2.0", + "@glideapps/glide-data-grid": "^5.3.0", "lodash": "^4.17.21", "marked": "^4.2.2", "react": "^18.2.0", @@ -51,9 +51,9 @@ } }, "node_modules/@glideapps/glide-data-grid": { - "version": "5.2.0", - "resolved": "https://registry.npmjs.org/@glideapps/glide-data-grid/-/glide-data-grid-5.2.0.tgz", - "integrity": "sha512-Fl6rnSIFRaE9IA5SXrPk9YmYjvCgwdT+iYGVSZB9CjCfoskKsvdVP1oUZzNGR7qc6x+G29rnCLwpjBT/MZT41A==", + "version": "5.3.0", + "resolved": "https://registry.npmjs.org/@glideapps/glide-data-grid/-/glide-data-grid-5.3.0.tgz", + "integrity": "sha512-dqNrwFftKEy1kECWkOjBCIllugJhF55HL9f0vxgzInA7Im6h8O/WWpJdPiNsZcN8x4gXWB5M92vfJ0TsV7gcWw==", "dependencies": { "canvas-hypertxt": "^0.0.7", "react-number-format": "^5.0.0" @@ -594,9 +594,9 @@ "optional": true }, "@glideapps/glide-data-grid": { - "version": "5.2.0", - "resolved": "https://registry.npmjs.org/@glideapps/glide-data-grid/-/glide-data-grid-5.2.0.tgz", - "integrity": "sha512-Fl6rnSIFRaE9IA5SXrPk9YmYjvCgwdT+iYGVSZB9CjCfoskKsvdVP1oUZzNGR7qc6x+G29rnCLwpjBT/MZT41A==", + "version": "5.3.0", + "resolved": "https://registry.npmjs.org/@glideapps/glide-data-grid/-/glide-data-grid-5.3.0.tgz", + "integrity": "sha512-dqNrwFftKEy1kECWkOjBCIllugJhF55HL9f0vxgzInA7Im6h8O/WWpJdPiNsZcN8x4gXWB5M92vfJ0TsV7gcWw==", "requires": { "canvas-hypertxt": "^0.0.7", "react-number-format": "^5.0.0" diff --git a/assets/data_table/package.json b/assets/data_table/package.json index 9dc72fc0..03f98069 100644 --- a/assets/data_table/package.json +++ b/assets/data_table/package.json @@ -5,7 +5,7 @@ "dev": "esbuild main.js --bundle --minify --outfile=../../lib/assets/data_table/build/main.js --format=esm --loader:.js=jsx --watch" }, "dependencies": { - "@glideapps/glide-data-grid": "^5.2.0", + "@glideapps/glide-data-grid": "^5.3.0", "lodash": "^4.17.21", "marked": "^4.2.2", "react": "^18.2.0", diff --git a/lib/assets/data_table/build/main.css b/lib/assets/data_table/build/main.css index 5928b6b2..da5c64ce 100644 --- a/lib/assets/data_table/build/main.css +++ b/lib/assets/data_table/build/main.css @@ -1 +1 @@ -.d1t1th9s{position:absolute;display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-flex-direction:column;-ms-flex-direction:column;flex-direction:column;overflow:hidden;box-sizing:border-box;--overlay-top:var(--d1t1th9s-0);left:var(--d1t1th9s-1);top:var(--d1t1th9s-2);min-width:var(--d1t1th9s-3);min-height:var(--d1t1th9s-4);width:-webkit-max-content;width:-moz-max-content;width:max-content;max-width:400px;max-height:calc(100vh - var(--d1t1th9s-5));font-family:var(--gdg-font-family);font-size:var(--gdg-editor-font-size);text-align:start}@-webkit-keyframes glide_fade_in-d1t1th9s{0%{opacity:0%}to{opacity:100%}}@keyframes glide_fade_in-d1t1th9s{0%{opacity:0%}to{opacity:100%}}.d1t1th9s.gdg-style{border-radius:2px;background-color:var(--gdg-bg-cell);box-shadow:0 0 0 1px var(--gdg-accent-color),0 0 1px #3e415666,0 6px 12px #3e415626;-webkit-animation:glide_fade_in-d1t1th9s 60ms 1;animation:glide_fade_in-d1t1th9s 60ms 1}.d1t1th9s.pad{padding:var(--d1t1th9s-6) 8.5px 3px}.d1t1th9s .clip-region{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-flex-direction:column;-ms-flex-direction:column;flex-direction:column;overflow-y:auto;overflow-x:hidden;border-radius:2px;-webkit-box-flex:1;-webkit-flex-grow:1;-ms-flex-positive:1;flex-grow:1}.d1t1th9s .clip-region .gdg-growing-entry{height:100%}.d1t1th9s .clip-region input.gdg-input{width:100%;border:none;border-width:0;outline:none}.d1t1th9s .clip-region textarea.gdg-input{border:none;border-width:0;outline:none}.m15w2ly5{position:absolute;right:44px;bottom:44px;background-color:var(--gdg-bg-cell);background:linear-gradient(var(--gdg-bg-cell),var(--gdg-bg-cell-medium));border-radius:4px;z-index:1;box-shadow:0 0 0 1px var(--gdg-border-color),0 2px 5px #00000014;overflow:hidden}.m15w2ly5 .header{position:absolute;left:0;top:0;width:100%;height:4px;background-color:var(--gdg-bg-header);box-shadow:0 0 0 1px var(--gdg-border-color)}.m15w2ly5 .locationMarker{position:absolute;border:1px solid var(--gdg-accent-color);background-color:var(--gdg-accent-light)}.s1jz82f8 .dvn-scroller{overflow:var(--s1jz82f8-0);-webkit-transform:translate3d(0,0,0);-ms-transform:translate3d(0,0,0);transform:translateZ(0)}.s1jz82f8 .hidden{visibility:hidden}.s1jz82f8 .dvn-scroll-inner{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;pointer-events:none}.s1jz82f8 .dvn-scroll-inner>*{-webkit-flex-shrink:0;-ms-flex-negative:0;flex-shrink:0}.s1jz82f8 .dvn-scroll-inner .dvn-spacer{-webkit-box-flex:1;-webkit-flex-grow:1;-ms-flex-positive:1;flex-grow:1}.s1jz82f8 .dvn-scroll-inner .dvn-stack{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-flex-direction:column;-ms-flex-direction:column;flex-direction:column}.s1jz82f8 .dvn-underlay>*{position:absolute;left:0;top:0}.s1jz82f8 canvas{outline:none}.s1jz82f8 canvas *{height:0}.sxep88s{position:absolute;top:4px;right:20px;background-color:var(--gdg-bg-cell);color:var(--gdg-text-dark);padding:8px;border:1px solid var(--gdg-border-color);border-radius:6px;font-size:var(--gdg-editor-font-size);-webkit-transform:translateX(var(--sxep88s-0));-ms-transform:translateX(var(--sxep88s-0));transform:translate(var(--sxep88s-0));-webkit-transition:-webkit-transform .15s;-webkit-transition:transform .15s;transition:transform .15s}.sxep88s .search-bar-inner{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex}.sxep88s .search-status{padding-top:4px;font-size:11px}.sxep88s .search-progress{position:absolute;height:4px;left:0;bottom:0;background-color:var(--gdg-text-light)}.sxep88s input{width:220px;color:var(--gdg-textDark);background-color:var(--gdg-bg-cell);border:none;border-width:0;outline:none}.sxep88s button{width:24px;height:24px;padding:0;border:none;outline:none;background:none;display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-box-pack:center;-webkit-justify-content:center;-ms-flex-pack:center;justify-content:center;-webkit-align-items:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center;cursor:pointer;color:var(--gdg-text-medium)}.sxep88s button:hover{color:var(--gdg-text-dark)}.sxep88s button .button-icon{width:16px;height:16px}.sxep88s button:disabled{opacity:.4;pointer-events:none}.r1kzy40b{-webkit-box-flex:1;-webkit-flex-grow:1;-ms-flex-positive:1;flex-grow:1;border:none;outline:none;background-color:var(--gdg-bg-header-has-focus);border-radius:9px;padding:0 8px;box-shadow:0 0 0 1px var(--gdg-border-color);color:var(--gdg-text-group-header);min-height:var(--r1kzy40b-0);font:var(--gdg-header-font-style) var(--gdg-font-family)}.c1sqdbw3{padding:0 8px;display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-align-items:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center;background-color:var(--gdg-bg-header)}.wzg2m5k{position:relative;min-width:10px;min-height:10px;max-width:100%;max-height:100%;width:var(--wzg2m5k-0);height:var(--wzg2m5k-1);overflow:hidden;overflow:clip;contain:strict}.wzg2m5k>:first-child{position:absolute;left:0;top:0;width:100%;height:100%}.b1bqsp5z{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-flex-wrap:wrap;-ms-flex-wrap:wrap;flex-wrap:wrap}.b1bqsp5z .boe-bubble{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-box-pack:center;-webkit-justify-content:center;-ms-flex-pack:center;justify-content:center;-webkit-align-items:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center;border-radius:100px;padding:0 8px;height:20px;background-color:var(--gdg-bg-bubble);color:var(--gdg-text-dark);margin:2px}.b1bqsp5z textarea{position:absolute;top:0;left:0;width:0px;height:0px;opacity:0}.df2kt4a{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-flex-wrap:wrap;-ms-flex-wrap:wrap;flex-wrap:wrap}.df2kt4a .doe-bubble{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-box-pack:center;-webkit-justify-content:center;-ms-flex-pack:center;justify-content:center;-webkit-align-items:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center;padding:0 8px;height:24px;background-color:var(--gdg-bg-cell);color:var(--gdg-text-dark);margin:2px;border-radius:6px;box-shadow:0 0 1px #3e415666,0 1px 3px #3e415666}.df2kt4a .doe-bubble img{height:16px;object-fit:contain;margin-right:4px}.df2kt4a textarea{position:absolute;top:0;left:0;width:0px;height:0px;opacity:0}.i1eozt10{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;height:100%}.i1eozt10 .centering-container{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-box-pack:center;-webkit-justify-content:center;-ms-flex-pack:center;justify-content:center;-webkit-align-items:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center;height:100%}.i1eozt10 .centering-container img,.i1eozt10 .centering-container canvas{max-height:calc(100vh - var(--overlay-top) - 20px);object-fit:contain;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}.i1eozt10 .centering-container canvas{max-width:380px}.i1eozt10 .edit-icon{position:absolute;top:12px;right:0;width:48px;height:48px;color:var(--gdg-accent-color);cursor:pointer;display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-box-pack:center;-webkit-justify-content:center;-ms-flex-pack:center;justify-content:center;-webkit-align-items:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center}.i1eozt10 .edit-icon>*{width:24px;height:24px}.i1eozt10 textarea{position:absolute;top:0;left:0;width:0px;height:0px;opacity:0}.mlbeo71{word-break:break-word;-webkit-touch-callout:default;padding-top:6px}.mlbeo71>*{margin:0}.mlbeo71 *:last-child{margin-bottom:0}.mlbeo71 p img{width:100%}.ijuk0po{position:absolute;inset:0;width:100%;height:100%;border-radius:0;resize:none;white-space:pre-wrap;min-width:100%;overflow:hidden;border:0;background-color:transparent;font-size:var(--gdg-editor-font-size);line-height:16px;font-family:var(--gdg-font-family);color:var(--gdg-text-dark);padding:0;margin:0}.ijuk0po::-webkit-input-placeholder{color:var(--gdg-text-light)}.ijuk0po::-moz-placeholder{color:var(--gdg-text-light)}.ijuk0po:-ms-input-placeholder{color:var(--gdg-text-light)}.ijuk0po::placeholder{color:var(--gdg-text-light)}.invalid .ijuk0po{-webkit-text-decoration:underline;text-decoration:underline;-webkit-text-decoration-color:#d60606;text-decoration-color:#d60606}.saq3p5l{visibility:hidden;white-space:pre-wrap;word-wrap:break-word;width:-webkit-max-content;width:-moz-max-content;width:max-content;max-width:100%;min-width:100%;font-size:var(--gdg-editor-font-size);line-height:16px;font-family:var(--gdg-font-family);color:var(--gdg-text-dark);padding:0 0 2px;margin:0}.gf8vzix{position:relative;margin-top:6px}.mdwzdl1{min-width:var(--mdwzdl1-0);width:100%;display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-align-items:flex-start;-webkit-box-align:flex-start;-ms-flex-align:flex-start;align-items:flex-start;-webkit-box-pack:justify;-webkit-justify-content:space-between;-ms-flex-pack:justify;justify-content:space-between;position:relative;color:var(--gdg-text-dark)}.mdwzdl1 .gf8vzix{-webkit-flex-shrink:1;-ms-flex-negative:1;flex-shrink:1;min-width:0}.mdwzdl1 .spacer{-webkit-flex:1;-ms-flex:1;flex:1}.mdwzdl1 .edit-icon{position:relative;cursor:pointer;display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-box-pack:center;-webkit-justify-content:center;-ms-flex-pack:center;justify-content:center;-webkit-align-items:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center;color:var(--gdg-accent-color);padding:0;height:24px;width:24px;-webkit-flex-shrink:0;-ms-flex-negative:0;flex-shrink:0;-webkit-transition:all "0.125s ease";transition:all "0.125s ease";border-radius:6px}.mdwzdl1 .edit-icon>*{width:16px;height:16px}.mdwzdl1 .edit-hover:hover{background-color:var(--gdg-accent-light);-webkit-transition:background-color .15s;transition:background-color .15s}.mdwzdl1 .checkmark-hover:hover{color:#fff;background-color:var(--gdg-accent-color)}.mdwzdl1 .md-edit-textarea{position:relative;top:0;left:0;width:0px;height:0px;margin-top:25px;opacity:0;padding:0}.mdwzdl1 .ml-6{margin-left:6px}.n1czszh3{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;margin:6px 0 3px;color:var(--gdg-text-dark)}.n1czszh3>input{font-size:var(--gdg-editor-font-size);padding:0;font-family:var(--gdg-font-family);color:var(--gdg-text-dark);background-color:var(--gdg-bg-cell)}.uf0sjo8{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-box-flex:1;-webkit-flex-grow:1;-ms-flex-positive:1;flex-grow:1;-webkit-align-items:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center;min-height:21px}.uf0sjo8 .link-area{-webkit-box-flex:1;-webkit-flex-grow:1;-ms-flex-positive:1;flex-grow:1;-webkit-flex-shrink:1;-ms-flex-negative:1;flex-shrink:1;cursor:pointer;margin-right:8px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;color:var(--gdg-link-color);-webkit-text-decoration:underline!important;text-decoration:underline!important}.uf0sjo8 .edit-icon{-webkit-flex-shrink:0;-ms-flex-negative:0;flex-shrink:0;width:32px;color:var(--gdg-accent-color);cursor:pointer;display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-box-pack:center;-webkit-justify-content:center;-ms-flex-pack:center;justify-content:center;-webkit-align-items:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center}.uf0sjo8 .edit-icon>*{width:24px;height:24px}.uf0sjo8 textarea{position:absolute;top:0;left:0;width:0px;height:0px;opacity:0}html{font-size:87.5%}.app{font-family:Inter;padding:12px;--gray-50: #f8fafc;--gray-100: #f0f5f9;--gray-200: #e1e8f0;--gray-300: #cad5e0;--gray-400: #91a4b7;--gray-500: #61758a;--gray-600: #445668;--gray-700: #304254;--gray-800: #1c2a3a}.navigation{margin-bottom:24px;display:flex;align-items:center}.navigation>:not(:first-child){margin-left:12px}.navigation__info{display:flex;align-items:baseline}.navigation__name{margin:0;font-size:1.125rem;line-height:1;font-weight:600;color:var(--gray-800)}.navigation__details{margin-left:10px;font-size:.875rem;line-height:1}.navigation__space{flex-grow:1}.pagination{display:flex}.pagination>:not(:first-child){margin-left:8px}.pagination__button{font-family:inherit;background:none;border:none;cursor:pointer;display:flex;align-items:center;font-weight:500;font-size:.875rem;color:var(--gray-500)}.pagination__button:hover{color:var(--gray-800)}.pagination__button:focus{outline:none}.pagination__button:disabled{pointer-events:none;color:var(--gray-300)}.pagination__info{padding:4px 8px;border:1px solid var(--gray-400);font-size:.875rem;font-weight:500;color:var(--gray-500);border-radius:8px}.table-container{box-shadow:0 0 25px -5px #0000001a,0 0 10px -5px #0000000a;border-radius:8px;max-width:100%}.icon-button{background:none;border:none;cursor:pointer;padding:4px;display:flex;align-items:center;justify-content:center;border-radius:100%;color:var(--gray-500);line-height:1}.icon-button:hover{color:var(--gray-900)}.icon-button:focus{outline:none;background-color:var(--gray-100)}.icon-button:disabled{color:var(--gray-300);cursor:default}.no-data{color:var(--gray-700)}.no-entries{color:var(--gray-700);font-weight:500}.invisible{visibility:hidden}.ri{font-size:1.25rem;vertical-align:middle;line-height:1}.sr-only{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border-width:0}.button{appearance:none;font-weight:500;background-color:var(--gray-100);border:1px solid var(--gray-200);border-radius:8px;padding:5px 10px;margin-bottom:5px}.button:hover{cursor:pointer;background-color:var(--gray-200)}.button--transparent{background:transparent;padding:4px 8px;border:1px solid var(--gray-400);font-size:.875rem;font-weight:500;color:var(--gray-500);border-radius:8px}.button--transparent:hover{background-color:var(--gray-100)}.input{appearance:none;padding:4px 8px;border:1px solid var(--gray-400);font-size:.875rem;font-weight:500;color:var(--gray-500);border-radius:8px;background-color:#fff}.input:focus{outline:none}.input-label{font-size:.875rem;color:var(--gray-500);font-weight:500;padding:4px}select.input{appearance:none;background-image:url(data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMTIiIGhlaWdodD0iOCIgdmlld0JveD0iMCAwIDEyIDgiIGZpbGw9Im5vbmUiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+CjxwYXRoIGQ9Ik01Ljk5OTg5IDQuOTc2NzFMMTAuMTI0OSAwLjg1MTcwOEwxMS4zMDMyIDIuMDMwMDRMNS45OTk4OSA3LjMzMzM3TDAuNjk2NTU1IDIuMDMwMDRMMS44NzQ4OSAwLjg1MTcwOEw1Ljk5OTg5IDQuOTc2NzFaIiBmaWxsPSIjNjE3NThBIi8+Cjwvc3ZnPgo=);background-repeat:no-repeat;background-position:center right 10px;background-size:10px;padding-right:28px}select option{color:#000}select.input__icon{appearance:none;background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M13 12H16L12 16L8 12H11V8H13V12ZM15 4H5V20H19V8H15V4ZM3 2.9918C3 2.44405 3.44749 2 3.9985 2H16L20.9997 7L21 20.9925C21 21.5489 20.5551 22 20.0066 22H3.9934C3.44476 22 3 21.5447 3 21.0082V2.9918Z' fill='rgba(97,117,138,1)'%3E%3C/path%3E%3C/svg%3E");background-repeat:no-repeat;background-size:17px;padding-right:18px;border:none;color:#fff;width:18px;height:18px;background-color:transparent}select.input__icon:hover{cursor:pointer;background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M13 12H16L12 16L8 12H11V8H13V12ZM15 4H5V20H19V8H15V4ZM3 2.9918C3 2.44405 3.44749 2 3.9985 2H16L20.9997 7L21 20.9925C21 21.5489 20.5551 22 20.0066 22H3.9934C3.44476 22 3 21.5447 3 21.0082V2.9918Z' fill='rgba(28,42,58,1)'%3E%3C/path%3E%3C/svg%3E")}select.input__icon:focus{outline:none}.tooltip{position:relative;display:flex;--distance: 4px;--arrow-size: 5px;--show-delay: .5s}.tooltip:before{position:absolute;content:attr(data-tooltip);white-space:pre;text-align:center;display:block;z-index:100;background-color:#1c273c;color:#f0f5f9;font-size:12px;font-weight:500;border-radius:4px;padding:3px 12px;visibility:hidden;transition-property:visibility;transition-duration:0s;transition-delay:0s}.tooltip:after{content:"";position:absolute;display:block;z-index:100;border-width:var(--arrow-size);border-style:solid;border-color:#1c273c;visibility:hidden;transition-property:visibility;transition-duration:0s;transition-delay:0s}.tooltip:hover:before{visibility:visible;transition-delay:var(--show-delay)}.tooltip:hover:after{visibility:visible;transition-delay:var(--show-delay)}.tooltip.right:before{top:50%;left:100%;transform:translate(calc(var(--arrow-size) - 1px + var(--distance)),-50%)}.tooltip.right:after{top:50%;left:100%;transform:translate(var(--distance),-50%);border-left:none;border-top-color:transparent;border-bottom-color:transparent}.header-menu{width:175px;padding:8px;border-radius:0 0 6px 6px;box-shadow:0 10px 15px -3px #0000001a,0 4px 6px -2px #0000000d;border:1px solid #e1e8f0;display:flex;flex-direction:column;background-color:#fff}.header-menu-item{font-size:.975rem;font-family:Inter;color:#304254;padding:4px;display:flex;justify-content:flex-start;align-items:center;gap:4px}.header-menu-item:hover{cursor:pointer;background-color:#f0f5f9}.header-menu-item.input-label{font-weight:500;padding-left:2px}.header-menu-item.button{font-weight:500;background-color:#f0f5f9;border:1px solid #e1e8f0;width:100%;justify-content:center;margin-bottom:6px}.header-menu-item.button:hover{cursor:pointer;background-color:#e1e8f0}.header-menu-input{border:1px solid #e1e8f0;color:#61758a;width:100%;margin-bottom:4px;font-size:.975rem}.header-menu-input:disabled{opacity:50%}.inline-form{display:flex;flex-direction:row;align-items:center;justify-content:space-between;margin-right:2px}.inline-form .input{border:none;background-color:transparent;background-position:center right 0px;cursor:pointer;text-align:right;padding-right:14px}.input-wrapper{display:flex;justify-content:space-between;align-items:center;margin-top:4px}.input-full{min-width:65%;padding-right:50px}.input__button{padding:4px 8px;border:none;cursor:pointer;display:flex;color:#304254;align-items:center;background-color:#f0f5f9;border-radius:0 8px 8px 0;position:relative;right:47px;bottom:2px;height:25px}.input__button:hover{background-color:#e1e8f0}.input__button:focus{outline:none}.input__button:disabled{pointer-events:none;color:#91a4b7}.inline-buttons{display:flex;align-items:center;gap:12px}.navigation .download{margin-left:8px}.search-icon{width:1.3em;height:1.3em} +.d1t1th9s{position:absolute;display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-flex-direction:column;-ms-flex-direction:column;flex-direction:column;overflow:hidden;box-sizing:border-box;--overlay-top:var(--d1t1th9s-0);left:var(--d1t1th9s-1);top:var(--d1t1th9s-2);min-width:var(--d1t1th9s-3);min-height:var(--d1t1th9s-4);width:-webkit-max-content;width:-moz-max-content;width:max-content;max-width:400px;max-height:calc(100vh - var(--d1t1th9s-5));font-family:var(--gdg-font-family);font-size:var(--gdg-editor-font-size);text-align:start}@-webkit-keyframes glide_fade_in-d1t1th9s{0%{opacity:0%}to{opacity:100%}}@keyframes glide_fade_in-d1t1th9s{0%{opacity:0%}to{opacity:100%}}.d1t1th9s.gdg-style{border-radius:2px;background-color:var(--gdg-bg-cell);box-shadow:0 0 0 1px var(--gdg-accent-color),0 0 1px #3e415666,0 6px 12px #3e415626;-webkit-animation:glide_fade_in-d1t1th9s 60ms 1;animation:glide_fade_in-d1t1th9s 60ms 1}.d1t1th9s.pad{padding:var(--d1t1th9s-6) 8.5px 3px}.d1t1th9s .clip-region{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-flex-direction:column;-ms-flex-direction:column;flex-direction:column;overflow-y:auto;overflow-x:hidden;border-radius:2px;-webkit-box-flex:1;-webkit-flex-grow:1;-ms-flex-positive:1;flex-grow:1}.d1t1th9s .clip-region .gdg-growing-entry{height:100%}.d1t1th9s .clip-region input.gdg-input{width:100%;border:none;border-width:0;outline:none}.d1t1th9s .clip-region textarea.gdg-input{border:none;border-width:0;outline:none}.m15w2ly5{position:absolute;right:44px;bottom:44px;background-color:var(--gdg-bg-cell);background:linear-gradient(var(--gdg-bg-cell),var(--gdg-bg-cell-medium));border-radius:4px;z-index:1;box-shadow:0 0 0 1px var(--gdg-border-color),0 2px 5px #00000014;overflow:hidden}.m15w2ly5 .header{position:absolute;left:0;top:0;width:100%;height:4px;background-color:var(--gdg-bg-header);box-shadow:0 0 0 1px var(--gdg-border-color)}.m15w2ly5 .locationMarker{position:absolute;border:1px solid var(--gdg-accent-color);background-color:var(--gdg-accent-light)}.s1jz82f8 .dvn-scroller{overflow:var(--s1jz82f8-0);-webkit-transform:translate3d(0,0,0);-ms-transform:translate3d(0,0,0);transform:translateZ(0)}.s1jz82f8 .hidden{visibility:hidden}.s1jz82f8 .dvn-scroll-inner{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;pointer-events:none}.s1jz82f8 .dvn-scroll-inner>*{-webkit-flex-shrink:0;-ms-flex-negative:0;flex-shrink:0}.s1jz82f8 .dvn-scroll-inner .dvn-spacer{-webkit-box-flex:1;-webkit-flex-grow:1;-ms-flex-positive:1;flex-grow:1}.s1jz82f8 .dvn-scroll-inner .dvn-stack{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-flex-direction:column;-ms-flex-direction:column;flex-direction:column}.s1jz82f8 .dvn-underlay>*{position:absolute;left:0;top:0}.s1jz82f8 canvas{outline:none}.s1jz82f8 canvas *{height:0}.sxep88s{position:absolute;top:4px;right:20px;background-color:var(--gdg-bg-cell);color:var(--gdg-text-dark);padding:8px;border:1px solid var(--gdg-border-color);border-radius:6px;font-size:var(--gdg-editor-font-size);-webkit-transform:translateX(var(--sxep88s-0));-ms-transform:translateX(var(--sxep88s-0));transform:translate(var(--sxep88s-0));-webkit-transition:-webkit-transform .15s;-webkit-transition:transform .15s;transition:transform .15s}.sxep88s .search-bar-inner{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex}.sxep88s .search-status{padding-top:4px;font-size:11px}.sxep88s .search-progress{position:absolute;height:4px;left:0;bottom:0;background-color:var(--gdg-text-light)}.sxep88s input{width:220px;color:var(--gdg-textDark);background-color:var(--gdg-bg-cell);border:none;border-width:0;outline:none}.sxep88s button{width:24px;height:24px;padding:0;border:none;outline:none;background:none;display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-box-pack:center;-webkit-justify-content:center;-ms-flex-pack:center;justify-content:center;-webkit-align-items:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center;cursor:pointer;color:var(--gdg-text-medium)}.sxep88s button:hover{color:var(--gdg-text-dark)}.sxep88s button .button-icon{width:16px;height:16px}.sxep88s button:disabled{opacity:.4;pointer-events:none}.r1kzy40b{-webkit-box-flex:1;-webkit-flex-grow:1;-ms-flex-positive:1;flex-grow:1;border:none;outline:none;background-color:var(--gdg-bg-header-has-focus);border-radius:9px;padding:0 8px;box-shadow:0 0 0 1px var(--gdg-border-color);color:var(--gdg-text-group-header);min-height:var(--r1kzy40b-0);font:var(--gdg-header-font-style) var(--gdg-font-family)}.c1sqdbw3{padding:0 8px;display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-align-items:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center;background-color:var(--gdg-bg-header)}.wzg2m5k{position:relative;min-width:10px;min-height:10px;max-width:100%;max-height:100%;width:var(--wzg2m5k-0);height:var(--wzg2m5k-1);overflow:hidden;overflow:clip;contain:strict;direction:ltr}.wzg2m5k>:first-child{position:absolute;left:0;top:0;width:100%;height:100%}.b1bqsp5z{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-flex-wrap:wrap;-ms-flex-wrap:wrap;flex-wrap:wrap}.b1bqsp5z .boe-bubble{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-box-pack:center;-webkit-justify-content:center;-ms-flex-pack:center;justify-content:center;-webkit-align-items:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center;border-radius:100px;padding:0 8px;height:20px;background-color:var(--gdg-bg-bubble);color:var(--gdg-text-dark);margin:2px}.b1bqsp5z textarea{position:absolute;top:0;left:0;width:0px;height:0px;opacity:0}.df2kt4a{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-flex-wrap:wrap;-ms-flex-wrap:wrap;flex-wrap:wrap}.df2kt4a .doe-bubble{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-box-pack:center;-webkit-justify-content:center;-ms-flex-pack:center;justify-content:center;-webkit-align-items:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center;padding:0 8px;height:24px;background-color:var(--gdg-bg-cell);color:var(--gdg-text-dark);margin:2px;border-radius:6px;box-shadow:0 0 1px #3e415666,0 1px 3px #3e415666}.df2kt4a .doe-bubble img{height:16px;object-fit:contain;margin-right:4px}.df2kt4a textarea{position:absolute;top:0;left:0;width:0px;height:0px;opacity:0}.i1eozt10{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;height:100%}.i1eozt10 .centering-container{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-box-pack:center;-webkit-justify-content:center;-ms-flex-pack:center;justify-content:center;-webkit-align-items:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center;height:100%}.i1eozt10 .centering-container img,.i1eozt10 .centering-container canvas{max-height:calc(100vh - var(--overlay-top) - 20px);object-fit:contain;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}.i1eozt10 .centering-container canvas{max-width:380px}.i1eozt10 .edit-icon{position:absolute;top:12px;right:0;width:48px;height:48px;color:var(--gdg-accent-color);cursor:pointer;display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-box-pack:center;-webkit-justify-content:center;-ms-flex-pack:center;justify-content:center;-webkit-align-items:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center}.i1eozt10 .edit-icon>*{width:24px;height:24px}.i1eozt10 textarea{position:absolute;top:0;left:0;width:0px;height:0px;opacity:0}.mlbeo71{word-break:break-word;-webkit-touch-callout:default;padding-top:6px}.mlbeo71>*{margin:0}.mlbeo71 *:last-child{margin-bottom:0}.mlbeo71 p img{width:100%}.ijuk0po{position:absolute;inset:0;width:100%;height:100%;border-radius:0;resize:none;white-space:pre-wrap;min-width:100%;overflow:hidden;border:0;background-color:transparent;font-size:var(--gdg-editor-font-size);line-height:16px;font-family:var(--gdg-font-family);color:var(--gdg-text-dark);padding:0;margin:0}.ijuk0po::-webkit-input-placeholder{color:var(--gdg-text-light)}.ijuk0po::-moz-placeholder{color:var(--gdg-text-light)}.ijuk0po:-ms-input-placeholder{color:var(--gdg-text-light)}.ijuk0po::placeholder{color:var(--gdg-text-light)}.invalid .ijuk0po{-webkit-text-decoration:underline;text-decoration:underline;-webkit-text-decoration-color:#d60606;text-decoration-color:#d60606}.saq3p5l{visibility:hidden;white-space:pre-wrap;word-wrap:break-word;width:-webkit-max-content;width:-moz-max-content;width:max-content;max-width:100%;min-width:100%;font-size:var(--gdg-editor-font-size);line-height:16px;font-family:var(--gdg-font-family);color:var(--gdg-text-dark);padding:0 0 2px;margin:0}.gf8vzix{position:relative;margin-top:6px}.mdwzdl1{min-width:var(--mdwzdl1-0);width:100%;display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-align-items:flex-start;-webkit-box-align:flex-start;-ms-flex-align:flex-start;align-items:flex-start;-webkit-box-pack:justify;-webkit-justify-content:space-between;-ms-flex-pack:justify;justify-content:space-between;position:relative;color:var(--gdg-text-dark)}.mdwzdl1 .gf8vzix{-webkit-flex-shrink:1;-ms-flex-negative:1;flex-shrink:1;min-width:0}.mdwzdl1 .spacer{-webkit-flex:1;-ms-flex:1;flex:1}.mdwzdl1 .edit-icon{position:relative;cursor:pointer;display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-box-pack:center;-webkit-justify-content:center;-ms-flex-pack:center;justify-content:center;-webkit-align-items:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center;color:var(--gdg-accent-color);padding:0;height:24px;width:24px;-webkit-flex-shrink:0;-ms-flex-negative:0;flex-shrink:0;-webkit-transition:all "0.125s ease";transition:all "0.125s ease";border-radius:6px}.mdwzdl1 .edit-icon>*{width:16px;height:16px}.mdwzdl1 .edit-hover:hover{background-color:var(--gdg-accent-light);-webkit-transition:background-color .15s;transition:background-color .15s}.mdwzdl1 .checkmark-hover:hover{color:#fff;background-color:var(--gdg-accent-color)}.mdwzdl1 .md-edit-textarea{position:relative;top:0;left:0;width:0px;height:0px;margin-top:25px;opacity:0;padding:0}.mdwzdl1 .ml-6{margin-left:6px}.n1czszh3{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;margin:6px 0 3px;color:var(--gdg-text-dark)}.n1czszh3>input{font-size:var(--gdg-editor-font-size);padding:0;font-family:var(--gdg-font-family);color:var(--gdg-text-dark);background-color:var(--gdg-bg-cell)}.uf0sjo8{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-box-flex:1;-webkit-flex-grow:1;-ms-flex-positive:1;flex-grow:1;-webkit-align-items:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center;min-height:21px}.uf0sjo8 .link-area{-webkit-box-flex:1;-webkit-flex-grow:1;-ms-flex-positive:1;flex-grow:1;-webkit-flex-shrink:1;-ms-flex-negative:1;flex-shrink:1;cursor:pointer;margin-right:8px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;color:var(--gdg-link-color);-webkit-text-decoration:underline!important;text-decoration:underline!important}.uf0sjo8 .edit-icon{-webkit-flex-shrink:0;-ms-flex-negative:0;flex-shrink:0;width:32px;color:var(--gdg-accent-color);cursor:pointer;display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-box-pack:center;-webkit-justify-content:center;-ms-flex-pack:center;justify-content:center;-webkit-align-items:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center}.uf0sjo8 .edit-icon>*{width:24px;height:24px}.uf0sjo8 textarea{position:absolute;top:0;left:0;width:0px;height:0px;opacity:0}html{font-size:87.5%}.app{font-family:Inter;padding:12px;--gray-50: #f8fafc;--gray-100: #f0f5f9;--gray-200: #e1e8f0;--gray-300: #cad5e0;--gray-400: #91a4b7;--gray-500: #61758a;--gray-600: #445668;--gray-700: #304254;--gray-800: #1c2a3a}.navigation{margin-bottom:24px;display:flex;align-items:center}.navigation>:not(:first-child){margin-left:12px}.navigation__info{display:flex;align-items:baseline}.navigation__name{margin:0;font-size:1.125rem;line-height:1;font-weight:600;color:var(--gray-800)}.navigation__details{margin-left:10px;font-size:.875rem;line-height:1}.navigation__space{flex-grow:1}.pagination{display:flex}.pagination>:not(:first-child){margin-left:8px}.pagination__button{font-family:inherit;background:none;border:none;cursor:pointer;display:flex;align-items:center;font-weight:500;font-size:.875rem;color:var(--gray-500)}.pagination__button:hover{color:var(--gray-800)}.pagination__button:focus{outline:none}.pagination__button:disabled{pointer-events:none;color:var(--gray-300)}.pagination__info{padding:4px 8px;border:1px solid var(--gray-400);font-size:.875rem;font-weight:500;color:var(--gray-500);border-radius:8px}.table-container{box-shadow:0 0 25px -5px #0000001a,0 0 10px -5px #0000000a;border-radius:8px;max-width:100%}.icon-button{background:none;border:none;cursor:pointer;padding:4px;display:flex;align-items:center;justify-content:center;border-radius:100%;color:var(--gray-500);line-height:1}.icon-button:hover{color:var(--gray-900)}.icon-button:focus{outline:none;background-color:var(--gray-100)}.icon-button:disabled{color:var(--gray-300);cursor:default}.no-data{color:var(--gray-700)}.no-entries{color:var(--gray-700);font-weight:500}.invisible{visibility:hidden}.ri{font-size:1.25rem;vertical-align:middle;line-height:1}.sr-only{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border-width:0}.button{appearance:none;font-weight:500;background-color:var(--gray-100);border:1px solid var(--gray-200);border-radius:8px;padding:5px 10px;margin-bottom:5px}.button:hover{cursor:pointer;background-color:var(--gray-200)}.button--transparent{background:transparent;padding:4px 8px;border:1px solid var(--gray-400);font-size:.875rem;font-weight:500;color:var(--gray-500);border-radius:8px}.button--transparent:hover{background-color:var(--gray-100)}.input{appearance:none;padding:4px 8px;border:1px solid var(--gray-400);font-size:.875rem;font-weight:500;color:var(--gray-500);border-radius:8px;background-color:#fff}.input:focus{outline:none}.input-label{font-size:.875rem;color:var(--gray-500);font-weight:500;padding:4px}select.input{appearance:none;background-image:url(data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMTIiIGhlaWdodD0iOCIgdmlld0JveD0iMCAwIDEyIDgiIGZpbGw9Im5vbmUiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+CjxwYXRoIGQ9Ik01Ljk5OTg5IDQuOTc2NzFMMTAuMTI0OSAwLjg1MTcwOEwxMS4zMDMyIDIuMDMwMDRMNS45OTk4OSA3LjMzMzM3TDAuNjk2NTU1IDIuMDMwMDRMMS44NzQ4OSAwLjg1MTcwOEw1Ljk5OTg5IDQuOTc2NzFaIiBmaWxsPSIjNjE3NThBIi8+Cjwvc3ZnPgo=);background-repeat:no-repeat;background-position:center right 10px;background-size:10px;padding-right:28px}select option{color:#000}select.input__icon{appearance:none;background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M13 12H16L12 16L8 12H11V8H13V12ZM15 4H5V20H19V8H15V4ZM3 2.9918C3 2.44405 3.44749 2 3.9985 2H16L20.9997 7L21 20.9925C21 21.5489 20.5551 22 20.0066 22H3.9934C3.44476 22 3 21.5447 3 21.0082V2.9918Z' fill='rgba(97,117,138,1)'%3E%3C/path%3E%3C/svg%3E");background-repeat:no-repeat;background-size:17px;padding-right:18px;border:none;color:#fff;width:18px;height:18px;background-color:transparent}select.input__icon:hover{cursor:pointer;background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M13 12H16L12 16L8 12H11V8H13V12ZM15 4H5V20H19V8H15V4ZM3 2.9918C3 2.44405 3.44749 2 3.9985 2H16L20.9997 7L21 20.9925C21 21.5489 20.5551 22 20.0066 22H3.9934C3.44476 22 3 21.5447 3 21.0082V2.9918Z' fill='rgba(28,42,58,1)'%3E%3C/path%3E%3C/svg%3E")}select.input__icon:focus{outline:none}.tooltip{position:relative;display:flex;--distance: 4px;--arrow-size: 5px;--show-delay: .5s}.tooltip:before{position:absolute;content:attr(data-tooltip);white-space:pre;text-align:center;display:block;z-index:100;background-color:#1c273c;color:#f0f5f9;font-size:12px;font-weight:500;border-radius:4px;padding:3px 12px;visibility:hidden;transition-property:visibility;transition-duration:0s;transition-delay:0s}.tooltip:after{content:"";position:absolute;display:block;z-index:100;border-width:var(--arrow-size);border-style:solid;border-color:#1c273c;visibility:hidden;transition-property:visibility;transition-duration:0s;transition-delay:0s}.tooltip:hover:before{visibility:visible;transition-delay:var(--show-delay)}.tooltip:hover:after{visibility:visible;transition-delay:var(--show-delay)}.tooltip.right:before{top:50%;left:100%;transform:translate(calc(var(--arrow-size) - 1px + var(--distance)),-50%)}.tooltip.right:after{top:50%;left:100%;transform:translate(var(--distance),-50%);border-left:none;border-top-color:transparent;border-bottom-color:transparent}.header-menu{width:175px;padding:8px;border-radius:0 0 6px 6px;box-shadow:0 10px 15px -3px #0000001a,0 4px 6px -2px #0000000d;border:1px solid #e1e8f0;display:flex;flex-direction:column;background-color:#fff}.header-menu-item{font-size:.975rem;font-family:Inter;color:#304254;padding:4px;display:flex;justify-content:flex-start;align-items:center;gap:4px}.header-menu-item:hover{cursor:pointer;background-color:#f0f5f9}.header-menu-item.input-label{font-weight:500;padding-left:2px}.header-menu-item.button{font-weight:500;background-color:#f0f5f9;border:1px solid #e1e8f0;width:100%;justify-content:center;margin-bottom:6px}.header-menu-item.button:hover{cursor:pointer;background-color:#e1e8f0}.header-menu-input{border:1px solid #e1e8f0;color:#61758a;width:100%;margin-bottom:4px;font-size:.975rem}.header-menu-input:disabled{opacity:50%}.inline-form{display:flex;flex-direction:row;align-items:center;justify-content:space-between;margin-right:2px}.inline-form .input{border:none;background-color:transparent;background-position:center right 0px;cursor:pointer;text-align:right;padding-right:14px}.input-wrapper{display:flex;justify-content:space-between;align-items:center;margin-top:4px}.input-full{min-width:65%;padding-right:50px}.input__button{padding:4px 8px;border:none;cursor:pointer;display:flex;color:#304254;align-items:center;background-color:#f0f5f9;border-radius:0 8px 8px 0;position:relative;right:47px;bottom:2px;height:25px}.input__button:hover{background-color:#e1e8f0}.input__button:focus{outline:none}.input__button:disabled{pointer-events:none;color:#91a4b7}.inline-buttons{display:flex;align-items:center;gap:12px}.navigation .download{margin-left:8px}.search-icon{width:1.3em;height:1.3em} diff --git a/lib/assets/data_table/build/main.js b/lib/assets/data_table/build/main.js index 290f3512..70207aea 100644 --- a/lib/assets/data_table/build/main.js +++ b/lib/assets/data_table/build/main.js @@ -1,30 +1,30 @@ -var km=Object.create;var ao=Object.defineProperty;var bm=Object.getOwnPropertyDescriptor;var Em=Object.getOwnPropertyNames;var _m=Object.getPrototypeOf,Tm=Object.prototype.hasOwnProperty;var eo=(t,a)=>()=>(t&&(a=t(t=0)),a);var B=(t,a)=>()=>(a||t((a={exports:{}}).exports,a),a.exports),Pm=(t,a)=>{for(var e in a)ao(t,e,{get:a[e],enumerable:!0})},Im=(t,a,e,r)=>{if(a&&typeof a=="object"||typeof a=="function")for(let n of Em(a))!Tm.call(t,n)&&n!==e&&ao(t,n,{get:()=>a[n],enumerable:!(r=bm(a,n))||r.enumerable});return t};var B1=(t,a,e)=>(e=t!=null?km(_m(t)):{},Im(a||!t||!t.__esModule?ao(e,"default",{value:t,enumerable:!0}):e,t));var u6=B(ht=>{"use strict";var kr=Symbol.for("react.element"),Om=Symbol.for("react.portal"),Dm=Symbol.for("react.fragment"),Nm=Symbol.for("react.strict_mode"),$m=Symbol.for("react.profiler"),Um=Symbol.for("react.provider"),Wm=Symbol.for("react.context"),jm=Symbol.for("react.forward_ref"),qm=Symbol.for("react.suspense"),Gm=Symbol.for("react.memo"),Km=Symbol.for("react.lazy"),n6=Symbol.iterator;function Xm(t){return t===null||typeof t!="object"?null:(t=n6&&t[n6]||t["@@iterator"],typeof t=="function"?t:null)}var o6={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},h6=Object.assign,c6={};function M4(t,a,e){this.props=t,this.context=a,this.refs=c6,this.updater=e||o6}M4.prototype.isReactComponent={};M4.prototype.setState=function(t,a){if(typeof t!="object"&&typeof t!="function"&&t!=null)throw Error("setState(...): takes an object of state variables to update or a function which returns an object of state variables.");this.updater.enqueueSetState(this,t,a,"setState")};M4.prototype.forceUpdate=function(t){this.updater.enqueueForceUpdate(this,t,"forceUpdate")};function v6(){}v6.prototype=M4.prototype;function no(t,a,e){this.props=t,this.context=a,this.refs=c6,this.updater=e||o6}var io=no.prototype=new v6;io.constructor=no;h6(io,M4.prototype);io.isPureReactComponent=!0;var i6=Array.isArray,g6=Object.prototype.hasOwnProperty,lo={current:null},d6={key:!0,ref:!0,__self:!0,__source:!0};function s6(t,a,e){var r,n={},i=null,l=null;if(a!=null)for(r in a.ref!==void 0&&(l=a.ref),a.key!==void 0&&(i=""+a.key),a)g6.call(a,r)&&!d6.hasOwnProperty(r)&&(n[r]=a[r]);var o=arguments.length-2;if(o===1)n.children=e;else if(1{"use strict";f6.exports=u6()});var R6=B(Tt=>{"use strict";function go(t,a){var e=t.length;t.push(a);t:for(;0>>1,n=t[r];if(0>>1;rzi(o,e))hzi(c,o)?(t[r]=c,t[h]=e,r=h):(t[r]=o,t[l]=e,r=l);else if(hzi(c,e))t[r]=c,t[h]=e,r=h;else break t}}return a}function zi(t,a){var e=t.sortIndex-a.sortIndex;return e!==0?e:t.id-a.id}typeof performance=="object"&&typeof performance.now=="function"?(p6=performance,Tt.unstable_now=function(){return p6.now()}):(ho=Date,z6=ho.now(),Tt.unstable_now=function(){return ho.now()-z6});var p6,ho,z6,la=[],ja=[],tM=1,V2=null,O0=3,Hi=!1,be=!1,Er=!1,H6=typeof setTimeout=="function"?setTimeout:null,x6=typeof clearTimeout=="function"?clearTimeout:null,m6=typeof setImmediate<"u"?setImmediate:null;typeof navigator<"u"&&navigator.scheduling!==void 0&&navigator.scheduling.isInputPending!==void 0&&navigator.scheduling.isInputPending.bind(navigator.scheduling);function so(t){for(var a=P2(ja);a!==null;){if(a.callback===null)Mi(ja);else if(a.startTime<=t)Mi(ja),a.sortIndex=a.expirationTime,go(la,a);else break;a=P2(ja)}}function uo(t){if(Er=!1,so(t),!be)if(P2(la)!==null)be=!0,po(fo);else{var a=P2(ja);a!==null&&zo(uo,a.startTime-t)}}function fo(t,a){be=!1,Er&&(Er=!1,x6(_r),_r=-1),Hi=!0;var e=O0;try{for(so(a),V2=P2(la);V2!==null&&(!(V2.expirationTime>a)||t&&!V6());){var r=V2.callback;if(typeof r=="function"){V2.callback=null,O0=V2.priorityLevel;var n=r(V2.expirationTime<=a);a=Tt.unstable_now(),typeof n=="function"?V2.callback=n:V2===P2(la)&&Mi(la),so(a)}else Mi(la);V2=P2(la)}if(V2!==null)var i=!0;else{var l=P2(ja);l!==null&&zo(uo,l.startTime-a),i=!1}return i}finally{V2=null,O0=e,Hi=!1}}var xi=!1,mi=null,_r=-1,w6=5,L6=-1;function V6(){return!(Tt.unstable_now()-L6t||125r?(t.sortIndex=e,go(ja,t),P2(la)===null&&t===P2(ja)&&(Er?(x6(_r),_r=-1):Er=!0,zo(uo,e-r))):(t.sortIndex=n,go(la,t),be||Hi||(be=!0,po(fo))),t};Tt.unstable_shouldYield=V6;Tt.unstable_wrapCallback=function(t){var a=O0;return function(){var e=O0;O0=a;try{return t.apply(this,arguments)}finally{O0=e}}}});var C6=B((P_,y6)=>{"use strict";y6.exports=R6()});var bc=B(z2=>{"use strict";var E7=T1(),f2=C6();function Z(t){for(var a="https://reactjs.org/docs/error-decoder.html?invariant="+t,e=1;e"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),Do=Object.prototype.hasOwnProperty,aM=/^[:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD][:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD\-.0-9\u00B7\u0300-\u036F\u203F-\u2040]*$/,B6={},S6={};function eM(t){return Do.call(S6,t)?!0:Do.call(B6,t)?!1:aM.test(t)?S6[t]=!0:(B6[t]=!0,!1)}function rM(t,a,e,r){if(e!==null&&e.type===0)return!1;switch(typeof a){case"function":case"symbol":return!0;case"boolean":return r?!1:e!==null?!e.acceptsBooleans:(t=t.toLowerCase().slice(0,5),t!=="data-"&&t!=="aria-");default:return!1}}function nM(t,a,e,r){if(a===null||typeof a>"u"||rM(t,a,e,r))return!0;if(r)return!1;if(e!==null)switch(e.type){case 3:return!a;case 4:return a===!1;case 5:return isNaN(a);case 6:return isNaN(a)||1>a}return!1}function X0(t,a,e,r,n,i,l){this.acceptsBooleans=a===2||a===3||a===4,this.attributeName=r,this.attributeNamespace=n,this.mustUseProperty=e,this.propertyName=t,this.type=a,this.sanitizeURL=i,this.removeEmptyString=l}var E0={};"children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style".split(" ").forEach(function(t){E0[t]=new X0(t,0,!1,t,null,!1,!1)});[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach(function(t){var a=t[0];E0[a]=new X0(a,1,!1,t[1],null,!1,!1)});["contentEditable","draggable","spellCheck","value"].forEach(function(t){E0[t]=new X0(t,2,!1,t.toLowerCase(),null,!1,!1)});["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach(function(t){E0[t]=new X0(t,2,!1,t,null,!1,!1)});"allowFullScreen async autoFocus autoPlay controls default defer disabled disablePictureInPicture disableRemotePlayback formNoValidate hidden loop noModule noValidate open playsInline readOnly required reversed scoped seamless itemScope".split(" ").forEach(function(t){E0[t]=new X0(t,3,!1,t.toLowerCase(),null,!1,!1)});["checked","multiple","muted","selected"].forEach(function(t){E0[t]=new X0(t,3,!0,t,null,!1,!1)});["capture","download"].forEach(function(t){E0[t]=new X0(t,4,!1,t,null,!1,!1)});["cols","rows","size","span"].forEach(function(t){E0[t]=new X0(t,6,!1,t,null,!1,!1)});["rowSpan","start"].forEach(function(t){E0[t]=new X0(t,5,!1,t.toLowerCase(),null,!1,!1)});var k3=/[\-:]([a-z])/g;function b3(t){return t[1].toUpperCase()}"accent-height alignment-baseline arabic-form baseline-shift cap-height clip-path clip-rule color-interpolation color-interpolation-filters color-profile color-rendering dominant-baseline enable-background fill-opacity fill-rule flood-color flood-opacity font-family font-size font-size-adjust font-stretch font-style font-variant font-weight glyph-name glyph-orientation-horizontal glyph-orientation-vertical horiz-adv-x horiz-origin-x image-rendering letter-spacing lighting-color marker-end marker-mid marker-start overline-position overline-thickness paint-order panose-1 pointer-events rendering-intent shape-rendering stop-color stop-opacity strikethrough-position strikethrough-thickness stroke-dasharray stroke-dashoffset stroke-linecap stroke-linejoin stroke-miterlimit stroke-opacity stroke-width text-anchor text-decoration text-rendering underline-position underline-thickness unicode-bidi unicode-range units-per-em v-alphabetic v-hanging v-ideographic v-mathematical vector-effect vert-adv-y vert-origin-x vert-origin-y word-spacing writing-mode xmlns:xlink x-height".split(" ").forEach(function(t){var a=t.replace(k3,b3);E0[a]=new X0(a,1,!1,t,null,!1,!1)});"xlink:actuate xlink:arcrole xlink:role xlink:show xlink:title xlink:type".split(" ").forEach(function(t){var a=t.replace(k3,b3);E0[a]=new X0(a,1,!1,t,"http://www.w3.org/1999/xlink",!1,!1)});["xml:base","xml:lang","xml:space"].forEach(function(t){var a=t.replace(k3,b3);E0[a]=new X0(a,1,!1,t,"http://www.w3.org/XML/1998/namespace",!1,!1)});["tabIndex","crossOrigin"].forEach(function(t){E0[t]=new X0(t,1,!1,t.toLowerCase(),null,!1,!1)});E0.xlinkHref=new X0("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1);["src","href","action","formAction"].forEach(function(t){E0[t]=new X0(t,1,!1,t.toLowerCase(),null,!0,!0)});function E3(t,a,e,r){var n=E0.hasOwnProperty(a)?E0[a]:null;(n!==null?n.type!==0:r||!(2()=>(t&&(a=t(t=0)),a);var B=(t,a)=>()=>(a||t((a={exports:{}}).exports,a),a.exports),tM=(t,a)=>{for(var e in a)ho(t,e,{get:a[e],enumerable:!0})},aM=(t,a,e,r)=>{if(a&&typeof a=="object"||typeof a=="function")for(let n of Qm(a))!Jm.call(t,n)&&n!==e&&ho(t,n,{get:()=>a[n],enumerable:!(r=Ym(a,n))||r.enumerable});return t};var F1=(t,a,e)=>(e=t!=null?Xm(Zm(t)):{},aM(a||!t||!t.__esModule?ho(e,"default",{value:t,enumerable:!0}):e,t));var L6=B(vt=>{"use strict";var Fr=Symbol.for("react.element"),eM=Symbol.for("react.portal"),rM=Symbol.for("react.fragment"),nM=Symbol.for("react.strict_mode"),iM=Symbol.for("react.profiler"),lM=Symbol.for("react.provider"),oM=Symbol.for("react.context"),hM=Symbol.for("react.forward_ref"),cM=Symbol.for("react.suspense"),vM=Symbol.for("react.memo"),gM=Symbol.for("react.lazy"),s6=Symbol.iterator;function dM(t){return t===null||typeof t!="object"?null:(t=s6&&t[s6]||t["@@iterator"],typeof t=="function"?t:null)}var p6={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},z6=Object.assign,m6={};function M4(t,a,e){this.props=t,this.context=a,this.refs=m6,this.updater=e||p6}M4.prototype.isReactComponent={};M4.prototype.setState=function(t,a){if(typeof t!="object"&&typeof t!="function"&&t!=null)throw Error("setState(...): takes an object of state variables to update or a function which returns an object of state variables.");this.updater.enqueueSetState(this,t,a,"setState")};M4.prototype.forceUpdate=function(t){this.updater.enqueueForceUpdate(this,t,"forceUpdate")};function M6(){}M6.prototype=M4.prototype;function go(t,a,e){this.props=t,this.context=a,this.refs=m6,this.updater=e||p6}var so=go.prototype=new M6;so.constructor=go;z6(so,M4.prototype);so.isPureReactComponent=!0;var u6=Array.isArray,H6=Object.prototype.hasOwnProperty,uo={current:null},x6={key:!0,ref:!0,__self:!0,__source:!0};function w6(t,a,e){var r,n={},i=null,l=null;if(a!=null)for(r in a.ref!==void 0&&(l=a.ref),a.key!==void 0&&(i=""+a.key),a)H6.call(a,r)&&!x6.hasOwnProperty(r)&&(n[r]=a[r]);var o=arguments.length-2;if(o===1)n.children=e;else if(1{"use strict";V6.exports=L6()});var E6=B(Tt=>{"use strict";function Mo(t,a){var e=t.length;t.push(a);t:for(;0>>1,n=t[r];if(0>>1;rLi(o,e))hLi(c,o)?(t[r]=c,t[h]=e,r=h):(t[r]=o,t[l]=e,r=l);else if(hLi(c,e))t[r]=c,t[h]=e,r=h;else break t}}return a}function Li(t,a){var e=t.sortIndex-a.sortIndex;return e!==0?e:t.id-a.id}typeof performance=="object"&&typeof performance.now=="function"?(R6=performance,Tt.unstable_now=function(){return R6.now()}):(po=Date,y6=po.now(),Tt.unstable_now=function(){return po.now()-y6});var R6,po,y6,va=[],Ka=[],zM=1,A2=null,I0=3,yi=!1,Ie=!1,br=!1,S6=typeof setTimeout=="function"?setTimeout:null,A6=typeof clearTimeout=="function"?clearTimeout:null,C6=typeof setImmediate<"u"?setImmediate:null;typeof navigator<"u"&&navigator.scheduling!==void 0&&navigator.scheduling.isInputPending!==void 0&&navigator.scheduling.isInputPending.bind(navigator.scheduling);function Ho(t){for(var a=$2(Ka);a!==null;){if(a.callback===null)Ri(Ka);else if(a.startTime<=t)Ri(Ka),a.sortIndex=a.expirationTime,Mo(va,a);else break;a=$2(Ka)}}function xo(t){if(br=!1,Ho(t),!Ie)if($2(va)!==null)Ie=!0,Lo(wo);else{var a=$2(Ka);a!==null&&Vo(xo,a.startTime-t)}}function wo(t,a){Ie=!1,br&&(br=!1,A6(Er),Er=-1),yi=!0;var e=I0;try{for(Ho(a),A2=$2(va);A2!==null&&(!(A2.expirationTime>a)||t&&!b6());){var r=A2.callback;if(typeof r=="function"){A2.callback=null,I0=A2.priorityLevel;var n=r(A2.expirationTime<=a);a=Tt.unstable_now(),typeof n=="function"?A2.callback=n:A2===$2(va)&&Ri(va),Ho(a)}else Ri(va);A2=$2(va)}if(A2!==null)var i=!0;else{var l=$2(Ka);l!==null&&Vo(xo,l.startTime-a),i=!1}return i}finally{A2=null,I0=e,yi=!1}}var Ci=!1,Vi=null,Er=-1,F6=5,k6=-1;function b6(){return!(Tt.unstable_now()-k6t||125r?(t.sortIndex=e,Mo(Ka,t),$2(va)===null&&t===$2(Ka)&&(br?(A6(Er),Er=-1):br=!0,Vo(xo,e-r))):(t.sortIndex=n,Mo(va,t),Ie||yi||(Ie=!0,Lo(wo))),t};Tt.unstable_shouldYield=b6;Tt.unstable_wrapCallback=function(t){var a=I0;return function(){var e=I0;I0=a;try{return t.apply(this,arguments)}finally{I0=e}}}});var T6=B((tT,_6)=>{"use strict";_6.exports=E6()});var $c=B(x2=>{"use strict";var U7=U1(),M2=T6();function Q(t){for(var a="https://reactjs.org/docs/error-decoder.html?invariant="+t,e=1;e"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),Go=Object.prototype.hasOwnProperty,mM=/^[:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD][:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD\-.0-9\u00B7\u0300-\u036F\u203F-\u2040]*$/,P6={},I6={};function MM(t){return Go.call(I6,t)?!0:Go.call(P6,t)?!1:mM.test(t)?I6[t]=!0:(P6[t]=!0,!1)}function HM(t,a,e,r){if(e!==null&&e.type===0)return!1;switch(typeof a){case"function":case"symbol":return!0;case"boolean":return r?!1:e!==null?!e.acceptsBooleans:(t=t.toLowerCase().slice(0,5),t!=="data-"&&t!=="aria-");default:return!1}}function xM(t,a,e,r){if(a===null||typeof a>"u"||HM(t,a,e,r))return!0;if(r)return!1;if(e!==null)switch(e.type){case 3:return!a;case 4:return a===!1;case 5:return isNaN(a);case 6:return isNaN(a)||1>a}return!1}function Y0(t,a,e,r,n,i,l){this.acceptsBooleans=a===2||a===3||a===4,this.attributeName=r,this.attributeNamespace=n,this.mustUseProperty=e,this.propertyName=t,this.type=a,this.sanitizeURL=i,this.removeEmptyString=l}var _0={};"children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style".split(" ").forEach(function(t){_0[t]=new Y0(t,0,!1,t,null,!1,!1)});[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach(function(t){var a=t[0];_0[a]=new Y0(a,1,!1,t[1],null,!1,!1)});["contentEditable","draggable","spellCheck","value"].forEach(function(t){_0[t]=new Y0(t,2,!1,t.toLowerCase(),null,!1,!1)});["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach(function(t){_0[t]=new Y0(t,2,!1,t,null,!1,!1)});"allowFullScreen async autoFocus autoPlay controls default defer disabled disablePictureInPicture disableRemotePlayback formNoValidate hidden loop noModule noValidate open playsInline readOnly required reversed scoped seamless itemScope".split(" ").forEach(function(t){_0[t]=new Y0(t,3,!1,t.toLowerCase(),null,!1,!1)});["checked","multiple","muted","selected"].forEach(function(t){_0[t]=new Y0(t,3,!0,t,null,!1,!1)});["capture","download"].forEach(function(t){_0[t]=new Y0(t,4,!1,t,null,!1,!1)});["cols","rows","size","span"].forEach(function(t){_0[t]=new Y0(t,6,!1,t,null,!1,!1)});["rowSpan","start"].forEach(function(t){_0[t]=new Y0(t,5,!1,t.toLowerCase(),null,!1,!1)});var O3=/[\-:]([a-z])/g;function D3(t){return t[1].toUpperCase()}"accent-height alignment-baseline arabic-form baseline-shift cap-height clip-path clip-rule color-interpolation color-interpolation-filters color-profile color-rendering dominant-baseline enable-background fill-opacity fill-rule flood-color flood-opacity font-family font-size font-size-adjust font-stretch font-style font-variant font-weight glyph-name glyph-orientation-horizontal glyph-orientation-vertical horiz-adv-x horiz-origin-x image-rendering letter-spacing lighting-color marker-end marker-mid marker-start overline-position overline-thickness paint-order panose-1 pointer-events rendering-intent shape-rendering stop-color stop-opacity strikethrough-position strikethrough-thickness stroke-dasharray stroke-dashoffset stroke-linecap stroke-linejoin stroke-miterlimit stroke-opacity stroke-width text-anchor text-decoration text-rendering underline-position underline-thickness unicode-bidi unicode-range units-per-em v-alphabetic v-hanging v-ideographic v-mathematical vector-effect vert-adv-y vert-origin-x vert-origin-y word-spacing writing-mode xmlns:xlink x-height".split(" ").forEach(function(t){var a=t.replace(O3,D3);_0[a]=new Y0(a,1,!1,t,null,!1,!1)});"xlink:actuate xlink:arcrole xlink:role xlink:show xlink:title xlink:type".split(" ").forEach(function(t){var a=t.replace(O3,D3);_0[a]=new Y0(a,1,!1,t,"http://www.w3.org/1999/xlink",!1,!1)});["xml:base","xml:lang","xml:space"].forEach(function(t){var a=t.replace(O3,D3);_0[a]=new Y0(a,1,!1,t,"http://www.w3.org/XML/1998/namespace",!1,!1)});["tabIndex","crossOrigin"].forEach(function(t){_0[t]=new Y0(t,1,!1,t.toLowerCase(),null,!1,!1)});_0.xlinkHref=new Y0("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1);["src","href","action","formAction"].forEach(function(t){_0[t]=new Y0(t,1,!1,t.toLowerCase(),null,!0,!0)});function N3(t,a,e,r){var n=_0.hasOwnProperty(a)?_0[a]:null;(n!==null?n.type!==0:r||!(2o||n[l]!==i[o]){var h=` -`+n[l].replace(" at new "," at ");return t.displayName&&h.includes("")&&(h=h.replace("",t.displayName)),h}while(1<=l&&0<=o);break}}}finally{Mo=!1,Error.prepareStackTrace=e}return(t=t?t.displayName||t.name:"")?Wr(t):""}function iM(t){switch(t.tag){case 5:return Wr(t.type);case 16:return Wr("Lazy");case 13:return Wr("Suspense");case 19:return Wr("SuspenseList");case 0:case 2:case 15:return t=Ho(t.type,!1),t;case 11:return t=Ho(t.type.render,!1),t;case 1:return t=Ho(t.type,!0),t;default:return""}}function Wo(t){if(t==null)return null;if(typeof t=="function")return t.displayName||t.name||null;if(typeof t=="string")return t;switch(t){case L4:return"Fragment";case w4:return"Portal";case No:return"Profiler";case _3:return"StrictMode";case $o:return"Suspense";case Uo:return"SuspenseList"}if(typeof t=="object")switch(t.$$typeof){case P7:return(t.displayName||"Context")+".Consumer";case T7:return(t._context.displayName||"Context")+".Provider";case T3:var a=t.render;return t=t.displayName,t||(t=a.displayName||a.name||"",t=t!==""?"ForwardRef("+t+")":"ForwardRef"),t;case P3:return a=t.displayName||null,a!==null?a:Wo(t.type)||"Memo";case Ga:a=t._payload,t=t._init;try{return Wo(t(a))}catch{}}return null}function lM(t){var a=t.type;switch(t.tag){case 24:return"Cache";case 9:return(a.displayName||"Context")+".Consumer";case 10:return(a._context.displayName||"Context")+".Provider";case 18:return"DehydratedFragment";case 11:return t=a.render,t=t.displayName||t.name||"",a.displayName||(t!==""?"ForwardRef("+t+")":"ForwardRef");case 7:return"Fragment";case 5:return a;case 4:return"Portal";case 3:return"Root";case 6:return"Text";case 16:return Wo(a);case 8:return a===_3?"StrictMode":"Mode";case 22:return"Offscreen";case 12:return"Profiler";case 21:return"Scope";case 13:return"Suspense";case 19:return"SuspenseList";case 25:return"TracingMarker";case 1:case 0:case 17:case 2:case 14:case 15:if(typeof a=="function")return a.displayName||a.name||null;if(typeof a=="string")return a}return null}function oe(t){switch(typeof t){case"boolean":case"number":case"string":case"undefined":return t;case"object":return t;default:return""}}function O7(t){var a=t.type;return(t=t.nodeName)&&t.toLowerCase()==="input"&&(a==="checkbox"||a==="radio")}function oM(t){var a=O7(t)?"checked":"value",e=Object.getOwnPropertyDescriptor(t.constructor.prototype,a),r=""+t[a];if(!t.hasOwnProperty(a)&&typeof e<"u"&&typeof e.get=="function"&&typeof e.set=="function"){var n=e.get,i=e.set;return Object.defineProperty(t,a,{configurable:!0,get:function(){return n.call(this)},set:function(l){r=""+l,i.call(this,l)}}),Object.defineProperty(t,a,{enumerable:e.enumerable}),{getValue:function(){return r},setValue:function(l){r=""+l},stopTracking:function(){t._valueTracker=null,delete t[a]}}}}function Li(t){t._valueTracker||(t._valueTracker=oM(t))}function D7(t){if(!t)return!1;var a=t._valueTracker;if(!a)return!0;var e=a.getValue(),r="";return t&&(r=O7(t)?t.checked?"true":"false":t.value),t=r,t!==e?(a.setValue(t),!0):!1}function Qi(t){if(t=t||(typeof document<"u"?document:void 0),typeof t>"u")return null;try{return t.activeElement||t.body}catch{return t.body}}function jo(t,a){var e=a.checked;return Qt({},a,{defaultChecked:void 0,defaultValue:void 0,value:void 0,checked:e??t._wrapperState.initialChecked})}function F6(t,a){var e=a.defaultValue==null?"":a.defaultValue,r=a.checked!=null?a.checked:a.defaultChecked;e=oe(a.value!=null?a.value:e),t._wrapperState={initialChecked:r,initialValue:e,controlled:a.type==="checkbox"||a.type==="radio"?a.checked!=null:a.value!=null}}function N7(t,a){a=a.checked,a!=null&&E3(t,"checked",a,!1)}function qo(t,a){N7(t,a);var e=oe(a.value),r=a.type;if(e!=null)r==="number"?(e===0&&t.value===""||t.value!=e)&&(t.value=""+e):t.value!==""+e&&(t.value=""+e);else if(r==="submit"||r==="reset"){t.removeAttribute("value");return}a.hasOwnProperty("value")?Go(t,a.type,e):a.hasOwnProperty("defaultValue")&&Go(t,a.type,oe(a.defaultValue)),a.checked==null&&a.defaultChecked!=null&&(t.defaultChecked=!!a.defaultChecked)}function k6(t,a,e){if(a.hasOwnProperty("value")||a.hasOwnProperty("defaultValue")){var r=a.type;if(!(r!=="submit"&&r!=="reset"||a.value!==void 0&&a.value!==null))return;a=""+t._wrapperState.initialValue,e||a===t.value||(t.value=a),t.defaultValue=a}e=t.name,e!==""&&(t.name=""),t.defaultChecked=!!t._wrapperState.initialChecked,e!==""&&(t.name=e)}function Go(t,a,e){(a!=="number"||Qi(t.ownerDocument)!==t)&&(e==null?t.defaultValue=""+t._wrapperState.initialValue:t.defaultValue!==""+e&&(t.defaultValue=""+e))}var jr=Array.isArray;function E4(t,a,e,r){if(t=t.options,a){a={};for(var n=0;n"+a.valueOf().toString()+"",a=Vi.firstChild;t.firstChild;)t.removeChild(t.firstChild);for(;a.firstChild;)t.appendChild(a.firstChild)}});function nn(t,a){if(a){var e=t.firstChild;if(e&&e===t.lastChild&&e.nodeType===3){e.nodeValue=a;return}}t.textContent=a}var Kr={animationIterationCount:!0,aspectRatio:!0,borderImageOutset:!0,borderImageSlice:!0,borderImageWidth:!0,boxFlex:!0,boxFlexGroup:!0,boxOrdinalGroup:!0,columnCount:!0,columns:!0,flex:!0,flexGrow:!0,flexPositive:!0,flexShrink:!0,flexNegative:!0,flexOrder:!0,gridArea:!0,gridRow:!0,gridRowEnd:!0,gridRowSpan:!0,gridRowStart:!0,gridColumn:!0,gridColumnEnd:!0,gridColumnSpan:!0,gridColumnStart:!0,fontWeight:!0,lineClamp:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,tabSize:!0,widows:!0,zIndex:!0,zoom:!0,fillOpacity:!0,floodOpacity:!0,stopOpacity:!0,strokeDasharray:!0,strokeDashoffset:!0,strokeMiterlimit:!0,strokeOpacity:!0,strokeWidth:!0},hM=["Webkit","ms","Moz","O"];Object.keys(Kr).forEach(function(t){hM.forEach(function(a){a=a+t.charAt(0).toUpperCase()+t.substring(1),Kr[a]=Kr[t]})});function j7(t,a,e){return a==null||typeof a=="boolean"||a===""?"":e||typeof a!="number"||a===0||Kr.hasOwnProperty(t)&&Kr[t]?(""+a).trim():a+"px"}function q7(t,a){t=t.style;for(var e in a)if(a.hasOwnProperty(e)){var r=e.indexOf("--")===0,n=j7(e,a[e],r);e==="float"&&(e="cssFloat"),r?t.setProperty(e,n):t[e]=n}}var cM=Qt({menuitem:!0},{area:!0,base:!0,br:!0,col:!0,embed:!0,hr:!0,img:!0,input:!0,keygen:!0,link:!0,meta:!0,param:!0,source:!0,track:!0,wbr:!0});function Yo(t,a){if(a){if(cM[t]&&(a.children!=null||a.dangerouslySetInnerHTML!=null))throw Error(Z(137,t));if(a.dangerouslySetInnerHTML!=null){if(a.children!=null)throw Error(Z(60));if(typeof a.dangerouslySetInnerHTML!="object"||!("__html"in a.dangerouslySetInnerHTML))throw Error(Z(61))}if(a.style!=null&&typeof a.style!="object")throw Error(Z(62))}}function Qo(t,a){if(t.indexOf("-")===-1)return typeof a.is=="string";switch(t){case"annotation-xml":case"color-profile":case"font-face":case"font-face-src":case"font-face-uri":case"font-face-format":case"font-face-name":case"missing-glyph":return!1;default:return!0}}var Zo=null;function I3(t){return t=t.target||t.srcElement||window,t.correspondingUseElement&&(t=t.correspondingUseElement),t.nodeType===3?t.parentNode:t}var Jo=null,_4=null,T4=null;function _6(t){if(t=Ln(t)){if(typeof Jo!="function")throw Error(Z(280));var a=t.stateNode;a&&(a=Rl(a),Jo(t.stateNode,t.type,a))}}function G7(t){_4?T4?T4.push(t):T4=[t]:_4=t}function K7(){if(_4){var t=_4,a=T4;if(T4=_4=null,_6(t),a)for(t=0;t>>=0,t===0?32:31-(HM(t)/xM|0)|0}var Ri=64,yi=4194304;function qr(t){switch(t&-t){case 1:return 1;case 2:return 2;case 4:return 4;case 8:return 8;case 16:return 16;case 32:return 32;case 64:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return t&4194240;case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:return t&130023424;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 1073741824;default:return t}}function al(t,a){var e=t.pendingLanes;if(e===0)return 0;var r=0,n=t.suspendedLanes,i=t.pingedLanes,l=e&268435455;if(l!==0){var o=l&~n;o!==0?r=qr(o):(i&=l,i!==0&&(r=qr(i)))}else l=e&~n,l!==0?r=qr(l):i!==0&&(r=qr(i));if(r===0)return 0;if(a!==0&&a!==r&&(a&n)===0&&(n=r&-r,i=a&-a,n>=i||n===16&&(i&4194240)!==0))return a;if((r&4)!==0&&(r|=e&16),a=t.entangledLanes,a!==0)for(t=t.entanglements,a&=r;0e;e++)a.push(t);return a}function xn(t,a,e){t.pendingLanes|=a,a!==536870912&&(t.suspendedLanes=0,t.pingedLanes=0),t=t.eventTimes,a=31-$2(a),t[a]=e}function RM(t,a){var e=t.pendingLanes&~a;t.pendingLanes=a,t.suspendedLanes=0,t.pingedLanes=0,t.expiredLanes&=a,t.mutableReadLanes&=a,t.entangledLanes&=a,a=t.entanglements;var r=t.eventTimes;for(t=t.expirationTimes;0=Yr),W6=String.fromCharCode(32),j6=!1;function u9(t,a){switch(t){case"keyup":return JM.indexOf(a.keyCode)!==-1;case"keydown":return a.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function f9(t){return t=t.detail,typeof t=="object"&&"data"in t?t.data:null}var V4=!1;function aH(t,a){switch(t){case"compositionend":return f9(a);case"keypress":return a.which!==32?null:(j6=!0,W6);case"textInput":return t=a.data,t===W6&&j6?null:t;default:return null}}function eH(t,a){if(V4)return t==="compositionend"||!q3&&u9(t,a)?(t=d9(),$i=U3=Qa=null,V4=!1,t):null;switch(t){case"paste":return null;case"keypress":if(!(a.ctrlKey||a.altKey||a.metaKey)||a.ctrlKey&&a.altKey){if(a.char&&1=a)return{node:e,offset:a-t};t=r}t:{for(;e;){if(e.nextSibling){e=e.nextSibling;break t}e=e.parentNode}e=void 0}e=K6(e)}}function M9(t,a){return t&&a?t===a?!0:t&&t.nodeType===3?!1:a&&a.nodeType===3?M9(t,a.parentNode):"contains"in t?t.contains(a):t.compareDocumentPosition?!!(t.compareDocumentPosition(a)&16):!1:!1}function H9(){for(var t=window,a=Qi();a instanceof t.HTMLIFrameElement;){try{var e=typeof a.contentWindow.location.href=="string"}catch{e=!1}if(e)t=a.contentWindow;else break;a=Qi(t.document)}return a}function G3(t){var a=t&&t.nodeName&&t.nodeName.toLowerCase();return a&&(a==="input"&&(t.type==="text"||t.type==="search"||t.type==="tel"||t.type==="url"||t.type==="password")||a==="textarea"||t.contentEditable==="true")}function gH(t){var a=H9(),e=t.focusedElem,r=t.selectionRange;if(a!==e&&e&&e.ownerDocument&&M9(e.ownerDocument.documentElement,e)){if(r!==null&&G3(e)){if(a=r.start,t=r.end,t===void 0&&(t=a),"selectionStart"in e)e.selectionStart=a,e.selectionEnd=Math.min(t,e.value.length);else if(t=(a=e.ownerDocument||document)&&a.defaultView||window,t.getSelection){t=t.getSelection();var n=e.textContent.length,i=Math.min(r.start,n);r=r.end===void 0?i:Math.min(r.end,n),!t.extend&&i>r&&(n=r,r=i,i=n),n=X6(e,i);var l=X6(e,r);n&&l&&(t.rangeCount!==1||t.anchorNode!==n.node||t.anchorOffset!==n.offset||t.focusNode!==l.node||t.focusOffset!==l.offset)&&(a=a.createRange(),a.setStart(n.node,n.offset),t.removeAllRanges(),i>r?(t.addRange(a),t.extend(l.node,l.offset)):(a.setEnd(l.node,l.offset),t.addRange(a)))}}for(a=[],t=e;t=t.parentNode;)t.nodeType===1&&a.push({element:t,left:t.scrollLeft,top:t.scrollTop});for(typeof e.focus=="function"&&e.focus(),e=0;e=document.documentMode,R4=null,i3=null,Zr=null,l3=!1;function Y6(t,a,e){var r=e.window===e?e.document:e.nodeType===9?e:e.ownerDocument;l3||R4==null||R4!==Qi(r)||(r=R4,"selectionStart"in r&&G3(r)?r={start:r.selectionStart,end:r.selectionEnd}:(r=(r.ownerDocument&&r.ownerDocument.defaultView||window).getSelection(),r={anchorNode:r.anchorNode,anchorOffset:r.anchorOffset,focusNode:r.focusNode,focusOffset:r.focusOffset}),Zr&&gn(Zr,r)||(Zr=r,r=nl(i3,"onSelect"),0B4||(t.current=d3[B4],d3[B4]=null,B4--)}function Pt(t,a){B4++,d3[B4]=t.current,t.current=a}var he={},U0=ve(he),e2=ve(!1),Ne=he;function N4(t,a){var e=t.type.contextTypes;if(!e)return he;var r=t.stateNode;if(r&&r.__reactInternalMemoizedUnmaskedChildContext===a)return r.__reactInternalMemoizedMaskedChildContext;var n={},i;for(i in e)n[i]=a[i];return r&&(t=t.stateNode,t.__reactInternalMemoizedUnmaskedChildContext=a,t.__reactInternalMemoizedMaskedChildContext=n),n}function r2(t){return t=t.childContextTypes,t!=null}function ll(){Nt(e2),Nt(U0)}function i7(t,a,e){if(U0.current!==he)throw Error(Z(168));Pt(U0,a),Pt(e2,e)}function S9(t,a,e){var r=t.stateNode;if(a=a.childContextTypes,typeof r.getChildContext!="function")return e;r=r.getChildContext();for(var n in r)if(!(n in a))throw Error(Z(108,lM(t)||"Unknown",n));return Qt({},e,r)}function ol(t){return t=(t=t.stateNode)&&t.__reactInternalMemoizedMergedChildContext||he,Ne=U0.current,Pt(U0,t),Pt(e2,e2.current),!0}function l7(t,a,e){var r=t.stateNode;if(!r)throw Error(Z(169));e?(t=S9(t,a,Ne),r.__reactInternalMemoizedMergedChildContext=t,Nt(e2),Nt(U0),Pt(U0,t)):Nt(e2),Pt(e2,e)}var Va=null,yl=!1,Fo=!1;function A9(t){Va===null?Va=[t]:Va.push(t)}function xH(t){yl=!0,A9(t)}function ge(){if(!Fo&&Va!==null){Fo=!0;var t=0,a=Vt;try{var e=Va;for(Vt=1;t>=l,n-=l,Ra=1<<32-$2(a)+n|e<V?(R=w,w=null):R=w.sibling;var S=s(u,w,m[V],M);if(S===null){w===null&&(w=R);break}t&&w&&S.alternate===null&&a(u,w),f=i(S,f,V),y===null?x=S:y.sibling=S,y=S,w=R}if(V===m.length)return e(u,w),Wt&&Ee(u,V),x;if(w===null){for(;VV?(R=w,w=null):R=w.sibling;var b=s(u,w,S.value,M);if(b===null){w===null&&(w=R);break}t&&w&&b.alternate===null&&a(u,w),f=i(b,f,V),y===null?x=b:y.sibling=b,y=b,w=R}if(S.done)return e(u,w),Wt&&Ee(u,V),x;if(w===null){for(;!S.done;V++,S=m.next())S=g(u,S.value,M),S!==null&&(f=i(S,f,V),y===null?x=S:y.sibling=S,y=S);return Wt&&Ee(u,V),x}for(w=r(u,w);!S.done;V++,S=m.next())S=d(w,u,V,S.value,M),S!==null&&(t&&S.alternate!==null&&w.delete(S.key===null?V:S.key),f=i(S,f,V),y===null?x=S:y.sibling=S,y=S);return t&&w.forEach(function(E){return a(u,E)}),Wt&&Ee(u,V),x}function L(u,f,m,M){if(typeof m=="object"&&m!==null&&m.type===L4&&m.key===null&&(m=m.props.children),typeof m=="object"&&m!==null){switch(m.$$typeof){case wi:t:{for(var x=m.key,y=f;y!==null;){if(y.key===x){if(x=m.type,x===L4){if(y.tag===7){e(u,y.sibling),f=n(y,m.props.children),f.return=u,u=f;break t}}else if(y.elementType===x||typeof x=="object"&&x!==null&&x.$$typeof===Ga&&s7(x)===y.type){e(u,y.sibling),f=n(y,m.props),f.ref=Dr(u,y,m),f.return=u,u=f;break t}e(u,y);break}else a(u,y);y=y.sibling}m.type===L4?(f=De(m.props.children,u.mode,M,m.key),f.return=u,u=f):(M=Yi(m.type,m.key,m.props,null,u.mode,M),M.ref=Dr(u,f,m),M.return=u,u=M)}return l(u);case w4:t:{for(y=m.key;f!==null;){if(f.key===y)if(f.tag===4&&f.stateNode.containerInfo===m.containerInfo&&f.stateNode.implementation===m.implementation){e(u,f.sibling),f=n(f,m.children||[]),f.return=u,u=f;break t}else{e(u,f);break}else a(u,f);f=f.sibling}f=Oo(m,u.mode,M),f.return=u,u=f}return l(u);case Ga:return y=m._init,L(u,f,y(m._payload),M)}if(jr(m))return p(u,f,m,M);if(Tr(m))return z(u,f,m,M);Pi(u,m)}return typeof m=="string"&&m!==""||typeof m=="number"?(m=""+m,f!==null&&f.tag===6?(e(u,f.sibling),f=n(f,m),f.return=u,u=f):(e(u,f),f=Io(m,u.mode,M),f.return=u,u=f),l(u)):e(u,f)}return L}var U4=I9(!0),O9=I9(!1),Vn={},ga=ve(Vn),fn=ve(Vn),pn=ve(Vn);function Ie(t){if(t===Vn)throw Error(Z(174));return t}function eh(t,a){switch(Pt(pn,a),Pt(fn,t),Pt(ga,Vn),t=a.nodeType,t){case 9:case 11:a=(a=a.documentElement)?a.namespaceURI:Xo(null,"");break;default:t=t===8?a.parentNode:a,a=t.namespaceURI||null,t=t.tagName,a=Xo(a,t)}Nt(ga),Pt(ga,a)}function W4(){Nt(ga),Nt(fn),Nt(pn)}function D9(t){Ie(pn.current);var a=Ie(ga.current),e=Xo(a,t.type);a!==e&&(Pt(fn,t),Pt(ga,e))}function rh(t){fn.current===t&&(Nt(ga),Nt(fn))}var Xt=ve(0);function sl(t){for(var a=t;a!==null;){if(a.tag===13){var e=a.memoizedState;if(e!==null&&(e=e.dehydrated,e===null||e.data==="$?"||e.data==="$!"))return a}else if(a.tag===19&&a.memoizedProps.revealOrder!==void 0){if((a.flags&128)!==0)return a}else if(a.child!==null){a.child.return=a,a=a.child;continue}if(a===t)break;for(;a.sibling===null;){if(a.return===null||a.return===t)return null;a=a.return}a.sibling.return=a.return,a=a.sibling}return null}var ko=[];function nh(){for(var t=0;te?e:4,t(!0);var r=bo.transition;bo.transition={};try{t(!1),a()}finally{Vt=e,bo.transition=r}}function ec(){return A2().memoizedState}function RH(t,a,e){var r=ie(t);if(e={lane:r,action:e,hasEagerState:!1,eagerState:null,next:null},rc(t))nc(a,e);else if(e=E9(t,a,e,r),e!==null){var n=K0();U2(e,t,r,n),ic(e,a,r)}}function yH(t,a,e){var r=ie(t),n={lane:r,action:e,hasEagerState:!1,eagerState:null,next:null};if(rc(t))nc(a,n);else{var i=t.alternate;if(t.lanes===0&&(i===null||i.lanes===0)&&(i=a.lastRenderedReducer,i!==null))try{var l=a.lastRenderedState,o=i(l,e);if(n.hasEagerState=!0,n.eagerState=o,W2(o,l)){var h=a.interleaved;h===null?(n.next=n,th(a)):(n.next=h.next,h.next=n),a.interleaved=n;return}}catch{}finally{}e=E9(t,a,n,r),e!==null&&(n=K0(),U2(e,t,r,n),ic(e,a,r))}}function rc(t){var a=t.alternate;return t===Yt||a!==null&&a===Yt}function nc(t,a){Jr=ul=!0;var e=t.pending;e===null?a.next=a:(a.next=e.next,e.next=a),t.pending=a}function ic(t,a,e){if((e&4194240)!==0){var r=a.lanes;r&=t.pendingLanes,e|=r,a.lanes=e,D3(t,e)}}var fl={readContext:S2,useCallback:D0,useContext:D0,useEffect:D0,useImperativeHandle:D0,useInsertionEffect:D0,useLayoutEffect:D0,useMemo:D0,useReducer:D0,useRef:D0,useState:D0,useDebugValue:D0,useDeferredValue:D0,useTransition:D0,useMutableSource:D0,useSyncExternalStore:D0,useId:D0,unstable_isNewReconciler:!1},CH={readContext:S2,useCallback:function(t,a){return ha().memoizedState=[t,a===void 0?null:a],t},useContext:S2,useEffect:f7,useImperativeHandle:function(t,a,e){return e=e!=null?e.concat([t]):null,qi(4194308,4,Q9.bind(null,a,t),e)},useLayoutEffect:function(t,a){return qi(4194308,4,t,a)},useInsertionEffect:function(t,a){return qi(4,2,t,a)},useMemo:function(t,a){var e=ha();return a=a===void 0?null:a,t=t(),e.memoizedState=[t,a],t},useReducer:function(t,a,e){var r=ha();return a=e!==void 0?e(a):a,r.memoizedState=r.baseState=a,t={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:t,lastRenderedState:a},r.queue=t,t=t.dispatch=RH.bind(null,Yt,t),[r.memoizedState,t]},useRef:function(t){var a=ha();return t={current:t},a.memoizedState=t},useState:u7,useDebugValue:ch,useDeferredValue:function(t){return ha().memoizedState=t},useTransition:function(){var t=u7(!1),a=t[0];return t=VH.bind(null,t[1]),ha().memoizedState=t,[a,t]},useMutableSource:function(){},useSyncExternalStore:function(t,a,e){var r=Yt,n=ha();if(Wt){if(e===void 0)throw Error(Z(407));e=e()}else{if(e=a(),R0===null)throw Error(Z(349));(Ue&30)!==0||U9(r,a,e)}n.memoizedState=e;var i={value:e,getSnapshot:a};return n.queue=i,f7(j9.bind(null,r,i,t),[t]),r.flags|=2048,Mn(9,W9.bind(null,r,i,e,a),void 0,null),e},useId:function(){var t=ha(),a=R0.identifierPrefix;if(Wt){var e=ya,r=Ra;e=(r&~(1<<32-$2(r)-1)).toString(32)+e,a=":"+a+"R"+e,e=zn++,0")&&(h=h.replace("",t.displayName)),h}while(1<=l&&0<=o);break}}}finally{yo=!1,Error.prepareStackTrace=e}return(t=t?t.displayName||t.name:"")?Ur(t):""}function wM(t){switch(t.tag){case 5:return Ur(t.type);case 16:return Ur("Lazy");case 13:return Ur("Suspense");case 19:return Ur("SuspenseList");case 0:case 2:case 15:return t=Co(t.type,!1),t;case 11:return t=Co(t.type.render,!1),t;case 1:return t=Co(t.type,!0),t;default:return""}}function Qo(t){if(t==null)return null;if(typeof t=="function")return t.displayName||t.name||null;if(typeof t=="string")return t;switch(t){case L4:return"Fragment";case w4:return"Portal";case Ko:return"Profiler";case $3:return"StrictMode";case Xo:return"Suspense";case Yo:return"SuspenseList"}if(typeof t=="object")switch(t.$$typeof){case q7:return(t.displayName||"Context")+".Consumer";case j7:return(t._context.displayName||"Context")+".Provider";case U3:var a=t.render;return t=t.displayName,t||(t=a.displayName||a.name||"",t=t!==""?"ForwardRef("+t+")":"ForwardRef"),t;case W3:return a=t.displayName||null,a!==null?a:Qo(t.type)||"Memo";case Ya:a=t._payload,t=t._init;try{return Qo(t(a))}catch{}}return null}function LM(t){var a=t.type;switch(t.tag){case 24:return"Cache";case 9:return(a.displayName||"Context")+".Consumer";case 10:return(a._context.displayName||"Context")+".Provider";case 18:return"DehydratedFragment";case 11:return t=a.render,t=t.displayName||t.name||"",a.displayName||(t!==""?"ForwardRef("+t+")":"ForwardRef");case 7:return"Fragment";case 5:return a;case 4:return"Portal";case 3:return"Root";case 6:return"Text";case 16:return Qo(a);case 8:return a===$3?"StrictMode":"Mode";case 22:return"Offscreen";case 12:return"Profiler";case 21:return"Scope";case 13:return"Suspense";case 19:return"SuspenseList";case 25:return"TracingMarker";case 1:case 0:case 17:case 2:case 14:case 15:if(typeof a=="function")return a.displayName||a.name||null;if(typeof a=="string")return a}return null}function ve(t){switch(typeof t){case"boolean":case"number":case"string":case"undefined":return t;case"object":return t;default:return""}}function K7(t){var a=t.type;return(t=t.nodeName)&&t.toLowerCase()==="input"&&(a==="checkbox"||a==="radio")}function VM(t){var a=K7(t)?"checked":"value",e=Object.getOwnPropertyDescriptor(t.constructor.prototype,a),r=""+t[a];if(!t.hasOwnProperty(a)&&typeof e<"u"&&typeof e.get=="function"&&typeof e.set=="function"){var n=e.get,i=e.set;return Object.defineProperty(t,a,{configurable:!0,get:function(){return n.call(this)},set:function(l){r=""+l,i.call(this,l)}}),Object.defineProperty(t,a,{enumerable:e.enumerable}),{getValue:function(){return r},setValue:function(l){r=""+l},stopTracking:function(){t._valueTracker=null,delete t[a]}}}}function Si(t){t._valueTracker||(t._valueTracker=VM(t))}function X7(t){if(!t)return!1;var a=t._valueTracker;if(!a)return!0;var e=a.getValue(),r="";return t&&(r=K7(t)?t.checked?"true":"false":t.value),t=r,t!==e?(a.setValue(t),!0):!1}function rl(t){if(t=t||(typeof document<"u"?document:void 0),typeof t>"u")return null;try{return t.activeElement||t.body}catch{return t.body}}function Zo(t,a){var e=a.checked;return Qt({},a,{defaultChecked:void 0,defaultValue:void 0,value:void 0,checked:e??t._wrapperState.initialChecked})}function D6(t,a){var e=a.defaultValue==null?"":a.defaultValue,r=a.checked!=null?a.checked:a.defaultChecked;e=ve(a.value!=null?a.value:e),t._wrapperState={initialChecked:r,initialValue:e,controlled:a.type==="checkbox"||a.type==="radio"?a.checked!=null:a.value!=null}}function Y7(t,a){a=a.checked,a!=null&&N3(t,"checked",a,!1)}function Jo(t,a){Y7(t,a);var e=ve(a.value),r=a.type;if(e!=null)r==="number"?(e===0&&t.value===""||t.value!=e)&&(t.value=""+e):t.value!==""+e&&(t.value=""+e);else if(r==="submit"||r==="reset"){t.removeAttribute("value");return}a.hasOwnProperty("value")?t3(t,a.type,e):a.hasOwnProperty("defaultValue")&&t3(t,a.type,ve(a.defaultValue)),a.checked==null&&a.defaultChecked!=null&&(t.defaultChecked=!!a.defaultChecked)}function N6(t,a,e){if(a.hasOwnProperty("value")||a.hasOwnProperty("defaultValue")){var r=a.type;if(!(r!=="submit"&&r!=="reset"||a.value!==void 0&&a.value!==null))return;a=""+t._wrapperState.initialValue,e||a===t.value||(t.value=a),t.defaultValue=a}e=t.name,e!==""&&(t.name=""),t.defaultChecked=!!t._wrapperState.initialChecked,e!==""&&(t.name=e)}function t3(t,a,e){(a!=="number"||rl(t.ownerDocument)!==t)&&(e==null?t.defaultValue=""+t._wrapperState.initialValue:t.defaultValue!==""+e&&(t.defaultValue=""+e))}var Wr=Array.isArray;function E4(t,a,e,r){if(t=t.options,a){a={};for(var n=0;n"+a.valueOf().toString()+"",a=Ai.firstChild;t.firstChild;)t.removeChild(t.firstChild);for(;a.firstChild;)t.appendChild(a.firstChild)}});function rn(t,a){if(a){var e=t.firstChild;if(e&&e===t.lastChild&&e.nodeType===3){e.nodeValue=a;return}}t.textContent=a}var Gr={animationIterationCount:!0,aspectRatio:!0,borderImageOutset:!0,borderImageSlice:!0,borderImageWidth:!0,boxFlex:!0,boxFlexGroup:!0,boxOrdinalGroup:!0,columnCount:!0,columns:!0,flex:!0,flexGrow:!0,flexPositive:!0,flexShrink:!0,flexNegative:!0,flexOrder:!0,gridArea:!0,gridRow:!0,gridRowEnd:!0,gridRowSpan:!0,gridRowStart:!0,gridColumn:!0,gridColumnEnd:!0,gridColumnSpan:!0,gridColumnStart:!0,fontWeight:!0,lineClamp:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,tabSize:!0,widows:!0,zIndex:!0,zoom:!0,fillOpacity:!0,floodOpacity:!0,stopOpacity:!0,strokeDasharray:!0,strokeDashoffset:!0,strokeMiterlimit:!0,strokeOpacity:!0,strokeWidth:!0},RM=["Webkit","ms","Moz","O"];Object.keys(Gr).forEach(function(t){RM.forEach(function(a){a=a+t.charAt(0).toUpperCase()+t.substring(1),Gr[a]=Gr[t]})});function t9(t,a,e){return a==null||typeof a=="boolean"||a===""?"":e||typeof a!="number"||a===0||Gr.hasOwnProperty(t)&&Gr[t]?(""+a).trim():a+"px"}function a9(t,a){t=t.style;for(var e in a)if(a.hasOwnProperty(e)){var r=e.indexOf("--")===0,n=t9(e,a[e],r);e==="float"&&(e="cssFloat"),r?t.setProperty(e,n):t[e]=n}}var yM=Qt({menuitem:!0},{area:!0,base:!0,br:!0,col:!0,embed:!0,hr:!0,img:!0,input:!0,keygen:!0,link:!0,meta:!0,param:!0,source:!0,track:!0,wbr:!0});function r3(t,a){if(a){if(yM[t]&&(a.children!=null||a.dangerouslySetInnerHTML!=null))throw Error(Q(137,t));if(a.dangerouslySetInnerHTML!=null){if(a.children!=null)throw Error(Q(60));if(typeof a.dangerouslySetInnerHTML!="object"||!("__html"in a.dangerouslySetInnerHTML))throw Error(Q(61))}if(a.style!=null&&typeof a.style!="object")throw Error(Q(62))}}function n3(t,a){if(t.indexOf("-")===-1)return typeof a.is=="string";switch(t){case"annotation-xml":case"color-profile":case"font-face":case"font-face-src":case"font-face-uri":case"font-face-format":case"font-face-name":case"missing-glyph":return!1;default:return!0}}var i3=null;function j3(t){return t=t.target||t.srcElement||window,t.correspondingUseElement&&(t=t.correspondingUseElement),t.nodeType===3?t.parentNode:t}var l3=null,_4=null,T4=null;function W6(t){if(t=wn(t)){if(typeof l3!="function")throw Error(Q(280));var a=t.stateNode;a&&(a=Fl(a),l3(t.stateNode,t.type,a))}}function e9(t){_4?T4?T4.push(t):T4=[t]:_4=t}function r9(){if(_4){var t=_4,a=T4;if(T4=_4=null,W6(t),a)for(t=0;t>>=0,t===0?32:31-(PM(t)/IM|0)|0}var Fi=64,ki=4194304;function jr(t){switch(t&-t){case 1:return 1;case 2:return 2;case 4:return 4;case 8:return 8;case 16:return 16;case 32:return 32;case 64:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return t&4194240;case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:return t&130023424;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 1073741824;default:return t}}function ol(t,a){var e=t.pendingLanes;if(e===0)return 0;var r=0,n=t.suspendedLanes,i=t.pingedLanes,l=e&268435455;if(l!==0){var o=l&~n;o!==0?r=jr(o):(i&=l,i!==0&&(r=jr(i)))}else l=e&~n,l!==0?r=jr(l):i!==0&&(r=jr(i));if(r===0)return 0;if(a!==0&&a!==r&&(a&n)===0&&(n=r&-r,i=a&-a,n>=i||n===16&&(i&4194240)!==0))return a;if((r&4)!==0&&(r|=e&16),a=t.entangledLanes,a!==0)for(t=t.entanglements,a&=r;0e;e++)a.push(t);return a}function Hn(t,a,e){t.pendingLanes|=a,a!==536870912&&(t.suspendedLanes=0,t.pingedLanes=0),t=t.eventTimes,a=31-G2(a),t[a]=e}function $M(t,a){var e=t.pendingLanes&~a;t.pendingLanes=a,t.suspendedLanes=0,t.pingedLanes=0,t.expiredLanes&=a,t.mutableReadLanes&=a,t.entangledLanes&=a,a=t.entanglements;var r=t.eventTimes;for(t=t.expirationTimes;0=Xr),J6=String.fromCharCode(32),t7=!1;function L9(t,a){switch(t){case"keyup":return pH.indexOf(a.keyCode)!==-1;case"keydown":return a.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function V9(t){return t=t.detail,typeof t=="object"&&"data"in t?t.data:null}var V4=!1;function mH(t,a){switch(t){case"compositionend":return V9(a);case"keypress":return a.which!==32?null:(t7=!0,J6);case"textInput":return t=a.data,t===J6&&t7?null:t;default:return null}}function MH(t,a){if(V4)return t==="compositionend"||!J3&&L9(t,a)?(t=x9(),Ki=Y3=te=null,V4=!1,t):null;switch(t){case"paste":return null;case"keypress":if(!(a.ctrlKey||a.altKey||a.metaKey)||a.ctrlKey&&a.altKey){if(a.char&&1=a)return{node:e,offset:a-t};t=r}t:{for(;e;){if(e.nextSibling){e=e.nextSibling;break t}e=e.parentNode}e=void 0}e=r7(e)}}function B9(t,a){return t&&a?t===a?!0:t&&t.nodeType===3?!1:a&&a.nodeType===3?B9(t,a.parentNode):"contains"in t?t.contains(a):t.compareDocumentPosition?!!(t.compareDocumentPosition(a)&16):!1:!1}function S9(){for(var t=window,a=rl();a instanceof t.HTMLIFrameElement;){try{var e=typeof a.contentWindow.location.href=="string"}catch{e=!1}if(e)t=a.contentWindow;else break;a=rl(t.document)}return a}function th(t){var a=t&&t.nodeName&&t.nodeName.toLowerCase();return a&&(a==="input"&&(t.type==="text"||t.type==="search"||t.type==="tel"||t.type==="url"||t.type==="password")||a==="textarea"||t.contentEditable==="true")}function BH(t){var a=S9(),e=t.focusedElem,r=t.selectionRange;if(a!==e&&e&&e.ownerDocument&&B9(e.ownerDocument.documentElement,e)){if(r!==null&&th(e)){if(a=r.start,t=r.end,t===void 0&&(t=a),"selectionStart"in e)e.selectionStart=a,e.selectionEnd=Math.min(t,e.value.length);else if(t=(a=e.ownerDocument||document)&&a.defaultView||window,t.getSelection){t=t.getSelection();var n=e.textContent.length,i=Math.min(r.start,n);r=r.end===void 0?i:Math.min(r.end,n),!t.extend&&i>r&&(n=r,r=i,i=n),n=n7(e,i);var l=n7(e,r);n&&l&&(t.rangeCount!==1||t.anchorNode!==n.node||t.anchorOffset!==n.offset||t.focusNode!==l.node||t.focusOffset!==l.offset)&&(a=a.createRange(),a.setStart(n.node,n.offset),t.removeAllRanges(),i>r?(t.addRange(a),t.extend(l.node,l.offset)):(a.setEnd(l.node,l.offset),t.addRange(a)))}}for(a=[],t=e;t=t.parentNode;)t.nodeType===1&&a.push({element:t,left:t.scrollLeft,top:t.scrollTop});for(typeof e.focus=="function"&&e.focus(),e=0;e=document.documentMode,R4=null,d3=null,Qr=null,s3=!1;function i7(t,a,e){var r=e.window===e?e.document:e.nodeType===9?e:e.ownerDocument;s3||R4==null||R4!==rl(r)||(r=R4,"selectionStart"in r&&th(r)?r={start:r.selectionStart,end:r.selectionEnd}:(r=(r.ownerDocument&&r.ownerDocument.defaultView||window).getSelection(),r={anchorNode:r.anchorNode,anchorOffset:r.anchorOffset,focusNode:r.focusNode,focusOffset:r.focusOffset}),Qr&&vn(Qr,r)||(Qr=r,r=vl(d3,"onSelect"),0B4||(t.current=M3[B4],M3[B4]=null,B4--)}function Pt(t,a){B4++,M3[B4]=t.current,t.current=a}var ge={},$0=se(ge),e2=se(!1),qe=ge;function N4(t,a){var e=t.type.contextTypes;if(!e)return ge;var r=t.stateNode;if(r&&r.__reactInternalMemoizedUnmaskedChildContext===a)return r.__reactInternalMemoizedMaskedChildContext;var n={},i;for(i in e)n[i]=a[i];return r&&(t=t.stateNode,t.__reactInternalMemoizedUnmaskedChildContext=a,t.__reactInternalMemoizedMaskedChildContext=n),n}function r2(t){return t=t.childContextTypes,t!=null}function dl(){Nt(e2),Nt($0)}function u7(t,a,e){if($0.current!==ge)throw Error(Q(168));Pt($0,a),Pt(e2,e)}function I9(t,a,e){var r=t.stateNode;if(a=a.childContextTypes,typeof r.getChildContext!="function")return e;r=r.getChildContext();for(var n in r)if(!(n in a))throw Error(Q(108,LM(t)||"Unknown",n));return Qt({},e,r)}function sl(t){return t=(t=t.stateNode)&&t.__reactInternalMemoizedMergedChildContext||ge,qe=$0.current,Pt($0,t),Pt(e2,e2.current),!0}function f7(t,a,e){var r=t.stateNode;if(!r)throw Error(Q(169));e?(t=I9(t,a,qe),r.__reactInternalMemoizedMergedChildContext=t,Nt(e2),Nt($0),Pt($0,t)):Nt(e2),Pt(e2,e)}var Aa=null,kl=!1,Io=!1;function O9(t){Aa===null?Aa=[t]:Aa.push(t)}function IH(t){kl=!0,O9(t)}function ue(){if(!Io&&Aa!==null){Io=!0;var t=0,a=yt;try{var e=Aa;for(yt=1;t>=l,n-=l,Fa=1<<32-G2(a)+n|e<L?(V=R,R=null):V=R.sibling;var C=d(s,R,m[L],H);if(C===null){R===null&&(R=V);break}t&&R&&C.alternate===null&&a(s,R),f=i(C,f,L),y===null?x=C:y.sibling=C,y=C,R=V}if(L===m.length)return e(s,R),Wt&&Oe(s,L),x;if(R===null){for(;LL?(V=R,R=null):V=R.sibling;var k=d(s,R,C.value,H);if(k===null){R===null&&(R=V);break}t&&R&&k.alternate===null&&a(s,R),f=i(k,f,L),y===null?x=k:y.sibling=k,y=k,R=V}if(C.done)return e(s,R),Wt&&Oe(s,L),x;if(R===null){for(;!C.done;L++,C=m.next())C=g(s,C.value,H),C!==null&&(f=i(C,f,L),y===null?x=C:y.sibling=C,y=C);return Wt&&Oe(s,L),x}for(R=r(s,R);!C.done;L++,C=m.next())C=u(R,s,L,C.value,H),C!==null&&(t&&C.alternate!==null&&R.delete(C.key===null?L:C.key),f=i(C,f,L),y===null?x=C:y.sibling=C,y=C);return t&&R.forEach(function(b){return a(s,b)}),Wt&&Oe(s,L),x}function w(s,f,m,H){if(typeof m=="object"&&m!==null&&m.type===L4&&m.key===null&&(m=m.props.children),typeof m=="object"&&m!==null){switch(m.$$typeof){case Bi:t:{for(var x=m.key,y=f;y!==null;){if(y.key===x){if(x=m.type,x===L4){if(y.tag===7){e(s,y.sibling),f=n(y,m.props.children),f.return=s,s=f;break t}}else if(y.elementType===x||typeof x=="object"&&x!==null&&x.$$typeof===Ya&&w7(x)===y.type){e(s,y.sibling),f=n(y,m.props),f.ref=Or(s,y,m),f.return=s,s=f;break t}e(s,y);break}else a(s,y);y=y.sibling}m.type===L4?(f=je(m.props.children,s.mode,H,m.key),f.return=s,s=f):(H=el(m.type,m.key,m.props,null,s.mode,H),H.ref=Or(s,f,m),H.return=s,s=H)}return l(s);case w4:t:{for(y=m.key;f!==null;){if(f.key===y)if(f.tag===4&&f.stateNode.containerInfo===m.containerInfo&&f.stateNode.implementation===m.implementation){e(s,f.sibling),f=n(f,m.children||[]),f.return=s,s=f;break t}else{e(s,f);break}else a(s,f);f=f.sibling}f=qo(m,s.mode,H),f.return=s,s=f}return l(s);case Ya:return y=m._init,w(s,f,y(m._payload),H)}if(Wr(m))return p(s,f,m,H);if(_r(m))return z(s,f,m,H);Ui(s,m)}return typeof m=="string"&&m!==""||typeof m=="number"?(m=""+m,f!==null&&f.tag===6?(e(s,f.sibling),f=n(f,m),f.return=s,s=f):(e(s,f),f=jo(m,s.mode,H),f.return=s,s=f),l(s)):e(s,f)}return w}var U4=G9(!0),K9=G9(!1),Ln={},fa=se(Ln),un=se(Ln),fn=se(Ln);function Ue(t){if(t===Ln)throw Error(Q(174));return t}function ch(t,a){switch(Pt(fn,a),Pt(un,t),Pt(fa,Ln),t=a.nodeType,t){case 9:case 11:a=(a=a.documentElement)?a.namespaceURI:e3(null,"");break;default:t=t===8?a.parentNode:a,a=t.namespaceURI||null,t=t.tagName,a=e3(a,t)}Nt(fa),Pt(fa,a)}function W4(){Nt(fa),Nt(un),Nt(fn)}function X9(t){Ue(fn.current);var a=Ue(fa.current),e=e3(a,t.type);a!==e&&(Pt(un,t),Pt(fa,e))}function vh(t){un.current===t&&(Nt(fa),Nt(un))}var Xt=se(0);function Ml(t){for(var a=t;a!==null;){if(a.tag===13){var e=a.memoizedState;if(e!==null&&(e=e.dehydrated,e===null||e.data==="$?"||e.data==="$!"))return a}else if(a.tag===19&&a.memoizedProps.revealOrder!==void 0){if((a.flags&128)!==0)return a}else if(a.child!==null){a.child.return=a,a=a.child;continue}if(a===t)break;for(;a.sibling===null;){if(a.return===null||a.return===t)return null;a=a.return}a.sibling.return=a.return,a=a.sibling}return null}var Oo=[];function gh(){for(var t=0;te?e:4,t(!0);var r=Do.transition;Do.transition={};try{t(!1),a()}finally{yt=e,Do.transition=r}}function gc(){return T2().memoizedState}function $H(t,a,e){var r=he(t);if(e={lane:r,action:e,hasEagerState:!1,eagerState:null,next:null},dc(t))sc(a,e);else if(e=U9(t,a,e,r),e!==null){var n=X0();K2(e,t,r,n),uc(e,a,r)}}function UH(t,a,e){var r=he(t),n={lane:r,action:e,hasEagerState:!1,eagerState:null,next:null};if(dc(t))sc(a,n);else{var i=t.alternate;if(t.lanes===0&&(i===null||i.lanes===0)&&(i=a.lastRenderedReducer,i!==null))try{var l=a.lastRenderedState,o=i(l,e);if(n.hasEagerState=!0,n.eagerState=o,X2(o,l)){var h=a.interleaved;h===null?(n.next=n,oh(a)):(n.next=h.next,h.next=n),a.interleaved=n;return}}catch{}finally{}e=U9(t,a,n,r),e!==null&&(n=X0(),K2(e,t,r,n),uc(e,a,r))}}function dc(t){var a=t.alternate;return t===Yt||a!==null&&a===Yt}function sc(t,a){Zr=Hl=!0;var e=t.pending;e===null?a.next=a:(a.next=e.next,e.next=a),t.pending=a}function uc(t,a,e){if((e&4194240)!==0){var r=a.lanes;r&=t.pendingLanes,e|=r,a.lanes=e,G3(t,e)}}var xl={readContext:_2,useCallback:O0,useContext:O0,useEffect:O0,useImperativeHandle:O0,useInsertionEffect:O0,useLayoutEffect:O0,useMemo:O0,useReducer:O0,useRef:O0,useState:O0,useDebugValue:O0,useDeferredValue:O0,useTransition:O0,useMutableSource:O0,useSyncExternalStore:O0,useId:O0,unstable_isNewReconciler:!1},WH={readContext:_2,useCallback:function(t,a){return da().memoizedState=[t,a===void 0?null:a],t},useContext:_2,useEffect:V7,useImperativeHandle:function(t,a,e){return e=e!=null?e.concat([t]):null,Zi(4194308,4,lc.bind(null,a,t),e)},useLayoutEffect:function(t,a){return Zi(4194308,4,t,a)},useInsertionEffect:function(t,a){return Zi(4,2,t,a)},useMemo:function(t,a){var e=da();return a=a===void 0?null:a,t=t(),e.memoizedState=[t,a],t},useReducer:function(t,a,e){var r=da();return a=e!==void 0?e(a):a,r.memoizedState=r.baseState=a,t={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:t,lastRenderedState:a},r.queue=t,t=t.dispatch=$H.bind(null,Yt,t),[r.memoizedState,t]},useRef:function(t){var a=da();return t={current:t},a.memoizedState=t},useState:L7,useDebugValue:ph,useDeferredValue:function(t){return da().memoizedState=t},useTransition:function(){var t=L7(!1),a=t[0];return t=NH.bind(null,t[1]),da().memoizedState=t,[a,t]},useMutableSource:function(){},useSyncExternalStore:function(t,a,e){var r=Yt,n=da();if(Wt){if(e===void 0)throw Error(Q(407));e=e()}else{if(e=a(),w0===null)throw Error(Q(349));(Ke&30)!==0||Z9(r,a,e)}n.memoizedState=e;var i={value:e,getSnapshot:a};return n.queue=i,V7(tc.bind(null,r,i,t),[t]),r.flags|=2048,mn(9,J9.bind(null,r,i,e,a),void 0,null),e},useId:function(){var t=da(),a=w0.identifierPrefix;if(Wt){var e=ka,r=Fa;e=(r&~(1<<32-G2(r)-1)).toString(32)+e,a=":"+a+"R"+e,e=pn++,0<\/script>",t=t.removeChild(t.firstChild)):typeof r.is=="string"?t=l.createElement(e,{is:r.is}):(t=l.createElement(e),e==="select"&&(l=t,r.multiple?l.multiple=!0:r.size&&(l.size=r.size))):t=l.createElementNS(t,e),t[ca]=a,t[un]=r,uc(t,a,!1,!1),a.stateNode=t;t:{switch(l=Qo(e,r),e){case"dialog":Dt("cancel",t),Dt("close",t),n=r;break;case"iframe":case"object":case"embed":Dt("load",t),n=r;break;case"video":case"audio":for(n=0;nq4&&(a.flags|=128,r=!0,Nr(i,!1),a.lanes=4194304)}else{if(!r)if(t=sl(l),t!==null){if(a.flags|=128,r=!0,e=t.updateQueue,e!==null&&(a.updateQueue=e,a.flags|=4),Nr(i,!0),i.tail===null&&i.tailMode==="hidden"&&!l.alternate&&!Wt)return N0(a),null}else 2*i0()-i.renderingStartTime>q4&&e!==1073741824&&(a.flags|=128,r=!0,Nr(i,!1),a.lanes=4194304);i.isBackwards?(l.sibling=a.child,a.child=l):(e=i.last,e!==null?e.sibling=l:a.child=l,i.last=l)}return i.tail!==null?(a=i.tail,i.rendering=a,i.tail=a.sibling,i.renderingStartTime=i0(),a.sibling=null,e=Xt.current,Pt(Xt,r?e&1|2:e&1),a):(N0(a),null);case 22:case 23:return fh(),r=a.memoizedState!==null,t!==null&&t.memoizedState!==null!==r&&(a.flags|=8192),r&&(a.mode&1)!==0?(d2&1073741824)!==0&&(N0(a),a.subtreeFlags&6&&(a.flags|=8192)):N0(a),null;case 24:return null;case 25:return null}throw Error(Z(156,a.tag))}function _H(t,a){switch(X3(a),a.tag){case 1:return r2(a.type)&&ll(),t=a.flags,t&65536?(a.flags=t&-65537|128,a):null;case 3:return W4(),Nt(e2),Nt(U0),nh(),t=a.flags,(t&65536)!==0&&(t&128)===0?(a.flags=t&-65537|128,a):null;case 5:return rh(a),null;case 13:if(Nt(Xt),t=a.memoizedState,t!==null&&t.dehydrated!==null){if(a.alternate===null)throw Error(Z(340));$4()}return t=a.flags,t&65536?(a.flags=t&-65537|128,a):null;case 19:return Nt(Xt),null;case 4:return W4(),null;case 10:return J3(a.type._context),null;case 22:case 23:return fh(),null;case 24:return null;default:return null}}var Oi=!1,$0=!1,TH=typeof WeakSet=="function"?WeakSet:Set,V1=null;function k4(t,a){var e=t.ref;if(e!==null)if(typeof e=="function")try{e(null)}catch(r){t0(t,a,r)}else e.current=null}function V3(t,a,e){try{e()}catch(r){t0(t,a,r)}}var V7=!1;function PH(t,a){if(o3=el,t=H9(),G3(t)){if("selectionStart"in t)var e={start:t.selectionStart,end:t.selectionEnd};else t:{e=(e=t.ownerDocument)&&e.defaultView||window;var r=e.getSelection&&e.getSelection();if(r&&r.rangeCount!==0){e=r.anchorNode;var n=r.anchorOffset,i=r.focusNode;r=r.focusOffset;try{e.nodeType,i.nodeType}catch{e=null;break t}var l=0,o=-1,h=-1,c=0,v=0,g=t,s=null;a:for(;;){for(var d;g!==e||n!==0&&g.nodeType!==3||(o=l+n),g!==i||r!==0&&g.nodeType!==3||(h=l+r),g.nodeType===3&&(l+=g.nodeValue.length),(d=g.firstChild)!==null;)s=g,g=d;for(;;){if(g===t)break a;if(s===e&&++c===n&&(o=l),s===i&&++v===r&&(h=l),(d=g.nextSibling)!==null)break;g=s,s=g.parentNode}g=d}e=o===-1||h===-1?null:{start:o,end:h}}else e=null}e=e||{start:0,end:0}}else e=null;for(h3={focusedElem:t,selectionRange:e},el=!1,V1=a;V1!==null;)if(a=V1,t=a.child,(a.subtreeFlags&1028)!==0&&t!==null)t.return=a,V1=t;else for(;V1!==null;){a=V1;try{var p=a.alternate;if((a.flags&1024)!==0)switch(a.tag){case 0:case 11:case 15:break;case 1:if(p!==null){var z=p.memoizedProps,L=p.memoizedState,u=a.stateNode,f=u.getSnapshotBeforeUpdate(a.elementType===a.type?z:O2(a.type,z),L);u.__reactInternalSnapshotBeforeUpdate=f}break;case 3:var m=a.stateNode.containerInfo;m.nodeType===1?m.textContent="":m.nodeType===9&&m.documentElement&&m.removeChild(m.documentElement);break;case 5:case 6:case 4:case 17:break;default:throw Error(Z(163))}}catch(M){t0(a,a.return,M)}if(t=a.sibling,t!==null){t.return=a.return,V1=t;break}V1=a.return}return p=V7,V7=!1,p}function tn(t,a,e){var r=a.updateQueue;if(r=r!==null?r.lastEffect:null,r!==null){var n=r=r.next;do{if((n.tag&t)===t){var i=n.destroy;n.destroy=void 0,i!==void 0&&V3(a,e,i)}n=n.next}while(n!==r)}}function Sl(t,a){if(a=a.updateQueue,a=a!==null?a.lastEffect:null,a!==null){var e=a=a.next;do{if((e.tag&t)===t){var r=e.create;e.destroy=r()}e=e.next}while(e!==a)}}function R3(t){var a=t.ref;if(a!==null){var e=t.stateNode;switch(t.tag){case 5:t=e;break;default:t=e}typeof a=="function"?a(t):a.current=t}}function zc(t){var a=t.alternate;a!==null&&(t.alternate=null,zc(a)),t.child=null,t.deletions=null,t.sibling=null,t.tag===5&&(a=t.stateNode,a!==null&&(delete a[ca],delete a[un],delete a[g3],delete a[MH],delete a[HH])),t.stateNode=null,t.return=null,t.dependencies=null,t.memoizedProps=null,t.memoizedState=null,t.pendingProps=null,t.stateNode=null,t.updateQueue=null}function mc(t){return t.tag===5||t.tag===3||t.tag===4}function R7(t){t:for(;;){for(;t.sibling===null;){if(t.return===null||mc(t.return))return null;t=t.return}for(t.sibling.return=t.return,t=t.sibling;t.tag!==5&&t.tag!==6&&t.tag!==18;){if(t.flags&2||t.child===null||t.tag===4)continue t;t.child.return=t,t=t.child}if(!(t.flags&2))return t.stateNode}}function y3(t,a,e){var r=t.tag;if(r===5||r===6)t=t.stateNode,a?e.nodeType===8?e.parentNode.insertBefore(t,a):e.insertBefore(t,a):(e.nodeType===8?(a=e.parentNode,a.insertBefore(t,e)):(a=e,a.appendChild(t)),e=e._reactRootContainer,e!=null||a.onclick!==null||(a.onclick=il));else if(r!==4&&(t=t.child,t!==null))for(y3(t,a,e),t=t.sibling;t!==null;)y3(t,a,e),t=t.sibling}function C3(t,a,e){var r=t.tag;if(r===5||r===6)t=t.stateNode,a?e.insertBefore(t,a):e.appendChild(t);else if(r!==4&&(t=t.child,t!==null))for(C3(t,a,e),t=t.sibling;t!==null;)C3(t,a,e),t=t.sibling}var k0=null,D2=!1;function qa(t,a,e){for(e=e.child;e!==null;)Mc(t,a,e),e=e.sibling}function Mc(t,a,e){if(va&&typeof va.onCommitFiberUnmount=="function")try{va.onCommitFiberUnmount(xl,e)}catch{}switch(e.tag){case 5:$0||k4(e,a);case 6:var r=k0,n=D2;k0=null,qa(t,a,e),k0=r,D2=n,k0!==null&&(D2?(t=k0,e=e.stateNode,t.nodeType===8?t.parentNode.removeChild(e):t.removeChild(e)):k0.removeChild(e.stateNode));break;case 18:k0!==null&&(D2?(t=k0,e=e.stateNode,t.nodeType===8?Ao(t.parentNode,e):t.nodeType===1&&Ao(t,e),cn(t)):Ao(k0,e.stateNode));break;case 4:r=k0,n=D2,k0=e.stateNode.containerInfo,D2=!0,qa(t,a,e),k0=r,D2=n;break;case 0:case 11:case 14:case 15:if(!$0&&(r=e.updateQueue,r!==null&&(r=r.lastEffect,r!==null))){n=r=r.next;do{var i=n,l=i.destroy;i=i.tag,l!==void 0&&((i&2)!==0||(i&4)!==0)&&V3(e,a,l),n=n.next}while(n!==r)}qa(t,a,e);break;case 1:if(!$0&&(k4(e,a),r=e.stateNode,typeof r.componentWillUnmount=="function"))try{r.props=e.memoizedProps,r.state=e.memoizedState,r.componentWillUnmount()}catch(o){t0(e,a,o)}qa(t,a,e);break;case 21:qa(t,a,e);break;case 22:e.mode&1?($0=(r=$0)||e.memoizedState!==null,qa(t,a,e),$0=r):qa(t,a,e);break;default:qa(t,a,e)}}function y7(t){var a=t.updateQueue;if(a!==null){t.updateQueue=null;var e=t.stateNode;e===null&&(e=t.stateNode=new TH),a.forEach(function(r){var n=qH.bind(null,t,r);e.has(r)||(e.add(r),r.then(n,n))})}}function I2(t,a){var e=a.deletions;if(e!==null)for(var r=0;rn&&(n=l),r&=~i}if(r=n,r=i0()-r,r=(120>r?120:480>r?480:1080>r?1080:1920>r?1920:3e3>r?3e3:4320>r?4320:1960*OH(r/1960))-r,10t?16:t,Za===null)var r=!1;else{if(t=Za,Za=null,ml=0,(dt&6)!==0)throw Error(Z(331));var n=dt;for(dt|=4,V1=t.current;V1!==null;){var i=V1,l=i.child;if((V1.flags&16)!==0){var o=i.deletions;if(o!==null){for(var h=0;hi0()-sh?Oe(t,0):dh|=e),n2(t,a)}function Cc(t,a){a===0&&((t.mode&1)===0?a=1:(a=yi,yi<<=1,(yi&130023424)===0&&(yi=4194304)));var e=K0();t=Aa(t,a),t!==null&&(xn(t,a,e),n2(t,e))}function jH(t){var a=t.memoizedState,e=0;a!==null&&(e=a.retryLane),Cc(t,e)}function qH(t,a){var e=0;switch(t.tag){case 13:var r=t.stateNode,n=t.memoizedState;n!==null&&(e=n.retryLane);break;case 19:r=t.stateNode;break;default:throw Error(Z(314))}r!==null&&r.delete(a),Cc(t,e)}var Bc;Bc=function(t,a,e){if(t!==null)if(t.memoizedProps!==a.pendingProps||e2.current)a2=!0;else{if((t.lanes&e)===0&&(a.flags&128)===0)return a2=!1,bH(t,a,e);a2=(t.flags&131072)!==0}else a2=!1,Wt&&(a.flags&1048576)!==0&&F9(a,cl,a.index);switch(a.lanes=0,a.tag){case 2:var r=a.type;Gi(t,a),t=a.pendingProps;var n=N4(a,U0.current);I4(a,e),n=lh(null,a,r,t,n,e);var i=oh();return a.flags|=1,typeof n=="object"&&n!==null&&typeof n.render=="function"&&n.$$typeof===void 0?(a.tag=1,a.memoizedState=null,a.updateQueue=null,r2(r)?(i=!0,ol(a)):i=!1,a.memoizedState=n.state!==null&&n.state!==void 0?n.state:null,ah(a),n.updater=Cl,a.stateNode=n,n._reactInternals=a,z3(a,r,t,e),a=H3(null,a,r,!0,i,e)):(a.tag=0,Wt&&i&&K3(a),G0(null,a,n,e),a=a.child),a;case 16:r=a.elementType;t:{switch(Gi(t,a),t=a.pendingProps,n=r._init,r=n(r._payload),a.type=r,n=a.tag=KH(r),t=O2(r,t),n){case 0:a=M3(null,a,r,t,e);break t;case 1:a=x7(null,a,r,t,e);break t;case 11:a=M7(null,a,r,t,e);break t;case 14:a=H7(null,a,r,O2(r.type,t),e);break t}throw Error(Z(306,r,""))}return a;case 0:return r=a.type,n=a.pendingProps,n=a.elementType===r?n:O2(r,n),M3(t,a,r,n,e);case 1:return r=a.type,n=a.pendingProps,n=a.elementType===r?n:O2(r,n),x7(t,a,r,n,e);case 3:t:{if(gc(a),t===null)throw Error(Z(387));r=a.pendingProps,i=a.memoizedState,n=i.element,_9(t,a),dl(a,r,null,e);var l=a.memoizedState;if(r=l.element,i.isDehydrated)if(i={element:r,isDehydrated:!1,cache:l.cache,pendingSuspenseBoundaries:l.pendingSuspenseBoundaries,transitions:l.transitions},a.updateQueue.baseState=i,a.memoizedState=i,a.flags&256){n=j4(Error(Z(423)),a),a=w7(t,a,r,e,n);break t}else if(r!==n){n=j4(Error(Z(424)),a),a=w7(t,a,r,e,n);break t}else for(s2=ee(a.stateNode.containerInfo.firstChild),u2=a,Wt=!0,N2=null,e=O9(a,null,r,e),a.child=e;e;)e.flags=e.flags&-3|4096,e=e.sibling;else{if($4(),r===n){a=Fa(t,a,e);break t}G0(t,a,r,e)}a=a.child}return a;case 5:return D9(a),t===null&&u3(a),r=a.type,n=a.pendingProps,i=t!==null?t.memoizedProps:null,l=n.children,c3(r,n)?l=null:i!==null&&c3(r,i)&&(a.flags|=32),vc(t,a),G0(t,a,l,e),a.child;case 6:return t===null&&u3(a),null;case 13:return dc(t,a,e);case 4:return eh(a,a.stateNode.containerInfo),r=a.pendingProps,t===null?a.child=U4(a,null,r,e):G0(t,a,r,e),a.child;case 11:return r=a.type,n=a.pendingProps,n=a.elementType===r?n:O2(r,n),M7(t,a,r,n,e);case 7:return G0(t,a,a.pendingProps,e),a.child;case 8:return G0(t,a,a.pendingProps.children,e),a.child;case 12:return G0(t,a,a.pendingProps.children,e),a.child;case 10:t:{if(r=a.type._context,n=a.pendingProps,i=a.memoizedProps,l=n.value,Pt(vl,r._currentValue),r._currentValue=l,i!==null)if(W2(i.value,l)){if(i.children===n.children&&!e2.current){a=Fa(t,a,e);break t}}else for(i=a.child,i!==null&&(i.return=a);i!==null;){var o=i.dependencies;if(o!==null){l=i.child;for(var h=o.firstContext;h!==null;){if(h.context===r){if(i.tag===1){h=Ca(-1,e&-e),h.tag=2;var c=i.updateQueue;if(c!==null){c=c.shared;var v=c.pending;v===null?h.next=h:(h.next=v.next,v.next=h),c.pending=h}}i.lanes|=e,h=i.alternate,h!==null&&(h.lanes|=e),f3(i.return,e,a),o.lanes|=e;break}h=h.next}}else if(i.tag===10)l=i.type===a.type?null:i.child;else if(i.tag===18){if(l=i.return,l===null)throw Error(Z(341));l.lanes|=e,o=l.alternate,o!==null&&(o.lanes|=e),f3(l,e,a),l=i.sibling}else l=i.child;if(l!==null)l.return=i;else for(l=i;l!==null;){if(l===a){l=null;break}if(i=l.sibling,i!==null){i.return=l.return,l=i;break}l=l.return}i=l}G0(t,a,n.children,e),a=a.child}return a;case 9:return n=a.type,r=a.pendingProps.children,I4(a,e),n=S2(n),r=r(n),a.flags|=1,G0(t,a,r,e),a.child;case 14:return r=a.type,n=O2(r,a.pendingProps),n=O2(r.type,n),H7(t,a,r,n,e);case 15:return hc(t,a,a.type,a.pendingProps,e);case 17:return r=a.type,n=a.pendingProps,n=a.elementType===r?n:O2(r,n),Gi(t,a),a.tag=1,r2(r)?(t=!0,ol(a)):t=!1,I4(a,e),P9(a,r,n),z3(a,r,n,e),H3(null,a,r,!0,t,e);case 19:return sc(t,a,e);case 22:return cc(t,a,e)}throw Error(Z(156,a.tag))};function Sc(t,a){return a9(t,a)}function GH(t,a,e,r){this.tag=t,this.key=e,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.ref=null,this.pendingProps=a,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=r,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function C2(t,a,e,r){return new GH(t,a,e,r)}function zh(t){return t=t.prototype,!(!t||!t.isReactComponent)}function KH(t){if(typeof t=="function")return zh(t)?1:0;if(t!=null){if(t=t.$$typeof,t===T3)return 11;if(t===P3)return 14}return 2}function le(t,a){var e=t.alternate;return e===null?(e=C2(t.tag,a,t.key,t.mode),e.elementType=t.elementType,e.type=t.type,e.stateNode=t.stateNode,e.alternate=t,t.alternate=e):(e.pendingProps=a,e.type=t.type,e.flags=0,e.subtreeFlags=0,e.deletions=null),e.flags=t.flags&14680064,e.childLanes=t.childLanes,e.lanes=t.lanes,e.child=t.child,e.memoizedProps=t.memoizedProps,e.memoizedState=t.memoizedState,e.updateQueue=t.updateQueue,a=t.dependencies,e.dependencies=a===null?null:{lanes:a.lanes,firstContext:a.firstContext},e.sibling=t.sibling,e.index=t.index,e.ref=t.ref,e}function Yi(t,a,e,r,n,i){var l=2;if(r=t,typeof t=="function")zh(t)&&(l=1);else if(typeof t=="string")l=5;else t:switch(t){case L4:return De(e.children,n,i,a);case _3:l=8,n|=8;break;case No:return t=C2(12,e,a,n|2),t.elementType=No,t.lanes=i,t;case $o:return t=C2(13,e,a,n),t.elementType=$o,t.lanes=i,t;case Uo:return t=C2(19,e,a,n),t.elementType=Uo,t.lanes=i,t;case I7:return Fl(e,n,i,a);default:if(typeof t=="object"&&t!==null)switch(t.$$typeof){case T7:l=10;break t;case P7:l=9;break t;case T3:l=11;break t;case P3:l=14;break t;case Ga:l=16,r=null;break t}throw Error(Z(130,t==null?t:typeof t,""))}return a=C2(l,e,a,n),a.elementType=t,a.type=r,a.lanes=i,a}function De(t,a,e,r){return t=C2(7,t,r,a),t.lanes=e,t}function Fl(t,a,e,r){return t=C2(22,t,r,a),t.elementType=I7,t.lanes=e,t.stateNode={isHidden:!1},t}function Io(t,a,e){return t=C2(6,t,null,a),t.lanes=e,t}function Oo(t,a,e){return a=C2(4,t.children!==null?t.children:[],t.key,a),a.lanes=e,a.stateNode={containerInfo:t.containerInfo,pendingChildren:null,implementation:t.implementation},a}function XH(t,a,e,r,n){this.tag=a,this.containerInfo=t,this.finishedWork=this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.pendingContext=this.context=null,this.callbackPriority=0,this.eventTimes=wo(0),this.expirationTimes=wo(-1),this.entangledLanes=this.finishedLanes=this.mutableReadLanes=this.expiredLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=wo(0),this.identifierPrefix=r,this.onRecoverableError=n,this.mutableSourceEagerHydrationData=null}function mh(t,a,e,r,n,i,l,o,h){return t=new XH(t,a,e,o,h),a===1?(a=1,i===!0&&(a|=8)):a=0,i=C2(3,null,null,a),t.current=i,i.stateNode=t,i.memoizedState={element:r,isDehydrated:e,cache:null,transitions:null,pendingSuspenseBoundaries:null},ah(i),t}function YH(t,a,e){var r=3{"use strict";function Ec(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(Ec)}catch(t){console.error(t)}}Ec(),_c.exports=bc()});var Pc=B(wh=>{"use strict";var Tc=Tl();wh.createRoot=Tc.createRoot,wh.hydrateRoot=Tc.hydrateRoot;var D_});function ax(t){var a={};return function(e){return a[e]===void 0&&(a[e]=t(e)),a[e]}}function cx(t,a,e){let r=Oc(a,e);return typeof t=="string"&&t.indexOf("-")===-1&&!ox(t[0])&&Object.keys(r).forEach(n=>{ix(n)||delete r[n]}),r}function gx(t){return a=>{if(Array.isArray(a))throw new Error('Using the "styled" tag in runtime is not supported. Make sure you have set up the Babel plugin correctly. See https://github.com/callstack/linaria#setup');let e=(n,i)=>{let{as:l=t,class:o}=n,h=cx(l,n,["as","class"]);h.ref=i,h.className=a.atomic?Ic(a.class,h.className||o):Ic(h.className||o,a.class);let{vars:c}=a;if(c){let v={};for(let d in c){let p=c[d],z=p[0],L=p[1]||"",u=typeof z=="function"?z(n):z;vx(u,a.name),v[`--${d}`]=`${u}${L}`}let g=h.style||{},s=Object.keys(g);s.length>0&&s.forEach(d=>{v[d]=g[d]}),h.style=v}return t.__linaria&&t!==l?(h.as=l,Rn.default.createElement(t,h)):Rn.default.createElement(l,h)},r=Rn.default.forwardRef?Rn.default.forwardRef(e):n=>{let i=Oc(n,["innerRef"]);return e(i,n.innerRef)};return r.displayName=a.name,r.__linaria={className:a.class,extends:t},r}}var Rn,ex,rx,nx,ix,lx,Ic,ox,hx,Oc,vx,y0,Lh=eo(()=>{Rn=B1(T1(),1);ex=ax,rx=/^((children|dangerouslySetInnerHTML|key|ref|autoFocus|defaultValue|defaultChecked|innerHTML|suppressContentEditableWarning|suppressHydrationWarning|valueLink|accept|acceptCharset|accessKey|action|allow|allowUserMedia|allowPaymentRequest|allowFullScreen|allowTransparency|alt|async|autoComplete|autoPlay|capture|cellPadding|cellSpacing|challenge|charSet|checked|cite|classID|className|cols|colSpan|content|contentEditable|contextMenu|controls|controlsList|coords|crossOrigin|data|dateTime|decoding|default|defer|dir|disabled|disablePictureInPicture|download|draggable|encType|form|formAction|formEncType|formMethod|formNoValidate|formTarget|frameBorder|headers|height|hidden|high|href|hrefLang|htmlFor|httpEquiv|id|inputMode|integrity|is|keyParams|keyType|kind|label|lang|list|loading|loop|low|marginHeight|marginWidth|max|maxLength|media|mediaGroup|method|min|minLength|multiple|muted|name|nonce|noValidate|open|optimum|pattern|placeholder|playsInline|poster|preload|profile|radioGroup|readOnly|referrerPolicy|rel|required|reversed|role|rows|rowSpan|sandbox|scope|scoped|scrolling|seamless|selected|shape|size|sizes|slot|span|spellCheck|src|srcDoc|srcLang|srcSet|start|step|style|summary|tabIndex|target|title|type|useMap|value|width|wmode|wrap|about|datatype|inlist|prefix|property|resource|typeof|vocab|autoCapitalize|autoCorrect|autoSave|color|inert|itemProp|itemScope|itemType|itemID|itemRef|on|results|security|unselectable|accentHeight|accumulate|additive|alignmentBaseline|allowReorder|alphabetic|amplitude|arabicForm|ascent|attributeName|attributeType|autoReverse|azimuth|baseFrequency|baselineShift|baseProfile|bbox|begin|bias|by|calcMode|capHeight|clip|clipPathUnits|clipPath|clipRule|colorInterpolation|colorInterpolationFilters|colorProfile|colorRendering|contentScriptType|contentStyleType|cursor|cx|cy|d|decelerate|descent|diffuseConstant|direction|display|divisor|dominantBaseline|dur|dx|dy|edgeMode|elevation|enableBackground|end|exponent|externalResourcesRequired|fill|fillOpacity|fillRule|filter|filterRes|filterUnits|floodColor|floodOpacity|focusable|fontFamily|fontSize|fontSizeAdjust|fontStretch|fontStyle|fontVariant|fontWeight|format|from|fr|fx|fy|g1|g2|glyphName|glyphOrientationHorizontal|glyphOrientationVertical|glyphRef|gradientTransform|gradientUnits|hanging|horizAdvX|horizOriginX|ideographic|imageRendering|in|in2|intercept|k|k1|k2|k3|k4|kernelMatrix|kernelUnitLength|kerning|keyPoints|keySplines|keyTimes|lengthAdjust|letterSpacing|lightingColor|limitingConeAngle|local|markerEnd|markerMid|markerStart|markerHeight|markerUnits|markerWidth|mask|maskContentUnits|maskUnits|mathematical|mode|numOctaves|offset|opacity|operator|order|orient|orientation|origin|overflow|overlinePosition|overlineThickness|panose1|paintOrder|pathLength|patternContentUnits|patternTransform|patternUnits|pointerEvents|points|pointsAtX|pointsAtY|pointsAtZ|preserveAlpha|preserveAspectRatio|primitiveUnits|r|radius|refX|refY|renderingIntent|repeatCount|repeatDur|requiredExtensions|requiredFeatures|restart|result|rotate|rx|ry|scale|seed|shapeRendering|slope|spacing|specularConstant|specularExponent|speed|spreadMethod|startOffset|stdDeviation|stemh|stemv|stitchTiles|stopColor|stopOpacity|strikethroughPosition|strikethroughThickness|string|stroke|strokeDasharray|strokeDashoffset|strokeLinecap|strokeLinejoin|strokeMiterlimit|strokeOpacity|strokeWidth|surfaceScale|systemLanguage|tableValues|targetX|targetY|textAnchor|textDecoration|textRendering|textLength|to|transform|u1|u2|underlinePosition|underlineThickness|unicode|unicodeBidi|unicodeRange|unitsPerEm|vAlphabetic|vHanging|vIdeographic|vMathematical|values|vectorEffect|version|vertAdvY|vertOriginX|vertOriginY|viewBox|viewTarget|visibility|widths|wordSpacing|writingMode|x|xHeight|x1|x2|xChannelSelector|xlinkActuate|xlinkArcrole|xlinkHref|xlinkRole|xlinkShow|xlinkTitle|xlinkType|xmlBase|xmlns|xmlnsXlink|xmlLang|xmlSpace|y|y1|y2|yChannelSelector|z|zoomAndPan|for|class|autofocus)|(([Dd][Aa][Tt][Aa]|[Aa][Rr][Ii][Aa]|x)-.*))$/,nx=ex(function(t){return rx.test(t)||t.charCodeAt(0)===111&&t.charCodeAt(1)===110&&t.charCodeAt(2)<91}),ix=nx,lx=function(){let a=Array.prototype.slice.call(arguments).filter(Boolean),e={},r=[];a.forEach(i=>{(i?i.split(" "):[]).forEach(o=>{if(o.startsWith("atm_")){let[,h]=o.split("_");e[h]=o}else r.push(o)})});let n=[];for(let i in e)Object.prototype.hasOwnProperty.call(e,i)&&n.push(e[i]);return n.push(...r),n.join(" ")},Ic=lx,ox=t=>t.toUpperCase()===t,hx=t=>a=>t.indexOf(a)===-1,Oc=(t,a)=>{let e={};return Object.keys(t).filter(hx(a)).forEach(r=>{e[r]=t[r]}),e};vx=(t,a)=>{{if(typeof t=="string"||typeof t=="number"&&isFinite(t))return;let e=typeof t=="object"?JSON.stringify(t):String(t);console.warn(`An interpolation evaluated to '${e}' in the component '${a}', which is probably a mistake. You should explicitly cast or transform the value to a string.`)}};y0=new Proxy(gx,{get(t,a){return t(a)}})});var Nc=B((U_,Dc)=>{function dx(t,a,e){return t===t&&(e!==void 0&&(t=t<=e?t:e),a!==void 0&&(t=t>=a?t:a)),t}Dc.exports=dx});var Uc=B((W_,$c)=>{var sx=/\s/;function ux(t){for(var a=t.length;a--&&sx.test(t.charAt(a)););return a}$c.exports=ux});var jc=B((j_,Wc)=>{var fx=Uc(),px=/^\s+/;function zx(t){return t&&t.slice(0,fx(t)+1).replace(px,"")}Wc.exports=zx});var de=B((q_,qc)=>{function mx(t){var a=typeof t;return t!=null&&(a=="object"||a=="function")}qc.exports=mx});var Vh=B((G_,Gc)=>{var Mx=typeof global=="object"&&global&&global.Object===Object&&global;Gc.exports=Mx});var j2=B((K_,Kc)=>{var Hx=Vh(),xx=typeof self=="object"&&self&&self.Object===Object&&self,wx=Hx||xx||Function("return this")();Kc.exports=wx});var X4=B((X_,Xc)=>{var Lx=j2(),Vx=Lx.Symbol;Xc.exports=Vx});var Jc=B((Y_,Zc)=>{var Yc=X4(),Qc=Object.prototype,Rx=Qc.hasOwnProperty,yx=Qc.toString,yn=Yc?Yc.toStringTag:void 0;function Cx(t){var a=Rx.call(t,yn),e=t[yn];try{t[yn]=void 0;var r=!0}catch{}var n=yx.call(t);return r&&(a?t[yn]=e:delete t[yn]),n}Zc.exports=Cx});var av=B((Q_,tv)=>{var Bx=Object.prototype,Sx=Bx.toString;function Ax(t){return Sx.call(t)}tv.exports=Ax});var Y4=B((Z_,nv)=>{var ev=X4(),Fx=Jc(),kx=av(),bx="[object Null]",Ex="[object Undefined]",rv=ev?ev.toStringTag:void 0;function _x(t){return t==null?t===void 0?Ex:bx:rv&&rv in Object(t)?Fx(t):kx(t)}nv.exports=_x});var Q4=B((J_,iv)=>{function Tx(t){return t!=null&&typeof t=="object"}iv.exports=Tx});var Cn=B((tT,lv)=>{var Px=Y4(),Ix=Q4(),Ox="[object Symbol]";function Dx(t){return typeof t=="symbol"||Ix(t)&&Px(t)==Ox}lv.exports=Dx});var Pl=B((aT,cv)=>{var Nx=jc(),ov=de(),$x=Cn(),hv=0/0,Ux=/^[-+]0x[0-9a-f]+$/i,Wx=/^0b[01]+$/i,jx=/^0o[0-7]+$/i,qx=parseInt;function Gx(t){if(typeof t=="number")return t;if($x(t))return hv;if(ov(t)){var a=typeof t.valueOf=="function"?t.valueOf():t;t=ov(a)?a+"":a}if(typeof t!="string")return t===0?t:+t;t=Nx(t);var e=Wx.test(t);return e||jx.test(t)?qx(t.slice(2),e?2:8):Ux.test(t)?hv:+t}cv.exports=Gx});var Z4=B((eT,vv)=>{var Kx=Nc(),Rh=Pl();function Xx(t,a,e){return e===void 0&&(e=a,a=void 0),e!==void 0&&(e=Rh(e),e=e===e?e:0),a!==void 0&&(a=Rh(a),a=a===a?a:0),Kx(Rh(t),a,e)}vv.exports=Xx});var yh=B((rT,gv)=>{var Yx=Y4(),Qx=de(),Zx="[object AsyncFunction]",Jx="[object Function]",tw="[object GeneratorFunction]",aw="[object Proxy]";function ew(t){if(!Qx(t))return!1;var a=Yx(t);return a==Jx||a==tw||a==Zx||a==aw}gv.exports=ew});var sv=B((nT,dv)=>{var rw=j2(),nw=rw["__core-js_shared__"];dv.exports=nw});var pv=B((iT,fv)=>{var Ch=sv(),uv=function(){var t=/[^.]+$/.exec(Ch&&Ch.keys&&Ch.keys.IE_PROTO||"");return t?"Symbol(src)_1."+t:""}();function iw(t){return!!uv&&uv in t}fv.exports=iw});var Bh=B((lT,zv)=>{var lw=Function.prototype,ow=lw.toString;function hw(t){if(t!=null){try{return ow.call(t)}catch{}try{return t+""}catch{}}return""}zv.exports=hw});var Mv=B((oT,mv)=>{var cw=yh(),vw=pv(),gw=de(),dw=Bh(),sw=/[\\^$.*+?()[\]{}|]/g,uw=/^\[object .+?Constructor\]$/,fw=Function.prototype,pw=Object.prototype,zw=fw.toString,mw=pw.hasOwnProperty,Mw=RegExp("^"+zw.call(mw).replace(sw,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function Hw(t){if(!gw(t)||vw(t))return!1;var a=cw(t)?Mw:uw;return a.test(dw(t))}mv.exports=Hw});var xv=B((hT,Hv)=>{function xw(t,a){return t?.[a]}Hv.exports=xw});var se=B((cT,wv)=>{var ww=Mv(),Lw=xv();function Vw(t,a){var e=Lw(t,a);return ww(e)?e:void 0}wv.exports=Vw});var Bn=B((vT,Lv)=>{var Rw=se(),yw=Rw(Object,"create");Lv.exports=yw});var yv=B((gT,Rv)=>{var Vv=Bn();function Cw(){this.__data__=Vv?Vv(null):{},this.size=0}Rv.exports=Cw});var Bv=B((dT,Cv)=>{function Bw(t){var a=this.has(t)&&delete this.__data__[t];return this.size-=a?1:0,a}Cv.exports=Bw});var Av=B((sT,Sv)=>{var Sw=Bn(),Aw="__lodash_hash_undefined__",Fw=Object.prototype,kw=Fw.hasOwnProperty;function bw(t){var a=this.__data__;if(Sw){var e=a[t];return e===Aw?void 0:e}return kw.call(a,t)?a[t]:void 0}Sv.exports=bw});var kv=B((uT,Fv)=>{var Ew=Bn(),_w=Object.prototype,Tw=_w.hasOwnProperty;function Pw(t){var a=this.__data__;return Ew?a[t]!==void 0:Tw.call(a,t)}Fv.exports=Pw});var Ev=B((fT,bv)=>{var Iw=Bn(),Ow="__lodash_hash_undefined__";function Dw(t,a){var e=this.__data__;return this.size+=this.has(t)?0:1,e[t]=Iw&&a===void 0?Ow:a,this}bv.exports=Dw});var Tv=B((pT,_v)=>{var Nw=yv(),$w=Bv(),Uw=Av(),Ww=kv(),jw=Ev();function J4(t){var a=-1,e=t==null?0:t.length;for(this.clear();++a{function qw(){this.__data__=[],this.size=0}Pv.exports=qw});var Il=B((mT,Ov)=>{function Gw(t,a){return t===a||t!==t&&a!==a}Ov.exports=Gw});var Sn=B((MT,Dv)=>{var Kw=Il();function Xw(t,a){for(var e=t.length;e--;)if(Kw(t[e][0],a))return e;return-1}Dv.exports=Xw});var $v=B((HT,Nv)=>{var Yw=Sn(),Qw=Array.prototype,Zw=Qw.splice;function Jw(t){var a=this.__data__,e=Yw(a,t);if(e<0)return!1;var r=a.length-1;return e==r?a.pop():Zw.call(a,e,1),--this.size,!0}Nv.exports=Jw});var Wv=B((xT,Uv)=>{var tL=Sn();function aL(t){var a=this.__data__,e=tL(a,t);return e<0?void 0:a[e][1]}Uv.exports=aL});var qv=B((wT,jv)=>{var eL=Sn();function rL(t){return eL(this.__data__,t)>-1}jv.exports=rL});var Kv=B((LT,Gv)=>{var nL=Sn();function iL(t,a){var e=this.__data__,r=nL(e,t);return r<0?(++this.size,e.push([t,a])):e[r][1]=a,this}Gv.exports=iL});var An=B((VT,Xv)=>{var lL=Iv(),oL=$v(),hL=Wv(),cL=qv(),vL=Kv();function tr(t){var a=-1,e=t==null?0:t.length;for(this.clear();++a{var gL=se(),dL=j2(),sL=gL(dL,"Map");Yv.exports=sL});var Jv=B((yT,Zv)=>{var Qv=Tv(),uL=An(),fL=Ol();function pL(){this.size=0,this.__data__={hash:new Qv,map:new(fL||uL),string:new Qv}}Zv.exports=pL});var ag=B((CT,tg)=>{function zL(t){var a=typeof t;return a=="string"||a=="number"||a=="symbol"||a=="boolean"?t!=="__proto__":t===null}tg.exports=zL});var Fn=B((BT,eg)=>{var mL=ag();function ML(t,a){var e=t.__data__;return mL(a)?e[typeof a=="string"?"string":"hash"]:e.map}eg.exports=ML});var ng=B((ST,rg)=>{var HL=Fn();function xL(t){var a=HL(this,t).delete(t);return this.size-=a?1:0,a}rg.exports=xL});var lg=B((AT,ig)=>{var wL=Fn();function LL(t){return wL(this,t).get(t)}ig.exports=LL});var hg=B((FT,og)=>{var VL=Fn();function RL(t){return VL(this,t).has(t)}og.exports=RL});var vg=B((kT,cg)=>{var yL=Fn();function CL(t,a){var e=yL(this,t),r=e.size;return e.set(t,a),this.size+=e.size==r?0:1,this}cg.exports=CL});var Dl=B((bT,gg)=>{var BL=Jv(),SL=ng(),AL=lg(),FL=hg(),kL=vg();function ar(t){var a=-1,e=t==null?0:t.length;for(this.clear();++a{var bL="__lodash_hash_undefined__";function EL(t){return this.__data__.set(t,bL),this}dg.exports=EL});var fg=B((_T,ug)=>{function _L(t){return this.__data__.has(t)}ug.exports=_L});var Sh=B((TT,pg)=>{var TL=Dl(),PL=sg(),IL=fg();function Nl(t){var a=-1,e=t==null?0:t.length;for(this.__data__=new TL;++a{function OL(t,a,e,r){for(var n=t.length,i=e+(r?1:-1);r?i--:++i{function DL(t){return t!==t}Mg.exports=DL});var wg=B((OT,xg)=>{function NL(t,a,e){for(var r=e-1,n=t.length;++r{var $L=mg(),UL=Hg(),WL=wg();function jL(t,a,e){return a===a?WL(t,a,e):$L(t,UL,e)}Lg.exports=jL});var yg=B((NT,Rg)=>{var qL=Vg();function GL(t,a){var e=t==null?0:t.length;return!!e&&qL(t,a,0)>-1}Rg.exports=GL});var Bg=B(($T,Cg)=>{function KL(t,a,e){for(var r=-1,n=t==null?0:t.length;++r{function XL(t,a){return t.has(a)}Sg.exports=XL});var Fh=B((WT,Ag)=>{var YL=se(),QL=j2(),ZL=YL(QL,"Set");Ag.exports=ZL});var kg=B((jT,Fg)=>{function JL(){}Fg.exports=JL});var $l=B((qT,bg)=>{function tV(t){var a=-1,e=Array(t.size);return t.forEach(function(r){e[++a]=r}),e}bg.exports=tV});var _g=B((GT,Eg)=>{var kh=Fh(),aV=kg(),eV=$l(),rV=1/0,nV=kh&&1/eV(new kh([,-0]))[1]==rV?function(t){return new kh(t)}:aV;Eg.exports=nV});var Pg=B((KT,Tg)=>{var iV=Sh(),lV=yg(),oV=Bg(),hV=Ah(),cV=_g(),vV=$l(),gV=200;function dV(t,a,e){var r=-1,n=lV,i=t.length,l=!0,o=[],h=o;if(e)l=!1,n=oV;else if(i>=gV){var c=a?null:cV(t);if(c)return vV(c);l=!1,n=hV,h=new iV}else h=a?[]:o;t:for(;++r{var sV=Pg();function uV(t){return t&&t.length?sV(t):[]}Ig.exports=uV});var bh=B((YT,Dg)=>{function fV(t,a){for(var e=-1,r=a.length,n=t.length;++e{var pV=Y4(),zV=Q4(),mV="[object Arguments]";function MV(t){return zV(t)&&pV(t)==mV}Ng.exports=MV});var Ul=B((ZT,jg)=>{var Ug=$g(),HV=Q4(),Wg=Object.prototype,xV=Wg.hasOwnProperty,wV=Wg.propertyIsEnumerable,LV=Ug(function(){return arguments}())?Ug:function(t){return HV(t)&&xV.call(t,"callee")&&!wV.call(t,"callee")};jg.exports=LV});var q2=B((JT,qg)=>{var VV=Array.isArray;qg.exports=VV});var Yg=B((tP,Xg)=>{var Gg=X4(),RV=Ul(),yV=q2(),Kg=Gg?Gg.isConcatSpreadable:void 0;function CV(t){return yV(t)||RV(t)||!!(Kg&&t&&t[Kg])}Xg.exports=CV});var Jg=B((aP,Zg)=>{var BV=bh(),SV=Yg();function Qg(t,a,e,r,n){var i=-1,l=t.length;for(e||(e=SV),n||(n=[]);++i0&&e(o)?a>1?Qg(o,a-1,e,r,n):BV(n,o):r||(n[n.length]=o)}return n}Zg.exports=Qg});var ad=B((eP,td)=>{var AV=Jg();function FV(t){var a=t==null?0:t.length;return a?AV(t,1):[]}td.exports=FV});var rd=B((rP,ed)=>{var kV=Math.ceil,bV=Math.max;function EV(t,a,e,r){for(var n=-1,i=bV(kV((a-t)/(e||1)),0),l=Array(i);i--;)l[r?i:++n]=t,t+=e;return l}ed.exports=EV});var Wl=B((nP,nd)=>{var _V=9007199254740991;function TV(t){return typeof t=="number"&&t>-1&&t%1==0&&t<=_V}nd.exports=TV});var jl=B((iP,id)=>{var PV=yh(),IV=Wl();function OV(t){return t!=null&&IV(t.length)&&!PV(t)}id.exports=OV});var ql=B((lP,ld)=>{var DV=9007199254740991,NV=/^(?:0|[1-9]\d*)$/;function $V(t,a){var e=typeof t;return a=a??DV,!!a&&(e=="number"||e!="symbol"&&NV.test(t))&&t>-1&&t%1==0&&t{var UV=Il(),WV=jl(),jV=ql(),qV=de();function GV(t,a,e){if(!qV(e))return!1;var r=typeof a;return(r=="number"?WV(e)&&jV(a,e.length):r=="string"&&a in e)?UV(e[a],t):!1}od.exports=GV});var gd=B((hP,vd)=>{var KV=Pl(),cd=1/0,XV=17976931348623157e292;function YV(t){if(!t)return t===0?t:0;if(t=KV(t),t===cd||t===-cd){var a=t<0?-1:1;return a*XV}return t===t?t:0}vd.exports=YV});var sd=B((cP,dd)=>{var QV=rd(),ZV=hd(),Eh=gd();function JV(t){return function(a,e,r){return r&&typeof r!="number"&&ZV(a,e,r)&&(e=r=void 0),a=Eh(a),e===void 0?(e=a,a=0):e=Eh(e),r=r===void 0?a{var tR=sd(),aR=tR();ud.exports=aR});var pd=B((gP,fd)=>{var eR=j2(),rR=function(){return eR.Date.now()};fd.exports=rR});var Gl=B((dP,md)=>{var nR=de(),Th=pd(),zd=Pl(),iR="Expected a function",lR=Math.max,oR=Math.min;function hR(t,a,e){var r,n,i,l,o,h,c=0,v=!1,g=!1,s=!0;if(typeof t!="function")throw new TypeError(iR);a=zd(a)||0,nR(e)&&(v=!!e.leading,g="maxWait"in e,i=g?lR(zd(e.maxWait)||0,a):i,s="trailing"in e?!!e.trailing:s);function d(y){var w=r,V=n;return r=n=void 0,c=y,l=t.apply(V,w),l}function p(y){return c=y,o=setTimeout(u,a),v?d(y):l}function z(y){var w=y-h,V=y-c,R=a-w;return g?oR(R,i-V):R}function L(y){var w=y-h,V=y-c;return h===void 0||w>=a||w<0||g&&V>=i}function u(){var y=Th();if(L(y))return f(y);o=setTimeout(u,z(y))}function f(y){return o=void 0,s&&r?d(y):(r=n=void 0,l)}function m(){o!==void 0&&clearTimeout(o),c=0,r=h=n=o=void 0}function M(){return o===void 0?l:f(Th())}function x(){var y=Th(),w=L(y);if(r=arguments,n=this,h=y,w){if(o===void 0)return p(h);if(g)return clearTimeout(o),o=setTimeout(u,a),d(h)}return o===void 0&&(o=setTimeout(u,a)),l}return x.cancel=m,x.flush=M,x}md.exports=hR});var Hd=B((sP,Md)=>{var cR=Object.prototype,vR=cR.hasOwnProperty;function gR(t,a){return t!=null&&vR.call(t,a)}Md.exports=gR});var Kl=B((uP,xd)=>{var dR=q2(),sR=Cn(),uR=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,fR=/^\w*$/;function pR(t,a){if(dR(t))return!1;var e=typeof t;return e=="number"||e=="symbol"||e=="boolean"||t==null||sR(t)?!0:fR.test(t)||!uR.test(t)||a!=null&&t in Object(a)}xd.exports=pR});var Vd=B((fP,Ld)=>{var wd=Dl(),zR="Expected a function";function Ph(t,a){if(typeof t!="function"||a!=null&&typeof a!="function")throw new TypeError(zR);var e=function(){var r=arguments,n=a?a.apply(this,r):r[0],i=e.cache;if(i.has(n))return i.get(n);var l=t.apply(this,r);return e.cache=i.set(n,l)||i,l};return e.cache=new(Ph.Cache||wd),e}Ph.Cache=wd;Ld.exports=Ph});var yd=B((pP,Rd)=>{var mR=Vd(),MR=500;function HR(t){var a=mR(t,function(r){return e.size===MR&&e.clear(),r}),e=a.cache;return a}Rd.exports=HR});var Bd=B((zP,Cd)=>{var xR=yd(),wR=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,LR=/\\(\\)?/g,VR=xR(function(t){var a=[];return t.charCodeAt(0)===46&&a.push(""),t.replace(wR,function(e,r,n,i){a.push(n?i.replace(LR,"$1"):r||e)}),a});Cd.exports=VR});var Ad=B((mP,Sd)=>{function RR(t,a){for(var e=-1,r=t==null?0:t.length,n=Array(r);++e{var Fd=X4(),yR=Ad(),CR=q2(),BR=Cn(),SR=1/0,kd=Fd?Fd.prototype:void 0,bd=kd?kd.toString:void 0;function Ed(t){if(typeof t=="string")return t;if(CR(t))return yR(t,Ed)+"";if(BR(t))return bd?bd.call(t):"";var a=t+"";return a=="0"&&1/t==-SR?"-0":a}_d.exports=Ed});var Id=B((HP,Pd)=>{var AR=Td();function FR(t){return t==null?"":AR(t)}Pd.exports=FR});var Ih=B((xP,Od)=>{var kR=q2(),bR=Kl(),ER=Bd(),_R=Id();function TR(t,a){return kR(t)?t:bR(t,a)?[t]:ER(_R(t))}Od.exports=TR});var kn=B((wP,Dd)=>{var PR=Cn(),IR=1/0;function OR(t){if(typeof t=="string"||PR(t))return t;var a=t+"";return a=="0"&&1/t==-IR?"-0":a}Dd.exports=OR});var Oh=B((LP,Nd)=>{var DR=Ih(),NR=Ul(),$R=q2(),UR=ql(),WR=Wl(),jR=kn();function qR(t,a,e){a=DR(a,t);for(var r=-1,n=a.length,i=!1;++r{var GR=Hd(),KR=Oh();function XR(t,a){return t!=null&&KR(t,a,GR)}$d.exports=XR});var jd=B((RP,Wd)=>{var YR=Gl(),QR=de(),ZR="Expected a function";function JR(t,a,e){var r=!0,n=!0;if(typeof t!="function")throw new TypeError(ZR);return QR(e)&&(r="leading"in e?!!e.leading:r,n="trailing"in e?!!e.trailing:n),YR(t,a,{leading:r,maxWait:a,trailing:n})}Wd.exports=JR});var Xd=B((CP,Kd)=>{var ry=se(),ny=function(){try{var t=ry(Object,"defineProperty");return t({},"",{}),t}catch{}}();Kd.exports=ny});var Zd=B((BP,Qd)=>{var Yd=Xd();function iy(t,a,e){a=="__proto__"&&Yd?Yd(t,a,{configurable:!0,enumerable:!0,value:e,writable:!0}):t[a]=e}Qd.exports=iy});var ts=B((SP,Jd)=>{function ly(t,a,e,r){for(var n=-1,i=t==null?0:t.length;++n{function oy(t){return function(a,e,r){for(var n=-1,i=Object(a),l=r(a),o=l.length;o--;){var h=l[t?o:++n];if(e(i[h],h,i)===!1)break}return a}}as.exports=oy});var ns=B((FP,rs)=>{var hy=es(),cy=hy();rs.exports=cy});var ls=B((kP,is)=>{function vy(t,a){for(var e=-1,r=Array(t);++e{function gy(){return!1}os.exports=gy});var Nh=B((En,nr)=>{var dy=j2(),sy=hs(),gs=typeof En=="object"&&En&&!En.nodeType&&En,cs=gs&&typeof nr=="object"&&nr&&!nr.nodeType&&nr,uy=cs&&cs.exports===gs,vs=uy?dy.Buffer:void 0,fy=vs?vs.isBuffer:void 0,py=fy||sy;nr.exports=py});var ss=B((EP,ds)=>{var zy=Y4(),my=Wl(),My=Q4(),Hy="[object Arguments]",xy="[object Array]",wy="[object Boolean]",Ly="[object Date]",Vy="[object Error]",Ry="[object Function]",yy="[object Map]",Cy="[object Number]",By="[object Object]",Sy="[object RegExp]",Ay="[object Set]",Fy="[object String]",ky="[object WeakMap]",by="[object ArrayBuffer]",Ey="[object DataView]",_y="[object Float32Array]",Ty="[object Float64Array]",Py="[object Int8Array]",Iy="[object Int16Array]",Oy="[object Int32Array]",Dy="[object Uint8Array]",Ny="[object Uint8ClampedArray]",$y="[object Uint16Array]",Uy="[object Uint32Array]",$t={};$t[_y]=$t[Ty]=$t[Py]=$t[Iy]=$t[Oy]=$t[Dy]=$t[Ny]=$t[$y]=$t[Uy]=!0;$t[Hy]=$t[xy]=$t[by]=$t[wy]=$t[Ey]=$t[Ly]=$t[Vy]=$t[Ry]=$t[yy]=$t[Cy]=$t[By]=$t[Sy]=$t[Ay]=$t[Fy]=$t[ky]=!1;function Wy(t){return My(t)&&my(t.length)&&!!$t[zy(t)]}ds.exports=Wy});var fs=B((_P,us)=>{function jy(t){return function(a){return t(a)}}us.exports=jy});var zs=B((_n,ir)=>{var qy=Vh(),ps=typeof _n=="object"&&_n&&!_n.nodeType&&_n,Tn=ps&&typeof ir=="object"&&ir&&!ir.nodeType&&ir,Gy=Tn&&Tn.exports===ps,$h=Gy&&qy.process,Ky=function(){try{var t=Tn&&Tn.require&&Tn.require("util").types;return t||$h&&$h.binding&&$h.binding("util")}catch{}}();ir.exports=Ky});var Uh=B((TP,Hs)=>{var Xy=ss(),Yy=fs(),ms=zs(),Ms=ms&&ms.isTypedArray,Qy=Ms?Yy(Ms):Xy;Hs.exports=Qy});var ws=B((PP,xs)=>{var Zy=ls(),Jy=Ul(),tC=q2(),aC=Nh(),eC=ql(),rC=Uh(),nC=Object.prototype,iC=nC.hasOwnProperty;function lC(t,a){var e=tC(t),r=!e&&Jy(t),n=!e&&!r&&aC(t),i=!e&&!r&&!n&&rC(t),l=e||r||n||i,o=l?Zy(t.length,String):[],h=o.length;for(var c in t)(a||iC.call(t,c))&&!(l&&(c=="length"||n&&(c=="offset"||c=="parent")||i&&(c=="buffer"||c=="byteLength"||c=="byteOffset")||eC(c,h)))&&o.push(c);return o}xs.exports=lC});var Vs=B((IP,Ls)=>{var oC=Object.prototype;function hC(t){var a=t&&t.constructor,e=typeof a=="function"&&a.prototype||oC;return t===e}Ls.exports=hC});var ys=B((OP,Rs)=>{function cC(t,a){return function(e){return t(a(e))}}Rs.exports=cC});var Bs=B((DP,Cs)=>{var vC=ys(),gC=vC(Object.keys,Object);Cs.exports=gC});var As=B((NP,Ss)=>{var dC=Vs(),sC=Bs(),uC=Object.prototype,fC=uC.hasOwnProperty;function pC(t){if(!dC(t))return sC(t);var a=[];for(var e in Object(t))fC.call(t,e)&&e!="constructor"&&a.push(e);return a}Ss.exports=pC});var Xl=B(($P,Fs)=>{var zC=ws(),mC=As(),MC=jl();function HC(t){return MC(t)?zC(t):mC(t)}Fs.exports=HC});var bs=B((UP,ks)=>{var xC=ns(),wC=Xl();function LC(t,a){return t&&xC(t,a,wC)}ks.exports=LC});var _s=B((WP,Es)=>{var VC=jl();function RC(t,a){return function(e,r){if(e==null)return e;if(!VC(e))return t(e,r);for(var n=e.length,i=a?n:-1,l=Object(e);(a?i--:++i{var yC=bs(),CC=_s(),BC=CC(yC);Ts.exports=BC});var Os=B((qP,Is)=>{var SC=Ps();function AC(t,a,e,r){return SC(t,function(n,i,l){a(r,n,e(n),l)}),r}Is.exports=AC});var Ns=B((GP,Ds)=>{var FC=An();function kC(){this.__data__=new FC,this.size=0}Ds.exports=kC});var Us=B((KP,$s)=>{function bC(t){var a=this.__data__,e=a.delete(t);return this.size=a.size,e}$s.exports=bC});var js=B((XP,Ws)=>{function EC(t){return this.__data__.get(t)}Ws.exports=EC});var Gs=B((YP,qs)=>{function _C(t){return this.__data__.has(t)}qs.exports=_C});var Xs=B((QP,Ks)=>{var TC=An(),PC=Ol(),IC=Dl(),OC=200;function DC(t,a){var e=this.__data__;if(e instanceof TC){var r=e.__data__;if(!PC||r.length{var NC=An(),$C=Ns(),UC=Us(),WC=js(),jC=Gs(),qC=Xs();function lr(t){var a=this.__data__=new NC(t);this.size=a.size}lr.prototype.clear=$C;lr.prototype.delete=UC;lr.prototype.get=WC;lr.prototype.has=jC;lr.prototype.set=qC;Ys.exports=lr});var Zs=B((JP,Qs)=>{function GC(t,a){for(var e=-1,r=t==null?0:t.length;++e{var KC=Sh(),XC=Zs(),YC=Ah(),QC=1,ZC=2;function JC(t,a,e,r,n,i){var l=e&QC,o=t.length,h=a.length;if(o!=h&&!(l&&h>o))return!1;var c=i.get(t),v=i.get(a);if(c&&v)return c==a&&v==t;var g=-1,s=!0,d=e&ZC?new KC:void 0;for(i.set(t,a),i.set(a,t);++g{var tB=j2(),aB=tB.Uint8Array;tu.exports=aB});var ru=B((eI,eu)=>{function eB(t){var a=-1,e=Array(t.size);return t.forEach(function(r,n){e[++a]=[n,r]}),e}eu.exports=eB});var hu=B((rI,ou)=>{var nu=X4(),iu=au(),rB=Il(),nB=jh(),iB=ru(),lB=$l(),oB=1,hB=2,cB="[object Boolean]",vB="[object Date]",gB="[object Error]",dB="[object Map]",sB="[object Number]",uB="[object RegExp]",fB="[object Set]",pB="[object String]",zB="[object Symbol]",mB="[object ArrayBuffer]",MB="[object DataView]",lu=nu?nu.prototype:void 0,qh=lu?lu.valueOf:void 0;function HB(t,a,e,r,n,i,l){switch(e){case MB:if(t.byteLength!=a.byteLength||t.byteOffset!=a.byteOffset)return!1;t=t.buffer,a=a.buffer;case mB:return!(t.byteLength!=a.byteLength||!i(new iu(t),new iu(a)));case cB:case vB:case sB:return rB(+t,+a);case gB:return t.name==a.name&&t.message==a.message;case uB:case pB:return t==a+"";case dB:var o=iB;case fB:var h=r&oB;if(o||(o=lB),t.size!=a.size&&!h)return!1;var c=l.get(t);if(c)return c==a;r|=hB,l.set(t,a);var v=nB(o(t),o(a),r,n,i,l);return l.delete(t),v;case zB:if(qh)return qh.call(t)==qh.call(a)}return!1}ou.exports=HB});var vu=B((nI,cu)=>{var xB=bh(),wB=q2();function LB(t,a,e){var r=a(t);return wB(t)?r:xB(r,e(t))}cu.exports=LB});var du=B((iI,gu)=>{function VB(t,a){for(var e=-1,r=t==null?0:t.length,n=0,i=[];++e{function RB(){return[]}su.exports=RB});var zu=B((oI,pu)=>{var yB=du(),CB=uu(),BB=Object.prototype,SB=BB.propertyIsEnumerable,fu=Object.getOwnPropertySymbols,AB=fu?function(t){return t==null?[]:(t=Object(t),yB(fu(t),function(a){return SB.call(t,a)}))}:CB;pu.exports=AB});var Mu=B((hI,mu)=>{var FB=vu(),kB=zu(),bB=Xl();function EB(t){return FB(t,bB,kB)}mu.exports=EB});var wu=B((cI,xu)=>{var Hu=Mu(),_B=1,TB=Object.prototype,PB=TB.hasOwnProperty;function IB(t,a,e,r,n,i){var l=e&_B,o=Hu(t),h=o.length,c=Hu(a),v=c.length;if(h!=v&&!l)return!1;for(var g=h;g--;){var s=o[g];if(!(l?s in a:PB.call(a,s)))return!1}var d=i.get(t),p=i.get(a);if(d&&p)return d==a&&p==t;var z=!0;i.set(t,a),i.set(a,t);for(var L=l;++g{var OB=se(),DB=j2(),NB=OB(DB,"DataView");Lu.exports=NB});var yu=B((gI,Ru)=>{var $B=se(),UB=j2(),WB=$B(UB,"Promise");Ru.exports=WB});var Bu=B((dI,Cu)=>{var jB=se(),qB=j2(),GB=jB(qB,"WeakMap");Cu.exports=GB});var Tu=B((sI,_u)=>{var Gh=Vu(),Kh=Ol(),Xh=yu(),Yh=Fh(),Qh=Bu(),Eu=Y4(),or=Bh(),Su="[object Map]",KB="[object Object]",Au="[object Promise]",Fu="[object Set]",ku="[object WeakMap]",bu="[object DataView]",XB=or(Gh),YB=or(Kh),QB=or(Xh),ZB=or(Yh),JB=or(Qh),Ke=Eu;(Gh&&Ke(new Gh(new ArrayBuffer(1)))!=bu||Kh&&Ke(new Kh)!=Su||Xh&&Ke(Xh.resolve())!=Au||Yh&&Ke(new Yh)!=Fu||Qh&&Ke(new Qh)!=ku)&&(Ke=function(t){var a=Eu(t),e=a==KB?t.constructor:void 0,r=e?or(e):"";if(r)switch(r){case XB:return bu;case YB:return Su;case QB:return Au;case ZB:return Fu;case JB:return ku}return a});_u.exports=Ke});var Wu=B((uI,Uu)=>{var Zh=Wh(),tS=jh(),aS=hu(),eS=wu(),Pu=Tu(),Iu=q2(),Ou=Nh(),rS=Uh(),nS=1,Du="[object Arguments]",Nu="[object Array]",Yl="[object Object]",iS=Object.prototype,$u=iS.hasOwnProperty;function lS(t,a,e,r,n,i){var l=Iu(t),o=Iu(a),h=l?Nu:Pu(t),c=o?Nu:Pu(a);h=h==Du?Yl:h,c=c==Du?Yl:c;var v=h==Yl,g=c==Yl,s=h==c;if(s&&Ou(t)){if(!Ou(a))return!1;l=!0,v=!1}if(s&&!v)return i||(i=new Zh),l||rS(t)?tS(t,a,e,r,n,i):aS(t,a,h,e,r,n,i);if(!(e&nS)){var d=v&&$u.call(t,"__wrapped__"),p=g&&$u.call(a,"__wrapped__");if(d||p){var z=d?t.value():t,L=p?a.value():a;return i||(i=new Zh),n(z,L,e,r,i)}}return s?(i||(i=new Zh),eS(t,a,e,r,n,i)):!1}Uu.exports=lS});var Jh=B((fI,Gu)=>{var oS=Wu(),ju=Q4();function qu(t,a,e,r,n){return t===a?!0:t==null||a==null||!ju(t)&&!ju(a)?t!==t&&a!==a:oS(t,a,e,r,qu,n)}Gu.exports=qu});var Xu=B((pI,Ku)=>{var hS=Wh(),cS=Jh(),vS=1,gS=2;function dS(t,a,e,r){var n=e.length,i=n,l=!r;if(t==null)return!i;for(t=Object(t);n--;){var o=e[n];if(l&&o[2]?o[1]!==t[o[0]]:!(o[0]in t))return!1}for(;++n{var sS=de();function uS(t){return t===t&&!sS(t)}Yu.exports=uS});var Zu=B((mI,Qu)=>{var fS=t8(),pS=Xl();function zS(t){for(var a=pS(t),e=a.length;e--;){var r=a[e],n=t[r];a[e]=[r,n,fS(n)]}return a}Qu.exports=zS});var a8=B((MI,Ju)=>{function mS(t,a){return function(e){return e==null?!1:e[t]===a&&(a!==void 0||t in Object(e))}}Ju.exports=mS});var af=B((HI,tf)=>{var MS=Xu(),HS=Zu(),xS=a8();function wS(t){var a=HS(t);return a.length==1&&a[0][2]?xS(a[0][0],a[0][1]):function(e){return e===t||MS(e,t,a)}}tf.exports=wS});var e8=B((xI,ef)=>{var LS=Ih(),VS=kn();function RS(t,a){a=LS(a,t);for(var e=0,r=a.length;t!=null&&e{var yS=e8();function CS(t,a,e){var r=t==null?void 0:yS(t,a);return r===void 0?e:r}rf.exports=CS});var of=B((LI,lf)=>{function BS(t,a){return t!=null&&a in Object(t)}lf.exports=BS});var cf=B((VI,hf)=>{var SS=of(),AS=Oh();function FS(t,a){return t!=null&&AS(t,a,SS)}hf.exports=FS});var gf=B((RI,vf)=>{var kS=Jh(),bS=nf(),ES=cf(),_S=Kl(),TS=t8(),PS=a8(),IS=kn(),OS=1,DS=2;function NS(t,a){return _S(t)&&TS(a)?PS(IS(t),a):function(e){var r=bS(e,t);return r===void 0&&r===a?ES(e,t):kS(a,r,OS|DS)}}vf.exports=NS});var sf=B((yI,df)=>{function $S(t){return t}df.exports=$S});var ff=B((CI,uf)=>{function US(t){return function(a){return a?.[t]}}uf.exports=US});var zf=B((BI,pf)=>{var WS=e8();function jS(t){return function(a){return WS(a,t)}}pf.exports=jS});var Mf=B((SI,mf)=>{var qS=ff(),GS=zf(),KS=Kl(),XS=kn();function YS(t){return KS(t)?qS(XS(t)):GS(t)}mf.exports=YS});var xf=B((AI,Hf)=>{var QS=af(),ZS=gf(),JS=sf(),tA=q2(),aA=Mf();function eA(t){return typeof t=="function"?t:t==null?JS:typeof t=="object"?tA(t)?ZS(t[0],t[1]):QS(t):aA(t)}Hf.exports=eA});var Lf=B((FI,wf)=>{var rA=ts(),nA=Os(),iA=xf(),lA=q2();function oA(t,a){return function(e,r){var n=lA(e)?rA:nA,i=a?a():{};return n(e,t,iA(r,2),i)}}wf.exports=oA});var Rf=B((kI,Vf)=>{var hA=Zd(),cA=Lf(),vA=Object.prototype,gA=vA.hasOwnProperty,dA=cA(function(t,a,e){gA.call(t,e)?t[e].push(a):hA(t,e,[a])});Vf.exports=dA});var Cf=B((bI,yf)=>{"use strict";var sA="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED";yf.exports=sA});var Ff=B((EI,Af)=>{"use strict";var uA=Cf();function Bf(){}function Sf(){}Sf.resetWarningCache=Bf;Af.exports=function(){function t(r,n,i,l,o,h){if(h!==uA){var c=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw c.name="Invariant Violation",c}}t.isRequired=t;function a(){return t}var e={array:t,bigint:t,bool:t,func:t,number:t,object:t,string:t,symbol:t,any:t,arrayOf:a,element:t,elementType:t,instanceOf:a,node:t,objectOf:a,oneOf:a,oneOfType:a,shape:a,exact:a,checkPropTypes:Sf,resetWarningCache:Bf};return e.PropTypes=e,e}});var bf=B((PI,kf)=>{kf.exports=Ff()();var _I,TI});var Ef=B(Ql=>{(function(t,a){if(typeof define=="function"&&define.amd)define(["exports","react","prop-types"],a);else if(typeof Ql<"u")a(Ql,T1(),bf());else{var e={exports:{}};a(e.exports,t.react,t.propTypes),t.reactSwipe=e.exports}})(Ql,function(t,a,e){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.setHasSupportToCaptureOption=d;var r=i(a),n=i(e);function i(u){return u&&u.__esModule?u:{default:u}}var l=Object.assign||function(u){for(var f=1;f=0||!Object.prototype.hasOwnProperty.call(u,M)||(m[M]=u[M]);return m}function h(u,f){if(!(u instanceof f))throw new TypeError("Cannot call a class as a function")}var c=function(){function u(f,m){for(var M=0;M0&&arguments[0]!==void 0?arguments[0]:{capture:!0};return s?u:u.capture}function z(u){if("touches"in u){var f=u.touches[0],m=f.pageX,M=f.pageY;return{x:m,y:M}}var x=u.screenX,y=u.screenY;return{x,y}}var L=function(u){g(f,u);function f(){var m;h(this,f);for(var M=arguments.length,x=Array(M),y=0;yx&&this.props.onSwipeRight(1,M),this.movePosition.deltaY<-x?this.props.onSwipeUp(1,M):this.movePosition.deltaY>x&&this.props.onSwipeDown(1,M)),this.moveStart=null,this.moving=!1,this.movePosition=null}},{key:"_setSwiperRef",value:function(M){this.swiper=M,this.props.innerRef(M)}},{key:"render",value:function(){var M=this.props,x=M.tagName,y=M.className,w=M.style,V=M.children,R=M.allowMouseEvents,S=M.onSwipeUp,b=M.onSwipeDown,E=M.onSwipeLeft,C=M.onSwipeRight,T=M.onSwipeStart,I=M.onSwipeMove,J=M.onSwipeEnd,W=M.innerRef,n1=M.tolerance,i1=o(M,["tagName","className","style","children","allowMouseEvents","onSwipeUp","onSwipeDown","onSwipeLeft","onSwipeRight","onSwipeStart","onSwipeMove","onSwipeEnd","innerRef","tolerance"]);return r.default.createElement(this.props.tagName,l({ref:this._setSwiperRef,onMouseDown:this._onMouseDown,onTouchStart:this._handleSwipeStart,onTouchEnd:this._handleSwipeEnd,className:y,style:w},i1),V)}}]),f}(a.Component);L.displayName="ReactSwipe",L.propTypes={tagName:n.default.string,className:n.default.string,style:n.default.object,children:n.default.node,allowMouseEvents:n.default.bool,onSwipeUp:n.default.func,onSwipeDown:n.default.func,onSwipeLeft:n.default.func,onSwipeRight:n.default.func,onSwipeStart:n.default.func,onSwipeMove:n.default.func,onSwipeEnd:n.default.func,innerRef:n.default.func,tolerance:n.default.number.isRequired},L.defaultProps={tagName:"div",allowMouseEvents:!1,onSwipeUp:function(){},onSwipeDown:function(){},onSwipeLeft:function(){},onSwipeRight:function(){},onSwipeStart:function(){},onSwipeMove:function(){},onSwipeEnd:function(){},innerRef:function(){},tolerance:0},t.default=L})});var r8=B(Zl=>{(function(t,a){if(typeof define=="function"&&define.amd)define(["exports","./react-swipe"],a);else if(typeof Zl<"u")a(Zl,Ef());else{var e={exports:{}};a(e.exports,t.reactSwipe),t.index=e.exports}})(Zl,function(t,a){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var e=r(a);function r(n){return n&&n.__esModule?n:{default:n}}t.default=e.default})});var _f=B((DI,Jl)=>{(function(){"use strict";var t={}.hasOwnProperty,a="[native code]";function e(){for(var r=[],n=0;n{"use strict";Object.defineProperty(t5,"__esModule",{value:!0});t5.default=void 0;var ue=fA(_f());function fA(t){return t&&t.__esModule?t:{default:t}}function pA(t,a,e){return a in t?Object.defineProperty(t,a,{value:e,enumerable:!0,configurable:!0,writable:!0}):t[a]=e,t}var zA={ROOT:function(a){return(0,ue.default)(pA({"carousel-root":!0},a||"",!!a))},CAROUSEL:function(a){return(0,ue.default)({carousel:!0,"carousel-slider":a})},WRAPPER:function(a,e){return(0,ue.default)({"thumbs-wrapper":!a,"slider-wrapper":a,"axis-horizontal":e==="horizontal","axis-vertical":e!=="horizontal"})},SLIDER:function(a,e){return(0,ue.default)({thumbs:!a,slider:a,animated:!e})},ITEM:function(a,e,r){return(0,ue.default)({thumb:!a,slide:a,selected:e,previous:r})},ARROW_PREV:function(a){return(0,ue.default)({"control-arrow control-prev":!0,"control-disabled":a})},ARROW_NEXT:function(a){return(0,ue.default)({"control-arrow control-next":!0,"control-disabled":a})},DOT:function(a){return(0,ue.default)({dot:!0,selected:a})}};t5.default=zA});var Tf=B(a5=>{"use strict";Object.defineProperty(a5,"__esModule",{value:!0});a5.outerWidth=void 0;var mA=function(a){var e=a.offsetWidth,r=getComputedStyle(a);return e+=parseInt(r.marginLeft)+parseInt(r.marginRight),e};a5.outerWidth=mA});var r5=B(e5=>{"use strict";Object.defineProperty(e5,"__esModule",{value:!0});e5.default=void 0;var MA=function(a,e,r){var n=a===0?a:a+e,i=r==="horizontal"?[n,0,0]:[0,n,0],l="translate3d",o="("+i.join(",")+")";return l+o};e5.default=MA});var i8=B(n5=>{"use strict";Object.defineProperty(n5,"__esModule",{value:!0});n5.default=void 0;var HA=function(){return window};n5.default=HA});var c8=B(h5=>{"use strict";Object.defineProperty(h5,"__esModule",{value:!0});h5.default=void 0;var G2=LA(T1()),Xe=o5(n8()),xA=Tf(),Pf=o5(r5()),wA=o5(r8()),i5=o5(i8());function o5(t){return t&&t.__esModule?t:{default:t}}function Of(){if(typeof WeakMap!="function")return null;var t=new WeakMap;return Of=function(){return t},t}function LA(t){if(t&&t.__esModule)return t;if(t===null||Pn(t)!=="object"&&typeof t!="function")return{default:t};var a=Of();if(a&&a.has(t))return a.get(t);var e={},r=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var n in t)if(Object.prototype.hasOwnProperty.call(t,n)){var i=r?Object.getOwnPropertyDescriptor(t,n):null;i&&(i.get||i.set)?Object.defineProperty(e,n,i):e[n]=t[n]}return e.default=t,a&&a.set(t,e),e}function Pn(t){return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?Pn=function(e){return typeof e}:Pn=function(e){return e&&typeof Symbol=="function"&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Pn(t)}function l8(){return l8=Object.assign||function(t){for(var a=1;a"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],function(){})),!0}catch{return!1}}function l5(t){return l5=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},l5(t)}function W0(t,a,e){return a in t?Object.defineProperty(t,a,{value:e,enumerable:!0,configurable:!0,writable:!0}):t[a]=e,t}var AA=function(a){return a.hasOwnProperty("key")},h8=function(t){yA(e,t);var a=CA(e);function e(r){var n;return VA(this,e),n=a.call(this,r),W0(Y0(n),"itemsWrapperRef",void 0),W0(Y0(n),"itemsListRef",void 0),W0(Y0(n),"thumbsRef",void 0),W0(Y0(n),"setItemsWrapperRef",function(i){n.itemsWrapperRef=i}),W0(Y0(n),"setItemsListRef",function(i){n.itemsListRef=i}),W0(Y0(n),"setThumbsRef",function(i,l){n.thumbsRef||(n.thumbsRef=[]),n.thumbsRef[l]=i}),W0(Y0(n),"updateSizes",function(){if(!(!n.props.children||!n.itemsWrapperRef||!n.thumbsRef)){var i=G2.Children.count(n.props.children),l=n.itemsWrapperRef.clientWidth,o=n.props.thumbWidth?n.props.thumbWidth:(0,xA.outerWidth)(n.thumbsRef[0]),h=Math.floor(l/o),c=h0&&(l=0),c===g&&l<0&&(l=0);var s=n.itemsWrapperRef.clientWidth,d=c+100/(s/l);return n.itemsListRef&&["WebkitTransform","MozTransform","MsTransform","OTransform","transform","msTransform"].forEach(function(p){n.itemsListRef.style[p]=(0,Pf.default)(d,"%",n.props.axis)}),!0}),W0(Y0(n),"slideRight",function(i){n.moveTo(n.state.firstItem-(typeof i=="number"?i:1))}),W0(Y0(n),"slideLeft",function(i){n.moveTo(n.state.firstItem+(typeof i=="number"?i:1))}),W0(Y0(n),"moveTo",function(i){i=i<0?0:i,i=i>=n.state.lastPosition?n.state.lastPosition:i,n.setState({firstItem:i})}),n.state={selectedItem:r.selectedItem,swiping:!1,showArrows:!1,firstItem:0,visibleItems:0,lastPosition:0},n}return RA(e,[{key:"componentDidMount",value:function(){this.setupThumbs()}},{key:"componentDidUpdate",value:function(n){this.props.selectedItem!==this.state.selectedItem&&this.setState({selectedItem:this.props.selectedItem,firstItem:this.getFirstItem(this.props.selectedItem)}),this.props.children!==n.children&&this.updateSizes()}},{key:"componentWillUnmount",value:function(){this.destroyThumbs()}},{key:"setupThumbs",value:function(){(0,i5.default)().addEventListener("resize",this.updateSizes),(0,i5.default)().addEventListener("DOMContentLoaded",this.updateSizes),this.updateSizes()}},{key:"destroyThumbs",value:function(){(0,i5.default)().removeEventListener("resize",this.updateSizes),(0,i5.default)().removeEventListener("DOMContentLoaded",this.updateSizes)}},{key:"getFirstItem",value:function(n){var i=n;return n>=this.state.lastPosition&&(i=this.state.lastPosition),n1,l=this.state.showArrows&&this.state.firstItem>0,o=this.state.showArrows&&this.state.firstItem{"use strict";Object.defineProperty(c5,"__esModule",{value:!0});c5.default=void 0;var FA=function(){return document};c5.default=FA});var v8=B(F2=>{"use strict";Object.defineProperty(F2,"__esModule",{value:!0});F2.setPosition=F2.getPosition=F2.isKeyboardEvent=F2.defaultStatusFormatter=F2.noop=void 0;var kA=T1(),bA=EA(r5());function EA(t){return t&&t.__esModule?t:{default:t}}var _A=function(){};F2.noop=_A;var TA=function(a,e){return"".concat(a," of ").concat(e)};F2.defaultStatusFormatter=TA;var PA=function(a){return a?a.hasOwnProperty("key"):!1};F2.isKeyboardEvent=PA;var IA=function(a,e){if(e.infiniteLoop&&++a,a===0)return 0;var r=kA.Children.count(e.children);if(e.centerMode&&e.axis==="horizontal"){var n=-a*e.centerSlidePercentage,i=r-1;return a&&(a!==i||e.infiniteLoop)?n+=(100-e.centerSlidePercentage)/2:a===i&&(n+=100-e.centerSlidePercentage),n}return-a*100};F2.getPosition=IA;var OA=function(a,e){var r={};return["WebkitTransform","MozTransform","MsTransform","OTransform","transform","msTransform"].forEach(function(n){r[n]=(0,bA.default)(a,"%",e)}),r};F2.setPosition=OA});var Uf=B(sa=>{"use strict";Object.defineProperty(sa,"__esModule",{value:!0});sa.fadeAnimationHandler=sa.slideStopSwipingHandler=sa.slideSwipeAnimationHandler=sa.slideAnimationHandler=void 0;var $f=T1(),DA=NA(r5()),da=v8();function NA(t){return t&&t.__esModule?t:{default:t}}function Nf(t,a){var e=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);a&&(r=r.filter(function(n){return Object.getOwnPropertyDescriptor(t,n).enumerable})),e.push.apply(e,r)}return e}function Ye(t){for(var a=1;al);if(o)return i<0?a.centerMode&&a.centerSlidePercentage&&a.axis==="horizontal"?r.itemListStyle=(0,da.setPosition)(-(l+2)*a.centerSlidePercentage-(100-a.centerSlidePercentage)/2,a.axis):r.itemListStyle=(0,da.setPosition)(-(l+2)*100,a.axis):i>l&&(r.itemListStyle=(0,da.setPosition)(0,a.axis)),r;var h=(0,da.getPosition)(n,a),c=(0,DA.default)(h,"%",a.axis),v=a.transitionTime+"ms";return r.itemListStyle={WebkitTransform:c,msTransform:c,OTransform:c,transform:c},e.swiping||(r.itemListStyle=Ye(Ye({},r.itemListStyle),{},{WebkitTransitionDuration:v,MozTransitionDuration:v,OTransitionDuration:v,transitionDuration:v,msTransitionDuration:v})),r};sa.slideAnimationHandler=UA;var WA=function(a,e,r,n){var i={},l=e.axis==="horizontal",o=$f.Children.count(e.children),h=0,c=(0,da.getPosition)(r.selectedItem,e),v=e.infiniteLoop?(0,da.getPosition)(o-1,e)-100:(0,da.getPosition)(o-1,e),g=l?a.x:a.y,s=g;c===h&&g>0&&(s=0),c===v&&g<0&&(s=0);var d=c+100/(r.itemSize/s),p=Math.abs(g)>e.swipeScrollTolerance;return e.infiniteLoop&&p&&(r.selectedItem===0&&d>-100?d-=o*100:r.selectedItem===o-1&&d<-o*100&&(d+=o*100)),(!e.preventMovementUntilSwipeScrollTolerance||p||r.swipeMovementStarted)&&(r.swipeMovementStarted||n({swipeMovementStarted:!0}),i.itemListStyle=(0,da.setPosition)(d,e.axis)),p&&!r.cancelClick&&n({cancelClick:!0}),i};sa.slideSwipeAnimationHandler=WA;var jA=function(a,e){var r=(0,da.getPosition)(e.selectedItem,a),n=(0,da.setPosition)(r,a.axis);return{itemListStyle:n}};sa.slideStopSwipingHandler=jA;var qA=function(a,e){var r=a.transitionTime+"ms",n="ease-in-out",i={position:"absolute",display:"block",zIndex:-2,minHeight:"100%",opacity:0,top:0,right:0,left:0,bottom:0,transitionTimingFunction:n,msTransitionTimingFunction:n,MozTransitionTimingFunction:n,WebkitTransitionTimingFunction:n,OTransitionTimingFunction:n};return e.swiping||(i=Ye(Ye({},i),{},{WebkitTransitionDuration:r,MozTransitionDuration:r,OTransitionDuration:r,transitionDuration:r,msTransitionDuration:r})),{slideStyle:i,selectedStyle:Ye(Ye({},i),{},{opacity:1,position:"relative"}),prevStyle:Ye({},i)}};sa.fadeAnimationHandler=qA});var Gf=B(u5=>{"use strict";Object.defineProperty(u5,"__esModule",{value:!0});u5.default=void 0;var Rt=XA(T1()),GA=Dn(r8()),ba=Dn(n8()),KA=Dn(c8()),v5=Dn(Df()),g5=Dn(i8()),In=v8(),d5=Uf();function Dn(t){return t&&t.__esModule?t:{default:t}}function qf(){if(typeof WeakMap!="function")return null;var t=new WeakMap;return qf=function(){return t},t}function XA(t){if(t&&t.__esModule)return t;if(t===null||On(t)!=="object"&&typeof t!="function")return{default:t};var a=qf();if(a&&a.has(t))return a.get(t);var e={},r=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var n in t)if(Object.prototype.hasOwnProperty.call(t,n)){var i=r?Object.getOwnPropertyDescriptor(t,n):null;i&&(i.get||i.set)?Object.defineProperty(e,n,i):e[n]=t[n]}return e.default=t,a&&a.set(t,e),e}function On(t){return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?On=function(e){return typeof e}:On=function(e){return e&&typeof Symbol=="function"&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},On(t)}function g8(){return g8=Object.assign||function(t){for(var a=1;a"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],function(){})),!0}catch{return!1}}function s5(t){return s5=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},s5(t)}function rt(t,a,e){return a in t?Object.defineProperty(t,a,{value:e,enumerable:!0,configurable:!0,writable:!0}):t[a]=e,t}var s8=function(t){ZA(e,t);var a=JA(e);function e(r){var n;YA(this,e),n=a.call(this,r),rt(nt(n),"thumbsRef",void 0),rt(nt(n),"carouselWrapperRef",void 0),rt(nt(n),"listRef",void 0),rt(nt(n),"itemsRef",void 0),rt(nt(n),"timer",void 0),rt(nt(n),"animationHandler",void 0),rt(nt(n),"setThumbsRef",function(l){n.thumbsRef=l}),rt(nt(n),"setCarouselWrapperRef",function(l){n.carouselWrapperRef=l}),rt(nt(n),"setListRef",function(l){n.listRef=l}),rt(nt(n),"setItemsRef",function(l,o){n.itemsRef||(n.itemsRef=[]),n.itemsRef[o]=l}),rt(nt(n),"autoPlay",function(){Rt.Children.count(n.props.children)<=1||(n.clearAutoPlay(),n.props.autoPlay&&(n.timer=setTimeout(function(){n.increment()},n.props.interval)))}),rt(nt(n),"clearAutoPlay",function(){n.timer&&clearTimeout(n.timer)}),rt(nt(n),"resetAutoPlay",function(){n.clearAutoPlay(),n.autoPlay()}),rt(nt(n),"stopOnHover",function(){n.setState({isMouseEntered:!0},n.clearAutoPlay)}),rt(nt(n),"startOnLeave",function(){n.setState({isMouseEntered:!1},n.autoPlay)}),rt(nt(n),"isFocusWithinTheCarousel",function(){return n.carouselWrapperRef?!!((0,v5.default)().activeElement===n.carouselWrapperRef||n.carouselWrapperRef.contains((0,v5.default)().activeElement)):!1}),rt(nt(n),"navigateWithKeyboard",function(l){if(!!n.isFocusWithinTheCarousel()){var o=n.props.axis,h=o==="horizontal",c={ArrowUp:38,ArrowRight:39,ArrowDown:40,ArrowLeft:37},v=h?c.ArrowRight:c.ArrowDown,g=h?c.ArrowLeft:c.ArrowUp;v===l.keyCode?n.increment():g===l.keyCode&&n.decrement()}}),rt(nt(n),"updateSizes",function(){if(!(!n.state.initialized||!n.itemsRef||n.itemsRef.length===0)){var l=n.props.axis==="horizontal",o=n.itemsRef[0];if(!!o){var h=l?o.clientWidth:o.clientHeight;n.setState({itemSize:h}),n.thumbsRef&&n.thumbsRef.updateSizes()}}}),rt(nt(n),"setMountState",function(){n.setState({hasMount:!0}),n.updateSizes()}),rt(nt(n),"handleClickItem",function(l,o){if(Rt.Children.count(n.props.children)!==0){if(n.state.cancelClick){n.setState({cancelClick:!1});return}n.props.onClickItem(l,o),l!==n.state.selectedItem&&n.setState({selectedItem:l})}}),rt(nt(n),"handleOnChange",function(l,o){Rt.Children.count(n.props.children)<=1||n.props.onChange(l,o)}),rt(nt(n),"handleClickThumb",function(l,o){n.props.onClickThumb(l,o),n.moveTo(l)}),rt(nt(n),"onSwipeStart",function(l){n.setState({swiping:!0}),n.props.onSwipeStart(l)}),rt(nt(n),"onSwipeEnd",function(l){n.setState({swiping:!1,cancelClick:!1,swipeMovementStarted:!1}),n.props.onSwipeEnd(l),n.clearAutoPlay(),n.state.autoPlay&&n.autoPlay()}),rt(nt(n),"onSwipeMove",function(l,o){n.props.onSwipeMove(o);var h=n.props.swipeAnimationHandler(l,n.props,n.state,n.setState.bind(nt(n)));return n.setState(K2({},h)),!!Object.keys(h).length}),rt(nt(n),"decrement",function(){var l=arguments.length>0&&arguments[0]!==void 0?arguments[0]:1;n.moveTo(n.state.selectedItem-(typeof l=="number"?l:1))}),rt(nt(n),"increment",function(){var l=arguments.length>0&&arguments[0]!==void 0?arguments[0]:1;n.moveTo(n.state.selectedItem+(typeof l=="number"?l:1))}),rt(nt(n),"moveTo",function(l){if(typeof l=="number"){var o=Rt.Children.count(n.props.children)-1;l<0&&(l=n.props.infiniteLoop?o:0),l>o&&(l=n.props.infiniteLoop?0:o),n.selectItem({selectedItem:l}),n.state.autoPlay&&n.state.isMouseEntered===!1&&n.resetAutoPlay()}}),rt(nt(n),"onClickNext",function(){n.increment(1)}),rt(nt(n),"onClickPrev",function(){n.decrement(1)}),rt(nt(n),"onSwipeForward",function(){n.increment(1),n.props.emulateTouch&&n.setState({cancelClick:!0})}),rt(nt(n),"onSwipeBackwards",function(){n.decrement(1),n.props.emulateTouch&&n.setState({cancelClick:!0})}),rt(nt(n),"changeItem",function(l){return function(o){(!(0,In.isKeyboardEvent)(o)||o.key==="Enter")&&n.moveTo(l)}}),rt(nt(n),"selectItem",function(l){n.setState(K2({previousItem:n.state.selectedItem},l),function(){n.setState(n.animationHandler(n.props,n.state))}),n.handleOnChange(l.selectedItem,Rt.Children.toArray(n.props.children)[l.selectedItem])}),rt(nt(n),"getInitialImage",function(){var l=n.props.selectedItem,o=n.itemsRef&&n.itemsRef[l],h=o&&o.getElementsByTagName("img")||[];return h[0]}),rt(nt(n),"getVariableItemHeight",function(l){var o=n.itemsRef&&n.itemsRef[l];if(n.state.hasMount&&o&&o.children.length){var h=o.children[0].getElementsByTagName("img")||[];if(h.length>0){var c=h[0];if(!c.complete){var v=function d(){n.forceUpdate(),c.removeEventListener("load",d)};c.addEventListener("load",v)}}var g=h[0]||o.children[0],s=g.clientHeight;return s>0?s:null}return null});var i={initialized:!1,previousItem:r.selectedItem,selectedItem:r.selectedItem,hasMount:!1,isMouseEntered:!1,autoPlay:r.autoPlay,swiping:!1,swipeMovementStarted:!1,cancelClick:!1,itemSize:1,itemListStyle:{},slideStyle:{},selectedStyle:{},prevStyle:{}};return n.animationHandler=typeof r.animationHandler=="function"&&r.animationHandler||r.animationHandler==="fade"&&d5.fadeAnimationHandler||d5.slideAnimationHandler,n.state=K2(K2({},i),n.animationHandler(r,i)),n}return QA(e,[{key:"componentDidMount",value:function(){!this.props.children||this.setupCarousel()}},{key:"componentDidUpdate",value:function(n,i){!n.children&&this.props.children&&!this.state.initialized&&this.setupCarousel(),!n.autoFocus&&this.props.autoFocus&&this.forceFocus(),i.swiping&&!this.state.swiping&&this.setState(K2({},this.props.stopSwipingHandler(this.props,this.state))),(n.selectedItem!==this.props.selectedItem||n.centerMode!==this.props.centerMode)&&(this.updateSizes(),this.moveTo(this.props.selectedItem)),n.autoPlay!==this.props.autoPlay&&(this.props.autoPlay?this.setupAutoPlay():this.destroyAutoPlay(),this.setState({autoPlay:this.props.autoPlay}))}},{key:"componentWillUnmount",value:function(){this.destroyCarousel()}},{key:"setupCarousel",value:function(){var n=this;this.bindEvents(),this.state.autoPlay&&Rt.Children.count(this.props.children)>1&&this.setupAutoPlay(),this.props.autoFocus&&this.forceFocus(),this.setState({initialized:!0},function(){var i=n.getInitialImage();i&&!i.complete?i.addEventListener("load",n.setMountState):n.setMountState()})}},{key:"destroyCarousel",value:function(){this.state.initialized&&(this.unbindEvents(),this.destroyAutoPlay())}},{key:"setupAutoPlay",value:function(){this.autoPlay();var n=this.carouselWrapperRef;this.props.stopOnHover&&n&&(n.addEventListener("mouseenter",this.stopOnHover),n.addEventListener("mouseleave",this.startOnLeave))}},{key:"destroyAutoPlay",value:function(){this.clearAutoPlay();var n=this.carouselWrapperRef;this.props.stopOnHover&&n&&(n.removeEventListener("mouseenter",this.stopOnHover),n.removeEventListener("mouseleave",this.startOnLeave))}},{key:"bindEvents",value:function(){(0,g5.default)().addEventListener("resize",this.updateSizes),(0,g5.default)().addEventListener("DOMContentLoaded",this.updateSizes),this.props.useKeyboardArrows&&(0,v5.default)().addEventListener("keydown",this.navigateWithKeyboard)}},{key:"unbindEvents",value:function(){(0,g5.default)().removeEventListener("resize",this.updateSizes),(0,g5.default)().removeEventListener("DOMContentLoaded",this.updateSizes);var n=this.getInitialImage();n&&n.removeEventListener("load",this.setMountState),this.props.useKeyboardArrows&&(0,v5.default)().removeEventListener("keydown",this.navigateWithKeyboard)}},{key:"forceFocus",value:function(){var n;(n=this.carouselWrapperRef)===null||n===void 0||n.focus()}},{key:"renderItems",value:function(n){var i=this;return this.props.children?Rt.Children.map(this.props.children,function(l,o){var h=o===i.state.selectedItem,c=o===i.state.previousItem,v=h&&i.state.selectedStyle||c&&i.state.prevStyle||i.state.slideStyle||{};i.props.centerMode&&i.props.axis==="horizontal"&&(v=K2(K2({},v),{},{minWidth:i.props.centerSlidePercentage+"%"})),i.state.swiping&&i.state.swipeMovementStarted&&(v=K2(K2({},v),{},{pointerEvents:"none"}));var g={ref:function(d){return i.setItemsRef(d,o)},key:"itemKey"+o+(n?"clone":""),className:ba.default.ITEM(!0,o===i.state.selectedItem,o===i.state.previousItem),onClick:i.handleClickItem.bind(i,o,l),style:v};return Rt.default.createElement("li",g,i.props.renderItem(l,{isSelected:o===i.state.selectedItem,isPrevious:o===i.state.previousItem}))}):[]}},{key:"renderControls",value:function(){var n=this,i=this.props,l=i.showIndicators,o=i.labels,h=i.renderIndicator,c=i.children;return l?Rt.default.createElement("ul",{className:"control-dots"},Rt.Children.map(c,function(v,g){return h&&h(n.changeItem(g),g===n.state.selectedItem,g,o.item)})):null}},{key:"renderStatus",value:function(){return this.props.showStatus?Rt.default.createElement("p",{className:"carousel-status"},this.props.statusFormatter(this.state.selectedItem+1,Rt.Children.count(this.props.children))):null}},{key:"renderThumbs",value:function(){return!this.props.showThumbs||!this.props.children||Rt.Children.count(this.props.children)===0?null:Rt.default.createElement(KA.default,{ref:this.setThumbsRef,onSelectItem:this.handleClickThumb,selectedItem:this.state.selectedItem,transitionTime:this.props.transitionTime,thumbWidth:this.props.thumbWidth,labels:this.props.labels,emulateTouch:this.props.emulateTouch},this.props.renderThumbs(this.props.children))}},{key:"render",value:function(){var n=this;if(!this.props.children||Rt.Children.count(this.props.children)===0)return null;var i=this.props.swipeable&&Rt.Children.count(this.props.children)>1,l=this.props.axis==="horizontal",o=this.props.showArrows&&Rt.Children.count(this.props.children)>1,h=o&&(this.state.selectedItem>0||this.props.infiniteLoop)||!1,c=o&&(this.state.selectedItem{"use strict"});var Yf=B(Nn=>{"use strict";Object.defineProperty(Nn,"__esModule",{value:!0});Object.defineProperty(Nn,"Carousel",{enumerable:!0,get:function(){return eF.default}});Object.defineProperty(Nn,"CarouselProps",{enumerable:!0,get:function(){return rF.CarouselProps}});Object.defineProperty(Nn,"Thumbs",{enumerable:!0,get:function(){return nF.default}});var eF=Xf(Gf()),rF=Kf(),nF=Xf(c8());function Xf(t){return t&&t.__esModule?t:{default:t}}});function gp(t,a){var e={};for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&a.indexOf(r)<0&&(e[r]=t[r]);if(t!=null&&typeof Object.getOwnPropertySymbols=="function")for(var n=0,r=Object.getOwnPropertySymbols(t);n=o?n=n+lp("0",l-o):n=(n.substring(0,l)||"0")+"."+n.substring(l),e+n}function op(t,a,e){if(["","-"].indexOf(t)!==-1)return t;var r=(t.indexOf(".")!==-1||e)&&a,n=u8(t),i=n.beforeDecimal,l=n.afterDecimal,o=n.hasNegation,h=parseFloat("0."+(l||"0")),c=l.length<=a?"0."+l:h.toFixed(a),v=c.split("."),g=i.split("").reverse().reduce(function(z,L,u){return z.length>u?(Number(z[0])+Number(L)).toString()+z.substring(1,z.length):L+z},v[0]),s=up(v[1]||"",a,e),d=o?"-":"",p=r?".":"";return""+d+g+p+s}function cr(t,a){if(t.value=t.value,t!==null){if(t.createTextRange){var e=t.createTextRange();return e.move("character",a),e.select(),!0}return t.selectionStart||t.selectionStart===0?(t.focus(),t.setSelectionRange(a,a),!0):(t.focus(),!1)}}function yF(t,a){for(var e=0,r=0,n=t.length,i=a.length;t[e]===a[e]&&ee&&n-r>e;)r++;return{from:{start:e,end:n-r},to:{start:e,end:i-r}}}function CF(t,a,e){return Math.min(Math.max(t,a),e)}function hp(t){return Math.max(t.selectionStart,t.selectionEnd)}function BF(){return typeof navigator<"u"&&!(navigator.platform&&/iPhone|iPod/.test(navigator.platform))}function SF(t){return{from:{start:0,end:0},to:{start:0,end:t.length},lastValue:""}}function AF(t,a,e,r,n,i){var l=n.findIndex(function(f){return f}),o=t.slice(0,l);!a&&!e.startsWith(o)&&(e=o+e,r=r+o.length);for(var h=e.length,c=t.length,v={},g=new Array(h),s=0;s0&&g[z]===-1;)z--;var u=z===-1||g[z]===-1?0:g[z]+1;return u>L?L:r-u=0&&!e[a];)a--;a===-1&&(a=e.indexOf(!0))}else{for(;a<=n&&!e[a];)a++;a>n&&(a=e.lastIndexOf(!0))}return a===-1&&(a=n),a}function FF(t){for(var a=Array.from({length:t.length+1}).map(function(){return!0}),e=0,r=a.length;et.length-i.length&&(f=v),t=t.substring(0,f),t=_F(L?"-"+t:t,r),t=(t.match(TF(d,!0))||[]).join("");var M=t.indexOf(d);t=t.replace(new RegExp(sp(d),"g"),function(R,S){return S===M?".":""});var x=u8(t,r),y=x.beforeDecimal,w=x.afterDecimal,V=x.addNegation;return h.end-h.start<\/script>",t=t.removeChild(t.firstChild)):typeof r.is=="string"?t=l.createElement(e,{is:r.is}):(t=l.createElement(e),e==="select"&&(l=t,r.multiple?l.multiple=!0:r.size&&(l.size=r.size))):t=l.createElementNS(t,e),t[sa]=a,t[sn]=r,Lc(t,a,!1,!1),a.stateNode=t;t:{switch(l=n3(e,r),e){case"dialog":Dt("cancel",t),Dt("close",t),n=r;break;case"iframe":case"object":case"embed":Dt("load",t),n=r;break;case"video":case"audio":for(n=0;nq4&&(a.flags|=128,r=!0,Dr(i,!1),a.lanes=4194304)}else{if(!r)if(t=Ml(l),t!==null){if(a.flags|=128,r=!0,e=t.updateQueue,e!==null&&(a.updateQueue=e,a.flags|=4),Dr(i,!0),i.tail===null&&i.tailMode==="hidden"&&!l.alternate&&!Wt)return D0(a),null}else 2*l0()-i.renderingStartTime>q4&&e!==1073741824&&(a.flags|=128,r=!0,Dr(i,!1),a.lanes=4194304);i.isBackwards?(l.sibling=a.child,a.child=l):(e=i.last,e!==null?e.sibling=l:a.child=l,i.last=l)}return i.tail!==null?(a=i.tail,i.rendering=a,i.tail=a.sibling,i.renderingStartTime=l0(),a.sibling=null,e=Xt.current,Pt(Xt,r?e&1|2:e&1),a):(D0(a),null);case 22:case 23:return wh(),r=a.memoizedState!==null,t!==null&&t.memoizedState!==null!==r&&(a.flags|=8192),r&&(a.mode&1)!==0?(p2&1073741824)!==0&&(D0(a),a.subtreeFlags&6&&(a.flags|=8192)):D0(a),null;case 24:return null;case 25:return null}throw Error(Q(156,a.tag))}function ZH(t,a){switch(eh(a),a.tag){case 1:return r2(a.type)&&dl(),t=a.flags,t&65536?(a.flags=t&-65537|128,a):null;case 3:return W4(),Nt(e2),Nt($0),gh(),t=a.flags,(t&65536)!==0&&(t&128)===0?(a.flags=t&-65537|128,a):null;case 5:return vh(a),null;case 13:if(Nt(Xt),t=a.memoizedState,t!==null&&t.dehydrated!==null){if(a.alternate===null)throw Error(Q(340));$4()}return t=a.flags,t&65536?(a.flags=t&-65537|128,a):null;case 19:return Nt(Xt),null;case 4:return W4(),null;case 10:return lh(a.type._context),null;case 22:case 23:return wh(),null;case 24:return null;default:return null}}var ji=!1,N0=!1,JH=typeof WeakSet=="function"?WeakSet:Set,V1=null;function k4(t,a){var e=t.ref;if(e!==null)if(typeof e=="function")try{e(null)}catch(r){e0(t,a,r)}else e.current=null}function F3(t,a,e){try{e()}catch(r){e0(t,a,r)}}var b7=!1;function tx(t,a){if(u3=hl,t=S9(),th(t)){if("selectionStart"in t)var e={start:t.selectionStart,end:t.selectionEnd};else t:{e=(e=t.ownerDocument)&&e.defaultView||window;var r=e.getSelection&&e.getSelection();if(r&&r.rangeCount!==0){e=r.anchorNode;var n=r.anchorOffset,i=r.focusNode;r=r.focusOffset;try{e.nodeType,i.nodeType}catch{e=null;break t}var l=0,o=-1,h=-1,c=0,v=0,g=t,d=null;a:for(;;){for(var u;g!==e||n!==0&&g.nodeType!==3||(o=l+n),g!==i||r!==0&&g.nodeType!==3||(h=l+r),g.nodeType===3&&(l+=g.nodeValue.length),(u=g.firstChild)!==null;)d=g,g=u;for(;;){if(g===t)break a;if(d===e&&++c===n&&(o=l),d===i&&++v===r&&(h=l),(u=g.nextSibling)!==null)break;g=d,d=g.parentNode}g=u}e=o===-1||h===-1?null:{start:o,end:h}}else e=null}e=e||{start:0,end:0}}else e=null;for(f3={focusedElem:t,selectionRange:e},hl=!1,V1=a;V1!==null;)if(a=V1,t=a.child,(a.subtreeFlags&1028)!==0&&t!==null)t.return=a,V1=t;else for(;V1!==null;){a=V1;try{var p=a.alternate;if((a.flags&1024)!==0)switch(a.tag){case 0:case 11:case 15:break;case 1:if(p!==null){var z=p.memoizedProps,w=p.memoizedState,s=a.stateNode,f=s.getSnapshotBeforeUpdate(a.elementType===a.type?z:W2(a.type,z),w);s.__reactInternalSnapshotBeforeUpdate=f}break;case 3:var m=a.stateNode.containerInfo;m.nodeType===1?m.textContent="":m.nodeType===9&&m.documentElement&&m.removeChild(m.documentElement);break;case 5:case 6:case 4:case 17:break;default:throw Error(Q(163))}}catch(H){e0(a,a.return,H)}if(t=a.sibling,t!==null){t.return=a.return,V1=t;break}V1=a.return}return p=b7,b7=!1,p}function Jr(t,a,e){var r=a.updateQueue;if(r=r!==null?r.lastEffect:null,r!==null){var n=r=r.next;do{if((n.tag&t)===t){var i=n.destroy;n.destroy=void 0,i!==void 0&&F3(a,e,i)}n=n.next}while(n!==r)}}function _l(t,a){if(a=a.updateQueue,a=a!==null?a.lastEffect:null,a!==null){var e=a=a.next;do{if((e.tag&t)===t){var r=e.create;e.destroy=r()}e=e.next}while(e!==a)}}function k3(t){var a=t.ref;if(a!==null){var e=t.stateNode;switch(t.tag){case 5:t=e;break;default:t=e}typeof a=="function"?a(t):a.current=t}}function yc(t){var a=t.alternate;a!==null&&(t.alternate=null,yc(a)),t.child=null,t.deletions=null,t.sibling=null,t.tag===5&&(a=t.stateNode,a!==null&&(delete a[sa],delete a[sn],delete a[m3],delete a[TH],delete a[PH])),t.stateNode=null,t.return=null,t.dependencies=null,t.memoizedProps=null,t.memoizedState=null,t.pendingProps=null,t.stateNode=null,t.updateQueue=null}function Cc(t){return t.tag===5||t.tag===3||t.tag===4}function E7(t){t:for(;;){for(;t.sibling===null;){if(t.return===null||Cc(t.return))return null;t=t.return}for(t.sibling.return=t.return,t=t.sibling;t.tag!==5&&t.tag!==6&&t.tag!==18;){if(t.flags&2||t.child===null||t.tag===4)continue t;t.child.return=t,t=t.child}if(!(t.flags&2))return t.stateNode}}function b3(t,a,e){var r=t.tag;if(r===5||r===6)t=t.stateNode,a?e.nodeType===8?e.parentNode.insertBefore(t,a):e.insertBefore(t,a):(e.nodeType===8?(a=e.parentNode,a.insertBefore(t,e)):(a=e,a.appendChild(t)),e=e._reactRootContainer,e!=null||a.onclick!==null||(a.onclick=gl));else if(r!==4&&(t=t.child,t!==null))for(b3(t,a,e),t=t.sibling;t!==null;)b3(t,a,e),t=t.sibling}function E3(t,a,e){var r=t.tag;if(r===5||r===6)t=t.stateNode,a?e.insertBefore(t,a):e.appendChild(t);else if(r!==4&&(t=t.child,t!==null))for(E3(t,a,e),t=t.sibling;t!==null;)E3(t,a,e),t=t.sibling}var b0=null,j2=!1;function Xa(t,a,e){for(e=e.child;e!==null;)Bc(t,a,e),e=e.sibling}function Bc(t,a,e){if(ua&&typeof ua.onCommitFiberUnmount=="function")try{ua.onCommitFiberUnmount(Cl,e)}catch{}switch(e.tag){case 5:N0||k4(e,a);case 6:var r=b0,n=j2;b0=null,Xa(t,a,e),b0=r,j2=n,b0!==null&&(j2?(t=b0,e=e.stateNode,t.nodeType===8?t.parentNode.removeChild(e):t.removeChild(e)):b0.removeChild(e.stateNode));break;case 18:b0!==null&&(j2?(t=b0,e=e.stateNode,t.nodeType===8?Po(t.parentNode,e):t.nodeType===1&&Po(t,e),hn(t)):Po(b0,e.stateNode));break;case 4:r=b0,n=j2,b0=e.stateNode.containerInfo,j2=!0,Xa(t,a,e),b0=r,j2=n;break;case 0:case 11:case 14:case 15:if(!N0&&(r=e.updateQueue,r!==null&&(r=r.lastEffect,r!==null))){n=r=r.next;do{var i=n,l=i.destroy;i=i.tag,l!==void 0&&((i&2)!==0||(i&4)!==0)&&F3(e,a,l),n=n.next}while(n!==r)}Xa(t,a,e);break;case 1:if(!N0&&(k4(e,a),r=e.stateNode,typeof r.componentWillUnmount=="function"))try{r.props=e.memoizedProps,r.state=e.memoizedState,r.componentWillUnmount()}catch(o){e0(e,a,o)}Xa(t,a,e);break;case 21:Xa(t,a,e);break;case 22:e.mode&1?(N0=(r=N0)||e.memoizedState!==null,Xa(t,a,e),N0=r):Xa(t,a,e);break;default:Xa(t,a,e)}}function _7(t){var a=t.updateQueue;if(a!==null){t.updateQueue=null;var e=t.stateNode;e===null&&(e=t.stateNode=new JH),a.forEach(function(r){var n=cx.bind(null,t,r);e.has(r)||(e.add(r),r.then(n,n))})}}function U2(t,a){var e=a.deletions;if(e!==null)for(var r=0;rn&&(n=l),r&=~i}if(r=n,r=l0()-r,r=(120>r?120:480>r?480:1080>r?1080:1920>r?1920:3e3>r?3e3:4320>r?4320:1960*ex(r/1960))-r,10t?16:t,ae===null)var r=!1;else{if(t=ae,ae=null,Vl=0,(pt&6)!==0)throw Error(Q(331));var n=pt;for(pt|=4,V1=t.current;V1!==null;){var i=V1,l=i.child;if((V1.flags&16)!==0){var o=i.deletions;if(o!==null){for(var h=0;hl0()-Hh?We(t,0):Mh|=e),n2(t,a)}function Tc(t,a){a===0&&((t.mode&1)===0?a=1:(a=ki,ki<<=1,(ki&130023424)===0&&(ki=4194304)));var e=X0();t=Ta(t,a),t!==null&&(Hn(t,a,e),n2(t,e))}function hx(t){var a=t.memoizedState,e=0;a!==null&&(e=a.retryLane),Tc(t,e)}function cx(t,a){var e=0;switch(t.tag){case 13:var r=t.stateNode,n=t.memoizedState;n!==null&&(e=n.retryLane);break;case 19:r=t.stateNode;break;default:throw Error(Q(314))}r!==null&&r.delete(a),Tc(t,e)}var Pc;Pc=function(t,a,e){if(t!==null)if(t.memoizedProps!==a.pendingProps||e2.current)a2=!0;else{if((t.lanes&e)===0&&(a.flags&128)===0)return a2=!1,YH(t,a,e);a2=(t.flags&131072)!==0}else a2=!1,Wt&&(a.flags&1048576)!==0&&D9(a,fl,a.index);switch(a.lanes=0,a.tag){case 2:var r=a.type;Ji(t,a),t=a.pendingProps;var n=N4(a,$0.current);I4(a,e),n=sh(null,a,r,t,n,e);var i=uh();return a.flags|=1,typeof n=="object"&&n!==null&&typeof n.render=="function"&&n.$$typeof===void 0?(a.tag=1,a.memoizedState=null,a.updateQueue=null,r2(r)?(i=!0,sl(a)):i=!1,a.memoizedState=n.state!==null&&n.state!==void 0?n.state:null,hh(a),n.updater=bl,a.stateNode=n,n._reactInternals=a,V3(a,r,t,e),a=C3(null,a,r,!0,i,e)):(a.tag=0,Wt&&i&&ah(a),K0(null,a,n,e),a=a.child),a;case 16:r=a.elementType;t:{switch(Ji(t,a),t=a.pendingProps,n=r._init,r=n(r._payload),a.type=r,n=a.tag=gx(r),t=W2(r,t),n){case 0:a=y3(null,a,r,t,e);break t;case 1:a=A7(null,a,r,t,e);break t;case 11:a=B7(null,a,r,t,e);break t;case 14:a=S7(null,a,r,W2(r.type,t),e);break t}throw Error(Q(306,r,""))}return a;case 0:return r=a.type,n=a.pendingProps,n=a.elementType===r?n:W2(r,n),y3(t,a,r,n,e);case 1:return r=a.type,n=a.pendingProps,n=a.elementType===r?n:W2(r,n),A7(t,a,r,n,e);case 3:t:{if(Hc(a),t===null)throw Error(Q(387));r=a.pendingProps,i=a.memoizedState,n=i.element,W9(t,a),ml(a,r,null,e);var l=a.memoizedState;if(r=l.element,i.isDehydrated)if(i={element:r,isDehydrated:!1,cache:l.cache,pendingSuspenseBoundaries:l.pendingSuspenseBoundaries,transitions:l.transitions},a.updateQueue.baseState=i,a.memoizedState=i,a.flags&256){n=j4(Error(Q(423)),a),a=F7(t,a,r,e,n);break t}else if(r!==n){n=j4(Error(Q(424)),a),a=F7(t,a,r,e,n);break t}else for(z2=ie(a.stateNode.containerInfo.firstChild),m2=a,Wt=!0,q2=null,e=K9(a,null,r,e),a.child=e;e;)e.flags=e.flags&-3|4096,e=e.sibling;else{if($4(),r===n){a=Pa(t,a,e);break t}K0(t,a,r,e)}a=a.child}return a;case 5:return X9(a),t===null&&x3(a),r=a.type,n=a.pendingProps,i=t!==null?t.memoizedProps:null,l=n.children,p3(r,n)?l=null:i!==null&&p3(r,i)&&(a.flags|=32),Mc(t,a),K0(t,a,l,e),a.child;case 6:return t===null&&x3(a),null;case 13:return xc(t,a,e);case 4:return ch(a,a.stateNode.containerInfo),r=a.pendingProps,t===null?a.child=U4(a,null,r,e):K0(t,a,r,e),a.child;case 11:return r=a.type,n=a.pendingProps,n=a.elementType===r?n:W2(r,n),B7(t,a,r,n,e);case 7:return K0(t,a,a.pendingProps,e),a.child;case 8:return K0(t,a,a.pendingProps.children,e),a.child;case 12:return K0(t,a,a.pendingProps.children,e),a.child;case 10:t:{if(r=a.type._context,n=a.pendingProps,i=a.memoizedProps,l=n.value,Pt(pl,r._currentValue),r._currentValue=l,i!==null)if(X2(i.value,l)){if(i.children===n.children&&!e2.current){a=Pa(t,a,e);break t}}else for(i=a.child,i!==null&&(i.return=a);i!==null;){var o=i.dependencies;if(o!==null){l=i.child;for(var h=o.firstContext;h!==null;){if(h.context===r){if(i.tag===1){h=ba(-1,e&-e),h.tag=2;var c=i.updateQueue;if(c!==null){c=c.shared;var v=c.pending;v===null?h.next=h:(h.next=v.next,v.next=h),c.pending=h}}i.lanes|=e,h=i.alternate,h!==null&&(h.lanes|=e),w3(i.return,e,a),o.lanes|=e;break}h=h.next}}else if(i.tag===10)l=i.type===a.type?null:i.child;else if(i.tag===18){if(l=i.return,l===null)throw Error(Q(341));l.lanes|=e,o=l.alternate,o!==null&&(o.lanes|=e),w3(l,e,a),l=i.sibling}else l=i.child;if(l!==null)l.return=i;else for(l=i;l!==null;){if(l===a){l=null;break}if(i=l.sibling,i!==null){i.return=l.return,l=i;break}l=l.return}i=l}K0(t,a,n.children,e),a=a.child}return a;case 9:return n=a.type,r=a.pendingProps.children,I4(a,e),n=_2(n),r=r(n),a.flags|=1,K0(t,a,r,e),a.child;case 14:return r=a.type,n=W2(r,a.pendingProps),n=W2(r.type,n),S7(t,a,r,n,e);case 15:return zc(t,a,a.type,a.pendingProps,e);case 17:return r=a.type,n=a.pendingProps,n=a.elementType===r?n:W2(r,n),Ji(t,a),a.tag=1,r2(r)?(t=!0,sl(a)):t=!1,I4(a,e),q9(a,r,n),V3(a,r,n,e),C3(null,a,r,!0,t,e);case 19:return wc(t,a,e);case 22:return mc(t,a,e)}throw Error(Q(156,a.tag))};function Ic(t,a){return v9(t,a)}function vx(t,a,e,r){this.tag=t,this.key=e,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.ref=null,this.pendingProps=a,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=r,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function b2(t,a,e,r){return new vx(t,a,e,r)}function Vh(t){return t=t.prototype,!(!t||!t.isReactComponent)}function gx(t){if(typeof t=="function")return Vh(t)?1:0;if(t!=null){if(t=t.$$typeof,t===U3)return 11;if(t===W3)return 14}return 2}function ce(t,a){var e=t.alternate;return e===null?(e=b2(t.tag,a,t.key,t.mode),e.elementType=t.elementType,e.type=t.type,e.stateNode=t.stateNode,e.alternate=t,t.alternate=e):(e.pendingProps=a,e.type=t.type,e.flags=0,e.subtreeFlags=0,e.deletions=null),e.flags=t.flags&14680064,e.childLanes=t.childLanes,e.lanes=t.lanes,e.child=t.child,e.memoizedProps=t.memoizedProps,e.memoizedState=t.memoizedState,e.updateQueue=t.updateQueue,a=t.dependencies,e.dependencies=a===null?null:{lanes:a.lanes,firstContext:a.firstContext},e.sibling=t.sibling,e.index=t.index,e.ref=t.ref,e}function el(t,a,e,r,n,i){var l=2;if(r=t,typeof t=="function")Vh(t)&&(l=1);else if(typeof t=="string")l=5;else t:switch(t){case L4:return je(e.children,n,i,a);case $3:l=8,n|=8;break;case Ko:return t=b2(12,e,a,n|2),t.elementType=Ko,t.lanes=i,t;case Xo:return t=b2(13,e,a,n),t.elementType=Xo,t.lanes=i,t;case Yo:return t=b2(19,e,a,n),t.elementType=Yo,t.lanes=i,t;case G7:return Pl(e,n,i,a);default:if(typeof t=="object"&&t!==null)switch(t.$$typeof){case j7:l=10;break t;case q7:l=9;break t;case U3:l=11;break t;case W3:l=14;break t;case Ya:l=16,r=null;break t}throw Error(Q(130,t==null?t:typeof t,""))}return a=b2(l,e,a,n),a.elementType=t,a.type=r,a.lanes=i,a}function je(t,a,e,r){return t=b2(7,t,r,a),t.lanes=e,t}function Pl(t,a,e,r){return t=b2(22,t,r,a),t.elementType=G7,t.lanes=e,t.stateNode={isHidden:!1},t}function jo(t,a,e){return t=b2(6,t,null,a),t.lanes=e,t}function qo(t,a,e){return a=b2(4,t.children!==null?t.children:[],t.key,a),a.lanes=e,a.stateNode={containerInfo:t.containerInfo,pendingChildren:null,implementation:t.implementation},a}function dx(t,a,e,r,n){this.tag=a,this.containerInfo=t,this.finishedWork=this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.pendingContext=this.context=null,this.callbackPriority=0,this.eventTimes=So(0),this.expirationTimes=So(-1),this.entangledLanes=this.finishedLanes=this.mutableReadLanes=this.expiredLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=So(0),this.identifierPrefix=r,this.onRecoverableError=n,this.mutableSourceEagerHydrationData=null}function Rh(t,a,e,r,n,i,l,o,h){return t=new dx(t,a,e,o,h),a===1?(a=1,i===!0&&(a|=8)):a=0,i=b2(3,null,null,a),t.current=i,i.stateNode=t,i.memoizedState={element:r,isDehydrated:e,cache:null,transitions:null,pendingSuspenseBoundaries:null},hh(i),t}function sx(t,a,e){var r=3{"use strict";function Uc(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(Uc)}catch(t){console.error(t)}}Uc(),Wc.exports=$c()});var qc=B(Sh=>{"use strict";var jc=$l();Sh.createRoot=jc.createRoot,Sh.hydrateRoot=jc.hydrateRoot;var rT});function mx(t){var a={};return function(e){return a[e]===void 0&&(a[e]=t(e)),a[e]}}function yx(t,a,e){let r=Kc(a,e);return typeof t=="string"&&t.indexOf("-")===-1&&!Vx(t[0])&&Object.keys(r).forEach(n=>{wx(n)||delete r[n]}),r}function Bx(t){return a=>{if(Array.isArray(a))throw new Error('Using the "styled" tag in runtime is not supported. Make sure you have set up the Babel plugin correctly. See https://github.com/callstack/linaria#setup');let e=(n,i)=>{let{as:l=t,class:o}=n,h=yx(l,n,["as","class"]);h.ref=i,h.className=a.atomic?Gc(a.class,h.className||o):Gc(h.className||o,a.class);let{vars:c}=a;if(c){let v={};for(let u in c){let p=c[u],z=p[0],w=p[1]||"",s=typeof z=="function"?z(n):z;Cx(s,a.name),v[`--${u}`]=`${s}${w}`}let g=h.style||{},d=Object.keys(g);d.length>0&&d.forEach(u=>{v[u]=g[u]}),h.style=v}return t.__linaria&&t!==l?(h.as=l,Vn.default.createElement(t,h)):Vn.default.createElement(l,h)},r=Vn.default.forwardRef?Vn.default.forwardRef(e):n=>{let i=Kc(n,["innerRef"]);return e(i,n.innerRef)};return r.displayName=a.name,r.__linaria={className:a.class,extends:t},r}}var Vn,Mx,Hx,xx,wx,Lx,Gc,Vx,Rx,Kc,Cx,L0,Ah=co(()=>{Vn=F1(U1(),1);Mx=mx,Hx=/^((children|dangerouslySetInnerHTML|key|ref|autoFocus|defaultValue|defaultChecked|innerHTML|suppressContentEditableWarning|suppressHydrationWarning|valueLink|accept|acceptCharset|accessKey|action|allow|allowUserMedia|allowPaymentRequest|allowFullScreen|allowTransparency|alt|async|autoComplete|autoPlay|capture|cellPadding|cellSpacing|challenge|charSet|checked|cite|classID|className|cols|colSpan|content|contentEditable|contextMenu|controls|controlsList|coords|crossOrigin|data|dateTime|decoding|default|defer|dir|disabled|disablePictureInPicture|download|draggable|encType|form|formAction|formEncType|formMethod|formNoValidate|formTarget|frameBorder|headers|height|hidden|high|href|hrefLang|htmlFor|httpEquiv|id|inputMode|integrity|is|keyParams|keyType|kind|label|lang|list|loading|loop|low|marginHeight|marginWidth|max|maxLength|media|mediaGroup|method|min|minLength|multiple|muted|name|nonce|noValidate|open|optimum|pattern|placeholder|playsInline|poster|preload|profile|radioGroup|readOnly|referrerPolicy|rel|required|reversed|role|rows|rowSpan|sandbox|scope|scoped|scrolling|seamless|selected|shape|size|sizes|slot|span|spellCheck|src|srcDoc|srcLang|srcSet|start|step|style|summary|tabIndex|target|title|type|useMap|value|width|wmode|wrap|about|datatype|inlist|prefix|property|resource|typeof|vocab|autoCapitalize|autoCorrect|autoSave|color|inert|itemProp|itemScope|itemType|itemID|itemRef|on|results|security|unselectable|accentHeight|accumulate|additive|alignmentBaseline|allowReorder|alphabetic|amplitude|arabicForm|ascent|attributeName|attributeType|autoReverse|azimuth|baseFrequency|baselineShift|baseProfile|bbox|begin|bias|by|calcMode|capHeight|clip|clipPathUnits|clipPath|clipRule|colorInterpolation|colorInterpolationFilters|colorProfile|colorRendering|contentScriptType|contentStyleType|cursor|cx|cy|d|decelerate|descent|diffuseConstant|direction|display|divisor|dominantBaseline|dur|dx|dy|edgeMode|elevation|enableBackground|end|exponent|externalResourcesRequired|fill|fillOpacity|fillRule|filter|filterRes|filterUnits|floodColor|floodOpacity|focusable|fontFamily|fontSize|fontSizeAdjust|fontStretch|fontStyle|fontVariant|fontWeight|format|from|fr|fx|fy|g1|g2|glyphName|glyphOrientationHorizontal|glyphOrientationVertical|glyphRef|gradientTransform|gradientUnits|hanging|horizAdvX|horizOriginX|ideographic|imageRendering|in|in2|intercept|k|k1|k2|k3|k4|kernelMatrix|kernelUnitLength|kerning|keyPoints|keySplines|keyTimes|lengthAdjust|letterSpacing|lightingColor|limitingConeAngle|local|markerEnd|markerMid|markerStart|markerHeight|markerUnits|markerWidth|mask|maskContentUnits|maskUnits|mathematical|mode|numOctaves|offset|opacity|operator|order|orient|orientation|origin|overflow|overlinePosition|overlineThickness|panose1|paintOrder|pathLength|patternContentUnits|patternTransform|patternUnits|pointerEvents|points|pointsAtX|pointsAtY|pointsAtZ|preserveAlpha|preserveAspectRatio|primitiveUnits|r|radius|refX|refY|renderingIntent|repeatCount|repeatDur|requiredExtensions|requiredFeatures|restart|result|rotate|rx|ry|scale|seed|shapeRendering|slope|spacing|specularConstant|specularExponent|speed|spreadMethod|startOffset|stdDeviation|stemh|stemv|stitchTiles|stopColor|stopOpacity|strikethroughPosition|strikethroughThickness|string|stroke|strokeDasharray|strokeDashoffset|strokeLinecap|strokeLinejoin|strokeMiterlimit|strokeOpacity|strokeWidth|surfaceScale|systemLanguage|tableValues|targetX|targetY|textAnchor|textDecoration|textRendering|textLength|to|transform|u1|u2|underlinePosition|underlineThickness|unicode|unicodeBidi|unicodeRange|unitsPerEm|vAlphabetic|vHanging|vIdeographic|vMathematical|values|vectorEffect|version|vertAdvY|vertOriginX|vertOriginY|viewBox|viewTarget|visibility|widths|wordSpacing|writingMode|x|xHeight|x1|x2|xChannelSelector|xlinkActuate|xlinkArcrole|xlinkHref|xlinkRole|xlinkShow|xlinkTitle|xlinkType|xmlBase|xmlns|xmlnsXlink|xmlLang|xmlSpace|y|y1|y2|yChannelSelector|z|zoomAndPan|for|class|autofocus)|(([Dd][Aa][Tt][Aa]|[Aa][Rr][Ii][Aa]|x)-.*))$/,xx=Mx(function(t){return Hx.test(t)||t.charCodeAt(0)===111&&t.charCodeAt(1)===110&&t.charCodeAt(2)<91}),wx=xx,Lx=function(){let a=Array.prototype.slice.call(arguments).filter(Boolean),e={},r=[];a.forEach(i=>{(i?i.split(" "):[]).forEach(o=>{if(o.startsWith("atm_")){let[,h]=o.split("_");e[h]=o}else r.push(o)})});let n=[];for(let i in e)Object.prototype.hasOwnProperty.call(e,i)&&n.push(e[i]);return n.push(...r),n.join(" ")},Gc=Lx,Vx=t=>t.toUpperCase()===t,Rx=t=>a=>t.indexOf(a)===-1,Kc=(t,a)=>{let e={};return Object.keys(t).filter(Rx(a)).forEach(r=>{e[r]=t[r]}),e};Cx=(t,a)=>{{if(typeof t=="string"||typeof t=="number"&&isFinite(t))return;let e=typeof t=="object"?JSON.stringify(t):String(t);console.warn(`An interpolation evaluated to '${e}' in the component '${a}', which is probably a mistake. You should explicitly cast or transform the value to a string.`)}};L0=new Proxy(Bx,{get(t,a){return t(a)}})});var Yc=B((lT,Xc)=>{function Sx(t,a,e){return t===t&&(e!==void 0&&(t=t<=e?t:e),a!==void 0&&(t=t>=a?t:a)),t}Xc.exports=Sx});var Zc=B((oT,Qc)=>{var Ax=/\s/;function Fx(t){for(var a=t.length;a--&&Ax.test(t.charAt(a)););return a}Qc.exports=Fx});var tv=B((hT,Jc)=>{var kx=Zc(),bx=/^\s+/;function Ex(t){return t&&t.slice(0,kx(t)+1).replace(bx,"")}Jc.exports=Ex});var fe=B((cT,av)=>{function _x(t){var a=typeof t;return t!=null&&(a=="object"||a=="function")}av.exports=_x});var Fh=B((vT,ev)=>{var Tx=typeof global=="object"&&global&&global.Object===Object&&global;ev.exports=Tx});var Y2=B((gT,rv)=>{var Px=Fh(),Ix=typeof self=="object"&&self&&self.Object===Object&&self,Ox=Px||Ix||Function("return this")();rv.exports=Ox});var X4=B((dT,nv)=>{var Dx=Y2(),Nx=Dx.Symbol;nv.exports=Nx});var hv=B((sT,ov)=>{var iv=X4(),lv=Object.prototype,$x=lv.hasOwnProperty,Ux=lv.toString,Rn=iv?iv.toStringTag:void 0;function Wx(t){var a=$x.call(t,Rn),e=t[Rn];try{t[Rn]=void 0;var r=!0}catch{}var n=Ux.call(t);return r&&(a?t[Rn]=e:delete t[Rn]),n}ov.exports=Wx});var vv=B((uT,cv)=>{var jx=Object.prototype,qx=jx.toString;function Gx(t){return qx.call(t)}cv.exports=Gx});var Y4=B((fT,sv)=>{var gv=X4(),Kx=hv(),Xx=vv(),Yx="[object Null]",Qx="[object Undefined]",dv=gv?gv.toStringTag:void 0;function Zx(t){return t==null?t===void 0?Qx:Yx:dv&&dv in Object(t)?Kx(t):Xx(t)}sv.exports=Zx});var Q4=B((pT,uv)=>{function Jx(t){return t!=null&&typeof t=="object"}uv.exports=Jx});var yn=B((zT,fv)=>{var tw=Y4(),aw=Q4(),ew="[object Symbol]";function rw(t){return typeof t=="symbol"||aw(t)&&tw(t)==ew}fv.exports=rw});var Ul=B((mT,mv)=>{var nw=tv(),pv=fe(),iw=yn(),zv=0/0,lw=/^[-+]0x[0-9a-f]+$/i,ow=/^0b[01]+$/i,hw=/^0o[0-7]+$/i,cw=parseInt;function vw(t){if(typeof t=="number")return t;if(iw(t))return zv;if(pv(t)){var a=typeof t.valueOf=="function"?t.valueOf():t;t=pv(a)?a+"":a}if(typeof t!="string")return t===0?t:+t;t=nw(t);var e=ow.test(t);return e||hw.test(t)?cw(t.slice(2),e?2:8):lw.test(t)?zv:+t}mv.exports=vw});var Z4=B((MT,Mv)=>{var gw=Yc(),kh=Ul();function dw(t,a,e){return e===void 0&&(e=a,a=void 0),e!==void 0&&(e=kh(e),e=e===e?e:0),a!==void 0&&(a=kh(a),a=a===a?a:0),gw(kh(t),a,e)}Mv.exports=dw});var bh=B((HT,Hv)=>{var sw=Y4(),uw=fe(),fw="[object AsyncFunction]",pw="[object Function]",zw="[object GeneratorFunction]",mw="[object Proxy]";function Mw(t){if(!uw(t))return!1;var a=sw(t);return a==pw||a==zw||a==fw||a==mw}Hv.exports=Mw});var wv=B((xT,xv)=>{var Hw=Y2(),xw=Hw["__core-js_shared__"];xv.exports=xw});var Rv=B((wT,Vv)=>{var Eh=wv(),Lv=function(){var t=/[^.]+$/.exec(Eh&&Eh.keys&&Eh.keys.IE_PROTO||"");return t?"Symbol(src)_1."+t:""}();function ww(t){return!!Lv&&Lv in t}Vv.exports=ww});var _h=B((LT,yv)=>{var Lw=Function.prototype,Vw=Lw.toString;function Rw(t){if(t!=null){try{return Vw.call(t)}catch{}try{return t+""}catch{}}return""}yv.exports=Rw});var Bv=B((VT,Cv)=>{var yw=bh(),Cw=Rv(),Bw=fe(),Sw=_h(),Aw=/[\\^$.*+?()[\]{}|]/g,Fw=/^\[object .+?Constructor\]$/,kw=Function.prototype,bw=Object.prototype,Ew=kw.toString,_w=bw.hasOwnProperty,Tw=RegExp("^"+Ew.call(_w).replace(Aw,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function Pw(t){if(!Bw(t)||Cw(t))return!1;var a=yw(t)?Tw:Fw;return a.test(Sw(t))}Cv.exports=Pw});var Av=B((RT,Sv)=>{function Iw(t,a){return t?.[a]}Sv.exports=Iw});var pe=B((yT,Fv)=>{var Ow=Bv(),Dw=Av();function Nw(t,a){var e=Dw(t,a);return Ow(e)?e:void 0}Fv.exports=Nw});var Cn=B((CT,kv)=>{var $w=pe(),Uw=$w(Object,"create");kv.exports=Uw});var _v=B((BT,Ev)=>{var bv=Cn();function Ww(){this.__data__=bv?bv(null):{},this.size=0}Ev.exports=Ww});var Pv=B((ST,Tv)=>{function jw(t){var a=this.has(t)&&delete this.__data__[t];return this.size-=a?1:0,a}Tv.exports=jw});var Ov=B((AT,Iv)=>{var qw=Cn(),Gw="__lodash_hash_undefined__",Kw=Object.prototype,Xw=Kw.hasOwnProperty;function Yw(t){var a=this.__data__;if(qw){var e=a[t];return e===Gw?void 0:e}return Xw.call(a,t)?a[t]:void 0}Iv.exports=Yw});var Nv=B((FT,Dv)=>{var Qw=Cn(),Zw=Object.prototype,Jw=Zw.hasOwnProperty;function tL(t){var a=this.__data__;return Qw?a[t]!==void 0:Jw.call(a,t)}Dv.exports=tL});var Uv=B((kT,$v)=>{var aL=Cn(),eL="__lodash_hash_undefined__";function rL(t,a){var e=this.__data__;return this.size+=this.has(t)?0:1,e[t]=aL&&a===void 0?eL:a,this}$v.exports=rL});var jv=B((bT,Wv)=>{var nL=_v(),iL=Pv(),lL=Ov(),oL=Nv(),hL=Uv();function J4(t){var a=-1,e=t==null?0:t.length;for(this.clear();++a{function cL(){this.__data__=[],this.size=0}qv.exports=cL});var Wl=B((_T,Kv)=>{function vL(t,a){return t===a||t!==t&&a!==a}Kv.exports=vL});var Bn=B((TT,Xv)=>{var gL=Wl();function dL(t,a){for(var e=t.length;e--;)if(gL(t[e][0],a))return e;return-1}Xv.exports=dL});var Qv=B((PT,Yv)=>{var sL=Bn(),uL=Array.prototype,fL=uL.splice;function pL(t){var a=this.__data__,e=sL(a,t);if(e<0)return!1;var r=a.length-1;return e==r?a.pop():fL.call(a,e,1),--this.size,!0}Yv.exports=pL});var Jv=B((IT,Zv)=>{var zL=Bn();function mL(t){var a=this.__data__,e=zL(a,t);return e<0?void 0:a[e][1]}Zv.exports=mL});var ag=B((OT,tg)=>{var ML=Bn();function HL(t){return ML(this.__data__,t)>-1}tg.exports=HL});var rg=B((DT,eg)=>{var xL=Bn();function wL(t,a){var e=this.__data__,r=xL(e,t);return r<0?(++this.size,e.push([t,a])):e[r][1]=a,this}eg.exports=wL});var Sn=B((NT,ng)=>{var LL=Gv(),VL=Qv(),RL=Jv(),yL=ag(),CL=rg();function tr(t){var a=-1,e=t==null?0:t.length;for(this.clear();++a{var BL=pe(),SL=Y2(),AL=BL(SL,"Map");ig.exports=AL});var hg=B((UT,og)=>{var lg=jv(),FL=Sn(),kL=jl();function bL(){this.size=0,this.__data__={hash:new lg,map:new(kL||FL),string:new lg}}og.exports=bL});var vg=B((WT,cg)=>{function EL(t){var a=typeof t;return a=="string"||a=="number"||a=="symbol"||a=="boolean"?t!=="__proto__":t===null}cg.exports=EL});var An=B((jT,gg)=>{var _L=vg();function TL(t,a){var e=t.__data__;return _L(a)?e[typeof a=="string"?"string":"hash"]:e.map}gg.exports=TL});var sg=B((qT,dg)=>{var PL=An();function IL(t){var a=PL(this,t).delete(t);return this.size-=a?1:0,a}dg.exports=IL});var fg=B((GT,ug)=>{var OL=An();function DL(t){return OL(this,t).get(t)}ug.exports=DL});var zg=B((KT,pg)=>{var NL=An();function $L(t){return NL(this,t).has(t)}pg.exports=$L});var Mg=B((XT,mg)=>{var UL=An();function WL(t,a){var e=UL(this,t),r=e.size;return e.set(t,a),this.size+=e.size==r?0:1,this}mg.exports=WL});var ql=B((YT,Hg)=>{var jL=hg(),qL=sg(),GL=fg(),KL=zg(),XL=Mg();function ar(t){var a=-1,e=t==null?0:t.length;for(this.clear();++a{var YL="__lodash_hash_undefined__";function QL(t){return this.__data__.set(t,YL),this}xg.exports=QL});var Vg=B((ZT,Lg)=>{function ZL(t){return this.__data__.has(t)}Lg.exports=ZL});var Th=B((JT,Rg)=>{var JL=ql(),tV=wg(),aV=Vg();function Gl(t){var a=-1,e=t==null?0:t.length;for(this.__data__=new JL;++a{function eV(t,a,e,r){for(var n=t.length,i=e+(r?1:-1);r?i--:++i{function rV(t){return t!==t}Bg.exports=rV});var Fg=B((eP,Ag)=>{function nV(t,a,e){for(var r=e-1,n=t.length;++r{var iV=Cg(),lV=Sg(),oV=Fg();function hV(t,a,e){return a===a?oV(t,a,e):iV(t,lV,e)}kg.exports=hV});var _g=B((nP,Eg)=>{var cV=bg();function vV(t,a){var e=t==null?0:t.length;return!!e&&cV(t,a,0)>-1}Eg.exports=vV});var Pg=B((iP,Tg)=>{function gV(t,a,e){for(var r=-1,n=t==null?0:t.length;++r{function dV(t,a){return t.has(a)}Ig.exports=dV});var Ih=B((oP,Og)=>{var sV=pe(),uV=Y2(),fV=sV(uV,"Set");Og.exports=fV});var Ng=B((hP,Dg)=>{function pV(){}Dg.exports=pV});var Kl=B((cP,$g)=>{function zV(t){var a=-1,e=Array(t.size);return t.forEach(function(r){e[++a]=r}),e}$g.exports=zV});var Wg=B((vP,Ug)=>{var Oh=Ih(),mV=Ng(),MV=Kl(),HV=1/0,xV=Oh&&1/MV(new Oh([,-0]))[1]==HV?function(t){return new Oh(t)}:mV;Ug.exports=xV});var qg=B((gP,jg)=>{var wV=Th(),LV=_g(),VV=Pg(),RV=Ph(),yV=Wg(),CV=Kl(),BV=200;function SV(t,a,e){var r=-1,n=LV,i=t.length,l=!0,o=[],h=o;if(e)l=!1,n=VV;else if(i>=BV){var c=a?null:yV(t);if(c)return CV(c);l=!1,n=RV,h=new wV}else h=a?[]:o;t:for(;++r{var AV=qg();function FV(t){return t&&t.length?AV(t):[]}Gg.exports=FV});var Dh=B((sP,Xg)=>{function kV(t,a){for(var e=-1,r=a.length,n=t.length;++e{var bV=Y4(),EV=Q4(),_V="[object Arguments]";function TV(t){return EV(t)&&bV(t)==_V}Yg.exports=TV});var Xl=B((fP,td)=>{var Zg=Qg(),PV=Q4(),Jg=Object.prototype,IV=Jg.hasOwnProperty,OV=Jg.propertyIsEnumerable,DV=Zg(function(){return arguments}())?Zg:function(t){return PV(t)&&IV.call(t,"callee")&&!OV.call(t,"callee")};td.exports=DV});var Q2=B((pP,ad)=>{var NV=Array.isArray;ad.exports=NV});var id=B((zP,nd)=>{var ed=X4(),$V=Xl(),UV=Q2(),rd=ed?ed.isConcatSpreadable:void 0;function WV(t){return UV(t)||$V(t)||!!(rd&&t&&t[rd])}nd.exports=WV});var hd=B((mP,od)=>{var jV=Dh(),qV=id();function ld(t,a,e,r,n){var i=-1,l=t.length;for(e||(e=qV),n||(n=[]);++i0&&e(o)?a>1?ld(o,a-1,e,r,n):jV(n,o):r||(n[n.length]=o)}return n}od.exports=ld});var vd=B((MP,cd)=>{var GV=hd();function KV(t){var a=t==null?0:t.length;return a?GV(t,1):[]}cd.exports=KV});var dd=B((HP,gd)=>{var XV=Math.ceil,YV=Math.max;function QV(t,a,e,r){for(var n=-1,i=YV(XV((a-t)/(e||1)),0),l=Array(i);i--;)l[r?i:++n]=t,t+=e;return l}gd.exports=QV});var Yl=B((xP,sd)=>{var ZV=9007199254740991;function JV(t){return typeof t=="number"&&t>-1&&t%1==0&&t<=ZV}sd.exports=JV});var Ql=B((wP,ud)=>{var tR=bh(),aR=Yl();function eR(t){return t!=null&&aR(t.length)&&!tR(t)}ud.exports=eR});var Zl=B((LP,fd)=>{var rR=9007199254740991,nR=/^(?:0|[1-9]\d*)$/;function iR(t,a){var e=typeof t;return a=a??rR,!!a&&(e=="number"||e!="symbol"&&nR.test(t))&&t>-1&&t%1==0&&t{var lR=Wl(),oR=Ql(),hR=Zl(),cR=fe();function vR(t,a,e){if(!cR(e))return!1;var r=typeof a;return(r=="number"?oR(e)&&hR(a,e.length):r=="string"&&a in e)?lR(e[a],t):!1}pd.exports=vR});var Hd=B((RP,Md)=>{var gR=Ul(),md=1/0,dR=17976931348623157e292;function sR(t){if(!t)return t===0?t:0;if(t=gR(t),t===md||t===-md){var a=t<0?-1:1;return a*dR}return t===t?t:0}Md.exports=sR});var wd=B((yP,xd)=>{var uR=dd(),fR=zd(),Nh=Hd();function pR(t){return function(a,e,r){return r&&typeof r!="number"&&fR(a,e,r)&&(e=r=void 0),a=Nh(a),e===void 0?(e=a,a=0):e=Nh(e),r=r===void 0?a{var zR=wd(),mR=zR();Ld.exports=mR});var Rd=B((BP,Vd)=>{var MR=Y2(),HR=function(){return MR.Date.now()};Vd.exports=HR});var Jl=B((SP,Cd)=>{var xR=fe(),Uh=Rd(),yd=Ul(),wR="Expected a function",LR=Math.max,VR=Math.min;function RR(t,a,e){var r,n,i,l,o,h,c=0,v=!1,g=!1,d=!0;if(typeof t!="function")throw new TypeError(wR);a=yd(a)||0,xR(e)&&(v=!!e.leading,g="maxWait"in e,i=g?LR(yd(e.maxWait)||0,a):i,d="trailing"in e?!!e.trailing:d);function u(y){var R=r,L=n;return r=n=void 0,c=y,l=t.apply(L,R),l}function p(y){return c=y,o=setTimeout(s,a),v?u(y):l}function z(y){var R=y-h,L=y-c,V=a-R;return g?VR(V,i-L):V}function w(y){var R=y-h,L=y-c;return h===void 0||R>=a||R<0||g&&L>=i}function s(){var y=Uh();if(w(y))return f(y);o=setTimeout(s,z(y))}function f(y){return o=void 0,d&&r?u(y):(r=n=void 0,l)}function m(){o!==void 0&&clearTimeout(o),c=0,r=h=n=o=void 0}function H(){return o===void 0?l:f(Uh())}function x(){var y=Uh(),R=w(y);if(r=arguments,n=this,h=y,R){if(o===void 0)return p(h);if(g)return clearTimeout(o),o=setTimeout(s,a),u(h)}return o===void 0&&(o=setTimeout(s,a)),l}return x.cancel=m,x.flush=H,x}Cd.exports=RR});var Sd=B((AP,Bd)=>{var yR=Object.prototype,CR=yR.hasOwnProperty;function BR(t,a){return t!=null&&CR.call(t,a)}Bd.exports=BR});var t5=B((FP,Ad)=>{var SR=Q2(),AR=yn(),FR=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,kR=/^\w*$/;function bR(t,a){if(SR(t))return!1;var e=typeof t;return e=="number"||e=="symbol"||e=="boolean"||t==null||AR(t)?!0:kR.test(t)||!FR.test(t)||a!=null&&t in Object(a)}Ad.exports=bR});var bd=B((kP,kd)=>{var Fd=ql(),ER="Expected a function";function Wh(t,a){if(typeof t!="function"||a!=null&&typeof a!="function")throw new TypeError(ER);var e=function(){var r=arguments,n=a?a.apply(this,r):r[0],i=e.cache;if(i.has(n))return i.get(n);var l=t.apply(this,r);return e.cache=i.set(n,l)||i,l};return e.cache=new(Wh.Cache||Fd),e}Wh.Cache=Fd;kd.exports=Wh});var _d=B((bP,Ed)=>{var _R=bd(),TR=500;function PR(t){var a=_R(t,function(r){return e.size===TR&&e.clear(),r}),e=a.cache;return a}Ed.exports=PR});var Pd=B((EP,Td)=>{var IR=_d(),OR=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,DR=/\\(\\)?/g,NR=IR(function(t){var a=[];return t.charCodeAt(0)===46&&a.push(""),t.replace(OR,function(e,r,n,i){a.push(n?i.replace(DR,"$1"):r||e)}),a});Td.exports=NR});var Od=B((_P,Id)=>{function $R(t,a){for(var e=-1,r=t==null?0:t.length,n=Array(r);++e{var Dd=X4(),UR=Od(),WR=Q2(),jR=yn(),qR=1/0,Nd=Dd?Dd.prototype:void 0,$d=Nd?Nd.toString:void 0;function Ud(t){if(typeof t=="string")return t;if(WR(t))return UR(t,Ud)+"";if(jR(t))return $d?$d.call(t):"";var a=t+"";return a=="0"&&1/t==-qR?"-0":a}Wd.exports=Ud});var Gd=B((PP,qd)=>{var GR=jd();function KR(t){return t==null?"":GR(t)}qd.exports=KR});var jh=B((IP,Kd)=>{var XR=Q2(),YR=t5(),QR=Pd(),ZR=Gd();function JR(t,a){return XR(t)?t:YR(t,a)?[t]:QR(ZR(t))}Kd.exports=JR});var Fn=B((OP,Xd)=>{var ty=yn(),ay=1/0;function ey(t){if(typeof t=="string"||ty(t))return t;var a=t+"";return a=="0"&&1/t==-ay?"-0":a}Xd.exports=ey});var qh=B((DP,Yd)=>{var ry=jh(),ny=Xl(),iy=Q2(),ly=Zl(),oy=Yl(),hy=Fn();function cy(t,a,e){a=ry(a,t);for(var r=-1,n=a.length,i=!1;++r{var vy=Sd(),gy=qh();function dy(t,a){return t!=null&&gy(t,a,vy)}Qd.exports=dy});var ts=B(($P,Jd)=>{var sy=Jl(),uy=fe(),fy="Expected a function";function py(t,a,e){var r=!0,n=!0;if(typeof t!="function")throw new TypeError(fy);return uy(e)&&(r="leading"in e?!!e.leading:r,n="trailing"in e?!!e.trailing:n),sy(t,a,{leading:r,maxWait:a,trailing:n})}Jd.exports=py});var ns=B((WP,rs)=>{var Hy=pe(),xy=function(){try{var t=Hy(Object,"defineProperty");return t({},"",{}),t}catch{}}();rs.exports=xy});var os=B((jP,ls)=>{var is=ns();function wy(t,a,e){a=="__proto__"&&is?is(t,a,{configurable:!0,enumerable:!0,value:e,writable:!0}):t[a]=e}ls.exports=wy});var cs=B((qP,hs)=>{function Ly(t,a,e,r){for(var n=-1,i=t==null?0:t.length;++n{function Vy(t){return function(a,e,r){for(var n=-1,i=Object(a),l=r(a),o=l.length;o--;){var h=l[t?o:++n];if(e(i[h],h,i)===!1)break}return a}}vs.exports=Vy});var ss=B((KP,ds)=>{var Ry=gs(),yy=Ry();ds.exports=yy});var fs=B((XP,us)=>{function Cy(t,a){for(var e=-1,r=Array(t);++e{function By(){return!1}ps.exports=By});var Kh=B((bn,nr)=>{var Sy=Y2(),Ay=zs(),Hs=typeof bn=="object"&&bn&&!bn.nodeType&&bn,ms=Hs&&typeof nr=="object"&&nr&&!nr.nodeType&&nr,Fy=ms&&ms.exports===Hs,Ms=Fy?Sy.Buffer:void 0,ky=Ms?Ms.isBuffer:void 0,by=ky||Ay;nr.exports=by});var ws=B((QP,xs)=>{var Ey=Y4(),_y=Yl(),Ty=Q4(),Py="[object Arguments]",Iy="[object Array]",Oy="[object Boolean]",Dy="[object Date]",Ny="[object Error]",$y="[object Function]",Uy="[object Map]",Wy="[object Number]",jy="[object Object]",qy="[object RegExp]",Gy="[object Set]",Ky="[object String]",Xy="[object WeakMap]",Yy="[object ArrayBuffer]",Qy="[object DataView]",Zy="[object Float32Array]",Jy="[object Float64Array]",tC="[object Int8Array]",aC="[object Int16Array]",eC="[object Int32Array]",rC="[object Uint8Array]",nC="[object Uint8ClampedArray]",iC="[object Uint16Array]",lC="[object Uint32Array]",$t={};$t[Zy]=$t[Jy]=$t[tC]=$t[aC]=$t[eC]=$t[rC]=$t[nC]=$t[iC]=$t[lC]=!0;$t[Py]=$t[Iy]=$t[Yy]=$t[Oy]=$t[Qy]=$t[Dy]=$t[Ny]=$t[$y]=$t[Uy]=$t[Wy]=$t[jy]=$t[qy]=$t[Gy]=$t[Ky]=$t[Xy]=!1;function oC(t){return Ty(t)&&_y(t.length)&&!!$t[Ey(t)]}xs.exports=oC});var Vs=B((ZP,Ls)=>{function hC(t){return function(a){return t(a)}}Ls.exports=hC});var ys=B((En,ir)=>{var cC=Fh(),Rs=typeof En=="object"&&En&&!En.nodeType&&En,_n=Rs&&typeof ir=="object"&&ir&&!ir.nodeType&&ir,vC=_n&&_n.exports===Rs,Xh=vC&&cC.process,gC=function(){try{var t=_n&&_n.require&&_n.require("util").types;return t||Xh&&Xh.binding&&Xh.binding("util")}catch{}}();ir.exports=gC});var Yh=B((JP,Ss)=>{var dC=ws(),sC=Vs(),Cs=ys(),Bs=Cs&&Cs.isTypedArray,uC=Bs?sC(Bs):dC;Ss.exports=uC});var Fs=B((tI,As)=>{var fC=fs(),pC=Xl(),zC=Q2(),mC=Kh(),MC=Zl(),HC=Yh(),xC=Object.prototype,wC=xC.hasOwnProperty;function LC(t,a){var e=zC(t),r=!e&&pC(t),n=!e&&!r&&mC(t),i=!e&&!r&&!n&&HC(t),l=e||r||n||i,o=l?fC(t.length,String):[],h=o.length;for(var c in t)(a||wC.call(t,c))&&!(l&&(c=="length"||n&&(c=="offset"||c=="parent")||i&&(c=="buffer"||c=="byteLength"||c=="byteOffset")||MC(c,h)))&&o.push(c);return o}As.exports=LC});var bs=B((aI,ks)=>{var VC=Object.prototype;function RC(t){var a=t&&t.constructor,e=typeof a=="function"&&a.prototype||VC;return t===e}ks.exports=RC});var _s=B((eI,Es)=>{function yC(t,a){return function(e){return t(a(e))}}Es.exports=yC});var Ps=B((rI,Ts)=>{var CC=_s(),BC=CC(Object.keys,Object);Ts.exports=BC});var Os=B((nI,Is)=>{var SC=bs(),AC=Ps(),FC=Object.prototype,kC=FC.hasOwnProperty;function bC(t){if(!SC(t))return AC(t);var a=[];for(var e in Object(t))kC.call(t,e)&&e!="constructor"&&a.push(e);return a}Is.exports=bC});var a5=B((iI,Ds)=>{var EC=Fs(),_C=Os(),TC=Ql();function PC(t){return TC(t)?EC(t):_C(t)}Ds.exports=PC});var $s=B((lI,Ns)=>{var IC=ss(),OC=a5();function DC(t,a){return t&&IC(t,a,OC)}Ns.exports=DC});var Ws=B((oI,Us)=>{var NC=Ql();function $C(t,a){return function(e,r){if(e==null)return e;if(!NC(e))return t(e,r);for(var n=e.length,i=a?n:-1,l=Object(e);(a?i--:++i{var UC=$s(),WC=Ws(),jC=WC(UC);js.exports=jC});var Ks=B((cI,Gs)=>{var qC=qs();function GC(t,a,e,r){return qC(t,function(n,i,l){a(r,n,e(n),l)}),r}Gs.exports=GC});var Ys=B((vI,Xs)=>{var KC=Sn();function XC(){this.__data__=new KC,this.size=0}Xs.exports=XC});var Zs=B((gI,Qs)=>{function YC(t){var a=this.__data__,e=a.delete(t);return this.size=a.size,e}Qs.exports=YC});var tu=B((dI,Js)=>{function QC(t){return this.__data__.get(t)}Js.exports=QC});var eu=B((sI,au)=>{function ZC(t){return this.__data__.has(t)}au.exports=ZC});var nu=B((uI,ru)=>{var JC=Sn(),tB=jl(),aB=ql(),eB=200;function rB(t,a){var e=this.__data__;if(e instanceof JC){var r=e.__data__;if(!tB||r.length{var nB=Sn(),iB=Ys(),lB=Zs(),oB=tu(),hB=eu(),cB=nu();function lr(t){var a=this.__data__=new nB(t);this.size=a.size}lr.prototype.clear=iB;lr.prototype.delete=lB;lr.prototype.get=oB;lr.prototype.has=hB;lr.prototype.set=cB;iu.exports=lr});var ou=B((pI,lu)=>{function vB(t,a){for(var e=-1,r=t==null?0:t.length;++e{var gB=Th(),dB=ou(),sB=Ph(),uB=1,fB=2;function pB(t,a,e,r,n,i){var l=e&uB,o=t.length,h=a.length;if(o!=h&&!(l&&h>o))return!1;var c=i.get(t),v=i.get(a);if(c&&v)return c==a&&v==t;var g=-1,d=!0,u=e&fB?new gB:void 0;for(i.set(t,a),i.set(a,t);++g{var zB=Y2(),mB=zB.Uint8Array;cu.exports=mB});var du=B((MI,gu)=>{function MB(t){var a=-1,e=Array(t.size);return t.forEach(function(r,n){e[++a]=[n,r]}),e}gu.exports=MB});var zu=B((HI,pu)=>{var su=X4(),uu=vu(),HB=Wl(),xB=Zh(),wB=du(),LB=Kl(),VB=1,RB=2,yB="[object Boolean]",CB="[object Date]",BB="[object Error]",SB="[object Map]",AB="[object Number]",FB="[object RegExp]",kB="[object Set]",bB="[object String]",EB="[object Symbol]",_B="[object ArrayBuffer]",TB="[object DataView]",fu=su?su.prototype:void 0,Jh=fu?fu.valueOf:void 0;function PB(t,a,e,r,n,i,l){switch(e){case TB:if(t.byteLength!=a.byteLength||t.byteOffset!=a.byteOffset)return!1;t=t.buffer,a=a.buffer;case _B:return!(t.byteLength!=a.byteLength||!i(new uu(t),new uu(a)));case yB:case CB:case AB:return HB(+t,+a);case BB:return t.name==a.name&&t.message==a.message;case FB:case bB:return t==a+"";case SB:var o=wB;case kB:var h=r&VB;if(o||(o=LB),t.size!=a.size&&!h)return!1;var c=l.get(t);if(c)return c==a;r|=RB,l.set(t,a);var v=xB(o(t),o(a),r,n,i,l);return l.delete(t),v;case EB:if(Jh)return Jh.call(t)==Jh.call(a)}return!1}pu.exports=PB});var Mu=B((xI,mu)=>{var IB=Dh(),OB=Q2();function DB(t,a,e){var r=a(t);return OB(t)?r:IB(r,e(t))}mu.exports=DB});var xu=B((wI,Hu)=>{function NB(t,a){for(var e=-1,r=t==null?0:t.length,n=0,i=[];++e{function $B(){return[]}wu.exports=$B});var yu=B((VI,Ru)=>{var UB=xu(),WB=Lu(),jB=Object.prototype,qB=jB.propertyIsEnumerable,Vu=Object.getOwnPropertySymbols,GB=Vu?function(t){return t==null?[]:(t=Object(t),UB(Vu(t),function(a){return qB.call(t,a)}))}:WB;Ru.exports=GB});var Bu=B((RI,Cu)=>{var KB=Mu(),XB=yu(),YB=a5();function QB(t){return KB(t,YB,XB)}Cu.exports=QB});var Fu=B((yI,Au)=>{var Su=Bu(),ZB=1,JB=Object.prototype,tS=JB.hasOwnProperty;function aS(t,a,e,r,n,i){var l=e&ZB,o=Su(t),h=o.length,c=Su(a),v=c.length;if(h!=v&&!l)return!1;for(var g=h;g--;){var d=o[g];if(!(l?d in a:tS.call(a,d)))return!1}var u=i.get(t),p=i.get(a);if(u&&p)return u==a&&p==t;var z=!0;i.set(t,a),i.set(a,t);for(var w=l;++g{var eS=pe(),rS=Y2(),nS=eS(rS,"DataView");ku.exports=nS});var _u=B((BI,Eu)=>{var iS=pe(),lS=Y2(),oS=iS(lS,"Promise");Eu.exports=oS});var Pu=B((SI,Tu)=>{var hS=pe(),cS=Y2(),vS=hS(cS,"WeakMap");Tu.exports=vS});var ju=B((AI,Wu)=>{var t8=bu(),a8=jl(),e8=_u(),r8=Ih(),n8=Pu(),Uu=Y4(),or=_h(),Iu="[object Map]",gS="[object Object]",Ou="[object Promise]",Du="[object Set]",Nu="[object WeakMap]",$u="[object DataView]",dS=or(t8),sS=or(a8),uS=or(e8),fS=or(r8),pS=or(n8),Je=Uu;(t8&&Je(new t8(new ArrayBuffer(1)))!=$u||a8&&Je(new a8)!=Iu||e8&&Je(e8.resolve())!=Ou||r8&&Je(new r8)!=Du||n8&&Je(new n8)!=Nu)&&(Je=function(t){var a=Uu(t),e=a==gS?t.constructor:void 0,r=e?or(e):"";if(r)switch(r){case dS:return $u;case sS:return Iu;case uS:return Ou;case fS:return Du;case pS:return Nu}return a});Wu.exports=Je});var Ju=B((FI,Zu)=>{var i8=Qh(),zS=Zh(),mS=zu(),MS=Fu(),qu=ju(),Gu=Q2(),Ku=Kh(),HS=Yh(),xS=1,Xu="[object Arguments]",Yu="[object Array]",e5="[object Object]",wS=Object.prototype,Qu=wS.hasOwnProperty;function LS(t,a,e,r,n,i){var l=Gu(t),o=Gu(a),h=l?Yu:qu(t),c=o?Yu:qu(a);h=h==Xu?e5:h,c=c==Xu?e5:c;var v=h==e5,g=c==e5,d=h==c;if(d&&Ku(t)){if(!Ku(a))return!1;l=!0,v=!1}if(d&&!v)return i||(i=new i8),l||HS(t)?zS(t,a,e,r,n,i):mS(t,a,h,e,r,n,i);if(!(e&xS)){var u=v&&Qu.call(t,"__wrapped__"),p=g&&Qu.call(a,"__wrapped__");if(u||p){var z=u?t.value():t,w=p?a.value():a;return i||(i=new i8),n(z,w,e,r,i)}}return d?(i||(i=new i8),MS(t,a,e,r,n,i)):!1}Zu.exports=LS});var l8=B((kI,ef)=>{var VS=Ju(),tf=Q4();function af(t,a,e,r,n){return t===a?!0:t==null||a==null||!tf(t)&&!tf(a)?t!==t&&a!==a:VS(t,a,e,r,af,n)}ef.exports=af});var nf=B((bI,rf)=>{var RS=Qh(),yS=l8(),CS=1,BS=2;function SS(t,a,e,r){var n=e.length,i=n,l=!r;if(t==null)return!i;for(t=Object(t);n--;){var o=e[n];if(l&&o[2]?o[1]!==t[o[0]]:!(o[0]in t))return!1}for(;++n{var AS=fe();function FS(t){return t===t&&!AS(t)}lf.exports=FS});var hf=B((_I,of)=>{var kS=o8(),bS=a5();function ES(t){for(var a=bS(t),e=a.length;e--;){var r=a[e],n=t[r];a[e]=[r,n,kS(n)]}return a}of.exports=ES});var h8=B((TI,cf)=>{function _S(t,a){return function(e){return e==null?!1:e[t]===a&&(a!==void 0||t in Object(e))}}cf.exports=_S});var gf=B((PI,vf)=>{var TS=nf(),PS=hf(),IS=h8();function OS(t){var a=PS(t);return a.length==1&&a[0][2]?IS(a[0][0],a[0][1]):function(e){return e===t||TS(e,t,a)}}vf.exports=OS});var c8=B((II,df)=>{var DS=jh(),NS=Fn();function $S(t,a){a=DS(a,t);for(var e=0,r=a.length;t!=null&&e{var US=c8();function WS(t,a,e){var r=t==null?void 0:US(t,a);return r===void 0?e:r}sf.exports=WS});var pf=B((DI,ff)=>{function jS(t,a){return t!=null&&a in Object(t)}ff.exports=jS});var mf=B((NI,zf)=>{var qS=pf(),GS=qh();function KS(t,a){return t!=null&&GS(t,a,qS)}zf.exports=KS});var Hf=B(($I,Mf)=>{var XS=l8(),YS=uf(),QS=mf(),ZS=t5(),JS=o8(),tA=h8(),aA=Fn(),eA=1,rA=2;function nA(t,a){return ZS(t)&&JS(a)?tA(aA(t),a):function(e){var r=YS(e,t);return r===void 0&&r===a?QS(e,t):XS(a,r,eA|rA)}}Mf.exports=nA});var wf=B((UI,xf)=>{function iA(t){return t}xf.exports=iA});var Vf=B((WI,Lf)=>{function lA(t){return function(a){return a?.[t]}}Lf.exports=lA});var yf=B((jI,Rf)=>{var oA=c8();function hA(t){return function(a){return oA(a,t)}}Rf.exports=hA});var Bf=B((qI,Cf)=>{var cA=Vf(),vA=yf(),gA=t5(),dA=Fn();function sA(t){return gA(t)?cA(dA(t)):vA(t)}Cf.exports=sA});var Af=B((GI,Sf)=>{var uA=gf(),fA=Hf(),pA=wf(),zA=Q2(),mA=Bf();function MA(t){return typeof t=="function"?t:t==null?pA:typeof t=="object"?zA(t)?fA(t[0],t[1]):uA(t):mA(t)}Sf.exports=MA});var kf=B((KI,Ff)=>{var HA=cs(),xA=Ks(),wA=Af(),LA=Q2();function VA(t,a){return function(e,r){var n=LA(e)?HA:xA,i=a?a():{};return n(e,t,wA(r,2),i)}}Ff.exports=VA});var Ef=B((XI,bf)=>{var RA=os(),yA=kf(),CA=Object.prototype,BA=CA.hasOwnProperty,SA=yA(function(t,a,e){BA.call(t,e)?t[e].push(a):RA(t,e,[a])});bf.exports=SA});var Tf=B((YI,_f)=>{"use strict";var AA="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED";_f.exports=AA});var Df=B((QI,Of)=>{"use strict";var FA=Tf();function Pf(){}function If(){}If.resetWarningCache=Pf;Of.exports=function(){function t(r,n,i,l,o,h){if(h!==FA){var c=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw c.name="Invariant Violation",c}}t.isRequired=t;function a(){return t}var e={array:t,bigint:t,bool:t,func:t,number:t,object:t,string:t,symbol:t,any:t,arrayOf:a,element:t,elementType:t,instanceOf:a,node:t,objectOf:a,oneOf:a,oneOfType:a,shape:a,exact:a,checkPropTypes:If,resetWarningCache:Pf};return e.PropTypes=e,e}});var $f=B((tO,Nf)=>{Nf.exports=Df()();var ZI,JI});var Uf=B(r5=>{(function(t,a){if(typeof define=="function"&&define.amd)define(["exports","react","prop-types"],a);else if(typeof r5<"u")a(r5,U1(),$f());else{var e={exports:{}};a(e.exports,t.react,t.propTypes),t.reactSwipe=e.exports}})(r5,function(t,a,e){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.setHasSupportToCaptureOption=u;var r=i(a),n=i(e);function i(s){return s&&s.__esModule?s:{default:s}}var l=Object.assign||function(s){for(var f=1;f=0||!Object.prototype.hasOwnProperty.call(s,H)||(m[H]=s[H]);return m}function h(s,f){if(!(s instanceof f))throw new TypeError("Cannot call a class as a function")}var c=function(){function s(f,m){for(var H=0;H0&&arguments[0]!==void 0?arguments[0]:{capture:!0};return d?s:s.capture}function z(s){if("touches"in s){var f=s.touches[0],m=f.pageX,H=f.pageY;return{x:m,y:H}}var x=s.screenX,y=s.screenY;return{x,y}}var w=function(s){g(f,s);function f(){var m;h(this,f);for(var H=arguments.length,x=Array(H),y=0;yx&&this.props.onSwipeRight(1,H),this.movePosition.deltaY<-x?this.props.onSwipeUp(1,H):this.movePosition.deltaY>x&&this.props.onSwipeDown(1,H)),this.moveStart=null,this.moving=!1,this.movePosition=null}},{key:"_setSwiperRef",value:function(H){this.swiper=H,this.props.innerRef(H)}},{key:"render",value:function(){var H=this.props,x=H.tagName,y=H.className,R=H.style,L=H.children,V=H.allowMouseEvents,C=H.onSwipeUp,k=H.onSwipeDown,b=H.onSwipeLeft,F=H.onSwipeRight,_=H.onSwipeStart,j=H.onSwipeMove,n1=H.onSwipeEnd,Z=H.innerRef,d1=H.tolerance,O=o(H,["tagName","className","style","children","allowMouseEvents","onSwipeUp","onSwipeDown","onSwipeLeft","onSwipeRight","onSwipeStart","onSwipeMove","onSwipeEnd","innerRef","tolerance"]);return r.default.createElement(this.props.tagName,l({ref:this._setSwiperRef,onMouseDown:this._onMouseDown,onTouchStart:this._handleSwipeStart,onTouchEnd:this._handleSwipeEnd,className:y,style:R},O),L)}}]),f}(a.Component);w.displayName="ReactSwipe",w.propTypes={tagName:n.default.string,className:n.default.string,style:n.default.object,children:n.default.node,allowMouseEvents:n.default.bool,onSwipeUp:n.default.func,onSwipeDown:n.default.func,onSwipeLeft:n.default.func,onSwipeRight:n.default.func,onSwipeStart:n.default.func,onSwipeMove:n.default.func,onSwipeEnd:n.default.func,innerRef:n.default.func,tolerance:n.default.number.isRequired},w.defaultProps={tagName:"div",allowMouseEvents:!1,onSwipeUp:function(){},onSwipeDown:function(){},onSwipeLeft:function(){},onSwipeRight:function(){},onSwipeStart:function(){},onSwipeMove:function(){},onSwipeEnd:function(){},innerRef:function(){},tolerance:0},t.default=w})});var v8=B(n5=>{(function(t,a){if(typeof define=="function"&&define.amd)define(["exports","./react-swipe"],a);else if(typeof n5<"u")a(n5,Uf());else{var e={exports:{}};a(e.exports,t.reactSwipe),t.index=e.exports}})(n5,function(t,a){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var e=r(a);function r(n){return n&&n.__esModule?n:{default:n}}t.default=e.default})});var Wf=B((rO,i5)=>{(function(){"use strict";var t={}.hasOwnProperty,a="[native code]";function e(){for(var r=[],n=0;n{"use strict";Object.defineProperty(l5,"__esModule",{value:!0});l5.default=void 0;var ze=kA(Wf());function kA(t){return t&&t.__esModule?t:{default:t}}function bA(t,a,e){return a in t?Object.defineProperty(t,a,{value:e,enumerable:!0,configurable:!0,writable:!0}):t[a]=e,t}var EA={ROOT:function(a){return(0,ze.default)(bA({"carousel-root":!0},a||"",!!a))},CAROUSEL:function(a){return(0,ze.default)({carousel:!0,"carousel-slider":a})},WRAPPER:function(a,e){return(0,ze.default)({"thumbs-wrapper":!a,"slider-wrapper":a,"axis-horizontal":e==="horizontal","axis-vertical":e!=="horizontal"})},SLIDER:function(a,e){return(0,ze.default)({thumbs:!a,slider:a,animated:!e})},ITEM:function(a,e,r){return(0,ze.default)({thumb:!a,slide:a,selected:e,previous:r})},ARROW_PREV:function(a){return(0,ze.default)({"control-arrow control-prev":!0,"control-disabled":a})},ARROW_NEXT:function(a){return(0,ze.default)({"control-arrow control-next":!0,"control-disabled":a})},DOT:function(a){return(0,ze.default)({dot:!0,selected:a})}};l5.default=EA});var jf=B(o5=>{"use strict";Object.defineProperty(o5,"__esModule",{value:!0});o5.outerWidth=void 0;var _A=function(a){var e=a.offsetWidth,r=getComputedStyle(a);return e+=parseInt(r.marginLeft)+parseInt(r.marginRight),e};o5.outerWidth=_A});var c5=B(h5=>{"use strict";Object.defineProperty(h5,"__esModule",{value:!0});h5.default=void 0;var TA=function(a,e,r){var n=a===0?a:a+e,i=r==="horizontal"?[n,0,0]:[0,n,0],l="translate3d",o="("+i.join(",")+")";return l+o};h5.default=TA});var d8=B(v5=>{"use strict";Object.defineProperty(v5,"__esModule",{value:!0});v5.default=void 0;var PA=function(){return window};v5.default=PA});var p8=B(u5=>{"use strict";Object.defineProperty(u5,"__esModule",{value:!0});u5.default=void 0;var Z2=DA(U1()),t4=s5(g8()),IA=jf(),qf=s5(c5()),OA=s5(v8()),g5=s5(d8());function s5(t){return t&&t.__esModule?t:{default:t}}function Kf(){if(typeof WeakMap!="function")return null;var t=new WeakMap;return Kf=function(){return t},t}function DA(t){if(t&&t.__esModule)return t;if(t===null||Tn(t)!=="object"&&typeof t!="function")return{default:t};var a=Kf();if(a&&a.has(t))return a.get(t);var e={},r=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var n in t)if(Object.prototype.hasOwnProperty.call(t,n)){var i=r?Object.getOwnPropertyDescriptor(t,n):null;i&&(i.get||i.set)?Object.defineProperty(e,n,i):e[n]=t[n]}return e.default=t,a&&a.set(t,e),e}function Tn(t){return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?Tn=function(e){return typeof e}:Tn=function(e){return e&&typeof Symbol=="function"&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Tn(t)}function s8(){return s8=Object.assign||function(t){for(var a=1;a"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],function(){})),!0}catch{return!1}}function d5(t){return d5=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},d5(t)}function U0(t,a,e){return a in t?Object.defineProperty(t,a,{value:e,enumerable:!0,configurable:!0,writable:!0}):t[a]=e,t}var GA=function(a){return a.hasOwnProperty("key")},f8=function(t){UA(e,t);var a=WA(e);function e(r){var n;return NA(this,e),n=a.call(this,r),U0(Q0(n),"itemsWrapperRef",void 0),U0(Q0(n),"itemsListRef",void 0),U0(Q0(n),"thumbsRef",void 0),U0(Q0(n),"setItemsWrapperRef",function(i){n.itemsWrapperRef=i}),U0(Q0(n),"setItemsListRef",function(i){n.itemsListRef=i}),U0(Q0(n),"setThumbsRef",function(i,l){n.thumbsRef||(n.thumbsRef=[]),n.thumbsRef[l]=i}),U0(Q0(n),"updateSizes",function(){if(!(!n.props.children||!n.itemsWrapperRef||!n.thumbsRef)){var i=Z2.Children.count(n.props.children),l=n.itemsWrapperRef.clientWidth,o=n.props.thumbWidth?n.props.thumbWidth:(0,IA.outerWidth)(n.thumbsRef[0]),h=Math.floor(l/o),c=h0&&(l=0),c===g&&l<0&&(l=0);var d=n.itemsWrapperRef.clientWidth,u=c+100/(d/l);return n.itemsListRef&&["WebkitTransform","MozTransform","MsTransform","OTransform","transform","msTransform"].forEach(function(p){n.itemsListRef.style[p]=(0,qf.default)(u,"%",n.props.axis)}),!0}),U0(Q0(n),"slideRight",function(i){n.moveTo(n.state.firstItem-(typeof i=="number"?i:1))}),U0(Q0(n),"slideLeft",function(i){n.moveTo(n.state.firstItem+(typeof i=="number"?i:1))}),U0(Q0(n),"moveTo",function(i){i=i<0?0:i,i=i>=n.state.lastPosition?n.state.lastPosition:i,n.setState({firstItem:i})}),n.state={selectedItem:r.selectedItem,swiping:!1,showArrows:!1,firstItem:0,visibleItems:0,lastPosition:0},n}return $A(e,[{key:"componentDidMount",value:function(){this.setupThumbs()}},{key:"componentDidUpdate",value:function(n){this.props.selectedItem!==this.state.selectedItem&&this.setState({selectedItem:this.props.selectedItem,firstItem:this.getFirstItem(this.props.selectedItem)}),this.props.children!==n.children&&this.updateSizes()}},{key:"componentWillUnmount",value:function(){this.destroyThumbs()}},{key:"setupThumbs",value:function(){(0,g5.default)().addEventListener("resize",this.updateSizes),(0,g5.default)().addEventListener("DOMContentLoaded",this.updateSizes),this.updateSizes()}},{key:"destroyThumbs",value:function(){(0,g5.default)().removeEventListener("resize",this.updateSizes),(0,g5.default)().removeEventListener("DOMContentLoaded",this.updateSizes)}},{key:"getFirstItem",value:function(n){var i=n;return n>=this.state.lastPosition&&(i=this.state.lastPosition),n1,l=this.state.showArrows&&this.state.firstItem>0,o=this.state.showArrows&&this.state.firstItem{"use strict";Object.defineProperty(f5,"__esModule",{value:!0});f5.default=void 0;var KA=function(){return document};f5.default=KA});var z8=B(P2=>{"use strict";Object.defineProperty(P2,"__esModule",{value:!0});P2.setPosition=P2.getPosition=P2.isKeyboardEvent=P2.defaultStatusFormatter=P2.noop=void 0;var XA=U1(),YA=QA(c5());function QA(t){return t&&t.__esModule?t:{default:t}}var ZA=function(){};P2.noop=ZA;var JA=function(a,e){return"".concat(a," of ").concat(e)};P2.defaultStatusFormatter=JA;var tF=function(a){return a?a.hasOwnProperty("key"):!1};P2.isKeyboardEvent=tF;var aF=function(a,e){if(e.infiniteLoop&&++a,a===0)return 0;var r=XA.Children.count(e.children);if(e.centerMode&&e.axis==="horizontal"){var n=-a*e.centerSlidePercentage,i=r-1;return a&&(a!==i||e.infiniteLoop)?n+=(100-e.centerSlidePercentage)/2:a===i&&(n+=100-e.centerSlidePercentage),n}return-a*100};P2.getPosition=aF;var eF=function(a,e){var r={};return["WebkitTransform","MozTransform","MsTransform","OTransform","transform","msTransform"].forEach(function(n){r[n]=(0,YA.default)(a,"%",e)}),r};P2.setPosition=eF});var Zf=B(za=>{"use strict";Object.defineProperty(za,"__esModule",{value:!0});za.fadeAnimationHandler=za.slideStopSwipingHandler=za.slideSwipeAnimationHandler=za.slideAnimationHandler=void 0;var Qf=U1(),rF=nF(c5()),pa=z8();function nF(t){return t&&t.__esModule?t:{default:t}}function Yf(t,a){var e=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);a&&(r=r.filter(function(n){return Object.getOwnPropertyDescriptor(t,n).enumerable})),e.push.apply(e,r)}return e}function a4(t){for(var a=1;al);if(o)return i<0?a.centerMode&&a.centerSlidePercentage&&a.axis==="horizontal"?r.itemListStyle=(0,pa.setPosition)(-(l+2)*a.centerSlidePercentage-(100-a.centerSlidePercentage)/2,a.axis):r.itemListStyle=(0,pa.setPosition)(-(l+2)*100,a.axis):i>l&&(r.itemListStyle=(0,pa.setPosition)(0,a.axis)),r;var h=(0,pa.getPosition)(n,a),c=(0,rF.default)(h,"%",a.axis),v=a.transitionTime+"ms";return r.itemListStyle={WebkitTransform:c,msTransform:c,OTransform:c,transform:c},e.swiping||(r.itemListStyle=a4(a4({},r.itemListStyle),{},{WebkitTransitionDuration:v,MozTransitionDuration:v,OTransitionDuration:v,transitionDuration:v,msTransitionDuration:v})),r};za.slideAnimationHandler=lF;var oF=function(a,e,r,n){var i={},l=e.axis==="horizontal",o=Qf.Children.count(e.children),h=0,c=(0,pa.getPosition)(r.selectedItem,e),v=e.infiniteLoop?(0,pa.getPosition)(o-1,e)-100:(0,pa.getPosition)(o-1,e),g=l?a.x:a.y,d=g;c===h&&g>0&&(d=0),c===v&&g<0&&(d=0);var u=c+100/(r.itemSize/d),p=Math.abs(g)>e.swipeScrollTolerance;return e.infiniteLoop&&p&&(r.selectedItem===0&&u>-100?u-=o*100:r.selectedItem===o-1&&u<-o*100&&(u+=o*100)),(!e.preventMovementUntilSwipeScrollTolerance||p||r.swipeMovementStarted)&&(r.swipeMovementStarted||n({swipeMovementStarted:!0}),i.itemListStyle=(0,pa.setPosition)(u,e.axis)),p&&!r.cancelClick&&n({cancelClick:!0}),i};za.slideSwipeAnimationHandler=oF;var hF=function(a,e){var r=(0,pa.getPosition)(e.selectedItem,a),n=(0,pa.setPosition)(r,a.axis);return{itemListStyle:n}};za.slideStopSwipingHandler=hF;var cF=function(a,e){var r=a.transitionTime+"ms",n="ease-in-out",i={position:"absolute",display:"block",zIndex:-2,minHeight:"100%",opacity:0,top:0,right:0,left:0,bottom:0,transitionTimingFunction:n,msTransitionTimingFunction:n,MozTransitionTimingFunction:n,WebkitTransitionTimingFunction:n,OTransitionTimingFunction:n};return e.swiping||(i=a4(a4({},i),{},{WebkitTransitionDuration:r,MozTransitionDuration:r,OTransitionDuration:r,transitionDuration:r,msTransitionDuration:r})),{slideStyle:i,selectedStyle:a4(a4({},i),{},{opacity:1,position:"relative"}),prevStyle:a4({},i)}};za.fadeAnimationHandler=cF});var ep=B(H5=>{"use strict";Object.defineProperty(H5,"__esModule",{value:!0});H5.default=void 0;var Ct=dF(U1()),vF=On(v8()),Oa=On(g8()),gF=On(p8()),p5=On(Xf()),z5=On(d8()),Pn=z8(),m5=Zf();function On(t){return t&&t.__esModule?t:{default:t}}function ap(){if(typeof WeakMap!="function")return null;var t=new WeakMap;return ap=function(){return t},t}function dF(t){if(t&&t.__esModule)return t;if(t===null||In(t)!=="object"&&typeof t!="function")return{default:t};var a=ap();if(a&&a.has(t))return a.get(t);var e={},r=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var n in t)if(Object.prototype.hasOwnProperty.call(t,n)){var i=r?Object.getOwnPropertyDescriptor(t,n):null;i&&(i.get||i.set)?Object.defineProperty(e,n,i):e[n]=t[n]}return e.default=t,a&&a.set(t,e),e}function In(t){return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?In=function(e){return typeof e}:In=function(e){return e&&typeof Symbol=="function"&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},In(t)}function m8(){return m8=Object.assign||function(t){for(var a=1;a"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],function(){})),!0}catch{return!1}}function M5(t){return M5=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},M5(t)}function nt(t,a,e){return a in t?Object.defineProperty(t,a,{value:e,enumerable:!0,configurable:!0,writable:!0}):t[a]=e,t}var H8=function(t){fF(e,t);var a=pF(e);function e(r){var n;sF(this,e),n=a.call(this,r),nt(it(n),"thumbsRef",void 0),nt(it(n),"carouselWrapperRef",void 0),nt(it(n),"listRef",void 0),nt(it(n),"itemsRef",void 0),nt(it(n),"timer",void 0),nt(it(n),"animationHandler",void 0),nt(it(n),"setThumbsRef",function(l){n.thumbsRef=l}),nt(it(n),"setCarouselWrapperRef",function(l){n.carouselWrapperRef=l}),nt(it(n),"setListRef",function(l){n.listRef=l}),nt(it(n),"setItemsRef",function(l,o){n.itemsRef||(n.itemsRef=[]),n.itemsRef[o]=l}),nt(it(n),"autoPlay",function(){Ct.Children.count(n.props.children)<=1||(n.clearAutoPlay(),n.props.autoPlay&&(n.timer=setTimeout(function(){n.increment()},n.props.interval)))}),nt(it(n),"clearAutoPlay",function(){n.timer&&clearTimeout(n.timer)}),nt(it(n),"resetAutoPlay",function(){n.clearAutoPlay(),n.autoPlay()}),nt(it(n),"stopOnHover",function(){n.setState({isMouseEntered:!0},n.clearAutoPlay)}),nt(it(n),"startOnLeave",function(){n.setState({isMouseEntered:!1},n.autoPlay)}),nt(it(n),"isFocusWithinTheCarousel",function(){return n.carouselWrapperRef?!!((0,p5.default)().activeElement===n.carouselWrapperRef||n.carouselWrapperRef.contains((0,p5.default)().activeElement)):!1}),nt(it(n),"navigateWithKeyboard",function(l){if(!!n.isFocusWithinTheCarousel()){var o=n.props.axis,h=o==="horizontal",c={ArrowUp:38,ArrowRight:39,ArrowDown:40,ArrowLeft:37},v=h?c.ArrowRight:c.ArrowDown,g=h?c.ArrowLeft:c.ArrowUp;v===l.keyCode?n.increment():g===l.keyCode&&n.decrement()}}),nt(it(n),"updateSizes",function(){if(!(!n.state.initialized||!n.itemsRef||n.itemsRef.length===0)){var l=n.props.axis==="horizontal",o=n.itemsRef[0];if(!!o){var h=l?o.clientWidth:o.clientHeight;n.setState({itemSize:h}),n.thumbsRef&&n.thumbsRef.updateSizes()}}}),nt(it(n),"setMountState",function(){n.setState({hasMount:!0}),n.updateSizes()}),nt(it(n),"handleClickItem",function(l,o){if(Ct.Children.count(n.props.children)!==0){if(n.state.cancelClick){n.setState({cancelClick:!1});return}n.props.onClickItem(l,o),l!==n.state.selectedItem&&n.setState({selectedItem:l})}}),nt(it(n),"handleOnChange",function(l,o){Ct.Children.count(n.props.children)<=1||n.props.onChange(l,o)}),nt(it(n),"handleClickThumb",function(l,o){n.props.onClickThumb(l,o),n.moveTo(l)}),nt(it(n),"onSwipeStart",function(l){n.setState({swiping:!0}),n.props.onSwipeStart(l)}),nt(it(n),"onSwipeEnd",function(l){n.setState({swiping:!1,cancelClick:!1,swipeMovementStarted:!1}),n.props.onSwipeEnd(l),n.clearAutoPlay(),n.state.autoPlay&&n.autoPlay()}),nt(it(n),"onSwipeMove",function(l,o){n.props.onSwipeMove(o);var h=n.props.swipeAnimationHandler(l,n.props,n.state,n.setState.bind(it(n)));return n.setState(J2({},h)),!!Object.keys(h).length}),nt(it(n),"decrement",function(){var l=arguments.length>0&&arguments[0]!==void 0?arguments[0]:1;n.moveTo(n.state.selectedItem-(typeof l=="number"?l:1))}),nt(it(n),"increment",function(){var l=arguments.length>0&&arguments[0]!==void 0?arguments[0]:1;n.moveTo(n.state.selectedItem+(typeof l=="number"?l:1))}),nt(it(n),"moveTo",function(l){if(typeof l=="number"){var o=Ct.Children.count(n.props.children)-1;l<0&&(l=n.props.infiniteLoop?o:0),l>o&&(l=n.props.infiniteLoop?0:o),n.selectItem({selectedItem:l}),n.state.autoPlay&&n.state.isMouseEntered===!1&&n.resetAutoPlay()}}),nt(it(n),"onClickNext",function(){n.increment(1)}),nt(it(n),"onClickPrev",function(){n.decrement(1)}),nt(it(n),"onSwipeForward",function(){n.increment(1),n.props.emulateTouch&&n.setState({cancelClick:!0})}),nt(it(n),"onSwipeBackwards",function(){n.decrement(1),n.props.emulateTouch&&n.setState({cancelClick:!0})}),nt(it(n),"changeItem",function(l){return function(o){(!(0,Pn.isKeyboardEvent)(o)||o.key==="Enter")&&n.moveTo(l)}}),nt(it(n),"selectItem",function(l){n.setState(J2({previousItem:n.state.selectedItem},l),function(){n.setState(n.animationHandler(n.props,n.state))}),n.handleOnChange(l.selectedItem,Ct.Children.toArray(n.props.children)[l.selectedItem])}),nt(it(n),"getInitialImage",function(){var l=n.props.selectedItem,o=n.itemsRef&&n.itemsRef[l],h=o&&o.getElementsByTagName("img")||[];return h[0]}),nt(it(n),"getVariableItemHeight",function(l){var o=n.itemsRef&&n.itemsRef[l];if(n.state.hasMount&&o&&o.children.length){var h=o.children[0].getElementsByTagName("img")||[];if(h.length>0){var c=h[0];if(!c.complete){var v=function u(){n.forceUpdate(),c.removeEventListener("load",u)};c.addEventListener("load",v)}}var g=h[0]||o.children[0],d=g.clientHeight;return d>0?d:null}return null});var i={initialized:!1,previousItem:r.selectedItem,selectedItem:r.selectedItem,hasMount:!1,isMouseEntered:!1,autoPlay:r.autoPlay,swiping:!1,swipeMovementStarted:!1,cancelClick:!1,itemSize:1,itemListStyle:{},slideStyle:{},selectedStyle:{},prevStyle:{}};return n.animationHandler=typeof r.animationHandler=="function"&&r.animationHandler||r.animationHandler==="fade"&&m5.fadeAnimationHandler||m5.slideAnimationHandler,n.state=J2(J2({},i),n.animationHandler(r,i)),n}return uF(e,[{key:"componentDidMount",value:function(){!this.props.children||this.setupCarousel()}},{key:"componentDidUpdate",value:function(n,i){!n.children&&this.props.children&&!this.state.initialized&&this.setupCarousel(),!n.autoFocus&&this.props.autoFocus&&this.forceFocus(),i.swiping&&!this.state.swiping&&this.setState(J2({},this.props.stopSwipingHandler(this.props,this.state))),(n.selectedItem!==this.props.selectedItem||n.centerMode!==this.props.centerMode)&&(this.updateSizes(),this.moveTo(this.props.selectedItem)),n.autoPlay!==this.props.autoPlay&&(this.props.autoPlay?this.setupAutoPlay():this.destroyAutoPlay(),this.setState({autoPlay:this.props.autoPlay}))}},{key:"componentWillUnmount",value:function(){this.destroyCarousel()}},{key:"setupCarousel",value:function(){var n=this;this.bindEvents(),this.state.autoPlay&&Ct.Children.count(this.props.children)>1&&this.setupAutoPlay(),this.props.autoFocus&&this.forceFocus(),this.setState({initialized:!0},function(){var i=n.getInitialImage();i&&!i.complete?i.addEventListener("load",n.setMountState):n.setMountState()})}},{key:"destroyCarousel",value:function(){this.state.initialized&&(this.unbindEvents(),this.destroyAutoPlay())}},{key:"setupAutoPlay",value:function(){this.autoPlay();var n=this.carouselWrapperRef;this.props.stopOnHover&&n&&(n.addEventListener("mouseenter",this.stopOnHover),n.addEventListener("mouseleave",this.startOnLeave))}},{key:"destroyAutoPlay",value:function(){this.clearAutoPlay();var n=this.carouselWrapperRef;this.props.stopOnHover&&n&&(n.removeEventListener("mouseenter",this.stopOnHover),n.removeEventListener("mouseleave",this.startOnLeave))}},{key:"bindEvents",value:function(){(0,z5.default)().addEventListener("resize",this.updateSizes),(0,z5.default)().addEventListener("DOMContentLoaded",this.updateSizes),this.props.useKeyboardArrows&&(0,p5.default)().addEventListener("keydown",this.navigateWithKeyboard)}},{key:"unbindEvents",value:function(){(0,z5.default)().removeEventListener("resize",this.updateSizes),(0,z5.default)().removeEventListener("DOMContentLoaded",this.updateSizes);var n=this.getInitialImage();n&&n.removeEventListener("load",this.setMountState),this.props.useKeyboardArrows&&(0,p5.default)().removeEventListener("keydown",this.navigateWithKeyboard)}},{key:"forceFocus",value:function(){var n;(n=this.carouselWrapperRef)===null||n===void 0||n.focus()}},{key:"renderItems",value:function(n){var i=this;return this.props.children?Ct.Children.map(this.props.children,function(l,o){var h=o===i.state.selectedItem,c=o===i.state.previousItem,v=h&&i.state.selectedStyle||c&&i.state.prevStyle||i.state.slideStyle||{};i.props.centerMode&&i.props.axis==="horizontal"&&(v=J2(J2({},v),{},{minWidth:i.props.centerSlidePercentage+"%"})),i.state.swiping&&i.state.swipeMovementStarted&&(v=J2(J2({},v),{},{pointerEvents:"none"}));var g={ref:function(u){return i.setItemsRef(u,o)},key:"itemKey"+o+(n?"clone":""),className:Oa.default.ITEM(!0,o===i.state.selectedItem,o===i.state.previousItem),onClick:i.handleClickItem.bind(i,o,l),style:v};return Ct.default.createElement("li",g,i.props.renderItem(l,{isSelected:o===i.state.selectedItem,isPrevious:o===i.state.previousItem}))}):[]}},{key:"renderControls",value:function(){var n=this,i=this.props,l=i.showIndicators,o=i.labels,h=i.renderIndicator,c=i.children;return l?Ct.default.createElement("ul",{className:"control-dots"},Ct.Children.map(c,function(v,g){return h&&h(n.changeItem(g),g===n.state.selectedItem,g,o.item)})):null}},{key:"renderStatus",value:function(){return this.props.showStatus?Ct.default.createElement("p",{className:"carousel-status"},this.props.statusFormatter(this.state.selectedItem+1,Ct.Children.count(this.props.children))):null}},{key:"renderThumbs",value:function(){return!this.props.showThumbs||!this.props.children||Ct.Children.count(this.props.children)===0?null:Ct.default.createElement(gF.default,{ref:this.setThumbsRef,onSelectItem:this.handleClickThumb,selectedItem:this.state.selectedItem,transitionTime:this.props.transitionTime,thumbWidth:this.props.thumbWidth,labels:this.props.labels,emulateTouch:this.props.emulateTouch},this.props.renderThumbs(this.props.children))}},{key:"render",value:function(){var n=this;if(!this.props.children||Ct.Children.count(this.props.children)===0)return null;var i=this.props.swipeable&&Ct.Children.count(this.props.children)>1,l=this.props.axis==="horizontal",o=this.props.showArrows&&Ct.Children.count(this.props.children)>1,h=o&&(this.state.selectedItem>0||this.props.infiniteLoop)||!1,c=o&&(this.state.selectedItem{"use strict"});var ip=B(Dn=>{"use strict";Object.defineProperty(Dn,"__esModule",{value:!0});Object.defineProperty(Dn,"Carousel",{enumerable:!0,get:function(){return MF.default}});Object.defineProperty(Dn,"CarouselProps",{enumerable:!0,get:function(){return HF.CarouselProps}});Object.defineProperty(Dn,"Thumbs",{enumerable:!0,get:function(){return xF.default}});var MF=np(ep()),HF=rp(),xF=np(p8());function np(t){return t&&t.__esModule?t:{default:t}}});function Hp(t,a){var e={};for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&a.indexOf(r)<0&&(e[r]=t[r]);if(t!=null&&typeof Object.getOwnPropertySymbols=="function")for(var n=0,r=Object.getOwnPropertySymbols(t);n=o?n=n+fp("0",l-o):n=(n.substring(0,l)||"0")+"."+n.substring(l),e+n}function pp(t,a,e){if(["","-"].indexOf(t)!==-1)return t;var r=(t.indexOf(".")!==-1||e)&&a,n=x8(t),i=n.beforeDecimal,l=n.afterDecimal,o=n.hasNegation,h=parseFloat("0."+(l||"0")),c=l.length<=a?"0."+l:h.toFixed(a),v=c.split("."),g=i.split("").reverse().reduce(function(z,w,s){return z.length>s?(Number(z[0])+Number(w)).toString()+z.substring(1,z.length):w+z},v[0]),d=Lp(v[1]||"",a,e),u=o?"-":"",p=r?".":"";return""+u+g+p+d}function cr(t,a){if(t.value=t.value,t!==null){if(t.createTextRange){var e=t.createTextRange();return e.move("character",a),e.select(),!0}return t.selectionStart||t.selectionStart===0?(t.focus(),t.setSelectionRange(a,a),!0):(t.focus(),!1)}}function UF(t,a){for(var e=0,r=0,n=t.length,i=a.length;t[e]===a[e]&&ee&&n-r>e;)r++;return{from:{start:e,end:n-r},to:{start:e,end:i-r}}}function WF(t,a,e){return Math.min(Math.max(t,a),e)}function zp(t){return Math.max(t.selectionStart,t.selectionEnd)}function jF(){return typeof navigator<"u"&&!(navigator.platform&&/iPhone|iPod/.test(navigator.platform))}function qF(t){return{from:{start:0,end:0},to:{start:0,end:t.length},lastValue:""}}function GF(t,a,e,r,n,i){var l=n.findIndex(function(f){return f}),o=t.slice(0,l);!a&&!e.startsWith(o)&&(e=o+e,r=r+o.length);for(var h=e.length,c=t.length,v={},g=new Array(h),d=0;d0&&g[z]===-1;)z--;var s=z===-1||g[z]===-1?0:g[z]+1;return s>w?w:r-s=0&&!e[a];)a--;a===-1&&(a=e.indexOf(!0))}else{for(;a<=n&&!e[a];)a++;a>n&&(a=e.lastIndexOf(!0))}return a===-1&&(a=n),a}function KF(t){for(var a=Array.from({length:t.length+1}).map(function(){return!0}),e=0,r=a.length;et.length-i.length&&(f=v),t=t.substring(0,f),t=ZF(w?"-"+t:t,r),t=(t.match(JF(u,!0))||[]).join("");var H=t.indexOf(u);t=t.replace(new RegExp(wp(u),"g"),function(V,C){return C===H?".":""});var x=x8(t,r),y=x.beforeDecimal,R=x.afterDecimal,L=x.addNegation;return h.end-h.start{a0=B1(T1());(function(t){t.event="event",t.props="prop"})(jn||(jn={}))});var Hp={};Pm(Hp,{default:()=>WF});function Mp(){var t,a,e;let n=(e=(a=(t=Intl.NumberFormat())==null?void 0:t.formatToParts(1.1))==null?void 0:a.find(i=>i.type==="decimal"))==null?void 0:e.value;return n??"."}function $F(){return Mp()==="."?",":"."}var Qe,NF,UF,WF,xp=eo(()=>{Lh();Qe=B1(T1(),1);mp();NF=y0("div")({name:"NumberOverlayEditorStyle",class:"n1czszh3"});UF=t=>{let{value:a,onChange:e,disabled:r,highlight:n,validatedSelection:i}=t,l=Qe.useRef();return Qe.useLayoutEffect(()=>{var o;if(i!==void 0){let h=typeof i=="number"?[i,null]:i;(o=l.current)==null||o.setSelectionRange(h[0],h[1])}},[i]),Qe.createElement(NF,null,Qe.createElement(zp,{autoFocus:!0,getInputRef:l,className:"gdg-input",onFocus:o=>o.target.setSelectionRange(n?0:o.target.value.length,o.target.value.length),disabled:r===!0,thousandSeparator:$F(),decimalSeparator:Mp(),value:Object.is(a,-0)?"-":a??"",onValueChange:e}))},WF=UF});var v1=B1(T1()),om=B1(Pc());Lh();var D=B1(T1(),1),Kn=B1(Z4(),1),Up=B1(Og(),1),w8=B1(ad(),1),e4=B1(_h(),1),Wp=B1(Gl(),1),l0=B1(T1(),1),jp=B1(Tl(),1),fr=B1(T1(),1),Gp=B1(T1(),1),Qp=B1(Ud(),1),ua=B1(T1(),1),U1=B1(T1(),1),g0=B1(T1(),1),az=B1(Z4(),1),It=B1(T1(),1),r1=B1(T1(),1),ez=B1(jd(),1),Zt=B1(T1(),1),iz=B1(Gl(),1),hz=B1(T1(),1);var er=new Map,rr=new Map,Dh=new Map;function qd(){er.clear(),Dh.clear(),rr.clear()}function ty(t,a,e,r,n){var i,l,o;let h=0,c={};for(let g of t)h+=(i=e.get(g))!=null?i:n,c[g]=((l=c[g])!=null?l:0)+1;let v=a-h;for(let g of Object.keys(c)){let s=c[g],d=(o=e.get(g))!=null?o:n,p=d*s/h,z=v*p*r/s,L=d+z;e.set(g,L)}}function ay(t,a){var e;let r=new Map,n=0;for(let c of"abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ1234567890,.-+=?"){let v=t.measureText(c).width;r.set(c,v),n+=v}let i=n/r.size,l=3,o=(a/i+l)/(l+1),h=r.keys();for(let c of h)r.set(c,((e=r.get(c))!=null?e:i)*o);return r}function bn(t,a,e,r){var n,i;let l=rr.get(e);if(r&&l!==void 0&&l.count>2e4){let c=Dh.get(e);if(c===void 0&&(c=ay(t,l.size),Dh.set(e,c)),l.count>5e5){let g=0;for(let s of a)g+=(n=c.get(s))!=null?n:l.size;return g*1.01}let v=t.measureText(a);return ty(a,v.width,c,Math.max(.05,1-l.count/2e5),l.size),rr.set(e,{count:l.count+a.length,size:l.size}),v.width}let o=t.measureText(a),h=o.width/a.length;if(((i=l?.count)!=null?i:0)>2e4)return o.width;if(l===void 0)rr.set(e,{count:a.length,size:h});else{let c=h-l.size,v=a.length/(l.count+a.length),g=l.size+c*v;rr.set(e,{count:l.count+a.length,size:g})}return o.width}function ey(t,a,e,r,n,i,l,o){if(a.length<=1)return a.length;if(ne;){let g=v!==void 0?0:a.lastIndexOf(" ",h-1);g>0?h=g:h--,c=bn(t,a.slice(0,Math.max(0,h)),r,l)}if(a[h]!==" "){let g=0;if(v===void 0)g=a.lastIndexOf(" ",h);else for(let s of v){if(s>h)break;g=s}g>0&&(h=g)}return h}function Gd(t,a,e,r,n,i){let l=`${a}_${e}_${r}px`,o=er.get(l);if(o!==void 0)return o;if(r<=0)return[];let h=[],c=a.split(` -`),v=rr.get(e),g=v===void 0?a.length:r/v.size*1.5,s=n&&v!==void 0&&v.count>2e4;for(let d of c){let p=bn(t,d.slice(0,Math.max(0,g)),e,s),z=Math.min(d.length,g);if(p<=r)h.push(d);else{for(;p>r;){let L=ey(t,d,r,e,p,z,s,i),u=d.slice(0,Math.max(0,L));d=d.slice(u.length),h.push(u),p=bn(t,d.slice(0,Math.max(0,g)),e,s),z=Math.min(d.length,g)}p>0&&h.push(d)}}return h=h.map((d,p)=>p===0?d.trimEnd():d.trim()),er.set(l,h),er.size>500&&er.delete(er.keys().next().value),h}var R8=B1(Z4(),1),dz=B1(_h(),1),sz=B1(Rf(),1),C8=B1(Z4(),1),r4=B1(T1(),1),it=B1(T1(),1),pr=B1(T1(),1),wz=B1(Z4(),1),S5=B1(T1(),1),m2=B1(T1(),1),A5=B1(T1(),1),B8=B1(T1(),1),Vz=B1(T1(),1),S8=B1(T1(),1),yz=B1(T1(),1),F5=B1(T1(),1),Cz=B1(T1(),1),Yn=B1(T1(),1),Bz=B1(T1(),1),a4=B1(T1(),1),Sz=B1(Yf(),1),Az=B1(T1(),1),B0=B1(T1(),1),A8=B1(T1(),1);function rp(){return{async:!1,baseUrl:null,breaks:!1,extensions:null,gfm:!0,headerIds:!0,headerPrefix:"",highlight:null,langPrefix:"language-",mangle:!0,pedantic:!1,renderer:null,sanitize:!1,sanitizer:null,silent:!1,smartypants:!1,tokenizer:null,walkTokens:null,xhtml:!1}}var hr=rp();function iF(t){hr=t}var lF=/[&<>"']/,oF=/[&<>"']/g,hF=/[<>"']|&(?!#?\w+;)/,cF=/[<>"']|&(?!#?\w+;)/g,vF={"&":"&","<":"<",">":">",'"':""","'":"'"},Qf=t=>vF[t];function C0(t,a){if(a){if(lF.test(t))return t.replace(oF,Qf)}else if(hF.test(t))return t.replace(cF,Qf);return t}var gF=/&(#(?:\d+)|(?:#x[0-9A-Fa-f]+)|(?:\w+));?/ig;function np(t){return t.replace(gF,(a,e)=>(e=e.toLowerCase(),e==="colon"?":":e.charAt(0)==="#"?e.charAt(1)==="x"?String.fromCharCode(parseInt(e.substring(2),16)):String.fromCharCode(+e.substring(1)):""))}var dF=/(^|[^\[])\^/g;function Ft(t,a){t=typeof t=="string"?t:t.source,a=a||"";let e={replace:(r,n)=>(n=n.source||n,n=n.replace(dF,"$1"),t=t.replace(r,n),e),getRegex:()=>new RegExp(t,a)};return e}var sF=/[^\w:]/g,uF=/^$|^[a-z][a-z0-9+.-]*:|^[?#]/i;function Zf(t,a,e){if(t){let r;try{r=decodeURIComponent(np(e)).replace(sF,"").toLowerCase()}catch{return null}if(r.indexOf("javascript:")===0||r.indexOf("vbscript:")===0||r.indexOf("data:")===0)return null}a&&!uF.test(e)&&(e=mF(a,e));try{e=encodeURI(e).replace(/%25/g,"%")}catch{return null}return e}var f5={},fF=/^[^:]+:\/*[^/]*$/,pF=/^([^:]+:)[\s\S]*$/,zF=/^([^:]+:\/*[^/]*)[\s\S]*$/;function mF(t,a){f5[" "+t]||(fF.test(t)?f5[" "+t]=t+"/":f5[" "+t]=p5(t,"/",!0)),t=f5[" "+t];let e=t.indexOf(":")===-1;return a.substring(0,2)==="//"?e?a:t.replace(pF,"$1")+a:a.charAt(0)==="/"?e?a:t.replace(zF,"$1")+a:t+a}var z5={exec:function(){}};function Y2(t){let a=1,e,r;for(;a{let h=!1,c=l;for(;--c>=0&&o[c]==="\\";)h=!h;return h?"|":" |"}),r=e.split(/ \|/),n=0;if(r[0].trim()||r.shift(),r.length>0&&!r[r.length-1].trim()&&r.pop(),r.length>a)r.splice(a);else for(;r.length1;)a&1&&(e+=t),a>>=1,t+=t;return e+t}function ap(t,a,e,r){let n=a.href,i=a.title?C0(a.title):null,l=t[1].replace(/\\([\[\]])/g,"$1");if(t[0].charAt(0)!=="!"){r.state.inLink=!0;let o={type:"link",raw:e,href:n,title:i,text:l,tokens:r.inlineTokens(l)};return r.state.inLink=!1,o}return{type:"image",raw:e,href:n,title:i,text:C0(l)}}function HF(t,a){let e=t.match(/^(\s+)(?:```)/);if(e===null)return a;let r=e[1];return a.split(` + `)}function rk(t){var a=t.decimalSeparator;a===void 0&&(a=".");var e=t.allowedDecimalSeparators,r=t.thousandsGroupStyle,n=t.suffix,i=t.allowNegative,l=t.allowLeadingZeros,o=t.onKeyDown;o===void 0&&(o=me);var h=t.onBlur;h===void 0&&(h=me);var c=t.thousandSeparator,v=t.decimalScale,g=t.fixedDecimalScale,d=t.prefix;d===void 0&&(d="");var u=t.defaultValue,p=t.value,z=t.valueIsNumericString,w=t.onValueChange,s=Hp(t,["decimalSeparator","allowedDecimalSeparators","thousandsGroupStyle","suffix","allowNegative","allowLeadingZeros","onKeyDown","onBlur","thousandSeparator","decimalScale","fixedDecimalScale","prefix","defaultValue","value","valueIsNumericString","onValueChange"]);ek(t);var f=function(_){return Mp(_,t)},m=function(_,j){return tk(_,j,t)},H=z;Un(p)?Un(u)||(H=z??typeof u=="number"):H=z??typeof p=="number";var x=function(_){return Un(_)||xp(_)?_:(typeof _=="number"&&(_=Vp(_)),H&&typeof v=="number"?pp(_,v,Boolean(g)):_)},y=Rp(x(p),x(u),Boolean(H),f,m,w),R=y[0],L=R.numAsString,V=R.formattedValue,C=y[1],k=function(_){var j=_.target,n1=_.key,Z=j.selectionStart,d1=j.selectionEnd,O=j.value;if(O===void 0&&(O=""),Z!==d1){o(_);return}n1==="Backspace"&&O[0]==="-"&&Z===d.length+1&&cr(j,1);var a1=C5(t),W=a1.decimalSeparator;n1==="Backspace"&&O[Z-1]===W&&v&&g&&(cr(j,Z-1),_.preventDefault());var L1=c===!0?",":c;n1==="Backspace"&&O[Z-1]===L1&&cr(j,Z-1),n1==="Delete"&&O[Z]===L1&&cr(j,Z+1),o(_)},b=function(_){var j=L;if(j.match(/\d/g)||(j=""),l||(j=$F(j)),g&&v&&(j=pp(j,v,g)),j!==L){var n1=Mp(j,t);C({formattedValue:n1,value:j,floatValue:parseFloat(j)},{event:_,source:Wn.event})}h(_)},F=function(_){return _===a?!0:y5(_)};return Object.assign(Object.assign({},s),{value:V,valueIsNumericString:!1,isValidInputCharacter:F,onValueChange:C,format:f,removeFormatting:m,getCaretBoundary:function(_){return ak(_,t)},onKeyDown:k,onBlur:b})}function yp(t){var a=rk(t);return r0.default.createElement(QF,Object.assign({},a))}var r0,Wn,Cp=co(()=>{r0=F1(U1());(function(t){t.event="event",t.props="prop"})(Wn||(Wn={}))});var Sp={};tM(Sp,{default:()=>ok});function Bp(){var t,a,e;let n=(e=(a=(t=Intl.NumberFormat())==null?void 0:t.formatToParts(1.1))==null?void 0:a.find(i=>i.type==="decimal"))==null?void 0:e.value;return n??"."}function ik(){return Bp()==="."?",":"."}var e4,nk,lk,ok,Ap=co(()=>{Ah();e4=F1(U1(),1);Cp();nk=L0("div")({name:"NumberOverlayEditorStyle",class:"n1czszh3"});lk=t=>{let{value:a,onChange:e,disabled:r,highlight:n,validatedSelection:i,fixedDecimals:l,allowNegative:o,thousandSeparator:h,decimalSeparator:c}=t,v=e4.useRef();return e4.useLayoutEffect(()=>{var g;if(i!==void 0){let d=typeof i=="number"?[i,null]:i;(g=v.current)==null||g.setSelectionRange(d[0],d[1])}},[i]),e4.createElement(nk,null,e4.createElement(yp,{autoFocus:!0,getInputRef:v,className:"gdg-input",onFocus:g=>g.target.setSelectionRange(n?0:g.target.value.length,g.target.value.length),disabled:r===!0,decimalScale:l,allowNegative:o,thousandSeparator:h??ik(),decimalSeparator:c??Bp(),value:Object.is(a,-0)?"-":a??"",onValueChange:e}))},ok=lk});var g1=F1(U1()),Lm=F1(qc());Ah();var $=F1(U1(),1),Gn=F1(Z4(),1),tz=F1(Kg(),1),B8=F1(vd(),1),i4=F1($h(),1),az=F1(Jl(),1),o0=F1(U1(),1),ez=F1($l(),1),pr=F1(U1(),1),nz=F1(U1(),1),hz=F1(Zd(),1),ma=F1(U1(),1),q1=F1(U1(),1),d0=F1(U1(),1),dz=F1(Z4(),1),It=F1(U1(),1),r1=F1(U1(),1),sz=F1(ts(),1),Zt=F1(U1(),1),pz=F1(Jl(),1),Lz=F1(U1(),1);var er=new Map,rr=new Map,Gh=new Map;function as(){er.clear(),Gh.clear(),rr.clear()}function zy(t,a,e,r,n){var i,l,o;let h=0,c={};for(let g of t)h+=(i=e.get(g))!=null?i:n,c[g]=((l=c[g])!=null?l:0)+1;let v=a-h;for(let g of Object.keys(c)){let d=c[g],u=(o=e.get(g))!=null?o:n,p=u*d/h,z=v*p*r/d,w=u+z;e.set(g,w)}}function my(t,a){var e;let r=new Map,n=0;for(let c of"abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ1234567890,.-+=?"){let v=t.measureText(c).width;r.set(c,v),n+=v}let i=n/r.size,l=3,o=(a/i+l)/(l+1),h=r.keys();for(let c of h)r.set(c,((e=r.get(c))!=null?e:i)*o);return r}function kn(t,a,e,r){var n,i;let l=rr.get(e);if(r&&l!==void 0&&l.count>2e4){let c=Gh.get(e);if(c===void 0&&(c=my(t,l.size),Gh.set(e,c)),l.count>5e5){let g=0;for(let d of a)g+=(n=c.get(d))!=null?n:l.size;return g*1.01}let v=t.measureText(a);return zy(a,v.width,c,Math.max(.05,1-l.count/2e5),l.size),rr.set(e,{count:l.count+a.length,size:l.size}),v.width}let o=t.measureText(a),h=o.width/a.length;if(((i=l?.count)!=null?i:0)>2e4)return o.width;if(l===void 0)rr.set(e,{count:a.length,size:h});else{let c=h-l.size,v=a.length/(l.count+a.length),g=l.size+c*v;rr.set(e,{count:l.count+a.length,size:g})}return o.width}function My(t,a,e,r,n,i,l,o){if(a.length<=1)return a.length;if(ne;){let g=v!==void 0?0:a.lastIndexOf(" ",h-1);g>0?h=g:h--,c=kn(t,a.slice(0,Math.max(0,h)),r,l)}if(a[h]!==" "){let g=0;if(v===void 0)g=a.lastIndexOf(" ",h);else for(let d of v){if(d>h)break;g=d}g>0&&(h=g)}return h}function es(t,a,e,r,n,i){let l=`${a}_${e}_${r}px`,o=er.get(l);if(o!==void 0)return o;if(r<=0)return[];let h=[],c=a.split(` +`),v=rr.get(e),g=v===void 0?a.length:r/v.size*1.5,d=n&&v!==void 0&&v.count>2e4;for(let u of c){let p=kn(t,u.slice(0,Math.max(0,g)),e,d),z=Math.min(u.length,g);if(p<=r)h.push(u);else{for(;p>r;){let w=My(t,u,r,e,p,z,d,i),s=u.slice(0,Math.max(0,w));u=u.slice(s.length),h.push(s),p=kn(t,u.slice(0,Math.max(0,g)),e,d),z=Math.min(u.length,g)}p>0&&h.push(u)}}return h=h.map((u,p)=>p===0?u.trimEnd():u.trim()),er.set(l,h),er.size>500&&er.delete(er.keys().next().value),h}var F8=F1(Z4(),1),Cz=F1($h(),1),Bz=F1(Ef(),1),b8=F1(Z4(),1),l4=F1(U1(),1),lt=F1(U1(),1),zr=F1(U1(),1),Pz=F1(Z4(),1),_5=F1(U1(),1),l2=F1(U1(),1),T5=F1(U1(),1),_8=F1(U1(),1),Dz=F1(U1(),1),T8=F1(U1(),1),$z=F1(U1(),1),P5=F1(U1(),1),Uz=F1(U1(),1),Xn=F1(U1(),1),Wz=F1(U1(),1),n4=F1(U1(),1),jz=F1(ip(),1),qz=F1(U1(),1),R0=F1(U1(),1),P8=F1(U1(),1);function dp(){return{async:!1,baseUrl:null,breaks:!1,extensions:null,gfm:!0,headerIds:!0,headerPrefix:"",highlight:null,langPrefix:"language-",mangle:!0,pedantic:!1,renderer:null,sanitize:!1,sanitizer:null,silent:!1,smartypants:!1,tokenizer:null,walkTokens:null,xhtml:!1}}var hr=dp();function wF(t){hr=t}var LF=/[&<>"']/,VF=/[&<>"']/g,RF=/[<>"']|&(?!#?\w+;)/,yF=/[<>"']|&(?!#?\w+;)/g,CF={"&":"&","<":"<",">":">",'"':""","'":"'"},lp=t=>CF[t];function V0(t,a){if(a){if(LF.test(t))return t.replace(VF,lp)}else if(RF.test(t))return t.replace(yF,lp);return t}var BF=/&(#(?:\d+)|(?:#x[0-9A-Fa-f]+)|(?:\w+));?/ig;function sp(t){return t.replace(BF,(a,e)=>(e=e.toLowerCase(),e==="colon"?":":e.charAt(0)==="#"?e.charAt(1)==="x"?String.fromCharCode(parseInt(e.substring(2),16)):String.fromCharCode(+e.substring(1)):""))}var SF=/(^|[^\[])\^/g;function bt(t,a){t=typeof t=="string"?t:t.source,a=a||"";let e={replace:(r,n)=>(n=n.source||n,n=n.replace(SF,"$1"),t=t.replace(r,n),e),getRegex:()=>new RegExp(t,a)};return e}var AF=/[^\w:]/g,FF=/^$|^[a-z][a-z0-9+.-]*:|^[?#]/i;function op(t,a,e){if(t){let r;try{r=decodeURIComponent(sp(e)).replace(AF,"").toLowerCase()}catch{return null}if(r.indexOf("javascript:")===0||r.indexOf("vbscript:")===0||r.indexOf("data:")===0)return null}a&&!FF.test(e)&&(e=_F(a,e));try{e=encodeURI(e).replace(/%25/g,"%")}catch{return null}return e}var x5={},kF=/^[^:]+:\/*[^/]*$/,bF=/^([^:]+:)[\s\S]*$/,EF=/^([^:]+:\/*[^/]*)[\s\S]*$/;function _F(t,a){x5[" "+t]||(kF.test(t)?x5[" "+t]=t+"/":x5[" "+t]=w5(t,"/",!0)),t=x5[" "+t];let e=t.indexOf(":")===-1;return a.substring(0,2)==="//"?e?a:t.replace(bF,"$1")+a:a.charAt(0)==="/"?e?a:t.replace(EF,"$1")+a:t+a}var L5={exec:function(){}};function aa(t){let a=1,e,r;for(;a{let h=!1,c=l;for(;--c>=0&&o[c]==="\\";)h=!h;return h?"|":" |"}),r=e.split(/ \|/),n=0;if(r[0].trim()||r.shift(),r.length>0&&!r[r.length-1].trim()&&r.pop(),r.length>a)r.splice(a);else for(;r.length1;)a&1&&(e+=t),a>>=1,t+=t;return e+t}function vp(t,a,e,r){let n=a.href,i=a.title?V0(a.title):null,l=t[1].replace(/\\([\[\]])/g,"$1");if(t[0].charAt(0)!=="!"){r.state.inLink=!0;let o={type:"link",raw:e,href:n,title:i,text:l,tokens:r.inlineTokens(l)};return r.state.inLink=!1,o}return{type:"image",raw:e,href:n,title:i,text:V0(l)}}function PF(t,a){let e=t.match(/^(\s+)(?:```)/);if(e===null)return a;let r=e[1];return a.split(` `).map(n=>{let i=n.match(/^\s+/);if(i===null)return n;let[l]=i;return l.length>=r.length?n.slice(r.length):n}).join(` -`)}var $n=class{constructor(a){this.options=a||hr}space(a){let e=this.rules.block.newline.exec(a);if(e&&e[0].length>0)return{type:"space",raw:e[0]}}code(a){let e=this.rules.block.code.exec(a);if(e){let r=e[0].replace(/^ {1,4}/gm,"");return{type:"code",raw:e[0],codeBlockStyle:"indented",text:this.options.pedantic?r:p5(r,` -`)}}}fences(a){let e=this.rules.block.fences.exec(a);if(e){let r=e[0],n=HF(r,e[3]||"");return{type:"code",raw:r,lang:e[2]?e[2].trim().replace(this.rules.inline._escapes,"$1"):e[2],text:n}}}heading(a){let e=this.rules.block.heading.exec(a);if(e){let r=e[2].trim();if(/#$/.test(r)){let n=p5(r,"#");(this.options.pedantic||!n||/ $/.test(n))&&(r=n.trim())}return{type:"heading",raw:e[0],depth:e[1].length,text:r,tokens:this.lexer.inline(r)}}}hr(a){let e=this.rules.block.hr.exec(a);if(e)return{type:"hr",raw:e[0]}}blockquote(a){let e=this.rules.block.blockquote.exec(a);if(e){let r=e[0].replace(/^ *>[ \t]?/gm,"");return{type:"blockquote",raw:e[0],tokens:this.lexer.blockTokens(r,[]),text:r}}}list(a){let e=this.rules.block.list.exec(a);if(e){let r,n,i,l,o,h,c,v,g,s,d,p,z=e[1].trim(),L=z.length>1,u={type:"list",raw:"",ordered:L,start:L?+z.slice(0,-1):"",loose:!1,items:[]};z=L?`\\d{1,9}\\${z.slice(-1)}`:`\\${z}`,this.options.pedantic&&(z=L?z:"[*+-]");let f=new RegExp(`^( {0,3}${z})((?:[ ][^\\n]*)?(?:\\n|$))`);for(;a&&(p=!1,!(!(e=f.exec(a))||this.rules.block.hr.test(a)));){if(r=e[0],a=a.substring(r.length),v=e[2].split(` +`)}var Nn=class{constructor(a){this.options=a||hr}space(a){let e=this.rules.block.newline.exec(a);if(e&&e[0].length>0)return{type:"space",raw:e[0]}}code(a){let e=this.rules.block.code.exec(a);if(e){let r=e[0].replace(/^ {1,4}/gm,"");return{type:"code",raw:e[0],codeBlockStyle:"indented",text:this.options.pedantic?r:w5(r,` +`)}}}fences(a){let e=this.rules.block.fences.exec(a);if(e){let r=e[0],n=PF(r,e[3]||"");return{type:"code",raw:r,lang:e[2]?e[2].trim().replace(this.rules.inline._escapes,"$1"):e[2],text:n}}}heading(a){let e=this.rules.block.heading.exec(a);if(e){let r=e[2].trim();if(/#$/.test(r)){let n=w5(r,"#");(this.options.pedantic||!n||/ $/.test(n))&&(r=n.trim())}return{type:"heading",raw:e[0],depth:e[1].length,text:r,tokens:this.lexer.inline(r)}}}hr(a){let e=this.rules.block.hr.exec(a);if(e)return{type:"hr",raw:e[0]}}blockquote(a){let e=this.rules.block.blockquote.exec(a);if(e){let r=e[0].replace(/^ *>[ \t]?/gm,"");return{type:"blockquote",raw:e[0],tokens:this.lexer.blockTokens(r,[]),text:r}}}list(a){let e=this.rules.block.list.exec(a);if(e){let r,n,i,l,o,h,c,v,g,d,u,p,z=e[1].trim(),w=z.length>1,s={type:"list",raw:"",ordered:w,start:w?+z.slice(0,-1):"",loose:!1,items:[]};z=w?`\\d{1,9}\\${z.slice(-1)}`:`\\${z}`,this.options.pedantic&&(z=w?z:"[*+-]");let f=new RegExp(`^( {0,3}${z})((?:[ ][^\\n]*)?(?:\\n|$))`);for(;a&&(p=!1,!(!(e=f.exec(a))||this.rules.block.hr.test(a)));){if(r=e[0],a=a.substring(r.length),v=e[2].split(` `,1)[0],g=a.split(` -`,1)[0],this.options.pedantic?(l=2,d=v.trimLeft()):(l=e[2].search(/[^ ]/),l=l>4?1:l,d=v.slice(l),l+=e[1].length),h=!1,!v&&/^ *$/.test(g)&&(r+=g+` -`,a=a.substring(g.length+1),p=!0),!p){let M=new RegExp(`^ {0,${Math.min(3,l-1)}}(?:[*+-]|\\d{1,9}[.)])((?: [^\\n]*)?(?:\\n|$))`),x=new RegExp(`^ {0,${Math.min(3,l-1)}}((?:- *){3,}|(?:_ *){3,}|(?:\\* *){3,})(?:\\n+|$)`),y=new RegExp(`^ {0,${Math.min(3,l-1)}}(?:\`\`\`|~~~)`),w=new RegExp(`^ {0,${Math.min(3,l-1)}}#`);for(;a&&(s=a.split(` -`,1)[0],v=s,this.options.pedantic&&(v=v.replace(/^ {1,4}(?=( {4})*[^ ])/g," ")),!(y.test(v)||w.test(v)||M.test(v)||x.test(a)));){if(v.search(/[^ ]/)>=l||!v.trim())d+=` -`+v.slice(l);else if(!h)d+=` -`+v;else break;!h&&!v.trim()&&(h=!0),r+=s+` -`,a=a.substring(s.length+1)}}u.loose||(c?u.loose=!0:/\n *\n *$/.test(r)&&(c=!0)),this.options.gfm&&(n=/^\[[ xX]\] /.exec(d),n&&(i=n[0]!=="[ ] ",d=d.replace(/^\[[ xX]\] +/,""))),u.items.push({type:"list_item",raw:r,task:!!n,checked:i,loose:!1,text:d}),u.raw+=r}u.items[u.items.length-1].raw=r.trimRight(),u.items[u.items.length-1].text=d.trimRight(),u.raw=u.raw.trimRight();let m=u.items.length;for(o=0;oy.type==="space"),x=M.every(y=>{let w=y.raw.split(""),V=0;for(let R of w)if(R===` -`&&(V+=1),V>1)return!0;return!1});!u.loose&&M.length&&x&&(u.loose=!0,u.items[o].loose=!0)}return u}}html(a){let e=this.rules.block.html.exec(a);if(e){let r={type:"html",raw:e[0],pre:!this.options.sanitizer&&(e[1]==="pre"||e[1]==="script"||e[1]==="style"),text:e[0]};if(this.options.sanitize){let n=this.options.sanitizer?this.options.sanitizer(e[0]):C0(e[0]);r.type="paragraph",r.text=n,r.tokens=this.lexer.inline(n)}return r}}def(a){let e=this.rules.block.def.exec(a);if(e)return e[3]&&(e[3]=e[3].substring(1,e[3].length-1)),{type:"def",tag:e[1].toLowerCase().replace(/\s+/g," "),raw:e[0],href:e[2]?e[2].replace(this.rules.inline._escapes,"$1"):e[2],title:e[3]?e[3].replace(this.rules.inline._escapes,"$1"):e[3]}}table(a){let e=this.rules.block.table.exec(a);if(e){let r={type:"table",header:Jf(e[1]).map(n=>({text:n})),align:e[2].replace(/^ *|\| *$/g,"").split(/ *\| */),rows:e[3]&&e[3].trim()?e[3].replace(/\n[ \t]*$/,"").split(` -`):[]};if(r.header.length===r.align.length){r.raw=e[0];let n=r.align.length,i,l,o,h;for(i=0;i({text:c}));for(n=r.header.length,l=0;l/i.test(e[0])&&(this.lexer.state.inLink=!1),!this.lexer.state.inRawBlock&&/^<(pre|code|kbd|script)(\s|>)/i.test(e[0])?this.lexer.state.inRawBlock=!0:this.lexer.state.inRawBlock&&/^<\/(pre|code|kbd|script)(\s|>)/i.test(e[0])&&(this.lexer.state.inRawBlock=!1),{type:this.options.sanitize?"text":"html",raw:e[0],inLink:this.lexer.state.inLink,inRawBlock:this.lexer.state.inRawBlock,text:this.options.sanitize?this.options.sanitizer?this.options.sanitizer(e[0]):C0(e[0]):e[0]}}link(a){let e=this.rules.inline.link.exec(a);if(e){let r=e[2].trim();if(!this.options.pedantic&&/^$/.test(r))return;let l=p5(r.slice(0,-1),"\\");if((r.length-l.length)%2===0)return}else{let l=MF(e[2],"()");if(l>-1){let h=(e[0].indexOf("!")===0?5:4)+e[1].length+l;e[2]=e[2].substring(0,l),e[0]=e[0].substring(0,h).trim(),e[3]=""}}let n=e[2],i="";if(this.options.pedantic){let l=/^([^'"]*[^\s])\s+(['"])(.*)\2/.exec(n);l&&(n=l[1],i=l[3])}else i=e[3]?e[3].slice(1,-1):"";return n=n.trim(),/^$/.test(r)?n=n.slice(1):n=n.slice(1,-1)),ap(e,{href:n&&n.replace(this.rules.inline._escapes,"$1"),title:i&&i.replace(this.rules.inline._escapes,"$1")},e[0],this.lexer)}}reflink(a,e){let r;if((r=this.rules.inline.reflink.exec(a))||(r=this.rules.inline.nolink.exec(a))){let n=(r[2]||r[1]).replace(/\s+/g," ");if(n=e[n.toLowerCase()],!n||!n.href){let i=r[0].charAt(0);return{type:"text",raw:i,text:i}}return ap(r,n,r[0],this.lexer)}}emStrong(a,e,r=""){let n=this.rules.inline.emStrong.lDelim.exec(a);if(!n||n[3]&&r.match(/[\p{L}\p{N}]/u))return;let i=n[1]||n[2]||"";if(!i||i&&(r===""||this.rules.inline.punctuation.exec(r))){let l=n[0].length-1,o,h,c=l,v=0,g=n[0][0]==="*"?this.rules.inline.emStrong.rDelimAst:this.rules.inline.emStrong.rDelimUnd;for(g.lastIndex=0,e=e.slice(-1*a.length+l);(n=g.exec(e))!=null;){if(o=n[1]||n[2]||n[3]||n[4]||n[5]||n[6],!o)continue;if(h=o.length,n[3]||n[4]){c+=h;continue}else if((n[5]||n[6])&&l%3&&!((l+h)%3)){v+=h;continue}if(c-=h,c>0)continue;h=Math.min(h,h+c+v);let s=a.slice(0,l+n.index+(n[0].length-o.length)+h);if(Math.min(l,h)%2){let p=s.slice(1,-1);return{type:"em",raw:s,text:p,tokens:this.lexer.inlineTokens(p)}}let d=s.slice(2,-2);return{type:"strong",raw:s,text:d,tokens:this.lexer.inlineTokens(d)}}}}codespan(a){let e=this.rules.inline.code.exec(a);if(e){let r=e[2].replace(/\n/g," "),n=/[^ ]/.test(r),i=/^ /.test(r)&&/ $/.test(r);return n&&i&&(r=r.substring(1,r.length-1)),r=C0(r,!0),{type:"codespan",raw:e[0],text:r}}}br(a){let e=this.rules.inline.br.exec(a);if(e)return{type:"br",raw:e[0]}}del(a){let e=this.rules.inline.del.exec(a);if(e)return{type:"del",raw:e[0],text:e[2],tokens:this.lexer.inlineTokens(e[2])}}autolink(a,e){let r=this.rules.inline.autolink.exec(a);if(r){let n,i;return r[2]==="@"?(n=C0(this.options.mangle?e(r[1]):r[1]),i="mailto:"+n):(n=C0(r[1]),i=n),{type:"link",raw:r[0],text:n,href:i,tokens:[{type:"text",raw:n,text:n}]}}}url(a,e){let r;if(r=this.rules.inline.url.exec(a)){let n,i;if(r[2]==="@")n=C0(this.options.mangle?e(r[0]):r[0]),i="mailto:"+n;else{let l;do l=r[0],r[0]=this.rules.inline._backpedal.exec(r[0])[0];while(l!==r[0]);n=C0(r[0]),r[1]==="www."?i="http://"+n:i=n}return{type:"link",raw:r[0],text:n,href:i,tokens:[{type:"text",raw:n,text:n}]}}}inlineText(a,e){let r=this.rules.inline.text.exec(a);if(r){let n;return this.lexer.state.inRawBlock?n=this.options.sanitize?this.options.sanitizer?this.options.sanitizer(r[0]):C0(r[0]):r[0]:n=C0(this.options.smartypants?e(r[0]):r[0]),{type:"text",raw:r[0],text:n}}}},E1={newline:/^(?: *(?:\n|$))+/,code:/^( {4}[^\n]+(?:\n(?: *(?:\n|$))*)?)+/,fences:/^ {0,3}(`{3,}(?=[^`\n]*\n)|~{3,})([^\n]*)\n(?:|([\s\S]*?)\n)(?: {0,3}\1[~`]* *(?=\n|$)|$)/,hr:/^ {0,3}((?:-[\t ]*){3,}|(?:_[ \t]*){3,}|(?:\*[ \t]*){3,})(?:\n+|$)/,heading:/^ {0,3}(#{1,6})(?=\s|$)(.*)(?:\n+|$)/,blockquote:/^( {0,3}> ?(paragraph|[^\n]*)(?:\n|$))+/,list:/^( {0,3}bull)([ \t][^\n]+?)?(?:\n|$)/,html:"^ {0,3}(?:<(script|pre|style|textarea)[\\s>][\\s\\S]*?(?:[^\\n]*\\n+|$)|comment[^\\n]*(\\n+|$)|<\\?[\\s\\S]*?(?:\\?>\\n*|$)|\\n*|$)|\\n*|$)|)[\\s\\S]*?(?:(?:\\n *)+\\n|$)|<(?!script|pre|style|textarea)([a-z][\\w-]*)(?:attribute)*? */?>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n *)+\\n|$)|(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n *)+\\n|$))",def:/^ {0,3}\[(label)\]: *(?:\n *)?]+)>?(?:(?: +(?:\n *)?| *\n *)(title))? *(?:\n+|$)/,table:z5,lheading:/^([^\n]+)\n {0,3}(=+|-+) *(?:\n+|$)/,_paragraph:/^([^\n]+(?:\n(?!hr|heading|lheading|blockquote|fences|list|html|table| +\n)[^\n]+)*)/,text:/^[^\n]+/};E1._label=/(?!\s*\])(?:\\.|[^\[\]\\])+/;E1._title=/(?:"(?:\\"?|[^"\\])*"|'[^'\n]*(?:\n[^'\n]+)*\n?'|\([^()]*\))/;E1.def=Ft(E1.def).replace("label",E1._label).replace("title",E1._title).getRegex();E1.bullet=/(?:[*+-]|\d{1,9}[.)])/;E1.listItemStart=Ft(/^( *)(bull) */).replace("bull",E1.bullet).getRegex();E1.list=Ft(E1.list).replace(/bull/g,E1.bullet).replace("hr","\\n+(?=\\1?(?:(?:- *){3,}|(?:_ *){3,}|(?:\\* *){3,})(?:\\n+|$))").replace("def","\\n+(?="+E1.def.source+")").getRegex();E1._tag="address|article|aside|base|basefont|blockquote|body|caption|center|col|colgroup|dd|details|dialog|dir|div|dl|dt|fieldset|figcaption|figure|footer|form|frame|frameset|h[1-6]|head|header|hr|html|iframe|legend|li|link|main|menu|menuitem|meta|nav|noframes|ol|optgroup|option|p|param|section|source|summary|table|tbody|td|tfoot|th|thead|title|tr|track|ul";E1._comment=/|$)/;E1.html=Ft(E1.html,"i").replace("comment",E1._comment).replace("tag",E1._tag).replace("attribute",/ +[a-zA-Z:_][\w.:-]*(?: *= *"[^"\n]*"| *= *'[^'\n]*'| *= *[^\s"'=<>`]+)?/).getRegex();E1.paragraph=Ft(E1._paragraph).replace("hr",E1.hr).replace("heading"," {0,3}#{1,6} ").replace("|lheading","").replace("|table","").replace("blockquote"," {0,3}>").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html",")|<(?:script|pre|style|textarea|!--)").replace("tag",E1._tag).getRegex();E1.blockquote=Ft(E1.blockquote).replace("paragraph",E1.paragraph).getRegex();E1.normal=Y2({},E1);E1.gfm=Y2({},E1.normal,{table:"^ *([^\\n ].*\\|.*)\\n {0,3}(?:\\| *)?(:?-+:? *(?:\\| *:?-+:? *)*)(?:\\| *)?(?:\\n((?:(?! *\\n|hr|heading|blockquote|code|fences|list|html).*(?:\\n|$))*)\\n*|$)"});E1.gfm.table=Ft(E1.gfm.table).replace("hr",E1.hr).replace("heading"," {0,3}#{1,6} ").replace("blockquote"," {0,3}>").replace("code"," {4}[^\\n]").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html",")|<(?:script|pre|style|textarea|!--)").replace("tag",E1._tag).getRegex();E1.gfm.paragraph=Ft(E1._paragraph).replace("hr",E1.hr).replace("heading"," {0,3}#{1,6} ").replace("|lheading","").replace("table",E1.gfm.table).replace("blockquote"," {0,3}>").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html",")|<(?:script|pre|style|textarea|!--)").replace("tag",E1._tag).getRegex();E1.pedantic=Y2({},E1.normal,{html:Ft(`^ *(?:comment *(?:\\n|\\s*$)|<(tag)[\\s\\S]+? *(?:\\n{2,}|\\s*$)|\\s]*)*?/?> *(?:\\n{2,}|\\s*$))`).replace("comment",E1._comment).replace(/tag/g,"(?!(?:a|em|strong|small|s|cite|q|dfn|abbr|data|time|code|var|samp|kbd|sub|sup|i|b|u|mark|ruby|rt|rp|bdi|bdo|span|br|wbr|ins|del|img)\\b)\\w+(?!:|[^\\w\\s@]*@)\\b").getRegex(),def:/^ *\[([^\]]+)\]: *]+)>?(?: +(["(][^\n]+[")]))? *(?:\n+|$)/,heading:/^(#{1,6})(.*)(?:\n+|$)/,fences:z5,paragraph:Ft(E1.normal._paragraph).replace("hr",E1.hr).replace("heading",` *#{1,6} *[^ -]`).replace("lheading",E1.lheading).replace("blockquote"," {0,3}>").replace("|fences","").replace("|list","").replace("|html","").getRegex()});var R1={escape:/^\\([!"#$%&'()*+,\-./:;<=>?@\[\]\\^_`{|}~])/,autolink:/^<(scheme:[^\s\x00-\x1f<>]*|email)>/,url:z5,tag:"^comment|^|^<[a-zA-Z][\\w-]*(?:attribute)*?\\s*/?>|^<\\?[\\s\\S]*?\\?>|^|^",link:/^!?\[(label)\]\(\s*(href)(?:\s+(title))?\s*\)/,reflink:/^!?\[(label)\]\[(ref)\]/,nolink:/^!?\[(ref)\](?:\[\])?/,reflinkSearch:"reflink|nolink(?!\\()",emStrong:{lDelim:/^(?:\*+(?:([punct_])|[^\s*]))|^_+(?:([punct*])|([^\s_]))/,rDelimAst:/^(?:[^_*\\]|\\.)*?\_\_(?:[^_*\\]|\\.)*?\*(?:[^_*\\]|\\.)*?(?=\_\_)|(?:[^*\\]|\\.)+(?=[^*])|[punct_](\*+)(?=[\s]|$)|(?:[^punct*_\s\\]|\\.)(\*+)(?=[punct_\s]|$)|[punct_\s](\*+)(?=[^punct*_\s])|[\s](\*+)(?=[punct_])|[punct_](\*+)(?=[punct_])|(?:[^punct*_\s\\]|\\.)(\*+)(?=[^punct*_\s])/,rDelimUnd:/^(?:[^_*\\]|\\.)*?\*\*(?:[^_*\\]|\\.)*?\_(?:[^_*\\]|\\.)*?(?=\*\*)|(?:[^_\\]|\\.)+(?=[^_])|[punct*](\_+)(?=[\s]|$)|(?:[^punct*_\s\\]|\\.)(\_+)(?=[punct*\s]|$)|[punct*\s](\_+)(?=[^punct*_\s])|[\s](\_+)(?=[punct*])|[punct*](\_+)(?=[punct*])/},code:/^(`+)([^`]|[^`][\s\S]*?[^`])\1(?!`)/,br:/^( {2,}|\\)\n(?!\s*$)/,del:z5,text:/^(`+|[^`])(?:(?= {2,}\n)|[\s\S]*?(?:(?=[\\?@\\[\\]`^{|}~";R1.punctuation=Ft(R1.punctuation).replace(/punctuation/g,R1._punctuation).getRegex();R1.blockSkip=/\[[^\]]*?\]\([^\)]*?\)|`[^`]*?`|<[^>]*?>/g;R1.escapedEmSt=/(?:^|[^\\])(?:\\\\)*\\[*_]/g;R1._comment=Ft(E1._comment).replace("(?:-->|$)","-->").getRegex();R1.emStrong.lDelim=Ft(R1.emStrong.lDelim).replace(/punct/g,R1._punctuation).getRegex();R1.emStrong.rDelimAst=Ft(R1.emStrong.rDelimAst,"g").replace(/punct/g,R1._punctuation).getRegex();R1.emStrong.rDelimUnd=Ft(R1.emStrong.rDelimUnd,"g").replace(/punct/g,R1._punctuation).getRegex();R1._escapes=/\\([!"#$%&'()*+,\-./:;<=>?@\[\]\\^_`{|}~])/g;R1._scheme=/[a-zA-Z][a-zA-Z0-9+.-]{1,31}/;R1._email=/[a-zA-Z0-9.!#$%&'*+/=?^_`{|}~-]+(@)[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)+(?![-_])/;R1.autolink=Ft(R1.autolink).replace("scheme",R1._scheme).replace("email",R1._email).getRegex();R1._attribute=/\s+[a-zA-Z:_][\w.:-]*(?:\s*=\s*"[^"]*"|\s*=\s*'[^']*'|\s*=\s*[^\s"'=<>`]+)?/;R1.tag=Ft(R1.tag).replace("comment",R1._comment).replace("attribute",R1._attribute).getRegex();R1._label=/(?:\[(?:\\.|[^\[\]\\])*\]|\\.|`[^`]*`|[^\[\]\\`])*?/;R1._href=/<(?:\\.|[^\n<>\\])+>|[^\s\x00-\x1f]*/;R1._title=/"(?:\\"?|[^"\\])*"|'(?:\\'?|[^'\\])*'|\((?:\\\)?|[^)\\])*\)/;R1.link=Ft(R1.link).replace("label",R1._label).replace("href",R1._href).replace("title",R1._title).getRegex();R1.reflink=Ft(R1.reflink).replace("label",R1._label).replace("ref",E1._label).getRegex();R1.nolink=Ft(R1.nolink).replace("ref",E1._label).getRegex();R1.reflinkSearch=Ft(R1.reflinkSearch,"g").replace("reflink",R1.reflink).replace("nolink",R1.nolink).getRegex();R1.normal=Y2({},R1);R1.pedantic=Y2({},R1.normal,{strong:{start:/^__|\*\*/,middle:/^__(?=\S)([\s\S]*?\S)__(?!_)|^\*\*(?=\S)([\s\S]*?\S)\*\*(?!\*)/,endAst:/\*\*(?!\*)/g,endUnd:/__(?!_)/g},em:{start:/^_|\*/,middle:/^()\*(?=\S)([\s\S]*?\S)\*(?!\*)|^_(?=\S)([\s\S]*?\S)_(?!_)/,endAst:/\*(?!\*)/g,endUnd:/_(?!_)/g},link:Ft(/^!?\[(label)\]\((.*?)\)/).replace("label",R1._label).getRegex(),reflink:Ft(/^!?\[(label)\]\s*\[([^\]]*)\]/).replace("label",R1._label).getRegex()});R1.gfm=Y2({},R1.normal,{escape:Ft(R1.escape).replace("])","~|])").getRegex(),_extended_email:/[A-Za-z0-9._+-]+(@)[a-zA-Z0-9-_]+(?:\.[a-zA-Z0-9-_]*[a-zA-Z0-9])+(?![-_])/,url:/^((?:ftp|https?):\/\/|www\.)(?:[a-zA-Z0-9\-]+\.?)+[^\s<]*|^email/,_backpedal:/(?:[^?!.,:;*_~()&]+|\([^)]*\)|&(?![a-zA-Z0-9]+;$)|[?!.,:;*_~)]+(?!$))+/,del:/^(~~?)(?=[^\s~])([\s\S]*?[^\s~])\1(?=[^~]|$)/,text:/^([`~]+|[^`~])(?:(?= {2,}\n)|(?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)|[\s\S]*?(?:(?=[\\.5&&(r="x"+r.toString(16)),a+="&#"+r+";";return a}var X2=class{constructor(a){this.tokens=[],this.tokens.links=Object.create(null),this.options=a||hr,this.options.tokenizer=this.options.tokenizer||new $n,this.tokenizer=this.options.tokenizer,this.tokenizer.options=this.options,this.tokenizer.lexer=this,this.inlineQueue=[],this.state={inLink:!1,inRawBlock:!1,top:!0};let e={block:E1.normal,inline:R1.normal};this.options.pedantic?(e.block=E1.pedantic,e.inline=R1.pedantic):this.options.gfm&&(e.block=E1.gfm,this.options.breaks?e.inline=R1.breaks:e.inline=R1.gfm),this.tokenizer.rules=e}static get rules(){return{block:E1,inline:R1}}static lex(a,e){return new X2(e).lex(a)}static lexInline(a,e){return new X2(e).inlineTokens(a)}lex(a){a=a.replace(/\r\n|\r/g,` +`,1)[0],this.options.pedantic?(l=2,u=v.trimLeft()):(l=e[2].search(/[^ ]/),l=l>4?1:l,u=v.slice(l),l+=e[1].length),h=!1,!v&&/^ *$/.test(g)&&(r+=g+` +`,a=a.substring(g.length+1),p=!0),!p){let H=new RegExp(`^ {0,${Math.min(3,l-1)}}(?:[*+-]|\\d{1,9}[.)])((?: [^\\n]*)?(?:\\n|$))`),x=new RegExp(`^ {0,${Math.min(3,l-1)}}((?:- *){3,}|(?:_ *){3,}|(?:\\* *){3,})(?:\\n+|$)`),y=new RegExp(`^ {0,${Math.min(3,l-1)}}(?:\`\`\`|~~~)`),R=new RegExp(`^ {0,${Math.min(3,l-1)}}#`);for(;a&&(d=a.split(` +`,1)[0],v=d,this.options.pedantic&&(v=v.replace(/^ {1,4}(?=( {4})*[^ ])/g," ")),!(y.test(v)||R.test(v)||H.test(v)||x.test(a)));){if(v.search(/[^ ]/)>=l||!v.trim())u+=` +`+v.slice(l);else if(!h)u+=` +`+v;else break;!h&&!v.trim()&&(h=!0),r+=d+` +`,a=a.substring(d.length+1)}}s.loose||(c?s.loose=!0:/\n *\n *$/.test(r)&&(c=!0)),this.options.gfm&&(n=/^\[[ xX]\] /.exec(u),n&&(i=n[0]!=="[ ] ",u=u.replace(/^\[[ xX]\] +/,""))),s.items.push({type:"list_item",raw:r,task:!!n,checked:i,loose:!1,text:u}),s.raw+=r}s.items[s.items.length-1].raw=r.trimRight(),s.items[s.items.length-1].text=u.trimRight(),s.raw=s.raw.trimRight();let m=s.items.length;for(o=0;oy.type==="space"),x=H.every(y=>{let R=y.raw.split(""),L=0;for(let V of R)if(V===` +`&&(L+=1),L>1)return!0;return!1});!s.loose&&H.length&&x&&(s.loose=!0,s.items[o].loose=!0)}return s}}html(a){let e=this.rules.block.html.exec(a);if(e){let r={type:"html",raw:e[0],pre:!this.options.sanitizer&&(e[1]==="pre"||e[1]==="script"||e[1]==="style"),text:e[0]};if(this.options.sanitize){let n=this.options.sanitizer?this.options.sanitizer(e[0]):V0(e[0]);r.type="paragraph",r.text=n,r.tokens=this.lexer.inline(n)}return r}}def(a){let e=this.rules.block.def.exec(a);if(e)return e[3]&&(e[3]=e[3].substring(1,e[3].length-1)),{type:"def",tag:e[1].toLowerCase().replace(/\s+/g," "),raw:e[0],href:e[2]?e[2].replace(this.rules.inline._escapes,"$1"):e[2],title:e[3]?e[3].replace(this.rules.inline._escapes,"$1"):e[3]}}table(a){let e=this.rules.block.table.exec(a);if(e){let r={type:"table",header:hp(e[1]).map(n=>({text:n})),align:e[2].replace(/^ *|\| *$/g,"").split(/ *\| */),rows:e[3]&&e[3].trim()?e[3].replace(/\n[ \t]*$/,"").split(` +`):[]};if(r.header.length===r.align.length){r.raw=e[0];let n=r.align.length,i,l,o,h;for(i=0;i({text:c}));for(n=r.header.length,l=0;l/i.test(e[0])&&(this.lexer.state.inLink=!1),!this.lexer.state.inRawBlock&&/^<(pre|code|kbd|script)(\s|>)/i.test(e[0])?this.lexer.state.inRawBlock=!0:this.lexer.state.inRawBlock&&/^<\/(pre|code|kbd|script)(\s|>)/i.test(e[0])&&(this.lexer.state.inRawBlock=!1),{type:this.options.sanitize?"text":"html",raw:e[0],inLink:this.lexer.state.inLink,inRawBlock:this.lexer.state.inRawBlock,text:this.options.sanitize?this.options.sanitizer?this.options.sanitizer(e[0]):V0(e[0]):e[0]}}link(a){let e=this.rules.inline.link.exec(a);if(e){let r=e[2].trim();if(!this.options.pedantic&&/^$/.test(r))return;let l=w5(r.slice(0,-1),"\\");if((r.length-l.length)%2===0)return}else{let l=TF(e[2],"()");if(l>-1){let h=(e[0].indexOf("!")===0?5:4)+e[1].length+l;e[2]=e[2].substring(0,l),e[0]=e[0].substring(0,h).trim(),e[3]=""}}let n=e[2],i="";if(this.options.pedantic){let l=/^([^'"]*[^\s])\s+(['"])(.*)\2/.exec(n);l&&(n=l[1],i=l[3])}else i=e[3]?e[3].slice(1,-1):"";return n=n.trim(),/^$/.test(r)?n=n.slice(1):n=n.slice(1,-1)),vp(e,{href:n&&n.replace(this.rules.inline._escapes,"$1"),title:i&&i.replace(this.rules.inline._escapes,"$1")},e[0],this.lexer)}}reflink(a,e){let r;if((r=this.rules.inline.reflink.exec(a))||(r=this.rules.inline.nolink.exec(a))){let n=(r[2]||r[1]).replace(/\s+/g," ");if(n=e[n.toLowerCase()],!n||!n.href){let i=r[0].charAt(0);return{type:"text",raw:i,text:i}}return vp(r,n,r[0],this.lexer)}}emStrong(a,e,r=""){let n=this.rules.inline.emStrong.lDelim.exec(a);if(!n||n[3]&&r.match(/[\p{L}\p{N}]/u))return;let i=n[1]||n[2]||"";if(!i||i&&(r===""||this.rules.inline.punctuation.exec(r))){let l=n[0].length-1,o,h,c=l,v=0,g=n[0][0]==="*"?this.rules.inline.emStrong.rDelimAst:this.rules.inline.emStrong.rDelimUnd;for(g.lastIndex=0,e=e.slice(-1*a.length+l);(n=g.exec(e))!=null;){if(o=n[1]||n[2]||n[3]||n[4]||n[5]||n[6],!o)continue;if(h=o.length,n[3]||n[4]){c+=h;continue}else if((n[5]||n[6])&&l%3&&!((l+h)%3)){v+=h;continue}if(c-=h,c>0)continue;h=Math.min(h,h+c+v);let d=a.slice(0,l+n.index+(n[0].length-o.length)+h);if(Math.min(l,h)%2){let p=d.slice(1,-1);return{type:"em",raw:d,text:p,tokens:this.lexer.inlineTokens(p)}}let u=d.slice(2,-2);return{type:"strong",raw:d,text:u,tokens:this.lexer.inlineTokens(u)}}}}codespan(a){let e=this.rules.inline.code.exec(a);if(e){let r=e[2].replace(/\n/g," "),n=/[^ ]/.test(r),i=/^ /.test(r)&&/ $/.test(r);return n&&i&&(r=r.substring(1,r.length-1)),r=V0(r,!0),{type:"codespan",raw:e[0],text:r}}}br(a){let e=this.rules.inline.br.exec(a);if(e)return{type:"br",raw:e[0]}}del(a){let e=this.rules.inline.del.exec(a);if(e)return{type:"del",raw:e[0],text:e[2],tokens:this.lexer.inlineTokens(e[2])}}autolink(a,e){let r=this.rules.inline.autolink.exec(a);if(r){let n,i;return r[2]==="@"?(n=V0(this.options.mangle?e(r[1]):r[1]),i="mailto:"+n):(n=V0(r[1]),i=n),{type:"link",raw:r[0],text:n,href:i,tokens:[{type:"text",raw:n,text:n}]}}}url(a,e){let r;if(r=this.rules.inline.url.exec(a)){let n,i;if(r[2]==="@")n=V0(this.options.mangle?e(r[0]):r[0]),i="mailto:"+n;else{let l;do l=r[0],r[0]=this.rules.inline._backpedal.exec(r[0])[0];while(l!==r[0]);n=V0(r[0]),r[1]==="www."?i="http://"+n:i=n}return{type:"link",raw:r[0],text:n,href:i,tokens:[{type:"text",raw:n,text:n}]}}}inlineText(a,e){let r=this.rules.inline.text.exec(a);if(r){let n;return this.lexer.state.inRawBlock?n=this.options.sanitize?this.options.sanitizer?this.options.sanitizer(r[0]):V0(r[0]):r[0]:n=V0(this.options.smartypants?e(r[0]):r[0]),{type:"text",raw:r[0],text:n}}}},O1={newline:/^(?: *(?:\n|$))+/,code:/^( {4}[^\n]+(?:\n(?: *(?:\n|$))*)?)+/,fences:/^ {0,3}(`{3,}(?=[^`\n]*\n)|~{3,})([^\n]*)\n(?:|([\s\S]*?)\n)(?: {0,3}\1[~`]* *(?=\n|$)|$)/,hr:/^ {0,3}((?:-[\t ]*){3,}|(?:_[ \t]*){3,}|(?:\*[ \t]*){3,})(?:\n+|$)/,heading:/^ {0,3}(#{1,6})(?=\s|$)(.*)(?:\n+|$)/,blockquote:/^( {0,3}> ?(paragraph|[^\n]*)(?:\n|$))+/,list:/^( {0,3}bull)([ \t][^\n]+?)?(?:\n|$)/,html:"^ {0,3}(?:<(script|pre|style|textarea)[\\s>][\\s\\S]*?(?:[^\\n]*\\n+|$)|comment[^\\n]*(\\n+|$)|<\\?[\\s\\S]*?(?:\\?>\\n*|$)|\\n*|$)|\\n*|$)|)[\\s\\S]*?(?:(?:\\n *)+\\n|$)|<(?!script|pre|style|textarea)([a-z][\\w-]*)(?:attribute)*? */?>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n *)+\\n|$)|(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n *)+\\n|$))",def:/^ {0,3}\[(label)\]: *(?:\n *)?]+)>?(?:(?: +(?:\n *)?| *\n *)(title))? *(?:\n+|$)/,table:L5,lheading:/^([^\n]+)\n {0,3}(=+|-+) *(?:\n+|$)/,_paragraph:/^([^\n]+(?:\n(?!hr|heading|lheading|blockquote|fences|list|html|table| +\n)[^\n]+)*)/,text:/^[^\n]+/};O1._label=/(?!\s*\])(?:\\.|[^\[\]\\])+/;O1._title=/(?:"(?:\\"?|[^"\\])*"|'[^'\n]*(?:\n[^'\n]+)*\n?'|\([^()]*\))/;O1.def=bt(O1.def).replace("label",O1._label).replace("title",O1._title).getRegex();O1.bullet=/(?:[*+-]|\d{1,9}[.)])/;O1.listItemStart=bt(/^( *)(bull) */).replace("bull",O1.bullet).getRegex();O1.list=bt(O1.list).replace(/bull/g,O1.bullet).replace("hr","\\n+(?=\\1?(?:(?:- *){3,}|(?:_ *){3,}|(?:\\* *){3,})(?:\\n+|$))").replace("def","\\n+(?="+O1.def.source+")").getRegex();O1._tag="address|article|aside|base|basefont|blockquote|body|caption|center|col|colgroup|dd|details|dialog|dir|div|dl|dt|fieldset|figcaption|figure|footer|form|frame|frameset|h[1-6]|head|header|hr|html|iframe|legend|li|link|main|menu|menuitem|meta|nav|noframes|ol|optgroup|option|p|param|section|source|summary|table|tbody|td|tfoot|th|thead|title|tr|track|ul";O1._comment=/|$)/;O1.html=bt(O1.html,"i").replace("comment",O1._comment).replace("tag",O1._tag).replace("attribute",/ +[a-zA-Z:_][\w.:-]*(?: *= *"[^"\n]*"| *= *'[^'\n]*'| *= *[^\s"'=<>`]+)?/).getRegex();O1.paragraph=bt(O1._paragraph).replace("hr",O1.hr).replace("heading"," {0,3}#{1,6} ").replace("|lheading","").replace("|table","").replace("blockquote"," {0,3}>").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html",")|<(?:script|pre|style|textarea|!--)").replace("tag",O1._tag).getRegex();O1.blockquote=bt(O1.blockquote).replace("paragraph",O1.paragraph).getRegex();O1.normal=aa({},O1);O1.gfm=aa({},O1.normal,{table:"^ *([^\\n ].*\\|.*)\\n {0,3}(?:\\| *)?(:?-+:? *(?:\\| *:?-+:? *)*)(?:\\| *)?(?:\\n((?:(?! *\\n|hr|heading|blockquote|code|fences|list|html).*(?:\\n|$))*)\\n*|$)"});O1.gfm.table=bt(O1.gfm.table).replace("hr",O1.hr).replace("heading"," {0,3}#{1,6} ").replace("blockquote"," {0,3}>").replace("code"," {4}[^\\n]").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html",")|<(?:script|pre|style|textarea|!--)").replace("tag",O1._tag).getRegex();O1.gfm.paragraph=bt(O1._paragraph).replace("hr",O1.hr).replace("heading"," {0,3}#{1,6} ").replace("|lheading","").replace("table",O1.gfm.table).replace("blockquote"," {0,3}>").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html",")|<(?:script|pre|style|textarea|!--)").replace("tag",O1._tag).getRegex();O1.pedantic=aa({},O1.normal,{html:bt(`^ *(?:comment *(?:\\n|\\s*$)|<(tag)[\\s\\S]+? *(?:\\n{2,}|\\s*$)|\\s]*)*?/?> *(?:\\n{2,}|\\s*$))`).replace("comment",O1._comment).replace(/tag/g,"(?!(?:a|em|strong|small|s|cite|q|dfn|abbr|data|time|code|var|samp|kbd|sub|sup|i|b|u|mark|ruby|rt|rp|bdi|bdo|span|br|wbr|ins|del|img)\\b)\\w+(?!:|[^\\w\\s@]*@)\\b").getRegex(),def:/^ *\[([^\]]+)\]: *]+)>?(?: +(["(][^\n]+[")]))? *(?:\n+|$)/,heading:/^(#{1,6})(.*)(?:\n+|$)/,fences:L5,paragraph:bt(O1.normal._paragraph).replace("hr",O1.hr).replace("heading",` *#{1,6} *[^ +]`).replace("lheading",O1.lheading).replace("blockquote"," {0,3}>").replace("|fences","").replace("|list","").replace("|html","").getRegex()});var R1={escape:/^\\([!"#$%&'()*+,\-./:;<=>?@\[\]\\^_`{|}~])/,autolink:/^<(scheme:[^\s\x00-\x1f<>]*|email)>/,url:L5,tag:"^comment|^|^<[a-zA-Z][\\w-]*(?:attribute)*?\\s*/?>|^<\\?[\\s\\S]*?\\?>|^|^",link:/^!?\[(label)\]\(\s*(href)(?:\s+(title))?\s*\)/,reflink:/^!?\[(label)\]\[(ref)\]/,nolink:/^!?\[(ref)\](?:\[\])?/,reflinkSearch:"reflink|nolink(?!\\()",emStrong:{lDelim:/^(?:\*+(?:([punct_])|[^\s*]))|^_+(?:([punct*])|([^\s_]))/,rDelimAst:/^(?:[^_*\\]|\\.)*?\_\_(?:[^_*\\]|\\.)*?\*(?:[^_*\\]|\\.)*?(?=\_\_)|(?:[^*\\]|\\.)+(?=[^*])|[punct_](\*+)(?=[\s]|$)|(?:[^punct*_\s\\]|\\.)(\*+)(?=[punct_\s]|$)|[punct_\s](\*+)(?=[^punct*_\s])|[\s](\*+)(?=[punct_])|[punct_](\*+)(?=[punct_])|(?:[^punct*_\s\\]|\\.)(\*+)(?=[^punct*_\s])/,rDelimUnd:/^(?:[^_*\\]|\\.)*?\*\*(?:[^_*\\]|\\.)*?\_(?:[^_*\\]|\\.)*?(?=\*\*)|(?:[^_\\]|\\.)+(?=[^_])|[punct*](\_+)(?=[\s]|$)|(?:[^punct*_\s\\]|\\.)(\_+)(?=[punct*\s]|$)|[punct*\s](\_+)(?=[^punct*_\s])|[\s](\_+)(?=[punct*])|[punct*](\_+)(?=[punct*])/},code:/^(`+)([^`]|[^`][\s\S]*?[^`])\1(?!`)/,br:/^( {2,}|\\)\n(?!\s*$)/,del:L5,text:/^(`+|[^`])(?:(?= {2,}\n)|[\s\S]*?(?:(?=[\\?@\\[\\]`^{|}~";R1.punctuation=bt(R1.punctuation).replace(/punctuation/g,R1._punctuation).getRegex();R1.blockSkip=/\[[^\]]*?\]\([^\)]*?\)|`[^`]*?`|<[^>]*?>/g;R1.escapedEmSt=/(?:^|[^\\])(?:\\\\)*\\[*_]/g;R1._comment=bt(O1._comment).replace("(?:-->|$)","-->").getRegex();R1.emStrong.lDelim=bt(R1.emStrong.lDelim).replace(/punct/g,R1._punctuation).getRegex();R1.emStrong.rDelimAst=bt(R1.emStrong.rDelimAst,"g").replace(/punct/g,R1._punctuation).getRegex();R1.emStrong.rDelimUnd=bt(R1.emStrong.rDelimUnd,"g").replace(/punct/g,R1._punctuation).getRegex();R1._escapes=/\\([!"#$%&'()*+,\-./:;<=>?@\[\]\\^_`{|}~])/g;R1._scheme=/[a-zA-Z][a-zA-Z0-9+.-]{1,31}/;R1._email=/[a-zA-Z0-9.!#$%&'*+/=?^_`{|}~-]+(@)[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)+(?![-_])/;R1.autolink=bt(R1.autolink).replace("scheme",R1._scheme).replace("email",R1._email).getRegex();R1._attribute=/\s+[a-zA-Z:_][\w.:-]*(?:\s*=\s*"[^"]*"|\s*=\s*'[^']*'|\s*=\s*[^\s"'=<>`]+)?/;R1.tag=bt(R1.tag).replace("comment",R1._comment).replace("attribute",R1._attribute).getRegex();R1._label=/(?:\[(?:\\.|[^\[\]\\])*\]|\\.|`[^`]*`|[^\[\]\\`])*?/;R1._href=/<(?:\\.|[^\n<>\\])+>|[^\s\x00-\x1f]*/;R1._title=/"(?:\\"?|[^"\\])*"|'(?:\\'?|[^'\\])*'|\((?:\\\)?|[^)\\])*\)/;R1.link=bt(R1.link).replace("label",R1._label).replace("href",R1._href).replace("title",R1._title).getRegex();R1.reflink=bt(R1.reflink).replace("label",R1._label).replace("ref",O1._label).getRegex();R1.nolink=bt(R1.nolink).replace("ref",O1._label).getRegex();R1.reflinkSearch=bt(R1.reflinkSearch,"g").replace("reflink",R1.reflink).replace("nolink",R1.nolink).getRegex();R1.normal=aa({},R1);R1.pedantic=aa({},R1.normal,{strong:{start:/^__|\*\*/,middle:/^__(?=\S)([\s\S]*?\S)__(?!_)|^\*\*(?=\S)([\s\S]*?\S)\*\*(?!\*)/,endAst:/\*\*(?!\*)/g,endUnd:/__(?!_)/g},em:{start:/^_|\*/,middle:/^()\*(?=\S)([\s\S]*?\S)\*(?!\*)|^_(?=\S)([\s\S]*?\S)_(?!_)/,endAst:/\*(?!\*)/g,endUnd:/_(?!_)/g},link:bt(/^!?\[(label)\]\((.*?)\)/).replace("label",R1._label).getRegex(),reflink:bt(/^!?\[(label)\]\s*\[([^\]]*)\]/).replace("label",R1._label).getRegex()});R1.gfm=aa({},R1.normal,{escape:bt(R1.escape).replace("])","~|])").getRegex(),_extended_email:/[A-Za-z0-9._+-]+(@)[a-zA-Z0-9-_]+(?:\.[a-zA-Z0-9-_]*[a-zA-Z0-9])+(?![-_])/,url:/^((?:ftp|https?):\/\/|www\.)(?:[a-zA-Z0-9\-]+\.?)+[^\s<]*|^email/,_backpedal:/(?:[^?!.,:;*_~()&]+|\([^)]*\)|&(?![a-zA-Z0-9]+;$)|[?!.,:;*_~)]+(?!$))+/,del:/^(~~?)(?=[^\s~])([\s\S]*?[^\s~])\1(?=[^~]|$)/,text:/^([`~]+|[^`~])(?:(?= {2,}\n)|(?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)|[\s\S]*?(?:(?=[\\.5&&(r="x"+r.toString(16)),a+="&#"+r+";";return a}var ta=class{constructor(a){this.tokens=[],this.tokens.links=Object.create(null),this.options=a||hr,this.options.tokenizer=this.options.tokenizer||new Nn,this.tokenizer=this.options.tokenizer,this.tokenizer.options=this.options,this.tokenizer.lexer=this,this.inlineQueue=[],this.state={inLink:!1,inRawBlock:!1,top:!0};let e={block:O1.normal,inline:R1.normal};this.options.pedantic?(e.block=O1.pedantic,e.inline=R1.pedantic):this.options.gfm&&(e.block=O1.gfm,this.options.breaks?e.inline=R1.breaks:e.inline=R1.gfm),this.tokenizer.rules=e}static get rules(){return{block:O1,inline:R1}}static lex(a,e){return new ta(e).lex(a)}static lexInline(a,e){return new ta(e).inlineTokens(a)}lex(a){a=a.replace(/\r\n|\r/g,` `),this.blockTokens(a,this.tokens);let e;for(;e=this.inlineQueue.shift();)this.inlineTokens(e.src,e.tokens);return this.tokens}blockTokens(a,e=[]){this.options.pedantic?a=a.replace(/\t/g," ").replace(/^ +$/gm,""):a=a.replace(/^( *)(\t+)/gm,(o,h,c)=>h+" ".repeat(c.length));let r,n,i,l;for(;a;)if(!(this.options.extensions&&this.options.extensions.block&&this.options.extensions.block.some(o=>(r=o.call({lexer:this},a,e))?(a=a.substring(r.raw.length),e.push(r),!0):!1))){if(r=this.tokenizer.space(a)){a=a.substring(r.raw.length),r.raw.length===1&&e.length>0?e[e.length-1].raw+=` `:e.push(r);continue}if(r=this.tokenizer.code(a)){a=a.substring(r.raw.length),n=e[e.length-1],n&&(n.type==="paragraph"||n.type==="text")?(n.raw+=` `+r.raw,n.text+=` @@ -34,9 +34,9 @@ Error generating stack: `+i.message+` `+r.raw,n.text+=` `+r.text,this.inlineQueue.pop(),this.inlineQueue[this.inlineQueue.length-1].src=n.text):e.push(r),l=i.length!==a.length,a=a.substring(r.raw.length);continue}if(r=this.tokenizer.text(a)){a=a.substring(r.raw.length),n=e[e.length-1],n&&n.type==="text"?(n.raw+=` `+r.raw,n.text+=` -`+r.text,this.inlineQueue.pop(),this.inlineQueue[this.inlineQueue.length-1].src=n.text):e.push(r);continue}if(a){let o="Infinite loop on byte: "+a.charCodeAt(0);if(this.options.silent){console.error(o);break}else throw new Error(o)}}return this.state.top=!0,e}inline(a,e=[]){return this.inlineQueue.push({src:a,tokens:e}),e}inlineTokens(a,e=[]){let r,n,i,l=a,o,h,c;if(this.tokens.links){let v=Object.keys(this.tokens.links);if(v.length>0)for(;(o=this.tokenizer.rules.inline.reflinkSearch.exec(l))!=null;)v.includes(o[0].slice(o[0].lastIndexOf("[")+1,-1))&&(l=l.slice(0,o.index)+"["+tp("a",o[0].length-2)+"]"+l.slice(this.tokenizer.rules.inline.reflinkSearch.lastIndex))}for(;(o=this.tokenizer.rules.inline.blockSkip.exec(l))!=null;)l=l.slice(0,o.index)+"["+tp("a",o[0].length-2)+"]"+l.slice(this.tokenizer.rules.inline.blockSkip.lastIndex);for(;(o=this.tokenizer.rules.inline.escapedEmSt.exec(l))!=null;)l=l.slice(0,o.index+o[0].length-2)+"++"+l.slice(this.tokenizer.rules.inline.escapedEmSt.lastIndex),this.tokenizer.rules.inline.escapedEmSt.lastIndex--;for(;a;)if(h||(c=""),h=!1,!(this.options.extensions&&this.options.extensions.inline&&this.options.extensions.inline.some(v=>(r=v.call({lexer:this},a,e))?(a=a.substring(r.raw.length),e.push(r),!0):!1))){if(r=this.tokenizer.escape(a)){a=a.substring(r.raw.length),e.push(r);continue}if(r=this.tokenizer.tag(a)){a=a.substring(r.raw.length),n=e[e.length-1],n&&r.type==="text"&&n.type==="text"?(n.raw+=r.raw,n.text+=r.text):e.push(r);continue}if(r=this.tokenizer.link(a)){a=a.substring(r.raw.length),e.push(r);continue}if(r=this.tokenizer.reflink(a,this.tokens.links)){a=a.substring(r.raw.length),n=e[e.length-1],n&&r.type==="text"&&n.type==="text"?(n.raw+=r.raw,n.text+=r.text):e.push(r);continue}if(r=this.tokenizer.emStrong(a,l,c)){a=a.substring(r.raw.length),e.push(r);continue}if(r=this.tokenizer.codespan(a)){a=a.substring(r.raw.length),e.push(r);continue}if(r=this.tokenizer.br(a)){a=a.substring(r.raw.length),e.push(r);continue}if(r=this.tokenizer.del(a)){a=a.substring(r.raw.length),e.push(r);continue}if(r=this.tokenizer.autolink(a,ep)){a=a.substring(r.raw.length),e.push(r);continue}if(!this.state.inLink&&(r=this.tokenizer.url(a,ep))){a=a.substring(r.raw.length),e.push(r);continue}if(i=a,this.options.extensions&&this.options.extensions.startInline){let v=1/0,g=a.slice(1),s;this.options.extensions.startInline.forEach(function(d){s=d.call({lexer:this},g),typeof s=="number"&&s>=0&&(v=Math.min(v,s))}),v<1/0&&v>=0&&(i=a.substring(0,v+1))}if(r=this.tokenizer.inlineText(i,xF)){a=a.substring(r.raw.length),r.raw.slice(-1)!=="_"&&(c=r.raw.slice(-1)),h=!0,n=e[e.length-1],n&&n.type==="text"?(n.raw+=r.raw,n.text+=r.text):e.push(r);continue}if(a){let v="Infinite loop on byte: "+a.charCodeAt(0);if(this.options.silent){console.error(v);break}else throw new Error(v)}}return e}},Un=class{constructor(a){this.options=a||hr}code(a,e,r){let n=(e||"").match(/\S*/)[0];if(this.options.highlight){let i=this.options.highlight(a,n);i!=null&&i!==a&&(r=!0,a=i)}return a=a.replace(/\n$/,"")+` -`,n?'
'+(r?a:C0(a,!0))+`
-`:"
"+(r?a:C0(a,!0))+`
+`+r.text,this.inlineQueue.pop(),this.inlineQueue[this.inlineQueue.length-1].src=n.text):e.push(r);continue}if(a){let o="Infinite loop on byte: "+a.charCodeAt(0);if(this.options.silent){console.error(o);break}else throw new Error(o)}}return this.state.top=!0,e}inline(a,e=[]){return this.inlineQueue.push({src:a,tokens:e}),e}inlineTokens(a,e=[]){let r,n,i,l=a,o,h,c;if(this.tokens.links){let v=Object.keys(this.tokens.links);if(v.length>0)for(;(o=this.tokenizer.rules.inline.reflinkSearch.exec(l))!=null;)v.includes(o[0].slice(o[0].lastIndexOf("[")+1,-1))&&(l=l.slice(0,o.index)+"["+cp("a",o[0].length-2)+"]"+l.slice(this.tokenizer.rules.inline.reflinkSearch.lastIndex))}for(;(o=this.tokenizer.rules.inline.blockSkip.exec(l))!=null;)l=l.slice(0,o.index)+"["+cp("a",o[0].length-2)+"]"+l.slice(this.tokenizer.rules.inline.blockSkip.lastIndex);for(;(o=this.tokenizer.rules.inline.escapedEmSt.exec(l))!=null;)l=l.slice(0,o.index+o[0].length-2)+"++"+l.slice(this.tokenizer.rules.inline.escapedEmSt.lastIndex),this.tokenizer.rules.inline.escapedEmSt.lastIndex--;for(;a;)if(h||(c=""),h=!1,!(this.options.extensions&&this.options.extensions.inline&&this.options.extensions.inline.some(v=>(r=v.call({lexer:this},a,e))?(a=a.substring(r.raw.length),e.push(r),!0):!1))){if(r=this.tokenizer.escape(a)){a=a.substring(r.raw.length),e.push(r);continue}if(r=this.tokenizer.tag(a)){a=a.substring(r.raw.length),n=e[e.length-1],n&&r.type==="text"&&n.type==="text"?(n.raw+=r.raw,n.text+=r.text):e.push(r);continue}if(r=this.tokenizer.link(a)){a=a.substring(r.raw.length),e.push(r);continue}if(r=this.tokenizer.reflink(a,this.tokens.links)){a=a.substring(r.raw.length),n=e[e.length-1],n&&r.type==="text"&&n.type==="text"?(n.raw+=r.raw,n.text+=r.text):e.push(r);continue}if(r=this.tokenizer.emStrong(a,l,c)){a=a.substring(r.raw.length),e.push(r);continue}if(r=this.tokenizer.codespan(a)){a=a.substring(r.raw.length),e.push(r);continue}if(r=this.tokenizer.br(a)){a=a.substring(r.raw.length),e.push(r);continue}if(r=this.tokenizer.del(a)){a=a.substring(r.raw.length),e.push(r);continue}if(r=this.tokenizer.autolink(a,gp)){a=a.substring(r.raw.length),e.push(r);continue}if(!this.state.inLink&&(r=this.tokenizer.url(a,gp))){a=a.substring(r.raw.length),e.push(r);continue}if(i=a,this.options.extensions&&this.options.extensions.startInline){let v=1/0,g=a.slice(1),d;this.options.extensions.startInline.forEach(function(u){d=u.call({lexer:this},g),typeof d=="number"&&d>=0&&(v=Math.min(v,d))}),v<1/0&&v>=0&&(i=a.substring(0,v+1))}if(r=this.tokenizer.inlineText(i,IF)){a=a.substring(r.raw.length),r.raw.slice(-1)!=="_"&&(c=r.raw.slice(-1)),h=!0,n=e[e.length-1],n&&n.type==="text"?(n.raw+=r.raw,n.text+=r.text):e.push(r);continue}if(a){let v="Infinite loop on byte: "+a.charCodeAt(0);if(this.options.silent){console.error(v);break}else throw new Error(v)}}return e}},$n=class{constructor(a){this.options=a||hr}code(a,e,r){let n=(e||"").match(/\S*/)[0];if(this.options.highlight){let i=this.options.highlight(a,n);i!=null&&i!==a&&(r=!0,a=i)}return a=a.replace(/\n$/,"")+` +`,n?'
'+(r?a:V0(a,!0))+`
+`:"
"+(r?a:V0(a,!0))+`
`}blockquote(a){return`
${a}
`}html(a){return a}heading(a,e,r,n){if(this.options.headerIds){let i=this.options.headerPrefix+n.slug(r);return`${a} @@ -54,19 +54,19 @@ ${a} `}tablerow(a){return` ${a} `}tablecell(a,e){let r=e.header?"th":"td";return(e.align?`<${r} align="${e.align}">`:`<${r}>`)+a+` -`}strong(a){return`${a}`}em(a){return`${a}`}codespan(a){return`${a}`}br(){return this.options.xhtml?"
":"
"}del(a){return`${a}`}link(a,e,r){if(a=Zf(this.options.sanitize,this.options.baseUrl,a),a===null)return r;let n='",n}image(a,e,r){if(a=Zf(this.options.sanitize,this.options.baseUrl,a),a===null)return r;let n=`${r}":">",n}text(a){return a}},m5=class{strong(a){return a}em(a){return a}codespan(a){return a}del(a){return a}html(a){return a}text(a){return a}link(a,e,r){return""+r}image(a,e,r){return""+r}br(){return""}},M5=class{constructor(){this.seen={}}serialize(a){return a.toLowerCase().trim().replace(/<[!\/a-z].*?>/ig,"").replace(/[\u2000-\u206F\u2E00-\u2E7F\\'!"#$%&()*+,./:;<=>?@[\]^`{|}~]/g,"").replace(/\s/g,"-")}getNextSafeSlug(a,e){let r=a,n=0;if(this.seen.hasOwnProperty(r)){n=this.seen[a];do n++,r=a+"-"+n;while(this.seen.hasOwnProperty(r))}return e||(this.seen[a]=n,this.seen[r]=0),r}slug(a,e={}){let r=this.serialize(a);return this.getNextSafeSlug(r,e.dryrun)}},k2=class{constructor(a){this.options=a||hr,this.options.renderer=this.options.renderer||new Un,this.renderer=this.options.renderer,this.renderer.options=this.options,this.textRenderer=new m5,this.slugger=new M5}static parse(a,e){return new k2(e).parse(a)}static parseInline(a,e){return new k2(e).parseInline(a)}parse(a,e=!0){let r="",n,i,l,o,h,c,v,g,s,d,p,z,L,u,f,m,M,x,y,w=a.length;for(n=0;n0&&f.tokens[0].type==="paragraph"?(f.tokens[0].text=x+" "+f.tokens[0].text,f.tokens[0].tokens&&f.tokens[0].tokens.length>0&&f.tokens[0].tokens[0].type==="text"&&(f.tokens[0].tokens[0].text=x+" "+f.tokens[0].tokens[0].text)):f.tokens.unshift({type:"text",text:x}):u+=x),u+=this.parse(f.tokens,L),s+=this.renderer.listitem(u,M,m);r+=this.renderer.list(s,p,z);continue}case"html":{r+=this.renderer.html(d.text);continue}case"paragraph":{r+=this.renderer.paragraph(this.parseInline(d.tokens));continue}case"text":{for(s=d.tokens?this.parseInline(d.tokens):d.text;n+1"u"||t===null)throw new Error("marked(): input parameter is undefined or null");if(typeof t!="string")throw new Error("marked(): input parameter is of type "+Object.prototype.toString.call(t)+", string expected");if(typeof a=="function"&&(e=a,a=null),a=Y2({},O1.defaults,a||{}),ip(a),e){let n=a.highlight,i;try{i=X2.lex(t,a)}catch(h){return e(h)}let l=function(h){let c;if(!h)try{a.walkTokens&&O1.walkTokens(i,a.walkTokens),c=k2.parse(i,a)}catch(v){h=v}return a.highlight=n,h?e(h):e(null,c)};if(!n||n.length<3||(delete a.highlight,!i.length))return l();let o=0;O1.walkTokens(i,function(h){h.type==="code"&&(o++,setTimeout(()=>{n(h.text,h.lang,function(c,v){if(c)return l(c);v!=null&&v!==h.text&&(h.text=v,h.escaped=!0),o--,o===0&&l()})},0))}),o===0&&l();return}function r(n){if(n.message+=` -Please report this to https://github.com/markedjs/marked.`,a.silent)return"

An error occurred:

"+C0(n.message+"",!0)+"
";throw n}try{let n=X2.lex(t,a);if(a.walkTokens){if(a.async)return Promise.all(O1.walkTokens(n,a.walkTokens)).then(()=>k2.parse(n,a)).catch(r);O1.walkTokens(n,a.walkTokens)}return k2.parse(n,a)}catch(n){r(n)}}O1.options=O1.setOptions=function(t){return Y2(O1.defaults,t),iF(O1.defaults),O1};O1.getDefaults=rp;O1.defaults=hr;O1.use=function(...t){let a=Y2({},...t),e=O1.defaults.extensions||{renderers:{},childTokens:{}},r;t.forEach(n=>{if(n.extensions&&(r=!0,n.extensions.forEach(i=>{if(!i.name)throw new Error("extension name required");if(i.renderer){let l=e.renderers?e.renderers[i.name]:null;l?e.renderers[i.name]=function(...o){let h=i.renderer.apply(this,o);return h===!1&&(h=l.apply(this,o)),h}:e.renderers[i.name]=i.renderer}if(i.tokenizer){if(!i.level||i.level!=="block"&&i.level!=="inline")throw new Error("extension level must be 'block' or 'inline'");e[i.level]?e[i.level].unshift(i.tokenizer):e[i.level]=[i.tokenizer],i.start&&(i.level==="block"?e.startBlock?e.startBlock.push(i.start):e.startBlock=[i.start]:i.level==="inline"&&(e.startInline?e.startInline.push(i.start):e.startInline=[i.start]))}i.childTokens&&(e.childTokens[i.name]=i.childTokens)})),n.renderer){let i=O1.defaults.renderer||new Un;for(let l in n.renderer){let o=i[l];i[l]=(...h)=>{let c=n.renderer[l].apply(i,h);return c===!1&&(c=o.apply(i,h)),c}}a.renderer=i}if(n.tokenizer){let i=O1.defaults.tokenizer||new $n;for(let l in n.tokenizer){let o=i[l];i[l]=(...h)=>{let c=n.tokenizer[l].apply(i,h);return c===!1&&(c=o.apply(i,h)),c}}a.tokenizer=i}if(n.walkTokens){let i=O1.defaults.walkTokens;a.walkTokens=function(l){let o=[];return o.push(n.walkTokens.call(this,l)),i&&(o=o.concat(i.call(this,l))),o}}r&&(a.extensions=e),O1.setOptions(a)})};O1.walkTokens=function(t,a){let e=[];for(let r of t)switch(e=e.concat(a.call(O1,r)),r.type){case"table":{for(let n of r.header)e=e.concat(O1.walkTokens(n.tokens,a));for(let n of r.rows)for(let i of n)e=e.concat(O1.walkTokens(i.tokens,a));break}case"list":{e=e.concat(O1.walkTokens(r.items,a));break}default:O1.defaults.extensions&&O1.defaults.extensions.childTokens&&O1.defaults.extensions.childTokens[r.type]?O1.defaults.extensions.childTokens[r.type].forEach(function(n){e=e.concat(O1.walkTokens(r[n],a))}):r.tokens&&(e=e.concat(O1.walkTokens(r.tokens,a)))}return e};O1.parseInline=function(t,a){if(typeof t>"u"||t===null)throw new Error("marked.parseInline(): input parameter is undefined or null");if(typeof t!="string")throw new Error("marked.parseInline(): input parameter is of type "+Object.prototype.toString.call(t)+", string expected");a=Y2({},O1.defaults,a||{}),ip(a);try{let e=X2.lexInline(t,a);return a.walkTokens&&O1.walkTokens(e,a.walkTokens),k2.parseInline(e,a)}catch(e){if(e.message+=` -Please report this to https://github.com/markedjs/marked.`,a.silent)return"

An error occurred:

"+C0(e.message+"",!0)+"
";throw e}};O1.Parser=k2;O1.parser=k2.parse;O1.Renderer=Un;O1.TextRenderer=m5;O1.Lexer=X2;O1.lexer=X2.lex;O1.Tokenizer=$n;O1.Slugger=M5;O1.parse=O1;var JI=O1.options,tO=O1.setOptions,aO=O1.use,eO=O1.walkTokens,rO=O1.parseInline;var nO=k2.parse,iO=X2.lex;var E2=B1(T1(),1),n4=B1(T1(),1),Fz=B1(T1(),1),kz=B1(T1(),1),bz=B1(T1(),1),Q2=B1(T1(),1),a_=B1(T1(),1);function $p(t="This should not happen"){throw new Error(t)}function i2(t,a="Assertion failed"){if(!t)return $p(a)}function dr(t){return $p("Hell froze over")}function jF(t,a){try{return t()}catch{return a}}var wp=Object.prototype.hasOwnProperty;function k5(t,a){let e,r;if(t===a)return!0;if(t&&a&&(e=t.constructor)===a.constructor){if(e===Date)return t.getTime()===a.getTime();if(e===RegExp)return t.toString()===a.toString();if(e===Array){if((r=t.length)===a.length)for(;r--&&k5(t[r],a[r]););return r===-1}if(!e||typeof t=="object"){r=0;for(e in t)if(wp.call(t,e)&&++r&&!wp.call(a,e)||!(e in a)||!k5(t[e],a[e]))return!1;return Object.keys(a).length===r}}return t!==t&&a!==a}var qp=class extends fr.PureComponent{constructor(){super(...arguments),this.wrapperRef=fr.createRef(),this.clickOutside=t=>{if(this.wrapperRef.current!==null&&!this.wrapperRef.current.contains(t.target)){let a=t.target;for(;a!==null;){if(a.classList.contains("click-outside-ignore"))return;a=a.parentElement}this.props.onClickOutside()}}}componentDidMount(){document.addEventListener("mousedown",this.clickOutside,!0),document.addEventListener("contextmenu",this.clickOutside,!0)}componentWillUnmount(){document.removeEventListener("mousedown",this.clickOutside),document.removeEventListener("contextmenu",this.clickOutside)}render(){let{onClickOutside:t,...a}=this.props;return fr.createElement("div",{...a,ref:this.wrapperRef},this.props.children)}};function Kp(t){var a,e;return{"--gdg-accent-color":t.accentColor,"--gdg-accent-fg":t.accentFg,"--gdg-accent-light":t.accentLight,"--gdg-text-dark":t.textDark,"--gdg-text-medium":t.textMedium,"--gdg-text-light":t.textLight,"--gdg-text-bubble":t.textBubble,"--gdg-bg-icon-header":t.bgIconHeader,"--gdg-fg-icon-header":t.fgIconHeader,"--gdg-text-header":t.textHeader,"--gdg-text-group-header":(a=t.textGroupHeader)!=null?a:t.textHeader,"--gdg-text-header-selected":t.textHeaderSelected,"--gdg-bg-cell":t.bgCell,"--gdg-bg-cell-medium":t.bgCellMedium,"--gdg-bg-header":t.bgHeader,"--gdg-bg-header-has-focus":t.bgHeaderHasFocus,"--gdg-bg-header-hovered":t.bgHeaderHovered,"--gdg-bg-bubble":t.bgBubble,"--gdg-bg-bubble-selected":t.bgBubbleSelected,"--gdg-bg-search-result":t.bgSearchResult,"--gdg-border-color":t.borderColor,"--gdg-horizontal-border-color":(e=t.horizontalBorderColor)!=null?e:t.borderColor,"--gdg-drilldown-border":t.drilldownBorder,"--gdg-link-color":t.linkColor,"--gdg-cell-horizontal-padding":`${t.cellHorizontalPadding}px`,"--gdg-cell-vertical-padding":`${t.cellVerticalPadding}px`,"--gdg-header-font-style":t.headerFontStyle,"--gdg-base-font-style":t.baseFontStyle,"--gdg-font-family":t.fontFamily,"--gdg-editor-font-size":t.editorFontSize}}var Xp={accentColor:"#4F5DFF",accentFg:"#FFFFFF",accentLight:"rgba(62, 116, 253, 0.1)",textDark:"#313139",textMedium:"#737383",textLight:"#B2B2C0",textBubble:"#313139",bgIconHeader:"#737383",fgIconHeader:"#FFFFFF",textHeader:"#313139",textGroupHeader:"#313139BB",textHeaderSelected:"#FFFFFF",bgCell:"#FFFFFF",bgCellMedium:"#FAFAFB",bgHeader:"#F7F7F8",bgHeaderHasFocus:"#E9E9EB",bgHeaderHovered:"#EFEFF1",bgBubble:"#EDEDF3",bgBubbleSelected:"#FFFFFF",bgSearchResult:"#fff9e3",borderColor:"rgba(115, 116, 131, 0.16)",drilldownBorder:"rgba(0, 0, 0, 0)",linkColor:"#4F5DFF",cellHorizontalPadding:8,cellVerticalPadding:3,headerIconSize:18,headerFontStyle:"600 13px",baseFontStyle:"13px",fontFamily:"Inter, Roboto, -apple-system, BlinkMacSystemFont, avenir next, avenir, segoe ui, helvetica neue, helvetica, Ubuntu, noto, arial, sans-serif",editorFontSize:"13px",lineHeight:1.4};function Lp(){return Xp}var Yp=Gp.default.createContext(Xp);function qF(t,a){let[e,r]=a;if(t.columns.hasIndex(e)||t.rows.hasIndex(r))return!0;if(t.current!==void 0){if(t.current.cell[0]===e&&t.current.cell[1]===r)return!0;let n=[t.current.range,...t.current.rangeStack];for(let i of n)if(e>=i.x&&e=i.y&&r{if(a===0)return this;let e=this.items.map(r=>[r[0]+a,r[1]+a]);return new gr(e)},this.add=a=>{let e=typeof a=="number"?[a,a+1]:a,r=KF([...this.items,e]);return new gr(r)},this.remove=a=>{let e=[...this.items],r=typeof a=="number"?a:a[0],n=typeof a=="number"?a+1:a[1];for(let[i,l]of e.entries()){let[o,h]=l;if(o<=n&&r<=h){let c=[];o{if(this.items.length!==0)return this.items[0][0]},this.last=()=>{if(this.items.length!==0)return this.items.slice(-1)[0][1]-1},this.hasIndex=a=>{for(let e=0;e=r&&a{for(let e=a[0];e{for(let e of this)if(a(e))return!0;return!1},this.equals=a=>{if(a===this)return!0;if(a.items.length!==this.items.length)return!1;for(let e=0;e{let a=[];for(let[e,r]of this.items)for(let n=e;nf8??(f8=new gr([]));pt.fromSingleSelection=t=>gr.empty().add(t);var XF=()=>t=>t.targetY,YF=()=>t=>t.targetX-1,QF=()=>t=>t.targetY-1,ZF=()=>t=>t.targetWidth+2,JF=()=>t=>t.targetHeight+2,tk=()=>t=>t.targetY+10,ak=()=>t=>Math.max(0,(t.targetHeight-28)/2),ek=y0("div")({name:"DataGridOverlayEditorStyle",class:"d1t1th9s",vars:{"d1t1th9s-0":[XF(),"px"],"d1t1th9s-1":[YF(),"px"],"d1t1th9s-2":[QF(),"px"],"d1t1th9s-3":[ZF(),"px"],"d1t1th9s-4":[JF(),"px"],"d1t1th9s-5":[tk(),"px"],"d1t1th9s-6":[ak(),"px"]}});function rk(){let[t,a]=ua.useState();return[t??void 0,a]}function nk(){let[t,a]=rk(),[e,r]=ua.useState(0),[n,i]=ua.useState(!0);ua.useLayoutEffect(()=>{if(t===void 0||!("IntersectionObserver"in window))return;let o=new IntersectionObserver(h=>{h.length!==0&&i(h[0].isIntersecting)},{threshold:1});return o.observe(t),()=>o.disconnect()},[t]),ua.useEffect(()=>{if(n||t===void 0)return;let o,h=()=>{let{right:c}=t.getBoundingClientRect();r(v=>Math.min(v+window.innerWidth-c-10,0)),o=requestAnimationFrame(h)};return o=requestAnimationFrame(h),()=>{o!==void 0&&cancelAnimationFrame(o)}},[t,n]);let l=ua.useMemo(()=>({transform:`translateX(${e}px)`}),[e]);return{ref:a,style:l}}var ik=t=>{let{target:a,content:e,onFinishEditing:r,forceEditMode:n,initialValue:i,imageEditorOverride:l,markdownDivCreateNode:o,highlight:h,className:c,theme:v,id:g,cell:s,validateCell:d,getCellRenderer:p,provideEditor:z}=t,[L,u]=l0.useState(n?e:void 0),f=l0.useRef(L??e);f.current=L??e;let[m,M]=l0.useState(()=>d===void 0?!0:!(Ea(e)&&d?.(s,e,f.current)===!1)),x=l0.useCallback((f1,d1)=>{r(m?f1:void 0,d1)},[m,r]),y=l0.useCallback(f1=>{if(d!==void 0&&f1!==void 0&&Ea(f1)){let d1=d(s,f1,f.current);d1===!1?M(!1):(typeof d1=="object"&&(f1=d1),M(!0))}u(f1)},[s,d]),w=l0.useRef(!1),V=l0.useRef(void 0),R=l0.useCallback(()=>{x(L,[0,0]),w.current=!0},[L,x]),S=l0.useCallback(f1=>{var d1;x(f1,(d1=V.current)!=null?d1:[0,0]),w.current=!0},[x]),b=l0.useCallback(async f1=>{let d1=!1;f1.key==="Escape"?(f1.stopPropagation(),f1.preventDefault(),V.current=[0,0]):f1.key==="Enter"&&!f1.shiftKey?(f1.stopPropagation(),f1.preventDefault(),V.current=[0,1],d1=!0):f1.key==="Tab"&&(f1.stopPropagation(),f1.preventDefault(),V.current=[f1.shiftKey?-1:1,0],d1=!0),window.setTimeout(()=>{!w.current&&V.current!==void 0&&(x(d1?L:void 0,V.current),w.current=!0)},0)},[x,L]),E=L??e,[C,T]=l0.useMemo(()=>{var f1,d1;if(ze(e))return[];let K1=z?.(e);return K1!==void 0?[K1,!1]:[(d1=(f1=p(e))==null?void 0:f1.provideEditor)==null?void 0:d1.call(f1,e),!1]},[e,p,z]),{ref:I,style:J}=nk(),W=!0,n1,i1=!0,g1;if(C!==void 0){W=C.disablePadding!==!0,i1=C.disableStyling!==!0;let f1=tz(C);f1&&(g1=C.styleOverride);let d1=f1?C.editor:C;n1=l0.createElement(d1,{isHighlighted:h,onChange:y,value:E,initialValue:i,onFinishedEditing:S,validatedSelection:Ea(E)?E.selectionRange:void 0,forceEditMode:n,target:a,imageEditorOverride:l,markdownDivCreateNode:o,isValid:m})}g1={...g1,...J};let l1=document.getElementById("portal");if(l1===null)return console.error('Cannot open Data Grid overlay editor, because portal not found. Please add `
` as the last child of your ``.'),null;let H1=i1?"gdg-style":"gdg-unstyle";return m||(H1+=" invalid"),W&&(H1+=" pad"),(0,jp.createPortal)(l0.createElement(Yp.Provider,{value:v},l0.createElement(qp,{style:Kp(v),className:c,onClickOutside:R},l0.createElement(ek,{ref:I,id:g,className:H1,style:g1,as:T===!0?"label":void 0,targetX:a.x,targetY:a.y,targetWidth:a.width,targetHeight:a.height},l0.createElement("div",{className:"clip-region",onKeyDown:b},n1)))),l1)},lk=ik,k8=1<<16,p8=[];function Rp(t,a){return a*k8+t}function rz(t){return t%k8}function nz(t,a){return(t-a)/k8}function ok(t){let a=rz(t),e=nz(t,a);return[a,e]}var hk=class{constructor(){this.imageLoaded=()=>{},this.loadedLocations=[],this.visibleWindow={x:0,y:0,width:0,height:0},this.freezeCols=0,this.isInWindow=t=>{let a=rz(t),e=nz(t,a),r=this.visibleWindow;return a=r.y&&e<=r.y+r.height?!0:a>=r.x&&a<=r.x+r.width&&e>=r.y&&e<=r.y+r.height},this.cache={},this.sendLoaded=(0,ez.default)(()=>{this.imageLoaded(this.loadedLocations),this.loadedLocations=[]},20),this.clearOutOfWindow=()=>{let t=Object.keys(this.cache);for(let a of t){let e=this.cache[a],r=!1;for(let n=0;n{o||(o=!0,p8.length<12?p8.unshift(l):i||(l.src=""))}},c=new Promise(v=>l.addEventListener("load",()=>v(null)));requestAnimationFrame(async()=>{try{l.src=t,await c,await l.decode();let v=this.cache[r];if(v!==void 0&&!o){v.img=l;for(let g of v.cells)this.loadedLocations.push(ok(g));i=!0,this.sendLoaded()}}catch{h.cancel()}}),this.cache[r]=h}loadOrGetImage(t,a,e){let r=t,n=this.cache[r];if(n!==void 0){let i=Rp(a,e);return n.cells.includes(i)||n.cells.push(i),n.img}else this.loadImage(t,a,e,r)}},ck=hk;function Q0(t,a,e,r,n=!1){let i=Zt.useRef();i.current=a,Zt.useEffect(()=>{if(e===null||e.addEventListener===void 0)return;let l=e,o=h=>{var c;(c=i.current)==null||c.call(l,h)};return l.addEventListener(t,o,{passive:r,capture:n}),()=>{l.removeEventListener(t,o,{capture:n})}},[t,e,r,n])}function qn(t,a){return t===void 0?void 0:a}var vk=Math.PI;function yp(t){return t*vk/180}var b8=t=>{var a;let e=(a=t.fgColor)!=null?a:"currentColor";return Zt.createElement("svg",{viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg"},Zt.createElement("path",{d:"M12.7073 7.05029C7.87391 11.8837 10.4544 9.30322 6.03024 13.7273C5.77392 13.9836 5.58981 14.3071 5.50189 14.6587L4.52521 18.5655C4.38789 19.1148 4.88543 19.6123 5.43472 19.475L9.34146 18.4983C9.69313 18.4104 10.0143 18.2286 10.2706 17.9722L16.9499 11.2929",stroke:e,strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round",fill:"none",vectorEffect:"non-scaling-stroke"}),Zt.createElement("path",{d:"M20.4854 4.92901L19.0712 3.5148C18.2901 2.73375 17.0238 2.73375 16.2428 3.5148L14.475 5.28257C15.5326 7.71912 16.4736 8.6278 18.7176 9.52521L20.4854 7.75744C21.2665 6.97639 21.2665 5.71006 20.4854 4.92901Z",stroke:e,strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round",fill:"none",vectorEffect:"non-scaling-stroke"}))},gk=t=>{var a;let e=(a=t.fgColor)!=null?a:"currentColor";return Zt.createElement("svg",{viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg"},Zt.createElement("path",{d:"M19 6L10.3802 17L5.34071 11.8758",vectorEffect:"non-scaling-stroke",stroke:e,strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"}))};function dk(t,a,e){let[r,n]=Zt.useState(t),i=Zt.useRef(!0);Zt.useEffect(()=>()=>{i.current=!1},[]);let l=Zt.useRef((0,iz.default)(o=>{i.current&&n(o)},e));return Zt.useLayoutEffect(()=>{i.current&&l.current(()=>t())},a),r}var lz="\u0591-\u07FF\uFB1D-\uFDFD\uFE70-\uFEFC",oz="A-Za-z\xC0-\xD6\xD8-\xF6\xF8-\u02B8\u0300-\u0590\u0800-\u1FFF\u200E\u2C00-\uFB1C\uFE00-\uFE6F\uFEFD-\uFFFF",sk=new RegExp("^[^"+oz+"]*["+lz+"]"),uk=new RegExp("^[^"+lz+"]*["+oz+"]");function fk(t){return sk.test(t)?"rtl":uk.test(t)?"ltr":"neutral"}var L5=void 0;function pk(){if(L5!==void 0)return L5;let t=document.createElement("p");t.style.width="100%",t.style.height="200px";let a=document.createElement("div");a.id="testScrollbar",a.style.position="absolute",a.style.top="0px",a.style.left="0px",a.style.visibility="hidden",a.style.width="200px",a.style.height="150px",a.style.overflow="hidden",a.append(t),document.body.append(a);let e=t.offsetWidth;a.style.overflow="scroll";let r=t.offsetWidth;return e===r&&(r=a.clientWidth),a.remove(),L5=e-r,L5}var Ze=Symbol();function zk(t){let a=Zt.useRef([Ze,t]);a.current[1]!==t&&(a.current[0]=t),a.current[1]=t;let[e,r]=Zt.useState(t),[,n]=Zt.useState(),i=Zt.useCallback(o=>{let h=a.current[0];h!==Ze&&(o=typeof o=="function"?o(h):o,o===h)||(h!==Ze&&n({}),r(c=>typeof o=="function"?o(h===Ze?c:h):o),a.current[0]=Ze)},[]),l=Zt.useCallback(()=>{a.current[0]=Ze,n({})},[]);return[a.current[0]===Ze?e:a.current[0],i,l]}function mk(t,a){return hz.default.useMemo(()=>t.map((e,r)=>({...e,sourceIndex:r,sticky:r=a.span[0]&&r<=a.span[1]}function Cp(t,a,e){let r=e.x,n=e.x+e.width-1,i=e.y,l=e.y+e.height-1,[o,h]=t;if(hl)return!1;if(a.span===void 0)return o>=r&&o<=n;let[c,v]=a.span;return c>=r&&c<=n||v>=r&&c<=n||cn}function Hk(t,a,e){let r=0;if(e.current===void 0)return r;Cp(t,a,e.current.range)&&r++;for(let n of e.current.rangeStack)Cp(t,a,n)&&r++;return r}function cz(t,a){let e=t;if(a!==void 0){let r=[...t],n=e[a.src];a.src>a.dest?(r.splice(a.src,1),r.splice(a.dest,0,n)):(r.splice(a.dest+1,0,n),r.splice(a.src,1)),r=r.map((i,l)=>({...i,sticky:t[l].sticky})),e=r}return e}function sr(t,a){let e=0,r=cz(t,a);for(let n=0;n0)for(let c of l)e-=c.width;let o=a,h=n??0;for(;h<=e&&oa-g)return i-1;let s=i-(c?1:0),d=t-(h??0);if(typeof l=="number"){let p=Math.floor((d-v)/l)+o;return p>=s?void 0:p}else{let p=v;for(let z=o;z"u";async function Vk(){var t;Lk||((t=document?.fonts)==null?void 0:t.ready)===void 0||(await document.fonts.ready,y5=0,C5={},qd())}Vk();function Rk(t,a,e,r){return`${t}_${r??a.font}_${e}`}function E8(t,a,e){let r=Rk(t,a,"middle",e),n=C5[r];return n===void 0&&(n=a.measureText(t),C5[r]=n,y5++),y5>1e4&&(C5={},y5=0),n}function _a(t,a){return typeof a!="string"&&(a=`${a.baseFontStyle} ${a.fontFamily}`),yk(t,a)}function Bp(t,a){let e="ABCDEFGHIJKLMNOPQRSTUVWXYZ";t.save(),t.textBaseline=a;let r=t.measureText(e);return t.restore(),r}var Sp=[];function yk(t,a){for(let i of Sp)if(i.key===a)return i.val;let e=Bp(t,"alphabetic"),n=-(Bp(t,"middle").actualBoundingBoxDescent-e.actualBoundingBoxDescent)+e.actualBoundingBoxAscent/2;return Sp.push({key:a,val:n}),n}function Ck(t,a,e,r,n){let{ctx:i,rect:l,theme:o}=t,h=Number.MAX_SAFE_INTEGER,c=500;if(a!==void 0&&(h=e-a,hp&&(a=a.slice(0,p))}let s=_a(i,o),d=fk(a)==="rtl";if(e===void 0&&d&&(e="right"),d&&(i.direction="rtl"),a.length>0){let p=!1;if(e==="right"?(i.textAlign="right",p=!0):e!==void 0&&e!=="left"&&(i.textAlign=e,p=!0),!r)Ap(i,a,h,c,v,g,s,o,e);else{let z=`${o.fontFamily} ${o.baseFontStyle}`,L=Gd(i,a,z,v-o.cellHorizontalPadding*2,n??!1),u=vz(i,z),f=o.lineHeight*u,m=u+f*(L.length-1),M=m+o.cellVerticalPadding>g;M&&(i.save(),i.rect(h,c,v,g),i.clip());let x=c+g/2-m/2,y=Math.max(c+o.cellVerticalPadding,x);for(let w of L)if(Ap(i,w,h,y,v,u,s,o,e),y+=f,y>c+g)break;M&&i.restore()}p&&(i.textAlign="start"),d&&(i.direction="inherit")}}function Bk(t,a,e){let{ctx:r,rect:n,hoverAmount:i,theme:l,spriteManager:o}=t,{x:h,y:c,width:v,height:g}=n;r.beginPath(),r.globalAlpha=i,r.rect(h,c,v,g),r.fillStyle=l.bgHeaderHovered,r.fill(),r.globalAlpha=1,r.beginPath();let s=a!=="",d=0;if(e!==void 0){let z=g-8,L=h+8/2,u=c+8/2;o.drawSprite(e,"normal",r,L,u,z,l,s?1:i),d=z}else{d=24;let p=12,z=s?p:i*p,L=s?0:(1-i)*p*.5,u=l.cellHorizontalPadding+4;z>0&&(r.moveTo(h+u+L,c+g/2),r.lineTo(h+u+L+z,c+g/2),r.moveTo(h+u+L+z*.5,c+g/2-z*.5),r.lineTo(h+u+L+z*.5,c+g/2+z*.5),r.lineWidth=2,r.strokeStyle=l.bgIconHeader,r.lineCap="round",r.stroke())}r.fillStyle=l.textMedium,r.fillText(a,d+h+l.cellHorizontalPadding+.5,c+g/2+_a(r,l)),r.beginPath()}function _8(t,a,e,r,n,i,l,o,h=-20,c=-20){let v=r+i/2,g=n+l/2,s=l/1.89,d=l/2,p=l/3.4,z=Math.abs(h-i/2)0){i.globalAlpha=d;let p=7*(e?o:1);if(_8(i,h,e,n?c+p:c,v,n?g-p:g,s,!0),n){i.globalAlpha=o,i.beginPath();for(let z of[3,6])for(let L of[-5,-1,3])i.rect(c+z,v+s/2+L,2,2);i.fillStyle=h.textLight,i.fill(),i.beginPath()}i.globalAlpha=1}if(r==="number"||r==="both"&&!e){let p=a.toString(),z=c+g/2;r==="both"&&o!==0&&(i.globalAlpha=1-o),i.fillStyle=h.textLight,i.fillText(p,z,v+s/2+_a(i,`9px ${h.fontFamily}`)),o!==0&&(i.globalAlpha=1)}}function kk(t){let{ctx:a,theme:e,rect:r}=t,{x:n,y:i,height:l}=r;a.beginPath();let o=2.5,h=n+e.cellHorizontalPadding+o,c=i+l/2,v=Math.cos(yp(30))*o,g=Math.sin(yp(30))*o;for(let s=0;s<12;s++)a.moveTo(h,c-o),a.lineTo(h,c+o),a.moveTo(h+v,c-g),a.lineTo(h-v,c+g),a.moveTo(h-v,c-g),a.lineTo(h+v,c+g),h+=8;a.lineWidth=1.1,a.lineCap="square",a.strokeStyle=e.textLight,a.stroke()}function Me(t,a,e,r,n,i){typeof i=="number"&&(i={tl:i,tr:i,br:i,bl:i}),i={tl:Math.min(i.tl,n/2,r/2),tr:Math.min(i.tr,n/2,r/2),bl:Math.min(i.bl,n/2,r/2),br:Math.min(i.br,n/2,r/2)},t.moveTo(a+i.tl,e),t.arcTo(a+r,e,a+r,e+i.tr,i.tr),t.arcTo(a+r,e+n,a+r-i.br,e+n,i.br),t.arcTo(a,e+n,a,e+n-i.bl,i.bl),t.arcTo(a,e,a+i.tl,e,i.tl)}function bk(t,a,e){if(!e&&a===Qn)return;let{ctx:r,hoverAmount:n,theme:i,rect:l,highlighted:o,hoverX:h,hoverY:c}=t,{x:v,y:g,width:s,height:d}=l,p=.35,z=e?1-p+p*n:.4;a===Qn&&(z*=n),z!==0&&(r.globalAlpha=z,_8(r,i,a,v,g,s,d,o,h,c),r.globalAlpha=1)}var T8=4;function Ek(t,a){let{rect:e,theme:r,ctx:n,highlighted:i}=t,{x:l,y:o,width:h,height:c}=e,v=20,g=8,s=T8,d=l+r.cellHorizontalPadding,p=[];for(let z of a){if(d>l+h)break;let L=E8(z,n,`${r.baseFontStyle} ${r.fontFamily}`).width;p.push({x:d,width:L}),d+=L+g*2+s}n.beginPath();for(let z of p)Me(n,z.x,o+(c-v)/2,z.width+g*2,v,v/2);n.fillStyle=i?r.bgBubbleSelected:r.bgBubble,n.fill();for(let[z,L]of p.entries())n.beginPath(),n.fillStyle=r.textBubble,n.fillText(a[z],L.x+g,o+c/2+_a(n,r))}var z8={};function _k(t,a,e){let r=Math.ceil(window.devicePixelRatio),n=5,i=e-n*2,l=4,o=6,h=e*r,c=o+n,v=o*3,g=(v+n*2)*r,s=`${t},${a},${r},${e}`;if(z8[s]!==void 0)return{el:z8[s],height:h,width:g,middleWidth:l*r,sideWidth:c*r,padding:n*r,dpr:r};let d=document.createElement("canvas"),p=d.getContext("2d");if(p===null)return null;d.width=g,d.height=h,p.scale(r,r),z8[s]=d;let z=Math.min(o,v/2,i/2);return p.beginPath(),Me(p,n,n,v,i,z),p.shadowColor="rgba(24, 25, 34, 0.4)",p.shadowBlur=1,p.fillStyle=t,p.fill(),p.shadowColor="rgba(24, 25, 34, 0.3)",p.shadowOffsetY=1,p.shadowBlur=5,p.fillStyle=t,p.fill(),p.shadowOffsetY=0,p.shadowBlur=0,p.shadowBlur=0,p.beginPath(),Me(p,n+.5,n+.5,v,i,z),p.strokeStyle=a,p.lineWidth=1,p.stroke(),{el:d,height:h,width:g,sideWidth:c*r,middleWidth:o*r,padding:n*r,dpr:r}}function Tk(t,a){let{rect:e,theme:r,ctx:n,imageLoader:i,col:l,row:o}=t,{x:h,width:c}=e,v=`${r.baseFontStyle} ${r.fontFamily}`,g=vz(n,v),s=Math.min(e.height,Math.max(16,Math.ceil(g*r.lineHeight)*2)),d=Math.floor(e.y+(e.height-s)/2),p=s-10,z=8,L=T8,u=h+r.cellHorizontalPadding,f=_k(r.bgCell,r.drilldownBorder,s),m=[];for(let M of a){if(u>h+c)break;let y=E8(M.text,n,v).width,w=0;M.img!==void 0&&i.loadOrGetImage(M.img,l,o)!==void 0&&(w=p-8+4);let V=y+w+z*2;m.push({x:u,width:V}),u+=V+L}if(f!==null){let{el:M,height:x,middleWidth:y,sideWidth:w,width:V,dpr:R,padding:S}=f,b=w/R,E=S/R;for(let C of m){let T=Math.floor(C.x),I=Math.floor(C.width);n.imageSmoothingEnabled=!1,n.drawImage(M,0,0,w,x,T-E,d,b,s),C.width>w*2&&n.drawImage(M,w,0,y,x,T+(b-E),d,I-(b-E)*2,s),n.drawImage(M,V-w,0,w,x,T+I-(b-E),d,b,s),n.imageSmoothingEnabled=!0}}n.beginPath();for(let[M,x]of m.entries()){let y=a[M],w=x.x+z;if(y.img!==void 0){let V=i.loadOrGetImage(y.img,l,o);if(V!==void 0){let R=p-8,S=0,b=0,E=V.width,C=V.height;E>C?(S+=(E-C)/2,E=C):C>E&&(b+=(C-E)/2,C=E),n.beginPath(),Me(n,w,d+s/2-R/2,R,R,3),n.save(),n.clip(),n.drawImage(V,S,b,E,C,w,d+s/2-R/2,R,R),n.restore(),w+=R+4}}n.beginPath(),n.fillStyle=r.textBubble,n.fillText(y.text,w,d+s/2+_a(n,r))}}function Pk(t,a,e=4){let{rect:r,col:n,row:i,theme:l,ctx:o,imageLoader:h}=t,{x:c,y:v,height:g}=r,s=c+l.cellHorizontalPadding;for(let d of a){if(d.length===0)continue;let p=h.loadOrGetImage(d,n,i);if(p!==void 0){let z=g-l.cellVerticalPadding*2,L=p.width*(z/p.height);e>0&&(Me(o,s,v+l.cellVerticalPadding,L,z,e),o.save(),o.clip()),o.drawImage(p,s,v+l.cellVerticalPadding,L,z),e>0&&o.restore(),s+=L+T8}}}function Ik(t,a,e){let r=function(o,h){let c=h.x-o.x,v=h.y-o.y,g=Math.sqrt(c*c+v*v),s=c/g,d=v/g;return{x:c,y:h.y-o.y,len:g,nx:s,ny:d,ang:Math.atan2(d,s)}},n,i=a.length,l=a[i-1];for(let o=0;o1?1:s),z=1,L=!1;d<0?p<0?p=Math.PI+p:(p=Math.PI-p,z=-1,L=!0):p>0&&(z=-1,L=!0),n=h.radius!==void 0?h.radius:e;let u=p/2,f=Math.abs(Math.cos(u)*n/Math.sin(u)),m;f>Math.min(v.len/2,g.len/2)?(f=Math.min(v.len/2,g.len/2),m=Math.abs(f*Math.sin(u)/Math.cos(u))):m=n;let M=h.x+g.nx*f,x=h.y+g.ny*f;M+=-g.ny*m*z,x+=g.nx*m*z,t.arc(M,x,m,v.ang+Math.PI/2*z,g.ang-Math.PI/2*z,L),l=h,h=c}t.closePath()}function Xn(t,a,e,r,n,i,l,o,h,c,v,g,s,d,p){let z={x:0,y:i+c,width:0,height:0},L=i-n;if(t>=g){let u=l>t?-1:1,f=sr(d);z.x+=f+h;for(let m=l;m!==t;m+=u)z.x+=d[u===1?m:m-1].width*u}else for(let u=0;u0&&Zn(d[u-1].group,f)&&d[u-1].sticky===m;){let x=d[u-1];z.x-=x.width,z.width+=x.width,u--}let M=t;for(;M+1e&&(z.width=e-z.x)}}else if(s&&a===v-1){let u=typeof p=="number"?p:p(a);z.y=r-u,z.height=u}else{let u=o>a?-1:1;if(typeof p=="number"){let f=a-o;z.y+=f*p}else for(let f=o;f!==a;f+=u)z.y+=p(f)*u;z.height=(typeof p=="number"?p:p(a))+1}return z}var Ot='',Ok=t=>{let a=t.fgColor,e=t.bgColor;return` - ${Ot}`},Dk=t=>{let a=t.fgColor,e=t.bgColor;return` - ${Ot}`},Nk=t=>{let a=t.fgColor,e=t.bgColor;return`${Ot} +`}strong(a){return`${a}`}em(a){return`${a}`}codespan(a){return`${a}`}br(){return this.options.xhtml?"
":"
"}del(a){return`${a}`}link(a,e,r){if(a=op(this.options.sanitize,this.options.baseUrl,a),a===null)return r;let n='
",n}image(a,e,r){if(a=op(this.options.sanitize,this.options.baseUrl,a),a===null)return r;let n=`${r}":">",n}text(a){return a}},V5=class{strong(a){return a}em(a){return a}codespan(a){return a}del(a){return a}html(a){return a}text(a){return a}link(a,e,r){return""+r}image(a,e,r){return""+r}br(){return""}},R5=class{constructor(){this.seen={}}serialize(a){return a.toLowerCase().trim().replace(/<[!\/a-z].*?>/ig,"").replace(/[\u2000-\u206F\u2E00-\u2E7F\\'!"#$%&()*+,./:;<=>?@[\]^`{|}~]/g,"").replace(/\s/g,"-")}getNextSafeSlug(a,e){let r=a,n=0;if(this.seen.hasOwnProperty(r)){n=this.seen[a];do n++,r=a+"-"+n;while(this.seen.hasOwnProperty(r))}return e||(this.seen[a]=n,this.seen[r]=0),r}slug(a,e={}){let r=this.serialize(a);return this.getNextSafeSlug(r,e.dryrun)}},I2=class{constructor(a){this.options=a||hr,this.options.renderer=this.options.renderer||new $n,this.renderer=this.options.renderer,this.renderer.options=this.options,this.textRenderer=new V5,this.slugger=new R5}static parse(a,e){return new I2(e).parse(a)}static parseInline(a,e){return new I2(e).parseInline(a)}parse(a,e=!0){let r="",n,i,l,o,h,c,v,g,d,u,p,z,w,s,f,m,H,x,y,R=a.length;for(n=0;n0&&f.tokens[0].type==="paragraph"?(f.tokens[0].text=x+" "+f.tokens[0].text,f.tokens[0].tokens&&f.tokens[0].tokens.length>0&&f.tokens[0].tokens[0].type==="text"&&(f.tokens[0].tokens[0].text=x+" "+f.tokens[0].tokens[0].text)):f.tokens.unshift({type:"text",text:x}):s+=x),s+=this.parse(f.tokens,w),d+=this.renderer.listitem(s,H,m);r+=this.renderer.list(d,p,z);continue}case"html":{r+=this.renderer.html(u.text);continue}case"paragraph":{r+=this.renderer.paragraph(this.parseInline(u.tokens));continue}case"text":{for(d=u.tokens?this.parseInline(u.tokens):u.text;n+1"u"||t===null)throw new Error("marked(): input parameter is undefined or null");if(typeof t!="string")throw new Error("marked(): input parameter is of type "+Object.prototype.toString.call(t)+", string expected");if(typeof a=="function"&&(e=a,a=null),a=aa({},j1.defaults,a||{}),up(a),e){let n=a.highlight,i;try{i=ta.lex(t,a)}catch(h){return e(h)}let l=function(h){let c;if(!h)try{a.walkTokens&&j1.walkTokens(i,a.walkTokens),c=I2.parse(i,a)}catch(v){h=v}return a.highlight=n,h?e(h):e(null,c)};if(!n||n.length<3||(delete a.highlight,!i.length))return l();let o=0;j1.walkTokens(i,function(h){h.type==="code"&&(o++,setTimeout(()=>{n(h.text,h.lang,function(c,v){if(c)return l(c);v!=null&&v!==h.text&&(h.text=v,h.escaped=!0),o--,o===0&&l()})},0))}),o===0&&l();return}function r(n){if(n.message+=` +Please report this to https://github.com/markedjs/marked.`,a.silent)return"

An error occurred:

"+V0(n.message+"",!0)+"
";throw n}try{let n=ta.lex(t,a);if(a.walkTokens){if(a.async)return Promise.all(j1.walkTokens(n,a.walkTokens)).then(()=>I2.parse(n,a)).catch(r);j1.walkTokens(n,a.walkTokens)}return I2.parse(n,a)}catch(n){r(n)}}j1.options=j1.setOptions=function(t){return aa(j1.defaults,t),wF(j1.defaults),j1};j1.getDefaults=dp;j1.defaults=hr;j1.use=function(...t){let a=aa({},...t),e=j1.defaults.extensions||{renderers:{},childTokens:{}},r;t.forEach(n=>{if(n.extensions&&(r=!0,n.extensions.forEach(i=>{if(!i.name)throw new Error("extension name required");if(i.renderer){let l=e.renderers?e.renderers[i.name]:null;l?e.renderers[i.name]=function(...o){let h=i.renderer.apply(this,o);return h===!1&&(h=l.apply(this,o)),h}:e.renderers[i.name]=i.renderer}if(i.tokenizer){if(!i.level||i.level!=="block"&&i.level!=="inline")throw new Error("extension level must be 'block' or 'inline'");e[i.level]?e[i.level].unshift(i.tokenizer):e[i.level]=[i.tokenizer],i.start&&(i.level==="block"?e.startBlock?e.startBlock.push(i.start):e.startBlock=[i.start]:i.level==="inline"&&(e.startInline?e.startInline.push(i.start):e.startInline=[i.start]))}i.childTokens&&(e.childTokens[i.name]=i.childTokens)})),n.renderer){let i=j1.defaults.renderer||new $n;for(let l in n.renderer){let o=i[l];i[l]=(...h)=>{let c=n.renderer[l].apply(i,h);return c===!1&&(c=o.apply(i,h)),c}}a.renderer=i}if(n.tokenizer){let i=j1.defaults.tokenizer||new Nn;for(let l in n.tokenizer){let o=i[l];i[l]=(...h)=>{let c=n.tokenizer[l].apply(i,h);return c===!1&&(c=o.apply(i,h)),c}}a.tokenizer=i}if(n.walkTokens){let i=j1.defaults.walkTokens;a.walkTokens=function(l){let o=[];return o.push(n.walkTokens.call(this,l)),i&&(o=o.concat(i.call(this,l))),o}}r&&(a.extensions=e),j1.setOptions(a)})};j1.walkTokens=function(t,a){let e=[];for(let r of t)switch(e=e.concat(a.call(j1,r)),r.type){case"table":{for(let n of r.header)e=e.concat(j1.walkTokens(n.tokens,a));for(let n of r.rows)for(let i of n)e=e.concat(j1.walkTokens(i.tokens,a));break}case"list":{e=e.concat(j1.walkTokens(r.items,a));break}default:j1.defaults.extensions&&j1.defaults.extensions.childTokens&&j1.defaults.extensions.childTokens[r.type]?j1.defaults.extensions.childTokens[r.type].forEach(function(n){e=e.concat(j1.walkTokens(r[n],a))}):r.tokens&&(e=e.concat(j1.walkTokens(r.tokens,a)))}return e};j1.parseInline=function(t,a){if(typeof t>"u"||t===null)throw new Error("marked.parseInline(): input parameter is undefined or null");if(typeof t!="string")throw new Error("marked.parseInline(): input parameter is of type "+Object.prototype.toString.call(t)+", string expected");a=aa({},j1.defaults,a||{}),up(a);try{let e=ta.lexInline(t,a);return a.walkTokens&&j1.walkTokens(e,a.walkTokens),I2.parseInline(e,a)}catch(e){if(e.message+=` +Please report this to https://github.com/markedjs/marked.`,a.silent)return"

An error occurred:

"+V0(e.message+"",!0)+"
";throw e}};j1.Parser=I2;j1.parser=I2.parse;j1.Renderer=$n;j1.TextRenderer=V5;j1.Lexer=ta;j1.lexer=ta.lex;j1.Tokenizer=Nn;j1.Slugger=R5;j1.parse=j1;var pO=j1.options,zO=j1.setOptions,mO=j1.use,MO=j1.walkTokens,HO=j1.parseInline;var xO=I2.parse,wO=ta.lex;var h2=F1(U1(),1),o4=F1(U1(),1),Gz=F1(U1(),1),Kz=F1(U1(),1),Xz=F1(U1(),1),ea=F1(U1(),1),m_=F1(U1(),1);function Jp(t="This should not happen"){throw new Error(t)}function i2(t,a="Assertion failed"){if(!t)return Jp(a)}function sr(t,a){return Jp(a??"Hell froze over")}function hk(t,a){try{return t()}catch{return a}}var Fp=Object.prototype.hasOwnProperty;function I5(t,a){let e,r;if(t===a)return!0;if(t&&a&&(e=t.constructor)===a.constructor){if(e===Date)return t.getTime()===a.getTime();if(e===RegExp)return t.toString()===a.toString();if(e===Array){if((r=t.length)===a.length)for(;r--&&I5(t[r],a[r]););return r===-1}if(!e||typeof t=="object"){r=0;for(e in t)if(Fp.call(t,e)&&++r&&!Fp.call(a,e)||!(e in a)||!I5(t[e],a[e]))return!1;return Object.keys(a).length===r}}return t!==t&&a!==a}var rz=class extends pr.PureComponent{constructor(){super(...arguments),this.wrapperRef=pr.createRef(),this.clickOutside=t=>{if(!(this.props.isOutsideClick&&!this.props.isOutsideClick(t))&&this.wrapperRef.current!==null&&!this.wrapperRef.current.contains(t.target)){let a=t.target;for(;a!==null;){if(a.classList.contains("click-outside-ignore"))return;a=a.parentElement}this.props.onClickOutside()}}}componentDidMount(){document.addEventListener("touchend",this.clickOutside,!0),document.addEventListener("mousedown",this.clickOutside,!0),document.addEventListener("contextmenu",this.clickOutside,!0)}componentWillUnmount(){document.removeEventListener("touchend",this.clickOutside,!0),document.removeEventListener("mousedown",this.clickOutside,!0),document.removeEventListener("contextmenu",this.clickOutside,!0)}render(){let{onClickOutside:t,isOutsideClick:a,...e}=this.props;return pr.createElement("div",{...e,ref:this.wrapperRef},this.props.children)}};function iz(t){var a,e;return{"--gdg-accent-color":t.accentColor,"--gdg-accent-fg":t.accentFg,"--gdg-accent-light":t.accentLight,"--gdg-text-dark":t.textDark,"--gdg-text-medium":t.textMedium,"--gdg-text-light":t.textLight,"--gdg-text-bubble":t.textBubble,"--gdg-bg-icon-header":t.bgIconHeader,"--gdg-fg-icon-header":t.fgIconHeader,"--gdg-text-header":t.textHeader,"--gdg-text-group-header":(a=t.textGroupHeader)!=null?a:t.textHeader,"--gdg-text-header-selected":t.textHeaderSelected,"--gdg-bg-cell":t.bgCell,"--gdg-bg-cell-medium":t.bgCellMedium,"--gdg-bg-header":t.bgHeader,"--gdg-bg-header-has-focus":t.bgHeaderHasFocus,"--gdg-bg-header-hovered":t.bgHeaderHovered,"--gdg-bg-bubble":t.bgBubble,"--gdg-bg-bubble-selected":t.bgBubbleSelected,"--gdg-bg-search-result":t.bgSearchResult,"--gdg-border-color":t.borderColor,"--gdg-horizontal-border-color":(e=t.horizontalBorderColor)!=null?e:t.borderColor,"--gdg-drilldown-border":t.drilldownBorder,"--gdg-link-color":t.linkColor,"--gdg-cell-horizontal-padding":`${t.cellHorizontalPadding}px`,"--gdg-cell-vertical-padding":`${t.cellVerticalPadding}px`,"--gdg-header-font-style":t.headerFontStyle,"--gdg-base-font-style":t.baseFontStyle,"--gdg-marker-font-style":t.markerFontStyle,"--gdg-font-family":t.fontFamily,"--gdg-editor-font-size":t.editorFontSize}}var lz={accentColor:"#4F5DFF",accentFg:"#FFFFFF",accentLight:"rgba(62, 116, 253, 0.1)",textDark:"#313139",textMedium:"#737383",textLight:"#B2B2C0",textBubble:"#313139",bgIconHeader:"#737383",fgIconHeader:"#FFFFFF",textHeader:"#313139",textGroupHeader:"#313139BB",textHeaderSelected:"#FFFFFF",bgCell:"#FFFFFF",bgCellMedium:"#FAFAFB",bgHeader:"#F7F7F8",bgHeaderHasFocus:"#E9E9EB",bgHeaderHovered:"#EFEFF1",bgBubble:"#EDEDF3",bgBubbleSelected:"#FFFFFF",bgSearchResult:"#fff9e3",borderColor:"rgba(115, 116, 131, 0.16)",drilldownBorder:"rgba(0, 0, 0, 0)",linkColor:"#4F5DFF",cellHorizontalPadding:8,cellVerticalPadding:3,headerIconSize:18,headerFontStyle:"600 13px",baseFontStyle:"13px",markerFontStyle:"9px",fontFamily:"Inter, Roboto, -apple-system, BlinkMacSystemFont, avenir next, avenir, segoe ui, helvetica neue, helvetica, Ubuntu, noto, arial, sans-serif",editorFontSize:"13px",lineHeight:1.4};function kp(){return lz}var oz=nz.default.createContext(lz);function ck(t,a){let[e,r]=a;if(t.columns.hasIndex(e)||t.rows.hasIndex(r))return!0;if(t.current!==void 0){if(t.current.cell[0]===e&&t.current.cell[1]===r)return!0;let n=[t.current.range,...t.current.rangeStack];for(let i of n)if(e>=i.x&&e=i.y&&r{if(a===0)return this;let e=this.items.map(r=>[r[0]+a,r[1]+a]);return new dr(e)},this.add=a=>{let e=typeof a=="number"?[a,a+1]:a,r=gk([...this.items,e]);return new dr(r)},this.remove=a=>{let e=[...this.items],r=typeof a=="number"?a:a[0],n=typeof a=="number"?a+1:a[1];for(let[i,l]of e.entries()){let[o,h]=l;if(o<=n&&r<=h){let c=[];o{if(this.items.length!==0)return this.items[0][0]},this.last=()=>{if(this.items.length!==0)return this.items.slice(-1)[0][1]-1},this.hasIndex=a=>{for(let e=0;e=r&&a{for(let e=a[0];e{for(let e of this)if(a(e))return!0;return!1},this.equals=a=>{if(a===this)return!0;if(a.items.length!==this.items.length)return!1;for(let e=0;e{let a=[];for(let[e,r]of this.items)for(let n=e;nw8??(w8=new dr([]));mt.fromSingleSelection=t=>dr.empty().add(t);var dk=()=>t=>t.targetY,sk=()=>t=>t.targetX-1,uk=()=>t=>t.targetY-1,fk=()=>t=>t.targetWidth+2,pk=()=>t=>t.targetHeight+2,zk=()=>t=>t.targetY+10,mk=()=>t=>Math.max(0,(t.targetHeight-28)/2),Mk=L0("div")({name:"DataGridOverlayEditorStyle",class:"d1t1th9s",vars:{"d1t1th9s-0":[dk(),"px"],"d1t1th9s-1":[sk(),"px"],"d1t1th9s-2":[uk(),"px"],"d1t1th9s-3":[fk(),"px"],"d1t1th9s-4":[pk(),"px"],"d1t1th9s-5":[zk(),"px"],"d1t1th9s-6":[mk(),"px"]}});function Hk(){let[t,a]=ma.useState();return[t??void 0,a]}function xk(){let[t,a]=Hk(),[e,r]=ma.useState(0),[n,i]=ma.useState(!0);ma.useLayoutEffect(()=>{if(t===void 0||!("IntersectionObserver"in window))return;let o=new IntersectionObserver(h=>{h.length!==0&&i(h[0].isIntersecting)},{threshold:1});return o.observe(t),()=>o.disconnect()},[t]),ma.useEffect(()=>{if(n||t===void 0)return;let o,h=()=>{let{right:c}=t.getBoundingClientRect();r(v=>Math.min(v+window.innerWidth-c-10,0)),o=requestAnimationFrame(h)};return o=requestAnimationFrame(h),()=>{o!==void 0&&cancelAnimationFrame(o)}},[t,n]);let l=ma.useMemo(()=>({transform:`translateX(${e}px)`}),[e]);return{ref:a,style:l}}var wk=t=>{let{target:a,content:e,onFinishEditing:r,forceEditMode:n,initialValue:i,imageEditorOverride:l,markdownDivCreateNode:o,highlight:h,className:c,theme:v,id:g,cell:d,validateCell:u,getCellRenderer:p,provideEditor:z,isOutsideClick:w}=t,[s,f]=o0.useState(n?e:void 0),m=o0.useRef(s??e);m.current=s??e;let[H,x]=o0.useState(()=>u===void 0?!0:!(Da(e)&&u?.(d,e,m.current)===!1)),y=o0.useCallback((o1,H1)=>{r(H?o1:void 0,H1)},[H,r]),R=o0.useCallback(o1=>{if(u!==void 0&&o1!==void 0&&Da(o1)){let H1=u(d,o1,m.current);H1===!1?x(!1):(typeof H1=="object"&&(o1=H1),x(!0))}f(o1)},[d,u]),L=o0.useRef(!1),V=o0.useRef(void 0),C=o0.useCallback(()=>{y(s,[0,0]),L.current=!0},[s,y]),k=o0.useCallback((o1,H1)=>{var P1;y(o1,(P1=H1??V.current)!=null?P1:[0,0]),L.current=!0},[y]),b=o0.useCallback(async o1=>{let H1=!1;o1.key==="Escape"?(o1.stopPropagation(),o1.preventDefault(),V.current=[0,0]):o1.key==="Enter"&&!o1.shiftKey?(o1.stopPropagation(),o1.preventDefault(),V.current=[0,1],H1=!0):o1.key==="Tab"&&(o1.stopPropagation(),o1.preventDefault(),V.current=[o1.shiftKey?-1:1,0],H1=!0),window.setTimeout(()=>{!L.current&&V.current!==void 0&&(y(H1?s:void 0,V.current),L.current=!0)},0)},[y,s]),F=s??e,[_,j]=o0.useMemo(()=>{var o1,H1;if(we(e))return[];let P1=z?.(e);return P1!==void 0?[P1,!1]:[(H1=(o1=p(e))==null?void 0:o1.provideEditor)==null?void 0:H1.call(o1,e),!1]},[e,p,z]),{ref:n1,style:Z}=xk(),d1=!0,O,a1=!0,W;if(_!==void 0){d1=_.disablePadding!==!0,a1=_.disableStyling!==!0;let o1=gz(_);o1&&(W=_.styleOverride);let H1=o1?_.editor:_;O=o0.createElement(H1,{isHighlighted:h,onChange:R,value:F,initialValue:i,onFinishedEditing:k,validatedSelection:Da(F)?F.selectionRange:void 0,forceEditMode:n,target:a,imageEditorOverride:l,markdownDivCreateNode:o,isValid:H})}W={...W,...Z};let L1=document.getElementById("portal");if(L1===null)return console.error('Cannot open Data Grid overlay editor, because portal not found. Please add `
` as the last child of your ``.'),null;let p1=a1?"gdg-style":"gdg-unstyle";return H||(p1+=" invalid"),d1&&(p1+=" pad"),(0,ez.createPortal)(o0.createElement(oz.Provider,{value:v},o0.createElement(rz,{style:iz(v),className:c,onClickOutside:C,isOutsideClick:w},o0.createElement(Mk,{ref:n1,id:g,className:p1,style:W,as:j===!0?"label":void 0,targetX:a.x,targetY:a.y,targetWidth:a.width,targetHeight:a.height},o0.createElement("div",{className:"clip-region",onKeyDown:b},O)))),L1)},Lk=wk,O8=1<<16,L8=[];function Ep(t,a){return a*O8+t}function uz(t){return t%O8}function fz(t,a){return(t-a)/O8}function Vk(t){let a=uz(t),e=fz(t,a);return[a,e]}var Rk=class{constructor(){this.imageLoaded=()=>{},this.loadedLocations=[],this.visibleWindow={x:0,y:0,width:0,height:0},this.freezeCols=0,this.isInWindow=t=>{let a=uz(t),e=fz(t,a),r=this.visibleWindow;return a=r.y&&e<=r.y+r.height?!0:a>=r.x&&a<=r.x+r.width&&e>=r.y&&e<=r.y+r.height},this.cache={},this.sendLoaded=(0,sz.default)(()=>{this.imageLoaded(this.loadedLocations),this.loadedLocations=[]},20),this.clearOutOfWindow=()=>{let t=Object.keys(this.cache);for(let a of t){let e=this.cache[a],r=!1;for(let n=0;n{o||(o=!0,L8.length<12?L8.unshift(l):i||(l.src=""))}},c=new Promise(v=>l.addEventListener("load",()=>v(null)));requestAnimationFrame(async()=>{try{l.src=t,await c,await l.decode();let v=this.cache[r];if(v!==void 0&&!o){v.img=l;for(let g of v.cells)this.loadedLocations.push(Vk(g));i=!0,this.sendLoaded()}}catch{h.cancel()}}),this.cache[r]=h}loadOrGetImage(t,a,e){let r=t,n=this.cache[r];if(n!==void 0){let i=Ep(a,e);return n.cells.includes(i)||n.cells.push(i),n.img}else this.loadImage(t,a,e,r)}},yk=Rk;function W0(t,a,e,r,n=!1){let i=Zt.useRef();i.current=a,Zt.useEffect(()=>{if(e===null||e.addEventListener===void 0)return;let l=e,o=h=>{var c;(c=i.current)==null||c.call(l,h)};return l.addEventListener(t,o,{passive:r,capture:n}),()=>{l.removeEventListener(t,o,{capture:n})}},[t,e,r,n])}function jn(t,a){return t===void 0?void 0:a}var Ck=Math.PI;function _p(t){return t*Ck/180}var zz=(t,a,e)=>({x1:t-e/2,y1:a-e/2,x2:t+e/2,y2:a+e/2}),mz=(t,a,e,r,n)=>{switch(t){case"left":return Math.floor(a)+r+n/2;case"center":return Math.floor(a+e/2);case"right":return Math.floor(a+e)-r-n/2}},Mz=(t,a,e)=>Math.min(t,a-e*2),Hz=(t,a,e)=>e.x1<=t&&t<=e.x2&&e.y1<=a&&a<=e.y2,D8=t=>{var a;let e=(a=t.fgColor)!=null?a:"currentColor";return Zt.createElement("svg",{viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg"},Zt.createElement("path",{d:"M12.7073 7.05029C7.87391 11.8837 10.4544 9.30322 6.03024 13.7273C5.77392 13.9836 5.58981 14.3071 5.50189 14.6587L4.52521 18.5655C4.38789 19.1148 4.88543 19.6123 5.43472 19.475L9.34146 18.4983C9.69313 18.4104 10.0143 18.2286 10.2706 17.9722L16.9499 11.2929",stroke:e,strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round",fill:"none",vectorEffect:"non-scaling-stroke"}),Zt.createElement("path",{d:"M20.4854 4.92901L19.0712 3.5148C18.2901 2.73375 17.0238 2.73375 16.2428 3.5148L14.475 5.28257C15.5326 7.71912 16.4736 8.6278 18.7176 9.52521L20.4854 7.75744C21.2665 6.97639 21.2665 5.71006 20.4854 4.92901Z",stroke:e,strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round",fill:"none",vectorEffect:"non-scaling-stroke"}))},Bk=t=>{var a;let e=(a=t.fgColor)!=null?a:"currentColor";return Zt.createElement("svg",{viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg"},Zt.createElement("path",{d:"M19 6L10.3802 17L5.34071 11.8758",vectorEffect:"non-scaling-stroke",stroke:e,strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"}))};function Sk(t,a,e){let[r,n]=Zt.useState(t),i=Zt.useRef(!0);Zt.useEffect(()=>()=>{i.current=!1},[]);let l=Zt.useRef((0,pz.default)(o=>{i.current&&n(o)},e));return Zt.useLayoutEffect(()=>{i.current&&l.current(()=>t())},a),r}var xz="\u0591-\u07FF\uFB1D-\uFDFD\uFE70-\uFEFC",wz="A-Za-z\xC0-\xD6\xD8-\xF6\xF8-\u02B8\u0300-\u0590\u0800-\u1FFF\u200E\u2C00-\uFB1C\uFE00-\uFE6F\uFEFD-\uFFFF",Ak=new RegExp("^[^"+wz+"]*["+xz+"]"),Fk=new RegExp("^[^"+xz+"]*["+wz+"]");function N8(t){return Ak.test(t)?"rtl":Fk.test(t)?"ltr":"neutral"}var S5=void 0;function kk(){if(S5!==void 0)return S5;let t=document.createElement("p");t.style.width="100%",t.style.height="200px";let a=document.createElement("div");a.id="testScrollbar",a.style.position="absolute",a.style.top="0px",a.style.left="0px",a.style.visibility="hidden",a.style.width="200px",a.style.height="150px",a.style.overflow="hidden",a.append(t),document.body.append(a);let e=t.offsetWidth;a.style.overflow="scroll";let r=t.offsetWidth;return e===r&&(r=a.clientWidth),a.remove(),S5=e-r,S5}var r4=Symbol();function bk(t){let a=Zt.useRef([r4,t]);a.current[1]!==t&&(a.current[0]=t),a.current[1]=t;let[e,r]=Zt.useState(t),[,n]=Zt.useState(),i=Zt.useCallback(o=>{let h=a.current[0];h!==r4&&(o=typeof o=="function"?o(h):o,o===h)||(h!==r4&&n({}),r(c=>typeof o=="function"?o(h===r4?c:h):o),a.current[0]=r4)},[]),l=Zt.useCallback(()=>{a.current[0]=r4,n({})},[]);return[a.current[0]===r4?e:a.current[0],i,l]}function Ek(t,a){return Lz.default.useMemo(()=>t.map((e,r)=>({...e,sourceIndex:r,sticky:r=a.span[0]&&r<=a.span[1]}function Tp(t,a,e){let r=e.x,n=e.x+e.width-1,i=e.y,l=e.y+e.height-1,[o,h]=t;if(hl)return!1;if(a.span===void 0)return o>=r&&o<=n;let[c,v]=a.span;return c>=r&&c<=n||v>=r&&c<=n||cn}function Tk(t,a,e){let r=0;if(e.current===void 0)return r;Tp(t,a,e.current.range)&&r++;for(let n of e.current.rangeStack)Tp(t,a,n)&&r++;return r}function Vz(t,a){let e=t;if(a!==void 0){let r=[...t],n=e[a.src];a.src>a.dest?(r.splice(a.src,1),r.splice(a.dest,0,n)):(r.splice(a.dest+1,0,n),r.splice(a.src,1)),r=r.map((i,l)=>({...i,sticky:t[l].sticky})),e=r}return e}function ur(t,a){let e=0,r=Vz(t,a);for(let n=0;n0)for(let c of l)e-=c.width;let o=a,h=n??0;for(;h<=e&&oa-g)return i-1;let d=i-(c?1:0),u=t-(h??0);if(typeof l=="number"){let p=Math.floor((u-v)/l)+o;return p>=d?void 0:p}else{let p=v;for(let z=o;z"u";async function Dk(){var t;Ok||((t=document?.fonts)==null?void 0:t.ready)===void 0||(await document.fonts.ready,k5=0,b5={},as())}Dk();function Nk(t,a,e,r){return`${t}_${r??a.font}_${e}`}function $8(t,a,e){let r=Nk(t,a,"middle",e),n=b5[r];return n===void 0&&(n=a.measureText(t),b5[r]=n,k5++),k5>1e4&&(b5={},k5=0),n}function Na(t,a){return typeof a!="string"&&(a=`${a.baseFontStyle} ${a.fontFamily}`),$k(t,a)}function Pp(t,a){let e="ABCDEFGHIJKLMNOPQRSTUVWXYZ";t.save(),t.textBaseline=a;let r=t.measureText(e);return t.restore(),r}var Ip=[];function $k(t,a){for(let i of Ip)if(i.key===a)return i.val;let e=Pp(t,"alphabetic"),n=-(Pp(t,"middle").actualBoundingBoxDescent-e.actualBoundingBoxDescent)+e.actualBoundingBoxAscent/2;return Ip.push({key:a,val:n}),n}function Uk(t,a,e,r,n){let{ctx:i,rect:l,theme:o}=t,h=Number.MAX_SAFE_INTEGER,c=500;if(a!==void 0&&(h=e-a,hp&&(a=a.slice(0,p))}let d=Na(i,o),u=N8(a)==="rtl";if(e===void 0&&u&&(e="right"),u&&(i.direction="rtl"),a.length>0){let p=!1;if(e==="right"?(i.textAlign="right",p=!0):e!==void 0&&e!=="left"&&(i.textAlign=e,p=!0),!r)Op(i,a,h,c,v,g,d,o,e);else{let z=`${o.fontFamily} ${o.baseFontStyle}`,w=es(i,a,z,v-o.cellHorizontalPadding*2,n??!1),s=Rz(i,z),f=o.lineHeight*s,m=s+f*(w.length-1),H=m+o.cellVerticalPadding>g;H&&(i.save(),i.rect(h,c,v,g),i.clip());let x=c+g/2-m/2,y=Math.max(c+o.cellVerticalPadding,x);for(let R of w)if(Op(i,R,h,y,v,s,d,o,e),y+=f,y>c+g)break;H&&i.restore()}p&&(i.textAlign="start"),u&&(i.direction="inherit")}}function Wk(t,a,e){let{ctx:r,rect:n,hoverAmount:i,theme:l,spriteManager:o}=t,{x:h,y:c,width:v,height:g}=n;r.beginPath(),r.globalAlpha=i,r.rect(h,c,v,g),r.fillStyle=l.bgHeaderHovered,r.fill(),r.globalAlpha=1,r.beginPath();let d=a!=="",u=0;if(e!==void 0){let z=g-8,w=h+8/2,s=c+8/2;o.drawSprite(e,"normal",r,w,s,z,l,d?1:i),u=z}else{u=24;let p=12,z=d?p:i*p,w=d?0:(1-i)*p*.5,s=l.cellHorizontalPadding+4;z>0&&(r.moveTo(h+s+w,c+g/2),r.lineTo(h+s+w+z,c+g/2),r.moveTo(h+s+w+z*.5,c+g/2-z*.5),r.lineTo(h+s+w+z*.5,c+g/2+z*.5),r.lineWidth=2,r.strokeStyle=l.bgIconHeader,r.lineCap="round",r.stroke())}r.fillStyle=l.textMedium,r.fillText(a,u+h+l.cellHorizontalPadding+.5,c+g/2+Na(r,l)),r.beginPath()}function U8(t,a,e,r,n,i,l,o,h=-20,c=-20,v=32,g="center"){let d=Math.floor(n+l/2),u=4,p=Mz(v,l,a.cellVerticalPadding),z=p/2,w=mz(g,r,i,a.cellHorizontalPadding,p),s=zz(w,d,p),f=Hz(r+h,n+c,s);switch(e){case!0:{t.beginPath(),Ve(t,w-p/2,d-p/2,p,p,u),t.fillStyle=o?a.accentColor:a.textMedium,t.fill(),t.beginPath(),t.moveTo(w-z+p/4.23,d-z+p/1.97),t.lineTo(w-z+p/2.42,d-z+p/1.44),t.lineTo(w-z+p/1.29,d-z+p/3.25),t.strokeStyle=a.bgCell,t.lineJoin="round",t.lineCap="round",t.lineWidth=1.9,t.stroke();break}case Qn:case!1:{t.beginPath(),Ve(t,w-p/2+.5,d-p/2+.5,p-1,p-1,u),t.lineWidth=1,t.strokeStyle=f?a.textDark:a.textMedium,t.stroke();break}case I8:{t.beginPath(),Ve(t,w-p/2,d-p/2,p,p,u),t.fillStyle=f?a.textMedium:a.textLight,t.fill(),t.beginPath(),t.moveTo(w-p/3,d),t.lineTo(w+p/3,d),t.strokeStyle=a.bgCell,t.lineCap="round",t.lineWidth=1.9,t.stroke();break}default:sr(e)}}function jk(t,a){let{ctx:e,theme:r}=t,n=`9px ${r.fontFamily}`,i=a??{};return i?.font!==n&&(e.font=n,i.font=n),i.deprep=qk,e.textAlign="center",i}function qk(t){let{ctx:a}=t;a.textAlign="start"}function Gk(t,a,e,r,n){let{ctx:i,rect:l,hoverAmount:o,theme:h}=t,{x:c,y:v,width:g,height:d}=l,u=e?1:r==="checkbox-visible"?.6+.4*o:o;if(r!=="number"&&u>0){i.globalAlpha=u;let p=7*(e?o:1);if(U8(i,h,e,n?c+p:c,v,n?g-p:g,d,!0,void 0,void 0,18),n){i.globalAlpha=o,i.beginPath();for(let z of[3,6])for(let w of[-5,-1,3])i.rect(c+z,v+d/2+w,2,2);i.fillStyle=h.textLight,i.fill(),i.beginPath()}i.globalAlpha=1}if(r==="number"||r==="both"&&!e){let p=a.toString(),z=`${h.markerFontStyle} ${h.fontFamily}`,w=c+g/2;r==="both"&&o!==0&&(i.globalAlpha=1-o),i.fillStyle=h.textLight,i.font=z,i.fillText(p,w,v+d/2+Na(i,z)),o!==0&&(i.globalAlpha=1)}}function Kk(t){let{ctx:a,theme:e,rect:r}=t,{x:n,y:i,height:l}=r;a.beginPath();let o=2.5,h=n+e.cellHorizontalPadding+o,c=i+l/2,v=Math.cos(_p(30))*o,g=Math.sin(_p(30))*o;for(let d=0;d<12;d++)a.moveTo(h,c-o),a.lineTo(h,c+o),a.moveTo(h+v,c-g),a.lineTo(h-v,c+g),a.moveTo(h-v,c-g),a.lineTo(h+v,c+g),h+=8;a.lineWidth=1.1,a.lineCap="square",a.strokeStyle=e.textLight,a.stroke()}function Ve(t,a,e,r,n,i){typeof i=="number"&&(i={tl:i,tr:i,br:i,bl:i}),i={tl:Math.min(i.tl,n/2,r/2),tr:Math.min(i.tr,n/2,r/2),bl:Math.min(i.bl,n/2,r/2),br:Math.min(i.br,n/2,r/2)},t.moveTo(a+i.tl,e),t.arcTo(a+r,e,a+r,e+i.tr,i.tr),t.arcTo(a+r,e+n,a+r-i.br,e+n,i.br),t.arcTo(a,e+n,a,e+n-i.bl,i.bl),t.arcTo(a,e,a+i.tl,e,i.tl)}function Xk(t,a,e,r){if(!e&&a===Qn)return;let{ctx:n,hoverAmount:i,theme:l,rect:o,highlighted:h,hoverX:c,hoverY:v,cell:{contentAlign:g}}=t,{x:d,y:u,width:p,height:z}=o,w=.35,s=e?1-w+w*i:.4;a===Qn&&(s*=i),s!==0&&(n.globalAlpha=s,U8(n,l,a,d,u,p,z,h,c,v,r,g),n.globalAlpha=1)}var Yn=4;function Yk(t,a){let{rect:e,theme:r,ctx:n,highlighted:i}=t,{x:l,y:o,width:h,height:c}=e,v=20,g=8,d=Yn,u=l+r.cellHorizontalPadding,p=[];for(let z of a){if(u>l+h)break;let w=$8(z,n,`${r.baseFontStyle} ${r.fontFamily}`).width;p.push({x:u,width:w}),u+=w+g*2+d}n.beginPath();for(let z of p)Ve(n,z.x,o+(c-v)/2,z.width+g*2,v,v/2);n.fillStyle=i?r.bgBubbleSelected:r.bgBubble,n.fill();for(let[z,w]of p.entries())n.beginPath(),n.fillStyle=r.textBubble,n.fillText(a[z],w.x+g,o+c/2+Na(n,r))}var V8={};function Qk(t,a,e){let r=Math.ceil(window.devicePixelRatio),n=5,i=e-n*2,l=4,o=6,h=e*r,c=o+n,v=o*3,g=(v+n*2)*r,d=`${t},${a},${r},${e}`;if(V8[d]!==void 0)return{el:V8[d],height:h,width:g,middleWidth:l*r,sideWidth:c*r,padding:n*r,dpr:r};let u=document.createElement("canvas"),p=u.getContext("2d");if(p===null)return null;u.width=g,u.height=h,p.scale(r,r),V8[d]=u;let z=Math.min(o,v/2,i/2);return p.beginPath(),Ve(p,n,n,v,i,z),p.shadowColor="rgba(24, 25, 34, 0.4)",p.shadowBlur=1,p.fillStyle=t,p.fill(),p.shadowColor="rgba(24, 25, 34, 0.3)",p.shadowOffsetY=1,p.shadowBlur=5,p.fillStyle=t,p.fill(),p.shadowOffsetY=0,p.shadowBlur=0,p.shadowBlur=0,p.beginPath(),Ve(p,n+.5,n+.5,v,i,z),p.strokeStyle=a,p.lineWidth=1,p.stroke(),{el:u,height:h,width:g,sideWidth:c*r,middleWidth:o*r,padding:n*r,dpr:r}}function Zk(t,a){let{rect:e,theme:r,ctx:n,imageLoader:i,col:l,row:o}=t,{x:h,width:c}=e,v=`${r.baseFontStyle} ${r.fontFamily}`,g=Rz(n,v),d=Math.min(e.height,Math.max(16,Math.ceil(g*r.lineHeight)*2)),u=Math.floor(e.y+(e.height-d)/2),p=d-10,z=8,w=Yn,s=h+r.cellHorizontalPadding,f=Qk(r.bgCell,r.drilldownBorder,d),m=[];for(let H of a){if(s>h+c)break;let y=$8(H.text,n,v).width,R=0;H.img!==void 0&&i.loadOrGetImage(H.img,l,o)!==void 0&&(R=p-8+4);let L=y+R+z*2;m.push({x:s,width:L}),s+=L+w}if(f!==null){let{el:H,height:x,middleWidth:y,sideWidth:R,width:L,dpr:V,padding:C}=f,k=R/V,b=C/V;for(let F of m){let _=Math.floor(F.x),j=Math.floor(F.width),n1=j-(k-b)*2;n.imageSmoothingEnabled=!1,n.drawImage(H,0,0,R,x,_-b,u,k,d),n1>0&&n.drawImage(H,R,0,y,x,_+(k-b),u,n1,d),n.drawImage(H,L-R,0,R,x,_+j-(k-b),u,k,d),n.imageSmoothingEnabled=!0}}n.beginPath();for(let[H,x]of m.entries()){let y=a[H],R=x.x+z;if(y.img!==void 0){let L=i.loadOrGetImage(y.img,l,o);if(L!==void 0){let V=p-8,C=0,k=0,b=L.width,F=L.height;b>F?(C+=(b-F)/2,b=F):F>b&&(k+=(F-b)/2,F=b),n.beginPath(),Ve(n,R,u+d/2-V/2,V,V,3),n.save(),n.clip(),n.drawImage(L,C,k,b,F,R,u+d/2-V/2,V,V),n.restore(),R+=V+4}}n.beginPath(),n.fillStyle=r.textBubble,n.fillText(y.text,R,u+d/2+Na(n,r))}}function Jk(t,a,e=4,r){let{rect:n,col:i,row:l,theme:o,ctx:h,imageLoader:c}=t,{x:v,y:g,height:d,width:u}=n,p=d-o.cellVerticalPadding*2,z=[],w=0;for(let f=0;f0&&(Ve(h,s,g+o.cellVerticalPadding,m,p,e),h.save(),h.clip()),h.drawImage(f,s,g+o.cellVerticalPadding,m,p),e>0&&h.restore(),s+=m+Yn}}function tb(t,a,e){let r=function(o,h){let c=h.x-o.x,v=h.y-o.y,g=Math.sqrt(c*c+v*v),d=c/g,u=v/g;return{x:c,y:h.y-o.y,len:g,nx:d,ny:u,ang:Math.atan2(u,d)}},n,i=a.length,l=a[i-1];for(let o=0;o1?1:d),z=1,w=!1;u<0?p<0?p=Math.PI+p:(p=Math.PI-p,z=-1,w=!0):p>0&&(z=-1,w=!0),n=h.radius!==void 0?h.radius:e;let s=p/2,f=Math.abs(Math.cos(s)*n/Math.sin(s)),m;f>Math.min(v.len/2,g.len/2)?(f=Math.min(v.len/2,g.len/2),m=Math.abs(f*Math.sin(s)/Math.cos(s))):m=n;let H=h.x+g.nx*f,x=h.y+g.ny*f;H+=-g.ny*m*z,x+=g.nx*m*z,t.arc(H,x,m,v.ang+Math.PI/2*z,g.ang-Math.PI/2*z,w),l=h,h=c}t.closePath()}function Kn(t,a,e,r,n,i,l,o,h,c,v,g,d,u,p){let z={x:0,y:i+c,width:0,height:0},w=i-n;if(t>=g){let s=l>t?-1:1,f=ur(u);z.x+=f+h;for(let m=l;m!==t;m+=s)z.x+=u[s===1?m:m-1].width*s}else for(let s=0;s0&&Zn(u[s-1].group,f)&&u[s-1].sticky===m;){let x=u[s-1];z.x-=x.width,z.width+=x.width,s--}let H=t;for(;H+1e&&(z.width=e-z.x)}}else if(d&&a===v-1){let s=typeof p=="number"?p:p(a);z.y=r-s,z.height=s}else{let s=o>a?-1:1;if(typeof p=="number"){let f=a-o;z.y+=f*p}else for(let f=o;f!==a;f+=s)z.y+=p(f)*s;z.height=(typeof p=="number"?p:p(a))+1}return z}var Ot='',ab=t=>{let a=t.fgColor,e=t.bgColor;return` + ${Ot}`},eb=t=>{let a=t.fgColor,e=t.bgColor;return` + ${Ot}`},rb=t=>{let a=t.fgColor,e=t.bgColor;return`${Ot} - `},$k=t=>{let a=t.fgColor,e=t.bgColor;return`${Ot} + `},nb=t=>{let a=t.fgColor,e=t.bgColor;return`${Ot} -`},Uk=t=>{let a=t.fgColor,e=t.bgColor;return`${Ot} +`},ib=t=>{let a=t.fgColor,e=t.bgColor;return`${Ot} An d="M7.66667 6.66669C5.73368 6.66669 4.16667 8.15907 4.16667 10C4.16667 11.841 5.73368 13.3334 7.66667 13.3334H12.3333C14.2663 13.3334 15.8333 11.841 15.8333 10C15.8333 8.15907 14.2663 6.66669 12.3333 6.66669H7.66667ZM12.5 12.5C13.8807 12.5 15 11.3807 15 10C15 8.61931 13.8807 7.50002 12.5 7.50002C11.1193 7.50002 10 8.61931 10 10C10 11.3807 11.1193 12.5 12.5 12.5Z" fill="${a}" /> -`},gz=t=>{let a=t.fgColor,e=t.bgColor;return`${Ot} +`},yz=t=>{let a=t.fgColor,e=t.bgColor;return`${Ot} - `},Wk=t=>{let a=t.bgColor;return`${Ot} + `},lb=t=>{let a=t.bgColor;return`${Ot} -`},jk=gz,qk=t=>{let a=t.fgColor,e=t.bgColor;return`${Ot} +`},ob=yz,hb=t=>{let a=t.fgColor,e=t.bgColor;return`${Ot} -`},Gk=t=>{let a=t.fgColor,e=t.bgColor;return` +`},cb=t=>{let a=t.fgColor,e=t.bgColor;return` ${Ot} @@ -99,104 +99,104 @@ Please report this to https://github.com/markedjs/marked.`,a.silent)return"

An - `},Kk=t=>{let a=t.fgColor,e=t.bgColor;return`${Ot} + `},vb=t=>{let a=t.fgColor,e=t.bgColor;return`${Ot} -`},Xk=t=>{let a=t.fgColor,e=t.bgColor;return` +`},gb=t=>{let a=t.fgColor,e=t.bgColor;return` ${Ot} - `},Yk=t=>{let a=t.fgColor,e=t.bgColor;return` + `},db=t=>{let a=t.fgColor,e=t.bgColor;return` ${Ot} - `},Qk=t=>{let a=t.fgColor,e=t.bgColor;return`${Ot} + `},sb=t=>{let a=t.fgColor,e=t.bgColor;return`${Ot} -`},Zk=t=>{let a=t.fgColor,e=t.bgColor;return` +`},ub=t=>{let a=t.fgColor,e=t.bgColor;return` ${Ot} - `},Jk=t=>{let a=t.fgColor,e=t.bgColor;return`${Ot} + `},fb=t=>{let a=t.fgColor,e=t.bgColor;return`${Ot} -`},tb=t=>{let a=t.fgColor,e=t.bgColor;return` +`},pb=t=>{let a=t.fgColor,e=t.bgColor;return` ${Ot} - `},ab=t=>{let a=t.fgColor,e=t.bgColor;return`${Ot} + `},zb=t=>{let a=t.fgColor,e=t.bgColor;return`${Ot} -`},eb=t=>{let a=t.fgColor,e=t.bgColor;return` +`},mb=t=>{let a=t.fgColor,e=t.bgColor;return` ${Ot} - `},rb=t=>{let a=t.fgColor,e=t.bgColor;return` + `},Mb=t=>{let a=t.fgColor,e=t.bgColor;return` ${Ot} - `},nb=t=>{let a=t.fgColor,e=t.bgColor;return`${Ot} + `},Hb=t=>{let a=t.fgColor,e=t.bgColor;return`${Ot} -`},ib=t=>{let a=t.fgColor,e=t.bgColor;return`${Ot} +`},xb=t=>{let a=t.fgColor,e=t.bgColor;return`${Ot} -`},lb=t=>{let a=t.fgColor,e=t.bgColor;return` +`},wb=t=>{let a=t.fgColor,e=t.bgColor;return` ${Ot} - `},ob=t=>{let a=t.fgColor,e=t.bgColor;return`${Ot} + `},Lb=t=>{let a=t.fgColor,e=t.bgColor;return`${Ot} -`},hb=t=>{let a=t.fgColor,e=t.bgColor;return` +`},Vb=t=>{let a=t.fgColor,e=t.bgColor;return` ${Ot} - `},cb=t=>{let a=t.fgColor,e=t.bgColor;return`${Ot} + `},Rb=t=>{let a=t.fgColor,e=t.bgColor;return`${Ot} -`},vb=t=>{let a=t.fgColor,e=t.bgColor;return`${Ot} +`},yb=t=>{let a=t.fgColor,e=t.bgColor;return`${Ot} -`},gb=t=>{let a=t.fgColor;return` +`},Cb=t=>{let a=t.fgColor;return` - `},db=t=>{let a=t.fgColor;return` + `},Bb=t=>{let a=t.fgColor;return` -`},sb={headerRowID:Ok,headerNumber:Nk,headerCode:Dk,headerString:$k,headerBoolean:Uk,headerAudioUri:jk,headerVideoUri:qk,headerEmoji:Gk,headerImage:Kk,headerUri:gz,headerPhone:Xk,headerMarkdown:Yk,headerDate:Qk,headerTime:Zk,headerEmail:Jk,headerReference:tb,headerIfThenElse:ab,headerSingleValue:eb,headerLookup:rb,headerTextTemplate:nb,headerMath:ib,headerRollup:lb,headerJoinStrings:ob,headerSplitString:hb,headerGeoDistance:cb,headerArray:vb,rowOwnerOverlay:gb,protectedColumnOverlay:db,renameIcon:Wk};function ub(t,a){return t==="normal"?[a.bgIconHeader,a.fgIconHeader]:t==="selected"?["white",a.accentColor]:[a.accentColor,a.bgHeader]}var fb=class{constructor(t,a){this.onSettled=a,this.spriteMap=new Map,this.inFlight=0,this.headerIcons={...sb,...t}}drawSprite(t,a,e,r,n,i,l,o=1){let[h,c]=ub(a,l),v=i*Math.ceil(window.devicePixelRatio),g=`${h}_${c}_${v}_${t}`,s=this.spriteMap.get(g);if(s===void 0){let d=this.headerIcons[t];if(d===void 0)return;s=document.createElement("canvas");let p=s.getContext("2d");if(p===null)return;let z=new Image;z.src=`data:image/svg+xml;charset=utf-8,${encodeURIComponent(d({fgColor:c,bgColor:h}))}`,this.spriteMap.set(g,s);let L=z.decode();if(L===void 0)return;this.inFlight++,L.then(()=>{p.drawImage(z,0,0,v,v)}).finally(()=>{this.inFlight--,this.inFlight===0&&this.onSettled()})}else o<1&&(e.globalAlpha=o),e.drawImage(s,0,0,v,v,r,n,i,i),o<1&&(e.globalAlpha=1)}},m8={},pe=null;function pb(){let t=document.createElement("div");return t.style.opacity="0",t.style.pointerEvents="none",t.style.position="fixed",document.body.append(t),t}function y8(t){let a=t.toLowerCase().trim();if(m8[a]!==void 0)return m8[a];pe=pe||pb(),pe.style.color="#000",pe.style.color=a;let e=getComputedStyle(pe).color;pe.style.color="#fff",pe.style.color=a;let r=getComputedStyle(pe).color;if(r!==e)throw new Error("Could not parse color");let n=r.replace(/[^\d.,]/g,"").split(",").map(Number.parseFloat);return n.length<4&&n.push(1),m8[a]=n,n}function ur(t,a){let[e,r,n]=y8(t);return`rgba(${e}, ${r}, ${n}, ${a})`}function me(t,a){if(a===void 0)return t;let[e,r,n,i]=y8(t);if(i===1)return t;let[l,o,h,c]=y8(a),v=i+c*(1-i),g=(i*e+c*l*(1-i))/v,s=(i*r+c*o*(1-i))/v,d=(i*n+c*h*(1-i))/v;return`rgba(${g}, ${s}, ${d}, ${v})`}var zb={kind:t1.Loading,allowOverlay:!1};function uz(t,a,e,r,n,i,l,o,h,c,v,g,s,d,p,z,L,u,f,m){let M,x;p!==void 0&&p[0][0]===r&&p[0][1]===a&&(M=p[1][0],x=p[1][1]);let y,w={ctx:t,theme:c,col:r,row:a,cell:e,rect:{x:n,y:i,width:l,height:o},highlighted:h,hoverAmount:d,hoverX:M,hoverY:x,imageLoader:g,spriteManager:s,hyperWrapping:z,requestAnimationFrame:()=>{V=!0}},V=!1;return(Ck(w,e.lastUpdated,L,u,()=>{var S,b;if(!(ze(e)?!1:v?.(w)===!0)){let C=m(e);if(C!==void 0){u?.renderer!==C&&((S=u?.deprep)==null||S.call(u,w),u=void 0);let T=(b=C.drawPrep)==null?void 0:b.call(C,w,u);C.draw(w,e),y={deprep:T?.deprep,fillStyle:T?.fillStyle,font:T?.font,renderer:C}}}})||V)&&f?.([r,a]),y}function mb(t,a,e,r,n,i,l,o,h,c,v,g,s,d,p,z,L){let u=[],f=!1;t.imageSmoothingEnabled=!1;let m=Math.min(e.cellYOffset,n),M=Math.max(e.cellYOffset,n),x=0;if(typeof z=="number")x+=(M-m)*z;else for(let C=m;Ce.cellYOffset&&(x=-x),x+=l-e.translateY;let y=Math.min(e.cellXOffset,r),w=Math.max(e.cellXOffset,r),V=0;for(let C=y;Ce.cellXOffset&&(V=-V),V+=i-e.translateX;let R=sr(p);if(R>0&&R++,V!==0&&x!==0)return{regions:[],yOnly:!1};let S=o?typeof z=="number"?z:z(v-1):0,b=h-R-Math.abs(V),E=c-g-S-Math.abs(x)-1;if(b>150&&E>150){f=V===0;let C={sx:0,sy:0,sw:h*s,sh:c*s,dx:0,dy:0,dw:h*s,dh:c*s};x>0?(C.sy=(g+1)*s,C.sh=E*s,C.dy=(x+g+1)*s,C.dh=E*s,u.push({x:0,y:g,width:h,height:x+1})):x<0&&(C.sy=(-x+g+1)*s,C.sh=E*s,C.dy=(g+1)*s,C.dh=E*s,u.push({x:0,y:c+x-S,width:h,height:-x+S})),V>0?(C.sx=R*s,C.sw=b*s,C.dx=(V+R)*s,C.dw=b*s,u.push({x:R-1,y:0,width:V+2,height:c})):V<0&&(C.sx=(R-V)*s,C.sw=b*s,C.dx=R*s,C.dw=b*s,u.push({x:h+V,y:0,width:-V,height:c})),t.setTransform(1,0,0,1,0,0),R>0&&V!==0&&x===0&&L&&t.drawImage(a,0,0,R*s,c*s,0,0,R*s,c*s),t.drawImage(a,C.sx,C.sy,C.sw,C.sh,C.dx,C.dy,C.dw,C.dh),t.scale(s,s)}return t.imageSmoothingEnabled=!0,{regions:u,yOnly:f}}function Mb(t,a,e,r,n,i,l,o,h,c){let v=[];return a!==t.cellXOffset||e!==t.cellYOffset||r!==t.translateX||n!==t.translateY||i4(h,e,r,n,o,(g,s,d,p)=>{if(g.sourceIndex===c){let z=Math.max(s,p)+1;return v.push({x:z,y:0,width:i-z,height:l}),!0}}),v}function Fp(t,a,e,r,n,i,l,o,h,c,v,g,s,d,p,z,L,u=!1){var f,m,M;if(h!==void 0){t.beginPath(),t.save(),t.rect(0,0,i,l);for(let W of h)t.rect(W.x+1,W.y+1,W.width-1,W.height-1);t.clip("evenodd")}let x=(f=L.horizontalBorderColor)!=null?f:L.borderColor,y=L.borderColor,w=0,V=i,R=0,S=l;if(o!==void 0&&o.length>0){w=Number.MAX_SAFE_INTEGER,R=Number.MAX_SAFE_INTEGER,V=Number.MIN_SAFE_INTEGER,S=Number.MIN_SAFE_INTEGER;for(let W of o)w=Math.min(w,W.x-1),V=Math.max(V,W.x+W.width+1),R=Math.min(R,W.y-1),S=Math.max(S,W.y+W.height+1)}let b=[];t.beginPath();let E=.5;for(let W=0;W=w&&i1<=V&&d(W+1)&&b.push({x1:i1,y1:Math.max(c,R),x2:i1,y2:Math.min(l,S),color:y})}let C=g(z-1),T=l-C+.5,I=p==="sticky";if(I&&b.push({x1:w,y1:T,x2:V,y2:T,color:x}),u!==!0){let W=v+.5,n1=e,i1=I?l-C:l;for(;W+n<=i1;){let g1=W+n;if(g1>=R&&g1<=S-1&&(!I||n1!==z-1||Math.abs(g1-T)>1)){let l1=s?.(n1);b.push({x1:w,y1:g1,x2:V,y2:g1,color:(M=(m=l1?.horizontalBorderColor)!=null?m:l1?.borderColor)!=null?M:x})}W+=g(n1),n1++}}let J=(0,sz.default)(b,W=>W.color);for(let W of Object.keys(J)){t.strokeStyle=W;for(let n1 of J[W])t.moveTo(n1.x1,n1.y1),t.lineTo(n1.x2,n1.y2);t.stroke(),t.beginPath()}h!==void 0&&t.restore()}function fz(t,a){let e=[],r=t.x+t.width-26*a.length,n=t.y+t.height/2-13,i=26,l=26;for(let o=0;o=t.x&&a<=t.x+t.width&&e>=t.y&&e<=t.y+t.height}function Hb(t,a,e,r,n,i,l,o,h,c,v,g){var s;let[p,z]=(s=i?.[0])!=null?s:[],L=0;Hz(a,e,r,n,(u,f,m,M,x,y)=>{var w,V;if(g!==void 0&&!g.some(C=>C[1]===-2&&C[0]>=u[0]&&C[0]<=u[1]))return;t.save(),t.beginPath(),t.rect(m,M,x,y),t.clip();let R=v(f),S=R?.overrideTheme===void 0?l:{...l,...R.overrideTheme},b=z===-2&&p!==void 0&&p>=u[0]&&p<=u[1],E=b?S.bgHeaderHovered:S.bgHeader;if(E!==l.bgHeader&&(t.fillStyle=E,t.fill()),t.fillStyle=(w=S.textGroupHeader)!=null?w:S.textHeader,R!==void 0){let C=m;if(R.icon!==void 0&&(o.drawSprite(R.icon,"normal",t,C+8,(n-20)/2,20,S),C+=26),t.fillText(R.name,C+8,n/2+_a(t,`${l.headerFontStyle} ${l.fontFamily}`)),R.actions!==void 0&&b){let T=fz({x:m,y:M,width:x,height:y},R.actions);t.beginPath();let I=T[0].x-10,J=m+x-I;t.rect(I,0,J,n);let W=t.createLinearGradient(I,0,I+J,0),n1=ur(E,0);W.addColorStop(0,n1),W.addColorStop(10/J,E),W.addColorStop(1,E),t.fillStyle=W,t.fill(),t.globalAlpha=.6;let[i1,g1]=(V=i?.[1])!=null?V:[-1,-1];for(let l1=0;l135){let x=r-35,y=r-35*.7,w=x/r,V=y/r,R=t.createLinearGradient(a,0,a+r,0),S=ur(u,0);R.addColorStop(0,u),R.addColorStop(w,u),R.addColorStop(V,S),R.addColorStop(1,S),t.fillStyle=R}else t.fillStyle=u;if(t.fillText(i.title,m,e+n/2+_a(t,`${o.headerFontStyle} ${o.fontFamily}`)),f&&i.hasMenu===!0){t.beginPath();let M=z.x+z.width/2-5.5,x=z.y+z.height/2-3;Ik(t,[{x:M,y:x},{x:M+11,y:x},{x:M+5.5,y:x+6}],1),t.fillStyle=u,t.fill()}}function xb(t,a,e,r,n,i,l,o,h,c,v,g,s,d,p,z,L,u,f){var m;let M=l+o;if(M<=0)return;t.fillStyle=g.bgHeader,t.fillRect(0,0,n,M);let[x,y]=(m=r?.[0])!=null?m:[],w=`${g.headerFontStyle} ${g.fontFamily}`;t.font=w,i4(a,0,i,0,M,(V,R,S,b)=>{var E,C,T;if(L!==void 0&&!L.some(j1=>j1[1]===-1&&j1[0]===V.sourceIndex))return;let I=Math.max(0,b-R);t.save(),t.beginPath(),t.rect(R+I,o,V.width-I,l),t.clip();let J=z((E=V.group)!=null?E:"").overrideTheme,W=V.themeOverride===void 0&&J===void 0?g:{...g,...J,...V.themeOverride};W.bgHeader!==g.bgHeader&&(t.fillStyle=W.bgHeader,t.fill());let n1=`${W.headerFontStyle} ${W.fontFamily}`;w!==n1&&(t.font=n1);let i1=v.columns.hasIndex(V.sourceIndex),g1=h!==void 0||c,l1=!g1&&y===-1&&x===V.sourceIndex,H1=g1?0:(T=(C=d.find(j1=>j1.item[0]===V.sourceIndex&&j1.item[1]===-1))==null?void 0:C.hoverAmount)!=null?T:0,f1=v?.current!==void 0&&v.current.cell[0]===V.sourceIndex,d1=i1?W.accentColor:f1?W.bgHeaderHasFocus:W.bgHeader,K1=e?o:0,X1=V.sourceIndex===0?0:1;i1?(t.fillStyle=d1,t.fillRect(R+X1,K1,V.width-X1,l)):(f1||H1>0)&&(t.beginPath(),t.rect(R+X1,K1,V.width-X1,l),f1&&(t.fillStyle=W.bgHeaderHasFocus,t.fill()),H1>0&&(t.globalAlpha=H1,t.fillStyle=W.bgHeaderHovered,t.fill(),t.globalAlpha=1)),mz(t,R,K1,V.width,l,V,i1,W,l1,f1,H1,s,u,f),t.restore()}),e&&Hb(t,a,n,i,o,r,g,s,d,p,z,L)}function He(t,a,e,r,n,i,l,o){return t<=n+l&&n<=t+e&&a<=i+o&&i<=a+r}function kp(t,a,e,r,n,i,l,o,h,c,v,g,s,d){if(s===void 0||s.length===0)return;let p=g==="sticky"?v(c-1):0;t.beginPath(),Hz(a,e,l,n,(z,L,u,f,m,M)=>{for(let x=0;x=z[0]&&y[0]<=z[1]){t.rect(u,f,m,M);break}}}),i4(a,h,l,o,i,(z,L,u,f,m)=>{let M=Math.max(0,f-L),x=L+M+1,y=z.width-M-1;for(let w=0;w{let b=!1;for(let E=0;E0&&t.rect(x,E,y,T)}})}),t.clip()}function Mz(t,a,e,r,n,i,l){var o,h;let[c,v]=t,g,s,d=(h=(o=l.find(p=>!p.sticky))==null?void 0:o.sourceIndex)!=null?h:0;if(v>d){let p=Math.max(c,d),z=a,L=r;for(let u=i.sourceIndex-1;u>=p;u--)z-=l[u].width,L+=l[u].width;for(let u=i.sourceIndex+1;u<=v;u++)L+=l[u].width;s={x:z,y:e,width:L,height:n}}if(d>c){let p=Math.min(v,d-1),z=a,L=r;for(let u=i.sourceIndex-1;u>=c;u--)z-=l[u].width,L+=l[u].width;for(let u=i.sourceIndex+1;u<=p;u++)L+=l[u].width;g={x:z,y:e,width:L,height:n}}return[g,s]}function bp(t,a,e,r,n,i,l,o,h,c,v,g,s,d,p,z,L,u,f,m,M,x,y,w,V,R,S,b,E,C,T){var I;let J=(I=f?.length)!=null?I:Number.MAX_SAFE_INTEGER,W=performance.now(),n1=`${E.baseFontStyle} ${E.fontFamily}`;t.font=n1;let i1,g1=new Set;return i4(a,o,i,l,n,(l1,H1,f1,d1,K1)=>{var X1;let j1=Math.max(0,d1-H1),P1=H1+j1,ct=n+1,b1=l1.width-j1,Q1=r-n-1;if(u.length>0){let c1=!1;for(let $=0;${t.save(),t.beginPath(),t.rect(P1,ct,b1,Q1),t.clip()},N=m.columns.hasIndex(l1.sourceIndex),u1=g((X1=l1.group)!=null?X1:"").overrideTheme,o1=l1.themeOverride===void 0&&u1===void 0?E:{...E,...u1,...l1.themeOverride},O=`${o1.baseFontStyle} ${o1.fontFamily}`;O!==n1&&(n1=O,t.font=O),j();let Q;return ai(K1,f1,r,h,c,L,(c1,$,s1,W1,k1)=>{var tt,C1,Ut,q;if($<0)return;if(f!==void 0){let lt=!1;for(let zt=0;zt0){let lt=!1;for(let zt=0;ztz1.span!==void 0&<>=z1.span[0]&<<=z1.span[1]);bt&&!p&&z?T0=0:bt&&(T0=Math.max(T0,1)),H2&&T0++,bt||(h1&&T0++,N&&!W1&&T0++);let Z0=z1.kind===t1.Protected?D1.bgCellMedium:D1.bgCell,qt;if((W1||Z0!==E.bgCell)&&(qt=me(Z0,qt)),T0>0||x1){x1&&(qt=me(D1.bgHeader,qt));for(let lt=0;ltlt[0]===l1.sourceIndex&<[1]===$)===!0&&(qt=me(D1.bgSearchResult,qt));if(x!==void 0)for(let lt of x){let zt=lt.range;zt.x<=l1.sourceIndex&&l1.sourceIndexlt.item[0]===l1.sourceIndex&<.item[1]===$);if(vt>10&&!xt){let lt=`${D1.baseFontStyle} ${D1.fontFamily}`;lt!==n1&&(t.font=lt,n1=lt),Q=uz(t,$,z1,l1.sourceIndex,F1,c1,vt,s1,T0>0,D1,y,w,V,(Ut=yt?.hoverAmount)!=null?Ut:0,S,b,W,Q,C,T)}return z1.style==="faded"&&(t.globalAlpha=1),J--,jt&&(t.restore(),(q=Q?.deprep)==null||q.call(Q,{ctx:t}),Q=void 0,j(),n1=O,t.font=O),J<=0}),t.restore(),J<=0}),i1}function wb(t,a,e,r,n,i,l,o,h,c,v,g,s,d,p,z,L,u){L!==void 0||a[a.length-1]!==e[a.length-1]||i4(a,h,l,o,i,(f,m,M,x,y)=>{if(f!==a[a.length-1])return;m+=f.width;let w=Math.max(m,x);w>r||(t.save(),t.beginPath(),t.rect(w,i+1,1e4,n-i-1),t.clip(),ai(y,M,n,c,v,p,(V,R,S,b)=>{if(!b&&z.length>0&&!z.some(J=>He(m,V,1e4,S,J.x,J.y,J.width,J.height)))return;let E=s.hasIndex(R),C=d.hasIndex(R);t.beginPath();let T=g?.(R),I=T===void 0?u:{...u,...T};I.bgCell!==u.bgCell&&(t.fillStyle=I.bgCell,t.fillRect(m,V,1e4,S)),C&&(t.fillStyle=I.bgHeader,t.fillRect(m,V,1e4,S)),E&&(t.fillStyle=I.accentLight,t.fillRect(m,V,1e4,S))}),t.restore())})}function Lb(t,a,e,r,n,i,l,o,h){var c;let v=!1;for(let p of a)if(!p.sticky){v=l(p.sourceIndex);break}let g=(c=h.horizontalBorderColor)!=null?c:h.borderColor,s=h.borderColor,d=v?sr(a):0;if(d!==0&&(t.beginPath(),t.moveTo(d+.5,0),t.lineTo(d+.5,r),t.strokeStyle=me(s,h.bgCell),t.stroke()),n){let p=o(i-1);t.beginPath(),t.moveTo(0,r-p+.5),t.lineTo(e,r-p+.5),t.strokeStyle=me(g,h.bgCell),t.stroke()}}function Vb(t,a,e,r,n,i,l,o,h,c,v,g,s,d,p){let z=p?.filter(m=>m.style!=="no-outline");if(z===void 0||z.length===0)return;let L=z.map(m=>{var M,x,y,w,V;let R=m.range,S=Xn(R.x,R.y,a,e,v,c+v,r,n,i,l,d,h,s,o,g);if(R.width===1&&R.height===1)return R.x=h){let E=Xn(h-1,R.y+R.height-1,a,e,v,c+v,r,n,i,l,d,h,s,o,g),C=Xn(h,R.y+R.height-1,a,e,v,c+v,r,n,i,l,d,h,s,o,g);return[{color:m.color,style:(y=m.style)!=null?y:"dashed",rect:{x:S.x,y:S.y,width:E.x+E.width-S.x,height:E.y+E.height-S.y}},{color:m.color,style:(w=m.style)!=null?w:"dashed",rect:{x:C.x,y:C.y,width:b.x+b.width-C.x,height:b.y+b.height-C.y}}]}else return[void 0,{color:m.color,style:(V=m.style)!=null?V:"dashed",rect:{x:S.x,y:S.y,width:b.x+b.width-S.x,height:b.y+b.height-S.y}}]}),u=sr(o),f=()=>{t.beginPath(),t.save();let m=!1,M=y=>{m!==y&&(t.setLineDash(y?[5,3]:[]),m=y)};t.lineWidth=1;for(let y of L){let[w]=y;w!==void 0&&He(0,0,a,e,w.rect.x,w.rect.y,w.rect.width,w.rect.height)&&(M(w.style==="dashed"),t.strokeStyle=ur(w.color,1),t.strokeRect(w.rect.x+1,w.rect.y+1,w.rect.width-2,w.rect.height-2))}let x=!1;for(let y of L){let[,w]=y;w!==void 0&&He(0,0,a,e,w.rect.x,w.rect.y,w.rect.width,w.rect.height)&&(M(w.style==="dashed"),!x&&w.rect.x{var S;return R.sourceIndex===((S=v.current)==null?void 0:S.cell[0])}))return;let[u,f]=v.current.cell,m=s(v.current.cell),M=(L=m.span)!=null?L:[u,u],x=d==="sticky"&&f===z-1,y=d==="sticky"&&!x?g(z-1)-1:0,w;if(i4(l,r,n,i,c,(R,S,b,E,C)=>{if(!(R.sticky&&u>R.sourceIndex)&&!(R.sourceIndexM[1]))return ai(C,b,e,z,g,d,(T,I,J)=>{if(I!==f)return;let W=S,n1=R.width;if(m.span!==void 0){let i1=Mz(m.span,S,T,R.width,J,R,o),g1=R.sticky?i1[0]:i1[1];g1!==void 0&&(W=g1.x,n1=g1.width)}return w=()=>{var i1,g1,l1,H1;E>W&&!R.sticky&&(t.beginPath(),t.rect(E,0,a-E,e),t.clip()),t.beginPath(),t.rect(W+.5,T+.5,n1,J),t.strokeStyle=(g1=(i1=R.themeOverride)==null?void 0:i1.accentColor)!=null?g1:h.accentColor,t.lineWidth=1,t.stroke(),p&&(t.beginPath(),t.rect(W+n1-4,T+J-4,4,4),t.fillStyle=(H1=(l1=R.themeOverride)==null?void 0:l1.accentColor)!=null?H1:h.accentColor,t.fill())},!0}),!0}),w===void 0)return;let V=()=>{t.save(),t.beginPath(),t.rect(0,c,a,e-c-y),t.clip(),w?.(),t.restore()};return V(),V}function Rb(t,a,e,r,n,i,l,o,h){let c=0;return i4(t,i,r,n,e,(v,g,s,d,p)=>(ai(p,s,a,l,o,h,(z,L,u,f)=>{f||(c=Math.max(L,c))}),!0)),c}function yb(t,a){if(a===void 0||t.width!==a.width||t.height!==a.height||t.theme!==a.theme||t.headerHeight!==a.headerHeight||t.rowHeight!==a.rowHeight||t.rows!==a.rows||t.getRowThemeOverride!==a.getRowThemeOverride||t.isFocused!==a.isFocused||t.isResizing!==a.isResizing||t.verticalBorder!==a.verticalBorder||t.getCellContent!==a.getCellContent||t.highlightRegions!==a.highlightRegions||t.selection!==a.selection||t.dragAndDropState!==a.dragAndDropState||t.prelightCells!==a.prelightCells||t.touchMode!==a.touchMode||t.scrolling!==a.scrolling)return!1;if(t.mappedColumns!==a.mappedColumns){if(t.mappedColumns.length>100||t.mappedColumns.length!==a.mappedColumns.length)return!1;let e;for(let r=0;rx:x;k1.save(),k1.beginPath(),C1.save(),C1.beginPath(),k1.textBaseline="middle",C1.textBaseline="middle",o1!==1&&(k1.scale(o1,o1),C1.scale(o1,o1));let h1=V8(s,h,l,z,v),x1=[],z1=u&&((r=V.current)==null?void 0:r.cell[1])===c&&g===0,F1=()=>{var Y1,D1;xb(k1,h1,d,d1,l,v,f,m,z,w,V,L,K1,H1,y,C,N,W,j1),Fp(k1,h1,c,v,g,l,o,void 0,void 0,m,c1,q,T,y,S,b,L,!0),k1.beginPath(),k1.moveTo(0,$-.5),k1.lineTo(l,$-.5),k1.strokeStyle=me((D1=(Y1=L.headerBottomBorderColor)!=null?Y1:L.horizontalBorderColor)!=null?D1:L.borderColor,L.bgHeader),k1.stroke(),z1&&M8(k1,l,o,c,v,g,h1,s,L,c1,V,q,E,S,R,b)};if(N!==void 0){let Y1=!1;N=N.filter(D1=>(Y1=Y1||D1[1]<0,D1[1]<0||He(h,c,h1.length,300,D1[0],D1[1],1,1)||He(0,c,p,300,D1[0],D1[1],1,1)||S&&He(h,b-1,h1.length,1,D1[0],D1[1],1,1))),N.length>0&&(kp(C1,h1,l,o,m,c1,v,g,c,b,q,S,N,!0),C1.fillStyle=L.bgCell,C1.fillRect(0,c1+1,l,o-c1-1),bp(C1,h1,s,o,c1,v,g,c,b,q,E,C,T,M,I,u,S,x1,N,V,n1,i1,J,g1,K1,H1,d1,f1,L,P1,ct),R&&u&&V.current!==void 0&&N.some(D1=>{var Mt,bt;return D1[0]===((Mt=V.current)==null?void 0:Mt.cell[0])&&D1[1]===((bt=V.current)==null?void 0:bt.cell[1])})&&M8(C1,l,o,c,v,g,h1,s,L,c1,V,q,E,S,R,b)),Y1&&(kp(k1,h1,l,c1,m,c1,v,g,c,b,q,S,N,!1),F1()),C1.restore(),k1.restore(),W1!==null&&(W1.fillStyle=L.bgCell,W1.fillRect(0,0,l,o),W1.drawImage(C1.canvas,0,0));return}if((O!==!0||h!==s1?.cellXOffset||v!==s1?.translateX||z1!==s1?.mustDrawFocusOnHeader)&&F1(),O===!0){i2(Ut!==void 0&&s1!==void 0);let{regions:Y1}=mb(C1,Ut,s1,h,c,v,g,S==="sticky",l,o,b,c1,o1,s,h1,x,u1);x1=Y1}else O!==!1&&(i2(s1!==void 0),x1=Mb(s1,h,c,v,g,l,o,c1,h1,O));Lb(C1,h1,l,o,S==="sticky",b,y,q,L);let vt=u?M8(C1,l,o,c,v,g,h1,s,L,c1,V,q,E,S,R,b):void 0,jt=Vb(C1,l,o,h,c,v,g,s,p,f,m,x,S==="sticky",b,i1);if(C1.fillStyle=L.bgCell,x1.length>0){C1.beginPath();for(let Y1 of x1)C1.rect(Y1.x,Y1.y,Y1.width,Y1.height);C1.clip(),C1.fill(),C1.beginPath()}else C1.fillRect(0,0,l,o);let xt=bp(C1,h1,s,o,c1,v,g,c,b,q,E,C,T,M,I,u,S,x1,N,V,n1,i1,J,g1,K1,H1,d1,f1,L,P1,ct);wb(C1,h1,s,l,o,c1,v,g,c,b,q,T,V.rows,M,S,x1,N,L),Fp(C1,h1,c,v,g,l,o,x1,xt,m,c1,q,T,y,S,b,L),vt?.(),jt?.(),W1!==null&&(W1.fillStyle=L.bgCell,W1.fillRect(0,0,l,o),W1.drawImage(C1.canvas,0,0));let kt=Rb(h1,o,c1,v,g,c,b,q,S);g1?.setWindow({x:h,y:c,width:h1.length,height:kt-c},p),l1.current={cellXOffset:h,cellYOffset:c,translateX:v,translateY:g,mustDrawFocusOnHeader:z1,lastBuffer:u1?tt===Q1?"a":"b":void 0},C1.restore(),k1.restore()}function ai(t,a,e,r,n,i,l){let o=a,h=t,c=i==="sticky";for(;o=e;v&&(c=!1,h=r-1);let g=n(h);if(v&&(o=e-g),!(c&&h===r-1)&&l(o,h,g,v,i!=="none"&&h===r-1)===!0||v)break;o+=g,h++}}function i4(t,a,e,r,n,i){let l=0,o=0,h=n+r;for(let c of t){let v=c.sticky?o:l+e;if(i(c,v,h,o,a)===!0)break;l+=c.width,o+=c.sticky?c.width:0}}function Hz(t,a,e,r,n){var i;let l=0,o=0;for(let h=0;ha?.[0]===e?.[0]&&a?.[1]===e?.[1],this.addToLeavingItems=a=>{this.leavingItems.some(r=>this.areSameItems(r.item,a.item))||this.leavingItems.push(a)},this.removeFromLeavingItems=a=>{var e;let r=this.leavingItems.find(n=>this.areSameItems(n.item,a));return this.leavingItems=this.leavingItems.filter(n=>n!==r),(e=r?.hoverAmount)!=null?e:0},this.cleanUpLeavingElements=()=>{this.leavingItems=this.leavingItems.filter(a=>a.hoverAmount>0)},this.shouldStep=()=>{let a=this.leavingItems.length>0,e=this.currentHoveredItem!==void 0&&this.currentHoveredItem.hoverAmount<1;return a||e},this.getAnimatingItems=()=>this.currentHoveredItem!==void 0?[...this.leavingItems,this.currentHoveredItem]:this.leavingItems.map(a=>({...a,hoverAmount:Bb(a.hoverAmount)})),this.step=a=>{if(this.lastAnimationTime===void 0)this.lastAnimationTime=a;else{let r=(a-this.lastAnimationTime)/Cb;for(let i of this.leavingItems)i.hoverAmount=(0,C8.default)(i.hoverAmount-r,0,1);this.currentHoveredItem!==void 0&&(this.currentHoveredItem.hoverAmount=(0,C8.default)(this.currentHoveredItem.hoverAmount+r,0,1));let n=this.getAnimatingItems();this.callback(n),this.cleanUpLeavingElements()}this.shouldStep()?(this.lastAnimationTime=a,window.requestAnimationFrame(this.step)):this.lastAnimationTime=void 0},this.setHovered=a=>{var e;if(!this.areSameItems((e=this.currentHoveredItem)==null?void 0:e.item,a)){if(this.currentHoveredItem!==void 0&&this.addToLeavingItems(this.currentHoveredItem),a!==void 0){let r=this.removeFromLeavingItems(a);this.currentHoveredItem={item:a,hoverAmount:r}}else this.currentHoveredItem=void 0;this.lastAnimationTime===void 0&&window.requestAnimationFrame(this.step)}}}},Ab=class{constructor(t){this.fn=t}get value(){var t;return(t=this.val)!=null?t:this.val=this.fn()}};function P8(t){return new Ab(t)}var Fb=P8(()=>window.navigator.userAgent.includes("Firefox")),xz=P8(()=>window.navigator.userAgent.includes("Mac OS")&&window.navigator.userAgent.includes("Safari")&&!window.navigator.userAgent.includes("Chrome")),B5=P8(()=>window.navigator.platform.toLowerCase().startsWith("mac"));function kb(t,a){for(let e of t)if(e[0]===a[0]&&e[1]===a[1])return!0;return!1}function bb(t){let a=r4.useRef([]),e=r4.useRef(0),r=r4.useRef(t);r.current=t;let n=r4.useCallback(()=>{let i=()=>window.requestAnimationFrame(l),l=()=>{let o=a.current;a.current=[],r.current(o),a.current.length>0?e.current++:e.current=0};window.requestAnimationFrame(e.current>600?i:l)},[]);return r4.useCallback(i=>{kb(a.current,i)||(a.current.length===0&&n(),a.current.push(i))},[n])}var Eb=(t,a)=>{var e;if(t.kind===t1.Custom)return t.copyData;let r=a?.(t);return(e=r?.getAccessibilityString(t))!=null?e:""},_b=(t,a)=>{var e,r,n,i,l,o,h,c;let{width:v,height:g,accessibilityHeight:s,columns:d,cellXOffset:p,cellYOffset:z,headerHeight:L,fillHandle:u=!1,groupHeaderHeight:f,rowHeight:m,rows:M,getCellContent:x,getRowThemeOverride:y,onHeaderMenuClick:w,enableGroups:V,isFilling:R,onCanvasFocused:S,onCanvasBlur:b,isFocused:E,selection:C,freezeColumns:T,onContextMenu:I,trailingRowType:J,fixedShadowX:W=!0,fixedShadowY:n1=!0,drawFocusRing:i1=!0,onMouseDown:g1,onMouseUp:l1,onMouseMoveRaw:H1,onMouseMove:f1,onItemHovered:d1,dragAndDropState:K1,firstColAccessible:X1,onKeyDown:j1,onKeyUp:P1,highlightRegions:ct,canvasRef:b1,onDragStart:Q1,onDragEnd:j,eventTargetRef:N,isResizing:u1,isDragging:o1,isDraggable:O=!1,allowResize:Q,disabledRows:c1,getGroupDetails:$,theme:s1,prelightCells:W1,headerIcons:k1,verticalBorder:tt,drawHeader:C1,drawCustomCell:Ut,onCellFocused:q,onDragOverCell:h1,onDrop:x1,onDragLeave:z1,imageWindowLoader:F1,smoothScrollX:vt=!1,smoothScrollY:jt=!1,experimental:xt,getCellRenderer:kt}=t,Y1=(e=t.translateX)!=null?e:0,D1=(r=t.translateY)!=null?r:0,Mt=Math.max(T,Math.min(d.length-1,p)),bt=r1.useRef(null),T0=r1.useMemo(()=>new ck,[]),H2=F1??T0,Z0=r1.useRef(),[qt,yt]=r1.useState(!1),lt=r1.useRef([]),zt=r1.useRef(),[Ct,_2]=r1.useState(),[s0,H0]=r1.useState(),o2=r1.useRef(null),[J0,h2]=r1.useState(!1),Ta=r1.useRef(J0);Ta.current=J0;let fa=r1.useMemo(()=>new fb(k1,()=>{l4.current=void 0,ye.current()}),[k1]),e0=V?f+L:L,ta=r1.useRef(-1),Ve=xt?.enableFirefoxRescaling!==!0;r1.useLayoutEffect(()=>{!Fb.value||window.devicePixelRatio===1||Ve||(ta.current!==-1&&yt(!0),window.clearTimeout(ta.current),ta.current=window.setTimeout(()=>{yt(!1),ta.current=-1},200))},[z,Mt,Y1,D1,Ve]);let u0=mk(d,T),r0=r1.useCallback((F,U,S1)=>{let m1=F.getBoundingClientRect();if(U>=u0.length||S1>=M)return;let N1=m1.width/v,y1=Xn(U,S1,v,g,f,e0,Mt,z,Y1,D1,M,T,J==="sticky",u0,m);return N1!==1&&(y1.x*=N1,y1.y*=N1,y1.width*=N1,y1.height*=N1),y1.x+=m1.x,y1.y+=m1.y,y1},[v,g,f,e0,Mt,z,Y1,D1,M,T,J,u0,m]),P0=r1.useCallback((F,U,S1,m1)=>{var N1,y1;let p1=F.getBoundingClientRect(),At=p1.width/v,$1=(U-p1.left)/At,ut=(S1-p1.top)/At,I0=5,ot=V8(u0,Mt,v,void 0,Y1),wt=0;m1 instanceof MouseEvent&&(wt=m1.button);let et=xk($1,ot,Y1),Ht=wk(ut,g,V,L,f,M,m,z,D1,J==="sticky"),c0=m1?.shiftKey===!0,Ma=m1?.ctrlKey===!0,Ha=m1?.metaKey===!0,g2=m1!==void 0&&!(m1 instanceof MouseEvent),Et=20,Gt=[Math.abs($1)v||ut>g){let J1=$1>v?-1:$1<0?1:0,xa=ut>g?1:ut<0?-1:0,w2=!1;if(et===-1&&Ht===-1){let n0=r0(F,u0.length-1,-1);i2(n0!==void 0),w2=U=0?(xa=!0,J1=r0(F,w2,Ht),i2(J1!==void 0),p0={kind:V&&Ht===-2?b2:t4,location:[w2,Ht],bounds:J1,group:(N1=u0[w2].group)!=null?N1:"",isEdge:xa,shiftKey:c0,ctrlKey:Ma,metaKey:Ha,isTouch:g2,localEventX:U-J1.x,localEventY:S1-J1.y,button:wt,scrollEdge:Gt}):p0={kind:V&&Ht===-2?b2:t4,group:(y1=u0[et].group)!=null?y1:"",location:[et,Ht],bounds:J1,isEdge:xa,shiftKey:c0,ctrlKey:Ma,metaKey:Ha,isTouch:g2,localEventX:U-J1.x,localEventY:S1-J1.y,button:wt,scrollEdge:Gt}}else{let J1=r0(F,et,Ht);i2(J1!==void 0);let xa=J1!==void 0&&J1.x+J1.width-U{}),Ia=r1.useRef(Ct);Ia.current=Ct;let[ea,Re]=r1.useMemo(()=>{let F=document.createElement("canvas"),U=document.createElement("canvas");return F.style.display="none",F.style.opacity="0",F.style.position="fixed",U.style.display="none",U.style.opacity="0",U.style.position="fixed",[F,U]},[]);r1.useLayoutEffect(()=>(document.documentElement.append(ea),document.documentElement.append(Re),()=>{ea.remove(),Re.remove()}),[ea,Re]);let l4=r1.useRef(),o4=r1.useCallback(()=>{var F,U;let S1=bt.current,m1=o2.current;if(S1===null||m1===null)return;let N1=l4.current,y1={canvas:S1,bufferA:ea,bufferB:Re,headerCanvas:m1,width:v,height:g,cellXOffset:Mt,cellYOffset:z,translateX:Math.round(Y1),translateY:Math.round(D1),mappedColumns:u0,enableGroups:V,freezeColumns:T,dragAndDropState:K1,theme:s1,headerHeight:L,groupHeaderHeight:f,disabledRows:c1??pt.empty(),rowHeight:m,verticalBorder:tt,isResizing:u1,isFocused:E,selection:C,fillHandle:u,lastRowSticky:J,rows:M,drawFocus:i1,getCellContent:x,getGroupDetails:$??(p1=>({name:p1})),getRowThemeOverride:y,drawCustomCell:Ut,drawHeaderCallback:C1,prelightCells:W1,highlightRegions:ct,imageLoader:H2,lastBlitData:zt,damage:Z0.current,hoverValues:lt.current,hoverInfo:Ia.current,spriteManager:fa,scrolling:qt,hyperWrapping:(F=xt?.hyperWrapping)!=null?F:!1,touchMode:J0,enqueue:Pa.current,renderStrategy:(U=xt?.renderStrategy)!=null?U:xz.value?"double-buffer":"single-buffer",getCellRenderer:kt};y1.damage===void 0?(l4.current=y1,Ep(y1,N1)):Ep(y1,void 0)},[ea,Re,v,g,Mt,z,Y1,D1,u0,V,T,K1,s1,L,f,c1,m,tt,u1,E,C,u,J,M,i1,x,$,y,Ut,C1,W1,ct,H2,fa,qt,xt?.hyperWrapping,xt?.renderStrategy,J0,kt]),ye=r1.useRef(o4);r1.useLayoutEffect(()=>{o4(),ye.current=o4},[o4]),r1.useLayoutEffect(()=>{(async()=>{var U;((U=document?.fonts)==null?void 0:U.ready)!==void 0&&(await document.fonts.ready,l4.current=void 0,ye.current())})()},[]);let pa=r1.useCallback(F=>{Z0.current=F,ye.current(),Z0.current=void 0},[]),N5=bb(pa);Pa.current=N5;let ri=r1.useCallback(F=>{pa(F.map(U=>U.cell))},[pa]);H2.setCallback(pa);let[ni,h4]=r1.useState(!1),[za,ma]=aa??[],T2=za!==void 0&&ma===-1,Oa=za!==void 0&&ma===-2,Ce=!1,ii=!1,li;if(za!==void 0&&ma!==void 0&&ma>-1){let F=x([za,ma]);Ce=F.kind===l2.NewRow||F.kind===l2.Marker&&F.markerKind!=="number",ii=F.kind===t1.Boolean&&L8(F),li=F.cursor}let c4=o1?"grabbing":(s0??!1)||u1?"col-resize":ni||R?"crosshair":li!==void 0?li:T2||Ce||ii||Oa?"pointer":"default",x0=r1.useMemo(()=>({contain:"strict",display:"block",cursor:c4}),[c4]),v4=r1.useRef("default"),g4=N?.current;g4!=null&&v4.current!==x0.cursor&&(g4.style.cursor=v4.current=x0.cursor);let Be=r1.useCallback((F,U,S1,m1)=>{if($===void 0)return;let N1=$(F);if(N1.actions!==void 0){let y1=fz(U,N1.actions);for(let[p1,At]of y1.entries())if(pz(At,S1+U.x,m1+At.y))return N1.actions[p1]}},[$]),Se=r1.useCallback((F,U,S1,m1)=>{let N1=d[U];if(!o1&&!u1&&N1.hasMenu===!0&&!(s0??!1)){let y1=r0(F,U,-1);i2(y1!==void 0);let p1=zz(y1.x,y1.y,y1.width,y1.height);if(S1>p1.x&&S1p1.y&&m1{let U=bt.current,S1=N?.current;if(U===null||F.target!==U&&F.target!==S1)return;let m1,N1;if(F instanceof MouseEvent?(m1=F.clientX,N1=F.clientY):(m1=F.touches[0].clientX,N1=F.touches[0].clientY),F.target===S1&&S1!==null){let p1=S1.getBoundingClientRect();if(m1>p1.left+S1.clientWidth||N1>p1.top+S1.clientHeight)return}let y1=P0(U,m1,N1,F);st.current=y1.location,y1.isTouch&&(Hr.current=Date.now()),Ta.current!==y1.isTouch&&h2(y1.isTouch),!(y1.kind===t4&&Se(U,y1.location[0],m1,N1)!==void 0)&&(y1.kind===b2&&Be(y1.group,y1.bounds,y1.localEventX,y1.localEventY)!==void 0||(g1?.(y1),!y1.isTouch&&O!==!0&&O!==y1.kind&&F.preventDefault()))},[N,O,P0,Be,Se,g1]);Q0("touchstart",Da,window,!1),Q0("mousedown",Da,window,!1);let c2=r1.useCallback(F=>{var U,S1;let m1=bt.current;if(l1===void 0||m1===null)return;let N1=N?.current,y1=F.target!==m1&&F.target!==N1,p1,At;F instanceof MouseEvent?(p1=F.clientX,At=F.clientY):(p1=F.changedTouches[0].clientX,At=F.changedTouches[0].clientY);let $1=P0(m1,p1,At,F);if($1.isTouch&&Hr.current!==0&&Date.now()-Hr.current>500&&($1={...$1,isLongTouch:!0}),Ta.current!==$1.isTouch&&h2($1.isTouch),!y1&&F.cancelable&&F.preventDefault(),$1.kind===t4&&Se(m1,$1.location[0],p1,At)){let[ut]=$1.location,I0=Se(m1,ut,p1,At);if(I0!==void 0){$1.button===0&&((U=st.current)==null?void 0:U[0])===ut&&((S1=st.current)==null?void 0:S1[1])===-1?w?.(ut,I0):l1($1,!0);return}}else if($1.kind===b2){let ut=Be($1.group,$1.bounds,$1.localEventX,$1.localEventY);if(ut!==void 0){$1.button===0&&ut.onClick($1);return}}l1($1,y1)},[l1,N,P0,Se,w,Be]);Q0("mouseup",c2,window,!1),Q0("touchend",c2,window,!1);let P=r1.useCallback(F=>{let U=bt.current;if(U===null||I===void 0)return;let S1=P0(U,F.clientX,F.clientY,F);I(S1,()=>{F.cancelable&&F.preventDefault()})},[P0,I]);Q0("contextmenu",P,(n=N?.current)!=null?n:null,!1);let w0=r1.useCallback(F=>{Z0.current=F.map(U=>U.item),lt.current=F,ye.current(),Z0.current=void 0},[]),v2=r1.useMemo(()=>new Sb(w0),[w0]),oi=r1.useRef(v2);oi.current=v2,r1.useLayoutEffect(()=>{let F=oi.current;if(aa===void 0||aa[1]<0){F.setHovered(aa);return}let U=x(aa),S1=kt(U);F.setHovered(S1===void 0&&U.kind===t1.Custom||S1?.needsHover===!0?aa:void 0)},[x,kt,aa]);let xr=r1.useRef(),U5=r1.useCallback(F=>{var U;let S1=bt.current;if(S1===null)return;let m1=P0(S1,F.clientX,F.clientY,F);if(!D5(m1,xr.current))d1?.(m1),_2(m1.kind===b5?void 0:[m1.location,[m1.localEventX,m1.localEventY]]),xr.current=m1;else if(m1.kind==="cell"||m1.kind===t4||m1.kind===b2){let N1=[m1.location,[m1.localEventX,m1.localEventY]];if(_2(N1),Ia.current=N1,m1.kind==="cell"){let y1=x(m1.location);(y1.kind===t1.Custom||((U=kt(y1))==null?void 0:U.needsHoverPosition)===!0)&&pa([m1.location])}else m1.kind===b2&&pa([m1.location])}if(H0(m1.kind===t4&&m1.isEdge&&Q===!0),u&&C.current!==void 0){let[N1,y1]=C.current.cell,p1=r0(S1,N1,y1),At=F.clientX,$1=F.clientY;i2(p1!==void 0),h4(At>=p1.x+p1.width-6&&At<=p1.x+p1.width&&$1>=p1.y+p1.height-6&&$1<=p1.y+p1.height)}else h4(!1);H1?.(F),f1(m1)},[P0,Q,u,C,H1,f1,d1,x,kt,pa,r0]);Q0("mousemove",U5,window,!0);let W5=r1.useCallback(F=>{let U=bt.current;if(U===null)return;let S1;C.current!==void 0&&(S1=r0(U,C.current.cell[0],C.current.cell[1])),j1?.({bounds:S1,stopPropagation:()=>F.stopPropagation(),preventDefault:()=>F.preventDefault(),cancel:()=>{},ctrlKey:F.ctrlKey,metaKey:F.metaKey,shiftKey:F.shiftKey,altKey:F.altKey,key:F.key,keyCode:F.keyCode,rawEvent:F})},[j1,C,r0]),hi=r1.useCallback(F=>{let U=bt.current;if(U===null)return;let S1;C.current!==void 0&&(S1=r0(U,C.current.cell[0],C.current.cell[1])),P1?.({bounds:S1,stopPropagation:()=>F.stopPropagation(),preventDefault:()=>F.preventDefault(),cancel:()=>{},ctrlKey:F.ctrlKey,metaKey:F.metaKey,shiftKey:F.shiftKey,altKey:F.altKey,key:F.key,keyCode:F.keyCode,rawEvent:F})},[P1,C,r0]),G=r1.useCallback(F=>{bt.current=F,b1!==void 0&&(b1.current=F)},[b1]),x2=r1.useCallback(F=>{let U=bt.current;if(U===null||O===!1||u1){F.preventDefault();return}let S1,m1,N1=P0(U,F.clientX,F.clientY);if(O!==!0&&N1.kind!==O){F.preventDefault();return}let y1=(ot,wt)=>{S1=ot,m1=wt},p1,At,$1,ut=(ot,wt,et)=>{p1=ot,At=wt,$1=et},I0=!1;if(Q1?.({...N1,setData:y1,setDragImage:ut,preventDefault:()=>I0=!0,defaultPrevented:()=>I0}),!I0&&S1!==void 0&&m1!==void 0&&F.dataTransfer!==null)if(F.dataTransfer.setData(S1,m1),F.dataTransfer.effectAllowed="copyLink",p1!==void 0&&At!==void 0&&$1!==void 0)F.dataTransfer.setDragImage(p1,At,$1);else{let[ot,wt]=N1.location;if(wt!==void 0){let et=document.createElement("canvas"),Ht=r0(U,ot,wt);i2(Ht!==void 0),et.width=Ht.width,et.height=Ht.height;let c0=et.getContext("2d");c0!==null&&(c0.textBaseline="middle",wt===-1?(c0.font=`${s1.headerFontStyle} ${s1.fontFamily}`,c0.fillStyle=s1.bgHeader,c0.fillRect(0,0,et.width,et.height),mz(c0,0,0,Ht.width,Ht.height,u0[ot],!1,s1,!1,!1,0,fa,C1,!1)):(c0.font=`${s1.baseFontStyle} ${s1.fontFamily}`,c0.fillStyle=s1.bgCell,c0.fillRect(0,0,et.width,et.height),uz(c0,wt,x([ot,wt]),0,0,0,Ht.width,Ht.height,!1,s1,Ut,H2,fa,1,void 0,!1,0,void 0,void 0,kt))),et.style.left="-100%",et.style.position="absolute",document.body.append(et),F.dataTransfer.setDragImage(et,Ht.width/2,Ht.height/2),window.setTimeout(()=>{et.remove()},0)}}else F.preventDefault()},[O,u1,P0,Q1,r0,s1,u0,fa,C1,x,Ut,H2,kt]);Q0("dragstart",x2,(i=N?.current)!=null?i:null,!1,!1);let L0=r1.useRef(),j5=r1.useCallback(F=>{var U;let S1=bt.current;if(x1!==void 0&&F.preventDefault(),S1===null||h1===void 0)return;let m1=P0(S1,F.clientX,F.clientY),[N1,y1]=m1.location,p1=N1-(X1?0:1),[At,$1]=(U=L0.current)!=null?U:[];(At!==p1||$1!==y1)&&(L0.current=[p1,y1],h1([p1,y1],F.dataTransfer))},[X1,P0,h1,x1]);Q0("dragover",j5,(l=N?.current)!=null?l:null,!1,!1);let q5=r1.useCallback(()=>{L0.current=void 0,j?.()},[j]);Q0("dragend",q5,(o=N?.current)!=null?o:null,!1,!1);let d4=r1.useCallback(F=>{let U=bt.current;if(U===null||x1===void 0)return;F.preventDefault();let S1=P0(U,F.clientX,F.clientY),[m1,N1]=S1.location,y1=m1-(X1?0:1);x1([y1,N1],F.dataTransfer)},[X1,P0,x1]);Q0("drop",d4,(h=N?.current)!=null?h:null,!1,!1);let ra=r1.useCallback(()=>{z1?.()},[z1]);Q0("dragleave",ra,(c=N?.current)!=null?c:null,!1,!1);let Na=r1.useRef(C);Na.current=C;let s4=r1.useRef(null),wr=r1.useCallback(F=>{var U;bt.current===null||!bt.current.contains(document.activeElement)||(F===null&&Na.current.current!==void 0?(U=b1?.current)==null||U.focus({preventScroll:!0}):F!==null&&F.focus({preventScroll:!0}),s4.current=F)},[b1]);r1.useImperativeHandle(a,()=>({focus:()=>{var F;let U=s4.current;U===null||!document.contains(U)?(F=b1?.current)==null||F.focus({preventScroll:!0}):U.focus({preventScroll:!0})},getBounds:(F,U)=>{if(!(b1===void 0||b1.current===null))return r0(b1.current,F,U??-1)},damage:ri}),[b1,ri,r0]);let Lr=r1.useRef(),Vr=dk(()=>{var F,U,S1,m1;if(v<50)return null;let N1=V8(u0,Mt,v,K1,Y1),y1=X1?0:-1;!X1&&((F=N1[0])==null?void 0:F.sourceIndex)===0&&(N1=N1.slice(1));let[p1,At]=(S1=(U=C.current)==null?void 0:U.cell)!=null?S1:[],$1=(m1=C.current)==null?void 0:m1.range,ut=N1.map(ot=>ot.sourceIndex),I0=(0,dz.default)(z,Math.min(M,z+s));return p1!==void 0&&At!==void 0&&!(ut.includes(p1)&&I0.includes(At))&&wr(null),r1.createElement("table",{key:"access-tree",role:"grid","aria-rowcount":M+1,"aria-multiselectable":"true","aria-colcount":u0.length+y1},r1.createElement("thead",{role:"rowgroup"},r1.createElement("tr",{role:"row","aria-rowindex":1},N1.map(ot=>r1.createElement("th",{role:"columnheader","aria-selected":C.columns.hasIndex(ot.sourceIndex),"aria-colindex":ot.sourceIndex+1+y1,tabIndex:-1,onFocus:wt=>{if(wt.target!==s4.current)return q?.([ot.sourceIndex,-1])},key:ot.sourceIndex},ot.title)))),r1.createElement("tbody",{role:"rowgroup"},I0.map(ot=>r1.createElement("tr",{role:"row","aria-selected":C.rows.hasIndex(ot),key:ot,"aria-rowindex":ot+2},N1.map(wt=>{let et=wt.sourceIndex,Ht=`${et},${ot}`,c0=p1===et&&At===ot,Ma=$1!==void 0&&et>=$1.x&&et<$1.x+$1.width&&ot>=$1.y&&ot<$1.y+$1.height,Ha=`glide-cell-${et}-${ot}`,g2=x([et,ot]);return r1.createElement("td",{key:Ht,role:"gridcell","aria-colindex":et+1+y1,"aria-selected":Ma,"aria-readonly":ze(g2)||!vr(g2),id:Ha,"data-testid":Ha,onClick:()=>{let Et=b1?.current;if(Et!=null)return j1?.({bounds:r0(Et,et,ot),cancel:()=>{},preventDefault:()=>{},stopPropagation:()=>{},ctrlKey:!1,key:"Enter",keyCode:13,metaKey:!1,shiftKey:!1,altKey:!1,rawEvent:void 0})},onFocusCapture:Et=>{var Gt,p0;if(!(Et.target===s4.current||((Gt=Lr.current)==null?void 0:Gt[0])===et&&((p0=Lr.current)==null?void 0:p0[1])===ot))return Lr.current=[et,ot],q?.([et,ot])},ref:c0?wr:void 0,tabIndex:-1},Eb(g2,kt))})))))},[v,u0,Mt,K1,Y1,M,z,s,C,wr,x,b1,j1,r0,q],200),f0=W?sr(u0,K1):0,o0=T===0||!W?0:Mt>T?1:(0,R8.default)(-Y1/100,0,1),h0=-z*32+D1,A0=n1?(0,R8.default)(-h0/100,0,1):0,u4=r1.useMemo(()=>{if(!o0&&!A0)return null;let F={position:"absolute",top:0,left:f0,width:v-f0,height:g,opacity:o0,pointerEvents:"none",transition:vt?void 0:"opacity 0.2s",boxShadow:"inset 13px 0 10px -13px rgba(0, 0, 0, 0.2)"},U={position:"absolute",top:e0,left:0,width:v,height:g,opacity:A0,pointerEvents:"none",transition:jt?void 0:"opacity 0.2s",boxShadow:"inset 0 13px 10px -13px rgba(0, 0, 0, 0.2)"};return r1.createElement(r1.Fragment,null,o0>0&&r1.createElement("div",{id:"shadow-x",style:F}),A0>0&&r1.createElement("div",{id:"shadow-y",style:U}))},[o0,A0,f0,v,vt,e0,g,jt]),G5=r1.useMemo(()=>({position:"absolute",top:0,left:0}),[]);return r1.createElement(r1.Fragment,null,r1.createElement("canvas",{"data-testid":"data-grid-canvas",tabIndex:0,onKeyDown:W5,onKeyUp:hi,onFocus:S,onBlur:b,ref:G,style:x0},Vr),r1.createElement("canvas",{ref:o2,style:G5}),u4)},Tb=r1.memo(r1.forwardRef(_b));function Gn(t,a,e,r){var n;return(0,az.default)(Math.round(a-((n=t.growOffset)!=null?n:0)),Math.ceil(e),Math.floor(r))}var Pb=t=>{var a;let[e,r]=It.useState(),[n,i]=It.useState(),[l,o]=It.useState(),[h,c]=It.useState(),[v,g]=It.useState(!1),[s,d]=It.useState(),[p,z]=It.useState(),[L,u]=It.useState(),[f,m]=It.useState(!1),[M,x]=It.useState(),{onHeaderMenuClick:y,getCellContent:w,onColumnMoved:V,onColumnResize:R,onColumnResizeStart:S,onColumnResizeEnd:b,gridRef:E,maxColumnWidth:C,minColumnWidth:T,onRowMoved:I,lockColumns:J,onMouseDown:W,onMouseUp:n1,onItemHovered:i1,onDragStart:g1}=t,l1=((a=R??b)!=null?a:S)!==void 0,{columns:H1,selection:f1}=t,d1=f1.columns,K1=It.useCallback(O=>{let[Q,c1]=O.location;l!==void 0&&h!==Q&&Q>=J?(g(!0),c(Q)):p!==void 0&&c1!==void 0?(m(!0),u(Math.max(0,c1))):i1?.(O)},[l,p,h,i1,J]),X1=V!==void 0,j1=It.useCallback(O=>{var Q,c1;if(O.button===0){let[$,s1]=O.location;if(O.kind==="out-of-bounds"&&O.isEdge&&l1){let W1=(Q=E?.current)==null?void 0:Q.getBounds(H1.length-1,-1);W1!==void 0&&(r(W1.x),i(H1.length-1))}else O.kind==="header"&&$>=J?O.isEdge&&l1?(r(O.bounds.x),i($),S?.(H1[$],O.bounds.width,$,O.bounds.width+((c1=H1[$].growOffset)!=null?c1:0))):O.kind==="header"&&X1&&(d(O.bounds.x),o($)):O.kind==="cell"&&J>0&&$===0&&s1!==void 0&&I!==void 0&&(x(O.bounds.y),z(s1))}W?.(O)},[W,l1,J,I,E,H1,X1,S]),P1=It.useCallback((O,Q)=>{v||f||y?.(O,Q)},[v,f,y]),ct=It.useRef(-1),b1=It.useCallback(()=>{ct.current=-1,z(void 0),u(void 0),x(void 0),m(!1),o(void 0),c(void 0),d(void 0),g(!1),i(void 0),r(void 0)},[]),Q1=It.useCallback((O,Q)=>{var c1,$,s1;if(O.button===0){if(n!==void 0){if(d1?.hasIndex(n)===!0)for(let k1 of d1){if(k1===n)continue;let tt=H1[k1],C1=Gn(tt,ct.current,T,C);R?.(tt,C1,k1,C1+((c1=tt.growOffset)!=null?c1:0))}let W1=Gn(H1[n],ct.current,T,C);b?.(H1[n],W1,n,W1+(($=H1[n].growOffset)!=null?$:0));for(let k1 of d1){if(k1===n)continue;let tt=H1[k1],C1=Gn(tt,ct.current,T,C);b?.(tt,C1,k1,C1+((s1=tt.growOffset)!=null?s1:0))}}b1(),l!==void 0&&h!==void 0&&V?.(l,h),p!==void 0&&L!==void 0&&I?.(p,L)}n1?.(O,Q)},[n1,n,l,h,p,L,d1,b,H1,T,C,R,V,I,b1]),j=It.useMemo(()=>{if(!(l===void 0||h===void 0)&&l!==h)return{src:l,dest:h}},[l,h]),N=It.useCallback(O=>{var Q,c1;if(l!==void 0&&s!==void 0)Math.abs(O.clientX-s)>20&&g(!0);else if(p!==void 0&&M!==void 0)Math.abs(O.clientY-M)>20&&m(!0);else if(n!==void 0&&e!==void 0){let $=H1[n],s1=O.clientX-e,W1=Gn($,s1,T,C);if(R?.($,W1,n,W1+((Q=$.growOffset)!=null?Q:0)),ct.current=s1,d1?.first()===n)for(let k1 of d1){if(k1===n)continue;let tt=H1[k1],C1=Gn(tt,ct.current,T,C);R?.(tt,C1,k1,C1+((c1=tt.growOffset)!=null?c1:0))}}},[l,s,p,M,n,e,H1,T,C,R,d1]),u1=It.useCallback(O=>{if(p===void 0||L===void 0)return w(O);let[Q,c1]=O;return c1===L?c1=p:(c1>L&&(c1-=1),c1>=p&&(c1+=1)),w([Q,c1])},[p,L,w]),o1=It.useCallback(O=>{g1?.(O),O.defaultPrevented()||b1()},[b1,g1]);return It.createElement(Tb,{accessibilityHeight:t.accessibilityHeight,canvasRef:t.canvasRef,cellXOffset:t.cellXOffset,cellYOffset:t.cellYOffset,columns:t.columns,disabledRows:t.disabledRows,drawCustomCell:t.drawCustomCell,drawFocusRing:t.drawFocusRing,drawHeader:t.drawHeader,enableGroups:t.enableGroups,eventTargetRef:t.eventTargetRef,experimental:t.experimental,fillHandle:t.fillHandle,firstColAccessible:t.firstColAccessible,fixedShadowX:t.fixedShadowX,fixedShadowY:t.fixedShadowY,freezeColumns:t.freezeColumns,getCellRenderer:t.getCellRenderer,getGroupDetails:t.getGroupDetails,getRowThemeOverride:t.getRowThemeOverride,groupHeaderHeight:t.groupHeaderHeight,headerHeight:t.headerHeight,headerIcons:t.headerIcons,height:t.height,highlightRegions:t.highlightRegions,imageWindowLoader:t.imageWindowLoader,isDraggable:t.isDraggable,isFilling:t.isFilling,isFocused:t.isFocused,onCanvasBlur:t.onCanvasBlur,onCanvasFocused:t.onCanvasFocused,onCellFocused:t.onCellFocused,onContextMenu:t.onContextMenu,onDragEnd:t.onDragEnd,onDragLeave:t.onDragLeave,onDragOverCell:t.onDragOverCell,onDrop:t.onDrop,onKeyDown:t.onKeyDown,onKeyUp:t.onKeyUp,onMouseMove:t.onMouseMove,prelightCells:t.prelightCells,rowHeight:t.rowHeight,rows:t.rows,selection:t.selection,smoothScrollX:t.smoothScrollX,smoothScrollY:t.smoothScrollY,theme:t.theme,trailingRowType:t.trailingRowType,translateX:t.translateX,translateY:t.translateY,verticalBorder:t.verticalBorder,width:t.width,getCellContent:u1,isResizing:n!==void 0,onHeaderMenuClick:P1,isDragging:v,onItemHovered:K1,onDragStart:o1,onMouseDown:j1,allowResize:l1,onMouseUp:Q1,dragAndDropState:j,onMouseMoveRaw:N,ref:E})},Ib=Pb;function Ob(t){let a=(0,pr.useRef)(null),[e,r]=(0,pr.useState)({width:t?.[0],height:t?.[1]});return(0,pr.useLayoutEffect)(()=>{let n=l=>{for(let o of l){let{width:h,height:c}=o&&o.contentRect||{};r(v=>v.width===h&&v.height===c?v:{width:h,height:c})}},i=new window.ResizeObserver(n);return a.current&&i.observe(a.current,void 0),()=>{i.disconnect()}},[a.current]),{ref:a,...e}}var Db=()=>t=>t.isSafari?"scroll":"auto",Nb=y0("div")({name:"ScrollRegionStyle",class:"s1jz82f8",vars:{"s1jz82f8-0":[Db()]}});function H8(t){t.stopPropagation()}function $b(t){let[a,e]=it.useState(!1),r=it.useRef(0);return Q0("touchstart",it.useCallback(()=>{window.clearTimeout(r.current),e(!0)},[]),window,!0,!1),Q0("touchend",it.useCallback(n=>{n.touches.length===0&&(r.current=window.setTimeout(()=>e(!1),t))},[t]),window,!0,!1),a}var Ub=t=>{var a,e,r,n;let{children:i,clientHeight:l,scrollHeight:o,scrollWidth:h,update:c,draggable:v,className:g,preventDiagonalScrolling:s=!1,paddingBottom:d=0,paddingRight:p=0,rightElement:z,rightElementProps:L,scrollRef:u,scrollToEnd:f,initialSize:m,minimap:M}=t,x=[],y=(a=L?.sticky)!=null?a:!1,w=(e=L?.fill)!=null?e:!1,V=it.useRef(0),R=it.useRef(0),S=it.useRef(null),b=window.devicePixelRatio;it.useEffect(()=>{let P1=S.current;P1===null||f!==!0||(P1.scrollLeft=P1.scrollWidth-P1.clientWidth)},[f]);let E=it.useRef({scrollLeft:0,scrollTop:0,lockDirection:void 0}),C=it.useRef(null),T=$b(200),[I,J]=it.useState(!0),W=it.useRef(0);it.useEffect(()=>{if(!I||T||E.current.lockDirection===void 0)return;let P1=S.current;if(P1===null)return;let[ct,b1]=E.current.lockDirection;ct!==void 0?P1.scrollLeft=ct:b1!==void 0&&(P1.scrollTop=b1),E.current.lockDirection=void 0},[T,I]);let n1=it.useCallback(()=>{var P1,ct,b1,Q1;let j=S.current;if(j===null)return;let N=j.scrollTop,u1=j.scrollLeft,o1=E.current.scrollTop,O=E.current.scrollLeft,Q=u1-O,c1=N-o1;T&&Q!==0&&c1!==0&&(Math.abs(Q)>3||Math.abs(c1)>3)&&s&&E.current.lockDirection===void 0&&(E.current.lockDirection=Math.abs(Q)0&&(Math.abs(W1)>2e3||s1===0||s1===k1)&&o>j.scrollHeight+5){let tt=s1/k1,C1=(o-j.clientHeight)*tt;V.current=C1-s1}$!==void 0&&(window.clearTimeout(W.current),J(!1),W.current=window.setTimeout(()=>J(!0),200)),c({x:u1,y:s1+V.current,width:j.clientWidth-p,height:j.clientHeight-d,paddingRight:(Q1=(b1=C.current)==null?void 0:b1.clientWidth)!=null?Q1:0})},[d,p,o,c,s,T]),i1=it.useRef(n1);i1.current=n1;let g1=it.useRef(),l1=it.useRef(!1);it.useEffect(()=>{l1.current?n1():l1.current=!0},[n1,d,p]);let H1=it.useCallback(P1=>{S.current=P1,u!==void 0&&(u.current=P1)},[u]),f1=0,d1=0;for(x.push(it.createElement("div",{key:f1++,style:{width:h,height:0}}));d1i1.current(),0),g1.current={width:X1,height:j1}),(X1??0)===0||(j1??0)===0?it.createElement("div",{ref:K1}):it.createElement("div",{ref:K1},it.createElement(Nb,{isSafari:xz.value},M,it.createElement("div",{className:"dvn-underlay"},i),it.createElement("div",{ref:H1,style:g1.current,draggable:v,onDragStart:P1=>{v||(P1.stopPropagation(),P1.preventDefault())},className:"dvn-scroller "+(g??""),onScroll:n1},it.createElement("div",{className:"dvn-scroll-inner"+(z===void 0?" hidden":"")},it.createElement("div",{className:"dvn-stack"},x),z!==void 0&&it.createElement(it.Fragment,null,!w&&it.createElement("div",{className:"dvn-spacer"}),it.createElement("div",{ref:C,onMouseDown:H8,onMouseUp:H8,onMouseMove:H8,style:{height:j1,maxHeight:l-Math.ceil(b%1),position:"sticky",top:0,paddingLeft:1,marginBottom:-40,marginRight:p,flexGrow:w?1:void 0,right:y?p??0:void 0,pointerEvents:"auto"}},z))))))},Wb=y0("div")({name:"MinimapStyle",class:"m15w2ly5"}),jb=t=>{var a,e,r;let{columns:n,rows:i,rowHeight:l,headerHeight:o,groupHeaderHeight:h,enableGroups:c,freezeColumns:v,experimental:g,clientSize:s,className:d,onVisibleRegionChanged:p,scrollToEnd:z,scrollRef:L,preventDiagonalScrolling:u,rightElement:f,rightElementProps:m,overscrollX:M,overscrollY:x,showMinimap:y=!1,initialSize:w,smoothScrollX:V=!1,smoothScrollY:R=!1,isDraggable:S}=t,{paddingRight:b,paddingBottom:E}=g??{},[C,T]=s,I=g0.useRef(),J=g0.useRef(),W=g0.useRef(),n1=g0.useRef(),i1=g0.useMemo(()=>{let O=Math.max(0,M??0);for(let Q of n)O+=Q.width;return O},[n,M]),g1=c?o+h:o;if(typeof l=="number")g1+=i*l;else for(let O=0;O{var O,Q,c1;if(l1.current===void 0)return;let $={...l1.current},s1=0,W1=$.x<0?-$.x:0,k1=0,tt=0;$.x=$.x<0?0:$.x;let C1=0;for(let F1=0;F1=vt+F1.width)s1+=F1.width,tt++,k1++;else if($.x>vt)s1+=F1.width,V?W1+=vt-$.x:tt++,k1++;else if($.x+$.width>vt)s1+=F1.width,k1++;else break}let Ut=0,q=0,h1=0;if(typeof l=="number")R?(q=Math.floor($.y/l),Ut=q*l-$.y):q=Math.ceil($.y/l),h1=Math.ceil($.height/l)+q,Ut<0&&h1++;else{let F1=0;for(let vt=0;vt=F1+jt)F1+=jt,q++,h1++;else if($.y>xt)F1+=jt,R?Ut+=xt-$.y:q++,h1++;else if($.y+$.height>jt/2+F1)F1+=jt,h1++;else break}}let x1={x:tt,y:q,width:k1-tt,height:h1-q},z1=I.current;(z1===void 0||z1.y!==x1.y||z1.x!==x1.x||z1.height!==x1.height||z1.width!==x1.width||J.current!==W1||W.current!==Ut||$.width!==((O=n1.current)==null?void 0:O[0])||$.height!==((Q=n1.current)==null?void 0:Q[1]))&&(p?.({x:tt,y:q,width:k1-tt,height:h1-q},$.width,$.height,(c1=$.paddingRight)!=null?c1:0,W1,Ut),I.current=x1,J.current=W1,W.current=Ut,n1.current=[$.width,$.height])},[n,l,i,p,v,V,R]),f1=g0.useCallback(O=>{l1.current=O,H1()},[H1]);g0.useEffect(()=>{H1()},[H1]);let d1=(a=L?.current)!=null?a:void 0,K1=(0,wz.default)(i1/g1,2/3,1.5),X1=200,j1=K1>1?X1:Math.ceil(X1*K1),P1=K1>1?Math.ceil(X1/K1):X1,ct=j1/i1,b1=P1/g1,Q1=Math.min(C*Math.max(ct,.01),j1),j=Math.min(T*Math.max(b1,.01),P1),N=((e=d1?.scrollLeft)!=null?e:0)/(i1-C)*(j1-Q1),u1=((r=d1?.scrollTop)!=null?r:0)/(g1-T)*(P1-j),o1=g0.useMemo(()=>{if(!y||Q1===0||j===0)return;let O=Q=>{if(d1===void 0)return;let c1=Q.currentTarget.getBoundingClientRect(),$=Q.clientX-c1.x-Q1/2,s1=Q.clientY-c1.y-j/2,W1=(i1-d1.clientWidth)*($/(j1-Q1)),k1=(g1-d1.clientHeight)*(s1/(P1-j));d1.scrollTo({left:W1,top:k1,behavior:Q.type==="mousemove"?"auto":"smooth"})};return g0.createElement(Wb,{style:{width:j1,height:P1},"data-testid":"minimap-container",onMouseMove:Q=>{Q.buttons===1&&O(Q)},onClick:O},g0.createElement("div",{className:"header"}),g0.createElement("div",{className:"locationMarker",onDragStart:Q=>Q.preventDefault(),style:{left:N,top:u1,width:Q1,height:j,borderRadius:Math.min(Q1,j*.2,9)}}))},[P1,g1,N,d1,y,u1,j,Q1,j1,i1]);return g0.createElement(Ub,{scrollRef:L,minimap:o1,className:d,preventDiagonalScrolling:u,draggable:S===!0||typeof S=="string",scrollWidth:i1+(b??0),scrollHeight:g1+(E??0),clientHeight:T,rightElement:f,paddingBottom:E,paddingRight:b,rightElementProps:m,update:f1,initialSize:w,scrollToEnd:z},g0.createElement(Ib,{eventTargetRef:L,width:C,height:T,accessibilityHeight:t.accessibilityHeight,canvasRef:t.canvasRef,cellXOffset:t.cellXOffset,cellYOffset:t.cellYOffset,columns:t.columns,disabledRows:t.disabledRows,enableGroups:t.enableGroups,fillHandle:t.fillHandle,firstColAccessible:t.firstColAccessible,fixedShadowX:t.fixedShadowX,fixedShadowY:t.fixedShadowY,freezeColumns:t.freezeColumns,getCellContent:t.getCellContent,getCellRenderer:t.getCellRenderer,getGroupDetails:t.getGroupDetails,getRowThemeOverride:t.getRowThemeOverride,groupHeaderHeight:t.groupHeaderHeight,headerHeight:t.headerHeight,highlightRegions:t.highlightRegions,imageWindowLoader:t.imageWindowLoader,isFilling:t.isFilling,isFocused:t.isFocused,lockColumns:t.lockColumns,maxColumnWidth:t.maxColumnWidth,minColumnWidth:t.minColumnWidth,onHeaderMenuClick:t.onHeaderMenuClick,onMouseMove:t.onMouseMove,prelightCells:t.prelightCells,rowHeight:t.rowHeight,rows:t.rows,selection:t.selection,theme:t.theme,trailingRowType:t.trailingRowType,translateX:t.translateX,translateY:t.translateY,verticalBorder:t.verticalBorder,drawCustomCell:t.drawCustomCell,drawFocusRing:t.drawFocusRing,drawHeader:t.drawHeader,experimental:t.experimental,gridRef:t.gridRef,headerIcons:t.headerIcons,isDraggable:t.isDraggable,onCanvasBlur:t.onCanvasBlur,onCanvasFocused:t.onCanvasFocused,onCellFocused:t.onCellFocused,onColumnMoved:t.onColumnMoved,onColumnResize:t.onColumnResize,onColumnResizeEnd:t.onColumnResizeEnd,onColumnResizeStart:t.onColumnResizeStart,onContextMenu:t.onContextMenu,onDragEnd:t.onDragEnd,onDragLeave:t.onDragLeave,onDragOverCell:t.onDragOverCell,onDragStart:t.onDragStart,onDrop:t.onDrop,onItemHovered:t.onItemHovered,onKeyDown:t.onKeyDown,onKeyUp:t.onKeyUp,onMouseDown:t.onMouseDown,onMouseUp:t.onMouseUp,onRowMoved:t.onRowMoved,smoothScrollX:t.smoothScrollX,smoothScrollY:t.smoothScrollY}))},qb=jb,Gb=()=>t=>t.showSearch?0:400,Kb=y0("div")({name:"SearchWrapper",class:"sxep88s",vars:{"sxep88s-0":[Gb(),"px"]}}),Xb=U1.createElement("svg",{className:"button-icon",viewBox:"0 0 512 512"},U1.createElement("path",{fill:"none",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"48",d:"M112 244l144-144 144 144M256 120v292"})),Yb=U1.createElement("svg",{className:"button-icon",viewBox:"0 0 512 512"},U1.createElement("path",{fill:"none",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"48",d:"M112 268l144 144 144-144M256 392V100"})),Qb=U1.createElement("svg",{className:"button-icon",viewBox:"0 0 512 512"},U1.createElement("path",{fill:"none",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"32",d:"M368 368L144 144M368 144L144 368"})),Zb=10,Jb=t=>{let{canvasRef:a,cellYOffset:e,rows:r,columns:n,searchInputRef:i,getCellsForSelection:l,onSearchResultsChanged:o,showSearch:h=!1,onSearchClose:c}=t,[v]=U1.useState(()=>"search-box-"+Math.round(Math.random()*1e3)),[g,s]=U1.useState(""),[d,p]=U1.useState(),z=U1.useRef(d);z.current=d;let L=U1.useRef(new AbortController),u=U1.useRef(),[f,m]=U1.useState([]),M=U1.useCallback(()=>{u.current!==void 0&&(window.cancelAnimationFrame(u.current),u.current=void 0,L.current.abort())},[]),x=U1.useRef(e);x.current=e;let y=U1.useCallback(C=>{let T=new RegExp(C.replace(/([$()*+.?[\\\]^{|}-])/g,"\\$1"),"i"),I=x.current,J=Math.min(10,r),W=0;p(void 0),m([]);let n1=[],i1=async()=>{var g1,l1;if(l===void 0)return;let H1=performance.now(),f1=r-W,d1=l({x:0,y:I,width:n.length,height:Math.min(J,f1,r-I)},L.current.signal);typeof d1=="function"&&(d1=await d1());let K1=!1;for(let[Q1,j]of d1.entries())for(let[N,u1]of j.entries()){let o1;switch(u1.kind){case t1.Text:case t1.Number:o1=u1.displayData;break;case t1.Uri:case t1.Markdown:o1=u1.data;break;case t1.Boolean:o1=typeof u1.data=="boolean"?u1.data.toString():void 0;break;case t1.Image:case t1.Bubble:o1=u1.data.join("\u{1F433}");break;case t1.Custom:o1=u1.copyData;break}o1!==void 0&&T.test(o1)&&(n1.push([N,Q1+I]),K1=!0)}let X1=performance.now();K1&&m([...n1]),W+=d1.length,i2(W<=r);let j1=(l1=(g1=z.current)==null?void 0:g1.selectedIndex)!=null?l1:-1;p({results:n1.length,rowsSearched:W,selectedIndex:j1}),o?.(n1,j1),I+J>=r?I=0:I+=J;let P1=X1-H1,ct=Math.max(P1,1),b1=Zb/ct;J=Math.ceil(J*b1),W{var C;c?.(),p(void 0),m([]),o?.([],-1),M(),(C=a?.current)==null||C.focus()},[M,a,c,o]),V=U1.useCallback(C=>{s(C.target.value),C.target.value===""?(p(void 0),m([]),M()):y(C.target.value)},[y,M]);U1.useEffect(()=>{h&&i.current!==null&&(s(""),i.current.focus({preventScroll:!0}))},[h,i]);let R=U1.useCallback(C=>{var T;if((T=C?.stopPropagation)==null||T.call(C),d===void 0)return;let I=(d.selectedIndex+1)%d.results;p({...d,selectedIndex:I}),o?.(f,I)},[d,o,f]),S=U1.useCallback(C=>{var T;if((T=C?.stopPropagation)==null||T.call(C),d===void 0)return;let I=(d.selectedIndex-1)%d.results;I<0&&(I+=d.results),p({...d,selectedIndex:I}),o?.(f,I)},[o,f,d]),b=U1.useCallback(C=>{(C.ctrlKey||C.metaKey)&&C.nativeEvent.code==="KeyF"||C.key==="Escape"?(w(),C.stopPropagation(),C.preventDefault()):C.key==="Enter"&&(C.shiftKey?S():R())},[w,R,S]);U1.useEffect(()=>()=>{M()},[M]);let E=U1.useMemo(()=>{var C,T,I;let J;d!==void 0&&(J=d.results>=1e3?"over 1000":`${d.results} result${d.results!==1?"s":""}`,d.selectedIndex>=0&&(J=`${d.selectedIndex+1} of ${J}`));let W=g1=>{g1.stopPropagation()},i1={width:`${Math.floor(((C=d?.rowsSearched)!=null?C:0)/r*100)}%`};return U1.createElement(Kb,{showSearch:h,onMouseDown:W,onMouseMove:W,onMouseUp:W,onClick:W},U1.createElement("div",{className:"search-bar-inner"},U1.createElement("input",{id:v,"aria-hidden":!h,"data-testid":"search-input",ref:i,onChange:V,value:g,tabIndex:h?void 0:-1,onKeyDownCapture:b}),U1.createElement("button",{"aria-label":"Previous Result","aria-hidden":!h,tabIndex:h?void 0:-1,onClick:S,disabled:((T=d?.results)!=null?T:0)===0},Xb),U1.createElement("button",{"aria-label":"Next Result","aria-hidden":!h,tabIndex:h?void 0:-1,onClick:R,disabled:((I=d?.results)!=null?I:0)===0},Yb),c!==void 0&&U1.createElement("button",{"aria-label":"Close Search","aria-hidden":!h,"data-testid":"search-close-button",tabIndex:h?void 0:-1,onClick:w},Qb)),d!==void 0?U1.createElement(U1.Fragment,null,U1.createElement("div",{className:"search-status"},U1.createElement("div",{"data-testid":"search-result-area"},J)),U1.createElement("div",{className:"search-progress",style:i1})):U1.createElement("div",{className:"search-status"},U1.createElement("label",{htmlFor:v},"Type to search")))},[w,R,S,V,c,b,r,d,g,h,v,i]);return U1.createElement(U1.Fragment,null,U1.createElement(qb,{prelightCells:f,accessibilityHeight:t.accessibilityHeight,canvasRef:t.canvasRef,cellXOffset:t.cellXOffset,cellYOffset:t.cellYOffset,className:t.className,clientSize:t.clientSize,columns:t.columns,disabledRows:t.disabledRows,enableGroups:t.enableGroups,fillHandle:t.fillHandle,firstColAccessible:t.firstColAccessible,fixedShadowX:t.fixedShadowX,fixedShadowY:t.fixedShadowY,freezeColumns:t.freezeColumns,getCellContent:t.getCellContent,getCellRenderer:t.getCellRenderer,getGroupDetails:t.getGroupDetails,getRowThemeOverride:t.getRowThemeOverride,groupHeaderHeight:t.groupHeaderHeight,headerHeight:t.headerHeight,highlightRegions:t.highlightRegions,imageWindowLoader:t.imageWindowLoader,initialSize:t.initialSize,isFilling:t.isFilling,isFocused:t.isFocused,lockColumns:t.lockColumns,maxColumnWidth:t.maxColumnWidth,minColumnWidth:t.minColumnWidth,onHeaderMenuClick:t.onHeaderMenuClick,onMouseMove:t.onMouseMove,onVisibleRegionChanged:t.onVisibleRegionChanged,overscrollX:t.overscrollX,overscrollY:t.overscrollY,preventDiagonalScrolling:t.preventDiagonalScrolling,rightElement:t.rightElement,rightElementProps:t.rightElementProps,rowHeight:t.rowHeight,rows:t.rows,scrollRef:t.scrollRef,selection:t.selection,showMinimap:t.showMinimap,theme:t.theme,trailingRowType:t.trailingRowType,translateX:t.translateX,translateY:t.translateY,verticalBorder:t.verticalBorder,drawCustomCell:t.drawCustomCell,drawFocusRing:t.drawFocusRing,drawHeader:t.drawHeader,experimental:t.experimental,gridRef:t.gridRef,headerIcons:t.headerIcons,isDraggable:t.isDraggable,onCanvasBlur:t.onCanvasBlur,onCanvasFocused:t.onCanvasFocused,onCellFocused:t.onCellFocused,onColumnMoved:t.onColumnMoved,onColumnResize:t.onColumnResize,onColumnResizeEnd:t.onColumnResizeEnd,onColumnResizeStart:t.onColumnResizeStart,onContextMenu:t.onContextMenu,onDragEnd:t.onDragEnd,onDragLeave:t.onDragLeave,onDragOverCell:t.onDragOverCell,onDragStart:t.onDragStart,onDrop:t.onDrop,onItemHovered:t.onItemHovered,onKeyDown:t.onKeyDown,onKeyUp:t.onKeyUp,onMouseDown:t.onMouseDown,onMouseUp:t.onMouseUp,onRowMoved:t.onRowMoved,smoothScrollX:t.smoothScrollX,smoothScrollY:t.smoothScrollY,scrollToEnd:t.scrollToEnd}),E)},tE=Jb,aE=()=>t=>Math.max(16,t.targetHeight-10),eE=y0("input")({name:"RenameInput",class:"r1kzy40b",vars:{"r1kzy40b-0":[aE(),"px"]}}),rE=t=>{let{bounds:a,group:e,onClose:r,canvasBounds:n,onFinish:i}=t,[l,o]=S5.default.useState(e);return S5.default.createElement(qp,{style:{position:"absolute",left:a.x-n.left+1,top:a.y-n.top,width:a.width-2,height:a.height},className:"c1sqdbw3",onClickOutside:r},S5.default.createElement(eE,{targetHeight:a.height,"data-testid":"group-rename-input",value:l,onBlur:r,onFocus:h=>h.target.setSelectionRange(0,l.length),onChange:h=>o(h.target.value),onKeyDown:h=>{h.key==="Enter"?i(l):h.key==="Escape"&&r()},autoFocus:!0}))},E5=150;function nE(t,a,e,r){var n,i;if(a.kind===t1.Custom)return E5;let l=r(a);return(i=(n=l?.measure)==null?void 0:n.call(l,t,a,e))!=null?i:E5}function Lz(t,a,e,r,n,i,l,o,h){let c=[];if(n!==void 0&&c.push(...n.map(s=>s[r]).map(s=>nE(t,s,a,h))),c.length>5&&o){let s=c.reduce((d,p)=>d+p)/c.length;c=c.filter(d=>d{if(typeof window===void 0)return null;let u=document.createElement("canvas");return u.style.display="none",u.style.opacity="0",u.style.position="fixed",document.documentElement.append(u),u.getContext("2d",{alpha:!1})}),d=m2.useRef({}),p=m2.useRef(),[z,L]=m2.useState();return m2.useLayoutEffect(()=>{let u=v.current;if(u===void 0||t.every(w5))return;let f=Math.max(1,10-Math.floor(t.length/1e4)),m=0;f1&&(f--,m=1);let M={x:0,y:0,width:t.length,height:Math.min(c.current,f)},x={x:0,y:c.current-1,width:t.length,height:1};(async()=>{let w=u(M,h.signal),V=m>0?u(x,h.signal):void 0,R;typeof w=="object"?R=w:R=await Vp(w),V!==void 0&&(typeof V=="object"?R=[...R,...V]:R=[...R,...await Vp(V)]),p.current=t,L(R)})()},[h.signal,t]),m2.useMemo(()=>{var u;let m=(()=>t.every(w5)?t:s===null?t.map(w=>w5(w)?w:{...w,width:E5}):(s.font=`${g.current.baseFontStyle} ${g.current.fontFamily}`,t.map((w,V)=>{if(w5(w))return w;if(d.current[w.id]!==void 0)return{...w,width:d.current[w.id]};if(z===void 0||p.current!==t||w.id===void 0)return{...w,width:E5};let R=Lz(s,l,w,V,z,n,i,!0,o);return d.current[w.id]=R.width,R})))(),M=0,x=0,y=[];for(let[w,V]of m.entries())M+=V.width,V.grow!==void 0&&V.grow>0&&(x+=V.grow,y.push(w));if(M0){let w=[...m],V=r-M,R=V;for(let S=0;S1&&t.startsWith("_")){if(Number.parseInt(t.slice(1))!==a.keyCode)return!1}else if(t!==a.key)return!1;return!0}function _0(t,a){if(t.length===0)return!1;let e=!1,r=!1,n=!1,i=!1,l=t.split("+"),o=l.pop();if(!lE(o,a))return!1;for(let h of l)switch(h){case"ctrl":e=!0;break;case"shift":r=!0;break;case"alt":n=!0;break;case"meta":i=!0;break;case"primary":B5.value?i=!0:e=!0;break}return a.altKey===n&&a.ctrlKey===e&&a.shiftKey===r&&a.metaKey===i}function oE(t,a,e,r,n,i){let l=A5.default.useCallback((c,v,g,s)=>{var d,p;(i==="cell"||i==="multi-cell")&&c!==void 0&&(c={...c,range:{x:c.cell[0],y:c.cell[1],width:1,height:1}});let z=e==="mixed"&&(g||s==="drag"),L=r==="mixed"&&z,u=n==="mixed"&&z,f={current:c===void 0?void 0:{...c,rangeStack:s==="drag"?(p=(d=t.current)==null?void 0:d.rangeStack)!=null?p:[]:[]},columns:L?t.columns:pt.empty(),rows:u?t.rows:pt.empty()};g&&(i==="multi-rect"||i==="multi-cell")&&f.current!==void 0&&t.current!==void 0&&(f={...f,current:{...f.current,rangeStack:[...t.current.rangeStack,t.current.range]}}),a(f,v)},[r,t,e,i,n,a]),o=A5.default.useCallback((c,v,g)=>{c=c??t.rows,v!==void 0&&(c=c.add(v));let s;if(n==="exclusive"&&c.length>0)s={current:void 0,columns:pt.empty(),rows:c};else{let d=g&&e==="mixed",p=g&&r==="mixed";s={current:d?t.current:void 0,columns:p?t.columns:pt.empty(),rows:c}}a(s,!1)},[r,t,e,n,a]),h=A5.default.useCallback((c,v,g)=>{c=c??t.columns,v!==void 0&&(c=c.add(v));let s;if(r==="exclusive"&&c.length>0)s={current:void 0,rows:pt.empty(),columns:c};else{let d=g&&e==="mixed",p=g&&n==="mixed";s={current:d?t.current:void 0,rows:p?t.rows:pt.empty(),columns:c}}a(s,!1)},[r,t,e,n,a]);return[l,o,h]}function hE(t,a,e,r){let n=B8.useCallback(h=>{var c;if(t===!0){let v=[];for(let g=h.y;g{if(i===void 0)return[];let c={...h,x:h.x-e};if(c.x<0){c.x=0,c.width--;let v=i(c,r.signal);return typeof v=="function"?async()=>(await v()).map(g=>[{kind:t1.Loading,allowOverlay:!1},...g]):v.map(g=>[{kind:t1.Loading,allowOverlay:!1},...g])}return i(c,r.signal)},[r.signal,i,e]);return[t!==void 0?l:void 0,i]}function cE(t,a,e,r,n){var i,l;let o=t;if(r==="allowPartial"||t.current===void 0)return t;if(a!==void 0){let h=!1;do{if(t?.current===void 0)break;let c=(i=t.current)==null?void 0:i.range,v=[];if(c.width>2){let d=a({x:c.x,y:c.y,width:1,height:c.height},n.signal);if(typeof d=="function")return o;v.push(...d);let p=a({x:c.x+c.width-1,y:c.y,width:1,height:c.height},n.signal);if(typeof p=="function")return o;v.push(...p)}else{let d=a({x:c.x,y:c.y,width:c.width,height:c.height},n.signal);if(typeof d=="function")return o;v.push(...d)}let g=c.x-e,s=c.x+c.width-1-e;for(let d of v)for(let p of d)p.span!==void 0&&(g=Math.min(p.span[0],g),s=Math.max(p.span[1],s));g===c.x-e&&s===c.x+c.width-1-e?h=!0:t={current:{cell:(l=t.current.cell)!=null?l:[0,0],range:{x:g+e,y:c.y,width:s-g+1,height:c.height},rangeStack:t.current.rangeStack},columns:t.columns,rows:t.rows}}while(!h)}return t}function _p(t){return t.startsWith('"')&&t.endsWith('"')&&(t=t.slice(1,-1).replace(/""/g,'"')),t}function vE(t){var a;(function(o){o[o.None=0]="None",o[o.inString=1]="inString",o[o.inStringPostQuote=2]="inStringPostQuote"})(a||(a={}));let e=[],r=[],n=0,i=0;t=t.replace(/\r\n/g,` +`},Sb={headerRowID:ab,headerNumber:rb,headerCode:eb,headerString:nb,headerBoolean:ib,headerAudioUri:ob,headerVideoUri:hb,headerEmoji:cb,headerImage:vb,headerUri:yz,headerPhone:gb,headerMarkdown:db,headerDate:sb,headerTime:ub,headerEmail:fb,headerReference:pb,headerIfThenElse:zb,headerSingleValue:mb,headerLookup:Mb,headerTextTemplate:Hb,headerMath:xb,headerRollup:wb,headerJoinStrings:Lb,headerSplitString:Vb,headerGeoDistance:Rb,headerArray:yb,rowOwnerOverlay:Cb,protectedColumnOverlay:Bb,renameIcon:lb};function Ab(t,a){return t==="normal"?[a.bgIconHeader,a.fgIconHeader]:t==="selected"?["white",a.accentColor]:[a.accentColor,a.bgHeader]}var Fb=class{constructor(t,a){this.onSettled=a,this.spriteMap=new Map,this.inFlight=0,this.headerIcons={...Sb,...t}}drawSprite(t,a,e,r,n,i,l,o=1){let[h,c]=Ab(a,l),v=i*Math.ceil(window.devicePixelRatio),g=`${h}_${c}_${v}_${t}`,d=this.spriteMap.get(g);if(d===void 0){let u=this.headerIcons[t];if(u===void 0)return;d=document.createElement("canvas");let p=d.getContext("2d");if(p===null)return;let z=new Image;z.src=`data:image/svg+xml;charset=utf-8,${encodeURIComponent(u({fgColor:c,bgColor:h}))}`,this.spriteMap.set(g,d);let w=z.decode();if(w===void 0)return;this.inFlight++,w.then(()=>{p.drawImage(z,0,0,v,v)}).finally(()=>{this.inFlight--,this.inFlight===0&&this.onSettled()})}else o<1&&(e.globalAlpha=o),e.drawImage(d,0,0,v,v,r,n,i,i),o<1&&(e.globalAlpha=1)}},R8={},Me=null;function kb(){let t=document.createElement("div");return t.style.opacity="0",t.style.pointerEvents="none",t.style.position="fixed",document.body.append(t),t}function k8(t){let a=t.toLowerCase().trim();if(R8[a]!==void 0)return R8[a];Me=Me||kb(),Me.style.color="#000",Me.style.color=a;let e=getComputedStyle(Me).color;Me.style.color="#fff",Me.style.color=a;let r=getComputedStyle(Me).color;if(r!==e)return[0,0,0,1];let n=r.replace(/[^\d.,]/g,"").split(",").map(Number.parseFloat);return n.length<4&&n.push(1),n=n.map(i=>{let l=Number.isNaN(i);return l&&console.warn("Could not parse color",t),l?0:i}),R8[a]=n,n}function fr(t,a){let[e,r,n]=k8(t);return`rgba(${e}, ${r}, ${n}, ${a})`}function Le(t,a){if(a===void 0)return t;let[e,r,n,i]=k8(t);if(i===1)return t;let[l,o,h,c]=k8(a),v=i+c*(1-i),g=(i*e+c*l*(1-i))/v,d=(i*r+c*o*(1-i))/v,u=(i*n+c*h*(1-i))/v;return`rgba(${g}, ${d}, ${u}, ${v})`}var bb={kind:l1.Loading,allowOverlay:!1};function Sz(t,a,e,r,n,i,l,o,h,c,v,g,d,u,p,z,w,s,f,m){let H,x;p!==void 0&&p[0][0]===r&&p[0][1]===a&&(H=p[1][0],x=p[1][1]);let y,R={ctx:t,theme:c,col:r,row:a,cell:e,rect:{x:n,y:i,width:l,height:o},highlighted:h,hoverAmount:u,hoverX:H,hoverY:x,imageLoader:g,spriteManager:d,hyperWrapping:z,requestAnimationFrame:()=>{L=!0}},L=!1;return(Uk(R,e.lastUpdated,w,s,()=>{var C,k;if(!(we(e)?!1:v?.(R)===!0)){let F=m(e);if(F!==void 0){s?.renderer!==F&&((C=s?.deprep)==null||C.call(s,R),s=void 0);let _=(k=F.drawPrep)==null?void 0:k.call(F,R,s);F.draw(R,e),y={deprep:_?.deprep,fillStyle:_?.fillStyle,font:_?.font,renderer:F}}}})||L)&&f?.([r,a]),y}function Eb(t,a,e,r,n,i,l,o,h,c,v,g,d,u,p,z,w){let s=[],f=!1;t.imageSmoothingEnabled=!1;let m=Math.min(e.cellYOffset,n),H=Math.max(e.cellYOffset,n),x=0;if(typeof z=="number")x+=(H-m)*z;else for(let F=m;Fe.cellYOffset&&(x=-x),x+=l-e.translateY;let y=Math.min(e.cellXOffset,r),R=Math.max(e.cellXOffset,r),L=0;for(let F=y;Fe.cellXOffset&&(L=-L),L+=i-e.translateX;let V=ur(p);if(V>0&&V++,L!==0&&x!==0)return{regions:[],yOnly:!1};let C=o?typeof z=="number"?z:z(v-1):0,k=h-V-Math.abs(L),b=c-g-C-Math.abs(x)-1;if(k>150&&b>150){f=L===0;let F={sx:0,sy:0,sw:h*d,sh:c*d,dx:0,dy:0,dw:h*d,dh:c*d};x>0?(F.sy=(g+1)*d,F.sh=b*d,F.dy=(x+g+1)*d,F.dh=b*d,s.push({x:0,y:g,width:h,height:x+1})):x<0&&(F.sy=(-x+g+1)*d,F.sh=b*d,F.dy=(g+1)*d,F.dh=b*d,s.push({x:0,y:c+x-C,width:h,height:-x+C})),L>0?(F.sx=V*d,F.sw=k*d,F.dx=(L+V)*d,F.dw=k*d,s.push({x:V-1,y:0,width:L+2,height:c})):L<0&&(F.sx=(V-L)*d,F.sw=k*d,F.dx=V*d,F.dw=k*d,s.push({x:h+L,y:0,width:-L,height:c})),t.setTransform(1,0,0,1,0,0),V>0&&L!==0&&x===0&&w&&t.drawImage(a,0,0,V*d,c*d,0,0,V*d,c*d),t.drawImage(a,F.sx,F.sy,F.sw,F.sh,F.dx,F.dy,F.dw,F.dh),t.scale(d,d)}return t.imageSmoothingEnabled=!0,{regions:s,yOnly:f}}function _b(t,a,e,r,n,i,l,o,h,c){let v=[];return a!==t.cellXOffset||e!==t.cellYOffset||r!==t.translateX||n!==t.translateY||h4(h,e,r,n,o,(g,d,u,p)=>{if(g.sourceIndex===c){let z=Math.max(d,p)+1;return v.push({x:z,y:0,width:i-z,height:l}),!0}}),v}function Dp(t,a,e,r,n,i,l,o,h,c,v,g,d,u,p,z,w,s=!1){var f,m,H;if(h!==void 0){t.beginPath(),t.save(),t.rect(0,0,i,l);for(let Z of h)t.rect(Z.x+1,Z.y+1,Z.width-1,Z.height-1);t.clip("evenodd")}let x=(f=w.horizontalBorderColor)!=null?f:w.borderColor,y=w.borderColor,R=0,L=i,V=0,C=l;if(o!==void 0&&o.length>0){R=Number.MAX_SAFE_INTEGER,V=Number.MAX_SAFE_INTEGER,L=Number.MIN_SAFE_INTEGER,C=Number.MIN_SAFE_INTEGER;for(let Z of o)R=Math.min(R,Z.x-1),L=Math.max(L,Z.x+Z.width+1),V=Math.min(V,Z.y-1),C=Math.max(C,Z.y+Z.height+1)}let k=[];t.beginPath();let b=.5;for(let Z=0;Z=R&&O<=L&&u(Z+1)&&k.push({x1:O,y1:Math.max(c,V),x2:O,y2:Math.min(l,C),color:y})}let F=g(z-1),_=l-F+.5,j=p==="sticky";if(j&&k.push({x1:R,y1:_,x2:L,y2:_,color:x}),s!==!0){let Z=v+.5,d1=e,O=j?l-F:l;for(;Z+n<=O;){let a1=Z+n;if(a1>=V&&a1<=C-1&&(!j||d1!==z-1||Math.abs(a1-_)>1)){let W=d?.(d1);k.push({x1:R,y1:a1,x2:L,y2:a1,color:(H=(m=W?.horizontalBorderColor)!=null?m:W?.borderColor)!=null?H:x})}Z+=g(d1),d1++}}let n1=(0,Bz.default)(k,Z=>Z.color);for(let Z of Object.keys(n1)){t.strokeStyle=Z;for(let d1 of n1[Z])t.moveTo(d1.x1,d1.y1),t.lineTo(d1.x2,d1.y2);t.stroke(),t.beginPath()}h!==void 0&&t.restore()}function Az(t,a){let e=[],r=t.x+t.width-26*a.length,n=t.y+t.height/2-13,i=26,l=26;for(let o=0;o=t.x&&a<=t.x+t.width&&e>=t.y&&e<=t.y+t.height}function Tb(t,a,e,r,n,i,l,o,h,c,v,g){var d;let[p,z]=(d=i?.[0])!=null?d:[],w=0;_z(a,e,r,n,(s,f,m,H,x,y)=>{var R,L;if(g!==void 0&&!g.some(F=>F[1]===-2&&F[0]>=s[0]&&F[0]<=s[1]))return;t.save(),t.beginPath(),t.rect(m,H,x,y),t.clip();let V=v(f),C=V?.overrideTheme===void 0?l:{...l,...V.overrideTheme},k=z===-2&&p!==void 0&&p>=s[0]&&p<=s[1],b=k?C.bgHeaderHovered:C.bgHeader;if(b!==l.bgHeader&&(t.fillStyle=b,t.fill()),t.fillStyle=(R=C.textGroupHeader)!=null?R:C.textHeader,V!==void 0){let F=m;if(V.icon!==void 0&&(o.drawSprite(V.icon,"normal",t,F+8,(n-20)/2,20,C),F+=26),t.fillText(V.name,F+8,n/2+Na(t,`${l.headerFontStyle} ${l.fontFamily}`)),V.actions!==void 0&&k){let _=Az({x:m,y:H,width:x,height:y},V.actions);t.beginPath();let j=_[0].x-10,n1=m+x-j;t.rect(j,0,n1,n);let Z=t.createLinearGradient(j,0,j+n1,0),d1=fr(b,0);Z.addColorStop(0,d1),Z.addColorStop(10/n1,b),Z.addColorStop(1,b),t.fillStyle=Z,t.fill(),t.globalAlpha=.6;let[O,a1]=(L=i?.[1])!=null?L:[-1,-1];for(let W=0;W35){let R=z?35:r-35,L=z?35*.7:r-35*.7,V=R/r,C=L/r,k=t.createLinearGradient(a,0,a+r,0),b=fr(f,0);k.addColorStop(z?1:0,f),k.addColorStop(V,f),k.addColorStop(C,b),k.addColorStop(z?0:1,b),t.fillStyle=k}else t.fillStyle=f;if(z&&(t.textAlign="right"),t.fillText(i.title,x,e+n/2+Na(t,`${o.headerFontStyle} ${o.fontFamily}`)),z&&(t.textAlign="left"),m&&i.hasMenu===!0){t.beginPath();let y=w.x+w.width/2-5.5,R=w.y+w.height/2-3;tb(t,[{x:y,y:R},{x:y+11,y:R},{x:y+5.5,y:R+6}],1),t.fillStyle=f,t.fill()}}function Pb(t,a,e,r,n,i,l,o,h,c,v,g,d,u,p,z,w,s,f){var m;let H=l+o;if(H<=0)return;t.fillStyle=g.bgHeader,t.fillRect(0,0,n,H);let[x,y]=(m=r?.[0])!=null?m:[],R=`${g.headerFontStyle} ${g.fontFamily}`;t.font=R,h4(a,0,i,0,H,(L,V,C,k)=>{var b,F,_;if(w!==void 0&&!w.some(K1=>K1[1]===-1&&K1[0]===L.sourceIndex))return;let j=Math.max(0,k-V);t.save(),t.beginPath(),t.rect(V+j,o,L.width-j,l),t.clip();let n1=z((b=L.group)!=null?b:"").overrideTheme,Z=L.themeOverride===void 0&&n1===void 0?g:{...g,...n1,...L.themeOverride};Z.bgHeader!==g.bgHeader&&(t.fillStyle=Z.bgHeader,t.fill());let d1=`${Z.headerFontStyle} ${Z.fontFamily}`;R!==d1&&(t.font=d1);let O=v.columns.hasIndex(L.sourceIndex),a1=h!==void 0||c,W=!a1&&y===-1&&x===L.sourceIndex,L1=a1?0:(_=(F=u.find(K1=>K1.item[0]===L.sourceIndex&&K1.item[1]===-1))==null?void 0:F.hoverAmount)!=null?_:0,p1=v?.current!==void 0&&v.current.cell[0]===L.sourceIndex,o1=O?Z.accentColor:p1?Z.bgHeaderHasFocus:Z.bgHeader,H1=e?o:0,P1=L.sourceIndex===0?0:1;O?(t.fillStyle=o1,t.fillRect(V+P1,H1,L.width-P1,l)):(p1||L1>0)&&(t.beginPath(),t.rect(V+P1,H1,L.width-P1,l),p1&&(t.fillStyle=Z.bgHeaderHasFocus,t.fill()),L1>0&&(t.globalAlpha=L1,t.fillStyle=Z.bgHeaderHovered,t.fill(),t.globalAlpha=1)),bz(t,V,H1,L.width,l,L,O,Z,W,p1,L1,d,s,f),t.restore()}),e&&Tb(t,a,n,i,o,r,g,d,u,p,z,w)}function Re(t,a,e,r,n,i,l,o){return t<=n+l&&n<=t+e&&a<=i+o&&i<=a+r}function Np(t,a,e,r,n,i,l,o,h,c,v,g,d,u){if(d===void 0||d.length===0)return;let p=g==="sticky"?v(c-1):0;t.beginPath(),_z(a,e,l,n,(z,w,s,f,m,H)=>{for(let x=0;x=z[0]&&y[0]<=z[1]){t.rect(s,f,m,H);break}}}),h4(a,h,l,o,i,(z,w,s,f,m)=>{let H=Math.max(0,f-w),x=w+H+1,y=z.width-H-1;for(let R=0;R{let k=!1;for(let b=0;b0&&t.rect(x,b,y,_)}})}),t.clip()}function Ez(t,a,e,r,n,i,l){var o,h;let[c,v]=t,g,d,u=(h=(o=l.find(p=>!p.sticky))==null?void 0:o.sourceIndex)!=null?h:0;if(v>u){let p=Math.max(c,u),z=a,w=r;for(let s=i.sourceIndex-1;s>=p;s--)z-=l[s].width,w+=l[s].width;for(let s=i.sourceIndex+1;s<=v;s++)w+=l[s].width;d={x:z,y:e,width:w,height:n}}if(u>c){let p=Math.min(v,u-1),z=a,w=r;for(let s=i.sourceIndex-1;s>=c;s--)z-=l[s].width,w+=l[s].width;for(let s=i.sourceIndex+1;s<=p;s++)w+=l[s].width;g={x:z,y:e,width:w,height:n}}return[g,d]}function $p(t,a,e,r,n,i,l,o,h,c,v,g,d,u,p,z,w,s,f,m,H,x,y,R,L,V,C,k,b,F,_){var j;let n1=(j=f?.length)!=null?j:Number.MAX_SAFE_INTEGER,Z=performance.now(),d1=`${b.baseFontStyle} ${b.fontFamily}`;t.font=d1;let O,a1=new Set;return h4(a,o,i,l,n,(W,L1,p1,o1,H1)=>{var P1;let K1=Math.max(0,o1-L1),W1=L1+K1,Bt=n+1,T1=W.width-K1,X1=r-n-1;if(s.length>0){let v1=!1;for(let D=0;D{t.save(),t.beginPath(),t.rect(W1,Bt,T1,X1),t.clip()},N=m.columns.hasIndex(W.sourceIndex),s1=g((P1=W.group)!=null?P1:"").overrideTheme,x1=W.themeOverride===void 0&&s1===void 0?b:{...b,...s1,...W.themeOverride},f1=`${x1.baseFontStyle} ${x1.fontFamily}`;f1!==d1&&(d1=f1,t.font=f1),Y();let U;return ai(H1,p1,r,h,c,w,(v1,D,I,C1,D1)=>{var et,B1,c1,e1;if(D<0)return;if(f!==void 0){let dt=!1;for(let At=0;At0){let dt=!1;for(let At=0;AtI1.span!==void 0&&dt>=I1.span[0]&&dt<=I1.span[1]);Mt&&!p&&z?C0=0:Mt&&(C0=Math.max(C0,1)),Z0&&C0++,Mt||(u1&&C0++,N&&!C1&&C0++);let B0=I1.kind===l1.Protected?J1.bgCellMedium:J1.bgCell,t0;if((C1||B0!==b.bgCell)&&(t0=Le(B0,t0)),C0>0||M1){M1&&(t0=Le(J1.bgHeader,t0));for(let dt=0;dtdt[0]===W.sourceIndex&&dt[1]===D)===!0&&(t0=Le(J1.bgSearchResult,t0));if(x!==void 0)for(let dt of x){let At=dt.range;At.x<=W.sourceIndex&&W.sourceIndexdt.item[0]===W.sourceIndex&&dt.item[1]===D);if(St>10&&!Ut){let dt=`${J1.baseFontStyle} ${J1.fontFamily}`;dt!==d1&&(t.font=dt,d1=dt),U=Sz(t,D,I1,W.sourceIndex,Q1,v1,St,I,C0>0,J1,y,R,L,(c1=Ma?.hoverAmount)!=null?c1:0,C,k,Z,U,F,_)}return I1.style==="faded"&&(t.globalAlpha=1),n1--,jt&&(t.restore(),(e1=U?.deprep)==null||e1.call(U,{ctx:t}),U=void 0,Y(),d1=f1,t.font=f1),n1<=0}),t.restore(),n1<=0}),O}function Ib(t,a,e,r,n,i,l,o,h,c,v,g,d,u,p,z,w,s){w!==void 0||a[a.length-1]!==e[a.length-1]||h4(a,h,l,o,i,(f,m,H,x,y)=>{if(f!==a[a.length-1])return;m+=f.width;let R=Math.max(m,x);R>r||(t.save(),t.beginPath(),t.rect(R,i+1,1e4,n-i-1),t.clip(),ai(y,H,n,c,v,p,(L,V,C,k)=>{if(!k&&z.length>0&&!z.some(n1=>Re(m,L,1e4,C,n1.x,n1.y,n1.width,n1.height)))return;let b=d.hasIndex(V),F=u.hasIndex(V);t.beginPath();let _=g?.(V),j=_===void 0?s:{...s,..._};j.bgCell!==s.bgCell&&(t.fillStyle=j.bgCell,t.fillRect(m,L,1e4,C)),F&&(t.fillStyle=j.bgHeader,t.fillRect(m,L,1e4,C)),b&&(t.fillStyle=j.accentLight,t.fillRect(m,L,1e4,C))}),t.restore())})}function Ob(t,a,e,r,n,i,l,o,h){var c;let v=!1;for(let p of a)if(!p.sticky){v=l(p.sourceIndex);break}let g=(c=h.horizontalBorderColor)!=null?c:h.borderColor,d=h.borderColor,u=v?ur(a):0;if(u!==0&&(t.beginPath(),t.moveTo(u+.5,0),t.lineTo(u+.5,r),t.strokeStyle=Le(d,h.bgCell),t.stroke()),n){let p=o(i-1);t.beginPath(),t.moveTo(0,r-p+.5),t.lineTo(e,r-p+.5),t.strokeStyle=Le(g,h.bgCell),t.stroke()}}function Db(t,a,e,r,n,i,l,o,h,c,v,g,d,u,p){let z=p?.filter(m=>m.style!=="no-outline");if(z===void 0||z.length===0)return;let w=z.map(m=>{var H,x,y,R,L;let V=m.range,C=Kn(V.x,V.y,a,e,v,c+v,r,n,i,l,u,h,d,o,g);if(V.width===1&&V.height===1)return V.x=h){let b=Kn(h-1,V.y+V.height-1,a,e,v,c+v,r,n,i,l,u,h,d,o,g),F=Kn(h,V.y+V.height-1,a,e,v,c+v,r,n,i,l,u,h,d,o,g);return[{color:m.color,style:(y=m.style)!=null?y:"dashed",rect:{x:C.x,y:C.y,width:b.x+b.width-C.x,height:b.y+b.height-C.y}},{color:m.color,style:(R=m.style)!=null?R:"dashed",rect:{x:F.x,y:F.y,width:k.x+k.width-F.x,height:k.y+k.height-F.y}}]}else return[void 0,{color:m.color,style:(L=m.style)!=null?L:"dashed",rect:{x:C.x,y:C.y,width:k.x+k.width-C.x,height:k.y+k.height-C.y}}]}),s=ur(o),f=()=>{t.beginPath(),t.save();let m=!1,H=y=>{m!==y&&(t.setLineDash(y?[5,3]:[]),m=y)};t.lineWidth=1;for(let y of w){let[R]=y;R!==void 0&&Re(0,0,a,e,R.rect.x,R.rect.y,R.rect.width,R.rect.height)&&(H(R.style==="dashed"),t.strokeStyle=fr(R.color,1),t.strokeRect(R.rect.x+1,R.rect.y+1,R.rect.width-2,R.rect.height-2))}let x=!1;for(let y of w){let[,R]=y;R!==void 0&&Re(0,0,a,e,R.rect.x,R.rect.y,R.rect.width,R.rect.height)&&(H(R.style==="dashed"),!x&&R.rect.x{var C;return V.sourceIndex===((C=v.current)==null?void 0:C.cell[0])}))return;let[s,f]=v.current.cell,m=d(v.current.cell),H=(w=m.span)!=null?w:[s,s],x=u==="sticky"&&f===z-1,y=u==="sticky"&&!x?g(z-1)-1:0,R;if(h4(l,r,n,i,c,(V,C,k,b,F)=>{if(!(V.sticky&&s>V.sourceIndex)&&!(V.sourceIndexH[1]))return ai(F,k,e,z,g,u,(_,j,n1)=>{if(j!==f)return;let Z=C,d1=V.width;if(m.span!==void 0){let O=Ez(m.span,C,_,V.width,n1,V,o),a1=V.sticky?O[0]:O[1];a1!==void 0&&(Z=a1.x,d1=a1.width)}return R=()=>{var O,a1,W,L1;b>Z&&!V.sticky&&(t.beginPath(),t.rect(b,0,a-b,e),t.clip()),t.beginPath(),t.rect(Z+.5,_+.5,d1,n1),t.strokeStyle=(a1=(O=V.themeOverride)==null?void 0:O.accentColor)!=null?a1:h.accentColor,t.lineWidth=1,t.stroke(),p&&(t.beginPath(),t.rect(Z+d1-4,_+n1-4,4,4),t.fillStyle=(L1=(W=V.themeOverride)==null?void 0:W.accentColor)!=null?L1:h.accentColor,t.fill())},!0}),!0}),R===void 0)return;let L=()=>{t.save(),t.beginPath(),t.rect(0,c,a,e-c-y),t.clip(),R?.(),t.restore()};return L(),L}function Nb(t,a,e,r,n,i,l,o,h){let c=0;return h4(t,i,r,n,e,(v,g,d,u,p)=>(ai(p,d,a,l,o,h,(z,w,s,f)=>{f||(c=Math.max(w,c))}),!0)),c}function $b(t,a){if(a===void 0||t.width!==a.width||t.height!==a.height||t.theme!==a.theme||t.headerHeight!==a.headerHeight||t.rowHeight!==a.rowHeight||t.rows!==a.rows||t.getRowThemeOverride!==a.getRowThemeOverride||t.isFocused!==a.isFocused||t.isResizing!==a.isResizing||t.verticalBorder!==a.verticalBorder||t.getCellContent!==a.getCellContent||t.highlightRegions!==a.highlightRegions||t.selection!==a.selection||t.dragAndDropState!==a.dragAndDropState||t.prelightCells!==a.prelightCells||t.touchMode!==a.touchMode||t.scrolling!==a.scrolling)return!1;if(t.mappedColumns!==a.mappedColumns){if(t.mappedColumns.length>100||t.mappedColumns.length!==a.mappedColumns.length)return!1;let e;for(let r=0;rx:x;D1.save(),D1.beginPath(),B1.save(),B1.beginPath(),D1.textBaseline="middle",B1.textBaseline="middle",x1!==1&&(D1.scale(x1,x1),B1.scale(x1,x1));let u1=A8(d,h,l,z,v),M1=[],I1=s&&((r=L.current)==null?void 0:r.cell[1])===c&&g===0,Q1=()=>{var ot,J1;Pb(D1,u1,u,o1,l,v,f,m,z,R,L,w,H1,L1,y,F,N,Z,K1),Dp(D1,u1,c,v,g,l,o,void 0,void 0,m,v1,e1,_,y,C,k,w,!0),D1.beginPath(),D1.moveTo(0,D-.5),D1.lineTo(l,D-.5),D1.strokeStyle=Le((J1=(ot=w.headerBottomBorderColor)!=null?ot:w.horizontalBorderColor)!=null?J1:w.borderColor,w.bgHeader),D1.stroke(),I1&&y8(D1,l,o,c,v,g,u1,d,w,v1,L,e1,b,C,V,k)};if(N!==void 0){let ot=!1;N=N.filter(J1=>(ot=ot||J1[1]<0,J1[1]<0||Re(h,c,u1.length,300,J1[0],J1[1],1,1)||Re(0,c,p,300,J1[0],J1[1],1,1)||C&&Re(h,k-1,u1.length,1,J1[0],J1[1],1,1))),N.length>0&&(Np(B1,u1,l,o,m,v1,v,g,c,k,e1,C,N,!0),B1.fillStyle=w.bgCell,B1.fillRect(0,v1+1,l,o-v1-1),$p(B1,u1,d,o,v1,v,g,c,k,e1,b,F,_,H,j,s,C,M1,N,L,d1,O,n1,a1,H1,L1,o1,p1,w,W1,Bt),V&&s&&L.current!==void 0&&N.some(J1=>{var Jt,Mt;return J1[0]===((Jt=L.current)==null?void 0:Jt.cell[0])&&J1[1]===((Mt=L.current)==null?void 0:Mt.cell[1])})&&y8(B1,l,o,c,v,g,u1,d,w,v1,L,e1,b,C,V,k)),ot&&(Np(D1,u1,l,v1,m,v1,v,g,c,k,e1,C,N,!1),Q1()),B1.restore(),D1.restore(),C1!==null&&(C1.fillStyle=w.bgCell,C1.fillRect(0,0,l,o),C1.drawImage(B1.canvas,0,0));return}if((f1!==!0||h!==I?.cellXOffset||v!==I?.translateX||I1!==I?.mustDrawFocusOnHeader)&&Q1(),f1===!0){i2(c1!==void 0&&I!==void 0);let{regions:ot}=Eb(B1,c1,I,h,c,v,g,C==="sticky",l,o,k,v1,x1,d,u1,x,s1);M1=ot}else f1!==!1&&(i2(I!==void 0),M1=_b(I,h,c,v,g,l,o,v1,u1,f1));Ob(B1,u1,l,o,C==="sticky",k,y,e1,w);let St=s?y8(B1,l,o,c,v,g,u1,d,w,v1,L,e1,b,C,V,k):void 0,jt=Db(B1,l,o,h,c,v,g,d,p,f,m,x,C==="sticky",k,O);if(B1.fillStyle=w.bgCell,M1.length>0){B1.beginPath();for(let ot of M1)B1.rect(ot.x,ot.y,ot.width,ot.height);B1.clip(),B1.fill(),B1.beginPath()}else B1.fillRect(0,0,l,o);let Ut=$p(B1,u1,d,o,v1,v,g,c,k,e1,b,F,_,H,j,s,C,M1,N,L,d1,O,n1,a1,H1,L1,o1,p1,w,W1,Bt);Ib(B1,u1,d,l,o,v1,v,g,c,k,e1,_,L.rows,H,C,M1,N,w),Dp(B1,u1,c,v,g,l,o,M1,Ut,m,v1,e1,_,y,C,k,w),St?.(),jt?.(),C1!==null&&(C1.fillStyle=w.bgCell,C1.fillRect(0,0,l,o),C1.drawImage(B1.canvas,0,0));let Et=Nb(u1,o,v1,v,g,c,k,e1,C);a1?.setWindow({x:h,y:c,width:u1.length,height:Et-c},p),W.current={cellXOffset:h,cellYOffset:c,translateX:v,translateY:g,mustDrawFocusOnHeader:I1,lastBuffer:s1?et===X1?"a":"b":void 0},B1.restore(),D1.restore()}function ai(t,a,e,r,n,i,l){let o=a,h=t,c=i==="sticky";for(;o=e;v&&(c=!1,h=r-1);let g=n(h);if(v&&(o=e-g),!(c&&h===r-1)&&l(o,h,g,v,i!=="none"&&h===r-1)===!0||v)break;o+=g,h++}}function h4(t,a,e,r,n,i){let l=0,o=0,h=n+r;for(let c of t){let v=c.sticky?o:l+e;if(i(c,v,h,o,a)===!0)break;l+=c.width,o+=c.sticky?c.width:0}}function _z(t,a,e,r,n){var i;let l=0,o=0;for(let h=0;ha?.[0]===e?.[0]&&a?.[1]===e?.[1],this.addToLeavingItems=a=>{this.leavingItems.some(r=>this.areSameItems(r.item,a.item))||this.leavingItems.push(a)},this.removeFromLeavingItems=a=>{var e;let r=this.leavingItems.find(n=>this.areSameItems(n.item,a));return this.leavingItems=this.leavingItems.filter(n=>n!==r),(e=r?.hoverAmount)!=null?e:0},this.cleanUpLeavingElements=()=>{this.leavingItems=this.leavingItems.filter(a=>a.hoverAmount>0)},this.shouldStep=()=>{let a=this.leavingItems.length>0,e=this.currentHoveredItem!==void 0&&this.currentHoveredItem.hoverAmount<1;return a||e},this.getAnimatingItems=()=>this.currentHoveredItem!==void 0?[...this.leavingItems,this.currentHoveredItem]:this.leavingItems.map(a=>({...a,hoverAmount:Wb(a.hoverAmount)})),this.step=a=>{if(this.lastAnimationTime===void 0)this.lastAnimationTime=a;else{let r=(a-this.lastAnimationTime)/Ub;for(let i of this.leavingItems)i.hoverAmount=(0,b8.default)(i.hoverAmount-r,0,1);this.currentHoveredItem!==void 0&&(this.currentHoveredItem.hoverAmount=(0,b8.default)(this.currentHoveredItem.hoverAmount+r,0,1));let n=this.getAnimatingItems();this.callback(n),this.cleanUpLeavingElements()}this.shouldStep()?(this.lastAnimationTime=a,window.requestAnimationFrame(this.step)):this.lastAnimationTime=void 0},this.setHovered=a=>{var e;if(!this.areSameItems((e=this.currentHoveredItem)==null?void 0:e.item,a)){if(this.currentHoveredItem!==void 0&&this.addToLeavingItems(this.currentHoveredItem),a!==void 0){let r=this.removeFromLeavingItems(a);this.currentHoveredItem={item:a,hoverAmount:r}}else this.currentHoveredItem=void 0;this.lastAnimationTime===void 0&&window.requestAnimationFrame(this.step)}}}},qb=class{constructor(t){this.fn=t}get value(){var t;return(t=this.val)!=null?t:this.val=this.fn()}};function W8(t){return new qb(t)}var Gb=W8(()=>window.navigator.userAgent.includes("Firefox")),Tz=W8(()=>window.navigator.userAgent.includes("Mac OS")&&window.navigator.userAgent.includes("Safari")&&!window.navigator.userAgent.includes("Chrome")),E5=W8(()=>window.navigator.platform.toLowerCase().startsWith("mac"));function Kb(t,a){for(let e of t)if(e[0]===a[0]&&e[1]===a[1])return!0;return!1}function Xb(t){let a=l4.useRef([]),e=l4.useRef(0),r=l4.useRef(t);r.current=t;let n=l4.useCallback(()=>{let i=()=>window.requestAnimationFrame(l),l=()=>{let o=a.current;a.current=[],r.current(o),a.current.length>0?e.current++:e.current=0};window.requestAnimationFrame(e.current>600?i:l)},[]);return l4.useCallback(i=>{Kb(a.current,i)||(a.current.length===0&&n(),a.current.push(i))},[n])}var Yb=(t,a)=>{var e;if(t.kind===l1.Custom)return t.copyData;let r=a?.(t);return(e=r?.getAccessibilityString(t))!=null?e:""},Qb=(t,a)=>{var e,r,n,i,l,o,h,c;let{width:v,height:g,accessibilityHeight:d,columns:u,cellXOffset:p,cellYOffset:z,headerHeight:w,fillHandle:s=!1,groupHeaderHeight:f,rowHeight:m,rows:H,getCellContent:x,getRowThemeOverride:y,onHeaderMenuClick:R,enableGroups:L,isFilling:V,onCanvasFocused:C,onCanvasBlur:k,isFocused:b,selection:F,freezeColumns:_,onContextMenu:j,trailingRowType:n1,fixedShadowX:Z=!0,fixedShadowY:d1=!0,drawFocusRing:O=!0,onMouseDown:a1,onMouseUp:W,onMouseMoveRaw:L1,onMouseMove:p1,onItemHovered:o1,dragAndDropState:H1,firstColAccessible:P1,onKeyDown:K1,onKeyUp:W1,highlightRegions:Bt,canvasRef:T1,onDragStart:X1,onDragEnd:Y,eventTargetRef:N,isResizing:s1,isDragging:x1,isDraggable:f1=!1,allowResize:U,disabledRows:v1,getGroupDetails:D,theme:I,prelightCells:C1,headerIcons:D1,verticalBorder:et,drawHeader:B1,drawCustomCell:c1,onCellFocused:e1,onDragOverCell:u1,onDrop:M1,onDragLeave:I1,imageWindowLoader:Q1,smoothScrollX:St=!1,smoothScrollY:jt=!1,experimental:Ut,getCellRenderer:Et}=t,ot=(e=t.translateX)!=null?e:0,J1=(r=t.translateY)!=null?r:0,Jt=Math.max(_,Math.min(u.length-1,p)),Mt=r1.useRef(null),C0=r1.useMemo(()=>new yk,[]),Z0=Q1??C0,B0=r1.useRef(),[t0,Ma]=r1.useState(!1),dt=r1.useRef([]),At=r1.useRef(),[h0,wt]=r1.useState(),[Ft,qt]=r1.useState(),c2=r1.useRef(null),[v2,$a]=r1.useState(!1),O2=r1.useRef(v2);O2.current=v2;let j0=r1.useMemo(()=>new Fb(D1,()=>{la.current=void 0,oa.current()}),[D1]),g2=L?f+w:w,D2=r1.useRef(-1),ri=Ut?.enableFirefoxRescaling!==!0;r1.useLayoutEffect(()=>{!Gb.value||window.devicePixelRatio===1||ri||(D2.current!==-1&&Ma(!0),window.clearTimeout(D2.current),D2.current=window.setTimeout(()=>{Ma(!1),D2.current=-1},200))},[z,Jt,ot,J1,ri]);let u0=Ek(u,_),Ht=r1.useCallback((S,G,b1)=>{let z1=S.getBoundingClientRect();if(G>=u0.length||b1>=H)return;let E1=z1.width/v,h1=Kn(G,b1,v,g,f,g2,Jt,z,ot,J1,H,_,n1==="sticky",u0,m);return E1!==1&&(h1.x*=E1,h1.y*=E1,h1.width*=E1,h1.height*=E1),h1.x+=z1.x,h1.y+=z1.y,h1},[v,g,f,g2,Jt,z,ot,J1,H,_,n1,u0,m]),m0=r1.useCallback((S,G,b1,z1)=>{var E1,h1;let $1=S.getBoundingClientRect(),st=$1.width/v,S1=(G-$1.left)/st,_1=(b1-$1.top)/st,a0=5,tt=A8(u0,Jt,v,void 0,ot),ut=0;z1 instanceof MouseEvent&&(ut=z1.button);let ht=Pk(S1,tt,ot),xt=Ik(_1,g,L,w,f,H,m,z,J1,n1==="sticky"),_t=z1?.shiftKey===!0,Ca=z1?.ctrlKey===!0,y2=z1?.metaKey===!0,C2=z1!==void 0&&!(z1 instanceof MouseEvent)||z1?.pointerType==="touch",N2=20,B2=[Math.abs(S1)v||_1>g){let G1=S1>v?-1:S1<0?1:0,Gt=_1>g?1:_1<0?-1:0,n0=!1;if(ht===-1&&xt===-1){let A0=Ht(S,u0.length-1,-1);i2(A0!==void 0),n0=G=0?(Gt=!0,G1=Ht(S,n0,xt),i2(G1!==void 0),u2={kind:L&&xt===-2?w2:xe,location:[n0,xt],bounds:G1,group:(E1=u0[n0].group)!=null?E1:"",isEdge:Gt,shiftKey:_t,ctrlKey:Ca,metaKey:y2,isTouch:C2,localEventX:G-G1.x,localEventY:b1-G1.y,button:ut,scrollEdge:B2}):u2={kind:L&&xt===-2?w2:xe,group:(h1=u0[ht].group)!=null?h1:"",location:[ht,xt],bounds:G1,isEdge:Gt,shiftKey:_t,ctrlKey:Ca,metaKey:y2,isTouch:C2,localEventX:G-G1.x,localEventY:b1-G1.y,button:ut,scrollEdge:B2}}else{let G1=Ht(S,ht,xt);i2(G1!==void 0);let Gt=G1!==void 0&&G1.x+G1.width-G{}),xr=r1.useRef(h0);xr.current=h0;let[Se,Ae]=r1.useMemo(()=>{let S=document.createElement("canvas"),G=document.createElement("canvas");return S.style.display="none",S.style.opacity="0",S.style.position="fixed",G.style.display="none",G.style.opacity="0",G.style.position="fixed",[S,G]},[]);r1.useLayoutEffect(()=>(document.documentElement.append(Se),document.documentElement.append(Ae),()=>{Se.remove(),Ae.remove()}),[Se,Ae]);let la=r1.useRef(),Ha=r1.useCallback(()=>{var S,G;let b1=Mt.current,z1=c2.current;if(b1===null||z1===null)return;let E1=la.current,h1={canvas:b1,bufferA:Se,bufferB:Ae,headerCanvas:z1,width:v,height:g,cellXOffset:Jt,cellYOffset:z,translateX:Math.round(ot),translateY:Math.round(J1),mappedColumns:u0,enableGroups:L,freezeColumns:_,dragAndDropState:H1,theme:I,headerHeight:w,groupHeaderHeight:f,disabledRows:v1??mt.empty(),rowHeight:m,verticalBorder:et,isResizing:s1,isFocused:b,selection:F,fillHandle:s,lastRowSticky:n1,rows:H,drawFocus:O,getCellContent:x,getGroupDetails:D??($1=>({name:$1})),getRowThemeOverride:y,drawCustomCell:c1,drawHeaderCallback:B1,prelightCells:C1,highlightRegions:Bt,imageLoader:Z0,lastBlitData:At,damage:B0.current,hoverValues:dt.current,hoverInfo:xr.current,spriteManager:j0,scrolling:t0,hyperWrapping:(S=Ut?.hyperWrapping)!=null?S:!1,touchMode:v2,enqueue:ni.current,renderStrategy:(G=Ut?.renderStrategy)!=null?G:Tz.value?"double-buffer":"single-buffer",getCellRenderer:Et};h1.damage===void 0?(la.current=h1,Up(h1,E1)):Up(h1,void 0)},[Se,Ae,v,g,Jt,z,ot,J1,u0,L,_,H1,I,w,f,v1,m,et,s1,b,F,s,n1,H,O,x,D,y,c1,B1,C1,Bt,Z0,j0,t0,Ut?.hyperWrapping,Ut?.renderStrategy,v2,Et]),oa=r1.useRef(Ha);r1.useLayoutEffect(()=>{Ha(),oa.current=Ha},[Ha]),r1.useLayoutEffect(()=>{(async()=>{var G;((G=document?.fonts)==null?void 0:G.ready)!==void 0&&(await document.fonts.ready,la.current=void 0,oa.current())})()},[]);let xa=r1.useCallback(S=>{B0.current=S,oa.current(),B0.current=void 0},[]),q5=Xb(xa);ni.current=q5;let ii=r1.useCallback(S=>{xa(S.map(G=>G.cell))},[xa]);Z0.setCallback(xa);let[G5,li]=r1.useState(!1),[c4,Fe]=ia??[],oi=c4!==void 0&&Fe===-1,wr=c4!==void 0&&Fe===-2,ke=!1,v4=!1,d2;if(c4!==void 0&&Fe!==void 0&&Fe>-1){let S=x([c4,Fe],!0);ke=S.kind===o2.NewRow||S.kind===o2.Marker&&S.markerKind!=="number",v4=S.kind===l1.Boolean&&S8(S),d2=S.cursor}let wa=x1?"grabbing":(Ft??!1)||s1?"col-resize":G5||V?"crosshair":d2!==void 0?d2:oi||ke||v4||wr?"pointer":"default",Ua=r1.useMemo(()=>({contain:"strict",display:"block",cursor:wa}),[wa]),hi=r1.useRef("default"),ci=N?.current;ci!=null&&hi.current!==Ua.cursor&&(ci.style.cursor=hi.current=Ua.cursor);let La=r1.useCallback((S,G,b1,z1)=>{if(D===void 0)return;let E1=D(S);if(E1.actions!==void 0){let h1=Az(G,E1.actions);for(let[$1,st]of h1.entries())if(Fz(st,b1+G.x,z1+st.y))return E1.actions[$1]}},[D]),ha=r1.useCallback((S,G,b1,z1)=>{let E1=u[G];if(!x1&&!s1&&E1.hasMenu===!0&&!(Ft??!1)){let h1=Ht(S,G,-1);i2(h1!==void 0);let $1=kz(h1.x,h1.y,h1.width,h1.height,N8(E1.title)==="rtl");if(b1>$1.x&&b1<$1.x+$1.width&&z1>$1.y&&z1<$1.y+$1.height)return h1}},[u,Ht,Ft,x1,s1]),M0=r1.useRef(0),Va=r1.useRef(),g4=r1.useRef(!1),Lr=r1.useCallback(S=>{let G=Mt.current,b1=N?.current;if(G===null||S.target!==G&&S.target!==b1)return;g4.current=!0;let z1,E1;if(S instanceof MouseEvent?(z1=S.clientX,E1=S.clientY):(z1=S.touches[0].clientX,E1=S.touches[0].clientY),S.target===b1&&b1!==null){let $1=b1.getBoundingClientRect();if(z1>$1.right||E1>$1.bottom)return}let h1=m0(G,z1,E1,S);Va.current=h1.location,h1.isTouch&&(M0.current=Date.now()),O2.current!==h1.isTouch&&$a(h1.isTouch),!(h1.kind===xe&&ha(G,h1.location[0],z1,E1)!==void 0)&&(h1.kind===w2&&La(h1.group,h1.bounds,h1.localEventX,h1.localEventY)!==void 0||(a1?.(h1),!h1.isTouch&&f1!==!0&&f1!==h1.kind&&S.preventDefault()))},[N,f1,m0,La,ha,a1]);W0("touchstart",Lr,window,!1),W0("mousedown",Lr,window,!1);let vi=r1.useCallback(S=>{var G,b1;let z1=Mt.current;if(g4.current=!1,W===void 0||z1===null)return;let E1=N?.current,h1=S.target!==z1&&S.target!==E1,$1,st;if(S instanceof MouseEvent){if($1=S.clientX,st=S.clientY,S.pointerType==="touch")return}else $1=S.changedTouches[0].clientX,st=S.changedTouches[0].clientY;let S1=m0(z1,$1,st,S);S1.isTouch&&M0.current!==0&&Date.now()-M0.current>500&&(S1={...S1,isLongTouch:!0}),O2.current!==S1.isTouch&&$a(S1.isTouch),!h1&&S.cancelable&&S.preventDefault();let[_1]=S1.location,a0=ha(z1,_1,$1,st);if(S1.kind===xe&&a0!==void 0){(S1.button!==0||((G=Va.current)==null?void 0:G[0])!==_1||((b1=Va.current)==null?void 0:b1[1])!==-1)&&W(S1,!0);return}else if(S1.kind===w2){let tt=La(S1.group,S1.bounds,S1.localEventX,S1.localEventY);if(tt!==void 0){S1.button===0&&tt.onClick(S1);return}}W(S1,h1)},[W,N,m0,ha,La]);W0("mouseup",vi,window,!1),W0("touchend",vi,window,!1);let K5=r1.useCallback(S=>{var G,b1;let z1=Mt.current;if(z1===null)return;let E1=N?.current,h1=S.target!==z1&&S.target!==E1,$1,st;S instanceof MouseEvent?($1=S.clientX,st=S.clientY):($1=S.changedTouches[0].clientX,st=S.changedTouches[0].clientY);let S1=m0(z1,$1,st,S);O2.current!==S1.isTouch&&$a(S1.isTouch),!h1&&S.cancelable&&S.preventDefault();let[_1]=S1.location,a0=ha(z1,_1,$1,st);if(S1.kind===xe&&a0!==void 0)S1.button===0&&((G=Va.current)==null?void 0:G[0])===_1&&((b1=Va.current)==null?void 0:b1[1])===-1&&R?.(_1,a0);else if(S1.kind===w2){let tt=La(S1.group,S1.bounds,S1.localEventX,S1.localEventY);tt!==void 0&&S1.button===0&&tt.onClick(S1)}},[N,m0,ha,R,La]);W0("click",K5,window,!1);let Lt=r1.useCallback(S=>{let G=Mt.current;if(G===null||j===void 0)return;let b1=m0(G,S.clientX,S.clientY,S);j(b1,()=>{S.cancelable&&S.preventDefault()})},[m0,j]);W0("contextmenu",Lt,(n=N?.current)!=null?n:null,!1);let Wa=r1.useCallback(S=>{B0.current=S.map(G=>G.item),dt.current=S,oa.current(),B0.current=void 0},[]),s2=r1.useMemo(()=>new jb(Wa),[Wa]),P=r1.useRef(s2);P.current=s2,r1.useLayoutEffect(()=>{let S=P.current;if(ia===void 0||ia[1]<0){S.setHovered(ia);return}let G=x(ia),b1=Et(G);S.setHovered(b1===void 0&&G.kind===l1.Custom||b1?.needsHover===!0?ia:void 0)},[x,Et,ia]);let H0=r1.useRef(),V2=r1.useCallback(S=>{var G;let b1=Mt.current;if(b1===null)return;let z1=N?.current,E1=S.target!==b1&&S.target!==z1,h1=m0(b1,S.clientX,S.clientY,S);if(h1.kind!=="out-of-bounds"&&E1&&!g4.current&&!h1.isTouch)return;if(!j5(h1,H0.current))o1?.(h1),wt(h1.kind===O5?void 0:[h1.location,[h1.localEventX,h1.localEventY]]),H0.current=h1;else if(h1.kind==="cell"||h1.kind===xe||h1.kind===w2){let st=[h1.location,[h1.localEventX,h1.localEventY]];if(wt(st),xr.current=st,h1.kind==="cell"){let S1=x(h1.location);(S1.kind===l1.Custom||((G=Et(S1))==null?void 0:G.needsHoverPosition)===!0)&&xa([h1.location])}else h1.kind===w2&&xa([h1.location])}let $1=h1.location[0]>=(P1?0:1);if(qt(h1.kind===xe&&h1.isEdge&&$1&&U===!0),s&&F.current!==void 0){let[st,S1]=F.current.cell,_1=Ht(b1,st,S1),a0=S.clientX,tt=S.clientY;i2(_1!==void 0),li(a0>=_1.x+_1.width-6&&a0<=_1.x+_1.width&&tt>=_1.y+_1.height-6&&tt<=_1.y+_1.height)}else li(!1);L1?.(S),p1(h1)},[N,m0,P1,U,s,F,L1,p1,o1,x,Et,xa,Ht]);W0("mousemove",V2,window,!0);let X5=r1.useCallback(S=>{let G=Mt.current;if(G===null)return;let b1,z1;F.current!==void 0&&(b1=Ht(G,F.current.cell[0],F.current.cell[1]),z1=F.current.cell),K1?.({bounds:b1,stopPropagation:()=>S.stopPropagation(),preventDefault:()=>S.preventDefault(),cancel:()=>{},ctrlKey:S.ctrlKey,metaKey:S.metaKey,shiftKey:S.shiftKey,altKey:S.altKey,key:S.key,keyCode:S.keyCode,rawEvent:S,location:z1})},[K1,F,Ht]),gi=r1.useCallback(S=>{let G=Mt.current;if(G===null)return;let b1,z1;F.current!==void 0&&(b1=Ht(G,F.current.cell[0],F.current.cell[1]),z1=F.current.cell),W1?.({bounds:b1,stopPropagation:()=>S.stopPropagation(),preventDefault:()=>S.preventDefault(),cancel:()=>{},ctrlKey:S.ctrlKey,metaKey:S.metaKey,shiftKey:S.shiftKey,altKey:S.altKey,key:S.key,keyCode:S.keyCode,rawEvent:S,location:z1})},[W1,F,Ht]),Y5=r1.useCallback(S=>{Mt.current=S,T1!==void 0&&(T1.current=S)},[T1]),Q5=r1.useCallback(S=>{let G=Mt.current;if(G===null||f1===!1||s1){S.preventDefault();return}let b1,z1,E1=m0(G,S.clientX,S.clientY);if(f1!==!0&&E1.kind!==f1){S.preventDefault();return}let h1=(tt,ut)=>{b1=tt,z1=ut},$1,st,S1,_1=(tt,ut,ht)=>{$1=tt,st=ut,S1=ht},a0=!1;if(X1?.({...E1,setData:h1,setDragImage:_1,preventDefault:()=>a0=!0,defaultPrevented:()=>a0}),!a0&&b1!==void 0&&z1!==void 0&&S.dataTransfer!==null)if(S.dataTransfer.setData(b1,z1),S.dataTransfer.effectAllowed="copyLink",$1!==void 0&&st!==void 0&&S1!==void 0)S.dataTransfer.setDragImage($1,st,S1);else{let[tt,ut]=E1.location;if(ut!==void 0){let ht=document.createElement("canvas"),xt=Ht(G,tt,ut);i2(xt!==void 0),ht.width=xt.width,ht.height=xt.height;let _t=ht.getContext("2d");_t!==null&&(_t.textBaseline="middle",ut===-1?(_t.font=`${I.headerFontStyle} ${I.fontFamily}`,_t.fillStyle=I.bgHeader,_t.fillRect(0,0,ht.width,ht.height),bz(_t,0,0,xt.width,xt.height,u0[tt],!1,I,!1,!1,0,j0,B1,!1)):(_t.font=`${I.baseFontStyle} ${I.fontFamily}`,_t.fillStyle=I.bgCell,_t.fillRect(0,0,ht.width,ht.height),Sz(_t,ut,x([tt,ut]),0,0,0,xt.width,xt.height,!1,I,c1,Z0,j0,1,void 0,!1,0,void 0,void 0,Et))),ht.style.left="-100%",ht.style.position="absolute",document.body.append(ht),S.dataTransfer.setDragImage(ht,xt.width/2,xt.height/2),window.setTimeout(()=>{ht.remove()},0)}}else S.preventDefault()},[f1,s1,m0,X1,Ht,I,u0,j0,B1,x,c1,Z0,Et]);W0("dragstart",Q5,(i=N?.current)!=null?i:null,!1,!1);let d4=r1.useRef(),q=r1.useCallback(S=>{var G;let b1=Mt.current;if(M1!==void 0&&S.preventDefault(),b1===null||u1===void 0)return;let z1=m0(b1,S.clientX,S.clientY),[E1,h1]=z1.location,$1=E1-(P1?0:1),[st,S1]=(G=d4.current)!=null?G:[];(st!==$1||S1!==h1)&&(d4.current=[$1,h1],u1([$1,h1],S.dataTransfer))},[P1,m0,u1,M1]);W0("dragover",q,(l=N?.current)!=null?l:null,!1,!1);let R2=r1.useCallback(()=>{d4.current=void 0,Y?.()},[Y]);W0("dragend",R2,(o=N?.current)!=null?o:null,!1,!1);let P0=r1.useCallback(S=>{let G=Mt.current;if(G===null||M1===void 0)return;S.preventDefault();let b1=m0(G,S.clientX,S.clientY),[z1,E1]=b1.location,h1=z1-(P1?0:1);M1([h1,E1],S.dataTransfer)},[P1,m0,M1]);W0("drop",P0,(h=N?.current)!=null?h:null,!1,!1);let Z5=r1.useCallback(()=>{I1?.()},[I1]);W0("dragleave",Z5,(c=N?.current)!=null?c:null,!1,!1);let di=r1.useRef(F);di.current=F;let Ra=r1.useRef(null),J0=r1.useCallback(S=>{var G;Mt.current===null||!Mt.current.contains(document.activeElement)||(S===null&&di.current.current!==void 0?(G=T1?.current)==null||G.focus({preventScroll:!0}):S!==null&&S.focus({preventScroll:!0}),Ra.current=S)},[T1]);r1.useImperativeHandle(a,()=>({focus:()=>{var S;let G=Ra.current;G===null||!document.contains(G)?(S=T1?.current)==null||S.focus({preventScroll:!0}):G.focus({preventScroll:!0})},getBounds:(S,G)=>{if(!(T1===void 0||T1.current===null))return Ht(T1.current,S,G??-1)},damage:ii}),[T1,ii,Ht]);let ya=r1.useRef(),J5=Sk(()=>{var S,G,b1,z1;if(v<50)return null;let E1=A8(u0,Jt,v,H1,ot),h1=P1?0:-1;!P1&&((S=E1[0])==null?void 0:S.sourceIndex)===0&&(E1=E1.slice(1));let[$1,st]=(b1=(G=F.current)==null?void 0:G.cell)!=null?b1:[],S1=(z1=F.current)==null?void 0:z1.range,_1=E1.map(tt=>tt.sourceIndex),a0=(0,Cz.default)(z,Math.min(H,z+d));return $1!==void 0&&st!==void 0&&!(_1.includes($1)&&a0.includes(st))&&J0(null),r1.createElement("table",{key:"access-tree",role:"grid","aria-rowcount":H+1,"aria-multiselectable":"true","aria-colcount":u0.length+h1},r1.createElement("thead",{role:"rowgroup"},r1.createElement("tr",{role:"row","aria-rowindex":1},E1.map(tt=>r1.createElement("th",{role:"columnheader","aria-selected":F.columns.hasIndex(tt.sourceIndex),"aria-colindex":tt.sourceIndex+1+h1,tabIndex:-1,onFocus:ut=>{if(ut.target!==Ra.current)return e1?.([tt.sourceIndex,-1])},key:tt.sourceIndex},tt.title)))),r1.createElement("tbody",{role:"rowgroup"},a0.map(tt=>r1.createElement("tr",{role:"row","aria-selected":F.rows.hasIndex(tt),key:tt,"aria-rowindex":tt+2},E1.map(ut=>{let ht=ut.sourceIndex,xt=`${ht},${tt}`,_t=$1===ht&&st===tt,Ca=S1!==void 0&&ht>=S1.x&&ht=S1.y&&tt{let B2=T1?.current;if(B2!=null)return K1?.({bounds:Ht(B2,ht,tt),cancel:()=>{},preventDefault:()=>{},stopPropagation:()=>{},ctrlKey:!1,key:"Enter",keyCode:13,metaKey:!1,shiftKey:!1,altKey:!1,rawEvent:void 0,location:C2})},onFocusCapture:B2=>{var u2,G1;if(!(B2.target===Ra.current||((u2=ya.current)==null?void 0:u2[0])===ht&&((G1=ya.current)==null?void 0:G1[1])===tt))return ya.current=C2,e1?.(C2)},ref:_t?J0:void 0,tabIndex:-1},Yb(N2,Et))})))))},[v,u0,Jt,H1,ot,H,z,d,F,J0,x,T1,K1,Ht,e1],200),Vr=Z?ur(u0,H1):0,s4=_===0||!Z?0:Jt>_?1:(0,F8.default)(-ot/100,0,1),Rr=-z*32+J1,c0=d1?(0,F8.default)(-Rr/100,0,1):0,S0=r1.useMemo(()=>{if(!s4&&!c0)return null;let S={position:"absolute",top:0,left:Vr,width:v-Vr,height:g,opacity:s4,pointerEvents:"none",transition:St?void 0:"opacity 0.2s",boxShadow:"inset 13px 0 10px -13px rgba(0, 0, 0, 0.2)"},G={position:"absolute",top:g2,left:0,width:v,height:g,opacity:c0,pointerEvents:"none",transition:jt?void 0:"opacity 0.2s",boxShadow:"inset 0 13px 10px -13px rgba(0, 0, 0, 0.2)"};return r1.createElement(r1.Fragment,null,s4>0&&r1.createElement("div",{id:"shadow-x",style:S}),c0>0&&r1.createElement("div",{id:"shadow-y",style:G}))},[s4,c0,Vr,v,St,g2,g,jt]),v0=r1.useMemo(()=>({position:"absolute",top:0,left:0}),[]);return r1.createElement(r1.Fragment,null,r1.createElement("canvas",{"data-testid":"data-grid-canvas",tabIndex:0,onKeyDown:X5,onKeyUp:gi,onFocus:C,onBlur:k,ref:Y5,style:Ua},J5),r1.createElement("canvas",{ref:c2,style:v0}),S0)},Zb=r1.memo(r1.forwardRef(Qb));function qn(t,a,e,r){var n;return(0,dz.default)(Math.round(a-((n=t.growOffset)!=null?n:0)),Math.ceil(e),Math.floor(r))}var Jb=t=>{var a;let[e,r]=It.useState(),[n,i]=It.useState(),[l,o]=It.useState(),[h,c]=It.useState(),[v,g]=It.useState(!1),[d,u]=It.useState(),[p,z]=It.useState(),[w,s]=It.useState(),[f,m]=It.useState(!1),[H,x]=It.useState(),{onHeaderMenuClick:y,getCellContent:R,onColumnMoved:L,onColumnResize:V,onColumnResizeStart:C,onColumnResizeEnd:k,gridRef:b,maxColumnWidth:F,minColumnWidth:_,onRowMoved:j,lockColumns:n1,onMouseDown:Z,onMouseUp:d1,onItemHovered:O,onDragStart:a1,canvasRef:W}=t,L1=((a=V??k)!=null?a:C)!==void 0,{columns:p1,selection:o1}=t,H1=o1.columns,P1=It.useCallback(U=>{let[v1,D]=U.location;l!==void 0&&h!==v1&&v1>=n1?(g(!0),c(v1)):p!==void 0&&D!==void 0?(m(!0),s(Math.max(0,D))):O?.(U)},[l,p,h,O,n1]),K1=L!==void 0,W1=It.useCallback(U=>{var v1,D;if(U.button===0){let[I,C1]=U.location;if(U.kind==="out-of-bounds"&&U.isEdge&&L1){let D1=(v1=b?.current)==null?void 0:v1.getBounds(p1.length-1,-1);D1!==void 0&&(r(D1.x),i(p1.length-1))}else if(U.kind==="header"&&I>=n1){let D1=W?.current;if(U.isEdge&&L1&&D1){r(U.bounds.x),i(I);let B1=D1.getBoundingClientRect().width/D1.offsetWidth,c1=U.bounds.width/B1;C?.(p1[I],c1,I,c1+((D=p1[I].growOffset)!=null?D:0))}else U.kind==="header"&&K1&&(u(U.bounds.x),o(I))}else U.kind==="cell"&&n1>0&&I===0&&C1!==void 0&&j!==void 0&&(x(U.bounds.y),z(C1))}Z?.(U)},[Z,L1,n1,j,b,p1,K1,C,W]),Bt=It.useCallback((U,v1)=>{v||f||y?.(U,v1)},[v,f,y]),T1=It.useRef(-1),X1=It.useCallback(()=>{T1.current=-1,z(void 0),s(void 0),x(void 0),m(!1),o(void 0),c(void 0),u(void 0),g(!1),i(void 0),r(void 0)},[]),Y=It.useCallback((U,v1)=>{var D,I,C1;if(U.button===0){if(n!==void 0){if(H1?.hasIndex(n)===!0)for(let et of H1){if(et===n)continue;let B1=p1[et],c1=qn(B1,T1.current,_,F);V?.(B1,c1,et,c1+((D=B1.growOffset)!=null?D:0))}let D1=qn(p1[n],T1.current,_,F);if(k?.(p1[n],D1,n,D1+((I=p1[n].growOffset)!=null?I:0)),H1.hasIndex(n))for(let et of H1){if(et===n)continue;let B1=p1[et],c1=qn(B1,T1.current,_,F);k?.(B1,c1,et,c1+((C1=B1.growOffset)!=null?C1:0))}}X1(),l!==void 0&&h!==void 0&&L?.(l,h),p!==void 0&&w!==void 0&&j?.(p,w)}d1?.(U,v1)},[d1,n,l,h,p,w,H1,k,p1,_,F,V,L,j,X1]),N=It.useMemo(()=>{if(!(l===void 0||h===void 0)&&l!==h)return{src:l,dest:h}},[l,h]),s1=It.useCallback(U=>{var v1,D;let I=W?.current;if(l!==void 0&&d!==void 0)Math.abs(U.clientX-d)>20&&g(!0);else if(p!==void 0&&H!==void 0)Math.abs(U.clientY-H)>20&&m(!0);else if(n!==void 0&&e!==void 0&&I){let D1=I.getBoundingClientRect().width/I.offsetWidth,et=(U.clientX-e)/D1,B1=p1[n],c1=qn(B1,et,_,F);if(V?.(B1,c1,n,c1+((v1=B1.growOffset)!=null?v1:0)),T1.current=et,H1?.first()===n)for(let e1 of H1){if(e1===n)continue;let u1=p1[e1],M1=qn(u1,T1.current,_,F);V?.(u1,M1,e1,M1+((D=u1.growOffset)!=null?D:0))}}},[l,d,p,H,n,e,p1,_,F,V,H1,W]),x1=It.useCallback((U,v1)=>{if(p===void 0||w===void 0)return R(U,v1);let[D,I]=U;return I===w?I=p:(I>w&&(I-=1),I>=p&&(I+=1)),R([D,I],v1)},[p,w,R]),f1=It.useCallback(U=>{a1?.(U),U.defaultPrevented()||X1()},[X1,a1]);return It.createElement(Zb,{accessibilityHeight:t.accessibilityHeight,canvasRef:t.canvasRef,cellXOffset:t.cellXOffset,cellYOffset:t.cellYOffset,columns:t.columns,disabledRows:t.disabledRows,drawCustomCell:t.drawCustomCell,drawFocusRing:t.drawFocusRing,drawHeader:t.drawHeader,enableGroups:t.enableGroups,eventTargetRef:t.eventTargetRef,experimental:t.experimental,fillHandle:t.fillHandle,firstColAccessible:t.firstColAccessible,fixedShadowX:t.fixedShadowX,fixedShadowY:t.fixedShadowY,freezeColumns:t.freezeColumns,getCellRenderer:t.getCellRenderer,getGroupDetails:t.getGroupDetails,getRowThemeOverride:t.getRowThemeOverride,groupHeaderHeight:t.groupHeaderHeight,headerHeight:t.headerHeight,headerIcons:t.headerIcons,height:t.height,highlightRegions:t.highlightRegions,imageWindowLoader:t.imageWindowLoader,isDraggable:t.isDraggable,isFilling:t.isFilling,isFocused:t.isFocused,onCanvasBlur:t.onCanvasBlur,onCanvasFocused:t.onCanvasFocused,onCellFocused:t.onCellFocused,onContextMenu:t.onContextMenu,onDragEnd:t.onDragEnd,onDragLeave:t.onDragLeave,onDragOverCell:t.onDragOverCell,onDrop:t.onDrop,onKeyDown:t.onKeyDown,onKeyUp:t.onKeyUp,onMouseMove:t.onMouseMove,prelightCells:t.prelightCells,rowHeight:t.rowHeight,rows:t.rows,selection:t.selection,smoothScrollX:t.smoothScrollX,smoothScrollY:t.smoothScrollY,theme:t.theme,trailingRowType:t.trailingRowType,translateX:t.translateX,translateY:t.translateY,verticalBorder:t.verticalBorder,width:t.width,getCellContent:x1,isResizing:n!==void 0,onHeaderMenuClick:Bt,isDragging:v,onItemHovered:P1,onDragStart:f1,onMouseDown:W1,allowResize:L1,onMouseUp:Y,dragAndDropState:N,onMouseMoveRaw:s1,ref:b})},tE=Jb;function aE(t){let a=(0,zr.useRef)(null),[e,r]=(0,zr.useState)({width:t?.[0],height:t?.[1]});return(0,zr.useLayoutEffect)(()=>{let n=l=>{for(let o of l){let{width:h,height:c}=o&&o.contentRect||{};r(v=>v.width===h&&v.height===c?v:{width:h,height:c})}},i=new window.ResizeObserver(n);return a.current&&i.observe(a.current,void 0),()=>{i.disconnect()}},[a.current]),{ref:a,...e}}var eE=()=>t=>t.isSafari?"scroll":"auto",rE=L0("div")({name:"ScrollRegionStyle",class:"s1jz82f8",vars:{"s1jz82f8-0":[eE()]}});function C8(t){t.stopPropagation()}function nE(t){let[a,e]=lt.useState(!1),r=lt.useRef(0);return W0("touchstart",lt.useCallback(()=>{window.clearTimeout(r.current),e(!0)},[]),window,!0,!1),W0("touchend",lt.useCallback(n=>{n.touches.length===0&&(r.current=window.setTimeout(()=>e(!1),t))},[t]),window,!0,!1),a}var iE=t=>{var a,e,r,n;let{children:i,clientHeight:l,scrollHeight:o,scrollWidth:h,update:c,draggable:v,className:g,preventDiagonalScrolling:d=!1,paddingBottom:u=0,paddingRight:p=0,rightElement:z,rightElementProps:w,scrollRef:s,scrollToEnd:f,initialSize:m,minimap:H}=t,x=[],y=(a=w?.sticky)!=null?a:!1,R=(e=w?.fill)!=null?e:!1,L=lt.useRef(0),V=lt.useRef(0),C=lt.useRef(null),k=window.devicePixelRatio;lt.useEffect(()=>{let W1=C.current;W1===null||f!==!0||(W1.scrollLeft=W1.scrollWidth-W1.clientWidth)},[f]);let b=lt.useRef({scrollLeft:0,scrollTop:0,lockDirection:void 0}),F=lt.useRef(null),_=nE(200),[j,n1]=lt.useState(!0),Z=lt.useRef(0);lt.useEffect(()=>{if(!j||_||b.current.lockDirection===void 0)return;let W1=C.current;if(W1===null)return;let[Bt,T1]=b.current.lockDirection;Bt!==void 0?W1.scrollLeft=Bt:T1!==void 0&&(W1.scrollTop=T1),b.current.lockDirection=void 0},[_,j]);let d1=lt.useCallback(()=>{var W1,Bt,T1,X1;let Y=C.current;if(Y===null)return;let N=Y.scrollTop,s1=Y.scrollLeft,x1=b.current.scrollTop,f1=b.current.scrollLeft,U=s1-f1,v1=N-x1;_&&U!==0&&v1!==0&&(Math.abs(U)>3||Math.abs(v1)>3)&&d&&b.current.lockDirection===void 0&&(b.current.lockDirection=Math.abs(U)0&&(Math.abs(C1)>2e3||I===0||I===D1)&&o>Y.scrollHeight+5){let et=I/D1,B1=(o-Y.clientHeight)*et;L.current=B1-I}D!==void 0&&(window.clearTimeout(Z.current),n1(!1),Z.current=window.setTimeout(()=>n1(!0),200)),c({x:s1,y:I+L.current,width:Y.clientWidth-p,height:Y.clientHeight-u,paddingRight:(X1=(T1=F.current)==null?void 0:T1.clientWidth)!=null?X1:0})},[u,p,o,c,d,_]),O=lt.useRef(d1);O.current=d1;let a1=lt.useRef(),W=lt.useRef(!1);lt.useEffect(()=>{W.current?d1():W.current=!0},[d1,u,p]);let L1=lt.useCallback(W1=>{C.current=W1,s!==void 0&&(s.current=W1)},[s]),p1=0,o1=0;for(x.push(lt.createElement("div",{key:p1++,style:{width:h,height:0}}));o1O.current(),0),a1.current={width:P1,height:K1}),(P1??0)===0||(K1??0)===0?lt.createElement("div",{ref:H1}):lt.createElement("div",{ref:H1},lt.createElement(rE,{isSafari:Tz.value},H,lt.createElement("div",{className:"dvn-underlay"},i),lt.createElement("div",{ref:L1,style:a1.current,draggable:v,onDragStart:W1=>{v||(W1.stopPropagation(),W1.preventDefault())},className:"dvn-scroller "+(g??""),onScroll:d1},lt.createElement("div",{className:"dvn-scroll-inner"+(z===void 0?" hidden":"")},lt.createElement("div",{className:"dvn-stack"},x),z!==void 0&<.createElement(lt.Fragment,null,!R&<.createElement("div",{className:"dvn-spacer"}),lt.createElement("div",{ref:F,onMouseDown:C8,onMouseUp:C8,onMouseMove:C8,style:{height:K1,maxHeight:l-Math.ceil(k%1),position:"sticky",top:0,paddingLeft:1,marginBottom:-40,marginRight:p,flexGrow:R?1:void 0,right:y?p??0:void 0,pointerEvents:"auto"}},z))))))},lE=L0("div")({name:"MinimapStyle",class:"m15w2ly5"}),oE=t=>{var a,e,r;let{columns:n,rows:i,rowHeight:l,headerHeight:o,groupHeaderHeight:h,enableGroups:c,freezeColumns:v,experimental:g,clientSize:d,className:u,onVisibleRegionChanged:p,scrollToEnd:z,scrollRef:w,preventDiagonalScrolling:s,rightElement:f,rightElementProps:m,overscrollX:H,overscrollY:x,showMinimap:y=!1,initialSize:R,smoothScrollX:L=!1,smoothScrollY:V=!1,isDraggable:C}=t,{paddingRight:k,paddingBottom:b}=g??{},[F,_]=d,j=d0.useRef(),n1=d0.useRef(),Z=d0.useRef(),d1=d0.useRef(),O=d0.useMemo(()=>{let f1=Math.max(0,H??0);for(let U of n)f1+=U.width;return f1},[n,H]),a1=c?o+h:o;if(typeof l=="number")a1+=i*l;else for(let f1=0;f1{var f1,U,v1;if(W.current===void 0)return;let D={...W.current},I=0,C1=D.x<0?-D.x:0,D1=0,et=0;D.x=D.x<0?0:D.x;let B1=0;for(let Q1=0;Q1=St+Q1.width)I+=Q1.width,et++,D1++;else if(D.x>St)I+=Q1.width,L?C1+=St-D.x:et++,D1++;else if(D.x+D.width>St)I+=Q1.width,D1++;else break}let c1=0,e1=0,u1=0;if(typeof l=="number")V?(e1=Math.floor(D.y/l),c1=e1*l-D.y):e1=Math.ceil(D.y/l),u1=Math.ceil(D.height/l)+e1,c1<0&&u1++;else{let Q1=0;for(let St=0;St=Q1+jt)Q1+=jt,e1++,u1++;else if(D.y>Ut)Q1+=jt,V?c1+=Ut-D.y:e1++,u1++;else if(D.y+D.height>jt/2+Q1)Q1+=jt,u1++;else break}}let M1={x:et,y:e1,width:D1-et,height:u1-e1},I1=j.current;(I1===void 0||I1.y!==M1.y||I1.x!==M1.x||I1.height!==M1.height||I1.width!==M1.width||n1.current!==C1||Z.current!==c1||D.width!==((f1=d1.current)==null?void 0:f1[0])||D.height!==((U=d1.current)==null?void 0:U[1]))&&(p?.({x:et,y:e1,width:D1-et,height:u1-e1},D.width,D.height,(v1=D.paddingRight)!=null?v1:0,C1,c1),j.current=M1,n1.current=C1,Z.current=c1,d1.current=[D.width,D.height])},[n,l,i,p,v,L,V]),p1=d0.useCallback(f1=>{W.current=f1,L1()},[L1]);d0.useEffect(()=>{L1()},[L1]);let o1=(a=w?.current)!=null?a:void 0,H1=(0,Pz.default)(O/a1,2/3,1.5),P1=200,K1=H1>1?P1:Math.ceil(P1*H1),W1=H1>1?Math.ceil(P1/H1):P1,Bt=K1/O,T1=W1/a1,X1=Math.min(F*Math.max(Bt,.01),K1),Y=Math.min(_*Math.max(T1,.01),W1),N=((e=o1?.scrollLeft)!=null?e:0)/(O-F)*(K1-X1),s1=((r=o1?.scrollTop)!=null?r:0)/(a1-_)*(W1-Y),x1=d0.useMemo(()=>{if(!y||X1===0||Y===0)return;let f1=U=>{if(o1===void 0)return;let v1=U.currentTarget.getBoundingClientRect(),D=U.clientX-v1.x-X1/2,I=U.clientY-v1.y-Y/2,C1=(O-o1.clientWidth)*(D/(K1-X1)),D1=(a1-o1.clientHeight)*(I/(W1-Y));o1.scrollTo({left:C1,top:D1,behavior:U.type==="mousemove"?"auto":"smooth"})};return d0.createElement(lE,{style:{width:K1,height:W1},"data-testid":"minimap-container",onMouseMove:U=>{U.buttons===1&&f1(U)},onClick:f1},d0.createElement("div",{className:"header"}),d0.createElement("div",{className:"locationMarker",onDragStart:U=>U.preventDefault(),style:{left:N,top:s1,width:X1,height:Y,borderRadius:Math.min(X1,Y*.2,9)}}))},[W1,a1,N,o1,y,s1,Y,X1,K1,O]);return d0.createElement(iE,{scrollRef:w,minimap:x1,className:u,preventDiagonalScrolling:s,draggable:C===!0||typeof C=="string",scrollWidth:O+(k??0),scrollHeight:a1+(b??0),clientHeight:_,rightElement:f,paddingBottom:b,paddingRight:k,rightElementProps:m,update:p1,initialSize:R,scrollToEnd:z},d0.createElement(tE,{eventTargetRef:w,width:F,height:_,accessibilityHeight:t.accessibilityHeight,canvasRef:t.canvasRef,cellXOffset:t.cellXOffset,cellYOffset:t.cellYOffset,columns:t.columns,disabledRows:t.disabledRows,enableGroups:t.enableGroups,fillHandle:t.fillHandle,firstColAccessible:t.firstColAccessible,fixedShadowX:t.fixedShadowX,fixedShadowY:t.fixedShadowY,freezeColumns:t.freezeColumns,getCellContent:t.getCellContent,getCellRenderer:t.getCellRenderer,getGroupDetails:t.getGroupDetails,getRowThemeOverride:t.getRowThemeOverride,groupHeaderHeight:t.groupHeaderHeight,headerHeight:t.headerHeight,highlightRegions:t.highlightRegions,imageWindowLoader:t.imageWindowLoader,isFilling:t.isFilling,isFocused:t.isFocused,lockColumns:t.lockColumns,maxColumnWidth:t.maxColumnWidth,minColumnWidth:t.minColumnWidth,onHeaderMenuClick:t.onHeaderMenuClick,onMouseMove:t.onMouseMove,prelightCells:t.prelightCells,rowHeight:t.rowHeight,rows:t.rows,selection:t.selection,theme:t.theme,trailingRowType:t.trailingRowType,translateX:t.translateX,translateY:t.translateY,verticalBorder:t.verticalBorder,drawCustomCell:t.drawCustomCell,drawFocusRing:t.drawFocusRing,drawHeader:t.drawHeader,experimental:t.experimental,gridRef:t.gridRef,headerIcons:t.headerIcons,isDraggable:t.isDraggable,onCanvasBlur:t.onCanvasBlur,onCanvasFocused:t.onCanvasFocused,onCellFocused:t.onCellFocused,onColumnMoved:t.onColumnMoved,onColumnResize:t.onColumnResize,onColumnResizeEnd:t.onColumnResizeEnd,onColumnResizeStart:t.onColumnResizeStart,onContextMenu:t.onContextMenu,onDragEnd:t.onDragEnd,onDragLeave:t.onDragLeave,onDragOverCell:t.onDragOverCell,onDragStart:t.onDragStart,onDrop:t.onDrop,onItemHovered:t.onItemHovered,onKeyDown:t.onKeyDown,onKeyUp:t.onKeyUp,onMouseDown:t.onMouseDown,onMouseUp:t.onMouseUp,onRowMoved:t.onRowMoved,smoothScrollX:t.smoothScrollX,smoothScrollY:t.smoothScrollY}))},hE=oE,cE=()=>t=>t.showSearch?0:400,vE=L0("div")({name:"SearchWrapper",class:"sxep88s",vars:{"sxep88s-0":[cE(),"px"]}}),gE=q1.createElement("svg",{className:"button-icon",viewBox:"0 0 512 512"},q1.createElement("path",{fill:"none",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"48",d:"M112 244l144-144 144 144M256 120v292"})),dE=q1.createElement("svg",{className:"button-icon",viewBox:"0 0 512 512"},q1.createElement("path",{fill:"none",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"48",d:"M112 268l144 144 144-144M256 392V100"})),sE=q1.createElement("svg",{className:"button-icon",viewBox:"0 0 512 512"},q1.createElement("path",{fill:"none",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"32",d:"M368 368L144 144M368 144L144 368"})),uE=10,fE=t=>{let{canvasRef:a,cellYOffset:e,rows:r,columns:n,searchInputRef:i,searchValue:l,searchResults:o,onSearchValueChange:h,getCellsForSelection:c,onSearchResultsChanged:v,showSearch:g=!1,onSearchClose:d}=t,[u]=q1.useState(()=>"search-box-"+Math.round(Math.random()*1e3)),[p,z]=q1.useState(""),w=l??p,s=q1.useCallback(O=>{z(O),h?.(O)},[h]),[f,m]=q1.useState(),H=q1.useRef(f);H.current=f,q1.useEffect(()=>{o!==void 0&&(o.length>0?m(O=>{var a1;return{rowsSearched:r,results:o.length,selectedIndex:(a1=O?.selectedIndex)!=null?a1:-1}}):m(void 0))},[r,o]);let x=q1.useRef(new AbortController),y=q1.useRef(),[R,L]=q1.useState([]),V=o??R,C=q1.useCallback(()=>{y.current!==void 0&&(window.cancelAnimationFrame(y.current),y.current=void 0,x.current.abort())},[]),k=q1.useRef(e);k.current=e;let b=q1.useCallback(O=>{let a1=new RegExp(O.replace(/([$()*+.?[\\\]^{|}-])/g,"\\$1"),"i"),W=k.current,L1=Math.min(10,r),p1=0;m(void 0),L([]);let o1=[],H1=async()=>{var P1,K1;if(c===void 0)return;let W1=performance.now(),Bt=r-p1,T1=c({x:0,y:W,width:n.length,height:Math.min(L1,Bt,r-W)},x.current.signal);typeof T1=="function"&&(T1=await T1());let X1=!1;for(let[U,v1]of T1.entries())for(let[D,I]of v1.entries()){let C1;switch(I.kind){case l1.Text:case l1.Number:C1=I.displayData;break;case l1.Uri:case l1.Markdown:C1=I.data;break;case l1.Boolean:C1=typeof I.data=="boolean"?I.data.toString():void 0;break;case l1.Image:case l1.Bubble:C1=I.data.join("\u{1F433}");break;case l1.Custom:C1=I.copyData;break}C1!==void 0&&a1.test(C1)&&(o1.push([D,U+W]),X1=!0)}let Y=performance.now();X1&&L([...o1]),p1+=T1.length,i2(p1<=r);let N=(K1=(P1=H.current)==null?void 0:P1.selectedIndex)!=null?K1:-1;m({results:o1.length,rowsSearched:p1,selectedIndex:N}),v?.(o1,N),W+L1>=r?W=0:W+=L1;let s1=Y-W1,x1=Math.max(s1,1),f1=uE/x1;L1=Math.ceil(L1*f1),p1{var O;d?.(),m(void 0),L([]),v?.([],-1),C(),(O=a?.current)==null||O.focus()},[C,a,d,v]),_=q1.useCallback(O=>{s(O.target.value),o===void 0&&(O.target.value===""?(m(void 0),L([]),C()):b(O.target.value))},[b,C,s,o]);q1.useEffect(()=>{g&&i.current!==null&&(s(""),i.current.focus({preventScroll:!0}))},[g,i,s]);let j=q1.useCallback(O=>{var a1;if((a1=O?.stopPropagation)==null||a1.call(O),f===void 0)return;let W=(f.selectedIndex+1)%f.results;m({...f,selectedIndex:W}),v?.(V,W)},[f,v,V]),n1=q1.useCallback(O=>{var a1;if((a1=O?.stopPropagation)==null||a1.call(O),f===void 0)return;let W=(f.selectedIndex-1)%f.results;W<0&&(W+=f.results),m({...f,selectedIndex:W}),v?.(V,W)},[v,V,f]),Z=q1.useCallback(O=>{(O.ctrlKey||O.metaKey)&&O.nativeEvent.code==="KeyF"||O.key==="Escape"?(F(),O.stopPropagation(),O.preventDefault()):O.key==="Enter"&&(O.shiftKey?n1():j())},[F,j,n1]);q1.useEffect(()=>()=>{C()},[C]);let d1=q1.useMemo(()=>{var O,a1,W;let L1;f!==void 0&&(L1=f.results>=1e3?"over 1000":`${f.results} result${f.results!==1?"s":""}`,f.selectedIndex>=0&&(L1=`${f.selectedIndex+1} of ${L1}`));let p1=P1=>{P1.stopPropagation()},H1={width:`${Math.floor(((O=f?.rowsSearched)!=null?O:0)/r*100)}%`};return q1.createElement(vE,{showSearch:g,onMouseDown:p1,onMouseMove:p1,onMouseUp:p1,onClick:p1},q1.createElement("div",{className:"search-bar-inner"},q1.createElement("input",{id:u,"aria-hidden":!g,"data-testid":"search-input",ref:i,onChange:_,value:w,tabIndex:g?void 0:-1,onKeyDownCapture:Z}),q1.createElement("button",{"aria-label":"Previous Result","aria-hidden":!g,tabIndex:g?void 0:-1,onClick:n1,disabled:((a1=f?.results)!=null?a1:0)===0},gE),q1.createElement("button",{"aria-label":"Next Result","aria-hidden":!g,tabIndex:g?void 0:-1,onClick:j,disabled:((W=f?.results)!=null?W:0)===0},dE),d!==void 0&&q1.createElement("button",{"aria-label":"Close Search","aria-hidden":!g,"data-testid":"search-close-button",tabIndex:g?void 0:-1,onClick:F},sE)),f!==void 0?q1.createElement(q1.Fragment,null,q1.createElement("div",{className:"search-status"},q1.createElement("div",{"data-testid":"search-result-area"},L1)),q1.createElement("div",{className:"search-progress",style:H1})):q1.createElement("div",{className:"search-status"},q1.createElement("label",{htmlFor:u},"Type to search")))},[F,j,n1,_,d,Z,r,f,w,g,u,i]);return q1.createElement(q1.Fragment,null,q1.createElement(hE,{prelightCells:V,accessibilityHeight:t.accessibilityHeight,canvasRef:t.canvasRef,cellXOffset:t.cellXOffset,cellYOffset:t.cellYOffset,className:t.className,clientSize:t.clientSize,columns:t.columns,disabledRows:t.disabledRows,enableGroups:t.enableGroups,fillHandle:t.fillHandle,firstColAccessible:t.firstColAccessible,fixedShadowX:t.fixedShadowX,fixedShadowY:t.fixedShadowY,freezeColumns:t.freezeColumns,getCellContent:t.getCellContent,getCellRenderer:t.getCellRenderer,getGroupDetails:t.getGroupDetails,getRowThemeOverride:t.getRowThemeOverride,groupHeaderHeight:t.groupHeaderHeight,headerHeight:t.headerHeight,highlightRegions:t.highlightRegions,imageWindowLoader:t.imageWindowLoader,initialSize:t.initialSize,isFilling:t.isFilling,isFocused:t.isFocused,lockColumns:t.lockColumns,maxColumnWidth:t.maxColumnWidth,minColumnWidth:t.minColumnWidth,onHeaderMenuClick:t.onHeaderMenuClick,onMouseMove:t.onMouseMove,onVisibleRegionChanged:t.onVisibleRegionChanged,overscrollX:t.overscrollX,overscrollY:t.overscrollY,preventDiagonalScrolling:t.preventDiagonalScrolling,rightElement:t.rightElement,rightElementProps:t.rightElementProps,rowHeight:t.rowHeight,rows:t.rows,scrollRef:t.scrollRef,selection:t.selection,showMinimap:t.showMinimap,theme:t.theme,trailingRowType:t.trailingRowType,translateX:t.translateX,translateY:t.translateY,verticalBorder:t.verticalBorder,drawCustomCell:t.drawCustomCell,drawFocusRing:t.drawFocusRing,drawHeader:t.drawHeader,experimental:t.experimental,gridRef:t.gridRef,headerIcons:t.headerIcons,isDraggable:t.isDraggable,onCanvasBlur:t.onCanvasBlur,onCanvasFocused:t.onCanvasFocused,onCellFocused:t.onCellFocused,onColumnMoved:t.onColumnMoved,onColumnResize:t.onColumnResize,onColumnResizeEnd:t.onColumnResizeEnd,onColumnResizeStart:t.onColumnResizeStart,onContextMenu:t.onContextMenu,onDragEnd:t.onDragEnd,onDragLeave:t.onDragLeave,onDragOverCell:t.onDragOverCell,onDragStart:t.onDragStart,onDrop:t.onDrop,onItemHovered:t.onItemHovered,onKeyDown:t.onKeyDown,onKeyUp:t.onKeyUp,onMouseDown:t.onMouseDown,onMouseUp:t.onMouseUp,onRowMoved:t.onRowMoved,smoothScrollX:t.smoothScrollX,smoothScrollY:t.smoothScrollY,scrollToEnd:t.scrollToEnd}),d1)},pE=fE,zE=()=>t=>Math.max(16,t.targetHeight-10),mE=L0("input")({name:"RenameInput",class:"r1kzy40b",vars:{"r1kzy40b-0":[zE(),"px"]}}),ME=t=>{let{bounds:a,group:e,onClose:r,canvasBounds:n,onFinish:i}=t,[l,o]=_5.default.useState(e);return _5.default.createElement(rz,{style:{position:"absolute",left:a.x-n.left+1,top:a.y-n.top,width:a.width-2,height:a.height},className:"c1sqdbw3",onClickOutside:r},_5.default.createElement(mE,{targetHeight:a.height,"data-testid":"group-rename-input",value:l,onBlur:r,onFocus:h=>h.target.setSelectionRange(0,l.length),onChange:h=>o(h.target.value),onKeyDown:h=>{h.key==="Enter"?i(l):h.key==="Escape"&&r()},autoFocus:!0}))},E8=150;function HE(t,a,e,r){var n,i;let l=r(a);return(i=(n=l?.measure)==null?void 0:n.call(l,t,a,e))!=null?i:E8}function Iz(t,a,e,r,n,i,l,o,h){let c=[];if(n!==void 0&&c.push(...n.map(d=>d[r]).map(d=>HE(t,d,a,h))),c.length>5&&o){let d=c.reduce((u,p)=>u+p)/c.length;c=c.filter(u=>u{if(typeof window>"u")return[null,null];let f=document.createElement("canvas");return f.style.display="none",f.style.opacity="0",f.style.position="fixed",[f,f.getContext("2d",{alpha:!1})]},[]);l2.useLayoutEffect(()=>(d&&document.documentElement.append(d),()=>{d?.remove()}),[d]);let p=l2.useRef({}),z=l2.useRef(),[w,s]=l2.useState();return l2.useLayoutEffect(()=>{let f=v.current;if(f===void 0||t.every(B5))return;let m=Math.max(1,10-Math.floor(t.length/1e4)),H=0;m1&&(m--,H=1);let x={x:0,y:0,width:t.length,height:Math.min(c.current,m)},y={x:0,y:c.current-1,width:t.length,height:1};(async()=>{let L=f(x,h.signal),V=H>0?f(y,h.signal):void 0,C;typeof L=="object"?C=L:C=await bp(L),V!==void 0&&(typeof V=="object"?C=[...C,...V]:C=[...C,...await bp(V)]),z.current=t,s(C)})()},[h.signal,t]),l2.useMemo(()=>{var f;let H=(()=>t.every(B5)?t:u===null?t.map(L=>B5(L)?L:{...L,width:E8}):(u.font=`${g.current.baseFontStyle} ${g.current.fontFamily}`,t.map((L,V)=>{if(B5(L))return L;if(p.current[L.id]!==void 0)return{...L,width:p.current[L.id]};if(w===void 0||z.current!==t||L.id===void 0)return{...L,width:E8};let C=Iz(u,l,L,V,w,n,i,!0,o);return p.current[L.id]=C.width,C})))(),x=0,y=0,R=[];for(let[L,V]of H.entries())x+=V.width,V.grow!==void 0&&V.grow>0&&(y+=V.grow,R.push(L));if(x0){let L=[...H],V=r-x,C=V;for(let k=0;k1&&t.startsWith("_")){if(Number.parseInt(t.slice(1))!==a.keyCode)return!1}else if(t!==a.key)return!1;return!0}function T0(t,a){if(t.length===0)return!1;let e=!1,r=!1,n=!1,i=!1,l=t.split("+"),o=l.pop();if(!wE(o,a))return!1;for(let h of l)switch(h){case"ctrl":e=!0;break;case"shift":r=!0;break;case"alt":n=!0;break;case"meta":i=!0;break;case"primary":E5.value?i=!0:e=!0;break}return a.altKey===n&&a.ctrlKey===e&&a.shiftKey===r&&a.metaKey===i}function LE(t,a,e,r,n,i){let l=T5.default.useCallback((c,v,g,d)=>{var u,p;(i==="cell"||i==="multi-cell")&&c!==void 0&&(c={...c,range:{x:c.cell[0],y:c.cell[1],width:1,height:1}});let z=e==="mixed"&&(g||d==="drag"),w=r==="mixed"&&z,s=n==="mixed"&&z,f={current:c===void 0?void 0:{...c,rangeStack:d==="drag"?(p=(u=t.current)==null?void 0:u.rangeStack)!=null?p:[]:[]},columns:w?t.columns:mt.empty(),rows:s?t.rows:mt.empty()};g&&(i==="multi-rect"||i==="multi-cell")&&f.current!==void 0&&t.current!==void 0&&(f={...f,current:{...f.current,rangeStack:[...t.current.rangeStack,t.current.range]}}),a(f,v)},[r,t,e,i,n,a]),o=T5.default.useCallback((c,v,g)=>{c=c??t.rows,v!==void 0&&(c=c.add(v));let d;if(n==="exclusive"&&c.length>0)d={current:void 0,columns:mt.empty(),rows:c};else{let u=g&&e==="mixed",p=g&&r==="mixed";d={current:u?t.current:void 0,columns:p?t.columns:mt.empty(),rows:c}}a(d,!1)},[r,t,e,n,a]),h=T5.default.useCallback((c,v,g)=>{c=c??t.columns,v!==void 0&&(c=c.add(v));let d;if(r==="exclusive"&&c.length>0)d={current:void 0,rows:mt.empty(),columns:c};else{let u=g&&e==="mixed",p=g&&n==="mixed";d={current:u?t.current:void 0,rows:p?t.rows:mt.empty(),columns:c}}a(d,!1)},[r,t,e,n,a]);return[l,o,h]}function VE(t,a,e,r,n){let i=_8.useCallback(c=>{var v;if(t===!0){let g=[];for(let d=c.y;d=n?u.push({kind:l1.Loading,allowOverlay:!1}):u.push(a([p,d]));g.push(u)}return g}return(v=t?.(c,r.signal))!=null?v:[]},[r.signal,a,t,n]),l=t!==void 0?i:void 0,o=_8.useCallback(c=>{if(l===void 0)return[];let v={...c,x:c.x-e};if(v.x<0){v.x=0,v.width--;let g=l(v,r.signal);return typeof g=="function"?async()=>(await g()).map(d=>[{kind:l1.Loading,allowOverlay:!1},...d]):g.map(d=>[{kind:l1.Loading,allowOverlay:!1},...d])}return l(v,r.signal)},[r.signal,l,e]);return[t!==void 0?o:void 0,l]}function RE(t,a,e,r,n){var i,l;let o=t;if(r==="allowPartial"||t.current===void 0)return t;if(a!==void 0){let h=!1;do{if(t?.current===void 0)break;let c=(i=t.current)==null?void 0:i.range,v=[];if(c.width>2){let u=a({x:c.x,y:c.y,width:1,height:c.height},n.signal);if(typeof u=="function")return o;v.push(...u);let p=a({x:c.x+c.width-1,y:c.y,width:1,height:c.height},n.signal);if(typeof p=="function")return o;v.push(...p)}else{let u=a({x:c.x,y:c.y,width:c.width,height:c.height},n.signal);if(typeof u=="function")return o;v.push(...u)}let g=c.x-e,d=c.x+c.width-1-e;for(let u of v)for(let p of u)p.span!==void 0&&(g=Math.min(p.span[0],g),d=Math.max(p.span[1],d));g===c.x-e&&d===c.x+c.width-1-e?h=!0:t={current:{cell:(l=t.current.cell)!=null?l:[0,0],range:{x:g+e,y:c.y,width:d-g+1,height:c.height},rangeStack:t.current.rangeStack},columns:t.columns,rows:t.rows}}while(!h)}return t}function Wp(t){return t.startsWith('"')&&t.endsWith('"')&&(t=t.slice(1,-1).replace(/""/g,'"')),t}function yE(t){var a;(function(o){o[o.None=0]="None",o[o.inString=1]="inString",o[o.inStringPostQuote=2]="inStringPostQuote"})(a||(a={}));let e=[],r=[],n=0,i=0;t=t.replace(/\r\n/g,` `);let l=0;for(let o of t){switch(i){case 0:o===" "||o===` `?(r.push(t.slice(n,l)),n=l+1,o===` `&&(e.push(r),r=[])):o==='"'&&(i=1);break;case 1:o==='"'&&(i=2);break;case 2:o==='"'?i=1:((o===" "||o===` -`)&&(r.push(_p(t.slice(n,l))),n=l+1,o===` -`&&(e.push(r),r=[])),i=0);break}l++}return n0;){let l=r.pop();if(l===void 0)break;l instanceof HTMLTableElement||l.nodeName==="TBODY"?r.push(...[...l.children].reverse()):l instanceof HTMLTableRowElement?(i!==void 0&&n.push(i),i=[],r.push(...[...l.children].reverse())):l instanceof HTMLTableCellElement&&i?.push((e=(a=l.innerText)!=null?a:l.textContent)!=null?e:"")}return i!==void 0&&n.push(i),n}function Je(t){return/[\t\n"]/.test(t)&&(t=`"${t.replace(/"/g,'""')}"`),t}var gE=t=>{switch(t){case!0:return"TRUE";case!1:return"FALSE";case F8:return"INDETERMINATE";case Qn:return"";default:dr(t)}};function Pp(t,a,e){var r,n,i,l;let o=(c,v,g)=>{var s,d;let p=a[v];if(c.span!==void 0&&c.span[0]!==p)return"";switch(c.kind){case t1.Text:case t1.Number:return Je(g?(d=(s=c.data)==null?void 0:s.toString())!=null?d:"":c.displayData);case t1.Markdown:case t1.RowID:case t1.Uri:return Je(c.data);case t1.Image:case t1.Bubble:return c.data.reduce((z,L)=>`${Je(z)},${Je(L)}`);case t1.Boolean:return gE(c.data);case t1.Loading:return g?"":"#LOADING";case t1.Protected:return g?"":"************";case t1.Drilldown:return c.data.map(z=>z.text).reduce((z,L)=>`${Je(z)},${Je(L)}`);case t1.Custom:return Je(c.copyData);default:dr(c)}},h=t.map(c=>c.map((v,g)=>o(v,g,!1)).join(" ")).join(` -`);if(((r=window.navigator.clipboard)==null?void 0:r.write)!==void 0||e!==void 0){let c=document.createElement("tbody");for(let v of t){let g=document.createElement("tr");for(let[s,d]of v.entries()){let p=document.createElement("td");if(d.kind===t1.Uri){let z=document.createElement("a");z.href=d.data,z.innerText=d.data,p.append(z)}else p.innerText=o(d,s,!0);g.append(p)}c.append(g)}if(((n=window.navigator.clipboard)==null?void 0:n.write)!==void 0)window.navigator.clipboard.write([new ClipboardItem({"text/plain":new Blob([h],{type:"text/plain"}),"text/html":new Blob([`${c.outerHTML}
`],{type:"text/html"})})]);else if(e!==void 0&&e?.clipboardData!==null)try{e.clipboardData.setData("text/plain",h),e.clipboardData.setData("text/html",`${c.outerHTML}
`)}catch{(i=window.navigator.clipboard)==null||i.writeText(h)}}else(l=window.navigator.clipboard)==null||l.writeText(h);e?.preventDefault()}function Ip(t){return typeof t=="string"?t:`${t}px`}var dE=()=>t=>t.innerWidth,sE=()=>t=>t.innerHeight,uE=y0("div")({name:"Wrapper",class:"wzg2m5k",vars:{"wzg2m5k-0":[dE()],"wzg2m5k-1":[sE()]}}),fE=t=>{let{inWidth:a,inHeight:e,children:r,...n}=t;return Vz.createElement(uE,{innerHeight:Ip(e),innerWidth:Ip(a),...n},r)};function Rz(t){return t!==!0}var pE={getAccessibilityString:t=>{var a,e;return(e=(a=t.data)==null?void 0:a.toString())!=null?e:"false"},kind:t1.Boolean,needsHover:!0,useLabel:!1,needsHoverPosition:!0,measure:()=>50,draw:t=>bk(t,t.cell.data,L8(t.cell)),onDelete:t=>({...t,data:!1}),onClick:t=>{let{cell:a,posX:e,posY:r,bounds:n}=t;if(L8(a)&&Math.abs(e-n.width/2)<=n.height/3.4&&Math.abs(r-n.height/2)<=n.height/3.4)return{...a,data:Rz(a.data)}},onPaste:(t,a)=>{let e=Qn;return t.toLowerCase()==="true"?e=!0:t.toLowerCase()==="false"?e=!1:t.toLowerCase()==="indeterminate"&&(e=F8),e===a.data?void 0:{...a,data:e}}},zE=2,mE=1300;function ME(t,a){let e=S8.default.useRef(0),[r,n]=t??[0,0];S8.default.useEffect(()=>{if(r===0&&n===0){e.current=0;return}let i=0,l=h=>{var c;if(i===0)i=h;else{let v=h-i;e.current=Math.min(1,e.current+v/mE);let g=e.current**1.618*v*zE;(c=a.current)==null||c.scrollBy(r*g,n*g),i=h}o=window.requestAnimationFrame(l)},o=window.requestAnimationFrame(l);return()=>window.cancelAnimationFrame(o)},[a,r,n])}var HE=y0("div")({name:"BubblesOverlayEditorStyle",class:"b1bqsp5z"}),xE=t=>{let{bubbles:a}=t;return F5.createElement(HE,null,a.map((e,r)=>F5.createElement("div",{key:r,className:"boe-bubble"},e)),F5.createElement("textarea",{className:"gdg-input",autoFocus:!0}))},wE=xE,LE={getAccessibilityString:t=>{var a,e;return(e=(a=t.data)==null?void 0:a.toString())!=null?e:""},kind:t1.Bubble,needsHover:!1,useLabel:!1,needsHoverPosition:!1,measure:(t,a,e)=>a.data.reduce((r,n)=>t.measureText(n).width+r+20,0)+2*e.cellHorizontalPadding-4,draw:t=>Ek(t,t.cell.data),provideEditor:()=>t=>{let{value:a}=t;return yz.createElement(wE,{bubbles:a.data})},onPaste:()=>{}},VE=y0("div")({name:"DrilldownOverlayEditorStyle",class:"df2kt4a"}),RE=t=>{let{drilldowns:a}=t;return Yn.createElement(VE,null,a.map((e,r)=>Yn.createElement("div",{key:r,className:"doe-bubble"},e.img!==void 0&&Yn.createElement("img",{src:e.img}),Yn.createElement("div",null,e.text))))},yE=RE,CE={getAccessibilityString:t=>t.data.map(a=>a.text).join(", "),kind:t1.Drilldown,needsHover:!1,useLabel:!1,needsHoverPosition:!1,measure:(t,a,e)=>a.data.reduce((r,n)=>t.measureText(n.text).width+r+20+(n.img!==void 0?18:0),0)+2*e.cellHorizontalPadding-4,draw:t=>Tk(t,t.cell.data),provideEditor:()=>t=>{let{value:a}=t;return Cz.createElement(yE,{drilldowns:a.data})},onPaste:()=>{}},BE=y0("div")({name:"ImageOverlayEditorStyle",class:"i1eozt10"}),SE=t=>{let{urls:a,canWrite:e,onEditClick:r,renderImage:n}=t,i=a.filter(o=>o!=="");if(i.length===0)return null;let l=i.length>1;return a4.createElement(BE,{"data-testid":"GDG-default-image-overlay-editor"},a4.createElement(Sz.Carousel,{showArrows:l,showThumbs:!1,swipeable:l,emulateTouch:l,infiniteLoop:l},i.map(o=>{var h;let c=(h=n?.(o))!=null?h:a4.createElement("img",{draggable:!1,src:o});return a4.createElement("div",{className:"centering-container",key:o},c)})),e&&r&&a4.createElement("button",{className:"edit-icon",onClick:r},a4.createElement(b8,null)))},AE={getAccessibilityString:t=>t.data.join(", "),kind:t1.Image,needsHover:!1,useLabel:!1,needsHoverPosition:!1,draw:t=>{var a;return Pk(t,(a=t.cell.displayData)!=null?a:t.cell.data,t.cell.rounding)},measure:(t,a)=>a.data.length*50,onDelete:t=>({...t,data:[]}),provideEditor:()=>t=>{let{value:a,onFinishedEditing:e,imageEditorOverride:r}=t;return Bz.createElement(r??SE,{urls:a.data,canWrite:a.allowAdd,onCancel:e,onChange:i=>{e({...a,data:[i]})}})},onPaste:(t,a)=>{t=t.trim();let r=t.split(",").map(n=>{try{return new URL(n),n}catch{return}}).filter(n=>n!==void 0);if(!(r.length===a.data.length&&r.every((n,i)=>n===a.data[i])))return{...a,data:r}}},FE={getAccessibilityString:()=>"",kind:t1.Loading,needsHover:!1,useLabel:!1,needsHoverPosition:!1,measure:()=>120,draw:()=>{},onPaste:()=>{}},kE=y0("div")({name:"MarkdownContainer",class:"mlbeo71"}),bE=class extends A8.default.PureComponent{constructor(){super(...arguments),this.targetElement=null,this.containerRefHook=t=>{this.targetElement=t,this.renderMarkdownIntoDiv()}}renderMarkdownIntoDiv(){let{targetElement:t,props:a}=this;if(t===null)return;let{contents:e,createNode:r}=a,n=O1(e),i=document.createRange();i.selectNodeContents(t),i.deleteContents();let l=r?.(n);if(l===void 0){let h=document.createElement("template");h.innerHTML=n,l=h.content}t.append(l);let o=t.getElementsByTagName("a");for(let h of o)h.target="_blank",h.rel="noreferrer noopener"}render(){return this.renderMarkdownIntoDiv(),A8.default.createElement(kE,{ref:this.containerRefHook})}},EE=y0("textarea")({name:"InputBox",class:"ijuk0po"}),_E=y0("div")({name:"ShadowBox",class:"saq3p5l"}),TE=y0("div")({name:"GrowingEntryStyle",class:"gf8vzix"}),T5=t=>{let{placeholder:a,value:e,onKeyDown:r,highlight:n,altNewline:i,validatedSelection:l,...o}=t,{onChange:h,className:c}=o,v=E2.useRef(null),g=e??"";i2(h!==void 0,"GrowingEntry must be a controlled input area"),E2.useEffect(()=>{let d=v.current;if(d===null||d.disabled)return;let p=g.toString().length;d.focus(),d.setSelectionRange(n?0:p,p)},[]),E2.useLayoutEffect(()=>{var d;if(l!==void 0){let p=typeof l=="number"?[l,null]:l;(d=v.current)==null||d.setSelectionRange(p[0],p[1])}},[l]);let s=E2.useCallback(d=>{d.key==="Enter"&&d.shiftKey&&i===!0||r?.(d)},[i,r]);return E2.createElement(TE,{className:"gdg-growing-entry"},E2.createElement(_E,{className:c},g+` -`),E2.createElement(EE,{...o,className:(c??"")+" gdg-input",ref:v,onKeyDown:s,value:g,placeholder:a,dir:"auto"}))},PE=()=>t=>t.targetWidth,Op=y0("div")({name:"MarkdownOverlayEditorStyle",class:"mdwzdl1",vars:{"mdwzdl1-0":[PE(),"px"]}}),IE=t=>{let{markdown:a,onChange:e,forceEditMode:r,createNode:n,targetRect:i,readonly:l,onFinish:o,validatedSelection:h}=t,[c,v]=B0.useState(a===""||r),g=B0.useCallback(()=>{v(d=>!d)},[]),s=a?"ml-6":"";return c?B0.createElement(Op,{targetWidth:i.width-20},B0.createElement(T5,{autoFocus:!0,highlight:!1,validatedSelection:h,value:a,onKeyDown:d=>{d.key==="Enter"&&d.stopPropagation()},onChange:e}),B0.createElement("div",{className:`edit-icon checkmark-hover ${s}`,onClick:()=>o()},B0.createElement(gk,null))):B0.createElement(Op,{targetWidth:i.width},B0.createElement(bE,{contents:a,createNode:n}),!l&&B0.createElement(B0.Fragment,null,B0.createElement("div",{className:"spacer"}),B0.createElement("div",{className:`edit-icon edit-hover ${s}`,onClick:g},B0.createElement(b8,null))),B0.createElement("textarea",{className:"md-edit-textarea gdg-input",autoFocus:!0}))},OE={getAccessibilityString:t=>{var a,e;return(e=(a=t.data)==null?void 0:a.toString())!=null?e:""},kind:t1.Markdown,needsHover:!1,needsHoverPosition:!1,drawPrep:Jn,measure:(t,a,e)=>{let r=a.data.split(` -`)[0];return t.measureText(r).width+2*e.cellHorizontalPadding},draw:t=>ti(t,t.cell.data,t.cell.contentAlign),onDelete:t=>({...t,data:""}),provideEditor:()=>t=>{let{onChange:a,value:e,target:r,onFinishedEditing:n,markdownDivCreateNode:i,forceEditMode:l,validatedSelection:o}=t;return Az.createElement(IE,{onFinish:n,targetRect:r,readonly:e.readonly===!0,markdown:e.data,validatedSelection:o,onChange:h=>a({...e,data:h.target.value}),forceEditMode:l,createNode:i})},onPaste:(t,a)=>t===a.data?void 0:{...a,data:t}},DE={getAccessibilityString:t=>t.row.toString(),kind:l2.Marker,needsHover:!0,needsHoverPosition:!1,drawPrep:Sk,measure:()=>44,draw:t=>Fk(t,t.cell.row,t.cell.checked,t.cell.markerKind,t.cell.drawHandle),onClick:t=>{let{bounds:a,cell:e,posX:r,posY:n}=t,{width:i,height:l}=a,o=e.drawHandle?7+(i-7)/2:i/2,h=l/2;if(Math.abs(r-o)<=10&&Math.abs(n-h)<=10)return{...e,checked:!e.checked}},onPaste:()=>{}},NE={getAccessibilityString:()=>"",kind:l2.NewRow,needsHover:!0,needsHoverPosition:!1,measure:()=>200,draw:t=>Bk(t,t.cell.hint,t.cell.icon),onPaste:()=>{}},$E=n4.lazy(async()=>await Promise.resolve().then(()=>(xp(),Hp))),UE={getAccessibilityString:t=>{var a,e;return(e=(a=t.data)==null?void 0:a.toString())!=null?e:""},kind:t1.Number,needsHover:!1,needsHoverPosition:!1,useLabel:!0,drawPrep:Jn,draw:t=>ti(t,t.cell.displayData,t.cell.contentAlign),measure:(t,a)=>t.measureText(a.displayData).width+16,onDelete:t=>({...t,data:void 0}),provideEditor:()=>t=>{let{isHighlighted:a,onChange:e,value:r,validatedSelection:n}=t;return n4.createElement(n4.Suspense,{fallback:null},n4.createElement($E,{highlight:a,disabled:r.readonly===!0,value:r.data,validatedSelection:n,onChange:i=>{var l;return e({...r,data:Number.isNaN((l=i.floatValue)!=null?l:0)?0:i.floatValue})}}))},onPaste:(t,a)=>{let e=Number.parseFloat(t);if(!(Number.isNaN(e)||a.data===e))return{...a,data:e}}},WE={getAccessibilityString:()=>"",measure:()=>108,kind:t1.Protected,needsHover:!1,needsHoverPosition:!1,draw:kk,onPaste:()=>{}},jE={getAccessibilityString:t=>{var a,e;return(e=(a=t.data)==null?void 0:a.toString())!=null?e:""},kind:t1.RowID,needsHover:!1,needsHoverPosition:!1,drawPrep:(t,a)=>Jn(t,a,t.theme.textLight),draw:t=>ti(t,t.cell.data,t.cell.contentAlign),measure:(t,a)=>t.measureText(a.data).width+16,provideEditor:()=>t=>{let{isHighlighted:a,onChange:e,value:r,validatedSelection:n}=t;return Fz.default.createElement(T5,{highlight:a,autoFocus:r.readonly!==!0,disabled:r.readonly!==!1,value:r.data,validatedSelection:n,onChange:i=>e({...r,data:i.target.value})})},onPaste:()=>{}},qE={getAccessibilityString:t=>{var a,e;return(e=(a=t.data)==null?void 0:a.toString())!=null?e:""},kind:t1.Text,needsHover:!1,needsHoverPosition:!1,drawPrep:Jn,useLabel:!0,draw:t=>(ti(t,t.cell.displayData,t.cell.contentAlign,t.cell.allowWrapping,t.hyperWrapping),!0),measure:(t,a,e)=>{let r=a.displayData.split(` -`).slice(0,a.allowWrapping===!0?void 0:1);return Math.max(...r.map(n=>t.measureText(n).width+2*e.cellHorizontalPadding))},onDelete:t=>({...t,data:""}),provideEditor:()=>t=>{let{isHighlighted:a,onChange:e,value:r,validatedSelection:n}=t;return kz.createElement(T5,{highlight:a,autoFocus:r.readonly!==!0,disabled:r.readonly===!0,altNewline:!0,value:r.data,validatedSelection:n,onChange:i=>e({...r,data:i.target.value})})},onPaste:(t,a)=>t===a.data?void 0:{...a,data:t}},GE=y0("div")({name:"UriOverlayEditorStyle",class:"uf0sjo8"}),KE=t=>{let{uri:a,onChange:e,forceEditMode:r,readonly:n,validatedSelection:i}=t,[l,o]=Q2.useState(a===""||r),h=Q2.useCallback(()=>{o(!0)},[]);return l?Q2.createElement(T5,{validatedSelection:i,highlight:!0,autoFocus:!0,value:a,onChange:e}):Q2.createElement(GE,null,Q2.createElement("a",{className:"link-area",href:a,target:"_blank",rel:"noopener noreferrer"},a),!n&&Q2.createElement("div",{className:"edit-icon",onClick:h},Q2.createElement(b8,null)),Q2.createElement("textarea",{className:"gdg-input",autoFocus:!0}))},XE=KE,YE={getAccessibilityString:t=>{var a,e;return(e=(a=t.data)==null?void 0:a.toString())!=null?e:""},kind:t1.Uri,needsHover:!1,needsHoverPosition:!1,useLabel:!0,drawPrep:Jn,draw:t=>ti(t,t.cell.data,t.cell.contentAlign),measure:(t,a)=>t.measureText(a.data).width+16,onDelete:t=>({...t,data:""}),provideEditor:()=>t=>{let{onChange:a,value:e,forceEditMode:r,validatedSelection:n}=t;return bz.createElement(XE,{forceEditMode:r,uri:e.data,validatedSelection:n,readonly:e.readonly===!0,onChange:i=>a({...e,data:i.target.value})})},onPaste:(t,a)=>t===a.data?void 0:{...a,data:t}},QE={[l2.Marker]:DE,[l2.NewRow]:NE,[t1.Boolean]:pE,[t1.Bubble]:LE,[t1.Drilldown]:CE,[t1.Image]:AE,[t1.Loading]:FE,[t1.Markdown]:OE,[t1.Number]:UE,[t1.Protected]:WE,[t1.RowID]:jE,[t1.Text]:qE,[t1.Uri]:YE},ZE=0;function JE(t){return(0,Up.default)((0,w8.default)((0,w8.default)(t).filter(a=>a.span!==void 0).map(a=>{var e,r,n,i;return(0,e4.default)(((r=(e=a.span)==null?void 0:e[0])!=null?r:0)+1,((i=(n=a.span)==null?void 0:n[1])!=null?i:0)+1)})))}function R5(t,a){return t===void 0||a===0||t.columns.length===0&&t.current===void 0?t:{current:t.current===void 0?void 0:{cell:[t.current.cell[0]+a,t.current.cell[1]],range:{...t.current.range,x:t.current.range.x+a},rangeStack:t.current.rangeStack.map(e=>({...e,x:e.x+a}))},rows:t.rows,columns:t.columns.offset(a)}}var Dp={selectAll:!0,selectRow:!0,selectColumn:!0,downFill:!1,rightFill:!1,pageUp:!1,pageDown:!1,clear:!0,copy:!0,paste:!0,search:!1,first:!0,last:!0},Np={kind:t1.Loading,allowOverlay:!1},x8={columns:pt.empty(),rows:pt.empty(),current:void 0},t_=(t,a)=>{var e,r,n,i,l;let[o,h]=D.useState(x8),[c,v]=D.useState(),g=D.useRef(null),s=D.useRef(null),[d,p]=D.useState(),z=D.useRef(null),L=D.useRef(),{rowMarkers:u="none",rowMarkerWidth:f,imageEditorOverride:m,getRowThemeOverride:M,markdownDivCreateNode:x,width:y,height:w,columns:V,rows:R,getCellContent:S,onCellClicked:b,onCellActivated:E,onFinishedEditing:C,coercePasteValue:T,drawHeader:I,onHeaderClicked:J,spanRangeBehavior:W="default",onGroupHeaderClicked:n1,onCellContextMenu:i1,className:g1,onHeaderContextMenu:l1,getCellsForSelection:H1,onGroupHeaderContextMenu:f1,onGroupHeaderRenamed:d1,onCellEdited:K1,onCellsEdited:X1,onKeyDown:j1,onKeyUp:P1,keybindings:ct,onRowAppended:b1,onColumnMoved:Q1,validateCell:j,highlightRegions:N,drawCell:u1,rangeSelect:o1="rect",columnSelect:O="multi",rowSelect:Q="multi",rangeSelectionBlending:c1="exclusive",columnSelectionBlending:$="exclusive",rowSelectionBlending:s1="exclusive",onDelete:W1,onDragStart:k1,onMouseMove:tt,onPaste:C1,copyHeaders:Ut=!1,freezeColumns:q=0,rowSelectionMode:h1="auto",rowMarkerStartIndex:x1=1,rowMarkerTheme:z1,onHeaderMenuClick:F1,getGroupDetails:vt,onSearchClose:jt,onItemHovered:xt,onSelectionCleared:kt,showSearch:Y1,onVisibleRegionChanged:D1,gridSelection:Mt,onGridSelectionChange:bt,minColumnWidth:T0=50,maxColumnWidth:H2=500,maxColumnAutoWidth:Z0,provideEditor:qt,trailingRowOptions:yt,scrollOffsetX:lt,scrollOffsetY:zt,verticalBorder:Ct,onDragOverCell:_2,onDrop:s0,onColumnResize:H0,onColumnResizeEnd:o2,onColumnResizeStart:J0,customRenderers:h2,fillHandle:Ta,drawFocusRing:fa,experimental:e0,fixedShadowX:ta,fixedShadowY:Ve,headerIcons:u0,imageWindowLoader:r0,initialSize:P0,isDraggable:D5,onDragLeave:aa,onRowMoved:Pa,overscrollX:Ia,overscrollY:ea,preventDiagonalScrolling:Re,rightElement:l4,rightElementProps:o4,showMinimap:ye,smoothScrollX:pa,smoothScrollY:N5,scrollToEnd:ri,scaleToRem:ni=!1,rowHeight:h4=34,headerHeight:za=36,groupHeaderHeight:ma=za,theme:T2}=t,Oa=Math.max(T0,20),Ce=Math.max(H2,Oa),ii=Math.max(Z0??Ce,Oa),$5=D.useMemo(()=>typeof window>"u"?{fontSize:"16px"}:window.getComputedStyle(document.documentElement),[]).fontSize,c4=D.useMemo(()=>Number.parseFloat($5),[$5]),[x0,v4,g4,Be,Se,Hr]=D.useMemo(()=>{var H,A,k;if(!ni||c4===16)return[h4,za,ma,T2,Ia,ea];let _=c4/16,K=h4,X=Lp();return[typeof K=="number"?K*_:a1=>Math.ceil(K(a1)*_),Math.ceil(za*_),Math.ceil(ma*_),{...T2,headerIconSize:((H=T2?.headerIconSize)!=null?H:X.headerIconSize)*_,cellHorizontalPadding:((A=T2?.cellHorizontalPadding)!=null?A:X.cellHorizontalPadding)*_,cellVerticalPadding:((k=T2?.cellVerticalPadding)!=null?k:X.cellVerticalPadding)*_},Math.ceil((Ia??0)*_),Math.ceil((ea??0)*_)]},[ma,za,Ia,ea,c4,h4,ni,T2]),st=D.useMemo(()=>ct===void 0?Dp:{...Dp,...ct},[ct]),Da=f??(R>1e4?48:R>1e3?44:R>100?36:32),c2=u!=="none",P=c2?1:0,w0=b1!==void 0,v2=yt?.sticky===!0,[oi,xr]=D.useState(!1),U5=Y1??oi,W5=D.useCallback(()=>{jt!==void 0?jt():xr(!1)},[jt]),hi=D.useMemo(()=>Mt===void 0?void 0:R5(Mt,P),[Mt,P]),G=hi??o,x2=D.useRef(new AbortController);D.useEffect(()=>()=>{x2?.current.abort()},[]);let[L0,j5]=hE(H1,S,P,x2.current),q5=D.useCallback((H,A,k)=>{if(j===void 0)return!0;let _=[H[0]-P,H[1]];return j?.(_,A,k)},[P,j]),d4=D.useRef(Mt),ra=D.useCallback((H,A)=>{A&&(H=cE(H,L0,P,W,x2.current)),bt!==void 0?(d4.current=R5(H,-P),bt(d4.current)):h(H)},[bt,L0,P,W]),Na=qn(H0,D.useCallback((H,A,k,_)=>{H0?.(V[k-P],A,k-P,_)},[H0,P,V])),s4=qn(o2,D.useCallback((H,A,k,_)=>{o2?.(V[k-P],A,k-P,_)},[o2,P,V])),wr=qn(J0,D.useCallback((H,A,k,_)=>{J0?.(V[k-P],A,k-P,_)},[J0,P,V])),Lr=qn(I,D.useCallback(H=>{var A;return(A=I?.({...H,columnIndex:H.columnIndex-P}))!=null?A:!1},[I,P])),Vr=D.useCallback(H=>{if(W1!==void 0){let A=W1(R5(H,-P));return typeof A=="boolean"?A:R5(A,P)}return!0},[W1,P]),[f0,o0,h0]=oE(G,ra,c1,$,s1,o1),A0=D.useMemo(()=>({...Lp(),...Be}),[Be]),[u4,G5]=D.useState([10,10,0]),F=D.useCallback(H=>H.kind!==t1.Custom?QE[H.kind]:h2?.find(A=>A.isMatch(H)),[h2]),U=iE(V,R,j5,u4[0]-(P===0?0:Da)-u4[2],Oa,ii,A0,F,x2.current),S1=D.useMemo(()=>U.some(H=>H.group!==void 0),[U]),m1=S1?v4+g4:v4,N1=G.rows.length,y1=u==="none"?"":N1===0?Jp:N1===R?Zp:GF,p1=D.useMemo(()=>u==="none"?U:[{title:y1,width:Da,icon:void 0,hasMenu:!1,style:"normal",themeOverride:z1},...U],[U,Da,u,y1,z1]),[At,$1]=D.useMemo(()=>[zt!==void 0&&typeof x0=="number"?Math.floor(zt/x0):0,zt!==void 0&&typeof x0=="number"?-(zt%x0):0],[zt,x0]),ut=D.useRef({height:1,width:1,x:0,y:0}),I0=D.useMemo(()=>{var H,A;return{x:ut.current.x,y:At,width:(H=ut.current.width)!=null?H:1,height:(A=ut.current.height)!=null?A:1,ty:$1}},[$1,At]),ot=D.useRef(!1),[wt,et,Ht]=zk(I0);ut.current=wt;let c0=((e=wt.height)!=null?e:1)>1;D.useLayoutEffect(()=>{if(zt!==void 0&&z.current!==null&&c0){if(z.current.scrollTop===zt)return;z.current.scrollTop=zt,z.current.scrollTop!==zt&&Ht(),ot.current=!0}},[zt,c0,Ht]);let Ma=((r=wt.width)!=null?r:1)>1;D.useLayoutEffect(()=>{if(lt!==void 0&&z.current!==null&&Ma){if(z.current.scrollLeft===lt)return;z.current.scrollLeft=lt,z.current.scrollLeft!==lt&&Ht(),ot.current=!0}},[lt,Ma,Ht]);let Ha=wt.x+P,g2=wt.y,Et=D.useRef(null),Gt=D.useCallback(H=>{var A;H===!0?(A=Et.current)==null||A.focus():window.requestAnimationFrame(()=>{var k;(k=Et.current)==null||k.focus()})},[]),p0=w0?R+1:R,J1=D.useCallback(H=>{let A=P===0?H:H.map(_=>({..._,location:[_.location[0]-P,_.location[1]]})),k=X1?.(A);if(k!==!0)for(let _ of A)K1?.(_.location,_.value);return k},[K1,X1,P]),xa=D.useMemo(()=>{if(N!==void 0)return P===0?N:N.map(H=>{let A=p1.length-H.range.x-P;if(!(A<=0))return{color:H.color,range:{...H.range,x:H.range.x+P,width:Math.min(A,H.range.width)},style:H.style}}).filter(H=>H!==void 0)},[N,p1.length,P]),w2=D.useRef(p1);w2.current=p1;let n0=D.useCallback(([H,A])=>{var k,_,K,X,a1,e1,Y,M1,A1,I1;let q1=w0&&A===p0-1;if(H===0&&c2)return q1?Np:{kind:l2.Marker,allowOverlay:!1,checked:G?.rows.hasIndex(A)===!0,markerKind:u==="clickable-number"?"number":u,row:x1+A,drawHandle:Pa!==void 0};if(q1){let at=H===P&&(k=yt?.hint)!=null?k:"",_1=w2.current[H];if(((_=_1?.trailingRowOptions)==null?void 0:_.disabled)===!0)return Np;{let G1=(X=(K=_1?.trailingRowOptions)==null?void 0:K.hint)!=null?X:at,Lt=(e1=(a1=_1?.trailingRowOptions)==null?void 0:a1.addIcon)!=null?e1:yt?.addIcon;return{kind:l2.NewRow,hint:G1,allowOverlay:!1,icon:Lt}}}else{let w1=H-P;if(e0?.strict===!0){let _1=ut.current,G1=_1.x>w1||w1>_1.x+_1.width||_1.y>A||A>_1.y+_1.height,Lt=w1===((M1=(Y=_1.extras)==null?void 0:Y.selected)==null?void 0:M1[0])&&A===((A1=_1.extras)==null?void 0:A1.selected[1]),ft=((I1=_1.extras)==null?void 0:I1.freezeRegion)===void 0||_1.extras.freezeRegion.x>w1||w1>_1.extras.freezeRegion.x+_1.extras.freezeRegion.width||_1.extras.freezeRegion.y>A||A>_1.extras.freezeRegion.y+_1.extras.freezeRegion.height;if(G1&&!Lt&&ft)return{kind:t1.Loading,allowOverlay:!1}}let at=S([w1,A]);return P!==0&&at.span!==void 0&&(at={...at,span:[at.span[0]+P,at.span[1]+P]}),at}},[w0,p0,c2,G?.rows,Pa,u,P,yt?.hint,yt?.addIcon,e0?.strict,S,x1]),K5=D.useCallback(H=>{var A,k;let _=(A=vt?.(H))!=null?A:{name:H};return d1!==void 0&&H!==""&&(_={icon:_.icon,name:_.name,overrideTheme:_.overrideTheme,actions:[...(k=_.actions)!=null?k:[],{title:"Rename",icon:"renameIcon",onClick:K=>Y5({group:_.name,bounds:K.bounds})}]}),_},[vt,d1]),ci=D.useCallback(H=>{var A;let[k,_]=H.cell,K=p1[k],X=K?.group!==void 0?(A=K5(K.group))==null?void 0:A.overrideTheme:void 0,a1=K?.themeOverride,e1=M?.(_);v({...H,theme:{...A0,...X,...a1,...e1,...H.content.themeOverride}})},[M,p1,K5,A0]),Rr=D.useCallback((H,A,k)=>{var _;if(G.current===void 0)return;let[K,X]=G.current.cell,a1=n0([K,X]);if(a1.kind!==t1.Boolean&&a1.allowOverlay){let e1=a1;if(k!==void 0)switch(e1.kind){case t1.Number:{let Y=jF(()=>k==="-"?-0:Number.parseFloat(k),0);e1={...e1,data:Number.isNaN(Y)?0:Y};break}case t1.Text:case t1.Markdown:case t1.Uri:e1={...e1,data:k};break}ci({target:H,content:e1,initialValue:k,cell:[K,X],highlight:k===void 0,forceEditMode:k!==void 0})}else a1.kind===t1.Boolean&&A&&a1.readonly!==!0&&(J1([{location:G.current.cell,value:{...a1,data:Rz(a1.data)}}]),(_=Et.current)==null||_.damage([{cell:G.current.cell}]))},[n0,G,J1,ci]),q8=D.useCallback((H,A)=>{var k;let _=(k=Et.current)==null?void 0:k.getBounds(H,A);if(_===void 0||z.current===null)return;let K=n0([H,A]);!K.allowOverlay||ci({target:_,content:K,initialValue:void 0,highlight:!0,cell:[H,A],forceEditMode:!0})},[n0,ci]),Kt=D.useCallback((H,A,k="both",_=0,K=0,X=void 0)=>{var a1;if(z.current!==null){let e1=Et.current,Y=s.current,M1=typeof H!="number"?H.unit==="cell"?H.amount:void 0:H,A1=typeof A!="number"?A.unit==="cell"?A.amount:void 0:A,I1=typeof H!="number"&&H.unit==="px"?H.amount:void 0,q1=typeof A!="number"&&A.unit==="px"?A.amount:void 0;if(e1!==null&&Y!==null){let L1={x:0,y:0,width:0,height:0},w1=0,at=0;if((M1!==void 0||A1!==void 0)&&(L1=(a1=e1.getBounds((M1??0)+P,A1??0))!=null?a1:L1,L1.width===0||L1.height===0))return;let _1=Y.getBoundingClientRect();if(I1!==void 0&&(L1={...L1,x:I1-_1.left-z.current.scrollLeft,width:1}),q1!==void 0&&(L1={...L1,y:q1+_1.top-z.current.scrollTop,height:1}),L1!==void 0){let G1={x:L1.x-_,y:L1.y-K,width:L1.width+2*_,height:L1.height+2*K},Lt=0;for(let Fe=0;FeG1.x?w1=G1.x-gt:_tG1.y?at=G1.y-Jt:Bt{var A;let k=p1[H];if(((A=k?.trailingRowOptions)==null?void 0:A.disabled)===!0)return;let _=b1?.(),K,X=!0;_!==void 0&&(K=await _,K==="top"&&(X=!1),typeof K=="number"&&(X=!1));let a1=0,e1=()=>{if(X8.current<=R){a1<500&&window.setTimeout(e1,a1),a1=50+a1*2;return}let Y=typeof K=="number"?K:X?R:0;Kt(H-P,Y),f0({cell:[H,Y],range:{x:H,y:Y,width:1,height:1}},!1,!1,"edit");let M1=K8.current([H-P,Y]);M1.allowOverlay&&vr(M1)&&M1.readonly!==!0&&window.setTimeout(()=>{G8.current(H,Y)},0)};e1()},[p1,b1,P,R,Kt,f0]),vi=D.useCallback(H=>{var A,k,_;let K=(_=(k=(A=U[H])==null?void 0:A.trailingRowOptions)==null?void 0:k.targetColumn)!=null?_:yt?.targetColumn;if(typeof K=="number")return K+(c2?1:0);if(typeof K=="object"){let X=V.indexOf(K);if(X>=0)return X+(c2?1:0)}},[U,V,c2,yt?.targetColumn]),$a=D.useRef(),p4=D.useRef(),yr=D.useCallback((H,A)=>{var k;let[_,K]=A;return{...A0,...(k=p1[_])==null?void 0:k.themeOverride,...M?.(K),...H.themeOverride}},[M,p1,A0]),Cr=D.useCallback(H=>{var A,k,_,K;let X=B5.value?H.metaKey:H.ctrlKey,a1=X&&Q==="multi",e1=X&&O==="multi",[Y,M1]=H.location,A1=G.columns,I1=G.rows,[q1,L1]=(k=(A=G.current)==null?void 0:A.cell)!=null?k:[];if(H.kind==="cell"){if(p4.current=void 0,z4.current=[Y,M1],Y===0&&c2){if(w0===!0&&M1===R||u==="number"||Q==="none")return;let w1=n0(H.location);if(w1.kind!==l2.Marker)return;if(Pa!==void 0){let G1=F(w1);i2(G1?.kind===l2.Marker);let Lt=(_=G1?.onClick)==null?void 0:_.call(G1,{...H,cell:w1,posX:H.localEventX,posY:H.localEventY,bounds:H.bounds,theme:yr(w1,H.location),preventDefault:()=>{}});if(Lt===void 0||Lt.checked===w1.checked)return}v(void 0),Gt();let at=I1.hasIndex(M1),_1=$a.current;if(Q==="multi"&&(H.shiftKey||H.isLongTouch===!0)&&_1!==void 0&&I1.hasIndex(_1)){let G1=[Math.min(_1,M1),Math.max(_1,M1)+1];a1||h1==="multi"?o0(void 0,G1,!0):o0(pt.fromSingleSelection(G1),void 0,a1)}else a1||H.isTouch||h1==="multi"?at?o0(I1.remove(M1),void 0,!0):(o0(void 0,M1,!0),$a.current=M1):at&&I1.length===1?o0(pt.empty(),void 0,X):(o0(pt.fromSingleSelection(M1),void 0,X),$a.current=M1)}else if(Y>=P&&w0&&M1===R){let w1=vi(Y);f4(w1??Y)}else if(q1!==Y||L1!==M1){let w1=n0(H.location),at=F(w1);if(at?.onSelect!==void 0){let Lt=!1;if(at.onSelect({...H,cell:w1,posX:H.localEventX,posY:H.localEventY,bounds:H.bounds,preventDefault:()=>Lt=!0,theme:yr(w1,H.location)}),Lt)return}let _1=v2&&M1===R,G1=v2&&G!==void 0&&((K=G.current)==null?void 0:K.cell[1])===R;if((H.shiftKey||H.isLongTouch===!0)&&q1!==void 0&&L1!==void 0&&G.current!==void 0&&!G1){if(_1)return;let Lt=Math.min(Y,q1),ft=Math.max(Y,q1),gt=Math.min(M1,L1),_t=Math.max(M1,L1);f0({...G.current,range:{x:Lt,y:gt,width:ft-Lt+1,height:_t-gt+1}},!0,X,"click"),$a.current=void 0,Gt()}else f0({cell:[Y,M1],range:{x:Y,y:M1,width:1,height:1}},!0,X,"click"),$a.current=void 0,v(void 0),Gt()}}else if(H.kind==="header")if(z4.current=[Y,M1],v(void 0),c2&&Y===0)$a.current=void 0,p4.current=void 0,Q==="multi"&&(I1.length!==R?o0(pt.fromSingleSelection([0,R]),void 0,X):o0(pt.empty(),void 0,X),Gt());else{let w1=p4.current;if(O==="multi"&&(H.shiftKey||H.isLongTouch===!0)&&w1!==void 0&&A1.hasIndex(w1)){let at=[Math.min(w1,Y),Math.max(w1,Y)+1];e1?h0(void 0,at,X):h0(pt.fromSingleSelection(at),void 0,X)}else e1?(A1.hasIndex(Y)?h0(A1.remove(Y),void 0,X):h0(void 0,Y,X),p4.current=Y):O!=="none"&&(h0(pt.fromSingleSelection(Y),void 0,X),p4.current=Y);$a.current=void 0,Gt()}else H.kind===b2?z4.current=[Y,M1]:H.kind===b5&&(ra(x8,!1),v(void 0),Gt(),kt?.(),$a.current=void 0,p4.current=void 0)},[f4,O,Gt,F,vi,n0,G,c2,v2,kt,Pa,P,u,Q,h1,R,f0,ra,h0,o0,w0,yr]),z4=D.useRef(),Y8=D.useRef(wt),na=D.useRef(),hm=D.useCallback(H=>{var A,k;if(Br.current=!1,Y8.current=ut.current,H.button!==0){na.current=void 0;return}let _=performance.now(),K=_-((k=(A=na.current)==null?void 0:A.time)!=null?k:-1e3)<250;na.current={wasDoubleClick:K,time:_,location:H.location};let X=H.kind==="cell"&&H.isFillHandle;!X&&H.kind!=="cell"&&H.isEdge||(p({previousSelection:G,fillHandle:X}),z4.current=void 0,H.isTouch||Cr(H))},[G,Cr]),[X5,Y5]=D.useState(),Q8=D.useCallback(H=>{if(H.kind!==b2||O!=="multi")return;let A=B5.value?H.metaKey:H.ctrlKey,[k]=H.location,_=G.columns;if(k=P&&Zn(K.group,p1[e1].group);e1--)X--;for(let e1=k+1;e1{var A;if(G.current===void 0)return;let k=[],_=G.current.range;for(let K=0;K<_.width;K++){let X=K+_.x,a1=n0([X,H?_.y+_.height-1:_.y]);if(!(ze(a1)||!vr(a1)))for(let e1=1;e1<_.height;e1++){let Y=H?_.y+_.height-(e1+1):e1+_.y,M1=[X,Y];k.push({location:M1,value:{...a1}})}}J1(k),(A=Et.current)==null||A.damage(k.map(K=>({cell:K.location})))},[n0,G,J1]),Br=D.useRef(!1),Z8=D.useCallback(async H=>{var A;if(((A=na.current)==null?void 0:A.wasDoubleClick)===!0&&L0!==void 0&&Na!==void 0){let k=ut.current.y,_=ut.current.height,K=L0({x:H,y:k,width:1,height:Math.min(_,R-k)},x2.current.signal);typeof K!="object"&&(K=await K());let X=U[H-P],e1=document.createElement("canvas").getContext("2d",{alpha:!1});if(e1!==null){e1.font=`${A0.baseFontStyle} ${A0.fontFamily}`;let Y=Lz(e1,A0,X,0,K,Oa,Ce,!1,F);Na?.(X,Y.width,H,Y.width)}}},[U,L0,Ce,A0,Oa,Na,P,R,F]),[cm,J8]=D.useState(),vm=D.useCallback((H,A)=>{var k,_,K;let X=d;if(p(void 0),J8(void 0),A)return;if(X?.fillHandle===!0&&G.current!==void 0){gi(G.current.cell[1]!==G.current.range.y);return}let[a1,e1]=H.location,[Y,M1]=(k=z4.current)!=null?k:[],A1=()=>{Br.current=!0},I1=L1=>{var w1,at,_1;if((L1.isTouch||Y===a1&&M1===e1)&&b?.([a1-P,e1],{...L1,preventDefault:A1}),!Br.current){let G1=n0(H.location),Lt=F(G1);if(Lt!==void 0&&Lt.onClick!==void 0){let ft=Lt.onClick({...L1,cell:G1,posX:L1.localEventX,posY:L1.localEventY,bounds:L1.bounds,theme:yr(G1,H.location),preventDefault:A1});ft!==void 0&&!ze(ft)&&Ea(ft)&&(J1([{location:L1.location,value:ft}]),(w1=Et.current)==null||w1.damage([{cell:L1.location}]))}if(!Br.current&&((_1=(at=X?.previousSelection)==null?void 0:at.current)==null?void 0:_1.cell)!==void 0&&G.current!==void 0){let[ft,gt]=G.current.cell,[_t,Jt]=X.previousSelection.current.cell;if(a1===ft&&a1===_t&&e1===gt&&e1===Jt)return E?.([a1-P,e1]),Rr(L1.bounds,!1),!0}}return!1},q1=H.location[0]-P;if(H.isTouch){let L1=ut.current,w1=Y8.current;if(L1.x!==w1.x||L1.y!==w1.y)return;if(H.isLongTouch===!0){if(H.kind==="cell"&&((_=G?.current)==null?void 0:_.cell[0])===a1&&((K=G?.current)==null?void 0:K.cell[1])===e1){i1?.([q1,H.location[1]],{...H,preventDefault:A1});return}else if(H.kind==="header"&&G.columns.hasIndex(a1)){l1?.(q1,{...H,preventDefault:A1});return}else if(H.kind===b2){if(q1<0)return;f1?.(q1,{...H,preventDefault:A1});return}}H.kind==="cell"?I1(H)||Cr(H):H.kind===b2?n1?.(q1,{...H,preventDefault:A1}):(H.kind===t4&&J?.(q1,{...H,preventDefault:A1}),Cr(H));return}if(H.kind==="header"){if(q1<0)return;H.isEdge?Z8(a1):H.button===0&&a1===Y&&e1===M1&&J?.(q1,{...H,preventDefault:A1})}if(H.kind===b2){if(q1<0)return;H.button===0&&a1===Y&&e1===M1&&(n1?.(q1,{...H,preventDefault:A1}),Br.current||Q8(H))}H.kind==="cell"&&H.button===0&&I1(H),z4.current=void 0},[d,P,G,b,gi,n0,F,yr,J1,E,Rr,i1,l1,f1,Cr,n1,Z8,J,Q8]),gm=D.useCallback(H=>{let A={...H,location:[H.location[0]-P,H.location[1]]};tt?.(A),J8(k=>{var _,K;return H.scrollEdge[0]===k?.[0]&&H.scrollEdge[1]===k[1]?k:d===void 0||((K=(_=na.current)==null?void 0:_.location[0])!=null?K:0){F1?.(H-P,A)},[F1,P]),wa=(n=G?.current)==null?void 0:n.cell,sm=D.useCallback((H,A,k,_,K,X)=>{ot.current=!1;let a1=wa;a1!==void 0&&(a1=[a1[0]-P,a1[1]]);let e1={x:H.x-P,y:H.y,width:H.width,height:w0&&H.y+H.height>=R?H.height-1:H.height,tx:K,ty:X,extras:{selected:a1,freezeRegion:q===0?void 0:{x:0,y:H.y,width:q,height:H.height}}};G5([A,k,_]),et(e1),D1?.(e1,e1.tx,e1.ty,e1.extras)},[wa,P,w0,R,q,et,D1]),um=qn(Q1,D.useCallback((H,A)=>{Q1?.(H-P,A-P),O!=="none"&&h0(pt.fromSingleSelection(A),void 0,!0)},[O,Q1,P,h0])),Q5=D.useRef(!1),fm=D.useCallback(H=>{if(H.location[0]===0&&P>0){H.preventDefault();return}k1?.({...H,location:[H.location[0]-P,H.location[1]]}),H.defaultPrevented()||(Q5.current=!0),p(void 0)},[k1,P]),pm=D.useCallback(()=>{Q5.current=!1},[]),zm=D.useCallback(H=>{var A;if(d!==void 0&&((A=na.current)==null?void 0:A.location[0])===0&&H.location[0]===0&&P===1&&Q==="multi"&&d.previousSelection&&!d.previousSelection.rows.hasIndex(na.current.location[1])&&G.rows.hasIndex(na.current.location[1])){let k=Math.min(na.current.location[1],H.location[1]),_=Math.max(na.current.location[1],H.location[1])+1;o0(pt.fromSingleSelection([k,_]),void 0,!1)}if(d!==void 0&&G.current!==void 0&&!Q5.current&&(o1==="rect"||o1==="multi-rect")){let[k,_]=G.current.cell,[K,X]=H.location;if(X<0&&(X=ut.current.y),v2&&_===R)return;if(v2&&X===R)if(H.kind===b5)X--;else return;K=Math.max(K,P);let Y=K-k,M1=X-_,A1={x:Y>=0?k:K,y:M1>=0?_:X,width:Math.abs(Y)+1,height:Math.abs(M1)+1};f0({...G.current,range:A1},!0,!1,"drag")}xt?.({...H,location:[H.location[0]-P,H.location[1]]})},[d,P,Q,G,o1,xt,o0,v2,R,f0]),Ae=D.useCallback(H=>{if(G.current===void 0)return;let[A,k]=H,[_,K]=G.current.cell,X=G.current.range,a1=X.x,e1=X.x+X.width,Y=X.y,M1=X.y+X.height;if(k!==0)switch(k){case 2:{M1=R,Y=K,Kt(0,M1,"vertical");break}case-2:{Y=0,M1=K+1,Kt(0,Y,"vertical");break}case 1:{YK+1?(M1--,Kt(0,M1,"vertical")):(Y=Math.max(0,Y-1),Kt(0,Y,"vertical"));break}default:dr(k)}if(A!==0)if(A===2)e1=p1.length,a1=_,Kt(e1-1-P,0,"horizontal");else if(A===-2)a1=P,e1=_+1,Kt(a1-P,0,"horizontal");else{let A1=[];if(L0!==void 0){let I1=L0({x:a1,y:Y,width:e1-a1-P,height:M1-Y},x2.current.signal);typeof I1=="object"&&(A1=JE(I1))}if(A===1){let I1=!1;if(a1<_){if(A1.length>0){let q1=(0,e4.default)(a1+1,_+1).find(L1=>!A1.includes(L1-P));q1!==void 0&&(a1=q1,I1=!0)}else a1++,I1=!0;I1&&Kt(a1,0,"horizontal")}I1||(e1=Math.min(p1.length,e1+1),Kt(e1-1-P,0,"horizontal"))}else if(A===-1){let I1=!1;if(e1>_+1){if(A1.length>0){let q1=(0,e4.default)(e1-1,_,-1).find(L1=>!A1.includes(L1-P));q1!==void 0&&(e1=q1,I1=!0)}else e1--,I1=!0;I1&&Kt(e1-P,0,"horizontal")}I1||(a1=Math.max(P,a1-1),Kt(a1-P,0,"horizontal"))}else dr(A)}f0({cell:G.current.cell,range:{x:a1,y:Y,width:e1-a1,height:M1-Y}},!0,!1,"keyboard-select")},[L0,G,p1.length,P,R,Kt,f0]),Ua=D.useCallback((H,A,k,_)=>{let K=p0-(k?0:1);if(H=(0,Kn.default)(H,P,U.length-1+P),A=(0,Kn.default)(A,0,K),H===wa?.[0]&&A===wa?.[1])return!1;if(_&&G.current!==void 0){let X=[...G.current.rangeStack];(G.current.range.width>1||G.current.range.height>1)&&X.push(G.current.range),ra({...G,current:{cell:[H,A],range:{x:H,y:A,width:1,height:1},rangeStack:X}},!0)}else f0({cell:[H,A],range:{x:H,y:A,width:1,height:1}},!0,!1,"keyboard-nav");return L.current!==void 0&&L.current[0]===H&&L.current[1]===A&&(L.current=void 0),Kt(H-P,A),!0},[p0,P,U.length,wa,G,Kt,ra,f0]),mm=D.useCallback((H,A)=>{c?.cell!==void 0&&H!==void 0&&Ea(H)&&(J1([{location:c.cell,value:H}]),window.requestAnimationFrame(()=>{var K;(K=Et.current)==null||K.damage([{cell:c.cell}])})),Gt(!0),v(void 0);let[k,_]=A;if(G.current!==void 0&&(k!==0||_!==0)){let K=G.current.cell[1]===p0-1&&H!==void 0;Ua((0,Kn.default)(G.current.cell[0]+k,0,p1.length-1),(0,Kn.default)(G.current.cell[1]+_,0,p0-1),K,!1)}C?.(H,A)},[c?.cell,Gt,G,C,J1,p0,Ua,p1.length]),Z5=D.useMemo(()=>`gdg-overlay-${ZE++}`,[]),Sr=D.useCallback(H=>{(async()=>{var k,_,K,X,a1;let e1=!1;if(j1!==void 0&&j1({...H,cancel:()=>{e1=!0}}),e1)return;let Y=()=>{H.stopPropagation(),H.preventDefault()},M1=c!==void 0,{altKey:A1,shiftKey:I1,metaKey:q1,ctrlKey:L1,key:w1,bounds:at}=H,_1=B5.value,G1=_1?q1:L1,Lt=w1==="Delete"||_1&&w1==="Backspace",ft=ut.current,gt=G.columns,_t=G.rows;if(w1==="Escape"){M1?v(void 0):st.clear&&(ra(x8,!1),kt?.());return}else if(_0("primary+a",H)&&st.selectAll){if(!M1)ra({columns:pt.empty(),rows:pt.empty(),current:{cell:(_=(k=G.current)==null?void 0:k.cell)!=null?_:[P,0],range:{x:P,y:0,width:V.length,height:R},rangeStack:[]}},!1);else{let St=document.getElementById(Z5);if(St!==null){let z0=window.getSelection(),F0=document.createRange();F0.selectNodeContents(St),z0?.removeAllRanges(),z0?.addRange(F0)}}Y();return}else _0("primary+f",H)&&st.search&&(Y(),(K=g?.current)==null||K.focus({preventScroll:!0}),xr(!0));function Jt(St){var z0,F0,Ar;Gt();let ke=[];for(let ia=St.x;ia({cell:ia.location})))}if(Lt){let St=(X=Vr?.(G))!=null?X:!0;if(Y(),St!==!1){let z0=St===!0?G:St;if(z0.current!==void 0){Jt(z0.current.range);for(let F0 of z0.current.rangeStack)Jt(F0)}for(let F0 of z0.rows)Jt({x:P,y:F0,width:p1.length-P,height:1});for(let F0 of z0.columns)Jt({x:F0,y:0,width:1,height:R})}return}if(G.current===void 0)return;let[Bt,mt]=G.current.cell,j0=!1;if(st.selectColumn&&_0("ctrl+ ",H)&&O!=="none")gt.hasIndex(Bt)?h0(gt.remove(Bt),void 0,!0):O==="single"?h0(pt.fromSingleSelection(Bt),void 0,!0):h0(void 0,Bt,!0);else if(st.selectRow&&_0("shift+ ",H)&&Q!=="none")_t.hasIndex(mt)?o0(_t.remove(mt),void 0,!0):Q==="single"?o0(pt.fromSingleSelection(mt),void 0,!0):o0(void 0,mt,!0);else if((_0("Enter",H)||_0(" ",H)||_0("shift+Enter",H))&&at!==void 0)M1?(v(void 0),_0("Enter",H)?mt++:_0("shift+Enter",H)&&mt--):mt===R&&w0?window.setTimeout(()=>{let St=vi(Bt);f4(St??Bt)},0):(E?.([Bt-P,mt]),Rr(at,!0),Y());else if(st.downFill&&_0("primary+_68",H)&&G.current.range.height>1)gi(!1),Y();else if(st.rightFill&&_0("primary+_82",H)&&G.current.range.width>1){let St=[],z0=G.current.range;for(let F0=0;F0({cell:F0.location}))),Y()}else if(st.pageDown&&_0("PageDown",H))mt+=Math.max(1,ut.current.height-4),Y();else if(st.pageUp&&_0("PageUp",H))mt-=Math.max(1,ut.current.height-4),Y();else if(st.first&&_0("primary+Home",H))v(void 0),mt=0,Bt=0;else if(st.last&&_0("primary+End",H))v(void 0),mt=Number.MAX_SAFE_INTEGER,Bt=Number.MAX_SAFE_INTEGER;else if(st.first&&_0("primary+shift+Home",H))v(void 0),Ae([-2,-2]);else if(st.last&&_0("primary+shift+End",H))v(void 0),Ae([2,2]);else if(w1==="ArrowDown"){if(L1&&A1)return;v(void 0),I1&&(o1==="rect"||o1==="multi-rect")?Ae([0,G1&&!A1?2:1]):(A1&&!G1&&(j0=!0),G1&&!A1?mt=R-1:mt+=1)}else if(w1==="ArrowUp"||w1==="Home"){let St=w1==="Home"||G1;v(void 0),I1&&(o1==="rect"||o1==="multi-rect")?Ae([0,St&&!A1?-2:-1]):(A1&&!St&&(j0=!0),mt+=St&&!A1?Number.MIN_SAFE_INTEGER:-1)}else if(w1==="ArrowRight"||w1==="End"){let St=w1==="End"||G1;v(void 0),I1&&(o1==="rect"||o1==="multi-rect")?Ae([St&&!A1?2:1,0]):(A1&&!St&&(j0=!0),Bt+=St&&!A1?Number.MAX_SAFE_INTEGER:1)}else if(w1==="ArrowLeft")v(void 0),I1&&(o1==="rect"||o1==="multi-rect")?Ae([G1&&!A1?-2:-1,0]):(A1&&!G1&&(j0=!0),Bt+=G1&&!A1?Number.MIN_SAFE_INTEGER:-1);else if(w1==="Tab")v(void 0),I1?Bt--:Bt++;else if(!q1&&!L1&&G.current!==void 0&&w1.length===1&&/[ -~]/g.test(w1)&&at!==void 0&&vr(S([Bt-P,Math.max(0,mt-1)]))){if((!v2||mt!==R)&&(ft.y>mt||mt>ft.y+ft.height||ft.x>Bt||Bt>ft.x+ft.width))return;Rr(at,!0,w1),Y()}Ua(Bt,mt,!1,j0)&&Y()})()},[j1,c,G,st.selectAll,st.search,st.selectColumn,st.selectRow,st.downFill,st.rightFill,st.pageDown,st.pageUp,st.first,st.last,st.clear,O,Q,S,P,Ua,ra,kt,V.length,R,Z5,Gt,J1,qt,F,Vr,p1.length,h0,o0,w0,vi,f4,E,Rr,gi,n0,Ae,o1,v2]),Mm=D.useCallback((H,A)=>{let k=H.location[0]-P;if(H.kind==="header"&&l1?.(k,{...H,preventDefault:A}),H.kind===b2){if(k<0)return;f1?.(k,{...H,preventDefault:A})}if(H.kind==="cell"){let[_,K]=H.location;i1?.([k,K],{...H,preventDefault:A}),qF(G,H.location)||Ua(_,K,!1,!1)}},[G,i1,f1,l1,P,Ua]),J5=D.useCallback(async H=>{var A,k,_,K,X,a1,e1;if(!st.paste)return;function Y(L1,w1,at){var _1,G1;if(!ze(L1)&&vr(L1)&&L1.readonly!==!0){let Lt=T?.(at,L1);if(Lt!==void 0&&Ea(Lt))return Lt.kind!==L1.kind&&console.warn("Coercion should not change cell kind."),{location:w1,value:Lt};let ft=F(L1);if(ft===void 0)return;if(ft.kind===t1.Custom){i2(L1.kind===t1.Custom);let gt=(_1=ft.onPaste)==null?void 0:_1.call(ft,at,L1);return gt===void 0?void 0:{location:w1,value:{...L1,data:gt}}}else{let gt=(G1=ft.onPaste)==null?void 0:G1.call(ft,at,L1);return gt===void 0?void 0:(i2(gt.kind===L1.kind),{location:w1,value:gt})}}}let M1=G.columns,A1=G.rows,I1=((A=z.current)==null?void 0:A.contains(document.activeElement))===!0||((k=s.current)==null?void 0:k.contains(document.activeElement))===!0,q1=(_=G.current)==null?void 0:_.cell;if(q1===void 0&&M1.length===1&&(q1=[(K=M1.first())!=null?K:0,0]),q1===void 0&&A1.length===1&&(q1=[P,(X=A1.first())!=null?X:0]),I1&&q1!==void 0){let L1,w1,at="text/plain",_1="text/html";if(navigator.clipboard.read!==void 0){let gt=await navigator.clipboard.read();for(let _t of gt){if(_t.types.includes(_1)){let Bt=await(await _t.getType(_1)).text(),mt=document.createElement("html");mt.innerHTML=Bt;let j0=mt.querySelector("table");if(j0!==null){L1=Tp(j0);break}}_t.types.includes(at)&&(w1=await(await _t.getType(at)).text())}}else if(navigator.clipboard.readText!==void 0)w1=await navigator.clipboard.readText();else if(H!==void 0&&H?.clipboardData!==null){if(H.clipboardData.types.includes(_1)){let gt=H.clipboardData.getData(_1),_t=document.createElement("html");_t.innerHTML=gt;let Jt=_t.querySelector("table");Jt!==null&&(L1=Tp(Jt))}L1===void 0&&H.clipboardData.types.includes(at)&&(w1=H.clipboardData.getData(at))}else return;let[G1,Lt]=q1,ft=[];do{if(C1===void 0){let gt=n0(q1),_t=Y(gt,q1,(a1=w1??L1?.map(Jt=>Jt.join(" ")).join(" "))!=null?a1:"");_t!==void 0&&ft.push(_t);break}if(L1===void 0){if(w1===void 0)return;L1=vE(w1)}if(C1===!1||typeof C1=="function"&&C1?.([q1[0]-P,q1[1]],L1)!==!0)return;for(let[gt,_t]of L1.entries()){if(gt+Lt>=R)break;for(let[Jt,Bt]of _t.entries()){let mt=[Jt+G1,gt+Lt],j0=n0(mt),Fe=Y(j0,mt,Bt);Fe!==void 0&&ft.push(Fe)}}}while(!1);J1(ft),(e1=Et.current)==null||e1.damage(ft.map(gt=>({cell:gt.location})))}},[T,F,n0,G,st.paste,J1,C1,P,R]);Q0("paste",J5,window,!1,!0);let to=D.useCallback(async(H,A)=>{var k,_;if(!st.copy)return;let K=A===!0||((k=z.current)==null?void 0:k.contains(document.activeElement))===!0||((_=s.current)==null?void 0:_.contains(document.activeElement))===!0,X=G.columns,a1=G.rows,e1=(Y,M1)=>{if(!Ut)Pp(Y,M1,H);else{let A1=M1.map(I1=>({kind:t1.Text,data:V[I1].title,displayData:V[I1].title,allowOverlay:!1}));Pp([A1,...Y],M1,H)}};if(K&&L0!==void 0){if(G.current!==void 0){let Y=L0(G.current.range,x2.current.signal);typeof Y!="object"&&(Y=await Y()),e1(Y,(0,e4.default)(G.current.range.x-P,G.current.range.x+G.current.range.width-P))}else if(a1!==void 0&&a1.length>0){let M1=[...a1].map(A1=>{let I1=L0({x:P,y:A1,width:V.length-P,height:1},x2.current.signal);return typeof I1=="object"?I1[0]:I1().then(q1=>q1[0])});if(M1.some(A1=>A1 instanceof Promise)){let A1=await Promise.all(M1);e1(A1,(0,e4.default)(V.length))}else e1(M1,(0,e4.default)(V.length))}else if(X.length>0){let Y=[],M1=[];for(let A1 of X){let I1=L0({x:A1,y:0,width:1,height:R},x2.current.signal);typeof I1!="object"&&(I1=await I1()),Y.push(I1),M1.push(A1-P)}if(Y.length===1)e1(Y[0],M1);else{let A1=Y.reduce((I1,q1)=>I1.map((L1,w1)=>[...L1,...q1[w1]]));e1(A1,M1)}}}},[V,L0,G,st.copy,P,R,Ut]);Q0("copy",to,window,!1,!1);let Hm=D.useCallback((H,A)=>{if(H.length===0||A===-1)return;let[k,_]=H[A];L.current!==void 0&&L.current[0]===k&&L.current[1]===_||(L.current=[k,_],Ua(k,_,!1,!1))},[Ua]),[di,si]=(l=(i=Mt?.current)==null?void 0:i.cell)!=null?l:[],t6=D.useRef(Kt);t6.current=Kt,D.useLayoutEffect(()=>{var H,A,k,_;!ot.current&&di!==void 0&&si!==void 0&&(di!==((A=(H=d4.current)==null?void 0:H.current)==null?void 0:A.cell[0])||si!==((_=(k=d4.current)==null?void 0:k.current)==null?void 0:_.cell[1]))&&t6.current(di,si),ot.current=!1},[di,si]);let xm=D.useMemo(()=>w0===!0&&yt?.tint===!0?pt.fromSingleSelection(p0-1):pt.empty(),[p0,w0,yt?.tint]),wm=D.useCallback(H=>{var A;return typeof Ct=="boolean"?Ct:(A=Ct?.(H-P))!=null?A:!0},[P,Ct]),Lm=D.useMemo(()=>{if(X5===void 0||s.current===null)return null;let{bounds:H,group:A}=X5,k=s.current.getBoundingClientRect();return D.createElement(rE,{bounds:H,group:A,canvasBounds:k,onClose:()=>Y5(void 0),onFinish:_=>{Y5(void 0),d1?.(A,_)}})},[d1,X5]),Vm=Math.min(p1.length,q+(c2?1:0));D.useImperativeHandle(a,()=>({appendRow:H=>f4(H+P),updateCells:H=>{var A;return P!==0&&(H=H.map(k=>({cell:[k.cell[0]+P,k.cell[1]]}))),(A=Et.current)==null?void 0:A.damage(H)},getBounds:(H,A)=>{var k;return(k=Et.current)==null?void 0:k.getBounds(H+P,A)},focus:()=>{var H;return(H=Et.current)==null?void 0:H.focus()},emit:async H=>{switch(H){case"delete":Sr({bounds:void 0,cancel:()=>{},stopPropagation:()=>{},preventDefault:()=>{},ctrlKey:!1,key:"Delete",keyCode:46,metaKey:!1,shiftKey:!1,altKey:!1,rawEvent:void 0});break;case"fill-right":Sr({bounds:void 0,cancel:()=>{},stopPropagation:()=>{},preventDefault:()=>{},ctrlKey:!0,key:"r",keyCode:82,metaKey:!1,shiftKey:!1,altKey:!1,rawEvent:void 0});break;case"fill-down":Sr({bounds:void 0,cancel:()=>{},stopPropagation:()=>{},preventDefault:()=>{},ctrlKey:!0,key:"d",keyCode:68,metaKey:!1,shiftKey:!1,altKey:!1,rawEvent:void 0});break;case"copy":await to(void 0,!0);break;case"paste":await J5();break}},scrollTo:Kt}),[f4,to,Sr,J5,P,Kt]);let[a6,e6]=wa??[],Rm=D.useCallback(H=>{let[A,k]=H;if(k===-1){O!=="none"&&(h0(pt.fromSingleSelection(A),void 0,!1),Gt());return}a6===A&&e6===k||(f0({cell:H,range:{x:A,y:k,width:1,height:1}},!0,!1,"keyboard-nav"),Kt(A,k))},[O,Gt,Kt,a6,e6,f0,h0]),[ym,Cm]=D.useState(!1),r6=D.useRef((0,Wp.default)(H=>{Cm(H)},5)),Bm=D.useCallback(()=>{r6.current(!0),G.current===void 0&&G.columns.length===0&&G.rows.length===0&&d===void 0&&f0({cell:[P,g2],range:{x:P,y:g2,width:1,height:1}},!0,!1,"keyboard-select")},[g2,G,d,P,f0]),Sm=D.useCallback(()=>{r6.current(!1)},[]),[Am,Fm]=D.useMemo(()=>{var H;let A,k=(H=e0?.scrollbarWidthOverride)!=null?H:pk(),_=R+(w0?1:0);if(typeof x0=="number")A=m1+_*x0;else{let X=0,a1=Math.min(_,10);for(let e1=0;e1a1.width+X,0)+k;return[`${Math.min(1e5,K)}px`,`${Math.min(1e5,A)}px`]},[p1,e0?.scrollbarWidthOverride,x0,R,w0,m1]);return D.createElement(Yp.Provider,{value:A0},D.createElement(fE,{style:Kp(A0),className:g1,inWidth:y??Am,inHeight:w??Fm},D.createElement(tE,{fillHandle:Ta,drawFocusRing:fa,experimental:e0,fixedShadowX:ta,fixedShadowY:Ve,getRowThemeOverride:M,headerIcons:u0,imageWindowLoader:r0,initialSize:P0,isDraggable:D5,onDragLeave:aa,onRowMoved:Pa,overscrollX:Se,overscrollY:Hr,preventDiagonalScrolling:Re,rightElement:l4,rightElementProps:o4,showMinimap:ye,smoothScrollX:pa,smoothScrollY:N5,className:g1,enableGroups:S1,onCanvasFocused:Bm,onCanvasBlur:Sm,canvasRef:s,onContextMenu:Mm,theme:A0,cellXOffset:Ha,cellYOffset:g2,accessibilityHeight:wt.height,onDragEnd:pm,columns:p1,drawCustomCell:u1,drawHeader:Lr,disabledRows:xm,freezeColumns:Vm,lockColumns:P,firstColAccessible:P===0,getCellContent:n0,minColumnWidth:Oa,maxColumnWidth:Ce,searchInputRef:g,showSearch:U5,onSearchClose:W5,highlightRegions:xa,getCellsForSelection:L0,getGroupDetails:K5,headerHeight:v4,isFocused:ym,groupHeaderHeight:S1?g4:0,trailingRowType:w0?yt?.sticky===!0?"sticky":"appended":"none",onColumnResize:Na,onColumnResizeEnd:s4,onColumnResizeStart:wr,onCellFocused:Rm,onColumnMoved:um,onDragStart:fm,onHeaderMenuClick:dm,onItemHovered:zm,isFilling:d?.fillHandle===!0,onMouseMove:gm,onKeyDown:Sr,onKeyUp:P1,onMouseDown:hm,onMouseUp:vm,onDragOverCell:_2,onDrop:s0,onSearchResultsChanged:Hm,onVisibleRegionChanged:sm,clientSize:[u4[0],u4[1]],rowHeight:x0,rows:p0,scrollRef:z,selection:G,translateX:wt.tx,translateY:wt.ty,verticalBorder:wm,gridRef:Et,getCellRenderer:F,scrollToEnd:ri}),Lm,c!==void 0&&D.createElement(lk,{...c,validateCell:q5,id:Z5,getCellRenderer:F,className:e0?.isSubGrid===!0?"click-outside-ignore":void 0,provideEditor:qt,imageEditorOverride:m,onFinishEditing:mm,markdownDivCreateNode:x})))},Ez=D.forwardRef(t_);var zr=B1(T1());var I8=B1(T1()),O8={color:void 0,size:void 0,className:void 0,style:void 0,attr:void 0},D8=I8.default.createContext&&I8.default.createContext(O8);var we=function(){return we=Object.assign||function(t){for(var a,e=1,r=arguments.length;et.length)&&(a=t.length);for(var e=0,r=new Array(a);e=t.length?{done:!0}:{done:!1,value:t[r++]}}}throw new TypeError(`Invalid attempt to iterate non-iterable instance. -In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function jz(t){var a=(0,Z1.useRef)(null);function e(r){!r||r===a.current||(a.current=r,t(r))}return e}function l_(t){var a=(0,Z1.useRef)(t);return(0,Z1.useMemo)(function(){function e(n){typeof n=="function"?a.current=n(a.current):a.current=n}function r(){return a.current}return[r,e]},[])}function o_(){var t=(0,Z1.useRef)([]);return(0,Z1.useMemo)(function(){function a(){return t.current.length>0}function e(){for(var n=Mr(t.current),i;!(i=n()).done;){var l=i.value;l()}t.current=[]}function r(n){t.current.push(n)}return{hasEventSubscriptions:a,removeAllEventSubscriptions:e,addEventSubscription:r}},[])}var N8=typeof window<"u"?Z1.useLayoutEffect:Z1.useEffect;function h_(t,a){var e=(0,Z1.useRef)(t);return a?(e.current=t,e):(e.current=null,e)}function ei(t){return parseFloat(t.replace("px",""))}function U8(t,a,e){return te?e:t}function qz(t){return t!=null}function Gz(){for(var t=arguments.length,a=new Array(t),e=0;e"u"))return a||t.ResizeObserver}function em(t,a){var e=[];if(!t||!a||t===document.body)return e;var r=a.getComputedStyle(t),n=r.overflow,i=r.overflowX,l=r.overflowY;return[n,i,l].some(function(o){return["auto","scroll"].includes(o)})&&e.push(t),[].concat(e,em(t.parentElement,a))}function P5(t){return"react-laag: Could not find a valid reference for the "+t+` element. There might be 2 causes: +`)&&(r.push(Wp(t.slice(n,l))),n=l+1,o===` +`&&(e.push(r),r=[])),i=0);break}l++}return n0;){let l=r.pop();if(l===void 0)break;l instanceof HTMLTableElement||l.nodeName==="TBODY"?r.push(...[...l.children].reverse()):l instanceof HTMLTableRowElement?(i!==void 0&&n.push(i),i=[],r.push(...[...l.children].reverse())):l instanceof HTMLTableCellElement&&i?.push((e=(a=l.innerText)!=null?a:l.textContent)!=null?e:"")}return i!==void 0&&n.push(i),n}function He(t){return/[\t\n",]/.test(t)&&(t=`"${t.replace(/"/g,'""')}"`),t}var CE=t=>{switch(t){case!0:return"TRUE";case!1:return"FALSE";case I8:return"INDETERMINATE";case Qn:return"";default:sr(t,`A boolean was formated with invalid type: ${typeof t}`)}};function Oz(t,a,e,r){var n,i;let l=r[a];if(t.span!==void 0&&t.span[0]!==l)return"";if(t.copyData!==void 0)return He(t.copyData);switch(t.kind){case l1.Text:case l1.Number:return He(e?(i=(n=t.data)==null?void 0:n.toString())!=null?i:"":t.displayData);case l1.Markdown:case l1.RowID:case l1.Uri:return He(t.data);case l1.Image:case l1.Bubble:return t.data.length===0?"":t.data.reduce((o,h)=>`${He(o)},${He(h)}`);case l1.Boolean:return CE(t.data);case l1.Loading:return e?"":"#LOADING";case l1.Protected:return e?"":"************";case l1.Drilldown:return t.data.length===0?"":t.data.map(o=>o.text).reduce((o,h)=>`${He(o)},${He(h)}`);case l1.Custom:return He(t.copyData);default:sr(t,`A cell was passed with an invalid kind: ${t.kind}`)}}function BE(t,a){return t.map(e=>e.map((r,n)=>Oz(r,n,!1,a)).join(" ")).join(` +`)}function qp(t,a,e){var r,n,i,l;let o=BE(t,a);if(((r=window.navigator.clipboard)==null?void 0:r.write)!==void 0||e!==void 0){let h=document.createElement("tbody");for(let c of t){let v=document.createElement("tr");for(let[g,d]of c.entries()){let u=document.createElement("td");if(d.kind===l1.Uri){let p=document.createElement("a");p.href=d.data,p.innerText=d.data,u.append(p)}else u.innerText=Oz(d,g,!0,a);v.append(u)}h.append(v)}if(((n=window.navigator.clipboard)==null?void 0:n.write)!==void 0)window.navigator.clipboard.write([new ClipboardItem({"text/plain":new Blob([o],{type:"text/plain"}),"text/html":new Blob([`${h.outerHTML}
`],{type:"text/html"})})]);else if(e!==void 0&&e?.clipboardData!==null)try{e.clipboardData.setData("text/plain",o),e.clipboardData.setData("text/html",`${h.outerHTML}
`)}catch{(i=window.navigator.clipboard)==null||i.writeText(o)}}else(l=window.navigator.clipboard)==null||l.writeText(o);e?.preventDefault()}function Gp(t){return typeof t=="string"?t:`${t}px`}var SE=()=>t=>t.innerWidth,AE=()=>t=>t.innerHeight,FE=L0("div")({name:"Wrapper",class:"wzg2m5k",vars:{"wzg2m5k-0":[SE()],"wzg2m5k-1":[AE()]}}),kE=t=>{let{inWidth:a,inHeight:e,children:r,...n}=t;return Dz.createElement(FE,{innerHeight:Gp(e),innerWidth:Gp(a),...n},r)};function Nz(t){return t!==!0}var Kp=20,bE={getAccessibilityString:t=>{var a,e;return(e=(a=t.data)==null?void 0:a.toString())!=null?e:"false"},kind:l1.Boolean,needsHover:!0,useLabel:!1,needsHoverPosition:!0,measure:()=>50,draw:t=>{var a;return Xk(t,t.cell.data,S8(t.cell),(a=t.cell.maxSize)!=null?a:Kp)},onDelete:t=>({...t,data:!1}),onClick:t=>{var a,e;let{cell:r,posX:n,posY:i,bounds:l,theme:o}=t,{width:h,height:c,x:v,y:g}=l,d=(a=r.maxSize)!=null?a:Kp,u=Math.floor(l.y+c/2),p=Mz(d,c,o.cellVerticalPadding),z=mz((e=r.contentAlign)!=null?e:"center",v,h,o.cellHorizontalPadding,p),w=zz(z,u,p),s=Hz(v+n,g+i,w);if(S8(r)&&s)return{...r,data:Nz(r.data)}},onPaste:(t,a)=>{let e=Qn;return t.toLowerCase()==="true"?e=!0:t.toLowerCase()==="false"?e=!1:t.toLowerCase()==="indeterminate"&&(e=I8),e===a.data?void 0:{...a,data:e}}},EE=2,_E=1300;function TE(t,a){let e=T8.default.useRef(0),[r,n]=t??[0,0];T8.default.useEffect(()=>{if(r===0&&n===0){e.current=0;return}let i=0,l=h=>{var c;if(i===0)i=h;else{let v=h-i;e.current=Math.min(1,e.current+v/_E);let g=e.current**1.618*v*EE;(c=a.current)==null||c.scrollBy(r*g,n*g),i=h}o=window.requestAnimationFrame(l)},o=window.requestAnimationFrame(l);return()=>window.cancelAnimationFrame(o)},[a,r,n])}var PE=L0("div")({name:"BubblesOverlayEditorStyle",class:"b1bqsp5z"}),IE=t=>{let{bubbles:a}=t;return P5.createElement(PE,null,a.map((e,r)=>P5.createElement("div",{key:r,className:"boe-bubble"},e)),P5.createElement("textarea",{className:"gdg-input",autoFocus:!0}))},OE=IE,DE={getAccessibilityString:t=>{var a,e;return(e=(a=t.data)==null?void 0:a.toString())!=null?e:""},kind:l1.Bubble,needsHover:!1,useLabel:!1,needsHoverPosition:!1,measure:(t,a,e)=>a.data.reduce((r,n)=>t.measureText(n).width+r+20,0)+2*e.cellHorizontalPadding-4,draw:t=>Yk(t,t.cell.data),provideEditor:()=>t=>{let{value:a}=t;return $z.createElement(OE,{bubbles:a.data})},onPaste:()=>{}},NE=L0("div")({name:"DrilldownOverlayEditorStyle",class:"df2kt4a"}),$E=t=>{let{drilldowns:a}=t;return Xn.createElement(NE,null,a.map((e,r)=>Xn.createElement("div",{key:r,className:"doe-bubble"},e.img!==void 0&&Xn.createElement("img",{src:e.img}),Xn.createElement("div",null,e.text))))},UE=$E,WE={getAccessibilityString:t=>t.data.map(a=>a.text).join(", "),kind:l1.Drilldown,needsHover:!1,useLabel:!1,needsHoverPosition:!1,measure:(t,a,e)=>a.data.reduce((r,n)=>t.measureText(n.text).width+r+20+(n.img!==void 0?18:0),0)+2*e.cellHorizontalPadding-4,draw:t=>Zk(t,t.cell.data),provideEditor:()=>t=>{let{value:a}=t;return Uz.createElement(UE,{drilldowns:a.data})},onPaste:()=>{}},jE=L0("div")({name:"ImageOverlayEditorStyle",class:"i1eozt10"}),qE=t=>{let{urls:a,canWrite:e,onEditClick:r,renderImage:n}=t,i=a.filter(o=>o!=="");if(i.length===0)return null;let l=i.length>1;return n4.createElement(jE,{"data-testid":"GDG-default-image-overlay-editor"},n4.createElement(jz.Carousel,{showArrows:l,showThumbs:!1,swipeable:l,emulateTouch:l,infiniteLoop:l},i.map(o=>{var h;let c=(h=n?.(o))!=null?h:n4.createElement("img",{draggable:!1,src:o});return n4.createElement("div",{className:"centering-container",key:o},c)})),e&&r&&n4.createElement("button",{className:"edit-icon",onClick:r},n4.createElement(D8,null)))},GE={getAccessibilityString:t=>t.data.join(", "),kind:l1.Image,needsHover:!1,useLabel:!1,needsHoverPosition:!1,draw:t=>{var a;return Jk(t,(a=t.cell.displayData)!=null?a:t.cell.data,t.cell.rounding,t.cell.contentAlign)},measure:(t,a)=>a.data.length*50,onDelete:t=>({...t,data:[]}),provideEditor:()=>t=>{let{value:a,onFinishedEditing:e,imageEditorOverride:r}=t;return Wz.createElement(r??qE,{urls:a.data,canWrite:a.allowAdd,onCancel:e,onChange:i=>{e({...a,data:[i]})}})},onPaste:(t,a)=>{t=t.trim();let r=t.split(",").map(n=>{try{return new URL(n),n}catch{return}}).filter(n=>n!==void 0);if(!(r.length===a.data.length&&r.every((n,i)=>n===a.data[i])))return{...a,data:r}}},KE={getAccessibilityString:()=>"",kind:l1.Loading,needsHover:!1,useLabel:!1,needsHoverPosition:!1,measure:()=>120,draw:()=>{},onPaste:()=>{}},XE=L0("div")({name:"MarkdownContainer",class:"mlbeo71"}),YE=class extends P8.default.PureComponent{constructor(){super(...arguments),this.targetElement=null,this.containerRefHook=t=>{this.targetElement=t,this.renderMarkdownIntoDiv()}}renderMarkdownIntoDiv(){let{targetElement:t,props:a}=this;if(t===null)return;let{contents:e,createNode:r}=a,n=j1(e),i=document.createRange();i.selectNodeContents(t),i.deleteContents();let l=r?.(n);if(l===void 0){let h=document.createElement("template");h.innerHTML=n,l=h.content}t.append(l);let o=t.getElementsByTagName("a");for(let h of o)h.target="_blank",h.rel="noreferrer noopener"}render(){return this.renderMarkdownIntoDiv(),P8.default.createElement(XE,{ref:this.containerRefHook})}},QE=L0("textarea")({name:"InputBox",class:"ijuk0po"}),ZE=L0("div")({name:"ShadowBox",class:"saq3p5l"}),JE=L0("div")({name:"GrowingEntryStyle",class:"gf8vzix"}),Xp=0,N5=t=>{let{placeholder:a,value:e,onKeyDown:r,highlight:n,altNewline:i,validatedSelection:l,...o}=t,{onChange:h,className:c}=o,v=h2.useRef(null),g=e??"";i2(h!==void 0,"GrowingEntry must be a controlled input area");let[d]=h2.useState(()=>"input-box-"+(Xp=(Xp+1)%1e7));h2.useEffect(()=>{let p=v.current;if(p===null||p.disabled)return;let z=g.toString().length;p.focus(),p.setSelectionRange(n?0:z,z)},[]),h2.useLayoutEffect(()=>{var p;if(l!==void 0){let z=typeof l=="number"?[l,null]:l;(p=v.current)==null||p.setSelectionRange(z[0],z[1])}},[l]);let u=h2.useCallback(p=>{p.key==="Enter"&&p.shiftKey&&i===!0||r?.(p)},[i,r]);return h2.createElement(JE,{className:"gdg-growing-entry"},h2.createElement(ZE,{className:c},g+` +`),h2.createElement(QE,{...o,className:(c??"")+" gdg-input",id:d,ref:v,onKeyDown:u,value:g,placeholder:a,dir:"auto"}))},t_=()=>t=>t.targetWidth,Yp=L0("div")({name:"MarkdownOverlayEditorStyle",class:"mdwzdl1",vars:{"mdwzdl1-0":[t_(),"px"]}}),a_=t=>{let{value:a,onChange:e,forceEditMode:r,createNode:n,targetRect:i,onFinish:l,validatedSelection:o}=t,h=a.data,c=a.readonly===!0,[v,g]=R0.useState(h===""||r),d=R0.useCallback(()=>{g(p=>!p)},[]),u=h?"ml-6":"";return v?R0.createElement(Yp,{targetWidth:i.width-20},R0.createElement(N5,{autoFocus:!0,highlight:!1,validatedSelection:o,value:h,onKeyDown:p=>{p.key==="Enter"&&p.stopPropagation()},onChange:e}),R0.createElement("div",{className:`edit-icon checkmark-hover ${u}`,onClick:()=>l(a)},R0.createElement(Bk,null))):R0.createElement(Yp,{targetWidth:i.width},R0.createElement(YE,{contents:h,createNode:n}),!c&&R0.createElement(R0.Fragment,null,R0.createElement("div",{className:"spacer"}),R0.createElement("div",{className:`edit-icon edit-hover ${u}`,onClick:d},R0.createElement(D8,null))),R0.createElement("textarea",{className:"md-edit-textarea gdg-input",autoFocus:!0}))},e_={getAccessibilityString:t=>{var a,e;return(e=(a=t.data)==null?void 0:a.toString())!=null?e:""},kind:l1.Markdown,needsHover:!1,needsHoverPosition:!1,drawPrep:Jn,measure:(t,a,e)=>{let r=a.data.split(` +`)[0];return t.measureText(r).width+2*e.cellHorizontalPadding},draw:t=>ti(t,t.cell.data,t.cell.contentAlign),onDelete:t=>({...t,data:""}),provideEditor:()=>t=>{let{onChange:a,value:e,target:r,onFinishedEditing:n,markdownDivCreateNode:i,forceEditMode:l,validatedSelection:o}=t;return qz.createElement(a_,{onFinish:n,targetRect:r,value:e,validatedSelection:o,onChange:h=>a({...e,data:h.target.value}),forceEditMode:l,createNode:i})},onPaste:(t,a)=>t===a.data?void 0:{...a,data:t}},r_={getAccessibilityString:t=>t.row.toString(),kind:o2.Marker,needsHover:!0,needsHoverPosition:!1,drawPrep:jk,measure:()=>44,draw:t=>Gk(t,t.cell.row,t.cell.checked,t.cell.markerKind,t.cell.drawHandle),onClick:t=>{let{bounds:a,cell:e,posX:r,posY:n}=t,{width:i,height:l}=a,o=e.drawHandle?7+(i-7)/2:i/2,h=l/2;if(Math.abs(r-o)<=10&&Math.abs(n-h)<=10)return{...e,checked:!e.checked}},onPaste:()=>{}},n_={getAccessibilityString:()=>"",kind:o2.NewRow,needsHover:!0,needsHoverPosition:!1,measure:()=>200,draw:t=>Wk(t,t.cell.hint,t.cell.icon),onPaste:()=>{}},i_=o4.lazy(async()=>await Promise.resolve().then(()=>(Ap(),Sp))),l_={getAccessibilityString:t=>{var a,e;return(e=(a=t.data)==null?void 0:a.toString())!=null?e:""},kind:l1.Number,needsHover:!1,needsHoverPosition:!1,useLabel:!0,drawPrep:Jn,draw:t=>ti(t,t.cell.displayData,t.cell.contentAlign),measure:(t,a)=>t.measureText(a.displayData).width+16,onDelete:t=>({...t,data:void 0}),provideEditor:()=>t=>{let{isHighlighted:a,onChange:e,value:r,validatedSelection:n}=t;return o4.createElement(o4.Suspense,{fallback:null},o4.createElement(i_,{highlight:a,disabled:r.readonly===!0,value:r.data,fixedDecimals:r.fixedDecimals,allowNegative:r.allowNegative,thousandSeparator:r.thousandSeparator,decimalSeparator:r.decimalSeparator,validatedSelection:n,onChange:i=>{var l;return e({...r,data:Number.isNaN((l=i.floatValue)!=null?l:0)?0:i.floatValue})}}))},onPaste:(t,a)=>{let e=Number.parseFloat(t);if(!(Number.isNaN(e)||a.data===e))return{...a,data:e}}},o_={getAccessibilityString:()=>"",measure:()=>108,kind:l1.Protected,needsHover:!1,needsHoverPosition:!1,draw:Kk,onPaste:()=>{}},h_={getAccessibilityString:t=>{var a,e;return(e=(a=t.data)==null?void 0:a.toString())!=null?e:""},kind:l1.RowID,needsHover:!1,needsHoverPosition:!1,drawPrep:(t,a)=>Jn(t,a,t.theme.textLight),draw:t=>ti(t,t.cell.data,t.cell.contentAlign),measure:(t,a)=>t.measureText(a.data).width+16,provideEditor:()=>t=>{let{isHighlighted:a,onChange:e,value:r,validatedSelection:n}=t;return Gz.default.createElement(N5,{highlight:a,autoFocus:r.readonly!==!0,disabled:r.readonly!==!1,value:r.data,validatedSelection:n,onChange:i=>e({...r,data:i.target.value})})},onPaste:()=>{}},c_={getAccessibilityString:t=>{var a,e;return(e=(a=t.data)==null?void 0:a.toString())!=null?e:""},kind:l1.Text,needsHover:!1,needsHoverPosition:!1,drawPrep:Jn,useLabel:!0,draw:t=>(ti(t,t.cell.displayData,t.cell.contentAlign,t.cell.allowWrapping,t.hyperWrapping),!0),measure:(t,a,e)=>{let r=a.displayData.split(` +`).slice(0,a.allowWrapping===!0?void 0:1);return Math.max(...r.map(n=>t.measureText(n).width+2*e.cellHorizontalPadding))},onDelete:t=>({...t,data:""}),provideEditor:t=>({disablePadding:t.allowWrapping===!0,editor:a=>{let{isHighlighted:e,onChange:r,value:n,validatedSelection:i}=a;return Kz.createElement(N5,{style:t.allowWrapping===!0?{padding:"3px 8.5px"}:void 0,highlight:e,autoFocus:n.readonly!==!0,disabled:n.readonly===!0,altNewline:!0,value:n.data,validatedSelection:i,onChange:l=>r({...n,data:l.target.value})})}}),onPaste:(t,a)=>t===a.data?void 0:{...a,data:t}},v_=L0("div")({name:"UriOverlayEditorStyle",class:"uf0sjo8"}),g_=t=>{let{uri:a,onChange:e,forceEditMode:r,readonly:n,validatedSelection:i,preview:l}=t,[o,h]=ea.useState(a===""||r),c=ea.useCallback(()=>{h(!0)},[]);return o?ea.createElement(N5,{validatedSelection:i,highlight:!0,autoFocus:!0,value:a,onChange:e}):ea.createElement(v_,null,ea.createElement("a",{className:"link-area",href:a,target:"_blank",rel:"noopener noreferrer"},l),!n&&ea.createElement("div",{className:"edit-icon",onClick:c},ea.createElement(D8,null)),ea.createElement("textarea",{className:"gdg-input",autoFocus:!0}))},d_=g_,s_={getAccessibilityString:t=>{var a,e;return(e=(a=t.data)==null?void 0:a.toString())!=null?e:""},kind:l1.Uri,needsHover:!1,needsHoverPosition:!1,useLabel:!0,drawPrep:Jn,draw:t=>ti(t,t.cell.data,t.cell.contentAlign),measure:(t,a,e)=>t.measureText(a.data).width+e.cellHorizontalPadding*2,onDelete:t=>({...t,data:""}),provideEditor:()=>t=>{var a;let{onChange:e,value:r,forceEditMode:n,validatedSelection:i}=t;return Xz.createElement(d_,{forceEditMode:n,uri:r.data,preview:(a=r.displayData)!=null?a:r.data,validatedSelection:i,readonly:r.readonly===!0,onChange:l=>e({...r,data:l.target.value})})},onPaste:(t,a)=>t===a.data?void 0:{...a,data:t}},u_={[o2.Marker]:r_,[o2.NewRow]:n_,[l1.Boolean]:bE,[l1.Bubble]:DE,[l1.Drilldown]:WE,[l1.Image]:GE,[l1.Loading]:KE,[l1.Markdown]:e_,[l1.Number]:l_,[l1.Protected]:o_,[l1.RowID]:h_,[l1.Text]:c_,[l1.Uri]:s_},f_=0;function p_(t){return(0,tz.default)((0,B8.default)((0,B8.default)(t).filter(a=>a.span!==void 0).map(a=>{var e,r,n,i;return(0,i4.default)(((r=(e=a.span)==null?void 0:e[0])!=null?r:0)+1,((i=(n=a.span)==null?void 0:n[1])!=null?i:0)+1)})))}function A5(t,a){return t===void 0||a===0||t.columns.length===0&&t.current===void 0?t:{current:t.current===void 0?void 0:{cell:[t.current.cell[0]+a,t.current.cell[1]],range:{...t.current.range,x:t.current.range.x+a},rangeStack:t.current.rangeStack.map(e=>({...e,x:e.x+a}))},rows:t.rows,columns:t.columns.offset(a)}}var Qp={selectAll:!0,selectRow:!0,selectColumn:!0,downFill:!1,rightFill:!1,pageUp:!1,pageDown:!1,clear:!0,copy:!0,paste:!0,search:!1,first:!0,last:!0},Zp={kind:l1.Loading,allowOverlay:!1},F5={columns:mt.empty(),rows:mt.empty(),current:void 0},z_=(t,a)=>{var e,r,n,i,l;let[o,h]=$.useState(F5),[c,v]=$.useState(),g=$.useRef(null),d=$.useRef(null),[u,p]=$.useState(),z=$.useRef(null),w=$.useRef(),{rowMarkers:s="none",rowMarkerWidth:f,imageEditorOverride:m,getRowThemeOverride:H,markdownDivCreateNode:x,width:y,height:R,columns:L,rows:V,getCellContent:C,onCellClicked:k,onCellActivated:b,onFinishedEditing:F,coercePasteValue:_,drawHeader:j,onHeaderClicked:n1,spanRangeBehavior:Z="default",onGroupHeaderClicked:d1,onCellContextMenu:O,className:a1,onHeaderContextMenu:W,getCellsForSelection:L1,onGroupHeaderContextMenu:p1,onGroupHeaderRenamed:o1,onCellEdited:H1,onCellsEdited:P1,onSearchResultsChanged:K1,searchResults:W1,onSearchValueChange:Bt,searchValue:T1,onKeyDown:X1,onKeyUp:Y,keybindings:N,onRowAppended:s1,onColumnMoved:x1,validateCell:f1,highlightRegions:U,drawCell:v1,rangeSelect:D="rect",columnSelect:I="multi",rowSelect:C1="multi",rangeSelectionBlending:D1="exclusive",columnSelectionBlending:et="exclusive",rowSelectionBlending:B1="exclusive",onDelete:c1,onDragStart:e1,onMouseMove:u1,onPaste:M1,copyHeaders:I1=!1,freezeColumns:Q1=0,rowSelectionMode:St="auto",rowMarkerStartIndex:jt=1,rowMarkerTheme:Ut,onHeaderMenuClick:Et,getGroupDetails:ot,onSearchClose:J1,onItemHovered:Jt,onSelectionCleared:Mt,showSearch:C0,onVisibleRegionChanged:Z0,gridSelection:B0,onGridSelectionChange:t0,minColumnWidth:Ma=50,maxColumnWidth:dt=500,maxColumnAutoWidth:At,provideEditor:h0,trailingRowOptions:wt,scrollOffsetX:Ft,scrollOffsetY:qt,verticalBorder:c2,onDragOverCell:v2,onDrop:$a,onColumnResize:O2,onColumnResizeEnd:j0,onColumnResizeStart:g2,customRenderers:D2,fillHandle:ri,drawFocusRing:u0,experimental:Ht,fixedShadowX:m0,fixedShadowY:j5,headerIcons:ia,imageWindowLoader:ni,initialSize:xr,isDraggable:Se,onDragLeave:Ae,onRowMoved:la,overscrollX:Ha,overscrollY:oa,preventDiagonalScrolling:xa,rightElement:q5,rightElementProps:ii,showMinimap:G5,smoothScrollX:li,smoothScrollY:c4,scrollToEnd:Fe,scaleToRem:oi=!1,rowHeight:wr=34,headerHeight:ke=36,groupHeaderHeight:v4=ke,theme:d2,isOutsideClick:J8}=t,wa=Math.max(Ma,20),Ua=Math.max(dt,wa),hi=Math.max(At??Ua,wa),La=$.useMemo(()=>typeof window>"u"?{fontSize:"16px"}:window.getComputedStyle(document.documentElement),[]).fontSize,ha=$.useMemo(()=>Number.parseFloat(La),[La]),[M0,Va,g4,Lr,vi,K5]=$.useMemo(()=>{var M,A,E;if(!oi||ha===16)return[wr,ke,v4,d2,Ha,oa];let T=ha/16,J=wr,K=kp();return[typeof J=="number"?J*T:X=>Math.ceil(J(X)*T),Math.ceil(ke*T),Math.ceil(v4*T),{...d2,headerIconSize:((M=d2?.headerIconSize)!=null?M:K.headerIconSize)*T,cellHorizontalPadding:((A=d2?.cellHorizontalPadding)!=null?A:K.cellHorizontalPadding)*T,cellVerticalPadding:((E=d2?.cellVerticalPadding)!=null?E:K.cellVerticalPadding)*T},Math.ceil((Ha??0)*T),Math.ceil((oa??0)*T)]},[v4,ke,Ha,oa,ha,wr,oi,d2]),Lt=$.useMemo(()=>N===void 0?Qp:{...Qp,...N},[N]),Wa=f??(V>1e4?48:V>1e3?44:V>100?36:32),s2=s!=="none",P=s2?1:0,H0=s1!==void 0,V2=wt?.sticky===!0,[X5,gi]=$.useState(!1),Y5=C0??X5,Q5=$.useCallback(()=>{J1!==void 0?J1():gi(!1)},[J1]),d4=$.useMemo(()=>B0===void 0?void 0:A5(B0,P),[B0,P]),q=d4??o,R2=$.useRef(new AbortController);$.useEffect(()=>()=>{R2?.current.abort()},[]);let[P0,Z5]=VE(L1,C,P,R2.current,V),di=$.useCallback((M,A,E)=>{if(f1===void 0)return!0;let T=[M[0]-P,M[1]];return f1?.(T,A,E)},[P,f1]),Ra=$.useRef(B0),J0=$.useCallback((M,A)=>{A&&(M=RE(M,P0,P,Z,R2.current)),t0!==void 0?(Ra.current=A5(M,-P),t0(Ra.current)):h(M)},[t0,P0,P,Z]),ya=jn(O2,$.useCallback((M,A,E,T)=>{O2?.(L[E-P],A,E-P,T)},[O2,P,L])),J5=jn(j0,$.useCallback((M,A,E,T)=>{j0?.(L[E-P],A,E-P,T)},[j0,P,L])),Vr=jn(g2,$.useCallback((M,A,E,T)=>{g2?.(L[E-P],A,E-P,T)},[g2,P,L])),s4=jn(j,$.useCallback(M=>{var A;return(A=j?.({...M,columnIndex:M.columnIndex-P}))!=null?A:!1},[j,P])),Rr=$.useCallback(M=>{if(c1!==void 0){let A=c1(A5(M,-P));return typeof A=="boolean"?A:A5(A,P)}return!0},[c1,P]),[c0,S0,v0]=LE(q,J0,D1,et,B1,D),S=$.useMemo(()=>({...kp(),...Lr}),[Lr]),[G,b1]=$.useState([10,10,0]),z1=$.useCallback(M=>M.kind!==l1.Custom?u_[M.kind]:D2?.find(A=>A.isMatch(M)),[D2]),E1=xE(L,V,Z5,G[0]-(P===0?0:Wa)-G[2],wa,hi,S,z1,R2.current),h1=$.useMemo(()=>E1.some(M=>M.group!==void 0),[E1]),$1=h1?Va+g4:Va,st=q.rows.length,S1=s==="none"?"":st===0?vz:st===V?cz:vk,_1=$.useMemo(()=>s==="none"?E1:[{title:S1,width:Wa,icon:void 0,hasMenu:!1,style:"normal",themeOverride:Ut},...E1],[E1,Wa,s,S1,Ut]),[a0,tt]=$.useMemo(()=>[qt!==void 0&&typeof M0=="number"?Math.floor(qt/M0):0,qt!==void 0&&typeof M0=="number"?-(qt%M0):0],[qt,M0]),ut=$.useRef({height:1,width:1,x:0,y:0}),ht=$.useMemo(()=>{var M,A;return{x:ut.current.x,y:a0,width:(M=ut.current.width)!=null?M:1,height:(A=ut.current.height)!=null?A:1,ty:tt}},[tt,a0]),xt=$.useRef(!1),[_t,Ca,y2]=bk(ht),C2=((e=_t.height)!=null?e:1)>1;$.useLayoutEffect(()=>{if(qt!==void 0&&z.current!==null&&C2){if(z.current.scrollTop===qt)return;z.current.scrollTop=qt,z.current.scrollTop!==qt&&y2(),xt.current=!0}},[qt,C2,y2]);let N2=((r=_t.width)!=null?r:1)>1;$.useLayoutEffect(()=>{if(Ft!==void 0&&z.current!==null&&N2){if(z.current.scrollLeft===Ft)return;z.current.scrollLeft=Ft,z.current.scrollLeft!==Ft&&y2(),xt.current=!0}},[Ft,N2,y2]);let B2=_t.x+P,u2=_t.y,G1=$.useRef(null),Gt=$.useCallback(M=>{var A;M===!0?(A=G1.current)==null||A.focus():window.requestAnimationFrame(()=>{var E;(E=G1.current)==null||E.focus()})},[]),n0=H0?V+1:V,A0=$.useCallback(M=>{let A=P===0?M:M.map(T=>({...T,location:[T.location[0]-P,T.location[1]]})),E=P1?.(A);if(E!==!0)for(let T of A)H1?.(T.location,T.value);return E},[H1,P1,P]),Vm=$.useMemo(()=>{if(U!==void 0)return P===0?U:U.map(M=>{let A=_1.length-M.range.x-P;if(!(A<=0))return{color:M.color,range:{...M.range,x:M.range.x+P,width:Math.min(A,M.range.width)},style:M.style}}).filter(M=>M!==void 0)},[U,_1.length,P]),t6=$.useRef(_1);t6.current=_1;let F0=$.useCallback(([M,A],E=!1)=>{var T,J,K,X,i1,t1,m1,y1,N1,Y1;let w1=H0&&A===n0-1;if(M===0&&s2)return w1?Zp:{kind:o2.Marker,allowOverlay:!1,checked:q?.rows.hasIndex(A)===!0,markerKind:s==="clickable-number"?"number":s,row:jt+A,drawHandle:la!==void 0,cursor:s==="clickable-number"?"pointer":void 0};if(w1){let ct=M===P&&(T=wt?.hint)!=null?T:"",k1=t6.current[M];if(((J=k1?.trailingRowOptions)==null?void 0:J.disabled)===!0)return Zp;{let rt=(X=(K=k1?.trailingRowOptions)==null?void 0:K.hint)!=null?X:ct,gt=(t1=(i1=k1?.trailingRowOptions)==null?void 0:i1.addIcon)!=null?t1:wt?.addIcon;return{kind:o2.NewRow,hint:rt,allowOverlay:!1,icon:gt}}}else{let at=M-P;if(E||Ht?.strict===!0){let k1=ut.current,rt=k1.x>at||at>k1.x+k1.width||k1.y>A||A>k1.y+k1.height,gt=at===((y1=(m1=k1.extras)==null?void 0:m1.selected)==null?void 0:y1[0])&&A===((N1=k1.extras)==null?void 0:N1.selected[1]),Vt=((Y1=k1.extras)==null?void 0:Y1.freezeRegion)===void 0||k1.extras.freezeRegion.x>at||at>k1.extras.freezeRegion.x+k1.extras.freezeRegion.width||k1.extras.freezeRegion.y>A||A>k1.extras.freezeRegion.y+k1.extras.freezeRegion.height;if(rt&&!gt&&Vt)return{kind:l1.Loading,allowOverlay:!1}}let ct=C([at,A]);return P!==0&&ct.span!==void 0&&(ct={...ct,span:[ct.span[0]+P,ct.span[1]+P]}),ct}},[H0,n0,s2,q?.rows,la,s,P,wt?.hint,wt?.addIcon,Ht?.strict,C,jt]),to=$.useCallback(M=>{var A,E;let T=(A=ot?.(M))!=null?A:{name:M};return o1!==void 0&&M!==""&&(T={icon:T.icon,name:T.name,overrideTheme:T.overrideTheme,actions:[...(E=T.actions)!=null?E:[],{title:"Rename",icon:"renameIcon",onClick:J=>ro({group:T.name,bounds:J.bounds})}]}),T},[ot,o1]),si=$.useCallback(M=>{var A;let[E,T]=M.cell,J=_1[E],K=J?.group!==void 0?(A=to(J.group))==null?void 0:A.overrideTheme:void 0,X=J?.themeOverride,i1=H?.(T);v({...M,theme:{...S,...K,...X,...i1,...M.content.themeOverride}})},[H,_1,to,S]),yr=$.useCallback((M,A,E)=>{var T;if(q.current===void 0)return;let[J,K]=q.current.cell,X=F0([J,K]);if(X.kind!==l1.Boolean&&X.allowOverlay){let i1=X;if(E!==void 0)switch(i1.kind){case l1.Number:{let t1=hk(()=>E==="-"?-0:Number.parseFloat(E),0);i1={...i1,data:Number.isNaN(t1)?0:t1};break}case l1.Text:case l1.Markdown:case l1.Uri:i1={...i1,data:E};break}si({target:M,content:i1,initialValue:E,cell:[J,K],highlight:E===void 0,forceEditMode:E!==void 0})}else X.kind===l1.Boolean&&A&&X.readonly!==!0&&(A0([{location:q.current.cell,value:{...X,data:Nz(X.data)}}]),(T=G1.current)==null||T.damage([{cell:q.current.cell}]))},[F0,q,A0,si]),a6=$.useCallback((M,A)=>{var E;let T=(E=G1.current)==null?void 0:E.getBounds(M,A);if(T===void 0||z.current===null)return;let J=F0([M,A]);!J.allowOverlay||si({target:T,content:J,initialValue:void 0,highlight:!0,cell:[M,A],forceEditMode:!0})},[F0,si]),Kt=$.useCallback((M,A,E="both",T=0,J=0,K=void 0)=>{var X;if(z.current!==null){let i1=G1.current,t1=d.current,m1=typeof M!="number"?M.unit==="cell"?M.amount:void 0:M,y1=typeof A!="number"?A.unit==="cell"?A.amount:void 0:A,N1=typeof M!="number"&&M.unit==="px"?M.amount:void 0,Y1=typeof A!="number"&&A.unit==="px"?A.amount:void 0;if(i1!==null&&t1!==null){let w1={x:0,y:0,width:0,height:0},A1=0,at=0;if((m1!==void 0||y1!==void 0)&&(w1=(X=i1.getBounds((m1??0)+P,y1??0))!=null?X:w1,w1.width===0||w1.height===0))return;let ct=t1.getBoundingClientRect(),k1=ct.width/t1.offsetWidth;if(N1!==void 0&&(w1={...w1,x:N1-ct.left-z.current.scrollLeft,width:1}),Y1!==void 0&&(w1={...w1,y:Y1+ct.top-z.current.scrollTop,height:1}),w1!==void 0){let rt={x:w1.x-T,y:w1.y-J,width:w1.width+2*T,height:w1.height+2*J},gt=0;for(let zt=0;ztrt.x?A1=rt.x-kt:i0rt.y?at=rt.y-Rt:ft{var E;let T=_1[M];if(((E=T?.trailingRowOptions)==null?void 0:E.disabled)===!0)return;let J=s1?.(),K,X=!0;J!==void 0&&(K=await J,K==="top"&&(X=!1),typeof K=="number"&&(X=!1));let i1=0,t1=()=>{if(n6.current<=V){i1<500&&window.setTimeout(t1,i1),i1=50+i1*2;return}let m1=typeof K=="number"?K:X?V:0;Kt(M-P,m1),c0({cell:[M,m1],range:{x:M,y:m1,width:1,height:1}},!1,!1,"edit");let y1=r6.current([M-P,m1]);y1.allowOverlay&&gr(y1)&&y1.readonly!==!0&&A&&window.setTimeout(()=>{e6.current(M,m1)},0)};t1()},[_1,s1,P,V,Kt,c0]),ui=$.useCallback(M=>{var A,E,T;let J=(T=(E=(A=E1[M])==null?void 0:A.trailingRowOptions)==null?void 0:E.targetColumn)!=null?T:wt?.targetColumn;if(typeof J=="number")return J+(s2?1:0);if(typeof J=="object"){let K=L.indexOf(J);if(K>=0)return K+(s2?1:0)}},[E1,L,s2,wt?.targetColumn]),ja=$.useRef(),f4=$.useRef(),Cr=$.useCallback((M,A)=>{var E;let[T,J]=A;return{...S,...(E=_1[T])==null?void 0:E.themeOverride,...H?.(J),...M.themeOverride}},[H,_1,S]),Br=$.useCallback(M=>{var A,E,T,J;let K=E5.value?M.metaKey:M.ctrlKey,X=K&&C1==="multi",i1=K&&I==="multi",[t1,m1]=M.location,y1=q.columns,N1=q.rows,[Y1,w1]=(E=(A=q.current)==null?void 0:A.cell)!=null?E:[];if(M.kind==="cell"){if(f4.current=void 0,be.current=[t1,m1],t1===0&&s2){if(H0===!0&&m1===V||s==="number"||C1==="none")return;let A1=F0(M.location);if(A1.kind!==o2.Marker)return;if(la!==void 0){let k1=z1(A1);i2(k1?.kind===o2.Marker);let rt=(T=k1?.onClick)==null?void 0:T.call(k1,{...M,cell:A1,posX:M.localEventX,posY:M.localEventY,bounds:M.bounds,theme:Cr(A1,M.location),preventDefault:()=>{}});if(rt===void 0||rt.checked===A1.checked)return}v(void 0),Gt();let at=N1.hasIndex(m1),ct=ja.current;if(C1==="multi"&&(M.shiftKey||M.isLongTouch===!0)&&ct!==void 0&&N1.hasIndex(ct)){let k1=[Math.min(ct,m1),Math.max(ct,m1)+1];X||St==="multi"?S0(void 0,k1,!0):S0(mt.fromSingleSelection(k1),void 0,X)}else X||M.isTouch||St==="multi"?at?S0(N1.remove(m1),void 0,!0):(S0(void 0,m1,!0),ja.current=m1):at&&N1.length===1?S0(mt.empty(),void 0,K):(S0(mt.fromSingleSelection(m1),void 0,K),ja.current=m1)}else if(t1>=P&&H0&&m1===V){let A1=ui(t1);u4(A1??t1)}else if(Y1!==t1||w1!==m1){let A1=F0(M.location),at=z1(A1);if(at?.onSelect!==void 0){let rt=!1;if(at.onSelect({...M,cell:A1,posX:M.localEventX,posY:M.localEventY,bounds:M.bounds,preventDefault:()=>rt=!0,theme:Cr(A1,M.location)}),rt)return}let ct=V2&&m1===V,k1=V2&&q!==void 0&&((J=q.current)==null?void 0:J.cell[1])===V;if((M.shiftKey||M.isLongTouch===!0)&&Y1!==void 0&&w1!==void 0&&q.current!==void 0&&!k1){if(ct)return;let rt=Math.min(t1,Y1),gt=Math.max(t1,Y1),Vt=Math.min(m1,w1),kt=Math.max(m1,w1);c0({...q.current,range:{x:rt,y:Vt,width:gt-rt+1,height:kt-Vt+1}},!0,K,"click"),ja.current=void 0,Gt()}else c0({cell:[t1,m1],range:{x:t1,y:m1,width:1,height:1}},!0,K,"click"),ja.current=void 0,v(void 0),Gt()}}else if(M.kind==="header")if(be.current=[t1,m1],v(void 0),s2&&t1===0)ja.current=void 0,f4.current=void 0,C1==="multi"&&(N1.length!==V?S0(mt.fromSingleSelection([0,V]),void 0,K):S0(mt.empty(),void 0,K),Gt());else{let A1=f4.current;if(I==="multi"&&(M.shiftKey||M.isLongTouch===!0)&&A1!==void 0&&y1.hasIndex(A1)){let at=[Math.min(A1,t1),Math.max(A1,t1)+1];i1?v0(void 0,at,K):v0(mt.fromSingleSelection(at),void 0,K)}else i1?(y1.hasIndex(t1)?v0(y1.remove(t1),void 0,K):v0(void 0,t1,K),f4.current=t1):I!=="none"&&(v0(mt.fromSingleSelection(t1),void 0,K),f4.current=t1);ja.current=void 0,Gt()}else M.kind===w2?be.current=[t1,m1]:M.kind===O5&&(J0(F5,!1),v(void 0),Gt(),Mt?.(),ja.current=void 0,f4.current=void 0)},[u4,I,Gt,z1,ui,F0,q,s2,V2,Mt,la,P,s,C1,St,V,c0,J0,v0,S0,H0,Cr]),ao=$.useRef(!1),be=$.useRef(),i6=$.useRef(_t),f2=$.useRef(),Rm=$.useCallback(M=>{var A,E;if(p4.current=!1,i6.current=ut.current,M.button!==0&&M.button!==1){f2.current=void 0;return}let T=performance.now(),J=T-((E=(A=f2.current)==null?void 0:A.time)!=null?E:-1e3)<250;f2.current={wasDoubleClick:J,button:M.button,time:T,location:M.location},M?.kind==="header"&&(ao.current=!0);let K=M.kind==="cell"&&M.isFillHandle;!K&&M.kind!=="cell"&&M.isEdge||(p({previousSelection:q,fillHandle:K}),be.current=void 0,!M.isTouch&&M.button===0?Br(M):!M.isTouch&&M.button===1&&(be.current=M.location))},[q,Br]),[eo,ro]=$.useState(),l6=$.useCallback(M=>{if(M.kind!==w2||I!=="multi")return;let A=E5.value?M.metaKey:M.ctrlKey,[E]=M.location,T=q.columns;if(E=P&&Zn(J.group,_1[i1].group);i1--)K--;for(let i1=E+1;i1<_1.length&&Zn(J.group,_1[i1].group);i1++)X++;if(Gt(),A)if(T.hasAll([K,X+1])){let i1=T;for(let t1=K;t1<=X;t1++)i1=i1.remove(t1);v0(i1,void 0,A)}else v0(void 0,[K,X+1],A);else v0(mt.fromSingleSelection([K,X+1]),void 0,A)},[I,Gt,q.columns,_1,P,v0]),fi=$.useCallback(M=>{var A;if(q.current===void 0)return;let E=[],T=q.current.range;for(let J=0;J({cell:J.location})))},[F0,q,A0]),p4=$.useRef(!1),pi=$.useCallback(async(M,A=!1)=>{var E;if((((E=f2.current)==null?void 0:E.wasDoubleClick)===!0||A)&&P0!==void 0&&ya!==void 0){let T=ut.current.y,J=ut.current.height,K=P0({x:M,y:T,width:1,height:Math.min(J,V-T)},R2.current.signal);typeof K!="object"&&(K=await K());let X=E1[M-P],t1=document.createElement("canvas").getContext("2d",{alpha:!1});if(t1!==null){t1.font=`${S.baseFontStyle} ${S.fontFamily}`;let m1=Iz(t1,S,X,0,K,wa,Ua,!1,z1);ya?.(X,m1.width,M,m1.width)}}},[E1,P0,Ua,S,wa,ya,P,V,z1]),[ym,o6]=$.useState(),Cm=$.useCallback((M,A)=>{var E,T,J;let K=u;if(p(void 0),o6(void 0),ao.current=!1,A)return;if(K?.fillHandle===!0&&q.current!==void 0){fi(q.current.cell[1]!==q.current.range.y);return}let[X,i1]=M.location,[t1,m1]=(E=be.current)!=null?E:[],y1=()=>{p4.current=!0},N1=w1=>{var A1,at,ct;if((w1.isTouch||t1===X&&m1===i1)&&k?.([X-P,i1],{...w1,preventDefault:y1}),w1.button===1)return!p4.current;if(!p4.current){let k1=F0(M.location),rt=z1(k1);if(rt!==void 0&&rt.onClick!==void 0){let gt=rt.onClick({...w1,cell:k1,posX:w1.localEventX,posY:w1.localEventY,bounds:w1.bounds,theme:Cr(k1,M.location),preventDefault:y1});gt!==void 0&&!we(gt)&&Da(gt)&&(A0([{location:w1.location,value:gt}]),(A1=G1.current)==null||A1.damage([{cell:w1.location}]))}if(!p4.current&&((ct=(at=K?.previousSelection)==null?void 0:at.current)==null?void 0:ct.cell)!==void 0&&q.current!==void 0){let[gt,Vt]=q.current.cell,[kt,i0]=K.previousSelection.current.cell;if(X===gt&&X===kt&&i1===Vt&&i1===i0)return b?.([X-P,i1]),yr(w1.bounds,!1),!0}}return!1},Y1=M.location[0]-P;if(M.isTouch){let w1=ut.current,A1=i6.current;if(w1.x!==A1.x||w1.y!==A1.y)return;if(M.isLongTouch===!0){if(M.kind==="cell"&&((T=q?.current)==null?void 0:T.cell[0])===X&&((J=q?.current)==null?void 0:J.cell[1])===i1){O?.([Y1,M.location[1]],{...M,preventDefault:y1});return}else if(M.kind==="header"&&q.columns.hasIndex(X)){W?.(Y1,{...M,preventDefault:y1});return}else if(M.kind===w2){if(Y1<0)return;p1?.(Y1,{...M,preventDefault:y1});return}}M.kind==="cell"?N1(M)||Br(M):M.kind===w2?d1?.(Y1,{...M,preventDefault:y1}):(M.kind===xe&&n1?.(Y1,{...M,preventDefault:y1}),Br(M));return}if(M.kind==="header"){if(Y1<0)return;M.isEdge?pi(X):M.button===0&&X===t1&&i1===m1&&n1?.(Y1,{...M,preventDefault:y1})}if(M.kind===w2){if(Y1<0)return;M.button===0&&X===t1&&i1===m1&&(d1?.(Y1,{...M,preventDefault:y1}),p4.current||l6(M))}M.kind==="cell"&&(M.button===0||M.button===1)&&N1(M),be.current=void 0},[u,P,q,k,fi,F0,z1,Cr,A0,b,yr,O,W,p1,Br,d1,pi,n1,l6]),Bm=$.useCallback(M=>{let A={...M,location:[M.location[0]-P,M.location[1]]};u1?.(A),o6(E=>{var T,J;return ao.current?[M.scrollEdge[0],0]:M.scrollEdge[0]===E?.[0]&&M.scrollEdge[1]===E[1]?E:u===void 0||((J=(T=f2.current)==null?void 0:T.location[0])!=null?J:0){Et?.(M-P,A)},[Et,P]),Ba=(n=q?.current)==null?void 0:n.cell,Am=$.useCallback((M,A,E,T,J,K)=>{xt.current=!1;let X=Ba;X!==void 0&&(X=[X[0]-P,X[1]]);let i1={x:M.x-P,y:M.y,width:M.width,height:H0&&M.y+M.height>=V?M.height-1:M.height,tx:J,ty:K,extras:{selected:X,freezeRegion:Q1===0?void 0:{x:0,y:M.y,width:Q1,height:M.height}}};ut.current=i1,Ca(i1),b1([A,E,T]),Z0?.(i1,i1.tx,i1.ty,i1.extras)},[Ba,P,H0,V,Q1,Ca,Z0]),Fm=jn(x1,$.useCallback((M,A)=>{x1?.(M-P,A-P),I!=="none"&&v0(mt.fromSingleSelection(A),void 0,!0)},[I,x1,P,v0])),no=$.useRef(!1),km=$.useCallback(M=>{if(M.location[0]===0&&P>0){M.preventDefault();return}e1?.({...M,location:[M.location[0]-P,M.location[1]]}),M.defaultPrevented()||(no.current=!0),p(void 0)},[e1,P]),bm=$.useCallback(()=>{no.current=!1},[]),Em=$.useCallback(M=>{var A,E;if(!(((A=f2?.current)==null?void 0:A.button)!==void 0&&f2.current.button>=1)){if(u!==void 0&&((E=f2.current)==null?void 0:E.location[0])===0&&M.location[0]===0&&P===1&&C1==="multi"&&u.previousSelection&&!u.previousSelection.rows.hasIndex(f2.current.location[1])&&q.rows.hasIndex(f2.current.location[1])){let T=Math.min(f2.current.location[1],M.location[1]),J=Math.max(f2.current.location[1],M.location[1])+1;S0(mt.fromSingleSelection([T,J]),void 0,!1)}if(u!==void 0&&q.current!==void 0&&!no.current&&(D==="rect"||D==="multi-rect")){let[T,J]=q.current.cell,[K,X]=M.location;if(X<0&&(X=ut.current.y),V2&&J===V)return;if(V2&&X===V)if(M.kind===O5)X--;else return;K=Math.max(K,P);let m1=K-T,y1=X-J,N1={x:m1>=0?T:K,y:y1>=0?J:X,width:Math.abs(m1)+1,height:Math.abs(y1)+1};c0({...q.current,range:N1},!0,!1,"drag")}Jt?.({...M,location:[M.location[0]-P,M.location[1]]})}},[u,P,C1,q,D,Jt,S0,V2,V,c0]),Ee=$.useCallback(M=>{if(q.current===void 0)return;let[A,E]=M,[T,J]=q.current.cell,K=q.current.range,X=K.x,i1=K.x+K.width,t1=K.y,m1=K.y+K.height;if(E!==0)switch(E){case 2:{m1=V,t1=J,Kt(0,m1,"vertical");break}case-2:{t1=0,m1=J+1,Kt(0,t1,"vertical");break}case 1:{t1J+1?(m1--,Kt(0,m1,"vertical")):(t1=Math.max(0,t1-1),Kt(0,t1,"vertical"));break}default:sr(E)}if(A!==0)if(A===2)i1=_1.length,X=T,Kt(i1-1-P,0,"horizontal");else if(A===-2)X=P,i1=T+1,Kt(X-P,0,"horizontal");else{let y1=[];if(P0!==void 0){let N1=P0({x:X,y:t1,width:i1-X-P,height:m1-t1},R2.current.signal);typeof N1=="object"&&(y1=p_(N1))}if(A===1){let N1=!1;if(X0){let Y1=(0,i4.default)(X+1,T+1).find(w1=>!y1.includes(w1-P));Y1!==void 0&&(X=Y1,N1=!0)}else X++,N1=!0;N1&&Kt(X,0,"horizontal")}N1||(i1=Math.min(_1.length,i1+1),Kt(i1-1-P,0,"horizontal"))}else if(A===-1){let N1=!1;if(i1>T+1){if(y1.length>0){let Y1=(0,i4.default)(i1-1,T,-1).find(w1=>!y1.includes(w1-P));Y1!==void 0&&(i1=Y1,N1=!0)}else i1--,N1=!0;N1&&Kt(i1-P,0,"horizontal")}N1||(X=Math.max(P,X-1),Kt(X-P,0,"horizontal"))}else sr(A)}c0({cell:q.current.cell,range:{x:X,y:t1,width:i1-X,height:m1-t1}},!0,!1,"keyboard-select")},[P0,q,_1.length,P,V,Kt,c0]),qa=$.useCallback((M,A,E,T)=>{let J=n0-(E?0:1);if(M=(0,Gn.default)(M,P,E1.length-1+P),A=(0,Gn.default)(A,0,J),M===Ba?.[0]&&A===Ba?.[1])return!1;if(T&&q.current!==void 0){let K=[...q.current.rangeStack];(q.current.range.width>1||q.current.range.height>1)&&K.push(q.current.range),J0({...q,current:{cell:[M,A],range:{x:M,y:A,width:1,height:1},rangeStack:K}},!0)}else c0({cell:[M,A],range:{x:M,y:A,width:1,height:1}},!0,!1,"keyboard-nav");return w.current!==void 0&&w.current[0]===M&&w.current[1]===A&&(w.current=void 0),Kt(M-P,A),!0},[n0,P,E1.length,Ba,q,Kt,J0,c0]),_m=$.useCallback((M,A)=>{c?.cell!==void 0&&M!==void 0&&Da(M)&&(A0([{location:c.cell,value:M}]),window.requestAnimationFrame(()=>{var J;(J=G1.current)==null||J.damage([{cell:c.cell}])})),Gt(!0),v(void 0);let[E,T]=A;if(q.current!==void 0&&(E!==0||T!==0)){let J=q.current.cell[1]===n0-1&&M!==void 0;qa((0,Gn.default)(q.current.cell[0]+E,0,_1.length-1),(0,Gn.default)(q.current.cell[1]+T,0,n0-1),J,!1)}F?.(M,A)},[c?.cell,Gt,q,F,A0,n0,qa,_1.length]),io=$.useMemo(()=>`gdg-overlay-${f_++}`,[]),Sr=$.useCallback(M=>{(async()=>{var E,T,J,K,X;let i1=!1;if(X1!==void 0&&X1({...M,cancel:()=>{i1=!0}}),i1)return;let t1=()=>{M.stopPropagation(),M.preventDefault()},m1=c!==void 0,{altKey:y1,shiftKey:N1,metaKey:Y1,ctrlKey:w1,key:A1,bounds:at}=M,ct=E5.value,k1=ct?Y1:w1,rt=A1==="Delete"||ct&&A1==="Backspace",gt=ut.current,Vt=q.columns,kt=q.rows;if(A1==="Escape"){m1?v(void 0):Lt.clear&&(J0(F5,!1),Mt?.());return}else if(T0("primary+a",M)&&Lt.selectAll){if(!m1)J0({columns:mt.empty(),rows:mt.empty(),current:{cell:(T=(E=q.current)==null?void 0:E.cell)!=null?T:[P,0],range:{x:P,y:0,width:L.length,height:V},rangeStack:[]}},!1);else{let zt=document.getElementById(io);if(zt!==null){let f0=window.getSelection(),k0=document.createRange();k0.selectNodeContents(zt),f0?.removeAllRanges(),f0?.addRange(k0)}}t1();return}else T0("primary+f",M)&&Lt.search&&(t1(),(J=g?.current)==null||J.focus({preventScroll:!0}),gi(!0));function i0(zt){var f0,k0,Ar,z4;Gt();let _e=[];for(let Te=zt.x;Te({cell:Te.location})))}if(rt){let zt=(K=Rr?.(q))!=null?K:!0;if(t1(),zt!==!1){let f0=zt===!0?q:zt;if(f0.current!==void 0){i0(f0.current.range);for(let k0 of f0.current.rangeStack)i0(k0)}for(let k0 of f0.rows)i0({x:P,y:k0,width:_1.length-P,height:1});for(let k0 of f0.columns)i0({x:k0,y:0,width:1,height:V})}return}if(q.current===void 0)return;let[Rt,ft]=q.current.cell,q0=!1;if(Lt.selectColumn&&T0("ctrl+ ",M)&&I!=="none")Vt.hasIndex(Rt)?v0(Vt.remove(Rt),void 0,!0):I==="single"?v0(mt.fromSingleSelection(Rt),void 0,!0):v0(void 0,Rt,!0);else if(Lt.selectRow&&T0("shift+ ",M)&&C1!=="none")kt.hasIndex(ft)?S0(kt.remove(ft),void 0,!0):C1==="single"?S0(mt.fromSingleSelection(ft),void 0,!0):S0(void 0,ft,!0);else if((T0("Enter",M)||T0(" ",M)||T0("shift+Enter",M))&&at!==void 0)m1?(v(void 0),T0("Enter",M)?ft++:T0("shift+Enter",M)&&ft--):ft===V&&H0?window.setTimeout(()=>{let zt=ui(Rt);u4(zt??Rt)},0):(b?.([Rt-P,ft]),yr(at,!0),t1());else if(Lt.downFill&&T0("primary+_68",M)&&q.current.range.height>1)fi(!1),t1();else if(Lt.rightFill&&T0("primary+_82",M)&&q.current.range.width>1){let zt=[],f0=q.current.range;for(let k0=0;k0({cell:k0.location}))),t1()}else if(Lt.pageDown&&T0("PageDown",M))ft+=Math.max(1,ut.current.height-4),t1();else if(Lt.pageUp&&T0("PageUp",M))ft-=Math.max(1,ut.current.height-4),t1();else if(Lt.first&&T0("primary+Home",M))v(void 0),ft=0,Rt=0;else if(Lt.last&&T0("primary+End",M))v(void 0),ft=Number.MAX_SAFE_INTEGER,Rt=Number.MAX_SAFE_INTEGER;else if(Lt.first&&T0("primary+shift+Home",M))v(void 0),Ee([-2,-2]);else if(Lt.last&&T0("primary+shift+End",M))v(void 0),Ee([2,2]);else if(A1==="ArrowDown"){if(w1&&y1)return;v(void 0),N1&&(D==="rect"||D==="multi-rect")?Ee([0,k1&&!y1?2:1]):(y1&&!k1&&(q0=!0),k1&&!y1?ft=V-1:ft+=1)}else if(A1==="ArrowUp"||A1==="Home"){let zt=A1==="Home"||k1;v(void 0),N1&&(D==="rect"||D==="multi-rect")?Ee([0,zt&&!y1?-2:-1]):(y1&&!zt&&(q0=!0),ft+=zt&&!y1?Number.MIN_SAFE_INTEGER:-1)}else if(A1==="ArrowRight"||A1==="End"){let zt=A1==="End"||k1;v(void 0),N1&&(D==="rect"||D==="multi-rect")?Ee([zt&&!y1?2:1,0]):(y1&&!zt&&(q0=!0),Rt+=zt&&!y1?Number.MAX_SAFE_INTEGER:1)}else if(A1==="ArrowLeft")v(void 0),N1&&(D==="rect"||D==="multi-rect")?Ee([k1&&!y1?-2:-1,0]):(y1&&!k1&&(q0=!0),Rt+=k1&&!y1?Number.MIN_SAFE_INTEGER:-1);else if(A1==="Tab")v(void 0),N1?Rt--:Rt++;else if(!Y1&&!w1&&q.current!==void 0&&A1.length===1&&/[ -~]/g.test(A1)&&at!==void 0&&gr(C([Rt-P,Math.max(0,ft-1)]))){if((!V2||ft!==V)&&(gt.y>ft||ft>gt.y+gt.height||gt.x>Rt||Rt>gt.x+gt.width))return;yr(at,!0,A1),t1()}qa(Rt,ft,!1,q0)&&t1()})()},[X1,c,q,Lt.selectAll,Lt.search,Lt.selectColumn,Lt.selectRow,Lt.downFill,Lt.rightFill,Lt.pageDown,Lt.pageUp,Lt.first,Lt.last,Lt.clear,I,C1,C,P,qa,J0,Mt,L.length,V,io,Gt,A0,z1,Rr,_1.length,v0,S0,H0,ui,u4,b,yr,fi,F0,Ee,D,V2]),Tm=$.useCallback((M,A)=>{let E=M.location[0]-P;if(M.kind==="header"&&W?.(E,{...M,preventDefault:A}),M.kind===w2){if(E<0)return;p1?.(E,{...M,preventDefault:A})}if(M.kind==="cell"){let[T,J]=M.location;O?.([E,J],{...M,preventDefault:A}),ck(q,M.location)||qa(T,J,!1,!1)}},[q,O,p1,W,P,qa]),lo=$.useCallback(async M=>{var A,E,T,J,K,X,i1;if(!Lt.paste)return;function t1(w1,A1,at){var ct,k1;if(!we(w1)&&gr(w1)&&w1.readonly!==!0){let rt=_?.(at,w1);if(rt!==void 0&&Da(rt))return rt.kind!==w1.kind&&console.warn("Coercion should not change cell kind."),{location:A1,value:rt};let gt=z1(w1);if(gt===void 0)return;if(gt.kind===l1.Custom){i2(w1.kind===l1.Custom);let Vt=(ct=gt.onPaste)==null?void 0:ct.call(gt,at,w1.data);return Vt===void 0?void 0:{location:A1,value:{...w1,data:Vt}}}else{let Vt=(k1=gt.onPaste)==null?void 0:k1.call(gt,at,w1);return Vt===void 0?void 0:(i2(Vt.kind===w1.kind),{location:A1,value:Vt})}}}let m1=q.columns,y1=q.rows,N1=((A=z.current)==null?void 0:A.contains(document.activeElement))===!0||((E=d.current)==null?void 0:E.contains(document.activeElement))===!0,Y1=(T=q.current)==null?void 0:T.cell;if(Y1===void 0&&m1.length===1&&(Y1=[(J=m1.first())!=null?J:0,0]),Y1===void 0&&y1.length===1&&(Y1=[P,(K=y1.first())!=null?K:0]),N1&&Y1!==void 0){let w1,A1,at="text/plain",ct="text/html";if(navigator.clipboard.read!==void 0){let Vt=await navigator.clipboard.read();for(let kt of Vt){if(kt.types.includes(ct)){let Rt=await(await kt.getType(ct)).text(),ft=document.createElement("html");ft.innerHTML=Rt;let q0=ft.querySelector("table");if(q0!==null){w1=jp(q0);break}}kt.types.includes(at)&&(A1=await(await kt.getType(at)).text())}}else if(navigator.clipboard.readText!==void 0)A1=await navigator.clipboard.readText();else if(M!==void 0&&M?.clipboardData!==null){if(M.clipboardData.types.includes(ct)){let Vt=M.clipboardData.getData(ct),kt=document.createElement("html");kt.innerHTML=Vt;let i0=kt.querySelector("table");i0!==null&&(w1=jp(i0))}w1===void 0&&M.clipboardData.types.includes(at)&&(A1=M.clipboardData.getData(at))}else return;let[k1,rt]=Y1,gt=[];do{if(M1===void 0){let Vt=F0(Y1),kt=t1(Vt,Y1,(X=A1??w1?.map(i0=>i0.join(" ")).join(" "))!=null?X:"");kt!==void 0&>.push(kt);break}if(w1===void 0){if(A1===void 0)return;w1=yE(A1)}if(M1===!1||typeof M1=="function"&&M1?.([Y1[0]-P,Y1[1]],w1)!==!0)return;for(let[Vt,kt]of w1.entries()){if(Vt+rt>=V)break;for(let[i0,Rt]of kt.entries()){let ft=[i0+k1,Vt+rt],q0=F0(ft),Ga=t1(q0,ft,Rt);Ga!==void 0&>.push(Ga)}}}while(!1);A0(gt),(i1=G1.current)==null||i1.damage(gt.map(Vt=>({cell:Vt.location})))}},[_,z1,F0,q,Lt.paste,A0,M1,P,V]);W0("paste",lo,window,!1,!0);let oo=$.useCallback(async(M,A)=>{var E,T;if(!Lt.copy)return;let J=A===!0||((E=z.current)==null?void 0:E.contains(document.activeElement))===!0||((T=d.current)==null?void 0:T.contains(document.activeElement))===!0,K=q.columns,X=q.rows,i1=(t1,m1)=>{if(!I1)qp(t1,m1,M);else{let y1=m1.map(N1=>({kind:l1.Text,data:L[N1].title,displayData:L[N1].title,allowOverlay:!1}));qp([y1,...t1],m1,M)}};if(J&&P0!==void 0){if(q.current!==void 0){let t1=P0(q.current.range,R2.current.signal);typeof t1!="object"&&(t1=await t1()),i1(t1,(0,i4.default)(q.current.range.x-P,q.current.range.x+q.current.range.width-P))}else if(X!==void 0&&X.length>0){let m1=[...X].map(y1=>{let N1=P0({x:P,y:y1,width:L.length,height:1},R2.current.signal);return typeof N1=="object"?N1[0]:N1().then(Y1=>Y1[0])});if(m1.some(y1=>y1 instanceof Promise)){let y1=await Promise.all(m1);i1(y1,(0,i4.default)(L.length))}else i1(m1,(0,i4.default)(L.length))}else if(K.length>0){let t1=[],m1=[];for(let y1 of K){let N1=P0({x:y1,y:0,width:1,height:V},R2.current.signal);typeof N1!="object"&&(N1=await N1()),t1.push(N1),m1.push(y1-P)}if(t1.length===1)i1(t1[0],m1);else{let y1=t1.reduce((N1,Y1)=>N1.map((w1,A1)=>[...w1,...Y1[A1]]));i1(y1,m1)}}}},[L,P0,q,Lt.copy,P,V,I1]);W0("copy",oo,window,!1,!1);let Pm=$.useCallback((M,A)=>{if(K1!==void 0){P!==0&&(M=M.map(J=>[J[0]-P,J[1]])),K1(M,A);return}if(M.length===0||A===-1)return;let[E,T]=M[A];w.current!==void 0&&w.current[0]===E&&w.current[1]===T||(w.current=[E,T],qa(E,T,!1,!1))},[K1,P,qa]),[zi,mi]=(l=(i=B0?.current)==null?void 0:i.cell)!=null?l:[],h6=$.useRef(Kt);h6.current=Kt,$.useLayoutEffect(()=>{var M,A,E,T;!xt.current&&zi!==void 0&&mi!==void 0&&(zi!==((A=(M=Ra.current)==null?void 0:M.current)==null?void 0:A.cell[0])||mi!==((T=(E=Ra.current)==null?void 0:E.current)==null?void 0:T.cell[1]))&&h6.current(zi,mi),xt.current=!1},[zi,mi]);let c6=q.current!==void 0&&(q.current.cell[0]>=_1.length||q.current.cell[1]>=n0);$.useLayoutEffect(()=>{c6&&J0(F5,!1)},[c6,J0]);let Im=$.useMemo(()=>H0===!0&&wt?.tint===!0?mt.fromSingleSelection(n0-1):mt.empty(),[n0,H0,wt?.tint]),Om=$.useCallback(M=>{var A;return typeof c2=="boolean"?c2:(A=c2?.(M-P))!=null?A:!0},[P,c2]),Dm=$.useMemo(()=>{if(eo===void 0||d.current===null)return null;let{bounds:M,group:A}=eo,E=d.current.getBoundingClientRect();return $.createElement(ME,{bounds:M,group:A,canvasBounds:E,onClose:()=>ro(void 0),onFinish:T=>{ro(void 0),o1?.(A,T)}})},[o1,eo]),Nm=Math.min(_1.length,Q1+(s2?1:0));$.useImperativeHandle(a,()=>({appendRow:(M,A)=>u4(M+P,A),updateCells:M=>{var A;return P!==0&&(M=M.map(E=>({cell:[E.cell[0]+P,E.cell[1]]}))),(A=G1.current)==null?void 0:A.damage(M)},getBounds:(M,A)=>{var E;return(E=G1.current)==null?void 0:E.getBounds(M+P,A)},focus:()=>{var M;return(M=G1.current)==null?void 0:M.focus()},emit:async M=>{switch(M){case"delete":Sr({bounds:void 0,cancel:()=>{},stopPropagation:()=>{},preventDefault:()=>{},ctrlKey:!1,key:"Delete",keyCode:46,metaKey:!1,shiftKey:!1,altKey:!1,rawEvent:void 0,location:void 0});break;case"fill-right":Sr({bounds:void 0,cancel:()=>{},stopPropagation:()=>{},preventDefault:()=>{},ctrlKey:!0,key:"r",keyCode:82,metaKey:!1,shiftKey:!1,altKey:!1,rawEvent:void 0,location:void 0});break;case"fill-down":Sr({bounds:void 0,cancel:()=>{},stopPropagation:()=>{},preventDefault:()=>{},ctrlKey:!0,key:"d",keyCode:68,metaKey:!1,shiftKey:!1,altKey:!1,rawEvent:void 0,location:void 0});break;case"copy":await oo(void 0,!0);break;case"paste":await lo();break}},scrollTo:Kt,remeasureColumns:M=>{for(let A of M)pi(A+P,!0)}}),[u4,pi,oo,Sr,lo,P,Kt]);let[v6,g6]=Ba??[],$m=$.useCallback(M=>{let[A,E]=M;if(E===-1){I!=="none"&&(v0(mt.fromSingleSelection(A),void 0,!1),Gt());return}v6===A&&g6===E||(c0({cell:M,range:{x:A,y:E,width:1,height:1}},!0,!1,"keyboard-nav"),Kt(A,E))},[I,Gt,Kt,v6,g6,c0,v0]),[Um,Wm]=$.useState(!1),d6=$.useRef((0,az.default)(M=>{Wm(M)},5)),jm=$.useCallback(()=>{d6.current(!0),q.current===void 0&&q.columns.length===0&&q.rows.length===0&&u===void 0&&c0({cell:[P,u2],range:{x:P,y:u2,width:1,height:1}},!0,!1,"keyboard-select")},[u2,q,u,P,c0]),qm=$.useCallback(()=>{d6.current(!1)},[]),[Gm,Km]=$.useMemo(()=>{var M;let A,E=(M=Ht?.scrollbarWidthOverride)!=null?M:kk(),T=V+(H0?1:0);if(typeof M0=="number")A=$1+T*M0;else{let K=0,X=Math.min(T,10);for(let i1=0;i1X.width+K,0)+E;return[`${Math.min(1e5,J)}px`,`${Math.min(1e5,A)}px`]},[_1,Ht?.scrollbarWidthOverride,M0,V,H0,$1]);return $.createElement(oz.Provider,{value:S},$.createElement(kE,{style:iz(S),className:a1,inWidth:y??Gm,inHeight:R??Km},$.createElement(pE,{fillHandle:ri,drawFocusRing:u0,experimental:Ht,fixedShadowX:m0,fixedShadowY:j5,getRowThemeOverride:H,headerIcons:ia,imageWindowLoader:ni,initialSize:xr,isDraggable:Se,onDragLeave:Ae,onRowMoved:la,overscrollX:vi,overscrollY:K5,preventDiagonalScrolling:xa,rightElement:q5,rightElementProps:ii,showMinimap:G5,smoothScrollX:li,smoothScrollY:c4,className:a1,enableGroups:h1,onCanvasFocused:jm,onCanvasBlur:qm,canvasRef:d,onContextMenu:Tm,theme:S,cellXOffset:B2,cellYOffset:u2,accessibilityHeight:_t.height,onDragEnd:bm,columns:_1,drawCustomCell:v1,drawHeader:s4,disabledRows:Im,freezeColumns:Nm,lockColumns:P,firstColAccessible:P===0,getCellContent:F0,minColumnWidth:wa,maxColumnWidth:Ua,searchInputRef:g,showSearch:Y5,onSearchClose:Q5,highlightRegions:Vm,getCellsForSelection:P0,getGroupDetails:to,headerHeight:Va,isFocused:Um,groupHeaderHeight:h1?g4:0,trailingRowType:H0?wt?.sticky===!0?"sticky":"appended":"none",onColumnResize:ya,onColumnResizeEnd:J5,onColumnResizeStart:Vr,onCellFocused:$m,onColumnMoved:Fm,onDragStart:km,onHeaderMenuClick:Sm,onItemHovered:Em,isFilling:u?.fillHandle===!0,onMouseMove:Bm,onKeyDown:Sr,onKeyUp:Y,onMouseDown:Rm,onMouseUp:Cm,onDragOverCell:v2,onDrop:$a,onSearchResultsChanged:Pm,onVisibleRegionChanged:Am,clientSize:[G[0],G[1]],rowHeight:M0,searchResults:W1,searchValue:T1,onSearchValueChange:Bt,rows:n0,scrollRef:z,selection:q,translateX:_t.tx,translateY:_t.ty,verticalBorder:Om,gridRef:G1,getCellRenderer:z1,scrollToEnd:Fe}),Dm,c!==void 0&&$.createElement(Lk,{...c,validateCell:di,id:io,getCellRenderer:z1,className:Ht?.isSubGrid===!0?"click-outside-ignore":void 0,provideEditor:h0,imageEditorOverride:m,onFinishEditing:_m,markdownDivCreateNode:x,isOutsideClick:J8})))},Yz=$.forwardRef(z_);var mr=F1(U1());var j8=F1(U1()),q8={color:void 0,size:void 0,className:void 0,style:void 0,attr:void 0},G8=j8.default.createContext&&j8.default.createContext(q8);var Ce=function(){return Ce=Object.assign||function(t){for(var a,e=1,r=arguments.length;et.length)&&(a=t.length);for(var e=0,r=new Array(a);e=t.length?{done:!0}:{done:!1,value:t[r++]}}}throw new TypeError(`Invalid attempt to iterate non-iterable instance. +In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function om(t){var a=(0,Z1.useRef)(null);function e(r){!r||r===a.current||(a.current=r,t(r))}return e}function L_(t){var a=(0,Z1.useRef)(t);return(0,Z1.useMemo)(function(){function e(n){typeof n=="function"?a.current=n(a.current):a.current=n}function r(){return a.current}return[r,e]},[])}function V_(){var t=(0,Z1.useRef)([]);return(0,Z1.useMemo)(function(){function a(){return t.current.length>0}function e(){for(var n=Hr(t.current),i;!(i=n()).done;){var l=i.value;l()}t.current=[]}function r(n){t.current.push(n)}return{hasEventSubscriptions:a,removeAllEventSubscriptions:e,addEventSubscription:r}},[])}var K8=typeof window<"u"?Z1.useLayoutEffect:Z1.useEffect;function R_(t,a){var e=(0,Z1.useRef)(t);return a?(e.current=t,e):(e.current=null,e)}function ei(t){return parseFloat(t.replace("px",""))}function Y8(t,a,e){return te?e:t}function hm(t){return t!=null}function cm(){for(var t=arguments.length,a=new Array(t),e=0;e"u"))return a||t.ResizeObserver}function mm(t,a){var e=[];if(!t||!a||t===document.body)return e;var r=a.getComputedStyle(t),n=r.overflow,i=r.overflowX,l=r.overflowY;return[n,i,l].some(function(o){return["auto","scroll"].includes(o)})&&e.push(t),[].concat(e,mm(t.parentElement,a))}function $5(t){return"react-laag: Could not find a valid reference for the "+t+` element. There might be 2 causes: - Make sure that the 'ref' is set correctly on the `+t+` element when isOpen: true. Also make sure your component forwards the ref with "forwardRef()". - - Make sure that you are actually rendering the `+t+" when the isOpen prop is set to true"}function v_(t){var a=t.enabled,e=t.onChange,r=t.environment,n=t.ResizeObserverPolyfill,i=t.overflowContainer,l=t.triggerOption,o=c_(r,n);(0,Z1.useEffect)(function(){},[o]);var h=(0,Z1.useRef)(null),c=Boolean(l),v=l_({scrollContainers:[],trigger:null,layer:null}),g=v[0],s=v[1],d=o_(),p=d.hasEventSubscriptions,z=d.addEventSubscription,L=d.removeAllEventSubscriptions,u=(0,Z1.useCallback)(function(){var R=g(),S=R.layer,b=R.trigger,E=R.scrollContainers,C=E[0];if(!S)throw new Error(P5("layer"));if(!b&&!c)throw new Error(P5("trigger"));var T={top:0,left:0};if(C){var I=C.scrollLeft,J=C.scrollTop;T={top:J,left:I}}else{var W=r.scrollX,n1=r.scrollY;T={top:n1,left:W}}var i1={left:0,top:0};if(C){var g1=r.getComputedStyle(C),l1=g1.borderLeftWidth,H1=g1.borderTopWidth;i1={left:ei(l1)||0,top:ei(H1)||0}}e({layer:S,trigger:b,scrollContainers:E,arrow:h.current},T,i1)},[g,e,r,h,c]),f=(0,Z1.useCallback)(function(){var R=g(),S=R.trigger,b=R.layer,E=R.scrollContainers;if(!b)throw new Error(P5("layer"));if(!S&&!c)throw new Error(P5("trigger"));if(o){for(var C=!1,T=function(){if(!C){C=!0;return}u()},I=new o(T),J=0,W=[S,b,document.body];J=0})}},{key:"negativeSides",get:function(){var e=this;return Object.fromEntries(I5.filter(function(r){return e[r]<0}).map(function(r){return[r,e[r]]}))}}]),t}();function Kz(){for(var t=arguments.length,a=new Array(t),e=0;ef?f-y:0;z[x.prop]=U8(y+r+w,u,f),z[x.opposite.prop]=z[x.prop]+i.factor(h[s])}z.width=z.right-z.left,z.height=z.bottom-z.top;var V=J2.create(z);return r===0&&(this._cachedLayerBounds=V),V},a.getLayerCollisionBounds=function(){var r=this.offsets.container;return this.getLayerBounds().mapSides(function(n,i){return i-=n.factor(r)}).merge(function(n){var i=n.width,l=n.height;return{width:i+r*2,height:l+r*2}})},a.getContainerOffsets=function(r){if(this._cachedContainerOffsets&&!r)return this._cachedContainerOffsets;var n=this.subjectsBounds.merge({layer:r||this.getLayerCollisionBounds()}),i=j8.mergeSmallestSides(n.layerOffsetsToScrollContainers);return r||(this._cachedContainerOffsets=i),i},O5(t,[{key:"type",get:function(){return this.primary.prop+"-"+(this.secondary.prop==="center"?"center":["bottom","right"].includes(this.secondary.prop)?"end":"start")}},{key:"triggerIsBigger",get:function(){var r=this.secondary.isHorizontal,n=this.subjectsBounds,i=n.triggerHasBiggerWidth,l=n.triggerHasBiggerHeight;return r&&i||!r&&l}},{key:"fitsContainer",get:function(){return this.getContainerOffsets().allSidesArePositive}},{key:"visibleSurface",get:function(){var r=this.getLayerBounds(),n=this.getContainerOffsets(r),i=n.negativeSides;for(var l in i)i[l]=-i[l];return r.substract(i).surface}},{key:"secondaryOffsetSide",get:function(){var r,n,i=this,l=this.getContainerOffsets(),o=(r=(n=Object.entries(l.negativeSides).map(function(c){var v=c[0],g=c[1];return[S0[v],g]}).filter(function(c){var v=c[0];return i.primary.isOppositeDirection(v)}).sort(function(c,v){var g=c[1],s=v[1];return s-g}))==null?void 0:n[0])!=null?r:[],h=o[0];return h||null}}]),t}(),Xz=function(t){n_(a,t);function a(){return t.apply(this,arguments)||this}var e=a.prototype;return e.getLayerBounds=function(){var n=this.subjectsBounds,i=n.trigger,l=n.layer,o=J2.empty();return o.top=i.top+i.height/2-l.height/2,o.bottom=o.top+l.height,o.left=i.left+i.width/2-l.width/2,o.right=o.left+l.width,o.width=o.right-o.left,o.height=o.bottom-o.top,o},a}(nm);function m_(t,a,e){var r=t.layer,n=t.trigger,i=t.arrow,l=a.primary.oppositeSizeProp,o=a.primary.isHorizontal?["top","bottom"]:["left","right"],h=o[0],c=o[1],v=r[h]+r[l]/2-n[h]-i[l]/2-e,g=r[c]-r[l]/2-n[c]+i[l]/2+e;return(v<0?-v:0)+(g>0?-g:0)}var Yz={position:"absolute",willChange:"top, left",left:null,right:null,top:null,bottom:null};function M_(t,a,e){var r;if(a.primary.isCenter)return Yz;var n=t.layer,i=t.trigger,l=t.arrow,o=a.primary.oppositeSizeProp,h=i[o]>n[o],c=e+l[o]/2,v=n[o]-l[o]/2-e,g=m_(t,a,e),s=a.primary.prop,d=a.primary.oppositeCssProp,p=h?n[o]/2+g:i[d]+i[o]/2-n[d];return M2({},Yz,(r={},r[s]="100%",r[d]=U8(p,c,v),r))}var Qz=function(){function t(e,r,n){this.placements=void 0,this.config=void 0,this.subjectsBounds=void 0,this.placements=e,this.config=r,this.subjectsBounds=n}t.getSidesFromPlacementType=function(r){var n=r.split("-"),i=n[0],l=n[1],o=S0[i],h;return l==="center"?h=d0.center:o.isHorizontal?h=l==="start"?d0.top:d0.bottom:h=l==="start"?d0.left:d0.right,[o,h]},t.create=function(r,n){var i={arrow:n.arrowOffset,container:n.containerOffset,trigger:n.triggerOffset};function l(o){o===void 0&&(o=n.placement);var h=t.getSidesFromPlacementType(o),c=h[0],v=h[1],g=S0[c.isHorizontal?n.preferY:n.preferX],s=!c.isHorizontal&&r.triggerHasBiggerWidth||c.isHorizontal&&r.triggerHasBiggerHeight;function d(z,L){return new nm(z,L,r,n.layerDimensions,i)}var p=[];return p[0]=d(c,v),p[1]=d(c,v.isCenter?g:d0.center),p[2]=d(c,d0[(v.opposite.isCenter?g.opposite:v.opposite).prop]),p[3]=d(g,s?c:d0[c.opposite.prop]),p[4]=d(g,d0.center),p[5]=d(g,s?d0[c.opposite.prop]:c),p[6]=d(S0[g.opposite.prop],s?c:d0[c.opposite.prop]),p[7]=d(S0[g.opposite.prop],d0.center),p[8]=d(S0[g.opposite.prop],s?d0[c.opposite.prop]:c),p[9]=d(S0[c.opposite.prop],v),p[10]=d(S0[c.opposite.prop],v.isCenter?g:d0.center),p[11]=d(S0[c.opposite.prop],d0[(v.opposite.isCenter?g.opposite:v.opposite).prop]),p=p.filter(function(z){return z.type===n.placement||n.possiblePlacements.includes(z.type)}),p}return n.placement==="center"?new t([new Xz(d0.center,d0.center,r,n.layerDimensions,i)].concat(l(n.preferY+"-"+n.preferX)),n,r):new t(l(),n,r)};var a=t.prototype;return a.filterPlacementsBySide=function(r){return this.placements.filter(function(n){return n.primary===r})},a.findFirstPlacementThatFits=function(){return this.placements.find(function(r){return r.fitsContainer})},a.placementWithBiggestVisibleSurface=function(){var r=this.placements.map(function(i){return{placement:i,surface:i.visibleSurface}}).sort(function(i,l){return l.surface-i.surface}),n=r[0].placement;return n},a.findSuitablePlacement=function(){return this.config.auto?this.findFirstPlacementThatFits()||this.placementWithBiggestVisibleSurface():this.placements[0]},a.getSecondaryOffset=function(r){var n=this.config,i=n.auto,l=n.snap;if(!i||l||r instanceof Xz)return 0;var o=this.filterPlacementsBySide(r.primary),h=o.indexOf(r)===0;if(h&&r.fitsContainer)return 0;var c=o.find(function(z){return!z.fitsContainer});if(!c)return 0;var v=c.secondaryOffsetSide;if(!v)return 0;var g=r.getContainerOffsets(),s=r.secondary,d;r.triggerIsBigger||c===r?d=v.isPush?-1:1:d=s===d0.left||[d0.top,d0.center].includes(s)&&v.isPush?-1:1;var p=g[v.prop];return p*d},a.getStyles=function(r,n,i,l){var o={willChange:"top, left, width, height"},h=M_(this.subjectsBounds.merge({layer:r}),n,this.config.arrowOffset),c=this.config.overflowContainer?M2({},o,{position:"fixed",top:r.top,left:r.left}):M2({},o,{position:"absolute",top:r.top-this.subjectsBounds.parent.top+i.top-l.top,left:r.left-this.subjectsBounds.parent.left+i.left-l.left});return{arrow:h,layer:c}},a.getHasDisappeared=function(r){var n=this.config.overflowContainer?this.subjectsBounds.trigger:r,i=j8.mergeSmallestSides(this.subjectsBounds.offsetsToScrollContainers(n,!0)),l=Object.entries(i.negativeSides),o=l.some(function(h){var c=h[0],v=h[1],g=S0[c];return v<=-n[g.sizeProp]});return o?"full":i.allSidesArePositive?null:"partial"},a.result=function(r,n){var i=this.findSuitablePlacement(),l=this.getSecondaryOffset(i),o=i.getLayerBounds(l),h=this.getStyles(o,i,r,n),c=i.primary.prop;return{styles:h,layerSide:c,placement:i,layerBounds:o,hasDisappeared:this.getHasDisappeared(o)}},t}(),H_=function(){function t(e,r){this.overflowContainer=void 0,this.trigger=void 0,this.layer=void 0,this.arrow=void 0,this.parent=void 0,this.window=void 0,this.scrollContainers=void 0,this.overflowContainer=r,Object.assign(this,e)}t.create=function(r,n,i,l,o,h,c,v){var g=J2.fromWindow(r);return new t({layer:J2.fromElement(n,{environment:r,withTransform:!1}),trigger:v?J2.create(W8(v())):J2.fromElement(i),arrow:o?J2.fromElement(o):J2.empty(),parent:l?J2.fromElement(l):g,window:g,scrollContainers:[g].concat(h.map(function(s){return J2.fromElement(s,{withScrollbars:!1})}))},c)};var a=t.prototype;return a.merge=function(r){return new t(M2({},this,r),this.overflowContainer)},a.offsetsToScrollContainers=function(r,n){n===void 0&&(n=!1);var i=this.overflowContainer&&!n?[this.window]:this.scrollContainers;return i.map(function(l){return l.offsetsTo(r)})},O5(t,[{key:"layerOffsetsToScrollContainers",get:function(){return this.offsetsToScrollContainers(this.layer)}},{key:"triggerHasBiggerWidth",get:function(){return this.trigger.width>this.layer.width}},{key:"triggerHasBiggerHeight",get:function(){return this.trigger.height>this.layer.height}}]),t}(),Zz=null;var Z2={auto:!1,arrowOffset:0,containerOffset:10,triggerOffset:0,overflowContainer:!0,placement:"top-center",possiblePlacements:u_,preferX:"right",preferY:"bottom",snap:!1,container:void 0,trigger:void 0};function im(t){var a,e=t.isOpen,r=e===void 0?!1:e,n=t.overflowContainer,i=n===void 0?Z2.overflowContainer:n,l=t.environment,o=l===void 0?typeof window<"u"?window:void 0:l,h=t.ResizeObserver,c=t.placement,v=c===void 0?Z2.placement:c,g=t.possiblePlacements,s=g===void 0?Z2.possiblePlacements:g,d=t.preferX,p=d===void 0?Z2.preferX:d,z=t.preferY,L=z===void 0?Z2.preferY:z,u=t.auto,f=u===void 0?Z2.auto:u,m=t.snap,M=m===void 0?Z2.snap:m,x=t.triggerOffset,y=x===void 0?Z2.triggerOffset:x,w=t.containerOffset,V=w===void 0?Z2.containerOffset:w,R=t.arrowOffset,S=R===void 0?Z2.arrowOffset:R,b=t.container,E=b===void 0?Z2.container:b,C=t.layerDimensions,T=C===void 0?null:C,I=t.onDisappear,J=t.onOutsideClick,W=t.onParentClose,n1=t.trigger,i1=(0,Z1.useState)(function(){return{layerSide:v==="center"?"center":Qz.getSidesFromPlacementType(v)[0].prop,styles:{layer:{position:i?"fixed":"absolute",top:0,left:0},arrow:{position:"absolute",top:0,left:0}}}}),g1=i1[0],l1=i1[1],H1=(0,Z1.useRef)(null),f1=h_(g1,r),d1=(0,Z1.useRef)({cancelled:!1});(0,Z1.useEffect)(function(){return function(){d1.current.cancelled=!0}},[]);var K1=(0,Z1.useCallback)(function(O,Q,c1){var $=O.arrow,s1=O.layer,W1=O.scrollContainers,k1=O.trigger,tt=W1[0],C1=H_.create(o,s1,k1,tt,$,W1,i,n1?.getBounds),Ut={placement:v,possiblePlacements:s,auto:f,layerDimensions:T,arrowOffset:S,containerOffset:V,triggerOffset:y,preferX:p,preferY:L,snap:M,overflowContainer:i},q=Qz.create(C1,Ut).result(Q,c1),h1=q.hasDisappeared,x1=q.layerSide,z1=q.styles,F1={layerSide:x1,styles:z1};if(!f1.current||x_(f1.current,F1)){f1.current=F1,d1.current.cancelled=!0;var vt={cancelled:!1};d1.current=vt,Promise.resolve().then(function(){vt.cancelled||l1(F1)})}qz(h1)&&qz(I)&&I(h1)},[S,f,V,o,T,I,i,v,s,p,L,M,y,f1,n1]),X1=v_({ResizeObserverPolyfill:h,environment:o,enabled:r,overflowContainer:i,onChange:K1,triggerOption:n1}),j1=X1.triggerRef,P1=X1.layerRef,ct=X1.arrowRef,b1=X1.closestScrollContainer,Q1=s_({isOpen:r,onOutsideClick:J,onParentClose:W}),j=Q1.closeOnOutsideClickRefs,N=Q1.registrations,u1={triggerProps:Boolean(n1)?{}:{ref:Gz(j1,j.trigger,H1)},layerProps:{ref:Gz(P1,j.layer),style:g1.styles.layer},arrowProps:{ref:ct,style:g1.styles.arrow,layerSide:g1.layerSide},layerSide:g1.layerSide,triggerBounds:r?n1?n1.getBounds():(a=H1.current)==null?void 0:a.getBoundingClientRect():null,renderLayer:function(O){return typeof document<"u"?(0,am.createPortal)((0,Z1.createElement)(g_,{registrations:N,children:O}),i||!b1?w_(E):b1):null}};return u1}function x_(t,a){if(t.layerSide!==a.layerSide)return!0;for(var e=["position","top","left","right","bottom"],r=0,n=e;r=0})}},{key:"negativeSides",get:function(){var e=this;return Object.fromEntries(U5.filter(function(r){return e[r]<0}).map(function(r){return[r,e[r]]}))}}]),t}();function vm(){for(var t=arguments.length,a=new Array(t),e=0;ef?f-y:0;z[x.prop]=Y8(y+r+R,s,f),z[x.opposite.prop]=z[x.prop]+i.factor(h[d])}z.width=z.right-z.left,z.height=z.bottom-z.top;var L=na.create(z);return r===0&&(this._cachedLayerBounds=L),L},a.getLayerCollisionBounds=function(){var r=this.offsets.container;return this.getLayerBounds().mapSides(function(n,i){return i-=n.factor(r)}).merge(function(n){var i=n.width,l=n.height;return{width:i+r*2,height:l+r*2}})},a.getContainerOffsets=function(r){if(this._cachedContainerOffsets&&!r)return this._cachedContainerOffsets;var n=this.subjectsBounds.merge({layer:r||this.getLayerCollisionBounds()}),i=Z8.mergeSmallestSides(n.layerOffsetsToScrollContainers);return r||(this._cachedContainerOffsets=i),i},W5(t,[{key:"type",get:function(){return this.primary.prop+"-"+(this.secondary.prop==="center"?"center":["bottom","right"].includes(this.secondary.prop)?"end":"start")}},{key:"triggerIsBigger",get:function(){var r=this.secondary.isHorizontal,n=this.subjectsBounds,i=n.triggerHasBiggerWidth,l=n.triggerHasBiggerHeight;return r&&i||!r&&l}},{key:"fitsContainer",get:function(){return this.getContainerOffsets().allSidesArePositive}},{key:"visibleSurface",get:function(){var r=this.getLayerBounds(),n=this.getContainerOffsets(r),i=n.negativeSides;for(var l in i)i[l]=-i[l];return r.substract(i).surface}},{key:"secondaryOffsetSide",get:function(){var r,n,i=this,l=this.getContainerOffsets(),o=(r=(n=Object.entries(l.negativeSides).map(function(c){var v=c[0],g=c[1];return[y0[v],g]}).filter(function(c){var v=c[0];return i.primary.isOppositeDirection(v)}).sort(function(c,v){var g=c[1],d=v[1];return d-g}))==null?void 0:n[0])!=null?r:[],h=o[0];return h||null}}]),t}(),gm=function(t){x_(a,t);function a(){return t.apply(this,arguments)||this}var e=a.prototype;return e.getLayerBounds=function(){var n=this.subjectsBounds,i=n.trigger,l=n.layer,o=na.empty();return o.top=i.top+i.height/2-l.height/2,o.bottom=o.top+l.height,o.left=i.left+i.width/2-l.width/2,o.right=o.left+l.width,o.width=o.right-o.left,o.height=o.bottom-o.top,o},a}(Hm);function __(t,a,e){var r=t.layer,n=t.trigger,i=t.arrow,l=a.primary.oppositeSizeProp,o=a.primary.isHorizontal?["top","bottom"]:["left","right"],h=o[0],c=o[1],v=r[h]+r[l]/2-n[h]-i[l]/2-e,g=r[c]-r[l]/2-n[c]+i[l]/2+e;return(v<0?-v:0)+(g>0?-g:0)}var dm={position:"absolute",willChange:"top, left",left:null,right:null,top:null,bottom:null};function T_(t,a,e){var r;if(a.primary.isCenter)return dm;var n=t.layer,i=t.trigger,l=t.arrow,o=a.primary.oppositeSizeProp,h=i[o]>n[o],c=e+l[o]/2,v=n[o]-l[o]/2-e,g=__(t,a,e),d=a.primary.prop,u=a.primary.oppositeCssProp,p=h?n[o]/2+g:i[u]+i[o]/2-n[u];return L2({},dm,(r={},r[d]="100%",r[u]=Y8(p,c,v),r))}var sm=function(){function t(e,r,n){this.placements=void 0,this.config=void 0,this.subjectsBounds=void 0,this.placements=e,this.config=r,this.subjectsBounds=n}t.getSidesFromPlacementType=function(r){var n=r.split("-"),i=n[0],l=n[1],o=y0[i],h;return l==="center"?h=s0.center:o.isHorizontal?h=l==="start"?s0.top:s0.bottom:h=l==="start"?s0.left:s0.right,[o,h]},t.create=function(r,n){var i={arrow:n.arrowOffset,container:n.containerOffset,trigger:n.triggerOffset};function l(o){o===void 0&&(o=n.placement);var h=t.getSidesFromPlacementType(o),c=h[0],v=h[1],g=y0[c.isHorizontal?n.preferY:n.preferX],d=!c.isHorizontal&&r.triggerHasBiggerWidth||c.isHorizontal&&r.triggerHasBiggerHeight;function u(z,w){return new Hm(z,w,r,n.layerDimensions,i)}var p=[];return p[0]=u(c,v),p[1]=u(c,v.isCenter?g:s0.center),p[2]=u(c,s0[(v.opposite.isCenter?g.opposite:v.opposite).prop]),p[3]=u(g,d?c:s0[c.opposite.prop]),p[4]=u(g,s0.center),p[5]=u(g,d?s0[c.opposite.prop]:c),p[6]=u(y0[g.opposite.prop],d?c:s0[c.opposite.prop]),p[7]=u(y0[g.opposite.prop],s0.center),p[8]=u(y0[g.opposite.prop],d?s0[c.opposite.prop]:c),p[9]=u(y0[c.opposite.prop],v),p[10]=u(y0[c.opposite.prop],v.isCenter?g:s0.center),p[11]=u(y0[c.opposite.prop],s0[(v.opposite.isCenter?g.opposite:v.opposite).prop]),p=p.filter(function(z){return z.type===n.placement||n.possiblePlacements.includes(z.type)}),p}return n.placement==="center"?new t([new gm(s0.center,s0.center,r,n.layerDimensions,i)].concat(l(n.preferY+"-"+n.preferX)),n,r):new t(l(),n,r)};var a=t.prototype;return a.filterPlacementsBySide=function(r){return this.placements.filter(function(n){return n.primary===r})},a.findFirstPlacementThatFits=function(){return this.placements.find(function(r){return r.fitsContainer})},a.placementWithBiggestVisibleSurface=function(){var r=this.placements.map(function(i){return{placement:i,surface:i.visibleSurface}}).sort(function(i,l){return l.surface-i.surface}),n=r[0].placement;return n},a.findSuitablePlacement=function(){return this.config.auto?this.findFirstPlacementThatFits()||this.placementWithBiggestVisibleSurface():this.placements[0]},a.getSecondaryOffset=function(r){var n=this.config,i=n.auto,l=n.snap;if(!i||l||r instanceof gm)return 0;var o=this.filterPlacementsBySide(r.primary),h=o.indexOf(r)===0;if(h&&r.fitsContainer)return 0;var c=o.find(function(z){return!z.fitsContainer});if(!c)return 0;var v=c.secondaryOffsetSide;if(!v)return 0;var g=r.getContainerOffsets(),d=r.secondary,u;r.triggerIsBigger||c===r?u=v.isPush?-1:1:u=d===s0.left||[s0.top,s0.center].includes(d)&&v.isPush?-1:1;var p=g[v.prop];return p*u},a.getStyles=function(r,n,i,l){var o={willChange:"top, left, width, height"},h=T_(this.subjectsBounds.merge({layer:r}),n,this.config.arrowOffset),c=this.config.overflowContainer?L2({},o,{position:"fixed",top:r.top,left:r.left}):L2({},o,{position:"absolute",top:r.top-this.subjectsBounds.parent.top+i.top-l.top,left:r.left-this.subjectsBounds.parent.left+i.left-l.left});return{arrow:h,layer:c}},a.getHasDisappeared=function(r){var n=this.config.overflowContainer?this.subjectsBounds.trigger:r,i=Z8.mergeSmallestSides(this.subjectsBounds.offsetsToScrollContainers(n,!0)),l=Object.entries(i.negativeSides),o=l.some(function(h){var c=h[0],v=h[1],g=y0[c];return v<=-n[g.sizeProp]});return o?"full":i.allSidesArePositive?null:"partial"},a.result=function(r,n){var i=this.findSuitablePlacement(),l=this.getSecondaryOffset(i),o=i.getLayerBounds(l),h=this.getStyles(o,i,r,n),c=i.primary.prop;return{styles:h,layerSide:c,placement:i,layerBounds:o,hasDisappeared:this.getHasDisappeared(o)}},t}(),P_=function(){function t(e,r){this.overflowContainer=void 0,this.trigger=void 0,this.layer=void 0,this.arrow=void 0,this.parent=void 0,this.window=void 0,this.scrollContainers=void 0,this.overflowContainer=r,Object.assign(this,e)}t.create=function(r,n,i,l,o,h,c,v){var g=na.fromWindow(r);return new t({layer:na.fromElement(n,{environment:r,withTransform:!1}),trigger:v?na.create(Q8(v())):na.fromElement(i),arrow:o?na.fromElement(o):na.empty(),parent:l?na.fromElement(l):g,window:g,scrollContainers:[g].concat(h.map(function(d){return na.fromElement(d,{withScrollbars:!1})}))},c)};var a=t.prototype;return a.merge=function(r){return new t(L2({},this,r),this.overflowContainer)},a.offsetsToScrollContainers=function(r,n){n===void 0&&(n=!1);var i=this.overflowContainer&&!n?[this.window]:this.scrollContainers;return i.map(function(l){return l.offsetsTo(r)})},W5(t,[{key:"layerOffsetsToScrollContainers",get:function(){return this.offsetsToScrollContainers(this.layer)}},{key:"triggerHasBiggerWidth",get:function(){return this.trigger.width>this.layer.width}},{key:"triggerHasBiggerHeight",get:function(){return this.trigger.height>this.layer.height}}]),t}(),um=null;var ra={auto:!1,arrowOffset:0,containerOffset:10,triggerOffset:0,overflowContainer:!0,placement:"top-center",possiblePlacements:F_,preferX:"right",preferY:"bottom",snap:!1,container:void 0,trigger:void 0};function xm(t){var a,e=t.isOpen,r=e===void 0?!1:e,n=t.overflowContainer,i=n===void 0?ra.overflowContainer:n,l=t.environment,o=l===void 0?typeof window<"u"?window:void 0:l,h=t.ResizeObserver,c=t.placement,v=c===void 0?ra.placement:c,g=t.possiblePlacements,d=g===void 0?ra.possiblePlacements:g,u=t.preferX,p=u===void 0?ra.preferX:u,z=t.preferY,w=z===void 0?ra.preferY:z,s=t.auto,f=s===void 0?ra.auto:s,m=t.snap,H=m===void 0?ra.snap:m,x=t.triggerOffset,y=x===void 0?ra.triggerOffset:x,R=t.containerOffset,L=R===void 0?ra.containerOffset:R,V=t.arrowOffset,C=V===void 0?ra.arrowOffset:V,k=t.container,b=k===void 0?ra.container:k,F=t.layerDimensions,_=F===void 0?null:F,j=t.onDisappear,n1=t.onOutsideClick,Z=t.onParentClose,d1=t.trigger,O=(0,Z1.useState)(function(){return{layerSide:v==="center"?"center":sm.getSidesFromPlacementType(v)[0].prop,styles:{layer:{position:i?"fixed":"absolute",top:0,left:0},arrow:{position:"absolute",top:0,left:0}}}}),a1=O[0],W=O[1],L1=(0,Z1.useRef)(null),p1=R_(a1,r),o1=(0,Z1.useRef)({cancelled:!1});(0,Z1.useEffect)(function(){return function(){o1.current.cancelled=!0}},[]);var H1=(0,Z1.useCallback)(function(f1,U,v1){var D=f1.arrow,I=f1.layer,C1=f1.scrollContainers,D1=f1.trigger,et=C1[0],B1=P_.create(o,I,D1,et,D,C1,i,d1?.getBounds),c1={placement:v,possiblePlacements:d,auto:f,layerDimensions:_,arrowOffset:C,containerOffset:L,triggerOffset:y,preferX:p,preferY:w,snap:H,overflowContainer:i},e1=sm.create(B1,c1).result(U,v1),u1=e1.hasDisappeared,M1=e1.layerSide,I1=e1.styles,Q1={layerSide:M1,styles:I1};if(!p1.current||I_(p1.current,Q1)){p1.current=Q1,o1.current.cancelled=!0;var St={cancelled:!1};o1.current=St,Promise.resolve().then(function(){St.cancelled||W(Q1)})}hm(u1)&&hm(j)&&j(u1)},[C,f,L,o,_,j,i,v,d,p,w,H,y,p1,d1]),P1=C_({ResizeObserverPolyfill:h,environment:o,enabled:r,overflowContainer:i,onChange:H1,triggerOption:d1}),K1=P1.triggerRef,W1=P1.layerRef,Bt=P1.arrowRef,T1=P1.closestScrollContainer,X1=A_({isOpen:r,onOutsideClick:n1,onParentClose:Z}),Y=X1.closeOnOutsideClickRefs,N=X1.registrations,s1={triggerProps:Boolean(d1)?{}:{ref:cm(K1,Y.trigger,L1)},layerProps:{ref:cm(W1,Y.layer),style:a1.styles.layer},arrowProps:{ref:Bt,style:a1.styles.arrow,layerSide:a1.layerSide},layerSide:a1.layerSide,triggerBounds:r?d1?d1.getBounds():(a=L1.current)==null?void 0:a.getBoundingClientRect():null,renderLayer:function(f1){return typeof document<"u"?(0,zm.createPortal)((0,Z1.createElement)(B_,{registrations:N,children:f1}),i||!T1?O_(b):T1):null}};return s1}function I_(t,a){if(t.layerSide!==a.layerSide)return!0;for(var e=["position","top","left","right","bottom"],r=0,n=e;r` + `,document.body.appendChild(a))}return a}var pm;(function(t){t[t.ENTERING=0]="ENTERING",t[t.LEAVING=1]="LEAVING",t[t.IDLE=2]="IDLE"})(pm||(pm={}));var D_={arrowUp:t=>` `,arrowDown:t=>` - `},V_={text:xe.HeaderString,number:xe.HeaderNumber,uri:xe.HeaderUri,date:xe.HeaderDate},R_={text:t1.Text,number:t1.Number,uri:t1.Uri,date:t1.Text},lm={fontFamily:"JetBrains Mono",bgHeader:"white",textDark:"#61758a",textHeader:"#304254",headerFontStyle:"bold 14px",baseFontStyle:"14px",borderColor:"#E1E8F0",horizontalBorderColor:"#E1E8F0",accentColor:"#3E64FF",accentLight:"#ECF0FF",bgHeaderHovered:"#F0F5F9",bgHeaderHasFocus:"#E1E8F0",bgSearchResult:"#FFF7EC",headerIconSize:22};function NO(t,a){t.importCSS("main.css"),t.importCSS("https://fonts.googleapis.com/css2?family=Inter:wght@400;500&display=swap"),t.importCSS("https://fonts.googleapis.com/css2?family=JetBrains+Mono:wght@400;500;600&display=swap"),(0,om.createRoot)(t.root).render(v1.default.createElement(y_,{ctx:t,data:a}))}function y_({ctx:t,data:a}){let e=[],r=[],n=a.content.columns.map(q=>{let h1=q.summary,x1=q.label,z1=q.key;return r.push({[x1]:250}),h1&&e.push(h1.keys.length),{title:x1,id:z1,type:q.type,icon:V_[q.type]||xe.HeaderString,hasMenu:!0,summary:h1}}),i=a.features.includes("refetch"),l=a.features.includes("export"),o=a.content.columns.length!==0,h=e.length>0,c=a.features.includes("sorting"),v=l?a.export?.formats:null,g=l&&v,s={rows:pt.empty(),columns:pt.empty()},[d,p]=(0,v1.useState)(a.content),[z,L]=(0,v1.useState)(!1),[u,f]=(0,v1.useState)(n),[m,M]=(0,v1.useState)(r),[x,y]=(0,v1.useState)(null),[w,V]=(0,v1.useState)(!1),[R,S]=(0,v1.useState)(s),[b,E]=(0,v1.useState)(0),[C,T]=(0,v1.useState)(null),I=d.total_rows,J=o&&I>0,W=a.features.includes("pagination")&&(I===null||I>0),n1=d.limit===I,i1=44,g1=h&&J?Math.max(...e):0,l1=i1+g1*22,H1=c?140:70,f1=440+l1,K1=I&&I<(c?3:2)&&x?H1+l1:null,X1=I>=10&&n1?f1:K1,j1=(d.page-1)*d.limit+1,P1=h?150:50,ct=a.content.columns.length===1?800:350,b1=d.page_length,Q1=(0,v1.useCallback)(q=>{let{ctx:h1,theme:x1,rect:z1,column:F1,menuBounds:vt,isHovered:jt,isSelected:xt,spriteManager:kt}=q;if(F1.sourceIndex===0)return!0;if(!J)return!1;h1.rect(z1.x,z1.y,z1.width,z1.height);let Y1=10,D1=19,Mt=xt?x1.textHeaderSelected:x1.textHeader,bt=xt?x1.accentLight:x1.textDark,T0=F1.hasMenu===!0&&jt,H2=!!F1.summary,Z0=35,qt=z1.width-Z0,yt=z1.width-Z0*.7,lt=qt/z1.width,zt=yt/z1.width,Ct=h1.createLinearGradient(z1.x,0,z1.x+z1.width,0),_2=ur(Mt,0),s0=_a(h1,`${x1.headerFontStyle} ${x1.fontFamily}`);if(Ct.addColorStop(0,Mt),Ct.addColorStop(lt,Mt),Ct.addColorStop(zt,_2),Ct.addColorStop(1,_2),h1.fillStyle=T0?Ct:Mt,F1.icon){let H0=xt?"selected":F1.style==="highlight"?"special":"normal",o2=x1.headerIconSize;kt.drawSprite(F1.icon,H0,h1,z1.x+Y1,z1.y+Y1,o2,x1),F1.overlayIcon&&kt.drawSprite(F1.overlayIcon,xt?"selected":"special",h1,z1.x+Y1+D1/2,z1.y+Y1+D1/2,D1,x1)}if(h1.fillText(F1.title,vt.x-z1.width+x1.headerIconSize*2.5+14,H2?z1.y+Y1+x1.headerIconSize/2+s0:vt.y+vt.height/2+s0),H2){let H0=d.columns[F1.sourceIndex-1].summary,o2=Object.fromEntries(H0.keys.map((e0,ta)=>[e0,H0.values[ta]])),J0=13,h2=J0+Y1,Ta=`${J0}px ${x1.fontFamily}`,fa=`bold ${Ta}`;h1.fillStyle=bt,Object.entries(o2).forEach(([e0,ta],Ve)=>{h1.font=fa,h1.fillText(`${e0}:`,z1.x+h2/2,z1.y+h2*(Ve+1)+h2),h1.font=Ta,h1.fillText(ta,z1.x+h1.measureText(e0).width+h2,z1.y+h2*(Ve+1)+h2)})}if(T0){h1.fillStyle=Ct;let H0=vt.x+vt.width/2-Y1*1.5,o2=x1.headerIconSize/2-2,J0=new Path2D("M12 16l-6-6h12z");h1.translate(H0,o2),h1.fill(J0)}return!0},[d]),j=(0,v1.useCallback)(([q,h1])=>{let x1=R_[d.columns[q].type]||t1.Text,F1=d.data_orientation==="columns"?d.data[q][h1]:d.data[h1][q];return{kind:x1,data:F1,displayData:F1,allowOverlay:!0,allowWrapping:!1,readonly:!0}},[d]),N=()=>{L(!z)},u1=q=>{let h1=q!=="none"?x.columnKey:null;t.pushEvent("order_by",{key:h1,direction:q??"asc"}),y(null)},o1=()=>{t.pushEvent("show_page",{page:d.page-1}),S({...s,columns:R.columns})},O=()=>{t.pushEvent("show_page",{page:d.page+1}),S({...s,columns:R.columns})},Q=()=>{let q={...s,columns:pt.fromSingleSelection(x.column)};S(q),y(null)},{layerProps:c1,renderLayer:$}=im({isOpen:w,auto:!0,placement:"bottom-end",possiblePlacements:["bottom-end","bottom-center","bottom-start"],triggerOffset:0,onOutsideClick:()=>y(null),trigger:{getBounds:()=>({left:x?.bounds.x??0,top:x?.bounds.y??0,width:x?.bounds.width??0,height:x?.bounds.height??0,right:(x?.bounds.x??0)+(x?.bounds.width??0),bottom:(x?.bounds.y??0)+(x?.bounds.height??0)})}}),s1=(0,v1.useCallback)((q,h1)=>{M(x1=>({...x1,[q.title]:h1}))},[]),W1=(0,v1.useCallback)((q,h1)=>{let{summary:x1,id:z1,type:F1}=u[q];x1||y({column:q,bounds:h1,columnKey:z1,columnType:F1})},[]),k1=(0,v1.useCallback)((q,{bounds:h1})=>{let{id:x1,type:z1}=u[q];y({column:q,bounds:h1,columnKey:x1,columnType:z1})},[]),tt=(0,v1.useCallback)(q=>{let[h1,x1]=q.location;x1===-1&&h1===-1&&q.kind==="header"?T([...Array.from({length:b1},(z1,F1)=>F1)]):h1===-1&&q.kind==="cell"?T([x1]):T(null)},[b1]),C1=(0,v1.useCallback)(q=>C?.includes(q)?{bgCell:lm.bgHeaderHovered}:null,[C]),Ut=(0,v1.useCallback)(({x:q,y:h1,width:x1,height:z1})=>{let F1=[],vt=d.columns.length,jt=x1>=vt||q+x1>=vt?0:b,xt=[...Array.from({length:z1},(Y1,D1)=>D1+h1)],kt=[...Array.from({length:x1+jt},(Y1,D1)=>D1+q)];return xt.forEach(Y1=>{let D1=[];kt.forEach(Mt=>{D1.push(j([Mt,Y1]))}),F1.push(D1)}),F1},[b,j]);return(0,v1.useEffect)(()=>{R.rows?.items.length>0?E(1):E(0)},[R]),(0,v1.useEffect)(()=>{t.handleEvent("update_content",q=>{p(q)}),t.handleEvent("download_content",([q,h1])=>{let x1=new Blob([h1],{type:q.type}),z1=document.createElement("a");z1.href=window.URL.createObjectURL(x1),z1.download=`${q.filename}-${+new Date}${q.format}`,z1.click()})},[]),(0,v1.useEffect)(()=>{let q=d.order?.direction==="asc"?"arrowUp":"arrowDown",h1=u.map(x1=>({...x1,overlayIcon:x1.id===d.order?.key?q:null}));f(h1)},[d.order?.direction,d.order?.key]),(0,v1.useEffect)(()=>{let q=u.map(h1=>({...h1,width:m[h1.title]}));f(q)},[m]),(0,v1.useEffect)(()=>{let q=x?.columnKey,h1={bgHeader:"#F0F5F9"},x1=u.map(z1=>({...z1,themeOverride:z1.id===q?h1:null}));f(x1),V(!!x)},[x]),v1.default.createElement("div",{className:"app"},v1.default.createElement("div",{className:"navigation"},v1.default.createElement("div",{className:"navigation__info"},v1.default.createElement("h2",{className:"navigation__name"},a.name),v1.default.createElement("span",{className:"navigation__details"},I||"?"," ",I===1?"entry":"entries"),It.pushEvent("download",{format:q})}),v1.default.createElement("div",{className:"navigation__space"}),i&&v1.default.createElement(B_,{onRefetch:()=>t.pushEvent("refetch")}),v1.default.createElement(S_,{toggleSearch:N}),v1.default.createElement(A_,{limit:d.limit,totalRows:I,onChange:q=>t.pushEvent("limit",{limit:q})}),W&&v1.default.createElement(F_,{page:d.page,maxPage:d.max_page,onPrev:o1,onNext:O,rows:b1})),o&&v1.default.createElement(Ez,{className:"table-container",theme:lm,getCellContent:j,columns:u,rows:b1,width:"100%",height:X1,rowHeight:44,headerHeight:l1,drawHeader:Q1,verticalBorder:!1,rowMarkers:"clickable-number",rowMarkerWidth:32,onHeaderMenuClick:W1,onHeaderClicked:k1,showSearch:z,getCellsForSelection:Ut,onSearchClose:N,headerIcons:L_,overscrollX:100,isDraggable:!1,smoothScrollX:!0,smoothScrollY:!0,onColumnResize:s1,columnSelect:"none",gridSelection:R,onGridSelectionChange:q=>S(q),rowMarkerStartIndex:j1,minColumnWidth:P1,maxColumnAutoWidth:ct,fillHandle:!0,onItemHovered:tt,getRowThemeOverride:C1}),w&&$(v1.default.createElement(k_,{layerProps:c1,menu:x,orderBy:u1,selectAllCurrent:Q,hasSorting:c})),!o&&v1.default.createElement("p",{className:"no-data"},"No data"),v1.default.createElement("div",{id:"portal"}))}function C_({supportedFormats:t,onDownload:a}){let e=t.map(r=>v1.default.createElement("option",null,r));return v1.default.createElement("div",{className:"download"},v1.default.createElement("span",{className:"tooltip right","data-tooltip":"Export to"},v1.default.createElement("form",null,v1.default.createElement("select",{className:"input__icon",value:"",onChange:r=>a(r.target.value)},v1.default.createElement("option",{selected:!0,disabled:!0,value:""},"Export to"),e))))}function B_({onRefetch:t}){return v1.default.createElement("button",{className:"icon-button","aria-label":"refresh",onClick:t},v1.default.createElement(Nz,null))}function S_({toggleSearch:t}){return v1.default.createElement("span",{className:"tooltip right","data-tooltip":"Current page search"},v1.default.createElement("button",{className:"icon-button search","aria-label":"search",onClick:t},v1.default.createElement($z,{className:"search-icon"})))}function A_({limit:t,totalRows:a,onChange:e}){return v1.default.createElement("div",null,v1.default.createElement("form",null,v1.default.createElement("label",{className:"input-label"},"Show"),v1.default.createElement("select",{className:"input",value:t,onChange:r=>e(parseInt(r.target.value))},v1.default.createElement("option",{value:"10"},"10"),v1.default.createElement("option",{value:"20"},"20"),v1.default.createElement("option",{value:"50"},"50"),v1.default.createElement("option",{value:"100"},"100"),a?v1.default.createElement("option",{value:a},"All"):null)))}function F_({page:t,maxPage:a,onPrev:e,onNext:r,rows:n}){return v1.default.createElement("div",{className:"pagination"},v1.default.createElement("button",{className:"pagination__button",onClick:e,disabled:t===1},v1.default.createElement(Oz,null),v1.default.createElement("span",null,"Prev")),v1.default.createElement("div",{className:"pagination__info"},v1.default.createElement("span",null,t," of ",a||"?")),v1.default.createElement("button",{className:"pagination__button",onClick:r,disabled:t===a||n===0},v1.default.createElement("span",null,"Next"),v1.default.createElement(Dz,null)))}function k_({layerProps:t,selectAllCurrent:a,hasSorting:e,orderBy:r}){return v1.default.createElement("div",{className:"header-menu",...t},v1.default.createElement("button",{className:"header-menu-item button",onClick:a},"Select this column"),e&&v1.default.createElement(v1.default.Fragment,null,v1.default.createElement("div",{className:"header-menu-item",onClick:()=>r("asc")},v1.default.createElement(Pz,null),v1.default.createElement("span",null,"Sort: ascending")),v1.default.createElement("div",{className:"header-menu-item",onClick:()=>r("desc")},v1.default.createElement(Iz,null),v1.default.createElement("span",null,"Sort: descending")),v1.default.createElement("div",{className:"header-menu-item",onClick:()=>r("none")},v1.default.createElement(Tz,null),v1.default.createElement("span",null,"Sort: none"))))}export{NO as init}; + `},N_={text:ye.HeaderString,number:ye.HeaderNumber,uri:ye.HeaderUri,date:ye.HeaderDate},$_={text:l1.Text,number:l1.Number,uri:l1.Uri,date:l1.Text},wm={fontFamily:"JetBrains Mono",bgHeader:"white",textDark:"#61758a",textHeader:"#304254",headerFontStyle:"bold 14px",baseFontStyle:"14px",borderColor:"#E1E8F0",horizontalBorderColor:"#E1E8F0",accentColor:"#3E64FF",accentLight:"#ECF0FF",bgHeaderHovered:"#F0F5F9",bgHeaderHasFocus:"#E1E8F0",bgSearchResult:"#FFF7EC",headerIconSize:22};function nD(t,a){t.importCSS("main.css"),t.importCSS("https://fonts.googleapis.com/css2?family=Inter:wght@400;500&display=swap"),t.importCSS("https://fonts.googleapis.com/css2?family=JetBrains+Mono:wght@400;500;600&display=swap"),(0,Lm.createRoot)(t.root).render(g1.default.createElement(U_,{ctx:t,data:a}))}function U_({ctx:t,data:a}){let e=[],r=[],n=a.content.columns.map(c1=>{let e1=c1.summary,u1=c1.label,M1=c1.key;return r.push({[u1]:250}),e1&&e.push(e1.keys.length),{title:u1,id:M1,type:c1.type,icon:N_[c1.type]||ye.HeaderString,hasMenu:!0,summary:e1}}),i=a.features.includes("refetch"),l=a.features.includes("export"),o=a.content.columns.length!==0,h=e.length>0,c=a.features.includes("sorting"),v=l?a.export?.formats:null,g=l&&v,d={rows:mt.empty(),columns:mt.empty()},[u,p]=(0,g1.useState)(a.content),[z,w]=(0,g1.useState)(!1),[s,f]=(0,g1.useState)(n),[m,H]=(0,g1.useState)(r),[x,y]=(0,g1.useState)(null),[R,L]=(0,g1.useState)(!1),[V,C]=(0,g1.useState)(d),[k,b]=(0,g1.useState)(0),[F,_]=(0,g1.useState)(null),j=u.total_rows,n1=o&&j>0,Z=a.features.includes("pagination")&&(j===null||j>0),d1=u.limit===j,O=44,a1=h&&n1?Math.max(...e):0,W=O+a1*22,L1=c?140:70,p1=440+W,H1=j&&j<(c?3:2)&&x?L1+W:null,P1=j>=10&&d1?p1:H1,K1=(u.page-1)*u.limit+1,W1=h?150:50,Bt=a.content.columns.length===1?800:350,T1=u.page_length,X1=(0,g1.useCallback)(c1=>{let{ctx:e1,theme:u1,rect:M1,column:I1,menuBounds:Q1,isHovered:St,isSelected:jt,spriteManager:Ut}=c1;if(I1.sourceIndex===0)return!0;if(!n1)return!1;e1.rect(M1.x,M1.y,M1.width,M1.height);let Et=10,ot=19,J1=jt?u1.textHeaderSelected:u1.textHeader,Jt=jt?u1.accentLight:u1.textDark,Mt=I1.hasMenu===!0&&St,C0=!!I1.summary,Z0=35,B0=M1.width-Z0,t0=M1.width-Z0*.7,Ma=B0/M1.width,dt=t0/M1.width,At=e1.createLinearGradient(M1.x,0,M1.x+M1.width,0),h0=fr(J1,0),wt=Na(e1,`${u1.headerFontStyle} ${u1.fontFamily}`);if(At.addColorStop(0,J1),At.addColorStop(Ma,J1),At.addColorStop(dt,h0),At.addColorStop(1,h0),e1.fillStyle=Mt?At:J1,I1.icon){let Ft=jt?"selected":I1.style==="highlight"?"special":"normal",qt=u1.headerIconSize;Ut.drawSprite(I1.icon,Ft,e1,M1.x+Et,M1.y+Et,qt,u1),I1.overlayIcon&&Ut.drawSprite(I1.overlayIcon,jt?"selected":"special",e1,M1.x+Et+ot/2,M1.y+Et+ot/2,ot,u1)}if(e1.fillText(I1.title,Q1.x-M1.width+u1.headerIconSize*2.5+14,C0?M1.y+Et+u1.headerIconSize/2+wt:Q1.y+Q1.height/2+wt),C0){let Ft=u.columns[I1.sourceIndex-1].summary,qt=Object.fromEntries(Ft.keys.map((j0,g2)=>[j0,Ft.values[g2]])),c2=13,v2=c2+Et,$a=`${c2}px ${u1.fontFamily}`,O2=`bold ${$a}`;e1.fillStyle=Jt,Object.entries(qt).forEach(([j0,g2],D2)=>{e1.font=O2,e1.fillText(`${j0}:`,M1.x+v2/2,M1.y+v2*(D2+1)+v2),e1.font=$a,e1.fillText(g2,M1.x+e1.measureText(j0).width+v2,M1.y+v2*(D2+1)+v2)})}if(Mt){e1.fillStyle=At;let Ft=Q1.x+Q1.width/2-Et*1.5,qt=u1.headerIconSize/2-2,c2=new Path2D("M12 16l-6-6h12z");e1.translate(Ft,qt),e1.fill(c2)}return!0},[u]),Y=(0,g1.useCallback)(([c1,e1])=>{let u1=$_[u.columns[c1].type]||l1.Text,I1=u.data_orientation==="columns"?u.data[c1][e1]:u.data[e1][c1];return{kind:u1,data:I1,displayData:I1,allowOverlay:!0,allowWrapping:!1,readonly:!0}},[u]),N=()=>{w(!z)},s1=c1=>{let e1=c1!=="none"?x.columnKey:null;t.pushEvent("order_by",{key:e1,direction:c1??"asc"}),y(null)},x1=()=>{t.pushEvent("show_page",{page:u.page-1}),C({...d,columns:V.columns})},f1=()=>{t.pushEvent("show_page",{page:u.page+1}),C({...d,columns:V.columns})},U=()=>{let c1={...d,columns:mt.fromSingleSelection(x.column)};C(c1),y(null)},{layerProps:v1,renderLayer:D}=xm({isOpen:R,auto:!0,placement:"bottom-end",possiblePlacements:["bottom-end","bottom-center","bottom-start"],triggerOffset:0,onOutsideClick:()=>y(null),trigger:{getBounds:()=>({left:x?.bounds.x??0,top:x?.bounds.y??0,width:x?.bounds.width??0,height:x?.bounds.height??0,right:(x?.bounds.x??0)+(x?.bounds.width??0),bottom:(x?.bounds.y??0)+(x?.bounds.height??0)})}}),I=(0,g1.useCallback)((c1,e1)=>{H(u1=>({...u1,[c1.title]:e1}))},[]),C1=(0,g1.useCallback)((c1,e1)=>{let{summary:u1,id:M1,type:I1}=s[c1];u1||y({column:c1,bounds:e1,columnKey:M1,columnType:I1})},[]),D1=(0,g1.useCallback)((c1,{bounds:e1})=>{let{id:u1,type:M1}=s[c1];y({column:c1,bounds:e1,columnKey:u1,columnType:M1})},[]),et=(0,g1.useCallback)(c1=>{let[e1,u1]=c1.location;u1===-1&&e1===-1&&c1.kind==="header"?_([...Array.from({length:T1},(M1,I1)=>I1)]):e1===-1&&c1.kind==="cell"?_([u1]):_(null)},[T1]),B1=(0,g1.useCallback)(c1=>F?.includes(c1)?{bgCell:wm.bgHeaderHovered}:null,[F]);return(0,g1.useEffect)(()=>{V.rows?.items.length>0?b(1):b(0)},[V]),(0,g1.useEffect)(()=>{t.handleEvent("update_content",c1=>{p(c1)}),t.handleEvent("download_content",([c1,e1])=>{let u1=new Blob([e1],{type:c1.type}),M1=document.createElement("a");M1.href=window.URL.createObjectURL(u1),M1.download=`${c1.filename}-${+new Date}${c1.format}`,M1.click()})},[]),(0,g1.useEffect)(()=>{let c1=u.order?.direction==="asc"?"arrowUp":"arrowDown",e1=s.map(u1=>({...u1,overlayIcon:u1.id===u.order?.key?c1:null}));f(e1)},[u.order?.direction,u.order?.key]),(0,g1.useEffect)(()=>{let c1=s.map(e1=>({...e1,width:m[e1.title]}));f(c1)},[m]),(0,g1.useEffect)(()=>{let c1=x?.columnKey,e1={bgHeader:"#F0F5F9"},u1=s.map(M1=>({...M1,themeOverride:M1.id===c1?e1:null}));f(u1),L(!!x)},[x]),g1.default.createElement("div",{className:"app"},g1.default.createElement("div",{className:"navigation"},g1.default.createElement("div",{className:"navigation__info"},g1.default.createElement("h2",{className:"navigation__name"},a.name),g1.default.createElement("span",{className:"navigation__details"},j||"?"," ",j===1?"entry":"entries"),jt.pushEvent("download",{format:c1})}),g1.default.createElement("div",{className:"navigation__space"}),i&&g1.default.createElement(j_,{onRefetch:()=>t.pushEvent("refetch")}),g1.default.createElement(q_,{toggleSearch:N}),g1.default.createElement(G_,{limit:u.limit,totalRows:j,onChange:c1=>t.pushEvent("limit",{limit:c1})}),Z&&g1.default.createElement(K_,{page:u.page,maxPage:u.max_page,onPrev:x1,onNext:f1,rows:T1})),o&&g1.default.createElement(Yz,{className:"table-container",theme:wm,getCellContent:Y,columns:s,rows:T1,width:"100%",height:P1,rowHeight:44,headerHeight:W,drawHeader:X1,verticalBorder:!1,rowMarkers:"clickable-number",rowMarkerWidth:32,onHeaderMenuClick:C1,onHeaderClicked:D1,showSearch:z,getCellsForSelection:!0,onSearchClose:N,headerIcons:D_,overscrollX:100,isDraggable:!1,smoothScrollX:!0,smoothScrollY:!0,onColumnResize:I,columnSelect:"none",gridSelection:V,onGridSelectionChange:c1=>C(c1),rowMarkerStartIndex:K1,minColumnWidth:W1,maxColumnAutoWidth:Bt,fillHandle:!0,onItemHovered:et,getRowThemeOverride:B1}),R&&D(g1.default.createElement(X_,{layerProps:v1,menu:x,orderBy:s1,selectAllCurrent:U,hasSorting:c})),!o&&g1.default.createElement("p",{className:"no-data"},"No data"),g1.default.createElement("div",{id:"portal"}))}function W_({supportedFormats:t,onDownload:a}){let e=t.map(r=>g1.default.createElement("option",null,r));return g1.default.createElement("div",{className:"download"},g1.default.createElement("span",{className:"tooltip right","data-tooltip":"Export to"},g1.default.createElement("form",null,g1.default.createElement("select",{className:"input__icon",value:"",onChange:r=>a(r.target.value)},g1.default.createElement("option",{selected:!0,disabled:!0,value:""},"Export to"),e))))}function j_({onRefetch:t}){return g1.default.createElement("button",{className:"icon-button","aria-label":"refresh",onClick:t},g1.default.createElement(rm,null))}function q_({toggleSearch:t}){return g1.default.createElement("span",{className:"tooltip right","data-tooltip":"Current page search"},g1.default.createElement("button",{className:"icon-button search","aria-label":"search",onClick:t},g1.default.createElement(nm,{className:"search-icon"})))}function G_({limit:t,totalRows:a,onChange:e}){return g1.default.createElement("div",null,g1.default.createElement("form",null,g1.default.createElement("label",{className:"input-label"},"Show"),g1.default.createElement("select",{className:"input",value:t,onChange:r=>e(parseInt(r.target.value))},g1.default.createElement("option",{value:"10"},"10"),g1.default.createElement("option",{value:"20"},"20"),g1.default.createElement("option",{value:"50"},"50"),g1.default.createElement("option",{value:"100"},"100"),a?g1.default.createElement("option",{value:a},"All"):null)))}function K_({page:t,maxPage:a,onPrev:e,onNext:r,rows:n}){return g1.default.createElement("div",{className:"pagination"},g1.default.createElement("button",{className:"pagination__button",onClick:e,disabled:t===1},g1.default.createElement(am,null),g1.default.createElement("span",null,"Prev")),g1.default.createElement("div",{className:"pagination__info"},g1.default.createElement("span",null,t," of ",a||"?")),g1.default.createElement("button",{className:"pagination__button",onClick:r,disabled:t===a||n===0},g1.default.createElement("span",null,"Next"),g1.default.createElement(em,null)))}function X_({layerProps:t,selectAllCurrent:a,hasSorting:e,orderBy:r}){return g1.default.createElement("div",{className:"header-menu",...t},g1.default.createElement("button",{className:"header-menu-item button",onClick:a},"Select this column"),e&&g1.default.createElement(g1.default.Fragment,null,g1.default.createElement("div",{className:"header-menu-item",onClick:()=>r("asc")},g1.default.createElement(Jz,null),g1.default.createElement("span",null,"Sort: ascending")),g1.default.createElement("div",{className:"header-menu-item",onClick:()=>r("desc")},g1.default.createElement(tm,null),g1.default.createElement("span",null,"Sort: descending")),g1.default.createElement("div",{className:"header-menu-item",onClick:()=>r("none")},g1.default.createElement(Zz,null),g1.default.createElement("span",null,"Sort: none"))))}export{nD as init}; /*! Copyright (c) 2018 Jed Watson. Licensed under the MIT License (MIT), see