From 99bf9f173e5e748dec59fb37450142edd7fc4ec5 Mon Sep 17 00:00:00 2001 From: Thomas Durieux <5577568+tdurieux@users.noreply.github.com> Date: Sat, 14 Nov 2026 13:21:03 +0000 Subject: [PATCH] feat(admin): add email activity and investigation workflow --- public/asset-manifest.json | 4 +- public/css/all.min.css | 2 +- public/css/style.css | 94 ++++++++++--------- public/partials/admin/emails.htm | 73 ++++++++------- public/script/admin.js | 148 +++++++++++++++++++++++++----- public/script/vendor.min.js | 94 +++++++++---------- scripts/dev-mock.js | 63 ++++++++++--- src/server/routes/admin-emails.ts | 66 ++++++++++++- test/email-admin-ui.test.js | 118 +++++++++++++++++++++++- test/email-history.test.js | 78 +++++++++++++++- 10 files changed, 571 insertions(+), 169 deletions(-) diff --git a/public/asset-manifest.json b/public/asset-manifest.json index fd259de..c5a61f8 100644 --- a/public/asset-manifest.json +++ b/public/asset-manifest.json @@ -1,8 +1,8 @@ { "core.min.js": "core.d23af1c652.min.js", - "vendor.min.js": "vendor.6976ec5aeb.min.js", + "vendor.min.js": "vendor.8b4208bcea.min.js", "mermaid.min.js": "mermaid.a7356d5ed1.min.js", - "all.min.css": "all.c7881c7621.min.css", + "all.min.css": "all.9ae101d36f.min.css", "markdown.min.js": "markdown.6c8dfb7b1d.min.js", "pdf.min.js": "pdf.4d9cc6ff49.min.js", "notebook.min.js": "notebook.c3144c18ae.min.js", diff --git a/public/css/all.min.css b/public/css/all.min.css index b4af6b7..4925b6a 100644 --- a/public/css/all.min.css +++ b/public/css/all.min.css @@ -10,4 +10,4 @@ @container explorer-file (max-width: 700px) { .reviewer-preview .file-card-head .file-card-meta, .reviewer-preview .file-card-head .symbols { display: none !important; } } -.reviewer-preview .rp-main{min-width:0;min-height:0;display:flex;flex-direction:column;overflow:hidden}.reviewer-preview .rp-document{flex:1 1 auto;min-height:0;min-width:0;overflow:auto;scrollbar-width:thin;position:relative}.reviewer-preview button.rp-count{background:0 0;border:0;padding:0;font:inherit;cursor:pointer;text-decoration:underline;text-decoration-color:transparent;text-underline-offset:3px}.reviewer-preview button.rp-count:hover{text-decoration-color:currentColor}@media (max-width:767px){.reviewer-preview .file-card-head .rp-preserved-tag{display:none}}.billing-page{--bl-subscription:#008C7E;--bl-repository:#D0652A;--bl-conference:#6250D6}.dark-mode .billing-page{--bl-subscription:#16A091;--bl-repository:#D95926;--bl-conference:#9085E9}.billing-page .bl-subscription{background:var(--bl-subscription)!important}.billing-page .bl-repository{background:var(--bl-repository)!important}.billing-page .bl-conference{background:var(--bl-conference)!important}.billing-page .bl-toolbar{display:flex;align-items:center;justify-content:space-between;flex-wrap:wrap;gap:8px 16px;margin:4px 0 0}.billing-page .bl-basis{margin:0;font-size:12px;color:var(--ink-muted)}.billing-page .bl-message{display:flex;align-items:center;gap:8px;margin:14px 0 0;padding:10px 14px;border:1px solid var(--border-color);border-radius:var(--radius-control,8px);font-size:13px;color:var(--color);background:var(--paper-card)}.billing-page .bl-message .ui-icon{width:16px;height:16px;flex:none;color:var(--ink-muted)}.billing-page .bl-message.ov-performance-warning{border-color:color-mix(in srgb,var(--status-progress) 45%,var(--border-color));background:color-mix(in srgb,var(--status-progress) 8%,var(--paper-card))}.billing-page .bl-message.ov-performance-warning .ui-icon{color:var(--status-progress)}.billing-page .bl-message .btn{margin-left:auto}.overview-page .bl-kpi-row{grid-template-columns:repeat(6,minmax(0,1fr));margin:16px 0 16px}.overview-page .bl-kpi-row .ov-kpi-card{min-width:0;padding:16px 18px}.overview-page .bl-kpi-row .ov-kpi-label{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.overview-page .bl-kpi-row .ov-kpi-sub{white-space:normal;overflow-wrap:anywhere;line-height:1.4}.overview-page .bl-kpi-row .ov-kpi-value{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.overview-page .bl-kpi-row .bl-muted-value{color:var(--ink-muted);font-size:20px;line-height:28px}.overview-page .bl-kpi-row.is-loading .ov-kpi-card{opacity:.6}.billing-page .bl-skeleton-value{display:block;width:50%;height:28px;margin:4px 0;border-radius:6px}@media (max-width:1279px){.overview-page .bl-kpi-row{grid-template-columns:repeat(3,minmax(0,1fr))!important}}@media (max-width:767px){.overview-page .bl-kpi-row{grid-template-columns:repeat(2,minmax(0,1fr))!important}}.billing-page .bl-health{display:flex;align-items:center;flex-wrap:wrap;gap:6px 20px;padding:10px 16px;margin:0 0 16px;border:1px solid var(--border-color);border-radius:var(--radius-control,8px);background:var(--paper-card);font-size:13px;font-variant-numeric:tabular-nums}.billing-page .bl-health-title{display:inline-flex;align-items:center;gap:8px;font-weight:600}.billing-page .bl-health-title .ov-svc-dot{width:8px;height:8px;margin:0;border-radius:50%}.billing-page .bl-dot-bad{background:var(--st-bad,#b42318)}.billing-page .bl-health-item .k{color:var(--ink-muted);margin-right:2px}.billing-page .bl-health-item.is-bad{color:var(--st-bad,#b42318);font-weight:600}.billing-page .bl-health-item.is-warn{color:#946519;font-weight:600}.dark-mode .billing-page .bl-health-item.is-warn{color:var(--status-progress)}.dark-mode .billing-page .bl-health-item.is-bad{color:#f08a82}.billing-page .bl-health-error{min-width:0;max-width:100%;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.billing-page .bl-health-error code{font-size:12px;color:inherit;background:var(--paper-bg-alt);padding:1px 5px;border-radius:4px}.billing-page .bl-chart-card{margin-bottom:16px}.billing-page .bl-swatch{display:inline-block;width:8px;height:8px;border-radius:2px;flex:none}.billing-page .bl-bars{position:relative;gap:3px}.billing-page .bl-bars.is-dense{gap:1px}.billing-page .bl-col{min-width:0}.billing-page .bl-stack{display:flex;flex-direction:column-reverse;width:100%;gap:1px;border-radius:2px 2px 0 0;overflow:hidden}.billing-page .bl-stack>i{display:block;min-height:2px;flex-basis:0}.billing-page .bl-col:hover .bl-stack{filter:brightness(1.08)}.billing-page .bl-col.is-zero .bl-stack{height:1px!important;background:var(--border-color)}.billing-page .bl-empty{margin:8px 0 4px;padding:32px 0;text-align:center;color:var(--ink-muted)}.billing-page .bl-plans{margin-bottom:24px}.billing-page .ov-metrics-table thead th.bl-group{text-align:center;border-bottom:1px solid var(--border-color)}.billing-page .ov-metrics-table tfoot td,.billing-page .ov-metrics-table tfoot th{border-top:1px solid var(--border-color);border-bottom:0;font-weight:600;background:var(--paper-bg-alt)}.billing-page .ov-metrics-table tbody tr:last-child>*{border-bottom:0}.billing-page .bl-plan-name{font-weight:500;text-align:left}.billing-page .bl-plan-cell .bl-swatch,.billing-page .bl-plan-name .bl-swatch{margin-right:8px;vertical-align:1px}.billing-page .bl-link{padding:0;border:0;background:0 0;font:inherit;color:var(--link-color);cursor:pointer;text-align:left}.billing-page .bl-link:hover{text-decoration:underline}.billing-page .bl-idle .bl-link,.billing-page .bl-idle td{color:var(--ink-faint)}.billing-page .ov-muted{color:var(--ink-faint)}.billing-page .bl-note{margin:10px 0 0}.billing-page .bl-grants{margin:8px 0 24px;scroll-margin-top:16px}.billing-page .bl-section-head{margin:0 0 8px}.billing-page .bl-section-head h2{margin:0}.billing-page .bl-grant-scroll{margin-top:12px}.billing-page .bl-grant-table th[scope=row]{font-weight:500;text-align:left;max-width:200px;overflow:hidden;text-overflow:ellipsis}.billing-page .bl-grant-table td,.billing-page .bl-grant-table th{padding:9px 12px}.billing-page .bl-grant-table th[scope=row] a,.billing-page .bl-scope a{color:var(--link-color)}.billing-page .bl-grant-table .sortable{display:inline-flex;align-items:center;gap:4px;padding:0;border:0;background:0 0;font:inherit;color:inherit;cursor:pointer}.billing-page .bl-grant-table .sortable.active{color:var(--color)}.billing-page .bl-state{display:inline-flex;align-items:center;gap:6px}.billing-page .bl-state .status-dot{margin:0}.billing-page .bl-plan-cell{white-space:nowrap}.billing-page .bl-flag{display:inline-block;padding:1px 8px;border-radius:999px;font-size:12px;background:color-mix(in srgb,var(--status-progress) 14%,transparent);color:#7a5212}.dark-mode .billing-page .bl-flag{color:var(--status-progress)}.billing-page .bl-flag.is-bad{background:color-mix(in srgb,var(--st-bad,#b42318) 12%,transparent);color:#a1251b}.dark-mode .billing-page .bl-flag.is-bad{color:#f08a82}.billing-page .bl-scope a{display:inline-flex;align-items:center;gap:6px;max-width:200px;min-width:0}.billing-page .bl-scope a>span{overflow:hidden;text-overflow:ellipsis}.billing-page .bl-scope .ui-icon{width:14px;height:14px;flex:none;color:var(--ink-muted)}.billing-page .bl-page{font-family:var(--font-mono);font-size:12px;color:var(--ink-muted)}.billing-page .bl-alert{display:flex;align-items:center;gap:8px;margin:8px 0}.billing-page .bl-alert .btn{margin-left:auto}.billing-page .bl-pager{justify-content:space-between;border-bottom:none;margin-top:8px}.billing-page .paper-table-empty{display:flex;flex-direction:column;align-items:center;gap:8px;margin-top:12px}@media (max-width:767px){.billing-page .bl-health{gap:4px 14px}.billing-page .bl-health-title{flex-basis:100%}.billing-page .bl-toolbar .seg-filter{max-width:100%;overflow-x:auto}}.breadcrumb .redact-slot,.files .tree-name .redact-slot{position:relative;top:-.15em}.dark-mode .markdown-body :is(p,li,td,th,blockquote,dd) mark.redact-chip,.markdown-body :is(p,li,td,th,blockquote,dd) mark.redact-chip{vertical-align:.04em!important}.email-help{max-width:75ch;margin:1rem 0 .35rem;color:var(--ink-muted)}.email-about{margin-bottom:1.25rem;color:var(--ink-muted);font-size:13px}.email-about summary{cursor:pointer;width:fit-content}.email-about p{max-width:75ch;margin:.5rem 0}.email-toolbar{display:flex;flex-wrap:wrap;align-items:end;gap:1rem;margin-bottom:1.25rem}.email-toolbar label{margin-bottom:0;display:grid;gap:.4rem;font-weight:600}.email-toolbar select{min-width:11rem;max-width:100%}.email-toolbar-actions{display:flex;flex-wrap:wrap;gap:.5rem}.email-state{display:flex;align-items:center;flex-wrap:wrap;gap:1rem;padding:1rem;margin:1rem 0;background:var(--paper-card);border:1px solid var(--border-color);border-radius:12px;color:var(--ink-muted)}.email-state p{margin:0}.email-state-error{color:var(--status-error);background:var(--status-error-soft)}.email-table-wrap{border:1px solid var(--border-color);border-radius:12px;overflow:hidden;background:var(--paper-card)}.email-table{width:100%;table-layout:fixed;font-size:13px;line-height:1.5}.email-table td,.email-table th{padding:1rem;text-align:left;vertical-align:top;overflow-wrap:anywhere}.email-table th{background:var(--paper-bg-alt);color:var(--ink-muted);font-weight:500;font-size:12px}.email-table tbody tr+tr{border-top:1px solid var(--border-color)}.email-table th:first-child{width:25%}.email-table th:nth-child(2){width:22%}.email-table th:nth-child(3){width:19%}.email-table th:nth-child(4){width:16%}.email-detail{display:block;color:var(--ink-muted);font-size:11.5px;margin-top:.35rem}.email-resource .email-detail{font-family:var(--font-mono)}.email-outcome{display:inline-flex;align-items:baseline;gap:.4rem;font-weight:600}.email-outcome::before{content:'';width:6px;height:6px;border-radius:50%;background:currentColor;flex-shrink:0;align-self:center}.email-outcome-accepted{color:var(--status-ready)}.email-outcome-rejected{color:var(--status-error)}.email-outcome-sending,.email-outcome-unknown{color:var(--status-progress)}.email-footer{display:flex;flex-wrap:wrap;justify-content:space-between;gap:1rem;align-items:center;margin-top:1rem;color:var(--ink-muted);font-size:13px}.email-mobile-label{display:none}@media (max-width:767px){.email-toolbar{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr);gap:.75rem}.email-toolbar select{width:100%;min-width:0;font-size:13px}.email-toolbar-actions{grid-column:1/-1}.email-table,.email-table tbody{display:block}.email-table thead{position:absolute;width:1px;height:1px;padding:0;overflow:hidden;clip-path:inset(50%);white-space:nowrap}.email-table tbody tr{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr);gap:.85rem 1rem;padding:1rem}.email-table td{display:block;padding:0;min-width:0}.email-table .email-recipient{grid-column:1/-1;font-weight:500}.email-table .email-result{grid-column:1/-1}.email-table .email-resource{grid-column:1/-1}.email-mobile-label{display:block;margin-bottom:.2rem;color:var(--ink-muted);font-size:11px;font-weight:400}} \ No newline at end of file +.reviewer-preview .rp-main{min-width:0;min-height:0;display:flex;flex-direction:column;overflow:hidden}.reviewer-preview .rp-document{flex:1 1 auto;min-height:0;min-width:0;overflow:auto;scrollbar-width:thin;position:relative}.reviewer-preview button.rp-count{background:0 0;border:0;padding:0;font:inherit;cursor:pointer;text-decoration:underline;text-decoration-color:transparent;text-underline-offset:3px}.reviewer-preview button.rp-count:hover{text-decoration-color:currentColor}@media (max-width:767px){.reviewer-preview .file-card-head .rp-preserved-tag{display:none}}.billing-page{--bl-subscription:#008C7E;--bl-repository:#D0652A;--bl-conference:#6250D6}.dark-mode .billing-page{--bl-subscription:#16A091;--bl-repository:#D95926;--bl-conference:#9085E9}.billing-page .bl-subscription{background:var(--bl-subscription)!important}.billing-page .bl-repository{background:var(--bl-repository)!important}.billing-page .bl-conference{background:var(--bl-conference)!important}.billing-page .bl-toolbar{display:flex;align-items:center;justify-content:space-between;flex-wrap:wrap;gap:8px 16px;margin:4px 0 0}.billing-page .bl-basis{margin:0;font-size:12px;color:var(--ink-muted)}.billing-page .bl-message{display:flex;align-items:center;gap:8px;margin:14px 0 0;padding:10px 14px;border:1px solid var(--border-color);border-radius:var(--radius-control,8px);font-size:13px;color:var(--color);background:var(--paper-card)}.billing-page .bl-message .ui-icon{width:16px;height:16px;flex:none;color:var(--ink-muted)}.billing-page .bl-message.ov-performance-warning{border-color:color-mix(in srgb,var(--status-progress) 45%,var(--border-color));background:color-mix(in srgb,var(--status-progress) 8%,var(--paper-card))}.billing-page .bl-message.ov-performance-warning .ui-icon{color:var(--status-progress)}.billing-page .bl-message .btn{margin-left:auto}.overview-page .bl-kpi-row{grid-template-columns:repeat(6,minmax(0,1fr));margin:16px 0 16px}.overview-page .bl-kpi-row .ov-kpi-card{min-width:0;padding:16px 18px}.overview-page .bl-kpi-row .ov-kpi-label{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.overview-page .bl-kpi-row .ov-kpi-sub{white-space:normal;overflow-wrap:anywhere;line-height:1.4}.overview-page .bl-kpi-row .ov-kpi-value{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.overview-page .bl-kpi-row .bl-muted-value{color:var(--ink-muted);font-size:20px;line-height:28px}.overview-page .bl-kpi-row.is-loading .ov-kpi-card{opacity:.6}.billing-page .bl-skeleton-value{display:block;width:50%;height:28px;margin:4px 0;border-radius:6px}@media (max-width:1279px){.overview-page .bl-kpi-row{grid-template-columns:repeat(3,minmax(0,1fr))!important}}@media (max-width:767px){.overview-page .bl-kpi-row{grid-template-columns:repeat(2,minmax(0,1fr))!important}}.billing-page .bl-health{display:flex;align-items:center;flex-wrap:wrap;gap:6px 20px;padding:10px 16px;margin:0 0 16px;border:1px solid var(--border-color);border-radius:var(--radius-control,8px);background:var(--paper-card);font-size:13px;font-variant-numeric:tabular-nums}.billing-page .bl-health-title{display:inline-flex;align-items:center;gap:8px;font-weight:600}.billing-page .bl-health-title .ov-svc-dot{width:8px;height:8px;margin:0;border-radius:50%}.billing-page .bl-dot-bad{background:var(--st-bad,#b42318)}.billing-page .bl-health-item .k{color:var(--ink-muted);margin-right:2px}.billing-page .bl-health-item.is-bad{color:var(--st-bad,#b42318);font-weight:600}.billing-page .bl-health-item.is-warn{color:#946519;font-weight:600}.dark-mode .billing-page .bl-health-item.is-warn{color:var(--status-progress)}.dark-mode .billing-page .bl-health-item.is-bad{color:#f08a82}.billing-page .bl-health-error{min-width:0;max-width:100%;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.billing-page .bl-health-error code{font-size:12px;color:inherit;background:var(--paper-bg-alt);padding:1px 5px;border-radius:4px}.billing-page .bl-chart-card{margin-bottom:16px}.billing-page .bl-swatch{display:inline-block;width:8px;height:8px;border-radius:2px;flex:none}.billing-page .bl-bars{position:relative;gap:3px}.billing-page .bl-bars.is-dense{gap:1px}.billing-page .bl-col{min-width:0}.billing-page .bl-stack{display:flex;flex-direction:column-reverse;width:100%;gap:1px;border-radius:2px 2px 0 0;overflow:hidden}.billing-page .bl-stack>i{display:block;min-height:2px;flex-basis:0}.billing-page .bl-col:hover .bl-stack{filter:brightness(1.08)}.billing-page .bl-col.is-zero .bl-stack{height:1px!important;background:var(--border-color)}.billing-page .bl-empty{margin:8px 0 4px;padding:32px 0;text-align:center;color:var(--ink-muted)}.billing-page .bl-plans{margin-bottom:24px}.billing-page .ov-metrics-table thead th.bl-group{text-align:center;border-bottom:1px solid var(--border-color)}.billing-page .ov-metrics-table tfoot td,.billing-page .ov-metrics-table tfoot th{border-top:1px solid var(--border-color);border-bottom:0;font-weight:600;background:var(--paper-bg-alt)}.billing-page .ov-metrics-table tbody tr:last-child>*{border-bottom:0}.billing-page .bl-plan-name{font-weight:500;text-align:left}.billing-page .bl-plan-cell .bl-swatch,.billing-page .bl-plan-name .bl-swatch{margin-right:8px;vertical-align:1px}.billing-page .bl-link{padding:0;border:0;background:0 0;font:inherit;color:var(--link-color);cursor:pointer;text-align:left}.billing-page .bl-link:hover{text-decoration:underline}.billing-page .bl-idle .bl-link,.billing-page .bl-idle td{color:var(--ink-faint)}.billing-page .ov-muted{color:var(--ink-faint)}.billing-page .bl-note{margin:10px 0 0}.billing-page .bl-grants{margin:8px 0 24px;scroll-margin-top:16px}.billing-page .bl-section-head{margin:0 0 8px}.billing-page .bl-section-head h2{margin:0}.billing-page .bl-grant-scroll{margin-top:12px}.billing-page .bl-grant-table th[scope=row]{font-weight:500;text-align:left;max-width:200px;overflow:hidden;text-overflow:ellipsis}.billing-page .bl-grant-table td,.billing-page .bl-grant-table th{padding:9px 12px}.billing-page .bl-grant-table th[scope=row] a,.billing-page .bl-scope a{color:var(--link-color)}.billing-page .bl-grant-table .sortable{display:inline-flex;align-items:center;gap:4px;padding:0;border:0;background:0 0;font:inherit;color:inherit;cursor:pointer}.billing-page .bl-grant-table .sortable.active{color:var(--color)}.billing-page .bl-state{display:inline-flex;align-items:center;gap:6px}.billing-page .bl-state .status-dot{margin:0}.billing-page .bl-plan-cell{white-space:nowrap}.billing-page .bl-flag{display:inline-block;padding:1px 8px;border-radius:999px;font-size:12px;background:color-mix(in srgb,var(--status-progress) 14%,transparent);color:#7a5212}.dark-mode .billing-page .bl-flag{color:var(--status-progress)}.billing-page .bl-flag.is-bad{background:color-mix(in srgb,var(--st-bad,#b42318) 12%,transparent);color:#a1251b}.dark-mode .billing-page .bl-flag.is-bad{color:#f08a82}.billing-page .bl-scope a{display:inline-flex;align-items:center;gap:6px;max-width:200px;min-width:0}.billing-page .bl-scope a>span{overflow:hidden;text-overflow:ellipsis}.billing-page .bl-scope .ui-icon{width:14px;height:14px;flex:none;color:var(--ink-muted)}.billing-page .bl-page{font-family:var(--font-mono);font-size:12px;color:var(--ink-muted)}.billing-page .bl-alert{display:flex;align-items:center;gap:8px;margin:8px 0}.billing-page .bl-alert .btn{margin-left:auto}.billing-page .bl-pager{justify-content:space-between;border-bottom:none;margin-top:8px}.billing-page .paper-table-empty{display:flex;flex-direction:column;align-items:center;gap:8px;margin-top:12px}@media (max-width:767px){.billing-page .bl-health{gap:4px 14px}.billing-page .bl-health-title{flex-basis:100%}.billing-page .bl-toolbar .seg-filter{max-width:100%;overflow-x:auto}}.breadcrumb .redact-slot,.files .tree-name .redact-slot{position:relative;top:-.15em}.dark-mode .markdown-body :is(p,li,td,th,blockquote,dd) mark.redact-chip,.markdown-body :is(p,li,td,th,blockquote,dd) mark.redact-chip{vertical-align:.04em!important}.emails-page .email-overview-toolbar,.emails-page .email-refresh,.emails-page .email-section-head{display:flex;align-items:center;justify-content:space-between;gap:12px;flex-wrap:wrap}.email-overview-toolbar{margin:20px 0 10px}.email-basis,.email-muted,.email-refresh{color:var(--ink-muted);font-size:12px}.email-basis{margin:0 0 16px}.emails-page .email-kpis{grid-template-columns:repeat(4,minmax(0,1fr));margin-bottom:16px}.email-error-text{color:var(--status-error)}.email-chart{margin-bottom:28px}.email-chart h2{margin:0}.email-legend{display:flex;flex-wrap:wrap;gap:16px;font-size:11px}.email-chart-plot{display:flex;gap:10px;height:108px;margin-top:20px}.email-axis{display:flex;flex-direction:column;justify-content:space-between;color:var(--ink-muted);font:11px var(--font-mono);min-width:20px}.email-bars{display:flex;gap:5px;flex:1;border-bottom:1px solid var(--border-color);background:linear-gradient(var(--border-color),var(--border-color)) center/100% 1px no-repeat}.email-bar-column{flex:1;min-width:0;display:flex;align-items:flex-end;padding:0 2px}.email-bar-stack{width:100%;display:flex;flex-direction:column-reverse;gap:1px;border-radius:2px 2px 0 0;overflow:hidden;background:var(--border-color)}.email-bar-stack i{flex-basis:0;min-height:0}.email-bar-accepted{background:var(--status-ready)}.email-bar-rejected{background:var(--status-error)}.email-bar-unknown{background:var(--status-progress)}.email-chart-dates{display:flex;justify-content:space-between;gap:12px;margin:8px 0 0 30px;color:var(--ink-muted);font-size:11px}.email-section-head{margin-bottom:14px}.email-section-head h2{font-size:18px;margin:0}.email-toolbar{display:flex;align-items:end;gap:10px;margin-bottom:16px}.email-toolbar label{display:grid;gap:6px;margin:0;font-size:12px;font-weight:500}.email-toolbar .email-search{flex:1}.email-toolbar input{width:100%}.email-toolbar select{min-width:180px}.email-status-tabs{display:flex;gap:20px;border-bottom:1px solid var(--border-color);margin-bottom:14px;overflow-x:auto}.email-status-tabs button{padding:0 0 10px;background:0 0;border:0;border-bottom:2px solid transparent;color:var(--ink-muted);font:500 12px inherit;white-space:nowrap;cursor:pointer}.email-status-tabs button.active{border-color:var(--accent);color:var(--color)}.email-status-tabs button span{margin-left:5px;font-family:var(--font-mono);font-size:11px}.email-state{display:flex;align-items:center;flex-wrap:wrap;gap:12px;padding:20px;margin:16px 0;background:var(--paper-card);border:1px solid var(--border-color);border-radius:8px;color:var(--ink-muted)}.email-state p{margin:0}.email-state-error{color:var(--status-error)}.email-table-wrap{border:1px solid var(--border-color);border-radius:8px;overflow:hidden;background:var(--paper-card)}.email-table{width:100%;table-layout:fixed;font-size:12px;line-height:1.5}.email-table td,.email-table th{padding:11px 14px;text-align:left;vertical-align:middle;overflow-wrap:anywhere}.email-table th{background:var(--paper-bg-alt);color:var(--ink-muted);font-weight:500;font-size:11px}.email-table tbody tr+tr{border-top:1px solid var(--border-color)}.email-table th:first-child{width:32%}.email-table th:nth-child(2){width:19%}.email-table th:nth-child(3){width:21%}.email-table th:nth-child(4){width:18%}.email-table th:last-child{width:10%}.email-recipient>span{display:block;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.email-attempted,.email-type{color:var(--ink-muted)}.email-outcome{display:inline-flex;align-items:center;gap:6px;font-weight:500;white-space:nowrap}.email-outcome::before{content:'';width:6px;height:6px;border-radius:50%;background:currentColor;flex-shrink:0}.email-outcome-accepted{color:var(--status-ready)}.email-outcome-rejected{color:var(--status-error)}.email-outcome-sending,.email-outcome-unknown{color:var(--status-progress)}.email-http{margin-left:8px;color:var(--ink-muted);font:10px var(--font-mono)}.email-copy,.email-detail-button{border:0;background:0 0;color:var(--link-color);cursor:pointer;font:inherit;padding:3px 0}.email-detail-button{white-space:nowrap}.email-detail-button span{margin-left:5px}.email-copy:hover,.email-detail-button:hover{text-decoration:underline}.email-selected{background:var(--paper-bg-alt)}.email-expanded td{padding:20px 24px;background:var(--paper-bg-alt)}.email-detail-heading{display:flex;align-items:center;gap:16px}.email-detail-heading h3{margin:0;font-size:14px}.email-explanation{max-width:85ch;margin:10px 0 20px;color:var(--ink-soft)}.email-detail-grid{display:grid;grid-template-columns:1fr 1fr;gap:16px 30px;margin:0}.email-detail-grid dt{color:var(--ink-muted);font-size:11px;font-weight:400;margin-bottom:4px}.email-detail-grid dd{margin:0;overflow-wrap:anywhere}.email-detail-grid code{color:inherit;background:0 0;padding:0;font-size:11px}.email-copy{margin-left:10px;font-size:11px}.email-copy-feedback{margin:10px 0 0;color:var(--ink-muted);min-height:18px}.email-footer{display:flex;justify-content:space-between;gap:12px;align-items:center;margin-top:12px;color:var(--ink-muted);font-size:12px}.email-footer>div{display:flex;gap:8px}.email-about{margin:24px 0;color:var(--ink-muted);font-size:12px}.email-about summary{cursor:pointer;width:fit-content}.email-about p{max-width:90ch;margin:8px 0}@media(max-width:767px){.emails-page .email-kpis{grid-template-columns:repeat(2,minmax(0,1fr))}.emails-page .email-kpis .ov-kpi-card{padding:14px}.emails-page .email-kpis .ov-kpi-value{font-size:26px}.email-overview-toolbar .email-refresh{width:100%}.email-toolbar{flex-wrap:wrap}.email-toolbar .email-search{flex-basis:100%}.email-toolbar label:not(.email-search){flex:1}.email-toolbar select{min-width:0;width:100%}.email-legend{gap:10px}.email-chart .ov-chart-head{flex-wrap:wrap;gap:10px}.email-chart-dates{font-size:10px}.email-bars{gap:2px}.email-bar-column{padding:0}.email-status-tabs{gap:18px}.email-table,.email-table tbody{display:block}.email-table thead{position:absolute;width:1px;height:1px;overflow:hidden;clip-path:inset(50%)}.email-table tbody tr{display:grid;grid-template-columns:1fr auto;gap:6px 12px;padding:14px}.email-table td{display:block;padding:0;min-width:0}.email-table .email-recipient{grid-column:1/-1}.email-table .email-recipient>span{white-space:normal}.email-table .email-result{grid-column:1}.email-table .email-type{grid-column:1}.email-table .email-attempted{grid-column:1;font-size:11px}.email-table .email-expand{grid-column:2;grid-row:2/5;align-self:center}.email-table tbody .email-expanded{display:block;padding:18px 14px;background:var(--paper-bg-alt)}.email-detail-grid{grid-template-columns:1fr;gap:14px}.email-detail-heading{flex-wrap:wrap}.email-section-head .email-muted{font-size:11px}.email-footer{flex-wrap:wrap}.email-table .email-http{font-size:10px}}.emails-page .ov-kpi-sub{white-space:normal;overflow:visible;text-overflow:clip}.email-pager-top{margin:0 0 10px}.email-status-tabs button{font-family:inherit;font-size:12px;font-weight:500}.email-chart-data{margin:12px 0 0 30px;color:var(--ink-muted);font-size:11px}.email-chart-data summary{cursor:pointer;width:fit-content}.email-data-scroll{overflow:auto;max-height:240px;margin-top:10px}.email-chart-data table{width:100%;font-variant-numeric:tabular-nums}.email-chart-data td,.email-chart-data th{text-align:right;padding:6px 10px;border-bottom:1px solid var(--border-color);white-space:nowrap}.email-chart-data th:first-child{text-align:left}.email-chart-data th{font-weight:500}.email-search-help{margin:-6px 0 16px;font-size:11px;color:var(--ink-muted)}@media(max-width:767px){.email-status-tabs{flex-wrap:wrap;gap:10px 18px;overflow:visible}.email-status-tabs button{padding-bottom:7px}.email-search-help{line-height:1.5}}.emails-page .email-kpis .ov-kpi-sub{white-space:normal!important}#email-history-title{scroll-margin-top:80px}.email-jump{font-size:12px;margin-right:auto} \ No newline at end of file diff --git a/public/css/style.css b/public/css/style.css index ae99343..60db110 100644 --- a/public/css/style.css +++ b/public/css/style.css @@ -14329,46 +14329,56 @@ body.dark-mode .reviewer-preview .rp-preserved-tag { background: rgba(251, 191, /* Text: the slot centers on the line's letters, level with parentheses and punctuation. */ .markdown-body :is(p, li, td, th, blockquote, dd) mark.redact-chip, .dark-mode .markdown-body :is(p, li, td, th, blockquote, dd) mark.redact-chip { vertical-align: .04em !important; } -/* Email delivery history follows the admin palette and table typography. */ -.email-help { max-width: 75ch; margin: 1rem 0 .35rem; color: var(--ink-muted); } -.email-about { margin-bottom: 1.25rem; color: var(--ink-muted); font-size: 13px; } -.email-about summary { cursor: pointer; width: fit-content; } -.email-about p { max-width: 75ch; margin: .5rem 0; } -.email-toolbar { display: flex; flex-wrap: wrap; align-items: end; gap: 1rem; margin-bottom: 1.25rem; } -.email-toolbar label { margin-bottom: 0; display: grid; gap: .4rem; font-weight: 600; } -.email-toolbar select { min-width: 11rem; max-width: 100%; } -.email-toolbar-actions { display: flex; flex-wrap: wrap; gap: .5rem; } -.email-state { display: flex; align-items: center; flex-wrap: wrap; gap: 1rem; padding: 1rem; margin: 1rem 0; background: var(--paper-card); border: 1px solid var(--border-color); border-radius: 12px; color: var(--ink-muted); } -.email-state p { margin: 0; } -.email-state-error { color: var(--status-error); background: var(--status-error-soft); } -.email-table-wrap { border: 1px solid var(--border-color); border-radius: 12px; overflow: hidden; background: var(--paper-card); } -.email-table { width: 100%; table-layout: fixed; font-size: 13px; line-height: 1.5; } -.email-table th, .email-table td { padding: 1rem; text-align: left; vertical-align: top; overflow-wrap: anywhere; } -.email-table th { background: var(--paper-bg-alt); color: var(--ink-muted); font-weight: 500; font-size: 12px; } -.email-table tbody tr + tr { border-top: 1px solid var(--border-color); } -.email-table th:first-child { width: 25%; } -.email-table th:nth-child(2) { width: 22%; } -.email-table th:nth-child(3) { width: 19%; } -.email-table th:nth-child(4) { width: 16%; } -.email-detail { display: block; color: var(--ink-muted); font-size: 11.5px; margin-top: .35rem; } -.email-resource .email-detail { font-family: var(--font-mono); } -.email-outcome { display: inline-flex; align-items: baseline; gap: .4rem; font-weight: 600; } -.email-outcome::before { content: ''; width: 6px; height: 6px; border-radius: 50%; background: currentColor; flex-shrink: 0; align-self: center; } -.email-outcome-accepted { color: var(--status-ready); } -.email-outcome-rejected { color: var(--status-error); } -.email-outcome-unknown, .email-outcome-sending { color: var(--status-progress); } -.email-footer { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 1rem; align-items: center; margin-top: 1rem; color: var(--ink-muted); font-size: 13px; } -.email-mobile-label { display: none; } -@media (max-width: 767px) { - .email-toolbar { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: .75rem; } - .email-toolbar select { width: 100%; min-width: 0; font-size: 13px; } - .email-toolbar-actions { grid-column: 1 / -1; } - .email-table, .email-table tbody { display: block; } - .email-table thead { position: absolute; width: 1px; height: 1px; padding: 0; overflow: hidden; clip-path: inset(50%); white-space: nowrap; } - .email-table tbody tr { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: .85rem 1rem; padding: 1rem; } - .email-table td { display: block; padding: 0; min-width: 0; } - .email-table .email-recipient { grid-column: 1 / -1; font-weight: 500; } - .email-table .email-result { grid-column: 1 / -1; } - .email-table .email-resource { grid-column: 1 / -1; } - .email-mobile-label { display: block; margin-bottom: .2rem; color: var(--ink-muted); font-size: 11px; font-weight: 400; } +/* Email operations: shared admin surfaces, compact history, progressive details. */ +.emails-page .email-overview-toolbar, .emails-page .email-section-head, .emails-page .email-refresh { display:flex; align-items:center; justify-content:space-between; gap:12px; flex-wrap:wrap; } +.email-overview-toolbar { margin:20px 0 10px; } +.email-refresh, .email-basis, .email-muted { color:var(--ink-muted); font-size:12px; } +.email-basis { margin:0 0 16px; } +.emails-page .email-kpis { grid-template-columns:repeat(4,minmax(0,1fr)); margin-bottom:16px; } +.email-error-text { color:var(--status-error); } +.email-chart { margin-bottom:28px; } +.email-chart h2 { margin:0; } +.email-legend { display:flex; flex-wrap:wrap; gap:16px; font-size:11px; } +.email-chart-plot { display:flex; gap:10px; height:108px; margin-top:20px; } +.email-axis { display:flex; flex-direction:column; justify-content:space-between; color:var(--ink-muted); font:11px var(--font-mono); min-width:20px; } +.email-bars { display:flex; gap:5px; flex:1; border-bottom:1px solid var(--border-color); background:linear-gradient(var(--border-color),var(--border-color)) center/100% 1px no-repeat; } +.email-bar-column { flex:1; min-width:0; display:flex; align-items:flex-end; padding:0 2px; } +.email-bar-stack { width:100%; display:flex; flex-direction:column-reverse; gap:1px; border-radius:2px 2px 0 0; overflow:hidden; background:var(--border-color); } +.email-bar-stack i { flex-basis:0; min-height:0; } +.email-bar-accepted { background:var(--status-ready); }.email-bar-rejected { background:var(--status-error); }.email-bar-unknown { background:var(--status-progress); } +.email-chart-dates { display:flex; justify-content:space-between; gap:12px; margin:8px 0 0 30px; color:var(--ink-muted); font-size:11px; } +.email-section-head { margin-bottom:14px; }.email-section-head h2 { font-size:18px; margin:0; } +.email-toolbar { display:flex; align-items:end; gap:10px; margin-bottom:16px; } +.email-toolbar label { display:grid; gap:6px; margin:0; font-size:12px; font-weight:500; } +.email-toolbar .email-search { flex:1; }.email-toolbar input { width:100%; }.email-toolbar select { min-width:180px; } +.email-status-tabs { display:flex; gap:20px; border-bottom:1px solid var(--border-color); margin-bottom:14px; overflow-x:auto; } +.email-status-tabs button { padding:0 0 10px; background:none; border:0; border-bottom:2px solid transparent; color:var(--ink-muted); font:500 12px inherit; white-space:nowrap; cursor:pointer; } +.email-status-tabs button.active { border-color:var(--accent); color:var(--color); }.email-status-tabs button span { margin-left:5px; font-family:var(--font-mono); font-size:11px; } +.email-state { display:flex; align-items:center; flex-wrap:wrap; gap:12px; padding:20px; margin:16px 0; background:var(--paper-card); border:1px solid var(--border-color); border-radius:8px; color:var(--ink-muted); }.email-state p { margin:0; }.email-state-error { color:var(--status-error); } +.email-table-wrap { border:1px solid var(--border-color); border-radius:8px; overflow:hidden; background:var(--paper-card); } +.email-table { width:100%; table-layout:fixed; font-size:12px; line-height:1.5; } +.email-table th,.email-table td { padding:11px 14px; text-align:left; vertical-align:middle; overflow-wrap:anywhere; } +.email-table th { background:var(--paper-bg-alt); color:var(--ink-muted); font-weight:500; font-size:11px; } +.email-table tbody tr+tr { border-top:1px solid var(--border-color); }.email-table th:first-child { width:32%; }.email-table th:nth-child(2) { width:19%; }.email-table th:nth-child(3) { width:21%; }.email-table th:nth-child(4) { width:18%; }.email-table th:last-child { width:10%; } +.email-recipient > span { display:block; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }.email-type,.email-attempted { color:var(--ink-muted); } +.email-outcome { display:inline-flex; align-items:center; gap:6px; font-weight:500; white-space:nowrap; }.email-outcome::before { content:''; width:6px; height:6px; border-radius:50%; background:currentColor; flex-shrink:0; } +.email-outcome-accepted { color:var(--status-ready); }.email-outcome-rejected { color:var(--status-error); }.email-outcome-unknown,.email-outcome-sending { color:var(--status-progress); }.email-http { margin-left:8px; color:var(--ink-muted); font:10px var(--font-mono); } +.email-detail-button,.email-copy { border:0; background:none; color:var(--link-color); cursor:pointer; font:inherit; padding:3px 0; }.email-detail-button { white-space:nowrap; }.email-detail-button span { margin-left:5px; }.email-detail-button:hover,.email-copy:hover { text-decoration:underline; } +.email-selected { background:var(--paper-bg-alt); }.email-expanded td { padding:20px 24px; background:var(--paper-bg-alt); }.email-detail-heading { display:flex; align-items:center; gap:16px; }.email-detail-heading h3 { margin:0; font-size:14px; }.email-explanation { max-width:85ch; margin:10px 0 20px; color:var(--ink-soft); }.email-detail-grid { display:grid; grid-template-columns:1fr 1fr; gap:16px 30px; margin:0; }.email-detail-grid dt { color:var(--ink-muted); font-size:11px; font-weight:400; margin-bottom:4px; }.email-detail-grid dd { margin:0; overflow-wrap:anywhere; }.email-detail-grid code { color:inherit; background:none; padding:0; font-size:11px; }.email-copy { margin-left:10px; font-size:11px; }.email-copy-feedback { margin:10px 0 0; color:var(--ink-muted); min-height:18px; } +.email-footer { display:flex; justify-content:space-between; gap:12px; align-items:center; margin-top:12px; color:var(--ink-muted); font-size:12px; }.email-footer>div { display:flex; gap:8px; } +.email-about { margin:24px 0; color:var(--ink-muted); font-size:12px; }.email-about summary { cursor:pointer; width:fit-content; }.email-about p { max-width:90ch; margin:8px 0; } +@media(max-width:767px) { + .emails-page .email-kpis { grid-template-columns:repeat(2,minmax(0,1fr)); }.emails-page .email-kpis .ov-kpi-card { padding:14px; }.emails-page .email-kpis .ov-kpi-value { font-size:26px; }.email-overview-toolbar .email-refresh { width:100%; }.email-toolbar { flex-wrap:wrap; }.email-toolbar .email-search { flex-basis:100%; }.email-toolbar label:not(.email-search) { flex:1; }.email-toolbar select { min-width:0; width:100%; }.email-legend { gap:10px; }.email-chart .ov-chart-head { flex-wrap:wrap; gap:10px; }.email-chart-dates { font-size:10px; }.email-bars { gap:2px; }.email-bar-column { padding:0; }.email-status-tabs { gap:18px; }.email-table,.email-table tbody { display:block; }.email-table thead { position:absolute; width:1px; height:1px; overflow:hidden; clip-path:inset(50%); }.email-table tbody tr { display:grid; grid-template-columns:1fr auto; gap:6px 12px; padding:14px; }.email-table td { display:block; padding:0; min-width:0; }.email-table .email-recipient { grid-column:1/-1; }.email-table .email-recipient>span { white-space:normal; }.email-table .email-result { grid-column:1; }.email-table .email-type { grid-column:1; }.email-table .email-attempted { grid-column:1; font-size:11px; }.email-table .email-expand { grid-column:2; grid-row:2/5; align-self:center; }.email-table tbody .email-expanded { display:block; padding:18px 14px; background:var(--paper-bg-alt); }.email-detail-grid { grid-template-columns:1fr; gap:14px; }.email-detail-heading { flex-wrap:wrap; }.email-section-head .email-muted { font-size:11px; }.email-footer { flex-wrap:wrap; }.email-table .email-http { font-size:10px; } } + +.emails-page .ov-kpi-sub { white-space:normal; overflow:visible; text-overflow:clip; }.email-pager-top { margin:0 0 10px; }.email-status-tabs button { font-family:inherit; font-size:12px; font-weight:500; } + +.email-chart-data { margin:12px 0 0 30px; color:var(--ink-muted); font-size:11px; }.email-chart-data summary { cursor:pointer; width:fit-content; }.email-data-scroll { overflow:auto; max-height:240px; margin-top:10px; }.email-chart-data table { width:100%; font-variant-numeric:tabular-nums; }.email-chart-data th,.email-chart-data td { text-align:right; padding:6px 10px; border-bottom:1px solid var(--border-color); white-space:nowrap; }.email-chart-data th:first-child { text-align:left; }.email-chart-data th { font-weight:500; } + +.email-search-help { margin:-6px 0 16px; font-size:11px; color:var(--ink-muted); } +@media(max-width:767px) { .email-status-tabs { flex-wrap:wrap; gap:10px 18px; overflow:visible; }.email-status-tabs button { padding-bottom:7px; }.email-search-help { line-height:1.5; } } + +.emails-page .email-kpis .ov-kpi-sub { white-space:normal !important; } +#email-history-title { scroll-margin-top:80px; } + +.email-jump { font-size:12px; margin-right:auto; } diff --git a/public/partials/admin/emails.htm b/public/partials/admin/emails.htm index 2a2465c..6acef95 100644 --- a/public/partials/admin/emails.htm +++ b/public/partials/admin/emails.htm @@ -1,4 +1,4 @@ -
+
Admin  /  Emails

Emails

@@ -14,37 +14,44 @@ Errors - - - -

{{ emailAnnouncement }}

- - - - diff --git a/public/script/admin.js b/public/script/admin.js index 4d61298..7d5008b 100644 --- a/public/script/admin.js +++ b/public/script/admin.js @@ -2432,43 +2432,127 @@ export const billingAdminController = function (state, http, location) { export const emailsAdminController = function (state, http, location) { if (state.user == null) { location.url("/"); return; } + state.Math = Math; + const browser = typeof window !== "undefined" ? window : null; + const query = browser ? new URLSearchParams(browser.location.search) : null; + const periods = ["7d", "30d", "90d", "all"]; + const statuses = ["accepted", "rejected", "unknown", "sending"]; state.emailRows = []; - state.emailState = ""; - state.emailKind = ""; + state.emailState = statuses.includes(query?.get("state")) ? query.get("state") : ""; + state.emailKind = ["repository-expiration", "owner-access"].includes(query?.get("kind")) ? query.get("kind") : ""; + state.emailPeriod = periods.includes(query?.get("period")) ? query.get("period") : "7d"; + state.emailSearch = query?.get("search") || ""; + let appliedSearch = state.emailSearch.trim(); state.emailLoading = false; state.emailError = ""; state.emailAnnouncement = ""; state.emailNextCursor = null; - state.emailStatusLabel = (value) => ({ sending: "Outcome pending", accepted: "Accepted", rejected: "Rejected", unknown: "Unknown outcome" }[value] || value); - state.emailKindLabel = (value) => value === "repository-expiration" ? "Repository expiration" : "GitHub access"; - state.emailTime = (value) => value ? new Date(value).toLocaleString(undefined, { - year: "numeric", month: "short", day: "numeric", hour: "2-digit", minute: "2-digit", timeZoneName: "short", - }) : "Not recorded"; - state.hasEmailFilters = () => !!(state.emailState || state.emailKind); - state.clearEmailFilters = () => { state.emailState = ""; state.emailKind = ""; return state.loadEmails(); }; - let generation = 0, lastFilters = "", failedMore = false; - state.on("dispose", () => { generation++; }); + state.emailSummary = null; + state.emailSummaryError = ""; + state.emailSummaryLoading = false; + state.emailUpdated = null; + state.emailPage = 1; + state.selectedEmailId = null; + state.emailCopyMessage = ""; + state.emailCopiedValue = null; + state.emailTimezone = Intl.DateTimeFormat().resolvedOptions().timeZone; + state.emailStatusLabel = (value) => ({ sending: "Pending", accepted: "Accepted", rejected: "Rejected", unknown: "Unknown" }[value] || value); + state.emailKindLabel = (value) => ({ "repository-expiration": "Repository expiration", "owner-access": "GitHub access" }[value] || value); + state.emailTime = (value) => value ? new Date(value).toLocaleString(undefined, { year: "numeric", month: "short", day: "numeric", hour: "2-digit", minute: "2-digit", second: "2-digit", timeZoneName: "short" }) : "Not recorded"; + state.emailShortTime = (value) => { + if (!value) return "Not recorded"; + const date = new Date(value); + return date.toLocaleString(undefined, { ...(state.emailPeriod === "all" || date.getFullYear() !== new Date().getFullYear() ? { year: "numeric" } : {}), month: "short", day: "numeric", hour: "2-digit", minute: "2-digit" }); + }; + state.emailExplanation = (row) => { + if (row.state === "accepted") return "The provider accepted this request. Inbox delivery is not confirmed."; + if (row.state === "sending") return "The attempt was recorded, but no final outcome has been recorded. Check the provider before sending again."; + if (row.state === "unknown") return "The provider outcome could not be confirmed. Check the provider before sending again to avoid duplicates."; + const reasons = { 400: "The provider rejected the request as invalid.", 401: "The provider rejected authentication.", 403: "The provider denied this request.", 404: "The provider could not find the requested endpoint or resource.", 422: "The provider could not process the request.", 429: "The provider rejected the request because of rate limiting." }; + return reasons[row.httpStatus] || (row.httpStatus >= 500 ? "The provider reported a server error." : "The provider rejected this request."); + }; + state.toggleEmail = (row) => { state.selectedEmailId = state.selectedEmailId === row._id ? null : row._id; state.emailCopyMessage = ""; state.emailCopiedValue = null; }; + let disposed = false, generation = 0, summaryGeneration = 0, lastFilters = "", lastSummaryFilters = "", failedMore = false, pendingPage = null; + state.copyEmail = async (value) => { + state.emailCopiedValue = null; + try { + if (!browser?.navigator?.clipboard) throw new Error("Clipboard unavailable"); + await browser.navigator.clipboard.writeText(String(value)); + if (!disposed) { state.emailCopyMessage = "Copied."; state.emailCopiedValue = String(value); } + } catch { if (!disposed) state.emailCopyMessage = "Could not copy. Select and copy the text manually."; } + }; + const params = () => ({ period: state.emailPeriod, search: appliedSearch || undefined, kind: state.emailKind || undefined }); + const persist = () => { + if (!browser) return; + try { + const url = new URL(browser.location.href); + for (const [key, value] of Object.entries({ ...params(), state: state.emailState })) { + if (value) url.searchParams.set(key, value); else url.searchParams.delete(key); + } + browser.history.replaceState(null, "", url.pathname + url.search + url.hash); + } catch { /* History may be unavailable in embedded browsers. */ } + }; + state.hasEmailFilters = () => !!(state.emailState || state.emailKind || appliedSearch || state.emailPeriod !== "7d"); + state.emailVisibleRows = () => state.emailRows.slice((state.emailPage - 1) * 25, state.emailPage * 25); + state.emailTotal = () => state.emailSummary ? (state.emailState ? state.emailSummary.counts[state.emailState] : state.emailSummary.total) : null; + state.emailPageCount = () => state.emailTotal() == null ? null : Math.max(1, Math.ceil(state.emailTotal() / 25)); + state.emailDayTotal = (day) => statuses.reduce((sum, key) => sum + (Number(day[key]) || 0), 0); + state.emailChartTotal = () => (state.emailSummary?.series || []).reduce((total, day) => total + state.emailDayTotal(day), 0); + state.jumpToEmailHistory = () => { const heading = browser?.document?.querySelector("#email-history-title"); if (heading) { heading.focus({ preventScroll: true }); heading.scrollIntoView({ block: "start" }); } }; + state.emailChartMax = () => Math.max(1, ...(state.emailSummary?.series || []).map(state.emailDayTotal)); + state.emailDayLabel = (day) => { + const value = typeof day === "string" ? day : day?.date; + if (!value) return ""; + const date = new Date(value + "T12:00:00Z"); + return Number.isNaN(date.getTime()) ? "" : date.toLocaleDateString(undefined, { month: "short", day: "numeric", timeZone: "UTC" }); + }; + const changePage = (page) => { + state.emailPage = page; state.selectedEmailId = null; pendingPage = null; + const start = (page - 1) * 25 + 1, end = Math.min(page * 25, state.emailRows.length); + state.emailAnnouncement = `Page ${page}. Showing attempts ${start} to ${end}.`; + const heading = browser?.document?.querySelector("#email-history-title"); + if (heading) { + heading.setAttribute("tabindex", "-1"); + heading.focus({ preventScroll: true }); + heading.scrollIntoView({ block: "start", behavior: "auto" }); + } + }; + state.loadEmailSummary = async () => { + const filter = JSON.stringify(params()); + if (filter !== lastSummaryFilters) state.emailSummary = null; + lastSummaryFilters = filter; + const current = ++summaryGeneration; + state.emailSummaryLoading = true; state.emailSummaryError = ""; + try { + const response = await http.get("/api/admin/emails/summary", { params: params() }); + if (current === summaryGeneration) state.emailSummary = response.data; + } catch { + if (current === summaryGeneration) state.emailSummaryError = state.emailSummary ? "Could not refresh the summary. Previously loaded totals are still shown." : "Email summary is unavailable."; + } finally { if (current === summaryGeneration) state.emailSummaryLoading = false; } + }; state.retryEmails = () => state.loadEmails(failedMore); state.loadEmails = async (more = false) => { - const filters = JSON.stringify([state.emailState, state.emailKind]); + const filters = JSON.stringify([state.emailState, state.emailKind, state.emailPeriod, appliedSearch]); const changed = filters !== lastFilters; lastFilters = filters; if (changed) more = false; if (more && (state.emailLoading || !state.emailNextCursor)) return; const current = ++generation; - state.emailLoading = true; - state.emailError = ""; + state.emailLoading = true; state.emailError = ""; state.emailAnnouncement = more ? "Loading older emails." : "Loading email history."; - if (changed) { state.emailRows = []; state.emailNextCursor = null; } + if (changed) { state.emailRows = []; state.emailNextCursor = null; state.emailPage = 1; state.selectedEmailId = null; pendingPage = null; } + if (!more) pendingPage = null; + persist(); try { - const response = await http.get("/api/admin/emails", { params: { - state: state.emailState || undefined, kind: state.emailKind || undefined, - before: more ? state.emailNextCursor : undefined, - } }); + const response = await http.get("/api/admin/emails", { params: { ...params(), state: state.emailState || undefined, before: more ? state.emailNextCursor : undefined } }); if (current !== generation) return; state.emailRows = more ? state.emailRows.concat(response.data.entries) : response.data.entries; state.emailNextCursor = response.data.nextCursor; - state.emailAnnouncement = `Email history loaded. ${state.emailRows.length} attempts shown.`; + if (!more) state.emailPage = 1; + state.emailUpdated = new Date().toISOString(); + state.emailAnnouncement = `Email history loaded. ${state.emailRows.length} attempts loaded.`; + if (more && pendingPage && state.emailRows.length > (pendingPage - 1) * 25) changePage(pendingPage); + return true; } catch { if (current === generation) { failedMore = more; @@ -2478,5 +2562,27 @@ export const emailsAdminController = function (state, http, location) { } } finally { if (current === generation) state.emailLoading = false; } }; - state.loadEmails(); + state.emailPreviousPage = () => { if (!state.emailLoading && state.emailPage > 1) changePage(state.emailPage - 1); }; + state.emailNextPage = async () => { + if (state.emailLoading) return; + const target = state.emailPage + 1; + const filter = lastFilters; + if (state.emailRows.length <= (target - 1) * 25 && state.emailNextCursor) { + pendingPage = target; + await state.loadEmails(true); + } + if (!disposed && filter === lastFilters && state.emailPage !== target && state.emailRows.length > (target - 1) * 25) changePage(target); + }; + state.refreshEmails = () => Promise.all([state.loadEmails(), state.loadEmailSummary()]); + state.applyEmailFilters = () => { appliedSearch = state.emailSearch.trim(); return state.refreshEmails(); }; + state.setEmailStatus = (value) => { state.emailState = statuses.includes(value) ? value : ""; return state.loadEmails(); }; + state.clearEmailFilters = () => { state.emailState = ""; state.emailKind = ""; state.emailSearch = ""; state.emailPeriod = "7d"; return state.applyEmailFilters(); }; + let navTimer; + if (browser?.setTimeout) navTimer = browser.setTimeout(() => { + const nav = browser.document?.querySelector(".emails-page .admin-nav"); + const active = nav?.querySelector('[aria-current="page"]'); + if (nav && active) nav.scrollLeft = Math.max(0, active.offsetLeft - nav.offsetLeft - (nav.clientWidth - active.offsetWidth) / 2); + }, 0); + state.on("dispose", () => { disposed = true; generation++; summaryGeneration++; if (navTimer != null) browser.clearTimeout(navTimer); }); + state.refreshEmails(); }; diff --git a/public/script/vendor.min.js b/public/script/vendor.min.js index 3c1a36e..4ea9e1d 100644 --- a/public/script/vendor.min.js +++ b/public/script/vendor.min.js @@ -1,52 +1,52 @@ -"use strict";(()=>{var el=Object.defineProperty;var tl=e=>{throw TypeError(e)};var of=(e,t,s)=>t in e?el(e,t,{enumerable:!0,configurable:!0,writable:!0,value:s}):e[t]=s;var rf=(e,t)=>{for(var s in t)el(e,s,{get:t[s],enumerable:!0})};var xe=(e,t,s)=>of(e,typeof t!="symbol"?t+"":t,s),mr=(e,t,s)=>t.has(e)||tl("Cannot "+s);var re=(e,t,s)=>(mr(e,t,"read from private field"),s?s.call(e):t.get(e)),qe=(e,t,s)=>t.has(e)?tl("Cannot add the same private member more than once"):t instanceof WeakSet?t.add(e):t.set(e,s),$e=(e,t,s,i)=>(mr(e,t,"write to private field"),i?i.call(e,s):t.set(e,s),s),_e=(e,t,s)=>(mr(e,t,"access private method"),s);var nl=(e,t,s,i)=>({set _(o){$e(e,t,o,s)},get _(){return re(e,t,i)}});var me=["abap","abc","actionscript","ada","alda","apache_conf","apex","applescript","aql","asciidoc","asl","assembly_x86","autohotkey","batchfile","c9search","c_cpp","cirru","clojure","cobol","coffee","coldfusion","crystal","csharp","csound_document","csound_orchestra","csound_score","csp","css","curly","d","dart","diff","django","dockerfile","dot","drools","edifact","eiffel","ejs","elixir","elm","erlang","forth","fortran","fsharp","fsl","ftl","gcode","gherkin","gitignore","glsl","gobstones","golang","graphqlschema","groovy","haml","handlebars","haskell","haskell_cabal","haxe","hjson","html","html_elixir","html_ruby","ini","io","jack","jade","java","javascript","json","json5","jsoniq","jsp","jssm","jsx","julia","kotlin","latex","less","liquid","lisp","livescript","logiql","logtalk","lsl","lua","luapage","lucene","makefile","markdown","mask","matlab","maze","mediawiki","mel","mixal","mushcode","mysql","nginx","nim","nix","nsis","nunjucks","objectivec","ocaml","pascal","perl","perl6","pgsql","php","php_laravel_blade","pig","plain_text","powershell","praat","prisma","prolog","properties","protobuf","puppet","python","qml","r","razor","rdoc","red","redshift","rhtml","rst","ruby","rust","sass","scad","scala","scheme","scss","sh","sjs","slim","smarty","snippets","soy_template","space","sparql","sql","sqlserver","stylus","svg","swift","tcl","terraform","tex","text","textile","toml","tsx","turtle","twig","typescript","vala","vbscript","velocity","verilog","vhdl","visualforce","wollok","xml","xquery","yaml","zeek"];var ge={markdown:"/script/markdown.6c8dfb7b1d.min.js",org:"/script/org.f61f262915.min.js",notebook:"/script/notebook.c3144c18ae.min.js",pdf:"/script/pdf.4d9cc6ff49.min.js",editor:"/script/editor.4f142d3adc.min.js"};function sl(e){let t=e.location.hash.slice(1);if(e.history.replaceState(null,"","/review-link"),t.length>2048)return null;let s=new URLSearchParams(t);if([...s.keys()].length!==3||[...s.keys()].some(d=>!["clientId","intentId","token"].includes(d)))return null;let i=s.get("clientId"),o=s.get("intentId"),r=s.get("token");return!/^[a-f0-9]{32}$/.test(i||"")||!/^[a-f0-9]{32}$/.test(o||"")||!/^[a-f0-9]{64}$/.test(r||"")?null:{contract:"4open.artifacts/1",clientId:i,intentId:o,token:r}}function ol(e,t){let{http:s,promises:i,window:o}=t,r=t.takeReviewHandoff(),d=r?{clientId:r.clientId,intentId:r.intentId}:null,p,u,y,m,b,h=!0,w,R=i.defer(),S=()=>[...o.crypto.getRandomValues(new Uint8Array(16))].map(V=>V.toString(16).padStart(2,"0")).join("");Object.assign(e,{repositoryId:"",handoffEnabled:!1,busy:!1,preview:null,acceptAccess:!1,acceptRetention:!1,uncertain:!1,saved:!1,expired:!1,error:r?"":"Open a new artifact link from your submission. This link is missing or invalid."});let N=()=>h&&e.user?.username===b;function v(){h=!1,r=p=u=void 0,R.resolve(),o.clearTimeout(w)}e.on("dispose",v),e.on("routeLeave",v),e.watch(()=>e.user?.username,V=>{!b&&V?b=V:b&&V!==b&&(v(),e.preview=null,e.repositoryId="",e.busy=!1,e.saved=!1,e.handoffEnabled=!1,e.error="Your account changed. Open a new artifact link from your submission.")});let E=()=>({timeout:R.promise,headers:{"Content-Type":"application/json","X-Review-CSRF":u}}),M=V=>V?.status===404?"Artifact linking is not available on this server.":V?.status===401?"Sign in, then open a new artifact link from your submission.":V?.status===403?"This account cannot approve this repository or this link.":"The request could not be completed. You can retry from this page.";e.loadPreview=async()=>{if(!h||!r||e.busy||e.uncertain||e.saved||!e.user?.username)return;b=e.user.username;let V=e.repositoryId.trim();if(!/^[A-Za-z0-9_-]{3,128}$/.test(V)){e.error="Enter the anonymous repository ID from its URL.";return}e.busy=!0,e.error="",e.preview=null,p=void 0,e.acceptAccess=e.acceptRetention=!1,e.expired=!1,o.clearTimeout(w),m||(m=S());try{let _=(await s.get("/api/review-consent/csrf",{timeout:R.promise})).data;if(!N())return;if(u=_.csrf,e.handoffEnabled=_.handoffEnabled===!0,!/^[a-f0-9]{64}$/.test(u||""))throw new Error("invalid_csrf");let G=(await s.post("/api/review-consent/preview",{repositoryId:V,intent:{...r,requestId:m}},E())).data;if(!N())return;if(!G||typeof G.ticket!="string"||!G.ticket||G.ticket.length>8192||typeof G.repositoryName!="string"||!["restricted-review","anonymous-link"].includes(G.policy?.access)||!Number.isSafeInteger(G.policy.version)||!Number.isFinite(Date.parse(G.policy.retainUntil))||!Number.isFinite(Date.parse(G.expiresAt))||Date.parse(G.expiresAt)<=Date.now()||Date.parse(G.expiresAt)>Date.now()+6e5)throw new Error("invalid_preview");p=G.ticket,y=S(),e.preview={repositoryName:G.repositoryName,policy:{...G.policy},expiresAt:G.expiresAt},w=o.setTimeout(()=>{h&&(e.expired=!0)},Math.max(0,Date.parse(G.expiresAt)-Date.now()))}catch(_){N()&&(e.error=M(_))}finally{N()&&(e.busy=!1)}},e.confirmConsent=async()=>{if(!(!N()||e.busy||e.saved||!p||!e.acceptAccess||!e.acceptRetention)){if(Date.parse(e.preview.expiresAt)<=Date.now()){e.expired=!0;return}e.busy=!0,e.error="";try{let V=(await s.post("/api/review-consent/confirm",{ticket:p,requestId:y,acceptAccess:!0,acceptRetention:!0},E())).data;if(!N())return;if(V?.requestId!==y||!Number.isFinite(Date.parse(V.confirmedAt)))throw new Error("invalid_receipt");e.saved=!0,e.uncertain=!1,r=void 0,e.handoffEnabled||(p=void 0)}catch{N()&&(e.uncertain=!0,e.error="The confirmation was not verified. Retry with the same approval, or return to your submission to check its status.")}finally{N()&&(e.busy=!1)}}},e.continueReview=async()=>{if(!N()||e.busy||!e.saved||!e.handoffEnabled||!p||!d)return;e.busy=!0,e.error="";let V,_=()=>{V?.remove(),o.removeEventListener("securitypolicyviolation",G)},G=te=>{te.violatedDirective?.startsWith("form-action")&&(_(),N()&&(e.busy=!1,e.error="The return address was blocked. Return to your submission to check the artifact status."))};try{let te=(await s.post("/api/review-consent/handoff",{ticket:p},E())).data;if(!N())return;let X=te?.completion,O=new URL(te?.callbackUrl);if(!X||Object.keys(X).sort().join(",")!=="clientId,code,contract,expiresAt,intentId"||X.contract!=="4open.artifacts/1"||X.clientId!==d.clientId||X.intentId!==d.intentId||!/^[a-f0-9]{64}$/.test(X.code||"")||!Number.isFinite(Date.parse(X.expiresAt))||Date.parse(X.expiresAt)<=Date.now()||Date.parse(X.expiresAt)>Date.now()+3e5||O.protocol!=="https:"||O.href!==te.callbackUrl||O.username||O.password||te.callbackUrl.includes("?")||te.callbackUrl.includes("#"))throw new Error("invalid_handoff");V=o.document.createElement("form"),V.method="POST",V.action=O.href;let U=o.document.createElement("input");U.type="hidden",U.name="completion",U.value=JSON.stringify(X),V.appendChild(U),o.document.body.appendChild(V),o.addEventListener("securitypolicyviolation",G),e.on("dispose",_),V.submit()}catch{_(),N()&&(e.busy=!1,e.error="The return to review could not be prepared. Retry from this page, or return to your submission to check its status.")}}}var ti=new Map,df=ge;function Jn(e){if(!ti.has(e)){let t=document.createElement("script");t.src=df[e];let s=new Promise((i,o)=>{t.onload=i,t.onerror=()=>{ti.delete(e),t.remove(),o(new Error(`Unable to load ${e}. Please retry.`))}});ti.set(e,s),document.head.appendChild(t)}return ti.get(e)}async function ni(){await Jn("editor"),ace.config.set("basePath","/script/external/ace/")}function Ns(e){let t=Object.create(null);for(let s of e.split(","))t[s]=1;return s=>s in t}var Ze={},In=[],Tt=()=>{},vr=()=>!1,Rs=e=>e.charCodeAt(0)===111&&e.charCodeAt(1)===110&&(e.charCodeAt(2)>122||e.charCodeAt(2)<97),As=e=>e.startsWith("onUpdate:"),ct=Object.assign,eo=(e,t)=>{let s=e.indexOf(t);s>-1&&e.splice(s,1)},uf=Object.prototype.hasOwnProperty,je=(e,t)=>uf.call(e,t),Ne=Array.isArray,yn=e=>to(e)==="[object Map]",Xt=e=>to(e)==="[object Set]",il=e=>to(e)==="[object Date]";var Te=e=>typeof e=="function",it=e=>typeof e=="string",_t=e=>typeof e=="symbol",Ye=e=>e!==null&&typeof e=="object",yr=e=>(Ye(e)||Te(e))&&Te(e.then)&&Te(e.catch),dl=Object.prototype.toString,to=e=>dl.call(e),br=e=>to(e).slice(8,-1),si=e=>to(e)==="[object Object]",oi=e=>it(e)&&e!=="NaN"&&e[0]!=="-"&&""+parseInt(e,10)===e,Ps=Ns(",key,ref,ref_for,ref_key,onVnodeBeforeMount,onVnodeMounted,onVnodeBeforeUpdate,onVnodeUpdated,onVnodeBeforeUnmount,onVnodeUnmounted");var ii=e=>{let t=Object.create(null);return(s=>t[s]||(t[s]=e(s)))},cf=/-\w/g,ht=ii(e=>e.replace(cf,t=>t.slice(1).toUpperCase())),pf=/\B([A-Z])/g,on=ii(e=>e.replace(pf,"-$1").toLowerCase()),Qn=ii(e=>e.charAt(0).toUpperCase()+e.slice(1)),no=ii(e=>e?`on${Qn(e)}`:""),Ht=(e,t)=>!Object.is(e,t),Ds=(e,...t)=>{for(let s=0;s{Object.defineProperty(e,t,{configurable:!0,enumerable:!1,writable:i,value:s})},Ts=e=>{let t=parseFloat(e);return isNaN(t)?e:t};var rl,so=()=>rl||(rl=typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:typeof global<"u"?global:{});function Ie(e){if(Ne(e)){let t={};for(let s=0;ss.startsWith("/*")?"":s).split(ff).forEach(s=>{if(s){let i=s.split(hf);i.length>1&&(t[i[0].trim()]=i[1].trim())}}),t}function A(e){let t="";if(it(e))t=e;else if(Ne(e))for(let s=0;sJt(s,t))}var pl=e=>!!(e&&e.__v_isRef===!0),c=e=>it(e)?e:e==null?"":Ne(e)||Ye(e)&&(e.toString===dl||!Te(e.toString))?pl(e)?c(e.value):JSON.stringify(e,fl,2):String(e),fl=(e,t)=>pl(t)?fl(e,t.value):yn(t)?{[`Map(${t.size})`]:[...t.entries()].reduce((s,[i,o],r)=>(s[gr(i,r)+" =>"]=o,s),{})}:Xt(t)?{[`Set(${t.size})`]:[...t.values()].map(s=>gr(s))}:_t(t)?gr(t):Ye(t)&&!Ne(t)&&!si(t)?String(t):t,gr=(e,t="")=>{var s;return _t(e)?`Symbol(${(s=e.description)!=null?s:t})`:e};function wf(e,...t){console.warn(`[Vue warn] ${e}`,...t)}var mt,ao=class{constructor(t=!1){this.detached=t,this._active=!0,this._on=0,this.effects=[],this.cleanups=[],this._isPaused=!1,this._warnOnRun=!0,this.__v_skip=!0,!t&&mt&&(mt.active?(this.parent=mt,this.index=(mt.scopes||(mt.scopes=[])).push(this)-1):(this._active=!1,this._warnOnRun=!1))}get active(){return this._active}pause(){if(this._active){this._isPaused=!0;let t,s;if(this.scopes){let i=this.scopes.slice();for(t=0,s=i.length;t0&&--this._on===0){if(mt===this)mt=this.prevScope;else{let t=mt;for(;t;){if(t.prevScope===this){t.prevScope=this.prevScope;break}t=t.prevScope}}this.prevScope=void 0}}stop(t){if(this._active){this._active=!1;let s,i;for(s=0,i=this.effects.length;s0)return;if(ro){let t=ro;for(ro=void 0;t;){let s=t.next;t.next=void 0,t.flags&=-9,t=s}}let e;for(;io;){let t=io;for(io=void 0;t;){let s=t.next;if(t.next=void 0,t.flags&=-9,t.flags&1)try{t.trigger()}catch(i){e||(e=i)}t=s}}if(e)throw e}function wl(e){for(let t=e.deps;t;t=t.nextDep)t.version=-1,t.prevActiveLink=t.dep.activeLink,t.dep.activeLink=t}function kl(e){let t,s=e.depsTail,i=s;for(;i;){let o=i.prevDep;i.version===-1?(i===s&&(s=o),Mr(i),kf(i)):t=i,i.dep.activeLink=i.prevActiveLink,i.prevActiveLink=void 0,i=o}e.deps=t,e.depsTail=s}function Er(e){for(let t=e.deps;t;t=t.nextDep)if(t.dep.version!==t.version||t.dep.computed&&(Cl(t.dep.computed)||t.dep.version!==t.version))return!0;return!!e._dirty}function Cl(e){if(e.flags&4&&!(e.flags&16)||(e.flags&=-17,e.globalVersion===lo)||(e.globalVersion=lo,!e.isSSR&&e.flags&128&&(!e.deps&&!e._dirty||!Er(e))))return;e.flags|=2;let t=e.dep,s=nt,i=Qt;nt=e,Qt=!0;try{wl(e);let o=e.fn(e._value);(t.version===0||Ht(o,e._value))&&(e.flags|=128,e._value=o,t.version++)}catch(o){throw t.version++,o}finally{nt=s,Qt=i,kl(e),e.flags&=-3}}function Mr(e,t=!1){let{dep:s,prevSub:i,nextSub:o}=e;if(i&&(i.nextSub=o,e.prevSub=void 0),o&&(o.prevSub=i,e.nextSub=void 0),s.subs===e&&(s.subs=i,!i&&s.computed)){s.computed.flags&=-5;for(let r=s.computed.deps;r;r=r.nextDep)Mr(r,!0)}!t&&!--s.sc&&s.map&&s.map.delete(s.key)}function kf(e){let{prevDep:t,nextDep:s}=e;t&&(t.nextDep=s,e.prevDep=void 0),s&&(s.prevDep=t,e.nextDep=void 0)}var Qt=!0,El=[];function Zt(){El.push(Qt),Qt=!1}function xt(){let e=El.pop();Qt=e===void 0?!0:e}function hl(e){let{cleanup:t}=e;if(e.cleanup=void 0,t){let s=nt;nt=void 0;try{t()}finally{nt=s}}}var lo=0,Sr=class{constructor(t,s){this.sub=t,this.dep=s,this.version=s.version,this.nextDep=this.prevDep=this.nextSub=this.prevSub=this.prevActiveLink=void 0}},uo=class{constructor(t){this.computed=t,this.version=0,this.activeLink=void 0,this.subs=void 0,this.map=void 0,this.key=void 0,this.sc=0,this.__v_skip=!0}track(t){if(!nt||!Qt||nt===this.computed)return;let s=this.activeLink;if(s===void 0||s.sub!==nt)s=this.activeLink=new Sr(nt,this),nt.deps?(s.prevDep=nt.depsTail,nt.depsTail.nextDep=s,nt.depsTail=s):nt.deps=nt.depsTail=s,Sl(s);else if(s.version===-1&&(s.version=this.version,s.nextDep)){let i=s.nextDep;i.prevDep=s.prevDep,s.prevDep&&(s.prevDep.nextDep=i),s.prevDep=nt.depsTail,s.nextDep=void 0,nt.depsTail.nextDep=s,nt.depsTail=s,nt.deps===s&&(nt.deps=i)}return s}trigger(t){this.version++,lo++,this.notify(t)}notify(t){Or();try{for(let s=this.subs;s;s=s.prevSub)s.sub.notify()&&s.sub.dep.notify()}finally{Ir()}}};function Sl(e){if(e.dep.sc++,e.sub.flags&4){let t=e.dep.computed;if(t&&!e.dep.subs){t.flags|=20;for(let i=t.deps;i;i=i.nextDep)Sl(i)}let s=e.dep.subs;s!==e&&(e.prevSub=s,s&&(s.nextSub=e)),e.dep.subs=e}}var Nr=new WeakMap,xn=Symbol(""),Rr=Symbol(""),co=Symbol("");function Et(e,t,s){if(Qt&&nt){let i=Nr.get(e);i||Nr.set(e,i=new Map);let o=i.get(s);o||(i.set(s,o=new uo),o.map=i,o.key=s),o.track()}}function an(e,t,s,i,o,r){let d=Nr.get(e);if(!d){lo++;return}let p=u=>{u&&u.trigger()};if(Or(),t==="clear")d.forEach(p);else{let u=Ne(e),y=u&&oi(s);if(u&&s==="length"){let m=Number(i);d.forEach((b,h)=>{(h==="length"||h===co||!_t(h)&&h>=m)&&p(b)})}else switch((s!==void 0||d.has(void 0))&&p(d.get(s)),y&&p(d.get(co)),t){case"add":u?y&&p(d.get("length")):(p(d.get(xn)),yn(e)&&p(d.get(Rr)));break;case"delete":u||(p(d.get(xn)),yn(e)&&p(d.get(Rr)));break;case"set":yn(e)&&p(d.get(xn));break}}Ir()}function Os(e){let t=We(e);return t===e||(Et(t,"iterate",co),Ot(e))?t:jt(e)?dn(e)?t.map(s=>wn(Lt(s))):t.map(wn):t.map(Lt)}function po(e){return Et(e=We(e),"iterate",co),e}function rn(e,t){return jt(e)?wn(dn(e)?Lt(t):t):Lt(t)}var Cf={__proto__:null,[Symbol.iterator](){return kr(this,Symbol.iterator,e=>rn(this,e))},concat(...e){return Os(this).concat(...e.map(t=>Ne(t)?Os(t):t))},entries(){return kr(this,"entries",e=>(e[1]=rn(this,e[1]),e))},every(e,t){return bn(this,"every",e,t,void 0,arguments)},filter(e,t){return bn(this,"filter",e,t,s=>s.map(i=>rn(this,i)),arguments)},find(e,t){return bn(this,"find",e,t,s=>rn(this,s),arguments)},findIndex(e,t){return bn(this,"findIndex",e,t,void 0,arguments)},findLast(e,t){return bn(this,"findLast",e,t,s=>rn(this,s),arguments)},findLastIndex(e,t){return bn(this,"findLastIndex",e,t,void 0,arguments)},forEach(e,t){return bn(this,"forEach",e,t,void 0,arguments)},includes(...e){return Cr(this,"includes",e)},indexOf(...e){return Cr(this,"indexOf",e)},join(e){return Os(this).join(e)},lastIndexOf(...e){return Cr(this,"lastIndexOf",e)},map(e,t){return bn(this,"map",e,t,void 0,arguments)},pop(){return oo(this,"pop")},push(...e){return oo(this,"push",e)},reduce(e,...t){return gl(this,"reduce",e,t)},reduceRight(e,...t){return gl(this,"reduceRight",e,t)},shift(){return oo(this,"shift")},some(e,t){return bn(this,"some",e,t,void 0,arguments)},splice(...e){return oo(this,"splice",e)},toReversed(){return Os(this).toReversed()},toSorted(e){return Os(this).toSorted(e)},toSpliced(...e){return Os(this).toSpliced(...e)},unshift(...e){return oo(this,"unshift",e)},values(){return kr(this,"values",e=>rn(this,e))}};function kr(e,t,s){let i=po(e),o=i[t],r=o.call(i);if(i!==e&&!Ot(e)){if(r[Symbol.toStringTag]==="Array Iterator"){let d=Object.create(Object.getPrototypeOf(r));return d.next=()=>ml(r.next(),s),o!==Nl[t]&&Object.defineProperties(d,{return:{get(){let p=r.return;return typeof p=="function"?p.bind(r):p}},throw:{get(){let p=r.throw;return typeof p=="function"?p.bind(r):p}}}),d}r._next=r.next,r.next=()=>ml(r._next(),s)}return r}function ml(e,t){return e.done||(e.value=t(e.value)),e}var Nl=Array.prototype;function bn(e,t,s,i,o,r){let d=po(e),p=d!==e&&!Ot(e),u=d[t];if(u!==Nl[t]){let b=u.apply(e,r);return p?Lt(b):b}let y=s;d!==e&&(p?y=function(b,h){return s.call(this,rn(e,b),h,e)}:s.length>2&&(y=function(b,h){return s.call(this,b,h,e)}));let m=u.call(d,y,i);return p&&o?o(m):m}function gl(e,t,s,i){let o=po(e),r=o!==e&&!Ot(e),d=s,p=!1;o!==e&&(r?(p=i.length===0,d=function(y,m,b){return p&&(p=!1,y=rn(e,y)),s.call(this,y,rn(e,m),b,e)}):s.length>3&&(d=function(y,m,b){return s.call(this,y,m,b,e)}));let u=o[t](d,...i);return p?rn(e,u):u}function Cr(e,t,s){let i=We(e);Et(i,"iterate",co);let o=i[t](...s);return(o===-1||o===!1)&&ho(s[0])?(s[0]=We(s[0]),i[t](...s)):o}function oo(e,t,s=[]){Zt(),Or();let i=We(e)[t].apply(e,s);return Ir(),xt(),i}var Ef=Ns("__proto__,__v_isRef,__isVue"),Rl=new Set(Object.getOwnPropertyNames(Symbol).filter(e=>e!=="arguments"&&e!=="caller").map(e=>Symbol[e]).filter(_t));function Sf(e){_t(e)||(e=String(e));let t=We(this);return Et(t,"has",e),t.hasOwnProperty(e)}var pi=class{constructor(t=!1,s=!1){this._isReadonly=t,this._isShallow=s}get(t,s,i){if(s==="__v_skip")return t.__v_skip;let o=this._isReadonly,r=this._isShallow;if(s==="__v_isReactive")return!o;if(s==="__v_isReadonly")return o;if(s==="__v_isShallow")return r;if(s==="__v_raw")return i===(o?r?Mf:Dl:r?Pl:Al).get(t)||Object.getPrototypeOf(t)===Object.getPrototypeOf(i)?t:void 0;let d=Ne(t);if(!o){let u;if(d&&(u=Cf[s]))return u;if(s==="hasOwnProperty")return Sf}let p=Reflect.get(t,s,wt(t)?t:i);if((_t(s)?Rl.has(s):Ef(s))||(o||Et(t,"get",s),r))return p;if(wt(p)){let u=d&&oi(s)?p:p.value;return o&&Ye(u)?hi(u):u}return Ye(p)?o?hi(p):st(p):p}},fi=class extends pi{constructor(t=!1){super(!1,t)}set(t,s,i,o){let r=t[s],d=Ne(t)&&oi(s);if(!this._isShallow){let y=jt(r);if(!Ot(i)&&!jt(i)&&(r=We(r),i=We(i)),!d&&wt(r)&&!wt(i))return y||(r.value=i),!0}let p=d?Number(s)e,di=e=>Reflect.getPrototypeOf(e);function Pf(e,t,s){return function(...i){let o=this.__v_raw,r=We(o),d=yn(r),p=e==="entries"||e===Symbol.iterator&&d,u=e==="keys"&&d,y=o[e](...i),m=s?Pr:t?wn:Lt;return!t&&Et(r,"iterate",u?Rr:xn),ct(Object.create(y),{next(){let{value:b,done:h}=y.next();return h?{value:b,done:h}:{value:p?[m(b[0]),m(b[1])]:m(b),done:h}}})}}function ui(e){return function(...t){return e==="delete"?!1:e==="clear"?void 0:this}}function Df(e,t){let s={get(o){let r=this.__v_raw,d=We(r),p=We(o);e||(Ht(o,p)&&Et(d,"get",o),Et(d,"get",p));let{has:u}=di(d),y=t?Pr:e?wn:Lt;if(u.call(d,o))return y(r.get(o));if(u.call(d,p))return y(r.get(p));r!==d&&r.get(o)},get size(){let o=this.__v_raw;return!e&&Et(We(o),"iterate",xn),o.size},has(o){let r=this.__v_raw,d=We(r),p=We(o);return e||(Ht(o,p)&&Et(d,"has",o),Et(d,"has",p)),o===p?r.has(o):r.has(o)||r.has(p)},forEach(o,r){let d=this,p=d.__v_raw,u=We(p),y=t?Pr:e?wn:Lt;return!e&&Et(u,"iterate",xn),p.forEach((m,b)=>o.call(r,y(m),y(b),d))}};return ct(s,e?{add:ui("add"),set:ui("set"),delete:ui("delete"),clear:ui("clear")}:{add(o){let r=We(this),d=di(r),p=We(o),u=!t&&!Ot(o)&&!jt(o)?p:o;return d.has.call(r,u)||Ht(o,u)&&d.has.call(r,o)||Ht(p,u)&&d.has.call(r,p)||(r.add(u),an(r,"add",u,u)),this},set(o,r){!t&&!Ot(r)&&!jt(r)&&(r=We(r));let d=We(this),{has:p,get:u}=di(d),y=p.call(d,o);y||(o=We(o),y=p.call(d,o));let m=u.call(d,o);return d.set(o,r),y?Ht(r,m)&&an(d,"set",o,r,m):an(d,"add",o,r),this},delete(o){let r=We(this),{has:d,get:p}=di(r),u=d.call(r,o);u||(o=We(o),u=d.call(r,o));let y=p?p.call(r,o):void 0,m=r.delete(o);return u&&an(r,"delete",o,void 0,y),m},clear(){let o=We(this),r=o.size!==0,d=void 0,p=o.clear();return r&&an(o,"clear",void 0,void 0,d),p}}),["keys","values","entries",Symbol.iterator].forEach(o=>{s[o]=Pf(o,e,t)}),s}function Vr(e,t){let s=Df(e,t);return(i,o,r)=>o==="__v_isReactive"?!e:o==="__v_isReadonly"?e:o==="__v_isShallow"?t:o==="__v_raw"?i:Reflect.get(je(s,o)&&o in i?s:i,o,r)}var Tf={get:Vr(!1,!1)},Of={get:Vr(!1,!0)},If={get:Vr(!0,!1)};var Al=new WeakMap,Pl=new WeakMap,Dl=new WeakMap,Mf=new WeakMap;function Vf(e){switch(e){case"Object":case"Array":return 1;case"Map":case"Set":case"WeakMap":case"WeakSet":return 2;default:return 0}}function st(e){return jt(e)?e:qr(e,!1,Nf,Tf,Al)}function fo(e){return qr(e,!1,Af,Of,Pl)}function hi(e){return qr(e,!0,Rf,If,Dl)}function qr(e,t,s,i,o){if(!Ye(e)||e.__v_raw&&!(t&&e.__v_isReactive)||e.__v_skip||!Object.isExtensible(e))return e;let r=o.get(e);if(r)return r;let d=Vf(br(e));if(d===0)return e;let p=new Proxy(e,d===2?i:s);return o.set(e,p),p}function dn(e){return jt(e)?dn(e.__v_raw):!!(e&&e.__v_isReactive)}function jt(e){return!!(e&&e.__v_isReadonly)}function Ot(e){return!!(e&&e.__v_isShallow)}function ho(e){return e?!!e.__v_raw:!1}function We(e){let t=e&&e.__v_raw;return t?We(t):e}function un(e){return!je(e,"__v_skip")&&Object.isExtensible(e)&&ri(e,"__v_skip",!0),e}var Lt=e=>Ye(e)?st(e):e,wn=e=>Ye(e)?hi(e):e;function wt(e){return e?e.__v_isRef===!0:!1}function St(e){return Tl(e,!1)}function gi(e){return Tl(e,!0)}function Tl(e,t){return wt(e)?e:new Dr(e,t)}var Dr=class{constructor(t,s){this.dep=new uo,this.__v_isRef=!0,this.__v_isShallow=!1,this._rawValue=s?t:We(t),this._value=s?t:Lt(t),this.__v_isShallow=s}get value(){return this.dep.track(),this._value}set value(t){let s=this._rawValue,i=this.__v_isShallow||Ot(t)||jt(t);t=i?t:We(t),Ht(t,s)&&(this._rawValue=t,this._value=i?t:Lt(t),this.dep.trigger())}};function kn(e){return wt(e)?e.value:e}var qf={get:(e,t,s)=>t==="__v_raw"?e:kn(Reflect.get(e,t,s)),set:(e,t,s,i)=>{let o=e[t];return wt(o)&&!wt(s)?(o.value=s,!0):Reflect.set(e,t,s,i)}};function vi(e){return dn(e)?e:new Proxy(e,qf)}var Tr=class{constructor(t,s,i){this.fn=t,this.setter=s,this._value=void 0,this.dep=new uo(this),this.__v_isRef=!0,this.deps=void 0,this.depsTail=void 0,this.flags=16,this.globalVersion=lo-1,this.next=void 0,this.effect=this,this.__v_isReadonly=!s,this.isSSR=i}notify(){if(this.flags|=16,!(this.flags&8)&&nt!==this)return bl(this,!0),!0}get value(){let t=this.dep.track();return Cl(this),t&&(t.version=this.dep.version),this._value}set value(t){this.setter&&this.setter(t)}};function Ol(e,t,s=!1){let i,o;return Te(e)?i=e:(i=e.get,o=e.set),new Tr(i,o,s)}var ci={},mi=new WeakMap,Zn;function Il(e,t=!1,s=Zn){if(s){let i=mi.get(s);i||mi.set(s,i=[]),i.push(e)}}function Ml(e,t,s=Ze){let{immediate:i,deep:o,once:r,scheduler:d,augmentJob:p,call:u}=s,y=_=>{(s.onWarn||wf)("Invalid watch source: ",_,"A watch source can only be a getter/effect function, a ref, a reactive object, or an array of these types.")},m=_=>o?_:Ot(_)||o===!1||o===0?ln(_,1):ln(_),b,h,w,R,S=!1,N=!1;if(wt(e)?(h=()=>e.value,S=Ot(e)):dn(e)?(h=()=>m(e),S=!0):Ne(e)?(N=!0,S=e.some(_=>dn(_)||Ot(_)),h=()=>e.map(_=>{if(wt(_))return _.value;if(dn(_))return m(_);if(Te(_))return u?u(_,2):_()})):Te(e)?t?h=u?()=>u(e,2):e:h=()=>{if(w){Zt();try{w()}finally{xt()}}let _=Zn;Zn=b;try{return u?u(e,3,[R]):e(R)}finally{Zn=_}}:h=Tt,t&&o){let _=h,G=o===!0?1/0:o;h=()=>ln(_(),G)}let v=vl(),E=()=>{b.stop(),v&&v.active&&eo(v.effects,b)};if(r&&t){let _=t;t=(...G)=>{try{return _(...G)}finally{E()}}}let M=N?new Array(e.length).fill(ci):ci,V=_=>{if(!(!(b.flags&1)||!b.dirty&&!_))if(t){let G=b.run();if(_||o||S||(N?G.some((te,X)=>Ht(te,M[X])):Ht(G,M))){let te=Zn;Zt();try{w&&w(),Zn=b;let X=[G,M===ci?void 0:N&&M[0]===ci?[]:M,R];M=G,u?u(t,3,X):t(...X)}finally{Zn=te,xt()}}}else b.run()};return p&&p(V),b=new Is(h),b.scheduler=d?()=>d(V,!1):V,R=_=>Il(_,!1,b),w=b.onStop=()=>{let _=mi.get(b);if(_){if(u)u(_,4);else for(let G of _)G();mi.delete(b)}},t?i?V(!0):M=b.run():d?d(V.bind(null,!0),!0):b.run(),E.pause=b.pause.bind(b),E.resume=b.resume.bind(b),E.stop=E,E}function ln(e,t=1/0,s){if(t<=0||!Ye(e)||e.__v_skip||(s=s||new Map,(s.get(e)||0)>=t))return e;if(s.set(e,t),t--,wt(e))ln(e.value,t,s);else if(Ne(e))for(let i=0;i{ln(i,t,s)});else if(si(e)){for(let i in e)ln(e[i],t,s);for(let i of Object.getOwnPropertySymbols(e))Object.prototype.propertyIsEnumerable.call(e,i)&&ln(e[i],t,s)}return e}function Ro(e,t,s,i){try{return i?e(...i):e()}catch(o){Ao(o,t,s)}}function Gt(e,t,s,i){if(Te(e)){let o=Ro(e,t,s,i);return o&&yr(o)&&o.catch(r=>{Ao(r,t,s)}),o}if(Ne(e)){let o=[];for(let r=0;r>>1,o=Pt[i],r=ko(o);r=ko(s)?Pt.push(e):Pt.splice(Uf(t),0,e),e.flags|=1,Jl()}}function Jl(){wi||(wi=Xl.then(ed))}function Ql(e){if(!Ne(e))Mn&&e.id===-1?Mn.splice(Ms+1,0,e):e.flags&1||(pn.push(e),e.flags|=1);else for(let t=0;t=t))continue;Pt.splice(i,1),i=e?i-1:en,o.flags&4&&(o.flags&=-2),o(),o.flags&4||(o.flags&=-2)}}}function xl(e,t,s=0){if(pn.length){let i=pn,o=0;if(t){i=[];for(let d=0;dko(d)-ko(p));if(pn.length=o,Mn){for(let d=0;de.id==null?e.flags&2?-1:1/0:e.id;function ed(e){let t=Tt;try{for(en=0;en{i._d&&Si(-1);let r=ki(t),d=ss.length,p;try{p=e(...o)}finally{for(let u=ss.length;u>d;u--)Td();ki(r),i._d&&Si(1)}return p};return i._n=!0,i._c=!0,i._d=!0,i}function D(e,t){if($t===null)return e;let s=Ii($t),i=e.dirs||(e.dirs=[]);for(let o=0;o1)return s&&Te(t)?t.call(i&&i.proxy):t}}var Hf=Symbol.for("v-scx"),jf=()=>{{let e=Mt(Hf);return e}};function dt(e,t,s){return nd(e,t,s)}function nd(e,t,s=Ze){let{immediate:i,deep:o,flush:r,once:d}=s,p=ct({},s),u=t&&i||!t&&r!=="post",y;if(_s){if(r==="sync"){let w=jf();y=w.__watcherHandles||(w.__watcherHandles=[])}else if(!u){let w=()=>{};return w.stop=Tt,w.resume=Tt,w.pause=Tt,w}}let m=Nt;p.call=(w,R,S)=>Gt(w,m,R,S);let b=!1;r==="post"?p.scheduler=w=>{w.i=m,It(w,m&&m.suspense)}:r!=="sync"&&(b=!0,p.scheduler=(w,R)=>{R?w():Kr(w)}),p.augmentJob=w=>{t&&(w.flags|=4),b&&(w.flags|=2,m&&(w.id=m.uid,w.i=m))};let h=Ml(e,t,p);return _s&&(y?y.push(h):u&&h()),h}function Gf(e,t,s){let i=this.proxy,o=it(e)?e.includes(".")?sd(i,e):()=>i[e]:e.bind(i,i),r;Te(t)?r=t:(r=t.handler,s=t);let d=To(this),p=nd(o,r.bind(i),s);return d(),p}function sd(e,t){let s=t.split(".");return()=>{let i=e;for(let o=0;oe.__isTeleport;var Lr=Symbol("_leaveCb");function Kf(e){let t=e[0];if(e.length>1){let s=!1;for(let i of e)if(i.type!==tn){t=i,s=!0;break}}return t}function od(e){if(!Pi(e))return Ai(e.type)&&e.children?Kf(e.children):e;if(e.component)return e.component.subTree;let{shapeFlag:t,children:s}=e;if(s){if(t&16)return s[0];if(t&32&&Te(s.default))return s.default()}}function Co(e,t){if(e.shapeFlag&6&&e.component){e.transition=t;let s=e.component.subTree;Co(Ai(s.type)&&od(s)||s,t)}else if(e.shapeFlag&128)e.ssContent.transition=t.clone(e.ssContent),e.ssFallback.transition=t.clone(e.ssFallback);else if(e.transition=t,e.type===q&&Ne(e.children)){let s=gd(e.children,!1);s&&Co(s,t)}}function Br(e){if(e.component)return Br(e.component.subTree);if(e.type===q){let t=Ne(e.children)&&gd(e.children,!1);return t?Br(t):void 0}if(e.type!==tn)return e}function Po(e,t){return Te(e)?ct({name:e.name},t,{setup:e}):e}function Yr(e){e.ids=[e.ids[0]+e.ids[2]+++"-",0,0]}function Vl(e,t){let s;return!!((s=Object.getOwnPropertyDescriptor(e,t))&&!s.configurable)}var Ci=new WeakMap;function vo(e,t,s,i,o=!1){if(Ne(e)){e.forEach((S,N)=>vo(S,t&&(Ne(t)?t[N]:t),s,i,o));return}if(yo(i)&&!o){i.shapeFlag&512&&i.type.__asyncResolved&&i.component.subTree.component&&vo(e,t,s,i.component.subTree);return}let r=i.shapeFlag&4?Ii(i.component):i.el,d=o?null:r,{i:p,r:u}=e,y=t&&t.r,m=p.refs===Ze?p.refs={}:p.refs,b=p.setupState,h=We(b),w=b===Ze?vr:S=>Vl(m,S)?!1:je(h,S),R=(S,N)=>!(N&&Vl(m,N));if(y!=null&&y!==u){if(ql(t),it(y))m[y]=null,w(y)&&(b[y]=null);else if(wt(y)){let S=t;R(y,S.k)&&(y.value=null),S.k&&(m[S.k]=null)}}if(Te(u))Ro(u,p,12,[d,m]);else{let S=it(u),N=wt(u);if(S||N){let v=()=>{if(e.f){let E=S?w(u)?b[u]:m[u]:R(u)||!e.k?u.value:m[e.k];if(o)Ne(E)&&eo(E,r);else if(Ne(E))E.includes(r)||E.push(r);else if(S)m[u]=[r],w(u)&&(b[u]=m[u]);else{let M=[r];R(u,e.k)&&(u.value=M),e.k&&(m[e.k]=M)}}else S?(m[u]=d,w(u)&&(b[u]=d)):N&&(R(u,e.k)&&(u.value=d),e.k&&(m[e.k]=d))};if(d){let E=()=>{v(),Ci.delete(e)};E.id=-1,Ci.set(e,E),It(E,s)}else ql(e),v()}}}function ql(e){let t=Ci.get(e);t&&(t.flags|=8,Ci.delete(e))}var _l=e=>e.nodeType===8;var XQ=so().requestIdleCallback||(e=>setTimeout(e,1)),JQ=so().cancelIdleCallback||(e=>clearTimeout(e));function Yf(e,t){if(_l(e)&&e.data==="["){let s=1,i=e.nextSibling;for(;i;){if(i.nodeType===1){if(t(i)===!1)break}else if(_l(i))if(i.data==="]"){if(--s===0)break}else i.data==="["&&s++;i=i.nextSibling}}else t(e)}var yo=e=>!!e.type.__asyncLoader;function id(e){Te(e)&&(e={loader:e});let{loader:t,loadingComponent:s,errorComponent:i,delay:o=200,hydrate:r,timeout:d,suspensible:p=!0,onError:u}=e,y=null,m,b=0,h=()=>(b++,y=null,w()),w=()=>{let R;return y||(R=y=t().catch(S=>{if(S=S instanceof Error?S:new Error(String(S)),u)return new Promise((N,v)=>{u(S,()=>N(h()),()=>v(S),b+1)});throw S}).then(S=>R!==y&&y?y:(S&&(S.__esModule||S[Symbol.toStringTag]==="Module")&&(S=S.default),m=S,S)))};return Po({name:"AsyncComponentWrapper",__asyncLoader:w,__asyncHydrate(R,S,N){let v=R.isConnected,E=!1;(S.bu||(S.bu=[])).push(()=>E=!0);let M=()=>{E||!R.parentNode||v&&!R.isConnected||N()},V=r?()=>{let _=r(M,G=>Yf(R,G));_&&(S.bum||(S.bum=[])).push(_)}:M;m?V():w().then(()=>!S.isUnmounted&&V())},get __asyncResolved(){return m},setup(){let R=Nt;if(Yr(R),m)return()=>yi(m,R);let S=_=>{y=null,Ao(_,R,13,!i)};if(p&&R.suspense||_s)return w().then(_=>()=>yi(_,R)).catch(_=>(S(_),()=>i?Oe(i,{error:_}):null));let N=St(!1),v=St(),E=St(!!o),M,V;return Do(()=>{M!=null&&clearTimeout(M),V!=null&&clearTimeout(V)}),o&&(V=setTimeout(()=>{R.isUnmounted||(E.value=!1)},o)),d!=null&&(M=setTimeout(()=>{if(!R.isUnmounted&&!N.value&&!v.value){let _=new Error(`Async component timed out after ${d}ms.`);S(_),v.value=_}},d)),w().then(()=>{R.isUnmounted||(N.value=!0,R.parent&&Pi(R.parent.vnode)&&R.parent.update())}).catch(_=>{if(R.isUnmounted){y=null;return}S(_),v.value=_}),()=>{if(N.value&&m)return yi(m,R);if(v.value&&i)return Oe(i,{error:v.value});if(s&&!E.value)return yi(s,R)}}})}function yi(e,t){let{ref:s,props:i,children:o,ce:r}=t.vnode,d=Oe(e,i,o);return d.ref=s,d.ce=r,delete t.vnode.ce,d}var Pi=e=>e.type.__isKeepAlive;function rd(e,t){ld(e,"a",t)}function ad(e,t){ld(e,"da",t)}function ld(e,t,s=Nt){let i=e.__wdc||(e.__wdc=()=>{let o=s;for(;o;){if(o.isDeactivated)return;o=o.parent}return e()});if(Di(t,i,s),s){let o=s.parent;for(;o&&o.parent;)Pi(o.parent.vnode)&&Xf(i,t,s,o),o=o.parent}}function Xf(e,t,s,i){let o=Di(t,e,i,!0);Do(()=>{eo(i[t],o)},s)}function Di(e,t,s=Nt,i=!1){if(s){let o=s[e]||(s[e]=[]),r=t.__weh||(t.__weh=(...d)=>{Zt();let p=To(s),u=Gt(t,s,e,d);return p(),xt(),u});return i?o.unshift(r):o.push(r),r}}var En=e=>(t,s=Nt)=>{(!_s||e==="sp")&&Di(e,(...i)=>t(...i),s)},Jf=En("bm"),hn=En("m"),dd=En("bu"),ud=En("u"),is=En("bum"),Do=En("um"),Qf=En("sp"),Zf=En("rtg"),xf=En("rtc");function eh(e,t=Nt){Di("ec",e,t)}var cd="components",th="directives";function Xe(e,t){return pd(cd,e,!0,t)||e}var nh=Symbol.for("v-ndc");function Pe(e){return pd(th,e)}function pd(e,t,s=!0,i=!1){let o=$t||Nt;if(o){let r=o.type;if(e===cd){let p=Fh(r,!1);if(p&&(p===t||p===ht(t)||p===Qn(ht(t))))return r}let d=Ll(o[e]||r[e],t)||Ll(o.appContext[e],t);return!d&&i?r:d}}function Ll(e,t){return e&&(e[t]||e[ht(t)]||e[Qn(ht(t))])}function Q(e,t,s,i){let o,r=s&&s[i],d=Ne(e);if(d||it(e)){let p=d&&dn(e),u=!1,y=!1;p&&(u=!Ot(e),y=jt(e),e=po(e)),o=new Array(e.length);for(let m=0,b=e.length;mt(p,u,void 0,r&&r[u]));else{let p=Object.keys(e);o=new Array(p.length);for(let u=0,y=p.length;ue?Vd(e)?Ii(e):zr(e.parent):null;var bo=ct(Object.create(null),{$:e=>e,$el:e=>e.vnode.el,$data:e=>e.data,$props:e=>e.props,$attrs:e=>e.attrs,$slots:e=>e.slots,$refs:e=>e.refs,$parent:e=>zr(e.parent),$root:e=>zr(e.root),$host:e=>e.ce,$emit:e=>e.emit,$options:e=>Xr(e),$forceUpdate:e=>e.f||(e.f=()=>{Kr(e.update)}),$nextTick:e=>e.n||(e.n=tt.bind(e.proxy)),$watch:e=>Gf.bind(e)});var $r=(e,t)=>e!==Ze&&!e.__isScriptSetup&&je(e,t),sh={get({_:e},t){if(t==="__v_skip")return!0;let{ctx:s,setupState:i,data:o,props:r,accessCache:d,type:p,appContext:u}=e;if(t[0]!=="$"){let h=d[t];if(h!==void 0)switch(h){case 1:return i[t];case 2:return o[t];case 4:return s[t];case 3:return r[t]}else{if($r(i,t))return d[t]=1,i[t];if(o!==Ze&&je(o,t))return d[t]=2,o[t];if(je(r,t))return d[t]=3,r[t];if(s!==Ze&&je(s,t))return d[t]=4,s[t];Hr&&(d[t]=0)}}let y=bo[t],m,b;if(y)return t==="$attrs"&&Et(e.attrs,"get",""),y(e);if((m=p.__cssModules)&&(m=m[t]))return m;if(s!==Ze&&je(s,t))return d[t]=4,s[t];if(b=u.config.globalProperties,je(b,t))return b[t]},set({_:e},t,s){let{data:i,setupState:o,ctx:r}=e;return $r(o,t)?(o[t]=s,!0):i!==Ze&&je(i,t)?(i[t]=s,!0):je(e.props,t)||t[0]==="$"&&t.slice(1)in e?!1:(r[t]=s,!0)},has({_:{data:e,setupState:t,accessCache:s,ctx:i,appContext:o,props:r,type:d}},p){let u;return!!(s[p]||e!==Ze&&p[0]!=="$"&&je(e,p)||$r(t,p)||je(r,p)||je(i,p)||je(bo,p)||je(o.config.globalProperties,p)||(u=d.__cssModules)&&u[p])},defineProperty(e,t,s){return s.get!=null?e._.accessCache[t]=0:je(s,"value")&&this.set(e,t,s.value,null),Reflect.defineProperty(e,t,s)}};function $l(e){return Ne(e)?e.reduce((t,s)=>(t[s]=null,t),{}):e}var Hr=!0;function oh(e){let t=Xr(e),s=e.proxy,i=e.ctx;Hr=!1,t.beforeCreate&&Fl(t.beforeCreate,e,"bc");let{data:o,computed:r,methods:d,watch:p,provide:u,inject:y,created:m,beforeMount:b,mounted:h,beforeUpdate:w,updated:R,activated:S,deactivated:N,beforeDestroy:v,beforeUnmount:E,destroyed:M,unmounted:V,render:_,renderTracked:G,renderTriggered:te,errorCaptured:X,serverPrefetch:O,expose:U,inheritAttrs:C,components:L,directives:z,filters:K}=t;if(y&&ih(y,i,null),d)for(let Y in d){let he=d[Y];Te(he)&&(i[Y]=he.bind(s))}if(o){let Y=o.call(s,s);Ye(Y)&&(e.data=st(Y))}if(Hr=!0,r)for(let Y in r){let he=r[Y],Se=Te(he)?he.bind(s,s):Te(he.get)?he.get.bind(s,s):Tt,Ue=!Te(he)&&Te(he.set)?he.set.bind(s):Tt,Be=Rt({get:Se,set:Ue});Object.defineProperty(i,Y,{enumerable:!0,configurable:!0,get:()=>Be.value,set:Qe=>Be.value=Qe})}if(p)for(let Y in p)fd(p[Y],i,s,Y);if(u){let Y=Te(u)?u.call(s):u;Reflect.ownKeys(Y).forEach(he=>{os(he,Y[he])})}m&&Fl(m,e,"c");function se(Y,he){Ne(he)?he.forEach(Se=>Y(Se.bind(s))):he&&Y(he.bind(s))}if(se(Jf,b),se(hn,h),se(dd,w),se(ud,R),se(rd,S),se(ad,N),se(eh,X),se(xf,G),se(Zf,te),se(is,E),se(Do,V),se(Qf,O),Ne(U))if(U.length){let Y=e.exposed||(e.exposed={});U.forEach(he=>{Object.defineProperty(Y,he,{get:()=>s[he],set:Se=>s[he]=Se,enumerable:!0})})}else e.exposed||(e.exposed={});_&&e.render===Tt&&(e.render=_),C!=null&&(e.inheritAttrs=C),L&&(e.components=L),z&&(e.directives=z),O&&Yr(e)}function ih(e,t,s=Tt){Ne(e)&&(e=jr(e));for(let i in e){let o=e[i],r;Ye(o)?"default"in o?r=Mt(o.from||i,o.default,!0):r=Mt(o.from||i):r=Mt(o),wt(r)?Object.defineProperty(t,i,{enumerable:!0,configurable:!0,get:()=>r.value,set:d=>r.value=d}):t[i]=r}}function Fl(e,t,s){Gt(Ne(e)?e.map(i=>i.bind(t.proxy)):e.bind(t.proxy),t,s)}function fd(e,t,s,i){let o=i.includes(".")?sd(s,i):()=>s[i];if(it(e)){let r=t[e];Te(r)&&dt(o,r)}else if(Te(e))dt(o,e.bind(s));else if(Ye(e))if(Ne(e))e.forEach(r=>fd(r,t,s,i));else{let r=Te(e.handler)?e.handler.bind(s):t[e.handler];Te(r)&&dt(o,r,e)}}function Xr(e){let t=e.type,{mixins:s,extends:i}=t,{mixins:o,optionsCache:r,config:{optionMergeStrategies:d}}=e.appContext,p=r.get(t),u;return p?u=p:!o.length&&!s&&!i?u=t:(u={},o.length&&o.forEach(y=>Ei(u,y,d,!0)),Ei(u,t,d)),Ye(t)&&r.set(t,u),u}function Ei(e,t,s,i=!1){let{mixins:o,extends:r}=t;r&&Ei(e,r,s,!0),o&&o.forEach(d=>Ei(e,d,s,!0));for(let d in t)if(!(i&&d==="expose")){let p=rh[d]||s&&s[d];e[d]=p?p(e[d],t[d]):t[d]}return e}var rh={data:Ul,props:Bl,emits:Bl,methods:go,computed:go,beforeCreate:At,created:At,beforeMount:At,mounted:At,beforeUpdate:At,updated:At,beforeDestroy:At,beforeUnmount:At,destroyed:At,unmounted:At,activated:At,deactivated:At,errorCaptured:At,serverPrefetch:At,components:go,directives:go,watch:lh,provide:Ul,inject:ah};function Ul(e,t){return t?e?function(){return ct(Te(e)?e.call(this,this):e,Te(t)?t.call(this,this):t)}:t:e}function ah(e,t){return go(jr(e),jr(t))}function jr(e){if(Ne(e)){let t={};for(let s=0;st==="modelValue"||t==="model-value"?e.modelModifiers:e[`${t}Modifiers`]||e[`${ht(t)}Modifiers`]||e[`${on(t)}Modifiers`];function ph(e,t,...s){if(e.isUnmounted)return;let i=e.vnode.props||Ze,o=s,r=t.startsWith("update:"),d=r&&ch(i,t.slice(7));d&&(d.trim&&(o=s.map(m=>it(m)?m.trim():m)),d.number&&(o=o.map(Ts)));let p,u=i[p=no(t)]||i[p=no(ht(t))];!u&&r&&(u=i[p=no(on(t))]),u&&Gt(u,e,6,o);let y=i[p+"Once"];if(y){if(!e.emitted)e.emitted={};else if(e.emitted[p])return;e.emitted[p]=!0,Gt(y,e,6,o)}}var fh=new WeakMap;function md(e,t,s=!1){let i=s?fh:t.emitsCache,o=i.get(e);if(o!==void 0)return o;let r=e.emits,d={},p=!1;if(!Te(e)){let u=y=>{let m=md(y,t,!0);m&&(p=!0,ct(d,m))};!s&&t.mixins.length&&t.mixins.forEach(u),e.extends&&u(e.extends),e.mixins&&e.mixins.forEach(u)}return!r&&!p?(Ye(e)&&i.set(e,null),null):(Ne(r)?r.forEach(u=>d[u]=null):ct(d,r),Ye(e)&&i.set(e,d),d)}function Ti(e,t){return!e||!Rs(t)?!1:(t=t.slice(2),t=t==="Once"?t:t.replace(/Once$/,""),je(e,t[0].toLowerCase()+t.slice(1))||je(e,on(t))||je(e,t))}function Fr(e){let{type:t,vnode:s,proxy:i,withProxy:o,propsOptions:[r],slots:d,attrs:p,emit:u,render:y,renderCache:m,props:b,data:h,setupState:w,ctx:R,inheritAttrs:S}=e,N=ki(e),v,E;try{if(s.shapeFlag&4){let _=o||i,G=_;v=fn(y.call(G,_,m,b,w,h,R)),E=p}else{let _=t;v=fn(_.length>1?_(b,{attrs:p,slots:d,emit:u}):_(b,null)),E=t.props?p:hh(p)}}catch(_){ss.length=0,Ao(_,e,1),v=Oe(tn)}let M=v,V;if(E&&S!==!1){let _=Object.keys(E),{shapeFlag:G}=M;_.length&&G&7&&(r&&_.some(As)&&(E=mh(E,r)),M=qs(M,E,!1,!0))}if(s.dirs&&(M=qs(M,null,!1,!0),M.dirs=M.dirs?M.dirs.concat(s.dirs):s.dirs),s.transition){let _=Ai(M.type)&&od(M)||M;Co(_,s.transition)}return v=M,ki(N),v}function gd(e,t=!0){let s;for(let i=0;i{let t;for(let s in e)(s==="class"||s==="style"||Rs(s))&&((t||(t={}))[s]=e[s]);return t},mh=(e,t)=>{let s={};for(let i in e)(!As(i)||!(i.slice(9)in t))&&(s[i]=e[i]);return s};function gh(e,t,s){let{props:i,children:o,component:r}=e,{props:d,children:p,patchFlag:u}=t,y=r.emitsOptions;if(t.dirs||t.transition)return!0;if(s&&u>=0){if(u&1024)return!0;if(u&16)return i?zl(i,d,y):!!d;if(u&8){let m=t.dynamicProps;for(let b=0;bObject.create(yd),wd=e=>Object.getPrototypeOf(e)===yd;function yh(e,t,s,i=!1){let o={},r=bd();e.propsDefaults=Object.create(null),kd(e,t,o,r);for(let d in e.propsOptions[0])d in o||(o[d]=void 0);s?e.props=i?o:fo(o):e.type.props?e.props=o:e.props=r,e.attrs=r}function bh(e,t,s,i){let{props:o,attrs:r,vnode:{patchFlag:d}}=e,p=We(o),[u]=e.propsOptions,y=!1;if((i||d>0)&&!(d&16)){if(d&8){let m=e.vnode.dynamicProps;for(let b=0;b{u=!0;let[h,w]=Cd(b,t,!0);ct(d,h),w&&p.push(...w)};!s&&t.mixins.length&&t.mixins.forEach(m),e.extends&&m(e.extends),e.mixins&&e.mixins.forEach(m)}if(!r&&!u)return Ye(e)&&i.set(e,In),In;if(Ne(r))for(let m=0;me==="_"||e==="_ctx"||e==="$stable",Qr=e=>Ne(e)?e.map(fn):[fn(e)],kh=(e,t,s)=>{if(t._n)return t;let i=zf((...o)=>Qr(t(...o)),s);return i._c=!1,i},Ed=(e,t,s)=>{let i=e._ctx;for(let o in e){if(Jr(o))continue;let r=e[o];if(Te(r))t[o]=kh(o,r,i);else if(r!=null){let d=Qr(r);t[o]=()=>d}}},Sd=(e,t)=>{let s=Qr(t);e.slots.default=()=>s},Nd=(e,t,s)=>{for(let i in t)(s||!Jr(i))&&(e[i]=t[i])},Ch=(e,t,s)=>{let i=e.slots=bd();if(e.vnode.shapeFlag&32){let o=t._;o?(Nd(i,t,s),s&&ri(i,"_",o,!0)):Ed(t,i)}else t&&Sd(e,t)},Eh=(e,t,s)=>{let{vnode:i,slots:o}=e,r=!0,d=Ze;if(i.shapeFlag&32){let p=t._;p?s&&p===1?r=!1:Nd(o,t,s):(r=!t.$stable,Ed(t,o)),d=t}else t&&(Sd(e,t),d={default:1});if(r)for(let p in o)!Jr(p)&&d[p]==null&&delete o[p]};function Sh(){let e=[]}var It=Ph;function Rd(e){return Nh(e)}function Nh(e,t){Sh();let s=so();s.__VUE__=!0;let{insert:i,remove:o,patchProp:r,createElement:d,createText:p,createComment:u,setText:y,setElementText:m,parentNode:b,nextSibling:h,setScopeId:w=Tt,insertStaticContent:R}=e,S=(P,T,F,J=null,H=null,x=null,le=void 0,ne=null,oe=!!T.dynamicChildren)=>{if(P===T)return;P&&!mo(P,T)&&(J=fe(P),He(P,H,x,!0),P=null),T.patchFlag===-2&&(oe=!1,T.dynamicChildren=null),T.dynamicChildren&&P&&P.dynamicChildren&&P.dynamicChildren.hasOnce&&(T.dynamicChildren===In&&(T.dynamicChildren=[]),T.dynamicChildren.hasOnce=!0);let{type:ee,ref:ke,shapeFlag:pe}=T;switch(ee){case Oi:N(P,T,F,J);break;case tn:v(P,T,F,J);break;case wo:P==null&&E(T,F,J,le);break;case q:z(P,T,F,J,H,x,le,ne,oe);break;default:pe&1?G(P,T,F,J,H,x,le,ne,oe):pe&6?K(P,T,F,J,H,x,le,ne,oe):(pe&64||pe&128)&&ee.process(P,T,F,J,H,x,le,ne,oe,ce)}ke!=null&&H?vo(ke,P&&P.ref,x,T||P,!T):ke==null&&P&&P.ref!=null&&vo(P.ref,null,x,P,!0)},N=(P,T,F,J)=>{if(P==null)i(T.el=p(T.children),F,J);else{let H=T.el=P.el;T.children!==P.children&&y(H,T.children)}},v=(P,T,F,J)=>{P==null?i(T.el=u(T.children||""),F,J):T.el=P.el},E=(P,T,F,J)=>{[P.el,P.anchor]=R(P.children,T,F,J,P.el,P.anchor)},M=(P,T,F,J)=>{if(T.children!==P.children){let H=h(P.anchor);_(P),[T.el,T.anchor]=R(T.children,F,H,J)}else T.el=P.el,T.anchor=P.anchor},V=({el:P,anchor:T},F,J)=>{let H;for(;P&&P!==T;)H=h(P),i(P,F,J),P=H;i(T,F,J)},_=({el:P,anchor:T})=>{let F;for(;P&&P!==T;)F=h(P),o(P),P=F;o(T)},G=(P,T,F,J,H,x,le,ne,oe)=>{if(T.type==="svg"?le="svg":T.type==="math"&&(le="mathml"),P==null)te(T,F,J,H,x,le,ne,oe);else{let ee=P.el&&P.el._isVueCE?P.el:null;try{ee&&ee._beginPatch(),U(P,T,H,x,le,ne,oe)}finally{ee&&ee._endPatch()}}},te=(P,T,F,J,H,x,le,ne)=>{let oe,ee,{props:ke,shapeFlag:pe,transition:Ee,dirs:Ae}=P;if(oe=P.el=d(P.type,x,ke&&ke.is,ke),pe&8?m(oe,P.children):pe&16&&O(P.children,oe,null,J,H,Ur(P,x),le,ne),Ae&&ts(P,null,J,"created"),X(oe,P,P.scopeId,le,J),ke){for(let Ge in ke)Ge!=="value"&&!Ps(Ge)&&r(oe,Ge,null,ke[Ge],x,J);"value"in ke&&r(oe,"value",null,ke.value,x),(ee=ke.onVnodeBeforeMount)&&cn(ee,J,P)}Ae&&ts(P,null,J,"beforeMount");let Ve=Rh(H,Ee);Ve&&Ee.beforeEnter(oe),i(oe,T,F),((ee=ke&&ke.onVnodeMounted)||Ve||Ae)&&It(()=>{let ze;ee&&cn(ee,J,P),Ve&&Ee.enter(oe),Ae&&ts(P,null,J,"mounted")},H)},X=(P,T,F,J,H)=>{if(F&&w(P,F),J)for(let x=0;x{for(let ee=oe;ee{let ne=T.el=P.el,{patchFlag:oe,dynamicChildren:ee,dirs:ke}=T;oe|=P.patchFlag&16;let pe=P.props||Ze,Ee=T.props||Ze,Ae;if(F&&ns(F,!1),(Ae=Ee.onVnodeBeforeUpdate)&&cn(Ae,F,T,P),ke&&ts(T,P,F,"beforeUpdate"),F&&ns(F,!0),ee&&(!P.dynamicChildren||P.dynamicChildren.length!==ee.length)&&(oe=0,le=!1,ee=null),(pe.innerHTML&&Ee.innerHTML==null||pe.textContent&&Ee.textContent==null)&&m(ne,""),ee?C(P.dynamicChildren,ee,ne,F,J,Ur(T,H),x):le||Se(P,T,ne,null,F,J,Ur(T,H),x,!1),oe>0){if(oe&16)L(ne,pe,Ee,F,H);else if(oe&2&&pe.class!==Ee.class&&r(ne,"class",null,Ee.class,H),oe&4&&r(ne,"style",pe.style,Ee.style,H),oe&8){let Ve=T.dynamicProps;for(let Ge=0;Ge{Ae&&cn(Ae,F,T,P),ke&&ts(T,P,F,"updated")},J)},C=(P,T,F,J,H,x,le)=>{for(let ne=0;ne{if(T!==F){if(T!==Ze)for(let x in T)!Ps(x)&&!(x in F)&&r(P,x,T[x],null,H,J);for(let x in F){if(Ps(x))continue;let le=F[x],ne=T[x];le!==ne&&x!=="value"&&r(P,x,ne,le,H,J)}"value"in F&&r(P,"value",T.value,F.value,H)}},z=(P,T,F,J,H,x,le,ne,oe)=>{let ee=T.el=P?P.el:p(""),ke=T.anchor=P?P.anchor:p(""),{patchFlag:pe,dynamicChildren:Ee,slotScopeIds:Ae}=T;Ae&&(ne=ne?ne.concat(Ae):Ae),P==null?(i(ee,F,J),i(ke,F,J),O(T.children||[],F,ke,H,x,le,ne,oe)):pe>0&&pe&64&&Ee&&P.dynamicChildren&&P.dynamicChildren.length===Ee.length?(C(P.dynamicChildren,Ee,F,H,x,le,ne),(T.key!=null||H&&T===H.subTree)&&Ad(P,T,!0)):Se(P,T,F,ke,H,x,le,ne,oe)},K=(P,T,F,J,H,x,le,ne,oe)=>{T.slotScopeIds=ne,P==null?T.shapeFlag&512?H.ctx.activate(T,F,J,le,oe):ie(T,F,J,H,x,le,oe):se(P,T,oe)},ie=(P,T,F,J,H,x,le)=>{let ne=P.component=Vh(P,J,H);if(Pi(P)&&(ne.ctx.renderer=ce),qh(ne,!1,le),ne.asyncDep){if(H&&H.registerDep(ne,Y,le,x),!P.el){let oe=ne.subTree=Oe(tn);v(null,oe,T,F),P.placeholder=oe.el}}else Y(ne,P,T,F,H,x,le)},se=(P,T,F)=>{let J=T.component=P.component;if(gh(P,T,F))if(J.asyncDep&&!J.asyncResolved){T.el=P.el,T.placeholder=P.placeholder,he(J,T,F);return}else J.next=T,J.update();else T.el=P.el,T.placeholder=P.placeholder,J.vnode=T},Y=(P,T,F,J,H,x,le)=>{let ne=()=>{if(P.isMounted){let{next:pe,bu:Ee,u:Ae,parent:Ve,vnode:Ge}=P;{let rt=Pd(P);if(rt){pe&&(pe.el=Ge.el,he(P,pe,le)),rt.asyncDep.then(()=>{It(()=>{P.isUnmounted||ee()},H)});return}}let ze=pe,we;ns(P,!1),pe?(pe.el=Ge.el,he(P,pe,le)):pe=Ge,Ee&&Ds(Ee),(we=pe.props&&pe.props.onVnodeBeforeUpdate)&&cn(we,Ve,pe,Ge),ns(P,!0);let be=Fr(P),ot=P.subTree;P.subTree=be,S(ot,be,b(ot.el),fe(ot),P,H,x),pe.el=be.el,ze===null&&vh(P,be.el),Ae&&It(Ae,H),(we=pe.props&&pe.props.onVnodeUpdated)&&It(()=>cn(we,Ve,pe,Ge),H)}else{let pe,{el:Ee,props:Ae}=T,{bm:Ve,m:Ge,parent:ze,root:we,type:be}=P,ot=yo(T);if(ns(P,!1),Ve&&Ds(Ve),!ot&&(pe=Ae&&Ae.onVnodeBeforeMount)&&cn(pe,ze,T),ns(P,!0),Ee&&Me){let rt=()=>{P.subTree=Fr(P),Me(Ee,P.subTree,P,H,null)};ot&&be.__asyncHydrate?be.__asyncHydrate(Ee,P,rt):rt()}else{we.ce&&we.ce._hasShadowRoot()&&we.ce._injectChildStyle(be,P.parent?P.parent.type:void 0);let rt=P.subTree=Fr(P);S(null,rt,F,J,P,H,x),T.el=rt.el}if(Ge&&It(Ge,H),!ot&&(pe=Ae&&Ae.onVnodeMounted)){let rt=T;It(()=>cn(pe,ze,rt),H)}(T.shapeFlag&256||ze&&yo(ze.vnode)&&ze.vnode.shapeFlag&256)&&P.a&&It(P.a,H),P.isMounted=!0,T=F=J=null}};P.scope.on();let oe=P.effect=new Is(ne);P.scope.off();let ee=P.update=oe.run.bind(oe),ke=P.job=oe.runIfDirty.bind(oe);ke.i=P,ke.id=P.uid,oe.scheduler=()=>Kr(ke),ns(P,!0),ee()},he=(P,T,F)=>{T.component=P;let J=P.vnode.props;P.vnode=T,P.next=null,bh(P,T.props,J,F),Eh(P,T.children,F),Zt(),Zl(P),xt()},Se=(P,T,F,J,H,x,le,ne,oe=!1)=>{let ee=P&&P.children,ke=P?P.shapeFlag:0,pe=T.children,{patchFlag:Ee,shapeFlag:Ae}=T;if(Ee>0){if(Ee&128){Be(ee,pe,F,J,H,x,le,ne,oe);return}else if(Ee&256){Ue(ee,pe,F,J,H,x,le,ne,oe);return}}Ae&8?(ke&16&&W(ee,H,x),pe!==ee&&m(F,pe)):ke&16?Ae&16?Be(ee,pe,F,J,H,x,le,ne,oe):W(ee,H,x,!0):(ke&8&&m(F,""),Ae&16&&O(pe,F,J,H,x,le,ne,oe))},Ue=(P,T,F,J,H,x,le,ne,oe)=>{P=P||In,T=T||In;let ee=P.length,ke=T.length,pe=Math.min(ee,ke),Ee;for(Ee=0;Eeke?W(P,H,x,!0,!1,pe):O(T,F,J,H,x,le,ne,oe,pe)},Be=(P,T,F,J,H,x,le,ne,oe)=>{let ee=0,ke=T.length,pe=P.length-1,Ee=ke-1;for(;ee<=pe&&ee<=Ee;){let Ae=P[ee],Ve=T[ee]=oe?Cn(T[ee]):fn(T[ee]);if(mo(Ae,Ve))S(Ae,Ve,F,null,H,x,le,ne,oe);else break;ee++}for(;ee<=pe&&ee<=Ee;){let Ae=P[pe],Ve=T[Ee]=oe?Cn(T[Ee]):fn(T[Ee]);if(mo(Ae,Ve))S(Ae,Ve,F,null,H,x,le,ne,oe);else break;pe--,Ee--}if(ee>pe){if(ee<=Ee){let Ae=Ee+1,Ve=AeEe)for(;ee<=pe;)He(P[ee],H,x,!0),ee++;else{let Ae=ee,Ve=ee,Ge=new Map;for(ee=Ve;ee<=Ee;ee++){let lt=T[ee]=oe?Cn(T[ee]):fn(T[ee]);lt.key!=null&&Ge.set(lt.key,ee)}let ze,we=0,be=Ee-Ve+1,ot=!1,rt=0,yt=new Array(be);for(ee=0;ee=be){He(lt,H,x,!0);continue}let ft;if(lt.key!=null)ft=Ge.get(lt.key);else for(ze=Ve;ze<=Ee;ze++)if(yt[ze-Ve]===0&&mo(lt,T[ze])){ft=ze;break}ft===void 0?He(lt,H,x,!0):(yt[ft-Ve]=ee+1,ft>=rt?rt=ft:ot=!0,S(lt,T[ft],F,null,H,x,le,ne,oe),we++)}let at=ot?Ah(yt):In;for(ze=at.length-1,ee=be-1;ee>=0;ee--){let lt=Ve+ee,ft=T[lt],Vt=T[lt+1],Yn=lt+1{let{el:x,type:le,transition:ne,children:oe,shapeFlag:ee}=P;if(ee&6){Qe(P.component.subTree,T,F,J);return}if(ee&128){P.suspense.move(T,F,J);return}if(ee&64){le.move(P,T,F,ce);return}if(le===q){i(x,T,F);for(let pe=0;pene.enter(x),H));else{let{leave:pe,delayLeave:Ee,afterLeave:Ae}=ne,Ve=()=>{P.ctx.isUnmounted?o(x):i(x,T,F)},Ge=()=>{let ze=x._isLeaving||!!x[Lr];x._isLeaving&&x[Lr](!0),ne.persisted&&!ze?Ve():pe(x,()=>{Ve(),Ae&&Ae()})};Ee?Ee(x,Ve,Ge):Ge()}else i(x,T,F)},He=(P,T,F,J=!1,H=!1)=>{let{type:x,props:le,ref:ne,children:oe,dynamicChildren:ee,shapeFlag:ke,patchFlag:pe,dirs:Ee,cacheIndex:Ae,memo:Ve}=P;if((pe===-2||ee&&ee.hasOnce)&&(H=!1),ne!=null&&(Zt(),vo(ne,null,F,P,!0),xt()),Ae!=null&&(!P.ctx||P.ctx===T)&&(T.renderCache[Ae]=void 0),ke&256){T.ctx.deactivate(P);return}let Ge=ke&1&&Ee,ze=!yo(P),we;if(ze&&(we=le&&le.onVnodeBeforeUnmount)&&cn(we,T,P),ke&6)Fe(P.component,F,J);else{if(ke&128){P.suspense.unmount(F,J);return}Ge&&ts(P,null,T,"beforeUnmount"),ke&64?P.type.remove(P,T,F,ce,J):ee&&!ee.hasOnce&&(x!==q||pe>0&&pe&64)?W(ee,T,F,!1,!0):(x===q&&pe&384||!H&&ke&16)&&W(oe,T,F),J&&et(P)}let be=Ve!=null&&Ae==null;(ze&&(we=le&&le.onVnodeUnmounted)||Ge||be)&&It(()=>{we&&cn(we,T,P),Ge&&ts(P,null,T,"unmounted"),be&&(P.el=null)},F)},et=P=>{let{type:T,el:F,anchor:J,transition:H}=P,x=T===q;if(x&&!H){Re(F,J);return}if(T===wo){_(P),H&&!H.persisted&&H.afterLeave&&H.afterLeave();return}let le=x?Br(P):P,ne=()=>{x?b(F)&&Re(F,J):o(F),H&&!H.persisted&&H.afterLeave&&H.afterLeave()};if(le&&le.shapeFlag&1&&H&&!H.persisted){let{leave:oe,delayLeave:ee}=H,ke=le.el,pe=()=>oe(ke,ne);ee?ee(ke,ne,pe):pe()}else ne()},Re=(P,T)=>{let F;for(;P!==T;)F=h(P),o(P),P=F;o(T)},Fe=(P,T,F)=>{let{bum:J,scope:H,job:x,subTree:le,um:ne,m:oe,a:ee}=P;jl(oe),jl(ee),J&&Ds(J),H.stop(),x?(x.flags|=8,He(le,P,T,F)):P.vnode.el&&le&&(le.transition=P.vnode.transition,He(le,P,T,F)),ne&&It(ne,T),It(()=>{P.isUnmounted=!0},T)},W=(P,T,F,J=!1,H=!1,x=0)=>{for(let le=x;le{if(P.shapeFlag&6)return fe(P.component.subTree);if(P.shapeFlag&128)return P.suspense.next();let T=h(P.anchor||P.el),F=T&&T[Wf];return F?h(F):T},de=(P,T,F)=>{let J=P&&T._vnode?void 0:P&&P.component?P.component.uid:Mh();Bf(()=>{P==null?T._vnode&&He(T._vnode,null,null,!0):S(T._vnode||null,P,T,null,null,null,F),T._vnode=P},J)},ce={p:S,um:He,m:Qe,r:et,mt:ie,mc:O,pc:Se,pbc:C,n:fe,o:e},ve,Me;return t&&([ve,Me]=t(ce)),{render:de,hydrate:ve,createApp:uh(de,ve)}}function Ur({type:e,props:t},s){return s==="svg"&&e==="foreignObject"||s==="mathml"&&e==="annotation-xml"&&t&&t.encoding&&t.encoding.includes("html")?void 0:s}function ns({effect:e,job:t},s){s?(e.flags|=32,t.flags|=4):(e.flags&=-33,t.flags&=-5)}function Rh(e,t){return(!e||e&&!e.pendingBranch)&&t&&!t.persisted}function Ad(e,t,s=!1){let i=e.children,o=t.children;if(Ne(i)&&Ne(o))for(let r=0;r>1,e[s[p]]0&&(t[i]=s[r-1]),s[r]=i)}}for(r=s.length,d=s[r-1];r-- >0;)s[r]=d,d=t[d];return s}function Pd(e){let t=e.subTree.component;if(t)return t.asyncDep&&!t.asyncResolved?t:Pd(t)}function jl(e){if(e)for(let t=0;te.__isSuspense;function Ph(e,t){t&&t.pendingBranch?Ne(e)?t.effects.push(...e):t.effects.push(e):Ql(e)}var q=Symbol.for("v-fgt"),Oi=Symbol.for("v-txt"),tn=Symbol.for("v-cmt"),wo=Symbol.for("v-stc"),ss=[],Ft=null;function a(e=!1){ss.push(Ft=e?null:[])}function Td(){ss.pop(),Ft=ss[ss.length-1]||null}var Eo=1;function Si(e,t=!1){Eo+=e,e<0&&Ft&&t&&(Ft.hasOnce=!0)}function Od(e){return e.dynamicChildren=Eo>0?Ft||In:null,Td(),Eo>0&&Ft&&Ft.push(e),e}function l(e,t,s,i,o,r){return Od(n(e,t,s,i,o,r,!0))}function Wt(e,t,s,i,o){return Od(Oe(e,t,s,i,o,!0))}function So(e){return e?e.__v_isVNode===!0:!1}function mo(e,t){return e.type===t.type&&e.key===t.key}var Id=({key:e})=>e??null,bi=({ref:e,ref_key:t,ref_for:s})=>(typeof e=="number"&&(e=""+e),e!=null?it(e)||wt(e)||Te(e)?{i:$t,r:e,k:t,f:!!s}:e:null);function n(e,t=null,s=null,i=0,o=null,r=e===q?0:1,d=!1,p=!1){let u={__v_isVNode:!0,__v_skip:!0,type:e,props:t,key:t&&Id(t),ref:t&&bi(t),scopeId:td,slotScopeIds:null,children:s,component:null,suspense:null,ssContent:null,ssFallback:null,dirs:null,transition:null,el:null,anchor:null,target:null,targetStart:null,targetAnchor:null,staticCount:0,shapeFlag:r,patchFlag:i,dynamicProps:o,dynamicChildren:null,appContext:null,ctx:$t};return p?(Ni(u,s),r&128&&e.normalize(u)):s&&(u.shapeFlag|=it(s)?8:16),Eo>0&&!d&&Ft&&(u.patchFlag>0||r&6)&&u.patchFlag!==32&&Ft.push(u),u}var Oe=Dh;function Dh(e,t=null,s=null,i=0,o=null,r=!1){if((!e||e===nh)&&(e=tn),So(e)){let p=qs(e,t,!0);return s&&Ni(p,s),Eo>0&&!r&&Ft&&(p.shapeFlag&6?Ft[Ft.indexOf(e)]=p:Ft.push(p)),p.patchFlag=-2,p}if(Uh(e)&&(e=e.__vccOpts),t){t=Th(t);let{class:p,style:u}=t;p&&!it(p)&&(t.class=A(p)),Ye(u)&&(ho(u)&&!Ne(u)&&(u=ct({},u)),t.style=Ie(u))}let d=it(e)?1:Dd(e)?128:Ai(e)?64:Ye(e)?4:Te(e)?2:0;return n(e,t,s,i,o,d,r,!0)}function Th(e){return e?ho(e)||wd(e)?ct({},e):e:null}function qs(e,t,s=!1,i=!1){let{props:o,ref:r,patchFlag:d,children:p,transition:u}=e,y=t?Oh(o||{},t):o,m={__v_isVNode:!0,__v_skip:!0,type:e.type,props:y,key:y&&Id(y),ref:t&&t.ref?s&&r?Ne(r)?r.concat(bi(t)):[r,bi(t)]:bi(t):r,scopeId:e.scopeId,slotScopeIds:e.slotScopeIds,children:p,target:e.target,targetStart:e.targetStart,targetAnchor:e.targetAnchor,staticCount:e.staticCount,shapeFlag:e.shapeFlag,patchFlag:t&&e.type!==q?d===-1?16:d|16:d,dynamicProps:e.dynamicProps,dynamicChildren:e.dynamicChildren,appContext:e.appContext,dirs:e.dirs,transition:u,component:e.component,suspense:e.suspense,ssContent:e.ssContent&&qs(e.ssContent),ssFallback:e.ssFallback&&qs(e.ssFallback),placeholder:e.placeholder,el:e.el,anchor:e.anchor,ctx:e.ctx,ce:e.ce,cacheIndex:e.cacheIndex};return u&&i&&Co(m,u.clone(m)),m}function g(e=" ",t=0){return Oe(Oi,null,e,t)}function Ce(e,t){let s=Oe(wo,null,e);return s.staticCount=t,s}function f(e="",t=!1){return t?(a(),Wt(tn,null,e)):Oe(tn,null,e)}function fn(e){return e==null||typeof e=="boolean"?Oe(tn):Ne(e)?Oe(q,null,e.slice()):So(e)?Cn(e):Oe(Oi,null,String(e))}function Cn(e){return e.el===null&&e.patchFlag!==-1||e.memo?e:qs(e)}function Ni(e,t){let s=0,{shapeFlag:i}=e;if(t==null)t=null;else if(Ne(t))s=16;else if(typeof t=="object")if(i&65){let o=t.default;o&&(o._c&&(o._d=!1),Ni(e,o()),o._c&&(o._d=!0));return}else{s=32;let o=t._;!o&&!wd(t)?t._ctx=$t:o===3&&$t&&($t.slots._===1?t._=1:(t._=2,e.patchFlag|=1024))}else if(Te(t)){if(i&65){Ni(e,{default:t});return}t={default:t,_ctx:$t},s=32}else t=String(t),i&64?(s=16,t=[g(t)]):s=8;e.children=t,e.shapeFlag|=s}function Oh(...e){let t={};for(let s=0;sNt||$t,Ri,No;{let e=so(),t=(s,i)=>{let o;return(o=e[s])||(o=e[s]=[]),o.push(i),r=>{o.length>1?o.forEach(d=>d(r)):o[0](r)}};Ri=t("__VUE_INSTANCE_SETTERS__",s=>Nt=s),No=t("__VUE_SSR_SETTERS__",s=>_s=s)}var To=e=>{let t=Nt;return Ri(e),e.scope.on(),()=>{e.scope.off(),Ri(t)}},Gl=()=>{Nt&&Nt.scope.off(),Ri(null)};function Vd(e){return e.vnode.shapeFlag&4}var _s=!1;function qh(e,t=!1,s=!1){t&&No(t);let{props:i,children:o}=e.vnode,r=Vd(e);yh(e,i,r,t),Ch(e,o,s||t);let d=r?_h(e,t):void 0;return t&&No(!1),d}function _h(e,t){let s=e.type;e.accessCache=Object.create(null),e.proxy=new Proxy(e.ctx,sh);let{setup:i}=s;if(i){Zt();let o=e.setupContext=i.length>1?$h(e):null,r=To(e),d=Ro(i,e,0,[e.props,o]),p=yr(d);if(xt(),r(),(p||e.sp)&&!yo(e)&&Yr(e),p){if(d.then(Gl,Gl),t)return d.then(u=>{No(!0);try{Wl(e,u,t)}finally{No(!1)}}).catch(u=>{Ao(u,e,0)});e.asyncDep=d}else Wl(e,d,t)}else qd(e,t)}function Wl(e,t,s){Te(t)?e.type.__ssrInlineRender?e.ssrRender=t:e.render=t:Ye(t)&&(e.setupState=vi(t)),qd(e,s)}var Kl,Yl;function qd(e,t,s){let i=e.type;if(!e.render){if(!t&&Kl&&!i.render){let o=i.template||Xr(e).template;if(o){let{isCustomElement:r,compilerOptions:d}=e.appContext.config,{delimiters:p,compilerOptions:u}=i,y=ct(ct({isCustomElement:r,delimiters:p},d),u);i.render=Kl(o,y)}}e.render=i.render||Tt,Yl&&Yl(e)}{let o=To(e);Zt();try{oh(e)}finally{xt(),o()}}}var Lh={get(e,t){return Et(e,"get",""),e[t]}};function $h(e){let t=s=>{e.exposed=s||{}};return{attrs:new Proxy(e.attrs,Lh),slots:e.slots,emit:e.emit,expose:t}}function Ii(e){return e.exposed?e.exposeProxy||(e.exposeProxy=new Proxy(vi(un(e.exposed)),{get(t,s){if(s in t)return t[s];if(s in bo)return bo[s](e)},has(t,s){return s in t||s in bo}})):e.proxy}function Fh(e,t=!0){return Te(e)?e.displayName||e.name:e.name||t&&e.__name}function Uh(e){return Te(e)&&"__vccOpts"in e}var Rt=(e,t)=>Ol(e,t,_s);function De(e,t,s){try{Si(-1);let i=arguments.length;return i===2?Ye(t)&&!Ne(t)?So(t)?Oe(e,null,[t]):Oe(e,t):Oe(e,null,t):(i>3?s=Array.prototype.slice.call(arguments,2):i===3&&So(s)&&(s=[s]),Oe(e,t,s))}finally{Si(1)}}var Bh="3.5.44";var na,_d=typeof window<"u"&&window.trustedTypes;if(_d)try{na=_d.createPolicy("vue",{createHTML:e=>e})}catch{}var Yd=na?e=>na.createHTML(e):e=>e,zh="http://www.w3.org/2000/svg",Hh="http://www.w3.org/1998/Math/MathML",Sn=typeof document<"u"?document:null,Ld=Sn&&Sn.createElement("template"),jh={insert:(e,t,s)=>{t.insertBefore(e,s||null)},remove:e=>{let t=e.parentNode;t&&t.removeChild(e)},createElement:(e,t,s,i)=>{let o=t==="svg"?Sn.createElementNS(zh,e):t==="mathml"?Sn.createElementNS(Hh,e):s?Sn.createElement(e,{is:s}):Sn.createElement(e);return e==="select"&&i&&i.multiple!=null&&o.setAttribute("multiple",i.multiple),o},createText:e=>Sn.createTextNode(e),createComment:e=>Sn.createComment(e),setText:(e,t)=>{e.nodeValue=t},setElementText:(e,t)=>{e.textContent=t},parentNode:e=>e.parentNode,nextSibling:e=>e.nextSibling,querySelector:e=>Sn.querySelector(e),setScopeId(e,t){e.setAttribute(t,"")},insertStaticContent(e,t,s,i,o,r){let d=s?s.previousSibling:t.lastChild;if(o&&(o===r||o.nextSibling))for(;t.insertBefore(o.cloneNode(!0),s),!(o===r||!(o=o.nextSibling)););else{Ld.innerHTML=Yd(i==="svg"?`${e}`:i==="mathml"?`${e}`:e);let p=Ld.content;if(i==="svg"||i==="mathml"){let u=p.firstChild;for(;u.firstChild;)p.appendChild(u.firstChild);p.removeChild(u)}t.insertBefore(p,s)}return[d?d.nextSibling:t.firstChild,s?s.previousSibling:t.lastChild]}};var Gh=Symbol("_vtc");function Wh(e,t,s){let i=e[Gh];i&&(t=(t?[t,...i]:[...i]).join(" ")),t==null?e.removeAttribute("class"):s?e.setAttribute("class",t):e.className=t}var qi=Symbol("_vod"),Xd=Symbol("_vsh"),Z={name:"show",beforeMount(e,{value:t},{transition:s}){e[qi]=e.style.display==="none"?"":e.style.display,s&&t?s.beforeEnter(e):Oo(e,t)},mounted(e,{value:t},{transition:s}){s&&t&&s.enter(e)},updated(e,{value:t,oldValue:s},{transition:i}){!t!=!s&&(i?t?(i.beforeEnter(e),Oo(e,!0),i.enter(e)):i.leave(e,()=>{Oo(e,!1)}):Oo(e,t))},beforeUnmount(e,{value:t}){Oo(e,t)}};function Oo(e,t){e.style.display=t?e[qi]:"none",e[Xd]=!t}var Kh=Symbol("");var Yh=/(?:^|;)\s*display\s*:/;function Xh(e,t,s){let i=e.style,o=it(s),r=!1;if(s&&!o){if(t)if(it(t))for(let d of t.split(";")){let p=d.slice(0,d.indexOf(":")).trim();s[p]==null&&Io(i,p,"")}else for(let d in t)s[d]==null&&Io(i,d,"");for(let d in s){d==="display"&&(r=!0);let p=s[d];p!=null?Qh(e,d,!it(t)&&t?t[d]:void 0,p)||Io(i,d,p):Io(i,d,"")}}else if(o){if(t!==s){let d=i[Kh];d&&(s+=";"+d),i.cssText=s,r=Yh.test(s)}}else t&&e.removeAttribute("style");qi in e&&((!o||t!==s)&&(e[qi]=r?i.display:""),e[Xd]&&(i.display="none"))}var Mi=/\s*!important$/;function Io(e,t,s){if(Ne(s))s.forEach(i=>Io(e,t,i));else if(s==null&&(s=""),t.startsWith("--"))Mi.test(s)?e.setProperty(t,s.replace(Mi,""),"important"):e.setProperty(t,s);else{let i=Jh(e,t);Mi.test(s)?e.setProperty(on(i),s.replace(Mi,""),"important"):e[i]=s}}var $d=["Webkit","Moz","ms"],xr={};function Jh(e,t){let s=xr[t];if(s)return s;let i=ht(t);if(i!=="filter"&&i in e)return xr[t]=i;i=Qn(i);for(let o=0;o<$d.length;o++){let r=$d[o]+i;if(r in e)return xr[t]=r}return t}function Qh(e,t,s,i){return e.tagName==="TEXTAREA"&&(t==="width"||t==="height")&&it(i)&&s===i}var Fd="http://www.w3.org/1999/xlink";function Ud(e,t,s,i,o,r=cl(t)){i&&t.startsWith("xlink:")?s==null?e.removeAttributeNS(Fd,t.slice(6,t.length)):e.setAttributeNS(Fd,t,s):s==null||r&&!ai(s)?e.removeAttribute(t):e.setAttribute(t,r?"":_t(s)?String(s):s)}function Bd(e,t,s,i,o){if(t==="innerHTML"||t==="textContent"){s!=null&&(e[t]=t==="innerHTML"?Yd(s):s);return}let r=e.tagName;if(t==="value"&&r!=="PROGRESS"&&!r.includes("-")){let p=r==="OPTION"?e.getAttribute("value")||"":e.value,u=s==null?e.type==="checkbox"?"on":"":String(s);(p!==u||!("_value"in e))&&(e.value=u),s==null&&e.removeAttribute(t),e._value=s;return}let d=!1;if(s===""||s==null){let p=typeof e[t];p==="boolean"?s=ai(s):s==null&&p==="string"?(s="",d=!0):p==="number"&&(s=0,d=!0)}try{e[t]=s}catch{}d&&e.removeAttribute(o||t)}function Vn(e,t,s,i){e.addEventListener(t,s,i)}function Zh(e,t,s,i){e.removeEventListener(t,s,i)}var zd=Symbol("_vei");function xh(e,t,s,i,o=null){let r=e[zd]||(e[zd]={}),d=r[t];if(i&&d)d.value=i;else{let[p,u]=nm(t);if(i){let y=r[t]=im(i,o);Vn(e,p,y,u)}else d&&(Zh(e,p,d,u),r[t]=void 0)}}var em=/(Once|Passive|Capture)$/,tm=/^on:?(?:Once|Passive|Capture)$/;function nm(e){let t,s;for(;(s=e.match(em))&&!tm.test(e);)t||(t={}),e=e.slice(0,e.length-s[1].length),t[s[1].toLowerCase()]=!0;return[e[2]===":"?e.slice(3):on(e.slice(2)),t]}var ea=0,sm=Promise.resolve(),om=()=>ea||(sm.then(()=>ea=0),ea=Date.now());function im(e,t){let s=i=>{if(!i._vts)i._vts=Date.now();else if(i._vts<=s.attached)return;let o=s.value;if(Ne(o)){let r=i.stopImmediatePropagation;i.stopImmediatePropagation=()=>{r.call(i),i._stopped=!0};let d=o.slice(),p=[i];for(let u=0;ue.charCodeAt(0)===111&&e.charCodeAt(1)===110&&e.charCodeAt(2)>96&&e.charCodeAt(2)<123,rm=(e,t,s,i,o,r)=>{let d=o==="svg";t==="class"?Wh(e,i,d):t==="style"?Xh(e,s,i):Rs(t)?As(t)||xh(e,t,s,i,r):(t[0]==="."?(t=t.slice(1),!0):t[0]==="^"?(t=t.slice(1),!1):am(e,t,i,d))?(Bd(e,t,i),!e.tagName.includes("-")&&(t==="value"||t==="checked"||t==="selected")&&Ud(e,t,i,d,r,t!=="value")):e._isVueCE&&(lm(e,t)||e._def.__asyncLoader&&(/[A-Z]/.test(t)||!it(i)))?Bd(e,ht(t),i,r,t):(t==="true-value"?e._trueValue=i:t==="false-value"&&(e._falseValue=i),Ud(e,t,i,d))};function am(e,t,s,i){if(i)return!!(t==="innerHTML"||t==="textContent"||t in e&&Hd(t)&&Te(s));if(t==="spellcheck"||t==="draggable"||t==="translate"||t==="autocorrect"||t==="sandbox"&&e.tagName==="IFRAME"||t==="form"||t==="list"&&e.tagName==="INPUT"||t==="type"&&e.tagName==="TEXTAREA")return!1;if(t==="width"||t==="height"){let o=e.tagName;if(o==="IMG"||o==="VIDEO"||o==="CANVAS"||o==="SOURCE")return!1}return Hd(t)&&it(s)?!1:t in e}function lm(e,t){let s=e._def.props;if(!s)return!1;let i=ht(t);return Array.isArray(s)?s.some(o=>ht(o)===i):Object.keys(s).some(o=>ht(o)===i)}var Ls=e=>{let t=e.props["onUpdate:modelValue"]||!1;return Ne(t)?s=>Ds(t,s):t};function dm(e){e.target.composing=!0}function jd(e){let t=e.target;t.composing&&(t.composing=!1,t.dispatchEvent(new Event("input")))}var mn=Symbol("_assign"),Vi=Symbol("_initialValue");function ta(e,t,s){return t&&(e=e.trim()),s&&(e=Ts(e)),e}var pt={created(e,{modifiers:{lazy:t,trim:s,number:i}},o){e.parentNode&&(e.type==="text"?e[Vi]=e.defaultValue.replace(/[\r\n]/g,""):e.type==="textarea"&&(e[Vi]=e.defaultValue.replace(/\r\n?/g,` -`))),e[mn]=Ls(o);let r=i||o.props&&o.props.type==="number";Vn(e,t?"change":"input",d=>{d.target.composing||e[mn](ta(e.value,s,r))}),(s||r)&&Vn(e,"change",()=>{e.value=ta(e.value,s,r)}),t||(Vn(e,"compositionstart",dm),Vn(e,"compositionend",jd),Vn(e,"change",jd))},mounted(e,{value:t,modifiers:{trim:s,number:i}}){let o=t??"",r=e[Vi];delete e[Vi],r!==void 0&&(e.type==="text"||e.type==="textarea")&&e.value!==r?e[mn](ta(e.value,s,i)):e.value=o},beforeUpdate(e,{value:t,oldValue:s,modifiers:{lazy:i,trim:o,number:r}},d){if(e[mn]=Ls(d),e.composing)return;let p=(r||e.type==="number")&&!/^0\d/.test(e.value)?Ts(e.value):e.value,u=t??"";if(p===u)return;let y=e.getRootNode();(y instanceof Document||y instanceof ShadowRoot)&&y.activeElement===e&&e.type!=="range"&&(i&&t===s||o&&e.value.trim()===u)||(e.value=u)}},sa={deep:!0,created(e,t,s){e[mn]=Ls(s),Vn(e,"change",()=>{let i=e._modelValue,o=Mo(e),r=e.checked,d=e[mn];if(Ne(i)){let p=li(i,o),u=p!==-1;if(r&&!u)d(i.concat(o));else if(!r&&u){let y=[...i];y.splice(p,1),d(y)}}else if(Xt(i)){let p=new Set(i);r?p.add(o):p.delete(o),d(p)}else d(Jd(e,r))})},mounted:Gd,beforeUpdate(e,t,s){e[mn]=Ls(s),Gd(e,t,s)}};function Gd(e,{value:t,oldValue:s},i){e._modelValue=t;let o;if(Ne(t))o=li(t,i.props.value)>-1;else if(Xt(t))o=t.has(i.props.value);else{if(t===s)return;o=Jt(t,Jd(e,!0))}e.checked!==o&&(e.checked=o)}var Ut={deep:!0,created(e,{value:t,modifiers:{number:s}},i){e._modelValue=t,Vn(e,"change",()=>{let o=Array.prototype.filter.call(e.options,u=>u.selected).map(u=>s?Ts(Mo(u)):Mo(u)),r=e.multiple,d=r?Xt(e._modelValue)?new Set(o):o:o[0],p=e._pendingValue=[r,r?Ne(d)?o.slice():o:d];try{e[mn](d)}finally{tt(()=>{e._pendingValue===p&&(e._pendingValue=void 0)})}}),e[mn]=Ls(i)},mounted(e,{value:t}){Wd(e,t)},beforeUpdate(e,{value:t},s){e._modelValue=t,e[mn]=Ls(s)},updated(e,{value:t}){let s=e._pendingValue;e._pendingValue=void 0,(!s||s[0]!==e.multiple||!um(t,s[1],s[0]))&&Wd(e,t)}};function um(e,t,s){if(!s)return Jt(e,t);if(Ne(e))return Jt(e,t);if(Xt(e)){if(e.size!==t.length)return!1;for(let i of t)if(!e.has(i))return!1;return!0}return!1}function Wd(e,t){let s=e.multiple,i=Ne(t);if(!(s&&!i&&!Xt(t))){for(let o=0,r=e.options.length;oString(y)===String(p)):d.selected=li(t,p)>-1}else d.selected=t.has(p);else if(Jt(Mo(d),t)){e.selectedIndex!==o&&(e.selectedIndex=o);return}}!s&&e.selectedIndex!==-1&&(e.selectedIndex=-1)}}function Mo(e){return"_value"in e?e._value:e.value}function Jd(e,t){let s=t?"_trueValue":"_falseValue";return s in e?e[s]:t}var cm=["ctrl","shift","alt","meta"],pm={stop:e=>e.stopPropagation(),prevent:e=>e.preventDefault(),self:e=>e.target!==e.currentTarget,ctrl:e=>!e.ctrlKey,shift:e=>!e.shiftKey,alt:e=>!e.altKey,meta:e=>!e.metaKey,left:e=>"button"in e&&e.button!==0,middle:e=>"button"in e&&e.button!==1,right:e=>"button"in e&&e.button!==2,exact:(e,t)=>cm.some(s=>e[`${s}Key`]&&!t.includes(s))},ae=(e,t)=>{if(!e)return e;let s=e._withMods||(e._withMods={}),i=t.join(".");return s[i]||(s[i]=((o,...r)=>{for(let d=0;d{let s=e._withKeys||(e._withKeys={}),i=t.join(".");return s[i]||(s[i]=(o=>{if(!("key"in o))return;let r=on(o.key);if(t.some(d=>d===r||fm[d]===r))return e(o)}))},hm=ct({patchProp:rm},jh),Kd;function mm(){return Kd||(Kd=Rd(hm))}var Qd=((...e)=>{let t=mm().createApp(...e),{mount:s}=t;return t.mount=i=>{let o=vm(i);if(!o)return;let r=t._component;!Te(r)&&!r.render&&!r.template&&(r.template=o.innerHTML),o.nodeType===1&&(o.textContent="");let d=s(o,!1,gm(o));return o instanceof Element&&(o.removeAttribute("v-cloak"),o.setAttribute("data-v-app","")),d},t});function gm(e){if(e instanceof SVGElement)return"svg";if(typeof MathMLElement=="function"&&e instanceof MathMLElement)return"mathml"}function vm(e){return it(e)?document.querySelector(e):e}var ls=typeof document<"u";function xd(e){return typeof e=="object"||"displayName"in e||"props"in e||"__vccOpts"in e}function ym(e){return e.__esModule||e[Symbol.toStringTag]==="Module"||e.default&&xd(e.default)}var Je=Object.assign;function _i(e,t){let s={};for(let i in t){let o=t[i];s[i]=Kt(o)?o.map(e):e(o)}return s}var Fs=()=>{},Kt=Array.isArray;function ra(e,t){let s={};for(let i in e)s[i]=i in t?t[i]:e[i];return s}var eu=/#/g,bm=/&/g,wm=/\//g,km=/=/g,Cm=/\?/g,tu=/\+/g,Em=/%5B/g,Sm=/%5D/g,nu=/%5E/g,Nm=/%60/g,su=/%7B/g,Rm=/%7C/g,ou=/%7D/g,Am=/%20/g;function aa(e){return e==null?"":encodeURI(""+e).replace(Rm,"|").replace(Em,"[").replace(Sm,"]")}function iu(e){return aa(e).replace(su,"{").replace(ou,"}").replace(nu,"^")}function oa(e){return aa(e).replace(tu,"%2B").replace(Am,"+").replace(eu,"%23").replace(bm,"%26").replace(Nm,"`").replace(su,"{").replace(ou,"}").replace(nu,"^")}function Pm(e){return oa(e).replace(km,"%3D")}function Dm(e){return aa(e).replace(eu,"%23").replace(Cm,"%3F")}function ru(e){return Dm(e).replace(wm,"%2F")}function $s(e){if(e==null)return null;try{return decodeURIComponent(""+e)}catch{}return""+e}var Tm=/\/$/,Om=e=>e.replace(Tm,"");function Li(e,t,s="/"){let i,o={},r="",d="",p=t.indexOf("#"),u=t.indexOf("?");return u=p>=0&&u>p?-1:u,u>=0&&(i=t.slice(0,u),r=t.slice(u,p>0?p:t.length),o=e(r.slice(1))),p>=0&&(i=i||t.slice(0,p),d=t.slice(p,t.length)),i=Mm(i??t,s),{fullPath:i+r+d,path:i,query:o,hash:$s(d)}}function au(e,t){let s=t.query?e(t.query):"";return t.path+(s&&"?")+s+(t.hash||"")}function la(e,t){return!t||!e.toLowerCase().startsWith(t.toLowerCase())?e:e.slice(t.length)||"/"}function lu(e,t,s){let i=t.matched.length-1,o=s.matched.length-1;return i>-1&&i===o&&rs(t.matched[i],s.matched[o])&&da(t.params,s.params)&&e(t.query)===e(s.query)&&t.hash===s.hash}function rs(e,t){return(e.aliasOf||e)===(t.aliasOf||t)}function da(e,t){if(Object.keys(e).length!==Object.keys(t).length)return!1;for(var s in e)if(!Im(e[s],t[s]))return!1;return!0}function Im(e,t){return Kt(e)?Zd(e,t):Kt(t)?Zd(t,e):e?.valueOf()===t?.valueOf()}function Zd(e,t){return Kt(t)?e.length===t.length&&e.every((s,i)=>s===t[i]):e.length===1&&e[0]===t}function Mm(e,t){if(e.startsWith("/"))return e;if(!e)return t;let s=t.split("/"),i=e.split("/"),o=i[i.length-1];(o===".."||o===".")&&i.push("");let r=s.length-1,d,p;for(d=0;d1&&r--;else break;return s.slice(0,r).join("/")+"/"+i.slice(d).join("/")}var Rn={path:"/",name:void 0,params:{},query:{},hash:"",fullPath:"/",matched:[],meta:{},redirectedFrom:void 0},$i=(function(e){return e.pop="pop",e.push="push",e})({}),Fi=(function(e){return e.back="back",e.forward="forward",e.unknown="",e})({});function du(e){if(!e)if(ls){let t=document.querySelector("base");e=t&&t.getAttribute("href")||"/",e=e.replace(/^\w+:\/\/[^\/]+/,"")}else e="/";return e[0]!=="/"&&e[0]!=="#"&&(e="/"+e),Om(e)}var Vm=/^[^#]+#/;function uu(e,t){return e.replace(Vm,"#")+t}function qm(e,t){let s=document.documentElement.getBoundingClientRect(),i=e.getBoundingClientRect();return{behavior:t.behavior,left:i.left-s.left-(t.left||0),top:i.top-s.top-(t.top||0)}}var Vo=()=>({left:window.scrollX,top:window.scrollY});function cu(e){let t;if("el"in e){let s=e.el,i=typeof s=="string"&&s.startsWith("#"),o=typeof s=="string"?i?document.getElementById(s.slice(1)):document.querySelector(s):s;if(!o)return;t=qm(o,e)}else t=e;"scrollBehavior"in document.documentElement.style?window.scrollTo(t):window.scrollTo(t.left!=null?t.left:window.scrollX,t.top!=null?t.top:window.scrollY)}function ua(e,t){return(history.state?history.state.position-t:-1)+e}var ia=new Map;function pu(e,t){ia.set(e,t)}function fu(e){let t=ia.get(e);return ia.delete(e),t}function _m(e){return typeof e=="string"||e&&typeof e=="object"}function ca(e){return typeof e=="string"||typeof e=="symbol"}var ut=(function(e){return e[e.MATCHER_NOT_FOUND=1]="MATCHER_NOT_FOUND",e[e.NAVIGATION_GUARD_REDIRECT=2]="NAVIGATION_GUARD_REDIRECT",e[e.NAVIGATION_ABORTED=4]="NAVIGATION_ABORTED",e[e.NAVIGATION_CANCELLED=8]="NAVIGATION_CANCELLED",e[e.NAVIGATION_DUPLICATED=16]="NAVIGATION_DUPLICATED",e})({}),hu=Symbol("");var AZ={[ut.MATCHER_NOT_FOUND]({location:e,currentLocation:t}){return`No match for +"use strict";(()=>{var el=Object.defineProperty;var tl=e=>{throw TypeError(e)};var of=(e,t,s)=>t in e?el(e,t,{enumerable:!0,configurable:!0,writable:!0,value:s}):e[t]=s;var rf=(e,t)=>{for(var s in t)el(e,s,{get:t[s],enumerable:!0})};var xe=(e,t,s)=>of(e,typeof t!="symbol"?t+"":t,s),hr=(e,t,s)=>t.has(e)||tl("Cannot "+s);var re=(e,t,s)=>(hr(e,t,"read from private field"),s?s.call(e):t.get(e)),qe=(e,t,s)=>t.has(e)?tl("Cannot add the same private member more than once"):t instanceof WeakSet?t.add(e):t.set(e,s),$e=(e,t,s,i)=>(hr(e,t,"write to private field"),i?i.call(e,s):t.set(e,s),s),_e=(e,t,s)=>(hr(e,t,"access private method"),s);var nl=(e,t,s,i)=>({set _(o){$e(e,t,o,s)},get _(){return re(e,t,i)}});var he=["abap","abc","actionscript","ada","alda","apache_conf","apex","applescript","aql","asciidoc","asl","assembly_x86","autohotkey","batchfile","c9search","c_cpp","cirru","clojure","cobol","coffee","coldfusion","crystal","csharp","csound_document","csound_orchestra","csound_score","csp","css","curly","d","dart","diff","django","dockerfile","dot","drools","edifact","eiffel","ejs","elixir","elm","erlang","forth","fortran","fsharp","fsl","ftl","gcode","gherkin","gitignore","glsl","gobstones","golang","graphqlschema","groovy","haml","handlebars","haskell","haskell_cabal","haxe","hjson","html","html_elixir","html_ruby","ini","io","jack","jade","java","javascript","json","json5","jsoniq","jsp","jssm","jsx","julia","kotlin","latex","less","liquid","lisp","livescript","logiql","logtalk","lsl","lua","luapage","lucene","makefile","markdown","mask","matlab","maze","mediawiki","mel","mixal","mushcode","mysql","nginx","nim","nix","nsis","nunjucks","objectivec","ocaml","pascal","perl","perl6","pgsql","php","php_laravel_blade","pig","plain_text","powershell","praat","prisma","prolog","properties","protobuf","puppet","python","qml","r","razor","rdoc","red","redshift","rhtml","rst","ruby","rust","sass","scad","scala","scheme","scss","sh","sjs","slim","smarty","snippets","soy_template","space","sparql","sql","sqlserver","stylus","svg","swift","tcl","terraform","tex","text","textile","toml","tsx","turtle","twig","typescript","vala","vbscript","velocity","verilog","vhdl","visualforce","wollok","xml","xquery","yaml","zeek"];var ge={markdown:"/script/markdown.6c8dfb7b1d.min.js",notebook:"/script/notebook.c3144c18ae.min.js",org:"/script/org.f61f262915.min.js",editor:"/script/editor.4f142d3adc.min.js",pdf:"/script/pdf.4d9cc6ff49.min.js"};function sl(e){let t=e.location.hash.slice(1);if(e.history.replaceState(null,"","/review-link"),t.length>2048)return null;let s=new URLSearchParams(t);if([...s.keys()].length!==3||[...s.keys()].some(d=>!["clientId","intentId","token"].includes(d)))return null;let i=s.get("clientId"),o=s.get("intentId"),r=s.get("token");return!/^[a-f0-9]{32}$/.test(i||"")||!/^[a-f0-9]{32}$/.test(o||"")||!/^[a-f0-9]{64}$/.test(r||"")?null:{contract:"4open.artifacts/1",clientId:i,intentId:o,token:r}}function ol(e,t){let{http:s,promises:i,window:o}=t,r=t.takeReviewHandoff(),d=r?{clientId:r.clientId,intentId:r.intentId}:null,p,u,y,h,b,m=!0,w,N=i.defer(),S=()=>[...o.crypto.getRandomValues(new Uint8Array(16))].map(V=>V.toString(16).padStart(2,"0")).join("");Object.assign(e,{repositoryId:"",handoffEnabled:!1,busy:!1,preview:null,acceptAccess:!1,acceptRetention:!1,uncertain:!1,saved:!1,expired:!1,error:r?"":"Open a new artifact link from your submission. This link is missing or invalid."});let R=()=>m&&e.user?.username===b;function v(){m=!1,r=p=u=void 0,N.resolve(),o.clearTimeout(w)}e.on("dispose",v),e.on("routeLeave",v),e.watch(()=>e.user?.username,V=>{!b&&V?b=V:b&&V!==b&&(v(),e.preview=null,e.repositoryId="",e.busy=!1,e.saved=!1,e.handoffEnabled=!1,e.error="Your account changed. Open a new artifact link from your submission.")});let E=()=>({timeout:N.promise,headers:{"Content-Type":"application/json","X-Review-CSRF":u}}),D=V=>V?.status===404?"Artifact linking is not available on this server.":V?.status===401?"Sign in, then open a new artifact link from your submission.":V?.status===403?"This account cannot approve this repository or this link.":"The request could not be completed. You can retry from this page.";e.loadPreview=async()=>{if(!m||!r||e.busy||e.uncertain||e.saved||!e.user?.username)return;b=e.user.username;let V=e.repositoryId.trim();if(!/^[A-Za-z0-9_-]{3,128}$/.test(V)){e.error="Enter the anonymous repository ID from its URL.";return}e.busy=!0,e.error="",e.preview=null,p=void 0,e.acceptAccess=e.acceptRetention=!1,e.expired=!1,o.clearTimeout(w),h||(h=S());try{let _=(await s.get("/api/review-consent/csrf",{timeout:N.promise})).data;if(!R())return;if(u=_.csrf,e.handoffEnabled=_.handoffEnabled===!0,!/^[a-f0-9]{64}$/.test(u||""))throw new Error("invalid_csrf");let z=(await s.post("/api/review-consent/preview",{repositoryId:V,intent:{...r,requestId:h}},E())).data;if(!R())return;if(!z||typeof z.ticket!="string"||!z.ticket||z.ticket.length>8192||typeof z.repositoryName!="string"||!["restricted-review","anonymous-link"].includes(z.policy?.access)||!Number.isSafeInteger(z.policy.version)||!Number.isFinite(Date.parse(z.policy.retainUntil))||!Number.isFinite(Date.parse(z.expiresAt))||Date.parse(z.expiresAt)<=Date.now()||Date.parse(z.expiresAt)>Date.now()+6e5)throw new Error("invalid_preview");p=z.ticket,y=S(),e.preview={repositoryName:z.repositoryName,policy:{...z.policy},expiresAt:z.expiresAt},w=o.setTimeout(()=>{m&&(e.expired=!0)},Math.max(0,Date.parse(z.expiresAt)-Date.now()))}catch(_){R()&&(e.error=D(_))}finally{R()&&(e.busy=!1)}},e.confirmConsent=async()=>{if(!(!R()||e.busy||e.saved||!p||!e.acceptAccess||!e.acceptRetention)){if(Date.parse(e.preview.expiresAt)<=Date.now()){e.expired=!0;return}e.busy=!0,e.error="";try{let V=(await s.post("/api/review-consent/confirm",{ticket:p,requestId:y,acceptAccess:!0,acceptRetention:!0},E())).data;if(!R())return;if(V?.requestId!==y||!Number.isFinite(Date.parse(V.confirmedAt)))throw new Error("invalid_receipt");e.saved=!0,e.uncertain=!1,r=void 0,e.handoffEnabled||(p=void 0)}catch{R()&&(e.uncertain=!0,e.error="The confirmation was not verified. Retry with the same approval, or return to your submission to check its status.")}finally{R()&&(e.busy=!1)}}},e.continueReview=async()=>{if(!R()||e.busy||!e.saved||!e.handoffEnabled||!p||!d)return;e.busy=!0,e.error="";let V,_=()=>{V?.remove(),o.removeEventListener("securitypolicyviolation",z)},z=x=>{x.violatedDirective?.startsWith("form-action")&&(_(),R()&&(e.busy=!1,e.error="The return address was blocked. Return to your submission to check the artifact status."))};try{let x=(await s.post("/api/review-consent/handoff",{ticket:p},E())).data;if(!R())return;let X=x?.completion,I=new URL(x?.callbackUrl);if(!X||Object.keys(X).sort().join(",")!=="clientId,code,contract,expiresAt,intentId"||X.contract!=="4open.artifacts/1"||X.clientId!==d.clientId||X.intentId!==d.intentId||!/^[a-f0-9]{64}$/.test(X.code||"")||!Number.isFinite(Date.parse(X.expiresAt))||Date.parse(X.expiresAt)<=Date.now()||Date.parse(X.expiresAt)>Date.now()+3e5||I.protocol!=="https:"||I.href!==x.callbackUrl||I.username||I.password||x.callbackUrl.includes("?")||x.callbackUrl.includes("#"))throw new Error("invalid_handoff");V=o.document.createElement("form"),V.method="POST",V.action=I.href;let U=o.document.createElement("input");U.type="hidden",U.name="completion",U.value=JSON.stringify(X),V.appendChild(U),o.document.body.appendChild(V),o.addEventListener("securitypolicyviolation",z),e.on("dispose",_),V.submit()}catch{_(),R()&&(e.busy=!1,e.error="The return to review could not be prepared. Retry from this page, or return to your submission to check its status.")}}}var ti=new Map,df=ge;function Jn(e){if(!ti.has(e)){let t=document.createElement("script");t.src=df[e];let s=new Promise((i,o)=>{t.onload=i,t.onerror=()=>{ti.delete(e),t.remove(),o(new Error(`Unable to load ${e}. Please retry.`))}});ti.set(e,s),document.head.appendChild(t)}return ti.get(e)}async function ni(){await Jn("editor"),ace.config.set("basePath","/script/external/ace/")}function Ns(e){let t=Object.create(null);for(let s of e.split(","))t[s]=1;return s=>s in t}var Ze={},In=[],Tt=()=>{},vr=()=>!1,Rs=e=>e.charCodeAt(0)===111&&e.charCodeAt(1)===110&&(e.charCodeAt(2)>122||e.charCodeAt(2)<97),Ps=e=>e.startsWith("onUpdate:"),pt=Object.assign,eo=(e,t)=>{let s=e.indexOf(t);s>-1&&e.splice(s,1)},uf=Object.prototype.hasOwnProperty,je=(e,t)=>uf.call(e,t),Ne=Array.isArray,yn=e=>to(e)==="[object Map]",Xt=e=>to(e)==="[object Set]",il=e=>to(e)==="[object Date]";var Oe=e=>typeof e=="function",it=e=>typeof e=="string",_t=e=>typeof e=="symbol",Ye=e=>e!==null&&typeof e=="object",yr=e=>(Ye(e)||Oe(e))&&Oe(e.then)&&Oe(e.catch),dl=Object.prototype.toString,to=e=>dl.call(e),br=e=>to(e).slice(8,-1),si=e=>to(e)==="[object Object]",oi=e=>it(e)&&e!=="NaN"&&e[0]!=="-"&&""+parseInt(e,10)===e,Ds=Ns(",key,ref,ref_for,ref_key,onVnodeBeforeMount,onVnodeMounted,onVnodeBeforeUpdate,onVnodeUpdated,onVnodeBeforeUnmount,onVnodeUnmounted");var ii=e=>{let t=Object.create(null);return(s=>t[s]||(t[s]=e(s)))},cf=/-\w/g,mt=ii(e=>e.replace(cf,t=>t.slice(1).toUpperCase())),pf=/\B([A-Z])/g,on=ii(e=>e.replace(pf,"-$1").toLowerCase()),Qn=ii(e=>e.charAt(0).toUpperCase()+e.slice(1)),no=ii(e=>e?`on${Qn(e)}`:""),zt=(e,t)=>!Object.is(e,t),As=(e,...t)=>{for(let s=0;s{Object.defineProperty(e,t,{configurable:!0,enumerable:!1,writable:i,value:s})},Ts=e=>{let t=parseFloat(e);return isNaN(t)?e:t};var rl,so=()=>rl||(rl=typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:typeof global<"u"?global:{});function Te(e){if(Ne(e)){let t={};for(let s=0;ss.startsWith("/*")?"":s).split(ff).forEach(s=>{if(s){let i=s.split(mf);i.length>1&&(t[i[0].trim()]=i[1].trim())}}),t}function P(e){let t="";if(it(e))t=e;else if(Ne(e))for(let s=0;sJt(s,t))}var pl=e=>!!(e&&e.__v_isRef===!0),c=e=>it(e)?e:e==null?"":Ne(e)||Ye(e)&&(e.toString===dl||!Oe(e.toString))?pl(e)?c(e.value):JSON.stringify(e,fl,2):String(e),fl=(e,t)=>pl(t)?fl(e,t.value):yn(t)?{[`Map(${t.size})`]:[...t.entries()].reduce((s,[i,o],r)=>(s[gr(i,r)+" =>"]=o,s),{})}:Xt(t)?{[`Set(${t.size})`]:[...t.values()].map(s=>gr(s))}:_t(t)?gr(t):Ye(t)&&!Ne(t)&&!si(t)?String(t):t,gr=(e,t="")=>{var s;return _t(e)?`Symbol(${(s=e.description)!=null?s:t})`:e};function wf(e,...t){console.warn(`[Vue warn] ${e}`,...t)}var ht,ao=class{constructor(t=!1){this.detached=t,this._active=!0,this._on=0,this.effects=[],this.cleanups=[],this._isPaused=!1,this._warnOnRun=!0,this.__v_skip=!0,!t&&ht&&(ht.active?(this.parent=ht,this.index=(ht.scopes||(ht.scopes=[])).push(this)-1):(this._active=!1,this._warnOnRun=!1))}get active(){return this._active}pause(){if(this._active){this._isPaused=!0;let t,s;if(this.scopes){let i=this.scopes.slice();for(t=0,s=i.length;t0&&--this._on===0){if(ht===this)ht=this.prevScope;else{let t=ht;for(;t;){if(t.prevScope===this){t.prevScope=this.prevScope;break}t=t.prevScope}}this.prevScope=void 0}}stop(t){if(this._active){this._active=!1;let s,i;for(s=0,i=this.effects.length;s0)return;if(ro){let t=ro;for(ro=void 0;t;){let s=t.next;t.next=void 0,t.flags&=-9,t=s}}let e;for(;io;){let t=io;for(io=void 0;t;){let s=t.next;if(t.next=void 0,t.flags&=-9,t.flags&1)try{t.trigger()}catch(i){e||(e=i)}t=s}}if(e)throw e}function wl(e){for(let t=e.deps;t;t=t.nextDep)t.version=-1,t.prevActiveLink=t.dep.activeLink,t.dep.activeLink=t}function kl(e){let t,s=e.depsTail,i=s;for(;i;){let o=i.prevDep;i.version===-1?(i===s&&(s=o),Mr(i),kf(i)):t=i,i.dep.activeLink=i.prevActiveLink,i.prevActiveLink=void 0,i=o}e.deps=t,e.depsTail=s}function Er(e){for(let t=e.deps;t;t=t.nextDep)if(t.dep.version!==t.version||t.dep.computed&&(Cl(t.dep.computed)||t.dep.version!==t.version))return!0;return!!e._dirty}function Cl(e){if(e.flags&4&&!(e.flags&16)||(e.flags&=-17,e.globalVersion===lo)||(e.globalVersion=lo,!e.isSSR&&e.flags&128&&(!e.deps&&!e._dirty||!Er(e))))return;e.flags|=2;let t=e.dep,s=nt,i=Qt;nt=e,Qt=!0;try{wl(e);let o=e.fn(e._value);(t.version===0||zt(o,e._value))&&(e.flags|=128,e._value=o,t.version++)}catch(o){throw t.version++,o}finally{nt=s,Qt=i,kl(e),e.flags&=-3}}function Mr(e,t=!1){let{dep:s,prevSub:i,nextSub:o}=e;if(i&&(i.nextSub=o,e.prevSub=void 0),o&&(o.prevSub=i,e.nextSub=void 0),s.subs===e&&(s.subs=i,!i&&s.computed)){s.computed.flags&=-5;for(let r=s.computed.deps;r;r=r.nextDep)Mr(r,!0)}!t&&!--s.sc&&s.map&&s.map.delete(s.key)}function kf(e){let{prevDep:t,nextDep:s}=e;t&&(t.nextDep=s,e.prevDep=void 0),s&&(s.prevDep=t,e.nextDep=void 0)}var Qt=!0,El=[];function Zt(){El.push(Qt),Qt=!1}function xt(){let e=El.pop();Qt=e===void 0?!0:e}function ml(e){let{cleanup:t}=e;if(e.cleanup=void 0,t){let s=nt;nt=void 0;try{t()}finally{nt=s}}}var lo=0,Sr=class{constructor(t,s){this.sub=t,this.dep=s,this.version=s.version,this.nextDep=this.prevDep=this.nextSub=this.prevSub=this.prevActiveLink=void 0}},uo=class{constructor(t){this.computed=t,this.version=0,this.activeLink=void 0,this.subs=void 0,this.map=void 0,this.key=void 0,this.sc=0,this.__v_skip=!0}track(t){if(!nt||!Qt||nt===this.computed)return;let s=this.activeLink;if(s===void 0||s.sub!==nt)s=this.activeLink=new Sr(nt,this),nt.deps?(s.prevDep=nt.depsTail,nt.depsTail.nextDep=s,nt.depsTail=s):nt.deps=nt.depsTail=s,Sl(s);else if(s.version===-1&&(s.version=this.version,s.nextDep)){let i=s.nextDep;i.prevDep=s.prevDep,s.prevDep&&(s.prevDep.nextDep=i),s.prevDep=nt.depsTail,s.nextDep=void 0,nt.depsTail.nextDep=s,nt.depsTail=s,nt.deps===s&&(nt.deps=i)}return s}trigger(t){this.version++,lo++,this.notify(t)}notify(t){Or();try{for(let s=this.subs;s;s=s.prevSub)s.sub.notify()&&s.sub.dep.notify()}finally{Ir()}}};function Sl(e){if(e.dep.sc++,e.sub.flags&4){let t=e.dep.computed;if(t&&!e.dep.subs){t.flags|=20;for(let i=t.deps;i;i=i.nextDep)Sl(i)}let s=e.dep.subs;s!==e&&(e.prevSub=s,s&&(s.nextSub=e)),e.dep.subs=e}}var Nr=new WeakMap,xn=Symbol(""),Rr=Symbol(""),co=Symbol("");function Et(e,t,s){if(Qt&&nt){let i=Nr.get(e);i||Nr.set(e,i=new Map);let o=i.get(s);o||(i.set(s,o=new uo),o.map=i,o.key=s),o.track()}}function an(e,t,s,i,o,r){let d=Nr.get(e);if(!d){lo++;return}let p=u=>{u&&u.trigger()};if(Or(),t==="clear")d.forEach(p);else{let u=Ne(e),y=u&&oi(s);if(u&&s==="length"){let h=Number(i);d.forEach((b,m)=>{(m==="length"||m===co||!_t(m)&&m>=h)&&p(b)})}else switch((s!==void 0||d.has(void 0))&&p(d.get(s)),y&&p(d.get(co)),t){case"add":u?y&&p(d.get("length")):(p(d.get(xn)),yn(e)&&p(d.get(Rr)));break;case"delete":u||(p(d.get(xn)),yn(e)&&p(d.get(Rr)));break;case"set":yn(e)&&p(d.get(xn));break}}Ir()}function Os(e){let t=We(e);return t===e||(Et(t,"iterate",co),Ot(e))?t:Ht(e)?dn(e)?t.map(s=>wn(Lt(s))):t.map(wn):t.map(Lt)}function po(e){return Et(e=We(e),"iterate",co),e}function rn(e,t){return Ht(e)?wn(dn(e)?Lt(t):t):Lt(t)}var Cf={__proto__:null,[Symbol.iterator](){return kr(this,Symbol.iterator,e=>rn(this,e))},concat(...e){return Os(this).concat(...e.map(t=>Ne(t)?Os(t):t))},entries(){return kr(this,"entries",e=>(e[1]=rn(this,e[1]),e))},every(e,t){return bn(this,"every",e,t,void 0,arguments)},filter(e,t){return bn(this,"filter",e,t,s=>s.map(i=>rn(this,i)),arguments)},find(e,t){return bn(this,"find",e,t,s=>rn(this,s),arguments)},findIndex(e,t){return bn(this,"findIndex",e,t,void 0,arguments)},findLast(e,t){return bn(this,"findLast",e,t,s=>rn(this,s),arguments)},findLastIndex(e,t){return bn(this,"findLastIndex",e,t,void 0,arguments)},forEach(e,t){return bn(this,"forEach",e,t,void 0,arguments)},includes(...e){return Cr(this,"includes",e)},indexOf(...e){return Cr(this,"indexOf",e)},join(e){return Os(this).join(e)},lastIndexOf(...e){return Cr(this,"lastIndexOf",e)},map(e,t){return bn(this,"map",e,t,void 0,arguments)},pop(){return oo(this,"pop")},push(...e){return oo(this,"push",e)},reduce(e,...t){return gl(this,"reduce",e,t)},reduceRight(e,...t){return gl(this,"reduceRight",e,t)},shift(){return oo(this,"shift")},some(e,t){return bn(this,"some",e,t,void 0,arguments)},splice(...e){return oo(this,"splice",e)},toReversed(){return Os(this).toReversed()},toSorted(e){return Os(this).toSorted(e)},toSpliced(...e){return Os(this).toSpliced(...e)},unshift(...e){return oo(this,"unshift",e)},values(){return kr(this,"values",e=>rn(this,e))}};function kr(e,t,s){let i=po(e),o=i[t],r=o.call(i);if(i!==e&&!Ot(e)){if(r[Symbol.toStringTag]==="Array Iterator"){let d=Object.create(Object.getPrototypeOf(r));return d.next=()=>hl(r.next(),s),o!==Nl[t]&&Object.defineProperties(d,{return:{get(){let p=r.return;return typeof p=="function"?p.bind(r):p}},throw:{get(){let p=r.throw;return typeof p=="function"?p.bind(r):p}}}),d}r._next=r.next,r.next=()=>hl(r._next(),s)}return r}function hl(e,t){return e.done||(e.value=t(e.value)),e}var Nl=Array.prototype;function bn(e,t,s,i,o,r){let d=po(e),p=d!==e&&!Ot(e),u=d[t];if(u!==Nl[t]){let b=u.apply(e,r);return p?Lt(b):b}let y=s;d!==e&&(p?y=function(b,m){return s.call(this,rn(e,b),m,e)}:s.length>2&&(y=function(b,m){return s.call(this,b,m,e)}));let h=u.call(d,y,i);return p&&o?o(h):h}function gl(e,t,s,i){let o=po(e),r=o!==e&&!Ot(e),d=s,p=!1;o!==e&&(r?(p=i.length===0,d=function(y,h,b){return p&&(p=!1,y=rn(e,y)),s.call(this,y,rn(e,h),b,e)}):s.length>3&&(d=function(y,h,b){return s.call(this,y,h,b,e)}));let u=o[t](d,...i);return p?rn(e,u):u}function Cr(e,t,s){let i=We(e);Et(i,"iterate",co);let o=i[t](...s);return(o===-1||o===!1)&&mo(s[0])?(s[0]=We(s[0]),i[t](...s)):o}function oo(e,t,s=[]){Zt(),Or();let i=We(e)[t].apply(e,s);return Ir(),xt(),i}var Ef=Ns("__proto__,__v_isRef,__isVue"),Rl=new Set(Object.getOwnPropertyNames(Symbol).filter(e=>e!=="arguments"&&e!=="caller").map(e=>Symbol[e]).filter(_t));function Sf(e){_t(e)||(e=String(e));let t=We(this);return Et(t,"has",e),t.hasOwnProperty(e)}var pi=class{constructor(t=!1,s=!1){this._isReadonly=t,this._isShallow=s}get(t,s,i){if(s==="__v_skip")return t.__v_skip;let o=this._isReadonly,r=this._isShallow;if(s==="__v_isReactive")return!o;if(s==="__v_isReadonly")return o;if(s==="__v_isShallow")return r;if(s==="__v_raw")return i===(o?r?Mf:Al:r?Dl:Pl).get(t)||Object.getPrototypeOf(t)===Object.getPrototypeOf(i)?t:void 0;let d=Ne(t);if(!o){let u;if(d&&(u=Cf[s]))return u;if(s==="hasOwnProperty")return Sf}let p=Reflect.get(t,s,wt(t)?t:i);if((_t(s)?Rl.has(s):Ef(s))||(o||Et(t,"get",s),r))return p;if(wt(p)){let u=d&&oi(s)?p:p.value;return o&&Ye(u)?mi(u):u}return Ye(p)?o?mi(p):st(p):p}},fi=class extends pi{constructor(t=!1){super(!1,t)}set(t,s,i,o){let r=t[s],d=Ne(t)&&oi(s);if(!this._isShallow){let y=Ht(r);if(!Ot(i)&&!Ht(i)&&(r=We(r),i=We(i)),!d&&wt(r)&&!wt(i))return y||(r.value=i),!0}let p=d?Number(s)e,di=e=>Reflect.getPrototypeOf(e);function Df(e,t,s){return function(...i){let o=this.__v_raw,r=We(o),d=yn(r),p=e==="entries"||e===Symbol.iterator&&d,u=e==="keys"&&d,y=o[e](...i),h=s?Dr:t?wn:Lt;return!t&&Et(r,"iterate",u?Rr:xn),pt(Object.create(y),{next(){let{value:b,done:m}=y.next();return m?{value:b,done:m}:{value:p?[h(b[0]),h(b[1])]:h(b),done:m}}})}}function ui(e){return function(...t){return e==="delete"?!1:e==="clear"?void 0:this}}function Af(e,t){let s={get(o){let r=this.__v_raw,d=We(r),p=We(o);e||(zt(o,p)&&Et(d,"get",o),Et(d,"get",p));let{has:u}=di(d),y=t?Dr:e?wn:Lt;if(u.call(d,o))return y(r.get(o));if(u.call(d,p))return y(r.get(p));r!==d&&r.get(o)},get size(){let o=this.__v_raw;return!e&&Et(We(o),"iterate",xn),o.size},has(o){let r=this.__v_raw,d=We(r),p=We(o);return e||(zt(o,p)&&Et(d,"has",o),Et(d,"has",p)),o===p?r.has(o):r.has(o)||r.has(p)},forEach(o,r){let d=this,p=d.__v_raw,u=We(p),y=t?Dr:e?wn:Lt;return!e&&Et(u,"iterate",xn),p.forEach((h,b)=>o.call(r,y(h),y(b),d))}};return pt(s,e?{add:ui("add"),set:ui("set"),delete:ui("delete"),clear:ui("clear")}:{add(o){let r=We(this),d=di(r),p=We(o),u=!t&&!Ot(o)&&!Ht(o)?p:o;return d.has.call(r,u)||zt(o,u)&&d.has.call(r,o)||zt(p,u)&&d.has.call(r,p)||(r.add(u),an(r,"add",u,u)),this},set(o,r){!t&&!Ot(r)&&!Ht(r)&&(r=We(r));let d=We(this),{has:p,get:u}=di(d),y=p.call(d,o);y||(o=We(o),y=p.call(d,o));let h=u.call(d,o);return d.set(o,r),y?zt(r,h)&&an(d,"set",o,r,h):an(d,"add",o,r),this},delete(o){let r=We(this),{has:d,get:p}=di(r),u=d.call(r,o);u||(o=We(o),u=d.call(r,o));let y=p?p.call(r,o):void 0,h=r.delete(o);return u&&an(r,"delete",o,void 0,y),h},clear(){let o=We(this),r=o.size!==0,d=void 0,p=o.clear();return r&&an(o,"clear",void 0,void 0,d),p}}),["keys","values","entries",Symbol.iterator].forEach(o=>{s[o]=Df(o,e,t)}),s}function Vr(e,t){let s=Af(e,t);return(i,o,r)=>o==="__v_isReactive"?!e:o==="__v_isReadonly"?e:o==="__v_isShallow"?t:o==="__v_raw"?i:Reflect.get(je(s,o)&&o in i?s:i,o,r)}var Tf={get:Vr(!1,!1)},Of={get:Vr(!1,!0)},If={get:Vr(!0,!1)};var Pl=new WeakMap,Dl=new WeakMap,Al=new WeakMap,Mf=new WeakMap;function Vf(e){switch(e){case"Object":case"Array":return 1;case"Map":case"Set":case"WeakMap":case"WeakSet":return 2;default:return 0}}function st(e){return Ht(e)?e:qr(e,!1,Nf,Tf,Pl)}function fo(e){return qr(e,!1,Pf,Of,Dl)}function mi(e){return qr(e,!0,Rf,If,Al)}function qr(e,t,s,i,o){if(!Ye(e)||e.__v_raw&&!(t&&e.__v_isReactive)||e.__v_skip||!Object.isExtensible(e))return e;let r=o.get(e);if(r)return r;let d=Vf(br(e));if(d===0)return e;let p=new Proxy(e,d===2?i:s);return o.set(e,p),p}function dn(e){return Ht(e)?dn(e.__v_raw):!!(e&&e.__v_isReactive)}function Ht(e){return!!(e&&e.__v_isReadonly)}function Ot(e){return!!(e&&e.__v_isShallow)}function mo(e){return e?!!e.__v_raw:!1}function We(e){let t=e&&e.__v_raw;return t?We(t):e}function un(e){return!je(e,"__v_skip")&&Object.isExtensible(e)&&ri(e,"__v_skip",!0),e}var Lt=e=>Ye(e)?st(e):e,wn=e=>Ye(e)?mi(e):e;function wt(e){return e?e.__v_isRef===!0:!1}function St(e){return Tl(e,!1)}function gi(e){return Tl(e,!0)}function Tl(e,t){return wt(e)?e:new Ar(e,t)}var Ar=class{constructor(t,s){this.dep=new uo,this.__v_isRef=!0,this.__v_isShallow=!1,this._rawValue=s?t:We(t),this._value=s?t:Lt(t),this.__v_isShallow=s}get value(){return this.dep.track(),this._value}set value(t){let s=this._rawValue,i=this.__v_isShallow||Ot(t)||Ht(t);t=i?t:We(t),zt(t,s)&&(this._rawValue=t,this._value=i?t:Lt(t),this.dep.trigger())}};function kn(e){return wt(e)?e.value:e}var qf={get:(e,t,s)=>t==="__v_raw"?e:kn(Reflect.get(e,t,s)),set:(e,t,s,i)=>{let o=e[t];return wt(o)&&!wt(s)?(o.value=s,!0):Reflect.set(e,t,s,i)}};function vi(e){return dn(e)?e:new Proxy(e,qf)}var Tr=class{constructor(t,s,i){this.fn=t,this.setter=s,this._value=void 0,this.dep=new uo(this),this.__v_isRef=!0,this.deps=void 0,this.depsTail=void 0,this.flags=16,this.globalVersion=lo-1,this.next=void 0,this.effect=this,this.__v_isReadonly=!s,this.isSSR=i}notify(){if(this.flags|=16,!(this.flags&8)&&nt!==this)return bl(this,!0),!0}get value(){let t=this.dep.track();return Cl(this),t&&(t.version=this.dep.version),this._value}set value(t){this.setter&&this.setter(t)}};function Ol(e,t,s=!1){let i,o;return Oe(e)?i=e:(i=e.get,o=e.set),new Tr(i,o,s)}var ci={},hi=new WeakMap,Zn;function Il(e,t=!1,s=Zn){if(s){let i=hi.get(s);i||hi.set(s,i=[]),i.push(e)}}function Ml(e,t,s=Ze){let{immediate:i,deep:o,once:r,scheduler:d,augmentJob:p,call:u}=s,y=_=>{(s.onWarn||wf)("Invalid watch source: ",_,"A watch source can only be a getter/effect function, a ref, a reactive object, or an array of these types.")},h=_=>o?_:Ot(_)||o===!1||o===0?ln(_,1):ln(_),b,m,w,N,S=!1,R=!1;if(wt(e)?(m=()=>e.value,S=Ot(e)):dn(e)?(m=()=>h(e),S=!0):Ne(e)?(R=!0,S=e.some(_=>dn(_)||Ot(_)),m=()=>e.map(_=>{if(wt(_))return _.value;if(dn(_))return h(_);if(Oe(_))return u?u(_,2):_()})):Oe(e)?t?m=u?()=>u(e,2):e:m=()=>{if(w){Zt();try{w()}finally{xt()}}let _=Zn;Zn=b;try{return u?u(e,3,[N]):e(N)}finally{Zn=_}}:m=Tt,t&&o){let _=m,z=o===!0?1/0:o;m=()=>ln(_(),z)}let v=vl(),E=()=>{b.stop(),v&&v.active&&eo(v.effects,b)};if(r&&t){let _=t;t=(...z)=>{try{return _(...z)}finally{E()}}}let D=R?new Array(e.length).fill(ci):ci,V=_=>{if(!(!(b.flags&1)||!b.dirty&&!_))if(t){let z=b.run();if(_||o||S||(R?z.some((x,X)=>zt(x,D[X])):zt(z,D))){let x=Zn;Zt();try{w&&w(),Zn=b;let X=[z,D===ci?void 0:R&&D[0]===ci?[]:D,N];D=z,u?u(t,3,X):t(...X)}finally{Zn=x,xt()}}}else b.run()};return p&&p(V),b=new Is(m),b.scheduler=d?()=>d(V,!1):V,N=_=>Il(_,!1,b),w=b.onStop=()=>{let _=hi.get(b);if(_){if(u)u(_,4);else for(let z of _)z();hi.delete(b)}},t?i?V(!0):D=b.run():d?d(V.bind(null,!0),!0):b.run(),E.pause=b.pause.bind(b),E.resume=b.resume.bind(b),E.stop=E,E}function ln(e,t=1/0,s){if(t<=0||!Ye(e)||e.__v_skip||(s=s||new Map,(s.get(e)||0)>=t))return e;if(s.set(e,t),t--,wt(e))ln(e.value,t,s);else if(Ne(e))for(let i=0;i{ln(i,t,s)});else if(si(e)){for(let i in e)ln(e[i],t,s);for(let i of Object.getOwnPropertySymbols(e))Object.prototype.propertyIsEnumerable.call(e,i)&&ln(e[i],t,s)}return e}function Ro(e,t,s,i){try{return i?e(...i):e()}catch(o){Po(o,t,s)}}function jt(e,t,s,i){if(Oe(e)){let o=Ro(e,t,s,i);return o&&yr(o)&&o.catch(r=>{Po(r,t,s)}),o}if(Ne(e)){let o=[];for(let r=0;r>>1,o=Dt[i],r=ko(o);r=ko(s)?Dt.push(e):Dt.splice(Uf(t),0,e),e.flags|=1,Jl()}}function Jl(){wi||(wi=Xl.then(ed))}function Ql(e){if(!Ne(e))Mn&&e.id===-1?Mn.splice(Ms+1,0,e):e.flags&1||(pn.push(e),e.flags|=1);else for(let t=0;t=t))continue;Dt.splice(i,1),i=e?i-1:en,o.flags&4&&(o.flags&=-2),o(),o.flags&4||(o.flags&=-2)}}}function xl(e,t,s=0){if(pn.length){let i=pn,o=0;if(t){i=[];for(let d=0;dko(d)-ko(p));if(pn.length=o,Mn){for(let d=0;de.id==null?e.flags&2?-1:1/0:e.id;function ed(e){let t=Tt;try{for(en=0;en{i._d&&Si(-1);let r=ki(t),d=ss.length,p;try{p=e(...o)}finally{for(let u=ss.length;u>d;u--)Td();ki(r),i._d&&Si(1)}return p};return i._n=!0,i._c=!0,i._d=!0,i}function T(e,t){if($t===null)return e;let s=Ii($t),i=e.dirs||(e.dirs=[]);for(let o=0;o1)return s&&Oe(t)?t.call(i&&i.proxy):t}}var Hf=Symbol.for("v-scx"),jf=()=>{{let e=Mt(Hf);return e}};function ut(e,t,s){return nd(e,t,s)}function nd(e,t,s=Ze){let{immediate:i,deep:o,flush:r,once:d}=s,p=pt({},s),u=t&&i||!t&&r!=="post",y;if(_s){if(r==="sync"){let w=jf();y=w.__watcherHandles||(w.__watcherHandles=[])}else if(!u){let w=()=>{};return w.stop=Tt,w.resume=Tt,w.pause=Tt,w}}let h=Nt;p.call=(w,N,S)=>jt(w,h,N,S);let b=!1;r==="post"?p.scheduler=w=>{w.i=h,It(w,h&&h.suspense)}:r!=="sync"&&(b=!0,p.scheduler=(w,N)=>{N?w():Kr(w)}),p.augmentJob=w=>{t&&(w.flags|=4),b&&(w.flags|=2,h&&(w.id=h.uid,w.i=h))};let m=Ml(e,t,p);return _s&&(y?y.push(m):u&&m()),m}function Gf(e,t,s){let i=this.proxy,o=it(e)?e.includes(".")?sd(i,e):()=>i[e]:e.bind(i,i),r;Oe(t)?r=t:(r=t.handler,s=t);let d=To(this),p=nd(o,r.bind(i),s);return d(),p}function sd(e,t){let s=t.split(".");return()=>{let i=e;for(let o=0;oe.__isTeleport;var Lr=Symbol("_leaveCb");function Kf(e){let t=e[0];if(e.length>1){let s=!1;for(let i of e)if(i.type!==tn){t=i,s=!0;break}}return t}function od(e){if(!Di(e))return Pi(e.type)&&e.children?Kf(e.children):e;if(e.component)return e.component.subTree;let{shapeFlag:t,children:s}=e;if(s){if(t&16)return s[0];if(t&32&&Oe(s.default))return s.default()}}function Co(e,t){if(e.shapeFlag&6&&e.component){e.transition=t;let s=e.component.subTree;Co(Pi(s.type)&&od(s)||s,t)}else if(e.shapeFlag&128)e.ssContent.transition=t.clone(e.ssContent),e.ssFallback.transition=t.clone(e.ssFallback);else if(e.transition=t,e.type===q&&Ne(e.children)){let s=gd(e.children,!1);s&&Co(s,t)}}function Br(e){if(e.component)return Br(e.component.subTree);if(e.type===q){let t=Ne(e.children)&&gd(e.children,!1);return t?Br(t):void 0}if(e.type!==tn)return e}function Do(e,t){return Oe(e)?pt({name:e.name},t,{setup:e}):e}function Yr(e){e.ids=[e.ids[0]+e.ids[2]+++"-",0,0]}function Vl(e,t){let s;return!!((s=Object.getOwnPropertyDescriptor(e,t))&&!s.configurable)}var Ci=new WeakMap;function vo(e,t,s,i,o=!1){if(Ne(e)){e.forEach((S,R)=>vo(S,t&&(Ne(t)?t[R]:t),s,i,o));return}if(yo(i)&&!o){i.shapeFlag&512&&i.type.__asyncResolved&&i.component.subTree.component&&vo(e,t,s,i.component.subTree);return}let r=i.shapeFlag&4?Ii(i.component):i.el,d=o?null:r,{i:p,r:u}=e,y=t&&t.r,h=p.refs===Ze?p.refs={}:p.refs,b=p.setupState,m=We(b),w=b===Ze?vr:S=>Vl(h,S)?!1:je(m,S),N=(S,R)=>!(R&&Vl(h,R));if(y!=null&&y!==u){if(ql(t),it(y))h[y]=null,w(y)&&(b[y]=null);else if(wt(y)){let S=t;N(y,S.k)&&(y.value=null),S.k&&(h[S.k]=null)}}if(Oe(u))Ro(u,p,12,[d,h]);else{let S=it(u),R=wt(u);if(S||R){let v=()=>{if(e.f){let E=S?w(u)?b[u]:h[u]:N(u)||!e.k?u.value:h[e.k];if(o)Ne(E)&&eo(E,r);else if(Ne(E))E.includes(r)||E.push(r);else if(S)h[u]=[r],w(u)&&(b[u]=h[u]);else{let D=[r];N(u,e.k)&&(u.value=D),e.k&&(h[e.k]=D)}}else S?(h[u]=d,w(u)&&(b[u]=d)):R&&(N(u,e.k)&&(u.value=d),e.k&&(h[e.k]=d))};if(d){let E=()=>{v(),Ci.delete(e)};E.id=-1,Ci.set(e,E),It(E,s)}else ql(e),v()}}}function ql(e){let t=Ci.get(e);t&&(t.flags|=8,Ci.delete(e))}var _l=e=>e.nodeType===8;var jZ=so().requestIdleCallback||(e=>setTimeout(e,1)),GZ=so().cancelIdleCallback||(e=>clearTimeout(e));function Yf(e,t){if(_l(e)&&e.data==="["){let s=1,i=e.nextSibling;for(;i;){if(i.nodeType===1){if(t(i)===!1)break}else if(_l(i))if(i.data==="]"){if(--s===0)break}else i.data==="["&&s++;i=i.nextSibling}}else t(e)}var yo=e=>!!e.type.__asyncLoader;function id(e){Oe(e)&&(e={loader:e});let{loader:t,loadingComponent:s,errorComponent:i,delay:o=200,hydrate:r,timeout:d,suspensible:p=!0,onError:u}=e,y=null,h,b=0,m=()=>(b++,y=null,w()),w=()=>{let N;return y||(N=y=t().catch(S=>{if(S=S instanceof Error?S:new Error(String(S)),u)return new Promise((R,v)=>{u(S,()=>R(m()),()=>v(S),b+1)});throw S}).then(S=>N!==y&&y?y:(S&&(S.__esModule||S[Symbol.toStringTag]==="Module")&&(S=S.default),h=S,S)))};return Do({name:"AsyncComponentWrapper",__asyncLoader:w,__asyncHydrate(N,S,R){let v=N.isConnected,E=!1;(S.bu||(S.bu=[])).push(()=>E=!0);let D=()=>{E||!N.parentNode||v&&!N.isConnected||R()},V=r?()=>{let _=r(D,z=>Yf(N,z));_&&(S.bum||(S.bum=[])).push(_)}:D;h?V():w().then(()=>!S.isUnmounted&&V())},get __asyncResolved(){return h},setup(){let N=Nt;if(Yr(N),h)return()=>yi(h,N);let S=_=>{y=null,Po(_,N,13,!i)};if(p&&N.suspense||_s)return w().then(_=>()=>yi(_,N)).catch(_=>(S(_),()=>i?Ie(i,{error:_}):null));let R=St(!1),v=St(),E=St(!!o),D,V;return Ao(()=>{D!=null&&clearTimeout(D),V!=null&&clearTimeout(V)}),o&&(V=setTimeout(()=>{N.isUnmounted||(E.value=!1)},o)),d!=null&&(D=setTimeout(()=>{if(!N.isUnmounted&&!R.value&&!v.value){let _=new Error(`Async component timed out after ${d}ms.`);S(_),v.value=_}},d)),w().then(()=>{N.isUnmounted||(R.value=!0,N.parent&&Di(N.parent.vnode)&&N.parent.update())}).catch(_=>{if(N.isUnmounted){y=null;return}S(_),v.value=_}),()=>{if(R.value&&h)return yi(h,N);if(v.value&&i)return Ie(i,{error:v.value});if(s&&!E.value)return yi(s,N)}}})}function yi(e,t){let{ref:s,props:i,children:o,ce:r}=t.vnode,d=Ie(e,i,o);return d.ref=s,d.ce=r,delete t.vnode.ce,d}var Di=e=>e.type.__isKeepAlive;function rd(e,t){ld(e,"a",t)}function ad(e,t){ld(e,"da",t)}function ld(e,t,s=Nt){let i=e.__wdc||(e.__wdc=()=>{let o=s;for(;o;){if(o.isDeactivated)return;o=o.parent}return e()});if(Ai(t,i,s),s){let o=s.parent;for(;o&&o.parent;)Di(o.parent.vnode)&&Xf(i,t,s,o),o=o.parent}}function Xf(e,t,s,i){let o=Ai(t,e,i,!0);Ao(()=>{eo(i[t],o)},s)}function Ai(e,t,s=Nt,i=!1){if(s){let o=s[e]||(s[e]=[]),r=t.__weh||(t.__weh=(...d)=>{Zt();let p=To(s),u=jt(t,s,e,d);return p(),xt(),u});return i?o.unshift(r):o.push(r),r}}var En=e=>(t,s=Nt)=>{(!_s||e==="sp")&&Ai(e,(...i)=>t(...i),s)},Jf=En("bm"),mn=En("m"),dd=En("bu"),ud=En("u"),is=En("bum"),Ao=En("um"),Qf=En("sp"),Zf=En("rtg"),xf=En("rtc");function em(e,t=Nt){Ai("ec",e,t)}var cd="components",tm="directives";function Xe(e,t){return pd(cd,e,!0,t)||e}var nm=Symbol.for("v-ndc");function De(e){return pd(tm,e)}function pd(e,t,s=!0,i=!1){let o=$t||Nt;if(o){let r=o.type;if(e===cd){let p=Fm(r,!1);if(p&&(p===t||p===mt(t)||p===Qn(mt(t))))return r}let d=Ll(o[e]||r[e],t)||Ll(o.appContext[e],t);return!d&&i?r:d}}function Ll(e,t){return e&&(e[t]||e[mt(t)]||e[Qn(mt(t))])}function Q(e,t,s,i){let o,r=s&&s[i],d=Ne(e);if(d||it(e)){let p=d&&dn(e),u=!1,y=!1;p&&(u=!Ot(e),y=Ht(e),e=po(e)),o=new Array(e.length);for(let h=0,b=e.length;ht(p,u,void 0,r&&r[u]));else{let p=Object.keys(e);o=new Array(p.length);for(let u=0,y=p.length;ue?Vd(e)?Ii(e):zr(e.parent):null;var bo=pt(Object.create(null),{$:e=>e,$el:e=>e.vnode.el,$data:e=>e.data,$props:e=>e.props,$attrs:e=>e.attrs,$slots:e=>e.slots,$refs:e=>e.refs,$parent:e=>zr(e.parent),$root:e=>zr(e.root),$host:e=>e.ce,$emit:e=>e.emit,$options:e=>Xr(e),$forceUpdate:e=>e.f||(e.f=()=>{Kr(e.update)}),$nextTick:e=>e.n||(e.n=tt.bind(e.proxy)),$watch:e=>Gf.bind(e)});var $r=(e,t)=>e!==Ze&&!e.__isScriptSetup&&je(e,t),sm={get({_:e},t){if(t==="__v_skip")return!0;let{ctx:s,setupState:i,data:o,props:r,accessCache:d,type:p,appContext:u}=e;if(t[0]!=="$"){let m=d[t];if(m!==void 0)switch(m){case 1:return i[t];case 2:return o[t];case 4:return s[t];case 3:return r[t]}else{if($r(i,t))return d[t]=1,i[t];if(o!==Ze&&je(o,t))return d[t]=2,o[t];if(je(r,t))return d[t]=3,r[t];if(s!==Ze&&je(s,t))return d[t]=4,s[t];Hr&&(d[t]=0)}}let y=bo[t],h,b;if(y)return t==="$attrs"&&Et(e.attrs,"get",""),y(e);if((h=p.__cssModules)&&(h=h[t]))return h;if(s!==Ze&&je(s,t))return d[t]=4,s[t];if(b=u.config.globalProperties,je(b,t))return b[t]},set({_:e},t,s){let{data:i,setupState:o,ctx:r}=e;return $r(o,t)?(o[t]=s,!0):i!==Ze&&je(i,t)?(i[t]=s,!0):je(e.props,t)||t[0]==="$"&&t.slice(1)in e?!1:(r[t]=s,!0)},has({_:{data:e,setupState:t,accessCache:s,ctx:i,appContext:o,props:r,type:d}},p){let u;return!!(s[p]||e!==Ze&&p[0]!=="$"&&je(e,p)||$r(t,p)||je(r,p)||je(i,p)||je(bo,p)||je(o.config.globalProperties,p)||(u=d.__cssModules)&&u[p])},defineProperty(e,t,s){return s.get!=null?e._.accessCache[t]=0:je(s,"value")&&this.set(e,t,s.value,null),Reflect.defineProperty(e,t,s)}};function $l(e){return Ne(e)?e.reduce((t,s)=>(t[s]=null,t),{}):e}var Hr=!0;function om(e){let t=Xr(e),s=e.proxy,i=e.ctx;Hr=!1,t.beforeCreate&&Fl(t.beforeCreate,e,"bc");let{data:o,computed:r,methods:d,watch:p,provide:u,inject:y,created:h,beforeMount:b,mounted:m,beforeUpdate:w,updated:N,activated:S,deactivated:R,beforeDestroy:v,beforeUnmount:E,destroyed:D,unmounted:V,render:_,renderTracked:z,renderTriggered:x,errorCaptured:X,serverPrefetch:I,expose:U,inheritAttrs:C,components:L,directives:H,filters:K}=t;if(y&&im(y,i,null),d)for(let Y in d){let me=d[Y];Oe(me)&&(i[Y]=me.bind(s))}if(o){let Y=o.call(s,s);Ye(Y)&&(e.data=st(Y))}if(Hr=!0,r)for(let Y in r){let me=r[Y],Se=Oe(me)?me.bind(s,s):Oe(me.get)?me.get.bind(s,s):Tt,Ue=!Oe(me)&&Oe(me.set)?me.set.bind(s):Tt,Be=Rt({get:Se,set:Ue});Object.defineProperty(i,Y,{enumerable:!0,configurable:!0,get:()=>Be.value,set:Qe=>Be.value=Qe})}if(p)for(let Y in p)fd(p[Y],i,s,Y);if(u){let Y=Oe(u)?u.call(s):u;Reflect.ownKeys(Y).forEach(me=>{os(me,Y[me])})}h&&Fl(h,e,"c");function se(Y,me){Ne(me)?me.forEach(Se=>Y(Se.bind(s))):me&&Y(me.bind(s))}if(se(Jf,b),se(mn,m),se(dd,w),se(ud,N),se(rd,S),se(ad,R),se(em,X),se(xf,z),se(Zf,x),se(is,E),se(Ao,V),se(Qf,I),Ne(U))if(U.length){let Y=e.exposed||(e.exposed={});U.forEach(me=>{Object.defineProperty(Y,me,{get:()=>s[me],set:Se=>s[me]=Se,enumerable:!0})})}else e.exposed||(e.exposed={});_&&e.render===Tt&&(e.render=_),C!=null&&(e.inheritAttrs=C),L&&(e.components=L),H&&(e.directives=H),I&&Yr(e)}function im(e,t,s=Tt){Ne(e)&&(e=jr(e));for(let i in e){let o=e[i],r;Ye(o)?"default"in o?r=Mt(o.from||i,o.default,!0):r=Mt(o.from||i):r=Mt(o),wt(r)?Object.defineProperty(t,i,{enumerable:!0,configurable:!0,get:()=>r.value,set:d=>r.value=d}):t[i]=r}}function Fl(e,t,s){jt(Ne(e)?e.map(i=>i.bind(t.proxy)):e.bind(t.proxy),t,s)}function fd(e,t,s,i){let o=i.includes(".")?sd(s,i):()=>s[i];if(it(e)){let r=t[e];Oe(r)&&ut(o,r)}else if(Oe(e))ut(o,e.bind(s));else if(Ye(e))if(Ne(e))e.forEach(r=>fd(r,t,s,i));else{let r=Oe(e.handler)?e.handler.bind(s):t[e.handler];Oe(r)&&ut(o,r,e)}}function Xr(e){let t=e.type,{mixins:s,extends:i}=t,{mixins:o,optionsCache:r,config:{optionMergeStrategies:d}}=e.appContext,p=r.get(t),u;return p?u=p:!o.length&&!s&&!i?u=t:(u={},o.length&&o.forEach(y=>Ei(u,y,d,!0)),Ei(u,t,d)),Ye(t)&&r.set(t,u),u}function Ei(e,t,s,i=!1){let{mixins:o,extends:r}=t;r&&Ei(e,r,s,!0),o&&o.forEach(d=>Ei(e,d,s,!0));for(let d in t)if(!(i&&d==="expose")){let p=rm[d]||s&&s[d];e[d]=p?p(e[d],t[d]):t[d]}return e}var rm={data:Ul,props:Bl,emits:Bl,methods:go,computed:go,beforeCreate:Pt,created:Pt,beforeMount:Pt,mounted:Pt,beforeUpdate:Pt,updated:Pt,beforeDestroy:Pt,beforeUnmount:Pt,destroyed:Pt,unmounted:Pt,activated:Pt,deactivated:Pt,errorCaptured:Pt,serverPrefetch:Pt,components:go,directives:go,watch:lm,provide:Ul,inject:am};function Ul(e,t){return t?e?function(){return pt(Oe(e)?e.call(this,this):e,Oe(t)?t.call(this,this):t)}:t:e}function am(e,t){return go(jr(e),jr(t))}function jr(e){if(Ne(e)){let t={};for(let s=0;st==="modelValue"||t==="model-value"?e.modelModifiers:e[`${t}Modifiers`]||e[`${mt(t)}Modifiers`]||e[`${on(t)}Modifiers`];function pm(e,t,...s){if(e.isUnmounted)return;let i=e.vnode.props||Ze,o=s,r=t.startsWith("update:"),d=r&&cm(i,t.slice(7));d&&(d.trim&&(o=s.map(h=>it(h)?h.trim():h)),d.number&&(o=o.map(Ts)));let p,u=i[p=no(t)]||i[p=no(mt(t))];!u&&r&&(u=i[p=no(on(t))]),u&&jt(u,e,6,o);let y=i[p+"Once"];if(y){if(!e.emitted)e.emitted={};else if(e.emitted[p])return;e.emitted[p]=!0,jt(y,e,6,o)}}var fm=new WeakMap;function hd(e,t,s=!1){let i=s?fm:t.emitsCache,o=i.get(e);if(o!==void 0)return o;let r=e.emits,d={},p=!1;if(!Oe(e)){let u=y=>{let h=hd(y,t,!0);h&&(p=!0,pt(d,h))};!s&&t.mixins.length&&t.mixins.forEach(u),e.extends&&u(e.extends),e.mixins&&e.mixins.forEach(u)}return!r&&!p?(Ye(e)&&i.set(e,null),null):(Ne(r)?r.forEach(u=>d[u]=null):pt(d,r),Ye(e)&&i.set(e,d),d)}function Ti(e,t){return!e||!Rs(t)?!1:(t=t.slice(2),t=t==="Once"?t:t.replace(/Once$/,""),je(e,t[0].toLowerCase()+t.slice(1))||je(e,on(t))||je(e,t))}function Fr(e){let{type:t,vnode:s,proxy:i,withProxy:o,propsOptions:[r],slots:d,attrs:p,emit:u,render:y,renderCache:h,props:b,data:m,setupState:w,ctx:N,inheritAttrs:S}=e,R=ki(e),v,E;try{if(s.shapeFlag&4){let _=o||i,z=_;v=fn(y.call(z,_,h,b,w,m,N)),E=p}else{let _=t;v=fn(_.length>1?_(b,{attrs:p,slots:d,emit:u}):_(b,null)),E=t.props?p:mm(p)}}catch(_){ss.length=0,Po(_,e,1),v=Ie(tn)}let D=v,V;if(E&&S!==!1){let _=Object.keys(E),{shapeFlag:z}=D;_.length&&z&7&&(r&&_.some(Ps)&&(E=hm(E,r)),D=qs(D,E,!1,!0))}if(s.dirs&&(D=qs(D,null,!1,!0),D.dirs=D.dirs?D.dirs.concat(s.dirs):s.dirs),s.transition){let _=Pi(D.type)&&od(D)||D;Co(_,s.transition)}return v=D,ki(R),v}function gd(e,t=!0){let s;for(let i=0;i{let t;for(let s in e)(s==="class"||s==="style"||Rs(s))&&((t||(t={}))[s]=e[s]);return t},hm=(e,t)=>{let s={};for(let i in e)(!Ps(i)||!(i.slice(9)in t))&&(s[i]=e[i]);return s};function gm(e,t,s){let{props:i,children:o,component:r}=e,{props:d,children:p,patchFlag:u}=t,y=r.emitsOptions;if(t.dirs||t.transition)return!0;if(s&&u>=0){if(u&1024)return!0;if(u&16)return i?zl(i,d,y):!!d;if(u&8){let h=t.dynamicProps;for(let b=0;bObject.create(yd),wd=e=>Object.getPrototypeOf(e)===yd;function ym(e,t,s,i=!1){let o={},r=bd();e.propsDefaults=Object.create(null),kd(e,t,o,r);for(let d in e.propsOptions[0])d in o||(o[d]=void 0);s?e.props=i?o:fo(o):e.type.props?e.props=o:e.props=r,e.attrs=r}function bm(e,t,s,i){let{props:o,attrs:r,vnode:{patchFlag:d}}=e,p=We(o),[u]=e.propsOptions,y=!1;if((i||d>0)&&!(d&16)){if(d&8){let h=e.vnode.dynamicProps;for(let b=0;b{u=!0;let[m,w]=Cd(b,t,!0);pt(d,m),w&&p.push(...w)};!s&&t.mixins.length&&t.mixins.forEach(h),e.extends&&h(e.extends),e.mixins&&e.mixins.forEach(h)}if(!r&&!u)return Ye(e)&&i.set(e,In),In;if(Ne(r))for(let h=0;he==="_"||e==="_ctx"||e==="$stable",Qr=e=>Ne(e)?e.map(fn):[fn(e)],km=(e,t,s)=>{if(t._n)return t;let i=zf((...o)=>Qr(t(...o)),s);return i._c=!1,i},Ed=(e,t,s)=>{let i=e._ctx;for(let o in e){if(Jr(o))continue;let r=e[o];if(Oe(r))t[o]=km(o,r,i);else if(r!=null){let d=Qr(r);t[o]=()=>d}}},Sd=(e,t)=>{let s=Qr(t);e.slots.default=()=>s},Nd=(e,t,s)=>{for(let i in t)(s||!Jr(i))&&(e[i]=t[i])},Cm=(e,t,s)=>{let i=e.slots=bd();if(e.vnode.shapeFlag&32){let o=t._;o?(Nd(i,t,s),s&&ri(i,"_",o,!0)):Ed(t,i)}else t&&Sd(e,t)},Em=(e,t,s)=>{let{vnode:i,slots:o}=e,r=!0,d=Ze;if(i.shapeFlag&32){let p=t._;p?s&&p===1?r=!1:Nd(o,t,s):(r=!t.$stable,Ed(t,o)),d=t}else t&&(Sd(e,t),d={default:1});if(r)for(let p in o)!Jr(p)&&d[p]==null&&delete o[p]};function Sm(){let e=[]}var It=Dm;function Rd(e){return Nm(e)}function Nm(e,t){Sm();let s=so();s.__VUE__=!0;let{insert:i,remove:o,patchProp:r,createElement:d,createText:p,createComment:u,setText:y,setElementText:h,parentNode:b,nextSibling:m,setScopeId:w=Tt,insertStaticContent:N}=e,S=(A,O,F,J=null,j=null,ee=null,le=void 0,ne=null,oe=!!O.dynamicChildren)=>{if(A===O)return;A&&!ho(A,O)&&(J=fe(A),He(A,j,ee,!0),A=null),O.patchFlag===-2&&(oe=!1,O.dynamicChildren=null),O.dynamicChildren&&A&&A.dynamicChildren&&A.dynamicChildren.hasOnce&&(O.dynamicChildren===In&&(O.dynamicChildren=[]),O.dynamicChildren.hasOnce=!0);let{type:te,ref:ke,shapeFlag:pe}=O;switch(te){case Oi:R(A,O,F,J);break;case tn:v(A,O,F,J);break;case wo:A==null&&E(O,F,J,le);break;case q:H(A,O,F,J,j,ee,le,ne,oe);break;default:pe&1?z(A,O,F,J,j,ee,le,ne,oe):pe&6?K(A,O,F,J,j,ee,le,ne,oe):(pe&64||pe&128)&&te.process(A,O,F,J,j,ee,le,ne,oe,ce)}ke!=null&&j?vo(ke,A&&A.ref,ee,O||A,!O):ke==null&&A&&A.ref!=null&&vo(A.ref,null,ee,A,!0)},R=(A,O,F,J)=>{if(A==null)i(O.el=p(O.children),F,J);else{let j=O.el=A.el;O.children!==A.children&&y(j,O.children)}},v=(A,O,F,J)=>{A==null?i(O.el=u(O.children||""),F,J):O.el=A.el},E=(A,O,F,J)=>{[A.el,A.anchor]=N(A.children,O,F,J,A.el,A.anchor)},D=(A,O,F,J)=>{if(O.children!==A.children){let j=m(A.anchor);_(A),[O.el,O.anchor]=N(O.children,F,j,J)}else O.el=A.el,O.anchor=A.anchor},V=({el:A,anchor:O},F,J)=>{let j;for(;A&&A!==O;)j=m(A),i(A,F,J),A=j;i(O,F,J)},_=({el:A,anchor:O})=>{let F;for(;A&&A!==O;)F=m(A),o(A),A=F;o(O)},z=(A,O,F,J,j,ee,le,ne,oe)=>{if(O.type==="svg"?le="svg":O.type==="math"&&(le="mathml"),A==null)x(O,F,J,j,ee,le,ne,oe);else{let te=A.el&&A.el._isVueCE?A.el:null;try{te&&te._beginPatch(),U(A,O,j,ee,le,ne,oe)}finally{te&&te._endPatch()}}},x=(A,O,F,J,j,ee,le,ne)=>{let oe,te,{props:ke,shapeFlag:pe,transition:Ee,dirs:Pe}=A;if(oe=A.el=d(A.type,ee,ke&&ke.is,ke),pe&8?h(oe,A.children):pe&16&&I(A.children,oe,null,J,j,Ur(A,ee),le,ne),Pe&&ts(A,null,J,"created"),X(oe,A,A.scopeId,le,J),ke){for(let Ge in ke)Ge!=="value"&&!Ds(Ge)&&r(oe,Ge,null,ke[Ge],ee,J);"value"in ke&&r(oe,"value",null,ke.value,ee),(te=ke.onVnodeBeforeMount)&&cn(te,J,A)}Pe&&ts(A,null,J,"beforeMount");let Ve=Rm(j,Ee);Ve&&Ee.beforeEnter(oe),i(oe,O,F),((te=ke&&ke.onVnodeMounted)||Ve||Pe)&&It(()=>{let ze;te&&cn(te,J,A),Ve&&Ee.enter(oe),Pe&&ts(A,null,J,"mounted")},j)},X=(A,O,F,J,j)=>{if(F&&w(A,F),J)for(let ee=0;ee{for(let te=oe;te{let ne=O.el=A.el,{patchFlag:oe,dynamicChildren:te,dirs:ke}=O;oe|=A.patchFlag&16;let pe=A.props||Ze,Ee=O.props||Ze,Pe;if(F&&ns(F,!1),(Pe=Ee.onVnodeBeforeUpdate)&&cn(Pe,F,O,A),ke&&ts(O,A,F,"beforeUpdate"),F&&ns(F,!0),te&&(!A.dynamicChildren||A.dynamicChildren.length!==te.length)&&(oe=0,le=!1,te=null),(pe.innerHTML&&Ee.innerHTML==null||pe.textContent&&Ee.textContent==null)&&h(ne,""),te?C(A.dynamicChildren,te,ne,F,J,Ur(O,j),ee):le||Se(A,O,ne,null,F,J,Ur(O,j),ee,!1),oe>0){if(oe&16)L(ne,pe,Ee,F,j);else if(oe&2&&pe.class!==Ee.class&&r(ne,"class",null,Ee.class,j),oe&4&&r(ne,"style",pe.style,Ee.style,j),oe&8){let Ve=O.dynamicProps;for(let Ge=0;Ge{Pe&&cn(Pe,F,O,A),ke&&ts(O,A,F,"updated")},J)},C=(A,O,F,J,j,ee,le)=>{for(let ne=0;ne{if(O!==F){if(O!==Ze)for(let ee in O)!Ds(ee)&&!(ee in F)&&r(A,ee,O[ee],null,j,J);for(let ee in F){if(Ds(ee))continue;let le=F[ee],ne=O[ee];le!==ne&&ee!=="value"&&r(A,ee,ne,le,j,J)}"value"in F&&r(A,"value",O.value,F.value,j)}},H=(A,O,F,J,j,ee,le,ne,oe)=>{let te=O.el=A?A.el:p(""),ke=O.anchor=A?A.anchor:p(""),{patchFlag:pe,dynamicChildren:Ee,slotScopeIds:Pe}=O;Pe&&(ne=ne?ne.concat(Pe):Pe),A==null?(i(te,F,J),i(ke,F,J),I(O.children||[],F,ke,j,ee,le,ne,oe)):pe>0&&pe&64&&Ee&&A.dynamicChildren&&A.dynamicChildren.length===Ee.length?(C(A.dynamicChildren,Ee,F,j,ee,le,ne),(O.key!=null||j&&O===j.subTree)&&Pd(A,O,!0)):Se(A,O,F,ke,j,ee,le,ne,oe)},K=(A,O,F,J,j,ee,le,ne,oe)=>{O.slotScopeIds=ne,A==null?O.shapeFlag&512?j.ctx.activate(O,F,J,le,oe):ie(O,F,J,j,ee,le,oe):se(A,O,oe)},ie=(A,O,F,J,j,ee,le)=>{let ne=A.component=Vm(A,J,j);if(Di(A)&&(ne.ctx.renderer=ce),qm(ne,!1,le),ne.asyncDep){if(j&&j.registerDep(ne,Y,le,ee),!A.el){let oe=ne.subTree=Ie(tn);v(null,oe,O,F),A.placeholder=oe.el}}else Y(ne,A,O,F,j,ee,le)},se=(A,O,F)=>{let J=O.component=A.component;if(gm(A,O,F))if(J.asyncDep&&!J.asyncResolved){O.el=A.el,O.placeholder=A.placeholder,me(J,O,F);return}else J.next=O,J.update();else O.el=A.el,O.placeholder=A.placeholder,J.vnode=O},Y=(A,O,F,J,j,ee,le)=>{let ne=()=>{if(A.isMounted){let{next:pe,bu:Ee,u:Pe,parent:Ve,vnode:Ge}=A;{let at=Dd(A);if(at){pe&&(pe.el=Ge.el,me(A,pe,le)),at.asyncDep.then(()=>{It(()=>{A.isUnmounted||te()},j)});return}}let ze=pe,we;ns(A,!1),pe?(pe.el=Ge.el,me(A,pe,le)):pe=Ge,Ee&&As(Ee),(we=pe.props&&pe.props.onVnodeBeforeUpdate)&&cn(we,Ve,pe,Ge),ns(A,!0);let be=Fr(A),ot=A.subTree;A.subTree=be,S(ot,be,b(ot.el),fe(ot),A,j,ee),pe.el=be.el,ze===null&&vm(A,be.el),Pe&&It(Pe,j),(we=pe.props&&pe.props.onVnodeUpdated)&&It(()=>cn(we,Ve,pe,Ge),j)}else{let pe,{el:Ee,props:Pe}=O,{bm:Ve,m:Ge,parent:ze,root:we,type:be}=A,ot=yo(O);if(ns(A,!1),Ve&&As(Ve),!ot&&(pe=Pe&&Pe.onVnodeBeforeMount)&&cn(pe,ze,O),ns(A,!0),Ee&&Me){let at=()=>{A.subTree=Fr(A),Me(Ee,A.subTree,A,j,null)};ot&&be.__asyncHydrate?be.__asyncHydrate(Ee,A,at):at()}else{we.ce&&we.ce._hasShadowRoot()&&we.ce._injectChildStyle(be,A.parent?A.parent.type:void 0);let at=A.subTree=Fr(A);S(null,at,F,J,A,j,ee),O.el=at.el}if(Ge&&It(Ge,j),!ot&&(pe=Pe&&Pe.onVnodeMounted)){let at=O;It(()=>cn(pe,ze,at),j)}(O.shapeFlag&256||ze&&yo(ze.vnode)&&ze.vnode.shapeFlag&256)&&A.a&&It(A.a,j),A.isMounted=!0,O=F=J=null}};A.scope.on();let oe=A.effect=new Is(ne);A.scope.off();let te=A.update=oe.run.bind(oe),ke=A.job=oe.runIfDirty.bind(oe);ke.i=A,ke.id=A.uid,oe.scheduler=()=>Kr(ke),ns(A,!0),te()},me=(A,O,F)=>{O.component=A;let J=A.vnode.props;A.vnode=O,A.next=null,bm(A,O.props,J,F),Em(A,O.children,F),Zt(),Zl(A),xt()},Se=(A,O,F,J,j,ee,le,ne,oe=!1)=>{let te=A&&A.children,ke=A?A.shapeFlag:0,pe=O.children,{patchFlag:Ee,shapeFlag:Pe}=O;if(Ee>0){if(Ee&128){Be(te,pe,F,J,j,ee,le,ne,oe);return}else if(Ee&256){Ue(te,pe,F,J,j,ee,le,ne,oe);return}}Pe&8?(ke&16&&W(te,j,ee),pe!==te&&h(F,pe)):ke&16?Pe&16?Be(te,pe,F,J,j,ee,le,ne,oe):W(te,j,ee,!0):(ke&8&&h(F,""),Pe&16&&I(pe,F,J,j,ee,le,ne,oe))},Ue=(A,O,F,J,j,ee,le,ne,oe)=>{A=A||In,O=O||In;let te=A.length,ke=O.length,pe=Math.min(te,ke),Ee;for(Ee=0;Eeke?W(A,j,ee,!0,!1,pe):I(O,F,J,j,ee,le,ne,oe,pe)},Be=(A,O,F,J,j,ee,le,ne,oe)=>{let te=0,ke=O.length,pe=A.length-1,Ee=ke-1;for(;te<=pe&&te<=Ee;){let Pe=A[te],Ve=O[te]=oe?Cn(O[te]):fn(O[te]);if(ho(Pe,Ve))S(Pe,Ve,F,null,j,ee,le,ne,oe);else break;te++}for(;te<=pe&&te<=Ee;){let Pe=A[pe],Ve=O[Ee]=oe?Cn(O[Ee]):fn(O[Ee]);if(ho(Pe,Ve))S(Pe,Ve,F,null,j,ee,le,ne,oe);else break;pe--,Ee--}if(te>pe){if(te<=Ee){let Pe=Ee+1,Ve=PeEe)for(;te<=pe;)He(A[te],j,ee,!0),te++;else{let Pe=te,Ve=te,Ge=new Map;for(te=Ve;te<=Ee;te++){let dt=O[te]=oe?Cn(O[te]):fn(O[te]);dt.key!=null&&Ge.set(dt.key,te)}let ze,we=0,be=Ee-Ve+1,ot=!1,at=0,yt=new Array(be);for(te=0;te=be){He(dt,j,ee,!0);continue}let ft;if(dt.key!=null)ft=Ge.get(dt.key);else for(ze=Ve;ze<=Ee;ze++)if(yt[ze-Ve]===0&&ho(dt,O[ze])){ft=ze;break}ft===void 0?He(dt,j,ee,!0):(yt[ft-Ve]=te+1,ft>=at?at=ft:ot=!0,S(dt,O[ft],F,null,j,ee,le,ne,oe),we++)}let lt=ot?Pm(yt):In;for(ze=lt.length-1,te=be-1;te>=0;te--){let dt=Ve+te,ft=O[dt],Vt=O[dt+1],Yn=dt+1{let{el:ee,type:le,transition:ne,children:oe,shapeFlag:te}=A;if(te&6){Qe(A.component.subTree,O,F,J);return}if(te&128){A.suspense.move(O,F,J);return}if(te&64){le.move(A,O,F,ce);return}if(le===q){i(ee,O,F);for(let pe=0;pene.enter(ee),j));else{let{leave:pe,delayLeave:Ee,afterLeave:Pe}=ne,Ve=()=>{A.ctx.isUnmounted?o(ee):i(ee,O,F)},Ge=()=>{let ze=ee._isLeaving||!!ee[Lr];ee._isLeaving&&ee[Lr](!0),ne.persisted&&!ze?Ve():pe(ee,()=>{Ve(),Pe&&Pe()})};Ee?Ee(ee,Ve,Ge):Ge()}else i(ee,O,F)},He=(A,O,F,J=!1,j=!1)=>{let{type:ee,props:le,ref:ne,children:oe,dynamicChildren:te,shapeFlag:ke,patchFlag:pe,dirs:Ee,cacheIndex:Pe,memo:Ve}=A;if((pe===-2||te&&te.hasOnce)&&(j=!1),ne!=null&&(Zt(),vo(ne,null,F,A,!0),xt()),Pe!=null&&(!A.ctx||A.ctx===O)&&(O.renderCache[Pe]=void 0),ke&256){O.ctx.deactivate(A);return}let Ge=ke&1&&Ee,ze=!yo(A),we;if(ze&&(we=le&&le.onVnodeBeforeUnmount)&&cn(we,O,A),ke&6)Fe(A.component,F,J);else{if(ke&128){A.suspense.unmount(F,J);return}Ge&&ts(A,null,O,"beforeUnmount"),ke&64?A.type.remove(A,O,F,ce,J):te&&!te.hasOnce&&(ee!==q||pe>0&&pe&64)?W(te,O,F,!1,!0):(ee===q&&pe&384||!j&&ke&16)&&W(oe,O,F),J&&et(A)}let be=Ve!=null&&Pe==null;(ze&&(we=le&&le.onVnodeUnmounted)||Ge||be)&&It(()=>{we&&cn(we,O,A),Ge&&ts(A,null,O,"unmounted"),be&&(A.el=null)},F)},et=A=>{let{type:O,el:F,anchor:J,transition:j}=A,ee=O===q;if(ee&&!j){Re(F,J);return}if(O===wo){_(A),j&&!j.persisted&&j.afterLeave&&j.afterLeave();return}let le=ee?Br(A):A,ne=()=>{ee?b(F)&&Re(F,J):o(F),j&&!j.persisted&&j.afterLeave&&j.afterLeave()};if(le&&le.shapeFlag&1&&j&&!j.persisted){let{leave:oe,delayLeave:te}=j,ke=le.el,pe=()=>oe(ke,ne);te?te(ke,ne,pe):pe()}else ne()},Re=(A,O)=>{let F;for(;A!==O;)F=m(A),o(A),A=F;o(O)},Fe=(A,O,F)=>{let{bum:J,scope:j,job:ee,subTree:le,um:ne,m:oe,a:te}=A;jl(oe),jl(te),J&&As(J),j.stop(),ee?(ee.flags|=8,He(le,A,O,F)):A.vnode.el&&le&&(le.transition=A.vnode.transition,He(le,A,O,F)),ne&&It(ne,O),It(()=>{A.isUnmounted=!0},O)},W=(A,O,F,J=!1,j=!1,ee=0)=>{for(let le=ee;le{if(A.shapeFlag&6)return fe(A.component.subTree);if(A.shapeFlag&128)return A.suspense.next();let O=m(A.anchor||A.el),F=O&&O[Wf];return F?m(F):O},de=(A,O,F)=>{let J=A&&O._vnode?void 0:A&&A.component?A.component.uid:Mm();Bf(()=>{A==null?O._vnode&&He(O._vnode,null,null,!0):S(O._vnode||null,A,O,null,null,null,F),O._vnode=A},J)},ce={p:S,um:He,m:Qe,r:et,mt:ie,mc:I,pc:Se,pbc:C,n:fe,o:e},ve,Me;return t&&([ve,Me]=t(ce)),{render:de,hydrate:ve,createApp:um(de,ve)}}function Ur({type:e,props:t},s){return s==="svg"&&e==="foreignObject"||s==="mathml"&&e==="annotation-xml"&&t&&t.encoding&&t.encoding.includes("html")?void 0:s}function ns({effect:e,job:t},s){s?(e.flags|=32,t.flags|=4):(e.flags&=-33,t.flags&=-5)}function Rm(e,t){return(!e||e&&!e.pendingBranch)&&t&&!t.persisted}function Pd(e,t,s=!1){let i=e.children,o=t.children;if(Ne(i)&&Ne(o))for(let r=0;r>1,e[s[p]]0&&(t[i]=s[r-1]),s[r]=i)}}for(r=s.length,d=s[r-1];r-- >0;)s[r]=d,d=t[d];return s}function Dd(e){let t=e.subTree.component;if(t)return t.asyncDep&&!t.asyncResolved?t:Dd(t)}function jl(e){if(e)for(let t=0;te.__isSuspense;function Dm(e,t){t&&t.pendingBranch?Ne(e)?t.effects.push(...e):t.effects.push(e):Ql(e)}var q=Symbol.for("v-fgt"),Oi=Symbol.for("v-txt"),tn=Symbol.for("v-cmt"),wo=Symbol.for("v-stc"),ss=[],Ft=null;function a(e=!1){ss.push(Ft=e?null:[])}function Td(){ss.pop(),Ft=ss[ss.length-1]||null}var Eo=1;function Si(e,t=!1){Eo+=e,e<0&&Ft&&t&&(Ft.hasOnce=!0)}function Od(e){return e.dynamicChildren=Eo>0?Ft||In:null,Td(),Eo>0&&Ft&&Ft.push(e),e}function l(e,t,s,i,o,r){return Od(n(e,t,s,i,o,r,!0))}function Gt(e,t,s,i,o){return Od(Ie(e,t,s,i,o,!0))}function So(e){return e?e.__v_isVNode===!0:!1}function ho(e,t){return e.type===t.type&&e.key===t.key}var Id=({key:e})=>e??null,bi=({ref:e,ref_key:t,ref_for:s})=>(typeof e=="number"&&(e=""+e),e!=null?it(e)||wt(e)||Oe(e)?{i:$t,r:e,k:t,f:!!s}:e:null);function n(e,t=null,s=null,i=0,o=null,r=e===q?0:1,d=!1,p=!1){let u={__v_isVNode:!0,__v_skip:!0,type:e,props:t,key:t&&Id(t),ref:t&&bi(t),scopeId:td,slotScopeIds:null,children:s,component:null,suspense:null,ssContent:null,ssFallback:null,dirs:null,transition:null,el:null,anchor:null,target:null,targetStart:null,targetAnchor:null,staticCount:0,shapeFlag:r,patchFlag:i,dynamicProps:o,dynamicChildren:null,appContext:null,ctx:$t};return p?(Ni(u,s),r&128&&e.normalize(u)):s&&(u.shapeFlag|=it(s)?8:16),Eo>0&&!d&&Ft&&(u.patchFlag>0||r&6)&&u.patchFlag!==32&&Ft.push(u),u}var Ie=Am;function Am(e,t=null,s=null,i=0,o=null,r=!1){if((!e||e===nm)&&(e=tn),So(e)){let p=qs(e,t,!0);return s&&Ni(p,s),Eo>0&&!r&&Ft&&(p.shapeFlag&6?Ft[Ft.indexOf(e)]=p:Ft.push(p)),p.patchFlag=-2,p}if(Um(e)&&(e=e.__vccOpts),t){t=Tm(t);let{class:p,style:u}=t;p&&!it(p)&&(t.class=P(p)),Ye(u)&&(mo(u)&&!Ne(u)&&(u=pt({},u)),t.style=Te(u))}let d=it(e)?1:Ad(e)?128:Pi(e)?64:Ye(e)?4:Oe(e)?2:0;return n(e,t,s,i,o,d,r,!0)}function Tm(e){return e?mo(e)||wd(e)?pt({},e):e:null}function qs(e,t,s=!1,i=!1){let{props:o,ref:r,patchFlag:d,children:p,transition:u}=e,y=t?Om(o||{},t):o,h={__v_isVNode:!0,__v_skip:!0,type:e.type,props:y,key:y&&Id(y),ref:t&&t.ref?s&&r?Ne(r)?r.concat(bi(t)):[r,bi(t)]:bi(t):r,scopeId:e.scopeId,slotScopeIds:e.slotScopeIds,children:p,target:e.target,targetStart:e.targetStart,targetAnchor:e.targetAnchor,staticCount:e.staticCount,shapeFlag:e.shapeFlag,patchFlag:t&&e.type!==q?d===-1?16:d|16:d,dynamicProps:e.dynamicProps,dynamicChildren:e.dynamicChildren,appContext:e.appContext,dirs:e.dirs,transition:u,component:e.component,suspense:e.suspense,ssContent:e.ssContent&&qs(e.ssContent),ssFallback:e.ssFallback&&qs(e.ssFallback),placeholder:e.placeholder,el:e.el,anchor:e.anchor,ctx:e.ctx,ce:e.ce,cacheIndex:e.cacheIndex};return u&&i&&Co(h,u.clone(h)),h}function g(e=" ",t=0){return Ie(Oi,null,e,t)}function Ce(e,t){let s=Ie(wo,null,e);return s.staticCount=t,s}function f(e="",t=!1){return t?(a(),Gt(tn,null,e)):Ie(tn,null,e)}function fn(e){return e==null||typeof e=="boolean"?Ie(tn):Ne(e)?Ie(q,null,e.slice()):So(e)?Cn(e):Ie(Oi,null,String(e))}function Cn(e){return e.el===null&&e.patchFlag!==-1||e.memo?e:qs(e)}function Ni(e,t){let s=0,{shapeFlag:i}=e;if(t==null)t=null;else if(Ne(t))s=16;else if(typeof t=="object")if(i&65){let o=t.default;o&&(o._c&&(o._d=!1),Ni(e,o()),o._c&&(o._d=!0));return}else{s=32;let o=t._;!o&&!wd(t)?t._ctx=$t:o===3&&$t&&($t.slots._===1?t._=1:(t._=2,e.patchFlag|=1024))}else if(Oe(t)){if(i&65){Ni(e,{default:t});return}t={default:t,_ctx:$t},s=32}else t=String(t),i&64?(s=16,t=[g(t)]):s=8;e.children=t,e.shapeFlag|=s}function Om(...e){let t={};for(let s=0;sNt||$t,Ri,No;{let e=so(),t=(s,i)=>{let o;return(o=e[s])||(o=e[s]=[]),o.push(i),r=>{o.length>1?o.forEach(d=>d(r)):o[0](r)}};Ri=t("__VUE_INSTANCE_SETTERS__",s=>Nt=s),No=t("__VUE_SSR_SETTERS__",s=>_s=s)}var To=e=>{let t=Nt;return Ri(e),e.scope.on(),()=>{e.scope.off(),Ri(t)}},Gl=()=>{Nt&&Nt.scope.off(),Ri(null)};function Vd(e){return e.vnode.shapeFlag&4}var _s=!1;function qm(e,t=!1,s=!1){t&&No(t);let{props:i,children:o}=e.vnode,r=Vd(e);ym(e,i,r,t),Cm(e,o,s||t);let d=r?_m(e,t):void 0;return t&&No(!1),d}function _m(e,t){let s=e.type;e.accessCache=Object.create(null),e.proxy=new Proxy(e.ctx,sm);let{setup:i}=s;if(i){Zt();let o=e.setupContext=i.length>1?$m(e):null,r=To(e),d=Ro(i,e,0,[e.props,o]),p=yr(d);if(xt(),r(),(p||e.sp)&&!yo(e)&&Yr(e),p){if(d.then(Gl,Gl),t)return d.then(u=>{No(!0);try{Wl(e,u,t)}finally{No(!1)}}).catch(u=>{Po(u,e,0)});e.asyncDep=d}else Wl(e,d,t)}else qd(e,t)}function Wl(e,t,s){Oe(t)?e.type.__ssrInlineRender?e.ssrRender=t:e.render=t:Ye(t)&&(e.setupState=vi(t)),qd(e,s)}var Kl,Yl;function qd(e,t,s){let i=e.type;if(!e.render){if(!t&&Kl&&!i.render){let o=i.template||Xr(e).template;if(o){let{isCustomElement:r,compilerOptions:d}=e.appContext.config,{delimiters:p,compilerOptions:u}=i,y=pt(pt({isCustomElement:r,delimiters:p},d),u);i.render=Kl(o,y)}}e.render=i.render||Tt,Yl&&Yl(e)}{let o=To(e);Zt();try{om(e)}finally{xt(),o()}}}var Lm={get(e,t){return Et(e,"get",""),e[t]}};function $m(e){let t=s=>{e.exposed=s||{}};return{attrs:new Proxy(e.attrs,Lm),slots:e.slots,emit:e.emit,expose:t}}function Ii(e){return e.exposed?e.exposeProxy||(e.exposeProxy=new Proxy(vi(un(e.exposed)),{get(t,s){if(s in t)return t[s];if(s in bo)return bo[s](e)},has(t,s){return s in t||s in bo}})):e.proxy}function Fm(e,t=!0){return Oe(e)?e.displayName||e.name:e.name||t&&e.__name}function Um(e){return Oe(e)&&"__vccOpts"in e}var Rt=(e,t)=>Ol(e,t,_s);function Ae(e,t,s){try{Si(-1);let i=arguments.length;return i===2?Ye(t)&&!Ne(t)?So(t)?Ie(e,null,[t]):Ie(e,t):Ie(e,null,t):(i>3?s=Array.prototype.slice.call(arguments,2):i===3&&So(s)&&(s=[s]),Ie(e,t,s))}finally{Si(1)}}var Bm="3.5.44";var na,_d=typeof window<"u"&&window.trustedTypes;if(_d)try{na=_d.createPolicy("vue",{createHTML:e=>e})}catch{}var Yd=na?e=>na.createHTML(e):e=>e,zm="http://www.w3.org/2000/svg",Hm="http://www.w3.org/1998/Math/MathML",Sn=typeof document<"u"?document:null,Ld=Sn&&Sn.createElement("template"),jm={insert:(e,t,s)=>{t.insertBefore(e,s||null)},remove:e=>{let t=e.parentNode;t&&t.removeChild(e)},createElement:(e,t,s,i)=>{let o=t==="svg"?Sn.createElementNS(zm,e):t==="mathml"?Sn.createElementNS(Hm,e):s?Sn.createElement(e,{is:s}):Sn.createElement(e);return e==="select"&&i&&i.multiple!=null&&o.setAttribute("multiple",i.multiple),o},createText:e=>Sn.createTextNode(e),createComment:e=>Sn.createComment(e),setText:(e,t)=>{e.nodeValue=t},setElementText:(e,t)=>{e.textContent=t},parentNode:e=>e.parentNode,nextSibling:e=>e.nextSibling,querySelector:e=>Sn.querySelector(e),setScopeId(e,t){e.setAttribute(t,"")},insertStaticContent(e,t,s,i,o,r){let d=s?s.previousSibling:t.lastChild;if(o&&(o===r||o.nextSibling))for(;t.insertBefore(o.cloneNode(!0),s),!(o===r||!(o=o.nextSibling)););else{Ld.innerHTML=Yd(i==="svg"?`${e}`:i==="mathml"?`${e}`:e);let p=Ld.content;if(i==="svg"||i==="mathml"){let u=p.firstChild;for(;u.firstChild;)p.appendChild(u.firstChild);p.removeChild(u)}t.insertBefore(p,s)}return[d?d.nextSibling:t.firstChild,s?s.previousSibling:t.lastChild]}};var Gm=Symbol("_vtc");function Wm(e,t,s){let i=e[Gm];i&&(t=(t?[t,...i]:[...i]).join(" ")),t==null?e.removeAttribute("class"):s?e.setAttribute("class",t):e.className=t}var qi=Symbol("_vod"),Xd=Symbol("_vsh"),Z={name:"show",beforeMount(e,{value:t},{transition:s}){e[qi]=e.style.display==="none"?"":e.style.display,s&&t?s.beforeEnter(e):Oo(e,t)},mounted(e,{value:t},{transition:s}){s&&t&&s.enter(e)},updated(e,{value:t,oldValue:s},{transition:i}){!t!=!s&&(i?t?(i.beforeEnter(e),Oo(e,!0),i.enter(e)):i.leave(e,()=>{Oo(e,!1)}):Oo(e,t))},beforeUnmount(e,{value:t}){Oo(e,t)}};function Oo(e,t){e.style.display=t?e[qi]:"none",e[Xd]=!t}var Km=Symbol("");var Ym=/(?:^|;)\s*display\s*:/;function Xm(e,t,s){let i=e.style,o=it(s),r=!1;if(s&&!o){if(t)if(it(t))for(let d of t.split(";")){let p=d.slice(0,d.indexOf(":")).trim();s[p]==null&&Io(i,p,"")}else for(let d in t)s[d]==null&&Io(i,d,"");for(let d in s){d==="display"&&(r=!0);let p=s[d];p!=null?Qm(e,d,!it(t)&&t?t[d]:void 0,p)||Io(i,d,p):Io(i,d,"")}}else if(o){if(t!==s){let d=i[Km];d&&(s+=";"+d),i.cssText=s,r=Ym.test(s)}}else t&&e.removeAttribute("style");qi in e&&((!o||t!==s)&&(e[qi]=r?i.display:""),e[Xd]&&(i.display="none"))}var Mi=/\s*!important$/;function Io(e,t,s){if(Ne(s))s.forEach(i=>Io(e,t,i));else if(s==null&&(s=""),t.startsWith("--"))Mi.test(s)?e.setProperty(t,s.replace(Mi,""),"important"):e.setProperty(t,s);else{let i=Jm(e,t);Mi.test(s)?e.setProperty(on(i),s.replace(Mi,""),"important"):e[i]=s}}var $d=["Webkit","Moz","ms"],xr={};function Jm(e,t){let s=xr[t];if(s)return s;let i=mt(t);if(i!=="filter"&&i in e)return xr[t]=i;i=Qn(i);for(let o=0;o<$d.length;o++){let r=$d[o]+i;if(r in e)return xr[t]=r}return t}function Qm(e,t,s,i){return e.tagName==="TEXTAREA"&&(t==="width"||t==="height")&&it(i)&&s===i}var Fd="http://www.w3.org/1999/xlink";function Ud(e,t,s,i,o,r=cl(t)){i&&t.startsWith("xlink:")?s==null?e.removeAttributeNS(Fd,t.slice(6,t.length)):e.setAttributeNS(Fd,t,s):s==null||r&&!ai(s)?e.removeAttribute(t):e.setAttribute(t,r?"":_t(s)?String(s):s)}function Bd(e,t,s,i,o){if(t==="innerHTML"||t==="textContent"){s!=null&&(e[t]=t==="innerHTML"?Yd(s):s);return}let r=e.tagName;if(t==="value"&&r!=="PROGRESS"&&!r.includes("-")){let p=r==="OPTION"?e.getAttribute("value")||"":e.value,u=s==null?e.type==="checkbox"?"on":"":String(s);(p!==u||!("_value"in e))&&(e.value=u),s==null&&e.removeAttribute(t),e._value=s;return}let d=!1;if(s===""||s==null){let p=typeof e[t];p==="boolean"?s=ai(s):s==null&&p==="string"?(s="",d=!0):p==="number"&&(s=0,d=!0)}try{e[t]=s}catch{}d&&e.removeAttribute(o||t)}function Vn(e,t,s,i){e.addEventListener(t,s,i)}function Zm(e,t,s,i){e.removeEventListener(t,s,i)}var zd=Symbol("_vei");function xm(e,t,s,i,o=null){let r=e[zd]||(e[zd]={}),d=r[t];if(i&&d)d.value=i;else{let[p,u]=nh(t);if(i){let y=r[t]=ih(i,o);Vn(e,p,y,u)}else d&&(Zm(e,p,d,u),r[t]=void 0)}}var eh=/(Once|Passive|Capture)$/,th=/^on:?(?:Once|Passive|Capture)$/;function nh(e){let t,s;for(;(s=e.match(eh))&&!th.test(e);)t||(t={}),e=e.slice(0,e.length-s[1].length),t[s[1].toLowerCase()]=!0;return[e[2]===":"?e.slice(3):on(e.slice(2)),t]}var ea=0,sh=Promise.resolve(),oh=()=>ea||(sh.then(()=>ea=0),ea=Date.now());function ih(e,t){let s=i=>{if(!i._vts)i._vts=Date.now();else if(i._vts<=s.attached)return;let o=s.value;if(Ne(o)){let r=i.stopImmediatePropagation;i.stopImmediatePropagation=()=>{r.call(i),i._stopped=!0};let d=o.slice(),p=[i];for(let u=0;ue.charCodeAt(0)===111&&e.charCodeAt(1)===110&&e.charCodeAt(2)>96&&e.charCodeAt(2)<123,rh=(e,t,s,i,o,r)=>{let d=o==="svg";t==="class"?Wm(e,i,d):t==="style"?Xm(e,s,i):Rs(t)?Ps(t)||xm(e,t,s,i,r):(t[0]==="."?(t=t.slice(1),!0):t[0]==="^"?(t=t.slice(1),!1):ah(e,t,i,d))?(Bd(e,t,i),!e.tagName.includes("-")&&(t==="value"||t==="checked"||t==="selected")&&Ud(e,t,i,d,r,t!=="value")):e._isVueCE&&(lh(e,t)||e._def.__asyncLoader&&(/[A-Z]/.test(t)||!it(i)))?Bd(e,mt(t),i,r,t):(t==="true-value"?e._trueValue=i:t==="false-value"&&(e._falseValue=i),Ud(e,t,i,d))};function ah(e,t,s,i){if(i)return!!(t==="innerHTML"||t==="textContent"||t in e&&Hd(t)&&Oe(s));if(t==="spellcheck"||t==="draggable"||t==="translate"||t==="autocorrect"||t==="sandbox"&&e.tagName==="IFRAME"||t==="form"||t==="list"&&e.tagName==="INPUT"||t==="type"&&e.tagName==="TEXTAREA")return!1;if(t==="width"||t==="height"){let o=e.tagName;if(o==="IMG"||o==="VIDEO"||o==="CANVAS"||o==="SOURCE")return!1}return Hd(t)&&it(s)?!1:t in e}function lh(e,t){let s=e._def.props;if(!s)return!1;let i=mt(t);return Array.isArray(s)?s.some(o=>mt(o)===i):Object.keys(s).some(o=>mt(o)===i)}var Ls=e=>{let t=e.props["onUpdate:modelValue"]||!1;return Ne(t)?s=>As(t,s):t};function dh(e){e.target.composing=!0}function jd(e){let t=e.target;t.composing&&(t.composing=!1,t.dispatchEvent(new Event("input")))}var hn=Symbol("_assign"),Vi=Symbol("_initialValue");function ta(e,t,s){return t&&(e=e.trim()),s&&(e=Ts(e)),e}var rt={created(e,{modifiers:{lazy:t,trim:s,number:i}},o){e.parentNode&&(e.type==="text"?e[Vi]=e.defaultValue.replace(/[\r\n]/g,""):e.type==="textarea"&&(e[Vi]=e.defaultValue.replace(/\r\n?/g,` +`))),e[hn]=Ls(o);let r=i||o.props&&o.props.type==="number";Vn(e,t?"change":"input",d=>{d.target.composing||e[hn](ta(e.value,s,r))}),(s||r)&&Vn(e,"change",()=>{e.value=ta(e.value,s,r)}),t||(Vn(e,"compositionstart",dh),Vn(e,"compositionend",jd),Vn(e,"change",jd))},mounted(e,{value:t,modifiers:{trim:s,number:i}}){let o=t??"",r=e[Vi];delete e[Vi],r!==void 0&&(e.type==="text"||e.type==="textarea")&&e.value!==r?e[hn](ta(e.value,s,i)):e.value=o},beforeUpdate(e,{value:t,oldValue:s,modifiers:{lazy:i,trim:o,number:r}},d){if(e[hn]=Ls(d),e.composing)return;let p=(r||e.type==="number")&&!/^0\d/.test(e.value)?Ts(e.value):e.value,u=t??"";if(p===u)return;let y=e.getRootNode();(y instanceof Document||y instanceof ShadowRoot)&&y.activeElement===e&&e.type!=="range"&&(i&&t===s||o&&e.value.trim()===u)||(e.value=u)}},sa={deep:!0,created(e,t,s){e[hn]=Ls(s),Vn(e,"change",()=>{let i=e._modelValue,o=Mo(e),r=e.checked,d=e[hn];if(Ne(i)){let p=li(i,o),u=p!==-1;if(r&&!u)d(i.concat(o));else if(!r&&u){let y=[...i];y.splice(p,1),d(y)}}else if(Xt(i)){let p=new Set(i);r?p.add(o):p.delete(o),d(p)}else d(Jd(e,r))})},mounted:Gd,beforeUpdate(e,t,s){e[hn]=Ls(s),Gd(e,t,s)}};function Gd(e,{value:t,oldValue:s},i){e._modelValue=t;let o;if(Ne(t))o=li(t,i.props.value)>-1;else if(Xt(t))o=t.has(i.props.value);else{if(t===s)return;o=Jt(t,Jd(e,!0))}e.checked!==o&&(e.checked=o)}var Wt={deep:!0,created(e,{value:t,modifiers:{number:s}},i){e._modelValue=t,Vn(e,"change",()=>{let o=Array.prototype.filter.call(e.options,u=>u.selected).map(u=>s?Ts(Mo(u)):Mo(u)),r=e.multiple,d=r?Xt(e._modelValue)?new Set(o):o:o[0],p=e._pendingValue=[r,r?Ne(d)?o.slice():o:d];try{e[hn](d)}finally{tt(()=>{e._pendingValue===p&&(e._pendingValue=void 0)})}}),e[hn]=Ls(i)},mounted(e,{value:t}){Wd(e,t)},beforeUpdate(e,{value:t},s){e._modelValue=t,e[hn]=Ls(s)},updated(e,{value:t}){let s=e._pendingValue;e._pendingValue=void 0,(!s||s[0]!==e.multiple||!uh(t,s[1],s[0]))&&Wd(e,t)}};function uh(e,t,s){if(!s)return Jt(e,t);if(Ne(e))return Jt(e,t);if(Xt(e)){if(e.size!==t.length)return!1;for(let i of t)if(!e.has(i))return!1;return!0}return!1}function Wd(e,t){let s=e.multiple,i=Ne(t);if(!(s&&!i&&!Xt(t))){for(let o=0,r=e.options.length;oString(y)===String(p)):d.selected=li(t,p)>-1}else d.selected=t.has(p);else if(Jt(Mo(d),t)){e.selectedIndex!==o&&(e.selectedIndex=o);return}}!s&&e.selectedIndex!==-1&&(e.selectedIndex=-1)}}function Mo(e){return"_value"in e?e._value:e.value}function Jd(e,t){let s=t?"_trueValue":"_falseValue";return s in e?e[s]:t}var ch=["ctrl","shift","alt","meta"],ph={stop:e=>e.stopPropagation(),prevent:e=>e.preventDefault(),self:e=>e.target!==e.currentTarget,ctrl:e=>!e.ctrlKey,shift:e=>!e.shiftKey,alt:e=>!e.altKey,meta:e=>!e.metaKey,left:e=>"button"in e&&e.button!==0,middle:e=>"button"in e&&e.button!==1,right:e=>"button"in e&&e.button!==2,exact:(e,t)=>ch.some(s=>e[`${s}Key`]&&!t.includes(s))},ae=(e,t)=>{if(!e)return e;let s=e._withMods||(e._withMods={}),i=t.join(".");return s[i]||(s[i]=((o,...r)=>{for(let d=0;d{let s=e._withKeys||(e._withKeys={}),i=t.join(".");return s[i]||(s[i]=(o=>{if(!("key"in o))return;let r=on(o.key);if(t.some(d=>d===r||fh[d]===r))return e(o)}))},mh=pt({patchProp:rh},jm),Kd;function hh(){return Kd||(Kd=Rd(mh))}var Qd=((...e)=>{let t=hh().createApp(...e),{mount:s}=t;return t.mount=i=>{let o=vh(i);if(!o)return;let r=t._component;!Oe(r)&&!r.render&&!r.template&&(r.template=o.innerHTML),o.nodeType===1&&(o.textContent="");let d=s(o,!1,gh(o));return o instanceof Element&&(o.removeAttribute("v-cloak"),o.setAttribute("data-v-app","")),d},t});function gh(e){if(e instanceof SVGElement)return"svg";if(typeof MathMLElement=="function"&&e instanceof MathMLElement)return"mathml"}function vh(e){return it(e)?document.querySelector(e):e}var ls=typeof document<"u";function xd(e){return typeof e=="object"||"displayName"in e||"props"in e||"__vccOpts"in e}function yh(e){return e.__esModule||e[Symbol.toStringTag]==="Module"||e.default&&xd(e.default)}var Je=Object.assign;function _i(e,t){let s={};for(let i in t){let o=t[i];s[i]=Kt(o)?o.map(e):e(o)}return s}var Fs=()=>{},Kt=Array.isArray;function ra(e,t){let s={};for(let i in e)s[i]=i in t?t[i]:e[i];return s}var eu=/#/g,bh=/&/g,wh=/\//g,kh=/=/g,Ch=/\?/g,tu=/\+/g,Eh=/%5B/g,Sh=/%5D/g,nu=/%5E/g,Nh=/%60/g,su=/%7B/g,Rh=/%7C/g,ou=/%7D/g,Ph=/%20/g;function aa(e){return e==null?"":encodeURI(""+e).replace(Rh,"|").replace(Eh,"[").replace(Sh,"]")}function iu(e){return aa(e).replace(su,"{").replace(ou,"}").replace(nu,"^")}function oa(e){return aa(e).replace(tu,"%2B").replace(Ph,"+").replace(eu,"%23").replace(bh,"%26").replace(Nh,"`").replace(su,"{").replace(ou,"}").replace(nu,"^")}function Dh(e){return oa(e).replace(kh,"%3D")}function Ah(e){return aa(e).replace(eu,"%23").replace(Ch,"%3F")}function ru(e){return Ah(e).replace(wh,"%2F")}function $s(e){if(e==null)return null;try{return decodeURIComponent(""+e)}catch{}return""+e}var Th=/\/$/,Oh=e=>e.replace(Th,"");function Li(e,t,s="/"){let i,o={},r="",d="",p=t.indexOf("#"),u=t.indexOf("?");return u=p>=0&&u>p?-1:u,u>=0&&(i=t.slice(0,u),r=t.slice(u,p>0?p:t.length),o=e(r.slice(1))),p>=0&&(i=i||t.slice(0,p),d=t.slice(p,t.length)),i=Mh(i??t,s),{fullPath:i+r+d,path:i,query:o,hash:$s(d)}}function au(e,t){let s=t.query?e(t.query):"";return t.path+(s&&"?")+s+(t.hash||"")}function la(e,t){return!t||!e.toLowerCase().startsWith(t.toLowerCase())?e:e.slice(t.length)||"/"}function lu(e,t,s){let i=t.matched.length-1,o=s.matched.length-1;return i>-1&&i===o&&rs(t.matched[i],s.matched[o])&&da(t.params,s.params)&&e(t.query)===e(s.query)&&t.hash===s.hash}function rs(e,t){return(e.aliasOf||e)===(t.aliasOf||t)}function da(e,t){if(Object.keys(e).length!==Object.keys(t).length)return!1;for(var s in e)if(!Ih(e[s],t[s]))return!1;return!0}function Ih(e,t){return Kt(e)?Zd(e,t):Kt(t)?Zd(t,e):e?.valueOf()===t?.valueOf()}function Zd(e,t){return Kt(t)?e.length===t.length&&e.every((s,i)=>s===t[i]):e.length===1&&e[0]===t}function Mh(e,t){if(e.startsWith("/"))return e;if(!e)return t;let s=t.split("/"),i=e.split("/"),o=i[i.length-1];(o===".."||o===".")&&i.push("");let r=s.length-1,d,p;for(d=0;d1&&r--;else break;return s.slice(0,r).join("/")+"/"+i.slice(d).join("/")}var Rn={path:"/",name:void 0,params:{},query:{},hash:"",fullPath:"/",matched:[],meta:{},redirectedFrom:void 0},$i=(function(e){return e.pop="pop",e.push="push",e})({}),Fi=(function(e){return e.back="back",e.forward="forward",e.unknown="",e})({});function du(e){if(!e)if(ls){let t=document.querySelector("base");e=t&&t.getAttribute("href")||"/",e=e.replace(/^\w+:\/\/[^\/]+/,"")}else e="/";return e[0]!=="/"&&e[0]!=="#"&&(e="/"+e),Oh(e)}var Vh=/^[^#]+#/;function uu(e,t){return e.replace(Vh,"#")+t}function qh(e,t){let s=document.documentElement.getBoundingClientRect(),i=e.getBoundingClientRect();return{behavior:t.behavior,left:i.left-s.left-(t.left||0),top:i.top-s.top-(t.top||0)}}var Vo=()=>({left:window.scrollX,top:window.scrollY});function cu(e){let t;if("el"in e){let s=e.el,i=typeof s=="string"&&s.startsWith("#"),o=typeof s=="string"?i?document.getElementById(s.slice(1)):document.querySelector(s):s;if(!o)return;t=qh(o,e)}else t=e;"scrollBehavior"in document.documentElement.style?window.scrollTo(t):window.scrollTo(t.left!=null?t.left:window.scrollX,t.top!=null?t.top:window.scrollY)}function ua(e,t){return(history.state?history.state.position-t:-1)+e}var ia=new Map;function pu(e,t){ia.set(e,t)}function fu(e){let t=ia.get(e);return ia.delete(e),t}function _h(e){return typeof e=="string"||e&&typeof e=="object"}function ca(e){return typeof e=="string"||typeof e=="symbol"}var ct=(function(e){return e[e.MATCHER_NOT_FOUND=1]="MATCHER_NOT_FOUND",e[e.NAVIGATION_GUARD_REDIRECT=2]="NAVIGATION_GUARD_REDIRECT",e[e.NAVIGATION_ABORTED=4]="NAVIGATION_ABORTED",e[e.NAVIGATION_CANCELLED=8]="NAVIGATION_CANCELLED",e[e.NAVIGATION_DUPLICATED=16]="NAVIGATION_DUPLICATED",e})({}),mu=Symbol("");var Cx={[ct.MATCHER_NOT_FOUND]({location:e,currentLocation:t}){return`No match for ${JSON.stringify(e)}${t?` while being at -`+JSON.stringify(t):""}`},[ut.NAVIGATION_GUARD_REDIRECT]({from:e,to:t}){return`Redirected from "${e.fullPath}" to "${$m(t)}" via a navigation guard.`},[ut.NAVIGATION_ABORTED]({from:e,to:t}){return`Navigation aborted from "${e.fullPath}" to "${t.fullPath}" via a navigation guard.`},[ut.NAVIGATION_CANCELLED]({from:e,to:t}){return`Navigation cancelled from "${e.fullPath}" to "${t.fullPath}" with a new navigation.`},[ut.NAVIGATION_DUPLICATED]({from:e,to:t}){return`Avoided redundant navigation to current location: "${e.fullPath}".`}};function as(e,t){return Je(new Error,{type:e,[hu]:!0},t)}function gn(e,t){return e instanceof Error&&hu in e&&(t==null||!!(e.type&t))}var Lm=["params","query","hash"];function $m(e){if(typeof e=="string")return e;if(e.path!=null)return e.path;let t={};for(let s of Lm)s in e&&(t[s]=e[s]);return JSON.stringify(t,null,2)}function mu(e){let t={};if(e===""||e==="?")return t;let s=(e[0]==="?"?e.slice(1):e).split("&");for(let i=0;io&&oa(o)):[i&&oa(i)]).forEach(o=>{o!==void 0&&(t+=(t.length?"&":"")+s,o!=null&&(t+="="+o))})}return t}function gu(e){let t={};for(let s in e){let i=e[s];i!==void 0&&(t[s]=Kt(i)?i.map(o=>o==null?null:""+o):i==null?i:""+i)}return t}var vu=Symbol(""),fa=Symbol(""),Ui=Symbol(""),Bi=Symbol(""),zi=Symbol("");function Us(){let e=[];function t(i){return e.push(i),()=>{let o=e.indexOf(i);o>-1&&e.splice(o,1)}}function s(){e=[]}return{add:t,list:()=>e.slice(),reset:s}}function Nn(e,t,s,i,o,r=d=>d()){let d=i&&(i.enterCallbacks[o]=i.enterCallbacks[o]||[]);return()=>new Promise((p,u)=>{let y=h=>{h===!1?u(as(ut.NAVIGATION_ABORTED,{from:s,to:t})):h instanceof Error?u(h):_m(h)?u(as(ut.NAVIGATION_GUARD_REDIRECT,{from:t,to:h})):(d&&i.enterCallbacks[o]===d&&typeof h=="function"&&d.push(h),p())},m=r(()=>e.call(i&&i.instances[o],t,s,y)),b=Promise.resolve(m);e.length<3&&(b=b.then(y)),b.catch(h=>u(h))})}function Hi(e,t,s,i,o=r=>r()){let r=[];for(let d of e)for(let p in d.components){let u=d.components[p];if(!(t!=="beforeRouteEnter"&&!d.instances[p]))if(xd(u)){let y=(u.__vccOpts||u)[t];y&&r.push(Nn(y,s,i,d,p,o))}else{let y=u();r.push(()=>y.then(m=>{if(!m)throw new Error(`Couldn't resolve component "${p}" at "${d.path}"`);let b=ym(m)?m.default:m;d.mods[p]=m,d.components[p]=b;let h=(b.__vccOpts||b)[t];return h&&Nn(h,s,i,d,p,o)()}))}}return r}function yu(e,t){let s=[],i=[],o=[],r=Math.max(t.matched.length,e.matched.length);for(let d=0;drs(y,p))?i.push(p):s.push(p));let u=e.matched[d];u&&(t.matched.find(y=>rs(y,u))||o.push(u))}return[s,i,o]}var Fm=()=>location.protocol+"//"+location.host;function Du(e,t){let{pathname:s,search:i,hash:o}=t,r=e.indexOf("#");if(r>-1){let d=o.includes(e.slice(r))?e.slice(r).length:1,p=o.slice(d);return p[0]!=="/"&&(p="/"+p),la(p,"")}return la(s,e)+i+o}function Um(e,t,s,i){let o=[],r=[],d=null,p=({state:h})=>{let w=Du(e,location),R=s.value,S=t.value,N=0;if(h){if(s.value=w,t.value=h,d&&d===R){d=null;return}N=S?h.position-S.position:0}else i(w);o.forEach(v=>{v(s.value,R,{delta:N,type:$i.pop,direction:N?N>0?Fi.forward:Fi.back:Fi.unknown})})};function u(){d=s.value}function y(h){o.push(h);let w=()=>{let R=o.indexOf(h);R>-1&&o.splice(R,1)};return r.push(w),w}function m(){if(document.visibilityState==="hidden"){let{history:h}=window;if(!h.state)return;h.replaceState(Je({},h.state,{scroll:Vo()}),"")}}function b(){for(let h of r)h();r=[],window.removeEventListener("popstate",p),window.removeEventListener("pagehide",m),document.removeEventListener("visibilitychange",m)}return window.addEventListener("popstate",p),window.addEventListener("pagehide",m),document.addEventListener("visibilitychange",m),{pauseListeners:u,listen:y,destroy:b}}function bu(e,t,s,i=!1,o=!1){return{back:e,current:t,forward:s,replaced:i,position:window.history.length,scroll:o?Vo():null}}function Bm(e){let{history:t,location:s}=window,i={value:Du(e,s)},o={value:t.state};o.value||r(i.value,{back:null,current:i.value,forward:null,position:t.length-1,replaced:!0,scroll:null},!0);function r(u,y,m){let b=e.indexOf("#"),h=b>-1?(s.host&&document.querySelector("base")?e:e.slice(b))+u:Fm()+e+u;try{t[m?"replaceState":"pushState"](y,"",h),o.value=y}catch(w){console.error(w),s[m?"replace":"assign"](h)}}function d(u,y){r(u,Je({},t.state,bu(o.value.back,u,o.value.forward,!0),y,{position:o.value.position}),!0),i.value=u}function p(u,y){let m=Je({},o.value,t.state,{forward:u,scroll:Vo()});r(m.current,m,!0),r(u,Je({},bu(i.value,u,null),{position:m.position+1},y),!1),i.value=u}return{location:i,state:o,push:p,replace:d}}function Tu(e){e=du(e);let t=Bm(e),s=Um(e,t.state,t.location,t.replace);function i(r,d=!0){d||s.pauseListeners(),history.go(r)}let o=Je({location:"",base:e,go:i,createHref:uu.bind(null,e)},t,s);return Object.defineProperty(o,"location",{enumerable:!0,get:()=>t.location.value}),Object.defineProperty(o,"state",{enumerable:!0,get:()=>t.state.value}),o}var ds=(function(e){return e[e.Static=0]="Static",e[e.Param=1]="Param",e[e.Group=2]="Group",e})({}),gt=(function(e){return e[e.Static=0]="Static",e[e.Param=1]="Param",e[e.ParamRegExp=2]="ParamRegExp",e[e.ParamRegExpEnd=3]="ParamRegExpEnd",e[e.EscapeNext=4]="EscapeNext",e})(gt||{}),zm={type:ds.Static,value:""},Hm=/[a-zA-Z0-9_]/;function jm(e){if(!e)return[[]];if(e==="/")return[[zm]];if(!e.startsWith("/"))throw new Error(`Invalid path "${e}"`);function t(w){throw new Error(`ERR (${s})/"${y}": ${w}`)}let s=gt.Static,i=s,o=[],r;function d(){r&&o.push(r),r=[]}let p=0,u,y="",m="";function b(){y&&(s===gt.Static?r.push({type:ds.Static,value:y}):s===gt.Param||s===gt.ParamRegExp||s===gt.ParamRegExpEnd?(r.length>1&&(u==="*"||u==="+")&&t(`A repeatable param (${y}) must be alone in its segment. eg: '/:ids+.`),r.push({type:ds.Param,value:y,regexp:m,repeatable:u==="*"||u==="+",optional:u==="*"||u==="?"})):t("Invalid state to consume buffer"),y="")}function h(){y+=u}for(;pt.length?t.length===1&&t[0]===Dt.Static+Dt.Segment?1:-1:0}function Ou(e,t){let s=0,i=e.score,o=t.score;for(;s0&&t[t.length-1]<0}var Xm={strict:!1,end:!0,sensitive:!1};function Jm(e,t,s){let i=Km(jm(e.path),s),o=Je(i,{record:e,parent:t,children:[],alias:[]});return t&&!o.record.aliasOf==!t.record.aliasOf&&t.children.push(o),o}function Qm(e,t){let s=[],i=new Map;t=ra(Xm,t);function o(b){return i.get(b)}function r(b,h,w){let R=!w,S=Eu(b);S.aliasOf=w&&w.record;let N=ra(t,b),v=[S];if("alias"in b){let V=typeof b.alias=="string"?[b.alias]:b.alias;for(let _ of V)v.push(Eu(Je({},S,{components:w?w.record.components:S.components,path:_,aliasOf:w?w.record:S})))}let E,M;for(let V of v){let{path:_}=V;if(h&&_[0]!=="/"){let G=h.record.path,te=G[G.length-1]==="/"?"":"/";V.path=h.record.path+(_&&te+_)}if(E=Jm(V,h,N),w?w.alias.push(E):(M=M||E,M!==E&&M.alias.push(E),R&&b.name&&!Su(E)&&d(b.name)),Iu(E)&&u(E),S.children){let G=S.children;for(let te=0;te{d(M)}:Fs}function d(b){if(ca(b)){let h=i.get(b);h&&(i.delete(b),s.splice(s.indexOf(h),1),h.children.forEach(d),h.alias.forEach(d))}else{let h=s.indexOf(b);h>-1&&(s.splice(h,1),b.record.name&&i.delete(b.record.name),b.children.forEach(d),b.alias.forEach(d))}}function p(){return s}function u(b){let h=eg(b,s);s.splice(h,0,b),b.record.name&&!Su(b)&&i.set(b.record.name,b)}function y(b,h){let w,R={},S,N;if("name"in b&&b.name){if(w=i.get(b.name),!w)throw as(ut.MATCHER_NOT_FOUND,{location:b});N=w.record.name,R=Je(Cu(h.params,w.keys.filter(M=>!M.optional).concat(w.parent?w.parent.keys.filter(M=>M.optional):[]).map(M=>M.name)),b.params&&Cu(b.params,w.keys.map(M=>M.name))),S=w.stringify(R)}else if(b.path!=null)S=b.path,w=s.find(M=>M.re.test(S)),w&&(R=w.parse(S),N=w.record.name);else{if(w=h.name?i.get(h.name):s.find(M=>M.re.test(h.path)),!w)throw as(ut.MATCHER_NOT_FOUND,{location:b,currentLocation:h});N=w.record.name,R=Je({},h.params,b.params),S=w.stringify(R)}let v=[],E=w;for(;E;)v.unshift(E.record),E=E.parent;return{name:N,path:S,params:R,matched:v,meta:xm(v)}}e.forEach(b=>r(b));function m(){s.length=0,i.clear()}return{addRoute:r,resolve:y,removeRoute:d,clearRoutes:m,getRoutes:p,getRecordMatcher:o}}function Cu(e,t){let s={};for(let i of t)i in e&&(s[i]=e[i]);return s}function Eu(e){let t={path:e.path,redirect:e.redirect,name:e.name,meta:e.meta||{},aliasOf:e.aliasOf,beforeEnter:e.beforeEnter,props:Zm(e),children:e.children||[],instances:{},leaveGuards:new Set,updateGuards:new Set,enterCallbacks:{},components:"components"in e?e.components||null:e.component&&{default:e.component}};return Object.defineProperty(t,"mods",{value:{}}),t}function Zm(e){let t={},s=e.props||!1;if("component"in e)t.default=s;else for(let i in e.components)t[i]=typeof s=="object"?s[i]:s;return t}function Su(e){for(;e;){if(e.record.aliasOf)return!0;e=e.parent}return!1}function xm(e){return e.reduce((t,s)=>Je(t,s.meta),{})}function eg(e,t){let s=0,i=t.length;for(;s!==i;){let r=s+i>>1;Ou(e,t[r])<0?i=r:s=r+1}let o=tg(e);return o&&(i=t.lastIndexOf(o,i-1)),i}function tg(e){let t=e;for(;t=t.parent;)if(Iu(t)&&Ou(e,t)===0)return t}function Iu({record:e}){return!!(e.name||e.components&&Object.keys(e.components).length||e.redirect)}function Nu(e){let t=Mt(Ui),s=Mt(Bi),i=!1,o=null,r=Rt(()=>{let m=kn(e.to);return t.resolve(m)}),d=Rt(()=>{let{matched:m}=r.value,{length:b}=m,h=m[b-1],w=s.matched;if(!h||!w.length)return-1;let R=w.findIndex(rs.bind(null,h));if(R>-1)return R;let S=Ru(m[b-2]);return b>1&&Ru(h)===S&&w[w.length-1].path!==S?w.findIndex(rs.bind(null,m[b-2])):R}),p=Rt(()=>d.value>-1&&rg(s.params,r.value.params)),u=Rt(()=>d.value>-1&&d.value===s.matched.length-1&&da(s.params,r.value.params));function y(m={}){if(ig(m)){let b=t[kn(e.replace)?"replace":"push"](kn(e.to)).catch(Fs);return e.viewTransition&&typeof document<"u"&&"startViewTransition"in document&&document.startViewTransition(()=>b),b}return Promise.resolve()}return{route:r,href:Rt(()=>r.value.href),isActive:p,isExactActive:u,navigate:y}}function ng(e){return e.length===1?e[0]:e}var sg=Po({name:"RouterLink",compatConfig:{MODE:3},props:{to:{type:[String,Object],required:!0},replace:Boolean,activeClass:String,exactActiveClass:String,custom:Boolean,ariaCurrentValue:{type:String,default:"page"},viewTransition:Boolean},useLink:Nu,setup(e,{slots:t}){let s=st(Nu(e)),{options:i}=Mt(Ui),o=Rt(()=>({[Au(e.activeClass,i.linkActiveClass,"router-link-active")]:s.isActive,[Au(e.exactActiveClass,i.linkExactActiveClass,"router-link-exact-active")]:s.isExactActive}));return()=>{let r=t.default&&ng(t.default(s));return e.custom?r:De("a",{"aria-current":s.isExactActive?e.ariaCurrentValue:null,href:s.href,onClick:s.navigate,class:o.value},r)}}}),og=sg;function ig(e){if(!(e.metaKey||e.altKey||e.ctrlKey||e.shiftKey)&&!e.defaultPrevented&&!(e.button!==void 0&&e.button!==0)){if(e.currentTarget&&e.currentTarget.getAttribute){let t=e.currentTarget.getAttribute("target");if(/\b_blank\b/i.test(t))return}return e.preventDefault&&e.preventDefault(),!0}}function rg(e,t){for(let s in t){let i=t[s],o=e[s];if(typeof i=="string"){if(i!==o)return!1}else if(!Kt(o)||o.length!==i.length||i.some((r,d)=>r.valueOf()!==o[d].valueOf()))return!1}return!0}function Ru(e){return e?e.aliasOf?e.aliasOf.path:e.path:""}var Au=(e,t,s)=>e??t??s,ag=Po({name:"RouterView",inheritAttrs:!1,props:{name:{type:String,default:"default"},route:Object},compatConfig:{MODE:3},setup(e,{attrs:t,slots:s}){let i=Mt(zi),o=Rt(()=>e.route||i.value),r=Mt(fa,0),d=Rt(()=>{let y=kn(r),{matched:m}=o.value,b;for(;(b=m[y])&&!b.components;)y++;return y}),p=Rt(()=>o.value.matched[d.value]);os(fa,Rt(()=>d.value+1)),os(vu,p),os(zi,o);let u=St();return dt(()=>[u.value,p.value,e.name],([y,m,b],[h,w,R])=>{m&&(m.instances[b]=y,w&&w!==m&&y&&y===h&&(m.leaveGuards.size||(m.leaveGuards=w.leaveGuards),m.updateGuards.size||(m.updateGuards=w.updateGuards))),y&&m&&(!w||!rs(m,w)||!h)&&(m.enterCallbacks[b]||[]).forEach(S=>S(y))},{flush:"post"}),()=>{let y=o.value,m=e.name,b=p.value,h=b&&b.components[m];if(!h)return Pu(s.default,{Component:h,route:y});let w=b.props[m],R=w?w===!0?y.params:typeof w=="function"?w(y):w:null,N=De(h,Je({},R,t,{onVnodeUnmounted:v=>{v.component.isUnmounted&&(b.instances[m]=null)},ref:u}));return Pu(s.default,{Component:N,route:y})||N}}});function Pu(e,t){if(!e)return null;let s=e(t);return s.length===1?s[0]:s}var ha=ag;function Mu(e){let t=Qm(e.routes,e),s=e.parseQuery||mu,i=e.stringifyQuery||pa,o=e.history,r=Us(),d=Us(),p=Us(),u=gi(Rn),y=Rn;ls&&e.scrollBehavior&&"scrollRestoration"in history&&(history.scrollRestoration="manual");let m=_i.bind(null,W=>""+W),b=_i.bind(null,ru),h=_i.bind(null,$s);function w(W,fe){let de,ce;return ca(W)?(de=t.getRecordMatcher(W),ce=fe):ce=W,t.addRoute(ce,de)}function R(W){let fe=t.getRecordMatcher(W);fe&&t.removeRoute(fe)}function S(){return t.getRoutes().map(W=>W.record)}function N(W){return!!t.getRecordMatcher(W)}function v(W,fe){if(fe=Je({},fe||u.value),typeof W=="string"){let T=Li(s,W,fe.path),F=t.resolve({path:T.path},fe),J=o.createHref(T.fullPath);return Je(T,F,{params:h(F.params),hash:$s(T.hash),redirectedFrom:void 0,href:J})}let de;if(W.path!=null)de=Je({},W,{path:Li(s,W.path,fe.path).path});else{let T=Je({},W.params);for(let F in T)T[F]==null&&delete T[F];de=Je({},W,{params:b(T)}),fe.params=b(fe.params)}let ce=t.resolve(de,fe),ve=W.hash||"";ce.params=m(h(ce.params));let Me=au(i,Je({},W,{hash:iu(ve),path:ce.path})),P=o.createHref(Me);return Je({fullPath:Me,hash:ve,query:i===pa?gu(W.query):W.query||{}},ce,{redirectedFrom:void 0,href:P})}function E(W){return typeof W=="string"?Li(s,W,u.value.path):Je({},W)}function M(W,fe){if(y!==W)return as(ut.NAVIGATION_CANCELLED,{from:fe,to:W})}function V(W){return te(W)}function _(W){return V(Je(E(W),{replace:!0}))}function G(W,fe){let de=W.matched[W.matched.length-1];if(de&&de.redirect){let{redirect:ce}=de,ve=typeof ce=="function"?ce(W,fe):ce;return typeof ve=="string"&&(ve=ve.includes("?")||ve.includes("#")?ve=E(ve):{path:ve},ve.params={}),Je({query:W.query,hash:W.hash,params:ve.path!=null?{}:W.params},ve)}}function te(W,fe){let de=y=v(W),ce=u.value,ve=W.state,Me=W.force,P=W.replace===!0,T=G(de,ce);if(T)return te(Je(E(T),{state:typeof T=="object"?Je({},ve,T.state):ve,force:Me,replace:P}),fe||de);let F=de;F.redirectedFrom=fe;let J;return!Me&&lu(i,ce,de)&&(J=as(ut.NAVIGATION_DUPLICATED,{to:F,from:ce}),Be(ce,ce,!0,!1)),(J?Promise.resolve(J):U(F,ce)).catch(H=>gn(H)?gn(H,ut.NAVIGATION_GUARD_REDIRECT)?H:Ue(H):he(H,F,ce)).then(H=>{if(H){if(gn(H,ut.NAVIGATION_GUARD_REDIRECT))return te(Je({replace:P},E(H.to),{state:typeof H.to=="object"?Je({},ve,H.to.state):ve,force:Me}),fe||F)}else H=L(F,ce,!0,P,ve);return C(F,ce,H),H})}function X(W,fe){let de=M(W,fe);return de?Promise.reject(de):Promise.resolve()}function O(W){let fe=et.values().next().value;return fe&&typeof fe.runWithContext=="function"?fe.runWithContext(W):W()}function U(W,fe){let de,[ce,ve,Me]=yu(W,fe);de=Hi(ce.reverse(),"beforeRouteLeave",W,fe);for(let T of ce)T.leaveGuards.forEach(F=>{de.push(Nn(F,W,fe))});let P=X.bind(null,W,fe);return de.push(P),Fe(de).then(()=>{de=[];for(let T of r.list())de.push(Nn(T,W,fe));return de.push(P),Fe(de)}).then(()=>{de=Hi(ve,"beforeRouteUpdate",W,fe);for(let T of ve)T.updateGuards.forEach(F=>{de.push(Nn(F,W,fe))});return de.push(P),Fe(de)}).then(()=>{de=[];for(let T of Me)if(T.beforeEnter)if(Kt(T.beforeEnter))for(let F of T.beforeEnter)de.push(Nn(F,W,fe));else de.push(Nn(T.beforeEnter,W,fe));return de.push(P),Fe(de)}).then(()=>(W.matched.forEach(T=>T.enterCallbacks={}),de=Hi(Me,"beforeRouteEnter",W,fe,O),de.push(P),Fe(de))).then(()=>{de=[];for(let T of d.list())de.push(Nn(T,W,fe));return de.push(P),Fe(de)}).catch(T=>gn(T,ut.NAVIGATION_CANCELLED)?T:Promise.reject(T))}function C(W,fe,de){p.list().forEach(ce=>O(()=>ce(W,fe,de)))}function L(W,fe,de,ce,ve){let Me=M(W,fe);if(Me)return Me;let P=fe===Rn,T=ls?history.state:{};de&&(ce||P?o.replace(W.fullPath,Je({scroll:P&&T&&T.scroll},ve)):o.push(W.fullPath,ve)),u.value=W,Be(W,fe,de,P),Ue()}let z;function K(){z||(z=o.listen((W,fe,de)=>{if(!Re.listening)return;let ce=v(W),ve=G(ce,Re.currentRoute.value);if(ve){te(Je(ve,{replace:!0,force:!0}),ce).catch(Fs);return}y=ce;let Me=u.value;ls&&pu(ua(Me.fullPath,de.delta),Vo()),U(ce,Me).catch(P=>gn(P,ut.NAVIGATION_ABORTED|ut.NAVIGATION_CANCELLED)?P:gn(P,ut.NAVIGATION_GUARD_REDIRECT)?(te(Je(E(P.to),{force:!0}),ce).then(T=>{gn(T,ut.NAVIGATION_ABORTED|ut.NAVIGATION_DUPLICATED)&&!de.delta&&de.type===$i.pop&&o.go(-1,!1)}).catch(Fs),Promise.reject()):(de.delta&&o.go(-de.delta,!1),he(P,ce,Me))).then(P=>{P=P||L(ce,Me,!1),P&&(de.delta&&!gn(P,ut.NAVIGATION_CANCELLED)?o.go(-de.delta,!1):de.type===$i.pop&&gn(P,ut.NAVIGATION_ABORTED|ut.NAVIGATION_DUPLICATED)&&o.go(-1,!1)),C(ce,Me,P)}).catch(Fs)}))}let ie=Us(),se=Us(),Y;function he(W,fe,de){Ue(W);let ce=se.list();return ce.length?ce.forEach(ve=>ve(W,fe,de)):console.error(W),Promise.reject(W)}function Se(){return Y&&u.value!==Rn?Promise.resolve():new Promise((W,fe)=>{ie.add([W,fe])})}function Ue(W){return Y||(Y=!W,K(),ie.list().forEach(([fe,de])=>W?de(W):fe()),ie.reset()),W}function Be(W,fe,de,ce){let{scrollBehavior:ve}=e;if(!ls||!ve)return Promise.resolve();let Me=!de&&fu(ua(W.fullPath,0))||(ce||!de)&&history.state&&history.state.scroll||null;return tt().then(()=>ve(W,fe,Me)).then(P=>P&&cu(P)).catch(P=>he(P,W,fe))}let Qe=W=>o.go(W),He,et=new Set,Re={currentRoute:u,listening:!0,addRoute:w,removeRoute:R,clearRoutes:t.clearRoutes,hasRoute:N,getRoutes:S,resolve:v,options:e,push:V,replace:_,go:Qe,back:()=>Qe(-1),forward:()=>Qe(1),beforeEach:r.add,beforeResolve:d.add,afterEach:p.add,onError:se.add,isReady:Se,install(W){W.component("RouterLink",og),W.component("RouterView",ha),W.config.globalProperties.$router=Re,Object.defineProperty(W.config.globalProperties,"$route",{enumerable:!0,get:()=>kn(u)}),ls&&!He&&u.value===Rn&&(He=!0,V(o.location).catch(ce=>{}));let fe={};for(let ce in Rn)Object.defineProperty(fe,ce,{get:()=>u.value[ce],enumerable:!0});W.provide(Ui,Re),W.provide(Bi,fo(fe)),W.provide(zi,u);let de=W.unmount;et.add(W),W.unmount=function(){et.delete(W),et.size<1&&(y=Rn,z&&z(),z=null,u.value=Rn,He=!1,Y=!1),de()}}};function Fe(W){return W.reduce((fe,de)=>fe.then(()=>O(de)),Promise.resolve())}return Re}function Vu(e){return Mt(Bi)}function Gi(e){return["author_pass","repo_extend","repo_never","repo_slot","repo_pack"].includes(e)}var ji=new WeakMap;function Wi(e){if(!ji.has(e)){let t=e.get("/api/billing/").finally(()=>ji.delete(e));ji.set(e,t)}return ji.get(e)}function Ki(e,t,s=()=>{},i={}){let o=new URLSearchParams(window.location.search).get("billing");e.billing=null,e.billingLoading=!0,e.billingBusy=!1,e.billingError="",e.billingNotice="",e.billingPending=o==="success",e.billingRepository="";let r={billing_invalid_draft:"This draft could not be saved. Your form is unchanged. Try again.",billing_draft_not_found:"This checkout draft is unavailable or expired. Your local form is unchanged.",billing_recovery_required:"Your earlier payment needs verification. Please contact support before paying again.",billing_checkout_disabled:"New purchases are temporarily unavailable. You can still manage existing billing.",billing_unavailable:"Payments are not available yet. Please try again later.",billing_subscription_exists:"You already have a subscription. Use Manage billing to change or cancel it.",billing_checkout_in_progress:"You have another checkout open. Complete it, or wait up to 30 minutes for it to expire, before choosing a different option.",billing_busy:"Another billing request is processing. Please try again shortly.",billing_already_paid:"This repository or conference already has this paid option.",billing_invalid_review_window:"Conference packages cover up to 180 days. Check the review dates.",billing_invalid_conference:"Only a conference owner can pay for a conference awaiting payment.",repo_not_found:"Enter the ID of an existing repository that you own."};e.billingAmount=u=>u?.amount==null?"":new Intl.NumberFormat(void 0,{style:"currency",currency:u.currency,minimumFractionDigits:u.amount%100?2:0,maximumFractionDigits:2}).format(u.amount/100),e.billingPrice=u=>u.amount==null?"Price shown at checkout":e.billingAmount(u)+(u.interval?` / ${u.intervalCount>1?u.intervalCount+" ":""}${u.interval}`:" once"),e.billingPerMonth=u=>u?.amount==null?"":new Intl.NumberFormat(void 0,{style:"currency",currency:u.currency}).format(u.amount/1200),e.billingBytes=u=>{let y=Number(u)||0;if(y<1024)return`${y} B`;let m=Math.min(4,Math.floor(Math.log2(y)/10));return`${new Intl.NumberFormat(void 0,{maximumFractionDigits:1}).format(y/1024**m)} ${["B","KB","MB","GB","TB"][m]}`},e.billingDate=u=>u?new Date(u).toLocaleDateString(void 0,{year:"numeric",month:"short",day:"numeric"}):"",e.loadBilling=()=>(e.billingError="",e.billingLoading=!0,Wi(t).then(u=>{e.billing=u.data,e.emit?.("billing:updated",u.data)}).catch(()=>{e.billingError="Billing could not be loaded. Try again."}).finally(()=>{e.billingLoading=!1}));async function d(u,y,m=!0){if(!(e.billingBusy||!e.billing?.csrf)){e.billingBusy=!0,e.billingError="";try{let b=await t.post(`/api/billing/${u}`,y,{headers:{"x-csrf-token":e.billing.csrf}});if(m)window.location.assign(b.data.url);else return await e.loadBilling(),await s(),e.billingPending=!!b.data.pending,e.emit?.("billing:pending",e.billingPending),e.billingNotice=b.data.pending?"Your payment is still pending. Please do not pay again.":i.confirmedMessage||"Billing status refreshed. Your confirmed access appears below.",b.data}catch(b){e.billingError=r[b.data?.error]||"The billing request failed. Please try again."}finally{e.billingBusy=!1}}}e.checkout=(u,y="",m={})=>d("checkout",{planId:u,target:y,...m}),e.billingPortal=()=>d("portal",{}),e.refreshBilling=()=>d("refresh",{},!1);async function p(){for(let u=0;u<5;u++){let y=await e.refreshBilling();if(!y||!y.pending)return;await new Promise(m=>window.setTimeout(m,3e3))}e.billingNotice="Confirmation is taking longer than usual. You can refresh payment status later. Please do not pay again."}e.loadBilling().then(()=>{o==="success"?(e.billingNotice="Checking your payment. Paid access starts after confirmation.",p()):o==="portal"?e.refreshBilling().then(()=>{e.billingPending=!1,e.emit?.("billing:pending",!1),e.billingNotice=i.portalMessage?.(e.billing)||"Your billing details are up to date."}):o==="cancelled"&&(e.billingNotice="Checkout was closed. No new paid access has been activated.")})}function qu(e,t){return t?.split(".").reduce((s,i)=>s?.[i],e)}function qo(e=null,t=new Map){let s=st({}),i=[],o=!1,r=new Proxy(s,{get(d,p){return typeof p=="string"&&p.startsWith("__v_")||Reflect.has(d,p)?Reflect.get(d,p):e?.[p]}});return Object.defineProperty(s,"parent",{value:e,configurable:!0}),Object.defineProperty(s,"viewState",{get:()=>r}),r.watch=(d,p,u=!1,y=!0)=>{let m=typeof d=="function"?()=>d(r):()=>qu(r,d),b=dt(m,p,{deep:u,flush:"post"});return i.push(b),y&&tt(()=>{o||p(m(),m())}),b},r.watchGroup=(d,p,u=!0)=>r.watch(()=>d.map(y=>qu(r,y)),p,!0,u),r.on=(d,p)=>{if(d==="dispose")return i.push(p),()=>{};t.has(d)||t.set(d,new Set),t.get(d).add(p);let u=()=>t.get(d)?.delete(p);return i.push(u),u},r.emit=(d,...p)=>{for(let u of[...t.get(d)||[]])u({},...p)},r.dispose=()=>{o=!0,i.splice(0).reverse().forEach(d=>d())},es(r.dispose),r}function Ct(){let e=new Set,t=new Set,s=!1,i=(r,d=0)=>{if(s)return;let p=setTimeout(()=>{e.delete(p),r()},d);return e.add(p),p};i.cancel=r=>{clearTimeout(r),e.delete(r)};let o=(r,d)=>{if(s)return;let p=setInterval(r,d);return t.add(p),p};return o.cancel=r=>{clearInterval(r),t.delete(r)},es(()=>{s=!0,e.forEach(clearTimeout),t.forEach(clearInterval)}),{timeout:i,interval:o}}function Bt(){let e=new Set;return es(()=>{e.forEach(t=>t()),e.clear()}),(t,s,i,o)=>{t.addEventListener(s,i,o);let r=()=>{t.removeEventListener(s,i,o),e.delete(r)};return e.add(r),r}}var ma=function(e,t=e){let s=/\bXXXX-\d+\b/g;t.on("dark-mode",(O,U)=>{e.aceOption&&(e.aceOption.theme=U?"nord_dark":"chrome")});let i=Ct(),o=Bt();e.isMac=/Mac|iPhone|iPad|iPod/.test(navigator.platform||navigator.userAgent);let r={yml:"yaml",txt:"text",py:"python",js:"javascript",ts:"typescript"},d=["license","txt"],p=["png","jpg","jpeg","gif","svg","ico","bmp","tiff","tif","webp","avif","heif","heic"],u=["wav","mp3","ogg","wma","flac","aac","m4a"],y=["mp4","avi","webm","mov","mpg","mpeg","mkv","flv","wmv","3gp","3g2","m4v","f4v","f4p","f4a","f4b"];e.toggleSource=function(){e.showSource=!e.showSource},e.toggleAllowScripts=function(){e.allowScripts=!e.allowScripts};let m=(()=>{try{return window.localStorage?.getItem("wrapLines")}catch{return null}})();e.wrapLines=(m??(window.matchMedia?.("(max-width: 767px)").matches?"false":"true"))!=="false",e.toggleWrap=function(){e.wrapLines=!e.wrapLines;try{window.localStorage?.setItem("wrapLines",String(e.wrapLines))}catch{}e.codeEditor?.session.setUseWrapMode(e.wrapLines)};function b(){return window.document.querySelector(".reading-layout .markdown-body")}function h(){let O=b();O&&(O.querySelectorAll("mark.md-find").forEach(U=>{U.replaceWith(window.document.createTextNode(U.textContent))}),O.normalize())}e.runMdFind=function(){h(),e.mdFindTotal=0,e.mdFindIndex=0;let O=(e.mdFindQuery||"").trim(),U=b();if(!O||!U)return;let C=!!e.mdFindCase,L=C?O:O.toLowerCase(),z=window.document.createTreeWalker(U,4),K=[];for(;z.nextNode();)(C?z.currentNode.nodeValue:z.currentNode.nodeValue.toLowerCase()).includes(L)&&K.push(z.currentNode);let ie=0;for(let se of K){let Y=se.nodeValue,he=C?Y:Y.toLowerCase(),Se=window.document.createDocumentFragment(),Ue=0,Be;for(;(Be=he.indexOf(L,Ue))!==-1;){Se.appendChild(window.document.createTextNode(Y.slice(Ue,Be)));let Qe=window.document.createElement("mark");Qe.className="md-find",Qe.textContent=Y.slice(Be,Be+O.length),Se.appendChild(Qe),ie++,Ue=Be+O.length}Se.appendChild(window.document.createTextNode(Y.slice(Ue))),se.parentNode.replaceChild(Se,se)}e.mdFindTotal=ie,ie&&e.stepMdFind(0)},e.stepMdFind=function(O){let U=b();if(!U||!e.mdFindTotal)return;let C=U.querySelectorAll("mark.md-find");e.mdFindIndex=(e.mdFindIndex+O+C.length)%C.length,C.forEach((L,z)=>L.classList.toggle("is-current",z===e.mdFindIndex)),C[e.mdFindIndex]?.scrollIntoView({block:"center",behavior:"smooth"})},e.toggleMdFind=function(O){if(e.mdFindOpen=O===void 0?!e.mdFindOpen:O,!e.mdFindOpen){h(),e.mdFindTotal=0;return}tt(()=>window.document.querySelector(".md-find-input")?.focus())},e.findInFile=function(){let O=e.codeEditor;if(!O)return;O.focus(),O.execCommand("find");let U=()=>{let C=O.searchBox?.element;C&&(O.renderer.setScrollMargin(52,12,0,0),!C._dockObserver&&(C._dockObserver=new MutationObserver(()=>{O.renderer.setScrollMargin(C.style.display!=="none"?52:12,12,0,0)}),C._dockObserver.observe(C,{attributes:!0,attributeFilter:["style"]})))};U(),setTimeout(U,150)};let w=[[/^\s*(?:export\s+)?(?:default\s+)?(?:abstract\s+)?class\s+([A-Za-z_$][\w$]*)/,"class"],[/^\s*(?:export\s+)?(?:default\s+)?(?:async\s+)?function\s*\*?\s*([A-Za-z_$][\w$]*)/,"function"],[/^\s*(?:export\s+)?(?:const|let|var)\s+([A-Za-z_$][\w$]*)\s*=\s*(?:async\s*)?(?:function|\([^)]*\)\s*=>|[A-Za-z_$][\w$]*\s*=>)/,"function"],[/^\s*(?:async\s+)?def\s+([A-Za-z_]\w*)/,"function"],[/^\s*class\s+([A-Za-z_]\w*)/,"class"],[/^\s*func\s+(?:\([^)]*\)\s*)?([A-Za-z_]\w*)/,"function"],[/^\s*(?:pub\s+)?fn\s+([A-Za-z_]\w*)/,"function"],[/^\s*(?:public|private|protected|static|\s)+[\w<>\[\],\s]+\s+([A-Za-z_]\w*)\s*\([^;]*\)\s*\{?\s*$/,"function"]],R={content:null,list:[]};e.symbolsOpen=!1,e.symbols=function(){if(typeof e.content!="string"||e.content.length>2e6)return[];if(R.content===e.content)return R.list;let O=[];return e.content.split(` -`).forEach((U,C)=>{for(let[L,z]of w){let K=L.exec(U);if(K&&!/^(if|for|while|switch|return|catch)$/.test(K[1])){O.push({name:K[1],kind:z,line:C+1});break}}}),R={content:e.content,list:O.slice(0,300)},R.list},e.goToSymbol=function(O){e.symbolsOpen=!1;let U=e.codeEditor;U&&(U.scrollToLine(O-1,!0,!0,()=>{}),U.gotoLine(O,0,!0),window.history.replaceState(null,"",window.location.pathname+window.location.search+"#L"+O),window.dispatchEvent(new HashChangeEvent("hashchange")))},e.gotoLine=function(){e.codeEditor&&(e.moreOpen=!1,e.gotoError="",e.gotoValue=String(e.codeEditor.getCursorPosition().row+1),e.gotoOpen=!0,setTimeout(()=>{let O=window.document.getElementById("goto-input");O&&(O.focus(),O.select())},0))},e.closeGoto=function(){e.gotoOpen=!1,e.gotoError="",e.codeEditor?.focus()},e.submitGoto=function(){let O=e.codeEditor;if(!O)return;let U=/^\s*:?\s*(\d+)\s*(?:[:,]\s*(\d+))?\s*$/.exec(e.gotoValue||""),C=O.session.getLength();if(!U||+U[1]<1||+U[1]>C){e.gotoError="Enter a line from 1 to "+C;return}O.gotoLine(+U[1],U[2]?Math.max(0,+U[2]-1):0,!0),e.gotoOpen=!1,e.gotoError="",O.focus()},e.rootEntries=function(){return[...e.files||[]].sort((O,U)=>{let C=O.size==null,L=U.size==null;return C!==L?C?-1:1:O.name.localeCompare(U.name)})},e.formatSize=function(O){if(O==null)return"";if(O<1024)return O+" B";let U=O/1024,C=L=>L.toFixed(1).replace(/\.0$/,"");return U<1024?C(U)+" KB":U<1024*1024?C(U/1024)+" MB":C(U/1024/1024)+" GB"},e.fileSize=function(O){if(!O)return null;let U=O.replace(/^\/+/,""),C=(e.files||[]).find(L=>(L.path?L.path+"/":"")+L.name===U);return C&&C.size!=null?C.size:null},e.revealFolder=function(O){e.sidebarHidden=!1,e.sidebarCollapsed=!1,tt(()=>{let U=window.document.querySelector('.files a[data-path="/'+(window.CSS?.escape?window.CSS.escape(O):O)+'"]');U&&(U.closest("li")?.classList.contains("open")||U.click(),U.scrollIntoView({block:"nearest"}),U.focus())})};let S={content:null,n:0},N=O=>{if(S.content===O)return S.n;let U=O;if(typeof U=="string")try{U=JSON.parse(U)}catch{U=null}let C=[],L=K=>{Array.isArray(K)?C.push(K.join("")):typeof K=="string"&&C.push(K)};(U&&(U.cells||(U.worksheets||[]).flatMap(K=>K.cells||[]))||[]).forEach(K=>{L(K?.source??K?.input),(K?.outputs||[]).forEach(ie=>{L(ie?.text),ie?.data&&(L(ie.data["text/plain"]),L(ie.data["text/markdown"]),L(ie.data["text/html"])),L(ie?.traceback)})});let z=C.reduce((K,ie)=>K+(ie.match(s)||[]).length,0);return S={content:O,n:z},z};e.redactionCount=function(){return e.type==="IPython"?N(e.content):typeof e.content!="string"?0:((e.type==="html"?e.content.replace(/<[^>]*>/g," "):e.content).match(s)||[]).length},e.renderRedacted=_o;let v=O=>O.toLowerCase().trim().replace(/[^a-z0-9\s-]/g,"").replace(/\s+/g,"-").slice(0,60)||"section";e.renderReadme=function(O){let U=e.renderRedacted(O);if(!U||typeof window.DOMParser!="function")return U;let C=new window.DOMParser().parseFromString("
"+U+"
","text/html"),L={};return C.querySelectorAll("h1, h2, h3").forEach(z=>{let K=z.id||v(z.textContent);L[K]?K+="-"+ ++L[K]:L[K]=1,z.id=K}),C.body.firstChild.innerHTML};let E={content:null,list:[]};e.readmeToc=function(){if(e.type!=="html"||typeof e.content!="string")return[];if(E.content===e.content)return E.list;let U=[...new window.DOMParser().parseFromString("
"+e.renderReadme(e.sanitize?e.sanitize(e.content):e.content)+"
","text/html").querySelectorAll("h2, h3")].map(C=>({id:C.id,text:C.textContent.trim(),level:C.tagName==="H3"?3:2})).slice(0,40);return E={content:e.content,list:U},U},e.activeHeading=null,o(window,"scroll",()=>{let O=e.readmeToc?e.readmeToc():[];if(!O.length)return;let U=150,C="",L="";for(let z of O){let K=window.document.getElementById(z.id);if(!K)continue;let ie=K.getBoundingClientRect().top;ie{let C=[],L=[],z="",K=!1;for(let ie=0;ieie.length>1||ie[0]!=="")};e.isCsv=()=>typeof e.content=="string"&&e.type!=="html"&&/\.(csv|tsv)$/i.test(e.filePath||"")&&e.content.length<=1024*1024,e.csvRows=()=>{if(M.content!==e.content){let O=/\.tsv$/i.test(e.filePath||"")?" ":",";M={content:e.content,rows:V(e.content,O)}}return M.rows},e.csvNumCol=O=>{let U=e.csvRows().slice(1).map(C=>C[O]).filter(C=>C!=null&&String(C).trim()!=="");return U.length>0&&U.every(C=>e.csvNumeric(C))},e.csvNumeric=O=>/^\s*[-+]?(\d[\d,]*)?(\.\d+)?(e[-+]?\d+)?%?\s*$/i.test(O)&&/\d/.test(O),e.redactParts=function(O){let U=[],C=0,L,z=/\bXXXX-(\d+)\b/g;for(O=String(O||"");L=z.exec(O);)L.index>C&&U.push({t:O.slice(C,L.index)}),U.push({n:L[1]}),C=L.index+L[0].length;return C{e.pathCopied=!1},1600))},e.contentCopied=!1,e.copyContent=async function(){if(typeof e.content!="string"||!window.navigator.clipboard?.writeText)return;let O=e.content;if(e.type==="html"&&e.url)if(e.preview)O=e.sourceContent;else try{O=await(await window.fetch(e.url,{credentials:"same-origin"})).text()}catch{return}await window.navigator.clipboard.writeText(O),e.contentCopied=!0,setTimeout(()=>{e.contentCopied=!1},1600)};function _(O){return r[O]?r[O]:O}function G(O){return O=="pdf"?"pdf":O=="html"||O=="htm"?"html-doc":["md","markdown","mdown","mkdn","mdx"].includes(O)?"md":O=="org"?"org":O=="ipynb"?"IPython":d.indexOf(O)>-1?"text":p.indexOf(O)>-1?"image":y.indexOf(O)>-1?"media":u.indexOf(O)>-1?"audio":"code"}e.downloadUrl=()=>e.preview?e.url:e.url+"&download=true",e.prepareFile=function(O){e.showSource=!1,e.allowScripts=!1,e.imageSize="",e.filePath=O,e.paths=O.split("/").filter(Boolean);let U=e.filePath.toLowerCase(),C=U.lastIndexOf(".");C>-1&&(U=U.substring(C+1));let L={javascript:"JavaScript",typescript:"TypeScript",tsx:"TSX",jsx:"JSX",python:"Python",java:"Java",c_cpp:"C/C++",csharp:"C#",golang:"Go",rust:"Rust",ruby:"Ruby",php:"PHP",html:"HTML",css:"CSS",scss:"SCSS",json:"JSON",yaml:"YAML",markdown:"Markdown",sh:"Shell",dockerfile:"Dockerfile",xml:"XML",sql:"SQL",kotlin:"Kotlin",swift:"Swift",scala:"Scala",r:"R",julia:"Julia",latex:"LaTeX",toml:"TOML",csv:"CSV",tsv:"TSV",text:""},z=_(U);e.languageName=L[z]??(z?z.charAt(0).toUpperCase()+z.slice(1):""),e.aceOption={readOnly:!0,useWrapMode:!0,showGutter:!0,theme:"chrome",useSoftTab:!0,tabSize:2,fontSize:window.matchMedia?.("(max-width: 767px)").matches?12:13,keyBinding:"vscode",fullLineSelection:!0,highlightActiveLine:!1,highlightGutterLine:!1,cursor:"hide",showInvisibles:!1,showIndentGuides:!1,showPrintMargin:!1,highlightSelectedWord:!1,enableBehaviours:!0,fadeFoldWidgets:!1,mode:_(U),onLoad:function(K){e.codeEditor=un(K);{let Re=K.session,Fe=Re.getTokens.bind(Re),W=/\bXXXX-\d+\b/g;if(Re.getTokens=function(fe){let de=Fe(fe);if(!de.some(ve=>ve.value.indexOf("XXXX-")!==-1))return de;let ce=[];for(let ve of de){if(ve.value.indexOf("XXXX-")===-1){ce.push(ve);continue}let Me=0;W.lastIndex=0;let P;for(;P=W.exec(ve.value);)P.index>Me&&ce.push({type:ve.type,value:ve.value.slice(Me,P.index)}),ce.push({type:"redacted.n"+P[0].slice(5),value:P[0]}),Me=P.index+P[0].length;Me`.ace_redacted.ace_n${ce+1}::after{content:"${ce+1}"}`).join(""),window.document.head.appendChild(fe)}K.renderer.updateFull(!0)}K.session.setUseWrapMode(e.wrapLines!==!1);let ie=K.container.closest?.(".file-card"),se=()=>{if(!ie)return;let Re=K.renderer,Fe=(Re.layerConfig?.width||0)-(Re.$size?.scrollerWidth||0);ie.classList.toggle("at-right-edge",Fe<=2||Re.getScrollLeft()>=Fe-2)};K.session.on("changeScrollLeft",se),K.renderer.on("afterRender",se),window.matchMedia?.("(max-width: 767px)").matches&&K.setOption("hScrollBarAlwaysVisible",!0);let Y=ace.require("ace/range").Range,he=null;function Se(Re,Fe){he!==null&&(K.session.removeMarker(he),he=null),Re!=null&&(he=K.session.addMarker(new Y(Re,0,Fe,1),"highlighted-line","fullLine"))}function Ue(Re){let Fe=!e.preview&&window.location.hash.match(/^#L(\d+)(?:-L(\d+))?/);if(!Fe){Se(null);return}let W=parseInt(Fe[1])-1,fe=Fe[2]?parseInt(Fe[2])-1:W;Se(W,fe),Re&&i.timeout(()=>{K.scrollToLine(W,!0,!0,function(){})},100)}Ue(!0);let Be=null;K.on("guttermousedown",function(Re){let Fe=Re.getDocumentPosition().row,W=Re.domEvent&&Re.domEvent.shiftKey,fe=Fe,de=Fe;W&&Be!==null?(fe=Math.min(Be,Fe),de=Math.max(Be,Fe)):Be=Fe;let ce=fe===de?`#L${fe+1}`:`#L${fe+1}-L${de+1}`,ve=window.location.pathname+window.location.search+ce;e.preview||window.history.replaceState(null,"",ve),Se(fe,de),Re.stop()});let Qe=o(window,"hashchange",()=>Ue(!1));K.setFontSize(e.aceOption.fontSize),K.setOptions({fontFamily:"'JetBrains Mono', ui-monospace, SFMono-Regular, Menlo, monospace"}),K.container.style.lineHeight="20px",K.renderer.setPadding(16),K.renderer.setScrollMargin(12,12,0,0),K.renderer.updateFontSize(),K.setReadOnly(e.aceOption.readOnly),K.setKeyboardHandler(e.aceOption.keyBinding),K.setSelectionStyle(e.aceOption.fullLineSelection?"line":"text"),K.setOption("displayIndentGuides",!1),K.setHighlightActiveLine(e.aceOption.highlightActiveLine),e.aceOption.cursor=="hide"&&(K.renderer.$cursorLayer.element.style.display="none"),K.setHighlightGutterLine(e.aceOption.highlightGutterLine),K.setShowInvisibles(e.aceOption.showInvisibles),K.setDisplayIndentGuides(e.aceOption.showIndentGuides),K.renderer.setShowPrintMargin(e.aceOption.showPrintMargin),K.setHighlightSelectedWord(e.aceOption.highlightSelectedWord),K.session.setUseSoftTabs(e.aceOption.useSoftTab),K.session.setTabSize(e.aceOption.tabSize),K.setBehavioursEnabled(e.aceOption.enableBehaviours),K.setFadeFoldWidgets(e.aceOption.fadeFoldWidgets);let He=()=>!e.preview||K.isFocused(),et=o(window,"keydown",Re=>{if((Re.ctrlKey||Re.metaKey)&&!Re.altKey&&Re.key.toLowerCase()==="g"&&document.body.contains(K.container)&&He()){Re.preventDefault(),e.gotoLine();return}if(Re.altKey&&!Re.ctrlKey&&!Re.metaKey&&Re.key.toLowerCase()==="z"&&document.body.contains(K.container)&&He()){Re.preventDefault(),e.toggleWrap();return}(Re.ctrlKey||Re.metaKey)&&!Re.altKey&&Re.key.toLowerCase()==="f"&&document.body.contains(K.container)&&He()&&(Re.preventDefault(),e.findInFile())});return()=>{Qe(),et()}}},e.isDarkMode&&(e.aceOption.theme="nord_dark"),e.type=G(U)},e.renderFileContent=function(O,U,C,L){if(e.type=U,e.content=O,e.sourceContent=O,e.content==""&&(e.content=null),e.type=="md"&&(e.content=renderMD(O,C),e.type="html"),e.type=="org"){let K=contentAbs2Relative(O);var z=new Org.Parser().parse(K).convert(Org.ConverterHTML,{headerOffset:1,exportFromLineNumber:!1,suppressSubScriptHandling:!0,suppressAutoLink:!1});e.content=DOMPurify.sanitize(z.toString()),e.type="html"}e.type=="code"&&L=="application/octet-stream"&&(e.type="binary",e.content="binary"),i.timeout(()=>{Prism.highlightAll()},50)};let te=["image","media","audio","pdf","IPython","binary"],X=["file_too_big","file_not_found","file_not_accessible","file_not_supported","folder_not_supported"];e.fileFrame=()=>e.filePath?te.includes(e.type)?e.content!=null:e.type==="error"?X.includes(e.content):e.content==null&&["code","text"].includes(e.type):!1,e.fileKind=()=>{let O=(e.paths||[])[(e.paths||[]).length-1]||"",U=O.lastIndexOf("."),C=U>0?O.slice(U+1).toUpperCase():"";if(e.type==="image")return(C==="JPG"?"JPEG":C)+" image";let L={WEBM:"WebM",OGG:"Ogg",OGV:"Ogg",MOV:"QuickTime",M4V:"M4V",MKV:"Matroska"};return e.type==="media"?(L[C]||C)+" video":e.type==="audio"?C+" audio":e.type==="pdf"?"PDF":e.type==="IPython"?"Jupyter notebook":e.type==="binary"?"Binary file":e.languageName||(C?C+" file":"File")},e.imageSize="",e.onImageLoad=O=>{let U=O.target;U?.naturalWidth&&(e.imageSize=`${U.naturalWidth} \xD7 ${U.naturalHeight}`)},o(document,"click",O=>{e.preview&&(O.target.closest?.(".symbols")||(e.symbolsOpen=!1),O.target.closest?.(".tb-more")||(e.moreOpen=!1),O.target.closest?.(".tb-toc-m")||(e.tocOpen=!1),O.target.isConnected&&!O.target.closest?.(".goto-pop, .btn-goto, .tb-more")&&(e.gotoOpen=!1))})};function ga(e,t,s){let i,o=!1,r="form-draft:"+s,d=()=>Object.fromEntries(t.map(h=>[h,e[h]])),p=()=>JSON.stringify(d()),u=h=>{for(let w of t)Object.prototype.hasOwnProperty.call(h,w)&&(e[w]=h[w]);e.options?.expirationDate&&(e.options.expirationDate=new Date(e.options.expirationDate))},y=()=>{try{window.sessionStorage.removeItem(r)}catch{}},m=(h=!1)=>{if(i!==void 0){if(h&&document.querySelectorAll("input, select, textarea").forEach(w=>{w._field?.binding.state===e&&w._field.timer&&w._field.commit()}),e.unsavedChanges=p()!==i,e.draftSaved=!1,!e.unsavedChanges){y();return}try{window.sessionStorage.setItem(r,JSON.stringify({account:e.user?.username||null,savedAt:Date.now(),values:d()})),e.draftSaved=!0}catch{}}},b=()=>m(!0);return e.on("routeLeave",b),window.addEventListener("beforeunload",b),e.on("dispose",()=>window.removeEventListener("beforeunload",b)),{restore(){i=p();let h;try{h=JSON.parse(window.sessionStorage.getItem(r)||"null")}catch{}let w=h&&h.account===(e.user?.username||null)&&Date.now()-h.savedAt<30*6e4&&h.values;return w&&(u(h.values),e.draftRestored=!0),o||(o=!0,e.watch(()=>d(),()=>m(),!0)),e.unsavedChanges=p()!==i,!!w},checkpoint(){return document.querySelectorAll("input, select, textarea").forEach(h=>{h._field?.binding.state===e&&h._field.timer&&h._field.commit()}),JSON.parse(p())},accept(h){i=JSON.stringify(h),e.draftRestored=!1,m()},discard(){document.querySelectorAll("input, select, textarea").forEach(h=>{h._field?.binding.state!==e||!h._field.timer||(clearTimeout(h._field.timer),h._field.timer=null,h.value=h._field.binding.value??"")}),i!==void 0&&u(JSON.parse(i)),e.draftRestored=!1,m()},clear(){i=p(),e.unsavedChanges=!1,e.draftRestored=!1,e.draftSaved=!1,y()}}}var wa={};rf(wa,{bigNum:()=>dg,date:()=>bg,dateEcho:()=>ya,diff:()=>pg,duration:()=>qn,filter:()=>vg,humanFileSize:()=>lg,humanTime:()=>va,limitTo:()=>gg,money:()=>hg,number:()=>fg,orderBy:()=>yg,plural:()=>wg,shortDate:()=>ba,statusLabel:()=>cg,statusMsg:()=>Yi,title:()=>ug,uppercase:()=>mg});var lg=e=>String(window.humanFileSize(e)).replace(/([KMGTPEZY])iB$/,"$1B").replace(/\.0 ([KMGTPEZY]?B)$/," $1"),dg=(function(){return function(t){let s=Number(t)||0,i=Math.abs(s);return i<1e3?String(s):i<1e4?(s/1e3).toFixed(1).replace(/\.0$/,"")+"k":i<1e6?Math.round(s/1e3)+"k":i<1e7?(s/1e6).toFixed(1).replace(/\.0$/,"")+"M":Math.round(s/1e6)+"M"}})(),va=(function(){return function(t){if(!t)return"never";var s=null;t instanceof Date&&(s=t,t=Math.round((Date.now()-t)/1e3)),(typeof t=="string"||typeof t=="number")&&(s=new Date(t),t=Math.round((Date.now()-s)/1e3));var i=t<0?"from now":"ago";if(Math.abs(t)>7200*24)return(s&&!isNaN(s)?s:new Date(Date.now()-t*1e3)).toLocaleDateString(void 0,{day:"numeric",month:"short",year:"numeric"});t=Math.abs(t);for(var o=[t/60/60/24/365,t/60/60/24/30,t/60/60/24/7,t/60/60/24,t/60/60,t/60,t],r=["year","month","week","day","hour","minute","second"],d=0;d1&&(u+="s"),p>=1)return p+" "+u+" "+i}return"0 seconds "+i}})(),ug=(function(){return function(e){if(!e)return e;e=e.toLowerCase();var t=e.split(" "),s=t.map(function(i){return i.charAt(0).toUpperCase()+i.substring(1,i.length)});return s.join(" ")}})(),cg=(function(){var e={ready:"Ready",error:"Error",expired:"Expired",expiring:"Expiring",removed:"Removed",removing:"Removing",queue:"Queued",download:"Downloading",downloaded:"Downloaded",preparing:"Preparing",anonymizing:"Anonymizing"};return function(t){if(!t)return"";if(e[t])return e[t];var s=String(t).replace(/[_-]+/g," ").toLowerCase();return s.charAt(0).toUpperCase()+s.slice(1)}})(),Yi=(function(){var e={branch_not_found:"Branch not found on GitHub",repo_not_found:"Repository not found on GitHub",repository_not_found:"Repository not found on GitHub",repo_not_accessible:"Repository is not accessible with your token",pr_not_found:"Pull request not found on GitHub",gist_not_found:"Gist not found on GitHub",commit_not_found:"Commit not found on GitHub",repo_too_big:"Repository exceeds the size limit",repository_too_big:"Repository exceeds the size limit",quota_exceeded:"Storage quota exceeded",incomplete_record:"Incomplete record: missing identifier"};return function(t){if(!t)return t;var s=t.match(/^rate_limited:(\d+)$/);if(s){var i=Math.max(0,Math.ceil((parseInt(s[1],10)-Date.now())/1e3));if(i<=0)return"Rate limited \u2014 resuming soon";var o=Math.floor(i/60),r=i%60;return"Rate limited \u2014 retrying in "+(o>0?o+"m "+r+"s":r+"s")}if(e[t])return e[t];var d=/^([a-z0-9]+(?:_[a-z0-9]+)+):\s*\S/.exec(t);if(d){if(e[d[1]])return e[d[1]];var p=d[1].replace(/_/g," ");return p.charAt(0).toUpperCase()+p.slice(1)}if(/^[a-z0-9]+(_[a-z0-9]+)+$/.test(t)){var u=t.replace(/_/g," ");return u.charAt(0).toUpperCase()+u.slice(1)}return t}})(),pg=(function(e){let t=i=>i.replace(/&/g,"&").replace(//g,">");function s(i,o){if(!o)return;let r=o.newPath&&o.newPath!=="/dev/null"?o.newPath:o.oldPath||"",d=o.oldPath==="/dev/null"?"added":o.newPath==="/dev/null"?"deleted":o.oldPath&&o.newPath&&o.oldPath!==o.newPath?"renamed":"modified";if(i.push('
'),i.push('
'+t(r)+''+d+"
"),o.lines.length){i.push('');for(let p of o.lines)i.push('");i.push("
'+(p.oldNo||"")+''+(p.newNo||"")+''+(p.kind==="add"?"+":p.kind==="remove"?"-":"")+''+t(p.text)+"
")}i.push("
")}return function(i){if(!i)return i;let o=[],r=null,d=0,p=0,u=()=>(r||(r={oldPath:"",newPath:"",lines:[]}),r),y=()=>{r&&(r.lines.length||r.oldPath||r.newPath)&&(s(o,r),r=null)},m=i.split(` -`);for(let b=0;be});function fg(e,t){return e==null?"":Number(e).toLocaleString(void 0,t==null?{}:{minimumFractionDigits:t,maximumFractionDigits:t})}function hg(e,t="EUR"){let s=Number(e)||0;return new Intl.NumberFormat(void 0,{style:"currency",currency:t,minimumFractionDigits:s%1?2:0,maximumFractionDigits:2}).format(s)}function mg(e){return String(e??"").toUpperCase()}function gg(e,t,s=0){return(e||[]).slice(s,s+t)}function vg(e,t){return Array.isArray(e)?typeof t=="function"?e.filter(t):e:[]}function yg(e,t){if(!t)return e||[];let s=Array.isArray(t)?t:[t];return[...e||[]].sort((i,o)=>{for(let r of s){let d=r[0]==="-"?-1:1;r=r.replace(/^[+-]/,"");let p=r.split(".").reduce((y,m)=>y?.[m],i),u=r.split(".").reduce((y,m)=>y?.[m],o);if(typeof p=="string"&&(p=p.toLowerCase()),typeof u=="string"&&(u=u.toLowerCase()),p!==u)return(p==null?-1:u==null?1:pi[o])}function wg(e,t){return(t?.[e]??t?.[e===1?"one":"other"]??"").replace(/\{\}/g,e??0)}function ya(e){if(!e)return"";let t=/^(\d{4})-(\d{2})-(\d{2})$/.exec(String(e)),s=t?new Date(+t[1],+t[2]-1,+t[3]):new Date(e);if(isNaN(s))return"";let i=s.toLocaleDateString(void 0,{year:"numeric",month:"short",day:"numeric"}),o=new Date;o.setHours(0,0,0,0);let r=Math.round((s-o)/864e5),d;if(r===0)d="today";else if(r===1)d="tomorrow";else if(r===-1)d="yesterday";else{let p=Math.abs(r),u=Math.round(p/30.44),y=p<14?[p,"day"]:p<60?[Math.round(p/7),"week"]:u<18?[u,"month"]:[Math.round(p/365.25),"year"],m=y[0]+" "+y[1]+(y[0]===1?"":"s");d=r>0?"in "+m:m+" ago"}return i+" \xB7 "+d}function qn(e){if(e==null||e===""||isNaN(e))return"";e=Number(e);let t="\u202F";if(e<1e3)return+(e<10?e.toFixed(2):e<100?e.toFixed(1):Math.round(e))+t+"ms";let s=e/1e3;if(s<60)return+(s<10?s.toFixed(2):s.toFixed(1))+t+"s";let i=r=>String(r).padStart(2,"0"),o=Math.round(s);return o<3600?Math.floor(o/60)+"m "+i(o%60)+"s":Math.floor(o/3600)+"h "+i(Math.floor(o%3600/60))+"m"}function ba(e){if(!e)return"";let t=new Date(e);if(isNaN(t))return"";let s={day:"numeric",month:"short"};return t.getFullYear()!==new Date().getFullYear()&&(s.year="numeric"),t.toLocaleDateString(void 0,s)}var Xi=e=>["preparing","download","downloading","downloaded","queue","anonymizing"].includes(e)?"preparing":e==="expiring"?"expired":e==="removing"?"removed":e;function Ji(e,{flags:t,keys:s,count:i,onChange:o=()=>{}}){if(e.segView=()=>{let r=t()||{};if(s.every(p=>!!r[p]))return"all";let d=s.filter(p=>!!r[p]);return d.length===1?d[0]:"custom"},e.setSegView=r=>{let d=t();if(d){for(let p of s)d[p]=r==="all"?!0:p===r;o()}},e.segCount=r=>r==="all"?s.reduce((d,p)=>d+i(p),0):i(r),t()&&e.segView()==="custom")for(let r of s)t()[r]=!0}var $u=function(e,t,s){let i=Ct(),o=Bt();Gu(i,o),e.Math=Math,e.watch("user.status",()=>{e.user==null&&s.url("/")}),e.user==null&&s.url("/"),e.repositories=[],e.total=-1,e.totalPage=0,e.statusCounts=[],e.totalSize=0,e.selected={},e.allSelected=!1;let r=S=>{if(S.key==="/"&&!["INPUT","TEXTAREA","SELECT"].includes(document.activeElement?.tagName)){S.preventDefault();let N=document.querySelector('.admin-filter-toolbar input[type="search"]');N&&N.focus()}};o(document,"keydown",r),e.on("dispose",()=>document.removeEventListener("keydown",r)),e.clearFilter=S=>{S==="dateRange"?(e.query.dateFrom="",e.query.dateTo=""):e.query[S]="",e.query.page=1},e.chips=[];let d=()=>{let S=[];e.query.owner&&S.push({key:"owner",label:"Owner",value:e.query.owner}),e.query.conference&&S.push({key:"conference",label:"Conference",value:e.query.conference}),e.chips=S};e.showStatusMessage=S=>{let N=S.statusMessage||"(no message)";window.prompt(`Status message for ${S.repoId} (${S.status}):`,N)},e.fetchGithubInfo=S=>{let N=window.open("","_blank");N&&N.document.write("
Loading GitHub info for "+S.repoId+"...
"),t.get("/api/admin/repos/"+S.repoId+"/github").then(v=>{N&&(N.document.open(),N.document.write('
'+JSON.stringify(v.data,null,2).replace(/[<>]/g,E=>E==="<"?"<":">")+"
"),N.document.close())},v=>{let E=v&&v.data?JSON.stringify(v.data,null,2):String(v);N&&(N.document.body.innerHTML='
'+E+"
")})},e.statusCountFor=S=>{let N=(e.statusCounts||[]).find(v=>v._id===S);return N?N.count:0},e.statusStorageFor=S=>{let N=(e.statusCounts||[]).find(v=>v._id===S);return N?N.storage:0},e.isErrorsOnly=()=>e.query&&e.query.error&&!e.query.ready&&!e.query.preparing&&!e.query.expired&&!e.query.removed,e.toggleErrorsOnly=()=>{e.isErrorsOnly()?Object.assign(e.query,{ready:!1,preparing:!0,expired:!1,removed:!1,error:!0}):Object.assign(e.query,{ready:!1,preparing:!1,expired:!1,removed:!1,error:!0}),e.query.page=1},e.toggleSortDirection=()=>{e.query.direction=e.query.direction==="asc"?"desc":"asc"},e.sortBy=S=>{e.query.sort===S?e.query.direction=e.query.direction==="asc"?"desc":"asc":(e.query.sort=S,e.query.direction="desc"),e.query.page=1},e.sortIcon=S=>e.query.sort===S?e.query.direction==="asc"?"fa-arrow-up":"fa-arrow-down":"";let p="admin.repos.filterPrefs",u={page:1,limit:25,sort:"lastView",direction:"desc",search:"",owner:"",conference:"",dateFrom:"",dateTo:"",ready:!0,expired:!0,removed:!0,error:!0,preparing:!0},y=loadFilterPrefs(p)||{};e.query=Object.assign({},u,y,{page:1,search:""});let m=s.search();m.owner&&(e.query.owner=m.owner),m.conference&&(e.query.conference=m.conference),m.search&&(e.query.search=m.search);let b="admin.repos.presets";e.presets=JSON.parse(localStorage.getItem(b)||"[]"),e.savePreset=()=>{let S=window.prompt("Preset name:");if(!S)return;let N=Object.assign({},e.query);delete N.page,e.presets=(e.presets||[]).filter(v=>v.name!==S),e.presets.push({name:S,query:N}),localStorage.setItem(b,JSON.stringify(e.presets))},e.applyPreset=S=>{Object.assign(e.query,S.query,{page:1})},e.deletePreset=S=>{e.presets=(e.presets||[]).filter(N=>N.name!==S.name),localStorage.setItem(b,JSON.stringify(e.presets))},e.selectAllOnPage=()=>{e.allSelected=!e.allSelected,e.repositories.forEach(S=>{e.selected[S.repoId]=e.allSelected})},e.selectedCount=()=>Object.values(e.selected||{}).filter(Boolean).length,e.selectedRepos=()=>e.repositories.filter(S=>e.selected[S.repoId]),e.bulkRefresh=()=>{let S=e.selectedRepos();S.length&&confirm(`Force refresh ${S.length} repositories?`)&&S.forEach(N=>e.updateRepository(N))},e.bulkRemoveCache=()=>{let S=e.selectedRepos();S.length&&confirm(`Purge cache for ${S.length} repositories?`)&&S.forEach(N=>e.removeCache(N))},e.clearSelection=()=>{e.selected={},e.allSelected=!1},e.exportCsv=()=>{let S=new URLSearchParams(Object.entries(e.query).filter(([,N])=>N!==""&&N!==!1&&N!=null));S.set("format","csv"),S.set("limit","10000"),window.open("/api/admin/repos?"+S.toString(),"_blank")},e.removeCache=S=>{confirm("Remove cached files for "+S.repoId+"?")&&t.delete("/api/admin/repos/"+S.repoId).then(()=>h(),N=>console.error(N))},e.removeRepository=S=>{confirm("Remove repository "+S.repoId+"?")&&t.delete("/api/repo/"+S.repoId+"/").then(()=>h(),N=>console.error(N))},e.updateRepository=S=>{let N=st({title:`Refreshing ${S.repoId}...`,date:new Date,body:`The repository ${S.repoId} is going to be refreshed.`});e.toasts.push(N),t.post(`/api/repo/${S.repoId}/refresh`).then(v=>{v.data.status=="ready"?N.title=`${S.repoId} is refreshed.`:N.title=`Refreshing of ${S.repoId}.`},v=>{N.title=`Error during the refresh of ${S.repoId}.`,N.body=v.body})},e.filtersOpen=!1,e.fetchError=null;function h(){e.fetchError=null,t.get("/api/admin/repos",{params:e.query}).then(S=>{e.total=S.data.total,e.totalPage=Math.ceil(S.data.total/e.query.limit),e.repositories=S.data.results,e.allSelected=!1},S=>{e.fetchError=S&&S.data&&S.data.error||"Failed to load repositories",console.error(S)})}function w(){let S=Object.assign({},e.query,{page:1,limit:1,ready:!0,expired:!0,removed:!0,error:!0,preparing:!0});t.get("/api/admin/repos",{params:S}).then(N=>{e.statusCounts=N.data.statusCounts||[],e.totalSize=N.data.totalSize||0},()=>{})}e.showAllStatuses=()=>Object.assign(e.query,{ready:!0,expired:!0,removed:!0,error:!0,preparing:!0,page:1}),Ji(e,{flags:()=>e.query,keys:["ready","preparing","error","expired","removed"],count:S=>S==="preparing"?e.statusCountFor("preparing")+e.statusCountFor("download"):S==="expired"?e.statusCountFor("expired")+e.statusCountFor("expiring"):S==="removed"?e.statusCountFor("removed")+e.statusCountFor("removing"):e.statusCountFor(S),onChange:()=>{e.query.page=1}}),h(),w();let R=null;e.watch("query",()=>{i.timeout.cancel(R),R=i.timeout(()=>{h(),w()},500);let{page:S,search:N,...v}=e.query;saveFilterPrefs(p,v),d()},!0),d()},Fu=function(e,t,s){let i=Ct(),o=Bt();e.Math=Math,e.watch("user.status",()=>{e.user==null&&s.url("/")}),e.user==null&&s.url("/"),e.users=[],e.total=-1,e.totalPage=0,e.statusCounts=[],e.selected={},e.allSelected=!1;let r=h=>{if(h.key==="/"&&!["INPUT","TEXTAREA","SELECT"].includes(document.activeElement?.tagName)){h.preventDefault();let w=document.querySelector('.admin-filter-toolbar input[type="search"]');w&&w.focus()}};o(document,"keydown",r),e.on("dispose",()=>document.removeEventListener("keydown",r)),e.clearFilter=h=>{h==="dateRange"?(e.query.dateFrom="",e.query.dateTo=""):e.query[h]="",e.query.page=1},e.chips=[];let d=()=>{let h=[];e.query.role&&h.push({key:"role",label:"Role",value:e.query.role}),e.chips=h};e.statusCountFor=h=>{let w=(e.statusCounts||[]).find(R=>R._id===h);return w?w.count:0},e.toggleSortDirection=()=>{e.query.direction=e.query.direction==="asc"?"desc":"asc"},e.sortBy=h=>{e.query.sort===h?e.query.direction=e.query.direction==="asc"?"desc":"asc":(e.query.sort=h,e.query.direction="desc"),e.query.page=1},e.sortIcon=h=>e.query.sort===h?e.query.direction==="asc"?"fa-arrow-up":"fa-arrow-down":"";let p="admin.users.filterPrefs",u={page:1,limit:25,sort:"username",direction:"asc",search:"",status:"",role:"",dateFrom:"",dateTo:""},y=loadFilterPrefs(p)||{};e.query=Object.assign({},u,y,{page:1,search:""}),e.selectAllOnPage=()=>{e.allSelected=!e.allSelected,e.users.forEach(h=>{e.selected[h.username]=e.allSelected})},e.selectedCount=()=>Object.values(e.selected||{}).filter(Boolean).length,e.selectedUsers=()=>e.users.filter(h=>e.selected[h.username]),e.banUser=h=>{confirm(`Ban user ${h.username}?`)&&t.post(`/api/admin/users/${h.username}/ban`).then(m,w=>console.error(w))},e.activateUser=h=>{t.post(`/api/admin/users/${h.username}/activate`).then(m,w=>console.error(w))},e.bulkBan=()=>{let h=e.selectedUsers();h.length&&confirm(`Ban ${h.length} users?`)&&h.forEach(w=>e.banUser(w))},e.exportCsv=()=>{let h=new URLSearchParams(Object.entries(e.query).filter(([,w])=>w!==""&&w!==!1&&w!=null));h.set("format","csv"),h.set("limit","10000"),window.open("/api/admin/users?"+h.toString(),"_blank")},e.fetchError=null;function m(){e.fetchError=null,t.get("/api/admin/users",{params:e.query}).then(h=>{e.total=h.data.total,e.totalPage=Math.ceil(h.data.total/e.query.limit),e.users=h.data.results,e.statusCounts=h.data.statusCounts||[],e.allSelected=!1},h=>{e.fetchError=h&&h.data&&h.data.error||"Failed to load users",console.error(h)})}m();let b=null;e.watch("query",()=>{i.timeout.cancel(b),b=i.timeout(m,500);let{page:h,search:w,...R}=e.query;saveFilterPrefs(p,R),d()},!0),d()},Uu=function(e,t,s,i){let o=Ct();Gu(o,Bt()),e.watch("user.status",()=>{e.user==null&&s.url("/")}),e.user==null&&s.url("/"),e.userInfo,e.repositories=[],e.search="",e.selected={},e.allSelected=!1;let r="admin.user.filterPrefs",d={filters:{status:{ready:!0,expired:!0,removed:!0,error:!0,preparing:!0}},sort:"anonymizeDate",direction:"desc"},p=loadFilterPrefs(r)||{};e.filters={status:Object.assign({},d.filters.status,p.filters&&p.filters.status||{})},e.query={sort:p.sort||d.sort,direction:p.direction||d.direction},e.orderBy=(e.query.direction==="asc"?"":"-")+e.query.sort,e.sortBy=h=>{e.query.sort===h?e.query.direction=e.query.direction==="asc"?"desc":"asc":(e.query.sort=h,e.query.direction="desc"),e.orderBy=(e.query.direction==="asc"?"":"-")+e.query.sort},e.sortIcon=h=>e.query.sort===h?e.query.direction==="asc"?"fa-arrow-up":"fa-arrow-down":"",e.watch("query",()=>{saveFilterPrefs(r,{filters:e.filters,sort:e.query.sort,direction:e.query.direction})},!0),e.watch("filters",()=>{saveFilterPrefs(r,{filters:e.filters,sort:e.query.sort,direction:e.query.direction})},!0),e.statusCountFor=h=>(e.repositories||[]).filter(w=>Xi(w.status)===h).length,Ji(e,{flags:()=>e.filters.status,keys:["ready","preparing","error","expired","removed"],count:h=>e.statusCountFor(h)}),e.repoFiler=h=>e.filters.status[Xi(h.status)]==!1?!1:!!(e.search.trim().length==0||h.source.fullName.indexOf(e.search)>-1||h.repoId.indexOf(e.search)>-1||h.statusMessage&&h.statusMessage.indexOf(e.search)>-1||h.conference&&h.conference.indexOf(e.search)>-1),e.selectAllOnPage=()=>{e.allSelected=!e.allSelected,(e.filteredRepositories||e.repositories).forEach(h=>{e.selected[h.repoId]=e.allSelected})},e.selectedCount=()=>Object.values(e.selected||{}).filter(Boolean).length,e.selectedRepos=()=>e.repositories.filter(h=>e.selected[h.repoId]),e.bulkRefresh=()=>{let h=e.selectedRepos();h.length&&confirm(`Force refresh ${h.length} repositories?`)&&h.forEach(w=>e.updateRepository(w))},e.bulkRemoveCache=()=>{let h=e.selectedRepos();h.length&&confirm(`Purge cache for ${h.length} repositories?`)&&h.forEach(w=>e.removeCache(w))},e.clearSelection=()=>{e.selected={},e.allSelected=!1},e.exportCsv=()=>{let h=e.filteredRepositories||e.repositories,R=["repoId","status","statusMessage","pageView","anonymizeDate","source.fullName","conference","size.storage"].join(","),S=h.map(E=>[E.repoId,E.status,E.statusMessage||"",E.pageView||0,E.anonymizeDate||"",E.source&&E.source.fullName||"",E.conference||"",E.size&&E.size.storage||0].map(M=>{let V=String(M??"");return/[",\n\r]/.test(V)?'"'+V.replace(/"/g,'""')+'"':V}).join(",")),N=new Blob([R+` +`+JSON.stringify(t):""}`},[ct.NAVIGATION_GUARD_REDIRECT]({from:e,to:t}){return`Redirected from "${e.fullPath}" to "${$h(t)}" via a navigation guard.`},[ct.NAVIGATION_ABORTED]({from:e,to:t}){return`Navigation aborted from "${e.fullPath}" to "${t.fullPath}" via a navigation guard.`},[ct.NAVIGATION_CANCELLED]({from:e,to:t}){return`Navigation cancelled from "${e.fullPath}" to "${t.fullPath}" with a new navigation.`},[ct.NAVIGATION_DUPLICATED]({from:e,to:t}){return`Avoided redundant navigation to current location: "${e.fullPath}".`}};function as(e,t){return Je(new Error,{type:e,[mu]:!0},t)}function gn(e,t){return e instanceof Error&&mu in e&&(t==null||!!(e.type&t))}var Lh=["params","query","hash"];function $h(e){if(typeof e=="string")return e;if(e.path!=null)return e.path;let t={};for(let s of Lh)s in e&&(t[s]=e[s]);return JSON.stringify(t,null,2)}function hu(e){let t={};if(e===""||e==="?")return t;let s=(e[0]==="?"?e.slice(1):e).split("&");for(let i=0;io&&oa(o)):[i&&oa(i)]).forEach(o=>{o!==void 0&&(t+=(t.length?"&":"")+s,o!=null&&(t+="="+o))})}return t}function gu(e){let t={};for(let s in e){let i=e[s];i!==void 0&&(t[s]=Kt(i)?i.map(o=>o==null?null:""+o):i==null?i:""+i)}return t}var vu=Symbol(""),fa=Symbol(""),Ui=Symbol(""),Bi=Symbol(""),zi=Symbol("");function Us(){let e=[];function t(i){return e.push(i),()=>{let o=e.indexOf(i);o>-1&&e.splice(o,1)}}function s(){e=[]}return{add:t,list:()=>e.slice(),reset:s}}function Nn(e,t,s,i,o,r=d=>d()){let d=i&&(i.enterCallbacks[o]=i.enterCallbacks[o]||[]);return()=>new Promise((p,u)=>{let y=m=>{m===!1?u(as(ct.NAVIGATION_ABORTED,{from:s,to:t})):m instanceof Error?u(m):_h(m)?u(as(ct.NAVIGATION_GUARD_REDIRECT,{from:t,to:m})):(d&&i.enterCallbacks[o]===d&&typeof m=="function"&&d.push(m),p())},h=r(()=>e.call(i&&i.instances[o],t,s,y)),b=Promise.resolve(h);e.length<3&&(b=b.then(y)),b.catch(m=>u(m))})}function Hi(e,t,s,i,o=r=>r()){let r=[];for(let d of e)for(let p in d.components){let u=d.components[p];if(!(t!=="beforeRouteEnter"&&!d.instances[p]))if(xd(u)){let y=(u.__vccOpts||u)[t];y&&r.push(Nn(y,s,i,d,p,o))}else{let y=u();r.push(()=>y.then(h=>{if(!h)throw new Error(`Couldn't resolve component "${p}" at "${d.path}"`);let b=yh(h)?h.default:h;d.mods[p]=h,d.components[p]=b;let m=(b.__vccOpts||b)[t];return m&&Nn(m,s,i,d,p,o)()}))}}return r}function yu(e,t){let s=[],i=[],o=[],r=Math.max(t.matched.length,e.matched.length);for(let d=0;drs(y,p))?i.push(p):s.push(p));let u=e.matched[d];u&&(t.matched.find(y=>rs(y,u))||o.push(u))}return[s,i,o]}var Fh=()=>location.protocol+"//"+location.host;function Au(e,t){let{pathname:s,search:i,hash:o}=t,r=e.indexOf("#");if(r>-1){let d=o.includes(e.slice(r))?e.slice(r).length:1,p=o.slice(d);return p[0]!=="/"&&(p="/"+p),la(p,"")}return la(s,e)+i+o}function Uh(e,t,s,i){let o=[],r=[],d=null,p=({state:m})=>{let w=Au(e,location),N=s.value,S=t.value,R=0;if(m){if(s.value=w,t.value=m,d&&d===N){d=null;return}R=S?m.position-S.position:0}else i(w);o.forEach(v=>{v(s.value,N,{delta:R,type:$i.pop,direction:R?R>0?Fi.forward:Fi.back:Fi.unknown})})};function u(){d=s.value}function y(m){o.push(m);let w=()=>{let N=o.indexOf(m);N>-1&&o.splice(N,1)};return r.push(w),w}function h(){if(document.visibilityState==="hidden"){let{history:m}=window;if(!m.state)return;m.replaceState(Je({},m.state,{scroll:Vo()}),"")}}function b(){for(let m of r)m();r=[],window.removeEventListener("popstate",p),window.removeEventListener("pagehide",h),document.removeEventListener("visibilitychange",h)}return window.addEventListener("popstate",p),window.addEventListener("pagehide",h),document.addEventListener("visibilitychange",h),{pauseListeners:u,listen:y,destroy:b}}function bu(e,t,s,i=!1,o=!1){return{back:e,current:t,forward:s,replaced:i,position:window.history.length,scroll:o?Vo():null}}function Bh(e){let{history:t,location:s}=window,i={value:Au(e,s)},o={value:t.state};o.value||r(i.value,{back:null,current:i.value,forward:null,position:t.length-1,replaced:!0,scroll:null},!0);function r(u,y,h){let b=e.indexOf("#"),m=b>-1?(s.host&&document.querySelector("base")?e:e.slice(b))+u:Fh()+e+u;try{t[h?"replaceState":"pushState"](y,"",m),o.value=y}catch(w){console.error(w),s[h?"replace":"assign"](m)}}function d(u,y){r(u,Je({},t.state,bu(o.value.back,u,o.value.forward,!0),y,{position:o.value.position}),!0),i.value=u}function p(u,y){let h=Je({},o.value,t.state,{forward:u,scroll:Vo()});r(h.current,h,!0),r(u,Je({},bu(i.value,u,null),{position:h.position+1},y),!1),i.value=u}return{location:i,state:o,push:p,replace:d}}function Tu(e){e=du(e);let t=Bh(e),s=Uh(e,t.state,t.location,t.replace);function i(r,d=!0){d||s.pauseListeners(),history.go(r)}let o=Je({location:"",base:e,go:i,createHref:uu.bind(null,e)},t,s);return Object.defineProperty(o,"location",{enumerable:!0,get:()=>t.location.value}),Object.defineProperty(o,"state",{enumerable:!0,get:()=>t.state.value}),o}var ds=(function(e){return e[e.Static=0]="Static",e[e.Param=1]="Param",e[e.Group=2]="Group",e})({}),gt=(function(e){return e[e.Static=0]="Static",e[e.Param=1]="Param",e[e.ParamRegExp=2]="ParamRegExp",e[e.ParamRegExpEnd=3]="ParamRegExpEnd",e[e.EscapeNext=4]="EscapeNext",e})(gt||{}),zh={type:ds.Static,value:""},Hh=/[a-zA-Z0-9_]/;function jh(e){if(!e)return[[]];if(e==="/")return[[zh]];if(!e.startsWith("/"))throw new Error(`Invalid path "${e}"`);function t(w){throw new Error(`ERR (${s})/"${y}": ${w}`)}let s=gt.Static,i=s,o=[],r;function d(){r&&o.push(r),r=[]}let p=0,u,y="",h="";function b(){y&&(s===gt.Static?r.push({type:ds.Static,value:y}):s===gt.Param||s===gt.ParamRegExp||s===gt.ParamRegExpEnd?(r.length>1&&(u==="*"||u==="+")&&t(`A repeatable param (${y}) must be alone in its segment. eg: '/:ids+.`),r.push({type:ds.Param,value:y,regexp:h,repeatable:u==="*"||u==="+",optional:u==="*"||u==="?"})):t("Invalid state to consume buffer"),y="")}function m(){y+=u}for(;pt.length?t.length===1&&t[0]===At.Static+At.Segment?1:-1:0}function Ou(e,t){let s=0,i=e.score,o=t.score;for(;s0&&t[t.length-1]<0}var Xh={strict:!1,end:!0,sensitive:!1};function Jh(e,t,s){let i=Kh(jh(e.path),s),o=Je(i,{record:e,parent:t,children:[],alias:[]});return t&&!o.record.aliasOf==!t.record.aliasOf&&t.children.push(o),o}function Qh(e,t){let s=[],i=new Map;t=ra(Xh,t);function o(b){return i.get(b)}function r(b,m,w){let N=!w,S=Eu(b);S.aliasOf=w&&w.record;let R=ra(t,b),v=[S];if("alias"in b){let V=typeof b.alias=="string"?[b.alias]:b.alias;for(let _ of V)v.push(Eu(Je({},S,{components:w?w.record.components:S.components,path:_,aliasOf:w?w.record:S})))}let E,D;for(let V of v){let{path:_}=V;if(m&&_[0]!=="/"){let z=m.record.path,x=z[z.length-1]==="/"?"":"/";V.path=m.record.path+(_&&x+_)}if(E=Jh(V,m,R),w?w.alias.push(E):(D=D||E,D!==E&&D.alias.push(E),N&&b.name&&!Su(E)&&d(b.name)),Iu(E)&&u(E),S.children){let z=S.children;for(let x=0;x{d(D)}:Fs}function d(b){if(ca(b)){let m=i.get(b);m&&(i.delete(b),s.splice(s.indexOf(m),1),m.children.forEach(d),m.alias.forEach(d))}else{let m=s.indexOf(b);m>-1&&(s.splice(m,1),b.record.name&&i.delete(b.record.name),b.children.forEach(d),b.alias.forEach(d))}}function p(){return s}function u(b){let m=eg(b,s);s.splice(m,0,b),b.record.name&&!Su(b)&&i.set(b.record.name,b)}function y(b,m){let w,N={},S,R;if("name"in b&&b.name){if(w=i.get(b.name),!w)throw as(ct.MATCHER_NOT_FOUND,{location:b});R=w.record.name,N=Je(Cu(m.params,w.keys.filter(D=>!D.optional).concat(w.parent?w.parent.keys.filter(D=>D.optional):[]).map(D=>D.name)),b.params&&Cu(b.params,w.keys.map(D=>D.name))),S=w.stringify(N)}else if(b.path!=null)S=b.path,w=s.find(D=>D.re.test(S)),w&&(N=w.parse(S),R=w.record.name);else{if(w=m.name?i.get(m.name):s.find(D=>D.re.test(m.path)),!w)throw as(ct.MATCHER_NOT_FOUND,{location:b,currentLocation:m});R=w.record.name,N=Je({},m.params,b.params),S=w.stringify(N)}let v=[],E=w;for(;E;)v.unshift(E.record),E=E.parent;return{name:R,path:S,params:N,matched:v,meta:xh(v)}}e.forEach(b=>r(b));function h(){s.length=0,i.clear()}return{addRoute:r,resolve:y,removeRoute:d,clearRoutes:h,getRoutes:p,getRecordMatcher:o}}function Cu(e,t){let s={};for(let i of t)i in e&&(s[i]=e[i]);return s}function Eu(e){let t={path:e.path,redirect:e.redirect,name:e.name,meta:e.meta||{},aliasOf:e.aliasOf,beforeEnter:e.beforeEnter,props:Zh(e),children:e.children||[],instances:{},leaveGuards:new Set,updateGuards:new Set,enterCallbacks:{},components:"components"in e?e.components||null:e.component&&{default:e.component}};return Object.defineProperty(t,"mods",{value:{}}),t}function Zh(e){let t={},s=e.props||!1;if("component"in e)t.default=s;else for(let i in e.components)t[i]=typeof s=="object"?s[i]:s;return t}function Su(e){for(;e;){if(e.record.aliasOf)return!0;e=e.parent}return!1}function xh(e){return e.reduce((t,s)=>Je(t,s.meta),{})}function eg(e,t){let s=0,i=t.length;for(;s!==i;){let r=s+i>>1;Ou(e,t[r])<0?i=r:s=r+1}let o=tg(e);return o&&(i=t.lastIndexOf(o,i-1)),i}function tg(e){let t=e;for(;t=t.parent;)if(Iu(t)&&Ou(e,t)===0)return t}function Iu({record:e}){return!!(e.name||e.components&&Object.keys(e.components).length||e.redirect)}function Nu(e){let t=Mt(Ui),s=Mt(Bi),i=!1,o=null,r=Rt(()=>{let h=kn(e.to);return t.resolve(h)}),d=Rt(()=>{let{matched:h}=r.value,{length:b}=h,m=h[b-1],w=s.matched;if(!m||!w.length)return-1;let N=w.findIndex(rs.bind(null,m));if(N>-1)return N;let S=Ru(h[b-2]);return b>1&&Ru(m)===S&&w[w.length-1].path!==S?w.findIndex(rs.bind(null,h[b-2])):N}),p=Rt(()=>d.value>-1&&rg(s.params,r.value.params)),u=Rt(()=>d.value>-1&&d.value===s.matched.length-1&&da(s.params,r.value.params));function y(h={}){if(ig(h)){let b=t[kn(e.replace)?"replace":"push"](kn(e.to)).catch(Fs);return e.viewTransition&&typeof document<"u"&&"startViewTransition"in document&&document.startViewTransition(()=>b),b}return Promise.resolve()}return{route:r,href:Rt(()=>r.value.href),isActive:p,isExactActive:u,navigate:y}}function ng(e){return e.length===1?e[0]:e}var sg=Do({name:"RouterLink",compatConfig:{MODE:3},props:{to:{type:[String,Object],required:!0},replace:Boolean,activeClass:String,exactActiveClass:String,custom:Boolean,ariaCurrentValue:{type:String,default:"page"},viewTransition:Boolean},useLink:Nu,setup(e,{slots:t}){let s=st(Nu(e)),{options:i}=Mt(Ui),o=Rt(()=>({[Pu(e.activeClass,i.linkActiveClass,"router-link-active")]:s.isActive,[Pu(e.exactActiveClass,i.linkExactActiveClass,"router-link-exact-active")]:s.isExactActive}));return()=>{let r=t.default&&ng(t.default(s));return e.custom?r:Ae("a",{"aria-current":s.isExactActive?e.ariaCurrentValue:null,href:s.href,onClick:s.navigate,class:o.value},r)}}}),og=sg;function ig(e){if(!(e.metaKey||e.altKey||e.ctrlKey||e.shiftKey)&&!e.defaultPrevented&&!(e.button!==void 0&&e.button!==0)){if(e.currentTarget&&e.currentTarget.getAttribute){let t=e.currentTarget.getAttribute("target");if(/\b_blank\b/i.test(t))return}return e.preventDefault&&e.preventDefault(),!0}}function rg(e,t){for(let s in t){let i=t[s],o=e[s];if(typeof i=="string"){if(i!==o)return!1}else if(!Kt(o)||o.length!==i.length||i.some((r,d)=>r.valueOf()!==o[d].valueOf()))return!1}return!0}function Ru(e){return e?e.aliasOf?e.aliasOf.path:e.path:""}var Pu=(e,t,s)=>e??t??s,ag=Do({name:"RouterView",inheritAttrs:!1,props:{name:{type:String,default:"default"},route:Object},compatConfig:{MODE:3},setup(e,{attrs:t,slots:s}){let i=Mt(zi),o=Rt(()=>e.route||i.value),r=Mt(fa,0),d=Rt(()=>{let y=kn(r),{matched:h}=o.value,b;for(;(b=h[y])&&!b.components;)y++;return y}),p=Rt(()=>o.value.matched[d.value]);os(fa,Rt(()=>d.value+1)),os(vu,p),os(zi,o);let u=St();return ut(()=>[u.value,p.value,e.name],([y,h,b],[m,w,N])=>{h&&(h.instances[b]=y,w&&w!==h&&y&&y===m&&(h.leaveGuards.size||(h.leaveGuards=w.leaveGuards),h.updateGuards.size||(h.updateGuards=w.updateGuards))),y&&h&&(!w||!rs(h,w)||!m)&&(h.enterCallbacks[b]||[]).forEach(S=>S(y))},{flush:"post"}),()=>{let y=o.value,h=e.name,b=p.value,m=b&&b.components[h];if(!m)return Du(s.default,{Component:m,route:y});let w=b.props[h],N=w?w===!0?y.params:typeof w=="function"?w(y):w:null,R=Ae(m,Je({},N,t,{onVnodeUnmounted:v=>{v.component.isUnmounted&&(b.instances[h]=null)},ref:u}));return Du(s.default,{Component:R,route:y})||R}}});function Du(e,t){if(!e)return null;let s=e(t);return s.length===1?s[0]:s}var ma=ag;function Mu(e){let t=Qh(e.routes,e),s=e.parseQuery||hu,i=e.stringifyQuery||pa,o=e.history,r=Us(),d=Us(),p=Us(),u=gi(Rn),y=Rn;ls&&e.scrollBehavior&&"scrollRestoration"in history&&(history.scrollRestoration="manual");let h=_i.bind(null,W=>""+W),b=_i.bind(null,ru),m=_i.bind(null,$s);function w(W,fe){let de,ce;return ca(W)?(de=t.getRecordMatcher(W),ce=fe):ce=W,t.addRoute(ce,de)}function N(W){let fe=t.getRecordMatcher(W);fe&&t.removeRoute(fe)}function S(){return t.getRoutes().map(W=>W.record)}function R(W){return!!t.getRecordMatcher(W)}function v(W,fe){if(fe=Je({},fe||u.value),typeof W=="string"){let O=Li(s,W,fe.path),F=t.resolve({path:O.path},fe),J=o.createHref(O.fullPath);return Je(O,F,{params:m(F.params),hash:$s(O.hash),redirectedFrom:void 0,href:J})}let de;if(W.path!=null)de=Je({},W,{path:Li(s,W.path,fe.path).path});else{let O=Je({},W.params);for(let F in O)O[F]==null&&delete O[F];de=Je({},W,{params:b(O)}),fe.params=b(fe.params)}let ce=t.resolve(de,fe),ve=W.hash||"";ce.params=h(m(ce.params));let Me=au(i,Je({},W,{hash:iu(ve),path:ce.path})),A=o.createHref(Me);return Je({fullPath:Me,hash:ve,query:i===pa?gu(W.query):W.query||{}},ce,{redirectedFrom:void 0,href:A})}function E(W){return typeof W=="string"?Li(s,W,u.value.path):Je({},W)}function D(W,fe){if(y!==W)return as(ct.NAVIGATION_CANCELLED,{from:fe,to:W})}function V(W){return x(W)}function _(W){return V(Je(E(W),{replace:!0}))}function z(W,fe){let de=W.matched[W.matched.length-1];if(de&&de.redirect){let{redirect:ce}=de,ve=typeof ce=="function"?ce(W,fe):ce;return typeof ve=="string"&&(ve=ve.includes("?")||ve.includes("#")?ve=E(ve):{path:ve},ve.params={}),Je({query:W.query,hash:W.hash,params:ve.path!=null?{}:W.params},ve)}}function x(W,fe){let de=y=v(W),ce=u.value,ve=W.state,Me=W.force,A=W.replace===!0,O=z(de,ce);if(O)return x(Je(E(O),{state:typeof O=="object"?Je({},ve,O.state):ve,force:Me,replace:A}),fe||de);let F=de;F.redirectedFrom=fe;let J;return!Me&&lu(i,ce,de)&&(J=as(ct.NAVIGATION_DUPLICATED,{to:F,from:ce}),Be(ce,ce,!0,!1)),(J?Promise.resolve(J):U(F,ce)).catch(j=>gn(j)?gn(j,ct.NAVIGATION_GUARD_REDIRECT)?j:Ue(j):me(j,F,ce)).then(j=>{if(j){if(gn(j,ct.NAVIGATION_GUARD_REDIRECT))return x(Je({replace:A},E(j.to),{state:typeof j.to=="object"?Je({},ve,j.to.state):ve,force:Me}),fe||F)}else j=L(F,ce,!0,A,ve);return C(F,ce,j),j})}function X(W,fe){let de=D(W,fe);return de?Promise.reject(de):Promise.resolve()}function I(W){let fe=et.values().next().value;return fe&&typeof fe.runWithContext=="function"?fe.runWithContext(W):W()}function U(W,fe){let de,[ce,ve,Me]=yu(W,fe);de=Hi(ce.reverse(),"beforeRouteLeave",W,fe);for(let O of ce)O.leaveGuards.forEach(F=>{de.push(Nn(F,W,fe))});let A=X.bind(null,W,fe);return de.push(A),Fe(de).then(()=>{de=[];for(let O of r.list())de.push(Nn(O,W,fe));return de.push(A),Fe(de)}).then(()=>{de=Hi(ve,"beforeRouteUpdate",W,fe);for(let O of ve)O.updateGuards.forEach(F=>{de.push(Nn(F,W,fe))});return de.push(A),Fe(de)}).then(()=>{de=[];for(let O of Me)if(O.beforeEnter)if(Kt(O.beforeEnter))for(let F of O.beforeEnter)de.push(Nn(F,W,fe));else de.push(Nn(O.beforeEnter,W,fe));return de.push(A),Fe(de)}).then(()=>(W.matched.forEach(O=>O.enterCallbacks={}),de=Hi(Me,"beforeRouteEnter",W,fe,I),de.push(A),Fe(de))).then(()=>{de=[];for(let O of d.list())de.push(Nn(O,W,fe));return de.push(A),Fe(de)}).catch(O=>gn(O,ct.NAVIGATION_CANCELLED)?O:Promise.reject(O))}function C(W,fe,de){p.list().forEach(ce=>I(()=>ce(W,fe,de)))}function L(W,fe,de,ce,ve){let Me=D(W,fe);if(Me)return Me;let A=fe===Rn,O=ls?history.state:{};de&&(ce||A?o.replace(W.fullPath,Je({scroll:A&&O&&O.scroll},ve)):o.push(W.fullPath,ve)),u.value=W,Be(W,fe,de,A),Ue()}let H;function K(){H||(H=o.listen((W,fe,de)=>{if(!Re.listening)return;let ce=v(W),ve=z(ce,Re.currentRoute.value);if(ve){x(Je(ve,{replace:!0,force:!0}),ce).catch(Fs);return}y=ce;let Me=u.value;ls&&pu(ua(Me.fullPath,de.delta),Vo()),U(ce,Me).catch(A=>gn(A,ct.NAVIGATION_ABORTED|ct.NAVIGATION_CANCELLED)?A:gn(A,ct.NAVIGATION_GUARD_REDIRECT)?(x(Je(E(A.to),{force:!0}),ce).then(O=>{gn(O,ct.NAVIGATION_ABORTED|ct.NAVIGATION_DUPLICATED)&&!de.delta&&de.type===$i.pop&&o.go(-1,!1)}).catch(Fs),Promise.reject()):(de.delta&&o.go(-de.delta,!1),me(A,ce,Me))).then(A=>{A=A||L(ce,Me,!1),A&&(de.delta&&!gn(A,ct.NAVIGATION_CANCELLED)?o.go(-de.delta,!1):de.type===$i.pop&&gn(A,ct.NAVIGATION_ABORTED|ct.NAVIGATION_DUPLICATED)&&o.go(-1,!1)),C(ce,Me,A)}).catch(Fs)}))}let ie=Us(),se=Us(),Y;function me(W,fe,de){Ue(W);let ce=se.list();return ce.length?ce.forEach(ve=>ve(W,fe,de)):console.error(W),Promise.reject(W)}function Se(){return Y&&u.value!==Rn?Promise.resolve():new Promise((W,fe)=>{ie.add([W,fe])})}function Ue(W){return Y||(Y=!W,K(),ie.list().forEach(([fe,de])=>W?de(W):fe()),ie.reset()),W}function Be(W,fe,de,ce){let{scrollBehavior:ve}=e;if(!ls||!ve)return Promise.resolve();let Me=!de&&fu(ua(W.fullPath,0))||(ce||!de)&&history.state&&history.state.scroll||null;return tt().then(()=>ve(W,fe,Me)).then(A=>A&&cu(A)).catch(A=>me(A,W,fe))}let Qe=W=>o.go(W),He,et=new Set,Re={currentRoute:u,listening:!0,addRoute:w,removeRoute:N,clearRoutes:t.clearRoutes,hasRoute:R,getRoutes:S,resolve:v,options:e,push:V,replace:_,go:Qe,back:()=>Qe(-1),forward:()=>Qe(1),beforeEach:r.add,beforeResolve:d.add,afterEach:p.add,onError:se.add,isReady:Se,install(W){W.component("RouterLink",og),W.component("RouterView",ma),W.config.globalProperties.$router=Re,Object.defineProperty(W.config.globalProperties,"$route",{enumerable:!0,get:()=>kn(u)}),ls&&!He&&u.value===Rn&&(He=!0,V(o.location).catch(ce=>{}));let fe={};for(let ce in Rn)Object.defineProperty(fe,ce,{get:()=>u.value[ce],enumerable:!0});W.provide(Ui,Re),W.provide(Bi,fo(fe)),W.provide(zi,u);let de=W.unmount;et.add(W),W.unmount=function(){et.delete(W),et.size<1&&(y=Rn,H&&H(),H=null,u.value=Rn,He=!1,Y=!1),de()}}};function Fe(W){return W.reduce((fe,de)=>fe.then(()=>I(de)),Promise.resolve())}return Re}function Vu(e){return Mt(Bi)}function Gi(e){return["author_pass","repo_extend","repo_never","repo_slot","repo_pack"].includes(e)}var ji=new WeakMap;function Wi(e){if(!ji.has(e)){let t=e.get("/api/billing/").finally(()=>ji.delete(e));ji.set(e,t)}return ji.get(e)}function Ki(e,t,s=()=>{},i={}){let o=new URLSearchParams(window.location.search).get("billing");e.billing=null,e.billingLoading=!0,e.billingBusy=!1,e.billingError="",e.billingNotice="",e.billingPending=o==="success",e.billingRepository="";let r={billing_invalid_draft:"This draft could not be saved. Your form is unchanged. Try again.",billing_draft_not_found:"This checkout draft is unavailable or expired. Your local form is unchanged.",billing_recovery_required:"Your earlier payment needs verification. Please contact support before paying again.",billing_checkout_disabled:"New purchases are temporarily unavailable. You can still manage existing billing.",billing_unavailable:"Payments are not available yet. Please try again later.",billing_subscription_exists:"You already have a subscription. Use Manage billing to change or cancel it.",billing_checkout_in_progress:"You have another checkout open. Complete it, or wait up to 30 minutes for it to expire, before choosing a different option.",billing_busy:"Another billing request is processing. Please try again shortly.",billing_already_paid:"This repository or conference already has this paid option.",billing_invalid_review_window:"Conference packages cover up to 180 days. Check the review dates.",billing_invalid_conference:"Only a conference owner can pay for a conference awaiting payment.",repo_not_found:"Enter the ID of an existing repository that you own."};e.billingAmount=u=>u?.amount==null?"":new Intl.NumberFormat(void 0,{style:"currency",currency:u.currency,minimumFractionDigits:u.amount%100?2:0,maximumFractionDigits:2}).format(u.amount/100),e.billingPrice=u=>u.amount==null?"Price shown at checkout":e.billingAmount(u)+(u.interval?` / ${u.intervalCount>1?u.intervalCount+" ":""}${u.interval}`:" once"),e.billingPerMonth=u=>u?.amount==null?"":new Intl.NumberFormat(void 0,{style:"currency",currency:u.currency}).format(u.amount/1200),e.billingBytes=u=>{let y=Number(u)||0;if(y<1024)return`${y} B`;let h=Math.min(4,Math.floor(Math.log2(y)/10));return`${new Intl.NumberFormat(void 0,{maximumFractionDigits:1}).format(y/1024**h)} ${["B","KB","MB","GB","TB"][h]}`},e.billingDate=u=>u?new Date(u).toLocaleDateString(void 0,{year:"numeric",month:"short",day:"numeric"}):"",e.loadBilling=()=>(e.billingError="",e.billingLoading=!0,Wi(t).then(u=>{e.billing=u.data,e.emit?.("billing:updated",u.data)}).catch(()=>{e.billingError="Billing could not be loaded. Try again."}).finally(()=>{e.billingLoading=!1}));async function d(u,y,h=!0){if(!(e.billingBusy||!e.billing?.csrf)){e.billingBusy=!0,e.billingError="";try{let b=await t.post(`/api/billing/${u}`,y,{headers:{"x-csrf-token":e.billing.csrf}});if(h)window.location.assign(b.data.url);else return await e.loadBilling(),await s(),e.billingPending=!!b.data.pending,e.emit?.("billing:pending",e.billingPending),e.billingNotice=b.data.pending?"Your payment is still pending. Please do not pay again.":i.confirmedMessage||"Billing status refreshed. Your confirmed access appears below.",b.data}catch(b){e.billingError=r[b.data?.error]||"The billing request failed. Please try again."}finally{e.billingBusy=!1}}}e.checkout=(u,y="",h={})=>d("checkout",{planId:u,target:y,...h}),e.billingPortal=()=>d("portal",{}),e.refreshBilling=()=>d("refresh",{},!1);async function p(){for(let u=0;u<5;u++){let y=await e.refreshBilling();if(!y||!y.pending)return;await new Promise(h=>window.setTimeout(h,3e3))}e.billingNotice="Confirmation is taking longer than usual. You can refresh payment status later. Please do not pay again."}e.loadBilling().then(()=>{o==="success"?(e.billingNotice="Checking your payment. Paid access starts after confirmation.",p()):o==="portal"?e.refreshBilling().then(()=>{e.billingPending=!1,e.emit?.("billing:pending",!1),e.billingNotice=i.portalMessage?.(e.billing)||"Your billing details are up to date."}):o==="cancelled"&&(e.billingNotice="Checkout was closed. No new paid access has been activated.")})}function qu(e,t){return t?.split(".").reduce((s,i)=>s?.[i],e)}function qo(e=null,t=new Map){let s=st({}),i=[],o=!1,r=new Proxy(s,{get(d,p){return typeof p=="string"&&p.startsWith("__v_")||Reflect.has(d,p)?Reflect.get(d,p):e?.[p]}});return Object.defineProperty(s,"parent",{value:e,configurable:!0}),Object.defineProperty(s,"viewState",{get:()=>r}),r.watch=(d,p,u=!1,y=!0)=>{let h=typeof d=="function"?()=>d(r):()=>qu(r,d),b=ut(h,p,{deep:u,flush:"post"});return i.push(b),y&&tt(()=>{o||p(h(),h())}),b},r.watchGroup=(d,p,u=!0)=>r.watch(()=>d.map(y=>qu(r,y)),p,!0,u),r.on=(d,p)=>{if(d==="dispose")return i.push(p),()=>{};t.has(d)||t.set(d,new Set),t.get(d).add(p);let u=()=>t.get(d)?.delete(p);return i.push(u),u},r.emit=(d,...p)=>{for(let u of[...t.get(d)||[]])u({},...p)},r.dispose=()=>{o=!0,i.splice(0).reverse().forEach(d=>d())},es(r.dispose),r}function Ct(){let e=new Set,t=new Set,s=!1,i=(r,d=0)=>{if(s)return;let p=setTimeout(()=>{e.delete(p),r()},d);return e.add(p),p};i.cancel=r=>{clearTimeout(r),e.delete(r)};let o=(r,d)=>{if(s)return;let p=setInterval(r,d);return t.add(p),p};return o.cancel=r=>{clearInterval(r),t.delete(r)},es(()=>{s=!0,e.forEach(clearTimeout),t.forEach(clearInterval)}),{timeout:i,interval:o}}function Ut(){let e=new Set;return es(()=>{e.forEach(t=>t()),e.clear()}),(t,s,i,o)=>{t.addEventListener(s,i,o);let r=()=>{t.removeEventListener(s,i,o),e.delete(r)};return e.add(r),r}}var ha=function(e,t=e){let s=/\bXXXX-\d+\b/g;t.on("dark-mode",(I,U)=>{e.aceOption&&(e.aceOption.theme=U?"nord_dark":"chrome")});let i=Ct(),o=Ut();e.isMac=/Mac|iPhone|iPad|iPod/.test(navigator.platform||navigator.userAgent);let r={yml:"yaml",txt:"text",py:"python",js:"javascript",ts:"typescript"},d=["license","txt"],p=["png","jpg","jpeg","gif","svg","ico","bmp","tiff","tif","webp","avif","heif","heic"],u=["wav","mp3","ogg","wma","flac","aac","m4a"],y=["mp4","avi","webm","mov","mpg","mpeg","mkv","flv","wmv","3gp","3g2","m4v","f4v","f4p","f4a","f4b"];e.toggleSource=function(){e.showSource=!e.showSource},e.toggleAllowScripts=function(){e.allowScripts=!e.allowScripts};let h=(()=>{try{return window.localStorage?.getItem("wrapLines")}catch{return null}})();e.wrapLines=(h??(window.matchMedia?.("(max-width: 767px)").matches?"false":"true"))!=="false",e.toggleWrap=function(){e.wrapLines=!e.wrapLines;try{window.localStorage?.setItem("wrapLines",String(e.wrapLines))}catch{}e.codeEditor?.session.setUseWrapMode(e.wrapLines)};function b(){return window.document.querySelector(".reading-layout .markdown-body")}function m(){let I=b();I&&(I.querySelectorAll("mark.md-find").forEach(U=>{U.replaceWith(window.document.createTextNode(U.textContent))}),I.normalize())}e.runMdFind=function(){m(),e.mdFindTotal=0,e.mdFindIndex=0;let I=(e.mdFindQuery||"").trim(),U=b();if(!I||!U)return;let C=!!e.mdFindCase,L=C?I:I.toLowerCase(),H=window.document.createTreeWalker(U,4),K=[];for(;H.nextNode();)(C?H.currentNode.nodeValue:H.currentNode.nodeValue.toLowerCase()).includes(L)&&K.push(H.currentNode);let ie=0;for(let se of K){let Y=se.nodeValue,me=C?Y:Y.toLowerCase(),Se=window.document.createDocumentFragment(),Ue=0,Be;for(;(Be=me.indexOf(L,Ue))!==-1;){Se.appendChild(window.document.createTextNode(Y.slice(Ue,Be)));let Qe=window.document.createElement("mark");Qe.className="md-find",Qe.textContent=Y.slice(Be,Be+I.length),Se.appendChild(Qe),ie++,Ue=Be+I.length}Se.appendChild(window.document.createTextNode(Y.slice(Ue))),se.parentNode.replaceChild(Se,se)}e.mdFindTotal=ie,ie&&e.stepMdFind(0)},e.stepMdFind=function(I){let U=b();if(!U||!e.mdFindTotal)return;let C=U.querySelectorAll("mark.md-find");e.mdFindIndex=(e.mdFindIndex+I+C.length)%C.length,C.forEach((L,H)=>L.classList.toggle("is-current",H===e.mdFindIndex)),C[e.mdFindIndex]?.scrollIntoView({block:"center",behavior:"smooth"})},e.toggleMdFind=function(I){if(e.mdFindOpen=I===void 0?!e.mdFindOpen:I,!e.mdFindOpen){m(),e.mdFindTotal=0;return}tt(()=>window.document.querySelector(".md-find-input")?.focus())},e.findInFile=function(){let I=e.codeEditor;if(!I)return;I.focus(),I.execCommand("find");let U=()=>{let C=I.searchBox?.element;C&&(I.renderer.setScrollMargin(52,12,0,0),!C._dockObserver&&(C._dockObserver=new MutationObserver(()=>{I.renderer.setScrollMargin(C.style.display!=="none"?52:12,12,0,0)}),C._dockObserver.observe(C,{attributes:!0,attributeFilter:["style"]})))};U(),setTimeout(U,150)};let w=[[/^\s*(?:export\s+)?(?:default\s+)?(?:abstract\s+)?class\s+([A-Za-z_$][\w$]*)/,"class"],[/^\s*(?:export\s+)?(?:default\s+)?(?:async\s+)?function\s*\*?\s*([A-Za-z_$][\w$]*)/,"function"],[/^\s*(?:export\s+)?(?:const|let|var)\s+([A-Za-z_$][\w$]*)\s*=\s*(?:async\s*)?(?:function|\([^)]*\)\s*=>|[A-Za-z_$][\w$]*\s*=>)/,"function"],[/^\s*(?:async\s+)?def\s+([A-Za-z_]\w*)/,"function"],[/^\s*class\s+([A-Za-z_]\w*)/,"class"],[/^\s*func\s+(?:\([^)]*\)\s*)?([A-Za-z_]\w*)/,"function"],[/^\s*(?:pub\s+)?fn\s+([A-Za-z_]\w*)/,"function"],[/^\s*(?:public|private|protected|static|\s)+[\w<>\[\],\s]+\s+([A-Za-z_]\w*)\s*\([^;]*\)\s*\{?\s*$/,"function"]],N={content:null,list:[]};e.symbolsOpen=!1,e.symbols=function(){if(typeof e.content!="string"||e.content.length>2e6)return[];if(N.content===e.content)return N.list;let I=[];return e.content.split(` +`).forEach((U,C)=>{for(let[L,H]of w){let K=L.exec(U);if(K&&!/^(if|for|while|switch|return|catch)$/.test(K[1])){I.push({name:K[1],kind:H,line:C+1});break}}}),N={content:e.content,list:I.slice(0,300)},N.list},e.goToSymbol=function(I){e.symbolsOpen=!1;let U=e.codeEditor;U&&(U.scrollToLine(I-1,!0,!0,()=>{}),U.gotoLine(I,0,!0),window.history.replaceState(null,"",window.location.pathname+window.location.search+"#L"+I),window.dispatchEvent(new HashChangeEvent("hashchange")))},e.gotoLine=function(){e.codeEditor&&(e.moreOpen=!1,e.gotoError="",e.gotoValue=String(e.codeEditor.getCursorPosition().row+1),e.gotoOpen=!0,setTimeout(()=>{let I=window.document.getElementById("goto-input");I&&(I.focus(),I.select())},0))},e.closeGoto=function(){e.gotoOpen=!1,e.gotoError="",e.codeEditor?.focus()},e.submitGoto=function(){let I=e.codeEditor;if(!I)return;let U=/^\s*:?\s*(\d+)\s*(?:[:,]\s*(\d+))?\s*$/.exec(e.gotoValue||""),C=I.session.getLength();if(!U||+U[1]<1||+U[1]>C){e.gotoError="Enter a line from 1 to "+C;return}I.gotoLine(+U[1],U[2]?Math.max(0,+U[2]-1):0,!0),e.gotoOpen=!1,e.gotoError="",I.focus()},e.rootEntries=function(){return[...e.files||[]].sort((I,U)=>{let C=I.size==null,L=U.size==null;return C!==L?C?-1:1:I.name.localeCompare(U.name)})},e.formatSize=function(I){if(I==null)return"";if(I<1024)return I+" B";let U=I/1024,C=L=>L.toFixed(1).replace(/\.0$/,"");return U<1024?C(U)+" KB":U<1024*1024?C(U/1024)+" MB":C(U/1024/1024)+" GB"},e.fileSize=function(I){if(!I)return null;let U=I.replace(/^\/+/,""),C=(e.files||[]).find(L=>(L.path?L.path+"/":"")+L.name===U);return C&&C.size!=null?C.size:null},e.revealFolder=function(I){e.sidebarHidden=!1,e.sidebarCollapsed=!1,tt(()=>{let U=window.document.querySelector('.files a[data-path="/'+(window.CSS?.escape?window.CSS.escape(I):I)+'"]');U&&(U.closest("li")?.classList.contains("open")||U.click(),U.scrollIntoView({block:"nearest"}),U.focus())})};let S={content:null,n:0},R=I=>{if(S.content===I)return S.n;let U=I;if(typeof U=="string")try{U=JSON.parse(U)}catch{U=null}let C=[],L=K=>{Array.isArray(K)?C.push(K.join("")):typeof K=="string"&&C.push(K)};(U&&(U.cells||(U.worksheets||[]).flatMap(K=>K.cells||[]))||[]).forEach(K=>{L(K?.source??K?.input),(K?.outputs||[]).forEach(ie=>{L(ie?.text),ie?.data&&(L(ie.data["text/plain"]),L(ie.data["text/markdown"]),L(ie.data["text/html"])),L(ie?.traceback)})});let H=C.reduce((K,ie)=>K+(ie.match(s)||[]).length,0);return S={content:I,n:H},H};e.redactionCount=function(){return e.type==="IPython"?R(e.content):typeof e.content!="string"?0:((e.type==="html"?e.content.replace(/<[^>]*>/g," "):e.content).match(s)||[]).length},e.renderRedacted=_o;let v=I=>I.toLowerCase().trim().replace(/[^a-z0-9\s-]/g,"").replace(/\s+/g,"-").slice(0,60)||"section";e.renderReadme=function(I){let U=e.renderRedacted(I);if(!U||typeof window.DOMParser!="function")return U;let C=new window.DOMParser().parseFromString("
"+U+"
","text/html"),L={};return C.querySelectorAll("h1, h2, h3").forEach(H=>{let K=H.id||v(H.textContent);L[K]?K+="-"+ ++L[K]:L[K]=1,H.id=K}),C.body.firstChild.innerHTML};let E={content:null,list:[]};e.readmeToc=function(){if(e.type!=="html"||typeof e.content!="string")return[];if(E.content===e.content)return E.list;let U=[...new window.DOMParser().parseFromString("
"+e.renderReadme(e.sanitize?e.sanitize(e.content):e.content)+"
","text/html").querySelectorAll("h2, h3")].map(C=>({id:C.id,text:C.textContent.trim(),level:C.tagName==="H3"?3:2})).slice(0,40);return E={content:e.content,list:U},U},e.activeHeading=null,o(window,"scroll",()=>{let I=e.readmeToc?e.readmeToc():[];if(!I.length)return;let U=150,C="",L="";for(let H of I){let K=window.document.getElementById(H.id);if(!K)continue;let ie=K.getBoundingClientRect().top;ie{let C=[],L=[],H="",K=!1;for(let ie=0;ieie.length>1||ie[0]!=="")};e.isCsv=()=>typeof e.content=="string"&&e.type!=="html"&&/\.(csv|tsv)$/i.test(e.filePath||"")&&e.content.length<=1024*1024,e.csvRows=()=>{if(D.content!==e.content){let I=/\.tsv$/i.test(e.filePath||"")?" ":",";D={content:e.content,rows:V(e.content,I)}}return D.rows},e.csvNumCol=I=>{let U=e.csvRows().slice(1).map(C=>C[I]).filter(C=>C!=null&&String(C).trim()!=="");return U.length>0&&U.every(C=>e.csvNumeric(C))},e.csvNumeric=I=>/^\s*[-+]?(\d[\d,]*)?(\.\d+)?(e[-+]?\d+)?%?\s*$/i.test(I)&&/\d/.test(I),e.redactParts=function(I){let U=[],C=0,L,H=/\bXXXX-(\d+)\b/g;for(I=String(I||"");L=H.exec(I);)L.index>C&&U.push({t:I.slice(C,L.index)}),U.push({n:L[1]}),C=L.index+L[0].length;return C{e.pathCopied=!1},1600))},e.contentCopied=!1,e.copyContent=async function(){if(typeof e.content!="string"||!window.navigator.clipboard?.writeText)return;let I=e.content;if(e.type==="html"&&e.url)if(e.preview)I=e.sourceContent;else try{I=await(await window.fetch(e.url,{credentials:"same-origin"})).text()}catch{return}await window.navigator.clipboard.writeText(I),e.contentCopied=!0,setTimeout(()=>{e.contentCopied=!1},1600)};function _(I){return r[I]?r[I]:I}function z(I){return I=="pdf"?"pdf":I=="html"||I=="htm"?"html-doc":["md","markdown","mdown","mkdn","mdx"].includes(I)?"md":I=="org"?"org":I=="ipynb"?"IPython":d.indexOf(I)>-1?"text":p.indexOf(I)>-1?"image":y.indexOf(I)>-1?"media":u.indexOf(I)>-1?"audio":"code"}e.downloadUrl=()=>e.preview?e.url:e.url+"&download=true",e.prepareFile=function(I){e.showSource=!1,e.allowScripts=!1,e.imageSize="",e.filePath=I,e.paths=I.split("/").filter(Boolean);let U=e.filePath.toLowerCase(),C=U.lastIndexOf(".");C>-1&&(U=U.substring(C+1));let L={javascript:"JavaScript",typescript:"TypeScript",tsx:"TSX",jsx:"JSX",python:"Python",java:"Java",c_cpp:"C/C++",csharp:"C#",golang:"Go",rust:"Rust",ruby:"Ruby",php:"PHP",html:"HTML",css:"CSS",scss:"SCSS",json:"JSON",yaml:"YAML",markdown:"Markdown",sh:"Shell",dockerfile:"Dockerfile",xml:"XML",sql:"SQL",kotlin:"Kotlin",swift:"Swift",scala:"Scala",r:"R",julia:"Julia",latex:"LaTeX",toml:"TOML",csv:"CSV",tsv:"TSV",text:""},H=_(U);e.languageName=L[H]??(H?H.charAt(0).toUpperCase()+H.slice(1):""),e.aceOption={readOnly:!0,useWrapMode:!0,showGutter:!0,theme:"chrome",useSoftTab:!0,tabSize:2,fontSize:window.matchMedia?.("(max-width: 767px)").matches?12:13,keyBinding:"vscode",fullLineSelection:!0,highlightActiveLine:!1,highlightGutterLine:!1,cursor:"hide",showInvisibles:!1,showIndentGuides:!1,showPrintMargin:!1,highlightSelectedWord:!1,enableBehaviours:!0,fadeFoldWidgets:!1,mode:_(U),onLoad:function(K){e.codeEditor=un(K);{let Re=K.session,Fe=Re.getTokens.bind(Re),W=/\bXXXX-\d+\b/g;if(Re.getTokens=function(fe){let de=Fe(fe);if(!de.some(ve=>ve.value.indexOf("XXXX-")!==-1))return de;let ce=[];for(let ve of de){if(ve.value.indexOf("XXXX-")===-1){ce.push(ve);continue}let Me=0;W.lastIndex=0;let A;for(;A=W.exec(ve.value);)A.index>Me&&ce.push({type:ve.type,value:ve.value.slice(Me,A.index)}),ce.push({type:"redacted.n"+A[0].slice(5),value:A[0]}),Me=A.index+A[0].length;Me`.ace_redacted.ace_n${ce+1}::after{content:"${ce+1}"}`).join(""),window.document.head.appendChild(fe)}K.renderer.updateFull(!0)}K.session.setUseWrapMode(e.wrapLines!==!1);let ie=K.container.closest?.(".file-card"),se=()=>{if(!ie)return;let Re=K.renderer,Fe=(Re.layerConfig?.width||0)-(Re.$size?.scrollerWidth||0);ie.classList.toggle("at-right-edge",Fe<=2||Re.getScrollLeft()>=Fe-2)};K.session.on("changeScrollLeft",se),K.renderer.on("afterRender",se),window.matchMedia?.("(max-width: 767px)").matches&&K.setOption("hScrollBarAlwaysVisible",!0);let Y=ace.require("ace/range").Range,me=null;function Se(Re,Fe){me!==null&&(K.session.removeMarker(me),me=null),Re!=null&&(me=K.session.addMarker(new Y(Re,0,Fe,1),"highlighted-line","fullLine"))}function Ue(Re){let Fe=!e.preview&&window.location.hash.match(/^#L(\d+)(?:-L(\d+))?/);if(!Fe){Se(null);return}let W=parseInt(Fe[1])-1,fe=Fe[2]?parseInt(Fe[2])-1:W;Se(W,fe),Re&&i.timeout(()=>{K.scrollToLine(W,!0,!0,function(){})},100)}Ue(!0);let Be=null;K.on("guttermousedown",function(Re){let Fe=Re.getDocumentPosition().row,W=Re.domEvent&&Re.domEvent.shiftKey,fe=Fe,de=Fe;W&&Be!==null?(fe=Math.min(Be,Fe),de=Math.max(Be,Fe)):Be=Fe;let ce=fe===de?`#L${fe+1}`:`#L${fe+1}-L${de+1}`,ve=window.location.pathname+window.location.search+ce;e.preview||window.history.replaceState(null,"",ve),Se(fe,de),Re.stop()});let Qe=o(window,"hashchange",()=>Ue(!1));K.setFontSize(e.aceOption.fontSize),K.setOptions({fontFamily:"'JetBrains Mono', ui-monospace, SFMono-Regular, Menlo, monospace"}),K.container.style.lineHeight="20px",K.renderer.setPadding(16),K.renderer.setScrollMargin(12,12,0,0),K.renderer.updateFontSize(),K.setReadOnly(e.aceOption.readOnly),K.setKeyboardHandler(e.aceOption.keyBinding),K.setSelectionStyle(e.aceOption.fullLineSelection?"line":"text"),K.setOption("displayIndentGuides",!1),K.setHighlightActiveLine(e.aceOption.highlightActiveLine),e.aceOption.cursor=="hide"&&(K.renderer.$cursorLayer.element.style.display="none"),K.setHighlightGutterLine(e.aceOption.highlightGutterLine),K.setShowInvisibles(e.aceOption.showInvisibles),K.setDisplayIndentGuides(e.aceOption.showIndentGuides),K.renderer.setShowPrintMargin(e.aceOption.showPrintMargin),K.setHighlightSelectedWord(e.aceOption.highlightSelectedWord),K.session.setUseSoftTabs(e.aceOption.useSoftTab),K.session.setTabSize(e.aceOption.tabSize),K.setBehavioursEnabled(e.aceOption.enableBehaviours),K.setFadeFoldWidgets(e.aceOption.fadeFoldWidgets);let He=()=>!e.preview||K.isFocused(),et=o(window,"keydown",Re=>{if((Re.ctrlKey||Re.metaKey)&&!Re.altKey&&Re.key.toLowerCase()==="g"&&document.body.contains(K.container)&&He()){Re.preventDefault(),e.gotoLine();return}if(Re.altKey&&!Re.ctrlKey&&!Re.metaKey&&Re.key.toLowerCase()==="z"&&document.body.contains(K.container)&&He()){Re.preventDefault(),e.toggleWrap();return}(Re.ctrlKey||Re.metaKey)&&!Re.altKey&&Re.key.toLowerCase()==="f"&&document.body.contains(K.container)&&He()&&(Re.preventDefault(),e.findInFile())});return()=>{Qe(),et()}}},e.isDarkMode&&(e.aceOption.theme="nord_dark"),e.type=z(U)},e.renderFileContent=function(I,U,C,L){if(e.type=U,e.content=I,e.sourceContent=I,e.content==""&&(e.content=null),e.type=="md"&&(e.content=renderMD(I,C),e.type="html"),e.type=="org"){let K=contentAbs2Relative(I);var H=new Org.Parser().parse(K).convert(Org.ConverterHTML,{headerOffset:1,exportFromLineNumber:!1,suppressSubScriptHandling:!0,suppressAutoLink:!1});e.content=DOMPurify.sanitize(H.toString()),e.type="html"}e.type=="code"&&L=="application/octet-stream"&&(e.type="binary",e.content="binary"),i.timeout(()=>{Prism.highlightAll()},50)};let x=["image","media","audio","pdf","IPython","binary"],X=["file_too_big","file_not_found","file_not_accessible","file_not_supported","folder_not_supported"];e.fileFrame=()=>e.filePath?x.includes(e.type)?e.content!=null:e.type==="error"?X.includes(e.content):e.content==null&&["code","text"].includes(e.type):!1,e.fileKind=()=>{let I=(e.paths||[])[(e.paths||[]).length-1]||"",U=I.lastIndexOf("."),C=U>0?I.slice(U+1).toUpperCase():"";if(e.type==="image")return(C==="JPG"?"JPEG":C)+" image";let L={WEBM:"WebM",OGG:"Ogg",OGV:"Ogg",MOV:"QuickTime",M4V:"M4V",MKV:"Matroska"};return e.type==="media"?(L[C]||C)+" video":e.type==="audio"?C+" audio":e.type==="pdf"?"PDF":e.type==="IPython"?"Jupyter notebook":e.type==="binary"?"Binary file":e.languageName||(C?C+" file":"File")},e.imageSize="",e.onImageLoad=I=>{let U=I.target;U?.naturalWidth&&(e.imageSize=`${U.naturalWidth} \xD7 ${U.naturalHeight}`)},o(document,"click",I=>{e.preview&&(I.target.closest?.(".symbols")||(e.symbolsOpen=!1),I.target.closest?.(".tb-more")||(e.moreOpen=!1),I.target.closest?.(".tb-toc-m")||(e.tocOpen=!1),I.target.isConnected&&!I.target.closest?.(".goto-pop, .btn-goto, .tb-more")&&(e.gotoOpen=!1))})};function ga(e,t,s){let i,o=!1,r="form-draft:"+s,d=()=>Object.fromEntries(t.map(m=>[m,e[m]])),p=()=>JSON.stringify(d()),u=m=>{for(let w of t)Object.prototype.hasOwnProperty.call(m,w)&&(e[w]=m[w]);e.options?.expirationDate&&(e.options.expirationDate=new Date(e.options.expirationDate))},y=()=>{try{window.sessionStorage.removeItem(r)}catch{}},h=(m=!1)=>{if(i!==void 0){if(m&&document.querySelectorAll("input, select, textarea").forEach(w=>{w._field?.binding.state===e&&w._field.timer&&w._field.commit()}),e.unsavedChanges=p()!==i,e.draftSaved=!1,!e.unsavedChanges){y();return}try{window.sessionStorage.setItem(r,JSON.stringify({account:e.user?.username||null,savedAt:Date.now(),values:d()})),e.draftSaved=!0}catch{}}},b=()=>h(!0);return e.on("routeLeave",b),window.addEventListener("beforeunload",b),e.on("dispose",()=>window.removeEventListener("beforeunload",b)),{restore(){i=p();let m;try{m=JSON.parse(window.sessionStorage.getItem(r)||"null")}catch{}let w=m&&m.account===(e.user?.username||null)&&Date.now()-m.savedAt<30*6e4&&m.values;return w&&(u(m.values),e.draftRestored=!0),o||(o=!0,e.watch(()=>d(),()=>h(),!0)),e.unsavedChanges=p()!==i,!!w},checkpoint(){return document.querySelectorAll("input, select, textarea").forEach(m=>{m._field?.binding.state===e&&m._field.timer&&m._field.commit()}),JSON.parse(p())},accept(m){i=JSON.stringify(m),e.draftRestored=!1,h()},discard(){document.querySelectorAll("input, select, textarea").forEach(m=>{m._field?.binding.state!==e||!m._field.timer||(clearTimeout(m._field.timer),m._field.timer=null,m.value=m._field.binding.value??"")}),i!==void 0&&u(JSON.parse(i)),e.draftRestored=!1,h()},clear(){i=p(),e.unsavedChanges=!1,e.draftRestored=!1,e.draftSaved=!1,y()}}}var wa={};rf(wa,{bigNum:()=>dg,date:()=>bg,dateEcho:()=>ya,diff:()=>pg,duration:()=>qn,filter:()=>vg,humanFileSize:()=>lg,humanTime:()=>va,limitTo:()=>gg,money:()=>mg,number:()=>fg,orderBy:()=>yg,plural:()=>wg,shortDate:()=>ba,statusLabel:()=>cg,statusMsg:()=>Yi,title:()=>ug,uppercase:()=>hg});var lg=e=>String(window.humanFileSize(e)).replace(/([KMGTPEZY])iB$/,"$1B").replace(/\.0 ([KMGTPEZY]?B)$/," $1"),dg=(function(){return function(t){let s=Number(t)||0,i=Math.abs(s);return i<1e3?String(s):i<1e4?(s/1e3).toFixed(1).replace(/\.0$/,"")+"k":i<1e6?Math.round(s/1e3)+"k":i<1e7?(s/1e6).toFixed(1).replace(/\.0$/,"")+"M":Math.round(s/1e6)+"M"}})(),va=(function(){return function(t){if(!t)return"never";var s=null;t instanceof Date&&(s=t,t=Math.round((Date.now()-t)/1e3)),(typeof t=="string"||typeof t=="number")&&(s=new Date(t),t=Math.round((Date.now()-s)/1e3));var i=t<0?"from now":"ago";if(Math.abs(t)>7200*24)return(s&&!isNaN(s)?s:new Date(Date.now()-t*1e3)).toLocaleDateString(void 0,{day:"numeric",month:"short",year:"numeric"});t=Math.abs(t);for(var o=[t/60/60/24/365,t/60/60/24/30,t/60/60/24/7,t/60/60/24,t/60/60,t/60,t],r=["year","month","week","day","hour","minute","second"],d=0;d1&&(u+="s"),p>=1)return p+" "+u+" "+i}return"0 seconds "+i}})(),ug=(function(){return function(e){if(!e)return e;e=e.toLowerCase();var t=e.split(" "),s=t.map(function(i){return i.charAt(0).toUpperCase()+i.substring(1,i.length)});return s.join(" ")}})(),cg=(function(){var e={ready:"Ready",error:"Error",expired:"Expired",expiring:"Expiring",removed:"Removed",removing:"Removing",queue:"Queued",download:"Downloading",downloaded:"Downloaded",preparing:"Preparing",anonymizing:"Anonymizing"};return function(t){if(!t)return"";if(e[t])return e[t];var s=String(t).replace(/[_-]+/g," ").toLowerCase();return s.charAt(0).toUpperCase()+s.slice(1)}})(),Yi=(function(){var e={branch_not_found:"Branch not found on GitHub",repo_not_found:"Repository not found on GitHub",repository_not_found:"Repository not found on GitHub",repo_not_accessible:"Repository is not accessible with your token",pr_not_found:"Pull request not found on GitHub",gist_not_found:"Gist not found on GitHub",commit_not_found:"Commit not found on GitHub",repo_too_big:"Repository exceeds the size limit",repository_too_big:"Repository exceeds the size limit",quota_exceeded:"Storage quota exceeded",incomplete_record:"Incomplete record: missing identifier"};return function(t){if(!t)return t;var s=t.match(/^rate_limited:(\d+)$/);if(s){var i=Math.max(0,Math.ceil((parseInt(s[1],10)-Date.now())/1e3));if(i<=0)return"Rate limited \u2014 resuming soon";var o=Math.floor(i/60),r=i%60;return"Rate limited \u2014 retrying in "+(o>0?o+"m "+r+"s":r+"s")}if(e[t])return e[t];var d=/^([a-z0-9]+(?:_[a-z0-9]+)+):\s*\S/.exec(t);if(d){if(e[d[1]])return e[d[1]];var p=d[1].replace(/_/g," ");return p.charAt(0).toUpperCase()+p.slice(1)}if(/^[a-z0-9]+(_[a-z0-9]+)+$/.test(t)){var u=t.replace(/_/g," ");return u.charAt(0).toUpperCase()+u.slice(1)}return t}})(),pg=(function(e){let t=i=>i.replace(/&/g,"&").replace(//g,">");function s(i,o){if(!o)return;let r=o.newPath&&o.newPath!=="/dev/null"?o.newPath:o.oldPath||"",d=o.oldPath==="/dev/null"?"added":o.newPath==="/dev/null"?"deleted":o.oldPath&&o.newPath&&o.oldPath!==o.newPath?"renamed":"modified";if(i.push('
'),i.push('
'+t(r)+''+d+"
"),o.lines.length){i.push('');for(let p of o.lines)i.push('");i.push("
'+(p.oldNo||"")+''+(p.newNo||"")+''+(p.kind==="add"?"+":p.kind==="remove"?"-":"")+''+t(p.text)+"
")}i.push("
")}return function(i){if(!i)return i;let o=[],r=null,d=0,p=0,u=()=>(r||(r={oldPath:"",newPath:"",lines:[]}),r),y=()=>{r&&(r.lines.length||r.oldPath||r.newPath)&&(s(o,r),r=null)},h=i.split(` +`);for(let b=0;be});function fg(e,t){return e==null?"":Number(e).toLocaleString(void 0,t==null?{}:{minimumFractionDigits:t,maximumFractionDigits:t})}function mg(e,t="EUR"){let s=Number(e)||0;return new Intl.NumberFormat(void 0,{style:"currency",currency:t,minimumFractionDigits:s%1?2:0,maximumFractionDigits:2}).format(s)}function hg(e){return String(e??"").toUpperCase()}function gg(e,t,s=0){return(e||[]).slice(s,s+t)}function vg(e,t){return Array.isArray(e)?typeof t=="function"?e.filter(t):e:[]}function yg(e,t){if(!t)return e||[];let s=Array.isArray(t)?t:[t];return[...e||[]].sort((i,o)=>{for(let r of s){let d=r[0]==="-"?-1:1;r=r.replace(/^[+-]/,"");let p=r.split(".").reduce((y,h)=>y?.[h],i),u=r.split(".").reduce((y,h)=>y?.[h],o);if(typeof p=="string"&&(p=p.toLowerCase()),typeof u=="string"&&(u=u.toLowerCase()),p!==u)return(p==null?-1:u==null?1:pi[o])}function wg(e,t){return(t?.[e]??t?.[e===1?"one":"other"]??"").replace(/\{\}/g,e??0)}function ya(e){if(!e)return"";let t=/^(\d{4})-(\d{2})-(\d{2})$/.exec(String(e)),s=t?new Date(+t[1],+t[2]-1,+t[3]):new Date(e);if(isNaN(s))return"";let i=s.toLocaleDateString(void 0,{year:"numeric",month:"short",day:"numeric"}),o=new Date;o.setHours(0,0,0,0);let r=Math.round((s-o)/864e5),d;if(r===0)d="today";else if(r===1)d="tomorrow";else if(r===-1)d="yesterday";else{let p=Math.abs(r),u=Math.round(p/30.44),y=p<14?[p,"day"]:p<60?[Math.round(p/7),"week"]:u<18?[u,"month"]:[Math.round(p/365.25),"year"],h=y[0]+" "+y[1]+(y[0]===1?"":"s");d=r>0?"in "+h:h+" ago"}return i+" \xB7 "+d}function qn(e){if(e==null||e===""||isNaN(e))return"";e=Number(e);let t="\u202F";if(e<1e3)return+(e<10?e.toFixed(2):e<100?e.toFixed(1):Math.round(e))+t+"ms";let s=e/1e3;if(s<60)return+(s<10?s.toFixed(2):s.toFixed(1))+t+"s";let i=r=>String(r).padStart(2,"0"),o=Math.round(s);return o<3600?Math.floor(o/60)+"m "+i(o%60)+"s":Math.floor(o/3600)+"h "+i(Math.floor(o%3600/60))+"m"}function ba(e){if(!e)return"";let t=new Date(e);if(isNaN(t))return"";let s={day:"numeric",month:"short"};return t.getFullYear()!==new Date().getFullYear()&&(s.year="numeric"),t.toLocaleDateString(void 0,s)}var Xi=e=>["preparing","download","downloading","downloaded","queue","anonymizing"].includes(e)?"preparing":e==="expiring"?"expired":e==="removing"?"removed":e;function Ji(e,{flags:t,keys:s,count:i,onChange:o=()=>{}}){if(e.segView=()=>{let r=t()||{};if(s.every(p=>!!r[p]))return"all";let d=s.filter(p=>!!r[p]);return d.length===1?d[0]:"custom"},e.setSegView=r=>{let d=t();if(d){for(let p of s)d[p]=r==="all"?!0:p===r;o()}},e.segCount=r=>r==="all"?s.reduce((d,p)=>d+i(p),0):i(r),t()&&e.segView()==="custom")for(let r of s)t()[r]=!0}var $u=function(e,t,s){let i=Ct(),o=Ut();Gu(i,o),e.Math=Math,e.watch("user.status",()=>{e.user==null&&s.url("/")}),e.user==null&&s.url("/"),e.repositories=[],e.total=-1,e.totalPage=0,e.statusCounts=[],e.totalSize=0,e.selected={},e.allSelected=!1;let r=S=>{if(S.key==="/"&&!["INPUT","TEXTAREA","SELECT"].includes(document.activeElement?.tagName)){S.preventDefault();let R=document.querySelector('.admin-filter-toolbar input[type="search"]');R&&R.focus()}};o(document,"keydown",r),e.on("dispose",()=>document.removeEventListener("keydown",r)),e.clearFilter=S=>{S==="dateRange"?(e.query.dateFrom="",e.query.dateTo=""):e.query[S]="",e.query.page=1},e.chips=[];let d=()=>{let S=[];e.query.owner&&S.push({key:"owner",label:"Owner",value:e.query.owner}),e.query.conference&&S.push({key:"conference",label:"Conference",value:e.query.conference}),e.chips=S};e.showStatusMessage=S=>{let R=S.statusMessage||"(no message)";window.prompt(`Status message for ${S.repoId} (${S.status}):`,R)},e.fetchGithubInfo=S=>{let R=window.open("","_blank");R&&R.document.write("
Loading GitHub info for "+S.repoId+"...
"),t.get("/api/admin/repos/"+S.repoId+"/github").then(v=>{R&&(R.document.open(),R.document.write('
'+JSON.stringify(v.data,null,2).replace(/[<>]/g,E=>E==="<"?"<":">")+"
"),R.document.close())},v=>{let E=v&&v.data?JSON.stringify(v.data,null,2):String(v);R&&(R.document.body.innerHTML='
'+E+"
")})},e.statusCountFor=S=>{let R=(e.statusCounts||[]).find(v=>v._id===S);return R?R.count:0},e.statusStorageFor=S=>{let R=(e.statusCounts||[]).find(v=>v._id===S);return R?R.storage:0},e.isErrorsOnly=()=>e.query&&e.query.error&&!e.query.ready&&!e.query.preparing&&!e.query.expired&&!e.query.removed,e.toggleErrorsOnly=()=>{e.isErrorsOnly()?Object.assign(e.query,{ready:!1,preparing:!0,expired:!1,removed:!1,error:!0}):Object.assign(e.query,{ready:!1,preparing:!1,expired:!1,removed:!1,error:!0}),e.query.page=1},e.toggleSortDirection=()=>{e.query.direction=e.query.direction==="asc"?"desc":"asc"},e.sortBy=S=>{e.query.sort===S?e.query.direction=e.query.direction==="asc"?"desc":"asc":(e.query.sort=S,e.query.direction="desc"),e.query.page=1},e.sortIcon=S=>e.query.sort===S?e.query.direction==="asc"?"fa-arrow-up":"fa-arrow-down":"";let p="admin.repos.filterPrefs",u={page:1,limit:25,sort:"lastView",direction:"desc",search:"",owner:"",conference:"",dateFrom:"",dateTo:"",ready:!0,expired:!0,removed:!0,error:!0,preparing:!0},y=loadFilterPrefs(p)||{};e.query=Object.assign({},u,y,{page:1,search:""});let h=s.search();h.owner&&(e.query.owner=h.owner),h.conference&&(e.query.conference=h.conference),h.search&&(e.query.search=h.search);let b="admin.repos.presets";e.presets=JSON.parse(localStorage.getItem(b)||"[]"),e.savePreset=()=>{let S=window.prompt("Preset name:");if(!S)return;let R=Object.assign({},e.query);delete R.page,e.presets=(e.presets||[]).filter(v=>v.name!==S),e.presets.push({name:S,query:R}),localStorage.setItem(b,JSON.stringify(e.presets))},e.applyPreset=S=>{Object.assign(e.query,S.query,{page:1})},e.deletePreset=S=>{e.presets=(e.presets||[]).filter(R=>R.name!==S.name),localStorage.setItem(b,JSON.stringify(e.presets))},e.selectAllOnPage=()=>{e.allSelected=!e.allSelected,e.repositories.forEach(S=>{e.selected[S.repoId]=e.allSelected})},e.selectedCount=()=>Object.values(e.selected||{}).filter(Boolean).length,e.selectedRepos=()=>e.repositories.filter(S=>e.selected[S.repoId]),e.bulkRefresh=()=>{let S=e.selectedRepos();S.length&&confirm(`Force refresh ${S.length} repositories?`)&&S.forEach(R=>e.updateRepository(R))},e.bulkRemoveCache=()=>{let S=e.selectedRepos();S.length&&confirm(`Purge cache for ${S.length} repositories?`)&&S.forEach(R=>e.removeCache(R))},e.clearSelection=()=>{e.selected={},e.allSelected=!1},e.exportCsv=()=>{let S=new URLSearchParams(Object.entries(e.query).filter(([,R])=>R!==""&&R!==!1&&R!=null));S.set("format","csv"),S.set("limit","10000"),window.open("/api/admin/repos?"+S.toString(),"_blank")},e.removeCache=S=>{confirm("Remove cached files for "+S.repoId+"?")&&t.delete("/api/admin/repos/"+S.repoId).then(()=>m(),R=>console.error(R))},e.removeRepository=S=>{confirm("Remove repository "+S.repoId+"?")&&t.delete("/api/repo/"+S.repoId+"/").then(()=>m(),R=>console.error(R))},e.updateRepository=S=>{let R=st({title:`Refreshing ${S.repoId}...`,date:new Date,body:`The repository ${S.repoId} is going to be refreshed.`});e.toasts.push(R),t.post(`/api/repo/${S.repoId}/refresh`).then(v=>{v.data.status=="ready"?R.title=`${S.repoId} is refreshed.`:R.title=`Refreshing of ${S.repoId}.`},v=>{R.title=`Error during the refresh of ${S.repoId}.`,R.body=v.body})},e.filtersOpen=!1,e.fetchError=null;function m(){e.fetchError=null,t.get("/api/admin/repos",{params:e.query}).then(S=>{e.total=S.data.total,e.totalPage=Math.ceil(S.data.total/e.query.limit),e.repositories=S.data.results,e.allSelected=!1},S=>{e.fetchError=S&&S.data&&S.data.error||"Failed to load repositories",console.error(S)})}function w(){let S=Object.assign({},e.query,{page:1,limit:1,ready:!0,expired:!0,removed:!0,error:!0,preparing:!0});t.get("/api/admin/repos",{params:S}).then(R=>{e.statusCounts=R.data.statusCounts||[],e.totalSize=R.data.totalSize||0},()=>{})}e.showAllStatuses=()=>Object.assign(e.query,{ready:!0,expired:!0,removed:!0,error:!0,preparing:!0,page:1}),Ji(e,{flags:()=>e.query,keys:["ready","preparing","error","expired","removed"],count:S=>S==="preparing"?e.statusCountFor("preparing")+e.statusCountFor("download"):S==="expired"?e.statusCountFor("expired")+e.statusCountFor("expiring"):S==="removed"?e.statusCountFor("removed")+e.statusCountFor("removing"):e.statusCountFor(S),onChange:()=>{e.query.page=1}}),m(),w();let N=null;e.watch("query",()=>{i.timeout.cancel(N),N=i.timeout(()=>{m(),w()},500);let{page:S,search:R,...v}=e.query;saveFilterPrefs(p,v),d()},!0),d()},Fu=function(e,t,s){let i=Ct(),o=Ut();e.Math=Math,e.watch("user.status",()=>{e.user==null&&s.url("/")}),e.user==null&&s.url("/"),e.users=[],e.total=-1,e.totalPage=0,e.statusCounts=[],e.selected={},e.allSelected=!1;let r=m=>{if(m.key==="/"&&!["INPUT","TEXTAREA","SELECT"].includes(document.activeElement?.tagName)){m.preventDefault();let w=document.querySelector('.admin-filter-toolbar input[type="search"]');w&&w.focus()}};o(document,"keydown",r),e.on("dispose",()=>document.removeEventListener("keydown",r)),e.clearFilter=m=>{m==="dateRange"?(e.query.dateFrom="",e.query.dateTo=""):e.query[m]="",e.query.page=1},e.chips=[];let d=()=>{let m=[];e.query.role&&m.push({key:"role",label:"Role",value:e.query.role}),e.chips=m};e.statusCountFor=m=>{let w=(e.statusCounts||[]).find(N=>N._id===m);return w?w.count:0},e.toggleSortDirection=()=>{e.query.direction=e.query.direction==="asc"?"desc":"asc"},e.sortBy=m=>{e.query.sort===m?e.query.direction=e.query.direction==="asc"?"desc":"asc":(e.query.sort=m,e.query.direction="desc"),e.query.page=1},e.sortIcon=m=>e.query.sort===m?e.query.direction==="asc"?"fa-arrow-up":"fa-arrow-down":"";let p="admin.users.filterPrefs",u={page:1,limit:25,sort:"username",direction:"asc",search:"",status:"",role:"",dateFrom:"",dateTo:""},y=loadFilterPrefs(p)||{};e.query=Object.assign({},u,y,{page:1,search:""}),e.selectAllOnPage=()=>{e.allSelected=!e.allSelected,e.users.forEach(m=>{e.selected[m.username]=e.allSelected})},e.selectedCount=()=>Object.values(e.selected||{}).filter(Boolean).length,e.selectedUsers=()=>e.users.filter(m=>e.selected[m.username]),e.banUser=m=>{confirm(`Ban user ${m.username}?`)&&t.post(`/api/admin/users/${m.username}/ban`).then(h,w=>console.error(w))},e.activateUser=m=>{t.post(`/api/admin/users/${m.username}/activate`).then(h,w=>console.error(w))},e.bulkBan=()=>{let m=e.selectedUsers();m.length&&confirm(`Ban ${m.length} users?`)&&m.forEach(w=>e.banUser(w))},e.exportCsv=()=>{let m=new URLSearchParams(Object.entries(e.query).filter(([,w])=>w!==""&&w!==!1&&w!=null));m.set("format","csv"),m.set("limit","10000"),window.open("/api/admin/users?"+m.toString(),"_blank")},e.fetchError=null;function h(){e.fetchError=null,t.get("/api/admin/users",{params:e.query}).then(m=>{e.total=m.data.total,e.totalPage=Math.ceil(m.data.total/e.query.limit),e.users=m.data.results,e.statusCounts=m.data.statusCounts||[],e.allSelected=!1},m=>{e.fetchError=m&&m.data&&m.data.error||"Failed to load users",console.error(m)})}h();let b=null;e.watch("query",()=>{i.timeout.cancel(b),b=i.timeout(h,500);let{page:m,search:w,...N}=e.query;saveFilterPrefs(p,N),d()},!0),d()},Uu=function(e,t,s,i){let o=Ct();Gu(o,Ut()),e.watch("user.status",()=>{e.user==null&&s.url("/")}),e.user==null&&s.url("/"),e.userInfo,e.repositories=[],e.search="",e.selected={},e.allSelected=!1;let r="admin.user.filterPrefs",d={filters:{status:{ready:!0,expired:!0,removed:!0,error:!0,preparing:!0}},sort:"anonymizeDate",direction:"desc"},p=loadFilterPrefs(r)||{};e.filters={status:Object.assign({},d.filters.status,p.filters&&p.filters.status||{})},e.query={sort:p.sort||d.sort,direction:p.direction||d.direction},e.orderBy=(e.query.direction==="asc"?"":"-")+e.query.sort,e.sortBy=m=>{e.query.sort===m?e.query.direction=e.query.direction==="asc"?"desc":"asc":(e.query.sort=m,e.query.direction="desc"),e.orderBy=(e.query.direction==="asc"?"":"-")+e.query.sort},e.sortIcon=m=>e.query.sort===m?e.query.direction==="asc"?"fa-arrow-up":"fa-arrow-down":"",e.watch("query",()=>{saveFilterPrefs(r,{filters:e.filters,sort:e.query.sort,direction:e.query.direction})},!0),e.watch("filters",()=>{saveFilterPrefs(r,{filters:e.filters,sort:e.query.sort,direction:e.query.direction})},!0),e.statusCountFor=m=>(e.repositories||[]).filter(w=>Xi(w.status)===m).length,Ji(e,{flags:()=>e.filters.status,keys:["ready","preparing","error","expired","removed"],count:m=>e.statusCountFor(m)}),e.repoFiler=m=>e.filters.status[Xi(m.status)]==!1?!1:!!(e.search.trim().length==0||m.source.fullName.indexOf(e.search)>-1||m.repoId.indexOf(e.search)>-1||m.statusMessage&&m.statusMessage.indexOf(e.search)>-1||m.conference&&m.conference.indexOf(e.search)>-1),e.selectAllOnPage=()=>{e.allSelected=!e.allSelected,(e.filteredRepositories||e.repositories).forEach(m=>{e.selected[m.repoId]=e.allSelected})},e.selectedCount=()=>Object.values(e.selected||{}).filter(Boolean).length,e.selectedRepos=()=>e.repositories.filter(m=>e.selected[m.repoId]),e.bulkRefresh=()=>{let m=e.selectedRepos();m.length&&confirm(`Force refresh ${m.length} repositories?`)&&m.forEach(w=>e.updateRepository(w))},e.bulkRemoveCache=()=>{let m=e.selectedRepos();m.length&&confirm(`Purge cache for ${m.length} repositories?`)&&m.forEach(w=>e.removeCache(w))},e.clearSelection=()=>{e.selected={},e.allSelected=!1},e.exportCsv=()=>{let m=e.filteredRepositories||e.repositories,N=["repoId","status","statusMessage","pageView","anonymizeDate","source.fullName","conference","size.storage"].join(","),S=m.map(E=>[E.repoId,E.status,E.statusMessage||"",E.pageView||0,E.anonymizeDate||"",E.source&&E.source.fullName||"",E.conference||"",E.size&&E.size.storage||0].map(D=>{let V=String(D??"");return/[",\n\r]/.test(V)?'"'+V.replace(/"/g,'""')+'"':V}).join(",")),R=new Blob([N+` `+S.join(` -`)],{type:"text/csv"}),v=document.createElement("a");v.href=URL.createObjectURL(N),v.download=i.username+"-repositories.csv",v.click()},e.showStatusMessage=h=>{let w=h.statusMessage||"(no message)";window.prompt(`Status message for ${h.repoId} (${h.status}):`,w)},e.fetchGithubInfo=h=>{let w=window.open("","_blank");w&&w.document.write("
Loading GitHub info for "+h.repoId+"...
"),t.get("/api/admin/repos/"+h.repoId+"/github").then(R=>{w&&(w.document.open(),w.document.write('
'+JSON.stringify(R.data,null,2).replace(/[<>]/g,S=>S==="<"?"<":">")+"
"),w.document.close())},R=>{let S=R&&R.data?JSON.stringify(R.data,null,2):String(R);w&&(w.document.body.innerHTML='
'+S+"
")})};function u(h){t.get("/api/admin/users/"+h+"/repos",{}).then(w=>{e.repositories=w.data},w=>{console.error(w)})}function y(h){t.get("/api/admin/users/"+h,{}).then(w=>{e.userInfo=w.data},w=>{console.error(w)})}y(i.username),u(i.username),e.banUser=()=>{confirm(`Ban user ${i.username}?`)&&t.post(`/api/admin/users/${i.username}/ban`).then(()=>y(i.username),h=>console.error(h))},e.activateUser=()=>{t.post(`/api/admin/users/${i.username}/activate`).then(()=>y(i.username),h=>console.error(h))},e.promoteUser=()=>{confirm(`Promote ${i.username} to admin?`)&&t.post(`/api/admin/users/${i.username}/promote`).then(()=>y(i.username),h=>console.error(h))},e.demoteUser=()=>{confirm(`Remove admin privileges from ${i.username}?`)&&t.post(`/api/admin/users/${i.username}/demote`).then(()=>y(i.username),h=>console.error(h))},e.tokens=[],e.tokenForm={name:"",plaintext:null};function m(){t.get("/api/admin/tokens").then(h=>{e.tokens=h.data||[]},h=>{h.status!==401&&h.status!==403&&console.error(h)})}m(),e.createToken=()=>{e.tokenForm.name&&t.post("/api/admin/tokens",{name:e.tokenForm.name}).then(h=>{e.tokenForm.plaintext=h.data.token,e.tokenForm.name="",m()},h=>console.error(h))},e.revokeToken=h=>{confirm(`Revoke token "${h.name}"?`)&&t.delete("/api/admin/tokens/"+h.id).then(()=>m(),w=>console.error(w))},e.removeCache=h=>{confirm("Remove cached files for "+h.repoId+"?")&&t.delete("/api/admin/repos/"+h.repoId).then(()=>u(i.username),w=>console.error(w))},e.removeRepository=h=>{confirm("Remove repository "+h.repoId+"?")&&t.delete("/api/repo/"+h.repoId+"/").then(()=>u(i.username),w=>console.error(w))},e.updateRepository=h=>{let w=st({title:`Refreshing ${h.repoId}...`,date:new Date,body:`The repository ${h.repoId} is going to be refreshed.`});e.toasts.push(w),t.post(`/api/repo/${h.repoId}/refresh`).then(R=>{R.data.status=="ready"?w.title=`${h.repoId} is refreshed.`:w.title=`Refreshing of ${h.repoId}.`},R=>{w.title=`Error during the refresh of ${h.repoId}.`,w.body=R.body})},e.getGitHubRepositories=h=>{t.get(`/api/user/${e.userInfo.username}/all_repositories`,{params:{force:"1"}}).then(w=>{e.userInfo.repositories=w.data})};let b=null;e.watch("query",()=>{o.timeout.cancel(b),b=o.timeout(()=>{u(i.username)},500)},!0)},Bu=function(e,t,s){let i=Ct(),o=Bt();e.Math=Math,e.watch("user.status",()=>{e.user==null&&s.url("/")}),e.user==null&&s.url("/"),e.conferences=[],e.total=-1,e.totalPage=0,e.statusCounts=[];let r=R=>{if(R.key==="/"&&!["INPUT","TEXTAREA","SELECT"].includes(document.activeElement?.tagName)){R.preventDefault();let S=document.querySelector('.admin-filter-toolbar input[type="search"]');S&&S.focus()}};o(document,"keydown",r),e.on("dispose",()=>document.removeEventListener("keydown",r)),e.clearFilter=R=>{R==="dateRange"?(e.query.dateFrom="",e.query.dateTo=""):e.query[R]="",e.query.page=1},e.chips=[];let d=()=>{let R=[];(e.query.dateFrom||e.query.dateTo)&&R.push({key:"dateRange",label:"Date",value:(e.query.dateFrom||"\u2026")+" \u2013 "+(e.query.dateTo||"\u2026")}),e.chips=R};e.statusCountFor=R=>{let S=(e.statusCounts||[]).find(N=>N._id===R);return S?S.count:0},e.toggleSortDirection=()=>{e.query.direction=e.query.direction==="asc"?"desc":"asc"},e.sortBy=R=>{e.query.sort===R?e.query.direction=e.query.direction==="asc"?"desc":"asc":(e.query.sort=R,e.query.direction="desc"),e.query.page=1},e.sortIcon=R=>e.query.sort===R?e.query.direction==="asc"?"fa-arrow-up":"fa-arrow-down":"";let p="admin.conferences.filterPrefs",u={page:1,limit:25,sort:"name",direction:"asc",search:"",dateFrom:"",dateTo:"",ready:!0,expired:!0,removed:!0,error:!0,preparing:!0},y=loadFilterPrefs(p)||{};e.query=Object.assign({},u,y,{page:1,search:""});let m=s.search();m.search&&(e.query.search=m.search);let b="admin.conferences.presets";e.presets=JSON.parse(localStorage.getItem(b)||"[]"),e.savePreset=()=>{let R=window.prompt("Preset name:");if(!R)return;let S=Object.assign({},e.query);delete S.page,e.presets=(e.presets||[]).filter(N=>N.name!==R),e.presets.push({name:R,query:S}),localStorage.setItem(b,JSON.stringify(e.presets))},e.applyPreset=R=>{Object.assign(e.query,R.query,{page:1})},e.deletePreset=R=>{e.presets=(e.presets||[]).filter(S=>S.name!==R.name),localStorage.setItem(b,JSON.stringify(e.presets))},e.removeConference=R=>{confirm("Remove conference "+R.conferenceID+"?")&&t.delete("/api/admin/conferences/"+R.conferenceID).then(()=>h(),S=>console.error(S))},e.exportCsv=()=>{let R=new URLSearchParams(Object.entries(e.query).filter(([,S])=>S!==""&&S!==!1&&S!=null));R.set("format","csv"),R.set("limit","10000"),window.open("/api/admin/conferences?"+R.toString(),"_blank")},e.fetchError=null;function h(){e.fetchError=null,t.get("/api/admin/conferences",{params:e.query}).then(R=>{e.total=R.data.total,e.totalPage=Math.ceil(R.data.total/e.query.limit),e.conferences=R.data.results,e.statusCounts=R.data.statusCounts||[]},R=>{e.fetchError=R&&R.data&&R.data.error||"Failed to load conferences",console.error(R)})}Ji(e,{flags:()=>e.query,keys:["ready","preparing","error","expired","removed"],count:R=>e.statusCountFor(R),onChange:()=>{e.query.page=1}}),h();let w=null;e.watch("query",()=>{i.timeout.cancel(w),w=i.timeout(h,500);let{page:R,search:S,...N}=e.query;saveFilterPrefs(p,N),d()},!0),d()},zu=function(e,t,s,i,o){let r=Ct();e.watch("user.status",()=>{e.user==null&&s.url("/")}),e.user==null&&s.url("/"),e.queueList=[],e.jobs=[],e.selectedQueue="download",e.selectedStats=null,e.range="1h",e.allStates=["active","waiting","delayed","failed","completed"],e.stateFilter={active:!0,waiting:!0,delayed:!0,failed:!0,completed:!0},Ji(e,{flags:()=>e.stateFilter,keys:e.allStates,count:N=>(e.jobs||[]).filter(v=>v._state===N).length}),e.query={search:"",autoRefresh:!0},e.filteredJobs=()=>(e.jobs||[]).filter(N=>e.stateFilter[N._state]),e.jobProgressPct=N=>N?._state==="completed"?100:N&&N.progress&&typeof N.progress=="object"&&typeof N.progress.percent=="number"?Math.max(0,Math.min(100,Math.round(N.progress.percent))):typeof N.progress=="number"?Math.max(0,Math.min(100,Math.round(N.progress))):null;let d={get_files:"Fetching files",download:"Downloading",downloading:"Downloading",anonymize:"Anonymizing",anonymizing:"Anonymizing",ready:"Ready",removing:"Removing",preparing:"Preparing"};e.jobDetail=N=>{if(N?._state==="failed")return Yi(N.failedReason||"")||"Failed";let v=N?.progress&&typeof N.progress=="object"?N.progress.status:null;return N?._state==="active"&&v?d[v]||Yi(v):"\u2014"},e.jobDuration=N=>{if(!N.processedOn)return"\u2014";let v=N.finishedOn||Date.now();return qn(v-N.processedOn)},e.metricsPoints=[],e.selectQueue=N=>{e.selectedQueue=N,p(),u()},e.setRange=N=>{e.range=N,u()};function p(){let N={queue:e.selectedQueue,search:e.query.search};t.get("/api/admin/queues",{params:N}).then(v=>{e.queueList=v.data.queues||[],e.jobs=v.data.jobs||[],e.selectedStats=e.queueList.find(E=>E.key===e.selectedQueue)||e.queueList[0]||null},v=>console.error(v))}function u(){t.get("/api/admin/queues/metrics",{params:{queue:e.selectedQueue,range:e.range}}).then(N=>{e.metricsPoints=N.data.points||[],o(w,0)},N=>console.error(N))}p(),u();let y=i(()=>{e.query.autoRefresh&&(p(),u())},15e3);e.on("dispose",()=>i.cancel(y)),e.refreshNow=function(){p(),u()};function m(N){let v=N&&N.data&&(N.data.message||N.data.error)||"Request failed";e.actionError=v,o(()=>{e.actionError=null},5e3),console.error(N)}e.actionError=null,e.removeJob=N=>{t.delete(`/api/admin/queue/${e.selectedQueue}/${N.id}`).then(p,m)},e.retryJob=N=>{t.post(`/api/admin/queue/${e.selectedQueue}/${N.id}`).then(p,m)},e.retryFailed=()=>{confirm(`Retry all failed jobs in ${e.selectedQueue}?`)&&t.post(`/api/admin/queue/${e.selectedQueue}/retry-failed`).then(p,N=>console.error(N))},e.drainSelected=()=>{confirm(`Drain the ${e.selectedQueue} queue?`)&&t.post(`/api/admin/queue/${e.selectedQueue}/drain`).then(p,N=>console.error(N))},e.togglePause=()=>{let N=e.selectedStats&&e.selectedStats.paused?"resume":"pause";t.post(`/api/admin/queue/${e.selectedQueue}/${N}`).then(p,v=>console.error(v))},e.emptyQueue=()=>{confirm(`Empty the ${e.selectedQueue} queue? This removes ALL jobs.`)&&t.post(`/api/admin/queue/${e.selectedQueue}/empty`).then(p,N=>console.error(N))},e.pauseAll=()=>{confirm("Pause all queues?")&&t.post("/api/admin/queues/pause-all").then(p,N=>console.error(N))};let b=null;e.watch("query.search",()=>{r.timeout.cancel(b),b=r.timeout(p,350)}),e.expanded={},e.toggleJob=N=>{e.expanded[N.id]=!e.expanded[N.id]},e.humanTime=N=>{if(!N)return"";let v=new Date(N);return v.toLocaleTimeString([],{hour:"2-digit",minute:"2-digit",second:"2-digit",hour12:!1})+" "+v.toLocaleDateString([],{month:"short",day:"numeric"})},e.delayCountdown=N=>{if(!N)return"";var v=Math.max(0,Math.ceil((N-Date.now())/1e3));if(v<=0)return"resuming soon";var E=Math.floor(v/60),M=v%60;return"in "+(E>0?E+"m "+M+"s":M+"s")};function h(N){if(N<=0)return{ticks:[0],niceMax:1};let v=Math.pow(10,Math.floor(Math.log10(N))),E=v;N/E<2?E=v/2:N/E>5&&(E=v*2);let M=Math.ceil(N/E)*E,V=[];for(let _=0;_<=M;_+=E)V.push(_);return{ticks:V,niceMax:M}}function w(){var N=document.getElementById("q-throughput-chart");if(!N)return;var v=N.getContext("2d"),E=window.devicePixelRatio||1,M=N.parentElement.getBoundingClientRect(),V=44,_=44,G=22,te=Math.max(200,Math.round(M.width)),X=Math.max(180,Math.min(420,Math.round(M.height)||180)),O=te-V-_,U=X-G;N.width=te*E,N.height=X*E,N.style.width=te+"px",N.style.height=X+"px",v.setTransform(E,0,0,E,0,0);var C=document.body.classList.contains("dark-mode"),L="#8A857C",z=C?"rgba(255,255,255,0.06)":"rgba(0,0,0,0.06)",K=C?"#6FBF8A":"#2F7D4F",ie=C?"rgba(111,191,138,0.12)":"rgba(47,125,79,0.08)",se=C?"#F08A82":"#B42318",Y=C?"rgba(240,138,130,0.08)":"rgba(180,35,24,0.06)",he=getComputedStyle(document.body).getPropertyValue("--q-time-series").trim()||(C?"#E0A94A":"#946512"),Se=e.metricsPoints||[];if(Se.length===0){v.fillStyle=L,v.font="13px Inter, system-ui, sans-serif",v.textAlign="center",v.fillText("No metrics data yet",te/2,X/2),R=null;return}var Ue=Se.map(function(we){return we.completed}),Be=Se.map(function(we){return we.failed}),Qe=Se.map(function(we){return we.avgMs});if(!Ue.some(Boolean)&&!Be.some(Boolean)){v.strokeStyle=C?"rgba(255,255,255,0.14)":"rgba(0,0,0,0.12)",v.beginPath(),v.moveTo(0,X-18.5),v.lineTo(te,X-18.5),v.stroke(),v.fillStyle=C?"#CFC8BD":"#4F4A42",v.font="500 14px Inter, system-ui, sans-serif",v.textAlign="center",v.fillText("No jobs processed in this window",te/2,X/2-6),v.fillStyle=L,v.font="12.5px Inter, system-ui, sans-serif",v.fillText("Completed and failed jobs will chart here",te/2,X/2+16),R=null;return}var He=Se.length,et=O/(He-1||1),Re=Math.max(1,Math.max.apply(null,Ue),Math.max.apply(null,Be)),Fe=h(Re),W=Math.max.apply(null,Qe),fe=W>0?h(W):{ticks:[0],niceMax:1},de=function(we){return U-we/Fe.niceMax*(U-10)},ce=function(we){return U-we/fe.niceMax*(U-10)},ve=function(we){return V+we*et};v.textAlign="right",v.textBaseline="middle",v.font="11px Inter, system-ui, sans-serif",Fe.ticks.forEach(function(we){var be=de(we);v.strokeStyle=z,v.lineWidth=1,v.beginPath(),v.moveTo(V,be),v.lineTo(te-_,be),v.stroke(),v.fillStyle=L,we!==0&&v.fillText(we>=1e3?(we/1e3).toFixed(1)+"k":String(we),V-6,be)}),W>0&&(v.textAlign="left",fe.ticks.forEach(function(we){var be=ce(we);v.fillStyle=he,we!==0&&v.fillText(qn(we),te-_+6,be)}));var Me=Se[He-1].ts,P=Se[0].ts,T=Math.max(0,(Me-P)/6e4),F=[1,2,5,10,15,30,60,120,180,360,720,1440,2880,10080],J=F.find(function(we){return T/we<=4})||F[F.length-1],H=function(we){return we<60?we+"m":we<1440?we/60+"h":we/1440+"d"},x=function(we){for(var be=0,ot=1;ot0&&Math.abs(Se[ke].ts-(Me-ee*6e4))>le+1)){var pe=ve(ke),Ee=ee===0?"now":H(ee)+" ago",Ae=v.measureText(Ee).width,Ve=oe===0?"right":ke===0?"left":"center",Ge=Ve==="right"?pe:Ve==="left"?pe+Ae:pe+Ae/2;Ge>ne-12||(v.textAlign=Ve,v.fillText(Ee,pe,U+6),ne=Ve==="right"?pe-Ae:Ve==="left"?pe:pe-Ae/2)}}function ze(we,be,ot,rt){we.length!==0&&(v.beginPath(),v.moveTo(ve(0),U),we.forEach(function(yt,at){var lt=ve(at),ft=be(yt);if(at===0)v.lineTo(lt,ft);else{var Vt=(ve(at-1)+lt)/2;v.bezierCurveTo(Vt,be(we[at-1]),Vt,ft,lt,ft)}}),v.lineTo(ve(we.length-1),U),v.closePath(),v.fillStyle=ot,v.fill(),v.beginPath(),we.forEach(function(yt,at){var lt=ve(at),ft=be(yt);if(at===0)v.moveTo(lt,ft);else{var Vt=(ve(at-1)+lt)/2;v.bezierCurveTo(Vt,be(we[at-1]),Vt,ft,lt,ft)}}),v.strokeStyle=rt,v.lineWidth=1.5,v.stroke())}ze(Ue,de,ie,K),ze(Be,de,Y,se),W>0&&(v.beginPath(),Qe.forEach(function(we,be){var ot=ve(be),rt=ce(we);if(be===0)v.moveTo(ot,rt);else{var yt=(ve(be-1)+ot)/2;v.bezierCurveTo(yt,ce(Qe[be-1]),yt,rt,ot,rt)}}),v.strokeStyle=he,v.lineWidth=1,v.setLineDash([4,3]),v.stroke(),v.setLineDash([])),R={pts:Se,maxLen:He,marginLeft:V,step:et,totalW:te,toX:ve}}var R=null;function S(){var N=document.getElementById("q-throughput-chart");if(!(!N||N._tipBound)){N._tipBound=!0;var v=document.getElementById("q-chart-tooltip"),E=document.getElementById("q-chart-crosshair");N.addEventListener("mousemove",function(M){if(!(!R||!v||!E)){var V=R,_=N.getBoundingClientRect(),G=M.clientX-_.left,te=Math.round((G-V.marginLeft)/V.step);if(te<0||te>=V.maxLen){v.style.display="none",E.style.display="none";return}var X=V.pts[te],O=V.pts[V.pts.length-1].ts,U=Math.round((O-X.ts)/6e4),C;if(U<=0)C="now";else if(U<60)C=U+"m ago";else if(U<1440){var L=Math.floor(U/60),z=U%60;C=L+"h"+(z?" "+z+"m":"")+" ago"}else C=Math.round(U/1440)+"d ago";var K='
'+C+'
● completed: '+X.completed+'/min
● failed: '+X.failed+"/min
";if(X.avgMs>0){var ie=qn(X.avgMs);K+='
● avg time: '+ie+"
"}v.innerHTML=K;var se=V.toX(te),Y=v.offsetWidth,he=se+10;he+Y>V.totalW&&(he=se-Y-10),v.style.display="block",v.style.left=he+"px",v.style.top="8px",E.style.display="block",E.style.left=se+"px"}}),N.addEventListener("mouseleave",function(){v&&(v.style.display="none"),E&&(E.style.display="none")})}}e.watch("metricsPoints",function(){o(S,50)})},Hu=function(e,t,s,i){let o=Ct();e.watch("user.status",()=>{e.user==null&&s.url("/")}),e.user==null&&s.url("/"),e.entries=[],e.visible=[],e.available=!0,e.cap=1e3,e.total=0,e.pageSize=250,e.expanded={},e.detailTab={},e.copyHint="",e.parsedFilterCount=0,e.stats={last24h:0,prev24h:0,delta:0,severity:{error:0,warn:0,info:0},unique:{error:0,warn:0,info:0},buckets:[],dropped:0},e.query={search:"",bucket:"",sort:"recent",group:"code",autoRefresh:!0},e.relTime=v=>{if(!v)return"";let E=new Date(v).getTime();if(isNaN(E))return v;let M=Math.max(0,Date.now()-E),V=Math.floor(M/1e3);if(V<5)return"just now";if(V<60)return`${V}s ago`;let _=Math.floor(V/60);if(_<60)return`${_}m ago`;let G=Math.floor(_/60);if(G<24)return`${G}h ago`;let te=Math.floor(G/24);return te<7?`${te}d ago`:new Date(v).toLocaleDateString(void 0,{year:"numeric",month:"short",day:"numeric"})},e.absTime=v=>{if(!v)return"";let E=new Date(v);return isNaN(E.getTime())?v:E.toLocaleString(void 0,{year:"numeric",month:"short",day:"numeric",hour:"2-digit",minute:"2-digit"})},e.absTimeShort=v=>{if(!v)return"";let E=new Date(v);return isNaN(E.getTime())?v:E.toLocaleTimeString([],{hour:"2-digit",minute:"2-digit",second:"2-digit",hour12:!1})};let r=/^[a-zA-Z][a-zA-Z0-9]*(?:_[a-zA-Z0-9]+)+$/;function d(v,E){let M=v&&(v.httpStatus||v.status)||null;if(typeof M=="number"){if(M>=500)return"error";if(M===401||M===403||M===404)return"info";if(M>=400)return"warn"}return E==="error"?"error":E==="warn"?"warn":"info"}function p(v){let E=(v.raw||[]).find(G=>G&&typeof G=="object"&&!Array.isArray(G));if(E){E.message&&r.test(E.message)?(v.displayMessage=E.message,v.displayContext=v.message):E.code&&r.test(String(E.code))?(v.displayMessage=String(E.code),v.displayContext=v.message):E.name&&E.name!=="AnonymousError"&&E.name!=="Error"?(v.displayMessage=E.name,v.displayContext=E.message||v.message):v.displayMessage=v.message,v._status=E.httpStatus||E.status||null,v._url=E.url||null,v._method=E.method||null,v._repoId=E.repoId||E.detail||null,v._detail=E.detail&&E.detail!==v._repoId?E.detail:null;let G=typeof E.stack=="string"?E.stack:null;for(var M=[E.cause,E.err].filter(Boolean),V=0;!G&&V{O==null||O===""||M.push([X,O])};V("name",E&&E.name),V("code",v.displayMessage||E&&E.message),v._bucket&&V("kind",v._bucket),V("httpStatus",E&&E.httpStatus),E&&E.status&&!E.httpStatus&&V("status",E.status),V("module",v.module);let _=E&&E.detail;if(typeof _=="string"){let X=_.trim();if(X[0]==="{"||X[0]==="[")try{_=JSON.parse(_)}catch{}}if(V("detail",_),V("repoId",E&&E.repoId),V("filePath",E&&E.filePath),V("upstreamStatus",E&&E.upstreamStatus),V("upstreamBody",E&&E.upstreamBody),V("url",v._url),V("err",E&&E.err),V("cause",E&&!E.err&&E.cause),V("ts",v.ts),!M.length)return JSON.stringify(v,null,2);let G=M.reduce((X,O)=>Math.max(X,O[0].length),0),te=["{"];return M.forEach(([X,O],U)=>{let L=` ${`"${X}":`.padEnd(G+3," ")} `,z=U{let w=m.statusMessage||"(no message)";window.prompt(`Status message for ${m.repoId} (${m.status}):`,w)},e.fetchGithubInfo=m=>{let w=window.open("","_blank");w&&w.document.write("
Loading GitHub info for "+m.repoId+"...
"),t.get("/api/admin/repos/"+m.repoId+"/github").then(N=>{w&&(w.document.open(),w.document.write('
'+JSON.stringify(N.data,null,2).replace(/[<>]/g,S=>S==="<"?"<":">")+"
"),w.document.close())},N=>{let S=N&&N.data?JSON.stringify(N.data,null,2):String(N);w&&(w.document.body.innerHTML='
'+S+"
")})};function u(m){t.get("/api/admin/users/"+m+"/repos",{}).then(w=>{e.repositories=w.data},w=>{console.error(w)})}function y(m){t.get("/api/admin/users/"+m,{}).then(w=>{e.userInfo=w.data},w=>{console.error(w)})}y(i.username),u(i.username),e.banUser=()=>{confirm(`Ban user ${i.username}?`)&&t.post(`/api/admin/users/${i.username}/ban`).then(()=>y(i.username),m=>console.error(m))},e.activateUser=()=>{t.post(`/api/admin/users/${i.username}/activate`).then(()=>y(i.username),m=>console.error(m))},e.promoteUser=()=>{confirm(`Promote ${i.username} to admin?`)&&t.post(`/api/admin/users/${i.username}/promote`).then(()=>y(i.username),m=>console.error(m))},e.demoteUser=()=>{confirm(`Remove admin privileges from ${i.username}?`)&&t.post(`/api/admin/users/${i.username}/demote`).then(()=>y(i.username),m=>console.error(m))},e.tokens=[],e.tokenForm={name:"",plaintext:null};function h(){t.get("/api/admin/tokens").then(m=>{e.tokens=m.data||[]},m=>{m.status!==401&&m.status!==403&&console.error(m)})}h(),e.createToken=()=>{e.tokenForm.name&&t.post("/api/admin/tokens",{name:e.tokenForm.name}).then(m=>{e.tokenForm.plaintext=m.data.token,e.tokenForm.name="",h()},m=>console.error(m))},e.revokeToken=m=>{confirm(`Revoke token "${m.name}"?`)&&t.delete("/api/admin/tokens/"+m.id).then(()=>h(),w=>console.error(w))},e.removeCache=m=>{confirm("Remove cached files for "+m.repoId+"?")&&t.delete("/api/admin/repos/"+m.repoId).then(()=>u(i.username),w=>console.error(w))},e.removeRepository=m=>{confirm("Remove repository "+m.repoId+"?")&&t.delete("/api/repo/"+m.repoId+"/").then(()=>u(i.username),w=>console.error(w))},e.updateRepository=m=>{let w=st({title:`Refreshing ${m.repoId}...`,date:new Date,body:`The repository ${m.repoId} is going to be refreshed.`});e.toasts.push(w),t.post(`/api/repo/${m.repoId}/refresh`).then(N=>{N.data.status=="ready"?w.title=`${m.repoId} is refreshed.`:w.title=`Refreshing of ${m.repoId}.`},N=>{w.title=`Error during the refresh of ${m.repoId}.`,w.body=N.body})},e.getGitHubRepositories=m=>{t.get(`/api/user/${e.userInfo.username}/all_repositories`,{params:{force:"1"}}).then(w=>{e.userInfo.repositories=w.data})};let b=null;e.watch("query",()=>{o.timeout.cancel(b),b=o.timeout(()=>{u(i.username)},500)},!0)},Bu=function(e,t,s){let i=Ct(),o=Ut();e.Math=Math,e.watch("user.status",()=>{e.user==null&&s.url("/")}),e.user==null&&s.url("/"),e.conferences=[],e.total=-1,e.totalPage=0,e.statusCounts=[];let r=N=>{if(N.key==="/"&&!["INPUT","TEXTAREA","SELECT"].includes(document.activeElement?.tagName)){N.preventDefault();let S=document.querySelector('.admin-filter-toolbar input[type="search"]');S&&S.focus()}};o(document,"keydown",r),e.on("dispose",()=>document.removeEventListener("keydown",r)),e.clearFilter=N=>{N==="dateRange"?(e.query.dateFrom="",e.query.dateTo=""):e.query[N]="",e.query.page=1},e.chips=[];let d=()=>{let N=[];(e.query.dateFrom||e.query.dateTo)&&N.push({key:"dateRange",label:"Date",value:(e.query.dateFrom||"\u2026")+" \u2013 "+(e.query.dateTo||"\u2026")}),e.chips=N};e.statusCountFor=N=>{let S=(e.statusCounts||[]).find(R=>R._id===N);return S?S.count:0},e.toggleSortDirection=()=>{e.query.direction=e.query.direction==="asc"?"desc":"asc"},e.sortBy=N=>{e.query.sort===N?e.query.direction=e.query.direction==="asc"?"desc":"asc":(e.query.sort=N,e.query.direction="desc"),e.query.page=1},e.sortIcon=N=>e.query.sort===N?e.query.direction==="asc"?"fa-arrow-up":"fa-arrow-down":"";let p="admin.conferences.filterPrefs",u={page:1,limit:25,sort:"name",direction:"asc",search:"",dateFrom:"",dateTo:"",ready:!0,expired:!0,removed:!0,error:!0,preparing:!0},y=loadFilterPrefs(p)||{};e.query=Object.assign({},u,y,{page:1,search:""});let h=s.search();h.search&&(e.query.search=h.search);let b="admin.conferences.presets";e.presets=JSON.parse(localStorage.getItem(b)||"[]"),e.savePreset=()=>{let N=window.prompt("Preset name:");if(!N)return;let S=Object.assign({},e.query);delete S.page,e.presets=(e.presets||[]).filter(R=>R.name!==N),e.presets.push({name:N,query:S}),localStorage.setItem(b,JSON.stringify(e.presets))},e.applyPreset=N=>{Object.assign(e.query,N.query,{page:1})},e.deletePreset=N=>{e.presets=(e.presets||[]).filter(S=>S.name!==N.name),localStorage.setItem(b,JSON.stringify(e.presets))},e.removeConference=N=>{confirm("Remove conference "+N.conferenceID+"?")&&t.delete("/api/admin/conferences/"+N.conferenceID).then(()=>m(),S=>console.error(S))},e.exportCsv=()=>{let N=new URLSearchParams(Object.entries(e.query).filter(([,S])=>S!==""&&S!==!1&&S!=null));N.set("format","csv"),N.set("limit","10000"),window.open("/api/admin/conferences?"+N.toString(),"_blank")},e.fetchError=null;function m(){e.fetchError=null,t.get("/api/admin/conferences",{params:e.query}).then(N=>{e.total=N.data.total,e.totalPage=Math.ceil(N.data.total/e.query.limit),e.conferences=N.data.results,e.statusCounts=N.data.statusCounts||[]},N=>{e.fetchError=N&&N.data&&N.data.error||"Failed to load conferences",console.error(N)})}Ji(e,{flags:()=>e.query,keys:["ready","preparing","error","expired","removed"],count:N=>e.statusCountFor(N),onChange:()=>{e.query.page=1}}),m();let w=null;e.watch("query",()=>{i.timeout.cancel(w),w=i.timeout(m,500);let{page:N,search:S,...R}=e.query;saveFilterPrefs(p,R),d()},!0),d()},zu=function(e,t,s,i,o){let r=Ct();e.watch("user.status",()=>{e.user==null&&s.url("/")}),e.user==null&&s.url("/"),e.queueList=[],e.jobs=[],e.selectedQueue="download",e.selectedStats=null,e.range="1h",e.allStates=["active","waiting","delayed","failed","completed"],e.stateFilter={active:!0,waiting:!0,delayed:!0,failed:!0,completed:!0},Ji(e,{flags:()=>e.stateFilter,keys:e.allStates,count:R=>(e.jobs||[]).filter(v=>v._state===R).length}),e.query={search:"",autoRefresh:!0},e.filteredJobs=()=>(e.jobs||[]).filter(R=>e.stateFilter[R._state]),e.jobProgressPct=R=>R?._state==="completed"?100:R&&R.progress&&typeof R.progress=="object"&&typeof R.progress.percent=="number"?Math.max(0,Math.min(100,Math.round(R.progress.percent))):typeof R.progress=="number"?Math.max(0,Math.min(100,Math.round(R.progress))):null;let d={get_files:"Fetching files",download:"Downloading",downloading:"Downloading",anonymize:"Anonymizing",anonymizing:"Anonymizing",ready:"Ready",removing:"Removing",preparing:"Preparing"};e.jobDetail=R=>{if(R?._state==="failed")return Yi(R.failedReason||"")||"Failed";let v=R?.progress&&typeof R.progress=="object"?R.progress.status:null;return R?._state==="active"&&v?d[v]||Yi(v):"\u2014"},e.jobDuration=R=>{if(!R.processedOn)return"\u2014";let v=R.finishedOn||Date.now();return qn(v-R.processedOn)},e.metricsPoints=[],e.selectQueue=R=>{e.selectedQueue=R,p(),u()},e.setRange=R=>{e.range=R,u()};function p(){let R={queue:e.selectedQueue,search:e.query.search};t.get("/api/admin/queues",{params:R}).then(v=>{e.queueList=v.data.queues||[],e.jobs=v.data.jobs||[],e.selectedStats=e.queueList.find(E=>E.key===e.selectedQueue)||e.queueList[0]||null},v=>console.error(v))}function u(){t.get("/api/admin/queues/metrics",{params:{queue:e.selectedQueue,range:e.range}}).then(R=>{e.metricsPoints=R.data.points||[],o(w,0)},R=>console.error(R))}p(),u();let y=i(()=>{e.query.autoRefresh&&(p(),u())},15e3);e.on("dispose",()=>i.cancel(y)),e.refreshNow=function(){p(),u()};function h(R){let v=R&&R.data&&(R.data.message||R.data.error)||"Request failed";e.actionError=v,o(()=>{e.actionError=null},5e3),console.error(R)}e.actionError=null,e.removeJob=R=>{t.delete(`/api/admin/queue/${e.selectedQueue}/${R.id}`).then(p,h)},e.retryJob=R=>{t.post(`/api/admin/queue/${e.selectedQueue}/${R.id}`).then(p,h)},e.retryFailed=()=>{confirm(`Retry all failed jobs in ${e.selectedQueue}?`)&&t.post(`/api/admin/queue/${e.selectedQueue}/retry-failed`).then(p,R=>console.error(R))},e.drainSelected=()=>{confirm(`Drain the ${e.selectedQueue} queue?`)&&t.post(`/api/admin/queue/${e.selectedQueue}/drain`).then(p,R=>console.error(R))},e.togglePause=()=>{let R=e.selectedStats&&e.selectedStats.paused?"resume":"pause";t.post(`/api/admin/queue/${e.selectedQueue}/${R}`).then(p,v=>console.error(v))},e.emptyQueue=()=>{confirm(`Empty the ${e.selectedQueue} queue? This removes ALL jobs.`)&&t.post(`/api/admin/queue/${e.selectedQueue}/empty`).then(p,R=>console.error(R))},e.pauseAll=()=>{confirm("Pause all queues?")&&t.post("/api/admin/queues/pause-all").then(p,R=>console.error(R))};let b=null;e.watch("query.search",()=>{r.timeout.cancel(b),b=r.timeout(p,350)}),e.expanded={},e.toggleJob=R=>{e.expanded[R.id]=!e.expanded[R.id]},e.humanTime=R=>{if(!R)return"";let v=new Date(R);return v.toLocaleTimeString([],{hour:"2-digit",minute:"2-digit",second:"2-digit",hour12:!1})+" "+v.toLocaleDateString([],{month:"short",day:"numeric"})},e.delayCountdown=R=>{if(!R)return"";var v=Math.max(0,Math.ceil((R-Date.now())/1e3));if(v<=0)return"resuming soon";var E=Math.floor(v/60),D=v%60;return"in "+(E>0?E+"m "+D+"s":D+"s")};function m(R){if(R<=0)return{ticks:[0],niceMax:1};let v=Math.pow(10,Math.floor(Math.log10(R))),E=v;R/E<2?E=v/2:R/E>5&&(E=v*2);let D=Math.ceil(R/E)*E,V=[];for(let _=0;_<=D;_+=E)V.push(_);return{ticks:V,niceMax:D}}function w(){var R=document.getElementById("q-throughput-chart");if(!R)return;var v=R.getContext("2d"),E=window.devicePixelRatio||1,D=R.parentElement.getBoundingClientRect(),V=44,_=44,z=22,x=Math.max(200,Math.round(D.width)),X=Math.max(180,Math.min(420,Math.round(D.height)||180)),I=x-V-_,U=X-z;R.width=x*E,R.height=X*E,R.style.width=x+"px",R.style.height=X+"px",v.setTransform(E,0,0,E,0,0);var C=document.body.classList.contains("dark-mode"),L="#8A857C",H=C?"rgba(255,255,255,0.06)":"rgba(0,0,0,0.06)",K=C?"#6FBF8A":"#2F7D4F",ie=C?"rgba(111,191,138,0.12)":"rgba(47,125,79,0.08)",se=C?"#F08A82":"#B42318",Y=C?"rgba(240,138,130,0.08)":"rgba(180,35,24,0.06)",me=getComputedStyle(document.body).getPropertyValue("--q-time-series").trim()||(C?"#E0A94A":"#946512"),Se=e.metricsPoints||[];if(Se.length===0){v.fillStyle=L,v.font="13px Inter, system-ui, sans-serif",v.textAlign="center",v.fillText("No metrics data yet",x/2,X/2),N=null;return}var Ue=Se.map(function(we){return we.completed}),Be=Se.map(function(we){return we.failed}),Qe=Se.map(function(we){return we.avgMs});if(!Ue.some(Boolean)&&!Be.some(Boolean)){v.strokeStyle=C?"rgba(255,255,255,0.14)":"rgba(0,0,0,0.12)",v.beginPath(),v.moveTo(0,X-18.5),v.lineTo(x,X-18.5),v.stroke(),v.fillStyle=C?"#CFC8BD":"#4F4A42",v.font="500 14px Inter, system-ui, sans-serif",v.textAlign="center",v.fillText("No jobs processed in this window",x/2,X/2-6),v.fillStyle=L,v.font="12.5px Inter, system-ui, sans-serif",v.fillText("Completed and failed jobs will chart here",x/2,X/2+16),N=null;return}var He=Se.length,et=I/(He-1||1),Re=Math.max(1,Math.max.apply(null,Ue),Math.max.apply(null,Be)),Fe=m(Re),W=Math.max.apply(null,Qe),fe=W>0?m(W):{ticks:[0],niceMax:1},de=function(we){return U-we/Fe.niceMax*(U-10)},ce=function(we){return U-we/fe.niceMax*(U-10)},ve=function(we){return V+we*et};v.textAlign="right",v.textBaseline="middle",v.font="11px Inter, system-ui, sans-serif",Fe.ticks.forEach(function(we){var be=de(we);v.strokeStyle=H,v.lineWidth=1,v.beginPath(),v.moveTo(V,be),v.lineTo(x-_,be),v.stroke(),v.fillStyle=L,we!==0&&v.fillText(we>=1e3?(we/1e3).toFixed(1)+"k":String(we),V-6,be)}),W>0&&(v.textAlign="left",fe.ticks.forEach(function(we){var be=ce(we);v.fillStyle=me,we!==0&&v.fillText(qn(we),x-_+6,be)}));var Me=Se[He-1].ts,A=Se[0].ts,O=Math.max(0,(Me-A)/6e4),F=[1,2,5,10,15,30,60,120,180,360,720,1440,2880,10080],J=F.find(function(we){return O/we<=4})||F[F.length-1],j=function(we){return we<60?we+"m":we<1440?we/60+"h":we/1440+"d"},ee=function(we){for(var be=0,ot=1;ot0&&Math.abs(Se[ke].ts-(Me-te*6e4))>le+1)){var pe=ve(ke),Ee=te===0?"now":j(te)+" ago",Pe=v.measureText(Ee).width,Ve=oe===0?"right":ke===0?"left":"center",Ge=Ve==="right"?pe:Ve==="left"?pe+Pe:pe+Pe/2;Ge>ne-12||(v.textAlign=Ve,v.fillText(Ee,pe,U+6),ne=Ve==="right"?pe-Pe:Ve==="left"?pe:pe-Pe/2)}}function ze(we,be,ot,at){we.length!==0&&(v.beginPath(),v.moveTo(ve(0),U),we.forEach(function(yt,lt){var dt=ve(lt),ft=be(yt);if(lt===0)v.lineTo(dt,ft);else{var Vt=(ve(lt-1)+dt)/2;v.bezierCurveTo(Vt,be(we[lt-1]),Vt,ft,dt,ft)}}),v.lineTo(ve(we.length-1),U),v.closePath(),v.fillStyle=ot,v.fill(),v.beginPath(),we.forEach(function(yt,lt){var dt=ve(lt),ft=be(yt);if(lt===0)v.moveTo(dt,ft);else{var Vt=(ve(lt-1)+dt)/2;v.bezierCurveTo(Vt,be(we[lt-1]),Vt,ft,dt,ft)}}),v.strokeStyle=at,v.lineWidth=1.5,v.stroke())}ze(Ue,de,ie,K),ze(Be,de,Y,se),W>0&&(v.beginPath(),Qe.forEach(function(we,be){var ot=ve(be),at=ce(we);if(be===0)v.moveTo(ot,at);else{var yt=(ve(be-1)+ot)/2;v.bezierCurveTo(yt,ce(Qe[be-1]),yt,at,ot,at)}}),v.strokeStyle=me,v.lineWidth=1,v.setLineDash([4,3]),v.stroke(),v.setLineDash([])),N={pts:Se,maxLen:He,marginLeft:V,step:et,totalW:x,toX:ve}}var N=null;function S(){var R=document.getElementById("q-throughput-chart");if(!(!R||R._tipBound)){R._tipBound=!0;var v=document.getElementById("q-chart-tooltip"),E=document.getElementById("q-chart-crosshair");R.addEventListener("mousemove",function(D){if(!(!N||!v||!E)){var V=N,_=R.getBoundingClientRect(),z=D.clientX-_.left,x=Math.round((z-V.marginLeft)/V.step);if(x<0||x>=V.maxLen){v.style.display="none",E.style.display="none";return}var X=V.pts[x],I=V.pts[V.pts.length-1].ts,U=Math.round((I-X.ts)/6e4),C;if(U<=0)C="now";else if(U<60)C=U+"m ago";else if(U<1440){var L=Math.floor(U/60),H=U%60;C=L+"h"+(H?" "+H+"m":"")+" ago"}else C=Math.round(U/1440)+"d ago";var K='
'+C+'
● completed: '+X.completed+'/min
● failed: '+X.failed+"/min
";if(X.avgMs>0){var ie=qn(X.avgMs);K+='
● avg time: '+ie+"
"}v.innerHTML=K;var se=V.toX(x),Y=v.offsetWidth,me=se+10;me+Y>V.totalW&&(me=se-Y-10),v.style.display="block",v.style.left=me+"px",v.style.top="8px",E.style.display="block",E.style.left=se+"px"}}),R.addEventListener("mouseleave",function(){v&&(v.style.display="none"),E&&(E.style.display="none")})}}e.watch("metricsPoints",function(){o(S,50)})},Hu=function(e,t,s,i){let o=Ct();e.watch("user.status",()=>{e.user==null&&s.url("/")}),e.user==null&&s.url("/"),e.entries=[],e.visible=[],e.available=!0,e.cap=1e3,e.total=0,e.pageSize=250,e.expanded={},e.detailTab={},e.copyHint="",e.parsedFilterCount=0,e.stats={last24h:0,prev24h:0,delta:0,severity:{error:0,warn:0,info:0},unique:{error:0,warn:0,info:0},buckets:[],dropped:0},e.query={search:"",bucket:"",sort:"recent",group:"code",autoRefresh:!0},e.relTime=v=>{if(!v)return"";let E=new Date(v).getTime();if(isNaN(E))return v;let D=Math.max(0,Date.now()-E),V=Math.floor(D/1e3);if(V<5)return"just now";if(V<60)return`${V}s ago`;let _=Math.floor(V/60);if(_<60)return`${_}m ago`;let z=Math.floor(_/60);if(z<24)return`${z}h ago`;let x=Math.floor(z/24);return x<7?`${x}d ago`:new Date(v).toLocaleDateString(void 0,{year:"numeric",month:"short",day:"numeric"})},e.absTime=v=>{if(!v)return"";let E=new Date(v);return isNaN(E.getTime())?v:E.toLocaleString(void 0,{year:"numeric",month:"short",day:"numeric",hour:"2-digit",minute:"2-digit"})},e.absTimeShort=v=>{if(!v)return"";let E=new Date(v);return isNaN(E.getTime())?v:E.toLocaleTimeString([],{hour:"2-digit",minute:"2-digit",second:"2-digit",hour12:!1})};let r=/^[a-zA-Z][a-zA-Z0-9]*(?:_[a-zA-Z0-9]+)+$/;function d(v,E){let D=v&&(v.httpStatus||v.status)||null;if(typeof D=="number"){if(D>=500)return"error";if(D===401||D===403||D===404)return"info";if(D>=400)return"warn"}return E==="error"?"error":E==="warn"?"warn":"info"}function p(v){let E=(v.raw||[]).find(z=>z&&typeof z=="object"&&!Array.isArray(z));if(E){E.message&&r.test(E.message)?(v.displayMessage=E.message,v.displayContext=v.message):E.code&&r.test(String(E.code))?(v.displayMessage=String(E.code),v.displayContext=v.message):E.name&&E.name!=="AnonymousError"&&E.name!=="Error"?(v.displayMessage=E.name,v.displayContext=E.message||v.message):v.displayMessage=v.message,v._status=E.httpStatus||E.status||null,v._url=E.url||null,v._method=E.method||null,v._repoId=E.repoId||E.detail||null,v._detail=E.detail&&E.detail!==v._repoId?E.detail:null;let z=typeof E.stack=="string"?E.stack:null;for(var D=[E.cause,E.err].filter(Boolean),V=0;!z&&V{I==null||I===""||D.push([X,I])};V("name",E&&E.name),V("code",v.displayMessage||E&&E.message),v._bucket&&V("kind",v._bucket),V("httpStatus",E&&E.httpStatus),E&&E.status&&!E.httpStatus&&V("status",E.status),V("module",v.module);let _=E&&E.detail;if(typeof _=="string"){let X=_.trim();if(X[0]==="{"||X[0]==="[")try{_=JSON.parse(_)}catch{}}if(V("detail",_),V("repoId",E&&E.repoId),V("filePath",E&&E.filePath),V("upstreamStatus",E&&E.upstreamStatus),V("upstreamBody",E&&E.upstreamBody),V("url",v._url),V("err",E&&E.err),V("cause",E&&!E.err&&E.cause),V("ts",v.ts),!D.length)return JSON.stringify(v,null,2);let z=D.reduce((X,I)=>Math.max(X,I[0].length),0),x=["{"];return D.forEach(([X,I],U)=>{let L=` ${`"${X}":`.padEnd(z+3," ")} `,H=UY===0?se:ie+se).join(` -`)}else typeof O=="number"||typeof O=="boolean"?K=String(O):K=JSON.stringify(O);te.push(`${L}${K}${z}`)}),te.push("}"),te.join(` -`)}function y(v){let E=[],M="",V=/(\w+):(>=|<=|!=|>|<|=)?([^\s]+)/g,_=0,G;for(;G=V.exec(v);)M+=v.slice(_,G.index),_=V.lastIndex,E.push({key:G[1],op:G[2]||"=",val:G[3]});return M+=v.slice(_),{filters:E,free:M.trim().toLowerCase()}}function m(v,E){for(let M of E.filters){let V=(G,te,X)=>{let O=parseFloat(G),U=parseFloat(te);return X==="="?String(G)===String(te):X==="!="?String(G)!==String(te):X===">="?O>=U:X==="<="?O<=U:X===">"?O>U:X==="<"?OE&&X._bucket!==E?!1:m(X,v)),V=e.query.group;if(V){let X=C=>V==="module"?C.module:C.displayMessage||C.message||"_",O=new Map;for(let C of M){let L=X(C);if(O.has(L)){let z=O.get(L);z.count++,z._related.push(C),new Date(C.ts)>new Date(z.ts)&&(z.ts=C.ts,z._url=C._url,z._status=C._status),new Date(C.ts)new Date(L.ts).getTime()>=U).length;M=Array.from(O.values())}else M=M.map((X,O)=>(X._key="row:"+O+":"+X.ts,X._related=[X],X._firstSeen=X.ts,X._lastHourCount=0,X.count=1,X));let _=X=>({error:0,warn:1,info:2})[X._bucket]??1;e.query.sort==="count"?M.sort((X,O)=>_(X)-_(O)||O.count-X.count||new Date(O.ts)-new Date(X.ts)):M.sort((X,O)=>_(X)-_(O)||new Date(O.ts)-new Date(X.ts)),e.visible=M;let G=!!(e.query.bucket||(e.query.search||"").trim()),te=!G&&(e.stats?.severity?.error||0)>0&&!M.some(X=>X._bucket==="error")&&e.entries.length<1500;(G&&!M.length||te)&&e.canLoadMore?.()&&!e._autoLoading&&e.entries.length<2500&&(e._autoLoading=!0,h(!0))}function h(v){let E=v?e.entries.length:0,M=v?e.pageSize:Math.max(e.pageSize,e.entries.length||e.pageSize);t.get("/api/admin/errors",{params:{offset:E,limit:M}}).then(V=>{let _=(V.data.entries||[]).map(p);e.entries=v?e.entries.concat(_):_,e.available=!!V.data.available,e.cap=V.data.max||e.cap,e.total=V.data.total||e.entries.length,e._autoLoading=!1,b()},V=>{e._autoLoading=!1,console.error(V)})}e.loadMore=()=>h(!0),e.canLoadMore=()=>e.entries.length{let E=v.data||{},M=E.prev24h?Math.round((E.last24h-E.prev24h)/E.prev24h*100):0;e.stats={last24h:E.last24h||0,prev24h:E.prev24h||0,delta:M,severity:E.severity||{error:0,warn:0,info:0},unique:E.unique||{error:0,warn:0,info:0},buckets:E.buckets||[],dropped:E.dropped||0},b()},v=>console.error(v))}function R(){h(),w()}e.barPx=(v,E)=>{let M=e.stats.buckets||[],V=0,_=0;for(let O of M)V=Math.max(V,(O.error||0)+(O.warn||0)),_=Math.max(_,O.info||0);let G=v[E]||0;if(!G)return 0;if(E==="info")return _?Math.max(2,Math.round(G/_*(V?16:60))):0;let te=(v.error||0)+(v.warn||0),X=Math.round(te/V*44);return Math.max(4,Math.round(G/te*X))},e.bucketTitle=v=>`${new Date(v.hour).toLocaleTimeString([],{hour:"2-digit",minute:"2-digit"})} \xB7 ${v.error||0} err \xB7 ${v.warn||0} warn \xB7 ${v.info||0} info`,e.toggle=v=>{e.expanded[v._key]=!e.expanded[v._key]},e.setBucket=v=>{e.query.bucket=v},e.refreshNow=R,e.clearAll=()=>{confirm("Clear all captured errors?")&&t.delete("/api/admin/errors").then(R,v=>console.error(v))},e.exportCsv=()=>{let v=["ts","level","module","displayMessage","_status","_url","_repoId"],E=[v.join(",")];for(let G of e.visible)E.push(v.map(te=>{let X=G[te]==null?"":String(G[te]);return/[",\n]/.test(X)?`"${X.replace(/"/g,'""')}"`:X}).join(","));let M=new Blob([E.join(` -`)],{type:"text/csv;charset=utf-8"}),V=URL.createObjectURL(M),_=document.createElement("a");_.href=V,_.download=`errors-${new Date().toISOString().slice(0,19)}.csv`,document.body.appendChild(_),_.click(),document.body.removeChild(_),URL.revokeObjectURL(V)};function S(v){e.copyHint=`${v} copied`,o.timeout(()=>{e.copyHint=""},1500)}e.copyJson=v=>{navigator.clipboard.writeText(v._detailJson).then(()=>S("JSON"))},e.copyCurl=v=>{if(!v._url)return;let M=`curl -X ${v._method||"GET"} '${window.location.origin}${v._url}'`;navigator.clipboard.writeText(M).then(()=>S("curl"))},R();let N=i(()=>{e.query.autoRefresh&&R()},15e3);e.on("dispose",()=>i.cancel(N)),e.watch("query.search",b),e.watch("query.bucket",b),e.watch("query.sort",b),e.watch("query.group",b)},ju=function(e,t,s,i){if(e.Math=Math,e.watch("user.status",()=>{e.user==null&&s.url("/")}),e.user==null){s.url("/");return}e.data=null,e.loading=!0,e.error=null,e.performance=null,e.performanceMinutes=15,e.performanceTab="routes",e.cacheReport=null,e.cacheError=null,e.cacheMinutes=60,e.cacheTraffic="all",e.ovView=["performance","cache"].includes((window.location.hash||"").slice(1))?window.location.hash.slice(1):"summary",e.setOvView=function(v){e.ovView=v;try{window.history.replaceState(null,"",v==="summary"?window.location.pathname:"#"+v)}catch{}};var o=!1;e.loadCache=function(){if(!o){o=!0;var v=e.cacheMinutes;t.get("/api/admin/cache",{params:{minutes:v}}).then(function(E){v===e.cacheMinutes&&(e.cacheReport=E.data,e.cacheError=E.data.available?null:E.data.reason||"Cache monitoring is unavailable.")},function(){e.cacheError="Could not refresh cache monitoring. Displayed values may be stale."}).finally(function(){o=!1,v!==e.cacheMinutes&&e.loadCache()})}},e.cacheRows=function(){return(e.cacheReport?.rows||[]).filter(function(v){return e.cacheTraffic==="all"||v.traffic===e.cacheTraffic})},e.cacheRate=function(v,E){var M=e.cacheRows(),V=function(te){return M.filter(function(X){return X.name===te}).reduce(function(X,O){return X+O[E]},0)},_=V(v+"_hit"),G=V(v+"_miss");return _+G?(100*_/(_+G)).toFixed(1)+"%":"No samples"},e.cacheEventName=function(v){return v.replaceAll("_"," ")},e.cacheP95=function(v){var E=0,M=e.cacheReport?.latencyBucketsMs||[];if(!v.count)return"No samples";if(!v.ms)return"Not timed";for(var V=0;V<=M.length;V++)if(E+=v["b"+V]||0,E>=Math.ceil(v.count*.95))return V 10\u202Fs";return"No samples"},e.healthAlert=function(){let v=e.data&&e.data.system||{},E=[["Memory",v.memPercent],["Disk",v.diskPercent]].filter(([,V])=>V>90);return E.length?E.map(([V,_])=>V+" is at "+_+"%").join(" and ")+". New anonymizations may fail until "+(E.length>1?"they drop.":"it drops."):""},e.performanceError=null,e.formatMs=function(v){return v==null?"":qn(v)},e.latencyBound=function(v,E){return v.count?v[E]==null?"> 60\u202Fs":"\u2264 "+e.formatMs(v[E]):"No samples"},e.firstByteBound=function(v){return e.latencyBound({count:v.firstByteCount,p95UpperMs:v.firstByteP95UpperMs},"p95UpperMs")},e.sampleAge=function(v){return Math.max(0,Math.round((Date.now()-v.sampledAt)/1e3))},e.peakRss=function(v){return(e.performance.runtimeSeries||[]).filter(function(E){return E.instance===v.instance}).reduce(function(E,M){return Math.max(E,M.rss)},v.memory.rss)},e.performanceWarning=function(v){return e.sampleAge(v)>45||v.droppedBatches||v.droppedMetrics||v.sockets?.closeWait>0||v.eventLoop?.p95Ms>100||v.memoryLimitBytes&&v.memory.rss>v.memoryLimitBytes*.8};var r=!1;e.loadPerformance=function(){var v=e.performanceMinutes;e.performance?.windowMinutes&&e.performance.windowMinutes!==v&&(e.performance=null),!r&&(r=!0,t.get("/api/admin/performance",{params:{minutes:v}}).then(function(E){v===e.performanceMinutes&&(e.performance=E.data,e.performanceError=E.data.available?null:"Performance monitoring is unavailable. Request history may be incomplete.")},function(){v===e.performanceMinutes&&(e.performanceError="Could not refresh performance monitoring. Displayed samples may be stale.")}).finally(function(){r=!1,v!==e.performanceMinutes&&e.loadPerformance()}))};function d(v){if(v==null)return"\u2014";for(var E=["B","KB","MB","GB","TB"],M=0,V=v;V>=1024&&M0?1:0).replace(/\.0$/,"")+" "+E[M]}e.humanBytes=d;function p(v){if(!v)return"\u2014";var E=Math.floor(v/86400),M=Math.floor(v%86400/3600),V=Math.floor(v%3600/60);return E>0?E+"d "+(M<10?"0":"")+M+"h":M>0?M+"h "+(V<10?"0":"")+V+"m":V+"m"}e.humanDuration=p;function u(v){return v==null?"\u2014":v>=1e6?(v/1e6).toFixed(1)+"M":v>=1e3?(v/1e3).toFixed(1)+"K":String(v)}e.humanNum=u,e.queueTotal=function(v){return v?(v.waiting||0)+(v.active||0)+(v.delayed||0)+(v.failed||0):0},e.statusCount=function(v){if(!e.data||!e.data.repos)return 0;for(var E=e.data.repos.statusBreakdown||[],M=0;M0,zero:!V,title:String(_.getHours()).padStart(2,"0")+":00 \xB7 "+(M.error||0)+" 5xx, "+(M.warn||0)+" 4xx"}})},e.errorHoursPeak=function(){var v=e.errorStats&&e.errorStats.buckets||[];return v.reduce(function(E,M){return Math.max(E,(M.error||0)+(M.warn||0))},0)};function y(v){var E=v||[];return E.map(function(M,V){var _=E[V-1]||{},G=Object.assign({},M);return G.dailyRepositories=V?Math.max(0,(M.nbRepositories||0)-(_.nbRepositories||0)):0,G.dailyUsers=V?Math.max(0,(M.nbUsers||0)-(_.nbUsers||0)):0,G.dailyPageViews=V?Math.max(0,(M.nbPageViews||0)-(_.nbPageViews||0)):0,G})}function m(v){var E=v&&v.length?v[v.length-1]:{};return{repositories:E.dailyRepositories||0,users:E.dailyUsers||0,pageViews:E.dailyPageViews||0}}function b(v,E){if(!v||!v.length)return v;var M=new Date(v[v.length-1].date);if(isNaN(M))return v;var V={};v.forEach(function(O){V[new Date(O.date).toISOString().slice(0,10)]=O});for(var _=[],G=E-1;G>=0;G--){var te=new Date(M.getTime()-G*864e5),X=te.toISOString().slice(0,10);_.push(V[X]||{date:te.toISOString(),_empty:!0,dailyPageViews:0,dailyRepositories:0,dailyUsers:0,nbUsers:0})}return _}var h={};e.historyMax=function(v){return h[v]||0};var w={};e.axisMax=function(v){var E=h[v]||0;if(E<=2)return 2;if(E<=10)return Math.ceil(E/2)*2;var M=Math.pow(10,Math.floor(Math.log10(E)));return Math.ceil(E/M)*M},e.historyBarH=function(v,E){return!v||!h[E]||!v[E]?0:Math.max(1,Math.round(v[E]/e.axisMax(E)*140))},e.historyRange=function(v){return{min:w[v],max:h[v]}};var R=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"];e.historyLabel=function(v){if(!v||!v.date)return"";var E=new Date(v.date);return R[E.getUTCMonth()]+" "+E.getUTCDate()},e.historyHasMissing=function(){return!!(e.data&&e.data.history||[]).some(function(v){return v&&v._empty})},e.firstDataIndex=function(){for(var v=e.data&&e.data.history||[],E=0;E=M)return{lo:X,hi:X+2*G[te]}}return{lo:0,hi:e.axisMax("nbUsers")}},e.userStepPath=function(v){var E=e.data&&e.data.history||[],M=e.userAxis(),V=h.nbUsers?M.hi-M.lo:0,_=e.firstDataIndex();if(!V||_>=E.length)return"";for(var G=function(U){return(140-((U||0)-M.lo)/V*140).toFixed(2)},te=v?"M"+_+" 140":"",X=_;Xh[M])&&(h[M]=E[M]),(w[M]==null||E[M] .meta-more"),s=[...e.querySelectorAll(":scope > .meta-item")];if(s.forEach(o=>{o.removeAttribute("data-meta-hidden")}),t&&(t.hidden=!0,t.textContent="",t.removeAttribute("title"),t.removeAttribute("aria-label")),!e.clientWidth)return;if(e.classList.add("is-fitting"),e.scrollWidth<=e.clientWidth+1){e.classList.remove("is-fitting");return}let i=[];for(let o=s.length-1;o>=0&&e.scrollWidth>e.clientWidth+1;o--)if(s[o].setAttribute("data-meta-hidden",""),i.unshift(s[o]),t){let r=i.map(d=>d.dataset.metaLabel||d.textContent.trim().replace(/\s+/g," "));t.hidden=!1,t.textContent="+"+i.length,t.title=r.join(" \xB7 "),t.setAttribute("aria-label",i.length+" more: "+r.join(", "))}e.classList.remove("is-fitting")}function Gu(e,t){if(typeof document>"u"||typeof MutationObserver>"u"||!document.body)return;let s=!1,i=null,o=()=>{s=!1,i&&(document.querySelectorAll("[data-meta-fit]").forEach(kg),i.takeRecords())},r=()=>{!s&&i&&(s=!0,e.timeout(o,30))};i=new MutationObserver(d=>{d.some(p=>!(p.target.closest&&p.target.closest(".meta-more")))&&r()}),i.observe(document.body,{childList:!0,subtree:!0,characterData:!0}),es(()=>{i.disconnect(),i=null}),t(window,"resize",r),document.fonts?.ready&&document.fonts.ready.then(r),r()}var Cg=["bif","clp","djf","gnf","jpy","kmf","krw","mga","pyg","rwf","ugx","vnd","vuv","xaf","xof","xpf"],_u=[{id:"subscription",label:"Subscriptions"},{id:"repository",label:"Repository purchases"},{id:"conference",label:"Conferences"}],Eg={author_monthly:"Author monthly",author_annual:"Author annual",author_pass:"Live updates",repo_extend:"Extended expiration",repo_never:"Never expire",repo_slot:"Extra repository",repo_pack:"Paper pack",conference_workshop:"Workshop",conference:"Conference",conference_large:"Large conference"};function Lu(e){return Object.entries(e||{}).filter(([,t])=>t).sort((t,s)=>s[1]-t[1]).map(([t,s])=>{let i=Cg.includes(t)?s:s/100;try{return new Intl.NumberFormat(void 0,{style:"currency",currency:t.toUpperCase(),minimumFractionDigits:i%1?2:0,maximumFractionDigits:2}).format(i)}catch{return i+" "+t.toUpperCase()}})}var Wu=function(e,t,s){let i=Ct();if(e.Math=Math,e.watch("user.status",()=>{e.user==null&&s.url("/")}),e.user==null){s.url("/");return}e.families=_u,e.periods=[{id:"7d",label:"7 days"},{id:"30d",label:"30 days"},{id:"90d",label:"90 days"},{id:"12m",label:"12 months"},{id:"all",label:"All time"}];let o=(()=>{try{return localStorage.getItem("admin.billing.period")}catch{return null}})();e.period=e.periods.some(h=>h.id===o)?o:"30d",e.summary=null,e.summaryError=null,e.summaryLoading=!0,e.periodLabel=()=>(e.periods.find(h=>h.id===e.period)||{}).label||"",e.periodPhrase=()=>e.period==="all"?"all time":"last "+e.periodLabel(),e.money=h=>Lu(h),e.moneyText=(h,w="\u2014")=>Lu(h).join(" \xB7 ")||w,e.revenueOn=()=>!!e.summary?.revenue?.available,e.planName=h=>((e.summary?.plans||[]).find(w=>w.planId===h)||{}).name||Eg[h]||h,e.bucketTotal=h=>h?h.subscription+h.repository+h.conference:0,e.chartMax=()=>{let h=Math.max(0,...(e.summary?.series||[]).map(e.bucketTotal));if(h<=4)return 4;let w=Math.pow(10,Math.floor(Math.log10(h)));return[1,1.2,1.5,2,2.5,3,4,5,6,8,10].map(R=>R*w).find(R=>R>=h&&R%2===0)||10*w},e.segmentPct=(h,w)=>h&&h[w]?h[w]/e.chartMax()*100:0,e.familyTotal=h=>(e.summary?.series||[]).reduce((w,R)=>w+R[h],0),e.bucketLabel=h=>{if(!h)return"";let w=new Date(h.date),R={timeZone:"UTC",day:"numeric",month:"short"};return e.summary?.bucket==="month"?w.toLocaleDateString(void 0,{timeZone:"UTC",month:"short",year:"numeric"}):((e.period==="12m"||e.period==="all"||w.getUTCFullYear()!==new Date().getUTCFullYear())&&(R.year="numeric"),(e.summary?.bucket==="week"?"Week of ":"")+w.toLocaleDateString(void 0,R))},e.bucketTip=h=>{let w=e.bucketTotal(h);if(!w)return e.bucketLabel(h)+": no sales";let R=_u.filter(S=>h[S.id]).map(S=>h[S.id]+" "+S.label.toLowerCase());return e.bucketLabel(h)+": "+w+(w===1?" sale":" sales")+" ("+R.join(", ")+")"},e.bucketName=()=>({day:"day",week:"week",month:"month"})[e.summary?.bucket]||"day",e.seriesSales=()=>(e.summary?.series||[]).reduce((h,w)=>h+e.bucketTotal(w),0),e.plansWithActivity=()=>(e.summary?.plans||[]).filter(h=>h.active||h.allTimeSales||h.sales),e.planTotals=()=>{let h=w=>(e.summary?.plans||[]).reduce((R,S)=>R+(S[w]||0),0);return{active:h("active"),sales:h("sales"),allTimeSales:h("allTimeSales")}},e.webhookState=()=>{let h=e.summary?.webhooks;return h?h.failed||h.reconciliationFailed?"bad":h.oldestPendingSeconds>900||h.unreviewedRevocations?"warn":"ok":"ok"},e.age=h=>h?qn(h*1e3):"\u2014";let r=0;e.loadSummary=()=>{let h=++r;e.summaryLoading=!0,e.summaryError=null,t.get("/api/admin/billing/summary",{params:{period:e.period}}).then(w=>{if(h!==r)return;e.summaryLoading=!1;let R=w.data;if(!R||!R.subscriptions||!R.sales||!Array.isArray(R.plans)){e.summaryError="The billing summary had an unexpected format.";return}e.summary=R},w=>{h===r&&(e.summaryLoading=!1,e.summaryError=w&&w.data&&w.data.error||"Could not load billing figures.")})},e.setPeriod=h=>{if(e.period!==h){e.period=h;try{localStorage.setItem("admin.billing.period",h)}catch{}e.loadSummary()}},e.grants=[],e.total=-1,e.totalPage=0,e.stateCounts={},e.statuses=[],e.grantsError=null,e.filtersOpen=!1,e.query={page:1,limit:25,search:"",plan:"",status:"",state:"",sort:"purchasedAt",direction:"desc"};let d=s.search();d.search&&(e.query.search=d.search),e.stateView=()=>e.query.state||"all",e.setStateView=h=>{e.query.state=h==="all"?"":h,e.query.page=1},e.stateCount=h=>h==="all"?["active","expired","revoked"].reduce((w,R)=>w+(e.stateCounts[R]||0),0):e.stateCounts[h]||0,e.sortBy=h=>{e.query.sort===h?e.query.direction=e.query.direction==="asc"?"desc":"asc":(e.query.sort=h,e.query.direction="desc"),e.query.page=1},e.sortIcon=h=>e.query.sort===h?e.query.direction==="asc"?"fa-arrow-up":"fa-arrow-down":"",e.chips=[];let p=()=>{let h=[];e.query.plan&&h.push({key:"plan",label:"Plan",value:e.planName(e.query.plan)}),e.query.status&&h.push({key:"status",label:"Stripe status",value:e.query.status.replace(/_/g," ")}),e.chips=h};e.clearFilter=h=>{e.query[h]="",e.query.page=1},e.filterPlan=h=>{Object.assign(e.query,{plan:h,page:1});let w=document.getElementById("bl-grants");w&&w.scrollIntoView&&w.scrollIntoView({behavior:"smooth",block:"start"})},e.clearFilters=()=>Object.assign(e.query,{search:"",plan:"",status:"",state:"",page:1}),e.hasFilters=()=>!!(e.query.search||e.query.plan||e.query.status||e.query.state),e.statusText=h=>(h.status||"unknown").replace(/_/g," "),e.revocationText=h=>h==="dispute"?"Disputed":h==="full_refund"?"Refunded":"Revoked",e.scopeHref=h=>h?.kind==="repo"?"/admin/repositories?search="+encodeURIComponent(h.id):h?.kind==="conference"?"/conference/"+encodeURIComponent(h.id):null;let u=0;function y(){let h=++u;e.grantsError=null;let w=Object.fromEntries(Object.entries(e.query).filter(([,R])=>R!==""&&R!=null));t.get("/api/admin/billing/grants",{params:w}).then(R=>{h===u&&(e.total=R.data?.total??0,e.totalPage=Math.ceil(e.total/e.query.limit),e.grants=R.data?.results||[],e.stateCounts=R.data.stateCounts||{},e.statuses=R.data.statuses||[])},R=>{h===u&&(e.grantsError=R&&R.data&&R.data.error||"Could not load subscriptions and purchases.")})}e.reloadGrants=y,e.loadSummary(),y(),p();let m=null,b=JSON.stringify({...e.query,page:0});e.watch("query",()=>{let h=JSON.stringify({...e.query,page:0});if(h!==b&&e.query.page!==1){b=h,e.query.page=1;return}b=h,i.timeout.cancel(m),m=i.timeout(y,300),p()},!0)},Ku=function(e,t,s){if(e.user==null){s.url("/");return}e.emailRows=[],e.emailState="",e.emailKind="",e.emailLoading=!1,e.emailError="",e.emailAnnouncement="",e.emailNextCursor=null,e.emailStatusLabel=d=>({sending:"Outcome pending",accepted:"Accepted",rejected:"Rejected",unknown:"Unknown outcome"})[d]||d,e.emailKindLabel=d=>d==="repository-expiration"?"Repository expiration":"GitHub access",e.emailTime=d=>d?new Date(d).toLocaleString(void 0,{year:"numeric",month:"short",day:"numeric",hour:"2-digit",minute:"2-digit",timeZoneName:"short"}):"Not recorded",e.hasEmailFilters=()=>!!(e.emailState||e.emailKind),e.clearEmailFilters=()=>(e.emailState="",e.emailKind="",e.loadEmails());let i=0,o="",r=!1;e.on("dispose",()=>{i++}),e.retryEmails=()=>e.loadEmails(r),e.loadEmails=async(d=!1)=>{let p=JSON.stringify([e.emailState,e.emailKind]),u=p!==o;if(o=p,u&&(d=!1),d&&(e.emailLoading||!e.emailNextCursor))return;let y=++i;e.emailLoading=!0,e.emailError="",e.emailAnnouncement=d?"Loading older emails.":"Loading email history.",u&&(e.emailRows=[],e.emailNextCursor=null);try{let m=await t.get("/api/admin/emails",{params:{state:e.emailState||void 0,kind:e.emailKind||void 0,before:d?e.emailNextCursor:void 0}});if(y!==i)return;e.emailRows=d?e.emailRows.concat(m.data.entries):m.data.entries,e.emailNextCursor=m.data.nextCursor,e.emailAnnouncement=`Email history loaded. ${e.emailRows.length} attempts shown.`}catch{y===i&&(r=d,e.emailError=d?"Could not load older emails. Your loaded history is still shown.":e.emailRows.length?"Could not refresh email history. Previously loaded results are still shown.":"Could not load email history.",e.emailAnnouncement="")}finally{y===i&&(e.emailLoading=!1)}},e.loadEmails()};var ka=(e,t,s)=>{let i=e instanceof RegExp?Yu(e,s):e,o=t instanceof RegExp?Yu(t,s):t,r=i!==null&&o!=null&&Ng(i,o,s);return r&&{start:r[0],end:r[1],pre:s.slice(0,r[0]),body:s.slice(r[0]+i.length,r[1]),post:s.slice(r[1]+o.length)}},Yu=(e,t)=>{let s=t.match(e);return s?s[0]:null},Ng=(e,t,s)=>{let i,o,r,d,p,u=s.indexOf(e),y=s.indexOf(t,u+1),m=u;if(u>=0&&y>0){if(e===t)return[u,y];for(i=[],r=s.length;m>=0&&!p;){if(m===u)i.push(m),u=s.indexOf(e,m+1);else if(i.length===1){let b=i.pop();b!==void 0&&(p=[b,y])}else o=i.pop(),o!==void 0&&o=0?u:y}i.length&&d!==void 0&&(p=[r,d])}return p};var Xu="\0SLASH"+Math.random()+"\0",Ju="\0OPEN"+Math.random()+"\0",Na="\0CLOSE"+Math.random()+"\0",Qu="\0COMMA"+Math.random()+"\0",Zu="\0PERIOD"+Math.random()+"\0",Rg=new RegExp(Xu,"g"),Ag=new RegExp(Ju,"g"),Pg=new RegExp(Na,"g"),Dg=new RegExp(Qu,"g"),Tg=new RegExp(Zu,"g"),Og=/\\\\/g,Ig=/\\{/g,Mg=/\\}/g,Vg=/\\,/g,qg=/\\\./g,_g=1e5,Lg=4e6,$g=1e3,Fg=1e3;function Ca(e){return isNaN(e)?e.charCodeAt(0):parseInt(e,10)}function Ug(e){return e.replace(Og,Xu).replace(Ig,Ju).replace(Mg,Na).replace(Vg,Qu).replace(qg,Zu)}function Bg(e){return e.replace(Rg,"\\").replace(Ag,"{").replace(Pg,"}").replace(Dg,",").replace(Tg,".")}function Ea(e,t){for(let s=0;s=t}function Lo(e,t,s,i,o,r){let d=[],p=0;for(let u=0;u=i)return d;let m=e[u]+t+s[y];if(!(r&&!m)){if(p+m.length>o)return d;d.push(m),p+=m.length}}return d}function Kg(e,t,s,i){let o=e.split(/\.\./),r=[];if(o[0]===void 0||o[1]===void 0)return r;let d=Ca(o[0]),p=Ca(o[1]),u=Math.max(o[0].length,o[1].length),y=o.length===3&&o[2]!==void 0?Math.max(Math.abs(Ca(o[2])),1):1,m=Gg;p0){let v=new Array(N+1).join("0");R<0?S="-"+v+S.slice(1):S=v+S}}if(w+S.length>i)break;r.push(S),w+=S.length}return r}function Sa(e,t,s,i,o,r,d){if(o>i)return[e];let p=[""],u=0,y=!1,m=!0;for(;;){let b=ka("{","}",e);if(!b)return Lo(p,e,[""],t,s,y);let h=b.pre;if(/\$$/.test(h)){if(p=Lo(p,h+"{"+b.body+"}",[""],t,s,y&&!b.post.length),m=!1,!b.post.length)break;e=b.post;continue}let w=/^-?\d+\.\.-?\d+(?:\.\.-?\d+)?$/.test(b.body),R=/^[a-zA-Z]\.\.[a-zA-Z](?:\.\.-?\d+)?$/.test(b.body),S=w||R,N=b.body.indexOf(",")>=0;if(!S&&!N){if(u=t||V+X.length>s)break e;v.push(X),V+=X.length}}}}if(p=Lo(p,h,v,t,s,y&&!b.post.length),!b.post.length)break;e=b.post}return p}var Yg={"[:alnum:]":["\\p{L}\\p{Nl}\\p{Nd}"],"[:alpha:]":["\\p{L}\\p{Nl}"],"[:ascii:]":["\\x00-\\x7f"],"[:blank:]":["\\p{Zs}\\t"],"[:cntrl:]":["\\p{Cc}"],"[:digit:]":["\\p{Nd}"],"[:graph:]":["\\p{Z}\\p{C}",!0],"[:lower:]":["\\p{Ll}"],"[:print:]":["\\p{C}",!0],"[:punct:]":["\\p{P}\\p{S}"],"[:space:]":["\\p{Z}\\t\\r\\n\\v\\f"],"[:upper:]":["\\p{Lu}"],"[:word:]":["\\p{L}\\p{Nl}\\p{Nd}\\p{Pc}"],"[:xdigit:]":["A-Fa-f0-9"]},$o=e=>e.replace(/[[\]\\-]/g,"\\$&"),Ra=/$./,ec=(e,t,s=!1,i)=>{let o=v=>{let E=i?v.normalize(i):v;return[...E].length===1?E:v},r=t;if(e.charAt(r)!=="[")throw new Error("not in a brace expression");let d=[],p=[],u=r+1,y=!1,m=!1,b=!1,h=r,w="";e:for(;uw.codePointAt(0)?d.push($o(w)+"-"+$o(E)):E===w&&d.push($o(E)),w="",u+=v.length;continue}if(e.startsWith("-]",u+v.length)){d.push($o(E+"-")),u+=v.length+1;continue}if(e.startsWith("-",u+v.length)){w=E,u+=v.length+1;continue}d.push($o(E)),u+=v.length}if(h({t:"lit",ch:e}),Jg=e=>e.replace(/[\\^$.*+?()[\]{}|/]/g,"\\$&"),oc=e=>new RegExp(`^${Jg(e)}$`,"iu"),Qi=new Map,ic=e=>{let t=Qi.get(e);return t||(t=oc(e),Qi.size>=1e3&&Qi.clear(),Qi.set(e,t)),t},Ma=(e,t)=>{if(t===e.ch)return!0;if(!e.re)return!1;let s=t.charCodeAt(0);if(s>=128)return e.re.test(t);let i=e.ascii??(e.ascii=new Uint8Array(128));return i[s]||(i[s]=e.re.test(t)?1:2),i[s]===1},Qg=(e,t,s,i)=>{let o=[];for(let r=0;r{let t=new Map,s=[];return e.forEach((i,o)=>{i.t==="open"?s.push(o):i.t==="close"&&s.length&&t.set(s.pop(),o)}),t},rc=(e,t,s,i,o)=>{let r=[],d=[r];for(let p=s;p{let s=[],i="",o=()=>{for(let r of i.normalize(t))s.push(us(r));i=""};for(let r of e){if(r.t==="lit"){i+=r.ch;continue}o(),s.push(r.t==="ext"?{...r,alts:r.alts.map(d=>ac(d,t))}:r)}return o(),s},xg=(e,t)=>{let s=1,i=p=>({t:"split",id:s++,out:p}),o=(p,u)=>p.reduceRight((y,m)=>r(m,y),u),r=(p,u)=>{switch(p.t){case"lit":let h=t?ic(p.ch):void 0;return{t:"lit",id:s++,ch:p.ch,re:h,next:u};case"any":case"star":return{t:p.t,id:s++,next:u};case"class":return{t:"class",id:s++,re:p.re,next:u}}let y=h=>p.alts.map(w=>o(w,h));switch(p.type){case"@":return i(y(u));case"?":return i([u,...y(u)]);case"!":return{t:"neg",id:s++,sub:i(y(Aa)),next:u}}let m=i([]),b=i(y(m));return m.out.push(u,b),p.type==="*"?m:b};return[o(e,Aa),s]},ev=e=>{let t=[],s=new Set,i=r=>r.t==="match"?"match":String(r.id),o=(r,d)=>{if(r.t==="match"||s.has(r))return;s.add(r);let p=u=>t.push(`${d}${r.id}: ${u}`);switch(r.t){case"split":p(`split -> ${r.out.map(i).join(", ")}`);for(let u of r.out)o(u,d);return;case"neg":return p(`!(${i(r.sub)}) -> ${i(r.next)}`),o(r.sub,d+" "),o(r.next,d);case"lit":p(`${JSON.stringify(r.ch)} -> ${i(r.next)}`);break;case"class":p(`${r.re} -> ${i(r.next)}`);break;default:p(`${r.t==="any"?"?":"*"} -> ${i(r.next)}`)}o(r.next,d)};return o(e,""),[`start -> ${i(e)}`,...t].join(` -`)},Pa=class{constructor(t){xe(this,"gen");xe(this,"threads",[]);xe(this,"match",!1);xe(this,"runs",[]);xe(this,"ids",[]);this.gen=t}get dead(){return!this.threads.length&&!this.match&&!this.runs.length}},lc=(e,t)=>e.ids.length!==t.ids.length||e.runs.length!==t.runs.length||e.ids.some((s,i)=>s!==t.ids[i])?!1:e.runs.every(s=>t.runs.some(i=>i.neg===s.neg&&lc(i.state,s.state))),tc=e=>({has:new Float64Array(e),seen:new Float64Array(e),gen:0}),cs,Bn,Da,Ta,Uo=class{constructor(t,s,i){qe(this,Bn);xe(this,"dots");xe(this,"dotStart");qe(this,cs);this.dots=t,this.dotStart=s,$e(this,cs,i)}state(){return new Pa(++re(this,cs).gen)}done(t){return t.ids=t.threads.map(s=>s.id).sort((s,i)=>s-i),t.match&&t.ids.unshift(Aa.id),t}restricted(t,s){return s&&(this.dots||this.dotStart&&t===0)}add(t,s,i,o){switch(s.t){case"split":if(!_e(this,Bn,Da).call(this,t,s))return;for(let d of s.out)this.add(t,d,i,o);return;case"neg":if(!_e(this,Bn,Da).call(this,t,s))return;let r=this.state();return this.add(r,s.sub,i,!1),this.done(r),this.addRun(t,{t:"run",neg:s,state:r},i,o);case"star":if(this.restricted(i,o))return;_e(this,Bn,Ta).call(this,t,s)&&this.add(t,s.next,i,o);return;case"match":t.match=!0;return;default:_e(this,Bn,Ta).call(this,t,s)}}addRun(t,s,i,o){for(let r of t.runs)if(r.neg===s.neg&&lc(r.state,s.state))return;t.runs.push(s),s.state.match||this.add(t,s.neg.next,i,o)}step(t,s,i,o){let r=this.state();for(let d of t.threads)switch(d.t){case"lit":Ma(d,s)&&this.add(r,d.next,i+1,o);break;case"any":this.restricted(i,o)||this.add(r,d.next,i+1,o);break;case"class":!this.restricted(i,o)&&d.re.test(s)&&this.add(r,d.next,i+1,o);break;case"star":this.restricted(i,o)||this.add(r,d,i+1,o)}if(!this.restricted(i,o))for(let d of t.runs){if(d.state.dead){this.addRun(r,d,i+1,o);continue}let p=this.step(d.state,s,i,!1);this.addRun(r,{t:"run",neg:d.neg,state:p},i+1,o)}return this.done(r)}};cs=new WeakMap,Bn=new WeakSet,Da=function(t,s){let{seen:i}=re(this,cs);return i[s.id]===t.gen?!1:(i[s.id]=t.gen,!0)},Ta=function(t,s){let{has:i}=re(this,cs);return i[s.id]===t.gen?!1:(i[s.id]=t.gen,t.threads.push(s),!0)};var dc=e=>{let t=e.ids.join();if(!e.runs.length)return t;let s=e.runs.map(i=>`${i.neg.id}(${dc(i.state)})`);return`${t}|${s.sort().join("|")}`},tv=1<<18,Bs,zs,_n,ps,Ln,$n,Fn,sn,Ia,xi,uc,Oa=class{constructor(t,s){qe(this,sn);qe(this,Bs);qe(this,zs,new Map);qe(this,_n,0);qe(this,ps);qe(this,Ln);qe(this,$n);qe(this,Fn);$e(this,Bs,t),$e(this,$n,new Uo(!1,!1,s)),$e(this,Fn,new Uo(!1,!0,s))}start(t){if(t){if(re(this,Ln))return re(this,Ln);let i=re(this,Fn).state();return re(this,Fn).add(i,re(this,Bs),0,!0),$e(this,Ln,_e(this,sn,Ia).call(this,re(this,Fn).done(i)))}if(re(this,ps))return re(this,ps);let s=re(this,$n).state();return re(this,$n).add(s,re(this,Bs),0,!0),$e(this,ps,_e(this,sn,xi).call(this,re(this,$n).done(s)))}next(t,s){let i=s.charCodeAt(0),o=i<128?void 0:t.next.get(s);if(o)return o;let r=t===re(this,Ln)?_e(this,sn,xi).call(this,re(this,Fn).step(t.state,s,0,!0)):_e(this,sn,xi).call(this,re(this,$n).step(t.state,s,1,!0));return i<128?(t.ascii||(t.ascii=new Array(128),$e(this,_n,re(this,_n)+128)),t.ascii[i]=r):t.next.set(s,r),nl(this,_n)._++,r}};Bs=new WeakMap,zs=new WeakMap,_n=new WeakMap,ps=new WeakMap,Ln=new WeakMap,$n=new WeakMap,Fn=new WeakMap,sn=new WeakSet,Ia=function(t){return{state:t,match:t.match,dead:t.dead,next:new Map}},xi=function(t){let s=dc(t),i=re(this,zs).get(s);if(i)return i;re(this,_n)>tv&&_e(this,sn,uc).call(this);let o=_e(this,sn,Ia).call(this,t);return re(this,zs).set(s,o),$e(this,_n,re(this,_n)+(s.length+1)),o},uc=function(){re(this,zs).clear(),$e(this,_n,0),$e(this,ps,void 0),$e(this,Ln,void 0)};var nv=e=>{let t=[];for(let s=e;s.t!=="match";s=s.next){if(s.t==="split"||s.t==="neg")return;t.push(s)}return t},sv=(e,t,s,i)=>{let o=0,r=s,d=-1,p=0;for(;r{let t=0,s=0;for(let i of e){let[o,r]=ov(i);t+=o,s+=r}return[t,s]},ov=e=>{if(e.t==="star")return[0,1/0];if(e.t!=="ext")return[1,1];if(e.type==="!")return[0,1/0];let t=e.alts.map(cc),s=Math.min(...t.map(r=>r[0])),i=Math.max(...t.map(r=>r[1])),o=i===0?0:1/0;return e.type==="@"?[s,i]:e.type==="?"?[0,i]:e.type==="*"?[0,o]:[s,o]},nc=(e,t,s)=>{for(let i=0;irv.test(e)?[...e]:e,sc=e=>{if(e.includes("/"))throw new Error("can only match a single path portion, got: "+e)},Un,Hs,fs,er,hs,zo,tr,ms,Ho,jo,Go,An,vn,js,Gs,Wo,nr,nn,gs,Fo,Bo=class{constructor(t,s={}){qe(this,gs);xe(this,"pattern");xe(this,"options");qe(this,Un);qe(this,Hs);qe(this,fs);qe(this,er);qe(this,hs);qe(this,zo,!1);qe(this,tr);qe(this,ms);qe(this,Ho,!1);qe(this,jo,0);qe(this,Go,1/0);qe(this,An,[]);qe(this,vn,[]);qe(this,js);qe(this,Gs);qe(this,Wo,!1);qe(this,nr);qe(this,nn);if(t.includes("/"))throw new Error("can only match a single path portion, got pattern: "+t);this.pattern=t,this.options=s;let{nocase:i=!1,noext:o=!1,normalize:r}=s;$e(this,nn,r===!0?"NFC":r||void 0);let d=/^[?*+@]\(\)$/.test(t),p=Qg(t,i,o||d,re(this,nn)),[u]=rc(p,Zg(p),0,p.length,!0);re(this,nn)&&(u=ac(u,re(this,nn)));let[y,m]=xg(u,i);if($e(this,Un,y),$e(this,Hs,m),u.every(b=>b.t==="lit"))$e(this,hs,u.map(b=>b.ch).join("")),$e(this,zo,i);else{let b=R=>R.t!=="lit"?void 0:i?{ch:R.ch,re:ic(R.ch)}:{ch:R.ch};for(let R of u){let S=b(R);if(!S)break;re(this,An).push(S)}for(let R=u.length-1;R>=0;R--){let S=b(u[R]);if(!S)break;re(this,vn).unshift(S)}$e(this,Wo,!!(re(this,An).length||re(this,vn).length)),i||($e(this,js,re(this,An).map(R=>R.ch).join("")),$e(this,Gs,re(this,vn).map(R=>R.ch).join(""))),$e(this,ms,nv(re(this,Un))?.slice(re(this,An).length,-re(this,vn).length||void 0)),$e(this,Ho,!!re(this,ms)?.every(R=>R.t==="star"||R.t==="any"));let[h,w]=cc(u);$e(this,jo,h),$e(this,Go,w)}}test(t){return re(this,nn)?(sc(t),_e(this,gs,Fo).call(this,t.normalize(re(this,nn)))):iv.test(t)?(sc(t),_e(this,gs,Fo).call(this,t,[...t])):_e(this,gs,Fo).call(this,t,t)}testUnchecked(t){return _e(this,gs,Fo).call(this,re(this,nn)?t.normalize(re(this,nn)):t)}toString(){return ev(re(this,Un))}};Un=new WeakMap,Hs=new WeakMap,fs=new WeakMap,er=new WeakMap,hs=new WeakMap,zo=new WeakMap,tr=new WeakMap,ms=new WeakMap,Ho=new WeakMap,jo=new WeakMap,Go=new WeakMap,An=new WeakMap,vn=new WeakMap,js=new WeakMap,Gs=new WeakMap,Wo=new WeakMap,nr=new WeakMap,nn=new WeakMap,gs=new WeakSet,Fo=function(t,s){if(re(this,hs)!==void 0)return re(this,zo)?(re(this,tr)??$e(this,tr,oc(re(this,hs)))).test(t):t===re(this,hs);let i=re(this,jo),o=re(this,Go);if(s===void 0){let m=t.length,b=m+1>>1;if(mo)return!1;(bo)&&(s=Zi(t))}if(s!==void 0&&(s.lengtho))return!1;let r=re(this,An).length;if(re(this,Wo))if(re(this,js)!==void 0&&re(this,Gs)!==void 0){if(!t.startsWith(re(this,js))||!t.endsWith(re(this,Gs)))return!1}else{s??(s=Zi(t));let m=s.length-re(this,vn).length;if(!nc(re(this,An),s,0)||!nc(re(this,vn),s,m))return!1}let d=!this.options.dot&&t.startsWith(".");if(re(this,ms)){if(t==="."||t===".."||d&&!r)return!1;if(re(this,Ho))return!0;s??(s=Zi(t));let m=s.length-re(this,vn).length;return sv(re(this,ms),s,r,m)}if(s??(s=Zi(t)),t==="."||t===".."){re(this,fs)??$e(this,fs,tc(re(this,Hs)));let m=re(this,er)??$e(this,er,new Uo(!0,!1,re(this,fs))),b=m.state();m.add(b,re(this,Un),0,!0);let h=m.done(b);for(let w=0;w{if(typeof e!="string")throw new TypeError("invalid pattern");if(e.length>65536)throw new TypeError("pattern is too long")};var zn=(e,{windowsPathsNoEscape:t=!1,magicalBraces:s=!1}={})=>s?t?e.replace(/[?*()[\]{}]/g,"[$&]"):e.replace(/[?*()[\]\\{}]/g,"\\$&"):t?e.replace(/[?*()[\]]/g,"[$&]"):e.replace(/[?*()[\]\\]/g,"\\$&");var vs=(e,{windowsPathsNoEscape:t=!1,magicalBraces:s=!0}={})=>s?t?e.replace(/\[([^/\\])\]/g,"$1"):e.replace(/((?!\\).|^)\[([^/\\])\]/g,"$1$2").replace(/\\([^/])/g,"$1"):t?e.replace(/\[([^/\\{}])\]/g,"$1"):e.replace(/((?!\\).|^)\[([^/\\{}])\]/g,"$1$2").replace(/\\([^/{}])/g,"$1");var zt=(e,t,s={})=>(Ko(t),!s.nocomment&&t.charAt(0)==="#"?!1:lv(t,s).match(e)),Ws=new Map,av=256,lv=(e,t)=>{let s=e+"\0"+JSON.stringify(t),i=Ws.get(s);return i?Ws.delete(s):(i=new ys(e,{...t}),Ws.size>=av&&Ws.delete(Ws.keys().next().value)),Ws.set(s,i),i},vc=typeof process=="object"&&process?process.env?.__MINIMATCH_TESTING_PLATFORM__||process.platform:"posix",pc={win32:{sep:"\\"},posix:{sep:"/"}},dv=vc==="win32"?pc.win32.sep:pc.posix.sep;zt.sep=dv;var vt=Symbol("globstar **");zt.GLOBSTAR=vt;var uv=(e,t={})=>s=>zt(s,e,t);zt.filter=uv;var Pn=(e,t={})=>Object.assign({},e,t),cv=e=>{if(!e||typeof e!="object"||!Object.keys(e).length)return zt;let t=zt;return Object.assign((i,o,r={})=>t(i,o,Pn(e,r)),{Minimatch:class extends t.Minimatch{constructor(o,r={}){super(o,Pn(e,r))}static defaults(o){return t.defaults(Pn(e,o)).Minimatch}},unescape:(i,o={})=>t.unescape(i,Pn(e,o)),escape:(i,o={})=>t.escape(i,Pn(e,o)),filter:(i,o={})=>t.filter(i,Pn(e,o)),defaults:i=>t.defaults(Pn(e,i)),braceExpand:(i,o={})=>t.braceExpand(i,Pn(e,o)),match:(i,o,r={})=>t.match(i,o,Pn(e,r)),sep:t.sep,GLOBSTAR:vt})};zt.defaults=cv;var yc=(e,t={})=>(Ko(e),t.nobrace||!/\{(?:(?!\{).)*\}/.test(e)?[e]:xu(e,{max:t.braceExpandMax}));zt.braceExpand=yc;var pv=(e,t,s={})=>{let i=new ys(t,s);return e=e.filter(o=>i.match(o)),i.options.nonull&&!e.length&&e.push(t),e};zt.match=pv;var fc=/[?*]|[+@!]\(.*?\)|\[|\]/,bc=(e,t)=>{let s=t+1;(e.charAt(s)==="!"||e.charAt(s)==="^")&&s++;let i=!1;for(;s{if(!t&&(e==="+()"||e==="@()"))return e;let s="";for(let i=0;i{if(/^[?*+@]\(\)$/.test(e)||e.includes("[:"))return!1;let t=0;for(let s=0;stypeof e=="string"?t===e:t!==""&&e.testUnchecked(t),mc=(e,t,s,i,o)=>Hn(e,t)?s:i!==void 0&&Hn(e,i)?o:-1,$a=e=>e==="."||e==="..",qa=e=>typeof e=="string"&&/^[a-z]:$/i.test(e),or=e=>typeof e=="string"&&/^unc$/i.test(e),_a=e=>{if(e[0]!==""||e[1]!=="")return-1;let t=e[2]!=="?"?2:or(e[3])?4:-1,s=e[t],i=e[t+1];return t!==-1&&s!==void 0&&s!==""&&s!==vt&&i!==void 0&&i!==""&&i!==vt?t:-1},sr=(e,t)=>!$a(e)&&(t||!e.startsWith(".")),Yo=(e,t,s,i,o)=>{for(let r=t;r=s||rr(e.charCodeAt(p),o))return!0}let d=Fa(e,r,o);if(d===-1)return!1;for(r=d+1;rt==="/"?e===47:t==="\\"?e===92:e===47||e===92,Fa=(e,t,s)=>{if(s!=="both")return e.indexOf(s,t);let i=e.indexOf("/",t),o=e.indexOf("\\",t);return i===-1?o:o===-1?i:Math.min(i,o)},gc=(e,t,s)=>s!=="both"?e.lastIndexOf(s,t):Math.max(e.lastIndexOf("/",t),e.lastIndexOf("\\",t)),La={},jn,Ys,Gn,Dn,Xs,Js,Wn,Jo,Qs,Qo,Le,ir,Xo,wc,kc,Cc,Ec,Sc,Nc,Ua,Rc,Ac,Ba,Ks,za,ys=class{constructor(t,s={}){qe(this,Le);xe(this,"options");xe(this,"set");xe(this,"pattern");xe(this,"windowsPathsNoEscape");xe(this,"nonegate");xe(this,"negate");xe(this,"comment");xe(this,"empty");xe(this,"preserveMultipleSlashes");xe(this,"partial");xe(this,"globSet");xe(this,"globParts");xe(this,"nocase");xe(this,"isWindows");xe(this,"platform");xe(this,"windowsNoMagicRoot");xe(this,"maxGlobstarRecursion");qe(this,jn);qe(this,Ys);qe(this,Gn);qe(this,Dn);qe(this,Xs,[]);qe(this,Js,[]);qe(this,Wn,[]);qe(this,Jo,new Map);qe(this,Qs,!1);qe(this,Qo,new WeakMap);Ko(t),s=s||{},this.options=s,this.maxGlobstarRecursion=s.maxGlobstarRecursion??200,this.pattern=t,this.platform=s.platform||vc,this.isWindows=this.platform==="win32";let i="allowWindowsEscape";this.windowsPathsNoEscape=!!s.windowsPathsNoEscape||s[i]===!1,this.windowsPathsNoEscape&&(this.pattern=this.pattern.replace(/\\/g,"/")),this.preserveMultipleSlashes=!!s.preserveMultipleSlashes,this.negate=!1,this.nonegate=!!s.nonegate,this.comment=!1,this.empty=!1,this.partial=!!s.partial,this.nocase=!!this.options.nocase,this.windowsNoMagicRoot=s.windowsNoMagicRoot!==void 0?s.windowsNoMagicRoot:!!(this.isWindows&&this.nocase),this.globSet=[],this.globParts=[],this.set=[],$e(this,jn,!this.preserveMultipleSlashes),$e(this,Gn,(s.optimizationLevel??1)>=2);let o=s.normalize;$e(this,Dn,o===!0?"NFC":o||void 0),this.make();let r=this.set.map(d=>_e(this,Le,Xo).call(this,d));$e(this,Wn,this.set.map((d,p)=>re(this,jn)&&d.length-1>r[p])),$e(this,Xs,this.set.map((d,p)=>{let u=re(this,Wn)[p]?d.length-1:d.length,y=d.slice(r[p]+1,u).filter(m=>typeof m=="string"&&!!m);return[...new Set(y)]})),$e(this,Ys,re(this,Xs).some(d=>d.length)),$e(this,Js,this.set.map((d,p)=>{let[u,y,m]=d;if(re(this,Wn)[p]&&d.length===2&&u===vt&&y!==vt)return"tail";if(re(this,Wn)[p]&&s.matchBase&&d.length===1&&u!==vt&&u!=="")return"base";if(!(!re(this,jn)||r[p]!==-1)){if(d.length===3&&u===vt&&m===vt&&y!==vt&&y!==""&&this.maxGlobstarRecursion>0)return"mid";if(d.length===2&&y===vt&&u!==vt&&u!=="")return"head"}}))}hasMagic(){if(this.options.magicalBraces&&this.set.length>1)return!0;for(let t of this.set)for(let s of t)if(typeof s!="string")return!0;return!1}make(){let t=this.pattern,s=this.options;if(!s.nocomment&&t.charAt(0)==="#"){this.comment=!0;return}if(!t){this.empty=!0;return}this.parseNegate(),this.globSet=[...new Set(this.braceExpand())];let i=this.globSet.map(r=>_e(this,Le,za).call(this,r));this.globParts=this.preprocess(i),$e(this,Qs,!0);let o=this.globParts.map((r,d,p)=>{if(this.isWindows&&this.windowsNoMagicRoot){let u=r[2]==="?"&&or(r[3])?6:4,y=r[0]===""&&r[1]===""&&(r[2]==="?"||!fc.test(r[2]))&&r.slice(3,u).every(b=>!fc.test(b)),m=/^[a-z]:/i.test(r[0]);if(y)return[...r.slice(0,u).map(b=>_e(this,Le,ir).call(this,b)),...r.slice(u).map(b=>this.parse(b))];if(m)return[_e(this,Le,ir).call(this,r[0]),...r.slice(1).map(b=>this.parse(b))]}return r.map(u=>this.parse(u))});if(this.set=o.filter(r=>r.indexOf(!1)===-1),this.isWindows)for(let r=0;r{for(let p=0;pi.length));for(let i=0;i{if(!(d[i]instanceof Bo||d[i]===La)||!hv(this.globParts[p][i]))return;let u=[...this.globParts[p]];u[i]="";let y=`${d.length}/${u.join("/")}`,m=o.get(y);m?m.push(p):o.set(y,[p])});let r=new Set;for(let d of o.values()){if(d.length<2)continue;let[p,...u]=d,m=`@(${d.map(b=>this.globParts[b][i]).join("|")})`;this.globParts[p][i]=m,this.set[p][i]=this.parse(m);for(let b of u)r.add(b)}r.size&&(t=!0,this.set=this.set.filter((d,p)=>!r.has(p)),this.globParts=this.globParts.filter((d,p)=>!r.has(p)))}}}preprocess(t){if(this.options.noglobstar)for(let i of t)for(let o=0;o=2?(t=this.firstPhasePreProcess(t),t=this.secondPhasePreProcess(t)):s>=1?t=this.levelOneOptimize(t):t=this.adjascentGlobstarOptimize(t),t}adjascentGlobstarOptimize(t){return t.map(s=>{let i=-1;for(;(i=s.indexOf("**",i+1))!==-1;){let o=i;for(;s[o+1]==="**";)o++;o!==i&&s.splice(i,o-i)}return s})}levelOneOptimize(t){return t.map(s=>{let i=_e(this,Le,Xo).call(this,s)+1;return s=s.reduce((o,r)=>{let d=o[o.length-1];return r==="**"&&d==="**"?o:r===".."&&o.length>i&&d&&d!==".."&&d!=="."&&d!=="**"?(o.pop(),o):(o.push(r),o)},[]),s.length===0?[""]:s})}firstPhasePreProcess(t){let{braceExpandMax:s=1e5}=this.options,i=!1;do{i=!1;for(let o of t){let r=-1;for(;(r=o.indexOf("**",r+1))!==-1;){let u=r;for(;o[u+1]==="**";)u++;u>r&&o.splice(r+1,u-r);let y=o[r+1],m=o[r+2],b=o[r+3];if(y!==".."||!m||m==="."||m===".."||!b||b==="."||b===".."||t.length>=s)continue;i=!0,o.splice(r,1);let h=o.slice(0);h[r]="**",t.push(h),r--}if(!this.preserveMultipleSlashes){for(let u=1;u1e3)return t;for(let s=0;ss.length)}partsMatch(t,s,i=!1){let o=0,r=0,d=[],p="";for(;o=0;y--)u=r[y];for(let y=0;y=0){let v=S;for(;v>0&&rr(t.charCodeAt(v-1),s);)v--;p=v===0?0:gc(t,v-1,s)+1,d=t.slice(p,v)}let N=re(this,Gn)&&($a(o)||o===""&&d!==void 0&&$a(d));i=N?-1:1,h=!N}let w=-1;if(h&&typeof b=="string"&&(w=mc(b,o,r,d,p),w===-1))continue;if(re(this,Ys)){for(let S of re(this,Xs)[y])if(!t.includes(S))continue e}if(h&&typeof b=="object"&&(w=mc(b,o,r,d,p),w===-1))continue;let R=re(this,Js)[y];if(R==="base"&&h)return"yes";if(R==="tail"&&h){if(re(this,Gn)&&Yo(t,0,w,!0,s))return"maybe";if(!Yo(t,0,w,u,s))return"yes";continue}if(R==="mid"||R==="head"){let S=_e(this,Le,Cc).call(this,t,m,R==="head",u,s);if(S!=="no")return S;continue}return"maybe"}return"no"},kc=function(t,s,i){let o=!!this.options.dot,r=t.length;if(i==="head"){if(r<2||!Hn(s[0],t[0]))return!1;for(let p=1;pp&&d.testUnchecked(t.slice(p,u)))&&!Yo(t,y,t.length,o,r))return"yes";if(i||Yo(t,p,y,o,r))return"no";p=y}return"no"},Ec=function(t){let s=Va;return s?.f===t&&s.isWindows===this.isWindows&&s.preserveMultipleSlashes===this.preserveMultipleSlashes&&s.normalize===re(this,Dn)?s:void 0},Sc=function(t){let{isWindows:s,preserveMultipleSlashes:i}=this,o=_e(this,Le,za).call(this,s?t.split("\\").join("/"):t),r=re(this,Dn);return r&&(o=o.map(d=>d.normalize(r))),Va={f:t,isWindows:s,preserveMultipleSlashes:i,normalize:r,parts:o},Va},Nc=function(t){let s=[...t],i=!1;do{if(i=!1,!this.preserveMultipleSlashes){for(let d=1;dt.length)return!1;let b=t.length-u.length;if(_e(this,Le,Ks).call(this,t,u,i,b,0))m=u.length;else{if(t[t.length-1]!==""||o+u.length===t.length||(b--,!_e(this,Le,Ks).call(this,t,u,i,b,0)))return!1;m=u.length+1}}if(!p.length){let b=!!m;for(let h=o;h{v[1]=R-S[E]});let N={head:y,body:m,tail:b,segments:h};return o[r]=N,N},Ba=function(t,s,i,o,r,d,p,u,y){let m=s[r];if(!m){if(d)return o>=i||o===i-1&&t[o]==="";for(let R=o;Re.lastIndexOf(t)===s)}function ja(e){let t=(e||[]).filter(s=>typeof s=="string"&&s.length>0).map(s=>{let{negated:i,anchored:o,directoryOnly:r,body:d}=mv(s);return{negated:i,directoryOnly:r,matcher:new ys(d,{dot:!0,nonegate:!0,nocomment:!0,matchBase:!o&&!d.includes("/")})}});return(s,i=!1)=>{let o=(s||"").replace(/^\/+/,"");if(!o)return!1;let r=o.split("/"),d=r.slice(0,-1).map((u,y)=>r.slice(0,y+1).join("/")),p=i;for(let u of t){if(u.negated?!p:p)continue;(u.directoryOnly?d:[...d,o]).some(m=>u.matcher.match(m))&&(p=!u.negated)}return p}}var eee=new Set("^$\\.*+?()[]{}|/dDsSwWbBnrtvf0cxupP".split(""));function Ga(e){let t=e.indexOf("=>");if(t<0)return{term:e,replacement:null};let s=e.slice(0,t).replace(/\s+$/,""),i=e.slice(t+2).replace(/^\s+/,"");return s?{term:s,replacement:i}:{term:e,replacement:null}}var Pc=new Set(["*","+","?","(",")","[","]","{","}","|","^","$"]);function Dc(e){let t=[];return String(e||"").split(` -`).forEach((s,i)=>{let{term:o}=Ga(s.trim());if(!o)return;let r=[];for(let d=0;d{let t=e.target;if(!t||t.tagName!=="IMG"||t.dataset.failed||!t.closest?.(".markdown-body, .anonymize-preview-body"))return;t.dataset.failed="1";let s=window.document.createElement("span"),i=parseInt(t.getAttribute("width"),10)||0,o=parseInt(t.getAttribute("height"),10)||0;s.className=i>=200||o>=120?"img-unavailable is-large":"img-unavailable",s.textContent="Image unavailable",s.title=t.alt?"Image unavailable: "+t.alt.replace(/\bXXXX-(\d+)\b/g,"[redacted term $1]"):"Image unavailable",s.setAttribute("role","img"),s.setAttribute("aria-label",s.title),t.replaceWith(s)},!0);function ar(e){let t=e?.data;if(typeof t=="string")try{t=JSON.parse(t)}catch{t=null}return typeof t?.error=="string"&&Object.prototype.hasOwnProperty.call(Kn.ERRORS,t.error)?t.error:e?.status===-1||e?.status===0?"request_error":[502,503,504].includes(e?.status)?"unreachable":"unknown_error"}var lr="XXXX",vv=e=>{lr=e||"XXXX"},yv=(e=lr)=>{if(!e)return null;let t=e.replace(/[.*+?^${}()|[\]\\]/g,"\\$&");return new RegExp(t+"(?:-\\d+)?","g")},Oc=(e,t=lr)=>{let s=yv(t);if(!s||!e||!e.textContent.includes(t))return;let i=e.ownerDocument,o=i.createTreeWalker(e,NodeFilter.SHOW_TEXT),r=[];for(;o.nextNode();)r.push(o.currentNode);for(let d of r){let p=d.nodeValue,u=d.parentElement;if(!p.includes(t)||!u||u.closest("script, style, mark.redaction, .mermaid"))continue;let y=u.closest('code[class*="language-"]');if(y&&!y.contains(e))continue;let m=i.createDocumentFragment(),b=0;for(let h of p.matchAll(s)){m.append(p.slice(b,h.index));let w=i.createElement("mark");w.className="redaction",w.title="Redacted by Anonymous GitHub",w.textContent=h[0],m.append(w),b=h.index+h[0].length}m.append(p.slice(b)),d.replaceWith(m)}},Zo=/\bXXXX-\d+\b/g,_o=function(e){if(!e||e.indexOf("XXXX-")===-1||typeof window.DOMParser!="function")return e;let t=new window.DOMParser().parseFromString("
"+e+"
","text/html"),s=t.createTreeWalker(t.body,4),i=[];for(;s.nextNode();)Zo.lastIndex=0,!s.currentNode.parentElement?.closest("pre code")&&Zo.test(s.currentNode.nodeValue)&&i.push(s.currentNode);for(let o of i){Zo.lastIndex=0;let r=t.createDocumentFragment(),d=0,p,u=o.nodeValue;for(;p=Zo.exec(u);){r.appendChild(t.createTextNode(u.slice(d,p.index)));let y=t.createElement("mark");y.className="redact-chip",y.setAttribute("title","Redacted term "+p[0].slice(5)+" \u2014 the same term everywhere in this snapshot");let m=p[0].slice(5);y.textContent="";let b=t.createElement("i");b.textContent=m,y.appendChild(b),y.dataset.term=p[0],y.setAttribute("aria-label","Redacted term "+m);let h=/^[.,;:!?)\]]+/.exec(u.slice(p.index+p[0].length));if(h){let w=t.createElement("span");w.className="redact-glue",w.appendChild(y),w.appendChild(t.createTextNode(h[0])),r.appendChild(w),d=p.index+p[0].length+h[0].length}else r.appendChild(y),d=p.index+p[0].length}r.appendChild(t.createTextNode(u.slice(d))),o.parentNode.replaceChild(r,o)}return t.body.firstChild.innerHTML},Ic=()=>{window.Prism?.hooks&&!window.Prism.redactionHook&&(window.Prism.hooks.add("complete",e=>{Oc(e.element),e.element.querySelectorAll?.("mark.redaction").forEach(t=>{let s=/^XXXX-(\d+)$/.exec(t.textContent);if(!s)return;t.className="redact-chip",t.setAttribute("title","Redacted term "+s[1]+" \u2014 the same term everywhere in this snapshot"),t.setAttribute("aria-label","Redacted term "+s[1]),t.dataset.term=s[0],t.style.setProperty("--slot-ch",s[0].length+"ch"),t.textContent="";let i=t.ownerDocument.createElement("span");i.className="redact-src",i.textContent=s[0].slice(0,s[0].length-s[1].length),t.appendChild(i);let o=t.ownerDocument.createElement("i");o.textContent=s[1],t.appendChild(o)})}),window.Prism.redactionHook=!0)},Mc=(e,t=lr)=>{if(!e||!t||!e.includes(t))return e;let s=new DOMParser().parseFromString(""+e+"","text/html");return Oc(s.body,t),s.body.innerHTML};async function Wa(e){if(window.navigator.clipboard?.writeText){await window.navigator.clipboard.writeText(e);return}let t=document.createElement("textarea");t.value=e,t.setAttribute("readonly",""),t.style.position="fixed",t.style.opacity="0";let s=document.activeElement;document.body.appendChild(t);try{if(t.select(),!document.execCommand?.("copy"))throw Error("Copy unavailable")}finally{t.remove(),s?.focus()}}function bv(e){if(!["ArrowLeft","ArrowRight","Home","End"].includes(e.key))return;let t=[...e.currentTarget.closest('[role="tablist"]').querySelectorAll('[role="tab"]')],s=t.indexOf(e.currentTarget),i=e.key==="Home"?0:e.key==="End"?t.length-1:(s+(e.key==="ArrowRight"?1:-1)+t.length)%t.length;e.preventDefault(),t[i]?.focus(),t[i]?.click()}var Vc=function(e,t,s,i){e.previewTabKeydown=bv,e.headerCanUpgrade=!1,e.headerShowSupport=!1,e.headerBillingPending=new URLSearchParams(window.location.search).get("billing")==="success";let o=N=>{e.headerShowSupport=!(N?.grants||[]).some(E=>["active","paid","past_due"].includes(E.status)&&new Date(E.until).getTime()>Date.now());let v=(N?.grants||[]).some(E=>["author_monthly","author_annual"].includes(E.planId)&&["active","paid","past_due"].includes(E.status)&&new Date(E.until).getTime()>Date.now());e.headerCanUpgrade=!!N?.enabled&&N.checkoutEnabled!==!1&&!v&&(N.plans||[]).some(E=>["author_monthly","author_annual"].includes(E.id))};e.on("billing:updated",(N,v)=>o(v)),e.on("billing:pending",(N,v)=>{e.headerBillingPending=v}),e.openHeaderUpgrade=()=>{s.path()==="/profile"?e.emit("settings:upgrade"):s.url("/profile?upgrade=1")};let r=Bt(),d=Ct(),p=!1,u=()=>{p=!1;let N=document.querySelector("nav.navbar.navbar-expand-lg");if(!N||(N.classList.remove("nav-fit-1","nav-fit-2"),window.innerWidth<992))return;let v=N.querySelector(".navbar-collapse"),E=()=>N.scrollWidth>N.clientWidth+1||!!v&&v.scrollWidth>v.clientWidth+1;E()&&N.classList.add("nav-fit-1"),E()&&N.classList.add("nav-fit-2")},y=()=>{p||(p=!0,tt(()=>d.timeout(u,0)))};r(window,"resize",y),e.on("routeChange",y),e.on("billing:updated",y),document.fonts?.ready&&document.fonts.ready.then(y).catch(()=>{}),e.title="Main",e.user={status:"connection"},e.site_options,e.toasts=[],e.removeToast=function(N){let v=e.toasts.indexOf(N);v!==-1&&e.toasts.splice(v,1)},e.addToast=function(N){return e.toasts.push(N),i(function(){e.removeToast(N)},8e3),N};let m=/^\/(r|repository|pr|gist)\//;e.path=s.url(),e.paths=s.path().substring(1).split("/"),e.isReviewerRoute=m.test(s.path()),e.darkMode=function(N){localStorage.setItem("darkMode",N),e.isDarkMode=N;let v="/css/prism.css";if($("link[href='/css/prism-okaidia.css']").remove(),N)$("body").addClass("dark-mode"),$(`link[href='${v}']`).remove();else if($("body").removeClass("dark-mode"),!document.querySelector(`link[href='${v}']`)){let E=document.createElement("link");E.href=v,E.rel="stylesheet",document.head.append(E)}e.emit("dark-mode",N)},e.darkMode(localStorage.getItem("darkMode")=="true"),e.emailPromptOpen=!1,e.emailPromptAddress="",e.emailPromptBusy=!1,e.emailPromptError="";let b;e.respondToEmailPrompt=async N=>{if(!e.emailPromptBusy){e.emailPromptBusy=!0,e.emailPromptError="";try{let v=await t.post("/github/connections/email",{action:N,email:e.emailPromptAddress},{headers:{"X-CSRF-Token":e.user.emailPromptCSRF}});N==="save"&&(e.user.notificationEmail=v.data.notificationEmail),e.emailPromptOpen=!1,e.user.showEmailPrompt=!1,b?.focus()}catch(v){e.emailPromptError=v.data?.error||"Unable to save your preference. Please try again."}finally{e.emailPromptBusy=!1}}};function h(){t.get("/api/user").then(N=>{N&&(e.user=N.data),y(),e.user?.username?Wi(t).then(v=>o(v.data)).catch(()=>{}):e.headerShowSupport=!0,e.user?.emailNotificationsEnabled&&e.user.showEmailPrompt&&!e.user.notificationEmail&&(b=document.activeElement,e.emailPromptOpen=!0,i(()=>{let v=document.getElementById("email-prompt");v?.showModal?v.showModal():v?.setAttribute("open",""),document.getElementById("email-prompt-address")?.focus()},0))},()=>{e.user=null,e.headerShowSupport=!0})}h();function w(){t.get("/api/options").then(N=>{N&&(e.site_options=N.data),vv(N?.data?.ANONYMIZATION_MASK),e.emit("site-options")},()=>{e.site_options=null})}w();function R(){t.get("/api/message").then(N=>{N&&(e.generalMessage=N.data)},()=>{e.generalMessage=null})}R();function S(N,v){v&&(e.title=v.title),e.path=s.url(),e.paths=s.path().substring(1).split("/"),e.isReviewerRoute=m.test(s.path())}e.on("routeChange",S),e.on("routeUpdate",S)},qc=function(e,t){let s=Bt(),i=Ct();e.faqQuery="",e.faqResults=0;let o=d=>(d||"").toLowerCase().normalize("NFD").replace(/[\u0300-\u036f]/g,"").replace(/\s+/g," ");e.filterFaq=()=>{let d=o(e.faqQuery).trim().split(" ").filter(Boolean),p=0;document.querySelectorAll(".faq-section .panel-group").forEach(u=>{let y=0;u.querySelectorAll(":scope > .panel").forEach(h=>{let w=h.dataset.faqText||(h.dataset.faqText=o(h.textContent)),R=d.every(S=>w.includes(S));h.classList.toggle("faq-hit",d.length>0&&R),h.hidden=d.length>0&&!R,R&&y++});let m=d.length>0&&y===0;u.hidden=m;let b=u.previousElementSibling;b?.classList.contains("faq-cat")&&(b.hidden=m),p+=y}),e.faqResults=d.length?p:0},e.clearFaqSearch=()=>{e.faqQuery="",e.filterFaq(),document.getElementById("faq-search-input")?.focus()};let r=()=>{let d=window.location.hash.slice(1),p=document.getElementById(d);if(!p?.classList.contains("panel-collapse"))return;$(p).collapse("show");let u=document.getElementById(p.getAttribute("aria-labelledby"));u?.setAttribute("tabindex","-1"),u?.focus({preventScroll:!0}),u?.scrollIntoView?.({block:"start"})};e.on("routeUpdate",()=>i.timeout(r,0)),s(window,"hashchange",r),i.timeout(r,0)},_c=function(e,t,s,i,o){e.settingsTab=/(?:billing|upgrade)=/.test(window.location.search)?"billing":"defaults",e.confirmDeleteAccount=!1,e.deleteUsername="",e.profilePastSubscription=()=>!e.profileAuthorGrant()&&(e.billing?.grants||[]).some(m=>["author_monthly","author_annual"].includes(m.planId)),e.showAuthorPlans=new URLSearchParams(window.location.search).get("upgrade")==="1",e.showRepositoryPass=!1,e.profilePlan="author_annual",e.openProfileUpgrade=()=>{e.settingsTab="billing",e.showAuthorPlans=!0,tt(()=>document.getElementById("settings-plan-comparison")?.focus())},e.on("settings:upgrade",()=>e.openProfileUpgrade()),e.profileAuthorPlans=()=>(e.billing?.plans||[]).filter(m=>["author_monthly","author_annual"].includes(m.id)),e.profileSelectedPlan=()=>e.profileAuthorPlans().find(m=>m.id===e.profilePlan)||e.profileAuthorPlans()[0],e.profilePassPlan=()=>(e.billing?.plans||[]).find(m=>m.id==="author_pass"),e.profileAddonPlans=()=>(e.billing?.plans||[]).filter(m=>Gi(m.id)).sort((m,b)=>+(b.id==="repo_pack")-+(m.id==="repo_pack")),e.profileAddonId="repo_pack",e.profilePackPlan=()=>(e.billing?.plans||[]).find(m=>m.id==="repo_pack"),e.profileSlotPlan=()=>(e.billing?.plans||[]).find(m=>m.id==="repo_slot"),e.profileRepositories=()=>(e.billing?.repositories||[]).filter(m=>m.status!=="removed"),e.openProfileAddon=m=>{m&&(e.profileAddonId=m),e.showRepositoryPass=!0,e.billingRepository="",tt(()=>{let b=document.getElementById("settings-addons-title");b?.scrollIntoView?.({block:"nearest",behavior:"smooth"}),b?.focus?.({preventScroll:!0})})};let r=["repo_slot","author_pass","repo_extend","repo_never"];e.profileSingleAddons=()=>e.profileAddonPlans().filter(m=>m.id!=="repo_pack").sort((m,b)=>r.indexOf(m.id)-r.indexOf(b.id)),e.profileSingleId="repo_slot",e.profileSingleAddon=()=>e.profileSingleAddons().find(m=>m.id===e.profileSingleId)||e.profileSingleAddons()[0],e.profileCheapestAddon=()=>[...e.profileSingleAddons()].sort((m,b)=>(m.amount??1/0)-(b.amount??1/0))[0],e.profileAuthorPlansByValue=()=>[...e.profileAuthorPlans()].sort((m,b)=>+(m.interval==="year")-+(b.interval==="year")),e.profilePackSummary=m=>m.parts.map(b=>b.planId==="repo_slot"?"Extra repository":`${e.profileGrantName(b)} until ${e.billingDate(b.until)}`).join(" \xB7 "),e.profileAddonFeatures=m=>({repo_pack:["One more repository, outside your free ones",`Its own ${e.billingBytes(e.profileSlotPlan()?.storage||e.profilePassPlan()?.storage)} of storage`,"Automatic updates for 180 days","Online for up to a year","No subscription"],repo_slot:["One more repository, outside your free ones",`Its own ${e.billingBytes(e.profileSlotPlan()?.storage)} of storage`,"Valid while the repository exists","Refresh it by hand"],author_pass:["Automatic updates for 180 days",`Its own ${e.billingBytes(e.profilePassPlan()?.storage)} of storage`,"No subscription"],repo_extend:["Online for up to one more year","Buy again to add another year","No subscription"],repo_never:["The link never expires","No subscription","Ends only if the payment is refunded"]})[m]||[],e.profileAddonBlurb=m=>({repo_slot:"One more repository",author_pass:"Auto-updates for 180 days",repo_extend:"Online one more year",repo_never:"The link never expires"})[m]||"",e.profileAuthorPurchase=()=>(e.billing?.purchases||[]).find(m=>m.recurring&&["active","overdue"].includes(m.status)),e.profileRepositoryExpiry=m=>m.status==="expired"?"expired":m.expirationMode==="never"?"never expires":m.expirationDate?"expires "+e.billingDate(m.expirationDate):"no date",e.profileAnnualSavings=()=>{let m=e.profileAuthorPlans().find(h=>h.interval==="month")?.amount,b=e.profileAuthorPlans().find(h=>h.interval==="year")?.amount;return m&&b&&b(e.billing?.purchases||[]).filter(b=>["active","overdue"].includes(b.status)===m),e.profilePurchaseStatus=m=>({active:"Active",overdue:"Payment overdue",ended:"Ended",refunded:"Refunded",disputed:"Disputed"})[m.status]||m.status,e.profilePurchaseTerm=m=>{let b=m.status&&!["active","overdue"].includes(m.status);if(m.recurring)return b?m.until?"Ended "+e.billingDate(m.until):"":(m.cancelAtPeriodEnd?"Ends ":"Renews ")+e.billingDate(m.until);if(m.planId==="repo_pack"){let h=m.parts.map(w=>w.until).filter(Boolean).map(w=>new Date(w).getTime());return b||!h.length?"":"Until "+e.billingDate(new Date(Math.max(...h)))}return m.until?(b||new Date(m.until).getTime()e.profileAddonPlans().find(m=>m.id===e.profileAddonId)||e.profileAddonPlans()[0],e.profileAuthorGrant=()=>(e.billing?.grants||[]).find(m=>["author_monthly","author_annual"].includes(m.planId)&&["active","paid","past_due"].includes(m.status)&&new Date(m.until).getTime()>Date.now()),e.profileConferencePlan=()=>(e.billing?.plans||[]).filter(m=>["conference_workshop","conference","conference_large"].includes(m.id)&&m.amount!=null).sort((m,b)=>m.amount-b.amount)[0],e.profileGrantName=m=>({author_monthly:"Author monthly",author_annual:"Author annual",author_pass:"Live updates",repo_extend:"Extended expiration",repo_never:"Never expire",repo_slot:"Extra repository",repo_pack:"Paper pack",conference:"Conference package",conference_workshop:"Workshop package",conference_large:"Large conference package"})[m.planId]||m.planId,Ki(e,t,()=>o.load().then(m=>{e.quota=m},console.error),{portalMessage:()=>{let m=e.profileAuthorGrant();return m?m.cancelAtPeriodEnd?`Renewal cancelled. Your access continues until ${e.billingDate(m.until)}.`:`Your subscription renews on ${e.billingDate(m.until)}.`:"Your billing details are up to date."}}),e.terms="",e.options={expirationMode:"remove",update:!1,image:!0,pdf:!0,notebook:!0,loc:!0,link:!0},e.saving=!1,e.message=null,e.error=null,e.accountEmail="",e.emailLoading=!0,e.emailCSRFReady=!1,e.emailSaving=!1,e.emailSaved=!1,e.emailError="";let d="";e.loadAccountEmail=async()=>{e.emailLoading=!0,e.emailError="";try{let m=await t.get("/github/connections/email");e.accountEmail=m.data.notificationEmail||"",d=m.data.csrf,e.emailCSRFReady=!!d}catch{e.emailError="Unable to load your email address. Please try again."}finally{e.emailLoading=!1}},e.saveAccountEmail=async()=>{if(!(e.emailSaving||e.emailLoading||!d)){e.emailSaving=!0,e.emailSaved=!1,e.emailError="";try{let m=await t.post("/github/connections/email",{email:e.accountEmail},{headers:{"X-CSRF-Token":d}});e.accountEmail=m.data.notificationEmail,e.user&&(e.user.notificationEmail=m.data.notificationEmail),e.emailSaved=!0}catch{e.emailError="Unable to save your email address. Check the address and try again."}finally{e.emailSaving=!1}}},e.loadAccountEmail(),o.load().then(m=>{e.quota=m},console.error);let p=ga(e,["terms","options"],"profile");e.discardDraft=()=>p.discard();function u(){t.get("/api/user/default").then(m=>{let b=m.data||{};b.terms&&(e.terms=b.terms.join(` -`)),e.options=Object.assign({},e.options,b.options),p.restore()})}u();let y=null;e.saveDefault=m=>{if(m&&m.preventDefault&&m.preventDefault(),e.saving)return;let b=p.checkpoint(),h={terms:e.terms.split(` -`).map(w=>w.trim()).filter(w=>w.length>0),options:e.options};e.saving=!0,e.error=null,t.post("/api/user/default",h).then(()=>{p.accept(b),e.saving=!1,e.message=e.unsavedChanges?null:"Saved",y&&i.cancel(y),y=i(()=>{e.message=null},2500)},w=>{e.saving=!1;let R=w&&w.data&&w.data.error,S="Unable to save your defaults. Please try again.";Promise.all([s("ERRORS."+R),s("ERRORS.unknown_error")]).then(([N,v])=>{e.error=R&&N!==v?N:S},()=>{e.error=S})})},e.deleteAccount=()=>{e.deletingAccount||!e.confirmDeleteAccount||e.deleteUsername!==e.user?.username||(e.deletingAccount=!0,t.delete("/api/user").then(()=>{window.location.href="/"},()=>{e.deletingAccount=!1,e.deleteError="Unable to delete the account. Please try again."}))}},Lc=function(e,t,s){e.repoId=null,e.repoUrl=null,e.claim=()=>{t.post("/api/repo/claim",{repoId:e.repoId,repoUrl:e.repoUrl}).then(i=>{s.url("/dashboard")},i=>{e.error=i.data,e.claimForm.repoUrl.setValidity("not_found",!1),e.claimForm.repoId.setValidity("not_found",!1)})}},$c=function(e,t,s,i,o){e.user&&!e.user.status&&s.url("/dashboard"),e.watch("user.status",()=>{e.user&&!e.user.status&&s.url("/dashboard")}),e.features=[{key:"anonymize",num:"01",eyebrow:"Anonymize",title:"Double-anonymous,",accent:"your rules.",text:"Choose what reviewers may see: links, images, PDFs, notebooks, GitHub Pages. Add your own terms, with regex if you need it, and pick the expiration date.",cta:"Start an anonymization",href:"/anonymize",url:"anonymous.4open.science/anonymize",img:"/imgs/anonymize.png",alt:"The anonymize form: source repository, terms to redact, options and a live README preview"},{key:"review",num:"02",eyebrow:"Review",title:"Reviewers browse",accent:"the real thing.",text:"Highlighted source code, rendered PDFs, images, and notebooks, in a familiar file explorer. GitHub Pages is also supported.",cta:"Open the example",href:"https://anonymous.4open.science/r/840c8c57-3c32-451e-bf12-0e20be300389/",target:"_self",url:"anonymous.4open.science/r/840c8c57-\u2026",img:"/imgs/explorer.png",alt:"The repository explorer with a file tree and a rendered README"},{key:"manage",num:"03",eyebrow:"Manage",title:"One dashboard,",accent:"until the decision.",text:"Monitor views, edit configuration, remove or update your repository. Program chairs can group submissions under a conference with one shared expiry.",cta:"Open the dashboard",href:"/dashboard",needsUser:!0,url:"anonymous.4open.science/dashboard",img:"/imgs/dashboard.png",alt:"The dashboard listing anonymized repositories with status, views and expiry"}],e.feature=e.features[0].key,e.selectFeature=function(p){e.feature=p},e.featureHref=function(p){return p.needsUser&&!e.user?"/signin":p.href},e.featureTarget=function(p){return p.needsUser&&!e.user?"_self":p.target||void 0},e.featureKeydown=function(p,u){let y={ArrowDown:1,ArrowRight:1,ArrowUp:-1,ArrowLeft:-1,Home:"first",End:"last"}[p.key];if(y===void 0)return;p.preventDefault();let m=e.features.length,b=y==="first"?0:y==="last"?m-1:(u+y+m)%m;e.feature=e.features[b].key,o(()=>{let h=i.document.getElementById("feature-tab-"+e.feature);h&&h.focus()})},e.demoText=`# DeepLearnUtils +`)}else typeof I=="number"||typeof I=="boolean"?K=String(I):K=JSON.stringify(I);x.push(`${L}${K}${H}`)}),x.push("}"),x.join(` +`)}function y(v){let E=[],D="",V=/(\w+):(>=|<=|!=|>|<|=)?([^\s]+)/g,_=0,z;for(;z=V.exec(v);)D+=v.slice(_,z.index),_=V.lastIndex,E.push({key:z[1],op:z[2]||"=",val:z[3]});return D+=v.slice(_),{filters:E,free:D.trim().toLowerCase()}}function h(v,E){for(let D of E.filters){let V=(z,x,X)=>{let I=parseFloat(z),U=parseFloat(x);return X==="="?String(z)===String(x):X==="!="?String(z)!==String(x):X===">="?I>=U:X==="<="?I<=U:X===">"?I>U:X==="<"?IE&&X._bucket!==E?!1:h(X,v)),V=e.query.group;if(V){let X=C=>V==="module"?C.module:C.displayMessage||C.message||"_",I=new Map;for(let C of D){let L=X(C);if(I.has(L)){let H=I.get(L);H.count++,H._related.push(C),new Date(C.ts)>new Date(H.ts)&&(H.ts=C.ts,H._url=C._url,H._status=C._status),new Date(C.ts)new Date(L.ts).getTime()>=U).length;D=Array.from(I.values())}else D=D.map((X,I)=>(X._key="row:"+I+":"+X.ts,X._related=[X],X._firstSeen=X.ts,X._lastHourCount=0,X.count=1,X));let _=X=>({error:0,warn:1,info:2})[X._bucket]??1;e.query.sort==="count"?D.sort((X,I)=>_(X)-_(I)||I.count-X.count||new Date(I.ts)-new Date(X.ts)):D.sort((X,I)=>_(X)-_(I)||new Date(I.ts)-new Date(X.ts)),e.visible=D;let z=!!(e.query.bucket||(e.query.search||"").trim()),x=!z&&(e.stats?.severity?.error||0)>0&&!D.some(X=>X._bucket==="error")&&e.entries.length<1500;(z&&!D.length||x)&&e.canLoadMore?.()&&!e._autoLoading&&e.entries.length<2500&&(e._autoLoading=!0,m(!0))}function m(v){let E=v?e.entries.length:0,D=v?e.pageSize:Math.max(e.pageSize,e.entries.length||e.pageSize);t.get("/api/admin/errors",{params:{offset:E,limit:D}}).then(V=>{let _=(V.data.entries||[]).map(p);e.entries=v?e.entries.concat(_):_,e.available=!!V.data.available,e.cap=V.data.max||e.cap,e.total=V.data.total||e.entries.length,e._autoLoading=!1,b()},V=>{e._autoLoading=!1,console.error(V)})}e.loadMore=()=>m(!0),e.canLoadMore=()=>e.entries.length{let E=v.data||{},D=E.prev24h?Math.round((E.last24h-E.prev24h)/E.prev24h*100):0;e.stats={last24h:E.last24h||0,prev24h:E.prev24h||0,delta:D,severity:E.severity||{error:0,warn:0,info:0},unique:E.unique||{error:0,warn:0,info:0},buckets:E.buckets||[],dropped:E.dropped||0},b()},v=>console.error(v))}function N(){m(),w()}e.barPx=(v,E)=>{let D=e.stats.buckets||[],V=0,_=0;for(let I of D)V=Math.max(V,(I.error||0)+(I.warn||0)),_=Math.max(_,I.info||0);let z=v[E]||0;if(!z)return 0;if(E==="info")return _?Math.max(2,Math.round(z/_*(V?16:60))):0;let x=(v.error||0)+(v.warn||0),X=Math.round(x/V*44);return Math.max(4,Math.round(z/x*X))},e.bucketTitle=v=>`${new Date(v.hour).toLocaleTimeString([],{hour:"2-digit",minute:"2-digit"})} \xB7 ${v.error||0} err \xB7 ${v.warn||0} warn \xB7 ${v.info||0} info`,e.toggle=v=>{e.expanded[v._key]=!e.expanded[v._key]},e.setBucket=v=>{e.query.bucket=v},e.refreshNow=N,e.clearAll=()=>{confirm("Clear all captured errors?")&&t.delete("/api/admin/errors").then(N,v=>console.error(v))},e.exportCsv=()=>{let v=["ts","level","module","displayMessage","_status","_url","_repoId"],E=[v.join(",")];for(let z of e.visible)E.push(v.map(x=>{let X=z[x]==null?"":String(z[x]);return/[",\n]/.test(X)?`"${X.replace(/"/g,'""')}"`:X}).join(","));let D=new Blob([E.join(` +`)],{type:"text/csv;charset=utf-8"}),V=URL.createObjectURL(D),_=document.createElement("a");_.href=V,_.download=`errors-${new Date().toISOString().slice(0,19)}.csv`,document.body.appendChild(_),_.click(),document.body.removeChild(_),URL.revokeObjectURL(V)};function S(v){e.copyHint=`${v} copied`,o.timeout(()=>{e.copyHint=""},1500)}e.copyJson=v=>{navigator.clipboard.writeText(v._detailJson).then(()=>S("JSON"))},e.copyCurl=v=>{if(!v._url)return;let D=`curl -X ${v._method||"GET"} '${window.location.origin}${v._url}'`;navigator.clipboard.writeText(D).then(()=>S("curl"))},N();let R=i(()=>{e.query.autoRefresh&&N()},15e3);e.on("dispose",()=>i.cancel(R)),e.watch("query.search",b),e.watch("query.bucket",b),e.watch("query.sort",b),e.watch("query.group",b)},ju=function(e,t,s,i){if(e.Math=Math,e.watch("user.status",()=>{e.user==null&&s.url("/")}),e.user==null){s.url("/");return}e.data=null,e.loading=!0,e.error=null,e.performance=null,e.performanceMinutes=15,e.performanceTab="routes",e.cacheReport=null,e.cacheError=null,e.cacheMinutes=60,e.cacheTraffic="all",e.ovView=["performance","cache"].includes((window.location.hash||"").slice(1))?window.location.hash.slice(1):"summary",e.setOvView=function(v){e.ovView=v;try{window.history.replaceState(null,"",v==="summary"?window.location.pathname:"#"+v)}catch{}};var o=!1;e.loadCache=function(){if(!o){o=!0;var v=e.cacheMinutes;t.get("/api/admin/cache",{params:{minutes:v}}).then(function(E){v===e.cacheMinutes&&(e.cacheReport=E.data,e.cacheError=E.data.available?null:E.data.reason||"Cache monitoring is unavailable.")},function(){e.cacheError="Could not refresh cache monitoring. Displayed values may be stale."}).finally(function(){o=!1,v!==e.cacheMinutes&&e.loadCache()})}},e.cacheRows=function(){return(e.cacheReport?.rows||[]).filter(function(v){return e.cacheTraffic==="all"||v.traffic===e.cacheTraffic})},e.cacheRate=function(v,E){var D=e.cacheRows(),V=function(x){return D.filter(function(X){return X.name===x}).reduce(function(X,I){return X+I[E]},0)},_=V(v+"_hit"),z=V(v+"_miss");return _+z?(100*_/(_+z)).toFixed(1)+"%":"No samples"},e.cacheEventName=function(v){return v.replaceAll("_"," ")},e.cacheP95=function(v){var E=0,D=e.cacheReport?.latencyBucketsMs||[];if(!v.count)return"No samples";if(!v.ms)return"Not timed";for(var V=0;V<=D.length;V++)if(E+=v["b"+V]||0,E>=Math.ceil(v.count*.95))return V 10\u202Fs";return"No samples"},e.healthAlert=function(){let v=e.data&&e.data.system||{},E=[["Memory",v.memPercent],["Disk",v.diskPercent]].filter(([,V])=>V>90);return E.length?E.map(([V,_])=>V+" is at "+_+"%").join(" and ")+". New anonymizations may fail until "+(E.length>1?"they drop.":"it drops."):""},e.performanceError=null,e.formatMs=function(v){return v==null?"":qn(v)},e.latencyBound=function(v,E){return v.count?v[E]==null?"> 60\u202Fs":"\u2264 "+e.formatMs(v[E]):"No samples"},e.firstByteBound=function(v){return e.latencyBound({count:v.firstByteCount,p95UpperMs:v.firstByteP95UpperMs},"p95UpperMs")},e.sampleAge=function(v){return Math.max(0,Math.round((Date.now()-v.sampledAt)/1e3))},e.peakRss=function(v){return(e.performance.runtimeSeries||[]).filter(function(E){return E.instance===v.instance}).reduce(function(E,D){return Math.max(E,D.rss)},v.memory.rss)},e.performanceWarning=function(v){return e.sampleAge(v)>45||v.droppedBatches||v.droppedMetrics||v.sockets?.closeWait>0||v.eventLoop?.p95Ms>100||v.memoryLimitBytes&&v.memory.rss>v.memoryLimitBytes*.8};var r=!1;e.loadPerformance=function(){var v=e.performanceMinutes;e.performance?.windowMinutes&&e.performance.windowMinutes!==v&&(e.performance=null),!r&&(r=!0,t.get("/api/admin/performance",{params:{minutes:v}}).then(function(E){v===e.performanceMinutes&&(e.performance=E.data,e.performanceError=E.data.available?null:"Performance monitoring is unavailable. Request history may be incomplete.")},function(){v===e.performanceMinutes&&(e.performanceError="Could not refresh performance monitoring. Displayed samples may be stale.")}).finally(function(){r=!1,v!==e.performanceMinutes&&e.loadPerformance()}))};function d(v){if(v==null)return"\u2014";for(var E=["B","KB","MB","GB","TB"],D=0,V=v;V>=1024&&D0?1:0).replace(/\.0$/,"")+" "+E[D]}e.humanBytes=d;function p(v){if(!v)return"\u2014";var E=Math.floor(v/86400),D=Math.floor(v%86400/3600),V=Math.floor(v%3600/60);return E>0?E+"d "+(D<10?"0":"")+D+"h":D>0?D+"h "+(V<10?"0":"")+V+"m":V+"m"}e.humanDuration=p;function u(v){return v==null?"\u2014":v>=1e6?(v/1e6).toFixed(1)+"M":v>=1e3?(v/1e3).toFixed(1)+"K":String(v)}e.humanNum=u,e.queueTotal=function(v){return v?(v.waiting||0)+(v.active||0)+(v.delayed||0)+(v.failed||0):0},e.statusCount=function(v){if(!e.data||!e.data.repos)return 0;for(var E=e.data.repos.statusBreakdown||[],D=0;D0,zero:!V,title:String(_.getHours()).padStart(2,"0")+":00 \xB7 "+(D.error||0)+" 5xx, "+(D.warn||0)+" 4xx"}})},e.errorHoursPeak=function(){var v=e.errorStats&&e.errorStats.buckets||[];return v.reduce(function(E,D){return Math.max(E,(D.error||0)+(D.warn||0))},0)};function y(v){var E=v||[];return E.map(function(D,V){var _=E[V-1]||{},z=Object.assign({},D);return z.dailyRepositories=V?Math.max(0,(D.nbRepositories||0)-(_.nbRepositories||0)):0,z.dailyUsers=V?Math.max(0,(D.nbUsers||0)-(_.nbUsers||0)):0,z.dailyPageViews=V?Math.max(0,(D.nbPageViews||0)-(_.nbPageViews||0)):0,z})}function h(v){var E=v&&v.length?v[v.length-1]:{};return{repositories:E.dailyRepositories||0,users:E.dailyUsers||0,pageViews:E.dailyPageViews||0}}function b(v,E){if(!v||!v.length)return v;var D=new Date(v[v.length-1].date);if(isNaN(D))return v;var V={};v.forEach(function(I){V[new Date(I.date).toISOString().slice(0,10)]=I});for(var _=[],z=E-1;z>=0;z--){var x=new Date(D.getTime()-z*864e5),X=x.toISOString().slice(0,10);_.push(V[X]||{date:x.toISOString(),_empty:!0,dailyPageViews:0,dailyRepositories:0,dailyUsers:0,nbUsers:0})}return _}var m={};e.historyMax=function(v){return m[v]||0};var w={};e.axisMax=function(v){var E=m[v]||0;if(E<=2)return 2;if(E<=10)return Math.ceil(E/2)*2;var D=Math.pow(10,Math.floor(Math.log10(E)));return Math.ceil(E/D)*D},e.historyBarH=function(v,E){return!v||!m[E]||!v[E]?0:Math.max(1,Math.round(v[E]/e.axisMax(E)*140))},e.historyRange=function(v){return{min:w[v],max:m[v]}};var N=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"];e.historyLabel=function(v){if(!v||!v.date)return"";var E=new Date(v.date);return N[E.getUTCMonth()]+" "+E.getUTCDate()},e.historyHasMissing=function(){return!!(e.data&&e.data.history||[]).some(function(v){return v&&v._empty})},e.firstDataIndex=function(){for(var v=e.data&&e.data.history||[],E=0;E=D)return{lo:X,hi:X+2*z[x]}}return{lo:0,hi:e.axisMax("nbUsers")}},e.userStepPath=function(v){var E=e.data&&e.data.history||[],D=e.userAxis(),V=m.nbUsers?D.hi-D.lo:0,_=e.firstDataIndex();if(!V||_>=E.length)return"";for(var z=function(U){return(140-((U||0)-D.lo)/V*140).toFixed(2)},x=v?"M"+_+" 140":"",X=_;Xm[D])&&(m[D]=E[D]),(w[D]==null||E[D] .meta-more"),s=[...e.querySelectorAll(":scope > .meta-item")];if(s.forEach(o=>{o.removeAttribute("data-meta-hidden")}),t&&(t.hidden=!0,t.textContent="",t.removeAttribute("title"),t.removeAttribute("aria-label")),!e.clientWidth)return;if(e.classList.add("is-fitting"),e.scrollWidth<=e.clientWidth+1){e.classList.remove("is-fitting");return}let i=[];for(let o=s.length-1;o>=0&&e.scrollWidth>e.clientWidth+1;o--)if(s[o].setAttribute("data-meta-hidden",""),i.unshift(s[o]),t){let r=i.map(d=>d.dataset.metaLabel||d.textContent.trim().replace(/\s+/g," "));t.hidden=!1,t.textContent="+"+i.length,t.title=r.join(" \xB7 "),t.setAttribute("aria-label",i.length+" more: "+r.join(", "))}e.classList.remove("is-fitting")}function Gu(e,t){if(typeof document>"u"||typeof MutationObserver>"u"||!document.body)return;let s=!1,i=null,o=()=>{s=!1,i&&(document.querySelectorAll("[data-meta-fit]").forEach(kg),i.takeRecords())},r=()=>{!s&&i&&(s=!0,e.timeout(o,30))};i=new MutationObserver(d=>{d.some(p=>!(p.target.closest&&p.target.closest(".meta-more")))&&r()}),i.observe(document.body,{childList:!0,subtree:!0,characterData:!0}),es(()=>{i.disconnect(),i=null}),t(window,"resize",r),document.fonts?.ready&&document.fonts.ready.then(r),r()}var Cg=["bif","clp","djf","gnf","jpy","kmf","krw","mga","pyg","rwf","ugx","vnd","vuv","xaf","xof","xpf"],_u=[{id:"subscription",label:"Subscriptions"},{id:"repository",label:"Repository purchases"},{id:"conference",label:"Conferences"}],Eg={author_monthly:"Author monthly",author_annual:"Author annual",author_pass:"Live updates",repo_extend:"Extended expiration",repo_never:"Never expire",repo_slot:"Extra repository",repo_pack:"Paper pack",conference_workshop:"Workshop",conference:"Conference",conference_large:"Large conference"};function Lu(e){return Object.entries(e||{}).filter(([,t])=>t).sort((t,s)=>s[1]-t[1]).map(([t,s])=>{let i=Cg.includes(t)?s:s/100;try{return new Intl.NumberFormat(void 0,{style:"currency",currency:t.toUpperCase(),minimumFractionDigits:i%1?2:0,maximumFractionDigits:2}).format(i)}catch{return i+" "+t.toUpperCase()}})}var Wu=function(e,t,s){let i=Ct();if(e.Math=Math,e.watch("user.status",()=>{e.user==null&&s.url("/")}),e.user==null){s.url("/");return}e.families=_u,e.periods=[{id:"7d",label:"7 days"},{id:"30d",label:"30 days"},{id:"90d",label:"90 days"},{id:"12m",label:"12 months"},{id:"all",label:"All time"}];let o=(()=>{try{return localStorage.getItem("admin.billing.period")}catch{return null}})();e.period=e.periods.some(m=>m.id===o)?o:"30d",e.summary=null,e.summaryError=null,e.summaryLoading=!0,e.periodLabel=()=>(e.periods.find(m=>m.id===e.period)||{}).label||"",e.periodPhrase=()=>e.period==="all"?"all time":"last "+e.periodLabel(),e.money=m=>Lu(m),e.moneyText=(m,w="\u2014")=>Lu(m).join(" \xB7 ")||w,e.revenueOn=()=>!!e.summary?.revenue?.available,e.planName=m=>((e.summary?.plans||[]).find(w=>w.planId===m)||{}).name||Eg[m]||m,e.bucketTotal=m=>m?m.subscription+m.repository+m.conference:0,e.chartMax=()=>{let m=Math.max(0,...(e.summary?.series||[]).map(e.bucketTotal));if(m<=4)return 4;let w=Math.pow(10,Math.floor(Math.log10(m)));return[1,1.2,1.5,2,2.5,3,4,5,6,8,10].map(N=>N*w).find(N=>N>=m&&N%2===0)||10*w},e.segmentPct=(m,w)=>m&&m[w]?m[w]/e.chartMax()*100:0,e.familyTotal=m=>(e.summary?.series||[]).reduce((w,N)=>w+N[m],0),e.bucketLabel=m=>{if(!m)return"";let w=new Date(m.date),N={timeZone:"UTC",day:"numeric",month:"short"};return e.summary?.bucket==="month"?w.toLocaleDateString(void 0,{timeZone:"UTC",month:"short",year:"numeric"}):((e.period==="12m"||e.period==="all"||w.getUTCFullYear()!==new Date().getUTCFullYear())&&(N.year="numeric"),(e.summary?.bucket==="week"?"Week of ":"")+w.toLocaleDateString(void 0,N))},e.bucketTip=m=>{let w=e.bucketTotal(m);if(!w)return e.bucketLabel(m)+": no sales";let N=_u.filter(S=>m[S.id]).map(S=>m[S.id]+" "+S.label.toLowerCase());return e.bucketLabel(m)+": "+w+(w===1?" sale":" sales")+" ("+N.join(", ")+")"},e.bucketName=()=>({day:"day",week:"week",month:"month"})[e.summary?.bucket]||"day",e.seriesSales=()=>(e.summary?.series||[]).reduce((m,w)=>m+e.bucketTotal(w),0),e.plansWithActivity=()=>(e.summary?.plans||[]).filter(m=>m.active||m.allTimeSales||m.sales),e.planTotals=()=>{let m=w=>(e.summary?.plans||[]).reduce((N,S)=>N+(S[w]||0),0);return{active:m("active"),sales:m("sales"),allTimeSales:m("allTimeSales")}},e.webhookState=()=>{let m=e.summary?.webhooks;return m?m.failed||m.reconciliationFailed?"bad":m.oldestPendingSeconds>900||m.unreviewedRevocations?"warn":"ok":"ok"},e.age=m=>m?qn(m*1e3):"\u2014";let r=0;e.loadSummary=()=>{let m=++r;e.summaryLoading=!0,e.summaryError=null,t.get("/api/admin/billing/summary",{params:{period:e.period}}).then(w=>{if(m!==r)return;e.summaryLoading=!1;let N=w.data;if(!N||!N.subscriptions||!N.sales||!Array.isArray(N.plans)){e.summaryError="The billing summary had an unexpected format.";return}e.summary=N},w=>{m===r&&(e.summaryLoading=!1,e.summaryError=w&&w.data&&w.data.error||"Could not load billing figures.")})},e.setPeriod=m=>{if(e.period!==m){e.period=m;try{localStorage.setItem("admin.billing.period",m)}catch{}e.loadSummary()}},e.grants=[],e.total=-1,e.totalPage=0,e.stateCounts={},e.statuses=[],e.grantsError=null,e.filtersOpen=!1,e.query={page:1,limit:25,search:"",plan:"",status:"",state:"",sort:"purchasedAt",direction:"desc"};let d=s.search();d.search&&(e.query.search=d.search),e.stateView=()=>e.query.state||"all",e.setStateView=m=>{e.query.state=m==="all"?"":m,e.query.page=1},e.stateCount=m=>m==="all"?["active","expired","revoked"].reduce((w,N)=>w+(e.stateCounts[N]||0),0):e.stateCounts[m]||0,e.sortBy=m=>{e.query.sort===m?e.query.direction=e.query.direction==="asc"?"desc":"asc":(e.query.sort=m,e.query.direction="desc"),e.query.page=1},e.sortIcon=m=>e.query.sort===m?e.query.direction==="asc"?"fa-arrow-up":"fa-arrow-down":"",e.chips=[];let p=()=>{let m=[];e.query.plan&&m.push({key:"plan",label:"Plan",value:e.planName(e.query.plan)}),e.query.status&&m.push({key:"status",label:"Stripe status",value:e.query.status.replace(/_/g," ")}),e.chips=m};e.clearFilter=m=>{e.query[m]="",e.query.page=1},e.filterPlan=m=>{Object.assign(e.query,{plan:m,page:1});let w=document.getElementById("bl-grants");w&&w.scrollIntoView&&w.scrollIntoView({behavior:"smooth",block:"start"})},e.clearFilters=()=>Object.assign(e.query,{search:"",plan:"",status:"",state:"",page:1}),e.hasFilters=()=>!!(e.query.search||e.query.plan||e.query.status||e.query.state),e.statusText=m=>(m.status||"unknown").replace(/_/g," "),e.revocationText=m=>m==="dispute"?"Disputed":m==="full_refund"?"Refunded":"Revoked",e.scopeHref=m=>m?.kind==="repo"?"/admin/repositories?search="+encodeURIComponent(m.id):m?.kind==="conference"?"/conference/"+encodeURIComponent(m.id):null;let u=0;function y(){let m=++u;e.grantsError=null;let w=Object.fromEntries(Object.entries(e.query).filter(([,N])=>N!==""&&N!=null));t.get("/api/admin/billing/grants",{params:w}).then(N=>{m===u&&(e.total=N.data?.total??0,e.totalPage=Math.ceil(e.total/e.query.limit),e.grants=N.data?.results||[],e.stateCounts=N.data.stateCounts||{},e.statuses=N.data.statuses||[])},N=>{m===u&&(e.grantsError=N&&N.data&&N.data.error||"Could not load subscriptions and purchases.")})}e.reloadGrants=y,e.loadSummary(),y(),p();let h=null,b=JSON.stringify({...e.query,page:0});e.watch("query",()=>{let m=JSON.stringify({...e.query,page:0});if(m!==b&&e.query.page!==1){b=m,e.query.page=1;return}b=m,i.timeout.cancel(h),h=i.timeout(y,300),p()},!0)},Ku=function(e,t,s){if(e.user==null){s.url("/");return}e.Math=Math;let i=typeof window<"u"?window:null,o=i?new URLSearchParams(i.location.search):null,r=["7d","30d","90d","all"],d=["accepted","rejected","unknown","sending"];e.emailRows=[],e.emailState=d.includes(o?.get("state"))?o.get("state"):"",e.emailKind=["repository-expiration","owner-access"].includes(o?.get("kind"))?o.get("kind"):"",e.emailPeriod=r.includes(o?.get("period"))?o.get("period"):"7d",e.emailSearch=o?.get("search")||"";let p=e.emailSearch.trim();e.emailLoading=!1,e.emailError="",e.emailAnnouncement="",e.emailNextCursor=null,e.emailSummary=null,e.emailSummaryError="",e.emailSummaryLoading=!1,e.emailUpdated=null,e.emailPage=1,e.selectedEmailId=null,e.emailCopyMessage="",e.emailCopiedValue=null,e.emailTimezone=Intl.DateTimeFormat().resolvedOptions().timeZone,e.emailStatusLabel=D=>({sending:"Pending",accepted:"Accepted",rejected:"Rejected",unknown:"Unknown"})[D]||D,e.emailKindLabel=D=>({"repository-expiration":"Repository expiration","owner-access":"GitHub access"})[D]||D,e.emailTime=D=>D?new Date(D).toLocaleString(void 0,{year:"numeric",month:"short",day:"numeric",hour:"2-digit",minute:"2-digit",second:"2-digit",timeZoneName:"short"}):"Not recorded",e.emailShortTime=D=>{if(!D)return"Not recorded";let V=new Date(D);return V.toLocaleString(void 0,{...e.emailPeriod==="all"||V.getFullYear()!==new Date().getFullYear()?{year:"numeric"}:{},month:"short",day:"numeric",hour:"2-digit",minute:"2-digit"})},e.emailExplanation=D=>D.state==="accepted"?"The provider accepted this request. Inbox delivery is not confirmed.":D.state==="sending"?"The attempt was recorded, but no final outcome has been recorded. Check the provider before sending again.":D.state==="unknown"?"The provider outcome could not be confirmed. Check the provider before sending again to avoid duplicates.":{400:"The provider rejected the request as invalid.",401:"The provider rejected authentication.",403:"The provider denied this request.",404:"The provider could not find the requested endpoint or resource.",422:"The provider could not process the request.",429:"The provider rejected the request because of rate limiting."}[D.httpStatus]||(D.httpStatus>=500?"The provider reported a server error.":"The provider rejected this request."),e.toggleEmail=D=>{e.selectedEmailId=e.selectedEmailId===D._id?null:D._id,e.emailCopyMessage="",e.emailCopiedValue=null};let u=!1,y=0,h=0,b="",m="",w=!1,N=null;e.copyEmail=async D=>{e.emailCopiedValue=null;try{if(!i?.navigator?.clipboard)throw new Error("Clipboard unavailable");await i.navigator.clipboard.writeText(String(D)),u||(e.emailCopyMessage="Copied.",e.emailCopiedValue=String(D))}catch{u||(e.emailCopyMessage="Could not copy. Select and copy the text manually.")}};let S=()=>({period:e.emailPeriod,search:p||void 0,kind:e.emailKind||void 0}),R=()=>{if(i)try{let D=new URL(i.location.href);for(let[V,_]of Object.entries({...S(),state:e.emailState}))_?D.searchParams.set(V,_):D.searchParams.delete(V);i.history.replaceState(null,"",D.pathname+D.search+D.hash)}catch{}};e.hasEmailFilters=()=>!!(e.emailState||e.emailKind||p||e.emailPeriod!=="7d"),e.emailVisibleRows=()=>e.emailRows.slice((e.emailPage-1)*25,e.emailPage*25),e.emailTotal=()=>e.emailSummary?e.emailState?e.emailSummary.counts[e.emailState]:e.emailSummary.total:null,e.emailPageCount=()=>e.emailTotal()==null?null:Math.max(1,Math.ceil(e.emailTotal()/25)),e.emailDayTotal=D=>d.reduce((V,_)=>V+(Number(D[_])||0),0),e.emailChartTotal=()=>(e.emailSummary?.series||[]).reduce((D,V)=>D+e.emailDayTotal(V),0),e.jumpToEmailHistory=()=>{let D=i?.document?.querySelector("#email-history-title");D&&(D.focus({preventScroll:!0}),D.scrollIntoView({block:"start"}))},e.emailChartMax=()=>Math.max(1,...(e.emailSummary?.series||[]).map(e.emailDayTotal)),e.emailDayLabel=D=>{let V=typeof D=="string"?D:D?.date;if(!V)return"";let _=new Date(V+"T12:00:00Z");return Number.isNaN(_.getTime())?"":_.toLocaleDateString(void 0,{month:"short",day:"numeric",timeZone:"UTC"})};let v=D=>{e.emailPage=D,e.selectedEmailId=null,N=null;let V=(D-1)*25+1,_=Math.min(D*25,e.emailRows.length);e.emailAnnouncement=`Page ${D}. Showing attempts ${V} to ${_}.`;let z=i?.document?.querySelector("#email-history-title");z&&(z.setAttribute("tabindex","-1"),z.focus({preventScroll:!0}),z.scrollIntoView({block:"start",behavior:"auto"}))};e.loadEmailSummary=async()=>{let D=JSON.stringify(S());D!==m&&(e.emailSummary=null),m=D;let V=++h;e.emailSummaryLoading=!0,e.emailSummaryError="";try{let _=await t.get("/api/admin/emails/summary",{params:S()});V===h&&(e.emailSummary=_.data)}catch{V===h&&(e.emailSummaryError=e.emailSummary?"Could not refresh the summary. Previously loaded totals are still shown.":"Email summary is unavailable.")}finally{V===h&&(e.emailSummaryLoading=!1)}},e.retryEmails=()=>e.loadEmails(w),e.loadEmails=async(D=!1)=>{let V=JSON.stringify([e.emailState,e.emailKind,e.emailPeriod,p]),_=V!==b;if(b=V,_&&(D=!1),D&&(e.emailLoading||!e.emailNextCursor))return;let z=++y;e.emailLoading=!0,e.emailError="",e.emailAnnouncement=D?"Loading older emails.":"Loading email history.",_&&(e.emailRows=[],e.emailNextCursor=null,e.emailPage=1,e.selectedEmailId=null,N=null),D||(N=null),R();try{let x=await t.get("/api/admin/emails",{params:{...S(),state:e.emailState||void 0,before:D?e.emailNextCursor:void 0}});return z!==y?void 0:(e.emailRows=D?e.emailRows.concat(x.data.entries):x.data.entries,e.emailNextCursor=x.data.nextCursor,D||(e.emailPage=1),e.emailUpdated=new Date().toISOString(),e.emailAnnouncement=`Email history loaded. ${e.emailRows.length} attempts loaded.`,D&&N&&e.emailRows.length>(N-1)*25&&v(N),!0)}catch{z===y&&(w=D,e.emailError=D?"Could not load older emails. Your loaded history is still shown.":e.emailRows.length?"Could not refresh email history. Previously loaded results are still shown.":"Could not load email history.",e.emailAnnouncement="")}finally{z===y&&(e.emailLoading=!1)}},e.emailPreviousPage=()=>{!e.emailLoading&&e.emailPage>1&&v(e.emailPage-1)},e.emailNextPage=async()=>{if(e.emailLoading)return;let D=e.emailPage+1,V=b;e.emailRows.length<=(D-1)*25&&e.emailNextCursor&&(N=D,await e.loadEmails(!0)),!u&&V===b&&e.emailPage!==D&&e.emailRows.length>(D-1)*25&&v(D)},e.refreshEmails=()=>Promise.all([e.loadEmails(),e.loadEmailSummary()]),e.applyEmailFilters=()=>(p=e.emailSearch.trim(),e.refreshEmails()),e.setEmailStatus=D=>(e.emailState=d.includes(D)?D:"",e.loadEmails()),e.clearEmailFilters=()=>(e.emailState="",e.emailKind="",e.emailSearch="",e.emailPeriod="7d",e.applyEmailFilters());let E;i?.setTimeout&&(E=i.setTimeout(()=>{let D=i.document?.querySelector(".emails-page .admin-nav"),V=D?.querySelector('[aria-current="page"]');D&&V&&(D.scrollLeft=Math.max(0,V.offsetLeft-D.offsetLeft-(D.clientWidth-V.offsetWidth)/2))},0)),e.on("dispose",()=>{u=!0,y++,h++,E!=null&&i.clearTimeout(E)}),e.refreshEmails()};var ka=(e,t,s)=>{let i=e instanceof RegExp?Yu(e,s):e,o=t instanceof RegExp?Yu(t,s):t,r=i!==null&&o!=null&&Ng(i,o,s);return r&&{start:r[0],end:r[1],pre:s.slice(0,r[0]),body:s.slice(r[0]+i.length,r[1]),post:s.slice(r[1]+o.length)}},Yu=(e,t)=>{let s=t.match(e);return s?s[0]:null},Ng=(e,t,s)=>{let i,o,r,d,p,u=s.indexOf(e),y=s.indexOf(t,u+1),h=u;if(u>=0&&y>0){if(e===t)return[u,y];for(i=[],r=s.length;h>=0&&!p;){if(h===u)i.push(h),u=s.indexOf(e,h+1);else if(i.length===1){let b=i.pop();b!==void 0&&(p=[b,y])}else o=i.pop(),o!==void 0&&o=0?u:y}i.length&&d!==void 0&&(p=[r,d])}return p};var Xu="\0SLASH"+Math.random()+"\0",Ju="\0OPEN"+Math.random()+"\0",Na="\0CLOSE"+Math.random()+"\0",Qu="\0COMMA"+Math.random()+"\0",Zu="\0PERIOD"+Math.random()+"\0",Rg=new RegExp(Xu,"g"),Pg=new RegExp(Ju,"g"),Dg=new RegExp(Na,"g"),Ag=new RegExp(Qu,"g"),Tg=new RegExp(Zu,"g"),Og=/\\\\/g,Ig=/\\{/g,Mg=/\\}/g,Vg=/\\,/g,qg=/\\\./g,_g=1e5,Lg=4e6,$g=1e3,Fg=1e3;function Ca(e){return isNaN(e)?e.charCodeAt(0):parseInt(e,10)}function Ug(e){return e.replace(Og,Xu).replace(Ig,Ju).replace(Mg,Na).replace(Vg,Qu).replace(qg,Zu)}function Bg(e){return e.replace(Rg,"\\").replace(Pg,"{").replace(Dg,"}").replace(Ag,",").replace(Tg,".")}function Ea(e,t){for(let s=0;s=t}function Lo(e,t,s,i,o,r){let d=[],p=0;for(let u=0;u=i)return d;let h=e[u]+t+s[y];if(!(r&&!h)){if(p+h.length>o)return d;d.push(h),p+=h.length}}return d}function Kg(e,t,s,i){let o=e.split(/\.\./),r=[];if(o[0]===void 0||o[1]===void 0)return r;let d=Ca(o[0]),p=Ca(o[1]),u=Math.max(o[0].length,o[1].length),y=o.length===3&&o[2]!==void 0?Math.max(Math.abs(Ca(o[2])),1):1,h=Gg;p0){let v=new Array(R+1).join("0");N<0?S="-"+v+S.slice(1):S=v+S}}if(w+S.length>i)break;r.push(S),w+=S.length}return r}function Sa(e,t,s,i,o,r,d){if(o>i)return[e];let p=[""],u=0,y=!1,h=!0;for(;;){let b=ka("{","}",e);if(!b)return Lo(p,e,[""],t,s,y);let m=b.pre;if(/\$$/.test(m)){if(p=Lo(p,m+"{"+b.body+"}",[""],t,s,y&&!b.post.length),h=!1,!b.post.length)break;e=b.post;continue}let w=/^-?\d+\.\.-?\d+(?:\.\.-?\d+)?$/.test(b.body),N=/^[a-zA-Z]\.\.[a-zA-Z](?:\.\.-?\d+)?$/.test(b.body),S=w||N,R=b.body.indexOf(",")>=0;if(!S&&!R){if(u=t||V+X.length>s)break e;v.push(X),V+=X.length}}}}if(p=Lo(p,m,v,t,s,y&&!b.post.length),!b.post.length)break;e=b.post}return p}var Yg={"[:alnum:]":["\\p{L}\\p{Nl}\\p{Nd}"],"[:alpha:]":["\\p{L}\\p{Nl}"],"[:ascii:]":["\\x00-\\x7f"],"[:blank:]":["\\p{Zs}\\t"],"[:cntrl:]":["\\p{Cc}"],"[:digit:]":["\\p{Nd}"],"[:graph:]":["\\p{Z}\\p{C}",!0],"[:lower:]":["\\p{Ll}"],"[:print:]":["\\p{C}",!0],"[:punct:]":["\\p{P}\\p{S}"],"[:space:]":["\\p{Z}\\t\\r\\n\\v\\f"],"[:upper:]":["\\p{Lu}"],"[:word:]":["\\p{L}\\p{Nl}\\p{Nd}\\p{Pc}"],"[:xdigit:]":["A-Fa-f0-9"]},$o=e=>e.replace(/[[\]\\-]/g,"\\$&"),Ra=/$./,ec=(e,t,s=!1,i)=>{let o=v=>{let E=i?v.normalize(i):v;return[...E].length===1?E:v},r=t;if(e.charAt(r)!=="[")throw new Error("not in a brace expression");let d=[],p=[],u=r+1,y=!1,h=!1,b=!1,m=r,w="";e:for(;uw.codePointAt(0)?d.push($o(w)+"-"+$o(E)):E===w&&d.push($o(E)),w="",u+=v.length;continue}if(e.startsWith("-]",u+v.length)){d.push($o(E+"-")),u+=v.length+1;continue}if(e.startsWith("-",u+v.length)){w=E,u+=v.length+1;continue}d.push($o(E)),u+=v.length}if(m({t:"lit",ch:e}),Jg=e=>e.replace(/[\\^$.*+?()[\]{}|/]/g,"\\$&"),oc=e=>new RegExp(`^${Jg(e)}$`,"iu"),Qi=new Map,ic=e=>{let t=Qi.get(e);return t||(t=oc(e),Qi.size>=1e3&&Qi.clear(),Qi.set(e,t)),t},Ma=(e,t)=>{if(t===e.ch)return!0;if(!e.re)return!1;let s=t.charCodeAt(0);if(s>=128)return e.re.test(t);let i=e.ascii??(e.ascii=new Uint8Array(128));return i[s]||(i[s]=e.re.test(t)?1:2),i[s]===1},Qg=(e,t,s,i)=>{let o=[];for(let r=0;r{let t=new Map,s=[];return e.forEach((i,o)=>{i.t==="open"?s.push(o):i.t==="close"&&s.length&&t.set(s.pop(),o)}),t},rc=(e,t,s,i,o)=>{let r=[],d=[r];for(let p=s;p{let s=[],i="",o=()=>{for(let r of i.normalize(t))s.push(us(r));i=""};for(let r of e){if(r.t==="lit"){i+=r.ch;continue}o(),s.push(r.t==="ext"?{...r,alts:r.alts.map(d=>ac(d,t))}:r)}return o(),s},xg=(e,t)=>{let s=1,i=p=>({t:"split",id:s++,out:p}),o=(p,u)=>p.reduceRight((y,h)=>r(h,y),u),r=(p,u)=>{switch(p.t){case"lit":let m=t?ic(p.ch):void 0;return{t:"lit",id:s++,ch:p.ch,re:m,next:u};case"any":case"star":return{t:p.t,id:s++,next:u};case"class":return{t:"class",id:s++,re:p.re,next:u}}let y=m=>p.alts.map(w=>o(w,m));switch(p.type){case"@":return i(y(u));case"?":return i([u,...y(u)]);case"!":return{t:"neg",id:s++,sub:i(y(Pa)),next:u}}let h=i([]),b=i(y(h));return h.out.push(u,b),p.type==="*"?h:b};return[o(e,Pa),s]},ev=e=>{let t=[],s=new Set,i=r=>r.t==="match"?"match":String(r.id),o=(r,d)=>{if(r.t==="match"||s.has(r))return;s.add(r);let p=u=>t.push(`${d}${r.id}: ${u}`);switch(r.t){case"split":p(`split -> ${r.out.map(i).join(", ")}`);for(let u of r.out)o(u,d);return;case"neg":return p(`!(${i(r.sub)}) -> ${i(r.next)}`),o(r.sub,d+" "),o(r.next,d);case"lit":p(`${JSON.stringify(r.ch)} -> ${i(r.next)}`);break;case"class":p(`${r.re} -> ${i(r.next)}`);break;default:p(`${r.t==="any"?"?":"*"} -> ${i(r.next)}`)}o(r.next,d)};return o(e,""),[`start -> ${i(e)}`,...t].join(` +`)},Da=class{constructor(t){xe(this,"gen");xe(this,"threads",[]);xe(this,"match",!1);xe(this,"runs",[]);xe(this,"ids",[]);this.gen=t}get dead(){return!this.threads.length&&!this.match&&!this.runs.length}},lc=(e,t)=>e.ids.length!==t.ids.length||e.runs.length!==t.runs.length||e.ids.some((s,i)=>s!==t.ids[i])?!1:e.runs.every(s=>t.runs.some(i=>i.neg===s.neg&&lc(i.state,s.state))),tc=e=>({has:new Float64Array(e),seen:new Float64Array(e),gen:0}),cs,Bn,Aa,Ta,Uo=class{constructor(t,s,i){qe(this,Bn);xe(this,"dots");xe(this,"dotStart");qe(this,cs);this.dots=t,this.dotStart=s,$e(this,cs,i)}state(){return new Da(++re(this,cs).gen)}done(t){return t.ids=t.threads.map(s=>s.id).sort((s,i)=>s-i),t.match&&t.ids.unshift(Pa.id),t}restricted(t,s){return s&&(this.dots||this.dotStart&&t===0)}add(t,s,i,o){switch(s.t){case"split":if(!_e(this,Bn,Aa).call(this,t,s))return;for(let d of s.out)this.add(t,d,i,o);return;case"neg":if(!_e(this,Bn,Aa).call(this,t,s))return;let r=this.state();return this.add(r,s.sub,i,!1),this.done(r),this.addRun(t,{t:"run",neg:s,state:r},i,o);case"star":if(this.restricted(i,o))return;_e(this,Bn,Ta).call(this,t,s)&&this.add(t,s.next,i,o);return;case"match":t.match=!0;return;default:_e(this,Bn,Ta).call(this,t,s)}}addRun(t,s,i,o){for(let r of t.runs)if(r.neg===s.neg&&lc(r.state,s.state))return;t.runs.push(s),s.state.match||this.add(t,s.neg.next,i,o)}step(t,s,i,o){let r=this.state();for(let d of t.threads)switch(d.t){case"lit":Ma(d,s)&&this.add(r,d.next,i+1,o);break;case"any":this.restricted(i,o)||this.add(r,d.next,i+1,o);break;case"class":!this.restricted(i,o)&&d.re.test(s)&&this.add(r,d.next,i+1,o);break;case"star":this.restricted(i,o)||this.add(r,d,i+1,o)}if(!this.restricted(i,o))for(let d of t.runs){if(d.state.dead){this.addRun(r,d,i+1,o);continue}let p=this.step(d.state,s,i,!1);this.addRun(r,{t:"run",neg:d.neg,state:p},i+1,o)}return this.done(r)}};cs=new WeakMap,Bn=new WeakSet,Aa=function(t,s){let{seen:i}=re(this,cs);return i[s.id]===t.gen?!1:(i[s.id]=t.gen,!0)},Ta=function(t,s){let{has:i}=re(this,cs);return i[s.id]===t.gen?!1:(i[s.id]=t.gen,t.threads.push(s),!0)};var dc=e=>{let t=e.ids.join();if(!e.runs.length)return t;let s=e.runs.map(i=>`${i.neg.id}(${dc(i.state)})`);return`${t}|${s.sort().join("|")}`},tv=1<<18,Bs,zs,_n,ps,Ln,$n,Fn,sn,Ia,xi,uc,Oa=class{constructor(t,s){qe(this,sn);qe(this,Bs);qe(this,zs,new Map);qe(this,_n,0);qe(this,ps);qe(this,Ln);qe(this,$n);qe(this,Fn);$e(this,Bs,t),$e(this,$n,new Uo(!1,!1,s)),$e(this,Fn,new Uo(!1,!0,s))}start(t){if(t){if(re(this,Ln))return re(this,Ln);let i=re(this,Fn).state();return re(this,Fn).add(i,re(this,Bs),0,!0),$e(this,Ln,_e(this,sn,Ia).call(this,re(this,Fn).done(i)))}if(re(this,ps))return re(this,ps);let s=re(this,$n).state();return re(this,$n).add(s,re(this,Bs),0,!0),$e(this,ps,_e(this,sn,xi).call(this,re(this,$n).done(s)))}next(t,s){let i=s.charCodeAt(0),o=i<128?void 0:t.next.get(s);if(o)return o;let r=t===re(this,Ln)?_e(this,sn,xi).call(this,re(this,Fn).step(t.state,s,0,!0)):_e(this,sn,xi).call(this,re(this,$n).step(t.state,s,1,!0));return i<128?(t.ascii||(t.ascii=new Array(128),$e(this,_n,re(this,_n)+128)),t.ascii[i]=r):t.next.set(s,r),nl(this,_n)._++,r}};Bs=new WeakMap,zs=new WeakMap,_n=new WeakMap,ps=new WeakMap,Ln=new WeakMap,$n=new WeakMap,Fn=new WeakMap,sn=new WeakSet,Ia=function(t){return{state:t,match:t.match,dead:t.dead,next:new Map}},xi=function(t){let s=dc(t),i=re(this,zs).get(s);if(i)return i;re(this,_n)>tv&&_e(this,sn,uc).call(this);let o=_e(this,sn,Ia).call(this,t);return re(this,zs).set(s,o),$e(this,_n,re(this,_n)+(s.length+1)),o},uc=function(){re(this,zs).clear(),$e(this,_n,0),$e(this,ps,void 0),$e(this,Ln,void 0)};var nv=e=>{let t=[];for(let s=e;s.t!=="match";s=s.next){if(s.t==="split"||s.t==="neg")return;t.push(s)}return t},sv=(e,t,s,i)=>{let o=0,r=s,d=-1,p=0;for(;r{let t=0,s=0;for(let i of e){let[o,r]=ov(i);t+=o,s+=r}return[t,s]},ov=e=>{if(e.t==="star")return[0,1/0];if(e.t!=="ext")return[1,1];if(e.type==="!")return[0,1/0];let t=e.alts.map(cc),s=Math.min(...t.map(r=>r[0])),i=Math.max(...t.map(r=>r[1])),o=i===0?0:1/0;return e.type==="@"?[s,i]:e.type==="?"?[0,i]:e.type==="*"?[0,o]:[s,o]},nc=(e,t,s)=>{for(let i=0;irv.test(e)?[...e]:e,sc=e=>{if(e.includes("/"))throw new Error("can only match a single path portion, got: "+e)},Un,Hs,fs,er,ms,zo,tr,hs,Ho,jo,Go,Pn,vn,js,Gs,Wo,nr,nn,gs,Fo,Bo=class{constructor(t,s={}){qe(this,gs);xe(this,"pattern");xe(this,"options");qe(this,Un);qe(this,Hs);qe(this,fs);qe(this,er);qe(this,ms);qe(this,zo,!1);qe(this,tr);qe(this,hs);qe(this,Ho,!1);qe(this,jo,0);qe(this,Go,1/0);qe(this,Pn,[]);qe(this,vn,[]);qe(this,js);qe(this,Gs);qe(this,Wo,!1);qe(this,nr);qe(this,nn);if(t.includes("/"))throw new Error("can only match a single path portion, got pattern: "+t);this.pattern=t,this.options=s;let{nocase:i=!1,noext:o=!1,normalize:r}=s;$e(this,nn,r===!0?"NFC":r||void 0);let d=/^[?*+@]\(\)$/.test(t),p=Qg(t,i,o||d,re(this,nn)),[u]=rc(p,Zg(p),0,p.length,!0);re(this,nn)&&(u=ac(u,re(this,nn)));let[y,h]=xg(u,i);if($e(this,Un,y),$e(this,Hs,h),u.every(b=>b.t==="lit"))$e(this,ms,u.map(b=>b.ch).join("")),$e(this,zo,i);else{let b=N=>N.t!=="lit"?void 0:i?{ch:N.ch,re:ic(N.ch)}:{ch:N.ch};for(let N of u){let S=b(N);if(!S)break;re(this,Pn).push(S)}for(let N=u.length-1;N>=0;N--){let S=b(u[N]);if(!S)break;re(this,vn).unshift(S)}$e(this,Wo,!!(re(this,Pn).length||re(this,vn).length)),i||($e(this,js,re(this,Pn).map(N=>N.ch).join("")),$e(this,Gs,re(this,vn).map(N=>N.ch).join(""))),$e(this,hs,nv(re(this,Un))?.slice(re(this,Pn).length,-re(this,vn).length||void 0)),$e(this,Ho,!!re(this,hs)?.every(N=>N.t==="star"||N.t==="any"));let[m,w]=cc(u);$e(this,jo,m),$e(this,Go,w)}}test(t){return re(this,nn)?(sc(t),_e(this,gs,Fo).call(this,t.normalize(re(this,nn)))):iv.test(t)?(sc(t),_e(this,gs,Fo).call(this,t,[...t])):_e(this,gs,Fo).call(this,t,t)}testUnchecked(t){return _e(this,gs,Fo).call(this,re(this,nn)?t.normalize(re(this,nn)):t)}toString(){return ev(re(this,Un))}};Un=new WeakMap,Hs=new WeakMap,fs=new WeakMap,er=new WeakMap,ms=new WeakMap,zo=new WeakMap,tr=new WeakMap,hs=new WeakMap,Ho=new WeakMap,jo=new WeakMap,Go=new WeakMap,Pn=new WeakMap,vn=new WeakMap,js=new WeakMap,Gs=new WeakMap,Wo=new WeakMap,nr=new WeakMap,nn=new WeakMap,gs=new WeakSet,Fo=function(t,s){if(re(this,ms)!==void 0)return re(this,zo)?(re(this,tr)??$e(this,tr,oc(re(this,ms)))).test(t):t===re(this,ms);let i=re(this,jo),o=re(this,Go);if(s===void 0){let h=t.length,b=h+1>>1;if(ho)return!1;(bo)&&(s=Zi(t))}if(s!==void 0&&(s.lengtho))return!1;let r=re(this,Pn).length;if(re(this,Wo))if(re(this,js)!==void 0&&re(this,Gs)!==void 0){if(!t.startsWith(re(this,js))||!t.endsWith(re(this,Gs)))return!1}else{s??(s=Zi(t));let h=s.length-re(this,vn).length;if(!nc(re(this,Pn),s,0)||!nc(re(this,vn),s,h))return!1}let d=!this.options.dot&&t.startsWith(".");if(re(this,hs)){if(t==="."||t===".."||d&&!r)return!1;if(re(this,Ho))return!0;s??(s=Zi(t));let h=s.length-re(this,vn).length;return sv(re(this,hs),s,r,h)}if(s??(s=Zi(t)),t==="."||t===".."){re(this,fs)??$e(this,fs,tc(re(this,Hs)));let h=re(this,er)??$e(this,er,new Uo(!0,!1,re(this,fs))),b=h.state();h.add(b,re(this,Un),0,!0);let m=h.done(b);for(let w=0;w{if(typeof e!="string")throw new TypeError("invalid pattern");if(e.length>65536)throw new TypeError("pattern is too long")};var zn=(e,{windowsPathsNoEscape:t=!1,magicalBraces:s=!1}={})=>s?t?e.replace(/[?*()[\]{}]/g,"[$&]"):e.replace(/[?*()[\]\\{}]/g,"\\$&"):t?e.replace(/[?*()[\]]/g,"[$&]"):e.replace(/[?*()[\]\\]/g,"\\$&");var vs=(e,{windowsPathsNoEscape:t=!1,magicalBraces:s=!0}={})=>s?t?e.replace(/\[([^/\\])\]/g,"$1"):e.replace(/((?!\\).|^)\[([^/\\])\]/g,"$1$2").replace(/\\([^/])/g,"$1"):t?e.replace(/\[([^/\\{}])\]/g,"$1"):e.replace(/((?!\\).|^)\[([^/\\{}])\]/g,"$1$2").replace(/\\([^/{}])/g,"$1");var Bt=(e,t,s={})=>(Ko(t),!s.nocomment&&t.charAt(0)==="#"?!1:lv(t,s).match(e)),Ws=new Map,av=256,lv=(e,t)=>{let s=e+"\0"+JSON.stringify(t),i=Ws.get(s);return i?Ws.delete(s):(i=new ys(e,{...t}),Ws.size>=av&&Ws.delete(Ws.keys().next().value)),Ws.set(s,i),i},vc=typeof process=="object"&&process?process.env?.__MINIMATCH_TESTING_PLATFORM__||process.platform:"posix",pc={win32:{sep:"\\"},posix:{sep:"/"}},dv=vc==="win32"?pc.win32.sep:pc.posix.sep;Bt.sep=dv;var vt=Symbol("globstar **");Bt.GLOBSTAR=vt;var uv=(e,t={})=>s=>Bt(s,e,t);Bt.filter=uv;var Dn=(e,t={})=>Object.assign({},e,t),cv=e=>{if(!e||typeof e!="object"||!Object.keys(e).length)return Bt;let t=Bt;return Object.assign((i,o,r={})=>t(i,o,Dn(e,r)),{Minimatch:class extends t.Minimatch{constructor(o,r={}){super(o,Dn(e,r))}static defaults(o){return t.defaults(Dn(e,o)).Minimatch}},unescape:(i,o={})=>t.unescape(i,Dn(e,o)),escape:(i,o={})=>t.escape(i,Dn(e,o)),filter:(i,o={})=>t.filter(i,Dn(e,o)),defaults:i=>t.defaults(Dn(e,i)),braceExpand:(i,o={})=>t.braceExpand(i,Dn(e,o)),match:(i,o,r={})=>t.match(i,o,Dn(e,r)),sep:t.sep,GLOBSTAR:vt})};Bt.defaults=cv;var yc=(e,t={})=>(Ko(e),t.nobrace||!/\{(?:(?!\{).)*\}/.test(e)?[e]:xu(e,{max:t.braceExpandMax}));Bt.braceExpand=yc;var pv=(e,t,s={})=>{let i=new ys(t,s);return e=e.filter(o=>i.match(o)),i.options.nonull&&!e.length&&e.push(t),e};Bt.match=pv;var fc=/[?*]|[+@!]\(.*?\)|\[|\]/,bc=(e,t)=>{let s=t+1;(e.charAt(s)==="!"||e.charAt(s)==="^")&&s++;let i=!1;for(;s{if(!t&&(e==="+()"||e==="@()"))return e;let s="";for(let i=0;i{if(/^[?*+@]\(\)$/.test(e)||e.includes("[:"))return!1;let t=0;for(let s=0;stypeof e=="string"?t===e:t!==""&&e.testUnchecked(t),hc=(e,t,s,i,o)=>Hn(e,t)?s:i!==void 0&&Hn(e,i)?o:-1,$a=e=>e==="."||e==="..",qa=e=>typeof e=="string"&&/^[a-z]:$/i.test(e),or=e=>typeof e=="string"&&/^unc$/i.test(e),_a=e=>{if(e[0]!==""||e[1]!=="")return-1;let t=e[2]!=="?"?2:or(e[3])?4:-1,s=e[t],i=e[t+1];return t!==-1&&s!==void 0&&s!==""&&s!==vt&&i!==void 0&&i!==""&&i!==vt?t:-1},sr=(e,t)=>!$a(e)&&(t||!e.startsWith(".")),Yo=(e,t,s,i,o)=>{for(let r=t;r=s||rr(e.charCodeAt(p),o))return!0}let d=Fa(e,r,o);if(d===-1)return!1;for(r=d+1;rt==="/"?e===47:t==="\\"?e===92:e===47||e===92,Fa=(e,t,s)=>{if(s!=="both")return e.indexOf(s,t);let i=e.indexOf("/",t),o=e.indexOf("\\",t);return i===-1?o:o===-1?i:Math.min(i,o)},gc=(e,t,s)=>s!=="both"?e.lastIndexOf(s,t):Math.max(e.lastIndexOf("/",t),e.lastIndexOf("\\",t)),La={},jn,Ys,Gn,An,Xs,Js,Wn,Jo,Qs,Qo,Le,ir,Xo,wc,kc,Cc,Ec,Sc,Nc,Ua,Rc,Pc,Ba,Ks,za,ys=class{constructor(t,s={}){qe(this,Le);xe(this,"options");xe(this,"set");xe(this,"pattern");xe(this,"windowsPathsNoEscape");xe(this,"nonegate");xe(this,"negate");xe(this,"comment");xe(this,"empty");xe(this,"preserveMultipleSlashes");xe(this,"partial");xe(this,"globSet");xe(this,"globParts");xe(this,"nocase");xe(this,"isWindows");xe(this,"platform");xe(this,"windowsNoMagicRoot");xe(this,"maxGlobstarRecursion");qe(this,jn);qe(this,Ys);qe(this,Gn);qe(this,An);qe(this,Xs,[]);qe(this,Js,[]);qe(this,Wn,[]);qe(this,Jo,new Map);qe(this,Qs,!1);qe(this,Qo,new WeakMap);Ko(t),s=s||{},this.options=s,this.maxGlobstarRecursion=s.maxGlobstarRecursion??200,this.pattern=t,this.platform=s.platform||vc,this.isWindows=this.platform==="win32";let i="allowWindowsEscape";this.windowsPathsNoEscape=!!s.windowsPathsNoEscape||s[i]===!1,this.windowsPathsNoEscape&&(this.pattern=this.pattern.replace(/\\/g,"/")),this.preserveMultipleSlashes=!!s.preserveMultipleSlashes,this.negate=!1,this.nonegate=!!s.nonegate,this.comment=!1,this.empty=!1,this.partial=!!s.partial,this.nocase=!!this.options.nocase,this.windowsNoMagicRoot=s.windowsNoMagicRoot!==void 0?s.windowsNoMagicRoot:!!(this.isWindows&&this.nocase),this.globSet=[],this.globParts=[],this.set=[],$e(this,jn,!this.preserveMultipleSlashes),$e(this,Gn,(s.optimizationLevel??1)>=2);let o=s.normalize;$e(this,An,o===!0?"NFC":o||void 0),this.make();let r=this.set.map(d=>_e(this,Le,Xo).call(this,d));$e(this,Wn,this.set.map((d,p)=>re(this,jn)&&d.length-1>r[p])),$e(this,Xs,this.set.map((d,p)=>{let u=re(this,Wn)[p]?d.length-1:d.length,y=d.slice(r[p]+1,u).filter(h=>typeof h=="string"&&!!h);return[...new Set(y)]})),$e(this,Ys,re(this,Xs).some(d=>d.length)),$e(this,Js,this.set.map((d,p)=>{let[u,y,h]=d;if(re(this,Wn)[p]&&d.length===2&&u===vt&&y!==vt)return"tail";if(re(this,Wn)[p]&&s.matchBase&&d.length===1&&u!==vt&&u!=="")return"base";if(!(!re(this,jn)||r[p]!==-1)){if(d.length===3&&u===vt&&h===vt&&y!==vt&&y!==""&&this.maxGlobstarRecursion>0)return"mid";if(d.length===2&&y===vt&&u!==vt&&u!=="")return"head"}}))}hasMagic(){if(this.options.magicalBraces&&this.set.length>1)return!0;for(let t of this.set)for(let s of t)if(typeof s!="string")return!0;return!1}make(){let t=this.pattern,s=this.options;if(!s.nocomment&&t.charAt(0)==="#"){this.comment=!0;return}if(!t){this.empty=!0;return}this.parseNegate(),this.globSet=[...new Set(this.braceExpand())];let i=this.globSet.map(r=>_e(this,Le,za).call(this,r));this.globParts=this.preprocess(i),$e(this,Qs,!0);let o=this.globParts.map((r,d,p)=>{if(this.isWindows&&this.windowsNoMagicRoot){let u=r[2]==="?"&&or(r[3])?6:4,y=r[0]===""&&r[1]===""&&(r[2]==="?"||!fc.test(r[2]))&&r.slice(3,u).every(b=>!fc.test(b)),h=/^[a-z]:/i.test(r[0]);if(y)return[...r.slice(0,u).map(b=>_e(this,Le,ir).call(this,b)),...r.slice(u).map(b=>this.parse(b))];if(h)return[_e(this,Le,ir).call(this,r[0]),...r.slice(1).map(b=>this.parse(b))]}return r.map(u=>this.parse(u))});if(this.set=o.filter(r=>r.indexOf(!1)===-1),this.isWindows)for(let r=0;r{for(let p=0;pi.length));for(let i=0;i{if(!(d[i]instanceof Bo||d[i]===La)||!mv(this.globParts[p][i]))return;let u=[...this.globParts[p]];u[i]="";let y=`${d.length}/${u.join("/")}`,h=o.get(y);h?h.push(p):o.set(y,[p])});let r=new Set;for(let d of o.values()){if(d.length<2)continue;let[p,...u]=d,h=`@(${d.map(b=>this.globParts[b][i]).join("|")})`;this.globParts[p][i]=h,this.set[p][i]=this.parse(h);for(let b of u)r.add(b)}r.size&&(t=!0,this.set=this.set.filter((d,p)=>!r.has(p)),this.globParts=this.globParts.filter((d,p)=>!r.has(p)))}}}preprocess(t){if(this.options.noglobstar)for(let i of t)for(let o=0;o=2?(t=this.firstPhasePreProcess(t),t=this.secondPhasePreProcess(t)):s>=1?t=this.levelOneOptimize(t):t=this.adjascentGlobstarOptimize(t),t}adjascentGlobstarOptimize(t){return t.map(s=>{let i=-1;for(;(i=s.indexOf("**",i+1))!==-1;){let o=i;for(;s[o+1]==="**";)o++;o!==i&&s.splice(i,o-i)}return s})}levelOneOptimize(t){return t.map(s=>{let i=_e(this,Le,Xo).call(this,s)+1;return s=s.reduce((o,r)=>{let d=o[o.length-1];return r==="**"&&d==="**"?o:r===".."&&o.length>i&&d&&d!==".."&&d!=="."&&d!=="**"?(o.pop(),o):(o.push(r),o)},[]),s.length===0?[""]:s})}firstPhasePreProcess(t){let{braceExpandMax:s=1e5}=this.options,i=!1;do{i=!1;for(let o of t){let r=-1;for(;(r=o.indexOf("**",r+1))!==-1;){let u=r;for(;o[u+1]==="**";)u++;u>r&&o.splice(r+1,u-r);let y=o[r+1],h=o[r+2],b=o[r+3];if(y!==".."||!h||h==="."||h===".."||!b||b==="."||b===".."||t.length>=s)continue;i=!0,o.splice(r,1);let m=o.slice(0);m[r]="**",t.push(m),r--}if(!this.preserveMultipleSlashes){for(let u=1;u1e3)return t;for(let s=0;ss.length)}partsMatch(t,s,i=!1){let o=0,r=0,d=[],p="";for(;o=0;y--)u=r[y];for(let y=0;y=0){let v=S;for(;v>0&&rr(t.charCodeAt(v-1),s);)v--;p=v===0?0:gc(t,v-1,s)+1,d=t.slice(p,v)}let R=re(this,Gn)&&($a(o)||o===""&&d!==void 0&&$a(d));i=R?-1:1,m=!R}let w=-1;if(m&&typeof b=="string"&&(w=hc(b,o,r,d,p),w===-1))continue;if(re(this,Ys)){for(let S of re(this,Xs)[y])if(!t.includes(S))continue e}if(m&&typeof b=="object"&&(w=hc(b,o,r,d,p),w===-1))continue;let N=re(this,Js)[y];if(N==="base"&&m)return"yes";if(N==="tail"&&m){if(re(this,Gn)&&Yo(t,0,w,!0,s))return"maybe";if(!Yo(t,0,w,u,s))return"yes";continue}if(N==="mid"||N==="head"){let S=_e(this,Le,Cc).call(this,t,h,N==="head",u,s);if(S!=="no")return S;continue}return"maybe"}return"no"},kc=function(t,s,i){let o=!!this.options.dot,r=t.length;if(i==="head"){if(r<2||!Hn(s[0],t[0]))return!1;for(let p=1;pp&&d.testUnchecked(t.slice(p,u)))&&!Yo(t,y,t.length,o,r))return"yes";if(i||Yo(t,p,y,o,r))return"no";p=y}return"no"},Ec=function(t){let s=Va;return s?.f===t&&s.isWindows===this.isWindows&&s.preserveMultipleSlashes===this.preserveMultipleSlashes&&s.normalize===re(this,An)?s:void 0},Sc=function(t){let{isWindows:s,preserveMultipleSlashes:i}=this,o=_e(this,Le,za).call(this,s?t.split("\\").join("/"):t),r=re(this,An);return r&&(o=o.map(d=>d.normalize(r))),Va={f:t,isWindows:s,preserveMultipleSlashes:i,normalize:r,parts:o},Va},Nc=function(t){let s=[...t],i=!1;do{if(i=!1,!this.preserveMultipleSlashes){for(let d=1;dt.length)return!1;let b=t.length-u.length;if(_e(this,Le,Ks).call(this,t,u,i,b,0))h=u.length;else{if(t[t.length-1]!==""||o+u.length===t.length||(b--,!_e(this,Le,Ks).call(this,t,u,i,b,0)))return!1;h=u.length+1}}if(!p.length){let b=!!h;for(let m=o;m{v[1]=N-S[E]});let R={head:y,body:h,tail:b,segments:m};return o[r]=R,R},Ba=function(t,s,i,o,r,d,p,u,y){let h=s[r];if(!h){if(d)return o>=i||o===i-1&&t[o]==="";for(let N=o;Ne.lastIndexOf(t)===s)}function ja(e){let t=(e||[]).filter(s=>typeof s=="string"&&s.length>0).map(s=>{let{negated:i,anchored:o,directoryOnly:r,body:d}=hv(s);return{negated:i,directoryOnly:r,matcher:new ys(d,{dot:!0,nonegate:!0,nocomment:!0,matchBase:!o&&!d.includes("/")})}});return(s,i=!1)=>{let o=(s||"").replace(/^\/+/,"");if(!o)return!1;let r=o.split("/"),d=r.slice(0,-1).map((u,y)=>r.slice(0,y+1).join("/")),p=i;for(let u of t){if(u.negated?!p:p)continue;(u.directoryOnly?d:[...d,o]).some(h=>u.matcher.match(h))&&(p=!u.negated)}return p}}var Xee=new Set("^$\\.*+?()[]{}|/dDsSwWbBnrtvf0cxupP".split(""));function Ga(e){let t=e.indexOf("=>");if(t<0)return{term:e,replacement:null};let s=e.slice(0,t).replace(/\s+$/,""),i=e.slice(t+2).replace(/^\s+/,"");return s?{term:s,replacement:i}:{term:e,replacement:null}}var Dc=new Set(["*","+","?","(",")","[","]","{","}","|","^","$"]);function Ac(e){let t=[];return String(e||"").split(` +`).forEach((s,i)=>{let{term:o}=Ga(s.trim());if(!o)return;let r=[];for(let d=0;d{let t=e.target;if(!t||t.tagName!=="IMG"||t.dataset.failed||!t.closest?.(".markdown-body, .anonymize-preview-body"))return;t.dataset.failed="1";let s=window.document.createElement("span"),i=parseInt(t.getAttribute("width"),10)||0,o=parseInt(t.getAttribute("height"),10)||0;s.className=i>=200||o>=120?"img-unavailable is-large":"img-unavailable",s.textContent="Image unavailable",s.title=t.alt?"Image unavailable: "+t.alt.replace(/\bXXXX-(\d+)\b/g,"[redacted term $1]"):"Image unavailable",s.setAttribute("role","img"),s.setAttribute("aria-label",s.title),t.replaceWith(s)},!0);function ar(e){let t=e?.data;if(typeof t=="string")try{t=JSON.parse(t)}catch{t=null}return typeof t?.error=="string"&&Object.prototype.hasOwnProperty.call(Kn.ERRORS,t.error)?t.error:e?.status===-1||e?.status===0?"request_error":[502,503,504].includes(e?.status)?"unreachable":"unknown_error"}var lr="XXXX",vv=e=>{lr=e||"XXXX"},yv=(e=lr)=>{if(!e)return null;let t=e.replace(/[.*+?^${}()|[\]\\]/g,"\\$&");return new RegExp(t+"(?:-\\d+)?","g")},Oc=(e,t=lr)=>{let s=yv(t);if(!s||!e||!e.textContent.includes(t))return;let i=e.ownerDocument,o=i.createTreeWalker(e,NodeFilter.SHOW_TEXT),r=[];for(;o.nextNode();)r.push(o.currentNode);for(let d of r){let p=d.nodeValue,u=d.parentElement;if(!p.includes(t)||!u||u.closest("script, style, mark.redaction, .mermaid"))continue;let y=u.closest('code[class*="language-"]');if(y&&!y.contains(e))continue;let h=i.createDocumentFragment(),b=0;for(let m of p.matchAll(s)){h.append(p.slice(b,m.index));let w=i.createElement("mark");w.className="redaction",w.title="Redacted by Anonymous GitHub",w.textContent=m[0],h.append(w),b=m.index+m[0].length}h.append(p.slice(b)),d.replaceWith(h)}},Zo=/\bXXXX-\d+\b/g,_o=function(e){if(!e||e.indexOf("XXXX-")===-1||typeof window.DOMParser!="function")return e;let t=new window.DOMParser().parseFromString("
"+e+"
","text/html"),s=t.createTreeWalker(t.body,4),i=[];for(;s.nextNode();)Zo.lastIndex=0,!s.currentNode.parentElement?.closest("pre code")&&Zo.test(s.currentNode.nodeValue)&&i.push(s.currentNode);for(let o of i){Zo.lastIndex=0;let r=t.createDocumentFragment(),d=0,p,u=o.nodeValue;for(;p=Zo.exec(u);){r.appendChild(t.createTextNode(u.slice(d,p.index)));let y=t.createElement("mark");y.className="redact-chip",y.setAttribute("title","Redacted term "+p[0].slice(5)+" \u2014 the same term everywhere in this snapshot");let h=p[0].slice(5);y.textContent="";let b=t.createElement("i");b.textContent=h,y.appendChild(b),y.dataset.term=p[0],y.setAttribute("aria-label","Redacted term "+h);let m=/^[.,;:!?)\]]+/.exec(u.slice(p.index+p[0].length));if(m){let w=t.createElement("span");w.className="redact-glue",w.appendChild(y),w.appendChild(t.createTextNode(m[0])),r.appendChild(w),d=p.index+p[0].length+m[0].length}else r.appendChild(y),d=p.index+p[0].length}r.appendChild(t.createTextNode(u.slice(d))),o.parentNode.replaceChild(r,o)}return t.body.firstChild.innerHTML},Ic=()=>{window.Prism?.hooks&&!window.Prism.redactionHook&&(window.Prism.hooks.add("complete",e=>{Oc(e.element),e.element.querySelectorAll?.("mark.redaction").forEach(t=>{let s=/^XXXX-(\d+)$/.exec(t.textContent);if(!s)return;t.className="redact-chip",t.setAttribute("title","Redacted term "+s[1]+" \u2014 the same term everywhere in this snapshot"),t.setAttribute("aria-label","Redacted term "+s[1]),t.dataset.term=s[0],t.style.setProperty("--slot-ch",s[0].length+"ch"),t.textContent="";let i=t.ownerDocument.createElement("span");i.className="redact-src",i.textContent=s[0].slice(0,s[0].length-s[1].length),t.appendChild(i);let o=t.ownerDocument.createElement("i");o.textContent=s[1],t.appendChild(o)})}),window.Prism.redactionHook=!0)},Mc=(e,t=lr)=>{if(!e||!t||!e.includes(t))return e;let s=new DOMParser().parseFromString(""+e+"","text/html");return Oc(s.body,t),s.body.innerHTML};async function Wa(e){if(window.navigator.clipboard?.writeText){await window.navigator.clipboard.writeText(e);return}let t=document.createElement("textarea");t.value=e,t.setAttribute("readonly",""),t.style.position="fixed",t.style.opacity="0";let s=document.activeElement;document.body.appendChild(t);try{if(t.select(),!document.execCommand?.("copy"))throw Error("Copy unavailable")}finally{t.remove(),s?.focus()}}function bv(e){if(!["ArrowLeft","ArrowRight","Home","End"].includes(e.key))return;let t=[...e.currentTarget.closest('[role="tablist"]').querySelectorAll('[role="tab"]')],s=t.indexOf(e.currentTarget),i=e.key==="Home"?0:e.key==="End"?t.length-1:(s+(e.key==="ArrowRight"?1:-1)+t.length)%t.length;e.preventDefault(),t[i]?.focus(),t[i]?.click()}var Vc=function(e,t,s,i){e.previewTabKeydown=bv,e.headerCanUpgrade=!1,e.headerShowSupport=!1,e.headerBillingPending=new URLSearchParams(window.location.search).get("billing")==="success";let o=R=>{e.headerShowSupport=!(R?.grants||[]).some(E=>["active","paid","past_due"].includes(E.status)&&new Date(E.until).getTime()>Date.now());let v=(R?.grants||[]).some(E=>["author_monthly","author_annual"].includes(E.planId)&&["active","paid","past_due"].includes(E.status)&&new Date(E.until).getTime()>Date.now());e.headerCanUpgrade=!!R?.enabled&&R.checkoutEnabled!==!1&&!v&&(R.plans||[]).some(E=>["author_monthly","author_annual"].includes(E.id))};e.on("billing:updated",(R,v)=>o(v)),e.on("billing:pending",(R,v)=>{e.headerBillingPending=v}),e.openHeaderUpgrade=()=>{s.path()==="/profile"?e.emit("settings:upgrade"):s.url("/profile?upgrade=1")};let r=Ut(),d=Ct(),p=!1,u=()=>{p=!1;let R=document.querySelector("nav.navbar.navbar-expand-lg");if(!R||(R.classList.remove("nav-fit-1","nav-fit-2"),window.innerWidth<992))return;let v=R.querySelector(".navbar-collapse"),E=()=>R.scrollWidth>R.clientWidth+1||!!v&&v.scrollWidth>v.clientWidth+1;E()&&R.classList.add("nav-fit-1"),E()&&R.classList.add("nav-fit-2")},y=()=>{p||(p=!0,tt(()=>d.timeout(u,0)))};r(window,"resize",y),e.on("routeChange",y),e.on("billing:updated",y),document.fonts?.ready&&document.fonts.ready.then(y).catch(()=>{}),e.title="Main",e.user={status:"connection"},e.site_options,e.toasts=[],e.removeToast=function(R){let v=e.toasts.indexOf(R);v!==-1&&e.toasts.splice(v,1)},e.addToast=function(R){return e.toasts.push(R),i(function(){e.removeToast(R)},8e3),R};let h=/^\/(r|repository|pr|gist)\//;e.path=s.url(),e.paths=s.path().substring(1).split("/"),e.isReviewerRoute=h.test(s.path()),e.darkMode=function(R){localStorage.setItem("darkMode",R),e.isDarkMode=R;let v="/css/prism.css";if($("link[href='/css/prism-okaidia.css']").remove(),R)$("body").addClass("dark-mode"),$(`link[href='${v}']`).remove();else if($("body").removeClass("dark-mode"),!document.querySelector(`link[href='${v}']`)){let E=document.createElement("link");E.href=v,E.rel="stylesheet",document.head.append(E)}e.emit("dark-mode",R)},e.darkMode(localStorage.getItem("darkMode")=="true"),e.emailPromptOpen=!1,e.emailPromptAddress="",e.emailPromptBusy=!1,e.emailPromptError="";let b;e.respondToEmailPrompt=async R=>{if(!e.emailPromptBusy){e.emailPromptBusy=!0,e.emailPromptError="";try{let v=await t.post("/github/connections/email",{action:R,email:e.emailPromptAddress},{headers:{"X-CSRF-Token":e.user.emailPromptCSRF}});R==="save"&&(e.user.notificationEmail=v.data.notificationEmail),e.emailPromptOpen=!1,e.user.showEmailPrompt=!1,b?.focus()}catch(v){e.emailPromptError=v.data?.error||"Unable to save your preference. Please try again."}finally{e.emailPromptBusy=!1}}};function m(){t.get("/api/user").then(R=>{R&&(e.user=R.data),y(),e.user?.username?Wi(t).then(v=>o(v.data)).catch(()=>{}):e.headerShowSupport=!0,e.user?.emailNotificationsEnabled&&e.user.showEmailPrompt&&!e.user.notificationEmail&&(b=document.activeElement,e.emailPromptOpen=!0,i(()=>{let v=document.getElementById("email-prompt");v?.showModal?v.showModal():v?.setAttribute("open",""),document.getElementById("email-prompt-address")?.focus()},0))},()=>{e.user=null,e.headerShowSupport=!0})}m();function w(){t.get("/api/options").then(R=>{R&&(e.site_options=R.data),vv(R?.data?.ANONYMIZATION_MASK),e.emit("site-options")},()=>{e.site_options=null})}w();function N(){t.get("/api/message").then(R=>{R&&(e.generalMessage=R.data)},()=>{e.generalMessage=null})}N();function S(R,v){v&&(e.title=v.title),e.path=s.url(),e.paths=s.path().substring(1).split("/"),e.isReviewerRoute=h.test(s.path())}e.on("routeChange",S),e.on("routeUpdate",S)},qc=function(e,t){let s=Ut(),i=Ct();e.faqQuery="",e.faqResults=0;let o=d=>(d||"").toLowerCase().normalize("NFD").replace(/[\u0300-\u036f]/g,"").replace(/\s+/g," ");e.filterFaq=()=>{let d=o(e.faqQuery).trim().split(" ").filter(Boolean),p=0;document.querySelectorAll(".faq-section .panel-group").forEach(u=>{let y=0;u.querySelectorAll(":scope > .panel").forEach(m=>{let w=m.dataset.faqText||(m.dataset.faqText=o(m.textContent)),N=d.every(S=>w.includes(S));m.classList.toggle("faq-hit",d.length>0&&N),m.hidden=d.length>0&&!N,N&&y++});let h=d.length>0&&y===0;u.hidden=h;let b=u.previousElementSibling;b?.classList.contains("faq-cat")&&(b.hidden=h),p+=y}),e.faqResults=d.length?p:0},e.clearFaqSearch=()=>{e.faqQuery="",e.filterFaq(),document.getElementById("faq-search-input")?.focus()};let r=()=>{let d=window.location.hash.slice(1),p=document.getElementById(d);if(!p?.classList.contains("panel-collapse"))return;$(p).collapse("show");let u=document.getElementById(p.getAttribute("aria-labelledby"));u?.setAttribute("tabindex","-1"),u?.focus({preventScroll:!0}),u?.scrollIntoView?.({block:"start"})};e.on("routeUpdate",()=>i.timeout(r,0)),s(window,"hashchange",r),i.timeout(r,0)},_c=function(e,t,s,i,o){e.settingsTab=/(?:billing|upgrade)=/.test(window.location.search)?"billing":"defaults",e.confirmDeleteAccount=!1,e.deleteUsername="",e.profilePastSubscription=()=>!e.profileAuthorGrant()&&(e.billing?.grants||[]).some(h=>["author_monthly","author_annual"].includes(h.planId)),e.showAuthorPlans=new URLSearchParams(window.location.search).get("upgrade")==="1",e.showRepositoryPass=!1,e.profilePlan="author_annual",e.openProfileUpgrade=()=>{e.settingsTab="billing",e.showAuthorPlans=!0,tt(()=>document.getElementById("settings-plan-comparison")?.focus())},e.on("settings:upgrade",()=>e.openProfileUpgrade()),e.profileAuthorPlans=()=>(e.billing?.plans||[]).filter(h=>["author_monthly","author_annual"].includes(h.id)),e.profileSelectedPlan=()=>e.profileAuthorPlans().find(h=>h.id===e.profilePlan)||e.profileAuthorPlans()[0],e.profilePassPlan=()=>(e.billing?.plans||[]).find(h=>h.id==="author_pass"),e.profileAddonPlans=()=>(e.billing?.plans||[]).filter(h=>Gi(h.id)).sort((h,b)=>+(b.id==="repo_pack")-+(h.id==="repo_pack")),e.profileAddonId="repo_pack",e.profilePackPlan=()=>(e.billing?.plans||[]).find(h=>h.id==="repo_pack"),e.profileSlotPlan=()=>(e.billing?.plans||[]).find(h=>h.id==="repo_slot"),e.profileRepositories=()=>(e.billing?.repositories||[]).filter(h=>h.status!=="removed"),e.openProfileAddon=h=>{h&&(e.profileAddonId=h),e.showRepositoryPass=!0,e.billingRepository="",tt(()=>{let b=document.getElementById("settings-addons-title");b?.scrollIntoView?.({block:"nearest",behavior:"smooth"}),b?.focus?.({preventScroll:!0})})};let r=["repo_slot","author_pass","repo_extend","repo_never"];e.profileSingleAddons=()=>e.profileAddonPlans().filter(h=>h.id!=="repo_pack").sort((h,b)=>r.indexOf(h.id)-r.indexOf(b.id)),e.profileSingleId="repo_slot",e.profileSingleAddon=()=>e.profileSingleAddons().find(h=>h.id===e.profileSingleId)||e.profileSingleAddons()[0],e.profileCheapestAddon=()=>[...e.profileSingleAddons()].sort((h,b)=>(h.amount??1/0)-(b.amount??1/0))[0],e.profileAuthorPlansByValue=()=>[...e.profileAuthorPlans()].sort((h,b)=>+(h.interval==="year")-+(b.interval==="year")),e.profilePackSummary=h=>h.parts.map(b=>b.planId==="repo_slot"?"Extra repository":`${e.profileGrantName(b)} until ${e.billingDate(b.until)}`).join(" \xB7 "),e.profileAddonFeatures=h=>({repo_pack:["One more repository, outside your free ones",`Its own ${e.billingBytes(e.profileSlotPlan()?.storage||e.profilePassPlan()?.storage)} of storage`,"Automatic updates for 180 days","Online for up to a year","No subscription"],repo_slot:["One more repository, outside your free ones",`Its own ${e.billingBytes(e.profileSlotPlan()?.storage)} of storage`,"Valid while the repository exists","Refresh it by hand"],author_pass:["Automatic updates for 180 days",`Its own ${e.billingBytes(e.profilePassPlan()?.storage)} of storage`,"No subscription"],repo_extend:["Online for up to one more year","Buy again to add another year","No subscription"],repo_never:["The link never expires","No subscription","Ends only if the payment is refunded"]})[h]||[],e.profileAddonBlurb=h=>({repo_slot:"One more repository",author_pass:"Auto-updates for 180 days",repo_extend:"Online one more year",repo_never:"The link never expires"})[h]||"",e.profileAuthorPurchase=()=>(e.billing?.purchases||[]).find(h=>h.recurring&&["active","overdue"].includes(h.status)),e.profileRepositoryExpiry=h=>h.status==="expired"?"expired":h.expirationMode==="never"?"never expires":h.expirationDate?"expires "+e.billingDate(h.expirationDate):"no date",e.profileAnnualSavings=()=>{let h=e.profileAuthorPlans().find(m=>m.interval==="month")?.amount,b=e.profileAuthorPlans().find(m=>m.interval==="year")?.amount;return h&&b&&b(e.billing?.purchases||[]).filter(b=>["active","overdue"].includes(b.status)===h),e.profilePurchaseStatus=h=>({active:"Active",overdue:"Payment overdue",ended:"Ended",refunded:"Refunded",disputed:"Disputed"})[h.status]||h.status,e.profilePurchaseTerm=h=>{let b=h.status&&!["active","overdue"].includes(h.status);if(h.recurring)return b?h.until?"Ended "+e.billingDate(h.until):"":(h.cancelAtPeriodEnd?"Ends ":"Renews ")+e.billingDate(h.until);if(h.planId==="repo_pack"){let m=h.parts.map(w=>w.until).filter(Boolean).map(w=>new Date(w).getTime());return b||!m.length?"":"Until "+e.billingDate(new Date(Math.max(...m)))}return h.until?(b||new Date(h.until).getTime()e.profileAddonPlans().find(h=>h.id===e.profileAddonId)||e.profileAddonPlans()[0],e.profileAuthorGrant=()=>(e.billing?.grants||[]).find(h=>["author_monthly","author_annual"].includes(h.planId)&&["active","paid","past_due"].includes(h.status)&&new Date(h.until).getTime()>Date.now()),e.profileConferencePlan=()=>(e.billing?.plans||[]).filter(h=>["conference_workshop","conference","conference_large"].includes(h.id)&&h.amount!=null).sort((h,b)=>h.amount-b.amount)[0],e.profileGrantName=h=>({author_monthly:"Author monthly",author_annual:"Author annual",author_pass:"Live updates",repo_extend:"Extended expiration",repo_never:"Never expire",repo_slot:"Extra repository",repo_pack:"Paper pack",conference:"Conference package",conference_workshop:"Workshop package",conference_large:"Large conference package"})[h.planId]||h.planId,Ki(e,t,()=>o.load().then(h=>{e.quota=h},console.error),{portalMessage:()=>{let h=e.profileAuthorGrant();return h?h.cancelAtPeriodEnd?`Renewal cancelled. Your access continues until ${e.billingDate(h.until)}.`:`Your subscription renews on ${e.billingDate(h.until)}.`:"Your billing details are up to date."}}),e.terms="",e.options={expirationMode:"remove",update:!1,image:!0,pdf:!0,notebook:!0,loc:!0,link:!0},e.saving=!1,e.message=null,e.error=null,e.accountEmail="",e.emailLoading=!0,e.emailCSRFReady=!1,e.emailSaving=!1,e.emailSaved=!1,e.emailError="";let d="";e.loadAccountEmail=async()=>{e.emailLoading=!0,e.emailError="";try{let h=await t.get("/github/connections/email");e.accountEmail=h.data.notificationEmail||"",d=h.data.csrf,e.emailCSRFReady=!!d}catch{e.emailError="Unable to load your email address. Please try again."}finally{e.emailLoading=!1}},e.saveAccountEmail=async()=>{if(!(e.emailSaving||e.emailLoading||!d)){e.emailSaving=!0,e.emailSaved=!1,e.emailError="";try{let h=await t.post("/github/connections/email",{email:e.accountEmail},{headers:{"X-CSRF-Token":d}});e.accountEmail=h.data.notificationEmail,e.user&&(e.user.notificationEmail=h.data.notificationEmail),e.emailSaved=!0}catch{e.emailError="Unable to save your email address. Check the address and try again."}finally{e.emailSaving=!1}}},e.loadAccountEmail(),o.load().then(h=>{e.quota=h},console.error);let p=ga(e,["terms","options"],"profile");e.discardDraft=()=>p.discard();function u(){t.get("/api/user/default").then(h=>{let b=h.data||{};b.terms&&(e.terms=b.terms.join(` +`)),e.options=Object.assign({},e.options,b.options),p.restore()})}u();let y=null;e.saveDefault=h=>{if(h&&h.preventDefault&&h.preventDefault(),e.saving)return;let b=p.checkpoint(),m={terms:e.terms.split(` +`).map(w=>w.trim()).filter(w=>w.length>0),options:e.options};e.saving=!0,e.error=null,t.post("/api/user/default",m).then(()=>{p.accept(b),e.saving=!1,e.message=e.unsavedChanges?null:"Saved",y&&i.cancel(y),y=i(()=>{e.message=null},2500)},w=>{e.saving=!1;let N=w&&w.data&&w.data.error,S="Unable to save your defaults. Please try again.";Promise.all([s("ERRORS."+N),s("ERRORS.unknown_error")]).then(([R,v])=>{e.error=N&&R!==v?R:S},()=>{e.error=S})})},e.deleteAccount=()=>{e.deletingAccount||!e.confirmDeleteAccount||e.deleteUsername!==e.user?.username||(e.deletingAccount=!0,t.delete("/api/user").then(()=>{window.location.href="/"},()=>{e.deletingAccount=!1,e.deleteError="Unable to delete the account. Please try again."}))}},Lc=function(e,t,s){e.repoId=null,e.repoUrl=null,e.claim=()=>{t.post("/api/repo/claim",{repoId:e.repoId,repoUrl:e.repoUrl}).then(i=>{s.url("/dashboard")},i=>{e.error=i.data,e.claimForm.repoUrl.setValidity("not_found",!1),e.claimForm.repoId.setValidity("not_found",!1)})}},$c=function(e,t,s,i,o){e.user&&!e.user.status&&s.url("/dashboard"),e.watch("user.status",()=>{e.user&&!e.user.status&&s.url("/dashboard")}),e.features=[{key:"anonymize",num:"01",eyebrow:"Anonymize",title:"Double-anonymous,",accent:"your rules.",text:"Choose what reviewers may see: links, images, PDFs, notebooks, GitHub Pages. Add your own terms, with regex if you need it, and pick the expiration date.",cta:"Start an anonymization",href:"/anonymize",url:"anonymous.4open.science/anonymize",img:"/imgs/anonymize.png",alt:"The anonymize form: source repository, terms to redact, options and a live README preview"},{key:"review",num:"02",eyebrow:"Review",title:"Reviewers browse",accent:"the real thing.",text:"Highlighted source code, rendered PDFs, images, and notebooks, in a familiar file explorer. GitHub Pages is also supported.",cta:"Open the example",href:"https://anonymous.4open.science/r/840c8c57-3c32-451e-bf12-0e20be300389/",target:"_self",url:"anonymous.4open.science/r/840c8c57-\u2026",img:"/imgs/explorer.png",alt:"The repository explorer with a file tree and a rendered README"},{key:"manage",num:"03",eyebrow:"Manage",title:"One dashboard,",accent:"until the decision.",text:"Monitor views, edit configuration, remove or update your repository. Program chairs can group submissions under a conference with one shared expiry.",cta:"Open the dashboard",href:"/dashboard",needsUser:!0,url:"anonymous.4open.science/dashboard",img:"/imgs/dashboard.png",alt:"The dashboard listing anonymized repositories with status, views and expiry"}],e.feature=e.features[0].key,e.selectFeature=function(p){e.feature=p},e.featureHref=function(p){return p.needsUser&&!e.user?"/signin":p.href},e.featureTarget=function(p){return p.needsUser&&!e.user?"_self":p.target||void 0},e.featureKeydown=function(p,u){let y={ArrowDown:1,ArrowRight:1,ArrowUp:-1,ArrowLeft:-1,Home:"first",End:"last"}[p.key];if(y===void 0)return;p.preventDefault();let h=e.features.length,b=y==="first"?0:y==="last"?h-1:(u+y+h)%h;e.feature=e.features[b].key,o(()=>{let m=i.document.getElementById("feature-tab-"+e.feature);m&&m.focus()})},e.demoText=`# DeepLearnUtils Developed by Jane Smith at MIT CSAIL. See Smith et al., "Attention That Works," 2026. -Contact: jane.smith@mit.edu`,e.demoTerms="Jane Smith, Smith, MIT CSAIL, jane.smith@mit.edu",e.demoParts=function(){let p=(e.demoTerms||"").split(/[,\n]/).map(h=>h.trim()).filter(Boolean).sort((h,w)=>w.length-h.length),u=h=>h.replace(/[.*+?^${}()|[\]\\]/g,"\\$&");if(!p.length)return[{text:e.demoText}];let y=new RegExp("("+p.map(u).join("|")+")","gi"),m={},b=0;return(e.demoText||"").split(y).filter(h=>h!=="").map(h=>{let w=p.find(R=>R.toLowerCase()===h.toLowerCase());return w?(m[w.toLowerCase()]||(m[w.toLowerCase()]=++b),{text:String(m[w.toLowerCase()]),redacted:!0,original:h}):{text:h}})},e.demoCount=()=>e.demoParts().filter(p=>p.redacted).length,e.cards=[{key:"repositories",total:0,label:"repositories anonymized"},{key:"users",total:0,label:"researchers"},{key:"pageViews",total:0,label:"page views"},{key:"pullRequests",total:0,label:"pull requests"}],e.statsEmpty=()=>!!e.stat&&e.cards.every(p=>!p.total);function r(){t.get("/api/stat/").then(p=>{e.stat=p.data,e.cards[0].total=p.data.nbRepositories,e.cards[1].total=p.data.nbUsers,e.cards[2].total=p.data.nbPageViews,e.cards[3].total=p.data.nbPullRequests}).catch(()=>{})}r();function d(p){let u={series:p,bars:[],viewW:100,deltaToday:0,pctChange:0,pctAbs:0,isUp:!0};if(!p||p.length<2)return u;let y=new Array(p.length-1);for(let S=1;S=2){let S=y[m-2];S&&(u.pctChange=(u.deltaToday-S)/S*100)}return u.pctAbs=Math.round(Math.abs(u.pctChange)),u.isUp=u.pctChange>=0,u}e.history={repositories:d([]),users:d([]),pageViews:d([]),pullRequests:d([])},t.get("/api/stat/history?days=60").then(p=>{let u=p.data||[];e.history={repositories:d(u.map(y=>y.nbRepositories||0)),users:d(u.map(y=>y.nbUsers||0)),pageViews:d(u.map(y=>y.nbPageViews||0)),pullRequests:d(u.map(y=>y.nbPullRequests||0))}}).catch(()=>{})},Fc=function(e,t,s,i,o,r){let d=Ct();e.on("routeLeave",function(){$('[data-toggle="tooltip"]').tooltip("dispose")}),e.watch("user.status",()=>{e.user==null&&s.url("/")}),e.user==null&&s.url("/"),d.timeout(()=>{$('[data-toggle="tooltip"]').tooltip()},250),e.quotaExpanded=!1,e.closeQuota=()=>{e.quotaExpanded=!1,tt(()=>document.querySelector(".dashboard-quota > summary")?.focus())},Bt()(document,"click",C=>{e.quotaExpanded&&!C.target.closest?.(".dashboard-quota")&&(e.quotaExpanded=!1)}),e.filtersExpanded=!1,e.projectView="all",e.selectedProject=null,e.projectName="",e.nameSaving=!1,e.nameError="",e.nameMessage="",e.needsAttention=C=>C.status==="error"||C._broken||u(C.status)==="progress"&&C._stale,e.attentionCount=()=>e.dashboardTotals?.attention??e.items.filter(e.needsAttention).length,e.hasProjects=()=>(e.dashboardTotals?.total??e.items.length)>0,e.setProjectView=C=>{e.projectView=C,C==="attention"&&(e.filters.status.error=!0,e.filters.status.progress=!0)},e.idleText=C=>{let L=va(C?.anonymizeDate||C?.lastView)||"";return/ ago$/.test(L)?"No activity for "+L.replace(/ ago$/,""):"No activity since "+L.replace(", "+new Date().getFullYear(),"")},e.projectDetailsId=C=>"project-details-"+encodeURIComponent(C._type+":"+(C._id||C._source||"unknown")),e.showProjectDetails=async C=>{e.selectedProject=C,e.projectName=C.projectName||"",e.nameError="",e.nameMessage="",await tt();let L=document.getElementById(e.projectDetailsId(C));L?.focus(),L?.scrollIntoView?.({block:"nearest"})},e.closeProjectDetails=C=>{e.selectedProject=null,tt(()=>document.querySelector(`[data-project-actions="${encodeURIComponent(C._type+":"+C._id)}"]`)?.focus())},e.saveProjectName=async C=>{if(e.nameSaving||!C._id)return;let L=e.projectName.trim();if(L.length>100){e.nameError="Use 100 characters or fewer.";return}e.nameSaving=!0,e.nameError="",e.nameMessage="";try{let z=await t.post("/api/user/project-name",{type:C._type,id:C._id,name:L});C.projectName=z.data.name,C._label=C.projectName||C._fallbackLabel,e.selectedProject===C&&(e.nameMessage=L?"Project name saved.":"Default project name restored."),E||(e.dashboardCursor=null,await V(),e.selectedProject===C&&(e.selectedProject=e.items.find(K=>K._type===C._type&&K._id===C._id)||null))}catch{e.selectedProject===C&&(e.nameError="The project name could not be saved. Try again.")}finally{e.nameSaving=!1}},e.copyingId=null,e.copyLink=async C=>{if(!C._viewUrl||e.copyingId)return;let L=new URL(C._viewUrl,o.location.origin).href;e.copyingId=C._type+":"+C._id;try{await Wa(L),e.addToast({title:"Link copied",body:"The anonymous link is ready to share."})}catch{e.addToast({title:"Copy this anonymous link",body:L})}finally{e.copyingId=null}},e.items=[],e.search="",e.loading=!0,e.statusKeyLabels={ready:"Ready",progress:"Preparing",error:"Error",expired:"Expiring / expired",removed:"Removing / removed"};let p=["queue","download","downloaded","preparing","anonymizing"];function u(C){return C==="ready"||C==="error"?C:C==="expired"||C==="expiring"?"expired":C==="removed"||C==="removing"?"removed":(p.indexOf(C)>-1,"progress")}let y=7200*1e3,m="dashboard.filterPrefs",b={typeFilter:"all",filters:{status:{ready:!0,progress:!0,error:!0,expired:!0,removed:!1}},orderBy:"-anonymizeDate"},h=loadFilterPrefs(m)||{};e.typeFilter=h.typeFilter||b.typeFilter,e.filters={status:Object.assign({},b.filters.status,h.filters&&h.filters.status||{})},e.orderBy=h.orderBy||b.orderBy;let w={_name:{label:"Anonymous ID",defaultDesc:!1},_label:{label:"Project",defaultDesc:!1},anonymizeDate:{label:"Anonymize date",defaultDesc:!0},status:{label:"Status",defaultDesc:!1},lastView:{label:"Last view",defaultDesc:!0},pageView:{label:"Views",defaultDesc:!0},"options.expirationDate":{label:"Expiration",defaultDesc:!1}};e.sortFields=w,e.sortField=()=>e.orderBy.replace(/^-/,""),e.sortDesc=()=>e.orderBy.charAt(0)==="-",e.sortLabel=()=>{let C=w[e.sortField()];return C?C.label:"Custom"},e.isSortedBy=C=>e.sortField()===C,e.setSort=(C,L)=>{typeof L!="boolean"&&(L=e.isSortedBy(C)?!e.sortDesc():!!(w[C]&&w[C].defaultDesc)),e.orderBy=(L?"-":"")+C},e.toggleSortDirection=()=>{e.setSort(e.sortField(),!e.sortDesc())},e.watchGroup(["typeFilter","orderBy"],()=>{saveFilterPrefs(m,{typeFilter:e.typeFilter,filters:e.filters,orderBy:e.orderBy})}),e.watch("filters",()=>{saveFilterPrefs(m,{typeFilter:e.typeFilter,filters:e.filters,orderBy:e.orderBy})},!0),r.load().then(C=>{e.quota=C},console.error);function R(C,L,z,K,ie,se){C.pageView||(C.pageView=0),C.lastView||(C.lastView=""),C.options=C.options||{},C.options.terms=(C.options.terms||[]).filter(he=>he),C._id=L||"",C._source=K,C._broken=!L,C._name=L||K||"(unnamed)",C._fallbackLabel=C._type==="gist"?"Gist "+(L||K||"without an ID"):K||z||C._name,C._label=C.projectName||C._fallbackLabel,C._editUrl=L?ie:null,C._viewUrl=L?se:null,C._broken&&(C.status="error",C.statusMessage="incomplete_record"),C._statusKey=u(C.status);let Y=C.anonymizeDate||C.lastView;if(C._stale=C._statusKey==="progress"&&!!Y&&Date.now()-new Date(Y).getTime()>y,C.status==="expired"||C.status==="expiring")C._expiry={kind:"expired",date:C.options.expirationDate},C._expiry.label=ba(C.options.expirationDate)||void 0;else if(C.status!=="ready")C._expiry={kind:"none"};else if(C.options.expirationMode==="never"||!C.options.expirationDate)C._expiry={kind:"never"};else{C._expiry={kind:"date",date:C.options.expirationDate};let he=new Date(C.options.expirationDate).getTime()-Date.now();if(he>0&&he<=168*3600*1e3){let Se=Math.max(1,Math.round(he/36e5)),Ue=Math.round(he/864e5);C._expiry.soon=Se<48?"in "+Se+(Se===1?" hour":" hours"):"in "+Ue+" days"}}return C}function S(C){return t.get(C).then(L=>L.data||[],L=>(console.error(L),[]))}function N(){return e.loading=!0,i.all([S("/api/user/anonymized_repositories"),S("/api/user/anonymized_pull_requests"),S("/api/user/anonymized_gists")]).then(C=>{let L=C[0],z=C[1],K=C[2],ie=[];L.forEach(se=>{se._type="repo";let Y=se.source||{};ie.push(R(se,se.repoId,se.repoId,Y.fullName,"/anonymize/"+se.repoId,"/r/"+se.repoId+"/"))}),z.forEach(se=>{se._type="pr";let Y=se.source||{};ie.push(R(se,se.pullRequestId,se.pullRequestId,Y.repositoryFullName?Y.repositoryFullName+"#"+Y.pullRequestId:void 0,"/pull-request-anonymize/"+se.pullRequestId,"/pr/"+se.pullRequestId+"/"))}),K.forEach(se=>{se._type="gist";let Y=se.source||{};ie.push(R(se,se.gistId,se.gistId,Y.gistId,"/gist-anonymize/"+se.gistId,"/gist/"+se.gistId+"/"))}),e.items=ie,e.removedCount=ie.filter(se=>se._statusKey==="removed").length,e.loading=!1})}let v=0,E=!1;e.dashboardCursor=null,e.dashboardError="";function M(C){let L=C.source||{};return C._type==="repo"?R(C,C.repoId,C.repoId,L.fullName,"/anonymize/"+C.repoId,"/r/"+C.repoId+"/"):C._type==="pr"?R(C,C.pullRequestId,C.pullRequestId,L.repositoryFullName?L.repositoryFullName+"#"+L.pullRequestId:void 0,"/pull-request-anonymize/"+C.pullRequestId,"/pr/"+C.pullRequestId+"/"):R(C,C.gistId,C.gistId,L.gistId,"/gist-anonymize/"+C.gistId,"/gist/"+C.gistId+"/")}function V(C=!1){if(E)return N();let L=++v;return e.loading=!C,e.loadingMore=C,e.dashboardError="",t.get("/api/user/dashboard",{params:{q:e.search,type:e.typeFilter,sort:e.orderBy,statuses:Object.keys(e.filters.status).filter(z=>e.filters.status[z]!==!1).join(",")||"none",attention:String(e.projectView==="attention"),cursor:C?e.dashboardCursor:void 0}}).then(z=>{if(L===v){if(!Array.isArray(z.data?.items))return E=!0,N();e.items=(C?e.items:[]).concat(z.data.items.map(M)),e.dashboardCursor=z.data.cursor,e.dashboardTotals=z.data,C||te()}},z=>{if(L===v){if(z.status===404)return E=!0,N();e.dashboardError="Projects could not be loaded. Please try again."}}).finally(()=>{L===v&&(e.loading=!1,e.loadingMore=!1)})}e.loadMoreProjects=()=>V(!0);let _;e.watchGroup(["search","typeFilter","orderBy","projectView"],()=>{E||(_&&d.timeout.cancel(_),_=d.timeout(()=>V(),150))},!1),e.watch("filters",()=>{E||V()},!0,!1),e.on("dispose",()=>{v++}),V(),e.openItem=(C,L)=>{if(!C._viewUrl)return;let z=L&&L.target;z&&z.closest&&z.closest("a, button, .dropdown, input")||(o.location.href=C._viewUrl)},e.hiddenStatusCount=()=>Object.keys(e.filters.status).filter(C=>e.filters.status[C]===!1).length,e.hasHiddenStatus=()=>e.hiddenStatusCount()>0;let G=()=>Object.keys(e.statusKeyLabels);e.onlyRemovedShown=()=>G().every(C=>C==="removed"==(e.filters.status[C]!==!1)),e.isActiveDefault=()=>G().every(C=>C==="removed"==(e.filters.status[C]===!1)),e.statusView=()=>e.projectView==="attention"?"attention":e.onlyRemovedShown()?"removed":e.filters.status.removed===!1?"active":"custom",e.setStatusView=C=>{if(C==="attention")return e.setProjectView("attention");e.projectView="all",G().forEach(L=>{e.filters.status[L]=C==="removed"?L==="removed":L!=="removed"})},e.statusChipKeys=()=>{let C=e.statusView();return C==="removed"?[]:G().filter(L=>e.filters.status[L]===!1&&!(L==="removed"&&C!=="custom"))},e.removedCount=null;function te(){if(E){e.removedCount=e.items.filter(L=>L._statusKey==="removed").length;return}let C=e.dashboardTotals;!C||e.projectView!=="all"||e.search.trim()||e.typeFilter!=="all"||(e.isActiveDefault()?e.removedCount=Math.max(0,C.total-C.filtered):e.onlyRemovedShown()&&(e.removedCount=C.filtered))}e.showViewTabs=()=>e.statusView()!=="active"||e.attentionCount()>0||e.removedCount>0||e.removedCount==null&&!!e.dashboardTotals&&e.dashboardTotals.total>e.dashboardTotals.filtered,e.hasActiveFilters=()=>e.projectView!=="all"||e.typeFilter!=="all"||e.search.trim().length>0||Object.keys(e.filters.status).some(C=>e.filters.status[C]===!1),e.showClearFilters=()=>e.search.trim().length>0||e.typeFilter!=="all"||e.statusChipKeys().length>0,e.isPlainView=()=>!e.showClearFilters(),e.clearFilters=()=>{let C=e.statusView();e.typeFilter="all",e.search="",e.setStatusView(C==="removed"?"removed":"active")};function X(C,L,z,K){t.get("/api/repo/"+C).then(async ie=>{let se=K!==void 0&&K!==ie.data.status;for(let Y of e.items)if(Y._type==="repo"&&Y.repoId==C){se=se||Y.status!==ie.data.status;let he=e.needsAttention(Y);Y.status=ie.data.status,Y.statusMessage=ie.data.statusMessage,Y._statusKey=u(Y.status),Y._statusKey!=="progress"&&(Y._stale=!1);let Se=e.needsAttention(Y);e.dashboardTotals&&he!==Se&&(e.dashboardTotals.attention=Math.max(0,e.dashboardTotals.attention+(Se?1:-1)));break}if(se&&!E){e.dashboardCursor=null;let Y=e.selectedProject;await V(),Y&&e.selectedProject===Y&&(e.selectedProject=e.items.find(he=>he._type===Y._type&&he._id===Y._id)||null)}if(ie.data.status=="ready"||ie.data.status=="error"||ie.data.status=="removed"||ie.data.status=="expired"){L(ie.data);return}d.timeout(()=>X(C,L,z,ie.data.status),2500)},z)}let O=C=>C==="repo"?"repository":C==="gist"?"gist":"pull request",U=C=>C==="repo"?"/api/repo":C==="gist"?"/api/gist":"/api/pr";e.removeItem=C=>{let L=O(C._type);if(confirm(`Are you sure that you want to remove the ${L} ${C._id}?`)){let z=st({title:`Removing ${C._id}...`,date:new Date,body:`The ${L} ${C._id} is going to be removed.`});e.addToast(z);let K=`${U(C._type)}/${C._id}`;t.delete(K).then(()=>{C._type==="repo"?X(C._id,()=>{z.title=`${C._id} is removed.`,z.body=`The ${L} ${C._id} is removed.`},void 0,C.status):(z.title=`${C._id} is removed.`,z.body=`The ${L} ${C._id} is removed.`,V())},ie=>{z.title=`Error during the removal of ${C._id}.`,z.body=ie.body,V()})}},e.refreshItem=C=>{let L=O(C._type),z=st({title:`Refreshing ${C._id}...`,date:new Date,body:`The ${L} ${C._id} is going to be refreshed.`});e.addToast(z);let K=se=>{z.title=`Error during the refresh of ${C._id}.`,z.body=se.data?.error||se.body||"The refresh could not be completed. Please try again.",V()},ie=`${U(C._type)}/${C._id}/refresh`;t.post(ie).then(()=>{C._type==="repo"?X(C._id,se=>{if(se.status!=="ready"){K({body:se.statusMessage||`The repository is ${se.status}.`});return}z.title=`${C._id} is refreshed.`,z.body=`The ${L} ${C._id} is refreshed.`},K,C.status):(z.title=`${C._id} is refreshed.`,z.body=`The ${L} ${C._id} is refreshed.`,V())},K)},e.extendItem=C=>{let L=O(C._type),z=st({title:`Extending ${C._id}...`,date:new Date,body:`The expiration of ${L} ${C._id} is being extended.`});e.addToast(z);let K=`${U(C._type)}/${C._id}/extend`;t.post(K).then(ie=>{let se=ie?.data?.expirationDate?` until ${new Date(ie.data.expirationDate).toLocaleDateString(void 0,{year:"numeric",month:"short",day:"numeric"})}`:"";C._type==="repo"?X(C._id,()=>{z.title=`${C._id} is extended.`,z.body=`${L} ${C._id} is extended${se}.`},void 0,C.status):(z.title=`${C._id} is extended.`,z.body=`${L} ${C._id} is extended${se}.`,V())},ie=>{z.title=`Error during the extension of ${C._id}.`;let se=ie.data&&ie.data.error;z.body=se||ie.body,se&&Object.prototype.hasOwnProperty.call(Kn.ERRORS,se)&&(z.body=Kn.ERRORS[se]),V()})},e.itemFilter=C=>{if(e.projectView==="attention"&&!e.needsAttention(C)||e.typeFilter!=="all"&&C._type!==e.typeFilter||e.filters.status[C._statusKey]===!1)return!1;let L=e.search.trim().toLowerCase();return!!(L.length==0||C._label&&String(C._label).toLowerCase().indexOf(L)>-1||C._source&&String(C._source).toLowerCase().indexOf(L)>-1||C._id&&String(C._id).toLowerCase().indexOf(L)>-1||C.conference&&String(C.conference).toLowerCase().indexOf(L)>-1)}};var Uc=function(e,t,s){let i=Ct();e.repoId=s.repoId,e.reviewUrl=window.location.origin+"/r/"+encodeURIComponent(s.repoId)+"/",e.repo=null,e.progress=0,e.rateLimitResetAt=0,e.rateLimitCountdown="",e.shareUrl=(window.location?.origin||"")+"/r/"+encodeURIComponent(e.repoId)+"/",e.copied=!1;let o=null;e.copyShareUrl=async()=>{try{await Wa(e.shareUrl),e.copied=!0,o&&i.timeout.cancel(o),o=i.timeout(()=>{e.copied=!1},2e3)}catch{e.addToast?.({title:"Copy this anonymous link",body:e.shareUrl})}},e.selectShareUrl=m=>{let b=window.getSelection?.();if(!b||!m?.target)return;let h=document.createRange();h.selectNodeContents(m.target),b.removeAllRanges(),b.addRange(h)};var r=null;let d=null,p=!1;function u(m){e.rateLimitResetAt=m,r&&i.interval.cancel(r);function b(){var h=Math.max(0,Math.ceil((m-Date.now())/1e3));if(h<=0)e.rateLimitCountdown="",e.rateLimitResetAt=0,i.interval.cancel(r),r=null;else{var w=Math.floor(h/60),R=h%60;e.rateLimitCountdown=w>0?w+"m "+R+"s":R+"s"}}b(),r=i.interval(b,1e3)}e.on("dispose",function(){p=!0,r&&i.interval.cancel(r),d&&i.timeout.cancel(d)});function y(m){if(!m)return m;var b=m.match(/^rate_limited:(\d+)$/);return b?(u(parseInt(b[1],10)),null):(e.rateLimitResetAt=0,m)}e.getStatus=()=>{p||t.get("/api/repo/"+e.repoId,{repoId:e.repoId,repoUrl:e.repoUrl}).then(m=>{if(!p){e.repo=m.data,m.data.rateLimitResetAt?u(m.data.rateLimitResetAt):e.repo.statusMessage=y(e.repo.statusMessage),e.repo.status=="ready"?e.progress=100:e.repo.status=="queue"?e.progress=10:e.repo.status=="downloaded"?e.progress=50:e.repo.status=="download"||e.repo.status=="preparing"?e.progress=25:e.repo.status=="anonymizing"&&(e.progress=75);var b=!["ready","removed","expired"].includes(e.repo.status);e.repo.status=="error"&&!e.rateLimitResetAt&&(b=!1),b&&(d=i.timeout(e.getStatus,2e3))}},m=>{e.error=m.data.error})},e.getStatus()},dr=function(e,t,s,i,o,r,d){Ic(),e.renderRedacted=_o,e.sourceUrl="",e.workspaceOpen=!1,e.sourceUrlError="",e.previewStatus="idle",e.sourceLoading=!1,e.mobilePane="settings";let p=window.matchMedia?.("(max-width: 767px)");e.mobileWorkspace=!!p?.matches,p?.addEventListener&&Bt()(p,"change",k=>{e.mobileWorkspace=k.matches}),e.selectMobilePane=k=>{e.mobilePane=k};let u=0,y=!1,m=new Set,b=(k,I=!1)=>!y&&k.generation===u&&k.url===e.sourceUrl.trim()&&k.connection===e.githubConnection&&(!I||k.branch===e.source.branch),h=()=>{let k={generation:u,url:e.sourceUrl.trim(),connection:e.githubConnection,branch:e.source.branch};return m.add(k),e.sourceLoading=!0,k},w=k=>{m.delete(k),y||(e.sourceLoading=[...m].some(I=>b(I)))};e.on("dispose",()=>{y=!0,u++});let R=null,S=k=>k.gistId&&!k.repo?"gist:"+k.gistId.toLowerCase():(k.owner+"/"+k.repo).toLowerCase()+(k.pullRequestId?"/pull/"+k.pullRequestId:""),N=ga(e,["sourceUrl","terms","repoId","pullRequestId","gistId","source","options","conference","githubConnection"],"anonymize:"+(o.path?.()||"")),v=null,E=null,M=null;e.hostingReview=!1,e.previewExpanded=!1,e.taskValidationError="",e.editRepository=()=>{e.mobilePane="settings",e.previewExpanded=!1,tt(()=>document.querySelector(".anonymize-fields .is-invalid")?.focus())},e.submitRepository=k=>{if(e.taskValidationError="",!(e.sourceLoading||e.billingBusy||e.hostingSaving||e.billingPending)){if(ei()||e.anonymize?.invalid||e.sourceUrlError){e.taskValidationError="Check the highlighted fields before continuing.",e.editRepository();return}return e.hostingNeedsPayment()?e.checkoutRepository(Gi(e.hostingChoice())?e.hostingChoice():""):e.anonymizeRepo(k)}},e.hostingPayment=!1,e.hostingAlternatives=!1,e.hostingPrice=k=>k.amount==null?"Price shown at checkout":new Intl.NumberFormat(void 0,{style:"currency",currency:k.currency,minimumFractionDigits:0,maximumFractionDigits:2}).format(k.amount/100)+(k.interval==="year"?" billed annually":" billed monthly"),e.hostingPlan="",e.hostingSaving=!1,e.selectedHostingPlan=()=>e.authorPlans().find(k=>k.id===e.hostingPlan)||e.hostingSubscriptionPlan?.();let V=()=>t.get("/api/user/quota").then(k=>{e.hostingQuota=k.data});Ki(e,t,async()=>{await V(),e.hostingQuotaBlocked=!1},{confirmedMessage:"Hosting status refreshed. Your draft is ready to continue."}),V().catch(()=>{}),e.authorPlans=()=>(e.billing?.plans||[]).filter(k=>["author_monthly","author_annual"].includes(k.id)),e.conferenceHosting=()=>!!(e.conference&&e.conference_data?.hosting),e.hasAuthorHosting=()=>["author_monthly","author_annual"].includes(e.billing?.allowance?.plan),e.hostingNeedsPayment=()=>!e.billing?.enabled||e.detectedType!=="repo"||e.hasAuthorHosting()||e.isUpdate&&e.role!=="owner"?!1:!!(e.options?.expirationMode==="never"&&!e._existingNever&&!e.repositoryGrants("repo_never").length||!e.conferenceHosting()&&e.hostingQuotaBlocked),e.repositoryGrants=k=>(e.billing?.grants||[]).filter(I=>I.planId===k&&I.scope===`repo:${e.repoId}`&&["active","paid","past_due"].includes(I.status)&&new Date(I.until).getTime()>Date.now()),e.repositoryAddonPlans=()=>(e.billing?.plans||[]).filter(k=>Gi(k.id)&&(["repo_extend","repo_pack"].includes(k.id)||!e.repositoryGrants(k.id).length)),e.hostingOneTimePlans=()=>{let k=I=>I.map(B=>(e.billing?.plans||[]).find(j=>j.id===B&&!e.repositoryGrants(B).length)).filter(Boolean);return e.options?.expirationMode==="never"&&!e._existingNever&&!e.repositoryGrants("repo_never").length?k(["repo_never"]):e.hostingQuotaBlocked&&!e.conferenceHosting()?k(["repo_slot","repo_pack"]):[]},e.hostingOneTime=()=>e.hostingOneTimePlans()[0];let _=["free","repo_slot"];e.liveUpdatesIncluded=()=>{if(!e.billing?.enabled||e.detectedType!=="repo"||e.isUpdate&&e.role!=="owner"||e.conferenceHosting()||e.hasAuthorHosting())return!0;let k=e.billing?.allowance?.plan;return k&&!_.includes(k)?!0:e.repositoryGrants("author_pass").length>0||e.repositoryGrants("repo_pack").length>0},e.liveUpdatesPrice=()=>{let k=(e.billing?.plans||[]).find(I=>I.id==="author_pass");return k?.amount!=null?e.billingAmount(k):""},e.showHostingOptions=()=>{e.mobilePane="settings",tt(()=>document.getElementById("repository-hosting")?.scrollIntoView({block:"start",behavior:"smooth"}))},e.neverExpireTag=()=>{if(e.hasAuthorHosting())return"Included in your subscription";if(e.repositoryGrants("repo_never").length)return"Paid for this repository";let k=(e.billing?.plans||[]).find(I=>I.id==="repo_never");return k?.amount!=null?`${e.billingAmount(k)} once, or with a subscription`:"Subscription or one-time add-on"},e.hostingCycle="author_annual",e.hostingSubscriptionPlan=()=>e.authorPlans().find(k=>k.id===e.hostingCycle)||e.authorPlans().find(k=>k.interval==="year")||e.authorPlans()[0],e.hostingAnnualSavings=()=>{let k=e.authorPlans().find(B=>B.interval==="month")?.amount,I=e.authorPlans().find(B=>B.interval==="year")?.amount;return k&&I&&Ie.hostingOneTimePlans().concat(e.authorPlans().length?[e.hostingSubscriptionPlan()]:[]),e.hostingOptionName=k=>({repo_slot:"Add this repository",repo_pack:"Paper pack",repo_never:"Never expire",author_annual:"Author subscription",author_monthly:"Author subscription"})[k.id]||k.name,e.hostingOptionBlurb=k=>({repo_slot:"Hosted outside your free repositories. Refresh it by hand.",repo_pack:"Adds automatic updates for 180 days and keeps the link online for a year.",repo_never:"This link never expires. No subscription."})[k.id]||`${k.repositories} repositories, ${e.billingBytes(k.storage)}, automatic updates and links that never expire.`,e.hostingChoice=()=>{let k=e.hostingOneTimePlans();return k.some(I=>I.id===e.hostingPlan)||e.authorPlans().some(I=>I.id===e.hostingPlan)?e.hostingPlan:k[0]?.id||e.hostingSubscriptionPlan()?.id||""},e.checkoutRepository=async(k="")=>{if(!(e.hostingSaving||e.billingBusy||!e.billing?.csrf||e.sourceLoading)){e.hostingSaving=!0,e.billingError="";try{let I=N.checkpoint(),B=JSON.stringify(I);(!E||B!==M)&&(E=(await t.post("/api/billing/draft",{path:o.path(),values:I},{headers:{"x-csrf-token":e.billing.csrf}})).data.id,M=B);let j=e.authorPlans().find(ue=>ue.id===e.hostingPlan)||e.hostingSubscriptionPlan();if(!k&&!j)throw new Error("No author plan available");await e.checkout(k||j.id,k?e.repoId:"",{draftId:E})}catch{e.billingError="Your draft could not be saved for checkout. Your form is unchanged. Please try again."}finally{e.hostingSaving=!1}}},e.useDatedHosting=()=>{e.options.expirationMode="remove"},e.discardDraft=async()=>{N.discard(),e.workspaceOpen=!!e.sourceUrl,e.error=null,e.sourceUrl?await e.urlSelected(!0):(u++,e.sourceLoading=!1,e.detectedType=null,e.details=null,e.sourceUrlError="",Yt.cancel(),Tn.cancel(),On.cancel(),e.previewStatus="idle")},e.githubConnection=void 0,e.githubConnections=null,e.gistOAuthRequired=!1,e.gistAppRequired=!1;let G=()=>{let k={};for(let I of["sourceUrl","terms","repoId","pullRequestId","gistId","source","options","conference","githubConnection"])k[I]=e[I];sessionStorage.setItem("github-access-draft",JSON.stringify({path:o.path(),savedAt:Date.now(),draft:k}))};e.connectGistApp=()=>{G(),window.location.href="/github/app/login?returnTo="+encodeURIComponent(o.path())},e.connectGistOAuth=()=>{G(),window.location.href="/github/login?returnTo="+encodeURIComponent(o.path())},e.grantGitHubAccess=()=>{G();let k=o.path(),I=he(e.sourceUrl)||"",B=e.githubConnections?.appConnected?"/github/app/install":"/github/app/login";window.location.href=B+"?returnTo="+encodeURIComponent(k)+"&repository="+encodeURIComponent(I)+"&install=1"},e.chooseGitHubConnection=async k=>{e.githubConnection=k,e.readme="",e.sourceUrl&&await Ue()},e.detectedType=null,e.repoId="",e.pullRequestId="",e.gistId="",e.terms="",e.defaultTerms="",e.branches=[],e.source={branch:"",commit:""},e.options={expirationMode:"remove",expirationDate:new Date,update:!1,image:!0,pdf:!0,notebook:!0,link:!0,body:!0,title:!0,origin:!1,diff:!0,content:!0,comments:!0,username:!0,date:!0};function te(){let k=new Date;return k.setMonth(k.getMonth()+6),k}e.options.expirationDate=te();function X(k){let I=k.getFullYear(),B=String(k.getMonth()+1).padStart(2,"0"),j=String(k.getDate()).padStart(2,"0");return`${I}-${B}-${j}`}e.minExpirationDate=X(new Date);let O=()=>{let k=new Date,I=new Date(k);if(I.setFullYear(I.getFullYear()+1),e.billing?.enabled&&e.detectedType==="repo"&&!e.hasAuthorHosting()){I=new Date(k),I.setMonth(I.getMonth()+(e.billing.freeExpirationMonths||5));for(let ue of e.repositoryGrants("repo_extend"))new Date(ue.until)>I&&(I=new Date(ue.until));e.conference_data?.endDate&&new Date(e.conference_data.endDate)>I&&(I=new Date(e.conference_data.endDate)),e._savedExpirationDate&&e._savedExpirationDate>I&&(I=new Date(e._savedExpirationDate));let B=e.options?.expirationDate,j=e._savedExpirationDate&&B instanceof Date&&B.getTime()===e._savedExpirationDate.getTime();B instanceof Date&&B>I&&!j&&(e.options.expirationDate=new Date(I))}e.maxExpirationDate=X(I)};O(),e.watch(()=>[e.billing,e.repoId,e.conference_data,e.isUpdate,e._savedExpirationDate,e.options?.expirationMode,e.detectedType],O,!0,!1),e.anonymize_readme="",e.readme="",e.isUpdate=!1,e.userRepos=[],e.userReposStatus="idle",e.userRepoFilter="",e.loadUserRepos=(k=!1)=>{e.userReposStatus!=="loading"&&(e.userReposStatus="loading",t.get("/api/user/all_repositories",k?{params:{force:"1"}}:{}).then(I=>{if(y)return;let B=Array.isArray(I.data)?I.data.filter(j=>j&&j.fullName):[];e.userRepos=B.sort((j,ue)=>j.fullName.localeCompare(ue.fullName,void 0,{sensitivity:"base"})),e.userReposStatus="ready"},()=>{y||(e.userReposStatus="error")}))},e.filteredUserRepos=()=>{let k=String(e.userRepoFilter||"").trim().toLowerCase(),I=e.userRepos||[];return k?I.filter(B=>B.fullName.toLowerCase().includes(k)):I},e.selectUserRepo=k=>{if(k?.fullName)return e.sourceUrl="https://github.com/"+k.fullName,e.urlSelected()},!i.repoId&&!i.pullRequestId&&!i.gistId&&Promise.resolve().then(()=>{y||e.loadUserRepos()}),e.previousConfigurations=[],e.previousConfigurationId="";let U,C=k=>String(k||"").replace(/\/$/,"").replace(/\.git$/i,"").toLowerCase();async function L(){if(e.isUpdate||i.repoId||i.pullRequestId||i.gistId)return;let k={generation:u,url:e.sourceUrl.trim(),connection:e.githubConnection};try{U||(U=t.get("/api/user/anonymized_repositories").then(j=>j.data));let I=await U;if(!b(k))return;let B=C(he(k.url));e.previousConfigurations=I.filter(j=>j.repoId&&j.options&&C(j.source?.fullName)===B).sort((j,ue)=>(Date.parse(ue.anonymizeDate)||0)-(Date.parse(j.anonymizeDate)||0)),e.previousConfigurationId=e.previousConfigurations[0]?.repoId||""}catch{U=void 0}}e.sourceSummary=()=>{let k=String(e.sourceUrl||""),I=/github\.com\/([^/\s]+\/[^/\s]+)\/pull\/(\d+)/i.exec(k);return I?I[1]+" \xB7 PR #"+I[2]:(I=/gist\.github\.com\/([^/\s]+)\/([0-9a-f]{8,})/i.exec(k),I?I[1]+" \xB7 gist "+(I[2].length>12?I[2].slice(0,7)+"\u2026"+I[2].slice(-4):I[2]):"")},e.previewId=()=>e.detectedType==="pr"?e.pullRequestId:e.detectedType==="gist"?e.gistId:e.repoId,e.previewPath=()=>{let k=e.previewId();return k?(e.detectedType==="pr"?"/pr/":e.detectedType==="gist"?"/gist/":"/r/")+encodeURIComponent(k)+"/":""},e.previewUrl=()=>{let k=e.previewPath();return k?"anonymous.4open.science"+k.replace(/\/$/,""):""},e.previewRedactions=()=>{let k=j=>typeof j=="string"?(j.match(Zo)||[]).length:0;if(e.detectedType==="repo")return e.previewViewer.redactionCount();let I=e.detectedType==="pr"?ks:Cs,B=0;return I.forEach(j=>{B+=k(j)}),B};let z=(k,I)=>k.localeCompare(I,void 0,{sensitivity:"base"}),K=k=>k.slice(k.lastIndexOf("/")+1),ie={key:null,files:[]};e.previewTreeFiles=()=>{if(!e.preserve.commit||!ve)return[];let k=e.preserve.commit+"\0"+e.terms+"\0"+bs.size+"\0"+ve.files.length;if(ie.key===k)return ie.files;let I=ve.files.map(B=>{let j=e.previewPathName(B),ue=j.lastIndexOf("/");return{name:j.slice(ue+1),path:ue<0?"":j.slice(0,ue),size:0,sourcePath:B}});return ie={key:k,files:I},I},e.selectPreviewPath=k=>{let I=e.previewTreeFiles().find(B=>"/"+(B.path?B.path+"/":"")+B.name===k);I&&e.openPreviewFile(I.sourcePath)},e.existingConfigurationUrl=()=>{let k=e.previousConfigurations.find(I=>I.repoId===e.previousConfigurationId);return k?"/anonymize/"+encodeURIComponent(k.repoId):null};function se(k){t.get("/api/user/default").then(I=>{let B=I.data;B.terms&&(e.defaultTerms=B.terms.join(` -`)),e.options=Object.assign({},e.options,B.options),e.options.expirationDate=B.options&&B.options.expirationDate?new Date(B.options.expirationDate):te(),!i.repoId&&!i.pullRequestId&&!i.gistId&&!e.anonymize?.terms?.dirty&&(e.terms=e.defaultTerms),k&&k()})}function Y(k,I,B){e.anonymize&&e.anonymize[k]&&e.anonymize[k].setValidity(I,B)}function he(k){try{let I=parseGithubUrl(k);if(I&&I.owner&&I.repo)return I.owner+"/"+I.repo}catch{}return null}e.accessRepairAllowed=!1,e.repairingGitHubAccess=!1,e.accessRepairMessage="",e.repairGitHubAccess=async()=>{if(!e.accessRepairAllowed||e.repairingGitHubAccess||!e.githubConnections?.appEnabled||!i.repoId||e.role!=="owner"||e.githubConnection!=="github-app"||he(e.sourceUrl)!==e._originalFullName)return;e.repairingGitHubAccess=!0,e.accessRepairMessage="";let k=h();try{let I=await t.get("/github/connections");if(e.githubConnections=I.data,!I.data.appEnabled)return;let B=await t.post("/github/connections/migrate",{type:"repository",id:i.repoId,connection:"github-app"},{headers:{"X-CSRF-Token":I.data.csrf}});if(!b(k))return;e.error=null,B.data.fullName&&(e._originalFullName=B.data.fullName,e.source.fullName=B.data.fullName,e.sourceUrl="https://github.com/"+B.data.fullName),e.accessRepairMessage="GitHub access repaired. Your anonymous URL and published commit are unchanged.",await e.urlSelected(!0)}catch{b(k)&&(e.accessRepairMessage="Unable to repair GitHub access. Check the App's repository permissions in Manage access, then retry. Your published snapshot has not been replaced.")}finally{e.repairingGitHubAccess=!1,w(k)}},e.reconnectingSource=!1,e.reconnectRepositoryId=void 0,e.reconnectSource=async()=>{if(confirm("Reconnect to the repository currently at this GitHub URL? Review its branch and commit before saving. Saving will replace the published snapshot.")){e.reconnectingSource=!0,e.reconnectRepositoryId=void 0,e.source.commit="",e.source.branch="",e.readme="",e.branches=[];try{await Qe()}catch{}}};function Se(){return e.reconnectingSource||!e.isUpdate||!e._originalRepositoryID?void 0:he(e.sourceUrl)===e._originalFullName?e._originalRepositoryID:void 0}async function Ue(){e._preservingDraft=!0;try{await e.urlSelected(!0)}finally{e._preservingDraft=!1}}async function Be(){let k=new URLSearchParams(window.location.search).get("billingDraft");if(k){N.restore();try{let B=(await t.get("/api/billing/draft/"+encodeURIComponent(k))).data;if(B.path!==o.path())throw new Error("Wrong task");v=B.values.conference||null;for(let j of["sourceUrl","terms","repoId","source","options","conference","githubConnection"])Object.prototype.hasOwnProperty.call(B.values,j)&&(e[j]=B.values[j]);return e.options?.expirationDate&&(e.options.expirationDate=new Date(e.options.expirationDate)),E=B.id,M=JSON.stringify(N.checkpoint()),e.draftRestored=!0,e.hostingReview=!0,e.sourceUrl&&await Ue(),o.replace?.(o.path()),!0}catch{e.billingError="The checkout draft could not be restored. Retry by reloading this page; any local draft is still available."}}let I;try{I=JSON.parse(sessionStorage.getItem("github-access-draft")||"null")}catch{return!1}if(!I||I.path!==o.path()||Date.now()-I.savedAt>=30*6e4)return N.restore()?(e.sourceUrl&&await Ue(),!0):!1;N.restore();for(let B of["sourceUrl","terms","repoId","pullRequestId","gistId","source","options","conference","githubConnection"])Object.prototype.hasOwnProperty.call(I.draft,B)&&(e[B]=I.draft[B]);return e.options.expirationDate&&(e.options.expirationDate=new Date(e.options.expirationDate)),await Ue(),sessionStorage.removeItem("github-access-draft"),!0}se(()=>{!i.repoId&&!i.pullRequestId&&!i.gistId&&d(Be,0),i.repoId&&i.repoId!=""&&(e.isUpdate=!0,e.detectedType="repo",e.repoId=i.repoId,t.get("/api/repo/"+e.repoId).then(async k=>{e.accessRepairAllowed=!["removed","archived","preparing","queue","download","removing","expiring"].includes(k.data.status),e.githubConnection=k.data.connection||"oauth",e.sourceUrl="https://github.com/"+k.data.source.fullName,e._originalFullName=k.data.source.fullName,e.terms=k.data.options.terms.filter(I=>I).join(` -`),e.source=k.data.source,e.role=k.data.role||"owner",e._existingNever=k.data.options.expirationMode==="never",e._savedExpirationDate=k.data.options.expirationDate?new Date(k.data.options.expirationDate):null,e.coauthors=k.data.coauthors||[],e._originalBranch=k.data.source.branch,e.options=Object.assign({},e.options,k.data.options),e.conference=k.data.conference,e._originalConference=k.data.conference,e.repositoryID=k.data.source.repositoryID,e._originalRepositoryID=k.data.source.repositoryID,k.data.options.expirationDate&&(e.options.expirationDate=new Date(k.data.options.expirationDate)),R=S(parseGithubUrl(e.sourceUrl)),!await Be()&&(await Promise.all([Qe(),He()]),ws())},()=>{o.url("/404")})),i.pullRequestId&&i.pullRequestId!=""&&(e.isUpdate=!0,e.detectedType="pr",e.pullRequestId=i.pullRequestId,t.get("/api/pr/"+e.pullRequestId).then(async k=>{if(e.githubConnection=k.data.connection||"oauth",e.sourceUrl="https://github.com/"+k.data.source.repositoryFullName+"/pull/"+k.data.source.pullRequestId,e.terms=k.data.options.terms.filter(I=>I).join(` -`),e.source=k.data.source,e.options=Object.assign({},e.options,k.data.options),e.conference=k.data.conference,e._originalConference=k.data.conference,k.data.options.expirationDate&&(e.options.expirationDate=new Date(k.data.options.expirationDate)),R=S(parseGithubUrl(e.sourceUrl)),!await Be())try{await Qa()}catch{}},()=>{o.url("/404")})),i.gistId&&i.gistId!=""&&(e.isUpdate=!0,e.detectedType="gist",e.gistId=i.gistId,t.get("/api/gist/"+e.gistId).then(async k=>{e.sourceUrl="https://gist.github.com/"+k.data.source.gistId,e.terms=k.data.options.terms.filter(I=>I).join(` -`),e.source=k.data.source,e.options=Object.assign({},e.options,k.data.options),e.conference=k.data.conference,e._originalConference=k.data.conference,k.data.options.expirationDate&&(e.options.expirationDate=new Date(k.data.options.expirationDate)),R=S(parseGithubUrl(e.sourceUrl)),!await Be()&&await Za()},()=>{o.url("/404")}))}),t.get("/github/connections").then(k=>{e.githubConnections=k.data,!i.repoId&&!i.pullRequestId&&!i.gistId&&e.githubConnection===void 0&&k.data.appEnabled&&k.data.appConnected&&(e.githubConnection="github-app",e.sourceUrl&&e.workspaceOpen&&Ue())}).catch(()=>{}),e.urlSelected=async(k=!1)=>{let I=++u;e.previousConfigurations=[],e.previousConfigurationId="";let B;try{B=parseGithubUrl(e.sourceUrl.trim())}catch{e.sourceLoading=!1,Yt.cancel(),Tn.cancel(),On.cancel(),e.previewStatus="idle",e.sourceUrlError=e.sourceUrl?"Please provide a valid GitHub URL.":"",Y("sourceUrl","github",!1);return}let j=S(B),ue=k||R===j;R=j,e.sourceUrlError="",Y("sourceUrl","github",!0);let ye=document.activeElement?.id==="sourceUrl-landing";e.workspaceOpen=!0,setTimeout(()=>{let Ke=window.document.getElementById("sourceUrl");if(Ke){try{Ke.setSelectionRange(0,0)}catch{}Ke.scrollLeft=0}},50),ye&&d(()=>document.getElementById("sourceUrl")?.focus(),0),e.reconnectingSource=!1,e.reconnectRepositoryId=void 0,!ue&&!e.isUpdate&&(e.repoId="",e.pullRequestId="",e.gistId=""),e.details=null,e.branches=[],ue||(e.source={type:"GitHubStream",branch:"",commit:""}),Yt.cancel(),Tn.cancel(),On.cancel(),ks.clear(),Cs.clear(),e.previewStatus="idle",e.anonymize_readme="",e.readme="",lt(),e.detectedType=null,e.gistOAuthRequired=!1,e.gistAppRequired=!1,e._preservingDraft=ue;try{B.gistId&&!B.repo?(e.detectedType="gist",e.source={gistId:B.gistId},await Za()):B.pullRequestId?(e.detectedType="pr",e.source={repositoryFullName:B.owner+"/"+B.repo,pullRequestId:B.pullRequestId},await Qa()):(e.detectedType="repo",L(),await Promise.all([Qe(),He()]),ws())}catch{}finally{I===u&&(e._preservingDraft=!1)}$('[data-toggle="tooltip"]').tooltip()},$('[data-toggle="tooltip"]').tooltip(),e.watch("source.branch",async()=>{if(e.detectedType!=="repo")return;let k=e.branches.filter(B=>B.name==e.source.branch)[0];if(!k)return;!(!e.reconnectingSource&&e.isUpdate&&e._originalBranch===e.source.branch&&e.source.commit)&&!(e._preservingDraft&&e.source.commit)&&(e.source.commit=k.commit),e.readme=k.readme,await He(),ws()}),e.getBranches=async k=>{let I=parseGithubUrl(e.sourceUrl),B=h();try{let j=await t.get(`/api/repo/${I.owner}/${I.repo}/branches`,{params:{reconnect:e.reconnectingSource?"1":void 0,anonymizedRepoId:e.isUpdate&&i.repoId&&he(e.sourceUrl)===e._originalFullName?i.repoId:void 0,connection:e.githubConnection,force:k===!0||e.reconnectingSource?"1":"0",repositoryID:Se()}});if(!b(B))return;e.branches=j.data,e.sourceUnreachable=!1,e.source.branch||(e.source.branch=e.details.defaultBranch);let ue=e.branches.filter(ye=>ye.name==e.source.branch);ue.length>0&&(!(!e.reconnectingSource&&!k&&e.isUpdate&&!e.options.update&&e._originalBranch===e.source.branch&&e.source.commit)&&!(e._preservingDraft&&e.source.commit)&&(e.source.commit=ue[0].commit),e.readme=ue[0].readme,await He(k))}catch(j){if(!b(B))return;e.branches=[],e.sourceUnreachable=j&&(j.status===404||j.data&&j.data.error==="repo_not_found");let ue=j&&j.data&&j.data.error||(j&&j.status===404?"repo_not_found":"unknown_error");r("ERRORS."+ue).then(ye=>{e.toasts=e.toasts||[],e.addToast({title:"Error",date:new Date,body:ye}),e.error=ye},console.error),typeof Y=="function"&&Y("sourceUrl","missing",!1)}finally{w(B)}};async function Qe(){let k=parseGithubUrl(e.sourceUrl),I=h();try{Es();let B=await t.get(`/api/repo/${k.owner}/${k.repo}/`,{params:{reconnect:e.reconnectingSource?"1":void 0,anonymizedRepoId:e.isUpdate&&i.repoId&&he(e.sourceUrl)===e._originalFullName?i.repoId:void 0,connection:e.githubConnection,repositoryID:Se(),force:"1"}});if(!b(I))return;e.details=B.data,e.reconnectingSource&&(e.reconnectRepositoryId=e.details.externalId),e.details&&e.details.id&&(e.repositoryID=e.details.id),e.repoId||(e.repoId=e.details.repo+"-"+generateRandomId(4)),await e.getBranches(e.reconnectingSource)}catch(B){if(!b(I))return;throw B.data&&(r("ERRORS."+B.data.error).then(j=>{e.addToast({title:"Error",date:new Date,body:j}),e.error=j},console.error),Ss(B.data.error)),Y("sourceUrl","missing",!1),B}finally{w(I)}}async function He(k){if(e.readme&&!k)return e.readme;let I=parseGithubUrl(e.sourceUrl),B=h();try{let j=await t.get(`/api/repo/${I.owner}/${I.repo}/readme`,{params:{reconnect:e.reconnectingSource?"1":void 0,anonymizedRepoId:e.isUpdate&&i.repoId&&he(e.sourceUrl)===e._originalFullName?i.repoId:void 0,connection:e.githubConnection,force:k===!0?"1":"0",branch:e.source.branch,repositoryID:Se()}});b(B,!0)&&(e.readme=j.data)}catch{b(B,!0)&&(e.readme="")}finally{w(B)}}let et={magicalBraces:!0},Re=k=>k.startsWith("/")&&!k.endsWith("/")&&zn(vs(k.slice(1),et),et)===k.slice(1),Fe=()=>Object.keys(e.preserve.picked).filter(k=>e.preserve.picked[k]).sort().map(k=>"/"+zn(k,et)),W=k=>"/"+zn(k,et)+"/**",fe=k=>"!/"+zn(k,et)+"/",de=()=>String(e.preserve.patterns||"").split(` -`).map(k=>k.trim()).filter(Boolean),ce=null,ve=null,Me=new Set,P=0,T=null,F=()=>!1;function J(){let k=P+"\0"+e.preserve.patterns;if(k!==T){T=k;try{F=ja(Ha([...Fe(),...de()]))}catch{F=()=>!1}}return F}function H(k){let I=new Map([["",{dirs:[],files:[]}]]);for(let B of k){let j=B.split("/"),ue="";for(let ye=0;yeI.startsWith(k+"/"))),ce.descendants.get(k)}let le=k=>J()(k);function ne(k){let I=x(k),B=0;for(let j of I)le(j)&&B++;return B===0?"none":B===I.length?"all":"some"}e.preserve={open:!1,loading:!1,error:"",truncated:!1,commit:"",search:"",expanded:{},picked:{},patterns:"",patternsOpen:!1},e.preserveSummary=()=>{let k=(e.options?.preserveFiles||[]).map(I=>String(I).trim()).filter(Boolean).map(I=>Re(I)?vs(I.slice(1),et):I);return k.length?k.slice(0,2).join(", ")+(k.length>2?` and ${k.length-2} more`:""):"None. Every file is redacted."};async function oe(){let k=e.source?.commit;if(!(ce&&e.preserve.commit===k)){e.preserve.loading=!0,e.preserve.error="",ce=null,ve=null;try{let I=parseGithubUrl(e.sourceUrl),B=await t.get(`/api/repo/${I.owner}/${I.repo}/tree`,{params:{commit:k,connection:e.githubConnection,anonymizedRepoId:e.isUpdate&&i.repoId&&he(e.sourceUrl)===e._originalFullName?i.repoId:void 0,repositoryID:Se()}});if(e.source?.commit!==k)return;let j=Array.isArray(B.data.binaryFiles)?B.data.binaryFiles:[];ce=un(H(B.data.files||[])),ve=j.length?un(H([...B.data.files||[],...j])):ce,Me=un(new Set(j)),e.preserve.commit=k,e.preserve.truncated=!!B.data.truncated,e.previewFile||Yt()}catch{e.preserve.error="The file list could not be loaded from GitHub. You can still use patterns.",e.preserve.patternsOpen=!0}finally{e.preserve.loading=!1}}}e.watch("source.commit",k=>{e.previewFile&&e.openPreviewFile(""),e.detectedType==="repo"&&k&&e.sourceUrl&&oe().catch(()=>{})}),e.openPreserveFiles=()=>{let k={},I=[];for(let j of e.options?.preserveFiles||[]){let ue=String(j).trim();ue&&(!I.length&&Re(ue)?k[vs(ue.slice(1),et)]=!0:I.push(ue))}let B={};for(let j of Object.keys(k)){let ue=j.split("/");for(let ye=1;ye0}),e.mobileWorkspace&&(e.mobilePane="settings"),P++,d(()=>{let j=document.getElementById("preserve-files-dialog");j?.showModal&&!j.open&&j.showModal(),document.getElementById("preserve-files-search")?.focus()},0),oe()},e.closePreserveFiles=()=>{document.getElementById("preserve-files-dialog")?.close?.(),e.preserve.open=!1},e.savePreserveFiles=()=>{e.options.preserveFiles=Ha([...Fe(),...de()]),e.closePreserveFiles()},e.preserveRows=()=>{if(!ce)return[];let k=J(),I=(ye,Ke,qt)=>{let bt=!!e.preserve.picked[ye],Xn=k(ye);return{kind:"file",path:ye,label:qt,depth:Ke,state:Xn?"all":"none",locked:!bt&&Xn,note:!bt&&Xn?"matched by a pattern":bt&&!Xn?"excluded by a pattern":""}},B=String(e.preserve.search||"").trim().toLowerCase();if(B)return ce.files.filter(ye=>ye.toLowerCase().includes(B)).slice(0,300).map(ye=>I(ye,0,ye));let j=[],ue=(ye,Ke)=>{let qt=ce.dirs.get(ye);for(let bt of qt.dirs){let Xn=!!e.preserve.expanded[bt],xa=de().includes(W(bt));j.push({kind:"dir",path:bt,label:bt.slice(ye?ye.length+1:0)+"/",depth:Ke,open:Xn,state:ne(bt),locked:!1,note:xa?"whole folder":""}),Xn&&ue(bt,Ke+1)}for(let bt of qt.files)j.push(I(bt,Ke,bt.slice(ye?ye.length+1:0)))};return ue("",0),j},e.preserveCount=()=>ce?ce.files.filter(le).length:0,e.togglePreserveDir=k=>{e.preserve.expanded[k]=!e.preserve.expanded[k]},e.togglePreserveFile=k=>{e.preserve.picked[k]=!e.preserve.picked[k],P++},e.togglePreserveFolder=k=>{let I=W(k),B=fe(k),j=de().filter(ye=>ye!==I&&ye!==B),ue=ne(k)==="all"||de().includes(I);for(let ye of x(k))e.preserve.picked[ye]=!1;P++,e.preserve.patterns=(ue?j:[...j,I]).join(` -`),ue&&x(k).some(le)&&(e.preserve.patterns=[...j,B].join(` -`))};let ee=/^readme(\.[^/]*)?$/i,ke=[".md",".markdown",".mdown",".mkdn",".rst",".txt",""],pe=["README.md","README","README.markdown","README.rst","README.txt","readme.md"],Ee=k=>{let I=K(k),B=I.indexOf("."),j=ke.indexOf(B===-1?"":I.slice(B).toLowerCase());return j===-1?ke.length:j},Ae=()=>!!ce&&!!e.preserve.commit&&e.preserve.commit===e.source?.commit;e.readmePath=()=>{if(!Ae())return"";for(let k of[".github","","docs"]){let I=(ce.dirs.get(k)?.files||[]).filter(B=>ee.test(K(B)));if(I.length)return I.sort((B,j)=>Ee(B)-Ee(j)||z(B,j))[0]}return""},e.readmeName=()=>K(e.readmePath())||"README.md";let Ve={key:null,fn:()=>!1},Ge=()=>{let k=(e.options?.preserveFiles||[]).map(B=>String(B).trim()).filter(Boolean),I=k.join(` -`);if(I!==Ve.key){let B=()=>!1;try{k.length&&(B=ja(k))}catch{}Ve={key:I,fn:B}}return Ve.fn};e.pathPreserved=k=>!!k&&Ge()(k),e.readmePreserved=()=>{if(e.detectedType!=="repo")return!1;let k=Ge();if(Ae()){let I=e.readmePath();return!!I&&k(I)}return pe.some(I=>k(I))},e.previewPreserved=()=>e.detectedType==="repo"&&(e.previewFile?e.pathPreserved(e.previewFile):e.readmePreserved());function ze(){let k={terms:e.terms?e.terms.split(` -`):[],filePath:e.previewOpenPath()||"README.md",preserveFiles:e.options.preserveFiles||[],image:!!e.options.image,link:!!e.options.link,repoId:e.repoId};e.source&&e.source.branch&&(k.branchName=e.source.branch);try{let I=parseGithubUrl(e.sourceUrl);k.repoName=`${I.owner}/${I.repo}`}catch{}return k}function we(k,I,B){let j=null,ue=0,ye=()=>{if(e.detectedType!==k)return;j&&d.cancel(j);let Ke=++ue;e.previewStatus="loading",j=d(()=>{j=null;let qt=I();if(!qt){e.previewStatus="idle";return}t.post("/api/anonymize-preview",qt).then(bt=>{Ke===ue&&(B(bt.data,qt),e.previewStatus="ready")}).catch(()=>{Ke===ue&&(e.previewStatus="error")})},200)};return ye.cancel=()=>{ue++,j&&d.cancel(j),j=null},e.on("dispose",ye.cancel),ye}e.retryPreview=()=>{e.detectedType==="repo"&&(e.previewFile&&typeof at!="string"?ft(e.previewFile):Yt()),e.detectedType==="pr"&&Tn(),e.detectedType==="gist"&&On()};let be=un(qo(e));Object.defineProperty(e,"previewViewer",{get:()=>be}),ma(be,e),Object.assign(be,{options:{},files:[],paths:[],content:null,type:"loading",sidebarHidden:!1,sidebarCollapsed:!0,moreOpen:!1,tocOpen:!1,gotoOpen:!1,mdFindOpen:!1,mdFindQuery:"",mdFindTotal:0,mdFindIndex:0}),be.preview=!0,be.fileSize=k=>k===be.filePath&&typeof at=="string"?new Blob([at]).size:!e.previewFile&&e.readme?new Blob([e.readme]).size:null,be.openPreserveFiles=()=>e.openPreserveFiles(),be.previewPreserved=()=>e.previewPreserved(),be.retryContent=()=>e.retryPreview();let ot=k=>Me.has(k)||/\.(pdf|png|jpe?g|gif|svg|ico|bmp|tiff?|webp|avif|heic|heif|mp4|webm|mp3|wav|zip|bin)$/i.test(k),rt=(k="")=>({path:k,loading:!1,note:"",loadError:""});e.previewFile="",e.previewDoc=rt();let yt=0,at=null;e.previewOpenPath=()=>e.previewFile||e.readmePath(),e.openPreviewFile=k=>{if(k=k||"",k&&k===e.readmePath()&&(k=""),yt++,at=null,Yn(),Yt.cancel(),e.previewFile=k,e.previewDoc=rt(k),be.sidebarCollapsed=!0,be.content=null,!k){e.readme?Yt():e.previewStatus="idle";return}if(ot(k)){cr("binary"),e.previewStatus="ready";return}ft(k)};function lt(){yt++,at=null,e.previewFile="",e.previewDoc=rt(),be.sidebarCollapsed=!0,be.content=null}function ft(k){let I=++yt;at=null,Object.assign(e.previewDoc,{loading:!0,loadError:""}),e.previewStatus="loading";let B;try{B=parseGithubUrl(e.sourceUrl)}catch{B=null}if(!B||!e.source?.commit){Object.assign(e.previewDoc,{loading:!1,loadError:"The repository is still loading. Try again in a moment."}),e.previewStatus="error";return}t.get(`/api/repo/${B.owner}/${B.repo}/file`,{params:{commit:e.source.commit,path:k,connection:e.githubConnection,anonymizedRepoId:e.isUpdate&&i.repoId&&he(e.sourceUrl)===e._originalFullName?i.repoId:void 0,repositoryID:Se()},transformResponse:j=>j}).then(j=>{if(I!==yt)return;e.previewDoc.loading=!1;let ue=typeof j.headers=="function"&&j.headers("content-type")||"";if(/json/i.test(ue)){let ye=null;try{ye=JSON.parse(j.data)}catch{}if(ye&&ye.binary===!0){cr("binary"),e.previewStatus="ready";return}}at=typeof j.data=="string"?j.data:"",Yt()},j=>{if(I!==yt)return;e.previewDoc.loading=!1;let ue=ar(j);if(ue==="file_too_big"){cr("too_big"),e.previewStatus="ready";return}e.previewDoc.loadError=Kn.ERRORS[ue]||"GitHub did not return this file.",e.previewStatus="error"})}let Vt;function Yn(){Vt&&window.URL.revokeObjectURL(Vt),Vt=void 0,be.url=void 0}e.on("dispose",Yn);function cr(k){Yn(),e.previewDoc.note=k,be.prepareFile(e.previewPathName(e.previewOpenPath()||e.readmeName())),be.type=k==="too_big"?"error":"binary",be.content=k==="too_big"?"file_too_big":"binary"}function xp(k){try{let I=parseGithubUrl(e.sourceUrl),B=e.source.branch||e.details&&e.details.defaultBranch||"main",j=k&&k.includes("/")?k.slice(0,k.lastIndexOf("/")+1):"";return`https://github.com/${I.owner}/${I.repo}/raw/${B}/${j}`}catch{return""}}let Ja=we("repo",()=>e.previewFile?typeof at!="string"?null:{content:at,options:ze()}:e.readme?{content:e.readme,options:ze()}:null,k=>{if(typeof k?.content!="string")throw Error("Invalid preview response");Yn(),window.URL?.createObjectURL&&(be.url=Vt=window.URL.createObjectURL(new Blob([k.content],{type:"text/plain"})));let I=e.previewOpenPath()||e.readmeName();be.prepareFile(e.previewPathName(I)),be.fileBaseUrl=xp(I),be.renderFileContent(k.content,be.type,be.fileBaseUrl,"text/plain"),e.previewFile||(e.anonymize_readme=k.content)}),Yt=()=>{e.previewFile&&typeof at!="string"||Ja()};Yt.cancel=Ja.cancel;let bs=st(new Map),pr=new Set,fr=new Set,Zs="",xs=null,xo=()=>String(e.terms||"").split(` -`).filter(k=>k.trim());function ef(){xs=null;let k=xo(),I=k.join(` -`);I!==Zs&&(bs.clear(),fr.clear(),Zs=I);let B=[...pr].filter(j=>!bs.has(j));if(pr.clear(),!(!B.length||!k.length))for(let j=0;j{if(Zs!==I||xo().join(` -`)!==I)return;let Ke=ye.data?.contents;if(!Array.isArray(Ke)||Ke.length!==ue.length)throw Error("Invalid preview response");ue.forEach((qt,bt)=>bs.set(qt,typeof Ke[bt]=="string"?Ke[bt]:qt))}).catch(()=>{Zs===I&&ue.forEach(ye=>fr.add(ye))})}}e.previewName=k=>{if(!k||!xo().length)return k;if(Zs===xo().join(` -`)){if(bs.has(k))return bs.get(k);if(fr.has(k))return k}return pr.add(k),xs||(xs=d(ef,120)),k},e.previewPathName=k=>{k=String(k||"");let I=k.lastIndexOf("/");return I<0?e.previewName(k):e.previewName(k.slice(0,I))+"/"+e.previewName(k.slice(I+1))},e.watch(()=>[e.repoId,e.previewPathName(e.previewOpenPath()||e.readmeName()),e.previewTreeFiles()],()=>{be.repoId=e.repoId||"repository",be.filePath=e.previewPathName(e.previewOpenPath()||e.readmeName()),be.paths=be.filePath.split("/"),be.files=e.previewTreeFiles(),be.loadedFolders=Object.fromEntries([...ve?.dirs.keys()||[]].map(k=>[e.previewName(k),!0]))},!0),e.on("dispose",()=>{xs&&d.cancel(xs)});function ws(){!e.anonymize||!e.anonymize.terms||Yt()}async function Qa(){let k=parseGithubUrl(e.sourceUrl),I=h();try{Es();let B=await t.get(`/api/pr/${k.owner}/${k.repo}/${k.pullRequestId}`,{params:{connection:e.githubConnection}});if(!b(I))return;e.details=B.data,e.pullRequestId||(e.pullRequestId=k.repo+"-PR"+k.pullRequestId+"-"+generateRandomId(4))}catch(B){if(!b(I))return;throw B.data&&(r("ERRORS."+B.data.error).then(j=>{e.addToast({title:"Error",date:new Date,body:j}),e.error=j},console.error),Ss(B.data.error)),Y("sourceUrl","missing",!1),B}finally{w(I)}}let ks=st(new Map);function tf(){let k=new Set,I=e.details&&e.details.pullRequest;if(!I)return k;typeof I.title=="string"&&k.add(I.title),typeof I.body=="string"&&k.add(I.body),typeof I.diff=="string"&&k.add(I.diff);let B=I.comments||[];for(let j of B)typeof j.author=="string"&&k.add(j.author),typeof j.body=="string"&&k.add(j.body);return k}let Tn=we("pr",()=>{let k=tf(),I=Array.from(k);return I.length===0?null:{contents:I,options:ze()}},(k,I)=>{if(!Array.isArray(k?.contents)||k.contents.length!==I.contents.length||k.contents.some(ue=>typeof ue!="string"))throw Error("Invalid preview response");let B=I.contents,j=new Map;for(let ue=0;ueks.set(ye,ue))});e.anonymizePrContent=function(k){return k&&(ks.has(k)?ks.get(k):"")};async function Za(){let k=parseGithubUrl(e.sourceUrl),I=h();try{Es(),e.gistOAuthRequired=!1,e.gistAppRequired=!1;let B=await t.get(`/api/gist/source/${k.gistId}`);if(!b(I))return;e.details=B.data,e.gistId||(e.gistId="gist-"+k.gistId.substring(0,6)+"-"+generateRandomId(4))}catch(B){if(!b(I))return;if(B.data?.error==="github_app_reconnect_required"){e.gistAppRequired=!0,Y("sourceUrl","missing",!1);return}if(B.data?.error==="github_oauth_required"){e.gistOAuthRequired=!0,Y("sourceUrl","missing",!1);return}throw B.data&&(r("ERRORS."+B.data.error).then(j=>{e.addToast({title:"Error",date:new Date,body:j}),e.error=j},console.error),Ss(B.data.error)),Y("sourceUrl","missing",!1),B}finally{w(I)}}let Cs=st(new Map);function nf(){let k=new Set,I=e.details&&e.details.gist;if(!I)return k;typeof I.description=="string"&&k.add(I.description),typeof I.ownerLogin=="string"&&k.add(I.ownerLogin);let B=I.files||[];for(let ue of B)typeof ue.filename=="string"&&k.add(ue.filename),typeof ue.content=="string"&&k.add(ue.content);let j=I.comments||[];for(let ue of j)typeof ue.author=="string"&&k.add(ue.author),typeof ue.body=="string"&&k.add(ue.body);return k}let On=we("gist",()=>{let k=nf(),I=Array.from(k);return I.length===0?null:{contents:I,options:ze()}},(k,I)=>{if(!Array.isArray(k?.contents)||k.contents.length!==I.contents.length||k.contents.some(ue=>typeof ue!="string"))throw Error("Invalid preview response");let B=I.contents,j=new Map;for(let ue=0;ueCs.set(ye,ue)),hr()});e.anonymizeGistContent=function(k){return k&&(Cs.has(k)?Cs.get(k):"")},e.previewGistFiles=[];function hr(){let k=e.details&&e.details.gist&&e.details.gist.files||[];e.previewGistFiles=k.map(I=>({filename:e.anonymizeGistContent(I.filename),content:e.anonymizeGistContent(I.content),language:I.language}))}e.watch("details.gist.files",hr,!0),e.watch("terms",hr);function sf(){let k=e.conference;if(e.conference_data=null,!k)return;let I=k===v||e.isUpdate&&k===e._originalConference;k!==v&&(v=null),t.get("/api/conferences/"+k).then(B=>{e.conference===k&&(e.conference_data=B.data,e.conference_data.startDate=new Date(e.conference_data.startDate),e.conference_data.endDate=new Date(e.conference_data.endDate),!I&&(e.options.expirationDate=new Date(e.conference_data.endDate),e.options.expirationMode="remove",e.options.update=e.conference_data.options.update,e.options.image=e.conference_data.options.image,e.options.pdf=e.conference_data.options.pdf,e.options.notebook=e.conference_data.options.notebook,e.options.link=e.conference_data.options.link))},()=>{e.conference===k&&(e.conference_data=null)})}function Es(){Y("repoId","used",!0),Y("repoId","format",!0),Y("pullRequestId","used",!0),Y("pullRequestId","format",!0),Y("gistId","used",!0),Y("gistId","format",!0),Y("sourceUrl","used",!0),Y("sourceUrl","missing",!0),Y("sourceUrl","access",!0),Y("sourceUrl","github",!0),Y("commit","exists",!0),Y("conference","activated",!0),Y("terms","format",!0),e.termHints=[]}function ei(){if(e.detectedType==="repo"&&e.options.expirationMode==="never")return!1;let k=e.anonymize&&e.anonymize.expirationDate;return!e.options.expirationDate||k&&k.invalid?(k&&k.setDirty&&k.setDirty(),e.error="Please choose a valid expiration date.",!0):!1}function Ss(k){let I=e.detectedType==="pr"?"pullRequestId":e.detectedType==="gist"?"gistId":"repoId";switch(k){case"repoId_already_used":Y(I,"used",!1);break;case"invalid_repoId":Y(I,"format",!1);break;case"options_not_provided":Y(I,"format",!1);break;case"repo_already_anonymized":Y("sourceUrl","used",!1);break;case"invalid_terms_format":Y("terms","format",!1);break;case"repo_not_found":Y("sourceUrl","missing",!1);break;case"repo_not_accessible":Y("sourceUrl","access",!1);break;case"commit_not_found":Y("commit","exists",!1);break;case"conf_not_activated":Y("conference","activated",!1);break}}e.coauthors=e.coauthors||[],e.coauthorResults=[],e.coauthorError="",e.searchCoauthors=()=>{let k=(e.coauthorSearch||"").trim();if(e.coauthorError="",k.length<2){e.coauthorResults=[];return}t.get("/api/user/search/github-users",{params:{q:k}}).then(I=>{let B=new Set((e.coauthors||[]).map(j=>(j.username||"").toLowerCase()));e.coauthorResults=(I.data||[]).filter(j=>!B.has((j.username||"").toLowerCase()))},()=>{e.coauthorResults=[]})},e.addCoauthor=(k,I)=>{I&&I.preventDefault(),!(!k||!k.username)&&t.post("/api/repo/"+e.repoId+"/coauthors",{username:k.username}).then(B=>{e.coauthors=B.data||[],e.coauthorResults=[],e.coauthorSearch="",e.coauthorError=""},B=>{let j=B&&B.data&&B.data.error||"unknown_error";e.coauthorError=j})},e.removeCoauthor=k=>{!k||!k.username||confirm("Remove co-author "+k.username+"?")&&t.delete("/api/repo/"+e.repoId+"/coauthors/"+encodeURIComponent(k.username)).then(I=>{e.coauthors=I.data||[]},I=>{let B=I&&I.data&&I.data.error||"unknown_error";e.coauthorError=B})},e.anonymizeRepo=k=>{if(e.sourceLoading){e.error="Wait for the source to finish loading before saving.";return}if(e.reconnectingSource&&!e.reconnectRepositoryId)return;if(ei()){e.editRepository();return}if(e.anonymize?.invalid||e.sourceUrlError){e.editRepository(),e.error="Please correct the highlighted fields before saving.";return}if(e.hostingNeedsPayment()&&e.options.expirationMode==="never"){e.hostingReview=!0,tt(()=>document.getElementById("repository-hosting")?.scrollIntoView({block:"center"}));return}let I=k.currentTarget||k.target.closest?.("button")||k.target;I.disabled=!0;let B=parseGithubUrl(e.sourceUrl),j={repoId:e.repoId,terms:e.terms.trim().split(` -`).filter(ye=>ye),connection:e.githubConnection,fullName:`${B.owner}/${B.repo}`,repository:e.sourceUrl,reconnectRepositoryId:e.reconnectRepositoryId,options:e.options,source:e.source,conference:e.conference};e.details&&(j.options.pageSource=e.details.pageSource),Es();let ue=e.isUpdate?"/api/repo/"+e.repoId:"/api/repo/";t.post(ue,j,{headers:{"Content-Type":"application/json"}}).then(()=>{N.clear(),window.location.href="/status/"+e.repoId},ye=>{if(ye.data){let Ke=["quota_exceeded","subscription_required_for_never_expiration"].includes(ye.data.error);Ke||r("ERRORS."+ye.data.error).then(qt=>{e.error=qt},console.error),Ss(ye.data.error),Ke&&(ye.data.error==="subscription_required_for_never_expiration"&&(e._existingNever=!1),e.hostingQuotaBlocked=!0,e.hostingReview=!0,tt(()=>document.getElementById("repository-hosting")?.scrollIntoView({block:"center"})))}}).finally(()=>{I.disabled=!1})},e.anonymizeGist=k=>{if(e.sourceLoading){e.error="Wait for the source to finish loading before saving.";return}if(ei())return;if(e.anonymize?.invalid||e.sourceUrlError){e.error="Please correct the highlighted fields before saving.";return}let I=k.currentTarget||k.target.closest?.("button")||k.target;I.disabled=!0;let B=parseGithubUrl(e.sourceUrl),j={gistId:e.gistId,terms:e.terms.trim().split(` -`).filter(ye=>ye),source:{gistId:B.gistId},options:e.options,conference:e.conference};Es();let ue=e.isUpdate?"/api/gist/"+e.gistId:"/api/gist/";t.post(ue,j,{headers:{"Content-Type":"application/json"}}).then(()=>{N.clear(),window.location.href="/gist/"+e.gistId},ye=>{ye.data&&(r("ERRORS."+ye.data.error).then(Ke=>{e.error=Ke},console.error),Ss(ye.data.error))}).finally(()=>{I.disabled=!1})},e.anonymizePullRequest=k=>{if(e.sourceLoading){e.error="Wait for the source to finish loading before saving.";return}if(ei())return;if(e.anonymize?.invalid||e.sourceUrlError){e.error="Please correct the highlighted fields before saving.";return}let I=k.currentTarget||k.target.closest?.("button")||k.target;I.disabled=!0;let B=parseGithubUrl(e.sourceUrl),j={pullRequestId:e.pullRequestId,connection:e.githubConnection,terms:e.terms.trim().split(` -`).filter(ye=>ye),source:{repositoryFullName:`${B.owner}/${B.repo}`,pullRequestId:B.pullRequestId},options:e.options,conference:e.conference};Es();let ue=e.isUpdate?"/api/pr/"+e.pullRequestId:"/api/pr/";t.post(ue,j,{headers:{"Content-Type":"application/json"}}).then(()=>{N.clear(),window.location.href="/pr/"+e.pullRequestId},ye=>{ye.data&&(r("ERRORS."+ye.data.error).then(Ke=>{e.error=Ke},console.error),Ss(ye.data.error))}).finally(()=>{I.disabled=!1})},e.watch("conference",()=>{sf()}),e.termHints=[],e.matchTermAsWritten=k=>{e.terms=Tc(e.terms,k)},e.watch("options.preserveFiles",()=>{e.detectedType==="repo"&&Yt()}),e.watch("terms",()=>{e.termHints=Dc(e.terms),e.detectedType==="repo"&&ws(),e.detectedType==="pr"&&Tn(),e.detectedType==="gist"&&On()}),e.watch("options.image",()=>{e.detectedType==="repo"&&ws(),e.detectedType==="pr"&&Tn(),e.detectedType==="gist"&&On()}),e.watch("options.link",()=>{e.detectedType==="repo"&&ws(),e.detectedType==="pr"&&Tn(),e.detectedType==="gist"&&On()}),e.watch("details",()=>{e.detectedType==="pr"&&Tn(),e.detectedType==="gist"&&On()},!0)},Ka=function(e,t,s,i,o,r){ma(e);let d=Ct();Ic();let p=Bt(),u=0,y=null,m=null;e.fileLoadingSlow=!1,e.fileReceivedBytes=0;function b(){y&&(y.resolve(),y=null),m&&(d.timeout.cancel(m),m=null)}let h=!1;e.on("dispose",()=>{h=!0,u++,b(),w&&w.resolve()}),e.files=[],e.isMac=/Mac|iPhone|iPad|iPod/.test(navigator.platform||navigator.userAgent),e.fileSearchQuery="",e.fileSearchResults=null,e.fileSearchLoading=!1,p(document,"click",O=>{e.symbolsOpen&&!O.target.closest?.(".symbols")&&(e.symbolsOpen=!1),e.moreOpen&&!O.target.closest?.(".tb-more")&&(e.moreOpen=!1),e.tocOpen&&!O.target.closest?.(".tb-toc-m")&&(e.tocOpen=!1),e.gotoOpen&&O.target.isConnected&&!O.target.closest?.(".goto-pop, .btn-goto, .tb-more")&&(e.gotoOpen=!1),e.accountOpen&&!O.target.closest?.(".acct")&&(e.accountOpen=!1),e.helpOpen&&!O.target.closest?.(".vb-help")&&(e.helpOpen=!1)}),p(document,"keydown",O=>{O.key==="Escape"&&(e.symbolsOpen=!1,e.moreOpen=!1,e.tocOpen=!1,e.gotoOpen=!1,e.accountOpen=!1,e.helpOpen=!1),(O.ctrlKey||O.metaKey)&&!O.altKey&&O.key&&O.key.toLowerCase()==="f"&&e.type==="html"&&window.document.querySelector(".reading-layout")&&(O.preventDefault(),e.toggleMdFind(!0))}),p(document,"keydown",function(O){if((O.metaKey||O.ctrlKey)&&O.key==="k"){O.preventDefault();var U=document.querySelector(".tree-search-input");U&&(U.focus(),U.select())}});var w=null;e.onFileSearchChange=function(){w&&(w.resolve(),w=null);let O=e.fileSearchQuery;if(!O||O.length<2){e.fileSearchResults=null,e.fileSearchLoading=!1;return}e.fileSearchLoading=!0;let U=r.defer();w=U,t.get(`/api/repo/${e.repoId}/files/search?q=${encodeURIComponent(O)}`,{timeout:U.promise}).then(function(C){if(!(h||w!==U)){w=null,e.fileSearchLoading=!1;var L={};e.files.forEach(function(Fe){L[(Fe.path||"")+"/"+Fe.name]=!0});for(var z=[],K={},ie=0;ie0&&e.files.push.apply(e.files,z);for(var Qe=[],He=0;He0&&e.files.push.apply(e.files,Qe),e.fileSearchResults=C.data}},function(){!h&&w===U&&(w=null,e.fileSearchLoading=!1,e.fileSearchResults=[])})},e.on("routeUpdate",function(O,U){if(e.repoId!=i.repoId)return X();if((i.path||"")!=e.filePath){window.matchMedia?.("(max-width: 767px)").matches&&(e.sidebarCollapsed=!0),e.filePath=i.path||"",e.paths=e.filePath.split("/").filter(C=>C&&C.trim().length>0),te();for(let C=0;C0?e.paths.slice(0,C).join("/"):"";e.files.some(K=>K.path===L)||e.getFiles(L)}}});function R(){if(e.paths[0]!="")return;let O=["readme.md","readme.txt","readme.org","readme.1st","readme"],U={};for(let L of e.files)L.name.toLowerCase().indexOf("readme")>-1&&(U[L.name.toLowerCase()]=L.name);let C=null;for(let L of O)if(U[L]){C=L;break}if(!C&&Object.keys(U).length>0&&(C=Object.keys(U)[0]),C){let L=s.url();L[L.length-1]!="/"&&(L+="/"),s.url(L+encodePathForUrl(U[C]))}}e.fileCounts=null;let S=0,N=new Set,v=!1;e.getFiles=function(O,U=!1){let C=e.repoId,L=S;return t.get(`/api/repo/${e.repoId}/files/?path=${encodeURIComponent(O)}&v=${e.options.lastUpdateDate}`).then(function(z){if(h||C!==e.repoId||L!==S)return[];let K=O||"";return e.files=e.files.filter(ie=>ie.path!==K),e.files.push(...z.data),e.loadedFolders={...e.loadedFolders,[K]:!0},E(K,L),z.data},function(z){if(h||C!==e.repoId||L!==S)return[];U||(e.type="error",e.content=ar(z),e.files=[])})};function E(O,U){if(v||N.has(O))return;N.add(O);let C=e.repoId;t.get(`/api/repo/${e.repoId}/files/counts?path=${encodeURIComponent(O)}`).then(function(L){h||C!==e.repoId||U!==S||(e.fileCounts={...e.fileCounts,...L.data})},function(){h||C!==e.repoId||U!==S||(v=!0)})}function M(){return e.files.filter(O=>O.name==e.paths[e.paths.length-1]&&O.path==e.paths.slice(0,e.paths.length-1).join("/"))[0]}var V=null;e.on("dispose",function(){V&&d.interval.cancel(V)});function _(O){if(h)return;let U=e.repoId;t.get(`/api/repo/${e.repoId}/options`).then(C=>{if(!(h||U!==e.repoId)){if(e.options=C.data,e.options.url){window.location=e.options.url;return}O&&O(C.data)}},C=>{if(!(h||U!==e.repoId)){var L=C.data||{};if(L.error==="rate_limited"&&L.resetAt){let K=function(){var ie=Math.max(0,Math.ceil((e.rateLimitResetAt-Date.now())/1e3));if(ie<=0)e.rateLimitCountdown="",e.rateLimitResetAt=0,V&&(d.interval.cancel(V),V=null),_(O);else{var se=Math.floor(ie/60),Y=ie%60;e.rateLimitCountdown=se>0?se+"m "+Y+"s":Y+"s"}};var z=K;e.type="rate_limited",e.rateLimitResetAt=L.resetAt,V&&d.interval.cancel(V),K(),V=d.interval(K,1e3)}else L.error==="repository_not_ready"?(e.type="loading",d.timeout(function(){_(O)},3e3)):(e.type="error",e.content=ar(C))}})}function G(O,U){let C=u;if(!O){e.type="error",e.content="no_file_selected";return}let L=e.type;(L==="code"||L==="text")&&ni().catch(()=>{}),e.type="loading",e.content="loading",e.fileLoadingSlow=!1,e.fileReceivedBytes=0;let z=r.defer();y=z,m=d.timeout(()=>{!h&&C===u&&e.type==="loading"&&(e.fileLoadingSlow=!0)},1500);let K=U&&U.sha||"0";t.get(`/api/repo/${e.repoId}/file/${encodePathForUrl(O)}?v=`+K,{timeout:z.promise,onDownloadProgress:ie=>{!h&&C===u&&(e.fileReceivedBytes=ie)},transformResponse:ie=>ie}).then(ie=>{h||C!==u||(b(),e.renderFileContent(ie.data,L,s.url()+"/../",ie.headers("content-type")))},ie=>{h||C!==u||(b(),e.type="error",e.content=ar(ie))})}function te(){u++,b(),e.content="",e.file=M();let O="0";e.file&&e.file.sha&&(O=e.file.sha),e.url=`/api/repo/${e.repoId}/file/${encodePathForUrl(e.filePath)}?v=${O}`;let U=e.filePath.substring(0,e.filePath.lastIndexOf("/")+1);if(e.fileBaseUrl=`/api/repo/${e.repoId}/file/${U?encodePathForUrl(U):""}`,e.showSource=!1,e.imageSize="",e.allowScripts=!1,e.prepareFile(e.filePath),e.type=="pdf"){e.content="pdf";return}if(e.type=="media"||e.type=="audio"){e.content=e.type;return}G(e.filePath,e.file)}e.isSourceAccessError=()=>["repo_not_found","token_expired","github_app_access_required","github_app_reconnect_required","repo_saml_enforcement","repo_access_limited"].includes(e.content),e.retryContent=()=>X();function X(){u++,b(),e.files=[],e.loadedFolders={},e.content=null,e.fileCounts=null,S++,N=new Set,v=!1,e.fileSearchQuery="",e.onFileSearchChange(),e.repoId=i.repoId,e.type="loading",e.filePath=i.path||"",e.paths=e.filePath.split("/");let O=e.repoId;_(function(U){if(e.filePath){te();let L=[...new Set(e.paths.map((z,K)=>e.paths.slice(0,K).join("/")))];r.all(L.map(z=>e.getFiles(z,!0)));return}var C=r.resolve();for(let L=0;L0?e.paths.slice(0,L).join("/"):"";C=C.then(function(){return e.getFiles(z)}).then(function(){if(e.type==="error")return r.reject("error")})}C.then(function(){h||O!==e.repoId||(e.files.length==1&&e.files[0].name==""?(e.files=[],e.type="empty"):(R(),te()))})})}X()},Bc=function(e,t,s,i,o){async function r(u){t.get(`/api/pr/${e.pullRequestId}/options`).then(y=>{if(e.options=y.data,e.options.url){window.location=e.options.url;return}u&&u(y.data)},y=>{e.type="error",e.content=y.data.error})}async function d(u){t.get(`/api/pr/${e.pullRequestId}/content`).then(y=>{e.details=y.data,e.tabState={active:y.data.diff?"diff":"comments"},u&&u(y.data)},y=>{e.type="error",e.content=y.data.error})}function p(){e.pullRequestId=i.pullRequestId,e.type="loading",r(u=>{d()})}p()},zc=function(e,t,s,i,o){async function r(u){t.get(`/api/gist/${e.gistId}/options`).then(y=>{if(e.options=y.data,e.options.url){window.location=e.options.url;return}u&&u(y.data)},y=>{e.type="error",e.content=y.data.error})}async function d(u){t.get(`/api/gist/${e.gistId}/content`).then(y=>{e.details=y.data;let m=y.data&&y.data.files&&y.data.files.length;e.tabState={active:m?"files":"comments"},u&&u(y.data)},y=>{e.type="error",e.content=y.data.error})}function p(){e.gistId=i.gistId,e.type="loading",r(()=>{d()})}p()},Hc=function(e,t,s){e.watch("user.status",()=>{e.user==null&&s.url("/")}),e.user==null&&s.url("/"),e.conferences=[],e.loading=!0,e.error="",e.search="";let i="conferences.filterPrefs",o={filters:{status:{ready:!0,expired:!1,removed:!1}},orderBy:"name"},r=loadFilterPrefs(i)||{};e.filters={status:Object.assign({},o.filters.status,r.filters&&r.filters.status||{})},e.orderBy=r.orderBy||o.orderBy,e.watch("orderBy",()=>{saveFilterPrefs(i,{filters:e.filters,orderBy:e.orderBy})}),e.watch("filters",()=>{saveFilterPrefs(i,{filters:e.filters,orderBy:e.orderBy})},!0),e.removeConference=function(d){if(!d.removing&&confirm(`Are you sure that you want to remove the conference ${d.name}? All the repositories linked to this conference will expire.`)){d.removing=!0;let p=st({title:`Removing ${d.name}...`,date:new Date,body:`The conference ${d.name} is going to be removed.`});e.addToast(p),t.delete(`/api/conferences/${d.conferenceID}`).then(()=>{p.title=`${d.name} is removed.`,p.body=`The conference ${d.name} is removed.`,e.loadConferences()}).catch(()=>{p.title="Unable to remove conference",p.body="Please try again. The conference has not been removed."}).finally(()=>{d.removing=!1})}},e.loadConferences=()=>(e.loading=!0,e.error="",t.get("/api/conferences/").then(d=>{e.conferences=d.data||[]},d=>{e.error="Unable to load your conferences. Please try again."}).finally(()=>{e.loading=!1})),e.loadConferences(),e.conferenceFilter=d=>{if(e.filters.status[d.status]==!1)return!1;let p=e.search.trim().toLowerCase();return!!(!p||(d.name||"").toLowerCase().includes(p)||(d.conferenceID||"").toLowerCase().includes(p))}},Ya=function(e,t,s,i){e.watch("user.status",()=>{e.user==null&&s.url("/")}),e.user==null&&s.url("/");let o=()=>{for(let[h,w,R]of[["startDate","Starts","startDate"],["endDate","Ends","endDate"]]){let S=document.getElementById(h);if(!S)continue;let N=S.parentElement.querySelector(":scope > .date-echo");N||(N=document.createElement("p"),N.className="date-echo",N.setAttribute("aria-live","polite"),S.insertAdjacentElement("afterend",N));let v=ya(e.options?.[R]);N.textContent=v?w+" "+v:"",N.hidden=!v}};typeof e.watchGroup=="function"&&e.watchGroup(["options.startDate","options.endDate"],()=>tt(o));let r=(h=20)=>{let w=document.querySelector("input#name.form-control"),R=document.querySelector("input#conferenceID.form-control");R&&(R.placeholder="e.g. ICSE27"),w?w.placeholder="e.g. ICSE 2027":h>0&&setTimeout(()=>r(h-1),50)};setTimeout(()=>r(),0),e.plans=[],e.plansLoaded=!1,e.conferenceBilling=null,Wi(t).then(h=>{e.conferenceBilling=h.data}).catch(()=>{}),e.conferenceTiers=()=>e.plans.filter(h=>h.id!=="free_conference").map(h=>{let w=(e.conferenceBilling?.plans||[]).find(R=>R.id===h.id)||{};return{...h,storage:h.storagePerRepo,...w,id:h.id,name:h.name}}),e.conferenceAudience=h=>({conference_workshop:"Workshops and small venues",conference:"A typical conference",conference_large:"Large or multi-track venues"})[h]||"",e.conferencePlanName=h=>jc(h),e.conferenceAmount=(h,w=h?.amount)=>new Intl.NumberFormat(void 0,{style:"currency",currency:h?.currency||"eur",minimumFractionDigits:w%100?2:0,maximumFractionDigits:2}).format(w/100),e.conferenceBytes=h=>{let w=Number(h)||0,R=Math.min(4,Math.floor(Math.log2(Math.max(w,1))/10));return`${new Intl.NumberFormat(void 0,{maximumFractionDigits:1}).format(w/1024**R)} ${["B","KB","MB","GB","TB"][R]}`},e.editionMode=!1,e.saving=!1,e.error="";function d(){return t.get("/api/conferences/"+i.conferenceId).then(h=>{e.options={...e.options,...h.data,billing:h.data.billing||{}},e.options.startDate=new Date(e.options.startDate),e.options.endDate=new Date(e.options.endDate)})}i.conferenceId&&(e.editionMode=!0,d());function p(){t.get("/api/conferences/plans").then(h=>{e.plans=h.data,e.plansLoaded=!0,!e.editionMode&&e.plans.length&&!e.plans.some(w=>w.id==e.options.plan.planID)&&(e.options.plan.planID=(e.plans.find(w=>w.id==="conference")||e.plans[0]).id),e.plan=e.plans.filter(w=>w.id==e.options.plan.planID)[0]})}p();let u=new Date;u.setDate(1),u.setMonth(u.getMonth()+1);let y=new Date(u);y.setTime(u.getTime()+179*864e5),e.options={billing:{},startDate:u,endDate:y,plan:{planID:"free_conference"},options:{link:!0,image:!0,pdf:!0,notebook:!0,update:!0,page:!0}},e.plan=null,e.watch("options.plan.planID",()=>{e.plan=e.plans.filter(h=>h.id==e.options.plan.planID)[0]});function m(){e.conference.name.setValidity("required",!0),e.conference.conferenceID.setValidity("pattern",!0),e.conference.conferenceID.setValidity("required",!0),e.conference.conferenceID.setValidity("used",!0),e.conference.startDate.setValidity("required",!0),e.conference.startDate.setValidity("invalid",!0),e.conference.endDate.setValidity("required",!0),e.conference.endDate.setValidity("invalid",!0),e.conference.setValidity("error",!0)}function b(h){switch(h){case"conf_name_missing":e.conference.name.setValidity("required",!1);break;case"conf_id_missing":e.conference.conferenceID.setValidity("required",!1);break;case"conf_id_format":e.conference.conferenceID.setValidity("pattern",!1);break;case"conf_id_used":e.conference.conferenceID.setValidity("used",!1);break;case"conf_start_date_missing":e.conference.startDate.setValidity("required",!1);break;case"conf_end_date_missing":e.conference.endDate.setValidity("required",!1);break;case"conf_start_date_invalid":e.conference.startDate.setValidity("invalid",!1);break;case"conf_end_date_invalid":e.conference.endDate.setValidity("invalid",!1);break;default:e.conference.setValidity("error",!1);break}}e.submit=function(){if(e.saving)return;e.saving=!0,e.error="";let h=JSON.parse(JSON.stringify(e.options)),w=st({title:`Creating ${h.name}...`,date:new Date,body:`The conference ${h.conferenceID} is in creation.`});e.editionMode&&(w.title=`Updating ${h.name}...`,w.body=`The conference '${h.conferenceID}' is updating.`),e.addToast(w),m(),t.post("/api/conferences/"+(e.editionMode?h.conferenceID:""),h).then(()=>{e.editionMode?(w.title=`${h.name} updated`,w.body=`The conference '${h.conferenceID}' is updated.`):(w.title=`${h.name} created`,w.body=`The conference '${h.conferenceID}' is created.`),s.url("/conference/"+h.conferenceID)},R=>{b(R.data?.error),e.error="Unable to save the conference. Please correct any highlighted fields and try again.",e.removeToast(w)}).finally(()=>{e.saving=!1})}};function jc(e){return{free_conference:"Free (no longer offered to new conferences)",conference_workshop:"Workshop package",conference:"Conference package",conference_large:"Large conference package",premium_conference:"Premium (legacy)",unlimited_conference:"Unlimited (legacy)"}[e]||e||"Free"}var Gc=function(e,t,s,i){Ki(e,t,()=>p(),{confirmedMessage:"Payment status checked. Your conference is ready for submissions once payment is confirmed."}),e.conferencePlanName=u=>jc(u),e.watch("user.status",()=>{e.user==null&&s.url("/")}),e.user==null&&s.url("/"),e.conference=null,e.search="",e.filters={status:{ready:!0,preparing:!0,error:!0,expired:!0,removed:!1}},e.orderBy="-anonymizeDate";let o=Xi,r=["ready","preparing","error","expired","removed"],d={current:u=>u!=="removed",attention:u=>u==="error",removed:u=>u==="removed"};e.confView=()=>Object.keys(d).find(u=>r.every(y=>d[u](y)===(e.filters.status[y]!==!1)))||"custom",e.setConfView=u=>{r.forEach(y=>{e.filters.status[y]=(d[u]||d.current)(y)})},e.confCount=u=>(e.conference?.repositories||[]).filter(y=>d[u](o(y.status))).length,e.copyingId=null,e.copyRepoLink=async u=>{if(!u?.repoId||e.copyingId)return;let y=new URL("/r/"+u.repoId+"/",window.location.origin).href;e.copyingId=u.repoId;try{await Wa(y),e.addToast({title:"Link copied",body:"The anonymous link is ready to share."})}catch{e.addToast({title:"Copy this anonymous link",body:y})}finally{e.copyingId=null}},e.extendingId=null,e.extendRepo=u=>{!u?.repoId||e.extendingId||(e.extendingId=u.repoId,t.post("/api/repo/"+u.repoId+"/extend").then(y=>{let m=y?.data?.expirationDate?` until ${new Date(y.data.expirationDate).toLocaleDateString(void 0,{year:"numeric",month:"short",day:"numeric"})}`:"";e.addToast({title:`${u.repoId} is extended.`,body:`Reviewers can open it again${m}.`}),u.status="ready",y?.data?.expirationDate&&(u.options={...u.options||{},expirationDate:y.data.expirationDate}),e.extendingId=null},y=>{let m=y?.status||y?.data?.status;e.addToast({title:`Couldn't extend ${u.repoId}.`,body:m===401||m===403?"Only the repository's authors can extend this link. Ask them to extend it from My work.":"Try again in a moment."}),e.extendingId=null}))},e.repoFiler=u=>{if(e.filters.status[o(u.status)]==!1)return!1;let y=e.search.trim().toLowerCase();return!!(!y||(u.source?.fullName||"").toLowerCase().includes(y)||(u.repoId||"").toLowerCase().includes(y))};function p(){t.get("/api/conferences/"+i.conferenceId).then(u=>{e.conference=u.data})}p()},Wc=function(e,t){e.notificationEmail="",e.emailSaved=!1,e.saveNotificationEmail=async()=>{e.busy=!0,e.emailSaved=!1,e.connectionError="";try{let s=await t.post("/github/connections/email",{email:e.notificationEmail},{headers:{"X-CSRF-Token":e.connections.csrf}});e.notificationEmail=s.data.notificationEmail,e.user&&(e.user.notificationEmail=s.data.notificationEmail),e.emailSaved=!0}catch(s){e.connectionError=s.data?.error||"Unable to save email address."}finally{e.busy=!1}},e.connections=null,e.connectionError="",e.busy=!1,e.loadConnections=()=>t.get("/github/connections").then(s=>{e.connections=s.data,e.notificationEmail=s.data.notificationEmail||""}).catch(s=>{e.connectionError=s.data?.error||"Unable to load connections."}),e.changeConnection=async(s,i,o)=>{e.busy=!0,e.connectionError="";try{let r=await t.post("/github/connections/migrate",{type:s.type,id:s.id,connection:i,preview:o},{headers:{"X-CSRF-Token":e.connections.csrf}});o?s.eligible=r.data.eligible:await e.loadConnections()}catch(r){e.connectionError=r.data?.error||"Unable to change connection."}finally{e.busy=!1}},e.disconnectOAuth=async()=>{e.busy=!0;try{await t.post("/github/connections/disconnect-oauth",{},{headers:{"X-CSRF-Token":e.connections.csrf}}),await e.loadConnections()}catch(s){e.connectionError=s.data?.error||"Unable to disconnect OAuth."}finally{e.busy=!1}},e.loadConnections()},Kc=function(e,t){e.accountRecovery=!1,t.get("/github/account-recovery").then(s=>{e.accountRecovery=s.data.required}).catch(()=>{})};typeof document<"u"&&document.addEventListener("scroll",e=>{let t=e.target;!t||!t.classList||!t.classList.contains("repo-picker-list")||t.classList.toggle("is-end",t.scrollTop+t.clientHeight>=t.scrollHeight-2)},!0);var Yc=[{path:"/review-link",template:"partials/reviewConsent.htm",title:"Artifact consent \u2013 Anonymous GitHub",setup:(e,t)=>ol(e,t)},{path:"/connections",template:"partials/connections.htm",title:"GitHub connections \u2013 Anonymous GitHub",preserveExplorer:!1,setup:(e,t)=>Wc(e,t.http)},{path:"/signin",template:"partials/signin.htm",title:"Sign in \u2013 Anonymous GitHub",preserveExplorer:!1,setup:(e,t)=>Kc(e,t.http)},{path:"/",template:"partials/home.htm",title:"Anonymous GitHub \u2013 Share the code, not the author",preserveExplorer:!1,setup:(e,t)=>$c(e,t.http,t.location,t.window,t.timeout)},{path:"/dashboard",template:"partials/dashboard.htm",title:"Your anonymizations \u2013 Anonymous GitHub",preserveExplorer:!1,setup:(e,t)=>Fc(e,t.http,t.location,t.promises,t.window,t.quotaService)},{path:"/pr-dashboard",redirect:"/dashboard"},{path:"/anonymize/:repoId?",template:"partials/anonymize.htm",title:"New anonymization \u2013 Anonymous GitHub",preserveExplorer:!1,setup:(e,t)=>dr(e,t.http,t.html,t.params,t.location,t.translate,t.timeout)},{path:"/pull-request-anonymize/:pullRequestId?",template:"partials/anonymize.htm",title:"Anonymize a pull request \u2013 Anonymous GitHub",preserveExplorer:!1,setup:(e,t)=>dr(e,t.http,t.html,t.params,t.location,t.translate,t.timeout)},{path:"/gist-anonymize/:gistId?",template:"partials/anonymize.htm",title:"Anonymize a gist \u2013 Anonymous GitHub",preserveExplorer:!1,setup:(e,t)=>dr(e,t.http,t.html,t.params,t.location,t.translate,t.timeout)},{path:"/status/:repoId",template:"partials/status.htm",title:"Repository status \u2013 Anonymous GitHub",preserveExplorer:!1,setup:(e,t)=>Uc(e,t.http,t.params)},{path:"/conferences",template:"partials/conferences.htm",title:"Your conferences \u2013 Anonymous GitHub",preserveExplorer:!1,setup:(e,t)=>Hc(e,t.http,t.location)},{path:"/conference/new",template:"partials/newConference.htm",title:"New conference \u2013 Anonymous GitHub",preserveExplorer:!1,setup:(e,t)=>Ya(e,t.http,t.location,t.params)},{path:"/conference/:conferenceId/edit",template:"partials/newConference.htm",title:"Edit conference \u2013 Anonymous GitHub",preserveExplorer:!1,setup:(e,t)=>Ya(e,t.http,t.location,t.params)},{path:"/conference/:conferenceId",template:"partials/conference.htm",title:"Conference \u2013 Anonymous GitHub",preserveExplorer:!1,setup:(e,t)=>Gc(e,t.http,t.location,t.params)},{path:"/faq",template:"partials/faq.htm",title:"FAQ \u2013 Anonymous GitHub",preserveExplorer:!1,setup:(e,t)=>qc(e,t.http)},{path:"/profile",template:"partials/profile.htm",title:"Your settings \u2013 Anonymous GitHub",preserveExplorer:!1,setup:(e,t)=>_c(e,t.http,t.translate,t.timeout,t.quotaService)},{path:"/claim",template:"partials/claim.htm",title:"Claim an anonymization \u2013 Anonymous GitHub",preserveExplorer:!1,setup:(e,t)=>Lc(e,t.http,t.location)},{path:"/pr/:pullRequestId/:path(.*)*",template:"partials/pullRequest.htm",title:"Anonymous pull request \u2013 Anonymous GitHub",preserveExplorer:!1,setup:(e,t)=>Bc(e,t.http,t.location,t.params,t.html)},{path:"/gist/:gistId/:path(.*)*",template:"partials/gist.htm",title:"Anonymous gist \u2013 Anonymous GitHub",preserveExplorer:!1,setup:(e,t)=>zc(e,t.http,t.location,t.params,t.html)},{path:"/r/:repoId/:path(.*)*",template:"partials/explorer.htm",title:"Anonymous repository \u2013 Anonymous GitHub",preserveExplorer:!0,setup:(e,t)=>Ka(e,t.http,t.location,t.params,t.html,t.promises)},{path:"/repository/:repoId/:path(.*)*",template:"partials/explorer.htm",title:"Anonymous repository \u2013 Anonymous GitHub",preserveExplorer:!0,setup:(e,t)=>Ka(e,t.http,t.location,t.params,t.html,t.promises)},{path:"/admin/",template:"partials/admin/overview.htm",title:"Admin \xB7 Overview \u2013 Anonymous GitHub",preserveExplorer:!1,setup:(e,t)=>ju(e,t.http,t.location,t.interval)},{path:"/admin/repositories",template:"partials/admin/repositories.htm",title:"Admin \xB7 Repositories \u2013 Anonymous GitHub",preserveExplorer:!1,setup:(e,t)=>$u(e,t.http,t.location)},{path:"/admin/users",template:"partials/admin/users.htm",title:"Admin \xB7 Users \u2013 Anonymous GitHub",preserveExplorer:!1,setup:(e,t)=>Fu(e,t.http,t.location)},{path:"/admin/users/:username",template:"partials/admin/user.htm",title:"Admin \xB7 User details \u2013 Anonymous GitHub",preserveExplorer:!1,setup:(e,t)=>Uu(e,t.http,t.location,t.params)},{path:"/admin/conferences",template:"partials/admin/conferences.htm",title:"Admin \xB7 Conferences \u2013 Anonymous GitHub",preserveExplorer:!1,setup:(e,t)=>Bu(e,t.http,t.location)},{path:"/admin/emails",template:"partials/admin/emails.htm",title:"Admin \xB7 Emails \u2013 Anonymous GitHub",preserveExplorer:!1,setup:(e,t)=>Ku(e,t.http,t.location)},{path:"/admin/billing",template:"partials/admin/billing.htm",title:"Admin \xB7 Billing \u2013 Anonymous GitHub",preserveExplorer:!1,setup:(e,t)=>Wu(e,t.http,t.location)},{path:"/admin/queues",template:"partials/admin/queues.htm",title:"Admin \xB7 Queues \u2013 Anonymous GitHub",preserveExplorer:!1,setup:(e,t)=>zu(e,t.http,t.location,t.interval,t.timeout)},{path:"/admin/errors",template:"partials/admin/errors.htm",title:"Admin \xB7 Errors \u2013 Anonymous GitHub",preserveExplorer:!1,setup:(e,t)=>Hu(e,t.http,t.location,t.interval)},{path:"/404",template:"partials/404.htm",title:"Page not found \u2013 Anonymous GitHub",preserveExplorer:!1,setup:()=>{}},{path:"/:pathMatch(.*)*",template:"partials/404.htm",title:"Page not found \u2013 Anonymous GitHub",setup:()=>{}}];var kv={class:"container paper-page admin-page emails-page"},Cv={class:"email-toolbar-actions"},Ev=["disabled"],Sv={class:"sr-only",role:"status","aria-live":"polite","aria-atomic":"true"},Nv={key:0,class:"email-state email-state-error",role:"alert"},Rv=["disabled"],Av={key:1,class:"email-state"},Pv={key:2,class:"email-state"},Dv=["aria-busy"],Tv={class:"email-table",role:"table"},Ov={role:"rowgroup"},Iv={class:"email-recipient",role:"cell"},Mv={class:"email-result",role:"cell"},Vv={key:0,class:"email-detail"},qv={key:1,class:"email-detail"},_v={class:"email-attempted",role:"cell"},Lv=["datetime"],$v={role:"cell"},Fv={class:"email-resource",role:"cell"},Uv={class:"email-detail"},Bv={key:4,class:"email-footer"},zv=["disabled"];function Xc(e,t){return a(),l("div",kv,[t[20]||(t[20]=Ce('
Admin \xA0/\xA0 Emails

Emails

',4)),n("form",{class:"email-toolbar",onSubmit:t[5]||(t[5]=ae(s=>e.loadEmails(),["prevent"])),"aria-label":"Filter email history"},[n("label",null,[t[10]||(t[10]=g("Status ",-1)),D(n("select",{"onUpdate:modelValue":t[0]||(t[0]=s=>e.emailState=s),onChange:t[1]||(t[1]=s=>e.loadEmails())},[...t[9]||(t[9]=[Ce('',5)])],544),[[Ut,e.emailState]])]),n("label",null,[t[12]||(t[12]=g("Email type ",-1)),D(n("select",{"onUpdate:modelValue":t[2]||(t[2]=s=>e.emailKind=s),onChange:t[3]||(t[3]=s=>e.loadEmails())},[...t[11]||(t[11]=[n("option",{value:""},"All types",-1),n("option",{value:"repository-expiration"},"Repository expiration",-1),n("option",{value:"owner-access"},"GitHub access",-1)])],544),[[Ut,e.emailKind]])]),n("div",Cv,[n("button",{class:"btn",type:"submit",disabled:e.emailLoading},c(e.emailLoading?"Loading\u2026":"Refresh"),9,Ev),e.hasEmailFilters()?(a(),l("button",{key:0,class:"btn",type:"button",onClick:t[4]||(t[4]=s=>e.clearEmailFilters())},"Clear filters")):f("v-if",!0)])],32),n("p",Sv,c(e.emailAnnouncement),1),e.emailError?(a(),l("div",Nv,[n("span",null,c(e.emailError),1),n("button",{class:"btn btn-sm",type:"button",disabled:e.emailLoading,onClick:t[6]||(t[6]=s=>e.retryEmails())},"Retry",8,Rv)])):f("v-if",!0),e.emailLoading&&!e.emailRows.length?(a(),l("p",Av,"Loading email history\u2026")):f("v-if",!0),!e.emailLoading&&!e.emailError&&!e.emailRows.length?(a(),l("div",Pv,[n("p",null,c(e.hasEmailFilters()?"No email attempts match these filters.":"No email attempts recorded yet."),1),e.hasEmailFilters()?(a(),l("button",{key:0,type:"button",class:"btn btn-sm",onClick:t[7]||(t[7]=s=>e.clearEmailFilters())},"Clear filters")):f("v-if",!0)])):f("v-if",!0),e.emailRows.length?(a(),l("div",{key:3,class:"email-table-wrap","aria-busy":e.emailLoading},[n("table",Tv,[t[18]||(t[18]=n("caption",{class:"sr-only"},"Email attempts, newest first. Times use your local time zone.",-1)),t[19]||(t[19]=n("thead",{role:"rowgroup"},[n("tr",{role:"row"},[n("th",{scope:"col",role:"columnheader"},"Recipient"),n("th",{scope:"col",role:"columnheader"},"Outcome"),n("th",{scope:"col",role:"columnheader"},"Attempted"),n("th",{scope:"col",role:"columnheader"},"Email type"),n("th",{scope:"col",role:"columnheader"},"Resource")])],-1)),n("tbody",Ov,[(a(!0),l(q,null,Q(e.emailRows,s=>(a(),l("tr",{key:s._id,role:"row"},[n("td",Iv,[t[13]||(t[13]=n("span",{class:"email-mobile-label","aria-hidden":"true"},"Recipient",-1)),g(c(s.recipient),1)]),n("td",Mv,[t[14]||(t[14]=n("span",{class:"email-mobile-label","aria-hidden":"true"},"Outcome",-1)),n("span",{class:A(["email-outcome","email-outcome-"+s.state])},c(e.emailStatusLabel(s.state)),3),s.httpStatus?(a(),l("small",Vv,"HTTP "+c(s.httpStatus),1)):f("v-if",!0),s.completedAt?(a(),l("small",qv,"Completed "+c(e.emailTime(s.completedAt)),1)):f("v-if",!0)]),n("td",_v,[t[15]||(t[15]=n("span",{class:"email-mobile-label","aria-hidden":"true"},"Attempted",-1)),n("time",{datetime:s.createdAt},c(e.emailTime(s.createdAt)),9,Lv)]),n("td",$v,[t[16]||(t[16]=n("span",{class:"email-mobile-label","aria-hidden":"true"},"Email type",-1)),g(c(e.emailKindLabel(s.kind)),1)]),n("td",Fv,[t[17]||(t[17]=n("span",{class:"email-mobile-label","aria-hidden":"true"},"Resource",-1)),g(c(s.resourceKind),1),n("small",Uv,c(s.resourceId),1)])]))),128))])])],8,Dv)):f("v-if",!0),e.emailRows.length?(a(),l("div",Bv,[n("span",null,c(e.emailRows.length)+" attempts shown",1),e.emailNextCursor?(a(),l("button",{key:0,class:"btn",type:"button",disabled:e.emailLoading,onClick:t[8]||(t[8]=s=>e.loadEmails(!0))},c(e.emailLoading?"Loading\u2026":"Load older emails"),9,zv)):f("v-if",!0)])):f("v-if",!0)])}var Hv={class:"container py-4",style:{"max-width":"48rem","overflow-wrap":"anywhere"}},jv={key:0},Gv={key:1,role:"alert"},Wv={key:2,role:"status"},Kv={key:0},Yv={key:1},Xv=["disabled"],Jv=["disabled"],Qv=["disabled"],Zv={key:5,class:"mt-4","aria-labelledby":"review-policy-title"},xv={id:"review-policy-title"},ey={key:0,role:"alert"},ty=["disabled"],ny=["disabled"],sy=["disabled"],oy={key:6,role:"status"};function Jc(e,t){return a(),l("section",Hv,[t[12]||(t[12]=n("a",{href:"/"},"Anonymous GitHub",-1)),t[13]||(t[13]=n("h1",{class:"mt-3"},"Approve artifact access",-1)),t[14]||(t[14]=n("p",null,"This records your approval as the repository owner or an authorized co-author.",-1)),e.user?.username?f("v-if",!0):(a(),l("p",jv,[...t[6]||(t[6]=[g("Sign in first, then reopen the artifact link from your submission. ",-1),n("a",{href:"/signin"},"Sign in",-1)])])),e.error?(a(),l("p",Gv,c(e.error),1)):f("v-if",!0),e.saved?(a(),l("p",Wv,[t[7]||(t[7]=g("Consent recorded. ",-1)),e.handoffEnabled?(a(),l("span",Kv,"Continue to review to finish linking.")):(a(),l("span",Yv,"Artifact linking is not complete. Return to your submission to check its status."))])):f("v-if",!0),e.saved&&e.handoffEnabled?(a(),l("button",{key:3,class:"btn btn-primary",type:"button",onClick:t[0]||(t[0]=(...s)=>e.continueReview&&e.continueReview(...s)),disabled:e.busy},"Continue to review",8,Xv)):f("v-if",!0),e.user?.username&&!e.saved?(a(),l("form",{key:4,onSubmit:t[2]||(t[2]=ae((...s)=>e.loadPreview&&e.loadPreview(...s),["prevent"]))},[t[8]||(t[8]=n("label",{for:"review-repository"},"Anonymous repository ID",-1)),D(n("input",{id:"review-repository",class:"form-control","onUpdate:modelValue":t[1]||(t[1]=s=>e.repositoryId=s),maxlength:"128",autocomplete:"off",disabled:e.busy||e.uncertain,"aria-describedby":"review-repository-help"},null,8,Jv),[[pt,e.repositoryId]]),t[9]||(t[9]=n("p",{id:"review-repository-help"},"Use the ID after /r/ in the anonymous repository URL.",-1)),n("button",{type:"submit",class:"btn btn-primary",disabled:e.busy||e.uncertain},"Preview access and retention",8,Qv)],32)):f("v-if",!0),e.preview&&!e.saved?(a(),l("section",Zv,[n("h2",xv,c(e.preview.repositoryName),1),n("p",null,"Access: "+c(e.preview.policy.access==="anonymous-link"?"Anyone with the anonymous link":"Restricted review access")+".",1),n("p",null,"Retain until "+c(e.preview.policy.retainUntil)+". Policy version "+c(e.preview.policy.version)+".",1),e.expired?(a(),l("p",ey,"This preview expired. Open a new artifact link from your submission.")):f("v-if",!0),n("div",null,[n("label",null,[D(n("input",{type:"checkbox","onUpdate:modelValue":t[3]||(t[3]=s=>e.acceptAccess=s),disabled:e.busy||e.uncertain||e.expired},null,8,ty),[[sa,e.acceptAccess]]),t[10]||(t[10]=g(" I approve the access policy above.",-1))])]),n("div",null,[n("label",null,[D(n("input",{type:"checkbox","onUpdate:modelValue":t[4]||(t[4]=s=>e.acceptRetention=s),disabled:e.busy||e.uncertain||e.expired},null,8,ny),[[sa,e.acceptRetention]]),t[11]||(t[11]=g(" I approve retention until the date above.",-1))])]),n("button",{class:"btn btn-primary",type:"button",onClick:t[5]||(t[5]=(...s)=>e.confirmConsent&&e.confirmConsent(...s)),disabled:e.busy||e.expired||!e.acceptAccess||!e.acceptRetention},c(e.uncertain?"Retry confirmation":"Confirm consent"),9,sy)])):f("v-if",!0),e.busy?(a(),l("p",oy,"Waiting for the server\u2026")):f("v-if",!0)])}var iy={class:"container paper-page connections-page"},ry={key:0,class:"paper-inline-alert paper-inline-alert-error",role:"alert"},ay={key:1,role:"status"},ly=["disabled"],dy={key:3},uy={key:0,class:"connection-resources"},cy=["disabled"],py=["disabled"],fy={key:0,role:"status"},hy={class:"connections-grid"},my={key:0},gy={class:"connection-title"},vy={key:0,class:"paper-inline-alert paper-inline-alert-error",role:"alert"},yy={class:"connection-actions"},by={key:0,class:"btn btn-ink",target:"_self",href:"/github/app/install"},wy=["disabled"],ky={key:1,class:"connection-installations"},Cy={key:0},Ey=["href"],Sy={class:"sr-only"},Ny={class:"connection-title"},Ry={key:0,target:"_self",href:"/github/login",class:"btn btn-outline-ink"},Ay={key:1,class:"connection-revoke"},Py={key:0},Dy=["disabled"],Ty={class:"connection-resources"},Oy={class:"connection-title"},Iy={class:"connection-count"},My={key:0,class:"connection-empty"},Vy={class:"connection-resource-name"},qy={key:0,class:"connection-resource-actions"},_y=["disabled","onClick"],Ly=["disabled","onClick"],$y={key:1,class:"connection-help",role:"status"},Fy=["disabled","onClick"];function Qc(e,t){return a(),l("div",iy,[t[27]||(t[27]=Ce('
My work \xA0/\xA0 GitHub connections

GitHub connections

Manage how GitHub shares your code. Your anonymizations and URLs stay the same.

',2)),e.connectionError?(a(),l("p",ry,c(e.connectionError),1)):f("v-if",!0),!e.connections&&!e.connectionError?(a(),l("p",ay,"Loading your connections\u2026")):f("v-if",!0),!e.connections&&e.connectionError?(a(),l("button",{key:2,class:"btn btn-outline-ink",disabled:e.busy,onClick:t[0]||(t[0]=s=>e.loadConnections())},"Try again",8,ly)):f("v-if",!0),e.connections?(a(),l("div",dy,[e.connections.emailNotificationsEnabled?(a(),l("section",uy,[t[6]||(t[6]=n("h2",null,"Email alerts",-1)),t[7]||(t[7]=n("p",null,"We will email you if your GitHub connection stops working or a repository becomes inaccessible. Your address is never shown on anonymous pages.",-1)),n("form",{onSubmit:t[2]||(t[2]=ae(s=>e.saveNotificationEmail(),["prevent"]))},[t[5]||(t[5]=n("label",{for:"notification-email"},"Email address",-1)),D(n("input",{id:"notification-email",class:"form-control",type:"email",autocomplete:"email",maxlength:"254",required:"","onUpdate:modelValue":t[1]||(t[1]=s=>e.notificationEmail=s),disabled:e.busy},null,8,cy),[[pt,e.notificationEmail]]),n("button",{class:"btn btn-ink mt-2",type:"submit",disabled:e.busy},"Save email address",8,py),e.emailSaved?(a(),l("p",fy,"Email address saved.")):f("v-if",!0)],32)])):f("v-if",!0),n("div",hy,[e.connections.appEnabled?(a(),l("section",my,[t[15]||(t[15]=n("div",{class:"connection-top"},[n("i",{class:"fab fa-github","aria-hidden":"true"}),n("span",{class:"connection-badge"},"Recommended")],-1)),n("div",gy,[t[8]||(t[8]=n("h2",null,"GitHub App",-1)),n("span",{class:A(["connection-status",{"is-connected":e.connections.appConnected&&!e.connections.appError}])},c(e.connections.appError?"Needs attention":e.connections.appConnected?"Connected":"Not connected"),3)]),t[16]||(t[16]=n("p",null,"Read-only access to gists and the repositories you choose.",-1)),e.connections.appError?(a(),l("p",vy,c(e.connections.appError)+". Reconnect to restore access.",1)):f("v-if",!0),n("div",yy,[e.connections.appConnected&&!e.connections.appError?(a(),l("a",by,[...t[9]||(t[9]=[g("Manage repository access ",-1),n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-external-link"})],-1)])])):f("v-if",!0),n("a",{class:A(e.connections.appConnected&&!e.connections.appError?"connection-link":"btn btn-ink"),target:"_self",href:"/github/app/login"},c(e.connections.appConnected?"Reconnect account":"Connect GitHub account"),3),e.connections.appConnected?(a(),l("button",{key:1,class:"connection-link connection-refresh",title:"Refresh access",disabled:e.busy,onClick:t[3]||(t[3]=s=>e.loadConnections())},[...t[10]||(t[10]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-refresh"})],-1),n("span",{class:"sr-only"},"Refresh access",-1)])],8,wy)):f("v-if",!0)]),t[17]||(t[17]=n("p",{class:"connection-help"},"Choose repositories on GitHub. Organization access may need an administrator's approval.",-1)),e.connections.installations?.length?(a(),l("ul",ky,[(a(!0),l(q,null,Q(e.connections.installations,s=>(a(),l("li",{key:s.id},[n("div",null,[t[11]||(t[11]=n("span",{class:"connection-label"},"Installed on",-1)),t[12]||(t[12]=g()),n("strong",null,c(s.account),1),s.suspended?(a(),l("span",Cy," \xB7 Suspended")):f("v-if",!0)]),e.connections.installations.length>1?(a(),l("a",{key:0,target:"_self",href:"/github/app/install?installationId="+s.id},[t[13]||(t[13]=g("Manage access ",-1)),n("span",Sy,"for "+c(s.account),1),t[14]||(t[14]=g(" \u2192",-1))],8,Ey)):f("v-if",!0)]))),128))])):f("v-if",!0)])):f("v-if",!0),n("section",null,[t[20]||(t[20]=n("div",{class:"connection-top"},[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-key"})]),n("span",{class:"connection-badge connection-badge-muted"},"Legacy")],-1)),n("div",Ny,[t[18]||(t[18]=n("h2",null,"GitHub OAuth",-1)),n("span",{class:A(["connection-status",{"is-connected":e.connections.oauthConnected}])},c(e.connections.oauthConnected?"Connected":"Not connected"),3)]),t[21]||(t[21]=n("p",null,"For existing OAuth anonymizations.",-1)),t[22]||(t[22]=n("p",{class:"connection-help"},"This connection uses GitHub's broader repository permissions. Existing work keeps using it until you switch below.",-1)),e.connections.oauthEnabled?(a(),l("a",Ry,c(e.connections.oauthConnected?"Reconnect OAuth":"Connect legacy OAuth"),1)):f("v-if",!0),e.connections.oauthConnected?(a(),l("div",Ay,[e.connections.gistCount?(a(),l("p",Py,c(e.connections.gistCount)+" gist(s) use your GitHub App connection when available.",1)):f("v-if",!0),t[19]||(t[19]=n("p",null,"Switch all dependent repositories before revoking access. Gists can use your GitHub App connection.",-1)),e.connections.appConnected?(a(),l("button",{key:1,class:"btn btn-sm btn-outline-danger connection-danger",disabled:e.busy||e.connections.resources.some(s=>s.connection==="oauth"),onClick:t[4]||(t[4]=s=>e.disconnectOAuth())},"Revoke OAuth access",8,Dy)):f("v-if",!0)])):f("v-if",!0)])]),n("section",Ty,[n("div",Oy,[t[23]||(t[23]=n("h2",null,"Repository connections",-1)),n("span",Iy,c(e.connections.resources?.length||0)+" "+c((e.connections.resources?.length||0)===1?"resource":"resources"),1)]),t[25]||(t[25]=n("p",null,"Check access, then switch each resource to the GitHub App. After reinstalling the App, reconnect existing resources here to keep their anonymous URLs and published snapshots.",-1)),e.connections.resources?.length?f("v-if",!0):(a(),l("div",My,[...t[24]||(t[24]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#project-type-repo"})],-1),n("div",null,[n("h3",null,"No repository connections yet"),n("p",null,"Your repositories and pull requests will appear here once you anonymize them.")],-1),n("a",{class:"connection-link",href:"/anonymize"},"New anonymization \u2192",-1)])])),(a(!0),l(q,null,Q(e.connections.resources,s=>(a(),l("div",{class:"connection-resource",key:s.type+s.id},[n("div",Vy,[n("strong",null,c(s.name||s.id),1),n("small",null,c(s.type)+" \xB7 "+c(s.id),1)]),n("span",{class:A(["connection-badge",{"connection-badge-muted":s.connection==="oauth"}])},c(s.connection==="github-app"?"Read-only App":"Legacy OAuth"),3),!["archived","removed","preparing","queue","removing","expiring"].includes(s.status)&&(s.status!=="download"||s.type==="pull-request"&&(!s.statusDate||new Date(s.statusDate).getTime()<=Date.now()-3e5))&&e.connections.appEnabled&&e.connections.appConnected?(a(),l("div",qy,[n("button",{class:"btn btn-outline-ink",disabled:e.busy,onClick:i=>e.changeConnection(s,"github-app",!0)},"Check read-only access",8,_y),s.eligible?(a(),l("button",{key:0,class:"btn btn-ink",disabled:e.busy,onClick:i=>e.changeConnection(s,"github-app",!1)},c(s.connection==="github-app"?"Reconnect read-only access":"Switch to read-only access"),9,Ly)):f("v-if",!0),s.eligible===!1?(a(),l("span",$y,"Access unavailable. Allow this repository on GitHub, then check again.")):f("v-if",!0)])):f("v-if",!0),!["archived","removed","preparing","queue","removing","expiring"].includes(s.status)&&(s.status!=="download"||s.type==="pull-request"&&(!s.statusDate||new Date(s.statusDate).getTime()<=Date.now()-3e5))&&s.connection==="github-app"&&e.connections.oauthConnected?(a(),l("button",{key:1,class:"connection-link",disabled:e.busy,onClick:i=>e.changeConnection(s,"oauth",!1)},"Use OAuth",8,Fy)):f("v-if",!0)]))),128)),t[26]||(t[26]=n("p",{class:"connection-footnote"},[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-info"})]),g(" Removing access stops new fetches from GitHub. Published content keeps its current expiration and removal settings.")],-1))])])):f("v-if",!0)])}var Uy={class:"container paper-page auth-page"},By={class:"auth-layout"},zy={class:"auth-options"},Hy={key:0},jy={key:0,class:"btn btn-ink auth-continue",target:"_self",href:"/github/login?recover=1"},Gy={key:1},Wy={key:1,class:"auth-card"},Ky={key:2,class:"auth-legacy"},Yy={key:3,role:"status"};function Zc(e,t){let s=Xe("partial-view");return a(),l(q,null,[n("div",Uy,[n("div",By,[t[4]||(t[4]=Ce('
Your research, ready for review

Your code.
Your identity,
protected.
Sign in to GitHub

Sign in to create and manage your anonymizations.

',1)),n("div",zy,[e.accountRecovery?(a(),l("section",Hy,[t[0]||(t[0]=n("h2",null,"Verify your existing account",-1)),t[1]||(t[1]=n("p",null,"We found an existing account. Verify it with your previous GitHub connection to keep your anonymizations. Future sign-ins will use the GitHub App.",-1)),e.site_options?.GITHUB_OAUTH_ENABLED?(a(),l("a",jy,"Verify with previous GitHub connection")):(a(),l("p",Gy,"Account verification is currently unavailable. Please try again later."))])):f("v-if",!0),e.site_options?.GITHUB_APP_ENABLED&&!e.accountRecovery?(a(),l("section",Wy,[...t[2]||(t[2]=[Ce('

Continue with GitHub

Connect through the GitHub App with read-only repository access.

  • You choose which repositories to share
  • No permission to write to your code
Sign in with GitHubYour existing anonymizations and connections stay with your account.',5)])])):f("v-if",!0),!e.site_options?.GITHUB_APP_ENABLED&&e.site_options?.GITHUB_OAUTH_ENABLED&&!e.accountRecovery?(a(),l("section",Ky,[...t[3]||(t[3]=[n("div",{class:"connection-title"},[n("h2",null,"Continue with GitHub")],-1),n("p",null,"Sign in to access your account. GitHub OAuth includes write access to private repositories.",-1),n("a",{class:"connection-link",target:"_self",href:"/github/login"},[g("Sign in with GitHub "),n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-arrow-right"})])],-1)])])):f("v-if",!0),e.site_options&&!e.site_options.GITHUB_APP_ENABLED&&!e.site_options.GITHUB_OAUTH_ENABLED?(a(),l("p",Yy,"GitHub sign-in is currently unavailable. Please try again later.")):f("v-if",!0)])])]),Oe(s,{name:"partials/footer.htm",state:e.viewState},null,8,["state"])],64)}function xc(e,t){let s=Xe("partial-view");return a(),l(q,null,[t[0]||(t[0]=Ce('
Error \xB7 404

This link
isn\u2019t here.

The anonymous mirror you\u2019re looking for has expired, been removed by its owner, or never existed. If you received this URL from an author, ask them to re-issue it.

',1)),Oe(s,{name:"partials/footer.htm",state:e.viewState},null,8,["state"])],64)}var Xy={class:"container paper-page admin-page"},Jy={class:"seg-bar"},Qy={class:"seg-filter",role:"radiogroup","aria-label":"Filter by status"},Zy=["aria-checked"],xy={class:"count"},eb=["aria-checked"],tb={class:"count"},sb=["aria-checked"],ob={class:"count"},ib=["aria-checked"],rb={class:"count"},ab=["aria-checked"],lb={class:"count"},db=["aria-checked"],ub={class:"count"},cb={class:"seg-countline",role:"status"},pb={key:0,class:"alert alert-danger",style:{margin:"8px 0"}},fb={class:"w-100 admin-filter-toolbar","aria-label":"Conferences","accept-charset":"UTF-8"},hb={class:"admin-filter-row"},mb={class:"search-wrap"},gb={type:"search",class:"form-control",placeholder:"Search conferences\u2026",autocomplete:"off"},vb={key:0,class:"admin-search-hint"},yb={key:1,class:"admin-filter-inline","aria-label":"Pagination"},bb=["disabled"],wb={style:{"font-family":"var(--font-mono)","font-size":"12px",color:"var(--ink-muted)"}},kb=["disabled"],Cb={key:0,class:"admin-filter-row"},Eb={class:"admin-active-chips"},Sb={class:"key"},Nb=["onClick"],Rb={class:"paper-table paper-table-conferences w-100",role:"table","aria-label":"Conferences"},Ab={key:0,class:"paper-table-head",role:"row"},Pb={role:"columnheader"},Db={role:"columnheader"},Tb={role:"columnheader"},Ob={class:"paper-table-row",role:"row"},Ib={class:"cell-anon",role:"cell"},Mb={class:"anon-text"},Vb=["textContent","href"],qb={class:"anon-sub"},_b={class:"cell-status",role:"cell"},Lb=["textContent"],$b={class:"cell-views num",role:"cell"},Fb=["textContent","href"],Ub={class:"cell-expires",role:"cell"},Bb={class:"cell-actions",role:"cell"},zb={class:"dropdown"},Hb={class:"dropdown-menu dropdown-menu-right"},jb=["href"],Gb=["href"],Wb=["href"],Kb=["onClick"],Yb={key:1,class:"paper-table-empty"},Xb={class:"admin-toolbar",style:{"justify-content":"space-between","border-bottom":"none"}},Jb={key:0,class:"pagination-compact"},Qb=["disabled"],Zb=["max"],xb=["disabled"],e1={class:"admin-filter-inline"},t1={class:"form-control form-control-sm"};function ep(e,t){let s=Pe("field"),i=Pe("form");return a(),l("div",Xy,[t[55]||(t[55]=Ce('
Admin \xA0/\xA0 Conferences

Conferences

',3)),n("div",Jy,[n("div",Qy,[n("button",{type:"button",role:"radio",class:A(["seg-chip",{active:e.segView()==="all"}]),"aria-checked":e.segView()==="all",onClick:t[0]||(t[0]=o=>e.setSegView("all"))},[t[14]||(t[14]=g("All ",-1)),n("span",xy,c(e.fmt?.number(e.segCount("all"))),1)],10,Zy),n("button",{type:"button",role:"radio",class:A(["seg-chip",{active:e.segView()==="ready","is-empty":!e.segCount("ready")}]),"aria-checked":e.segView()==="ready",onClick:t[1]||(t[1]=o=>e.setSegView("ready"))},[t[15]||(t[15]=n("span",{class:"seg-dot ok","aria-hidden":"true"},null,-1)),t[16]||(t[16]=g("Ready ",-1)),n("span",tb,c(e.fmt?.number(e.segCount("ready"))),1)],10,eb),n("button",{type:"button",role:"radio",class:A(["seg-chip",{active:e.segView()==="preparing","is-empty":!e.segCount("preparing")}]),"aria-checked":e.segView()==="preparing",onClick:t[2]||(t[2]=o=>e.setSegView("preparing"))},[t[17]||(t[17]=n("span",{class:"seg-dot warn","aria-hidden":"true"},null,-1)),t[18]||(t[18]=g("Preparing ",-1)),n("span",ob,c(e.fmt?.number(e.segCount("preparing"))),1)],10,sb),n("button",{type:"button",role:"radio",class:A(["seg-chip",{active:e.segView()==="error","is-empty":!e.segCount("error")}]),"aria-checked":e.segView()==="error",onClick:t[3]||(t[3]=o=>e.setSegView("error"))},[t[19]||(t[19]=n("span",{class:"seg-dot bad","aria-hidden":"true"},null,-1)),t[20]||(t[20]=g("Error ",-1)),n("span",rb,c(e.fmt?.number(e.segCount("error"))),1)],10,ib),n("button",{type:"button",role:"radio",class:A(["seg-chip",{active:e.segView()==="expired","is-empty":!e.segCount("expired")}]),"aria-checked":e.segView()==="expired",onClick:t[4]||(t[4]=o=>e.setSegView("expired"))},[t[21]||(t[21]=n("span",{class:"seg-dot off","aria-hidden":"true"},null,-1)),t[22]||(t[22]=g("Expired ",-1)),n("span",lb,c(e.fmt?.number(e.segCount("expired"))),1)],10,ab),n("button",{type:"button",role:"radio",class:A(["seg-chip",{active:e.segView()==="removed","is-empty":!e.segCount("removed")}]),"aria-checked":e.segView()==="removed",onClick:t[5]||(t[5]=o=>e.setSegView("removed"))},[t[23]||(t[23]=n("span",{class:"seg-dot off","aria-hidden":"true"},null,-1)),t[24]||(t[24]=g("Removed ",-1)),n("span",ub,c(e.fmt?.number(e.segCount("removed"))),1)],10,db)]),n("p",cb,[n("strong",null,c(e.total>=0?e.fmt.number(e.total):"\u2026"),1),t[25]||(t[25]=g(" shown",-1))])]),e.fetchError?(a(),l("div",pb,[t[26]||(t[26]=n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-warning"})],-1)),g(" "+c(e.fetchError),1)])):f("v-if",!0),D((a(),l("form",fb,[n("div",hb,[n("div",mb,[D(n("input",gb,null,512),[[s,{state:e.viewState,set:o=>{e.query.search=o},value:e.query?.search,form:null,options:{}}]]),e.query?.search?f("v-if",!0):(a(),l("span",vb,"/"))]),t[30]||(t[30]=n("span",{class:"admin-filter-spacer"},null,-1)),e.total>0?(a(),l("button",{key:0,class:"btn btn-sm",type:"button",onClick:t[6]||(t[6]=o=>e.exportCsv())},[...t[27]||(t[27]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-export"})],-1),g(" Export",-1)])])):f("v-if",!0),e.totalPage>1?(a(),l("span",yb,[n("button",{class:"btn btn-sm btn-icon",type:"button",onClick:t[7]||(t[7]=o=>e.query.page=Math.max(1,e.query.page-1)),disabled:e.query?.page<=1,"aria-label":"Previous page"},[...t[28]||(t[28]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-chevron-left"})],-1)])],8,bb),n("span",wb,c(e.query?.page)+"/"+c(e.totalPage||1),1),n("button",{class:"btn btn-sm btn-icon",type:"button",onClick:t[8]||(t[8]=o=>e.query.page=Math.min(e.totalPage,e.query.page+1)),disabled:e.query?.page>=e.totalPage,"aria-label":"Next page"},[...t[29]||(t[29]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-chevron-right"})],-1)])],8,kb)])):f("v-if",!0)]),e.chips?.length?(a(),l("div",Cb,[n("div",Eb,[(a(!0),l(q,null,Q(e.chips,(o,r)=>(a(),l("span",{class:"admin-active-chip",key:o?.key},[n("span",Sb,c(o?.label),1),n("span",null,c(o?.value),1),n("button",{type:"button",onClick:d=>e.clearFilter(o.key),"aria-label":"Clear filter"},[...t[31]||(t[31]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#project-icon-close"})],-1)])],8,Nb)]))),128))])])):f("v-if",!0)])),[[i,e.viewState]]),n("div",Rb,[e.total!==0?(a(),l("div",Ab,[n("div",Pb,[n("button",{type:"button",class:A(["sortable",{active:e.query?.sort=="name"}]),onClick:t[9]||(t[9]=o=>e.sortBy("name"))},[t[33]||(t[33]=g("Conference ",-1)),e.sortIcon("name")?(a(),l("svg",{key:0,class:A(["ui-icon sort-direction",{ascending:e.sortIcon("name")==="fa-arrow-up"}]),"aria-hidden":"true"},[...t[32]||(t[32]=[n("use",{href:"#project-icon-arrow"},null,-1)])],2)):f("v-if",!0)],2)]),n("div",Db,[n("button",{type:"button",class:A(["sortable",{active:e.query?.sort=="status"}]),onClick:t[10]||(t[10]=o=>e.sortBy("status"))},[t[35]||(t[35]=g("Status ",-1)),e.sortIcon("status")?(a(),l("svg",{key:0,class:A(["ui-icon sort-direction",{ascending:e.sortIcon("status")==="fa-arrow-up"}]),"aria-hidden":"true"},[...t[34]||(t[34]=[n("use",{href:"#project-icon-arrow"},null,-1)])],2)):f("v-if",!0)],2)]),t[38]||(t[38]=n("div",{role:"columnheader",class:"num"},"Repos",-1)),n("div",Tb,[n("button",{type:"button",class:A(["sortable",{active:e.query?.sort=="startDate"}]),onClick:t[11]||(t[11]=o=>e.sortBy("startDate"))},[t[37]||(t[37]=g("Window ",-1)),e.sortIcon("startDate")?(a(),l("svg",{key:0,class:A(["ui-icon sort-direction",{ascending:e.sortIcon("startDate")==="fa-arrow-up"}]),"aria-hidden":"true"},[...t[36]||(t[36]=[n("use",{href:"#project-icon-arrow"},null,-1)])],2)):f("v-if",!0)],2)]),t[39]||(t[39]=n("div",{role:"columnheader","aria-label":"Actions"},null,-1))])):f("v-if",!0),(a(!0),l(q,null,Q(e.filteredConferences,(o,r)=>(a(),l("div",Ob,[n("div",Ib,[t[40]||(t[40]=n("svg",{class:"ui-icon record-type-icon",role:"img","aria-label":"Conference"},[n("use",{href:"#project-icon-conference"})],-1)),n("div",Mb,[n("a",{class:"repo-name",textContent:c(o?.name),href:e.safeUrl("/conference/"+o?.conferenceID)},null,8,Vb),n("div",qb,[n("span",null,c(o?.conferenceID),1),n("span",null,c(e.fmt?.money(o?.price||0)),1)])])]),n("div",_b,[n("span",{class:A(["status-dot","st-"+(o?.status||"unknown")])},null,2),n("span",{textContent:c(e.fmt?.statusLabel(o?.status))},null,8,Lb)]),n("div",$b,[t[41]||(t[41]=n("svg",{class:"ui-icon mobile-meta-icon","aria-hidden":"true"},[n("use",{href:"#project-type-repo"})],-1)),n("a",{title:"Show repositories in this conference",textContent:c(e.fmt?.number(o?.repositories?.length||0)),href:e.safeUrl("/admin/?conference="+o?.conferenceID)},null,8,Fb)]),n("div",Ub,[t[42]||(t[42]=n("svg",{class:"ui-icon mobile-meta-icon","aria-hidden":"true"},[n("use",{href:"#project-icon-clock"})],-1)),g(" "+c(e.fmt?.date(o?.startDate))+" \u2013 "+c(e.fmt?.date(o?.endDate)),1)]),n("div",Bb,[n("div",zb,[t[48]||(t[48]=n("button",{class:"btn btn-icon-dots",type:"button","data-toggle":"dropdown","aria-haspopup":"true","aria-expanded":"false","aria-label":"Actions"},[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#project-icon-more"})])],-1)),n("div",Hb,[n("a",{class:"dropdown-item",href:e.safeUrl("/conference/"+o?.conferenceID+"/edit")},[...t[43]||(t[43]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-edit"})],-1),g(" Edit",-1)])],8,jb),n("a",{class:"dropdown-item",href:e.safeUrl("/conference/"+o?.conferenceID+"/")},[...t[44]||(t[44]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#project-icon-eye"})],-1),g(" View",-1)])],8,Gb),n("a",{class:"dropdown-item",href:e.safeUrl("/admin/?conference="+o?.conferenceID)},[...t[45]||(t[45]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#project-type-repo"})],-1),g(" View repositories",-1)])],8,Wb),t[47]||(t[47]=n("div",{class:"dropdown-divider"},null,-1)),D(n("a",{class:"dropdown-item text-danger",href:"#",onClick:ae(d=>e.removeConference(o),["prevent"])},[...t[46]||(t[46]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-trash"})],-1),g(" Remove",-1)])],8,Kb),[[Z,o?.status!="removed"]])])])])]))),256)),e.filteredConferences?.length==0?(a(),l("div",Yb,[t[49]||(t[49]=n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#project-icon-inbox"})],-1)),n("span",null,c(e.total?"No conferences match the current filters.":"No conferences yet."),1)])):f("v-if",!0)]),n("div",Xb,[t[54]||(t[54]=n("span",{"aria-hidden":"true"},null,-1)),e.totalPage>1?(a(),l("div",Jb,[n("button",{class:"btn btn-sm",onClick:t[12]||(t[12]=o=>e.query.page=Math.max(1,e.query.page-1)),disabled:e.query?.page<=1},[...t[50]||(t[50]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-chevron-left"})],-1),g(" Previous",-1)])],8,Qb),D(n("input",{type:"number",class:"form-control form-control-sm",min:"1",style:{width:"56px"},max:e.totalPage},null,8,Zb),[[s,{state:e.viewState,set:o=>{e.query.page=o},value:e.query?.page,form:null,options:{}}]]),n("span",null,"of "+c(e.totalPage),1),n("button",{class:"btn btn-sm",onClick:t[13]||(t[13]=o=>e.query.page=Math.min(e.totalPage,e.query.page+1)),disabled:e.query?.page>=e.totalPage},[...t[51]||(t[51]=[g("Next ",-1),n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-chevron-right"})],-1)])],8,xb)])):f("v-if",!0),n("span",e1,[t[53]||(t[53]=n("label",null,"Per page",-1)),D((a(),l("select",t1,[...t[52]||(t[52]=[Ce('',5)])])),[[s,{state:e.viewState,set:o=>{e.query.limit=o},value:e.query?.limit,form:null,options:{}}]])])])])}var n1={class:"container paper-page admin-page errors-page"},s1={class:"errors-header"},o1={class:"errors-actions"},i1={class:"kpi-grid"},r1={class:"kpi-card"},a1={class:"kpi-value"},l1={key:0},d1={key:1},u1={key:2},c1=["aria-pressed"],p1={class:"kpi-value"},f1={class:"kpi-sub"},h1=["aria-pressed"],m1={class:"kpi-value"},g1={class:"kpi-sub"},v1=["aria-pressed"],y1={class:"kpi-value"},b1={class:"kpi-sub"},w1={class:"kpi-value"},k1={class:"kpi-sub"},C1={key:0,class:"dropped-warn"},E1={class:"volume-chart"},S1={class:"volume-head"},N1={class:"volume-legend"},R1={key:0},A1={key:1},P1={key:2},D1={class:"volume-bars"},T1=["title"],O1={class:"errors-toolbar","aria-label":"Error filters"},I1={class:"seg-filter",role:"radiogroup","aria-label":"Filter by severity"},M1=["aria-checked"],V1={class:"count"},q1=["aria-checked"],_1={class:"count"},L1=["aria-checked"],$1={class:"count"},F1=["aria-checked"],U1={class:"count"},B1={class:"search-wrap"},z1={type:"search",class:"form-control",placeholder:"Search errors\u2026",title:"Search messages, or filter with code:repo_not_found module:route status:>=400",autocomplete:"off"},H1={key:0,class:"filter-count"},j1={class:"select-wrap"},G1={class:"form-control form-control-sm"},W1={class:"select-wrap"},K1={class:"form-control form-control-sm"},Y1={class:"autoref"},X1={type:"checkbox"},J1={key:0,class:"admin-empty"},Q1={key:1,class:"errors-pager"},Z1={key:2,class:"errors-list"},x1={key:0,class:"errors-group-head"},ew={class:"errors-group-count"},tw={key:0,class:"errors-group-note"},nw=["onClick"],sw={class:"col-when"},ow={class:"when-rel"},iw={class:"when-abs"},rw={class:"col-sev"},aw={class:"sev-label"},lw={class:"col-mod"},dw={class:"pill pill-module"},uw={class:"col-msg"},cw={class:"msg-code"},pw={key:0,class:"msg-context"},fw={key:1,class:"msg-detail"},hw=["title"],mw={class:"col-count"},gw={key:0,class:"count-pill"},vw={key:1,class:"count-pill count-pill-muted"},yw={class:"col-status"},bw=["title"],ww={key:1,class:"status-empty",title:"No HTTP status for this event"},kw={key:0,class:"errors-row-detail"},Cw={class:"detail-tabs"},Ew=["onClick"],Sw=["onClick"],Nw=["onClick"],Rw={class:"detail-body"},Aw={class:"detail-main"},Pw={key:0},Dw={key:1,class:"stack-pre"},Tw={key:2,class:"related-list"},Ow={class:"when-abs"},Iw={class:"msg-url"},Mw={class:"detail-actions"},Vw=["onClick"],qw=["onClick"],_w={key:0,class:"copy-hint"},Lw={class:"detail-aside"},$w={class:"aside-block"},Fw=["title"],Uw={class:"aside-block"},Bw=["title"],zw={class:"aside-block"},Hw={class:"aside-value"},jw={key:0,class:"aside-sub"},Gw={key:0,class:"aside-block"},Ww=["href"],Kw={key:1,class:"aside-block"},Yw={class:"aside-value mono"};function tp(e,t){let s=Pe("field"),i=Pe("form");return a(),l("div",n1,[t[49]||(t[49]=n("div",{class:"paper-crumbs"},[g("Admin \xA0/\xA0 "),n("span",{class:"here"},"Errors")],-1)),n("header",s1,[t[16]||(t[16]=n("h1",{class:"paper-page-title"},"Errors",-1)),n("div",o1,[n("button",{class:"btn btn-sm",type:"button",onClick:t[0]||(t[0]=o=>e.exportCsv())},[...t[14]||(t[14]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-export"})],-1),g(" Export CSV",-1)])]),n("button",{class:"btn btn-sm btn-outline-danger",type:"button",onClick:t[1]||(t[1]=o=>e.clearAll())},[...t[15]||(t[15]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-trash"})],-1),g(" Clear all",-1)])])])]),t[50]||(t[50]=Ce('',1)),n("section",i1,[n("div",r1,[t[17]||(t[17]=n("div",{class:"kpi-label"},"Occurrences \xB7 24h",-1)),n("div",a1,c(e.fmt?.number(e.stats?.last24h??0)),1),n("div",{class:A(["kpi-sub",{up:e.stats?.delta>0,down:e.stats?.delta<0}])},[e.stats?.prev24h>=20?(a(),l("span",l1,c((e.stats?.last24h??0)-(e.stats?.prev24h??0)>=0?"+":"")+c(Math.round(((e.stats?.last24h??0)-(e.stats?.prev24h??0))/e.stats.prev24h*100))+"% vs yesterday",1)):e.stats?.prev24h!==void 0?(a(),l("span",d1,c(e.fmt?.number(e.stats?.prev24h??0))+" in prior 24h",1)):f("v-if",!0),e.stats?.prev24h?f("v-if",!0):(a(),l("span",u1,"no prior baseline"))],2)]),n("div",{class:A(["kpi-card kpi-error kpi-filter",{"is-selected":e.query?.bucket==="error"}]),role:"button",tabindex:"0","aria-pressed":e.query?.bucket==="error",title:"Show only errors (5xx)",onClick:t[2]||(t[2]=o=>e.setBucket(e.query?.bucket==="error"?"":"error")),onKeydown:t[3]||(t[3]=kt(ae(o=>e.setBucket(e.query?.bucket==="error"?"":"error"),["prevent"]),["enter"]))},[t[18]||(t[18]=n("div",{class:"kpi-label"},"Error",-1)),n("div",p1,c(e.fmt?.number(e.stats?.severity?.error??0)),1),n("div",f1,"5xx \xB7 "+c(e.stats?.unique?.error)+" unique",1)],42,c1),n("div",{class:A(["kpi-card kpi-warn kpi-filter",{"is-selected":e.query?.bucket==="warn"}]),role:"button",tabindex:"0","aria-pressed":e.query?.bucket==="warn",title:"Show only warnings (4xx, aborted requests)",onClick:t[4]||(t[4]=o=>e.setBucket(e.query?.bucket==="warn"?"":"warn")),onKeydown:t[5]||(t[5]=kt(ae(o=>e.setBucket(e.query?.bucket==="warn"?"":"warn"),["prevent"]),["enter"]))},[t[19]||(t[19]=n("div",{class:"kpi-label"},"Warning",-1)),n("div",m1,c(e.fmt?.number(e.stats?.severity?.warn??0)),1),n("div",g1,"4xx, aborted \xB7 "+c(e.stats?.unique?.warn)+" unique",1)],42,h1),n("div",{class:A(["kpi-card kpi-info kpi-filter",{"is-selected":e.query?.bucket==="info"}]),role:"button",tabindex:"0","aria-pressed":e.query?.bucket==="info",title:"Show only info events",onClick:t[6]||(t[6]=o=>e.setBucket(e.query?.bucket==="info"?"":"info")),onKeydown:t[7]||(t[7]=kt(ae(o=>e.setBucket(e.query?.bucket==="info"?"":"info"),["prevent"]),["enter"]))},[t[20]||(t[20]=n("div",{class:"kpi-label"},"Info",-1)),n("div",y1,c(e.fmt?.number(e.stats?.severity?.info??0)),1),n("div",b1,"Auth, 404 \xB7 "+c(e.stats?.unique?.info)+" unique",1)],42,v1),n("div",{class:A(["kpi-card",{"kpi-error":e.stats?.dropped>0}])},[t[21]||(t[21]=n("div",{class:"kpi-label"},"Distinct errors stored",-1)),n("div",w1,c(e.fmt?.number(e.total)),1),n("div",k1,[g(" all time \xB7 cap "+c(e.fmt?.number(e.cap))+" \xB7 "+c(e.available?"live":"redis off")+" ",1),e.stats?.dropped>0?(a(),l("span",C1," \xB7 "+c(e.stats?.dropped)+" dropped",1)):f("v-if",!0)])],2)]),n("section",E1,[n("div",S1,[t[25]||(t[25]=n("span",{class:"volume-title"},"Volume \xB7 24h \xB7 1h buckets",-1)),n("span",N1,[e.stats?.severity?.error?(a(),l("span",R1,[...t[22]||(t[22]=[n("span",{class:"dot dot-error"},null,-1),g("Error",-1)])])):f("v-if",!0),e.stats?.severity?.warn?(a(),l("span",A1,[...t[23]||(t[23]=[n("span",{class:"dot dot-warn"},null,-1),g("Warning",-1)])])):f("v-if",!0),e.stats?.severity?.info?(a(),l("span",P1,[...t[24]||(t[24]=[n("span",{class:"dot dot-info"},null,-1),g("Info",-1)])])):f("v-if",!0)])]),n("div",D1,[(a(!0),l(q,null,Q(e.stats?.buckets,(o,r)=>(a(),l("div",{class:"volume-bar",key:r,title:e.bucketTitle(o)},[n("span",{class:"seg seg-error",style:Ie({height:e.barPx(o,"error")+"px"})},null,4),n("span",{class:"seg seg-warn",style:Ie({height:e.barPx(o,"warn")+"px"})},null,4),n("span",{class:"seg seg-info",style:Ie({height:e.barPx(o,"info")+"px"})},null,4)],8,T1))),128))]),t[26]||(t[26]=n("div",{class:"volume-axis","aria-hidden":"true"},[n("span",null,"24h ago"),n("span",null,"12h ago"),n("span",null,"now")],-1))]),D((a(),l("form",O1,[n("div",I1,[n("button",{type:"button",role:"radio",class:A(["seg-chip",{active:(e.query?.bucket||"")===""}]),"aria-checked":(e.query?.bucket||"")==="",onClick:t[8]||(t[8]=o=>e.setBucket(""))},[t[27]||(t[27]=g("All ",-1)),n("span",V1,c(e.fmt?.number((e.stats?.severity?.error??0)+(e.stats?.severity?.warn??0)+(e.stats?.severity?.info??0))),1)],10,M1),n("button",{type:"button",role:"radio",class:A(["seg-chip",{active:(e.query?.bucket||"")==="error","is-empty":!e.stats?.severity?.error}]),"aria-checked":(e.query?.bucket||"")==="error",onClick:t[9]||(t[9]=o=>e.setBucket("error"))},[t[28]||(t[28]=n("span",{class:"seg-dot bad","aria-hidden":"true"},null,-1)),t[29]||(t[29]=g("Error ",-1)),n("span",_1,c(e.fmt?.number(e.stats?.severity?.error??0)),1)],10,q1),n("button",{type:"button",role:"radio",class:A(["seg-chip",{active:(e.query?.bucket||"")==="warn","is-empty":!e.stats?.severity?.warn}]),"aria-checked":(e.query?.bucket||"")==="warn",onClick:t[10]||(t[10]=o=>e.setBucket("warn"))},[t[30]||(t[30]=n("span",{class:"seg-dot warn","aria-hidden":"true"},null,-1)),t[31]||(t[31]=g("Warning ",-1)),n("span",$1,c(e.fmt?.number(e.stats?.severity?.warn??0)),1)],10,L1),n("button",{type:"button",role:"radio",class:A(["seg-chip",{active:(e.query?.bucket||"")==="info","is-empty":!e.stats?.severity?.info}]),"aria-checked":(e.query?.bucket||"")==="info",onClick:t[11]||(t[11]=o=>e.setBucket("info"))},[t[32]||(t[32]=n("span",{class:"seg-dot off","aria-hidden":"true"},null,-1)),t[33]||(t[33]=g("Info ",-1)),n("span",U1,c(e.fmt?.number(e.stats?.severity?.info??0)),1)],10,F1)]),n("div",B1,[t[34]||(t[34]=n("svg",{class:"ui-icon search-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-search"})],-1)),D(n("input",z1,null,512),[[s,{state:e.viewState,set:o=>{e.query.search=o},value:e.query?.search,form:null,options:{}}]]),e.parsedFilterCount?(a(),l("span",H1,c(e.parsedFilterCount)+" filter"+c(e.parsedFilterCount>1?"s":""),1)):f("v-if",!0)]),n("div",j1,[t[36]||(t[36]=n("label",null,"Sort",-1)),D((a(),l("select",G1,[...t[35]||(t[35]=[n("option",{value:"recent"},"Most recent",-1),n("option",{value:"count"},"Most frequent",-1)])])),[[s,{state:e.viewState,set:o=>{e.query.sort=o},value:e.query?.sort,form:null,options:{}}]])]),n("div",W1,[t[38]||(t[38]=n("label",{title:"Rows are always sectioned by severity. This merges repeated events inside each section."},"Merge",-1)),D((a(),l("select",K1,[...t[37]||(t[37]=[n("option",{value:""},"Don't merge",-1),n("option",{value:"code"},"Same error",-1),n("option",{value:"module"},"Same module",-1)])])),[[s,{state:e.viewState,set:o=>{e.query.group=o},value:e.query?.group,form:null,options:{}}]])]),n("label",Y1,[D(n("input",X1,null,512),[[s,{state:e.viewState,set:o=>{e.query.autoRefresh=o},value:e.query?.autoRefresh,form:null,options:{}}]]),t[39]||(t[39]=n("span",{class:"auto-refresh-label"},"Auto-refresh",-1))]),n("button",{class:"btn btn-sm btn-icon",type:"button",title:"Refresh now",onClick:t[12]||(t[12]=o=>e.refreshNow()),"aria-label":"Refresh"},[...t[40]||(t[40]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-refresh"})],-1)])])])),[[i,e.viewState]]),e.visible?.length?f("v-if",!0):(a(),l("div",J1,"No errors captured.")),e.canLoadMore()&&e.visible?.length?(a(),l("div",Q1,[n("span",null,c(e.query?.group&&e.visible?.length!==e.entries?.length?e.fmt?.number(e.visible?.length)+(e.visible?.length===1?" group":" groups")+" from ":"")+c(e.fmt?.number(e.entries?.length))+" of "+c(e.fmt?.number(e.total))+" stored errors loaded",1),n("button",{class:"btn btn-sm",type:"button",onClick:t[13]||(t[13]=o=>e.loadMore())},"Load 250 older")])):f("v-if",!0),e.visible?.length?(a(),l("div",Z1,[t[48]||(t[48]=Ce('
WhenSeverityModuleMessageTotalStatus
',1)),(a(!0),l(q,null,Q(e.visible,(o,r)=>(a(),l(q,{key:o?._key},[r===0||e.visible[r-1]?._bucket!==o?._bucket?(a(),l("div",x1,[n("span",{class:A(["sev-dot","sev-"+o?._bucket])},null,2),g(c(o?._bucket==="error"?"Error":o?._bucket==="warn"?"Warning":"Info"),1),n("span",ew,c(e.fmt?.number(e.visible.filter(d=>d?._bucket===o?._bucket).length)),1),r===0?(a(),l("span",tw,"By severity \xB7 "+c(e.query?.group==="code"?"repeats merged by error \xB7 ":e.query?.group==="module"?"repeats merged by module \xB7 ":"")+c(e.query?.sort==="count"?"most frequent first":"most recent first"),1)):f("v-if",!0)])):f("v-if",!0),n("div",{class:A(["errors-row",{open:e.expanded[o?._key]}])},[n("div",{class:"errors-row-main",onClick:d=>e.toggle(o)},[n("div",sw,[n("div",ow,c(e.relTime(o?.ts)),1),n("div",iw,c(e.absTimeShort(o?.ts)),1)]),n("div",rw,[n("span",{class:A(["sev-dot","sev-"+o?._bucket])},null,2),n("span",aw,c(o?._bucket==="error"?"Error":o?._bucket==="warn"?"Warning":"Info"),1)]),n("div",lw,[n("span",dw,c(o?.module),1)]),n("div",uw,[n("strong",cw,c(o?.displayMessage),1),o?.displayContext&&o?.displayContext!==o?.displayMessage?(a(),l("span",pw,c(o?.displayContext),1)):f("v-if",!0),o?._detail?(a(),l("span",fw,c(o?._detail),1)):f("v-if",!0),o?._url?(a(),l("div",{key:2,class:"msg-url",title:o?._url},c(o?._url),9,hw)):f("v-if",!0)]),n("div",mw,[o?.count>1?(a(),l("span",gw,"\xD7"+c(o?.count),1)):f("v-if",!0),o?.count===1?(a(),l("span",vw,"\xD71")):f("v-if",!0)]),n("div",yw,[o?._status?(a(),l("span",{key:0,class:A(["status-pill",String(o?._status).match(/^[23]/)?"status-neutral":"status-"+o?._bucket]),title:String(o?._status).match(/^2/)&&o?._bucket==="warn"?"Client closed the connection":null},c(String(o?._status).match(/^2/)&&o?._bucket==="warn"?"\u2014":o?._status),11,bw)):f("v-if",!0),o?._status?f("v-if",!0):(a(),l("span",ww,"\u2014"))])],8,nw),e.expanded[o?._key]?(a(),l("div",kw,[n("div",Cw,[n("button",{type:"button",class:A({active:e.detailTab[o?._key]==="raw"||!e.detailTab[o?._key]}),onClick:d=>e.detailTab[o._key]="raw"},"Raw",10,Ew),o?._stack?(a(),l("button",{key:0,type:"button",class:A({active:e.detailTab[o?._key]==="stack"}),onClick:d=>e.detailTab[o._key]="stack"},"Stack",10,Sw)):f("v-if",!0),o?.count>1?(a(),l("button",{key:1,type:"button",class:A({active:e.detailTab[o?._key]==="related"}),onClick:d=>e.detailTab[o._key]="related"},"Related ("+c(o?.count)+")",11,Nw)):f("v-if",!0)]),n("div",Rw,[n("div",Aw,[(e.detailTab[o?._key]||"raw")==="raw"?(a(),l("pre",Pw,c(o?._detailJson),1)):f("v-if",!0),e.detailTab[o?._key]==="stack"?(a(),l("pre",Dw,c(o?._stack),1)):f("v-if",!0),e.detailTab[o?._key]==="related"?(a(),l("div",Tw,[(a(!0),l(q,null,Q(o?._related,(d,p)=>(a(),l("div",{class:"related-row",key:p},[n("span",Ow,c(e.absTimeShort(d?.ts)),1),n("span",Iw,c(d?._url),1),d?._status?(a(),l("span",{key:0,class:A(["status-pill","status-"+d?._bucket])},c(d?._status),3)):f("v-if",!0)]))),128))])):f("v-if",!0),n("div",Mw,[n("button",{class:"btn btn-sm",type:"button",title:"Copy a curl that reproduces the request",onClick:d=>e.copyCurl(o)},[...t[41]||(t[41]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-code"})],-1),g(" Copy curl",-1)])],8,Vw),n("button",{class:"btn btn-sm",type:"button",onClick:d=>e.copyJson(o)},[...t[42]||(t[42]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-clipboard"})],-1),g(" Copy JSON",-1)])],8,qw),e.copyHint?(a(),l("span",_w,c(e.copyHint),1)):f("v-if",!0)])]),n("aside",Lw,[n("div",$w,[t[43]||(t[43]=n("div",{class:"aside-label"},"First seen",-1)),n("div",{class:"aside-value",title:e.absTime(o?._firstSeen)},c(e.relTime(o?._firstSeen)),9,Fw)]),n("div",Uw,[t[44]||(t[44]=n("div",{class:"aside-label"},"Last seen",-1)),n("div",{class:"aside-value",title:e.absTime(o?.ts)},c(e.relTime(o?.ts)),9,Bw)]),n("div",zw,[t[45]||(t[45]=n("div",{class:"aside-label"},"Occurrences",-1)),n("div",Hw,[g(c(o?.count),1),o?._lastHourCount?(a(),l("span",jw," \xB7 "+c(o?._lastHourCount)+" this hour",1)):f("v-if",!0)])]),o?._repoId?(a(),l("div",Gw,[t[46]||(t[46]=n("div",{class:"aside-label"},"Repository",-1)),n("a",{class:"aside-value",href:e.safeUrl("/r/"+o?._repoId)},c(o?._repoId),9,Ww)])):f("v-if",!0),o?._url?(a(),l("div",Kw,[t[47]||(t[47]=n("div",{class:"aside-label"},"URL",-1)),n("div",Yw,c(o?._url),1)])):f("v-if",!0)])])])):f("v-if",!0)],2)],64))),128))])):f("v-if",!0)])}var Xw={class:"container paper-page admin-page overview-page"},Jw={key:0,class:"admin-empty"},Qw={key:1,class:"alert alert-danger",style:{margin:"12px 0"}},Zw={class:"ov-views",role:"tablist","aria-label":"Overview sections"},xw=["aria-selected","onClick"],ek={key:2},tk={key:0,class:"ov-health",role:"status"},nk={class:"ov-kpi-row"},sk={class:"ov-kpi-card"},ok={class:"ov-kpi-value"},ik={class:"ov-kpi-sub"},rk={class:"ov-kpi-card"},ak={class:"ov-kpi-sub"},lk={class:"ov-kpi-card"},dk={class:"ov-kpi-sub"},uk={class:"ov-kpi-card"},ck={class:"ov-kpi-sub"},pk={class:"ov-kpi-card"},fk={class:"ov-kpi-value"},hk={class:"ov-kpi-sub"},mk={class:"ov-daily-row"},gk={class:"ov-daily-card"},vk={class:"ov-daily-value"},yk={class:"ov-daily-card"},bk={class:"ov-daily-value"},wk={class:"ov-daily-sub"},kk={class:"ov-daily-card"},Ck={class:"ov-daily-value"},Ek={class:"ov-chart-card"},Sk={class:"ov-chart-head"},Nk={class:"ov-chart-legends"},Rk={class:"ov-chart-legend"},Ak={key:0,class:"ov-legend-missing"},Pk={key:0,class:"ov-spark-bars ov-has-axis"},Dk={class:"ov-yaxis","aria-hidden":"true"},Tk=["data-tip","aria-label"],Ok={key:1,class:"ov-spark-x"},Ik={class:"ov-chart-card"},Mk={class:"ov-chart-head"},Vk={class:"ov-chart-legends"},qk={class:"ov-chart-legend"},_k={key:0,class:"ov-legend-missing"},Lk={key:0,class:"ov-spark-bars ov-has-axis"},$k={class:"ov-yaxis","aria-hidden":"true"},Fk=["data-tip","aria-label"],Uk={key:1,class:"ov-spark-x"},Bk={key:0,class:"ov-chart-card"},zk={class:"ov-chart-head"},Hk={class:"ov-chart-legends"},jk={class:"ov-chart-legend"},Gk={key:0,class:"ov-legend-missing"},Wk={key:0,class:"ov-spark-bars ov-spark-step ov-has-axis"},Kk={class:"ov-yaxis","aria-hidden":"true"},Yk=["viewBox","aria-label"],Xk=["d"],Jk=["d"],Qk={key:1,class:"ov-spark-x"},Zk={class:"ov-chart-card"},xk={class:"ov-chart-head"},e0={class:"ov-chart-legends"},t0={class:"ov-chart-legend"},n0={key:0,class:"ov-legend-missing"},s0={key:0,class:"ov-spark-bars ov-has-axis"},o0={class:"ov-yaxis","aria-hidden":"true"},i0=["data-tip","aria-label"],r0={key:1,class:"ov-spark-x"},a0={class:"ov-triple-row"},l0={class:"ov-panel-card"},d0={class:"ov-panel-head"},u0={class:"ov-panel-meta"},c0={class:"ov-stacked-bar"},p0={class:"ov-bar-legend"},f0={href:"/admin/repositories",class:"ov-legend-item"},h0={class:"ov-legend-n"},m0={href:"/admin/repositories",class:"ov-legend-item"},g0={class:"ov-legend-n"},v0={href:"/admin/repositories",class:"ov-legend-item"},y0={class:"ov-legend-n"},b0={href:"/admin/repositories",class:"ov-legend-item"},w0={class:"ov-legend-n"},k0={href:"/admin/repositories",class:"ov-legend-item"},C0={class:"ov-legend-n"},E0={class:"ov-panel-card"},S0={class:"ov-panel-head"},N0={class:"ov-panel-meta"},R0={class:"ov-error-bars"},A0={class:"ov-ebar-row"},P0={class:"ov-ebar-track"},D0={class:"ov-ebar-n"},T0={class:"ov-ebar-row"},O0={class:"ov-ebar-track"},I0={class:"ov-ebar-n"},M0={key:0,class:"ov-ehours",role:"img","aria-label":"Errors per hour over the last 24 hours"},V0={class:"ov-ehours-legend"},q0={class:"ov-ehours-note"},_0={class:"ov-ehours-bars"},L0=["title"],$0={key:0,class:"ov-ehours-zero"},F0={class:"ov-ebar-note"},U0={key:0,class:"ov-panel-foot"},B0={href:"/admin/errors"},z0={class:"ov-panel-card"},H0={class:"ov-routes-table"},j0={class:"ov-route-row",href:"/admin/queues"},G0={class:"ov-route-n"},W0={class:"ov-route-n"},K0={class:"ov-route-row",href:"/admin/queues"},Y0={class:"ov-route-n"},X0={class:"ov-route-n"},J0={class:"ov-route-row",href:"/admin/queues"},Q0={class:"ov-route-n"},Z0={class:"ov-route-n"},x0={class:"ov-services-card"},e2={class:"ov-services-head"},t2={class:"ov-panel-meta"},n2={class:"ov-services-grid"},s2={class:"ov-svc"},o2={class:"ov-svc-info"},i2={class:"ov-svc-meta"},r2={class:"ov-svc"},a2={class:"ov-svc-info"},l2={key:0,class:"ov-svc-meta"},d2={key:1,class:"ov-svc-meta"},u2={class:"ov-svc"},c2={class:"ov-svc-info"},p2={key:0,class:"ov-svc-meta"},f2={key:1,class:"ov-svc-meta"},h2={class:"ov-svc"},m2={class:"ov-svc-info"},g2={key:0,class:"ov-svc-meta"},v2={key:1,class:"ov-svc-meta"},y2={class:"ov-svc"},b2=["title"],w2={class:"ov-svc-info"},k2={class:"ov-svc-meta"},C2={class:"ov-panel-card ov-cache","aria-labelledby":"cache-heading"},E2={class:"ov-panel-head ov-performance-head"},S2={class:"ov-performance-window"},N2={key:0,class:"ov-performance-message ov-performance-warning",role:"alert"},R2={key:1,class:"ov-performance-empty",role:"status"},A2={key:0,class:"ov-performance-note"},P2={key:1,class:"ov-performance-note"},D2={key:2,class:"ov-performance-message ov-performance-warning",role:"status"},T2={key:3,class:"ov-metrics-scroll",tabindex:"0",role:"region","aria-label":"Cache storage budgets"},O2={class:"ov-metrics-table"},I2={scope:"row",class:"ov-event-name"},M2=["title"],V2={key:0,class:"ov-metric-bad-text"},q2={key:1,class:"budget-bar","aria-hidden":"true"},_2={class:"num"},L2={class:"num"},$2={class:"num"},F2={class:"num"},U2={key:4,class:"ov-cache-rates"},B2={key:5,class:"ov-metrics-scroll",tabindex:"0",role:"region","aria-label":"Cache events and processing durations"},z2={class:"ov-metrics-table"},H2={scope:"row",class:"ov-event-name"},j2={class:"ov-event-traffic"},G2={class:"num"},W2={class:"num"},K2={key:6,class:"ov-performance-empty",role:"status"},Y2={class:"ov-performance-note"},X2={class:"ov-panel-card ov-performance","aria-labelledby":"performance-heading"},J2={class:"ov-panel-head ov-performance-head"},Q2={class:"ov-performance-window"},Z2={key:0,class:"ov-performance-message ov-performance-warning",role:"alert"},x2={key:1,class:"ov-performance-empty",role:"status"},eC={key:2},tC={id:"performance-routes",role:"region","aria-label":"Routes"},nC={key:0,class:"ov-metrics-scroll",tabindex:"0",role:"region","aria-label":"Route latency metrics, scroll for more columns"},sC={class:"ov-metrics-table"},oC={scope:"row",class:"ov-metric-name"},iC={class:"num"},rC={class:"num"},aC={class:"num"},lC={class:"num"},dC={class:"num"},uC={key:1,class:"ov-performance-empty"},cC={id:"performance-processes",role:"region","aria-label":"Processes"},pC={key:0,class:"ov-performance-message ov-performance-warning",role:"status"},fC={key:1,class:"ov-metrics-scroll",tabindex:"0",role:"region","aria-label":"Process resource metrics, scroll for more columns"},hC={class:"ov-metrics-table"},mC={scope:"row",class:"ov-metric-name"},gC={key:0,class:"ov-metric-warn"},vC={class:"num"},yC={class:"num"},bC={class:"num"},wC={class:"num"},kC={class:"num"},CC={class:"num"},EC={class:"num"},SC={class:"num"},NC={id:"performance-stages",role:"region","aria-label":"Work stages"},RC={key:0,class:"ov-metrics-scroll",tabindex:"0",role:"region","aria-label":"Work stage metrics, scroll for more columns"},AC={class:"ov-metrics-table"},PC={scope:"row",class:"ov-metric-name"},DC={class:"num"},TC={class:"num"},OC={class:"num"},IC={key:1,class:"ov-performance-empty"};function np(e,t){return a(),l("div",Xw,[t[95]||(t[95]=Ce('
Admin \xA0/\xA0 Overview

Overview

Live \xB7 refreshes every 30s
',2)),e.loading?(a(),l("div",Jw,"Loading overview\u2026")):f("v-if",!0),e.error?(a(),l("div",Qw,[t[8]||(t[8]=n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-warning"})],-1)),g(" "+c(e.error),1)])):f("v-if",!0),n("div",Zw,[(a(),l(q,null,Q([{id:"summary",label:"Summary"},{id:"performance",label:"Performance"},{id:"cache",label:"Cache"}],s=>n("button",{type:"button",role:"tab",key:s.id,"aria-selected":e.ovView===s.id?"true":"false",class:A({active:e.ovView===s.id}),onClick:i=>e.setOvView(s.id)},c(s.label),11,xw)),64))]),e.data?D((a(),l("div",ek,[e.data?.system?.memPercent>90||e.data?.system?.diskPercent>90?(a(),l("div",tk,[t[10]||(t[10]=n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-warning"})],-1)),n("span",null,[t[9]||(t[9]=n("b",null,"Server needs attention.",-1)),g(" "+c(e.healthAlert()),1)])])):f("v-if",!0),f(" \u2500\u2500 Top KPI row \u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500 "),n("section",nk,[n("div",sk,[t[11]||(t[11]=n("div",{class:"ov-kpi-label"},"Live repositories",-1)),n("div",ok,c(e.humanNum((e.data?.repos?.statusBreakdown||[]).filter(s=>s._id!=="removed"&&s._id!=="expired").reduce((s,i)=>s+(i.count||0),0))),1),n("div",ik,c(e.humanNum(((e.data?.repos?.statusBreakdown||[]).find(s=>s._id==="removed")||{}).count||0))+" removed \xB7 "+c(e.humanNum(e.data?.repos?.total))+" total",1)]),n("div",rk,[t[12]||(t[12]=n("div",{class:"ov-kpi-label"},"CPU",-1)),n("div",{class:A(["ov-kpi-value",{"ov-val-warn":e.data?.system?.cpuPercent>=75}])},c(e.data?.system?.cpuPercent)+"%",3),n("div",{class:A(["ov-meter",{warn:e.data?.system?.cpuPercent>=75,crit:e.data?.system?.cpuPercent>90}])},[n("span",{style:Ie({width:Math.min(100,e.data?.system?.cpuPercent||0)+"%"})},null,4)],2),n("div",ak,[e.data?.system?.cpuPercent>=75?(a(),l("b",{key:0,class:A(["ov-flag",{critical:e.data?.system?.cpuPercent>90}])},c(e.data?.system?.cpuPercent>90?"Critical":"High")+" \xB7 ",3)):f("v-if",!0),g(c(e.data?.system?.cpuCount)+" cores \xB7 load "+c(e.data?.system?.loadAvg?.[0]?.toFixed(1)),1)])]),n("div",lk,[t[13]||(t[13]=n("div",{class:"ov-kpi-label"},"Memory",-1)),n("div",{class:A(["ov-kpi-value",{"ov-val-warn":e.data?.system?.memPercent>=75}])},c(e.data?.system?.memPercent)+"%",3),n("div",{class:A(["ov-meter",{warn:e.data?.system?.memPercent>=75,crit:e.data?.system?.memPercent>90}])},[n("span",{style:Ie({width:Math.min(100,e.data?.system?.memPercent||0)+"%"})},null,4)],2),n("div",dk,[e.data?.system?.memPercent>=75?(a(),l("b",{key:0,class:A(["ov-flag",{critical:e.data?.system?.memPercent>90}])},c(e.data?.system?.memPercent>90?"Critical":"High")+" \xB7 ",3)):f("v-if",!0),g(c(e.humanBytes(e.data?.system?.memUsed).replace(/\s*GB$/,""))+" / "+c(e.humanBytes(e.data?.system?.memTotal)),1)])]),n("div",uk,[t[14]||(t[14]=n("div",{class:"ov-kpi-label"},"Disk",-1)),n("div",{class:A(["ov-kpi-value",{"ov-val-warn":e.data?.system?.diskPercent>=75}])},c(e.data?.system?.diskPercent)+"%",3),n("div",{class:A(["ov-meter",{warn:e.data?.system?.diskPercent>=75,crit:e.data?.system?.diskPercent>90}])},[n("span",{style:Ie({width:Math.min(100,e.data?.system?.diskPercent||0)+"%"})},null,4)],2),n("div",ck,[e.data?.system?.diskPercent>=75?(a(),l("b",{key:0,class:A(["ov-flag",{critical:e.data?.system?.diskPercent>90}])},c(e.data?.system?.diskPercent>90?"Critical":"High")+" \xB7 ",3)):f("v-if",!0),g(c(e.humanBytes(e.data?.system?.diskUsed).replace(/\s*GB$/,""))+" / "+c(e.humanBytes(e.data?.system?.diskTotal)),1),e.data?.system?.diskMount&&e.data.system.diskMount!=="/"?(a(),l(q,{key:1},[g(" \xB7 "+c(e.data?.system?.diskMount),1)],64)):f("v-if",!0)])]),n("div",pk,[t[15]||(t[15]=n("div",{class:"ov-kpi-label"},"Uptime",-1)),n("div",fk,c(e.humanDuration(e.data?.system?.uptime)),1),n("div",hk,c(e.data?.system?.nodeVersion)+" \xB7 "+c(e.data?.system?.platform),1)])]),f(" \u2500\u2500 Daily activity highlights \u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500 "),n("section",mk,[n("div",gk,[t[16]||(t[16]=n("div",{class:"ov-daily-label"},"New repos today",-1)),n("div",vk,c(e.fmt?.number(e.data?.daily?.today?.repositories||0)),1),t[17]||(t[17]=n("div",{class:"ov-daily-sub"},"so far today",-1))]),n("div",yk,[t[18]||(t[18]=n("div",{class:"ov-daily-label"},"New users today",-1)),n("div",bk,c(e.fmt?.number(e.data?.daily?.today?.users||0)),1),n("div",wk,c(e.fmt?.number(e.data?.users?.total))+" total \xB7 +"+c(e.fmt?.number(e.usersGained()))+" in 30 days",1)]),n("div",kk,[t[19]||(t[19]=n("div",{class:"ov-daily-label"},"Page views today",-1)),n("div",Ck,c(e.fmt?.number(e.data?.daily?.today?.pageViews||0)),1),t[20]||(t[20]=n("div",{class:"ov-daily-sub"},"so far today",-1))])]),f(" \u2500\u2500 Daily charts \u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500 "),n("section",{class:A(["ov-chart-row",{"is-three":e.usersTiny()}])},[n("div",Ek,[n("div",Sk,[t[23]||(t[23]=n("span",{class:"ov-chart-title"},"Daily page views \xB7 30d",-1)),n("span",Nk,[n("span",Rk,[t[21]||(t[21]=n("span",{class:"ov-dot-legend ov-dot-accent"},null,-1)),g("views/day \xB7 peak "+c(e.fmt?.number(e.historyMax("dailyPageViews"))),1)]),e.historyHasMissing()?(a(),l("span",Ak,[...t[22]||(t[22]=[n("span",{class:"ov-swatch-missing","aria-hidden":"true"},null,-1),g("No data",-1)])])):f("v-if",!0)])]),e.data?.history?.length?(a(),l("div",Pk,[n("div",Dk,[n("span",null,c(e.fmt?.number(e.axisMax("dailyPageViews"))),1),n("span",null,c(e.fmt?.number(e.axisMax("dailyPageViews")/2)),1),t[24]||(t[24]=n("span",null,"0",-1))]),(a(!0),l(q,null,Q(e.data?.history,(s,i)=>(a(),l("div",{class:A(["ov-spark-col has-tip",{"is-missing":s?._empty}]),key:i,"data-tip":s?._empty?e.historyLabel(s)+": no data":e.historyLabel(s)+": +"+e.fmt?.number(s?.dailyPageViews)+(s?.dailyPageViews===1?" view":" views"),"aria-label":s?._empty?e.historyLabel(s)+": no data":e.historyLabel(s)+": +"+e.fmt?.number(s?.dailyPageViews)+(s?.dailyPageViews===1?" view":" views")},[n("span",{class:"ov-spark-fill",style:Ie({height:e.historyBarH(s,"dailyPageViews")+"px"})},null,4)],10,Tk))),128))])):f("v-if",!0),e.data?.history?.length?(a(),l("div",Ok,[n("span",null,c(e.historyLabel(e.data?.history[0])),1),n("span",null,c(e.historyLabel(e.data?.history[Math?.floor(e.data?.history?.length/2)])),1),n("span",null,c(e.historyLabel(e.data?.history[e.data?.history?.length-1])),1)])):f("v-if",!0)]),n("div",Ik,[n("div",Mk,[t[27]||(t[27]=n("span",{class:"ov-chart-title"},"New repos \xB7 30d",-1)),n("span",Vk,[n("span",qk,[t[25]||(t[25]=n("span",{class:"ov-dot-legend ov-dot-ok-fill"},null,-1)),g("repos/day \xB7 peak "+c(e.fmt?.number(e.historyMax("dailyRepositories"))),1)]),e.historyHasMissing()?(a(),l("span",_k,[...t[26]||(t[26]=[n("span",{class:"ov-swatch-missing","aria-hidden":"true"},null,-1),g("No data",-1)])])):f("v-if",!0)])]),e.data?.history?.length?(a(),l("div",Lk,[n("div",$k,[n("span",null,c(e.fmt?.number(e.axisMax("dailyRepositories"))),1),n("span",null,c(e.fmt?.number(e.axisMax("dailyRepositories")/2)),1),t[28]||(t[28]=n("span",null,"0",-1))]),(a(!0),l(q,null,Q(e.data?.history,(s,i)=>(a(),l("div",{class:A(["ov-spark-col has-tip",{"is-missing":s?._empty}]),key:i,"data-tip":s?._empty?e.historyLabel(s)+": no data":e.historyLabel(s)+": +"+e.fmt?.number(s?.dailyRepositories)+(s?.dailyRepositories===1?" repo":" repos"),"aria-label":s?._empty?e.historyLabel(s)+": no data":e.historyLabel(s)+": +"+e.fmt?.number(s?.dailyRepositories)+(s?.dailyRepositories===1?" repo":" repos")},[n("span",{class:"ov-spark-fill ov-spark-fill-alt",style:Ie({height:e.historyBarH(s,"dailyRepositories")+"px"})},null,4)],10,Fk))),128))])):f("v-if",!0),e.data?.history?.length?(a(),l("div",Uk,[n("span",null,c(e.historyLabel(e.data?.history[0])),1),n("span",null,c(e.historyLabel(e.data?.history[Math?.floor(e.data?.history?.length/2)])),1),n("span",null,c(e.historyLabel(e.data?.history[e.data?.history?.length-1])),1)])):f("v-if",!0)]),e.usersTiny()?f("v-if",!0):(a(),l("div",Bk,[n("div",zk,[t[31]||(t[31]=n("span",{class:"ov-chart-title"},"Users \xB7 30d",-1)),n("span",Hk,[n("span",jk,[t[29]||(t[29]=n("span",{class:"ov-dot-legend ov-dot-user-fill"},null,-1)),g("total users \xB7 "+c(e.fmt?.number(e.historyRange("nbUsers").max))+" now \xB7 +"+c(e.fmt?.number(Math.max(0,e.historyRange("nbUsers").max-e.usersFirst())))+" in 30 days",1)]),e.historyHasMissing()?(a(),l("span",Gk,[...t[30]||(t[30]=[n("span",{class:"ov-swatch-missing","aria-hidden":"true"},null,-1),g("No data",-1)])])):f("v-if",!0)])]),e.data?.history?.length?(a(),l("div",Wk,[n("div",Kk,[n("span",null,c(e.fmt?.number(e.userAxis().hi)),1),n("span",null,c(e.fmt?.number((e.userAxis().hi+e.userAxis().lo)/2)),1),n("span",null,c(e.fmt?.number(e.userAxis().lo)),1)]),(a(),l("svg",{class:"ov-step-svg",viewBox:"0 0 "+e.data.history.length+" 140",preserveAspectRatio:"none",role:"img","aria-label":"Total users over 30 days, from "+e.fmt?.number(e.usersFirst())+" to "+e.fmt?.number(e.historyRange("nbUsers").max)},[e.userAxis().lo===0?(a(),l("path",{key:0,class:"ov-step-area",d:e.userStepPath(!0)},null,8,Xk)):f("v-if",!0),n("path",{class:"ov-step-line",d:e.userStepPath(!1),"vector-effect":"non-scaling-stroke"},null,8,Jk)],8,Yk)),e.firstDataIndex()>0?(a(),l("div",{key:0,class:"ov-step-missing",style:Ie({width:e.firstDataIndex()/e.data.history.length*100+"%"})},null,4)):f("v-if",!0)])):f("v-if",!0),e.data?.history?.length?(a(),l("div",Qk,[n("span",null,c(e.historyLabel(e.data?.history[0])),1),n("span",null,c(e.historyLabel(e.data?.history[Math?.floor(e.data?.history?.length/2)])),1),n("span",null,c(e.historyLabel(e.data?.history[e.data?.history?.length-1])),1)])):f("v-if",!0)])),n("div",Zk,[n("div",xk,[t[34]||(t[34]=n("span",{class:"ov-chart-title"},"New users \xB7 30d",-1)),n("span",e0,[n("span",t0,[t[32]||(t[32]=n("span",{class:"ov-dot-legend ov-dot-new-user-fill"},null,-1)),g("users/day \xB7 peak "+c(e.fmt?.number(e.historyMax("dailyUsers"))),1)]),e.historyHasMissing()?(a(),l("span",n0,[...t[33]||(t[33]=[n("span",{class:"ov-swatch-missing","aria-hidden":"true"},null,-1),g("No data",-1)])])):f("v-if",!0)])]),e.data?.history?.length?(a(),l("div",s0,[n("div",o0,[n("span",null,c(e.fmt?.number(e.axisMax("dailyUsers"))),1),n("span",null,c(e.fmt?.number(e.axisMax("dailyUsers")/2)),1),t[35]||(t[35]=n("span",null,"0",-1))]),(a(!0),l(q,null,Q(e.data?.history,(s,i)=>(a(),l("div",{class:A(["ov-spark-col has-tip",{"is-missing":s?._empty}]),key:i,"data-tip":s?._empty?e.historyLabel(s)+": no data":e.historyLabel(s)+": +"+e.fmt?.number(s?.dailyUsers)+(s?.dailyUsers===1?" user":" users"),"aria-label":s?._empty?e.historyLabel(s)+": no data":e.historyLabel(s)+": +"+e.fmt?.number(s?.dailyUsers)+(s?.dailyUsers===1?" user":" users")},[n("span",{class:"ov-spark-fill ov-spark-fill-new-user",style:Ie({height:e.historyBarH(s,"dailyUsers")+"px"})},null,4)],10,i0))),128))])):f("v-if",!0),e.data?.history?.length?(a(),l("div",r0,[n("span",null,c(e.historyLabel(e.data?.history[0])),1),n("span",null,c(e.historyLabel(e.data?.history[Math?.floor(e.data?.history?.length/2)])),1),n("span",null,c(e.historyLabel(e.data?.history[e.data?.history?.length-1])),1)])):f("v-if",!0)])],2),f(" \u2500\u2500 Three-panel row: Status / Errors / Queues \u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500 "),n("section",a0,[f(" Repo status breakdown "),n("div",l0,[n("div",d0,[t[36]||(t[36]=n("span",{class:"ov-panel-title"},"Repo status",-1)),n("span",u0,c(e.fmt?.number(e.data?.repos?.total))+" total",1)]),n("div",c0,[e.barPct("ready")>0?(a(),l("span",{key:0,class:"ov-bar-seg ov-bar-ready",title:"Ready",style:Ie({width:e.barPct("ready")+"%"})},null,4)):f("v-if",!0),e.barPct("preparing")>0?(a(),l("span",{key:1,class:"ov-bar-seg ov-bar-preparing",title:"Preparing",style:Ie({width:e.barPct("preparing")+"%"})},null,4)):f("v-if",!0),e.barPct("error")>0?(a(),l("span",{key:2,class:"ov-bar-seg ov-bar-error",title:"Error",style:Ie({width:e.barPct("error")+"%"})},null,4)):f("v-if",!0),e.barPct("expired")>0?(a(),l("span",{key:3,class:"ov-bar-seg ov-bar-expired",title:"Expiring / expired",style:Ie({width:e.barPct("expired")+"%"})},null,4)):f("v-if",!0),e.barPct("removed")>0?(a(),l("span",{key:4,class:"ov-bar-seg ov-bar-removed",title:"Removing / removed",style:Ie({width:e.barPct("removed")+"%"})},null,4)):f("v-if",!0)]),n("div",p0,[n("a",f0,[t[37]||(t[37]=n("span",{class:"ov-swatch ov-bar-ready"},null,-1)),t[38]||(t[38]=g(" Ready ",-1)),n("span",h0,c(e.fmt?.number(e.statusCount("ready"))),1)]),n("a",m0,[t[39]||(t[39]=n("span",{class:"ov-swatch ov-bar-preparing"},null,-1)),t[40]||(t[40]=g(" Preparing ",-1)),n("span",g0,c(e.fmt?.number(e.statusCount("preparing")+e.statusCount("download"))),1)]),n("a",v0,[t[41]||(t[41]=n("span",{class:"ov-swatch ov-bar-error"},null,-1)),t[42]||(t[42]=g(" Error ",-1)),n("span",y0,c(e.fmt?.number(e.statusCount("error"))),1)]),n("a",b0,[t[43]||(t[43]=n("span",{class:"ov-swatch ov-bar-expired"},null,-1)),t[44]||(t[44]=g(" Expiring / expired ",-1)),n("span",w0,c(e.fmt?.number(e.statusCount("expired")+e.statusCount("expiring"))),1)]),n("a",k0,[t[45]||(t[45]=n("span",{class:"ov-swatch ov-bar-removed"},null,-1)),t[46]||(t[46]=g(" Removing / removed ",-1)),n("span",C0,c(e.fmt?.number(e.statusCount("removed")+e.statusCount("removing"))),1)])])]),f(" Error breakdown "),n("div",E0,[n("div",S0,[t[47]||(t[47]=n("span",{class:"ov-panel-title"},"Errors \xB7 24h",-1)),n("span",N0,c(e.fmt?.number(e.realErrors()))+" "+c(e.realErrors()===1?"error":"errors"),1)]),n("div",R0,[n("div",A0,[t[48]||(t[48]=n("span",{class:"ov-ebar-label"},"Error",-1)),n("span",P0,[n("span",{class:"ov-ebar-fill ov-ebar-error",style:Ie({width:e.errPct("error")+"%"})},null,4)]),n("span",D0,c(e.data?.errors?.severity?.error),1)]),n("div",T0,[t[49]||(t[49]=n("span",{class:"ov-ebar-label"},"Warning",-1)),n("span",O0,[n("span",{class:"ov-ebar-fill ov-ebar-warn",style:Ie({width:e.errPct("warn")+"%"})},null,4)]),n("span",I0,c(e.data?.errors?.severity?.warn),1)]),e.errorHours().length?(a(),l("div",M0,[n("div",V0,[t[52]||(t[52]=n("span",{class:"ov-ehours-key"},[n("span",{class:"ov-ehours-swatch is-error","aria-hidden":"true"}),g("Error")],-1)),t[53]||(t[53]=n("span",{class:"ov-ehours-key"},[n("span",{class:"ov-ehours-swatch is-warn","aria-hidden":"true"}),g("Warning")],-1)),n("span",q0,[t[50]||(t[50]=g("Per hour",-1)),t[51]||(t[51]=n("span",{class:"seg-sep","aria-hidden":"true"},"\xB7",-1)),g("peak "+c(e.fmt?.number(e.errorHoursPeak())),1)])]),n("div",_0,[(a(!0),l(q,null,Q(e.errorHours(),s=>(a(),l("span",{key:s.key,class:A({"is-bad":s.bad,"is-zero":s.zero}),title:s.title},[s.zero?(a(),l("i",$0)):(a(),l(q,{key:1},[s.errPct?(a(),l("i",{key:0,class:"ov-ehours-e",style:Ie({height:s.errPct+"%"})},null,4)):f("v-if",!0),s.warnPct?(a(),l("i",{key:1,class:"ov-ehours-w",style:Ie({height:s.warnPct+"%"})},null,4)):f("v-if",!0)],64))],10,L0))),128))]),t[54]||(t[54]=n("div",{class:"ov-ehours-x"},[n("span",null,"24h ago"),n("span",null,"now")],-1))])):f("v-if",!0),n("p",F0,"Info "+c(e.fmt?.number(e.data?.errors?.severity?.info||0))+" \xB7 logged, not counted as errors",1)]),e.data?.repos?.recentErrors24h?(a(),l("div",U0,[n("a",B0,c(e.data?.repos?.recentErrors24h)+" repos in error state \u2192",1)])):f("v-if",!0)]),f(" Top routes / queues "),n("div",z0,[t[59]||(t[59]=n("div",{class:"ov-panel-head"},[n("span",{class:"ov-panel-title"},"Queues"),n("span",{class:"ov-panel-meta"},"by state")],-1)),n("div",H0,[t[58]||(t[58]=Ce('
QueueActiveWaitFailed
',1)),n("a",j0,[t[55]||(t[55]=n("span",{class:"ov-route-name"},"Download",-1)),n("span",G0,c(e.data?.queues?.download?.active),1),n("span",W0,c(e.data?.queues?.download?.waiting),1),n("span",{class:A(["ov-route-n ov-route-lat",{"ov-n-bad":e.data?.queues?.download?.failed>0}])},c(e.data?.queues?.download?.failed),3)]),n("a",K0,[t[56]||(t[56]=n("span",{class:"ov-route-name"},"Remove",-1)),n("span",Y0,c(e.data?.queues?.remove?.active),1),n("span",X0,c(e.data?.queues?.remove?.waiting),1),n("span",{class:A(["ov-route-n ov-route-lat",{"ov-n-bad":e.data?.queues?.remove?.failed>0}])},c(e.data?.queues?.remove?.failed),3)]),n("a",J0,[t[57]||(t[57]=n("span",{class:"ov-route-name"},"Cache cleanup",-1)),n("span",Q0,c(e.data?.queues?.cache?.active),1),n("span",Z0,c(e.data?.queues?.cache?.waiting),1),n("span",{class:A(["ov-route-n ov-route-lat",{"ov-n-bad":e.data?.queues?.cache?.failed>0}])},c(e.data?.queues?.cache?.failed),3)])])])]),f(" \u2500\u2500 Services bar \u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500 "),n("section",x0,[n("div",e2,[t[60]||(t[60]=n("span",{class:"ov-panel-title"},"Services",-1)),n("span",t2,"5 services \xB7 "+c(e.realErrors()>0?"1 needs attention":"all healthy"),1)]),n("div",n2,[n("div",s2,[t[62]||(t[62]=n("span",{class:"ov-svc-dot ov-dot-ok"},null,-1)),n("div",o2,[t[61]||(t[61]=n("span",{class:"ov-svc-name"},"web",-1)),n("span",i2,c(e.data?.system?.nodeVersion)+" \xB7 up "+c(e.humanDuration(e.data?.system?.uptime)),1)])]),n("div",r2,[n("span",{class:A(["ov-svc-dot",e.queueTotal(e.data?.queues?.download)>0?"ov-dot-ok":"ov-dot-idle"])},null,2),n("div",a2,[t[63]||(t[63]=n("span",{class:"ov-svc-name"},"download",-1)),e.queueTotal(e.data?.queues?.download)?(a(),l("span",l2,c(e.queueTotal(e.data?.queues?.download))+" "+c(e.queueTotal(e.data?.queues?.download)===1?"job":"jobs"),1)):f("v-if",!0),e.queueTotal(e.data?.queues?.download)?f("v-if",!0):(a(),l("span",d2,"idle"))])]),n("div",u2,[n("span",{class:A(["ov-svc-dot",e.queueTotal(e.data?.queues?.cache)>0?"ov-dot-ok":"ov-dot-idle"])},null,2),n("div",c2,[t[64]||(t[64]=n("span",{class:"ov-svc-name"},"cache",-1)),e.queueTotal(e.data?.queues?.cache)?(a(),l("span",p2,c(e.queueTotal(e.data?.queues?.cache))+" "+c(e.queueTotal(e.data?.queues?.cache)===1?"job":"jobs"),1)):f("v-if",!0),e.queueTotal(e.data?.queues?.cache)?f("v-if",!0):(a(),l("span",f2,"idle"))])]),n("div",h2,[n("span",{class:A(["ov-svc-dot",e.queueTotal(e.data?.queues?.remove)>0?"ov-dot-ok":"ov-dot-idle"])},null,2),n("div",m2,[t[65]||(t[65]=n("span",{class:"ov-svc-name"},"remove",-1)),e.queueTotal(e.data?.queues?.remove)?(a(),l("span",g2,c(e.queueTotal(e.data?.queues?.remove))+" "+c(e.queueTotal(e.data?.queues?.remove)===1?"job":"jobs"),1)):f("v-if",!0),e.queueTotal(e.data?.queues?.remove)?f("v-if",!0):(a(),l("span",v2,"idle"))])]),n("div",y2,[n("span",{class:A(["ov-svc-dot",e.realErrors()>0?"ov-dot-warn":"ov-dot-ok"]),title:e.realErrors()>0?"Errors in the last 24 hours":"No errors in the last 24 hours"},null,10,b2),n("div",w2,[t[66]||(t[66]=n("span",{class:"ov-svc-name"},"errors",-1)),n("span",k2,c(e.fmt?.number(e.realErrors()))+" / 24h",1)])])])])],512)),[[Z,e.ovView==="summary"]]):f("v-if",!0),D(n("section",C2,[n("div",E2,[t[71]||(t[71]=n("div",null,[n("h2",{class:"ov-panel-title",id:"cache-heading"},"Cache"),n("p",{class:"ov-performance-note"},"Shared storage, repeated reads and anonymization work")],-1)),n("div",S2,[t[69]||(t[69]=n("label",{for:"cache-window"},"Time range",-1)),D(n("select",{id:"cache-window",class:"form-control form-control-sm","onUpdate:modelValue":t[0]||(t[0]=s=>e.cacheMinutes=s),onChange:t[1]||(t[1]=s=>e.loadCache())},[...t[67]||(t[67]=[n("option",{value:15},"Last 15 minutes",-1),n("option",{value:60},"Last hour",-1),n("option",{value:1440},"Last 24 hours",-1),n("option",{value:10080},"Last 7 days",-1)])],544),[[Ut,e.cacheMinutes,void 0,{number:!0}]]),t[70]||(t[70]=n("label",{for:"cache-traffic"},"Traffic",-1)),D(n("select",{id:"cache-traffic",class:"form-control form-control-sm","onUpdate:modelValue":t[2]||(t[2]=s=>e.cacheTraffic=s)},[...t[68]||(t[68]=[Ce('',6)])],512),[[Ut,e.cacheTraffic]])])]),e.cacheError?(a(),l("div",N2,[n("span",null,c(e.cacheError),1),n("button",{type:"button",class:"btn btn-sm",onClick:t[3]||(t[3]=s=>e.loadCache())},"Retry")])):f("v-if",!0),!e.cacheReport&&!e.cacheError?(a(),l("p",R2,"Loading cache monitoring\u2026")):f("v-if",!0),e.cacheReport?.available?(a(),l(q,{key:2},[e.cacheReport.enabled?f("v-if",!0):(a(),l("p",A2,"Shared blob storage is disabled. Inspection and legacy-cache activity are still measured.")),e.cacheReport.filesystemSupported?f("v-if",!0):(a(),l("p",P2,"Shared blobs require a local filesystem. The configured storage continues to use its existing cache.")),e.cacheReport.dropped?(a(),l("p",D2,c(e.cacheReport.dropped)+" telemetry events were dropped. Totals may be incomplete.",1)):f("v-if",!0),e.cacheReport.source?(a(),l("div",T2,[n("table",O2,[t[72]||(t[72]=n("caption",{class:"sr-only"},"Current shared-cache storage and byte budgets",-1)),t[73]||(t[73]=n("thead",null,[n("tr",null,[n("th",{scope:"col"},"Pool"),n("th",{scope:"col",class:"num"},"Allocated / budget"),n("th",{scope:"col",class:"num"},"Reserved for fills"),n("th",{scope:"col",class:"num"},"Original bytes"),n("th",{scope:"col",class:"num"},"Blobs"),n("th",{scope:"col",class:"num"},"Active readers")])],-1)),n("tbody",null,[(a(!0),l(q,null,Q([{name:"Source blobs",data:e.cacheReport.source},{name:"Transformed output",data:e.cacheReport.results}],s=>D((a(),l("tr",{key:s.name},[n("th",I2,c(s.name),1),n("td",{class:A(["num budget-cell",{"is-over":s.data?.budgetBytes&&s.data?.allocatedBytes>s.data?.budgetBytes}]),title:s.data?.budgetBytes?Math.round(100*(s.data?.allocatedBytes||0)/s.data.budgetBytes)+"% of budget":null},[s.data?.budgetBytes&&s.data?.allocatedBytes>s.data?.budgetBytes?(a(),l("span",V2,"Over budget \xB7 ")):f("v-if",!0),g(c(e.humanBytes(s.data?.allocatedBytes))+" / "+c(e.humanBytes(s.data?.budgetBytes)),1),s.data?.budgetBytes?(a(),l("span",q2,[n("i",{style:Ie({width:Math.min(100,Math.round(100*(s.data?.allocatedBytes||0)/s.data.budgetBytes))+"%"})},null,4)])):f("v-if",!0)],10,M2),n("td",_2,c(e.humanBytes(s.data?.reservedBytes)),1),n("td",L2,c(e.humanBytes(s.data?.originalBytes)),1),n("td",$2,c(e.fmt?.number(s.data?.blobs)),1),n("td",F2,c(e.fmt?.number(s.data?.activeReaders)),1)])),[[Z,s.data]])),128))])])])):f("v-if",!0),e.cacheReport.source?(a(),l("dl",U2,[n("div",null,[t[74]||(t[74]=n("dt",null,"Source request hit rate",-1)),n("dd",null,c(e.cacheRate("source","count")),1)]),n("div",null,[t[75]||(t[75]=n("dt",null,"Source byte hit rate",-1)),n("dd",null,c(e.cacheRate("source","bytes")),1)]),n("div",null,[t[76]||(t[76]=n("dt",null,"Decision hit rate",-1)),n("dd",null,c(e.cacheRate("decision","count")),1)])])):f("v-if",!0),t[79]||(t[79]=n("p",{class:"ov-performance-note"},"Reuse counts measure consecutive reads of the same blob within each interval. Codec timings are elapsed stream time, not CPU time; eviction times measure how long a blob was idle. Known monitors are identified by request metadata; other automation may remain in file reads.",-1)),e.cacheRows().length?(a(),l("div",B2,[n("table",z2,[t[77]||(t[77]=n("caption",{class:"sr-only"},"Cache events for the selected time range and traffic",-1)),t[78]||(t[78]=n("thead",null,[n("tr",null,[n("th",{scope:"col"},"Event"),n("th",{scope:"col"},"Traffic"),n("th",{scope:"col",class:"num"},"Count"),n("th",{scope:"col",class:"num"},"Bytes"),n("th",{scope:"col",class:"num"},"Mean measured time"),n("th",{scope:"col",class:"num"},"p95 bound")])],-1)),n("tbody",null,[(a(!0),l(q,null,Q(e.cacheRows(),s=>(a(),l("tr",{key:s.name+":"+s.traffic},[n("th",H2,c(e.cacheEventName(s.name)),1),n("td",j2,c(s.traffic),1),n("td",G2,c(e.fmt?.number(s.count)),1),n("td",W2,c(e.humanBytes(s.bytes)),1),n("td",{class:A(["num",{"ov-muted":!s.ms}])},c(s.ms?e.fmt.duration(s.ms/s.count):"Not timed"),3),n("td",{class:A(["num",{"ov-muted":!s.ms}])},c(e.cacheP95(s)),3)]))),128))])])])):(a(),l("p",K2,"No cache events in this time range for the selected traffic.")),n("p",Y2,"Updated "+c(e.sampleAge(e.cacheReport))+" seconds ago. Minute history is retained for 48 hours; hourly history for 30 days.",1)],64)):f("v-if",!0)],512),[[Z,e.ovView==="cache"]]),D(n("section",X2,[n("div",J2,[t[84]||(t[84]=n("div",null,[n("h2",{class:"ov-panel-title",id:"performance-heading"},"Request performance"),n("p",{class:"ov-performance-note"},"Request latency and process health")],-1)),n("div",Q2,[e.performance?.available?(a(),l(q,{key:0},[t[81]||(t[81]=n("label",{for:"performance-view"},"Show",-1)),D(n("select",{id:"performance-view",class:"form-control form-control-sm","onUpdate:modelValue":t[4]||(t[4]=s=>e.performanceTab=s),"aria-label":"Performance metrics"},[...t[80]||(t[80]=[n("option",{value:"routes"},"Routes",-1),n("option",{value:"processes"},"Processes",-1),n("option",{value:"stages"},"Work stages",-1)])],512),[[Ut,e.performanceTab]])],64)):f("v-if",!0),t[83]||(t[83]=n("label",{for:"performance-window"},"Time range",-1)),D(n("select",{id:"performance-window",class:"form-control form-control-sm","onUpdate:modelValue":t[5]||(t[5]=s=>e.performanceMinutes=s),onChange:t[6]||(t[6]=s=>e.loadPerformance()),"aria-label":"Performance time range"},[...t[82]||(t[82]=[n("option",{value:15},"Last 15 minutes",-1),n("option",{value:60},"Last hour",-1)])],544),[[Ut,e.performanceMinutes,void 0,{number:!0}]])])]),e.performanceError?(a(),l("div",Z2,[t[85]||(t[85]=n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-warning"})],-1)),n("span",null,c(e.performanceError),1),n("button",{type:"button",class:"btn btn-sm",onClick:t[7]||(t[7]=s=>e.loadPerformance())},"Retry")])):f("v-if",!0),!e.performance&&!e.performanceError?(a(),l("p",x2,"Loading performance monitoring\u2026")):f("v-if",!0),e.performance?.available?(a(),l("div",eC,[D(n("div",tC,[e.performance.routes?.length?(a(),l("div",nC,[n("table",sC,[t[86]||(t[86]=n("caption",{class:"sr-only"},"Route latency for the selected time range",-1)),t[87]||(t[87]=n("thead",null,[n("tr",null,[n("th",{scope:"col"},"Route"),n("th",{scope:"col",class:"num"},"Requests"),n("th",{scope:"col",class:"num"},"Average"),n("th",{scope:"col",class:"num"},"First byte p95"),n("th",{scope:"col",class:"num"},"p95"),n("th",{scope:"col",class:"num"},"p99"),n("th",{scope:"col",class:"num"},"Interrupted"),n("th",{scope:"col",class:"num"},"5xx"),n("th",{scope:"col",class:"num"},"Slow")])],-1)),n("tbody",null,[(a(!0),l(q,null,Q(e.performance.routes,s=>(a(),l("tr",{key:s.service+s.method+s.route},[n("th",oC,[n("span",null,c(s.route),1),n("small",null,c(s.service)+" \xB7 "+c(s.method),1)]),n("td",iC,c(e.fmt.number(s.count)),1),n("td",rC,c(e.formatMs(s.avgMs)),1),n("td",aC,c(e.firstByteBound(s)),1),n("td",lC,c(e.latencyBound(s,"p95UpperMs")),1),n("td",dC,c(e.latencyBound(s,"p99UpperMs")),1),n("td",{class:A(["num",{"ov-metric-warn":s.aborted>0}])},c(e.fmt.number(s.aborted)),3),n("td",{class:A(["num",{"ov-metric-bad":s.errors>0}])},c(e.fmt.number(s.errors)),3),n("td",{class:A(["num",{"ov-metric-warn":s.slow>0}])},c(e.fmt.number(s.slow)),3)]))),128))])])])):(a(),l("p",uC,"No recorded requests in this time range yet."))],512),[[Z,e.performanceTab==="routes"]]),D(n("div",cC,[t[91]||(t[91]=n("p",{class:"ov-performance-note"},"API and streamer processes \xB7 latest sample per instance",-1)),e.performance.instances?.length?(a(),l("div",fC,[n("table",hC,[t[89]||(t[89]=n("caption",{class:"sr-only"},"API and streamer process resource usage",-1)),t[90]||(t[90]=n("thead",null,[n("tr",null,[n("th",{scope:"col"},"Process"),n("th",{scope:"col",class:"num"},"RSS / limit"),n("th",{scope:"col",class:"num"},"CPU"),n("th",{scope:"col",class:"num"},"Event loop p95"),n("th",{scope:"col",class:"num"},"Active requests"),n("th",{scope:"col",class:"num"},"Sockets / CLOSE_WAIT"),n("th",{scope:"col",class:"num"},"Workers / waiting"),n("th",{scope:"col",class:"num"},"Sample age"),n("th",{scope:"col",class:"num"},"Dropped batches / metrics")])],-1)),n("tbody",null,[(a(!0),l(q,null,Q(e.performance.instances,s=>(a(),l("tr",{key:s.instance,class:A({"ov-metric-warning-row":e.performanceWarning(s)})},[n("th",mC,[n("span",null,c(s.instance),1),e.performanceWarning(s)?(a(),l("small",gC,[...t[88]||(t[88]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-warning"})],-1),g(" Needs attention",-1)])])):f("v-if",!0)]),n("td",vC,[g(c(e.humanBytes(s.memory.rss))+" / "+c(e.humanBytes(s.memoryLimitBytes)),1),n("small",null,"Peak "+c(e.humanBytes(e.peakRss(s))),1)]),n("td",yC,c(s.cpuPercent==null?"Unavailable":s.cpuPercent.toFixed(1)+"%"),1),n("td",bC,c(s.eventLoop?.p95Ms==null?"Not applicable":e.fmt.duration(s.eventLoop.p95Ms)),1),n("td",wC,c(s.activeRequests),1),n("td",kC,c(s.sockets?.descriptors??"Unavailable")+" / "+c(s.sockets?.closeWait??"Unavailable"),1),n("td",CC,c(s.workers?.running??0)+" / "+c(s.workers?.waiting??0),1),n("td",EC,c(e.sampleAge(s))+" s",1),n("td",SC,c(s.droppedBatches)+" / "+c(s.droppedMetrics),1)],2))),128))])])])):(a(),l("div",pC,"No recent process samples. Monitoring coverage is incomplete."))],512),[[Z,e.performanceTab==="processes"]]),D(n("div",NC,[e.performance.stages?.some(s=>s.metric!=="first_byte")?(a(),l("div",RC,[n("table",AC,[t[92]||(t[92]=n("caption",{class:"sr-only"},"Work stages and cache results",-1)),t[93]||(t[93]=n("thead",null,[n("tr",null,[n("th",{scope:"col"},"Work stage"),n("th",{scope:"col",class:"num"},"Samples"),n("th",{scope:"col",class:"num"},"Average"),n("th",{scope:"col",class:"num"},"p95")])],-1)),n("tbody",null,[(a(!0),l(q,null,Q(e.performance.stages.filter(s=>s.metric!=="first_byte"),s=>(a(),l("tr",{key:s.service+s.metric},[n("th",PC,[n("span",null,c(s.metric),1),n("small",null,c(s.service),1)]),n("td",DC,c(e.fmt.number(s.count)),1),n("td",TC,c(e.formatMs(s.avgMs)),1),n("td",OC,c(e.latencyBound(s,"p95UpperMs")),1)]))),128))])])])):(a(),l("p",IC,"No recorded work stages or cache results in this time range yet."))],512),[[Z,e.performanceTab==="stages"]]),t[94]||(t[94]=n("details",{class:"ov-performance-help"},[n("summary",null,"How to read these metrics"),n("p",null,"Latency includes upstream waits and response transfer. Percentiles show histogram bucket upper bounds, not exact timings. Process rows marked \u201CNeeds attention\u201D have stale samples, dropped monitoring data, CLOSE_WAIT sockets, high event loop delay, or high memory usage.")],-1))])):f("v-if",!0)],512),[[Z,e.ovView==="performance"]])])}var MC={class:"container paper-page admin-page"},VC={class:"q-header"},qC={class:"q-header-actions"},_C={class:"q-cards"},LC=["aria-pressed","onKeydown","onClick"],$C={class:"q-card-head"},FC=["title"],UC=["textContent"],BC=["textContent"],zC={class:"q-card-sub"},HC={class:"q-card-failed"},jC={key:0,class:"q-card-bar"},GC={key:0,class:"q-detail"},WC={class:"q-throughput"},KC={class:"q-range-btns"},YC={class:"q-section-label"},XC={key:0,class:"q-section-right"},JC={class:"q-chart-wrap"},QC={key:0,class:"q-chart-empty"},ZC={class:"q-stats-panel"},xC={class:"q-section-label"},eE={class:"q-stats-grid"},tE={class:"q-stat"},nE=["textContent"],sE={class:"q-stat"},oE=["textContent"],iE={class:"q-stat"},rE=["textContent"],aE={class:"q-stat"},lE=["textContent"],dE={class:"q-stat"},uE=["textContent"],cE={class:"q-stat"},pE=["textContent"],fE={class:"q-stats-actions"},hE=["disabled"],mE={class:"q-danger-group"},gE={class:"q-jobs"},vE={class:"q-jobs-header"},yE={class:"q-section-label"},bE={class:"seg-filter",role:"radiogroup","aria-label":"Filter jobs by state"},wE=["aria-checked"],kE={class:"count"},CE=["aria-checked"],EE={class:"count"},SE=["aria-checked"],NE={class:"count"},RE=["aria-checked"],AE={class:"count"},PE=["aria-checked"],DE={class:"count"},TE=["aria-checked"],OE={class:"count"},IE={class:"q-search-row"},ME={type:"search",class:"form-control",placeholder:"Search by job/repo id\u2026",autocomplete:"off"},VE={class:"q-auto-refresh"},qE={type:"checkbox"},_E={key:0,class:"q-table"},LE=["onClick"],$E={class:"q-cell-state"},FE=["textContent"],UE=["textContent"],BE=["title"],zE=["textContent","href"],HE=["title","textContent"],jE=["textContent"],GE=["textContent"],WE={class:"q-cell-progress"},KE=["aria-label"],YE=["textContent"],XE={class:"q-cell-actions"},JE=["onClick"],QE=["onClick"],ZE={key:0,class:"q-detail-row"},xE={colspan:"7"},eS={class:"q-job-detail"},tS={class:"q-job-detail-grid"},nS={class:"q-job-detail-item"},sS={class:"q-job-detail-value"},oS=["textContent","href"],iS={class:"q-job-detail-item"},rS={class:"q-job-detail-value"},aS=["textContent"],lS={key:0,class:"q-job-detail-item"},dS=["textContent"],uS={key:1,class:"q-job-detail-item"},cS=["textContent"],pS={key:2,class:"q-job-detail-item"},fS={class:"q-job-detail-value"},hS={key:3,class:"q-job-detail-item"},mS=["textContent"],gS={key:4,class:"q-job-detail-item"},vS=["textContent"],yS={key:5,class:"q-job-detail-item"},bS=["textContent"],wS={key:6,class:"q-job-detail-item"},kS=["textContent"],CS={key:7,class:"q-job-detail-item"},ES=["textContent"],SS={key:0,class:"q-job-detail-error"},NS=["textContent"],RS={key:1},AS=["textContent"],PS={class:"q-job-detail-actions"},DS=["onClick"],TS=["onClick"],OS=["href"],IS={key:1,class:"paper-table-empty",style:{border:"1px solid var(--border-color)","border-radius":"10px",background:"var(--paper-card)"}},MS={key:0},VS={key:1};function sp(e,t){let s=Pe("field");return a(),l("div",MC,[t[71]||(t[71]=n("div",{class:"paper-crumbs"},[g("Admin \xA0/\xA0 "),n("span",{class:"here"},"Queues")],-1)),n("div",VC,[t[18]||(t[18]=n("h1",{class:"paper-page-title"},"Queues",-1)),n("div",qC,[n("button",{class:"btn btn-sm",onClick:t[0]||(t[0]=i=>e.pauseAll())},"Pause all queues")])]),t[72]||(t[72]=Ce('',1)),f(" Queue overview cards "),n("div",_C,[(a(!0),l(q,null,Q(e.queueList,(i,o)=>(a(),l("div",{class:A(["q-card",{selected:e.selectedQueue==i?.key,paused:i?.paused}]),role:"button",tabindex:"0","aria-pressed":e.selectedQueue===i.key,onKeydown:[kt(ae(r=>e.selectQueue(i.key),["prevent"]),["enter"]),kt(ae(r=>e.selectQueue(i.key),["prevent"]),["space"])],onClick:r=>e.selectQueue(i.key)},[n("div",$C,[n("span",{class:A(["q-dot",{"q-dot-red":i?.paused||i?.counts?.failed>0,"q-dot-idle":!i?.counts?.active&&!i?.counts?.waiting}]),title:i?.paused?"Paused":i?.counts?.failed>0?i.counts.failed+" failed jobs":i?.counts?.active||i?.counts?.waiting?"Running":"Idle"},null,10,FC),n("span",{class:"q-card-name",textContent:c(i?.label)},null,8,UC)]),n("div",{class:"q-card-count",textContent:c((i?.counts?.waiting||0)+(i?.counts?.active||0)+(i?.counts?.delayed||0))},null,8,BC),n("div",zC,[n("span",null,[g("waiting \xB7 "+c(i?.counts?.active||0)+" active",1),i?.counts?.failed?(a(),l(q,{key:0},[t[19]||(t[19]=g(" \xB7 ",-1)),n("b",HC,c(i.counts.failed)+" failed",1)],64)):f("v-if",!0),i?.paused?(a(),l(q,{key:1},[t[20]||(t[20]=g(" \xB7 ",-1)),t[21]||(t[21]=n("b",{class:"q-card-failed"},"paused",-1))],64)):f("v-if",!0)]),i?.counts?.active?(a(),l("div",jC,[n("div",{class:"q-card-bar-fill",style:Ie({width:i?.counts?.active/((i?.counts?.waiting||0)+(i?.counts?.active||0)+(i?.counts?.delayed||0)||1)*100+"%"})},null,4)])):f("v-if",!0)])],42,LC))),256))]),f(" Detail: throughput chart + stats panel "),e.selectedStats?(a(),l("div",GC,[n("div",WC,[n("div",KC,[n("button",{class:A(["btn btn-sm",{active:e.range=="1h"}]),onClick:t[1]||(t[1]=i=>e.setRange("1h"))},"1h",2),n("button",{class:A(["btn btn-sm",{active:e.range=="6h"}]),onClick:t[2]||(t[2]=i=>e.setRange("6h"))},"6h",2),n("button",{class:A(["btn btn-sm",{active:e.range=="24h"}]),onClick:t[3]||(t[3]=i=>e.setRange("24h"))},"24h",2),n("button",{class:A(["btn btn-sm",{active:e.range=="7d"}]),onClick:t[4]||(t[4]=i=>e.setRange("7d"))},"7d",2)]),n("div",YC,[g("Throughput \xB7 "+c(e.selectedQueue)+" ",1),(e.selectedStats?.completed24h||0)+(e.selectedStats?.failed24h||0)>0?(a(),l("span",XC,[t[23]||(t[23]=n("span",{class:"q-legend-completed"},"\u25CF",-1)),t[24]||(t[24]=g(" Completed ",-1)),t[25]||(t[25]=n("span",{class:"q-legend-failed"},"\u25CF",-1)),t[26]||(t[26]=g(" Failed ",-1)),(e.selectedStats?.completed24h||0)+(e.selectedStats?.failed24h||0)>0?(a(),l(q,{key:0},[t[22]||(t[22]=n("span",{class:"q-legend-exec","aria-hidden":"true"},null,-1)),g(" Avg time \xB7 "+c(e.range),1)],64)):f("v-if",!0)])):f("v-if",!0)]),n("div",JC,[t[28]||(t[28]=n("canvas",{id:"q-throughput-chart",height:"180"},null,-1)),(e.selectedStats?.completed24h||0)+(e.selectedStats?.failed24h||0)===0?(a(),l("div",QC,[...t[27]||(t[27]=[n("strong",null,"No jobs processed in this window",-1),n("span",null,"Completed and failed jobs will chart here.",-1)])])):f("v-if",!0),t[29]||(t[29]=n("div",{id:"q-chart-tooltip",class:"q-chart-tooltip",style:{display:"none"}},null,-1)),t[30]||(t[30]=n("div",{id:"q-chart-crosshair",class:"q-chart-crosshair",style:{display:"none"}},null,-1))])]),n("div",ZC,[n("div",xC,"Stats \xB7 "+c(e.selectedQueue),1),n("div",eE,[n("div",tE,[t[31]||(t[31]=n("div",{class:"q-stat-label"},"Waiting",-1)),n("div",{class:"q-stat-value",textContent:c(e.selectedStats?.counts?.waiting||0)},null,8,nE)]),n("div",sE,[t[32]||(t[32]=n("div",{class:"q-stat-label"},"Active",-1)),n("div",{class:"q-stat-value",textContent:c(e.selectedStats?.counts?.active||0)},null,8,oE)]),n("div",iE,[t[33]||(t[33]=n("div",{class:"q-stat-label"},"Completed (24h)",-1)),n("div",{class:"q-stat-value",textContent:c(e.fmt?.number(e.selectedStats?.completed24h))},null,8,rE)]),n("div",aE,[t[34]||(t[34]=n("div",{class:"q-stat-label"},"Failed (24h)",-1)),n("div",{class:"q-stat-value",textContent:c(e.selectedStats?.failed24h||0)},null,8,lE)]),n("div",dE,[t[35]||(t[35]=n("div",{class:"q-stat-label"},"Delayed",-1)),n("div",{class:"q-stat-value",textContent:c(e.selectedStats?.counts?.delayed||0)},null,8,uE)]),n("div",cE,[t[36]||(t[36]=n("div",{class:"q-stat-label"},"Workers",-1)),n("div",{class:"q-stat-value",textContent:c(e.selectedStats?.workers||0)},null,8,pE)])]),n("div",fE,[n("button",{class:"btn btn-sm",onClick:t[5]||(t[5]=i=>e.togglePause())},c(e.selectedStats?.paused?"Resume "+e.selectedQueue:"Pause "+e.selectedQueue),1),n("button",{class:"btn btn-sm",onClick:t[6]||(t[6]=i=>e.retryFailed()),disabled:!e.selectedStats?.counts?.failed},"Retry failed",8,hE),n("span",mE,[n("button",{class:"btn btn-sm btn-outline-danger",onClick:t[7]||(t[7]=i=>e.drainSelected())},"Drain"),n("button",{class:"btn btn-sm btn-outline-danger",onClick:t[8]||(t[8]=i=>e.emptyQueue())},"Empty")])])])])):f("v-if",!0),e.actionError?(a(),l("div",{key:1,class:"q-toast-error",onClick:t[9]||(t[9]=i=>e.actionError=null)},[t[37]||(t[37]=n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-info"})],-1)),g(" "+c(e.actionError),1)])):f("v-if",!0),f(" Jobs table "),n("div",gE,[n("div",vE,[n("div",yE,"All jobs \xB7 "+c(e.selectedQueue),1),n("div",bE,[n("button",{type:"button",role:"radio",class:A(["seg-chip",{active:e.segView()==="all"}]),"aria-checked":e.segView()==="all",onClick:t[10]||(t[10]=i=>e.setSegView("all"))},[t[38]||(t[38]=g("All ",-1)),n("span",kE,c(e.fmt?.number(e.segCount("all"))),1)],10,wE),n("button",{type:"button",role:"radio",class:A(["seg-chip",{active:e.segView()==="active","is-empty":!e.segCount("active")}]),"aria-checked":e.segView()==="active",onClick:t[11]||(t[11]=i=>e.setSegView("active"))},[t[39]||(t[39]=n("span",{class:"seg-dot ok","aria-hidden":"true"},null,-1)),t[40]||(t[40]=g("Active ",-1)),n("span",EE,c(e.fmt?.number(e.segCount("active"))),1)],10,CE),n("button",{type:"button",role:"radio",class:A(["seg-chip",{active:e.segView()==="waiting","is-empty":!e.segCount("waiting")}]),"aria-checked":e.segView()==="waiting",onClick:t[12]||(t[12]=i=>e.setSegView("waiting"))},[t[41]||(t[41]=n("span",{class:"seg-dot warn","aria-hidden":"true"},null,-1)),t[42]||(t[42]=g("Waiting ",-1)),n("span",NE,c(e.fmt?.number(e.segCount("waiting"))),1)],10,SE),n("button",{type:"button",role:"radio",class:A(["seg-chip",{active:e.segView()==="delayed","is-empty":!e.segCount("delayed")}]),"aria-checked":e.segView()==="delayed",onClick:t[13]||(t[13]=i=>e.setSegView("delayed"))},[t[43]||(t[43]=n("span",{class:"seg-dot warn","aria-hidden":"true"},null,-1)),t[44]||(t[44]=g("Delayed ",-1)),n("span",AE,c(e.fmt?.number(e.segCount("delayed"))),1)],10,RE),n("button",{type:"button",role:"radio",class:A(["seg-chip",{active:e.segView()==="failed","is-empty":!e.segCount("failed")}]),"aria-checked":e.segView()==="failed",onClick:t[14]||(t[14]=i=>e.setSegView("failed"))},[t[45]||(t[45]=n("span",{class:"seg-dot bad","aria-hidden":"true"},null,-1)),t[46]||(t[46]=g("Failed ",-1)),n("span",DE,c(e.fmt?.number(e.segCount("failed"))),1)],10,PE),n("button",{type:"button",role:"radio",class:A(["seg-chip",{active:e.segView()==="completed","is-empty":!e.segCount("completed")}]),"aria-checked":e.segView()==="completed",onClick:t[15]||(t[15]=i=>e.setSegView("completed"))},[t[47]||(t[47]=n("span",{class:"seg-dot done","aria-hidden":"true"},null,-1)),t[48]||(t[48]=g("Completed ",-1)),n("span",OE,c(e.fmt?.number(e.segCount("completed"))),1)],10,TE)])]),n("div",IE,[D(n("input",ME,null,512),[[s,{state:e.viewState,set:i=>{e.query.search=i},value:e.query?.search,form:null,options:{}}]]),n("label",VE,[D(n("input",qE,null,512),[[s,{state:e.viewState,set:i=>{e.query.autoRefresh=i},value:e.query?.autoRefresh,form:null,options:{}}]]),t[49]||(t[49]=n("span",{class:"auto-refresh-label"},"Auto-refresh",-1))]),n("button",{class:"btn btn-sm btn-icon",type:"button",title:"Refresh now",onClick:t[16]||(t[16]=i=>e.refreshNow()),"aria-label":"Refresh"},[...t[50]||(t[50]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-refresh"})],-1)])])]),e.filteredJobs().length>0?(a(),l("table",_E,[t[69]||(t[69]=n("thead",null,[n("tr",null,[n("th",null,"State"),n("th",null,"Job"),n("th",null,"Detail"),n("th",null,"Attempts"),n("th",{class:"q-th-num"},"Duration"),n("th",null,"Progress"),n("th")])],-1)),(a(!0),l(q,null,Q(e.filteredJobs(),(i,o)=>(a(),l("tbody",null,[n("tr",{style:{cursor:"pointer"},class:A({"q-row-failed":i?._state=="failed","q-row-expanded":e.expanded[i?.id]}),onClick:r=>e.toggleJob(i)},[n("td",$E,[n("span",{textContent:c(i?._state),class:A("q-state-badge q-state-"+i?._state)},null,10,FE),i?._state=="delayed"&&i?.delayUntil?(a(),l("span",{key:0,class:"q-delay-hint",textContent:c(e.delayCountdown(i?.delayUntil))},null,8,UE)):f("v-if",!0)]),n("td",{class:"q-cell-id",title:"job:"+i?.id+(i?.name&&i?.name!==i?.id?" \xB7 "+i.name:"")+(i?.data?.repoId&&i?.data?.repoId!==i?.id?" \xB7 "+i.data.repoId:"")},[(a(),l("svg",{class:A(["ui-icon q-chevron",{"q-chevron-open":e.expanded[i?.id]}]),"aria-hidden":"true"},[...t[51]||(t[51]=[n("use",{href:"#ui-icon-chevron-right"},null,-1)])],2)),n("a",{target:"_blank",class:"q-job-link",textContent:c(i?.data?.repoId||i?.id),onClick:t[17]||(t[17]=r=>r.stopPropagation()),href:e.safeUrl("/r/"+(i?.data?.repoId||i?.id))},null,8,zE)],8,BE),n("td",{class:A(["q-cell-detail",{"is-error":i?._state=="failed"}]),title:i?._state=="failed"?i?.failedReason:"",textContent:c(e.jobDetail(i))},null,10,HE),n("td",{class:"q-cell-num",textContent:c(i?.attemptsMade||1)},null,8,jE),n("td",{class:"q-cell-num q-cell-duration",textContent:c(e.jobDuration(i))},null,8,GE),n("td",WE,[n("div",{class:A(["q-progress-wrap",{"is-indeterminate":e.jobProgressPct(i)===null}]),"aria-label":e.jobProgressPct(i)===null?"Progress not reported":e.jobProgressPct(i)+"% done"},[n("div",{class:"q-progress-bar",style:Ie({"--pct":(e.jobProgressPct(i)||0)+"%"})},null,4),n("span",{class:"q-progress-label",textContent:c(e.jobProgressPct(i)===null?"\u2014":e.jobProgressPct(i)+"%")},null,8,YE)],10,KE)]),n("td",XE,[i?._state=="failed"?(a(),l("button",{key:0,class:"btn btn-sm btn-icon",title:"Retry",onClick:r=>{e.retryJob(i),r.stopPropagation()},"aria-label":"Retry job"},[...t[52]||(t[52]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-refresh"})],-1)])],8,JE)):f("v-if",!0),n("button",{class:"btn btn-sm btn-icon",title:"Remove","aria-label":"Remove job",onClick:r=>{e.removeJob(i),r.stopPropagation()}},[...t[53]||(t[53]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-trash"})],-1)])],8,QE)])],10,LE),e.expanded[i?.id]?(a(),l("tr",ZE,[n("td",xE,[n("div",eS,[n("div",tS,[n("div",nS,[t[54]||(t[54]=n("span",{class:"q-job-detail-label"},"Job id",-1)),n("span",sS,[n("a",{target:"_blank",textContent:c(i?.id),href:e.safeUrl("/r/"+i?.id)},null,8,oS)])]),n("div",iS,[t[55]||(t[55]=n("span",{class:"q-job-detail-label"},"State",-1)),n("span",rS,[n("span",{textContent:c(i?._state),class:A("q-state-badge q-state-"+i?._state)},null,10,aS)])]),i?.data?.repoId?(a(),l("div",lS,[t[56]||(t[56]=n("span",{class:"q-job-detail-label"},"Repo ID",-1)),n("span",{class:"q-job-detail-value",textContent:c(i?.data?.repoId)},null,8,dS)])):f("v-if",!0),i?.timestamp?(a(),l("div",uS,[t[57]||(t[57]=n("span",{class:"q-job-detail-label"},"Created",-1)),n("span",{class:"q-job-detail-value",textContent:c(e.humanTime(i?.timestamp))},null,8,cS)])):f("v-if",!0),i?._state=="delayed"&&i?.delayUntil?(a(),l("div",pS,[t[58]||(t[58]=n("span",{class:"q-job-detail-label"},"Retry at",-1)),n("span",fS,c(e.humanTime(i?.delayUntil))+" ("+c(e.delayCountdown(i?.delayUntil))+")",1)])):f("v-if",!0),i?.processedOn?(a(),l("div",hS,[t[59]||(t[59]=n("span",{class:"q-job-detail-label"},"Processed",-1)),n("span",{class:"q-job-detail-value",textContent:c(e.humanTime(i?.processedOn))},null,8,mS)])):f("v-if",!0),i?.finishedOn?(a(),l("div",gS,[t[60]||(t[60]=n("span",{class:"q-job-detail-label"},"Finished",-1)),n("span",{class:"q-job-detail-value",textContent:c(e.humanTime(i?.finishedOn))},null,8,vS)])):f("v-if",!0),i?.attemptsMade?(a(),l("div",yS,[t[61]||(t[61]=n("span",{class:"q-job-detail-label"},"Attempts",-1)),n("span",{class:"q-job-detail-value",textContent:c(i?.attemptsMade)},null,8,bS)])):f("v-if",!0),i?.progress&&i?.progress?.status?(a(),l("div",wS,[t[62]||(t[62]=n("span",{class:"q-job-detail-label"},"Status",-1)),n("span",{class:"q-job-detail-value",textContent:c(i?.progress?.status)},null,8,kS)])):f("v-if",!0),e.jobProgressPct(i)!==null?(a(),l("div",CS,[t[63]||(t[63]=n("span",{class:"q-job-detail-label"},"Progress",-1)),n("span",{class:"q-job-detail-value",textContent:c(e.jobProgressPct(i)+"%")},null,8,ES)])):f("v-if",!0)]),i?.failedReason?(a(),l("div",SS,[t[64]||(t[64]=n("span",{class:"q-job-detail-label"},"Error",-1)),n("div",{class:"q-error-reason",textContent:c(i?.failedReason)},null,8,NS)])):f("v-if",!0),i?.stacktrace?.length?(a(),l("div",RS,[t[65]||(t[65]=n("span",{class:"q-job-detail-label"},"Stacktrace",-1)),(a(!0),l(q,null,Q(i?.stacktrace,(r,d)=>(a(),l("pre",{class:"q-error-stack",key:d},[n("code",{textContent:c(r)},null,8,AS)]))),128))])):f("v-if",!0),n("div",PS,[i?._state=="failed"?(a(),l("button",{key:0,class:"btn btn-sm",onClick:r=>e.retryJob(i)},[...t[66]||(t[66]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-refresh"})],-1),g(" Retry",-1)])],8,DS)):f("v-if",!0),n("button",{class:"btn btn-sm",onClick:r=>e.removeJob(i)},[...t[67]||(t[67]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-trash"})],-1),g(" Remove",-1)])],8,TS),n("a",{class:"btn btn-sm",target:"_blank",href:e.safeUrl("/r/"+i?.id)},[...t[68]||(t[68]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-external-link"})],-1),g(" View repo",-1)])],8,OS)])])])])):f("v-if",!0)]))),256))])):f("v-if",!0),e.filteredJobs().length==0?(a(),l("div",IS,[t[70]||(t[70]=n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-check-circle"})],-1)),e.query?.search?f("v-if",!0):(a(),l("span",MS,"No jobs in the "+c(e.selectedQueue)+" queue.",1)),e.query?.search?(a(),l("span",VS,"No jobs match the current filters.")):f("v-if",!0)])):f("v-if",!0)])])}var qS={class:"container paper-page admin-page"},_S={class:"seg-bar"},LS={class:"seg-filter",role:"radiogroup","aria-label":"Filter by status"},$S=["aria-checked"],FS={class:"count"},US=["aria-checked"],BS={class:"count"},zS=["aria-checked"],HS={class:"count"},jS=["aria-checked"],GS={class:"count"},WS=["aria-checked"],KS={class:"count"},YS=["aria-checked"],XS={class:"count"},JS={class:"seg-countline",role:"status"},QS={class:"seg-meta"},ZS={key:0,class:"alert alert-danger",style:{margin:"8px 0"}},xS={class:"w-100 admin-filter-toolbar","aria-label":"Repositories","accept-charset":"UTF-8"},eN=["aria-expanded"],tN={class:"search-wrap"},nN={type:"search",class:"form-control","aria-label":"Search repositories",placeholder:"Search repositories\u2026",autocomplete:"off"},sN={key:0,class:"admin-search-hint"},oN={class:"admin-filter-inline"},iN={type:"text",class:"form-control form-control-sm",placeholder:"username"},rN={class:"admin-filter-inline"},aN={type:"text",class:"form-control form-control-sm",placeholder:"ID"},lN={key:0,class:"admin-filter-inline","aria-label":"Pagination"},dN=["disabled"],uN={style:{"font-family":"var(--font-mono)","font-size":"12px",color:"var(--ink-muted)"}},cN=["disabled"],pN={key:0,class:"admin-filter-row"},fN={class:"admin-active-chips"},hN={class:"key"},mN=["onClick"],gN={key:1,class:"bulk-bar"},vN={class:"paper-table paper-table-repos has-bulk w-100",role:"table","aria-label":"Repositories"},yN={class:"paper-table-head",role:"row"},bN={role:"columnheader",style:{width:"28px"}},wN=["checked"],kN={role:"columnheader"},CN={role:"columnheader"},EN={role:"columnheader",class:"num"},SN={role:"columnheader"},NN={role:"cell",style:{width:"28px"}},RN={type:"checkbox","aria-label":"Select repository"},AN={class:"cell-anon",role:"cell"},PN={class:"anon-text"},DN=["textContent","href"],TN=["title"],ON=["href"],IN=["textContent"],MN=["textContent"],VN=["data-meta-label"],qN=["title","textContent","href"],_N=["data-meta-label"],LN=["textContent","href"],$N=["data-meta-label"],FN={key:3,class:"meta-item"},UN={class:"meta-item"},BN={class:"cell-status",role:"cell"},zN={class:"status-line"},HN=["textContent"],jN=["textContent","title"],GN=["data-unit"],WN=["textContent"],KN={class:"cell-expires",role:"cell"},YN=["textContent"],XN={class:"cell-actions",role:"cell"},JN={class:"dropdown"},QN={class:"dropdown-menu dropdown-menu-right"},ZN=["href"],xN=["href"],eR=["href"],tR=["onClick"],nR=["onClick"],sR=["onClick"],oR=["onClick"],iR=["onClick"],rR=["onClick"],aR={key:0,class:"paper-table-empty"},lR={class:"admin-toolbar",style:{"justify-content":"space-between","border-bottom":"none"}},dR={key:0,class:"pagination-compact"},uR=["disabled"],cR=["max"],pR=["disabled"],fR={class:"admin-filter-inline"},hR={class:"form-control form-control-sm"};function op(e,t){let s=Pe("field"),i=Pe("form");return a(),l("div",qS,[t[80]||(t[80]=Ce('
Admin \xA0/\xA0 Repositories

Repositories

',3)),n("div",_S,[n("div",LS,[n("button",{type:"button",role:"radio",class:A(["seg-chip",{active:e.segView()==="all"}]),"aria-checked":e.segView()==="all",onClick:t[0]||(t[0]=o=>e.setSegView("all"))},[t[21]||(t[21]=g("All ",-1)),n("span",FS,c(e.fmt?.number(e.segCount("all"))),1)],10,$S),n("button",{type:"button",role:"radio",class:A(["seg-chip",{active:e.segView()==="ready","is-empty":!e.segCount("ready")}]),"aria-checked":e.segView()==="ready",onClick:t[1]||(t[1]=o=>e.setSegView("ready"))},[t[22]||(t[22]=n("span",{class:"seg-dot ok","aria-hidden":"true"},null,-1)),t[23]||(t[23]=g("Ready ",-1)),n("span",BS,c(e.fmt?.number(e.segCount("ready"))),1)],10,US),n("button",{type:"button",role:"radio",class:A(["seg-chip",{active:e.segView()==="preparing","is-empty":!e.segCount("preparing")}]),"aria-checked":e.segView()==="preparing",onClick:t[2]||(t[2]=o=>e.setSegView("preparing"))},[t[24]||(t[24]=n("span",{class:"seg-dot warn","aria-hidden":"true"},null,-1)),t[25]||(t[25]=g("Preparing ",-1)),n("span",HS,c(e.fmt?.number(e.segCount("preparing"))),1)],10,zS),n("button",{type:"button",role:"radio",class:A(["seg-chip",{active:e.segView()==="error","is-empty":!e.segCount("error")}]),"aria-checked":e.segView()==="error",onClick:t[3]||(t[3]=o=>e.setSegView("error"))},[t[26]||(t[26]=n("span",{class:"seg-dot bad","aria-hidden":"true"},null,-1)),t[27]||(t[27]=g("Error ",-1)),n("span",GS,c(e.fmt?.number(e.segCount("error"))),1)],10,jS),n("button",{type:"button",role:"radio",class:A(["seg-chip",{active:e.segView()==="expired","is-empty":!e.segCount("expired")}]),"aria-checked":e.segView()==="expired",onClick:t[4]||(t[4]=o=>e.setSegView("expired"))},[t[28]||(t[28]=n("span",{class:"seg-dot off","aria-hidden":"true"},null,-1)),t[29]||(t[29]=g("Expiring / expired ",-1)),n("span",KS,c(e.fmt?.number(e.segCount("expired"))),1)],10,WS),n("button",{type:"button",role:"radio",class:A(["seg-chip",{active:e.segView()==="removed","is-empty":!e.segCount("removed")}]),"aria-checked":e.segView()==="removed",onClick:t[5]||(t[5]=o=>e.setSegView("removed"))},[t[30]||(t[30]=n("span",{class:"seg-dot off","aria-hidden":"true"},null,-1)),t[31]||(t[31]=g("Removing / removed ",-1)),n("span",XS,c(e.fmt?.number(e.segCount("removed"))),1)],10,YS)]),n("p",JS,[n("strong",null,c(e.total>=0?e.fmt.number(e.total):"\u2026"),1),t[32]||(t[32]=g(" shown",-1)),t[33]||(t[33]=n("span",{class:"seg-sep"},"\xB7",-1)),n("span",QS,c(e.fmt?.humanFileSize(e.totalSize))+" on disk",1)])]),e.fetchError?(a(),l("div",ZS,[t[34]||(t[34]=n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-warning"})],-1)),g(" "+c(e.fetchError),1)])):f("v-if",!0),D((a(),l("form",xS,[f(" Row 1: search + scoped inputs + headline actions "),n("button",{type:"button",class:"btn btn-sm admin-filters-toggle",onClick:t[6]||(t[6]=o=>e.filtersOpen=!e.filtersOpen),"aria-expanded":e.filtersOpen?"true":"false"},"Filters",8,eN),n("div",{class:A(["admin-filter-row",{"is-open":e.filtersOpen}])},[n("div",tN,[D(n("input",nN,null,512),[[s,{state:e.viewState,set:o=>{e.query.search=o},value:e.query?.search,form:null,options:{}}]]),e.query?.search?f("v-if",!0):(a(),l("span",sN,"/"))]),n("span",oN,[t[35]||(t[35]=n("label",null,"Owner",-1)),D(n("input",iN,null,512),[[s,{state:e.viewState,set:o=>{e.query.owner=o},value:e.query?.owner,form:null,options:{}}]])]),n("span",rN,[t[36]||(t[36]=n("label",null,"Conference",-1)),D(n("input",aN,null,512),[[s,{state:e.viewState,set:o=>{e.query.conference=o},value:e.query?.conference,form:null,options:{}}]])]),t[40]||(t[40]=n("span",{class:"admin-filter-spacer"},null,-1)),n("button",{class:"btn btn-sm",type:"button",title:"Export current view to CSV",onClick:t[7]||(t[7]=o=>e.exportCsv())},[...t[37]||(t[37]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-export"})],-1),g(" Export",-1)])]),e.totalPage>1?(a(),l("span",lN,[n("button",{class:"btn btn-sm btn-icon",type:"button",onClick:t[8]||(t[8]=o=>e.query.page=Math.max(1,e.query.page-1)),disabled:e.query?.page<=1,"aria-label":"Previous page"},[...t[38]||(t[38]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-chevron-left"})],-1)])],8,dN),n("span",uN,c(e.query?.page)+"/"+c(e.totalPage||1),1),n("button",{class:"btn btn-sm btn-icon",type:"button",onClick:t[9]||(t[9]=o=>e.query.page=Math.min(e.totalPage,e.query.page+1)),disabled:e.query?.page>=e.totalPage,"aria-label":"Next page"},[...t[39]||(t[39]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-chevron-right"})],-1)])],8,cN)])):f("v-if",!0)],2),f(" Row 2: appears only when there are active filter chips "),e.chips?.length?(a(),l("div",pN,[n("div",fN,[(a(!0),l(q,null,Q(e.chips,(o,r)=>(a(),l("span",{class:"admin-active-chip",key:o?.key},[n("span",hN,c(o?.label),1),n("span",null,c(o?.value),1),n("button",{type:"button","aria-label":"Remove filter",onClick:d=>e.clearFilter(o.key)},[...t[41]||(t[41]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#project-icon-close"})],-1)])],8,mN)]))),128))])])):f("v-if",!0)])),[[i,e.viewState]]),e.selectedCount()>0?(a(),l("div",gN,[n("span",null,[n("strong",null,c(e.selectedCount()),1),t[42]||(t[42]=g(" selected",-1))]),n("button",{class:"btn btn-sm",type:"button",onClick:t[10]||(t[10]=o=>e.bulkRefresh())},[...t[43]||(t[43]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-refresh"})],-1),g(" Force refresh",-1)])]),n("button",{class:"btn btn-sm text-danger",type:"button",onClick:t[11]||(t[11]=o=>e.bulkRemoveCache())},[...t[44]||(t[44]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-broom"})],-1),g(" Remove cache",-1)])]),n("button",{class:"btn btn-sm",type:"button",onClick:t[12]||(t[12]=o=>e.clearSelection())},"Clear")])):f("v-if",!0),n("div",vN,[n("div",yN,[n("div",bN,[n("input",{type:"checkbox","aria-label":"Select all on page",onClick:t[13]||(t[13]=o=>e.selectAllOnPage()),checked:e.allSelected},null,8,wN)]),n("div",kN,[n("button",{type:"button",class:A(["sortable",{active:e.query?.sort=="source.repositoryName"}]),onClick:t[14]||(t[14]=o=>e.sortBy("source.repositoryName"))},[t[46]||(t[46]=g("Repository ",-1)),e.sortIcon("source.repositoryName")?(a(),l("svg",{key:0,class:A(["ui-icon sort-direction",{ascending:e.sortIcon("source.repositoryName")==="fa-arrow-up"}]),"aria-hidden":"true"},[...t[45]||(t[45]=[n("use",{href:"#project-icon-arrow"},null,-1)])],2)):f("v-if",!0)],2)]),n("div",CN,[n("button",{type:"button",class:A(["sortable",{active:e.query?.sort=="status"}]),onClick:t[15]||(t[15]=o=>e.sortBy("status"))},[t[48]||(t[48]=g("Status ",-1)),e.sortIcon("status")?(a(),l("svg",{key:0,class:A(["ui-icon sort-direction",{ascending:e.sortIcon("status")==="fa-arrow-up"}]),"aria-hidden":"true"},[...t[47]||(t[47]=[n("use",{href:"#project-icon-arrow"},null,-1)])],2)):f("v-if",!0)],2)]),n("div",EN,[n("button",{type:"button",class:A(["sortable",{active:e.query?.sort=="pageView"}]),onClick:t[16]||(t[16]=o=>e.sortBy("pageView"))},[t[50]||(t[50]=g("Views ",-1)),e.sortIcon("pageView")?(a(),l("svg",{key:0,class:A(["ui-icon sort-direction",{ascending:e.sortIcon("pageView")==="fa-arrow-up"}]),"aria-hidden":"true"},[...t[49]||(t[49]=[n("use",{href:"#project-icon-arrow"},null,-1)])],2)):f("v-if",!0)],2)]),n("div",SN,[n("button",{type:"button",class:A(["sortable",{active:e.query?.sort=="anonymizeDate"}]),onClick:t[17]||(t[17]=o=>e.sortBy("anonymizeDate"))},[t[52]||(t[52]=g("Anonymized ",-1)),e.sortIcon("anonymizeDate")?(a(),l("svg",{key:0,class:A(["ui-icon sort-direction",{ascending:e.sortIcon("anonymizeDate")==="fa-arrow-up"}]),"aria-hidden":"true"},[...t[51]||(t[51]=[n("use",{href:"#project-icon-arrow"},null,-1)])],2)):f("v-if",!0)],2)]),t[53]||(t[53]=n("div",{role:"columnheader","aria-label":"Actions"},null,-1))]),(a(!0),l(q,null,Q(e.filteredRepositories,(o,r)=>(a(),l("div",{class:A(["paper-table-row",{"repo-inactive":o?.status=="expired"||o?.status=="removed","repo-error":o?.status=="error","row-selected":e.selected[o?.repoId]}]),role:"row"},[n("div",NN,[D(n("input",RN,null,512),[[s,{state:e.viewState,set:d=>{e.selected[o.repoId]=d},value:e.selected[o?.repoId],form:null,options:{}}]])]),n("div",AN,[t[56]||(t[56]=n("svg",{class:"ui-icon record-type-icon",role:"img","aria-label":"Repository"},[n("use",{href:"#project-type-repo"})],-1)),n("div",PN,[n("a",{class:"repo-name",target:"_blank",textContent:c(o?.repoId),href:e.safeUrl("/r/"+o?.repoId)},null,8,DN),n("div",{class:"anon-sub anon-meta","data-meta-fit":"",title:[o?.source?.fullName||o?.source?.repositoryName,o?.options?.update?"branch "+o?.source?.branch:"commit "+o?.source?.commit?.substring(0,7),o?.conference?"conference "+o?.conference:"",o?.size?.storage>0?e.fmt?.humanFileSize(o?.size?.storage):"",e.fmt?.number(o?.options?.terms?.length)+(o?.options?.terms?.length===1?" term":" terms")].filter(Boolean).join(" \xB7 ")},[n("a",{class:"src-path",href:e.safeUrl("https://github.com/"+o?.source?.repositoryName+"/")},[(o?.source?.repositoryName||"").includes("/")?(a(),l("span",{key:0,class:"src-owner",textContent:c((d=>d.length>16?d.slice(0,14)+"\u2026":d)((o?.source?.repositoryName||"").split("/")[0]))},null,8,IN)):f("v-if",!0),n("span",{class:"src-repo",textContent:c((o?.source?.repositoryName||"").includes("/")?"/"+(o?.source?.repositoryName||"").split("/").slice(1).join("/"):o?.source?.repositoryName)},null,8,MN)],8,ON),o?.options?.update?f("v-if",!0):(a(),l("span",{key:0,class:"meta-item","data-meta-label":"commit "+(o?.source?.commit||"").substring(0,7)},[n("a",{class:"mono-hash",title:o?.source?.commit,textContent:c(o?.source?.commit?.substring(0,7)),href:e.safeUrl("https://github.com/"+o?.source?.fullName+"/tree/"+o?.source?.commit)},null,8,qN)],8,VN)),o?.options?.update?(a(),l("span",{key:1,class:"meta-item","data-meta-label":"branch "+(o?.source?.branch||"")},[n("a",{textContent:c(o?.source?.branch),href:e.safeUrl("https://github.com/"+o?.source?.fullName+"/tree/"+o?.source?.branch)},null,8,LN)],8,_N)):f("v-if",!0),o?.conference?(a(),l("span",{key:2,class:"meta-item meta-conf","data-meta-label":"conference "+o?.conference},[t[54]||(t[54]=n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#project-icon-conference"})],-1)),g(" "+c(o?.conference),1)],8,$N)):f("v-if",!0),o?.size?.storage>0?(a(),l("span",FN,c(e.fmt?.humanFileSize(o?.size?.storage)),1)):f("v-if",!0),n("span",UN,c(e.fmt?.number(o?.options?.terms?.length))+" "+c(o?.options?.terms?.length===1?"term":"terms"),1),t[55]||(t[55]=n("span",{class:"meta-more",hidden:""},null,-1))],8,TN)])]),n("div",BN,[n("span",zN,[n("span",{class:A(["status-dot","st-"+(o?.status||"unknown")])},null,2),n("span",{textContent:c(e.fmt?.statusLabel(o?.status))},null,8,HN)]),o?.statusMessage?(a(),l("span",{key:0,class:"status-sub",textContent:c(e.fmt?.statusMsg(o?.statusMessage)),title:o?.statusMessage},null,8,jN)):f("v-if",!0)]),n("div",{class:"cell-views num",role:"cell","data-unit":(o?.pageView||0)===1?"view":"views"},[t[57]||(t[57]=n("svg",{class:"ui-icon mobile-meta-icon","aria-hidden":"true"},[n("use",{href:"#project-icon-eye"})],-1)),t[58]||(t[58]=g()),n("span",{textContent:c(e.fmt?.number(o?.pageView||0))},null,8,WN)],8,GN),n("div",KN,[t[59]||(t[59]=n("svg",{class:"ui-icon mobile-meta-icon","aria-hidden":"true"},[n("use",{href:"#project-icon-clock"})],-1)),t[60]||(t[60]=g()),n("span",{textContent:c((e.fmt?.humanTime(o?.anonymizeDate)||"").replace(/^on /,""))},null,8,YN)]),n("div",XN,[n("div",JN,[t[72]||(t[72]=n("button",{class:"btn btn-icon-dots",type:"button","data-toggle":"dropdown","aria-haspopup":"true","aria-expanded":"false","aria-label":"Actions"},[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#project-icon-more"})])],-1)),n("div",QN,[n("a",{class:"dropdown-item",href:e.safeUrl("/anonymize/"+o?.repoId)},[...t[61]||(t[61]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-edit"})],-1),g(" Edit",-1)])],8,ZN),n("a",{class:"dropdown-item",href:e.safeUrl("/r/"+o?.repoId+"/")},[...t[62]||(t[62]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#project-icon-eye"})],-1),g(" View repo",-1)])],8,xN),o?.options?.page&&o?.status=="ready"?(a(),l("a",{key:0,class:"dropdown-item",target:"_self",href:e.safeUrl("/w/"+o?.repoId+"/")},[...t[63]||(t[63]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-globe"})],-1),g(" View page",-1)])],8,eR)):f("v-if",!0),n("a",{class:"dropdown-item",href:"#",onClick:ae(d=>e.fetchGithubInfo(o),["prevent"])},[...t[64]||(t[64]=[n("i",{class:"fab fa-github"},null,-1),g(" Live GitHub info",-1)])],8,tR),t[70]||(t[70]=n("div",{class:"dropdown-divider"},null,-1)),D(n("a",{class:"dropdown-item",href:"#",onClick:ae(d=>e.updateRepository(o),["prevent"])},[...t[65]||(t[65]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-refresh"})],-1),g(" Force update",-1)])],8,nR),[[Z,o?.status=="ready"||o?.status=="error"]]),D(n("a",{class:"dropdown-item",href:"#",onClick:ae(d=>e.updateRepository(o),["prevent"])},[...t[66]||(t[66]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-check-circle"})],-1),g(" Enable",-1)])],8,sR),[[Z,o?.status=="removed"]]),D(n("a",{class:"dropdown-item",href:"#",onClick:ae(d=>e.showStatusMessage(o),["prevent"])},[...t[67]||(t[67]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-warning"})],-1),g(" View status message",-1)])],8,oR),[[Z,o?.statusMessage]]),t[71]||(t[71]=n("div",{class:"dropdown-divider"},null,-1)),n("a",{class:"dropdown-item",href:"#",onClick:ae(d=>e.removeCache(o),["prevent"])},[...t[68]||(t[68]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-broom"})],-1),g(" Remove cache",-1)])],8,iR),D(n("a",{class:"dropdown-item text-danger",href:"#",onClick:ae(d=>e.removeRepository(o),["prevent"])},[...t[69]||(t[69]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-trash"})],-1),g(" Remove",-1)])],8,rR),[[Z,o?.status=="ready"]])])])])],2))),256)),e.filteredRepositories?.length==0?(a(),l("div",aR,[t[73]||(t[73]=n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#project-icon-inbox"})],-1)),t[74]||(t[74]=n("span",null,"No repositories match the current filters.",-1)),e.query.ready&&e.query.expired&&e.query.removed&&e.query.error&&e.query.preparing?f("v-if",!0):(a(),l("button",{key:0,type:"button",class:"btn btn-sm btn-outline-ink",onClick:t[18]||(t[18]=o=>e.showAllStatuses())},"Show all statuses"))])):f("v-if",!0)]),n("div",lR,[t[79]||(t[79]=n("span",{"aria-hidden":"true"},null,-1)),e.totalPage>1?(a(),l("div",dR,[n("button",{class:"btn btn-sm",onClick:t[19]||(t[19]=o=>e.query.page=Math.max(1,e.query.page-1)),disabled:e.query?.page<=1},[...t[75]||(t[75]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-chevron-left"})],-1),g(" Previous ",-1)])],8,uR),D(n("input",{type:"number",class:"form-control form-control-sm",min:"1",style:{width:"56px"},"aria-label":"Page",max:e.totalPage},null,8,cR),[[s,{state:e.viewState,set:o=>{e.query.page=o},value:e.query?.page,form:null,options:{}}]]),n("span",null,"of "+c(e.totalPage),1),n("button",{class:"btn btn-sm",onClick:t[20]||(t[20]=o=>e.query.page=Math.min(e.totalPage,e.query.page+1)),disabled:e.query?.page>=e.totalPage},[...t[76]||(t[76]=[g(" Next ",-1),n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-chevron-right"})],-1)])],8,pR)])):f("v-if",!0),n("span",fR,[t[78]||(t[78]=n("label",null,"Per page",-1)),D((a(),l("select",hR,[...t[77]||(t[77]=[Ce('',5)])])),[[s,{state:e.viewState,set:o=>{e.query.limit=o},value:e.query?.limit,form:null,options:{}}]])])])])}var mR={class:"container paper-page admin-page"},gR={class:"paper-crumbs"},vR={class:"here"},yR={class:"paper-page-title"},bR={key:0,class:"user-detail-card"},wR={class:"user-header"},kR=["src"],CR={class:"user-header-status"},ER={class:"status-dot-wrap"},SR=["textContent"],NR={key:0,class:"type-badge type-repo"},RR={class:"user-actions",style:{"margin-top":"4px"}},AR={class:"user-detail-grid"},PR={class:"detail-value mono-id"},DR={class:"detail-value"},TR=["href"],OR={class:"detail-value"},IR={class:"detail-value"},MR={key:0},VR={key:1,class:"text-muted"},qR={class:"detail-value"},_R={key:0,style:{"margin-top":"20px"}},LR={class:"paper-table w-100",style:{"margin-top":"10px"}},$R={class:"paper-table-row",style:{"grid-template-columns":"1fr 160px"}},FR={class:"cell-anon",role:"cell"},UR={class:"anon-text"},BR=["textContent"],zR={class:"cell-expires",role:"cell"},HR={key:1,class:"admin-section-header"},jR={class:"section-count"},GR={key:2,class:"user-detail-card"},WR={type:"text",class:"form-control",placeholder:"Token name (e.g. dev-laptop)",required:""},KR={key:0,class:"alert alert-warning",role:"alert"},YR={style:{"white-space":"pre-wrap","word-break":"break-all",margin:"8px 0 0","font-family":"var(--font-mono)","font-size":"0.85rem"}},XR={key:1,class:"paper-table w-100"},JR={class:"paper-table-row",role:"row",style:{"grid-template-columns":"1fr 200px 200px 80px"}},QR=["textContent"],ZR=["textContent"],xR={role:"cell"},e4={key:0},t4={key:1,class:"text-muted"},n4={role:"cell"},s4=["onClick"],o4={key:2,class:"paper-table-empty"},i4={class:"admin-section-header"},r4={class:"section-count"},a4={class:"seg-bar"},l4={class:"seg-filter",role:"radiogroup","aria-label":"Filter by status"},d4=["aria-checked"],u4={class:"count"},c4=["aria-checked"],p4={class:"count"},f4=["aria-checked"],h4={class:"count"},m4=["aria-checked"],g4={class:"count"},v4=["aria-checked"],y4={class:"count"},b4=["aria-checked"],w4={class:"count"},k4={class:"seg-countline",role:"status"},C4={class:"w-100 admin-filter-toolbar","aria-label":"Repositories","accept-charset":"UTF-8"},E4={class:"admin-filter-row"},S4={class:"search-wrap"},N4={type:"search",class:"form-control","aria-label":"Search repositories",placeholder:"Search repositories or errors\u2026",autocomplete:"off"},R4={key:3,class:"bulk-bar"},A4={class:"paper-table paper-table-repos has-bulk w-100",role:"table","aria-label":"Repositories"},P4={class:"paper-table-head",role:"row"},D4={role:"columnheader",style:{width:"28px"}},T4=["checked"],O4={role:"columnheader"},I4={role:"columnheader"},M4={role:"columnheader",class:"num"},V4={role:"columnheader"},q4={role:"cell",style:{width:"28px"}},_4={type:"checkbox","aria-label":"Select repository"},L4={class:"cell-anon",role:"cell"},$4={class:"anon-text"},F4=["textContent","href"],U4=["title"],B4=["href"],z4=["textContent"],H4=["textContent"],j4=["data-meta-label"],G4=["title","textContent","href"],W4=["data-meta-label"],K4=["textContent","href"],Y4=["data-meta-label"],X4={key:3,class:"meta-item"},J4={class:"meta-item"},Q4={class:"cell-status",role:"cell"},Z4={class:"status-line"},x4=["textContent"],eA=["textContent","title"],tA=["data-unit","textContent"],nA=["textContent"],sA={class:"cell-actions",role:"cell"},oA={class:"dropdown"},iA={class:"dropdown-menu dropdown-menu-right"},rA=["href"],aA=["href"],lA=["href"],dA=["onClick"],uA=["onClick"],cA=["onClick"],pA=["onClick"],fA=["onClick"],hA=["onClick"],mA={key:0,class:"paper-table-empty"};function ip(e,t){let s=Pe("field"),i=Pe("form");return a(),l("div",mR,[n("div",gR,[t[23]||(t[23]=n("a",{href:"/admin/"},"Admin",-1)),t[24]||(t[24]=g(" \xA0/\xA0 ",-1)),t[25]||(t[25]=n("a",{href:"/admin/users"},"Users",-1)),t[26]||(t[26]=g(" \xA0/\xA0 ",-1)),n("span",vR,c(e.userInfo?.username||"Profile"),1)]),n("h1",yR,c(e.userInfo?.username||"User"),1),t[93]||(t[93]=Ce('',1)),e.userInfo?(a(),l("div",bR,[n("div",wR,[e.userInfo?.photo?(a(),l("img",{key:0,width:"56",height:"56",src:e.safeUrl(e.userInfo?.photo)},null,8,kR)):f("v-if",!0),n("div",null,[n("div",CR,[n("span",ER,[n("span",{class:A(["status-dot","st-"+(e.userInfo?.status||"unknown")])},null,2),n("span",{textContent:c(e.fmt?.title(e.userInfo?.status))},null,8,SR)]),e.userInfo?.isAdmin?(a(),l("span",NR,"Admin")):f("v-if",!0)]),n("div",RR,[e.userInfo?.status!=="banned"&&e.userInfo?.username!==e.user?.username?(a(),l("button",{key:0,class:"btn btn-sm btn-outline-danger",onClick:t[0]||(t[0]=o=>e.banUser())},[...t[27]||(t[27]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-ban"})],-1),g(" Ban",-1)])])):f("v-if",!0),e.userInfo?.status==="banned"||e.userInfo?.status==="removed"?(a(),l("button",{key:1,class:"btn btn-sm",onClick:t[1]||(t[1]=o=>e.activateUser())},[...t[28]||(t[28]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-check-circle"})],-1),g(" Activate",-1)])])):f("v-if",!0),e.userInfo?.isAdmin?f("v-if",!0):(a(),l("button",{key:2,class:"btn btn-sm",onClick:t[2]||(t[2]=o=>e.promoteUser())},[...t[29]||(t[29]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-user-shield"})],-1),g(" Promote to admin",-1)])])),e.userInfo?.isAdmin&&e.userInfo?.username!==e.user?.username?(a(),l("button",{key:3,class:"btn btn-sm btn-outline-ink",onClick:t[3]||(t[3]=o=>e.demoteUser())},[...t[30]||(t[30]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-user-minus"})],-1),g(" Remove admin",-1)])])):f("v-if",!0)])])]),n("div",AR,[t[33]||(t[33]=n("div",{class:"detail-label"},"ID",-1)),n("div",PR,c(e.userInfo?._id),1),t[34]||(t[34]=n("div",{class:"detail-label"},"Email",-1)),n("div",{class:A(["detail-value",{"is-empty":!e.userInfo?.emails?.[0]?.email}])},c(e.userInfo?.emails?.[0]?.email||"Not shared"),3),t[35]||(t[35]=n("div",{class:"detail-label"},"Access token",-1)),n("div",{class:A(["detail-value",{"is-empty":!e.userInfo?.accessTokens?.github}]),style:{"font-family":"var(--font-mono)","font-size":"0.85rem"}},c(e.userInfo?.accessTokens?.github||"Not stored"),3),t[36]||(t[36]=n("div",{class:"detail-label"},"GitHub",-1)),n("div",DR,[n("a",{target:"_blank",href:e.safeUrl("https://github.com/"+e.userInfo?.username)},[t[31]||(t[31]=n("i",{class:"fab fa-github"},null,-1)),g(" "+c(e.userInfo?.username),1)],8,TR)]),t[37]||(t[37]=n("div",{class:"detail-label"},"Created",-1)),n("div",OR,c(e.fmt?.humanTime(e.userInfo?.dateOfEntry)),1),t[38]||(t[38]=n("div",{class:"detail-label"},"Last connection",-1)),n("div",IR,[e.userInfo?.accessTokenDates?.github?(a(),l("span",MR,c(e.fmt?.humanTime(e.userInfo?.accessTokenDates?.github)),1)):f("v-if",!0),e.userInfo?.accessTokenDates?.github?f("v-if",!0):(a(),l("span",VR,"Not recorded (GitHub App sign-in)"))]),t[39]||(t[39]=n("div",{class:"detail-label"},"GitHub repos",-1)),n("div",qR,[g(c(e.userInfo?.repositories?.length?e.userInfo.repositories.length+" repositories":"Not synced")+" ",1),e.userInfo?.repositories?.length?(a(),l("button",{key:0,class:"btn btn-sm ml-2",onClick:t[4]||(t[4]=o=>e.showRepos=!e.showRepos)},c(e.showRepos?"Hide repos":"Show repos"),1)):f("v-if",!0),n("button",{class:"btn btn-sm ml-1",onClick:t[5]||(t[5]=o=>e.getGitHubRepositories())},[...t[32]||(t[32]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-refresh"})],-1),g(" Refresh ",-1)])])])]),e.showRepos?(a(),l("div",_R,[t[42]||(t[42]=n("div",{class:"paper-section-eyebrow"},"GitHub repositories",-1)),n("div",LR,[(a(!0),l(q,null,Q(e.userInfo?.repositories,(o,r)=>(a(),l("div",$R,[n("div",FR,[t[40]||(t[40]=n("svg",{class:"ui-icon record-type-icon",role:"img","aria-label":"Repository"},[n("use",{href:"#project-type-repo"})],-1)),n("div",UR,[n("span",{class:"repo-name",textContent:c(o?.name)},null,8,BR)])]),n("div",zR,[t[41]||(t[41]=n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-database"})],-1)),g(" "+c(e.fmt?.humanFileSize(o?.size)),1)])]))),256))])])):f("v-if",!0)])):f("v-if",!0),e.userInfo&&e.userInfo?.isAdmin&&e.user&&e.user?.username==e.userInfo?.username?(a(),l("div",HR,[t[43]||(t[43]=n("h2",null,[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-key"})]),g(" API tokens")],-1)),n("span",jR,c(e.tokens?.length),1)])):f("v-if",!0),e.userInfo&&e.userInfo?.isAdmin&&e.user&&e.user?.username==e.userInfo?.username?(a(),l("div",GR,[t[49]||(t[49]=n("p",{class:"paper-page-lede"},[g("Personal API tokens for this admin account. Send as "),n("code",null,"Authorization: Bearer "),g(" to authenticate without GitHub OAuth (useful for development).")],-1)),D((a(),l("form",{class:"d-flex",style:{gap:"8px","margin-bottom":"12px"},onSubmit:t[6]||(t[6]=ae(o=>e.submitForm(o,()=>{e.createToken()}),["prevent"]))},[D(n("input",WR,null,512),[[s,{state:e.viewState,set:o=>{e.tokenForm.name=o},value:e.tokenForm?.name,form:null,options:{}}]]),t[44]||(t[44]=n("button",{type:"submit",class:"btn btn-ink"},[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#project-icon-plus"})]),g(" Generate")],-1))],32)),[[i,e.viewState]]),e.tokenForm?.plaintext?(a(),l("div",KR,[t[45]||(t[45]=n("strong",null,"Copy this token now \u2014 it will not be shown again:",-1)),n("pre",YR,c(e.tokenForm?.plaintext),1),n("button",{class:"btn btn-sm",onClick:t[7]||(t[7]=o=>e.tokenForm.plaintext=null)},"Dismiss")])):f("v-if",!0),e.tokens?.length?(a(),l("div",XR,[t[47]||(t[47]=n("div",{class:"paper-table-head",role:"row",style:{"grid-template-columns":"1fr 200px 200px 80px"}},[n("div",{role:"columnheader"},"Name"),n("div",{role:"columnheader"},"Created"),n("div",{role:"columnheader"},"Last used"),n("div",{role:"columnheader","aria-label":"Actions"})],-1)),(a(!0),l(q,null,Q(e.tokens,(o,r)=>(a(),l("div",JR,[n("div",{role:"cell",textContent:c(o?.name)},null,8,QR),n("div",{role:"cell",textContent:c(e.fmt?.humanTime(o?.createdAt))},null,8,ZR),n("div",xR,[o?.lastUsedAt?(a(),l("span",e4,c(e.fmt?.humanTime(o?.lastUsedAt)),1)):f("v-if",!0),o?.lastUsedAt?f("v-if",!0):(a(),l("span",t4,"never"))]),n("div",n4,[n("button",{class:"btn btn-sm text-danger btn-icon",title:"Revoke","aria-label":"Revoke token",onClick:d=>e.revokeToken(o)},[...t[46]||(t[46]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-trash"})],-1)])],8,s4)])]))),256))])):f("v-if",!0),e.tokens?.length?f("v-if",!0):(a(),l("div",o4,[...t[48]||(t[48]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#project-icon-inbox"})],-1),n("span",null,"No tokens yet.",-1)])]))])):f("v-if",!0),n("div",i4,[t[50]||(t[50]=n("h2",null,[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#project-type-repo"})]),g(" Anonymized repositories")],-1)),n("span",r4,c(e.repositories?.length),1)]),n("div",a4,[n("div",l4,[n("button",{type:"button",role:"radio",class:A(["seg-chip",{active:e.segView()==="all"}]),"aria-checked":e.segView()==="all",onClick:t[8]||(t[8]=o=>e.setSegView("all"))},[t[51]||(t[51]=g("All ",-1)),n("span",u4,c(e.fmt?.number(e.segCount("all"))),1)],10,d4),n("button",{type:"button",role:"radio",class:A(["seg-chip",{active:e.segView()==="ready","is-empty":!e.segCount("ready")}]),"aria-checked":e.segView()==="ready",onClick:t[9]||(t[9]=o=>e.setSegView("ready"))},[t[52]||(t[52]=n("span",{class:"seg-dot ok","aria-hidden":"true"},null,-1)),t[53]||(t[53]=g("Ready ",-1)),n("span",p4,c(e.fmt?.number(e.segCount("ready"))),1)],10,c4),n("button",{type:"button",role:"radio",class:A(["seg-chip",{active:e.segView()==="preparing","is-empty":!e.segCount("preparing")}]),"aria-checked":e.segView()==="preparing",onClick:t[10]||(t[10]=o=>e.setSegView("preparing"))},[t[54]||(t[54]=n("span",{class:"seg-dot warn","aria-hidden":"true"},null,-1)),t[55]||(t[55]=g("Preparing ",-1)),n("span",h4,c(e.fmt?.number(e.segCount("preparing"))),1)],10,f4),n("button",{type:"button",role:"radio",class:A(["seg-chip",{active:e.segView()==="error","is-empty":!e.segCount("error")}]),"aria-checked":e.segView()==="error",onClick:t[11]||(t[11]=o=>e.setSegView("error"))},[t[56]||(t[56]=n("span",{class:"seg-dot bad","aria-hidden":"true"},null,-1)),t[57]||(t[57]=g("Error ",-1)),n("span",g4,c(e.fmt?.number(e.segCount("error"))),1)],10,m4),n("button",{type:"button",role:"radio",class:A(["seg-chip",{active:e.segView()==="expired","is-empty":!e.segCount("expired")}]),"aria-checked":e.segView()==="expired",onClick:t[12]||(t[12]=o=>e.setSegView("expired"))},[t[58]||(t[58]=n("span",{class:"seg-dot off","aria-hidden":"true"},null,-1)),t[59]||(t[59]=g("Expiring / expired ",-1)),n("span",y4,c(e.fmt?.number(e.segCount("expired"))),1)],10,v4),n("button",{type:"button",role:"radio",class:A(["seg-chip",{active:e.segView()==="removed","is-empty":!e.segCount("removed")}]),"aria-checked":e.segView()==="removed",onClick:t[13]||(t[13]=o=>e.setSegView("removed"))},[t[60]||(t[60]=n("span",{class:"seg-dot off","aria-hidden":"true"},null,-1)),t[61]||(t[61]=g("Removing / removed ",-1)),n("span",w4,c(e.fmt?.number(e.segCount("removed"))),1)],10,b4)]),n("p",k4,[n("strong",null,c(e.fmt.number(e.filteredRepositories?.length||0)),1),t[62]||(t[62]=g(" shown",-1))])]),D((a(),l("form",C4,[n("div",E4,[n("div",S4,[D(n("input",N4,null,512),[[s,{state:e.viewState,set:o=>{e.search=o},value:e.search,form:null,options:{}}]])]),t[64]||(t[64]=n("span",{class:"admin-filter-spacer"},null,-1)),n("button",{class:"btn btn-sm",type:"button",title:"Export current view to CSV",onClick:t[14]||(t[14]=o=>e.exportCsv())},[...t[63]||(t[63]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-export"})],-1),g(" Export",-1)])])])])),[[i,e.viewState]]),e.selectedCount()>0?(a(),l("div",R4,[n("span",null,[n("strong",null,c(e.selectedCount()),1),t[65]||(t[65]=g(" selected",-1))]),n("button",{class:"btn btn-sm",type:"button",onClick:t[15]||(t[15]=o=>e.bulkRefresh())},[...t[66]||(t[66]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-refresh"})],-1),g(" Force refresh",-1)])]),n("button",{class:"btn btn-sm text-danger",type:"button",onClick:t[16]||(t[16]=o=>e.bulkRemoveCache())},[...t[67]||(t[67]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-broom"})],-1),g(" Remove cache",-1)])]),n("button",{class:"btn btn-sm",type:"button",onClick:t[17]||(t[17]=o=>e.clearSelection())},"Clear")])):f("v-if",!0),n("div",A4,[n("div",P4,[n("div",D4,[n("input",{type:"checkbox","aria-label":"Select all on page",onClick:t[18]||(t[18]=o=>e.selectAllOnPage()),checked:e.allSelected},null,8,T4)]),n("div",O4,[n("button",{type:"button",class:A(["sortable",{active:e.query?.sort=="source.repositoryName"}]),onClick:t[19]||(t[19]=o=>e.sortBy("source.repositoryName"))},[t[69]||(t[69]=g("Repository ",-1)),e.sortIcon("source.repositoryName")?(a(),l("svg",{key:0,class:A(["ui-icon sort-direction",{ascending:e.sortIcon("source.repositoryName")==="fa-arrow-up"}]),"aria-hidden":"true"},[...t[68]||(t[68]=[n("use",{href:"#project-icon-arrow"},null,-1)])],2)):f("v-if",!0)],2)]),n("div",I4,[n("button",{type:"button",class:A(["sortable",{active:e.query?.sort=="status"}]),onClick:t[20]||(t[20]=o=>e.sortBy("status"))},[t[71]||(t[71]=g("Status ",-1)),e.sortIcon("status")?(a(),l("svg",{key:0,class:A(["ui-icon sort-direction",{ascending:e.sortIcon("status")==="fa-arrow-up"}]),"aria-hidden":"true"},[...t[70]||(t[70]=[n("use",{href:"#project-icon-arrow"},null,-1)])],2)):f("v-if",!0)],2)]),n("div",M4,[n("button",{type:"button",class:A(["sortable",{active:e.query?.sort=="pageView"}]),onClick:t[21]||(t[21]=o=>e.sortBy("pageView"))},[t[73]||(t[73]=g("Views ",-1)),e.sortIcon("pageView")?(a(),l("svg",{key:0,class:A(["ui-icon sort-direction",{ascending:e.sortIcon("pageView")==="fa-arrow-up"}]),"aria-hidden":"true"},[...t[72]||(t[72]=[n("use",{href:"#project-icon-arrow"},null,-1)])],2)):f("v-if",!0)],2)]),n("div",V4,[n("button",{type:"button",class:A(["sortable",{active:e.query?.sort=="anonymizeDate"}]),onClick:t[22]||(t[22]=o=>e.sortBy("anonymizeDate"))},[t[75]||(t[75]=g("Anonymized ",-1)),e.sortIcon("anonymizeDate")?(a(),l("svg",{key:0,class:A(["ui-icon sort-direction",{ascending:e.sortIcon("anonymizeDate")==="fa-arrow-up"}]),"aria-hidden":"true"},[...t[74]||(t[74]=[n("use",{href:"#project-icon-arrow"},null,-1)])],2)):f("v-if",!0)],2)]),t[76]||(t[76]=n("div",{role:"columnheader","aria-label":"Actions"},null,-1))]),(a(!0),l(q,null,Q(e.filteredRepositories,(o,r)=>(a(),l("div",{class:A(["paper-table-row",{"repo-inactive":o?.status=="expired"||o?.status=="removed","repo-error":o?.status=="error","row-selected":e.selected[o?.repoId]}]),role:"row"},[n("div",q4,[D(n("input",_4,null,512),[[s,{state:e.viewState,set:d=>{e.selected[o.repoId]=d},value:e.selected[o?.repoId],form:null,options:{}}]])]),n("div",L4,[t[79]||(t[79]=n("svg",{class:"ui-icon record-type-icon",role:"img","aria-label":"Repository"},[n("use",{href:"#project-type-repo"})],-1)),n("div",$4,[n("a",{class:"repo-name",target:"_blank",textContent:c(o?.repoId),href:e.safeUrl("/r/"+o?.repoId)},null,8,F4),n("div",{class:"anon-sub anon-meta","data-meta-fit":"",title:[o?.source?.fullName||o?.source?.repositoryName,o?.options?.update?"branch "+o?.source?.branch:"commit "+o?.source?.commit?.substring(0,7),o?.conference?"conference "+o?.conference:"",o?.size?.storage>0?e.fmt?.humanFileSize(o?.size?.storage):"",e.fmt?.number(o?.options?.terms?.length)+(o?.options?.terms?.length===1?" term":" terms")].filter(Boolean).join(" \xB7 ")},[n("a",{class:"src-path",href:e.safeUrl("https://github.com/"+o?.source?.fullName+"/")},[(o?.source?.fullName||"").includes("/")?(a(),l("span",{key:0,class:"src-owner",textContent:c((d=>d.length>16?d.slice(0,14)+"\u2026":d)((o?.source?.fullName||"").split("/")[0]))},null,8,z4)):f("v-if",!0),n("span",{class:"src-repo",textContent:c((o?.source?.fullName||"").includes("/")?"/"+(o?.source?.fullName||"").split("/").slice(1).join("/"):o?.source?.fullName)},null,8,H4)],8,B4),o?.options?.update?f("v-if",!0):(a(),l("span",{key:0,class:"meta-item","data-meta-label":"commit "+(o?.source?.commit||"").substring(0,7)},[n("a",{class:"mono-hash",title:o?.source?.commit,textContent:c(o?.source?.commit?.substring(0,7)),href:e.safeUrl("https://github.com/"+o?.source?.fullName+"/tree/"+o?.source?.commit)},null,8,G4)],8,j4)),o?.options?.update?(a(),l("span",{key:1,class:"meta-item","data-meta-label":"branch "+(o?.source?.branch||"")},[n("a",{textContent:c(o?.source?.branch),href:e.safeUrl("https://github.com/"+o?.source?.fullName+"/tree/"+o?.source?.branch)},null,8,K4)],8,W4)):f("v-if",!0),o?.conference?(a(),l("span",{key:2,class:"meta-item meta-conf","data-meta-label":"conference "+o?.conference},[t[77]||(t[77]=n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#project-icon-conference"})],-1)),g(" "+c(o?.conference),1)],8,Y4)):f("v-if",!0),o?.size?.storage>0?(a(),l("span",X4,c(e.fmt?.humanFileSize(o?.size?.storage)),1)):f("v-if",!0),n("span",J4,c(e.fmt?.number(o?.options?.terms?.length))+" "+c(o?.options?.terms?.length===1?"term":"terms"),1),t[78]||(t[78]=n("span",{class:"meta-more",hidden:""},null,-1))],8,U4)])]),n("div",Q4,[n("span",Z4,[n("span",{class:A(["status-dot","st-"+(o?.status||"unknown")])},null,2),n("span",{textContent:c(e.fmt?.statusLabel(o?.status))},null,8,x4)]),o?.statusMessage?(a(),l("span",{key:0,class:"status-sub",textContent:c(e.fmt?.statusMsg(o?.statusMessage)),title:o?.statusMessage},null,8,eA)):f("v-if",!0)]),n("div",{class:"cell-views num",role:"cell","data-unit":(o?.pageView||0)===1?"view":"views",textContent:c(e.fmt?.number(o?.pageView||0))},null,8,tA),n("div",{class:"cell-expires",role:"cell",textContent:c(e.fmt?.humanTime(o?.anonymizeDate))},null,8,nA),n("div",sA,[n("div",oA,[t[91]||(t[91]=n("button",{class:"btn btn-icon-dots",type:"button","data-toggle":"dropdown","aria-haspopup":"true","aria-expanded":"false","aria-label":"Actions"},[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#project-icon-more"})])],-1)),n("div",iA,[n("a",{class:"dropdown-item",href:e.safeUrl("/anonymize/"+o?.repoId)},[...t[80]||(t[80]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-edit"})],-1),g(" Edit",-1)])],8,rA),n("a",{class:"dropdown-item",href:e.safeUrl("/r/"+o?.repoId+"/")},[...t[81]||(t[81]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#project-icon-eye"})],-1),g(" View repo",-1)])],8,aA),o?.options?.page&&o?.status=="ready"?(a(),l("a",{key:0,class:"dropdown-item",target:"_self",href:e.safeUrl("/w/"+o?.repoId+"/")},[...t[82]||(t[82]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-globe"})],-1),g(" View page",-1)])],8,lA)):f("v-if",!0),n("a",{class:"dropdown-item",href:"#",onClick:ae(d=>e.fetchGithubInfo(o),["prevent"])},[...t[83]||(t[83]=[n("i",{class:"fab fa-github"},null,-1),g(" Live GitHub info",-1)])],8,dA),t[89]||(t[89]=n("div",{class:"dropdown-divider"},null,-1)),D(n("a",{class:"dropdown-item",href:"#",onClick:ae(d=>e.updateRepository(o),["prevent"])},[...t[84]||(t[84]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-refresh"})],-1),g(" Force update",-1)])],8,uA),[[Z,o?.status=="ready"||o?.status=="error"]]),D(n("a",{class:"dropdown-item",href:"#",onClick:ae(d=>e.updateRepository(o),["prevent"])},[...t[85]||(t[85]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-check-circle"})],-1),g(" Enable",-1)])],8,cA),[[Z,o?.status=="removed"]]),D(n("a",{class:"dropdown-item",href:"#",onClick:ae(d=>e.showStatusMessage(o),["prevent"])},[...t[86]||(t[86]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-warning"})],-1),g(" View status message",-1)])],8,pA),[[Z,o?.statusMessage]]),t[90]||(t[90]=n("div",{class:"dropdown-divider"},null,-1)),n("a",{class:"dropdown-item",href:"#",onClick:ae(d=>e.removeCache(o),["prevent"])},[...t[87]||(t[87]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-broom"})],-1),g(" Remove cache",-1)])],8,fA),D(n("a",{class:"dropdown-item text-danger",href:"#",onClick:ae(d=>e.removeRepository(o),["prevent"])},[...t[88]||(t[88]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-trash"})],-1),g(" Remove",-1)])],8,hA),[[Z,o?.status=="ready"]])])])])],2))),256)),e.filteredRepositories?.length==0?(a(),l("div",mA,[...t[92]||(t[92]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#project-icon-inbox"})],-1),n("span",null,"No repositories match the current filters.",-1)])])):f("v-if",!0)])])}var gA={class:"container paper-page admin-page"},vA={class:"seg-bar"},yA={class:"seg-filter",role:"radiogroup","aria-label":"Filter by status"},bA=["aria-checked"],wA={class:"count"},kA=["aria-checked"],CA={class:"count"},EA=["aria-checked"],SA={class:"count"},NA=["aria-checked"],RA={class:"count"},AA={class:"seg-countline",role:"status"},PA={key:0,class:"alert alert-danger",style:{margin:"8px 0"}},DA={class:"w-100 admin-filter-toolbar","aria-label":"Users","accept-charset":"UTF-8"},TA={class:"admin-filter-row"},OA={class:"search-wrap"},IA={type:"search",class:"form-control","aria-label":"Search users",placeholder:"Search username or email\u2026",autocomplete:"off"},MA={key:0,class:"admin-search-hint"},VA={class:"admin-filter-inline"},qA={class:"form-control form-control-sm"},_A={key:0,class:"admin-filter-inline","aria-label":"Pagination"},LA=["disabled"],$A={style:{"font-family":"var(--font-mono)","font-size":"12px",color:"var(--ink-muted)"}},FA=["disabled"],UA={key:0,class:"admin-filter-row"},BA={class:"admin-active-chips"},zA={class:"key"},HA=["onClick"],jA={key:1,class:"bulk-bar"},GA={class:"paper-table w-100",role:"table","aria-label":"Users",style:{"--cols":"28px minmax(280px, 2.4fr) 100px 140px 140px 52px"}},WA={class:"paper-table-head admin-users-row",role:"row"},KA={role:"columnheader",style:{width:"28px"}},YA=["checked"],XA={role:"columnheader"},JA={role:"columnheader"},QA={role:"cell",style:{width:"28px"}},ZA={type:"checkbox","aria-label":"Select user"},xA={class:"cell-anon",role:"cell"},eP=["src"],tP={key:1,class:"avatar-fallback","aria-hidden":"true"},nP={class:"anon-text"},sP={class:"user-name-line"},oP=["textContent","href"],iP=["href","title","aria-label"],rP={class:"anon-sub meta-dots"},aP=["title"],lP={key:1},dP={class:"cell-views num",role:"cell"},uP=["title","textContent","href"],cP={class:"cell-status",role:"cell"},pP=["textContent"],fP={class:"cell-status",role:"cell"},hP={key:0,class:"role-pill"},mP={key:1,class:"empty-dash"},gP={class:"cell-actions",role:"cell"},vP={class:"dropdown"},yP={class:"dropdown-menu dropdown-menu-right"},bP=["href"],wP=["href"],kP=["onClick"],CP=["onClick"],EP={key:0,class:"paper-table-empty"},SP={class:"admin-toolbar",style:{"justify-content":"space-between","border-bottom":"none"}},NP={key:0,class:"pagination-compact"},RP=["disabled"],AP=["max"],PP=["disabled"],DP={class:"admin-filter-inline"},TP={class:"form-control form-control-sm"};function rp(e,t){let s=Pe("field"),i=Pe("form");return a(),l("div",gA,[t[53]||(t[53]=Ce('
Admin \xA0/\xA0 Users

Users

',3)),n("div",vA,[n("div",yA,[n("button",{type:"button",role:"radio",class:A(["seg-chip",{active:!e.query?.status}]),"aria-checked":!e.query?.status,onClick:t[0]||(t[0]=o=>{e.query.status="",e.query.page=1})},[t[14]||(t[14]=g("All ",-1)),n("span",wA,c(e.fmt?.number(e.statusCountFor("active")+e.statusCountFor("banned")+e.statusCountFor("removed"))),1)],10,bA),n("button",{type:"button",role:"radio",class:A(["seg-chip",{active:e.query?.status==="active","is-empty":!e.statusCountFor("active")}]),"aria-checked":e.query?.status==="active",onClick:t[1]||(t[1]=o=>{e.query.status="active",e.query.page=1})},[t[15]||(t[15]=n("span",{class:"seg-dot ok","aria-hidden":"true"},null,-1)),t[16]||(t[16]=g("Active ",-1)),n("span",CA,c(e.fmt?.number(e.statusCountFor("active"))),1)],10,kA),n("button",{type:"button",role:"radio",class:A(["seg-chip",{active:e.query?.status==="banned","is-empty":!e.statusCountFor("banned")}]),"aria-checked":e.query?.status==="banned",onClick:t[2]||(t[2]=o=>{e.query.status="banned",e.query.page=1})},[t[17]||(t[17]=n("span",{class:"seg-dot bad","aria-hidden":"true"},null,-1)),t[18]||(t[18]=g("Banned ",-1)),n("span",SA,c(e.fmt?.number(e.statusCountFor("banned"))),1)],10,EA),n("button",{type:"button",role:"radio",class:A(["seg-chip",{active:e.query?.status==="removed","is-empty":!e.statusCountFor("removed")}]),"aria-checked":e.query?.status==="removed",onClick:t[3]||(t[3]=o=>{e.query.status="removed",e.query.page=1})},[t[19]||(t[19]=n("span",{class:"seg-dot off","aria-hidden":"true"},null,-1)),t[20]||(t[20]=g("Removed ",-1)),n("span",RA,c(e.fmt?.number(e.statusCountFor("removed"))),1)],10,NA)]),n("p",AA,[n("strong",null,c(e.total>=0?e.fmt.number(e.total):"\u2026"),1),t[21]||(t[21]=g(" shown",-1))])]),e.fetchError?(a(),l("div",PA,[t[22]||(t[22]=n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-warning"})],-1)),g(" "+c(e.fetchError),1)])):f("v-if",!0),D((a(),l("form",DA,[n("div",TA,[n("div",OA,[D(n("input",IA,null,512),[[s,{state:e.viewState,set:o=>{e.query.search=o},value:e.query?.search,form:null,options:{}}]]),e.query?.search?f("v-if",!0):(a(),l("span",MA,"/"))]),n("span",VA,[t[24]||(t[24]=n("label",null,"Role",-1)),D((a(),l("select",qA,[...t[23]||(t[23]=[n("option",{value:""},"Any",-1),n("option",{value:"admin"},"Admin",-1)])])),[[s,{state:e.viewState,set:o=>{e.query.role=o},value:e.query?.role,form:null,options:{}}]])]),t[28]||(t[28]=n("span",{class:"admin-filter-spacer"},null,-1)),n("button",{class:"btn btn-sm",type:"button",onClick:t[4]||(t[4]=o=>e.exportCsv())},[...t[25]||(t[25]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-export"})],-1),g(" Export",-1)])]),e.totalPage>1?(a(),l("span",_A,[n("button",{class:"btn btn-sm btn-icon",type:"button",onClick:t[5]||(t[5]=o=>e.query.page=Math.max(1,e.query.page-1)),disabled:e.query?.page<=1,"aria-label":"Previous page"},[...t[26]||(t[26]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-chevron-left"})],-1)])],8,LA),n("span",$A,c(e.query?.page)+"/"+c(e.totalPage||1),1),n("button",{class:"btn btn-sm btn-icon",type:"button",onClick:t[6]||(t[6]=o=>e.query.page=Math.min(e.totalPage,e.query.page+1)),disabled:e.query?.page>=e.totalPage,"aria-label":"Next page"},[...t[27]||(t[27]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-chevron-right"})],-1)])],8,FA)])):f("v-if",!0)]),e.chips?.length?(a(),l("div",UA,[n("div",BA,[(a(!0),l(q,null,Q(e.chips,(o,r)=>(a(),l("span",{class:"admin-active-chip",key:o?.key},[n("span",zA,c(o?.label),1),n("span",null,c(o?.value),1),n("button",{type:"button",onClick:d=>e.clearFilter(o.key),"aria-label":"Clear filter"},[...t[29]||(t[29]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#project-icon-close"})],-1)])],8,HA)]))),128))])])):f("v-if",!0)])),[[i,e.viewState]]),e.selectedCount()>0?(a(),l("div",jA,[n("span",null,[n("strong",null,c(e.selectedCount()),1),t[30]||(t[30]=g(" selected",-1))]),n("button",{class:"btn btn-sm text-danger",type:"button",onClick:t[7]||(t[7]=o=>e.bulkBan())},[...t[31]||(t[31]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-ban"})],-1),g(" Ban",-1)])]),n("button",{class:"btn btn-sm",type:"button",onClick:t[8]||(t[8]=o=>{e.selected={},e.allSelected=!1})},"Clear")])):f("v-if",!0),n("div",GA,[n("div",WA,[n("div",KA,[n("input",{type:"checkbox","aria-label":"Select all on page",onClick:t[9]||(t[9]=o=>e.selectAllOnPage()),checked:e.allSelected},null,8,YA)]),n("div",XA,[n("button",{type:"button",class:A(["sortable",{active:e.query?.sort=="username"}]),onClick:t[10]||(t[10]=o=>e.sortBy("username"))},[t[33]||(t[33]=g("User ",-1)),e.sortIcon("username")?(a(),l("svg",{key:0,class:A(["ui-icon sort-direction",{ascending:e.sortIcon("username")==="fa-arrow-up"}]),"aria-hidden":"true"},[...t[32]||(t[32]=[n("use",{href:"#project-icon-arrow"},null,-1)])],2)):f("v-if",!0)],2)]),t[36]||(t[36]=n("div",{role:"columnheader",class:"num",title:"Repositories discovered on the user's GitHub account"},"GitHub repos",-1)),n("div",JA,[n("button",{type:"button",class:A(["sortable",{active:e.query?.sort=="status"}]),onClick:t[11]||(t[11]=o=>e.sortBy("status"))},[t[35]||(t[35]=g("Status ",-1)),e.sortIcon("status")?(a(),l("svg",{key:0,class:A(["ui-icon sort-direction",{ascending:e.sortIcon("status")==="fa-arrow-up"}]),"aria-hidden":"true"},[...t[34]||(t[34]=[n("use",{href:"#project-icon-arrow"},null,-1)])],2)):f("v-if",!0)],2)]),t[37]||(t[37]=n("div",{role:"columnheader"},"Role",-1)),t[38]||(t[38]=n("div",{role:"columnheader","aria-label":"Actions"},null,-1))]),(a(!0),l(q,null,Q(e.filteredUsers,(o,r)=>(a(),l("div",{class:A(["paper-table-row admin-users-row",{"row-selected":e.selected[o?.username]}]),role:"row"},[n("div",QA,[D(n("input",ZA,null,512),[[s,{state:e.viewState,set:d=>{e.selected[o.username]=d},value:e.selected[o?.username],form:null,options:{}}]])]),n("div",xA,[o?.photo?(a(),l("img",{key:0,width:"28",height:"28",class:"rounded-circle",style:{"flex-shrink":"0"},src:e.safeUrl(o?.photo)},null,8,eP)):(a(),l("span",tP,c((o?.username||"?").charAt(0).toUpperCase()),1)),n("div",nP,[n("span",sP,[n("a",{class:"repo-name",textContent:c(o?.username),href:e.safeUrl("/admin/users/"+o?.username)},null,8,oP),n("a",{class:"user-gh-link",target:"_blank",rel:"noopener",href:e.safeUrl("https://github.com/"+o?.username),title:o?.username+" on GitHub","aria-label":o?.username+" on GitHub"},[...t[39]||(t[39]=[n("i",{class:"fab fa-github","aria-hidden":"true"},null,-1)])],8,iP)]),n("div",rP,[o?.emails?.[0]?.email?(a(),l("span",{key:0,class:"meta-email meta-tail",title:o?.emails?.[0]?.email},c(o?.emails?.[0]?.email),9,aP)):f("v-if",!0),o?.dateOfEntry?(a(),l("span",lP,"Joined "+c(e.fmt?.humanTime(o?.dateOfEntry)),1)):f("v-if",!0)])])]),n("div",dP,[t[40]||(t[40]=n("svg",{class:"ui-icon mobile-meta-icon","aria-hidden":"true"},[n("use",{href:"#project-type-repo"})],-1)),n("a",{title:o?.repoCount?"Show this user\u2019s repositories":"Repositories not synced yet",textContent:c(o?.repoCount?e.fmt?.number(o.repoCount):"Not synced"),class:A({"is-unsynced":!o?.repoCount}),href:e.safeUrl("/admin/repositories?owner="+o?.username)},null,10,uP)]),n("div",cP,[n("span",{class:A(["status-dot","st-"+(o?.status||"unknown")])},null,2),n("span",{textContent:c(e.fmt?.title(o?.status))},null,8,pP)]),n("div",fP,[o?.isAdmin?(a(),l("span",hP,"Admin")):f("v-if",!0),o?.isAdmin?f("v-if",!0):(a(),l("span",mP,"\u2014"))]),n("div",gP,[n("div",vP,[t[46]||(t[46]=n("button",{class:"btn btn-icon-dots",type:"button","data-toggle":"dropdown","aria-haspopup":"true","aria-expanded":"false","aria-label":"Actions"},[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#project-icon-more"})])],-1)),n("div",yP,[n("a",{class:"dropdown-item",href:e.safeUrl("/admin/users/"+o?.username)},[...t[41]||(t[41]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#project-icon-eye"})],-1),g(" View details",-1)])],8,bP),n("a",{class:"dropdown-item",href:e.safeUrl("/admin/repositories?owner="+o?.username)},[...t[42]||(t[42]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#project-type-repo"})],-1),g(" View repositories",-1)])],8,wP),t[45]||(t[45]=n("div",{class:"dropdown-divider"},null,-1)),D(n("a",{class:"dropdown-item text-danger",href:"#",onClick:ae(d=>e.banUser(o),["prevent"])},[...t[43]||(t[43]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-ban"})],-1),g(" Ban",-1)])],8,kP),[[Z,o?.status=="active"]]),D(n("a",{class:"dropdown-item",href:"#",onClick:ae(d=>e.activateUser(o),["prevent"])},[...t[44]||(t[44]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-check-circle"})],-1),g(" Activate",-1)])],8,CP),[[Z,o?.status=="removed"||o?.status=="banned"]])])])])],2))),256)),e.filteredUsers?.length==0?(a(),l("div",EP,[...t[47]||(t[47]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#project-icon-inbox"})],-1),n("span",null,"No users match the current filters.",-1)])])):f("v-if",!0)]),n("div",SP,[t[52]||(t[52]=n("span",{"aria-hidden":"true"},null,-1)),e.totalPage>1?(a(),l("div",NP,[n("button",{class:"btn btn-sm",onClick:t[12]||(t[12]=o=>e.query.page=Math.max(1,e.query.page-1)),disabled:e.query?.page<=1},[...t[48]||(t[48]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-chevron-left"})],-1),g(" Previous",-1)])],8,RP),D(n("input",{type:"number",class:"form-control form-control-sm",min:"1",style:{width:"56px"},max:e.totalPage},null,8,AP),[[s,{state:e.viewState,set:o=>{e.query.page=o},value:e.query?.page,form:null,options:{}}]]),n("span",null,"of "+c(e.totalPage),1),n("button",{class:"btn btn-sm",onClick:t[13]||(t[13]=o=>e.query.page=Math.min(e.totalPage,e.query.page+1)),disabled:e.query?.page>=e.totalPage},[...t[49]||(t[49]=[g("Next ",-1),n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-chevron-right"})],-1)])],8,PP)])):f("v-if",!0),n("span",DP,[t[51]||(t[51]=n("label",null,"Per page",-1)),D((a(),l("select",TP,[...t[50]||(t[50]=[n("option",{value:"10"},"10",-1),n("option",{value:"25"},"25",-1),n("option",{value:"50"},"50",-1),n("option",{value:"100"},"100",-1)])])),[[s,{state:e.viewState,set:o=>{e.query.limit=o},value:e.query?.limit,form:null,options:{}}]])])])])}var OP={class:"anonymize-landing"},IP={class:"anonymize-landing-inner"},MP={class:"form-group mt-4 mb-2"},VP={class:"source-url-label-row"},qP={key:0,class:"repo-access","aria-label":"GitHub access"},_P={key:0,class:"repo-access-switch",role:"group","aria-label":"Repository connection"},LP=["aria-pressed","disabled"],$P=["aria-pressed","disabled"],FP={key:1,class:"connection-badge"},UP={class:"landing-url-row"},BP={id:"sourceUrl-landing",onblur:"this.scrollLeft=0",type:"text",class:"form-control form-control-lg",placeholder:"https://github.com/owner/repository"},zP=["aria-disabled"],HP={key:0,class:"text-danger",role:"alert"},jP={class:"repo-picker","aria-labelledby":"repo-picker-title"},GP={class:"repo-picker-head"},WP={class:"repo-picker-title"},KP={key:0,class:"repo-picker-count","aria-live":"polite"},YP={key:0,class:"repo-picker-list","aria-busy":"true","aria-label":"Loading your repositories"},XP={class:"repo-picker-row is-skeleton","aria-hidden":"true"},JP={key:1,class:"repo-picker-list"},QP=["title"],ZP={class:"repo-picker-owner"},xP={class:"repo-picker-repo"},eD=["onClick","aria-label"],tD={key:2,class:"repo-picker-state"},nD={key:3,class:"repo-picker-state"},sD={key:4,class:"repo-picker-state",role:"alert"},oD={key:5,class:"repo-access-details","aria-label":"GitHub access"},iD={class:"repo-access-main"},rD={class:"repo-access-controls"},aD={key:0,class:"access-q"},lD={key:2,class:"connection-link",href:"/connections"},dD={class:"repo-access-note"},uD={key:0},cD={class:"anonymize-workspace"},pD={class:"anonymize-topbar"},fD={class:"anonymize-topbar-inner"},hD={class:"paper-crumbs"},mD={class:"here"},gD={class:"anonymize-topbar-head"},vD={class:"paper-page-title anonymize-topbar-title"},yD={key:0},bD={key:1},wD={class:"paper-page-lede anonymize-topbar-lede"},kD={key:0,class:"task-trail flow-trail","aria-label":"Anonymization steps"},CD={key:0,class:"alert alert-info",role:"status"},ED={key:1,class:"alert alert-info",role:"status"},SD={key:1},ND={class:"anonymize-mobile-tabs",role:"tablist","aria-label":"Anonymization workspace"},RD=["aria-selected","tabindex"],AD=["aria-selected","tabindex"],PD={class:"anonymize-split"},DD=["role","aria-labelledby"],TD={class:"form needs-validation paper-settings-main",name:"anonymize",novalidate:""},OD={class:"anonymize-fields"},ID={class:"paper-settings-section"},MD={class:"form-group"},VD={class:"source-url-label-row"},qD={key:0,class:"repo-access","aria-label":"GitHub access"},_D={key:0,class:"repo-access-switch",role:"group","aria-label":"Repository connection"},LD=["aria-pressed","disabled"],$D=["aria-pressed","disabled"],FD={key:1,class:"connection-badge"},UD=["disabled"],BD={key:0,class:"source-summary"},zD={class:"invalid-feedback"},HD={class:"invalid-feedback"},jD={class:"invalid-feedback"},GD={class:"invalid-feedback"},WD={key:0,class:"repo-access-details","aria-label":"Previous repository configuration"},KD={key:0,class:"form-group"},YD=["value"],XD={key:1},JD={class:"repo-access-controls"},QD=["href"],ZD={key:1,class:"repo-access-details","aria-label":"GitHub access"},xD={class:"repo-access-main"},eT={class:"repo-access-controls"},tT={key:0,class:"access-q"},nT={key:2,class:"connection-link",href:"/connections"},sT={class:"repo-access-note"},oT={key:0},iT={key:1},rT=["open"],aT={key:0,class:"repair-step"},lT=["disabled"],dT={key:0,role:"status"},uT={class:"repair-step"},cT={key:0,role:"status"},pT={key:3,class:"form-grid-2"},fT={class:"form-group"},hT={class:"input-group"},mT={class:"form-control",id:"branch",name:"branch"},gT=["textContent","value"],vT={class:"input-group-append"},yT={class:"form-group"},bT=["disabled"],wT={class:"invalid-feedback"},kT={class:"invalid-feedback"},CT={class:"form-check-input",type:"checkbox",id:"update",name:"update","aria-describedby":"update-help"},ET={class:"form-check-label",for:"update"},ST={key:0,class:"paid-tag"},NT={key:0,class:"form-text text-muted",id:"update-help"},RT={key:1,class:"form-text text-muted auto-update-paid",id:"update-help"},AT={class:"paper-settings-section"},PT={class:"form-group"},DT=["disabled"],TT={class:"form-text text-muted anon-url-echo"},OT={class:"anon-url-id"},IT={class:"invalid-feedback"},MT={class:"form-group"},VT=["disabled"],qT={class:"form-text text-muted anon-url-echo"},_T={class:"anon-url-id"},LT={class:"invalid-feedback"},$T={class:"form-group"},FT=["disabled"],UT={class:"form-text text-muted anon-url-echo"},BT={class:"anon-url-id"},zT={class:"invalid-feedback"},HT={class:"form-group"},jT=["rows"],GT={class:"redaction-syntax"},WT={class:"form-text text-muted"},KT=["onClick"],YT={key:0,class:"term-hint-more"},XT={class:"invalid-feedback"},JT={class:"preserve-row"},QT={class:"preserve-row-text"},ZT={class:"preserve-row-value"},xT=["disabled"],e3={class:"preserve-tree"},t3={key:0,class:"preserve-status"},n3={key:1,class:"paper-inline-alert paper-inline-alert-error",role:"alert"},s3=["aria-expanded","aria-label","onClick"],o3={key:1,class:"preserve-caret-space"},i3=["id","aria-label","checked",".indeterminate","disabled","onChange"],r3=["for","onClick"],a3={key:2,class:"preserve-note"},l3={key:0,class:"preserve-status"},d3={key:0,class:"preserve-status"},u3=["open"],c3={class:"preserve-foot"},p3={class:"preserve-count","aria-live":"polite"},f3={class:"preserve-actions"},h3={class:"paper-settings-section"},m3={class:"form-check"},g3={class:"form-check-input",type:"checkbox",id:"link",name:"link"},v3={class:"form-check"},y3={class:"form-check-input",type:"checkbox",id:"image",name:"image"},b3={class:"form-check"},w3={class:"form-check-input",type:"checkbox",id:"pdf",name:"pdf"},k3={class:"form-check"},C3={class:"form-check-input",type:"checkbox",id:"notebook",name:"notebook"},E3={class:"form-check"},S3=["disabled"],N3={key:0,class:"form-text text-muted"},R3={key:1,class:"form-text text-muted"},A3={key:0,class:"form-text text-muted"},P3={class:"form-check"},D3={class:"form-check-input",type:"checkbox",id:"title-gist",name:"title-gist"},T3={class:"form-check"},O3={class:"form-check-input",type:"checkbox",id:"content-gist",name:"content-gist"},I3={class:"form-check"},M3={class:"form-check-input",type:"checkbox",id:"comments-gist",name:"comments-gist"},V3={class:"form-check"},q3={class:"form-check-input",type:"checkbox",id:"username-gist",name:"username-gist"},_3={class:"form-check"},L3={class:"form-check-input",type:"checkbox",id:"date-gist",name:"date-gist"},$3={class:"form-check"},F3={class:"form-check-input",type:"checkbox",id:"origin-gist",name:"origin-gist"},U3={class:"form-check"},B3={class:"form-check-input",type:"checkbox",id:"title",name:"title"},z3={class:"form-check"},H3={class:"form-check-input",type:"checkbox",id:"body",name:"body"},j3={class:"form-check"},G3={class:"form-check-input",type:"checkbox",id:"diff",name:"diff"},W3={class:"form-check"},K3={class:"form-check-input",type:"checkbox",id:"comments",name:"comments"},Y3={class:"form-check"},X3={class:"form-check-input",type:"checkbox",id:"username",name:"username"},J3={class:"form-check"},Q3={class:"form-check-input",type:"checkbox",id:"date",name:"date"},Z3={class:"form-check"},x3={class:"form-check-input",type:"checkbox",id:"origin",name:"origin"},eO={class:"paper-settings-section hosting-settings",id:"repository-hosting","aria-labelledby":"hosting-heading"},tO={class:"form-group conference-field"},nO=["href"],sO={class:"invalid-feedback"},oO={class:"form-text text-muted"},iO={key:0,class:"hosting-usage"},rO={key:0},aO={key:1},lO={key:2},dO={key:1,class:"hosting-limit auto-update-note",role:"status"},uO={key:2,class:"hosting-payment"},cO={key:0,class:"hosting-limit",role:"status"},pO={key:1,class:"hosting-options"},fO={class:"hosting-options-title"},hO=["value","checked","onChange"],mO={class:"hosting-option-body"},gO={key:0,class:"hosting-cycle billing-toggle",role:"radiogroup","aria-label":"Billing frequency"},vO=["aria-checked","onClick"],yO={key:0,class:"billing-toggle-save"},bO={class:"hosting-option-price"},wO={key:2,role:"status"},kO={key:3,class:"hosting-terms"},CO={key:4,class:"hosting-terms"},EO={key:5,class:"capacity-options"},SO=["disabled"],NO={key:3,class:"hosting-subhead"},RO={class:"expiration-choices"},AO={class:"expiration-choice"},PO=["checked","disabled"],DO={key:0,class:"dated-options"},TO={key:0,class:"hosting-date"},OO=["min","max"],IO={key:0,class:"date-echo","aria-live":"polite"},MO={class:"invalid-feedback"},VO={class:"invalid-feedback"},qO={class:"hosting-property"},_O={key:1,class:"expiration-choice"},LO=["checked","disabled"],$O={key:0},FO={key:4,class:"form-text text-muted"},UO={key:5,class:"inline-hosting"},BO={key:0,role:"alert",class:"text-danger"},zO={key:1,role:"alert",class:"text-danger"},HO=["disabled"],jO={key:2,role:"status"},GO={key:3,role:"status",class:"form-text text-muted"},WO={key:4,class:"hosting-terms"},KO={key:5,class:"hosting-terms"},YO={key:6,class:"repository-pass"},XO=["disabled","onClick"],JO={class:"paper-settings-section"},QO={class:"form-group"},ZO={style:{position:"relative"}},xO={type:"text",id:"coauthorSearch",class:"form-control",placeholder:"Search GitHub username\u2026",autocomplete:"off"},eI={class:"dropdown-menu show",style:{display:"block","max-height":"220px","overflow-y":"auto",width:"100%"}},tI=["onClick"],nI=["src"],sI=["textContent"],oI=["textContent"],iI={class:"coauthor-list"},rI={class:"coauthor-row d-flex align-items-center",style:{padding:"6px 0",gap:"8px"}},aI=["src"],lI=["textContent","href"],dI=["onClick"],uI={class:"form-text text-muted"},cI=["textContent"],pI={class:"anonymize-submit-bar"},fI=["disabled"],hI=["disabled"],mI=["disabled"],gI=["disabled"],vI=["disabled"],yI=["disabled"],bI={key:5,class:"submit-reason",role:"status"},wI={key:6,class:"submit-reason",role:"status"},kI={key:7,class:"checkout-return-note"},CI={key:8,class:"draft-status",role:"status"},EI={key:9,class:"draft-status"},SI=["role","aria-labelledby"],NI={class:"rp-caption"},RI=["aria-expanded"],AI=["title"],PI={class:"redact-slot","aria-hidden":"true"},DI={key:2,class:"rp-count rp-count-none"},TI=["href"],OI=["aria-pressed"],II={class:"rp-open-icon",viewBox:"0 0 16 16","aria-hidden":"true"},MI={key:0,d:"M9.5 2.5h4v4M13.5 2.5 9 7M6.5 13.5h-4v-4M2.5 13.5 7 9"},VI={key:1,d:"M13.5 6.5h-4v-4M9.5 6.5 14 2M2.5 9.5h4v4M6.5 9.5 2 14"},qI={class:"rp-window"},_I={class:"rp-chrome","aria-hidden":"true"},LI={class:"rp-url"},$I={class:"rp-bar","aria-hidden":"true"},FI={key:0,class:"rp-bar-id"},UI={key:1,class:"rp-bar-kind"},BI={class:"leftCol-head"},zI={class:"leftCol-body"},HI={key:0,class:"rp-state rp-loading",role:"status"},jI={class:"rp-state-text"},GI={class:"rp-state rp-error",role:"alert"},WI={class:"rp-state-actions"},KI={key:1,class:"btn btn-outline-ink btn-sm",href:"/connections"},YI={key:2,class:"rp-state rp-error",role:"alert"},XI={class:"rp-state-actions"},JI={class:"rp-state rp-error",role:"alert"},QI={class:"rp-state-actions"},ZI={class:"rp-state rp-error",role:"alert"},xI={class:"rp-state-actions"},e5={key:5,class:"rp-state rp-empty"},t5={key:7,class:"anonymize-preview-body"},n5={class:"d-flex w-100 justify-content-between align-items-center flex-wrap"},s5={class:"pr-title mb-1"},o5={key:0},i5=["textContent"],r5={key:0},a5={key:1},l5={key:2},d5={class:"pr-comments mt-3"},u5={class:"pr-comment"},c5={class:"pr-comment-head"},p5=["textContent"],f5={key:0,class:"pr-comment-date"},h5={key:3},m5={class:"pr-comments"},g5={class:"pr-comment"},v5={class:"pr-comment-head"},y5={key:0,class:"pr-comment-author"},b5=["textContent"],w5=["textContent"],k5={key:0,class:"pr-comment-body"},C5={key:8,class:"anonymize-preview-body"},E5={class:"d-flex w-100 justify-content-between align-items-center flex-wrap"},S5={class:"pr-title mb-1"},N5={key:0},R5=["textContent"],A5={key:0},P5={key:1,class:"pr-body"},D5={key:2,class:"paper-tabs",role:"tablist"},T5=["aria-selected","tabindex"],O5=["aria-selected","tabindex"],I5=["textContent"],M5={key:3,class:"anonymize-preview-status"},V5={class:"paper-tab-content"},q5={key:0,role:"tabpanel",id:"preview-pr-diff-panel","aria-labelledby":"preview-pr-diff-tab"},_5=["innerHTML"],L5={key:1,role:"tabpanel",id:"preview-pr-comments-panel","aria-labelledby":"preview-pr-comments-tab"},$5={class:"pr-comments"},F5={class:"pr-comment"},U5={class:"pr-comment-head"},B5={key:0,class:"pr-comment-author"},z5=["textContent"],H5=["textContent"],j5={key:0,class:"pr-comment-body"},G5={key:9,class:"rp-more"},W5=["href"],K5={key:2,class:"rp-more-btn is-hint","aria-hidden":"true"};function ap(e,t){let s=Xe("tree"),i=Xe("partial-view"),o=Xe("gist-file"),r=Xe("markdown"),d=Pe("field"),p=Pe("form");return a(),l("div",{class:A(["anonymize-page h-100",{"mobile-preview-active":e.mobilePane==="preview","preview-expanded":e.previewExpanded}])},[f(" ===== STATE 1: No URL \u2014 centered input ===== "),D(n("div",OP,[n("div",IP,[t[70]||(t[70]=Ce('
My work \xA0/\xA0 New anonymization

New anonymization

Paste a repository, pull request, or gist URL, or pick one of your repositories. You\u2019ll choose the terms to redact next.

  1. 1. Repository
  2. 2. Review and hosting
  3. 3. Review link
',2)),n("div",MP,[n("div",VP,[t[61]||(t[61]=n("label",{class:"paper-field-label",for:"sourceUrl-landing"},"Source URL",-1)),!e.sourceUrl&&e.githubConnections?.appEnabled&&e.githubConnections.appConnected&&e.githubConnections.oauthConnected?(a(),l("aside",qP,[!e.isUpdate&&e.detectedType!=="gist"?(a(),l("div",_P,[n("button",{type:"button","aria-pressed":e.githubConnection==="github-app",disabled:e.githubConnection==="github-app",onClick:t[0]||(t[0]=u=>e.chooseGitHubConnection("github-app"))},[...t[60]||(t[60]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-shield"})],-1),g(),n("span",{class:"sr-only"},"Read-only ",-1),g("GitHub App",-1)])],8,LP),n("button",{type:"button","aria-pressed":e.githubConnection==="oauth",disabled:e.githubConnection==="oauth",onClick:t[1]||(t[1]=u=>e.chooseGitHubConnection("oauth"))},"Legacy OAuth",8,$P)])):f("v-if",!0),e.isUpdate||e.detectedType==="gist"?(a(),l("span",FP,c((e.detectedType==="gist"?e.githubConnections?.gistConnection==="github-app":e.githubConnection==="github-app")?"Read-only GitHub App":"Legacy OAuth"),1)):f("v-if",!0)])):f("v-if",!0)]),n("div",UP,[D(n("input",BP,null,512),[[d,{state:e.viewState,set:u=>{e.sourceUrl=u},value:e.sourceUrl,form:null,options:{debounce:{default:1e3,blur:0,click:0},updateOn:"default blur click"},change:()=>{e.urlSelected()}}]]),n("button",{type:"button",class:"btn btn-primary landing-continue","aria-disabled":e.sourceUrl?.trim()?null:"true",onClick:t[2]||(t[2]=u=>e.sourceUrl?.trim()&&e.urlSelected())},"Continue",8,zP)])]),e.sourceUrlError?(a(),l("p",HP,c(e.sourceUrlError),1)):f("v-if",!0),t[71]||(t[71]=n("small",{class:"form-text landing-help",style:{color:"var(--ink-muted)"}}," Repository, pull request (\u2026/pull/42) and gist (gist.github.com/\u2026) URLs are all accepted. ",-1)),n("section",jP,[n("div",GP,[n("div",WP,[t[63]||(t[63]=n("h2",{id:"repo-picker-title"},"Your repositories",-1)),e.userReposStatus==="ready"&&e.userRepos.length>0?(a(),l("span",KP,[e.userRepoFilter&&e.filteredUserRepos().length!==e.userRepos.length?(a(),l(q,{key:0},[g(c(e.filteredUserRepos().length)+" of ",1)],64)):f("v-if",!0),g(c(e.userRepos.length)+" "+c(e.userRepos.length===1?"repository":"repositories"),1),t[62]||(t[62]=n("span",{class:"repo-picker-more"},[n("span",{class:"repo-picker-more-sep"}," \xB7 "),g("scroll for more")],-1))])):f("v-if",!0)]),e.userReposStatus==="ready"&&e.userRepos.length>0?D((a(),l("input",{key:0,type:"search",class:"form-control repo-picker-filter",placeholder:"Filter\u2026","aria-label":"Filter your repositories",autocomplete:"off","onUpdate:modelValue":t[3]||(t[3]=u=>e.userRepoFilter=u)},null,512)),[[pt,e.userRepoFilter]]):f("v-if",!0)]),e.userReposStatus==="loading"||e.userReposStatus==="idle"?(a(),l("ul",YP,[(a(),l(q,null,Q([1,2,3,4],(u,y)=>n("li",XP,[n("span",{class:"skeleton skeleton-line",style:Ie({width:34+u*9+"%"})},null,4)])),64))])):f("v-if",!0),e.userReposStatus==="ready"&&e.filteredUserRepos().length>0?(a(),l("ul",JP,[(a(!0),l(q,null,Q(e.filteredUserRepos(),(u,y)=>(a(),l("li",{key:u.id||u.fullName,class:"repo-picker-row"},[t[65]||(t[65]=n("svg",{class:"project-type-svg","aria-hidden":"true"},[n("use",{href:"#project-type-repo"})],-1)),n("span",{class:"repo-picker-name",title:u.fullName},[n("span",ZP,[g(c(u.fullName.split("/")[0]),1),t[64]||(t[64]=n("span",{class:"repo-picker-slash"},"/",-1))]),n("span",xP,c(u.fullName.split("/").slice(1).join("/")),1)],8,QP),n("button",{type:"button",class:"btn btn-outline-ink btn-sm repo-picker-select",onClick:m=>e.selectUserRepo(u),"aria-label":"Select "+u.fullName},"Select",8,eD)]))),128))])):f("v-if",!0),e.userReposStatus==="ready"&&e.userRepos.length>0&&e.filteredUserRepos().length===0?(a(),l("p",tD,"No repository matches \u201C"+c(e.userRepoFilter)+"\u201D.",1)):f("v-if",!0),e.userReposStatus==="ready"&&e.userRepos.length===0?(a(),l("p",nD,"No repositories found for your GitHub account. Paste a URL above, or grant access below.")):f("v-if",!0),e.userReposStatus==="error"?(a(),l("p",sD,[t[66]||(t[66]=g("Your repositories could not be loaded. ",-1)),n("button",{type:"button",class:"task-text-button",onClick:t[4]||(t[4]=u=>e.loadUserRepos(!0))},"Try again")])):f("v-if",!0),!e.sourceUrl&&e.githubConnections?.appEnabled&&e.githubConnections.appConnected?(a(),l("aside",oD,[n("div",iD,[n("div",rD,[e.detectedType!=="gist"&&e.githubConnection!=="oauth"?(a(),l("span",aD,"Repository not listed?")):f("v-if",!0),e.detectedType!=="gist"&&e.githubConnection!=="oauth"?(a(),l("button",{key:1,type:"button",class:"btn btn-outline-ink",onClick:t[5]||(t[5]=u=>e.grantGitHubAccess())},[...t[67]||(t[67]=[g("Manage GitHub access ",-1),n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-external-link"})],-1)])])):f("v-if",!0),e.isUpdate||e.detectedType==="gist"||e.githubConnection==="oauth"?(a(),l("a",lD,[...t[68]||(t[68]=[g("Manage GitHub access ",-1),n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-external-link"})],-1)])])):f("v-if",!0)])]),n("div",dD,[e.error&&e.detectedType!=="gist"&&e.githubConnection==="github-app"?(a(),l("span",uD,"Signing in does not grant access to private repositories. Use Manage GitHub access to select this repository, then return here. Organization access may require administrator approval.")):f("v-if",!0),t[69]||(t[69]=n("span",null,[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-info"})]),g(" Anonymized content is public, even from private repositories.")],-1))])])):f("v-if",!0)])])],512),[[Z,!e.workspaceOpen&&!e.isUpdate]]),f(" ===== STATE 2: URL provided \u2014 form (left) + preview (right) ===== "),D(n("div",cD,[n("header",pD,[n("div",fD,[n("div",hD,[t[72]||(t[72]=n("a",{href:"/dashboard"},"My work",-1)),t[73]||(t[73]=g(" \xA0/\xA0 ",-1)),n("span",mD,c(e.isUpdate?"Edit anonymization":"New anonymization"),1)]),n("div",gD,[n("h1",vD,[e.isUpdate?f("v-if",!0):(a(),l("span",yD,"New anonymization")),e.isUpdate?(a(),l("span",bD,"Edit anonymization")):f("v-if",!0)]),D(n("span",{class:A(["type-badge",{"type-repo":e.detectedType==="repo","type-pr":e.detectedType==="pr","type-gist":e.detectedType==="gist"}])},c(e.detectedType==="repo"?"Repository":e.detectedType==="pr"?"Pull request":"Gist"),3),[[Z,e.detectedType]])]),n("p",wD,c(e.isUpdate?"Changes apply to the existing anonymous link; reviewers keep the same URL.":"Choose the terms to redact, what reviewers see, and when the link expires."),1),e.isUpdate?f("v-if",!0):(a(),l("ol",kD,[...t[74]||(t[74]=[n("li",null,"1. Repository",-1),n("li",{"aria-current":"step"},"2. Review and hosting",-1),n("li",null,"3. Review link",-1)])]))])]),e.detectedType==="gist"&&e.gistAppRequired?(a(),l("aside",CD,[t[75]||(t[75]=n("p",null,"Reconnect your GitHub account to read this gist. Your draft will be restored when you return.",-1)),n("button",{type:"button",class:"btn btn-ink",onClick:t[6]||(t[6]=u=>e.connectGistApp())},"Connect GitHub App to access gists")])):f("v-if",!0),e.detectedType==="gist"&&e.gistOAuthRequired?(a(),l("aside",ED,[t[76]||(t[76]=n("p",null,"Connect GitHub OAuth to access gists. Your account and existing anonymizations stay the same, and your draft will be restored when you return.",-1)),t[77]||(t[77]=n("p",null,"GitHub's legacy OAuth connection includes write access to private repositories.",-1)),e.githubConnections?.oauthEnabled?(a(),l("button",{key:0,type:"button",class:"btn btn-ink",onClick:t[7]||(t[7]=u=>e.connectGistOAuth())},"Connect GitHub OAuth to access gists")):(a(),l("p",SD,"GitHub OAuth is currently unavailable. Please try again later."))])):f("v-if",!0),n("nav",ND,[n("button",{id:"workspace-settings-tab",role:"tab",type:"button","aria-selected":e.mobilePane==="settings","aria-controls":"workspace-settings",tabindex:e.mobilePane==="settings"?0:-1,onKeydown:t[8]||(t[8]=u=>e.previewTabKeydown(u)),onClick:t[9]||(t[9]=u=>e.selectMobilePane("settings"))},[...t[78]||(t[78]=[n("span",{class:"tab-label"},"Settings",-1)])],40,RD),n("button",{id:"workspace-preview-tab",role:"tab",type:"button","aria-selected":e.mobilePane==="preview","aria-controls":"workspace-preview",tabindex:e.mobilePane==="preview"?0:-1,onKeydown:t[10]||(t[10]=u=>e.previewTabKeydown(u)),onClick:t[11]||(t[11]=u=>e.selectMobilePane("preview"))},[...t[79]||(t[79]=[n("span",{class:"tab-label"},"Reviewer preview",-1)])],40,AD)]),n("div",PD,[f(" Form column (left) "),n("div",{id:"workspace-settings",role:e.mobileWorkspace?"tabpanel":null,"aria-labelledby":e.mobileWorkspace?"workspace-settings-tab":null,class:"anonymize-form-col overflow-auto"},[D((a(),l("form",TD,[n("div",OD,[n("section",ID,[t[99]||(t[99]=n("h2",{class:"paper-section-eyebrow"},"Source & access",-1)),n("div",MD,[n("div",VD,[t[81]||(t[81]=n("label",{class:"paper-field-label",for:"sourceUrl"},"Source URL",-1)),e.sourceUrl&&e.githubConnections?.appEnabled&&e.githubConnections.appConnected&&e.githubConnections.oauthConnected?(a(),l("aside",qD,[!e.isUpdate&&e.detectedType!=="gist"?(a(),l("div",_D,[n("button",{type:"button","aria-pressed":e.githubConnection==="github-app",disabled:e.githubConnection==="github-app",onClick:t[12]||(t[12]=u=>e.chooseGitHubConnection("github-app"))},[...t[80]||(t[80]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-shield"})],-1),g(),n("span",{class:"sr-only"},"Read-only ",-1),g("GitHub App",-1)])],8,LD),n("button",{type:"button","aria-pressed":e.githubConnection==="oauth",disabled:e.githubConnection==="oauth",onClick:t[13]||(t[13]=u=>e.chooseGitHubConnection("oauth"))},"Legacy OAuth",8,$D)])):f("v-if",!0),e.isUpdate||e.detectedType==="gist"?(a(),l("span",FD,c((e.detectedType==="gist"?e.githubConnections?.gistConnection==="github-app":e.githubConnection==="github-app")?"Read-only GitHub App":"Legacy OAuth"),1)):f("v-if",!0)])):f("v-if",!0)]),D(n("input",{type:"text",class:A(["form-control",{"is-invalid":e.anonymize?.sourceUrl?.invalid}]),name:"sourceUrl",id:"sourceUrl",onblur:"this.scrollLeft=0",disabled:e.isUpdate&&e.detectedType!=="repo",placeholder:"Paste a GitHub repo or pull request URL"},null,10,UD),[[d,{state:e.viewState,set:u=>{e.sourceUrl=u},value:e.sourceUrl,form:"anonymize",options:{debounce:{default:1e3,blur:0,click:0},updateOn:"default blur click"},change:()=>{e.urlSelected()}}]]),e.sourceSummary()&&!e.anonymize?.sourceUrl?.invalid?(a(),l("p",BD,[t[82]||(t[82]=n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-check"})],-1)),g(c(e.sourceSummary()),1)])):f("v-if",!0),D(n("div",zD," Please provide a valid GitHub URL. ",512),[[Z,e.anonymize?.sourceUrl?.errors?.github]]),D(n("div",HD," Not accessible. The organization may restrict access. ",512),[[Z,e.anonymize?.sourceUrl?.errors?.access]]),D(n("div",jD," Does not exist or is not accessible. ",512),[[Z,e.anonymize?.sourceUrl?.errors?.missing]]),D(n("div",GD," Already anonymized. ",512),[[Z,e.anonymize?.sourceUrl?.errors?.used]])]),!e.isUpdate&&e.previousConfigurations.length?(a(),l("aside",WD,[t[84]||(t[84]=n("p",{role:"status"},"You have already anonymized this repository. Use the existing configuration to keep its anonymous link and avoid creating another repository.",-1)),e.previousConfigurations.length>1?(a(),l("div",KD,[t[83]||(t[83]=n("label",{class:"paper-field-label",for:"previousConfiguration"},"Previous anonymization",-1)),D(n("select",{id:"previousConfiguration",class:"form-control","onUpdate:modelValue":t[14]||(t[14]=u=>e.previousConfigurationId=u)},[(a(!0),l(q,null,Q(e.previousConfigurations,u=>(a(),l("option",{key:u.repoId,value:u.repoId},c(u.repoId),9,YD))),128))],512),[[Ut,e.previousConfigurationId]])])):(a(),l("p",XD,c(e.previousConfigurationId),1)),t[85]||(t[85]=n("p",null,"You can review and update its settings before saving.",-1)),n("div",JD,[n("a",{class:"btn btn-ink",href:e.existingConfigurationUrl()},"Use existing configuration",8,QD),n("button",{type:"button",class:"btn btn-outline-ink",onClick:t[15]||(t[15]=u=>e.previousConfigurations=[])},"Create a separate one")])])):f("v-if",!0),e.sourceUrl&&e.githubConnections?.appEnabled&&e.githubConnections.appConnected?(a(),l("aside",ZD,[n("div",xD,[n("div",eT,[e.detectedType!=="gist"&&e.githubConnection!=="oauth"&&!e.details?(a(),l("span",tT,"Repository not listed?")):f("v-if",!0),e.detectedType!=="gist"&&e.githubConnection!=="oauth"&&!e.details?(a(),l("button",{key:1,type:"button",class:"btn btn-outline-ink",onClick:t[16]||(t[16]=u=>e.grantGitHubAccess())},[...t[86]||(t[86]=[g("Manage GitHub access ",-1),n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-external-link"})],-1)])])):f("v-if",!0),e.isUpdate||e.detectedType==="gist"||e.githubConnection==="oauth"?(a(),l("a",nT,[...t[87]||(t[87]=[g("Manage GitHub access ",-1),n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-external-link"})],-1)])])):f("v-if",!0)])]),n("div",sT,[e.error&&e.detectedType!=="gist"&&e.githubConnection==="github-app"?(a(),l("span",oT,"Signing in does not grant access to private repositories. Use Manage GitHub access to select this repository, then return here. Organization access may require administrator approval.")):f("v-if",!0),e.detectedType!=="gist"&&e.githubConnection!=="oauth"&&!e.details?(a(),l("span",iT,"Select repositories on GitHub, then return here.")):f("v-if",!0),t[88]||(t[88]=n("span",null,[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-info"})]),g(" Selected content will be published, including content from private repositories.")],-1))])])):f("v-if",!0),e.isUpdate&&e.detectedType==="repo"&&e.role==="owner"&&e.sourceUrl==="https://github.com/"+e._originalFullName?(a(),l("details",{key:2,class:"repair-disclosure",open:!!(e.error||e.accessRepairMessage||e.reconnectRepositoryId)},[t[92]||(t[92]=n("summary",null,"Connection problems?",-1)),e.accessRepairAllowed&&e.githubConnections?.appEnabled&&e.githubConnection==="github-app"&&e.sourceUrl==="https://github.com/"+e._originalFullName?(a(),l("div",aT,[t[90]||(t[90]=n("p",null,"If this repository became private or its App installation changed, repair its access here. This keeps the same anonymous URL and published commit.",-1)),n("button",{type:"button",class:"btn btn-outline-ink",disabled:e.repairingGitHubAccess,onClick:t[17]||(t[17]=u=>e.repairGitHubAccess())},"Repair GitHub access",8,lT),n("button",{type:"button",class:"btn btn-outline-ink",onClick:t[18]||(t[18]=u=>e.grantGitHubAccess())},[...t[89]||(t[89]=[g("Manage GitHub access ",-1),n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-external-link"})],-1)])]),e.accessRepairMessage?(a(),l("p",dT,c(e.accessRepairMessage),1)):f("v-if",!0)])):f("v-if",!0),n("div",uT,[t[91]||(t[91]=n("p",null,"If you deleted and recreated this repository, reconnect it before choosing a branch.",-1)),n("button",{type:"button",class:"btn btn-outline-ink",onClick:t[19]||(t[19]=u=>e.reconnectSource())},"Reconnect source repository"),e.reconnectRepositoryId?(a(),l("p",cT,"Source reloaded. Review the branch, commit, and anonymization preview, then save to replace the published snapshot.")):f("v-if",!0)])],8,rT)):f("v-if",!0),e.detectedType==="repo"?(a(),l("div",pT,[n("div",fT,[t[94]||(t[94]=n("label",{class:"paper-field-label",for:"branch"},"Branch",-1)),n("div",hT,[D((a(),l("select",mT,[(a(!0),l(q,null,Q(e.branches,(u,y)=>(a(),l("option",{textContent:c(u?.name),value:u?.name},null,8,gT))),256))])),[[d,{state:e.viewState,set:u=>{e.source.branch=u},value:e.source?.branch,form:"anonymize",options:{}}]]),n("div",vT,[n("button",{class:"btn btn-icon refresh-branches",type:"button",title:"Refresh branches",onClick:t[20]||(t[20]=u=>e.getBranches(!0)),"aria-label":"Refresh branches"},[...t[93]||(t[93]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-refresh"})],-1)])])])])]),n("div",yT,[t[95]||(t[95]=n("label",{class:"paper-field-label",for:"commit"},"Commit",-1)),D(n("input",{class:A(["form-control",{"is-invalid":e.anonymize?.commit?.invalid}]),id:"commit",disabled:e.options.update,name:"commit",pattern:"[a-fA-Z0-9]{6,}",required:""},null,10,bT),[[d,{state:e.viewState,set:u=>{e.source.commit=u},value:e.source?.commit,form:"anonymize",options:{}}]]),D(n("div",wT," The commit SHA is not valid. ",512),[[Z,e.anonymize?.commit?.errors?.pattern||e.anonymize?.commit?.errors?.required]]),D(n("div",kT," This commit no longer exists in the repository. Click refresh to get the latest. ",512),[[Z,e.anonymize?.commit?.errors?.exists]])])])):f("v-if",!0),D(n("div",{class:A(["form-check auto-update-check",{"is-paid":!e.liveUpdatesIncluded()}])},[D(n("input",CT,null,512),[[d,{state:e.viewState,set:u=>{e.options.update=u},value:e.options?.update,form:"anonymize",options:{}}]]),n("label",ET,[t[96]||(t[96]=g("Auto-update from GitHub",-1)),e.liveUpdatesIncluded()?f("v-if",!0):(a(),l("span",ST,"Paid"))]),e.liveUpdatesIncluded()?(a(),l("small",NT,"Follows the latest version, at most once an hour.")):(a(),l("small",RT,[t[97]||(t[97]=g("Needs Live updates",-1)),e.liveUpdatesPrice()?(a(),l(q,{key:0},[g(" \xB7 "+c(e.liveUpdatesPrice()),1)],64)):f("v-if",!0),t[98]||(t[98]=g(", a Paper pack or an author subscription. ",-1)),n("a",{href:"#repository-hosting",onClick:t[21]||(t[21]=ae(u=>e.showHostingOptions(),["prevent"]))},"Hosting options")]))],2),[[Z,e.detectedType]])]),D(n("section",AT,[t[133]||(t[133]=n("h2",{class:"paper-section-eyebrow"},"Anonymization",-1)),D(n("div",PT,[t[104]||(t[104]=n("label",{class:"paper-field-label",for:"repoId"},"Anonymized repository ID",-1)),D(n("input",{type:"text",class:A(["form-control",{"is-invalid":e.anonymize?.repoId?.invalid}]),name:"repoId",id:"repoId",disabled:e.isUpdate},null,10,DT),[[d,{state:e.viewState,set:u=>{e.repoId=u},value:e.repoId,form:"anonymize",options:{debounce:{default:1e3,blur:0,click:0},updateOn:"default blur click"}}]]),n("small",TT,[t[100]||(t[100]=g("anonymous.4open.science/",-1)),t[101]||(t[101]=n("wbr",null,null,-1)),t[102]||(t[102]=g("r/",-1)),t[103]||(t[103]=n("wbr",null,null,-1)),n("span",OT,c(e.repoId),1)]),D(n("div",IT,"ID can only contain letters and numbers.",512),[[Z,e.anonymize?.repoId?.errors?.format]]),D(n("div",{class:"invalid-feedback"},c(e.repoId)+" is already used.",513),[[Z,e.anonymize?.repoId?.errors?.used]])],512),[[Z,e.detectedType==="repo"]]),D(n("div",MT,[t[109]||(t[109]=n("label",{class:"paper-field-label",for:"pullRequestId"},"Anonymized pull request ID",-1)),D(n("input",{type:"text",class:A(["form-control",{"is-invalid":e.anonymize?.pullRequestId?.invalid}]),name:"pullRequestId",id:"pullRequestId",disabled:e.isUpdate},null,10,VT),[[d,{state:e.viewState,set:u=>{e.pullRequestId=u},value:e.pullRequestId,form:"anonymize",options:{debounce:{default:1e3,blur:0,click:0},updateOn:"default blur click"}}]]),n("small",qT,[t[105]||(t[105]=g("anonymous.4open.science/",-1)),t[106]||(t[106]=n("wbr",null,null,-1)),t[107]||(t[107]=g("pr/",-1)),t[108]||(t[108]=n("wbr",null,null,-1)),n("span",_T,c(e.pullRequestId),1)]),D(n("div",LT,"ID can only contain letters and numbers.",512),[[Z,e.anonymize?.pullRequestId?.errors?.format]]),D(n("div",{class:"invalid-feedback"},c(e.pullRequestId)+" is already used.",513),[[Z,e.anonymize?.pullRequestId?.errors?.used]])],512),[[Z,e.detectedType==="pr"]]),D(n("div",$T,[t[114]||(t[114]=n("label",{class:"paper-field-label",for:"gistId"},"Anonymized gist ID",-1)),D(n("input",{type:"text",class:A(["form-control",{"is-invalid":e.anonymize?.gistId?.invalid}]),name:"gistId",id:"gistId",disabled:e.isUpdate},null,10,FT),[[d,{state:e.viewState,set:u=>{e.gistId=u},value:e.gistId,form:"anonymize",options:{debounce:{default:1e3,blur:0,click:0},updateOn:"default blur click"}}]]),n("small",UT,[t[110]||(t[110]=g("anonymous.4open.science/",-1)),t[111]||(t[111]=n("wbr",null,null,-1)),t[112]||(t[112]=g("gist/",-1)),t[113]||(t[113]=n("wbr",null,null,-1)),n("span",BT,c(e.gistId),1)]),D(n("div",zT,"ID can only contain letters and numbers.",512),[[Z,e.anonymize?.gistId?.errors?.format]]),D(n("div",{class:"invalid-feedback"},c(e.gistId)+" is already used.",513),[[Z,e.anonymize?.gistId?.errors?.used]])],512),[[Z,e.detectedType==="gist"]]),n("div",HT,[t[125]||(t[125]=n("label",{class:"paper-field-label",for:"terms"},"Terms to redact",-1)),D(n("textarea",{class:A(["form-control terms-input",{"is-invalid":e.anonymize?.terms?.invalid}]),id:"terms",name:"terms",rows:Math.min(14,Math.max(4,String(e.terms||"").split(` +Contact: jane.smith@mit.edu`,e.demoTerms="Jane Smith, Smith, MIT CSAIL, jane.smith@mit.edu",e.demoParts=function(){let p=(e.demoTerms||"").split(/[,\n]/).map(m=>m.trim()).filter(Boolean).sort((m,w)=>w.length-m.length),u=m=>m.replace(/[.*+?^${}()|[\]\\]/g,"\\$&");if(!p.length)return[{text:e.demoText}];let y=new RegExp("("+p.map(u).join("|")+")","gi"),h={},b=0;return(e.demoText||"").split(y).filter(m=>m!=="").map(m=>{let w=p.find(N=>N.toLowerCase()===m.toLowerCase());return w?(h[w.toLowerCase()]||(h[w.toLowerCase()]=++b),{text:String(h[w.toLowerCase()]),redacted:!0,original:m}):{text:m}})},e.demoCount=()=>e.demoParts().filter(p=>p.redacted).length,e.cards=[{key:"repositories",total:0,label:"repositories anonymized"},{key:"users",total:0,label:"researchers"},{key:"pageViews",total:0,label:"page views"},{key:"pullRequests",total:0,label:"pull requests"}],e.statsEmpty=()=>!!e.stat&&e.cards.every(p=>!p.total);function r(){t.get("/api/stat/").then(p=>{e.stat=p.data,e.cards[0].total=p.data.nbRepositories,e.cards[1].total=p.data.nbUsers,e.cards[2].total=p.data.nbPageViews,e.cards[3].total=p.data.nbPullRequests}).catch(()=>{})}r();function d(p){let u={series:p,bars:[],viewW:100,deltaToday:0,pctChange:0,pctAbs:0,isUp:!0};if(!p||p.length<2)return u;let y=new Array(p.length-1);for(let S=1;S=2){let S=y[h-2];S&&(u.pctChange=(u.deltaToday-S)/S*100)}return u.pctAbs=Math.round(Math.abs(u.pctChange)),u.isUp=u.pctChange>=0,u}e.history={repositories:d([]),users:d([]),pageViews:d([]),pullRequests:d([])},t.get("/api/stat/history?days=60").then(p=>{let u=p.data||[];e.history={repositories:d(u.map(y=>y.nbRepositories||0)),users:d(u.map(y=>y.nbUsers||0)),pageViews:d(u.map(y=>y.nbPageViews||0)),pullRequests:d(u.map(y=>y.nbPullRequests||0))}}).catch(()=>{})},Fc=function(e,t,s,i,o,r){let d=Ct();e.on("routeLeave",function(){$('[data-toggle="tooltip"]').tooltip("dispose")}),e.watch("user.status",()=>{e.user==null&&s.url("/")}),e.user==null&&s.url("/"),d.timeout(()=>{$('[data-toggle="tooltip"]').tooltip()},250),e.quotaExpanded=!1,e.closeQuota=()=>{e.quotaExpanded=!1,tt(()=>document.querySelector(".dashboard-quota > summary")?.focus())},Ut()(document,"click",C=>{e.quotaExpanded&&!C.target.closest?.(".dashboard-quota")&&(e.quotaExpanded=!1)}),e.filtersExpanded=!1,e.projectView="all",e.selectedProject=null,e.projectName="",e.nameSaving=!1,e.nameError="",e.nameMessage="",e.needsAttention=C=>C.status==="error"||C._broken||u(C.status)==="progress"&&C._stale,e.attentionCount=()=>e.dashboardTotals?.attention??e.items.filter(e.needsAttention).length,e.hasProjects=()=>(e.dashboardTotals?.total??e.items.length)>0,e.setProjectView=C=>{e.projectView=C,C==="attention"&&(e.filters.status.error=!0,e.filters.status.progress=!0)},e.idleText=C=>{let L=va(C?.anonymizeDate||C?.lastView)||"";return/ ago$/.test(L)?"No activity for "+L.replace(/ ago$/,""):"No activity since "+L.replace(", "+new Date().getFullYear(),"")},e.projectDetailsId=C=>"project-details-"+encodeURIComponent(C._type+":"+(C._id||C._source||"unknown")),e.showProjectDetails=async C=>{e.selectedProject=C,e.projectName=C.projectName||"",e.nameError="",e.nameMessage="",await tt();let L=document.getElementById(e.projectDetailsId(C));L?.focus(),L?.scrollIntoView?.({block:"nearest"})},e.closeProjectDetails=C=>{e.selectedProject=null,tt(()=>document.querySelector(`[data-project-actions="${encodeURIComponent(C._type+":"+C._id)}"]`)?.focus())},e.saveProjectName=async C=>{if(e.nameSaving||!C._id)return;let L=e.projectName.trim();if(L.length>100){e.nameError="Use 100 characters or fewer.";return}e.nameSaving=!0,e.nameError="",e.nameMessage="";try{let H=await t.post("/api/user/project-name",{type:C._type,id:C._id,name:L});C.projectName=H.data.name,C._label=C.projectName||C._fallbackLabel,e.selectedProject===C&&(e.nameMessage=L?"Project name saved.":"Default project name restored."),E||(e.dashboardCursor=null,await V(),e.selectedProject===C&&(e.selectedProject=e.items.find(K=>K._type===C._type&&K._id===C._id)||null))}catch{e.selectedProject===C&&(e.nameError="The project name could not be saved. Try again.")}finally{e.nameSaving=!1}},e.copyingId=null,e.copyLink=async C=>{if(!C._viewUrl||e.copyingId)return;let L=new URL(C._viewUrl,o.location.origin).href;e.copyingId=C._type+":"+C._id;try{await Wa(L),e.addToast({title:"Link copied",body:"The anonymous link is ready to share."})}catch{e.addToast({title:"Copy this anonymous link",body:L})}finally{e.copyingId=null}},e.items=[],e.search="",e.loading=!0,e.statusKeyLabels={ready:"Ready",progress:"Preparing",error:"Error",expired:"Expiring / expired",removed:"Removing / removed"};let p=["queue","download","downloaded","preparing","anonymizing"];function u(C){return C==="ready"||C==="error"?C:C==="expired"||C==="expiring"?"expired":C==="removed"||C==="removing"?"removed":(p.indexOf(C)>-1,"progress")}let y=7200*1e3,h="dashboard.filterPrefs",b={typeFilter:"all",filters:{status:{ready:!0,progress:!0,error:!0,expired:!0,removed:!1}},orderBy:"-anonymizeDate"},m=loadFilterPrefs(h)||{};e.typeFilter=m.typeFilter||b.typeFilter,e.filters={status:Object.assign({},b.filters.status,m.filters&&m.filters.status||{})},e.orderBy=m.orderBy||b.orderBy;let w={_name:{label:"Anonymous ID",defaultDesc:!1},_label:{label:"Project",defaultDesc:!1},anonymizeDate:{label:"Anonymize date",defaultDesc:!0},status:{label:"Status",defaultDesc:!1},lastView:{label:"Last view",defaultDesc:!0},pageView:{label:"Views",defaultDesc:!0},"options.expirationDate":{label:"Expiration",defaultDesc:!1}};e.sortFields=w,e.sortField=()=>e.orderBy.replace(/^-/,""),e.sortDesc=()=>e.orderBy.charAt(0)==="-",e.sortLabel=()=>{let C=w[e.sortField()];return C?C.label:"Custom"},e.isSortedBy=C=>e.sortField()===C,e.setSort=(C,L)=>{typeof L!="boolean"&&(L=e.isSortedBy(C)?!e.sortDesc():!!(w[C]&&w[C].defaultDesc)),e.orderBy=(L?"-":"")+C},e.toggleSortDirection=()=>{e.setSort(e.sortField(),!e.sortDesc())},e.watchGroup(["typeFilter","orderBy"],()=>{saveFilterPrefs(h,{typeFilter:e.typeFilter,filters:e.filters,orderBy:e.orderBy})}),e.watch("filters",()=>{saveFilterPrefs(h,{typeFilter:e.typeFilter,filters:e.filters,orderBy:e.orderBy})},!0),r.load().then(C=>{e.quota=C},console.error);function N(C,L,H,K,ie,se){C.pageView||(C.pageView=0),C.lastView||(C.lastView=""),C.options=C.options||{},C.options.terms=(C.options.terms||[]).filter(me=>me),C._id=L||"",C._source=K,C._broken=!L,C._name=L||K||"(unnamed)",C._fallbackLabel=C._type==="gist"?"Gist "+(L||K||"without an ID"):K||H||C._name,C._label=C.projectName||C._fallbackLabel,C._editUrl=L?ie:null,C._viewUrl=L?se:null,C._broken&&(C.status="error",C.statusMessage="incomplete_record"),C._statusKey=u(C.status);let Y=C.anonymizeDate||C.lastView;if(C._stale=C._statusKey==="progress"&&!!Y&&Date.now()-new Date(Y).getTime()>y,C.status==="expired"||C.status==="expiring")C._expiry={kind:"expired",date:C.options.expirationDate},C._expiry.label=ba(C.options.expirationDate)||void 0;else if(C.status!=="ready")C._expiry={kind:"none"};else if(C.options.expirationMode==="never"||!C.options.expirationDate)C._expiry={kind:"never"};else{C._expiry={kind:"date",date:C.options.expirationDate};let me=new Date(C.options.expirationDate).getTime()-Date.now();if(me>0&&me<=168*3600*1e3){let Se=Math.max(1,Math.round(me/36e5)),Ue=Math.round(me/864e5);C._expiry.soon=Se<48?"in "+Se+(Se===1?" hour":" hours"):"in "+Ue+" days"}}return C}function S(C){return t.get(C).then(L=>L.data||[],L=>(console.error(L),[]))}function R(){return e.loading=!0,i.all([S("/api/user/anonymized_repositories"),S("/api/user/anonymized_pull_requests"),S("/api/user/anonymized_gists")]).then(C=>{let L=C[0],H=C[1],K=C[2],ie=[];L.forEach(se=>{se._type="repo";let Y=se.source||{};ie.push(N(se,se.repoId,se.repoId,Y.fullName,"/anonymize/"+se.repoId,"/r/"+se.repoId+"/"))}),H.forEach(se=>{se._type="pr";let Y=se.source||{};ie.push(N(se,se.pullRequestId,se.pullRequestId,Y.repositoryFullName?Y.repositoryFullName+"#"+Y.pullRequestId:void 0,"/pull-request-anonymize/"+se.pullRequestId,"/pr/"+se.pullRequestId+"/"))}),K.forEach(se=>{se._type="gist";let Y=se.source||{};ie.push(N(se,se.gistId,se.gistId,Y.gistId,"/gist-anonymize/"+se.gistId,"/gist/"+se.gistId+"/"))}),e.items=ie,e.removedCount=ie.filter(se=>se._statusKey==="removed").length,e.loading=!1})}let v=0,E=!1;e.dashboardCursor=null,e.dashboardError="";function D(C){let L=C.source||{};return C._type==="repo"?N(C,C.repoId,C.repoId,L.fullName,"/anonymize/"+C.repoId,"/r/"+C.repoId+"/"):C._type==="pr"?N(C,C.pullRequestId,C.pullRequestId,L.repositoryFullName?L.repositoryFullName+"#"+L.pullRequestId:void 0,"/pull-request-anonymize/"+C.pullRequestId,"/pr/"+C.pullRequestId+"/"):N(C,C.gistId,C.gistId,L.gistId,"/gist-anonymize/"+C.gistId,"/gist/"+C.gistId+"/")}function V(C=!1){if(E)return R();let L=++v;return e.loading=!C,e.loadingMore=C,e.dashboardError="",t.get("/api/user/dashboard",{params:{q:e.search,type:e.typeFilter,sort:e.orderBy,statuses:Object.keys(e.filters.status).filter(H=>e.filters.status[H]!==!1).join(",")||"none",attention:String(e.projectView==="attention"),cursor:C?e.dashboardCursor:void 0}}).then(H=>{if(L===v){if(!Array.isArray(H.data?.items))return E=!0,R();e.items=(C?e.items:[]).concat(H.data.items.map(D)),e.dashboardCursor=H.data.cursor,e.dashboardTotals=H.data,C||x()}},H=>{if(L===v){if(H.status===404)return E=!0,R();e.dashboardError="Projects could not be loaded. Please try again."}}).finally(()=>{L===v&&(e.loading=!1,e.loadingMore=!1)})}e.loadMoreProjects=()=>V(!0);let _;e.watchGroup(["search","typeFilter","orderBy","projectView"],()=>{E||(_&&d.timeout.cancel(_),_=d.timeout(()=>V(),150))},!1),e.watch("filters",()=>{E||V()},!0,!1),e.on("dispose",()=>{v++}),V(),e.openItem=(C,L)=>{if(!C._viewUrl)return;let H=L&&L.target;H&&H.closest&&H.closest("a, button, .dropdown, input")||(o.location.href=C._viewUrl)},e.hiddenStatusCount=()=>Object.keys(e.filters.status).filter(C=>e.filters.status[C]===!1).length,e.hasHiddenStatus=()=>e.hiddenStatusCount()>0;let z=()=>Object.keys(e.statusKeyLabels);e.onlyRemovedShown=()=>z().every(C=>C==="removed"==(e.filters.status[C]!==!1)),e.isActiveDefault=()=>z().every(C=>C==="removed"==(e.filters.status[C]===!1)),e.statusView=()=>e.projectView==="attention"?"attention":e.onlyRemovedShown()?"removed":e.filters.status.removed===!1?"active":"custom",e.setStatusView=C=>{if(C==="attention")return e.setProjectView("attention");e.projectView="all",z().forEach(L=>{e.filters.status[L]=C==="removed"?L==="removed":L!=="removed"})},e.statusChipKeys=()=>{let C=e.statusView();return C==="removed"?[]:z().filter(L=>e.filters.status[L]===!1&&!(L==="removed"&&C!=="custom"))},e.removedCount=null;function x(){if(E){e.removedCount=e.items.filter(L=>L._statusKey==="removed").length;return}let C=e.dashboardTotals;!C||e.projectView!=="all"||e.search.trim()||e.typeFilter!=="all"||(e.isActiveDefault()?e.removedCount=Math.max(0,C.total-C.filtered):e.onlyRemovedShown()&&(e.removedCount=C.filtered))}e.showViewTabs=()=>e.statusView()!=="active"||e.attentionCount()>0||e.removedCount>0||e.removedCount==null&&!!e.dashboardTotals&&e.dashboardTotals.total>e.dashboardTotals.filtered,e.hasActiveFilters=()=>e.projectView!=="all"||e.typeFilter!=="all"||e.search.trim().length>0||Object.keys(e.filters.status).some(C=>e.filters.status[C]===!1),e.showClearFilters=()=>e.search.trim().length>0||e.typeFilter!=="all"||e.statusChipKeys().length>0,e.isPlainView=()=>!e.showClearFilters(),e.clearFilters=()=>{let C=e.statusView();e.typeFilter="all",e.search="",e.setStatusView(C==="removed"?"removed":"active")};function X(C,L,H,K){t.get("/api/repo/"+C).then(async ie=>{let se=K!==void 0&&K!==ie.data.status;for(let Y of e.items)if(Y._type==="repo"&&Y.repoId==C){se=se||Y.status!==ie.data.status;let me=e.needsAttention(Y);Y.status=ie.data.status,Y.statusMessage=ie.data.statusMessage,Y._statusKey=u(Y.status),Y._statusKey!=="progress"&&(Y._stale=!1);let Se=e.needsAttention(Y);e.dashboardTotals&&me!==Se&&(e.dashboardTotals.attention=Math.max(0,e.dashboardTotals.attention+(Se?1:-1)));break}if(se&&!E){e.dashboardCursor=null;let Y=e.selectedProject;await V(),Y&&e.selectedProject===Y&&(e.selectedProject=e.items.find(me=>me._type===Y._type&&me._id===Y._id)||null)}if(ie.data.status=="ready"||ie.data.status=="error"||ie.data.status=="removed"||ie.data.status=="expired"){L(ie.data);return}d.timeout(()=>X(C,L,H,ie.data.status),2500)},H)}let I=C=>C==="repo"?"repository":C==="gist"?"gist":"pull request",U=C=>C==="repo"?"/api/repo":C==="gist"?"/api/gist":"/api/pr";e.removeItem=C=>{let L=I(C._type);if(confirm(`Are you sure that you want to remove the ${L} ${C._id}?`)){let H=st({title:`Removing ${C._id}...`,date:new Date,body:`The ${L} ${C._id} is going to be removed.`});e.addToast(H);let K=`${U(C._type)}/${C._id}`;t.delete(K).then(()=>{C._type==="repo"?X(C._id,()=>{H.title=`${C._id} is removed.`,H.body=`The ${L} ${C._id} is removed.`},void 0,C.status):(H.title=`${C._id} is removed.`,H.body=`The ${L} ${C._id} is removed.`,V())},ie=>{H.title=`Error during the removal of ${C._id}.`,H.body=ie.body,V()})}},e.refreshItem=C=>{let L=I(C._type),H=st({title:`Refreshing ${C._id}...`,date:new Date,body:`The ${L} ${C._id} is going to be refreshed.`});e.addToast(H);let K=se=>{H.title=`Error during the refresh of ${C._id}.`,H.body=se.data?.error||se.body||"The refresh could not be completed. Please try again.",V()},ie=`${U(C._type)}/${C._id}/refresh`;t.post(ie).then(()=>{C._type==="repo"?X(C._id,se=>{if(se.status!=="ready"){K({body:se.statusMessage||`The repository is ${se.status}.`});return}H.title=`${C._id} is refreshed.`,H.body=`The ${L} ${C._id} is refreshed.`},K,C.status):(H.title=`${C._id} is refreshed.`,H.body=`The ${L} ${C._id} is refreshed.`,V())},K)},e.extendItem=C=>{let L=I(C._type),H=st({title:`Extending ${C._id}...`,date:new Date,body:`The expiration of ${L} ${C._id} is being extended.`});e.addToast(H);let K=`${U(C._type)}/${C._id}/extend`;t.post(K).then(ie=>{let se=ie?.data?.expirationDate?` until ${new Date(ie.data.expirationDate).toLocaleDateString(void 0,{year:"numeric",month:"short",day:"numeric"})}`:"";C._type==="repo"?X(C._id,()=>{H.title=`${C._id} is extended.`,H.body=`${L} ${C._id} is extended${se}.`},void 0,C.status):(H.title=`${C._id} is extended.`,H.body=`${L} ${C._id} is extended${se}.`,V())},ie=>{H.title=`Error during the extension of ${C._id}.`;let se=ie.data&&ie.data.error;H.body=se||ie.body,se&&Object.prototype.hasOwnProperty.call(Kn.ERRORS,se)&&(H.body=Kn.ERRORS[se]),V()})},e.itemFilter=C=>{if(e.projectView==="attention"&&!e.needsAttention(C)||e.typeFilter!=="all"&&C._type!==e.typeFilter||e.filters.status[C._statusKey]===!1)return!1;let L=e.search.trim().toLowerCase();return!!(L.length==0||C._label&&String(C._label).toLowerCase().indexOf(L)>-1||C._source&&String(C._source).toLowerCase().indexOf(L)>-1||C._id&&String(C._id).toLowerCase().indexOf(L)>-1||C.conference&&String(C.conference).toLowerCase().indexOf(L)>-1)}};var Uc=function(e,t,s){let i=Ct();e.repoId=s.repoId,e.reviewUrl=window.location.origin+"/r/"+encodeURIComponent(s.repoId)+"/",e.repo=null,e.progress=0,e.rateLimitResetAt=0,e.rateLimitCountdown="",e.shareUrl=(window.location?.origin||"")+"/r/"+encodeURIComponent(e.repoId)+"/",e.copied=!1;let o=null;e.copyShareUrl=async()=>{try{await Wa(e.shareUrl),e.copied=!0,o&&i.timeout.cancel(o),o=i.timeout(()=>{e.copied=!1},2e3)}catch{e.addToast?.({title:"Copy this anonymous link",body:e.shareUrl})}},e.selectShareUrl=h=>{let b=window.getSelection?.();if(!b||!h?.target)return;let m=document.createRange();m.selectNodeContents(h.target),b.removeAllRanges(),b.addRange(m)};var r=null;let d=null,p=!1;function u(h){e.rateLimitResetAt=h,r&&i.interval.cancel(r);function b(){var m=Math.max(0,Math.ceil((h-Date.now())/1e3));if(m<=0)e.rateLimitCountdown="",e.rateLimitResetAt=0,i.interval.cancel(r),r=null;else{var w=Math.floor(m/60),N=m%60;e.rateLimitCountdown=w>0?w+"m "+N+"s":N+"s"}}b(),r=i.interval(b,1e3)}e.on("dispose",function(){p=!0,r&&i.interval.cancel(r),d&&i.timeout.cancel(d)});function y(h){if(!h)return h;var b=h.match(/^rate_limited:(\d+)$/);return b?(u(parseInt(b[1],10)),null):(e.rateLimitResetAt=0,h)}e.getStatus=()=>{p||t.get("/api/repo/"+e.repoId,{repoId:e.repoId,repoUrl:e.repoUrl}).then(h=>{if(!p){e.repo=h.data,h.data.rateLimitResetAt?u(h.data.rateLimitResetAt):e.repo.statusMessage=y(e.repo.statusMessage),e.repo.status=="ready"?e.progress=100:e.repo.status=="queue"?e.progress=10:e.repo.status=="downloaded"?e.progress=50:e.repo.status=="download"||e.repo.status=="preparing"?e.progress=25:e.repo.status=="anonymizing"&&(e.progress=75);var b=!["ready","removed","expired"].includes(e.repo.status);e.repo.status=="error"&&!e.rateLimitResetAt&&(b=!1),b&&(d=i.timeout(e.getStatus,2e3))}},h=>{e.error=h.data.error})},e.getStatus()},dr=function(e,t,s,i,o,r,d){Ic(),e.renderRedacted=_o,e.sourceUrl="",e.workspaceOpen=!1,e.sourceUrlError="",e.previewStatus="idle",e.sourceLoading=!1,e.mobilePane="settings";let p=window.matchMedia?.("(max-width: 767px)");e.mobileWorkspace=!!p?.matches,p?.addEventListener&&Ut()(p,"change",k=>{e.mobileWorkspace=k.matches}),e.selectMobilePane=k=>{e.mobilePane=k};let u=0,y=!1,h=new Set,b=(k,M=!1)=>!y&&k.generation===u&&k.url===e.sourceUrl.trim()&&k.connection===e.githubConnection&&(!M||k.branch===e.source.branch),m=()=>{let k={generation:u,url:e.sourceUrl.trim(),connection:e.githubConnection,branch:e.source.branch};return h.add(k),e.sourceLoading=!0,k},w=k=>{h.delete(k),y||(e.sourceLoading=[...h].some(M=>b(M)))};e.on("dispose",()=>{y=!0,u++});let N=null,S=k=>k.gistId&&!k.repo?"gist:"+k.gistId.toLowerCase():(k.owner+"/"+k.repo).toLowerCase()+(k.pullRequestId?"/pull/"+k.pullRequestId:""),R=ga(e,["sourceUrl","terms","repoId","pullRequestId","gistId","source","options","conference","githubConnection"],"anonymize:"+(o.path?.()||"")),v=null,E=null,D=null;e.hostingReview=!1,e.previewExpanded=!1,e.taskValidationError="",e.editRepository=()=>{e.mobilePane="settings",e.previewExpanded=!1,tt(()=>document.querySelector(".anonymize-fields .is-invalid")?.focus())},e.submitRepository=k=>{if(e.taskValidationError="",!(e.sourceLoading||e.billingBusy||e.hostingSaving||e.billingPending)){if(ei()||e.anonymize?.invalid||e.sourceUrlError){e.taskValidationError="Check the highlighted fields before continuing.",e.editRepository();return}return e.hostingNeedsPayment()?e.checkoutRepository(Gi(e.hostingChoice())?e.hostingChoice():""):e.anonymizeRepo(k)}},e.hostingPayment=!1,e.hostingAlternatives=!1,e.hostingPrice=k=>k.amount==null?"Price shown at checkout":new Intl.NumberFormat(void 0,{style:"currency",currency:k.currency,minimumFractionDigits:0,maximumFractionDigits:2}).format(k.amount/100)+(k.interval==="year"?" billed annually":" billed monthly"),e.hostingPlan="",e.hostingSaving=!1,e.selectedHostingPlan=()=>e.authorPlans().find(k=>k.id===e.hostingPlan)||e.hostingSubscriptionPlan?.();let V=()=>t.get("/api/user/quota").then(k=>{e.hostingQuota=k.data});Ki(e,t,async()=>{await V(),e.hostingQuotaBlocked=!1},{confirmedMessage:"Hosting status refreshed. Your draft is ready to continue."}),V().catch(()=>{}),e.authorPlans=()=>(e.billing?.plans||[]).filter(k=>["author_monthly","author_annual"].includes(k.id)),e.conferenceHosting=()=>!!(e.conference&&e.conference_data?.hosting),e.hasAuthorHosting=()=>["author_monthly","author_annual"].includes(e.billing?.allowance?.plan),e.hostingNeedsPayment=()=>!e.billing?.enabled||e.detectedType!=="repo"||e.hasAuthorHosting()||e.isUpdate&&e.role!=="owner"?!1:!!(e.options?.expirationMode==="never"&&!e._existingNever&&!e.repositoryGrants("repo_never").length||!e.conferenceHosting()&&e.hostingQuotaBlocked),e.repositoryGrants=k=>(e.billing?.grants||[]).filter(M=>M.planId===k&&M.scope===`repo:${e.repoId}`&&["active","paid","past_due"].includes(M.status)&&new Date(M.until).getTime()>Date.now()),e.repositoryAddonPlans=()=>(e.billing?.plans||[]).filter(k=>Gi(k.id)&&(["repo_extend","repo_pack"].includes(k.id)||!e.repositoryGrants(k.id).length)),e.hostingOneTimePlans=()=>{let k=M=>M.map(B=>(e.billing?.plans||[]).find(G=>G.id===B&&!e.repositoryGrants(B).length)).filter(Boolean);return e.options?.expirationMode==="never"&&!e._existingNever&&!e.repositoryGrants("repo_never").length?k(["repo_never"]):e.hostingQuotaBlocked&&!e.conferenceHosting()?k(["repo_slot","repo_pack"]):[]},e.hostingOneTime=()=>e.hostingOneTimePlans()[0];let _=["free","repo_slot"];e.liveUpdatesIncluded=()=>{if(!e.billing?.enabled||e.detectedType!=="repo"||e.isUpdate&&e.role!=="owner"||e.conferenceHosting()||e.hasAuthorHosting())return!0;let k=e.billing?.allowance?.plan;return k&&!_.includes(k)?!0:e.repositoryGrants("author_pass").length>0||e.repositoryGrants("repo_pack").length>0},e.liveUpdatesPrice=()=>{let k=(e.billing?.plans||[]).find(M=>M.id==="author_pass");return k?.amount!=null?e.billingAmount(k):""},e.showHostingOptions=()=>{e.mobilePane="settings",tt(()=>document.getElementById("repository-hosting")?.scrollIntoView({block:"start",behavior:"smooth"}))},e.neverExpireTag=()=>{if(e.hasAuthorHosting())return"Included in your subscription";if(e.repositoryGrants("repo_never").length)return"Paid for this repository";let k=(e.billing?.plans||[]).find(M=>M.id==="repo_never");return k?.amount!=null?`${e.billingAmount(k)} once, or with a subscription`:"Subscription or one-time add-on"},e.hostingCycle="author_annual",e.hostingSubscriptionPlan=()=>e.authorPlans().find(k=>k.id===e.hostingCycle)||e.authorPlans().find(k=>k.interval==="year")||e.authorPlans()[0],e.hostingAnnualSavings=()=>{let k=e.authorPlans().find(B=>B.interval==="month")?.amount,M=e.authorPlans().find(B=>B.interval==="year")?.amount;return k&&M&&Me.hostingOneTimePlans().concat(e.authorPlans().length?[e.hostingSubscriptionPlan()]:[]),e.hostingOptionName=k=>({repo_slot:"Add this repository",repo_pack:"Paper pack",repo_never:"Never expire",author_annual:"Author subscription",author_monthly:"Author subscription"})[k.id]||k.name,e.hostingOptionBlurb=k=>({repo_slot:"Hosted outside your free repositories. Refresh it by hand.",repo_pack:"Adds automatic updates for 180 days and keeps the link online for a year.",repo_never:"This link never expires. No subscription."})[k.id]||`${k.repositories} repositories, ${e.billingBytes(k.storage)}, automatic updates and links that never expire.`,e.hostingChoice=()=>{let k=e.hostingOneTimePlans();return k.some(M=>M.id===e.hostingPlan)||e.authorPlans().some(M=>M.id===e.hostingPlan)?e.hostingPlan:k[0]?.id||e.hostingSubscriptionPlan()?.id||""},e.checkoutRepository=async(k="")=>{if(!(e.hostingSaving||e.billingBusy||!e.billing?.csrf||e.sourceLoading)){e.hostingSaving=!0,e.billingError="";try{let M=R.checkpoint(),B=JSON.stringify(M);(!E||B!==D)&&(E=(await t.post("/api/billing/draft",{path:o.path(),values:M},{headers:{"x-csrf-token":e.billing.csrf}})).data.id,D=B);let G=e.authorPlans().find(ue=>ue.id===e.hostingPlan)||e.hostingSubscriptionPlan();if(!k&&!G)throw new Error("No author plan available");await e.checkout(k||G.id,k?e.repoId:"",{draftId:E})}catch{e.billingError="Your draft could not be saved for checkout. Your form is unchanged. Please try again."}finally{e.hostingSaving=!1}}},e.useDatedHosting=()=>{e.options.expirationMode="remove"},e.discardDraft=async()=>{R.discard(),e.workspaceOpen=!!e.sourceUrl,e.error=null,e.sourceUrl?await e.urlSelected(!0):(u++,e.sourceLoading=!1,e.detectedType=null,e.details=null,e.sourceUrlError="",Yt.cancel(),Tn.cancel(),On.cancel(),e.previewStatus="idle")},e.githubConnection=void 0,e.githubConnections=null,e.gistOAuthRequired=!1,e.gistAppRequired=!1;let z=()=>{let k={};for(let M of["sourceUrl","terms","repoId","pullRequestId","gistId","source","options","conference","githubConnection"])k[M]=e[M];sessionStorage.setItem("github-access-draft",JSON.stringify({path:o.path(),savedAt:Date.now(),draft:k}))};e.connectGistApp=()=>{z(),window.location.href="/github/app/login?returnTo="+encodeURIComponent(o.path())},e.connectGistOAuth=()=>{z(),window.location.href="/github/login?returnTo="+encodeURIComponent(o.path())},e.grantGitHubAccess=()=>{z();let k=o.path(),M=me(e.sourceUrl)||"",B=e.githubConnections?.appConnected?"/github/app/install":"/github/app/login";window.location.href=B+"?returnTo="+encodeURIComponent(k)+"&repository="+encodeURIComponent(M)+"&install=1"},e.chooseGitHubConnection=async k=>{e.githubConnection=k,e.readme="",e.sourceUrl&&await Ue()},e.detectedType=null,e.repoId="",e.pullRequestId="",e.gistId="",e.terms="",e.defaultTerms="",e.branches=[],e.source={branch:"",commit:""},e.options={expirationMode:"remove",expirationDate:new Date,update:!1,image:!0,pdf:!0,notebook:!0,link:!0,body:!0,title:!0,origin:!1,diff:!0,content:!0,comments:!0,username:!0,date:!0};function x(){let k=new Date;return k.setMonth(k.getMonth()+6),k}e.options.expirationDate=x();function X(k){let M=k.getFullYear(),B=String(k.getMonth()+1).padStart(2,"0"),G=String(k.getDate()).padStart(2,"0");return`${M}-${B}-${G}`}e.minExpirationDate=X(new Date);let I=()=>{let k=new Date,M=new Date(k);if(M.setFullYear(M.getFullYear()+1),e.billing?.enabled&&e.detectedType==="repo"&&!e.hasAuthorHosting()){M=new Date(k),M.setMonth(M.getMonth()+(e.billing.freeExpirationMonths||5));for(let ue of e.repositoryGrants("repo_extend"))new Date(ue.until)>M&&(M=new Date(ue.until));e.conference_data?.endDate&&new Date(e.conference_data.endDate)>M&&(M=new Date(e.conference_data.endDate)),e._savedExpirationDate&&e._savedExpirationDate>M&&(M=new Date(e._savedExpirationDate));let B=e.options?.expirationDate,G=e._savedExpirationDate&&B instanceof Date&&B.getTime()===e._savedExpirationDate.getTime();B instanceof Date&&B>M&&!G&&(e.options.expirationDate=new Date(M))}e.maxExpirationDate=X(M)};I(),e.watch(()=>[e.billing,e.repoId,e.conference_data,e.isUpdate,e._savedExpirationDate,e.options?.expirationMode,e.detectedType],I,!0,!1),e.anonymize_readme="",e.readme="",e.isUpdate=!1,e.userRepos=[],e.userReposStatus="idle",e.userRepoFilter="",e.loadUserRepos=(k=!1)=>{e.userReposStatus!=="loading"&&(e.userReposStatus="loading",t.get("/api/user/all_repositories",k?{params:{force:"1"}}:{}).then(M=>{if(y)return;let B=Array.isArray(M.data)?M.data.filter(G=>G&&G.fullName):[];e.userRepos=B.sort((G,ue)=>G.fullName.localeCompare(ue.fullName,void 0,{sensitivity:"base"})),e.userReposStatus="ready"},()=>{y||(e.userReposStatus="error")}))},e.filteredUserRepos=()=>{let k=String(e.userRepoFilter||"").trim().toLowerCase(),M=e.userRepos||[];return k?M.filter(B=>B.fullName.toLowerCase().includes(k)):M},e.selectUserRepo=k=>{if(k?.fullName)return e.sourceUrl="https://github.com/"+k.fullName,e.urlSelected()},!i.repoId&&!i.pullRequestId&&!i.gistId&&Promise.resolve().then(()=>{y||e.loadUserRepos()}),e.previousConfigurations=[],e.previousConfigurationId="";let U,C=k=>String(k||"").replace(/\/$/,"").replace(/\.git$/i,"").toLowerCase();async function L(){if(e.isUpdate||i.repoId||i.pullRequestId||i.gistId)return;let k={generation:u,url:e.sourceUrl.trim(),connection:e.githubConnection};try{U||(U=t.get("/api/user/anonymized_repositories").then(G=>G.data));let M=await U;if(!b(k))return;let B=C(me(k.url));e.previousConfigurations=M.filter(G=>G.repoId&&G.options&&C(G.source?.fullName)===B).sort((G,ue)=>(Date.parse(ue.anonymizeDate)||0)-(Date.parse(G.anonymizeDate)||0)),e.previousConfigurationId=e.previousConfigurations[0]?.repoId||""}catch{U=void 0}}e.sourceSummary=()=>{let k=String(e.sourceUrl||""),M=/github\.com\/([^/\s]+\/[^/\s]+)\/pull\/(\d+)/i.exec(k);return M?M[1]+" \xB7 PR #"+M[2]:(M=/gist\.github\.com\/([^/\s]+)\/([0-9a-f]{8,})/i.exec(k),M?M[1]+" \xB7 gist "+(M[2].length>12?M[2].slice(0,7)+"\u2026"+M[2].slice(-4):M[2]):"")},e.previewId=()=>e.detectedType==="pr"?e.pullRequestId:e.detectedType==="gist"?e.gistId:e.repoId,e.previewPath=()=>{let k=e.previewId();return k?(e.detectedType==="pr"?"/pr/":e.detectedType==="gist"?"/gist/":"/r/")+encodeURIComponent(k)+"/":""},e.previewUrl=()=>{let k=e.previewPath();return k?"anonymous.4open.science"+k.replace(/\/$/,""):""},e.previewRedactions=()=>{let k=G=>typeof G=="string"?(G.match(Zo)||[]).length:0;if(e.detectedType==="repo")return e.previewViewer.redactionCount();let M=e.detectedType==="pr"?ks:Cs,B=0;return M.forEach(G=>{B+=k(G)}),B};let H=(k,M)=>k.localeCompare(M,void 0,{sensitivity:"base"}),K=k=>k.slice(k.lastIndexOf("/")+1),ie={key:null,files:[]};e.previewTreeFiles=()=>{if(!e.preserve.commit||!ve)return[];let k=e.preserve.commit+"\0"+e.terms+"\0"+bs.size+"\0"+ve.files.length;if(ie.key===k)return ie.files;let M=ve.files.map(B=>{let G=e.previewPathName(B),ue=G.lastIndexOf("/");return{name:G.slice(ue+1),path:ue<0?"":G.slice(0,ue),size:0,sourcePath:B}});return ie={key:k,files:M},M},e.selectPreviewPath=k=>{let M=e.previewTreeFiles().find(B=>"/"+(B.path?B.path+"/":"")+B.name===k);M&&e.openPreviewFile(M.sourcePath)},e.existingConfigurationUrl=()=>{let k=e.previousConfigurations.find(M=>M.repoId===e.previousConfigurationId);return k?"/anonymize/"+encodeURIComponent(k.repoId):null};function se(k){t.get("/api/user/default").then(M=>{let B=M.data;B.terms&&(e.defaultTerms=B.terms.join(` +`)),e.options=Object.assign({},e.options,B.options),e.options.expirationDate=B.options&&B.options.expirationDate?new Date(B.options.expirationDate):x(),!i.repoId&&!i.pullRequestId&&!i.gistId&&!e.anonymize?.terms?.dirty&&(e.terms=e.defaultTerms),k&&k()})}function Y(k,M,B){e.anonymize&&e.anonymize[k]&&e.anonymize[k].setValidity(M,B)}function me(k){try{let M=parseGithubUrl(k);if(M&&M.owner&&M.repo)return M.owner+"/"+M.repo}catch{}return null}e.accessRepairAllowed=!1,e.repairingGitHubAccess=!1,e.accessRepairMessage="",e.repairGitHubAccess=async()=>{if(!e.accessRepairAllowed||e.repairingGitHubAccess||!e.githubConnections?.appEnabled||!i.repoId||e.role!=="owner"||e.githubConnection!=="github-app"||me(e.sourceUrl)!==e._originalFullName)return;e.repairingGitHubAccess=!0,e.accessRepairMessage="";let k=m();try{let M=await t.get("/github/connections");if(e.githubConnections=M.data,!M.data.appEnabled)return;let B=await t.post("/github/connections/migrate",{type:"repository",id:i.repoId,connection:"github-app"},{headers:{"X-CSRF-Token":M.data.csrf}});if(!b(k))return;e.error=null,B.data.fullName&&(e._originalFullName=B.data.fullName,e.source.fullName=B.data.fullName,e.sourceUrl="https://github.com/"+B.data.fullName),e.accessRepairMessage="GitHub access repaired. Your anonymous URL and published commit are unchanged.",await e.urlSelected(!0)}catch{b(k)&&(e.accessRepairMessage="Unable to repair GitHub access. Check the App's repository permissions in Manage access, then retry. Your published snapshot has not been replaced.")}finally{e.repairingGitHubAccess=!1,w(k)}},e.reconnectingSource=!1,e.reconnectRepositoryId=void 0,e.reconnectSource=async()=>{if(confirm("Reconnect to the repository currently at this GitHub URL? Review its branch and commit before saving. Saving will replace the published snapshot.")){e.reconnectingSource=!0,e.reconnectRepositoryId=void 0,e.source.commit="",e.source.branch="",e.readme="",e.branches=[];try{await Qe()}catch{}}};function Se(){return e.reconnectingSource||!e.isUpdate||!e._originalRepositoryID?void 0:me(e.sourceUrl)===e._originalFullName?e._originalRepositoryID:void 0}async function Ue(){e._preservingDraft=!0;try{await e.urlSelected(!0)}finally{e._preservingDraft=!1}}async function Be(){let k=new URLSearchParams(window.location.search).get("billingDraft");if(k){R.restore();try{let B=(await t.get("/api/billing/draft/"+encodeURIComponent(k))).data;if(B.path!==o.path())throw new Error("Wrong task");v=B.values.conference||null;for(let G of["sourceUrl","terms","repoId","source","options","conference","githubConnection"])Object.prototype.hasOwnProperty.call(B.values,G)&&(e[G]=B.values[G]);return e.options?.expirationDate&&(e.options.expirationDate=new Date(e.options.expirationDate)),E=B.id,D=JSON.stringify(R.checkpoint()),e.draftRestored=!0,e.hostingReview=!0,e.sourceUrl&&await Ue(),o.replace?.(o.path()),!0}catch{e.billingError="The checkout draft could not be restored. Retry by reloading this page; any local draft is still available."}}let M;try{M=JSON.parse(sessionStorage.getItem("github-access-draft")||"null")}catch{return!1}if(!M||M.path!==o.path()||Date.now()-M.savedAt>=30*6e4)return R.restore()?(e.sourceUrl&&await Ue(),!0):!1;R.restore();for(let B of["sourceUrl","terms","repoId","pullRequestId","gistId","source","options","conference","githubConnection"])Object.prototype.hasOwnProperty.call(M.draft,B)&&(e[B]=M.draft[B]);return e.options.expirationDate&&(e.options.expirationDate=new Date(e.options.expirationDate)),await Ue(),sessionStorage.removeItem("github-access-draft"),!0}se(()=>{!i.repoId&&!i.pullRequestId&&!i.gistId&&d(Be,0),i.repoId&&i.repoId!=""&&(e.isUpdate=!0,e.detectedType="repo",e.repoId=i.repoId,t.get("/api/repo/"+e.repoId).then(async k=>{e.accessRepairAllowed=!["removed","archived","preparing","queue","download","removing","expiring"].includes(k.data.status),e.githubConnection=k.data.connection||"oauth",e.sourceUrl="https://github.com/"+k.data.source.fullName,e._originalFullName=k.data.source.fullName,e.terms=k.data.options.terms.filter(M=>M).join(` +`),e.source=k.data.source,e.role=k.data.role||"owner",e._existingNever=k.data.options.expirationMode==="never",e._savedExpirationDate=k.data.options.expirationDate?new Date(k.data.options.expirationDate):null,e.coauthors=k.data.coauthors||[],e._originalBranch=k.data.source.branch,e.options=Object.assign({},e.options,k.data.options),e.conference=k.data.conference,e._originalConference=k.data.conference,e.repositoryID=k.data.source.repositoryID,e._originalRepositoryID=k.data.source.repositoryID,k.data.options.expirationDate&&(e.options.expirationDate=new Date(k.data.options.expirationDate)),N=S(parseGithubUrl(e.sourceUrl)),!await Be()&&(await Promise.all([Qe(),He()]),ws())},()=>{o.url("/404")})),i.pullRequestId&&i.pullRequestId!=""&&(e.isUpdate=!0,e.detectedType="pr",e.pullRequestId=i.pullRequestId,t.get("/api/pr/"+e.pullRequestId).then(async k=>{if(e.githubConnection=k.data.connection||"oauth",e.sourceUrl="https://github.com/"+k.data.source.repositoryFullName+"/pull/"+k.data.source.pullRequestId,e.terms=k.data.options.terms.filter(M=>M).join(` +`),e.source=k.data.source,e.options=Object.assign({},e.options,k.data.options),e.conference=k.data.conference,e._originalConference=k.data.conference,k.data.options.expirationDate&&(e.options.expirationDate=new Date(k.data.options.expirationDate)),N=S(parseGithubUrl(e.sourceUrl)),!await Be())try{await Qa()}catch{}},()=>{o.url("/404")})),i.gistId&&i.gistId!=""&&(e.isUpdate=!0,e.detectedType="gist",e.gistId=i.gistId,t.get("/api/gist/"+e.gistId).then(async k=>{e.sourceUrl="https://gist.github.com/"+k.data.source.gistId,e.terms=k.data.options.terms.filter(M=>M).join(` +`),e.source=k.data.source,e.options=Object.assign({},e.options,k.data.options),e.conference=k.data.conference,e._originalConference=k.data.conference,k.data.options.expirationDate&&(e.options.expirationDate=new Date(k.data.options.expirationDate)),N=S(parseGithubUrl(e.sourceUrl)),!await Be()&&await Za()},()=>{o.url("/404")}))}),t.get("/github/connections").then(k=>{e.githubConnections=k.data,!i.repoId&&!i.pullRequestId&&!i.gistId&&e.githubConnection===void 0&&k.data.appEnabled&&k.data.appConnected&&(e.githubConnection="github-app",e.sourceUrl&&e.workspaceOpen&&Ue())}).catch(()=>{}),e.urlSelected=async(k=!1)=>{let M=++u;e.previousConfigurations=[],e.previousConfigurationId="";let B;try{B=parseGithubUrl(e.sourceUrl.trim())}catch{e.sourceLoading=!1,Yt.cancel(),Tn.cancel(),On.cancel(),e.previewStatus="idle",e.sourceUrlError=e.sourceUrl?"Please provide a valid GitHub URL.":"",Y("sourceUrl","github",!1);return}let G=S(B),ue=k||N===G;N=G,e.sourceUrlError="",Y("sourceUrl","github",!0);let ye=document.activeElement?.id==="sourceUrl-landing";e.workspaceOpen=!0,setTimeout(()=>{let Ke=window.document.getElementById("sourceUrl");if(Ke){try{Ke.setSelectionRange(0,0)}catch{}Ke.scrollLeft=0}},50),ye&&d(()=>document.getElementById("sourceUrl")?.focus(),0),e.reconnectingSource=!1,e.reconnectRepositoryId=void 0,!ue&&!e.isUpdate&&(e.repoId="",e.pullRequestId="",e.gistId=""),e.details=null,e.branches=[],ue||(e.source={type:"GitHubStream",branch:"",commit:""}),Yt.cancel(),Tn.cancel(),On.cancel(),ks.clear(),Cs.clear(),e.previewStatus="idle",e.anonymize_readme="",e.readme="",dt(),e.detectedType=null,e.gistOAuthRequired=!1,e.gistAppRequired=!1,e._preservingDraft=ue;try{B.gistId&&!B.repo?(e.detectedType="gist",e.source={gistId:B.gistId},await Za()):B.pullRequestId?(e.detectedType="pr",e.source={repositoryFullName:B.owner+"/"+B.repo,pullRequestId:B.pullRequestId},await Qa()):(e.detectedType="repo",L(),await Promise.all([Qe(),He()]),ws())}catch{}finally{M===u&&(e._preservingDraft=!1)}$('[data-toggle="tooltip"]').tooltip()},$('[data-toggle="tooltip"]').tooltip(),e.watch("source.branch",async()=>{if(e.detectedType!=="repo")return;let k=e.branches.filter(B=>B.name==e.source.branch)[0];if(!k)return;!(!e.reconnectingSource&&e.isUpdate&&e._originalBranch===e.source.branch&&e.source.commit)&&!(e._preservingDraft&&e.source.commit)&&(e.source.commit=k.commit),e.readme=k.readme,await He(),ws()}),e.getBranches=async k=>{let M=parseGithubUrl(e.sourceUrl),B=m();try{let G=await t.get(`/api/repo/${M.owner}/${M.repo}/branches`,{params:{reconnect:e.reconnectingSource?"1":void 0,anonymizedRepoId:e.isUpdate&&i.repoId&&me(e.sourceUrl)===e._originalFullName?i.repoId:void 0,connection:e.githubConnection,force:k===!0||e.reconnectingSource?"1":"0",repositoryID:Se()}});if(!b(B))return;e.branches=G.data,e.sourceUnreachable=!1,e.source.branch||(e.source.branch=e.details.defaultBranch);let ue=e.branches.filter(ye=>ye.name==e.source.branch);ue.length>0&&(!(!e.reconnectingSource&&!k&&e.isUpdate&&!e.options.update&&e._originalBranch===e.source.branch&&e.source.commit)&&!(e._preservingDraft&&e.source.commit)&&(e.source.commit=ue[0].commit),e.readme=ue[0].readme,await He(k))}catch(G){if(!b(B))return;e.branches=[],e.sourceUnreachable=G&&(G.status===404||G.data&&G.data.error==="repo_not_found");let ue=G&&G.data&&G.data.error||(G&&G.status===404?"repo_not_found":"unknown_error");r("ERRORS."+ue).then(ye=>{e.toasts=e.toasts||[],e.addToast({title:"Error",date:new Date,body:ye}),e.error=ye},console.error),typeof Y=="function"&&Y("sourceUrl","missing",!1)}finally{w(B)}};async function Qe(){let k=parseGithubUrl(e.sourceUrl),M=m();try{Es();let B=await t.get(`/api/repo/${k.owner}/${k.repo}/`,{params:{reconnect:e.reconnectingSource?"1":void 0,anonymizedRepoId:e.isUpdate&&i.repoId&&me(e.sourceUrl)===e._originalFullName?i.repoId:void 0,connection:e.githubConnection,repositoryID:Se(),force:"1"}});if(!b(M))return;e.details=B.data,e.reconnectingSource&&(e.reconnectRepositoryId=e.details.externalId),e.details&&e.details.id&&(e.repositoryID=e.details.id),e.repoId||(e.repoId=e.details.repo+"-"+generateRandomId(4)),await e.getBranches(e.reconnectingSource)}catch(B){if(!b(M))return;throw B.data&&(r("ERRORS."+B.data.error).then(G=>{e.addToast({title:"Error",date:new Date,body:G}),e.error=G},console.error),Ss(B.data.error)),Y("sourceUrl","missing",!1),B}finally{w(M)}}async function He(k){if(e.readme&&!k)return e.readme;let M=parseGithubUrl(e.sourceUrl),B=m();try{let G=await t.get(`/api/repo/${M.owner}/${M.repo}/readme`,{params:{reconnect:e.reconnectingSource?"1":void 0,anonymizedRepoId:e.isUpdate&&i.repoId&&me(e.sourceUrl)===e._originalFullName?i.repoId:void 0,connection:e.githubConnection,force:k===!0?"1":"0",branch:e.source.branch,repositoryID:Se()}});b(B,!0)&&(e.readme=G.data)}catch{b(B,!0)&&(e.readme="")}finally{w(B)}}let et={magicalBraces:!0},Re=k=>k.startsWith("/")&&!k.endsWith("/")&&zn(vs(k.slice(1),et),et)===k.slice(1),Fe=()=>Object.keys(e.preserve.picked).filter(k=>e.preserve.picked[k]).sort().map(k=>"/"+zn(k,et)),W=k=>"/"+zn(k,et)+"/**",fe=k=>"!/"+zn(k,et)+"/",de=()=>String(e.preserve.patterns||"").split(` +`).map(k=>k.trim()).filter(Boolean),ce=null,ve=null,Me=new Set,A=0,O=null,F=()=>!1;function J(){let k=A+"\0"+e.preserve.patterns;if(k!==O){O=k;try{F=ja(Ha([...Fe(),...de()]))}catch{F=()=>!1}}return F}function j(k){let M=new Map([["",{dirs:[],files:[]}]]);for(let B of k){let G=B.split("/"),ue="";for(let ye=0;yeM.startsWith(k+"/"))),ce.descendants.get(k)}let le=k=>J()(k);function ne(k){let M=ee(k),B=0;for(let G of M)le(G)&&B++;return B===0?"none":B===M.length?"all":"some"}e.preserve={open:!1,loading:!1,error:"",truncated:!1,commit:"",search:"",expanded:{},picked:{},patterns:"",patternsOpen:!1},e.preserveSummary=()=>{let k=(e.options?.preserveFiles||[]).map(M=>String(M).trim()).filter(Boolean).map(M=>Re(M)?vs(M.slice(1),et):M);return k.length?k.slice(0,2).join(", ")+(k.length>2?` and ${k.length-2} more`:""):"None. Every file is redacted."};async function oe(){let k=e.source?.commit;if(!(ce&&e.preserve.commit===k)){e.preserve.loading=!0,e.preserve.error="",ce=null,ve=null;try{let M=parseGithubUrl(e.sourceUrl),B=await t.get(`/api/repo/${M.owner}/${M.repo}/tree`,{params:{commit:k,connection:e.githubConnection,anonymizedRepoId:e.isUpdate&&i.repoId&&me(e.sourceUrl)===e._originalFullName?i.repoId:void 0,repositoryID:Se()}});if(e.source?.commit!==k)return;let G=Array.isArray(B.data.binaryFiles)?B.data.binaryFiles:[];ce=un(j(B.data.files||[])),ve=G.length?un(j([...B.data.files||[],...G])):ce,Me=un(new Set(G)),e.preserve.commit=k,e.preserve.truncated=!!B.data.truncated,e.previewFile||Yt()}catch{e.preserve.error="The file list could not be loaded from GitHub. You can still use patterns.",e.preserve.patternsOpen=!0}finally{e.preserve.loading=!1}}}e.watch("source.commit",k=>{e.previewFile&&e.openPreviewFile(""),e.detectedType==="repo"&&k&&e.sourceUrl&&oe().catch(()=>{})}),e.openPreserveFiles=()=>{let k={},M=[];for(let G of e.options?.preserveFiles||[]){let ue=String(G).trim();ue&&(!M.length&&Re(ue)?k[vs(ue.slice(1),et)]=!0:M.push(ue))}let B={};for(let G of Object.keys(k)){let ue=G.split("/");for(let ye=1;ye0}),e.mobileWorkspace&&(e.mobilePane="settings"),A++,d(()=>{let G=document.getElementById("preserve-files-dialog");G?.showModal&&!G.open&&G.showModal(),document.getElementById("preserve-files-search")?.focus()},0),oe()},e.closePreserveFiles=()=>{document.getElementById("preserve-files-dialog")?.close?.(),e.preserve.open=!1},e.savePreserveFiles=()=>{e.options.preserveFiles=Ha([...Fe(),...de()]),e.closePreserveFiles()},e.preserveRows=()=>{if(!ce)return[];let k=J(),M=(ye,Ke,qt)=>{let bt=!!e.preserve.picked[ye],Xn=k(ye);return{kind:"file",path:ye,label:qt,depth:Ke,state:Xn?"all":"none",locked:!bt&&Xn,note:!bt&&Xn?"matched by a pattern":bt&&!Xn?"excluded by a pattern":""}},B=String(e.preserve.search||"").trim().toLowerCase();if(B)return ce.files.filter(ye=>ye.toLowerCase().includes(B)).slice(0,300).map(ye=>M(ye,0,ye));let G=[],ue=(ye,Ke)=>{let qt=ce.dirs.get(ye);for(let bt of qt.dirs){let Xn=!!e.preserve.expanded[bt],xa=de().includes(W(bt));G.push({kind:"dir",path:bt,label:bt.slice(ye?ye.length+1:0)+"/",depth:Ke,open:Xn,state:ne(bt),locked:!1,note:xa?"whole folder":""}),Xn&&ue(bt,Ke+1)}for(let bt of qt.files)G.push(M(bt,Ke,bt.slice(ye?ye.length+1:0)))};return ue("",0),G},e.preserveCount=()=>ce?ce.files.filter(le).length:0,e.togglePreserveDir=k=>{e.preserve.expanded[k]=!e.preserve.expanded[k]},e.togglePreserveFile=k=>{e.preserve.picked[k]=!e.preserve.picked[k],A++},e.togglePreserveFolder=k=>{let M=W(k),B=fe(k),G=de().filter(ye=>ye!==M&&ye!==B),ue=ne(k)==="all"||de().includes(M);for(let ye of ee(k))e.preserve.picked[ye]=!1;A++,e.preserve.patterns=(ue?G:[...G,M]).join(` +`),ue&&ee(k).some(le)&&(e.preserve.patterns=[...G,B].join(` +`))};let te=/^readme(\.[^/]*)?$/i,ke=[".md",".markdown",".mdown",".mkdn",".rst",".txt",""],pe=["README.md","README","README.markdown","README.rst","README.txt","readme.md"],Ee=k=>{let M=K(k),B=M.indexOf("."),G=ke.indexOf(B===-1?"":M.slice(B).toLowerCase());return G===-1?ke.length:G},Pe=()=>!!ce&&!!e.preserve.commit&&e.preserve.commit===e.source?.commit;e.readmePath=()=>{if(!Pe())return"";for(let k of[".github","","docs"]){let M=(ce.dirs.get(k)?.files||[]).filter(B=>te.test(K(B)));if(M.length)return M.sort((B,G)=>Ee(B)-Ee(G)||H(B,G))[0]}return""},e.readmeName=()=>K(e.readmePath())||"README.md";let Ve={key:null,fn:()=>!1},Ge=()=>{let k=(e.options?.preserveFiles||[]).map(B=>String(B).trim()).filter(Boolean),M=k.join(` +`);if(M!==Ve.key){let B=()=>!1;try{k.length&&(B=ja(k))}catch{}Ve={key:M,fn:B}}return Ve.fn};e.pathPreserved=k=>!!k&&Ge()(k),e.readmePreserved=()=>{if(e.detectedType!=="repo")return!1;let k=Ge();if(Pe()){let M=e.readmePath();return!!M&&k(M)}return pe.some(M=>k(M))},e.previewPreserved=()=>e.detectedType==="repo"&&(e.previewFile?e.pathPreserved(e.previewFile):e.readmePreserved());function ze(){let k={terms:e.terms?e.terms.split(` +`):[],filePath:e.previewOpenPath()||"README.md",preserveFiles:e.options.preserveFiles||[],image:!!e.options.image,link:!!e.options.link,repoId:e.repoId};e.source&&e.source.branch&&(k.branchName=e.source.branch);try{let M=parseGithubUrl(e.sourceUrl);k.repoName=`${M.owner}/${M.repo}`}catch{}return k}function we(k,M,B){let G=null,ue=0,ye=()=>{if(e.detectedType!==k)return;G&&d.cancel(G);let Ke=++ue;e.previewStatus="loading",G=d(()=>{G=null;let qt=M();if(!qt){e.previewStatus="idle";return}t.post("/api/anonymize-preview",qt).then(bt=>{Ke===ue&&(B(bt.data,qt),e.previewStatus="ready")}).catch(()=>{Ke===ue&&(e.previewStatus="error")})},200)};return ye.cancel=()=>{ue++,G&&d.cancel(G),G=null},e.on("dispose",ye.cancel),ye}e.retryPreview=()=>{e.detectedType==="repo"&&(e.previewFile&&typeof lt!="string"?ft(e.previewFile):Yt()),e.detectedType==="pr"&&Tn(),e.detectedType==="gist"&&On()};let be=un(qo(e));Object.defineProperty(e,"previewViewer",{get:()=>be}),ha(be,e),Object.assign(be,{options:{},files:[],paths:[],content:null,type:"loading",sidebarHidden:!1,sidebarCollapsed:!0,moreOpen:!1,tocOpen:!1,gotoOpen:!1,mdFindOpen:!1,mdFindQuery:"",mdFindTotal:0,mdFindIndex:0}),be.preview=!0,be.fileSize=k=>k===be.filePath&&typeof lt=="string"?new Blob([lt]).size:!e.previewFile&&e.readme?new Blob([e.readme]).size:null,be.openPreserveFiles=()=>e.openPreserveFiles(),be.previewPreserved=()=>e.previewPreserved(),be.retryContent=()=>e.retryPreview();let ot=k=>Me.has(k)||/\.(pdf|png|jpe?g|gif|svg|ico|bmp|tiff?|webp|avif|heic|heif|mp4|webm|mp3|wav|zip|bin)$/i.test(k),at=(k="")=>({path:k,loading:!1,note:"",loadError:""});e.previewFile="",e.previewDoc=at();let yt=0,lt=null;e.previewOpenPath=()=>e.previewFile||e.readmePath(),e.openPreviewFile=k=>{if(k=k||"",k&&k===e.readmePath()&&(k=""),yt++,lt=null,Yn(),Yt.cancel(),e.previewFile=k,e.previewDoc=at(k),be.sidebarCollapsed=!0,be.content=null,!k){e.readme?Yt():e.previewStatus="idle";return}if(ot(k)){cr("binary"),e.previewStatus="ready";return}ft(k)};function dt(){yt++,lt=null,e.previewFile="",e.previewDoc=at(),be.sidebarCollapsed=!0,be.content=null}function ft(k){let M=++yt;lt=null,Object.assign(e.previewDoc,{loading:!0,loadError:""}),e.previewStatus="loading";let B;try{B=parseGithubUrl(e.sourceUrl)}catch{B=null}if(!B||!e.source?.commit){Object.assign(e.previewDoc,{loading:!1,loadError:"The repository is still loading. Try again in a moment."}),e.previewStatus="error";return}t.get(`/api/repo/${B.owner}/${B.repo}/file`,{params:{commit:e.source.commit,path:k,connection:e.githubConnection,anonymizedRepoId:e.isUpdate&&i.repoId&&me(e.sourceUrl)===e._originalFullName?i.repoId:void 0,repositoryID:Se()},transformResponse:G=>G}).then(G=>{if(M!==yt)return;e.previewDoc.loading=!1;let ue=typeof G.headers=="function"&&G.headers("content-type")||"";if(/json/i.test(ue)){let ye=null;try{ye=JSON.parse(G.data)}catch{}if(ye&&ye.binary===!0){cr("binary"),e.previewStatus="ready";return}}lt=typeof G.data=="string"?G.data:"",Yt()},G=>{if(M!==yt)return;e.previewDoc.loading=!1;let ue=ar(G);if(ue==="file_too_big"){cr("too_big"),e.previewStatus="ready";return}e.previewDoc.loadError=Kn.ERRORS[ue]||"GitHub did not return this file.",e.previewStatus="error"})}let Vt;function Yn(){Vt&&window.URL.revokeObjectURL(Vt),Vt=void 0,be.url=void 0}e.on("dispose",Yn);function cr(k){Yn(),e.previewDoc.note=k,be.prepareFile(e.previewPathName(e.previewOpenPath()||e.readmeName())),be.type=k==="too_big"?"error":"binary",be.content=k==="too_big"?"file_too_big":"binary"}function xp(k){try{let M=parseGithubUrl(e.sourceUrl),B=e.source.branch||e.details&&e.details.defaultBranch||"main",G=k&&k.includes("/")?k.slice(0,k.lastIndexOf("/")+1):"";return`https://github.com/${M.owner}/${M.repo}/raw/${B}/${G}`}catch{return""}}let Ja=we("repo",()=>e.previewFile?typeof lt!="string"?null:{content:lt,options:ze()}:e.readme?{content:e.readme,options:ze()}:null,k=>{if(typeof k?.content!="string")throw Error("Invalid preview response");Yn(),window.URL?.createObjectURL&&(be.url=Vt=window.URL.createObjectURL(new Blob([k.content],{type:"text/plain"})));let M=e.previewOpenPath()||e.readmeName();be.prepareFile(e.previewPathName(M)),be.fileBaseUrl=xp(M),be.renderFileContent(k.content,be.type,be.fileBaseUrl,"text/plain"),e.previewFile||(e.anonymize_readme=k.content)}),Yt=()=>{e.previewFile&&typeof lt!="string"||Ja()};Yt.cancel=Ja.cancel;let bs=st(new Map),pr=new Set,fr=new Set,Zs="",xs=null,xo=()=>String(e.terms||"").split(` +`).filter(k=>k.trim());function ef(){xs=null;let k=xo(),M=k.join(` +`);M!==Zs&&(bs.clear(),fr.clear(),Zs=M);let B=[...pr].filter(G=>!bs.has(G));if(pr.clear(),!(!B.length||!k.length))for(let G=0;G{if(Zs!==M||xo().join(` +`)!==M)return;let Ke=ye.data?.contents;if(!Array.isArray(Ke)||Ke.length!==ue.length)throw Error("Invalid preview response");ue.forEach((qt,bt)=>bs.set(qt,typeof Ke[bt]=="string"?Ke[bt]:qt))}).catch(()=>{Zs===M&&ue.forEach(ye=>fr.add(ye))})}}e.previewName=k=>{if(!k||!xo().length)return k;if(Zs===xo().join(` +`)){if(bs.has(k))return bs.get(k);if(fr.has(k))return k}return pr.add(k),xs||(xs=d(ef,120)),k},e.previewPathName=k=>{k=String(k||"");let M=k.lastIndexOf("/");return M<0?e.previewName(k):e.previewName(k.slice(0,M))+"/"+e.previewName(k.slice(M+1))},e.watch(()=>[e.repoId,e.previewPathName(e.previewOpenPath()||e.readmeName()),e.previewTreeFiles()],()=>{be.repoId=e.repoId||"repository",be.filePath=e.previewPathName(e.previewOpenPath()||e.readmeName()),be.paths=be.filePath.split("/"),be.files=e.previewTreeFiles(),be.loadedFolders=Object.fromEntries([...ve?.dirs.keys()||[]].map(k=>[e.previewName(k),!0]))},!0),e.on("dispose",()=>{xs&&d.cancel(xs)});function ws(){!e.anonymize||!e.anonymize.terms||Yt()}async function Qa(){let k=parseGithubUrl(e.sourceUrl),M=m();try{Es();let B=await t.get(`/api/pr/${k.owner}/${k.repo}/${k.pullRequestId}`,{params:{connection:e.githubConnection}});if(!b(M))return;e.details=B.data,e.pullRequestId||(e.pullRequestId=k.repo+"-PR"+k.pullRequestId+"-"+generateRandomId(4))}catch(B){if(!b(M))return;throw B.data&&(r("ERRORS."+B.data.error).then(G=>{e.addToast({title:"Error",date:new Date,body:G}),e.error=G},console.error),Ss(B.data.error)),Y("sourceUrl","missing",!1),B}finally{w(M)}}let ks=st(new Map);function tf(){let k=new Set,M=e.details&&e.details.pullRequest;if(!M)return k;typeof M.title=="string"&&k.add(M.title),typeof M.body=="string"&&k.add(M.body),typeof M.diff=="string"&&k.add(M.diff);let B=M.comments||[];for(let G of B)typeof G.author=="string"&&k.add(G.author),typeof G.body=="string"&&k.add(G.body);return k}let Tn=we("pr",()=>{let k=tf(),M=Array.from(k);return M.length===0?null:{contents:M,options:ze()}},(k,M)=>{if(!Array.isArray(k?.contents)||k.contents.length!==M.contents.length||k.contents.some(ue=>typeof ue!="string"))throw Error("Invalid preview response");let B=M.contents,G=new Map;for(let ue=0;ueks.set(ye,ue))});e.anonymizePrContent=function(k){return k&&(ks.has(k)?ks.get(k):"")};async function Za(){let k=parseGithubUrl(e.sourceUrl),M=m();try{Es(),e.gistOAuthRequired=!1,e.gistAppRequired=!1;let B=await t.get(`/api/gist/source/${k.gistId}`);if(!b(M))return;e.details=B.data,e.gistId||(e.gistId="gist-"+k.gistId.substring(0,6)+"-"+generateRandomId(4))}catch(B){if(!b(M))return;if(B.data?.error==="github_app_reconnect_required"){e.gistAppRequired=!0,Y("sourceUrl","missing",!1);return}if(B.data?.error==="github_oauth_required"){e.gistOAuthRequired=!0,Y("sourceUrl","missing",!1);return}throw B.data&&(r("ERRORS."+B.data.error).then(G=>{e.addToast({title:"Error",date:new Date,body:G}),e.error=G},console.error),Ss(B.data.error)),Y("sourceUrl","missing",!1),B}finally{w(M)}}let Cs=st(new Map);function nf(){let k=new Set,M=e.details&&e.details.gist;if(!M)return k;typeof M.description=="string"&&k.add(M.description),typeof M.ownerLogin=="string"&&k.add(M.ownerLogin);let B=M.files||[];for(let ue of B)typeof ue.filename=="string"&&k.add(ue.filename),typeof ue.content=="string"&&k.add(ue.content);let G=M.comments||[];for(let ue of G)typeof ue.author=="string"&&k.add(ue.author),typeof ue.body=="string"&&k.add(ue.body);return k}let On=we("gist",()=>{let k=nf(),M=Array.from(k);return M.length===0?null:{contents:M,options:ze()}},(k,M)=>{if(!Array.isArray(k?.contents)||k.contents.length!==M.contents.length||k.contents.some(ue=>typeof ue!="string"))throw Error("Invalid preview response");let B=M.contents,G=new Map;for(let ue=0;ueCs.set(ye,ue)),mr()});e.anonymizeGistContent=function(k){return k&&(Cs.has(k)?Cs.get(k):"")},e.previewGistFiles=[];function mr(){let k=e.details&&e.details.gist&&e.details.gist.files||[];e.previewGistFiles=k.map(M=>({filename:e.anonymizeGistContent(M.filename),content:e.anonymizeGistContent(M.content),language:M.language}))}e.watch("details.gist.files",mr,!0),e.watch("terms",mr);function sf(){let k=e.conference;if(e.conference_data=null,!k)return;let M=k===v||e.isUpdate&&k===e._originalConference;k!==v&&(v=null),t.get("/api/conferences/"+k).then(B=>{e.conference===k&&(e.conference_data=B.data,e.conference_data.startDate=new Date(e.conference_data.startDate),e.conference_data.endDate=new Date(e.conference_data.endDate),!M&&(e.options.expirationDate=new Date(e.conference_data.endDate),e.options.expirationMode="remove",e.options.update=e.conference_data.options.update,e.options.image=e.conference_data.options.image,e.options.pdf=e.conference_data.options.pdf,e.options.notebook=e.conference_data.options.notebook,e.options.link=e.conference_data.options.link))},()=>{e.conference===k&&(e.conference_data=null)})}function Es(){Y("repoId","used",!0),Y("repoId","format",!0),Y("pullRequestId","used",!0),Y("pullRequestId","format",!0),Y("gistId","used",!0),Y("gistId","format",!0),Y("sourceUrl","used",!0),Y("sourceUrl","missing",!0),Y("sourceUrl","access",!0),Y("sourceUrl","github",!0),Y("commit","exists",!0),Y("conference","activated",!0),Y("terms","format",!0),e.termHints=[]}function ei(){if(e.detectedType==="repo"&&e.options.expirationMode==="never")return!1;let k=e.anonymize&&e.anonymize.expirationDate;return!e.options.expirationDate||k&&k.invalid?(k&&k.setDirty&&k.setDirty(),e.error="Please choose a valid expiration date.",!0):!1}function Ss(k){let M=e.detectedType==="pr"?"pullRequestId":e.detectedType==="gist"?"gistId":"repoId";switch(k){case"repoId_already_used":Y(M,"used",!1);break;case"invalid_repoId":Y(M,"format",!1);break;case"options_not_provided":Y(M,"format",!1);break;case"repo_already_anonymized":Y("sourceUrl","used",!1);break;case"invalid_terms_format":Y("terms","format",!1);break;case"repo_not_found":Y("sourceUrl","missing",!1);break;case"repo_not_accessible":Y("sourceUrl","access",!1);break;case"commit_not_found":Y("commit","exists",!1);break;case"conf_not_activated":Y("conference","activated",!1);break}}e.coauthors=e.coauthors||[],e.coauthorResults=[],e.coauthorError="",e.searchCoauthors=()=>{let k=(e.coauthorSearch||"").trim();if(e.coauthorError="",k.length<2){e.coauthorResults=[];return}t.get("/api/user/search/github-users",{params:{q:k}}).then(M=>{let B=new Set((e.coauthors||[]).map(G=>(G.username||"").toLowerCase()));e.coauthorResults=(M.data||[]).filter(G=>!B.has((G.username||"").toLowerCase()))},()=>{e.coauthorResults=[]})},e.addCoauthor=(k,M)=>{M&&M.preventDefault(),!(!k||!k.username)&&t.post("/api/repo/"+e.repoId+"/coauthors",{username:k.username}).then(B=>{e.coauthors=B.data||[],e.coauthorResults=[],e.coauthorSearch="",e.coauthorError=""},B=>{let G=B&&B.data&&B.data.error||"unknown_error";e.coauthorError=G})},e.removeCoauthor=k=>{!k||!k.username||confirm("Remove co-author "+k.username+"?")&&t.delete("/api/repo/"+e.repoId+"/coauthors/"+encodeURIComponent(k.username)).then(M=>{e.coauthors=M.data||[]},M=>{let B=M&&M.data&&M.data.error||"unknown_error";e.coauthorError=B})},e.anonymizeRepo=k=>{if(e.sourceLoading){e.error="Wait for the source to finish loading before saving.";return}if(e.reconnectingSource&&!e.reconnectRepositoryId)return;if(ei()){e.editRepository();return}if(e.anonymize?.invalid||e.sourceUrlError){e.editRepository(),e.error="Please correct the highlighted fields before saving.";return}if(e.hostingNeedsPayment()&&e.options.expirationMode==="never"){e.hostingReview=!0,tt(()=>document.getElementById("repository-hosting")?.scrollIntoView({block:"center"}));return}let M=k.currentTarget||k.target.closest?.("button")||k.target;M.disabled=!0;let B=parseGithubUrl(e.sourceUrl),G={repoId:e.repoId,terms:e.terms.trim().split(` +`).filter(ye=>ye),connection:e.githubConnection,fullName:`${B.owner}/${B.repo}`,repository:e.sourceUrl,reconnectRepositoryId:e.reconnectRepositoryId,options:e.options,source:e.source,conference:e.conference};e.details&&(G.options.pageSource=e.details.pageSource),Es();let ue=e.isUpdate?"/api/repo/"+e.repoId:"/api/repo/";t.post(ue,G,{headers:{"Content-Type":"application/json"}}).then(()=>{R.clear(),window.location.href="/status/"+e.repoId},ye=>{if(ye.data){let Ke=["quota_exceeded","subscription_required_for_never_expiration"].includes(ye.data.error);Ke||r("ERRORS."+ye.data.error).then(qt=>{e.error=qt},console.error),Ss(ye.data.error),Ke&&(ye.data.error==="subscription_required_for_never_expiration"&&(e._existingNever=!1),e.hostingQuotaBlocked=!0,e.hostingReview=!0,tt(()=>document.getElementById("repository-hosting")?.scrollIntoView({block:"center"})))}}).finally(()=>{M.disabled=!1})},e.anonymizeGist=k=>{if(e.sourceLoading){e.error="Wait for the source to finish loading before saving.";return}if(ei())return;if(e.anonymize?.invalid||e.sourceUrlError){e.error="Please correct the highlighted fields before saving.";return}let M=k.currentTarget||k.target.closest?.("button")||k.target;M.disabled=!0;let B=parseGithubUrl(e.sourceUrl),G={gistId:e.gistId,terms:e.terms.trim().split(` +`).filter(ye=>ye),source:{gistId:B.gistId},options:e.options,conference:e.conference};Es();let ue=e.isUpdate?"/api/gist/"+e.gistId:"/api/gist/";t.post(ue,G,{headers:{"Content-Type":"application/json"}}).then(()=>{R.clear(),window.location.href="/gist/"+e.gistId},ye=>{ye.data&&(r("ERRORS."+ye.data.error).then(Ke=>{e.error=Ke},console.error),Ss(ye.data.error))}).finally(()=>{M.disabled=!1})},e.anonymizePullRequest=k=>{if(e.sourceLoading){e.error="Wait for the source to finish loading before saving.";return}if(ei())return;if(e.anonymize?.invalid||e.sourceUrlError){e.error="Please correct the highlighted fields before saving.";return}let M=k.currentTarget||k.target.closest?.("button")||k.target;M.disabled=!0;let B=parseGithubUrl(e.sourceUrl),G={pullRequestId:e.pullRequestId,connection:e.githubConnection,terms:e.terms.trim().split(` +`).filter(ye=>ye),source:{repositoryFullName:`${B.owner}/${B.repo}`,pullRequestId:B.pullRequestId},options:e.options,conference:e.conference};Es();let ue=e.isUpdate?"/api/pr/"+e.pullRequestId:"/api/pr/";t.post(ue,G,{headers:{"Content-Type":"application/json"}}).then(()=>{R.clear(),window.location.href="/pr/"+e.pullRequestId},ye=>{ye.data&&(r("ERRORS."+ye.data.error).then(Ke=>{e.error=Ke},console.error),Ss(ye.data.error))}).finally(()=>{M.disabled=!1})},e.watch("conference",()=>{sf()}),e.termHints=[],e.matchTermAsWritten=k=>{e.terms=Tc(e.terms,k)},e.watch("options.preserveFiles",()=>{e.detectedType==="repo"&&Yt()}),e.watch("terms",()=>{e.termHints=Ac(e.terms),e.detectedType==="repo"&&ws(),e.detectedType==="pr"&&Tn(),e.detectedType==="gist"&&On()}),e.watch("options.image",()=>{e.detectedType==="repo"&&ws(),e.detectedType==="pr"&&Tn(),e.detectedType==="gist"&&On()}),e.watch("options.link",()=>{e.detectedType==="repo"&&ws(),e.detectedType==="pr"&&Tn(),e.detectedType==="gist"&&On()}),e.watch("details",()=>{e.detectedType==="pr"&&Tn(),e.detectedType==="gist"&&On()},!0)},Ka=function(e,t,s,i,o,r){ha(e);let d=Ct();Ic();let p=Ut(),u=0,y=null,h=null;e.fileLoadingSlow=!1,e.fileReceivedBytes=0;function b(){y&&(y.resolve(),y=null),h&&(d.timeout.cancel(h),h=null)}let m=!1;e.on("dispose",()=>{m=!0,u++,b(),w&&w.resolve()}),e.files=[],e.isMac=/Mac|iPhone|iPad|iPod/.test(navigator.platform||navigator.userAgent),e.fileSearchQuery="",e.fileSearchResults=null,e.fileSearchLoading=!1,p(document,"click",I=>{e.symbolsOpen&&!I.target.closest?.(".symbols")&&(e.symbolsOpen=!1),e.moreOpen&&!I.target.closest?.(".tb-more")&&(e.moreOpen=!1),e.tocOpen&&!I.target.closest?.(".tb-toc-m")&&(e.tocOpen=!1),e.gotoOpen&&I.target.isConnected&&!I.target.closest?.(".goto-pop, .btn-goto, .tb-more")&&(e.gotoOpen=!1),e.accountOpen&&!I.target.closest?.(".acct")&&(e.accountOpen=!1),e.helpOpen&&!I.target.closest?.(".vb-help")&&(e.helpOpen=!1)}),p(document,"keydown",I=>{I.key==="Escape"&&(e.symbolsOpen=!1,e.moreOpen=!1,e.tocOpen=!1,e.gotoOpen=!1,e.accountOpen=!1,e.helpOpen=!1),(I.ctrlKey||I.metaKey)&&!I.altKey&&I.key&&I.key.toLowerCase()==="f"&&e.type==="html"&&window.document.querySelector(".reading-layout")&&(I.preventDefault(),e.toggleMdFind(!0))}),p(document,"keydown",function(I){if((I.metaKey||I.ctrlKey)&&I.key==="k"){I.preventDefault();var U=document.querySelector(".tree-search-input");U&&(U.focus(),U.select())}});var w=null;e.onFileSearchChange=function(){w&&(w.resolve(),w=null);let I=e.fileSearchQuery;if(!I||I.length<2){e.fileSearchResults=null,e.fileSearchLoading=!1;return}e.fileSearchLoading=!0;let U=r.defer();w=U,t.get(`/api/repo/${e.repoId}/files/search?q=${encodeURIComponent(I)}`,{timeout:U.promise}).then(function(C){if(!(m||w!==U)){w=null,e.fileSearchLoading=!1;var L={};e.files.forEach(function(Fe){L[(Fe.path||"")+"/"+Fe.name]=!0});for(var H=[],K={},ie=0;ie0&&e.files.push.apply(e.files,H);for(var Qe=[],He=0;He0&&e.files.push.apply(e.files,Qe),e.fileSearchResults=C.data}},function(){!m&&w===U&&(w=null,e.fileSearchLoading=!1,e.fileSearchResults=[])})},e.on("routeUpdate",function(I,U){if(e.repoId!=i.repoId)return X();if((i.path||"")!=e.filePath){window.matchMedia?.("(max-width: 767px)").matches&&(e.sidebarCollapsed=!0),e.filePath=i.path||"",e.paths=e.filePath.split("/").filter(C=>C&&C.trim().length>0),x();for(let C=0;C0?e.paths.slice(0,C).join("/"):"";e.files.some(K=>K.path===L)||e.getFiles(L)}}});function N(){if(e.paths[0]!="")return;let I=["readme.md","readme.txt","readme.org","readme.1st","readme"],U={};for(let L of e.files)L.name.toLowerCase().indexOf("readme")>-1&&(U[L.name.toLowerCase()]=L.name);let C=null;for(let L of I)if(U[L]){C=L;break}if(!C&&Object.keys(U).length>0&&(C=Object.keys(U)[0]),C){let L=s.url();L[L.length-1]!="/"&&(L+="/"),s.url(L+encodePathForUrl(U[C]))}}e.fileCounts=null;let S=0,R=new Set,v=!1;e.getFiles=function(I,U=!1){let C=e.repoId,L=S;return t.get(`/api/repo/${e.repoId}/files/?path=${encodeURIComponent(I)}&v=${e.options.lastUpdateDate}`).then(function(H){if(m||C!==e.repoId||L!==S)return[];let K=I||"";return e.files=e.files.filter(ie=>ie.path!==K),e.files.push(...H.data),e.loadedFolders={...e.loadedFolders,[K]:!0},E(K,L),H.data},function(H){if(m||C!==e.repoId||L!==S)return[];U||(e.type="error",e.content=ar(H),e.files=[])})};function E(I,U){if(v||R.has(I))return;R.add(I);let C=e.repoId;t.get(`/api/repo/${e.repoId}/files/counts?path=${encodeURIComponent(I)}`).then(function(L){m||C!==e.repoId||U!==S||(e.fileCounts={...e.fileCounts,...L.data})},function(){m||C!==e.repoId||U!==S||(v=!0)})}function D(){return e.files.filter(I=>I.name==e.paths[e.paths.length-1]&&I.path==e.paths.slice(0,e.paths.length-1).join("/"))[0]}var V=null;e.on("dispose",function(){V&&d.interval.cancel(V)});function _(I){if(m)return;let U=e.repoId;t.get(`/api/repo/${e.repoId}/options`).then(C=>{if(!(m||U!==e.repoId)){if(e.options=C.data,e.options.url){window.location=e.options.url;return}I&&I(C.data)}},C=>{if(!(m||U!==e.repoId)){var L=C.data||{};if(L.error==="rate_limited"&&L.resetAt){let K=function(){var ie=Math.max(0,Math.ceil((e.rateLimitResetAt-Date.now())/1e3));if(ie<=0)e.rateLimitCountdown="",e.rateLimitResetAt=0,V&&(d.interval.cancel(V),V=null),_(I);else{var se=Math.floor(ie/60),Y=ie%60;e.rateLimitCountdown=se>0?se+"m "+Y+"s":Y+"s"}};var H=K;e.type="rate_limited",e.rateLimitResetAt=L.resetAt,V&&d.interval.cancel(V),K(),V=d.interval(K,1e3)}else L.error==="repository_not_ready"?(e.type="loading",d.timeout(function(){_(I)},3e3)):(e.type="error",e.content=ar(C))}})}function z(I,U){let C=u;if(!I){e.type="error",e.content="no_file_selected";return}let L=e.type;(L==="code"||L==="text")&&ni().catch(()=>{}),e.type="loading",e.content="loading",e.fileLoadingSlow=!1,e.fileReceivedBytes=0;let H=r.defer();y=H,h=d.timeout(()=>{!m&&C===u&&e.type==="loading"&&(e.fileLoadingSlow=!0)},1500);let K=U&&U.sha||"0";t.get(`/api/repo/${e.repoId}/file/${encodePathForUrl(I)}?v=`+K,{timeout:H.promise,onDownloadProgress:ie=>{!m&&C===u&&(e.fileReceivedBytes=ie)},transformResponse:ie=>ie}).then(ie=>{m||C!==u||(b(),e.renderFileContent(ie.data,L,s.url()+"/../",ie.headers("content-type")))},ie=>{m||C!==u||(b(),e.type="error",e.content=ar(ie))})}function x(){u++,b(),e.content="",e.file=D();let I="0";e.file&&e.file.sha&&(I=e.file.sha),e.url=`/api/repo/${e.repoId}/file/${encodePathForUrl(e.filePath)}?v=${I}`;let U=e.filePath.substring(0,e.filePath.lastIndexOf("/")+1);if(e.fileBaseUrl=`/api/repo/${e.repoId}/file/${U?encodePathForUrl(U):""}`,e.showSource=!1,e.imageSize="",e.allowScripts=!1,e.prepareFile(e.filePath),e.type=="pdf"){e.content="pdf";return}if(e.type=="media"||e.type=="audio"){e.content=e.type;return}z(e.filePath,e.file)}e.isSourceAccessError=()=>["repo_not_found","token_expired","github_app_access_required","github_app_reconnect_required","repo_saml_enforcement","repo_access_limited"].includes(e.content),e.retryContent=()=>X();function X(){u++,b(),e.files=[],e.loadedFolders={},e.content=null,e.fileCounts=null,S++,R=new Set,v=!1,e.fileSearchQuery="",e.onFileSearchChange(),e.repoId=i.repoId,e.type="loading",e.filePath=i.path||"",e.paths=e.filePath.split("/");let I=e.repoId;_(function(U){if(e.filePath){x();let L=[...new Set(e.paths.map((H,K)=>e.paths.slice(0,K).join("/")))];r.all(L.map(H=>e.getFiles(H,!0)));return}var C=r.resolve();for(let L=0;L0?e.paths.slice(0,L).join("/"):"";C=C.then(function(){return e.getFiles(H)}).then(function(){if(e.type==="error")return r.reject("error")})}C.then(function(){m||I!==e.repoId||(e.files.length==1&&e.files[0].name==""?(e.files=[],e.type="empty"):(N(),x()))})})}X()},Bc=function(e,t,s,i,o){async function r(u){t.get(`/api/pr/${e.pullRequestId}/options`).then(y=>{if(e.options=y.data,e.options.url){window.location=e.options.url;return}u&&u(y.data)},y=>{e.type="error",e.content=y.data.error})}async function d(u){t.get(`/api/pr/${e.pullRequestId}/content`).then(y=>{e.details=y.data,e.tabState={active:y.data.diff?"diff":"comments"},u&&u(y.data)},y=>{e.type="error",e.content=y.data.error})}function p(){e.pullRequestId=i.pullRequestId,e.type="loading",r(u=>{d()})}p()},zc=function(e,t,s,i,o){async function r(u){t.get(`/api/gist/${e.gistId}/options`).then(y=>{if(e.options=y.data,e.options.url){window.location=e.options.url;return}u&&u(y.data)},y=>{e.type="error",e.content=y.data.error})}async function d(u){t.get(`/api/gist/${e.gistId}/content`).then(y=>{e.details=y.data;let h=y.data&&y.data.files&&y.data.files.length;e.tabState={active:h?"files":"comments"},u&&u(y.data)},y=>{e.type="error",e.content=y.data.error})}function p(){e.gistId=i.gistId,e.type="loading",r(()=>{d()})}p()},Hc=function(e,t,s){e.watch("user.status",()=>{e.user==null&&s.url("/")}),e.user==null&&s.url("/"),e.conferences=[],e.loading=!0,e.error="",e.search="";let i="conferences.filterPrefs",o={filters:{status:{ready:!0,expired:!1,removed:!1}},orderBy:"name"},r=loadFilterPrefs(i)||{};e.filters={status:Object.assign({},o.filters.status,r.filters&&r.filters.status||{})},e.orderBy=r.orderBy||o.orderBy,e.watch("orderBy",()=>{saveFilterPrefs(i,{filters:e.filters,orderBy:e.orderBy})}),e.watch("filters",()=>{saveFilterPrefs(i,{filters:e.filters,orderBy:e.orderBy})},!0),e.removeConference=function(d){if(!d.removing&&confirm(`Are you sure that you want to remove the conference ${d.name}? All the repositories linked to this conference will expire.`)){d.removing=!0;let p=st({title:`Removing ${d.name}...`,date:new Date,body:`The conference ${d.name} is going to be removed.`});e.addToast(p),t.delete(`/api/conferences/${d.conferenceID}`).then(()=>{p.title=`${d.name} is removed.`,p.body=`The conference ${d.name} is removed.`,e.loadConferences()}).catch(()=>{p.title="Unable to remove conference",p.body="Please try again. The conference has not been removed."}).finally(()=>{d.removing=!1})}},e.loadConferences=()=>(e.loading=!0,e.error="",t.get("/api/conferences/").then(d=>{e.conferences=d.data||[]},d=>{e.error="Unable to load your conferences. Please try again."}).finally(()=>{e.loading=!1})),e.loadConferences(),e.conferenceFilter=d=>{if(e.filters.status[d.status]==!1)return!1;let p=e.search.trim().toLowerCase();return!!(!p||(d.name||"").toLowerCase().includes(p)||(d.conferenceID||"").toLowerCase().includes(p))}},Ya=function(e,t,s,i){e.watch("user.status",()=>{e.user==null&&s.url("/")}),e.user==null&&s.url("/");let o=()=>{for(let[m,w,N]of[["startDate","Starts","startDate"],["endDate","Ends","endDate"]]){let S=document.getElementById(m);if(!S)continue;let R=S.parentElement.querySelector(":scope > .date-echo");R||(R=document.createElement("p"),R.className="date-echo",R.setAttribute("aria-live","polite"),S.insertAdjacentElement("afterend",R));let v=ya(e.options?.[N]);R.textContent=v?w+" "+v:"",R.hidden=!v}};typeof e.watchGroup=="function"&&e.watchGroup(["options.startDate","options.endDate"],()=>tt(o));let r=(m=20)=>{let w=document.querySelector("input#name.form-control"),N=document.querySelector("input#conferenceID.form-control");N&&(N.placeholder="e.g. ICSE27"),w?w.placeholder="e.g. ICSE 2027":m>0&&setTimeout(()=>r(m-1),50)};setTimeout(()=>r(),0),e.plans=[],e.plansLoaded=!1,e.conferenceBilling=null,Wi(t).then(m=>{e.conferenceBilling=m.data}).catch(()=>{}),e.conferenceTiers=()=>e.plans.filter(m=>m.id!=="free_conference").map(m=>{let w=(e.conferenceBilling?.plans||[]).find(N=>N.id===m.id)||{};return{...m,storage:m.storagePerRepo,...w,id:m.id,name:m.name}}),e.conferenceAudience=m=>({conference_workshop:"Workshops and small venues",conference:"A typical conference",conference_large:"Large or multi-track venues"})[m]||"",e.conferencePlanName=m=>jc(m),e.conferenceAmount=(m,w=m?.amount)=>new Intl.NumberFormat(void 0,{style:"currency",currency:m?.currency||"eur",minimumFractionDigits:w%100?2:0,maximumFractionDigits:2}).format(w/100),e.conferenceBytes=m=>{let w=Number(m)||0,N=Math.min(4,Math.floor(Math.log2(Math.max(w,1))/10));return`${new Intl.NumberFormat(void 0,{maximumFractionDigits:1}).format(w/1024**N)} ${["B","KB","MB","GB","TB"][N]}`},e.editionMode=!1,e.saving=!1,e.error="";function d(){return t.get("/api/conferences/"+i.conferenceId).then(m=>{e.options={...e.options,...m.data,billing:m.data.billing||{}},e.options.startDate=new Date(e.options.startDate),e.options.endDate=new Date(e.options.endDate)})}i.conferenceId&&(e.editionMode=!0,d());function p(){t.get("/api/conferences/plans").then(m=>{e.plans=m.data,e.plansLoaded=!0,!e.editionMode&&e.plans.length&&!e.plans.some(w=>w.id==e.options.plan.planID)&&(e.options.plan.planID=(e.plans.find(w=>w.id==="conference")||e.plans[0]).id),e.plan=e.plans.filter(w=>w.id==e.options.plan.planID)[0]})}p();let u=new Date;u.setDate(1),u.setMonth(u.getMonth()+1);let y=new Date(u);y.setTime(u.getTime()+179*864e5),e.options={billing:{},startDate:u,endDate:y,plan:{planID:"free_conference"},options:{link:!0,image:!0,pdf:!0,notebook:!0,update:!0,page:!0}},e.plan=null,e.watch("options.plan.planID",()=>{e.plan=e.plans.filter(m=>m.id==e.options.plan.planID)[0]});function h(){e.conference.name.setValidity("required",!0),e.conference.conferenceID.setValidity("pattern",!0),e.conference.conferenceID.setValidity("required",!0),e.conference.conferenceID.setValidity("used",!0),e.conference.startDate.setValidity("required",!0),e.conference.startDate.setValidity("invalid",!0),e.conference.endDate.setValidity("required",!0),e.conference.endDate.setValidity("invalid",!0),e.conference.setValidity("error",!0)}function b(m){switch(m){case"conf_name_missing":e.conference.name.setValidity("required",!1);break;case"conf_id_missing":e.conference.conferenceID.setValidity("required",!1);break;case"conf_id_format":e.conference.conferenceID.setValidity("pattern",!1);break;case"conf_id_used":e.conference.conferenceID.setValidity("used",!1);break;case"conf_start_date_missing":e.conference.startDate.setValidity("required",!1);break;case"conf_end_date_missing":e.conference.endDate.setValidity("required",!1);break;case"conf_start_date_invalid":e.conference.startDate.setValidity("invalid",!1);break;case"conf_end_date_invalid":e.conference.endDate.setValidity("invalid",!1);break;default:e.conference.setValidity("error",!1);break}}e.submit=function(){if(e.saving)return;e.saving=!0,e.error="";let m=JSON.parse(JSON.stringify(e.options)),w=st({title:`Creating ${m.name}...`,date:new Date,body:`The conference ${m.conferenceID} is in creation.`});e.editionMode&&(w.title=`Updating ${m.name}...`,w.body=`The conference '${m.conferenceID}' is updating.`),e.addToast(w),h(),t.post("/api/conferences/"+(e.editionMode?m.conferenceID:""),m).then(()=>{e.editionMode?(w.title=`${m.name} updated`,w.body=`The conference '${m.conferenceID}' is updated.`):(w.title=`${m.name} created`,w.body=`The conference '${m.conferenceID}' is created.`),s.url("/conference/"+m.conferenceID)},N=>{b(N.data?.error),e.error="Unable to save the conference. Please correct any highlighted fields and try again.",e.removeToast(w)}).finally(()=>{e.saving=!1})}};function jc(e){return{free_conference:"Free (no longer offered to new conferences)",conference_workshop:"Workshop package",conference:"Conference package",conference_large:"Large conference package",premium_conference:"Premium (legacy)",unlimited_conference:"Unlimited (legacy)"}[e]||e||"Free"}var Gc=function(e,t,s,i){Ki(e,t,()=>p(),{confirmedMessage:"Payment status checked. Your conference is ready for submissions once payment is confirmed."}),e.conferencePlanName=u=>jc(u),e.watch("user.status",()=>{e.user==null&&s.url("/")}),e.user==null&&s.url("/"),e.conference=null,e.search="",e.filters={status:{ready:!0,preparing:!0,error:!0,expired:!0,removed:!1}},e.orderBy="-anonymizeDate";let o=Xi,r=["ready","preparing","error","expired","removed"],d={current:u=>u!=="removed",attention:u=>u==="error",removed:u=>u==="removed"};e.confView=()=>Object.keys(d).find(u=>r.every(y=>d[u](y)===(e.filters.status[y]!==!1)))||"custom",e.setConfView=u=>{r.forEach(y=>{e.filters.status[y]=(d[u]||d.current)(y)})},e.confCount=u=>(e.conference?.repositories||[]).filter(y=>d[u](o(y.status))).length,e.copyingId=null,e.copyRepoLink=async u=>{if(!u?.repoId||e.copyingId)return;let y=new URL("/r/"+u.repoId+"/",window.location.origin).href;e.copyingId=u.repoId;try{await Wa(y),e.addToast({title:"Link copied",body:"The anonymous link is ready to share."})}catch{e.addToast({title:"Copy this anonymous link",body:y})}finally{e.copyingId=null}},e.extendingId=null,e.extendRepo=u=>{!u?.repoId||e.extendingId||(e.extendingId=u.repoId,t.post("/api/repo/"+u.repoId+"/extend").then(y=>{let h=y?.data?.expirationDate?` until ${new Date(y.data.expirationDate).toLocaleDateString(void 0,{year:"numeric",month:"short",day:"numeric"})}`:"";e.addToast({title:`${u.repoId} is extended.`,body:`Reviewers can open it again${h}.`}),u.status="ready",y?.data?.expirationDate&&(u.options={...u.options||{},expirationDate:y.data.expirationDate}),e.extendingId=null},y=>{let h=y?.status||y?.data?.status;e.addToast({title:`Couldn't extend ${u.repoId}.`,body:h===401||h===403?"Only the repository's authors can extend this link. Ask them to extend it from My work.":"Try again in a moment."}),e.extendingId=null}))},e.repoFiler=u=>{if(e.filters.status[o(u.status)]==!1)return!1;let y=e.search.trim().toLowerCase();return!!(!y||(u.source?.fullName||"").toLowerCase().includes(y)||(u.repoId||"").toLowerCase().includes(y))};function p(){t.get("/api/conferences/"+i.conferenceId).then(u=>{e.conference=u.data})}p()},Wc=function(e,t){e.notificationEmail="",e.emailSaved=!1,e.saveNotificationEmail=async()=>{e.busy=!0,e.emailSaved=!1,e.connectionError="";try{let s=await t.post("/github/connections/email",{email:e.notificationEmail},{headers:{"X-CSRF-Token":e.connections.csrf}});e.notificationEmail=s.data.notificationEmail,e.user&&(e.user.notificationEmail=s.data.notificationEmail),e.emailSaved=!0}catch(s){e.connectionError=s.data?.error||"Unable to save email address."}finally{e.busy=!1}},e.connections=null,e.connectionError="",e.busy=!1,e.loadConnections=()=>t.get("/github/connections").then(s=>{e.connections=s.data,e.notificationEmail=s.data.notificationEmail||""}).catch(s=>{e.connectionError=s.data?.error||"Unable to load connections."}),e.changeConnection=async(s,i,o)=>{e.busy=!0,e.connectionError="";try{let r=await t.post("/github/connections/migrate",{type:s.type,id:s.id,connection:i,preview:o},{headers:{"X-CSRF-Token":e.connections.csrf}});o?s.eligible=r.data.eligible:await e.loadConnections()}catch(r){e.connectionError=r.data?.error||"Unable to change connection."}finally{e.busy=!1}},e.disconnectOAuth=async()=>{e.busy=!0;try{await t.post("/github/connections/disconnect-oauth",{},{headers:{"X-CSRF-Token":e.connections.csrf}}),await e.loadConnections()}catch(s){e.connectionError=s.data?.error||"Unable to disconnect OAuth."}finally{e.busy=!1}},e.loadConnections()},Kc=function(e,t){e.accountRecovery=!1,t.get("/github/account-recovery").then(s=>{e.accountRecovery=s.data.required}).catch(()=>{})};typeof document<"u"&&document.addEventListener("scroll",e=>{let t=e.target;!t||!t.classList||!t.classList.contains("repo-picker-list")||t.classList.toggle("is-end",t.scrollTop+t.clientHeight>=t.scrollHeight-2)},!0);var Yc=[{path:"/review-link",template:"partials/reviewConsent.htm",title:"Artifact consent \u2013 Anonymous GitHub",setup:(e,t)=>ol(e,t)},{path:"/connections",template:"partials/connections.htm",title:"GitHub connections \u2013 Anonymous GitHub",preserveExplorer:!1,setup:(e,t)=>Wc(e,t.http)},{path:"/signin",template:"partials/signin.htm",title:"Sign in \u2013 Anonymous GitHub",preserveExplorer:!1,setup:(e,t)=>Kc(e,t.http)},{path:"/",template:"partials/home.htm",title:"Anonymous GitHub \u2013 Share the code, not the author",preserveExplorer:!1,setup:(e,t)=>$c(e,t.http,t.location,t.window,t.timeout)},{path:"/dashboard",template:"partials/dashboard.htm",title:"Your anonymizations \u2013 Anonymous GitHub",preserveExplorer:!1,setup:(e,t)=>Fc(e,t.http,t.location,t.promises,t.window,t.quotaService)},{path:"/pr-dashboard",redirect:"/dashboard"},{path:"/anonymize/:repoId?",template:"partials/anonymize.htm",title:"New anonymization \u2013 Anonymous GitHub",preserveExplorer:!1,setup:(e,t)=>dr(e,t.http,t.html,t.params,t.location,t.translate,t.timeout)},{path:"/pull-request-anonymize/:pullRequestId?",template:"partials/anonymize.htm",title:"Anonymize a pull request \u2013 Anonymous GitHub",preserveExplorer:!1,setup:(e,t)=>dr(e,t.http,t.html,t.params,t.location,t.translate,t.timeout)},{path:"/gist-anonymize/:gistId?",template:"partials/anonymize.htm",title:"Anonymize a gist \u2013 Anonymous GitHub",preserveExplorer:!1,setup:(e,t)=>dr(e,t.http,t.html,t.params,t.location,t.translate,t.timeout)},{path:"/status/:repoId",template:"partials/status.htm",title:"Repository status \u2013 Anonymous GitHub",preserveExplorer:!1,setup:(e,t)=>Uc(e,t.http,t.params)},{path:"/conferences",template:"partials/conferences.htm",title:"Your conferences \u2013 Anonymous GitHub",preserveExplorer:!1,setup:(e,t)=>Hc(e,t.http,t.location)},{path:"/conference/new",template:"partials/newConference.htm",title:"New conference \u2013 Anonymous GitHub",preserveExplorer:!1,setup:(e,t)=>Ya(e,t.http,t.location,t.params)},{path:"/conference/:conferenceId/edit",template:"partials/newConference.htm",title:"Edit conference \u2013 Anonymous GitHub",preserveExplorer:!1,setup:(e,t)=>Ya(e,t.http,t.location,t.params)},{path:"/conference/:conferenceId",template:"partials/conference.htm",title:"Conference \u2013 Anonymous GitHub",preserveExplorer:!1,setup:(e,t)=>Gc(e,t.http,t.location,t.params)},{path:"/faq",template:"partials/faq.htm",title:"FAQ \u2013 Anonymous GitHub",preserveExplorer:!1,setup:(e,t)=>qc(e,t.http)},{path:"/profile",template:"partials/profile.htm",title:"Your settings \u2013 Anonymous GitHub",preserveExplorer:!1,setup:(e,t)=>_c(e,t.http,t.translate,t.timeout,t.quotaService)},{path:"/claim",template:"partials/claim.htm",title:"Claim an anonymization \u2013 Anonymous GitHub",preserveExplorer:!1,setup:(e,t)=>Lc(e,t.http,t.location)},{path:"/pr/:pullRequestId/:path(.*)*",template:"partials/pullRequest.htm",title:"Anonymous pull request \u2013 Anonymous GitHub",preserveExplorer:!1,setup:(e,t)=>Bc(e,t.http,t.location,t.params,t.html)},{path:"/gist/:gistId/:path(.*)*",template:"partials/gist.htm",title:"Anonymous gist \u2013 Anonymous GitHub",preserveExplorer:!1,setup:(e,t)=>zc(e,t.http,t.location,t.params,t.html)},{path:"/r/:repoId/:path(.*)*",template:"partials/explorer.htm",title:"Anonymous repository \u2013 Anonymous GitHub",preserveExplorer:!0,setup:(e,t)=>Ka(e,t.http,t.location,t.params,t.html,t.promises)},{path:"/repository/:repoId/:path(.*)*",template:"partials/explorer.htm",title:"Anonymous repository \u2013 Anonymous GitHub",preserveExplorer:!0,setup:(e,t)=>Ka(e,t.http,t.location,t.params,t.html,t.promises)},{path:"/admin/",template:"partials/admin/overview.htm",title:"Admin \xB7 Overview \u2013 Anonymous GitHub",preserveExplorer:!1,setup:(e,t)=>ju(e,t.http,t.location,t.interval)},{path:"/admin/repositories",template:"partials/admin/repositories.htm",title:"Admin \xB7 Repositories \u2013 Anonymous GitHub",preserveExplorer:!1,setup:(e,t)=>$u(e,t.http,t.location)},{path:"/admin/users",template:"partials/admin/users.htm",title:"Admin \xB7 Users \u2013 Anonymous GitHub",preserveExplorer:!1,setup:(e,t)=>Fu(e,t.http,t.location)},{path:"/admin/users/:username",template:"partials/admin/user.htm",title:"Admin \xB7 User details \u2013 Anonymous GitHub",preserveExplorer:!1,setup:(e,t)=>Uu(e,t.http,t.location,t.params)},{path:"/admin/conferences",template:"partials/admin/conferences.htm",title:"Admin \xB7 Conferences \u2013 Anonymous GitHub",preserveExplorer:!1,setup:(e,t)=>Bu(e,t.http,t.location)},{path:"/admin/emails",template:"partials/admin/emails.htm",title:"Admin \xB7 Emails \u2013 Anonymous GitHub",preserveExplorer:!1,setup:(e,t)=>Ku(e,t.http,t.location)},{path:"/admin/billing",template:"partials/admin/billing.htm",title:"Admin \xB7 Billing \u2013 Anonymous GitHub",preserveExplorer:!1,setup:(e,t)=>Wu(e,t.http,t.location)},{path:"/admin/queues",template:"partials/admin/queues.htm",title:"Admin \xB7 Queues \u2013 Anonymous GitHub",preserveExplorer:!1,setup:(e,t)=>zu(e,t.http,t.location,t.interval,t.timeout)},{path:"/admin/errors",template:"partials/admin/errors.htm",title:"Admin \xB7 Errors \u2013 Anonymous GitHub",preserveExplorer:!1,setup:(e,t)=>Hu(e,t.http,t.location,t.interval)},{path:"/404",template:"partials/404.htm",title:"Page not found \u2013 Anonymous GitHub",preserveExplorer:!1,setup:()=>{}},{path:"/:pathMatch(.*)*",template:"partials/404.htm",title:"Page not found \u2013 Anonymous GitHub",setup:()=>{}}];var kv={class:"container paper-page admin-page overview-page emails-page"},Cv={class:"email-overview-toolbar"},Ev={class:"seg-filter",role:"group","aria-label":"History period"},Sv=["aria-pressed","onClick"],Nv={class:"email-refresh"},Rv={key:0},Pv=["disabled"],Dv={key:0,class:"email-state email-state-error",role:"alert"},Av=["aria-busy"],Tv={class:"ov-kpi-card"},Ov={class:"ov-kpi-value"},Iv={class:"ov-kpi-card"},Mv={class:"ov-kpi-value"},Vv={class:"ov-kpi-card"},qv={class:"ov-kpi-card"},_v={class:"ov-kpi-value"},Lv={class:"ov-kpi-sub"},$v={key:1,class:"ov-chart-card email-chart","aria-label":"Email activity by day"},Fv={class:"ov-chart-head"},Uv={class:"ov-chart-title"},Bv={class:"email-muted"},zv={class:"email-chart-plot"},Hv={class:"email-axis"},jv={class:"email-bars"},Gv=["aria-label","title"],Wv={class:"email-chart-dates"},Kv={key:0},Yv={class:"email-chart-data"},Xv={class:"email-data-scroll"},Jv={scope:"row"},Qv={"aria-labelledby":"email-history-title",class:"email-history"},Zv={class:"email-section-head"},xv={class:"email-muted"},ey={class:"email-search"},ty={class:"email-status-tabs",role:"group","aria-label":"Outcome filter"},ny=["aria-pressed","onClick"],sy={class:"sr-only",role:"status","aria-live":"polite","aria-atomic":"true"},oy={key:0,class:"email-state email-state-error",role:"alert"},iy=["disabled"],ry={key:1,class:"email-state"},ay={key:2,class:"email-state"},ly={key:3,class:"email-footer email-pager-top"},dy=["disabled"],uy=["disabled"],cy=["aria-busy"],py={class:"email-table",role:"table"},fy={role:"rowgroup"},my={class:"email-recipient",role:"cell"},hy=["title"],gy={class:"email-result",role:"cell"},vy={key:0,class:"email-http"},yy={class:"email-type",role:"cell"},by={class:"email-attempted",role:"cell"},wy=["datetime","title"],ky={class:"email-expand",role:"cell"},Cy=["aria-expanded","aria-controls","aria-label","onClick"],Ey={"aria-hidden":"true"},Sy={key:0,class:"email-expanded",role:"row"},Ny={colspan:"5",role:"cell"},Ry=["id","aria-label"],Py={class:"email-detail-heading"},Dy={class:"email-explanation"},Ay={class:"email-detail-grid"},Ty=["onClick"],Oy=["onClick"],Iy=["onClick"],My=["onClick"],Vy={key:0,class:"email-copy-feedback"},qy={key:5,class:"email-footer"},_y=["disabled"],Ly=["disabled"];function Xc(e,t){return a(),l("div",kv,[t[43]||(t[43]=Ce('
Admin \xA0/\xA0 Emails

Emails

',2)),n("div",Cv,[n("div",Ev,[(a(),l(q,null,Q([{id:"7d",label:"7 days"},{id:"30d",label:"30 days"},{id:"90d",label:"90 days"},{id:"all",label:"All time"}],s=>n("button",{key:s.id,class:P(["seg-chip",{active:e.emailPeriod===s.id}]),"aria-pressed":e.emailPeriod===s.id,onClick:i=>{e.emailPeriod=s.id,e.applyEmailFilters()}},c(s.label),11,Sv)),64))]),n("button",{class:"email-detail-button email-jump",onClick:t[0]||(t[0]=s=>e.jumpToEmailHistory())},"Search email history \u2193"),n("div",Nv,[e.emailUpdated?(a(),l("span",Rv,"History updated "+c(e.emailShortTime(e.emailUpdated)),1)):f("v-if",!0),n("button",{class:"btn btn-sm",disabled:e.emailLoading||e.emailSummaryLoading,onClick:t[1]||(t[1]=s=>e.refreshEmails())},"Refresh",8,Pv)])]),t[44]||(t[44]=n("p",{class:"email-basis"},"Recorded sending attempts \xB7 Provider acceptance does not confirm inbox delivery.",-1)),e.emailSummaryError?(a(),l("div",Dv,[g(c(e.emailSummaryError)+" ",1),n("button",{class:"btn btn-sm",onClick:t[2]||(t[2]=s=>e.loadEmailSummary())},"Retry summary")])):f("v-if",!0),n("section",{class:"ov-kpi-row email-kpis","aria-label":"Email summary","aria-busy":e.emailSummaryLoading},[n("div",Tv,[t[14]||(t[14]=n("div",{class:"ov-kpi-label"},"Recorded attempts",-1)),n("div",Ov,c(e.emailSummary?e.emailSummary.total.toLocaleString():"\u2014"),1),t[15]||(t[15]=n("div",{class:"ov-kpi-sub"},"Selected period, search and type",-1))]),n("div",Iv,[t[16]||(t[16]=n("div",{class:"ov-kpi-label"},"Accepted by provider",-1)),n("div",Mv,c(e.emailSummary?e.emailSummary.counts.accepted.toLocaleString():"\u2014"),1),t[17]||(t[17]=n("div",{class:"ov-kpi-sub"},"Delivery unverified",-1))]),n("div",Vv,[t[18]||(t[18]=n("div",{class:"ov-kpi-label"},"Rejected",-1)),n("div",{class:P(["ov-kpi-value",{"email-error-text":e.emailSummary?.counts.rejected}])},c(e.emailSummary?e.emailSummary.counts.rejected.toLocaleString():"\u2014"),3),t[19]||(t[19]=n("div",{class:"ov-kpi-sub"},"Provider returned an error",-1))]),n("div",qv,[t[20]||(t[20]=n("div",{class:"ov-kpi-label"},"Unconfirmed",-1)),n("div",_v,c(e.emailSummary?(e.emailSummary.counts.unknown+e.emailSummary.counts.sending).toLocaleString():"\u2014"),1),n("div",Lv,c(e.emailSummary?e.emailSummary.counts.unknown:"\u2014")+" unknown \xB7 "+c(e.emailSummary?e.emailSummary.counts.sending:"\u2014")+" pending",1)])],8,Av),e.emailSummary?(a(),l("section",$v,[n("div",Fv,[n("h2",Uv,[t[21]||(t[21]=g("Sending activity ",-1)),n("span",Bv,"\xB7 "+c(e.emailSummary.chartDays)+" days \xB7 UTC",1)]),t[22]||(t[22]=n("div",{class:"email-legend"},[n("span",{class:"email-outcome email-outcome-accepted"},"Accepted"),n("span",{class:"email-outcome email-outcome-rejected"},"Rejected"),n("span",{class:"email-outcome email-outcome-unknown"},"Unconfirmed")],-1))]),n("div",zv,[n("div",Hv,[n("span",null,c(e.emailChartMax()),1),t[23]||(t[23]=n("span",null,"0",-1))]),n("div",jv,[(a(!0),l(q,null,Q(e.emailSummary.series,s=>(a(),l("div",{key:s.date,class:"email-bar-column","aria-label":e.emailDayLabel(s)+": "+s.accepted+" accepted, "+s.rejected+" rejected, "+(s.unknown+s.sending)+" unconfirmed",title:e.emailDayLabel(s)+": "+e.emailDayTotal(s)+" attempts"},[n("div",{class:"email-bar-stack",style:Te({height:Math.max(1,e.emailDayTotal(s)/e.emailChartMax()*100)+"%"})},[n("i",{class:"email-bar-accepted",style:Te({flexGrow:s.accepted})},null,4),n("i",{class:"email-bar-rejected",style:Te({flexGrow:s.rejected})},null,4),n("i",{class:"email-bar-unknown",style:Te({flexGrow:s.unknown+s.sending})},null,4)],4)],8,Gv))),128))])]),n("div",Wv,[n("span",null,c(e.emailDayLabel(e.emailSummary.series[0])),1),e.emailChartTotal()?f("v-if",!0):(a(),l("span",Kv,"No recorded activity in these "+c(e.emailSummary.chartDays)+" days",1)),n("span",null,c(e.emailDayLabel(e.emailSummary.series[e.emailSummary.series.length-1])),1)]),n("details",Yv,[t[26]||(t[26]=n("summary",null,"View daily counts",-1)),n("div",Xv,[n("table",null,[t[24]||(t[24]=n("caption",{class:"sr-only"},"Daily sending attempts in UTC",-1)),t[25]||(t[25]=n("thead",null,[n("tr",null,[n("th",{scope:"col"},"Date"),n("th",{scope:"col"},"Accepted"),n("th",{scope:"col"},"Rejected"),n("th",{scope:"col"},"Unknown"),n("th",{scope:"col"},"Pending")])],-1)),n("tbody",null,[(a(!0),l(q,null,Q(e.emailSummary.series,s=>(a(),l("tr",{key:s.date},[n("th",Jv,c(e.emailDayLabel(s)),1),n("td",null,c(s.accepted),1),n("td",null,c(s.rejected),1),n("td",null,c(s.unknown),1),n("td",null,c(s.sending),1)]))),128))])])])])])):f("v-if",!0),n("section",Qv,[n("div",Zv,[t[27]||(t[27]=n("h2",{id:"email-history-title",tabindex:"-1"},"Email history",-1)),n("span",xv,"Newest first \xB7 "+c(e.emailTimezone),1)]),n("form",{class:"email-toolbar",onSubmit:t[7]||(t[7]=ae(s=>e.applyEmailFilters(),["prevent"])),"aria-label":"Filter email history"},[n("label",ey,[t[28]||(t[28]=g("Search attempts",-1)),T(n("input",{class:"form-control","onUpdate:modelValue":t[3]||(t[3]=s=>e.emailSearch=s),type:"search",maxlength:"200",placeholder:"Search recipients or IDs","aria-describedby":"email-search-help"},null,512),[[rt,e.emailSearch]])]),n("label",null,[t[30]||(t[30]=g("Email type",-1)),T(n("select",{class:"form-control","onUpdate:modelValue":t[4]||(t[4]=s=>e.emailKind=s),onChange:t[5]||(t[5]=s=>e.applyEmailFilters())},[...t[29]||(t[29]=[n("option",{value:""},"All email types",-1),n("option",{value:"repository-expiration"},"Repository expiration",-1),n("option",{value:"owner-access"},"GitHub access",-1)])],544),[[Wt,e.emailKind]])]),t[31]||(t[31]=n("button",{class:"btn",type:"submit"},"Search",-1)),e.hasEmailFilters()?(a(),l("button",{key:0,class:"btn",type:"button",onClick:t[6]||(t[6]=s=>e.clearEmailFilters())},"Clear")):f("v-if",!0)],32),t[42]||(t[42]=n("p",{id:"email-search-help",class:"email-search-help"},"Search part of a recipient address, or an exact attempt, owner or resource ID.",-1)),n("div",ty,[(a(),l(q,null,Q(["","accepted","rejected","unknown","sending"],s=>n("button",{key:s,class:P({active:e.emailState===s}),"aria-pressed":e.emailState===s,onClick:i=>e.setEmailStatus(s)},[g(c(s?e.emailStatusLabel(s):"All attempts")+" ",1),n("span",null,c(e.emailSummary?(s?e.emailSummary.counts[s]:e.emailSummary.total).toLocaleString():"\u2014"),1)],10,ny)),64))]),n("p",sy,c(e.emailAnnouncement)+" "+c(e.emailCopyMessage),1),e.emailError?(a(),l("div",oy,[n("span",null,c(e.emailError),1),n("button",{class:"btn btn-sm",disabled:e.emailLoading,onClick:t[8]||(t[8]=s=>e.retryEmails())},"Retry",8,iy)])):f("v-if",!0),e.emailLoading&&!e.emailRows.length?(a(),l("p",ry,"Loading email history\u2026")):f("v-if",!0),!e.emailLoading&&!e.emailError&&!e.emailRows.length?(a(),l("div",ay,[n("p",null,c(e.hasEmailFilters()?"No attempts match these filters. Try another recipient or a wider period.":"No attempts recorded in this period."),1),e.hasEmailFilters()?(a(),l("button",{key:0,class:"btn btn-sm",onClick:t[9]||(t[9]=s=>e.clearEmailFilters())},"Clear filters")):f("v-if",!0)])):f("v-if",!0),e.emailRows.length?(a(),l("div",ly,[n("span",null,[g(c((e.emailPage-1)*25+1)+"\u2013"+c(Math.min(e.emailPage*25,e.emailRows.length)),1),e.emailTotal()!=null?(a(),l(q,{key:0},[g(" of "+c(e.emailTotal().toLocaleString()),1)],64)):f("v-if",!0),t[32]||(t[32]=g(" attempts",-1))]),n("div",null,[n("button",{class:"btn btn-sm",disabled:e.emailPage===1||e.emailLoading,onClick:t[10]||(t[10]=s=>e.emailPreviousPage())},"Previous",8,dy),n("button",{class:"btn btn-sm",disabled:e.emailLoading||!e.emailNextCursor&&e.emailPage*25>=e.emailRows.length,onClick:t[11]||(t[11]=s=>e.emailNextPage())},"Next",8,uy)])])):f("v-if",!0),e.emailRows.length?(a(),l("div",{key:4,class:"email-table-wrap","aria-busy":e.emailLoading},[n("table",py,[t[40]||(t[40]=n("caption",{class:"sr-only"},"Recorded email attempts. Expand a row for identifiers and outcome details.",-1)),t[41]||(t[41]=n("thead",{role:"rowgroup"},[n("tr",{role:"row"},[n("th",{scope:"col"},"Recipient"),n("th",{scope:"col"},"Outcome"),n("th",{scope:"col"},"Email type"),n("th",{scope:"col"},"Attempted"),n("th",{scope:"col"},[n("span",{class:"sr-only"},"Details")])])],-1)),n("tbody",fy,[(a(!0),l(q,null,Q(e.emailVisibleRows(),s=>(a(),l(q,{key:s._id},[n("tr",{role:"row",class:P({"email-selected":e.selectedEmailId===s._id})},[n("td",my,[n("span",{title:s.recipient},c(s.recipient),9,hy)]),n("td",gy,[n("span",{class:P(["email-outcome","email-outcome-"+s.state])},c(e.emailStatusLabel(s.state)),3),s.httpStatus?(a(),l("small",vy,c(s.httpStatus),1)):f("v-if",!0)]),n("td",yy,c(e.emailKindLabel(s.kind)),1),n("td",by,[n("time",{datetime:s.createdAt,title:e.emailTime(s.createdAt)},c(e.emailShortTime(s.createdAt)),9,wy)]),n("td",ky,[n("button",{class:"email-detail-button","aria-expanded":e.selectedEmailId===s._id,"aria-controls":"detail-"+s._id,"aria-label":(e.selectedEmailId===s._id?"Close":"View")+" details for "+s.recipient,onClick:i=>e.toggleEmail(s)},[g(c(e.selectedEmailId===s._id?"Close":"Details")+" ",1),n("span",Ey,c(e.selectedEmailId===s._id?"\u2212":"+"),1)],8,Cy)])],2),e.selectedEmailId===s._id?(a(),l("tr",Sy,[n("td",Ny,[n("section",{id:"detail-"+s._id,"aria-label":"Attempt details for "+s.recipient},[n("div",Py,[t[33]||(t[33]=n("h3",null,"Attempt details",-1)),n("span",{class:P(["email-outcome","email-outcome-"+s.state])},c(e.emailStatusLabel(s.state)),3)]),n("p",Dy,c(e.emailExplanation(s)),1),n("dl",Ay,[n("div",null,[t[34]||(t[34]=n("dt",null,"Recipient",-1)),n("dd",null,[g(c(s.recipient)+" ",1),n("button",{class:"email-copy",onClick:i=>e.copyEmail(s.recipient),"aria-label":"Copy recipient"},c(e.emailCopiedValue===s.recipient?"Copied":"Copy"),9,Ty)])]),n("div",null,[t[35]||(t[35]=n("dt",null,"Provider response",-1)),n("dd",null,c(s.httpStatus?"HTTP "+s.httpStatus:"No HTTP response recorded"),1)]),n("div",null,[t[36]||(t[36]=n("dt",null,"Attempted",-1)),n("dd",null,c(e.emailTime(s.createdAt)),1)]),n("div",null,[t[37]||(t[37]=n("dt",null,"Completed",-1)),n("dd",null,c(e.emailTime(s.completedAt)),1)]),n("div",null,[t[38]||(t[38]=n("dt",null,"Attempt ID",-1)),n("dd",null,[n("code",null,c(s._id),1),n("button",{class:"email-copy",onClick:i=>e.copyEmail(s._id),"aria-label":"Copy attempt ID"},c(e.emailCopiedValue===s._id?"Copied":"Copy"),9,Oy)])]),n("div",null,[t[39]||(t[39]=n("dt",null,"Owner ID",-1)),n("dd",null,[n("code",null,c(s.ownerId),1),n("button",{class:"email-copy",onClick:i=>e.copyEmail(s.ownerId),"aria-label":"Copy owner ID"},c(e.emailCopiedValue===s.ownerId?"Copied":"Copy"),9,Iy)])]),n("div",null,[n("dt",null,"Resource \xB7 "+c(s.resourceKind),1),n("dd",null,[n("code",null,c(s.resourceId),1),n("button",{class:"email-copy",onClick:i=>e.copyEmail(s.resourceId),"aria-label":"Copy resource ID"},c(e.emailCopiedValue===s.resourceId?"Copied":"Copy"),9,My)])])]),e.emailCopyMessage&&e.emailCopyMessage!=="Copied."?(a(),l("p",Vy,c(e.emailCopyMessage),1)):f("v-if",!0)],8,Ry)])])):f("v-if",!0)],64))),128))])])],8,cy)):f("v-if",!0),e.emailRows.length?(a(),l("div",qy,[n("span",null,[g("Page "+c(e.emailPage),1),e.emailPageCount()?(a(),l(q,{key:0},[g(" of "+c(e.emailPageCount()),1)],64)):f("v-if",!0),g(" \xB7 "+c(e.emailTotal()==null?e.emailRows.length+" loaded":e.emailTotal().toLocaleString()+" attempts"),1)]),n("div",null,[n("button",{class:"btn btn-sm",disabled:e.emailPage===1||e.emailLoading,onClick:t[12]||(t[12]=s=>e.emailPreviousPage())},"Previous",8,_y),n("button",{class:"btn btn-sm",disabled:e.emailLoading||!e.emailNextCursor&&e.emailPage*25>=e.emailRows.length,onClick:t[13]||(t[13]=s=>e.emailNextPage())},"Next",8,Ly)])])):f("v-if",!0)]),t[45]||(t[45]=n("details",{class:"email-about"},[n("summary",null,"What this history records"),n("p",null,"New sending attempts only; older sends are not backfilled. Accepted means the provider accepted the request, not that it reached the inbox. Check pending or unknown outcomes in Resend before considering another send. Audit storage failures can leave this history incomplete.")],-1))])}var $y={class:"container py-4",style:{"max-width":"48rem","overflow-wrap":"anywhere"}},Fy={key:0},Uy={key:1,role:"alert"},By={key:2,role:"status"},zy={key:0},Hy={key:1},jy=["disabled"],Gy=["disabled"],Wy=["disabled"],Ky={key:5,class:"mt-4","aria-labelledby":"review-policy-title"},Yy={id:"review-policy-title"},Xy={key:0,role:"alert"},Jy=["disabled"],Qy=["disabled"],Zy=["disabled"],xy={key:6,role:"status"};function Jc(e,t){return a(),l("section",$y,[t[12]||(t[12]=n("a",{href:"/"},"Anonymous GitHub",-1)),t[13]||(t[13]=n("h1",{class:"mt-3"},"Approve artifact access",-1)),t[14]||(t[14]=n("p",null,"This records your approval as the repository owner or an authorized co-author.",-1)),e.user?.username?f("v-if",!0):(a(),l("p",Fy,[...t[6]||(t[6]=[g("Sign in first, then reopen the artifact link from your submission. ",-1),n("a",{href:"/signin"},"Sign in",-1)])])),e.error?(a(),l("p",Uy,c(e.error),1)):f("v-if",!0),e.saved?(a(),l("p",By,[t[7]||(t[7]=g("Consent recorded. ",-1)),e.handoffEnabled?(a(),l("span",zy,"Continue to review to finish linking.")):(a(),l("span",Hy,"Artifact linking is not complete. Return to your submission to check its status."))])):f("v-if",!0),e.saved&&e.handoffEnabled?(a(),l("button",{key:3,class:"btn btn-primary",type:"button",onClick:t[0]||(t[0]=(...s)=>e.continueReview&&e.continueReview(...s)),disabled:e.busy},"Continue to review",8,jy)):f("v-if",!0),e.user?.username&&!e.saved?(a(),l("form",{key:4,onSubmit:t[2]||(t[2]=ae((...s)=>e.loadPreview&&e.loadPreview(...s),["prevent"]))},[t[8]||(t[8]=n("label",{for:"review-repository"},"Anonymous repository ID",-1)),T(n("input",{id:"review-repository",class:"form-control","onUpdate:modelValue":t[1]||(t[1]=s=>e.repositoryId=s),maxlength:"128",autocomplete:"off",disabled:e.busy||e.uncertain,"aria-describedby":"review-repository-help"},null,8,Gy),[[rt,e.repositoryId]]),t[9]||(t[9]=n("p",{id:"review-repository-help"},"Use the ID after /r/ in the anonymous repository URL.",-1)),n("button",{type:"submit",class:"btn btn-primary",disabled:e.busy||e.uncertain},"Preview access and retention",8,Wy)],32)):f("v-if",!0),e.preview&&!e.saved?(a(),l("section",Ky,[n("h2",Yy,c(e.preview.repositoryName),1),n("p",null,"Access: "+c(e.preview.policy.access==="anonymous-link"?"Anyone with the anonymous link":"Restricted review access")+".",1),n("p",null,"Retain until "+c(e.preview.policy.retainUntil)+". Policy version "+c(e.preview.policy.version)+".",1),e.expired?(a(),l("p",Xy,"This preview expired. Open a new artifact link from your submission.")):f("v-if",!0),n("div",null,[n("label",null,[T(n("input",{type:"checkbox","onUpdate:modelValue":t[3]||(t[3]=s=>e.acceptAccess=s),disabled:e.busy||e.uncertain||e.expired},null,8,Jy),[[sa,e.acceptAccess]]),t[10]||(t[10]=g(" I approve the access policy above.",-1))])]),n("div",null,[n("label",null,[T(n("input",{type:"checkbox","onUpdate:modelValue":t[4]||(t[4]=s=>e.acceptRetention=s),disabled:e.busy||e.uncertain||e.expired},null,8,Qy),[[sa,e.acceptRetention]]),t[11]||(t[11]=g(" I approve retention until the date above.",-1))])]),n("button",{class:"btn btn-primary",type:"button",onClick:t[5]||(t[5]=(...s)=>e.confirmConsent&&e.confirmConsent(...s)),disabled:e.busy||e.expired||!e.acceptAccess||!e.acceptRetention},c(e.uncertain?"Retry confirmation":"Confirm consent"),9,Zy)])):f("v-if",!0),e.busy?(a(),l("p",xy,"Waiting for the server\u2026")):f("v-if",!0)])}var eb={class:"container paper-page connections-page"},tb={key:0,class:"paper-inline-alert paper-inline-alert-error",role:"alert"},sb={key:1,role:"status"},ob=["disabled"],ib={key:3},rb={key:0,class:"connection-resources"},ab=["disabled"],lb=["disabled"],db={key:0,role:"status"},ub={class:"connections-grid"},cb={key:0},pb={class:"connection-title"},fb={key:0,class:"paper-inline-alert paper-inline-alert-error",role:"alert"},mb={class:"connection-actions"},hb={key:0,class:"btn btn-ink",target:"_self",href:"/github/app/install"},gb=["disabled"],vb={key:1,class:"connection-installations"},yb={key:0},bb=["href"],wb={class:"sr-only"},kb={class:"connection-title"},Cb={key:0,target:"_self",href:"/github/login",class:"btn btn-outline-ink"},Eb={key:1,class:"connection-revoke"},Sb={key:0},Nb=["disabled"],Rb={class:"connection-resources"},Pb={class:"connection-title"},Db={class:"connection-count"},Ab={key:0,class:"connection-empty"},Tb={class:"connection-resource-name"},Ob={key:0,class:"connection-resource-actions"},Ib=["disabled","onClick"],Mb=["disabled","onClick"],Vb={key:1,class:"connection-help",role:"status"},qb=["disabled","onClick"];function Qc(e,t){return a(),l("div",eb,[t[27]||(t[27]=Ce('
My work \xA0/\xA0 GitHub connections

GitHub connections

Manage how GitHub shares your code. Your anonymizations and URLs stay the same.

',2)),e.connectionError?(a(),l("p",tb,c(e.connectionError),1)):f("v-if",!0),!e.connections&&!e.connectionError?(a(),l("p",sb,"Loading your connections\u2026")):f("v-if",!0),!e.connections&&e.connectionError?(a(),l("button",{key:2,class:"btn btn-outline-ink",disabled:e.busy,onClick:t[0]||(t[0]=s=>e.loadConnections())},"Try again",8,ob)):f("v-if",!0),e.connections?(a(),l("div",ib,[e.connections.emailNotificationsEnabled?(a(),l("section",rb,[t[6]||(t[6]=n("h2",null,"Email alerts",-1)),t[7]||(t[7]=n("p",null,"We will email you if your GitHub connection stops working or a repository becomes inaccessible. Your address is never shown on anonymous pages.",-1)),n("form",{onSubmit:t[2]||(t[2]=ae(s=>e.saveNotificationEmail(),["prevent"]))},[t[5]||(t[5]=n("label",{for:"notification-email"},"Email address",-1)),T(n("input",{id:"notification-email",class:"form-control",type:"email",autocomplete:"email",maxlength:"254",required:"","onUpdate:modelValue":t[1]||(t[1]=s=>e.notificationEmail=s),disabled:e.busy},null,8,ab),[[rt,e.notificationEmail]]),n("button",{class:"btn btn-ink mt-2",type:"submit",disabled:e.busy},"Save email address",8,lb),e.emailSaved?(a(),l("p",db,"Email address saved.")):f("v-if",!0)],32)])):f("v-if",!0),n("div",ub,[e.connections.appEnabled?(a(),l("section",cb,[t[15]||(t[15]=n("div",{class:"connection-top"},[n("i",{class:"fab fa-github","aria-hidden":"true"}),n("span",{class:"connection-badge"},"Recommended")],-1)),n("div",pb,[t[8]||(t[8]=n("h2",null,"GitHub App",-1)),n("span",{class:P(["connection-status",{"is-connected":e.connections.appConnected&&!e.connections.appError}])},c(e.connections.appError?"Needs attention":e.connections.appConnected?"Connected":"Not connected"),3)]),t[16]||(t[16]=n("p",null,"Read-only access to gists and the repositories you choose.",-1)),e.connections.appError?(a(),l("p",fb,c(e.connections.appError)+". Reconnect to restore access.",1)):f("v-if",!0),n("div",mb,[e.connections.appConnected&&!e.connections.appError?(a(),l("a",hb,[...t[9]||(t[9]=[g("Manage repository access ",-1),n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-external-link"})],-1)])])):f("v-if",!0),n("a",{class:P(e.connections.appConnected&&!e.connections.appError?"connection-link":"btn btn-ink"),target:"_self",href:"/github/app/login"},c(e.connections.appConnected?"Reconnect account":"Connect GitHub account"),3),e.connections.appConnected?(a(),l("button",{key:1,class:"connection-link connection-refresh",title:"Refresh access",disabled:e.busy,onClick:t[3]||(t[3]=s=>e.loadConnections())},[...t[10]||(t[10]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-refresh"})],-1),n("span",{class:"sr-only"},"Refresh access",-1)])],8,gb)):f("v-if",!0)]),t[17]||(t[17]=n("p",{class:"connection-help"},"Choose repositories on GitHub. Organization access may need an administrator's approval.",-1)),e.connections.installations?.length?(a(),l("ul",vb,[(a(!0),l(q,null,Q(e.connections.installations,s=>(a(),l("li",{key:s.id},[n("div",null,[t[11]||(t[11]=n("span",{class:"connection-label"},"Installed on",-1)),t[12]||(t[12]=g()),n("strong",null,c(s.account),1),s.suspended?(a(),l("span",yb," \xB7 Suspended")):f("v-if",!0)]),e.connections.installations.length>1?(a(),l("a",{key:0,target:"_self",href:"/github/app/install?installationId="+s.id},[t[13]||(t[13]=g("Manage access ",-1)),n("span",wb,"for "+c(s.account),1),t[14]||(t[14]=g(" \u2192",-1))],8,bb)):f("v-if",!0)]))),128))])):f("v-if",!0)])):f("v-if",!0),n("section",null,[t[20]||(t[20]=n("div",{class:"connection-top"},[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-key"})]),n("span",{class:"connection-badge connection-badge-muted"},"Legacy")],-1)),n("div",kb,[t[18]||(t[18]=n("h2",null,"GitHub OAuth",-1)),n("span",{class:P(["connection-status",{"is-connected":e.connections.oauthConnected}])},c(e.connections.oauthConnected?"Connected":"Not connected"),3)]),t[21]||(t[21]=n("p",null,"For existing OAuth anonymizations.",-1)),t[22]||(t[22]=n("p",{class:"connection-help"},"This connection uses GitHub's broader repository permissions. Existing work keeps using it until you switch below.",-1)),e.connections.oauthEnabled?(a(),l("a",Cb,c(e.connections.oauthConnected?"Reconnect OAuth":"Connect legacy OAuth"),1)):f("v-if",!0),e.connections.oauthConnected?(a(),l("div",Eb,[e.connections.gistCount?(a(),l("p",Sb,c(e.connections.gistCount)+" gist(s) use your GitHub App connection when available.",1)):f("v-if",!0),t[19]||(t[19]=n("p",null,"Switch all dependent repositories before revoking access. Gists can use your GitHub App connection.",-1)),e.connections.appConnected?(a(),l("button",{key:1,class:"btn btn-sm btn-outline-danger connection-danger",disabled:e.busy||e.connections.resources.some(s=>s.connection==="oauth"),onClick:t[4]||(t[4]=s=>e.disconnectOAuth())},"Revoke OAuth access",8,Nb)):f("v-if",!0)])):f("v-if",!0)])]),n("section",Rb,[n("div",Pb,[t[23]||(t[23]=n("h2",null,"Repository connections",-1)),n("span",Db,c(e.connections.resources?.length||0)+" "+c((e.connections.resources?.length||0)===1?"resource":"resources"),1)]),t[25]||(t[25]=n("p",null,"Check access, then switch each resource to the GitHub App. After reinstalling the App, reconnect existing resources here to keep their anonymous URLs and published snapshots.",-1)),e.connections.resources?.length?f("v-if",!0):(a(),l("div",Ab,[...t[24]||(t[24]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#project-type-repo"})],-1),n("div",null,[n("h3",null,"No repository connections yet"),n("p",null,"Your repositories and pull requests will appear here once you anonymize them.")],-1),n("a",{class:"connection-link",href:"/anonymize"},"New anonymization \u2192",-1)])])),(a(!0),l(q,null,Q(e.connections.resources,s=>(a(),l("div",{class:"connection-resource",key:s.type+s.id},[n("div",Tb,[n("strong",null,c(s.name||s.id),1),n("small",null,c(s.type)+" \xB7 "+c(s.id),1)]),n("span",{class:P(["connection-badge",{"connection-badge-muted":s.connection==="oauth"}])},c(s.connection==="github-app"?"Read-only App":"Legacy OAuth"),3),!["archived","removed","preparing","queue","removing","expiring"].includes(s.status)&&(s.status!=="download"||s.type==="pull-request"&&(!s.statusDate||new Date(s.statusDate).getTime()<=Date.now()-3e5))&&e.connections.appEnabled&&e.connections.appConnected?(a(),l("div",Ob,[n("button",{class:"btn btn-outline-ink",disabled:e.busy,onClick:i=>e.changeConnection(s,"github-app",!0)},"Check read-only access",8,Ib),s.eligible?(a(),l("button",{key:0,class:"btn btn-ink",disabled:e.busy,onClick:i=>e.changeConnection(s,"github-app",!1)},c(s.connection==="github-app"?"Reconnect read-only access":"Switch to read-only access"),9,Mb)):f("v-if",!0),s.eligible===!1?(a(),l("span",Vb,"Access unavailable. Allow this repository on GitHub, then check again.")):f("v-if",!0)])):f("v-if",!0),!["archived","removed","preparing","queue","removing","expiring"].includes(s.status)&&(s.status!=="download"||s.type==="pull-request"&&(!s.statusDate||new Date(s.statusDate).getTime()<=Date.now()-3e5))&&s.connection==="github-app"&&e.connections.oauthConnected?(a(),l("button",{key:1,class:"connection-link",disabled:e.busy,onClick:i=>e.changeConnection(s,"oauth",!1)},"Use OAuth",8,qb)):f("v-if",!0)]))),128)),t[26]||(t[26]=n("p",{class:"connection-footnote"},[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-info"})]),g(" Removing access stops new fetches from GitHub. Published content keeps its current expiration and removal settings.")],-1))])])):f("v-if",!0)])}var _b={class:"container paper-page auth-page"},Lb={class:"auth-layout"},$b={class:"auth-options"},Fb={key:0},Ub={key:0,class:"btn btn-ink auth-continue",target:"_self",href:"/github/login?recover=1"},Bb={key:1},zb={key:1,class:"auth-card"},Hb={key:2,class:"auth-legacy"},jb={key:3,role:"status"};function Zc(e,t){let s=Xe("partial-view");return a(),l(q,null,[n("div",_b,[n("div",Lb,[t[4]||(t[4]=Ce('
Your research, ready for review

Your code.
Your identity,
protected.
Sign in to GitHub

Sign in to create and manage your anonymizations.

',1)),n("div",$b,[e.accountRecovery?(a(),l("section",Fb,[t[0]||(t[0]=n("h2",null,"Verify your existing account",-1)),t[1]||(t[1]=n("p",null,"We found an existing account. Verify it with your previous GitHub connection to keep your anonymizations. Future sign-ins will use the GitHub App.",-1)),e.site_options?.GITHUB_OAUTH_ENABLED?(a(),l("a",Ub,"Verify with previous GitHub connection")):(a(),l("p",Bb,"Account verification is currently unavailable. Please try again later."))])):f("v-if",!0),e.site_options?.GITHUB_APP_ENABLED&&!e.accountRecovery?(a(),l("section",zb,[...t[2]||(t[2]=[Ce('

Continue with GitHub

Connect through the GitHub App with read-only repository access.

  • You choose which repositories to share
  • No permission to write to your code
Sign in with GitHubYour existing anonymizations and connections stay with your account.',5)])])):f("v-if",!0),!e.site_options?.GITHUB_APP_ENABLED&&e.site_options?.GITHUB_OAUTH_ENABLED&&!e.accountRecovery?(a(),l("section",Hb,[...t[3]||(t[3]=[n("div",{class:"connection-title"},[n("h2",null,"Continue with GitHub")],-1),n("p",null,"Sign in to access your account. GitHub OAuth includes write access to private repositories.",-1),n("a",{class:"connection-link",target:"_self",href:"/github/login"},[g("Sign in with GitHub "),n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-arrow-right"})])],-1)])])):f("v-if",!0),e.site_options&&!e.site_options.GITHUB_APP_ENABLED&&!e.site_options.GITHUB_OAUTH_ENABLED?(a(),l("p",jb,"GitHub sign-in is currently unavailable. Please try again later.")):f("v-if",!0)])])]),Ie(s,{name:"partials/footer.htm",state:e.viewState},null,8,["state"])],64)}function xc(e,t){let s=Xe("partial-view");return a(),l(q,null,[t[0]||(t[0]=Ce('
Error \xB7 404

This link
isn\u2019t here.

The anonymous mirror you\u2019re looking for has expired, been removed by its owner, or never existed. If you received this URL from an author, ask them to re-issue it.

',1)),Ie(s,{name:"partials/footer.htm",state:e.viewState},null,8,["state"])],64)}var Gb={class:"container paper-page admin-page"},Wb={class:"seg-bar"},Kb={class:"seg-filter",role:"radiogroup","aria-label":"Filter by status"},Yb=["aria-checked"],Xb={class:"count"},Jb=["aria-checked"],Qb={class:"count"},Zb=["aria-checked"],xb={class:"count"},e1=["aria-checked"],t1={class:"count"},n1=["aria-checked"],s1={class:"count"},o1=["aria-checked"],i1={class:"count"},r1={class:"seg-countline",role:"status"},a1={key:0,class:"alert alert-danger",style:{margin:"8px 0"}},l1={class:"w-100 admin-filter-toolbar","aria-label":"Conferences","accept-charset":"UTF-8"},d1={class:"admin-filter-row"},u1={class:"search-wrap"},c1={type:"search",class:"form-control",placeholder:"Search conferences\u2026",autocomplete:"off"},p1={key:0,class:"admin-search-hint"},f1={key:1,class:"admin-filter-inline","aria-label":"Pagination"},m1=["disabled"],h1={style:{"font-family":"var(--font-mono)","font-size":"12px",color:"var(--ink-muted)"}},g1=["disabled"],v1={key:0,class:"admin-filter-row"},y1={class:"admin-active-chips"},b1={class:"key"},w1=["onClick"],k1={class:"paper-table paper-table-conferences w-100",role:"table","aria-label":"Conferences"},C1={key:0,class:"paper-table-head",role:"row"},E1={role:"columnheader"},S1={role:"columnheader"},N1={role:"columnheader"},R1={class:"paper-table-row",role:"row"},P1={class:"cell-anon",role:"cell"},D1={class:"anon-text"},A1=["textContent","href"],T1={class:"anon-sub"},O1={class:"cell-status",role:"cell"},I1=["textContent"],M1={class:"cell-views num",role:"cell"},V1=["textContent","href"],q1={class:"cell-expires",role:"cell"},_1={class:"cell-actions",role:"cell"},L1={class:"dropdown"},$1={class:"dropdown-menu dropdown-menu-right"},F1=["href"],U1=["href"],B1=["href"],z1=["onClick"],H1={key:1,class:"paper-table-empty"},j1={class:"admin-toolbar",style:{"justify-content":"space-between","border-bottom":"none"}},G1={key:0,class:"pagination-compact"},W1=["disabled"],K1=["max"],Y1=["disabled"],X1={class:"admin-filter-inline"},J1={class:"form-control form-control-sm"};function ep(e,t){let s=De("field"),i=De("form");return a(),l("div",Gb,[t[55]||(t[55]=Ce('
Admin \xA0/\xA0 Conferences

Conferences

',3)),n("div",Wb,[n("div",Kb,[n("button",{type:"button",role:"radio",class:P(["seg-chip",{active:e.segView()==="all"}]),"aria-checked":e.segView()==="all",onClick:t[0]||(t[0]=o=>e.setSegView("all"))},[t[14]||(t[14]=g("All ",-1)),n("span",Xb,c(e.fmt?.number(e.segCount("all"))),1)],10,Yb),n("button",{type:"button",role:"radio",class:P(["seg-chip",{active:e.segView()==="ready","is-empty":!e.segCount("ready")}]),"aria-checked":e.segView()==="ready",onClick:t[1]||(t[1]=o=>e.setSegView("ready"))},[t[15]||(t[15]=n("span",{class:"seg-dot ok","aria-hidden":"true"},null,-1)),t[16]||(t[16]=g("Ready ",-1)),n("span",Qb,c(e.fmt?.number(e.segCount("ready"))),1)],10,Jb),n("button",{type:"button",role:"radio",class:P(["seg-chip",{active:e.segView()==="preparing","is-empty":!e.segCount("preparing")}]),"aria-checked":e.segView()==="preparing",onClick:t[2]||(t[2]=o=>e.setSegView("preparing"))},[t[17]||(t[17]=n("span",{class:"seg-dot warn","aria-hidden":"true"},null,-1)),t[18]||(t[18]=g("Preparing ",-1)),n("span",xb,c(e.fmt?.number(e.segCount("preparing"))),1)],10,Zb),n("button",{type:"button",role:"radio",class:P(["seg-chip",{active:e.segView()==="error","is-empty":!e.segCount("error")}]),"aria-checked":e.segView()==="error",onClick:t[3]||(t[3]=o=>e.setSegView("error"))},[t[19]||(t[19]=n("span",{class:"seg-dot bad","aria-hidden":"true"},null,-1)),t[20]||(t[20]=g("Error ",-1)),n("span",t1,c(e.fmt?.number(e.segCount("error"))),1)],10,e1),n("button",{type:"button",role:"radio",class:P(["seg-chip",{active:e.segView()==="expired","is-empty":!e.segCount("expired")}]),"aria-checked":e.segView()==="expired",onClick:t[4]||(t[4]=o=>e.setSegView("expired"))},[t[21]||(t[21]=n("span",{class:"seg-dot off","aria-hidden":"true"},null,-1)),t[22]||(t[22]=g("Expired ",-1)),n("span",s1,c(e.fmt?.number(e.segCount("expired"))),1)],10,n1),n("button",{type:"button",role:"radio",class:P(["seg-chip",{active:e.segView()==="removed","is-empty":!e.segCount("removed")}]),"aria-checked":e.segView()==="removed",onClick:t[5]||(t[5]=o=>e.setSegView("removed"))},[t[23]||(t[23]=n("span",{class:"seg-dot off","aria-hidden":"true"},null,-1)),t[24]||(t[24]=g("Removed ",-1)),n("span",i1,c(e.fmt?.number(e.segCount("removed"))),1)],10,o1)]),n("p",r1,[n("strong",null,c(e.total>=0?e.fmt.number(e.total):"\u2026"),1),t[25]||(t[25]=g(" shown",-1))])]),e.fetchError?(a(),l("div",a1,[t[26]||(t[26]=n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-warning"})],-1)),g(" "+c(e.fetchError),1)])):f("v-if",!0),T((a(),l("form",l1,[n("div",d1,[n("div",u1,[T(n("input",c1,null,512),[[s,{state:e.viewState,set:o=>{e.query.search=o},value:e.query?.search,form:null,options:{}}]]),e.query?.search?f("v-if",!0):(a(),l("span",p1,"/"))]),t[30]||(t[30]=n("span",{class:"admin-filter-spacer"},null,-1)),e.total>0?(a(),l("button",{key:0,class:"btn btn-sm",type:"button",onClick:t[6]||(t[6]=o=>e.exportCsv())},[...t[27]||(t[27]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-export"})],-1),g(" Export",-1)])])):f("v-if",!0),e.totalPage>1?(a(),l("span",f1,[n("button",{class:"btn btn-sm btn-icon",type:"button",onClick:t[7]||(t[7]=o=>e.query.page=Math.max(1,e.query.page-1)),disabled:e.query?.page<=1,"aria-label":"Previous page"},[...t[28]||(t[28]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-chevron-left"})],-1)])],8,m1),n("span",h1,c(e.query?.page)+"/"+c(e.totalPage||1),1),n("button",{class:"btn btn-sm btn-icon",type:"button",onClick:t[8]||(t[8]=o=>e.query.page=Math.min(e.totalPage,e.query.page+1)),disabled:e.query?.page>=e.totalPage,"aria-label":"Next page"},[...t[29]||(t[29]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-chevron-right"})],-1)])],8,g1)])):f("v-if",!0)]),e.chips?.length?(a(),l("div",v1,[n("div",y1,[(a(!0),l(q,null,Q(e.chips,(o,r)=>(a(),l("span",{class:"admin-active-chip",key:o?.key},[n("span",b1,c(o?.label),1),n("span",null,c(o?.value),1),n("button",{type:"button",onClick:d=>e.clearFilter(o.key),"aria-label":"Clear filter"},[...t[31]||(t[31]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#project-icon-close"})],-1)])],8,w1)]))),128))])])):f("v-if",!0)])),[[i,e.viewState]]),n("div",k1,[e.total!==0?(a(),l("div",C1,[n("div",E1,[n("button",{type:"button",class:P(["sortable",{active:e.query?.sort=="name"}]),onClick:t[9]||(t[9]=o=>e.sortBy("name"))},[t[33]||(t[33]=g("Conference ",-1)),e.sortIcon("name")?(a(),l("svg",{key:0,class:P(["ui-icon sort-direction",{ascending:e.sortIcon("name")==="fa-arrow-up"}]),"aria-hidden":"true"},[...t[32]||(t[32]=[n("use",{href:"#project-icon-arrow"},null,-1)])],2)):f("v-if",!0)],2)]),n("div",S1,[n("button",{type:"button",class:P(["sortable",{active:e.query?.sort=="status"}]),onClick:t[10]||(t[10]=o=>e.sortBy("status"))},[t[35]||(t[35]=g("Status ",-1)),e.sortIcon("status")?(a(),l("svg",{key:0,class:P(["ui-icon sort-direction",{ascending:e.sortIcon("status")==="fa-arrow-up"}]),"aria-hidden":"true"},[...t[34]||(t[34]=[n("use",{href:"#project-icon-arrow"},null,-1)])],2)):f("v-if",!0)],2)]),t[38]||(t[38]=n("div",{role:"columnheader",class:"num"},"Repos",-1)),n("div",N1,[n("button",{type:"button",class:P(["sortable",{active:e.query?.sort=="startDate"}]),onClick:t[11]||(t[11]=o=>e.sortBy("startDate"))},[t[37]||(t[37]=g("Window ",-1)),e.sortIcon("startDate")?(a(),l("svg",{key:0,class:P(["ui-icon sort-direction",{ascending:e.sortIcon("startDate")==="fa-arrow-up"}]),"aria-hidden":"true"},[...t[36]||(t[36]=[n("use",{href:"#project-icon-arrow"},null,-1)])],2)):f("v-if",!0)],2)]),t[39]||(t[39]=n("div",{role:"columnheader","aria-label":"Actions"},null,-1))])):f("v-if",!0),(a(!0),l(q,null,Q(e.filteredConferences,(o,r)=>(a(),l("div",R1,[n("div",P1,[t[40]||(t[40]=n("svg",{class:"ui-icon record-type-icon",role:"img","aria-label":"Conference"},[n("use",{href:"#project-icon-conference"})],-1)),n("div",D1,[n("a",{class:"repo-name",textContent:c(o?.name),href:e.safeUrl("/conference/"+o?.conferenceID)},null,8,A1),n("div",T1,[n("span",null,c(o?.conferenceID),1),n("span",null,c(e.fmt?.money(o?.price||0)),1)])])]),n("div",O1,[n("span",{class:P(["status-dot","st-"+(o?.status||"unknown")])},null,2),n("span",{textContent:c(e.fmt?.statusLabel(o?.status))},null,8,I1)]),n("div",M1,[t[41]||(t[41]=n("svg",{class:"ui-icon mobile-meta-icon","aria-hidden":"true"},[n("use",{href:"#project-type-repo"})],-1)),n("a",{title:"Show repositories in this conference",textContent:c(e.fmt?.number(o?.repositories?.length||0)),href:e.safeUrl("/admin/?conference="+o?.conferenceID)},null,8,V1)]),n("div",q1,[t[42]||(t[42]=n("svg",{class:"ui-icon mobile-meta-icon","aria-hidden":"true"},[n("use",{href:"#project-icon-clock"})],-1)),g(" "+c(e.fmt?.date(o?.startDate))+" \u2013 "+c(e.fmt?.date(o?.endDate)),1)]),n("div",_1,[n("div",L1,[t[48]||(t[48]=n("button",{class:"btn btn-icon-dots",type:"button","data-toggle":"dropdown","aria-haspopup":"true","aria-expanded":"false","aria-label":"Actions"},[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#project-icon-more"})])],-1)),n("div",$1,[n("a",{class:"dropdown-item",href:e.safeUrl("/conference/"+o?.conferenceID+"/edit")},[...t[43]||(t[43]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-edit"})],-1),g(" Edit",-1)])],8,F1),n("a",{class:"dropdown-item",href:e.safeUrl("/conference/"+o?.conferenceID+"/")},[...t[44]||(t[44]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#project-icon-eye"})],-1),g(" View",-1)])],8,U1),n("a",{class:"dropdown-item",href:e.safeUrl("/admin/?conference="+o?.conferenceID)},[...t[45]||(t[45]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#project-type-repo"})],-1),g(" View repositories",-1)])],8,B1),t[47]||(t[47]=n("div",{class:"dropdown-divider"},null,-1)),T(n("a",{class:"dropdown-item text-danger",href:"#",onClick:ae(d=>e.removeConference(o),["prevent"])},[...t[46]||(t[46]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-trash"})],-1),g(" Remove",-1)])],8,z1),[[Z,o?.status!="removed"]])])])])]))),256)),e.filteredConferences?.length==0?(a(),l("div",H1,[t[49]||(t[49]=n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#project-icon-inbox"})],-1)),n("span",null,c(e.total?"No conferences match the current filters.":"No conferences yet."),1)])):f("v-if",!0)]),n("div",j1,[t[54]||(t[54]=n("span",{"aria-hidden":"true"},null,-1)),e.totalPage>1?(a(),l("div",G1,[n("button",{class:"btn btn-sm",onClick:t[12]||(t[12]=o=>e.query.page=Math.max(1,e.query.page-1)),disabled:e.query?.page<=1},[...t[50]||(t[50]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-chevron-left"})],-1),g(" Previous",-1)])],8,W1),T(n("input",{type:"number",class:"form-control form-control-sm",min:"1",style:{width:"56px"},max:e.totalPage},null,8,K1),[[s,{state:e.viewState,set:o=>{e.query.page=o},value:e.query?.page,form:null,options:{}}]]),n("span",null,"of "+c(e.totalPage),1),n("button",{class:"btn btn-sm",onClick:t[13]||(t[13]=o=>e.query.page=Math.min(e.totalPage,e.query.page+1)),disabled:e.query?.page>=e.totalPage},[...t[51]||(t[51]=[g("Next ",-1),n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-chevron-right"})],-1)])],8,Y1)])):f("v-if",!0),n("span",X1,[t[53]||(t[53]=n("label",null,"Per page",-1)),T((a(),l("select",J1,[...t[52]||(t[52]=[Ce('',5)])])),[[s,{state:e.viewState,set:o=>{e.query.limit=o},value:e.query?.limit,form:null,options:{}}]])])])])}var Q1={class:"container paper-page admin-page errors-page"},Z1={class:"errors-header"},x1={class:"errors-actions"},ew={class:"kpi-grid"},tw={class:"kpi-card"},nw={class:"kpi-value"},sw={key:0},ow={key:1},iw={key:2},rw=["aria-pressed"],aw={class:"kpi-value"},lw={class:"kpi-sub"},dw=["aria-pressed"],uw={class:"kpi-value"},cw={class:"kpi-sub"},pw=["aria-pressed"],fw={class:"kpi-value"},mw={class:"kpi-sub"},hw={class:"kpi-value"},gw={class:"kpi-sub"},vw={key:0,class:"dropped-warn"},yw={class:"volume-chart"},bw={class:"volume-head"},ww={class:"volume-legend"},kw={key:0},Cw={key:1},Ew={key:2},Sw={class:"volume-bars"},Nw=["title"],Rw={class:"errors-toolbar","aria-label":"Error filters"},Pw={class:"seg-filter",role:"radiogroup","aria-label":"Filter by severity"},Dw=["aria-checked"],Aw={class:"count"},Tw=["aria-checked"],Ow={class:"count"},Iw=["aria-checked"],Mw={class:"count"},Vw=["aria-checked"],qw={class:"count"},_w={class:"search-wrap"},Lw={type:"search",class:"form-control",placeholder:"Search errors\u2026",title:"Search messages, or filter with code:repo_not_found module:route status:>=400",autocomplete:"off"},$w={key:0,class:"filter-count"},Fw={class:"select-wrap"},Uw={class:"form-control form-control-sm"},Bw={class:"select-wrap"},zw={class:"form-control form-control-sm"},Hw={class:"autoref"},jw={type:"checkbox"},Gw={key:0,class:"admin-empty"},Ww={key:1,class:"errors-pager"},Kw={key:2,class:"errors-list"},Yw={key:0,class:"errors-group-head"},Xw={class:"errors-group-count"},Jw={key:0,class:"errors-group-note"},Qw=["onClick"],Zw={class:"col-when"},xw={class:"when-rel"},ek={class:"when-abs"},tk={class:"col-sev"},nk={class:"sev-label"},sk={class:"col-mod"},ok={class:"pill pill-module"},ik={class:"col-msg"},rk={class:"msg-code"},ak={key:0,class:"msg-context"},lk={key:1,class:"msg-detail"},dk=["title"],uk={class:"col-count"},ck={key:0,class:"count-pill"},pk={key:1,class:"count-pill count-pill-muted"},fk={class:"col-status"},mk=["title"],hk={key:1,class:"status-empty",title:"No HTTP status for this event"},gk={key:0,class:"errors-row-detail"},vk={class:"detail-tabs"},yk=["onClick"],bk=["onClick"],wk=["onClick"],kk={class:"detail-body"},Ck={class:"detail-main"},Ek={key:0},Sk={key:1,class:"stack-pre"},Nk={key:2,class:"related-list"},Rk={class:"when-abs"},Pk={class:"msg-url"},Dk={class:"detail-actions"},Ak=["onClick"],Tk=["onClick"],Ok={key:0,class:"copy-hint"},Ik={class:"detail-aside"},Mk={class:"aside-block"},Vk=["title"],qk={class:"aside-block"},_k=["title"],Lk={class:"aside-block"},$k={class:"aside-value"},Fk={key:0,class:"aside-sub"},Uk={key:0,class:"aside-block"},Bk=["href"],zk={key:1,class:"aside-block"},Hk={class:"aside-value mono"};function tp(e,t){let s=De("field"),i=De("form");return a(),l("div",Q1,[t[49]||(t[49]=n("div",{class:"paper-crumbs"},[g("Admin \xA0/\xA0 "),n("span",{class:"here"},"Errors")],-1)),n("header",Z1,[t[16]||(t[16]=n("h1",{class:"paper-page-title"},"Errors",-1)),n("div",x1,[n("button",{class:"btn btn-sm",type:"button",onClick:t[0]||(t[0]=o=>e.exportCsv())},[...t[14]||(t[14]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-export"})],-1),g(" Export CSV",-1)])]),n("button",{class:"btn btn-sm btn-outline-danger",type:"button",onClick:t[1]||(t[1]=o=>e.clearAll())},[...t[15]||(t[15]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-trash"})],-1),g(" Clear all",-1)])])])]),t[50]||(t[50]=Ce('',1)),n("section",ew,[n("div",tw,[t[17]||(t[17]=n("div",{class:"kpi-label"},"Occurrences \xB7 24h",-1)),n("div",nw,c(e.fmt?.number(e.stats?.last24h??0)),1),n("div",{class:P(["kpi-sub",{up:e.stats?.delta>0,down:e.stats?.delta<0}])},[e.stats?.prev24h>=20?(a(),l("span",sw,c((e.stats?.last24h??0)-(e.stats?.prev24h??0)>=0?"+":"")+c(Math.round(((e.stats?.last24h??0)-(e.stats?.prev24h??0))/e.stats.prev24h*100))+"% vs yesterday",1)):e.stats?.prev24h!==void 0?(a(),l("span",ow,c(e.fmt?.number(e.stats?.prev24h??0))+" in prior 24h",1)):f("v-if",!0),e.stats?.prev24h?f("v-if",!0):(a(),l("span",iw,"no prior baseline"))],2)]),n("div",{class:P(["kpi-card kpi-error kpi-filter",{"is-selected":e.query?.bucket==="error"}]),role:"button",tabindex:"0","aria-pressed":e.query?.bucket==="error",title:"Show only errors (5xx)",onClick:t[2]||(t[2]=o=>e.setBucket(e.query?.bucket==="error"?"":"error")),onKeydown:t[3]||(t[3]=kt(ae(o=>e.setBucket(e.query?.bucket==="error"?"":"error"),["prevent"]),["enter"]))},[t[18]||(t[18]=n("div",{class:"kpi-label"},"Error",-1)),n("div",aw,c(e.fmt?.number(e.stats?.severity?.error??0)),1),n("div",lw,"5xx \xB7 "+c(e.stats?.unique?.error)+" unique",1)],42,rw),n("div",{class:P(["kpi-card kpi-warn kpi-filter",{"is-selected":e.query?.bucket==="warn"}]),role:"button",tabindex:"0","aria-pressed":e.query?.bucket==="warn",title:"Show only warnings (4xx, aborted requests)",onClick:t[4]||(t[4]=o=>e.setBucket(e.query?.bucket==="warn"?"":"warn")),onKeydown:t[5]||(t[5]=kt(ae(o=>e.setBucket(e.query?.bucket==="warn"?"":"warn"),["prevent"]),["enter"]))},[t[19]||(t[19]=n("div",{class:"kpi-label"},"Warning",-1)),n("div",uw,c(e.fmt?.number(e.stats?.severity?.warn??0)),1),n("div",cw,"4xx, aborted \xB7 "+c(e.stats?.unique?.warn)+" unique",1)],42,dw),n("div",{class:P(["kpi-card kpi-info kpi-filter",{"is-selected":e.query?.bucket==="info"}]),role:"button",tabindex:"0","aria-pressed":e.query?.bucket==="info",title:"Show only info events",onClick:t[6]||(t[6]=o=>e.setBucket(e.query?.bucket==="info"?"":"info")),onKeydown:t[7]||(t[7]=kt(ae(o=>e.setBucket(e.query?.bucket==="info"?"":"info"),["prevent"]),["enter"]))},[t[20]||(t[20]=n("div",{class:"kpi-label"},"Info",-1)),n("div",fw,c(e.fmt?.number(e.stats?.severity?.info??0)),1),n("div",mw,"Auth, 404 \xB7 "+c(e.stats?.unique?.info)+" unique",1)],42,pw),n("div",{class:P(["kpi-card",{"kpi-error":e.stats?.dropped>0}])},[t[21]||(t[21]=n("div",{class:"kpi-label"},"Distinct errors stored",-1)),n("div",hw,c(e.fmt?.number(e.total)),1),n("div",gw,[g(" all time \xB7 cap "+c(e.fmt?.number(e.cap))+" \xB7 "+c(e.available?"live":"redis off")+" ",1),e.stats?.dropped>0?(a(),l("span",vw," \xB7 "+c(e.stats?.dropped)+" dropped",1)):f("v-if",!0)])],2)]),n("section",yw,[n("div",bw,[t[25]||(t[25]=n("span",{class:"volume-title"},"Volume \xB7 24h \xB7 1h buckets",-1)),n("span",ww,[e.stats?.severity?.error?(a(),l("span",kw,[...t[22]||(t[22]=[n("span",{class:"dot dot-error"},null,-1),g("Error",-1)])])):f("v-if",!0),e.stats?.severity?.warn?(a(),l("span",Cw,[...t[23]||(t[23]=[n("span",{class:"dot dot-warn"},null,-1),g("Warning",-1)])])):f("v-if",!0),e.stats?.severity?.info?(a(),l("span",Ew,[...t[24]||(t[24]=[n("span",{class:"dot dot-info"},null,-1),g("Info",-1)])])):f("v-if",!0)])]),n("div",Sw,[(a(!0),l(q,null,Q(e.stats?.buckets,(o,r)=>(a(),l("div",{class:"volume-bar",key:r,title:e.bucketTitle(o)},[n("span",{class:"seg seg-error",style:Te({height:e.barPx(o,"error")+"px"})},null,4),n("span",{class:"seg seg-warn",style:Te({height:e.barPx(o,"warn")+"px"})},null,4),n("span",{class:"seg seg-info",style:Te({height:e.barPx(o,"info")+"px"})},null,4)],8,Nw))),128))]),t[26]||(t[26]=n("div",{class:"volume-axis","aria-hidden":"true"},[n("span",null,"24h ago"),n("span",null,"12h ago"),n("span",null,"now")],-1))]),T((a(),l("form",Rw,[n("div",Pw,[n("button",{type:"button",role:"radio",class:P(["seg-chip",{active:(e.query?.bucket||"")===""}]),"aria-checked":(e.query?.bucket||"")==="",onClick:t[8]||(t[8]=o=>e.setBucket(""))},[t[27]||(t[27]=g("All ",-1)),n("span",Aw,c(e.fmt?.number((e.stats?.severity?.error??0)+(e.stats?.severity?.warn??0)+(e.stats?.severity?.info??0))),1)],10,Dw),n("button",{type:"button",role:"radio",class:P(["seg-chip",{active:(e.query?.bucket||"")==="error","is-empty":!e.stats?.severity?.error}]),"aria-checked":(e.query?.bucket||"")==="error",onClick:t[9]||(t[9]=o=>e.setBucket("error"))},[t[28]||(t[28]=n("span",{class:"seg-dot bad","aria-hidden":"true"},null,-1)),t[29]||(t[29]=g("Error ",-1)),n("span",Ow,c(e.fmt?.number(e.stats?.severity?.error??0)),1)],10,Tw),n("button",{type:"button",role:"radio",class:P(["seg-chip",{active:(e.query?.bucket||"")==="warn","is-empty":!e.stats?.severity?.warn}]),"aria-checked":(e.query?.bucket||"")==="warn",onClick:t[10]||(t[10]=o=>e.setBucket("warn"))},[t[30]||(t[30]=n("span",{class:"seg-dot warn","aria-hidden":"true"},null,-1)),t[31]||(t[31]=g("Warning ",-1)),n("span",Mw,c(e.fmt?.number(e.stats?.severity?.warn??0)),1)],10,Iw),n("button",{type:"button",role:"radio",class:P(["seg-chip",{active:(e.query?.bucket||"")==="info","is-empty":!e.stats?.severity?.info}]),"aria-checked":(e.query?.bucket||"")==="info",onClick:t[11]||(t[11]=o=>e.setBucket("info"))},[t[32]||(t[32]=n("span",{class:"seg-dot off","aria-hidden":"true"},null,-1)),t[33]||(t[33]=g("Info ",-1)),n("span",qw,c(e.fmt?.number(e.stats?.severity?.info??0)),1)],10,Vw)]),n("div",_w,[t[34]||(t[34]=n("svg",{class:"ui-icon search-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-search"})],-1)),T(n("input",Lw,null,512),[[s,{state:e.viewState,set:o=>{e.query.search=o},value:e.query?.search,form:null,options:{}}]]),e.parsedFilterCount?(a(),l("span",$w,c(e.parsedFilterCount)+" filter"+c(e.parsedFilterCount>1?"s":""),1)):f("v-if",!0)]),n("div",Fw,[t[36]||(t[36]=n("label",null,"Sort",-1)),T((a(),l("select",Uw,[...t[35]||(t[35]=[n("option",{value:"recent"},"Most recent",-1),n("option",{value:"count"},"Most frequent",-1)])])),[[s,{state:e.viewState,set:o=>{e.query.sort=o},value:e.query?.sort,form:null,options:{}}]])]),n("div",Bw,[t[38]||(t[38]=n("label",{title:"Rows are always sectioned by severity. This merges repeated events inside each section."},"Merge",-1)),T((a(),l("select",zw,[...t[37]||(t[37]=[n("option",{value:""},"Don't merge",-1),n("option",{value:"code"},"Same error",-1),n("option",{value:"module"},"Same module",-1)])])),[[s,{state:e.viewState,set:o=>{e.query.group=o},value:e.query?.group,form:null,options:{}}]])]),n("label",Hw,[T(n("input",jw,null,512),[[s,{state:e.viewState,set:o=>{e.query.autoRefresh=o},value:e.query?.autoRefresh,form:null,options:{}}]]),t[39]||(t[39]=n("span",{class:"auto-refresh-label"},"Auto-refresh",-1))]),n("button",{class:"btn btn-sm btn-icon",type:"button",title:"Refresh now",onClick:t[12]||(t[12]=o=>e.refreshNow()),"aria-label":"Refresh"},[...t[40]||(t[40]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-refresh"})],-1)])])])),[[i,e.viewState]]),e.visible?.length?f("v-if",!0):(a(),l("div",Gw,"No errors captured.")),e.canLoadMore()&&e.visible?.length?(a(),l("div",Ww,[n("span",null,c(e.query?.group&&e.visible?.length!==e.entries?.length?e.fmt?.number(e.visible?.length)+(e.visible?.length===1?" group":" groups")+" from ":"")+c(e.fmt?.number(e.entries?.length))+" of "+c(e.fmt?.number(e.total))+" stored errors loaded",1),n("button",{class:"btn btn-sm",type:"button",onClick:t[13]||(t[13]=o=>e.loadMore())},"Load 250 older")])):f("v-if",!0),e.visible?.length?(a(),l("div",Kw,[t[48]||(t[48]=Ce('
WhenSeverityModuleMessageTotalStatus
',1)),(a(!0),l(q,null,Q(e.visible,(o,r)=>(a(),l(q,{key:o?._key},[r===0||e.visible[r-1]?._bucket!==o?._bucket?(a(),l("div",Yw,[n("span",{class:P(["sev-dot","sev-"+o?._bucket])},null,2),g(c(o?._bucket==="error"?"Error":o?._bucket==="warn"?"Warning":"Info"),1),n("span",Xw,c(e.fmt?.number(e.visible.filter(d=>d?._bucket===o?._bucket).length)),1),r===0?(a(),l("span",Jw,"By severity \xB7 "+c(e.query?.group==="code"?"repeats merged by error \xB7 ":e.query?.group==="module"?"repeats merged by module \xB7 ":"")+c(e.query?.sort==="count"?"most frequent first":"most recent first"),1)):f("v-if",!0)])):f("v-if",!0),n("div",{class:P(["errors-row",{open:e.expanded[o?._key]}])},[n("div",{class:"errors-row-main",onClick:d=>e.toggle(o)},[n("div",Zw,[n("div",xw,c(e.relTime(o?.ts)),1),n("div",ek,c(e.absTimeShort(o?.ts)),1)]),n("div",tk,[n("span",{class:P(["sev-dot","sev-"+o?._bucket])},null,2),n("span",nk,c(o?._bucket==="error"?"Error":o?._bucket==="warn"?"Warning":"Info"),1)]),n("div",sk,[n("span",ok,c(o?.module),1)]),n("div",ik,[n("strong",rk,c(o?.displayMessage),1),o?.displayContext&&o?.displayContext!==o?.displayMessage?(a(),l("span",ak,c(o?.displayContext),1)):f("v-if",!0),o?._detail?(a(),l("span",lk,c(o?._detail),1)):f("v-if",!0),o?._url?(a(),l("div",{key:2,class:"msg-url",title:o?._url},c(o?._url),9,dk)):f("v-if",!0)]),n("div",uk,[o?.count>1?(a(),l("span",ck,"\xD7"+c(o?.count),1)):f("v-if",!0),o?.count===1?(a(),l("span",pk,"\xD71")):f("v-if",!0)]),n("div",fk,[o?._status?(a(),l("span",{key:0,class:P(["status-pill",String(o?._status).match(/^[23]/)?"status-neutral":"status-"+o?._bucket]),title:String(o?._status).match(/^2/)&&o?._bucket==="warn"?"Client closed the connection":null},c(String(o?._status).match(/^2/)&&o?._bucket==="warn"?"\u2014":o?._status),11,mk)):f("v-if",!0),o?._status?f("v-if",!0):(a(),l("span",hk,"\u2014"))])],8,Qw),e.expanded[o?._key]?(a(),l("div",gk,[n("div",vk,[n("button",{type:"button",class:P({active:e.detailTab[o?._key]==="raw"||!e.detailTab[o?._key]}),onClick:d=>e.detailTab[o._key]="raw"},"Raw",10,yk),o?._stack?(a(),l("button",{key:0,type:"button",class:P({active:e.detailTab[o?._key]==="stack"}),onClick:d=>e.detailTab[o._key]="stack"},"Stack",10,bk)):f("v-if",!0),o?.count>1?(a(),l("button",{key:1,type:"button",class:P({active:e.detailTab[o?._key]==="related"}),onClick:d=>e.detailTab[o._key]="related"},"Related ("+c(o?.count)+")",11,wk)):f("v-if",!0)]),n("div",kk,[n("div",Ck,[(e.detailTab[o?._key]||"raw")==="raw"?(a(),l("pre",Ek,c(o?._detailJson),1)):f("v-if",!0),e.detailTab[o?._key]==="stack"?(a(),l("pre",Sk,c(o?._stack),1)):f("v-if",!0),e.detailTab[o?._key]==="related"?(a(),l("div",Nk,[(a(!0),l(q,null,Q(o?._related,(d,p)=>(a(),l("div",{class:"related-row",key:p},[n("span",Rk,c(e.absTimeShort(d?.ts)),1),n("span",Pk,c(d?._url),1),d?._status?(a(),l("span",{key:0,class:P(["status-pill","status-"+d?._bucket])},c(d?._status),3)):f("v-if",!0)]))),128))])):f("v-if",!0),n("div",Dk,[n("button",{class:"btn btn-sm",type:"button",title:"Copy a curl that reproduces the request",onClick:d=>e.copyCurl(o)},[...t[41]||(t[41]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-code"})],-1),g(" Copy curl",-1)])],8,Ak),n("button",{class:"btn btn-sm",type:"button",onClick:d=>e.copyJson(o)},[...t[42]||(t[42]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-clipboard"})],-1),g(" Copy JSON",-1)])],8,Tk),e.copyHint?(a(),l("span",Ok,c(e.copyHint),1)):f("v-if",!0)])]),n("aside",Ik,[n("div",Mk,[t[43]||(t[43]=n("div",{class:"aside-label"},"First seen",-1)),n("div",{class:"aside-value",title:e.absTime(o?._firstSeen)},c(e.relTime(o?._firstSeen)),9,Vk)]),n("div",qk,[t[44]||(t[44]=n("div",{class:"aside-label"},"Last seen",-1)),n("div",{class:"aside-value",title:e.absTime(o?.ts)},c(e.relTime(o?.ts)),9,_k)]),n("div",Lk,[t[45]||(t[45]=n("div",{class:"aside-label"},"Occurrences",-1)),n("div",$k,[g(c(o?.count),1),o?._lastHourCount?(a(),l("span",Fk," \xB7 "+c(o?._lastHourCount)+" this hour",1)):f("v-if",!0)])]),o?._repoId?(a(),l("div",Uk,[t[46]||(t[46]=n("div",{class:"aside-label"},"Repository",-1)),n("a",{class:"aside-value",href:e.safeUrl("/r/"+o?._repoId)},c(o?._repoId),9,Bk)])):f("v-if",!0),o?._url?(a(),l("div",zk,[t[47]||(t[47]=n("div",{class:"aside-label"},"URL",-1)),n("div",Hk,c(o?._url),1)])):f("v-if",!0)])])])):f("v-if",!0)],2)],64))),128))])):f("v-if",!0)])}var jk={class:"container paper-page admin-page overview-page"},Gk={key:0,class:"admin-empty"},Wk={key:1,class:"alert alert-danger",style:{margin:"12px 0"}},Kk={class:"ov-views",role:"tablist","aria-label":"Overview sections"},Yk=["aria-selected","onClick"],Xk={key:2},Jk={key:0,class:"ov-health",role:"status"},Qk={class:"ov-kpi-row"},Zk={class:"ov-kpi-card"},xk={class:"ov-kpi-value"},e0={class:"ov-kpi-sub"},t0={class:"ov-kpi-card"},n0={class:"ov-kpi-sub"},s0={class:"ov-kpi-card"},o0={class:"ov-kpi-sub"},i0={class:"ov-kpi-card"},r0={class:"ov-kpi-sub"},a0={class:"ov-kpi-card"},l0={class:"ov-kpi-value"},d0={class:"ov-kpi-sub"},u0={class:"ov-daily-row"},c0={class:"ov-daily-card"},p0={class:"ov-daily-value"},f0={class:"ov-daily-card"},m0={class:"ov-daily-value"},h0={class:"ov-daily-sub"},g0={class:"ov-daily-card"},v0={class:"ov-daily-value"},y0={class:"ov-chart-card"},b0={class:"ov-chart-head"},w0={class:"ov-chart-legends"},k0={class:"ov-chart-legend"},C0={key:0,class:"ov-legend-missing"},E0={key:0,class:"ov-spark-bars ov-has-axis"},S0={class:"ov-yaxis","aria-hidden":"true"},N0=["data-tip","aria-label"],R0={key:1,class:"ov-spark-x"},P0={class:"ov-chart-card"},D0={class:"ov-chart-head"},A0={class:"ov-chart-legends"},T0={class:"ov-chart-legend"},O0={key:0,class:"ov-legend-missing"},I0={key:0,class:"ov-spark-bars ov-has-axis"},M0={class:"ov-yaxis","aria-hidden":"true"},V0=["data-tip","aria-label"],q0={key:1,class:"ov-spark-x"},_0={key:0,class:"ov-chart-card"},L0={class:"ov-chart-head"},$0={class:"ov-chart-legends"},F0={class:"ov-chart-legend"},U0={key:0,class:"ov-legend-missing"},B0={key:0,class:"ov-spark-bars ov-spark-step ov-has-axis"},z0={class:"ov-yaxis","aria-hidden":"true"},H0=["viewBox","aria-label"],j0=["d"],G0=["d"],W0={key:1,class:"ov-spark-x"},K0={class:"ov-chart-card"},Y0={class:"ov-chart-head"},X0={class:"ov-chart-legends"},J0={class:"ov-chart-legend"},Q0={key:0,class:"ov-legend-missing"},Z0={key:0,class:"ov-spark-bars ov-has-axis"},x0={class:"ov-yaxis","aria-hidden":"true"},e2=["data-tip","aria-label"],t2={key:1,class:"ov-spark-x"},n2={class:"ov-triple-row"},s2={class:"ov-panel-card"},o2={class:"ov-panel-head"},i2={class:"ov-panel-meta"},r2={class:"ov-stacked-bar"},a2={class:"ov-bar-legend"},l2={href:"/admin/repositories",class:"ov-legend-item"},d2={class:"ov-legend-n"},u2={href:"/admin/repositories",class:"ov-legend-item"},c2={class:"ov-legend-n"},p2={href:"/admin/repositories",class:"ov-legend-item"},f2={class:"ov-legend-n"},m2={href:"/admin/repositories",class:"ov-legend-item"},h2={class:"ov-legend-n"},g2={href:"/admin/repositories",class:"ov-legend-item"},v2={class:"ov-legend-n"},y2={class:"ov-panel-card"},b2={class:"ov-panel-head"},w2={class:"ov-panel-meta"},k2={class:"ov-error-bars"},C2={class:"ov-ebar-row"},E2={class:"ov-ebar-track"},S2={class:"ov-ebar-n"},N2={class:"ov-ebar-row"},R2={class:"ov-ebar-track"},P2={class:"ov-ebar-n"},D2={key:0,class:"ov-ehours",role:"img","aria-label":"Errors per hour over the last 24 hours"},A2={class:"ov-ehours-legend"},T2={class:"ov-ehours-note"},O2={class:"ov-ehours-bars"},I2=["title"],M2={key:0,class:"ov-ehours-zero"},V2={class:"ov-ebar-note"},q2={key:0,class:"ov-panel-foot"},_2={href:"/admin/errors"},L2={class:"ov-panel-card"},$2={class:"ov-routes-table"},F2={class:"ov-route-row",href:"/admin/queues"},U2={class:"ov-route-n"},B2={class:"ov-route-n"},z2={class:"ov-route-row",href:"/admin/queues"},H2={class:"ov-route-n"},j2={class:"ov-route-n"},G2={class:"ov-route-row",href:"/admin/queues"},W2={class:"ov-route-n"},K2={class:"ov-route-n"},Y2={class:"ov-services-card"},X2={class:"ov-services-head"},J2={class:"ov-panel-meta"},Q2={class:"ov-services-grid"},Z2={class:"ov-svc"},x2={class:"ov-svc-info"},eC={class:"ov-svc-meta"},tC={class:"ov-svc"},nC={class:"ov-svc-info"},sC={key:0,class:"ov-svc-meta"},oC={key:1,class:"ov-svc-meta"},iC={class:"ov-svc"},rC={class:"ov-svc-info"},aC={key:0,class:"ov-svc-meta"},lC={key:1,class:"ov-svc-meta"},dC={class:"ov-svc"},uC={class:"ov-svc-info"},cC={key:0,class:"ov-svc-meta"},pC={key:1,class:"ov-svc-meta"},fC={class:"ov-svc"},mC=["title"],hC={class:"ov-svc-info"},gC={class:"ov-svc-meta"},vC={class:"ov-panel-card ov-cache","aria-labelledby":"cache-heading"},yC={class:"ov-panel-head ov-performance-head"},bC={class:"ov-performance-window"},wC={key:0,class:"ov-performance-message ov-performance-warning",role:"alert"},kC={key:1,class:"ov-performance-empty",role:"status"},CC={key:0,class:"ov-performance-note"},EC={key:1,class:"ov-performance-note"},SC={key:2,class:"ov-performance-message ov-performance-warning",role:"status"},NC={key:3,class:"ov-metrics-scroll",tabindex:"0",role:"region","aria-label":"Cache storage budgets"},RC={class:"ov-metrics-table"},PC={scope:"row",class:"ov-event-name"},DC=["title"],AC={key:0,class:"ov-metric-bad-text"},TC={key:1,class:"budget-bar","aria-hidden":"true"},OC={class:"num"},IC={class:"num"},MC={class:"num"},VC={class:"num"},qC={key:4,class:"ov-cache-rates"},_C={key:5,class:"ov-metrics-scroll",tabindex:"0",role:"region","aria-label":"Cache events and processing durations"},LC={class:"ov-metrics-table"},$C={scope:"row",class:"ov-event-name"},FC={class:"ov-event-traffic"},UC={class:"num"},BC={class:"num"},zC={key:6,class:"ov-performance-empty",role:"status"},HC={class:"ov-performance-note"},jC={class:"ov-panel-card ov-performance","aria-labelledby":"performance-heading"},GC={class:"ov-panel-head ov-performance-head"},WC={class:"ov-performance-window"},KC={key:0,class:"ov-performance-message ov-performance-warning",role:"alert"},YC={key:1,class:"ov-performance-empty",role:"status"},XC={key:2},JC={id:"performance-routes",role:"region","aria-label":"Routes"},QC={key:0,class:"ov-metrics-scroll",tabindex:"0",role:"region","aria-label":"Route latency metrics, scroll for more columns"},ZC={class:"ov-metrics-table"},xC={scope:"row",class:"ov-metric-name"},eE={class:"num"},tE={class:"num"},nE={class:"num"},sE={class:"num"},oE={class:"num"},iE={key:1,class:"ov-performance-empty"},rE={id:"performance-processes",role:"region","aria-label":"Processes"},aE={key:0,class:"ov-performance-message ov-performance-warning",role:"status"},lE={key:1,class:"ov-metrics-scroll",tabindex:"0",role:"region","aria-label":"Process resource metrics, scroll for more columns"},dE={class:"ov-metrics-table"},uE={scope:"row",class:"ov-metric-name"},cE={key:0,class:"ov-metric-warn"},pE={class:"num"},fE={class:"num"},mE={class:"num"},hE={class:"num"},gE={class:"num"},vE={class:"num"},yE={class:"num"},bE={class:"num"},wE={id:"performance-stages",role:"region","aria-label":"Work stages"},kE={key:0,class:"ov-metrics-scroll",tabindex:"0",role:"region","aria-label":"Work stage metrics, scroll for more columns"},CE={class:"ov-metrics-table"},EE={scope:"row",class:"ov-metric-name"},SE={class:"num"},NE={class:"num"},RE={class:"num"},PE={key:1,class:"ov-performance-empty"};function np(e,t){return a(),l("div",jk,[t[95]||(t[95]=Ce('
Admin \xA0/\xA0 Overview

Overview

Live \xB7 refreshes every 30s
',2)),e.loading?(a(),l("div",Gk,"Loading overview\u2026")):f("v-if",!0),e.error?(a(),l("div",Wk,[t[8]||(t[8]=n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-warning"})],-1)),g(" "+c(e.error),1)])):f("v-if",!0),n("div",Kk,[(a(),l(q,null,Q([{id:"summary",label:"Summary"},{id:"performance",label:"Performance"},{id:"cache",label:"Cache"}],s=>n("button",{type:"button",role:"tab",key:s.id,"aria-selected":e.ovView===s.id?"true":"false",class:P({active:e.ovView===s.id}),onClick:i=>e.setOvView(s.id)},c(s.label),11,Yk)),64))]),e.data?T((a(),l("div",Xk,[e.data?.system?.memPercent>90||e.data?.system?.diskPercent>90?(a(),l("div",Jk,[t[10]||(t[10]=n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-warning"})],-1)),n("span",null,[t[9]||(t[9]=n("b",null,"Server needs attention.",-1)),g(" "+c(e.healthAlert()),1)])])):f("v-if",!0),f(" \u2500\u2500 Top KPI row \u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500 "),n("section",Qk,[n("div",Zk,[t[11]||(t[11]=n("div",{class:"ov-kpi-label"},"Live repositories",-1)),n("div",xk,c(e.humanNum((e.data?.repos?.statusBreakdown||[]).filter(s=>s._id!=="removed"&&s._id!=="expired").reduce((s,i)=>s+(i.count||0),0))),1),n("div",e0,c(e.humanNum(((e.data?.repos?.statusBreakdown||[]).find(s=>s._id==="removed")||{}).count||0))+" removed \xB7 "+c(e.humanNum(e.data?.repos?.total))+" total",1)]),n("div",t0,[t[12]||(t[12]=n("div",{class:"ov-kpi-label"},"CPU",-1)),n("div",{class:P(["ov-kpi-value",{"ov-val-warn":e.data?.system?.cpuPercent>=75}])},c(e.data?.system?.cpuPercent)+"%",3),n("div",{class:P(["ov-meter",{warn:e.data?.system?.cpuPercent>=75,crit:e.data?.system?.cpuPercent>90}])},[n("span",{style:Te({width:Math.min(100,e.data?.system?.cpuPercent||0)+"%"})},null,4)],2),n("div",n0,[e.data?.system?.cpuPercent>=75?(a(),l("b",{key:0,class:P(["ov-flag",{critical:e.data?.system?.cpuPercent>90}])},c(e.data?.system?.cpuPercent>90?"Critical":"High")+" \xB7 ",3)):f("v-if",!0),g(c(e.data?.system?.cpuCount)+" cores \xB7 load "+c(e.data?.system?.loadAvg?.[0]?.toFixed(1)),1)])]),n("div",s0,[t[13]||(t[13]=n("div",{class:"ov-kpi-label"},"Memory",-1)),n("div",{class:P(["ov-kpi-value",{"ov-val-warn":e.data?.system?.memPercent>=75}])},c(e.data?.system?.memPercent)+"%",3),n("div",{class:P(["ov-meter",{warn:e.data?.system?.memPercent>=75,crit:e.data?.system?.memPercent>90}])},[n("span",{style:Te({width:Math.min(100,e.data?.system?.memPercent||0)+"%"})},null,4)],2),n("div",o0,[e.data?.system?.memPercent>=75?(a(),l("b",{key:0,class:P(["ov-flag",{critical:e.data?.system?.memPercent>90}])},c(e.data?.system?.memPercent>90?"Critical":"High")+" \xB7 ",3)):f("v-if",!0),g(c(e.humanBytes(e.data?.system?.memUsed).replace(/\s*GB$/,""))+" / "+c(e.humanBytes(e.data?.system?.memTotal)),1)])]),n("div",i0,[t[14]||(t[14]=n("div",{class:"ov-kpi-label"},"Disk",-1)),n("div",{class:P(["ov-kpi-value",{"ov-val-warn":e.data?.system?.diskPercent>=75}])},c(e.data?.system?.diskPercent)+"%",3),n("div",{class:P(["ov-meter",{warn:e.data?.system?.diskPercent>=75,crit:e.data?.system?.diskPercent>90}])},[n("span",{style:Te({width:Math.min(100,e.data?.system?.diskPercent||0)+"%"})},null,4)],2),n("div",r0,[e.data?.system?.diskPercent>=75?(a(),l("b",{key:0,class:P(["ov-flag",{critical:e.data?.system?.diskPercent>90}])},c(e.data?.system?.diskPercent>90?"Critical":"High")+" \xB7 ",3)):f("v-if",!0),g(c(e.humanBytes(e.data?.system?.diskUsed).replace(/\s*GB$/,""))+" / "+c(e.humanBytes(e.data?.system?.diskTotal)),1),e.data?.system?.diskMount&&e.data.system.diskMount!=="/"?(a(),l(q,{key:1},[g(" \xB7 "+c(e.data?.system?.diskMount),1)],64)):f("v-if",!0)])]),n("div",a0,[t[15]||(t[15]=n("div",{class:"ov-kpi-label"},"Uptime",-1)),n("div",l0,c(e.humanDuration(e.data?.system?.uptime)),1),n("div",d0,c(e.data?.system?.nodeVersion)+" \xB7 "+c(e.data?.system?.platform),1)])]),f(" \u2500\u2500 Daily activity highlights \u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500 "),n("section",u0,[n("div",c0,[t[16]||(t[16]=n("div",{class:"ov-daily-label"},"New repos today",-1)),n("div",p0,c(e.fmt?.number(e.data?.daily?.today?.repositories||0)),1),t[17]||(t[17]=n("div",{class:"ov-daily-sub"},"so far today",-1))]),n("div",f0,[t[18]||(t[18]=n("div",{class:"ov-daily-label"},"New users today",-1)),n("div",m0,c(e.fmt?.number(e.data?.daily?.today?.users||0)),1),n("div",h0,c(e.fmt?.number(e.data?.users?.total))+" total \xB7 +"+c(e.fmt?.number(e.usersGained()))+" in 30 days",1)]),n("div",g0,[t[19]||(t[19]=n("div",{class:"ov-daily-label"},"Page views today",-1)),n("div",v0,c(e.fmt?.number(e.data?.daily?.today?.pageViews||0)),1),t[20]||(t[20]=n("div",{class:"ov-daily-sub"},"so far today",-1))])]),f(" \u2500\u2500 Daily charts \u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500 "),n("section",{class:P(["ov-chart-row",{"is-three":e.usersTiny()}])},[n("div",y0,[n("div",b0,[t[23]||(t[23]=n("span",{class:"ov-chart-title"},"Daily page views \xB7 30d",-1)),n("span",w0,[n("span",k0,[t[21]||(t[21]=n("span",{class:"ov-dot-legend ov-dot-accent"},null,-1)),g("views/day \xB7 peak "+c(e.fmt?.number(e.historyMax("dailyPageViews"))),1)]),e.historyHasMissing()?(a(),l("span",C0,[...t[22]||(t[22]=[n("span",{class:"ov-swatch-missing","aria-hidden":"true"},null,-1),g("No data",-1)])])):f("v-if",!0)])]),e.data?.history?.length?(a(),l("div",E0,[n("div",S0,[n("span",null,c(e.fmt?.number(e.axisMax("dailyPageViews"))),1),n("span",null,c(e.fmt?.number(e.axisMax("dailyPageViews")/2)),1),t[24]||(t[24]=n("span",null,"0",-1))]),(a(!0),l(q,null,Q(e.data?.history,(s,i)=>(a(),l("div",{class:P(["ov-spark-col has-tip",{"is-missing":s?._empty}]),key:i,"data-tip":s?._empty?e.historyLabel(s)+": no data":e.historyLabel(s)+": +"+e.fmt?.number(s?.dailyPageViews)+(s?.dailyPageViews===1?" view":" views"),"aria-label":s?._empty?e.historyLabel(s)+": no data":e.historyLabel(s)+": +"+e.fmt?.number(s?.dailyPageViews)+(s?.dailyPageViews===1?" view":" views")},[n("span",{class:"ov-spark-fill",style:Te({height:e.historyBarH(s,"dailyPageViews")+"px"})},null,4)],10,N0))),128))])):f("v-if",!0),e.data?.history?.length?(a(),l("div",R0,[n("span",null,c(e.historyLabel(e.data?.history[0])),1),n("span",null,c(e.historyLabel(e.data?.history[Math?.floor(e.data?.history?.length/2)])),1),n("span",null,c(e.historyLabel(e.data?.history[e.data?.history?.length-1])),1)])):f("v-if",!0)]),n("div",P0,[n("div",D0,[t[27]||(t[27]=n("span",{class:"ov-chart-title"},"New repos \xB7 30d",-1)),n("span",A0,[n("span",T0,[t[25]||(t[25]=n("span",{class:"ov-dot-legend ov-dot-ok-fill"},null,-1)),g("repos/day \xB7 peak "+c(e.fmt?.number(e.historyMax("dailyRepositories"))),1)]),e.historyHasMissing()?(a(),l("span",O0,[...t[26]||(t[26]=[n("span",{class:"ov-swatch-missing","aria-hidden":"true"},null,-1),g("No data",-1)])])):f("v-if",!0)])]),e.data?.history?.length?(a(),l("div",I0,[n("div",M0,[n("span",null,c(e.fmt?.number(e.axisMax("dailyRepositories"))),1),n("span",null,c(e.fmt?.number(e.axisMax("dailyRepositories")/2)),1),t[28]||(t[28]=n("span",null,"0",-1))]),(a(!0),l(q,null,Q(e.data?.history,(s,i)=>(a(),l("div",{class:P(["ov-spark-col has-tip",{"is-missing":s?._empty}]),key:i,"data-tip":s?._empty?e.historyLabel(s)+": no data":e.historyLabel(s)+": +"+e.fmt?.number(s?.dailyRepositories)+(s?.dailyRepositories===1?" repo":" repos"),"aria-label":s?._empty?e.historyLabel(s)+": no data":e.historyLabel(s)+": +"+e.fmt?.number(s?.dailyRepositories)+(s?.dailyRepositories===1?" repo":" repos")},[n("span",{class:"ov-spark-fill ov-spark-fill-alt",style:Te({height:e.historyBarH(s,"dailyRepositories")+"px"})},null,4)],10,V0))),128))])):f("v-if",!0),e.data?.history?.length?(a(),l("div",q0,[n("span",null,c(e.historyLabel(e.data?.history[0])),1),n("span",null,c(e.historyLabel(e.data?.history[Math?.floor(e.data?.history?.length/2)])),1),n("span",null,c(e.historyLabel(e.data?.history[e.data?.history?.length-1])),1)])):f("v-if",!0)]),e.usersTiny()?f("v-if",!0):(a(),l("div",_0,[n("div",L0,[t[31]||(t[31]=n("span",{class:"ov-chart-title"},"Users \xB7 30d",-1)),n("span",$0,[n("span",F0,[t[29]||(t[29]=n("span",{class:"ov-dot-legend ov-dot-user-fill"},null,-1)),g("total users \xB7 "+c(e.fmt?.number(e.historyRange("nbUsers").max))+" now \xB7 +"+c(e.fmt?.number(Math.max(0,e.historyRange("nbUsers").max-e.usersFirst())))+" in 30 days",1)]),e.historyHasMissing()?(a(),l("span",U0,[...t[30]||(t[30]=[n("span",{class:"ov-swatch-missing","aria-hidden":"true"},null,-1),g("No data",-1)])])):f("v-if",!0)])]),e.data?.history?.length?(a(),l("div",B0,[n("div",z0,[n("span",null,c(e.fmt?.number(e.userAxis().hi)),1),n("span",null,c(e.fmt?.number((e.userAxis().hi+e.userAxis().lo)/2)),1),n("span",null,c(e.fmt?.number(e.userAxis().lo)),1)]),(a(),l("svg",{class:"ov-step-svg",viewBox:"0 0 "+e.data.history.length+" 140",preserveAspectRatio:"none",role:"img","aria-label":"Total users over 30 days, from "+e.fmt?.number(e.usersFirst())+" to "+e.fmt?.number(e.historyRange("nbUsers").max)},[e.userAxis().lo===0?(a(),l("path",{key:0,class:"ov-step-area",d:e.userStepPath(!0)},null,8,j0)):f("v-if",!0),n("path",{class:"ov-step-line",d:e.userStepPath(!1),"vector-effect":"non-scaling-stroke"},null,8,G0)],8,H0)),e.firstDataIndex()>0?(a(),l("div",{key:0,class:"ov-step-missing",style:Te({width:e.firstDataIndex()/e.data.history.length*100+"%"})},null,4)):f("v-if",!0)])):f("v-if",!0),e.data?.history?.length?(a(),l("div",W0,[n("span",null,c(e.historyLabel(e.data?.history[0])),1),n("span",null,c(e.historyLabel(e.data?.history[Math?.floor(e.data?.history?.length/2)])),1),n("span",null,c(e.historyLabel(e.data?.history[e.data?.history?.length-1])),1)])):f("v-if",!0)])),n("div",K0,[n("div",Y0,[t[34]||(t[34]=n("span",{class:"ov-chart-title"},"New users \xB7 30d",-1)),n("span",X0,[n("span",J0,[t[32]||(t[32]=n("span",{class:"ov-dot-legend ov-dot-new-user-fill"},null,-1)),g("users/day \xB7 peak "+c(e.fmt?.number(e.historyMax("dailyUsers"))),1)]),e.historyHasMissing()?(a(),l("span",Q0,[...t[33]||(t[33]=[n("span",{class:"ov-swatch-missing","aria-hidden":"true"},null,-1),g("No data",-1)])])):f("v-if",!0)])]),e.data?.history?.length?(a(),l("div",Z0,[n("div",x0,[n("span",null,c(e.fmt?.number(e.axisMax("dailyUsers"))),1),n("span",null,c(e.fmt?.number(e.axisMax("dailyUsers")/2)),1),t[35]||(t[35]=n("span",null,"0",-1))]),(a(!0),l(q,null,Q(e.data?.history,(s,i)=>(a(),l("div",{class:P(["ov-spark-col has-tip",{"is-missing":s?._empty}]),key:i,"data-tip":s?._empty?e.historyLabel(s)+": no data":e.historyLabel(s)+": +"+e.fmt?.number(s?.dailyUsers)+(s?.dailyUsers===1?" user":" users"),"aria-label":s?._empty?e.historyLabel(s)+": no data":e.historyLabel(s)+": +"+e.fmt?.number(s?.dailyUsers)+(s?.dailyUsers===1?" user":" users")},[n("span",{class:"ov-spark-fill ov-spark-fill-new-user",style:Te({height:e.historyBarH(s,"dailyUsers")+"px"})},null,4)],10,e2))),128))])):f("v-if",!0),e.data?.history?.length?(a(),l("div",t2,[n("span",null,c(e.historyLabel(e.data?.history[0])),1),n("span",null,c(e.historyLabel(e.data?.history[Math?.floor(e.data?.history?.length/2)])),1),n("span",null,c(e.historyLabel(e.data?.history[e.data?.history?.length-1])),1)])):f("v-if",!0)])],2),f(" \u2500\u2500 Three-panel row: Status / Errors / Queues \u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500 "),n("section",n2,[f(" Repo status breakdown "),n("div",s2,[n("div",o2,[t[36]||(t[36]=n("span",{class:"ov-panel-title"},"Repo status",-1)),n("span",i2,c(e.fmt?.number(e.data?.repos?.total))+" total",1)]),n("div",r2,[e.barPct("ready")>0?(a(),l("span",{key:0,class:"ov-bar-seg ov-bar-ready",title:"Ready",style:Te({width:e.barPct("ready")+"%"})},null,4)):f("v-if",!0),e.barPct("preparing")>0?(a(),l("span",{key:1,class:"ov-bar-seg ov-bar-preparing",title:"Preparing",style:Te({width:e.barPct("preparing")+"%"})},null,4)):f("v-if",!0),e.barPct("error")>0?(a(),l("span",{key:2,class:"ov-bar-seg ov-bar-error",title:"Error",style:Te({width:e.barPct("error")+"%"})},null,4)):f("v-if",!0),e.barPct("expired")>0?(a(),l("span",{key:3,class:"ov-bar-seg ov-bar-expired",title:"Expiring / expired",style:Te({width:e.barPct("expired")+"%"})},null,4)):f("v-if",!0),e.barPct("removed")>0?(a(),l("span",{key:4,class:"ov-bar-seg ov-bar-removed",title:"Removing / removed",style:Te({width:e.barPct("removed")+"%"})},null,4)):f("v-if",!0)]),n("div",a2,[n("a",l2,[t[37]||(t[37]=n("span",{class:"ov-swatch ov-bar-ready"},null,-1)),t[38]||(t[38]=g(" Ready ",-1)),n("span",d2,c(e.fmt?.number(e.statusCount("ready"))),1)]),n("a",u2,[t[39]||(t[39]=n("span",{class:"ov-swatch ov-bar-preparing"},null,-1)),t[40]||(t[40]=g(" Preparing ",-1)),n("span",c2,c(e.fmt?.number(e.statusCount("preparing")+e.statusCount("download"))),1)]),n("a",p2,[t[41]||(t[41]=n("span",{class:"ov-swatch ov-bar-error"},null,-1)),t[42]||(t[42]=g(" Error ",-1)),n("span",f2,c(e.fmt?.number(e.statusCount("error"))),1)]),n("a",m2,[t[43]||(t[43]=n("span",{class:"ov-swatch ov-bar-expired"},null,-1)),t[44]||(t[44]=g(" Expiring / expired ",-1)),n("span",h2,c(e.fmt?.number(e.statusCount("expired")+e.statusCount("expiring"))),1)]),n("a",g2,[t[45]||(t[45]=n("span",{class:"ov-swatch ov-bar-removed"},null,-1)),t[46]||(t[46]=g(" Removing / removed ",-1)),n("span",v2,c(e.fmt?.number(e.statusCount("removed")+e.statusCount("removing"))),1)])])]),f(" Error breakdown "),n("div",y2,[n("div",b2,[t[47]||(t[47]=n("span",{class:"ov-panel-title"},"Errors \xB7 24h",-1)),n("span",w2,c(e.fmt?.number(e.realErrors()))+" "+c(e.realErrors()===1?"error":"errors"),1)]),n("div",k2,[n("div",C2,[t[48]||(t[48]=n("span",{class:"ov-ebar-label"},"Error",-1)),n("span",E2,[n("span",{class:"ov-ebar-fill ov-ebar-error",style:Te({width:e.errPct("error")+"%"})},null,4)]),n("span",S2,c(e.data?.errors?.severity?.error),1)]),n("div",N2,[t[49]||(t[49]=n("span",{class:"ov-ebar-label"},"Warning",-1)),n("span",R2,[n("span",{class:"ov-ebar-fill ov-ebar-warn",style:Te({width:e.errPct("warn")+"%"})},null,4)]),n("span",P2,c(e.data?.errors?.severity?.warn),1)]),e.errorHours().length?(a(),l("div",D2,[n("div",A2,[t[52]||(t[52]=n("span",{class:"ov-ehours-key"},[n("span",{class:"ov-ehours-swatch is-error","aria-hidden":"true"}),g("Error")],-1)),t[53]||(t[53]=n("span",{class:"ov-ehours-key"},[n("span",{class:"ov-ehours-swatch is-warn","aria-hidden":"true"}),g("Warning")],-1)),n("span",T2,[t[50]||(t[50]=g("Per hour",-1)),t[51]||(t[51]=n("span",{class:"seg-sep","aria-hidden":"true"},"\xB7",-1)),g("peak "+c(e.fmt?.number(e.errorHoursPeak())),1)])]),n("div",O2,[(a(!0),l(q,null,Q(e.errorHours(),s=>(a(),l("span",{key:s.key,class:P({"is-bad":s.bad,"is-zero":s.zero}),title:s.title},[s.zero?(a(),l("i",M2)):(a(),l(q,{key:1},[s.errPct?(a(),l("i",{key:0,class:"ov-ehours-e",style:Te({height:s.errPct+"%"})},null,4)):f("v-if",!0),s.warnPct?(a(),l("i",{key:1,class:"ov-ehours-w",style:Te({height:s.warnPct+"%"})},null,4)):f("v-if",!0)],64))],10,I2))),128))]),t[54]||(t[54]=n("div",{class:"ov-ehours-x"},[n("span",null,"24h ago"),n("span",null,"now")],-1))])):f("v-if",!0),n("p",V2,"Info "+c(e.fmt?.number(e.data?.errors?.severity?.info||0))+" \xB7 logged, not counted as errors",1)]),e.data?.repos?.recentErrors24h?(a(),l("div",q2,[n("a",_2,c(e.data?.repos?.recentErrors24h)+" repos in error state \u2192",1)])):f("v-if",!0)]),f(" Top routes / queues "),n("div",L2,[t[59]||(t[59]=n("div",{class:"ov-panel-head"},[n("span",{class:"ov-panel-title"},"Queues"),n("span",{class:"ov-panel-meta"},"by state")],-1)),n("div",$2,[t[58]||(t[58]=Ce('
QueueActiveWaitFailed
',1)),n("a",F2,[t[55]||(t[55]=n("span",{class:"ov-route-name"},"Download",-1)),n("span",U2,c(e.data?.queues?.download?.active),1),n("span",B2,c(e.data?.queues?.download?.waiting),1),n("span",{class:P(["ov-route-n ov-route-lat",{"ov-n-bad":e.data?.queues?.download?.failed>0}])},c(e.data?.queues?.download?.failed),3)]),n("a",z2,[t[56]||(t[56]=n("span",{class:"ov-route-name"},"Remove",-1)),n("span",H2,c(e.data?.queues?.remove?.active),1),n("span",j2,c(e.data?.queues?.remove?.waiting),1),n("span",{class:P(["ov-route-n ov-route-lat",{"ov-n-bad":e.data?.queues?.remove?.failed>0}])},c(e.data?.queues?.remove?.failed),3)]),n("a",G2,[t[57]||(t[57]=n("span",{class:"ov-route-name"},"Cache cleanup",-1)),n("span",W2,c(e.data?.queues?.cache?.active),1),n("span",K2,c(e.data?.queues?.cache?.waiting),1),n("span",{class:P(["ov-route-n ov-route-lat",{"ov-n-bad":e.data?.queues?.cache?.failed>0}])},c(e.data?.queues?.cache?.failed),3)])])])]),f(" \u2500\u2500 Services bar \u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500 "),n("section",Y2,[n("div",X2,[t[60]||(t[60]=n("span",{class:"ov-panel-title"},"Services",-1)),n("span",J2,"5 services \xB7 "+c(e.realErrors()>0?"1 needs attention":"all healthy"),1)]),n("div",Q2,[n("div",Z2,[t[62]||(t[62]=n("span",{class:"ov-svc-dot ov-dot-ok"},null,-1)),n("div",x2,[t[61]||(t[61]=n("span",{class:"ov-svc-name"},"web",-1)),n("span",eC,c(e.data?.system?.nodeVersion)+" \xB7 up "+c(e.humanDuration(e.data?.system?.uptime)),1)])]),n("div",tC,[n("span",{class:P(["ov-svc-dot",e.queueTotal(e.data?.queues?.download)>0?"ov-dot-ok":"ov-dot-idle"])},null,2),n("div",nC,[t[63]||(t[63]=n("span",{class:"ov-svc-name"},"download",-1)),e.queueTotal(e.data?.queues?.download)?(a(),l("span",sC,c(e.queueTotal(e.data?.queues?.download))+" "+c(e.queueTotal(e.data?.queues?.download)===1?"job":"jobs"),1)):f("v-if",!0),e.queueTotal(e.data?.queues?.download)?f("v-if",!0):(a(),l("span",oC,"idle"))])]),n("div",iC,[n("span",{class:P(["ov-svc-dot",e.queueTotal(e.data?.queues?.cache)>0?"ov-dot-ok":"ov-dot-idle"])},null,2),n("div",rC,[t[64]||(t[64]=n("span",{class:"ov-svc-name"},"cache",-1)),e.queueTotal(e.data?.queues?.cache)?(a(),l("span",aC,c(e.queueTotal(e.data?.queues?.cache))+" "+c(e.queueTotal(e.data?.queues?.cache)===1?"job":"jobs"),1)):f("v-if",!0),e.queueTotal(e.data?.queues?.cache)?f("v-if",!0):(a(),l("span",lC,"idle"))])]),n("div",dC,[n("span",{class:P(["ov-svc-dot",e.queueTotal(e.data?.queues?.remove)>0?"ov-dot-ok":"ov-dot-idle"])},null,2),n("div",uC,[t[65]||(t[65]=n("span",{class:"ov-svc-name"},"remove",-1)),e.queueTotal(e.data?.queues?.remove)?(a(),l("span",cC,c(e.queueTotal(e.data?.queues?.remove))+" "+c(e.queueTotal(e.data?.queues?.remove)===1?"job":"jobs"),1)):f("v-if",!0),e.queueTotal(e.data?.queues?.remove)?f("v-if",!0):(a(),l("span",pC,"idle"))])]),n("div",fC,[n("span",{class:P(["ov-svc-dot",e.realErrors()>0?"ov-dot-warn":"ov-dot-ok"]),title:e.realErrors()>0?"Errors in the last 24 hours":"No errors in the last 24 hours"},null,10,mC),n("div",hC,[t[66]||(t[66]=n("span",{class:"ov-svc-name"},"errors",-1)),n("span",gC,c(e.fmt?.number(e.realErrors()))+" / 24h",1)])])])])],512)),[[Z,e.ovView==="summary"]]):f("v-if",!0),T(n("section",vC,[n("div",yC,[t[71]||(t[71]=n("div",null,[n("h2",{class:"ov-panel-title",id:"cache-heading"},"Cache"),n("p",{class:"ov-performance-note"},"Shared storage, repeated reads and anonymization work")],-1)),n("div",bC,[t[69]||(t[69]=n("label",{for:"cache-window"},"Time range",-1)),T(n("select",{id:"cache-window",class:"form-control form-control-sm","onUpdate:modelValue":t[0]||(t[0]=s=>e.cacheMinutes=s),onChange:t[1]||(t[1]=s=>e.loadCache())},[...t[67]||(t[67]=[n("option",{value:15},"Last 15 minutes",-1),n("option",{value:60},"Last hour",-1),n("option",{value:1440},"Last 24 hours",-1),n("option",{value:10080},"Last 7 days",-1)])],544),[[Wt,e.cacheMinutes,void 0,{number:!0}]]),t[70]||(t[70]=n("label",{for:"cache-traffic"},"Traffic",-1)),T(n("select",{id:"cache-traffic",class:"form-control form-control-sm","onUpdate:modelValue":t[2]||(t[2]=s=>e.cacheTraffic=s)},[...t[68]||(t[68]=[Ce('',6)])],512),[[Wt,e.cacheTraffic]])])]),e.cacheError?(a(),l("div",wC,[n("span",null,c(e.cacheError),1),n("button",{type:"button",class:"btn btn-sm",onClick:t[3]||(t[3]=s=>e.loadCache())},"Retry")])):f("v-if",!0),!e.cacheReport&&!e.cacheError?(a(),l("p",kC,"Loading cache monitoring\u2026")):f("v-if",!0),e.cacheReport?.available?(a(),l(q,{key:2},[e.cacheReport.enabled?f("v-if",!0):(a(),l("p",CC,"Shared blob storage is disabled. Inspection and legacy-cache activity are still measured.")),e.cacheReport.filesystemSupported?f("v-if",!0):(a(),l("p",EC,"Shared blobs require a local filesystem. The configured storage continues to use its existing cache.")),e.cacheReport.dropped?(a(),l("p",SC,c(e.cacheReport.dropped)+" telemetry events were dropped. Totals may be incomplete.",1)):f("v-if",!0),e.cacheReport.source?(a(),l("div",NC,[n("table",RC,[t[72]||(t[72]=n("caption",{class:"sr-only"},"Current shared-cache storage and byte budgets",-1)),t[73]||(t[73]=n("thead",null,[n("tr",null,[n("th",{scope:"col"},"Pool"),n("th",{scope:"col",class:"num"},"Allocated / budget"),n("th",{scope:"col",class:"num"},"Reserved for fills"),n("th",{scope:"col",class:"num"},"Original bytes"),n("th",{scope:"col",class:"num"},"Blobs"),n("th",{scope:"col",class:"num"},"Active readers")])],-1)),n("tbody",null,[(a(!0),l(q,null,Q([{name:"Source blobs",data:e.cacheReport.source},{name:"Transformed output",data:e.cacheReport.results}],s=>T((a(),l("tr",{key:s.name},[n("th",PC,c(s.name),1),n("td",{class:P(["num budget-cell",{"is-over":s.data?.budgetBytes&&s.data?.allocatedBytes>s.data?.budgetBytes}]),title:s.data?.budgetBytes?Math.round(100*(s.data?.allocatedBytes||0)/s.data.budgetBytes)+"% of budget":null},[s.data?.budgetBytes&&s.data?.allocatedBytes>s.data?.budgetBytes?(a(),l("span",AC,"Over budget \xB7 ")):f("v-if",!0),g(c(e.humanBytes(s.data?.allocatedBytes))+" / "+c(e.humanBytes(s.data?.budgetBytes)),1),s.data?.budgetBytes?(a(),l("span",TC,[n("i",{style:Te({width:Math.min(100,Math.round(100*(s.data?.allocatedBytes||0)/s.data.budgetBytes))+"%"})},null,4)])):f("v-if",!0)],10,DC),n("td",OC,c(e.humanBytes(s.data?.reservedBytes)),1),n("td",IC,c(e.humanBytes(s.data?.originalBytes)),1),n("td",MC,c(e.fmt?.number(s.data?.blobs)),1),n("td",VC,c(e.fmt?.number(s.data?.activeReaders)),1)])),[[Z,s.data]])),128))])])])):f("v-if",!0),e.cacheReport.source?(a(),l("dl",qC,[n("div",null,[t[74]||(t[74]=n("dt",null,"Source request hit rate",-1)),n("dd",null,c(e.cacheRate("source","count")),1)]),n("div",null,[t[75]||(t[75]=n("dt",null,"Source byte hit rate",-1)),n("dd",null,c(e.cacheRate("source","bytes")),1)]),n("div",null,[t[76]||(t[76]=n("dt",null,"Decision hit rate",-1)),n("dd",null,c(e.cacheRate("decision","count")),1)])])):f("v-if",!0),t[79]||(t[79]=n("p",{class:"ov-performance-note"},"Reuse counts measure consecutive reads of the same blob within each interval. Codec timings are elapsed stream time, not CPU time; eviction times measure how long a blob was idle. Known monitors are identified by request metadata; other automation may remain in file reads.",-1)),e.cacheRows().length?(a(),l("div",_C,[n("table",LC,[t[77]||(t[77]=n("caption",{class:"sr-only"},"Cache events for the selected time range and traffic",-1)),t[78]||(t[78]=n("thead",null,[n("tr",null,[n("th",{scope:"col"},"Event"),n("th",{scope:"col"},"Traffic"),n("th",{scope:"col",class:"num"},"Count"),n("th",{scope:"col",class:"num"},"Bytes"),n("th",{scope:"col",class:"num"},"Mean measured time"),n("th",{scope:"col",class:"num"},"p95 bound")])],-1)),n("tbody",null,[(a(!0),l(q,null,Q(e.cacheRows(),s=>(a(),l("tr",{key:s.name+":"+s.traffic},[n("th",$C,c(e.cacheEventName(s.name)),1),n("td",FC,c(s.traffic),1),n("td",UC,c(e.fmt?.number(s.count)),1),n("td",BC,c(e.humanBytes(s.bytes)),1),n("td",{class:P(["num",{"ov-muted":!s.ms}])},c(s.ms?e.fmt.duration(s.ms/s.count):"Not timed"),3),n("td",{class:P(["num",{"ov-muted":!s.ms}])},c(e.cacheP95(s)),3)]))),128))])])])):(a(),l("p",zC,"No cache events in this time range for the selected traffic.")),n("p",HC,"Updated "+c(e.sampleAge(e.cacheReport))+" seconds ago. Minute history is retained for 48 hours; hourly history for 30 days.",1)],64)):f("v-if",!0)],512),[[Z,e.ovView==="cache"]]),T(n("section",jC,[n("div",GC,[t[84]||(t[84]=n("div",null,[n("h2",{class:"ov-panel-title",id:"performance-heading"},"Request performance"),n("p",{class:"ov-performance-note"},"Request latency and process health")],-1)),n("div",WC,[e.performance?.available?(a(),l(q,{key:0},[t[81]||(t[81]=n("label",{for:"performance-view"},"Show",-1)),T(n("select",{id:"performance-view",class:"form-control form-control-sm","onUpdate:modelValue":t[4]||(t[4]=s=>e.performanceTab=s),"aria-label":"Performance metrics"},[...t[80]||(t[80]=[n("option",{value:"routes"},"Routes",-1),n("option",{value:"processes"},"Processes",-1),n("option",{value:"stages"},"Work stages",-1)])],512),[[Wt,e.performanceTab]])],64)):f("v-if",!0),t[83]||(t[83]=n("label",{for:"performance-window"},"Time range",-1)),T(n("select",{id:"performance-window",class:"form-control form-control-sm","onUpdate:modelValue":t[5]||(t[5]=s=>e.performanceMinutes=s),onChange:t[6]||(t[6]=s=>e.loadPerformance()),"aria-label":"Performance time range"},[...t[82]||(t[82]=[n("option",{value:15},"Last 15 minutes",-1),n("option",{value:60},"Last hour",-1)])],544),[[Wt,e.performanceMinutes,void 0,{number:!0}]])])]),e.performanceError?(a(),l("div",KC,[t[85]||(t[85]=n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-warning"})],-1)),n("span",null,c(e.performanceError),1),n("button",{type:"button",class:"btn btn-sm",onClick:t[7]||(t[7]=s=>e.loadPerformance())},"Retry")])):f("v-if",!0),!e.performance&&!e.performanceError?(a(),l("p",YC,"Loading performance monitoring\u2026")):f("v-if",!0),e.performance?.available?(a(),l("div",XC,[T(n("div",JC,[e.performance.routes?.length?(a(),l("div",QC,[n("table",ZC,[t[86]||(t[86]=n("caption",{class:"sr-only"},"Route latency for the selected time range",-1)),t[87]||(t[87]=n("thead",null,[n("tr",null,[n("th",{scope:"col"},"Route"),n("th",{scope:"col",class:"num"},"Requests"),n("th",{scope:"col",class:"num"},"Average"),n("th",{scope:"col",class:"num"},"First byte p95"),n("th",{scope:"col",class:"num"},"p95"),n("th",{scope:"col",class:"num"},"p99"),n("th",{scope:"col",class:"num"},"Interrupted"),n("th",{scope:"col",class:"num"},"5xx"),n("th",{scope:"col",class:"num"},"Slow")])],-1)),n("tbody",null,[(a(!0),l(q,null,Q(e.performance.routes,s=>(a(),l("tr",{key:s.service+s.method+s.route},[n("th",xC,[n("span",null,c(s.route),1),n("small",null,c(s.service)+" \xB7 "+c(s.method),1)]),n("td",eE,c(e.fmt.number(s.count)),1),n("td",tE,c(e.formatMs(s.avgMs)),1),n("td",nE,c(e.firstByteBound(s)),1),n("td",sE,c(e.latencyBound(s,"p95UpperMs")),1),n("td",oE,c(e.latencyBound(s,"p99UpperMs")),1),n("td",{class:P(["num",{"ov-metric-warn":s.aborted>0}])},c(e.fmt.number(s.aborted)),3),n("td",{class:P(["num",{"ov-metric-bad":s.errors>0}])},c(e.fmt.number(s.errors)),3),n("td",{class:P(["num",{"ov-metric-warn":s.slow>0}])},c(e.fmt.number(s.slow)),3)]))),128))])])])):(a(),l("p",iE,"No recorded requests in this time range yet."))],512),[[Z,e.performanceTab==="routes"]]),T(n("div",rE,[t[91]||(t[91]=n("p",{class:"ov-performance-note"},"API and streamer processes \xB7 latest sample per instance",-1)),e.performance.instances?.length?(a(),l("div",lE,[n("table",dE,[t[89]||(t[89]=n("caption",{class:"sr-only"},"API and streamer process resource usage",-1)),t[90]||(t[90]=n("thead",null,[n("tr",null,[n("th",{scope:"col"},"Process"),n("th",{scope:"col",class:"num"},"RSS / limit"),n("th",{scope:"col",class:"num"},"CPU"),n("th",{scope:"col",class:"num"},"Event loop p95"),n("th",{scope:"col",class:"num"},"Active requests"),n("th",{scope:"col",class:"num"},"Sockets / CLOSE_WAIT"),n("th",{scope:"col",class:"num"},"Workers / waiting"),n("th",{scope:"col",class:"num"},"Sample age"),n("th",{scope:"col",class:"num"},"Dropped batches / metrics")])],-1)),n("tbody",null,[(a(!0),l(q,null,Q(e.performance.instances,s=>(a(),l("tr",{key:s.instance,class:P({"ov-metric-warning-row":e.performanceWarning(s)})},[n("th",uE,[n("span",null,c(s.instance),1),e.performanceWarning(s)?(a(),l("small",cE,[...t[88]||(t[88]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-warning"})],-1),g(" Needs attention",-1)])])):f("v-if",!0)]),n("td",pE,[g(c(e.humanBytes(s.memory.rss))+" / "+c(e.humanBytes(s.memoryLimitBytes)),1),n("small",null,"Peak "+c(e.humanBytes(e.peakRss(s))),1)]),n("td",fE,c(s.cpuPercent==null?"Unavailable":s.cpuPercent.toFixed(1)+"%"),1),n("td",mE,c(s.eventLoop?.p95Ms==null?"Not applicable":e.fmt.duration(s.eventLoop.p95Ms)),1),n("td",hE,c(s.activeRequests),1),n("td",gE,c(s.sockets?.descriptors??"Unavailable")+" / "+c(s.sockets?.closeWait??"Unavailable"),1),n("td",vE,c(s.workers?.running??0)+" / "+c(s.workers?.waiting??0),1),n("td",yE,c(e.sampleAge(s))+" s",1),n("td",bE,c(s.droppedBatches)+" / "+c(s.droppedMetrics),1)],2))),128))])])])):(a(),l("div",aE,"No recent process samples. Monitoring coverage is incomplete."))],512),[[Z,e.performanceTab==="processes"]]),T(n("div",wE,[e.performance.stages?.some(s=>s.metric!=="first_byte")?(a(),l("div",kE,[n("table",CE,[t[92]||(t[92]=n("caption",{class:"sr-only"},"Work stages and cache results",-1)),t[93]||(t[93]=n("thead",null,[n("tr",null,[n("th",{scope:"col"},"Work stage"),n("th",{scope:"col",class:"num"},"Samples"),n("th",{scope:"col",class:"num"},"Average"),n("th",{scope:"col",class:"num"},"p95")])],-1)),n("tbody",null,[(a(!0),l(q,null,Q(e.performance.stages.filter(s=>s.metric!=="first_byte"),s=>(a(),l("tr",{key:s.service+s.metric},[n("th",EE,[n("span",null,c(s.metric),1),n("small",null,c(s.service),1)]),n("td",SE,c(e.fmt.number(s.count)),1),n("td",NE,c(e.formatMs(s.avgMs)),1),n("td",RE,c(e.latencyBound(s,"p95UpperMs")),1)]))),128))])])])):(a(),l("p",PE,"No recorded work stages or cache results in this time range yet."))],512),[[Z,e.performanceTab==="stages"]]),t[94]||(t[94]=n("details",{class:"ov-performance-help"},[n("summary",null,"How to read these metrics"),n("p",null,"Latency includes upstream waits and response transfer. Percentiles show histogram bucket upper bounds, not exact timings. Process rows marked \u201CNeeds attention\u201D have stale samples, dropped monitoring data, CLOSE_WAIT sockets, high event loop delay, or high memory usage.")],-1))])):f("v-if",!0)],512),[[Z,e.ovView==="performance"]])])}var DE={class:"container paper-page admin-page"},AE={class:"q-header"},TE={class:"q-header-actions"},OE={class:"q-cards"},IE=["aria-pressed","onKeydown","onClick"],ME={class:"q-card-head"},VE=["title"],qE=["textContent"],_E=["textContent"],LE={class:"q-card-sub"},$E={class:"q-card-failed"},FE={key:0,class:"q-card-bar"},UE={key:0,class:"q-detail"},BE={class:"q-throughput"},zE={class:"q-range-btns"},HE={class:"q-section-label"},jE={key:0,class:"q-section-right"},GE={class:"q-chart-wrap"},WE={key:0,class:"q-chart-empty"},KE={class:"q-stats-panel"},YE={class:"q-section-label"},XE={class:"q-stats-grid"},JE={class:"q-stat"},QE=["textContent"],ZE={class:"q-stat"},xE=["textContent"],eS={class:"q-stat"},tS=["textContent"],nS={class:"q-stat"},sS=["textContent"],oS={class:"q-stat"},iS=["textContent"],rS={class:"q-stat"},aS=["textContent"],lS={class:"q-stats-actions"},dS=["disabled"],uS={class:"q-danger-group"},cS={class:"q-jobs"},pS={class:"q-jobs-header"},fS={class:"q-section-label"},mS={class:"seg-filter",role:"radiogroup","aria-label":"Filter jobs by state"},hS=["aria-checked"],gS={class:"count"},vS=["aria-checked"],yS={class:"count"},bS=["aria-checked"],wS={class:"count"},kS=["aria-checked"],CS={class:"count"},ES=["aria-checked"],SS={class:"count"},NS=["aria-checked"],RS={class:"count"},PS={class:"q-search-row"},DS={type:"search",class:"form-control",placeholder:"Search by job/repo id\u2026",autocomplete:"off"},AS={class:"q-auto-refresh"},TS={type:"checkbox"},OS={key:0,class:"q-table"},IS=["onClick"],MS={class:"q-cell-state"},VS=["textContent"],qS=["textContent"],_S=["title"],LS=["textContent","href"],$S=["title","textContent"],FS=["textContent"],US=["textContent"],BS={class:"q-cell-progress"},zS=["aria-label"],HS=["textContent"],jS={class:"q-cell-actions"},GS=["onClick"],WS=["onClick"],KS={key:0,class:"q-detail-row"},YS={colspan:"7"},XS={class:"q-job-detail"},JS={class:"q-job-detail-grid"},QS={class:"q-job-detail-item"},ZS={class:"q-job-detail-value"},xS=["textContent","href"],eN={class:"q-job-detail-item"},tN={class:"q-job-detail-value"},nN=["textContent"],sN={key:0,class:"q-job-detail-item"},oN=["textContent"],iN={key:1,class:"q-job-detail-item"},rN=["textContent"],aN={key:2,class:"q-job-detail-item"},lN={class:"q-job-detail-value"},dN={key:3,class:"q-job-detail-item"},uN=["textContent"],cN={key:4,class:"q-job-detail-item"},pN=["textContent"],fN={key:5,class:"q-job-detail-item"},mN=["textContent"],hN={key:6,class:"q-job-detail-item"},gN=["textContent"],vN={key:7,class:"q-job-detail-item"},yN=["textContent"],bN={key:0,class:"q-job-detail-error"},wN=["textContent"],kN={key:1},CN=["textContent"],EN={class:"q-job-detail-actions"},SN=["onClick"],NN=["onClick"],RN=["href"],PN={key:1,class:"paper-table-empty",style:{border:"1px solid var(--border-color)","border-radius":"10px",background:"var(--paper-card)"}},DN={key:0},AN={key:1};function sp(e,t){let s=De("field");return a(),l("div",DE,[t[71]||(t[71]=n("div",{class:"paper-crumbs"},[g("Admin \xA0/\xA0 "),n("span",{class:"here"},"Queues")],-1)),n("div",AE,[t[18]||(t[18]=n("h1",{class:"paper-page-title"},"Queues",-1)),n("div",TE,[n("button",{class:"btn btn-sm",onClick:t[0]||(t[0]=i=>e.pauseAll())},"Pause all queues")])]),t[72]||(t[72]=Ce('',1)),f(" Queue overview cards "),n("div",OE,[(a(!0),l(q,null,Q(e.queueList,(i,o)=>(a(),l("div",{class:P(["q-card",{selected:e.selectedQueue==i?.key,paused:i?.paused}]),role:"button",tabindex:"0","aria-pressed":e.selectedQueue===i.key,onKeydown:[kt(ae(r=>e.selectQueue(i.key),["prevent"]),["enter"]),kt(ae(r=>e.selectQueue(i.key),["prevent"]),["space"])],onClick:r=>e.selectQueue(i.key)},[n("div",ME,[n("span",{class:P(["q-dot",{"q-dot-red":i?.paused||i?.counts?.failed>0,"q-dot-idle":!i?.counts?.active&&!i?.counts?.waiting}]),title:i?.paused?"Paused":i?.counts?.failed>0?i.counts.failed+" failed jobs":i?.counts?.active||i?.counts?.waiting?"Running":"Idle"},null,10,VE),n("span",{class:"q-card-name",textContent:c(i?.label)},null,8,qE)]),n("div",{class:"q-card-count",textContent:c((i?.counts?.waiting||0)+(i?.counts?.active||0)+(i?.counts?.delayed||0))},null,8,_E),n("div",LE,[n("span",null,[g("waiting \xB7 "+c(i?.counts?.active||0)+" active",1),i?.counts?.failed?(a(),l(q,{key:0},[t[19]||(t[19]=g(" \xB7 ",-1)),n("b",$E,c(i.counts.failed)+" failed",1)],64)):f("v-if",!0),i?.paused?(a(),l(q,{key:1},[t[20]||(t[20]=g(" \xB7 ",-1)),t[21]||(t[21]=n("b",{class:"q-card-failed"},"paused",-1))],64)):f("v-if",!0)]),i?.counts?.active?(a(),l("div",FE,[n("div",{class:"q-card-bar-fill",style:Te({width:i?.counts?.active/((i?.counts?.waiting||0)+(i?.counts?.active||0)+(i?.counts?.delayed||0)||1)*100+"%"})},null,4)])):f("v-if",!0)])],42,IE))),256))]),f(" Detail: throughput chart + stats panel "),e.selectedStats?(a(),l("div",UE,[n("div",BE,[n("div",zE,[n("button",{class:P(["btn btn-sm",{active:e.range=="1h"}]),onClick:t[1]||(t[1]=i=>e.setRange("1h"))},"1h",2),n("button",{class:P(["btn btn-sm",{active:e.range=="6h"}]),onClick:t[2]||(t[2]=i=>e.setRange("6h"))},"6h",2),n("button",{class:P(["btn btn-sm",{active:e.range=="24h"}]),onClick:t[3]||(t[3]=i=>e.setRange("24h"))},"24h",2),n("button",{class:P(["btn btn-sm",{active:e.range=="7d"}]),onClick:t[4]||(t[4]=i=>e.setRange("7d"))},"7d",2)]),n("div",HE,[g("Throughput \xB7 "+c(e.selectedQueue)+" ",1),(e.selectedStats?.completed24h||0)+(e.selectedStats?.failed24h||0)>0?(a(),l("span",jE,[t[23]||(t[23]=n("span",{class:"q-legend-completed"},"\u25CF",-1)),t[24]||(t[24]=g(" Completed ",-1)),t[25]||(t[25]=n("span",{class:"q-legend-failed"},"\u25CF",-1)),t[26]||(t[26]=g(" Failed ",-1)),(e.selectedStats?.completed24h||0)+(e.selectedStats?.failed24h||0)>0?(a(),l(q,{key:0},[t[22]||(t[22]=n("span",{class:"q-legend-exec","aria-hidden":"true"},null,-1)),g(" Avg time \xB7 "+c(e.range),1)],64)):f("v-if",!0)])):f("v-if",!0)]),n("div",GE,[t[28]||(t[28]=n("canvas",{id:"q-throughput-chart",height:"180"},null,-1)),(e.selectedStats?.completed24h||0)+(e.selectedStats?.failed24h||0)===0?(a(),l("div",WE,[...t[27]||(t[27]=[n("strong",null,"No jobs processed in this window",-1),n("span",null,"Completed and failed jobs will chart here.",-1)])])):f("v-if",!0),t[29]||(t[29]=n("div",{id:"q-chart-tooltip",class:"q-chart-tooltip",style:{display:"none"}},null,-1)),t[30]||(t[30]=n("div",{id:"q-chart-crosshair",class:"q-chart-crosshair",style:{display:"none"}},null,-1))])]),n("div",KE,[n("div",YE,"Stats \xB7 "+c(e.selectedQueue),1),n("div",XE,[n("div",JE,[t[31]||(t[31]=n("div",{class:"q-stat-label"},"Waiting",-1)),n("div",{class:"q-stat-value",textContent:c(e.selectedStats?.counts?.waiting||0)},null,8,QE)]),n("div",ZE,[t[32]||(t[32]=n("div",{class:"q-stat-label"},"Active",-1)),n("div",{class:"q-stat-value",textContent:c(e.selectedStats?.counts?.active||0)},null,8,xE)]),n("div",eS,[t[33]||(t[33]=n("div",{class:"q-stat-label"},"Completed (24h)",-1)),n("div",{class:"q-stat-value",textContent:c(e.fmt?.number(e.selectedStats?.completed24h))},null,8,tS)]),n("div",nS,[t[34]||(t[34]=n("div",{class:"q-stat-label"},"Failed (24h)",-1)),n("div",{class:"q-stat-value",textContent:c(e.selectedStats?.failed24h||0)},null,8,sS)]),n("div",oS,[t[35]||(t[35]=n("div",{class:"q-stat-label"},"Delayed",-1)),n("div",{class:"q-stat-value",textContent:c(e.selectedStats?.counts?.delayed||0)},null,8,iS)]),n("div",rS,[t[36]||(t[36]=n("div",{class:"q-stat-label"},"Workers",-1)),n("div",{class:"q-stat-value",textContent:c(e.selectedStats?.workers||0)},null,8,aS)])]),n("div",lS,[n("button",{class:"btn btn-sm",onClick:t[5]||(t[5]=i=>e.togglePause())},c(e.selectedStats?.paused?"Resume "+e.selectedQueue:"Pause "+e.selectedQueue),1),n("button",{class:"btn btn-sm",onClick:t[6]||(t[6]=i=>e.retryFailed()),disabled:!e.selectedStats?.counts?.failed},"Retry failed",8,dS),n("span",uS,[n("button",{class:"btn btn-sm btn-outline-danger",onClick:t[7]||(t[7]=i=>e.drainSelected())},"Drain"),n("button",{class:"btn btn-sm btn-outline-danger",onClick:t[8]||(t[8]=i=>e.emptyQueue())},"Empty")])])])])):f("v-if",!0),e.actionError?(a(),l("div",{key:1,class:"q-toast-error",onClick:t[9]||(t[9]=i=>e.actionError=null)},[t[37]||(t[37]=n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-info"})],-1)),g(" "+c(e.actionError),1)])):f("v-if",!0),f(" Jobs table "),n("div",cS,[n("div",pS,[n("div",fS,"All jobs \xB7 "+c(e.selectedQueue),1),n("div",mS,[n("button",{type:"button",role:"radio",class:P(["seg-chip",{active:e.segView()==="all"}]),"aria-checked":e.segView()==="all",onClick:t[10]||(t[10]=i=>e.setSegView("all"))},[t[38]||(t[38]=g("All ",-1)),n("span",gS,c(e.fmt?.number(e.segCount("all"))),1)],10,hS),n("button",{type:"button",role:"radio",class:P(["seg-chip",{active:e.segView()==="active","is-empty":!e.segCount("active")}]),"aria-checked":e.segView()==="active",onClick:t[11]||(t[11]=i=>e.setSegView("active"))},[t[39]||(t[39]=n("span",{class:"seg-dot ok","aria-hidden":"true"},null,-1)),t[40]||(t[40]=g("Active ",-1)),n("span",yS,c(e.fmt?.number(e.segCount("active"))),1)],10,vS),n("button",{type:"button",role:"radio",class:P(["seg-chip",{active:e.segView()==="waiting","is-empty":!e.segCount("waiting")}]),"aria-checked":e.segView()==="waiting",onClick:t[12]||(t[12]=i=>e.setSegView("waiting"))},[t[41]||(t[41]=n("span",{class:"seg-dot warn","aria-hidden":"true"},null,-1)),t[42]||(t[42]=g("Waiting ",-1)),n("span",wS,c(e.fmt?.number(e.segCount("waiting"))),1)],10,bS),n("button",{type:"button",role:"radio",class:P(["seg-chip",{active:e.segView()==="delayed","is-empty":!e.segCount("delayed")}]),"aria-checked":e.segView()==="delayed",onClick:t[13]||(t[13]=i=>e.setSegView("delayed"))},[t[43]||(t[43]=n("span",{class:"seg-dot warn","aria-hidden":"true"},null,-1)),t[44]||(t[44]=g("Delayed ",-1)),n("span",CS,c(e.fmt?.number(e.segCount("delayed"))),1)],10,kS),n("button",{type:"button",role:"radio",class:P(["seg-chip",{active:e.segView()==="failed","is-empty":!e.segCount("failed")}]),"aria-checked":e.segView()==="failed",onClick:t[14]||(t[14]=i=>e.setSegView("failed"))},[t[45]||(t[45]=n("span",{class:"seg-dot bad","aria-hidden":"true"},null,-1)),t[46]||(t[46]=g("Failed ",-1)),n("span",SS,c(e.fmt?.number(e.segCount("failed"))),1)],10,ES),n("button",{type:"button",role:"radio",class:P(["seg-chip",{active:e.segView()==="completed","is-empty":!e.segCount("completed")}]),"aria-checked":e.segView()==="completed",onClick:t[15]||(t[15]=i=>e.setSegView("completed"))},[t[47]||(t[47]=n("span",{class:"seg-dot done","aria-hidden":"true"},null,-1)),t[48]||(t[48]=g("Completed ",-1)),n("span",RS,c(e.fmt?.number(e.segCount("completed"))),1)],10,NS)])]),n("div",PS,[T(n("input",DS,null,512),[[s,{state:e.viewState,set:i=>{e.query.search=i},value:e.query?.search,form:null,options:{}}]]),n("label",AS,[T(n("input",TS,null,512),[[s,{state:e.viewState,set:i=>{e.query.autoRefresh=i},value:e.query?.autoRefresh,form:null,options:{}}]]),t[49]||(t[49]=n("span",{class:"auto-refresh-label"},"Auto-refresh",-1))]),n("button",{class:"btn btn-sm btn-icon",type:"button",title:"Refresh now",onClick:t[16]||(t[16]=i=>e.refreshNow()),"aria-label":"Refresh"},[...t[50]||(t[50]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-refresh"})],-1)])])]),e.filteredJobs().length>0?(a(),l("table",OS,[t[69]||(t[69]=n("thead",null,[n("tr",null,[n("th",null,"State"),n("th",null,"Job"),n("th",null,"Detail"),n("th",null,"Attempts"),n("th",{class:"q-th-num"},"Duration"),n("th",null,"Progress"),n("th")])],-1)),(a(!0),l(q,null,Q(e.filteredJobs(),(i,o)=>(a(),l("tbody",null,[n("tr",{style:{cursor:"pointer"},class:P({"q-row-failed":i?._state=="failed","q-row-expanded":e.expanded[i?.id]}),onClick:r=>e.toggleJob(i)},[n("td",MS,[n("span",{textContent:c(i?._state),class:P("q-state-badge q-state-"+i?._state)},null,10,VS),i?._state=="delayed"&&i?.delayUntil?(a(),l("span",{key:0,class:"q-delay-hint",textContent:c(e.delayCountdown(i?.delayUntil))},null,8,qS)):f("v-if",!0)]),n("td",{class:"q-cell-id",title:"job:"+i?.id+(i?.name&&i?.name!==i?.id?" \xB7 "+i.name:"")+(i?.data?.repoId&&i?.data?.repoId!==i?.id?" \xB7 "+i.data.repoId:"")},[(a(),l("svg",{class:P(["ui-icon q-chevron",{"q-chevron-open":e.expanded[i?.id]}]),"aria-hidden":"true"},[...t[51]||(t[51]=[n("use",{href:"#ui-icon-chevron-right"},null,-1)])],2)),n("a",{target:"_blank",class:"q-job-link",textContent:c(i?.data?.repoId||i?.id),onClick:t[17]||(t[17]=r=>r.stopPropagation()),href:e.safeUrl("/r/"+(i?.data?.repoId||i?.id))},null,8,LS)],8,_S),n("td",{class:P(["q-cell-detail",{"is-error":i?._state=="failed"}]),title:i?._state=="failed"?i?.failedReason:"",textContent:c(e.jobDetail(i))},null,10,$S),n("td",{class:"q-cell-num",textContent:c(i?.attemptsMade||1)},null,8,FS),n("td",{class:"q-cell-num q-cell-duration",textContent:c(e.jobDuration(i))},null,8,US),n("td",BS,[n("div",{class:P(["q-progress-wrap",{"is-indeterminate":e.jobProgressPct(i)===null}]),"aria-label":e.jobProgressPct(i)===null?"Progress not reported":e.jobProgressPct(i)+"% done"},[n("div",{class:"q-progress-bar",style:Te({"--pct":(e.jobProgressPct(i)||0)+"%"})},null,4),n("span",{class:"q-progress-label",textContent:c(e.jobProgressPct(i)===null?"\u2014":e.jobProgressPct(i)+"%")},null,8,HS)],10,zS)]),n("td",jS,[i?._state=="failed"?(a(),l("button",{key:0,class:"btn btn-sm btn-icon",title:"Retry",onClick:r=>{e.retryJob(i),r.stopPropagation()},"aria-label":"Retry job"},[...t[52]||(t[52]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-refresh"})],-1)])],8,GS)):f("v-if",!0),n("button",{class:"btn btn-sm btn-icon",title:"Remove","aria-label":"Remove job",onClick:r=>{e.removeJob(i),r.stopPropagation()}},[...t[53]||(t[53]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-trash"})],-1)])],8,WS)])],10,IS),e.expanded[i?.id]?(a(),l("tr",KS,[n("td",YS,[n("div",XS,[n("div",JS,[n("div",QS,[t[54]||(t[54]=n("span",{class:"q-job-detail-label"},"Job id",-1)),n("span",ZS,[n("a",{target:"_blank",textContent:c(i?.id),href:e.safeUrl("/r/"+i?.id)},null,8,xS)])]),n("div",eN,[t[55]||(t[55]=n("span",{class:"q-job-detail-label"},"State",-1)),n("span",tN,[n("span",{textContent:c(i?._state),class:P("q-state-badge q-state-"+i?._state)},null,10,nN)])]),i?.data?.repoId?(a(),l("div",sN,[t[56]||(t[56]=n("span",{class:"q-job-detail-label"},"Repo ID",-1)),n("span",{class:"q-job-detail-value",textContent:c(i?.data?.repoId)},null,8,oN)])):f("v-if",!0),i?.timestamp?(a(),l("div",iN,[t[57]||(t[57]=n("span",{class:"q-job-detail-label"},"Created",-1)),n("span",{class:"q-job-detail-value",textContent:c(e.humanTime(i?.timestamp))},null,8,rN)])):f("v-if",!0),i?._state=="delayed"&&i?.delayUntil?(a(),l("div",aN,[t[58]||(t[58]=n("span",{class:"q-job-detail-label"},"Retry at",-1)),n("span",lN,c(e.humanTime(i?.delayUntil))+" ("+c(e.delayCountdown(i?.delayUntil))+")",1)])):f("v-if",!0),i?.processedOn?(a(),l("div",dN,[t[59]||(t[59]=n("span",{class:"q-job-detail-label"},"Processed",-1)),n("span",{class:"q-job-detail-value",textContent:c(e.humanTime(i?.processedOn))},null,8,uN)])):f("v-if",!0),i?.finishedOn?(a(),l("div",cN,[t[60]||(t[60]=n("span",{class:"q-job-detail-label"},"Finished",-1)),n("span",{class:"q-job-detail-value",textContent:c(e.humanTime(i?.finishedOn))},null,8,pN)])):f("v-if",!0),i?.attemptsMade?(a(),l("div",fN,[t[61]||(t[61]=n("span",{class:"q-job-detail-label"},"Attempts",-1)),n("span",{class:"q-job-detail-value",textContent:c(i?.attemptsMade)},null,8,mN)])):f("v-if",!0),i?.progress&&i?.progress?.status?(a(),l("div",hN,[t[62]||(t[62]=n("span",{class:"q-job-detail-label"},"Status",-1)),n("span",{class:"q-job-detail-value",textContent:c(i?.progress?.status)},null,8,gN)])):f("v-if",!0),e.jobProgressPct(i)!==null?(a(),l("div",vN,[t[63]||(t[63]=n("span",{class:"q-job-detail-label"},"Progress",-1)),n("span",{class:"q-job-detail-value",textContent:c(e.jobProgressPct(i)+"%")},null,8,yN)])):f("v-if",!0)]),i?.failedReason?(a(),l("div",bN,[t[64]||(t[64]=n("span",{class:"q-job-detail-label"},"Error",-1)),n("div",{class:"q-error-reason",textContent:c(i?.failedReason)},null,8,wN)])):f("v-if",!0),i?.stacktrace?.length?(a(),l("div",kN,[t[65]||(t[65]=n("span",{class:"q-job-detail-label"},"Stacktrace",-1)),(a(!0),l(q,null,Q(i?.stacktrace,(r,d)=>(a(),l("pre",{class:"q-error-stack",key:d},[n("code",{textContent:c(r)},null,8,CN)]))),128))])):f("v-if",!0),n("div",EN,[i?._state=="failed"?(a(),l("button",{key:0,class:"btn btn-sm",onClick:r=>e.retryJob(i)},[...t[66]||(t[66]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-refresh"})],-1),g(" Retry",-1)])],8,SN)):f("v-if",!0),n("button",{class:"btn btn-sm",onClick:r=>e.removeJob(i)},[...t[67]||(t[67]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-trash"})],-1),g(" Remove",-1)])],8,NN),n("a",{class:"btn btn-sm",target:"_blank",href:e.safeUrl("/r/"+i?.id)},[...t[68]||(t[68]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-external-link"})],-1),g(" View repo",-1)])],8,RN)])])])])):f("v-if",!0)]))),256))])):f("v-if",!0),e.filteredJobs().length==0?(a(),l("div",PN,[t[70]||(t[70]=n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-check-circle"})],-1)),e.query?.search?f("v-if",!0):(a(),l("span",DN,"No jobs in the "+c(e.selectedQueue)+" queue.",1)),e.query?.search?(a(),l("span",AN,"No jobs match the current filters.")):f("v-if",!0)])):f("v-if",!0)])])}var TN={class:"container paper-page admin-page"},ON={class:"seg-bar"},IN={class:"seg-filter",role:"radiogroup","aria-label":"Filter by status"},MN=["aria-checked"],VN={class:"count"},qN=["aria-checked"],_N={class:"count"},LN=["aria-checked"],$N={class:"count"},FN=["aria-checked"],UN={class:"count"},BN=["aria-checked"],zN={class:"count"},HN=["aria-checked"],jN={class:"count"},GN={class:"seg-countline",role:"status"},WN={class:"seg-meta"},KN={key:0,class:"alert alert-danger",style:{margin:"8px 0"}},YN={class:"w-100 admin-filter-toolbar","aria-label":"Repositories","accept-charset":"UTF-8"},XN=["aria-expanded"],JN={class:"search-wrap"},QN={type:"search",class:"form-control","aria-label":"Search repositories",placeholder:"Search repositories\u2026",autocomplete:"off"},ZN={key:0,class:"admin-search-hint"},xN={class:"admin-filter-inline"},eR={type:"text",class:"form-control form-control-sm",placeholder:"username"},tR={class:"admin-filter-inline"},nR={type:"text",class:"form-control form-control-sm",placeholder:"ID"},sR={key:0,class:"admin-filter-inline","aria-label":"Pagination"},oR=["disabled"],iR={style:{"font-family":"var(--font-mono)","font-size":"12px",color:"var(--ink-muted)"}},rR=["disabled"],aR={key:0,class:"admin-filter-row"},lR={class:"admin-active-chips"},dR={class:"key"},uR=["onClick"],cR={key:1,class:"bulk-bar"},pR={class:"paper-table paper-table-repos has-bulk w-100",role:"table","aria-label":"Repositories"},fR={class:"paper-table-head",role:"row"},mR={role:"columnheader",style:{width:"28px"}},hR=["checked"],gR={role:"columnheader"},vR={role:"columnheader"},yR={role:"columnheader",class:"num"},bR={role:"columnheader"},wR={role:"cell",style:{width:"28px"}},kR={type:"checkbox","aria-label":"Select repository"},CR={class:"cell-anon",role:"cell"},ER={class:"anon-text"},SR=["textContent","href"],NR=["title"],RR=["href"],PR=["textContent"],DR=["textContent"],AR=["data-meta-label"],TR=["title","textContent","href"],OR=["data-meta-label"],IR=["textContent","href"],MR=["data-meta-label"],VR={key:3,class:"meta-item"},qR={class:"meta-item"},_R={class:"cell-status",role:"cell"},LR={class:"status-line"},$R=["textContent"],FR=["textContent","title"],UR=["data-unit"],BR=["textContent"],zR={class:"cell-expires",role:"cell"},HR=["textContent"],jR={class:"cell-actions",role:"cell"},GR={class:"dropdown"},WR={class:"dropdown-menu dropdown-menu-right"},KR=["href"],YR=["href"],XR=["href"],JR=["onClick"],QR=["onClick"],ZR=["onClick"],xR=["onClick"],e4=["onClick"],t4=["onClick"],n4={key:0,class:"paper-table-empty"},s4={class:"admin-toolbar",style:{"justify-content":"space-between","border-bottom":"none"}},o4={key:0,class:"pagination-compact"},i4=["disabled"],r4=["max"],a4=["disabled"],l4={class:"admin-filter-inline"},d4={class:"form-control form-control-sm"};function op(e,t){let s=De("field"),i=De("form");return a(),l("div",TN,[t[80]||(t[80]=Ce('
Admin \xA0/\xA0 Repositories

Repositories

',3)),n("div",ON,[n("div",IN,[n("button",{type:"button",role:"radio",class:P(["seg-chip",{active:e.segView()==="all"}]),"aria-checked":e.segView()==="all",onClick:t[0]||(t[0]=o=>e.setSegView("all"))},[t[21]||(t[21]=g("All ",-1)),n("span",VN,c(e.fmt?.number(e.segCount("all"))),1)],10,MN),n("button",{type:"button",role:"radio",class:P(["seg-chip",{active:e.segView()==="ready","is-empty":!e.segCount("ready")}]),"aria-checked":e.segView()==="ready",onClick:t[1]||(t[1]=o=>e.setSegView("ready"))},[t[22]||(t[22]=n("span",{class:"seg-dot ok","aria-hidden":"true"},null,-1)),t[23]||(t[23]=g("Ready ",-1)),n("span",_N,c(e.fmt?.number(e.segCount("ready"))),1)],10,qN),n("button",{type:"button",role:"radio",class:P(["seg-chip",{active:e.segView()==="preparing","is-empty":!e.segCount("preparing")}]),"aria-checked":e.segView()==="preparing",onClick:t[2]||(t[2]=o=>e.setSegView("preparing"))},[t[24]||(t[24]=n("span",{class:"seg-dot warn","aria-hidden":"true"},null,-1)),t[25]||(t[25]=g("Preparing ",-1)),n("span",$N,c(e.fmt?.number(e.segCount("preparing"))),1)],10,LN),n("button",{type:"button",role:"radio",class:P(["seg-chip",{active:e.segView()==="error","is-empty":!e.segCount("error")}]),"aria-checked":e.segView()==="error",onClick:t[3]||(t[3]=o=>e.setSegView("error"))},[t[26]||(t[26]=n("span",{class:"seg-dot bad","aria-hidden":"true"},null,-1)),t[27]||(t[27]=g("Error ",-1)),n("span",UN,c(e.fmt?.number(e.segCount("error"))),1)],10,FN),n("button",{type:"button",role:"radio",class:P(["seg-chip",{active:e.segView()==="expired","is-empty":!e.segCount("expired")}]),"aria-checked":e.segView()==="expired",onClick:t[4]||(t[4]=o=>e.setSegView("expired"))},[t[28]||(t[28]=n("span",{class:"seg-dot off","aria-hidden":"true"},null,-1)),t[29]||(t[29]=g("Expiring / expired ",-1)),n("span",zN,c(e.fmt?.number(e.segCount("expired"))),1)],10,BN),n("button",{type:"button",role:"radio",class:P(["seg-chip",{active:e.segView()==="removed","is-empty":!e.segCount("removed")}]),"aria-checked":e.segView()==="removed",onClick:t[5]||(t[5]=o=>e.setSegView("removed"))},[t[30]||(t[30]=n("span",{class:"seg-dot off","aria-hidden":"true"},null,-1)),t[31]||(t[31]=g("Removing / removed ",-1)),n("span",jN,c(e.fmt?.number(e.segCount("removed"))),1)],10,HN)]),n("p",GN,[n("strong",null,c(e.total>=0?e.fmt.number(e.total):"\u2026"),1),t[32]||(t[32]=g(" shown",-1)),t[33]||(t[33]=n("span",{class:"seg-sep"},"\xB7",-1)),n("span",WN,c(e.fmt?.humanFileSize(e.totalSize))+" on disk",1)])]),e.fetchError?(a(),l("div",KN,[t[34]||(t[34]=n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-warning"})],-1)),g(" "+c(e.fetchError),1)])):f("v-if",!0),T((a(),l("form",YN,[f(" Row 1: search + scoped inputs + headline actions "),n("button",{type:"button",class:"btn btn-sm admin-filters-toggle",onClick:t[6]||(t[6]=o=>e.filtersOpen=!e.filtersOpen),"aria-expanded":e.filtersOpen?"true":"false"},"Filters",8,XN),n("div",{class:P(["admin-filter-row",{"is-open":e.filtersOpen}])},[n("div",JN,[T(n("input",QN,null,512),[[s,{state:e.viewState,set:o=>{e.query.search=o},value:e.query?.search,form:null,options:{}}]]),e.query?.search?f("v-if",!0):(a(),l("span",ZN,"/"))]),n("span",xN,[t[35]||(t[35]=n("label",null,"Owner",-1)),T(n("input",eR,null,512),[[s,{state:e.viewState,set:o=>{e.query.owner=o},value:e.query?.owner,form:null,options:{}}]])]),n("span",tR,[t[36]||(t[36]=n("label",null,"Conference",-1)),T(n("input",nR,null,512),[[s,{state:e.viewState,set:o=>{e.query.conference=o},value:e.query?.conference,form:null,options:{}}]])]),t[40]||(t[40]=n("span",{class:"admin-filter-spacer"},null,-1)),n("button",{class:"btn btn-sm",type:"button",title:"Export current view to CSV",onClick:t[7]||(t[7]=o=>e.exportCsv())},[...t[37]||(t[37]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-export"})],-1),g(" Export",-1)])]),e.totalPage>1?(a(),l("span",sR,[n("button",{class:"btn btn-sm btn-icon",type:"button",onClick:t[8]||(t[8]=o=>e.query.page=Math.max(1,e.query.page-1)),disabled:e.query?.page<=1,"aria-label":"Previous page"},[...t[38]||(t[38]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-chevron-left"})],-1)])],8,oR),n("span",iR,c(e.query?.page)+"/"+c(e.totalPage||1),1),n("button",{class:"btn btn-sm btn-icon",type:"button",onClick:t[9]||(t[9]=o=>e.query.page=Math.min(e.totalPage,e.query.page+1)),disabled:e.query?.page>=e.totalPage,"aria-label":"Next page"},[...t[39]||(t[39]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-chevron-right"})],-1)])],8,rR)])):f("v-if",!0)],2),f(" Row 2: appears only when there are active filter chips "),e.chips?.length?(a(),l("div",aR,[n("div",lR,[(a(!0),l(q,null,Q(e.chips,(o,r)=>(a(),l("span",{class:"admin-active-chip",key:o?.key},[n("span",dR,c(o?.label),1),n("span",null,c(o?.value),1),n("button",{type:"button","aria-label":"Remove filter",onClick:d=>e.clearFilter(o.key)},[...t[41]||(t[41]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#project-icon-close"})],-1)])],8,uR)]))),128))])])):f("v-if",!0)])),[[i,e.viewState]]),e.selectedCount()>0?(a(),l("div",cR,[n("span",null,[n("strong",null,c(e.selectedCount()),1),t[42]||(t[42]=g(" selected",-1))]),n("button",{class:"btn btn-sm",type:"button",onClick:t[10]||(t[10]=o=>e.bulkRefresh())},[...t[43]||(t[43]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-refresh"})],-1),g(" Force refresh",-1)])]),n("button",{class:"btn btn-sm text-danger",type:"button",onClick:t[11]||(t[11]=o=>e.bulkRemoveCache())},[...t[44]||(t[44]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-broom"})],-1),g(" Remove cache",-1)])]),n("button",{class:"btn btn-sm",type:"button",onClick:t[12]||(t[12]=o=>e.clearSelection())},"Clear")])):f("v-if",!0),n("div",pR,[n("div",fR,[n("div",mR,[n("input",{type:"checkbox","aria-label":"Select all on page",onClick:t[13]||(t[13]=o=>e.selectAllOnPage()),checked:e.allSelected},null,8,hR)]),n("div",gR,[n("button",{type:"button",class:P(["sortable",{active:e.query?.sort=="source.repositoryName"}]),onClick:t[14]||(t[14]=o=>e.sortBy("source.repositoryName"))},[t[46]||(t[46]=g("Repository ",-1)),e.sortIcon("source.repositoryName")?(a(),l("svg",{key:0,class:P(["ui-icon sort-direction",{ascending:e.sortIcon("source.repositoryName")==="fa-arrow-up"}]),"aria-hidden":"true"},[...t[45]||(t[45]=[n("use",{href:"#project-icon-arrow"},null,-1)])],2)):f("v-if",!0)],2)]),n("div",vR,[n("button",{type:"button",class:P(["sortable",{active:e.query?.sort=="status"}]),onClick:t[15]||(t[15]=o=>e.sortBy("status"))},[t[48]||(t[48]=g("Status ",-1)),e.sortIcon("status")?(a(),l("svg",{key:0,class:P(["ui-icon sort-direction",{ascending:e.sortIcon("status")==="fa-arrow-up"}]),"aria-hidden":"true"},[...t[47]||(t[47]=[n("use",{href:"#project-icon-arrow"},null,-1)])],2)):f("v-if",!0)],2)]),n("div",yR,[n("button",{type:"button",class:P(["sortable",{active:e.query?.sort=="pageView"}]),onClick:t[16]||(t[16]=o=>e.sortBy("pageView"))},[t[50]||(t[50]=g("Views ",-1)),e.sortIcon("pageView")?(a(),l("svg",{key:0,class:P(["ui-icon sort-direction",{ascending:e.sortIcon("pageView")==="fa-arrow-up"}]),"aria-hidden":"true"},[...t[49]||(t[49]=[n("use",{href:"#project-icon-arrow"},null,-1)])],2)):f("v-if",!0)],2)]),n("div",bR,[n("button",{type:"button",class:P(["sortable",{active:e.query?.sort=="anonymizeDate"}]),onClick:t[17]||(t[17]=o=>e.sortBy("anonymizeDate"))},[t[52]||(t[52]=g("Anonymized ",-1)),e.sortIcon("anonymizeDate")?(a(),l("svg",{key:0,class:P(["ui-icon sort-direction",{ascending:e.sortIcon("anonymizeDate")==="fa-arrow-up"}]),"aria-hidden":"true"},[...t[51]||(t[51]=[n("use",{href:"#project-icon-arrow"},null,-1)])],2)):f("v-if",!0)],2)]),t[53]||(t[53]=n("div",{role:"columnheader","aria-label":"Actions"},null,-1))]),(a(!0),l(q,null,Q(e.filteredRepositories,(o,r)=>(a(),l("div",{class:P(["paper-table-row",{"repo-inactive":o?.status=="expired"||o?.status=="removed","repo-error":o?.status=="error","row-selected":e.selected[o?.repoId]}]),role:"row"},[n("div",wR,[T(n("input",kR,null,512),[[s,{state:e.viewState,set:d=>{e.selected[o.repoId]=d},value:e.selected[o?.repoId],form:null,options:{}}]])]),n("div",CR,[t[56]||(t[56]=n("svg",{class:"ui-icon record-type-icon",role:"img","aria-label":"Repository"},[n("use",{href:"#project-type-repo"})],-1)),n("div",ER,[n("a",{class:"repo-name",target:"_blank",textContent:c(o?.repoId),href:e.safeUrl("/r/"+o?.repoId)},null,8,SR),n("div",{class:"anon-sub anon-meta","data-meta-fit":"",title:[o?.source?.fullName||o?.source?.repositoryName,o?.options?.update?"branch "+o?.source?.branch:"commit "+o?.source?.commit?.substring(0,7),o?.conference?"conference "+o?.conference:"",o?.size?.storage>0?e.fmt?.humanFileSize(o?.size?.storage):"",e.fmt?.number(o?.options?.terms?.length)+(o?.options?.terms?.length===1?" term":" terms")].filter(Boolean).join(" \xB7 ")},[n("a",{class:"src-path",href:e.safeUrl("https://github.com/"+o?.source?.repositoryName+"/")},[(o?.source?.repositoryName||"").includes("/")?(a(),l("span",{key:0,class:"src-owner",textContent:c((d=>d.length>16?d.slice(0,14)+"\u2026":d)((o?.source?.repositoryName||"").split("/")[0]))},null,8,PR)):f("v-if",!0),n("span",{class:"src-repo",textContent:c((o?.source?.repositoryName||"").includes("/")?"/"+(o?.source?.repositoryName||"").split("/").slice(1).join("/"):o?.source?.repositoryName)},null,8,DR)],8,RR),o?.options?.update?f("v-if",!0):(a(),l("span",{key:0,class:"meta-item","data-meta-label":"commit "+(o?.source?.commit||"").substring(0,7)},[n("a",{class:"mono-hash",title:o?.source?.commit,textContent:c(o?.source?.commit?.substring(0,7)),href:e.safeUrl("https://github.com/"+o?.source?.fullName+"/tree/"+o?.source?.commit)},null,8,TR)],8,AR)),o?.options?.update?(a(),l("span",{key:1,class:"meta-item","data-meta-label":"branch "+(o?.source?.branch||"")},[n("a",{textContent:c(o?.source?.branch),href:e.safeUrl("https://github.com/"+o?.source?.fullName+"/tree/"+o?.source?.branch)},null,8,IR)],8,OR)):f("v-if",!0),o?.conference?(a(),l("span",{key:2,class:"meta-item meta-conf","data-meta-label":"conference "+o?.conference},[t[54]||(t[54]=n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#project-icon-conference"})],-1)),g(" "+c(o?.conference),1)],8,MR)):f("v-if",!0),o?.size?.storage>0?(a(),l("span",VR,c(e.fmt?.humanFileSize(o?.size?.storage)),1)):f("v-if",!0),n("span",qR,c(e.fmt?.number(o?.options?.terms?.length))+" "+c(o?.options?.terms?.length===1?"term":"terms"),1),t[55]||(t[55]=n("span",{class:"meta-more",hidden:""},null,-1))],8,NR)])]),n("div",_R,[n("span",LR,[n("span",{class:P(["status-dot","st-"+(o?.status||"unknown")])},null,2),n("span",{textContent:c(e.fmt?.statusLabel(o?.status))},null,8,$R)]),o?.statusMessage?(a(),l("span",{key:0,class:"status-sub",textContent:c(e.fmt?.statusMsg(o?.statusMessage)),title:o?.statusMessage},null,8,FR)):f("v-if",!0)]),n("div",{class:"cell-views num",role:"cell","data-unit":(o?.pageView||0)===1?"view":"views"},[t[57]||(t[57]=n("svg",{class:"ui-icon mobile-meta-icon","aria-hidden":"true"},[n("use",{href:"#project-icon-eye"})],-1)),t[58]||(t[58]=g()),n("span",{textContent:c(e.fmt?.number(o?.pageView||0))},null,8,BR)],8,UR),n("div",zR,[t[59]||(t[59]=n("svg",{class:"ui-icon mobile-meta-icon","aria-hidden":"true"},[n("use",{href:"#project-icon-clock"})],-1)),t[60]||(t[60]=g()),n("span",{textContent:c((e.fmt?.humanTime(o?.anonymizeDate)||"").replace(/^on /,""))},null,8,HR)]),n("div",jR,[n("div",GR,[t[72]||(t[72]=n("button",{class:"btn btn-icon-dots",type:"button","data-toggle":"dropdown","aria-haspopup":"true","aria-expanded":"false","aria-label":"Actions"},[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#project-icon-more"})])],-1)),n("div",WR,[n("a",{class:"dropdown-item",href:e.safeUrl("/anonymize/"+o?.repoId)},[...t[61]||(t[61]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-edit"})],-1),g(" Edit",-1)])],8,KR),n("a",{class:"dropdown-item",href:e.safeUrl("/r/"+o?.repoId+"/")},[...t[62]||(t[62]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#project-icon-eye"})],-1),g(" View repo",-1)])],8,YR),o?.options?.page&&o?.status=="ready"?(a(),l("a",{key:0,class:"dropdown-item",target:"_self",href:e.safeUrl("/w/"+o?.repoId+"/")},[...t[63]||(t[63]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-globe"})],-1),g(" View page",-1)])],8,XR)):f("v-if",!0),n("a",{class:"dropdown-item",href:"#",onClick:ae(d=>e.fetchGithubInfo(o),["prevent"])},[...t[64]||(t[64]=[n("i",{class:"fab fa-github"},null,-1),g(" Live GitHub info",-1)])],8,JR),t[70]||(t[70]=n("div",{class:"dropdown-divider"},null,-1)),T(n("a",{class:"dropdown-item",href:"#",onClick:ae(d=>e.updateRepository(o),["prevent"])},[...t[65]||(t[65]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-refresh"})],-1),g(" Force update",-1)])],8,QR),[[Z,o?.status=="ready"||o?.status=="error"]]),T(n("a",{class:"dropdown-item",href:"#",onClick:ae(d=>e.updateRepository(o),["prevent"])},[...t[66]||(t[66]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-check-circle"})],-1),g(" Enable",-1)])],8,ZR),[[Z,o?.status=="removed"]]),T(n("a",{class:"dropdown-item",href:"#",onClick:ae(d=>e.showStatusMessage(o),["prevent"])},[...t[67]||(t[67]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-warning"})],-1),g(" View status message",-1)])],8,xR),[[Z,o?.statusMessage]]),t[71]||(t[71]=n("div",{class:"dropdown-divider"},null,-1)),n("a",{class:"dropdown-item",href:"#",onClick:ae(d=>e.removeCache(o),["prevent"])},[...t[68]||(t[68]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-broom"})],-1),g(" Remove cache",-1)])],8,e4),T(n("a",{class:"dropdown-item text-danger",href:"#",onClick:ae(d=>e.removeRepository(o),["prevent"])},[...t[69]||(t[69]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-trash"})],-1),g(" Remove",-1)])],8,t4),[[Z,o?.status=="ready"]])])])])],2))),256)),e.filteredRepositories?.length==0?(a(),l("div",n4,[t[73]||(t[73]=n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#project-icon-inbox"})],-1)),t[74]||(t[74]=n("span",null,"No repositories match the current filters.",-1)),e.query.ready&&e.query.expired&&e.query.removed&&e.query.error&&e.query.preparing?f("v-if",!0):(a(),l("button",{key:0,type:"button",class:"btn btn-sm btn-outline-ink",onClick:t[18]||(t[18]=o=>e.showAllStatuses())},"Show all statuses"))])):f("v-if",!0)]),n("div",s4,[t[79]||(t[79]=n("span",{"aria-hidden":"true"},null,-1)),e.totalPage>1?(a(),l("div",o4,[n("button",{class:"btn btn-sm",onClick:t[19]||(t[19]=o=>e.query.page=Math.max(1,e.query.page-1)),disabled:e.query?.page<=1},[...t[75]||(t[75]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-chevron-left"})],-1),g(" Previous ",-1)])],8,i4),T(n("input",{type:"number",class:"form-control form-control-sm",min:"1",style:{width:"56px"},"aria-label":"Page",max:e.totalPage},null,8,r4),[[s,{state:e.viewState,set:o=>{e.query.page=o},value:e.query?.page,form:null,options:{}}]]),n("span",null,"of "+c(e.totalPage),1),n("button",{class:"btn btn-sm",onClick:t[20]||(t[20]=o=>e.query.page=Math.min(e.totalPage,e.query.page+1)),disabled:e.query?.page>=e.totalPage},[...t[76]||(t[76]=[g(" Next ",-1),n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-chevron-right"})],-1)])],8,a4)])):f("v-if",!0),n("span",l4,[t[78]||(t[78]=n("label",null,"Per page",-1)),T((a(),l("select",d4,[...t[77]||(t[77]=[Ce('',5)])])),[[s,{state:e.viewState,set:o=>{e.query.limit=o},value:e.query?.limit,form:null,options:{}}]])])])])}var u4={class:"container paper-page admin-page"},c4={class:"paper-crumbs"},p4={class:"here"},f4={class:"paper-page-title"},m4={key:0,class:"user-detail-card"},h4={class:"user-header"},g4=["src"],v4={class:"user-header-status"},y4={class:"status-dot-wrap"},b4=["textContent"],w4={key:0,class:"type-badge type-repo"},k4={class:"user-actions",style:{"margin-top":"4px"}},C4={class:"user-detail-grid"},E4={class:"detail-value mono-id"},S4={class:"detail-value"},N4=["href"],R4={class:"detail-value"},P4={class:"detail-value"},D4={key:0},A4={key:1,class:"text-muted"},T4={class:"detail-value"},O4={key:0,style:{"margin-top":"20px"}},I4={class:"paper-table w-100",style:{"margin-top":"10px"}},M4={class:"paper-table-row",style:{"grid-template-columns":"1fr 160px"}},V4={class:"cell-anon",role:"cell"},q4={class:"anon-text"},_4=["textContent"],L4={class:"cell-expires",role:"cell"},$4={key:1,class:"admin-section-header"},F4={class:"section-count"},U4={key:2,class:"user-detail-card"},B4={type:"text",class:"form-control",placeholder:"Token name (e.g. dev-laptop)",required:""},z4={key:0,class:"alert alert-warning",role:"alert"},H4={style:{"white-space":"pre-wrap","word-break":"break-all",margin:"8px 0 0","font-family":"var(--font-mono)","font-size":"0.85rem"}},j4={key:1,class:"paper-table w-100"},G4={class:"paper-table-row",role:"row",style:{"grid-template-columns":"1fr 200px 200px 80px"}},W4=["textContent"],K4=["textContent"],Y4={role:"cell"},X4={key:0},J4={key:1,class:"text-muted"},Q4={role:"cell"},Z4=["onClick"],x4={key:2,class:"paper-table-empty"},eP={class:"admin-section-header"},tP={class:"section-count"},nP={class:"seg-bar"},sP={class:"seg-filter",role:"radiogroup","aria-label":"Filter by status"},oP=["aria-checked"],iP={class:"count"},rP=["aria-checked"],aP={class:"count"},lP=["aria-checked"],dP={class:"count"},uP=["aria-checked"],cP={class:"count"},pP=["aria-checked"],fP={class:"count"},mP=["aria-checked"],hP={class:"count"},gP={class:"seg-countline",role:"status"},vP={class:"w-100 admin-filter-toolbar","aria-label":"Repositories","accept-charset":"UTF-8"},yP={class:"admin-filter-row"},bP={class:"search-wrap"},wP={type:"search",class:"form-control","aria-label":"Search repositories",placeholder:"Search repositories or errors\u2026",autocomplete:"off"},kP={key:3,class:"bulk-bar"},CP={class:"paper-table paper-table-repos has-bulk w-100",role:"table","aria-label":"Repositories"},EP={class:"paper-table-head",role:"row"},SP={role:"columnheader",style:{width:"28px"}},NP=["checked"],RP={role:"columnheader"},PP={role:"columnheader"},DP={role:"columnheader",class:"num"},AP={role:"columnheader"},TP={role:"cell",style:{width:"28px"}},OP={type:"checkbox","aria-label":"Select repository"},IP={class:"cell-anon",role:"cell"},MP={class:"anon-text"},VP=["textContent","href"],qP=["title"],_P=["href"],LP=["textContent"],$P=["textContent"],FP=["data-meta-label"],UP=["title","textContent","href"],BP=["data-meta-label"],zP=["textContent","href"],HP=["data-meta-label"],jP={key:3,class:"meta-item"},GP={class:"meta-item"},WP={class:"cell-status",role:"cell"},KP={class:"status-line"},YP=["textContent"],XP=["textContent","title"],JP=["data-unit","textContent"],QP=["textContent"],ZP={class:"cell-actions",role:"cell"},xP={class:"dropdown"},eD={class:"dropdown-menu dropdown-menu-right"},tD=["href"],nD=["href"],sD=["href"],oD=["onClick"],iD=["onClick"],rD=["onClick"],aD=["onClick"],lD=["onClick"],dD=["onClick"],uD={key:0,class:"paper-table-empty"};function ip(e,t){let s=De("field"),i=De("form");return a(),l("div",u4,[n("div",c4,[t[23]||(t[23]=n("a",{href:"/admin/"},"Admin",-1)),t[24]||(t[24]=g(" \xA0/\xA0 ",-1)),t[25]||(t[25]=n("a",{href:"/admin/users"},"Users",-1)),t[26]||(t[26]=g(" \xA0/\xA0 ",-1)),n("span",p4,c(e.userInfo?.username||"Profile"),1)]),n("h1",f4,c(e.userInfo?.username||"User"),1),t[93]||(t[93]=Ce('',1)),e.userInfo?(a(),l("div",m4,[n("div",h4,[e.userInfo?.photo?(a(),l("img",{key:0,width:"56",height:"56",src:e.safeUrl(e.userInfo?.photo)},null,8,g4)):f("v-if",!0),n("div",null,[n("div",v4,[n("span",y4,[n("span",{class:P(["status-dot","st-"+(e.userInfo?.status||"unknown")])},null,2),n("span",{textContent:c(e.fmt?.title(e.userInfo?.status))},null,8,b4)]),e.userInfo?.isAdmin?(a(),l("span",w4,"Admin")):f("v-if",!0)]),n("div",k4,[e.userInfo?.status!=="banned"&&e.userInfo?.username!==e.user?.username?(a(),l("button",{key:0,class:"btn btn-sm btn-outline-danger",onClick:t[0]||(t[0]=o=>e.banUser())},[...t[27]||(t[27]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-ban"})],-1),g(" Ban",-1)])])):f("v-if",!0),e.userInfo?.status==="banned"||e.userInfo?.status==="removed"?(a(),l("button",{key:1,class:"btn btn-sm",onClick:t[1]||(t[1]=o=>e.activateUser())},[...t[28]||(t[28]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-check-circle"})],-1),g(" Activate",-1)])])):f("v-if",!0),e.userInfo?.isAdmin?f("v-if",!0):(a(),l("button",{key:2,class:"btn btn-sm",onClick:t[2]||(t[2]=o=>e.promoteUser())},[...t[29]||(t[29]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-user-shield"})],-1),g(" Promote to admin",-1)])])),e.userInfo?.isAdmin&&e.userInfo?.username!==e.user?.username?(a(),l("button",{key:3,class:"btn btn-sm btn-outline-ink",onClick:t[3]||(t[3]=o=>e.demoteUser())},[...t[30]||(t[30]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-user-minus"})],-1),g(" Remove admin",-1)])])):f("v-if",!0)])])]),n("div",C4,[t[33]||(t[33]=n("div",{class:"detail-label"},"ID",-1)),n("div",E4,c(e.userInfo?._id),1),t[34]||(t[34]=n("div",{class:"detail-label"},"Email",-1)),n("div",{class:P(["detail-value",{"is-empty":!e.userInfo?.emails?.[0]?.email}])},c(e.userInfo?.emails?.[0]?.email||"Not shared"),3),t[35]||(t[35]=n("div",{class:"detail-label"},"Access token",-1)),n("div",{class:P(["detail-value",{"is-empty":!e.userInfo?.accessTokens?.github}]),style:{"font-family":"var(--font-mono)","font-size":"0.85rem"}},c(e.userInfo?.accessTokens?.github||"Not stored"),3),t[36]||(t[36]=n("div",{class:"detail-label"},"GitHub",-1)),n("div",S4,[n("a",{target:"_blank",href:e.safeUrl("https://github.com/"+e.userInfo?.username)},[t[31]||(t[31]=n("i",{class:"fab fa-github"},null,-1)),g(" "+c(e.userInfo?.username),1)],8,N4)]),t[37]||(t[37]=n("div",{class:"detail-label"},"Created",-1)),n("div",R4,c(e.fmt?.humanTime(e.userInfo?.dateOfEntry)),1),t[38]||(t[38]=n("div",{class:"detail-label"},"Last connection",-1)),n("div",P4,[e.userInfo?.accessTokenDates?.github?(a(),l("span",D4,c(e.fmt?.humanTime(e.userInfo?.accessTokenDates?.github)),1)):f("v-if",!0),e.userInfo?.accessTokenDates?.github?f("v-if",!0):(a(),l("span",A4,"Not recorded (GitHub App sign-in)"))]),t[39]||(t[39]=n("div",{class:"detail-label"},"GitHub repos",-1)),n("div",T4,[g(c(e.userInfo?.repositories?.length?e.userInfo.repositories.length+" repositories":"Not synced")+" ",1),e.userInfo?.repositories?.length?(a(),l("button",{key:0,class:"btn btn-sm ml-2",onClick:t[4]||(t[4]=o=>e.showRepos=!e.showRepos)},c(e.showRepos?"Hide repos":"Show repos"),1)):f("v-if",!0),n("button",{class:"btn btn-sm ml-1",onClick:t[5]||(t[5]=o=>e.getGitHubRepositories())},[...t[32]||(t[32]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-refresh"})],-1),g(" Refresh ",-1)])])])]),e.showRepos?(a(),l("div",O4,[t[42]||(t[42]=n("div",{class:"paper-section-eyebrow"},"GitHub repositories",-1)),n("div",I4,[(a(!0),l(q,null,Q(e.userInfo?.repositories,(o,r)=>(a(),l("div",M4,[n("div",V4,[t[40]||(t[40]=n("svg",{class:"ui-icon record-type-icon",role:"img","aria-label":"Repository"},[n("use",{href:"#project-type-repo"})],-1)),n("div",q4,[n("span",{class:"repo-name",textContent:c(o?.name)},null,8,_4)])]),n("div",L4,[t[41]||(t[41]=n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-database"})],-1)),g(" "+c(e.fmt?.humanFileSize(o?.size)),1)])]))),256))])])):f("v-if",!0)])):f("v-if",!0),e.userInfo&&e.userInfo?.isAdmin&&e.user&&e.user?.username==e.userInfo?.username?(a(),l("div",$4,[t[43]||(t[43]=n("h2",null,[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-key"})]),g(" API tokens")],-1)),n("span",F4,c(e.tokens?.length),1)])):f("v-if",!0),e.userInfo&&e.userInfo?.isAdmin&&e.user&&e.user?.username==e.userInfo?.username?(a(),l("div",U4,[t[49]||(t[49]=n("p",{class:"paper-page-lede"},[g("Personal API tokens for this admin account. Send as "),n("code",null,"Authorization: Bearer "),g(" to authenticate without GitHub OAuth (useful for development).")],-1)),T((a(),l("form",{class:"d-flex",style:{gap:"8px","margin-bottom":"12px"},onSubmit:t[6]||(t[6]=ae(o=>e.submitForm(o,()=>{e.createToken()}),["prevent"]))},[T(n("input",B4,null,512),[[s,{state:e.viewState,set:o=>{e.tokenForm.name=o},value:e.tokenForm?.name,form:null,options:{}}]]),t[44]||(t[44]=n("button",{type:"submit",class:"btn btn-ink"},[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#project-icon-plus"})]),g(" Generate")],-1))],32)),[[i,e.viewState]]),e.tokenForm?.plaintext?(a(),l("div",z4,[t[45]||(t[45]=n("strong",null,"Copy this token now \u2014 it will not be shown again:",-1)),n("pre",H4,c(e.tokenForm?.plaintext),1),n("button",{class:"btn btn-sm",onClick:t[7]||(t[7]=o=>e.tokenForm.plaintext=null)},"Dismiss")])):f("v-if",!0),e.tokens?.length?(a(),l("div",j4,[t[47]||(t[47]=n("div",{class:"paper-table-head",role:"row",style:{"grid-template-columns":"1fr 200px 200px 80px"}},[n("div",{role:"columnheader"},"Name"),n("div",{role:"columnheader"},"Created"),n("div",{role:"columnheader"},"Last used"),n("div",{role:"columnheader","aria-label":"Actions"})],-1)),(a(!0),l(q,null,Q(e.tokens,(o,r)=>(a(),l("div",G4,[n("div",{role:"cell",textContent:c(o?.name)},null,8,W4),n("div",{role:"cell",textContent:c(e.fmt?.humanTime(o?.createdAt))},null,8,K4),n("div",Y4,[o?.lastUsedAt?(a(),l("span",X4,c(e.fmt?.humanTime(o?.lastUsedAt)),1)):f("v-if",!0),o?.lastUsedAt?f("v-if",!0):(a(),l("span",J4,"never"))]),n("div",Q4,[n("button",{class:"btn btn-sm text-danger btn-icon",title:"Revoke","aria-label":"Revoke token",onClick:d=>e.revokeToken(o)},[...t[46]||(t[46]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-trash"})],-1)])],8,Z4)])]))),256))])):f("v-if",!0),e.tokens?.length?f("v-if",!0):(a(),l("div",x4,[...t[48]||(t[48]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#project-icon-inbox"})],-1),n("span",null,"No tokens yet.",-1)])]))])):f("v-if",!0),n("div",eP,[t[50]||(t[50]=n("h2",null,[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#project-type-repo"})]),g(" Anonymized repositories")],-1)),n("span",tP,c(e.repositories?.length),1)]),n("div",nP,[n("div",sP,[n("button",{type:"button",role:"radio",class:P(["seg-chip",{active:e.segView()==="all"}]),"aria-checked":e.segView()==="all",onClick:t[8]||(t[8]=o=>e.setSegView("all"))},[t[51]||(t[51]=g("All ",-1)),n("span",iP,c(e.fmt?.number(e.segCount("all"))),1)],10,oP),n("button",{type:"button",role:"radio",class:P(["seg-chip",{active:e.segView()==="ready","is-empty":!e.segCount("ready")}]),"aria-checked":e.segView()==="ready",onClick:t[9]||(t[9]=o=>e.setSegView("ready"))},[t[52]||(t[52]=n("span",{class:"seg-dot ok","aria-hidden":"true"},null,-1)),t[53]||(t[53]=g("Ready ",-1)),n("span",aP,c(e.fmt?.number(e.segCount("ready"))),1)],10,rP),n("button",{type:"button",role:"radio",class:P(["seg-chip",{active:e.segView()==="preparing","is-empty":!e.segCount("preparing")}]),"aria-checked":e.segView()==="preparing",onClick:t[10]||(t[10]=o=>e.setSegView("preparing"))},[t[54]||(t[54]=n("span",{class:"seg-dot warn","aria-hidden":"true"},null,-1)),t[55]||(t[55]=g("Preparing ",-1)),n("span",dP,c(e.fmt?.number(e.segCount("preparing"))),1)],10,lP),n("button",{type:"button",role:"radio",class:P(["seg-chip",{active:e.segView()==="error","is-empty":!e.segCount("error")}]),"aria-checked":e.segView()==="error",onClick:t[11]||(t[11]=o=>e.setSegView("error"))},[t[56]||(t[56]=n("span",{class:"seg-dot bad","aria-hidden":"true"},null,-1)),t[57]||(t[57]=g("Error ",-1)),n("span",cP,c(e.fmt?.number(e.segCount("error"))),1)],10,uP),n("button",{type:"button",role:"radio",class:P(["seg-chip",{active:e.segView()==="expired","is-empty":!e.segCount("expired")}]),"aria-checked":e.segView()==="expired",onClick:t[12]||(t[12]=o=>e.setSegView("expired"))},[t[58]||(t[58]=n("span",{class:"seg-dot off","aria-hidden":"true"},null,-1)),t[59]||(t[59]=g("Expiring / expired ",-1)),n("span",fP,c(e.fmt?.number(e.segCount("expired"))),1)],10,pP),n("button",{type:"button",role:"radio",class:P(["seg-chip",{active:e.segView()==="removed","is-empty":!e.segCount("removed")}]),"aria-checked":e.segView()==="removed",onClick:t[13]||(t[13]=o=>e.setSegView("removed"))},[t[60]||(t[60]=n("span",{class:"seg-dot off","aria-hidden":"true"},null,-1)),t[61]||(t[61]=g("Removing / removed ",-1)),n("span",hP,c(e.fmt?.number(e.segCount("removed"))),1)],10,mP)]),n("p",gP,[n("strong",null,c(e.fmt.number(e.filteredRepositories?.length||0)),1),t[62]||(t[62]=g(" shown",-1))])]),T((a(),l("form",vP,[n("div",yP,[n("div",bP,[T(n("input",wP,null,512),[[s,{state:e.viewState,set:o=>{e.search=o},value:e.search,form:null,options:{}}]])]),t[64]||(t[64]=n("span",{class:"admin-filter-spacer"},null,-1)),n("button",{class:"btn btn-sm",type:"button",title:"Export current view to CSV",onClick:t[14]||(t[14]=o=>e.exportCsv())},[...t[63]||(t[63]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-export"})],-1),g(" Export",-1)])])])])),[[i,e.viewState]]),e.selectedCount()>0?(a(),l("div",kP,[n("span",null,[n("strong",null,c(e.selectedCount()),1),t[65]||(t[65]=g(" selected",-1))]),n("button",{class:"btn btn-sm",type:"button",onClick:t[15]||(t[15]=o=>e.bulkRefresh())},[...t[66]||(t[66]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-refresh"})],-1),g(" Force refresh",-1)])]),n("button",{class:"btn btn-sm text-danger",type:"button",onClick:t[16]||(t[16]=o=>e.bulkRemoveCache())},[...t[67]||(t[67]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-broom"})],-1),g(" Remove cache",-1)])]),n("button",{class:"btn btn-sm",type:"button",onClick:t[17]||(t[17]=o=>e.clearSelection())},"Clear")])):f("v-if",!0),n("div",CP,[n("div",EP,[n("div",SP,[n("input",{type:"checkbox","aria-label":"Select all on page",onClick:t[18]||(t[18]=o=>e.selectAllOnPage()),checked:e.allSelected},null,8,NP)]),n("div",RP,[n("button",{type:"button",class:P(["sortable",{active:e.query?.sort=="source.repositoryName"}]),onClick:t[19]||(t[19]=o=>e.sortBy("source.repositoryName"))},[t[69]||(t[69]=g("Repository ",-1)),e.sortIcon("source.repositoryName")?(a(),l("svg",{key:0,class:P(["ui-icon sort-direction",{ascending:e.sortIcon("source.repositoryName")==="fa-arrow-up"}]),"aria-hidden":"true"},[...t[68]||(t[68]=[n("use",{href:"#project-icon-arrow"},null,-1)])],2)):f("v-if",!0)],2)]),n("div",PP,[n("button",{type:"button",class:P(["sortable",{active:e.query?.sort=="status"}]),onClick:t[20]||(t[20]=o=>e.sortBy("status"))},[t[71]||(t[71]=g("Status ",-1)),e.sortIcon("status")?(a(),l("svg",{key:0,class:P(["ui-icon sort-direction",{ascending:e.sortIcon("status")==="fa-arrow-up"}]),"aria-hidden":"true"},[...t[70]||(t[70]=[n("use",{href:"#project-icon-arrow"},null,-1)])],2)):f("v-if",!0)],2)]),n("div",DP,[n("button",{type:"button",class:P(["sortable",{active:e.query?.sort=="pageView"}]),onClick:t[21]||(t[21]=o=>e.sortBy("pageView"))},[t[73]||(t[73]=g("Views ",-1)),e.sortIcon("pageView")?(a(),l("svg",{key:0,class:P(["ui-icon sort-direction",{ascending:e.sortIcon("pageView")==="fa-arrow-up"}]),"aria-hidden":"true"},[...t[72]||(t[72]=[n("use",{href:"#project-icon-arrow"},null,-1)])],2)):f("v-if",!0)],2)]),n("div",AP,[n("button",{type:"button",class:P(["sortable",{active:e.query?.sort=="anonymizeDate"}]),onClick:t[22]||(t[22]=o=>e.sortBy("anonymizeDate"))},[t[75]||(t[75]=g("Anonymized ",-1)),e.sortIcon("anonymizeDate")?(a(),l("svg",{key:0,class:P(["ui-icon sort-direction",{ascending:e.sortIcon("anonymizeDate")==="fa-arrow-up"}]),"aria-hidden":"true"},[...t[74]||(t[74]=[n("use",{href:"#project-icon-arrow"},null,-1)])],2)):f("v-if",!0)],2)]),t[76]||(t[76]=n("div",{role:"columnheader","aria-label":"Actions"},null,-1))]),(a(!0),l(q,null,Q(e.filteredRepositories,(o,r)=>(a(),l("div",{class:P(["paper-table-row",{"repo-inactive":o?.status=="expired"||o?.status=="removed","repo-error":o?.status=="error","row-selected":e.selected[o?.repoId]}]),role:"row"},[n("div",TP,[T(n("input",OP,null,512),[[s,{state:e.viewState,set:d=>{e.selected[o.repoId]=d},value:e.selected[o?.repoId],form:null,options:{}}]])]),n("div",IP,[t[79]||(t[79]=n("svg",{class:"ui-icon record-type-icon",role:"img","aria-label":"Repository"},[n("use",{href:"#project-type-repo"})],-1)),n("div",MP,[n("a",{class:"repo-name",target:"_blank",textContent:c(o?.repoId),href:e.safeUrl("/r/"+o?.repoId)},null,8,VP),n("div",{class:"anon-sub anon-meta","data-meta-fit":"",title:[o?.source?.fullName||o?.source?.repositoryName,o?.options?.update?"branch "+o?.source?.branch:"commit "+o?.source?.commit?.substring(0,7),o?.conference?"conference "+o?.conference:"",o?.size?.storage>0?e.fmt?.humanFileSize(o?.size?.storage):"",e.fmt?.number(o?.options?.terms?.length)+(o?.options?.terms?.length===1?" term":" terms")].filter(Boolean).join(" \xB7 ")},[n("a",{class:"src-path",href:e.safeUrl("https://github.com/"+o?.source?.fullName+"/")},[(o?.source?.fullName||"").includes("/")?(a(),l("span",{key:0,class:"src-owner",textContent:c((d=>d.length>16?d.slice(0,14)+"\u2026":d)((o?.source?.fullName||"").split("/")[0]))},null,8,LP)):f("v-if",!0),n("span",{class:"src-repo",textContent:c((o?.source?.fullName||"").includes("/")?"/"+(o?.source?.fullName||"").split("/").slice(1).join("/"):o?.source?.fullName)},null,8,$P)],8,_P),o?.options?.update?f("v-if",!0):(a(),l("span",{key:0,class:"meta-item","data-meta-label":"commit "+(o?.source?.commit||"").substring(0,7)},[n("a",{class:"mono-hash",title:o?.source?.commit,textContent:c(o?.source?.commit?.substring(0,7)),href:e.safeUrl("https://github.com/"+o?.source?.fullName+"/tree/"+o?.source?.commit)},null,8,UP)],8,FP)),o?.options?.update?(a(),l("span",{key:1,class:"meta-item","data-meta-label":"branch "+(o?.source?.branch||"")},[n("a",{textContent:c(o?.source?.branch),href:e.safeUrl("https://github.com/"+o?.source?.fullName+"/tree/"+o?.source?.branch)},null,8,zP)],8,BP)):f("v-if",!0),o?.conference?(a(),l("span",{key:2,class:"meta-item meta-conf","data-meta-label":"conference "+o?.conference},[t[77]||(t[77]=n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#project-icon-conference"})],-1)),g(" "+c(o?.conference),1)],8,HP)):f("v-if",!0),o?.size?.storage>0?(a(),l("span",jP,c(e.fmt?.humanFileSize(o?.size?.storage)),1)):f("v-if",!0),n("span",GP,c(e.fmt?.number(o?.options?.terms?.length))+" "+c(o?.options?.terms?.length===1?"term":"terms"),1),t[78]||(t[78]=n("span",{class:"meta-more",hidden:""},null,-1))],8,qP)])]),n("div",WP,[n("span",KP,[n("span",{class:P(["status-dot","st-"+(o?.status||"unknown")])},null,2),n("span",{textContent:c(e.fmt?.statusLabel(o?.status))},null,8,YP)]),o?.statusMessage?(a(),l("span",{key:0,class:"status-sub",textContent:c(e.fmt?.statusMsg(o?.statusMessage)),title:o?.statusMessage},null,8,XP)):f("v-if",!0)]),n("div",{class:"cell-views num",role:"cell","data-unit":(o?.pageView||0)===1?"view":"views",textContent:c(e.fmt?.number(o?.pageView||0))},null,8,JP),n("div",{class:"cell-expires",role:"cell",textContent:c(e.fmt?.humanTime(o?.anonymizeDate))},null,8,QP),n("div",ZP,[n("div",xP,[t[91]||(t[91]=n("button",{class:"btn btn-icon-dots",type:"button","data-toggle":"dropdown","aria-haspopup":"true","aria-expanded":"false","aria-label":"Actions"},[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#project-icon-more"})])],-1)),n("div",eD,[n("a",{class:"dropdown-item",href:e.safeUrl("/anonymize/"+o?.repoId)},[...t[80]||(t[80]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-edit"})],-1),g(" Edit",-1)])],8,tD),n("a",{class:"dropdown-item",href:e.safeUrl("/r/"+o?.repoId+"/")},[...t[81]||(t[81]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#project-icon-eye"})],-1),g(" View repo",-1)])],8,nD),o?.options?.page&&o?.status=="ready"?(a(),l("a",{key:0,class:"dropdown-item",target:"_self",href:e.safeUrl("/w/"+o?.repoId+"/")},[...t[82]||(t[82]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-globe"})],-1),g(" View page",-1)])],8,sD)):f("v-if",!0),n("a",{class:"dropdown-item",href:"#",onClick:ae(d=>e.fetchGithubInfo(o),["prevent"])},[...t[83]||(t[83]=[n("i",{class:"fab fa-github"},null,-1),g(" Live GitHub info",-1)])],8,oD),t[89]||(t[89]=n("div",{class:"dropdown-divider"},null,-1)),T(n("a",{class:"dropdown-item",href:"#",onClick:ae(d=>e.updateRepository(o),["prevent"])},[...t[84]||(t[84]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-refresh"})],-1),g(" Force update",-1)])],8,iD),[[Z,o?.status=="ready"||o?.status=="error"]]),T(n("a",{class:"dropdown-item",href:"#",onClick:ae(d=>e.updateRepository(o),["prevent"])},[...t[85]||(t[85]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-check-circle"})],-1),g(" Enable",-1)])],8,rD),[[Z,o?.status=="removed"]]),T(n("a",{class:"dropdown-item",href:"#",onClick:ae(d=>e.showStatusMessage(o),["prevent"])},[...t[86]||(t[86]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-warning"})],-1),g(" View status message",-1)])],8,aD),[[Z,o?.statusMessage]]),t[90]||(t[90]=n("div",{class:"dropdown-divider"},null,-1)),n("a",{class:"dropdown-item",href:"#",onClick:ae(d=>e.removeCache(o),["prevent"])},[...t[87]||(t[87]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-broom"})],-1),g(" Remove cache",-1)])],8,lD),T(n("a",{class:"dropdown-item text-danger",href:"#",onClick:ae(d=>e.removeRepository(o),["prevent"])},[...t[88]||(t[88]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-trash"})],-1),g(" Remove",-1)])],8,dD),[[Z,o?.status=="ready"]])])])])],2))),256)),e.filteredRepositories?.length==0?(a(),l("div",uD,[...t[92]||(t[92]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#project-icon-inbox"})],-1),n("span",null,"No repositories match the current filters.",-1)])])):f("v-if",!0)])])}var cD={class:"container paper-page admin-page"},pD={class:"seg-bar"},fD={class:"seg-filter",role:"radiogroup","aria-label":"Filter by status"},mD=["aria-checked"],hD={class:"count"},gD=["aria-checked"],vD={class:"count"},yD=["aria-checked"],bD={class:"count"},wD=["aria-checked"],kD={class:"count"},CD={class:"seg-countline",role:"status"},ED={key:0,class:"alert alert-danger",style:{margin:"8px 0"}},SD={class:"w-100 admin-filter-toolbar","aria-label":"Users","accept-charset":"UTF-8"},ND={class:"admin-filter-row"},RD={class:"search-wrap"},PD={type:"search",class:"form-control","aria-label":"Search users",placeholder:"Search username or email\u2026",autocomplete:"off"},DD={key:0,class:"admin-search-hint"},AD={class:"admin-filter-inline"},TD={class:"form-control form-control-sm"},OD={key:0,class:"admin-filter-inline","aria-label":"Pagination"},ID=["disabled"],MD={style:{"font-family":"var(--font-mono)","font-size":"12px",color:"var(--ink-muted)"}},VD=["disabled"],qD={key:0,class:"admin-filter-row"},_D={class:"admin-active-chips"},LD={class:"key"},$D=["onClick"],FD={key:1,class:"bulk-bar"},UD={class:"paper-table w-100",role:"table","aria-label":"Users",style:{"--cols":"28px minmax(280px, 2.4fr) 100px 140px 140px 52px"}},BD={class:"paper-table-head admin-users-row",role:"row"},zD={role:"columnheader",style:{width:"28px"}},HD=["checked"],jD={role:"columnheader"},GD={role:"columnheader"},WD={role:"cell",style:{width:"28px"}},KD={type:"checkbox","aria-label":"Select user"},YD={class:"cell-anon",role:"cell"},XD=["src"],JD={key:1,class:"avatar-fallback","aria-hidden":"true"},QD={class:"anon-text"},ZD={class:"user-name-line"},xD=["textContent","href"],eA=["href","title","aria-label"],tA={class:"anon-sub meta-dots"},nA=["title"],sA={key:1},oA={class:"cell-views num",role:"cell"},iA=["title","textContent","href"],rA={class:"cell-status",role:"cell"},aA=["textContent"],lA={class:"cell-status",role:"cell"},dA={key:0,class:"role-pill"},uA={key:1,class:"empty-dash"},cA={class:"cell-actions",role:"cell"},pA={class:"dropdown"},fA={class:"dropdown-menu dropdown-menu-right"},mA=["href"],hA=["href"],gA=["onClick"],vA=["onClick"],yA={key:0,class:"paper-table-empty"},bA={class:"admin-toolbar",style:{"justify-content":"space-between","border-bottom":"none"}},wA={key:0,class:"pagination-compact"},kA=["disabled"],CA=["max"],EA=["disabled"],SA={class:"admin-filter-inline"},NA={class:"form-control form-control-sm"};function rp(e,t){let s=De("field"),i=De("form");return a(),l("div",cD,[t[53]||(t[53]=Ce('
Admin \xA0/\xA0 Users

Users

',3)),n("div",pD,[n("div",fD,[n("button",{type:"button",role:"radio",class:P(["seg-chip",{active:!e.query?.status}]),"aria-checked":!e.query?.status,onClick:t[0]||(t[0]=o=>{e.query.status="",e.query.page=1})},[t[14]||(t[14]=g("All ",-1)),n("span",hD,c(e.fmt?.number(e.statusCountFor("active")+e.statusCountFor("banned")+e.statusCountFor("removed"))),1)],10,mD),n("button",{type:"button",role:"radio",class:P(["seg-chip",{active:e.query?.status==="active","is-empty":!e.statusCountFor("active")}]),"aria-checked":e.query?.status==="active",onClick:t[1]||(t[1]=o=>{e.query.status="active",e.query.page=1})},[t[15]||(t[15]=n("span",{class:"seg-dot ok","aria-hidden":"true"},null,-1)),t[16]||(t[16]=g("Active ",-1)),n("span",vD,c(e.fmt?.number(e.statusCountFor("active"))),1)],10,gD),n("button",{type:"button",role:"radio",class:P(["seg-chip",{active:e.query?.status==="banned","is-empty":!e.statusCountFor("banned")}]),"aria-checked":e.query?.status==="banned",onClick:t[2]||(t[2]=o=>{e.query.status="banned",e.query.page=1})},[t[17]||(t[17]=n("span",{class:"seg-dot bad","aria-hidden":"true"},null,-1)),t[18]||(t[18]=g("Banned ",-1)),n("span",bD,c(e.fmt?.number(e.statusCountFor("banned"))),1)],10,yD),n("button",{type:"button",role:"radio",class:P(["seg-chip",{active:e.query?.status==="removed","is-empty":!e.statusCountFor("removed")}]),"aria-checked":e.query?.status==="removed",onClick:t[3]||(t[3]=o=>{e.query.status="removed",e.query.page=1})},[t[19]||(t[19]=n("span",{class:"seg-dot off","aria-hidden":"true"},null,-1)),t[20]||(t[20]=g("Removed ",-1)),n("span",kD,c(e.fmt?.number(e.statusCountFor("removed"))),1)],10,wD)]),n("p",CD,[n("strong",null,c(e.total>=0?e.fmt.number(e.total):"\u2026"),1),t[21]||(t[21]=g(" shown",-1))])]),e.fetchError?(a(),l("div",ED,[t[22]||(t[22]=n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-warning"})],-1)),g(" "+c(e.fetchError),1)])):f("v-if",!0),T((a(),l("form",SD,[n("div",ND,[n("div",RD,[T(n("input",PD,null,512),[[s,{state:e.viewState,set:o=>{e.query.search=o},value:e.query?.search,form:null,options:{}}]]),e.query?.search?f("v-if",!0):(a(),l("span",DD,"/"))]),n("span",AD,[t[24]||(t[24]=n("label",null,"Role",-1)),T((a(),l("select",TD,[...t[23]||(t[23]=[n("option",{value:""},"Any",-1),n("option",{value:"admin"},"Admin",-1)])])),[[s,{state:e.viewState,set:o=>{e.query.role=o},value:e.query?.role,form:null,options:{}}]])]),t[28]||(t[28]=n("span",{class:"admin-filter-spacer"},null,-1)),n("button",{class:"btn btn-sm",type:"button",onClick:t[4]||(t[4]=o=>e.exportCsv())},[...t[25]||(t[25]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-export"})],-1),g(" Export",-1)])]),e.totalPage>1?(a(),l("span",OD,[n("button",{class:"btn btn-sm btn-icon",type:"button",onClick:t[5]||(t[5]=o=>e.query.page=Math.max(1,e.query.page-1)),disabled:e.query?.page<=1,"aria-label":"Previous page"},[...t[26]||(t[26]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-chevron-left"})],-1)])],8,ID),n("span",MD,c(e.query?.page)+"/"+c(e.totalPage||1),1),n("button",{class:"btn btn-sm btn-icon",type:"button",onClick:t[6]||(t[6]=o=>e.query.page=Math.min(e.totalPage,e.query.page+1)),disabled:e.query?.page>=e.totalPage,"aria-label":"Next page"},[...t[27]||(t[27]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-chevron-right"})],-1)])],8,VD)])):f("v-if",!0)]),e.chips?.length?(a(),l("div",qD,[n("div",_D,[(a(!0),l(q,null,Q(e.chips,(o,r)=>(a(),l("span",{class:"admin-active-chip",key:o?.key},[n("span",LD,c(o?.label),1),n("span",null,c(o?.value),1),n("button",{type:"button",onClick:d=>e.clearFilter(o.key),"aria-label":"Clear filter"},[...t[29]||(t[29]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#project-icon-close"})],-1)])],8,$D)]))),128))])])):f("v-if",!0)])),[[i,e.viewState]]),e.selectedCount()>0?(a(),l("div",FD,[n("span",null,[n("strong",null,c(e.selectedCount()),1),t[30]||(t[30]=g(" selected",-1))]),n("button",{class:"btn btn-sm text-danger",type:"button",onClick:t[7]||(t[7]=o=>e.bulkBan())},[...t[31]||(t[31]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-ban"})],-1),g(" Ban",-1)])]),n("button",{class:"btn btn-sm",type:"button",onClick:t[8]||(t[8]=o=>{e.selected={},e.allSelected=!1})},"Clear")])):f("v-if",!0),n("div",UD,[n("div",BD,[n("div",zD,[n("input",{type:"checkbox","aria-label":"Select all on page",onClick:t[9]||(t[9]=o=>e.selectAllOnPage()),checked:e.allSelected},null,8,HD)]),n("div",jD,[n("button",{type:"button",class:P(["sortable",{active:e.query?.sort=="username"}]),onClick:t[10]||(t[10]=o=>e.sortBy("username"))},[t[33]||(t[33]=g("User ",-1)),e.sortIcon("username")?(a(),l("svg",{key:0,class:P(["ui-icon sort-direction",{ascending:e.sortIcon("username")==="fa-arrow-up"}]),"aria-hidden":"true"},[...t[32]||(t[32]=[n("use",{href:"#project-icon-arrow"},null,-1)])],2)):f("v-if",!0)],2)]),t[36]||(t[36]=n("div",{role:"columnheader",class:"num",title:"Repositories discovered on the user's GitHub account"},"GitHub repos",-1)),n("div",GD,[n("button",{type:"button",class:P(["sortable",{active:e.query?.sort=="status"}]),onClick:t[11]||(t[11]=o=>e.sortBy("status"))},[t[35]||(t[35]=g("Status ",-1)),e.sortIcon("status")?(a(),l("svg",{key:0,class:P(["ui-icon sort-direction",{ascending:e.sortIcon("status")==="fa-arrow-up"}]),"aria-hidden":"true"},[...t[34]||(t[34]=[n("use",{href:"#project-icon-arrow"},null,-1)])],2)):f("v-if",!0)],2)]),t[37]||(t[37]=n("div",{role:"columnheader"},"Role",-1)),t[38]||(t[38]=n("div",{role:"columnheader","aria-label":"Actions"},null,-1))]),(a(!0),l(q,null,Q(e.filteredUsers,(o,r)=>(a(),l("div",{class:P(["paper-table-row admin-users-row",{"row-selected":e.selected[o?.username]}]),role:"row"},[n("div",WD,[T(n("input",KD,null,512),[[s,{state:e.viewState,set:d=>{e.selected[o.username]=d},value:e.selected[o?.username],form:null,options:{}}]])]),n("div",YD,[o?.photo?(a(),l("img",{key:0,width:"28",height:"28",class:"rounded-circle",style:{"flex-shrink":"0"},src:e.safeUrl(o?.photo)},null,8,XD)):(a(),l("span",JD,c((o?.username||"?").charAt(0).toUpperCase()),1)),n("div",QD,[n("span",ZD,[n("a",{class:"repo-name",textContent:c(o?.username),href:e.safeUrl("/admin/users/"+o?.username)},null,8,xD),n("a",{class:"user-gh-link",target:"_blank",rel:"noopener",href:e.safeUrl("https://github.com/"+o?.username),title:o?.username+" on GitHub","aria-label":o?.username+" on GitHub"},[...t[39]||(t[39]=[n("i",{class:"fab fa-github","aria-hidden":"true"},null,-1)])],8,eA)]),n("div",tA,[o?.emails?.[0]?.email?(a(),l("span",{key:0,class:"meta-email meta-tail",title:o?.emails?.[0]?.email},c(o?.emails?.[0]?.email),9,nA)):f("v-if",!0),o?.dateOfEntry?(a(),l("span",sA,"Joined "+c(e.fmt?.humanTime(o?.dateOfEntry)),1)):f("v-if",!0)])])]),n("div",oA,[t[40]||(t[40]=n("svg",{class:"ui-icon mobile-meta-icon","aria-hidden":"true"},[n("use",{href:"#project-type-repo"})],-1)),n("a",{title:o?.repoCount?"Show this user\u2019s repositories":"Repositories not synced yet",textContent:c(o?.repoCount?e.fmt?.number(o.repoCount):"Not synced"),class:P({"is-unsynced":!o?.repoCount}),href:e.safeUrl("/admin/repositories?owner="+o?.username)},null,10,iA)]),n("div",rA,[n("span",{class:P(["status-dot","st-"+(o?.status||"unknown")])},null,2),n("span",{textContent:c(e.fmt?.title(o?.status))},null,8,aA)]),n("div",lA,[o?.isAdmin?(a(),l("span",dA,"Admin")):f("v-if",!0),o?.isAdmin?f("v-if",!0):(a(),l("span",uA,"\u2014"))]),n("div",cA,[n("div",pA,[t[46]||(t[46]=n("button",{class:"btn btn-icon-dots",type:"button","data-toggle":"dropdown","aria-haspopup":"true","aria-expanded":"false","aria-label":"Actions"},[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#project-icon-more"})])],-1)),n("div",fA,[n("a",{class:"dropdown-item",href:e.safeUrl("/admin/users/"+o?.username)},[...t[41]||(t[41]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#project-icon-eye"})],-1),g(" View details",-1)])],8,mA),n("a",{class:"dropdown-item",href:e.safeUrl("/admin/repositories?owner="+o?.username)},[...t[42]||(t[42]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#project-type-repo"})],-1),g(" View repositories",-1)])],8,hA),t[45]||(t[45]=n("div",{class:"dropdown-divider"},null,-1)),T(n("a",{class:"dropdown-item text-danger",href:"#",onClick:ae(d=>e.banUser(o),["prevent"])},[...t[43]||(t[43]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-ban"})],-1),g(" Ban",-1)])],8,gA),[[Z,o?.status=="active"]]),T(n("a",{class:"dropdown-item",href:"#",onClick:ae(d=>e.activateUser(o),["prevent"])},[...t[44]||(t[44]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-check-circle"})],-1),g(" Activate",-1)])],8,vA),[[Z,o?.status=="removed"||o?.status=="banned"]])])])])],2))),256)),e.filteredUsers?.length==0?(a(),l("div",yA,[...t[47]||(t[47]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#project-icon-inbox"})],-1),n("span",null,"No users match the current filters.",-1)])])):f("v-if",!0)]),n("div",bA,[t[52]||(t[52]=n("span",{"aria-hidden":"true"},null,-1)),e.totalPage>1?(a(),l("div",wA,[n("button",{class:"btn btn-sm",onClick:t[12]||(t[12]=o=>e.query.page=Math.max(1,e.query.page-1)),disabled:e.query?.page<=1},[...t[48]||(t[48]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-chevron-left"})],-1),g(" Previous",-1)])],8,kA),T(n("input",{type:"number",class:"form-control form-control-sm",min:"1",style:{width:"56px"},max:e.totalPage},null,8,CA),[[s,{state:e.viewState,set:o=>{e.query.page=o},value:e.query?.page,form:null,options:{}}]]),n("span",null,"of "+c(e.totalPage),1),n("button",{class:"btn btn-sm",onClick:t[13]||(t[13]=o=>e.query.page=Math.min(e.totalPage,e.query.page+1)),disabled:e.query?.page>=e.totalPage},[...t[49]||(t[49]=[g("Next ",-1),n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-chevron-right"})],-1)])],8,EA)])):f("v-if",!0),n("span",SA,[t[51]||(t[51]=n("label",null,"Per page",-1)),T((a(),l("select",NA,[...t[50]||(t[50]=[n("option",{value:"10"},"10",-1),n("option",{value:"25"},"25",-1),n("option",{value:"50"},"50",-1),n("option",{value:"100"},"100",-1)])])),[[s,{state:e.viewState,set:o=>{e.query.limit=o},value:e.query?.limit,form:null,options:{}}]])])])])}var RA={class:"anonymize-landing"},PA={class:"anonymize-landing-inner"},DA={class:"form-group mt-4 mb-2"},AA={class:"source-url-label-row"},TA={key:0,class:"repo-access","aria-label":"GitHub access"},OA={key:0,class:"repo-access-switch",role:"group","aria-label":"Repository connection"},IA=["aria-pressed","disabled"],MA=["aria-pressed","disabled"],VA={key:1,class:"connection-badge"},qA={class:"landing-url-row"},_A={id:"sourceUrl-landing",onblur:"this.scrollLeft=0",type:"text",class:"form-control form-control-lg",placeholder:"https://github.com/owner/repository"},LA=["aria-disabled"],$A={key:0,class:"text-danger",role:"alert"},FA={class:"repo-picker","aria-labelledby":"repo-picker-title"},UA={class:"repo-picker-head"},BA={class:"repo-picker-title"},zA={key:0,class:"repo-picker-count","aria-live":"polite"},HA={key:0,class:"repo-picker-list","aria-busy":"true","aria-label":"Loading your repositories"},jA={class:"repo-picker-row is-skeleton","aria-hidden":"true"},GA={key:1,class:"repo-picker-list"},WA=["title"],KA={class:"repo-picker-owner"},YA={class:"repo-picker-repo"},XA=["onClick","aria-label"],JA={key:2,class:"repo-picker-state"},QA={key:3,class:"repo-picker-state"},ZA={key:4,class:"repo-picker-state",role:"alert"},xA={key:5,class:"repo-access-details","aria-label":"GitHub access"},eT={class:"repo-access-main"},tT={class:"repo-access-controls"},nT={key:0,class:"access-q"},sT={key:2,class:"connection-link",href:"/connections"},oT={class:"repo-access-note"},iT={key:0},rT={class:"anonymize-workspace"},aT={class:"anonymize-topbar"},lT={class:"anonymize-topbar-inner"},dT={class:"paper-crumbs"},uT={class:"here"},cT={class:"anonymize-topbar-head"},pT={class:"paper-page-title anonymize-topbar-title"},fT={key:0},mT={key:1},hT={class:"paper-page-lede anonymize-topbar-lede"},gT={key:0,class:"task-trail flow-trail","aria-label":"Anonymization steps"},vT={key:0,class:"alert alert-info",role:"status"},yT={key:1,class:"alert alert-info",role:"status"},bT={key:1},wT={class:"anonymize-mobile-tabs",role:"tablist","aria-label":"Anonymization workspace"},kT=["aria-selected","tabindex"],CT=["aria-selected","tabindex"],ET={class:"anonymize-split"},ST=["role","aria-labelledby"],NT={class:"form needs-validation paper-settings-main",name:"anonymize",novalidate:""},RT={class:"anonymize-fields"},PT={class:"paper-settings-section"},DT={class:"form-group"},AT={class:"source-url-label-row"},TT={key:0,class:"repo-access","aria-label":"GitHub access"},OT={key:0,class:"repo-access-switch",role:"group","aria-label":"Repository connection"},IT=["aria-pressed","disabled"],MT=["aria-pressed","disabled"],VT={key:1,class:"connection-badge"},qT=["disabled"],_T={key:0,class:"source-summary"},LT={class:"invalid-feedback"},$T={class:"invalid-feedback"},FT={class:"invalid-feedback"},UT={class:"invalid-feedback"},BT={key:0,class:"repo-access-details","aria-label":"Previous repository configuration"},zT={key:0,class:"form-group"},HT=["value"],jT={key:1},GT={class:"repo-access-controls"},WT=["href"],KT={key:1,class:"repo-access-details","aria-label":"GitHub access"},YT={class:"repo-access-main"},XT={class:"repo-access-controls"},JT={key:0,class:"access-q"},QT={key:2,class:"connection-link",href:"/connections"},ZT={class:"repo-access-note"},xT={key:0},e3={key:1},t3=["open"],n3={key:0,class:"repair-step"},s3=["disabled"],o3={key:0,role:"status"},i3={class:"repair-step"},r3={key:0,role:"status"},a3={key:3,class:"form-grid-2"},l3={class:"form-group"},d3={class:"input-group"},u3={class:"form-control",id:"branch",name:"branch"},c3=["textContent","value"],p3={class:"input-group-append"},f3={class:"form-group"},m3=["disabled"],h3={class:"invalid-feedback"},g3={class:"invalid-feedback"},v3={class:"form-check-input",type:"checkbox",id:"update",name:"update","aria-describedby":"update-help"},y3={class:"form-check-label",for:"update"},b3={key:0,class:"paid-tag"},w3={key:0,class:"form-text text-muted",id:"update-help"},k3={key:1,class:"form-text text-muted auto-update-paid",id:"update-help"},C3={class:"paper-settings-section"},E3={class:"form-group"},S3=["disabled"],N3={class:"form-text text-muted anon-url-echo"},R3={class:"anon-url-id"},P3={class:"invalid-feedback"},D3={class:"form-group"},A3=["disabled"],T3={class:"form-text text-muted anon-url-echo"},O3={class:"anon-url-id"},I3={class:"invalid-feedback"},M3={class:"form-group"},V3=["disabled"],q3={class:"form-text text-muted anon-url-echo"},_3={class:"anon-url-id"},L3={class:"invalid-feedback"},$3={class:"form-group"},F3=["rows"],U3={class:"redaction-syntax"},B3={class:"form-text text-muted"},z3=["onClick"],H3={key:0,class:"term-hint-more"},j3={class:"invalid-feedback"},G3={class:"preserve-row"},W3={class:"preserve-row-text"},K3={class:"preserve-row-value"},Y3=["disabled"],X3={class:"preserve-tree"},J3={key:0,class:"preserve-status"},Q3={key:1,class:"paper-inline-alert paper-inline-alert-error",role:"alert"},Z3=["aria-expanded","aria-label","onClick"],x3={key:1,class:"preserve-caret-space"},eO=["id","aria-label","checked",".indeterminate","disabled","onChange"],tO=["for","onClick"],nO={key:2,class:"preserve-note"},sO={key:0,class:"preserve-status"},oO={key:0,class:"preserve-status"},iO=["open"],rO={class:"preserve-foot"},aO={class:"preserve-count","aria-live":"polite"},lO={class:"preserve-actions"},dO={class:"paper-settings-section"},uO={class:"form-check"},cO={class:"form-check-input",type:"checkbox",id:"link",name:"link"},pO={class:"form-check"},fO={class:"form-check-input",type:"checkbox",id:"image",name:"image"},mO={class:"form-check"},hO={class:"form-check-input",type:"checkbox",id:"pdf",name:"pdf"},gO={class:"form-check"},vO={class:"form-check-input",type:"checkbox",id:"notebook",name:"notebook"},yO={class:"form-check"},bO=["disabled"],wO={key:0,class:"form-text text-muted"},kO={key:1,class:"form-text text-muted"},CO={key:0,class:"form-text text-muted"},EO={class:"form-check"},SO={class:"form-check-input",type:"checkbox",id:"title-gist",name:"title-gist"},NO={class:"form-check"},RO={class:"form-check-input",type:"checkbox",id:"content-gist",name:"content-gist"},PO={class:"form-check"},DO={class:"form-check-input",type:"checkbox",id:"comments-gist",name:"comments-gist"},AO={class:"form-check"},TO={class:"form-check-input",type:"checkbox",id:"username-gist",name:"username-gist"},OO={class:"form-check"},IO={class:"form-check-input",type:"checkbox",id:"date-gist",name:"date-gist"},MO={class:"form-check"},VO={class:"form-check-input",type:"checkbox",id:"origin-gist",name:"origin-gist"},qO={class:"form-check"},_O={class:"form-check-input",type:"checkbox",id:"title",name:"title"},LO={class:"form-check"},$O={class:"form-check-input",type:"checkbox",id:"body",name:"body"},FO={class:"form-check"},UO={class:"form-check-input",type:"checkbox",id:"diff",name:"diff"},BO={class:"form-check"},zO={class:"form-check-input",type:"checkbox",id:"comments",name:"comments"},HO={class:"form-check"},jO={class:"form-check-input",type:"checkbox",id:"username",name:"username"},GO={class:"form-check"},WO={class:"form-check-input",type:"checkbox",id:"date",name:"date"},KO={class:"form-check"},YO={class:"form-check-input",type:"checkbox",id:"origin",name:"origin"},XO={class:"paper-settings-section hosting-settings",id:"repository-hosting","aria-labelledby":"hosting-heading"},JO={class:"form-group conference-field"},QO=["href"],ZO={class:"invalid-feedback"},xO={class:"form-text text-muted"},eI={key:0,class:"hosting-usage"},tI={key:0},nI={key:1},sI={key:2},oI={key:1,class:"hosting-limit auto-update-note",role:"status"},iI={key:2,class:"hosting-payment"},rI={key:0,class:"hosting-limit",role:"status"},aI={key:1,class:"hosting-options"},lI={class:"hosting-options-title"},dI=["value","checked","onChange"],uI={class:"hosting-option-body"},cI={key:0,class:"hosting-cycle billing-toggle",role:"radiogroup","aria-label":"Billing frequency"},pI=["aria-checked","onClick"],fI={key:0,class:"billing-toggle-save"},mI={class:"hosting-option-price"},hI={key:2,role:"status"},gI={key:3,class:"hosting-terms"},vI={key:4,class:"hosting-terms"},yI={key:5,class:"capacity-options"},bI=["disabled"],wI={key:3,class:"hosting-subhead"},kI={class:"expiration-choices"},CI={class:"expiration-choice"},EI=["checked","disabled"],SI={key:0,class:"dated-options"},NI={key:0,class:"hosting-date"},RI=["min","max"],PI={key:0,class:"date-echo","aria-live":"polite"},DI={class:"invalid-feedback"},AI={class:"invalid-feedback"},TI={class:"hosting-property"},OI={key:1,class:"expiration-choice"},II=["checked","disabled"],MI={key:0},VI={key:4,class:"form-text text-muted"},qI={key:5,class:"inline-hosting"},_I={key:0,role:"alert",class:"text-danger"},LI={key:1,role:"alert",class:"text-danger"},$I=["disabled"],FI={key:2,role:"status"},UI={key:3,role:"status",class:"form-text text-muted"},BI={key:4,class:"hosting-terms"},zI={key:5,class:"hosting-terms"},HI={key:6,class:"repository-pass"},jI=["disabled","onClick"],GI={class:"paper-settings-section"},WI={class:"form-group"},KI={style:{position:"relative"}},YI={type:"text",id:"coauthorSearch",class:"form-control",placeholder:"Search GitHub username\u2026",autocomplete:"off"},XI={class:"dropdown-menu show",style:{display:"block","max-height":"220px","overflow-y":"auto",width:"100%"}},JI=["onClick"],QI=["src"],ZI=["textContent"],xI=["textContent"],e5={class:"coauthor-list"},t5={class:"coauthor-row d-flex align-items-center",style:{padding:"6px 0",gap:"8px"}},n5=["src"],s5=["textContent","href"],o5=["onClick"],i5={class:"form-text text-muted"},r5=["textContent"],a5={class:"anonymize-submit-bar"},l5=["disabled"],d5=["disabled"],u5=["disabled"],c5=["disabled"],p5=["disabled"],f5=["disabled"],m5={key:5,class:"submit-reason",role:"status"},h5={key:6,class:"submit-reason",role:"status"},g5={key:7,class:"checkout-return-note"},v5={key:8,class:"draft-status",role:"status"},y5={key:9,class:"draft-status"},b5=["role","aria-labelledby"],w5={class:"rp-caption"},k5=["aria-expanded"],C5=["title"],E5={class:"redact-slot","aria-hidden":"true"},S5={key:2,class:"rp-count rp-count-none"},N5=["href"],R5=["aria-pressed"],P5={class:"rp-open-icon",viewBox:"0 0 16 16","aria-hidden":"true"},D5={key:0,d:"M9.5 2.5h4v4M13.5 2.5 9 7M6.5 13.5h-4v-4M2.5 13.5 7 9"},A5={key:1,d:"M13.5 6.5h-4v-4M9.5 6.5 14 2M2.5 9.5h4v4M6.5 9.5 2 14"},T5={class:"rp-window"},O5={class:"rp-chrome","aria-hidden":"true"},I5={class:"rp-url"},M5={class:"rp-bar","aria-hidden":"true"},V5={key:0,class:"rp-bar-id"},q5={key:1,class:"rp-bar-kind"},_5={class:"leftCol-head"},L5={class:"leftCol-body"},$5={key:0,class:"rp-state rp-loading",role:"status"},F5={class:"rp-state-text"},U5={class:"rp-state rp-error",role:"alert"},B5={class:"rp-state-actions"},z5={key:1,class:"btn btn-outline-ink btn-sm",href:"/connections"},H5={key:2,class:"rp-state rp-error",role:"alert"},j5={class:"rp-state-actions"},G5={class:"rp-state rp-error",role:"alert"},W5={class:"rp-state-actions"},K5={class:"rp-state rp-error",role:"alert"},Y5={class:"rp-state-actions"},X5={key:5,class:"rp-state rp-empty"},J5={key:7,class:"anonymize-preview-body"},Q5={class:"d-flex w-100 justify-content-between align-items-center flex-wrap"},Z5={class:"pr-title mb-1"},x5={key:0},e8=["textContent"],t8={key:0},n8={key:1},s8={key:2},o8={class:"pr-comments mt-3"},i8={class:"pr-comment"},r8={class:"pr-comment-head"},a8=["textContent"],l8={key:0,class:"pr-comment-date"},d8={key:3},u8={class:"pr-comments"},c8={class:"pr-comment"},p8={class:"pr-comment-head"},f8={key:0,class:"pr-comment-author"},m8=["textContent"],h8=["textContent"],g8={key:0,class:"pr-comment-body"},v8={key:8,class:"anonymize-preview-body"},y8={class:"d-flex w-100 justify-content-between align-items-center flex-wrap"},b8={class:"pr-title mb-1"},w8={key:0},k8=["textContent"],C8={key:0},E8={key:1,class:"pr-body"},S8={key:2,class:"paper-tabs",role:"tablist"},N8=["aria-selected","tabindex"],R8=["aria-selected","tabindex"],P8=["textContent"],D8={key:3,class:"anonymize-preview-status"},A8={class:"paper-tab-content"},T8={key:0,role:"tabpanel",id:"preview-pr-diff-panel","aria-labelledby":"preview-pr-diff-tab"},O8=["innerHTML"],I8={key:1,role:"tabpanel",id:"preview-pr-comments-panel","aria-labelledby":"preview-pr-comments-tab"},M8={class:"pr-comments"},V8={class:"pr-comment"},q8={class:"pr-comment-head"},_8={key:0,class:"pr-comment-author"},L8=["textContent"],$8=["textContent"],F8={key:0,class:"pr-comment-body"},U8={key:9,class:"rp-more"},B8=["href"],z8={key:2,class:"rp-more-btn is-hint","aria-hidden":"true"};function ap(e,t){let s=Xe("tree"),i=Xe("partial-view"),o=Xe("gist-file"),r=Xe("markdown"),d=De("field"),p=De("form");return a(),l("div",{class:P(["anonymize-page h-100",{"mobile-preview-active":e.mobilePane==="preview","preview-expanded":e.previewExpanded}])},[f(" ===== STATE 1: No URL \u2014 centered input ===== "),T(n("div",RA,[n("div",PA,[t[70]||(t[70]=Ce('
My work \xA0/\xA0 New anonymization

New anonymization

Paste a repository, pull request, or gist URL, or pick one of your repositories. You\u2019ll choose the terms to redact next.

  1. 1. Repository
  2. 2. Review and hosting
  3. 3. Review link
',2)),n("div",DA,[n("div",AA,[t[61]||(t[61]=n("label",{class:"paper-field-label",for:"sourceUrl-landing"},"Source URL",-1)),!e.sourceUrl&&e.githubConnections?.appEnabled&&e.githubConnections.appConnected&&e.githubConnections.oauthConnected?(a(),l("aside",TA,[!e.isUpdate&&e.detectedType!=="gist"?(a(),l("div",OA,[n("button",{type:"button","aria-pressed":e.githubConnection==="github-app",disabled:e.githubConnection==="github-app",onClick:t[0]||(t[0]=u=>e.chooseGitHubConnection("github-app"))},[...t[60]||(t[60]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-shield"})],-1),g(),n("span",{class:"sr-only"},"Read-only ",-1),g("GitHub App",-1)])],8,IA),n("button",{type:"button","aria-pressed":e.githubConnection==="oauth",disabled:e.githubConnection==="oauth",onClick:t[1]||(t[1]=u=>e.chooseGitHubConnection("oauth"))},"Legacy OAuth",8,MA)])):f("v-if",!0),e.isUpdate||e.detectedType==="gist"?(a(),l("span",VA,c((e.detectedType==="gist"?e.githubConnections?.gistConnection==="github-app":e.githubConnection==="github-app")?"Read-only GitHub App":"Legacy OAuth"),1)):f("v-if",!0)])):f("v-if",!0)]),n("div",qA,[T(n("input",_A,null,512),[[d,{state:e.viewState,set:u=>{e.sourceUrl=u},value:e.sourceUrl,form:null,options:{debounce:{default:1e3,blur:0,click:0},updateOn:"default blur click"},change:()=>{e.urlSelected()}}]]),n("button",{type:"button",class:"btn btn-primary landing-continue","aria-disabled":e.sourceUrl?.trim()?null:"true",onClick:t[2]||(t[2]=u=>e.sourceUrl?.trim()&&e.urlSelected())},"Continue",8,LA)])]),e.sourceUrlError?(a(),l("p",$A,c(e.sourceUrlError),1)):f("v-if",!0),t[71]||(t[71]=n("small",{class:"form-text landing-help",style:{color:"var(--ink-muted)"}}," Repository, pull request (\u2026/pull/42) and gist (gist.github.com/\u2026) URLs are all accepted. ",-1)),n("section",FA,[n("div",UA,[n("div",BA,[t[63]||(t[63]=n("h2",{id:"repo-picker-title"},"Your repositories",-1)),e.userReposStatus==="ready"&&e.userRepos.length>0?(a(),l("span",zA,[e.userRepoFilter&&e.filteredUserRepos().length!==e.userRepos.length?(a(),l(q,{key:0},[g(c(e.filteredUserRepos().length)+" of ",1)],64)):f("v-if",!0),g(c(e.userRepos.length)+" "+c(e.userRepos.length===1?"repository":"repositories"),1),t[62]||(t[62]=n("span",{class:"repo-picker-more"},[n("span",{class:"repo-picker-more-sep"}," \xB7 "),g("scroll for more")],-1))])):f("v-if",!0)]),e.userReposStatus==="ready"&&e.userRepos.length>0?T((a(),l("input",{key:0,type:"search",class:"form-control repo-picker-filter",placeholder:"Filter\u2026","aria-label":"Filter your repositories",autocomplete:"off","onUpdate:modelValue":t[3]||(t[3]=u=>e.userRepoFilter=u)},null,512)),[[rt,e.userRepoFilter]]):f("v-if",!0)]),e.userReposStatus==="loading"||e.userReposStatus==="idle"?(a(),l("ul",HA,[(a(),l(q,null,Q([1,2,3,4],(u,y)=>n("li",jA,[n("span",{class:"skeleton skeleton-line",style:Te({width:34+u*9+"%"})},null,4)])),64))])):f("v-if",!0),e.userReposStatus==="ready"&&e.filteredUserRepos().length>0?(a(),l("ul",GA,[(a(!0),l(q,null,Q(e.filteredUserRepos(),(u,y)=>(a(),l("li",{key:u.id||u.fullName,class:"repo-picker-row"},[t[65]||(t[65]=n("svg",{class:"project-type-svg","aria-hidden":"true"},[n("use",{href:"#project-type-repo"})],-1)),n("span",{class:"repo-picker-name",title:u.fullName},[n("span",KA,[g(c(u.fullName.split("/")[0]),1),t[64]||(t[64]=n("span",{class:"repo-picker-slash"},"/",-1))]),n("span",YA,c(u.fullName.split("/").slice(1).join("/")),1)],8,WA),n("button",{type:"button",class:"btn btn-outline-ink btn-sm repo-picker-select",onClick:h=>e.selectUserRepo(u),"aria-label":"Select "+u.fullName},"Select",8,XA)]))),128))])):f("v-if",!0),e.userReposStatus==="ready"&&e.userRepos.length>0&&e.filteredUserRepos().length===0?(a(),l("p",JA,"No repository matches \u201C"+c(e.userRepoFilter)+"\u201D.",1)):f("v-if",!0),e.userReposStatus==="ready"&&e.userRepos.length===0?(a(),l("p",QA,"No repositories found for your GitHub account. Paste a URL above, or grant access below.")):f("v-if",!0),e.userReposStatus==="error"?(a(),l("p",ZA,[t[66]||(t[66]=g("Your repositories could not be loaded. ",-1)),n("button",{type:"button",class:"task-text-button",onClick:t[4]||(t[4]=u=>e.loadUserRepos(!0))},"Try again")])):f("v-if",!0),!e.sourceUrl&&e.githubConnections?.appEnabled&&e.githubConnections.appConnected?(a(),l("aside",xA,[n("div",eT,[n("div",tT,[e.detectedType!=="gist"&&e.githubConnection!=="oauth"?(a(),l("span",nT,"Repository not listed?")):f("v-if",!0),e.detectedType!=="gist"&&e.githubConnection!=="oauth"?(a(),l("button",{key:1,type:"button",class:"btn btn-outline-ink",onClick:t[5]||(t[5]=u=>e.grantGitHubAccess())},[...t[67]||(t[67]=[g("Manage GitHub access ",-1),n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-external-link"})],-1)])])):f("v-if",!0),e.isUpdate||e.detectedType==="gist"||e.githubConnection==="oauth"?(a(),l("a",sT,[...t[68]||(t[68]=[g("Manage GitHub access ",-1),n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-external-link"})],-1)])])):f("v-if",!0)])]),n("div",oT,[e.error&&e.detectedType!=="gist"&&e.githubConnection==="github-app"?(a(),l("span",iT,"Signing in does not grant access to private repositories. Use Manage GitHub access to select this repository, then return here. Organization access may require administrator approval.")):f("v-if",!0),t[69]||(t[69]=n("span",null,[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-info"})]),g(" Anonymized content is public, even from private repositories.")],-1))])])):f("v-if",!0)])])],512),[[Z,!e.workspaceOpen&&!e.isUpdate]]),f(" ===== STATE 2: URL provided \u2014 form (left) + preview (right) ===== "),T(n("div",rT,[n("header",aT,[n("div",lT,[n("div",dT,[t[72]||(t[72]=n("a",{href:"/dashboard"},"My work",-1)),t[73]||(t[73]=g(" \xA0/\xA0 ",-1)),n("span",uT,c(e.isUpdate?"Edit anonymization":"New anonymization"),1)]),n("div",cT,[n("h1",pT,[e.isUpdate?f("v-if",!0):(a(),l("span",fT,"New anonymization")),e.isUpdate?(a(),l("span",mT,"Edit anonymization")):f("v-if",!0)]),T(n("span",{class:P(["type-badge",{"type-repo":e.detectedType==="repo","type-pr":e.detectedType==="pr","type-gist":e.detectedType==="gist"}])},c(e.detectedType==="repo"?"Repository":e.detectedType==="pr"?"Pull request":"Gist"),3),[[Z,e.detectedType]])]),n("p",hT,c(e.isUpdate?"Changes apply to the existing anonymous link; reviewers keep the same URL.":"Choose the terms to redact, what reviewers see, and when the link expires."),1),e.isUpdate?f("v-if",!0):(a(),l("ol",gT,[...t[74]||(t[74]=[n("li",null,"1. Repository",-1),n("li",{"aria-current":"step"},"2. Review and hosting",-1),n("li",null,"3. Review link",-1)])]))])]),e.detectedType==="gist"&&e.gistAppRequired?(a(),l("aside",vT,[t[75]||(t[75]=n("p",null,"Reconnect your GitHub account to read this gist. Your draft will be restored when you return.",-1)),n("button",{type:"button",class:"btn btn-ink",onClick:t[6]||(t[6]=u=>e.connectGistApp())},"Connect GitHub App to access gists")])):f("v-if",!0),e.detectedType==="gist"&&e.gistOAuthRequired?(a(),l("aside",yT,[t[76]||(t[76]=n("p",null,"Connect GitHub OAuth to access gists. Your account and existing anonymizations stay the same, and your draft will be restored when you return.",-1)),t[77]||(t[77]=n("p",null,"GitHub's legacy OAuth connection includes write access to private repositories.",-1)),e.githubConnections?.oauthEnabled?(a(),l("button",{key:0,type:"button",class:"btn btn-ink",onClick:t[7]||(t[7]=u=>e.connectGistOAuth())},"Connect GitHub OAuth to access gists")):(a(),l("p",bT,"GitHub OAuth is currently unavailable. Please try again later."))])):f("v-if",!0),n("nav",wT,[n("button",{id:"workspace-settings-tab",role:"tab",type:"button","aria-selected":e.mobilePane==="settings","aria-controls":"workspace-settings",tabindex:e.mobilePane==="settings"?0:-1,onKeydown:t[8]||(t[8]=u=>e.previewTabKeydown(u)),onClick:t[9]||(t[9]=u=>e.selectMobilePane("settings"))},[...t[78]||(t[78]=[n("span",{class:"tab-label"},"Settings",-1)])],40,kT),n("button",{id:"workspace-preview-tab",role:"tab",type:"button","aria-selected":e.mobilePane==="preview","aria-controls":"workspace-preview",tabindex:e.mobilePane==="preview"?0:-1,onKeydown:t[10]||(t[10]=u=>e.previewTabKeydown(u)),onClick:t[11]||(t[11]=u=>e.selectMobilePane("preview"))},[...t[79]||(t[79]=[n("span",{class:"tab-label"},"Reviewer preview",-1)])],40,CT)]),n("div",ET,[f(" Form column (left) "),n("div",{id:"workspace-settings",role:e.mobileWorkspace?"tabpanel":null,"aria-labelledby":e.mobileWorkspace?"workspace-settings-tab":null,class:"anonymize-form-col overflow-auto"},[T((a(),l("form",NT,[n("div",RT,[n("section",PT,[t[99]||(t[99]=n("h2",{class:"paper-section-eyebrow"},"Source & access",-1)),n("div",DT,[n("div",AT,[t[81]||(t[81]=n("label",{class:"paper-field-label",for:"sourceUrl"},"Source URL",-1)),e.sourceUrl&&e.githubConnections?.appEnabled&&e.githubConnections.appConnected&&e.githubConnections.oauthConnected?(a(),l("aside",TT,[!e.isUpdate&&e.detectedType!=="gist"?(a(),l("div",OT,[n("button",{type:"button","aria-pressed":e.githubConnection==="github-app",disabled:e.githubConnection==="github-app",onClick:t[12]||(t[12]=u=>e.chooseGitHubConnection("github-app"))},[...t[80]||(t[80]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-shield"})],-1),g(),n("span",{class:"sr-only"},"Read-only ",-1),g("GitHub App",-1)])],8,IT),n("button",{type:"button","aria-pressed":e.githubConnection==="oauth",disabled:e.githubConnection==="oauth",onClick:t[13]||(t[13]=u=>e.chooseGitHubConnection("oauth"))},"Legacy OAuth",8,MT)])):f("v-if",!0),e.isUpdate||e.detectedType==="gist"?(a(),l("span",VT,c((e.detectedType==="gist"?e.githubConnections?.gistConnection==="github-app":e.githubConnection==="github-app")?"Read-only GitHub App":"Legacy OAuth"),1)):f("v-if",!0)])):f("v-if",!0)]),T(n("input",{type:"text",class:P(["form-control",{"is-invalid":e.anonymize?.sourceUrl?.invalid}]),name:"sourceUrl",id:"sourceUrl",onblur:"this.scrollLeft=0",disabled:e.isUpdate&&e.detectedType!=="repo",placeholder:"Paste a GitHub repo or pull request URL"},null,10,qT),[[d,{state:e.viewState,set:u=>{e.sourceUrl=u},value:e.sourceUrl,form:"anonymize",options:{debounce:{default:1e3,blur:0,click:0},updateOn:"default blur click"},change:()=>{e.urlSelected()}}]]),e.sourceSummary()&&!e.anonymize?.sourceUrl?.invalid?(a(),l("p",_T,[t[82]||(t[82]=n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-check"})],-1)),g(c(e.sourceSummary()),1)])):f("v-if",!0),T(n("div",LT," Please provide a valid GitHub URL. ",512),[[Z,e.anonymize?.sourceUrl?.errors?.github]]),T(n("div",$T," Not accessible. The organization may restrict access. ",512),[[Z,e.anonymize?.sourceUrl?.errors?.access]]),T(n("div",FT," Does not exist or is not accessible. ",512),[[Z,e.anonymize?.sourceUrl?.errors?.missing]]),T(n("div",UT," Already anonymized. ",512),[[Z,e.anonymize?.sourceUrl?.errors?.used]])]),!e.isUpdate&&e.previousConfigurations.length?(a(),l("aside",BT,[t[84]||(t[84]=n("p",{role:"status"},"You have already anonymized this repository. Use the existing configuration to keep its anonymous link and avoid creating another repository.",-1)),e.previousConfigurations.length>1?(a(),l("div",zT,[t[83]||(t[83]=n("label",{class:"paper-field-label",for:"previousConfiguration"},"Previous anonymization",-1)),T(n("select",{id:"previousConfiguration",class:"form-control","onUpdate:modelValue":t[14]||(t[14]=u=>e.previousConfigurationId=u)},[(a(!0),l(q,null,Q(e.previousConfigurations,u=>(a(),l("option",{key:u.repoId,value:u.repoId},c(u.repoId),9,HT))),128))],512),[[Wt,e.previousConfigurationId]])])):(a(),l("p",jT,c(e.previousConfigurationId),1)),t[85]||(t[85]=n("p",null,"You can review and update its settings before saving.",-1)),n("div",GT,[n("a",{class:"btn btn-ink",href:e.existingConfigurationUrl()},"Use existing configuration",8,WT),n("button",{type:"button",class:"btn btn-outline-ink",onClick:t[15]||(t[15]=u=>e.previousConfigurations=[])},"Create a separate one")])])):f("v-if",!0),e.sourceUrl&&e.githubConnections?.appEnabled&&e.githubConnections.appConnected?(a(),l("aside",KT,[n("div",YT,[n("div",XT,[e.detectedType!=="gist"&&e.githubConnection!=="oauth"&&!e.details?(a(),l("span",JT,"Repository not listed?")):f("v-if",!0),e.detectedType!=="gist"&&e.githubConnection!=="oauth"&&!e.details?(a(),l("button",{key:1,type:"button",class:"btn btn-outline-ink",onClick:t[16]||(t[16]=u=>e.grantGitHubAccess())},[...t[86]||(t[86]=[g("Manage GitHub access ",-1),n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-external-link"})],-1)])])):f("v-if",!0),e.isUpdate||e.detectedType==="gist"||e.githubConnection==="oauth"?(a(),l("a",QT,[...t[87]||(t[87]=[g("Manage GitHub access ",-1),n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-external-link"})],-1)])])):f("v-if",!0)])]),n("div",ZT,[e.error&&e.detectedType!=="gist"&&e.githubConnection==="github-app"?(a(),l("span",xT,"Signing in does not grant access to private repositories. Use Manage GitHub access to select this repository, then return here. Organization access may require administrator approval.")):f("v-if",!0),e.detectedType!=="gist"&&e.githubConnection!=="oauth"&&!e.details?(a(),l("span",e3,"Select repositories on GitHub, then return here.")):f("v-if",!0),t[88]||(t[88]=n("span",null,[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-info"})]),g(" Selected content will be published, including content from private repositories.")],-1))])])):f("v-if",!0),e.isUpdate&&e.detectedType==="repo"&&e.role==="owner"&&e.sourceUrl==="https://github.com/"+e._originalFullName?(a(),l("details",{key:2,class:"repair-disclosure",open:!!(e.error||e.accessRepairMessage||e.reconnectRepositoryId)},[t[92]||(t[92]=n("summary",null,"Connection problems?",-1)),e.accessRepairAllowed&&e.githubConnections?.appEnabled&&e.githubConnection==="github-app"&&e.sourceUrl==="https://github.com/"+e._originalFullName?(a(),l("div",n3,[t[90]||(t[90]=n("p",null,"If this repository became private or its App installation changed, repair its access here. This keeps the same anonymous URL and published commit.",-1)),n("button",{type:"button",class:"btn btn-outline-ink",disabled:e.repairingGitHubAccess,onClick:t[17]||(t[17]=u=>e.repairGitHubAccess())},"Repair GitHub access",8,s3),n("button",{type:"button",class:"btn btn-outline-ink",onClick:t[18]||(t[18]=u=>e.grantGitHubAccess())},[...t[89]||(t[89]=[g("Manage GitHub access ",-1),n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-external-link"})],-1)])]),e.accessRepairMessage?(a(),l("p",o3,c(e.accessRepairMessage),1)):f("v-if",!0)])):f("v-if",!0),n("div",i3,[t[91]||(t[91]=n("p",null,"If you deleted and recreated this repository, reconnect it before choosing a branch.",-1)),n("button",{type:"button",class:"btn btn-outline-ink",onClick:t[19]||(t[19]=u=>e.reconnectSource())},"Reconnect source repository"),e.reconnectRepositoryId?(a(),l("p",r3,"Source reloaded. Review the branch, commit, and anonymization preview, then save to replace the published snapshot.")):f("v-if",!0)])],8,t3)):f("v-if",!0),e.detectedType==="repo"?(a(),l("div",a3,[n("div",l3,[t[94]||(t[94]=n("label",{class:"paper-field-label",for:"branch"},"Branch",-1)),n("div",d3,[T((a(),l("select",u3,[(a(!0),l(q,null,Q(e.branches,(u,y)=>(a(),l("option",{textContent:c(u?.name),value:u?.name},null,8,c3))),256))])),[[d,{state:e.viewState,set:u=>{e.source.branch=u},value:e.source?.branch,form:"anonymize",options:{}}]]),n("div",p3,[n("button",{class:"btn btn-icon refresh-branches",type:"button",title:"Refresh branches",onClick:t[20]||(t[20]=u=>e.getBranches(!0)),"aria-label":"Refresh branches"},[...t[93]||(t[93]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-refresh"})],-1)])])])])]),n("div",f3,[t[95]||(t[95]=n("label",{class:"paper-field-label",for:"commit"},"Commit",-1)),T(n("input",{class:P(["form-control",{"is-invalid":e.anonymize?.commit?.invalid}]),id:"commit",disabled:e.options.update,name:"commit",pattern:"[a-fA-Z0-9]{6,}",required:""},null,10,m3),[[d,{state:e.viewState,set:u=>{e.source.commit=u},value:e.source?.commit,form:"anonymize",options:{}}]]),T(n("div",h3," The commit SHA is not valid. ",512),[[Z,e.anonymize?.commit?.errors?.pattern||e.anonymize?.commit?.errors?.required]]),T(n("div",g3," This commit no longer exists in the repository. Click refresh to get the latest. ",512),[[Z,e.anonymize?.commit?.errors?.exists]])])])):f("v-if",!0),T(n("div",{class:P(["form-check auto-update-check",{"is-paid":!e.liveUpdatesIncluded()}])},[T(n("input",v3,null,512),[[d,{state:e.viewState,set:u=>{e.options.update=u},value:e.options?.update,form:"anonymize",options:{}}]]),n("label",y3,[t[96]||(t[96]=g("Auto-update from GitHub",-1)),e.liveUpdatesIncluded()?f("v-if",!0):(a(),l("span",b3,"Paid"))]),e.liveUpdatesIncluded()?(a(),l("small",w3,"Follows the latest version, at most once an hour.")):(a(),l("small",k3,[t[97]||(t[97]=g("Needs Live updates",-1)),e.liveUpdatesPrice()?(a(),l(q,{key:0},[g(" \xB7 "+c(e.liveUpdatesPrice()),1)],64)):f("v-if",!0),t[98]||(t[98]=g(", a Paper pack or an author subscription. ",-1)),n("a",{href:"#repository-hosting",onClick:t[21]||(t[21]=ae(u=>e.showHostingOptions(),["prevent"]))},"Hosting options")]))],2),[[Z,e.detectedType]])]),T(n("section",C3,[t[133]||(t[133]=n("h2",{class:"paper-section-eyebrow"},"Anonymization",-1)),T(n("div",E3,[t[104]||(t[104]=n("label",{class:"paper-field-label",for:"repoId"},"Anonymized repository ID",-1)),T(n("input",{type:"text",class:P(["form-control",{"is-invalid":e.anonymize?.repoId?.invalid}]),name:"repoId",id:"repoId",disabled:e.isUpdate},null,10,S3),[[d,{state:e.viewState,set:u=>{e.repoId=u},value:e.repoId,form:"anonymize",options:{debounce:{default:1e3,blur:0,click:0},updateOn:"default blur click"}}]]),n("small",N3,[t[100]||(t[100]=g("anonymous.4open.science/",-1)),t[101]||(t[101]=n("wbr",null,null,-1)),t[102]||(t[102]=g("r/",-1)),t[103]||(t[103]=n("wbr",null,null,-1)),n("span",R3,c(e.repoId),1)]),T(n("div",P3,"ID can only contain letters and numbers.",512),[[Z,e.anonymize?.repoId?.errors?.format]]),T(n("div",{class:"invalid-feedback"},c(e.repoId)+" is already used.",513),[[Z,e.anonymize?.repoId?.errors?.used]])],512),[[Z,e.detectedType==="repo"]]),T(n("div",D3,[t[109]||(t[109]=n("label",{class:"paper-field-label",for:"pullRequestId"},"Anonymized pull request ID",-1)),T(n("input",{type:"text",class:P(["form-control",{"is-invalid":e.anonymize?.pullRequestId?.invalid}]),name:"pullRequestId",id:"pullRequestId",disabled:e.isUpdate},null,10,A3),[[d,{state:e.viewState,set:u=>{e.pullRequestId=u},value:e.pullRequestId,form:"anonymize",options:{debounce:{default:1e3,blur:0,click:0},updateOn:"default blur click"}}]]),n("small",T3,[t[105]||(t[105]=g("anonymous.4open.science/",-1)),t[106]||(t[106]=n("wbr",null,null,-1)),t[107]||(t[107]=g("pr/",-1)),t[108]||(t[108]=n("wbr",null,null,-1)),n("span",O3,c(e.pullRequestId),1)]),T(n("div",I3,"ID can only contain letters and numbers.",512),[[Z,e.anonymize?.pullRequestId?.errors?.format]]),T(n("div",{class:"invalid-feedback"},c(e.pullRequestId)+" is already used.",513),[[Z,e.anonymize?.pullRequestId?.errors?.used]])],512),[[Z,e.detectedType==="pr"]]),T(n("div",M3,[t[114]||(t[114]=n("label",{class:"paper-field-label",for:"gistId"},"Anonymized gist ID",-1)),T(n("input",{type:"text",class:P(["form-control",{"is-invalid":e.anonymize?.gistId?.invalid}]),name:"gistId",id:"gistId",disabled:e.isUpdate},null,10,V3),[[d,{state:e.viewState,set:u=>{e.gistId=u},value:e.gistId,form:"anonymize",options:{debounce:{default:1e3,blur:0,click:0},updateOn:"default blur click"}}]]),n("small",q3,[t[110]||(t[110]=g("anonymous.4open.science/",-1)),t[111]||(t[111]=n("wbr",null,null,-1)),t[112]||(t[112]=g("gist/",-1)),t[113]||(t[113]=n("wbr",null,null,-1)),n("span",_3,c(e.gistId),1)]),T(n("div",L3,"ID can only contain letters and numbers.",512),[[Z,e.anonymize?.gistId?.errors?.format]]),T(n("div",{class:"invalid-feedback"},c(e.gistId)+" is already used.",513),[[Z,e.anonymize?.gistId?.errors?.used]])],512),[[Z,e.detectedType==="gist"]]),n("div",$3,[t[125]||(t[125]=n("label",{class:"paper-field-label",for:"terms"},"Terms to redact",-1)),T(n("textarea",{class:P(["form-control terms-input",{"is-invalid":e.anonymize?.terms?.invalid}]),id:"terms",name:"terms",rows:Math.min(14,Math.max(4,String(e.terms||"").split(` `).length+1)),placeholder:`Jane Smith MIT CSAIL -jane.smith@example.org`},null,10,jT),[[d,{state:e.viewState,set:u=>{e.terms=u},value:e.terms,form:"anonymize",options:{debounce:250}}]]),t[126]||(t[126]=n("small",{class:"form-text text-muted"},"One term per line.",-1)),n("details",GT,[t[121]||(t[121]=n("summary",null,"Regex & replacement syntax",-1)),t[122]||(t[122]=g()),n("small",WT,[t[115]||(t[115]=g("Regex is supported. Replaced by ",-1)),n("code",null,c(e.site_options?.ANONYMIZATION_MASK)+"-[N]",1),t[116]||(t[116]=g(", or use ",-1)),t[117]||(t[117]=n("code",null,"term=>replacement",-1)),t[118]||(t[118]=g(" to pick your own (e.g. ",-1)),t[119]||(t[119]=n("code",null,"Anonymous=>ABC",-1)),t[120]||(t[120]=g(").",-1))])]),(a(!0),l(q,null,Q((e.termHints||[]).slice(0,3),u=>(a(),l("div",{class:"term-hint",key:u.line},[n("span",null,[t[123]||(t[123]=g("In ",-1)),n("code",null,c(u.term),1),t[124]||(t[124]=g(", ",-1)),n("code",null,c(u.symbols.join(" ")),1),g(" "+c(u.symbols.length>1?"are regex symbols":"is a regex symbol")+", so it may not match the text as written.",1)]),n("button",{type:"button",class:"btn btn-outline-ink btn-sm",onClick:y=>e.matchTermAsWritten(u.line)},"Match as written",8,KT)]))),128)),(e.termHints||[]).length>3?(a(),l("div",YT,c(e.termHints.length-3)+" more "+c(e.termHints.length-3===1?"term uses":"terms use")+" regex symbols.",1)):f("v-if",!0),D(n("div",XT,"Terms are in an invalid format.",512),[[Z,e.anonymize?.terms?.errors?.format]])]),D(n("div",JT,[n("div",QT,[t[127]||(t[127]=n("span",{class:"paper-field-label",id:"preserve-files-label"},"Unredacted files",-1)),n("span",ZT,c(e.preserveSummary()),1)]),n("button",{type:"button",class:"btn btn-outline-ink btn-sm","aria-describedby":"preserve-files-label",disabled:!e.source?.commit,onClick:t[22]||(t[22]=u=>e.openPreserveFiles())},c((e.options?.preserveFiles||[]).length?"Edit":"Choose files"),9,xT)],512),[[Z,e.detectedType==="repo"]]),e.preserve?.open?(a(),l("dialog",{key:0,id:"preserve-files-dialog",class:"preserve-dialog","aria-labelledby":"preserve-files-title",onCancel:t[27]||(t[27]=ae(u=>e.closePreserveFiles(),["prevent"]))},[n("form",{onSubmit:t[26]||(t[26]=ae(u=>e.savePreserveFiles(),["prevent"]))},[t[131]||(t[131]=n("h2",{id:"preserve-files-title"},"Leave files unredacted",-1)),t[132]||(t[132]=n("p",{class:"preserve-intro"},"Checked files are shown exactly as written, for example a bibliography where redacted self-citations would reveal you. File names are still redacted.",-1)),D(n("input",{type:"search",id:"preserve-files-search",class:"form-control",placeholder:"Search files","aria-label":"Search files",autocomplete:"off","onUpdate:modelValue":t[23]||(t[23]=u=>e.preserve.search=u)},null,512),[[pt,e.preserve.search]]),n("div",e3,[e.preserve.loading?(a(),l("p",t3,"Loading files from GitHub\u2026")):e.preserve.error?(a(),l("p",n3,c(e.preserve.error),1)):(a(),l(q,{key:2},[(a(!0),l(q,null,Q(e.preserveRows(),(u,y)=>(a(),l("div",{class:"preserve-item",key:u.kind+":"+u.path,style:Ie({paddingLeft:u.depth*18+6+"px"})},[u.kind==="dir"?(a(),l("button",{key:0,type:"button",class:"preserve-caret","aria-expanded":u.open?"true":"false","aria-label":(u.open?"Collapse ":"Expand ")+u.label,onClick:m=>e.togglePreserveDir(u.path)},c(u.open?"\u25BE":"\u25B8"),9,s3)):(a(),l("span",o3)),n("input",{type:"checkbox",id:"pf-"+y,"aria-label":u.kind==="dir"?"Leave folder "+u.path+" unredacted":null,checked:u.state==="all",".indeterminate":u.state==="some",disabled:u.locked,onChange:m=>u.kind==="dir"?e.togglePreserveFolder(u.path):e.togglePreserveFile(u.path)},null,40,i3),n("label",{for:u.kind==="file"?"pf-"+y:null,class:"preserve-name",onClick:m=>u.kind==="dir"&&e.togglePreserveDir(u.path)},c(u.label),9,r3),u.note?(a(),l("span",a3,c(u.note),1)):f("v-if",!0)],4))),128)),!e.preserve.loading&&!e.preserveRows().length?(a(),l("p",l3,c(e.preserve.search?"No file matches your search.":"No text files in this commit."),1)):f("v-if",!0)],64))]),e.preserve.truncated?(a(),l("p",d3,"This repository has too many files to list them all. Use a pattern for files you cannot find.")):f("v-if",!0),n("details",{class:"preserve-patterns",open:e.preserve.patternsOpen},[t[128]||(t[128]=n("summary",null,"Patterns",-1)),D(n("textarea",{class:"form-control",rows:"3","aria-label":"Patterns",placeholder:`*.bib -paper/appendix/**`,"onUpdate:modelValue":t[24]||(t[24]=u=>e.preserve.patterns=u)},null,512),[[pt,e.preserve.patterns]]),t[129]||(t[129]=n("small",{class:"form-text text-muted"},[g("One per line, as in .gitignore: "),n("code",null,"*.bib"),g(" matches in any folder; "),n("code",null,"/refs.bib"),g(" and "),n("code",null,"paper/refs.bib"),g(" match from the repository root; a folder name such as "),n("code",null,"drafts/"),g(" covers everything inside it; "),n("code",null,"!private.bib"),g(" excludes again.")],-1))],8,u3),n("div",c3,[n("span",p3,c(e.preserve.loading||e.preserve.error?"":e.preserveCount()+(e.preserveCount()===1?" file":" files")+" will be shown as written"),1),n("span",f3,[n("button",{type:"button",class:"btn btn-outline-ink",onClick:t[25]||(t[25]=u=>e.closePreserveFiles())},"Cancel"),t[130]||(t[130]=n("button",{type:"submit",class:"btn btn-ink"},"Save",-1))])])],32)],32)):f("v-if",!0)],512),[[Z,e.detectedType]]),D(n("section",h3,[t[153]||(t[153]=n("h2",{class:"paper-section-eyebrow"},"Display",-1)),D(n("div",null,[n("div",m3,[D(n("input",g3,null,512),[[d,{state:e.viewState,set:u=>{e.options.link=u},value:e.options?.link,form:"anonymize",options:{}}]]),t[134]||(t[134]=n("label",{class:"form-check-label",for:"link"},"Keep links",-1))]),n("div",v3,[D(n("input",y3,null,512),[[d,{state:e.viewState,set:u=>{e.options.image=u},value:e.options?.image,form:"anonymize",options:{}}]]),t[135]||(t[135]=n("label",{class:"form-check-label",for:"image"},"Display images",-1))]),n("div",b3,[D(n("input",w3,null,512),[[d,{state:e.viewState,set:u=>{e.options.pdf=u},value:e.options?.pdf,form:"anonymize",options:{}}]]),t[136]||(t[136]=n("label",{class:"form-check-label",for:"pdf"},"Display PDFs",-1))]),n("div",k3,[D(n("input",C3,null,512),[[d,{state:e.viewState,set:u=>{e.options.notebook=u},value:e.options?.notebook,form:"anonymize",options:{}}]]),t[137]||(t[137]=n("label",{class:"form-check-label",for:"notebook"},"Display notebooks",-1))]),n("div",E3,[D(n("input",{class:"form-check-input",type:"checkbox",id:"page",name:"page",disabled:!e.details?.hasPage||e.details?.pageSource&&e.details?.pageSource?.branch!==e.source?.branch},null,8,S3),[[d,{state:e.viewState,set:u=>{e.options.page=u},value:e.options?.page,form:"anonymize",options:{}}]]),t[138]||(t[138]=n("label",{class:"form-check-label",for:"page"},"GitHub Pages",-1)),e.details?.hasPage?f("v-if",!0):(a(),l("small",N3,c(e.fmt?.translate("WARNINGS.page_not_enabled_on_repo")),1)),e.details?.hasPage&&e.details?.pageSource?.branch&&e.source?.branch&&e.details.pageSource.branch!==e.source.branch?(a(),l("small",R3,c(e.fmt?.translate("WARNINGS.page_branch_mismatch",{pageBranch:e.details?.pageSource?.branch,selectedBranch:e.source?.branch})),1)):f("v-if",!0)])],512),[[Z,e.detectedType==="repo"]]),e.detectedType==="repo"&&(e.options.image||e.options.pdf)?(a(),l("p",A3,[...t[139]||(t[139]=[g("Images and PDFs are served unchanged. Review their contents and metadata before sharing. ",-1),n("a",{href:"/faq#formats"},"Supported formats",-1)])])):f("v-if",!0),D(n("div",null,[n("div",P3,[D(n("input",D3,null,512),[[d,{state:e.viewState,set:u=>{e.options.title=u},value:e.options?.title,form:"anonymize",options:{}}]]),t[140]||(t[140]=n("label",{class:"form-check-label",for:"title-gist"},"Gist description",-1))]),n("div",T3,[D(n("input",O3,null,512),[[d,{state:e.viewState,set:u=>{e.options.content=u},value:e.options?.content,form:"anonymize",options:{}}]]),t[141]||(t[141]=n("label",{class:"form-check-label",for:"content-gist"},"File contents",-1))]),n("div",I3,[D(n("input",M3,null,512),[[d,{state:e.viewState,set:u=>{e.options.comments=u},value:e.options?.comments,form:"anonymize",options:{}}]]),t[142]||(t[142]=n("label",{class:"form-check-label",for:"comments-gist"},"Comments",-1))]),n("div",V3,[D(n("input",q3,null,512),[[d,{state:e.viewState,set:u=>{e.options.username=u},value:e.options?.username,form:"anonymize",options:{}}]]),t[143]||(t[143]=n("label",{class:"form-check-label",for:"username-gist"},"Usernames",-1))]),n("div",_3,[D(n("input",L3,null,512),[[d,{state:e.viewState,set:u=>{e.options.date=u},value:e.options?.date,form:"anonymize",options:{}}]]),t[144]||(t[144]=n("label",{class:"form-check-label",for:"date-gist"},"Dates",-1))]),n("div",$3,[D(n("input",F3,null,512),[[d,{state:e.viewState,set:u=>{e.options.origin=u},value:e.options?.origin,form:"anonymize",options:{}}]]),t[145]||(t[145]=n("label",{class:"form-check-label",for:"origin-gist"},"Source gist ID",-1))])],512),[[Z,e.detectedType==="gist"]]),D(n("div",null,[n("div",U3,[D(n("input",B3,null,512),[[d,{state:e.viewState,set:u=>{e.options.title=u},value:e.options?.title,form:"anonymize",options:{}}]]),t[146]||(t[146]=n("label",{class:"form-check-label",for:"title"},"PR title",-1))]),n("div",z3,[D(n("input",H3,null,512),[[d,{state:e.viewState,set:u=>{e.options.body=u},value:e.options?.body,form:"anonymize",options:{}}]]),t[147]||(t[147]=n("label",{class:"form-check-label",for:"body"},"PR body",-1))]),n("div",j3,[D(n("input",G3,null,512),[[d,{state:e.viewState,set:u=>{e.options.diff=u},value:e.options?.diff,form:"anonymize",options:{}}]]),t[148]||(t[148]=n("label",{class:"form-check-label",for:"diff"},"Diff",-1))]),n("div",W3,[D(n("input",K3,null,512),[[d,{state:e.viewState,set:u=>{e.options.comments=u},value:e.options?.comments,form:"anonymize",options:{}}]]),t[149]||(t[149]=n("label",{class:"form-check-label",for:"comments"},"Comments",-1))]),n("div",Y3,[D(n("input",X3,null,512),[[d,{state:e.viewState,set:u=>{e.options.username=u},value:e.options?.username,form:"anonymize",options:{}}]]),t[150]||(t[150]=n("label",{class:"form-check-label",for:"username"},"Usernames",-1))]),n("div",J3,[D(n("input",Q3,null,512),[[d,{state:e.viewState,set:u=>{e.options.date=u},value:e.options?.date,form:"anonymize",options:{}}]]),t[151]||(t[151]=n("label",{class:"form-check-label",for:"date"},"Dates",-1))]),n("div",Z3,[D(n("input",x3,null,512),[[d,{state:e.viewState,set:u=>{e.options.origin=u},value:e.options?.origin,form:"anonymize",options:{}}]]),t[152]||(t[152]=n("label",{class:"form-check-label",for:"origin"},"Project name",-1))])],512),[[Z,e.detectedType==="pr"]])],512),[[Z,e.detectedType]]),D(n("section",eO,[t[170]||(t[170]=n("h2",{class:"paper-section-eyebrow",id:"hosting-heading"},"Hosting & expiration",-1)),n("div",tO,[t[154]||(t[154]=n("label",{class:"paper-field-label",for:"conference"},[g("Conference code "),n("span",{class:"paper-optional"},"(optional)")],-1)),D(n("input",{class:A(["form-control",{"is-invalid":e.anonymize?.conference?.invalid}]),id:"conference",name:"conference"},null,2),[[d,{state:e.viewState,set:u=>{e.conference=u},value:e.conference,form:"anonymize",options:{debounce:{default:800,blur:0},updateOn:"default blur"}}]]),D(n("p",{class:A(["conference-hosting",{"is-covered":e.conferenceHosting()}]),role:"status"},[n("a",{target:"_blank",href:e.safeUrl(e.conference_data?.url)},c(e.conference_data?.name),9,nO),e.conferenceHosting()?(a(),l(q,{key:0},[g(" hosts this repository until "+c(e.fmt?.date(e.conference_data?.endDate))+", with automatic updates. You don't pay anything.",1)],64)):e.billing?.enabled&&e.detectedType==="repo"?(a(),l(q,{key:1},[g(" runs until "+c(e.fmt?.date(e.conference_data?.endDate))+". It doesn't pay for hosting, so this repository uses your own allowance.",1)],64)):(a(),l(q,{key:2},[g(" runs until "+c(e.fmt?.date(e.conference_data?.endDate))+".",1)],64))],2),[[Z,e.conference_data]]),D(n("div",sO,"The conference is not activated.",512),[[Z,e.anonymize?.conference?.errors?.activated]]),D(n("small",oO,"Submitting to a conference? Its code applies the venue's settings, and a paid conference hosts the repository for you.",512),[[Z,!e.conference_data]])]),e.detectedType==="repo"&&e.billing?.enabled&&!e.conferenceHosting()?(a(),l("p",iO,[e.isUpdate&&e.role!=="owner"?(a(),l("span",rO,"Uses the owner's hosting")):e.hasAuthorHosting()?(a(),l("span",aO,"Your author subscription is active.")):e.hostingQuota?.repository?(a(),l("span",lO,c(e.hostingQuota.repository.used)+" of "+c(e.hostingQuota.repository.total)+" active repositories \xB7 Free",1)):f("v-if",!0)])):f("v-if",!0),e.detectedType==="repo"&&e.options?.update&&!e.liveUpdatesIncluded()?(a(),l("p",dO,[t[155]||(t[155]=g("Automatic updates need a paid option. On free hosting, the link keeps the version you create until you refresh it from My work. Once it exists, add Live updates",-1)),e.liveUpdatesPrice()?(a(),l(q,{key:0},[g(" ("+c(e.liveUpdatesPrice())+" once)",1)],64)):f("v-if",!0),t[156]||(t[156]=g(" or a Paper pack in ",-1)),t[157]||(t[157]=n("a",{href:"/profile?billing=1"},"Settings \u203A Hosting & billing",-1)),t[158]||(t[158]=g(", or take an author subscription.",-1))])):f("v-if",!0),e.detectedType==="repo"&&e.billing?.enabled?(a(),l("div",uO,[e.hostingNeedsPayment()&&!e.billingPending?(a(),l(q,{key:0},[e.options.expirationMode!=="never"||e.hostingQuotaBlocked?(a(),l("p",cO,c(e.options.update&&!e.hostingQuotaBlocked&&e.hostingQuota?.repository?.used(a(),l("label",{class:A(["hosting-option",{"is-selected":e.hostingChoice()===u.id||u.interval&&e.authorPlans().some(y=>y.id===e.hostingChoice())}]),key:u.id},[n("input",{type:"radio",name:"hosting-plan",value:u.id,checked:e.hostingChoice()===u.id||u.interval&&e.authorPlans().some(y=>y.id===e.hostingChoice()),onChange:y=>e.hostingPlan=u.interval?e.hostingSubscriptionPlan().id:u.id},null,40,hO),n("span",mO,[n("strong",null,c(e.hostingOptionName(u)),1),n("small",null,c(e.hostingOptionBlurb(u)),1),u.interval&&e.authorPlans().length>1&&e.authorPlans().some(y=>y.id===e.hostingChoice())?(a(),l("span",gO,[(a(!0),l(q,null,Q(e.authorPlans(),y=>(a(),l("button",{type:"button",role:"radio",key:y.id,"aria-checked":e.hostingSubscriptionPlan().id===y.id?"true":"false",class:A({"is-on":e.hostingSubscriptionPlan().id===y.id}),onClick:ae(m=>{e.hostingCycle=y.id,e.hostingPlan=y.id},["prevent"])},[g(c(y.interval==="year"?"Yearly":"Monthly"),1),y.interval==="year"&&e.hostingAnnualSavings()?(a(),l("span",yO,"\u2212"+c(e.hostingAnnualSavings())+"%",1)):f("v-if",!0)],10,vO))),128))])):f("v-if",!0)]),n("span",bO,[n("strong",null,c(e.billingAmount(u.interval?e.hostingSubscriptionPlan():u)),1),n("small",null,c(u.interval?"per "+e.hostingSubscriptionPlan().interval:"once"),1)])],2))),128))])):(a(),l("p",wO,"New purchases are temporarily unavailable. Your draft is kept.")),e.authorPlans().some(u=>u.id===e.hostingChoice())?(a(),l("p",kO,"Renews "+c(e.hostingChoice()==="author_annual"?"yearly":"monthly")+" until you cancel. Tax shown at checkout.",1)):(a(),l("p",CO,"One-time payment, nothing renews. Tax shown at checkout.")),e.options.expirationMode!=="never"?(a(),l("details",EO,[t[159]||(t[159]=n("summary",null,"Keep using free hosting",-1)),t[160]||(t[160]=n("p",null,"Remove a repository you no longer need, or enter the code of a paid conference above. Removing a repository affects its review link.",-1)),t[161]||(t[161]=n("a",{href:"/dashboard"},"Review my repositories",-1)),n("button",{type:"button",class:"task-text-button",onClick:t[28]||(t[28]=u=>e.anonymizeRepo(u)),disabled:e.sourceLoading||e.billingBusy},"Recheck capacity and submit",8,SO)])):f("v-if",!0)],64)):f("v-if",!0)])):f("v-if",!0),e.hostingNeedsPayment()&&!e.billingPending?(a(),l("h4",NO,"Expiration")):f("v-if",!0),n("fieldset",RO,[t[167]||(t[167]=n("legend",{class:"sr-only"},"Expiration",-1)),n("label",AO,[n("input",{type:"radio",name:"expiration-choice",checked:e.options.expirationMode!=="never",onChange:t[29]||(t[29]=u=>e.useDatedHosting()),disabled:e.billingPending},null,40,PO),t[162]||(t[162]=n("span",null,"Expire on a date",-1))]),e.options.expirationMode!=="never"?(a(),l("div",DO,[e.options?.expirationMode!=="never"?(a(),l("div",TO,[t[163]||(t[163]=n("label",{class:"paper-field-label",for:"expirationDate"},"Expires",-1)),D(n("input",{class:A(["form-control",{"is-invalid":e.anonymize?.expirationDate?.invalid}]),type:"date",name:"expirationDate",id:"expirationDate",required:"",min:e.minExpirationDate,max:e.maxExpirationDate},null,10,OO),[[d,{state:e.viewState,set:u=>{e.options.expirationDate=u},value:e.options?.expirationDate,form:"anonymize",options:{}}]]),e.fmt?.dateEcho(e.options?.expirationDate)?(a(),l("p",IO,"Expires "+c(e.fmt?.dateEcho(e.options?.expirationDate)),1)):f("v-if",!0),D(n("div",MO,"Pick a date in the future.",512),[[Z,e.anonymize?.expirationDate?.errors?.min]]),D(n("div",{class:"invalid-feedback"},"Pick a date on or before "+c(e.fmt?.date(e.maxExpirationDate))+".",513),[[Z,e.anonymize?.expirationDate?.errors?.max]]),D(n("div",VO,"Enter a valid expiration date.",512),[[Z,e.anonymize?.expirationDate?.errors?.required||e.anonymize?.expirationDate?.errors?.date]])])):f("v-if",!0),n("div",qO,[t[165]||(t[165]=n("label",{for:"expiration"},"Then",-1)),D(n("select",{id:"expiration",class:"form-control","onUpdate:modelValue":t[30]||(t[30]=u=>e.options.expirationMode=u)},[...t[164]||(t[164]=[n("option",{value:"remove"},"Remove content",-1),n("option",{value:"redirect"},"Redirect to GitHub",-1)])],512),[[Ut,e.options.expirationMode]])])])):f("v-if",!0),e.detectedType==="repo"?(a(),l("label",_O,[n("input",{type:"radio",name:"expiration-choice",checked:e.options.expirationMode==="never",onChange:t[31]||(t[31]=u=>e.options.expirationMode="never"),disabled:e.billingPending},null,40,LO),n("span",null,[t[166]||(t[166]=g("Never expire",-1)),(e.options.expirationMode!=="never"||e.hasAuthorHosting()||e.repositoryGrants("repo_never").length)&&!(e.hostingNeedsPayment()&&e.hostingOptionPlans().length)?(a(),l("small",$O,c(e.neverExpireTag()),1)):f("v-if",!0)])])):f("v-if",!0)]),e.options.expirationMode==="redirect"?(a(),l("p",FO,"Visitors will be redirected to the original GitHub source on this date, revealing its identity.")):f("v-if",!0),e.detectedType==="repo"&&e.billing?.enabled?(a(),l("div",UO,[e.taskValidationError?(a(),l("p",BO,c(e.taskValidationError),1)):f("v-if",!0),e.billingError?(a(),l("p",zO,[g(c(e.billingError)+" ",1),n("button",{type:"button",class:"task-text-button",onClick:t[32]||(t[32]=u=>e.loadBilling()),disabled:e.billingBusy},"Reload billing",8,HO)])):f("v-if",!0),e.billingPending?(a(),l("div",jO,[...t[168]||(t[168]=[n("p",null,[n("strong",null,"Confirming your payment\u2026")],-1),n("p",{class:"form-text text-muted"},"Your draft is saved. Please do not pay again.",-1)])])):e.billingNotice?(a(),l("p",GO,c(e.billingNotice),1)):e.options.expirationMode==="never"&&!e.billingPending&&!e.hasAuthorHosting()&&e.repositoryGrants("repo_never").length?(a(),l("p",WO,"No scheduled expiration. Paid once for this repository.")):e.options.expirationMode==="never"&&!e.billingPending?(a(),l("p",KO,"No scheduled expiration while subscribed. A 90-day grace period applies if paid access ends.")):f("v-if",!0),e.isUpdate&&e.role==="owner"&&!e.hasAuthorHosting()&&!e.hostingNeedsPayment()&&e.repositoryAddonPlans().length?(a(),l("details",YO,[t[169]||(t[169]=n("summary",null,"Pay once for just this repository",-1)),(a(!0),l(q,null,Q(e.repositoryAddonPlans(),u=>(a(),l("div",{key:u.id},[n("p",null,[n("strong",null,c(u.name),1),g(" \xB7 "+c(e.billingPrice(u))+". "+c(u.description),1)]),n("button",{type:"button",class:"btn btn-outline-ink",disabled:e.billingBusy||e.hostingSaving||e.sourceLoading||e.billing.checkoutEnabled===!1||e.billingPending,onClick:y=>e.checkoutRepository(u.id)},"Buy "+c(u.name.toLowerCase()),9,XO)]))),128))])):f("v-if",!0)])):f("v-if",!0)],512),[[Z,e.detectedType]]),D(n("section",JO,[t[174]||(t[174]=n("h2",{class:"paper-section-eyebrow"},"Co-authors",-1)),t[175]||(t[175]=n("p",{class:"form-text text-muted",style:{"margin-bottom":"8px"}}," Co-authors can view and edit these settings. They cannot delete the anonymization or manage co-authors. ",-1)),D(n("div",QO,[t[171]||(t[171]=n("label",{class:"paper-field-label",for:"coauthorSearch"},"Add a GitHub user",-1)),n("div",ZO,[D(n("input",xO,null,512),[[d,{state:e.viewState,set:u=>{e.coauthorSearch=u},value:e.coauthorSearch,form:"anonymize",options:{debounce:300},change:()=>{e.searchCoauthors()}}]]),D(n("div",eI,[(a(!0),l(q,null,Q(e.coauthorResults,(u,y)=>(a(),l("a",{href:"#",class:"dropdown-item d-flex align-items-center",onClick:ae(m=>e.addCoauthor(u,m),["prevent"])},[n("img",{alt:"",style:{width:"22px",height:"22px","border-radius":"50%","margin-right":"8px"},src:e.safeUrl(u?.photo)},null,8,nI),n("span",{textContent:c(u?.username)},null,8,sI)],8,tI))),256))],512),[[Z,e.coauthorResults?.length>0]])]),D(n("small",{class:"form-text text-muted",textContent:c(e.coauthorError)},null,8,oI),[[Z,e.coauthorError]])],512),[[Z,e.role==="owner"||e.role==="admin"]]),n("div",iI,[(a(!0),l(q,null,Q(e.coauthors,(u,y)=>(a(),l("div",rI,[u?.photo?(a(),l("img",{key:0,alt:"",style:{width:"24px",height:"24px","border-radius":"50%"},src:e.safeUrl(u?.photo)},null,8,aI)):f("v-if",!0),n("a",{target:"_blank",textContent:c(u?.username),href:e.safeUrl("https://github.com/"+u?.username)},null,8,lI),t[173]||(t[173]=n("span",{class:"type-badge type-coauthor"},"Co-author",-1)),D(n("button",{type:"button",class:"btn btn-sm btn-icon",style:{"margin-left":"auto"},title:"Remove co-author",onClick:m=>e.removeCoauthor(u),"aria-label":"Remove co-author"},[...t[172]||(t[172]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#project-icon-close"})],-1)])],8,dI),[[Z,e.role==="owner"||e.role==="admin"]])]))),256)),D(n("div",uI," No co-authors yet. ",512),[[Z,!e.coauthors||e.coauthors?.length===0]])])],512),[[Z,e.isUpdate&&e.detectedType==="repo"]]),e.error?(a(),l("div",{key:0,class:"alert alert-danger",role:"alert",textContent:c(e.error)},null,8,cI)):f("v-if",!0)]),n("button",{type:"button",class:"btn btn-outline-ink mobile-preview-jump",onClick:t[33]||(t[33]=u=>e.selectMobilePane("preview"))},[...t[176]||(t[176]=[g("Review preview ",-1),n("span",{"aria-hidden":"true"},"\u2192",-1)])]),D(n("div",pI,[e.detectedType==="repo"?(a(),l(q,{key:0},[e.billingPending?(a(),l("button",{key:0,type:"button",class:"btn btn-ink",onClick:t[34]||(t[34]=u=>e.refreshBilling()),disabled:e.billingBusy},"Check payment status",8,fI)):(a(),l("button",{key:1,type:"submit",class:"btn btn-ink",disabled:e.sourceLoading||e.billingBusy||e.hostingSaving||e.billingLoading||e.hostingNeedsPayment()&&(!e.authorPlans().length&&!e.hostingOneTime()||e.billing?.checkoutEnabled===!1),onClick:t[35]||(t[35]=ae(u=>e.submitForm(u,()=>{e.submitRepository(u)}),["prevent"]))},c(e.hostingSaving?"Saving draft\u2026":e.hostingNeedsPayment()?"Continue to checkout":e.isUpdate?"Save changes":"Create anonymous link"),9,hI))],64)):f("v-if",!0),e.detectedType==="pr"&&!e.isUpdate?(a(),l("button",{key:1,type:"submit",disabled:e.sourceLoading||!e.details,class:"btn btn-ink",onClick:t[36]||(t[36]=ae(u=>e.submitForm(u,()=>{e.anonymizePullRequest(u)}),["prevent"]))}," Create anonymous link ",8,mI)):f("v-if",!0),e.detectedType==="pr"&&e.isUpdate?(a(),l("button",{key:2,type:"submit",disabled:e.sourceLoading,class:"btn btn-ink",onClick:t[37]||(t[37]=ae(u=>e.submitForm(u,()=>{e.anonymizePullRequest(u)}),["prevent"]))}," Save changes ",8,gI)):f("v-if",!0),e.detectedType==="gist"&&!e.isUpdate?(a(),l("button",{key:3,type:"submit",disabled:e.sourceLoading||!e.details,class:"btn btn-ink",onClick:t[38]||(t[38]=ae(u=>e.submitForm(u,()=>{e.anonymizeGist(u)}),["prevent"]))}," Create anonymous link ",8,vI)):f("v-if",!0),e.detectedType==="gist"&&e.isUpdate?(a(),l("button",{key:4,type:"submit",disabled:e.sourceLoading,class:"btn btn-ink",onClick:t[39]||(t[39]=ae(u=>e.submitForm(u,()=>{e.anonymizeGist(u)}),["prevent"]))}," Save changes ",8,yI)):f("v-if",!0),e.sourceLoading?(a(),l("p",bI,c(e.detectedType==="pr"?"Waiting for the pull request to load from GitHub\u2026":e.detectedType==="gist"?"Waiting for the gist to load from GitHub\u2026":"Waiting for the repository to load from GitHub\u2026"),1)):!e.details&&!e.isUpdate?(a(),l("p",wI,"Load an accessible source to continue. See the preview for details.")):f("v-if",!0),e.hostingNeedsPayment()&&!e.billingPending?(a(),l("p",kI,"You pay in Stripe, then come back here to finish.")):f("v-if",!0),e.draftRestored?(a(),l("div",CI,[t[177]||(t[177]=g("Your unsaved draft was restored. ",-1)),n("button",{type:"button",class:"draft-discard",onClick:t[40]||(t[40]=u=>e.discardDraft())},"Discard draft")])):e.unsavedChanges?(a(),l("div",EI,[g(c(e.draftSaved?"Draft saved \xB7":"Unsaved changes \xB7")+" ",1),n("button",{type:"button",class:"draft-discard",onClick:t[41]||(t[41]=u=>e.discardDraft())},c(e.isUpdate?"Restore saved":"Discard"),1)])):f("v-if",!0)],512),[[Z,e.detectedType]])])),[[p,e.viewState]])],8,DD),f(' Preview column (right): "What reviewers will see", a miniature reviewer window '),e.detectedType?(a(),l("div",{key:0,id:"workspace-preview",role:e.mobileWorkspace?"tabpanel":null,"aria-labelledby":e.mobileWorkspace?"workspace-preview-tab":null,class:"anonymize-preview-col reviewer-preview"},[n("div",NI,[t[180]||(t[180]=n("span",{class:"rp-title"},"What reviewers will see",-1)),e.detectedType==="repo"?(a(),l("button",{key:0,type:"button",class:"rp-open",onClick:t[42]||(t[42]=u=>e.previewViewer.sidebarCollapsed=!e.previewViewer.sidebarCollapsed),"aria-expanded":!e.previewViewer.sidebarCollapsed,"aria-controls":"preview-file-tree"},"Files",8,RI)):f("v-if",!0),e.previewStatus==="ready"&&e.previewRedactions()>0?(a(),l("span",{key:1,class:"rp-count",title:e.previewRedactions()+" redacted terms in this preview"},[n("span",PI,[n("i",null,c(e.previewRedactions()),1)]),t[178]||(t[178]=g(" redacted",-1))],8,AI)):e.previewStatus==="ready"&&!String(e.terms||"").trim()?(a(),l("span",DI,"No terms yet")):e.previewStatus==="ready"&&e.previewPreserved()?(a(),l("button",{key:3,type:"button",class:"rp-count rp-count-none",onClick:t[43]||(t[43]=u=>e.openPreserveFiles()),title:"Change it in Leave files unredacted"},c(e.previewName(e.previewFile?e.previewFile.slice(e.previewFile.lastIndexOf("/")+1):e.readmeName()))+" left unredacted",1)):f("v-if",!0),t[181]||(t[181]=n("span",{class:"rp-spacer"},null,-1)),e.isUpdate&&e.previewUrl()?(a(),l("a",{key:4,class:"rp-open is-external",href:e.safeUrl(e.previewPath()),target:"_blank",rel:"noopener"},[...t[179]||(t[179]=[g("Open reviewer page ",-1),n("span",{"aria-hidden":"true"},"\u2197",-1)])],8,TI)):(a(),l("button",{key:5,type:"button",class:"rp-open is-toggle",onClick:t[44]||(t[44]=u=>e.previewExpanded=!e.previewExpanded),"aria-pressed":!!e.previewExpanded},[(a(),l("svg",II,[e.previewExpanded?(a(),l("path",VI)):(a(),l("path",MI))])),g(c(e.previewExpanded?"Back to settings":"Expand preview"),1)],8,OI))]),n("div",qI,[n("div",_I,[t[182]||(t[182]=n("i",null,null,-1)),t[183]||(t[183]=n("i",null,null,-1)),t[184]||(t[184]=n("i",null,null,-1)),n("span",LI,c(e.previewUrl()||"anonymous.4open.science"),1)]),n("div",$I,[t[185]||(t[185]=n("span",{class:"vb-logo"},[g("Anonymous "),n("em",null,"GitHub")],-1)),e.previewId()?(a(),l("span",FI,c(e.previewId()),1)):f("v-if",!0),e.detectedType!=="repo"?(a(),l("span",UI,c(e.detectedType==="pr"?"Pull request":"Gist"),1)):f("v-if",!0)]),n("div",{class:A(["rp-body",{"reviewer-explorer":e.detectedType==="repo"}])},[e.detectedType==="repo"?(a(),l("aside",{key:0,id:"preview-file-tree",class:A(["leftCol",{collapsed:e.previewViewer.sidebarCollapsed}]),"aria-label":"Files reviewers will see"},[n("div",BI,[t[187]||(t[187]=n("span",{class:"leftCol-eyebrow"},"Files",-1)),n("button",{type:"button",class:"leftCol-close","aria-label":"Close files",onClick:t[45]||(t[45]=u=>e.previewViewer.sidebarCollapsed=!0)},[...t[186]||(t[186]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#project-icon-close"})],-1)])])]),n("div",zI,[Oe(s,{class:"files",file:e.previewTreeFiles(),page:e.previewViewer,"selected-path":"/"+e.previewPathName(e.previewOpenPath()),onSelect:t[46]||(t[46]=u=>e.selectPreviewPath(u))},null,8,["file","page","selected-path"])])],2)):f("v-if",!0),e.detectedType==="repo"?D((a(),l("div",{key:1,class:"leftCol-backdrop",onClick:t[47]||(t[47]=u=>e.previewViewer.sidebarCollapsed=!0)},null,512)),[[Z,!e.previewViewer.sidebarCollapsed]]):f("v-if",!0),n("div",{class:A(e.detectedType==="repo"?"explorer-main":"rp-main")},[n("div",{class:A(e.detectedType==="repo"?"explorer-content":"rp-document")},[f(" Loading: skeleton inside the window "),e.previewStatus==="loading"||e.sourceLoading&&e.previewStatus!=="ready"&&e.previewStatus!=="error"?(a(),l("div",HI,[n("span",jI,c(e.previewDoc.loading?"Loading "+e.previewName(e.previewFile.slice(e.previewFile.lastIndexOf("/")+1))+" from GitHub\u2026":e.previewStatus==="loading"?"Updating the anonymized preview\u2026":e.detectedType==="pr"?"Loading the pull request from GitHub\u2026":e.detectedType==="gist"?"Loading the gist from GitHub\u2026":"Loading the repository from GitHub\u2026"),1),t[188]||(t[188]=Ce('',7))])):!e.details&&e.detectedType!=="repo"?(a(),l(q,{key:1},[f(" The source itself could not be loaded "),n("div",GI,[n("strong",null,"Couldn't load "+c(e.sourceSummary()||(e.detectedType==="pr"?"this pull request":"this gist")),1),n("p",null,c(e.error||"GitHub did not return it. Check that the link is right and that Anonymous GitHub can read it."),1),n("div",WI,[n("button",{type:"button",class:"btn btn-ink btn-sm",onClick:t[48]||(t[48]=u=>e.urlSelected(!0))},"Retry"),e.detectedType==="pr"&&e.githubConnection!=="oauth"?(a(),l("button",{key:0,type:"button",class:"btn btn-outline-ink btn-sm",onClick:t[49]||(t[49]=u=>e.grantGitHubAccess())},[...t[189]||(t[189]=[g("Manage GitHub access ",-1),n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-external-link"})],-1)])])):(a(),l("a",KI,[...t[190]||(t[190]=[g("Manage GitHub access ",-1),n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-external-link"})],-1)])]))])])],2112)):!e.details&&e.detectedType==="repo"&&!e.isUpdate&&e.error?(a(),l("div",YI,[t[192]||(t[192]=n("strong",null,"Couldn't load this repository",-1)),n("p",null,c(e.error),1),n("div",XI,[n("button",{type:"button",class:"btn btn-ink btn-sm",onClick:t[50]||(t[50]=u=>e.urlSelected(!0))},"Retry"),e.githubConnection!=="oauth"?(a(),l("button",{key:0,type:"button",class:"btn btn-outline-ink btn-sm",onClick:t[51]||(t[51]=u=>e.grantGitHubAccess())},[...t[191]||(t[191]=[g("Manage GitHub access ",-1),n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-external-link"})],-1)])])):f("v-if",!0)])])):e.previewStatus==="error"&&e.previewDoc.loadError?(a(),l(q,{key:3},[f(" The open file could not be read from GitHub "),n("div",JI,[n("strong",null,"Couldn't load "+c(e.previewName(e.previewFile.slice(e.previewFile.lastIndexOf("/")+1))),1),n("p",null,c(e.previewDoc.loadError),1),n("div",QI,[n("button",{class:"btn btn-ink btn-sm",type:"button",onClick:t[52]||(t[52]=u=>e.retryPreview())},"Retry"),n("button",{class:"btn btn-outline-ink btn-sm",type:"button",onClick:t[53]||(t[53]=u=>e.openPreviewFile(""))},"Back to the README")])])],2112)):e.previewStatus==="error"?(a(),l(q,{key:4},[f(" The anonymized preview failed "),n("div",ZI,[t[193]||(t[193]=n("strong",null,"Couldn't apply the redactions",-1)),t[194]||(t[194]=n("p",null,"Unable to generate the anonymized preview. The latest redactions have not been verified.",-1)),n("div",xI,[n("button",{class:"btn btn-ink btn-sm",type:"button",onClick:t[54]||(t[54]=u=>e.retryPreview())},"Retry preview")])])],2112)):e.detectedType==="repo"&&!e.previewFile&&!e.readme&&e.previewStatus==="idle"?(a(),l("div",e5,[...t[195]||(t[195]=[n("strong",null,"No README",-1),n("p",null,"Reviewers land on the file list. Open the files you will share and check them before sending the link.",-1)])])):e.detectedType==="repo"&&e.previewStatus==="ready"?(a(),Wt(i,{key:6,name:"partials/pageView.htm",state:e.previewViewer},null,8,["state"])):e.detectedType==="gist"&&e.previewStatus==="ready"?(a(),l("div",t5,[n("div",n5,[n("h2",s5,[e.options?.title?(a(),l("span",o5,c(e.anonymizeGistContent(e.details?.gist?.description)||"Untitled gist"),1)):f("v-if",!0),n("span",{class:A(["badge",{"badge-success":e.details?.gist?.isPublic,"badge-secondary":!e.details?.gist?.isPublic}])},c(e.details?.gist?.isPublic?"public":"secret"),3)]),e.options?.date?(a(),l("small",{key:0,textContent:c(e.fmt?.date(e.details?.gist?.updatedDate))},null,8,i5)):f("v-if",!0)]),e.options?.origin?(a(),l("small",r5,"Gist ID: "+c(e.details?.source?.gistId),1)):f("v-if",!0),e.options?.username&&e.details?.gist?.ownerLogin?(a(),l("small",a5,"By @"+c(e.anonymizeGistContent(e.details?.gist?.ownerLogin)),1)):f("v-if",!0),e.options?.content&&e.previewGistFiles?.length?(a(),l("div",l5,[n("ul",d5,[(a(!0),l(q,null,Q(e.previewGistFiles,(u,y)=>(a(),l("li",u5,[n("div",c5,[n("strong",{textContent:c(u?.filename)},null,8,p5),u?.language?(a(),l("span",f5,c(u?.language),1)):f("v-if",!0)]),Oe(o,{file:u,terms:e.terms,options:e.options},null,8,["file","terms","options"])]))),256))])])):f("v-if",!0),e.options?.comments&&e.details?.gist?.comments&&e.details?.gist?.comments?.length?(a(),l("div",h5,[t[198]||(t[198]=n("h3",{class:"paper-section-eyebrow mt-3"},"Comments",-1)),n("ul",m5,[(a(!0),l(q,null,Q(e.details?.gist?.comments,(u,y)=>(a(),l("li",g5,[n("div",v5,[e.options?.username?(a(),l("span",y5,[t[196]||(t[196]=n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-user"})],-1)),t[197]||(t[197]=g(" @",-1)),n("span",{textContent:c(e.anonymizeGistContent(u?.author))},null,8,b5)])):f("v-if",!0),e.options?.date?(a(),l("span",{key:1,class:"pr-comment-date",textContent:c(e.fmt?.date(u?.updatedDate))},null,8,w5)):f("v-if",!0)]),e.options?.body?(a(),l("div",k5,[Oe(r,{content:e.anonymizeGistContent(u?.body),options:e.options,terms:e.terms},null,8,["content","options","terms"])])):f("v-if",!0)]))),256))])])):f("v-if",!0)])):e.detectedType==="pr"&&e.previewStatus==="ready"?(a(),l("div",C5,[n("div",E5,[n("h2",S5,[e.options?.title?(a(),l("span",N5,c(e.anonymizePrContent(e.details?.pullRequest?.title)),1)):f("v-if",!0),n("span",{class:A(["badge",{"badge-success":e.details?.pullRequest?.merged,"badge-warning":e.details?.pullRequest?.state=="open","badge-danger":e.details?.pullRequest?.state=="closed"&&!e.details?.pullRequest?.merged}])},c(e.fmt?.title(e.details?.pullRequest?.merged?"merged":e.details?.pullRequest?.state)),3)]),e.options?.date?(a(),l("small",{key:0,textContent:c(e.fmt?.date(e.details?.pullRequest?.updatedDate))},null,8,R5)):f("v-if",!0)]),e.options?.origin?(a(),l("small",A5,"Pull Request on "+c(e.details?.pullRequest?.baseRepositoryFullName),1)):f("v-if",!0),e.options?.body?(a(),l("div",P5,[Oe(r,{content:e.anonymizePrContent(e.details?.pullRequest?.body),options:e.options,terms:e.terms},null,8,["content","options","terms"])])):f("v-if",!0),e.options?.diff||e.options?.comments?(a(),l("nav",D5,[e.options?.diff?(a(),l("button",{key:0,class:A(["paper-tab",{active:e.prTabState?.active=="diff"}]),type:"button",role:"tab",id:"preview-pr-diff-tab","aria-selected":e.prTabState?.active==="diff","aria-controls":"preview-pr-diff-panel",tabindex:e.prTabState?.active==="diff"?0:-1,onKeydown:t[55]||(t[55]=u=>e.previewTabKeydown(u)),onClick:t[56]||(t[56]=u=>e.prTabState.active="diff")},[...t[199]||(t[199]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-code"})],-1),g(" Diff ",-1)])],42,T5)):f("v-if",!0),e.options?.comments?(a(),l("button",{key:1,class:A(["paper-tab",{active:e.prTabState?.active=="comments"}]),type:"button",role:"tab",id:"preview-pr-comments-tab","aria-selected":e.prTabState?.active==="comments","aria-controls":"preview-pr-comments-panel",tabindex:e.prTabState?.active==="comments"?0:-1,onKeydown:t[57]||(t[57]=u=>e.previewTabKeydown(u)),onClick:t[58]||(t[58]=u=>e.prTabState.active="comments")},[t[200]||(t[200]=n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-comment"})],-1)),n("span",{textContent:c(e.fmt.plural(e.details?.pullRequest?.comments?.length,{0:"No comments",one:"1 comment",other:"{} comments"}))},null,8,I5)],42,O5)):f("v-if",!0)])):f("v-if",!0),!e.options?.diff&&!e.options?.comments?(a(),l("div",M5,"Diff and comments are hidden by your display settings.")):f("v-if",!0),n("div",V5,[e.options?.diff&&e.prTabState?.active=="diff"?(a(),l("div",q5,[n("div",{class:"pr-diff",innerHTML:e.sanitize(e.fmt?.diff(e.anonymizePrContent(e.details?.pullRequest?.diff)))},null,8,_5)])):f("v-if",!0),e.options?.comments&&e.prTabState?.active=="comments"?(a(),l("div",L5,[n("ul",$5,[(a(!0),l(q,null,Q(e.details?.pullRequest?.comments,(u,y)=>(a(),l("li",F5,[n("div",U5,[e.options?.username?(a(),l("span",B5,[t[201]||(t[201]=n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-user"})],-1)),t[202]||(t[202]=g(" @",-1)),n("span",{textContent:c(e.anonymizePrContent(u?.author))},null,8,z5)])):f("v-if",!0),e.options?.date?(a(),l("span",{key:1,class:"pr-comment-date",textContent:c(e.fmt?.date(u?.updatedDate))},null,8,H5)):f("v-if",!0)]),e.options?.body?(a(),l("div",j5,[Oe(r,{content:e.anonymizePrContent(u?.body),options:e.options,terms:e.terms},null,8,["content","options","terms"])])):f("v-if",!0)]))),256))])])):f("v-if",!0)])])):f("v-if",!0),f(" More below: a fade with a way to keep reading (hidden by CSS once the window is scrolled to the end) "),e.previewStatus==="ready"&&!(e.detectedType==="repo"&&e.previewFile&&e.previewDoc.note)?(a(),l("div",G5,[e.isUpdate&&e.previewUrl()?(a(),l("a",{key:0,class:"rp-more-btn",href:e.safeUrl(e.previewPath()),target:"_blank",rel:"noopener"},[...t[203]||(t[203]=[g("Continue reading on the reviewer page ",-1),n("span",{"aria-hidden":"true"},"\u2197",-1)])],8,W5)):e.previewExpanded?(a(),l("span",K5,"Scroll for more")):(a(),l("button",{key:1,type:"button",class:"rp-more-btn",onClick:t[59]||(t[59]=u=>e.previewExpanded=!0)},"Continue reading in the expanded preview"))])):f("v-if",!0)],2)],2)],2)])],8,SI)):f("v-if",!0)])],512),[[Z,e.workspaceOpen||e.isUpdate]])],2)}var Y5={class:"container-fluid h-100 anonymize-page"},X5={class:"row h-100 flex-column flex-md-row"},J5={class:"col-md sidePanel shadow overflow-auto anonymize-form-col"},Q5={class:"form-group"},Z5={class:"form-group"},x5={class:"form-check"},e8={class:"form-check-input",type:"checkbox",id:"update",name:"update"},t8={class:"form-group"},n8={class:"form-text text-muted"},s8=["href"],o8={class:"invalid-feedback"},i8={class:"form-text text-muted"},r8={class:"form-group"},a8={id:"idHelp",class:"form-text text-muted"},l8={class:"invalid-feedback"},d8={class:"form-group"},u8={class:"invalid-feedback"},c8={class:"form-group"},p8={class:"form-control",id:"expiration",name:"expiration"},f8={class:"form-group",id:"expiration-date-form"},h8={class:"form-control",type:"date",name:"expirationDate",id:"expirationDate"},m8={key:0,class:"date-echo","aria-live":"polite"},g8={class:"accordion mb-3",id:"options"},v8={class:"card"},y8={id:"collapseOne",class:"collapse show","aria-labelledby":"headingOne","data-parent":"#options"},b8={class:"card-body"},w8={class:"form-group mb-0"},k8={class:"form-check"},C8={class:"form-check-input",type:"checkbox",id:"link",name:"link"},E8={class:"form-check"},S8={class:"form-check-input",type:"checkbox",id:"image",name:"image"},N8={class:"form-check"},R8={class:"form-check-input",type:"checkbox",id:"date",name:"date"},A8={class:"form-check"},P8={class:"form-check-input",type:"checkbox",id:"username",name:"username"},D8={class:"form-check"},T8={class:"form-check-input",type:"checkbox",id:"comments",name:"comments"},O8={class:"form-check"},I8={class:"form-check-input",type:"checkbox",id:"diff",name:"diff"},M8={class:"form-check"},V8={class:"form-check-input",type:"checkbox",id:"origin",name:"origin"},q8={class:"form-check"},_8={class:"form-check-input",type:"checkbox",id:"title",name:"title"},L8={class:"form-check"},$8={class:"form-check-input",type:"checkbox",id:"body",name:"body"},F8=["textContent"],U8={class:"anonymize-submit-bar"},B8={key:0,class:"col-md-8 p-2 overflow-auto anonymize-preview-col"},z8={class:"d-flex w-100 justify-content-between align-items-center flex-wrap"},H8={class:"pr-title mb-1"},j8={key:0},G8=["textContent"],W8={key:0},K8={key:1,class:"pr-body shadow-sm p-3 mb-4 rounded",style:{background:"var(--sidebar-bg-color)"}},Y8={class:"nav nav-tabs",id:"myTab",role:"tablist"},X8={key:0,class:"nav-item",role:"presentation"},J8={key:1,class:"nav-item",role:"presentation"},Q8=["textContent"],Z8={class:"tab-content",id:"pills-tabContent"},x8={class:"tab-pane show active",id:"pills-diff",role:"tabpanel","aria-labelledby":"pills-diff-tab"},eM={key:0,class:"pr-diff shadow-sm p-3 mb-4 rounded",style:{background:"var(--sidebar-bg-color)"}},tM={style:{"overflow-x":"auto"}},nM=["innerHTML"],sM={key:0,class:"pr-comments list-group"},oM={class:"pr-comment list-group-item"},iM={class:"d-flex w-100 justify-content-between flex-wrap"},rM={key:0,class:"mb-1"},aM=["textContent"],lM={class:"mb-1"};function lp(e,t){let s=Xe("markdown"),i=Pe("field"),o=Pe("form");return a(),l("div",Y5,[n("div",X5,[n("div",J5,[n("div",{class:A(["p-0 py-2 m-auto",{card:!e.pullRequestUrl,container:e.pullRequestUrl}])},[D((a(),l("form",{class:A(["form needs-validation",{"card-body":!e.pullRequestUrl}]),name:"anonymizeForm",novalidate:""},[t[30]||(t[30]=Ce('
Anonymize \xA0/\xA0 Pull request

Anonymize a pull request

Fill in the details \u2014 it only takes a minute.

Source
',4)),f(" pullRequestUrl "),n("div",Q5,[t[2]||(t[2]=n("label",{for:"pullRequestUrl"},"URL of your pull request",-1)),D(n("input",{type:"text",class:A(["form-control",{"is-invalid":e.anonymize?.pullRequestUrl?.invalid}]),name:"pullRequestUrl",id:"pullRequestUrl",placeholder:"https://github.com/owner/repo/pull/123"},null,2),[[i,{state:e.viewState,set:r=>{e.pullRequestUrl=r},value:e.pullRequestUrl,form:"anonymizeForm",options:{debounce:{default:1e3,blur:0,click:0},updateOn:"default blur click"},change:()=>{e.pullRequestSelected()}}]]),D(n("div",{class:"invalid-feedback"},c(e.pullRequestUrl)+" is not accessible. Some organizations are restricting the access to the repositories. ",513),[[Z,e.anonymize?.pullRequestUrl?.errors?.access]]),D(n("div",{class:"invalid-feedback"},c(e.pullRequestUrl)+" does not exist or is not accessible ",513),[[Z,e.anonymize?.pullRequestUrl?.errors?.missing]]),D(n("div",{class:"invalid-feedback"},c(e.pullRequestUrl)+" is already anonymized ",513),[[Z,e.anonymize?.pullRequestUrl?.errors?.used]])]),D(n("div",null,[n("div",Z5,[n("div",x5,[D(n("input",e8,null,512),[[i,{state:e.viewState,set:r=>{e.options.update=r},value:e.options?.update,form:"anonymizeForm",options:{}}]]),t[3]||(t[3]=n("label",{class:"form-check-label",for:"update"},"Auto update",-1)),t[4]||(t[4]=n("small",{id:"updateHelp",class:"form-text text-muted"},"Automatically update the anonymized pull request with the latest updates. The pull request is updated once per day maximum.",-1))])]),t[26]||(t[26]=n("div",{class:"paper-section-eyebrow anonymize-section-title"},[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#project-icon-conference"})]),g(" Conference ID ")],-1)),f(" Conference "),n("div",t8,[t[5]||(t[5]=n("label",{for:"conference"},[g("Conference ID "),n("span",{class:"text-muted"},"(Optional)")],-1)),D(n("input",{class:A(["form-control",{"is-invalid":e.anonymize?.conference?.invalid}]),id:"conference",name:"conference"},null,2),[[i,{state:e.viewState,set:r=>{e.conference=r},value:e.conference,form:"anonymizeForm",options:{debounce:{default:800,blur:0},updateOn:"default blur"}}]]),D(n("small",n8,[n("a",{target:"_target",href:e.safeUrl(e.conference_data?.url)},c(e.conference_data?.name),9,s8),g(" will expire on "+c(e.fmt?.date(e.conference_data?.endDate))+".",1)],512),[[Z,e.conference_data]]),D(n("div",o8," The conference is not activated. ",512),[[Z,e.anonymize?.conference?.errors?.activated]]),D(n("small",i8," Use the Conference ID that your conference provided you. This will update automatically the anonymization options based on the conference preferences. ",512),[[Z,!e.conference_data]])]),t[27]||(t[27]=n("div",{class:"paper-section-eyebrow anonymize-section-title"},[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-shield"})]),g(" Anonymization Options ")],-1)),f(" Pull Request ID "),n("div",r8,[t[6]||(t[6]=n("label",{for:"pullRequestId"},"Anonymized pull request id",-1)),D(n("input",{type:"text",class:A(["form-control",{"is-invalid":e.anonymize?.pullRequestId?.invalid}]),name:"pullRequestId",id:"pullRequestId"},null,2),[[i,{state:e.viewState,set:r=>{e.pullRequestId=r},value:e.pullRequestId,form:"anonymizeForm",options:{debounce:{default:1e3,blur:0,click:0},updateOn:"default blur click"}}]]),n("small",a8,"Id used in the url: https://anonymous.4open.science/r/"+c(e.pullRequestId),1),D(n("div",l8," Repository id can only contain letters and numbers ",512),[[Z,e.anonymize?.pullRequestId?.errors?.format]]),D(n("div",{class:"invalid-feedback"},c(e.pullRequestId)+" is already used ",513),[[Z,e.anonymize?.pullRequestId?.errors?.used]])]),f(" Terms "),n("div",d8,[t[7]||(t[7]=n("label",{for:"terms"},"Terms to anonymize",-1)),D(n("textarea",{class:A(["form-control",{"is-invalid":e.anonymize?.terms?.invalid}]),id:"terms",name:"terms",rows:"3"},null,2),[[i,{state:e.viewState,set:r=>{e.terms=r},value:e.terms,form:"anonymizeForm",options:{debounce:250}}]]),t[8]||(t[8]=n("small",{id:"termsHelp",class:"form-text text-muted"},"One term per line. Each term will be replaced by XXX.",-1)),D(n("div",u8," Terms are in an invalid format ",512),[[Z,e.anonymize?.terms?.errors?.format]])]),n("div",c8,[t[10]||(t[10]=n("label",{for:"expiration"},"Expiration strategy",-1)),D((a(),l("select",p8,[...t[9]||(t[9]=[n("option",{value:"never",selected:""},"Never expire",-1),n("option",{value:"redirect"}," Redirect to GitHub when expired ",-1),n("option",{value:"remove"},"Remove when expired",-1)])])),[[i,{state:e.viewState,set:r=>{e.options.expirationMode=r},value:e.options?.expirationMode,form:"anonymizeForm",options:{}}]]),t[11]||(t[11]=n("small",{class:"form-text text-muted"},"Define the expiration strategy for the anonymized repository.",-1))]),D(n("div",f8,[t[12]||(t[12]=n("label",{for:"expirationDate"},"Expiration date of the anonymized repository",-1)),D(n("input",h8,null,512),[[i,{state:e.viewState,set:r=>{e.options.expirationDate=r},value:e.options?.expirationDate,form:"anonymizeForm",options:{}}]]),e.fmt?.dateEcho(e.options?.expirationDate)?(a(),l("p",m8,"Expires "+c(e.fmt?.dateEcho(e.options?.expirationDate)),1)):f("v-if",!0),D(n("small",{class:"form-text text-muted"},"After "+c(e.fmt?.date(e.options?.expirationDate))+", the repository will be removed and the visitor will not be able to see the content of the repository.",513),[[Z,e.options?.expirationMode=="remove"]]),D(n("small",{class:"form-text text-muted"},"After "+c(e.fmt?.date(e.options?.expirationDate))+", the visitors of the anonymized repository will be redirected to "+c(e.pullRequestUrl)+".",513),[[Z,e.options?.expirationMode=="redirect"]])],512),[[Z,e.options?.expirationMode!="never"]]),n("div",g8,[n("div",v8,[t[25]||(t[25]=Ce('

',1)),n("div",y8,[n("div",b8,[n("div",w8,[n("div",k8,[D(n("input",C8,null,512),[[i,{state:e.viewState,set:r=>{e.options.link=r},value:e.options?.link,form:"anonymizeForm",options:{}}]]),t[13]||(t[13]=n("label",{class:"form-check-label",for:"link"},"Keep links",-1)),t[14]||(t[14]=n("small",{class:"form-text text-muted"},"Keep or remove all the links.",-1))]),n("div",E8,[D(n("input",S8,null,512),[[i,{state:e.viewState,set:r=>{e.options.image=r},value:e.options?.image,form:"anonymizeForm",options:{}}]]),t[15]||(t[15]=n("label",{class:"form-check-label",for:"image"},"Display images",-1)),t[16]||(t[16]=n("small",{class:"form-text text-muted"},"Images are not anonymized",-1))]),n("div",N8,[D(n("input",R8,null,512),[[i,{state:e.viewState,set:r=>{e.options.date=r},value:e.options?.date,form:"anonymizeForm",options:{}}]]),t[17]||(t[17]=n("label",{class:"form-check-label",for:"date"},"Display dates",-1)),t[18]||(t[18]=n("small",{class:"form-text text-muted"},"Display the date of the Pull Request and the date of the comments.",-1))]),n("div",A8,[D(n("input",P8,null,512),[[i,{state:e.viewState,set:r=>{e.options.username=r},value:e.options?.username,form:"anonymizeForm",options:{}}]]),t[19]||(t[19]=n("label",{class:"form-check-label",for:"username"},"Display username",-1))]),n("div",D8,[D(n("input",T8,null,512),[[i,{state:e.viewState,set:r=>{e.options.comments=r},value:e.options?.comments,form:"anonymizeForm",options:{}}]]),t[20]||(t[20]=n("label",{class:"form-check-label",for:"comments"},"Display comments",-1))]),n("div",O8,[D(n("input",I8,null,512),[[i,{state:e.viewState,set:r=>{e.options.diff=r},value:e.options?.diff,form:"anonymizeForm",options:{}}]]),t[21]||(t[21]=n("label",{class:"form-check-label",for:"diff"},"Display diff",-1))]),n("div",M8,[D(n("input",V8,null,512),[[i,{state:e.viewState,set:r=>{e.options.origin=r},value:e.options?.origin,form:"anonymizeForm",options:{}}]]),t[22]||(t[22]=n("label",{class:"form-check-label",for:"origin"},"Display the project name",-1))]),n("div",q8,[D(n("input",_8,null,512),[[i,{state:e.viewState,set:r=>{e.options.title=r},value:e.options?.title,form:"anonymizeForm",options:{}}]]),t[23]||(t[23]=n("label",{class:"form-check-label",for:"title"},"Display the PR title",-1))]),n("div",L8,[D(n("input",$8,null,512),[[i,{state:e.viewState,set:r=>{e.options.body=r},value:e.options?.body,form:"anonymizeForm",options:{}}]]),t[24]||(t[24]=n("label",{class:"form-check-label",for:"body"},"Display the PR body and comment bodies",-1))])])])])])])],512),[[Z,e.pullRequestUrl]]),e.error?(a(),l("div",{key:0,class:"alert alert-danger",role:"alert",textContent:c(e.error)},null,8,F8)):f("v-if",!0),D(n("div",U8,[e.isUpdate?f("v-if",!0):(a(),l("button",{key:0,id:"submit",type:"submit",class:"btn btn-ink btn-block",onClick:t[0]||(t[0]=ae(r=>e.submitForm(r,()=>{e.anonymizePullRequest(r)}),["prevent"]))},[...t[28]||(t[28]=[n("svg",{class:"ui-icon mr-1","aria-hidden":"true"},[n("use",{href:"#ui-icon-shield"})],-1),g(" Anonymize ",-1)])])),e.isUpdate?(a(),l("button",{key:1,id:"submit",type:"submit",class:"btn btn-ink btn-block",onClick:t[1]||(t[1]=ae(r=>e.submitForm(r,()=>{e.updatePullRequest(r)}),["prevent"]))},[...t[29]||(t[29]=[n("svg",{class:"ui-icon mr-1","aria-hidden":"true"},[n("use",{href:"#ui-icon-save"})],-1),g(" Update ",-1)])])):f("v-if",!0)],512),[[Z,e.pullRequestUrl]])],2)),[[o,e.viewState]])],2)]),e.details?(a(),l("div",B8,[n("div",z8,[n("h2",H8,[e.options?.title?(a(),l("span",j8,c(e.anonymize(e.details?.pullRequest?.title)),1)):f("v-if",!0),n("span",{class:A(["badge",{"badge-success":e.details?.pullRequest?.merged,"badge-warning":e.details?.pullRequest?.state=="open","badge-danger":e.details?.pullRequest?.state=="closed"&&!e.details?.pullRequest?.merged}])},c(e.fmt?.title(e.details?.pullRequest?.merged?"merged":e.details?.pullRequest?.state)),3)]),e.options?.date?(a(),l("small",{key:0,textContent:c(e.fmt?.date(e.details?.pullRequest?.updatedDate))},null,8,G8)):f("v-if",!0)]),e.options?.origin?(a(),l("small",W8,"Pull Request on "+c(e.details?.pullRequest?.baseRepositoryFullName),1)):f("v-if",!0),e.options?.body?(a(),l("div",K8,[Oe(s,{content:e.anonymize(e.details?.pullRequest?.body),options:e.options,terms:e.terms},null,8,["content","options","terms"])])):f("v-if",!0),n("ul",Y8,[e.options?.diff?(a(),l("li",X8,[...t[31]||(t[31]=[n("button",{class:"nav-link active",id:"pills-diff-tab","data-toggle":"pill","data-target":"#pills-diff",type:"button",role:"tab","aria-controls":"pills-diff","aria-selected":"true"}," Diff ",-1)])])):f("v-if",!0),e.options?.comments?(a(),l("li",J8,[n("button",{class:A(["nav-link",{active:!e.options?.diff}]),id:"pills-comments-tab","data-toggle":"pill","data-target":"#pills-comments",type:"button",role:"tab","aria-controls":"pills-comments","aria-selected":"false"},[n("span",{textContent:c(e.fmt.plural(e.details?.pullRequest?.comments?.length,{0:"No comment",one:"One Comment",other:"{} Comments"}))},null,8,Q8)],2)])):f("v-if",!0)]),n("div",Z8,[n("div",x8,[e.options?.diff?(a(),l("div",eM,[n("pre",tM,[n("code",{innerHTML:e.sanitize(e.fmt?.diff(e.anonymize(e.details?.pullRequest?.diff)))},null,8,nM)])])):f("v-if",!0)]),n("div",{class:A(["tab-pane",{"show active":!e.options?.diff}]),id:"pills-comments",role:"tabpanel","aria-labelledby":"pills-comments-tab"},[e.options?.comments?(a(),l("ul",sM,[(a(!0),l(q,null,Q(e.details?.pullRequest?.comments,(r,d)=>(a(),l("li",oM,[n("div",iM,[e.options?.username?(a(),l("h5",rM," @"+c(e.anonymize(r?.author)),1)):f("v-if",!0),e.options?.date?(a(),l("small",{key:1,textContent:c(e.fmt?.date(r?.updatedDate))},null,8,aM)):f("v-if",!0)]),n("p",lM,[e.options?.body?(a(),Wt(s,{key:0,class:"pr-comment-body",content:e.anonymize(r?.body),options:e.options,terms:e.terms},null,8,["content","options","terms"])):f("v-if",!0)])]))),256))])):f("v-if",!0)],2)])])):f("v-if",!0)])])}var dM={class:"container paper-page claim-page"},uM={class:"paper-settings-main claim-form"},cM={class:"form-group"},pM={class:"invalid-feedback"},fM={class:"form-group"};function dp(e,t){let s=Pe("field"),i=Pe("form");return a(),l("div",dM,[t[6]||(t[6]=Ce('
My work \xA0/\xA0 Claim

Claim an anonymization

Take ownership of an existing anonymized repository so it appears on your dashboard.

',3)),n("div",uM,[t[5]||(t[5]=n("p",{class:"paper-section-copy"},"Use this when an anonymization was created by a co-author or from another account. You must have access to the GitHub repository it was made from.",-1)),D((a(),l("form",{class:"form needs-validation",name:"claimForm",novalidate:"",onSubmit:t[0]||(t[0]=ae(o=>e.submitForm(o,()=>{e.claim()}),["prevent"]))},[n("div",cM,[t[1]||(t[1]=n("label",{class:"paper-field-label",for:"repoUrl"},"GitHub repository URL",-1)),D(n("input",{type:"text",class:A(["form-control",{"is-invalid":e.claimForm?.repoUrl?.invalid&&(e.claimForm?.repoUrl?.touched||e.claimForm?.submitted)}]),name:"repoUrl",id:"repoUrl",placeholder:"https://github.com/owner/repository",required:""},null,2),[[s,{state:e.viewState,set:o=>{e.repoUrl=o},value:e.repoUrl,form:"claimForm",options:{}}]]),D(n("div",pM," No anonymization matches this repository and ID. Check both values and that you can access the repository on GitHub. ",512),[[Z,e.claimForm?.repoUrl?.errors?.not_found]])]),n("div",fM,[t[2]||(t[2]=n("label",{class:"paper-field-label",for:"repoId"},"Anonymized repository ID",-1)),D(n("input",{type:"text",class:A(["form-control",{"is-invalid":e.claimForm?.repoId?.invalid&&(e.claimForm?.repoId?.touched||e.claimForm?.submitted)}]),name:"repoId",id:"repoId",placeholder:"e.g. my-paper-7F2A","aria-describedby":"idHelp",required:""},null,2),[[s,{state:e.viewState,set:o=>{e.repoId=o},value:e.repoId,form:"claimForm",options:{}}]]),t[3]||(t[3]=n("small",{id:"idHelp",class:"form-text text-muted"},[g("The ID is the last part of the anonymized URL: "),n("code",null,"anonymous.4open.science/r/"),g(".")],-1))]),t[4]||(t[4]=n("button",{id:"submit",type:"submit",class:"btn btn-ink"}," Claim anonymization ",-1))],32)),[[i,e.viewState]])])])}var hM={class:"container page paper-page conference-page"},mM={class:"paper-crumbs"},gM={class:"here"},vM={class:"d-flex align-items-end flex-wrap",style:{gap:"12px","justify-content":"space-between"}},yM={class:"conf-title-row"},bM=["textContent"],wM={key:0,class:"conf-status"},kM=["textContent"],CM={key:0,class:"paper-page-lede"},EM=["textContent","href"],SM={class:"d-flex align-items-center flex-wrap",style:{gap:"10px"}},NM=["href"],RM={class:"paper-meta-rule"},AM=["textContent"],PM=["textContent"],DM={key:0},TM={key:0,class:"conference-payment-status",role:"status"},OM=["disabled"],IM={key:1,role:"alert"},MM={key:2,class:"paper-settings-section","aria-labelledby":"conference-payment-heading"},VM={key:0,role:"status"},qM={key:1,role:"alert"},_M=["onClick","disabled"],LM={class:"dashboard-meta conf-view-meta"},$M={class:"dashboard-view-tabs",role:"group","aria-label":"Repository view"},FM=["aria-pressed"],UM=["aria-pressed","aria-label"],BM=["aria-pressed"],zM={class:"attention-count"},HM={class:"dashboard-count",role:"status"},jM={class:"search-wrap"},GM={type:"search",id:"search",class:"form-control","aria-label":"Search repositories",placeholder:"Search repositories\u2026",autocomplete:"off"},WM={class:"dashboard-filter-controls"},KM={class:"dropdown"},YM={class:"btn dropdown-toggle",type:"button",id:"dropdownSort","data-toggle":"dropdown","aria-haspopup":"true","aria-expanded":"false"},XM={class:"filter-btn-value"},JM={class:"dropdown-menu","aria-labelledby":"dropdownSort"},QM={class:"form-check dropdown-item"},ZM={class:"form-check-input",type:"radio",name:"sort",id:"anonymizeDate",value:"-anonymizeDate"},xM={class:"form-check dropdown-item"},e6={class:"form-check-input",type:"radio",name:"sort",id:"sortID",value:"repoId"},t6={class:"form-check dropdown-item"},n6={class:"form-check-input",type:"radio",name:"sort",id:"sortStatus",value:"-status"},s6={class:"form-check dropdown-item"},o6={class:"form-check-input",type:"radio",name:"sort",id:"sortViews",value:"-pageView"},i6={class:"dashboard-page conf-rows"},r6={class:"cell-anon",role:"cell"},a6={class:"anon-text"},l6={class:"anon-title"},d6=["title","href"],u6={class:"rn-owner"},c6={class:"rn-repo"},p6={class:"anon-sub"},f6=["title"],h6={class:"id-head"},m6={class:"id-tail"},g6=["title"],v6={class:"dashboard-row-meta",role:"presentation"},y6={class:"cell-status",role:"cell"},b6={class:"status-line"},w6=["textContent"],k6=["textContent","title"],C6=["href"],E6=["onClick","disabled"],S6={key:3,class:"status-sub status-sub-date"},N6=["data-unit","aria-label"],R6={class:"cell-expires",role:"cell"},A6={key:0,class:"expires-never"},P6=["textContent"],D6={key:2,class:"expires-past"},T6={key:3,class:"empty-dash","aria-label":"Not applicable"},O6={class:"cell-actions",role:"cell"},I6=["onClick","disabled","title","aria-label"],M6={class:"sr-only","aria-live":"polite"},V6={class:"project-type-svg","aria-hidden":"true"},q6=["href"],_6={class:"copy-url-label","aria-hidden":"true"},L6=["href","aria-label"],$6={class:"dropdown"},F6=["aria-label"],U6={class:"dropdown-menu dropdown-menu-right"},B6=["href"],z6=["href"],H6=["href"],j6={key:0,class:"paper-table-empty"},G6={key:0},W6={key:1},K6={key:2,class:"paper-table-empty-actions"};function up(e,t){let s=Pe("field"),i=Pe("form");return a(),l("div",hM,[n("div",null,[n("div",mM,[t[6]||(t[6]=n("a",{href:"/dashboard"},"My work",-1)),t[7]||(t[7]=g(" \xA0/\xA0 ",-1)),t[8]||(t[8]=n("a",{href:"/conferences"},"Conferences",-1)),t[9]||(t[9]=g(" \xA0/\xA0 ",-1)),n("span",gM,c(e.conference?.conferenceID),1)]),n("div",vM,[n("div",null,[n("div",yM,[n("h1",{class:"paper-page-title",textContent:c(e.conference?.name)},null,8,bM),e.conference?.status?(a(),l("span",wM,[n("span",{class:A(["status-dot","status-"+e.conference?.status]),"aria-hidden":"true"},null,2),n("span",{textContent:c(e.fmt?.statusLabel(e.conference?.status))},null,8,kM)])):f("v-if",!0)]),e.conference?.url?(a(),l("p",CM,[n("a",{target:"_blank",rel:"noopener",textContent:c(e.conference?.url),href:e.safeUrl(e.conference?.url)},null,8,EM)])):f("v-if",!0)]),n("div",SM,[n("a",{class:"btn btn-outline-ink",href:e.safeUrl("/conference/"+e.conference?.conferenceID+"/edit")},[...t[10]||(t[10]=[n("svg",{class:"ui-icon mr-1","aria-hidden":"true"},[n("use",{href:"#ui-icon-edit"})],-1),g(" Edit conference",-1)])],8,NM)])]),n("div",RM,[n("span",null,[t[11]||(t[11]=g("ID ",-1)),n("b",{class:"commit-hash",textContent:c(e.conference?.conferenceID)},null,8,AM)]),n("span",null,[t[12]||(t[12]=g("Review window ",-1)),n("b",null,c(e.fmt?.date(e.conference?.startDate,"mediumDate"))+" \u2013 "+c(e.fmt?.date(e.conference?.endDate,"mediumDate")),1)]),n("span",null,[t[13]||(t[13]=g("Repositories ",-1)),n("b",null,c(e.fmt?.number(e.conference?.repositories?.length)),1)]),n("span",null,[t[14]||(t[14]=g("Plan ",-1)),n("b",{textContent:c(e.conferencePlanName(e.conference?.plan?.planID))},null,8,PM)]),e.conference?.price?(a(),l("span",DM,[t[15]||(t[15]=g("Cost so far ",-1)),n("b",null,c(e.fmt?.money(e.conference?.price)),1)])):f("v-if",!0)]),e.billingNotice?(a(),l("div",TM,[n("p",null,c(e.billingNotice),1),n("button",{type:"button",class:"btn btn-outline-ink",onClick:t[0]||(t[0]=o=>e.refreshBilling()),disabled:e.billingBusy},"Check payment status",8,OM)])):f("v-if",!0),e.billingError&&e.conference?.status!=="pending_payment"?(a(),l("p",IM,c(e.billingError),1)):f("v-if",!0),e.conference?.status==="pending_payment"?(a(),l("section",MM,[t[16]||(t[16]=n("h2",{id:"conference-payment-heading"},"Activate your review package",-1)),t[17]||(t[17]=n("p",null,"This conference is waiting for payment. Authors can join after payment is confirmed. Checkout returns to this conference. Authors within the package do not pay separately.",-1)),e.billingLoading?(a(),l("p",VM,"Loading payment options\u2026")):f("v-if",!0),e.billingError?(a(),l("p",qM,c(e.billingError),1)):f("v-if",!0),(a(!0),l(q,null,Q((e.billing?.plans||[]).filter(o=>o.id===e.conference?.plan?.planID),o=>(a(),l("div",{key:o.id},[n("p",null,[n("strong",null,c(o.name)+" package",1),g(": "+c(e.billingPrice(o))+" for up to "+c(o.repositories)+" repositories and "+c(e.billingBytes(o.storage))+" of source files during the review window. Taxes, if applicable, appear at checkout.",1)]),n("button",{type:"button",class:"btn btn-primary",onClick:r=>e.checkout(o.id,e.conference.conferenceID),disabled:e.billingBusy||e.billingPending||e.billing?.checkoutEnabled===!1},c(e.billingBusy?"Please wait\u2026":"Pay for review package"),9,_M)]))),128)),t[18]||(t[18]=n("p",null,[n("a",{href:"/profile#settings-billing"},"Manage invoices")],-1))])):f("v-if",!0),n("div",LM,[n("div",$M,[n("button",{type:"button","aria-pressed":e.confView()==="current",onClick:t[1]||(t[1]=o=>e.setConfView("current")),title:"Every repository except removed links"},"Current",8,FM),e.confCount("attention")>0||e.confView()==="attention"?(a(),l("button",{key:0,type:"button","aria-pressed":e.confView()==="attention",onClick:t[2]||(t[2]=o=>e.setConfView("attention")),"aria-label":"Needs attention "+e.confCount("attention")},[t[19]||(t[19]=n("span",{class:"dashboard-attention-prefix"},"Needs ",-1)),t[20]||(t[20]=n("span",null,"attention",-1)),t[21]||(t[21]=g()),n("span",{class:A(["attention-count",{"has-attention":e.confCount("attention")>0}])},c(e.fmt?.number(e.confCount("attention"))),3)],8,UM)):f("v-if",!0),e.confCount("removed")>0||e.confView()==="removed"?(a(),l("button",{key:1,type:"button","aria-pressed":e.confView()==="removed",onClick:t[3]||(t[3]=o=>e.setConfView("removed")),title:"Links reviewers can no longer open"},[t[22]||(t[22]=g("Removed ",-1)),n("span",zM,c(e.fmt?.number(e.confCount("removed"))),1)],8,BM)):f("v-if",!0)]),n("span",HM,c(e.search.trim()?e.fmt?.number(e.filteredRepositories?.length||0)+" shown":e.fmt?.number(e.filteredRepositories?.length||0)+((e.filteredRepositories?.length||0)===1?" repository":" repositories")),1)]),D((a(),l("form",{class:"w-100 conf-repo-toolbar","aria-label":"Filter repositories","accept-charset":"UTF-8",onSubmit:t[4]||(t[4]=ae(o=>e.submitForm(o,()=>{o.preventDefault()}),["prevent"]))},[n("div",jM,[D(n("input",GM,null,512),[[s,{state:e.viewState,set:o=>{e.search=o},value:e.search,form:null,options:{}}]])]),n("div",WM,[n("div",KM,[n("button",YM,[t[23]||(t[23]=n("span",{class:"filter-btn-label"},"Sort",-1)),n("span",XM,c({"-anonymizeDate":"Anonymize date",repoId:"ID","-status":"Status","-pageView":"Views"}[e.orderBy]||"Custom"),1)]),n("div",JM,[t[28]||(t[28]=n("h6",{class:"dropdown-header"},"Order by",-1)),n("div",QM,[D(n("input",ZM,null,512),[[s,{state:e.viewState,set:o=>{e.orderBy=o},value:e.orderBy,form:null,options:{}}]]),t[24]||(t[24]=n("label",{class:"form-check-label",for:"anonymizeDate"},"Anonymize date",-1))]),n("div",xM,[D(n("input",e6,null,512),[[s,{state:e.viewState,set:o=>{e.orderBy=o},value:e.orderBy,form:null,options:{}}]]),t[25]||(t[25]=n("label",{class:"form-check-label",for:"sortID"},"ID",-1))]),n("div",t6,[D(n("input",n6,null,512),[[s,{state:e.viewState,set:o=>{e.orderBy=o},value:e.orderBy,form:null,options:{}}]]),t[26]||(t[26]=n("label",{class:"form-check-label",for:"sortStatus"},"Status",-1))]),n("div",s6,[D(n("input",o6,null,512),[[s,{state:e.viewState,set:o=>{e.orderBy=o},value:e.orderBy,form:null,options:{}}]]),t[27]||(t[27]=n("label",{class:"form-check-label",for:"sortViews"},"Views",-1))])])])])],32)),[[i,e.viewState]]),n("div",i6,[n("div",{class:A(["paper-table paper-table-dashboard paper-table-conf w-100",{"is-removed-view":e.confView()==="removed"}]),role:"table","aria-label":"Repositories"},[t[37]||(t[37]=n("div",{class:"paper-table-head",role:"row"},[n("div",{role:"columnheader"},"Repository"),n("div",{role:"columnheader"},"Status"),n("div",{role:"columnheader",class:"num"},"Views"),n("div",{role:"columnheader"},"Expires"),n("div",{role:"columnheader"},[n("span",{class:"sr-only"},"Actions")])],-1)),(a(!0),l(q,null,Q(e.filteredRepositories,(o,r)=>(a(),l("div",{class:A(["paper-table-row",{"repo-inactive":o?.status=="expired"||o?.status=="removed","repo-error":o?.status=="error"}]),role:"row",key:o?.repoId},[n("div",r6,[t[30]||(t[30]=n("span",{class:"project-type-icon",role:"img","aria-label":"Repository",title:"Repository"},[n("svg",{class:"project-type-svg","aria-hidden":"true"},[n("use",{href:"#project-type-repo"})])],-1)),n("div",a6,[n("div",l6,[n("a",{class:"repo-name",title:o?.source?.fullName,href:e.safeUrl("/r/"+o?.repoId+"/")},[(o?.source?.fullName||"").indexOf("/")>0?(a(),l(q,{key:0},[n("span",u6,c(o.source.fullName.slice(0,o.source.fullName.indexOf("/")+1)),1),t[29]||(t[29]=n("wbr",null,null,-1)),n("span",c6,c(o.source.fullName.slice(o.source.fullName.indexOf("/")+1)),1)],64)):(a(),l(q,{key:1},[g(c(o?.source?.fullName||o?.repoId),1)],64))],8,d6)]),n("div",p6,[n("code",{class:"anonymous-id",title:o?.repoId},[(o?.repoId||"").length>14?(a(),l(q,{key:0},[n("span",h6,c(o.repoId.slice(0,-6)),1),n("span",m6,c(o.repoId.slice(-6)),1)],64)):(a(),l(q,{key:1},[g(c(o?.repoId),1)],64))],8,f6),o?.source?.commit?(a(),l("span",{key:0,class:"commit-hash",title:o.source.commit},c(o.source.commit.substring(0,7)),9,g6)):f("v-if",!0)])])]),n("div",v6,[n("div",y6,[n("div",b6,[n("span",{class:A(["status-dot","status-"+(o?.status=="error"?"error":o?.status=="ready"?"ready":o?.status=="expired"||o?.status=="removed"?o?.status:"progress")]),"aria-hidden":"true"},null,2),n("span",{class:"status-word",textContent:c(e.fmt?.statusLabel(o?.status))},null,8,w6)]),o?.status=="error"&&o?.statusMessage?(a(),l("div",{key:0,class:"status-sub status-sub-error",textContent:c(e.fmt?.statusMsg(o?.statusMessage)),title:o?.statusMessage},null,8,k6)):f("v-if",!0),o?.status=="error"?(a(),l("a",{key:1,class:"project-attention-action",href:e.safeUrl("/status/"+o?.repoId)},"View status",8,C6)):f("v-if",!0),o?.status=="expired"?(a(),l("button",{key:2,type:"button",class:"project-attention-action",onClick:ae(d=>e.extendRepo(o),["stop"]),disabled:e.extendingId===o?.repoId,title:"Reviewers can no longer open this link"},"Extend 6 months",8,E6)):f("v-if",!0),o?.anonymizeDate&&o?.status!="error"&&o?.status!="expired"?(a(),l("div",S6,"anonymized "+c(e.fmt?.humanTime(o?.anonymizeDate)),1)):f("v-if",!0)]),n("div",{class:"cell-views num",role:"cell","data-unit":(o?.pageView||0)===1?"view":"views","aria-label":e.fmt?.number(o?.pageView||0)+((o?.pageView||0)===1?" view":" views")},[t[31]||(t[31]=n("svg",{class:"project-type-svg mobile-meta-icon","aria-hidden":"true"},[n("use",{href:"#project-icon-eye"})],-1)),n("span",null,c(e.fmt?.number(o?.pageView||0)),1)],8,N6),n("div",R6,[t[33]||(t[33]=n("svg",{class:"project-type-svg mobile-meta-icon","aria-hidden":"true"},[n("use",{href:"#project-icon-clock"})],-1)),o?.status=="ready"&&(o?.options?.expirationMode==="never"||!o?.options?.expirationDate)?(a(),l("span",A6,"No expiry")):f("v-if",!0),o?.status=="ready"&&o?.options?.expirationMode!=="never"&&o?.options?.expirationDate?(a(),l("span",{key:1,textContent:c((e.fmt?.humanTime(o?.options?.expirationDate)||"").replace(/^on /,""))},null,8,P6)):f("v-if",!0),o?.status=="expired"?(a(),l("span",D6,[t[32]||(t[32]=n("span",{class:"expires-past-prefix"},"Expired ",-1)),g(c(e.fmt?.shortDate(o?.options?.expirationDate)),1)])):f("v-if",!0),o?.status!="ready"&&o?.status!="expired"?(a(),l("span",T6,"\u2014")):f("v-if",!0)])]),n("div",O6,[o?.status!="expired"&&o?.status!="removed"?(a(),l("button",{key:0,type:"button",class:"copy-url",onClick:ae(d=>e.copyRepoLink(o),["stop"]),disabled:!!e.copyingId,title:"Copy link: /r/"+o?.repoId+"/","aria-label":"Copy anonymous link for "+o?.repoId},[n("span",M6,c(e.copyingId===o?.repoId?"Link copied":""),1),(a(),l("svg",V6,[n("use",{href:e.copyingId===o?.repoId?"#ui-icon-check":"#project-icon-copy"},null,8,q6)])),n("span",_6,c(e.copyingId===o?.repoId?"Copied":"Copy link"),1)],8,I6)):f("v-if",!0),o?.status!="expired"&&o?.status!="removed"?(a(),l("a",{key:1,class:"row-edit row-open",href:e.safeUrl("/r/"+o?.repoId+"/"),target:"_blank",rel:"noopener",title:"Open what reviewers see","aria-label":"Open anonymous page for "+o?.repoId},[...t[34]||(t[34]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-external-link"})],-1)])],8,L6)):f("v-if",!0),n("div",$6,[n("button",{class:"btn btn-icon-dots",type:"button","data-toggle":"dropdown","aria-haspopup":"true","aria-expanded":"false","aria-label":"Actions for "+o?.repoId},[...t[35]||(t[35]=[n("svg",{class:"project-type-svg","aria-hidden":"true"},[n("use",{href:"#project-icon-more"})],-1)])],8,F6),n("div",U6,[n("a",{class:"dropdown-item",href:e.safeUrl("/r/"+o?.repoId+"/")},"View",8,B6),n("a",{class:"dropdown-item",href:e.safeUrl("https://github.com/"+o?.source?.fullName+"/"),target:"_blank",rel:"noopener"},"Open source on GitHub",8,z6),n("a",{class:"dropdown-item",href:e.safeUrl("/anonymize/"+o?.repoId)},"Edit",8,H6)])])])],2))),128)),e.filteredRepositories?.length==0?(a(),l("div",j6,[t[36]||(t[36]=n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#project-icon-inbox"})],-1)),e.conference?.repositories?.length?f("v-if",!0):(a(),l("span",G6,"No repository has been submitted to this conference yet.")),e.conference?.repositories?.length?(a(),l("span",W6,"Nothing matches the current filters.")):f("v-if",!0),e.conference?.repositories?.length?(a(),l("div",K6,[n("button",{type:"button",class:"btn btn-outline-ink",onClick:t[5]||(t[5]=o=>{e.search="",e.setConfView("current")})},"Clear filters")])):f("v-if",!0)])):f("v-if",!0)],2)])])])}var Y6={class:"container page paper-page conferences-page"},X6={class:"row"},J6={class:"w-100"},Q6={class:"d-flex align-items-start justify-content-between flex-wrap page-head-row page-head page-head-main",style:{gap:"12px"}},Z6={key:0,href:"/conference/new",class:"btn btn-primary"},x6={class:"search-wrap"},eV={type:"search",id:"search",class:"form-control","aria-label":"Search conferences",placeholder:"Search by name or ID\u2026",autocomplete:"off"},tV={class:"dashboard-filter-controls"},nV={class:"dropdown"},sV={class:"btn dropdown-toggle",type:"button",id:"dropdownSort","data-toggle":"dropdown","aria-haspopup":"true","aria-expanded":"false"},oV={class:"filter-btn-value"},iV={class:"dropdown-menu","aria-labelledby":"dropdownSort"},rV={class:"form-check dropdown-item"},aV={class:"form-check-input",type:"radio",name:"sort",id:"sortName",value:"name"},lV={class:"form-check dropdown-item"},dV={class:"form-check-input",type:"radio",name:"sort",id:"sortID",value:"conferenceID"},uV={class:"form-check dropdown-item"},cV={class:"form-check-input",type:"radio",name:"sort",id:"sortStatus",value:"-status"},pV={class:"dropdown"},fV={class:"btn dropdown-toggle",type:"button",id:"dropdownStatus","data-toggle":"dropdown","aria-haspopup":"true","aria-expanded":"false"},hV={key:0,class:"filter-btn-value"},mV={key:1,class:"filter-btn-value"},gV={class:"dropdown-menu","aria-labelledby":"dropdownStatus"},vV={class:"form-check dropdown-item"},yV=["id"],bV=["for"],wV={key:1,class:"dashboard-meta"},kV={class:"dashboard-count"},CV={key:0},EV={key:0},SV={key:1},NV={key:0,class:"filter-chip"},RV=["onClick","aria-label"],AV={key:0,class:"conference-feedback",role:"alert"},PV={key:1,class:"conference-feedback",role:"status"},DV={class:"paper-table paper-table-conferences w-100",role:"table","aria-label":"Conferences"},TV={class:"cell-anon",role:"cell"},OV={class:"anon-text"},IV=["textContent","href"],MV={class:"anon-sub"},VV={class:"anon-source"},qV=["textContent"],_V={key:0},LV=["textContent","href"],$V={class:"cell-status",role:"cell"},FV={class:"status-line"},UV=["textContent"],BV={class:"cell-views num",role:"cell"},zV=["textContent"],HV={class:"cell-expires",role:"cell"},jV={key:0},GV={key:1,class:"empty-dash","aria-label":"No review window"},WV={class:"cell-actions",role:"cell"},KV={class:"dropdown"},YV=["disabled","aria-label"],XV={class:"dropdown-menu dropdown-menu-right"},JV=["href"],QV=["href"],ZV={key:0},xV=["onClick"],eq={key:0,class:"paper-table-empty"},tq={key:0,class:"empty-icon","aria-hidden":"true"},nq={key:1,class:"ui-icon","aria-hidden":"true"},sq={key:3},oq={class:"paper-table-empty-actions"},iq={key:0,href:"/conference/new",class:"btn btn-primary conf-empty-new"};function cp(e,t){let s=Pe("field"),i=Pe("form");return a(),l("div",Y6,[n("div",X6,[n("div",J6,[n("div",Q6,[t[4]||(t[4]=n("div",null,[n("h1",{class:"paper-page-title"},[g("Your "),n("em",null,"conferences")]),n("p",{class:"paper-page-lede"},"Group anonymizations by venue, give chairs a shared dashboard, and set one expiry for every submission.")],-1)),e.conferences&&e.conferences.length==0?f("v-if",!0):(a(),l("a",Z6,[...t[3]||(t[3]=[n("svg",{class:"ui-icon mr-1","aria-hidden":"true"},[n("use",{href:"#project-icon-plus"})],-1),g(" New conference ",-1)])]))]),e.conferences?.length>0?D((a(),l("form",{key:0,class:"w-100 dashboard-filter-row","aria-label":"Filter conferences","accept-charset":"UTF-8",onSubmit:t[0]||(t[0]=ae(o=>e.submitForm(o,()=>{o.preventDefault()}),["prevent"]))},[n("div",x6,[D(n("input",eV,null,512),[[s,{state:e.viewState,set:o=>{e.search=o},value:e.search,form:null,options:{}}]])]),n("div",tV,[n("div",nV,[n("button",sV,[t[5]||(t[5]=n("span",{class:"filter-btn-label"},"Sort",-1)),n("span",oV,c({name:"Name",conferenceID:"ID","-status":"Status"}[e.orderBy]||"Custom"),1)]),n("div",iV,[t[9]||(t[9]=n("h6",{class:"dropdown-header"},"Order by",-1)),n("div",rV,[D(n("input",aV,null,512),[[s,{state:e.viewState,set:o=>{e.orderBy=o},value:e.orderBy,form:null,options:{}}]]),t[6]||(t[6]=n("label",{class:"form-check-label",for:"sortName"},"Name",-1))]),n("div",lV,[D(n("input",dV,null,512),[[s,{state:e.viewState,set:o=>{e.orderBy=o},value:e.orderBy,form:null,options:{}}]]),t[7]||(t[7]=n("label",{class:"form-check-label",for:"sortID"},"ID",-1))]),n("div",uV,[D(n("input",cV,null,512),[[s,{state:e.viewState,set:o=>{e.orderBy=o},value:e.orderBy,form:null,options:{}}]]),t[8]||(t[8]=n("label",{class:"form-check-label",for:"sortStatus"},"Status",-1))])])]),n("div",pV,[n("button",fV,[t[10]||(t[10]=n("span",{class:"filter-btn-label"},"Status",-1)),e.filters?.status?.ready&&e.filters?.status?.expired&&e.filters?.status?.removed?(a(),l("span",hV,"All")):f("v-if",!0),e.filters?.status?.ready&&e.filters?.status?.expired&&e.filters?.status?.removed?f("v-if",!0):(a(),l("span",mV,c((e.filters?.status?.ready?0:1)+(e.filters?.status?.expired?0:1)+(e.filters?.status?.removed?0:1))+" hidden ",1))]),n("div",gV,[t[11]||(t[11]=n("h6",{class:"dropdown-header"},"Show statuses",-1)),(a(!0),l(q,null,Q(e.statusLabels,(o,r,d)=>(a(),l("div",vV,[D(n("input",{class:"form-check-input",type:"checkbox",id:"status-"+r},null,8,yV),[[s,{state:e.viewState,set:p=>{e.filters.status[r]=p},value:e.filters?.status[r],form:null,options:{}}]]),n("label",{class:"form-check-label",for:"status-"+r},c(o),9,bV)]))),256))])])])],32)),[[i,e.viewState]]):f("v-if",!0),e.conferences?.length>0?(a(),l("div",wV,[n("span",kV,[e.filteredConferences?.length===e.conferences?.length?(a(),l("span",CV,[g(c(e.fmt?.number(e.conferences?.length))+" conference",1),e.conferences?.length!==1?(a(),l("span",EV,"s")):f("v-if",!0)])):f("v-if",!0),e.filteredConferences?.length!==e.conferences?.length?(a(),l("span",SV,c(e.fmt?.number(e.filteredConferences?.length))+" of "+c(e.fmt?.number(e.conferences?.length))+" shown",1)):f("v-if",!0)]),(a(!0),l(q,null,Q(e.filters?.status,(o,r,d)=>(a(),l(q,null,[o===!1?(a(),l("span",NV,[g(" Hiding "+c(e.statusLabels[r])+" ",1),n("button",{type:"button",class:"filter-chip-close",onClick:p=>{e.filters.status[r]=!0},"aria-label":"Show "+e.statusLabels[r]+" again"},"\xD7",8,RV)])):f("v-if",!0)],64))),256))])):f("v-if",!0)]),e.error?(a(),l("div",AV,[n("span",null,c(e.error),1),n("button",{type:"button",class:"btn btn-outline-ink",onClick:t[1]||(t[1]=o=>e.loadConferences())},"Retry")])):f("v-if",!0),e.loading?(a(),l("div",PV,"Loading conferences\u2026")):f("v-if",!0),n("div",DV,[t[28]||(t[28]=n("div",{class:"paper-table-head",role:"row"},[n("div",{role:"columnheader"},"Conference"),n("div",{role:"columnheader"},"Status"),n("div",{role:"columnheader",class:"num"},"Repos"),n("div",{role:"columnheader"},"Review window"),n("div",{role:"columnheader"},[n("span",{class:"sr-only"},"Actions")])],-1)),(a(!0),l(q,null,Q(e.filteredConferences,(o,r)=>(a(),l("div",{class:A(["paper-table-row row-clickable",{"repo-inactive":o?.status=="expired"||o?.status=="removed"}]),role:"row",key:o?.conferenceID},[n("div",TV,[t[14]||(t[14]=n("svg",{class:"ui-icon record-type-icon",role:"img","aria-label":"Conference"},[n("use",{href:"#project-icon-conference"})],-1)),n("div",OV,[n("a",{class:"repo-name",textContent:c(o?.name),href:e.safeUrl("/conference/"+o?.conferenceID)},null,8,IV),n("div",MV,[n("span",VV,[t[13]||(t[13]=g("ID ",-1)),n("span",{class:"commit-hash",textContent:c(o?.conferenceID)},null,8,qV),o?.url?(a(),l("span",_V,[t[12]||(t[12]=g(" \xB7 ",-1)),n("a",{target:"_blank",rel:"noopener",textContent:c(e.fmt?.limitTo(o?.url,60)),href:e.safeUrl(o?.url)},null,8,LV)])):f("v-if",!0)])])])]),n("div",$V,[n("div",FV,[n("span",{class:A(["status-dot","status-"+o?.status]),"aria-hidden":"true"},null,2),n("span",{class:"status-word",textContent:c(e.fmt?.statusLabel(o?.status))},null,8,UV)])]),n("div",BV,[t[15]||(t[15]=n("svg",{class:"ui-icon mobile-meta-icon","aria-hidden":"true"},[n("use",{href:"#project-type-repo"})],-1)),t[16]||(t[16]=g()),n("span",{textContent:c(e.fmt?.number(o?.nbRepositories||0))},null,8,zV)]),n("div",HV,[t[17]||(t[17]=n("svg",{class:"ui-icon mobile-meta-icon","aria-hidden":"true"},[n("use",{href:"#project-icon-clock"})],-1)),o?.startDate?(a(),l("span",jV,c(e.fmt?.date(o?.startDate,"mediumDate"))+" \u2013 "+c(e.fmt?.date(o?.endDate,"mediumDate")),1)):f("v-if",!0),o?.startDate?f("v-if",!0):(a(),l("span",GV,"\u2014"))]),n("div",WV,[n("div",KV,[n("button",{class:"btn btn-icon-dots",type:"button","data-toggle":"dropdown","aria-haspopup":"true","aria-expanded":"false",disabled:o?.removing,"aria-label":"Actions for "+o?.name},[...t[18]||(t[18]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#project-icon-more"})],-1)])],8,YV),n("div",XV,[n("a",{class:"dropdown-item",href:e.safeUrl("/conference/"+o?.conferenceID+"/")},[...t[19]||(t[19]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#project-icon-eye"})],-1),g(" View ",-1)])],8,JV),n("a",{class:"dropdown-item",href:e.safeUrl("/conference/"+o?.conferenceID+"/edit")},[...t[20]||(t[20]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-edit"})],-1),g(" Edit ",-1)])],8,QV),o?.status!="removed"?(a(),l("div",ZV,[t[22]||(t[22]=n("div",{class:"dropdown-divider"},null,-1)),n("button",{type:"button",class:"dropdown-item dropdown-item-danger",onClick:d=>e.removeConference(o)},[...t[21]||(t[21]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-trash"})],-1),g(" Remove ",-1)])],8,xV)])):f("v-if",!0)])])])],2))),128)),!e.loading&&!e.error&&e.filteredConferences?.length==0?(a(),l("div",eq,[e.conferences?.length==0?(a(),l("span",tq,[...t[23]||(t[23]=[n("svg",{class:"ui-icon"},[n("use",{href:"#project-icon-conference"})],-1)])])):f("v-if",!0),e.conferences?.length>0?(a(),l("svg",nq,[...t[24]||(t[24]=[n("use",{href:"#project-icon-inbox"},null,-1)])])):f("v-if",!0),e.conferences?.length==0?(a(),l(q,{key:2},[t[25]||(t[25]=n("strong",{class:"empty-title"},"No conferences yet",-1)),t[26]||(t[26]=n("span",null,"Create one to group submissions for a venue, share a dashboard with chairs, and set a single expiry date.",-1))],64)):f("v-if",!0),e.conferences?.length>0?(a(),l("span",sq,"Nothing matches the current filters.")):f("v-if",!0),n("div",oq,[e.conferences?.length==0?(a(),l("a",iq,[...t[27]||(t[27]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#project-icon-plus"})],-1),g(" New conference",-1)])])):f("v-if",!0),e.conferences?.length>0?(a(),l("button",{key:1,type:"button",class:"btn btn-outline-ink",onClick:t[2]||(t[2]=o=>{e.search="",e.filters.status.ready=!0,e.filters.status.expired=!0,e.filters.status.removed=!0})},"Clear filters")):f("v-if",!0)])])):f("v-if",!0)])])])}var rq={class:"container page dashboard-page paper-page"},aq={class:"row"},lq={class:"w-100"},dq={class:"dashboard-heading page-head page-head-main"},uq={class:"dashboard-title-line"},cq={key:0,class:"dashboard-count-head","aria-hidden":"true"},pq={key:0},fq={class:"dashboard-heading-actions"},hq=["open"],mq=["aria-expanded"],gq=["stroke-dasharray"],vq={key:1,d:"M7 12c0-4 4-4 5 0s5 4 5 0-4-4-5 0-5 4-5 0",class:"quota-ring-unlimited"},yq={key:0,class:"quota-summary-value"},bq={key:0},wq={class:"quota-panel",id:"dashboard-usage"},kq={class:"quota-panel-heading"},Cq={key:1,class:"quota-loading",role:"status"},Eq={key:0,class:"dashboard-meta"},Sq={key:0,class:"dashboard-view-tabs",role:"group","aria-label":"Project view"},Nq=["aria-pressed"],Rq=["aria-pressed","aria-label"],Aq=["aria-pressed","aria-label"],Pq={key:0,class:"attention-count"},Dq={key:0},Tq={key:0},Oq={key:1},Iq={class:"search-wrap"},Mq={type:"search",id:"search",class:"form-control","aria-label":"Search anonymizations",placeholder:"Search projects\u2026",autocomplete:"off"},Vq=["aria-expanded"],qq={class:"btn-group",role:"group","aria-label":"Type"},_q=["aria-pressed"],Lq=["aria-pressed"],$q=["aria-pressed"],Fq=["aria-pressed"],Uq={class:"dropdown"},Bq={class:"btn dropdown-toggle",type:"button",id:"dropdownSort","data-toggle":"dropdown","aria-haspopup":"true","aria-expanded":"false"},zq={class:"filter-btn-value"},Hq={class:"sr-only"},jq={class:"dropdown-menu","aria-labelledby":"dropdownSort"},Gq={class:"form-check dropdown-item"},Wq=["onClick","checked","id"],Kq=["for"],Yq=["inert"],Xq={class:"btn dropdown-toggle",type:"button",id:"dropdownStatus","data-toggle":"dropdown","aria-haspopup":"true","aria-expanded":"false"},Jq={class:"filter-btn-value"},Qq={class:"dropdown-menu","aria-labelledby":"dropdownStatus"},Zq={key:0,class:"form-check dropdown-item"},xq=["id"],e_=["for"],t_={key:1,class:"dashboard-active-filters dashboard-active-filters-row"},n_=["onClick","aria-label","title"],s_=["aria-busy"],o_={class:"paper-table-head",role:"row"},i_=["aria-sort"],r_=["aria-sort"],a_=["aria-sort"],l_=["aria-sort"],d_={key:0,class:"paper-table-row paper-table-skeleton",role:"row","aria-hidden":"true"},u_=["onClick"],c_={class:"cell-anon",role:"cell"},p_=["aria-label","title"],f_={class:"project-type-svg","aria-hidden":"true"},h_=["href"],m_={class:"anon-text"},g_={class:"anon-title"},v_=["title","href"],y_={class:"rn-owner"},b_={class:"rn-repo"},w_={key:1,class:"repo-name repo-name-static"},k_={class:"rn-owner"},C_={class:"rn-repo"},E_={key:2,class:"type-badge type-coauthor",title:"You are a co-author on this anonymization"},S_={key:0,class:"anon-sub"},N_=["title"],R_={class:"id-head"},A_={class:"id-tail"},P_=["title"],D_=["title"],T_=["textContent"],O_={class:"dashboard-row-meta",role:"presentation"},I_={class:"cell-status",role:"cell"},M_={class:"status-line"},V_=["textContent"],q_=["onClick"],__=["textContent","title"],L_=["title"],$_=["href"],F_={key:3,class:"status-action-line"},U_={key:0,class:"status-stuck"},B_=["onClick","data-project-actions","aria-controls","aria-expanded"],z_=["onClick"],H_={key:5,class:"status-sub status-sub-date status-sub-removed"},j_={key:6,class:"status-sub status-sub-date"},G_=["data-unit","aria-label"],W_={class:"cell-expires",role:"cell"},K_={key:0,class:"expires-never"},Y_=["textContent"],X_=["title"],J_={key:3,class:"expires-past"},Q_={key:4,class:"expires-past"},Z_={key:5,class:"empty-dash","aria-label":"Not applicable"},x_={class:"cell-actions",role:"cell"},eL=["onClick","disabled","title","aria-label"],tL={class:"sr-only","aria-live":"polite"},nL={class:"project-type-svg","aria-hidden":"true"},sL=["href"],oL={class:"copy-url-label","aria-hidden":"true"},iL=["href","aria-label"],rL=["href","title","aria-label"],aL=["title","aria-label"],lL=["title","aria-label"],dL=["aria-label"],uL={key:6,class:"dropdown is-disabled"},cL=["aria-label"],pL={key:7,class:"dropdown"},fL=["data-project-actions","aria-label"],hL={class:"dropdown-menu dropdown-menu-right"},mL=["onClick","aria-controls","aria-expanded"],gL=["href"],vL=["href"],yL=["onClick","disabled"],bL=["href"],wL=["onClick"],kL=["onClick"],CL=["onClick"],EL={key:5},SL=["onClick"],NL={key:1,class:"project-details-row",role:"row"},RL=["id","onKeydown"],AL={class:"project-details-heading"},PL=["onClick"],DL={class:"project-details-list"},TL={key:0},OL={key:1},IL={key:0},ML={key:2},VL={key:0,class:"project-progress-help"},qL=["href"],_L=["onSubmit"],LL=["for"],$L=["id"],FL={class:"project-name-controls"},UL=["id","aria-describedby","disabled"],BL=["disabled"],zL={key:0,class:"project-name-error",role:"alert"},HL={key:1,role:"status"},jL={key:0,class:"paper-table-empty"},GL={key:0},WL={key:1},KL={class:"paper-table-empty-actions"},YL={key:1,href:"/anonymize",class:"btn btn-ink"},XL={key:0,class:"dashboard-pagination"},JL={key:0,role:"alert"},QL=["disabled"];function pp(e,t){let s=Xe("quota-usage"),i=Pe("field"),o=Pe("form");return a(),l("div",rq,[n("div",aq,[n("div",lq,[n("div",dq,[n("div",null,[n("div",uq,[t[27]||(t[27]=n("h1",{class:"paper-page-title"},"My work",-1)),!e.loading&&e.isPlainView()?(a(),l("span",cq,[g(c(e.fmt?.number(e.dashboardTotals?.filtered??e.filteredItems?.length))+" project",1),(e.dashboardTotals?.filtered??e.filteredItems?.length)!==1?(a(),l("span",pq,"s")):f("v-if",!0)])):f("v-if",!0)]),t[28]||(t[28]=n("p",{class:"paper-page-lede"},"Manage your anonymous links.",-1))]),n("div",fq,[n("details",{class:"dashboard-quota",open:e.quotaExpanded,onToggle:t[1]||(t[1]=r=>e.quotaExpanded=r.target.open),onKeydown:t[2]||(t[2]=kt(ae(r=>e.closeQuota(),["prevent","stop"]),["esc"]))},[n("summary",{"aria-controls":"dashboard-usage","aria-expanded":e.quotaExpanded,class:A(e.quota?"quota-level-"+e.quota.repository.level:""),style:Ie(e.quota&&!e.quota.repository.unlimited?{"--quota-pct":e.quota.repository.percent+"%"}:null)},[(a(),l("svg",{class:A(["quota-summary-ring",e.quota?"quota-"+e.quota.repository.level:""]),viewBox:"0 0 24 24","aria-hidden":"true"},[t[29]||(t[29]=n("circle",{class:"quota-ring-track",cx:"12",cy:"12",r:"9"},null,-1)),e.quota&&!e.quota.repository.unlimited?(a(),l("circle",{key:0,class:"quota-ring-fill",cx:"12",cy:"12",r:"9",pathLength:"100","stroke-dasharray":e.quota.repository.percent+" 100"},null,8,gq)):f("v-if",!0),e.quota?.repository.unlimited?(a(),l("path",vq)):f("v-if",!0)],2)),t[31]||(t[31]=n("span",{class:"quota-summary-label"},"Usage",-1)),e.quota?(a(),l("span",yq,[g(c(e.fmt.number(e.quota.repository.used)),1),e.quota.repository.unlimited?f("v-if",!0):(a(),l("span",bq," / "+c(e.fmt.number(e.quota.repository.total)),1)),t[30]||(t[30]=g(" repos",-1))])):f("v-if",!0),t[32]||(t[32]=n("svg",{class:"project-type-svg quota-summary-chevron","aria-hidden":"true"},[n("use",{href:"#project-icon-chevron"})],-1))],14,mq),n("div",wq,[n("div",kq,[t[34]||(t[34]=n("h2",null,"Account usage",-1)),n("button",{type:"button",class:"project-close","aria-label":"Close usage",onClick:t[0]||(t[0]=r=>e.closeQuota())},[...t[33]||(t[33]=[n("svg",{class:"project-type-svg","aria-hidden":"true"},[n("use",{href:"#project-icon-close"})],-1)])])]),e.quota?(a(),Wt(s,{key:0,quota:e.quota,fmt:e.fmt},null,8,["quota","fmt"])):(a(),l("p",Cq,"Loading usage\u2026"))])],40,hq),t[35]||(t[35]=Ce('New anonymization',1))])]),f(" Result count + active filter chips "),e.loading?f("v-if",!0):(a(),l("div",Eq,[e.showViewTabs()?(a(),l("div",Sq,[n("button",{type:"button","aria-pressed":e.statusView()==="active",onClick:t[3]||(t[3]=r=>e.setStatusView("active")),title:"Every project except removed links"},"Current",8,Nq),e.attentionCount()>0||e.statusView()==="attention"?(a(),l("button",{key:0,type:"button","aria-pressed":e.statusView()==="attention",onClick:t[4]||(t[4]=r=>e.setStatusView("attention")),"aria-label":"Needs attention "+e.attentionCount()},[t[36]||(t[36]=n("span",{class:"dashboard-attention-prefix"},"Needs ",-1)),t[37]||(t[37]=n("span",null,"attention",-1)),t[38]||(t[38]=g()),n("span",{class:A(["attention-count",{"has-attention":e.attentionCount()>0}])},c(e.attentionCount()),3)],8,Rq)):f("v-if",!0),e.removedCount>0||e.statusView()==="removed"||e.removedCount==null&&e.dashboardTotals?.total>e.dashboardTotals?.filtered?(a(),l("button",{key:1,type:"button","aria-pressed":e.statusView()==="removed",onClick:t[5]||(t[5]=r=>e.setStatusView("removed")),"aria-label":"Removed "+(e.removedCount??""),title:"Links reviewers can no longer open"},[t[39]||(t[39]=g("Removed ",-1)),e.removedCount!=null?(a(),l("span",Pq,c(e.fmt?.number(e.removedCount)),1)):f("v-if",!0)],8,Aq)):f("v-if",!0)])):f("v-if",!0),n("span",{class:A(["dashboard-count",{"is-plain":e.isPlainView()}])},[e.isPlainView()?(a(),l("span",Dq,[g(c(e.fmt?.number(e.dashboardTotals?.filtered??e.filteredItems?.length))+" project",1),(e.dashboardTotals?.filtered??e.filteredItems?.length)!==1?(a(),l("span",Tq,"s")):f("v-if",!0)])):(a(),l("span",Oq,c(e.fmt?.number(e.dashboardTotals?.filtered??e.filteredItems?.length))+" shown",1))],2)])),f(" Search + filters "),D((a(),l("form",{class:"w-100 dashboard-filter-row","aria-label":"Filter anonymizations","accept-charset":"UTF-8",onSubmit:t[13]||(t[13]=ae(r=>e.submitForm(r,()=>{r.preventDefault()}),["prevent"]))},[n("div",Iq,[D(n("input",Mq,null,512),[[i,{state:e.viewState,set:r=>{e.search=r},value:e.search,form:null,options:{}}]])]),n("button",{class:"btn dashboard-filters-toggle",type:"button","aria-expanded":e.filtersExpanded,"aria-controls":"dashboard-filter-controls",onClick:t[6]||(t[6]=r=>e.filtersExpanded=!e.filtersExpanded)},[...t[40]||(t[40]=[g("Filters",-1),n("svg",{class:"project-type-svg","aria-hidden":"true"},[n("use",{href:"#project-icon-filter"})],-1)])],8,Vq),n("div",{id:"dashboard-filter-controls",class:A(["dashboard-filter-controls",{expanded:e.filtersExpanded}])},[n("div",qq,[n("button",{type:"button",class:A(["btn",{"btn-primary":e.typeFilter==="all"}]),onClick:t[7]||(t[7]=r=>e.typeFilter="all"),"aria-pressed":e.typeFilter==="all"},"All",10,_q),n("button",{type:"button",class:A(["btn dashboard-type-filter",{"btn-primary":e.typeFilter==="repo"}]),title:"Repositories",onClick:t[8]||(t[8]=r=>e.typeFilter="repo"),"aria-pressed":e.typeFilter==="repo"},[...t[41]||(t[41]=[n("svg",{class:"project-type-svg","aria-hidden":"true"},[n("use",{href:"#project-type-repo"})],-1),n("span",{class:"type-filter-label"},"Repos",-1)])],10,Lq),n("button",{type:"button",class:A(["btn dashboard-type-filter",{"btn-primary":e.typeFilter==="pr"}]),title:"Pull requests",onClick:t[9]||(t[9]=r=>e.typeFilter="pr"),"aria-pressed":e.typeFilter==="pr"},[...t[42]||(t[42]=[n("svg",{class:"project-type-svg","aria-hidden":"true"},[n("use",{href:"#project-type-pr"})],-1),n("span",{class:"type-filter-label"},"PRs",-1)])],10,$q),n("button",{type:"button",class:A(["btn dashboard-type-filter",{"btn-primary":e.typeFilter==="gist"}]),title:"Gists",onClick:t[10]||(t[10]=r=>e.typeFilter="gist"),"aria-pressed":e.typeFilter==="gist"},[...t[43]||(t[43]=[n("svg",{class:"project-type-svg","aria-hidden":"true"},[n("use",{href:"#project-type-gist"})],-1),n("span",{class:"type-filter-label"},"Gists",-1)])],10,Fq)]),n("div",{id:"dashboard-extra-filters",class:A(["dashboard-extra-filters",{expanded:e.filtersExpanded}])},[n("div",Uq,[n("button",Bq,[t[45]||(t[45]=n("span",{class:"filter-btn-label"},"Sort",-1)),n("span",zq,c(e.sortLabel()),1),(a(),l("svg",{class:A(["project-type-svg sort-direction",{ascending:!e.sortDesc()}]),"aria-hidden":"true"},[...t[44]||(t[44]=[n("use",{href:"#project-icon-arrow"},null,-1)])],2)),n("span",Hq,c(e.sortDesc()?"descending":"ascending"),1)]),n("div",jq,[t[46]||(t[46]=n("h6",{class:"dropdown-header"},"Order by",-1)),(a(!0),l(q,null,Q(e.sortFields,(r,d,p)=>(a(),l("div",Gq,[n("input",{class:"form-check-input",type:"radio",name:"sort",onClick:u=>e.setSort(d,r.defaultDesc),checked:e.isSortedBy(d),id:"sort-"+p},null,8,Wq),n("label",{class:"form-check-label",for:"sort-"+p},c(r?.label),9,Kq)]))),256)),t[47]||(t[47]=n("div",{class:"dropdown-divider"},null,-1)),n("button",{type:"button",class:"dropdown-item",onClick:t[11]||(t[11]=r=>e.toggleSortDirection())},c(e.sortDesc()?"Switch to ascending":"Switch to descending"),1)])]),n("div",{class:A(["dropdown dashboard-status-filter",{"is-view-hidden":e.statusView()==="removed"}]),inert:e.statusView()==="removed"?!0:null},[n("button",Xq,[t[48]||(t[48]=n("span",{class:"filter-btn-label"},"Status",-1)),n("span",Jq,c(e.statusChipKeys().length===0?"Any":e.statusChipKeys().length===1?"Hiding "+(e.statusKeyLabels[e.statusChipKeys()[0]]||"").toLowerCase():e.statusChipKeys().length+" hidden"),1)]),n("div",Qq,[t[49]||(t[49]=n("h6",{class:"dropdown-header"},"Show statuses",-1)),n("button",{type:"button",class:A(["dropdown-item status-preset",{active:e.statusChipKeys().length===0}]),onClick:t[12]||(t[12]=r=>e.statusChipKeys().forEach(d=>{e.filters.status[d]=!0}))},"Any status",2),t[50]||(t[50]=n("div",{class:"dropdown-divider"},null,-1)),(a(!0),l(q,null,Q(e.statusKeyLabels,(r,d,p)=>(a(),l(q,{key:d},[d!=="removed"?(a(),l("div",Zq,[D(n("input",{class:"form-check-input",type:"checkbox",id:"status-"+d},null,8,xq),[[i,{state:e.viewState,set:u=>{e.filters.status[d]=u},value:e.filters?.status[d],form:null,options:{}}]]),n("label",{class:"form-check-label",for:"status-"+d},c(r),9,e_)])):f("v-if",!0)],64))),128))])],10,Yq)],2)],2)],32)),[[o,e.viewState]]),!e.loading&&e.showClearFilters()?(a(),l("div",t_,[(a(!0),l(q,null,Q(e.statusChipKeys(),r=>(a(),l("button",{key:r,type:"button",class:"filter-chip",onClick:d=>e.filters.status[r]=!0,"aria-label":"Show "+e.statusKeyLabels[r]+" again",title:"Show "+e.statusKeyLabels[r]+" again"},[g("Hiding "+c((e.statusKeyLabels[r]||"").toLowerCase()),1),t[51]||(t[51]=n("svg",{class:"project-type-svg","aria-hidden":"true"},[n("use",{href:"#project-icon-close"})],-1))],8,n_))),128)),e.typeFilter!=="all"?(a(),l("button",{key:0,type:"button",class:"filter-chip",onClick:t[14]||(t[14]=r=>e.typeFilter="all"),"aria-label":"Show all project types"},[g(c(e.typeFilter==="repo"?"Repositories":e.typeFilter==="pr"?"Pull requests":"Gists"),1),t[52]||(t[52]=n("svg",{class:"project-type-svg","aria-hidden":"true"},[n("use",{href:"#project-icon-close"})],-1))])):f("v-if",!0),e.showClearFilters()?(a(),l("button",{key:1,type:"button",class:"btn-link-inline",onClick:t[15]||(t[15]=r=>e.clearFilters())},"Clear filters")):f("v-if",!0)])):f("v-if",!0)]),f(" Table "),n("div",{class:A(["paper-table paper-table-dashboard",{"is-removed-view":e.statusView()==="removed"}]),role:"table","aria-label":"Anonymizations","aria-busy":e.loading},[n("div",o_,[n("div",{role:"columnheader","aria-sort":e.isSortedBy("_label")?e.sortDesc()?"descending":"ascending":"none"},[n("button",{type:"button",class:A(["sortable",{active:e.isSortedBy("_label")}]),onClick:t[16]||(t[16]=r=>e.setSort("_label"))},[t[54]||(t[54]=g(" Project ",-1)),e.isSortedBy("_label")?(a(),l("svg",{key:0,class:A(["project-type-svg sort-direction",{ascending:!e.sortDesc()}]),"aria-hidden":"true"},[...t[53]||(t[53]=[n("use",{href:"#project-icon-arrow"},null,-1)])],2)):f("v-if",!0)],2)],8,i_),n("div",{role:"columnheader","aria-sort":e.isSortedBy("status")?e.sortDesc()?"descending":"ascending":"none"},[n("button",{type:"button",class:A(["sortable",{active:e.isSortedBy("status")}]),onClick:t[17]||(t[17]=r=>e.setSort("status"))},[t[56]||(t[56]=g(" Status ",-1)),e.isSortedBy("status")?(a(),l("svg",{key:0,class:A(["project-type-svg sort-direction",{ascending:!e.sortDesc()}]),"aria-hidden":"true"},[...t[55]||(t[55]=[n("use",{href:"#project-icon-arrow"},null,-1)])],2)):f("v-if",!0)],2)],8,r_),n("div",{role:"columnheader",class:"num","aria-sort":e.isSortedBy("pageView")?e.sortDesc()?"descending":"ascending":"none"},[n("button",{type:"button",class:A(["sortable",{active:e.isSortedBy("pageView")}]),onClick:t[18]||(t[18]=r=>e.setSort("pageView"))},[t[58]||(t[58]=g(" Views ",-1)),e.isSortedBy("pageView")?(a(),l("svg",{key:0,class:A(["project-type-svg sort-direction",{ascending:!e.sortDesc()}]),"aria-hidden":"true"},[...t[57]||(t[57]=[n("use",{href:"#project-icon-arrow"},null,-1)])],2)):f("v-if",!0)],2)],8,a_),n("div",{role:"columnheader","aria-sort":e.isSortedBy("options.expirationDate")?e.sortDesc()?"descending":"ascending":"none"},[n("button",{type:"button",class:A(["sortable",{active:e.isSortedBy("options.expirationDate")}]),onClick:t[19]||(t[19]=r=>e.setSort("options.expirationDate"))},[t[60]||(t[60]=g(" Expires ",-1)),e.isSortedBy("options.expirationDate")?(a(),l("svg",{key:0,class:A(["project-type-svg sort-direction",{ascending:!e.sortDesc()}]),"aria-hidden":"true"},[...t[59]||(t[59]=[n("use",{href:"#project-icon-arrow"},null,-1)])],2)):f("v-if",!0)],2)],8,l_),t[61]||(t[61]=n("div",{role:"columnheader",class:"col-link"},[n("span",{class:"sr-only"},"Actions")],-1))]),f(" Loading skeleton: keeps the layout stable while the three lists load "),(a(),l(q,null,Q([1,2,3,4],(r,d)=>(a(),l(q,null,[e.loading?(a(),l("div",d_,[...t[62]||(t[62]=[n("div",{class:"cell-anon",role:"cell"},[n("span",{class:"skeleton skeleton-badge"}),n("div",{class:"anon-text"},[n("span",{class:"skeleton skeleton-line",style:{width:"38%"}}),n("span",{class:"skeleton skeleton-line skeleton-line-sm",style:{width:"56%"}})])],-1),n("div",{class:"cell-status",role:"cell"},[n("span",{class:"skeleton skeleton-line",style:{width:"60%"}})],-1),n("div",{class:"cell-views num",role:"cell"},[n("span",{class:"skeleton skeleton-line",style:{width:"40%"}})],-1),n("div",{class:"cell-expires",role:"cell"},[n("span",{class:"skeleton skeleton-line",style:{width:"55%"}})],-1),n("div",{class:"cell-actions",role:"cell"},null,-1)])])):f("v-if",!0)],64))),64)),(a(!0),l(q,null,Q(e.filteredItems,(r,d)=>(a(),l(q,{key:r?._type+":"+(r?._id||d)},[e.loading?f("v-if",!0):(a(),l("div",{key:0,class:A(["paper-table-row",{"repo-inactive":r?._statusKey=="expired"||r?._statusKey=="removed","repo-error":r?.status=="error","row-clickable":!!r?._viewUrl}]),role:"row",onClick:p=>e.openItem(r,p)},[n("div",c_,[n("span",{class:"project-type-icon",role:"img","aria-label":r?._type==="repo"?"Repository":r?._type==="pr"?"Pull request":"Gist",title:r?._type==="repo"?"Repository":r?._type==="pr"?"Pull request":"Gist"},[(a(),l("svg",f_,[n("use",{href:"#project-type-"+r._type},null,8,h_)]))],8,p_),n("div",m_,[n("div",g_,[r?._viewUrl?(a(),l("a",{key:0,class:"repo-name",title:r._label,href:e.safeUrl(r?._viewUrl)},[(r?._label||"").indexOf("/")>0?(a(),l(q,{key:0},[n("span",y_,c(r._label.slice(0,r._label.indexOf("/")+1)),1),t[63]||(t[63]=n("wbr",null,null,-1)),n("span",b_,c(r._label.slice(r._label.indexOf("/")+1)),1)],64)):(a(),l(q,{key:1},[g(c(r?._label),1)],64))],8,v_)):f("v-if",!0),r?._viewUrl?f("v-if",!0):(a(),l("span",w_,[(r?._label||"").indexOf("/")>0?(a(),l(q,{key:0},[n("span",k_,c(r._label.slice(0,r._label.indexOf("/")+1)),1),t[64]||(t[64]=n("wbr",null,null,-1)),n("span",C_,c(r._label.slice(r._label.indexOf("/")+1)),1)],64)):(a(),l(q,{key:1},[g(c(r?._label),1)],64))])),r?.role==="coauthor"?(a(),l("span",E_,"Co-author")):f("v-if",!0)]),r?._id||r?._type==="repo"&&r?.source?.commit||r?.conference?(a(),l("div",S_,[r?._id?(a(),l("code",{key:0,class:"anonymous-id",title:r._id},[r._id.length>14?(a(),l(q,{key:0},[n("span",R_,c(r._id.slice(0,-6)),1),n("span",A_,c(r._id.slice(-6)),1)],64)):(a(),l(q,{key:1},[g(c(r._id),1)],64))],8,N_)):f("v-if",!0),r?._type==="repo"&&r?.source?.commit?(a(),l("span",{key:1,class:"commit-hash",title:r.source.commit},c(r.source.commit.substring(0,7)),9,P_)):f("v-if",!0),r?.conference?(a(),l("span",{key:2,class:"cell-conf conf-tag",title:"Conference: "+r.conference},[t[65]||(t[65]=n("svg",{class:"project-type-svg","aria-hidden":"true"},[n("use",{href:"#project-icon-conference"})],-1)),n("span",{class:"conf-name",textContent:c(r?.conference)},null,8,T_)],8,D_)):f("v-if",!0)])):f("v-if",!0)])]),n("div",O_,[n("div",I_,[n("div",M_,[n("span",{class:A(["status-dot","status-"+r?._statusKey]),"aria-hidden":"true"},null,2),n("span",{class:"status-word",textContent:c(e.fmt?.statusLabel(r?.status))},null,8,V_),r?.status=="removed"?(a(),l(q,{key:0},[t[66]||(t[66]=n("span",{class:"seg-sep status-removed-sep","aria-hidden":"true"},"\xB7",-1)),n("button",{type:"button",class:"project-attention-action status-enable",onClick:ae(p=>e.refreshItem(r),["stop"]),title:"Reviewers can no longer open this link"},"Enable again",8,q_)],64)):f("v-if",!0)]),r?.status=="error"&&r?.statusMessage?(a(),l("div",{key:0,class:"status-sub status-sub-error",textContent:c(e.fmt?.statusMsg(r?.statusMessage)),title:r?.statusMessage},null,8,__)):f("v-if",!0),r?._stale?(a(),l("div",{key:1,class:"status-sub status-sub-warn",title:"Last activity "+e.fmt?.humanTime(r?.anonymizeDate||r?.lastView)},c(e.idleText(r)),9,L_)):f("v-if",!0),r.status==="error"&&r._editUrl?(a(),l("a",{key:2,class:"project-attention-action",href:e.safeUrl(r._editUrl)},"Fix source",8,$_)):f("v-if",!0),r._stale||r._broken?(a(),l("div",F_,[r._stale&&!r._broken?(a(),l("span",U_,[...t[67]||(t[67]=[g("May be stuck",-1),n("span",{"aria-hidden":"true"}," \xB7 ",-1)])])):f("v-if",!0),r._stale||r._broken?(a(),l("button",{key:1,type:"button",class:"project-attention-action",onClick:ae(p=>e.showProjectDetails(r),["stop"]),"data-project-actions":r._broken?encodeURIComponent(r._type+":"+r._id):null,"aria-controls":r._broken?e.projectDetailsId(r):null,"aria-expanded":r._broken?e.selectedProject===r:null},c(r._broken?"Review details":"Check progress"),9,B_)):f("v-if",!0)])):f("v-if",!0),r?.status=="expired"?(a(),l("button",{key:4,type:"button",class:"project-attention-action",onClick:ae(p=>e.extendItem(r),["stop"]),title:"Reviewers can no longer open this link"},"Extend 6 months",8,z_)):f("v-if",!0),r?.status=="removed"&&r?.anonymizeDate?(a(),l("div",H_,"anonymized "+c(e.fmt?.humanTime(r?.anonymizeDate)),1)):f("v-if",!0),r?.status!="error"&&r?.status!="expired"&&r?.status!="removed"&&!r?._stale&&r?.anonymizeDate?(a(),l("div",j_," anonymized "+c(e.fmt?.humanTime(r?.anonymizeDate)),1)):f("v-if",!0)]),n("div",{class:"cell-views num",role:"cell","data-unit":r.pageView===1?"view":"views","aria-label":e.fmt.number(r.pageView)+(r.pageView===1?" view":" views")},[t[68]||(t[68]=n("svg",{class:"project-type-svg mobile-meta-icon","aria-hidden":"true"},[n("use",{href:"#project-icon-eye"})],-1)),n("span",null,c(e.fmt.number(r.pageView)),1)],8,G_),n("div",W_,[t[72]||(t[72]=n("svg",{class:"project-type-svg mobile-meta-icon","aria-hidden":"true"},[n("use",{href:"#project-icon-clock"})],-1)),r?._expiry?.kind==="never"?(a(),l("span",K_,"No expiry")):f("v-if",!0),r?._expiry?.kind==="date"&&!r?._expiry?.soon?(a(),l("span",{key:1,textContent:c((e.fmt?.humanTime(r?._expiry?.date)||"").replace(/^on /,""))},null,8,Y_)):f("v-if",!0),r?._expiry?.kind==="date"&&r?._expiry?.soon?(a(),l("span",{key:2,class:"expires-soon",title:"Expires "+e.fmt?.humanTime(r?._expiry?.date)},[t[69]||(t[69]=n("svg",{class:"project-type-svg expires-soon-icon","aria-hidden":"true"},[n("use",{href:"#project-icon-clock"})],-1)),t[70]||(t[70]=n("span",{class:"expires-soon-prefix"},"Expires ",-1)),g(c(r._expiry.soon),1)],8,X_)):f("v-if",!0),r?._expiry?.kind==="expired"&&r?._expiry?.date?(a(),l("span",J_,[t[71]||(t[71]=n("span",{class:"expires-past-prefix"},"Expired ",-1)),g(c(r?._expiry?.label||e.fmt?.humanTime(r?._expiry?.date)),1)])):f("v-if",!0),r?._expiry?.kind==="expired"&&!r?._expiry?.date?(a(),l("span",Q_,"Expired")):f("v-if",!0),r?._expiry?.kind==="none"?(a(),l("span",Z_,"\u2014")):f("v-if",!0)])]),n("div",x_,[r._viewUrl&&!(r?._statusKey=="expired"||r?._statusKey=="removed")?(a(),l("button",{key:0,type:"button",class:"copy-url",onClick:ae(p=>e.copyLink(r),["stop"]),disabled:!!e.copyingId,title:"Copy link: "+r._viewUrl,"aria-label":"Copy anonymous link for "+r._label},[n("span",tL,c(e.copyingId===r._type+":"+r._id?"Link copied":""),1),(a(),l("svg",nL,[n("use",{href:e.copyingId===r._type+":"+r._id?"#ui-icon-check":"#project-icon-copy"},null,8,sL)])),n("span",oL,c(e.copyingId===r._type+":"+r._id?"Copied":"Copy link"),1)],8,eL)):f("v-if",!0),r._viewUrl&&!(r?._statusKey=="expired"||r?._statusKey=="removed")?(a(),l("a",{key:1,class:"row-edit row-open",href:e.safeUrl(r._viewUrl),target:"_blank",rel:"noopener",title:"Open what reviewers see","aria-label":"Open anonymous page for "+r._label},[...t[73]||(t[73]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-external-link"})],-1)])],8,iL)):f("v-if",!0),r?._editUrl&&!r?._broken&&r?._statusKey!="removed"?(a(),l("a",{key:2,class:"row-edit",href:e.safeUrl(r._editUrl),title:"Edit "+r._name,"aria-label":"Edit "+r._name},[...t[74]||(t[74]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-edit"})],-1)])],8,rL)):f("v-if",!0),!(r._viewUrl&&!(r?._statusKey=="expired"||r?._statusKey=="removed"))&&r?._statusKey!="removed"&&r?._statusKey!="expired"?(a(),l("button",{key:3,type:"button",class:"copy-url is-disabled","aria-disabled":"true",onClick:t[20]||(t[20]=ae(()=>{},["stop"])),title:r?._statusKey=="expired"?"Link expired: reviewers can no longer open it":r?._statusKey=="removed"?"Link offline: reviewers can no longer open it":"No link: this record is incomplete","aria-label":"Copy link unavailable for "+r._label},[...t[75]||(t[75]=[n("svg",{class:"project-type-svg","aria-hidden":"true"},[n("use",{href:"#project-icon-copy"})],-1),n("span",{class:"copy-url-label","aria-hidden":"true"},"Copy link",-1)])],8,aL)):f("v-if",!0),!(r._viewUrl&&!(r?._statusKey=="expired"||r?._statusKey=="removed"))&&r?._statusKey!="removed"&&r?._statusKey!="expired"?(a(),l("button",{key:4,type:"button",class:"row-edit row-open is-disabled","aria-disabled":"true",onClick:t[21]||(t[21]=ae(()=>{},["stop"])),title:r?._statusKey=="expired"?"Link expired: reviewers can no longer open it":r?._statusKey=="removed"?"Link offline: reviewers can no longer open it":"No link: this record is incomplete","aria-label":"Open unavailable for "+r._label},[...t[76]||(t[76]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-external-link"})],-1)])],8,lL)):f("v-if",!0),r?._editUrl&&!r?._broken?f("v-if",!0):(a(),l("button",{key:5,type:"button",class:"row-edit is-disabled","aria-disabled":"true",onClick:t[22]||(t[22]=ae(()=>{},["stop"])),title:"Can't edit: this record is incomplete","aria-label":"Edit unavailable for "+r._label},[...t[77]||(t[77]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-edit"})],-1)])],8,dL)),r?._broken?(a(),l("div",uL,[n("button",{type:"button",class:"btn btn-icon-dots is-disabled","aria-disabled":"true",onClick:t[23]||(t[23]=ae(()=>{},["stop"])),title:"No actions: this record is incomplete. Use Review details.","aria-label":"No actions available for "+r._label},[...t[78]||(t[78]=[n("svg",{class:"project-type-svg","aria-hidden":"true"},[n("use",{href:"#project-icon-more"})],-1)])],8,cL)])):f("v-if",!0),r?._broken?f("v-if",!0):(a(),l("div",pL,[n("button",{class:"btn btn-icon-dots",type:"button","data-toggle":"dropdown","aria-haspopup":"true","aria-expanded":"false","data-project-actions":encodeURIComponent(r._type+":"+r._id),"aria-label":"Actions for "+r?._name},[...t[79]||(t[79]=[n("svg",{class:"project-type-svg","aria-hidden":"true"},[n("use",{href:"#project-icon-more"})],-1)])],8,fL),n("div",hL,[n("button",{type:"button",class:"dropdown-item",onClick:p=>e.showProjectDetails(r),"aria-controls":e.projectDetailsId(r),"aria-expanded":e.selectedProject===r},"Project details & name",8,mL),n("a",{class:"dropdown-item",href:e.safeUrl(r?._viewUrl)}," View ",8,gL),r?._type==="repo"&&r?.options?.page&&r?.status=="ready"?(a(),l("a",{key:0,class:"dropdown-item",target:"_self",href:e.safeUrl("/w/"+r?.repoId+"/")}," View page ",8,vL)):f("v-if",!0),r?._viewUrl?(a(),l("button",{key:1,type:"button",class:"dropdown-item",onClick:p=>e.copyLink(r),disabled:!!e.copyingId}," Copy anonymous link ",8,yL)):f("v-if",!0),n("a",{class:"dropdown-item",href:e.safeUrl(r?._editUrl)}," Edit ",8,bL),r?.status=="ready"||r?.status=="error"?(a(),l("button",{key:2,type:"button",class:"dropdown-item",onClick:p=>e.refreshItem(r)}," Force update ",8,wL)):f("v-if",!0),r?.status=="removed"?(a(),l("button",{key:3,type:"button",class:"dropdown-item",onClick:p=>e.refreshItem(r)}," Enable ",8,kL)):f("v-if",!0),r?.status=="expired"?(a(),l("button",{key:4,type:"button",class:"dropdown-item",onClick:p=>e.extendItem(r)}," Extend 6 months ",8,CL)):f("v-if",!0),(r?.status=="ready"||r?.status=="expired"||r?.status=="error")&&r?.role!=="coauthor"?(a(),l("div",EL,[t[80]||(t[80]=n("div",{class:"dropdown-divider"},null,-1)),n("button",{type:"button",class:"dropdown-item dropdown-item-danger",onClick:p=>e.removeItem(r)}," Remove ",8,SL)])):f("v-if",!0)])]))])],10,u_)),!e.loading&&e.selectedProject===r?(a(),l("div",NL,[n("div",{class:"project-details",role:"cell","aria-colspan":"5",id:e.projectDetailsId(r),tabindex:"-1",onKeydown:kt(ae(p=>e.closeProjectDetails(r),["stop"]),["esc"])},[n("div",AL,[t[82]||(t[82]=n("h2",null,"Project details",-1)),n("button",{type:"button",class:"project-close",onClick:p=>e.closeProjectDetails(r),"aria-label":"Close project details"},[...t[81]||(t[81]=[n("svg",{class:"project-type-svg","aria-hidden":"true"},[n("use",{href:"#project-icon-close"})],-1)])],8,PL)]),n("dl",DL,[n("div",null,[t[83]||(t[83]=n("dt",null,"Source",-1)),n("dd",null,c(r._source||"Not available"),1)]),n("div",null,[t[84]||(t[84]=n("dt",null,"Anonymous ID",-1)),n("dd",null,[n("code",null,c(r._id||"Missing identifier"),1)])]),r.source?.commit?(a(),l("div",TL,[t[85]||(t[85]=n("dt",null,"Commit",-1)),n("dd",null,[n("code",null,c(r.source.commit),1)])])):f("v-if",!0),r.conference?(a(),l("div",OL,[t[86]||(t[86]=n("dt",null,"Conference",-1)),n("dd",null,c(r.conference),1)])):f("v-if",!0),n("div",null,[t[87]||(t[87]=n("dt",null,"Status",-1)),n("dd",null,[g(c(e.fmt.statusLabel(r.status)),1),r.statusMessage?(a(),l("span",IL," \xB7 "+c(e.fmt.statusMsg(r.statusMessage)),1)):f("v-if",!0)])]),r.anonymizeDate?(a(),l("div",ML,[t[88]||(t[88]=n("dt",null,"Last anonymized",-1)),n("dd",null,c(e.fmt.humanTime(r.anonymizeDate)),1)])):f("v-if",!0)]),r._stale?(a(),l("p",VL,"This download has not progressed recently. Check the source access and selected branch before retrying.")):f("v-if",!0),r._editUrl?(a(),l("a",{key:1,class:"project-attention-action",href:e.safeUrl(r._editUrl)},c(e.needsAttention(r)?"Check source settings":"Edit anonymization settings"),9,qL)):f("v-if",!0),r._id?(a(),l("form",{key:2,class:"project-name-form",onSubmit:ae(p=>e.saveProjectName(r),["prevent"])},[n("label",{for:"project-name-"+r._type+"-"+r._id},"Project name",8,LL),n("p",{id:"project-name-help-"+r._type+"-"+r._id},"Only you see this name. Leave it blank to use the default.",8,$L),n("div",FL,[D(n("input",{class:"form-control",type:"text",id:"project-name-"+r._type+"-"+r._id,"aria-describedby":"project-name-help-"+r._type+"-"+r._id,maxlength:"100","onUpdate:modelValue":t[24]||(t[24]=p=>e.projectName=p),disabled:e.nameSaving},null,8,UL),[[pt,e.projectName]]),n("button",{class:"btn btn-ink",type:"submit",disabled:e.nameSaving},c(e.nameSaving?"Saving\u2026":"Save name"),9,BL)]),e.nameError?(a(),l("p",zL,c(e.nameError),1)):f("v-if",!0),e.nameMessage?(a(),l("p",HL,c(e.nameMessage),1)):f("v-if",!0)],40,_L)):f("v-if",!0)],40,RL)])):f("v-if",!0)],64))),128)),!e.loading&&e.filteredItems?.length==0?(a(),l("div",jL,[t[90]||(t[90]=n("svg",{class:"project-type-svg project-empty-icon","aria-hidden":"true"},[n("use",{href:"#project-icon-inbox"})],-1)),e.hasProjects()?f("v-if",!0):(a(),l("span",GL,"You have no anonymizations yet.")),e.hasProjects()?(a(),l("span",WL,"Nothing matches the current filters.")):f("v-if",!0),n("div",KL,[e.hasActiveFilters()?(a(),l("button",{key:0,type:"button",class:"btn btn-outline-ink",onClick:t[25]||(t[25]=r=>e.clearFilters())},"Clear filters")):f("v-if",!0),e.hasProjects()?f("v-if",!0):(a(),l("a",YL,[...t[89]||(t[89]=[n("svg",{class:"project-type-svg","aria-hidden":"true"},[n("use",{href:"#project-icon-plus"})],-1),g(" New anonymization",-1)])]))])])):f("v-if",!0)],10,s_)]),e.dashboardCursor||e.dashboardError?(a(),l("div",XL,[e.dashboardError?(a(),l("p",JL,c(e.dashboardError),1)):f("v-if",!0),e.dashboardCursor?(a(),l("button",{key:1,type:"button",class:"btn",onClick:t[26]||(t[26]=r=>e.loadMoreProjects()),disabled:e.loadingMore},c(e.loadingMore?"Loading\u2026":"Load more projects"),9,QL)):f("v-if",!0)])):f("v-if",!0)])}var ZL={class:"viewer-bar"},xL={class:"vb-left"},e$=["aria-label","title"],t$=["href","title"],n$={class:"vb-artifact-id"},s$={class:"vb-right"},o$=["title"],i$={class:"vb-help"},r$=["aria-expanded"],a$={key:0,class:"acct-menu vb-help-menu",role:"menu"},l$=["aria-label","title"],d$={class:"ui-icon","aria-hidden":"true"},u$=["href"],c$={key:1,class:"acct"},p$=["aria-label","aria-expanded"],f$=["src"],h$={key:1,class:"acct-initial"},m$={key:0,class:"acct-menu",role:"menu"},g$={class:"acct-menu-head"},v$={key:2,class:"vb-signin",href:"/signin",target:"_self"},y$={key:0,class:"vb-context"},b$=["href","title"],w$={key:0,class:"vb-context-date"},k$=["aria-label"],C$={class:"ui-icon","aria-hidden":"true"},E$=["href"],S$=["textContent"],N$={class:"leftCol-head"},R$={class:"leftCol-search"},A$={class:"tree-search-box"},P$=["href"],D$={type:"text",class:"tree-search-input",placeholder:"Search files","aria-label":"Search files"},T$=["title","href"],O$={class:"leftCol-body"},I$={key:0,class:"paper-inline-warning",role:"alert"},M$={key:1,class:"paper-inline-warning",role:"alert"},V$={class:"explorer-main"},q$={class:"breadcrumb paths","aria-label":"Path"},_$={class:"breadcrumb-item breadcrumb-root"},L$=["href","title","textContent"],$$=["aria-current","textContent"],F$=["aria-label","title"],U$={class:"ui-icon","aria-hidden":"true"},B$=["href"],z$={class:"status-bar-actions"},H$=["href"],j$={class:"d-none d-md-inline"},G$={class:"ui-icon","aria-hidden":"true"},W$=["href"],K$={class:"d-none d-md-inline"},Y$=["href"],X$={class:"explorer-content"};function fp(e,t){let s=Xe("tree"),i=Xe("partial-view"),o=Pe("field");return a(),l("div",{class:A(["explorer-page",{"files-hidden":e.sidebarHidden}]),style:Ie({"--sidebar-w":e.sidebarWidth+"px"})},[n("header",ZL,[n("div",xL,[t[15]||(t[15]=n("a",{class:"vb-logo",href:"/"},[g("Anonymous "),n("em",null,"GitHub")],-1)),n("button",{type:"button",class:"vb-icon vb-sidebar","aria-label":e.sidebarHidden?"Show file tree":"Hide file tree",title:e.sidebarHidden?"Show file tree":"Hide file tree",onClick:t[0]||(t[0]=r=>e.sidebarHidden=!e.sidebarHidden)},[...t[13]||(t[13]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-sidebar"})],-1)])],8,e$),e.repoId?(a(),l("a",{key:0,class:"vb-artifact",href:e.safeUrl("/r/"+e.repoId+"/"),title:"Anonymous artifact "+e.repoId},[t[14]||(t[14]=n("span",{class:"sr-only"},"Artifact ",-1)),n("span",n$,c(e.repoId),1)],8,t$)):f("v-if",!0)]),n("div",s$,[e.options?.sourceCommitDate||e.options?.anonymizedAt||e.options?.lastUpdateDate?(a(),l("span",{key:0,class:"vb-snapshot",title:(e.options?.expirationDate?"Available until "+e.fmt?.date(e.options.expirationDate)+". ":"")+(e.options?.anonymizedAt&&!e.options?.publishedAt?"Older repositories have no recorded publication date. The source commit date does not establish when files became available here.":(e.options?.sourceCommitDate?"Source commit ":e.options?.anonymizedAt?"Anonymized ":"Updated ")+e.fmt?.date(e.options?.sourceCommitDate||e.options?.anonymizedAt||e.options?.lastUpdateDate)+(e.options?.publishedAt?" \xB7 snapshot ready "+e.fmt?.date(e.options.publishedAt):""))},[t[16]||(t[16]=n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#project-icon-clock"})],-1)),t[17]||(t[17]=n("span",null,"Snapshot",-1)),n("span",null,c(e.fmt?.date(e.options?.publishedAt||e.options?.sourceCommitDate||e.options?.anonymizedAt||e.options?.lastUpdateDate)),1)],8,o$)):f("v-if",!0),t[25]||(t[25]=n("a",{class:"vb-support",href:"https://ko-fi.com/tdurieux",target:"_blank",rel:"noopener",title:"Support Anonymous GitHub \u2014 help keep it free for researchers"},[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-heart"})]),n("span",null,"Support")],-1)),n("div",i$,[n("button",{type:"button",class:"vb-help-btn","aria-haspopup":"true","aria-expanded":e.helpOpen?"true":"false",onClick:t[1]||(t[1]=ae(r=>e.helpOpen=!e.helpOpen,["stop"]))},[...t[18]||(t[18]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-help"})],-1),n("span",null,"Help",-1)])],8,r$),e.helpOpen?(a(),l("div",a$,[...t[19]||(t[19]=[n("a",{role:"menuitem",href:"/faq"},[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-help"})]),n("span",null,[g("FAQ"),n("small",null,"How anonymization works")])],-1),n("a",{role:"menuitem",href:"https://github.com/tdurieux/anonymous_github/issues/new?template=issue_report.yml",target:"_blank",rel:"noopener"},[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-bug"})]),n("span",null,[g("Report a bug"),n("small",null,"About this service, not the paper")])],-1)])])):f("v-if",!0)]),n("button",{type:"button",class:"vb-icon","aria-label":e.isDarkMode?"Switch to light mode":"Switch to dark mode",title:e.isDarkMode?"Light mode":"Dark mode",onClick:t[2]||(t[2]=r=>e.darkMode(!e.isDarkMode))},[(a(),l("svg",d$,[n("use",{href:e.isDarkMode?"#ui-icon-sun":"#ui-icon-moon"},null,8,u$)]))],8,l$),e.user?(a(),l("div",c$,[n("button",{type:"button",class:"acct-chip","aria-haspopup":"true","aria-label":"Account: "+e.user?.username,"aria-expanded":e.accountOpen?"true":"false",onClick:t[3]||(t[3]=ae(r=>e.accountOpen=!e.accountOpen,["stop"]))},[e.user?.photo?(a(),l("img",{key:0,src:e.safeUrl(e.user.photo),alt:"",width:"26",height:"26"},null,8,f$)):(a(),l("span",h$,c((e.user?.username||"?").charAt(0).toUpperCase()),1))],8,p$),e.accountOpen?(a(),l("div",m$,[n("div",g$,[t[20]||(t[20]=g("Signed in as ",-1)),n("b",null,"@"+c(e.user?.username),1)]),t[21]||(t[21]=n("a",{role:"menuitem",href:"/dashboard"},[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-grid"})]),g("My work")],-1)),t[22]||(t[22]=n("a",{role:"menuitem",href:"/profile"},[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-user"})]),g("Settings")],-1)),t[23]||(t[23]=n("a",{role:"menuitem",href:"/api/user/logout",target:"_self"},[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-logout"})]),g("Sign out")],-1))])):f("v-if",!0)])):(a(),l("a",v$,[...t[24]||(t[24]=[n("i",{class:"fab fa-github","aria-hidden":"true"},null,-1),g("Sign in",-1)])]))])]),e.repoId?(a(),l("div",y$,[n("a",{class:"vb-context-id",href:e.safeUrl("/r/"+e.repoId+"/"),title:"Anonymous artifact "+e.repoId},c(e.repoId),9,b$),e.options?.publishedAt||e.options?.sourceCommitDate||e.options?.anonymizedAt||e.options?.lastUpdateDate?(a(),l("span",w$,"Snapshot "+c(e.fmt?.date(e.options?.publishedAt||e.options?.sourceCommitDate||e.options?.anonymizedAt||e.options?.lastUpdateDate)),1)):f("v-if",!0)])):f("v-if",!0),D(n("button",{class:"sidebar-toggle",onClick:t[4]||(t[4]=r=>e.sidebarCollapsed=!e.sidebarCollapsed),"aria-label":e.sidebarCollapsed?"Show files":"Hide files"},[(a(),l("svg",C$,[n("use",{href:e.sidebarCollapsed?"#ui-icon-folder":"#project-icon-close"},null,8,E$)])),n("span",{textContent:c(e.sidebarCollapsed?"Files":"Close")},null,8,S$)],8,k$),[[Z,e.files?.length]]),D(n("div",{class:A(["leftCol",{collapsed:e.sidebarCollapsed}])},[n("div",N$,[t[27]||(t[27]=n("span",{class:"leftCol-eyebrow"},"Files",-1)),n("button",{class:"leftCol-close","aria-label":"Close files",onClick:t[5]||(t[5]=r=>e.sidebarCollapsed=!0)},[...t[26]||(t[26]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#project-icon-close"})],-1)])])]),n("div",R$,[n("div",A$,[(a(),l("svg",{class:A(["ui-icon tree-search-icon",{"fa-spin":e.fileSearchLoading}]),"aria-hidden":"true"},[n("use",{href:e.fileSearchLoading?"#ui-icon-spinner":"#ui-icon-search"},null,8,P$)],2)),D(n("input",D$,null,512),[[o,{state:e.viewState,set:r=>{e.fileSearchQuery=r},value:e.fileSearchQuery,form:null,options:{debounce:300},change:()=>{e.onFileSearchChange()}}]]),D(n("kbd",{class:"tree-search-kbd"},c(e.isMac?"\u2318":"Ctrl+")+"K",513),[[Z,!e.fileSearchQuery]]),D(n("button",{class:"tree-search-clear","aria-label":"Clear search",onClick:t[6]||(t[6]=r=>{e.fileSearchQuery="",e.onFileSearchChange()})},"\xD7",512),[[Z,e.fileSearchQuery]])]),e.options?.download?(a(),l("a",{key:0,target:"_self",class:"search-zip","aria-label":"Download repository as ZIP",title:"Download the repository (snapshot "+e.fmt?.date(e.options?.sourceCommitDate||e.options?.anonymizedAt||e.options?.lastUpdateDate)+") as ZIP",href:e.safeUrl("/api/repo/"+e.repoId+"/zip")},[...t[28]||(t[28]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-download"})],-1),n("span",{class:"search-zip-label","aria-hidden":"true"},"ZIP",-1)])],8,T$)):f("v-if",!0)]),n("div",O$,[e.options?.truncatedFolders?.length>0?(a(),l("div",I$,[t[29]||(t[29]=n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-warning"})],-1)),g(" "+c(e.fmt?.translate("WARNINGS.repo_truncated")),1)])):f("v-if",!0),e.options?.hasSubmodules?(a(),l("div",M$,[t[30]||(t[30]=n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-warning"})],-1)),g(" "+c(e.fmt?.translate("WARNINGS.submodules_not_included")),1)])):f("v-if",!0),Oe(s,{class:"files",file:e.files,"search-query":e.fileSearchQuery,"search-results":e.fileSearchResults,page:e.viewState},null,8,["file","search-query","search-results","page"])])],2),[[Z,e.files?.length]]),D(n("div",{class:"leftCol-resizer",role:"separator","aria-orientation":"vertical","aria-label":"Resize file tree",title:"Drag to resize",onPointerdown:t[7]||(t[7]=r=>e.startSidebarResize(r))},null,544),[[Z,e.files?.length&&!e.sidebarHidden]]),D(n("div",{class:"leftCol-backdrop",onClick:t[8]||(t[8]=r=>e.sidebarCollapsed=!0)},null,512),[[Z,e.files?.length&&!e.sidebarCollapsed]]),n("div",V$,[D(n("div",{class:A(["status-bar",{"is-redundant":["code","text","html"].includes(e.type)&&e.content!=null||e.fileFrame()}])},[D(n("button",{type:"button",class:"btn btn-sm status-files-btn","aria-label":"Show files",title:"Show files",onClick:t[9]||(t[9]=r=>e.sidebarHidden?e.sidebarHidden=!1:e.sidebarCollapsed=!1)},[...t[31]||(t[31]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-folder"})],-1),n("span",null,"Files",-1)])],512),[[Z,e.files?.length]]),n("ol",q$,[n("li",_$,[n("a",{href:e.safeUrl("/r/"+e.repoId+"/"),title:e.repoId,textContent:c(/^[0-9a-f]{8}-[0-9a-f]{4}-/i.test(e.repoId||"")?"repository":e.repoId)},null,8,L$)]),(a(!0),l(q,null,Q(e.paths,(r,d)=>(a(),l("li",{class:"breadcrumb-item","aria-current":d===e.paths.length-1?"page":null,textContent:c(r)},null,8,$$))),256))]),D(n("button",{type:"button",class:"btn btn-sm btn-icon-only btn-ghost copy-path-btn","aria-label":e.pathCopied?"Path copied":"Copy path",title:e.pathCopied?"Path copied":"Copy path",onClick:t[10]||(t[10]=r=>e.copyPath())},[(a(),l("svg",U$,[n("use",{href:e.pathCopied?"#ui-icon-check":"#project-icon-copy"},null,8,B$)]))],8,F$),[[Z,e.filePath]]),n("div",z$,[e.options?.isAdmin||e.options?.isOwner?(a(),l("a",{key:0,class:"btn btn-sm","aria-label":"Edit",href:e.safeUrl("/anonymize/"+e.repoId)},[...t[32]||(t[32]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-edit"})],-1),n("span",{class:"d-none d-md-inline"}," Edit",-1)])],8,H$)):f("v-if",!0),e.type=="html-doc"&&!e.showSource?(a(),l("button",{key:1,class:A(["btn btn-sm",{"btn-active":e.allowScripts}]),"aria-label":"Allow this document to run JavaScript",title:"Scripts in this file are blocked by default. Enable them only if you trust the repository \u2014 the document stays isolated from your session either way.",onClick:t[11]||(t[11]=r=>e.toggleAllowScripts())},[t[33]||(t[33]=n("i",{class:"fab fa-js"},null,-1)),n("span",j$,c(e.allowScripts?"JS on":"JS off"),1)],2)):f("v-if",!0),e.type=="html-doc"?(a(),l("button",{key:2,class:"btn btn-sm","aria-label":"Toggle between the rendered document and its source",title:"Toggle between the rendered document and its source",onClick:t[12]||(t[12]=r=>e.toggleSource())},[(a(),l("svg",G$,[n("use",{href:e.showSource?"#project-icon-eye":"#ui-icon-code"},null,8,W$)])),n("span",K$,c(e.showSource?"Rendered":"Source"),1)])):f("v-if",!0),e.options?.hasWebsite?(a(),l("a",{key:3,target:"_self",class:"btn btn-sm","aria-label":"Website",href:e.safeUrl("/w/"+e.repoId+"/")},[...t[34]||(t[34]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-globe"})],-1),n("span",{class:"d-none d-md-inline"}," Website",-1)])],8,Y$)):f("v-if",!0)])],2),[[Z,e.type!="error"||e.files?.length]]),n("div",X$,[Oe(i,{name:"partials/pageView.htm",state:e.viewState},null,8,["state"])])])],6)}var J$={class:"paper-faq"},Q$={class:"paper-faq-body"},Z$={class:"paper-faq-toc"},x$={class:"faq-search",role:"search"},eF={class:"faq-search-field"},tF={id:"faq-search-status",class:"faq-search-status","aria-live":"polite"},nF={key:0,class:"faq-search-empty"},sF={class:"faq-search-empty-actions"};function hp(e,t){let s=Xe("partial-view"),i=Pe("paper-scrollspy");return a(),l(q,null,[n("div",J$,[t[12]||(t[12]=n("div",{class:"paper-faq-hero"},[n("div",{class:"paper-faq-eyebrow"},"Help"),n("h1",{class:"paper-faq-title"},[g("Mirrors, redaction, and "),n("em",null,"what reviewers see.")]),n("p",{class:"paper-faq-lede"}," How to set up an anonymous mirror, what it hides, and how long it stays online. ")],-1)),n("div",Q$,[D((a(),l("aside",Z$,[...t[5]||(t[5]=[Ce('
Contents
',2)])])),[[i]]),n("section",{class:A(["faq-section",{"faq-searching":!!e.faqQuery.trim()}]),"aria-label":"FAQs"},[n("div",x$,[t[7]||(t[7]=n("label",{for:"faq-search-input"},"Search questions",-1)),n("div",eF,[t[6]||(t[6]=n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-search"})],-1)),D(n("input",{id:"faq-search-input",type:"search",class:"form-control","onUpdate:modelValue":t[0]||(t[0]=o=>e.faqQuery=o),onInput:t[1]||(t[1]=o=>e.filterFaq()),onSearch:t[2]||(t[2]=o=>e.filterFaq()),onKeydown:t[3]||(t[3]=kt(o=>e.clearFaqSearch(),["esc"])),placeholder:"e.g. expiry, pull request, PDF",autocomplete:"off",spellcheck:"false","aria-describedby":"faq-search-status"},null,544),[[pt,e.faqQuery]])]),n("p",tF,[e.faqQuery.trim()&&e.faqResults?(a(),l(q,{key:0},[g(c(e.faqResults===1?"1 result":e.faqResults+" results"),1)],64)):f("v-if",!0)])]),e.faqQuery.trim()&&e.faqResults===0?(a(),l("div",nF,[n("strong",null,"No questions match \u201C"+c(e.faqQuery.trim())+"\u201D.",1),t[9]||(t[9]=n("p",null,"Try a shorter word, or ask us directly.",-1)),n("div",sF,[n("button",{type:"button",class:"btn btn-outline-ink btn-sm",onClick:t[4]||(t[4]=o=>e.clearFaqSearch())},"Clear search"),t[8]||(t[8]=n("a",{class:"btn btn-link btn-sm",target:"_blank",rel:"noopener",href:"https://github.com/tdurieux/anonymous_github/issues/new?template=issue_report.yml"},"Open an issue",-1))])])):f("v-if",!0),t[10]||(t[10]=n("div",{class:"faq-list"},[f(" General "),n("h4",{class:"faq-cat"},[n("svg",{class:"ui-icon mr-2","aria-hidden":"true"},[n("use",{href:"#ui-icon-info"})]),g("General ")]),n("div",{class:"panel-group",id:"faq-general",role:"tablist","aria-multiselectable":"true"},[n("div",{class:"panel panel-default mb-3"},[n("div",{class:"panel-heading p-3",role:"tab",id:"headingWhatIs"},[n("h3",{class:"panel-title"},[n("a",{role:"button","data-toggle":"collapse","data-parent":"#faq-general",href:"#whatIs","aria-expanded":"true","aria-controls":"whatIs"}," What is Anonymous GitHub? ")])]),n("div",{id:"whatIs",class:"panel-collapse collapse show",role:"tabpanel","aria-labelledby":"headingWhatIs"},[n("div",{class:"panel-body p-3"},[n("p",null," Anonymous GitHub is an open-source tool with free hosting and optional paid plans that anonymizes GitHub repositories and pull requests for double-anonymous (double-blind) peer review. It replaces identifying information, such as the repository owner, organization name, and custom terms, so that reviewers cannot determine the identity of the authors through the code repository. ")])])]),n("div",{class:"panel panel-default mb-3"},[n("div",{class:"panel-heading p-3",role:"tab",id:"headingHowWork"},[n("h3",{class:"panel-title"},[n("a",{class:"collapsed",role:"button","data-toggle":"collapse","data-parent":"#faq-general",href:"#howWork","aria-expanded":"false","aria-controls":"howWork"}," How does Anonymous GitHub work? ")])]),n("div",{id:"howWork",class:"panel-collapse collapse",role:"tabpanel","aria-labelledby":"headingHowWork"},[n("div",{class:"panel-body p-3"},[n("p",null," Anonymous GitHub either downloads the complete repository and anonymizes the content, or proxies requests to GitHub on the fly. In both cases, the original and anonymized versions of files are cached on the server. The system automatically detects and replaces the repository owner, organization name, and repository name. You can also specify additional custom terms to anonymize using one-per-line regex patterns. ")])])]),n("div",{class:"panel panel-default mb-3"},[n("div",{class:"panel-heading p-3",role:"tab",id:"headingScope"},[n("h3",{class:"panel-title"},[n("a",{class:"collapsed",role:"button","data-toggle":"collapse","data-parent":"#faq-general",href:"#scope","aria-expanded":"false","aria-controls":"scope"}," What is the scope of anonymization? ")])]),n("div",{id:"scope",class:"panel-collapse collapse",role:"tabpanel","aria-labelledby":"headingScope"},[n("div",{class:"panel-body p-3"},[n("p",null," In double-anonymous peer review, the boundary of anonymization is the paper plus its online appendix, not the entire internet. Searching for any part of the paper or the online appendix can be considered a deliberate attempt to break anonymity. Anonymous GitHub anonymizes the repository owner, organization, repository name, file and directory names, and file contents across all text-based file types. ")])])]),n("div",{class:"panel panel-default mb-3"},[n("div",{class:"panel-heading p-3",role:"tab",id:"headingCost"},[n("h3",{class:"panel-title"},[n("a",{class:"collapsed",role:"button","data-toggle":"collapse","data-parent":"#faq-general",href:"#cost","aria-expanded":"false","aria-controls":"cost"}," How much does it cost? ")])]),n("div",{id:"cost",class:"panel-collapse collapse",role:"tabpanel","aria-labelledby":"headingCost"},[n("div",{class:"panel-body p-3"},[n("p",null," A free account includes 5 owned repositories and 2 GiB of source files. Optional paid plans offer more capacity, automatic refresh, and, with an author subscription, never-expiring repositories. Reviewers can read shared repositories without an account or payment. "),n("p",null,[g(" See "),n("a",{href:"/profile#settings-billing"},"Plans and billing"),g(" for available plans and current prices. Offers depend on whether payments are enabled on this instance; the checkout shows the amount before you pay. Subscriptions help fund hosting, storage, backups, and continued maintenance. ")]),n("p",null,[g(" You can also support development through "),n("a",{href:"https://github.com/sponsors/tdurieux/",target:"_blank",rel:"noopener"},"GitHub Sponsors"),g(" or "),n("a",{href:"https://ko-fi.com/tdurieux",target:"_blank",rel:"noopener"},"Ko-fi"),g(". Donations are separate from subscriptions and do not automatically unlock paid features. ")])])])])]),f(" Plans and billing "),n("h4",{class:"faq-cat",id:"faq-plans-title"},"Plans and billing"),n("div",{class:"panel-group",id:"faq-plans",role:"tablist","aria-label":"Plans and billing","aria-multiselectable":"true"},[n("div",{class:"panel panel-default mb-3"},[n("div",{class:"panel-heading p-3",role:"tab",id:"headingWhyPaid"},[n("h3",{class:"panel-title"},[n("a",{class:"collapsed",role:"button","data-toggle":"collapse","data-parent":"#faq-plans",href:"#whyPaid","aria-expanded":"false","aria-controls":"whyPaid"},"Why is Anonymous GitHub no longer completely free?")])]),n("div",{id:"whyPaid",class:"panel-collapse collapse",role:"tabpanel","aria-labelledby":"headingWhyPaid"},[n("div",{class:"panel-body p-3"},[n("p",null,"Anonymous GitHub started as a small free service and was paid for out of pocket. Three things have changed since then:"),n("ul",null,[n("li",null,[n("strong",null,"Servers cost much more."),g(" Every hosted repository needs storage, bandwidth and backups, and these costs have risen sharply.")]),n("li",null,[n("strong",null,"Many more people use it."),g(" More users means more repositories to store and keep up to date, more support requests and more maintenance.")]),n("li",null,[n("strong",null,"AI has made security work heavier."),g(" AI-driven scrapers and automated abuse send far more traffic than before. Blocking them and keeping hosted content safe takes constant work.")])]),n("p",null,"The core service stays free: anonymizing a repository, sharing the link and reviewer access cost nothing, and reviewers never need an account. Most authors never need to pay. The paid options are small one-time payments for one repository, plus an optional subscription for heavy users. They are priced to cover running costs, not to make a profit."),n("p",null,[g("The source code remains open, so you can still "),n("a",{href:"#faq-hosting"},"host your own instance"),g(" for free.")])])])]),n("div",{class:"panel panel-default mb-3"},[n("div",{class:"panel-heading p-3",role:"tab",id:"headingFreePlan"},[n("h3",{class:"panel-title"},[n("a",{class:"collapsed",role:"button","data-toggle":"collapse","data-parent":"#faq-plans",href:"#freePlan","aria-expanded":"false","aria-controls":"freePlan"},"What is included in a free account?")])]),n("div",{id:"freePlan",class:"panel-collapse collapse",role:"tabpanel","aria-labelledby":"headingFreePlan"},[n("div",{class:"panel-body p-3"},[n("p",null,"The default free allowance is 5 repositories you own and 2 GiB of source files in total. Core anonymization and reviewer access remain free. You can manually refresh a repository within your allowance and choose a dated expiration up to 5 months ahead, then extend it again before it expires. Repositories submitted to a conference can stay online until the end of its review window."),n("p",null,"Repositories shared with you as a co-author do not use your own slots. Gists and pull requests are not included in these repository quotas. The usage shown in your account is the allowance available on this instance.")])])]),n("div",{class:"panel panel-default mb-3"},[n("div",{class:"panel-heading p-3",role:"tab",id:"headingAuthorPlans"},[n("h3",{class:"panel-title"},[n("a",{class:"collapsed",role:"button","data-toggle":"collapse","data-parent":"#faq-plans",href:"#authorPlans","aria-expanded":"false","aria-controls":"authorPlans"},"What do monthly and annual author subscriptions include?")])]),n("div",{id:"authorPlans",class:"panel-collapse collapse",role:"tabpanel","aria-labelledby":"headingAuthorPlans"},[n("div",{class:"panel-body p-3"},[n("p",null,[g("Both include 20 owned repositories and 10 GiB of source files in total. They also allow automatic refresh when enabled in repository settings and let the owner choose "),n("strong",null,"Never expire"),g(".")]),n("p",null,[g("Monthly and annual plans offer the same features with different billing periods. They renew automatically until you cancel renewal. Current prices are shown in "),n("a",{href:"/profile#settings-billing"},"Plans and billing"),g(".")]),n("p",null,"Paid plans do not change how anonymization works. File-size limits and other service safeguards still apply. Review your anonymized content before sharing it.")])])]),n("div",{class:"panel panel-default mb-3"},[n("div",{class:"panel-heading p-3",role:"tab",id:"headingReviewPass"},[n("h3",{class:"panel-title"},[n("a",{class:"collapsed",role:"button","data-toggle":"collapse","data-parent":"#faq-plans",href:"#reviewPass","aria-expanded":"false","aria-controls":"reviewPass"},"Can I pay for one repository without subscribing?")])]),n("div",{id:"reviewPass",class:"panel-collapse collapse",role:"tabpanel","aria-labelledby":"headingReviewPass"},[n("div",{class:"panel-body p-3"},[n("p",null,"Yes. These one-time add-ons apply to a single repository you own. None of them renews automatically:"),n("ul",null,[n("li",null,[n("strong",null,"Paper pack"),g(": an extra repository, automatic updates for 180 days and one more year before it expires, in a single payment. It covers what one paper usually needs during review.")]),n("li",null,[n("strong",null,"Extra repository"),g(": host one more repository once your free repositories are used up. It has its own 2 GiB allowance and does not count toward your free repositories. It lasts as long as the repository exists.")]),n("li",null,[n("strong",null,"Live updates"),g(": automatic refresh for 180 days, with a separate 2 GiB allowance.")]),n("li",null,[n("strong",null,"Extended expiration"),g(": choose an expiration date up to one year after purchase. Buying it again adds another year.")]),n("li",null,[n("strong",null,"Never expire"),g(": the repository has no expiration date. A full refund or a payment dispute ends it after a 90-day grace period.")])]),n("p",null,[g("When your free allowance is full, the Extra repository and Paper pack options are offered as you create the repository. You can also buy an add-on from the repository's edit page, or enter the anonymized ID of an existing repository in "),n("a",{href:"/profile#settings-billing"},"Plans and billing"),g(". Current prices are shown there.")])])])]),n("div",{class:"panel panel-default mb-3"},[n("div",{class:"panel-heading p-3",role:"tab",id:"headingConferencePlans"},[n("h3",{class:"panel-title"},[n("a",{class:"collapsed",role:"button","data-toggle":"collapse","data-parent":"#faq-plans",href:"#conferencePlans","aria-expanded":"false","aria-controls":"conferencePlans"},"Can a conference or lab pay for a group?")])]),n("div",{id:"conferencePlans",class:"panel-collapse collapse",role:"tabpanel","aria-labelledby":"headingConferencePlans"},[n("div",{class:"panel-body p-3"},[n("p",null,"A conference review package provides a shared allowance for a review window of up to 180 days, with automatic updates for every submission. It comes in three sizes: Workshop (25 repositories, 10 GiB), Conference (100 repositories, 50 GiB) and Large conference (400 repositories, 200 GiB). Choose the size when you create the conference; it cannot change afterwards. The organizer pays once and authors pay nothing (the price is shown when you create the conference); the package does not renew automatically. A lab organizing a review can use this shared package too."),n("p",null,"New conferences no longer have a free plan: every new conference is a review package. Conferences created earlier keep working as before. The conference must be activated by payment before authors can submit under its Conference ID. Eligible repositories use the conference allowance before an author's personal allowance, so authors do not each need a subscription for that capacity."),n("p",null,"The package has a fixed review window. Never expire still requires the repository owner's author subscription or a Never expire add-on for that repository.")])])]),n("div",{class:"panel panel-default mb-3"},[n("div",{class:"panel-heading p-3",role:"tab",id:"headingPaidCoauthors"},[n("h3",{class:"panel-title"},[n("a",{class:"collapsed",role:"button","data-toggle":"collapse","data-parent":"#faq-plans",href:"#paidCoauthors","aria-expanded":"false","aria-controls":"paidCoauthors"},"Does every co-author need to pay?")])]),n("div",{id:"paidCoauthors",class:"panel-collapse collapse",role:"tabpanel","aria-labelledby":"headingPaidCoauthors"},[n("div",{class:"panel-body p-3"},[n("p",null,"No. Co-authors can collaborate without buying a subscription. A shared repository uses its owner's allowance, unless a repository pass or paid conference covers it. It does not consume each co-author's personal allowance."),n("p",null,"A co-author's subscription does not increase the owner's allowance. If the owner's available capacity is exhausted, a co-author's refresh or edit may also be blocked. Reviewers never need a paid account.")])])]),n("div",{class:"panel panel-default mb-3"},[n("div",{class:"panel-heading p-3",role:"tab",id:"headingCapacity"},[n("h3",{class:"panel-title"},[n("a",{class:"collapsed",role:"button","data-toggle":"collapse","data-parent":"#faq-plans",href:"#capacity","aria-expanded":"false","aria-controls":"capacity"},"What counts toward my allowance, and what happens at the limit?")])]),n("div",{id:"capacity",class:"panel-collapse collapse",role:"tabpanel","aria-labelledby":"headingCapacity"},[n("div",{class:"panel-body p-3"},[n("p",null,"The repository limit counts work you own. Storage counts the source-file sizes reserved for those repositories, not just files a reviewer opens. Archived or failed repositories can still reserve capacity, and a refresh does not automatically reduce a previous storage reservation."),n("p",null,"At the repository limit you cannot add another repository to that allowance. An edit or refresh must also fit the available storage. Remove work you no longer need, add an Extra repository for the new one, choose a subscription, or use an eligible conference allowance."),n("p",null,"Removing a repository releases its reservation when capacity is next checked. Expired repositories may continue to reserve capacity until cleanup. Reaching a limit does not itself delete existing review links.")])])]),n("div",{class:"panel panel-default mb-3"},[n("div",{class:"panel-heading p-3",role:"tab",id:"headingNeverExpire"},[n("h3",{class:"panel-title"},[n("a",{class:"collapsed",role:"button","data-toggle":"collapse","data-parent":"#faq-plans",href:"#neverExpire","aria-expanded":"false","aria-controls":"neverExpire"},"What happens to Never expire repositories if I stop subscribing?")])]),n("div",{id:"neverExpire",class:"panel-collapse collapse",role:"tabpanel","aria-labelledby":"headingNeverExpire"},[n("div",{class:"panel-body p-3"},[n("p",null,[g("Never expire is available to monthly and annual author subscribers, or for one repository with the one-time Never expire add-on. If a subscription ends, these repositories remain available for a "),n("strong",null,"90-day grace period"),g(", then expire and their hosted content is removed.")]),n("p",null,"Renewing during the grace period keeps them active. After expiration, you must renew and explicitly reactivate the repository; restoring content also requires access to its GitHub source. A repository does not become public on GitHub when it expires."),n("p",null,"Existing never-expiring repositories created before this billing policy retain their settings. Never expire is not a guarantee of perpetual service availability.")])])]),n("div",{class:"panel panel-default mb-3"},[n("div",{class:"panel-heading p-3",role:"tab",id:"headingCancelPlan"},[n("h3",{class:"panel-title"},[n("a",{class:"collapsed",role:"button","data-toggle":"collapse","data-parent":"#faq-plans",href:"#cancelPlan","aria-expanded":"false","aria-controls":"cancelPlan"},"How do I cancel, and what happens after paid access ends?")])]),n("div",{id:"cancelPlan",class:"panel-collapse collapse",role:"tabpanel","aria-labelledby":"headingCancelPlan"},[n("div",{class:"panel-body p-3"},[n("p",null,[g("Open "),n("a",{href:"/profile#settings-billing"},"Plans and billing"),g(" and choose "),n("strong",null,"Manage billing and invoices"),g(" to manage renewal. Cancelling renewal keeps subscription benefits until the end of the paid period.")]),n("p",null,"After paid access ends, repositories fall back to another eligible allowance or the free allowance. Automatic refresh pauses on the free allowance; manual refresh remains available within its limits. Existing review links keep their configured expiration dates, except paid Never expire repositories, which follow the 90-day grace period described above."),n("p",null,"A repository pass or conference package ends after its paid window without automatic renewal.")])])]),n("div",{class:"panel panel-default mb-3"},[n("div",{class:"panel-heading p-3",role:"tab",id:"headingRefunds"},[n("h3",{class:"panel-title"},[n("a",{class:"collapsed",role:"button","data-toggle":"collapse","data-parent":"#faq-plans",href:"#refunds","aria-expanded":"false","aria-controls":"refunds"},"Can I get a refund?")])]),n("div",{id:"refunds",class:"panel-collapse collapse",role:"tabpanel","aria-labelledby":"headingRefunds"},[n("div",{class:"panel-body p-3"},[n("p",null,[g("Refunds are handled case by case. "),n("a",{href:"mailto:tdurieux@anonymous.4open.science"},"Email the maintainer"),g(" with the date of the payment and the repository it was for.")]),n("p",null,"A full refund ends what that payment bought. For a Paper pack, this means all three parts: the extra repository, automatic updates and the extended expiration. A Never expire repository then expires after a 90-day grace period. A partial refund keeps your access."),n("p",null,"To stop a subscription, cancel its renewal instead of asking for a refund. You keep access until the end of the period you paid for.")])])]),n("div",{class:"panel panel-default mb-3"},[n("div",{class:"panel-heading p-3",role:"tab",id:"headingPaymentHandling"},[n("h3",{class:"panel-title"},[n("a",{class:"collapsed",role:"button","data-toggle":"collapse","data-parent":"#faq-plans",href:"#paymentHandling","aria-expanded":"false","aria-controls":"paymentHandling"},"How are payments handled?")])]),n("div",{id:"paymentHandling",class:"panel-collapse collapse",role:"tabpanel","aria-labelledby":"headingPaymentHandling"},[n("div",{class:"panel-body p-3"},[n("p",null,[g("Stripe processes checkout and billing management. Anonymous GitHub does not store your card details. You can access billing management and invoices from "),n("a",{href:"/profile#settings-billing"},"Plans and billing"),g(".")]),n("p",null,[g("Paid access is activated after payment is confirmed. If checkout succeeds but your account has not updated, choose "),n("strong",null,"Refresh payment status"),g(" before trying another purchase. If paid plans are unavailable on this instance, no checkout is offered.")])])])])]),f(" Features "),n("h4",{class:"faq-cat"},[n("svg",{class:"ui-icon mr-2","aria-hidden":"true"},[n("use",{href:"#project-icon-filter"})]),g("Features ")]),n("div",{class:"panel-group",id:"faq-features",role:"tablist","aria-multiselectable":"true"},[n("div",{class:"panel panel-default mb-3"},[n("div",{class:"panel-heading p-3",role:"tab",id:"headingFormats"},[n("h3",{class:"panel-title"},[n("a",{class:"collapsed",role:"button","data-toggle":"collapse","data-parent":"#faq-features",href:"#formats","aria-expanded":"false","aria-controls":"formats"}," Which file formats are supported? ")])]),n("div",{id:"formats",class:"panel-collapse collapse",role:"tabpanel","aria-labelledby":"headingFormats"},[n("div",{class:"panel-body p-3"},[n("p",null," Anonymous GitHub can display and render a wide variety of file types: "),n("ul",null,[n("li",null,[n("strong",null,"Text and source code"),g(": displayed with syntax highlighting")]),n("li",null,[n("strong",null,"Markdown"),g(": rendered as formatted HTML")]),n("li",null,[n("strong",null,"Images"),g(" (PNG, JPG, SVG, etc.): displayed inline")]),n("li",null,[n("strong",null,"PDFs"),g(": rendered directly in the browser")]),n("li",null,[n("strong",null,"Jupyter Notebooks"),g(": rendered with code cells and outputs")])]),n("p",null," Only text-based files are anonymized. Anonymous GitHub analyzes the content of each file to determine whether it is textual or binary. ")])])]),n("div",{class:"panel panel-default mb-3"},[n("div",{class:"panel-heading p-3",role:"tab",id:"headingPR"},[n("h3",{class:"panel-title"},[n("a",{class:"collapsed",role:"button","data-toggle":"collapse","data-parent":"#faq-features",href:"#pullRequests","aria-expanded":"false","aria-controls":"pullRequests"}," Can I anonymize pull requests? ")])]),n("div",{id:"pullRequests",class:"panel-collapse collapse",role:"tabpanel","aria-labelledby":"headingPR"},[n("div",{class:"panel-body p-3"},[n("p",null," Yes. In addition to full repositories, Anonymous GitHub supports anonymizing individual pull requests. Simply paste the URL of a GitHub pull request when creating a new anonymized repository, and the system will automatically detect that it is a pull request and anonymize it accordingly. ")])])]),n("div",{class:"panel panel-default mb-3"},[n("div",{class:"panel-heading p-3",role:"tab",id:"headingConference"},[n("h3",{class:"panel-title"},[n("a",{class:"collapsed",role:"button","data-toggle":"collapse","data-parent":"#faq-features",href:"#conference","aria-expanded":"false","aria-controls":"conference"}," What is the Conference ID feature? ")])]),n("div",{id:"conference",class:"panel-collapse collapse",role:"tabpanel","aria-labelledby":"headingConference"},[n("div",{class:"panel-body p-3"},[n("p",null," When creating an anonymized repository, you can associate it with a Conference ID. This allows conferences to define default anonymization settings (such as expiration dates) that are automatically applied to repositories submitted under that conference. If your conference provides a Conference ID, enter it during the anonymization setup. ")])])]),n("div",{class:"panel panel-default mb-3"},[n("div",{class:"panel-heading p-3",role:"tab",id:"headingExpiration"},[n("h3",{class:"panel-title"},[n("a",{class:"collapsed",role:"button","data-toggle":"collapse","data-parent":"#faq-features",href:"#expiration","aria-expanded":"false","aria-controls":"expiration"}," What happens when an anonymized repository expires? ")])]),n("div",{id:"expiration",class:"panel-collapse collapse",role:"tabpanel","aria-labelledby":"headingExpiration"},[n("div",{class:"panel-body p-3"},[n("p",null," You can configure one of three expiration strategies when creating your anonymized repository: "),n("ul",null,[n("li",null,[n("strong",null,"Never expire"),g(": with a monthly or annual author subscription, no scheduled expiration while subscribed. A 90-day grace period applies after paid access ends. See "),n("a",{href:"#neverExpire"},"the subscription expiration policy"),g(".")]),n("li",null,[n("strong",null,"Redirect to GitHub"),g(": after expiration, visitors are redirected to the original GitHub repository.")]),n("li",null,[n("strong",null,"Remove content"),g(": after expiration, the anonymized content is deleted from the server.")])])])])]),n("div",{class:"panel panel-default mb-3"},[n("div",{class:"panel-heading p-3",role:"tab",id:"headingDownload"},[n("h3",{class:"panel-title"},[n("a",{class:"collapsed",role:"button","data-toggle":"collapse","data-parent":"#faq-features",href:"#download","aria-expanded":"false","aria-controls":"download"}," Can I download an anonymized repository? ")])]),n("div",{id:"download",class:"panel-collapse collapse",role:"tabpanel","aria-labelledby":"headingDownload"},[n("div",{class:"panel-body p-3"},[n("p",null," Yes. Anonymized repositories can be downloaded as a ZIP file. This is useful if reviewers want to build or test the code locally. The downloaded archive contains the fully anonymized version of the repository. ")])])]),n("div",{class:"panel panel-default mb-3"},[n("div",{class:"panel-heading p-3",role:"tab",id:"headingUpdates"},[n("h3",{class:"panel-title"},[n("a",{class:"collapsed",role:"button","data-toggle":"collapse","data-parent":"#faq-features",href:"#updates","aria-expanded":"false","aria-controls":"updates"}," Are updates to the original repository reflected in the anonymized version? ")])]),n("div",{id:"updates",class:"panel-collapse collapse",role:"tabpanel","aria-labelledby":"headingUpdates"},[n("div",{class:"panel-body p-3"},[n("p",null," You can refresh the anonymized repository from GitHub without creating a new share link. Free accounts can request a manual refresh within their allowance. Automatic refresh requires an eligible paid allowance and must be enabled in repository settings. It pauses when the repository falls back to the free allowance. "),n("p",null," After changing files or contributor names, review your anonymization terms before sharing the updated content. If GitHub access is revoked or the source is deleted, the service cannot fetch updates. ")])])]),n("div",{class:"panel panel-default mb-3"},[n("div",{class:"panel-heading p-3",role:"tab",id:"headingCLI"},[n("h3",{class:"panel-title"},[n("a",{class:"collapsed",role:"button","data-toggle":"collapse","data-parent":"#faq-features",href:"#cli","aria-expanded":"false","aria-controls":"cli"}," Is there a command-line tool? ")])]),n("div",{id:"cli",class:"panel-collapse collapse",role:"tabpanel","aria-labelledby":"headingCLI"},[n("div",{class:"panel-body p-3"},[n("p",null," Yes. Anonymous GitHub provides a CLI tool that lets you anonymize repositories locally, generating an anonymized ZIP file on your machine. Install it via npm: "),n("pre",{style:{"background-color":"var(--hover-bg-color)",padding:"12px","border-radius":"4px","margin-top":"8px",color:"var(--color)"}},[n("code",null,`npm install -g @tdurieux/anonymous_github -anonymous_github`)])])])])]),f(" Limitations "),n("h4",{class:"faq-cat"},[n("svg",{class:"ui-icon mr-2","aria-hidden":"true"},[n("use",{href:"#ui-icon-warning"})]),g("Limitations ")]),n("div",{class:"panel-group",id:"faq-limitations",role:"tablist","aria-multiselectable":"true"},[n("div",{class:"panel panel-default mb-3"},[n("div",{class:"panel-heading p-3",role:"tab",id:"headingLimitation"},[n("h3",{class:"panel-title"},[n("a",{class:"collapsed",role:"button","data-toggle":"collapse","data-parent":"#faq-limitations",href:"#limitation","aria-expanded":"false","aria-controls":"limitation"}," What are the limitations of Anonymous GitHub? ")])]),n("div",{id:"limitation",class:"panel-collapse collapse",role:"tabpanel","aria-labelledby":"headingLimitation"},[n("div",{class:"panel-body p-3"},[n("ul",null,[n("li",null," Anonymous GitHub only anonymizes text-based files. Binary files (compiled executables, archives, etc.) are served as-is without anonymization. "),n("li",null," Files larger than 8 MB are not supported. "),n("li",null," Static site generators (such as Jekyll) used with GitHub Pages are not fully supported, although Markdown files are converted to HTML. "),n("li",null," The anonymization of terms within source code may change the behavior of the program (e.g., if a replaced term appears in a string literal or identifier). ")])])])])]),f(" Privacy and security "),n("h4",{class:"faq-cat"},[n("svg",{class:"ui-icon mr-2","aria-hidden":"true"},[n("use",{href:"#ui-icon-shield"})]),g("Privacy and security ")]),n("div",{class:"panel-group",id:"faq-privacy",role:"tablist","aria-multiselectable":"true"},[n("div",{class:"panel panel-default mb-3"},[n("div",{class:"panel-heading p-3",role:"tab",id:"headingData"},[n("h3",{class:"panel-title"},[n("a",{class:"collapsed",role:"button","data-toggle":"collapse","data-parent":"#faq-privacy",href:"#data","aria-expanded":"false","aria-controls":"data"}," How is my data handled? ")])]),n("div",{id:"data",class:"panel-collapse collapse",role:"tabpanel","aria-labelledby":"headingData"},[n("div",{class:"panel-body p-3"},[n("p",null," Repository data is used to provide the anonymization service. If you purchase a plan, Stripe processes payment and billing information. When a repository is removed or expires, only its configuration is retained. This makes it easy to restore the repository if needed and ensures that no future repository reuses the same ID. ")])])]),n("div",{class:"panel panel-default mb-3"},[n("div",{class:"panel-heading p-3",role:"tab",id:"headingPermissions"},[n("h3",{class:"panel-title"},[n("a",{class:"collapsed",role:"button","data-toggle":"collapse","data-parent":"#faq-privacy",href:"#permissions","aria-expanded":"false","aria-controls":"permissions"}," Why does GitHub say Anonymous GitHub asks for write access? ")])]),n("div",{id:"permissions",class:"panel-collapse collapse",role:"tabpanel","aria-labelledby":"headingPermissions"},[n("div",{class:"panel-body p-3"},[n("p",null,[g("The GitHub App has read-only access to the repositories you choose. You can change repository access on your "),n("a",{href:"/connections"},"GitHub connections"),g(" page.")]),n("p",null,"Legacy GitHub OAuth includes write access to private repositories because GitHub's OAuth scopes do not offer a read-only option for them. Existing OAuth anonymizations and gists can still use this connection."),n("p",null,"Anonymous GitHub reads repository content. It never pushes, modifies, or deletes files on GitHub.")])])]),n("div",{class:"panel panel-default mb-3"},[n("div",{class:"panel-heading p-3",role:"tab",id:"headingViewer"},[n("h3",{class:"panel-title"},[n("a",{class:"collapsed",role:"button","data-toggle":"collapse","data-parent":"#faq-privacy",href:"#viewer","aria-expanded":"false","aria-controls":"viewer"}," Can repository owners see who viewed their anonymized repository? ")])]),n("div",{id:"viewer",class:"panel-collapse collapse",role:"tabpanel","aria-labelledby":"headingViewer"},[n("div",{class:"panel-body p-3"},[n("p",null," No. Only the total number of views is tracked as an incremental counter. It is not possible for the repository owner or for Anonymous GitHub to identify individual viewers. Reviewer anonymity is fully preserved. ")])])])]),f(" Self-hosting "),n("h4",{class:"faq-cat"},[n("svg",{class:"ui-icon mr-2","aria-hidden":"true"},[n("use",{href:"#project-icon-storage"})]),g("Self"),n("span",{class:"serif-hy"},"-"),g("hosting ")]),n("div",{class:"panel-group",id:"faq-hosting",role:"tablist","aria-multiselectable":"true"},[n("div",{class:"panel panel-default mb-3"},[n("div",{class:"panel-heading p-3",role:"tab",id:"headingDeploy"},[n("h3",{class:"panel-title"},[n("a",{class:"collapsed",role:"button","data-toggle":"collapse","data-parent":"#faq-hosting",href:"#deploy","aria-expanded":"false","aria-controls":"deploy"}," Can I deploy my own instance? ")])]),n("div",{id:"deploy",class:"panel-collapse collapse",role:"tabpanel","aria-labelledby":"headingDeploy"},[n("div",{class:"panel-body p-3"},[n("p",null,[g(" Yes. Anonymous GitHub is fully open source (GPL-3.0) and supports Docker-based deployment. Billing is optional and disabled by default for self-hosted instances; paid hosted plans are not required to run your own server. You will need to configure a GitHub OAuth app and provide a GitHub token. Detailed setup instructions are available on the "),n("a",{href:"https://github.com/tdurieux/anonymous_github/",target:"_blank"},"GitHub repository"),g(". ")]),n("p",null," The basic steps are: "),n("ol",null,[n("li",null,"Clone the repository and install dependencies"),n("li",null,[g("Create a "),n("code",null,".env"),g(" file with your GitHub token, OAuth client ID, and client secret")]),n("li",null,[g("Run "),n("code",null,"docker-compose up -d")])])])])])])],-1))],2),t[11]||(t[11]=n("aside",{class:"paper-faq-help","aria-label":"More help"},[n("div",{class:"paper-faq-help-card"},[n("strong",null,"Still stuck?"),n("p",null,"Open an issue on GitHub about the service. For a paper's content, contact the conference instead."),n("a",{class:"btn btn-outline-ink btn-sm",target:"_blank",rel:"noopener",href:"https://github.com/tdurieux/anonymous_github/issues/new?template=issue_report.yml"},"Open an issue")])],-1))])]),Oe(s,{name:"partials/footer.htm",state:e.viewState},null,8,["state"])],64)}var oF={class:"pr-page"},iF={class:"container paper-page pr-page-inner"},rF={class:"pr-header"},aF={class:"pr-title-row"},lF={class:"paper-page-title pr-title"},dF=["textContent"],uF={key:1,class:"text-muted"},cF=["href"],pF={class:"pr-header-meta"},fF={key:0,class:"pr-meta-item"},hF=["textContent"],mF={key:1,class:"pr-meta-item"},gF=["textContent"],vF={key:2,class:"pr-meta-item"},yF=["textContent"],bF={key:0,class:"paper-tabs",role:"tablist"},wF=["aria-selected","tabindex"],kF=["textContent"],CF=["aria-selected","tabindex"],EF=["textContent"],SF={class:"paper-tab-content"},NF={key:0,role:"tabpanel",id:"gist-files-panel","aria-labelledby":"gist-files-tab"},RF={class:"pr-comments"},AF={class:"pr-comment"},PF={class:"pr-comment-head"},DF=["textContent"],TF={key:0,class:"pr-comment-date"},OF={key:0,class:"paper-table-empty"},IF={key:1,role:"tabpanel",id:"gist-comments-panel","aria-labelledby":"gist-comments-tab"},MF={class:"pr-comments"},VF={class:"pr-comment"},qF={class:"pr-comment-head"},_F={key:0,class:"pr-comment-author"},LF=["textContent"],$F=["textContent"],FF={key:0,class:"pr-comment-body"},UF={key:0,class:"paper-table-empty"};function mp(e,t){let s=Xe("gist-file"),i=Xe("markdown");return a(),l("div",oF,[n("div",iF,[t[17]||(t[17]=n("div",{class:"paper-crumbs"},[n("a",{href:"/dashboard"},"Reviewer"),g(" \xA0/\xA0 "),n("span",{class:"here"},"Gist")],-1)),n("header",rF,[n("div",aF,[n("h1",lF,[e.details?.description?(a(),l("span",{key:0,textContent:c(e.details?.description)},null,8,dF)):f("v-if",!0),e.details?.description?f("v-if",!0):(a(),l("span",uF,"Untitled gist"))]),e.options?.isAdmin||e.options?.isOwner?(a(),l("a",{key:0,class:"btn btn-sm","aria-label":"Edit",href:e.safeUrl("/gist-anonymize/"+e.gistId)},[...t[4]||(t[4]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-edit"})],-1),n("span",{class:"d-none d-md-inline"}," Edit",-1)])],8,cF)):f("v-if",!0)]),n("div",pF,[n("span",{class:A(["paper-pill",{good:e.details?.isPublic,warn:!e.details?.isPublic}])},c(e.details?.isPublic?"Public":"Secret"),3),e.details?.ownerLogin?(a(),l("span",fF,[t[5]||(t[5]=n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-user"})],-1)),t[6]||(t[6]=g(" @",-1)),n("span",{textContent:c(e.details?.ownerLogin)},null,8,hF)])):f("v-if",!0),e.details?.updatedDate?(a(),l("span",mF,[t[7]||(t[7]=n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#project-icon-clock"})],-1)),t[8]||(t[8]=g()),n("span",{textContent:c(e.fmt?.date(e.details?.updatedDate))},null,8,gF)])):f("v-if",!0),e.details?.anonymizeDate?(a(),l("span",vF,[t[9]||(t[9]=n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-shield"})],-1)),t[10]||(t[10]=g(" Anonymized ",-1)),n("span",{textContent:c(e.fmt?.date(e.details?.anonymizeDate))},null,8,yF)])):f("v-if",!0)])]),e.details?.files&&e.details?.files?.length||e.details?.comments&&e.details?.comments?.length?(a(),l("nav",bF,[e.details?.files?(a(),l("button",{key:0,class:A(["paper-tab",{active:e.tabState?.active=="files"}]),type:"button",role:"tab",id:"gist-files-tab","aria-selected":e.tabState?.active==="files","aria-controls":"gist-files-panel",tabindex:e.tabState?.active==="files"?0:-1,onKeydown:t[0]||(t[0]=o=>e.previewTabKeydown(o)),onClick:t[1]||(t[1]=o=>e.tabState.active="files")},[t[11]||(t[11]=n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#project-type-gist"})],-1)),n("span",{textContent:c(e.fmt.plural(e.details?.files?.length,{0:"No files",one:"1 file",other:"{} files"}))},null,8,kF)],42,wF)):f("v-if",!0),e.details?.comments?(a(),l("button",{key:1,class:A(["paper-tab",{active:e.tabState?.active=="comments"}]),type:"button",role:"tab",id:"gist-comments-tab","aria-selected":e.tabState?.active==="comments","aria-controls":"gist-comments-panel",tabindex:e.tabState?.active==="comments"?0:-1,onKeydown:t[2]||(t[2]=o=>e.previewTabKeydown(o)),onClick:t[3]||(t[3]=o=>e.tabState.active="comments")},[t[12]||(t[12]=n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-comment"})],-1)),n("span",{textContent:c(e.fmt.plural(e.details?.comments?.length,{0:"No comments",one:"1 comment",other:"{} comments"}))},null,8,EF)],42,CF)):f("v-if",!0)])):f("v-if",!0),n("div",SF,[e.details?.files&&e.tabState?.active=="files"?(a(),l("div",NF,[n("ul",RF,[(a(!0),l(q,null,Q(e.details?.files,(o,r)=>(a(),l("li",AF,[n("div",PF,[n("strong",{textContent:c(o?.filename)},null,8,DF),o?.language?(a(),l("span",TF,c(o?.language),1)):f("v-if",!0)]),Oe(s,{file:o},null,8,["file"])]))),256)),e.details?.files?.length?f("v-if",!0):(a(),l("li",OF,[...t[13]||(t[13]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#project-icon-file"})],-1),n("span",null,"No files in this gist.",-1)])]))])])):f("v-if",!0),e.details?.comments&&e.tabState?.active=="comments"?(a(),l("div",IF,[n("ul",MF,[(a(!0),l(q,null,Q(e.details?.comments,(o,r)=>(a(),l("li",VF,[n("div",qF,[o?.author?(a(),l("span",_F,[t[14]||(t[14]=n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-user"})],-1)),t[15]||(t[15]=g(" @",-1)),n("span",{textContent:c(o?.author)},null,8,LF)])):f("v-if",!0),o?.updatedDate?(a(),l("span",{key:1,class:"pr-comment-date",textContent:c(e.fmt?.date(o?.updatedDate))},null,8,$F)):f("v-if",!0)]),o?.body?(a(),l("div",FF,[Oe(i,{content:o?.body},null,8,["content"])])):f("v-if",!0)]))),256)),e.details?.comments?.length?f("v-if",!0):(a(),l("li",UF,[...t[16]||(t[16]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-comment"})],-1),n("span",null,"No comments on this gist.",-1)])]))])])):f("v-if",!0)])])])}var BF={key:0,class:"nav-support",href:"https://ko-fi.com/tdurieux",target:"_blank",rel:"noopener",title:"Donate on Ko-fi to help cover hosting costs","aria-label":"Donate on Ko-fi to help cover hosting costs"},zF={key:1,class:"nav-heart-m",href:"https://ko-fi.com/tdurieux",target:"_blank",rel:"noopener","aria-label":"Support Anonymous GitHub",title:"Support Anonymous GitHub"},HF=["aria-label","title"],jF={class:"ui-icon","aria-hidden":"true"},GF=["href"],WF={key:3,class:"nav-signin-m",href:"/signin",target:"_self","aria-label":"Sign in with GitHub"},KF={class:"collapse navbar-collapse",id:"navbarSupportedContent"},YF={class:"navbar-nav mr-auto smooth-scroll"},XF={key:0,class:"nav-item nav-home-item"},JF={key:1,class:"nav-item"},QF={key:2,class:"nav-item"},ZF={key:3,class:"nav-item"},xF={class:"nav-item"},eU={key:4,class:"nav-item"},tU={class:"navbar-nav"},nU={key:0,class:"nav-item d-lg-none"},sU={key:1,class:"nav-item"},oU={key:2,class:"nav-item"},iU={key:3,class:"nav-item nav-signin-item"},rU={key:4,class:"nav-item"},aU={key:5,class:"nav-item dropdown user-chip-wrap"},lU={class:"nav-link user-chip dropdown-toggle",href:"#",id:"navbarDropdownMenuLink",role:"button","data-toggle":"dropdown","aria-haspopup":"true","aria-expanded":"false"},dU=["src"],uU={class:"user-chip-name"},cU={class:"dropdown-menu dropdown-menu-right user-menu","aria-labelledby":"navbarDropdownMenuLink"},pU={class:"dropdown-header"},fU={key:0,class:"dropdown-item um-extra",href:"https://ko-fi.com/tdurieux",target:"_blank",rel:"noopener"},hU=["innerHTML"],mU=["disabled"],gU={key:0,class:"paper-inline-alert paper-inline-alert-error",role:"alert"},vU={class:"email-prompt-actions"},yU=["disabled"],bU=["disabled"],wU=["disabled"];function gp(e,t){return a(),l(q,null,[n("nav",{class:A(["navbar navbar-expand-lg",{"navbar-dark":e.isDarkMode}])},[t[28]||(t[28]=n("a",{class:"navbar-brand",href:"/"},[g("Anonymous "),n("em",null,"GitHub")],-1)),e.headerShowSupport?(a(),l("a",BF,[...t[9]||(t[9]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-heart"})],-1),n("span",{class:"nav-support-label"},"Support",-1)])])):f("v-if",!0),/^\/(r|w|pr|gist)\//.test(e.path||"")?f("v-if",!0):(a(),l("a",zF,[...t[10]||(t[10]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-heart"})],-1)])])),/^\/(r|w|pr|gist)\//.test(e.path||"")?f("v-if",!0):(a(),l("button",{key:2,type:"button",class:"nav-theme-m","aria-label":e.isDarkMode?"Switch to light mode":"Switch to dark mode",title:e.isDarkMode?"Switch to light mode":"Switch to dark mode",onClick:t[0]||(t[0]=s=>e.darkMode(!e.isDarkMode))},[(a(),l("svg",jF,[n("use",{href:e.isDarkMode?"#ui-icon-sun":"#ui-icon-moon"},null,8,GF)]))],8,HF)),!e.user&&!/^\/(r|w|pr|gist)\//.test(e.path||"")?(a(),l("a",WF,[...t[11]||(t[11]=[n("i",{class:"fab fa-github","aria-hidden":"true"},null,-1),g("Sign in",-1)])])):f("v-if",!0),t[29]||(t[29]=n("button",{class:"navbar-toggler",type:"button","data-toggle":"collapse","data-target":"#navbarSupportedContent","aria-controls":"navbarSupportedContent","aria-expanded":"false","aria-label":"Toggle navigation"},[n("span",{class:"navbar-toggler-icon"})],-1)),n("div",KF,[n("ul",YF,[e.user?f("v-if",!0):(a(),l("li",XF,[n("a",{class:A(["nav-link",{active:e.path=="/"}]),href:"/"},[...t[12]||(t[12]=[n("svg",{class:"ui-icon d-lg-none mr-1","aria-hidden":"true"},[n("use",{href:"#ui-icon-home"})],-1),g(" Home ",-1)])],2)])),e.user?(a(),l("li",JF,[n("a",{class:A(["nav-link",{active:e.path=="/dashboard"}]),href:"/dashboard"},[...t[13]||(t[13]=[n("svg",{class:"ui-icon d-lg-none mr-1","aria-hidden":"true"},[n("use",{href:"#ui-icon-grid"})],-1),g(" My work ",-1)])],2)])):f("v-if",!0),e.user?(a(),l("li",QF,[n("a",{class:A(["nav-link",{active:e.path=="/anonymize"||e.path=="/pull-request-anonymize"}]),href:"/anonymize"},[...t[14]||(t[14]=[n("svg",{class:"ui-icon d-lg-none mr-1","aria-hidden":"true"},[n("use",{href:"#ui-icon-shield"})],-1),g(" Anonymize ",-1)])],2)])):f("v-if",!0),e.user?(a(),l("li",ZF,[n("a",{class:A(["nav-link",{active:e.path=="/conferences"||e.path?.startsWith("/conference/")}]),href:"/conferences"},[...t[15]||(t[15]=[n("svg",{class:"ui-icon d-lg-none mr-1","aria-hidden":"true"},[n("use",{href:"#project-icon-conference"})],-1),g(" Conferences ",-1)])],2)])):f("v-if",!0),n("li",xF,[n("a",{class:A(["nav-link",{active:e.path=="/faq"}]),href:"/faq"},[...t[16]||(t[16]=[n("svg",{class:"ui-icon d-lg-none mr-1","aria-hidden":"true"},[n("use",{href:"#ui-icon-help"})],-1),g("FAQ",-1)])],2)]),e.user&&e.user?.isAdmin?(a(),l("li",eU,[n("a",{class:A(["nav-link",{active:e.path?.indexOf("/admin")===0}]),href:"/admin/"},[...t[17]||(t[17]=[n("svg",{class:"ui-icon d-lg-none mr-1","aria-hidden":"true"},[n("use",{href:"#ui-icon-user-shield"})],-1),g(" Admin ",-1)])],2)])):f("v-if",!0)]),n("ul",tU,[e.user||!e.isReviewerRoute?(a(),l("li",nU,[...t[18]||(t[18]=[n("a",{class:"nav-link nav-icon",target:"_blank",href:"https://github.com/tdurieux/anonymous_github/",title:"Anonymous GitHub source code","aria-label":"Anonymous GitHub source code on GitHub",rel:"noopener","data-offset":"30"},[n("i",{class:"fab fa-github","aria-hidden":"true"})],-1)])])):f("v-if",!0),f(` "Report a bug" is about this service. Reviewers who land on an +jane.smith@example.org`},null,10,F3),[[d,{state:e.viewState,set:u=>{e.terms=u},value:e.terms,form:"anonymize",options:{debounce:250}}]]),t[126]||(t[126]=n("small",{class:"form-text text-muted"},"One term per line.",-1)),n("details",U3,[t[121]||(t[121]=n("summary",null,"Regex & replacement syntax",-1)),t[122]||(t[122]=g()),n("small",B3,[t[115]||(t[115]=g("Regex is supported. Replaced by ",-1)),n("code",null,c(e.site_options?.ANONYMIZATION_MASK)+"-[N]",1),t[116]||(t[116]=g(", or use ",-1)),t[117]||(t[117]=n("code",null,"term=>replacement",-1)),t[118]||(t[118]=g(" to pick your own (e.g. ",-1)),t[119]||(t[119]=n("code",null,"Anonymous=>ABC",-1)),t[120]||(t[120]=g(").",-1))])]),(a(!0),l(q,null,Q((e.termHints||[]).slice(0,3),u=>(a(),l("div",{class:"term-hint",key:u.line},[n("span",null,[t[123]||(t[123]=g("In ",-1)),n("code",null,c(u.term),1),t[124]||(t[124]=g(", ",-1)),n("code",null,c(u.symbols.join(" ")),1),g(" "+c(u.symbols.length>1?"are regex symbols":"is a regex symbol")+", so it may not match the text as written.",1)]),n("button",{type:"button",class:"btn btn-outline-ink btn-sm",onClick:y=>e.matchTermAsWritten(u.line)},"Match as written",8,z3)]))),128)),(e.termHints||[]).length>3?(a(),l("div",H3,c(e.termHints.length-3)+" more "+c(e.termHints.length-3===1?"term uses":"terms use")+" regex symbols.",1)):f("v-if",!0),T(n("div",j3,"Terms are in an invalid format.",512),[[Z,e.anonymize?.terms?.errors?.format]])]),T(n("div",G3,[n("div",W3,[t[127]||(t[127]=n("span",{class:"paper-field-label",id:"preserve-files-label"},"Unredacted files",-1)),n("span",K3,c(e.preserveSummary()),1)]),n("button",{type:"button",class:"btn btn-outline-ink btn-sm","aria-describedby":"preserve-files-label",disabled:!e.source?.commit,onClick:t[22]||(t[22]=u=>e.openPreserveFiles())},c((e.options?.preserveFiles||[]).length?"Edit":"Choose files"),9,Y3)],512),[[Z,e.detectedType==="repo"]]),e.preserve?.open?(a(),l("dialog",{key:0,id:"preserve-files-dialog",class:"preserve-dialog","aria-labelledby":"preserve-files-title",onCancel:t[27]||(t[27]=ae(u=>e.closePreserveFiles(),["prevent"]))},[n("form",{onSubmit:t[26]||(t[26]=ae(u=>e.savePreserveFiles(),["prevent"]))},[t[131]||(t[131]=n("h2",{id:"preserve-files-title"},"Leave files unredacted",-1)),t[132]||(t[132]=n("p",{class:"preserve-intro"},"Checked files are shown exactly as written, for example a bibliography where redacted self-citations would reveal you. File names are still redacted.",-1)),T(n("input",{type:"search",id:"preserve-files-search",class:"form-control",placeholder:"Search files","aria-label":"Search files",autocomplete:"off","onUpdate:modelValue":t[23]||(t[23]=u=>e.preserve.search=u)},null,512),[[rt,e.preserve.search]]),n("div",X3,[e.preserve.loading?(a(),l("p",J3,"Loading files from GitHub\u2026")):e.preserve.error?(a(),l("p",Q3,c(e.preserve.error),1)):(a(),l(q,{key:2},[(a(!0),l(q,null,Q(e.preserveRows(),(u,y)=>(a(),l("div",{class:"preserve-item",key:u.kind+":"+u.path,style:Te({paddingLeft:u.depth*18+6+"px"})},[u.kind==="dir"?(a(),l("button",{key:0,type:"button",class:"preserve-caret","aria-expanded":u.open?"true":"false","aria-label":(u.open?"Collapse ":"Expand ")+u.label,onClick:h=>e.togglePreserveDir(u.path)},c(u.open?"\u25BE":"\u25B8"),9,Z3)):(a(),l("span",x3)),n("input",{type:"checkbox",id:"pf-"+y,"aria-label":u.kind==="dir"?"Leave folder "+u.path+" unredacted":null,checked:u.state==="all",".indeterminate":u.state==="some",disabled:u.locked,onChange:h=>u.kind==="dir"?e.togglePreserveFolder(u.path):e.togglePreserveFile(u.path)},null,40,eO),n("label",{for:u.kind==="file"?"pf-"+y:null,class:"preserve-name",onClick:h=>u.kind==="dir"&&e.togglePreserveDir(u.path)},c(u.label),9,tO),u.note?(a(),l("span",nO,c(u.note),1)):f("v-if",!0)],4))),128)),!e.preserve.loading&&!e.preserveRows().length?(a(),l("p",sO,c(e.preserve.search?"No file matches your search.":"No text files in this commit."),1)):f("v-if",!0)],64))]),e.preserve.truncated?(a(),l("p",oO,"This repository has too many files to list them all. Use a pattern for files you cannot find.")):f("v-if",!0),n("details",{class:"preserve-patterns",open:e.preserve.patternsOpen},[t[128]||(t[128]=n("summary",null,"Patterns",-1)),T(n("textarea",{class:"form-control",rows:"3","aria-label":"Patterns",placeholder:`*.bib +paper/appendix/**`,"onUpdate:modelValue":t[24]||(t[24]=u=>e.preserve.patterns=u)},null,512),[[rt,e.preserve.patterns]]),t[129]||(t[129]=n("small",{class:"form-text text-muted"},[g("One per line, as in .gitignore: "),n("code",null,"*.bib"),g(" matches in any folder; "),n("code",null,"/refs.bib"),g(" and "),n("code",null,"paper/refs.bib"),g(" match from the repository root; a folder name such as "),n("code",null,"drafts/"),g(" covers everything inside it; "),n("code",null,"!private.bib"),g(" excludes again.")],-1))],8,iO),n("div",rO,[n("span",aO,c(e.preserve.loading||e.preserve.error?"":e.preserveCount()+(e.preserveCount()===1?" file":" files")+" will be shown as written"),1),n("span",lO,[n("button",{type:"button",class:"btn btn-outline-ink",onClick:t[25]||(t[25]=u=>e.closePreserveFiles())},"Cancel"),t[130]||(t[130]=n("button",{type:"submit",class:"btn btn-ink"},"Save",-1))])])],32)],32)):f("v-if",!0)],512),[[Z,e.detectedType]]),T(n("section",dO,[t[153]||(t[153]=n("h2",{class:"paper-section-eyebrow"},"Display",-1)),T(n("div",null,[n("div",uO,[T(n("input",cO,null,512),[[d,{state:e.viewState,set:u=>{e.options.link=u},value:e.options?.link,form:"anonymize",options:{}}]]),t[134]||(t[134]=n("label",{class:"form-check-label",for:"link"},"Keep links",-1))]),n("div",pO,[T(n("input",fO,null,512),[[d,{state:e.viewState,set:u=>{e.options.image=u},value:e.options?.image,form:"anonymize",options:{}}]]),t[135]||(t[135]=n("label",{class:"form-check-label",for:"image"},"Display images",-1))]),n("div",mO,[T(n("input",hO,null,512),[[d,{state:e.viewState,set:u=>{e.options.pdf=u},value:e.options?.pdf,form:"anonymize",options:{}}]]),t[136]||(t[136]=n("label",{class:"form-check-label",for:"pdf"},"Display PDFs",-1))]),n("div",gO,[T(n("input",vO,null,512),[[d,{state:e.viewState,set:u=>{e.options.notebook=u},value:e.options?.notebook,form:"anonymize",options:{}}]]),t[137]||(t[137]=n("label",{class:"form-check-label",for:"notebook"},"Display notebooks",-1))]),n("div",yO,[T(n("input",{class:"form-check-input",type:"checkbox",id:"page",name:"page",disabled:!e.details?.hasPage||e.details?.pageSource&&e.details?.pageSource?.branch!==e.source?.branch},null,8,bO),[[d,{state:e.viewState,set:u=>{e.options.page=u},value:e.options?.page,form:"anonymize",options:{}}]]),t[138]||(t[138]=n("label",{class:"form-check-label",for:"page"},"GitHub Pages",-1)),e.details?.hasPage?f("v-if",!0):(a(),l("small",wO,c(e.fmt?.translate("WARNINGS.page_not_enabled_on_repo")),1)),e.details?.hasPage&&e.details?.pageSource?.branch&&e.source?.branch&&e.details.pageSource.branch!==e.source.branch?(a(),l("small",kO,c(e.fmt?.translate("WARNINGS.page_branch_mismatch",{pageBranch:e.details?.pageSource?.branch,selectedBranch:e.source?.branch})),1)):f("v-if",!0)])],512),[[Z,e.detectedType==="repo"]]),e.detectedType==="repo"&&(e.options.image||e.options.pdf)?(a(),l("p",CO,[...t[139]||(t[139]=[g("Images and PDFs are served unchanged. Review their contents and metadata before sharing. ",-1),n("a",{href:"/faq#formats"},"Supported formats",-1)])])):f("v-if",!0),T(n("div",null,[n("div",EO,[T(n("input",SO,null,512),[[d,{state:e.viewState,set:u=>{e.options.title=u},value:e.options?.title,form:"anonymize",options:{}}]]),t[140]||(t[140]=n("label",{class:"form-check-label",for:"title-gist"},"Gist description",-1))]),n("div",NO,[T(n("input",RO,null,512),[[d,{state:e.viewState,set:u=>{e.options.content=u},value:e.options?.content,form:"anonymize",options:{}}]]),t[141]||(t[141]=n("label",{class:"form-check-label",for:"content-gist"},"File contents",-1))]),n("div",PO,[T(n("input",DO,null,512),[[d,{state:e.viewState,set:u=>{e.options.comments=u},value:e.options?.comments,form:"anonymize",options:{}}]]),t[142]||(t[142]=n("label",{class:"form-check-label",for:"comments-gist"},"Comments",-1))]),n("div",AO,[T(n("input",TO,null,512),[[d,{state:e.viewState,set:u=>{e.options.username=u},value:e.options?.username,form:"anonymize",options:{}}]]),t[143]||(t[143]=n("label",{class:"form-check-label",for:"username-gist"},"Usernames",-1))]),n("div",OO,[T(n("input",IO,null,512),[[d,{state:e.viewState,set:u=>{e.options.date=u},value:e.options?.date,form:"anonymize",options:{}}]]),t[144]||(t[144]=n("label",{class:"form-check-label",for:"date-gist"},"Dates",-1))]),n("div",MO,[T(n("input",VO,null,512),[[d,{state:e.viewState,set:u=>{e.options.origin=u},value:e.options?.origin,form:"anonymize",options:{}}]]),t[145]||(t[145]=n("label",{class:"form-check-label",for:"origin-gist"},"Source gist ID",-1))])],512),[[Z,e.detectedType==="gist"]]),T(n("div",null,[n("div",qO,[T(n("input",_O,null,512),[[d,{state:e.viewState,set:u=>{e.options.title=u},value:e.options?.title,form:"anonymize",options:{}}]]),t[146]||(t[146]=n("label",{class:"form-check-label",for:"title"},"PR title",-1))]),n("div",LO,[T(n("input",$O,null,512),[[d,{state:e.viewState,set:u=>{e.options.body=u},value:e.options?.body,form:"anonymize",options:{}}]]),t[147]||(t[147]=n("label",{class:"form-check-label",for:"body"},"PR body",-1))]),n("div",FO,[T(n("input",UO,null,512),[[d,{state:e.viewState,set:u=>{e.options.diff=u},value:e.options?.diff,form:"anonymize",options:{}}]]),t[148]||(t[148]=n("label",{class:"form-check-label",for:"diff"},"Diff",-1))]),n("div",BO,[T(n("input",zO,null,512),[[d,{state:e.viewState,set:u=>{e.options.comments=u},value:e.options?.comments,form:"anonymize",options:{}}]]),t[149]||(t[149]=n("label",{class:"form-check-label",for:"comments"},"Comments",-1))]),n("div",HO,[T(n("input",jO,null,512),[[d,{state:e.viewState,set:u=>{e.options.username=u},value:e.options?.username,form:"anonymize",options:{}}]]),t[150]||(t[150]=n("label",{class:"form-check-label",for:"username"},"Usernames",-1))]),n("div",GO,[T(n("input",WO,null,512),[[d,{state:e.viewState,set:u=>{e.options.date=u},value:e.options?.date,form:"anonymize",options:{}}]]),t[151]||(t[151]=n("label",{class:"form-check-label",for:"date"},"Dates",-1))]),n("div",KO,[T(n("input",YO,null,512),[[d,{state:e.viewState,set:u=>{e.options.origin=u},value:e.options?.origin,form:"anonymize",options:{}}]]),t[152]||(t[152]=n("label",{class:"form-check-label",for:"origin"},"Project name",-1))])],512),[[Z,e.detectedType==="pr"]])],512),[[Z,e.detectedType]]),T(n("section",XO,[t[170]||(t[170]=n("h2",{class:"paper-section-eyebrow",id:"hosting-heading"},"Hosting & expiration",-1)),n("div",JO,[t[154]||(t[154]=n("label",{class:"paper-field-label",for:"conference"},[g("Conference code "),n("span",{class:"paper-optional"},"(optional)")],-1)),T(n("input",{class:P(["form-control",{"is-invalid":e.anonymize?.conference?.invalid}]),id:"conference",name:"conference"},null,2),[[d,{state:e.viewState,set:u=>{e.conference=u},value:e.conference,form:"anonymize",options:{debounce:{default:800,blur:0},updateOn:"default blur"}}]]),T(n("p",{class:P(["conference-hosting",{"is-covered":e.conferenceHosting()}]),role:"status"},[n("a",{target:"_blank",href:e.safeUrl(e.conference_data?.url)},c(e.conference_data?.name),9,QO),e.conferenceHosting()?(a(),l(q,{key:0},[g(" hosts this repository until "+c(e.fmt?.date(e.conference_data?.endDate))+", with automatic updates. You don't pay anything.",1)],64)):e.billing?.enabled&&e.detectedType==="repo"?(a(),l(q,{key:1},[g(" runs until "+c(e.fmt?.date(e.conference_data?.endDate))+". It doesn't pay for hosting, so this repository uses your own allowance.",1)],64)):(a(),l(q,{key:2},[g(" runs until "+c(e.fmt?.date(e.conference_data?.endDate))+".",1)],64))],2),[[Z,e.conference_data]]),T(n("div",ZO,"The conference is not activated.",512),[[Z,e.anonymize?.conference?.errors?.activated]]),T(n("small",xO,"Submitting to a conference? Its code applies the venue's settings, and a paid conference hosts the repository for you.",512),[[Z,!e.conference_data]])]),e.detectedType==="repo"&&e.billing?.enabled&&!e.conferenceHosting()?(a(),l("p",eI,[e.isUpdate&&e.role!=="owner"?(a(),l("span",tI,"Uses the owner's hosting")):e.hasAuthorHosting()?(a(),l("span",nI,"Your author subscription is active.")):e.hostingQuota?.repository?(a(),l("span",sI,c(e.hostingQuota.repository.used)+" of "+c(e.hostingQuota.repository.total)+" active repositories \xB7 Free",1)):f("v-if",!0)])):f("v-if",!0),e.detectedType==="repo"&&e.options?.update&&!e.liveUpdatesIncluded()?(a(),l("p",oI,[t[155]||(t[155]=g("Automatic updates need a paid option. On free hosting, the link keeps the version you create until you refresh it from My work. Once it exists, add Live updates",-1)),e.liveUpdatesPrice()?(a(),l(q,{key:0},[g(" ("+c(e.liveUpdatesPrice())+" once)",1)],64)):f("v-if",!0),t[156]||(t[156]=g(" or a Paper pack in ",-1)),t[157]||(t[157]=n("a",{href:"/profile?billing=1"},"Settings \u203A Hosting & billing",-1)),t[158]||(t[158]=g(", or take an author subscription.",-1))])):f("v-if",!0),e.detectedType==="repo"&&e.billing?.enabled?(a(),l("div",iI,[e.hostingNeedsPayment()&&!e.billingPending?(a(),l(q,{key:0},[e.options.expirationMode!=="never"||e.hostingQuotaBlocked?(a(),l("p",rI,c(e.options.update&&!e.hostingQuotaBlocked&&e.hostingQuota?.repository?.used(a(),l("label",{class:P(["hosting-option",{"is-selected":e.hostingChoice()===u.id||u.interval&&e.authorPlans().some(y=>y.id===e.hostingChoice())}]),key:u.id},[n("input",{type:"radio",name:"hosting-plan",value:u.id,checked:e.hostingChoice()===u.id||u.interval&&e.authorPlans().some(y=>y.id===e.hostingChoice()),onChange:y=>e.hostingPlan=u.interval?e.hostingSubscriptionPlan().id:u.id},null,40,dI),n("span",uI,[n("strong",null,c(e.hostingOptionName(u)),1),n("small",null,c(e.hostingOptionBlurb(u)),1),u.interval&&e.authorPlans().length>1&&e.authorPlans().some(y=>y.id===e.hostingChoice())?(a(),l("span",cI,[(a(!0),l(q,null,Q(e.authorPlans(),y=>(a(),l("button",{type:"button",role:"radio",key:y.id,"aria-checked":e.hostingSubscriptionPlan().id===y.id?"true":"false",class:P({"is-on":e.hostingSubscriptionPlan().id===y.id}),onClick:ae(h=>{e.hostingCycle=y.id,e.hostingPlan=y.id},["prevent"])},[g(c(y.interval==="year"?"Yearly":"Monthly"),1),y.interval==="year"&&e.hostingAnnualSavings()?(a(),l("span",fI,"\u2212"+c(e.hostingAnnualSavings())+"%",1)):f("v-if",!0)],10,pI))),128))])):f("v-if",!0)]),n("span",mI,[n("strong",null,c(e.billingAmount(u.interval?e.hostingSubscriptionPlan():u)),1),n("small",null,c(u.interval?"per "+e.hostingSubscriptionPlan().interval:"once"),1)])],2))),128))])):(a(),l("p",hI,"New purchases are temporarily unavailable. Your draft is kept.")),e.authorPlans().some(u=>u.id===e.hostingChoice())?(a(),l("p",gI,"Renews "+c(e.hostingChoice()==="author_annual"?"yearly":"monthly")+" until you cancel. Tax shown at checkout.",1)):(a(),l("p",vI,"One-time payment, nothing renews. Tax shown at checkout.")),e.options.expirationMode!=="never"?(a(),l("details",yI,[t[159]||(t[159]=n("summary",null,"Keep using free hosting",-1)),t[160]||(t[160]=n("p",null,"Remove a repository you no longer need, or enter the code of a paid conference above. Removing a repository affects its review link.",-1)),t[161]||(t[161]=n("a",{href:"/dashboard"},"Review my repositories",-1)),n("button",{type:"button",class:"task-text-button",onClick:t[28]||(t[28]=u=>e.anonymizeRepo(u)),disabled:e.sourceLoading||e.billingBusy},"Recheck capacity and submit",8,bI)])):f("v-if",!0)],64)):f("v-if",!0)])):f("v-if",!0),e.hostingNeedsPayment()&&!e.billingPending?(a(),l("h4",wI,"Expiration")):f("v-if",!0),n("fieldset",kI,[t[167]||(t[167]=n("legend",{class:"sr-only"},"Expiration",-1)),n("label",CI,[n("input",{type:"radio",name:"expiration-choice",checked:e.options.expirationMode!=="never",onChange:t[29]||(t[29]=u=>e.useDatedHosting()),disabled:e.billingPending},null,40,EI),t[162]||(t[162]=n("span",null,"Expire on a date",-1))]),e.options.expirationMode!=="never"?(a(),l("div",SI,[e.options?.expirationMode!=="never"?(a(),l("div",NI,[t[163]||(t[163]=n("label",{class:"paper-field-label",for:"expirationDate"},"Expires",-1)),T(n("input",{class:P(["form-control",{"is-invalid":e.anonymize?.expirationDate?.invalid}]),type:"date",name:"expirationDate",id:"expirationDate",required:"",min:e.minExpirationDate,max:e.maxExpirationDate},null,10,RI),[[d,{state:e.viewState,set:u=>{e.options.expirationDate=u},value:e.options?.expirationDate,form:"anonymize",options:{}}]]),e.fmt?.dateEcho(e.options?.expirationDate)?(a(),l("p",PI,"Expires "+c(e.fmt?.dateEcho(e.options?.expirationDate)),1)):f("v-if",!0),T(n("div",DI,"Pick a date in the future.",512),[[Z,e.anonymize?.expirationDate?.errors?.min]]),T(n("div",{class:"invalid-feedback"},"Pick a date on or before "+c(e.fmt?.date(e.maxExpirationDate))+".",513),[[Z,e.anonymize?.expirationDate?.errors?.max]]),T(n("div",AI,"Enter a valid expiration date.",512),[[Z,e.anonymize?.expirationDate?.errors?.required||e.anonymize?.expirationDate?.errors?.date]])])):f("v-if",!0),n("div",TI,[t[165]||(t[165]=n("label",{for:"expiration"},"Then",-1)),T(n("select",{id:"expiration",class:"form-control","onUpdate:modelValue":t[30]||(t[30]=u=>e.options.expirationMode=u)},[...t[164]||(t[164]=[n("option",{value:"remove"},"Remove content",-1),n("option",{value:"redirect"},"Redirect to GitHub",-1)])],512),[[Wt,e.options.expirationMode]])])])):f("v-if",!0),e.detectedType==="repo"?(a(),l("label",OI,[n("input",{type:"radio",name:"expiration-choice",checked:e.options.expirationMode==="never",onChange:t[31]||(t[31]=u=>e.options.expirationMode="never"),disabled:e.billingPending},null,40,II),n("span",null,[t[166]||(t[166]=g("Never expire",-1)),(e.options.expirationMode!=="never"||e.hasAuthorHosting()||e.repositoryGrants("repo_never").length)&&!(e.hostingNeedsPayment()&&e.hostingOptionPlans().length)?(a(),l("small",MI,c(e.neverExpireTag()),1)):f("v-if",!0)])])):f("v-if",!0)]),e.options.expirationMode==="redirect"?(a(),l("p",VI,"Visitors will be redirected to the original GitHub source on this date, revealing its identity.")):f("v-if",!0),e.detectedType==="repo"&&e.billing?.enabled?(a(),l("div",qI,[e.taskValidationError?(a(),l("p",_I,c(e.taskValidationError),1)):f("v-if",!0),e.billingError?(a(),l("p",LI,[g(c(e.billingError)+" ",1),n("button",{type:"button",class:"task-text-button",onClick:t[32]||(t[32]=u=>e.loadBilling()),disabled:e.billingBusy},"Reload billing",8,$I)])):f("v-if",!0),e.billingPending?(a(),l("div",FI,[...t[168]||(t[168]=[n("p",null,[n("strong",null,"Confirming your payment\u2026")],-1),n("p",{class:"form-text text-muted"},"Your draft is saved. Please do not pay again.",-1)])])):e.billingNotice?(a(),l("p",UI,c(e.billingNotice),1)):e.options.expirationMode==="never"&&!e.billingPending&&!e.hasAuthorHosting()&&e.repositoryGrants("repo_never").length?(a(),l("p",BI,"No scheduled expiration. Paid once for this repository.")):e.options.expirationMode==="never"&&!e.billingPending?(a(),l("p",zI,"No scheduled expiration while subscribed. A 90-day grace period applies if paid access ends.")):f("v-if",!0),e.isUpdate&&e.role==="owner"&&!e.hasAuthorHosting()&&!e.hostingNeedsPayment()&&e.repositoryAddonPlans().length?(a(),l("details",HI,[t[169]||(t[169]=n("summary",null,"Pay once for just this repository",-1)),(a(!0),l(q,null,Q(e.repositoryAddonPlans(),u=>(a(),l("div",{key:u.id},[n("p",null,[n("strong",null,c(u.name),1),g(" \xB7 "+c(e.billingPrice(u))+". "+c(u.description),1)]),n("button",{type:"button",class:"btn btn-outline-ink",disabled:e.billingBusy||e.hostingSaving||e.sourceLoading||e.billing.checkoutEnabled===!1||e.billingPending,onClick:y=>e.checkoutRepository(u.id)},"Buy "+c(u.name.toLowerCase()),9,jI)]))),128))])):f("v-if",!0)])):f("v-if",!0)],512),[[Z,e.detectedType]]),T(n("section",GI,[t[174]||(t[174]=n("h2",{class:"paper-section-eyebrow"},"Co-authors",-1)),t[175]||(t[175]=n("p",{class:"form-text text-muted",style:{"margin-bottom":"8px"}}," Co-authors can view and edit these settings. They cannot delete the anonymization or manage co-authors. ",-1)),T(n("div",WI,[t[171]||(t[171]=n("label",{class:"paper-field-label",for:"coauthorSearch"},"Add a GitHub user",-1)),n("div",KI,[T(n("input",YI,null,512),[[d,{state:e.viewState,set:u=>{e.coauthorSearch=u},value:e.coauthorSearch,form:"anonymize",options:{debounce:300},change:()=>{e.searchCoauthors()}}]]),T(n("div",XI,[(a(!0),l(q,null,Q(e.coauthorResults,(u,y)=>(a(),l("a",{href:"#",class:"dropdown-item d-flex align-items-center",onClick:ae(h=>e.addCoauthor(u,h),["prevent"])},[n("img",{alt:"",style:{width:"22px",height:"22px","border-radius":"50%","margin-right":"8px"},src:e.safeUrl(u?.photo)},null,8,QI),n("span",{textContent:c(u?.username)},null,8,ZI)],8,JI))),256))],512),[[Z,e.coauthorResults?.length>0]])]),T(n("small",{class:"form-text text-muted",textContent:c(e.coauthorError)},null,8,xI),[[Z,e.coauthorError]])],512),[[Z,e.role==="owner"||e.role==="admin"]]),n("div",e5,[(a(!0),l(q,null,Q(e.coauthors,(u,y)=>(a(),l("div",t5,[u?.photo?(a(),l("img",{key:0,alt:"",style:{width:"24px",height:"24px","border-radius":"50%"},src:e.safeUrl(u?.photo)},null,8,n5)):f("v-if",!0),n("a",{target:"_blank",textContent:c(u?.username),href:e.safeUrl("https://github.com/"+u?.username)},null,8,s5),t[173]||(t[173]=n("span",{class:"type-badge type-coauthor"},"Co-author",-1)),T(n("button",{type:"button",class:"btn btn-sm btn-icon",style:{"margin-left":"auto"},title:"Remove co-author",onClick:h=>e.removeCoauthor(u),"aria-label":"Remove co-author"},[...t[172]||(t[172]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#project-icon-close"})],-1)])],8,o5),[[Z,e.role==="owner"||e.role==="admin"]])]))),256)),T(n("div",i5," No co-authors yet. ",512),[[Z,!e.coauthors||e.coauthors?.length===0]])])],512),[[Z,e.isUpdate&&e.detectedType==="repo"]]),e.error?(a(),l("div",{key:0,class:"alert alert-danger",role:"alert",textContent:c(e.error)},null,8,r5)):f("v-if",!0)]),n("button",{type:"button",class:"btn btn-outline-ink mobile-preview-jump",onClick:t[33]||(t[33]=u=>e.selectMobilePane("preview"))},[...t[176]||(t[176]=[g("Review preview ",-1),n("span",{"aria-hidden":"true"},"\u2192",-1)])]),T(n("div",a5,[e.detectedType==="repo"?(a(),l(q,{key:0},[e.billingPending?(a(),l("button",{key:0,type:"button",class:"btn btn-ink",onClick:t[34]||(t[34]=u=>e.refreshBilling()),disabled:e.billingBusy},"Check payment status",8,l5)):(a(),l("button",{key:1,type:"submit",class:"btn btn-ink",disabled:e.sourceLoading||e.billingBusy||e.hostingSaving||e.billingLoading||e.hostingNeedsPayment()&&(!e.authorPlans().length&&!e.hostingOneTime()||e.billing?.checkoutEnabled===!1),onClick:t[35]||(t[35]=ae(u=>e.submitForm(u,()=>{e.submitRepository(u)}),["prevent"]))},c(e.hostingSaving?"Saving draft\u2026":e.hostingNeedsPayment()?"Continue to checkout":e.isUpdate?"Save changes":"Create anonymous link"),9,d5))],64)):f("v-if",!0),e.detectedType==="pr"&&!e.isUpdate?(a(),l("button",{key:1,type:"submit",disabled:e.sourceLoading||!e.details,class:"btn btn-ink",onClick:t[36]||(t[36]=ae(u=>e.submitForm(u,()=>{e.anonymizePullRequest(u)}),["prevent"]))}," Create anonymous link ",8,u5)):f("v-if",!0),e.detectedType==="pr"&&e.isUpdate?(a(),l("button",{key:2,type:"submit",disabled:e.sourceLoading,class:"btn btn-ink",onClick:t[37]||(t[37]=ae(u=>e.submitForm(u,()=>{e.anonymizePullRequest(u)}),["prevent"]))}," Save changes ",8,c5)):f("v-if",!0),e.detectedType==="gist"&&!e.isUpdate?(a(),l("button",{key:3,type:"submit",disabled:e.sourceLoading||!e.details,class:"btn btn-ink",onClick:t[38]||(t[38]=ae(u=>e.submitForm(u,()=>{e.anonymizeGist(u)}),["prevent"]))}," Create anonymous link ",8,p5)):f("v-if",!0),e.detectedType==="gist"&&e.isUpdate?(a(),l("button",{key:4,type:"submit",disabled:e.sourceLoading,class:"btn btn-ink",onClick:t[39]||(t[39]=ae(u=>e.submitForm(u,()=>{e.anonymizeGist(u)}),["prevent"]))}," Save changes ",8,f5)):f("v-if",!0),e.sourceLoading?(a(),l("p",m5,c(e.detectedType==="pr"?"Waiting for the pull request to load from GitHub\u2026":e.detectedType==="gist"?"Waiting for the gist to load from GitHub\u2026":"Waiting for the repository to load from GitHub\u2026"),1)):!e.details&&!e.isUpdate?(a(),l("p",h5,"Load an accessible source to continue. See the preview for details.")):f("v-if",!0),e.hostingNeedsPayment()&&!e.billingPending?(a(),l("p",g5,"You pay in Stripe, then come back here to finish.")):f("v-if",!0),e.draftRestored?(a(),l("div",v5,[t[177]||(t[177]=g("Your unsaved draft was restored. ",-1)),n("button",{type:"button",class:"draft-discard",onClick:t[40]||(t[40]=u=>e.discardDraft())},"Discard draft")])):e.unsavedChanges?(a(),l("div",y5,[g(c(e.draftSaved?"Draft saved \xB7":"Unsaved changes \xB7")+" ",1),n("button",{type:"button",class:"draft-discard",onClick:t[41]||(t[41]=u=>e.discardDraft())},c(e.isUpdate?"Restore saved":"Discard"),1)])):f("v-if",!0)],512),[[Z,e.detectedType]])])),[[p,e.viewState]])],8,ST),f(' Preview column (right): "What reviewers will see", a miniature reviewer window '),e.detectedType?(a(),l("div",{key:0,id:"workspace-preview",role:e.mobileWorkspace?"tabpanel":null,"aria-labelledby":e.mobileWorkspace?"workspace-preview-tab":null,class:"anonymize-preview-col reviewer-preview"},[n("div",w5,[t[180]||(t[180]=n("span",{class:"rp-title"},"What reviewers will see",-1)),e.detectedType==="repo"?(a(),l("button",{key:0,type:"button",class:"rp-open",onClick:t[42]||(t[42]=u=>e.previewViewer.sidebarCollapsed=!e.previewViewer.sidebarCollapsed),"aria-expanded":!e.previewViewer.sidebarCollapsed,"aria-controls":"preview-file-tree"},"Files",8,k5)):f("v-if",!0),e.previewStatus==="ready"&&e.previewRedactions()>0?(a(),l("span",{key:1,class:"rp-count",title:e.previewRedactions()+" redacted terms in this preview"},[n("span",E5,[n("i",null,c(e.previewRedactions()),1)]),t[178]||(t[178]=g(" redacted",-1))],8,C5)):e.previewStatus==="ready"&&!String(e.terms||"").trim()?(a(),l("span",S5,"No terms yet")):e.previewStatus==="ready"&&e.previewPreserved()?(a(),l("button",{key:3,type:"button",class:"rp-count rp-count-none",onClick:t[43]||(t[43]=u=>e.openPreserveFiles()),title:"Change it in Leave files unredacted"},c(e.previewName(e.previewFile?e.previewFile.slice(e.previewFile.lastIndexOf("/")+1):e.readmeName()))+" left unredacted",1)):f("v-if",!0),t[181]||(t[181]=n("span",{class:"rp-spacer"},null,-1)),e.isUpdate&&e.previewUrl()?(a(),l("a",{key:4,class:"rp-open is-external",href:e.safeUrl(e.previewPath()),target:"_blank",rel:"noopener"},[...t[179]||(t[179]=[g("Open reviewer page ",-1),n("span",{"aria-hidden":"true"},"\u2197",-1)])],8,N5)):(a(),l("button",{key:5,type:"button",class:"rp-open is-toggle",onClick:t[44]||(t[44]=u=>e.previewExpanded=!e.previewExpanded),"aria-pressed":!!e.previewExpanded},[(a(),l("svg",P5,[e.previewExpanded?(a(),l("path",A5)):(a(),l("path",D5))])),g(c(e.previewExpanded?"Back to settings":"Expand preview"),1)],8,R5))]),n("div",T5,[n("div",O5,[t[182]||(t[182]=n("i",null,null,-1)),t[183]||(t[183]=n("i",null,null,-1)),t[184]||(t[184]=n("i",null,null,-1)),n("span",I5,c(e.previewUrl()||"anonymous.4open.science"),1)]),n("div",M5,[t[185]||(t[185]=n("span",{class:"vb-logo"},[g("Anonymous "),n("em",null,"GitHub")],-1)),e.previewId()?(a(),l("span",V5,c(e.previewId()),1)):f("v-if",!0),e.detectedType!=="repo"?(a(),l("span",q5,c(e.detectedType==="pr"?"Pull request":"Gist"),1)):f("v-if",!0)]),n("div",{class:P(["rp-body",{"reviewer-explorer":e.detectedType==="repo"}])},[e.detectedType==="repo"?(a(),l("aside",{key:0,id:"preview-file-tree",class:P(["leftCol",{collapsed:e.previewViewer.sidebarCollapsed}]),"aria-label":"Files reviewers will see"},[n("div",_5,[t[187]||(t[187]=n("span",{class:"leftCol-eyebrow"},"Files",-1)),n("button",{type:"button",class:"leftCol-close","aria-label":"Close files",onClick:t[45]||(t[45]=u=>e.previewViewer.sidebarCollapsed=!0)},[...t[186]||(t[186]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#project-icon-close"})],-1)])])]),n("div",L5,[Ie(s,{class:"files",file:e.previewTreeFiles(),page:e.previewViewer,"selected-path":"/"+e.previewPathName(e.previewOpenPath()),onSelect:t[46]||(t[46]=u=>e.selectPreviewPath(u))},null,8,["file","page","selected-path"])])],2)):f("v-if",!0),e.detectedType==="repo"?T((a(),l("div",{key:1,class:"leftCol-backdrop",onClick:t[47]||(t[47]=u=>e.previewViewer.sidebarCollapsed=!0)},null,512)),[[Z,!e.previewViewer.sidebarCollapsed]]):f("v-if",!0),n("div",{class:P(e.detectedType==="repo"?"explorer-main":"rp-main")},[n("div",{class:P(e.detectedType==="repo"?"explorer-content":"rp-document")},[f(" Loading: skeleton inside the window "),e.previewStatus==="loading"||e.sourceLoading&&e.previewStatus!=="ready"&&e.previewStatus!=="error"?(a(),l("div",$5,[n("span",F5,c(e.previewDoc.loading?"Loading "+e.previewName(e.previewFile.slice(e.previewFile.lastIndexOf("/")+1))+" from GitHub\u2026":e.previewStatus==="loading"?"Updating the anonymized preview\u2026":e.detectedType==="pr"?"Loading the pull request from GitHub\u2026":e.detectedType==="gist"?"Loading the gist from GitHub\u2026":"Loading the repository from GitHub\u2026"),1),t[188]||(t[188]=Ce('',7))])):!e.details&&e.detectedType!=="repo"?(a(),l(q,{key:1},[f(" The source itself could not be loaded "),n("div",U5,[n("strong",null,"Couldn't load "+c(e.sourceSummary()||(e.detectedType==="pr"?"this pull request":"this gist")),1),n("p",null,c(e.error||"GitHub did not return it. Check that the link is right and that Anonymous GitHub can read it."),1),n("div",B5,[n("button",{type:"button",class:"btn btn-ink btn-sm",onClick:t[48]||(t[48]=u=>e.urlSelected(!0))},"Retry"),e.detectedType==="pr"&&e.githubConnection!=="oauth"?(a(),l("button",{key:0,type:"button",class:"btn btn-outline-ink btn-sm",onClick:t[49]||(t[49]=u=>e.grantGitHubAccess())},[...t[189]||(t[189]=[g("Manage GitHub access ",-1),n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-external-link"})],-1)])])):(a(),l("a",z5,[...t[190]||(t[190]=[g("Manage GitHub access ",-1),n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-external-link"})],-1)])]))])])],2112)):!e.details&&e.detectedType==="repo"&&!e.isUpdate&&e.error?(a(),l("div",H5,[t[192]||(t[192]=n("strong",null,"Couldn't load this repository",-1)),n("p",null,c(e.error),1),n("div",j5,[n("button",{type:"button",class:"btn btn-ink btn-sm",onClick:t[50]||(t[50]=u=>e.urlSelected(!0))},"Retry"),e.githubConnection!=="oauth"?(a(),l("button",{key:0,type:"button",class:"btn btn-outline-ink btn-sm",onClick:t[51]||(t[51]=u=>e.grantGitHubAccess())},[...t[191]||(t[191]=[g("Manage GitHub access ",-1),n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-external-link"})],-1)])])):f("v-if",!0)])])):e.previewStatus==="error"&&e.previewDoc.loadError?(a(),l(q,{key:3},[f(" The open file could not be read from GitHub "),n("div",G5,[n("strong",null,"Couldn't load "+c(e.previewName(e.previewFile.slice(e.previewFile.lastIndexOf("/")+1))),1),n("p",null,c(e.previewDoc.loadError),1),n("div",W5,[n("button",{class:"btn btn-ink btn-sm",type:"button",onClick:t[52]||(t[52]=u=>e.retryPreview())},"Retry"),n("button",{class:"btn btn-outline-ink btn-sm",type:"button",onClick:t[53]||(t[53]=u=>e.openPreviewFile(""))},"Back to the README")])])],2112)):e.previewStatus==="error"?(a(),l(q,{key:4},[f(" The anonymized preview failed "),n("div",K5,[t[193]||(t[193]=n("strong",null,"Couldn't apply the redactions",-1)),t[194]||(t[194]=n("p",null,"Unable to generate the anonymized preview. The latest redactions have not been verified.",-1)),n("div",Y5,[n("button",{class:"btn btn-ink btn-sm",type:"button",onClick:t[54]||(t[54]=u=>e.retryPreview())},"Retry preview")])])],2112)):e.detectedType==="repo"&&!e.previewFile&&!e.readme&&e.previewStatus==="idle"?(a(),l("div",X5,[...t[195]||(t[195]=[n("strong",null,"No README",-1),n("p",null,"Reviewers land on the file list. Open the files you will share and check them before sending the link.",-1)])])):e.detectedType==="repo"&&e.previewStatus==="ready"?(a(),Gt(i,{key:6,name:"partials/pageView.htm",state:e.previewViewer},null,8,["state"])):e.detectedType==="gist"&&e.previewStatus==="ready"?(a(),l("div",J5,[n("div",Q5,[n("h2",Z5,[e.options?.title?(a(),l("span",x5,c(e.anonymizeGistContent(e.details?.gist?.description)||"Untitled gist"),1)):f("v-if",!0),n("span",{class:P(["badge",{"badge-success":e.details?.gist?.isPublic,"badge-secondary":!e.details?.gist?.isPublic}])},c(e.details?.gist?.isPublic?"public":"secret"),3)]),e.options?.date?(a(),l("small",{key:0,textContent:c(e.fmt?.date(e.details?.gist?.updatedDate))},null,8,e8)):f("v-if",!0)]),e.options?.origin?(a(),l("small",t8,"Gist ID: "+c(e.details?.source?.gistId),1)):f("v-if",!0),e.options?.username&&e.details?.gist?.ownerLogin?(a(),l("small",n8,"By @"+c(e.anonymizeGistContent(e.details?.gist?.ownerLogin)),1)):f("v-if",!0),e.options?.content&&e.previewGistFiles?.length?(a(),l("div",s8,[n("ul",o8,[(a(!0),l(q,null,Q(e.previewGistFiles,(u,y)=>(a(),l("li",i8,[n("div",r8,[n("strong",{textContent:c(u?.filename)},null,8,a8),u?.language?(a(),l("span",l8,c(u?.language),1)):f("v-if",!0)]),Ie(o,{file:u,terms:e.terms,options:e.options},null,8,["file","terms","options"])]))),256))])])):f("v-if",!0),e.options?.comments&&e.details?.gist?.comments&&e.details?.gist?.comments?.length?(a(),l("div",d8,[t[198]||(t[198]=n("h3",{class:"paper-section-eyebrow mt-3"},"Comments",-1)),n("ul",u8,[(a(!0),l(q,null,Q(e.details?.gist?.comments,(u,y)=>(a(),l("li",c8,[n("div",p8,[e.options?.username?(a(),l("span",f8,[t[196]||(t[196]=n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-user"})],-1)),t[197]||(t[197]=g(" @",-1)),n("span",{textContent:c(e.anonymizeGistContent(u?.author))},null,8,m8)])):f("v-if",!0),e.options?.date?(a(),l("span",{key:1,class:"pr-comment-date",textContent:c(e.fmt?.date(u?.updatedDate))},null,8,h8)):f("v-if",!0)]),e.options?.body?(a(),l("div",g8,[Ie(r,{content:e.anonymizeGistContent(u?.body),options:e.options,terms:e.terms},null,8,["content","options","terms"])])):f("v-if",!0)]))),256))])])):f("v-if",!0)])):e.detectedType==="pr"&&e.previewStatus==="ready"?(a(),l("div",v8,[n("div",y8,[n("h2",b8,[e.options?.title?(a(),l("span",w8,c(e.anonymizePrContent(e.details?.pullRequest?.title)),1)):f("v-if",!0),n("span",{class:P(["badge",{"badge-success":e.details?.pullRequest?.merged,"badge-warning":e.details?.pullRequest?.state=="open","badge-danger":e.details?.pullRequest?.state=="closed"&&!e.details?.pullRequest?.merged}])},c(e.fmt?.title(e.details?.pullRequest?.merged?"merged":e.details?.pullRequest?.state)),3)]),e.options?.date?(a(),l("small",{key:0,textContent:c(e.fmt?.date(e.details?.pullRequest?.updatedDate))},null,8,k8)):f("v-if",!0)]),e.options?.origin?(a(),l("small",C8,"Pull Request on "+c(e.details?.pullRequest?.baseRepositoryFullName),1)):f("v-if",!0),e.options?.body?(a(),l("div",E8,[Ie(r,{content:e.anonymizePrContent(e.details?.pullRequest?.body),options:e.options,terms:e.terms},null,8,["content","options","terms"])])):f("v-if",!0),e.options?.diff||e.options?.comments?(a(),l("nav",S8,[e.options?.diff?(a(),l("button",{key:0,class:P(["paper-tab",{active:e.prTabState?.active=="diff"}]),type:"button",role:"tab",id:"preview-pr-diff-tab","aria-selected":e.prTabState?.active==="diff","aria-controls":"preview-pr-diff-panel",tabindex:e.prTabState?.active==="diff"?0:-1,onKeydown:t[55]||(t[55]=u=>e.previewTabKeydown(u)),onClick:t[56]||(t[56]=u=>e.prTabState.active="diff")},[...t[199]||(t[199]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-code"})],-1),g(" Diff ",-1)])],42,N8)):f("v-if",!0),e.options?.comments?(a(),l("button",{key:1,class:P(["paper-tab",{active:e.prTabState?.active=="comments"}]),type:"button",role:"tab",id:"preview-pr-comments-tab","aria-selected":e.prTabState?.active==="comments","aria-controls":"preview-pr-comments-panel",tabindex:e.prTabState?.active==="comments"?0:-1,onKeydown:t[57]||(t[57]=u=>e.previewTabKeydown(u)),onClick:t[58]||(t[58]=u=>e.prTabState.active="comments")},[t[200]||(t[200]=n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-comment"})],-1)),n("span",{textContent:c(e.fmt.plural(e.details?.pullRequest?.comments?.length,{0:"No comments",one:"1 comment",other:"{} comments"}))},null,8,P8)],42,R8)):f("v-if",!0)])):f("v-if",!0),!e.options?.diff&&!e.options?.comments?(a(),l("div",D8,"Diff and comments are hidden by your display settings.")):f("v-if",!0),n("div",A8,[e.options?.diff&&e.prTabState?.active=="diff"?(a(),l("div",T8,[n("div",{class:"pr-diff",innerHTML:e.sanitize(e.fmt?.diff(e.anonymizePrContent(e.details?.pullRequest?.diff)))},null,8,O8)])):f("v-if",!0),e.options?.comments&&e.prTabState?.active=="comments"?(a(),l("div",I8,[n("ul",M8,[(a(!0),l(q,null,Q(e.details?.pullRequest?.comments,(u,y)=>(a(),l("li",V8,[n("div",q8,[e.options?.username?(a(),l("span",_8,[t[201]||(t[201]=n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-user"})],-1)),t[202]||(t[202]=g(" @",-1)),n("span",{textContent:c(e.anonymizePrContent(u?.author))},null,8,L8)])):f("v-if",!0),e.options?.date?(a(),l("span",{key:1,class:"pr-comment-date",textContent:c(e.fmt?.date(u?.updatedDate))},null,8,$8)):f("v-if",!0)]),e.options?.body?(a(),l("div",F8,[Ie(r,{content:e.anonymizePrContent(u?.body),options:e.options,terms:e.terms},null,8,["content","options","terms"])])):f("v-if",!0)]))),256))])])):f("v-if",!0)])])):f("v-if",!0),f(" More below: a fade with a way to keep reading (hidden by CSS once the window is scrolled to the end) "),e.previewStatus==="ready"&&!(e.detectedType==="repo"&&e.previewFile&&e.previewDoc.note)?(a(),l("div",U8,[e.isUpdate&&e.previewUrl()?(a(),l("a",{key:0,class:"rp-more-btn",href:e.safeUrl(e.previewPath()),target:"_blank",rel:"noopener"},[...t[203]||(t[203]=[g("Continue reading on the reviewer page ",-1),n("span",{"aria-hidden":"true"},"\u2197",-1)])],8,B8)):e.previewExpanded?(a(),l("span",z8,"Scroll for more")):(a(),l("button",{key:1,type:"button",class:"rp-more-btn",onClick:t[59]||(t[59]=u=>e.previewExpanded=!0)},"Continue reading in the expanded preview"))])):f("v-if",!0)],2)],2)],2)])],8,b5)):f("v-if",!0)])],512),[[Z,e.workspaceOpen||e.isUpdate]])],2)}var H8={class:"container-fluid h-100 anonymize-page"},j8={class:"row h-100 flex-column flex-md-row"},G8={class:"col-md sidePanel shadow overflow-auto anonymize-form-col"},W8={class:"form-group"},K8={class:"form-group"},Y8={class:"form-check"},X8={class:"form-check-input",type:"checkbox",id:"update",name:"update"},J8={class:"form-group"},Q8={class:"form-text text-muted"},Z8=["href"],x8={class:"invalid-feedback"},eM={class:"form-text text-muted"},tM={class:"form-group"},nM={id:"idHelp",class:"form-text text-muted"},sM={class:"invalid-feedback"},oM={class:"form-group"},iM={class:"invalid-feedback"},rM={class:"form-group"},aM={class:"form-control",id:"expiration",name:"expiration"},lM={class:"form-group",id:"expiration-date-form"},dM={class:"form-control",type:"date",name:"expirationDate",id:"expirationDate"},uM={key:0,class:"date-echo","aria-live":"polite"},cM={class:"accordion mb-3",id:"options"},pM={class:"card"},fM={id:"collapseOne",class:"collapse show","aria-labelledby":"headingOne","data-parent":"#options"},mM={class:"card-body"},hM={class:"form-group mb-0"},gM={class:"form-check"},vM={class:"form-check-input",type:"checkbox",id:"link",name:"link"},yM={class:"form-check"},bM={class:"form-check-input",type:"checkbox",id:"image",name:"image"},wM={class:"form-check"},kM={class:"form-check-input",type:"checkbox",id:"date",name:"date"},CM={class:"form-check"},EM={class:"form-check-input",type:"checkbox",id:"username",name:"username"},SM={class:"form-check"},NM={class:"form-check-input",type:"checkbox",id:"comments",name:"comments"},RM={class:"form-check"},PM={class:"form-check-input",type:"checkbox",id:"diff",name:"diff"},DM={class:"form-check"},AM={class:"form-check-input",type:"checkbox",id:"origin",name:"origin"},TM={class:"form-check"},OM={class:"form-check-input",type:"checkbox",id:"title",name:"title"},IM={class:"form-check"},MM={class:"form-check-input",type:"checkbox",id:"body",name:"body"},VM=["textContent"],qM={class:"anonymize-submit-bar"},_M={key:0,class:"col-md-8 p-2 overflow-auto anonymize-preview-col"},LM={class:"d-flex w-100 justify-content-between align-items-center flex-wrap"},$M={class:"pr-title mb-1"},FM={key:0},UM=["textContent"],BM={key:0},zM={key:1,class:"pr-body shadow-sm p-3 mb-4 rounded",style:{background:"var(--sidebar-bg-color)"}},HM={class:"nav nav-tabs",id:"myTab",role:"tablist"},jM={key:0,class:"nav-item",role:"presentation"},GM={key:1,class:"nav-item",role:"presentation"},WM=["textContent"],KM={class:"tab-content",id:"pills-tabContent"},YM={class:"tab-pane show active",id:"pills-diff",role:"tabpanel","aria-labelledby":"pills-diff-tab"},XM={key:0,class:"pr-diff shadow-sm p-3 mb-4 rounded",style:{background:"var(--sidebar-bg-color)"}},JM={style:{"overflow-x":"auto"}},QM=["innerHTML"],ZM={key:0,class:"pr-comments list-group"},xM={class:"pr-comment list-group-item"},e6={class:"d-flex w-100 justify-content-between flex-wrap"},t6={key:0,class:"mb-1"},n6=["textContent"],s6={class:"mb-1"};function lp(e,t){let s=Xe("markdown"),i=De("field"),o=De("form");return a(),l("div",H8,[n("div",j8,[n("div",G8,[n("div",{class:P(["p-0 py-2 m-auto",{card:!e.pullRequestUrl,container:e.pullRequestUrl}])},[T((a(),l("form",{class:P(["form needs-validation",{"card-body":!e.pullRequestUrl}]),name:"anonymizeForm",novalidate:""},[t[30]||(t[30]=Ce('
Anonymize \xA0/\xA0 Pull request

Anonymize a pull request

Fill in the details \u2014 it only takes a minute.

Source
',4)),f(" pullRequestUrl "),n("div",W8,[t[2]||(t[2]=n("label",{for:"pullRequestUrl"},"URL of your pull request",-1)),T(n("input",{type:"text",class:P(["form-control",{"is-invalid":e.anonymize?.pullRequestUrl?.invalid}]),name:"pullRequestUrl",id:"pullRequestUrl",placeholder:"https://github.com/owner/repo/pull/123"},null,2),[[i,{state:e.viewState,set:r=>{e.pullRequestUrl=r},value:e.pullRequestUrl,form:"anonymizeForm",options:{debounce:{default:1e3,blur:0,click:0},updateOn:"default blur click"},change:()=>{e.pullRequestSelected()}}]]),T(n("div",{class:"invalid-feedback"},c(e.pullRequestUrl)+" is not accessible. Some organizations are restricting the access to the repositories. ",513),[[Z,e.anonymize?.pullRequestUrl?.errors?.access]]),T(n("div",{class:"invalid-feedback"},c(e.pullRequestUrl)+" does not exist or is not accessible ",513),[[Z,e.anonymize?.pullRequestUrl?.errors?.missing]]),T(n("div",{class:"invalid-feedback"},c(e.pullRequestUrl)+" is already anonymized ",513),[[Z,e.anonymize?.pullRequestUrl?.errors?.used]])]),T(n("div",null,[n("div",K8,[n("div",Y8,[T(n("input",X8,null,512),[[i,{state:e.viewState,set:r=>{e.options.update=r},value:e.options?.update,form:"anonymizeForm",options:{}}]]),t[3]||(t[3]=n("label",{class:"form-check-label",for:"update"},"Auto update",-1)),t[4]||(t[4]=n("small",{id:"updateHelp",class:"form-text text-muted"},"Automatically update the anonymized pull request with the latest updates. The pull request is updated once per day maximum.",-1))])]),t[26]||(t[26]=n("div",{class:"paper-section-eyebrow anonymize-section-title"},[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#project-icon-conference"})]),g(" Conference ID ")],-1)),f(" Conference "),n("div",J8,[t[5]||(t[5]=n("label",{for:"conference"},[g("Conference ID "),n("span",{class:"text-muted"},"(Optional)")],-1)),T(n("input",{class:P(["form-control",{"is-invalid":e.anonymize?.conference?.invalid}]),id:"conference",name:"conference"},null,2),[[i,{state:e.viewState,set:r=>{e.conference=r},value:e.conference,form:"anonymizeForm",options:{debounce:{default:800,blur:0},updateOn:"default blur"}}]]),T(n("small",Q8,[n("a",{target:"_target",href:e.safeUrl(e.conference_data?.url)},c(e.conference_data?.name),9,Z8),g(" will expire on "+c(e.fmt?.date(e.conference_data?.endDate))+".",1)],512),[[Z,e.conference_data]]),T(n("div",x8," The conference is not activated. ",512),[[Z,e.anonymize?.conference?.errors?.activated]]),T(n("small",eM," Use the Conference ID that your conference provided you. This will update automatically the anonymization options based on the conference preferences. ",512),[[Z,!e.conference_data]])]),t[27]||(t[27]=n("div",{class:"paper-section-eyebrow anonymize-section-title"},[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-shield"})]),g(" Anonymization Options ")],-1)),f(" Pull Request ID "),n("div",tM,[t[6]||(t[6]=n("label",{for:"pullRequestId"},"Anonymized pull request id",-1)),T(n("input",{type:"text",class:P(["form-control",{"is-invalid":e.anonymize?.pullRequestId?.invalid}]),name:"pullRequestId",id:"pullRequestId"},null,2),[[i,{state:e.viewState,set:r=>{e.pullRequestId=r},value:e.pullRequestId,form:"anonymizeForm",options:{debounce:{default:1e3,blur:0,click:0},updateOn:"default blur click"}}]]),n("small",nM,"Id used in the url: https://anonymous.4open.science/r/"+c(e.pullRequestId),1),T(n("div",sM," Repository id can only contain letters and numbers ",512),[[Z,e.anonymize?.pullRequestId?.errors?.format]]),T(n("div",{class:"invalid-feedback"},c(e.pullRequestId)+" is already used ",513),[[Z,e.anonymize?.pullRequestId?.errors?.used]])]),f(" Terms "),n("div",oM,[t[7]||(t[7]=n("label",{for:"terms"},"Terms to anonymize",-1)),T(n("textarea",{class:P(["form-control",{"is-invalid":e.anonymize?.terms?.invalid}]),id:"terms",name:"terms",rows:"3"},null,2),[[i,{state:e.viewState,set:r=>{e.terms=r},value:e.terms,form:"anonymizeForm",options:{debounce:250}}]]),t[8]||(t[8]=n("small",{id:"termsHelp",class:"form-text text-muted"},"One term per line. Each term will be replaced by XXX.",-1)),T(n("div",iM," Terms are in an invalid format ",512),[[Z,e.anonymize?.terms?.errors?.format]])]),n("div",rM,[t[10]||(t[10]=n("label",{for:"expiration"},"Expiration strategy",-1)),T((a(),l("select",aM,[...t[9]||(t[9]=[n("option",{value:"never",selected:""},"Never expire",-1),n("option",{value:"redirect"}," Redirect to GitHub when expired ",-1),n("option",{value:"remove"},"Remove when expired",-1)])])),[[i,{state:e.viewState,set:r=>{e.options.expirationMode=r},value:e.options?.expirationMode,form:"anonymizeForm",options:{}}]]),t[11]||(t[11]=n("small",{class:"form-text text-muted"},"Define the expiration strategy for the anonymized repository.",-1))]),T(n("div",lM,[t[12]||(t[12]=n("label",{for:"expirationDate"},"Expiration date of the anonymized repository",-1)),T(n("input",dM,null,512),[[i,{state:e.viewState,set:r=>{e.options.expirationDate=r},value:e.options?.expirationDate,form:"anonymizeForm",options:{}}]]),e.fmt?.dateEcho(e.options?.expirationDate)?(a(),l("p",uM,"Expires "+c(e.fmt?.dateEcho(e.options?.expirationDate)),1)):f("v-if",!0),T(n("small",{class:"form-text text-muted"},"After "+c(e.fmt?.date(e.options?.expirationDate))+", the repository will be removed and the visitor will not be able to see the content of the repository.",513),[[Z,e.options?.expirationMode=="remove"]]),T(n("small",{class:"form-text text-muted"},"After "+c(e.fmt?.date(e.options?.expirationDate))+", the visitors of the anonymized repository will be redirected to "+c(e.pullRequestUrl)+".",513),[[Z,e.options?.expirationMode=="redirect"]])],512),[[Z,e.options?.expirationMode!="never"]]),n("div",cM,[n("div",pM,[t[25]||(t[25]=Ce('

',1)),n("div",fM,[n("div",mM,[n("div",hM,[n("div",gM,[T(n("input",vM,null,512),[[i,{state:e.viewState,set:r=>{e.options.link=r},value:e.options?.link,form:"anonymizeForm",options:{}}]]),t[13]||(t[13]=n("label",{class:"form-check-label",for:"link"},"Keep links",-1)),t[14]||(t[14]=n("small",{class:"form-text text-muted"},"Keep or remove all the links.",-1))]),n("div",yM,[T(n("input",bM,null,512),[[i,{state:e.viewState,set:r=>{e.options.image=r},value:e.options?.image,form:"anonymizeForm",options:{}}]]),t[15]||(t[15]=n("label",{class:"form-check-label",for:"image"},"Display images",-1)),t[16]||(t[16]=n("small",{class:"form-text text-muted"},"Images are not anonymized",-1))]),n("div",wM,[T(n("input",kM,null,512),[[i,{state:e.viewState,set:r=>{e.options.date=r},value:e.options?.date,form:"anonymizeForm",options:{}}]]),t[17]||(t[17]=n("label",{class:"form-check-label",for:"date"},"Display dates",-1)),t[18]||(t[18]=n("small",{class:"form-text text-muted"},"Display the date of the Pull Request and the date of the comments.",-1))]),n("div",CM,[T(n("input",EM,null,512),[[i,{state:e.viewState,set:r=>{e.options.username=r},value:e.options?.username,form:"anonymizeForm",options:{}}]]),t[19]||(t[19]=n("label",{class:"form-check-label",for:"username"},"Display username",-1))]),n("div",SM,[T(n("input",NM,null,512),[[i,{state:e.viewState,set:r=>{e.options.comments=r},value:e.options?.comments,form:"anonymizeForm",options:{}}]]),t[20]||(t[20]=n("label",{class:"form-check-label",for:"comments"},"Display comments",-1))]),n("div",RM,[T(n("input",PM,null,512),[[i,{state:e.viewState,set:r=>{e.options.diff=r},value:e.options?.diff,form:"anonymizeForm",options:{}}]]),t[21]||(t[21]=n("label",{class:"form-check-label",for:"diff"},"Display diff",-1))]),n("div",DM,[T(n("input",AM,null,512),[[i,{state:e.viewState,set:r=>{e.options.origin=r},value:e.options?.origin,form:"anonymizeForm",options:{}}]]),t[22]||(t[22]=n("label",{class:"form-check-label",for:"origin"},"Display the project name",-1))]),n("div",TM,[T(n("input",OM,null,512),[[i,{state:e.viewState,set:r=>{e.options.title=r},value:e.options?.title,form:"anonymizeForm",options:{}}]]),t[23]||(t[23]=n("label",{class:"form-check-label",for:"title"},"Display the PR title",-1))]),n("div",IM,[T(n("input",MM,null,512),[[i,{state:e.viewState,set:r=>{e.options.body=r},value:e.options?.body,form:"anonymizeForm",options:{}}]]),t[24]||(t[24]=n("label",{class:"form-check-label",for:"body"},"Display the PR body and comment bodies",-1))])])])])])])],512),[[Z,e.pullRequestUrl]]),e.error?(a(),l("div",{key:0,class:"alert alert-danger",role:"alert",textContent:c(e.error)},null,8,VM)):f("v-if",!0),T(n("div",qM,[e.isUpdate?f("v-if",!0):(a(),l("button",{key:0,id:"submit",type:"submit",class:"btn btn-ink btn-block",onClick:t[0]||(t[0]=ae(r=>e.submitForm(r,()=>{e.anonymizePullRequest(r)}),["prevent"]))},[...t[28]||(t[28]=[n("svg",{class:"ui-icon mr-1","aria-hidden":"true"},[n("use",{href:"#ui-icon-shield"})],-1),g(" Anonymize ",-1)])])),e.isUpdate?(a(),l("button",{key:1,id:"submit",type:"submit",class:"btn btn-ink btn-block",onClick:t[1]||(t[1]=ae(r=>e.submitForm(r,()=>{e.updatePullRequest(r)}),["prevent"]))},[...t[29]||(t[29]=[n("svg",{class:"ui-icon mr-1","aria-hidden":"true"},[n("use",{href:"#ui-icon-save"})],-1),g(" Update ",-1)])])):f("v-if",!0)],512),[[Z,e.pullRequestUrl]])],2)),[[o,e.viewState]])],2)]),e.details?(a(),l("div",_M,[n("div",LM,[n("h2",$M,[e.options?.title?(a(),l("span",FM,c(e.anonymize(e.details?.pullRequest?.title)),1)):f("v-if",!0),n("span",{class:P(["badge",{"badge-success":e.details?.pullRequest?.merged,"badge-warning":e.details?.pullRequest?.state=="open","badge-danger":e.details?.pullRequest?.state=="closed"&&!e.details?.pullRequest?.merged}])},c(e.fmt?.title(e.details?.pullRequest?.merged?"merged":e.details?.pullRequest?.state)),3)]),e.options?.date?(a(),l("small",{key:0,textContent:c(e.fmt?.date(e.details?.pullRequest?.updatedDate))},null,8,UM)):f("v-if",!0)]),e.options?.origin?(a(),l("small",BM,"Pull Request on "+c(e.details?.pullRequest?.baseRepositoryFullName),1)):f("v-if",!0),e.options?.body?(a(),l("div",zM,[Ie(s,{content:e.anonymize(e.details?.pullRequest?.body),options:e.options,terms:e.terms},null,8,["content","options","terms"])])):f("v-if",!0),n("ul",HM,[e.options?.diff?(a(),l("li",jM,[...t[31]||(t[31]=[n("button",{class:"nav-link active",id:"pills-diff-tab","data-toggle":"pill","data-target":"#pills-diff",type:"button",role:"tab","aria-controls":"pills-diff","aria-selected":"true"}," Diff ",-1)])])):f("v-if",!0),e.options?.comments?(a(),l("li",GM,[n("button",{class:P(["nav-link",{active:!e.options?.diff}]),id:"pills-comments-tab","data-toggle":"pill","data-target":"#pills-comments",type:"button",role:"tab","aria-controls":"pills-comments","aria-selected":"false"},[n("span",{textContent:c(e.fmt.plural(e.details?.pullRequest?.comments?.length,{0:"No comment",one:"One Comment",other:"{} Comments"}))},null,8,WM)],2)])):f("v-if",!0)]),n("div",KM,[n("div",YM,[e.options?.diff?(a(),l("div",XM,[n("pre",JM,[n("code",{innerHTML:e.sanitize(e.fmt?.diff(e.anonymize(e.details?.pullRequest?.diff)))},null,8,QM)])])):f("v-if",!0)]),n("div",{class:P(["tab-pane",{"show active":!e.options?.diff}]),id:"pills-comments",role:"tabpanel","aria-labelledby":"pills-comments-tab"},[e.options?.comments?(a(),l("ul",ZM,[(a(!0),l(q,null,Q(e.details?.pullRequest?.comments,(r,d)=>(a(),l("li",xM,[n("div",e6,[e.options?.username?(a(),l("h5",t6," @"+c(e.anonymize(r?.author)),1)):f("v-if",!0),e.options?.date?(a(),l("small",{key:1,textContent:c(e.fmt?.date(r?.updatedDate))},null,8,n6)):f("v-if",!0)]),n("p",s6,[e.options?.body?(a(),Gt(s,{key:0,class:"pr-comment-body",content:e.anonymize(r?.body),options:e.options,terms:e.terms},null,8,["content","options","terms"])):f("v-if",!0)])]))),256))])):f("v-if",!0)],2)])])):f("v-if",!0)])])}var o6={class:"container paper-page claim-page"},i6={class:"paper-settings-main claim-form"},r6={class:"form-group"},a6={class:"invalid-feedback"},l6={class:"form-group"};function dp(e,t){let s=De("field"),i=De("form");return a(),l("div",o6,[t[6]||(t[6]=Ce('
My work \xA0/\xA0 Claim

Claim an anonymization

Take ownership of an existing anonymized repository so it appears on your dashboard.

',3)),n("div",i6,[t[5]||(t[5]=n("p",{class:"paper-section-copy"},"Use this when an anonymization was created by a co-author or from another account. You must have access to the GitHub repository it was made from.",-1)),T((a(),l("form",{class:"form needs-validation",name:"claimForm",novalidate:"",onSubmit:t[0]||(t[0]=ae(o=>e.submitForm(o,()=>{e.claim()}),["prevent"]))},[n("div",r6,[t[1]||(t[1]=n("label",{class:"paper-field-label",for:"repoUrl"},"GitHub repository URL",-1)),T(n("input",{type:"text",class:P(["form-control",{"is-invalid":e.claimForm?.repoUrl?.invalid&&(e.claimForm?.repoUrl?.touched||e.claimForm?.submitted)}]),name:"repoUrl",id:"repoUrl",placeholder:"https://github.com/owner/repository",required:""},null,2),[[s,{state:e.viewState,set:o=>{e.repoUrl=o},value:e.repoUrl,form:"claimForm",options:{}}]]),T(n("div",a6," No anonymization matches this repository and ID. Check both values and that you can access the repository on GitHub. ",512),[[Z,e.claimForm?.repoUrl?.errors?.not_found]])]),n("div",l6,[t[2]||(t[2]=n("label",{class:"paper-field-label",for:"repoId"},"Anonymized repository ID",-1)),T(n("input",{type:"text",class:P(["form-control",{"is-invalid":e.claimForm?.repoId?.invalid&&(e.claimForm?.repoId?.touched||e.claimForm?.submitted)}]),name:"repoId",id:"repoId",placeholder:"e.g. my-paper-7F2A","aria-describedby":"idHelp",required:""},null,2),[[s,{state:e.viewState,set:o=>{e.repoId=o},value:e.repoId,form:"claimForm",options:{}}]]),t[3]||(t[3]=n("small",{id:"idHelp",class:"form-text text-muted"},[g("The ID is the last part of the anonymized URL: "),n("code",null,"anonymous.4open.science/r/"),g(".")],-1))]),t[4]||(t[4]=n("button",{id:"submit",type:"submit",class:"btn btn-ink"}," Claim anonymization ",-1))],32)),[[i,e.viewState]])])])}var d6={class:"container page paper-page conference-page"},u6={class:"paper-crumbs"},c6={class:"here"},p6={class:"d-flex align-items-end flex-wrap",style:{gap:"12px","justify-content":"space-between"}},f6={class:"conf-title-row"},m6=["textContent"],h6={key:0,class:"conf-status"},g6=["textContent"],v6={key:0,class:"paper-page-lede"},y6=["textContent","href"],b6={class:"d-flex align-items-center flex-wrap",style:{gap:"10px"}},w6=["href"],k6={class:"paper-meta-rule"},C6=["textContent"],E6=["textContent"],S6={key:0},N6={key:0,class:"conference-payment-status",role:"status"},R6=["disabled"],P6={key:1,role:"alert"},D6={key:2,class:"paper-settings-section","aria-labelledby":"conference-payment-heading"},A6={key:0,role:"status"},T6={key:1,role:"alert"},O6=["onClick","disabled"],I6={class:"dashboard-meta conf-view-meta"},M6={class:"dashboard-view-tabs",role:"group","aria-label":"Repository view"},V6=["aria-pressed"],q6=["aria-pressed","aria-label"],_6=["aria-pressed"],L6={class:"attention-count"},$6={class:"dashboard-count",role:"status"},F6={class:"search-wrap"},U6={type:"search",id:"search",class:"form-control","aria-label":"Search repositories",placeholder:"Search repositories\u2026",autocomplete:"off"},B6={class:"dashboard-filter-controls"},z6={class:"dropdown"},H6={class:"btn dropdown-toggle",type:"button",id:"dropdownSort","data-toggle":"dropdown","aria-haspopup":"true","aria-expanded":"false"},j6={class:"filter-btn-value"},G6={class:"dropdown-menu","aria-labelledby":"dropdownSort"},W6={class:"form-check dropdown-item"},K6={class:"form-check-input",type:"radio",name:"sort",id:"anonymizeDate",value:"-anonymizeDate"},Y6={class:"form-check dropdown-item"},X6={class:"form-check-input",type:"radio",name:"sort",id:"sortID",value:"repoId"},J6={class:"form-check dropdown-item"},Q6={class:"form-check-input",type:"radio",name:"sort",id:"sortStatus",value:"-status"},Z6={class:"form-check dropdown-item"},x6={class:"form-check-input",type:"radio",name:"sort",id:"sortViews",value:"-pageView"},eV={class:"dashboard-page conf-rows"},tV={class:"cell-anon",role:"cell"},nV={class:"anon-text"},sV={class:"anon-title"},oV=["title","href"],iV={class:"rn-owner"},rV={class:"rn-repo"},aV={class:"anon-sub"},lV=["title"],dV={class:"id-head"},uV={class:"id-tail"},cV=["title"],pV={class:"dashboard-row-meta",role:"presentation"},fV={class:"cell-status",role:"cell"},mV={class:"status-line"},hV=["textContent"],gV=["textContent","title"],vV=["href"],yV=["onClick","disabled"],bV={key:3,class:"status-sub status-sub-date"},wV=["data-unit","aria-label"],kV={class:"cell-expires",role:"cell"},CV={key:0,class:"expires-never"},EV=["textContent"],SV={key:2,class:"expires-past"},NV={key:3,class:"empty-dash","aria-label":"Not applicable"},RV={class:"cell-actions",role:"cell"},PV=["onClick","disabled","title","aria-label"],DV={class:"sr-only","aria-live":"polite"},AV={class:"project-type-svg","aria-hidden":"true"},TV=["href"],OV={class:"copy-url-label","aria-hidden":"true"},IV=["href","aria-label"],MV={class:"dropdown"},VV=["aria-label"],qV={class:"dropdown-menu dropdown-menu-right"},_V=["href"],LV=["href"],$V=["href"],FV={key:0,class:"paper-table-empty"},UV={key:0},BV={key:1},zV={key:2,class:"paper-table-empty-actions"};function up(e,t){let s=De("field"),i=De("form");return a(),l("div",d6,[n("div",null,[n("div",u6,[t[6]||(t[6]=n("a",{href:"/dashboard"},"My work",-1)),t[7]||(t[7]=g(" \xA0/\xA0 ",-1)),t[8]||(t[8]=n("a",{href:"/conferences"},"Conferences",-1)),t[9]||(t[9]=g(" \xA0/\xA0 ",-1)),n("span",c6,c(e.conference?.conferenceID),1)]),n("div",p6,[n("div",null,[n("div",f6,[n("h1",{class:"paper-page-title",textContent:c(e.conference?.name)},null,8,m6),e.conference?.status?(a(),l("span",h6,[n("span",{class:P(["status-dot","status-"+e.conference?.status]),"aria-hidden":"true"},null,2),n("span",{textContent:c(e.fmt?.statusLabel(e.conference?.status))},null,8,g6)])):f("v-if",!0)]),e.conference?.url?(a(),l("p",v6,[n("a",{target:"_blank",rel:"noopener",textContent:c(e.conference?.url),href:e.safeUrl(e.conference?.url)},null,8,y6)])):f("v-if",!0)]),n("div",b6,[n("a",{class:"btn btn-outline-ink",href:e.safeUrl("/conference/"+e.conference?.conferenceID+"/edit")},[...t[10]||(t[10]=[n("svg",{class:"ui-icon mr-1","aria-hidden":"true"},[n("use",{href:"#ui-icon-edit"})],-1),g(" Edit conference",-1)])],8,w6)])]),n("div",k6,[n("span",null,[t[11]||(t[11]=g("ID ",-1)),n("b",{class:"commit-hash",textContent:c(e.conference?.conferenceID)},null,8,C6)]),n("span",null,[t[12]||(t[12]=g("Review window ",-1)),n("b",null,c(e.fmt?.date(e.conference?.startDate,"mediumDate"))+" \u2013 "+c(e.fmt?.date(e.conference?.endDate,"mediumDate")),1)]),n("span",null,[t[13]||(t[13]=g("Repositories ",-1)),n("b",null,c(e.fmt?.number(e.conference?.repositories?.length)),1)]),n("span",null,[t[14]||(t[14]=g("Plan ",-1)),n("b",{textContent:c(e.conferencePlanName(e.conference?.plan?.planID))},null,8,E6)]),e.conference?.price?(a(),l("span",S6,[t[15]||(t[15]=g("Cost so far ",-1)),n("b",null,c(e.fmt?.money(e.conference?.price)),1)])):f("v-if",!0)]),e.billingNotice?(a(),l("div",N6,[n("p",null,c(e.billingNotice),1),n("button",{type:"button",class:"btn btn-outline-ink",onClick:t[0]||(t[0]=o=>e.refreshBilling()),disabled:e.billingBusy},"Check payment status",8,R6)])):f("v-if",!0),e.billingError&&e.conference?.status!=="pending_payment"?(a(),l("p",P6,c(e.billingError),1)):f("v-if",!0),e.conference?.status==="pending_payment"?(a(),l("section",D6,[t[16]||(t[16]=n("h2",{id:"conference-payment-heading"},"Activate your review package",-1)),t[17]||(t[17]=n("p",null,"This conference is waiting for payment. Authors can join after payment is confirmed. Checkout returns to this conference. Authors within the package do not pay separately.",-1)),e.billingLoading?(a(),l("p",A6,"Loading payment options\u2026")):f("v-if",!0),e.billingError?(a(),l("p",T6,c(e.billingError),1)):f("v-if",!0),(a(!0),l(q,null,Q((e.billing?.plans||[]).filter(o=>o.id===e.conference?.plan?.planID),o=>(a(),l("div",{key:o.id},[n("p",null,[n("strong",null,c(o.name)+" package",1),g(": "+c(e.billingPrice(o))+" for up to "+c(o.repositories)+" repositories and "+c(e.billingBytes(o.storage))+" of source files during the review window. Taxes, if applicable, appear at checkout.",1)]),n("button",{type:"button",class:"btn btn-primary",onClick:r=>e.checkout(o.id,e.conference.conferenceID),disabled:e.billingBusy||e.billingPending||e.billing?.checkoutEnabled===!1},c(e.billingBusy?"Please wait\u2026":"Pay for review package"),9,O6)]))),128)),t[18]||(t[18]=n("p",null,[n("a",{href:"/profile#settings-billing"},"Manage invoices")],-1))])):f("v-if",!0),n("div",I6,[n("div",M6,[n("button",{type:"button","aria-pressed":e.confView()==="current",onClick:t[1]||(t[1]=o=>e.setConfView("current")),title:"Every repository except removed links"},"Current",8,V6),e.confCount("attention")>0||e.confView()==="attention"?(a(),l("button",{key:0,type:"button","aria-pressed":e.confView()==="attention",onClick:t[2]||(t[2]=o=>e.setConfView("attention")),"aria-label":"Needs attention "+e.confCount("attention")},[t[19]||(t[19]=n("span",{class:"dashboard-attention-prefix"},"Needs ",-1)),t[20]||(t[20]=n("span",null,"attention",-1)),t[21]||(t[21]=g()),n("span",{class:P(["attention-count",{"has-attention":e.confCount("attention")>0}])},c(e.fmt?.number(e.confCount("attention"))),3)],8,q6)):f("v-if",!0),e.confCount("removed")>0||e.confView()==="removed"?(a(),l("button",{key:1,type:"button","aria-pressed":e.confView()==="removed",onClick:t[3]||(t[3]=o=>e.setConfView("removed")),title:"Links reviewers can no longer open"},[t[22]||(t[22]=g("Removed ",-1)),n("span",L6,c(e.fmt?.number(e.confCount("removed"))),1)],8,_6)):f("v-if",!0)]),n("span",$6,c(e.search.trim()?e.fmt?.number(e.filteredRepositories?.length||0)+" shown":e.fmt?.number(e.filteredRepositories?.length||0)+((e.filteredRepositories?.length||0)===1?" repository":" repositories")),1)]),T((a(),l("form",{class:"w-100 conf-repo-toolbar","aria-label":"Filter repositories","accept-charset":"UTF-8",onSubmit:t[4]||(t[4]=ae(o=>e.submitForm(o,()=>{o.preventDefault()}),["prevent"]))},[n("div",F6,[T(n("input",U6,null,512),[[s,{state:e.viewState,set:o=>{e.search=o},value:e.search,form:null,options:{}}]])]),n("div",B6,[n("div",z6,[n("button",H6,[t[23]||(t[23]=n("span",{class:"filter-btn-label"},"Sort",-1)),n("span",j6,c({"-anonymizeDate":"Anonymize date",repoId:"ID","-status":"Status","-pageView":"Views"}[e.orderBy]||"Custom"),1)]),n("div",G6,[t[28]||(t[28]=n("h6",{class:"dropdown-header"},"Order by",-1)),n("div",W6,[T(n("input",K6,null,512),[[s,{state:e.viewState,set:o=>{e.orderBy=o},value:e.orderBy,form:null,options:{}}]]),t[24]||(t[24]=n("label",{class:"form-check-label",for:"anonymizeDate"},"Anonymize date",-1))]),n("div",Y6,[T(n("input",X6,null,512),[[s,{state:e.viewState,set:o=>{e.orderBy=o},value:e.orderBy,form:null,options:{}}]]),t[25]||(t[25]=n("label",{class:"form-check-label",for:"sortID"},"ID",-1))]),n("div",J6,[T(n("input",Q6,null,512),[[s,{state:e.viewState,set:o=>{e.orderBy=o},value:e.orderBy,form:null,options:{}}]]),t[26]||(t[26]=n("label",{class:"form-check-label",for:"sortStatus"},"Status",-1))]),n("div",Z6,[T(n("input",x6,null,512),[[s,{state:e.viewState,set:o=>{e.orderBy=o},value:e.orderBy,form:null,options:{}}]]),t[27]||(t[27]=n("label",{class:"form-check-label",for:"sortViews"},"Views",-1))])])])])],32)),[[i,e.viewState]]),n("div",eV,[n("div",{class:P(["paper-table paper-table-dashboard paper-table-conf w-100",{"is-removed-view":e.confView()==="removed"}]),role:"table","aria-label":"Repositories"},[t[37]||(t[37]=n("div",{class:"paper-table-head",role:"row"},[n("div",{role:"columnheader"},"Repository"),n("div",{role:"columnheader"},"Status"),n("div",{role:"columnheader",class:"num"},"Views"),n("div",{role:"columnheader"},"Expires"),n("div",{role:"columnheader"},[n("span",{class:"sr-only"},"Actions")])],-1)),(a(!0),l(q,null,Q(e.filteredRepositories,(o,r)=>(a(),l("div",{class:P(["paper-table-row",{"repo-inactive":o?.status=="expired"||o?.status=="removed","repo-error":o?.status=="error"}]),role:"row",key:o?.repoId},[n("div",tV,[t[30]||(t[30]=n("span",{class:"project-type-icon",role:"img","aria-label":"Repository",title:"Repository"},[n("svg",{class:"project-type-svg","aria-hidden":"true"},[n("use",{href:"#project-type-repo"})])],-1)),n("div",nV,[n("div",sV,[n("a",{class:"repo-name",title:o?.source?.fullName,href:e.safeUrl("/r/"+o?.repoId+"/")},[(o?.source?.fullName||"").indexOf("/")>0?(a(),l(q,{key:0},[n("span",iV,c(o.source.fullName.slice(0,o.source.fullName.indexOf("/")+1)),1),t[29]||(t[29]=n("wbr",null,null,-1)),n("span",rV,c(o.source.fullName.slice(o.source.fullName.indexOf("/")+1)),1)],64)):(a(),l(q,{key:1},[g(c(o?.source?.fullName||o?.repoId),1)],64))],8,oV)]),n("div",aV,[n("code",{class:"anonymous-id",title:o?.repoId},[(o?.repoId||"").length>14?(a(),l(q,{key:0},[n("span",dV,c(o.repoId.slice(0,-6)),1),n("span",uV,c(o.repoId.slice(-6)),1)],64)):(a(),l(q,{key:1},[g(c(o?.repoId),1)],64))],8,lV),o?.source?.commit?(a(),l("span",{key:0,class:"commit-hash",title:o.source.commit},c(o.source.commit.substring(0,7)),9,cV)):f("v-if",!0)])])]),n("div",pV,[n("div",fV,[n("div",mV,[n("span",{class:P(["status-dot","status-"+(o?.status=="error"?"error":o?.status=="ready"?"ready":o?.status=="expired"||o?.status=="removed"?o?.status:"progress")]),"aria-hidden":"true"},null,2),n("span",{class:"status-word",textContent:c(e.fmt?.statusLabel(o?.status))},null,8,hV)]),o?.status=="error"&&o?.statusMessage?(a(),l("div",{key:0,class:"status-sub status-sub-error",textContent:c(e.fmt?.statusMsg(o?.statusMessage)),title:o?.statusMessage},null,8,gV)):f("v-if",!0),o?.status=="error"?(a(),l("a",{key:1,class:"project-attention-action",href:e.safeUrl("/status/"+o?.repoId)},"View status",8,vV)):f("v-if",!0),o?.status=="expired"?(a(),l("button",{key:2,type:"button",class:"project-attention-action",onClick:ae(d=>e.extendRepo(o),["stop"]),disabled:e.extendingId===o?.repoId,title:"Reviewers can no longer open this link"},"Extend 6 months",8,yV)):f("v-if",!0),o?.anonymizeDate&&o?.status!="error"&&o?.status!="expired"?(a(),l("div",bV,"anonymized "+c(e.fmt?.humanTime(o?.anonymizeDate)),1)):f("v-if",!0)]),n("div",{class:"cell-views num",role:"cell","data-unit":(o?.pageView||0)===1?"view":"views","aria-label":e.fmt?.number(o?.pageView||0)+((o?.pageView||0)===1?" view":" views")},[t[31]||(t[31]=n("svg",{class:"project-type-svg mobile-meta-icon","aria-hidden":"true"},[n("use",{href:"#project-icon-eye"})],-1)),n("span",null,c(e.fmt?.number(o?.pageView||0)),1)],8,wV),n("div",kV,[t[33]||(t[33]=n("svg",{class:"project-type-svg mobile-meta-icon","aria-hidden":"true"},[n("use",{href:"#project-icon-clock"})],-1)),o?.status=="ready"&&(o?.options?.expirationMode==="never"||!o?.options?.expirationDate)?(a(),l("span",CV,"No expiry")):f("v-if",!0),o?.status=="ready"&&o?.options?.expirationMode!=="never"&&o?.options?.expirationDate?(a(),l("span",{key:1,textContent:c((e.fmt?.humanTime(o?.options?.expirationDate)||"").replace(/^on /,""))},null,8,EV)):f("v-if",!0),o?.status=="expired"?(a(),l("span",SV,[t[32]||(t[32]=n("span",{class:"expires-past-prefix"},"Expired ",-1)),g(c(e.fmt?.shortDate(o?.options?.expirationDate)),1)])):f("v-if",!0),o?.status!="ready"&&o?.status!="expired"?(a(),l("span",NV,"\u2014")):f("v-if",!0)])]),n("div",RV,[o?.status!="expired"&&o?.status!="removed"?(a(),l("button",{key:0,type:"button",class:"copy-url",onClick:ae(d=>e.copyRepoLink(o),["stop"]),disabled:!!e.copyingId,title:"Copy link: /r/"+o?.repoId+"/","aria-label":"Copy anonymous link for "+o?.repoId},[n("span",DV,c(e.copyingId===o?.repoId?"Link copied":""),1),(a(),l("svg",AV,[n("use",{href:e.copyingId===o?.repoId?"#ui-icon-check":"#project-icon-copy"},null,8,TV)])),n("span",OV,c(e.copyingId===o?.repoId?"Copied":"Copy link"),1)],8,PV)):f("v-if",!0),o?.status!="expired"&&o?.status!="removed"?(a(),l("a",{key:1,class:"row-edit row-open",href:e.safeUrl("/r/"+o?.repoId+"/"),target:"_blank",rel:"noopener",title:"Open what reviewers see","aria-label":"Open anonymous page for "+o?.repoId},[...t[34]||(t[34]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-external-link"})],-1)])],8,IV)):f("v-if",!0),n("div",MV,[n("button",{class:"btn btn-icon-dots",type:"button","data-toggle":"dropdown","aria-haspopup":"true","aria-expanded":"false","aria-label":"Actions for "+o?.repoId},[...t[35]||(t[35]=[n("svg",{class:"project-type-svg","aria-hidden":"true"},[n("use",{href:"#project-icon-more"})],-1)])],8,VV),n("div",qV,[n("a",{class:"dropdown-item",href:e.safeUrl("/r/"+o?.repoId+"/")},"View",8,_V),n("a",{class:"dropdown-item",href:e.safeUrl("https://github.com/"+o?.source?.fullName+"/"),target:"_blank",rel:"noopener"},"Open source on GitHub",8,LV),n("a",{class:"dropdown-item",href:e.safeUrl("/anonymize/"+o?.repoId)},"Edit",8,$V)])])])],2))),128)),e.filteredRepositories?.length==0?(a(),l("div",FV,[t[36]||(t[36]=n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#project-icon-inbox"})],-1)),e.conference?.repositories?.length?f("v-if",!0):(a(),l("span",UV,"No repository has been submitted to this conference yet.")),e.conference?.repositories?.length?(a(),l("span",BV,"Nothing matches the current filters.")):f("v-if",!0),e.conference?.repositories?.length?(a(),l("div",zV,[n("button",{type:"button",class:"btn btn-outline-ink",onClick:t[5]||(t[5]=o=>{e.search="",e.setConfView("current")})},"Clear filters")])):f("v-if",!0)])):f("v-if",!0)],2)])])])}var HV={class:"container page paper-page conferences-page"},jV={class:"row"},GV={class:"w-100"},WV={class:"d-flex align-items-start justify-content-between flex-wrap page-head-row page-head page-head-main",style:{gap:"12px"}},KV={key:0,href:"/conference/new",class:"btn btn-primary"},YV={class:"search-wrap"},XV={type:"search",id:"search",class:"form-control","aria-label":"Search conferences",placeholder:"Search by name or ID\u2026",autocomplete:"off"},JV={class:"dashboard-filter-controls"},QV={class:"dropdown"},ZV={class:"btn dropdown-toggle",type:"button",id:"dropdownSort","data-toggle":"dropdown","aria-haspopup":"true","aria-expanded":"false"},xV={class:"filter-btn-value"},eq={class:"dropdown-menu","aria-labelledby":"dropdownSort"},tq={class:"form-check dropdown-item"},nq={class:"form-check-input",type:"radio",name:"sort",id:"sortName",value:"name"},sq={class:"form-check dropdown-item"},oq={class:"form-check-input",type:"radio",name:"sort",id:"sortID",value:"conferenceID"},iq={class:"form-check dropdown-item"},rq={class:"form-check-input",type:"radio",name:"sort",id:"sortStatus",value:"-status"},aq={class:"dropdown"},lq={class:"btn dropdown-toggle",type:"button",id:"dropdownStatus","data-toggle":"dropdown","aria-haspopup":"true","aria-expanded":"false"},dq={key:0,class:"filter-btn-value"},uq={key:1,class:"filter-btn-value"},cq={class:"dropdown-menu","aria-labelledby":"dropdownStatus"},pq={class:"form-check dropdown-item"},fq=["id"],mq=["for"],hq={key:1,class:"dashboard-meta"},gq={class:"dashboard-count"},vq={key:0},yq={key:0},bq={key:1},wq={key:0,class:"filter-chip"},kq=["onClick","aria-label"],Cq={key:0,class:"conference-feedback",role:"alert"},Eq={key:1,class:"conference-feedback",role:"status"},Sq={class:"paper-table paper-table-conferences w-100",role:"table","aria-label":"Conferences"},Nq={class:"cell-anon",role:"cell"},Rq={class:"anon-text"},Pq=["textContent","href"],Dq={class:"anon-sub"},Aq={class:"anon-source"},Tq=["textContent"],Oq={key:0},Iq=["textContent","href"],Mq={class:"cell-status",role:"cell"},Vq={class:"status-line"},qq=["textContent"],_q={class:"cell-views num",role:"cell"},Lq=["textContent"],$q={class:"cell-expires",role:"cell"},Fq={key:0},Uq={key:1,class:"empty-dash","aria-label":"No review window"},Bq={class:"cell-actions",role:"cell"},zq={class:"dropdown"},Hq=["disabled","aria-label"],jq={class:"dropdown-menu dropdown-menu-right"},Gq=["href"],Wq=["href"],Kq={key:0},Yq=["onClick"],Xq={key:0,class:"paper-table-empty"},Jq={key:0,class:"empty-icon","aria-hidden":"true"},Qq={key:1,class:"ui-icon","aria-hidden":"true"},Zq={key:3},xq={class:"paper-table-empty-actions"},e_={key:0,href:"/conference/new",class:"btn btn-primary conf-empty-new"};function cp(e,t){let s=De("field"),i=De("form");return a(),l("div",HV,[n("div",jV,[n("div",GV,[n("div",WV,[t[4]||(t[4]=n("div",null,[n("h1",{class:"paper-page-title"},[g("Your "),n("em",null,"conferences")]),n("p",{class:"paper-page-lede"},"Group anonymizations by venue, give chairs a shared dashboard, and set one expiry for every submission.")],-1)),e.conferences&&e.conferences.length==0?f("v-if",!0):(a(),l("a",KV,[...t[3]||(t[3]=[n("svg",{class:"ui-icon mr-1","aria-hidden":"true"},[n("use",{href:"#project-icon-plus"})],-1),g(" New conference ",-1)])]))]),e.conferences?.length>0?T((a(),l("form",{key:0,class:"w-100 dashboard-filter-row","aria-label":"Filter conferences","accept-charset":"UTF-8",onSubmit:t[0]||(t[0]=ae(o=>e.submitForm(o,()=>{o.preventDefault()}),["prevent"]))},[n("div",YV,[T(n("input",XV,null,512),[[s,{state:e.viewState,set:o=>{e.search=o},value:e.search,form:null,options:{}}]])]),n("div",JV,[n("div",QV,[n("button",ZV,[t[5]||(t[5]=n("span",{class:"filter-btn-label"},"Sort",-1)),n("span",xV,c({name:"Name",conferenceID:"ID","-status":"Status"}[e.orderBy]||"Custom"),1)]),n("div",eq,[t[9]||(t[9]=n("h6",{class:"dropdown-header"},"Order by",-1)),n("div",tq,[T(n("input",nq,null,512),[[s,{state:e.viewState,set:o=>{e.orderBy=o},value:e.orderBy,form:null,options:{}}]]),t[6]||(t[6]=n("label",{class:"form-check-label",for:"sortName"},"Name",-1))]),n("div",sq,[T(n("input",oq,null,512),[[s,{state:e.viewState,set:o=>{e.orderBy=o},value:e.orderBy,form:null,options:{}}]]),t[7]||(t[7]=n("label",{class:"form-check-label",for:"sortID"},"ID",-1))]),n("div",iq,[T(n("input",rq,null,512),[[s,{state:e.viewState,set:o=>{e.orderBy=o},value:e.orderBy,form:null,options:{}}]]),t[8]||(t[8]=n("label",{class:"form-check-label",for:"sortStatus"},"Status",-1))])])]),n("div",aq,[n("button",lq,[t[10]||(t[10]=n("span",{class:"filter-btn-label"},"Status",-1)),e.filters?.status?.ready&&e.filters?.status?.expired&&e.filters?.status?.removed?(a(),l("span",dq,"All")):f("v-if",!0),e.filters?.status?.ready&&e.filters?.status?.expired&&e.filters?.status?.removed?f("v-if",!0):(a(),l("span",uq,c((e.filters?.status?.ready?0:1)+(e.filters?.status?.expired?0:1)+(e.filters?.status?.removed?0:1))+" hidden ",1))]),n("div",cq,[t[11]||(t[11]=n("h6",{class:"dropdown-header"},"Show statuses",-1)),(a(!0),l(q,null,Q(e.statusLabels,(o,r,d)=>(a(),l("div",pq,[T(n("input",{class:"form-check-input",type:"checkbox",id:"status-"+r},null,8,fq),[[s,{state:e.viewState,set:p=>{e.filters.status[r]=p},value:e.filters?.status[r],form:null,options:{}}]]),n("label",{class:"form-check-label",for:"status-"+r},c(o),9,mq)]))),256))])])])],32)),[[i,e.viewState]]):f("v-if",!0),e.conferences?.length>0?(a(),l("div",hq,[n("span",gq,[e.filteredConferences?.length===e.conferences?.length?(a(),l("span",vq,[g(c(e.fmt?.number(e.conferences?.length))+" conference",1),e.conferences?.length!==1?(a(),l("span",yq,"s")):f("v-if",!0)])):f("v-if",!0),e.filteredConferences?.length!==e.conferences?.length?(a(),l("span",bq,c(e.fmt?.number(e.filteredConferences?.length))+" of "+c(e.fmt?.number(e.conferences?.length))+" shown",1)):f("v-if",!0)]),(a(!0),l(q,null,Q(e.filters?.status,(o,r,d)=>(a(),l(q,null,[o===!1?(a(),l("span",wq,[g(" Hiding "+c(e.statusLabels[r])+" ",1),n("button",{type:"button",class:"filter-chip-close",onClick:p=>{e.filters.status[r]=!0},"aria-label":"Show "+e.statusLabels[r]+" again"},"\xD7",8,kq)])):f("v-if",!0)],64))),256))])):f("v-if",!0)]),e.error?(a(),l("div",Cq,[n("span",null,c(e.error),1),n("button",{type:"button",class:"btn btn-outline-ink",onClick:t[1]||(t[1]=o=>e.loadConferences())},"Retry")])):f("v-if",!0),e.loading?(a(),l("div",Eq,"Loading conferences\u2026")):f("v-if",!0),n("div",Sq,[t[28]||(t[28]=n("div",{class:"paper-table-head",role:"row"},[n("div",{role:"columnheader"},"Conference"),n("div",{role:"columnheader"},"Status"),n("div",{role:"columnheader",class:"num"},"Repos"),n("div",{role:"columnheader"},"Review window"),n("div",{role:"columnheader"},[n("span",{class:"sr-only"},"Actions")])],-1)),(a(!0),l(q,null,Q(e.filteredConferences,(o,r)=>(a(),l("div",{class:P(["paper-table-row row-clickable",{"repo-inactive":o?.status=="expired"||o?.status=="removed"}]),role:"row",key:o?.conferenceID},[n("div",Nq,[t[14]||(t[14]=n("svg",{class:"ui-icon record-type-icon",role:"img","aria-label":"Conference"},[n("use",{href:"#project-icon-conference"})],-1)),n("div",Rq,[n("a",{class:"repo-name",textContent:c(o?.name),href:e.safeUrl("/conference/"+o?.conferenceID)},null,8,Pq),n("div",Dq,[n("span",Aq,[t[13]||(t[13]=g("ID ",-1)),n("span",{class:"commit-hash",textContent:c(o?.conferenceID)},null,8,Tq),o?.url?(a(),l("span",Oq,[t[12]||(t[12]=g(" \xB7 ",-1)),n("a",{target:"_blank",rel:"noopener",textContent:c(e.fmt?.limitTo(o?.url,60)),href:e.safeUrl(o?.url)},null,8,Iq)])):f("v-if",!0)])])])]),n("div",Mq,[n("div",Vq,[n("span",{class:P(["status-dot","status-"+o?.status]),"aria-hidden":"true"},null,2),n("span",{class:"status-word",textContent:c(e.fmt?.statusLabel(o?.status))},null,8,qq)])]),n("div",_q,[t[15]||(t[15]=n("svg",{class:"ui-icon mobile-meta-icon","aria-hidden":"true"},[n("use",{href:"#project-type-repo"})],-1)),t[16]||(t[16]=g()),n("span",{textContent:c(e.fmt?.number(o?.nbRepositories||0))},null,8,Lq)]),n("div",$q,[t[17]||(t[17]=n("svg",{class:"ui-icon mobile-meta-icon","aria-hidden":"true"},[n("use",{href:"#project-icon-clock"})],-1)),o?.startDate?(a(),l("span",Fq,c(e.fmt?.date(o?.startDate,"mediumDate"))+" \u2013 "+c(e.fmt?.date(o?.endDate,"mediumDate")),1)):f("v-if",!0),o?.startDate?f("v-if",!0):(a(),l("span",Uq,"\u2014"))]),n("div",Bq,[n("div",zq,[n("button",{class:"btn btn-icon-dots",type:"button","data-toggle":"dropdown","aria-haspopup":"true","aria-expanded":"false",disabled:o?.removing,"aria-label":"Actions for "+o?.name},[...t[18]||(t[18]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#project-icon-more"})],-1)])],8,Hq),n("div",jq,[n("a",{class:"dropdown-item",href:e.safeUrl("/conference/"+o?.conferenceID+"/")},[...t[19]||(t[19]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#project-icon-eye"})],-1),g(" View ",-1)])],8,Gq),n("a",{class:"dropdown-item",href:e.safeUrl("/conference/"+o?.conferenceID+"/edit")},[...t[20]||(t[20]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-edit"})],-1),g(" Edit ",-1)])],8,Wq),o?.status!="removed"?(a(),l("div",Kq,[t[22]||(t[22]=n("div",{class:"dropdown-divider"},null,-1)),n("button",{type:"button",class:"dropdown-item dropdown-item-danger",onClick:d=>e.removeConference(o)},[...t[21]||(t[21]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-trash"})],-1),g(" Remove ",-1)])],8,Yq)])):f("v-if",!0)])])])],2))),128)),!e.loading&&!e.error&&e.filteredConferences?.length==0?(a(),l("div",Xq,[e.conferences?.length==0?(a(),l("span",Jq,[...t[23]||(t[23]=[n("svg",{class:"ui-icon"},[n("use",{href:"#project-icon-conference"})],-1)])])):f("v-if",!0),e.conferences?.length>0?(a(),l("svg",Qq,[...t[24]||(t[24]=[n("use",{href:"#project-icon-inbox"},null,-1)])])):f("v-if",!0),e.conferences?.length==0?(a(),l(q,{key:2},[t[25]||(t[25]=n("strong",{class:"empty-title"},"No conferences yet",-1)),t[26]||(t[26]=n("span",null,"Create one to group submissions for a venue, share a dashboard with chairs, and set a single expiry date.",-1))],64)):f("v-if",!0),e.conferences?.length>0?(a(),l("span",Zq,"Nothing matches the current filters.")):f("v-if",!0),n("div",xq,[e.conferences?.length==0?(a(),l("a",e_,[...t[27]||(t[27]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#project-icon-plus"})],-1),g(" New conference",-1)])])):f("v-if",!0),e.conferences?.length>0?(a(),l("button",{key:1,type:"button",class:"btn btn-outline-ink",onClick:t[2]||(t[2]=o=>{e.search="",e.filters.status.ready=!0,e.filters.status.expired=!0,e.filters.status.removed=!0})},"Clear filters")):f("v-if",!0)])])):f("v-if",!0)])])])}var t_={class:"container page dashboard-page paper-page"},n_={class:"row"},s_={class:"w-100"},o_={class:"dashboard-heading page-head page-head-main"},i_={class:"dashboard-title-line"},r_={key:0,class:"dashboard-count-head","aria-hidden":"true"},a_={key:0},l_={class:"dashboard-heading-actions"},d_=["open"],u_=["aria-expanded"],c_=["stroke-dasharray"],p_={key:1,d:"M7 12c0-4 4-4 5 0s5 4 5 0-4-4-5 0-5 4-5 0",class:"quota-ring-unlimited"},f_={key:0,class:"quota-summary-value"},m_={key:0},h_={class:"quota-panel",id:"dashboard-usage"},g_={class:"quota-panel-heading"},v_={key:1,class:"quota-loading",role:"status"},y_={key:0,class:"dashboard-meta"},b_={key:0,class:"dashboard-view-tabs",role:"group","aria-label":"Project view"},w_=["aria-pressed"],k_=["aria-pressed","aria-label"],C_=["aria-pressed","aria-label"],E_={key:0,class:"attention-count"},S_={key:0},N_={key:0},R_={key:1},P_={class:"search-wrap"},D_={type:"search",id:"search",class:"form-control","aria-label":"Search anonymizations",placeholder:"Search projects\u2026",autocomplete:"off"},A_=["aria-expanded"],T_={class:"btn-group",role:"group","aria-label":"Type"},O_=["aria-pressed"],I_=["aria-pressed"],M_=["aria-pressed"],V_=["aria-pressed"],q_={class:"dropdown"},__={class:"btn dropdown-toggle",type:"button",id:"dropdownSort","data-toggle":"dropdown","aria-haspopup":"true","aria-expanded":"false"},L_={class:"filter-btn-value"},$_={class:"sr-only"},F_={class:"dropdown-menu","aria-labelledby":"dropdownSort"},U_={class:"form-check dropdown-item"},B_=["onClick","checked","id"],z_=["for"],H_=["inert"],j_={class:"btn dropdown-toggle",type:"button",id:"dropdownStatus","data-toggle":"dropdown","aria-haspopup":"true","aria-expanded":"false"},G_={class:"filter-btn-value"},W_={class:"dropdown-menu","aria-labelledby":"dropdownStatus"},K_={key:0,class:"form-check dropdown-item"},Y_=["id"],X_=["for"],J_={key:1,class:"dashboard-active-filters dashboard-active-filters-row"},Q_=["onClick","aria-label","title"],Z_=["aria-busy"],x_={class:"paper-table-head",role:"row"},eL=["aria-sort"],tL=["aria-sort"],nL=["aria-sort"],sL=["aria-sort"],oL={key:0,class:"paper-table-row paper-table-skeleton",role:"row","aria-hidden":"true"},iL=["onClick"],rL={class:"cell-anon",role:"cell"},aL=["aria-label","title"],lL={class:"project-type-svg","aria-hidden":"true"},dL=["href"],uL={class:"anon-text"},cL={class:"anon-title"},pL=["title","href"],fL={class:"rn-owner"},mL={class:"rn-repo"},hL={key:1,class:"repo-name repo-name-static"},gL={class:"rn-owner"},vL={class:"rn-repo"},yL={key:2,class:"type-badge type-coauthor",title:"You are a co-author on this anonymization"},bL={key:0,class:"anon-sub"},wL=["title"],kL={class:"id-head"},CL={class:"id-tail"},EL=["title"],SL=["title"],NL=["textContent"],RL={class:"dashboard-row-meta",role:"presentation"},PL={class:"cell-status",role:"cell"},DL={class:"status-line"},AL=["textContent"],TL=["onClick"],OL=["textContent","title"],IL=["title"],ML=["href"],VL={key:3,class:"status-action-line"},qL={key:0,class:"status-stuck"},_L=["onClick","data-project-actions","aria-controls","aria-expanded"],LL=["onClick"],$L={key:5,class:"status-sub status-sub-date status-sub-removed"},FL={key:6,class:"status-sub status-sub-date"},UL=["data-unit","aria-label"],BL={class:"cell-expires",role:"cell"},zL={key:0,class:"expires-never"},HL=["textContent"],jL=["title"],GL={key:3,class:"expires-past"},WL={key:4,class:"expires-past"},KL={key:5,class:"empty-dash","aria-label":"Not applicable"},YL={class:"cell-actions",role:"cell"},XL=["onClick","disabled","title","aria-label"],JL={class:"sr-only","aria-live":"polite"},QL={class:"project-type-svg","aria-hidden":"true"},ZL=["href"],xL={class:"copy-url-label","aria-hidden":"true"},e$=["href","aria-label"],t$=["href","title","aria-label"],n$=["title","aria-label"],s$=["title","aria-label"],o$=["aria-label"],i$={key:6,class:"dropdown is-disabled"},r$=["aria-label"],a$={key:7,class:"dropdown"},l$=["data-project-actions","aria-label"],d$={class:"dropdown-menu dropdown-menu-right"},u$=["onClick","aria-controls","aria-expanded"],c$=["href"],p$=["href"],f$=["onClick","disabled"],m$=["href"],h$=["onClick"],g$=["onClick"],v$=["onClick"],y$={key:5},b$=["onClick"],w$={key:1,class:"project-details-row",role:"row"},k$=["id","onKeydown"],C$={class:"project-details-heading"},E$=["onClick"],S$={class:"project-details-list"},N$={key:0},R$={key:1},P$={key:0},D$={key:2},A$={key:0,class:"project-progress-help"},T$=["href"],O$=["onSubmit"],I$=["for"],M$=["id"],V$={class:"project-name-controls"},q$=["id","aria-describedby","disabled"],_$=["disabled"],L$={key:0,class:"project-name-error",role:"alert"},$$={key:1,role:"status"},F$={key:0,class:"paper-table-empty"},U$={key:0},B$={key:1},z$={class:"paper-table-empty-actions"},H$={key:1,href:"/anonymize",class:"btn btn-ink"},j$={key:0,class:"dashboard-pagination"},G$={key:0,role:"alert"},W$=["disabled"];function pp(e,t){let s=Xe("quota-usage"),i=De("field"),o=De("form");return a(),l("div",t_,[n("div",n_,[n("div",s_,[n("div",o_,[n("div",null,[n("div",i_,[t[27]||(t[27]=n("h1",{class:"paper-page-title"},"My work",-1)),!e.loading&&e.isPlainView()?(a(),l("span",r_,[g(c(e.fmt?.number(e.dashboardTotals?.filtered??e.filteredItems?.length))+" project",1),(e.dashboardTotals?.filtered??e.filteredItems?.length)!==1?(a(),l("span",a_,"s")):f("v-if",!0)])):f("v-if",!0)]),t[28]||(t[28]=n("p",{class:"paper-page-lede"},"Manage your anonymous links.",-1))]),n("div",l_,[n("details",{class:"dashboard-quota",open:e.quotaExpanded,onToggle:t[1]||(t[1]=r=>e.quotaExpanded=r.target.open),onKeydown:t[2]||(t[2]=kt(ae(r=>e.closeQuota(),["prevent","stop"]),["esc"]))},[n("summary",{"aria-controls":"dashboard-usage","aria-expanded":e.quotaExpanded,class:P(e.quota?"quota-level-"+e.quota.repository.level:""),style:Te(e.quota&&!e.quota.repository.unlimited?{"--quota-pct":e.quota.repository.percent+"%"}:null)},[(a(),l("svg",{class:P(["quota-summary-ring",e.quota?"quota-"+e.quota.repository.level:""]),viewBox:"0 0 24 24","aria-hidden":"true"},[t[29]||(t[29]=n("circle",{class:"quota-ring-track",cx:"12",cy:"12",r:"9"},null,-1)),e.quota&&!e.quota.repository.unlimited?(a(),l("circle",{key:0,class:"quota-ring-fill",cx:"12",cy:"12",r:"9",pathLength:"100","stroke-dasharray":e.quota.repository.percent+" 100"},null,8,c_)):f("v-if",!0),e.quota?.repository.unlimited?(a(),l("path",p_)):f("v-if",!0)],2)),t[31]||(t[31]=n("span",{class:"quota-summary-label"},"Usage",-1)),e.quota?(a(),l("span",f_,[g(c(e.fmt.number(e.quota.repository.used)),1),e.quota.repository.unlimited?f("v-if",!0):(a(),l("span",m_," / "+c(e.fmt.number(e.quota.repository.total)),1)),t[30]||(t[30]=g(" repos",-1))])):f("v-if",!0),t[32]||(t[32]=n("svg",{class:"project-type-svg quota-summary-chevron","aria-hidden":"true"},[n("use",{href:"#project-icon-chevron"})],-1))],14,u_),n("div",h_,[n("div",g_,[t[34]||(t[34]=n("h2",null,"Account usage",-1)),n("button",{type:"button",class:"project-close","aria-label":"Close usage",onClick:t[0]||(t[0]=r=>e.closeQuota())},[...t[33]||(t[33]=[n("svg",{class:"project-type-svg","aria-hidden":"true"},[n("use",{href:"#project-icon-close"})],-1)])])]),e.quota?(a(),Gt(s,{key:0,quota:e.quota,fmt:e.fmt},null,8,["quota","fmt"])):(a(),l("p",v_,"Loading usage\u2026"))])],40,d_),t[35]||(t[35]=Ce('New anonymization',1))])]),f(" Result count + active filter chips "),e.loading?f("v-if",!0):(a(),l("div",y_,[e.showViewTabs()?(a(),l("div",b_,[n("button",{type:"button","aria-pressed":e.statusView()==="active",onClick:t[3]||(t[3]=r=>e.setStatusView("active")),title:"Every project except removed links"},"Current",8,w_),e.attentionCount()>0||e.statusView()==="attention"?(a(),l("button",{key:0,type:"button","aria-pressed":e.statusView()==="attention",onClick:t[4]||(t[4]=r=>e.setStatusView("attention")),"aria-label":"Needs attention "+e.attentionCount()},[t[36]||(t[36]=n("span",{class:"dashboard-attention-prefix"},"Needs ",-1)),t[37]||(t[37]=n("span",null,"attention",-1)),t[38]||(t[38]=g()),n("span",{class:P(["attention-count",{"has-attention":e.attentionCount()>0}])},c(e.attentionCount()),3)],8,k_)):f("v-if",!0),e.removedCount>0||e.statusView()==="removed"||e.removedCount==null&&e.dashboardTotals?.total>e.dashboardTotals?.filtered?(a(),l("button",{key:1,type:"button","aria-pressed":e.statusView()==="removed",onClick:t[5]||(t[5]=r=>e.setStatusView("removed")),"aria-label":"Removed "+(e.removedCount??""),title:"Links reviewers can no longer open"},[t[39]||(t[39]=g("Removed ",-1)),e.removedCount!=null?(a(),l("span",E_,c(e.fmt?.number(e.removedCount)),1)):f("v-if",!0)],8,C_)):f("v-if",!0)])):f("v-if",!0),n("span",{class:P(["dashboard-count",{"is-plain":e.isPlainView()}])},[e.isPlainView()?(a(),l("span",S_,[g(c(e.fmt?.number(e.dashboardTotals?.filtered??e.filteredItems?.length))+" project",1),(e.dashboardTotals?.filtered??e.filteredItems?.length)!==1?(a(),l("span",N_,"s")):f("v-if",!0)])):(a(),l("span",R_,c(e.fmt?.number(e.dashboardTotals?.filtered??e.filteredItems?.length))+" shown",1))],2)])),f(" Search + filters "),T((a(),l("form",{class:"w-100 dashboard-filter-row","aria-label":"Filter anonymizations","accept-charset":"UTF-8",onSubmit:t[13]||(t[13]=ae(r=>e.submitForm(r,()=>{r.preventDefault()}),["prevent"]))},[n("div",P_,[T(n("input",D_,null,512),[[i,{state:e.viewState,set:r=>{e.search=r},value:e.search,form:null,options:{}}]])]),n("button",{class:"btn dashboard-filters-toggle",type:"button","aria-expanded":e.filtersExpanded,"aria-controls":"dashboard-filter-controls",onClick:t[6]||(t[6]=r=>e.filtersExpanded=!e.filtersExpanded)},[...t[40]||(t[40]=[g("Filters",-1),n("svg",{class:"project-type-svg","aria-hidden":"true"},[n("use",{href:"#project-icon-filter"})],-1)])],8,A_),n("div",{id:"dashboard-filter-controls",class:P(["dashboard-filter-controls",{expanded:e.filtersExpanded}])},[n("div",T_,[n("button",{type:"button",class:P(["btn",{"btn-primary":e.typeFilter==="all"}]),onClick:t[7]||(t[7]=r=>e.typeFilter="all"),"aria-pressed":e.typeFilter==="all"},"All",10,O_),n("button",{type:"button",class:P(["btn dashboard-type-filter",{"btn-primary":e.typeFilter==="repo"}]),title:"Repositories",onClick:t[8]||(t[8]=r=>e.typeFilter="repo"),"aria-pressed":e.typeFilter==="repo"},[...t[41]||(t[41]=[n("svg",{class:"project-type-svg","aria-hidden":"true"},[n("use",{href:"#project-type-repo"})],-1),n("span",{class:"type-filter-label"},"Repos",-1)])],10,I_),n("button",{type:"button",class:P(["btn dashboard-type-filter",{"btn-primary":e.typeFilter==="pr"}]),title:"Pull requests",onClick:t[9]||(t[9]=r=>e.typeFilter="pr"),"aria-pressed":e.typeFilter==="pr"},[...t[42]||(t[42]=[n("svg",{class:"project-type-svg","aria-hidden":"true"},[n("use",{href:"#project-type-pr"})],-1),n("span",{class:"type-filter-label"},"PRs",-1)])],10,M_),n("button",{type:"button",class:P(["btn dashboard-type-filter",{"btn-primary":e.typeFilter==="gist"}]),title:"Gists",onClick:t[10]||(t[10]=r=>e.typeFilter="gist"),"aria-pressed":e.typeFilter==="gist"},[...t[43]||(t[43]=[n("svg",{class:"project-type-svg","aria-hidden":"true"},[n("use",{href:"#project-type-gist"})],-1),n("span",{class:"type-filter-label"},"Gists",-1)])],10,V_)]),n("div",{id:"dashboard-extra-filters",class:P(["dashboard-extra-filters",{expanded:e.filtersExpanded}])},[n("div",q_,[n("button",__,[t[45]||(t[45]=n("span",{class:"filter-btn-label"},"Sort",-1)),n("span",L_,c(e.sortLabel()),1),(a(),l("svg",{class:P(["project-type-svg sort-direction",{ascending:!e.sortDesc()}]),"aria-hidden":"true"},[...t[44]||(t[44]=[n("use",{href:"#project-icon-arrow"},null,-1)])],2)),n("span",$_,c(e.sortDesc()?"descending":"ascending"),1)]),n("div",F_,[t[46]||(t[46]=n("h6",{class:"dropdown-header"},"Order by",-1)),(a(!0),l(q,null,Q(e.sortFields,(r,d,p)=>(a(),l("div",U_,[n("input",{class:"form-check-input",type:"radio",name:"sort",onClick:u=>e.setSort(d,r.defaultDesc),checked:e.isSortedBy(d),id:"sort-"+p},null,8,B_),n("label",{class:"form-check-label",for:"sort-"+p},c(r?.label),9,z_)]))),256)),t[47]||(t[47]=n("div",{class:"dropdown-divider"},null,-1)),n("button",{type:"button",class:"dropdown-item",onClick:t[11]||(t[11]=r=>e.toggleSortDirection())},c(e.sortDesc()?"Switch to ascending":"Switch to descending"),1)])]),n("div",{class:P(["dropdown dashboard-status-filter",{"is-view-hidden":e.statusView()==="removed"}]),inert:e.statusView()==="removed"?!0:null},[n("button",j_,[t[48]||(t[48]=n("span",{class:"filter-btn-label"},"Status",-1)),n("span",G_,c(e.statusChipKeys().length===0?"Any":e.statusChipKeys().length===1?"Hiding "+(e.statusKeyLabels[e.statusChipKeys()[0]]||"").toLowerCase():e.statusChipKeys().length+" hidden"),1)]),n("div",W_,[t[49]||(t[49]=n("h6",{class:"dropdown-header"},"Show statuses",-1)),n("button",{type:"button",class:P(["dropdown-item status-preset",{active:e.statusChipKeys().length===0}]),onClick:t[12]||(t[12]=r=>e.statusChipKeys().forEach(d=>{e.filters.status[d]=!0}))},"Any status",2),t[50]||(t[50]=n("div",{class:"dropdown-divider"},null,-1)),(a(!0),l(q,null,Q(e.statusKeyLabels,(r,d,p)=>(a(),l(q,{key:d},[d!=="removed"?(a(),l("div",K_,[T(n("input",{class:"form-check-input",type:"checkbox",id:"status-"+d},null,8,Y_),[[i,{state:e.viewState,set:u=>{e.filters.status[d]=u},value:e.filters?.status[d],form:null,options:{}}]]),n("label",{class:"form-check-label",for:"status-"+d},c(r),9,X_)])):f("v-if",!0)],64))),128))])],10,H_)],2)],2)],32)),[[o,e.viewState]]),!e.loading&&e.showClearFilters()?(a(),l("div",J_,[(a(!0),l(q,null,Q(e.statusChipKeys(),r=>(a(),l("button",{key:r,type:"button",class:"filter-chip",onClick:d=>e.filters.status[r]=!0,"aria-label":"Show "+e.statusKeyLabels[r]+" again",title:"Show "+e.statusKeyLabels[r]+" again"},[g("Hiding "+c((e.statusKeyLabels[r]||"").toLowerCase()),1),t[51]||(t[51]=n("svg",{class:"project-type-svg","aria-hidden":"true"},[n("use",{href:"#project-icon-close"})],-1))],8,Q_))),128)),e.typeFilter!=="all"?(a(),l("button",{key:0,type:"button",class:"filter-chip",onClick:t[14]||(t[14]=r=>e.typeFilter="all"),"aria-label":"Show all project types"},[g(c(e.typeFilter==="repo"?"Repositories":e.typeFilter==="pr"?"Pull requests":"Gists"),1),t[52]||(t[52]=n("svg",{class:"project-type-svg","aria-hidden":"true"},[n("use",{href:"#project-icon-close"})],-1))])):f("v-if",!0),e.showClearFilters()?(a(),l("button",{key:1,type:"button",class:"btn-link-inline",onClick:t[15]||(t[15]=r=>e.clearFilters())},"Clear filters")):f("v-if",!0)])):f("v-if",!0)]),f(" Table "),n("div",{class:P(["paper-table paper-table-dashboard",{"is-removed-view":e.statusView()==="removed"}]),role:"table","aria-label":"Anonymizations","aria-busy":e.loading},[n("div",x_,[n("div",{role:"columnheader","aria-sort":e.isSortedBy("_label")?e.sortDesc()?"descending":"ascending":"none"},[n("button",{type:"button",class:P(["sortable",{active:e.isSortedBy("_label")}]),onClick:t[16]||(t[16]=r=>e.setSort("_label"))},[t[54]||(t[54]=g(" Project ",-1)),e.isSortedBy("_label")?(a(),l("svg",{key:0,class:P(["project-type-svg sort-direction",{ascending:!e.sortDesc()}]),"aria-hidden":"true"},[...t[53]||(t[53]=[n("use",{href:"#project-icon-arrow"},null,-1)])],2)):f("v-if",!0)],2)],8,eL),n("div",{role:"columnheader","aria-sort":e.isSortedBy("status")?e.sortDesc()?"descending":"ascending":"none"},[n("button",{type:"button",class:P(["sortable",{active:e.isSortedBy("status")}]),onClick:t[17]||(t[17]=r=>e.setSort("status"))},[t[56]||(t[56]=g(" Status ",-1)),e.isSortedBy("status")?(a(),l("svg",{key:0,class:P(["project-type-svg sort-direction",{ascending:!e.sortDesc()}]),"aria-hidden":"true"},[...t[55]||(t[55]=[n("use",{href:"#project-icon-arrow"},null,-1)])],2)):f("v-if",!0)],2)],8,tL),n("div",{role:"columnheader",class:"num","aria-sort":e.isSortedBy("pageView")?e.sortDesc()?"descending":"ascending":"none"},[n("button",{type:"button",class:P(["sortable",{active:e.isSortedBy("pageView")}]),onClick:t[18]||(t[18]=r=>e.setSort("pageView"))},[t[58]||(t[58]=g(" Views ",-1)),e.isSortedBy("pageView")?(a(),l("svg",{key:0,class:P(["project-type-svg sort-direction",{ascending:!e.sortDesc()}]),"aria-hidden":"true"},[...t[57]||(t[57]=[n("use",{href:"#project-icon-arrow"},null,-1)])],2)):f("v-if",!0)],2)],8,nL),n("div",{role:"columnheader","aria-sort":e.isSortedBy("options.expirationDate")?e.sortDesc()?"descending":"ascending":"none"},[n("button",{type:"button",class:P(["sortable",{active:e.isSortedBy("options.expirationDate")}]),onClick:t[19]||(t[19]=r=>e.setSort("options.expirationDate"))},[t[60]||(t[60]=g(" Expires ",-1)),e.isSortedBy("options.expirationDate")?(a(),l("svg",{key:0,class:P(["project-type-svg sort-direction",{ascending:!e.sortDesc()}]),"aria-hidden":"true"},[...t[59]||(t[59]=[n("use",{href:"#project-icon-arrow"},null,-1)])],2)):f("v-if",!0)],2)],8,sL),t[61]||(t[61]=n("div",{role:"columnheader",class:"col-link"},[n("span",{class:"sr-only"},"Actions")],-1))]),f(" Loading skeleton: keeps the layout stable while the three lists load "),(a(),l(q,null,Q([1,2,3,4],(r,d)=>(a(),l(q,null,[e.loading?(a(),l("div",oL,[...t[62]||(t[62]=[n("div",{class:"cell-anon",role:"cell"},[n("span",{class:"skeleton skeleton-badge"}),n("div",{class:"anon-text"},[n("span",{class:"skeleton skeleton-line",style:{width:"38%"}}),n("span",{class:"skeleton skeleton-line skeleton-line-sm",style:{width:"56%"}})])],-1),n("div",{class:"cell-status",role:"cell"},[n("span",{class:"skeleton skeleton-line",style:{width:"60%"}})],-1),n("div",{class:"cell-views num",role:"cell"},[n("span",{class:"skeleton skeleton-line",style:{width:"40%"}})],-1),n("div",{class:"cell-expires",role:"cell"},[n("span",{class:"skeleton skeleton-line",style:{width:"55%"}})],-1),n("div",{class:"cell-actions",role:"cell"},null,-1)])])):f("v-if",!0)],64))),64)),(a(!0),l(q,null,Q(e.filteredItems,(r,d)=>(a(),l(q,{key:r?._type+":"+(r?._id||d)},[e.loading?f("v-if",!0):(a(),l("div",{key:0,class:P(["paper-table-row",{"repo-inactive":r?._statusKey=="expired"||r?._statusKey=="removed","repo-error":r?.status=="error","row-clickable":!!r?._viewUrl}]),role:"row",onClick:p=>e.openItem(r,p)},[n("div",rL,[n("span",{class:"project-type-icon",role:"img","aria-label":r?._type==="repo"?"Repository":r?._type==="pr"?"Pull request":"Gist",title:r?._type==="repo"?"Repository":r?._type==="pr"?"Pull request":"Gist"},[(a(),l("svg",lL,[n("use",{href:"#project-type-"+r._type},null,8,dL)]))],8,aL),n("div",uL,[n("div",cL,[r?._viewUrl?(a(),l("a",{key:0,class:"repo-name",title:r._label,href:e.safeUrl(r?._viewUrl)},[(r?._label||"").indexOf("/")>0?(a(),l(q,{key:0},[n("span",fL,c(r._label.slice(0,r._label.indexOf("/")+1)),1),t[63]||(t[63]=n("wbr",null,null,-1)),n("span",mL,c(r._label.slice(r._label.indexOf("/")+1)),1)],64)):(a(),l(q,{key:1},[g(c(r?._label),1)],64))],8,pL)):f("v-if",!0),r?._viewUrl?f("v-if",!0):(a(),l("span",hL,[(r?._label||"").indexOf("/")>0?(a(),l(q,{key:0},[n("span",gL,c(r._label.slice(0,r._label.indexOf("/")+1)),1),t[64]||(t[64]=n("wbr",null,null,-1)),n("span",vL,c(r._label.slice(r._label.indexOf("/")+1)),1)],64)):(a(),l(q,{key:1},[g(c(r?._label),1)],64))])),r?.role==="coauthor"?(a(),l("span",yL,"Co-author")):f("v-if",!0)]),r?._id||r?._type==="repo"&&r?.source?.commit||r?.conference?(a(),l("div",bL,[r?._id?(a(),l("code",{key:0,class:"anonymous-id",title:r._id},[r._id.length>14?(a(),l(q,{key:0},[n("span",kL,c(r._id.slice(0,-6)),1),n("span",CL,c(r._id.slice(-6)),1)],64)):(a(),l(q,{key:1},[g(c(r._id),1)],64))],8,wL)):f("v-if",!0),r?._type==="repo"&&r?.source?.commit?(a(),l("span",{key:1,class:"commit-hash",title:r.source.commit},c(r.source.commit.substring(0,7)),9,EL)):f("v-if",!0),r?.conference?(a(),l("span",{key:2,class:"cell-conf conf-tag",title:"Conference: "+r.conference},[t[65]||(t[65]=n("svg",{class:"project-type-svg","aria-hidden":"true"},[n("use",{href:"#project-icon-conference"})],-1)),n("span",{class:"conf-name",textContent:c(r?.conference)},null,8,NL)],8,SL)):f("v-if",!0)])):f("v-if",!0)])]),n("div",RL,[n("div",PL,[n("div",DL,[n("span",{class:P(["status-dot","status-"+r?._statusKey]),"aria-hidden":"true"},null,2),n("span",{class:"status-word",textContent:c(e.fmt?.statusLabel(r?.status))},null,8,AL),r?.status=="removed"?(a(),l(q,{key:0},[t[66]||(t[66]=n("span",{class:"seg-sep status-removed-sep","aria-hidden":"true"},"\xB7",-1)),n("button",{type:"button",class:"project-attention-action status-enable",onClick:ae(p=>e.refreshItem(r),["stop"]),title:"Reviewers can no longer open this link"},"Enable again",8,TL)],64)):f("v-if",!0)]),r?.status=="error"&&r?.statusMessage?(a(),l("div",{key:0,class:"status-sub status-sub-error",textContent:c(e.fmt?.statusMsg(r?.statusMessage)),title:r?.statusMessage},null,8,OL)):f("v-if",!0),r?._stale?(a(),l("div",{key:1,class:"status-sub status-sub-warn",title:"Last activity "+e.fmt?.humanTime(r?.anonymizeDate||r?.lastView)},c(e.idleText(r)),9,IL)):f("v-if",!0),r.status==="error"&&r._editUrl?(a(),l("a",{key:2,class:"project-attention-action",href:e.safeUrl(r._editUrl)},"Fix source",8,ML)):f("v-if",!0),r._stale||r._broken?(a(),l("div",VL,[r._stale&&!r._broken?(a(),l("span",qL,[...t[67]||(t[67]=[g("May be stuck",-1),n("span",{"aria-hidden":"true"}," \xB7 ",-1)])])):f("v-if",!0),r._stale||r._broken?(a(),l("button",{key:1,type:"button",class:"project-attention-action",onClick:ae(p=>e.showProjectDetails(r),["stop"]),"data-project-actions":r._broken?encodeURIComponent(r._type+":"+r._id):null,"aria-controls":r._broken?e.projectDetailsId(r):null,"aria-expanded":r._broken?e.selectedProject===r:null},c(r._broken?"Review details":"Check progress"),9,_L)):f("v-if",!0)])):f("v-if",!0),r?.status=="expired"?(a(),l("button",{key:4,type:"button",class:"project-attention-action",onClick:ae(p=>e.extendItem(r),["stop"]),title:"Reviewers can no longer open this link"},"Extend 6 months",8,LL)):f("v-if",!0),r?.status=="removed"&&r?.anonymizeDate?(a(),l("div",$L,"anonymized "+c(e.fmt?.humanTime(r?.anonymizeDate)),1)):f("v-if",!0),r?.status!="error"&&r?.status!="expired"&&r?.status!="removed"&&!r?._stale&&r?.anonymizeDate?(a(),l("div",FL," anonymized "+c(e.fmt?.humanTime(r?.anonymizeDate)),1)):f("v-if",!0)]),n("div",{class:"cell-views num",role:"cell","data-unit":r.pageView===1?"view":"views","aria-label":e.fmt.number(r.pageView)+(r.pageView===1?" view":" views")},[t[68]||(t[68]=n("svg",{class:"project-type-svg mobile-meta-icon","aria-hidden":"true"},[n("use",{href:"#project-icon-eye"})],-1)),n("span",null,c(e.fmt.number(r.pageView)),1)],8,UL),n("div",BL,[t[72]||(t[72]=n("svg",{class:"project-type-svg mobile-meta-icon","aria-hidden":"true"},[n("use",{href:"#project-icon-clock"})],-1)),r?._expiry?.kind==="never"?(a(),l("span",zL,"No expiry")):f("v-if",!0),r?._expiry?.kind==="date"&&!r?._expiry?.soon?(a(),l("span",{key:1,textContent:c((e.fmt?.humanTime(r?._expiry?.date)||"").replace(/^on /,""))},null,8,HL)):f("v-if",!0),r?._expiry?.kind==="date"&&r?._expiry?.soon?(a(),l("span",{key:2,class:"expires-soon",title:"Expires "+e.fmt?.humanTime(r?._expiry?.date)},[t[69]||(t[69]=n("svg",{class:"project-type-svg expires-soon-icon","aria-hidden":"true"},[n("use",{href:"#project-icon-clock"})],-1)),t[70]||(t[70]=n("span",{class:"expires-soon-prefix"},"Expires ",-1)),g(c(r._expiry.soon),1)],8,jL)):f("v-if",!0),r?._expiry?.kind==="expired"&&r?._expiry?.date?(a(),l("span",GL,[t[71]||(t[71]=n("span",{class:"expires-past-prefix"},"Expired ",-1)),g(c(r?._expiry?.label||e.fmt?.humanTime(r?._expiry?.date)),1)])):f("v-if",!0),r?._expiry?.kind==="expired"&&!r?._expiry?.date?(a(),l("span",WL,"Expired")):f("v-if",!0),r?._expiry?.kind==="none"?(a(),l("span",KL,"\u2014")):f("v-if",!0)])]),n("div",YL,[r._viewUrl&&!(r?._statusKey=="expired"||r?._statusKey=="removed")?(a(),l("button",{key:0,type:"button",class:"copy-url",onClick:ae(p=>e.copyLink(r),["stop"]),disabled:!!e.copyingId,title:"Copy link: "+r._viewUrl,"aria-label":"Copy anonymous link for "+r._label},[n("span",JL,c(e.copyingId===r._type+":"+r._id?"Link copied":""),1),(a(),l("svg",QL,[n("use",{href:e.copyingId===r._type+":"+r._id?"#ui-icon-check":"#project-icon-copy"},null,8,ZL)])),n("span",xL,c(e.copyingId===r._type+":"+r._id?"Copied":"Copy link"),1)],8,XL)):f("v-if",!0),r._viewUrl&&!(r?._statusKey=="expired"||r?._statusKey=="removed")?(a(),l("a",{key:1,class:"row-edit row-open",href:e.safeUrl(r._viewUrl),target:"_blank",rel:"noopener",title:"Open what reviewers see","aria-label":"Open anonymous page for "+r._label},[...t[73]||(t[73]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-external-link"})],-1)])],8,e$)):f("v-if",!0),r?._editUrl&&!r?._broken&&r?._statusKey!="removed"?(a(),l("a",{key:2,class:"row-edit",href:e.safeUrl(r._editUrl),title:"Edit "+r._name,"aria-label":"Edit "+r._name},[...t[74]||(t[74]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-edit"})],-1)])],8,t$)):f("v-if",!0),!(r._viewUrl&&!(r?._statusKey=="expired"||r?._statusKey=="removed"))&&r?._statusKey!="removed"&&r?._statusKey!="expired"?(a(),l("button",{key:3,type:"button",class:"copy-url is-disabled","aria-disabled":"true",onClick:t[20]||(t[20]=ae(()=>{},["stop"])),title:r?._statusKey=="expired"?"Link expired: reviewers can no longer open it":r?._statusKey=="removed"?"Link offline: reviewers can no longer open it":"No link: this record is incomplete","aria-label":"Copy link unavailable for "+r._label},[...t[75]||(t[75]=[n("svg",{class:"project-type-svg","aria-hidden":"true"},[n("use",{href:"#project-icon-copy"})],-1),n("span",{class:"copy-url-label","aria-hidden":"true"},"Copy link",-1)])],8,n$)):f("v-if",!0),!(r._viewUrl&&!(r?._statusKey=="expired"||r?._statusKey=="removed"))&&r?._statusKey!="removed"&&r?._statusKey!="expired"?(a(),l("button",{key:4,type:"button",class:"row-edit row-open is-disabled","aria-disabled":"true",onClick:t[21]||(t[21]=ae(()=>{},["stop"])),title:r?._statusKey=="expired"?"Link expired: reviewers can no longer open it":r?._statusKey=="removed"?"Link offline: reviewers can no longer open it":"No link: this record is incomplete","aria-label":"Open unavailable for "+r._label},[...t[76]||(t[76]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-external-link"})],-1)])],8,s$)):f("v-if",!0),r?._editUrl&&!r?._broken?f("v-if",!0):(a(),l("button",{key:5,type:"button",class:"row-edit is-disabled","aria-disabled":"true",onClick:t[22]||(t[22]=ae(()=>{},["stop"])),title:"Can't edit: this record is incomplete","aria-label":"Edit unavailable for "+r._label},[...t[77]||(t[77]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-edit"})],-1)])],8,o$)),r?._broken?(a(),l("div",i$,[n("button",{type:"button",class:"btn btn-icon-dots is-disabled","aria-disabled":"true",onClick:t[23]||(t[23]=ae(()=>{},["stop"])),title:"No actions: this record is incomplete. Use Review details.","aria-label":"No actions available for "+r._label},[...t[78]||(t[78]=[n("svg",{class:"project-type-svg","aria-hidden":"true"},[n("use",{href:"#project-icon-more"})],-1)])],8,r$)])):f("v-if",!0),r?._broken?f("v-if",!0):(a(),l("div",a$,[n("button",{class:"btn btn-icon-dots",type:"button","data-toggle":"dropdown","aria-haspopup":"true","aria-expanded":"false","data-project-actions":encodeURIComponent(r._type+":"+r._id),"aria-label":"Actions for "+r?._name},[...t[79]||(t[79]=[n("svg",{class:"project-type-svg","aria-hidden":"true"},[n("use",{href:"#project-icon-more"})],-1)])],8,l$),n("div",d$,[n("button",{type:"button",class:"dropdown-item",onClick:p=>e.showProjectDetails(r),"aria-controls":e.projectDetailsId(r),"aria-expanded":e.selectedProject===r},"Project details & name",8,u$),n("a",{class:"dropdown-item",href:e.safeUrl(r?._viewUrl)}," View ",8,c$),r?._type==="repo"&&r?.options?.page&&r?.status=="ready"?(a(),l("a",{key:0,class:"dropdown-item",target:"_self",href:e.safeUrl("/w/"+r?.repoId+"/")}," View page ",8,p$)):f("v-if",!0),r?._viewUrl?(a(),l("button",{key:1,type:"button",class:"dropdown-item",onClick:p=>e.copyLink(r),disabled:!!e.copyingId}," Copy anonymous link ",8,f$)):f("v-if",!0),n("a",{class:"dropdown-item",href:e.safeUrl(r?._editUrl)}," Edit ",8,m$),r?.status=="ready"||r?.status=="error"?(a(),l("button",{key:2,type:"button",class:"dropdown-item",onClick:p=>e.refreshItem(r)}," Force update ",8,h$)):f("v-if",!0),r?.status=="removed"?(a(),l("button",{key:3,type:"button",class:"dropdown-item",onClick:p=>e.refreshItem(r)}," Enable ",8,g$)):f("v-if",!0),r?.status=="expired"?(a(),l("button",{key:4,type:"button",class:"dropdown-item",onClick:p=>e.extendItem(r)}," Extend 6 months ",8,v$)):f("v-if",!0),(r?.status=="ready"||r?.status=="expired"||r?.status=="error")&&r?.role!=="coauthor"?(a(),l("div",y$,[t[80]||(t[80]=n("div",{class:"dropdown-divider"},null,-1)),n("button",{type:"button",class:"dropdown-item dropdown-item-danger",onClick:p=>e.removeItem(r)}," Remove ",8,b$)])):f("v-if",!0)])]))])],10,iL)),!e.loading&&e.selectedProject===r?(a(),l("div",w$,[n("div",{class:"project-details",role:"cell","aria-colspan":"5",id:e.projectDetailsId(r),tabindex:"-1",onKeydown:kt(ae(p=>e.closeProjectDetails(r),["stop"]),["esc"])},[n("div",C$,[t[82]||(t[82]=n("h2",null,"Project details",-1)),n("button",{type:"button",class:"project-close",onClick:p=>e.closeProjectDetails(r),"aria-label":"Close project details"},[...t[81]||(t[81]=[n("svg",{class:"project-type-svg","aria-hidden":"true"},[n("use",{href:"#project-icon-close"})],-1)])],8,E$)]),n("dl",S$,[n("div",null,[t[83]||(t[83]=n("dt",null,"Source",-1)),n("dd",null,c(r._source||"Not available"),1)]),n("div",null,[t[84]||(t[84]=n("dt",null,"Anonymous ID",-1)),n("dd",null,[n("code",null,c(r._id||"Missing identifier"),1)])]),r.source?.commit?(a(),l("div",N$,[t[85]||(t[85]=n("dt",null,"Commit",-1)),n("dd",null,[n("code",null,c(r.source.commit),1)])])):f("v-if",!0),r.conference?(a(),l("div",R$,[t[86]||(t[86]=n("dt",null,"Conference",-1)),n("dd",null,c(r.conference),1)])):f("v-if",!0),n("div",null,[t[87]||(t[87]=n("dt",null,"Status",-1)),n("dd",null,[g(c(e.fmt.statusLabel(r.status)),1),r.statusMessage?(a(),l("span",P$," \xB7 "+c(e.fmt.statusMsg(r.statusMessage)),1)):f("v-if",!0)])]),r.anonymizeDate?(a(),l("div",D$,[t[88]||(t[88]=n("dt",null,"Last anonymized",-1)),n("dd",null,c(e.fmt.humanTime(r.anonymizeDate)),1)])):f("v-if",!0)]),r._stale?(a(),l("p",A$,"This download has not progressed recently. Check the source access and selected branch before retrying.")):f("v-if",!0),r._editUrl?(a(),l("a",{key:1,class:"project-attention-action",href:e.safeUrl(r._editUrl)},c(e.needsAttention(r)?"Check source settings":"Edit anonymization settings"),9,T$)):f("v-if",!0),r._id?(a(),l("form",{key:2,class:"project-name-form",onSubmit:ae(p=>e.saveProjectName(r),["prevent"])},[n("label",{for:"project-name-"+r._type+"-"+r._id},"Project name",8,I$),n("p",{id:"project-name-help-"+r._type+"-"+r._id},"Only you see this name. Leave it blank to use the default.",8,M$),n("div",V$,[T(n("input",{class:"form-control",type:"text",id:"project-name-"+r._type+"-"+r._id,"aria-describedby":"project-name-help-"+r._type+"-"+r._id,maxlength:"100","onUpdate:modelValue":t[24]||(t[24]=p=>e.projectName=p),disabled:e.nameSaving},null,8,q$),[[rt,e.projectName]]),n("button",{class:"btn btn-ink",type:"submit",disabled:e.nameSaving},c(e.nameSaving?"Saving\u2026":"Save name"),9,_$)]),e.nameError?(a(),l("p",L$,c(e.nameError),1)):f("v-if",!0),e.nameMessage?(a(),l("p",$$,c(e.nameMessage),1)):f("v-if",!0)],40,O$)):f("v-if",!0)],40,k$)])):f("v-if",!0)],64))),128)),!e.loading&&e.filteredItems?.length==0?(a(),l("div",F$,[t[90]||(t[90]=n("svg",{class:"project-type-svg project-empty-icon","aria-hidden":"true"},[n("use",{href:"#project-icon-inbox"})],-1)),e.hasProjects()?f("v-if",!0):(a(),l("span",U$,"You have no anonymizations yet.")),e.hasProjects()?(a(),l("span",B$,"Nothing matches the current filters.")):f("v-if",!0),n("div",z$,[e.hasActiveFilters()?(a(),l("button",{key:0,type:"button",class:"btn btn-outline-ink",onClick:t[25]||(t[25]=r=>e.clearFilters())},"Clear filters")):f("v-if",!0),e.hasProjects()?f("v-if",!0):(a(),l("a",H$,[...t[89]||(t[89]=[n("svg",{class:"project-type-svg","aria-hidden":"true"},[n("use",{href:"#project-icon-plus"})],-1),g(" New anonymization",-1)])]))])])):f("v-if",!0)],10,Z_)]),e.dashboardCursor||e.dashboardError?(a(),l("div",j$,[e.dashboardError?(a(),l("p",G$,c(e.dashboardError),1)):f("v-if",!0),e.dashboardCursor?(a(),l("button",{key:1,type:"button",class:"btn",onClick:t[26]||(t[26]=r=>e.loadMoreProjects()),disabled:e.loadingMore},c(e.loadingMore?"Loading\u2026":"Load more projects"),9,W$)):f("v-if",!0)])):f("v-if",!0)])}var K$={class:"viewer-bar"},Y$={class:"vb-left"},X$=["aria-label","title"],J$=["href","title"],Q$={class:"vb-artifact-id"},Z$={class:"vb-right"},x$=["title"],eF={class:"vb-help"},tF=["aria-expanded"],nF={key:0,class:"acct-menu vb-help-menu",role:"menu"},sF=["aria-label","title"],oF={class:"ui-icon","aria-hidden":"true"},iF=["href"],rF={key:1,class:"acct"},aF=["aria-label","aria-expanded"],lF=["src"],dF={key:1,class:"acct-initial"},uF={key:0,class:"acct-menu",role:"menu"},cF={class:"acct-menu-head"},pF={key:2,class:"vb-signin",href:"/signin",target:"_self"},fF={key:0,class:"vb-context"},mF=["href","title"],hF={key:0,class:"vb-context-date"},gF=["aria-label"],vF={class:"ui-icon","aria-hidden":"true"},yF=["href"],bF=["textContent"],wF={class:"leftCol-head"},kF={class:"leftCol-search"},CF={class:"tree-search-box"},EF=["href"],SF={type:"text",class:"tree-search-input",placeholder:"Search files","aria-label":"Search files"},NF=["title","href"],RF={class:"leftCol-body"},PF={key:0,class:"paper-inline-warning",role:"alert"},DF={key:1,class:"paper-inline-warning",role:"alert"},AF={class:"explorer-main"},TF={class:"breadcrumb paths","aria-label":"Path"},OF={class:"breadcrumb-item breadcrumb-root"},IF=["href","title","textContent"],MF=["aria-current","textContent"],VF=["aria-label","title"],qF={class:"ui-icon","aria-hidden":"true"},_F=["href"],LF={class:"status-bar-actions"},$F=["href"],FF={class:"d-none d-md-inline"},UF={class:"ui-icon","aria-hidden":"true"},BF=["href"],zF={class:"d-none d-md-inline"},HF=["href"],jF={class:"explorer-content"};function fp(e,t){let s=Xe("tree"),i=Xe("partial-view"),o=De("field");return a(),l("div",{class:P(["explorer-page",{"files-hidden":e.sidebarHidden}]),style:Te({"--sidebar-w":e.sidebarWidth+"px"})},[n("header",K$,[n("div",Y$,[t[15]||(t[15]=n("a",{class:"vb-logo",href:"/"},[g("Anonymous "),n("em",null,"GitHub")],-1)),n("button",{type:"button",class:"vb-icon vb-sidebar","aria-label":e.sidebarHidden?"Show file tree":"Hide file tree",title:e.sidebarHidden?"Show file tree":"Hide file tree",onClick:t[0]||(t[0]=r=>e.sidebarHidden=!e.sidebarHidden)},[...t[13]||(t[13]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-sidebar"})],-1)])],8,X$),e.repoId?(a(),l("a",{key:0,class:"vb-artifact",href:e.safeUrl("/r/"+e.repoId+"/"),title:"Anonymous artifact "+e.repoId},[t[14]||(t[14]=n("span",{class:"sr-only"},"Artifact ",-1)),n("span",Q$,c(e.repoId),1)],8,J$)):f("v-if",!0)]),n("div",Z$,[e.options?.sourceCommitDate||e.options?.anonymizedAt||e.options?.lastUpdateDate?(a(),l("span",{key:0,class:"vb-snapshot",title:(e.options?.expirationDate?"Available until "+e.fmt?.date(e.options.expirationDate)+". ":"")+(e.options?.anonymizedAt&&!e.options?.publishedAt?"Older repositories have no recorded publication date. The source commit date does not establish when files became available here.":(e.options?.sourceCommitDate?"Source commit ":e.options?.anonymizedAt?"Anonymized ":"Updated ")+e.fmt?.date(e.options?.sourceCommitDate||e.options?.anonymizedAt||e.options?.lastUpdateDate)+(e.options?.publishedAt?" \xB7 snapshot ready "+e.fmt?.date(e.options.publishedAt):""))},[t[16]||(t[16]=n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#project-icon-clock"})],-1)),t[17]||(t[17]=n("span",null,"Snapshot",-1)),n("span",null,c(e.fmt?.date(e.options?.publishedAt||e.options?.sourceCommitDate||e.options?.anonymizedAt||e.options?.lastUpdateDate)),1)],8,x$)):f("v-if",!0),t[25]||(t[25]=n("a",{class:"vb-support",href:"https://ko-fi.com/tdurieux",target:"_blank",rel:"noopener",title:"Support Anonymous GitHub \u2014 help keep it free for researchers"},[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-heart"})]),n("span",null,"Support")],-1)),n("div",eF,[n("button",{type:"button",class:"vb-help-btn","aria-haspopup":"true","aria-expanded":e.helpOpen?"true":"false",onClick:t[1]||(t[1]=ae(r=>e.helpOpen=!e.helpOpen,["stop"]))},[...t[18]||(t[18]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-help"})],-1),n("span",null,"Help",-1)])],8,tF),e.helpOpen?(a(),l("div",nF,[...t[19]||(t[19]=[n("a",{role:"menuitem",href:"/faq"},[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-help"})]),n("span",null,[g("FAQ"),n("small",null,"How anonymization works")])],-1),n("a",{role:"menuitem",href:"https://github.com/tdurieux/anonymous_github/issues/new?template=issue_report.yml",target:"_blank",rel:"noopener"},[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-bug"})]),n("span",null,[g("Report a bug"),n("small",null,"About this service, not the paper")])],-1)])])):f("v-if",!0)]),n("button",{type:"button",class:"vb-icon","aria-label":e.isDarkMode?"Switch to light mode":"Switch to dark mode",title:e.isDarkMode?"Light mode":"Dark mode",onClick:t[2]||(t[2]=r=>e.darkMode(!e.isDarkMode))},[(a(),l("svg",oF,[n("use",{href:e.isDarkMode?"#ui-icon-sun":"#ui-icon-moon"},null,8,iF)]))],8,sF),e.user?(a(),l("div",rF,[n("button",{type:"button",class:"acct-chip","aria-haspopup":"true","aria-label":"Account: "+e.user?.username,"aria-expanded":e.accountOpen?"true":"false",onClick:t[3]||(t[3]=ae(r=>e.accountOpen=!e.accountOpen,["stop"]))},[e.user?.photo?(a(),l("img",{key:0,src:e.safeUrl(e.user.photo),alt:"",width:"26",height:"26"},null,8,lF)):(a(),l("span",dF,c((e.user?.username||"?").charAt(0).toUpperCase()),1))],8,aF),e.accountOpen?(a(),l("div",uF,[n("div",cF,[t[20]||(t[20]=g("Signed in as ",-1)),n("b",null,"@"+c(e.user?.username),1)]),t[21]||(t[21]=n("a",{role:"menuitem",href:"/dashboard"},[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-grid"})]),g("My work")],-1)),t[22]||(t[22]=n("a",{role:"menuitem",href:"/profile"},[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-user"})]),g("Settings")],-1)),t[23]||(t[23]=n("a",{role:"menuitem",href:"/api/user/logout",target:"_self"},[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-logout"})]),g("Sign out")],-1))])):f("v-if",!0)])):(a(),l("a",pF,[...t[24]||(t[24]=[n("i",{class:"fab fa-github","aria-hidden":"true"},null,-1),g("Sign in",-1)])]))])]),e.repoId?(a(),l("div",fF,[n("a",{class:"vb-context-id",href:e.safeUrl("/r/"+e.repoId+"/"),title:"Anonymous artifact "+e.repoId},c(e.repoId),9,mF),e.options?.publishedAt||e.options?.sourceCommitDate||e.options?.anonymizedAt||e.options?.lastUpdateDate?(a(),l("span",hF,"Snapshot "+c(e.fmt?.date(e.options?.publishedAt||e.options?.sourceCommitDate||e.options?.anonymizedAt||e.options?.lastUpdateDate)),1)):f("v-if",!0)])):f("v-if",!0),T(n("button",{class:"sidebar-toggle",onClick:t[4]||(t[4]=r=>e.sidebarCollapsed=!e.sidebarCollapsed),"aria-label":e.sidebarCollapsed?"Show files":"Hide files"},[(a(),l("svg",vF,[n("use",{href:e.sidebarCollapsed?"#ui-icon-folder":"#project-icon-close"},null,8,yF)])),n("span",{textContent:c(e.sidebarCollapsed?"Files":"Close")},null,8,bF)],8,gF),[[Z,e.files?.length]]),T(n("div",{class:P(["leftCol",{collapsed:e.sidebarCollapsed}])},[n("div",wF,[t[27]||(t[27]=n("span",{class:"leftCol-eyebrow"},"Files",-1)),n("button",{class:"leftCol-close","aria-label":"Close files",onClick:t[5]||(t[5]=r=>e.sidebarCollapsed=!0)},[...t[26]||(t[26]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#project-icon-close"})],-1)])])]),n("div",kF,[n("div",CF,[(a(),l("svg",{class:P(["ui-icon tree-search-icon",{"fa-spin":e.fileSearchLoading}]),"aria-hidden":"true"},[n("use",{href:e.fileSearchLoading?"#ui-icon-spinner":"#ui-icon-search"},null,8,EF)],2)),T(n("input",SF,null,512),[[o,{state:e.viewState,set:r=>{e.fileSearchQuery=r},value:e.fileSearchQuery,form:null,options:{debounce:300},change:()=>{e.onFileSearchChange()}}]]),T(n("kbd",{class:"tree-search-kbd"},c(e.isMac?"\u2318":"Ctrl+")+"K",513),[[Z,!e.fileSearchQuery]]),T(n("button",{class:"tree-search-clear","aria-label":"Clear search",onClick:t[6]||(t[6]=r=>{e.fileSearchQuery="",e.onFileSearchChange()})},"\xD7",512),[[Z,e.fileSearchQuery]])]),e.options?.download?(a(),l("a",{key:0,target:"_self",class:"search-zip","aria-label":"Download repository as ZIP",title:"Download the repository (snapshot "+e.fmt?.date(e.options?.sourceCommitDate||e.options?.anonymizedAt||e.options?.lastUpdateDate)+") as ZIP",href:e.safeUrl("/api/repo/"+e.repoId+"/zip")},[...t[28]||(t[28]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-download"})],-1),n("span",{class:"search-zip-label","aria-hidden":"true"},"ZIP",-1)])],8,NF)):f("v-if",!0)]),n("div",RF,[e.options?.truncatedFolders?.length>0?(a(),l("div",PF,[t[29]||(t[29]=n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-warning"})],-1)),g(" "+c(e.fmt?.translate("WARNINGS.repo_truncated")),1)])):f("v-if",!0),e.options?.hasSubmodules?(a(),l("div",DF,[t[30]||(t[30]=n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-warning"})],-1)),g(" "+c(e.fmt?.translate("WARNINGS.submodules_not_included")),1)])):f("v-if",!0),Ie(s,{class:"files",file:e.files,"search-query":e.fileSearchQuery,"search-results":e.fileSearchResults,page:e.viewState},null,8,["file","search-query","search-results","page"])])],2),[[Z,e.files?.length]]),T(n("div",{class:"leftCol-resizer",role:"separator","aria-orientation":"vertical","aria-label":"Resize file tree",title:"Drag to resize",onPointerdown:t[7]||(t[7]=r=>e.startSidebarResize(r))},null,544),[[Z,e.files?.length&&!e.sidebarHidden]]),T(n("div",{class:"leftCol-backdrop",onClick:t[8]||(t[8]=r=>e.sidebarCollapsed=!0)},null,512),[[Z,e.files?.length&&!e.sidebarCollapsed]]),n("div",AF,[T(n("div",{class:P(["status-bar",{"is-redundant":["code","text","html"].includes(e.type)&&e.content!=null||e.fileFrame()}])},[T(n("button",{type:"button",class:"btn btn-sm status-files-btn","aria-label":"Show files",title:"Show files",onClick:t[9]||(t[9]=r=>e.sidebarHidden?e.sidebarHidden=!1:e.sidebarCollapsed=!1)},[...t[31]||(t[31]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-folder"})],-1),n("span",null,"Files",-1)])],512),[[Z,e.files?.length]]),n("ol",TF,[n("li",OF,[n("a",{href:e.safeUrl("/r/"+e.repoId+"/"),title:e.repoId,textContent:c(/^[0-9a-f]{8}-[0-9a-f]{4}-/i.test(e.repoId||"")?"repository":e.repoId)},null,8,IF)]),(a(!0),l(q,null,Q(e.paths,(r,d)=>(a(),l("li",{class:"breadcrumb-item","aria-current":d===e.paths.length-1?"page":null,textContent:c(r)},null,8,MF))),256))]),T(n("button",{type:"button",class:"btn btn-sm btn-icon-only btn-ghost copy-path-btn","aria-label":e.pathCopied?"Path copied":"Copy path",title:e.pathCopied?"Path copied":"Copy path",onClick:t[10]||(t[10]=r=>e.copyPath())},[(a(),l("svg",qF,[n("use",{href:e.pathCopied?"#ui-icon-check":"#project-icon-copy"},null,8,_F)]))],8,VF),[[Z,e.filePath]]),n("div",LF,[e.options?.isAdmin||e.options?.isOwner?(a(),l("a",{key:0,class:"btn btn-sm","aria-label":"Edit",href:e.safeUrl("/anonymize/"+e.repoId)},[...t[32]||(t[32]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-edit"})],-1),n("span",{class:"d-none d-md-inline"}," Edit",-1)])],8,$F)):f("v-if",!0),e.type=="html-doc"&&!e.showSource?(a(),l("button",{key:1,class:P(["btn btn-sm",{"btn-active":e.allowScripts}]),"aria-label":"Allow this document to run JavaScript",title:"Scripts in this file are blocked by default. Enable them only if you trust the repository \u2014 the document stays isolated from your session either way.",onClick:t[11]||(t[11]=r=>e.toggleAllowScripts())},[t[33]||(t[33]=n("i",{class:"fab fa-js"},null,-1)),n("span",FF,c(e.allowScripts?"JS on":"JS off"),1)],2)):f("v-if",!0),e.type=="html-doc"?(a(),l("button",{key:2,class:"btn btn-sm","aria-label":"Toggle between the rendered document and its source",title:"Toggle between the rendered document and its source",onClick:t[12]||(t[12]=r=>e.toggleSource())},[(a(),l("svg",UF,[n("use",{href:e.showSource?"#project-icon-eye":"#ui-icon-code"},null,8,BF)])),n("span",zF,c(e.showSource?"Rendered":"Source"),1)])):f("v-if",!0),e.options?.hasWebsite?(a(),l("a",{key:3,target:"_self",class:"btn btn-sm","aria-label":"Website",href:e.safeUrl("/w/"+e.repoId+"/")},[...t[34]||(t[34]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-globe"})],-1),n("span",{class:"d-none d-md-inline"}," Website",-1)])],8,HF)):f("v-if",!0)])],2),[[Z,e.type!="error"||e.files?.length]]),n("div",jF,[Ie(i,{name:"partials/pageView.htm",state:e.viewState},null,8,["state"])])])],6)}var GF={class:"paper-faq"},WF={class:"paper-faq-body"},KF={class:"paper-faq-toc"},YF={class:"faq-search",role:"search"},XF={class:"faq-search-field"},JF={id:"faq-search-status",class:"faq-search-status","aria-live":"polite"},QF={key:0,class:"faq-search-empty"},ZF={class:"faq-search-empty-actions"};function mp(e,t){let s=Xe("partial-view"),i=De("paper-scrollspy");return a(),l(q,null,[n("div",GF,[t[12]||(t[12]=n("div",{class:"paper-faq-hero"},[n("div",{class:"paper-faq-eyebrow"},"Help"),n("h1",{class:"paper-faq-title"},[g("Mirrors, redaction, and "),n("em",null,"what reviewers see.")]),n("p",{class:"paper-faq-lede"}," How to set up an anonymous mirror, what it hides, and how long it stays online. ")],-1)),n("div",WF,[T((a(),l("aside",KF,[...t[5]||(t[5]=[Ce('
Contents
',2)])])),[[i]]),n("section",{class:P(["faq-section",{"faq-searching":!!e.faqQuery.trim()}]),"aria-label":"FAQs"},[n("div",YF,[t[7]||(t[7]=n("label",{for:"faq-search-input"},"Search questions",-1)),n("div",XF,[t[6]||(t[6]=n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-search"})],-1)),T(n("input",{id:"faq-search-input",type:"search",class:"form-control","onUpdate:modelValue":t[0]||(t[0]=o=>e.faqQuery=o),onInput:t[1]||(t[1]=o=>e.filterFaq()),onSearch:t[2]||(t[2]=o=>e.filterFaq()),onKeydown:t[3]||(t[3]=kt(o=>e.clearFaqSearch(),["esc"])),placeholder:"e.g. expiry, pull request, PDF",autocomplete:"off",spellcheck:"false","aria-describedby":"faq-search-status"},null,544),[[rt,e.faqQuery]])]),n("p",JF,[e.faqQuery.trim()&&e.faqResults?(a(),l(q,{key:0},[g(c(e.faqResults===1?"1 result":e.faqResults+" results"),1)],64)):f("v-if",!0)])]),e.faqQuery.trim()&&e.faqResults===0?(a(),l("div",QF,[n("strong",null,"No questions match \u201C"+c(e.faqQuery.trim())+"\u201D.",1),t[9]||(t[9]=n("p",null,"Try a shorter word, or ask us directly.",-1)),n("div",ZF,[n("button",{type:"button",class:"btn btn-outline-ink btn-sm",onClick:t[4]||(t[4]=o=>e.clearFaqSearch())},"Clear search"),t[8]||(t[8]=n("a",{class:"btn btn-link btn-sm",target:"_blank",rel:"noopener",href:"https://github.com/tdurieux/anonymous_github/issues/new?template=issue_report.yml"},"Open an issue",-1))])])):f("v-if",!0),t[10]||(t[10]=n("div",{class:"faq-list"},[f(" General "),n("h4",{class:"faq-cat"},[n("svg",{class:"ui-icon mr-2","aria-hidden":"true"},[n("use",{href:"#ui-icon-info"})]),g("General ")]),n("div",{class:"panel-group",id:"faq-general",role:"tablist","aria-multiselectable":"true"},[n("div",{class:"panel panel-default mb-3"},[n("div",{class:"panel-heading p-3",role:"tab",id:"headingWhatIs"},[n("h3",{class:"panel-title"},[n("a",{role:"button","data-toggle":"collapse","data-parent":"#faq-general",href:"#whatIs","aria-expanded":"true","aria-controls":"whatIs"}," What is Anonymous GitHub? ")])]),n("div",{id:"whatIs",class:"panel-collapse collapse show",role:"tabpanel","aria-labelledby":"headingWhatIs"},[n("div",{class:"panel-body p-3"},[n("p",null," Anonymous GitHub is an open-source tool with free hosting and optional paid plans that anonymizes GitHub repositories and pull requests for double-anonymous (double-blind) peer review. It replaces identifying information, such as the repository owner, organization name, and custom terms, so that reviewers cannot determine the identity of the authors through the code repository. ")])])]),n("div",{class:"panel panel-default mb-3"},[n("div",{class:"panel-heading p-3",role:"tab",id:"headingHowWork"},[n("h3",{class:"panel-title"},[n("a",{class:"collapsed",role:"button","data-toggle":"collapse","data-parent":"#faq-general",href:"#howWork","aria-expanded":"false","aria-controls":"howWork"}," How does Anonymous GitHub work? ")])]),n("div",{id:"howWork",class:"panel-collapse collapse",role:"tabpanel","aria-labelledby":"headingHowWork"},[n("div",{class:"panel-body p-3"},[n("p",null," Anonymous GitHub either downloads the complete repository and anonymizes the content, or proxies requests to GitHub on the fly. In both cases, the original and anonymized versions of files are cached on the server. The system automatically detects and replaces the repository owner, organization name, and repository name. You can also specify additional custom terms to anonymize using one-per-line regex patterns. ")])])]),n("div",{class:"panel panel-default mb-3"},[n("div",{class:"panel-heading p-3",role:"tab",id:"headingScope"},[n("h3",{class:"panel-title"},[n("a",{class:"collapsed",role:"button","data-toggle":"collapse","data-parent":"#faq-general",href:"#scope","aria-expanded":"false","aria-controls":"scope"}," What is the scope of anonymization? ")])]),n("div",{id:"scope",class:"panel-collapse collapse",role:"tabpanel","aria-labelledby":"headingScope"},[n("div",{class:"panel-body p-3"},[n("p",null," In double-anonymous peer review, the boundary of anonymization is the paper plus its online appendix, not the entire internet. Searching for any part of the paper or the online appendix can be considered a deliberate attempt to break anonymity. Anonymous GitHub anonymizes the repository owner, organization, repository name, file and directory names, and file contents across all text-based file types. ")])])]),n("div",{class:"panel panel-default mb-3"},[n("div",{class:"panel-heading p-3",role:"tab",id:"headingCost"},[n("h3",{class:"panel-title"},[n("a",{class:"collapsed",role:"button","data-toggle":"collapse","data-parent":"#faq-general",href:"#cost","aria-expanded":"false","aria-controls":"cost"}," How much does it cost? ")])]),n("div",{id:"cost",class:"panel-collapse collapse",role:"tabpanel","aria-labelledby":"headingCost"},[n("div",{class:"panel-body p-3"},[n("p",null," A free account includes 5 owned repositories and 2 GiB of source files. Optional paid plans offer more capacity, automatic refresh, and, with an author subscription, never-expiring repositories. Reviewers can read shared repositories without an account or payment. "),n("p",null,[g(" See "),n("a",{href:"/profile#settings-billing"},"Plans and billing"),g(" for available plans and current prices. Offers depend on whether payments are enabled on this instance; the checkout shows the amount before you pay. Subscriptions help fund hosting, storage, backups, and continued maintenance. ")]),n("p",null,[g(" You can also support development through "),n("a",{href:"https://github.com/sponsors/tdurieux/",target:"_blank",rel:"noopener"},"GitHub Sponsors"),g(" or "),n("a",{href:"https://ko-fi.com/tdurieux",target:"_blank",rel:"noopener"},"Ko-fi"),g(". Donations are separate from subscriptions and do not automatically unlock paid features. ")])])])])]),f(" Plans and billing "),n("h4",{class:"faq-cat",id:"faq-plans-title"},"Plans and billing"),n("div",{class:"panel-group",id:"faq-plans",role:"tablist","aria-label":"Plans and billing","aria-multiselectable":"true"},[n("div",{class:"panel panel-default mb-3"},[n("div",{class:"panel-heading p-3",role:"tab",id:"headingWhyPaid"},[n("h3",{class:"panel-title"},[n("a",{class:"collapsed",role:"button","data-toggle":"collapse","data-parent":"#faq-plans",href:"#whyPaid","aria-expanded":"false","aria-controls":"whyPaid"},"Why is Anonymous GitHub no longer completely free?")])]),n("div",{id:"whyPaid",class:"panel-collapse collapse",role:"tabpanel","aria-labelledby":"headingWhyPaid"},[n("div",{class:"panel-body p-3"},[n("p",null,"Anonymous GitHub started as a small free service and was paid for out of pocket. Three things have changed since then:"),n("ul",null,[n("li",null,[n("strong",null,"Servers cost much more."),g(" Every hosted repository needs storage, bandwidth and backups, and these costs have risen sharply.")]),n("li",null,[n("strong",null,"Many more people use it."),g(" More users means more repositories to store and keep up to date, more support requests and more maintenance.")]),n("li",null,[n("strong",null,"AI has made security work heavier."),g(" AI-driven scrapers and automated abuse send far more traffic than before. Blocking them and keeping hosted content safe takes constant work.")])]),n("p",null,"The core service stays free: anonymizing a repository, sharing the link and reviewer access cost nothing, and reviewers never need an account. Most authors never need to pay. The paid options are small one-time payments for one repository, plus an optional subscription for heavy users. They are priced to cover running costs, not to make a profit."),n("p",null,[g("The source code remains open, so you can still "),n("a",{href:"#faq-hosting"},"host your own instance"),g(" for free.")])])])]),n("div",{class:"panel panel-default mb-3"},[n("div",{class:"panel-heading p-3",role:"tab",id:"headingFreePlan"},[n("h3",{class:"panel-title"},[n("a",{class:"collapsed",role:"button","data-toggle":"collapse","data-parent":"#faq-plans",href:"#freePlan","aria-expanded":"false","aria-controls":"freePlan"},"What is included in a free account?")])]),n("div",{id:"freePlan",class:"panel-collapse collapse",role:"tabpanel","aria-labelledby":"headingFreePlan"},[n("div",{class:"panel-body p-3"},[n("p",null,"The default free allowance is 5 repositories you own and 2 GiB of source files in total. Core anonymization and reviewer access remain free. You can manually refresh a repository within your allowance and choose a dated expiration up to 5 months ahead, then extend it again before it expires. Repositories submitted to a conference can stay online until the end of its review window."),n("p",null,"Repositories shared with you as a co-author do not use your own slots. Gists and pull requests are not included in these repository quotas. The usage shown in your account is the allowance available on this instance.")])])]),n("div",{class:"panel panel-default mb-3"},[n("div",{class:"panel-heading p-3",role:"tab",id:"headingAuthorPlans"},[n("h3",{class:"panel-title"},[n("a",{class:"collapsed",role:"button","data-toggle":"collapse","data-parent":"#faq-plans",href:"#authorPlans","aria-expanded":"false","aria-controls":"authorPlans"},"What do monthly and annual author subscriptions include?")])]),n("div",{id:"authorPlans",class:"panel-collapse collapse",role:"tabpanel","aria-labelledby":"headingAuthorPlans"},[n("div",{class:"panel-body p-3"},[n("p",null,[g("Both include 20 owned repositories and 10 GiB of source files in total. They also allow automatic refresh when enabled in repository settings and let the owner choose "),n("strong",null,"Never expire"),g(".")]),n("p",null,[g("Monthly and annual plans offer the same features with different billing periods. They renew automatically until you cancel renewal. Current prices are shown in "),n("a",{href:"/profile#settings-billing"},"Plans and billing"),g(".")]),n("p",null,"Paid plans do not change how anonymization works. File-size limits and other service safeguards still apply. Review your anonymized content before sharing it.")])])]),n("div",{class:"panel panel-default mb-3"},[n("div",{class:"panel-heading p-3",role:"tab",id:"headingReviewPass"},[n("h3",{class:"panel-title"},[n("a",{class:"collapsed",role:"button","data-toggle":"collapse","data-parent":"#faq-plans",href:"#reviewPass","aria-expanded":"false","aria-controls":"reviewPass"},"Can I pay for one repository without subscribing?")])]),n("div",{id:"reviewPass",class:"panel-collapse collapse",role:"tabpanel","aria-labelledby":"headingReviewPass"},[n("div",{class:"panel-body p-3"},[n("p",null,"Yes. These one-time add-ons apply to a single repository you own. None of them renews automatically:"),n("ul",null,[n("li",null,[n("strong",null,"Paper pack"),g(": an extra repository, automatic updates for 180 days and one more year before it expires, in a single payment. It covers what one paper usually needs during review.")]),n("li",null,[n("strong",null,"Extra repository"),g(": host one more repository once your free repositories are used up. It has its own 2 GiB allowance and does not count toward your free repositories. It lasts as long as the repository exists.")]),n("li",null,[n("strong",null,"Live updates"),g(": automatic refresh for 180 days, with a separate 2 GiB allowance.")]),n("li",null,[n("strong",null,"Extended expiration"),g(": choose an expiration date up to one year after purchase. Buying it again adds another year.")]),n("li",null,[n("strong",null,"Never expire"),g(": the repository has no expiration date. A full refund or a payment dispute ends it after a 90-day grace period.")])]),n("p",null,[g("When your free allowance is full, the Extra repository and Paper pack options are offered as you create the repository. You can also buy an add-on from the repository's edit page, or enter the anonymized ID of an existing repository in "),n("a",{href:"/profile#settings-billing"},"Plans and billing"),g(". Current prices are shown there.")])])])]),n("div",{class:"panel panel-default mb-3"},[n("div",{class:"panel-heading p-3",role:"tab",id:"headingConferencePlans"},[n("h3",{class:"panel-title"},[n("a",{class:"collapsed",role:"button","data-toggle":"collapse","data-parent":"#faq-plans",href:"#conferencePlans","aria-expanded":"false","aria-controls":"conferencePlans"},"Can a conference or lab pay for a group?")])]),n("div",{id:"conferencePlans",class:"panel-collapse collapse",role:"tabpanel","aria-labelledby":"headingConferencePlans"},[n("div",{class:"panel-body p-3"},[n("p",null,"A conference review package provides a shared allowance for a review window of up to 180 days, with automatic updates for every submission. It comes in three sizes: Workshop (25 repositories, 10 GiB), Conference (100 repositories, 50 GiB) and Large conference (400 repositories, 200 GiB). Choose the size when you create the conference; it cannot change afterwards. The organizer pays once and authors pay nothing (the price is shown when you create the conference); the package does not renew automatically. A lab organizing a review can use this shared package too."),n("p",null,"New conferences no longer have a free plan: every new conference is a review package. Conferences created earlier keep working as before. The conference must be activated by payment before authors can submit under its Conference ID. Eligible repositories use the conference allowance before an author's personal allowance, so authors do not each need a subscription for that capacity."),n("p",null,"The package has a fixed review window. Never expire still requires the repository owner's author subscription or a Never expire add-on for that repository.")])])]),n("div",{class:"panel panel-default mb-3"},[n("div",{class:"panel-heading p-3",role:"tab",id:"headingPaidCoauthors"},[n("h3",{class:"panel-title"},[n("a",{class:"collapsed",role:"button","data-toggle":"collapse","data-parent":"#faq-plans",href:"#paidCoauthors","aria-expanded":"false","aria-controls":"paidCoauthors"},"Does every co-author need to pay?")])]),n("div",{id:"paidCoauthors",class:"panel-collapse collapse",role:"tabpanel","aria-labelledby":"headingPaidCoauthors"},[n("div",{class:"panel-body p-3"},[n("p",null,"No. Co-authors can collaborate without buying a subscription. A shared repository uses its owner's allowance, unless a repository pass or paid conference covers it. It does not consume each co-author's personal allowance."),n("p",null,"A co-author's subscription does not increase the owner's allowance. If the owner's available capacity is exhausted, a co-author's refresh or edit may also be blocked. Reviewers never need a paid account.")])])]),n("div",{class:"panel panel-default mb-3"},[n("div",{class:"panel-heading p-3",role:"tab",id:"headingCapacity"},[n("h3",{class:"panel-title"},[n("a",{class:"collapsed",role:"button","data-toggle":"collapse","data-parent":"#faq-plans",href:"#capacity","aria-expanded":"false","aria-controls":"capacity"},"What counts toward my allowance, and what happens at the limit?")])]),n("div",{id:"capacity",class:"panel-collapse collapse",role:"tabpanel","aria-labelledby":"headingCapacity"},[n("div",{class:"panel-body p-3"},[n("p",null,"The repository limit counts work you own. Storage counts the source-file sizes reserved for those repositories, not just files a reviewer opens. Archived or failed repositories can still reserve capacity, and a refresh does not automatically reduce a previous storage reservation."),n("p",null,"At the repository limit you cannot add another repository to that allowance. An edit or refresh must also fit the available storage. Remove work you no longer need, add an Extra repository for the new one, choose a subscription, or use an eligible conference allowance."),n("p",null,"Removing a repository releases its reservation when capacity is next checked. Expired repositories may continue to reserve capacity until cleanup. Reaching a limit does not itself delete existing review links.")])])]),n("div",{class:"panel panel-default mb-3"},[n("div",{class:"panel-heading p-3",role:"tab",id:"headingNeverExpire"},[n("h3",{class:"panel-title"},[n("a",{class:"collapsed",role:"button","data-toggle":"collapse","data-parent":"#faq-plans",href:"#neverExpire","aria-expanded":"false","aria-controls":"neverExpire"},"What happens to Never expire repositories if I stop subscribing?")])]),n("div",{id:"neverExpire",class:"panel-collapse collapse",role:"tabpanel","aria-labelledby":"headingNeverExpire"},[n("div",{class:"panel-body p-3"},[n("p",null,[g("Never expire is available to monthly and annual author subscribers, or for one repository with the one-time Never expire add-on. If a subscription ends, these repositories remain available for a "),n("strong",null,"90-day grace period"),g(", then expire and their hosted content is removed.")]),n("p",null,"Renewing during the grace period keeps them active. After expiration, you must renew and explicitly reactivate the repository; restoring content also requires access to its GitHub source. A repository does not become public on GitHub when it expires."),n("p",null,"Existing never-expiring repositories created before this billing policy retain their settings. Never expire is not a guarantee of perpetual service availability.")])])]),n("div",{class:"panel panel-default mb-3"},[n("div",{class:"panel-heading p-3",role:"tab",id:"headingCancelPlan"},[n("h3",{class:"panel-title"},[n("a",{class:"collapsed",role:"button","data-toggle":"collapse","data-parent":"#faq-plans",href:"#cancelPlan","aria-expanded":"false","aria-controls":"cancelPlan"},"How do I cancel, and what happens after paid access ends?")])]),n("div",{id:"cancelPlan",class:"panel-collapse collapse",role:"tabpanel","aria-labelledby":"headingCancelPlan"},[n("div",{class:"panel-body p-3"},[n("p",null,[g("Open "),n("a",{href:"/profile#settings-billing"},"Plans and billing"),g(" and choose "),n("strong",null,"Manage billing and invoices"),g(" to manage renewal. Cancelling renewal keeps subscription benefits until the end of the paid period.")]),n("p",null,"After paid access ends, repositories fall back to another eligible allowance or the free allowance. Automatic refresh pauses on the free allowance; manual refresh remains available within its limits. Existing review links keep their configured expiration dates, except paid Never expire repositories, which follow the 90-day grace period described above."),n("p",null,"A repository pass or conference package ends after its paid window without automatic renewal.")])])]),n("div",{class:"panel panel-default mb-3"},[n("div",{class:"panel-heading p-3",role:"tab",id:"headingRefunds"},[n("h3",{class:"panel-title"},[n("a",{class:"collapsed",role:"button","data-toggle":"collapse","data-parent":"#faq-plans",href:"#refunds","aria-expanded":"false","aria-controls":"refunds"},"Can I get a refund?")])]),n("div",{id:"refunds",class:"panel-collapse collapse",role:"tabpanel","aria-labelledby":"headingRefunds"},[n("div",{class:"panel-body p-3"},[n("p",null,[g("Refunds are handled case by case. "),n("a",{href:"mailto:tdurieux@anonymous.4open.science"},"Email the maintainer"),g(" with the date of the payment and the repository it was for.")]),n("p",null,"A full refund ends what that payment bought. For a Paper pack, this means all three parts: the extra repository, automatic updates and the extended expiration. A Never expire repository then expires after a 90-day grace period. A partial refund keeps your access."),n("p",null,"To stop a subscription, cancel its renewal instead of asking for a refund. You keep access until the end of the period you paid for.")])])]),n("div",{class:"panel panel-default mb-3"},[n("div",{class:"panel-heading p-3",role:"tab",id:"headingPaymentHandling"},[n("h3",{class:"panel-title"},[n("a",{class:"collapsed",role:"button","data-toggle":"collapse","data-parent":"#faq-plans",href:"#paymentHandling","aria-expanded":"false","aria-controls":"paymentHandling"},"How are payments handled?")])]),n("div",{id:"paymentHandling",class:"panel-collapse collapse",role:"tabpanel","aria-labelledby":"headingPaymentHandling"},[n("div",{class:"panel-body p-3"},[n("p",null,[g("Stripe processes checkout and billing management. Anonymous GitHub does not store your card details. You can access billing management and invoices from "),n("a",{href:"/profile#settings-billing"},"Plans and billing"),g(".")]),n("p",null,[g("Paid access is activated after payment is confirmed. If checkout succeeds but your account has not updated, choose "),n("strong",null,"Refresh payment status"),g(" before trying another purchase. If paid plans are unavailable on this instance, no checkout is offered.")])])])])]),f(" Features "),n("h4",{class:"faq-cat"},[n("svg",{class:"ui-icon mr-2","aria-hidden":"true"},[n("use",{href:"#project-icon-filter"})]),g("Features ")]),n("div",{class:"panel-group",id:"faq-features",role:"tablist","aria-multiselectable":"true"},[n("div",{class:"panel panel-default mb-3"},[n("div",{class:"panel-heading p-3",role:"tab",id:"headingFormats"},[n("h3",{class:"panel-title"},[n("a",{class:"collapsed",role:"button","data-toggle":"collapse","data-parent":"#faq-features",href:"#formats","aria-expanded":"false","aria-controls":"formats"}," Which file formats are supported? ")])]),n("div",{id:"formats",class:"panel-collapse collapse",role:"tabpanel","aria-labelledby":"headingFormats"},[n("div",{class:"panel-body p-3"},[n("p",null," Anonymous GitHub can display and render a wide variety of file types: "),n("ul",null,[n("li",null,[n("strong",null,"Text and source code"),g(": displayed with syntax highlighting")]),n("li",null,[n("strong",null,"Markdown"),g(": rendered as formatted HTML")]),n("li",null,[n("strong",null,"Images"),g(" (PNG, JPG, SVG, etc.): displayed inline")]),n("li",null,[n("strong",null,"PDFs"),g(": rendered directly in the browser")]),n("li",null,[n("strong",null,"Jupyter Notebooks"),g(": rendered with code cells and outputs")])]),n("p",null," Only text-based files are anonymized. Anonymous GitHub analyzes the content of each file to determine whether it is textual or binary. ")])])]),n("div",{class:"panel panel-default mb-3"},[n("div",{class:"panel-heading p-3",role:"tab",id:"headingPR"},[n("h3",{class:"panel-title"},[n("a",{class:"collapsed",role:"button","data-toggle":"collapse","data-parent":"#faq-features",href:"#pullRequests","aria-expanded":"false","aria-controls":"pullRequests"}," Can I anonymize pull requests? ")])]),n("div",{id:"pullRequests",class:"panel-collapse collapse",role:"tabpanel","aria-labelledby":"headingPR"},[n("div",{class:"panel-body p-3"},[n("p",null," Yes. In addition to full repositories, Anonymous GitHub supports anonymizing individual pull requests. Simply paste the URL of a GitHub pull request when creating a new anonymized repository, and the system will automatically detect that it is a pull request and anonymize it accordingly. ")])])]),n("div",{class:"panel panel-default mb-3"},[n("div",{class:"panel-heading p-3",role:"tab",id:"headingConference"},[n("h3",{class:"panel-title"},[n("a",{class:"collapsed",role:"button","data-toggle":"collapse","data-parent":"#faq-features",href:"#conference","aria-expanded":"false","aria-controls":"conference"}," What is the Conference ID feature? ")])]),n("div",{id:"conference",class:"panel-collapse collapse",role:"tabpanel","aria-labelledby":"headingConference"},[n("div",{class:"panel-body p-3"},[n("p",null," When creating an anonymized repository, you can associate it with a Conference ID. This allows conferences to define default anonymization settings (such as expiration dates) that are automatically applied to repositories submitted under that conference. If your conference provides a Conference ID, enter it during the anonymization setup. ")])])]),n("div",{class:"panel panel-default mb-3"},[n("div",{class:"panel-heading p-3",role:"tab",id:"headingExpiration"},[n("h3",{class:"panel-title"},[n("a",{class:"collapsed",role:"button","data-toggle":"collapse","data-parent":"#faq-features",href:"#expiration","aria-expanded":"false","aria-controls":"expiration"}," What happens when an anonymized repository expires? ")])]),n("div",{id:"expiration",class:"panel-collapse collapse",role:"tabpanel","aria-labelledby":"headingExpiration"},[n("div",{class:"panel-body p-3"},[n("p",null," You can configure one of three expiration strategies when creating your anonymized repository: "),n("ul",null,[n("li",null,[n("strong",null,"Never expire"),g(": with a monthly or annual author subscription, no scheduled expiration while subscribed. A 90-day grace period applies after paid access ends. See "),n("a",{href:"#neverExpire"},"the subscription expiration policy"),g(".")]),n("li",null,[n("strong",null,"Redirect to GitHub"),g(": after expiration, visitors are redirected to the original GitHub repository.")]),n("li",null,[n("strong",null,"Remove content"),g(": after expiration, the anonymized content is deleted from the server.")])])])])]),n("div",{class:"panel panel-default mb-3"},[n("div",{class:"panel-heading p-3",role:"tab",id:"headingDownload"},[n("h3",{class:"panel-title"},[n("a",{class:"collapsed",role:"button","data-toggle":"collapse","data-parent":"#faq-features",href:"#download","aria-expanded":"false","aria-controls":"download"}," Can I download an anonymized repository? ")])]),n("div",{id:"download",class:"panel-collapse collapse",role:"tabpanel","aria-labelledby":"headingDownload"},[n("div",{class:"panel-body p-3"},[n("p",null," Yes. Anonymized repositories can be downloaded as a ZIP file. This is useful if reviewers want to build or test the code locally. The downloaded archive contains the fully anonymized version of the repository. ")])])]),n("div",{class:"panel panel-default mb-3"},[n("div",{class:"panel-heading p-3",role:"tab",id:"headingUpdates"},[n("h3",{class:"panel-title"},[n("a",{class:"collapsed",role:"button","data-toggle":"collapse","data-parent":"#faq-features",href:"#updates","aria-expanded":"false","aria-controls":"updates"}," Are updates to the original repository reflected in the anonymized version? ")])]),n("div",{id:"updates",class:"panel-collapse collapse",role:"tabpanel","aria-labelledby":"headingUpdates"},[n("div",{class:"panel-body p-3"},[n("p",null," You can refresh the anonymized repository from GitHub without creating a new share link. Free accounts can request a manual refresh within their allowance. Automatic refresh requires an eligible paid allowance and must be enabled in repository settings. It pauses when the repository falls back to the free allowance. "),n("p",null," After changing files or contributor names, review your anonymization terms before sharing the updated content. If GitHub access is revoked or the source is deleted, the service cannot fetch updates. ")])])]),n("div",{class:"panel panel-default mb-3"},[n("div",{class:"panel-heading p-3",role:"tab",id:"headingCLI"},[n("h3",{class:"panel-title"},[n("a",{class:"collapsed",role:"button","data-toggle":"collapse","data-parent":"#faq-features",href:"#cli","aria-expanded":"false","aria-controls":"cli"}," Is there a command-line tool? ")])]),n("div",{id:"cli",class:"panel-collapse collapse",role:"tabpanel","aria-labelledby":"headingCLI"},[n("div",{class:"panel-body p-3"},[n("p",null," Yes. Anonymous GitHub provides a CLI tool that lets you anonymize repositories locally, generating an anonymized ZIP file on your machine. Install it via npm: "),n("pre",{style:{"background-color":"var(--hover-bg-color)",padding:"12px","border-radius":"4px","margin-top":"8px",color:"var(--color)"}},[n("code",null,`npm install -g @tdurieux/anonymous_github +anonymous_github`)])])])])]),f(" Limitations "),n("h4",{class:"faq-cat"},[n("svg",{class:"ui-icon mr-2","aria-hidden":"true"},[n("use",{href:"#ui-icon-warning"})]),g("Limitations ")]),n("div",{class:"panel-group",id:"faq-limitations",role:"tablist","aria-multiselectable":"true"},[n("div",{class:"panel panel-default mb-3"},[n("div",{class:"panel-heading p-3",role:"tab",id:"headingLimitation"},[n("h3",{class:"panel-title"},[n("a",{class:"collapsed",role:"button","data-toggle":"collapse","data-parent":"#faq-limitations",href:"#limitation","aria-expanded":"false","aria-controls":"limitation"}," What are the limitations of Anonymous GitHub? ")])]),n("div",{id:"limitation",class:"panel-collapse collapse",role:"tabpanel","aria-labelledby":"headingLimitation"},[n("div",{class:"panel-body p-3"},[n("ul",null,[n("li",null," Anonymous GitHub only anonymizes text-based files. Binary files (compiled executables, archives, etc.) are served as-is without anonymization. "),n("li",null," Files larger than 8 MB are not supported. "),n("li",null," Static site generators (such as Jekyll) used with GitHub Pages are not fully supported, although Markdown files are converted to HTML. "),n("li",null," The anonymization of terms within source code may change the behavior of the program (e.g., if a replaced term appears in a string literal or identifier). ")])])])])]),f(" Privacy and security "),n("h4",{class:"faq-cat"},[n("svg",{class:"ui-icon mr-2","aria-hidden":"true"},[n("use",{href:"#ui-icon-shield"})]),g("Privacy and security ")]),n("div",{class:"panel-group",id:"faq-privacy",role:"tablist","aria-multiselectable":"true"},[n("div",{class:"panel panel-default mb-3"},[n("div",{class:"panel-heading p-3",role:"tab",id:"headingData"},[n("h3",{class:"panel-title"},[n("a",{class:"collapsed",role:"button","data-toggle":"collapse","data-parent":"#faq-privacy",href:"#data","aria-expanded":"false","aria-controls":"data"}," How is my data handled? ")])]),n("div",{id:"data",class:"panel-collapse collapse",role:"tabpanel","aria-labelledby":"headingData"},[n("div",{class:"panel-body p-3"},[n("p",null," Repository data is used to provide the anonymization service. If you purchase a plan, Stripe processes payment and billing information. When a repository is removed or expires, only its configuration is retained. This makes it easy to restore the repository if needed and ensures that no future repository reuses the same ID. ")])])]),n("div",{class:"panel panel-default mb-3"},[n("div",{class:"panel-heading p-3",role:"tab",id:"headingPermissions"},[n("h3",{class:"panel-title"},[n("a",{class:"collapsed",role:"button","data-toggle":"collapse","data-parent":"#faq-privacy",href:"#permissions","aria-expanded":"false","aria-controls":"permissions"}," Why does GitHub say Anonymous GitHub asks for write access? ")])]),n("div",{id:"permissions",class:"panel-collapse collapse",role:"tabpanel","aria-labelledby":"headingPermissions"},[n("div",{class:"panel-body p-3"},[n("p",null,[g("The GitHub App has read-only access to the repositories you choose. You can change repository access on your "),n("a",{href:"/connections"},"GitHub connections"),g(" page.")]),n("p",null,"Legacy GitHub OAuth includes write access to private repositories because GitHub's OAuth scopes do not offer a read-only option for them. Existing OAuth anonymizations and gists can still use this connection."),n("p",null,"Anonymous GitHub reads repository content. It never pushes, modifies, or deletes files on GitHub.")])])]),n("div",{class:"panel panel-default mb-3"},[n("div",{class:"panel-heading p-3",role:"tab",id:"headingViewer"},[n("h3",{class:"panel-title"},[n("a",{class:"collapsed",role:"button","data-toggle":"collapse","data-parent":"#faq-privacy",href:"#viewer","aria-expanded":"false","aria-controls":"viewer"}," Can repository owners see who viewed their anonymized repository? ")])]),n("div",{id:"viewer",class:"panel-collapse collapse",role:"tabpanel","aria-labelledby":"headingViewer"},[n("div",{class:"panel-body p-3"},[n("p",null," No. Only the total number of views is tracked as an incremental counter. It is not possible for the repository owner or for Anonymous GitHub to identify individual viewers. Reviewer anonymity is fully preserved. ")])])])]),f(" Self-hosting "),n("h4",{class:"faq-cat"},[n("svg",{class:"ui-icon mr-2","aria-hidden":"true"},[n("use",{href:"#project-icon-storage"})]),g("Self"),n("span",{class:"serif-hy"},"-"),g("hosting ")]),n("div",{class:"panel-group",id:"faq-hosting",role:"tablist","aria-multiselectable":"true"},[n("div",{class:"panel panel-default mb-3"},[n("div",{class:"panel-heading p-3",role:"tab",id:"headingDeploy"},[n("h3",{class:"panel-title"},[n("a",{class:"collapsed",role:"button","data-toggle":"collapse","data-parent":"#faq-hosting",href:"#deploy","aria-expanded":"false","aria-controls":"deploy"}," Can I deploy my own instance? ")])]),n("div",{id:"deploy",class:"panel-collapse collapse",role:"tabpanel","aria-labelledby":"headingDeploy"},[n("div",{class:"panel-body p-3"},[n("p",null,[g(" Yes. Anonymous GitHub is fully open source (GPL-3.0) and supports Docker-based deployment. Billing is optional and disabled by default for self-hosted instances; paid hosted plans are not required to run your own server. You will need to configure a GitHub OAuth app and provide a GitHub token. Detailed setup instructions are available on the "),n("a",{href:"https://github.com/tdurieux/anonymous_github/",target:"_blank"},"GitHub repository"),g(". ")]),n("p",null," The basic steps are: "),n("ol",null,[n("li",null,"Clone the repository and install dependencies"),n("li",null,[g("Create a "),n("code",null,".env"),g(" file with your GitHub token, OAuth client ID, and client secret")]),n("li",null,[g("Run "),n("code",null,"docker-compose up -d")])])])])])])],-1))],2),t[11]||(t[11]=n("aside",{class:"paper-faq-help","aria-label":"More help"},[n("div",{class:"paper-faq-help-card"},[n("strong",null,"Still stuck?"),n("p",null,"Open an issue on GitHub about the service. For a paper's content, contact the conference instead."),n("a",{class:"btn btn-outline-ink btn-sm",target:"_blank",rel:"noopener",href:"https://github.com/tdurieux/anonymous_github/issues/new?template=issue_report.yml"},"Open an issue")])],-1))])]),Ie(s,{name:"partials/footer.htm",state:e.viewState},null,8,["state"])],64)}var xF={class:"pr-page"},eU={class:"container paper-page pr-page-inner"},tU={class:"pr-header"},nU={class:"pr-title-row"},sU={class:"paper-page-title pr-title"},oU=["textContent"],iU={key:1,class:"text-muted"},rU=["href"],aU={class:"pr-header-meta"},lU={key:0,class:"pr-meta-item"},dU=["textContent"],uU={key:1,class:"pr-meta-item"},cU=["textContent"],pU={key:2,class:"pr-meta-item"},fU=["textContent"],mU={key:0,class:"paper-tabs",role:"tablist"},hU=["aria-selected","tabindex"],gU=["textContent"],vU=["aria-selected","tabindex"],yU=["textContent"],bU={class:"paper-tab-content"},wU={key:0,role:"tabpanel",id:"gist-files-panel","aria-labelledby":"gist-files-tab"},kU={class:"pr-comments"},CU={class:"pr-comment"},EU={class:"pr-comment-head"},SU=["textContent"],NU={key:0,class:"pr-comment-date"},RU={key:0,class:"paper-table-empty"},PU={key:1,role:"tabpanel",id:"gist-comments-panel","aria-labelledby":"gist-comments-tab"},DU={class:"pr-comments"},AU={class:"pr-comment"},TU={class:"pr-comment-head"},OU={key:0,class:"pr-comment-author"},IU=["textContent"],MU=["textContent"],VU={key:0,class:"pr-comment-body"},qU={key:0,class:"paper-table-empty"};function hp(e,t){let s=Xe("gist-file"),i=Xe("markdown");return a(),l("div",xF,[n("div",eU,[t[17]||(t[17]=n("div",{class:"paper-crumbs"},[n("a",{href:"/dashboard"},"Reviewer"),g(" \xA0/\xA0 "),n("span",{class:"here"},"Gist")],-1)),n("header",tU,[n("div",nU,[n("h1",sU,[e.details?.description?(a(),l("span",{key:0,textContent:c(e.details?.description)},null,8,oU)):f("v-if",!0),e.details?.description?f("v-if",!0):(a(),l("span",iU,"Untitled gist"))]),e.options?.isAdmin||e.options?.isOwner?(a(),l("a",{key:0,class:"btn btn-sm","aria-label":"Edit",href:e.safeUrl("/gist-anonymize/"+e.gistId)},[...t[4]||(t[4]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-edit"})],-1),n("span",{class:"d-none d-md-inline"}," Edit",-1)])],8,rU)):f("v-if",!0)]),n("div",aU,[n("span",{class:P(["paper-pill",{good:e.details?.isPublic,warn:!e.details?.isPublic}])},c(e.details?.isPublic?"Public":"Secret"),3),e.details?.ownerLogin?(a(),l("span",lU,[t[5]||(t[5]=n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-user"})],-1)),t[6]||(t[6]=g(" @",-1)),n("span",{textContent:c(e.details?.ownerLogin)},null,8,dU)])):f("v-if",!0),e.details?.updatedDate?(a(),l("span",uU,[t[7]||(t[7]=n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#project-icon-clock"})],-1)),t[8]||(t[8]=g()),n("span",{textContent:c(e.fmt?.date(e.details?.updatedDate))},null,8,cU)])):f("v-if",!0),e.details?.anonymizeDate?(a(),l("span",pU,[t[9]||(t[9]=n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-shield"})],-1)),t[10]||(t[10]=g(" Anonymized ",-1)),n("span",{textContent:c(e.fmt?.date(e.details?.anonymizeDate))},null,8,fU)])):f("v-if",!0)])]),e.details?.files&&e.details?.files?.length||e.details?.comments&&e.details?.comments?.length?(a(),l("nav",mU,[e.details?.files?(a(),l("button",{key:0,class:P(["paper-tab",{active:e.tabState?.active=="files"}]),type:"button",role:"tab",id:"gist-files-tab","aria-selected":e.tabState?.active==="files","aria-controls":"gist-files-panel",tabindex:e.tabState?.active==="files"?0:-1,onKeydown:t[0]||(t[0]=o=>e.previewTabKeydown(o)),onClick:t[1]||(t[1]=o=>e.tabState.active="files")},[t[11]||(t[11]=n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#project-type-gist"})],-1)),n("span",{textContent:c(e.fmt.plural(e.details?.files?.length,{0:"No files",one:"1 file",other:"{} files"}))},null,8,gU)],42,hU)):f("v-if",!0),e.details?.comments?(a(),l("button",{key:1,class:P(["paper-tab",{active:e.tabState?.active=="comments"}]),type:"button",role:"tab",id:"gist-comments-tab","aria-selected":e.tabState?.active==="comments","aria-controls":"gist-comments-panel",tabindex:e.tabState?.active==="comments"?0:-1,onKeydown:t[2]||(t[2]=o=>e.previewTabKeydown(o)),onClick:t[3]||(t[3]=o=>e.tabState.active="comments")},[t[12]||(t[12]=n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-comment"})],-1)),n("span",{textContent:c(e.fmt.plural(e.details?.comments?.length,{0:"No comments",one:"1 comment",other:"{} comments"}))},null,8,yU)],42,vU)):f("v-if",!0)])):f("v-if",!0),n("div",bU,[e.details?.files&&e.tabState?.active=="files"?(a(),l("div",wU,[n("ul",kU,[(a(!0),l(q,null,Q(e.details?.files,(o,r)=>(a(),l("li",CU,[n("div",EU,[n("strong",{textContent:c(o?.filename)},null,8,SU),o?.language?(a(),l("span",NU,c(o?.language),1)):f("v-if",!0)]),Ie(s,{file:o},null,8,["file"])]))),256)),e.details?.files?.length?f("v-if",!0):(a(),l("li",RU,[...t[13]||(t[13]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#project-icon-file"})],-1),n("span",null,"No files in this gist.",-1)])]))])])):f("v-if",!0),e.details?.comments&&e.tabState?.active=="comments"?(a(),l("div",PU,[n("ul",DU,[(a(!0),l(q,null,Q(e.details?.comments,(o,r)=>(a(),l("li",AU,[n("div",TU,[o?.author?(a(),l("span",OU,[t[14]||(t[14]=n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-user"})],-1)),t[15]||(t[15]=g(" @",-1)),n("span",{textContent:c(o?.author)},null,8,IU)])):f("v-if",!0),o?.updatedDate?(a(),l("span",{key:1,class:"pr-comment-date",textContent:c(e.fmt?.date(o?.updatedDate))},null,8,MU)):f("v-if",!0)]),o?.body?(a(),l("div",VU,[Ie(i,{content:o?.body},null,8,["content"])])):f("v-if",!0)]))),256)),e.details?.comments?.length?f("v-if",!0):(a(),l("li",qU,[...t[16]||(t[16]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-comment"})],-1),n("span",null,"No comments on this gist.",-1)])]))])])):f("v-if",!0)])])])}var _U={key:0,class:"nav-support",href:"https://ko-fi.com/tdurieux",target:"_blank",rel:"noopener",title:"Donate on Ko-fi to help cover hosting costs","aria-label":"Donate on Ko-fi to help cover hosting costs"},LU={key:1,class:"nav-heart-m",href:"https://ko-fi.com/tdurieux",target:"_blank",rel:"noopener","aria-label":"Support Anonymous GitHub",title:"Support Anonymous GitHub"},$U=["aria-label","title"],FU={class:"ui-icon","aria-hidden":"true"},UU=["href"],BU={key:3,class:"nav-signin-m",href:"/signin",target:"_self","aria-label":"Sign in with GitHub"},zU={class:"collapse navbar-collapse",id:"navbarSupportedContent"},HU={class:"navbar-nav mr-auto smooth-scroll"},jU={key:0,class:"nav-item nav-home-item"},GU={key:1,class:"nav-item"},WU={key:2,class:"nav-item"},KU={key:3,class:"nav-item"},YU={class:"nav-item"},XU={key:4,class:"nav-item"},JU={class:"navbar-nav"},QU={key:0,class:"nav-item d-lg-none"},ZU={key:1,class:"nav-item"},xU={key:2,class:"nav-item"},e7={key:3,class:"nav-item nav-signin-item"},t7={key:4,class:"nav-item"},n7={key:5,class:"nav-item dropdown user-chip-wrap"},s7={class:"nav-link user-chip dropdown-toggle",href:"#",id:"navbarDropdownMenuLink",role:"button","data-toggle":"dropdown","aria-haspopup":"true","aria-expanded":"false"},o7=["src"],i7={class:"user-chip-name"},r7={class:"dropdown-menu dropdown-menu-right user-menu","aria-labelledby":"navbarDropdownMenuLink"},a7={class:"dropdown-header"},l7={key:0,class:"dropdown-item um-extra",href:"https://ko-fi.com/tdurieux",target:"_blank",rel:"noopener"},d7=["innerHTML"],u7=["disabled"],c7={key:0,class:"paper-inline-alert paper-inline-alert-error",role:"alert"},p7={class:"email-prompt-actions"},f7=["disabled"],m7=["disabled"],h7=["disabled"];function gp(e,t){return a(),l(q,null,[n("nav",{class:P(["navbar navbar-expand-lg",{"navbar-dark":e.isDarkMode}])},[t[28]||(t[28]=n("a",{class:"navbar-brand",href:"/"},[g("Anonymous "),n("em",null,"GitHub")],-1)),e.headerShowSupport?(a(),l("a",_U,[...t[9]||(t[9]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-heart"})],-1),n("span",{class:"nav-support-label"},"Support",-1)])])):f("v-if",!0),/^\/(r|w|pr|gist)\//.test(e.path||"")?f("v-if",!0):(a(),l("a",LU,[...t[10]||(t[10]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-heart"})],-1)])])),/^\/(r|w|pr|gist)\//.test(e.path||"")?f("v-if",!0):(a(),l("button",{key:2,type:"button",class:"nav-theme-m","aria-label":e.isDarkMode?"Switch to light mode":"Switch to dark mode",title:e.isDarkMode?"Switch to light mode":"Switch to dark mode",onClick:t[0]||(t[0]=s=>e.darkMode(!e.isDarkMode))},[(a(),l("svg",FU,[n("use",{href:e.isDarkMode?"#ui-icon-sun":"#ui-icon-moon"},null,8,UU)]))],8,$U)),!e.user&&!/^\/(r|w|pr|gist)\//.test(e.path||"")?(a(),l("a",BU,[...t[11]||(t[11]=[n("i",{class:"fab fa-github","aria-hidden":"true"},null,-1),g("Sign in",-1)])])):f("v-if",!0),t[29]||(t[29]=n("button",{class:"navbar-toggler",type:"button","data-toggle":"collapse","data-target":"#navbarSupportedContent","aria-controls":"navbarSupportedContent","aria-expanded":"false","aria-label":"Toggle navigation"},[n("span",{class:"navbar-toggler-icon"})],-1)),n("div",zU,[n("ul",HU,[e.user?f("v-if",!0):(a(),l("li",jU,[n("a",{class:P(["nav-link",{active:e.path=="/"}]),href:"/"},[...t[12]||(t[12]=[n("svg",{class:"ui-icon d-lg-none mr-1","aria-hidden":"true"},[n("use",{href:"#ui-icon-home"})],-1),g(" Home ",-1)])],2)])),e.user?(a(),l("li",GU,[n("a",{class:P(["nav-link",{active:e.path=="/dashboard"}]),href:"/dashboard"},[...t[13]||(t[13]=[n("svg",{class:"ui-icon d-lg-none mr-1","aria-hidden":"true"},[n("use",{href:"#ui-icon-grid"})],-1),g(" My work ",-1)])],2)])):f("v-if",!0),e.user?(a(),l("li",WU,[n("a",{class:P(["nav-link",{active:e.path=="/anonymize"||e.path=="/pull-request-anonymize"}]),href:"/anonymize"},[...t[14]||(t[14]=[n("svg",{class:"ui-icon d-lg-none mr-1","aria-hidden":"true"},[n("use",{href:"#ui-icon-shield"})],-1),g(" Anonymize ",-1)])],2)])):f("v-if",!0),e.user?(a(),l("li",KU,[n("a",{class:P(["nav-link",{active:e.path=="/conferences"||e.path?.startsWith("/conference/")}]),href:"/conferences"},[...t[15]||(t[15]=[n("svg",{class:"ui-icon d-lg-none mr-1","aria-hidden":"true"},[n("use",{href:"#project-icon-conference"})],-1),g(" Conferences ",-1)])],2)])):f("v-if",!0),n("li",YU,[n("a",{class:P(["nav-link",{active:e.path=="/faq"}]),href:"/faq"},[...t[16]||(t[16]=[n("svg",{class:"ui-icon d-lg-none mr-1","aria-hidden":"true"},[n("use",{href:"#ui-icon-help"})],-1),g("FAQ",-1)])],2)]),e.user&&e.user?.isAdmin?(a(),l("li",XU,[n("a",{class:P(["nav-link",{active:e.path?.indexOf("/admin")===0}]),href:"/admin/"},[...t[17]||(t[17]=[n("svg",{class:"ui-icon d-lg-none mr-1","aria-hidden":"true"},[n("use",{href:"#ui-icon-user-shield"})],-1),g(" Admin ",-1)])],2)])):f("v-if",!0)]),n("ul",JU,[e.user||!e.isReviewerRoute?(a(),l("li",QU,[...t[18]||(t[18]=[n("a",{class:"nav-link nav-icon",target:"_blank",href:"https://github.com/tdurieux/anonymous_github/",title:"Anonymous GitHub source code","aria-label":"Anonymous GitHub source code on GitHub",rel:"noopener","data-offset":"30"},[n("i",{class:"fab fa-github","aria-hidden":"true"})],-1)])])):f("v-if",!0),f(` "Report a bug" is about this service. Reviewers who land on an anonymized repository often think it is about the paper, so the - label names the service and the tooltip says who to contact. `),n("li",{class:A(["nav-item nav-extra-item d-none d-lg-block",{"in-user-menu":!!e.user?.username}])},[...t[19]||(t[19]=[n("a",{class:"nav-link",target:"_blank",rel:"noopener",href:"https://github.com/tdurieux/anonymous_github/issues/new?template=issue_report.yml",title:"Report a problem with the Anonymous GitHub service. Questions about an anonymized repository or paper go to its authors.","data-offset":"30"},[n("svg",{class:"ui-icon d-lg-none mr-1","aria-hidden":"true"},[n("use",{href:"#ui-icon-bug"})]),g("Report a bug ")],-1)])],2),n("li",{class:A(["nav-item nav-support-item nav-extra-item d-none d-lg-block",{"in-user-menu":!!e.user?.username}])},[...t[20]||(t[20]=[n("a",{class:"nav-link nav-support-inline",href:"https://ko-fi.com/tdurieux",target:"_blank",rel:"noopener",title:"Donate on Ko-fi to help cover hosting costs"},[n("svg",{class:"ui-icon nav-heart","aria-hidden":"true"},[n("use",{href:"#ui-icon-heart"})]),g("Support ")],-1)])],2),e.isDarkMode?f("v-if",!0):(a(),l("li",sU,[n("button",{type:"button",class:"nav-link nav-icon",title:"Switch to dark mode","aria-label":"Switch to dark mode",onClick:t[1]||(t[1]=s=>{e.darkMode(!0)})},[...t[21]||(t[21]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-moon"})],-1)])])])),e.isDarkMode?(a(),l("li",oU,[n("button",{type:"button",class:"nav-link nav-icon",title:"Switch to light mode","aria-label":"Switch to light mode",onClick:t[2]||(t[2]=s=>{e.darkMode(!1)})},[...t[22]||(t[22]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-sun"})],-1)])])])):f("v-if",!0),!e.user&&!e.isReviewerRoute?(a(),l("li",iU,[...t[23]||(t[23]=[n("a",{class:"nav-link btn-signin",target:"_self",href:"/signin","data-offset":"30"},[n("i",{class:"fab fa-github mr-1"}),g(" Sign in ")],-1)])])):f("v-if",!0),e.user?.username&&e.headerCanUpgrade&&!e.headerBillingPending?(a(),l("li",rU,[n("a",{class:"nav-link nav-upgrade",href:"/profile?upgrade=1",onClick:t[3]||(t[3]=ae(s=>e.openHeaderUpgrade(),["prevent"]))},"Upgrade")])):f("v-if",!0),e.user?(a(),l("li",aU,[n("a",lU,[e.user?.photo?(a(),l("img",{key:0,width:"22",height:"22",class:"rounded-circle",src:e.safeUrl(e.user?.photo)},null,8,dU)):f("v-if",!0),n("span",uU,c(e.user?.username),1)]),n("div",cU,[n("h6",pU,"Signed in as @"+c(e.user?.username),1),t[25]||(t[25]=Ce('SettingsDefaults, quotas, accountGitHub connectionsRepository access and OAuthClaim an anonymizationAttach an existing mirror to your accountReport a bugAbout this service, not a paperSource code',6)),e.headerShowSupport?(a(),l("a",fU,[...t[24]||(t[24]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-heart"})],-1),n("span",null,"Support the project",-1)])])):f("v-if",!0),t[26]||(t[26]=n("div",{class:"dropdown-divider"},null,-1)),t[27]||(t[27]=n("a",{class:"dropdown-item",href:"/api/user/logout",target:"_self"},[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-logout"})]),n("span",null,"Sign out")],-1))])])):f("v-if",!0)])])],2),e.generalMessage?(a(),l("div",{key:0,class:"navbar shadow generalMessage",innerHTML:e.sanitize(e.generalMessage)},null,8,hU)):f("v-if",!0),e.emailPromptOpen?(a(),l("dialog",{key:1,id:"email-prompt",class:"email-prompt","aria-labelledby":"email-prompt-title","aria-describedby":"email-prompt-reason",onCancel:t[8]||(t[8]=ae(s=>e.respondToEmailPrompt("later"),["prevent"]))},[n("form",{onSubmit:t[7]||(t[7]=ae(s=>e.respondToEmailPrompt("save"),["prevent"]))},[t[30]||(t[30]=n("h2",{id:"email-prompt-title"},"Stay informed about access problems",-1)),t[31]||(t[31]=n("p",{id:"email-prompt-reason"},"Get email alerts when your GitHub token or repository access fails.",-1)),t[32]||(t[32]=n("label",{for:"email-prompt-address"},"Email address",-1)),D(n("input",{id:"email-prompt-address",class:"form-control",type:"email",autocomplete:"email",maxlength:"254",required:"","onUpdate:modelValue":t[4]||(t[4]=s=>e.emailPromptAddress=s),disabled:e.emailPromptBusy},null,8,mU),[[pt,e.emailPromptAddress]]),e.emailPromptError?(a(),l("p",gU,c(e.emailPromptError),1)):f("v-if",!0),n("div",vU,[n("button",{type:"button",class:"btn btn-outline-ink",disabled:e.emailPromptBusy,onClick:t[5]||(t[5]=s=>e.respondToEmailPrompt("later"))},"Remind me later",8,yU),n("button",{type:"button",class:"btn btn-outline-ink",disabled:e.emailPromptBusy,onClick:t[6]||(t[6]=s=>e.respondToEmailPrompt("never"))},"Never",8,bU),n("button",{type:"submit",class:"btn btn-ink",disabled:e.emailPromptBusy},c(e.emailPromptBusy?"Saving\u2026":"Save"),9,wU)])],32)],32)):f("v-if",!0)],64)}var kU={class:"paper-landing"},CU={class:"paper-hero"},EU={class:"paper-hero-copy"},SU={class:"paper-cta-row"},NU={key:0,href:"/signin",target:"_self",class:"btn-hero"},RU={key:1,href:"/anonymize",class:"btn-hero"},AU={class:"paper-stats-meta"},PU={key:0,class:"paper-stats-meta-left"},DU={key:0,class:"paper-stats-grid"},TU={class:"paper-stat-label"},OU={key:0,class:"paper-stat-delta"},IU={class:"demo paper-wrap","aria-label":"Try redaction"},MU={class:"demo-terms"},VU={class:"demo-panes"},qU={class:"pane"},_U={class:"demo-input-wrap"},LU={class:"pane-body demo-backdrop","aria-hidden":"true"},$U={key:0,class:"demo-match"},FU={class:"pane pane-after"},UU={class:"pane-header"},BU={class:"pane-url"},zU={class:"meta-redact"},HU={class:"pane-body demo-output","aria-live":"polite"},jU=["title"],GU={class:"paper-features paper-wrap","aria-label":"Product features"},WU={class:"paper-features-list",role:"tablist","aria-label":"Features","aria-orientation":"vertical"},KU=["onClick","onKeydown","id","aria-controls","aria-selected","tabindex"],YU={class:"paper-eyebrow"},XU={class:"pf-num"},JU={class:"pf-name"},QU={class:"paper-feature-title"},ZU={key:0,class:"serif-hy"},xU={class:"paper-feature-more"},e7={class:"paper-feature-title paper-feature-title-m","aria-hidden":"true"},t7={key:0,class:"serif-hy"},n7=["href","target"],s7={class:"paper-features-stage"},o7=["id","aria-labelledby"],i7={class:"paper-frame"},r7={class:"paper-frame-bar","aria-hidden":"true"},a7={class:"url"},l7=["aria-label"],d7={key:0,class:"fm-form"},u7={key:1,class:"fm-viewer"},c7={key:2,class:"fm-dash"};function vp(e,t){let s=Xe("partial-view");return a(),l("div",kU,[f(" Hero: copy on the left, the product on the right "),n("section",CU,[n("div",EU,[t[5]||(t[5]=n("div",{class:"paper-eyebrow"},"For double-anonymous peer review",-1)),t[6]||(t[6]=n("h1",{class:"hero-title"},[g(" Share the code,"),n("br"),n("span",{class:"accent"},"not the author.")],-1)),t[7]||(t[7]=n("p",{class:"hero-subtitle"}," Anonymous GitHub makes a read-only mirror of your repository, pull request, or gist. It redacts the terms you choose in text files, so reviewers can browse your artifact through an anonymous link. ",-1)),n("div",SU,[e.user?f("v-if",!0):(a(),l("a",NU,[...t[3]||(t[3]=[n("i",{class:"fab fa-github mr-2","aria-hidden":"true"},null,-1),g("Sign in with GitHub ",-1)])])),e.user?(a(),l("a",RU," Anonymize a repository \u2192 ")):f("v-if",!0),t[4]||(t[4]=n("a",{class:"paper-link-arrow",target:"_self",href:"https://anonymous.4open.science/r/840c8c57-3c32-451e-bf12-0e20be300389/"},"See an anonymized repository \u2192",-1))]),t[8]||(t[8]=n("ul",{class:"paper-reassure"},[n("li",null,"Free, open source"),n("li",null,"Read-only access"),n("li",null,"Set an expiry date")],-1)),t[9]||(t[9]=n("p",{class:"paper-proof-mobile"},"Used by authors at ICSE \xB7 FSE \xB7 OOPSLA",-1))]),t[10]||(t[10]=n("div",{class:"paper-hero-shot"},[n("div",{class:"paper-frame"},[n("div",{class:"paper-frame-bar","aria-hidden":"true"},[n("span",{class:"dots"},[n("i"),n("i"),n("i")]),n("span",{class:"url"},"anonymous.4open.science/r/paper-7f2a")]),n("div",{class:"hero-mock",role:"img","aria-label":"A reviewer browsing an anonymized repository: the author, affiliation, and email in the README are replaced by anonymous terms"},[n("div",{class:"hero-mock-tree","aria-hidden":"true"},[n("div",{class:"hero-mock-tree-title"},"Files"),n("div",{class:"hero-mock-row is-folder"},[n("svg",{viewBox:"0 0 16 16"},[n("path",{d:"M1.5 3.5h4l1.5 1.5h7.5v8h-13z"})]),g("data")]),n("div",{class:"hero-mock-row is-folder"},[n("svg",{viewBox:"0 0 16 16"},[n("path",{d:"M1.5 3.5h4l1.5 1.5h7.5v8h-13z"})]),g("experiments")]),n("div",{class:"hero-mock-row is-folder"},[n("svg",{viewBox:"0 0 16 16"},[n("path",{d:"M1.5 3.5h4l1.5 1.5h7.5v8h-13z"})]),g("src")]),n("div",{class:"hero-mock-row"},[n("svg",{viewBox:"0 0 16 16"},[n("path",{d:"M3.5 1.5h6l3 3v10h-9z"})]),g("LICENSE")]),n("div",{class:"hero-mock-row is-active"},[n("svg",{viewBox:"0 0 16 16"},[n("path",{d:"M3.5 1.5h6l3 3v10h-9z"})]),g("README.md")]),n("div",{class:"hero-mock-row"},[n("svg",{viewBox:"0 0 16 16"},[n("path",{d:"M3.5 1.5h6l3 3v10h-9z"})]),g("requirements.txt")])]),n("div",{class:"hero-mock-doc","aria-hidden":"true"},[n("div",{class:"hero-mock-doc-bar"},[n("strong",null,"README.md"),n("span",{class:"hero-mock-count"},"3 redacted")]),n("div",{class:"hero-mock-doc-body"},[n("div",{class:"hero-mock-h1"},"DeepLearnUtils"),n("p",null,[g("Developed by "),n("span",{class:"redact",role:"img","aria-label":"Redacted term 1"},[n("i",null,"1")]),g(" at "),n("span",{class:"redact",role:"img","aria-label":"Redacted term 2"},[n("i",null,"2")]),g(".")]),n("p",{class:"hm-opt"},"Utilities for reproducing the paper\u2019s experiments."),n("div",{class:"hero-mock-h2 hm-opt"},"Quick start"),n("pre",{class:"hm-opt"},`pip install -r requirements.txt -python experiments/run.py`),n("p",null,[g("Contact: "),n("span",{class:"redact",role:"img","aria-label":"Redacted term 3"},[n("i",null,"3")])])])])])])],-1))]),f(" Live stats "),n("section",{class:A(["paper-stats paper-wrap",{"is-empty":e.statsEmpty()}]),id:"metrics","aria-label":"Usage over the last 60 days"},[n("div",AU,[e.statsEmpty()?f("v-if",!0):(a(),l("div",PU,[...t[11]||(t[11]=[n("span",{class:"paper-stats-dot","aria-hidden":"true"},null,-1),g(),n("span",null,[g("Live \xB7 last 60 days"),n("span",{class:"paper-stats-daily"}," \xB7 updated daily")],-1)])])),t[12]||(t[12]=n("div",{class:"paper-stats-meta-right"},"Used by authors at ICSE \xB7 FSE \xB7 OOPSLA",-1))]),e.statsEmpty()?f("v-if",!0):(a(),l("div",DU,[(a(!0),l(q,null,Q(e.cards,(i,o)=>(a(),l("div",{class:"paper-stat-card",key:i?.key},[n("div",{class:A(["paper-stat-value",{"is-pending":!e.stat}])},c(e.stat?e.fmt?.bigNum(i?.total):"\u2014"),3),n("div",TU,c(i?.label),1),e.history[i?.key].bars?.length>1&&e.history[i?.key].deltaToday>0?(a(),l("div",OU," +"+c(e.fmt?.number(e.history[i?.key].deltaToday))+" today ",1)):f("v-if",!0)]))),128))]))],2),f(" Before / after "),t[22]||(t[22]=n("section",{class:"paper-section-head paper-wrap"},[n("div",null,[n("div",{class:"paper-eyebrow"},"Try it"),n("h2",null,[g("The same repository, "),n("em",null,"minus you.")])]),n("p",null," Names, affiliations, emails, and any term you list are replaced across the README, source files, notebooks, and PDF links. Reviewers browse the real thing, not a zip. ")],-1)),n("div",IU,[n("div",MU,[t[13]||(t[13]=n("label",{for:"demo-terms"},[g("Terms to redact "),n("span",null,[g("comma-separated"),n("span",{class:"dt-try"},", try adding your own")])],-1)),D(n("textarea",{id:"demo-terms",class:"demo-terms-input",rows:"1","onUpdate:modelValue":t[0]||(t[0]=i=>e.demoTerms=i),spellcheck:"false",autocomplete:"off",onKeydown:t[1]||(t[1]=kt(ae(()=>{},["prevent"]),["enter"]))},null,544),[[pt,e.demoTerms]])]),n("div",VU,[n("div",qU,[t[15]||(t[15]=n("div",{class:"pane-header"},[n("span",{class:"pane-label"},[g("Your repository "),n("span",{class:"pane-edit-hint"},"\xB7 editable")]),n("span",{class:"pane-url"},"github.com/jane-smith/DeepLearnUtils")],-1)),n("div",_U,[n("div",LU,[(a(!0),l(q,null,Q(e.demoParts(),(i,o)=>(a(),l(q,{key:o},[i.redacted?(a(),l("mark",$U,c(i.original),1)):(a(),l(q,{key:1},[g(c(i.text),1)],64))],64))),128)),t[14]||(t[14]=g("\u200B",-1))]),D(n("textarea",{class:"pane-body demo-input","onUpdate:modelValue":t[2]||(t[2]=i=>e.demoText=i),spellcheck:"false","aria-label":"Sample README to anonymize"},null,512),[[pt,e.demoText]])])]),n("div",FU,[n("div",UU,[t[16]||(t[16]=n("span",{class:"pane-label"},"What reviewers see",-1)),n("span",BU,[n("span",zU,c(e.demoCount())+" redacted",1)])]),n("div",HU,[(a(!0),l(q,null,Q(e.demoParts(),(i,o)=>(a(),l(q,{key:o},[i.redacted?(a(),l("span",{key:0,class:"redact-chip",title:"Replaces \u201C"+i.original+"\u201D"},c(i.text),9,jU)):(a(),l(q,{key:1},[g(c(i.text),1)],64))],64))),128))])])])]),f(" What you get: one screenshot, three tabs "),t[23]||(t[23]=n("section",{class:"paper-section-head paper-wrap",id:"about"},[n("div",null,[n("div",{class:"paper-eyebrow"},"What you get"),n("h2",null,"Anonymize, review, manage.")]),n("p",null," Terms are redacted in text files. Enabled images and PDFs are served unchanged, so review them for identifying content before sharing. Monitor your mirror, update it, or remove it when the review is over. ")],-1)),n("section",GU,[n("div",WU,[(a(!0),l(q,null,Q(e.features,(i,o)=>(a(),l("div",{class:A(["paper-feature",{"is-on":e.feature===i?.key}]),key:i?.key},[n("button",{type:"button",class:"paper-feature-tab",role:"tab",onClick:r=>e.selectFeature(i.key),onKeydown:r=>e.featureKeydown(r,o),id:"feature-tab-"+i?.key,"aria-controls":"feature-panel-"+i?.key,"aria-selected":e.feature===i?.key,tabindex:e.feature===i?.key?0:-1},[n("span",YU,[n("span",XU,c(i?.num),1),t[17]||(t[17]=n("span",{class:"pf-sep"}," \xB7 ",-1)),n("span",JU,c(i?.eyebrow),1)]),n("span",QU,[g(c(i?.title.split("-")[0]),1),i?.title.includes("-")?(a(),l("span",ZU,"-")):f("v-if",!0),g(c(i?.title.split("-").slice(1).join("-"))+" "+c(i?.accent),1)])],40,KU),n("div",xU,[n("span",e7,[g(c(i?.title.split("-")[0]),1),i?.title.includes("-")?(a(),l("span",t7,"-")):f("v-if",!0),g(c(i?.title.split("-").slice(1).join("-"))+" "+c(i?.accent),1)]),n("p",null,c(i?.text),1),n("a",{class:"paper-link-arrow",href:e.safeUrl(e.featureHref(i)),target:e.featureTarget(i)},c(i?.cta)+" \u2192",9,n7)])],2))),128))]),n("div",s7,[(a(!0),l(q,null,Q(e.features,(i,o)=>D((a(),l("div",{class:"paper-feature-panel",role:"tabpanel",key:i?.key,id:"feature-panel-"+i?.key,"aria-labelledby":"feature-tab-"+i?.key},[n("div",i7,[n("div",r7,[t[18]||(t[18]=n("span",{class:"dots"},[n("i"),n("i"),n("i")],-1)),n("span",a7,c(i?.url),1)]),n("div",{class:A(["feat-mock","is-"+i?.key]),role:"img","aria-label":i?.alt},[i?.key==="anonymize"?(a(),l("div",d7,[...t[19]||(t[19]=[Ce('
GitHub repository
github.com/jane-smith/DeepLearnUtils
Terms to redact
Jane SmithMIT CSAILjane.smith@mit.edu+ Add term
Reviewers can see
ImagesPDFsLinksNotebooks
Expires
Mar 31, 2027
Anonymize repository
',6)])])):i?.key==="review"?(a(),l("div",u7,[...t[20]||(t[20]=[Ce(`
data
src
train.py
README.md
LICENSE
train.py48 lines \xB7 Python
1# Training loop for DeepLearnUtils
+           label names the service and the tooltip says who to contact. `),n("li",{class:P(["nav-item nav-extra-item d-none d-lg-block",{"in-user-menu":!!e.user?.username}])},[...t[19]||(t[19]=[n("a",{class:"nav-link",target:"_blank",rel:"noopener",href:"https://github.com/tdurieux/anonymous_github/issues/new?template=issue_report.yml",title:"Report a problem with the Anonymous GitHub service. Questions about an anonymized repository or paper go to its authors.","data-offset":"30"},[n("svg",{class:"ui-icon d-lg-none mr-1","aria-hidden":"true"},[n("use",{href:"#ui-icon-bug"})]),g("Report a bug ")],-1)])],2),n("li",{class:P(["nav-item nav-support-item nav-extra-item d-none d-lg-block",{"in-user-menu":!!e.user?.username}])},[...t[20]||(t[20]=[n("a",{class:"nav-link nav-support-inline",href:"https://ko-fi.com/tdurieux",target:"_blank",rel:"noopener",title:"Donate on Ko-fi to help cover hosting costs"},[n("svg",{class:"ui-icon nav-heart","aria-hidden":"true"},[n("use",{href:"#ui-icon-heart"})]),g("Support ")],-1)])],2),e.isDarkMode?f("v-if",!0):(a(),l("li",ZU,[n("button",{type:"button",class:"nav-link nav-icon",title:"Switch to dark mode","aria-label":"Switch to dark mode",onClick:t[1]||(t[1]=s=>{e.darkMode(!0)})},[...t[21]||(t[21]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-moon"})],-1)])])])),e.isDarkMode?(a(),l("li",xU,[n("button",{type:"button",class:"nav-link nav-icon",title:"Switch to light mode","aria-label":"Switch to light mode",onClick:t[2]||(t[2]=s=>{e.darkMode(!1)})},[...t[22]||(t[22]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-sun"})],-1)])])])):f("v-if",!0),!e.user&&!e.isReviewerRoute?(a(),l("li",e7,[...t[23]||(t[23]=[n("a",{class:"nav-link btn-signin",target:"_self",href:"/signin","data-offset":"30"},[n("i",{class:"fab fa-github mr-1"}),g(" Sign in ")],-1)])])):f("v-if",!0),e.user?.username&&e.headerCanUpgrade&&!e.headerBillingPending?(a(),l("li",t7,[n("a",{class:"nav-link nav-upgrade",href:"/profile?upgrade=1",onClick:t[3]||(t[3]=ae(s=>e.openHeaderUpgrade(),["prevent"]))},"Upgrade")])):f("v-if",!0),e.user?(a(),l("li",n7,[n("a",s7,[e.user?.photo?(a(),l("img",{key:0,width:"22",height:"22",class:"rounded-circle",src:e.safeUrl(e.user?.photo)},null,8,o7)):f("v-if",!0),n("span",i7,c(e.user?.username),1)]),n("div",r7,[n("h6",a7,"Signed in as @"+c(e.user?.username),1),t[25]||(t[25]=Ce('SettingsDefaults, quotas, accountGitHub connectionsRepository access and OAuthClaim an anonymizationAttach an existing mirror to your accountReport a bugAbout this service, not a paperSource code',6)),e.headerShowSupport?(a(),l("a",l7,[...t[24]||(t[24]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-heart"})],-1),n("span",null,"Support the project",-1)])])):f("v-if",!0),t[26]||(t[26]=n("div",{class:"dropdown-divider"},null,-1)),t[27]||(t[27]=n("a",{class:"dropdown-item",href:"/api/user/logout",target:"_self"},[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-logout"})]),n("span",null,"Sign out")],-1))])])):f("v-if",!0)])])],2),e.generalMessage?(a(),l("div",{key:0,class:"navbar shadow generalMessage",innerHTML:e.sanitize(e.generalMessage)},null,8,d7)):f("v-if",!0),e.emailPromptOpen?(a(),l("dialog",{key:1,id:"email-prompt",class:"email-prompt","aria-labelledby":"email-prompt-title","aria-describedby":"email-prompt-reason",onCancel:t[8]||(t[8]=ae(s=>e.respondToEmailPrompt("later"),["prevent"]))},[n("form",{onSubmit:t[7]||(t[7]=ae(s=>e.respondToEmailPrompt("save"),["prevent"]))},[t[30]||(t[30]=n("h2",{id:"email-prompt-title"},"Stay informed about access problems",-1)),t[31]||(t[31]=n("p",{id:"email-prompt-reason"},"Get email alerts when your GitHub token or repository access fails.",-1)),t[32]||(t[32]=n("label",{for:"email-prompt-address"},"Email address",-1)),T(n("input",{id:"email-prompt-address",class:"form-control",type:"email",autocomplete:"email",maxlength:"254",required:"","onUpdate:modelValue":t[4]||(t[4]=s=>e.emailPromptAddress=s),disabled:e.emailPromptBusy},null,8,u7),[[rt,e.emailPromptAddress]]),e.emailPromptError?(a(),l("p",c7,c(e.emailPromptError),1)):f("v-if",!0),n("div",p7,[n("button",{type:"button",class:"btn btn-outline-ink",disabled:e.emailPromptBusy,onClick:t[5]||(t[5]=s=>e.respondToEmailPrompt("later"))},"Remind me later",8,f7),n("button",{type:"button",class:"btn btn-outline-ink",disabled:e.emailPromptBusy,onClick:t[6]||(t[6]=s=>e.respondToEmailPrompt("never"))},"Never",8,m7),n("button",{type:"submit",class:"btn btn-ink",disabled:e.emailPromptBusy},c(e.emailPromptBusy?"Saving\u2026":"Save"),9,h7)])],32)],32)):f("v-if",!0)],64)}var g7={class:"paper-landing"},v7={class:"paper-hero"},y7={class:"paper-hero-copy"},b7={class:"paper-cta-row"},w7={key:0,href:"/signin",target:"_self",class:"btn-hero"},k7={key:1,href:"/anonymize",class:"btn-hero"},C7={class:"paper-stats-meta"},E7={key:0,class:"paper-stats-meta-left"},S7={key:0,class:"paper-stats-grid"},N7={class:"paper-stat-label"},R7={key:0,class:"paper-stat-delta"},P7={class:"demo paper-wrap","aria-label":"Try redaction"},D7={class:"demo-terms"},A7={class:"demo-panes"},T7={class:"pane"},O7={class:"demo-input-wrap"},I7={class:"pane-body demo-backdrop","aria-hidden":"true"},M7={key:0,class:"demo-match"},V7={class:"pane pane-after"},q7={class:"pane-header"},_7={class:"pane-url"},L7={class:"meta-redact"},$7={class:"pane-body demo-output","aria-live":"polite"},F7=["title"],U7={class:"paper-features paper-wrap","aria-label":"Product features"},B7={class:"paper-features-list",role:"tablist","aria-label":"Features","aria-orientation":"vertical"},z7=["onClick","onKeydown","id","aria-controls","aria-selected","tabindex"],H7={class:"paper-eyebrow"},j7={class:"pf-num"},G7={class:"pf-name"},W7={class:"paper-feature-title"},K7={key:0,class:"serif-hy"},Y7={class:"paper-feature-more"},X7={class:"paper-feature-title paper-feature-title-m","aria-hidden":"true"},J7={key:0,class:"serif-hy"},Q7=["href","target"],Z7={class:"paper-features-stage"},x7=["id","aria-labelledby"],e9={class:"paper-frame"},t9={class:"paper-frame-bar","aria-hidden":"true"},n9={class:"url"},s9=["aria-label"],o9={key:0,class:"fm-form"},i9={key:1,class:"fm-viewer"},r9={key:2,class:"fm-dash"};function vp(e,t){let s=Xe("partial-view");return a(),l("div",g7,[f(" Hero: copy on the left, the product on the right "),n("section",v7,[n("div",y7,[t[5]||(t[5]=n("div",{class:"paper-eyebrow"},"For double-anonymous peer review",-1)),t[6]||(t[6]=n("h1",{class:"hero-title"},[g(" Share the code,"),n("br"),n("span",{class:"accent"},"not the author.")],-1)),t[7]||(t[7]=n("p",{class:"hero-subtitle"}," Anonymous GitHub makes a read-only mirror of your repository, pull request, or gist. It redacts the terms you choose in text files, so reviewers can browse your artifact through an anonymous link. ",-1)),n("div",b7,[e.user?f("v-if",!0):(a(),l("a",w7,[...t[3]||(t[3]=[n("i",{class:"fab fa-github mr-2","aria-hidden":"true"},null,-1),g("Sign in with GitHub ",-1)])])),e.user?(a(),l("a",k7," Anonymize a repository \u2192 ")):f("v-if",!0),t[4]||(t[4]=n("a",{class:"paper-link-arrow",target:"_self",href:"https://anonymous.4open.science/r/840c8c57-3c32-451e-bf12-0e20be300389/"},"See an anonymized repository \u2192",-1))]),t[8]||(t[8]=n("ul",{class:"paper-reassure"},[n("li",null,"Free, open source"),n("li",null,"Read-only access"),n("li",null,"Set an expiry date")],-1)),t[9]||(t[9]=n("p",{class:"paper-proof-mobile"},"Used by authors at ICSE \xB7 FSE \xB7 OOPSLA",-1))]),t[10]||(t[10]=n("div",{class:"paper-hero-shot"},[n("div",{class:"paper-frame"},[n("div",{class:"paper-frame-bar","aria-hidden":"true"},[n("span",{class:"dots"},[n("i"),n("i"),n("i")]),n("span",{class:"url"},"anonymous.4open.science/r/paper-7f2a")]),n("div",{class:"hero-mock",role:"img","aria-label":"A reviewer browsing an anonymized repository: the author, affiliation, and email in the README are replaced by anonymous terms"},[n("div",{class:"hero-mock-tree","aria-hidden":"true"},[n("div",{class:"hero-mock-tree-title"},"Files"),n("div",{class:"hero-mock-row is-folder"},[n("svg",{viewBox:"0 0 16 16"},[n("path",{d:"M1.5 3.5h4l1.5 1.5h7.5v8h-13z"})]),g("data")]),n("div",{class:"hero-mock-row is-folder"},[n("svg",{viewBox:"0 0 16 16"},[n("path",{d:"M1.5 3.5h4l1.5 1.5h7.5v8h-13z"})]),g("experiments")]),n("div",{class:"hero-mock-row is-folder"},[n("svg",{viewBox:"0 0 16 16"},[n("path",{d:"M1.5 3.5h4l1.5 1.5h7.5v8h-13z"})]),g("src")]),n("div",{class:"hero-mock-row"},[n("svg",{viewBox:"0 0 16 16"},[n("path",{d:"M3.5 1.5h6l3 3v10h-9z"})]),g("LICENSE")]),n("div",{class:"hero-mock-row is-active"},[n("svg",{viewBox:"0 0 16 16"},[n("path",{d:"M3.5 1.5h6l3 3v10h-9z"})]),g("README.md")]),n("div",{class:"hero-mock-row"},[n("svg",{viewBox:"0 0 16 16"},[n("path",{d:"M3.5 1.5h6l3 3v10h-9z"})]),g("requirements.txt")])]),n("div",{class:"hero-mock-doc","aria-hidden":"true"},[n("div",{class:"hero-mock-doc-bar"},[n("strong",null,"README.md"),n("span",{class:"hero-mock-count"},"3 redacted")]),n("div",{class:"hero-mock-doc-body"},[n("div",{class:"hero-mock-h1"},"DeepLearnUtils"),n("p",null,[g("Developed by "),n("span",{class:"redact",role:"img","aria-label":"Redacted term 1"},[n("i",null,"1")]),g(" at "),n("span",{class:"redact",role:"img","aria-label":"Redacted term 2"},[n("i",null,"2")]),g(".")]),n("p",{class:"hm-opt"},"Utilities for reproducing the paper\u2019s experiments."),n("div",{class:"hero-mock-h2 hm-opt"},"Quick start"),n("pre",{class:"hm-opt"},`pip install -r requirements.txt
+python experiments/run.py`),n("p",null,[g("Contact: "),n("span",{class:"redact",role:"img","aria-label":"Redacted term 3"},[n("i",null,"3")])])])])])])],-1))]),f(" Live stats "),n("section",{class:P(["paper-stats paper-wrap",{"is-empty":e.statsEmpty()}]),id:"metrics","aria-label":"Usage over the last 60 days"},[n("div",C7,[e.statsEmpty()?f("v-if",!0):(a(),l("div",E7,[...t[11]||(t[11]=[n("span",{class:"paper-stats-dot","aria-hidden":"true"},null,-1),g(),n("span",null,[g("Live \xB7 last 60 days"),n("span",{class:"paper-stats-daily"}," \xB7 updated daily")],-1)])])),t[12]||(t[12]=n("div",{class:"paper-stats-meta-right"},"Used by authors at ICSE \xB7 FSE \xB7 OOPSLA",-1))]),e.statsEmpty()?f("v-if",!0):(a(),l("div",S7,[(a(!0),l(q,null,Q(e.cards,(i,o)=>(a(),l("div",{class:"paper-stat-card",key:i?.key},[n("div",{class:P(["paper-stat-value",{"is-pending":!e.stat}])},c(e.stat?e.fmt?.bigNum(i?.total):"\u2014"),3),n("div",N7,c(i?.label),1),e.history[i?.key].bars?.length>1&&e.history[i?.key].deltaToday>0?(a(),l("div",R7," +"+c(e.fmt?.number(e.history[i?.key].deltaToday))+" today ",1)):f("v-if",!0)]))),128))]))],2),f(" Before / after "),t[22]||(t[22]=n("section",{class:"paper-section-head paper-wrap"},[n("div",null,[n("div",{class:"paper-eyebrow"},"Try it"),n("h2",null,[g("The same repository, "),n("em",null,"minus you.")])]),n("p",null," Names, affiliations, emails, and any term you list are replaced across the README, source files, notebooks, and PDF links. Reviewers browse the real thing, not a zip. ")],-1)),n("div",P7,[n("div",D7,[t[13]||(t[13]=n("label",{for:"demo-terms"},[g("Terms to redact "),n("span",null,[g("comma-separated"),n("span",{class:"dt-try"},", try adding your own")])],-1)),T(n("textarea",{id:"demo-terms",class:"demo-terms-input",rows:"1","onUpdate:modelValue":t[0]||(t[0]=i=>e.demoTerms=i),spellcheck:"false",autocomplete:"off",onKeydown:t[1]||(t[1]=kt(ae(()=>{},["prevent"]),["enter"]))},null,544),[[rt,e.demoTerms]])]),n("div",A7,[n("div",T7,[t[15]||(t[15]=n("div",{class:"pane-header"},[n("span",{class:"pane-label"},[g("Your repository "),n("span",{class:"pane-edit-hint"},"\xB7 editable")]),n("span",{class:"pane-url"},"github.com/jane-smith/DeepLearnUtils")],-1)),n("div",O7,[n("div",I7,[(a(!0),l(q,null,Q(e.demoParts(),(i,o)=>(a(),l(q,{key:o},[i.redacted?(a(),l("mark",M7,c(i.original),1)):(a(),l(q,{key:1},[g(c(i.text),1)],64))],64))),128)),t[14]||(t[14]=g("\u200B",-1))]),T(n("textarea",{class:"pane-body demo-input","onUpdate:modelValue":t[2]||(t[2]=i=>e.demoText=i),spellcheck:"false","aria-label":"Sample README to anonymize"},null,512),[[rt,e.demoText]])])]),n("div",V7,[n("div",q7,[t[16]||(t[16]=n("span",{class:"pane-label"},"What reviewers see",-1)),n("span",_7,[n("span",L7,c(e.demoCount())+" redacted",1)])]),n("div",$7,[(a(!0),l(q,null,Q(e.demoParts(),(i,o)=>(a(),l(q,{key:o},[i.redacted?(a(),l("span",{key:0,class:"redact-chip",title:"Replaces \u201C"+i.original+"\u201D"},c(i.text),9,F7)):(a(),l(q,{key:1},[g(c(i.text),1)],64))],64))),128))])])])]),f(" What you get: one screenshot, three tabs "),t[23]||(t[23]=n("section",{class:"paper-section-head paper-wrap",id:"about"},[n("div",null,[n("div",{class:"paper-eyebrow"},"What you get"),n("h2",null,"Anonymize, review, manage.")]),n("p",null," Terms are redacted in text files. Enabled images and PDFs are served unchanged, so review them for identifying content before sharing. Monitor your mirror, update it, or remove it when the review is over. ")],-1)),n("section",U7,[n("div",B7,[(a(!0),l(q,null,Q(e.features,(i,o)=>(a(),l("div",{class:P(["paper-feature",{"is-on":e.feature===i?.key}]),key:i?.key},[n("button",{type:"button",class:"paper-feature-tab",role:"tab",onClick:r=>e.selectFeature(i.key),onKeydown:r=>e.featureKeydown(r,o),id:"feature-tab-"+i?.key,"aria-controls":"feature-panel-"+i?.key,"aria-selected":e.feature===i?.key,tabindex:e.feature===i?.key?0:-1},[n("span",H7,[n("span",j7,c(i?.num),1),t[17]||(t[17]=n("span",{class:"pf-sep"}," \xB7 ",-1)),n("span",G7,c(i?.eyebrow),1)]),n("span",W7,[g(c(i?.title.split("-")[0]),1),i?.title.includes("-")?(a(),l("span",K7,"-")):f("v-if",!0),g(c(i?.title.split("-").slice(1).join("-"))+" "+c(i?.accent),1)])],40,z7),n("div",Y7,[n("span",X7,[g(c(i?.title.split("-")[0]),1),i?.title.includes("-")?(a(),l("span",J7,"-")):f("v-if",!0),g(c(i?.title.split("-").slice(1).join("-"))+" "+c(i?.accent),1)]),n("p",null,c(i?.text),1),n("a",{class:"paper-link-arrow",href:e.safeUrl(e.featureHref(i)),target:e.featureTarget(i)},c(i?.cta)+" \u2192",9,Q7)])],2))),128))]),n("div",Z7,[(a(!0),l(q,null,Q(e.features,(i,o)=>T((a(),l("div",{class:"paper-feature-panel",role:"tabpanel",key:i?.key,id:"feature-panel-"+i?.key,"aria-labelledby":"feature-tab-"+i?.key},[n("div",e9,[n("div",t9,[t[18]||(t[18]=n("span",{class:"dots"},[n("i"),n("i"),n("i")],-1)),n("span",n9,c(i?.url),1)]),n("div",{class:P(["feat-mock","is-"+i?.key]),role:"img","aria-label":i?.alt},[i?.key==="anonymize"?(a(),l("div",o9,[...t[19]||(t[19]=[Ce('
GitHub repository
github.com/jane-smith/DeepLearnUtils
Terms to redact
Jane SmithMIT CSAILjane.smith@mit.edu+ Add term
Reviewers can see
ImagesPDFsLinksNotebooks
Expires
Mar 31, 2027
Anonymize repository
',6)])])):i?.key==="review"?(a(),l("div",i9,[...t[20]||(t[20]=[Ce(`
data
src
train.py
README.md
LICENSE
train.py48 lines \xB7 Python
1# Training loop for DeepLearnUtils
 2# Author: XXXX-1, XXXX-2
 3import torch
 4from utils import load_config
@@ -55,18 +55,18 @@ python experiments/run.py`),n("p",null,[g("Contact: "),n("span",{class:"redact",
 7    model = build_model(config)
 8    for epoch in range(config.epochs):
 9        loss = step(model)
-10        log("epoch %d: %.3f", epoch, loss)
`,2)])])):(a(),l("div",c7,[...t[21]||(t[21]=[Ce('
ProjectStatusViewsExpires
DeepLearnUtilspaper-7f2a \xB7 ICSE 2027Ready41Mar 31, 2027
vision-bench#212pull request \xB7 FSE 2027Ready12Never
graph-repairgr-91abUpdating5Jan 5, 2027
JarSiftOOPSLA 2025Expired72Sep 28, 2026
',5)])]))],10,l7)])],8,o7)),[[Z,e.feature===i?.key]])),128))])]),f(" FAQ teaser "),t[24]||(t[24]=Ce('
Before you sign in

The questions that come up most.

Read the full FAQ \u2192
What access does GitHub sign-in require?

The GitHub App has read-only access to gists and the repositories you choose. Legacy OAuth uses broader permissions. Anonymous GitHub never writes to your repositories.

Which file formats are supported?

Source code with syntax highlighting, Markdown, Jupyter notebooks, PDFs, images, and GitHub Pages sites. Text files are anonymized; enabled images and PDFs are served unchanged.

What happens when an anonymized repository expires?

You choose: the mirror is removed, or visitors are redirected to the original GitHub repository once the review is over.

Ready for review?

Create an anonymous mirror in a couple of minutes. Reviewers just open the link.

',2)),Oe(s,{name:"partials/footer.htm",state:e.viewState},null,8,["state"])])}var p7={class:"paper-empty"},f7={class:"paper-empty-inner"},h7={key:0,class:"paper-eyebrow"},m7={key:1,class:"paper-eyebrow"},g7={key:2,class:"paper-empty-title"},v7=["textContent"];function yp(e,t){return a(),l("div",p7,[n("div",f7,[e.error?f("v-if",!0):(a(),l("div",h7,"Working")),e.error?(a(),l("div",m7,"Error")):f("v-if",!0),e.error?f("v-if",!0):(a(),l("h1",g7,[...t[0]||(t[0]=[g(" Loading",-1),n("span",{class:"dot-anim"},"\u2026",-1)])])),e.error?(a(),l("h1",{key:3,class:"paper-empty-title",textContent:c(e.fmt.translate(e.error))},null,8,v7)):f("v-if",!0)])])}var y7={class:"container paper-page paper-settings"},b7={class:"paper-crumbs"},w7={class:"here"},k7={class:"paper-page-title"},C7={class:"paper-settings-body"},E7={class:"paper-settings-toc"},S7={href:"#conf-billing"},N7={class:"form needs-validation paper-settings-main",name:"conference",novalidate:""},R7={id:"conf-basics",class:"paper-settings-section"},A7={class:"form-group"},P7={class:"invalid-feedback"},D7={class:"invalid-feedback"},T7={class:"form-group"},O7={class:"invalid-feedback"},I7={class:"form-group"},M7={class:"invalid-feedback"},V7={class:"invalid-feedback"},q7={id:"conf-window",class:"paper-settings-section"},_7={class:"form-grid-2"},L7={class:"form-group"},$7={class:"invalid-feedback"},F7={class:"invalid-feedback"},U7={class:"form-group"},B7={class:"invalid-feedback"},z7={class:"invalid-feedback"},H7={id:"conf-rendering",class:"paper-settings-section"},j7={class:"form-check"},G7={class:"form-check-input",type:"checkbox",id:"link",name:"link"},W7={class:"form-check"},K7={class:"form-check-input",type:"checkbox",id:"image",name:"image"},Y7={class:"form-check"},X7={class:"form-check-input",type:"checkbox",id:"pdf",name:"pdf"},J7={class:"form-check"},Q7={class:"form-check-input",type:"checkbox",id:"notebook",name:"notebook"},Z7={id:"conf-features",class:"paper-settings-section"},x7={class:"form-check"},e9={class:"form-check-input",type:"checkbox",id:"update",name:"update"},t9={class:"form-check"},n9={class:"form-check-input",type:"checkbox",id:"page",name:"page"},s9={id:"conf-plan",class:"paper-settings-section"},o9={key:0,class:"paper-section-copy"},i9={class:"conference-tiers",role:"radiogroup","aria-label":"Review package size"},r9=["value","checked","onChange"],a9={class:"conference-tier-head"},l9={key:0,class:"conference-tier-pill"},d9={class:"conference-tier-who"},u9={key:0,class:"conference-tier-price"},c9={class:"conference-tier-size"},p9={key:1,class:"conference-tier-per"},f9={key:2,class:"paper-plan-grid"},h9=["value"],m9=["textContent"],g9={class:"paper-plan-price"},v9=["innerHTML"],y9={key:3,class:"settings-notice",role:"status"},b9={key:0,id:"conf-billing",class:"paper-settings-section"},w9={class:"form-group"},k9={class:"form-group"},C9={class:"form-group"},E9={class:"form-group"},S9={class:"form-grid-3"},N9={class:"form-group"},R9={class:"form-group"},A9={class:"form-group"},P9={class:"form-group"},D9={class:"paper-settings-footer"},T9=["textContent"],O9=["textContent"],I9=["disabled"];function bp(e,t){let s=Pe("paper-scrollspy"),i=Pe("field"),o=Pe("form");return a(),l("div",y7,[n("div",b7,[t[1]||(t[1]=n("a",{href:"/dashboard"},"My work",-1)),t[2]||(t[2]=g(" \xA0/\xA0 ",-1)),t[3]||(t[3]=n("a",{href:"/conferences"},"Conferences",-1)),t[4]||(t[4]=g(" \xA0/\xA0 ",-1)),n("span",w7,c(e.editionMode?"Edit":"New"),1)]),n("h1",k7,[g(c(e.editionMode?"Edit":"Create a")+" ",1),t[5]||(t[5]=n("em",null,"conference",-1))]),t[44]||(t[44]=n("p",{class:"paper-page-lede"}," Give chairs access to every anonymization submitted to a venue. One payment hosts every submission, so authors don't pay during the review window. ",-1)),n("div",C7,[D((a(),l("aside",E7,[t[7]||(t[7]=n("div",{class:"paper-settings-toc-head"},"On this page",-1)),n("nav",null,[t[6]||(t[6]=Ce('BasicsReview windowRendering defaultsFeaturesPlan',5)),D(n("a",S7,"Billing",512),[[Z,e.plan?.pricePerRepo>0]])])])),[[s]]),D((a(),l("form",N7,[n("section",R7,[t[12]||(t[12]=n("div",{class:"paper-section-eyebrow"},"Basics",-1)),n("div",A7,[t[8]||(t[8]=n("label",{class:"paper-field-label",for:"name"},"Conference name",-1)),D(n("input",{type:"text",class:A(["form-control",{"is-invalid":e.conference?.name?.invalid&&(e.conference?.name?.touched||e.conference?.submitted)}]),name:"name",id:"name",required:"",placeholder:"e.g. International Conference on Software Engineering"},null,2),[[i,{state:e.viewState,set:r=>{e.options.name=r},value:e.options?.name,form:"conference",options:{}}]]),D(n("div",P7," The name of the conference is invalid. ",512),[[Z,e.conference?.name?.errors?.invalid]]),D(n("div",D7," The name of the conference is required. ",512),[[Z,e.conference?.name?.errors?.required]])]),n("div",T7,[t[9]||(t[9]=n("label",{class:"paper-field-label",for:"url"},"Website",-1)),D(n("input",{type:"url",class:A(["form-control",{"is-invalid":e.conference?.url?.invalid&&(e.conference?.url?.touched||e.conference?.submitted)}]),name:"url",id:"url",placeholder:"https://example.org"},null,2),[[i,{state:e.viewState,set:r=>{e.options.url=r},value:e.options?.url,form:"conference",options:{}}]]),D(n("div",O7," The url of the conference is invalid. ",512),[[Z,e.conference?.url?.errors?.url]])]),n("div",I7,[t[10]||(t[10]=n("label",{class:"paper-field-label",for:"conferenceID"},"Conference ID",-1)),D(n("input",{type:"text",class:A(["form-control",{"is-invalid":e.conference?.conferenceID?.invalid&&(e.conference?.conferenceID?.touched||e.conference?.submitted)}]),name:"conferenceID",id:"conferenceID",required:"",pattern:"[a-zA-Z0-9\\-_]{3,10}",placeholder:"ICSE26"},null,2),[[i,{state:e.viewState,set:r=>{e.options.conferenceID=r},value:e.options?.conferenceID,form:"conference",options:{}}]]),t[11]||(t[11]=n("small",{class:"form-text text-muted"},[g("3\u201310 characters, letters, numbers, "),n("code",null,"-"),g(" and "),n("code",null,"_"),g(". Authors reference this when they anonymize.")],-1)),D(n("div",{class:"invalid-feedback"}," The conference ID '"+c(e.options?.conferenceID)+"' is already used. ",513),[[Z,e.conference?.conferenceID?.errors?.used]]),D(n("div",M7," The conference ID is required. ",512),[[Z,e.conference?.conferenceID?.errors?.required]]),D(n("div",V7," The format of the conference ID is incorrect ([a-zA-Z0-9-_]{3,10}). ",512),[[Z,e.conference?.conferenceID?.errors?.pattern]])])]),n("section",q7,[t[17]||(t[17]=n("div",{class:"paper-section-eyebrow"},"Review window",-1)),n("div",_7,[n("div",L7,[t[13]||(t[13]=n("label",{class:"paper-field-label",for:"startDate"},"Start date",-1)),D(n("input",{type:"date",class:A(["form-control",{"is-invalid":e.conference?.startDate?.invalid&&(e.conference?.startDate?.touched||e.conference?.submitted)}]),name:"startDate",id:"startDate",required:""},null,2),[[i,{state:e.viewState,set:r=>{e.options.startDate=r},value:e.options?.startDate,form:"conference",options:{}}]]),t[14]||(t[14]=n("small",{class:"form-text text-muted"},"Beginning of the review process.",-1)),D(n("div",$7," Start date is required. ",512),[[Z,e.conference?.startDate?.errors?.required]]),D(n("div",F7," Start date must be before end date. ",512),[[Z,e.conference?.startDate?.errors?.invalid]])]),n("div",U7,[t[15]||(t[15]=n("label",{class:"paper-field-label",for:"endDate"},"End date",-1)),D(n("input",{type:"date",class:A(["form-control",{"is-invalid":e.conference?.endDate?.invalid&&(e.conference?.endDate?.touched||e.conference?.submitted)}]),name:"endDate",id:"endDate",required:""},null,2),[[i,{state:e.viewState,set:r=>{e.options.endDate=r},value:e.options?.endDate,form:"conference",options:{}}]]),t[16]||(t[16]=n("small",{class:"form-text text-muted"},"All repositories expire on this date.",-1)),D(n("div",B7," End date is required. ",512),[[Z,e.conference?.endDate?.errors?.required]]),D(n("div",z7," End date is invalid. ",512),[[Z,e.conference?.endDate?.errors?.invalid]])])])]),n("section",H7,[t[26]||(t[26]=n("div",{class:"paper-section-eyebrow"},"Rendering defaults",-1)),n("div",j7,[D(n("input",G7,null,512),[[i,{state:e.viewState,set:r=>{e.options.options.link=r},value:e.options?.options?.link,form:"conference",options:{}}]]),t[18]||(t[18]=n("label",{class:"form-check-label",for:"link"},"Keep links",-1)),t[19]||(t[19]=n("small",{class:"form-text text-muted"},"Keep or remove all links from text files.",-1))]),n("div",W7,[D(n("input",K7,null,512),[[i,{state:e.viewState,set:r=>{e.options.options.image=r},value:e.options?.options?.image,form:"conference",options:{}}]]),t[20]||(t[20]=n("label",{class:"form-check-label",for:"image"},"Display images",-1)),t[21]||(t[21]=n("small",{class:"form-text text-muted"},"Images are not anonymized.",-1))]),n("div",Y7,[D(n("input",X7,null,512),[[i,{state:e.viewState,set:r=>{e.options.options.pdf=r},value:e.options?.options?.pdf,form:"conference",options:{}}]]),t[22]||(t[22]=n("label",{class:"form-check-label",for:"pdf"},"Display PDFs",-1)),t[23]||(t[23]=n("small",{class:"form-text text-muted"},"PDFs are not anonymized.",-1))]),n("div",J7,[D(n("input",Q7,null,512),[[i,{state:e.viewState,set:r=>{e.options.options.notebook=r},value:e.options?.options?.notebook,form:"conference",options:{}}]]),t[24]||(t[24]=n("label",{class:"form-check-label",for:"notebook"},"Display notebooks",-1)),t[25]||(t[25]=n("small",{class:"form-text text-muted"},"Render Jupyter notebooks instead of raw JSON.",-1))])]),n("section",Z7,[t[31]||(t[31]=n("div",{class:"paper-section-eyebrow"},"Features",-1)),n("div",x7,[D(n("input",e9,null,512),[[i,{state:e.viewState,set:r=>{e.options.options.update=r},value:e.options?.options?.update,form:"conference",options:{}}]]),t[27]||(t[27]=n("label",{class:"form-check-label",for:"update"},"Auto-update from GitHub",-1)),t[28]||(t[28]=n("small",{class:"form-text text-muted"},"Pull the latest commit automatically (hourly maximum).",-1))]),n("div",t9,[D(n("input",n9,null,512),[[i,{state:e.viewState,set:r=>{e.options.options.page=r},value:e.options?.options?.page,form:"conference",options:{}}]]),t[29]||(t[29]=n("label",{class:"form-check-label",for:"page"},"GitHub Pages",-1)),t[30]||(t[30]=n("small",{class:"form-text text-muted"},"Enable anonymized GitHub pages.",-1))])]),n("section",s9,[t[35]||(t[35]=n("div",{class:"paper-section-eyebrow"},"Plan",-1)),e.editionMode?(a(),l("p",o9,c(e.conferencePlanName(e.options?.plan?.planID))+". The plan and review dates can't change after creation.",1)):e.conferenceTiers().length?(a(),l(q,{key:1},[t[33]||(t[33]=n("p",{class:"paper-section-copy"},"Pick the package that fits the number of submissions you expect. One payment hosts every submission, so authors don't pay.",-1)),n("div",i9,[(a(!0),l(q,null,Q(e.conferenceTiers(),r=>(a(),l("label",{class:A(["conference-tier",{"is-selected":e.options?.plan?.planID===r.id}]),key:r.id},[n("input",{type:"radio",name:"planPicker",value:r.id,checked:e.options?.plan?.planID===r.id,onChange:d=>e.options.plan.planID=r.id},null,40,r9),n("span",a9,[n("strong",null,c(r.name),1),r.id==="conference"&&e.conferenceTiers().length>1?(a(),l("span",l9,"Most common")):f("v-if",!0)]),n("span",d9,c(e.conferenceAudience(r.id)),1),r.amount!=null?(a(),l("span",u9,[n("strong",null,c(e.conferenceAmount(r)),1),t[32]||(t[32]=g(" once",-1))])):f("v-if",!0),n("span",c9,"Up to "+c(r.repositories)+" papers \xB7 "+c(e.conferenceBytes(r.storage)),1),r.amount!=null&&r.repositories?(a(),l("span",p9,"About "+c(e.conferenceAmount(r,r.amount/r.repositories))+" per paper",1)):f("v-if",!0)],2))),128))]),t[34]||(t[34]=Ce('

Every package includes

  • A review window of up to 180 days
  • Automatic updates for every submission
  • Links stay online until the review window ends
  • A dashboard of every submission for chairs

Nothing renews \xB7 Tax shown at checkout \xB7 Expecting more submissions? Email tdurieux@anonymous.4open.science

Create the conference, then pay from its page. Authors can submit once the payment is confirmed.

',2))],64)):e.plans.length?(a(),l("div",f9,[(a(!0),l(q,null,Q(e.plans,r=>(a(),l("label",{class:A(["paper-plan-card",{selected:e.options?.plan?.planID==r?.id}]),key:r.id},[D(n("input",{type:"radio",name:"planPicker",value:r?.id},null,8,h9),[[i,{state:e.viewState,set:d=>{e.options.plan.planID=d},value:e.options?.plan?.planID,form:"conference",options:{}}]]),n("div",{class:"paper-plan-head",textContent:c(r?.name)},null,8,m9),n("div",g9,c(r.pricePerRepo>0?e.fmt?.number(r.pricePerRepo,2)+" \u20AC per repository":"Free"),1),n("div",{class:"paper-plan-desc",innerHTML:e.sanitize(r?.description)},null,8,v9)],2))),128))])):e.plansLoaded?(a(),l("p",y9,"New conferences are unavailable right now. Please try again later.")):f("v-if",!0)]),e.plan?.pricePerRepo>0?(a(),l("section",b9,[t[43]||(t[43]=n("div",{class:"paper-section-eyebrow"},"Billing",-1)),n("div",w9,[t[36]||(t[36]=n("label",{class:"paper-field-label",for:"billing_name"},"Name",-1)),D(n("input",{type:"text",class:A(["form-control",{"is-invalid":e.conference?.billing_name?.invalid&&(e.conference?.billing_name?.touched||e.conference?.submitted)}]),name:"billing_name",id:"billing_name",required:"",placeholder:"First & last name"},null,2),[[i,{state:e.viewState,set:r=>{e.options.billing.name=r},value:e.options?.billing?.name,form:"conference",options:{}}]])]),n("div",k9,[t[37]||(t[37]=n("label",{class:"paper-field-label",for:"email"},"Email",-1)),D(n("input",{type:"email",class:A(["form-control",{"is-invalid":e.conference?.email?.invalid&&(e.conference?.email?.touched||e.conference?.submitted)}]),name:"email",id:"email",required:"",placeholder:"you@example.org"},null,2),[[i,{state:e.viewState,set:r=>{e.options.billing.email=r},value:e.options?.billing?.email,form:"conference",options:{}}]])]),n("div",C9,[t[38]||(t[38]=n("label",{class:"paper-field-label",for:"inputAddress"},"Address",-1)),D(n("input",{type:"text",class:A(["form-control",{"is-invalid":e.conference?.inputAddress?.invalid&&(e.conference?.inputAddress?.touched||e.conference?.submitted)}]),name:"inputAddress",id:"inputAddress",required:"",placeholder:"1234 Main St"},null,2),[[i,{state:e.viewState,set:r=>{e.options.billing.address=r},value:e.options?.billing?.address,form:"conference",options:{}}]])]),n("div",E9,[D(n("input",{type:"text",class:A(["form-control",{"is-invalid":e.conference?.inputAddress2?.invalid&&(e.conference?.inputAddress2?.touched||e.conference?.submitted)}]),name:"inputAddress2",id:"inputAddress2",placeholder:"Apartment, studio, or floor"},null,2),[[i,{state:e.viewState,set:r=>{e.options.billing.address2=r},value:e.options?.billing?.address2,form:"conference",options:{}}]])]),n("div",S9,[n("div",N9,[t[39]||(t[39]=n("label",{class:"paper-field-label",for:"city"},"City",-1)),D(n("input",{type:"text",class:A(["form-control",{"is-invalid":e.conference?.city?.invalid&&(e.conference?.city?.touched||e.conference?.submitted)}]),name:"city",id:"city",required:"",placeholder:"City"},null,2),[[i,{state:e.viewState,set:r=>{e.options.billing.city=r},value:e.options?.billing?.city,form:"conference",options:{}}]])]),n("div",R9,[t[40]||(t[40]=n("label",{class:"paper-field-label",for:"country"},"Country",-1)),D(n("input",{type:"text",class:A(["form-control",{"is-invalid":e.conference?.country?.invalid&&(e.conference?.country?.touched||e.conference?.submitted)}]),name:"country",id:"country",required:"",placeholder:"Country"},null,2),[[i,{state:e.viewState,set:r=>{e.options.billing.country=r},value:e.options?.billing?.country,form:"conference",options:{}}]])]),n("div",A9,[t[41]||(t[41]=n("label",{class:"paper-field-label",for:"zip"},"Zip",-1)),D(n("input",{type:"text",class:A(["form-control",{"is-invalid":e.conference?.zip?.invalid&&(e.conference?.zip?.touched||e.conference?.submitted)}]),name:"zip",id:"zip",required:"",placeholder:"Zip"},null,2),[[i,{state:e.viewState,set:r=>{e.options.billing.zip=r},value:e.options?.billing?.zip,form:"conference",options:{}}]])])]),n("div",P9,[t[42]||(t[42]=n("label",{class:"paper-field-label",for:"vat"},"VAT number",-1)),D(n("input",{type:"text",class:A(["form-control",{"is-invalid":e.conference?.vat?.invalid&&(e.conference?.vat?.touched||e.conference?.submitted)}]),name:"vat",id:"vat",placeholder:"VAT Number"},null,2),[[i,{state:e.viewState,set:r=>{e.options.billing.vat=r},value:e.options?.billing?.vat,form:"conference",options:{}}]])])])):f("v-if",!0),n("div",D9,[e.error?(a(),l("div",{key:0,class:"alert alert-danger",role:"alert",textContent:c(e.error)},null,8,T9)):f("v-if",!0),e.message?(a(),l("div",{key:1,class:"alert alert-success",role:"alert",textContent:c(e.message)},null,8,O9)):f("v-if",!0),n("button",{id:"send",disabled:e.saving,type:"submit",class:"btn btn-ink",onClick:t[0]||(t[0]=ae(r=>e.submitForm(r,()=>{e.submit(r)}),["prevent"]))},c(e.saving?e.editionMode?"Updating\u2026":"Creating\u2026":e.editionMode?"Update conference":"Create conference"),9,I9)])])),[[o,e.viewState]])])])}var M9={key:0,class:"dir-card","aria-label":"Repository files"},V9=["onClick"],q9={class:"dir-name"},_9=["href"],L9={class:"dir-name"},$9={class:"dir-meta"},F9={class:"file-card-head"},U9={class:"file-card-path"},B9={class:"breadcrumb paths","aria-label":"Path"},z9={class:"breadcrumb-item breadcrumb-root"},H9=["href","title","textContent"],j9=["aria-current"],G9=["aria-label"],W9={class:"mobile-sub ms"},K9=["title"],Y9={class:"ms-item"},X9={key:1,class:"ms-item"},J9={key:2,class:"ms-item"},Q9=["aria-label","title"],Z9={class:"ui-icon","aria-hidden":"true"},x9=["href"],eB={key:0,class:"file-card-meta"},tB=["title"],nB={class:"meta-extra"},sB={key:1,class:"file-card-meta"},oB=["title"],iB={class:"file-card-actions"},rB={key:0,class:"csv-toggle seg-filter",role:"radiogroup","aria-label":"CSV view"},aB=["aria-checked"],lB=["aria-checked"],dB={key:1,class:"symbols"},uB=["aria-expanded"],cB={key:0,class:"symbols-menu",role:"menu"},pB={class:"symbols-head"},fB=["onClick"],hB={class:"symbols-name"},mB={class:"symbols-line"},gB=["title"],vB={key:3,class:"tb-view",role:"group","aria-label":"View tools"},yB=["title"],bB=["aria-pressed"],wB=["title"],kB={key:4,class:"tb-file",role:"group","aria-label":"File actions"},CB=["target","title","href"],EB=["aria-label","title"],SB={class:"ui-icon","aria-hidden":"true"},NB=["href"],RB=["target","href","download"],AB=["aria-label"],PB={class:"ui-icon","aria-hidden":"true"},DB=["href"],TB={key:6,class:"tb-toc-m"},OB=["aria-expanded"],IB=["onClick"],MB={class:"tb-more"},VB=["aria-expanded"],qB={viewBox:"0 0 24 24",class:"ui-icon","aria-hidden":"true",style:{fill:"currentColor",stroke:"none"}},_B={key:0,class:"tb-menu-note"},LB={key:1,class:"tb-menu-note tb-menu-meta"},$B={key:2,class:"tb-menu-sep"},FB={key:4,class:"tb-menu-sep"},UB=["aria-checked"],BB={key:0,class:"tb-menu-check"},zB={class:"ui-icon","aria-hidden":"true"},HB=["href"],jB={key:9,class:"tb-menu-sep"},GB=["target","href"],WB=["target","href"],KB=["target","href","download"],YB=["target","href"],XB=["href"],JB=["target","href"],QB=["placeholder","aria-invalid"],ZB=["aria-label"],xB={class:"csv-table"},ez=["aria-label"],tz={class:"csv-rownum"},nz=["aria-label"],sz={key:1,class:"file-card-body"},oz={key:2,class:"md-find-bar",role:"search"},iz=["value"],rz={class:"md-find-nav"},az=["disabled"],lz=["disabled"],dz={class:"md-find-count","aria-live":"polite"},uz=["aria-pressed"],cz={key:3,class:"reading-layout"},pz=["innerHTML"],fz={key:0,class:"readme-toc","aria-label":"On this page"},hz={class:"toc-rail"},mz=["href","onClick"],gz={class:"file-card-head"},vz={class:"file-card-path"},yz={class:"breadcrumb paths","aria-label":"Path"},bz={class:"breadcrumb-item breadcrumb-root"},wz=["href","title","textContent"],kz=["aria-current"],Cz=["aria-label"],Ez={class:"mobile-sub ms"},Sz=["title"],Nz={class:"ms-item"},Rz={key:1,class:"ms-item"},Az={key:2,class:"ms-item"},Pz=["aria-label","title"],Dz={class:"ui-icon","aria-hidden":"true"},Tz=["href"],Oz={class:"file-card-meta"},Iz=["title"],Mz={class:"file-card-actions"},Vz={key:0,class:"file-card-state",title:"Files over the size limit can't be previewed or downloaded from this link"},qz={key:1,class:"tb-file",role:"group","aria-label":"File actions"},_z=["target","title","href"],Lz=["target","href","download"],$z={class:"tb-more"},Fz=["aria-expanded"],Uz={viewBox:"0 0 24 24",class:"ui-icon","aria-hidden":"true",style:{fill:"currentColor",stroke:"none"}},Bz={key:0,class:"tb-menu-note"},zz={key:1,class:"tb-menu-sep"},Hz=["target","href"],jz=["target","href","download"],Gz=["target","href"],Wz={key:0,class:"media-stage"},Kz=["src","alt"],Yz={key:1,class:"media-stage"},Xz=["src"],Jz={key:2,class:"media-stage is-audio"},Qz=["src"],Zz={key:4,class:"notebook-body"},xz={key:5,class:"file-state"},eH={class:"file-state-msg"},tH={key:0,class:"file-state-actions"},nH=["target","href","download"],sH={key:6,class:"file-state",role:"alert"},oH={class:"file-state-title"},iH={key:0,class:"file-state-msg"},rH={key:1,class:"file-state-msg"},aH={key:2,class:"file-state-actions"},lH=["href"],dH={key:7,class:"file-state"},uH={key:4,class:"file-error container d-flex h-100"},cH={class:"paper-ratelimit-card m-auto",style:{"max-width":"520px"}},pH={class:"paper-error-msg"},fH={key:5,class:"file-error container d-flex h-100"},hH={class:"viewer-error paper-error-card file-error-card m-auto",role:"alert","aria-labelledby":"viewer-error-title"},mH={id:"viewer-error-title",class:"paper-empty-title"},gH={class:"paper-error-actions"},vH={key:0,href:"/",class:"btn btn-sm"},yH={key:1,href:"/faq",class:"btn btn-sm"},bH={key:2,class:"btn btn-outline-ink",href:"/dashboard"},wH={key:6,class:"viewer-loading","aria-busy":"true"},kH={class:"viewer-loading-status",role:"status","aria-live":"polite"},CH={class:"viewer-loading-name sr-only"},EH={key:0},SH={class:"viewer-loading-lines","aria-hidden":"true"},NH={key:7,class:"file-error container d-flex h-100"},RH={key:8,class:"file-error container d-flex h-100"};function wp(e,t){let s=Xe("html-doc"),i=Xe("pdfviewer"),o=Xe("notebook"),r=Pe("code-editor");return a(),l(q,null,[e.sidebarHidden&&e.type=="html"&&e.content!=null&&e.paths?.length===1&&/^readme/i.test(e.paths[0]||"")&&e.files?.length?(a(),l("section",M9,[t[46]||(t[46]=n("header",{class:"dir-card-head"},[n("span",{class:"dir-card-title"},"Files"),n("span",{class:"dir-card-sub"},"Snapshot of the repository at review time")],-1)),n("ul",{class:A(["dir-list",{"is-expanded":e.dirExpanded}])},[(a(!0),l(q,null,Q(e.rootEntries(),d=>(a(),l("li",{key:d.name},[d.size==null?(a(),l("button",{key:0,type:"button",class:"dir-row",onClick:p=>e.revealFolder(d.name)},[t[43]||(t[43]=n("svg",{class:"dir-icon",viewBox:"0 0 16 16","aria-hidden":"true"},[n("path",{d:"M1.5 3.5h4l1.5 1.5h7.5v8h-13z"})],-1)),n("span",q9,c(d.name),1),t[44]||(t[44]=n("span",{class:"dir-meta"},"Folder",-1))],8,V9)):(a(),l("a",{key:1,class:A(["dir-row",{"is-current":d.name===e.paths[0]}]),href:e.safeUrl("/r/"+e.repoId+"/"+encodeURIComponent(d.name))},[t[45]||(t[45]=n("svg",{class:"dir-icon",viewBox:"0 0 16 16","aria-hidden":"true"},[n("path",{d:"M3.5 1.5h6l3 3v10h-9z"})],-1)),n("span",L9,c(d.name),1),n("span",$9,c(e.formatSize(d.size)),1)],10,_9))]))),128))],2),!e.dirExpanded&&e.files.length>8?(a(),l("button",{key:0,type:"button",class:"dir-more",onClick:t[0]||(t[0]=d=>e.dirExpanded=!0)},"Show all "+c(e.files.length)+" items",1)):f("v-if",!0)])):f("v-if",!0),(e.type=="text"||e.type=="code"||e.type=="html"||e.type=="html-doc"&&e.showSource)&&e.content!=null?(a(),l("section",{key:1,class:A(["file-card",{"is-code":e.type!="html","no-wrap":!e.wrapLines}])},[n("header",F9,[n("div",U9,[n("button",{type:"button",class:A(["btn btn-sm btn-icon-only btn-ghost card-files-btn",{"is-needed":e.sidebarHidden}]),title:"Show file tree",onClick:t[1]||(t[1]=d=>e.sidebarHidden?e.sidebarHidden=!1:e.sidebarCollapsed=!1)},[...t[47]||(t[47]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-sidebar"})],-1),n("span",{class:"card-files-label"},"Files",-1)])],2),n("ol",B9,[n("li",z9,[n("a",{href:e.safeUrl("/r/"+e.repoId+"/"),title:e.repoId,textContent:c(/^[0-9a-f]{8}-[0-9a-f]{4}-/i.test(e.repoId||"")?"repository":e.repoId)},null,8,H9)]),(a(!0),l(q,null,Q(e.paths,(d,p)=>(a(),l("li",{class:"breadcrumb-item","aria-current":p===e.paths.length-1?"page":null},[(a(!0),l(q,null,Q(e.redactParts(d),(u,y)=>(a(),l(q,{key:y},[u.n?(a(),l("span",{key:0,class:"redact-slot",role:"img","aria-label":"Redacted term "+u.n},[n("i",null,c(u.n),1)],8,G9)):(a(),l(q,{key:1},[g(c(u.t),1)],64))],64))),128))],8,j9))),256))]),n("span",W9,[e.redactionCount()?(a(),l("b",{key:0,class:"ms-item ms-redact",title:e.redactionCount()+" redacted terms"},[g(c(e.redactionCount()),1),t[48]||(t[48]=n("span",{class:"meta-redact-word"}," redacted",-1))],8,K9)):f("v-if",!0),n("span",Y9,c(e.type=="html"?"Markdown":e.languageName||"Text"),1),e.fileSize(e.filePath)!=null?(a(),l("span",X9,c(e.formatSize(e.fileSize(e.filePath))),1)):f("v-if",!0),e.type!="html"&&typeof e.content=="string"?(a(),l("span",J9,c(e.fmt?.number(e.content.split(` -`).length))+" lines",1)):f("v-if",!0)]),D(n("button",{type:"button",class:"btn btn-sm btn-icon-only btn-ghost copy-path-btn","aria-label":e.pathCopied?"Path copied":"Copy file path",title:e.pathCopied?"Path copied":"Copy file path",onClick:t[2]||(t[2]=d=>e.copyPath())},[(a(),l("svg",Z9,[n("use",{href:e.pathCopied?"#ui-icon-check":"#ui-icon-link"},null,8,x9)]))],8,Q9),[[Z,e.filePath]])]),e.type!="html"&&typeof e.content=="string"?(a(),l("span",eB,[e.redactionCount()?(a(),l(q,{key:0},[n("span",{class:"meta-redact",title:e.redactionCount()+" redacted terms"},[g(c(e.redactionCount()),1),t[49]||(t[49]=n("span",{class:"meta-redact-word"}," redacted",-1))],8,tB),t[50]||(t[50]=n("span",{class:"sep"},"\xB7",-1))],64)):f("v-if",!0),g(c(e.languageName||"Text"),1),n("span",nB,[t[51]||(t[51]=n("span",{class:"sep"},"\xB7",-1)),g(c(e.content.length<1024?e.content.length+" B":(e.content.length/1024).toFixed(1)+" KB"),1)]),t[52]||(t[52]=n("span",{class:"sep"},"\xB7",-1)),g(c(e.fmt?.number(e.content.split(` -`).length))+" lines",1)])):f("v-if",!0),e.type=="html"?(a(),l("span",sB,[e.redactionCount()?(a(),l(q,{key:0},[n("span",{class:"meta-redact",title:e.redactionCount()+" redacted terms"},[g(c(e.redactionCount()),1),t[53]||(t[53]=n("span",{class:"meta-redact-word"}," redacted",-1))],8,oB),t[54]||(t[54]=n("span",{class:"sep"},"\xB7",-1))],64)):f("v-if",!0),t[56]||(t[56]=g("Markdown",-1)),e.fileSize(e.filePath)!=null?(a(),l(q,{key:1},[t[55]||(t[55]=n("span",{class:"sep"},"\xB7",-1)),g(c(e.formatSize(e.fileSize(e.filePath))),1)],64)):f("v-if",!0)])):f("v-if",!0),e.preview&&e.previewPreserved()?(a(),l("button",{key:2,type:"button",class:"rp-preserved-tag",onClick:t[3]||(t[3]=d=>e.openPreserveFiles())},"Left unredacted")):f("v-if",!0),n("div",iB,[e.isCsv()?(a(),l("div",rB,[n("button",{type:"button",role:"radio",class:A(["seg-chip",{active:e.csvView==="table"}]),"aria-checked":e.csvView==="table",onClick:t[4]||(t[4]=d=>e.csvView="table")},"Table",10,aB),n("button",{type:"button",role:"radio",class:A(["seg-chip",{active:e.csvView==="raw"}]),"aria-checked":e.csvView==="raw",onClick:t[5]||(t[5]=d=>e.csvView="raw"),title:"Show the file as text with line numbers"},"Text",10,lB)])):f("v-if",!0),e.type!="html"&&e.symbols().length>1?(a(),l("div",dB,[n("button",{type:"button",class:A(["btn btn-sm btn-ghost btn-symbols",{"is-on":e.symbolsOpen}]),"aria-expanded":e.symbolsOpen?"true":"false","aria-haspopup":"true",title:"Symbols in this file",onClick:t[6]||(t[6]=d=>e.symbolsOpen=!e.symbolsOpen)},[...t[57]||(t[57]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-list"})],-1),n("span",{class:"btn-find-label"},"Symbols",-1)])],10,uB),e.symbolsOpen?(a(),l("div",cB,[n("div",pB,c(e.symbols().length)+" "+c(e.symbols().length===1?"symbol":"symbols"),1),(a(!0),l(q,null,Q(e.symbols(),d=>(a(),l("button",{type:"button",class:"symbols-item",role:"menuitem",key:d.line+d.name,onClick:p=>e.goToSymbol(d.line)},[n("span",{class:A(["symbols-kind","is-"+d.kind])},c(d.kind==="class"?"C":d.kind==="function"?"\u0192":"v"),3),n("span",hB,c(d.name),1),n("span",mB,c(d.line),1)],8,fB))),128))])):f("v-if",!0)])):f("v-if",!0),e.type=="html"?(a(),l("button",{key:2,type:"button",class:A(["btn btn-sm btn-ghost btn-icon-only btn-find btn-md-find",{"is-on":e.mdFindOpen}]),"aria-label":"Find on this page",title:"Find on this page ("+(e.isMac?"\u2318":"Ctrl+")+"F)",onClick:t[7]||(t[7]=d=>e.toggleMdFind())},[...t[58]||(t[58]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-search"})],-1)])],10,gB)):f("v-if",!0),e.type!="html"&&!(e.isCsv()&&e.csvView==="table")?(a(),l("div",vB,[e.type!="html"?(a(),l("button",{key:0,type:"button",class:"btn btn-sm btn-ghost btn-icon-only btn-goto","aria-label":"Go to line",title:"Go to line ("+(e.isMac?"\u2318":"Ctrl+")+"G)",onClick:t[8]||(t[8]=d=>e.gotoLine())},[...t[59]||(t[59]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-goto"})],-1)])],8,yB)):f("v-if",!0),e.type!="html"?(a(),l("button",{key:1,type:"button",class:A(["btn btn-sm btn-icon-only btn-ghost btn-toggle",{"is-on":e.wrapLines}]),"aria-pressed":e.wrapLines?"true":"false","aria-label":"Wrap lines",title:"Wrap lines (Alt+Z)",onClick:t[9]||(t[9]=d=>e.toggleWrap())},[...t[60]||(t[60]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-wrap"})],-1)])],10,bB)):f("v-if",!0),e.type!="html"?(a(),l("button",{key:2,type:"button",class:"btn btn-sm btn-ghost btn-icon-only btn-find","aria-label":"Find in file",title:"Find in file ("+(e.isMac?"\u2318":"Ctrl+")+"F)",onClick:t[10]||(t[10]=d=>e.findInFile())},[...t[61]||(t[61]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-search"})],-1)])],8,wB)):f("v-if",!0)])):f("v-if",!0),!e.preview||e.url?(a(),l("div",kB,[n("a",{target:e.preview?"_blank":"_self",class:"tb-seg-btn",title:e.type=="html"?"Open the Markdown source":"Open the raw file",href:e.safeUrl(e.url)},"Raw",8,CB),typeof e.content=="string"?(a(),l("button",{key:0,type:"button",class:"tb-seg-btn tb-seg-icon","aria-label":e.contentCopied?"Copied":"Copy file contents",title:e.contentCopied?"Copied":"Copy file contents",onClick:t[11]||(t[11]=d=>e.copyContent())},[(a(),l("svg",SB,[n("use",{href:e.contentCopied?"#ui-icon-check":"#project-icon-copy"},null,8,NB)]))],8,EB)):f("v-if",!0),n("a",{target:e.preview?"_blank":"_self",class:"tb-seg-btn tb-seg-icon","aria-label":"Download file",title:"Download file",href:e.safeUrl(e.downloadUrl()),download:e.preview?e.paths[e.paths.length-1]:null},[...t[62]||(t[62]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-download"})],-1)])],8,RB)])):f("v-if",!0),typeof e.content=="string"?(a(),l("button",{key:5,type:"button",class:"btn btn-sm btn-icon-only btn-ghost tb-copy-m","aria-label":e.contentCopied?"Copied":"Copy file contents",onClick:t[12]||(t[12]=d=>e.copyContent())},[(a(),l("svg",PB,[n("use",{href:e.contentCopied?"#ui-icon-check":"#project-icon-copy"},null,8,DB)]))],8,AB)):f("v-if",!0),e.type=="html"&&e.readmeToc().length>=3?(a(),l("div",TB,[n("button",{type:"button",class:A(["btn btn-sm btn-icon-only btn-ghost tb-toc-btn",{"is-on":e.tocOpen}]),"aria-label":"On this page",title:"On this page","aria-haspopup":"true","aria-expanded":e.tocOpen?"true":"false",onClick:t[13]||(t[13]=ae(d=>{e.tocOpen=!e.tocOpen,e.moreOpen=!1},["stop"]))},[...t[63]||(t[63]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-outline"})],-1)])],10,OB),e.tocOpen?(a(),l("div",{key:0,class:"tb-menu tb-toc-menu",role:"menu",onClick:t[15]||(t[15]=d=>e.tocOpen=!1)},[t[64]||(t[64]=n("div",{class:"tb-menu-label"},"On this page",-1)),n("button",{type:"button",role:"menuitem",class:A(["tb-menu-toc","lvl-2",{"is-active":!e.activeHeading}]),onClick:t[14]||(t[14]=d=>e.scrollToHeading(null))},"Introduction",2),(a(!0),l(q,null,Q(e.readmeToc(),d=>(a(),l("button",{type:"button",role:"menuitem",key:"m-"+d.id,class:A(["tb-menu-toc","lvl-"+d.level,{"is-active":e.activeHeading===d.id}]),onClick:p=>e.scrollToHeading(d.id)},c(d.text),11,IB))),128))])):f("v-if",!0)])):f("v-if",!0),n("div",MB,[n("button",{type:"button",class:A(["btn btn-sm btn-icon-only btn-ghost tb-more-btn",{"is-on":e.moreOpen}]),"aria-label":"More actions","aria-haspopup":"true","aria-expanded":e.moreOpen?"true":"false",onClick:t[16]||(t[16]=ae(d=>{e.tocOpen=!1,e.moreOpen=!e.moreOpen},["stop"]))},[(a(),l("svg",qB,[...t[65]||(t[65]=[n("circle",{cx:"5",cy:"12",r:"1.8"},null,-1),n("circle",{cx:"12",cy:"12",r:"1.8"},null,-1),n("circle",{cx:"19",cy:"12",r:"1.8"},null,-1)])]))],10,VB),e.moreOpen?(a(),l("div",{key:0,class:"tb-menu",role:"menu",onClick:t[23]||(t[23]=d=>e.moreOpen=!1)},[e.options?.publishedAt||e.options?.sourceCommitDate||e.options?.anonymizedAt||e.options?.lastUpdateDate?(a(),l("div",_B,[t[66]||(t[66]=n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#project-icon-clock"})],-1)),g("Snapshot \xB7 "+c(e.fmt?.date(e.options?.publishedAt||e.options?.sourceCommitDate||e.options?.anonymizedAt||e.options?.lastUpdateDate)),1)])):f("v-if",!0),typeof e.content=="string"?(a(),l("div",LB,[g(c(e.type=="html"?"Markdown":e.languageName||"Text")+" \xB7 "+c(e.type=="html"&&e.fileSize(e.filePath)!=null?e.formatSize(e.fileSize(e.filePath)):e.content.length<1024?e.content.length+" B":(e.content.length/1024).toFixed(1)+" KB"),1),e.type!="html"?(a(),l(q,{key:0},[g(" \xB7 "+c(e.fmt?.number(e.content.split(` -`).length))+" lines",1)],64)):f("v-if",!0)])):f("v-if",!0),e.options?.publishedAt||e.options?.sourceCommitDate||e.options?.anonymizedAt||e.options?.lastUpdateDate?(a(),l("div",$B)):f("v-if",!0),e.type=="html"?(a(),l("button",{key:3,type:"button",role:"menuitem",onClick:t[17]||(t[17]=d=>e.toggleMdFind())},[...t[67]||(t[67]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-search"})],-1),g("Find in file",-1)])])):f("v-if",!0),e.type=="html"?(a(),l("div",FB)):f("v-if",!0),e.type!="html"?(a(),l("button",{key:5,type:"button",role:"menuitem",onClick:t[18]||(t[18]=d=>e.findInFile())},[...t[68]||(t[68]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-search"})],-1),g("Find in file",-1)])])):f("v-if",!0),e.type!="html"?(a(),l("button",{key:6,type:"button",role:"menuitem",onClick:t[19]||(t[19]=d=>e.gotoLine())},[...t[69]||(t[69]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-goto"})],-1),g("Go to line",-1)])])):f("v-if",!0),e.type!="html"?(a(),l("button",{key:7,type:"button",role:"menuitemcheckbox","aria-checked":e.wrapLines?"true":"false",onClick:t[20]||(t[20]=d=>e.toggleWrap())},[t[70]||(t[70]=n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-wrap"})],-1)),t[71]||(t[71]=g("Wrap lines",-1)),e.wrapLines?(a(),l("span",BB,"\u2713")):f("v-if",!0)],8,UB)):f("v-if",!0),e.isCsv()?(a(),l("button",{key:8,type:"button",role:"menuitem",class:"tb-csv-view",onClick:t[21]||(t[21]=d=>{e.csvView=e.csvView==="table"?"raw":"table",e.moreOpen=!1})},[(a(),l("svg",zB,[n("use",{href:e.csvView==="table"?"#ui-icon-code":"#ui-icon-list"},null,8,HB)])),g(c(e.csvView==="table"?"Show as text":"Show as table"),1)])):f("v-if",!0),e.type!="html"?(a(),l("div",jB)):f("v-if",!0),e.type=="html"&&(!e.preview||e.url)?(a(),l("a",{key:10,role:"menuitem",target:e.preview?"_blank":"_self",href:e.safeUrl(e.url)},[...t[72]||(t[72]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-code"})],-1),g("View raw",-1)])],8,GB)):f("v-if",!0),e.type!="html"&&(!e.preview||e.url)?(a(),l("a",{key:11,role:"menuitem",target:e.preview?"_blank":"_self",href:e.safeUrl(e.url)},[...t[73]||(t[73]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-code"})],-1),g("View raw",-1)])],8,WB)):f("v-if",!0),!e.preview||e.url?(a(),l("a",{key:12,role:"menuitem",target:e.preview?"_blank":"_self",href:e.safeUrl(e.downloadUrl()),download:e.preview?e.paths[e.paths.length-1]:null},[...t[74]||(t[74]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-download"})],-1),g("Download file",-1)])],8,KB)):f("v-if",!0),e.options?.hasWebsite?(a(),l("a",{key:13,role:"menuitem",target:e.preview?"_blank":"_self",href:e.safeUrl("/w/"+e.repoId+"/")},[...t[75]||(t[75]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-globe"})],-1),g("Open website",-1)])],8,YB)):f("v-if",!0),e.options?.isAdmin||e.options?.isOwner?(a(),l("a",{key:14,role:"menuitem",href:e.safeUrl("/anonymize/"+e.repoId)},[...t[76]||(t[76]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-edit"})],-1),g("Edit anonymization",-1)])],8,XB)):f("v-if",!0),e.options?.download?(a(),l("a",{key:15,role:"menuitem",target:e.preview?"_blank":"_self",href:e.safeUrl("/api/repo/"+e.repoId+"/zip")},[...t[77]||(t[77]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-archive"})],-1),g("Download ZIP",-1)])],8,JB)):f("v-if",!0),n("button",{type:"button",role:"menuitem",onClick:t[22]||(t[22]=d=>e.copyPath())},[...t[78]||(t[78]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-link"})],-1),g("Copy file path",-1)])]),t[79]||(t[79]=n("div",{class:"tb-menu-sep"},null,-1)),t[80]||(t[80]=n("a",{role:"menuitem",href:"/faq"},[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-help"})]),g("FAQ")],-1)),t[81]||(t[81]=n("a",{role:"menuitem",href:"https://github.com/tdurieux/anonymous_github/issues/new?template=issue_report.yml",target:"_blank",rel:"noopener"},[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-bug"})]),g("Report a bug")],-1))])):f("v-if",!0)])]),e.gotoOpen&&e.type!="html"?(a(),l("form",{key:3,class:"goto-pop",role:"dialog","aria-label":"Go to line",onSubmit:t[26]||(t[26]=ae(d=>e.submitGoto(),["prevent"]))},[t[82]||(t[82]=n("label",{class:"goto-label",for:"goto-input"},"Go to line",-1)),D(n("input",{id:"goto-input",class:"goto-input",type:"text",inputmode:"numeric",autocomplete:"off",spellcheck:"false",placeholder:"1\u2013"+e.fmt?.number(typeof e.content=="string"?e.content.split(` -`).length:1),"aria-invalid":e.gotoError?"true":"false","onUpdate:modelValue":t[24]||(t[24]=d=>e.gotoValue=d),onKeydown:t[25]||(t[25]=kt(ae(d=>e.closeGoto(),["prevent","stop"]),["esc"]))},null,40,QB),[[pt,e.gotoValue]]),n("span",{class:A(["goto-hint",{"is-error":e.gotoError}])},c(e.gotoError||"Line, or line:column"),3)],32)):f("v-if",!0)]),e.isCsv()&&e.csvView==="table"?(a(),l("div",{key:0,class:"csv-table-wrap",tabindex:"0",role:"region","aria-label":"Table view of "+(e.paths?.[e.paths.length-1]||"file")},[n("table",xB,[n("thead",null,[n("tr",null,[t[83]||(t[83]=n("th",{class:"csv-rownum",scope:"col"},[n("span",{class:"sr-only"},"Row")],-1)),(a(!0),l(q,null,Q(e.csvRows()[0]||[],(d,p)=>(a(),l("th",{scope:"col",key:p,class:A({"is-num":e.csvNumCol(p)})},[(a(!0),l(q,null,Q(e.redactParts(d),(u,y)=>(a(),l(q,{key:y},[u.n?(a(),l("span",{key:0,class:"redact-slot",role:"img","aria-label":"Redacted term "+u.n},[n("i",null,c(u.n),1)],8,ez)):(a(),l(q,{key:1},[g(c(u.t),1)],64))],64))),128))],2))),128))])]),n("tbody",null,[(a(!0),l(q,null,Q(e.csvRows().slice(1),(d,p)=>(a(),l("tr",{key:p},[n("td",tz,c(p+1),1),(a(!0),l(q,null,Q(d,(u,y)=>(a(),l("td",{key:y,class:A({"is-num":e.csvNumCol(y)})},[(a(!0),l(q,null,Q(e.redactParts(u),(m,b)=>(a(),l(q,{key:b},[m.n?(a(),l("span",{key:0,class:"redact-slot",role:"img","aria-label":"Redacted term "+m.n},[n("i",null,c(m.n),1)],8,nz)):(a(),l(q,{key:1},[g(c(m.t),1)],64))],64))),128))],2))),128))]))),128))])])],8,ZB)):f("v-if",!0),e.type!="html"&&!(e.isCsv()&&e.csvView==="table")?D((a(),l("div",sz,null,512)),[[r,{content:e.content,options:e.aceOption}]]):f("v-if",!0),e.type=="html"&&e.mdFindOpen?(a(),l("div",oz,[n("input",{type:"search",class:"md-find-input",placeholder:"Find on this page","aria-label":"Find on this page",value:e.mdFindQuery,onInput:t[27]||(t[27]=d=>{e.mdFindQuery=d.target.value,e.runMdFind()}),onKeydown:[t[28]||(t[28]=kt(ae(d=>d.shiftKey?e.stepMdFind(-1):e.stepMdFind(1),["prevent"]),["enter"])),t[29]||(t[29]=kt(ae(d=>e.toggleMdFind(!1),["prevent"]),["esc"]))]},null,40,iz),n("span",rz,[n("button",{type:"button","aria-label":"Previous match",onClick:t[30]||(t[30]=d=>e.stepMdFind(-1)),disabled:!e.mdFindTotal},[...t[84]||(t[84]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-chevron-left"})],-1)])],8,az),n("button",{type:"button","aria-label":"Next match",onClick:t[31]||(t[31]=d=>e.stepMdFind(1)),disabled:!e.mdFindTotal},[...t[85]||(t[85]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-chevron-right"})],-1)])],8,lz)]),n("span",dz,c(e.mdFindQuery?e.mdFindTotal?e.mdFindIndex+1+" of "+e.mdFindTotal:"No results":""),1),n("button",{type:"button",class:A(["md-find-opt",{"is-on":e.mdFindCase}]),"aria-pressed":e.mdFindCase?"true":"false",title:"Match case","aria-label":"Match case",onClick:t[32]||(t[32]=d=>{e.mdFindCase=!e.mdFindCase,e.runMdFind()})},"Aa",10,uz),n("button",{type:"button",class:"md-find-close","aria-label":"Close find",onClick:t[33]||(t[33]=d=>e.toggleMdFind(!1))},"\xD7")])):f("v-if",!0),e.type=="html"?(a(),l("div",cz,[n("div",{class:"file-content markdown-body",innerHTML:e.renderReadme(e.sanitize(e.content))},null,8,pz),e.readmeToc().length>=3?(a(),l("aside",fz,[t[86]||(t[86]=n("div",{class:"readme-toc-head"},"On this page",-1)),n("nav",hz,[n("a",{href:"#",class:A(["lvl-2 toc-top",{"is-active":!e.activeHeading}]),onClick:t[34]||(t[34]=ae(d=>e.scrollToHeading(null),["prevent"]))},"Introduction",2),(a(!0),l(q,null,Q(e.readmeToc(),(d,p)=>(a(),l("a",{key:d.id,href:"#"+d.id,class:A(["lvl-"+d.level,{"is-active":e.activeHeading===d.id}]),onClick:ae(u=>e.scrollToHeading(d.id),["prevent"])},c(d.text),11,mz))),128))])])):f("v-if",!0)])):f("v-if",!0)],2)):f("v-if",!0),e.type=="html-doc"&&!e.showSource&&e.content!=null?(a(),Wt(s,{key:2,content:e.content,"base-url":e.fileBaseUrl,"allow-scripts":e.allowScripts},null,8,["content","base-url","allow-scripts"])):f("v-if",!0),e.fileFrame()?(a(),l("section",{key:3,class:A(["file-card file-card-media","view-"+e.type])},[n("header",gz,[n("div",vz,[n("button",{type:"button",class:A(["btn btn-sm btn-icon-only btn-ghost card-files-btn",{"is-needed":e.sidebarHidden}]),title:"Show file tree",onClick:t[35]||(t[35]=d=>e.sidebarHidden?e.sidebarHidden=!1:e.sidebarCollapsed=!1)},[...t[87]||(t[87]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-sidebar"})],-1),n("span",{class:"card-files-label"},"Files",-1)])],2),n("ol",yz,[n("li",bz,[n("a",{href:e.safeUrl("/r/"+e.repoId+"/"),title:e.repoId,textContent:c(/^[0-9a-f]{8}-[0-9a-f]{4}-/i.test(e.repoId||"")?"repository":e.repoId)},null,8,wz)]),(a(!0),l(q,null,Q(e.paths,(d,p)=>(a(),l("li",{class:"breadcrumb-item","aria-current":p===e.paths.length-1?"page":null},[(a(!0),l(q,null,Q(e.redactParts(d),(u,y)=>(a(),l(q,{key:y},[u.n?(a(),l("span",{key:0,class:"redact-slot",role:"img","aria-label":"Redacted term "+u.n},[n("i",null,c(u.n),1)],8,Cz)):(a(),l(q,{key:1},[g(c(u.t),1)],64))],64))),128))],8,kz))),256))]),n("span",Ez,[e.type=="IPython"&&e.redactionCount()?(a(),l("b",{key:0,class:"ms-item ms-redact",title:e.redactionCount()+" redacted terms"},[g(c(e.redactionCount()),1),t[88]||(t[88]=n("span",{class:"meta-redact-word"}," redacted",-1))],8,Sz)):f("v-if",!0),n("span",Nz,c(e.fileKind()),1),e.imageSize?(a(),l("span",Rz,c(e.imageSize),1)):f("v-if",!0),e.fileSize(e.filePath)!=null?(a(),l("span",Az,c(e.formatSize(e.fileSize(e.filePath))),1)):f("v-if",!0)]),D(n("button",{type:"button",class:"btn btn-sm btn-icon-only btn-ghost copy-path-btn","aria-label":e.pathCopied?"Path copied":"Copy file path",title:e.pathCopied?"Path copied":"Copy file path",onClick:t[36]||(t[36]=d=>e.copyPath())},[(a(),l("svg",Dz,[n("use",{href:e.pathCopied?"#ui-icon-check":"#ui-icon-link"},null,8,Tz)]))],8,Pz),[[Z,e.filePath]])]),n("span",Oz,[e.type=="IPython"&&e.redactionCount()?(a(),l(q,{key:0},[n("span",{class:"meta-redact",title:e.redactionCount()+" redacted terms"},[g(c(e.redactionCount()),1),t[89]||(t[89]=n("span",{class:"meta-redact-word"}," redacted",-1))],8,Iz),t[90]||(t[90]=n("span",{class:"sep"},"\xB7",-1))],64)):f("v-if",!0),g(c(e.fileKind()),1),e.imageSize?(a(),l(q,{key:1},[t[91]||(t[91]=n("span",{class:"sep"},"\xB7",-1)),g(c(e.imageSize),1)],64)):f("v-if",!0),e.fileSize(e.filePath)!=null?(a(),l(q,{key:2},[t[92]||(t[92]=n("span",{class:"sep"},"\xB7",-1)),g(c(e.formatSize(e.fileSize(e.filePath))),1)],64)):f("v-if",!0)]),e.preview&&e.previewPreserved()?(a(),l("button",{key:0,type:"button",class:"rp-preserved-tag",onClick:t[37]||(t[37]=d=>e.openPreserveFiles())},"Left unredacted")):f("v-if",!0),n("div",Mz,[e.type=="error"&&e.content==="file_too_big"?(a(),l("span",Vz,[...t[93]||(t[93]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-info"})],-1),g("Over the size limit",-1)])])):f("v-if",!0),e.type!="error"&&(!e.preview||e.url)?(a(),l("div",qz,[n("a",{target:e.preview?"_blank":"_self",class:"tb-seg-btn",title:e.type=="IPython"?"Open the notebook JSON":"Open the raw file",href:e.safeUrl(e.url)},"Raw",8,_z),n("a",{target:e.preview?"_blank":"_self",class:"tb-seg-btn tb-seg-icon","aria-label":"Download file",title:"Download file",href:e.safeUrl(e.downloadUrl()),download:e.preview?e.paths[e.paths.length-1]:null},[...t[94]||(t[94]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-download"})],-1)])],8,Lz)])):f("v-if",!0),n("div",$z,[n("button",{type:"button",class:A(["btn btn-sm btn-icon-only btn-ghost tb-more-btn",{"is-on":e.moreOpen}]),"aria-label":"More actions","aria-haspopup":"true","aria-expanded":e.moreOpen?"true":"false",onClick:t[38]||(t[38]=ae(d=>e.moreOpen=!e.moreOpen,["stop"]))},[(a(),l("svg",Uz,[...t[95]||(t[95]=[n("circle",{cx:"5",cy:"12",r:"1.8"},null,-1),n("circle",{cx:"12",cy:"12",r:"1.8"},null,-1),n("circle",{cx:"19",cy:"12",r:"1.8"},null,-1)])]))],10,Fz),e.moreOpen?(a(),l("div",{key:0,class:"tb-menu",role:"menu",onClick:t[40]||(t[40]=d=>e.moreOpen=!1)},[e.options?.publishedAt||e.options?.sourceCommitDate||e.options?.anonymizedAt||e.options?.lastUpdateDate?(a(),l("div",Bz,[t[96]||(t[96]=n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#project-icon-clock"})],-1)),g("Snapshot \xB7 "+c(e.fmt?.date(e.options?.publishedAt||e.options?.sourceCommitDate||e.options?.anonymizedAt||e.options?.lastUpdateDate)),1)])):f("v-if",!0),e.options?.publishedAt||e.options?.sourceCommitDate||e.options?.anonymizedAt||e.options?.lastUpdateDate?(a(),l("div",zz)):f("v-if",!0),e.type!="error"&&(!e.preview||e.url)?(a(),l("a",{key:2,role:"menuitem",target:e.preview?"_blank":"_self",href:e.safeUrl(e.url)},[t[97]||(t[97]=n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-code"})],-1)),g(c(e.type=="IPython"?"View notebook JSON":"View raw"),1)],8,Hz)):f("v-if",!0),e.type!="error"&&(!e.preview||e.url)?(a(),l("a",{key:3,role:"menuitem",target:e.preview?"_blank":"_self",href:e.safeUrl(e.downloadUrl()),download:e.preview?e.paths[e.paths.length-1]:null},[...t[98]||(t[98]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-download"})],-1),g("Download file",-1)])],8,jz)):f("v-if",!0),e.options?.download?(a(),l("a",{key:4,role:"menuitem",target:e.preview?"_blank":"_self",href:e.safeUrl("/api/repo/"+e.repoId+"/zip")},[...t[99]||(t[99]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-archive"})],-1),g("Download ZIP",-1)])],8,Gz)):f("v-if",!0),n("button",{type:"button",role:"menuitem",onClick:t[39]||(t[39]=d=>e.copyPath())},[...t[100]||(t[100]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-link"})],-1),g("Copy file path",-1)])]),t[101]||(t[101]=n("div",{class:"tb-menu-sep"},null,-1)),t[102]||(t[102]=n("a",{role:"menuitem",href:"/faq"},[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-help"})]),g("FAQ")],-1)),t[103]||(t[103]=n("a",{role:"menuitem",href:"https://github.com/tdurieux/anonymous_github/issues/new?template=issue_report.yml",target:"_blank",rel:"noopener"},[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-bug"})]),g("Report a bug")],-1))])):f("v-if",!0)])])]),e.type=="image"?(a(),l("div",Wz,[n("img",{class:"image-content",src:e.safeUrl(e.url),alt:e.paths[e.paths.length-1],onLoad:t[41]||(t[41]=d=>e.onImageLoad(d))},null,40,Kz)])):f("v-if",!0),e.type=="media"?(a(),l("div",Yz,[n("video",{class:"video-content",controls:"",preload:"metadata",playsinline:"",src:e.safeUrl(e.url)},null,8,Xz)])):f("v-if",!0),e.type=="audio"?(a(),l("div",Jz,[n("audio",{controls:"",preload:"metadata",src:e.safeUrl(e.url)},null,8,Qz)])):f("v-if",!0),e.type=="pdf"?(a(),Wt(i,{key:3,src:e.safeUrl(e.url)},null,8,["src"])):f("v-if",!0),e.type=="IPython"?(a(),l("div",Zz,[Oe(o,{class:"markdown-body",file:e.url,content:e.content},null,8,["file","content"])])):f("v-if",!0),e.type=="binary"?(a(),l("div",xz,[t[105]||(t[105]=n("svg",{class:"ui-icon file-state-icon","aria-hidden":"true"},[n("use",{href:"#project-icon-file"})],-1)),t[106]||(t[106]=n("h2",{class:"file-state-title"},"No preview for this file",-1)),n("p",eH,c(e.preview?"Reviewers can open this file; it is not previewed here.":"This is a binary file. Download it to open it on your computer."),1),e.preview?f("v-if",!0):(a(),l("div",tH,[n("a",{target:e.preview?"_blank":"_self",class:"btn btn-primary",href:e.safeUrl(e.downloadUrl()),download:e.preview?e.paths[e.paths.length-1]:null},[...t[104]||(t[104]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-download"})],-1),g("Download file",-1)])],8,nH)]))])):f("v-if",!0),e.type=="error"?(a(),l("div",sH,[t[108]||(t[108]=n("svg",{class:"ui-icon file-state-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-warning"})],-1)),n("h2",oH,c(e.content==="file_too_big"?"This file is too large to preview":"This file can't be shown"),1),e.content==="file_too_big"?(a(),l("p",iH,c(e.preview?"Reviewers can open this file; it is not previewed here. Files over 1 MB are only shown on the reviewer page.":"It is over the size limit for anonymized files, so it can't be previewed or downloaded from this link."),1)):(a(),l("p",rH,c(e.fmt.translate("ERRORS."+e.content)),1)),e.preview?f("v-if",!0):(a(),l("div",aH,[n("a",{class:"btn btn-primary",href:e.safeUrl("/r/"+e.repoId+"/")},"Back to the repository",8,lH),t[107]||(t[107]=n("a",{class:"btn btn-outline-ink",href:"/faq#formats"},"Supported files",-1))]))])):f("v-if",!0),e.content==null&&e.type!="error"?(a(),l("div",dH,[...t[109]||(t[109]=[n("svg",{class:"ui-icon file-state-icon","aria-hidden":"true"},[n("use",{href:"#project-icon-file"})],-1),n("h2",{class:"file-state-title"},"This file is empty",-1),n("p",{class:"file-state-msg"},"It has no content in this snapshot.",-1)])])):f("v-if",!0)],2)):f("v-if",!0),e.type=="rate_limited"?(a(),l("div",uH,[n("div",cH,[t[112]||(t[112]=Ce('
Temporarily paused
GitHub API rate limit reached
',1)),n("p",pH,[t[110]||(t[110]=g("This repository will be available in ",-1)),n("strong",null,c(e.rateLimitCountdown),1),t[111]||(t[111]=g(". The page will reload automatically.",-1))])])])):f("v-if",!0),e.type=="error"&&!e.fileFrame()?(a(),l("div",fH,[n("section",hH,[n("h1",mH,c(e.fmt.translate(e.isSourceAccessError()?"VIEWER_ERRORS.access_title":"VIEWER_ERRORS.title")),1),n("p",null,c(e.fmt.translate("ERRORS."+e.content)),1),e.isSourceAccessError()?(a(),l(q,{key:0},[n("p",null,c(e.fmt.translate("VIEWER_ERRORS.reader_help")),1),n("p",null,c(e.fmt.translate("VIEWER_ERRORS.owner_help")),1)],64)):f("v-if",!0),n("div",gH,[e.isSourceAccessError()?f("v-if",!0):(a(),l("a",vH,"Back to home")),e.isSourceAccessError()?f("v-if",!0):(a(),l("a",yH,"Read the FAQ")),n("button",{type:"button",class:"btn btn-primary",onClick:t[42]||(t[42]=d=>e.retryContent())},c(e.fmt.translate("VIEWER_ERRORS.retry")),1),e.isSourceAccessError()?(a(),l("a",bH,c(e.fmt.translate("VIEWER_ERRORS.dashboard")),1)):f("v-if",!0)])])])):f("v-if",!0),e.type=="loading"&&!e.error?(a(),l("section",wH,[n("div",kH,[n("strong",null,c(e.fmt.translate(e.fileReceivedBytes?"VIEWER_LOADING.receiving":"VIEWER_LOADING.loading")),1),n("span",CH,c(e.filePath),1),e.fileLoadingSlow?(a(),l("p",EH,c(e.fmt.translate("VIEWER_LOADING.slow")),1)):f("v-if",!0)]),n("div",SH,[(a(),l(q,null,Q(10,d=>n("span",{key:d})),64))])])):f("v-if",!0),e.type=="empty"?(a(),l("div",NH,[...t[113]||(t[113]=[n("h1",{class:"paper-empty-title m-auto"},[g("Empty "),n("em",null,"repository"),g(".")],-1)])])):f("v-if",!0),e.content==null&&!["empty","loading","error","rate_limited"].includes(e.type)&&!e.fileFrame()?(a(),l("div",RH,[...t[114]||(t[114]=[n("h1",{class:"paper-empty-title m-auto"},[g("Empty "),n("em",null,"file"),g(".")],-1)])])):f("v-if",!0)],64)}var AH={class:"container page dashboard-page paper-page"},PH={class:"row"},DH={class:"w-100"},TH={class:"w-100","aria-label":"Pull Requests","accept-charset":"UTF-8"},OH={class:"d-flex flex-column flex-md-row align-items-md-center",style:{gap:"8px"}},IH={class:"flex-grow-1"},MH={type:"search",id:"search",class:"form-control","aria-label":"Find a pull request...",placeholder:"Find a pull request...",autocomplete:"off"},VH={class:"d-flex flex-wrap",style:{gap:"6px"}},qH={class:"dropdown"},_H={class:"dropdown-menu","aria-labelledby":"dropdownSort"},LH={class:"form-check dropdown-item"},$H={class:"form-check-input",type:"radio",name:"sort",id:"sortFullName",value:"fullName"},FH={class:"form-check dropdown-item"},UH={class:"form-check-input",type:"radio",name:"sort",id:"sortAnonymizeDate",value:"-anonymizeDate"},BH={class:"form-check dropdown-item"},zH={class:"form-check-input",type:"radio",name:"sort",id:"sortStatus",value:"-status"},HH={class:"form-check dropdown-item"},jH={class:"form-check-input",type:"radio",name:"sort",id:"sortLastView",value:"-lastView"},GH={class:"form-check dropdown-item"},WH={class:"form-check-input",type:"radio",name:"sort",id:"sortPageView",value:"-pageView"},KH={class:"dropdown"},YH={class:"dropdown-menu","aria-labelledby":"dropdownStatus"},XH={class:"form-check dropdown-item"},JH={class:"form-check-input",type:"checkbox",name:"sort",id:"statusReady",value:"ready"},QH={class:"form-check dropdown-item"},ZH={class:"form-check-input",type:"checkbox",name:"sort",id:"statusExpired",value:"expired"},xH={class:"form-check dropdown-item"},ej={class:"form-check-input",type:"checkbox",name:"sort",id:"statusRemoved",value:"removed"},tj={class:"d-flex flex-wrap mt-2",style:{gap:"6px"}},nj={class:"filter-chip"},sj=["onClick"],oj={class:"repo-list w-100"},ij={class:"repo-list-item-content"},rj={class:"repo-list-item-main"},aj={class:"repo-list-item-header"},lj=["textContent","href"],dj=["textContent"],uj=["textContent"],cj={class:"repo-source"},pj=["href"],fj={class:"repo-date"},hj={class:"repo-meta"},mj={key:0,title:"Conference"},gj=["title"],vj=["title"],yj=["title"],bj={key:1},wj={class:"repo-list-item-actions"},kj={class:"dropdown"},Cj={class:"dropdown-menu dropdown-menu-right"},Ej=["href"],Sj=["onClick"],Nj=["onClick"],Rj=["onClick"],Aj=["href"],Pj={key:0,class:"repo-list-empty"};function kp(e,t){let s=Pe("field"),i=Pe("form");return a(),l("div",AH,[n("div",PH,[n("div",DH,[t[12]||(t[12]=Ce('
My work \xA0/\xA0 Pull requests

Anonymized pull requests

Track PR mirrors you\u2019ve created and their reviewer traffic.

',2)),f(" Search + filters row "),D((a(),l("form",TH,[n("div",OH,[n("div",IH,[D(n("input",MH,null,512),[[s,{state:e.viewState,set:o=>{e.search=o},value:e.search,form:null,options:{}}]])]),n("div",VH,[n("div",qH,[t[6]||(t[6]=n("button",{class:"btn btn-sm dropdown-toggle",type:"button",id:"dropdownSort","data-toggle":"dropdown","aria-haspopup":"true","aria-expanded":"false"}," Sort ",-1)),n("div",_H,[t[5]||(t[5]=n("h6",{class:"dropdown-header"},"Select order",-1)),n("div",LH,[D(n("input",$H,null,512),[[s,{state:e.viewState,set:o=>{e.orderBy=o},value:e.orderBy,form:null,options:{}}]]),t[0]||(t[0]=n("label",{class:"form-check-label",for:"sortFullName"},"Pull Request",-1))]),n("div",FH,[D(n("input",UH,null,512),[[s,{state:e.viewState,set:o=>{e.orderBy=o},value:e.orderBy,form:null,options:{}}]]),t[1]||(t[1]=n("label",{class:"form-check-label",for:"sortAnonymizeDate"},"Anonymize Date",-1))]),n("div",BH,[D(n("input",zH,null,512),[[s,{state:e.viewState,set:o=>{e.orderBy=o},value:e.orderBy,form:null,options:{}}]]),t[2]||(t[2]=n("label",{class:"form-check-label",for:"sortStatus"},"Status",-1))]),n("div",HH,[D(n("input",jH,null,512),[[s,{state:e.viewState,set:o=>{e.orderBy=o},value:e.orderBy,form:null,options:{}}]]),t[3]||(t[3]=n("label",{class:"form-check-label",for:"sortLastView"},"Last View",-1))]),n("div",GH,[D(n("input",WH,null,512),[[s,{state:e.viewState,set:o=>{e.orderBy=o},value:e.orderBy,form:null,options:{}}]]),t[4]||(t[4]=n("label",{class:"form-check-label",for:"sortPageView"},"Page View",-1))])])]),n("div",KH,[t[11]||(t[11]=n("button",{class:"btn btn-sm dropdown-toggle",type:"button",id:"dropdownStatus","data-toggle":"dropdown","aria-haspopup":"true","aria-expanded":"false"}," Status ",-1)),n("div",YH,[t[10]||(t[10]=n("h6",{class:"dropdown-header"},"Select status",-1)),n("div",XH,[D(n("input",JH,null,512),[[s,{state:e.viewState,set:o=>{e.filters.status.ready=o},value:e.filters?.status?.ready,form:null,options:{}}]]),t[7]||(t[7]=n("label",{class:"form-check-label",for:"statusReady"},"Ready",-1))]),n("div",QH,[D(n("input",ZH,null,512),[[s,{state:e.viewState,set:o=>{e.filters.status.expired=o},value:e.filters?.status?.expired,form:null,options:{}}]]),t[8]||(t[8]=n("label",{class:"form-check-label",for:"statusExpired"},"Expired",-1))]),n("div",xH,[D(n("input",ej,null,512),[[s,{state:e.viewState,set:o=>{e.filters.status.removed=o},value:e.filters?.status?.removed,form:null,options:{}}]]),t[9]||(t[9]=n("label",{class:"form-check-label",for:"statusRemoved"},"Removed",-1))])])])])])])),[[i,e.viewState]]),f(" Active filter chips "),D(n("div",tj,[(a(!0),l(q,null,Q(e.filters?.status,(o,r,d)=>D((a(),l("span",nj,[g(c(e.fmt?.title(r))+" ",1),n("button",{type:"button",class:"filter-chip-close","aria-label":"Remove filter",onClick:p=>{e.filters.status[r]=!0}}," \xD7 ",8,sj)],512)),[[Z,!o]])),256))],512),[[Z,e.filters?.status?.ready===!1||e.filters?.status?.expired===!1||e.filters?.status?.removed===!1]])]),f(" Pull request list "),n("ul",oj,[(a(!0),l(q,null,Q(e.filteredPullRequests,(o,r)=>(a(),l("li",{class:A(["repo-list-item",{"repo-inactive":o?.status=="expired"||o?.status=="removed"||o?.status=="error"}])},[n("div",ij,[n("div",rj,[n("div",aj,[n("a",{class:"repo-name",textContent:c(o?.pullRequestId),href:e.safeUrl("/pr/"+o?.pullRequestId)},null,8,lj),n("span",{class:A(["status-badge",{"status-removed":o?.status=="removed"||o?.status=="expired"||o?.status=="removing"||o?.status=="expiring","status-preparing":o?.status=="preparing"||o?.status=="download","status-ready":o?.status=="ready","status-error":o?.status=="error"}])},[n("span",{textContent:c(e.fmt?.title(o?.status))},null,8,dj),o?.status=="error"?(a(),l("span",{key:0,textContent:c(": "+o?.statusMessage)},null,8,uj)):f("v-if",!0)],2)]),n("div",cj,[n("span",null,[t[13]||(t[13]=n("i",{class:"fab fa-github","aria-hidden":"true"},null,-1)),n("a",{href:e.safeUrl("https://github.com/"+o?.source?.repositoryFullName+"/pull/"+o?.source?.pullRequestId)},c(o?.source?.repositoryFullName)+"#"+c(o?.source?.pullRequestId),9,pj)]),n("span",{class:A(["status-badge",{"status-ready":o?.merged,"status-removed":o?.state=="open","status-error":o?.state=="closed"&&!o?.merged}]),style:{"font-size":"10px"}},c(e.fmt?.title(o?.merged?"merged":o?.state)),3),n("span",fj,"anonymized "+c(e.fmt?.humanTime(o?.anonymizeDate)),1)])]),n("div",hj,[o?.conference?(a(),l("span",mj,[t[14]||(t[14]=n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#project-icon-conference"})],-1)),g(" "+c(o?.conference),1)])):f("v-if",!0),n("span",{"data-toggle":"tooltip","data-placement":"bottom",title:"Terms: "+o?.options?.terms?.join(", ")},[t[15]||(t[15]=n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-shield"})],-1)),g(" "+c(e.fmt?.number(o?.options?.terms?.length)),1)],8,gj),n("span",{"data-toggle":"tooltip","data-placement":"bottom",title:"Views: "+e.fmt?.number(o?.pageView)},[t[16]||(t[16]=n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#project-icon-eye"})],-1)),g(" "+c(e.fmt?.number(o?.pageView)),1)],8,vj),n("span",{"data-toggle":"tooltip","data-placement":"bottom",title:"Last view: "+e.fmt?.date(o?.lastView)},[t[17]||(t[17]=n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-calendar"})],-1)),g(" "+c(e.fmt?.humanTime(o?.lastView)),1)],8,yj),o?.options?.expirationMode!="never"&&o?.status=="ready"?(a(),l("span",bj,[t[18]||(t[18]=n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#project-icon-clock"})],-1)),g(" Expire: "+c(e.fmt?.humanTime(o?.options?.expirationDate)),1)])):f("v-if",!0)])]),n("div",wj,[n("div",kj,[t[24]||(t[24]=n("button",{class:"btn btn-sm dropdown-toggle",type:"button","data-toggle":"dropdown","aria-haspopup":"true","aria-expanded":"false"}," Actions ",-1)),n("div",Cj,[n("a",{class:"dropdown-item",href:e.safeUrl("/pull-request-anonymize/"+o?.pullRequestId)},[...t[19]||(t[19]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-edit"})],-1),g(" Edit ",-1)])],8,Ej),D(n("a",{class:"dropdown-item",href:"#",onClick:ae(d=>e.updatePullRequest(o),["prevent"])},[...t[20]||(t[20]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-refresh"})],-1),g(" Force update ",-1)])],8,Sj),[[Z,o?.status=="ready"||o?.status=="error"]]),D(n("a",{class:"dropdown-item",href:"#",onClick:ae(d=>e.updatePullRequest(o),["prevent"])},[...t[21]||(t[21]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-check-circle"})],-1),g(" Enable ",-1)])],8,Nj),[[Z,o?.status=="removed"]]),D(n("a",{class:"dropdown-item",href:"#",onClick:ae(d=>e.removePullRequest(o),["prevent"])},[...t[22]||(t[22]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-trash"})],-1),g(" Remove ",-1)])],8,Rj),[[Z,o?.status=="ready"]]),n("a",{class:"dropdown-item",href:e.safeUrl("/pr/"+o?.pullRequestId+"/")},[...t[23]||(t[23]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#project-icon-eye"})],-1),g(" View PR ",-1)])],8,Aj)])])])],2))),256)),e.filteredPullRequests?.length==0?(a(),l("li",Pj,[...t[25]||(t[25]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#project-icon-inbox"})],-1),n("span",null,"No pull requests to display.",-1)])])):f("v-if",!0)])])])}var Dj={class:"container paper-page user-settings"},Tj={class:"settings-nav","aria-label":"Settings"},Oj=["aria-current","onClick"],Ij={class:"settings-row"},Mj=["rows"],Vj={class:"settings-syntax"},qj={class:"invalid-feedback"},_j={class:"settings-row"},Lj={class:"settings-checks"},$j={class:"settings-check"},Fj={class:"form-check-input",type:"checkbox",id:"link",name:"link"},Uj={class:"settings-check"},Bj={class:"form-check-input",type:"checkbox",id:"image",name:"image"},zj={class:"settings-check"},Hj={class:"form-check-input",type:"checkbox",id:"pdf",name:"pdf"},jj={class:"settings-check"},Gj={class:"form-check-input",type:"checkbox",id:"notebook",name:"notebook"},Wj={class:"settings-check"},Kj={class:"form-check-input",type:"checkbox",id:"loc",name:"loc"},Yj={class:"settings-check"},Xj={class:"form-check-input",type:"checkbox",id:"page",name:"page"},Jj={class:"settings-row"},Qj={class:"settings-check"},Zj={class:"form-check-input",type:"checkbox",id:"update",name:"update"},xj={class:"settings-row"},eG={class:"form-control",id:"expiration",name:"expiration"},tG={class:"settings-help"},nG={class:"settings-save"},sG={class:"settings-save-status draft-status",role:"status"},oG={key:0},iG={key:1},rG={key:2},aG=["disabled"],lG={key:1,class:"settings-save-error",role:"alert"},dG=["aria-busy"],uG={key:0,role:"status"},cG={key:1,class:"settings-notice",role:"alert"},pG=["disabled"],fG={key:2,class:"settings-notice",role:"status"},hG={key:3,class:"settings-notice",role:"status"},mG=["disabled"],gG={class:"billing-summary"},vG={class:"billing-summary-head"},yG={class:"billing-plan-name"},bG={key:0,class:"billing-plan-meta"},wG={key:1,class:"billing-plan-meta"},kG={key:0,class:"billing-summary-actions"},CG=["disabled"],EG={id:"settings-quota"},SG={key:1,role:"status"},NG={key:0,class:"settings-notice"},RG={key:1,class:"settings-notice"},AG={key:2,class:"settings-notice"},PG={key:4,class:"billing-section","aria-labelledby":"settings-plan-comparison"},DG={key:0,class:"billing-offers"},TG={key:0,class:"billing-offer is-recommended"},OG={class:"billing-offer-price"},IG={class:"billing-offer-list"},MG=["disabled"],VG={key:1,class:"billing-offer"},qG={class:"billing-offer-head"},_G={class:"billing-toggle",role:"radiogroup","aria-label":"Billing frequency"},LG=["aria-checked","onClick"],$G={key:0,class:"billing-toggle-save"},FG={class:"billing-offer-price"},UG={class:"billing-offer-list"},BG=["disabled"],zG={key:1,class:"billing-addons"},HG={class:"billing-addon-rows"},jG={class:"billing-addon-price"},GG=["onClick","disabled"],WG={key:2,class:"billing-buy",id:"settings-addons-title",tabindex:"-1"},KG={class:"billing-buy-info"},YG={class:"billing-offer-price"},XG={class:"billing-offer-list"},JG={class:"billing-buy-form"},QG=["value"],ZG=["disabled"],xG={key:1,class:"billing-buy-desc"},eW={key:2,class:"billing-footnote"},tW={class:"billing-compare"},nW={class:"billing-compare-card"},sW={class:"settings-comparison"},oW={key:0,scope:"col",class:"is-recommended"},iW={key:1,scope:"col"},rW={key:0,class:"is-recommended"},aW={key:1},lW={key:0,class:"is-recommended"},dW={key:1},uW={key:0,class:"is-recommended"},cW={key:1},pW={key:0,class:"is-recommended"},fW={key:1},hW={key:0,class:"is-recommended"},mW={key:1},gW={key:0,class:"is-recommended"},vW={key:1},yW={key:3,class:"billing-footnote"},bW={key:5,class:"billing-section"},wW={class:"billing-section-head"},kW=["disabled"],CW={key:0,class:"billing-empty"},EW={key:1,class:"billing-history-head","aria-hidden":"true"},SW={key:2,class:"billing-history"},NW={class:"billing-history-main"},RW=["href"],AW=["href"],PW={class:"billing-history-term"},DW={class:"billing-history-paid"},TW={class:"billing-history-status"},OW={class:"billing-manage"},IW={key:0},MW={key:1},VW=["disabled"],qW={class:"billing-conference"},_W={id:"settings-account",class:"settings-account-panel"},LW={class:"paper-account-card"},$W=["src"],FW={class:"paper-account-identity"},UW={class:"paper-account-name"},BW=["disabled"],zW={key:0,role:"status"},HW={key:1,class:"paper-inline-alert paper-inline-alert-error",role:"alert"},jW=["disabled"],GW={key:3,role:"status"},WW={class:"paper-danger-zone"},KW={key:0,class:"paper-inline-alert paper-inline-alert-error",role:"alert"},YW=["textContent"],XW=["disabled"],JW={key:1,class:"settings-delete-confirm"},QW={for:"delete-username"},ZW={class:"settings-actions"},xW=["disabled"],eK=["disabled"];function Cp(e,t){let s=Xe("quota-usage"),i=Pe("field"),o=Pe("form");return a(),l("div",Dj,[t[107]||(t[107]=n("header",{class:"settings-title page-head page-head-main"},[n("h1",null,"Settings"),n("p",{class:"paper-page-lede"},"Defaults for new anonymizations, hosting and your account.")],-1)),n("nav",Tj,[(a(),l(q,null,Q([{id:"defaults",label:"Anonymization defaults"},{id:"billing",label:"Hosting & billing"},{id:"account",label:"Account"}],r=>n("button",{type:"button","aria-current":e.settingsTab===r.id?"page":null,onClick:d=>e.settingsTab=r.id},c(r.label),9,Oj)),64))]),D(n("div",null,[t[41]||(t[41]=n("p",{class:"settings-scope"},"For new anonymizations only. Existing repositories keep their settings.",-1)),D((a(),l("form",{class:"form needs-validation",name:"defaultsForm",novalidate:"",onInput:t[1]||(t[1]=r=>e.unsavedChanges=!0),onSubmit:t[2]||(t[2]=ae(r=>e.submitForm(r,()=>{e.saveDefault(r)}),["prevent"]))},[n("section",Ij,[t[26]||(t[26]=n("div",null,[n("label",{class:"settings-label",for:"terms"},"Terms to redact"),n("p",{class:"settings-help"},"One term per line.")],-1)),n("div",null,[D(n("textarea",{class:"form-control",id:"terms",name:"terms",rows:Math.min(14,Math.max(3,String(e.terms||"").split(` +10 log("epoch %d: %.3f", epoch, loss)
`,2)])])):(a(),l("div",r9,[...t[21]||(t[21]=[Ce('
ProjectStatusViewsExpires
DeepLearnUtilspaper-7f2a \xB7 ICSE 2027Ready41Mar 31, 2027
vision-bench#212pull request \xB7 FSE 2027Ready12Never
graph-repairgr-91abUpdating5Jan 5, 2027
JarSiftOOPSLA 2025Expired72Sep 28, 2026
',5)])]))],10,s9)])],8,x7)),[[Z,e.feature===i?.key]])),128))])]),f(" FAQ teaser "),t[24]||(t[24]=Ce('
Before you sign in

The questions that come up most.

Read the full FAQ \u2192
What access does GitHub sign-in require?

The GitHub App has read-only access to gists and the repositories you choose. Legacy OAuth uses broader permissions. Anonymous GitHub never writes to your repositories.

Which file formats are supported?

Source code with syntax highlighting, Markdown, Jupyter notebooks, PDFs, images, and GitHub Pages sites. Text files are anonymized; enabled images and PDFs are served unchanged.

What happens when an anonymized repository expires?

You choose: the mirror is removed, or visitors are redirected to the original GitHub repository once the review is over.

Ready for review?

Create an anonymous mirror in a couple of minutes. Reviewers just open the link.

',2)),Ie(s,{name:"partials/footer.htm",state:e.viewState},null,8,["state"])])}var a9={class:"paper-empty"},l9={class:"paper-empty-inner"},d9={key:0,class:"paper-eyebrow"},u9={key:1,class:"paper-eyebrow"},c9={key:2,class:"paper-empty-title"},p9=["textContent"];function yp(e,t){return a(),l("div",a9,[n("div",l9,[e.error?f("v-if",!0):(a(),l("div",d9,"Working")),e.error?(a(),l("div",u9,"Error")):f("v-if",!0),e.error?f("v-if",!0):(a(),l("h1",c9,[...t[0]||(t[0]=[g(" Loading",-1),n("span",{class:"dot-anim"},"\u2026",-1)])])),e.error?(a(),l("h1",{key:3,class:"paper-empty-title",textContent:c(e.fmt.translate(e.error))},null,8,p9)):f("v-if",!0)])])}var f9={class:"container paper-page paper-settings"},m9={class:"paper-crumbs"},h9={class:"here"},g9={class:"paper-page-title"},v9={class:"paper-settings-body"},y9={class:"paper-settings-toc"},b9={href:"#conf-billing"},w9={class:"form needs-validation paper-settings-main",name:"conference",novalidate:""},k9={id:"conf-basics",class:"paper-settings-section"},C9={class:"form-group"},E9={class:"invalid-feedback"},S9={class:"invalid-feedback"},N9={class:"form-group"},R9={class:"invalid-feedback"},P9={class:"form-group"},D9={class:"invalid-feedback"},A9={class:"invalid-feedback"},T9={id:"conf-window",class:"paper-settings-section"},O9={class:"form-grid-2"},I9={class:"form-group"},M9={class:"invalid-feedback"},V9={class:"invalid-feedback"},q9={class:"form-group"},_9={class:"invalid-feedback"},L9={class:"invalid-feedback"},$9={id:"conf-rendering",class:"paper-settings-section"},F9={class:"form-check"},U9={class:"form-check-input",type:"checkbox",id:"link",name:"link"},B9={class:"form-check"},z9={class:"form-check-input",type:"checkbox",id:"image",name:"image"},H9={class:"form-check"},j9={class:"form-check-input",type:"checkbox",id:"pdf",name:"pdf"},G9={class:"form-check"},W9={class:"form-check-input",type:"checkbox",id:"notebook",name:"notebook"},K9={id:"conf-features",class:"paper-settings-section"},Y9={class:"form-check"},X9={class:"form-check-input",type:"checkbox",id:"update",name:"update"},J9={class:"form-check"},Q9={class:"form-check-input",type:"checkbox",id:"page",name:"page"},Z9={id:"conf-plan",class:"paper-settings-section"},x9={key:0,class:"paper-section-copy"},eB={class:"conference-tiers",role:"radiogroup","aria-label":"Review package size"},tB=["value","checked","onChange"],nB={class:"conference-tier-head"},sB={key:0,class:"conference-tier-pill"},oB={class:"conference-tier-who"},iB={key:0,class:"conference-tier-price"},rB={class:"conference-tier-size"},aB={key:1,class:"conference-tier-per"},lB={key:2,class:"paper-plan-grid"},dB=["value"],uB=["textContent"],cB={class:"paper-plan-price"},pB=["innerHTML"],fB={key:3,class:"settings-notice",role:"status"},mB={key:0,id:"conf-billing",class:"paper-settings-section"},hB={class:"form-group"},gB={class:"form-group"},vB={class:"form-group"},yB={class:"form-group"},bB={class:"form-grid-3"},wB={class:"form-group"},kB={class:"form-group"},CB={class:"form-group"},EB={class:"form-group"},SB={class:"paper-settings-footer"},NB=["textContent"],RB=["textContent"],PB=["disabled"];function bp(e,t){let s=De("paper-scrollspy"),i=De("field"),o=De("form");return a(),l("div",f9,[n("div",m9,[t[1]||(t[1]=n("a",{href:"/dashboard"},"My work",-1)),t[2]||(t[2]=g(" \xA0/\xA0 ",-1)),t[3]||(t[3]=n("a",{href:"/conferences"},"Conferences",-1)),t[4]||(t[4]=g(" \xA0/\xA0 ",-1)),n("span",h9,c(e.editionMode?"Edit":"New"),1)]),n("h1",g9,[g(c(e.editionMode?"Edit":"Create a")+" ",1),t[5]||(t[5]=n("em",null,"conference",-1))]),t[44]||(t[44]=n("p",{class:"paper-page-lede"}," Give chairs access to every anonymization submitted to a venue. One payment hosts every submission, so authors don't pay during the review window. ",-1)),n("div",v9,[T((a(),l("aside",y9,[t[7]||(t[7]=n("div",{class:"paper-settings-toc-head"},"On this page",-1)),n("nav",null,[t[6]||(t[6]=Ce('BasicsReview windowRendering defaultsFeaturesPlan',5)),T(n("a",b9,"Billing",512),[[Z,e.plan?.pricePerRepo>0]])])])),[[s]]),T((a(),l("form",w9,[n("section",k9,[t[12]||(t[12]=n("div",{class:"paper-section-eyebrow"},"Basics",-1)),n("div",C9,[t[8]||(t[8]=n("label",{class:"paper-field-label",for:"name"},"Conference name",-1)),T(n("input",{type:"text",class:P(["form-control",{"is-invalid":e.conference?.name?.invalid&&(e.conference?.name?.touched||e.conference?.submitted)}]),name:"name",id:"name",required:"",placeholder:"e.g. International Conference on Software Engineering"},null,2),[[i,{state:e.viewState,set:r=>{e.options.name=r},value:e.options?.name,form:"conference",options:{}}]]),T(n("div",E9," The name of the conference is invalid. ",512),[[Z,e.conference?.name?.errors?.invalid]]),T(n("div",S9," The name of the conference is required. ",512),[[Z,e.conference?.name?.errors?.required]])]),n("div",N9,[t[9]||(t[9]=n("label",{class:"paper-field-label",for:"url"},"Website",-1)),T(n("input",{type:"url",class:P(["form-control",{"is-invalid":e.conference?.url?.invalid&&(e.conference?.url?.touched||e.conference?.submitted)}]),name:"url",id:"url",placeholder:"https://example.org"},null,2),[[i,{state:e.viewState,set:r=>{e.options.url=r},value:e.options?.url,form:"conference",options:{}}]]),T(n("div",R9," The url of the conference is invalid. ",512),[[Z,e.conference?.url?.errors?.url]])]),n("div",P9,[t[10]||(t[10]=n("label",{class:"paper-field-label",for:"conferenceID"},"Conference ID",-1)),T(n("input",{type:"text",class:P(["form-control",{"is-invalid":e.conference?.conferenceID?.invalid&&(e.conference?.conferenceID?.touched||e.conference?.submitted)}]),name:"conferenceID",id:"conferenceID",required:"",pattern:"[a-zA-Z0-9\\-_]{3,10}",placeholder:"ICSE26"},null,2),[[i,{state:e.viewState,set:r=>{e.options.conferenceID=r},value:e.options?.conferenceID,form:"conference",options:{}}]]),t[11]||(t[11]=n("small",{class:"form-text text-muted"},[g("3\u201310 characters, letters, numbers, "),n("code",null,"-"),g(" and "),n("code",null,"_"),g(". Authors reference this when they anonymize.")],-1)),T(n("div",{class:"invalid-feedback"}," The conference ID '"+c(e.options?.conferenceID)+"' is already used. ",513),[[Z,e.conference?.conferenceID?.errors?.used]]),T(n("div",D9," The conference ID is required. ",512),[[Z,e.conference?.conferenceID?.errors?.required]]),T(n("div",A9," The format of the conference ID is incorrect ([a-zA-Z0-9-_]{3,10}). ",512),[[Z,e.conference?.conferenceID?.errors?.pattern]])])]),n("section",T9,[t[17]||(t[17]=n("div",{class:"paper-section-eyebrow"},"Review window",-1)),n("div",O9,[n("div",I9,[t[13]||(t[13]=n("label",{class:"paper-field-label",for:"startDate"},"Start date",-1)),T(n("input",{type:"date",class:P(["form-control",{"is-invalid":e.conference?.startDate?.invalid&&(e.conference?.startDate?.touched||e.conference?.submitted)}]),name:"startDate",id:"startDate",required:""},null,2),[[i,{state:e.viewState,set:r=>{e.options.startDate=r},value:e.options?.startDate,form:"conference",options:{}}]]),t[14]||(t[14]=n("small",{class:"form-text text-muted"},"Beginning of the review process.",-1)),T(n("div",M9," Start date is required. ",512),[[Z,e.conference?.startDate?.errors?.required]]),T(n("div",V9," Start date must be before end date. ",512),[[Z,e.conference?.startDate?.errors?.invalid]])]),n("div",q9,[t[15]||(t[15]=n("label",{class:"paper-field-label",for:"endDate"},"End date",-1)),T(n("input",{type:"date",class:P(["form-control",{"is-invalid":e.conference?.endDate?.invalid&&(e.conference?.endDate?.touched||e.conference?.submitted)}]),name:"endDate",id:"endDate",required:""},null,2),[[i,{state:e.viewState,set:r=>{e.options.endDate=r},value:e.options?.endDate,form:"conference",options:{}}]]),t[16]||(t[16]=n("small",{class:"form-text text-muted"},"All repositories expire on this date.",-1)),T(n("div",_9," End date is required. ",512),[[Z,e.conference?.endDate?.errors?.required]]),T(n("div",L9," End date is invalid. ",512),[[Z,e.conference?.endDate?.errors?.invalid]])])])]),n("section",$9,[t[26]||(t[26]=n("div",{class:"paper-section-eyebrow"},"Rendering defaults",-1)),n("div",F9,[T(n("input",U9,null,512),[[i,{state:e.viewState,set:r=>{e.options.options.link=r},value:e.options?.options?.link,form:"conference",options:{}}]]),t[18]||(t[18]=n("label",{class:"form-check-label",for:"link"},"Keep links",-1)),t[19]||(t[19]=n("small",{class:"form-text text-muted"},"Keep or remove all links from text files.",-1))]),n("div",B9,[T(n("input",z9,null,512),[[i,{state:e.viewState,set:r=>{e.options.options.image=r},value:e.options?.options?.image,form:"conference",options:{}}]]),t[20]||(t[20]=n("label",{class:"form-check-label",for:"image"},"Display images",-1)),t[21]||(t[21]=n("small",{class:"form-text text-muted"},"Images are not anonymized.",-1))]),n("div",H9,[T(n("input",j9,null,512),[[i,{state:e.viewState,set:r=>{e.options.options.pdf=r},value:e.options?.options?.pdf,form:"conference",options:{}}]]),t[22]||(t[22]=n("label",{class:"form-check-label",for:"pdf"},"Display PDFs",-1)),t[23]||(t[23]=n("small",{class:"form-text text-muted"},"PDFs are not anonymized.",-1))]),n("div",G9,[T(n("input",W9,null,512),[[i,{state:e.viewState,set:r=>{e.options.options.notebook=r},value:e.options?.options?.notebook,form:"conference",options:{}}]]),t[24]||(t[24]=n("label",{class:"form-check-label",for:"notebook"},"Display notebooks",-1)),t[25]||(t[25]=n("small",{class:"form-text text-muted"},"Render Jupyter notebooks instead of raw JSON.",-1))])]),n("section",K9,[t[31]||(t[31]=n("div",{class:"paper-section-eyebrow"},"Features",-1)),n("div",Y9,[T(n("input",X9,null,512),[[i,{state:e.viewState,set:r=>{e.options.options.update=r},value:e.options?.options?.update,form:"conference",options:{}}]]),t[27]||(t[27]=n("label",{class:"form-check-label",for:"update"},"Auto-update from GitHub",-1)),t[28]||(t[28]=n("small",{class:"form-text text-muted"},"Pull the latest commit automatically (hourly maximum).",-1))]),n("div",J9,[T(n("input",Q9,null,512),[[i,{state:e.viewState,set:r=>{e.options.options.page=r},value:e.options?.options?.page,form:"conference",options:{}}]]),t[29]||(t[29]=n("label",{class:"form-check-label",for:"page"},"GitHub Pages",-1)),t[30]||(t[30]=n("small",{class:"form-text text-muted"},"Enable anonymized GitHub pages.",-1))])]),n("section",Z9,[t[35]||(t[35]=n("div",{class:"paper-section-eyebrow"},"Plan",-1)),e.editionMode?(a(),l("p",x9,c(e.conferencePlanName(e.options?.plan?.planID))+". The plan and review dates can't change after creation.",1)):e.conferenceTiers().length?(a(),l(q,{key:1},[t[33]||(t[33]=n("p",{class:"paper-section-copy"},"Pick the package that fits the number of submissions you expect. One payment hosts every submission, so authors don't pay.",-1)),n("div",eB,[(a(!0),l(q,null,Q(e.conferenceTiers(),r=>(a(),l("label",{class:P(["conference-tier",{"is-selected":e.options?.plan?.planID===r.id}]),key:r.id},[n("input",{type:"radio",name:"planPicker",value:r.id,checked:e.options?.plan?.planID===r.id,onChange:d=>e.options.plan.planID=r.id},null,40,tB),n("span",nB,[n("strong",null,c(r.name),1),r.id==="conference"&&e.conferenceTiers().length>1?(a(),l("span",sB,"Most common")):f("v-if",!0)]),n("span",oB,c(e.conferenceAudience(r.id)),1),r.amount!=null?(a(),l("span",iB,[n("strong",null,c(e.conferenceAmount(r)),1),t[32]||(t[32]=g(" once",-1))])):f("v-if",!0),n("span",rB,"Up to "+c(r.repositories)+" papers \xB7 "+c(e.conferenceBytes(r.storage)),1),r.amount!=null&&r.repositories?(a(),l("span",aB,"About "+c(e.conferenceAmount(r,r.amount/r.repositories))+" per paper",1)):f("v-if",!0)],2))),128))]),t[34]||(t[34]=Ce('

Every package includes

  • A review window of up to 180 days
  • Automatic updates for every submission
  • Links stay online until the review window ends
  • A dashboard of every submission for chairs

Nothing renews \xB7 Tax shown at checkout \xB7 Expecting more submissions? Email tdurieux@anonymous.4open.science

Create the conference, then pay from its page. Authors can submit once the payment is confirmed.

',2))],64)):e.plans.length?(a(),l("div",lB,[(a(!0),l(q,null,Q(e.plans,r=>(a(),l("label",{class:P(["paper-plan-card",{selected:e.options?.plan?.planID==r?.id}]),key:r.id},[T(n("input",{type:"radio",name:"planPicker",value:r?.id},null,8,dB),[[i,{state:e.viewState,set:d=>{e.options.plan.planID=d},value:e.options?.plan?.planID,form:"conference",options:{}}]]),n("div",{class:"paper-plan-head",textContent:c(r?.name)},null,8,uB),n("div",cB,c(r.pricePerRepo>0?e.fmt?.number(r.pricePerRepo,2)+" \u20AC per repository":"Free"),1),n("div",{class:"paper-plan-desc",innerHTML:e.sanitize(r?.description)},null,8,pB)],2))),128))])):e.plansLoaded?(a(),l("p",fB,"New conferences are unavailable right now. Please try again later.")):f("v-if",!0)]),e.plan?.pricePerRepo>0?(a(),l("section",mB,[t[43]||(t[43]=n("div",{class:"paper-section-eyebrow"},"Billing",-1)),n("div",hB,[t[36]||(t[36]=n("label",{class:"paper-field-label",for:"billing_name"},"Name",-1)),T(n("input",{type:"text",class:P(["form-control",{"is-invalid":e.conference?.billing_name?.invalid&&(e.conference?.billing_name?.touched||e.conference?.submitted)}]),name:"billing_name",id:"billing_name",required:"",placeholder:"First & last name"},null,2),[[i,{state:e.viewState,set:r=>{e.options.billing.name=r},value:e.options?.billing?.name,form:"conference",options:{}}]])]),n("div",gB,[t[37]||(t[37]=n("label",{class:"paper-field-label",for:"email"},"Email",-1)),T(n("input",{type:"email",class:P(["form-control",{"is-invalid":e.conference?.email?.invalid&&(e.conference?.email?.touched||e.conference?.submitted)}]),name:"email",id:"email",required:"",placeholder:"you@example.org"},null,2),[[i,{state:e.viewState,set:r=>{e.options.billing.email=r},value:e.options?.billing?.email,form:"conference",options:{}}]])]),n("div",vB,[t[38]||(t[38]=n("label",{class:"paper-field-label",for:"inputAddress"},"Address",-1)),T(n("input",{type:"text",class:P(["form-control",{"is-invalid":e.conference?.inputAddress?.invalid&&(e.conference?.inputAddress?.touched||e.conference?.submitted)}]),name:"inputAddress",id:"inputAddress",required:"",placeholder:"1234 Main St"},null,2),[[i,{state:e.viewState,set:r=>{e.options.billing.address=r},value:e.options?.billing?.address,form:"conference",options:{}}]])]),n("div",yB,[T(n("input",{type:"text",class:P(["form-control",{"is-invalid":e.conference?.inputAddress2?.invalid&&(e.conference?.inputAddress2?.touched||e.conference?.submitted)}]),name:"inputAddress2",id:"inputAddress2",placeholder:"Apartment, studio, or floor"},null,2),[[i,{state:e.viewState,set:r=>{e.options.billing.address2=r},value:e.options?.billing?.address2,form:"conference",options:{}}]])]),n("div",bB,[n("div",wB,[t[39]||(t[39]=n("label",{class:"paper-field-label",for:"city"},"City",-1)),T(n("input",{type:"text",class:P(["form-control",{"is-invalid":e.conference?.city?.invalid&&(e.conference?.city?.touched||e.conference?.submitted)}]),name:"city",id:"city",required:"",placeholder:"City"},null,2),[[i,{state:e.viewState,set:r=>{e.options.billing.city=r},value:e.options?.billing?.city,form:"conference",options:{}}]])]),n("div",kB,[t[40]||(t[40]=n("label",{class:"paper-field-label",for:"country"},"Country",-1)),T(n("input",{type:"text",class:P(["form-control",{"is-invalid":e.conference?.country?.invalid&&(e.conference?.country?.touched||e.conference?.submitted)}]),name:"country",id:"country",required:"",placeholder:"Country"},null,2),[[i,{state:e.viewState,set:r=>{e.options.billing.country=r},value:e.options?.billing?.country,form:"conference",options:{}}]])]),n("div",CB,[t[41]||(t[41]=n("label",{class:"paper-field-label",for:"zip"},"Zip",-1)),T(n("input",{type:"text",class:P(["form-control",{"is-invalid":e.conference?.zip?.invalid&&(e.conference?.zip?.touched||e.conference?.submitted)}]),name:"zip",id:"zip",required:"",placeholder:"Zip"},null,2),[[i,{state:e.viewState,set:r=>{e.options.billing.zip=r},value:e.options?.billing?.zip,form:"conference",options:{}}]])])]),n("div",EB,[t[42]||(t[42]=n("label",{class:"paper-field-label",for:"vat"},"VAT number",-1)),T(n("input",{type:"text",class:P(["form-control",{"is-invalid":e.conference?.vat?.invalid&&(e.conference?.vat?.touched||e.conference?.submitted)}]),name:"vat",id:"vat",placeholder:"VAT Number"},null,2),[[i,{state:e.viewState,set:r=>{e.options.billing.vat=r},value:e.options?.billing?.vat,form:"conference",options:{}}]])])])):f("v-if",!0),n("div",SB,[e.error?(a(),l("div",{key:0,class:"alert alert-danger",role:"alert",textContent:c(e.error)},null,8,NB)):f("v-if",!0),e.message?(a(),l("div",{key:1,class:"alert alert-success",role:"alert",textContent:c(e.message)},null,8,RB)):f("v-if",!0),n("button",{id:"send",disabled:e.saving,type:"submit",class:"btn btn-ink",onClick:t[0]||(t[0]=ae(r=>e.submitForm(r,()=>{e.submit(r)}),["prevent"]))},c(e.saving?e.editionMode?"Updating\u2026":"Creating\u2026":e.editionMode?"Update conference":"Create conference"),9,PB)])])),[[o,e.viewState]])])])}var DB={key:0,class:"dir-card","aria-label":"Repository files"},AB=["onClick"],TB={class:"dir-name"},OB=["href"],IB={class:"dir-name"},MB={class:"dir-meta"},VB={class:"file-card-head"},qB={class:"file-card-path"},_B={class:"breadcrumb paths","aria-label":"Path"},LB={class:"breadcrumb-item breadcrumb-root"},$B=["href","title","textContent"],FB=["aria-current"],UB=["aria-label"],BB={class:"mobile-sub ms"},zB=["title"],HB={class:"ms-item"},jB={key:1,class:"ms-item"},GB={key:2,class:"ms-item"},WB=["aria-label","title"],KB={class:"ui-icon","aria-hidden":"true"},YB=["href"],XB={key:0,class:"file-card-meta"},JB=["title"],QB={class:"meta-extra"},ZB={key:1,class:"file-card-meta"},xB=["title"],ez={class:"file-card-actions"},tz={key:0,class:"csv-toggle seg-filter",role:"radiogroup","aria-label":"CSV view"},nz=["aria-checked"],sz=["aria-checked"],oz={key:1,class:"symbols"},iz=["aria-expanded"],rz={key:0,class:"symbols-menu",role:"menu"},az={class:"symbols-head"},lz=["onClick"],dz={class:"symbols-name"},uz={class:"symbols-line"},cz=["title"],pz={key:3,class:"tb-view",role:"group","aria-label":"View tools"},fz=["title"],mz=["aria-pressed"],hz=["title"],gz={key:4,class:"tb-file",role:"group","aria-label":"File actions"},vz=["target","title","href"],yz=["aria-label","title"],bz={class:"ui-icon","aria-hidden":"true"},wz=["href"],kz=["target","href","download"],Cz=["aria-label"],Ez={class:"ui-icon","aria-hidden":"true"},Sz=["href"],Nz={key:6,class:"tb-toc-m"},Rz=["aria-expanded"],Pz=["onClick"],Dz={class:"tb-more"},Az=["aria-expanded"],Tz={viewBox:"0 0 24 24",class:"ui-icon","aria-hidden":"true",style:{fill:"currentColor",stroke:"none"}},Oz={key:0,class:"tb-menu-note"},Iz={key:1,class:"tb-menu-note tb-menu-meta"},Mz={key:2,class:"tb-menu-sep"},Vz={key:4,class:"tb-menu-sep"},qz=["aria-checked"],_z={key:0,class:"tb-menu-check"},Lz={class:"ui-icon","aria-hidden":"true"},$z=["href"],Fz={key:9,class:"tb-menu-sep"},Uz=["target","href"],Bz=["target","href"],zz=["target","href","download"],Hz=["target","href"],jz=["href"],Gz=["target","href"],Wz=["placeholder","aria-invalid"],Kz=["aria-label"],Yz={class:"csv-table"},Xz=["aria-label"],Jz={class:"csv-rownum"},Qz=["aria-label"],Zz={key:1,class:"file-card-body"},xz={key:2,class:"md-find-bar",role:"search"},eH=["value"],tH={class:"md-find-nav"},nH=["disabled"],sH=["disabled"],oH={class:"md-find-count","aria-live":"polite"},iH=["aria-pressed"],rH={key:3,class:"reading-layout"},aH=["innerHTML"],lH={key:0,class:"readme-toc","aria-label":"On this page"},dH={class:"toc-rail"},uH=["href","onClick"],cH={class:"file-card-head"},pH={class:"file-card-path"},fH={class:"breadcrumb paths","aria-label":"Path"},mH={class:"breadcrumb-item breadcrumb-root"},hH=["href","title","textContent"],gH=["aria-current"],vH=["aria-label"],yH={class:"mobile-sub ms"},bH=["title"],wH={class:"ms-item"},kH={key:1,class:"ms-item"},CH={key:2,class:"ms-item"},EH=["aria-label","title"],SH={class:"ui-icon","aria-hidden":"true"},NH=["href"],RH={class:"file-card-meta"},PH=["title"],DH={class:"file-card-actions"},AH={key:0,class:"file-card-state",title:"Files over the size limit can't be previewed or downloaded from this link"},TH={key:1,class:"tb-file",role:"group","aria-label":"File actions"},OH=["target","title","href"],IH=["target","href","download"],MH={class:"tb-more"},VH=["aria-expanded"],qH={viewBox:"0 0 24 24",class:"ui-icon","aria-hidden":"true",style:{fill:"currentColor",stroke:"none"}},_H={key:0,class:"tb-menu-note"},LH={key:1,class:"tb-menu-sep"},$H=["target","href"],FH=["target","href","download"],UH=["target","href"],BH={key:0,class:"media-stage"},zH=["src","alt"],HH={key:1,class:"media-stage"},jH=["src"],GH={key:2,class:"media-stage is-audio"},WH=["src"],KH={key:4,class:"notebook-body"},YH={key:5,class:"file-state"},XH={class:"file-state-msg"},JH={key:0,class:"file-state-actions"},QH=["target","href","download"],ZH={key:6,class:"file-state",role:"alert"},xH={class:"file-state-title"},ej={key:0,class:"file-state-msg"},tj={key:1,class:"file-state-msg"},nj={key:2,class:"file-state-actions"},sj=["href"],oj={key:7,class:"file-state"},ij={key:4,class:"file-error container d-flex h-100"},rj={class:"paper-ratelimit-card m-auto",style:{"max-width":"520px"}},aj={class:"paper-error-msg"},lj={key:5,class:"file-error container d-flex h-100"},dj={class:"viewer-error paper-error-card file-error-card m-auto",role:"alert","aria-labelledby":"viewer-error-title"},uj={id:"viewer-error-title",class:"paper-empty-title"},cj={class:"paper-error-actions"},pj={key:0,href:"/",class:"btn btn-sm"},fj={key:1,href:"/faq",class:"btn btn-sm"},mj={key:2,class:"btn btn-outline-ink",href:"/dashboard"},hj={key:6,class:"viewer-loading","aria-busy":"true"},gj={class:"viewer-loading-status",role:"status","aria-live":"polite"},vj={class:"viewer-loading-name sr-only"},yj={key:0},bj={class:"viewer-loading-lines","aria-hidden":"true"},wj={key:7,class:"file-error container d-flex h-100"},kj={key:8,class:"file-error container d-flex h-100"};function wp(e,t){let s=Xe("html-doc"),i=Xe("pdfviewer"),o=Xe("notebook"),r=De("code-editor");return a(),l(q,null,[e.sidebarHidden&&e.type=="html"&&e.content!=null&&e.paths?.length===1&&/^readme/i.test(e.paths[0]||"")&&e.files?.length?(a(),l("section",DB,[t[46]||(t[46]=n("header",{class:"dir-card-head"},[n("span",{class:"dir-card-title"},"Files"),n("span",{class:"dir-card-sub"},"Snapshot of the repository at review time")],-1)),n("ul",{class:P(["dir-list",{"is-expanded":e.dirExpanded}])},[(a(!0),l(q,null,Q(e.rootEntries(),d=>(a(),l("li",{key:d.name},[d.size==null?(a(),l("button",{key:0,type:"button",class:"dir-row",onClick:p=>e.revealFolder(d.name)},[t[43]||(t[43]=n("svg",{class:"dir-icon",viewBox:"0 0 16 16","aria-hidden":"true"},[n("path",{d:"M1.5 3.5h4l1.5 1.5h7.5v8h-13z"})],-1)),n("span",TB,c(d.name),1),t[44]||(t[44]=n("span",{class:"dir-meta"},"Folder",-1))],8,AB)):(a(),l("a",{key:1,class:P(["dir-row",{"is-current":d.name===e.paths[0]}]),href:e.safeUrl("/r/"+e.repoId+"/"+encodeURIComponent(d.name))},[t[45]||(t[45]=n("svg",{class:"dir-icon",viewBox:"0 0 16 16","aria-hidden":"true"},[n("path",{d:"M3.5 1.5h6l3 3v10h-9z"})],-1)),n("span",IB,c(d.name),1),n("span",MB,c(e.formatSize(d.size)),1)],10,OB))]))),128))],2),!e.dirExpanded&&e.files.length>8?(a(),l("button",{key:0,type:"button",class:"dir-more",onClick:t[0]||(t[0]=d=>e.dirExpanded=!0)},"Show all "+c(e.files.length)+" items",1)):f("v-if",!0)])):f("v-if",!0),(e.type=="text"||e.type=="code"||e.type=="html"||e.type=="html-doc"&&e.showSource)&&e.content!=null?(a(),l("section",{key:1,class:P(["file-card",{"is-code":e.type!="html","no-wrap":!e.wrapLines}])},[n("header",VB,[n("div",qB,[n("button",{type:"button",class:P(["btn btn-sm btn-icon-only btn-ghost card-files-btn",{"is-needed":e.sidebarHidden}]),title:"Show file tree",onClick:t[1]||(t[1]=d=>e.sidebarHidden?e.sidebarHidden=!1:e.sidebarCollapsed=!1)},[...t[47]||(t[47]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-sidebar"})],-1),n("span",{class:"card-files-label"},"Files",-1)])],2),n("ol",_B,[n("li",LB,[n("a",{href:e.safeUrl("/r/"+e.repoId+"/"),title:e.repoId,textContent:c(/^[0-9a-f]{8}-[0-9a-f]{4}-/i.test(e.repoId||"")?"repository":e.repoId)},null,8,$B)]),(a(!0),l(q,null,Q(e.paths,(d,p)=>(a(),l("li",{class:"breadcrumb-item","aria-current":p===e.paths.length-1?"page":null},[(a(!0),l(q,null,Q(e.redactParts(d),(u,y)=>(a(),l(q,{key:y},[u.n?(a(),l("span",{key:0,class:"redact-slot",role:"img","aria-label":"Redacted term "+u.n},[n("i",null,c(u.n),1)],8,UB)):(a(),l(q,{key:1},[g(c(u.t),1)],64))],64))),128))],8,FB))),256))]),n("span",BB,[e.redactionCount()?(a(),l("b",{key:0,class:"ms-item ms-redact",title:e.redactionCount()+" redacted terms"},[g(c(e.redactionCount()),1),t[48]||(t[48]=n("span",{class:"meta-redact-word"}," redacted",-1))],8,zB)):f("v-if",!0),n("span",HB,c(e.type=="html"?"Markdown":e.languageName||"Text"),1),e.fileSize(e.filePath)!=null?(a(),l("span",jB,c(e.formatSize(e.fileSize(e.filePath))),1)):f("v-if",!0),e.type!="html"&&typeof e.content=="string"?(a(),l("span",GB,c(e.fmt?.number(e.content.split(` +`).length))+" lines",1)):f("v-if",!0)]),T(n("button",{type:"button",class:"btn btn-sm btn-icon-only btn-ghost copy-path-btn","aria-label":e.pathCopied?"Path copied":"Copy file path",title:e.pathCopied?"Path copied":"Copy file path",onClick:t[2]||(t[2]=d=>e.copyPath())},[(a(),l("svg",KB,[n("use",{href:e.pathCopied?"#ui-icon-check":"#ui-icon-link"},null,8,YB)]))],8,WB),[[Z,e.filePath]])]),e.type!="html"&&typeof e.content=="string"?(a(),l("span",XB,[e.redactionCount()?(a(),l(q,{key:0},[n("span",{class:"meta-redact",title:e.redactionCount()+" redacted terms"},[g(c(e.redactionCount()),1),t[49]||(t[49]=n("span",{class:"meta-redact-word"}," redacted",-1))],8,JB),t[50]||(t[50]=n("span",{class:"sep"},"\xB7",-1))],64)):f("v-if",!0),g(c(e.languageName||"Text"),1),n("span",QB,[t[51]||(t[51]=n("span",{class:"sep"},"\xB7",-1)),g(c(e.content.length<1024?e.content.length+" B":(e.content.length/1024).toFixed(1)+" KB"),1)]),t[52]||(t[52]=n("span",{class:"sep"},"\xB7",-1)),g(c(e.fmt?.number(e.content.split(` +`).length))+" lines",1)])):f("v-if",!0),e.type=="html"?(a(),l("span",ZB,[e.redactionCount()?(a(),l(q,{key:0},[n("span",{class:"meta-redact",title:e.redactionCount()+" redacted terms"},[g(c(e.redactionCount()),1),t[53]||(t[53]=n("span",{class:"meta-redact-word"}," redacted",-1))],8,xB),t[54]||(t[54]=n("span",{class:"sep"},"\xB7",-1))],64)):f("v-if",!0),t[56]||(t[56]=g("Markdown",-1)),e.fileSize(e.filePath)!=null?(a(),l(q,{key:1},[t[55]||(t[55]=n("span",{class:"sep"},"\xB7",-1)),g(c(e.formatSize(e.fileSize(e.filePath))),1)],64)):f("v-if",!0)])):f("v-if",!0),e.preview&&e.previewPreserved()?(a(),l("button",{key:2,type:"button",class:"rp-preserved-tag",onClick:t[3]||(t[3]=d=>e.openPreserveFiles())},"Left unredacted")):f("v-if",!0),n("div",ez,[e.isCsv()?(a(),l("div",tz,[n("button",{type:"button",role:"radio",class:P(["seg-chip",{active:e.csvView==="table"}]),"aria-checked":e.csvView==="table",onClick:t[4]||(t[4]=d=>e.csvView="table")},"Table",10,nz),n("button",{type:"button",role:"radio",class:P(["seg-chip",{active:e.csvView==="raw"}]),"aria-checked":e.csvView==="raw",onClick:t[5]||(t[5]=d=>e.csvView="raw"),title:"Show the file as text with line numbers"},"Text",10,sz)])):f("v-if",!0),e.type!="html"&&e.symbols().length>1?(a(),l("div",oz,[n("button",{type:"button",class:P(["btn btn-sm btn-ghost btn-symbols",{"is-on":e.symbolsOpen}]),"aria-expanded":e.symbolsOpen?"true":"false","aria-haspopup":"true",title:"Symbols in this file",onClick:t[6]||(t[6]=d=>e.symbolsOpen=!e.symbolsOpen)},[...t[57]||(t[57]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-list"})],-1),n("span",{class:"btn-find-label"},"Symbols",-1)])],10,iz),e.symbolsOpen?(a(),l("div",rz,[n("div",az,c(e.symbols().length)+" "+c(e.symbols().length===1?"symbol":"symbols"),1),(a(!0),l(q,null,Q(e.symbols(),d=>(a(),l("button",{type:"button",class:"symbols-item",role:"menuitem",key:d.line+d.name,onClick:p=>e.goToSymbol(d.line)},[n("span",{class:P(["symbols-kind","is-"+d.kind])},c(d.kind==="class"?"C":d.kind==="function"?"\u0192":"v"),3),n("span",dz,c(d.name),1),n("span",uz,c(d.line),1)],8,lz))),128))])):f("v-if",!0)])):f("v-if",!0),e.type=="html"?(a(),l("button",{key:2,type:"button",class:P(["btn btn-sm btn-ghost btn-icon-only btn-find btn-md-find",{"is-on":e.mdFindOpen}]),"aria-label":"Find on this page",title:"Find on this page ("+(e.isMac?"\u2318":"Ctrl+")+"F)",onClick:t[7]||(t[7]=d=>e.toggleMdFind())},[...t[58]||(t[58]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-search"})],-1)])],10,cz)):f("v-if",!0),e.type!="html"&&!(e.isCsv()&&e.csvView==="table")?(a(),l("div",pz,[e.type!="html"?(a(),l("button",{key:0,type:"button",class:"btn btn-sm btn-ghost btn-icon-only btn-goto","aria-label":"Go to line",title:"Go to line ("+(e.isMac?"\u2318":"Ctrl+")+"G)",onClick:t[8]||(t[8]=d=>e.gotoLine())},[...t[59]||(t[59]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-goto"})],-1)])],8,fz)):f("v-if",!0),e.type!="html"?(a(),l("button",{key:1,type:"button",class:P(["btn btn-sm btn-icon-only btn-ghost btn-toggle",{"is-on":e.wrapLines}]),"aria-pressed":e.wrapLines?"true":"false","aria-label":"Wrap lines",title:"Wrap lines (Alt+Z)",onClick:t[9]||(t[9]=d=>e.toggleWrap())},[...t[60]||(t[60]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-wrap"})],-1)])],10,mz)):f("v-if",!0),e.type!="html"?(a(),l("button",{key:2,type:"button",class:"btn btn-sm btn-ghost btn-icon-only btn-find","aria-label":"Find in file",title:"Find in file ("+(e.isMac?"\u2318":"Ctrl+")+"F)",onClick:t[10]||(t[10]=d=>e.findInFile())},[...t[61]||(t[61]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-search"})],-1)])],8,hz)):f("v-if",!0)])):f("v-if",!0),!e.preview||e.url?(a(),l("div",gz,[n("a",{target:e.preview?"_blank":"_self",class:"tb-seg-btn",title:e.type=="html"?"Open the Markdown source":"Open the raw file",href:e.safeUrl(e.url)},"Raw",8,vz),typeof e.content=="string"?(a(),l("button",{key:0,type:"button",class:"tb-seg-btn tb-seg-icon","aria-label":e.contentCopied?"Copied":"Copy file contents",title:e.contentCopied?"Copied":"Copy file contents",onClick:t[11]||(t[11]=d=>e.copyContent())},[(a(),l("svg",bz,[n("use",{href:e.contentCopied?"#ui-icon-check":"#project-icon-copy"},null,8,wz)]))],8,yz)):f("v-if",!0),n("a",{target:e.preview?"_blank":"_self",class:"tb-seg-btn tb-seg-icon","aria-label":"Download file",title:"Download file",href:e.safeUrl(e.downloadUrl()),download:e.preview?e.paths[e.paths.length-1]:null},[...t[62]||(t[62]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-download"})],-1)])],8,kz)])):f("v-if",!0),typeof e.content=="string"?(a(),l("button",{key:5,type:"button",class:"btn btn-sm btn-icon-only btn-ghost tb-copy-m","aria-label":e.contentCopied?"Copied":"Copy file contents",onClick:t[12]||(t[12]=d=>e.copyContent())},[(a(),l("svg",Ez,[n("use",{href:e.contentCopied?"#ui-icon-check":"#project-icon-copy"},null,8,Sz)]))],8,Cz)):f("v-if",!0),e.type=="html"&&e.readmeToc().length>=3?(a(),l("div",Nz,[n("button",{type:"button",class:P(["btn btn-sm btn-icon-only btn-ghost tb-toc-btn",{"is-on":e.tocOpen}]),"aria-label":"On this page",title:"On this page","aria-haspopup":"true","aria-expanded":e.tocOpen?"true":"false",onClick:t[13]||(t[13]=ae(d=>{e.tocOpen=!e.tocOpen,e.moreOpen=!1},["stop"]))},[...t[63]||(t[63]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-outline"})],-1)])],10,Rz),e.tocOpen?(a(),l("div",{key:0,class:"tb-menu tb-toc-menu",role:"menu",onClick:t[15]||(t[15]=d=>e.tocOpen=!1)},[t[64]||(t[64]=n("div",{class:"tb-menu-label"},"On this page",-1)),n("button",{type:"button",role:"menuitem",class:P(["tb-menu-toc","lvl-2",{"is-active":!e.activeHeading}]),onClick:t[14]||(t[14]=d=>e.scrollToHeading(null))},"Introduction",2),(a(!0),l(q,null,Q(e.readmeToc(),d=>(a(),l("button",{type:"button",role:"menuitem",key:"m-"+d.id,class:P(["tb-menu-toc","lvl-"+d.level,{"is-active":e.activeHeading===d.id}]),onClick:p=>e.scrollToHeading(d.id)},c(d.text),11,Pz))),128))])):f("v-if",!0)])):f("v-if",!0),n("div",Dz,[n("button",{type:"button",class:P(["btn btn-sm btn-icon-only btn-ghost tb-more-btn",{"is-on":e.moreOpen}]),"aria-label":"More actions","aria-haspopup":"true","aria-expanded":e.moreOpen?"true":"false",onClick:t[16]||(t[16]=ae(d=>{e.tocOpen=!1,e.moreOpen=!e.moreOpen},["stop"]))},[(a(),l("svg",Tz,[...t[65]||(t[65]=[n("circle",{cx:"5",cy:"12",r:"1.8"},null,-1),n("circle",{cx:"12",cy:"12",r:"1.8"},null,-1),n("circle",{cx:"19",cy:"12",r:"1.8"},null,-1)])]))],10,Az),e.moreOpen?(a(),l("div",{key:0,class:"tb-menu",role:"menu",onClick:t[23]||(t[23]=d=>e.moreOpen=!1)},[e.options?.publishedAt||e.options?.sourceCommitDate||e.options?.anonymizedAt||e.options?.lastUpdateDate?(a(),l("div",Oz,[t[66]||(t[66]=n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#project-icon-clock"})],-1)),g("Snapshot \xB7 "+c(e.fmt?.date(e.options?.publishedAt||e.options?.sourceCommitDate||e.options?.anonymizedAt||e.options?.lastUpdateDate)),1)])):f("v-if",!0),typeof e.content=="string"?(a(),l("div",Iz,[g(c(e.type=="html"?"Markdown":e.languageName||"Text")+" \xB7 "+c(e.type=="html"&&e.fileSize(e.filePath)!=null?e.formatSize(e.fileSize(e.filePath)):e.content.length<1024?e.content.length+" B":(e.content.length/1024).toFixed(1)+" KB"),1),e.type!="html"?(a(),l(q,{key:0},[g(" \xB7 "+c(e.fmt?.number(e.content.split(` +`).length))+" lines",1)],64)):f("v-if",!0)])):f("v-if",!0),e.options?.publishedAt||e.options?.sourceCommitDate||e.options?.anonymizedAt||e.options?.lastUpdateDate?(a(),l("div",Mz)):f("v-if",!0),e.type=="html"?(a(),l("button",{key:3,type:"button",role:"menuitem",onClick:t[17]||(t[17]=d=>e.toggleMdFind())},[...t[67]||(t[67]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-search"})],-1),g("Find in file",-1)])])):f("v-if",!0),e.type=="html"?(a(),l("div",Vz)):f("v-if",!0),e.type!="html"?(a(),l("button",{key:5,type:"button",role:"menuitem",onClick:t[18]||(t[18]=d=>e.findInFile())},[...t[68]||(t[68]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-search"})],-1),g("Find in file",-1)])])):f("v-if",!0),e.type!="html"?(a(),l("button",{key:6,type:"button",role:"menuitem",onClick:t[19]||(t[19]=d=>e.gotoLine())},[...t[69]||(t[69]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-goto"})],-1),g("Go to line",-1)])])):f("v-if",!0),e.type!="html"?(a(),l("button",{key:7,type:"button",role:"menuitemcheckbox","aria-checked":e.wrapLines?"true":"false",onClick:t[20]||(t[20]=d=>e.toggleWrap())},[t[70]||(t[70]=n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-wrap"})],-1)),t[71]||(t[71]=g("Wrap lines",-1)),e.wrapLines?(a(),l("span",_z,"\u2713")):f("v-if",!0)],8,qz)):f("v-if",!0),e.isCsv()?(a(),l("button",{key:8,type:"button",role:"menuitem",class:"tb-csv-view",onClick:t[21]||(t[21]=d=>{e.csvView=e.csvView==="table"?"raw":"table",e.moreOpen=!1})},[(a(),l("svg",Lz,[n("use",{href:e.csvView==="table"?"#ui-icon-code":"#ui-icon-list"},null,8,$z)])),g(c(e.csvView==="table"?"Show as text":"Show as table"),1)])):f("v-if",!0),e.type!="html"?(a(),l("div",Fz)):f("v-if",!0),e.type=="html"&&(!e.preview||e.url)?(a(),l("a",{key:10,role:"menuitem",target:e.preview?"_blank":"_self",href:e.safeUrl(e.url)},[...t[72]||(t[72]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-code"})],-1),g("View raw",-1)])],8,Uz)):f("v-if",!0),e.type!="html"&&(!e.preview||e.url)?(a(),l("a",{key:11,role:"menuitem",target:e.preview?"_blank":"_self",href:e.safeUrl(e.url)},[...t[73]||(t[73]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-code"})],-1),g("View raw",-1)])],8,Bz)):f("v-if",!0),!e.preview||e.url?(a(),l("a",{key:12,role:"menuitem",target:e.preview?"_blank":"_self",href:e.safeUrl(e.downloadUrl()),download:e.preview?e.paths[e.paths.length-1]:null},[...t[74]||(t[74]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-download"})],-1),g("Download file",-1)])],8,zz)):f("v-if",!0),e.options?.hasWebsite?(a(),l("a",{key:13,role:"menuitem",target:e.preview?"_blank":"_self",href:e.safeUrl("/w/"+e.repoId+"/")},[...t[75]||(t[75]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-globe"})],-1),g("Open website",-1)])],8,Hz)):f("v-if",!0),e.options?.isAdmin||e.options?.isOwner?(a(),l("a",{key:14,role:"menuitem",href:e.safeUrl("/anonymize/"+e.repoId)},[...t[76]||(t[76]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-edit"})],-1),g("Edit anonymization",-1)])],8,jz)):f("v-if",!0),e.options?.download?(a(),l("a",{key:15,role:"menuitem",target:e.preview?"_blank":"_self",href:e.safeUrl("/api/repo/"+e.repoId+"/zip")},[...t[77]||(t[77]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-archive"})],-1),g("Download ZIP",-1)])],8,Gz)):f("v-if",!0),n("button",{type:"button",role:"menuitem",onClick:t[22]||(t[22]=d=>e.copyPath())},[...t[78]||(t[78]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-link"})],-1),g("Copy file path",-1)])]),t[79]||(t[79]=n("div",{class:"tb-menu-sep"},null,-1)),t[80]||(t[80]=n("a",{role:"menuitem",href:"/faq"},[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-help"})]),g("FAQ")],-1)),t[81]||(t[81]=n("a",{role:"menuitem",href:"https://github.com/tdurieux/anonymous_github/issues/new?template=issue_report.yml",target:"_blank",rel:"noopener"},[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-bug"})]),g("Report a bug")],-1))])):f("v-if",!0)])]),e.gotoOpen&&e.type!="html"?(a(),l("form",{key:3,class:"goto-pop",role:"dialog","aria-label":"Go to line",onSubmit:t[26]||(t[26]=ae(d=>e.submitGoto(),["prevent"]))},[t[82]||(t[82]=n("label",{class:"goto-label",for:"goto-input"},"Go to line",-1)),T(n("input",{id:"goto-input",class:"goto-input",type:"text",inputmode:"numeric",autocomplete:"off",spellcheck:"false",placeholder:"1\u2013"+e.fmt?.number(typeof e.content=="string"?e.content.split(` +`).length:1),"aria-invalid":e.gotoError?"true":"false","onUpdate:modelValue":t[24]||(t[24]=d=>e.gotoValue=d),onKeydown:t[25]||(t[25]=kt(ae(d=>e.closeGoto(),["prevent","stop"]),["esc"]))},null,40,Wz),[[rt,e.gotoValue]]),n("span",{class:P(["goto-hint",{"is-error":e.gotoError}])},c(e.gotoError||"Line, or line:column"),3)],32)):f("v-if",!0)]),e.isCsv()&&e.csvView==="table"?(a(),l("div",{key:0,class:"csv-table-wrap",tabindex:"0",role:"region","aria-label":"Table view of "+(e.paths?.[e.paths.length-1]||"file")},[n("table",Yz,[n("thead",null,[n("tr",null,[t[83]||(t[83]=n("th",{class:"csv-rownum",scope:"col"},[n("span",{class:"sr-only"},"Row")],-1)),(a(!0),l(q,null,Q(e.csvRows()[0]||[],(d,p)=>(a(),l("th",{scope:"col",key:p,class:P({"is-num":e.csvNumCol(p)})},[(a(!0),l(q,null,Q(e.redactParts(d),(u,y)=>(a(),l(q,{key:y},[u.n?(a(),l("span",{key:0,class:"redact-slot",role:"img","aria-label":"Redacted term "+u.n},[n("i",null,c(u.n),1)],8,Xz)):(a(),l(q,{key:1},[g(c(u.t),1)],64))],64))),128))],2))),128))])]),n("tbody",null,[(a(!0),l(q,null,Q(e.csvRows().slice(1),(d,p)=>(a(),l("tr",{key:p},[n("td",Jz,c(p+1),1),(a(!0),l(q,null,Q(d,(u,y)=>(a(),l("td",{key:y,class:P({"is-num":e.csvNumCol(y)})},[(a(!0),l(q,null,Q(e.redactParts(u),(h,b)=>(a(),l(q,{key:b},[h.n?(a(),l("span",{key:0,class:"redact-slot",role:"img","aria-label":"Redacted term "+h.n},[n("i",null,c(h.n),1)],8,Qz)):(a(),l(q,{key:1},[g(c(h.t),1)],64))],64))),128))],2))),128))]))),128))])])],8,Kz)):f("v-if",!0),e.type!="html"&&!(e.isCsv()&&e.csvView==="table")?T((a(),l("div",Zz,null,512)),[[r,{content:e.content,options:e.aceOption}]]):f("v-if",!0),e.type=="html"&&e.mdFindOpen?(a(),l("div",xz,[n("input",{type:"search",class:"md-find-input",placeholder:"Find on this page","aria-label":"Find on this page",value:e.mdFindQuery,onInput:t[27]||(t[27]=d=>{e.mdFindQuery=d.target.value,e.runMdFind()}),onKeydown:[t[28]||(t[28]=kt(ae(d=>d.shiftKey?e.stepMdFind(-1):e.stepMdFind(1),["prevent"]),["enter"])),t[29]||(t[29]=kt(ae(d=>e.toggleMdFind(!1),["prevent"]),["esc"]))]},null,40,eH),n("span",tH,[n("button",{type:"button","aria-label":"Previous match",onClick:t[30]||(t[30]=d=>e.stepMdFind(-1)),disabled:!e.mdFindTotal},[...t[84]||(t[84]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-chevron-left"})],-1)])],8,nH),n("button",{type:"button","aria-label":"Next match",onClick:t[31]||(t[31]=d=>e.stepMdFind(1)),disabled:!e.mdFindTotal},[...t[85]||(t[85]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-chevron-right"})],-1)])],8,sH)]),n("span",oH,c(e.mdFindQuery?e.mdFindTotal?e.mdFindIndex+1+" of "+e.mdFindTotal:"No results":""),1),n("button",{type:"button",class:P(["md-find-opt",{"is-on":e.mdFindCase}]),"aria-pressed":e.mdFindCase?"true":"false",title:"Match case","aria-label":"Match case",onClick:t[32]||(t[32]=d=>{e.mdFindCase=!e.mdFindCase,e.runMdFind()})},"Aa",10,iH),n("button",{type:"button",class:"md-find-close","aria-label":"Close find",onClick:t[33]||(t[33]=d=>e.toggleMdFind(!1))},"\xD7")])):f("v-if",!0),e.type=="html"?(a(),l("div",rH,[n("div",{class:"file-content markdown-body",innerHTML:e.renderReadme(e.sanitize(e.content))},null,8,aH),e.readmeToc().length>=3?(a(),l("aside",lH,[t[86]||(t[86]=n("div",{class:"readme-toc-head"},"On this page",-1)),n("nav",dH,[n("a",{href:"#",class:P(["lvl-2 toc-top",{"is-active":!e.activeHeading}]),onClick:t[34]||(t[34]=ae(d=>e.scrollToHeading(null),["prevent"]))},"Introduction",2),(a(!0),l(q,null,Q(e.readmeToc(),(d,p)=>(a(),l("a",{key:d.id,href:"#"+d.id,class:P(["lvl-"+d.level,{"is-active":e.activeHeading===d.id}]),onClick:ae(u=>e.scrollToHeading(d.id),["prevent"])},c(d.text),11,uH))),128))])])):f("v-if",!0)])):f("v-if",!0)],2)):f("v-if",!0),e.type=="html-doc"&&!e.showSource&&e.content!=null?(a(),Gt(s,{key:2,content:e.content,"base-url":e.fileBaseUrl,"allow-scripts":e.allowScripts},null,8,["content","base-url","allow-scripts"])):f("v-if",!0),e.fileFrame()?(a(),l("section",{key:3,class:P(["file-card file-card-media","view-"+e.type])},[n("header",cH,[n("div",pH,[n("button",{type:"button",class:P(["btn btn-sm btn-icon-only btn-ghost card-files-btn",{"is-needed":e.sidebarHidden}]),title:"Show file tree",onClick:t[35]||(t[35]=d=>e.sidebarHidden?e.sidebarHidden=!1:e.sidebarCollapsed=!1)},[...t[87]||(t[87]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-sidebar"})],-1),n("span",{class:"card-files-label"},"Files",-1)])],2),n("ol",fH,[n("li",mH,[n("a",{href:e.safeUrl("/r/"+e.repoId+"/"),title:e.repoId,textContent:c(/^[0-9a-f]{8}-[0-9a-f]{4}-/i.test(e.repoId||"")?"repository":e.repoId)},null,8,hH)]),(a(!0),l(q,null,Q(e.paths,(d,p)=>(a(),l("li",{class:"breadcrumb-item","aria-current":p===e.paths.length-1?"page":null},[(a(!0),l(q,null,Q(e.redactParts(d),(u,y)=>(a(),l(q,{key:y},[u.n?(a(),l("span",{key:0,class:"redact-slot",role:"img","aria-label":"Redacted term "+u.n},[n("i",null,c(u.n),1)],8,vH)):(a(),l(q,{key:1},[g(c(u.t),1)],64))],64))),128))],8,gH))),256))]),n("span",yH,[e.type=="IPython"&&e.redactionCount()?(a(),l("b",{key:0,class:"ms-item ms-redact",title:e.redactionCount()+" redacted terms"},[g(c(e.redactionCount()),1),t[88]||(t[88]=n("span",{class:"meta-redact-word"}," redacted",-1))],8,bH)):f("v-if",!0),n("span",wH,c(e.fileKind()),1),e.imageSize?(a(),l("span",kH,c(e.imageSize),1)):f("v-if",!0),e.fileSize(e.filePath)!=null?(a(),l("span",CH,c(e.formatSize(e.fileSize(e.filePath))),1)):f("v-if",!0)]),T(n("button",{type:"button",class:"btn btn-sm btn-icon-only btn-ghost copy-path-btn","aria-label":e.pathCopied?"Path copied":"Copy file path",title:e.pathCopied?"Path copied":"Copy file path",onClick:t[36]||(t[36]=d=>e.copyPath())},[(a(),l("svg",SH,[n("use",{href:e.pathCopied?"#ui-icon-check":"#ui-icon-link"},null,8,NH)]))],8,EH),[[Z,e.filePath]])]),n("span",RH,[e.type=="IPython"&&e.redactionCount()?(a(),l(q,{key:0},[n("span",{class:"meta-redact",title:e.redactionCount()+" redacted terms"},[g(c(e.redactionCount()),1),t[89]||(t[89]=n("span",{class:"meta-redact-word"}," redacted",-1))],8,PH),t[90]||(t[90]=n("span",{class:"sep"},"\xB7",-1))],64)):f("v-if",!0),g(c(e.fileKind()),1),e.imageSize?(a(),l(q,{key:1},[t[91]||(t[91]=n("span",{class:"sep"},"\xB7",-1)),g(c(e.imageSize),1)],64)):f("v-if",!0),e.fileSize(e.filePath)!=null?(a(),l(q,{key:2},[t[92]||(t[92]=n("span",{class:"sep"},"\xB7",-1)),g(c(e.formatSize(e.fileSize(e.filePath))),1)],64)):f("v-if",!0)]),e.preview&&e.previewPreserved()?(a(),l("button",{key:0,type:"button",class:"rp-preserved-tag",onClick:t[37]||(t[37]=d=>e.openPreserveFiles())},"Left unredacted")):f("v-if",!0),n("div",DH,[e.type=="error"&&e.content==="file_too_big"?(a(),l("span",AH,[...t[93]||(t[93]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-info"})],-1),g("Over the size limit",-1)])])):f("v-if",!0),e.type!="error"&&(!e.preview||e.url)?(a(),l("div",TH,[n("a",{target:e.preview?"_blank":"_self",class:"tb-seg-btn",title:e.type=="IPython"?"Open the notebook JSON":"Open the raw file",href:e.safeUrl(e.url)},"Raw",8,OH),n("a",{target:e.preview?"_blank":"_self",class:"tb-seg-btn tb-seg-icon","aria-label":"Download file",title:"Download file",href:e.safeUrl(e.downloadUrl()),download:e.preview?e.paths[e.paths.length-1]:null},[...t[94]||(t[94]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-download"})],-1)])],8,IH)])):f("v-if",!0),n("div",MH,[n("button",{type:"button",class:P(["btn btn-sm btn-icon-only btn-ghost tb-more-btn",{"is-on":e.moreOpen}]),"aria-label":"More actions","aria-haspopup":"true","aria-expanded":e.moreOpen?"true":"false",onClick:t[38]||(t[38]=ae(d=>e.moreOpen=!e.moreOpen,["stop"]))},[(a(),l("svg",qH,[...t[95]||(t[95]=[n("circle",{cx:"5",cy:"12",r:"1.8"},null,-1),n("circle",{cx:"12",cy:"12",r:"1.8"},null,-1),n("circle",{cx:"19",cy:"12",r:"1.8"},null,-1)])]))],10,VH),e.moreOpen?(a(),l("div",{key:0,class:"tb-menu",role:"menu",onClick:t[40]||(t[40]=d=>e.moreOpen=!1)},[e.options?.publishedAt||e.options?.sourceCommitDate||e.options?.anonymizedAt||e.options?.lastUpdateDate?(a(),l("div",_H,[t[96]||(t[96]=n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#project-icon-clock"})],-1)),g("Snapshot \xB7 "+c(e.fmt?.date(e.options?.publishedAt||e.options?.sourceCommitDate||e.options?.anonymizedAt||e.options?.lastUpdateDate)),1)])):f("v-if",!0),e.options?.publishedAt||e.options?.sourceCommitDate||e.options?.anonymizedAt||e.options?.lastUpdateDate?(a(),l("div",LH)):f("v-if",!0),e.type!="error"&&(!e.preview||e.url)?(a(),l("a",{key:2,role:"menuitem",target:e.preview?"_blank":"_self",href:e.safeUrl(e.url)},[t[97]||(t[97]=n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-code"})],-1)),g(c(e.type=="IPython"?"View notebook JSON":"View raw"),1)],8,$H)):f("v-if",!0),e.type!="error"&&(!e.preview||e.url)?(a(),l("a",{key:3,role:"menuitem",target:e.preview?"_blank":"_self",href:e.safeUrl(e.downloadUrl()),download:e.preview?e.paths[e.paths.length-1]:null},[...t[98]||(t[98]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-download"})],-1),g("Download file",-1)])],8,FH)):f("v-if",!0),e.options?.download?(a(),l("a",{key:4,role:"menuitem",target:e.preview?"_blank":"_self",href:e.safeUrl("/api/repo/"+e.repoId+"/zip")},[...t[99]||(t[99]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-archive"})],-1),g("Download ZIP",-1)])],8,UH)):f("v-if",!0),n("button",{type:"button",role:"menuitem",onClick:t[39]||(t[39]=d=>e.copyPath())},[...t[100]||(t[100]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-link"})],-1),g("Copy file path",-1)])]),t[101]||(t[101]=n("div",{class:"tb-menu-sep"},null,-1)),t[102]||(t[102]=n("a",{role:"menuitem",href:"/faq"},[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-help"})]),g("FAQ")],-1)),t[103]||(t[103]=n("a",{role:"menuitem",href:"https://github.com/tdurieux/anonymous_github/issues/new?template=issue_report.yml",target:"_blank",rel:"noopener"},[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-bug"})]),g("Report a bug")],-1))])):f("v-if",!0)])])]),e.type=="image"?(a(),l("div",BH,[n("img",{class:"image-content",src:e.safeUrl(e.url),alt:e.paths[e.paths.length-1],onLoad:t[41]||(t[41]=d=>e.onImageLoad(d))},null,40,zH)])):f("v-if",!0),e.type=="media"?(a(),l("div",HH,[n("video",{class:"video-content",controls:"",preload:"metadata",playsinline:"",src:e.safeUrl(e.url)},null,8,jH)])):f("v-if",!0),e.type=="audio"?(a(),l("div",GH,[n("audio",{controls:"",preload:"metadata",src:e.safeUrl(e.url)},null,8,WH)])):f("v-if",!0),e.type=="pdf"?(a(),Gt(i,{key:3,src:e.safeUrl(e.url)},null,8,["src"])):f("v-if",!0),e.type=="IPython"?(a(),l("div",KH,[Ie(o,{class:"markdown-body",file:e.url,content:e.content},null,8,["file","content"])])):f("v-if",!0),e.type=="binary"?(a(),l("div",YH,[t[105]||(t[105]=n("svg",{class:"ui-icon file-state-icon","aria-hidden":"true"},[n("use",{href:"#project-icon-file"})],-1)),t[106]||(t[106]=n("h2",{class:"file-state-title"},"No preview for this file",-1)),n("p",XH,c(e.preview?"Reviewers can open this file; it is not previewed here.":"This is a binary file. Download it to open it on your computer."),1),e.preview?f("v-if",!0):(a(),l("div",JH,[n("a",{target:e.preview?"_blank":"_self",class:"btn btn-primary",href:e.safeUrl(e.downloadUrl()),download:e.preview?e.paths[e.paths.length-1]:null},[...t[104]||(t[104]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-download"})],-1),g("Download file",-1)])],8,QH)]))])):f("v-if",!0),e.type=="error"?(a(),l("div",ZH,[t[108]||(t[108]=n("svg",{class:"ui-icon file-state-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-warning"})],-1)),n("h2",xH,c(e.content==="file_too_big"?"This file is too large to preview":"This file can't be shown"),1),e.content==="file_too_big"?(a(),l("p",ej,c(e.preview?"Reviewers can open this file; it is not previewed here. Files over 1 MB are only shown on the reviewer page.":"It is over the size limit for anonymized files, so it can't be previewed or downloaded from this link."),1)):(a(),l("p",tj,c(e.fmt.translate("ERRORS."+e.content)),1)),e.preview?f("v-if",!0):(a(),l("div",nj,[n("a",{class:"btn btn-primary",href:e.safeUrl("/r/"+e.repoId+"/")},"Back to the repository",8,sj),t[107]||(t[107]=n("a",{class:"btn btn-outline-ink",href:"/faq#formats"},"Supported files",-1))]))])):f("v-if",!0),e.content==null&&e.type!="error"?(a(),l("div",oj,[...t[109]||(t[109]=[n("svg",{class:"ui-icon file-state-icon","aria-hidden":"true"},[n("use",{href:"#project-icon-file"})],-1),n("h2",{class:"file-state-title"},"This file is empty",-1),n("p",{class:"file-state-msg"},"It has no content in this snapshot.",-1)])])):f("v-if",!0)],2)):f("v-if",!0),e.type=="rate_limited"?(a(),l("div",ij,[n("div",rj,[t[112]||(t[112]=Ce('
Temporarily paused
GitHub API rate limit reached
',1)),n("p",aj,[t[110]||(t[110]=g("This repository will be available in ",-1)),n("strong",null,c(e.rateLimitCountdown),1),t[111]||(t[111]=g(". The page will reload automatically.",-1))])])])):f("v-if",!0),e.type=="error"&&!e.fileFrame()?(a(),l("div",lj,[n("section",dj,[n("h1",uj,c(e.fmt.translate(e.isSourceAccessError()?"VIEWER_ERRORS.access_title":"VIEWER_ERRORS.title")),1),n("p",null,c(e.fmt.translate("ERRORS."+e.content)),1),e.isSourceAccessError()?(a(),l(q,{key:0},[n("p",null,c(e.fmt.translate("VIEWER_ERRORS.reader_help")),1),n("p",null,c(e.fmt.translate("VIEWER_ERRORS.owner_help")),1)],64)):f("v-if",!0),n("div",cj,[e.isSourceAccessError()?f("v-if",!0):(a(),l("a",pj,"Back to home")),e.isSourceAccessError()?f("v-if",!0):(a(),l("a",fj,"Read the FAQ")),n("button",{type:"button",class:"btn btn-primary",onClick:t[42]||(t[42]=d=>e.retryContent())},c(e.fmt.translate("VIEWER_ERRORS.retry")),1),e.isSourceAccessError()?(a(),l("a",mj,c(e.fmt.translate("VIEWER_ERRORS.dashboard")),1)):f("v-if",!0)])])])):f("v-if",!0),e.type=="loading"&&!e.error?(a(),l("section",hj,[n("div",gj,[n("strong",null,c(e.fmt.translate(e.fileReceivedBytes?"VIEWER_LOADING.receiving":"VIEWER_LOADING.loading")),1),n("span",vj,c(e.filePath),1),e.fileLoadingSlow?(a(),l("p",yj,c(e.fmt.translate("VIEWER_LOADING.slow")),1)):f("v-if",!0)]),n("div",bj,[(a(),l(q,null,Q(10,d=>n("span",{key:d})),64))])])):f("v-if",!0),e.type=="empty"?(a(),l("div",wj,[...t[113]||(t[113]=[n("h1",{class:"paper-empty-title m-auto"},[g("Empty "),n("em",null,"repository"),g(".")],-1)])])):f("v-if",!0),e.content==null&&!["empty","loading","error","rate_limited"].includes(e.type)&&!e.fileFrame()?(a(),l("div",kj,[...t[114]||(t[114]=[n("h1",{class:"paper-empty-title m-auto"},[g("Empty "),n("em",null,"file"),g(".")],-1)])])):f("v-if",!0)],64)}var Cj={class:"container page dashboard-page paper-page"},Ej={class:"row"},Sj={class:"w-100"},Nj={class:"w-100","aria-label":"Pull Requests","accept-charset":"UTF-8"},Rj={class:"d-flex flex-column flex-md-row align-items-md-center",style:{gap:"8px"}},Pj={class:"flex-grow-1"},Dj={type:"search",id:"search",class:"form-control","aria-label":"Find a pull request...",placeholder:"Find a pull request...",autocomplete:"off"},Aj={class:"d-flex flex-wrap",style:{gap:"6px"}},Tj={class:"dropdown"},Oj={class:"dropdown-menu","aria-labelledby":"dropdownSort"},Ij={class:"form-check dropdown-item"},Mj={class:"form-check-input",type:"radio",name:"sort",id:"sortFullName",value:"fullName"},Vj={class:"form-check dropdown-item"},qj={class:"form-check-input",type:"radio",name:"sort",id:"sortAnonymizeDate",value:"-anonymizeDate"},_j={class:"form-check dropdown-item"},Lj={class:"form-check-input",type:"radio",name:"sort",id:"sortStatus",value:"-status"},$j={class:"form-check dropdown-item"},Fj={class:"form-check-input",type:"radio",name:"sort",id:"sortLastView",value:"-lastView"},Uj={class:"form-check dropdown-item"},Bj={class:"form-check-input",type:"radio",name:"sort",id:"sortPageView",value:"-pageView"},zj={class:"dropdown"},Hj={class:"dropdown-menu","aria-labelledby":"dropdownStatus"},jj={class:"form-check dropdown-item"},Gj={class:"form-check-input",type:"checkbox",name:"sort",id:"statusReady",value:"ready"},Wj={class:"form-check dropdown-item"},Kj={class:"form-check-input",type:"checkbox",name:"sort",id:"statusExpired",value:"expired"},Yj={class:"form-check dropdown-item"},Xj={class:"form-check-input",type:"checkbox",name:"sort",id:"statusRemoved",value:"removed"},Jj={class:"d-flex flex-wrap mt-2",style:{gap:"6px"}},Qj={class:"filter-chip"},Zj=["onClick"],xj={class:"repo-list w-100"},eG={class:"repo-list-item-content"},tG={class:"repo-list-item-main"},nG={class:"repo-list-item-header"},sG=["textContent","href"],oG=["textContent"],iG=["textContent"],rG={class:"repo-source"},aG=["href"],lG={class:"repo-date"},dG={class:"repo-meta"},uG={key:0,title:"Conference"},cG=["title"],pG=["title"],fG=["title"],mG={key:1},hG={class:"repo-list-item-actions"},gG={class:"dropdown"},vG={class:"dropdown-menu dropdown-menu-right"},yG=["href"],bG=["onClick"],wG=["onClick"],kG=["onClick"],CG=["href"],EG={key:0,class:"repo-list-empty"};function kp(e,t){let s=De("field"),i=De("form");return a(),l("div",Cj,[n("div",Ej,[n("div",Sj,[t[12]||(t[12]=Ce('
My work \xA0/\xA0 Pull requests

Anonymized pull requests

Track PR mirrors you\u2019ve created and their reviewer traffic.

',2)),f(" Search + filters row "),T((a(),l("form",Nj,[n("div",Rj,[n("div",Pj,[T(n("input",Dj,null,512),[[s,{state:e.viewState,set:o=>{e.search=o},value:e.search,form:null,options:{}}]])]),n("div",Aj,[n("div",Tj,[t[6]||(t[6]=n("button",{class:"btn btn-sm dropdown-toggle",type:"button",id:"dropdownSort","data-toggle":"dropdown","aria-haspopup":"true","aria-expanded":"false"}," Sort ",-1)),n("div",Oj,[t[5]||(t[5]=n("h6",{class:"dropdown-header"},"Select order",-1)),n("div",Ij,[T(n("input",Mj,null,512),[[s,{state:e.viewState,set:o=>{e.orderBy=o},value:e.orderBy,form:null,options:{}}]]),t[0]||(t[0]=n("label",{class:"form-check-label",for:"sortFullName"},"Pull Request",-1))]),n("div",Vj,[T(n("input",qj,null,512),[[s,{state:e.viewState,set:o=>{e.orderBy=o},value:e.orderBy,form:null,options:{}}]]),t[1]||(t[1]=n("label",{class:"form-check-label",for:"sortAnonymizeDate"},"Anonymize Date",-1))]),n("div",_j,[T(n("input",Lj,null,512),[[s,{state:e.viewState,set:o=>{e.orderBy=o},value:e.orderBy,form:null,options:{}}]]),t[2]||(t[2]=n("label",{class:"form-check-label",for:"sortStatus"},"Status",-1))]),n("div",$j,[T(n("input",Fj,null,512),[[s,{state:e.viewState,set:o=>{e.orderBy=o},value:e.orderBy,form:null,options:{}}]]),t[3]||(t[3]=n("label",{class:"form-check-label",for:"sortLastView"},"Last View",-1))]),n("div",Uj,[T(n("input",Bj,null,512),[[s,{state:e.viewState,set:o=>{e.orderBy=o},value:e.orderBy,form:null,options:{}}]]),t[4]||(t[4]=n("label",{class:"form-check-label",for:"sortPageView"},"Page View",-1))])])]),n("div",zj,[t[11]||(t[11]=n("button",{class:"btn btn-sm dropdown-toggle",type:"button",id:"dropdownStatus","data-toggle":"dropdown","aria-haspopup":"true","aria-expanded":"false"}," Status ",-1)),n("div",Hj,[t[10]||(t[10]=n("h6",{class:"dropdown-header"},"Select status",-1)),n("div",jj,[T(n("input",Gj,null,512),[[s,{state:e.viewState,set:o=>{e.filters.status.ready=o},value:e.filters?.status?.ready,form:null,options:{}}]]),t[7]||(t[7]=n("label",{class:"form-check-label",for:"statusReady"},"Ready",-1))]),n("div",Wj,[T(n("input",Kj,null,512),[[s,{state:e.viewState,set:o=>{e.filters.status.expired=o},value:e.filters?.status?.expired,form:null,options:{}}]]),t[8]||(t[8]=n("label",{class:"form-check-label",for:"statusExpired"},"Expired",-1))]),n("div",Yj,[T(n("input",Xj,null,512),[[s,{state:e.viewState,set:o=>{e.filters.status.removed=o},value:e.filters?.status?.removed,form:null,options:{}}]]),t[9]||(t[9]=n("label",{class:"form-check-label",for:"statusRemoved"},"Removed",-1))])])])])])])),[[i,e.viewState]]),f(" Active filter chips "),T(n("div",Jj,[(a(!0),l(q,null,Q(e.filters?.status,(o,r,d)=>T((a(),l("span",Qj,[g(c(e.fmt?.title(r))+" ",1),n("button",{type:"button",class:"filter-chip-close","aria-label":"Remove filter",onClick:p=>{e.filters.status[r]=!0}}," \xD7 ",8,Zj)],512)),[[Z,!o]])),256))],512),[[Z,e.filters?.status?.ready===!1||e.filters?.status?.expired===!1||e.filters?.status?.removed===!1]])]),f(" Pull request list "),n("ul",xj,[(a(!0),l(q,null,Q(e.filteredPullRequests,(o,r)=>(a(),l("li",{class:P(["repo-list-item",{"repo-inactive":o?.status=="expired"||o?.status=="removed"||o?.status=="error"}])},[n("div",eG,[n("div",tG,[n("div",nG,[n("a",{class:"repo-name",textContent:c(o?.pullRequestId),href:e.safeUrl("/pr/"+o?.pullRequestId)},null,8,sG),n("span",{class:P(["status-badge",{"status-removed":o?.status=="removed"||o?.status=="expired"||o?.status=="removing"||o?.status=="expiring","status-preparing":o?.status=="preparing"||o?.status=="download","status-ready":o?.status=="ready","status-error":o?.status=="error"}])},[n("span",{textContent:c(e.fmt?.title(o?.status))},null,8,oG),o?.status=="error"?(a(),l("span",{key:0,textContent:c(": "+o?.statusMessage)},null,8,iG)):f("v-if",!0)],2)]),n("div",rG,[n("span",null,[t[13]||(t[13]=n("i",{class:"fab fa-github","aria-hidden":"true"},null,-1)),n("a",{href:e.safeUrl("https://github.com/"+o?.source?.repositoryFullName+"/pull/"+o?.source?.pullRequestId)},c(o?.source?.repositoryFullName)+"#"+c(o?.source?.pullRequestId),9,aG)]),n("span",{class:P(["status-badge",{"status-ready":o?.merged,"status-removed":o?.state=="open","status-error":o?.state=="closed"&&!o?.merged}]),style:{"font-size":"10px"}},c(e.fmt?.title(o?.merged?"merged":o?.state)),3),n("span",lG,"anonymized "+c(e.fmt?.humanTime(o?.anonymizeDate)),1)])]),n("div",dG,[o?.conference?(a(),l("span",uG,[t[14]||(t[14]=n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#project-icon-conference"})],-1)),g(" "+c(o?.conference),1)])):f("v-if",!0),n("span",{"data-toggle":"tooltip","data-placement":"bottom",title:"Terms: "+o?.options?.terms?.join(", ")},[t[15]||(t[15]=n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-shield"})],-1)),g(" "+c(e.fmt?.number(o?.options?.terms?.length)),1)],8,cG),n("span",{"data-toggle":"tooltip","data-placement":"bottom",title:"Views: "+e.fmt?.number(o?.pageView)},[t[16]||(t[16]=n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#project-icon-eye"})],-1)),g(" "+c(e.fmt?.number(o?.pageView)),1)],8,pG),n("span",{"data-toggle":"tooltip","data-placement":"bottom",title:"Last view: "+e.fmt?.date(o?.lastView)},[t[17]||(t[17]=n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-calendar"})],-1)),g(" "+c(e.fmt?.humanTime(o?.lastView)),1)],8,fG),o?.options?.expirationMode!="never"&&o?.status=="ready"?(a(),l("span",mG,[t[18]||(t[18]=n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#project-icon-clock"})],-1)),g(" Expire: "+c(e.fmt?.humanTime(o?.options?.expirationDate)),1)])):f("v-if",!0)])]),n("div",hG,[n("div",gG,[t[24]||(t[24]=n("button",{class:"btn btn-sm dropdown-toggle",type:"button","data-toggle":"dropdown","aria-haspopup":"true","aria-expanded":"false"}," Actions ",-1)),n("div",vG,[n("a",{class:"dropdown-item",href:e.safeUrl("/pull-request-anonymize/"+o?.pullRequestId)},[...t[19]||(t[19]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-edit"})],-1),g(" Edit ",-1)])],8,yG),T(n("a",{class:"dropdown-item",href:"#",onClick:ae(d=>e.updatePullRequest(o),["prevent"])},[...t[20]||(t[20]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-refresh"})],-1),g(" Force update ",-1)])],8,bG),[[Z,o?.status=="ready"||o?.status=="error"]]),T(n("a",{class:"dropdown-item",href:"#",onClick:ae(d=>e.updatePullRequest(o),["prevent"])},[...t[21]||(t[21]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-check-circle"})],-1),g(" Enable ",-1)])],8,wG),[[Z,o?.status=="removed"]]),T(n("a",{class:"dropdown-item",href:"#",onClick:ae(d=>e.removePullRequest(o),["prevent"])},[...t[22]||(t[22]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-trash"})],-1),g(" Remove ",-1)])],8,kG),[[Z,o?.status=="ready"]]),n("a",{class:"dropdown-item",href:e.safeUrl("/pr/"+o?.pullRequestId+"/")},[...t[23]||(t[23]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#project-icon-eye"})],-1),g(" View PR ",-1)])],8,CG)])])])],2))),256)),e.filteredPullRequests?.length==0?(a(),l("li",EG,[...t[25]||(t[25]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#project-icon-inbox"})],-1),n("span",null,"No pull requests to display.",-1)])])):f("v-if",!0)])])])}var SG={class:"container paper-page user-settings"},NG={class:"settings-nav","aria-label":"Settings"},RG=["aria-current","onClick"],PG={class:"settings-row"},DG=["rows"],AG={class:"settings-syntax"},TG={class:"invalid-feedback"},OG={class:"settings-row"},IG={class:"settings-checks"},MG={class:"settings-check"},VG={class:"form-check-input",type:"checkbox",id:"link",name:"link"},qG={class:"settings-check"},_G={class:"form-check-input",type:"checkbox",id:"image",name:"image"},LG={class:"settings-check"},$G={class:"form-check-input",type:"checkbox",id:"pdf",name:"pdf"},FG={class:"settings-check"},UG={class:"form-check-input",type:"checkbox",id:"notebook",name:"notebook"},BG={class:"settings-check"},zG={class:"form-check-input",type:"checkbox",id:"loc",name:"loc"},HG={class:"settings-check"},jG={class:"form-check-input",type:"checkbox",id:"page",name:"page"},GG={class:"settings-row"},WG={class:"settings-check"},KG={class:"form-check-input",type:"checkbox",id:"update",name:"update"},YG={class:"settings-row"},XG={class:"form-control",id:"expiration",name:"expiration"},JG={class:"settings-help"},QG={class:"settings-save"},ZG={class:"settings-save-status draft-status",role:"status"},xG={key:0},eW={key:1},tW={key:2},nW=["disabled"],sW={key:1,class:"settings-save-error",role:"alert"},oW=["aria-busy"],iW={key:0,role:"status"},rW={key:1,class:"settings-notice",role:"alert"},aW=["disabled"],lW={key:2,class:"settings-notice",role:"status"},dW={key:3,class:"settings-notice",role:"status"},uW=["disabled"],cW={class:"billing-summary"},pW={class:"billing-summary-head"},fW={class:"billing-plan-name"},mW={key:0,class:"billing-plan-meta"},hW={key:1,class:"billing-plan-meta"},gW={key:0,class:"billing-summary-actions"},vW=["disabled"],yW={id:"settings-quota"},bW={key:1,role:"status"},wW={key:0,class:"settings-notice"},kW={key:1,class:"settings-notice"},CW={key:2,class:"settings-notice"},EW={key:4,class:"billing-section","aria-labelledby":"settings-plan-comparison"},SW={key:0,class:"billing-offers"},NW={key:0,class:"billing-offer is-recommended"},RW={class:"billing-offer-price"},PW={class:"billing-offer-list"},DW=["disabled"],AW={key:1,class:"billing-offer"},TW={class:"billing-offer-head"},OW={class:"billing-toggle",role:"radiogroup","aria-label":"Billing frequency"},IW=["aria-checked","onClick"],MW={key:0,class:"billing-toggle-save"},VW={class:"billing-offer-price"},qW={class:"billing-offer-list"},_W=["disabled"],LW={key:1,class:"billing-addons"},$W={class:"billing-addon-rows"},FW={class:"billing-addon-price"},UW=["onClick","disabled"],BW={key:2,class:"billing-buy",id:"settings-addons-title",tabindex:"-1"},zW={class:"billing-buy-info"},HW={class:"billing-offer-price"},jW={class:"billing-offer-list"},GW={class:"billing-buy-form"},WW=["value"],KW=["disabled"],YW={key:1,class:"billing-buy-desc"},XW={key:2,class:"billing-footnote"},JW={class:"billing-compare"},QW={class:"billing-compare-card"},ZW={class:"settings-comparison"},xW={key:0,scope:"col",class:"is-recommended"},eK={key:1,scope:"col"},tK={key:0,class:"is-recommended"},nK={key:1},sK={key:0,class:"is-recommended"},oK={key:1},iK={key:0,class:"is-recommended"},rK={key:1},aK={key:0,class:"is-recommended"},lK={key:1},dK={key:0,class:"is-recommended"},uK={key:1},cK={key:0,class:"is-recommended"},pK={key:1},fK={key:3,class:"billing-footnote"},mK={key:5,class:"billing-section"},hK={class:"billing-section-head"},gK=["disabled"],vK={key:0,class:"billing-empty"},yK={key:1,class:"billing-history-head","aria-hidden":"true"},bK={key:2,class:"billing-history"},wK={class:"billing-history-main"},kK=["href"],CK=["href"],EK={class:"billing-history-term"},SK={class:"billing-history-paid"},NK={class:"billing-history-status"},RK={class:"billing-manage"},PK={key:0},DK={key:1},AK=["disabled"],TK={class:"billing-conference"},OK={id:"settings-account",class:"settings-account-panel"},IK={class:"paper-account-card"},MK=["src"],VK={class:"paper-account-identity"},qK={class:"paper-account-name"},_K=["disabled"],LK={key:0,role:"status"},$K={key:1,class:"paper-inline-alert paper-inline-alert-error",role:"alert"},FK=["disabled"],UK={key:3,role:"status"},BK={class:"paper-danger-zone"},zK={key:0,class:"paper-inline-alert paper-inline-alert-error",role:"alert"},HK=["textContent"],jK=["disabled"],GK={key:1,class:"settings-delete-confirm"},WK={for:"delete-username"},KK={class:"settings-actions"},YK=["disabled"],XK=["disabled"];function Cp(e,t){let s=Xe("quota-usage"),i=De("field"),o=De("form");return a(),l("div",SG,[t[107]||(t[107]=n("header",{class:"settings-title page-head page-head-main"},[n("h1",null,"Settings"),n("p",{class:"paper-page-lede"},"Defaults for new anonymizations, hosting and your account.")],-1)),n("nav",NG,[(a(),l(q,null,Q([{id:"defaults",label:"Anonymization defaults"},{id:"billing",label:"Hosting & billing"},{id:"account",label:"Account"}],r=>n("button",{type:"button","aria-current":e.settingsTab===r.id?"page":null,onClick:d=>e.settingsTab=r.id},c(r.label),9,RG)),64))]),T(n("div",null,[t[41]||(t[41]=n("p",{class:"settings-scope"},"For new anonymizations only. Existing repositories keep their settings.",-1)),T((a(),l("form",{class:"form needs-validation",name:"defaultsForm",novalidate:"",onInput:t[1]||(t[1]=r=>e.unsavedChanges=!0),onSubmit:t[2]||(t[2]=ae(r=>e.submitForm(r,()=>{e.saveDefault(r)}),["prevent"]))},[n("section",PG,[t[26]||(t[26]=n("div",null,[n("label",{class:"settings-label",for:"terms"},"Terms to redact"),n("p",{class:"settings-help"},"One term per line.")],-1)),n("div",null,[T(n("textarea",{class:"form-control",id:"terms",name:"terms",rows:Math.min(14,Math.max(3,String(e.terms||"").split(` `).length+1)),placeholder:`Jane Smith MIT CSAIL -jane.smith@example.org`},null,8,Mj),[[i,{state:e.viewState,set:r=>{e.terms=r},value:e.terms,form:"defaultsForm",options:{debounce:250}}]]),n("details",Vj,[t[25]||(t[25]=n("summary",null,"Regex & replacement syntax",-1)),n("p",null,[t[21]||(t[21]=g("Matches become ",-1)),n("code",null,c(e.site_options?.ANONYMIZATION_MASK||"XXX")+"-[N]",1),t[22]||(t[22]=g(". Use ",-1)),t[23]||(t[23]=n("code",null,"term=>replacement",-1)),t[24]||(t[24]=g(" for a custom replacement. Regex is supported.",-1))])]),D(n("div",qj,"Terms are in an invalid format.",512),[[Z,e.defaultsForm?.terms?.errors?.format]])])]),n("section",_j,[t[35]||(t[35]=n("h2",null,"Reviewer display",-1)),n("div",null,[n("div",Lj,[n("label",$j,[D(n("input",Fj,null,512),[[i,{state:e.viewState,set:r=>{e.options.link=r},value:e.options?.link,form:"defaultsForm",options:{}}]]),t[27]||(t[27]=g("Keep links",-1))]),n("label",Uj,[D(n("input",Bj,null,512),[[i,{state:e.viewState,set:r=>{e.options.image=r},value:e.options?.image,form:"defaultsForm",options:{}}]]),t[28]||(t[28]=g("Display images",-1))]),n("label",zj,[D(n("input",Hj,null,512),[[i,{state:e.viewState,set:r=>{e.options.pdf=r},value:e.options?.pdf,form:"defaultsForm",options:{}}]]),t[29]||(t[29]=g("Display PDFs",-1))]),n("label",jj,[D(n("input",Gj,null,512),[[i,{state:e.viewState,set:r=>{e.options.notebook=r},value:e.options?.notebook,form:"defaultsForm",options:{}}]]),t[30]||(t[30]=g("Display notebooks",-1))]),n("label",Wj,[D(n("input",Kj,null,512),[[i,{state:e.viewState,set:r=>{e.options.loc=r},value:e.options?.loc,form:"defaultsForm",options:{}}]]),t[31]||(t[31]=g("Show line counts",-1))]),n("label",Yj,[D(n("input",Xj,null,512),[[i,{state:e.viewState,set:r=>{e.options.page=r},value:e.options?.page,form:"defaultsForm",options:{}}]]),t[32]||(t[32]=g("GitHub Pages",-1))])]),t[33]||(t[33]=n("p",{class:"settings-help"},"Images and PDFs are not anonymized.",-1)),t[34]||(t[34]=n("p",{class:"settings-help"},"GitHub Pages must use the anonymized branch.",-1))])]),n("section",Jj,[t[38]||(t[38]=n("h2",null,"Source updates",-1)),n("div",null,[n("label",Qj,[D(n("input",Zj,null,512),[[i,{state:e.viewState,set:r=>{e.options.update=r},value:e.options?.update,form:"defaultsForm",options:{}}]]),t[36]||(t[36]=g("Auto-update from GitHub",-1))]),t[37]||(t[37]=n("p",{class:"settings-help"},"Latest commit, at most once an hour.",-1))])]),n("section",xj,[t[40]||(t[40]=n("label",{class:"settings-label",for:"expiration"},"On expiration",-1)),n("div",null,[D((a(),l("select",eG,[...t[39]||(t[39]=[n("option",{value:"redirect"},"Redirect visitors to the GitHub repository",-1),n("option",{value:"remove",selected:""},"Remove the anonymized repository",-1)])])),[[i,{state:e.viewState,set:r=>{e.options.expirationMode=r},value:e.options?.expirationMode,form:"defaultsForm",options:{}}]]),n("p",tG,c(e.options.expirationMode==="redirect"?"Redirecting reveals the original repository. Choose the date per anonymization.":"Set the expiration date for each repository."),1)])]),n("footer",nG,[n("div",sG,[e.draftRestored?(a(),l("span",oG,"Your unsaved draft was restored.")):e.unsavedChanges?(a(),l("span",iG,"Unsaved changes"+c(e.draftSaved?" \xB7 Draft saved in this tab":""),1)):(a(),l("span",rG,c(e.message?"Defaults saved":"No unsaved changes"),1))]),e.draftRestored||e.unsavedChanges?(a(),l("button",{key:0,type:"button",class:"draft-discard",onClick:t[0]||(t[0]=r=>e.discardDraft())},"Discard changes")):f("v-if",!0),n("button",{id:"save",type:"submit",class:A(["btn btn-ink",{"is-saving":e.saving}]),disabled:e.saving||!(e.unsavedChanges||e.draftRestored)},c(e.saving?"Saving\u2026":"Save defaults"),11,aG),e.error?(a(),l("div",lG,c(e.error),1)):f("v-if",!0)])],32)),[[o,e.viewState]])],512),[[Z,e.settingsTab==="defaults"]]),D(n("section",{id:"settings-billing","aria-busy":e.billingLoading||e.billingBusy},[t[95]||(t[95]=n("p",{class:"settings-scope"},"Your plan and usage. Reviewer access is always free.",-1)),e.billingLoading?(a(),l("p",uG,"Loading billing\u2026")):f("v-if",!0),e.billingError?(a(),l("div",cG,[g(c(e.billingError)+" ",1),n("button",{type:"button",class:"btn btn-outline-ink",onClick:t[3]||(t[3]=r=>e.loadBilling()),disabled:e.billingBusy},"Try again",8,pG)])):f("v-if",!0),e.billingNotice?(a(),l("p",fG,c(e.billingNotice),1)):f("v-if",!0),e.billingPending?(a(),l("div",hG,[t[42]||(t[42]=n("strong",null,"Confirming your payment",-1)),t[43]||(t[43]=n("p",null,"Your allowance will update after confirmation. Please do not pay again.",-1)),n("button",{type:"button",class:"btn btn-outline-ink",onClick:t[4]||(t[4]=r=>e.refreshBilling()),disabled:e.billingBusy},"Check payment status",8,mG)])):f("v-if",!0),n("section",gG,[n("div",vG,[n("div",null,[t[44]||(t[44]=n("p",{class:"billing-eyebrow"},"Current plan",-1)),n("h2",yG,c(e.profileAuthorGrant()?e.profileGrantName(e.profileAuthorGrant()):e.billing?.enabled?"Free":"Account allowance"),1),e.profileAuthorGrant()?(a(),l("p",bG,[g(c(e.profileAuthorGrant().cancelAtPeriodEnd?"Renewal cancelled \xB7 access until ":"Renews ")+c(e.billingDate(e.profileAuthorGrant().until)),1),e.profileAuthorPurchase()?.amount!=null?(a(),l(q,{key:0},[g(" \xB7 "+c(e.billingPrice(e.profileAuthorPurchase())),1)],64)):f("v-if",!0)])):e.billing?.allowance?(a(),l("p",wG,c(e.billing.allowance.repositories)+" repositories \xB7 "+c(e.billingBytes(e.billing.allowance.storage))+" \xB7 links up to "+c(e.billing.freeExpirationMonths||5)+" months",1)):f("v-if",!0)]),e.profileAuthorGrant()&&e.billing?.portal?(a(),l("div",kG,[n("button",{type:"button",class:"btn btn-outline-ink",onClick:t[5]||(t[5]=r=>e.billingPortal()),disabled:e.billingBusy},c(e.profileAuthorGrant().cancelAtPeriodEnd?"Resume renewal":"Change or cancel plan"),9,CG)])):f("v-if",!0)]),n("div",EG,[e.quota?(a(),Wt(s,{key:0,quota:e.quota,fmt:e.fmt},null,8,["quota","fmt"])):(a(),l("p",SG,"Loading usage\u2026"))]),e.quota?.repository&&!e.quota.repository.unlimited&&e.quota.repository.used>=e.quota.repository.total?(a(),l("p",NG,[g("Your free repositories are used up. Add the next one for "+c(e.profileSlotPlan()?e.billingPrice(e.profileSlotPlan()):"a one-time payment")+" when you create it, or ",1),t[45]||(t[45]=n("a",{href:"/dashboard"},"remove work you no longer need",-1)),t[46]||(t[46]=g(".",-1))])):f("v-if",!0),e.profileAuthorGrant()?.status==="past_due"?(a(),l("p",RG,"A subscription payment is overdue. Update your payment details in Manage billing and invoices.")):f("v-if",!0),e.profilePastSubscription()?(a(),l("p",AG,[...t[47]||(t[47]=[g("Your previous subscription has ended. Never-expiring repositories stay online for a 90-day grace period. ",-1),n("a",{href:"/dashboard"},"Review expiration dates",-1),g(".",-1)])])):f("v-if",!0),t[48]||(t[48]=n("p",{class:"billing-footnote"},"Co-authored, paid and conference repositories aren't counted here.",-1))]),e.billing?.enabled&&!e.profileAuthorGrant()&&(e.profilePackPlan()||e.profileAuthorPlans().length)?(a(),l("section",PG,[t[85]||(t[85]=n("h2",{class:"billing-section-title",id:"settings-plan-comparison",tabindex:"-1"},"Get more",-1)),e.showRepositoryPass&&e.profileAddon()&&!e.billingPending?f("v-if",!0):(a(),l("div",DG,[e.profilePackPlan()?(a(),l("article",TG,[t[54]||(t[54]=n("span",{class:"billing-offer-pill"},"Recommended",-1)),t[55]||(t[55]=n("div",{class:"billing-offer-head"},[n("p",{class:"billing-eyebrow"},"For one paper")],-1)),t[56]||(t[56]=n("h3",null,"Paper pack",-1)),n("p",OG,[n("strong",null,c(e.billingAmount(e.profilePackPlan())),1),t[49]||(t[49]=g(" once",-1))]),n("ul",IG,[t[50]||(t[50]=n("li",null,"One more repository, outside your free ones",-1)),n("li",null,"Its own "+c(e.billingBytes(e.profileSlotPlan()?.storage||e.profilePassPlan()?.storage))+" of storage",1),t[51]||(t[51]=n("li",null,"Automatic updates for 180 days",-1)),t[52]||(t[52]=n("li",null,"Online for up to a year",-1)),t[53]||(t[53]=n("li",null,"No subscription",-1))]),n("button",{type:"button",class:"btn btn-ink",onClick:t[6]||(t[6]=r=>e.openProfileAddon("repo_pack")),disabled:e.billingPending||e.billing.checkoutEnabled===!1},"Buy a Paper pack",8,MG)])):f("v-if",!0),e.profileAuthorPlans().length?(a(),l("article",VG,[n("div",qG,[t[57]||(t[57]=n("p",{class:"billing-eyebrow"},"For many papers",-1)),n("div",_G,[(a(!0),l(q,null,Q(e.profileAuthorPlansByValue(),r=>(a(),l("button",{type:"button",role:"radio",key:r.id,"aria-checked":e.profileSelectedPlan()?.id===r.id?"true":"false",class:A({"is-on":e.profileSelectedPlan()?.id===r.id}),onClick:d=>e.profilePlan=r.id},[g(c(r.interval==="year"?"Yearly":"Monthly"),1),r.interval==="year"&&e.profileAnnualSavings()?(a(),l("span",$G,"\u2212"+c(e.profileAnnualSavings())+"%",1)):f("v-if",!0)],10,LG))),128))])]),t[62]||(t[62]=n("h3",null,"Author subscription",-1)),n("p",FG,[n("strong",null,c(e.billingAmount(e.profileSelectedPlan())),1),g(" per "+c(e.profileSelectedPlan()?.interval==="year"?"year":"month"),1)]),n("ul",UG,[n("li",null,c(e.profileSelectedPlan()?.repositories)+" repositories, "+c(e.billingBytes(e.profileSelectedPlan()?.storage)),1),t[58]||(t[58]=n("li",null,"Automatic updates",-1)),t[59]||(t[59]=n("li",null,"Links that never expire",-1)),t[60]||(t[60]=n("li",null,"Coauthors included",-1)),t[61]||(t[61]=n("li",null,"Cancel renewal anytime",-1))]),n("button",{type:"button",class:"btn btn-outline-ink",disabled:e.billingBusy||e.billing.checkoutEnabled===!1,onClick:t[7]||(t[7]=r=>e.checkout(e.profileSelectedPlan().id))},c(e.billingBusy?"Please wait\u2026":"Subscribe"),9,BG)])):f("v-if",!0)])),e.profileSingleAddons().length&&!(e.showRepositoryPass&&e.profileAddon()&&!e.billingPending)?(a(),l("div",zG,[t[63]||(t[63]=n("div",{class:"billing-addons-head"},[n("h3",{class:"billing-subtitle"},"Or pay for one thing"),n("span",null,"One-time")],-1)),n("ul",HG,[(a(!0),l(q,null,Q(e.profileSingleAddons(),r=>(a(),l("li",{key:r.id},[n("div",null,[n("strong",null,c(r.name),1),n("span",null,c(e.profileAddonBlurb(r.id)),1)]),n("span",jG,c(e.billingAmount(r)),1),n("button",{type:"button",class:"settings-text-button",onClick:d=>e.openProfileAddon(r.id),disabled:e.billingPending||e.billing.checkoutEnabled===!1},"Buy",8,GG)]))),128))])])):f("v-if",!0),e.showRepositoryPass&&e.profileAddon()&&!e.billingPending?(a(),l("div",WG,[n("div",KG,[n("button",{type:"button",class:"btn btn-outline-ink billing-back",onClick:t[8]||(t[8]=r=>e.showRepositoryPass=!1)},"\u2190 All options"),n("h3",null,c(e.profileAddon().name),1),n("p",YG,[n("strong",null,c(e.billingAmount(e.profileAddon())),1),t[64]||(t[64]=g(" once",-1))]),n("ul",XG,[(a(!0),l(q,null,Q(e.profileAddonFeatures(e.profileAddon().id),r=>(a(),l("li",{key:r},c(r),1))),128))])]),n("div",JG,[e.profileRepositories().length?(a(),l(q,{key:0},[t[66]||(t[66]=n("label",{class:"paper-field-label",for:"billing-repository"},"Which repository?",-1)),D(n("select",{id:"billing-repository",class:"form-control","onUpdate:modelValue":t[9]||(t[9]=r=>e.billingRepository=r)},[t[65]||(t[65]=n("option",{value:"",disabled:""},"Choose a repository",-1)),(a(!0),l(q,null,Q(e.profileRepositories(),r=>(a(),l("option",{key:r.repoId,value:r.repoId},c(r.repoId)+" \xB7 "+c(e.profileRepositoryExpiry(r)),9,QG))),128))],512),[[Ut,e.billingRepository]]),n("button",{type:"button",class:"btn btn-ink",disabled:e.billingBusy||!e.billingRepository||e.billing.checkoutEnabled===!1,onClick:t[10]||(t[10]=r=>e.checkout(e.profileAddon().id,e.billingRepository))},c(e.billingBusy?"Please wait\u2026":"Continue to checkout"),9,ZG),t[67]||(t[67]=n("p",{class:"billing-footnote"},"One-time payment. Tax shown at checkout.",-1))],64)):(a(),l("p",xG,[...t[68]||(t[68]=[g("You have no repositories yet. ",-1),n("a",{href:"/anonymize"},"Create one",-1),g(" first.",-1)])])),["repo_slot","repo_pack"].includes(e.profileAddon().id)?(a(),l("p",eW,[...t[69]||(t[69]=[g("Adding a new repository? ",-1),n("a",{href:"/anonymize"},"Start creating it",-1),g("; the form offers this once your free repositories are in use.",-1)])])):f("v-if",!0)])])):f("v-if",!0),n("details",tW,[t[84]||(t[84]=n("summary",null,"Compare all features",-1)),n("div",nW,[n("table",sW,[t[83]||(t[83]=n("caption",{class:"sr-only"},"Free, Paper pack and Author hosting",-1)),n("thead",null,[n("tr",null,[t[72]||(t[72]=n("th",{scope:"col"},[n("span",{class:"sr-only"},"Feature")],-1)),t[73]||(t[73]=n("th",{scope:"col"},[g("Free"),n("small",null,"\u20AC0")],-1)),e.profilePackPlan()?(a(),l("th",oW,[t[70]||(t[70]=g("Paper pack",-1)),n("small",null,c(e.billingPrice(e.profilePackPlan())),1)])):f("v-if",!0),e.profileAuthorPlans().length?(a(),l("th",iW,[t[71]||(t[71]=g("Author",-1)),n("small",null,c(e.billingPrice(e.profileSelectedPlan())),1)])):f("v-if",!0)])]),n("tbody",null,[n("tr",null,[t[74]||(t[74]=n("th",{scope:"row"},"Repositories",-1)),n("td",null,c(e.billing.allowance?.repositories),1),e.profilePackPlan()?(a(),l("td",rW,"+1")):f("v-if",!0),e.profileAuthorPlans().length?(a(),l("td",aW,c(e.profileSelectedPlan()?.repositories),1)):f("v-if",!0)]),n("tr",null,[t[75]||(t[75]=n("th",{scope:"row"},"Source storage",-1)),n("td",null,c(e.billingBytes(e.billing.allowance?.storage))+" total",1),e.profilePackPlan()?(a(),l("td",lW,c(e.billingBytes(e.profileSlotPlan()?.storage||e.profilePassPlan()?.storage))+" for it",1)):f("v-if",!0),e.profileAuthorPlans().length?(a(),l("td",dW,c(e.billingBytes(e.profileSelectedPlan()?.storage))+" total",1)):f("v-if",!0)]),n("tr",null,[t[76]||(t[76]=n("th",{scope:"row"},"Latest expiration",-1)),n("td",null,c(e.billing.freeExpirationMonths||5)+" months ahead",1),e.profilePackPlan()?(a(),l("td",uW,"1 year after purchase")):f("v-if",!0),e.profileAuthorPlans().length?(a(),l("td",cW,"Never")):f("v-if",!0)]),n("tr",null,[t[77]||(t[77]=n("th",{scope:"row"},"Automatic updates",-1)),t[78]||(t[78]=n("td",null,"No",-1)),e.profilePackPlan()?(a(),l("td",pW,"180 days")):f("v-if",!0),e.profileAuthorPlans().length?(a(),l("td",fW,"Yes")):f("v-if",!0)]),n("tr",null,[t[79]||(t[79]=n("th",{scope:"row"},"Renews",-1)),t[80]||(t[80]=n("td",null,"No",-1)),e.profilePackPlan()?(a(),l("td",hW,"No")):f("v-if",!0),e.profileAuthorPlans().length?(a(),l("td",mW,"Until cancelled")):f("v-if",!0)]),n("tr",null,[t[81]||(t[81]=n("th",{scope:"row"},"Reviewer access",-1)),t[82]||(t[82]=n("td",null,"Free",-1)),e.profilePackPlan()?(a(),l("td",gW,"Free")):f("v-if",!0),e.profileAuthorPlans().length?(a(),l("td",vW,"Free")):f("v-if",!0)])])])])]),e.billing.checkoutEnabled===!1?(a(),l("p",yW,"New purchases are not available right now. Existing billing can still be managed below.")):f("v-if",!0)])):f("v-if",!0),e.billing?.enabled?(a(),l("section",bW,[n("div",wW,[t[86]||(t[86]=n("h2",{class:"billing-section-title"},"Purchases",-1)),e.billingPending?f("v-if",!0):(a(),l("button",{key:0,type:"button",class:"settings-text-button",onClick:t[11]||(t[11]=r=>e.refreshBilling()),disabled:e.billingBusy},"Refresh payment status",8,kW))]),(e.billing.purchases||[]).length?f("v-if",!0):(a(),l("p",CW,"No purchases yet.")),(e.billing.purchases||[]).length?(a(),l("div",EW,[...t[87]||(t[87]=[n("span",null,"Purchase",-1),n("span",null,"Period",-1),n("span",null,"Amount",-1),n("span",null,"Status",-1)])])):f("v-if",!0),(e.billing.purchases||[]).length?(a(),l("ul",SW,[(a(!0),l(q,null,Q(e.profilePurchases(!0).concat(e.profilePurchases(!1)),r=>(a(),l("li",{class:A(["billing-history-row",{"is-ended":!["active","overdue"].includes(r.status)}]),key:r.id},[n("div",NW,[n("strong",null,[g(c(e.profileGrantName(r)),1),r.repoId?(a(),l(q,{key:0},[t[88]||(t[88]=g(" \xB7 ",-1)),n("a",{href:"/anonymize/"+encodeURIComponent(r.repoId)},c(r.repoId),9,RW)],64)):r.conference?(a(),l(q,{key:1},[t[89]||(t[89]=g(" \xB7 ",-1)),n("a",{href:"/conference/"+encodeURIComponent(r.conference)},c(r.conference),9,AW)],64)):f("v-if",!0)]),n("span",null,c([r.purchasedAt?"Bought "+e.billingDate(r.purchasedAt):"",r.parts.length?e.profilePackSummary(r):["refunded","disputed"].includes(r.status)?"Payment "+r.status+", so what it paid for has ended":r.recurring?"Account subscription":""].filter(Boolean).join(" \xB7 ")),1)]),n("div",PW,c(e.profilePurchaseTerm(r)),1),n("div",DW,c(r.amount!=null?e.billingPrice(r):""),1),n("div",TW,[n("span",{class:A(["settings-status","is-"+r.status])},c(e.profilePurchaseStatus(r)),3)])],2))),128))])):f("v-if",!0),n("div",OW,[n("div",null,[t[90]||(t[90]=n("strong",null,"Invoices and payment details",-1)),e.billing.portal?(a(),l("p",IW,"Download receipts, update your card or change renewal in Stripe.")):(a(),l("p",MW,"Invoices appear here after your first purchase.")),t[91]||(t[91]=n("p",null,[g("Need a refund? "),n("a",{href:"mailto:tdurieux@anonymous.4open.science"},"Email the maintainer"),g(" with the payment date, or read the "),n("a",{href:"/faq#faq-plans"},"refund policy"),g(".")],-1))]),e.billing.portal?(a(),l("button",{key:0,type:"button",class:"btn btn-outline-ink",onClick:t[12]||(t[12]=r=>e.billingPortal()),disabled:e.billingBusy},"Manage billing and invoices",8,VW)):f("v-if",!0)])])):f("v-if",!0),n("p",qW,[t[92]||(t[92]=g("Organizing a conference? ",-1)),e.profileConferencePlan()?(a(),l(q,{key:0},[g("Review packages start at "+c(e.billingAmount(e.profileConferencePlan()))+" once for up to "+c(e.profileConferencePlan().repositories)+" submissions, and authors pay nothing.",1)],64)):(a(),l(q,{key:1},[g("One payment hosts every submission, and authors pay nothing.")],64)),t[93]||(t[93]=g()),t[94]||(t[94]=n("a",{href:"/conference/new"},"Create a conference",-1))])],8,dG),[[Z,e.settingsTab==="billing"]]),D(n("section",_W,[t[105]||(t[105]=n("p",{class:"settings-scope"},"Your identity, repository access, and account.",-1)),n("div",LW,[e.user?.photo?(a(),l("img",{key:0,width:"40",height:"40",class:"rounded-circle",alt:"",src:e.safeUrl(e.user?.photo)},null,8,$W)):f("v-if",!0),n("div",FW,[n("div",UW,"@"+c(e.user?.username),1),t[96]||(t[96]=n("div",{class:"paper-account-meta"},"Signed in with GitHub. Anonymous GitHub only reads your repositories.",-1))]),t[97]||(t[97]=n("a",{class:"btn btn-outline-ink",href:"/api/user/logout",target:"_self"},"Sign out",-1))]),n("form",{class:"paper-account-email",onSubmit:t[16]||(t[16]=ae(r=>e.saveAccountEmail(),["prevent"]))},[t[98]||(t[98]=n("label",{class:"paper-field-label",for:"account-email"},"Email address",-1)),t[99]||(t[99]=n("p",{id:"account-email-help",class:"paper-section-copy"},"Used for account alerts. Your address is never shown on anonymous pages.",-1)),D(n("input",{id:"account-email",class:"form-control",type:"email",autocomplete:"email",maxlength:"254",required:"","onUpdate:modelValue":t[13]||(t[13]=r=>e.accountEmail=r),"aria-describedby":"account-email-help",disabled:e.emailLoading||e.emailSaving||!e.emailCSRFReady,onInput:t[14]||(t[14]=r=>e.emailSaved=!1)},null,40,BW),[[pt,e.accountEmail]]),e.emailLoading?(a(),l("p",zW,"Loading your email address\u2026")):f("v-if",!0),e.emailError?(a(),l("p",HW,c(e.emailError),1)):f("v-if",!0),!e.emailCSRFReady&&!e.emailLoading?(a(),l("button",{key:2,class:"btn btn-outline-ink mt-2",type:"button",onClick:t[15]||(t[15]=r=>e.loadAccountEmail())},"Try again")):f("v-if",!0),n("button",{class:"btn btn-ink mt-2",type:"submit",disabled:e.emailLoading||e.emailSaving||!e.emailCSRFReady},c(e.emailSaving?"Saving\u2026":"Save email address"),9,jW),e.emailSaved?(a(),l("p",GW,"Email address saved.")):f("v-if",!0)],32),t[106]||(t[106]=n("a",{class:"paper-settings-connection-link",href:"/connections"},[n("i",{class:"fab fa-github","aria-hidden":"true"}),n("span",null,[g("GitHub connections"),n("small",null,"Manage repository access and legacy OAuth.")]),n("span",{"aria-hidden":"true"},"\u2192")],-1)),n("div",WW,[t[103]||(t[103]=n("div",{class:"paper-danger-head"},"Delete account",-1)),t[104]||(t[104]=n("p",{class:"paper-danger-copy"}," Removes all your anonymized repositories, gists, and pull requests, revokes the application's access to your GitHub account, and erases your personal data (username, email, access tokens). This cannot be undone. ",-1)),e.deleteError?(a(),l("div",KW,[t[100]||(t[100]=n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-info"})],-1)),t[101]||(t[101]=g()),n("span",{textContent:c(e.deleteError)},null,8,YW)])):f("v-if",!0),n("button",{type:"button",class:"btn btn-outline-danger",onClick:t[17]||(t[17]=r=>e.confirmDeleteAccount=!0),disabled:e.deletingAccount},[t[102]||(t[102]=n("svg",{class:"ui-icon mr-1","aria-hidden":"true"},[n("use",{href:"#ui-icon-trash"})],-1)),g(c(e.deletingAccount?"Deleting\u2026":"Delete my account"),1)],8,XW),e.confirmDeleteAccount?(a(),l("div",JW,[n("label",QW,"Type "+c(e.user?.username)+" to confirm",1),D(n("input",{id:"delete-username",class:"form-control","onUpdate:modelValue":t[18]||(t[18]=r=>e.deleteUsername=r),autocomplete:"off"},null,512),[[pt,e.deleteUsername]]),n("div",ZW,[n("button",{type:"button",class:"btn btn-outline-danger",onClick:t[19]||(t[19]=r=>e.deleteAccount()),disabled:e.deletingAccount||e.deleteUsername!==e.user?.username},c(e.deletingAccount?"Deleting\u2026":"Delete permanently"),9,xW),n("button",{type:"button",class:"btn btn-outline-ink",onClick:t[20]||(t[20]=r=>{e.confirmDeleteAccount=!1,e.deleteUsername=""}),disabled:e.deletingAccount},"Cancel",8,eK)])])):f("v-if",!0)])],512),[[Z,e.settingsTab==="account"]])])}var tK={class:"pr-page"},nK={class:"container paper-page pr-page-inner"},sK={class:"pr-header"},oK={class:"pr-title-row"},iK={class:"paper-page-title pr-title"},rK=["textContent"],aK={key:1,class:"text-muted"},lK=["href"],dK={class:"pr-header-meta"},uK={key:0,class:"pr-meta-item"},cK=["textContent"],pK={key:1,class:"pr-meta-item"},fK=["textContent"],hK={key:2,class:"pr-meta-item"},mK=["textContent"],gK={key:0,class:"pr-body-card"},vK={key:1,class:"paper-tabs",role:"tablist"},yK=["aria-selected","tabindex"],bK=["aria-selected","tabindex"],wK=["textContent"],kK={class:"paper-tab-content"},CK={key:0,role:"tabpanel",id:"pr-diff-panel","aria-labelledby":"pr-diff-tab"},EK=["innerHTML"],SK={key:1,role:"tabpanel",id:"pr-comments-panel","aria-labelledby":"pr-comments-tab"},NK={class:"pr-comments"},RK={class:"pr-comment"},AK={class:"pr-comment-head"},PK={key:0,class:"pr-comment-author"},DK=["textContent"],TK=["textContent"],OK={key:0,class:"pr-comment-body"},IK={key:0,class:"paper-table-empty"};function Ep(e,t){let s=Xe("markdown");return a(),l("div",tK,[n("div",nK,[t[17]||(t[17]=n("div",{class:"paper-crumbs"},[n("a",{href:"/dashboard"},"Reviewer"),g(" \xA0/\xA0 "),n("span",{class:"here"},"Pull request")],-1)),n("header",sK,[n("div",oK,[n("h1",iK,[e.details?.title?(a(),l("span",{key:0,textContent:c(e.details?.title)},null,8,rK)):f("v-if",!0),e.details?.title?f("v-if",!0):(a(),l("span",aK,"Untitled pull request"))]),e.options?.isAdmin||e.options?.isOwner?(a(),l("a",{key:0,class:"btn btn-sm","aria-label":"Edit",href:e.safeUrl("/pull-request-anonymize/"+e.pullRequestId)},[...t[4]||(t[4]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-edit"})],-1),n("span",{class:"d-none d-md-inline"}," Edit",-1)])],8,lK)):f("v-if",!0)]),n("div",dK,[n("span",{class:A(["paper-pill",{good:e.details?.merged,warn:e.details?.state=="open",bad:e.details?.state=="closed"&&!e.details?.merged}])},[n("span",{class:A(["status-dot",{"status-ready":e.details?.merged,"status-error":e.details?.state=="closed"&&!e.details?.merged}])},null,2),g(" "+c(e.details?.merged?"Merged":e.fmt.title(e.details?.state)),1)],2),e.details?.baseRepositoryFullName?(a(),l("span",uK,[t[5]||(t[5]=n("i",{class:"fab fa-github"},null,-1)),t[6]||(t[6]=g()),n("span",{textContent:c(e.details?.baseRepositoryFullName)},null,8,cK)])):f("v-if",!0),e.details?.updatedDate?(a(),l("span",pK,[t[7]||(t[7]=n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#project-icon-clock"})],-1)),t[8]||(t[8]=g()),n("span",{textContent:c(e.fmt?.date(e.details?.updatedDate))},null,8,fK)])):f("v-if",!0),e.details?.anonymizeDate?(a(),l("span",hK,[t[9]||(t[9]=n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-shield"})],-1)),t[10]||(t[10]=g(" Anonymized ",-1)),n("span",{textContent:c(e.fmt?.date(e.details?.anonymizeDate))},null,8,mK)])):f("v-if",!0)])]),e.details?.body?(a(),l("section",gK,[t[11]||(t[11]=n("div",{class:"paper-section-eyebrow"},"Description",-1)),Oe(s,{content:e.details?.body},null,8,["content"])])):f("v-if",!0),e.details?.diff||e.details?.comments?(a(),l("nav",vK,[e.details?.diff?(a(),l("button",{key:0,class:A(["paper-tab",{active:e.tabState?.active=="diff"}]),type:"button",role:"tab",id:"pr-diff-tab","aria-selected":e.tabState?.active==="diff","aria-controls":"pr-diff-panel",tabindex:e.tabState?.active==="diff"?0:-1,onKeydown:t[0]||(t[0]=i=>e.previewTabKeydown(i)),onClick:t[1]||(t[1]=i=>e.tabState.active="diff")},[...t[12]||(t[12]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-code"})],-1),g(" Diff ",-1)])],42,yK)):f("v-if",!0),e.details?.comments?(a(),l("button",{key:1,class:A(["paper-tab",{active:e.tabState?.active=="comments"}]),type:"button",role:"tab",id:"pr-comments-tab","aria-selected":e.tabState?.active==="comments","aria-controls":"pr-comments-panel",tabindex:e.tabState?.active==="comments"?0:-1,onKeydown:t[2]||(t[2]=i=>e.previewTabKeydown(i)),onClick:t[3]||(t[3]=i=>e.tabState.active="comments")},[t[13]||(t[13]=n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-comment"})],-1)),n("span",{textContent:c(e.fmt.plural(e.details?.comments?.length,{0:"No comments",one:"1 comment",other:"{} comments"}))},null,8,wK)],42,bK)):f("v-if",!0)])):f("v-if",!0),n("div",kK,[e.details?.diff&&e.tabState?.active=="diff"?(a(),l("div",CK,[n("div",{class:"pr-diff",innerHTML:e.sanitize(e.fmt?.diff(e.details?.diff))},null,8,EK)])):f("v-if",!0),e.details?.comments&&e.tabState?.active=="comments"?(a(),l("div",SK,[n("ul",NK,[(a(!0),l(q,null,Q(e.details?.comments,(i,o)=>(a(),l("li",RK,[n("div",AK,[i?.author?(a(),l("span",PK,[t[14]||(t[14]=n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-user"})],-1)),t[15]||(t[15]=g(" @",-1)),n("span",{textContent:c(i?.author)},null,8,DK)])):f("v-if",!0),i?.updatedDate?(a(),l("span",{key:1,class:"pr-comment-date",textContent:c(e.fmt?.date(i?.updatedDate))},null,8,TK)):f("v-if",!0)]),i?.body?(a(),l("div",OK,[Oe(s,{content:i?.body},null,8,["content"])])):f("v-if",!0)]))),256)),e.details?.comments?.length?f("v-if",!0):(a(),l("li",IK,[...t[16]||(t[16]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-comment"})],-1),n("span",null,"No comments on this pull request.",-1)])]))])])):f("v-if",!0)])])])}var MK={class:"repository-task status-page"},VK={class:"page-head-main"},qK={class:"task-lede"},_K={class:"task-columns"},LK={class:"task-preparation","aria-label":"Repository preparation"},$K={key:0,class:"text-danger",role:"alert"},FK={key:1,class:"paper-section-copy"},UK={key:2,class:"paper-ratelimit-card",role:"status"},BK={class:"paper-error-msg"},zK=["aria-valuenow"],HK={class:"paper-progress-label"},jK=["textContent"],GK={key:0},WK=["textContent"],KK={class:"paper-progress-pct"},YK={key:4,class:"paper-error-card",role:"alert"},XK={key:0,class:"paper-error-msg"},JK={key:1,class:"paper-error-msg"},QK={key:2},ZK=["href"],xK={class:"paper-error-actions"},eY=["href"],tY={key:5,class:"share-link"},nY={class:"share-link-row"},sY={class:"share-link-buttons"},oY={class:"ui-icon","aria-hidden":"true"},iY=["href"],rY=["textContent"],aY=["href"],lY={class:"share-link-note"},dY=["href"],uY={class:"share-link-next"},cY={class:"share-link-next-actions"},pY=["href"],fY={class:"task-summary","aria-label":"Repository summary"},hY=["title"],mY={key:1};function Sp(e,t){return a(),l("div",MK,[n("header",{class:A(["page-head",{"task-ready":e.repo?.status==="ready"}])},[t[3]||(t[3]=n("div",{class:"paper-crumbs"},[n("a",{href:"/dashboard"},"My work"),g(" \xA0/\xA0 "),n("span",{class:"here"},"Review link")],-1)),n("div",VK,[n("div",null,[n("h1",null,c(e.repo?.status==="ready"?"Your review link is ready":"Prepare your anonymous review link"),1),n("p",qK,c(e.repo?.status==="ready"?"Share this link with reviewers in your submission.":"Your settings are saved. Track preparation before sharing the link."),1)])]),t[4]||(t[4]=n("ol",{class:"task-trail flow-trail","aria-label":"Repository progress"},[n("li",null,"1. Repository"),n("li",null,"2. Review and hosting"),n("li",{"aria-current":"step"},"3. Review link")],-1))],2),n("div",_K,[n("section",LK,[e.error?(a(),l("p",$K,[t[5]||(t[5]=g("Unable to load repository status. ",-1)),n("button",{type:"button",class:"task-text-button",onClick:t[0]||(t[0]=s=>e.getStatus())},"Try again")])):f("v-if",!0),e.repo?.status!=="ready"?(a(),l("p",FK,[...t[6]||(t[6]=[g(" The repository will take a few minutes to get ready, depending on its size. Visit the ",-1),n("a",{href:"/faq"},"FAQ",-1),g(" for more information. ",-1)])])):f("v-if",!0),e.rateLimitResetAt?(a(),l("div",UK,[t[9]||(t[9]=Ce('
Temporarily paused
GitHub API rate limit reached
',1)),n("p",BK,[t[7]||(t[7]=g("Anonymization will resume automatically in ",-1)),n("strong",null,c(e.rateLimitCountdown),1),t[8]||(t[8]=g(". No action needed \u2014 the job is queued and will continue where it left off.",-1))])])):f("v-if",!0),e.repo?.status!=="ready"&&e.repo?.status!="error"&&!e.rateLimitResetAt?(a(),l("div",{key:3,class:A(["paper-progress",{"paper-progress-ready":e.repo?.status=="ready"}]),role:"progressbar","aria-valuemin":"0","aria-valuemax":"100","aria-valuenow":e.progress},[n("div",{class:"paper-progress-bar",style:Ie("width: "+e.progress+"%;")},null,4),n("div",HK,[n("span",{textContent:c(e.fmt?.title(e.repo?.status))},null,8,jK),e.repo?.statusMessage?(a(),l("span",GK,[t[10]||(t[10]=g("\xA0\xB7\xA0",-1)),n("span",{textContent:c(e.repo?.statusMessage)},null,8,WK)])):f("v-if",!0),n("span",KK,c(e.progress||0)+"%",1)])],10,zK)):f("v-if",!0),e.repo?.status=="error"&&!e.rateLimitResetAt?(a(),l("div",YK,[t[14]||(t[14]=Ce('
Anonymization failed
Something went wrong while preparing this repository.
',1)),e.repo?.statusMessage?(a(),l("p",XK,c(e.fmt?.translate("ERRORS."+e.repo?.statusMessage)),1)):f("v-if",!0),e.repo?.statusMessage?f("v-if",!0):(a(),l("p",JK,"No additional details were reported. The most common causes are private repositories, missing branches, and rate limits.")),e.repo?.statusMessage==="quota_exceeded"?(a(),l("p",QK,[n("a",{href:e.safeUrl("/anonymize/"+e.repoId)},"Review this repository\u2019s hosting",8,ZK),t[11]||(t[11]=g(", then retry preparation.",-1))])):f("v-if",!0),t[15]||(t[15]=n("ul",{class:"paper-error-hints"},[n("li",null,"Make sure the source URL points to a repository or pull request you can access."),n("li",null,"Check that the chosen branch and commit still exist on GitHub."),n("li",null,"If you just signed in, the access token may need a moment to propagate \u2014 try again.")],-1)),n("div",xK,[n("a",{class:"btn btn-primary",href:e.safeUrl("/anonymize/"+e.repoId)},[...t[12]||(t[12]=[n("svg",{class:"ui-icon mr-1","aria-hidden":"true"},[n("use",{href:"#ui-icon-edit"})],-1),g(" Edit anonymization",-1)])],8,eY),t[13]||(t[13]=Ce(' Read the FAQ Report a bug in Anonymous GitHub',2))])])):f("v-if",!0),e.repo?.status=="ready"?(a(),l("div",tY,[t[24]||(t[24]=n("div",{class:"share-link-label",id:"share-url-label"},"Review link",-1)),n("div",nY,[n("code",{id:"share-url",class:"share-link-url",tabindex:"0",role:"textbox","aria-readonly":"true","aria-labelledby":"share-url-label",onFocus:t[1]||(t[1]=s=>e.selectShareUrl(s))},c(e.shareUrl),33),n("div",sY,[n("button",{type:"button",class:"btn btn-primary share-copy",onClick:t[2]||(t[2]=s=>e.copyShareUrl())},[(a(),l("svg",oY,[n("use",{href:e.copied?"#ui-icon-check":"#project-icon-copy"},null,8,iY)])),n("span",{"aria-live":"polite",textContent:c(e.copied?"Copied":"Copy link")},null,8,rY)]),n("a",{class:"btn share-open",target:"_self",href:e.safeUrl("/r/"+e.repoId+"/")},[...t[16]||(t[16]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#project-icon-eye"})],-1),g(" Open repository ",-1)])],8,aY)])]),n("p",lY,[g(c(e.repo?.options?.expirationMode!=="never"&&e.repo?.options?.expirationDate?"Expires "+e.fmt.date(e.repo.options.expirationDate):"Never expires"),1),t[18]||(t[18]=n("span",{"aria-hidden":"true"}," \xB7 ",-1)),t[19]||(t[19]=g("Reviewers don\u2019t need an account",-1)),e.repo?.options?.page?(a(),l(q,{key:0},[t[17]||(t[17]=n("span",{"aria-hidden":"true"}," \xB7 ",-1)),n("a",{target:"_self",href:e.safeUrl("/w/"+e.repoId+"/")},"Open GitHub page",8,dY)],64)):f("v-if",!0)]),n("div",uY,[t[22]||(t[22]=n("h2",null,"Need to change something?",-1)),t[23]||(t[23]=n("p",null,"Edit the redacted terms or the expiry at any time. The link stays the same.",-1)),n("p",cY,[n("a",{href:e.safeUrl("/anonymize/"+e.repoId)},"Edit anonymization",8,pY),t[20]||(t[20]=n("span",{"aria-hidden":"true"},"\xB7",-1)),t[21]||(t[21]=n("a",{href:"/dashboard"},"Go to My work",-1))])])])):f("v-if",!0)]),n("aside",fY,[n("dl",null,[t[28]||(t[28]=n("dt",null,"Source",-1)),e.repo?.source?.fullName?(a(),l("dd",{key:0,class:"task-source",title:"https://github.com/"+e.repo.source.fullName},[t[25]||(t[25]=g("github.com/",-1)),t[26]||(t[26]=n("wbr",null,null,-1)),g(c(e.repo.source.fullName.split("/")[0])+"/",1),t[27]||(t[27]=n("wbr",null,null,-1)),g(c(e.repo.source.fullName.split("/").slice(1).join("/")),1)],8,hY)):(a(),l("dd",mY,"Loading\u2026")),t[29]||(t[29]=n("dt",null,"Lifetime",-1)),n("dd",null,c(e.repo?.options?.expirationMode==="never"?"Never expire while subscribed":e.repo?.options?.expirationDate?"Until "+e.fmt.date(e.repo.options.expirationDate):"Loading\u2026"),1),t[30]||(t[30]=n("dt",null,"Review access",-1)),t[31]||(t[31]=n("dd",null,"Anonymous and free",-1))])])])])}var gY={class:"container paper-page admin-page overview-page billing-page"},vY={class:"bl-toolbar"},yY={class:"seg-filter",role:"radiogroup","aria-label":"Period"},bY=["aria-checked","onClick"],wY={key:0,class:"bl-basis"},kY={key:0,class:"ov-performance-message ov-performance-warning bl-message",role:"alert"},CY={key:1,class:"ov-performance-message bl-message",role:"status"},EY={key:2,class:"ov-performance-message ov-performance-warning bl-message",role:"status"},SY=["aria-busy"],NY={class:"ov-kpi-card"},RY={class:"ov-kpi-value"},AY={class:"ov-kpi-sub"},PY={class:"ov-kpi-card"},DY={key:0,class:"ov-kpi-sub"},TY={key:1,class:"ov-kpi-sub"},OY={class:"ov-kpi-card"},IY={class:"ov-kpi-label"},MY={class:"ov-kpi-value"},VY={class:"ov-kpi-sub"},qY={class:"ov-kpi-card"},_Y={class:"ov-kpi-value"},LY={class:"ov-kpi-sub"},$Y={class:"ov-kpi-card"},FY={class:"ov-kpi-value"},UY={class:"ov-kpi-sub"},BY={class:"ov-kpi-card"},zY={class:"ov-kpi-sub"},HY={key:3,class:"bl-health","aria-label":"Webhook health"},jY={class:"bl-health-title"},GY={class:"bl-health-item"},WY=["title"],KY={key:1,class:"bl-health-item"},YY={key:4,class:"ov-chart-card bl-chart-card"},XY={class:"ov-chart-head"},JY={class:"ov-chart-title"},QY={key:0,class:"ov-chart-legends"},ZY=["aria-label"],xY={class:"ov-yaxis","aria-hidden":"true"},eX=["data-tip"],tX={class:"ov-spark-x bl-x"},nX={key:1,class:"ov-performance-empty bl-empty",role:"status"},sX={key:5,class:"ov-panel-card bl-plans","aria-labelledby":"bl-plans-heading"},oX={class:"ov-panel-head"},iX={class:"ov-panel-meta"},rX={class:"ov-metrics-scroll",tabindex:"0",role:"region","aria-label":"Sales by plan, scroll for more columns"},aX={class:"ov-metrics-table"},lX={key:0,scope:"colgroup",colspan:"2",class:"bl-group"},dX={scope:"row",class:"bl-plan-name"},uX=["title","onClick"],cX={class:"num"},pX={class:"num"},fX={class:"num"},hX={class:"num"},mX={class:"num"},gX={class:"num"},vX={class:"num"},yX={class:"num"},bX={class:"num"},wX={class:"num"},kX={class:"bl-grants",id:"bl-grants","aria-labelledby":"bl-grants-heading"},CX={class:"seg-bar"},EX={class:"seg-filter",role:"radiogroup","aria-label":"Filter by state"},SX=["aria-checked"],NX={class:"count"},RX=["aria-checked"],AX={class:"count"},PX=["aria-checked"],DX={class:"count"},TX=["aria-checked"],OX={class:"count"},IX={class:"seg-countline",role:"status"},MX={key:0,class:"alert alert-danger bl-alert"},VX=["aria-expanded"],qX={class:"search-wrap"},_X={type:"search",class:"form-control","aria-label":"Search by user",placeholder:"Search by user\u2026",autocomplete:"off"},LX={class:"admin-filter-inline"},$X={id:"bl-plan",class:"form-control form-control-sm"},FX=["label"],UX=["value"],BX={class:"admin-filter-inline"},zX={id:"bl-status",class:"form-control form-control-sm"},HX=["value"],jX={key:0,class:"admin-filter-inline","aria-label":"Pagination"},GX=["disabled"],WX={class:"bl-page"},KX=["disabled"],YX={key:0,class:"admin-filter-row"},XX={class:"admin-active-chips"},JX={class:"key"},QX=["onClick"],ZX={key:1,class:"ov-metrics-scroll bl-grant-scroll",tabindex:"0",role:"region","aria-label":"Subscriptions and purchases, scroll for more columns"},xX={class:"ov-metrics-table bl-grant-table"},eJ={scope:"col"},tJ={scope:"col"},nJ={scope:"row",class:"bl-user"},sJ=["title","href"],oJ={key:1,class:"ov-muted"},iJ={class:"bl-plan-cell"},rJ={key:0},aJ={class:"bl-state"},lJ={key:0},dJ={key:3},uJ={key:0,class:"bl-flag"},cJ={key:1,class:"ov-muted"},pJ={class:"bl-flag is-bad"},fJ={key:0},hJ={key:1,class:"ov-muted"},mJ={class:"bl-scope"},gJ=["href"],vJ={class:"ui-icon","aria-hidden":"true"},yJ=["href"],bJ={key:1,class:"ov-muted"},wJ={key:2,class:"paper-table-empty"},kJ={key:3,class:"admin-empty"},CJ={key:4,class:"admin-toolbar bl-pager"},EJ={key:0,class:"pagination-compact"},SJ=["disabled"],NJ=["max"],RJ=["disabled"],AJ={class:"admin-filter-inline"},PJ={id:"bl-limit",class:"form-control form-control-sm"};function Np(e,t){let s=Pe("field"),i=Pe("form");return a(),l("div",gY,[t[79]||(t[79]=Ce('
Admin \xA0/\xA0 Billing

Billing

',2)),n("div",vY,[n("div",yY,[(a(!0),l(q,null,Q(e.periods,o=>(a(),l("button",{type:"button",role:"radio",class:A(["seg-chip",{active:e.period===o.id}]),key:o.id,"aria-checked":e.period===o.id,onClick:r=>e.setPeriod(o.id)},c(o.label),11,bY))),128))]),e.summary?(a(),l("p",wY,"Sales are new checkouts and subscriptions. Revenue uses Stripe list prices; renewals count toward MRR.")):f("v-if",!0)]),e.summaryError?(a(),l("div",kY,[t[15]||(t[15]=n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-warning"})],-1)),n("span",null,c(e.summaryError),1),n("button",{type:"button",class:"btn btn-sm",onClick:t[0]||(t[0]=o=>e.loadSummary())},"Retry")])):f("v-if",!0),e.summary&&!e.summary.revenue?.available?(a(),l("div",CY,[...t[16]||(t[16]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-info"})],-1),n("span",null,[n("b",null,"Revenue unavailable."),g(" Stripe is not configured on this server, so amounts can't be looked up. Counts are complete.")],-1)])])):f("v-if",!0),e.summary?.revenue?.missingSales||e.summary?.revenue?.missingAllTimeSales||e.summary?.revenue?.missingSubscriptions?(a(),l("div",EY,[t[17]||(t[17]=n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-warning"})],-1)),n("span",null,"Some Stripe prices are unavailable. Affected totals are marked incomplete: "+c(e.fmt?.number(e.summary.revenue.missingSales||0))+" period sales, "+c(e.fmt?.number(e.summary.revenue.missingAllTimeSales||0))+" historical sales, "+c(e.fmt?.number(e.summary.revenue.missingSubscriptions||0))+" active subscriptions.",1)])):f("v-if",!0),f(" \u2500\u2500 Summary tiles \u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500 "),n("section",{class:A(["ov-kpi-row bl-kpi-row",{"is-loading":e.summaryLoading}]),"aria-busy":e.summaryLoading?"true":"false","aria-label":"Billing summary"},[!e.summary&&e.summaryLoading?(a(),l(q,{key:0},Q(6,o=>n("div",{class:"ov-kpi-card",key:o,"aria-hidden":"true"},[...t[18]||(t[18]=[n("span",{class:"skeleton skeleton-line-sm",style:{width:"60%"}},null,-1),n("span",{class:"skeleton bl-skeleton-value"},null,-1),n("span",{class:"skeleton skeleton-line-sm",style:{width:"80%"}},null,-1)])])),64)):f("v-if",!0),e.summary?(a(),l(q,{key:1},[n("div",NY,[t[19]||(t[19]=n("div",{class:"ov-kpi-label"},"Active subscriptions",-1)),n("div",RY,c(e.fmt?.number(e.summary.subscriptions.active)),1),n("div",AY,c(e.fmt?.number(e.summary.subscriptions.monthly))+" monthly \xB7 "+c(e.fmt?.number(e.summary.subscriptions.annual))+" annual",1)]),n("div",PY,[t[20]||(t[20]=n("div",{class:"ov-kpi-label"},"MRR",-1)),n("div",{class:A(["ov-kpi-value",{"bl-muted-value":!e.revenueOn()}])},c(e.revenueOn()?e.summary.subscriptions.complete===!1?"Incomplete":e.money(e.summary.subscriptions.mrr)[0]||e.fmt?.money(0):"Unavailable"),3),e.revenueOn()&&e.money(e.summary.subscriptions.mrr).length>1?(a(),l("div",DY,"+ "+c(e.money(e.summary.subscriptions.mrr).slice(1).join(" \xB7 ")),1)):(a(),l("div",TY,c(e.revenueOn()?"Annual plans \xF7 12":"Needs Stripe prices"),1))]),n("div",OY,[n("div",IY,"Sales \xB7 "+c(e.periodPhrase()),1),n("div",MY,c(e.fmt?.number(e.summary.sales.count)),1),n("div",VY,c(e.revenueOn()?e.summary.sales.complete===!1?"Revenue incomplete":e.moneyText(e.summary.sales.revenue,e.fmt?.money(0)):"Revenue unavailable"),1)]),n("div",qY,[t[21]||(t[21]=n("div",{class:"ov-kpi-label"},"All-time sales",-1)),n("div",_Y,c(e.fmt?.number(e.summary.allTime.count)),1),n("div",LY,c(e.revenueOn()?e.summary.allTime.complete===!1?"Revenue incomplete":e.moneyText(e.summary.allTime.revenue,e.fmt?.money(0)):"Revenue unavailable"),1)]),n("div",$Y,[t[22]||(t[22]=n("div",{class:"ov-kpi-label"},"Cancelling",-1)),n("div",FY,c(e.fmt?.number(e.summary.subscriptions.cancelling)),1),n("div",UY,"at period end, of "+c(e.fmt?.number(e.summary.subscriptions.active))+" active",1)]),n("div",BY,[t[23]||(t[23]=n("div",{class:"ov-kpi-label"},"Refunds & disputes",-1)),n("div",{class:A(["ov-kpi-value",{"ov-val-warn":e.summary.reversals.disputes>0}])},c(e.fmt?.number(e.summary.reversals.refunds+e.summary.reversals.disputes)),3),n("div",zY,c(e.fmt?.number(e.summary.reversals.refunds))+" "+c(e.summary.reversals.refunds===1?"refund":"refunds")+" \xB7 "+c(e.fmt?.number(e.summary.reversals.disputes))+" "+c(e.summary.reversals.disputes===1?"dispute":"disputes"),1)])],64)):f("v-if",!0)],10,SY),f(" \u2500\u2500 Webhook health \u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500 "),e.summary?.webhooks?(a(),l("section",HY,[n("span",jY,[n("span",{class:A(["ov-svc-dot",{"ov-dot-ok":e.webhookState()==="ok","ov-dot-warn":e.webhookState()==="warn","bl-dot-bad":e.webhookState()==="bad"}]),"aria-hidden":"true"},null,2),t[24]||(t[24]=g("Stripe webhooks",-1))]),n("span",GY,[t[25]||(t[25]=n("span",{class:"k"},"Pending",-1)),g(" "+c(e.fmt?.number(e.summary.webhooks.pending)),1),e.summary.webhooks.pending?(a(),l(q,{key:0},[g(" \xB7 oldest "+c(e.age(e.summary.webhooks.oldestPendingSeconds)),1)],64)):f("v-if",!0)]),n("span",{class:A(["bl-health-item",{"is-bad":e.summary.webhooks.failed}])},[t[26]||(t[26]=n("span",{class:"k"},"Failed",-1)),g(" "+c(e.fmt?.number(e.summary.webhooks.failed)),1)],2),e.summary.webhooks.lastError?(a(),l("span",{key:0,class:"bl-health-item bl-health-error",title:e.summary.webhooks.lastError.type+": "+e.summary.webhooks.lastError.error},[t[27]||(t[27]=n("span",{class:"k"},"Last error",-1)),t[28]||(t[28]=g()),n("code",null,c(e.summary.webhooks.lastError.error),1),g(" on "+c(e.summary.webhooks.lastError.type)+" \xB7 "+c(e.fmt?.humanTime(e.summary.webhooks.lastError.receivedAt)),1)],8,WY)):(a(),l("span",KY,[...t[29]||(t[29]=[n("span",{class:"k"},"Last error",-1),g(" none",-1)])])),n("span",{class:A(["bl-health-item",{"is-warn":e.summary.webhooks.unreviewedRevocations}])},[t[30]||(t[30]=n("span",{class:"k"},"Unreviewed reversals",-1)),g(" "+c(e.fmt?.number(e.summary.webhooks.unreviewedRevocations)),1)],2)])):f("v-if",!0),f(" \u2500\u2500 Sales over time \u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500 "),e.summary?(a(),l("section",YY,[n("div",XY,[n("span",JY,"Sales per "+c(e.bucketName())+" \xB7 "+c(e.periodPhrase()),1),e.seriesSales()?(a(),l("span",QY,[(a(!0),l(q,null,Q(e.families,o=>(a(),l("span",{class:"ov-chart-legend",key:o.id},[n("span",{class:A(["bl-swatch","bl-"+o.id]),"aria-hidden":"true"},null,2),g(c(o.label)+" \xB7 "+c(e.fmt?.number(e.familyTotal(o.id))),1)]))),128))])):f("v-if",!0)]),e.seriesSales()?(a(),l(q,{key:0},[n("div",{class:A(["ov-spark-bars ov-has-axis bl-bars",{"is-dense":e.summary.series.length>45}]),role:"img","aria-label":e.fmt?.number(e.seriesSales())+" sales, "+e.periodPhrase()+", by plan family"},[n("div",xY,[n("span",null,c(e.fmt?.number(e.chartMax())),1),n("span",null,c(e.fmt?.number(e.chartMax()/2)),1),t[31]||(t[31]=n("span",null,"0",-1))]),(a(!0),l(q,null,Q(e.summary.series,(o,r)=>(a(),l("div",{class:A(["ov-spark-col has-tip bl-col",{"is-zero":!e.bucketTotal(o)}]),key:r,"data-tip":e.bucketTip(o)},[n("span",{class:"bl-stack",style:Ie({height:e.bucketTotal(o)/e.chartMax()*100+"%"})},[(a(!0),l(q,null,Q(e.families,d=>D((a(),l("i",{key:d.id,class:A("bl-"+d.id),style:Ie({flexGrow:o[d.id]})},null,6)),[[Z,o[d.id]]])),128))],4)],10,eX))),128))],10,ZY),n("div",tX,[n("span",null,c(e.bucketLabel(e.summary.series[0])),1),n("span",null,c(e.bucketLabel(e.summary.series[Math.floor(e.summary.series.length/2)])),1),n("span",null,c(e.bucketLabel(e.summary.series[e.summary.series.length-1])),1)])],64)):(a(),l("p",nX,"No sales "+c(e.period==="all"?"yet":"in the "+e.periodPhrase())+".",1))])):f("v-if",!0),f(" \u2500\u2500 By plan \u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500 "),e.summary?(a(),l("section",sX,[n("div",oX,[t[32]||(t[32]=n("h2",{class:"ov-panel-title",id:"bl-plans-heading"},"By plan",-1)),n("span",iX,c(e.fmt?.number(e.plansWithActivity().length))+" of "+c(e.fmt?.number(e.summary.plans.length))+" plans sold",1)]),n("div",rX,[n("table",aX,[t[41]||(t[41]=n("caption",{class:"sr-only"},"Active grants, sales and revenue per plan",-1)),n("thead",null,[n("tr",null,[t[33]||(t[33]=n("th",{scope:"col",rowspan:"2"},"Plan",-1)),t[34]||(t[34]=n("th",{scope:"col",rowspan:"2",class:"num"},"Active",-1)),e.period!=="all"?(a(),l("th",lX,c(e.periodPhrase().replace(/^./,o=>o.toUpperCase())),1)):f("v-if",!0),t[35]||(t[35]=n("th",{scope:"colgroup",colspan:"2",class:"bl-group"},"All time",-1))]),n("tr",null,[e.period!=="all"?(a(),l(q,{key:0},[t[36]||(t[36]=n("th",{scope:"col",class:"num"},"Sales",-1)),t[37]||(t[37]=n("th",{scope:"col",class:"num"},"Revenue",-1))],64)):f("v-if",!0),t[38]||(t[38]=n("th",{scope:"col",class:"num"},"Sales",-1)),t[39]||(t[39]=n("th",{scope:"col",class:"num"},"Revenue",-1))])]),n("tbody",null,[(a(!0),l(q,null,Q(e.summary.plans,o=>(a(),l("tr",{key:o.planId,class:A({"bl-idle":!o.active&&!o.sales&&!o.allTimeSales})},[n("th",dX,[n("span",{class:A(["bl-swatch","bl-"+o.family]),"aria-hidden":"true"},null,2),n("button",{type:"button",class:"bl-link",title:"Show "+o.name+" grants",onClick:r=>e.filterPlan(o.planId)},c(o.name),9,uX)]),n("td",cX,c(e.fmt?.number(o.active)),1),e.period!=="all"?(a(),l(q,{key:0},[n("td",pX,c(e.fmt?.number(o.sales)),1),n("td",fX,c(e.revenueOn()?o.revenueComplete===!1?"Incomplete":e.moneyText(o.revenue):"\u2014"),1)],64)):f("v-if",!0),n("td",hX,c(e.fmt?.number(o.allTimeSales)),1),n("td",mX,c(e.revenueOn()?o.allTimeRevenueComplete===!1?"Incomplete":e.moneyText(o.allTimeRevenue):"\u2014"),1)],2))),128))]),n("tfoot",null,[n("tr",null,[t[40]||(t[40]=n("th",{scope:"row"},"Total",-1)),n("td",gX,c(e.fmt?.number(e.planTotals().active)),1),e.period!=="all"?(a(),l(q,{key:0},[n("td",vX,c(e.fmt?.number(e.planTotals().sales)),1),n("td",yX,c(e.revenueOn()?e.summary.sales.complete===!1?"Incomplete":e.moneyText(e.summary.sales.revenue):"\u2014"),1)],64)):f("v-if",!0),n("td",bX,c(e.fmt?.number(e.planTotals().allTimeSales)),1),n("td",wX,c(e.revenueOn()?e.summary.allTime.complete===!1?"Incomplete":e.moneyText(e.summary.allTime.revenue):"\u2014"),1)])])])]),t[42]||(t[42]=n("p",{class:"ov-performance-note bl-note"},"A paper pack counts once, under Paper pack. Active means paid time remains and the payment wasn't reversed.",-1))])):f("v-if",!0),f(" \u2500\u2500 Subscriptions and purchases \u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500 "),n("section",kX,[t[78]||(t[78]=n("div",{class:"bl-section-head"},[n("h2",{class:"ov-panel-title",id:"bl-grants-heading"},"Subscriptions and purchases")],-1)),n("div",CX,[n("div",EX,[n("button",{type:"button",role:"radio",class:A(["seg-chip",{active:e.stateView()==="all"}]),"aria-checked":e.stateView()==="all",onClick:t[1]||(t[1]=o=>e.setStateView("all"))},[t[43]||(t[43]=g("All ",-1)),n("span",NX,c(e.fmt?.number(e.stateCount("all"))),1)],10,SX),n("button",{type:"button",role:"radio",class:A(["seg-chip",{active:e.stateView()==="active","is-empty":!e.stateCount("active")}]),"aria-checked":e.stateView()==="active",onClick:t[2]||(t[2]=o=>e.setStateView("active"))},[t[44]||(t[44]=n("span",{class:"seg-dot ok","aria-hidden":"true"},null,-1)),t[45]||(t[45]=g("Active ",-1)),n("span",AX,c(e.fmt?.number(e.stateCount("active"))),1)],10,RX),n("button",{type:"button",role:"radio",class:A(["seg-chip",{active:e.stateView()==="expired","is-empty":!e.stateCount("expired")}]),"aria-checked":e.stateView()==="expired",onClick:t[3]||(t[3]=o=>e.setStateView("expired"))},[t[46]||(t[46]=n("span",{class:"seg-dot off","aria-hidden":"true"},null,-1)),t[47]||(t[47]=g("Expired ",-1)),n("span",DX,c(e.fmt?.number(e.stateCount("expired"))),1)],10,PX),n("button",{type:"button",role:"radio",class:A(["seg-chip",{active:e.stateView()==="revoked","is-empty":!e.stateCount("revoked")}]),"aria-checked":e.stateView()==="revoked",onClick:t[4]||(t[4]=o=>e.setStateView("revoked"))},[t[48]||(t[48]=n("span",{class:"seg-dot bad","aria-hidden":"true"},null,-1)),t[49]||(t[49]=g("Revoked ",-1)),n("span",OX,c(e.fmt?.number(e.stateCount("revoked"))),1)],10,TX)]),n("p",IX,[n("strong",null,c(e.total>=0?e.fmt.number(e.total):"\u2026"),1),t[50]||(t[50]=g(" shown",-1))])]),e.grantsError?(a(),l("div",MX,[t[51]||(t[51]=n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-warning"})],-1)),g(" "+c(e.grantsError)+" ",1),n("button",{type:"button",class:"btn btn-sm",onClick:t[5]||(t[5]=o=>e.reloadGrants())},"Retry")])):f("v-if",!0),D((a(),l("form",{class:"w-100 admin-filter-toolbar","aria-label":"Subscriptions and purchases","accept-charset":"UTF-8",onSubmit:t[9]||(t[9]=ae(()=>{},["prevent"]))},[n("button",{type:"button",class:"btn btn-sm admin-filters-toggle",onClick:t[6]||(t[6]=o=>e.filtersOpen=!e.filtersOpen),"aria-expanded":e.filtersOpen?"true":"false"},[t[52]||(t[52]=g("Filters",-1)),e.query.plan||e.query.status?(a(),l(q,{key:0},[g(" ("+c((e.query.plan?1:0)+(e.query.status?1:0))+")",1)],64)):f("v-if",!0)],8,VX),n("div",{class:A(["admin-filter-row",{"is-open":e.filtersOpen}])},[n("div",qX,[D(n("input",_X,null,512),[[s,{state:e.viewState,set:o=>{e.query.search=o},value:e.query?.search,form:null,options:{}}]])]),n("span",LX,[t[54]||(t[54]=n("label",{for:"bl-plan"},"Plan",-1)),D((a(),l("select",$X,[t[53]||(t[53]=n("option",{value:""},"Any",-1)),(a(!0),l(q,null,Q(e.families,o=>(a(),l("optgroup",{key:o.id,label:o.label},[(a(!0),l(q,null,Q((e.summary?.plans||[]).filter(r=>r.family===o.id),r=>(a(),l("option",{key:r.planId,value:r.planId},c(r.name),9,UX))),128))],8,FX))),128))])),[[s,{state:e.viewState,set:o=>{e.query.plan=o},value:e.query?.plan,form:null,options:{}}]])]),n("span",BX,[t[56]||(t[56]=n("label",{for:"bl-status"},"Stripe status",-1)),D((a(),l("select",zX,[t[55]||(t[55]=n("option",{value:""},"Any",-1)),(a(!0),l(q,null,Q(e.statuses,o=>(a(),l("option",{key:o,value:o},c(o.replace(/_/g," ")),9,HX))),128))])),[[s,{state:e.viewState,set:o=>{e.query.status=o},value:e.query?.status,form:null,options:{}}]])]),t[59]||(t[59]=n("span",{class:"admin-filter-spacer"},null,-1)),e.totalPage>1?(a(),l("span",jX,[n("button",{class:"btn btn-sm btn-icon",type:"button",onClick:t[7]||(t[7]=o=>e.query.page=Math.max(1,e.query.page-1)),disabled:e.query?.page<=1,"aria-label":"Previous page"},[...t[57]||(t[57]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-chevron-left"})],-1)])],8,GX),n("span",WX,c(e.query?.page)+"/"+c(e.totalPage||1),1),n("button",{class:"btn btn-sm btn-icon",type:"button",onClick:t[8]||(t[8]=o=>e.query.page=Math.min(e.totalPage,e.query.page+1)),disabled:e.query?.page>=e.totalPage,"aria-label":"Next page"},[...t[58]||(t[58]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-chevron-right"})],-1)])],8,KX)])):f("v-if",!0)],2),e.chips?.length?(a(),l("div",YX,[n("div",XX,[(a(!0),l(q,null,Q(e.chips,o=>(a(),l("span",{class:"admin-active-chip",key:o?.key},[n("span",JX,c(o?.label),1),n("span",null,c(o?.value),1),n("button",{type:"button",onClick:r=>e.clearFilter(o.key),"aria-label":"Clear filter"},[...t[60]||(t[60]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#project-icon-close"})],-1)])],8,QX)]))),128))])])):f("v-if",!0)],32)),[[i,e.viewState]]),e.grants?.length?(a(),l("div",ZX,[n("table",xX,[t[71]||(t[71]=n("caption",{class:"sr-only"},"Subscriptions and purchases",-1)),n("thead",null,[n("tr",null,[t[65]||(t[65]=n("th",{scope:"col"},"User",-1)),t[66]||(t[66]=n("th",{scope:"col"},"Plan",-1)),t[67]||(t[67]=n("th",{scope:"col"},"Status",-1)),n("th",eJ,[n("button",{type:"button",class:A(["sortable",{active:e.query?.sort=="purchasedAt"}]),onClick:t[10]||(t[10]=o=>e.sortBy("purchasedAt"))},[t[62]||(t[62]=g("Started ",-1)),e.sortIcon("purchasedAt")?(a(),l("svg",{key:0,class:A(["ui-icon sort-direction",{ascending:e.sortIcon("purchasedAt")==="fa-arrow-up"}]),"aria-hidden":"true"},[...t[61]||(t[61]=[n("use",{href:"#project-icon-arrow"},null,-1)])],2)):f("v-if",!0)],2)]),n("th",tJ,[n("button",{type:"button",class:A(["sortable",{active:e.query?.sort=="until"}]),onClick:t[11]||(t[11]=o=>e.sortBy("until"))},[t[64]||(t[64]=g("Renews / ends ",-1)),e.sortIcon("until")?(a(),l("svg",{key:0,class:A(["ui-icon sort-direction",{ascending:e.sortIcon("until")==="fa-arrow-up"}]),"aria-hidden":"true"},[...t[63]||(t[63]=[n("use",{href:"#project-icon-arrow"},null,-1)])],2)):f("v-if",!0)],2)]),t[68]||(t[68]=n("th",{scope:"col"},"Cancelling",-1)),t[69]||(t[69]=n("th",{scope:"col"},"Revoked",-1)),t[70]||(t[70]=n("th",{scope:"col"},"Applies to",-1))])]),n("tbody",null,[(a(!0),l(q,null,Q(e.grants,o=>(a(),l("tr",{key:o.id},[n("th",nJ,[o.user?(a(),l("a",{key:0,title:o.user,href:e.safeUrl("/admin/users/"+o.user)},c(o.user),9,sJ)):(a(),l("span",oJ,"Deleted user"))]),n("td",null,[n("span",iJ,[n("span",{class:A(["bl-swatch","bl-"+o.family]),"aria-hidden":"true"},null,2),g(c(e.planName(o.planId)),1)]),o.pack?(a(),l("small",rJ,"Part of a paper pack")):f("v-if",!0)]),n("td",null,[n("span",aJ,[n("span",{class:A(["status-dot",o.state==="active"?"st-ready":o.state==="revoked"?"st-error":"st-expired"])},null,2),g(c(o.state==="active"?"Active":o.state==="revoked"?"Revoked":"Expired"),1)]),["active","paid"].includes(o.status)?f("v-if",!0):(a(),l("small",lJ,"Stripe: "+c(e.statusText(o)),1))]),n("td",null,c(o.purchasedAt?e.fmt?.date(o.purchasedAt):"\u2014"),1),n("td",null,[o.never?(a(),l(q,{key:0},[g("Never ends")],64)):o.until?(a(),l(q,{key:1},[g(c(e.fmt?.date(o.until)),1)],64)):(a(),l(q,{key:2},[g("\u2014")],64)),o.subscription&&o.state==="active"?(a(),l("small",dJ,c(o.cancelAtPeriodEnd?"Ends":"Renews"),1)):f("v-if",!0)]),n("td",null,[o.cancelAtPeriodEnd?(a(),l("span",uJ,"Cancelling")):(a(),l("span",cJ,"\u2014"))]),n("td",null,[o.revoked?(a(),l(q,{key:0},[n("span",pJ,c(e.revocationText(o.revocationReason)),1),o.revokedAt?(a(),l("small",fJ,c(e.fmt?.date(o.revokedAt)),1)):f("v-if",!0)],64)):(a(),l("span",hJ,"\u2014"))]),n("td",mJ,[e.scopeHref(o.scope)?(a(),l("a",{key:0,href:e.safeUrl(e.scopeHref(o.scope))},[(a(),l("svg",vJ,[n("use",{href:o.scope.kind==="conference"?"#project-icon-conference":"#project-type-repo"},null,8,yJ)])),n("span",null,c(o.scope.id),1)],8,gJ)):(a(),l("span",bJ,"Account"))])]))),128))])])])):f("v-if",!0),e.total===0?(a(),l("div",wJ,[t[72]||(t[72]=n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#project-icon-inbox"})],-1)),n("span",null,c(e.hasFilters()?"No subscriptions or purchases match these filters.":"No subscriptions or purchases yet."),1),e.hasFilters()?(a(),l("button",{key:0,type:"button",class:"btn btn-sm",onClick:t[12]||(t[12]=o=>e.clearFilters())},"Clear filters")):f("v-if",!0)])):f("v-if",!0),e.total<0&&!e.grantsError?(a(),l("div",kJ,"Loading subscriptions and purchases\u2026")):f("v-if",!0),e.total>0?(a(),l("div",CJ,[t[77]||(t[77]=n("span",{"aria-hidden":"true"},null,-1)),e.totalPage>1?(a(),l("div",EJ,[n("button",{class:"btn btn-sm",onClick:t[13]||(t[13]=o=>e.query.page=Math.max(1,e.query.page-1)),disabled:e.query?.page<=1},[...t[73]||(t[73]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-chevron-left"})],-1),g(" Previous",-1)])],8,SJ),D(n("input",{type:"number",class:"form-control form-control-sm",min:"1",style:{width:"56px"},"aria-label":"Page",max:e.totalPage},null,8,NJ),[[s,{state:e.viewState,set:o=>{e.query.page=o},value:e.query?.page,form:null,options:{}}]]),n("span",null,"of "+c(e.totalPage),1),n("button",{class:"btn btn-sm",onClick:t[14]||(t[14]=o=>e.query.page=Math.min(e.totalPage,e.query.page+1)),disabled:e.query?.page>=e.totalPage},[...t[74]||(t[74]=[g("Next ",-1),n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-chevron-right"})],-1)])],8,RJ)])):f("v-if",!0),n("span",AJ,[t[76]||(t[76]=n("label",{for:"bl-limit"},"Per page",-1)),D((a(),l("select",PJ,[...t[75]||(t[75]=[n("option",{value:"10"},"10",-1),n("option",{value:"25"},"25",-1),n("option",{value:"50"},"50",-1),n("option",{value:"100"},"100",-1)])])),[[s,{state:e.viewState,set:o=>{e.query.limit=o},value:e.query?.limit,form:null,options:{}}]])])])):f("v-if",!0)])])}var DJ={class:"paper-footer"},TJ={class:"paper-footer-inner"},OJ={class:"paper-footer-col"},IJ={key:0,href:"/dashboard"},MJ={key:1,href:"/conferences"},VJ={class:"paper-footer-foot"};function Rp(e,t){return a(),l("footer",DJ,[n("div",TJ,[t[3]||(t[3]=n("div",{class:"paper-footer-brand"},[n("div",{class:"paper-footer-mark"},[g("Anonymous "),n("em",null,"GitHub")]),n("p",{class:"paper-footer-tag"}," A read-only, identity-stripped mirror of your repository, built for double-anonymous peer review. ")],-1)),n("div",OJ,[t[0]||(t[0]=n("div",{class:"paper-footer-head"},"Product",-1)),t[1]||(t[1]=n("a",{href:"/anonymize"},"Anonymize",-1)),e.user?(a(),l("a",IJ,"My work")):f("v-if",!0),e.user?(a(),l("a",MJ,"Conferences")):f("v-if",!0),t[2]||(t[2]=n("a",{href:"/faq"},"FAQ",-1))]),t[4]||(t[4]=Ce('',2))]),t[6]||(t[6]=n("div",{class:"paper-footer-rule"},null,-1)),n("div",VJ,[n("span",null,"\xA9 "+c(e.year||new Date().getFullYear())+" Anonymous GitHub \xB7 GPL-3.0 licensed",1),t[5]||(t[5]=n("span",{class:"paper-footer-meta"},"Built for reviewers, by researchers.",-1))])])}var ur={"partials/reviewConsent.htm":Jc,"partials/connections.htm":Qc,"partials/signin.htm":Zc,"partials/404.htm":xc,"partials/admin/billing.htm":Np,"partials/admin/emails.htm":Xc,"partials/admin/conferences.htm":ep,"partials/admin/errors.htm":tp,"partials/admin/overview.htm":np,"partials/admin/queues.htm":sp,"partials/admin/repositories.htm":op,"partials/admin/user.htm":ip,"partials/admin/users.htm":rp,"partials/anonymize.htm":ap,"partials/anonymizePullRequest.htm":lp,"partials/claim.htm":dp,"partials/conference.htm":up,"partials/conferences.htm":cp,"partials/dashboard.htm":pp,"partials/explorer.htm":fp,"partials/faq.htm":hp,"partials/gist.htm":mp,"partials/header.htm":gp,"partials/home.htm":vp,"partials/loading.htm":yp,"partials/newConference.htm":bp,"partials/pageView.htm":wp,"partials/pr-dashboard.htm":kp,"partials/profile.htm":Cp,"partials/pullRequest.htm":Ep,"partials/status.htm":Sp,"partials/footer.htm":Rp};var qJ={class:"ui-icon-definitions","aria-hidden":"true",focusable:"false"};function Ap(e,t){return a(),l("svg",qJ,[...t[0]||(t[0]=[Ce('',1)])])}function Pp(e,t){e==="partials/explorer.htm"&&(t.sidebarCollapsed=window.matchMedia?.("(max-width: 767px)").matches||!1,t.sidebarHidden=!1,t.dirExpanded=!1,t.moreOpen=!1,t.tocOpen=!1,t.gotoOpen=!1,t.gotoValue="",t.gotoError="",t.mdFindOpen=!1,t.mdFindQuery="",t.mdFindTotal=0,t.mdFindIndex=0,t.mdFindCase=!1,t.accountOpen=!1,t.helpOpen=!1,t.sidebarWidth=Math.min(520,Math.max(220,Number(localStorage.getItem("sidebarWidth"))||(window.innerWidth>=1280?320:280))),document.documentElement.style.setProperty("--sidebar-w",t.sidebarWidth+"px"),t.startSidebarResize=o=>{o.preventDefault();let r=o.clientX,d=t.sidebarWidth,p=y=>{t.sidebarWidth=Math.min(520,Math.max(220,d+y.clientX-r)),document.documentElement.style.setProperty("--sidebar-w",t.sidebarWidth+"px")},u=()=>{window.removeEventListener("pointermove",p),window.removeEventListener("pointerup",u),document.body.classList.remove("is-resizing"),localStorage.setItem("sidebarWidth",String(t.sidebarWidth))};document.body.classList.add("is-resizing"),window.addEventListener("pointermove",p),window.addEventListener("pointerup",u)}),e==="partials/anonymize.htm"&&(t.prTabState={active:t.options.diff?"diff":"comments"},t.watchGroup(["options.diff","options.comments"],()=>{t.options[t.prTabState.active]||(t.prTabState.active=t.options.diff?"diff":t.options.comments?"comments":null)})),e==="partials/gist.htm"&&(t.tabState={active:t.details?.files?"files":"comments"}),["partials/conferences.htm","partials/conference.htm"].includes(e)&&(t.statusLabels={ready:"Ready",expired:"Expired",removed:"Removed"});let i={"partials/dashboard.htm":["filteredItems",()=>t.items,"itemFilter"],"partials/conferences.htm":["filteredConferences",()=>t.conferences,"conferenceFilter"],"partials/conference.htm":["filteredRepositories",()=>t.conference?.repositories,"repoFiler"],"partials/admin/repositories.htm":["filteredRepositories",()=>t.repositories,"repoFiler"],"partials/admin/user.htm":["filteredRepositories",()=>t.repositories,"repoFiler"],"partials/admin/users.htm":["filteredUsers",()=>t.users,"userFiler"],"partials/admin/conferences.htm":["filteredConferences",()=>t.conferences]}[e];if(i){let o=Rt(()=>t.fmt.orderBy(t.fmt.filter(i[1](),t[i[2]]),t.orderBy));Object.defineProperty(t,i[0],{configurable:!0,get:()=>o.value})}}function Dp(e=(...t)=>fetch(...t)){async function t(i,o,r,d={}){let p=new URL(o,window.location.href);for(let[m,b]of Object.entries(d.params||{}))if(b!=null)for(let h of Array.isArray(b)?b:[b])p.searchParams.append(m,typeof h=="object"?JSON.stringify(h):h);let u=new AbortController,y;d.timeout?.then?d.timeout.then(()=>u.abort()):d.timeout&&(y=setTimeout(()=>u.abort(),d.timeout));try{let m={Accept:"application/json, text/plain, */*",...d.headers},b=document.cookie.match(/(?:^|;\s*)XSRF-TOKEN=([^;]*)/);b&&p.origin===window.location.origin&&(m["X-XSRF-TOKEN"]=decodeURIComponent(b[1]));let h;r!==void 0&&(r instanceof FormData?h=r:(m["Content-Type"]||(m["Content-Type"]="application/json;charset=utf-8"),h=JSON.stringify(r)));let w=await e(p.href,{method:i,headers:m,body:h,credentials:"same-origin",signal:u.signal}),R;if(d.onDownloadProgress&&w.ok&&w.body?.getReader&&typeof TextDecoder<"u"){let v=w.body.getReader(),E=new TextDecoder,M=[],V=0;try{for(;;){let{value:_,done:G}=await v.read();if(G)break;M.push(E.decode(_,{stream:!0})),V+=_.byteLength,d.onDownloadProgress(V)}M.push(E.decode()),R=M.join("")}finally{v.releaseLock()}}else R=await w.text();let S=R;if(d.transformResponse)S=d.transformResponse(R);else if(R&&(/json/i.test(w.headers.get("content-type")||"")||/^[\[{]/.test(R.trim())))try{S=JSON.parse(R)}catch{}let N={data:S,status:w.status,headers:v=>w.headers.get(v)};if(!w.ok)throw N;return N}catch(m){throw m.name==="AbortError"?{status:-1,data:null}:m}finally{clearTimeout(y)}}let s={};for(let i of["get","delete","head"])s[i]=(o,r)=>t(i.toUpperCase(),o,void 0,r);for(let i of["post","put","patch"])s[i]=(o,r,d)=>t(i.toUpperCase(),o,r,d);return s}var Tp={resolve:e=>Promise.resolve(e),reject:e=>Promise.reject(e),all:e=>Promise.all(e),defer(){let e,t;return{promise:new Promise((i,o)=>{e=i,t=o}),resolve:e,reject:t}}};var Op=function(e){function t(s){return s=s||{used:0,total:0},s.unlimited=!s.total,s.percent=s.unlimited?0:Math.min(100,s.used*100/s.total),s.level=s.unlimited?"unlimited":s.percent>=95?"danger":s.percent>=80?"warn":"ok",s}return{decorate:t,load:function(){return e.get("/api/user/quota").then(s=>{let i=s.data||{};return i.storage=t(i.storage),i.file=t(i.file),i.repository=t(i.repository),i})}}};var Ip={name:"htmlDoc",props:["content","baseUrl","allowScripts"],setup(e){let t=St(null);return hn(()=>{let i=[t.value][0];i.classList.add("html-doc");function o(){i.innerHTML="";let r=e.content;if(typeof r!="string")return;let d=document.createElement("iframe");d.className="html-doc-frame",d.setAttribute("title","Rendered HTML document");let p=["allow-popups","allow-popups-to-escape-sandbox"];e.allowScripts&&p.push("allow-scripts","allow-forms","allow-modals"),d.setAttribute("sandbox",p.join(" ")),d.setAttribute("referrerpolicy","no-referrer"),i.appendChild(d);let u="";e.baseUrl&&(u=''),d.srcdoc=u+r}dt(()=>e.content,o,{immediate:!0}),dt(()=>e.baseUrl,o,{immediate:!0}),dt(()=>e.allowScripts,o,{immediate:!0})}),()=>De("html-doc",{ref:t})}};var Mp={name:"pdfviewer",props:["src"],setup(e){let t=St(null);return hn(()=>{let s=[t.value],i=400,o=[.5,.75,1,1.25,1.5,2,3],r=1e3,d=s[0];d.classList.add("pdf-viewer");let p=null,u=[],y=!1,m=null,b=1,h=0,w=1,R=0,S=0,N=612/792,v=0,E=null,M=new Map,V=0;function _(T){let F=M.get(T);F&&(F.cancelled=!0,F.task?.cancel?.(),M.delete(T));let J=T.querySelector("canvas");J&&(J.width=0,J.height=0),T.innerHTML="",delete T.dataset.state}let G=document.createElement("div");G.className="pdf-toolbar";let te=document.createElement("div");te.className="pdf-pages",te.tabIndex=0,te.setAttribute("aria-label","PDF pages"),d.appendChild(G),d.appendChild(te);function X(T,F,J){let H=document.createElement("button");return H.type="button",H.className="pdf-toolbar-btn",H.title=F,H.setAttribute("aria-label",F),H.innerHTML='',H.addEventListener("click",J),H}let O=X("fa-chevron-up","Previous page",function(){Be(w-1)}),U=X("fa-chevron-down","Next page",function(){Be(w+1)}),C=document.createElement("input");C.type="text",C.className="pdf-toolbar-page",C.setAttribute("aria-label","Page number"),C.title="Page number \u2014 type a page and press Enter",C.addEventListener("keydown",function(T){T.key==="Enter"&&(Be(parseInt(C.value,10)),C.blur())}),C.addEventListener("blur",function(){C.value=String(w)});let L=document.createElement("span");L.className="pdf-toolbar-count";let z=X("fa-search-minus","Zoom out",function(){ve(o[Math.max(0,he()-1)])}),K=X("fa-search-plus","Zoom in",function(){ve(o[Math.min(o.length-1,he()+1)])}),ie=document.createElement("button");ie.type="button",ie.className="pdf-toolbar-btn pdf-toolbar-zoom",ie.title="Reset zoom to fit the width",ie.setAttribute("aria-label","Reset zoom to fit the width"),ie.addEventListener("click",function(){ve(1)}),G.appendChild(O),G.appendChild(U);let se=document.createElement("span");se.className="pdf-toolbar-group",se.appendChild(C),se.appendChild(L),G.appendChild(se);let Y=document.createElement("span");Y.className="pdf-toolbar-group pdf-toolbar-right",Y.appendChild(z),Y.appendChild(ie),Y.appendChild(K),G.appendChild(Y);function he(){let T=0;for(let F=0;F=T,ie.textContent=b===1||!h?"Fit":Math.round(Re()/(h*96/72)*100)+"%",z.disabled=he()===0,K.disabled=he()===o.length-1}function Ue(T){let F=u[T-1];F&&(te.scrollTop+=F.getBoundingClientRect().top-te.getBoundingClientRect().top)}function Be(T){if(!p||isNaN(T))return;let F=Math.min(Math.max(1,T),p.numPages);u[F-1]&&(Ue(F),w=F,R=F,S=Date.now()+800,Se(),W())}function Qe(){if(!u.length||Date.now(){}),E=null),m&&(clearTimeout(m),m=null),p&&(p.destroy(),p=null),u=[],w=1,te.innerHTML="",Se()}function et(){te.innerHTML="";let T=document.createElement("div");T.className="pdf-viewer-error",T.textContent="This PDF could not be displayed.",te.appendChild(T)}function Re(){let T=Math.max(120,te.clientWidth-24);return Math.round(Math.min(T,r)*b)}function Fe(T,F,J){let H=window.devicePixelRatio||1,x=T.getViewport({scale:1}),le=parseFloat(F.style.width);if(!le)return;let ne=T.getViewport({scale:le/x.width*H}),oe=document.createElement("canvas");return oe.width=Math.floor(ne.width),oe.height=Math.floor(ne.height),oe.style.width=le+"px",oe.style.height=Math.floor(ne.height/H)+"px",F.innerHTML="",F.appendChild(oe),F.style.height=oe.style.height,J.task=T.render({canvasContext:oe.getContext("2d"),viewport:ne}),J.task.promise}function W(){if(!p)return;let T=v,F=te.getBoundingClientRect(),J=F.top-i,H=F.top+te.clientHeight+i,x=u.map((ne,oe)=>({slot:ne,i:oe,rect:ne.getBoundingClientRect()})).filter(ne=>ne.rect.top<=H&&ne.rect.bottom>=J).sort((ne,oe)=>Math.abs(ne.rect.top-F.top)-Math.abs(oe.rect.top-F.top)).slice(0,6),le=new Set(x.map(ne=>ne.slot));for(let ne of M.keys())le.has(ne)||_(ne);for(let{slot:ne,i:oe}of x){if(ne.dataset.state||V>=2)continue;let ee={cancelled:!1,task:null};M.set(ne,ee),V++,ne.dataset.state="rendering";let ke;p.getPage(oe+1).then(pe=>{if(ke=pe,!(ee.cancelled||T!==v))return Fe(ke,ne,ee)}).then(()=>{ee.cancelled||T!==v||(ne.dataset.state="done",R&&Date.now(){!ee.cancelled&&T===v&&(ne.dataset.state="failed")}).finally(()=>{V--,ke?.cleanup?.(),p&&W()})}}function fe(){y||(y=!0,window.requestAnimationFrame(function(){y=!1,Qe(),W()}))}function de(){let T=!1;function F(){T||(T=!0,W())}window.requestAnimationFrame(F),window.setTimeout(F,50)}function ce(){v++,u.forEach(_);let T=Re();u.forEach(function(F){delete F.dataset.state,F.innerHTML="",F.style.width=T+"px",F.style.height=Math.round(T/N)+"px"}),W()}function ve(T){if(!p||!u.length||T===b)return;let F=w;b=T,Se(),ce(),Be(F)}function Me(){p&&(m&&clearTimeout(m),m=setTimeout(function(){m=null,p&&u.length&&ce()},250))}function P(T){if(He(),!T)return;let F=v;E=pdfjsLib.getDocument({url:T,isEvalSupported:!1,standardFontDataUrl:"/script/external/pdf-standard-fonts/",cMapUrl:"/script/external/pdf-cmaps/",cMapPacked:!0}),E.promise.then(function(J){if(F!==v){J.destroy();return}return p=J,p.getPage(1).then(function(H){if(F!==v)return;let x=H.getViewport({scale:1});x.width&&x.height&&(N=x.width/x.height),h=x.width||0;let le=Re();for(let ne=1;ne<=p.numPages;ne++){let oe=document.createElement("div");oe.className="pdf-viewer-page",oe.style.width=le+"px",oe.style.height=Math.round(le/N)+"px",te.appendChild(oe),u.push(oe)}Se(),de()})}).catch(function(){F===v&&et()})}te.addEventListener("scroll",fe,{passive:!0}),$(window).on("resize",Me),Se(),dt(()=>e.src,P,{immediate:!0}),is(function(){te.removeEventListener("scroll",fe),$(window).off("resize",Me),He()})}),()=>De("pdfviewer",{ref:t})}};var _J={key:0,class:"quota-row quota-usage"},LJ={class:"quota-header"},$J={class:"quota-label"},FJ={class:"project-type-svg","aria-hidden":"true"},UJ=["href"],BJ={key:0,class:"quota-percent"},zJ={key:1,class:"quota-unlimited-tag"},HJ={class:"quota-value"},jJ={key:0},GJ=["aria-label","aria-valuenow","aria-valuemax","aria-valuetext"],WJ={key:1,class:"quota-remaining"},KJ={key:2,class:"quota-remaining quota-limit"};function Vp(e,t){return e.quota?(a(),l("div",_J,[(a(),l(q,null,Q([{key:"repository",label:"Repositories",kind:"count",icon:"project-type-repo"},{key:"storage",label:"Storage",kind:"bytes",icon:"project-icon-storage"},{key:"file",label:"Files",kind:"count",icon:"project-icon-file"}],s=>n("div",{class:A(["quota-item","quota-"+e.quota[s.key].level]),key:s.key},[n("div",LJ,[n("span",$J,[(a(),l("svg",FJ,[n("use",{href:"#"+s.icon},null,8,UJ)])),g(c(s.label),1)]),e.quota[s.key].unlimited?f("v-if",!0):(a(),l("span",BJ,c(e.quota[s.key].percent>0&&e.quota[s.key].percent<1?"<1":e.fmt.number(e.quota[s.key].percent,0))+"% used",1)),e.quota[s.key].unlimited?(a(),l("span",zJ,"Unlimited")):f("v-if",!0)]),n("div",HJ,[n("strong",null,c(e.formatAmount(e.quota[s.key].used,s.kind)),1),e.quota[s.key].unlimited?f("v-if",!0):(a(),l("span",jJ," / "+c(e.formatAmount(e.quota[s.key].total,s.kind)),1))]),e.quota[s.key].unlimited?f("v-if",!0):(a(),l("div",{key:0,class:A(["quota-track","quota-"+e.quota[s.key].level]),role:"progressbar","aria-valuemin":"0","aria-label":s.label+" quota","aria-valuenow":Math.min(e.quota[s.key].used,e.quota[s.key].total),"aria-valuemax":e.quota[s.key].total,"aria-valuetext":e.fmt.number(e.quota[s.key].percent,0)+"% used"},[e.quota[s?.key].unlimited?f("v-if",!0):(a(),l("div",{key:0,class:"quota-fill",style:Ie({width:e.quota[s.key].percent+"%"})},null,4))],10,GJ)),!e.quota[s.key].unlimited&&e.quota[s.key].used=e.quota[s.key].total?(a(),l("p",KJ,c(e.quota[s.key].used>e.quota[s.key].total?"Limit exceeded":"Limit reached"),1)):f("v-if",!0)],2)),64))])):f("v-if",!0)}var YJ={props:["quota","fmt"],setup(e){return{formatAmount:(t,s)=>s==="bytes"?e.fmt.humanFileSize(e.quota?.storage?.unit==="bytes"?t*8:t).replace(/([a-zA-Z]+)$/," $1"):e.fmt.number(t)}},render:Vp},XJ=new Set(me),Lp=e=>e?.querySelectorAll("pre code.language-diff, pre code.lang-diff").forEach(t=>{if(t.querySelector(".md-diff-line"))return;let s=t.innerHTML.replace(/\n$/,"").split(` +jane.smith@example.org`},null,8,DG),[[i,{state:e.viewState,set:r=>{e.terms=r},value:e.terms,form:"defaultsForm",options:{debounce:250}}]]),n("details",AG,[t[25]||(t[25]=n("summary",null,"Regex & replacement syntax",-1)),n("p",null,[t[21]||(t[21]=g("Matches become ",-1)),n("code",null,c(e.site_options?.ANONYMIZATION_MASK||"XXX")+"-[N]",1),t[22]||(t[22]=g(". Use ",-1)),t[23]||(t[23]=n("code",null,"term=>replacement",-1)),t[24]||(t[24]=g(" for a custom replacement. Regex is supported.",-1))])]),T(n("div",TG,"Terms are in an invalid format.",512),[[Z,e.defaultsForm?.terms?.errors?.format]])])]),n("section",OG,[t[35]||(t[35]=n("h2",null,"Reviewer display",-1)),n("div",null,[n("div",IG,[n("label",MG,[T(n("input",VG,null,512),[[i,{state:e.viewState,set:r=>{e.options.link=r},value:e.options?.link,form:"defaultsForm",options:{}}]]),t[27]||(t[27]=g("Keep links",-1))]),n("label",qG,[T(n("input",_G,null,512),[[i,{state:e.viewState,set:r=>{e.options.image=r},value:e.options?.image,form:"defaultsForm",options:{}}]]),t[28]||(t[28]=g("Display images",-1))]),n("label",LG,[T(n("input",$G,null,512),[[i,{state:e.viewState,set:r=>{e.options.pdf=r},value:e.options?.pdf,form:"defaultsForm",options:{}}]]),t[29]||(t[29]=g("Display PDFs",-1))]),n("label",FG,[T(n("input",UG,null,512),[[i,{state:e.viewState,set:r=>{e.options.notebook=r},value:e.options?.notebook,form:"defaultsForm",options:{}}]]),t[30]||(t[30]=g("Display notebooks",-1))]),n("label",BG,[T(n("input",zG,null,512),[[i,{state:e.viewState,set:r=>{e.options.loc=r},value:e.options?.loc,form:"defaultsForm",options:{}}]]),t[31]||(t[31]=g("Show line counts",-1))]),n("label",HG,[T(n("input",jG,null,512),[[i,{state:e.viewState,set:r=>{e.options.page=r},value:e.options?.page,form:"defaultsForm",options:{}}]]),t[32]||(t[32]=g("GitHub Pages",-1))])]),t[33]||(t[33]=n("p",{class:"settings-help"},"Images and PDFs are not anonymized.",-1)),t[34]||(t[34]=n("p",{class:"settings-help"},"GitHub Pages must use the anonymized branch.",-1))])]),n("section",GG,[t[38]||(t[38]=n("h2",null,"Source updates",-1)),n("div",null,[n("label",WG,[T(n("input",KG,null,512),[[i,{state:e.viewState,set:r=>{e.options.update=r},value:e.options?.update,form:"defaultsForm",options:{}}]]),t[36]||(t[36]=g("Auto-update from GitHub",-1))]),t[37]||(t[37]=n("p",{class:"settings-help"},"Latest commit, at most once an hour.",-1))])]),n("section",YG,[t[40]||(t[40]=n("label",{class:"settings-label",for:"expiration"},"On expiration",-1)),n("div",null,[T((a(),l("select",XG,[...t[39]||(t[39]=[n("option",{value:"redirect"},"Redirect visitors to the GitHub repository",-1),n("option",{value:"remove",selected:""},"Remove the anonymized repository",-1)])])),[[i,{state:e.viewState,set:r=>{e.options.expirationMode=r},value:e.options?.expirationMode,form:"defaultsForm",options:{}}]]),n("p",JG,c(e.options.expirationMode==="redirect"?"Redirecting reveals the original repository. Choose the date per anonymization.":"Set the expiration date for each repository."),1)])]),n("footer",QG,[n("div",ZG,[e.draftRestored?(a(),l("span",xG,"Your unsaved draft was restored.")):e.unsavedChanges?(a(),l("span",eW,"Unsaved changes"+c(e.draftSaved?" \xB7 Draft saved in this tab":""),1)):(a(),l("span",tW,c(e.message?"Defaults saved":"No unsaved changes"),1))]),e.draftRestored||e.unsavedChanges?(a(),l("button",{key:0,type:"button",class:"draft-discard",onClick:t[0]||(t[0]=r=>e.discardDraft())},"Discard changes")):f("v-if",!0),n("button",{id:"save",type:"submit",class:P(["btn btn-ink",{"is-saving":e.saving}]),disabled:e.saving||!(e.unsavedChanges||e.draftRestored)},c(e.saving?"Saving\u2026":"Save defaults"),11,nW),e.error?(a(),l("div",sW,c(e.error),1)):f("v-if",!0)])],32)),[[o,e.viewState]])],512),[[Z,e.settingsTab==="defaults"]]),T(n("section",{id:"settings-billing","aria-busy":e.billingLoading||e.billingBusy},[t[95]||(t[95]=n("p",{class:"settings-scope"},"Your plan and usage. Reviewer access is always free.",-1)),e.billingLoading?(a(),l("p",iW,"Loading billing\u2026")):f("v-if",!0),e.billingError?(a(),l("div",rW,[g(c(e.billingError)+" ",1),n("button",{type:"button",class:"btn btn-outline-ink",onClick:t[3]||(t[3]=r=>e.loadBilling()),disabled:e.billingBusy},"Try again",8,aW)])):f("v-if",!0),e.billingNotice?(a(),l("p",lW,c(e.billingNotice),1)):f("v-if",!0),e.billingPending?(a(),l("div",dW,[t[42]||(t[42]=n("strong",null,"Confirming your payment",-1)),t[43]||(t[43]=n("p",null,"Your allowance will update after confirmation. Please do not pay again.",-1)),n("button",{type:"button",class:"btn btn-outline-ink",onClick:t[4]||(t[4]=r=>e.refreshBilling()),disabled:e.billingBusy},"Check payment status",8,uW)])):f("v-if",!0),n("section",cW,[n("div",pW,[n("div",null,[t[44]||(t[44]=n("p",{class:"billing-eyebrow"},"Current plan",-1)),n("h2",fW,c(e.profileAuthorGrant()?e.profileGrantName(e.profileAuthorGrant()):e.billing?.enabled?"Free":"Account allowance"),1),e.profileAuthorGrant()?(a(),l("p",mW,[g(c(e.profileAuthorGrant().cancelAtPeriodEnd?"Renewal cancelled \xB7 access until ":"Renews ")+c(e.billingDate(e.profileAuthorGrant().until)),1),e.profileAuthorPurchase()?.amount!=null?(a(),l(q,{key:0},[g(" \xB7 "+c(e.billingPrice(e.profileAuthorPurchase())),1)],64)):f("v-if",!0)])):e.billing?.allowance?(a(),l("p",hW,c(e.billing.allowance.repositories)+" repositories \xB7 "+c(e.billingBytes(e.billing.allowance.storage))+" \xB7 links up to "+c(e.billing.freeExpirationMonths||5)+" months",1)):f("v-if",!0)]),e.profileAuthorGrant()&&e.billing?.portal?(a(),l("div",gW,[n("button",{type:"button",class:"btn btn-outline-ink",onClick:t[5]||(t[5]=r=>e.billingPortal()),disabled:e.billingBusy},c(e.profileAuthorGrant().cancelAtPeriodEnd?"Resume renewal":"Change or cancel plan"),9,vW)])):f("v-if",!0)]),n("div",yW,[e.quota?(a(),Gt(s,{key:0,quota:e.quota,fmt:e.fmt},null,8,["quota","fmt"])):(a(),l("p",bW,"Loading usage\u2026"))]),e.quota?.repository&&!e.quota.repository.unlimited&&e.quota.repository.used>=e.quota.repository.total?(a(),l("p",wW,[g("Your free repositories are used up. Add the next one for "+c(e.profileSlotPlan()?e.billingPrice(e.profileSlotPlan()):"a one-time payment")+" when you create it, or ",1),t[45]||(t[45]=n("a",{href:"/dashboard"},"remove work you no longer need",-1)),t[46]||(t[46]=g(".",-1))])):f("v-if",!0),e.profileAuthorGrant()?.status==="past_due"?(a(),l("p",kW,"A subscription payment is overdue. Update your payment details in Manage billing and invoices.")):f("v-if",!0),e.profilePastSubscription()?(a(),l("p",CW,[...t[47]||(t[47]=[g("Your previous subscription has ended. Never-expiring repositories stay online for a 90-day grace period. ",-1),n("a",{href:"/dashboard"},"Review expiration dates",-1),g(".",-1)])])):f("v-if",!0),t[48]||(t[48]=n("p",{class:"billing-footnote"},"Co-authored, paid and conference repositories aren't counted here.",-1))]),e.billing?.enabled&&!e.profileAuthorGrant()&&(e.profilePackPlan()||e.profileAuthorPlans().length)?(a(),l("section",EW,[t[85]||(t[85]=n("h2",{class:"billing-section-title",id:"settings-plan-comparison",tabindex:"-1"},"Get more",-1)),e.showRepositoryPass&&e.profileAddon()&&!e.billingPending?f("v-if",!0):(a(),l("div",SW,[e.profilePackPlan()?(a(),l("article",NW,[t[54]||(t[54]=n("span",{class:"billing-offer-pill"},"Recommended",-1)),t[55]||(t[55]=n("div",{class:"billing-offer-head"},[n("p",{class:"billing-eyebrow"},"For one paper")],-1)),t[56]||(t[56]=n("h3",null,"Paper pack",-1)),n("p",RW,[n("strong",null,c(e.billingAmount(e.profilePackPlan())),1),t[49]||(t[49]=g(" once",-1))]),n("ul",PW,[t[50]||(t[50]=n("li",null,"One more repository, outside your free ones",-1)),n("li",null,"Its own "+c(e.billingBytes(e.profileSlotPlan()?.storage||e.profilePassPlan()?.storage))+" of storage",1),t[51]||(t[51]=n("li",null,"Automatic updates for 180 days",-1)),t[52]||(t[52]=n("li",null,"Online for up to a year",-1)),t[53]||(t[53]=n("li",null,"No subscription",-1))]),n("button",{type:"button",class:"btn btn-ink",onClick:t[6]||(t[6]=r=>e.openProfileAddon("repo_pack")),disabled:e.billingPending||e.billing.checkoutEnabled===!1},"Buy a Paper pack",8,DW)])):f("v-if",!0),e.profileAuthorPlans().length?(a(),l("article",AW,[n("div",TW,[t[57]||(t[57]=n("p",{class:"billing-eyebrow"},"For many papers",-1)),n("div",OW,[(a(!0),l(q,null,Q(e.profileAuthorPlansByValue(),r=>(a(),l("button",{type:"button",role:"radio",key:r.id,"aria-checked":e.profileSelectedPlan()?.id===r.id?"true":"false",class:P({"is-on":e.profileSelectedPlan()?.id===r.id}),onClick:d=>e.profilePlan=r.id},[g(c(r.interval==="year"?"Yearly":"Monthly"),1),r.interval==="year"&&e.profileAnnualSavings()?(a(),l("span",MW,"\u2212"+c(e.profileAnnualSavings())+"%",1)):f("v-if",!0)],10,IW))),128))])]),t[62]||(t[62]=n("h3",null,"Author subscription",-1)),n("p",VW,[n("strong",null,c(e.billingAmount(e.profileSelectedPlan())),1),g(" per "+c(e.profileSelectedPlan()?.interval==="year"?"year":"month"),1)]),n("ul",qW,[n("li",null,c(e.profileSelectedPlan()?.repositories)+" repositories, "+c(e.billingBytes(e.profileSelectedPlan()?.storage)),1),t[58]||(t[58]=n("li",null,"Automatic updates",-1)),t[59]||(t[59]=n("li",null,"Links that never expire",-1)),t[60]||(t[60]=n("li",null,"Coauthors included",-1)),t[61]||(t[61]=n("li",null,"Cancel renewal anytime",-1))]),n("button",{type:"button",class:"btn btn-outline-ink",disabled:e.billingBusy||e.billing.checkoutEnabled===!1,onClick:t[7]||(t[7]=r=>e.checkout(e.profileSelectedPlan().id))},c(e.billingBusy?"Please wait\u2026":"Subscribe"),9,_W)])):f("v-if",!0)])),e.profileSingleAddons().length&&!(e.showRepositoryPass&&e.profileAddon()&&!e.billingPending)?(a(),l("div",LW,[t[63]||(t[63]=n("div",{class:"billing-addons-head"},[n("h3",{class:"billing-subtitle"},"Or pay for one thing"),n("span",null,"One-time")],-1)),n("ul",$W,[(a(!0),l(q,null,Q(e.profileSingleAddons(),r=>(a(),l("li",{key:r.id},[n("div",null,[n("strong",null,c(r.name),1),n("span",null,c(e.profileAddonBlurb(r.id)),1)]),n("span",FW,c(e.billingAmount(r)),1),n("button",{type:"button",class:"settings-text-button",onClick:d=>e.openProfileAddon(r.id),disabled:e.billingPending||e.billing.checkoutEnabled===!1},"Buy",8,UW)]))),128))])])):f("v-if",!0),e.showRepositoryPass&&e.profileAddon()&&!e.billingPending?(a(),l("div",BW,[n("div",zW,[n("button",{type:"button",class:"btn btn-outline-ink billing-back",onClick:t[8]||(t[8]=r=>e.showRepositoryPass=!1)},"\u2190 All options"),n("h3",null,c(e.profileAddon().name),1),n("p",HW,[n("strong",null,c(e.billingAmount(e.profileAddon())),1),t[64]||(t[64]=g(" once",-1))]),n("ul",jW,[(a(!0),l(q,null,Q(e.profileAddonFeatures(e.profileAddon().id),r=>(a(),l("li",{key:r},c(r),1))),128))])]),n("div",GW,[e.profileRepositories().length?(a(),l(q,{key:0},[t[66]||(t[66]=n("label",{class:"paper-field-label",for:"billing-repository"},"Which repository?",-1)),T(n("select",{id:"billing-repository",class:"form-control","onUpdate:modelValue":t[9]||(t[9]=r=>e.billingRepository=r)},[t[65]||(t[65]=n("option",{value:"",disabled:""},"Choose a repository",-1)),(a(!0),l(q,null,Q(e.profileRepositories(),r=>(a(),l("option",{key:r.repoId,value:r.repoId},c(r.repoId)+" \xB7 "+c(e.profileRepositoryExpiry(r)),9,WW))),128))],512),[[Wt,e.billingRepository]]),n("button",{type:"button",class:"btn btn-ink",disabled:e.billingBusy||!e.billingRepository||e.billing.checkoutEnabled===!1,onClick:t[10]||(t[10]=r=>e.checkout(e.profileAddon().id,e.billingRepository))},c(e.billingBusy?"Please wait\u2026":"Continue to checkout"),9,KW),t[67]||(t[67]=n("p",{class:"billing-footnote"},"One-time payment. Tax shown at checkout.",-1))],64)):(a(),l("p",YW,[...t[68]||(t[68]=[g("You have no repositories yet. ",-1),n("a",{href:"/anonymize"},"Create one",-1),g(" first.",-1)])])),["repo_slot","repo_pack"].includes(e.profileAddon().id)?(a(),l("p",XW,[...t[69]||(t[69]=[g("Adding a new repository? ",-1),n("a",{href:"/anonymize"},"Start creating it",-1),g("; the form offers this once your free repositories are in use.",-1)])])):f("v-if",!0)])])):f("v-if",!0),n("details",JW,[t[84]||(t[84]=n("summary",null,"Compare all features",-1)),n("div",QW,[n("table",ZW,[t[83]||(t[83]=n("caption",{class:"sr-only"},"Free, Paper pack and Author hosting",-1)),n("thead",null,[n("tr",null,[t[72]||(t[72]=n("th",{scope:"col"},[n("span",{class:"sr-only"},"Feature")],-1)),t[73]||(t[73]=n("th",{scope:"col"},[g("Free"),n("small",null,"\u20AC0")],-1)),e.profilePackPlan()?(a(),l("th",xW,[t[70]||(t[70]=g("Paper pack",-1)),n("small",null,c(e.billingPrice(e.profilePackPlan())),1)])):f("v-if",!0),e.profileAuthorPlans().length?(a(),l("th",eK,[t[71]||(t[71]=g("Author",-1)),n("small",null,c(e.billingPrice(e.profileSelectedPlan())),1)])):f("v-if",!0)])]),n("tbody",null,[n("tr",null,[t[74]||(t[74]=n("th",{scope:"row"},"Repositories",-1)),n("td",null,c(e.billing.allowance?.repositories),1),e.profilePackPlan()?(a(),l("td",tK,"+1")):f("v-if",!0),e.profileAuthorPlans().length?(a(),l("td",nK,c(e.profileSelectedPlan()?.repositories),1)):f("v-if",!0)]),n("tr",null,[t[75]||(t[75]=n("th",{scope:"row"},"Source storage",-1)),n("td",null,c(e.billingBytes(e.billing.allowance?.storage))+" total",1),e.profilePackPlan()?(a(),l("td",sK,c(e.billingBytes(e.profileSlotPlan()?.storage||e.profilePassPlan()?.storage))+" for it",1)):f("v-if",!0),e.profileAuthorPlans().length?(a(),l("td",oK,c(e.billingBytes(e.profileSelectedPlan()?.storage))+" total",1)):f("v-if",!0)]),n("tr",null,[t[76]||(t[76]=n("th",{scope:"row"},"Latest expiration",-1)),n("td",null,c(e.billing.freeExpirationMonths||5)+" months ahead",1),e.profilePackPlan()?(a(),l("td",iK,"1 year after purchase")):f("v-if",!0),e.profileAuthorPlans().length?(a(),l("td",rK,"Never")):f("v-if",!0)]),n("tr",null,[t[77]||(t[77]=n("th",{scope:"row"},"Automatic updates",-1)),t[78]||(t[78]=n("td",null,"No",-1)),e.profilePackPlan()?(a(),l("td",aK,"180 days")):f("v-if",!0),e.profileAuthorPlans().length?(a(),l("td",lK,"Yes")):f("v-if",!0)]),n("tr",null,[t[79]||(t[79]=n("th",{scope:"row"},"Renews",-1)),t[80]||(t[80]=n("td",null,"No",-1)),e.profilePackPlan()?(a(),l("td",dK,"No")):f("v-if",!0),e.profileAuthorPlans().length?(a(),l("td",uK,"Until cancelled")):f("v-if",!0)]),n("tr",null,[t[81]||(t[81]=n("th",{scope:"row"},"Reviewer access",-1)),t[82]||(t[82]=n("td",null,"Free",-1)),e.profilePackPlan()?(a(),l("td",cK,"Free")):f("v-if",!0),e.profileAuthorPlans().length?(a(),l("td",pK,"Free")):f("v-if",!0)])])])])]),e.billing.checkoutEnabled===!1?(a(),l("p",fK,"New purchases are not available right now. Existing billing can still be managed below.")):f("v-if",!0)])):f("v-if",!0),e.billing?.enabled?(a(),l("section",mK,[n("div",hK,[t[86]||(t[86]=n("h2",{class:"billing-section-title"},"Purchases",-1)),e.billingPending?f("v-if",!0):(a(),l("button",{key:0,type:"button",class:"settings-text-button",onClick:t[11]||(t[11]=r=>e.refreshBilling()),disabled:e.billingBusy},"Refresh payment status",8,gK))]),(e.billing.purchases||[]).length?f("v-if",!0):(a(),l("p",vK,"No purchases yet.")),(e.billing.purchases||[]).length?(a(),l("div",yK,[...t[87]||(t[87]=[n("span",null,"Purchase",-1),n("span",null,"Period",-1),n("span",null,"Amount",-1),n("span",null,"Status",-1)])])):f("v-if",!0),(e.billing.purchases||[]).length?(a(),l("ul",bK,[(a(!0),l(q,null,Q(e.profilePurchases(!0).concat(e.profilePurchases(!1)),r=>(a(),l("li",{class:P(["billing-history-row",{"is-ended":!["active","overdue"].includes(r.status)}]),key:r.id},[n("div",wK,[n("strong",null,[g(c(e.profileGrantName(r)),1),r.repoId?(a(),l(q,{key:0},[t[88]||(t[88]=g(" \xB7 ",-1)),n("a",{href:"/anonymize/"+encodeURIComponent(r.repoId)},c(r.repoId),9,kK)],64)):r.conference?(a(),l(q,{key:1},[t[89]||(t[89]=g(" \xB7 ",-1)),n("a",{href:"/conference/"+encodeURIComponent(r.conference)},c(r.conference),9,CK)],64)):f("v-if",!0)]),n("span",null,c([r.purchasedAt?"Bought "+e.billingDate(r.purchasedAt):"",r.parts.length?e.profilePackSummary(r):["refunded","disputed"].includes(r.status)?"Payment "+r.status+", so what it paid for has ended":r.recurring?"Account subscription":""].filter(Boolean).join(" \xB7 ")),1)]),n("div",EK,c(e.profilePurchaseTerm(r)),1),n("div",SK,c(r.amount!=null?e.billingPrice(r):""),1),n("div",NK,[n("span",{class:P(["settings-status","is-"+r.status])},c(e.profilePurchaseStatus(r)),3)])],2))),128))])):f("v-if",!0),n("div",RK,[n("div",null,[t[90]||(t[90]=n("strong",null,"Invoices and payment details",-1)),e.billing.portal?(a(),l("p",PK,"Download receipts, update your card or change renewal in Stripe.")):(a(),l("p",DK,"Invoices appear here after your first purchase.")),t[91]||(t[91]=n("p",null,[g("Need a refund? "),n("a",{href:"mailto:tdurieux@anonymous.4open.science"},"Email the maintainer"),g(" with the payment date, or read the "),n("a",{href:"/faq#faq-plans"},"refund policy"),g(".")],-1))]),e.billing.portal?(a(),l("button",{key:0,type:"button",class:"btn btn-outline-ink",onClick:t[12]||(t[12]=r=>e.billingPortal()),disabled:e.billingBusy},"Manage billing and invoices",8,AK)):f("v-if",!0)])])):f("v-if",!0),n("p",TK,[t[92]||(t[92]=g("Organizing a conference? ",-1)),e.profileConferencePlan()?(a(),l(q,{key:0},[g("Review packages start at "+c(e.billingAmount(e.profileConferencePlan()))+" once for up to "+c(e.profileConferencePlan().repositories)+" submissions, and authors pay nothing.",1)],64)):(a(),l(q,{key:1},[g("One payment hosts every submission, and authors pay nothing.")],64)),t[93]||(t[93]=g()),t[94]||(t[94]=n("a",{href:"/conference/new"},"Create a conference",-1))])],8,oW),[[Z,e.settingsTab==="billing"]]),T(n("section",OK,[t[105]||(t[105]=n("p",{class:"settings-scope"},"Your identity, repository access, and account.",-1)),n("div",IK,[e.user?.photo?(a(),l("img",{key:0,width:"40",height:"40",class:"rounded-circle",alt:"",src:e.safeUrl(e.user?.photo)},null,8,MK)):f("v-if",!0),n("div",VK,[n("div",qK,"@"+c(e.user?.username),1),t[96]||(t[96]=n("div",{class:"paper-account-meta"},"Signed in with GitHub. Anonymous GitHub only reads your repositories.",-1))]),t[97]||(t[97]=n("a",{class:"btn btn-outline-ink",href:"/api/user/logout",target:"_self"},"Sign out",-1))]),n("form",{class:"paper-account-email",onSubmit:t[16]||(t[16]=ae(r=>e.saveAccountEmail(),["prevent"]))},[t[98]||(t[98]=n("label",{class:"paper-field-label",for:"account-email"},"Email address",-1)),t[99]||(t[99]=n("p",{id:"account-email-help",class:"paper-section-copy"},"Used for account alerts. Your address is never shown on anonymous pages.",-1)),T(n("input",{id:"account-email",class:"form-control",type:"email",autocomplete:"email",maxlength:"254",required:"","onUpdate:modelValue":t[13]||(t[13]=r=>e.accountEmail=r),"aria-describedby":"account-email-help",disabled:e.emailLoading||e.emailSaving||!e.emailCSRFReady,onInput:t[14]||(t[14]=r=>e.emailSaved=!1)},null,40,_K),[[rt,e.accountEmail]]),e.emailLoading?(a(),l("p",LK,"Loading your email address\u2026")):f("v-if",!0),e.emailError?(a(),l("p",$K,c(e.emailError),1)):f("v-if",!0),!e.emailCSRFReady&&!e.emailLoading?(a(),l("button",{key:2,class:"btn btn-outline-ink mt-2",type:"button",onClick:t[15]||(t[15]=r=>e.loadAccountEmail())},"Try again")):f("v-if",!0),n("button",{class:"btn btn-ink mt-2",type:"submit",disabled:e.emailLoading||e.emailSaving||!e.emailCSRFReady},c(e.emailSaving?"Saving\u2026":"Save email address"),9,FK),e.emailSaved?(a(),l("p",UK,"Email address saved.")):f("v-if",!0)],32),t[106]||(t[106]=n("a",{class:"paper-settings-connection-link",href:"/connections"},[n("i",{class:"fab fa-github","aria-hidden":"true"}),n("span",null,[g("GitHub connections"),n("small",null,"Manage repository access and legacy OAuth.")]),n("span",{"aria-hidden":"true"},"\u2192")],-1)),n("div",BK,[t[103]||(t[103]=n("div",{class:"paper-danger-head"},"Delete account",-1)),t[104]||(t[104]=n("p",{class:"paper-danger-copy"}," Removes all your anonymized repositories, gists, and pull requests, revokes the application's access to your GitHub account, and erases your personal data (username, email, access tokens). This cannot be undone. ",-1)),e.deleteError?(a(),l("div",zK,[t[100]||(t[100]=n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-info"})],-1)),t[101]||(t[101]=g()),n("span",{textContent:c(e.deleteError)},null,8,HK)])):f("v-if",!0),n("button",{type:"button",class:"btn btn-outline-danger",onClick:t[17]||(t[17]=r=>e.confirmDeleteAccount=!0),disabled:e.deletingAccount},[t[102]||(t[102]=n("svg",{class:"ui-icon mr-1","aria-hidden":"true"},[n("use",{href:"#ui-icon-trash"})],-1)),g(c(e.deletingAccount?"Deleting\u2026":"Delete my account"),1)],8,jK),e.confirmDeleteAccount?(a(),l("div",GK,[n("label",WK,"Type "+c(e.user?.username)+" to confirm",1),T(n("input",{id:"delete-username",class:"form-control","onUpdate:modelValue":t[18]||(t[18]=r=>e.deleteUsername=r),autocomplete:"off"},null,512),[[rt,e.deleteUsername]]),n("div",KK,[n("button",{type:"button",class:"btn btn-outline-danger",onClick:t[19]||(t[19]=r=>e.deleteAccount()),disabled:e.deletingAccount||e.deleteUsername!==e.user?.username},c(e.deletingAccount?"Deleting\u2026":"Delete permanently"),9,YK),n("button",{type:"button",class:"btn btn-outline-ink",onClick:t[20]||(t[20]=r=>{e.confirmDeleteAccount=!1,e.deleteUsername=""}),disabled:e.deletingAccount},"Cancel",8,XK)])])):f("v-if",!0)])],512),[[Z,e.settingsTab==="account"]])])}var JK={class:"pr-page"},QK={class:"container paper-page pr-page-inner"},ZK={class:"pr-header"},xK={class:"pr-title-row"},eY={class:"paper-page-title pr-title"},tY=["textContent"],nY={key:1,class:"text-muted"},sY=["href"],oY={class:"pr-header-meta"},iY={key:0,class:"pr-meta-item"},rY=["textContent"],aY={key:1,class:"pr-meta-item"},lY=["textContent"],dY={key:2,class:"pr-meta-item"},uY=["textContent"],cY={key:0,class:"pr-body-card"},pY={key:1,class:"paper-tabs",role:"tablist"},fY=["aria-selected","tabindex"],mY=["aria-selected","tabindex"],hY=["textContent"],gY={class:"paper-tab-content"},vY={key:0,role:"tabpanel",id:"pr-diff-panel","aria-labelledby":"pr-diff-tab"},yY=["innerHTML"],bY={key:1,role:"tabpanel",id:"pr-comments-panel","aria-labelledby":"pr-comments-tab"},wY={class:"pr-comments"},kY={class:"pr-comment"},CY={class:"pr-comment-head"},EY={key:0,class:"pr-comment-author"},SY=["textContent"],NY=["textContent"],RY={key:0,class:"pr-comment-body"},PY={key:0,class:"paper-table-empty"};function Ep(e,t){let s=Xe("markdown");return a(),l("div",JK,[n("div",QK,[t[17]||(t[17]=n("div",{class:"paper-crumbs"},[n("a",{href:"/dashboard"},"Reviewer"),g(" \xA0/\xA0 "),n("span",{class:"here"},"Pull request")],-1)),n("header",ZK,[n("div",xK,[n("h1",eY,[e.details?.title?(a(),l("span",{key:0,textContent:c(e.details?.title)},null,8,tY)):f("v-if",!0),e.details?.title?f("v-if",!0):(a(),l("span",nY,"Untitled pull request"))]),e.options?.isAdmin||e.options?.isOwner?(a(),l("a",{key:0,class:"btn btn-sm","aria-label":"Edit",href:e.safeUrl("/pull-request-anonymize/"+e.pullRequestId)},[...t[4]||(t[4]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-edit"})],-1),n("span",{class:"d-none d-md-inline"}," Edit",-1)])],8,sY)):f("v-if",!0)]),n("div",oY,[n("span",{class:P(["paper-pill",{good:e.details?.merged,warn:e.details?.state=="open",bad:e.details?.state=="closed"&&!e.details?.merged}])},[n("span",{class:P(["status-dot",{"status-ready":e.details?.merged,"status-error":e.details?.state=="closed"&&!e.details?.merged}])},null,2),g(" "+c(e.details?.merged?"Merged":e.fmt.title(e.details?.state)),1)],2),e.details?.baseRepositoryFullName?(a(),l("span",iY,[t[5]||(t[5]=n("i",{class:"fab fa-github"},null,-1)),t[6]||(t[6]=g()),n("span",{textContent:c(e.details?.baseRepositoryFullName)},null,8,rY)])):f("v-if",!0),e.details?.updatedDate?(a(),l("span",aY,[t[7]||(t[7]=n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#project-icon-clock"})],-1)),t[8]||(t[8]=g()),n("span",{textContent:c(e.fmt?.date(e.details?.updatedDate))},null,8,lY)])):f("v-if",!0),e.details?.anonymizeDate?(a(),l("span",dY,[t[9]||(t[9]=n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-shield"})],-1)),t[10]||(t[10]=g(" Anonymized ",-1)),n("span",{textContent:c(e.fmt?.date(e.details?.anonymizeDate))},null,8,uY)])):f("v-if",!0)])]),e.details?.body?(a(),l("section",cY,[t[11]||(t[11]=n("div",{class:"paper-section-eyebrow"},"Description",-1)),Ie(s,{content:e.details?.body},null,8,["content"])])):f("v-if",!0),e.details?.diff||e.details?.comments?(a(),l("nav",pY,[e.details?.diff?(a(),l("button",{key:0,class:P(["paper-tab",{active:e.tabState?.active=="diff"}]),type:"button",role:"tab",id:"pr-diff-tab","aria-selected":e.tabState?.active==="diff","aria-controls":"pr-diff-panel",tabindex:e.tabState?.active==="diff"?0:-1,onKeydown:t[0]||(t[0]=i=>e.previewTabKeydown(i)),onClick:t[1]||(t[1]=i=>e.tabState.active="diff")},[...t[12]||(t[12]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-code"})],-1),g(" Diff ",-1)])],42,fY)):f("v-if",!0),e.details?.comments?(a(),l("button",{key:1,class:P(["paper-tab",{active:e.tabState?.active=="comments"}]),type:"button",role:"tab",id:"pr-comments-tab","aria-selected":e.tabState?.active==="comments","aria-controls":"pr-comments-panel",tabindex:e.tabState?.active==="comments"?0:-1,onKeydown:t[2]||(t[2]=i=>e.previewTabKeydown(i)),onClick:t[3]||(t[3]=i=>e.tabState.active="comments")},[t[13]||(t[13]=n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-comment"})],-1)),n("span",{textContent:c(e.fmt.plural(e.details?.comments?.length,{0:"No comments",one:"1 comment",other:"{} comments"}))},null,8,hY)],42,mY)):f("v-if",!0)])):f("v-if",!0),n("div",gY,[e.details?.diff&&e.tabState?.active=="diff"?(a(),l("div",vY,[n("div",{class:"pr-diff",innerHTML:e.sanitize(e.fmt?.diff(e.details?.diff))},null,8,yY)])):f("v-if",!0),e.details?.comments&&e.tabState?.active=="comments"?(a(),l("div",bY,[n("ul",wY,[(a(!0),l(q,null,Q(e.details?.comments,(i,o)=>(a(),l("li",kY,[n("div",CY,[i?.author?(a(),l("span",EY,[t[14]||(t[14]=n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-user"})],-1)),t[15]||(t[15]=g(" @",-1)),n("span",{textContent:c(i?.author)},null,8,SY)])):f("v-if",!0),i?.updatedDate?(a(),l("span",{key:1,class:"pr-comment-date",textContent:c(e.fmt?.date(i?.updatedDate))},null,8,NY)):f("v-if",!0)]),i?.body?(a(),l("div",RY,[Ie(s,{content:i?.body},null,8,["content"])])):f("v-if",!0)]))),256)),e.details?.comments?.length?f("v-if",!0):(a(),l("li",PY,[...t[16]||(t[16]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-comment"})],-1),n("span",null,"No comments on this pull request.",-1)])]))])])):f("v-if",!0)])])])}var DY={class:"repository-task status-page"},AY={class:"page-head-main"},TY={class:"task-lede"},OY={class:"task-columns"},IY={class:"task-preparation","aria-label":"Repository preparation"},MY={key:0,class:"text-danger",role:"alert"},VY={key:1,class:"paper-section-copy"},qY={key:2,class:"paper-ratelimit-card",role:"status"},_Y={class:"paper-error-msg"},LY=["aria-valuenow"],$Y={class:"paper-progress-label"},FY=["textContent"],UY={key:0},BY=["textContent"],zY={class:"paper-progress-pct"},HY={key:4,class:"paper-error-card",role:"alert"},jY={key:0,class:"paper-error-msg"},GY={key:1,class:"paper-error-msg"},WY={key:2},KY=["href"],YY={class:"paper-error-actions"},XY=["href"],JY={key:5,class:"share-link"},QY={class:"share-link-row"},ZY={class:"share-link-buttons"},xY={class:"ui-icon","aria-hidden":"true"},eX=["href"],tX=["textContent"],nX=["href"],sX={class:"share-link-note"},oX=["href"],iX={class:"share-link-next"},rX={class:"share-link-next-actions"},aX=["href"],lX={class:"task-summary","aria-label":"Repository summary"},dX=["title"],uX={key:1};function Sp(e,t){return a(),l("div",DY,[n("header",{class:P(["page-head",{"task-ready":e.repo?.status==="ready"}])},[t[3]||(t[3]=n("div",{class:"paper-crumbs"},[n("a",{href:"/dashboard"},"My work"),g(" \xA0/\xA0 "),n("span",{class:"here"},"Review link")],-1)),n("div",AY,[n("div",null,[n("h1",null,c(e.repo?.status==="ready"?"Your review link is ready":"Prepare your anonymous review link"),1),n("p",TY,c(e.repo?.status==="ready"?"Share this link with reviewers in your submission.":"Your settings are saved. Track preparation before sharing the link."),1)])]),t[4]||(t[4]=n("ol",{class:"task-trail flow-trail","aria-label":"Repository progress"},[n("li",null,"1. Repository"),n("li",null,"2. Review and hosting"),n("li",{"aria-current":"step"},"3. Review link")],-1))],2),n("div",OY,[n("section",IY,[e.error?(a(),l("p",MY,[t[5]||(t[5]=g("Unable to load repository status. ",-1)),n("button",{type:"button",class:"task-text-button",onClick:t[0]||(t[0]=s=>e.getStatus())},"Try again")])):f("v-if",!0),e.repo?.status!=="ready"?(a(),l("p",VY,[...t[6]||(t[6]=[g(" The repository will take a few minutes to get ready, depending on its size. Visit the ",-1),n("a",{href:"/faq"},"FAQ",-1),g(" for more information. ",-1)])])):f("v-if",!0),e.rateLimitResetAt?(a(),l("div",qY,[t[9]||(t[9]=Ce('
Temporarily paused
GitHub API rate limit reached
',1)),n("p",_Y,[t[7]||(t[7]=g("Anonymization will resume automatically in ",-1)),n("strong",null,c(e.rateLimitCountdown),1),t[8]||(t[8]=g(". No action needed \u2014 the job is queued and will continue where it left off.",-1))])])):f("v-if",!0),e.repo?.status!=="ready"&&e.repo?.status!="error"&&!e.rateLimitResetAt?(a(),l("div",{key:3,class:P(["paper-progress",{"paper-progress-ready":e.repo?.status=="ready"}]),role:"progressbar","aria-valuemin":"0","aria-valuemax":"100","aria-valuenow":e.progress},[n("div",{class:"paper-progress-bar",style:Te("width: "+e.progress+"%;")},null,4),n("div",$Y,[n("span",{textContent:c(e.fmt?.title(e.repo?.status))},null,8,FY),e.repo?.statusMessage?(a(),l("span",UY,[t[10]||(t[10]=g("\xA0\xB7\xA0",-1)),n("span",{textContent:c(e.repo?.statusMessage)},null,8,BY)])):f("v-if",!0),n("span",zY,c(e.progress||0)+"%",1)])],10,LY)):f("v-if",!0),e.repo?.status=="error"&&!e.rateLimitResetAt?(a(),l("div",HY,[t[14]||(t[14]=Ce('
Anonymization failed
Something went wrong while preparing this repository.
',1)),e.repo?.statusMessage?(a(),l("p",jY,c(e.fmt?.translate("ERRORS."+e.repo?.statusMessage)),1)):f("v-if",!0),e.repo?.statusMessage?f("v-if",!0):(a(),l("p",GY,"No additional details were reported. The most common causes are private repositories, missing branches, and rate limits.")),e.repo?.statusMessage==="quota_exceeded"?(a(),l("p",WY,[n("a",{href:e.safeUrl("/anonymize/"+e.repoId)},"Review this repository\u2019s hosting",8,KY),t[11]||(t[11]=g(", then retry preparation.",-1))])):f("v-if",!0),t[15]||(t[15]=n("ul",{class:"paper-error-hints"},[n("li",null,"Make sure the source URL points to a repository or pull request you can access."),n("li",null,"Check that the chosen branch and commit still exist on GitHub."),n("li",null,"If you just signed in, the access token may need a moment to propagate \u2014 try again.")],-1)),n("div",YY,[n("a",{class:"btn btn-primary",href:e.safeUrl("/anonymize/"+e.repoId)},[...t[12]||(t[12]=[n("svg",{class:"ui-icon mr-1","aria-hidden":"true"},[n("use",{href:"#ui-icon-edit"})],-1),g(" Edit anonymization",-1)])],8,XY),t[13]||(t[13]=Ce(' Read the FAQ Report a bug in Anonymous GitHub',2))])])):f("v-if",!0),e.repo?.status=="ready"?(a(),l("div",JY,[t[24]||(t[24]=n("div",{class:"share-link-label",id:"share-url-label"},"Review link",-1)),n("div",QY,[n("code",{id:"share-url",class:"share-link-url",tabindex:"0",role:"textbox","aria-readonly":"true","aria-labelledby":"share-url-label",onFocus:t[1]||(t[1]=s=>e.selectShareUrl(s))},c(e.shareUrl),33),n("div",ZY,[n("button",{type:"button",class:"btn btn-primary share-copy",onClick:t[2]||(t[2]=s=>e.copyShareUrl())},[(a(),l("svg",xY,[n("use",{href:e.copied?"#ui-icon-check":"#project-icon-copy"},null,8,eX)])),n("span",{"aria-live":"polite",textContent:c(e.copied?"Copied":"Copy link")},null,8,tX)]),n("a",{class:"btn share-open",target:"_self",href:e.safeUrl("/r/"+e.repoId+"/")},[...t[16]||(t[16]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#project-icon-eye"})],-1),g(" Open repository ",-1)])],8,nX)])]),n("p",sX,[g(c(e.repo?.options?.expirationMode!=="never"&&e.repo?.options?.expirationDate?"Expires "+e.fmt.date(e.repo.options.expirationDate):"Never expires"),1),t[18]||(t[18]=n("span",{"aria-hidden":"true"}," \xB7 ",-1)),t[19]||(t[19]=g("Reviewers don\u2019t need an account",-1)),e.repo?.options?.page?(a(),l(q,{key:0},[t[17]||(t[17]=n("span",{"aria-hidden":"true"}," \xB7 ",-1)),n("a",{target:"_self",href:e.safeUrl("/w/"+e.repoId+"/")},"Open GitHub page",8,oX)],64)):f("v-if",!0)]),n("div",iX,[t[22]||(t[22]=n("h2",null,"Need to change something?",-1)),t[23]||(t[23]=n("p",null,"Edit the redacted terms or the expiry at any time. The link stays the same.",-1)),n("p",rX,[n("a",{href:e.safeUrl("/anonymize/"+e.repoId)},"Edit anonymization",8,aX),t[20]||(t[20]=n("span",{"aria-hidden":"true"},"\xB7",-1)),t[21]||(t[21]=n("a",{href:"/dashboard"},"Go to My work",-1))])])])):f("v-if",!0)]),n("aside",lX,[n("dl",null,[t[28]||(t[28]=n("dt",null,"Source",-1)),e.repo?.source?.fullName?(a(),l("dd",{key:0,class:"task-source",title:"https://github.com/"+e.repo.source.fullName},[t[25]||(t[25]=g("github.com/",-1)),t[26]||(t[26]=n("wbr",null,null,-1)),g(c(e.repo.source.fullName.split("/")[0])+"/",1),t[27]||(t[27]=n("wbr",null,null,-1)),g(c(e.repo.source.fullName.split("/").slice(1).join("/")),1)],8,dX)):(a(),l("dd",uX,"Loading\u2026")),t[29]||(t[29]=n("dt",null,"Lifetime",-1)),n("dd",null,c(e.repo?.options?.expirationMode==="never"?"Never expire while subscribed":e.repo?.options?.expirationDate?"Until "+e.fmt.date(e.repo.options.expirationDate):"Loading\u2026"),1),t[30]||(t[30]=n("dt",null,"Review access",-1)),t[31]||(t[31]=n("dd",null,"Anonymous and free",-1))])])])])}var cX={class:"container paper-page admin-page overview-page billing-page"},pX={class:"bl-toolbar"},fX={class:"seg-filter",role:"radiogroup","aria-label":"Period"},mX=["aria-checked","onClick"],hX={key:0,class:"bl-basis"},gX={key:0,class:"ov-performance-message ov-performance-warning bl-message",role:"alert"},vX={key:1,class:"ov-performance-message bl-message",role:"status"},yX={key:2,class:"ov-performance-message ov-performance-warning bl-message",role:"status"},bX=["aria-busy"],wX={class:"ov-kpi-card"},kX={class:"ov-kpi-value"},CX={class:"ov-kpi-sub"},EX={class:"ov-kpi-card"},SX={key:0,class:"ov-kpi-sub"},NX={key:1,class:"ov-kpi-sub"},RX={class:"ov-kpi-card"},PX={class:"ov-kpi-label"},DX={class:"ov-kpi-value"},AX={class:"ov-kpi-sub"},TX={class:"ov-kpi-card"},OX={class:"ov-kpi-value"},IX={class:"ov-kpi-sub"},MX={class:"ov-kpi-card"},VX={class:"ov-kpi-value"},qX={class:"ov-kpi-sub"},_X={class:"ov-kpi-card"},LX={class:"ov-kpi-sub"},$X={key:3,class:"bl-health","aria-label":"Webhook health"},FX={class:"bl-health-title"},UX={class:"bl-health-item"},BX=["title"],zX={key:1,class:"bl-health-item"},HX={key:4,class:"ov-chart-card bl-chart-card"},jX={class:"ov-chart-head"},GX={class:"ov-chart-title"},WX={key:0,class:"ov-chart-legends"},KX=["aria-label"],YX={class:"ov-yaxis","aria-hidden":"true"},XX=["data-tip"],JX={class:"ov-spark-x bl-x"},QX={key:1,class:"ov-performance-empty bl-empty",role:"status"},ZX={key:5,class:"ov-panel-card bl-plans","aria-labelledby":"bl-plans-heading"},xX={class:"ov-panel-head"},eJ={class:"ov-panel-meta"},tJ={class:"ov-metrics-scroll",tabindex:"0",role:"region","aria-label":"Sales by plan, scroll for more columns"},nJ={class:"ov-metrics-table"},sJ={key:0,scope:"colgroup",colspan:"2",class:"bl-group"},oJ={scope:"row",class:"bl-plan-name"},iJ=["title","onClick"],rJ={class:"num"},aJ={class:"num"},lJ={class:"num"},dJ={class:"num"},uJ={class:"num"},cJ={class:"num"},pJ={class:"num"},fJ={class:"num"},mJ={class:"num"},hJ={class:"num"},gJ={class:"bl-grants",id:"bl-grants","aria-labelledby":"bl-grants-heading"},vJ={class:"seg-bar"},yJ={class:"seg-filter",role:"radiogroup","aria-label":"Filter by state"},bJ=["aria-checked"],wJ={class:"count"},kJ=["aria-checked"],CJ={class:"count"},EJ=["aria-checked"],SJ={class:"count"},NJ=["aria-checked"],RJ={class:"count"},PJ={class:"seg-countline",role:"status"},DJ={key:0,class:"alert alert-danger bl-alert"},AJ=["aria-expanded"],TJ={class:"search-wrap"},OJ={type:"search",class:"form-control","aria-label":"Search by user",placeholder:"Search by user\u2026",autocomplete:"off"},IJ={class:"admin-filter-inline"},MJ={id:"bl-plan",class:"form-control form-control-sm"},VJ=["label"],qJ=["value"],_J={class:"admin-filter-inline"},LJ={id:"bl-status",class:"form-control form-control-sm"},$J=["value"],FJ={key:0,class:"admin-filter-inline","aria-label":"Pagination"},UJ=["disabled"],BJ={class:"bl-page"},zJ=["disabled"],HJ={key:0,class:"admin-filter-row"},jJ={class:"admin-active-chips"},GJ={class:"key"},WJ=["onClick"],KJ={key:1,class:"ov-metrics-scroll bl-grant-scroll",tabindex:"0",role:"region","aria-label":"Subscriptions and purchases, scroll for more columns"},YJ={class:"ov-metrics-table bl-grant-table"},XJ={scope:"col"},JJ={scope:"col"},QJ={scope:"row",class:"bl-user"},ZJ=["title","href"],xJ={key:1,class:"ov-muted"},eQ={class:"bl-plan-cell"},tQ={key:0},nQ={class:"bl-state"},sQ={key:0},oQ={key:3},iQ={key:0,class:"bl-flag"},rQ={key:1,class:"ov-muted"},aQ={class:"bl-flag is-bad"},lQ={key:0},dQ={key:1,class:"ov-muted"},uQ={class:"bl-scope"},cQ=["href"],pQ={class:"ui-icon","aria-hidden":"true"},fQ=["href"],mQ={key:1,class:"ov-muted"},hQ={key:2,class:"paper-table-empty"},gQ={key:3,class:"admin-empty"},vQ={key:4,class:"admin-toolbar bl-pager"},yQ={key:0,class:"pagination-compact"},bQ=["disabled"],wQ=["max"],kQ=["disabled"],CQ={class:"admin-filter-inline"},EQ={id:"bl-limit",class:"form-control form-control-sm"};function Np(e,t){let s=De("field"),i=De("form");return a(),l("div",cX,[t[79]||(t[79]=Ce('
Admin \xA0/\xA0 Billing

Billing

',2)),n("div",pX,[n("div",fX,[(a(!0),l(q,null,Q(e.periods,o=>(a(),l("button",{type:"button",role:"radio",class:P(["seg-chip",{active:e.period===o.id}]),key:o.id,"aria-checked":e.period===o.id,onClick:r=>e.setPeriod(o.id)},c(o.label),11,mX))),128))]),e.summary?(a(),l("p",hX,"Sales are new checkouts and subscriptions. Revenue uses Stripe list prices; renewals count toward MRR.")):f("v-if",!0)]),e.summaryError?(a(),l("div",gX,[t[15]||(t[15]=n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-warning"})],-1)),n("span",null,c(e.summaryError),1),n("button",{type:"button",class:"btn btn-sm",onClick:t[0]||(t[0]=o=>e.loadSummary())},"Retry")])):f("v-if",!0),e.summary&&!e.summary.revenue?.available?(a(),l("div",vX,[...t[16]||(t[16]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-info"})],-1),n("span",null,[n("b",null,"Revenue unavailable."),g(" Stripe is not configured on this server, so amounts can't be looked up. Counts are complete.")],-1)])])):f("v-if",!0),e.summary?.revenue?.missingSales||e.summary?.revenue?.missingAllTimeSales||e.summary?.revenue?.missingSubscriptions?(a(),l("div",yX,[t[17]||(t[17]=n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-warning"})],-1)),n("span",null,"Some Stripe prices are unavailable. Affected totals are marked incomplete: "+c(e.fmt?.number(e.summary.revenue.missingSales||0))+" period sales, "+c(e.fmt?.number(e.summary.revenue.missingAllTimeSales||0))+" historical sales, "+c(e.fmt?.number(e.summary.revenue.missingSubscriptions||0))+" active subscriptions.",1)])):f("v-if",!0),f(" \u2500\u2500 Summary tiles \u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500 "),n("section",{class:P(["ov-kpi-row bl-kpi-row",{"is-loading":e.summaryLoading}]),"aria-busy":e.summaryLoading?"true":"false","aria-label":"Billing summary"},[!e.summary&&e.summaryLoading?(a(),l(q,{key:0},Q(6,o=>n("div",{class:"ov-kpi-card",key:o,"aria-hidden":"true"},[...t[18]||(t[18]=[n("span",{class:"skeleton skeleton-line-sm",style:{width:"60%"}},null,-1),n("span",{class:"skeleton bl-skeleton-value"},null,-1),n("span",{class:"skeleton skeleton-line-sm",style:{width:"80%"}},null,-1)])])),64)):f("v-if",!0),e.summary?(a(),l(q,{key:1},[n("div",wX,[t[19]||(t[19]=n("div",{class:"ov-kpi-label"},"Active subscriptions",-1)),n("div",kX,c(e.fmt?.number(e.summary.subscriptions.active)),1),n("div",CX,c(e.fmt?.number(e.summary.subscriptions.monthly))+" monthly \xB7 "+c(e.fmt?.number(e.summary.subscriptions.annual))+" annual",1)]),n("div",EX,[t[20]||(t[20]=n("div",{class:"ov-kpi-label"},"MRR",-1)),n("div",{class:P(["ov-kpi-value",{"bl-muted-value":!e.revenueOn()}])},c(e.revenueOn()?e.summary.subscriptions.complete===!1?"Incomplete":e.money(e.summary.subscriptions.mrr)[0]||e.fmt?.money(0):"Unavailable"),3),e.revenueOn()&&e.money(e.summary.subscriptions.mrr).length>1?(a(),l("div",SX,"+ "+c(e.money(e.summary.subscriptions.mrr).slice(1).join(" \xB7 ")),1)):(a(),l("div",NX,c(e.revenueOn()?"Annual plans \xF7 12":"Needs Stripe prices"),1))]),n("div",RX,[n("div",PX,"Sales \xB7 "+c(e.periodPhrase()),1),n("div",DX,c(e.fmt?.number(e.summary.sales.count)),1),n("div",AX,c(e.revenueOn()?e.summary.sales.complete===!1?"Revenue incomplete":e.moneyText(e.summary.sales.revenue,e.fmt?.money(0)):"Revenue unavailable"),1)]),n("div",TX,[t[21]||(t[21]=n("div",{class:"ov-kpi-label"},"All-time sales",-1)),n("div",OX,c(e.fmt?.number(e.summary.allTime.count)),1),n("div",IX,c(e.revenueOn()?e.summary.allTime.complete===!1?"Revenue incomplete":e.moneyText(e.summary.allTime.revenue,e.fmt?.money(0)):"Revenue unavailable"),1)]),n("div",MX,[t[22]||(t[22]=n("div",{class:"ov-kpi-label"},"Cancelling",-1)),n("div",VX,c(e.fmt?.number(e.summary.subscriptions.cancelling)),1),n("div",qX,"at period end, of "+c(e.fmt?.number(e.summary.subscriptions.active))+" active",1)]),n("div",_X,[t[23]||(t[23]=n("div",{class:"ov-kpi-label"},"Refunds & disputes",-1)),n("div",{class:P(["ov-kpi-value",{"ov-val-warn":e.summary.reversals.disputes>0}])},c(e.fmt?.number(e.summary.reversals.refunds+e.summary.reversals.disputes)),3),n("div",LX,c(e.fmt?.number(e.summary.reversals.refunds))+" "+c(e.summary.reversals.refunds===1?"refund":"refunds")+" \xB7 "+c(e.fmt?.number(e.summary.reversals.disputes))+" "+c(e.summary.reversals.disputes===1?"dispute":"disputes"),1)])],64)):f("v-if",!0)],10,bX),f(" \u2500\u2500 Webhook health \u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500 "),e.summary?.webhooks?(a(),l("section",$X,[n("span",FX,[n("span",{class:P(["ov-svc-dot",{"ov-dot-ok":e.webhookState()==="ok","ov-dot-warn":e.webhookState()==="warn","bl-dot-bad":e.webhookState()==="bad"}]),"aria-hidden":"true"},null,2),t[24]||(t[24]=g("Stripe webhooks",-1))]),n("span",UX,[t[25]||(t[25]=n("span",{class:"k"},"Pending",-1)),g(" "+c(e.fmt?.number(e.summary.webhooks.pending)),1),e.summary.webhooks.pending?(a(),l(q,{key:0},[g(" \xB7 oldest "+c(e.age(e.summary.webhooks.oldestPendingSeconds)),1)],64)):f("v-if",!0)]),n("span",{class:P(["bl-health-item",{"is-bad":e.summary.webhooks.failed}])},[t[26]||(t[26]=n("span",{class:"k"},"Failed",-1)),g(" "+c(e.fmt?.number(e.summary.webhooks.failed)),1)],2),e.summary.webhooks.lastError?(a(),l("span",{key:0,class:"bl-health-item bl-health-error",title:e.summary.webhooks.lastError.type+": "+e.summary.webhooks.lastError.error},[t[27]||(t[27]=n("span",{class:"k"},"Last error",-1)),t[28]||(t[28]=g()),n("code",null,c(e.summary.webhooks.lastError.error),1),g(" on "+c(e.summary.webhooks.lastError.type)+" \xB7 "+c(e.fmt?.humanTime(e.summary.webhooks.lastError.receivedAt)),1)],8,BX)):(a(),l("span",zX,[...t[29]||(t[29]=[n("span",{class:"k"},"Last error",-1),g(" none",-1)])])),n("span",{class:P(["bl-health-item",{"is-warn":e.summary.webhooks.unreviewedRevocations}])},[t[30]||(t[30]=n("span",{class:"k"},"Unreviewed reversals",-1)),g(" "+c(e.fmt?.number(e.summary.webhooks.unreviewedRevocations)),1)],2)])):f("v-if",!0),f(" \u2500\u2500 Sales over time \u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500 "),e.summary?(a(),l("section",HX,[n("div",jX,[n("span",GX,"Sales per "+c(e.bucketName())+" \xB7 "+c(e.periodPhrase()),1),e.seriesSales()?(a(),l("span",WX,[(a(!0),l(q,null,Q(e.families,o=>(a(),l("span",{class:"ov-chart-legend",key:o.id},[n("span",{class:P(["bl-swatch","bl-"+o.id]),"aria-hidden":"true"},null,2),g(c(o.label)+" \xB7 "+c(e.fmt?.number(e.familyTotal(o.id))),1)]))),128))])):f("v-if",!0)]),e.seriesSales()?(a(),l(q,{key:0},[n("div",{class:P(["ov-spark-bars ov-has-axis bl-bars",{"is-dense":e.summary.series.length>45}]),role:"img","aria-label":e.fmt?.number(e.seriesSales())+" sales, "+e.periodPhrase()+", by plan family"},[n("div",YX,[n("span",null,c(e.fmt?.number(e.chartMax())),1),n("span",null,c(e.fmt?.number(e.chartMax()/2)),1),t[31]||(t[31]=n("span",null,"0",-1))]),(a(!0),l(q,null,Q(e.summary.series,(o,r)=>(a(),l("div",{class:P(["ov-spark-col has-tip bl-col",{"is-zero":!e.bucketTotal(o)}]),key:r,"data-tip":e.bucketTip(o)},[n("span",{class:"bl-stack",style:Te({height:e.bucketTotal(o)/e.chartMax()*100+"%"})},[(a(!0),l(q,null,Q(e.families,d=>T((a(),l("i",{key:d.id,class:P("bl-"+d.id),style:Te({flexGrow:o[d.id]})},null,6)),[[Z,o[d.id]]])),128))],4)],10,XX))),128))],10,KX),n("div",JX,[n("span",null,c(e.bucketLabel(e.summary.series[0])),1),n("span",null,c(e.bucketLabel(e.summary.series[Math.floor(e.summary.series.length/2)])),1),n("span",null,c(e.bucketLabel(e.summary.series[e.summary.series.length-1])),1)])],64)):(a(),l("p",QX,"No sales "+c(e.period==="all"?"yet":"in the "+e.periodPhrase())+".",1))])):f("v-if",!0),f(" \u2500\u2500 By plan \u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500 "),e.summary?(a(),l("section",ZX,[n("div",xX,[t[32]||(t[32]=n("h2",{class:"ov-panel-title",id:"bl-plans-heading"},"By plan",-1)),n("span",eJ,c(e.fmt?.number(e.plansWithActivity().length))+" of "+c(e.fmt?.number(e.summary.plans.length))+" plans sold",1)]),n("div",tJ,[n("table",nJ,[t[41]||(t[41]=n("caption",{class:"sr-only"},"Active grants, sales and revenue per plan",-1)),n("thead",null,[n("tr",null,[t[33]||(t[33]=n("th",{scope:"col",rowspan:"2"},"Plan",-1)),t[34]||(t[34]=n("th",{scope:"col",rowspan:"2",class:"num"},"Active",-1)),e.period!=="all"?(a(),l("th",sJ,c(e.periodPhrase().replace(/^./,o=>o.toUpperCase())),1)):f("v-if",!0),t[35]||(t[35]=n("th",{scope:"colgroup",colspan:"2",class:"bl-group"},"All time",-1))]),n("tr",null,[e.period!=="all"?(a(),l(q,{key:0},[t[36]||(t[36]=n("th",{scope:"col",class:"num"},"Sales",-1)),t[37]||(t[37]=n("th",{scope:"col",class:"num"},"Revenue",-1))],64)):f("v-if",!0),t[38]||(t[38]=n("th",{scope:"col",class:"num"},"Sales",-1)),t[39]||(t[39]=n("th",{scope:"col",class:"num"},"Revenue",-1))])]),n("tbody",null,[(a(!0),l(q,null,Q(e.summary.plans,o=>(a(),l("tr",{key:o.planId,class:P({"bl-idle":!o.active&&!o.sales&&!o.allTimeSales})},[n("th",oJ,[n("span",{class:P(["bl-swatch","bl-"+o.family]),"aria-hidden":"true"},null,2),n("button",{type:"button",class:"bl-link",title:"Show "+o.name+" grants",onClick:r=>e.filterPlan(o.planId)},c(o.name),9,iJ)]),n("td",rJ,c(e.fmt?.number(o.active)),1),e.period!=="all"?(a(),l(q,{key:0},[n("td",aJ,c(e.fmt?.number(o.sales)),1),n("td",lJ,c(e.revenueOn()?o.revenueComplete===!1?"Incomplete":e.moneyText(o.revenue):"\u2014"),1)],64)):f("v-if",!0),n("td",dJ,c(e.fmt?.number(o.allTimeSales)),1),n("td",uJ,c(e.revenueOn()?o.allTimeRevenueComplete===!1?"Incomplete":e.moneyText(o.allTimeRevenue):"\u2014"),1)],2))),128))]),n("tfoot",null,[n("tr",null,[t[40]||(t[40]=n("th",{scope:"row"},"Total",-1)),n("td",cJ,c(e.fmt?.number(e.planTotals().active)),1),e.period!=="all"?(a(),l(q,{key:0},[n("td",pJ,c(e.fmt?.number(e.planTotals().sales)),1),n("td",fJ,c(e.revenueOn()?e.summary.sales.complete===!1?"Incomplete":e.moneyText(e.summary.sales.revenue):"\u2014"),1)],64)):f("v-if",!0),n("td",mJ,c(e.fmt?.number(e.planTotals().allTimeSales)),1),n("td",hJ,c(e.revenueOn()?e.summary.allTime.complete===!1?"Incomplete":e.moneyText(e.summary.allTime.revenue):"\u2014"),1)])])])]),t[42]||(t[42]=n("p",{class:"ov-performance-note bl-note"},"A paper pack counts once, under Paper pack. Active means paid time remains and the payment wasn't reversed.",-1))])):f("v-if",!0),f(" \u2500\u2500 Subscriptions and purchases \u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500 "),n("section",gJ,[t[78]||(t[78]=n("div",{class:"bl-section-head"},[n("h2",{class:"ov-panel-title",id:"bl-grants-heading"},"Subscriptions and purchases")],-1)),n("div",vJ,[n("div",yJ,[n("button",{type:"button",role:"radio",class:P(["seg-chip",{active:e.stateView()==="all"}]),"aria-checked":e.stateView()==="all",onClick:t[1]||(t[1]=o=>e.setStateView("all"))},[t[43]||(t[43]=g("All ",-1)),n("span",wJ,c(e.fmt?.number(e.stateCount("all"))),1)],10,bJ),n("button",{type:"button",role:"radio",class:P(["seg-chip",{active:e.stateView()==="active","is-empty":!e.stateCount("active")}]),"aria-checked":e.stateView()==="active",onClick:t[2]||(t[2]=o=>e.setStateView("active"))},[t[44]||(t[44]=n("span",{class:"seg-dot ok","aria-hidden":"true"},null,-1)),t[45]||(t[45]=g("Active ",-1)),n("span",CJ,c(e.fmt?.number(e.stateCount("active"))),1)],10,kJ),n("button",{type:"button",role:"radio",class:P(["seg-chip",{active:e.stateView()==="expired","is-empty":!e.stateCount("expired")}]),"aria-checked":e.stateView()==="expired",onClick:t[3]||(t[3]=o=>e.setStateView("expired"))},[t[46]||(t[46]=n("span",{class:"seg-dot off","aria-hidden":"true"},null,-1)),t[47]||(t[47]=g("Expired ",-1)),n("span",SJ,c(e.fmt?.number(e.stateCount("expired"))),1)],10,EJ),n("button",{type:"button",role:"radio",class:P(["seg-chip",{active:e.stateView()==="revoked","is-empty":!e.stateCount("revoked")}]),"aria-checked":e.stateView()==="revoked",onClick:t[4]||(t[4]=o=>e.setStateView("revoked"))},[t[48]||(t[48]=n("span",{class:"seg-dot bad","aria-hidden":"true"},null,-1)),t[49]||(t[49]=g("Revoked ",-1)),n("span",RJ,c(e.fmt?.number(e.stateCount("revoked"))),1)],10,NJ)]),n("p",PJ,[n("strong",null,c(e.total>=0?e.fmt.number(e.total):"\u2026"),1),t[50]||(t[50]=g(" shown",-1))])]),e.grantsError?(a(),l("div",DJ,[t[51]||(t[51]=n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-warning"})],-1)),g(" "+c(e.grantsError)+" ",1),n("button",{type:"button",class:"btn btn-sm",onClick:t[5]||(t[5]=o=>e.reloadGrants())},"Retry")])):f("v-if",!0),T((a(),l("form",{class:"w-100 admin-filter-toolbar","aria-label":"Subscriptions and purchases","accept-charset":"UTF-8",onSubmit:t[9]||(t[9]=ae(()=>{},["prevent"]))},[n("button",{type:"button",class:"btn btn-sm admin-filters-toggle",onClick:t[6]||(t[6]=o=>e.filtersOpen=!e.filtersOpen),"aria-expanded":e.filtersOpen?"true":"false"},[t[52]||(t[52]=g("Filters",-1)),e.query.plan||e.query.status?(a(),l(q,{key:0},[g(" ("+c((e.query.plan?1:0)+(e.query.status?1:0))+")",1)],64)):f("v-if",!0)],8,AJ),n("div",{class:P(["admin-filter-row",{"is-open":e.filtersOpen}])},[n("div",TJ,[T(n("input",OJ,null,512),[[s,{state:e.viewState,set:o=>{e.query.search=o},value:e.query?.search,form:null,options:{}}]])]),n("span",IJ,[t[54]||(t[54]=n("label",{for:"bl-plan"},"Plan",-1)),T((a(),l("select",MJ,[t[53]||(t[53]=n("option",{value:""},"Any",-1)),(a(!0),l(q,null,Q(e.families,o=>(a(),l("optgroup",{key:o.id,label:o.label},[(a(!0),l(q,null,Q((e.summary?.plans||[]).filter(r=>r.family===o.id),r=>(a(),l("option",{key:r.planId,value:r.planId},c(r.name),9,qJ))),128))],8,VJ))),128))])),[[s,{state:e.viewState,set:o=>{e.query.plan=o},value:e.query?.plan,form:null,options:{}}]])]),n("span",_J,[t[56]||(t[56]=n("label",{for:"bl-status"},"Stripe status",-1)),T((a(),l("select",LJ,[t[55]||(t[55]=n("option",{value:""},"Any",-1)),(a(!0),l(q,null,Q(e.statuses,o=>(a(),l("option",{key:o,value:o},c(o.replace(/_/g," ")),9,$J))),128))])),[[s,{state:e.viewState,set:o=>{e.query.status=o},value:e.query?.status,form:null,options:{}}]])]),t[59]||(t[59]=n("span",{class:"admin-filter-spacer"},null,-1)),e.totalPage>1?(a(),l("span",FJ,[n("button",{class:"btn btn-sm btn-icon",type:"button",onClick:t[7]||(t[7]=o=>e.query.page=Math.max(1,e.query.page-1)),disabled:e.query?.page<=1,"aria-label":"Previous page"},[...t[57]||(t[57]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-chevron-left"})],-1)])],8,UJ),n("span",BJ,c(e.query?.page)+"/"+c(e.totalPage||1),1),n("button",{class:"btn btn-sm btn-icon",type:"button",onClick:t[8]||(t[8]=o=>e.query.page=Math.min(e.totalPage,e.query.page+1)),disabled:e.query?.page>=e.totalPage,"aria-label":"Next page"},[...t[58]||(t[58]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-chevron-right"})],-1)])],8,zJ)])):f("v-if",!0)],2),e.chips?.length?(a(),l("div",HJ,[n("div",jJ,[(a(!0),l(q,null,Q(e.chips,o=>(a(),l("span",{class:"admin-active-chip",key:o?.key},[n("span",GJ,c(o?.label),1),n("span",null,c(o?.value),1),n("button",{type:"button",onClick:r=>e.clearFilter(o.key),"aria-label":"Clear filter"},[...t[60]||(t[60]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#project-icon-close"})],-1)])],8,WJ)]))),128))])])):f("v-if",!0)],32)),[[i,e.viewState]]),e.grants?.length?(a(),l("div",KJ,[n("table",YJ,[t[71]||(t[71]=n("caption",{class:"sr-only"},"Subscriptions and purchases",-1)),n("thead",null,[n("tr",null,[t[65]||(t[65]=n("th",{scope:"col"},"User",-1)),t[66]||(t[66]=n("th",{scope:"col"},"Plan",-1)),t[67]||(t[67]=n("th",{scope:"col"},"Status",-1)),n("th",XJ,[n("button",{type:"button",class:P(["sortable",{active:e.query?.sort=="purchasedAt"}]),onClick:t[10]||(t[10]=o=>e.sortBy("purchasedAt"))},[t[62]||(t[62]=g("Started ",-1)),e.sortIcon("purchasedAt")?(a(),l("svg",{key:0,class:P(["ui-icon sort-direction",{ascending:e.sortIcon("purchasedAt")==="fa-arrow-up"}]),"aria-hidden":"true"},[...t[61]||(t[61]=[n("use",{href:"#project-icon-arrow"},null,-1)])],2)):f("v-if",!0)],2)]),n("th",JJ,[n("button",{type:"button",class:P(["sortable",{active:e.query?.sort=="until"}]),onClick:t[11]||(t[11]=o=>e.sortBy("until"))},[t[64]||(t[64]=g("Renews / ends ",-1)),e.sortIcon("until")?(a(),l("svg",{key:0,class:P(["ui-icon sort-direction",{ascending:e.sortIcon("until")==="fa-arrow-up"}]),"aria-hidden":"true"},[...t[63]||(t[63]=[n("use",{href:"#project-icon-arrow"},null,-1)])],2)):f("v-if",!0)],2)]),t[68]||(t[68]=n("th",{scope:"col"},"Cancelling",-1)),t[69]||(t[69]=n("th",{scope:"col"},"Revoked",-1)),t[70]||(t[70]=n("th",{scope:"col"},"Applies to",-1))])]),n("tbody",null,[(a(!0),l(q,null,Q(e.grants,o=>(a(),l("tr",{key:o.id},[n("th",QJ,[o.user?(a(),l("a",{key:0,title:o.user,href:e.safeUrl("/admin/users/"+o.user)},c(o.user),9,ZJ)):(a(),l("span",xJ,"Deleted user"))]),n("td",null,[n("span",eQ,[n("span",{class:P(["bl-swatch","bl-"+o.family]),"aria-hidden":"true"},null,2),g(c(e.planName(o.planId)),1)]),o.pack?(a(),l("small",tQ,"Part of a paper pack")):f("v-if",!0)]),n("td",null,[n("span",nQ,[n("span",{class:P(["status-dot",o.state==="active"?"st-ready":o.state==="revoked"?"st-error":"st-expired"])},null,2),g(c(o.state==="active"?"Active":o.state==="revoked"?"Revoked":"Expired"),1)]),["active","paid"].includes(o.status)?f("v-if",!0):(a(),l("small",sQ,"Stripe: "+c(e.statusText(o)),1))]),n("td",null,c(o.purchasedAt?e.fmt?.date(o.purchasedAt):"\u2014"),1),n("td",null,[o.never?(a(),l(q,{key:0},[g("Never ends")],64)):o.until?(a(),l(q,{key:1},[g(c(e.fmt?.date(o.until)),1)],64)):(a(),l(q,{key:2},[g("\u2014")],64)),o.subscription&&o.state==="active"?(a(),l("small",oQ,c(o.cancelAtPeriodEnd?"Ends":"Renews"),1)):f("v-if",!0)]),n("td",null,[o.cancelAtPeriodEnd?(a(),l("span",iQ,"Cancelling")):(a(),l("span",rQ,"\u2014"))]),n("td",null,[o.revoked?(a(),l(q,{key:0},[n("span",aQ,c(e.revocationText(o.revocationReason)),1),o.revokedAt?(a(),l("small",lQ,c(e.fmt?.date(o.revokedAt)),1)):f("v-if",!0)],64)):(a(),l("span",dQ,"\u2014"))]),n("td",uQ,[e.scopeHref(o.scope)?(a(),l("a",{key:0,href:e.safeUrl(e.scopeHref(o.scope))},[(a(),l("svg",pQ,[n("use",{href:o.scope.kind==="conference"?"#project-icon-conference":"#project-type-repo"},null,8,fQ)])),n("span",null,c(o.scope.id),1)],8,cQ)):(a(),l("span",mQ,"Account"))])]))),128))])])])):f("v-if",!0),e.total===0?(a(),l("div",hQ,[t[72]||(t[72]=n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#project-icon-inbox"})],-1)),n("span",null,c(e.hasFilters()?"No subscriptions or purchases match these filters.":"No subscriptions or purchases yet."),1),e.hasFilters()?(a(),l("button",{key:0,type:"button",class:"btn btn-sm",onClick:t[12]||(t[12]=o=>e.clearFilters())},"Clear filters")):f("v-if",!0)])):f("v-if",!0),e.total<0&&!e.grantsError?(a(),l("div",gQ,"Loading subscriptions and purchases\u2026")):f("v-if",!0),e.total>0?(a(),l("div",vQ,[t[77]||(t[77]=n("span",{"aria-hidden":"true"},null,-1)),e.totalPage>1?(a(),l("div",yQ,[n("button",{class:"btn btn-sm",onClick:t[13]||(t[13]=o=>e.query.page=Math.max(1,e.query.page-1)),disabled:e.query?.page<=1},[...t[73]||(t[73]=[n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-chevron-left"})],-1),g(" Previous",-1)])],8,bQ),T(n("input",{type:"number",class:"form-control form-control-sm",min:"1",style:{width:"56px"},"aria-label":"Page",max:e.totalPage},null,8,wQ),[[s,{state:e.viewState,set:o=>{e.query.page=o},value:e.query?.page,form:null,options:{}}]]),n("span",null,"of "+c(e.totalPage),1),n("button",{class:"btn btn-sm",onClick:t[14]||(t[14]=o=>e.query.page=Math.min(e.totalPage,e.query.page+1)),disabled:e.query?.page>=e.totalPage},[...t[74]||(t[74]=[g("Next ",-1),n("svg",{class:"ui-icon","aria-hidden":"true"},[n("use",{href:"#ui-icon-chevron-right"})],-1)])],8,kQ)])):f("v-if",!0),n("span",CQ,[t[76]||(t[76]=n("label",{for:"bl-limit"},"Per page",-1)),T((a(),l("select",EQ,[...t[75]||(t[75]=[n("option",{value:"10"},"10",-1),n("option",{value:"25"},"25",-1),n("option",{value:"50"},"50",-1),n("option",{value:"100"},"100",-1)])])),[[s,{state:e.viewState,set:o=>{e.query.limit=o},value:e.query?.limit,form:null,options:{}}]])])])):f("v-if",!0)])])}var SQ={class:"paper-footer"},NQ={class:"paper-footer-inner"},RQ={class:"paper-footer-col"},PQ={key:0,href:"/dashboard"},DQ={key:1,href:"/conferences"},AQ={class:"paper-footer-foot"};function Rp(e,t){return a(),l("footer",SQ,[n("div",NQ,[t[3]||(t[3]=n("div",{class:"paper-footer-brand"},[n("div",{class:"paper-footer-mark"},[g("Anonymous "),n("em",null,"GitHub")]),n("p",{class:"paper-footer-tag"}," A read-only, identity-stripped mirror of your repository, built for double-anonymous peer review. ")],-1)),n("div",RQ,[t[0]||(t[0]=n("div",{class:"paper-footer-head"},"Product",-1)),t[1]||(t[1]=n("a",{href:"/anonymize"},"Anonymize",-1)),e.user?(a(),l("a",PQ,"My work")):f("v-if",!0),e.user?(a(),l("a",DQ,"Conferences")):f("v-if",!0),t[2]||(t[2]=n("a",{href:"/faq"},"FAQ",-1))]),t[4]||(t[4]=Ce('',2))]),t[6]||(t[6]=n("div",{class:"paper-footer-rule"},null,-1)),n("div",AQ,[n("span",null,"\xA9 "+c(e.year||new Date().getFullYear())+" Anonymous GitHub \xB7 GPL-3.0 licensed",1),t[5]||(t[5]=n("span",{class:"paper-footer-meta"},"Built for reviewers, by researchers.",-1))])])}var ur={"partials/reviewConsent.htm":Jc,"partials/connections.htm":Qc,"partials/signin.htm":Zc,"partials/404.htm":xc,"partials/admin/billing.htm":Np,"partials/admin/emails.htm":Xc,"partials/admin/conferences.htm":ep,"partials/admin/errors.htm":tp,"partials/admin/overview.htm":np,"partials/admin/queues.htm":sp,"partials/admin/repositories.htm":op,"partials/admin/user.htm":ip,"partials/admin/users.htm":rp,"partials/anonymize.htm":ap,"partials/anonymizePullRequest.htm":lp,"partials/claim.htm":dp,"partials/conference.htm":up,"partials/conferences.htm":cp,"partials/dashboard.htm":pp,"partials/explorer.htm":fp,"partials/faq.htm":mp,"partials/gist.htm":hp,"partials/header.htm":gp,"partials/home.htm":vp,"partials/loading.htm":yp,"partials/newConference.htm":bp,"partials/pageView.htm":wp,"partials/pr-dashboard.htm":kp,"partials/profile.htm":Cp,"partials/pullRequest.htm":Ep,"partials/status.htm":Sp,"partials/footer.htm":Rp};var TQ={class:"ui-icon-definitions","aria-hidden":"true",focusable:"false"};function Pp(e,t){return a(),l("svg",TQ,[...t[0]||(t[0]=[Ce('',1)])])}function Dp(e,t){e==="partials/explorer.htm"&&(t.sidebarCollapsed=window.matchMedia?.("(max-width: 767px)").matches||!1,t.sidebarHidden=!1,t.dirExpanded=!1,t.moreOpen=!1,t.tocOpen=!1,t.gotoOpen=!1,t.gotoValue="",t.gotoError="",t.mdFindOpen=!1,t.mdFindQuery="",t.mdFindTotal=0,t.mdFindIndex=0,t.mdFindCase=!1,t.accountOpen=!1,t.helpOpen=!1,t.sidebarWidth=Math.min(520,Math.max(220,Number(localStorage.getItem("sidebarWidth"))||(window.innerWidth>=1280?320:280))),document.documentElement.style.setProperty("--sidebar-w",t.sidebarWidth+"px"),t.startSidebarResize=o=>{o.preventDefault();let r=o.clientX,d=t.sidebarWidth,p=y=>{t.sidebarWidth=Math.min(520,Math.max(220,d+y.clientX-r)),document.documentElement.style.setProperty("--sidebar-w",t.sidebarWidth+"px")},u=()=>{window.removeEventListener("pointermove",p),window.removeEventListener("pointerup",u),document.body.classList.remove("is-resizing"),localStorage.setItem("sidebarWidth",String(t.sidebarWidth))};document.body.classList.add("is-resizing"),window.addEventListener("pointermove",p),window.addEventListener("pointerup",u)}),e==="partials/anonymize.htm"&&(t.prTabState={active:t.options.diff?"diff":"comments"},t.watchGroup(["options.diff","options.comments"],()=>{t.options[t.prTabState.active]||(t.prTabState.active=t.options.diff?"diff":t.options.comments?"comments":null)})),e==="partials/gist.htm"&&(t.tabState={active:t.details?.files?"files":"comments"}),["partials/conferences.htm","partials/conference.htm"].includes(e)&&(t.statusLabels={ready:"Ready",expired:"Expired",removed:"Removed"});let i={"partials/dashboard.htm":["filteredItems",()=>t.items,"itemFilter"],"partials/conferences.htm":["filteredConferences",()=>t.conferences,"conferenceFilter"],"partials/conference.htm":["filteredRepositories",()=>t.conference?.repositories,"repoFiler"],"partials/admin/repositories.htm":["filteredRepositories",()=>t.repositories,"repoFiler"],"partials/admin/user.htm":["filteredRepositories",()=>t.repositories,"repoFiler"],"partials/admin/users.htm":["filteredUsers",()=>t.users,"userFiler"],"partials/admin/conferences.htm":["filteredConferences",()=>t.conferences]}[e];if(i){let o=Rt(()=>t.fmt.orderBy(t.fmt.filter(i[1](),t[i[2]]),t.orderBy));Object.defineProperty(t,i[0],{configurable:!0,get:()=>o.value})}}function Ap(e=(...t)=>fetch(...t)){async function t(i,o,r,d={}){let p=new URL(o,window.location.href);for(let[h,b]of Object.entries(d.params||{}))if(b!=null)for(let m of Array.isArray(b)?b:[b])p.searchParams.append(h,typeof m=="object"?JSON.stringify(m):m);let u=new AbortController,y;d.timeout?.then?d.timeout.then(()=>u.abort()):d.timeout&&(y=setTimeout(()=>u.abort(),d.timeout));try{let h={Accept:"application/json, text/plain, */*",...d.headers},b=document.cookie.match(/(?:^|;\s*)XSRF-TOKEN=([^;]*)/);b&&p.origin===window.location.origin&&(h["X-XSRF-TOKEN"]=decodeURIComponent(b[1]));let m;r!==void 0&&(r instanceof FormData?m=r:(h["Content-Type"]||(h["Content-Type"]="application/json;charset=utf-8"),m=JSON.stringify(r)));let w=await e(p.href,{method:i,headers:h,body:m,credentials:"same-origin",signal:u.signal}),N;if(d.onDownloadProgress&&w.ok&&w.body?.getReader&&typeof TextDecoder<"u"){let v=w.body.getReader(),E=new TextDecoder,D=[],V=0;try{for(;;){let{value:_,done:z}=await v.read();if(z)break;D.push(E.decode(_,{stream:!0})),V+=_.byteLength,d.onDownloadProgress(V)}D.push(E.decode()),N=D.join("")}finally{v.releaseLock()}}else N=await w.text();let S=N;if(d.transformResponse)S=d.transformResponse(N);else if(N&&(/json/i.test(w.headers.get("content-type")||"")||/^[\[{]/.test(N.trim())))try{S=JSON.parse(N)}catch{}let R={data:S,status:w.status,headers:v=>w.headers.get(v)};if(!w.ok)throw R;return R}catch(h){throw h.name==="AbortError"?{status:-1,data:null}:h}finally{clearTimeout(y)}}let s={};for(let i of["get","delete","head"])s[i]=(o,r)=>t(i.toUpperCase(),o,void 0,r);for(let i of["post","put","patch"])s[i]=(o,r,d)=>t(i.toUpperCase(),o,r,d);return s}var Tp={resolve:e=>Promise.resolve(e),reject:e=>Promise.reject(e),all:e=>Promise.all(e),defer(){let e,t;return{promise:new Promise((i,o)=>{e=i,t=o}),resolve:e,reject:t}}};var Op=function(e){function t(s){return s=s||{used:0,total:0},s.unlimited=!s.total,s.percent=s.unlimited?0:Math.min(100,s.used*100/s.total),s.level=s.unlimited?"unlimited":s.percent>=95?"danger":s.percent>=80?"warn":"ok",s}return{decorate:t,load:function(){return e.get("/api/user/quota").then(s=>{let i=s.data||{};return i.storage=t(i.storage),i.file=t(i.file),i.repository=t(i.repository),i})}}};var Ip={name:"htmlDoc",props:["content","baseUrl","allowScripts"],setup(e){let t=St(null);return mn(()=>{let i=[t.value][0];i.classList.add("html-doc");function o(){i.innerHTML="";let r=e.content;if(typeof r!="string")return;let d=document.createElement("iframe");d.className="html-doc-frame",d.setAttribute("title","Rendered HTML document");let p=["allow-popups","allow-popups-to-escape-sandbox"];e.allowScripts&&p.push("allow-scripts","allow-forms","allow-modals"),d.setAttribute("sandbox",p.join(" ")),d.setAttribute("referrerpolicy","no-referrer"),i.appendChild(d);let u="";e.baseUrl&&(u=''),d.srcdoc=u+r}ut(()=>e.content,o,{immediate:!0}),ut(()=>e.baseUrl,o,{immediate:!0}),ut(()=>e.allowScripts,o,{immediate:!0})}),()=>Ae("html-doc",{ref:t})}};var Mp={name:"pdfviewer",props:["src"],setup(e){let t=St(null);return mn(()=>{let s=[t.value],i=400,o=[.5,.75,1,1.25,1.5,2,3],r=1e3,d=s[0];d.classList.add("pdf-viewer");let p=null,u=[],y=!1,h=null,b=1,m=0,w=1,N=0,S=0,R=612/792,v=0,E=null,D=new Map,V=0;function _(O){let F=D.get(O);F&&(F.cancelled=!0,F.task?.cancel?.(),D.delete(O));let J=O.querySelector("canvas");J&&(J.width=0,J.height=0),O.innerHTML="",delete O.dataset.state}let z=document.createElement("div");z.className="pdf-toolbar";let x=document.createElement("div");x.className="pdf-pages",x.tabIndex=0,x.setAttribute("aria-label","PDF pages"),d.appendChild(z),d.appendChild(x);function X(O,F,J){let j=document.createElement("button");return j.type="button",j.className="pdf-toolbar-btn",j.title=F,j.setAttribute("aria-label",F),j.innerHTML='',j.addEventListener("click",J),j}let I=X("fa-chevron-up","Previous page",function(){Be(w-1)}),U=X("fa-chevron-down","Next page",function(){Be(w+1)}),C=document.createElement("input");C.type="text",C.className="pdf-toolbar-page",C.setAttribute("aria-label","Page number"),C.title="Page number \u2014 type a page and press Enter",C.addEventListener("keydown",function(O){O.key==="Enter"&&(Be(parseInt(C.value,10)),C.blur())}),C.addEventListener("blur",function(){C.value=String(w)});let L=document.createElement("span");L.className="pdf-toolbar-count";let H=X("fa-search-minus","Zoom out",function(){ve(o[Math.max(0,me()-1)])}),K=X("fa-search-plus","Zoom in",function(){ve(o[Math.min(o.length-1,me()+1)])}),ie=document.createElement("button");ie.type="button",ie.className="pdf-toolbar-btn pdf-toolbar-zoom",ie.title="Reset zoom to fit the width",ie.setAttribute("aria-label","Reset zoom to fit the width"),ie.addEventListener("click",function(){ve(1)}),z.appendChild(I),z.appendChild(U);let se=document.createElement("span");se.className="pdf-toolbar-group",se.appendChild(C),se.appendChild(L),z.appendChild(se);let Y=document.createElement("span");Y.className="pdf-toolbar-group pdf-toolbar-right",Y.appendChild(H),Y.appendChild(ie),Y.appendChild(K),z.appendChild(Y);function me(){let O=0;for(let F=0;F=O,ie.textContent=b===1||!m?"Fit":Math.round(Re()/(m*96/72)*100)+"%",H.disabled=me()===0,K.disabled=me()===o.length-1}function Ue(O){let F=u[O-1];F&&(x.scrollTop+=F.getBoundingClientRect().top-x.getBoundingClientRect().top)}function Be(O){if(!p||isNaN(O))return;let F=Math.min(Math.max(1,O),p.numPages);u[F-1]&&(Ue(F),w=F,N=F,S=Date.now()+800,Se(),W())}function Qe(){if(!u.length||Date.now(){}),E=null),h&&(clearTimeout(h),h=null),p&&(p.destroy(),p=null),u=[],w=1,x.innerHTML="",Se()}function et(){x.innerHTML="";let O=document.createElement("div");O.className="pdf-viewer-error",O.textContent="This PDF could not be displayed.",x.appendChild(O)}function Re(){let O=Math.max(120,x.clientWidth-24);return Math.round(Math.min(O,r)*b)}function Fe(O,F,J){let j=window.devicePixelRatio||1,ee=O.getViewport({scale:1}),le=parseFloat(F.style.width);if(!le)return;let ne=O.getViewport({scale:le/ee.width*j}),oe=document.createElement("canvas");return oe.width=Math.floor(ne.width),oe.height=Math.floor(ne.height),oe.style.width=le+"px",oe.style.height=Math.floor(ne.height/j)+"px",F.innerHTML="",F.appendChild(oe),F.style.height=oe.style.height,J.task=O.render({canvasContext:oe.getContext("2d"),viewport:ne}),J.task.promise}function W(){if(!p)return;let O=v,F=x.getBoundingClientRect(),J=F.top-i,j=F.top+x.clientHeight+i,ee=u.map((ne,oe)=>({slot:ne,i:oe,rect:ne.getBoundingClientRect()})).filter(ne=>ne.rect.top<=j&&ne.rect.bottom>=J).sort((ne,oe)=>Math.abs(ne.rect.top-F.top)-Math.abs(oe.rect.top-F.top)).slice(0,6),le=new Set(ee.map(ne=>ne.slot));for(let ne of D.keys())le.has(ne)||_(ne);for(let{slot:ne,i:oe}of ee){if(ne.dataset.state||V>=2)continue;let te={cancelled:!1,task:null};D.set(ne,te),V++,ne.dataset.state="rendering";let ke;p.getPage(oe+1).then(pe=>{if(ke=pe,!(te.cancelled||O!==v))return Fe(ke,ne,te)}).then(()=>{te.cancelled||O!==v||(ne.dataset.state="done",N&&Date.now(){!te.cancelled&&O===v&&(ne.dataset.state="failed")}).finally(()=>{V--,ke?.cleanup?.(),p&&W()})}}function fe(){y||(y=!0,window.requestAnimationFrame(function(){y=!1,Qe(),W()}))}function de(){let O=!1;function F(){O||(O=!0,W())}window.requestAnimationFrame(F),window.setTimeout(F,50)}function ce(){v++,u.forEach(_);let O=Re();u.forEach(function(F){delete F.dataset.state,F.innerHTML="",F.style.width=O+"px",F.style.height=Math.round(O/R)+"px"}),W()}function ve(O){if(!p||!u.length||O===b)return;let F=w;b=O,Se(),ce(),Be(F)}function Me(){p&&(h&&clearTimeout(h),h=setTimeout(function(){h=null,p&&u.length&&ce()},250))}function A(O){if(He(),!O)return;let F=v;E=pdfjsLib.getDocument({url:O,isEvalSupported:!1,standardFontDataUrl:"/script/external/pdf-standard-fonts/",cMapUrl:"/script/external/pdf-cmaps/",cMapPacked:!0}),E.promise.then(function(J){if(F!==v){J.destroy();return}return p=J,p.getPage(1).then(function(j){if(F!==v)return;let ee=j.getViewport({scale:1});ee.width&&ee.height&&(R=ee.width/ee.height),m=ee.width||0;let le=Re();for(let ne=1;ne<=p.numPages;ne++){let oe=document.createElement("div");oe.className="pdf-viewer-page",oe.style.width=le+"px",oe.style.height=Math.round(le/R)+"px",x.appendChild(oe),u.push(oe)}Se(),de()})}).catch(function(){F===v&&et()})}x.addEventListener("scroll",fe,{passive:!0}),$(window).on("resize",Me),Se(),ut(()=>e.src,A,{immediate:!0}),is(function(){x.removeEventListener("scroll",fe),$(window).off("resize",Me),He()})}),()=>Ae("pdfviewer",{ref:t})}};var OQ={key:0,class:"quota-row quota-usage"},IQ={class:"quota-header"},MQ={class:"quota-label"},VQ={class:"project-type-svg","aria-hidden":"true"},qQ=["href"],_Q={key:0,class:"quota-percent"},LQ={key:1,class:"quota-unlimited-tag"},$Q={class:"quota-value"},FQ={key:0},UQ=["aria-label","aria-valuenow","aria-valuemax","aria-valuetext"],BQ={key:1,class:"quota-remaining"},zQ={key:2,class:"quota-remaining quota-limit"};function Vp(e,t){return e.quota?(a(),l("div",OQ,[(a(),l(q,null,Q([{key:"repository",label:"Repositories",kind:"count",icon:"project-type-repo"},{key:"storage",label:"Storage",kind:"bytes",icon:"project-icon-storage"},{key:"file",label:"Files",kind:"count",icon:"project-icon-file"}],s=>n("div",{class:P(["quota-item","quota-"+e.quota[s.key].level]),key:s.key},[n("div",IQ,[n("span",MQ,[(a(),l("svg",VQ,[n("use",{href:"#"+s.icon},null,8,qQ)])),g(c(s.label),1)]),e.quota[s.key].unlimited?f("v-if",!0):(a(),l("span",_Q,c(e.quota[s.key].percent>0&&e.quota[s.key].percent<1?"<1":e.fmt.number(e.quota[s.key].percent,0))+"% used",1)),e.quota[s.key].unlimited?(a(),l("span",LQ,"Unlimited")):f("v-if",!0)]),n("div",$Q,[n("strong",null,c(e.formatAmount(e.quota[s.key].used,s.kind)),1),e.quota[s.key].unlimited?f("v-if",!0):(a(),l("span",FQ," / "+c(e.formatAmount(e.quota[s.key].total,s.kind)),1))]),e.quota[s.key].unlimited?f("v-if",!0):(a(),l("div",{key:0,class:P(["quota-track","quota-"+e.quota[s.key].level]),role:"progressbar","aria-valuemin":"0","aria-label":s.label+" quota","aria-valuenow":Math.min(e.quota[s.key].used,e.quota[s.key].total),"aria-valuemax":e.quota[s.key].total,"aria-valuetext":e.fmt.number(e.quota[s.key].percent,0)+"% used"},[e.quota[s?.key].unlimited?f("v-if",!0):(a(),l("div",{key:0,class:"quota-fill",style:Te({width:e.quota[s.key].percent+"%"})},null,4))],10,UQ)),!e.quota[s.key].unlimited&&e.quota[s.key].used=e.quota[s.key].total?(a(),l("p",zQ,c(e.quota[s.key].used>e.quota[s.key].total?"Limit exceeded":"Limit reached"),1)):f("v-if",!0)],2)),64))])):f("v-if",!0)}var HQ={props:["quota","fmt"],setup(e){return{formatAmount:(t,s)=>s==="bytes"?e.fmt.humanFileSize(e.quota?.storage?.unit==="bytes"?t*8:t).replace(/([a-zA-Z]+)$/," $1"):e.fmt.number(t)}},render:Vp},jQ=new Set(he),Lp=e=>e?.querySelectorAll("pre code.language-diff, pre code.lang-diff").forEach(t=>{if(t.querySelector(".md-diff-line"))return;let s=t.innerHTML.replace(/\n$/,"").split(` `);t.innerHTML=s.map(i=>{let o=i.replace(/^(<[^>]+>)+/,"").charAt(0),r=i.startsWith("@@")?"hunk":o==="+"?"add":o==="-"?"remove":"";return`${i||" "}`}).join(` `)}),qp=(e,t=0)=>{let s=(String(e).slice(t).match(/^[ \t]*/)[0]||"").replace(/\t/g," ").length;return Math.min(t+s+4,24)},$p=e=>{e?.closest?.(".reviewer-preview")&&e.querySelectorAll("pre code").forEach(t=>{let s=t.querySelectorAll(".md-diff-line");if(s.length){s.forEach(o=>{o.classList.contains("is-hunk")||o.style.setProperty("--hang",qp(o.textContent,1)+"ch")});return}if(t.querySelector(".code-line"))return;let i=[];t.innerHTML=t.innerHTML.replace(/\n$/,"").split(` `).map(o=>{let r=i.join("");o.replace(/<\/?span\b[^>]*>/g,p=>(p.startsWith("]+>/g,"");return`${r}${o||" "}${"".repeat(i.length)}`}).join(` -`)})},Fp={props:["content","terms","options"],setup(e){let t=St(null),s=()=>{t.value.innerHTML=renderMD(e.content||"",window.location.pathname+"/../"),Lp(t.value),$p(t.value)};return hn(()=>{s(),dt(()=>[e.content,e.terms,e.options],s,{deep:!0})}),()=>De("markdown",{ref:t})}},JJ={props:["file","terms","options"],setup(e){let t=St(null),s=()=>tt(()=>{t.value?.querySelectorAll("pre code").forEach(i=>window.Prism?.highlightElement(i)),Lp(t.value),$p(t.value)});return hn(s),dt(()=>[e.file?.content,e.terms,e.options],s,{deep:!0}),()=>{let i=e.file||{},o=(i.filename||"").split(".").pop().toLowerCase();if(["md","markdown"].includes(o)||i.language==="Markdown")return De("gist-file",{ref:t},De(Fp,{content:i.content,terms:e.terms,options:e.options}));let r={js:"javascript",jsx:"javascript",ts:"javascript",typescript:"javascript",py:"python",html:"markup",xml:"markup",svg:"markup",sh:"bash"},d=(i.language||o||"none").toLowerCase();return De("gist-file",{ref:t},De("pre",{class:"line-numbers"},De("code",{class:"language-"+(r[d]||d),key:i.content},i.content||"")))}}},QJ=e=>e?.querySelectorAll(".nb-input pre").forEach(t=>{if(t.parentElement?.classList.contains("nb-code-scroll"))return;let s=document.createElement("div");s.className="nb-code-scroll",t.replaceWith(s),s.appendChild(t);let i=()=>{let o=t.scrollWidth-t.clientWidth>1;if(s.classList.toggle("is-overflowing",o),s.classList.toggle("is-at-end",o&&t.scrollLeft+t.clientWidth>=t.scrollWidth-2),!o)return;let r=t.clientWidth-16,d=Math.max(24,r*t.clientWidth/t.scrollWidth);s.style.setProperty("--thumb-w",d+"px"),s.style.setProperty("--thumb-x",(r-d)*t.scrollLeft/(t.scrollWidth-t.clientWidth)+"px")};t.addEventListener("scroll",i,{passive:!0}),window.ResizeObserver?new ResizeObserver(i).observe(t):i(),i()}),ZJ={props:["file","content"],setup(e){let t=St(null),s=0,i,o=async()=>{let r=++s;i?.abort(),i=new AbortController;try{let d=e.content?JSON.parse(e.content):await fetch(e.file?.download_url||e.file,{signal:i.signal}).then(p=>{if(!p.ok)throw Error("Notebook request failed");return p.json()});if(await Jn("notebook"),r!==s)return;t.value.innerHTML=_o(DOMPurify.sanitize(nb.parse(d).render())),t.value.querySelectorAll("pre code").forEach(p=>window.Prism?.highlightElement(p)),QJ(t.value)}catch(d){r===s&&d.name!=="AbortError"&&(t.value.textContent="Unable to render the notebook.")}};return hn(()=>{o(),dt(()=>[e.file,e.content],o)}),is(()=>{s++,i?.abort()}),()=>De("notebook",{ref:t})}},xJ={props:["stats"],setup(e){return()=>{let t=Object.entries(e.stats||{}).filter(([,i])=>i.code),s=t.reduce((i,[,o])=>i+o.code,0);return De("loc",t.map(([i,o])=>De("div",{class:"lang",title:`${i}: ${o.code.toLocaleString()} lines`,style:{width:o.code*100/s+"%",background:langColors[i]}})))}}},Up={Markdown:Fp,GistFile:JJ,Notebook:ZJ,Loc:xJ,HtmlDoc:Ip,QuotaUsage:YJ,Pdfviewer:id(async()=>(await Jn("pdf"),pdfjsLib.GlobalWorkerOptions.workerSrc="/script/external/pdf.worker.js",Mp))},Bp={async mounted(e,{value:t}){e._editorValue=t;try{if(await ni(),e._editorDisposed)return;let s=e._editorValue,i=ace.edit(e);e._editor=i,i.setValue(String(s.content??""),-1),_p(e,s.options),e._editorCleanup=s.options?.onLoad?.(i)}catch(s){e._editorDisposed||(e.textContent=s.message)}},updated(e,{value:t}){e._editorValue=t,e._editor&&(e._editor.getValue()!==String(t.content??"")&&e._editor.setValue(String(t.content??""),-1),_p(e,t.options))},beforeUnmount(e){e._editorDisposed=!0,e._editorCleanup?.(),e._editor?.destroy()}};function _p(e,t={}){let s=XJ.has(t.mode)?t.mode:"text";e._editor.session.setMode("ace/mode/"+s),t.theme&&e._editor.setTheme("ace/theme/"+t.theme),e._editor.setReadOnly(t.readOnly!==!1)}var zp={mounted(e){if(!window.IntersectionObserver)return;let t=[...e.querySelectorAll('a[href^="#"]')],s=new Set,i=new IntersectionObserver(o=>{o.forEach(d=>d.isIntersecting?s.add(d.target.id):s.delete(d.target.id));let r=t.find(d=>s.has(d.hash.slice(1)));r&&t.forEach(d=>d.classList.toggle("active",d===r))},{rootMargin:"-20% 0px -60% 0px",threshold:0});tt(()=>{t.forEach(o=>{let r=document.getElementById(o.hash.slice(1));r&&i.observe(r)}),t[0]&&!t.some(o=>o.classList.contains("active"))&&t[0].classList.add("active")}),e._observer=i},beforeUnmount(e){e._observer?.disconnect()}};function Hp(e){let t=[],s=0,i=/\bXXXX-(\d+)\b/g,o;for(;o=i.exec(e);)o.index>s&&t.push(e.slice(s,o.index)),t.push(De("span",{class:"redact-slot",role:"img","aria-label":"Redacted term "+o[1]},[De("i",null,o[1])])),s=o.index+o[0].length;return t.length?(s{s.push(r),d=1024&&inQ(e.file)),p=()=>e.selectedPath??"/"+(Array.isArray(s.params.path)?s.params.path.join("/"):s.params.path||"");dt(()=>[s.params.repoId,s.params.path,e.selectedPath],()=>{let w="";p().split("/").filter(Boolean).forEach(R=>{w+="/"+R,o[w]=!0})},{immediate:!0});let u=Rt(()=>{if(!e.searchQuery||!e.searchResults)return null;let w=new Set,R=new Set;return e.searchResults.forEach(S=>{w.add(S.path?`${S.path}/${S.name}`:S.name);let N="";(S.path||"").split("/").filter(Boolean).forEach(v=>{N=N?N+"/"+v:v,R.add(N)})}),{files:w,folders:R}}),y=()=>[...i.value.querySelectorAll("li > a")],m=w=>{if(i.value.querySelector(".tree-focused")?.classList.remove("tree-focused"),!w)return;if(r=w.dataset.path,w.classList.add("tree-focused"),e.selectedPath===void 0){w.scrollIntoView?.({block:"nearest"}),i.value.focus();return}let R=i.value.scrollHeight>i.value.clientHeight?i.value:i.value.closest(".leftCol-body");if(R){let S=w.getBoundingClientRect(),N=R.getBoundingClientRect();S.topN.bottom&&(R.scrollTop+=S.bottom-N.bottom)}i.value.focus({preventScroll:!0})};function b(w){let R=y(),S=i.value.querySelector(".tree-focused")||R[0],N=R.indexOf(S);if(!["ArrowDown","ArrowUp","ArrowRight","ArrowLeft","Enter"].includes(w.key)||(w.preventDefault(),w.key==="ArrowDown"&&m(R[(N+1)%R.length]),w.key==="ArrowUp"&&m(R[(N-1+R.length)%R.length]),!S))return;let v=S.closest("li");w.key==="ArrowRight"&&v.classList.contains("folder")&&(v.classList.contains("open")?m(v.querySelector(":scope > ul > li > a")):S.click()),w.key==="ArrowLeft"&&(v.classList.contains("folder")&&v.classList.contains("open")?S.click():m(v.parentElement.closest("li.folder")?.querySelector(":scope > a"))),w.key==="Enter"&&S.click()}function h(w,R=""){let S=[...w].sort((N,v)=>+!!v.children-+!!N.children||N.name.localeCompare(v.name));return De("ul",S.flatMap(N=>{let v=N,E=v.name,M=(R+"/"+E).slice(1);if(u.value&&!u.value.files.has(M)&&!u.value.folders.has(M))return[];for(;v.children?.length===1&&v.children[0].children&&e.page?.loadedFolders?.[(R+"/"+E).slice(1)];)v=v.children[0],E+="/"+v.name;let V=R+"/"+E,_=!!v.children,G=u.value?o[V]!==!1:!!o[V],te=_&&e.page?.options?.truncatedFolders?.includes(V.slice(1)),X=De("span",{class:_?"tree-icon-folder":"far fa-file tree-icon-file","aria-hidden":"true"},_?De("svg",{viewBox:"0 0 14 12",focusable:"false"},De("path",{d:"M1.5 10.5v-9h4l1.5 2h5.5v7z"})):null),O=!1,U=E,C="",L="";if(E.length>80){let se=E.length-12;for(let Y=E.length-18;Y<=E.length-6;Y++)if(Y>0&&"-_. ".includes(E[Y])){se=Y;break}if(O=!/XXXX-\d+/.test(E.slice(Math.max(0,se-12))),U=E.slice(0,se).trimEnd(),C=E.slice(se).trimStart(),O){let Y=Math.max(8,30-C.length-1);if(U.length>Y&&!/XXXX-\d+/.test(U)){let he=-1;for(let Ue=Math.min(Y,U.length);Ue>=4;Ue--)if(".-_".includes(U[Ue])){he=Ue;break}let Se=E.slice(0,E.length-C.length);U=(he>0?U.slice(0,he):U.slice(0,Y)).trimEnd(),L=Se.slice(U.length)}}}let z=De("span",{class:{"tree-name":!0,"tree-name-split":O,"tree-name-wrap":!O},title:E.replace(/\bXXXX-(\d+)\b/g,"[redacted term $1]")},O?[De("span",{class:{"tree-name-head":!0,"is-cut":!!L}},Hp(U)),L?De("span",{class:"tree-name-middle"},L):null,De("span",{class:"tree-name-tail"},C)]:eQ(E)),K=se=>{if(m(se.currentTarget),!_){e.selectedPath!==void 0&&(se.preventDefault(),t("select",V));return}se.preventDefault(),o[V]=!G,o[V]&&!v.children.length&&e.page.getFiles(V.slice(1)),tt(()=>m(y().find(Y=>Y.dataset.path===r)))},ie=De("a",{"data-path":V,"aria-expanded":e.selectedPath!==void 0&&_?String(G):void 0,"aria-current":e.selectedPath!==void 0&&!_&&p()===V?"page":void 0,href:_?void 0:`/r/${encodeURIComponent(s.params.repoId)}${encodePathForUrl(V)}`,class:{"tree-focused":r===V},onClick:K},[_?De("span",{class:"tree-toggle"}):De("span",{class:"tree-spacer"}),X,z,te?De("span",{class:"truncated-warning",title:e.page.fmt.translate("WARNINGS.folder_truncated")},De("i",{class:"fas fa-exclamation-triangle"})):null]);return De("li",{key:V,class:{file:!0,folder:_,open:G,active:p()===V,truncated:te},title:_?"":`Size: ${tQ(v.size||0)}`},[ie,_&&G?v.children.length||!e.page?.loadedFolders?.[V.slice(1)]?h(v.children,V):De("ul",De("li",{class:"tree-empty"},"Empty folder")):null])}))}return()=>De("tree",{ref:i,tabindex:0,onKeydown:b},e.file?.length?u.value?.files.size===0?De("div",{class:"tree-search-empty"},"No files found"):h(d.value):"Empty repository")}};function Wp(){return st({errors:{},dirty:!1,touched:!1,submitted:!1,get invalid(){return Object.values(this.errors).some(Boolean)},setValidity(e,t){this.errors[e]=!t},setDirty(){this.dirty=!0}})}function Kp(e,t){if(!e[t]){let s=Wp();Object.defineProperty(s,"invalid",{get(){return Object.values(s.errors).some(Boolean)||Object.keys(s).some(i=>i!=="invalid"&&s[i]&&typeof s[i]=="object"&&s[i].invalid)}}),e[t]=s}return e[t]}var Yp={beforeMount(e,{value:t}){e._formState=Kp(t,e.name),e.addEventListener("submit",s=>s.preventDefault())}};function sQ(e){return e instanceof Date?isNaN(e)?"":`${e.getFullYear()}-${String(e.getMonth()+1).padStart(2,"0")}-${String(e.getDate()).padStart(2,"0")}`:e||""}function Gp(e){let t=e._field.binding.value;e.type==="checkbox"?e.checked=!!t:e.type==="radio"?e.checked=t==(e._value??e.value):e._field.timer||(e.value=e.type==="date"?sQ(t):t??""),Xa(e)}function Xa(e){let t=e._field.validation;if(!t)return;let s=e.validity;for(let[i,o]of Object.entries({required:s.valueMissing,pattern:s.patternMismatch,min:s.rangeUnderflow,max:s.rangeOverflow,date:s.badInput,email:s.typeMismatch&&e.type==="email",url:s.typeMismatch&&e.type==="url"}))t.setValidity(i,e.disabled||!o)}var Xp={beforeMount(e,{value:t}){var d;let s=t.form&&Kp(t.state,t.form),i=s&&e.name?s[d=e.name]||(s[d]=Wp()):null;e._field={binding:t,validation:i,timer:null};let o=()=>{clearTimeout(e._field.timer),e._field.timer=null;let p=e._field.binding,u=e.type==="checkbox"?e.checked:e._value??e.value;if(!(e.type==="radio"&&!e.checked)){if((e.type==="number"||e.type==="range")&&(u=e.value===""?null:Number(e.value)),e.type==="date"&&(u=e.value?new Date(e.value+"T00:00:00"):null),i){i.setDirty();for(let y of Object.keys(i.errors))i.setValidity(y,!0)}p.set(u),Xa(e),p.change?.()}};e._field.commit=o;let r=p=>{let u=e._field.binding.options?.debounce||0,y=typeof u=="number"?u:u[p.type]??u.default??0;clearTimeout(e._field.timer),y?e._field.timer=setTimeout(o,y):o()};e.addEventListener(e.tagName==="SELECT"||["checkbox","radio","date"].includes(e.type)?"change":"input",r),e.addEventListener("blur",()=>{i&&(i.touched=!0),e._field.timer&&o()})},mounted:Gp,updated(e,{value:t}){e._field.binding=t,Gp(e)},beforeUnmount(e){clearTimeout(e._field.timer);let{binding:t,validation:s}=e._field,i=t.form&&t.state[t.form];i&&i[e.name]===s&&delete i[e.name]}};function Jp(e,t){let s=e.target.closest("form");if(s?._formState&&(s._formState.submitted=!0),s?.querySelectorAll("input, select, textarea").forEach(i=>{i._field?.timer&&i._field.commit(),i._field&&Xa(i)}),s&&!s.checkValidity()){let i=s.querySelector("input:invalid, select:invalid, textarea:invalid");i?.scrollIntoView?.({block:"center"}),i?.focus(),s.reportValidity();return}return t()}var Qp=Symbol("session"),oQ=/^\/(w|api|github)(\/|$)/;function Zp(e,t={}){let s=e?.split(".").reduce((i,o)=>i?.[o],Kn);return s==null&&e?.startsWith("ERRORS.")&&(s=Kn.ERRORS.unknown_error),String(s??e??"").replace(/{{\s*([^}]+?)\s*}}/g,(i,o)=>t[o]??"")}var iQ={...wa,translate:Zp};function rQ(e){if(e==null||e==="")return e;try{let t=new URL(e,window.location.href);return["http:","https:","mailto:","tel:","blob:"].includes(t.protocol)?e:void 0}catch{return}}function aQ(e="#app",t={}){let s=!!document.querySelector('meta[name="review-consent-page"][content="1"]'),i=s&&window.location.pathname==="/review-link"?sl(window):null,o=()=>{let h=i;return i=null,h};!t.history&&window.location.pathname==="/"&&/^#!\/r\/[^/?#]+/.test(window.location.hash)&&window.history.replaceState(window.history.state,"",window.location.hash.slice(2));let r=new Map,d=Dp(t.fetch),p,u;function y(){let h=Ct(),w={url(S){return S===void 0?u.currentRoute.value.fullPath:(u.push(S),w)},replace(S){return u.replace(S)},path(){return u.currentRoute.value.path},search(){return u.currentRoute.value.query}},R=new Proxy({},{get(S,N){let v=u.currentRoute.value.params[N];return Array.isArray(v)?v.join("/"):v}});return{takeReviewHandoff:o,http:d,...h,location:w,params:R,window,promises:Tp,html:{trustAsHtml:S=>S},translate:(S,N)=>Promise.resolve(Zp(S,N)),quotaService:Op(d)}}function m(h){return{name:h.template,setup(){let w=qo(Mt(Qp),r);h.setup(w,y()),Pp(h.template,w);let R=[];return()=>ur[h.template](w,R)}}}u=Mu({history:t.history||Tu(),routes:Yc.map(h=>h.redirect?h:{path:h.path,component:m(h),meta:{title:h.title,preserveExplorer:h.preserveExplorer}})});let b=Qd({setup(){p=qo(null,r),p.fmt=iQ,p.window=window,p.Math=Math,p.sanitize=S=>DOMPurify.sanitize(S??""),p.highlightRedactions=S=>(p.site_options,Mc(S)),p.submitForm=Jp,p.safeUrl=rQ;let h=y();Vc(p,h.http,h.location,h.timeout),os(Qp,p),dt(()=>p.title,S=>{document.title=S||"Anonymous GitHub"});let w=[],R=S=>{let N=S.target.closest?.("a[href]");if(S.defaultPrevented||S.button!==0||S.metaKey||S.ctrlKey||S.shiftKey||S.altKey||!N||N.hasAttribute("download")||N.target&&N.target!=="_self"||N.dataset.toggle||N.getAttribute("href").startsWith("#"))return;let E=new URL(N.href,window.location.href);s||/^\/review-link\/?$/i.test(E.pathname)||E.origin!==window.location.origin||oQ.test(E.pathname)||(S.preventDefault(),u.push(E.pathname+E.search+E.hash),$("#navbarSupportedContent.show").collapse("hide"))};return document.addEventListener("click",R),is(()=>document.removeEventListener("click",R)),()=>[Ap(p,[]),s||/^\/(r|repository)\//.test(p.path||"")?null:De("header",{class:["app-header",{"is-contained":p.path==="/"||p.path==="/faq","is-signin":p.path==="/signin"}]},ur["partials/header.htm"](p,w)),De("main",{class:"app-view align-items-stretch w-100"},De(ha,null,{default:({Component:S,route:N})=>S?De(S,{key:N.meta.preserveExplorer?N.matched[0]?.path:N.path}):null})),De("div",{class:"position-fixed p-3",style:{zIndex:999999999,right:0,bottom:0}},p.toasts.map((S,N)=>De("div",{class:"toast show",role:"alert","aria-live":"assertive","aria-atomic":"true",key:N},[De("div",{class:"toast-header"},[De("strong",{class:"mr-auto"},S.title),De("button",{type:"button",class:"ml-2 mb-1 close","aria-label":"Close",onClick:()=>p.removeToast(S)},"\xD7")]),De("div",{class:"toast-body"},S.body)])))]}});for(let[h,w]of Object.entries(Up))b.component(h,w);return b.component("Tree",jp),b.component("PartialView",{props:["name","state"],setup(h){let w=[];return()=>ur[h.name](h.state,w)}}),b.directive("field",Xp),b.directive("form",Yp),b.directive("code-editor",Bp),b.directive("paper-scrollspy",zp),b.use(u),u.beforeEach(async h=>{if(h.path==="/review-link"&&!s||s&&h.path!=="/review-link")return window.location.assign(h.fullPath),!1;p?.emit("routeLeave"),/^\/(r|repository|anonymize|pull-request-anonymize|gist-anonymize|pr|gist)(\/|$)/.test(h.path)&&await Jn("markdown"),/^\/(r|repository|anonymize|pull-request-anonymize|gist-anonymize|pr|gist)(\/|$)/.test(h.path)&&await Jn("org")}),u.afterEach(h=>{if(!p)return;p.title=h.meta.title,p.emit("routeChange",{title:h.meta.title}),p.emit("routeUpdate",{title:h.meta.title});let w=document.querySelector(".app-view");!h.meta.preserveExplorer&&w&&(w.scrollTop=0)}),b.mount(e),{app:b,router:u,state:p}}document.querySelector("#app")&&(window.anonymousApp=aQ());})(); +`)})},Fp={props:["content","terms","options"],setup(e){let t=St(null),s=()=>{t.value.innerHTML=renderMD(e.content||"",window.location.pathname+"/../"),Lp(t.value),$p(t.value)};return mn(()=>{s(),ut(()=>[e.content,e.terms,e.options],s,{deep:!0})}),()=>Ae("markdown",{ref:t})}},GQ={props:["file","terms","options"],setup(e){let t=St(null),s=()=>tt(()=>{t.value?.querySelectorAll("pre code").forEach(i=>window.Prism?.highlightElement(i)),Lp(t.value),$p(t.value)});return mn(s),ut(()=>[e.file?.content,e.terms,e.options],s,{deep:!0}),()=>{let i=e.file||{},o=(i.filename||"").split(".").pop().toLowerCase();if(["md","markdown"].includes(o)||i.language==="Markdown")return Ae("gist-file",{ref:t},Ae(Fp,{content:i.content,terms:e.terms,options:e.options}));let r={js:"javascript",jsx:"javascript",ts:"javascript",typescript:"javascript",py:"python",html:"markup",xml:"markup",svg:"markup",sh:"bash"},d=(i.language||o||"none").toLowerCase();return Ae("gist-file",{ref:t},Ae("pre",{class:"line-numbers"},Ae("code",{class:"language-"+(r[d]||d),key:i.content},i.content||"")))}}},WQ=e=>e?.querySelectorAll(".nb-input pre").forEach(t=>{if(t.parentElement?.classList.contains("nb-code-scroll"))return;let s=document.createElement("div");s.className="nb-code-scroll",t.replaceWith(s),s.appendChild(t);let i=()=>{let o=t.scrollWidth-t.clientWidth>1;if(s.classList.toggle("is-overflowing",o),s.classList.toggle("is-at-end",o&&t.scrollLeft+t.clientWidth>=t.scrollWidth-2),!o)return;let r=t.clientWidth-16,d=Math.max(24,r*t.clientWidth/t.scrollWidth);s.style.setProperty("--thumb-w",d+"px"),s.style.setProperty("--thumb-x",(r-d)*t.scrollLeft/(t.scrollWidth-t.clientWidth)+"px")};t.addEventListener("scroll",i,{passive:!0}),window.ResizeObserver?new ResizeObserver(i).observe(t):i(),i()}),KQ={props:["file","content"],setup(e){let t=St(null),s=0,i,o=async()=>{let r=++s;i?.abort(),i=new AbortController;try{let d=e.content?JSON.parse(e.content):await fetch(e.file?.download_url||e.file,{signal:i.signal}).then(p=>{if(!p.ok)throw Error("Notebook request failed");return p.json()});if(await Jn("notebook"),r!==s)return;t.value.innerHTML=_o(DOMPurify.sanitize(nb.parse(d).render())),t.value.querySelectorAll("pre code").forEach(p=>window.Prism?.highlightElement(p)),WQ(t.value)}catch(d){r===s&&d.name!=="AbortError"&&(t.value.textContent="Unable to render the notebook.")}};return mn(()=>{o(),ut(()=>[e.file,e.content],o)}),is(()=>{s++,i?.abort()}),()=>Ae("notebook",{ref:t})}},YQ={props:["stats"],setup(e){return()=>{let t=Object.entries(e.stats||{}).filter(([,i])=>i.code),s=t.reduce((i,[,o])=>i+o.code,0);return Ae("loc",t.map(([i,o])=>Ae("div",{class:"lang",title:`${i}: ${o.code.toLocaleString()} lines`,style:{width:o.code*100/s+"%",background:langColors[i]}})))}}},Up={Markdown:Fp,GistFile:GQ,Notebook:KQ,Loc:YQ,HtmlDoc:Ip,QuotaUsage:HQ,Pdfviewer:id(async()=>(await Jn("pdf"),pdfjsLib.GlobalWorkerOptions.workerSrc="/script/external/pdf.worker.js",Mp))},Bp={async mounted(e,{value:t}){e._editorValue=t;try{if(await ni(),e._editorDisposed)return;let s=e._editorValue,i=ace.edit(e);e._editor=i,i.setValue(String(s.content??""),-1),_p(e,s.options),e._editorCleanup=s.options?.onLoad?.(i)}catch(s){e._editorDisposed||(e.textContent=s.message)}},updated(e,{value:t}){e._editorValue=t,e._editor&&(e._editor.getValue()!==String(t.content??"")&&e._editor.setValue(String(t.content??""),-1),_p(e,t.options))},beforeUnmount(e){e._editorDisposed=!0,e._editorCleanup?.(),e._editor?.destroy()}};function _p(e,t={}){let s=jQ.has(t.mode)?t.mode:"text";e._editor.session.setMode("ace/mode/"+s),t.theme&&e._editor.setTheme("ace/theme/"+t.theme),e._editor.setReadOnly(t.readOnly!==!1)}var zp={mounted(e){if(!window.IntersectionObserver)return;let t=[...e.querySelectorAll('a[href^="#"]')],s=new Set,i=new IntersectionObserver(o=>{o.forEach(d=>d.isIntersecting?s.add(d.target.id):s.delete(d.target.id));let r=t.find(d=>s.has(d.hash.slice(1)));r&&t.forEach(d=>d.classList.toggle("active",d===r))},{rootMargin:"-20% 0px -60% 0px",threshold:0});tt(()=>{t.forEach(o=>{let r=document.getElementById(o.hash.slice(1));r&&i.observe(r)}),t[0]&&!t.some(o=>o.classList.contains("active"))&&t[0].classList.add("active")}),e._observer=i},beforeUnmount(e){e._observer?.disconnect()}};function Hp(e){let t=[],s=0,i=/\bXXXX-(\d+)\b/g,o;for(;o=i.exec(e);)o.index>s&&t.push(e.slice(s,o.index)),t.push(Ae("span",{class:"redact-slot",role:"img","aria-label":"Redacted term "+o[1]},[Ae("i",null,o[1])])),s=o.index+o[0].length;return t.length?(s{s.push(r),d=1024&&iQQ(e.file)),p=()=>e.selectedPath??"/"+(Array.isArray(s.params.path)?s.params.path.join("/"):s.params.path||"");ut(()=>[s.params.repoId,s.params.path,e.selectedPath],()=>{let w="";p().split("/").filter(Boolean).forEach(N=>{w+="/"+N,o[w]=!0})},{immediate:!0});let u=Rt(()=>{if(!e.searchQuery||!e.searchResults)return null;let w=new Set,N=new Set;return e.searchResults.forEach(S=>{w.add(S.path?`${S.path}/${S.name}`:S.name);let R="";(S.path||"").split("/").filter(Boolean).forEach(v=>{R=R?R+"/"+v:v,N.add(R)})}),{files:w,folders:N}}),y=()=>[...i.value.querySelectorAll("li > a")],h=w=>{if(i.value.querySelector(".tree-focused")?.classList.remove("tree-focused"),!w)return;if(r=w.dataset.path,w.classList.add("tree-focused"),e.selectedPath===void 0){w.scrollIntoView?.({block:"nearest"}),i.value.focus();return}let N=i.value.scrollHeight>i.value.clientHeight?i.value:i.value.closest(".leftCol-body");if(N){let S=w.getBoundingClientRect(),R=N.getBoundingClientRect();S.topR.bottom&&(N.scrollTop+=S.bottom-R.bottom)}i.value.focus({preventScroll:!0})};function b(w){let N=y(),S=i.value.querySelector(".tree-focused")||N[0],R=N.indexOf(S);if(!["ArrowDown","ArrowUp","ArrowRight","ArrowLeft","Enter"].includes(w.key)||(w.preventDefault(),w.key==="ArrowDown"&&h(N[(R+1)%N.length]),w.key==="ArrowUp"&&h(N[(R-1+N.length)%N.length]),!S))return;let v=S.closest("li");w.key==="ArrowRight"&&v.classList.contains("folder")&&(v.classList.contains("open")?h(v.querySelector(":scope > ul > li > a")):S.click()),w.key==="ArrowLeft"&&(v.classList.contains("folder")&&v.classList.contains("open")?S.click():h(v.parentElement.closest("li.folder")?.querySelector(":scope > a"))),w.key==="Enter"&&S.click()}function m(w,N=""){let S=[...w].sort((R,v)=>+!!v.children-+!!R.children||R.name.localeCompare(v.name));return Ae("ul",S.flatMap(R=>{let v=R,E=v.name,D=(N+"/"+E).slice(1);if(u.value&&!u.value.files.has(D)&&!u.value.folders.has(D))return[];for(;v.children?.length===1&&v.children[0].children&&e.page?.loadedFolders?.[(N+"/"+E).slice(1)];)v=v.children[0],E+="/"+v.name;let V=N+"/"+E,_=!!v.children,z=u.value?o[V]!==!1:!!o[V],x=_&&e.page?.options?.truncatedFolders?.includes(V.slice(1)),X=Ae("span",{class:_?"tree-icon-folder":"far fa-file tree-icon-file","aria-hidden":"true"},_?Ae("svg",{viewBox:"0 0 14 12",focusable:"false"},Ae("path",{d:"M1.5 10.5v-9h4l1.5 2h5.5v7z"})):null),I=!1,U=E,C="",L="";if(E.length>80){let se=E.length-12;for(let Y=E.length-18;Y<=E.length-6;Y++)if(Y>0&&"-_. ".includes(E[Y])){se=Y;break}if(I=!/XXXX-\d+/.test(E.slice(Math.max(0,se-12))),U=E.slice(0,se).trimEnd(),C=E.slice(se).trimStart(),I){let Y=Math.max(8,30-C.length-1);if(U.length>Y&&!/XXXX-\d+/.test(U)){let me=-1;for(let Ue=Math.min(Y,U.length);Ue>=4;Ue--)if(".-_".includes(U[Ue])){me=Ue;break}let Se=E.slice(0,E.length-C.length);U=(me>0?U.slice(0,me):U.slice(0,Y)).trimEnd(),L=Se.slice(U.length)}}}let H=Ae("span",{class:{"tree-name":!0,"tree-name-split":I,"tree-name-wrap":!I},title:E.replace(/\bXXXX-(\d+)\b/g,"[redacted term $1]")},I?[Ae("span",{class:{"tree-name-head":!0,"is-cut":!!L}},Hp(U)),L?Ae("span",{class:"tree-name-middle"},L):null,Ae("span",{class:"tree-name-tail"},C)]:XQ(E)),K=se=>{if(h(se.currentTarget),!_){e.selectedPath!==void 0&&(se.preventDefault(),t("select",V));return}se.preventDefault(),o[V]=!z,o[V]&&!v.children.length&&e.page.getFiles(V.slice(1)),tt(()=>h(y().find(Y=>Y.dataset.path===r)))},ie=Ae("a",{"data-path":V,"aria-expanded":e.selectedPath!==void 0&&_?String(z):void 0,"aria-current":e.selectedPath!==void 0&&!_&&p()===V?"page":void 0,href:_?void 0:`/r/${encodeURIComponent(s.params.repoId)}${encodePathForUrl(V)}`,class:{"tree-focused":r===V},onClick:K},[_?Ae("span",{class:"tree-toggle"}):Ae("span",{class:"tree-spacer"}),X,H,x?Ae("span",{class:"truncated-warning",title:e.page.fmt.translate("WARNINGS.folder_truncated")},Ae("i",{class:"fas fa-exclamation-triangle"})):null]);return Ae("li",{key:V,class:{file:!0,folder:_,open:z,active:p()===V,truncated:x},title:_?"":`Size: ${JQ(v.size||0)}`},[ie,_&&z?v.children.length||!e.page?.loadedFolders?.[V.slice(1)]?m(v.children,V):Ae("ul",Ae("li",{class:"tree-empty"},"Empty folder")):null])}))}return()=>Ae("tree",{ref:i,tabindex:0,onKeydown:b},e.file?.length?u.value?.files.size===0?Ae("div",{class:"tree-search-empty"},"No files found"):m(d.value):"Empty repository")}};function Wp(){return st({errors:{},dirty:!1,touched:!1,submitted:!1,get invalid(){return Object.values(this.errors).some(Boolean)},setValidity(e,t){this.errors[e]=!t},setDirty(){this.dirty=!0}})}function Kp(e,t){if(!e[t]){let s=Wp();Object.defineProperty(s,"invalid",{get(){return Object.values(s.errors).some(Boolean)||Object.keys(s).some(i=>i!=="invalid"&&s[i]&&typeof s[i]=="object"&&s[i].invalid)}}),e[t]=s}return e[t]}var Yp={beforeMount(e,{value:t}){e._formState=Kp(t,e.name),e.addEventListener("submit",s=>s.preventDefault())}};function ZQ(e){return e instanceof Date?isNaN(e)?"":`${e.getFullYear()}-${String(e.getMonth()+1).padStart(2,"0")}-${String(e.getDate()).padStart(2,"0")}`:e||""}function Gp(e){let t=e._field.binding.value;e.type==="checkbox"?e.checked=!!t:e.type==="radio"?e.checked=t==(e._value??e.value):e._field.timer||(e.value=e.type==="date"?ZQ(t):t??""),Xa(e)}function Xa(e){let t=e._field.validation;if(!t)return;let s=e.validity;for(let[i,o]of Object.entries({required:s.valueMissing,pattern:s.patternMismatch,min:s.rangeUnderflow,max:s.rangeOverflow,date:s.badInput,email:s.typeMismatch&&e.type==="email",url:s.typeMismatch&&e.type==="url"}))t.setValidity(i,e.disabled||!o)}var Xp={beforeMount(e,{value:t}){var d;let s=t.form&&Kp(t.state,t.form),i=s&&e.name?s[d=e.name]||(s[d]=Wp()):null;e._field={binding:t,validation:i,timer:null};let o=()=>{clearTimeout(e._field.timer),e._field.timer=null;let p=e._field.binding,u=e.type==="checkbox"?e.checked:e._value??e.value;if(!(e.type==="radio"&&!e.checked)){if((e.type==="number"||e.type==="range")&&(u=e.value===""?null:Number(e.value)),e.type==="date"&&(u=e.value?new Date(e.value+"T00:00:00"):null),i){i.setDirty();for(let y of Object.keys(i.errors))i.setValidity(y,!0)}p.set(u),Xa(e),p.change?.()}};e._field.commit=o;let r=p=>{let u=e._field.binding.options?.debounce||0,y=typeof u=="number"?u:u[p.type]??u.default??0;clearTimeout(e._field.timer),y?e._field.timer=setTimeout(o,y):o()};e.addEventListener(e.tagName==="SELECT"||["checkbox","radio","date"].includes(e.type)?"change":"input",r),e.addEventListener("blur",()=>{i&&(i.touched=!0),e._field.timer&&o()})},mounted:Gp,updated(e,{value:t}){e._field.binding=t,Gp(e)},beforeUnmount(e){clearTimeout(e._field.timer);let{binding:t,validation:s}=e._field,i=t.form&&t.state[t.form];i&&i[e.name]===s&&delete i[e.name]}};function Jp(e,t){let s=e.target.closest("form");if(s?._formState&&(s._formState.submitted=!0),s?.querySelectorAll("input, select, textarea").forEach(i=>{i._field?.timer&&i._field.commit(),i._field&&Xa(i)}),s&&!s.checkValidity()){let i=s.querySelector("input:invalid, select:invalid, textarea:invalid");i?.scrollIntoView?.({block:"center"}),i?.focus(),s.reportValidity();return}return t()}var Qp=Symbol("session"),xQ=/^\/(w|api|github)(\/|$)/;function Zp(e,t={}){let s=e?.split(".").reduce((i,o)=>i?.[o],Kn);return s==null&&e?.startsWith("ERRORS.")&&(s=Kn.ERRORS.unknown_error),String(s??e??"").replace(/{{\s*([^}]+?)\s*}}/g,(i,o)=>t[o]??"")}var eZ={...wa,translate:Zp};function tZ(e){if(e==null||e==="")return e;try{let t=new URL(e,window.location.href);return["http:","https:","mailto:","tel:","blob:"].includes(t.protocol)?e:void 0}catch{return}}function nZ(e="#app",t={}){let s=!!document.querySelector('meta[name="review-consent-page"][content="1"]'),i=s&&window.location.pathname==="/review-link"?sl(window):null,o=()=>{let m=i;return i=null,m};!t.history&&window.location.pathname==="/"&&/^#!\/r\/[^/?#]+/.test(window.location.hash)&&window.history.replaceState(window.history.state,"",window.location.hash.slice(2));let r=new Map,d=Ap(t.fetch),p,u;function y(){let m=Ct(),w={url(S){return S===void 0?u.currentRoute.value.fullPath:(u.push(S),w)},replace(S){return u.replace(S)},path(){return u.currentRoute.value.path},search(){return u.currentRoute.value.query}},N=new Proxy({},{get(S,R){let v=u.currentRoute.value.params[R];return Array.isArray(v)?v.join("/"):v}});return{takeReviewHandoff:o,http:d,...m,location:w,params:N,window,promises:Tp,html:{trustAsHtml:S=>S},translate:(S,R)=>Promise.resolve(Zp(S,R)),quotaService:Op(d)}}function h(m){return{name:m.template,setup(){let w=qo(Mt(Qp),r);m.setup(w,y()),Dp(m.template,w);let N=[];return()=>ur[m.template](w,N)}}}u=Mu({history:t.history||Tu(),routes:Yc.map(m=>m.redirect?m:{path:m.path,component:h(m),meta:{title:m.title,preserveExplorer:m.preserveExplorer}})});let b=Qd({setup(){p=qo(null,r),p.fmt=eZ,p.window=window,p.Math=Math,p.sanitize=S=>DOMPurify.sanitize(S??""),p.highlightRedactions=S=>(p.site_options,Mc(S)),p.submitForm=Jp,p.safeUrl=tZ;let m=y();Vc(p,m.http,m.location,m.timeout),os(Qp,p),ut(()=>p.title,S=>{document.title=S||"Anonymous GitHub"});let w=[],N=S=>{let R=S.target.closest?.("a[href]");if(S.defaultPrevented||S.button!==0||S.metaKey||S.ctrlKey||S.shiftKey||S.altKey||!R||R.hasAttribute("download")||R.target&&R.target!=="_self"||R.dataset.toggle||R.getAttribute("href").startsWith("#"))return;let E=new URL(R.href,window.location.href);s||/^\/review-link\/?$/i.test(E.pathname)||E.origin!==window.location.origin||xQ.test(E.pathname)||(S.preventDefault(),u.push(E.pathname+E.search+E.hash),$("#navbarSupportedContent.show").collapse("hide"))};return document.addEventListener("click",N),is(()=>document.removeEventListener("click",N)),()=>[Pp(p,[]),s||/^\/(r|repository)\//.test(p.path||"")?null:Ae("header",{class:["app-header",{"is-contained":p.path==="/"||p.path==="/faq","is-signin":p.path==="/signin"}]},ur["partials/header.htm"](p,w)),Ae("main",{class:"app-view align-items-stretch w-100"},Ae(ma,null,{default:({Component:S,route:R})=>S?Ae(S,{key:R.meta.preserveExplorer?R.matched[0]?.path:R.path}):null})),Ae("div",{class:"position-fixed p-3",style:{zIndex:999999999,right:0,bottom:0}},p.toasts.map((S,R)=>Ae("div",{class:"toast show",role:"alert","aria-live":"assertive","aria-atomic":"true",key:R},[Ae("div",{class:"toast-header"},[Ae("strong",{class:"mr-auto"},S.title),Ae("button",{type:"button",class:"ml-2 mb-1 close","aria-label":"Close",onClick:()=>p.removeToast(S)},"\xD7")]),Ae("div",{class:"toast-body"},S.body)])))]}});for(let[m,w]of Object.entries(Up))b.component(m,w);return b.component("Tree",jp),b.component("PartialView",{props:["name","state"],setup(m){let w=[];return()=>ur[m.name](m.state,w)}}),b.directive("field",Xp),b.directive("form",Yp),b.directive("code-editor",Bp),b.directive("paper-scrollspy",zp),b.use(u),u.beforeEach(async m=>{if(m.path==="/review-link"&&!s||s&&m.path!=="/review-link")return window.location.assign(m.fullPath),!1;p?.emit("routeLeave"),/^\/(r|repository|anonymize|pull-request-anonymize|gist-anonymize|pr|gist)(\/|$)/.test(m.path)&&await Jn("markdown"),/^\/(r|repository|anonymize|pull-request-anonymize|gist-anonymize|pr|gist)(\/|$)/.test(m.path)&&await Jn("org")}),u.afterEach(m=>{if(!p)return;p.title=m.meta.title,p.emit("routeChange",{title:m.meta.title}),p.emit("routeUpdate",{title:m.meta.title});let w=document.querySelector(".app-view");!m.meta.preserveExplorer&&w&&(w.scrollTop=0)}),b.mount(e),{app:b,router:u,state:p}}document.querySelector("#app")&&(window.anonymousApp=nZ());})(); /*! Bundled license information: @vue/shared/dist/shared.esm-bundler.js: diff --git a/scripts/dev-mock.js b/scripts/dev-mock.js index ac792a4..e88422b 100644 --- a/scripts/dev-mock.js +++ b/scripts/dev-mock.js @@ -1001,21 +1001,62 @@ const emailHistory = Array.from({ length: 64 }, (_, index) => { return { _id: `00000000-0000-4000-8000-${String(index).padStart(12, "0")}`, kind: index % 2 ? "owner-access" : "repository-expiration", recipient: index ? `author${index}@example.com` : "research-team-with-a-long-address@example.com", - resourceKind: "repository", resourceId: oid(800 + index), + ownerId: oid(100 + index), resourceKind: "repository", resourceId: oid(800 + index), createdAt: ago(index / 24), completedAt: state === "sending" ? null : ago(index / 24), state, httpStatus: state === "accepted" ? 200 : state === "rejected" ? 429 : null }; }); -app.get("/api/admin/emails", (req, res) => { - const cookie = req.headers.cookie || ""; - if (/mock_emails_error=1/.test(cookie)) return res.status(503).json({ error: "Simulated history outage" }); - let rows = /mock_emails_empty=1/.test(cookie) ? [] : emailHistory; - rows = rows.filter(row => (!req.query.state || row.state === req.query.state) && (!req.query.kind || row.kind === req.query.kind)); - if (req.query.before) { - const [date, id] = String(req.query.before).split("|"); - rows = rows.filter(row => row.createdAt < date || (row.createdAt === date && row._id < id)); +function emailPeriod(query) { + const period = query.period === undefined ? "all" : query.period; + if (typeof period !== "string" || !["7d", "30d", "90d", "all"].includes(period)) throw Error("Invalid period"); + const chartDays = period === "all" ? 30 : parseInt(period, 10), now = new Date(); + const start = new Date(Date.UTC(now.getUTCFullYear(), now.getUTCMonth(), now.getUTCDate() - chartDays + 1)); + return { period, chartDays, start }; +} +function emailFilteredRows(req, summary = false) { + const period = emailPeriod(req.query); + const search = req.query.search; + if (search !== undefined && (typeof search !== "string" || search.length > 200)) throw Error("Invalid search"); + if (req.query.kind && !["repository-expiration", "owner-access"].includes(req.query.kind)) throw Error("Invalid type"); + if (!summary && req.query.state && !["accepted", "rejected", "unknown", "sending"].includes(req.query.state)) throw Error("Invalid status"); + const needle = (search || "").trim(); + let rows = /mock_emails_empty=1/.test(req.headers.cookie || "") ? [] : emailHistory; + rows = rows.filter(row => (summary || !req.query.state || row.state === req.query.state) + && (!req.query.kind || row.kind === req.query.kind) + && (period.period === "all" || row.createdAt >= period.start.toISOString()) + && (!needle || row.recipient.toLowerCase().includes(needle.toLowerCase()) || [row._id, row.ownerId, row.resourceId].includes(needle))); + if (!summary && req.query.before) { + if (typeof req.query.before !== "string" || req.query.before.length > 200) throw Error("Invalid cursor"); + const [date, id, extra] = req.query.before.split("|"); + if (extra || !id || !/^[0-9a-f-]{36}$/.test(id) || !Number.isFinite(new Date(date).getTime())) throw Error("Invalid cursor"); + const timestamp = new Date(date).toISOString(); + rows = rows.filter(row => row.createdAt < timestamp || (row.createdAt === timestamp && row._id < id)); } - const entries = rows.slice(0, 50), last = entries.at(-1); - res.json({ entries, nextCursor: rows.length > 50 ? `${last.createdAt}|${last._id}` : null }); + return { rows, ...period }; +} +app.get("/api/admin/emails/summary", (req, res) => { + res.set("Cache-Control", "no-store"); + if (/mock_emails_error=1/.test(req.headers.cookie || "")) return res.status(503).json({ error: "Simulated history outage" }); + try { + const { rows, period, chartDays, start } = emailFilteredRows(req, true); + const empty = () => ({ accepted: 0, rejected: 0, unknown: 0, sending: 0 }); + const counts = empty(); + const series = Array.from({ length: chartDays }, (_, index) => ({ date: new Date(start.getTime() + index * 86400000).toISOString().slice(0, 10), ...empty() })); + for (const row of rows) { + counts[row.state]++; + const day = series.find(point => point.date === row.createdAt.slice(0, 10)); + if (day) day[row.state]++; + } + res.json({ counts, total: rows.length, series, chartDays, period }); + } catch { res.status(400).json({ error: "Invalid email history filters." }); } +}); +app.get("/api/admin/emails", (req, res) => { + res.set("Cache-Control", "no-store"); + if (/mock_emails_error=1/.test(req.headers.cookie || "")) return res.status(503).json({ error: "Simulated history outage" }); + try { + const { rows } = emailFilteredRows(req); + const entries = rows.slice(0, 50), last = entries.at(-1); + res.json({ entries, nextCursor: rows.length > 50 ? `${last.createdAt}|${last._id}` : null }); + } catch { res.status(400).json({ error: "Invalid email history filters." }); } }); app.get("/api/admin/errors", (req, res) => { const offset = Math.max(0, parseInt(req.query.offset, 10) || 0); diff --git a/src/server/routes/admin-emails.ts b/src/server/routes/admin-emails.ts index 6696bef..de13dd2 100644 --- a/src/server/routes/admin-emails.ts +++ b/src/server/routes/admin-emails.ts @@ -3,7 +3,16 @@ import { mongo } from "mongoose"; import { EmailHistoryRecord, emailHistoryCollection, ensureEmailHistoryIndexes } from "../../core/email-history"; const router = Router(); -export function emailHistoryQuery(query: Record) { +const QUERY_TIMEOUT_MS = 5000; +const emptyCounts = () => ({ accepted: 0, rejected: 0, unknown: 0, sending: 0 }); +export function emailHistoryPeriod(period: unknown, now = new Date()) { + if (period !== undefined && (typeof period !== "string" || !["7d", "30d", "90d", "all"].includes(period))) throw new Error("Invalid period"); + const selected = (period || "all") as string; + const chartDays = selected === "all" ? 30 : parseInt(selected, 10); + const start = new Date(Date.UTC(now.getUTCFullYear(), now.getUTCMonth(), now.getUTCDate() - chartDays + 1)); + return { period: selected, chartDays, start }; +} +export function emailHistoryQuery(query: Record, now = new Date()) { const filter: mongo.Filter = {}; if (query.state) { if (typeof query.state !== "string" || !["sending", "accepted", "rejected", "unknown"].includes(String(query.state))) throw new Error("Invalid status"); @@ -13,16 +22,67 @@ export function emailHistoryQuery(query: Record) { if (typeof query.kind !== "string" || !["repository-expiration", "owner-access"].includes(String(query.kind))) throw new Error("Invalid email type"); filter.kind = query.kind as EmailHistoryRecord["kind"]; } + const period = emailHistoryPeriod(query.period, now); + if (period.period !== "all") filter.createdAt = { $gte: period.start }; + if (query.search !== undefined) { + if (typeof query.search !== "string" || query.search.length > 200) throw new Error("Invalid search"); + const search = query.search.trim(); + if (search) filter.$or = [ + { recipient: { $regex: search.replace(/[.*+?^${}()|[\]\\]/g, "\\$&"), $options: "i" } }, + { _id: search }, { ownerId: search }, { resourceId: search }, + ]; + } if (query.before) { if (typeof query.before !== "string" || query.before.length > 200) throw new Error("Invalid cursor"); const [date, id, extra] = query.before.split("|"); const time = new Date(date); if (extra || !id || !/^[0-9a-f-]{36}$/.test(id) || !Number.isFinite(time.getTime())) throw new Error("Invalid cursor"); - filter.$or = [{ createdAt: { $lt: time } }, { createdAt: time, _id: { $lt: id } }]; + const cursor = [{ createdAt: { $lt: time } }, { createdAt: time, _id: { $lt: id } }]; + if (filter.$or) filter.$and = [{ $or: cursor }]; + else filter.$or = cursor; } return filter; } +export function emailHistorySummary( + countsRows: Array<{ _id: string; count: number }>, + dailyRows: Array<{ _id: { date: string; state: string }; count: number }>, + period: ReturnType, +) { + const counts = emptyCounts(); + for (const row of countsRows) if (Object.hasOwn(counts, row._id)) counts[row._id as keyof typeof counts] = row.count; + const series = Array.from({ length: period.chartDays }, (_, index) => ({ + date: new Date(period.start.getTime() + index * 86400000).toISOString().slice(0, 10), ...emptyCounts(), + })); + for (const row of dailyRows) { + const day = series.find(point => point.date === row._id.date); + if (day && Object.hasOwn(counts, row._id.state)) day[row._id.state as keyof typeof counts] = row.count; + } + return { counts, total: Object.values(counts).reduce((sum, count) => sum + count, 0), series, chartDays: period.chartDays, period: period.period }; +} // Mounted after the shared authentication and administrator checks. +router.get("/summary", async (req, res) => { + res.set("Cache-Control", "no-store"); + let filter: mongo.Filter, period: ReturnType; + try { + const now = new Date(); + filter = emailHistoryQuery({ period: req.query.period, search: req.query.search, kind: req.query.kind }, now); + period = emailHistoryPeriod(req.query.period, now); + } catch { res.status(400).json({ error: "Invalid email history filters." }); return; } + try { + await ensureEmailHistoryIndexes(); + const [result] = await emailHistoryCollection().aggregate([ + { $match: filter }, + { $facet: { + counts: [{ $group: { _id: "$state", count: { $sum: 1 } } }], + daily: [ + { $match: { createdAt: { $gte: period.start } } }, + { $group: { _id: { date: { $dateToString: { format: "%Y-%m-%d", date: "$createdAt", timezone: "UTC" } }, state: "$state" }, count: { $sum: 1 } } }, + ], + } }, + ], { maxTimeMS: QUERY_TIMEOUT_MS }).toArray(); + res.json(emailHistorySummary(result?.counts || [], result?.daily || [], period)); + } catch { res.status(503).json({ error: "Email history summary is unavailable. Try again." }); } +}); router.get("/", async (req, res) => { res.set("Cache-Control", "no-store"); let filter: mongo.Filter; @@ -30,7 +90,7 @@ router.get("/", async (req, res) => { catch { res.status(400).json({ error: "Invalid email history filters." }); return; } try { await ensureEmailHistoryIndexes(); - const rows = await emailHistoryCollection().find(filter, { projection: { + const rows = await emailHistoryCollection().find(filter, { maxTimeMS: QUERY_TIMEOUT_MS, projection: { _id: 1, kind: 1, recipient: 1, ownerId: 1, resourceId: 1, resourceKind: 1, createdAt: 1, completedAt: 1, state: 1, httpStatus: 1, } }).sort({ createdAt: -1, _id: -1 }).limit(51).toArray(); diff --git a/test/email-admin-ui.test.js b/test/email-admin-ui.test.js index 7518627..02301eb 100644 --- a/test/email-admin-ui.test.js +++ b/test/email-admin-ui.test.js @@ -1,3 +1,4 @@ +const { URL, URLSearchParams } = require("node:url"); const { expect } = require("chai"); const fs = require("node:fs"); const vm = require("node:vm"); @@ -7,11 +8,11 @@ const sandbox = { console, Date, Intl }; vm.runInNewContext(script, sandbox); const tick = () => new Promise(resolve => require("node:timers").setImmediate(resolve)); describe("email admin UI requests", () => { - let state, pending; + let state, pending, summaries, dispose; beforeEach(() => { - pending = []; - state = { user: {}, on() {} }; - sandbox.controller(state, { get: (url, options) => new Promise((resolve, reject) => pending.push({ url, options, resolve, reject })) }, { url() {} }); + pending = []; summaries = []; + state = { user: {}, on(event, callback) { if (event === "dispose") dispose = callback; } }; + sandbox.controller(state, { get: (url, options) => new Promise((resolve, reject) => (url.endsWith("/summary") ? summaries : pending).push({ url, options, resolve, reject })) }, { url() {} }); }); const response = (entries, nextCursor = null) => ({ data: { entries, nextCursor } }); it("keeps visible history when a refresh fails", async () => { @@ -44,6 +45,113 @@ describe("email admin UI requests", () => { state.emailKind = "owner-access"; expect(state.hasEmailFilters()).to.equal(true); const clear = state.clearEmailFilters(); expect(state.hasEmailFilters()).to.equal(false); - pending[1].resolve(response([])); await clear; + pending[1].resolve(response([])); summaries[1].resolve({ data: { counts: {}, total: 0, series: [] } }); await clear; }); + it("loads bounded pages and fetches older history only at the loaded boundary", async () => { + pending[0].resolve(response(Array.from({ length: 50 }, (_, i) => ({ _id: String(i) })), "older")); await tick(); + expect(state.emailVisibleRows()).to.have.length(25); + await state.emailNextPage(); expect(state.emailPage).to.equal(2); expect(pending).to.have.length(1); + const next = state.emailNextPage(); + expect(pending[1].options.params.before).to.equal("older"); + pending[1].resolve(response([{ _id: "50" }])); await next; + expect(state.emailPage).to.equal(3); expect(state.emailVisibleRows()[0]._id).to.equal("50"); + state.emailPreviousPage(); expect(state.emailVisibleRows()).to.have.length(25); + }); + it("does not turn unavailable summary data into zero counts", async () => { + summaries[0].reject(Error("offline")); await tick(); + expect(state.emailTotal()).to.equal(null); expect(state.emailPageCount()).to.equal(null); + expect(state.emailSummaryError).not.to.equal(""); + }); + it("ignores stale summary responses and applies search only on submit", async () => { + state.emailSearch = " author@example.com "; + expect(pending[0].options.params.search).to.equal(undefined); + const current = state.applyEmailFilters(); + expect(pending[1].options.params.search).to.equal("author@example.com"); + expect(summaries[1].options.params.state).to.equal(undefined); + pending[1].resolve(response([])); summaries[1].resolve({ data: { counts: { rejected: 3 }, total: 3, series: [] } }); await current; + summaries[0].resolve({ data: { counts: {}, total: 99, series: [] } }); await tick(); + expect(state.emailTotal()).to.equal(3); + const status = state.setEmailStatus("rejected"); expect(summaries).to.have.length(2); + pending[2].resolve(response([])); await status; expect(state.emailTotal()).to.equal(3); + }); + it("ignores responses after disposal", async () => { + dispose(); pending[0].resolve(response([{ _id: "late" }])); + summaries[0].resolve({ data: { total: 99 } }); await tick(); + expect(state.emailRows).to.have.length(0); expect(state.emailSummary).to.equal(null); + }); + it("retains summary totals and the current page when requests fail", async () => { + pending[0].resolve(response(Array.from({ length: 25 }, (_, i) => ({ _id: String(i) })), "older")); + summaries[0].resolve({ data: { counts: { accepted: 30 }, total: 30, series: [] } }); await tick(); + const next = state.emailNextPage(); pending[1].reject(Error("offline")); await next; + expect(state.emailPage).to.equal(1); expect(state.emailVisibleRows()).to.have.length(25); + const summary = state.loadEmailSummary(); summaries[1].reject(Error("offline")); await summary; + expect(state.emailTotal()).to.equal(30); expect(state.emailSummaryError).to.include("Previously loaded"); + }); + it("restores valid URL filters and preserves unrelated URL state", async () => { + let saved; + const local = { console, Date, Intl, URL, URLSearchParams, window: { + location: { search: "?state=rejected&period=30d&search=author%40example.com&other=keep", href: "http://localhost/admin/emails?state=rejected&period=30d&search=author%40example.com&other=keep#history" }, + history: { replaceState(a, b, value) { saved = value; } }, + } }; + vm.runInNewContext(script, local); + const restored = { user: {}, on() {} }; + local.controller(restored, { get: () => new Promise(() => {}) }, { url() {} }); + expect(restored.emailState).to.equal("rejected"); expect(restored.emailPeriod).to.equal("30d"); + expect(restored.emailSearch).to.equal("author@example.com"); + expect(saved).to.include("other=keep"); expect(saved).to.include("#history"); + }); + it("advances to the intended page after retrying a failed Next", async () => { + pending[0].resolve(response(Array.from({ length: 25 }, (_, i) => ({ _id: String(i) })), "older")); await tick(); + const next = state.emailNextPage(); pending[1].reject(Error("offline")); await next; + expect(state.emailPage).to.equal(1); + const retry = state.retryEmails(); pending[2].resolve(response([{ _id: "next" }])); await retry; + expect(state.emailPage).to.equal(2); expect(state.emailVisibleRows()[0]._id).to.equal("next"); + expect(state.emailAnnouncement).to.equal("Page 2. Showing attempts 26 to 26."); + state.emailPreviousPage(); expect(state.emailAnnouncement).to.equal("Page 1. Showing attempts 1 to 25."); + await state.emailNextPage(); expect(state.emailAnnouncement).to.equal("Page 2. Showing attempts 26 to 26."); + }); + it("resets a failed page target on filter changes", async () => { + pending[0].resolve(response(Array.from({ length: 25 }, (_, i) => ({ _id: String(i) })), "older")); await tick(); + const next = state.emailNextPage(); pending[1].reject(Error("offline")); await next; + const filtered = state.setEmailStatus("rejected"); pending[2].resolve(response([{ _id: "filtered" }], "filteredOlder")); await filtered; + const more = state.loadEmails(true); pending[3].resolve(response(Array.from({ length: 25 }, (_, i) => ({ _id: "extra" + i })))); await more; + expect(state.emailPage).to.equal(1); + }); + it("handles empty chart date endpoints", () => { + expect(state.emailDayLabel(undefined)).to.equal(""); expect(state.emailDayLabel({})).to.equal(""); + expect(state.emailDayLabel({ date: "not-a-date" })).to.equal(""); + expect(state.emailDayLabel({ date: "2026-11-14" })).not.to.equal(""); + }); + it("focuses and scrolls the history heading only on explicit paging", async () => { + let focused = 0, scrolled = 0; + const heading = { setAttribute(key, value) { expect([key, value]).to.deep.equal(["tabindex", "-1"]); }, focus(options) { expect(options.preventScroll).to.equal(true); focused++; }, scrollIntoView() { scrolled++; } }; + const local = { console, Date, Intl, URL, URLSearchParams, window: { + location: { search: "", href: "http://localhost/admin/emails" }, history: { replaceState() {} }, + document: { querySelector(selector) { return selector === "#email-history-title" ? heading : null; } }, + } }; + vm.runInNewContext(script, local); + const view = { user: {}, on() {} }; + local.controller(view, { get: url => Promise.resolve(url.endsWith("/summary") ? { data: { counts: {}, total: 50, series: [] } } : response(Array.from({ length: 50 }, (_, i) => ({ _id: String(i) })))) }, { url() {} }); + await tick(); expect(focused).to.equal(0); + await view.emailNextPage(); expect(focused).to.equal(1); expect(scrolled).to.equal(1); + await view.refreshEmails(); expect(focused).to.equal(1); + }); + it("shows years for older dates and all-time history", () => { + const currentYear = new Date().getFullYear(); + expect(state.emailShortTime(`${currentYear - 1}-06-01T12:00:00Z`)).to.include(String(currentYear - 1)); + state.emailPeriod = "all"; + expect(state.emailShortTime(`${currentYear}-06-01T12:00:00Z`)).to.include(String(currentYear)); + }); + it("explains outcomes without inventing delivery evidence", () => { + expect(state.emailExplanation({ state: "accepted" })).to.include("not confirmed"); + expect(state.emailExplanation({ state: "rejected", httpStatus: 429 })).to.include("rate limiting"); + expect(state.emailExplanation({ state: "unknown" })).to.include("avoid duplicates"); + }); + it("uses displayed chart activity independently of all-time totals", () => { + state.emailSummary = {total: 100, series: [{date: "2026-11-14", accepted: 0, rejected: 0, unknown: 0, sending: 0}]}; + expect(state.emailChartTotal()).to.equal(0); + state.emailSummary.series[0].unknown = 3; + expect(state.emailChartTotal()).to.equal(3); + }); + }); diff --git a/test/email-history.test.js b/test/email-history.test.js index e89424d..f45095c 100644 --- a/test/email-history.test.js +++ b/test/email-history.test.js @@ -4,7 +4,7 @@ require("ts-node/register/transpile-only"); const Users = require("../src/core/model/users/users.model").default; const history = require("../src/core/email-history"); const admin = require("../src/server/routes/admin").default; -const { emailHistoryQuery } = require("../src/server/routes/admin-emails"); +const { emailHistoryQuery, emailHistoryPeriod, emailHistorySummary } = require("../src/server/routes/admin-emails"); describe("email delivery history", () => { const restores = []; @@ -65,12 +65,13 @@ describe("email delivery history", () => { const router = require("../src/server/routes/admin-emails").default; const handler = router.stack.find(layer => layer.route?.path === "/").route.stack[0].handle; const records = Array.from({ length: 51 }, (_, index) => ({ _id: String(index), createdAt: new Date("2026-01-01"), state: "accepted" })); - let limit, filter, sort, result, cache; - stub(history, "emailHistoryCollection", () => ({ find: query => { - filter = query; + let limit, filter, sort, result, cache, options; + stub(history, "emailHistoryCollection", () => ({ find: (query, value) => { + filter = query; options = value; return { sort: value => { sort = value; return { limit: count => { limit = count; return { toArray: async () => records }; } }; } }; } })); await handler({ query: { state: "accepted" } }, { set: (key, value) => { cache = [key, value]; }, json: value => { result = value; } }); + expect(options.maxTimeMS).to.equal(5000); expect(limit).to.equal(51); expect(sort).to.deep.equal({ createdAt: -1, _id: -1 }); expect(filter).to.deep.equal({ state: "accepted" }); expect(result.entries).to.have.length(50); @@ -88,6 +89,75 @@ describe("email delivery history", () => { await handler({ query: {} }, res); expect(code).to.equal(503); expect(body.error).not.to.include("private"); }); + it("uses UTC calendar periods and rejects malformed period or search input", () => { + const now = new Date("2026-11-14T23:59:00.000Z"); + expect(emailHistoryPeriod("7d", now)).to.deep.equal({ period: "7d", chartDays: 7, start: new Date("2026-11-08T00:00:00.000Z") }); + expect(emailHistoryQuery({ period: "30d" }, now).createdAt.$gte.toISOString()).to.equal("2026-10-16T00:00:00.000Z"); + expect(emailHistoryQuery({ period: "all" }, now)).to.deep.equal({}); + expect(emailHistoryQuery({}, now)).to.deep.equal({}); + for (const query of [{ period: "1d" }, { period: [] }, { period: "" }, { search: [] }, { search: { $ne: "" } }, { search: "a".repeat(201) }]) { + expect(() => emailHistoryQuery(query)).to.throw(); + } + }); + it("searches literal recipient text and exact IDs without losing the cursor or period", () => { + const now = new Date("2026-11-14T12:00:00.000Z"); + const before = "2026-11-12T12:00:00.000Z|aaaaaaaa-aaaa-aaaa-aaaa-aaaaaaaaaaaa"; + const query = emailHistoryQuery({ search: " a+b.[test]@example.com ", before, period: "7d" }, now); + const regex = new RegExp(query.$or[0].recipient.$regex, query.$or[0].recipient.$options); + expect(regex.test("A+B.[test]@example.com")).to.equal(true); + expect(regex.test("abxt@example.com")).to.equal(false); + expect(query.$or.slice(1)).to.deep.equal([{ _id: "a+b.[test]@example.com" }, { ownerId: "a+b.[test]@example.com" }, { resourceId: "a+b.[test]@example.com" }]); + expect(query.$and[0].$or).to.have.length(2); + expect(query.createdAt.$gte.toISOString()).to.equal("2026-11-08T00:00:00.000Z"); + expect(emailHistoryQuery({ search: " " })).to.deep.equal({}); + }); + it("zero fills UTC daily series and keeps all-time totals independent of the chart", () => { + const period = emailHistoryPeriod("all", new Date("2026-11-14T12:00:00.000Z")); + const result = emailHistorySummary([{ _id: "accepted", count: 75 }, { _id: "unknown", count: 3 }], [ + { _id: { date: "2026-11-14", state: "accepted" }, count: 2 }, + { _id: { date: "2025-01-01", state: "accepted" }, count: 50 }, + ], period); + expect(result.total).to.equal(78); + expect(result.counts).to.deep.equal({ accepted: 75, rejected: 0, unknown: 3, sending: 0 }); + expect(result.series).to.have.length(30); + expect(result.series[0]).to.deep.equal({ date: "2026-10-16", accepted: 0, rejected: 0, unknown: 0, sending: 0 }); + expect(result.series.at(-1).accepted).to.equal(2); + expect(result.chartDays).to.equal(30); + expect(result.period).to.equal("all"); + }); + it("aggregates the whole filtered dataset independently of state and cursor with bounded database time", async () => { + const router = require("../src/server/routes/admin-emails").default; + const handler = router.stack.find(layer => layer.route?.path === "/summary").route.stack[0].handle; + let pipeline, options, result, cache; + stub(history, "emailHistoryCollection", () => ({ aggregate: (stages, opts) => { + pipeline = stages; options = opts; + return { toArray: async () => [{ counts: [{ _id: "accepted", count: 120 }, { _id: "rejected", count: 8 }], daily: [] }] }; + } })); + await handler({ query: { state: "rejected", before: "ignored", period: "7d", kind: "owner-access", search: "research" } }, { + set: (key, value) => { cache = [key, value]; }, json: value => { result = value; }, + }); + expect(pipeline[0].$match).not.to.have.property("state"); + expect(pipeline[0].$match).not.to.have.property("$and"); + expect(pipeline[0].$match.kind).to.equal("owner-access"); + expect(pipeline[0].$match.$or[0].recipient.$regex).to.equal("research"); + expect(pipeline[1].$facet.daily[1].$group._id.date.$dateToString.timezone).to.equal("UTC"); + expect(options.maxTimeMS).to.equal(5000); + expect(result.total).to.equal(128); + expect(result.series).to.have.length(7); + expect(cache).to.deep.equal(["Cache-Control", "no-store"]); + }); + it("reports invalid summary filters and aggregate failures without exposing database errors", async () => { + const router = require("../src/server/routes/admin-emails").default; + const handler = router.stack.find(layer => layer.route?.path === "/summary").route.stack[0].handle; + let code, body; + const res = { set() {}, status(value) { code = value; return this; }, json(value) { body = value; } }; + await handler({ query: { period: "wrong" } }, res); + expect(code).to.equal(400); + stub(history, "emailHistoryCollection", () => ({ aggregate: () => ({ toArray: async () => { throw Error("private timeout info"); } }) })); + await handler({ query: {} }, res); + expect(code).to.equal(503); + expect(body.error).not.to.include("private"); + }); it("mounts history behind authentication and administrator checks", () => { const emails = require("../src/server/routes/admin-emails").default; const index = admin.stack.findIndex(layer => layer.handle === emails);