promptfoo 0.92.2 → 0.93.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/package.json +12 -10
- package/dist/src/app/assets/index-CQmOdU-e.js +783 -0
- package/dist/src/app/assets/{index-DdvQdOby.css → index-V4sLv2Tk.css} +1 -1
- package/dist/src/app/assets/{index.es-ihzvEu35.js → index.es-tEEAGvDQ.js} +1 -1
- package/dist/src/app/assets/{purify.es-DGIRlouP.js → purify.es-a-CayzAK.js} +2 -2
- package/dist/src/app/assets/{sync-BosjlpGJ.js → sync-BSL909CQ.js} +1 -1
- package/dist/src/app/index.html +2 -2
- package/dist/src/assertions.js +1 -1
- package/dist/src/assertions.js.map +1 -1
- package/dist/src/commands/eval.d.ts.map +1 -1
- package/dist/src/commands/eval.js +5 -3
- package/dist/src/commands/eval.js.map +1 -1
- package/dist/src/commands/init.d.ts +5 -0
- package/dist/src/commands/init.d.ts.map +1 -1
- package/dist/src/commands/init.js +149 -6
- package/dist/src/commands/init.js.map +1 -1
- package/dist/src/database/index.d.ts.map +1 -1
- package/dist/src/database/index.js +9 -1
- package/dist/src/database/index.js.map +1 -1
- package/dist/src/database/tables.d.ts +1 -0
- package/dist/src/database/tables.d.ts.map +1 -1
- package/dist/src/envars.d.ts +2 -0
- package/dist/src/envars.d.ts.map +1 -1
- package/dist/src/envars.js.map +1 -1
- package/dist/src/evaluator.d.ts.map +1 -1
- package/dist/src/evaluator.js +3 -1
- package/dist/src/evaluator.js.map +1 -1
- package/dist/src/evaluatorHelpers.d.ts.map +1 -1
- package/dist/src/evaluatorHelpers.js +1 -0
- package/dist/src/evaluatorHelpers.js.map +1 -1
- package/dist/src/index.d.ts +1 -0
- package/dist/src/index.d.ts.map +1 -1
- package/dist/src/matchers.d.ts.map +1 -1
- package/dist/src/matchers.js +15 -36
- package/dist/src/matchers.js.map +1 -1
- package/dist/src/models/provider.d.ts +3 -1
- package/dist/src/models/provider.d.ts.map +1 -1
- package/dist/src/models/provider.js +22 -17
- package/dist/src/models/provider.js.map +1 -1
- package/dist/src/prompts/grading.js +2 -2
- package/dist/src/providers/googleShared.d.ts +2 -0
- package/dist/src/providers/googleShared.d.ts.map +1 -0
- package/dist/src/providers/googleShared.js +46 -0
- package/dist/src/providers/googleShared.js.map +1 -0
- package/dist/src/providers/packageParser.d.ts +3 -0
- package/dist/src/providers/packageParser.d.ts.map +1 -0
- package/dist/src/providers/packageParser.js +47 -0
- package/dist/src/providers/packageParser.js.map +1 -0
- package/dist/src/providers/palm.d.ts +0 -1
- package/dist/src/providers/palm.d.ts.map +1 -1
- package/dist/src/providers/palm.js +3 -3
- package/dist/src/providers/palm.js.map +1 -1
- package/dist/src/providers/vertex.d.ts +0 -1
- package/dist/src/providers/vertex.d.ts.map +1 -1
- package/dist/src/providers/vertex.js +2 -34
- package/dist/src/providers/vertex.js.map +1 -1
- package/dist/src/providers/watsonx.d.ts +20 -0
- package/dist/src/providers/watsonx.d.ts.map +1 -0
- package/dist/src/providers/watsonx.js +192 -0
- package/dist/src/providers/watsonx.js.map +1 -0
- package/dist/src/providers.d.ts +2 -0
- package/dist/src/providers.d.ts.map +1 -1
- package/dist/src/providers.js +11 -0
- package/dist/src/providers.js.map +1 -1
- package/dist/src/redteam/commands/generate.d.ts.map +1 -1
- package/dist/src/redteam/commands/generate.js +39 -8
- package/dist/src/redteam/commands/generate.js.map +1 -1
- package/dist/src/redteam/commands/run.d.ts.map +1 -1
- package/dist/src/redteam/commands/run.js +13 -35
- package/dist/src/redteam/commands/run.js.map +1 -1
- package/dist/src/redteam/index.d.ts.map +1 -1
- package/dist/src/redteam/index.js +17 -16
- package/dist/src/redteam/index.js.map +1 -1
- package/dist/src/redteam/plugins/custom.d.ts +15 -4
- package/dist/src/redteam/plugins/custom.d.ts.map +1 -1
- package/dist/src/redteam/plugins/custom.js +37 -3
- package/dist/src/redteam/plugins/custom.js.map +1 -1
- package/dist/src/redteam/plugins/policy.d.ts.map +1 -1
- package/dist/src/redteam/plugins/policy.js +0 -3
- package/dist/src/redteam/plugins/policy.js.map +1 -1
- package/dist/src/redteam/types.d.ts +1 -0
- package/dist/src/redteam/types.d.ts.map +1 -1
- package/dist/src/remoteGrading.d.ts +8 -0
- package/dist/src/remoteGrading.d.ts.map +1 -0
- package/dist/src/remoteGrading.js +35 -0
- package/dist/src/remoteGrading.js.map +1 -0
- package/dist/src/server/server.d.ts.map +1 -1
- package/dist/src/server/server.js +34 -0
- package/dist/src/server/server.js.map +1 -1
- package/dist/src/share.d.ts.map +1 -1
- package/dist/src/share.js +14 -5
- package/dist/src/share.js.map +1 -1
- package/dist/src/types/index.d.ts +8 -0
- package/dist/src/types/index.d.ts.map +1 -1
- package/dist/src/types/index.js +1 -0
- package/dist/src/types/index.js.map +1 -1
- package/dist/src/types/providers.d.ts +2 -0
- package/dist/src/types/providers.d.ts.map +1 -1
- package/dist/src/types/providers.js.map +1 -1
- package/dist/src/util/config/load.d.ts.map +1 -1
- package/dist/src/util/config/load.js +7 -5
- package/dist/src/util/config/load.js.map +1 -1
- package/dist/test/assertions.test.js +14 -14
- package/dist/test/assertions.test.js.map +1 -1
- package/dist/test/commands/init.test.d.ts +2 -0
- package/dist/test/commands/init.test.d.ts.map +1 -0
- package/dist/test/commands/init.test.js +159 -0
- package/dist/test/commands/init.test.js.map +1 -0
- package/dist/test/factories/evalFactory.d.ts +1 -0
- package/dist/test/factories/evalFactory.d.ts.map +1 -1
- package/dist/test/matchers.test.js +75 -0
- package/dist/test/matchers.test.js.map +1 -1
- package/dist/test/providers.packageParser.test.d.ts +2 -0
- package/dist/test/providers.packageParser.test.d.ts.map +1 -0
- package/dist/test/providers.packageParser.test.js +96 -0
- package/dist/test/providers.packageParser.test.js.map +1 -0
- package/dist/test/providers.watsonx.test.d.ts +2 -0
- package/dist/test/providers.watsonx.test.d.ts.map +1 -0
- package/dist/test/providers.watsonx.test.js +211 -0
- package/dist/test/providers.watsonx.test.js.map +1 -0
- package/dist/test/redteam/plugins/custom.test.d.ts +2 -0
- package/dist/test/redteam/plugins/custom.test.d.ts.map +1 -0
- package/dist/test/redteam/plugins/custom.test.js +87 -0
- package/dist/test/redteam/plugins/custom.test.js.map +1 -0
- package/dist/test/util.config.load.test.ts.js +40 -0
- package/dist/test/util.config.load.test.ts.js.map +1 -1
- package/dist/tsconfig.tsbuildinfo +1 -1
- package/package.json +12 -10
- package/dist/src/app/assets/index-BpjzEMiv.js +0 -783
|
@@ -1 +1 @@
|
|
|
1
|
-
.dark-mode-toggle{display:flex;background-color:transparent;border:none;color:#f0f0f0;cursor:pointer;font-size:16px;padding:8px;transition:color .3s}.dark-mode-toggle:hover{color:var(--pass-color)}.logo{display:flex;font-family:monospace,monospace;font-size:.8rem;font-weight:700;align-items:center;gap:8px;background-color:#333;border-color:#444;padding:0 2rem 0 0;border-radius:.5rem}[data-theme=dark] .logo{background-color:#121212}.logo img{width:25px;margin-top:2px}.logo span{color:#f0f0f0}.nav{padding:.25rem 0 .25rem 1rem;gap:1rem;background-color:#333;margin-bottom:1rem;box-shadow:0 4px 6px #0000001a}[data-theme=dark] .nav{background-color:#121212}.nav a{text-decoration:none;align-self:center}@media (max-width: 760px){.nav{font-size:.75rem}}.nav .active{font-weight:700}.nav a{color:#f0f0f0}.nav .right-aligned{display:flex;align-items:center;gap:1rem;margin-left:auto;margin-right:.5rem}.nav a:hover{text-decoration:underline}.nav a:hover{color:#ddd}.prompt-var-highlight{background-color:var(--prompt-highlight-color);padding:.25rem;border-radius:4px}.glowing-border{border:1px solid #5cb3ff;box-shadow:0 0 8px 2px #5cb3ff}code[class*=language-],pre[class*=language-]{color:#000;background:none;text-shadow:0 1px white;font-family:Consolas,Monaco,Andale Mono,Ubuntu Mono,monospace;font-size:1em;text-align:left;white-space:pre;word-spacing:normal;word-break:normal;word-wrap:normal;line-height:1.5;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-hyphens:none;-moz-hyphens:none;-ms-hyphens:none;hyphens:none}pre[class*=language-]::-moz-selection,pre[class*=language-] ::-moz-selection,code[class*=language-]::-moz-selection,code[class*=language-] ::-moz-selection{text-shadow:none;background:#b3d4fc}pre[class*=language-]::selection,pre[class*=language-] ::selection,code[class*=language-]::selection,code[class*=language-] ::selection{text-shadow:none;background:#b3d4fc}@media print{code[class*=language-],pre[class*=language-]{text-shadow:none}}pre[class*=language-]{padding:1em;margin:.5em 0;overflow:auto}:not(pre)>code[class*=language-],pre[class*=language-]{background:#f5f2f0}:not(pre)>code[class*=language-]{padding:.1em;border-radius:.3em;white-space:normal}.token.comment,.token.prolog,.token.doctype,.token.cdata{color:#708090}.token.punctuation{color:#999}.token.namespace{opacity:.7}.token.property,.token.tag,.token.boolean,.token.number,.token.constant,.token.symbol,.token.deleted{color:#905}.token.selector,.token.attr-name,.token.string,.token.char,.token.builtin,.token.inserted{color:#690}.token.operator,.token.entity,.token.url,.language-css .token.string,.style .token.string{color:#9a6e3a;background:#ffffff80}.token.atrule,.token.attr-value,.token.keyword{color:#07a}.token.function,.token.class-name{color:#dd4a68}.token.regex,.token.important,.token.variable{color:#e90}.token.important,.token.bold{font-weight:700}.token.italic{font-style:italic}.token.entity{cursor:help}.yaml-config{font-size:10px}.custom-metric-container{display:inline-flex;flex-wrap:wrap;gap:.25rem;font-weight:400}.custom-metric-container>span{padding:.25rem .5rem;border-radius:4px;color:var(--text-color);border:1px solid var(--border-color);margin-right:.25rem}.custom-metric-container>span.clickable{cursor:pointer}.custom-metric-container>span.clickable:hover{border-color:var(--link-color)}.fail-reason-carousel-controls{float:right;color:var(--text-color);font-weight:400}pre{white-space:pre-wrap}.font-bold{font-weight:700}table.results-table,.divTable{border-collapse:collapse;width:100%;margin:1rem 0;background-color:#fff}[data-theme=dark] table.results-table,[data-theme=dark] .divTable{background-color:#1a1a1a}.results-table ins{background-color:var(--insert-highlight-color);text-decoration:none}.results-table del{background-color:var(--delete-highlight-color);text-decoration:strikethrough}.tr{display:flex}.results-table tr,.tr{width:fit-content}.results-table tr:hover,.tr:hover{background-color:#00000005}.results-table th,.th,.results-table td,.td{position:relative;border:1px solid var(--border-color);vertical-align:top}.compact.results-table th,.compact .th,.compact.results-table td,.compact .td{padding:.5rem}.results-table th.variable,.th.variable,.results-table td.variable,.td.variable{background-color:var(--variable-background-color)}.variable .cell{max-height:100%;overflow-y:auto}.results-table tr.header{background-color:var(--header-background-color)}.results-table th,.th{padding:1rem;position:relative;vertical-align:bottom;text-align:left;white-space:pre-wrap;font-weight:400}.results-table th .action{cursor:pointer;margin-left:.5rem}.results-table th .action svg{vertical-align:middle}.results-table td,.results-table th{height:1px}@-moz-document url-prefix(){.results-table td,.results-table th{height:100%}}.firefox-fix{display:table;height:100%}.results-table tr .cell{display:flex;flex-direction:column;white-space:pre-wrap;height:100%;padding:1rem}.results-table tr .cell img{max-width:256px;max-height:256px;cursor:zoom-in}.results-table tr .cell .prompt{background-color:var(--variable-background-color);border:1px solid var(--border-color);padding:1rem;border-radius:4px;margin-bottom:.5rem;font-family:Courier New,Courier,monospace;font-size:.8rem}.results-table tr .cell .prompt .pill{display:block;background-color:var(--neutral-background-color);border:1px solid var(--border-color);border-radius:4px;padding:.25rem;width:fit-content;margin-bottom:.5rem}.results-table tr .cell-actions{display:flex;gap:.5rem;visibility:hidden;position:absolute;top:1.25rem;right:.75rem;line-height:0;font-size:1.25rem}.results-table tr:hover .cell-actions{visibility:visible}.results-table tr .cell-detail{display:flex;flex-wrap:wrap;column-gap:.5rem;row-gap:.25rem;padding-top:1rem;margin-top:auto}.results-table tr .stat-item{font-weight:400;font-size:.75rem;color:#888}.results-table tr .cell-actions .action{cursor:pointer}.results-table tr .cell table{width:100%;border-collapse:collapse;margin:1rem 0}.results-table tr .cell table th,.results-table tr .cell table td{border:1px solid var(--border-color);padding:.5rem;text-align:left}.results-table tr .cell table th{background-color:var(--header-background-color);font-weight:700}.results-table tr .cell table tr:nth-child(2n){background-color:var(--row-background-color)}.results-table tr .cell table tr:hover{background-color:var(--hover-background-color)}.results-table th .output-header{display:flex;flex-direction:column;height:100%;align-items:flex-start}.results-table th .output-header .pills{display:flex;flex-wrap:wrap;gap:.25rem;align-items:center;margin-bottom:.5rem}.results-table th .prompt-container{font-weight:700;margin-bottom:.5rem}.results-table th .prompt-container>*{display:inline}.results-table th .provider{display:inline-block;padding:.25rem .5rem;background-color:var(--neutral-background-color);border:1px solid var(--border-color);border-radius:4px;margin-right:.25rem}.results-table th .summary{font-weight:400}.results-table th .prompt-detail{display:flex;flex-wrap:wrap;column-gap:.5rem;row-gap:.25rem;font-size:.75rem;color:#888;margin-top:auto}.results-table th .summary .highlight{padding:.25rem .5rem;border-radius:4px;background-color:var(--fail-background-color);border:1px solid var(--border-color)}.results-table th .summary .highlight.success{background-color:var(--success-background-color);border:1px solid var(--pass-color)}.results-table .status{display:flex;flex-direction:column;gap:.25rem;font-weight:700;margin-bottom:.5rem}.results-table .status .pill{display:inline-block;padding:.25rem .5rem;border-radius:4px;margin-right:.25rem;align-self:flex-start}.results-table .pass .pill{background-color:var(--success-background-color);color:var(--pass-color);border:1px solid var(--pass-color)}.results-table .fail .pill{border:1px solid var(--fail-color)}.results-table .fail{color:var(--fail-color)}.fail-reason{color:var(--fail-color);font-weight:700}.compact .fail-reason{display:inline}.results-table .fail .pill{background-color:var(--fail-background-color)}.results-table td .score{font-weight:400}.results-table .comment{margin-top:.5rem;padding:.25rem .5rem;border-radius:4px;background-color:var(--neutral-background-color);font-style:italic;cursor:pointer}.results-table td.first-prompt-col{border-left:2px solid #888}.results-table td.first-prompt-row{border-top:2px solid #888}.search-highlight{color:var(--search-text-color);background-color:var(--search-highlight-color)}.results-table tr .cell .lightbox{position:fixed;top:0;left:0;right:0;bottom:0;background-color:#000000b3;display:flex;align-items:center;justify-content:center;z-index:1000}.results-table tr .cell .lightbox img{max-width:90%;max-height:90%;cursor:zoom-out}.resizer{position:absolute;right:0;top:0;height:100%;width:5px;cursor:col-resize;-webkit-user-select:none;user-select:none;touch-action:none;background:var(--text-color);opacity:.5}.resizer.isResizing{background:var(--text-color);opacity:1}@media (hover: hover){.resizer{opacity:0}*:hover>.resizer{opacity:1}}.description{cursor:pointer;transition:background-color .3s ease}.description:hover{background-color:#f0f0f0}[data-theme=dark] .description:hover{background-color:#2a2a2a}.eval-header{display:flex;align-items:center;flex-grow:1}.eval-header strong{font-weight:500}body{background-color:var(--background-color);color:var(--text-color)}.notice{display:flex;flex-direction:column;gap:1.5rem;justify-content:center;align-items:center;height:9rem}.framework-compliance-card{transition:box-shadow .3s ease-in-out;border-radius:12px;overflow:hidden;background-color:#f5f5f5}.framework-compliance-card:hover{box-shadow:0 8px 16px #0000001a}.compliance-summary{text-align:center;margin-bottom:32px;padding:24px;background-color:#fff;border-radius:8px;box-shadow:0 2px 4px #0000000d}.framework-grid{margin-top:24px}.framework-item{height:100%;transition:transform .3s ease,box-shadow .3s ease}.framework-item:hover{box-shadow:0 4px 8px #0000001a}.framework-item.compliant{background-color:#e8f5e9}.framework-item.non-compliant{background-color:#ffebee}.icon-compliant{color:#4caf50;font-size:24px}.icon-non-compliant{color:#f44336;font-size:24px}[data-theme=dark] .framework-compliance-card{background-color:#1e1e1e}[data-theme=dark] .compliance-summary{background-color:#2a2a2a}[data-theme=dark] .framework-item.compliant{background-color:#4caf501a}[data-theme=dark] .framework-item.non-compliant{background-color:#f443361a}[data-theme=dark] .framework-compliance-card:hover,[data-theme=dark] .framework-item:hover{box-shadow:0 8px 16px #ffffff1a}.framework-item .MuiList-root,.framework-item .MuiListItem-root{padding-top:0;padding-bottom:0}.framework-item .MuiListItemIcon-root{min-width:24px}.framework-item .MuiListItemText-root{margin-top:0;margin-bottom:0}.severity-card{transition:transform .3s ease-in-out,box-shadow .3s ease-in-out}.severity-card:hover{transform:translateY(-5px);box-shadow:0 8px 16px #0000001a}[data-theme=dark] .severity-card:hover{box-shadow:none}.card-critical{border-left:5px solid #ff1744}.card-high{border-left:5px solid #ff9100}.card-medium{border-left:5px solid #ffc400}.card-low{border-left:5px solid #00e676}.risk-category-drawer .MuiListItem-root.failure-item{border:1px solid #e0e0e0;border-radius:8px;margin-bottom:16px;padding:16px;transition:all .3s ease;box-shadow:0 2px 4px #0000000d}.risk-category-drawer .MuiListItem-root.failure-item:hover{border-color:#bdbdbd;box-shadow:0 4px 8px #0000001a}.risk-category-drawer .prompt{font-weight:500;margin-bottom:8px}.risk-category-drawer .output{color:#555;white-space:pre-wrap;word-break:break-word;max-height:100px;overflow-y:auto;background-color:#f5f5f5;padding:8px;border-radius:4px}.risk-category-drawer .failed-tests-header{margin-top:8px;margin-bottom:8px;font-weight:500;border-top:2px solid #e0e0e0;padding-top:1.5rem}@media (prefers-color-scheme: dark){.risk-category-drawer .MuiListItem-root.failure-item{border-color:#424242;background-color:#2c2c2c;box-shadow:0 2px 4px #0003}.risk-category-drawer .MuiListItem-root.failure-item:hover{border-color:#616161;box-shadow:0 4px 8px #0000004d}.risk-category-drawer .prompt{color:#e0e0e0}.risk-category-drawer .output{color:#b0b0b0;background-color:#1e1e1e}.risk-category-drawer .failed-tests-header{color:#e0e0e0;border-top-color:#424242}}.risk-card-container{padding-top:3rem;padding-bottom:3rem}.risk-card-title{font-weight:700}.risk-card-progress{margin-bottom:1rem}.risk-card-issues{color:red}.risk-card-list-item{padding:0;transition:background-color .3s,box-shadow .3s}.risk-card-list-item:hover{background-color:#f0f8ff;box-shadow:0 0 0 1px #add8e6;border-radius:4px}[data-theme=dark] .risk-card-list-item:hover{background-color:#2a2a2a;box-shadow:0 0 0 1px #555;border-radius:4px}.risk-card-icon-passed{color:green;font-size:16px}.risk-card-icon-failed{color:red;font-size:16px}.risk-card-icon-no-tests{color:#888;font-size:16px}.risk-card-percentage{margin-left:8px;font-weight:700}.risk-card-percentage-high{color:#4caf50}.risk-card-percentage-medium{color:#ff9800}.risk-card-percentage-low{color:#f44336}[data-theme=dark] .risk-card-percentage-high{color:#81c784}[data-theme=dark] .risk-card-percentage-medium{color:#ffb74d}[data-theme=dark] .risk-card-percentage-low{color:#e57373}.strategy-stats-card{border-radius:.75rem}div.strategy-stats-content{padding:2rem}.strategy-grid{display:grid;grid-template-columns:repeat(2,1fr);gap:1.5rem}.strategy-item{border:1px solid #eee;border-radius:.5rem;padding:1rem;height:100%}[data-theme=dark] .strategy-item{border:1px solid #424242}.strategy-name{font-weight:500;margin-bottom:.25rem}.strategy-description{margin-bottom:.75rem}.progress-container{margin-bottom:.5rem}.fail-rate{text-align:right}.attack-stats{display:block;text-align:right}.pass-high{color:green!important}.pass-medium{color:#cb8503!important}.pass-low{color:red!important}.vuln-critical{color:red!important;font-weight:700!important}.vuln-high{color:red!important}.vuln-medium{color:#cb8503!important}.vuln-low{color:green!important}.report-header{padding:24px;border-radius:12px;box-shadow:0 4px 6px #0000001a}[data-theme=dark] .report-header{box-shadow:none}.report-details{display:flex;flex-wrap:wrap;gap:12px}.report-details .MuiChip-root{font-size:.875rem}:root{font-family:Inter,system-ui,Avenir,Helvetica,Arial,sans-serif;font-style:normal;font-weight-normal:400;font-weight-bold:700;font-synthesis:none;text-rendering:optimizeLegibility;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;-webkit-text-size-adjust:100%;--background-color: #f5f5f5;--text-color: #404040;--link-color: #2e6585;--border-color: lightgray;--table-border-color: lightgray;--pass-color: green;--fail-color: #ad0000;--success-background-color: #d1ffd7;--fail-background-color: #ffd1d1;--neutral-background-color: #eee;--variable-background-color: #f7f7f7;--header-background-color: #fffdf7;--insert-highlight-color: #d4fcbc;--delete-highlight-color: #fbb6c2;--prompt-highlight-color: linen;--textarea-background-color: #ffffff;--textarea-color: #404040;--search-highlight-color: #ffff00;--search-text-color: inherit}[data-theme=dark]{--background-color: #1a1a1a;--text-color: #f0f0f0;--link-color: #6fcaff;--border-color: #444444;--table-border-color: #444444;--pass-color: #b1e9b3;--fail-color: #ee726a;--success-background-color: #216d2b;--fail-background-color: #6d2121;--neutral-background-color: #424242;--variable-background-color: #333;--header-background-color: #333;--insert-highlight-color: #4f8a34;--delete-highlight-color: #8a3434;--prompt-highlight-color: #67605a;--textarea-background-color: #2d2d2d;--textarea-color: #fff;--search-highlight-color: #ffff00;--search-text-color: #404040}html{font-size:16px;background-color:var(--background-color);color:var(--text-color)}body{margin:0}a{color:var(--link-color);text-decoration:none}a:hover{text-decoration:underline}textarea{background-color:var(--textarea-background-color);color:var(--textarea-color);padding:.5em;border:1px solid var(--border-color);border-radius:.25em;resize:vertical}*{box-sizing:border-box}
|
|
1
|
+
.dark-mode-toggle{display:flex;background-color:transparent;border:none;color:#f0f0f0;cursor:pointer;font-size:16px;padding:8px;transition:color .3s}.dark-mode-toggle:hover{color:var(--pass-color)}.logo{display:flex;font-family:monospace,monospace;font-size:.8rem;font-weight:700;align-items:center;gap:8px;background-color:#333;border-color:#444;padding:0 2rem 0 0;border-radius:.5rem}[data-theme=dark] .logo{background-color:#121212}.logo img{width:25px;margin-top:2px}.logo span{color:#f0f0f0}.nav{padding:.25rem 0 .25rem 1rem;gap:1rem;background-color:#333;margin-bottom:1rem;box-shadow:0 4px 6px #0000001a}[data-theme=dark] .nav{background-color:#121212}.nav a{text-decoration:none;align-self:center}@media (max-width: 760px){.nav{font-size:.75rem}}.nav .active{font-weight:700}.nav a{color:#f0f0f0}.nav .right-aligned{display:flex;align-items:center;gap:1rem;margin-left:auto;margin-right:.5rem}.nav a:hover{text-decoration:underline}.nav a:hover{color:#ddd}.prompt-var-highlight{background-color:var(--prompt-highlight-color);padding:.25rem;border-radius:4px}.glowing-border{border:1px solid #5cb3ff;box-shadow:0 0 8px 2px #5cb3ff}code[class*=language-],pre[class*=language-]{color:#000;background:none;text-shadow:0 1px white;font-family:Consolas,Monaco,Andale Mono,Ubuntu Mono,monospace;font-size:1em;text-align:left;white-space:pre;word-spacing:normal;word-break:normal;word-wrap:normal;line-height:1.5;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-hyphens:none;-moz-hyphens:none;-ms-hyphens:none;hyphens:none}pre[class*=language-]::-moz-selection,pre[class*=language-] ::-moz-selection,code[class*=language-]::-moz-selection,code[class*=language-] ::-moz-selection{text-shadow:none;background:#b3d4fc}pre[class*=language-]::selection,pre[class*=language-] ::selection,code[class*=language-]::selection,code[class*=language-] ::selection{text-shadow:none;background:#b3d4fc}@media print{code[class*=language-],pre[class*=language-]{text-shadow:none}}pre[class*=language-]{padding:1em;margin:.5em 0;overflow:auto}:not(pre)>code[class*=language-],pre[class*=language-]{background:#f5f2f0}:not(pre)>code[class*=language-]{padding:.1em;border-radius:.3em;white-space:normal}.token.comment,.token.prolog,.token.doctype,.token.cdata{color:#708090}.token.punctuation{color:#999}.token.namespace{opacity:.7}.token.property,.token.tag,.token.boolean,.token.number,.token.constant,.token.symbol,.token.deleted{color:#905}.token.selector,.token.attr-name,.token.string,.token.char,.token.builtin,.token.inserted{color:#690}.token.operator,.token.entity,.token.url,.language-css .token.string,.style .token.string{color:#9a6e3a;background:#ffffff80}.token.atrule,.token.attr-value,.token.keyword{color:#07a}.token.function,.token.class-name{color:#dd4a68}.token.regex,.token.important,.token.variable{color:#e90}.token.important,.token.bold{font-weight:700}.token.italic{font-style:italic}.token.entity{cursor:help}.yaml-config{font-size:10px}.custom-metric-container{display:inline-flex;flex-wrap:wrap;gap:.25rem;font-weight:400}.custom-metric-container>span{padding:.25rem .5rem;border-radius:4px;color:var(--text-color);border:1px solid var(--border-color);margin-right:.25rem}.custom-metric-container>span.clickable{cursor:pointer}.custom-metric-container>span.clickable:hover{border-color:var(--link-color)}.fail-reason-carousel-controls{float:right;color:var(--text-color);font-weight:400}pre{white-space:pre-wrap}.font-bold{font-weight:700}table.results-table,.divTable{border-collapse:collapse;width:100%;margin:1rem 0;background-color:#fff}[data-theme=dark] table.results-table,[data-theme=dark] .divTable{background-color:#1a1a1a}.results-table ins{background-color:var(--insert-highlight-color);text-decoration:none}.results-table del{background-color:var(--delete-highlight-color);text-decoration:strikethrough}.tr{display:flex}.results-table tr,.tr{width:fit-content}.results-table tr:hover,.tr:hover{background-color:#00000005}.results-table th,.th,.results-table td,.td{position:relative;border:1px solid var(--border-color);vertical-align:top}.compact.results-table th,.compact .th,.compact.results-table td,.compact .td{padding:.5rem}.results-table th.variable,.th.variable,.results-table td.variable,.td.variable{background-color:var(--variable-background-color)}.variable .cell{max-height:100%;overflow-y:auto}.results-table tr.header{background-color:var(--header-background-color)}.results-table th,.th{padding:1rem;position:relative;vertical-align:bottom;text-align:left;white-space:pre-wrap;font-weight:400}.results-table th .action{cursor:pointer;margin-left:.5rem}.results-table th .action svg{vertical-align:middle}.results-table td,.results-table th{height:1px}@-moz-document url-prefix(){.results-table td,.results-table th{height:100%}}.firefox-fix{display:table;height:100%}.results-table tr .cell{display:flex;flex-direction:column;white-space:pre-wrap;height:100%;padding:1rem}.results-table tr .cell img{max-width:256px;max-height:256px;cursor:zoom-in}.results-table tr .cell .prompt{background-color:var(--variable-background-color);border:1px solid var(--border-color);padding:1rem;border-radius:4px;margin-bottom:.5rem;font-family:Courier New,Courier,monospace;font-size:.8rem}.results-table tr .cell .prompt .pill{display:block;background-color:var(--neutral-background-color);border:1px solid var(--border-color);border-radius:4px;padding:.25rem;width:fit-content;margin-bottom:.5rem}.results-table tr .cell-actions{display:flex;gap:.5rem;visibility:hidden;position:absolute;top:1.25rem;right:.75rem;line-height:0;font-size:1.25rem}.results-table tr:hover .cell-actions{visibility:visible}.results-table tr .cell-detail{display:flex;flex-wrap:wrap;column-gap:.5rem;row-gap:.25rem;padding-top:1rem;margin-top:auto}.results-table tr .stat-item{font-weight:400;font-size:.75rem;color:#888}.results-table tr .cell-actions .action{cursor:pointer}.results-table tr .cell table{width:100%;border-collapse:collapse;margin:1rem 0}.results-table tr .cell table th,.results-table tr .cell table td{border:1px solid var(--border-color);padding:.5rem;text-align:left}.results-table tr .cell table th{background-color:var(--header-background-color);font-weight:700}.results-table tr .cell table tr:nth-child(2n){background-color:var(--row-background-color)}.results-table tr .cell table tr:hover{background-color:var(--hover-background-color)}.results-table th .output-header{display:flex;flex-direction:column;height:100%;align-items:flex-start}.results-table th .output-header .pills{display:flex;flex-wrap:wrap;gap:.25rem;align-items:center;margin-bottom:.5rem}.results-table th .prompt-container{font-weight:700;margin-bottom:.5rem}.results-table th .prompt-container>*{display:inline}.results-table th .provider{display:inline-block;padding:.25rem .5rem;background-color:var(--neutral-background-color);border:1px solid var(--border-color);border-radius:4px;margin-right:.25rem}.results-table th .summary{font-weight:400}.results-table th .prompt-detail{display:flex;flex-wrap:wrap;column-gap:.5rem;row-gap:.25rem;font-size:.75rem;color:#888;margin-top:auto}.results-table th .summary .highlight{padding:.25rem .5rem;border-radius:4px;background-color:var(--fail-background-color);border:1px solid var(--border-color)}.results-table th .summary .highlight.success{background-color:var(--success-background-color);border:1px solid var(--pass-color)}.results-table .status{display:flex;flex-direction:column;gap:.25rem;font-weight:700;margin-bottom:.5rem}.results-table .status .pill{display:inline-block;padding:.25rem .5rem;border-radius:4px;margin-right:.25rem;align-self:flex-start}.results-table .pass .pill{background-color:var(--success-background-color);color:var(--pass-color);border:1px solid var(--pass-color)}.results-table .fail .pill{border:1px solid var(--fail-color)}.results-table .fail{color:var(--fail-color)}.fail-reason{color:var(--fail-color);font-weight:700}.compact .fail-reason{display:inline}.results-table .fail .pill{background-color:var(--fail-background-color)}.results-table td .score{font-weight:400}.results-table .comment{margin-top:.5rem;padding:.25rem .5rem;border-radius:4px;background-color:var(--neutral-background-color);font-style:italic;cursor:pointer}.results-table td.first-prompt-col{border-left:2px solid #888}.results-table td.first-prompt-row{border-top:2px solid #888}.search-highlight{color:var(--search-text-color);background-color:var(--search-highlight-color)}.results-table tr .cell .lightbox{position:fixed;top:0;left:0;right:0;bottom:0;background-color:#000000b3;display:flex;align-items:center;justify-content:center;z-index:1000}.results-table tr .cell .lightbox img{max-width:90%;max-height:90%;cursor:zoom-out}.resizer{position:absolute;right:0;top:0;height:100%;width:5px;cursor:col-resize;-webkit-user-select:none;user-select:none;touch-action:none;background:var(--text-color);opacity:.5}.resizer.isResizing{background:var(--text-color);opacity:1}@media (hover: hover){.resizer{opacity:0}*:hover>.resizer{opacity:1}}.description{cursor:pointer;transition:background-color .3s ease}.description:hover{background-color:#f0f0f0}[data-theme=dark] .description:hover{background-color:#2a2a2a}.eval-header{display:flex;align-items:center;flex-grow:1}.eval-header strong{font-weight:500}body{background-color:var(--background-color);color:var(--text-color)}.notice{display:flex;flex-direction:column;gap:1.5rem;justify-content:center;align-items:center;height:9rem}.page-content{padding:0;margin-top:-15px}.framework-compliance-card{transition:box-shadow .3s ease-in-out;border-radius:12px;overflow:hidden;background-color:#f5f5f5}.framework-compliance-card:hover{box-shadow:0 8px 16px #0000001a}.compliance-summary{text-align:center;margin-bottom:32px;padding:24px;background-color:#fff;border-radius:8px;box-shadow:0 2px 4px #0000000d}.framework-grid{margin-top:24px}.framework-item{height:100%;transition:transform .3s ease,box-shadow .3s ease}.framework-item:hover{box-shadow:0 4px 8px #0000001a}.framework-item.compliant{background-color:#e8f5e9}.framework-item.non-compliant{background-color:#ffebee}.icon-compliant{color:#4caf50;font-size:24px}.icon-non-compliant{color:#f44336;font-size:24px}[data-theme=dark] .framework-compliance-card{background-color:#1e1e1e}[data-theme=dark] .compliance-summary{background-color:#2a2a2a}[data-theme=dark] .framework-item.compliant{background-color:#4caf501a}[data-theme=dark] .framework-item.non-compliant{background-color:#f443361a}[data-theme=dark] .framework-compliance-card:hover,[data-theme=dark] .framework-item:hover{box-shadow:0 8px 16px #ffffff1a}.framework-item .MuiList-root,.framework-item .MuiListItem-root{padding-top:0;padding-bottom:0}.framework-item .MuiListItemIcon-root{min-width:24px}.framework-item .MuiListItemText-root{margin-top:0;margin-bottom:0}.severity-card{transition:transform .3s ease-in-out,box-shadow .3s ease-in-out}.severity-card:hover{transform:translateY(-5px);box-shadow:0 8px 16px #0000001a}[data-theme=dark] .severity-card:hover{box-shadow:none}.card-critical{border-left:5px solid #ff1744}.card-high{border-left:5px solid #ff9100}.card-medium{border-left:5px solid #ffc400}.card-low{border-left:5px solid #00e676}.risk-category-drawer .MuiListItem-root.failure-item{border:1px solid #e0e0e0;border-radius:8px;margin-bottom:16px;padding:16px;transition:all .3s ease;box-shadow:0 2px 4px #0000000d}.risk-category-drawer .MuiListItem-root.failure-item:hover{border-color:#bdbdbd;box-shadow:0 4px 8px #0000001a}.risk-category-drawer .prompt{font-weight:500;margin-bottom:8px}.risk-category-drawer .output{color:#555;white-space:pre-wrap;word-break:break-word;max-height:100px;overflow-y:auto;background-color:#f5f5f5;padding:8px;border-radius:4px}.risk-category-drawer .failed-tests-header{margin-top:8px;margin-bottom:8px;font-weight:500;border-top:2px solid #e0e0e0;padding-top:1.5rem}[data-theme=dark] .risk-category-drawer .MuiListItem-root.failure-item{border-color:#424242;background-color:#2c2c2c;box-shadow:0 2px 4px #0003}[data-theme=dark] .risk-category-drawer .MuiListItem-root.failure-item:hover{border-color:#616161;box-shadow:0 4px 8px #0000004d}[data-theme=dark] .risk-category-drawer .prompt{color:#e0e0e0}[data-theme=dark] .risk-category-drawer .output{color:#b0b0b0;background-color:#1e1e1e}[data-theme=dark] .risk-category-drawer .failed-tests-header{color:#e0e0e0;border-top-color:#424242}.risk-card-container{padding-top:3rem;padding-bottom:3rem}.risk-card-title{font-weight:700}.risk-card-progress{margin-bottom:1rem}.risk-card-issues{color:red}.risk-card-list-item{padding:0;transition:background-color .3s,box-shadow .3s}.risk-card-list-item:hover{background-color:#f0f8ff;box-shadow:0 0 0 1px #add8e6;border-radius:4px}[data-theme=dark] .risk-card-list-item:hover{background-color:#2a2a2a;box-shadow:0 0 0 1px #555;border-radius:4px}.risk-card-icon-passed{color:green;font-size:16px}.risk-card-icon-failed{color:red;font-size:16px}.risk-card-icon-no-tests{color:#888;font-size:16px}.risk-card-percentage{margin-left:8px;font-weight:700}.risk-card-percentage-high{color:#4caf50}.risk-card-percentage-medium{color:#ff9800}.risk-card-percentage-low{color:#f44336}[data-theme=dark] .risk-card-percentage-high{color:#81c784}[data-theme=dark] .risk-card-percentage-medium{color:#ffb74d}[data-theme=dark] .risk-card-percentage-low{color:#e57373}.strategy-stats-card{border-radius:.75rem}div.strategy-stats-content{padding:2rem}.strategy-grid{display:grid;grid-template-columns:repeat(2,1fr);gap:1.5rem}.strategy-item{border:1px solid #eee;border-radius:.5rem;padding:1rem;height:100%}[data-theme=dark] .strategy-item{border:1px solid #424242}.strategy-name{font-weight:500;margin-bottom:.25rem}.strategy-description{margin-bottom:.75rem}.progress-container{margin-bottom:.5rem}.fail-rate{text-align:right}.attack-stats{display:block;text-align:right}.pass-high{color:green!important}.pass-medium{color:#cb8503!important}.pass-low{color:red!important}.vuln-critical{color:red!important;font-weight:700!important}.vuln-high{color:red!important}.vuln-medium{color:#cb8503!important}.vuln-low{color:green!important}.report-header{padding:24px;border-radius:12px;box-shadow:0 4px 6px #0000001a}[data-theme=dark] .report-header{box-shadow:none}.report-details{display:flex;flex-wrap:wrap;gap:12px}.report-details .MuiChip-root{font-size:.875rem}:root{font-family:Inter,system-ui,Avenir,Helvetica,Arial,sans-serif;font-style:normal;font-weight-normal:400;font-weight-bold:700;font-synthesis:none;text-rendering:optimizeLegibility;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;-webkit-text-size-adjust:100%;--background-color: #f5f5f5;--text-color: #404040;--link-color: #2e6585;--border-color: lightgray;--table-border-color: lightgray;--pass-color: green;--fail-color: #ad0000;--success-background-color: #d1ffd7;--fail-background-color: #ffd1d1;--neutral-background-color: #eee;--variable-background-color: #f7f7f7;--header-background-color: #fffdf7;--insert-highlight-color: #d4fcbc;--delete-highlight-color: #fbb6c2;--prompt-highlight-color: linen;--textarea-background-color: #ffffff;--textarea-color: #404040;--search-highlight-color: #ffff00;--search-text-color: inherit}[data-theme=dark]{--background-color: #1a1a1a;--text-color: #f0f0f0;--link-color: #6fcaff;--border-color: #444444;--table-border-color: #444444;--pass-color: #b1e9b3;--fail-color: #ee726a;--success-background-color: #216d2b;--fail-background-color: #6d2121;--neutral-background-color: #424242;--variable-background-color: #333;--header-background-color: #333;--insert-highlight-color: #4f8a34;--delete-highlight-color: #8a3434;--prompt-highlight-color: #67605a;--textarea-background-color: #2d2d2d;--textarea-color: #fff;--search-highlight-color: #ffff00;--search-text-color: #404040}html{font-size:16px;background-color:var(--background-color);color:var(--text-color)}body{margin:0}a{color:var(--link-color);text-decoration:none}a:hover{text-decoration:underline}textarea{background-color:var(--textarea-background-color);color:var(--textarea-color);padding:.5em;border:1px solid var(--border-color);border-radius:.25em;resize:vertical}*{box-sizing:border-box}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{c as Ze,_ as Ha,p as Qe,g as Vo}from"./index-BpjzEMiv.js";var ft=function(a){return a&&a.Math===Math&&a},V=ft(typeof globalThis=="object"&&globalThis)||ft(typeof window=="object"&&window)||ft(typeof self=="object"&&self)||ft(typeof Ze=="object"&&Ze)||ft(typeof Ze=="object"&&Ze)||function(){return this}()||Function("return this")(),wt={},k=function(a){try{return!!a()}catch{return!0}},wl=k,le=!wl(function(){return Object.defineProperty({},1,{get:function(){return 7}})[1]!==7}),Cl=k,br=!Cl(function(){var a=(function(){}).bind();return typeof a!="function"||a.hasOwnProperty("prototype")}),Al=br,Gt=Function.prototype.call,Y=Al?Gt.bind(Gt):function(){return Gt.apply(Gt,arguments)},Do={},ko={}.propertyIsEnumerable,Lo=Object.getOwnPropertyDescriptor,Pl=Lo&&!ko.call({1:2},1);Do.f=Pl?function(e){var t=Lo(this,e);return!!t&&t.enumerable}:ko;var Oi=function(a,e){return{enumerable:!(a&1),configurable:!(a&2),writable:!(a&4),value:e}},Bo=br,jo=Function.prototype,Ya=jo.call,Rl=Bo&&jo.bind.bind(Ya,Ya),L=Bo?Rl:function(a){return function(){return Ya.apply(a,arguments)}},Fo=L,Nl=Fo({}.toString),Il=Fo("".slice),Be=function(a){return Il(Nl(a),8,-1)},Ml=L,_l=k,Vl=Be,Kr=Object,Dl=Ml("".split),Uo=_l(function(){return!Kr("z").propertyIsEnumerable(0)})?function(a){return Vl(a)==="String"?Dl(a,""):Kr(a)}:Kr,je=function(a){return a==null},kl=je,Ll=TypeError,he=function(a){if(kl(a))throw new Ll("Can't call method on "+a);return a},Bl=Uo,jl=he,Ct=function(a){return Bl(jl(a))},Zr=typeof document=="object"&&document.all,B=typeof Zr>"u"&&Zr!==void 0?function(a){return typeof a=="function"||a===Zr}:function(a){return typeof a=="function"},Fl=B,ve=function(a){return typeof a=="object"?a!==null:Fl(a)},Jr=V,Ul=B,Gl=function(a){return Ul(a)?a:void 0},Fe=function(a,e){return arguments.length<2?Gl(Jr[a]):Jr[a]&&Jr[a][e]},zl=L,xr=zl({}.isPrototypeOf),Hl=V,pn=Hl.navigator,yn=pn&&pn.userAgent,At=yn?String(yn):"",Go=V,ea=At,mn=Go.process,bn=Go.Deno,xn=mn&&mn.versions||bn&&bn.version,Tn=xn&&xn.v8,ue,cr;Tn&&(ue=Tn.split("."),cr=ue[0]>0&&ue[0]<4?1:+(ue[0]+ue[1]));!cr&&ea&&(ue=ea.match(/Edge\/(\d+)/),(!ue||ue[1]>=74)&&(ue=ea.match(/Chrome\/(\d+)/),ue&&(cr=+ue[1])));var Si=cr,On=Si,Yl=k,Xl=V,Wl=Xl.String,zo=!!Object.getOwnPropertySymbols&&!Yl(function(){var a=Symbol("symbol detection");return!Wl(a)||!(Object(a)instanceof Symbol)||!Symbol.sham&&On&&On<41}),ql=zo,Ho=ql&&!Symbol.sham&&typeof Symbol.iterator=="symbol",Ql=Fe,Kl=B,Zl=xr,Jl=Ho,eh=Object,Yo=Jl?function(a){return typeof a=="symbol"}:function(a){var e=Ql("Symbol");return Kl(e)&&Zl(e.prototype,eh(a))},th=String,Tr=function(a){try{return th(a)}catch{return"Object"}},rh=B,ah=Tr,ih=TypeError,Te=function(a){if(rh(a))return a;throw new ih(ah(a)+" is not a function")},nh=Te,sh=je,ut=function(a,e){var t=a[e];return sh(t)?void 0:nh(t)},ta=Y,ra=B,aa=ve,oh=TypeError,uh=function(a,e){var t,r;if(e==="string"&&ra(t=a.toString)&&!aa(r=ta(t,a))||ra(t=a.valueOf)&&!aa(r=ta(t,a))||e!=="string"&&ra(t=a.toString)&&!aa(r=ta(t,a)))return r;throw new oh("Can't convert object to primitive value")},Xo={exports:{}},Sn=V,lh=Object.defineProperty,Ei=function(a,e){try{lh(Sn,a,{value:e,configurable:!0,writable:!0})}catch{Sn[a]=e}return e},hh=V,vh=Ei,En="__core-js_shared__",$n=Xo.exports=hh[En]||vh(En,{});($n.versions||($n.versions=[])).push({version:"3.38.1",mode:"global",copyright:"© 2014-2024 Denis Pushkarev (zloirock.ru)",license:"https://github.com/zloirock/core-js/blob/v3.38.1/LICENSE",source:"https://github.com/zloirock/core-js"});var $i=Xo.exports,wn=$i,wi=function(a,e){return wn[a]||(wn[a]=e||{})},fh=he,ch=Object,Or=function(a){return ch(fh(a))},gh=L,dh=Or,ph=gh({}.hasOwnProperty),fe=Object.hasOwn||function(e,t){return ph(dh(e),t)},yh=L,mh=0,bh=Math.random(),xh=yh(1 .toString),Wo=function(a){return"Symbol("+(a===void 0?"":a)+")_"+xh(++mh+bh,36)},Th=V,Oh=wi,Cn=fe,Sh=Wo,Eh=zo,$h=Ho,Je=Th.Symbol,ia=Oh("wks"),wh=$h?Je.for||Je:Je&&Je.withoutSetter||Sh,z=function(a){return Cn(ia,a)||(ia[a]=Eh&&Cn(Je,a)?Je[a]:wh("Symbol."+a)),ia[a]},Ch=Y,An=ve,Pn=Yo,Ah=ut,Ph=uh,Rh=z,Nh=TypeError,Ih=Rh("toPrimitive"),Mh=function(a,e){if(!An(a)||Pn(a))return a;var t=Ah(a,Ih),r;if(t){if(e===void 0&&(e="default"),r=Ch(t,a,e),!An(r)||Pn(r))return r;throw new Nh("Can't convert object to primitive value")}return e===void 0&&(e="number"),Ph(a,e)},_h=Mh,Vh=Yo,qo=function(a){var e=_h(a,"string");return Vh(e)?e:e+""},Dh=V,Rn=ve,Xa=Dh.document,kh=Rn(Xa)&&Rn(Xa.createElement),Sr=function(a){return kh?Xa.createElement(a):{}},Lh=le,Bh=k,jh=Sr,Qo=!Lh&&!Bh(function(){return Object.defineProperty(jh("div"),"a",{get:function(){return 7}}).a!==7}),Fh=le,Uh=Y,Gh=Do,zh=Oi,Hh=Ct,Yh=qo,Xh=fe,Wh=Qo,Nn=Object.getOwnPropertyDescriptor;wt.f=Fh?Nn:function(e,t){if(e=Hh(e),t=Yh(t),Wh)try{return Nn(e,t)}catch{}if(Xh(e,t))return zh(!Uh(Gh.f,e,t),e[t])};var Oe={},qh=le,Qh=k,Ko=qh&&Qh(function(){return Object.defineProperty(function(){},"prototype",{value:42,writable:!1}).prototype!==42}),Kh=ve,Zh=String,Jh=TypeError,J=function(a){if(Kh(a))return a;throw new Jh(Zh(a)+" is not an object")},ev=le,tv=Qo,rv=Ko,zt=J,In=qo,av=TypeError,na=Object.defineProperty,iv=Object.getOwnPropertyDescriptor,sa="enumerable",oa="configurable",ua="writable";Oe.f=ev?rv?function(e,t,r){if(zt(e),t=In(t),zt(r),typeof e=="function"&&t==="prototype"&&"value"in r&&ua in r&&!r[ua]){var i=iv(e,t);i&&i[ua]&&(e[t]=r.value,r={configurable:oa in r?r[oa]:i[oa],enumerable:sa in r?r[sa]:i[sa],writable:!1})}return na(e,t,r)}:na:function(e,t,r){if(zt(e),t=In(t),zt(r),tv)try{return na(e,t,r)}catch{}if("get"in r||"set"in r)throw new av("Accessors not supported");return"value"in r&&(e[t]=r.value),e};var nv=le,sv=Oe,ov=Oi,Pt=nv?function(a,e,t){return sv.f(a,e,ov(1,t))}:function(a,e,t){return a[e]=t,a},Zo={exports:{}},Wa=le,uv=fe,Jo=Function.prototype,lv=Wa&&Object.getOwnPropertyDescriptor,Ci=uv(Jo,"name"),hv=Ci&&(function(){}).name==="something",vv=Ci&&(!Wa||Wa&&lv(Jo,"name").configurable),Er={EXISTS:Ci,PROPER:hv,CONFIGURABLE:vv},fv=L,cv=B,qa=$i,gv=fv(Function.toString);cv(qa.inspectSource)||(qa.inspectSource=function(a){return gv(a)});var Ai=qa.inspectSource,dv=V,pv=B,Mn=dv.WeakMap,yv=pv(Mn)&&/native code/.test(String(Mn)),mv=wi,bv=Wo,_n=mv("keys"),Pi=function(a){return _n[a]||(_n[a]=bv(a))},Ri={},xv=yv,eu=V,Tv=ve,Ov=Pt,la=fe,ha=$i,Sv=Pi,Ev=Ri,Vn="Object already initialized",Qa=eu.TypeError,$v=eu.WeakMap,gr,St,dr,wv=function(a){return dr(a)?St(a):gr(a,{})},Cv=function(a){return function(e){var t;if(!Tv(e)||(t=St(e)).type!==a)throw new Qa("Incompatible receiver, "+a+" required");return t}};if(xv||ha.state){var de=ha.state||(ha.state=new $v);de.get=de.get,de.has=de.has,de.set=de.set,gr=function(a,e){if(de.has(a))throw new Qa(Vn);return e.facade=a,de.set(a,e),e},St=function(a){return de.get(a)||{}},dr=function(a){return de.has(a)}}else{var Ye=Sv("state");Ev[Ye]=!0,gr=function(a,e){if(la(a,Ye))throw new Qa(Vn);return e.facade=a,Ov(a,Ye,e),e},St=function(a){return la(a,Ye)?a[Ye]:{}},dr=function(a){return la(a,Ye)}}var $r={set:gr,get:St,has:dr,enforce:wv,getterFor:Cv},Ni=L,Av=k,Pv=B,Ht=fe,Ka=le,Rv=Er.CONFIGURABLE,Nv=Ai,tu=$r,Iv=tu.enforce,Mv=tu.get,Dn=String,or=Object.defineProperty,_v=Ni("".slice),Vv=Ni("".replace),Dv=Ni([].join),kv=Ka&&!Av(function(){return or(function(){},"length",{value:8}).length!==8}),Lv=String(String).split("String"),Bv=Zo.exports=function(a,e,t){_v(Dn(e),0,7)==="Symbol("&&(e="["+Vv(Dn(e),/^Symbol\(([^)]*)\).*$/,"$1")+"]"),t&&t.getter&&(e="get "+e),t&&t.setter&&(e="set "+e),(!Ht(a,"name")||Rv&&a.name!==e)&&(Ka?or(a,"name",{value:e,configurable:!0}):a.name=e),kv&&t&&Ht(t,"arity")&&a.length!==t.arity&&or(a,"length",{value:t.arity});try{t&&Ht(t,"constructor")&&t.constructor?Ka&&or(a,"prototype",{writable:!1}):a.prototype&&(a.prototype=void 0)}catch{}var r=Iv(a);return Ht(r,"source")||(r.source=Dv(Lv,typeof e=="string"?e:"")),a};Function.prototype.toString=Bv(function(){return Pv(this)&&Mv(this).source||Nv(this)},"toString");var ru=Zo.exports,jv=B,Fv=Oe,Uv=ru,Gv=Ei,Ue=function(a,e,t,r){r||(r={});var i=r.enumerable,n=r.name!==void 0?r.name:e;if(jv(t)&&Uv(t,n,r),r.global)i?a[e]=t:Gv(e,t);else{try{r.unsafe?a[e]&&(i=!0):delete a[e]}catch{}i?a[e]=t:Fv.f(a,e,{value:t,enumerable:!1,configurable:!r.nonConfigurable,writable:!r.nonWritable})}return a},au={},zv=Math.ceil,Hv=Math.floor,Yv=Math.trunc||function(e){var t=+e;return(t>0?Hv:zv)(t)},Xv=Yv,wr=function(a){var e=+a;return e!==e||e===0?0:Xv(e)},Wv=wr,qv=Math.max,Qv=Math.min,Kv=function(a,e){var t=Wv(a);return t<0?qv(t+e,0):Qv(t,e)},Zv=wr,Jv=Math.min,lt=function(a){var e=Zv(a);return e>0?Jv(e,9007199254740991):0},ef=lt,Ii=function(a){return ef(a.length)},tf=Ct,rf=Kv,af=Ii,kn=function(a){return function(e,t,r){var i=tf(e),n=af(i);if(n===0)return!a&&-1;var o=rf(r,n),s;if(a&&t!==t){for(;n>o;)if(s=i[o++],s!==s)return!0}else for(;n>o;o++)if((a||o in i)&&i[o]===t)return a||o||0;return!a&&-1}},iu={includes:kn(!0),indexOf:kn(!1)},nf=L,va=fe,sf=Ct,of=iu.indexOf,uf=Ri,Ln=nf([].push),nu=function(a,e){var t=sf(a),r=0,i=[],n;for(n in t)!va(uf,n)&&va(t,n)&&Ln(i,n);for(;e.length>r;)va(t,n=e[r++])&&(~of(i,n)||Ln(i,n));return i},Mi=["constructor","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","toLocaleString","toString","valueOf"],lf=nu,hf=Mi,vf=hf.concat("length","prototype");au.f=Object.getOwnPropertyNames||function(e){return lf(e,vf)};var su={};su.f=Object.getOwnPropertySymbols;var ff=Fe,cf=L,gf=au,df=su,pf=J,yf=cf([].concat),mf=ff("Reflect","ownKeys")||function(e){var t=gf.f(pf(e)),r=df.f;return r?yf(t,r(e)):t},Bn=fe,bf=mf,xf=wt,Tf=Oe,Of=function(a,e,t){for(var r=bf(e),i=Tf.f,n=xf.f,o=0;o<r.length;o++){var s=r[o];!Bn(a,s)&&!(t&&Bn(t,s))&&i(a,s,n(e,s))}},Sf=k,Ef=B,$f=/#|\.prototype\./,Rt=function(a,e){var t=Cf[wf(a)];return t===Pf?!0:t===Af?!1:Ef(e)?Sf(e):!!e},wf=Rt.normalize=function(a){return String(a).replace($f,".").toLowerCase()},Cf=Rt.data={},Af=Rt.NATIVE="N",Pf=Rt.POLYFILL="P",ou=Rt,Yt=V,Rf=wt.f,Nf=Pt,If=Ue,Mf=Ei,_f=Of,Vf=ou,ee=function(a,e){var t=a.target,r=a.global,i=a.stat,n,o,s,u,l,h;if(r?o=Yt:i?o=Yt[t]||Mf(t,{}):o=Yt[t]&&Yt[t].prototype,o)for(s in e){if(l=e[s],a.dontCallGetSet?(h=Rf(o,s),u=h&&h.value):u=o[s],n=Vf(r?s:t+(i?".":"#")+s,a.forced),!n&&u!==void 0){if(typeof l==typeof u)continue;_f(l,u)}(a.sham||u&&u.sham)&&Nf(l,"sham",!0),If(o,s,l,a)}},ct=V,Df=At,kf=Be,Xt=function(a){return Df.slice(0,a.length)===a},uu=function(){return Xt("Bun/")?"BUN":Xt("Cloudflare-Workers")?"CLOUDFLARE":Xt("Deno/")?"DENO":Xt("Node.js/")?"NODE":ct.Bun&&typeof Bun.version=="string"?"BUN":ct.Deno&&typeof Deno.version=="object"?"DENO":kf(ct.process)==="process"?"NODE":ct.window&&ct.document?"BROWSER":"REST"}(),Lf=uu,Cr=Lf==="NODE",Bf=L,jf=Te,Ff=function(a,e,t){try{return Bf(jf(Object.getOwnPropertyDescriptor(a,e)[t]))}catch{}},Uf=ve,Gf=function(a){return Uf(a)||a===null},zf=Gf,Hf=String,Yf=TypeError,Xf=function(a){if(zf(a))return a;throw new Yf("Can't set "+Hf(a)+" as a prototype")},Wf=Ff,qf=ve,Qf=he,Kf=Xf,lu=Object.setPrototypeOf||("__proto__"in{}?function(){var a=!1,e={},t;try{t=Wf(Object.prototype,"__proto__","set"),t(e,[]),a=e instanceof Array}catch{}return function(i,n){return Qf(i),Kf(n),qf(i)&&(a?t(i,n):i.__proto__=n),i}}():void 0),Zf=Oe.f,Jf=fe,ec=z,jn=ec("toStringTag"),Ar=function(a,e,t){a&&!t&&(a=a.prototype),a&&!Jf(a,jn)&&Zf(a,jn,{configurable:!0,value:e})},Fn=ru,tc=Oe,rc=function(a,e,t){return t.get&&Fn(t.get,e,{getter:!0}),t.set&&Fn(t.set,e,{setter:!0}),tc.f(a,e,t)},ac=Fe,ic=rc,nc=z,sc=le,Un=nc("species"),oc=function(a){var e=ac(a);sc&&e&&!e[Un]&&ic(e,Un,{configurable:!0,get:function(){return this}})},uc=xr,lc=TypeError,hc=function(a,e){if(uc(e,a))return a;throw new lc("Incorrect invocation")},vc=z,fc=vc("toStringTag"),hu={};hu[fc]="z";var cc=String(hu)==="[object z]",gc=cc,dc=B,ur=Be,pc=z,yc=pc("toStringTag"),mc=Object,bc=ur(function(){return arguments}())==="Arguments",xc=function(a,e){try{return a[e]}catch{}},_i=gc?ur:function(a){var e,t,r;return a===void 0?"Undefined":a===null?"Null":typeof(t=xc(e=mc(a),yc))=="string"?t:bc?ur(e):(r=ur(e))==="Object"&&dc(e.callee)?"Arguments":r},Tc=L,Oc=k,vu=B,Sc=_i,Ec=Fe,$c=Ai,fu=function(){},cu=Ec("Reflect","construct"),Vi=/^\s*(?:class|function)\b/,wc=Tc(Vi.exec),Cc=!Vi.test(fu),gt=function(e){if(!vu(e))return!1;try{return cu(fu,[],e),!0}catch{return!1}},gu=function(e){if(!vu(e))return!1;switch(Sc(e)){case"AsyncFunction":case"GeneratorFunction":case"AsyncGeneratorFunction":return!1}try{return Cc||!!wc(Vi,$c(e))}catch{return!0}};gu.sham=!0;var Ac=!cu||Oc(function(){var a;return gt(gt.call)||!gt(Object)||!gt(function(){a=!0})||a})?gu:gt,Pc=Ac,Rc=Tr,Nc=TypeError,Ic=function(a){if(Pc(a))return a;throw new Nc(Rc(a)+" is not a constructor")},Gn=J,Mc=Ic,_c=je,Vc=z,Dc=Vc("species"),du=function(a,e){var t=Gn(a).constructor,r;return t===void 0||_c(r=Gn(t)[Dc])?e:Mc(r)},kc=br,pu=Function.prototype,zn=pu.apply,Hn=pu.call,yu=typeof Reflect=="object"&&Reflect.apply||(kc?Hn.bind(zn):function(){return Hn.apply(zn,arguments)}),Lc=Be,Bc=L,Pr=function(a){if(Lc(a)==="Function")return Bc(a)},Yn=Pr,jc=Te,Fc=br,Uc=Yn(Yn.bind),Di=function(a,e){return jc(a),e===void 0?a:Fc?Uc(a,e):function(){return a.apply(e,arguments)}},Gc=Fe,mu=Gc("document","documentElement"),zc=L,Hc=zc([].slice),Yc=TypeError,Xc=function(a,e){if(a<e)throw new Yc("Not enough arguments");return a},Wc=At,bu=/(?:ipad|iphone|ipod).*applewebkit/i.test(Wc),ae=V,qc=yu,Qc=Di,Xn=B,Kc=fe,xu=k,Wn=mu,Zc=Hc,qn=Sr,Jc=Xc,eg=bu,tg=Cr,Za=ae.setImmediate,Ja=ae.clearImmediate,rg=ae.process,fa=ae.Dispatch,ag=ae.Function,Qn=ae.MessageChannel,ig=ae.String,ca=0,Tt={},Kn="onreadystatechange",Et,Ie,ga,da;xu(function(){Et=ae.location});var ki=function(a){if(Kc(Tt,a)){var e=Tt[a];delete Tt[a],e()}},pa=function(a){return function(){ki(a)}},Zn=function(a){ki(a.data)},Jn=function(a){ae.postMessage(ig(a),Et.protocol+"//"+Et.host)};(!Za||!Ja)&&(Za=function(e){Jc(arguments.length,1);var t=Xn(e)?e:ag(e),r=Zc(arguments,1);return Tt[++ca]=function(){qc(t,void 0,r)},Ie(ca),ca},Ja=function(e){delete Tt[e]},tg?Ie=function(a){rg.nextTick(pa(a))}:fa&&fa.now?Ie=function(a){fa.now(pa(a))}:Qn&&!eg?(ga=new Qn,da=ga.port2,ga.port1.onmessage=Zn,Ie=Qc(da.postMessage,da)):ae.addEventListener&&Xn(ae.postMessage)&&!ae.importScripts&&Et&&Et.protocol!=="file:"&&!xu(Jn)?(Ie=Jn,ae.addEventListener("message",Zn,!1)):Kn in qn("script")?Ie=function(a){Wn.appendChild(qn("script"))[Kn]=function(){Wn.removeChild(this),ki(a)}}:Ie=function(a){setTimeout(pa(a),0)});var Tu={set:Za,clear:Ja},es=V,ng=le,sg=Object.getOwnPropertyDescriptor,og=function(a){if(!ng)return es[a];var e=sg(es,a);return e&&e.value},Ou=function(){this.head=null,this.tail=null};Ou.prototype={add:function(a){var e={item:a,next:null},t=this.tail;t?t.next=e:this.head=e,this.tail=e},get:function(){var a=this.head;if(a){var e=this.head=a.next;return e===null&&(this.tail=null),a.item}}};var Su=Ou,ug=At,lg=/ipad|iphone|ipod/i.test(ug)&&typeof Pebble<"u",hg=At,vg=/web0s(?!.*chrome)/i.test(hg),nt=V,fg=og,ts=Di,ya=Tu.set,cg=Su,gg=bu,dg=lg,pg=vg,ma=Cr,rs=nt.MutationObserver||nt.WebKitMutationObserver,as=nt.document,is=nt.process,Wt=nt.Promise,ei=fg("queueMicrotask"),Xe,ba,xa,qt,ns;if(!ei){var Qt=new cg,Kt=function(){var a,e;for(ma&&(a=is.domain)&&a.exit();e=Qt.get();)try{e()}catch(t){throw Qt.head&&Xe(),t}a&&a.enter()};!gg&&!ma&&!pg&&rs&&as?(ba=!0,xa=as.createTextNode(""),new rs(Kt).observe(xa,{characterData:!0}),Xe=function(){xa.data=ba=!ba}):!dg&&Wt&&Wt.resolve?(qt=Wt.resolve(void 0),qt.constructor=Wt,ns=ts(qt.then,qt),Xe=function(){ns(Kt)}):ma?Xe=function(){is.nextTick(Kt)}:(ya=ts(ya,nt),Xe=function(){ya(Kt)}),ei=function(a){Qt.head||Xe(),Qt.add(a)}}var yg=ei,mg=function(a,e){try{arguments.length===1?console.error(a):console.error(a,e)}catch{}},Li=function(a){try{return{error:!1,value:a()}}catch(e){return{error:!0,value:e}}},bg=V,Rr=bg.Promise,xg=V,Ot=Rr,Tg=B,Og=ou,Sg=Ai,Eg=z,ss=uu,Ta=Si;Ot&&Ot.prototype;var $g=Eg("species"),ti=!1,Eu=Tg(xg.PromiseRejectionEvent),wg=Og("Promise",function(){var a=Sg(Ot),e=a!==String(Ot);if(!e&&Ta===66)return!0;if(!Ta||Ta<51||!/native code/.test(a)){var t=new Ot(function(n){n(1)}),r=function(n){n(function(){},function(){})},i=t.constructor={};if(i[$g]=r,ti=t.then(function(){})instanceof r,!ti)return!0}return!e&&(ss==="BROWSER"||ss==="DENO")&&!Eu}),Nt={CONSTRUCTOR:wg,REJECTION_EVENT:Eu,SUBCLASSING:ti},ht={},os=Te,Cg=TypeError,Ag=function(a){var e,t;this.promise=new a(function(r,i){if(e!==void 0||t!==void 0)throw new Cg("Bad Promise constructor");e=r,t=i}),this.resolve=os(e),this.reject=os(t)};ht.f=function(a){return new Ag(a)};var Pg=ee,pr=Cr,we=V,st=Y,us=Ue,ls=lu,Rg=Ar,Ng=oc,Ig=Te,lr=B,Mg=ve,_g=hc,Vg=du,$u=Tu.set,Bi=yg,Dg=mg,kg=Li,Lg=Su,wu=$r,yr=Rr,ji=Nt,Cu=ht,Nr="Promise",Au=ji.CONSTRUCTOR,Bg=ji.REJECTION_EVENT,jg=ji.SUBCLASSING,Oa=wu.getterFor(Nr),Fg=wu.set,Ke=yr&&yr.prototype,De=yr,Zt=Ke,Pu=we.TypeError,ri=we.document,Fi=we.process,ai=Cu.f,Ug=ai,Gg=!!(ri&&ri.createEvent&&we.dispatchEvent),Ru="unhandledrejection",zg="rejectionhandled",hs=0,Nu=1,Hg=2,Ui=1,Iu=2,Jt,vs,Yg,fs,Mu=function(a){var e;return Mg(a)&&lr(e=a.then)?e:!1},_u=function(a,e){var t=e.value,r=e.state===Nu,i=r?a.ok:a.fail,n=a.resolve,o=a.reject,s=a.domain,u,l,h;try{i?(r||(e.rejection===Iu&&Wg(e),e.rejection=Ui),i===!0?u=t:(s&&s.enter(),u=i(t),s&&(s.exit(),h=!0)),u===a.promise?o(new Pu("Promise-chain cycle")):(l=Mu(u))?st(l,u,n,o):n(u)):o(t)}catch(f){s&&!h&&s.exit(),o(f)}},Vu=function(a,e){a.notified||(a.notified=!0,Bi(function(){for(var t=a.reactions,r;r=t.get();)_u(r,a);a.notified=!1,e&&!a.rejection&&Xg(a)}))},Du=function(a,e,t){var r,i;Gg?(r=ri.createEvent("Event"),r.promise=e,r.reason=t,r.initEvent(a,!1,!0),we.dispatchEvent(r)):r={promise:e,reason:t},!Bg&&(i=we["on"+a])?i(r):a===Ru&&Dg("Unhandled promise rejection",t)},Xg=function(a){st($u,we,function(){var e=a.facade,t=a.value,r=cs(a),i;if(r&&(i=kg(function(){pr?Fi.emit("unhandledRejection",t,e):Du(Ru,e,t)}),a.rejection=pr||cs(a)?Iu:Ui,i.error))throw i.value})},cs=function(a){return a.rejection!==Ui&&!a.parent},Wg=function(a){st($u,we,function(){var e=a.facade;pr?Fi.emit("rejectionHandled",e):Du(zg,e,a.value)})},et=function(a,e,t){return function(r){a(e,r,t)}},rt=function(a,e,t){a.done||(a.done=!0,t&&(a=t),a.value=e,a.state=Hg,Vu(a,!0))},ii=function(a,e,t){if(!a.done){a.done=!0,t&&(a=t);try{if(a.facade===e)throw new Pu("Promise can't be resolved itself");var r=Mu(e);r?Bi(function(){var i={done:!1};try{st(r,e,et(ii,i,a),et(rt,i,a))}catch(n){rt(i,n,a)}}):(a.value=e,a.state=Nu,Vu(a,!1))}catch(i){rt({done:!1},i,a)}}};if(Au&&(De=function(e){_g(this,Zt),Ig(e),st(Jt,this);var t=Oa(this);try{e(et(ii,t),et(rt,t))}catch(r){rt(t,r)}},Zt=De.prototype,Jt=function(e){Fg(this,{type:Nr,done:!1,notified:!1,parent:!1,reactions:new Lg,rejection:!1,state:hs,value:null})},Jt.prototype=us(Zt,"then",function(e,t){var r=Oa(this),i=ai(Vg(this,De));return r.parent=!0,i.ok=lr(e)?e:!0,i.fail=lr(t)&&t,i.domain=pr?Fi.domain:void 0,r.state===hs?r.reactions.add(i):Bi(function(){_u(i,r)}),i.promise}),vs=function(){var a=new Jt,e=Oa(a);this.promise=a,this.resolve=et(ii,e),this.reject=et(rt,e)},Cu.f=ai=function(a){return a===De||a===Yg?new vs(a):Ug(a)},lr(yr)&&Ke!==Object.prototype)){fs=Ke.then,jg||us(Ke,"then",function(e,t){var r=this;return new De(function(i,n){st(fs,r,i,n)}).then(e,t)},{unsafe:!0});try{delete Ke.constructor}catch{}ls&&ls(Ke,Zt)}Pg({global:!0,constructor:!0,wrap:!0,forced:Au},{Promise:De});Rg(De,Nr,!1);Ng(Nr);var It={},qg=z,Qg=It,Kg=qg("iterator"),Zg=Array.prototype,Jg=function(a){return a!==void 0&&(Qg.Array===a||Zg[Kg]===a)},ed=_i,gs=ut,td=je,rd=It,ad=z,id=ad("iterator"),ku=function(a){if(!td(a))return gs(a,id)||gs(a,"@@iterator")||rd[ed(a)]},nd=Y,sd=Te,od=J,ud=Tr,ld=ku,hd=TypeError,vd=function(a,e){var t=arguments.length<2?ld(a):e;if(sd(t))return od(nd(t,a));throw new hd(ud(a)+" is not iterable")},fd=Y,ds=J,cd=ut,gd=function(a,e,t){var r,i;ds(a);try{if(r=cd(a,"return"),!r){if(e==="throw")throw t;return t}r=fd(r,a)}catch(n){i=!0,r=n}if(e==="throw")throw t;if(i)throw r;return ds(r),t},dd=Di,pd=Y,yd=J,md=Tr,bd=Jg,xd=Ii,ps=xr,Td=vd,Od=ku,ys=gd,Sd=TypeError,hr=function(a,e){this.stopped=a,this.result=e},ms=hr.prototype,Lu=function(a,e,t){var r=t&&t.that,i=!!(t&&t.AS_ENTRIES),n=!!(t&&t.IS_RECORD),o=!!(t&&t.IS_ITERATOR),s=!!(t&&t.INTERRUPTED),u=dd(e,r),l,h,f,c,v,d,g,p=function(x){return l&&ys(l,"normal",x),new hr(!0,x)},y=function(x){return i?(yd(x),s?u(x[0],x[1],p):u(x[0],x[1])):s?u(x,p):u(x)};if(n)l=a.iterator;else if(o)l=a;else{if(h=Od(a),!h)throw new Sd(md(a)+" is not iterable");if(bd(h)){for(f=0,c=xd(a);c>f;f++)if(v=y(a[f]),v&&ps(ms,v))return v;return new hr(!1)}l=Td(a,h)}for(d=n?a.next:l.next;!(g=pd(d,l)).done;){try{v=y(g.value)}catch(x){ys(l,"throw",x)}if(typeof v=="object"&&v&&ps(ms,v))return v}return new hr(!1)},Ed=z,Bu=Ed("iterator"),ju=!1;try{var $d=0,bs={next:function(){return{done:!!$d++}},return:function(){ju=!0}};bs[Bu]=function(){return this},Array.from(bs,function(){throw 2})}catch{}var wd=function(a,e){try{if(!e&&!ju)return!1}catch{return!1}var t=!1;try{var r={};r[Bu]=function(){return{next:function(){return{done:t=!0}}}},a(r)}catch{}return t},Cd=Rr,Ad=wd,Pd=Nt.CONSTRUCTOR,Fu=Pd||!Ad(function(a){Cd.all(a).then(void 0,function(){})}),Rd=ee,Nd=Y,Id=Te,Md=ht,_d=Li,Vd=Lu,Dd=Fu;Rd({target:"Promise",stat:!0,forced:Dd},{all:function(e){var t=this,r=Md.f(t),i=r.resolve,n=r.reject,o=_d(function(){var s=Id(t.resolve),u=[],l=0,h=1;Vd(e,function(f){var c=l++,v=!1;h++,Nd(s,t,f).then(function(d){v||(v=!0,u[c]=d,--h||i(u))},n)}),--h||i(u)});return o.error&&n(o.value),r.promise}});var kd=ee,Ld=Nt.CONSTRUCTOR,ni=Rr,Bd=Fe,jd=B,Fd=Ue,xs=ni&&ni.prototype;kd({target:"Promise",proto:!0,forced:Ld,real:!0},{catch:function(a){return this.then(void 0,a)}});if(jd(ni)){var Ts=Bd("Promise").prototype.catch;xs.catch!==Ts&&Fd(xs,"catch",Ts,{unsafe:!0})}var Ud=ee,Gd=Y,zd=Te,Hd=ht,Yd=Li,Xd=Lu,Wd=Fu;Ud({target:"Promise",stat:!0,forced:Wd},{race:function(e){var t=this,r=Hd.f(t),i=r.reject,n=Yd(function(){var o=zd(t.resolve);Xd(e,function(s){Gd(o,t,s).then(r.resolve,i)})});return n.error&&i(n.value),r.promise}});var qd=ee,Qd=ht,Kd=Nt.CONSTRUCTOR;qd({target:"Promise",stat:!0,forced:Kd},{reject:function(e){var t=Qd.f(this),r=t.reject;return r(e),t.promise}});var Zd=J,Jd=ve,ep=ht,tp=function(a,e){if(Zd(a),Jd(e)&&e.constructor===a)return e;var t=ep.f(a),r=t.resolve;return r(e),t.promise},rp=ee,ap=Fe,ip=Nt.CONSTRUCTOR,np=tp;ap("Promise");rp({target:"Promise",stat:!0,forced:ip},{resolve:function(e){return np(this,e)}});function Os(a,e,t,r,i,n,o){try{var s=a[n](o),u=s.value}catch(l){return void t(l)}s.done?e(u):Promise.resolve(u).then(r,i)}function xe(a){return function(){var e=this,t=arguments;return new Promise(function(r,i){var n=a.apply(e,t);function o(u){Os(n,r,i,o,s,"next",u)}function s(u){Os(n,r,i,o,s,"throw",u)}o(void 0)})}}var sp=_i,op=String,pe=function(a){if(sp(a)==="Symbol")throw new TypeError("Cannot convert a Symbol value to a string");return op(a)},up=J,Uu=function(){var a=up(this),e="";return a.hasIndices&&(e+="d"),a.global&&(e+="g"),a.ignoreCase&&(e+="i"),a.multiline&&(e+="m"),a.dotAll&&(e+="s"),a.unicode&&(e+="u"),a.unicodeSets&&(e+="v"),a.sticky&&(e+="y"),e},Gi=k,lp=V,zi=lp.RegExp,Hi=Gi(function(){var a=zi("a","y");return a.lastIndex=2,a.exec("abcd")!==null}),hp=Hi||Gi(function(){return!zi("a","y").sticky}),vp=Hi||Gi(function(){var a=zi("^r","gy");return a.lastIndex=2,a.exec("str")!==null}),Gu={BROKEN_CARET:vp,MISSED_STICKY:hp,UNSUPPORTED_Y:Hi},zu={},fp=nu,cp=Mi,gp=Object.keys||function(e){return fp(e,cp)},dp=le,pp=Ko,yp=Oe,mp=J,bp=Ct,xp=gp;zu.f=dp&&!pp?Object.defineProperties:function(e,t){mp(e);for(var r=bp(t),i=xp(t),n=i.length,o=0,s;n>o;)yp.f(e,s=i[o++],r[s]);return e};var Tp=J,Op=zu,Ss=Mi,Sp=Ri,Ep=mu,$p=Sr,wp=Pi,Es=">",$s="<",si="prototype",oi="script",Hu=wp("IE_PROTO"),Sa=function(){},Yu=function(a){return $s+oi+Es+a+$s+"/"+oi+Es},ws=function(a){a.write(Yu("")),a.close();var e=a.parentWindow.Object;return a=null,e},Cp=function(){var a=$p("iframe"),e="java"+oi+":",t;return a.style.display="none",Ep.appendChild(a),a.src=String(e),t=a.contentWindow.document,t.open(),t.write(Yu("document.F=Object")),t.close(),t.F},er,vr=function(){try{er=new ActiveXObject("htmlfile")}catch{}vr=typeof document<"u"?document.domain&&er?ws(er):Cp():ws(er);for(var a=Ss.length;a--;)delete vr[si][Ss[a]];return vr()};Sp[Hu]=!0;var Yi=Object.create||function(e,t){var r;return e!==null?(Sa[si]=Tp(e),r=new Sa,Sa[si]=null,r[Hu]=e):r=vr(),t===void 0?r:Op.f(r,t)},Ap=k,Pp=V,Rp=Pp.RegExp,Np=Ap(function(){var a=Rp(".","s");return!(a.dotAll&&a.test(`
|
|
1
|
+
import{c as Ze,_ as Ha,p as Qe,g as Vo}from"./index-CQmOdU-e.js";var ft=function(a){return a&&a.Math===Math&&a},V=ft(typeof globalThis=="object"&&globalThis)||ft(typeof window=="object"&&window)||ft(typeof self=="object"&&self)||ft(typeof Ze=="object"&&Ze)||ft(typeof Ze=="object"&&Ze)||function(){return this}()||Function("return this")(),wt={},k=function(a){try{return!!a()}catch{return!0}},wl=k,le=!wl(function(){return Object.defineProperty({},1,{get:function(){return 7}})[1]!==7}),Cl=k,br=!Cl(function(){var a=(function(){}).bind();return typeof a!="function"||a.hasOwnProperty("prototype")}),Al=br,Gt=Function.prototype.call,Y=Al?Gt.bind(Gt):function(){return Gt.apply(Gt,arguments)},Do={},ko={}.propertyIsEnumerable,Lo=Object.getOwnPropertyDescriptor,Pl=Lo&&!ko.call({1:2},1);Do.f=Pl?function(e){var t=Lo(this,e);return!!t&&t.enumerable}:ko;var Oi=function(a,e){return{enumerable:!(a&1),configurable:!(a&2),writable:!(a&4),value:e}},Bo=br,jo=Function.prototype,Ya=jo.call,Rl=Bo&&jo.bind.bind(Ya,Ya),L=Bo?Rl:function(a){return function(){return Ya.apply(a,arguments)}},Fo=L,Nl=Fo({}.toString),Il=Fo("".slice),Be=function(a){return Il(Nl(a),8,-1)},Ml=L,_l=k,Vl=Be,Kr=Object,Dl=Ml("".split),Uo=_l(function(){return!Kr("z").propertyIsEnumerable(0)})?function(a){return Vl(a)==="String"?Dl(a,""):Kr(a)}:Kr,je=function(a){return a==null},kl=je,Ll=TypeError,he=function(a){if(kl(a))throw new Ll("Can't call method on "+a);return a},Bl=Uo,jl=he,Ct=function(a){return Bl(jl(a))},Zr=typeof document=="object"&&document.all,B=typeof Zr>"u"&&Zr!==void 0?function(a){return typeof a=="function"||a===Zr}:function(a){return typeof a=="function"},Fl=B,ve=function(a){return typeof a=="object"?a!==null:Fl(a)},Jr=V,Ul=B,Gl=function(a){return Ul(a)?a:void 0},Fe=function(a,e){return arguments.length<2?Gl(Jr[a]):Jr[a]&&Jr[a][e]},zl=L,xr=zl({}.isPrototypeOf),Hl=V,pn=Hl.navigator,yn=pn&&pn.userAgent,At=yn?String(yn):"",Go=V,ea=At,mn=Go.process,bn=Go.Deno,xn=mn&&mn.versions||bn&&bn.version,Tn=xn&&xn.v8,ue,cr;Tn&&(ue=Tn.split("."),cr=ue[0]>0&&ue[0]<4?1:+(ue[0]+ue[1]));!cr&&ea&&(ue=ea.match(/Edge\/(\d+)/),(!ue||ue[1]>=74)&&(ue=ea.match(/Chrome\/(\d+)/),ue&&(cr=+ue[1])));var Si=cr,On=Si,Yl=k,Xl=V,Wl=Xl.String,zo=!!Object.getOwnPropertySymbols&&!Yl(function(){var a=Symbol("symbol detection");return!Wl(a)||!(Object(a)instanceof Symbol)||!Symbol.sham&&On&&On<41}),ql=zo,Ho=ql&&!Symbol.sham&&typeof Symbol.iterator=="symbol",Ql=Fe,Kl=B,Zl=xr,Jl=Ho,eh=Object,Yo=Jl?function(a){return typeof a=="symbol"}:function(a){var e=Ql("Symbol");return Kl(e)&&Zl(e.prototype,eh(a))},th=String,Tr=function(a){try{return th(a)}catch{return"Object"}},rh=B,ah=Tr,ih=TypeError,Te=function(a){if(rh(a))return a;throw new ih(ah(a)+" is not a function")},nh=Te,sh=je,ut=function(a,e){var t=a[e];return sh(t)?void 0:nh(t)},ta=Y,ra=B,aa=ve,oh=TypeError,uh=function(a,e){var t,r;if(e==="string"&&ra(t=a.toString)&&!aa(r=ta(t,a))||ra(t=a.valueOf)&&!aa(r=ta(t,a))||e!=="string"&&ra(t=a.toString)&&!aa(r=ta(t,a)))return r;throw new oh("Can't convert object to primitive value")},Xo={exports:{}},Sn=V,lh=Object.defineProperty,Ei=function(a,e){try{lh(Sn,a,{value:e,configurable:!0,writable:!0})}catch{Sn[a]=e}return e},hh=V,vh=Ei,En="__core-js_shared__",$n=Xo.exports=hh[En]||vh(En,{});($n.versions||($n.versions=[])).push({version:"3.38.1",mode:"global",copyright:"© 2014-2024 Denis Pushkarev (zloirock.ru)",license:"https://github.com/zloirock/core-js/blob/v3.38.1/LICENSE",source:"https://github.com/zloirock/core-js"});var $i=Xo.exports,wn=$i,wi=function(a,e){return wn[a]||(wn[a]=e||{})},fh=he,ch=Object,Or=function(a){return ch(fh(a))},gh=L,dh=Or,ph=gh({}.hasOwnProperty),fe=Object.hasOwn||function(e,t){return ph(dh(e),t)},yh=L,mh=0,bh=Math.random(),xh=yh(1 .toString),Wo=function(a){return"Symbol("+(a===void 0?"":a)+")_"+xh(++mh+bh,36)},Th=V,Oh=wi,Cn=fe,Sh=Wo,Eh=zo,$h=Ho,Je=Th.Symbol,ia=Oh("wks"),wh=$h?Je.for||Je:Je&&Je.withoutSetter||Sh,z=function(a){return Cn(ia,a)||(ia[a]=Eh&&Cn(Je,a)?Je[a]:wh("Symbol."+a)),ia[a]},Ch=Y,An=ve,Pn=Yo,Ah=ut,Ph=uh,Rh=z,Nh=TypeError,Ih=Rh("toPrimitive"),Mh=function(a,e){if(!An(a)||Pn(a))return a;var t=Ah(a,Ih),r;if(t){if(e===void 0&&(e="default"),r=Ch(t,a,e),!An(r)||Pn(r))return r;throw new Nh("Can't convert object to primitive value")}return e===void 0&&(e="number"),Ph(a,e)},_h=Mh,Vh=Yo,qo=function(a){var e=_h(a,"string");return Vh(e)?e:e+""},Dh=V,Rn=ve,Xa=Dh.document,kh=Rn(Xa)&&Rn(Xa.createElement),Sr=function(a){return kh?Xa.createElement(a):{}},Lh=le,Bh=k,jh=Sr,Qo=!Lh&&!Bh(function(){return Object.defineProperty(jh("div"),"a",{get:function(){return 7}}).a!==7}),Fh=le,Uh=Y,Gh=Do,zh=Oi,Hh=Ct,Yh=qo,Xh=fe,Wh=Qo,Nn=Object.getOwnPropertyDescriptor;wt.f=Fh?Nn:function(e,t){if(e=Hh(e),t=Yh(t),Wh)try{return Nn(e,t)}catch{}if(Xh(e,t))return zh(!Uh(Gh.f,e,t),e[t])};var Oe={},qh=le,Qh=k,Ko=qh&&Qh(function(){return Object.defineProperty(function(){},"prototype",{value:42,writable:!1}).prototype!==42}),Kh=ve,Zh=String,Jh=TypeError,J=function(a){if(Kh(a))return a;throw new Jh(Zh(a)+" is not an object")},ev=le,tv=Qo,rv=Ko,zt=J,In=qo,av=TypeError,na=Object.defineProperty,iv=Object.getOwnPropertyDescriptor,sa="enumerable",oa="configurable",ua="writable";Oe.f=ev?rv?function(e,t,r){if(zt(e),t=In(t),zt(r),typeof e=="function"&&t==="prototype"&&"value"in r&&ua in r&&!r[ua]){var i=iv(e,t);i&&i[ua]&&(e[t]=r.value,r={configurable:oa in r?r[oa]:i[oa],enumerable:sa in r?r[sa]:i[sa],writable:!1})}return na(e,t,r)}:na:function(e,t,r){if(zt(e),t=In(t),zt(r),tv)try{return na(e,t,r)}catch{}if("get"in r||"set"in r)throw new av("Accessors not supported");return"value"in r&&(e[t]=r.value),e};var nv=le,sv=Oe,ov=Oi,Pt=nv?function(a,e,t){return sv.f(a,e,ov(1,t))}:function(a,e,t){return a[e]=t,a},Zo={exports:{}},Wa=le,uv=fe,Jo=Function.prototype,lv=Wa&&Object.getOwnPropertyDescriptor,Ci=uv(Jo,"name"),hv=Ci&&(function(){}).name==="something",vv=Ci&&(!Wa||Wa&&lv(Jo,"name").configurable),Er={EXISTS:Ci,PROPER:hv,CONFIGURABLE:vv},fv=L,cv=B,qa=$i,gv=fv(Function.toString);cv(qa.inspectSource)||(qa.inspectSource=function(a){return gv(a)});var Ai=qa.inspectSource,dv=V,pv=B,Mn=dv.WeakMap,yv=pv(Mn)&&/native code/.test(String(Mn)),mv=wi,bv=Wo,_n=mv("keys"),Pi=function(a){return _n[a]||(_n[a]=bv(a))},Ri={},xv=yv,eu=V,Tv=ve,Ov=Pt,la=fe,ha=$i,Sv=Pi,Ev=Ri,Vn="Object already initialized",Qa=eu.TypeError,$v=eu.WeakMap,gr,St,dr,wv=function(a){return dr(a)?St(a):gr(a,{})},Cv=function(a){return function(e){var t;if(!Tv(e)||(t=St(e)).type!==a)throw new Qa("Incompatible receiver, "+a+" required");return t}};if(xv||ha.state){var de=ha.state||(ha.state=new $v);de.get=de.get,de.has=de.has,de.set=de.set,gr=function(a,e){if(de.has(a))throw new Qa(Vn);return e.facade=a,de.set(a,e),e},St=function(a){return de.get(a)||{}},dr=function(a){return de.has(a)}}else{var Ye=Sv("state");Ev[Ye]=!0,gr=function(a,e){if(la(a,Ye))throw new Qa(Vn);return e.facade=a,Ov(a,Ye,e),e},St=function(a){return la(a,Ye)?a[Ye]:{}},dr=function(a){return la(a,Ye)}}var $r={set:gr,get:St,has:dr,enforce:wv,getterFor:Cv},Ni=L,Av=k,Pv=B,Ht=fe,Ka=le,Rv=Er.CONFIGURABLE,Nv=Ai,tu=$r,Iv=tu.enforce,Mv=tu.get,Dn=String,or=Object.defineProperty,_v=Ni("".slice),Vv=Ni("".replace),Dv=Ni([].join),kv=Ka&&!Av(function(){return or(function(){},"length",{value:8}).length!==8}),Lv=String(String).split("String"),Bv=Zo.exports=function(a,e,t){_v(Dn(e),0,7)==="Symbol("&&(e="["+Vv(Dn(e),/^Symbol\(([^)]*)\).*$/,"$1")+"]"),t&&t.getter&&(e="get "+e),t&&t.setter&&(e="set "+e),(!Ht(a,"name")||Rv&&a.name!==e)&&(Ka?or(a,"name",{value:e,configurable:!0}):a.name=e),kv&&t&&Ht(t,"arity")&&a.length!==t.arity&&or(a,"length",{value:t.arity});try{t&&Ht(t,"constructor")&&t.constructor?Ka&&or(a,"prototype",{writable:!1}):a.prototype&&(a.prototype=void 0)}catch{}var r=Iv(a);return Ht(r,"source")||(r.source=Dv(Lv,typeof e=="string"?e:"")),a};Function.prototype.toString=Bv(function(){return Pv(this)&&Mv(this).source||Nv(this)},"toString");var ru=Zo.exports,jv=B,Fv=Oe,Uv=ru,Gv=Ei,Ue=function(a,e,t,r){r||(r={});var i=r.enumerable,n=r.name!==void 0?r.name:e;if(jv(t)&&Uv(t,n,r),r.global)i?a[e]=t:Gv(e,t);else{try{r.unsafe?a[e]&&(i=!0):delete a[e]}catch{}i?a[e]=t:Fv.f(a,e,{value:t,enumerable:!1,configurable:!r.nonConfigurable,writable:!r.nonWritable})}return a},au={},zv=Math.ceil,Hv=Math.floor,Yv=Math.trunc||function(e){var t=+e;return(t>0?Hv:zv)(t)},Xv=Yv,wr=function(a){var e=+a;return e!==e||e===0?0:Xv(e)},Wv=wr,qv=Math.max,Qv=Math.min,Kv=function(a,e){var t=Wv(a);return t<0?qv(t+e,0):Qv(t,e)},Zv=wr,Jv=Math.min,lt=function(a){var e=Zv(a);return e>0?Jv(e,9007199254740991):0},ef=lt,Ii=function(a){return ef(a.length)},tf=Ct,rf=Kv,af=Ii,kn=function(a){return function(e,t,r){var i=tf(e),n=af(i);if(n===0)return!a&&-1;var o=rf(r,n),s;if(a&&t!==t){for(;n>o;)if(s=i[o++],s!==s)return!0}else for(;n>o;o++)if((a||o in i)&&i[o]===t)return a||o||0;return!a&&-1}},iu={includes:kn(!0),indexOf:kn(!1)},nf=L,va=fe,sf=Ct,of=iu.indexOf,uf=Ri,Ln=nf([].push),nu=function(a,e){var t=sf(a),r=0,i=[],n;for(n in t)!va(uf,n)&&va(t,n)&&Ln(i,n);for(;e.length>r;)va(t,n=e[r++])&&(~of(i,n)||Ln(i,n));return i},Mi=["constructor","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","toLocaleString","toString","valueOf"],lf=nu,hf=Mi,vf=hf.concat("length","prototype");au.f=Object.getOwnPropertyNames||function(e){return lf(e,vf)};var su={};su.f=Object.getOwnPropertySymbols;var ff=Fe,cf=L,gf=au,df=su,pf=J,yf=cf([].concat),mf=ff("Reflect","ownKeys")||function(e){var t=gf.f(pf(e)),r=df.f;return r?yf(t,r(e)):t},Bn=fe,bf=mf,xf=wt,Tf=Oe,Of=function(a,e,t){for(var r=bf(e),i=Tf.f,n=xf.f,o=0;o<r.length;o++){var s=r[o];!Bn(a,s)&&!(t&&Bn(t,s))&&i(a,s,n(e,s))}},Sf=k,Ef=B,$f=/#|\.prototype\./,Rt=function(a,e){var t=Cf[wf(a)];return t===Pf?!0:t===Af?!1:Ef(e)?Sf(e):!!e},wf=Rt.normalize=function(a){return String(a).replace($f,".").toLowerCase()},Cf=Rt.data={},Af=Rt.NATIVE="N",Pf=Rt.POLYFILL="P",ou=Rt,Yt=V,Rf=wt.f,Nf=Pt,If=Ue,Mf=Ei,_f=Of,Vf=ou,ee=function(a,e){var t=a.target,r=a.global,i=a.stat,n,o,s,u,l,h;if(r?o=Yt:i?o=Yt[t]||Mf(t,{}):o=Yt[t]&&Yt[t].prototype,o)for(s in e){if(l=e[s],a.dontCallGetSet?(h=Rf(o,s),u=h&&h.value):u=o[s],n=Vf(r?s:t+(i?".":"#")+s,a.forced),!n&&u!==void 0){if(typeof l==typeof u)continue;_f(l,u)}(a.sham||u&&u.sham)&&Nf(l,"sham",!0),If(o,s,l,a)}},ct=V,Df=At,kf=Be,Xt=function(a){return Df.slice(0,a.length)===a},uu=function(){return Xt("Bun/")?"BUN":Xt("Cloudflare-Workers")?"CLOUDFLARE":Xt("Deno/")?"DENO":Xt("Node.js/")?"NODE":ct.Bun&&typeof Bun.version=="string"?"BUN":ct.Deno&&typeof Deno.version=="object"?"DENO":kf(ct.process)==="process"?"NODE":ct.window&&ct.document?"BROWSER":"REST"}(),Lf=uu,Cr=Lf==="NODE",Bf=L,jf=Te,Ff=function(a,e,t){try{return Bf(jf(Object.getOwnPropertyDescriptor(a,e)[t]))}catch{}},Uf=ve,Gf=function(a){return Uf(a)||a===null},zf=Gf,Hf=String,Yf=TypeError,Xf=function(a){if(zf(a))return a;throw new Yf("Can't set "+Hf(a)+" as a prototype")},Wf=Ff,qf=ve,Qf=he,Kf=Xf,lu=Object.setPrototypeOf||("__proto__"in{}?function(){var a=!1,e={},t;try{t=Wf(Object.prototype,"__proto__","set"),t(e,[]),a=e instanceof Array}catch{}return function(i,n){return Qf(i),Kf(n),qf(i)&&(a?t(i,n):i.__proto__=n),i}}():void 0),Zf=Oe.f,Jf=fe,ec=z,jn=ec("toStringTag"),Ar=function(a,e,t){a&&!t&&(a=a.prototype),a&&!Jf(a,jn)&&Zf(a,jn,{configurable:!0,value:e})},Fn=ru,tc=Oe,rc=function(a,e,t){return t.get&&Fn(t.get,e,{getter:!0}),t.set&&Fn(t.set,e,{setter:!0}),tc.f(a,e,t)},ac=Fe,ic=rc,nc=z,sc=le,Un=nc("species"),oc=function(a){var e=ac(a);sc&&e&&!e[Un]&&ic(e,Un,{configurable:!0,get:function(){return this}})},uc=xr,lc=TypeError,hc=function(a,e){if(uc(e,a))return a;throw new lc("Incorrect invocation")},vc=z,fc=vc("toStringTag"),hu={};hu[fc]="z";var cc=String(hu)==="[object z]",gc=cc,dc=B,ur=Be,pc=z,yc=pc("toStringTag"),mc=Object,bc=ur(function(){return arguments}())==="Arguments",xc=function(a,e){try{return a[e]}catch{}},_i=gc?ur:function(a){var e,t,r;return a===void 0?"Undefined":a===null?"Null":typeof(t=xc(e=mc(a),yc))=="string"?t:bc?ur(e):(r=ur(e))==="Object"&&dc(e.callee)?"Arguments":r},Tc=L,Oc=k,vu=B,Sc=_i,Ec=Fe,$c=Ai,fu=function(){},cu=Ec("Reflect","construct"),Vi=/^\s*(?:class|function)\b/,wc=Tc(Vi.exec),Cc=!Vi.test(fu),gt=function(e){if(!vu(e))return!1;try{return cu(fu,[],e),!0}catch{return!1}},gu=function(e){if(!vu(e))return!1;switch(Sc(e)){case"AsyncFunction":case"GeneratorFunction":case"AsyncGeneratorFunction":return!1}try{return Cc||!!wc(Vi,$c(e))}catch{return!0}};gu.sham=!0;var Ac=!cu||Oc(function(){var a;return gt(gt.call)||!gt(Object)||!gt(function(){a=!0})||a})?gu:gt,Pc=Ac,Rc=Tr,Nc=TypeError,Ic=function(a){if(Pc(a))return a;throw new Nc(Rc(a)+" is not a constructor")},Gn=J,Mc=Ic,_c=je,Vc=z,Dc=Vc("species"),du=function(a,e){var t=Gn(a).constructor,r;return t===void 0||_c(r=Gn(t)[Dc])?e:Mc(r)},kc=br,pu=Function.prototype,zn=pu.apply,Hn=pu.call,yu=typeof Reflect=="object"&&Reflect.apply||(kc?Hn.bind(zn):function(){return Hn.apply(zn,arguments)}),Lc=Be,Bc=L,Pr=function(a){if(Lc(a)==="Function")return Bc(a)},Yn=Pr,jc=Te,Fc=br,Uc=Yn(Yn.bind),Di=function(a,e){return jc(a),e===void 0?a:Fc?Uc(a,e):function(){return a.apply(e,arguments)}},Gc=Fe,mu=Gc("document","documentElement"),zc=L,Hc=zc([].slice),Yc=TypeError,Xc=function(a,e){if(a<e)throw new Yc("Not enough arguments");return a},Wc=At,bu=/(?:ipad|iphone|ipod).*applewebkit/i.test(Wc),ae=V,qc=yu,Qc=Di,Xn=B,Kc=fe,xu=k,Wn=mu,Zc=Hc,qn=Sr,Jc=Xc,eg=bu,tg=Cr,Za=ae.setImmediate,Ja=ae.clearImmediate,rg=ae.process,fa=ae.Dispatch,ag=ae.Function,Qn=ae.MessageChannel,ig=ae.String,ca=0,Tt={},Kn="onreadystatechange",Et,Ie,ga,da;xu(function(){Et=ae.location});var ki=function(a){if(Kc(Tt,a)){var e=Tt[a];delete Tt[a],e()}},pa=function(a){return function(){ki(a)}},Zn=function(a){ki(a.data)},Jn=function(a){ae.postMessage(ig(a),Et.protocol+"//"+Et.host)};(!Za||!Ja)&&(Za=function(e){Jc(arguments.length,1);var t=Xn(e)?e:ag(e),r=Zc(arguments,1);return Tt[++ca]=function(){qc(t,void 0,r)},Ie(ca),ca},Ja=function(e){delete Tt[e]},tg?Ie=function(a){rg.nextTick(pa(a))}:fa&&fa.now?Ie=function(a){fa.now(pa(a))}:Qn&&!eg?(ga=new Qn,da=ga.port2,ga.port1.onmessage=Zn,Ie=Qc(da.postMessage,da)):ae.addEventListener&&Xn(ae.postMessage)&&!ae.importScripts&&Et&&Et.protocol!=="file:"&&!xu(Jn)?(Ie=Jn,ae.addEventListener("message",Zn,!1)):Kn in qn("script")?Ie=function(a){Wn.appendChild(qn("script"))[Kn]=function(){Wn.removeChild(this),ki(a)}}:Ie=function(a){setTimeout(pa(a),0)});var Tu={set:Za,clear:Ja},es=V,ng=le,sg=Object.getOwnPropertyDescriptor,og=function(a){if(!ng)return es[a];var e=sg(es,a);return e&&e.value},Ou=function(){this.head=null,this.tail=null};Ou.prototype={add:function(a){var e={item:a,next:null},t=this.tail;t?t.next=e:this.head=e,this.tail=e},get:function(){var a=this.head;if(a){var e=this.head=a.next;return e===null&&(this.tail=null),a.item}}};var Su=Ou,ug=At,lg=/ipad|iphone|ipod/i.test(ug)&&typeof Pebble<"u",hg=At,vg=/web0s(?!.*chrome)/i.test(hg),nt=V,fg=og,ts=Di,ya=Tu.set,cg=Su,gg=bu,dg=lg,pg=vg,ma=Cr,rs=nt.MutationObserver||nt.WebKitMutationObserver,as=nt.document,is=nt.process,Wt=nt.Promise,ei=fg("queueMicrotask"),Xe,ba,xa,qt,ns;if(!ei){var Qt=new cg,Kt=function(){var a,e;for(ma&&(a=is.domain)&&a.exit();e=Qt.get();)try{e()}catch(t){throw Qt.head&&Xe(),t}a&&a.enter()};!gg&&!ma&&!pg&&rs&&as?(ba=!0,xa=as.createTextNode(""),new rs(Kt).observe(xa,{characterData:!0}),Xe=function(){xa.data=ba=!ba}):!dg&&Wt&&Wt.resolve?(qt=Wt.resolve(void 0),qt.constructor=Wt,ns=ts(qt.then,qt),Xe=function(){ns(Kt)}):ma?Xe=function(){is.nextTick(Kt)}:(ya=ts(ya,nt),Xe=function(){ya(Kt)}),ei=function(a){Qt.head||Xe(),Qt.add(a)}}var yg=ei,mg=function(a,e){try{arguments.length===1?console.error(a):console.error(a,e)}catch{}},Li=function(a){try{return{error:!1,value:a()}}catch(e){return{error:!0,value:e}}},bg=V,Rr=bg.Promise,xg=V,Ot=Rr,Tg=B,Og=ou,Sg=Ai,Eg=z,ss=uu,Ta=Si;Ot&&Ot.prototype;var $g=Eg("species"),ti=!1,Eu=Tg(xg.PromiseRejectionEvent),wg=Og("Promise",function(){var a=Sg(Ot),e=a!==String(Ot);if(!e&&Ta===66)return!0;if(!Ta||Ta<51||!/native code/.test(a)){var t=new Ot(function(n){n(1)}),r=function(n){n(function(){},function(){})},i=t.constructor={};if(i[$g]=r,ti=t.then(function(){})instanceof r,!ti)return!0}return!e&&(ss==="BROWSER"||ss==="DENO")&&!Eu}),Nt={CONSTRUCTOR:wg,REJECTION_EVENT:Eu,SUBCLASSING:ti},ht={},os=Te,Cg=TypeError,Ag=function(a){var e,t;this.promise=new a(function(r,i){if(e!==void 0||t!==void 0)throw new Cg("Bad Promise constructor");e=r,t=i}),this.resolve=os(e),this.reject=os(t)};ht.f=function(a){return new Ag(a)};var Pg=ee,pr=Cr,we=V,st=Y,us=Ue,ls=lu,Rg=Ar,Ng=oc,Ig=Te,lr=B,Mg=ve,_g=hc,Vg=du,$u=Tu.set,Bi=yg,Dg=mg,kg=Li,Lg=Su,wu=$r,yr=Rr,ji=Nt,Cu=ht,Nr="Promise",Au=ji.CONSTRUCTOR,Bg=ji.REJECTION_EVENT,jg=ji.SUBCLASSING,Oa=wu.getterFor(Nr),Fg=wu.set,Ke=yr&&yr.prototype,De=yr,Zt=Ke,Pu=we.TypeError,ri=we.document,Fi=we.process,ai=Cu.f,Ug=ai,Gg=!!(ri&&ri.createEvent&&we.dispatchEvent),Ru="unhandledrejection",zg="rejectionhandled",hs=0,Nu=1,Hg=2,Ui=1,Iu=2,Jt,vs,Yg,fs,Mu=function(a){var e;return Mg(a)&&lr(e=a.then)?e:!1},_u=function(a,e){var t=e.value,r=e.state===Nu,i=r?a.ok:a.fail,n=a.resolve,o=a.reject,s=a.domain,u,l,h;try{i?(r||(e.rejection===Iu&&Wg(e),e.rejection=Ui),i===!0?u=t:(s&&s.enter(),u=i(t),s&&(s.exit(),h=!0)),u===a.promise?o(new Pu("Promise-chain cycle")):(l=Mu(u))?st(l,u,n,o):n(u)):o(t)}catch(f){s&&!h&&s.exit(),o(f)}},Vu=function(a,e){a.notified||(a.notified=!0,Bi(function(){for(var t=a.reactions,r;r=t.get();)_u(r,a);a.notified=!1,e&&!a.rejection&&Xg(a)}))},Du=function(a,e,t){var r,i;Gg?(r=ri.createEvent("Event"),r.promise=e,r.reason=t,r.initEvent(a,!1,!0),we.dispatchEvent(r)):r={promise:e,reason:t},!Bg&&(i=we["on"+a])?i(r):a===Ru&&Dg("Unhandled promise rejection",t)},Xg=function(a){st($u,we,function(){var e=a.facade,t=a.value,r=cs(a),i;if(r&&(i=kg(function(){pr?Fi.emit("unhandledRejection",t,e):Du(Ru,e,t)}),a.rejection=pr||cs(a)?Iu:Ui,i.error))throw i.value})},cs=function(a){return a.rejection!==Ui&&!a.parent},Wg=function(a){st($u,we,function(){var e=a.facade;pr?Fi.emit("rejectionHandled",e):Du(zg,e,a.value)})},et=function(a,e,t){return function(r){a(e,r,t)}},rt=function(a,e,t){a.done||(a.done=!0,t&&(a=t),a.value=e,a.state=Hg,Vu(a,!0))},ii=function(a,e,t){if(!a.done){a.done=!0,t&&(a=t);try{if(a.facade===e)throw new Pu("Promise can't be resolved itself");var r=Mu(e);r?Bi(function(){var i={done:!1};try{st(r,e,et(ii,i,a),et(rt,i,a))}catch(n){rt(i,n,a)}}):(a.value=e,a.state=Nu,Vu(a,!1))}catch(i){rt({done:!1},i,a)}}};if(Au&&(De=function(e){_g(this,Zt),Ig(e),st(Jt,this);var t=Oa(this);try{e(et(ii,t),et(rt,t))}catch(r){rt(t,r)}},Zt=De.prototype,Jt=function(e){Fg(this,{type:Nr,done:!1,notified:!1,parent:!1,reactions:new Lg,rejection:!1,state:hs,value:null})},Jt.prototype=us(Zt,"then",function(e,t){var r=Oa(this),i=ai(Vg(this,De));return r.parent=!0,i.ok=lr(e)?e:!0,i.fail=lr(t)&&t,i.domain=pr?Fi.domain:void 0,r.state===hs?r.reactions.add(i):Bi(function(){_u(i,r)}),i.promise}),vs=function(){var a=new Jt,e=Oa(a);this.promise=a,this.resolve=et(ii,e),this.reject=et(rt,e)},Cu.f=ai=function(a){return a===De||a===Yg?new vs(a):Ug(a)},lr(yr)&&Ke!==Object.prototype)){fs=Ke.then,jg||us(Ke,"then",function(e,t){var r=this;return new De(function(i,n){st(fs,r,i,n)}).then(e,t)},{unsafe:!0});try{delete Ke.constructor}catch{}ls&&ls(Ke,Zt)}Pg({global:!0,constructor:!0,wrap:!0,forced:Au},{Promise:De});Rg(De,Nr,!1);Ng(Nr);var It={},qg=z,Qg=It,Kg=qg("iterator"),Zg=Array.prototype,Jg=function(a){return a!==void 0&&(Qg.Array===a||Zg[Kg]===a)},ed=_i,gs=ut,td=je,rd=It,ad=z,id=ad("iterator"),ku=function(a){if(!td(a))return gs(a,id)||gs(a,"@@iterator")||rd[ed(a)]},nd=Y,sd=Te,od=J,ud=Tr,ld=ku,hd=TypeError,vd=function(a,e){var t=arguments.length<2?ld(a):e;if(sd(t))return od(nd(t,a));throw new hd(ud(a)+" is not iterable")},fd=Y,ds=J,cd=ut,gd=function(a,e,t){var r,i;ds(a);try{if(r=cd(a,"return"),!r){if(e==="throw")throw t;return t}r=fd(r,a)}catch(n){i=!0,r=n}if(e==="throw")throw t;if(i)throw r;return ds(r),t},dd=Di,pd=Y,yd=J,md=Tr,bd=Jg,xd=Ii,ps=xr,Td=vd,Od=ku,ys=gd,Sd=TypeError,hr=function(a,e){this.stopped=a,this.result=e},ms=hr.prototype,Lu=function(a,e,t){var r=t&&t.that,i=!!(t&&t.AS_ENTRIES),n=!!(t&&t.IS_RECORD),o=!!(t&&t.IS_ITERATOR),s=!!(t&&t.INTERRUPTED),u=dd(e,r),l,h,f,c,v,d,g,p=function(x){return l&&ys(l,"normal",x),new hr(!0,x)},y=function(x){return i?(yd(x),s?u(x[0],x[1],p):u(x[0],x[1])):s?u(x,p):u(x)};if(n)l=a.iterator;else if(o)l=a;else{if(h=Od(a),!h)throw new Sd(md(a)+" is not iterable");if(bd(h)){for(f=0,c=xd(a);c>f;f++)if(v=y(a[f]),v&&ps(ms,v))return v;return new hr(!1)}l=Td(a,h)}for(d=n?a.next:l.next;!(g=pd(d,l)).done;){try{v=y(g.value)}catch(x){ys(l,"throw",x)}if(typeof v=="object"&&v&&ps(ms,v))return v}return new hr(!1)},Ed=z,Bu=Ed("iterator"),ju=!1;try{var $d=0,bs={next:function(){return{done:!!$d++}},return:function(){ju=!0}};bs[Bu]=function(){return this},Array.from(bs,function(){throw 2})}catch{}var wd=function(a,e){try{if(!e&&!ju)return!1}catch{return!1}var t=!1;try{var r={};r[Bu]=function(){return{next:function(){return{done:t=!0}}}},a(r)}catch{}return t},Cd=Rr,Ad=wd,Pd=Nt.CONSTRUCTOR,Fu=Pd||!Ad(function(a){Cd.all(a).then(void 0,function(){})}),Rd=ee,Nd=Y,Id=Te,Md=ht,_d=Li,Vd=Lu,Dd=Fu;Rd({target:"Promise",stat:!0,forced:Dd},{all:function(e){var t=this,r=Md.f(t),i=r.resolve,n=r.reject,o=_d(function(){var s=Id(t.resolve),u=[],l=0,h=1;Vd(e,function(f){var c=l++,v=!1;h++,Nd(s,t,f).then(function(d){v||(v=!0,u[c]=d,--h||i(u))},n)}),--h||i(u)});return o.error&&n(o.value),r.promise}});var kd=ee,Ld=Nt.CONSTRUCTOR,ni=Rr,Bd=Fe,jd=B,Fd=Ue,xs=ni&&ni.prototype;kd({target:"Promise",proto:!0,forced:Ld,real:!0},{catch:function(a){return this.then(void 0,a)}});if(jd(ni)){var Ts=Bd("Promise").prototype.catch;xs.catch!==Ts&&Fd(xs,"catch",Ts,{unsafe:!0})}var Ud=ee,Gd=Y,zd=Te,Hd=ht,Yd=Li,Xd=Lu,Wd=Fu;Ud({target:"Promise",stat:!0,forced:Wd},{race:function(e){var t=this,r=Hd.f(t),i=r.reject,n=Yd(function(){var o=zd(t.resolve);Xd(e,function(s){Gd(o,t,s).then(r.resolve,i)})});return n.error&&i(n.value),r.promise}});var qd=ee,Qd=ht,Kd=Nt.CONSTRUCTOR;qd({target:"Promise",stat:!0,forced:Kd},{reject:function(e){var t=Qd.f(this),r=t.reject;return r(e),t.promise}});var Zd=J,Jd=ve,ep=ht,tp=function(a,e){if(Zd(a),Jd(e)&&e.constructor===a)return e;var t=ep.f(a),r=t.resolve;return r(e),t.promise},rp=ee,ap=Fe,ip=Nt.CONSTRUCTOR,np=tp;ap("Promise");rp({target:"Promise",stat:!0,forced:ip},{resolve:function(e){return np(this,e)}});function Os(a,e,t,r,i,n,o){try{var s=a[n](o),u=s.value}catch(l){return void t(l)}s.done?e(u):Promise.resolve(u).then(r,i)}function xe(a){return function(){var e=this,t=arguments;return new Promise(function(r,i){var n=a.apply(e,t);function o(u){Os(n,r,i,o,s,"next",u)}function s(u){Os(n,r,i,o,s,"throw",u)}o(void 0)})}}var sp=_i,op=String,pe=function(a){if(sp(a)==="Symbol")throw new TypeError("Cannot convert a Symbol value to a string");return op(a)},up=J,Uu=function(){var a=up(this),e="";return a.hasIndices&&(e+="d"),a.global&&(e+="g"),a.ignoreCase&&(e+="i"),a.multiline&&(e+="m"),a.dotAll&&(e+="s"),a.unicode&&(e+="u"),a.unicodeSets&&(e+="v"),a.sticky&&(e+="y"),e},Gi=k,lp=V,zi=lp.RegExp,Hi=Gi(function(){var a=zi("a","y");return a.lastIndex=2,a.exec("abcd")!==null}),hp=Hi||Gi(function(){return!zi("a","y").sticky}),vp=Hi||Gi(function(){var a=zi("^r","gy");return a.lastIndex=2,a.exec("str")!==null}),Gu={BROKEN_CARET:vp,MISSED_STICKY:hp,UNSUPPORTED_Y:Hi},zu={},fp=nu,cp=Mi,gp=Object.keys||function(e){return fp(e,cp)},dp=le,pp=Ko,yp=Oe,mp=J,bp=Ct,xp=gp;zu.f=dp&&!pp?Object.defineProperties:function(e,t){mp(e);for(var r=bp(t),i=xp(t),n=i.length,o=0,s;n>o;)yp.f(e,s=i[o++],r[s]);return e};var Tp=J,Op=zu,Ss=Mi,Sp=Ri,Ep=mu,$p=Sr,wp=Pi,Es=">",$s="<",si="prototype",oi="script",Hu=wp("IE_PROTO"),Sa=function(){},Yu=function(a){return $s+oi+Es+a+$s+"/"+oi+Es},ws=function(a){a.write(Yu("")),a.close();var e=a.parentWindow.Object;return a=null,e},Cp=function(){var a=$p("iframe"),e="java"+oi+":",t;return a.style.display="none",Ep.appendChild(a),a.src=String(e),t=a.contentWindow.document,t.open(),t.write(Yu("document.F=Object")),t.close(),t.F},er,vr=function(){try{er=new ActiveXObject("htmlfile")}catch{}vr=typeof document<"u"?document.domain&&er?ws(er):Cp():ws(er);for(var a=Ss.length;a--;)delete vr[si][Ss[a]];return vr()};Sp[Hu]=!0;var Yi=Object.create||function(e,t){var r;return e!==null?(Sa[si]=Tp(e),r=new Sa,Sa[si]=null,r[Hu]=e):r=vr(),t===void 0?r:Op.f(r,t)},Ap=k,Pp=V,Rp=Pp.RegExp,Np=Ap(function(){var a=Rp(".","s");return!(a.dotAll&&a.test(`
|
|
2
2
|
`)&&a.flags==="s")}),Ip=k,Mp=V,_p=Mp.RegExp,Vp=Ip(function(){var a=_p("(?<a>b)","g");return a.exec("b").groups.a!=="b"||"b".replace(a,"$<a>c")!=="bc"}),tt=Y,Ir=L,Dp=pe,kp=Uu,Lp=Gu,Bp=wi,jp=Yi,Fp=$r.get,Up=Np,Gp=Vp,zp=Bp("native-string-replace",String.prototype.replace),mr=RegExp.prototype.exec,ui=mr,Hp=Ir("".charAt),Yp=Ir("".indexOf),Xp=Ir("".replace),Ea=Ir("".slice),li=function(){var a=/a/,e=/b*/g;return tt(mr,a,"a"),tt(mr,e,"a"),a.lastIndex!==0||e.lastIndex!==0}(),Xu=Lp.BROKEN_CARET,hi=/()??/.exec("")[1]!==void 0,Wp=li||hi||Xu||Up||Gp;Wp&&(ui=function(e){var t=this,r=Fp(t),i=Dp(e),n=r.raw,o,s,u,l,h,f,c;if(n)return n.lastIndex=t.lastIndex,o=tt(ui,n,i),t.lastIndex=n.lastIndex,o;var v=r.groups,d=Xu&&t.sticky,g=tt(kp,t),p=t.source,y=0,x=i;if(d&&(g=Xp(g,"y",""),Yp(g,"g")===-1&&(g+="g"),x=Ea(i,t.lastIndex),t.lastIndex>0&&(!t.multiline||t.multiline&&Hp(i,t.lastIndex-1)!==`
|
|
3
3
|
`)&&(p="(?: "+p+")",x=" "+x,y++),s=new RegExp("^(?:"+p+")",g)),hi&&(s=new RegExp("^"+p+"$(?!\\s)",g)),li&&(u=t.lastIndex),l=tt(mr,d?s:t,x),d?l?(l.input=Ea(l.input,y),l[0]=Ea(l[0],y),l.index=t.lastIndex,t.lastIndex+=l[0].length):t.lastIndex=0:li&&l&&(t.lastIndex=t.global?l.index+l[0].length:u),hi&&l&&l.length>1&&tt(zp,l[0],s,function(){for(h=1;h<arguments.length-2;h++)arguments[h]===void 0&&(l[h]=void 0)}),l&&v)for(l.groups=f=jp(null),h=0;h<v.length;h++)c=v[h],f[c[0]]=l[c[1]];return l});var Xi=ui,qp=ee,Cs=Xi;qp({target:"RegExp",proto:!0,forced:/./.exec!==Cs},{exec:Cs});var As=Y,Ps=Ue,Qp=Xi,Rs=k,Wu=z,Kp=Pt,Zp=Wu("species"),$a=RegExp.prototype,Wi=function(a,e,t,r){var i=Wu(a),n=!Rs(function(){var l={};return l[i]=function(){return 7},""[a](l)!==7}),o=n&&!Rs(function(){var l=!1,h=/a/;return a==="split"&&(h={},h.constructor={},h.constructor[Zp]=function(){return h},h.flags="",h[i]=/./[i]),h.exec=function(){return l=!0,null},h[i](""),!l});if(!n||!o||t){var s=/./[i],u=e(i,""[a],function(l,h,f,c,v){var d=h.exec;return d===Qp||d===$a.exec?n&&!v?{done:!0,value:As(s,h,f,c)}:{done:!0,value:As(l,f,h,c)}:{done:!1}});Ps(String.prototype,a,u[0]),Ps($a,i,u[1])}r&&Kp($a[i],"sham",!0)},qi=L,Jp=wr,ey=pe,ty=he,ry=qi("".charAt),Ns=qi("".charCodeAt),ay=qi("".slice),Is=function(a){return function(e,t){var r=ey(ty(e)),i=Jp(t),n=r.length,o,s;return i<0||i>=n?a?"":void 0:(o=Ns(r,i),o<55296||o>56319||i+1===n||(s=Ns(r,i+1))<56320||s>57343?a?ry(r,i):o:a?ay(r,i,i+2):(o-55296<<10)+(s-56320)+65536)}},iy={codeAt:Is(!1),charAt:Is(!0)},ny=iy.charAt,Qi=function(a,e,t){return e+(t?ny(a,e).length:1)},Ms=Y,sy=J,oy=B,uy=Be,ly=Xi,hy=TypeError,Ki=function(a,e){var t=a.exec;if(oy(t)){var r=Ms(t,a,e);return r!==null&&sy(r),r}if(uy(a)==="RegExp")return Ms(ly,a,e);throw new hy("RegExp#exec called on incompatible receiver")},vy=Y,fy=Wi,cy=J,gy=je,dy=lt,wa=pe,py=he,yy=ut,my=Qi,_s=Ki;fy("match",function(a,e,t){return[function(i){var n=py(this),o=gy(i)?void 0:yy(i,a);return o?vy(o,i,n):new RegExp(i)[a](wa(n))},function(r){var i=cy(this),n=wa(r),o=t(e,i,n);if(o.done)return o.value;if(!i.global)return _s(i,n);var s=i.unicode;i.lastIndex=0;for(var u=[],l=0,h;(h=_s(i,n))!==null;){var f=wa(h[0]);u[l]=f,f===""&&(i.lastIndex=my(n,dy(i.lastIndex),s)),l++}return l===0?null:u}]});var Zi=L,by=Or,xy=Math.floor,Ca=Zi("".charAt),Ty=Zi("".replace),Aa=Zi("".slice),Oy=/\$([$&'`]|\d{1,2}|<[^>]*>)/g,Sy=/\$([$&'`]|\d{1,2})/g,Ey=function(a,e,t,r,i,n){var o=t+a.length,s=r.length,u=Sy;return i!==void 0&&(i=by(i),u=Oy),Ty(n,u,function(l,h){var f;switch(Ca(h,0)){case"$":return"$";case"&":return a;case"`":return Aa(e,0,t);case"'":return Aa(e,o);case"<":f=i[Aa(h,1,-1)];break;default:var c=+h;if(c===0)return l;if(c>s){var v=xy(c/10);return v===0?l:v<=s?r[v-1]===void 0?Ca(h,1):r[v-1]+Ca(h,1):l}f=r[c-1]}return f===void 0?"":f})},$y=yu,Vs=Y,Mr=L,wy=Wi,Cy=k,Ay=J,Py=B,Ry=je,Ny=wr,Iy=lt,We=pe,My=he,_y=Qi,Vy=ut,Dy=Ey,ky=Ki,Ly=z,vi=Ly("replace"),By=Math.max,jy=Math.min,Fy=Mr([].concat),Pa=Mr([].push),Ds=Mr("".indexOf),ks=Mr("".slice),Uy=function(a){return a===void 0?a:String(a)},Gy=function(){return"a".replace(/./,"$0")==="$0"}(),Ls=function(){return/./[vi]?/./[vi]("a","$0")==="":!1}(),zy=!Cy(function(){var a=/./;return a.exec=function(){var e=[];return e.groups={a:"7"},e},"".replace(a,"$<a>")!=="7"});wy("replace",function(a,e,t){var r=Ls?"$":"$0";return[function(n,o){var s=My(this),u=Ry(n)?void 0:Vy(n,vi);return u?Vs(u,n,s,o):Vs(e,We(s),n,o)},function(i,n){var o=Ay(this),s=We(i);if(typeof n=="string"&&Ds(n,r)===-1&&Ds(n,"$<")===-1){var u=t(e,o,s,n);if(u.done)return u.value}var l=Py(n);l||(n=We(n));var h=o.global,f;h&&(f=o.unicode,o.lastIndex=0);for(var c=[],v;v=ky(o,s),!(v===null||(Pa(c,v),!h));){var d=We(v[0]);d===""&&(o.lastIndex=_y(s,Iy(o.lastIndex),f))}for(var g="",p=0,y=0;y<c.length;y++){v=c[y];for(var x=We(v[0]),b=By(jy(Ny(v.index),s.length),0),T=[],$,E=1;E<v.length;E++)Pa(T,Uy(v[E]));var O=v.groups;if(l){var C=Fy([x],T,b,s);O!==void 0&&Pa(C,O),$=We($y(n,void 0,C))}else $=Dy(x,s,b,T,O,n);b>=p&&(g+=ks(s,p,b)+$,p=b+x.length)}return g+ks(s,p)}]},!zy||!Gy||Ls);var Hy=ve,Yy=Be,Xy=z,Wy=Xy("match"),qy=function(a){var e;return Hy(a)&&((e=a[Wy])!==void 0?!!e:Yy(a)==="RegExp")},Qy=qy,Ky=TypeError,Ji=function(a){if(Qy(a))throw new Ky("The method doesn't accept regular expressions");return a},Zy=z,Jy=Zy("match"),en=function(a){var e=/./;try{"/./"[a](e)}catch{try{return e[Jy]=!1,"/./"[a](e)}catch{}}return!1},em=ee,tm=Pr,rm=wt.f,am=lt,Bs=pe,im=Ji,nm=he,sm=en,om=tm("".slice),um=Math.min,qu=sm("startsWith"),lm=!qu&&!!function(){var a=rm(String.prototype,"startsWith");return a&&!a.writable}();em({target:"String",proto:!0,forced:!lm&&!qu},{startsWith:function(e){var t=Bs(nm(this));im(e);var r=am(um(arguments.length>1?arguments[1]:void 0,t.length)),i=Bs(e);return om(t,r,r+i.length)===i}});var hm=z,vm=Yi,fm=Oe.f,fi=hm("unscopables"),ci=Array.prototype;ci[fi]===void 0&&fm(ci,fi,{configurable:!0,value:vm(null)});var cm=function(a){ci[fi][a]=!0},gm=k,dm=!gm(function(){function a(){}return a.prototype.constructor=null,Object.getPrototypeOf(new a)!==a.prototype}),pm=fe,ym=B,mm=Or,bm=Pi,xm=dm,js=bm("IE_PROTO"),gi=Object,Tm=gi.prototype,Qu=xm?gi.getPrototypeOf:function(a){var e=mm(a);if(pm(e,js))return e[js];var t=e.constructor;return ym(t)&&e instanceof t?t.prototype:e instanceof gi?Tm:null},Om=k,Sm=B,Em=ve,Fs=Qu,$m=Ue,wm=z,di=wm("iterator"),Ku=!1,ke,Ra,Na;[].keys&&(Na=[].keys(),"next"in Na?(Ra=Fs(Fs(Na)),Ra!==Object.prototype&&(ke=Ra)):Ku=!0);var Cm=!Em(ke)||Om(function(){var a={};return ke[di].call(a)!==a});Cm&&(ke={});Sm(ke[di])||$m(ke,di,function(){return this});var Zu={IteratorPrototype:ke,BUGGY_SAFARI_ITERATORS:Ku},Am=Zu.IteratorPrototype,Pm=Yi,Rm=Oi,Nm=Ar,Im=It,Mm=function(){return this},_m=function(a,e,t,r){var i=e+" Iterator";return a.prototype=Pm(Am,{next:Rm(+!r,t)}),Nm(a,i,!1),Im[i]=Mm,a},Vm=ee,Dm=Y,Ju=Er,km=B,Lm=_m,Us=Qu,Gs=lu,Bm=Ar,jm=Pt,Ia=Ue,Fm=z,Um=It,el=Zu,Gm=Ju.PROPER,zm=Ju.CONFIGURABLE,zs=el.IteratorPrototype,tr=el.BUGGY_SAFARI_ITERATORS,dt=Fm("iterator"),Hs="keys",pt="values",Ys="entries",Hm=function(){return this},Ym=function(a,e,t,r,i,n,o){Lm(t,e,r);var s=function(y){if(y===i&&c)return c;if(!tr&&y&&y in h)return h[y];switch(y){case Hs:return function(){return new t(this,y)};case pt:return function(){return new t(this,y)};case Ys:return function(){return new t(this,y)}}return function(){return new t(this)}},u=e+" Iterator",l=!1,h=a.prototype,f=h[dt]||h["@@iterator"]||i&&h[i],c=!tr&&f||s(i),v=e==="Array"&&h.entries||f,d,g,p;if(v&&(d=Us(v.call(new a)),d!==Object.prototype&&d.next&&(Us(d)!==zs&&(Gs?Gs(d,zs):km(d[dt])||Ia(d,dt,Hm)),Bm(d,u,!0))),Gm&&i===pt&&f&&f.name!==pt&&(zm?jm(h,"name",pt):(l=!0,c=function(){return Dm(f,this)})),i)if(g={values:s(pt),keys:n?c:s(Hs),entries:s(Ys)},o)for(p in g)(tr||l||!(p in h))&&Ia(h,p,g[p]);else Vm({target:e,proto:!0,forced:tr||l},g);return h[dt]!==c&&Ia(h,dt,c,{name:i}),Um[e]=c,g},Xm=function(a,e){return{value:a,done:e}},Wm=Ct,tn=cm,Xs=It,tl=$r,qm=Oe.f,Qm=Ym,rr=Xm,Km=le,rl="Array Iterator",Zm=tl.set,Jm=tl.getterFor(rl),e0=Qm(Array,"Array",function(a,e){Zm(this,{type:rl,target:Wm(a),index:0,kind:e})},function(){var a=Jm(this),e=a.target,t=a.index++;if(!e||t>=e.length)return a.target=null,rr(void 0,!0);switch(a.kind){case"keys":return rr(t,!1);case"values":return rr(e[t],!1)}return rr([t,e[t]],!1)},"values"),Ws=Xs.Arguments=Xs.Array;tn("keys");tn("values");tn("entries");if(Km&&Ws.name!=="values")try{qm(Ws,"name",{value:"values"})}catch{}var t0={CSSRuleList:0,CSSStyleDeclaration:0,CSSValueList:0,ClientRectList:0,DOMRectList:0,DOMStringList:0,DOMTokenList:1,DataTransferItemList:0,FileList:0,HTMLAllCollection:0,HTMLCollection:0,HTMLFormElement:0,HTMLSelectElement:0,MediaList:0,MimeTypeArray:0,NamedNodeMap:0,NodeList:1,PaintRequestList:0,Plugin:0,PluginArray:0,SVGLengthList:0,SVGNumberList:0,SVGPathSegList:0,SVGPointList:0,SVGStringList:0,SVGTransformList:0,SourceBufferList:0,StyleSheetList:0,TextTrackCueList:0,TextTrackList:0,TouchList:0},r0=Sr,Ma=r0("span").classList,qs=Ma&&Ma.constructor&&Ma.constructor.prototype,a0=qs===Object.prototype?void 0:qs,Qs=V,al=t0,i0=a0,mt=e0,Ks=Pt,n0=Ar,s0=z,_a=s0("iterator"),Va=mt.values,il=function(a,e){if(a){if(a[_a]!==Va)try{Ks(a,_a,Va)}catch{a[_a]=Va}if(n0(a,e,!0),al[e]){for(var t in mt)if(a[t]!==mt[t])try{Ks(a,t,mt[t])}catch{a[t]=mt[t]}}}};for(var Da in al)il(Qs[Da]&&Qs[Da].prototype,Da);il(i0,"DOMTokenList");function o0(a,e){if(Ha(a)!="object"||!a)return a;var t=a[Symbol.toPrimitive];if(t!==void 0){var r=t.call(a,e||"default");if(Ha(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(a)}function u0(a){var e=o0(a,"string");return Ha(e)=="symbol"?e:e+""}function rn(a,e,t){return(e=u0(e))in a?Object.defineProperty(a,e,{value:t,enumerable:!0,configurable:!0,writable:!0}):a[e]=t,a}var l0=Te,h0=Or,v0=Uo,f0=Ii,Zs=TypeError,Js="Reduce of empty array with no initial value",eo=function(a){return function(e,t,r,i){var n=h0(e),o=v0(n),s=f0(n);if(l0(t),s===0&&r<2)throw new Zs(Js);var u=a?s-1:0,l=a?-1:1;if(r<2)for(;;){if(u in o){i=o[u],u+=l;break}if(u+=l,a?u<0:s<=u)throw new Zs(Js)}for(;a?u>=0:s>u;u+=l)u in o&&(i=t(i,o[u],u,n));return i}},c0={left:eo(!1),right:eo(!0)},g0=k,nl=function(a,e){var t=[][a];return!!t&&g0(function(){t.call(null,e||function(){return 1},1)})},d0=ee,p0=c0.left,y0=nl,to=Si,m0=Cr,b0=!m0&&to>79&&to<83,x0=b0||!y0("reduce");d0({target:"Array",proto:!0,forced:x0},{reduce:function(e){var t=arguments.length;return p0(this,e,t,t>1?arguments[1]:void 0)}});var T0=ee,O0=Pr,S0=wt.f,E0=lt,ro=pe,$0=Ji,w0=he,C0=en,A0=O0("".slice),P0=Math.min,sl=C0("endsWith"),R0=!sl&&!!function(){var a=S0(String.prototype,"endsWith");return a&&!a.writable}();T0({target:"String",proto:!0,forced:!R0&&!sl},{endsWith:function(e){var t=ro(w0(this));$0(e);var r=arguments.length>1?arguments[1]:void 0,i=t.length,n=r===void 0?i:P0(E0(r),i),o=ro(e);return A0(t,n-o.length,n)===o}});var ka=Y,ol=L,N0=Wi,I0=J,M0=je,_0=he,V0=du,D0=Qi,k0=lt,ao=pe,L0=ut,io=Ki,B0=Gu,j0=k,qe=B0.UNSUPPORTED_Y,F0=4294967295,U0=Math.min,La=ol([].push),Ba=ol("".slice),G0=!j0(function(){var a=/(?:)/,e=a.exec;a.exec=function(){return e.apply(this,arguments)};var t="ab".split(a);return t.length!==2||t[0]!=="a"||t[1]!=="b"}),no="abbc".split(/(b)*/)[1]==="c"||"test".split(/(?:)/,-1).length!==4||"ab".split(/(?:ab)*/).length!==2||".".split(/(.?)(.?)/).length!==4||".".split(/()()/).length>1||"".split(/.?/).length;N0("split",function(a,e,t){var r="0".split(void 0,0).length?function(i,n){return i===void 0&&n===0?[]:ka(e,this,i,n)}:e;return[function(n,o){var s=_0(this),u=M0(n)?void 0:L0(n,a);return u?ka(u,n,s,o):ka(r,ao(s),n,o)},function(i,n){var o=I0(this),s=ao(i);if(!no){var u=t(r,o,s,n,r!==e);if(u.done)return u.value}var l=V0(o,RegExp),h=o.unicode,f=(o.ignoreCase?"i":"")+(o.multiline?"m":"")+(o.unicode?"u":"")+(qe?"g":"y"),c=new l(qe?"^(?:"+o.source+")":o,f),v=n===void 0?F0:n>>>0;if(v===0)return[];if(s.length===0)return io(c,s)===null?[s]:[];for(var d=0,g=0,p=[];g<s.length;){c.lastIndex=qe?0:g;var y=io(c,qe?Ba(s,g):s),x;if(y===null||(x=U0(k0(c.lastIndex+(qe?g:0)),s.length))===d)g=D0(s,g,h);else{if(La(p,Ba(s,d,g)),p.length===v)return p;for(var b=1;b<=y.length-1;b++)if(La(p,y[b]),p.length===v)return p;g=d=x}}return La(p,Ba(s,d)),p}]},no||!G0,qe);var _r={exports:{}},bt={exports:{}};(function(){var a,e,t,r,i,n;typeof performance<"u"&&performance!==null&&performance.now?bt.exports=function(){return performance.now()}:typeof Qe<"u"&&Qe!==null&&Qe.hrtime?(bt.exports=function(){return(a()-i)/1e6},e=Qe.hrtime,a=function(){var o;return o=e(),o[0]*1e9+o[1]},r=a(),n=Qe.uptime()*1e9,i=r-n):Date.now?(bt.exports=function(){return Date.now()-t},t=Date.now()):(bt.exports=function(){return new Date().getTime()-t},t=new Date().getTime())}).call(Ze);var z0=bt.exports,H0=z0,be=typeof window>"u"?Ze:window,ar=["moz","webkit"],at="AnimationFrame",ot=be["request"+at],$t=be["cancel"+at]||be["cancelRequest"+at];for(var yt=0;!ot&&yt<ar.length;yt++)ot=be[ar[yt]+"Request"+at],$t=be[ar[yt]+"Cancel"+at]||be[ar[yt]+"CancelRequest"+at];if(!ot||!$t){var ja=0,so=0,Me=[],Y0=1e3/60;ot=function(a){if(Me.length===0){var e=H0(),t=Math.max(0,Y0-(e-ja));ja=t+e,setTimeout(function(){var r=Me.slice(0);Me.length=0;for(var i=0;i<r.length;i++)if(!r[i].cancelled)try{r[i].callback(ja)}catch(n){setTimeout(function(){throw n},0)}},Math.round(t))}return Me.push({handle:++so,callback:a,cancelled:!1}),so},$t=function(a){for(var e=0;e<Me.length;e++)Me[e].handle===a&&(Me[e].cancelled=!0)}}_r.exports=function(a){return ot.call(be,a)};_r.exports.cancel=function(){$t.apply(be,arguments)};_r.exports.polyfill=function(a){a||(a=be),a.requestAnimationFrame=ot,a.cancelAnimationFrame=$t};var X0=_r.exports;const Fa=Vo(X0);var ul=`
|
|
4
4
|
\v\f\r \u2028\u2029\uFEFF`,W0=L,q0=he,Q0=pe,pi=ul,oo=W0("".replace),K0=RegExp("^["+pi+"]+"),Z0=RegExp("(^|[^"+pi+"])["+pi+"]+$"),Ua=function(a){return function(e){var t=Q0(q0(e));return a&1&&(t=oo(t,K0,"")),a&2&&(t=oo(t,Z0,"$1")),t}},J0={start:Ua(1),end:Ua(2),trim:Ua(3)},eb=Er.PROPER,tb=k,uo=ul,lo="
",rb=function(a){return tb(function(){return!!uo[a]()||lo[a]()!==lo||eb&&uo[a].name!==a})},ab=ee,ib=J0.trim,nb=rb;ab({target:"String",proto:!0,forced:nb("trim")},{trim:function(){return ib(this)}});var sb=function(a){this.ok=!1,this.alpha=1,a.charAt(0)=="#"&&(a=a.substr(1,6)),a=a.replace(/ /g,""),a=a.toLowerCase();var e={aliceblue:"f0f8ff",antiquewhite:"faebd7",aqua:"00ffff",aquamarine:"7fffd4",azure:"f0ffff",beige:"f5f5dc",bisque:"ffe4c4",black:"000000",blanchedalmond:"ffebcd",blue:"0000ff",blueviolet:"8a2be2",brown:"a52a2a",burlywood:"deb887",cadetblue:"5f9ea0",chartreuse:"7fff00",chocolate:"d2691e",coral:"ff7f50",cornflowerblue:"6495ed",cornsilk:"fff8dc",crimson:"dc143c",cyan:"00ffff",darkblue:"00008b",darkcyan:"008b8b",darkgoldenrod:"b8860b",darkgray:"a9a9a9",darkgreen:"006400",darkkhaki:"bdb76b",darkmagenta:"8b008b",darkolivegreen:"556b2f",darkorange:"ff8c00",darkorchid:"9932cc",darkred:"8b0000",darksalmon:"e9967a",darkseagreen:"8fbc8f",darkslateblue:"483d8b",darkslategray:"2f4f4f",darkturquoise:"00ced1",darkviolet:"9400d3",deeppink:"ff1493",deepskyblue:"00bfff",dimgray:"696969",dodgerblue:"1e90ff",feldspar:"d19275",firebrick:"b22222",floralwhite:"fffaf0",forestgreen:"228b22",fuchsia:"ff00ff",gainsboro:"dcdcdc",ghostwhite:"f8f8ff",gold:"ffd700",goldenrod:"daa520",gray:"808080",green:"008000",greenyellow:"adff2f",honeydew:"f0fff0",hotpink:"ff69b4",indianred:"cd5c5c",indigo:"4b0082",ivory:"fffff0",khaki:"f0e68c",lavender:"e6e6fa",lavenderblush:"fff0f5",lawngreen:"7cfc00",lemonchiffon:"fffacd",lightblue:"add8e6",lightcoral:"f08080",lightcyan:"e0ffff",lightgoldenrodyellow:"fafad2",lightgrey:"d3d3d3",lightgreen:"90ee90",lightpink:"ffb6c1",lightsalmon:"ffa07a",lightseagreen:"20b2aa",lightskyblue:"87cefa",lightslateblue:"8470ff",lightslategray:"778899",lightsteelblue:"b0c4de",lightyellow:"ffffe0",lime:"00ff00",limegreen:"32cd32",linen:"faf0e6",magenta:"ff00ff",maroon:"800000",mediumaquamarine:"66cdaa",mediumblue:"0000cd",mediumorchid:"ba55d3",mediumpurple:"9370d8",mediumseagreen:"3cb371",mediumslateblue:"7b68ee",mediumspringgreen:"00fa9a",mediumturquoise:"48d1cc",mediumvioletred:"c71585",midnightblue:"191970",mintcream:"f5fffa",mistyrose:"ffe4e1",moccasin:"ffe4b5",navajowhite:"ffdead",navy:"000080",oldlace:"fdf5e6",olive:"808000",olivedrab:"6b8e23",orange:"ffa500",orangered:"ff4500",orchid:"da70d6",palegoldenrod:"eee8aa",palegreen:"98fb98",paleturquoise:"afeeee",palevioletred:"d87093",papayawhip:"ffefd5",peachpuff:"ffdab9",peru:"cd853f",pink:"ffc0cb",plum:"dda0dd",powderblue:"b0e0e6",purple:"800080",rebeccapurple:"663399",red:"ff0000",rosybrown:"bc8f8f",royalblue:"4169e1",saddlebrown:"8b4513",salmon:"fa8072",sandybrown:"f4a460",seagreen:"2e8b57",seashell:"fff5ee",sienna:"a0522d",silver:"c0c0c0",skyblue:"87ceeb",slateblue:"6a5acd",slategray:"708090",snow:"fffafa",springgreen:"00ff7f",steelblue:"4682b4",tan:"d2b48c",teal:"008080",thistle:"d8bfd8",tomato:"ff6347",turquoise:"40e0d0",violet:"ee82ee",violetred:"d02090",wheat:"f5deb3",white:"ffffff",whitesmoke:"f5f5f5",yellow:"ffff00",yellowgreen:"9acd32"};a=e[a]||a;for(var t=[{re:/^rgba\((\d{1,3}),\s*(\d{1,3}),\s*(\d{1,3}),\s*((?:\d?\.)?\d)\)$/,example:["rgba(123, 234, 45, 0.8)","rgba(255,234,245,1.0)"],process:function(u){return[parseInt(u[1]),parseInt(u[2]),parseInt(u[3]),parseFloat(u[4])]}},{re:/^rgb\((\d{1,3}),\s*(\d{1,3}),\s*(\d{1,3})\)$/,example:["rgb(123, 234, 45)","rgb(255,234,245)"],process:function(u){return[parseInt(u[1]),parseInt(u[2]),parseInt(u[3])]}},{re:/^([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})$/,example:["#00ff00","336699"],process:function(u){return[parseInt(u[1],16),parseInt(u[2],16),parseInt(u[3],16)]}},{re:/^([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,example:["#fb0","f0f"],process:function(u){return[parseInt(u[1]+u[1],16),parseInt(u[2]+u[2],16),parseInt(u[3]+u[3],16)]}}],r=0;r<t.length;r++){var i=t[r].re,n=t[r].process,o=i.exec(a);if(o){var s=n(o);this.r=s[0],this.g=s[1],this.b=s[2],s.length>3&&(this.alpha=s[3]),this.ok=!0}}this.r=this.r<0||isNaN(this.r)?0:this.r>255?255:this.r,this.g=this.g<0||isNaN(this.g)?0:this.g>255?255:this.g,this.b=this.b<0||isNaN(this.b)?0:this.b>255?255:this.b,this.alpha=this.alpha<0?0:this.alpha>1||isNaN(this.alpha)?1:this.alpha,this.toRGB=function(){return"rgb("+this.r+", "+this.g+", "+this.b+")"},this.toRGBA=function(){return"rgba("+this.r+", "+this.g+", "+this.b+", "+this.alpha+")"},this.toHex=function(){var u=this.r.toString(16),l=this.g.toString(16),h=this.b.toString(16);return u.length==1&&(u="0"+u),l.length==1&&(l="0"+l),h.length==1&&(h="0"+h),"#"+u+l+h},this.getHelpXML=function(){for(var u=new Array,l=0;l<t.length;l++)for(var h=t[l].example,f=0;f<h.length;f++)u[u.length]=h[f];for(var c in e)u[u.length]=c;var v=document.createElement("ul");v.setAttribute("id","rgbcolor-examples");for(var l=0;l<u.length;l++)try{var d=document.createElement("li"),g=new RGBColor(u[l]),p=document.createElement("div");p.style.cssText="margin: 3px; border: 1px solid black; background:"+g.toHex()+"; color:"+g.toHex(),p.appendChild(document.createTextNode("test"));var y=document.createTextNode(" "+u[l]+" -> "+g.toRGB()+" -> "+g.toHex());d.appendChild(p),d.appendChild(y),v.appendChild(d)}catch{}return v}};const yi=Vo(sb);var ob=ee,ub=Pr,lb=iu.indexOf,hb=nl,mi=ub([].indexOf),ll=!!mi&&1/mi([1],1,-0)<0,vb=ll||!hb("indexOf");ob({target:"Array",proto:!0,forced:vb},{indexOf:function(e){var t=arguments.length>1?arguments[1]:void 0;return ll?mi(this,e,t)||0:lb(this,e,t)}});var fb=ee,cb=L,gb=Ji,db=he,ho=pe,pb=en,yb=cb("".indexOf);fb({target:"String",proto:!0,forced:!pb("includes")},{includes:function(e){return!!~yb(ho(db(this)),ho(gb(e)),arguments.length>1?arguments[1]:void 0)}});var mb=Be,bb=Array.isArray||function(e){return mb(e)==="Array"},xb=ee,Tb=L,Ob=bb,Sb=Tb([].reverse),vo=[1,2];xb({target:"Array",proto:!0,forced:String(vo)===String(vo.reverse())},{reverse:function(){return Ob(this)&&(this.length=this.length),Sb(this)}});/*! *****************************************************************************
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
/*! @license DOMPurify 2.5.
|
|
2
|
-
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}var jt=Object.hasOwnProperty,ut=Object.setPrototypeOf,Yt=Object.isFrozen,Xt=Object.getPrototypeOf,Vt=Object.getOwnPropertyDescriptor,E=Object.freeze,b=Object.seal,qt=Object.create,vt=typeof Reflect<"u"&&Reflect,ue=vt.apply,Ue=vt.construct;ue||(ue=function(n,o,s){return n.apply(o,s)});E||(E=function(n){return n});b||(b=function(n){return n});Ue||(Ue=function(n,o){return le(n,M(o))});var Kt=O(Array.prototype.forEach),ft=O(Array.prototype.pop),q=O(Array.prototype.push),se=O(String.prototype.toLowerCase),De=O(String.prototype.toString),ct=O(String.prototype.match),L=O(String.prototype.replace),Zt=O(String.prototype.indexOf),Jt=O(String.prototype.trim),_=O(RegExp.prototype.test),we=Qt(TypeError);function O(a){return function(n){for(var o=arguments.length,s=new Array(o>1?o-1:0),c=1;c<o;c++)s[c-1]=arguments[c];return ue(a,n,s)}}function Qt(a){return function(){for(var n=arguments.length,o=new Array(n),s=0;s<n;s++)o[s]=arguments[s];return Ue(a,o)}}function l(a,n,o){var s;o=(s=o)!==null&&s!==void 0?s:se,ut&&ut(a,null);for(var c=n.length;c--;){var g=n[c];if(typeof g=="string"){var y=o(g);y!==g&&(Yt(n)||(n[c]=y),g=y)}a[g]=!0}return a}function U(a){var n=qt(null),o;for(o in a)ue(jt,a,[o])===!0&&(n[o]=a[o]);return n}function ie(a,n){for(;a!==null;){var o=Vt(a,n);if(o){if(o.get)return O(o.get);if(typeof o.value=="function")return O(o.value)}a=Xt(a)}function s(c){return console.warn("fallback value for",c),null}return s}var mt=E(["a","abbr","acronym","address","area","article","aside","audio","b","bdi","bdo","big","blink","blockquote","body","br","button","canvas","caption","center","cite","code","col","colgroup","content","data","datalist","dd","decorator","del","details","dfn","dialog","dir","div","dl","dt","element","em","fieldset","figcaption","figure","font","footer","form","h1","h2","h3","h4","h5","h6","head","header","hgroup","hr","html","i","img","input","ins","kbd","label","legend","li","main","map","mark","marquee","menu","menuitem","meter","nav","nobr","ol","optgroup","option","output","p","picture","pre","progress","q","rp","rt","ruby","s","samp","section","select","shadow","small","source","spacer","span","strike","strong","style","sub","summary","sup","table","tbody","td","template","textarea","tfoot","th","thead","time","tr","track","tt","u","ul","var","video","wbr"]),Ce=E(["svg","a","altglyph","altglyphdef","altglyphitem","animatecolor","animatemotion","animatetransform","circle","clippath","defs","desc","ellipse","filter","font","g","glyph","glyphref","hkern","image","line","lineargradient","marker","mask","metadata","mpath","path","pattern","polygon","polyline","radialgradient","rect","stop","style","switch","symbol","text","textpath","title","tref","tspan","view","vkern"]),Ie=E(["feBlend","feColorMatrix","feComponentTransfer","feComposite","feConvolveMatrix","feDiffuseLighting","feDisplacementMap","feDistantLight","feFlood","feFuncA","feFuncB","feFuncG","feFuncR","feGaussianBlur","feImage","feMerge","feMergeNode","feMorphology","feOffset","fePointLight","feSpecularLighting","feSpotLight","feTile","feTurbulence"]),er=E(["animate","color-profile","cursor","discard","fedropshadow","font-face","font-face-format","font-face-name","font-face-src","font-face-uri","foreignobject","hatch","hatchpath","mesh","meshgradient","meshpatch","meshrow","missing-glyph","script","set","solidcolor","unknown","use"]),xe=E(["math","menclose","merror","mfenced","mfrac","mglyph","mi","mlabeledtr","mmultiscripts","mn","mo","mover","mpadded","mphantom","mroot","mrow","ms","mspace","msqrt","mstyle","msub","msup","msubsup","mtable","mtd","mtext","mtr","munder","munderover"]),tr=E(["maction","maligngroup","malignmark","mlongdiv","mscarries","mscarry","msgroup","mstack","msline","msrow","semantics","annotation","annotation-xml","mprescripts","none"]),pt=E(["#text"]),dt=E(["accept","action","align","alt","autocapitalize","autocomplete","autopictureinpicture","autoplay","background","bgcolor","border","capture","cellpadding","cellspacing","checked","cite","class","clear","color","cols","colspan","controls","controlslist","coords","crossorigin","datetime","decoding","default","dir","disabled","disablepictureinpicture","disableremoteplayback","download","draggable","enctype","enterkeyhint","face","for","headers","height","hidden","high","href","hreflang","id","inputmode","integrity","ismap","kind","label","lang","list","loading","loop","low","max","maxlength","media","method","min","minlength","multiple","muted","name","nonce","noshade","novalidate","nowrap","open","optimum","pattern","placeholder","playsinline","poster","preload","pubdate","radiogroup","readonly","rel","required","rev","reversed","role","rows","rowspan","spellcheck","scope","selected","shape","size","sizes","span","srclang","start","src","srcset","step","style","summary","tabindex","title","translate","type","usemap","valign","value","width","xmlns","slot"]),ke=E(["accent-height","accumulate","additive","alignment-baseline","ascent","attributename","attributetype","azimuth","basefrequency","baseline-shift","begin","bias","by","class","clip","clippathunits","clip-path","clip-rule","color","color-interpolation","color-interpolation-filters","color-profile","color-rendering","cx","cy","d","dx","dy","diffuseconstant","direction","display","divisor","dur","edgemode","elevation","end","fill","fill-opacity","fill-rule","filter","filterunits","flood-color","flood-opacity","font-family","font-size","font-size-adjust","font-stretch","font-style","font-variant","font-weight","fx","fy","g1","g2","glyph-name","glyphref","gradientunits","gradienttransform","height","href","id","image-rendering","in","in2","k","k1","k2","k3","k4","kerning","keypoints","keysplines","keytimes","lang","lengthadjust","letter-spacing","kernelmatrix","kernelunitlength","lighting-color","local","marker-end","marker-mid","marker-start","markerheight","markerunits","markerwidth","maskcontentunits","maskunits","max","mask","media","method","mode","min","name","numoctaves","offset","operator","opacity","order","orient","orientation","origin","overflow","paint-order","path","pathlength","patterncontentunits","patterntransform","patternunits","points","preservealpha","preserveaspectratio","primitiveunits","r","rx","ry","radius","refx","refy","repeatcount","repeatdur","restart","result","rotate","scale","seed","shape-rendering","specularconstant","specularexponent","spreadmethod","startoffset","stddeviation","stitchtiles","stop-color","stop-opacity","stroke-dasharray","stroke-dashoffset","stroke-linecap","stroke-linejoin","stroke-miterlimit","stroke-opacity","stroke","stroke-width","style","surfacescale","systemlanguage","tabindex","targetx","targety","transform","transform-origin","text-anchor","text-decoration","text-rendering","textlength","type","u1","u2","unicode","values","viewbox","visibility","version","vert-adv-y","vert-origin-x","vert-origin-y","width","word-spacing","wrap","writing-mode","xchannelselector","ychannelselector","x","x1","x2","xmlns","y","y1","y2","z","zoomandpan"]),Tt=E(["accent","accentunder","align","bevelled","close","columnsalign","columnlines","columnspan","denomalign","depth","dir","display","displaystyle","encoding","fence","frame","height","href","id","largeop","length","linethickness","lspace","lquote","mathbackground","mathcolor","mathsize","mathvariant","maxsize","minsize","movablelimits","notation","numalign","open","rowalign","rowlines","rowspacing","rowspan","rspace","rquote","scriptlevel","scriptminsize","scriptsizemultiplier","selection","separator","separators","stretchy","subscriptshift","supscriptshift","symmetric","voffset","width","xmlns"]),oe=E(["xlink:href","xml:id","xlink:title","xml:space","xmlns:xlink"]),rr=b(/\{\{[\w\W]*|[\w\W]*\}\}/gm),ar=b(/<%[\w\W]*|[\w\W]*%>/gm),nr=b(/\${[\w\W]*}/gm),ir=b(/^data-[\-\w.\u00B7-\uFFFF]/),or=b(/^aria-[\-\w]+$/),lr=b(/^(?:(?:(?:f|ht)tps?|mailto|tel|callto|cid|xmpp):|[^a-z]|[a-z+.\-]+(?:[^a-z+.\-:]|$))/i),sr=b(/^(?:\w+script|data):/i),ur=b(/[\u0000-\u0020\u00A0\u1680\u180E\u2000-\u2029\u205F\u3000]/g),fr=b(/^html$/i),cr=b(/^[a-z][.\w]*(-[.\w]+)+$/i),mr=function(){return typeof window>"u"?null:window},pr=function(n,o){if(I(n)!=="object"||typeof n.createPolicy!="function")return null;var s=null,c="data-tt-policy-suffix";o.currentScript&&o.currentScript.hasAttribute(c)&&(s=o.currentScript.getAttribute(c));var g="dompurify"+(s?"#"+s:"");try{return n.createPolicy(g,{createHTML:function(N){return N},createScriptURL:function(N){return N}})}catch{return console.warn("TrustedTypes policy "+g+" could not be created."),null}};function _t(){var a=arguments.length>0&&arguments[0]!==void 0?arguments[0]:mr(),n=function(e){return _t(e)};if(n.version="2.5.6",n.removed=[],!a||!a.document||a.document.nodeType!==9)return n.isSupported=!1,n;var o=a.document,s=a.document,c=a.DocumentFragment,g=a.HTMLTemplateElement,y=a.Node,N=a.Element,x=a.NodeFilter,j=a.NamedNodeMap,ht=j===void 0?a.NamedNodeMap||a.MozNamedAttrMap:j,Et=a.HTMLFormElement,At=a.DOMParser,K=a.trustedTypes,Z=N.prototype,yt=ie(Z,"cloneNode"),gt=ie(Z,"nextSibling"),St=ie(Z,"childNodes"),fe=ie(Z,"parentNode");if(typeof g=="function"){var ce=s.createElement("template");ce.content&&ce.content.ownerDocument&&(s=ce.content.ownerDocument)}var R=pr(K,o),me=R?R.createHTML(""):"",J=s,pe=J.implementation,bt=J.createNodeIterator,Ot=J.createDocumentFragment,Rt=J.getElementsByTagName,Lt=o.importNode,He={};try{He=U(s).documentMode?s.documentMode:{}}catch{}var D={};n.isSupported=typeof fe=="function"&&pe&&pe.createHTMLDocument!==void 0&&He!==9;var de=rr,Te=ar,ve=nr,Mt=ir,Nt=or,Dt=sr,ze=ur,wt=cr,_e=lr,p=null,Ge=l({},[].concat(M(mt),M(Ce),M(Ie),M(xe),M(pt))),d=null,We=l({},[].concat(M(dt),M(ke),M(Tt),M(oe))),f=Object.seal(Object.create(null,{tagNameCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},attributeNameCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},allowCustomizedBuiltInElements:{writable:!0,configurable:!1,enumerable:!0,value:!1}})),Y=null,he=null,Be=!0,Ee=!0,$e=!1,je=!0,H=!1,Ae=!0,k=!1,ye=!1,ge=!1,z=!1,Q=!1,ee=!1,Ye=!0,Xe=!1,Ct="user-content-",Se=!0,X=!1,G={},W=null,Ve=l({},["annotation-xml","audio","colgroup","desc","foreignobject","head","iframe","math","mi","mn","mo","ms","mtext","noembed","noframes","noscript","plaintext","script","style","svg","template","thead","title","video","xmp"]),qe=null,Ke=l({},["audio","video","img","source","image","track"]),be=null,Ze=l({},["alt","class","for","id","label","name","pattern","placeholder","role","summary","title","value","style","xmlns"]),te="http://www.w3.org/1998/Math/MathML",re="http://www.w3.org/2000/svg",w="http://www.w3.org/1999/xhtml",B=w,Oe=!1,Re=null,It=l({},[te,re,w],De),P,xt=["application/xhtml+xml","text/html"],kt="text/html",T,$=null,Pt=s.createElement("form"),Je=function(e){return e instanceof RegExp||e instanceof Function},Le=function(e){$&&$===e||((!e||I(e)!=="object")&&(e={}),e=U(e),P=xt.indexOf(e.PARSER_MEDIA_TYPE)===-1?P=kt:P=e.PARSER_MEDIA_TYPE,T=P==="application/xhtml+xml"?De:se,p="ALLOWED_TAGS"in e?l({},e.ALLOWED_TAGS,T):Ge,d="ALLOWED_ATTR"in e?l({},e.ALLOWED_ATTR,T):We,Re="ALLOWED_NAMESPACES"in e?l({},e.ALLOWED_NAMESPACES,De):It,be="ADD_URI_SAFE_ATTR"in e?l(U(Ze),e.ADD_URI_SAFE_ATTR,T):Ze,qe="ADD_DATA_URI_TAGS"in e?l(U(Ke),e.ADD_DATA_URI_TAGS,T):Ke,W="FORBID_CONTENTS"in e?l({},e.FORBID_CONTENTS,T):Ve,Y="FORBID_TAGS"in e?l({},e.FORBID_TAGS,T):{},he="FORBID_ATTR"in e?l({},e.FORBID_ATTR,T):{},G="USE_PROFILES"in e?e.USE_PROFILES:!1,Be=e.ALLOW_ARIA_ATTR!==!1,Ee=e.ALLOW_DATA_ATTR!==!1,$e=e.ALLOW_UNKNOWN_PROTOCOLS||!1,je=e.ALLOW_SELF_CLOSE_IN_ATTR!==!1,H=e.SAFE_FOR_TEMPLATES||!1,Ae=e.SAFE_FOR_XML!==!1,k=e.WHOLE_DOCUMENT||!1,z=e.RETURN_DOM||!1,Q=e.RETURN_DOM_FRAGMENT||!1,ee=e.RETURN_TRUSTED_TYPE||!1,ge=e.FORCE_BODY||!1,Ye=e.SANITIZE_DOM!==!1,Xe=e.SANITIZE_NAMED_PROPS||!1,Se=e.KEEP_CONTENT!==!1,X=e.IN_PLACE||!1,_e=e.ALLOWED_URI_REGEXP||_e,B=e.NAMESPACE||w,f=e.CUSTOM_ELEMENT_HANDLING||{},e.CUSTOM_ELEMENT_HANDLING&&Je(e.CUSTOM_ELEMENT_HANDLING.tagNameCheck)&&(f.tagNameCheck=e.CUSTOM_ELEMENT_HANDLING.tagNameCheck),e.CUSTOM_ELEMENT_HANDLING&&Je(e.CUSTOM_ELEMENT_HANDLING.attributeNameCheck)&&(f.attributeNameCheck=e.CUSTOM_ELEMENT_HANDLING.attributeNameCheck),e.CUSTOM_ELEMENT_HANDLING&&typeof e.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements=="boolean"&&(f.allowCustomizedBuiltInElements=e.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements),H&&(Ee=!1),Q&&(z=!0),G&&(p=l({},M(pt)),d=[],G.html===!0&&(l(p,mt),l(d,dt)),G.svg===!0&&(l(p,Ce),l(d,ke),l(d,oe)),G.svgFilters===!0&&(l(p,Ie),l(d,ke),l(d,oe)),G.mathMl===!0&&(l(p,xe),l(d,Tt),l(d,oe))),e.ADD_TAGS&&(p===Ge&&(p=U(p)),l(p,e.ADD_TAGS,T)),e.ADD_ATTR&&(d===We&&(d=U(d)),l(d,e.ADD_ATTR,T)),e.ADD_URI_SAFE_ATTR&&l(be,e.ADD_URI_SAFE_ATTR,T),e.FORBID_CONTENTS&&(W===Ve&&(W=U(W)),l(W,e.FORBID_CONTENTS,T)),Se&&(p["#text"]=!0),k&&l(p,["html","head","body"]),p.table&&(l(p,["tbody"]),delete Y.tbody),E&&E(e),$=e)},Qe=l({},["mi","mo","mn","ms","mtext"]),et=l({},["foreignobject","annotation-xml"]),Ft=l({},["title","style","font","a","script"]),ae=l({},Ce);l(ae,Ie),l(ae,er);var Me=l({},xe);l(Me,tr);var Ut=function(e){var t=fe(e);(!t||!t.tagName)&&(t={namespaceURI:B,tagName:"template"});var r=se(e.tagName),u=se(t.tagName);return Re[e.namespaceURI]?e.namespaceURI===re?t.namespaceURI===w?r==="svg":t.namespaceURI===te?r==="svg"&&(u==="annotation-xml"||Qe[u]):!!ae[r]:e.namespaceURI===te?t.namespaceURI===w?r==="math":t.namespaceURI===re?r==="math"&&et[u]:!!Me[r]:e.namespaceURI===w?t.namespaceURI===re&&!et[u]||t.namespaceURI===te&&!Qe[u]?!1:!Me[r]&&(Ft[r]||!ae[r]):!!(P==="application/xhtml+xml"&&Re[e.namespaceURI]):!1},S=function(e){q(n.removed,{element:e});try{e.parentNode.removeChild(e)}catch{try{e.outerHTML=me}catch{e.remove()}}},ne=function(e,t){try{q(n.removed,{attribute:t.getAttributeNode(e),from:t})}catch{q(n.removed,{attribute:null,from:t})}if(t.removeAttribute(e),e==="is"&&!d[e])if(z||Q)try{S(t)}catch{}else try{t.setAttribute(e,"")}catch{}},tt=function(e){var t,r;if(ge)e="<remove></remove>"+e;else{var u=ct(e,/^[\r\n\t ]+/);r=u&&u[0]}P==="application/xhtml+xml"&&B===w&&(e='<html xmlns="http://www.w3.org/1999/xhtml"><head></head><body>'+e+"</body></html>");var A=R?R.createHTML(e):e;if(B===w)try{t=new At().parseFromString(A,P)}catch{}if(!t||!t.documentElement){t=pe.createDocument(B,"template",null);try{t.documentElement.innerHTML=Oe?me:A}catch{}}var h=t.body||t.documentElement;return e&&r&&h.insertBefore(s.createTextNode(r),h.childNodes[0]||null),B===w?Rt.call(t,k?"html":"body")[0]:k?t.documentElement:h},rt=function(e){return bt.call(e.ownerDocument||e,e,x.SHOW_ELEMENT|x.SHOW_COMMENT|x.SHOW_TEXT|x.SHOW_PROCESSING_INSTRUCTION|x.SHOW_CDATA_SECTION,null,!1)},at=function(e){return e instanceof Et&&(typeof e.nodeName!="string"||typeof e.textContent!="string"||typeof e.removeChild!="function"||!(e.attributes instanceof ht)||typeof e.removeAttribute!="function"||typeof e.setAttribute!="function"||typeof e.namespaceURI!="string"||typeof e.insertBefore!="function"||typeof e.hasChildNodes!="function")},V=function(e){return I(y)==="object"?e instanceof y:e&&I(e)==="object"&&typeof e.nodeType=="number"&&typeof e.nodeName=="string"},C=function(e,t,r){D[e]&&Kt(D[e],function(u){u.call(n,t,r,$)})},nt=function(e){var t;if(C("beforeSanitizeElements",e,null),at(e)||_(/[\u0080-\uFFFF]/,e.nodeName))return S(e),!0;var r=T(e.nodeName);if(C("uponSanitizeElement",e,{tagName:r,allowedTags:p}),e.hasChildNodes()&&!V(e.firstElementChild)&&(!V(e.content)||!V(e.content.firstElementChild))&&_(/<[/\w]/g,e.innerHTML)&&_(/<[/\w]/g,e.textContent)||r==="select"&&_(/<template/i,e.innerHTML)||e.nodeType===7||Ae&&e.nodeType===8&&_(/<[/\w]/g,e.data))return S(e),!0;if(!p[r]||Y[r]){if(!Y[r]&&ot(r)&&(f.tagNameCheck instanceof RegExp&&_(f.tagNameCheck,r)||f.tagNameCheck instanceof Function&&f.tagNameCheck(r)))return!1;if(Se&&!W[r]){var u=fe(e)||e.parentNode,A=St(e)||e.childNodes;if(A&&u)for(var h=A.length,v=h-1;v>=0;--v){var F=yt(A[v],!0);F.__removalCount=(e.__removalCount||0)+1,u.insertBefore(F,gt(e))}}return S(e),!0}return e instanceof N&&!Ut(e)||(r==="noscript"||r==="noembed"||r==="noframes")&&_(/<\/no(script|embed|frames)/i,e.innerHTML)?(S(e),!0):(H&&e.nodeType===3&&(t=e.textContent,t=L(t,de," "),t=L(t,Te," "),t=L(t,ve," "),e.textContent!==t&&(q(n.removed,{element:e.cloneNode()}),e.textContent=t)),C("afterSanitizeElements",e,null),!1)},it=function(e,t,r){if(Ye&&(t==="id"||t==="name")&&(r in s||r in Pt))return!1;if(!(Ee&&!he[t]&&_(Mt,t))){if(!(Be&&_(Nt,t))){if(!d[t]||he[t]){if(!(ot(e)&&(f.tagNameCheck instanceof RegExp&&_(f.tagNameCheck,e)||f.tagNameCheck instanceof Function&&f.tagNameCheck(e))&&(f.attributeNameCheck instanceof RegExp&&_(f.attributeNameCheck,t)||f.attributeNameCheck instanceof Function&&f.attributeNameCheck(t))||t==="is"&&f.allowCustomizedBuiltInElements&&(f.tagNameCheck instanceof RegExp&&_(f.tagNameCheck,r)||f.tagNameCheck instanceof Function&&f.tagNameCheck(r))))return!1}else if(!be[t]){if(!_(_e,L(r,ze,""))){if(!((t==="src"||t==="xlink:href"||t==="href")&&e!=="script"&&Zt(r,"data:")===0&&qe[e])){if(!($e&&!_(Dt,L(r,ze,"")))){if(r)return!1}}}}}}return!0},ot=function(e){return e!=="annotation-xml"&&ct(e,wt)},lt=function(e){var t,r,u,A;C("beforeSanitizeAttributes",e,null);var h=e.attributes;if(h){var v={attrName:"",attrValue:"",keepAttr:!0,allowedAttributes:d};for(A=h.length;A--;){t=h[A];var F=t,m=F.name,Ne=F.namespaceURI;if(r=m==="value"?t.value:Jt(t.value),u=T(m),v.attrName=u,v.attrValue=r,v.keepAttr=!0,v.forceKeepAttr=void 0,C("uponSanitizeAttribute",e,v),r=v.attrValue,Ae&&_(/((--!?|])>)|<\/(style|title)/i,r)){ne(m,e);continue}if(!v.forceKeepAttr&&(ne(m,e),!!v.keepAttr)){if(!je&&_(/\/>/i,r)){ne(m,e);continue}H&&(r=L(r,de," "),r=L(r,Te," "),r=L(r,ve," "));var st=T(e.nodeName);if(it(st,u,r)){if(Xe&&(u==="id"||u==="name")&&(ne(m,e),r=Ct+r),R&&I(K)==="object"&&typeof K.getAttributeType=="function"&&!Ne)switch(K.getAttributeType(st,u)){case"TrustedHTML":{r=R.createHTML(r);break}case"TrustedScriptURL":{r=R.createScriptURL(r);break}}try{Ne?e.setAttributeNS(Ne,m,r):e.setAttribute(m,r),at(e)?S(e):ft(n.removed)}catch{}}}}C("afterSanitizeAttributes",e,null)}},Ht=function i(e){var t,r=rt(e);for(C("beforeSanitizeShadowDOM",e,null);t=r.nextNode();)C("uponSanitizeShadowNode",t,null),!nt(t)&&(t.content instanceof c&&i(t.content),lt(t));C("afterSanitizeShadowDOM",e,null)};return n.sanitize=function(i){var e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},t,r,u,A,h;if(Oe=!i,Oe&&(i="<!-->"),typeof i!="string"&&!V(i))if(typeof i.toString=="function"){if(i=i.toString(),typeof i!="string")throw we("dirty is not a string, aborting")}else throw we("toString is not a function");if(!n.isSupported){if(I(a.toStaticHTML)==="object"||typeof a.toStaticHTML=="function"){if(typeof i=="string")return a.toStaticHTML(i);if(V(i))return a.toStaticHTML(i.outerHTML)}return i}if(ye||Le(e),n.removed=[],typeof i=="string"&&(X=!1),X){if(i.nodeName){var v=T(i.nodeName);if(!p[v]||Y[v])throw we("root node is forbidden and cannot be sanitized in-place")}}else if(i instanceof y)t=tt("<!---->"),r=t.ownerDocument.importNode(i,!0),r.nodeType===1&&r.nodeName==="BODY"||r.nodeName==="HTML"?t=r:t.appendChild(r);else{if(!z&&!H&&!k&&i.indexOf("<")===-1)return R&&ee?R.createHTML(i):i;if(t=tt(i),!t)return z?null:ee?me:""}t&&ge&&S(t.firstChild);for(var F=rt(X?i:t);u=F.nextNode();)u.nodeType===3&&u===A||nt(u)||(u.content instanceof c&&Ht(u.content),lt(u),A=u);if(A=null,X)return i;if(z){if(Q)for(h=Ot.call(t.ownerDocument);t.firstChild;)h.appendChild(t.firstChild);else h=t;return(d.shadowroot||d.shadowrootmod)&&(h=Lt.call(o,h,!0)),h}var m=k?t.outerHTML:t.innerHTML;return k&&p["!doctype"]&&t.ownerDocument&&t.ownerDocument.doctype&&t.ownerDocument.doctype.name&&_(fr,t.ownerDocument.doctype.name)&&(m="<!DOCTYPE "+t.ownerDocument.doctype.name+`>
|
|
1
|
+
/*! @license DOMPurify 2.5.7 | (c) Cure53 and other contributors | Released under the Apache license 2.0 and Mozilla Public License 2.0 | github.com/cure53/DOMPurify/blob/2.5.7/LICENSE */function I(a){"@babel/helpers - typeof";return I=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},I(a)}function Pe(a,n){return Pe=Object.setPrototypeOf||function(s,c){return s.__proto__=c,s},Pe(a,n)}function zt(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function le(a,n,o){return zt()?le=Reflect.construct:le=function(c,g,y){var N=[null];N.push.apply(N,g);var x=Function.bind.apply(c,N),j=new x;return y&&Pe(j,y.prototype),j},le.apply(null,arguments)}function M(a){return Gt(a)||Wt(a)||Bt(a)||$t()}function Gt(a){if(Array.isArray(a))return Fe(a)}function Wt(a){if(typeof Symbol<"u"&&a[Symbol.iterator]!=null||a["@@iterator"]!=null)return Array.from(a)}function Bt(a,n){if(a){if(typeof a=="string")return Fe(a,n);var o=Object.prototype.toString.call(a).slice(8,-1);if(o==="Object"&&a.constructor&&(o=a.constructor.name),o==="Map"||o==="Set")return Array.from(a);if(o==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(o))return Fe(a,n)}}function Fe(a,n){(n==null||n>a.length)&&(n=a.length);for(var o=0,s=new Array(n);o<n;o++)s[o]=a[o];return s}function $t(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
|
|
2
|
+
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}var jt=Object.hasOwnProperty,ut=Object.setPrototypeOf,Yt=Object.isFrozen,Xt=Object.getPrototypeOf,Vt=Object.getOwnPropertyDescriptor,E=Object.freeze,b=Object.seal,qt=Object.create,vt=typeof Reflect<"u"&&Reflect,ue=vt.apply,Ue=vt.construct;ue||(ue=function(n,o,s){return n.apply(o,s)});E||(E=function(n){return n});b||(b=function(n){return n});Ue||(Ue=function(n,o){return le(n,M(o))});var Kt=O(Array.prototype.forEach),ft=O(Array.prototype.pop),q=O(Array.prototype.push),se=O(String.prototype.toLowerCase),De=O(String.prototype.toString),ct=O(String.prototype.match),L=O(String.prototype.replace),Zt=O(String.prototype.indexOf),Jt=O(String.prototype.trim),_=O(RegExp.prototype.test),we=Qt(TypeError);function O(a){return function(n){for(var o=arguments.length,s=new Array(o>1?o-1:0),c=1;c<o;c++)s[c-1]=arguments[c];return ue(a,n,s)}}function Qt(a){return function(){for(var n=arguments.length,o=new Array(n),s=0;s<n;s++)o[s]=arguments[s];return Ue(a,o)}}function l(a,n,o){var s;o=(s=o)!==null&&s!==void 0?s:se,ut&&ut(a,null);for(var c=n.length;c--;){var g=n[c];if(typeof g=="string"){var y=o(g);y!==g&&(Yt(n)||(n[c]=y),g=y)}a[g]=!0}return a}function U(a){var n=qt(null),o;for(o in a)ue(jt,a,[o])===!0&&(n[o]=a[o]);return n}function ie(a,n){for(;a!==null;){var o=Vt(a,n);if(o){if(o.get)return O(o.get);if(typeof o.value=="function")return O(o.value)}a=Xt(a)}function s(c){return console.warn("fallback value for",c),null}return s}var mt=E(["a","abbr","acronym","address","area","article","aside","audio","b","bdi","bdo","big","blink","blockquote","body","br","button","canvas","caption","center","cite","code","col","colgroup","content","data","datalist","dd","decorator","del","details","dfn","dialog","dir","div","dl","dt","element","em","fieldset","figcaption","figure","font","footer","form","h1","h2","h3","h4","h5","h6","head","header","hgroup","hr","html","i","img","input","ins","kbd","label","legend","li","main","map","mark","marquee","menu","menuitem","meter","nav","nobr","ol","optgroup","option","output","p","picture","pre","progress","q","rp","rt","ruby","s","samp","section","select","shadow","small","source","spacer","span","strike","strong","style","sub","summary","sup","table","tbody","td","template","textarea","tfoot","th","thead","time","tr","track","tt","u","ul","var","video","wbr"]),Ce=E(["svg","a","altglyph","altglyphdef","altglyphitem","animatecolor","animatemotion","animatetransform","circle","clippath","defs","desc","ellipse","filter","font","g","glyph","glyphref","hkern","image","line","lineargradient","marker","mask","metadata","mpath","path","pattern","polygon","polyline","radialgradient","rect","stop","style","switch","symbol","text","textpath","title","tref","tspan","view","vkern"]),Ie=E(["feBlend","feColorMatrix","feComponentTransfer","feComposite","feConvolveMatrix","feDiffuseLighting","feDisplacementMap","feDistantLight","feFlood","feFuncA","feFuncB","feFuncG","feFuncR","feGaussianBlur","feImage","feMerge","feMergeNode","feMorphology","feOffset","fePointLight","feSpecularLighting","feSpotLight","feTile","feTurbulence"]),er=E(["animate","color-profile","cursor","discard","fedropshadow","font-face","font-face-format","font-face-name","font-face-src","font-face-uri","foreignobject","hatch","hatchpath","mesh","meshgradient","meshpatch","meshrow","missing-glyph","script","set","solidcolor","unknown","use"]),xe=E(["math","menclose","merror","mfenced","mfrac","mglyph","mi","mlabeledtr","mmultiscripts","mn","mo","mover","mpadded","mphantom","mroot","mrow","ms","mspace","msqrt","mstyle","msub","msup","msubsup","mtable","mtd","mtext","mtr","munder","munderover"]),tr=E(["maction","maligngroup","malignmark","mlongdiv","mscarries","mscarry","msgroup","mstack","msline","msrow","semantics","annotation","annotation-xml","mprescripts","none"]),pt=E(["#text"]),dt=E(["accept","action","align","alt","autocapitalize","autocomplete","autopictureinpicture","autoplay","background","bgcolor","border","capture","cellpadding","cellspacing","checked","cite","class","clear","color","cols","colspan","controls","controlslist","coords","crossorigin","datetime","decoding","default","dir","disabled","disablepictureinpicture","disableremoteplayback","download","draggable","enctype","enterkeyhint","face","for","headers","height","hidden","high","href","hreflang","id","inputmode","integrity","ismap","kind","label","lang","list","loading","loop","low","max","maxlength","media","method","min","minlength","multiple","muted","name","nonce","noshade","novalidate","nowrap","open","optimum","pattern","placeholder","playsinline","poster","preload","pubdate","radiogroup","readonly","rel","required","rev","reversed","role","rows","rowspan","spellcheck","scope","selected","shape","size","sizes","span","srclang","start","src","srcset","step","style","summary","tabindex","title","translate","type","usemap","valign","value","width","xmlns","slot"]),ke=E(["accent-height","accumulate","additive","alignment-baseline","ascent","attributename","attributetype","azimuth","basefrequency","baseline-shift","begin","bias","by","class","clip","clippathunits","clip-path","clip-rule","color","color-interpolation","color-interpolation-filters","color-profile","color-rendering","cx","cy","d","dx","dy","diffuseconstant","direction","display","divisor","dur","edgemode","elevation","end","fill","fill-opacity","fill-rule","filter","filterunits","flood-color","flood-opacity","font-family","font-size","font-size-adjust","font-stretch","font-style","font-variant","font-weight","fx","fy","g1","g2","glyph-name","glyphref","gradientunits","gradienttransform","height","href","id","image-rendering","in","in2","k","k1","k2","k3","k4","kerning","keypoints","keysplines","keytimes","lang","lengthadjust","letter-spacing","kernelmatrix","kernelunitlength","lighting-color","local","marker-end","marker-mid","marker-start","markerheight","markerunits","markerwidth","maskcontentunits","maskunits","max","mask","media","method","mode","min","name","numoctaves","offset","operator","opacity","order","orient","orientation","origin","overflow","paint-order","path","pathlength","patterncontentunits","patterntransform","patternunits","points","preservealpha","preserveaspectratio","primitiveunits","r","rx","ry","radius","refx","refy","repeatcount","repeatdur","restart","result","rotate","scale","seed","shape-rendering","specularconstant","specularexponent","spreadmethod","startoffset","stddeviation","stitchtiles","stop-color","stop-opacity","stroke-dasharray","stroke-dashoffset","stroke-linecap","stroke-linejoin","stroke-miterlimit","stroke-opacity","stroke","stroke-width","style","surfacescale","systemlanguage","tabindex","targetx","targety","transform","transform-origin","text-anchor","text-decoration","text-rendering","textlength","type","u1","u2","unicode","values","viewbox","visibility","version","vert-adv-y","vert-origin-x","vert-origin-y","width","word-spacing","wrap","writing-mode","xchannelselector","ychannelselector","x","x1","x2","xmlns","y","y1","y2","z","zoomandpan"]),Tt=E(["accent","accentunder","align","bevelled","close","columnsalign","columnlines","columnspan","denomalign","depth","dir","display","displaystyle","encoding","fence","frame","height","href","id","largeop","length","linethickness","lspace","lquote","mathbackground","mathcolor","mathsize","mathvariant","maxsize","minsize","movablelimits","notation","numalign","open","rowalign","rowlines","rowspacing","rowspan","rspace","rquote","scriptlevel","scriptminsize","scriptsizemultiplier","selection","separator","separators","stretchy","subscriptshift","supscriptshift","symmetric","voffset","width","xmlns"]),oe=E(["xlink:href","xml:id","xlink:title","xml:space","xmlns:xlink"]),rr=b(/\{\{[\w\W]*|[\w\W]*\}\}/gm),ar=b(/<%[\w\W]*|[\w\W]*%>/gm),nr=b(/\${[\w\W]*}/gm),ir=b(/^data-[\-\w.\u00B7-\uFFFF]/),or=b(/^aria-[\-\w]+$/),lr=b(/^(?:(?:(?:f|ht)tps?|mailto|tel|callto|cid|xmpp):|[^a-z]|[a-z+.\-]+(?:[^a-z+.\-:]|$))/i),sr=b(/^(?:\w+script|data):/i),ur=b(/[\u0000-\u0020\u00A0\u1680\u180E\u2000-\u2029\u205F\u3000]/g),fr=b(/^html$/i),cr=b(/^[a-z][.\w]*(-[.\w]+)+$/i),mr=function(){return typeof window>"u"?null:window},pr=function(n,o){if(I(n)!=="object"||typeof n.createPolicy!="function")return null;var s=null,c="data-tt-policy-suffix";o.currentScript&&o.currentScript.hasAttribute(c)&&(s=o.currentScript.getAttribute(c));var g="dompurify"+(s?"#"+s:"");try{return n.createPolicy(g,{createHTML:function(N){return N},createScriptURL:function(N){return N}})}catch{return console.warn("TrustedTypes policy "+g+" could not be created."),null}};function _t(){var a=arguments.length>0&&arguments[0]!==void 0?arguments[0]:mr(),n=function(e){return _t(e)};if(n.version="2.5.7",n.removed=[],!a||!a.document||a.document.nodeType!==9)return n.isSupported=!1,n;var o=a.document,s=a.document,c=a.DocumentFragment,g=a.HTMLTemplateElement,y=a.Node,N=a.Element,x=a.NodeFilter,j=a.NamedNodeMap,ht=j===void 0?a.NamedNodeMap||a.MozNamedAttrMap:j,Et=a.HTMLFormElement,At=a.DOMParser,K=a.trustedTypes,Z=N.prototype,yt=ie(Z,"cloneNode"),gt=ie(Z,"nextSibling"),St=ie(Z,"childNodes"),fe=ie(Z,"parentNode");if(typeof g=="function"){var ce=s.createElement("template");ce.content&&ce.content.ownerDocument&&(s=ce.content.ownerDocument)}var R=pr(K,o),me=R?R.createHTML(""):"",J=s,pe=J.implementation,bt=J.createNodeIterator,Ot=J.createDocumentFragment,Rt=J.getElementsByTagName,Lt=o.importNode,He={};try{He=U(s).documentMode?s.documentMode:{}}catch{}var D={};n.isSupported=typeof fe=="function"&&pe&&pe.createHTMLDocument!==void 0&&He!==9;var de=rr,Te=ar,ve=nr,Mt=ir,Nt=or,Dt=sr,ze=ur,wt=cr,_e=lr,p=null,Ge=l({},[].concat(M(mt),M(Ce),M(Ie),M(xe),M(pt))),d=null,We=l({},[].concat(M(dt),M(ke),M(Tt),M(oe))),f=Object.seal(Object.create(null,{tagNameCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},attributeNameCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},allowCustomizedBuiltInElements:{writable:!0,configurable:!1,enumerable:!0,value:!1}})),Y=null,he=null,Be=!0,Ee=!0,$e=!1,je=!0,H=!1,Ae=!0,k=!1,ye=!1,ge=!1,z=!1,Q=!1,ee=!1,Ye=!0,Xe=!1,Ct="user-content-",Se=!0,X=!1,G={},W=null,Ve=l({},["annotation-xml","audio","colgroup","desc","foreignobject","head","iframe","math","mi","mn","mo","ms","mtext","noembed","noframes","noscript","plaintext","script","style","svg","template","thead","title","video","xmp"]),qe=null,Ke=l({},["audio","video","img","source","image","track"]),be=null,Ze=l({},["alt","class","for","id","label","name","pattern","placeholder","role","summary","title","value","style","xmlns"]),te="http://www.w3.org/1998/Math/MathML",re="http://www.w3.org/2000/svg",w="http://www.w3.org/1999/xhtml",B=w,Oe=!1,Re=null,It=l({},[te,re,w],De),P,xt=["application/xhtml+xml","text/html"],kt="text/html",T,$=null,Pt=s.createElement("form"),Je=function(e){return e instanceof RegExp||e instanceof Function},Le=function(e){$&&$===e||((!e||I(e)!=="object")&&(e={}),e=U(e),P=xt.indexOf(e.PARSER_MEDIA_TYPE)===-1?P=kt:P=e.PARSER_MEDIA_TYPE,T=P==="application/xhtml+xml"?De:se,p="ALLOWED_TAGS"in e?l({},e.ALLOWED_TAGS,T):Ge,d="ALLOWED_ATTR"in e?l({},e.ALLOWED_ATTR,T):We,Re="ALLOWED_NAMESPACES"in e?l({},e.ALLOWED_NAMESPACES,De):It,be="ADD_URI_SAFE_ATTR"in e?l(U(Ze),e.ADD_URI_SAFE_ATTR,T):Ze,qe="ADD_DATA_URI_TAGS"in e?l(U(Ke),e.ADD_DATA_URI_TAGS,T):Ke,W="FORBID_CONTENTS"in e?l({},e.FORBID_CONTENTS,T):Ve,Y="FORBID_TAGS"in e?l({},e.FORBID_TAGS,T):{},he="FORBID_ATTR"in e?l({},e.FORBID_ATTR,T):{},G="USE_PROFILES"in e?e.USE_PROFILES:!1,Be=e.ALLOW_ARIA_ATTR!==!1,Ee=e.ALLOW_DATA_ATTR!==!1,$e=e.ALLOW_UNKNOWN_PROTOCOLS||!1,je=e.ALLOW_SELF_CLOSE_IN_ATTR!==!1,H=e.SAFE_FOR_TEMPLATES||!1,Ae=e.SAFE_FOR_XML!==!1,k=e.WHOLE_DOCUMENT||!1,z=e.RETURN_DOM||!1,Q=e.RETURN_DOM_FRAGMENT||!1,ee=e.RETURN_TRUSTED_TYPE||!1,ge=e.FORCE_BODY||!1,Ye=e.SANITIZE_DOM!==!1,Xe=e.SANITIZE_NAMED_PROPS||!1,Se=e.KEEP_CONTENT!==!1,X=e.IN_PLACE||!1,_e=e.ALLOWED_URI_REGEXP||_e,B=e.NAMESPACE||w,f=e.CUSTOM_ELEMENT_HANDLING||{},e.CUSTOM_ELEMENT_HANDLING&&Je(e.CUSTOM_ELEMENT_HANDLING.tagNameCheck)&&(f.tagNameCheck=e.CUSTOM_ELEMENT_HANDLING.tagNameCheck),e.CUSTOM_ELEMENT_HANDLING&&Je(e.CUSTOM_ELEMENT_HANDLING.attributeNameCheck)&&(f.attributeNameCheck=e.CUSTOM_ELEMENT_HANDLING.attributeNameCheck),e.CUSTOM_ELEMENT_HANDLING&&typeof e.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements=="boolean"&&(f.allowCustomizedBuiltInElements=e.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements),H&&(Ee=!1),Q&&(z=!0),G&&(p=l({},M(pt)),d=[],G.html===!0&&(l(p,mt),l(d,dt)),G.svg===!0&&(l(p,Ce),l(d,ke),l(d,oe)),G.svgFilters===!0&&(l(p,Ie),l(d,ke),l(d,oe)),G.mathMl===!0&&(l(p,xe),l(d,Tt),l(d,oe))),e.ADD_TAGS&&(p===Ge&&(p=U(p)),l(p,e.ADD_TAGS,T)),e.ADD_ATTR&&(d===We&&(d=U(d)),l(d,e.ADD_ATTR,T)),e.ADD_URI_SAFE_ATTR&&l(be,e.ADD_URI_SAFE_ATTR,T),e.FORBID_CONTENTS&&(W===Ve&&(W=U(W)),l(W,e.FORBID_CONTENTS,T)),Se&&(p["#text"]=!0),k&&l(p,["html","head","body"]),p.table&&(l(p,["tbody"]),delete Y.tbody),E&&E(e),$=e)},Qe=l({},["mi","mo","mn","ms","mtext"]),et=l({},["annotation-xml"]),Ft=l({},["title","style","font","a","script"]),ae=l({},Ce);l(ae,Ie),l(ae,er);var Me=l({},xe);l(Me,tr);var Ut=function(e){var t=fe(e);(!t||!t.tagName)&&(t={namespaceURI:B,tagName:"template"});var r=se(e.tagName),u=se(t.tagName);return Re[e.namespaceURI]?e.namespaceURI===re?t.namespaceURI===w?r==="svg":t.namespaceURI===te?r==="svg"&&(u==="annotation-xml"||Qe[u]):!!ae[r]:e.namespaceURI===te?t.namespaceURI===w?r==="math":t.namespaceURI===re?r==="math"&&et[u]:!!Me[r]:e.namespaceURI===w?t.namespaceURI===re&&!et[u]||t.namespaceURI===te&&!Qe[u]?!1:!Me[r]&&(Ft[r]||!ae[r]):!!(P==="application/xhtml+xml"&&Re[e.namespaceURI]):!1},S=function(e){q(n.removed,{element:e});try{e.parentNode.removeChild(e)}catch{try{e.outerHTML=me}catch{e.remove()}}},ne=function(e,t){try{q(n.removed,{attribute:t.getAttributeNode(e),from:t})}catch{q(n.removed,{attribute:null,from:t})}if(t.removeAttribute(e),e==="is"&&!d[e])if(z||Q)try{S(t)}catch{}else try{t.setAttribute(e,"")}catch{}},tt=function(e){var t,r;if(ge)e="<remove></remove>"+e;else{var u=ct(e,/^[\r\n\t ]+/);r=u&&u[0]}P==="application/xhtml+xml"&&B===w&&(e='<html xmlns="http://www.w3.org/1999/xhtml"><head></head><body>'+e+"</body></html>");var A=R?R.createHTML(e):e;if(B===w)try{t=new At().parseFromString(A,P)}catch{}if(!t||!t.documentElement){t=pe.createDocument(B,"template",null);try{t.documentElement.innerHTML=Oe?me:A}catch{}}var h=t.body||t.documentElement;return e&&r&&h.insertBefore(s.createTextNode(r),h.childNodes[0]||null),B===w?Rt.call(t,k?"html":"body")[0]:k?t.documentElement:h},rt=function(e){return bt.call(e.ownerDocument||e,e,x.SHOW_ELEMENT|x.SHOW_COMMENT|x.SHOW_TEXT|x.SHOW_PROCESSING_INSTRUCTION|x.SHOW_CDATA_SECTION,null,!1)},at=function(e){return e instanceof Et&&(typeof e.nodeName!="string"||typeof e.textContent!="string"||typeof e.removeChild!="function"||!(e.attributes instanceof ht)||typeof e.removeAttribute!="function"||typeof e.setAttribute!="function"||typeof e.namespaceURI!="string"||typeof e.insertBefore!="function"||typeof e.hasChildNodes!="function")},V=function(e){return I(y)==="object"?e instanceof y:e&&I(e)==="object"&&typeof e.nodeType=="number"&&typeof e.nodeName=="string"},C=function(e,t,r){D[e]&&Kt(D[e],function(u){u.call(n,t,r,$)})},nt=function(e){var t;if(C("beforeSanitizeElements",e,null),at(e)||_(/[\u0080-\uFFFF]/,e.nodeName))return S(e),!0;var r=T(e.nodeName);if(C("uponSanitizeElement",e,{tagName:r,allowedTags:p}),e.hasChildNodes()&&!V(e.firstElementChild)&&(!V(e.content)||!V(e.content.firstElementChild))&&_(/<[/\w]/g,e.innerHTML)&&_(/<[/\w]/g,e.textContent)||r==="select"&&_(/<template/i,e.innerHTML)||e.nodeType===7||Ae&&e.nodeType===8&&_(/<[/\w]/g,e.data))return S(e),!0;if(!p[r]||Y[r]){if(!Y[r]&&ot(r)&&(f.tagNameCheck instanceof RegExp&&_(f.tagNameCheck,r)||f.tagNameCheck instanceof Function&&f.tagNameCheck(r)))return!1;if(Se&&!W[r]){var u=fe(e)||e.parentNode,A=St(e)||e.childNodes;if(A&&u)for(var h=A.length,v=h-1;v>=0;--v){var F=yt(A[v],!0);F.__removalCount=(e.__removalCount||0)+1,u.insertBefore(F,gt(e))}}return S(e),!0}return e instanceof N&&!Ut(e)||(r==="noscript"||r==="noembed"||r==="noframes")&&_(/<\/no(script|embed|frames)/i,e.innerHTML)?(S(e),!0):(H&&e.nodeType===3&&(t=e.textContent,t=L(t,de," "),t=L(t,Te," "),t=L(t,ve," "),e.textContent!==t&&(q(n.removed,{element:e.cloneNode()}),e.textContent=t)),C("afterSanitizeElements",e,null),!1)},it=function(e,t,r){if(Ye&&(t==="id"||t==="name")&&(r in s||r in Pt))return!1;if(!(Ee&&!he[t]&&_(Mt,t))){if(!(Be&&_(Nt,t))){if(!d[t]||he[t]){if(!(ot(e)&&(f.tagNameCheck instanceof RegExp&&_(f.tagNameCheck,e)||f.tagNameCheck instanceof Function&&f.tagNameCheck(e))&&(f.attributeNameCheck instanceof RegExp&&_(f.attributeNameCheck,t)||f.attributeNameCheck instanceof Function&&f.attributeNameCheck(t))||t==="is"&&f.allowCustomizedBuiltInElements&&(f.tagNameCheck instanceof RegExp&&_(f.tagNameCheck,r)||f.tagNameCheck instanceof Function&&f.tagNameCheck(r))))return!1}else if(!be[t]){if(!_(_e,L(r,ze,""))){if(!((t==="src"||t==="xlink:href"||t==="href")&&e!=="script"&&Zt(r,"data:")===0&&qe[e])){if(!($e&&!_(Dt,L(r,ze,"")))){if(r)return!1}}}}}}return!0},ot=function(e){return e!=="annotation-xml"&&ct(e,wt)},lt=function(e){var t,r,u,A;C("beforeSanitizeAttributes",e,null);var h=e.attributes;if(h){var v={attrName:"",attrValue:"",keepAttr:!0,allowedAttributes:d};for(A=h.length;A--;){t=h[A];var F=t,m=F.name,Ne=F.namespaceURI;if(r=m==="value"?t.value:Jt(t.value),u=T(m),v.attrName=u,v.attrValue=r,v.keepAttr=!0,v.forceKeepAttr=void 0,C("uponSanitizeAttribute",e,v),r=v.attrValue,!v.forceKeepAttr&&(ne(m,e),!!v.keepAttr)){if(!je&&_(/\/>/i,r)){ne(m,e);continue}H&&(r=L(r,de," "),r=L(r,Te," "),r=L(r,ve," "));var st=T(e.nodeName);if(it(st,u,r)){if(Xe&&(u==="id"||u==="name")&&(ne(m,e),r=Ct+r),Ae&&_(/((--!?|])>)|<\/(style|title)/i,r)){ne(m,e);continue}if(R&&I(K)==="object"&&typeof K.getAttributeType=="function"&&!Ne)switch(K.getAttributeType(st,u)){case"TrustedHTML":{r=R.createHTML(r);break}case"TrustedScriptURL":{r=R.createScriptURL(r);break}}try{Ne?e.setAttributeNS(Ne,m,r):e.setAttribute(m,r),at(e)?S(e):ft(n.removed)}catch{}}}}C("afterSanitizeAttributes",e,null)}},Ht=function i(e){var t,r=rt(e);for(C("beforeSanitizeShadowDOM",e,null);t=r.nextNode();)C("uponSanitizeShadowNode",t,null),!nt(t)&&(t.content instanceof c&&i(t.content),lt(t));C("afterSanitizeShadowDOM",e,null)};return n.sanitize=function(i){var e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},t,r,u,A,h;if(Oe=!i,Oe&&(i="<!-->"),typeof i!="string"&&!V(i))if(typeof i.toString=="function"){if(i=i.toString(),typeof i!="string")throw we("dirty is not a string, aborting")}else throw we("toString is not a function");if(!n.isSupported){if(I(a.toStaticHTML)==="object"||typeof a.toStaticHTML=="function"){if(typeof i=="string")return a.toStaticHTML(i);if(V(i))return a.toStaticHTML(i.outerHTML)}return i}if(ye||Le(e),n.removed=[],typeof i=="string"&&(X=!1),X){if(i.nodeName){var v=T(i.nodeName);if(!p[v]||Y[v])throw we("root node is forbidden and cannot be sanitized in-place")}}else if(i instanceof y)t=tt("<!---->"),r=t.ownerDocument.importNode(i,!0),r.nodeType===1&&r.nodeName==="BODY"||r.nodeName==="HTML"?t=r:t.appendChild(r);else{if(!z&&!H&&!k&&i.indexOf("<")===-1)return R&&ee?R.createHTML(i):i;if(t=tt(i),!t)return z?null:ee?me:""}t&&ge&&S(t.firstChild);for(var F=rt(X?i:t);u=F.nextNode();)u.nodeType===3&&u===A||nt(u)||(u.content instanceof c&&Ht(u.content),lt(u),A=u);if(A=null,X)return i;if(z){if(Q)for(h=Ot.call(t.ownerDocument);t.firstChild;)h.appendChild(t.firstChild);else h=t;return(d.shadowroot||d.shadowrootmod)&&(h=Lt.call(o,h,!0)),h}var m=k?t.outerHTML:t.innerHTML;return k&&p["!doctype"]&&t.ownerDocument&&t.ownerDocument.doctype&&t.ownerDocument.doctype.name&&_(fr,t.ownerDocument.doctype.name)&&(m="<!DOCTYPE "+t.ownerDocument.doctype.name+`>
|
|
3
3
|
`+m),H&&(m=L(m,de," "),m=L(m,Te," "),m=L(m,ve," ")),R&&ee?R.createHTML(m):m},n.setConfig=function(i){Le(i),ye=!0},n.clearConfig=function(){$=null,ye=!1},n.isValidAttribute=function(i,e,t){$||Le({});var r=T(i),u=T(e);return it(r,u,t)},n.addHook=function(i,e){typeof e=="function"&&(D[i]=D[i]||[],q(D[i],e))},n.removeHook=function(i){if(D[i])return ft(D[i])},n.removeHooks=function(i){D[i]&&(D[i]=[])},n.removeAllHooks=function(){D={}},n}var Tr=_t();export{Tr as default};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{B as l}from"./index-BpjzEMiv.js";class _ extends Error{constructor(e,a,t,...i){Array.isArray(a)&&(a=a.join(" ").trim()),super(a),Error.captureStackTrace!==void 0&&Error.captureStackTrace(this,_),this.code=e;for(const s of i)for(const o in s){const n=s[o];this[o]=l.isBuffer(n)?n.toString(t.encoding):n==null?n:JSON.parse(JSON.stringify(n))}}}const U=function(r){return typeof r=="object"&&r!==null&&!Array.isArray(r)},j=function(r){const e=[];for(let a=0,t=r.length;a<t;a++){const i=r[a];if(i==null||i===!1)e[a]={disabled:!0};else if(typeof i=="string")e[a]={name:i};else if(U(i)){if(typeof i.name!="string")throw new _("CSV_OPTION_COLUMNS_MISSING_NAME",["Option columns missing name:",`property "name" is required at position ${a}`,"when column is an object literal"]);e[a]=i}else throw new _("CSV_INVALID_COLUMN_DEFINITION",["Invalid column definition:","expect a string or a literal object,",`got ${JSON.stringify(i)} at position ${a}`])}return e};class M{constructor(e=100){this.size=e,this.length=0,this.buf=l.allocUnsafe(e)}prepend(e){if(l.isBuffer(e)){const a=this.length+e.length;if(a>=this.size&&(this.resize(),a>=this.size))throw Error("INVALID_BUFFER_STATE");const t=this.buf;this.buf=l.allocUnsafe(this.size),e.copy(this.buf,0),t.copy(this.buf,e.length),this.length+=e.length}else{const a=this.length++;a===this.size&&this.resize();const t=this.clone();this.buf[0]=e,t.copy(this.buf,1,0,a)}}append(e){const a=this.length++;a===this.size&&this.resize(),this.buf[a]=e}clone(){return l.from(this.buf.slice(0,this.length))}resize(){const e=this.length;this.size=this.size*2;const a=l.allocUnsafe(this.size);this.buf.copy(a,0,0,e),this.buf=a}toString(e){return e?this.buf.slice(0,this.length).toString(e):Uint8Array.prototype.slice.call(this.buf.slice(0,this.length))}toJSON(){return this.toString("utf8")}reset(){this.length=0}}const G=12,H=13,Y=10,Z=32,X=9,K=function(r){return{bomSkipped:!1,bufBytesStart:0,castField:r.cast_function,commenting:!1,error:void 0,enabled:r.from_line===1,escaping:!1,escapeIsQuote:l.isBuffer(r.escape)&&l.isBuffer(r.quote)&&l.compare(r.escape,r.quote)===0,expectedRecordLength:Array.isArray(r.columns)?r.columns.length:void 0,field:new M(20),firstLineToHeaders:r.cast_first_line_to_header,needMoreDataSize:Math.max(r.comment!==null?r.comment.length:0,...r.delimiter.map(e=>e.length),r.quote!==null?r.quote.length:0),previousBuf:void 0,quoting:!1,stop:!1,rawBuffer:new M(100),record:[],recordHasError:!1,record_length:0,recordDelimiterMaxLength:r.record_delimiter.length===0?0:Math.max(...r.record_delimiter.map(e=>e.length)),trimChars:[l.from(" ",r.encoding)[0],l.from(" ",r.encoding)[0]],wasQuoting:!1,wasRowDelimiter:!1,timchars:[l.from(l.from([H],"utf8").toString(),r.encoding),l.from(l.from([Y],"utf8").toString(),r.encoding),l.from(l.from([G],"utf8").toString(),r.encoding),l.from(l.from([Z],"utf8").toString(),r.encoding),l.from(l.from([X],"utf8").toString(),r.encoding)]}},W=function(r){return r.replace(/([A-Z])/g,function(e,a){return"_"+a.toLowerCase()})},k=function(r){const e={};for(const t in r)e[W(t)]=r[t];if(e.encoding===void 0||e.encoding===!0)e.encoding="utf8";else if(e.encoding===null||e.encoding===!1)e.encoding=null;else if(typeof e.encoding!="string"&&e.encoding!==null)throw new _("CSV_INVALID_OPTION_ENCODING",["Invalid option encoding:","encoding must be a string or null to return a buffer,",`got ${JSON.stringify(e.encoding)}`],e);if(e.bom===void 0||e.bom===null||e.bom===!1)e.bom=!1;else if(e.bom!==!0)throw new _("CSV_INVALID_OPTION_BOM",["Invalid option bom:","bom must be true,",`got ${JSON.stringify(e.bom)}`],e);if(e.cast_function=null,e.cast===void 0||e.cast===null||e.cast===!1||e.cast==="")e.cast=void 0;else if(typeof e.cast=="function")e.cast_function=e.cast,e.cast=!0;else if(e.cast!==!0)throw new _("CSV_INVALID_OPTION_CAST",["Invalid option cast:","cast must be true or a function,",`got ${JSON.stringify(e.cast)}`],e);if(e.cast_date===void 0||e.cast_date===null||e.cast_date===!1||e.cast_date==="")e.cast_date=!1;else if(e.cast_date===!0)e.cast_date=function(t){const i=Date.parse(t);return isNaN(i)?t:new Date(i)};else if(typeof e.cast_date!="function")throw new _("CSV_INVALID_OPTION_CAST_DATE",["Invalid option cast_date:","cast_date must be true or a function,",`got ${JSON.stringify(e.cast_date)}`],e);if(e.cast_first_line_to_header=null,e.columns===!0)e.cast_first_line_to_header=void 0;else if(typeof e.columns=="function")e.cast_first_line_to_header=e.columns,e.columns=!0;else if(Array.isArray(e.columns))e.columns=j(e.columns);else if(e.columns===void 0||e.columns===null||e.columns===!1)e.columns=!1;else throw new _("CSV_INVALID_OPTION_COLUMNS",["Invalid option columns:","expect an array, a function or true,",`got ${JSON.stringify(e.columns)}`],e);if(e.group_columns_by_name===void 0||e.group_columns_by_name===null||e.group_columns_by_name===!1)e.group_columns_by_name=!1;else{if(e.group_columns_by_name!==!0)throw new _("CSV_INVALID_OPTION_GROUP_COLUMNS_BY_NAME",["Invalid option group_columns_by_name:","expect an boolean,",`got ${JSON.stringify(e.group_columns_by_name)}`],e);if(e.columns===!1)throw new _("CSV_INVALID_OPTION_GROUP_COLUMNS_BY_NAME",["Invalid option group_columns_by_name:","the `columns` mode must be activated."],e)}if(e.comment===void 0||e.comment===null||e.comment===!1||e.comment==="")e.comment=null;else if(typeof e.comment=="string"&&(e.comment=l.from(e.comment,e.encoding)),!l.isBuffer(e.comment))throw new _("CSV_INVALID_OPTION_COMMENT",["Invalid option comment:","comment must be a buffer or a string,",`got ${JSON.stringify(e.comment)}`],e);if(e.comment_no_infix===void 0||e.comment_no_infix===null||e.comment_no_infix===!1)e.comment_no_infix=!1;else if(e.comment_no_infix!==!0)throw new _("CSV_INVALID_OPTION_COMMENT",["Invalid option comment_no_infix:","value must be a boolean,",`got ${JSON.stringify(e.comment_no_infix)}`],e);const a=JSON.stringify(e.delimiter);if(Array.isArray(e.delimiter)||(e.delimiter=[e.delimiter]),e.delimiter.length===0)throw new _("CSV_INVALID_OPTION_DELIMITER",["Invalid option delimiter:","delimiter must be a non empty string or buffer or array of string|buffer,",`got ${a}`],e);if(e.delimiter=e.delimiter.map(function(t){if(t==null||t===!1)return l.from(",",e.encoding);if(typeof t=="string"&&(t=l.from(t,e.encoding)),!l.isBuffer(t)||t.length===0)throw new _("CSV_INVALID_OPTION_DELIMITER",["Invalid option delimiter:","delimiter must be a non empty string or buffer or array of string|buffer,",`got ${a}`],e);return t}),e.escape===void 0||e.escape===!0?e.escape=l.from('"',e.encoding):typeof e.escape=="string"?e.escape=l.from(e.escape,e.encoding):(e.escape===null||e.escape===!1)&&(e.escape=null),e.escape!==null&&!l.isBuffer(e.escape))throw new Error(`Invalid Option: escape must be a buffer, a string or a boolean, got ${JSON.stringify(e.escape)}`);if(e.from===void 0||e.from===null)e.from=1;else if(typeof e.from=="string"&&/\d+/.test(e.from)&&(e.from=parseInt(e.from)),Number.isInteger(e.from)){if(e.from<0)throw new Error(`Invalid Option: from must be a positive integer, got ${JSON.stringify(r.from)}`)}else throw new Error(`Invalid Option: from must be an integer, got ${JSON.stringify(e.from)}`);if(e.from_line===void 0||e.from_line===null)e.from_line=1;else if(typeof e.from_line=="string"&&/\d+/.test(e.from_line)&&(e.from_line=parseInt(e.from_line)),Number.isInteger(e.from_line)){if(e.from_line<=0)throw new Error(`Invalid Option: from_line must be a positive integer greater than 0, got ${JSON.stringify(r.from_line)}`)}else throw new Error(`Invalid Option: from_line must be an integer, got ${JSON.stringify(r.from_line)}`);if(e.ignore_last_delimiters===void 0||e.ignore_last_delimiters===null)e.ignore_last_delimiters=!1;else if(typeof e.ignore_last_delimiters=="number")e.ignore_last_delimiters=Math.floor(e.ignore_last_delimiters),e.ignore_last_delimiters===0&&(e.ignore_last_delimiters=!1);else if(typeof e.ignore_last_delimiters!="boolean")throw new _("CSV_INVALID_OPTION_IGNORE_LAST_DELIMITERS",["Invalid option `ignore_last_delimiters`:","the value must be a boolean value or an integer,",`got ${JSON.stringify(e.ignore_last_delimiters)}`],e);if(e.ignore_last_delimiters===!0&&e.columns===!1)throw new _("CSV_IGNORE_LAST_DELIMITERS_REQUIRES_COLUMNS",["The option `ignore_last_delimiters`","requires the activation of the `columns` option"],e);if(e.info===void 0||e.info===null||e.info===!1)e.info=!1;else if(e.info!==!0)throw new Error(`Invalid Option: info must be true, got ${JSON.stringify(e.info)}`);if(e.max_record_size===void 0||e.max_record_size===null||e.max_record_size===!1)e.max_record_size=0;else if(!(Number.isInteger(e.max_record_size)&&e.max_record_size>=0))if(typeof e.max_record_size=="string"&&/\d+/.test(e.max_record_size))e.max_record_size=parseInt(e.max_record_size);else throw new Error(`Invalid Option: max_record_size must be a positive integer, got ${JSON.stringify(e.max_record_size)}`);if(e.objname===void 0||e.objname===null||e.objname===!1)e.objname=void 0;else if(l.isBuffer(e.objname)){if(e.objname.length===0)throw new Error("Invalid Option: objname must be a non empty buffer");e.encoding===null||(e.objname=e.objname.toString(e.encoding))}else if(typeof e.objname=="string"){if(e.objname.length===0)throw new Error("Invalid Option: objname must be a non empty string")}else if(typeof e.objname!="number")throw new Error(`Invalid Option: objname must be a string or a buffer, got ${e.objname}`);if(e.objname!==void 0){if(typeof e.objname=="number"){if(e.columns!==!1)throw Error("Invalid Option: objname index cannot be combined with columns or be defined as a field")}else if(e.columns===!1)throw Error("Invalid Option: objname field must be combined with columns or be defined as an index")}if(e.on_record===void 0||e.on_record===null)e.on_record=void 0;else if(typeof e.on_record!="function")throw new _("CSV_INVALID_OPTION_ON_RECORD",["Invalid option `on_record`:","expect a function,",`got ${JSON.stringify(e.on_record)}`],e);if(e.on_skip!==void 0&&e.on_skip!==null&&typeof e.on_skip!="function")throw new Error(`Invalid Option: on_skip must be a function, got ${JSON.stringify(e.on_skip)}`);if(e.quote===null||e.quote===!1||e.quote==="")e.quote=null;else if(e.quote===void 0||e.quote===!0?e.quote=l.from('"',e.encoding):typeof e.quote=="string"&&(e.quote=l.from(e.quote,e.encoding)),!l.isBuffer(e.quote))throw new Error(`Invalid Option: quote must be a buffer or a string, got ${JSON.stringify(e.quote)}`);if(e.raw===void 0||e.raw===null||e.raw===!1)e.raw=!1;else if(e.raw!==!0)throw new Error(`Invalid Option: raw must be true, got ${JSON.stringify(e.raw)}`);if(e.record_delimiter===void 0)e.record_delimiter=[];else if(typeof e.record_delimiter=="string"||l.isBuffer(e.record_delimiter)){if(e.record_delimiter.length===0)throw new _("CSV_INVALID_OPTION_RECORD_DELIMITER",["Invalid option `record_delimiter`:","value must be a non empty string or buffer,",`got ${JSON.stringify(e.record_delimiter)}`],e);e.record_delimiter=[e.record_delimiter]}else if(!Array.isArray(e.record_delimiter))throw new _("CSV_INVALID_OPTION_RECORD_DELIMITER",["Invalid option `record_delimiter`:","value must be a string, a buffer or array of string|buffer,",`got ${JSON.stringify(e.record_delimiter)}`],e);if(e.record_delimiter=e.record_delimiter.map(function(t,i){if(typeof t!="string"&&!l.isBuffer(t))throw new _("CSV_INVALID_OPTION_RECORD_DELIMITER",["Invalid option `record_delimiter`:","value must be a string, a buffer or array of string|buffer",`at index ${i},`,`got ${JSON.stringify(t)}`],e);if(t.length===0)throw new _("CSV_INVALID_OPTION_RECORD_DELIMITER",["Invalid option `record_delimiter`:","value must be a non empty string or buffer",`at index ${i},`,`got ${JSON.stringify(t)}`],e);return typeof t=="string"&&(t=l.from(t,e.encoding)),t}),typeof e.relax_column_count!="boolean")if(e.relax_column_count===void 0||e.relax_column_count===null)e.relax_column_count=!1;else throw new Error(`Invalid Option: relax_column_count must be a boolean, got ${JSON.stringify(e.relax_column_count)}`);if(typeof e.relax_column_count_less!="boolean")if(e.relax_column_count_less===void 0||e.relax_column_count_less===null)e.relax_column_count_less=!1;else throw new Error(`Invalid Option: relax_column_count_less must be a boolean, got ${JSON.stringify(e.relax_column_count_less)}`);if(typeof e.relax_column_count_more!="boolean")if(e.relax_column_count_more===void 0||e.relax_column_count_more===null)e.relax_column_count_more=!1;else throw new Error(`Invalid Option: relax_column_count_more must be a boolean, got ${JSON.stringify(e.relax_column_count_more)}`);if(typeof e.relax_quotes!="boolean")if(e.relax_quotes===void 0||e.relax_quotes===null)e.relax_quotes=!1;else throw new Error(`Invalid Option: relax_quotes must be a boolean, got ${JSON.stringify(e.relax_quotes)}`);if(typeof e.skip_empty_lines!="boolean")if(e.skip_empty_lines===void 0||e.skip_empty_lines===null)e.skip_empty_lines=!1;else throw new Error(`Invalid Option: skip_empty_lines must be a boolean, got ${JSON.stringify(e.skip_empty_lines)}`);if(typeof e.skip_records_with_empty_values!="boolean")if(e.skip_records_with_empty_values===void 0||e.skip_records_with_empty_values===null)e.skip_records_with_empty_values=!1;else throw new Error(`Invalid Option: skip_records_with_empty_values must be a boolean, got ${JSON.stringify(e.skip_records_with_empty_values)}`);if(typeof e.skip_records_with_error!="boolean")if(e.skip_records_with_error===void 0||e.skip_records_with_error===null)e.skip_records_with_error=!1;else throw new Error(`Invalid Option: skip_records_with_error must be a boolean, got ${JSON.stringify(e.skip_records_with_error)}`);if(e.rtrim===void 0||e.rtrim===null||e.rtrim===!1)e.rtrim=!1;else if(e.rtrim!==!0)throw new Error(`Invalid Option: rtrim must be a boolean, got ${JSON.stringify(e.rtrim)}`);if(e.ltrim===void 0||e.ltrim===null||e.ltrim===!1)e.ltrim=!1;else if(e.ltrim!==!0)throw new Error(`Invalid Option: ltrim must be a boolean, got ${JSON.stringify(e.ltrim)}`);if(e.trim===void 0||e.trim===null||e.trim===!1)e.trim=!1;else if(e.trim!==!0)throw new Error(`Invalid Option: trim must be a boolean, got ${JSON.stringify(e.trim)}`);if(e.trim===!0&&r.ltrim!==!1?e.ltrim=!0:e.ltrim!==!0&&(e.ltrim=!1),e.trim===!0&&r.rtrim!==!1?e.rtrim=!0:e.rtrim!==!0&&(e.rtrim=!1),e.to===void 0||e.to===null)e.to=-1;else if(typeof e.to=="string"&&/\d+/.test(e.to)&&(e.to=parseInt(e.to)),Number.isInteger(e.to)){if(e.to<=0)throw new Error(`Invalid Option: to must be a positive integer greater than 0, got ${JSON.stringify(r.to)}`)}else throw new Error(`Invalid Option: to must be an integer, got ${JSON.stringify(r.to)}`);if(e.to_line===void 0||e.to_line===null)e.to_line=-1;else if(typeof e.to_line=="string"&&/\d+/.test(e.to_line)&&(e.to_line=parseInt(e.to_line)),Number.isInteger(e.to_line)){if(e.to_line<=0)throw new Error(`Invalid Option: to_line must be a positive integer greater than 0, got ${JSON.stringify(r.to_line)}`)}else throw new Error(`Invalid Option: to_line must be an integer, got ${JSON.stringify(r.to_line)}`);return e},B=function(r){return r.every(e=>e==null||e.toString&&e.toString().trim()==="")},ee=13,te=10,L={utf8:l.from([239,187,191]),utf16le:l.from([255,254])},ie=function(r={}){const e={bytes:0,comment_lines:0,empty_lines:0,invalid_field_length:0,lines:1,records:0},a=k(r);return{info:e,original_options:r,options:a,state:K(a),__needMoreData:function(t,i,s){if(s)return!1;const{encoding:o,escape:n,quote:u}=this.options,{quoting:c,needMoreDataSize:p,recordDelimiterMaxLength:b}=this.state,N=i-t-1,D=Math.max(p,b===0?l.from(`\r
|
|
1
|
+
import{B as l}from"./index-CQmOdU-e.js";class _ extends Error{constructor(e,a,t,...i){Array.isArray(a)&&(a=a.join(" ").trim()),super(a),Error.captureStackTrace!==void 0&&Error.captureStackTrace(this,_),this.code=e;for(const s of i)for(const o in s){const n=s[o];this[o]=l.isBuffer(n)?n.toString(t.encoding):n==null?n:JSON.parse(JSON.stringify(n))}}}const U=function(r){return typeof r=="object"&&r!==null&&!Array.isArray(r)},j=function(r){const e=[];for(let a=0,t=r.length;a<t;a++){const i=r[a];if(i==null||i===!1)e[a]={disabled:!0};else if(typeof i=="string")e[a]={name:i};else if(U(i)){if(typeof i.name!="string")throw new _("CSV_OPTION_COLUMNS_MISSING_NAME",["Option columns missing name:",`property "name" is required at position ${a}`,"when column is an object literal"]);e[a]=i}else throw new _("CSV_INVALID_COLUMN_DEFINITION",["Invalid column definition:","expect a string or a literal object,",`got ${JSON.stringify(i)} at position ${a}`])}return e};class M{constructor(e=100){this.size=e,this.length=0,this.buf=l.allocUnsafe(e)}prepend(e){if(l.isBuffer(e)){const a=this.length+e.length;if(a>=this.size&&(this.resize(),a>=this.size))throw Error("INVALID_BUFFER_STATE");const t=this.buf;this.buf=l.allocUnsafe(this.size),e.copy(this.buf,0),t.copy(this.buf,e.length),this.length+=e.length}else{const a=this.length++;a===this.size&&this.resize();const t=this.clone();this.buf[0]=e,t.copy(this.buf,1,0,a)}}append(e){const a=this.length++;a===this.size&&this.resize(),this.buf[a]=e}clone(){return l.from(this.buf.slice(0,this.length))}resize(){const e=this.length;this.size=this.size*2;const a=l.allocUnsafe(this.size);this.buf.copy(a,0,0,e),this.buf=a}toString(e){return e?this.buf.slice(0,this.length).toString(e):Uint8Array.prototype.slice.call(this.buf.slice(0,this.length))}toJSON(){return this.toString("utf8")}reset(){this.length=0}}const G=12,H=13,Y=10,Z=32,X=9,K=function(r){return{bomSkipped:!1,bufBytesStart:0,castField:r.cast_function,commenting:!1,error:void 0,enabled:r.from_line===1,escaping:!1,escapeIsQuote:l.isBuffer(r.escape)&&l.isBuffer(r.quote)&&l.compare(r.escape,r.quote)===0,expectedRecordLength:Array.isArray(r.columns)?r.columns.length:void 0,field:new M(20),firstLineToHeaders:r.cast_first_line_to_header,needMoreDataSize:Math.max(r.comment!==null?r.comment.length:0,...r.delimiter.map(e=>e.length),r.quote!==null?r.quote.length:0),previousBuf:void 0,quoting:!1,stop:!1,rawBuffer:new M(100),record:[],recordHasError:!1,record_length:0,recordDelimiterMaxLength:r.record_delimiter.length===0?0:Math.max(...r.record_delimiter.map(e=>e.length)),trimChars:[l.from(" ",r.encoding)[0],l.from(" ",r.encoding)[0]],wasQuoting:!1,wasRowDelimiter:!1,timchars:[l.from(l.from([H],"utf8").toString(),r.encoding),l.from(l.from([Y],"utf8").toString(),r.encoding),l.from(l.from([G],"utf8").toString(),r.encoding),l.from(l.from([Z],"utf8").toString(),r.encoding),l.from(l.from([X],"utf8").toString(),r.encoding)]}},W=function(r){return r.replace(/([A-Z])/g,function(e,a){return"_"+a.toLowerCase()})},k=function(r){const e={};for(const t in r)e[W(t)]=r[t];if(e.encoding===void 0||e.encoding===!0)e.encoding="utf8";else if(e.encoding===null||e.encoding===!1)e.encoding=null;else if(typeof e.encoding!="string"&&e.encoding!==null)throw new _("CSV_INVALID_OPTION_ENCODING",["Invalid option encoding:","encoding must be a string or null to return a buffer,",`got ${JSON.stringify(e.encoding)}`],e);if(e.bom===void 0||e.bom===null||e.bom===!1)e.bom=!1;else if(e.bom!==!0)throw new _("CSV_INVALID_OPTION_BOM",["Invalid option bom:","bom must be true,",`got ${JSON.stringify(e.bom)}`],e);if(e.cast_function=null,e.cast===void 0||e.cast===null||e.cast===!1||e.cast==="")e.cast=void 0;else if(typeof e.cast=="function")e.cast_function=e.cast,e.cast=!0;else if(e.cast!==!0)throw new _("CSV_INVALID_OPTION_CAST",["Invalid option cast:","cast must be true or a function,",`got ${JSON.stringify(e.cast)}`],e);if(e.cast_date===void 0||e.cast_date===null||e.cast_date===!1||e.cast_date==="")e.cast_date=!1;else if(e.cast_date===!0)e.cast_date=function(t){const i=Date.parse(t);return isNaN(i)?t:new Date(i)};else if(typeof e.cast_date!="function")throw new _("CSV_INVALID_OPTION_CAST_DATE",["Invalid option cast_date:","cast_date must be true or a function,",`got ${JSON.stringify(e.cast_date)}`],e);if(e.cast_first_line_to_header=null,e.columns===!0)e.cast_first_line_to_header=void 0;else if(typeof e.columns=="function")e.cast_first_line_to_header=e.columns,e.columns=!0;else if(Array.isArray(e.columns))e.columns=j(e.columns);else if(e.columns===void 0||e.columns===null||e.columns===!1)e.columns=!1;else throw new _("CSV_INVALID_OPTION_COLUMNS",["Invalid option columns:","expect an array, a function or true,",`got ${JSON.stringify(e.columns)}`],e);if(e.group_columns_by_name===void 0||e.group_columns_by_name===null||e.group_columns_by_name===!1)e.group_columns_by_name=!1;else{if(e.group_columns_by_name!==!0)throw new _("CSV_INVALID_OPTION_GROUP_COLUMNS_BY_NAME",["Invalid option group_columns_by_name:","expect an boolean,",`got ${JSON.stringify(e.group_columns_by_name)}`],e);if(e.columns===!1)throw new _("CSV_INVALID_OPTION_GROUP_COLUMNS_BY_NAME",["Invalid option group_columns_by_name:","the `columns` mode must be activated."],e)}if(e.comment===void 0||e.comment===null||e.comment===!1||e.comment==="")e.comment=null;else if(typeof e.comment=="string"&&(e.comment=l.from(e.comment,e.encoding)),!l.isBuffer(e.comment))throw new _("CSV_INVALID_OPTION_COMMENT",["Invalid option comment:","comment must be a buffer or a string,",`got ${JSON.stringify(e.comment)}`],e);if(e.comment_no_infix===void 0||e.comment_no_infix===null||e.comment_no_infix===!1)e.comment_no_infix=!1;else if(e.comment_no_infix!==!0)throw new _("CSV_INVALID_OPTION_COMMENT",["Invalid option comment_no_infix:","value must be a boolean,",`got ${JSON.stringify(e.comment_no_infix)}`],e);const a=JSON.stringify(e.delimiter);if(Array.isArray(e.delimiter)||(e.delimiter=[e.delimiter]),e.delimiter.length===0)throw new _("CSV_INVALID_OPTION_DELIMITER",["Invalid option delimiter:","delimiter must be a non empty string or buffer or array of string|buffer,",`got ${a}`],e);if(e.delimiter=e.delimiter.map(function(t){if(t==null||t===!1)return l.from(",",e.encoding);if(typeof t=="string"&&(t=l.from(t,e.encoding)),!l.isBuffer(t)||t.length===0)throw new _("CSV_INVALID_OPTION_DELIMITER",["Invalid option delimiter:","delimiter must be a non empty string or buffer or array of string|buffer,",`got ${a}`],e);return t}),e.escape===void 0||e.escape===!0?e.escape=l.from('"',e.encoding):typeof e.escape=="string"?e.escape=l.from(e.escape,e.encoding):(e.escape===null||e.escape===!1)&&(e.escape=null),e.escape!==null&&!l.isBuffer(e.escape))throw new Error(`Invalid Option: escape must be a buffer, a string or a boolean, got ${JSON.stringify(e.escape)}`);if(e.from===void 0||e.from===null)e.from=1;else if(typeof e.from=="string"&&/\d+/.test(e.from)&&(e.from=parseInt(e.from)),Number.isInteger(e.from)){if(e.from<0)throw new Error(`Invalid Option: from must be a positive integer, got ${JSON.stringify(r.from)}`)}else throw new Error(`Invalid Option: from must be an integer, got ${JSON.stringify(e.from)}`);if(e.from_line===void 0||e.from_line===null)e.from_line=1;else if(typeof e.from_line=="string"&&/\d+/.test(e.from_line)&&(e.from_line=parseInt(e.from_line)),Number.isInteger(e.from_line)){if(e.from_line<=0)throw new Error(`Invalid Option: from_line must be a positive integer greater than 0, got ${JSON.stringify(r.from_line)}`)}else throw new Error(`Invalid Option: from_line must be an integer, got ${JSON.stringify(r.from_line)}`);if(e.ignore_last_delimiters===void 0||e.ignore_last_delimiters===null)e.ignore_last_delimiters=!1;else if(typeof e.ignore_last_delimiters=="number")e.ignore_last_delimiters=Math.floor(e.ignore_last_delimiters),e.ignore_last_delimiters===0&&(e.ignore_last_delimiters=!1);else if(typeof e.ignore_last_delimiters!="boolean")throw new _("CSV_INVALID_OPTION_IGNORE_LAST_DELIMITERS",["Invalid option `ignore_last_delimiters`:","the value must be a boolean value or an integer,",`got ${JSON.stringify(e.ignore_last_delimiters)}`],e);if(e.ignore_last_delimiters===!0&&e.columns===!1)throw new _("CSV_IGNORE_LAST_DELIMITERS_REQUIRES_COLUMNS",["The option `ignore_last_delimiters`","requires the activation of the `columns` option"],e);if(e.info===void 0||e.info===null||e.info===!1)e.info=!1;else if(e.info!==!0)throw new Error(`Invalid Option: info must be true, got ${JSON.stringify(e.info)}`);if(e.max_record_size===void 0||e.max_record_size===null||e.max_record_size===!1)e.max_record_size=0;else if(!(Number.isInteger(e.max_record_size)&&e.max_record_size>=0))if(typeof e.max_record_size=="string"&&/\d+/.test(e.max_record_size))e.max_record_size=parseInt(e.max_record_size);else throw new Error(`Invalid Option: max_record_size must be a positive integer, got ${JSON.stringify(e.max_record_size)}`);if(e.objname===void 0||e.objname===null||e.objname===!1)e.objname=void 0;else if(l.isBuffer(e.objname)){if(e.objname.length===0)throw new Error("Invalid Option: objname must be a non empty buffer");e.encoding===null||(e.objname=e.objname.toString(e.encoding))}else if(typeof e.objname=="string"){if(e.objname.length===0)throw new Error("Invalid Option: objname must be a non empty string")}else if(typeof e.objname!="number")throw new Error(`Invalid Option: objname must be a string or a buffer, got ${e.objname}`);if(e.objname!==void 0){if(typeof e.objname=="number"){if(e.columns!==!1)throw Error("Invalid Option: objname index cannot be combined with columns or be defined as a field")}else if(e.columns===!1)throw Error("Invalid Option: objname field must be combined with columns or be defined as an index")}if(e.on_record===void 0||e.on_record===null)e.on_record=void 0;else if(typeof e.on_record!="function")throw new _("CSV_INVALID_OPTION_ON_RECORD",["Invalid option `on_record`:","expect a function,",`got ${JSON.stringify(e.on_record)}`],e);if(e.on_skip!==void 0&&e.on_skip!==null&&typeof e.on_skip!="function")throw new Error(`Invalid Option: on_skip must be a function, got ${JSON.stringify(e.on_skip)}`);if(e.quote===null||e.quote===!1||e.quote==="")e.quote=null;else if(e.quote===void 0||e.quote===!0?e.quote=l.from('"',e.encoding):typeof e.quote=="string"&&(e.quote=l.from(e.quote,e.encoding)),!l.isBuffer(e.quote))throw new Error(`Invalid Option: quote must be a buffer or a string, got ${JSON.stringify(e.quote)}`);if(e.raw===void 0||e.raw===null||e.raw===!1)e.raw=!1;else if(e.raw!==!0)throw new Error(`Invalid Option: raw must be true, got ${JSON.stringify(e.raw)}`);if(e.record_delimiter===void 0)e.record_delimiter=[];else if(typeof e.record_delimiter=="string"||l.isBuffer(e.record_delimiter)){if(e.record_delimiter.length===0)throw new _("CSV_INVALID_OPTION_RECORD_DELIMITER",["Invalid option `record_delimiter`:","value must be a non empty string or buffer,",`got ${JSON.stringify(e.record_delimiter)}`],e);e.record_delimiter=[e.record_delimiter]}else if(!Array.isArray(e.record_delimiter))throw new _("CSV_INVALID_OPTION_RECORD_DELIMITER",["Invalid option `record_delimiter`:","value must be a string, a buffer or array of string|buffer,",`got ${JSON.stringify(e.record_delimiter)}`],e);if(e.record_delimiter=e.record_delimiter.map(function(t,i){if(typeof t!="string"&&!l.isBuffer(t))throw new _("CSV_INVALID_OPTION_RECORD_DELIMITER",["Invalid option `record_delimiter`:","value must be a string, a buffer or array of string|buffer",`at index ${i},`,`got ${JSON.stringify(t)}`],e);if(t.length===0)throw new _("CSV_INVALID_OPTION_RECORD_DELIMITER",["Invalid option `record_delimiter`:","value must be a non empty string or buffer",`at index ${i},`,`got ${JSON.stringify(t)}`],e);return typeof t=="string"&&(t=l.from(t,e.encoding)),t}),typeof e.relax_column_count!="boolean")if(e.relax_column_count===void 0||e.relax_column_count===null)e.relax_column_count=!1;else throw new Error(`Invalid Option: relax_column_count must be a boolean, got ${JSON.stringify(e.relax_column_count)}`);if(typeof e.relax_column_count_less!="boolean")if(e.relax_column_count_less===void 0||e.relax_column_count_less===null)e.relax_column_count_less=!1;else throw new Error(`Invalid Option: relax_column_count_less must be a boolean, got ${JSON.stringify(e.relax_column_count_less)}`);if(typeof e.relax_column_count_more!="boolean")if(e.relax_column_count_more===void 0||e.relax_column_count_more===null)e.relax_column_count_more=!1;else throw new Error(`Invalid Option: relax_column_count_more must be a boolean, got ${JSON.stringify(e.relax_column_count_more)}`);if(typeof e.relax_quotes!="boolean")if(e.relax_quotes===void 0||e.relax_quotes===null)e.relax_quotes=!1;else throw new Error(`Invalid Option: relax_quotes must be a boolean, got ${JSON.stringify(e.relax_quotes)}`);if(typeof e.skip_empty_lines!="boolean")if(e.skip_empty_lines===void 0||e.skip_empty_lines===null)e.skip_empty_lines=!1;else throw new Error(`Invalid Option: skip_empty_lines must be a boolean, got ${JSON.stringify(e.skip_empty_lines)}`);if(typeof e.skip_records_with_empty_values!="boolean")if(e.skip_records_with_empty_values===void 0||e.skip_records_with_empty_values===null)e.skip_records_with_empty_values=!1;else throw new Error(`Invalid Option: skip_records_with_empty_values must be a boolean, got ${JSON.stringify(e.skip_records_with_empty_values)}`);if(typeof e.skip_records_with_error!="boolean")if(e.skip_records_with_error===void 0||e.skip_records_with_error===null)e.skip_records_with_error=!1;else throw new Error(`Invalid Option: skip_records_with_error must be a boolean, got ${JSON.stringify(e.skip_records_with_error)}`);if(e.rtrim===void 0||e.rtrim===null||e.rtrim===!1)e.rtrim=!1;else if(e.rtrim!==!0)throw new Error(`Invalid Option: rtrim must be a boolean, got ${JSON.stringify(e.rtrim)}`);if(e.ltrim===void 0||e.ltrim===null||e.ltrim===!1)e.ltrim=!1;else if(e.ltrim!==!0)throw new Error(`Invalid Option: ltrim must be a boolean, got ${JSON.stringify(e.ltrim)}`);if(e.trim===void 0||e.trim===null||e.trim===!1)e.trim=!1;else if(e.trim!==!0)throw new Error(`Invalid Option: trim must be a boolean, got ${JSON.stringify(e.trim)}`);if(e.trim===!0&&r.ltrim!==!1?e.ltrim=!0:e.ltrim!==!0&&(e.ltrim=!1),e.trim===!0&&r.rtrim!==!1?e.rtrim=!0:e.rtrim!==!0&&(e.rtrim=!1),e.to===void 0||e.to===null)e.to=-1;else if(typeof e.to=="string"&&/\d+/.test(e.to)&&(e.to=parseInt(e.to)),Number.isInteger(e.to)){if(e.to<=0)throw new Error(`Invalid Option: to must be a positive integer greater than 0, got ${JSON.stringify(r.to)}`)}else throw new Error(`Invalid Option: to must be an integer, got ${JSON.stringify(r.to)}`);if(e.to_line===void 0||e.to_line===null)e.to_line=-1;else if(typeof e.to_line=="string"&&/\d+/.test(e.to_line)&&(e.to_line=parseInt(e.to_line)),Number.isInteger(e.to_line)){if(e.to_line<=0)throw new Error(`Invalid Option: to_line must be a positive integer greater than 0, got ${JSON.stringify(r.to_line)}`)}else throw new Error(`Invalid Option: to_line must be an integer, got ${JSON.stringify(r.to_line)}`);return e},B=function(r){return r.every(e=>e==null||e.toString&&e.toString().trim()==="")},ee=13,te=10,L={utf8:l.from([239,187,191]),utf16le:l.from([255,254])},ie=function(r={}){const e={bytes:0,comment_lines:0,empty_lines:0,invalid_field_length:0,lines:1,records:0},a=k(r);return{info:e,original_options:r,options:a,state:K(a),__needMoreData:function(t,i,s){if(s)return!1;const{encoding:o,escape:n,quote:u}=this.options,{quoting:c,needMoreDataSize:p,recordDelimiterMaxLength:b}=this.state,N=i-t-1,D=Math.max(p,b===0?l.from(`\r
|
|
2
2
|
`,o).length:b,c?(n===null?0:n.length)+u.length:0,c?u.length+b:0);return N<D},parse:function(t,i,s,o){const{bom:n,comment_no_infix:u,encoding:c,from_line:p,ltrim:b,max_record_size:N,raw:D,relax_quotes:$,rtrim:w,skip_empty_lines:C,to:I,to_line:h}=this.options;let{comment:d,escape:O,quote:S,record_delimiter:V}=this.options;const{bomSkipped:z,previousBuf:T,rawBuffer:F,escapeIsQuote:Q}=this.state;let m;if(T===void 0)if(t===void 0){o();return}else m=t;else T!==void 0&&t===void 0?m=T:m=l.concat([T,t]);if(z===!1)if(n===!1)this.state.bomSkipped=!0;else if(m.length<3){if(i===!1){this.state.previousBuf=m;return}}else{for(const g in L)if(L[g].compare(m,0,L[g].length)===0){const x=L[g].length;this.state.bufBytesStart+=x,m=m.slice(x),this.options=k({...this.original_options,encoding:g}),{comment:d,escape:O,quote:S}=this.options;break}this.state.bomSkipped=!0}const q=m.length;let f;for(f=0;f<q&&!this.__needMoreData(f,q,i);f++){if(this.state.wasRowDelimiter===!0&&(this.info.lines++,this.state.wasRowDelimiter=!1),h!==-1&&this.info.lines>h){this.state.stop=!0,o();return}this.state.quoting===!1&&V.length===0&&this.__autoDiscoverRecordDelimiter(m,f)&&(V=this.options.record_delimiter);const g=m[f];if(D===!0&&F.append(g),(g===ee||g===te)&&this.state.wasRowDelimiter===!1&&(this.state.wasRowDelimiter=!0),this.state.escaping===!0)this.state.escaping=!1;else{if(O!==null&&this.state.quoting===!0&&this.__isEscape(m,f,g)&&f+O.length<q)if(Q){if(this.__isQuote(m,f+O.length)){this.state.escaping=!0,f+=O.length-1;continue}}else{this.state.escaping=!0,f+=O.length-1;continue}if(this.state.commenting===!1&&this.__isQuote(m,f))if(this.state.quoting===!0){const y=m[f+S.length],R=w&&this.__isCharTrimable(m,f+S.length),E=d!==null&&this.__compareBytes(d,m,f+S.length,y),v=this.__isDelimiter(m,f+S.length,y),A=V.length===0?this.__autoDiscoverRecordDelimiter(m,f+S.length):this.__isRecordDelimiter(y,m,f+S.length);if(O!==null&&this.__isEscape(m,f,g)&&this.__isQuote(m,f+O.length))f+=O.length-1;else if(!y||v||A||E||R){this.state.quoting=!1,this.state.wasQuoting=!0,f+=S.length-1;continue}else if($===!1){const J=this.__error(new _("CSV_INVALID_CLOSING_QUOTE",["Invalid Closing Quote:",`got "${String.fromCharCode(y)}"`,`at line ${this.info.lines}`,"instead of delimiter, record delimiter, trimable character","(if activated) or comment"],this.options,this.__infoField()));if(J!==void 0)return J}else this.state.quoting=!1,this.state.wasQuoting=!0,this.state.field.prepend(S),f+=S.length-1}else if(this.state.field.length!==0){if($===!1){const y=this.__infoField(),R=Object.keys(L).map(v=>L[v].equals(this.state.field.toString())?v:!1).filter(Boolean)[0],E=this.__error(new _("INVALID_OPENING_QUOTE",["Invalid Opening Quote:",`a quote is found on field ${JSON.stringify(y.column)} at line ${y.lines}, value is ${JSON.stringify(this.state.field.toString(c))}`,R?`(${R} bom)`:void 0],this.options,y,{field:this.state.field}));if(E!==void 0)return E}}else{this.state.quoting=!0,f+=S.length-1;continue}if(this.state.quoting===!1){const y=this.__isRecordDelimiter(g,m,f);if(y!==0){if(this.state.commenting&&this.state.wasQuoting===!1&&this.state.record.length===0&&this.state.field.length===0)this.info.comment_lines++;else{if(this.state.enabled===!1&&this.info.lines+(this.state.wasRowDelimiter===!0?1:0)>=p){this.state.enabled=!0,this.__resetField(),this.__resetRecord(),f+=y-1;continue}if(C===!0&&this.state.wasQuoting===!1&&this.state.record.length===0&&this.state.field.length===0){this.info.empty_lines++,f+=y-1;continue}this.info.bytes=this.state.bufBytesStart+f;const v=this.__onField();if(v!==void 0)return v;this.info.bytes=this.state.bufBytesStart+f+y;const A=this.__onRecord(s);if(A!==void 0)return A;if(I!==-1&&this.info.records>=I){this.state.stop=!0,o();return}}this.state.commenting=!1,f+=y-1;continue}if(this.state.commenting)continue;if(d!==null&&(u===!1||this.state.record.length===0&&this.state.field.length===0)&&this.__compareBytes(d,m,f,g)!==0){this.state.commenting=!0;continue}const R=this.__isDelimiter(m,f,g);if(R!==0){this.info.bytes=this.state.bufBytesStart+f;const E=this.__onField();if(E!==void 0)return E;f+=R-1;continue}}}if(this.state.commenting===!1&&N!==0&&this.state.record_length+this.state.field.length>N)return this.__error(new _("CSV_MAX_RECORD_SIZE",["Max Record Size:","record exceed the maximum number of tolerated bytes",`of ${N}`,`at line ${this.info.lines}`],this.options,this.__infoField()));const x=b===!1||this.state.quoting===!0||this.state.field.length!==0||!this.__isCharTrimable(m,f),P=w===!1||this.state.wasQuoting===!1;if(x===!0&&P===!0)this.state.field.append(g);else{if(w===!0&&!this.__isCharTrimable(m,f))return this.__error(new _("CSV_NON_TRIMABLE_CHAR_AFTER_CLOSING_QUOTE",["Invalid Closing Quote:","found non trimable byte after quote",`at line ${this.info.lines}`],this.options,this.__infoField()));x===!1&&(f+=this.__isCharTrimable(m,f)-1);continue}}if(i===!0)if(this.state.quoting===!0){const g=this.__error(new _("CSV_QUOTE_NOT_CLOSED",["Quote Not Closed:",`the parsing is finished with an opening quote at line ${this.info.lines}`],this.options,this.__infoField()));if(g!==void 0)return g}else if(this.state.wasQuoting===!0||this.state.record.length!==0||this.state.field.length!==0){this.info.bytes=this.state.bufBytesStart+f;const g=this.__onField();if(g!==void 0)return g;const x=this.__onRecord(s);if(x!==void 0)return x}else this.state.wasRowDelimiter===!0?this.info.empty_lines++:this.state.commenting===!0&&this.info.comment_lines++;else this.state.bufBytesStart+=f,this.state.previousBuf=m.slice(f);this.state.wasRowDelimiter===!0&&(this.info.lines++,this.state.wasRowDelimiter=!1)},__onRecord:function(t){const{columns:i,group_columns_by_name:s,encoding:o,info:n,from:u,relax_column_count:c,relax_column_count_less:p,relax_column_count_more:b,raw:N,skip_records_with_empty_values:D}=this.options,{enabled:$,record:w}=this.state;if($===!1)return this.__resetRecord();const C=w.length;if(i===!0){if(D===!0&&B(w)){this.__resetRecord();return}return this.__firstLineToColumns(w)}if(i===!1&&this.info.records===0&&(this.state.expectedRecordLength=C),C!==this.state.expectedRecordLength){const I=i===!1?new _("CSV_RECORD_INCONSISTENT_FIELDS_LENGTH",["Invalid Record Length:",`expect ${this.state.expectedRecordLength},`,`got ${C} on line ${this.info.lines}`],this.options,this.__infoField(),{record:w}):new _("CSV_RECORD_INCONSISTENT_COLUMNS",["Invalid Record Length:",`columns length is ${i.length},`,`got ${C} on line ${this.info.lines}`],this.options,this.__infoField(),{record:w});if(c===!0||p===!0&&C<this.state.expectedRecordLength||b===!0&&C>this.state.expectedRecordLength)this.info.invalid_field_length++,this.state.error=I;else{const h=this.__error(I);if(h)return h}}if(D===!0&&B(w)){this.__resetRecord();return}if(this.state.recordHasError===!0){this.__resetRecord(),this.state.recordHasError=!1;return}if(this.info.records++,u===1||this.info.records>=u){const{objname:I}=this.options;if(i!==!1){const h={};for(let d=0,O=w.length;d<O;d++)i[d]===void 0||i[d].disabled||(s===!0&&h[i[d].name]!==void 0?Array.isArray(h[i[d].name])?h[i[d].name]=h[i[d].name].concat(w[d]):h[i[d].name]=[h[i[d].name],w[d]]:h[i[d].name]=w[d]);if(N===!0||n===!0){const d=Object.assign({record:h},N===!0?{raw:this.state.rawBuffer.toString(o)}:{},n===!0?{info:this.__infoRecord()}:{}),O=this.__push(I===void 0?d:[h[I],d],t);if(O)return O}else{const d=this.__push(I===void 0?h:[h[I],h],t);if(d)return d}}else if(N===!0||n===!0){const h=Object.assign({record:w},N===!0?{raw:this.state.rawBuffer.toString(o)}:{},n===!0?{info:this.__infoRecord()}:{}),d=this.__push(I===void 0?h:[w[I],h],t);if(d)return d}else{const h=this.__push(I===void 0?w:[w[I],w],t);if(h)return h}}this.__resetRecord()},__firstLineToColumns:function(t){const{firstLineToHeaders:i}=this.state;try{const s=i===void 0?t:i.call(null,t);if(!Array.isArray(s))return this.__error(new _("CSV_INVALID_COLUMN_MAPPING",["Invalid Column Mapping:","expect an array from column function,",`got ${JSON.stringify(s)}`],this.options,this.__infoField(),{headers:s}));const o=j(s);this.state.expectedRecordLength=o.length,this.options.columns=o,this.__resetRecord();return}catch(s){return s}},__resetRecord:function(){this.options.raw===!0&&this.state.rawBuffer.reset(),this.state.error=void 0,this.state.record=[],this.state.record_length=0},__onField:function(){const{cast:t,encoding:i,rtrim:s,max_record_size:o}=this.options,{enabled:n,wasQuoting:u}=this.state;if(n===!1)return this.__resetField();let c=this.state.field.toString(i);if(s===!0&&u===!1&&(c=c.trimRight()),t===!0){const[p,b]=this.__cast(c);if(p!==void 0)return p;c=b}this.state.record.push(c),o!==0&&typeof c=="string"&&(this.state.record_length+=c.length),this.__resetField()},__resetField:function(){this.state.field.reset(),this.state.wasQuoting=!1},__push:function(t,i){const{on_record:s}=this.options;if(s!==void 0){const o=this.__infoRecord();try{t=s.call(null,t,o)}catch(n){return n}if(t==null)return}i(t)},__cast:function(t){const{columns:i,relax_column_count:s}=this.options;if(Array.isArray(i)===!0&&s&&this.options.columns.length<=this.state.record.length)return[void 0,void 0];if(this.state.castField!==null)try{const n=this.__infoField();return[void 0,this.state.castField.call(null,t,n)]}catch(n){return[n]}if(this.__isFloat(t))return[void 0,parseFloat(t)];if(this.options.cast_date!==!1){const n=this.__infoField();return[void 0,this.options.cast_date.call(null,t,n)]}return[void 0,t]},__isCharTrimable:function(t,i){return((o,n)=>{const{timchars:u}=this.state;e:for(let c=0;c<u.length;c++){const p=u[c];for(let b=0;b<p.length;b++)if(p[b]!==o[n+b])continue e;return p.length}return 0})(t,i)},__isFloat:function(t){return t-parseFloat(t)+1>=0},__compareBytes:function(t,i,s,o){if(t[0]!==o)return 0;const n=t.length;for(let u=1;u<n;u++)if(t[u]!==i[s+u])return 0;return n},__isDelimiter:function(t,i,s){const{delimiter:o,ignore_last_delimiters:n}=this.options;if(n===!0&&this.state.record.length===this.options.columns.length-1)return 0;if(n!==!1&&typeof n=="number"&&this.state.record.length===n-1)return 0;e:for(let u=0;u<o.length;u++){const c=o[u];if(c[0]===s){for(let p=1;p<c.length;p++)if(c[p]!==t[i+p])continue e;return c.length}}return 0},__isRecordDelimiter:function(t,i,s){const{record_delimiter:o}=this.options,n=o.length;e:for(let u=0;u<n;u++){const c=o[u],p=c.length;if(c[0]===t){for(let b=1;b<p;b++)if(c[b]!==i[s+b])continue e;return c.length}}return 0},__isEscape:function(t,i,s){const{escape:o}=this.options;if(o===null)return!1;const n=o.length;if(o[0]===s){for(let u=0;u<n;u++)if(o[u]!==t[i+u])return!1;return!0}return!1},__isQuote:function(t,i){const{quote:s}=this.options;if(s===null)return!1;const o=s.length;for(let n=0;n<o;n++)if(s[n]!==t[i+n])return!1;return!0},__autoDiscoverRecordDelimiter:function(t,i){const{encoding:s}=this.options,o=[l.from(`\r
|
|
3
3
|
`,s),l.from(`
|
|
4
4
|
`,s),l.from("\r",s)];e:for(let n=0;n<o.length;n++){const u=o[n].length;for(let c=0;c<u;c++)if(o[n][c]!==t[i+c])continue e;return this.options.record_delimiter.push(o[n]),this.state.recordDelimiterMaxLength=o[n].length,o[n].length}return 0},__error:function(t){const{encoding:i,raw:s,skip_records_with_error:o}=this.options,n=typeof t=="string"?new Error(t):t;if(o){this.state.recordHasError=!0,this.options.on_skip!==void 0&&this.options.on_skip(n,s?this.state.rawBuffer.toString(i):void 0);return}else return n},__infoDataSet:function(){return{...this.info,columns:this.options.columns}},__infoRecord:function(){const{columns:t,raw:i,encoding:s}=this.options;return{...this.__infoDataSet(),error:this.state.error,header:t===!0,index:this.state.record.length,raw:i?this.state.rawBuffer.toString(s):void 0}},__infoField:function(){const{columns:t}=this.options,i=Array.isArray(t);return{...this.__infoRecord(),column:i===!0?t.length>this.state.record.length?t[this.state.record.length].name:null:this.state.record.length,quoting:this.state.wasQuoting}}}},re=function(r,e={}){typeof r=="string"&&(r=l.from(r));const a=e&&e.objname?{}:[],t=ie(e),i=u=>{t.options.objname===void 0?a.push(u):a[u[0]]=u[1]},s=()=>{},o=t.parse(r,!1,i,s);if(o!==void 0)throw o;const n=t.parse(void 0,!0,i,s);if(n!==void 0)throw n;return a};export{_ as CsvError,re as parse};
|
package/dist/src/app/index.html
CHANGED
|
@@ -7,8 +7,8 @@
|
|
|
7
7
|
<title>promptfoo</title>
|
|
8
8
|
<meta name="description" content="LLM testing and evaluation" />
|
|
9
9
|
<meta property="og:image" content="https://www.promptfoo.dev/img/thumbnail.png" />
|
|
10
|
-
<script type="module" crossorigin src="./assets/index-
|
|
11
|
-
<link rel="stylesheet" crossorigin href="./assets/index-
|
|
10
|
+
<script type="module" crossorigin src="./assets/index-CQmOdU-e.js"></script>
|
|
11
|
+
<link rel="stylesheet" crossorigin href="./assets/index-V4sLv2Tk.css">
|
|
12
12
|
</head>
|
|
13
13
|
<body>
|
|
14
14
|
<div id="root"></div>
|
package/dist/src/assertions.js
CHANGED
|
@@ -325,7 +325,7 @@ async function runAssertion({ prompt, provider, assertion, test, latencyMs, prov
|
|
|
325
325
|
score: pass ? 1 : 0,
|
|
326
326
|
reason: pass
|
|
327
327
|
? 'Assertion passed'
|
|
328
|
-
: `Expected output "${
|
|
328
|
+
: `Expected output "${outputString}" to ${inverse ? 'not ' : ''}equal "${renderedValue}"`,
|
|
329
329
|
assertion,
|
|
330
330
|
};
|
|
331
331
|
}
|