From 6eeeb3346e675f16e10eba4b643efd04f3ec3842 Mon Sep 17 00:00:00 2001
From: ckerr <70381+ckerr@users.noreply.github.com>
Date: Sun, 3 Nov 2024 22:50:48 +0000
Subject: [PATCH] chore: update generated transmission-web files
---
web/package.json.buildonly | 1 +
web/public_html/transmission-app.css | 2 +-
web/public_html/transmission-app.css.map | 4 ++--
web/public_html/transmission-app.js | 6 +++---
4 files changed, 7 insertions(+), 6 deletions(-)
diff --git a/web/package.json.buildonly b/web/package.json.buildonly
index 6bdff994f..df6e5bc49 100644
--- a/web/package.json.buildonly
+++ b/web/package.json.buildonly
@@ -3,6 +3,7 @@
"main": "index.js",
"repository": "https://github.com/transmission/transmission",
"license": "MIT",
+ "type": "module",
"scripts": {
"build": "node esbuild.mjs"
},
diff --git a/web/public_html/transmission-app.css b/web/public_html/transmission-app.css
index 2aaf2e6cb..fc7f5e12f 100644
--- a/web/public_html/transmission-app.css
+++ b/web/public_html/transmission-app.css
@@ -1,2 +1,2 @@
-:root{--z-index-popup: 2;--dialog-logo-padding: calc(var(--dialog-padding) * .66);--dialog-padding: 20px;--logo-size: 64px;--pauseresume-size: 20px;--popup-top: 51px;--progressbar-border: 1px;--progressbar-height: 20px;--toolbar-height: 50px;--black: #000;--blue-100: #51b3f7;--blue-200: #357aaa;--blue-300: #2c7fea;--blue-400: #1847d4;--dark-mode-black: #121212;--dark-mode-white: #c9d1d9;--default-accent-color-dark: #0c2d6b;--default-border-dark: #575757;--default-border-light: #aeaeae;--default-tinted: rgba(128, 128, 144, .125);--green-100: #26aa55;--green-300: #7cef99;--green-400: #67c87f;--green-500: #34dc70;--grey-200: #e1e4e8;--grey-40: #666;--grey-500: #828282;--grey-900: #191919;--nice-grey: #f8f8f8;--red-500: #d73a49;--white: #fff;--yellow-300: #ffea7f;--image-alt-speed-disabled: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACQAAAASCAQAAACZKrSjAAACOElEQVR42mLABIBOygHIbyeAwu+Mv40qm9q2zkre1r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FeIj0ZbTEa3/ZQNDLQJqNQbcTJPGtwqypeBsDX+XlYN+08mbCjc2UKA2adQVgr1cY4giePSVK1CUHUIe+prp6i8iDDpWTzw/cIH1BT/LAiTfITTxGn8H3cLFaJVhGBdQUbhayRk3FS0ajk8iahaMbi/42rdCf/q8LoBSURjNaovt/+ANj4VO+gduEH2H+HyQkAbwrBCKDOajVJWLTnorsFt87UVKS+McpHaMgD4JzotDkMK8bsHPd8sehnMxgsPF1G+FCsEdwugWjuxchhYt5WEL/GMgNnFIPymi294abh4b6C4xtkSPjxQJqosvzz26R8A7pWO3evi0yJi43yZBBQN4FtaShFWAHr+MgTqWq4t2REkU7X2Ts7i8w24qaNzFNgzA98Mfp6En4tg7bO7topdM+YVfh5XWZjCMmIGOgGvOwJaeWbI7q1Ou8+42mZ13Z1EkAphmYzoAQHt1AWDAaaGlUQdnIcQZNjMWSU2QE+OYDEhaeqL3BYzp/QU9jcELAcAekBpBwHA5eAoXCSshmuYG7g3yOArXKC2PK7kJuEaI2UgLeBb6CLamJ0y9Hl8iWj1oUVtS0+JjONec3GqVtyPTY1bqyk0PLXbH3IMkiuyN75TxenzP2PwomuVkLYD6Hw9rjkSl0RslfFv3BodMBEQdLFMtKJYCacvtiuwojhr6MscIMo6h5iPLm69CrNe/IUtwKCiysuWUnnW0lPsv7jleAdgogy27VGBCQ9+M/2/Cb7SkNVpB3MSfhhL7fssmD0wuAlxiwDEFgB3Bf3hTGK1zfr4CJlxUMYWF0ZsAAAAAElFTkSuQmCC);--image-baseline: url('data:image/svg+xml,');--image-chevron-dn: url('data:image/svg+xml,');--image-chevron-up: url('data:image/svg+xml,');--image-lock-fill: url('data:image/svg+xml,');--image-magnet: url('data:image/svg+xml,');--image-pause-circle-active: url('data:image/svg+xml,%0A%0A%0A%0A');--image-pause-circle-idle: url('data:image/svg+xml,%0A%0A%0A');--image-play-circle-active: url('data:image/svg+xml,%0A%0A%0A%0A');--image-play-circle-idle: url('data:image/svg+xml,%0A%0A%0A');--app-image-url: url('data:image/svg+xml,');--audio-image-url: url('data:image/svg+xml,');--folder-image-url: url('data:image/svg+xml,');--font-image-url: url('data:image/svg+xml,');--image-image-url: url('data:image/svg+xml,');--package-image-url: url('data:image/svg+xml,');--text-image-url: url('data:image/svg+xml,');--video-image-url: url('data:image/svg+xml,');--progress: 100%;--color-bg-even: var(--default-tinted);--color-bg-tabs: var(--default-tinted);--color-fg-error: var(--red-500);--color-fg-port-closed: var(--red-500);--color-fg-port-open: var(--green-100);--color-progressbar-background-2: var(--green-400);--color-progressbar-leech: var(--blue-200);--color-progressbar-magnet: var(--yellow-300);--color-progressbar-paused: var(--grey-200);--color-progressbar-queued: var(--blue-400);--color-progressbar-verify: var(--yellow-300);--color-toolbar-background: var(--default-tinted);color-scheme:light dark}@media (prefers-color-scheme: dark){:root{--color-bg-hover: var(--grey-40);--color-bg-odd: var(--black);--color-bg-popup: var(--black);--color-bg-primary: var(--black);--color-bg-selected: var(--default-accent-color-dark);--color-bg-warn: #cf6679;--color-border-default: var(--default-border-dark);--color-border-stark: var(--dark-mode-white);--color-border-starkest: var(--grey-500);--color-fg-disabled: #808088;--color-fg-on-popup: var(--nice-grey);--color-fg-primary: var(--dark-mode-white);--color-fg-secondary: var(--nice-grey);--color-fg-selected: var(--dark-mode-white);--color-fg-tertiary: var(--grey-500);--color-fg-warn: var(--dark-mode-black);--color-progressbar-paused: var(--grey-500);--color-progressbar-seed-1: var(--green-100);--color-progressbar-seed-2: var(--green-400);--color-progressbar-seed-paused: var(--grey-500)}:root .contrast-more{--color-bg-even: var(--black);--color-bg-hover: var(--grey-40);--color-bg-selected: var(--blue-300);--color-bg-tabs: var(--black);--color-bg-warn: #cf6679;--color-border-default: var(--white);--color-border-stark: var(--white);--color-border-starkest: var(--white);--color-fg-disabled: var(--white);--color-fg-error: var(--red-500);--color-fg-on-popup: var(--white);--color-fg-port-closed: var(--red-500);--color-fg-port-open: var(--green-100);--color-fg-primary: var(--white);--color-fg-secondary: var(--white);--color-fg-selected: var(--white);--color-fg-tabs: var(--white);--color-fg-tertiary: var(--white);--color-fg-warn: var(--black);--color-progressbar-background-2: var(--white);--color-progressbar-magnet: var(--yellow-300);--color-progressbar-paused: var(--grey-500);--color-progressbar-queued: var(--blue-400);--color-progressbar-seed-1: var(--black);--color-progressbar-seed-2: var(--white);--color-progressbar-seed-paused: var(--grey-500);--color-progressbar-verify: var(--yellow-300);--color-toolbar-background: var(--black)}}@media (prefers-color-scheme: light){:root{--color-bg-hover: var(--nice-grey);--color-bg-odd: var(--white);--color-bg-popup: var(--white);--color-bg-primary: var(--white);--color-bg-selected: var(--blue-300);--color-bg-warn: #e4606d5b;--color-border-default: var(--default-border-light);--color-border-stark: var(--grey-500);--color-border-starkest: #d0d7de;--color-dialog-border: var(--nice-grey);--color-fg-disabled: var(--grey-500);--color-fg-error: var(--red-500);--color-fg-on-popup: var(--grey-900);--color-fg-port-closed: var(--red-500);--color-fg-port-open: var(--green-400);--color-fg-primary: #404040;--color-fg-secondary: var(--grey-500);--color-fg-selected: var(--nice-grey);--color-fg-tertiary: var(--grey-500);--color-fg-warn: #cf212e;--color-progressbar-leech: var(--blue-100);--color-progressbar-magnet: var(--yellow-300);--color-progressbar-paused: var(--grey-200);--color-progressbar-queued: var(--blue-400);--color-progressbar-seed-1: var(--green-500);--color-progressbar-seed-2: var(--green-300);--color-progressbar-seed-paused: var(--grey-200);--color-progressbar-verify: var(--yellow-300)}:root .contrast-more{--color-bg-even: var(--white);--color-bg-hover: var(--grey-40);--color-bg-selected: var(--blue-300);--color-bg-tabs: var(--white);--color-bg-warn: #cf6679;--color-border-default: var(--black);--color-border-stark: var(--black);--color-border-starkest: var(--black);--color-fg-disabled: var(--black);--color-fg-error: var(--red-500);--color-fg-on-popup: var(--black);--color-fg-port-closed: var(--red-500);--color-fg-port-open: var(--green-400);--color-fg-primary: var(--black);--color-fg-secondary: var(--black);--color-fg-selected: var(--white);--color-fg-tabs: var(--black);--color-fg-tertiary: var(--black);--color-fg-warn: var(--white);--color-progressbar-background-2: var(--white);--color-progressbar-leech: var(--blue-200);--color-progressbar-magnet: var(--yellow-300);--color-progressbar-paused: var(--grey-500);--color-progressbar-queued: var(--blue-400);--color-progressbar-seed-1: var(--black);--color-progressbar-seed-2: var(--white);--color-progressbar-seed-paused: var(--grey-500);--color-progressbar-verify: var(--yellow-300);--color-toolbar-background: var(--white)}}@supports (background-color: Canvas){:root .contrast-less{--color-bg-odd: Canvas;--color-bg-primary: Canvas;--color-bg-popup: Canvas}}html,body{background-color:var(--color-bg-primary);color:var(--color-fg-primary);font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica,Arial,sans-serif,"Apple Color Emoji","Segoe UI Emoji",Segoe UI Symbol;height:100%;margin:0}img{border:0}a{color:var(--color-fg-primary);outline:0;text-decoration:underline}.hidden{display:none}#mainwin{display:flex;flex-direction:column;height:100%;position:relative}#mainwin>*{margin:0;padding:0}#mainwin .flexible-space{margin-right:auto}#mainwin-workarea{display:flex;flex:1;flex-direction:row;overflow:auto}.popup,.tabs-container{box-shadow:0 3px 6px -4px #0000001f,0 6px 16px #00000014,0 9px 28px 8px #0000000f;position:absolute}#mainwin-toolbar{align-items:center;background:var(--color-toolbar-background);border-bottom:1px solid var(--color-border-default);display:flex;flex-direction:row;height:var(--toolbar-height);margin:0;width:100%}#mainwin-toolbar button{background-color:transparent;background-position:center;background-repeat:no-repeat;border:0;border-radius:5px;cursor:pointer;height:var(--toolbar-height);margin-right:6px;user-select:none;-webkit-user-select:none;width:var(--toolbar-height)}#mainwin-toolbar button svg{stroke:var(--color-fg-primary)}#mainwin-toolbar button svg g path{fill:var(--color-fg-primary)}#mainwin-toolbar button:disabled{cursor:default}#mainwin-toolbar button:disabled svg{stroke:var(--color-fg-disabled)}#mainwin-toolbar button:disabled svg g path{fill:var(--color-fg-disabled)}#mainwin-toolbar>.toolbar-separator{border-left:1px solid var(--color-border-default);height:25px;margin:0 6px 0 0}#mainwin-toolbar :nth-last-child(2){border:0;flex-grow:1}.toolbar-icon{stroke:var(--color-fg-primary)}#toolbar-overflow{margin-right:4px}#toolbar-overflow svg{fill:var(--color-fg-primary);height:36px;width:36px}#toolbar-overflow.alt-speed-enabled{background-image:var(--image-alt-speed-enabled);background-position:bottom left;background-size:20px}#mainwin-statusbar{white-space:nowrap;align-items:center;background:var(--color-toolbar-background);border-bottom:1px solid var(--color-border-default);display:flex;flex-direction:row;height:30px;padding-left:5px}@media (width < 600px){#mainwin-statusbar :not(select):not(input):not(option):not(.flexible-space){display:none}}#mainwin-statusbar #torrent-search{width:100%;max-width:160px}#mainwin-statusbar select{width:70px}#mainwin-statusbar>*{margin-right:5px}#mainwin-statusbar .speed-container{display:inherit;align-items:inherit;flex-direction:inherit}#mainwin-statusbar .speed-container:not(:nth-child(1 of#mainwin-statusbar .speed-container)){width:100px}#mainwin-statusbar #speed-up-icon,#mainwin-statusbar #speed-dn-icon{fill:var(--color-fg-primary)}#mainwin-statusbar #speed-up-icon svg,#mainwin-statusbar #speed-dn-icon svg{width:20px}#mainwin-statusbar #speed-dn-label,#mainwin-statusbar #speed-up-label{text-align:right}#torrent-container{flex-grow:1;left:0;margin:0;overflow:auto;padding:0;right:0}#torrent-list{cursor:pointer;list-style-type:none;margin:0;padding:0;text-align:left;width:100%;user-select:none;-webkit-user-select:none}#torrent-list .torrent{border-bottom:1px solid var(--color-border-default)}#torrent-list .torrent:nth-child(2n){background-color:var(--color-bg-even)}#torrent-list .torrent:nth-child(odd){background-color:var(--color-bg-odd)}#torrent-list .torrent .icon{background-color:var(--color-fg-primary);background-position:center,top left;-webkit-mask-image:var(--mime-icon-url);-webkit-mask-repeat:no-repeat;mask-image:var(--mime-icon-url);mask-repeat:no-repeat}#torrent-list .torrent .icon[data-icon-multifile=true]{-webkit-mask-image:var(--mime-icon-url),var(--folder-image-url);-webkit-mask-position:top left,bottom right;-webkit-mask-repeat:no-repeat,no-repeat;-webkit-mask-size:16px,16px;mask-image:var(--mime-icon-url),var(--folder-image-url);mask-position:top left,bottom right;mask-repeat:no-repeat,no-repeat;mask-size:16px,16px}#torrent-list .torrent .icon[data-icon-mime-type=audio]{--mime-icon-url: var(--audio-image-url)}#torrent-list .torrent .icon[data-icon-mime-type=application]{--mime-icon-url: var(--app-image-url)}#torrent-list .torrent .icon[data-icon-mime-type=font]{--mime-icon-url: var(--font-image-url)}#torrent-list .torrent .icon[data-icon-mime-type=image]{--mime-icon-url: var(--image-image-url)}#torrent-list .torrent .icon[data-icon-mime-type=model]{--mime-icon-url: var(--package-image-url)}#torrent-list .torrent .icon[data-icon-mime-type=text]{--mime-icon-url: var(--text-image-url)}#torrent-list .torrent .icon[data-icon-mime-type=video]{--mime-icon-url: var(--video-image-url)}#torrent-list .torrent .torrent-name{font-weight:700;margin-bottom:2px;margin-top:2px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}#torrent-list .torrent .torrent-name.compact{font-size:1em;font-weight:400}#torrent-list .torrent .torrent-labels{font-size:small;font-weight:400;margin-bottom:2px;margin-top:2px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;padding:1px 0}#torrent-list .torrent .torrent-labels.compact{flex:1;font-size:small}#torrent-list .torrent .torrent-label{padding:0 8px;margin:0 2px;border-radius:1em;border:1px solid var(--color-border-default)}#torrent-list .torrent .torrent-progress-details.error,#torrent-list .torrent .torrent-peer-details.error{color:var(--color-fg-error)}#torrent-list .torrent .torrent-progress-details,#torrent-list .torrent .torrent-peer-details{font-size:small}#torrent-list .torrent.compact{--icon-size: 16px;align-items:center;display:flex;flex-direction:row-reverse}#torrent-list .torrent.compact .icon{-webkit-mask-size:var(--icon-size),calc(var(--icon-size) / 2);flex-shrink:0;height:var(--icon-size);mask-size:var(--icon-size),calc(var(--icon-size) / 2);width:var(--icon-size)}#torrent-list .torrent.compact .icon[data-icon-multifile=true]{--mime-icon-url: var(--folder-image-url)}#torrent-list .torrent.compact>*{margin:5px}#torrent-list .torrent:not(.compact){--icon-size: 32px;align-items:center;display:grid;grid-column-gap:12px;grid-template-areas:"icon name labels" "icon progress-text progress-text" "icon progressbar progressbar" "icon peers peers";grid-template-columns:var(--icon-size) auto 1fr;padding:6px 12px}#torrent-list .torrent:not(.compact) .icon{background-size:var(--icon-size),calc(var(--icon-size) / 2);grid-area:icon;height:var(--icon-size);width:var(--icon-size)}#torrent-list .torrent:not(.compact) .torrent-name{grid-area:name}#torrent-list .torrent:not(.compact) .torrent-labels{grid-area:labels}#torrent-list .torrent:not(.compact) .torrent-peer-details{grid-area:peers}#torrent-list .torrent:not(.compact) .torrent-progress{display:flex;flex-direction:row;grid-area:progressbar}#torrent-list .torrent:not(.compact) .torrent-progress-details{grid-area:progress-text}#torrent-list .torrent:not(.compact)>*{margin:1px 0}#torrent-list .torrent.paused{color:var(--color-fg-disabled)}#torrent-list .torrent.paused .icon{background-color:var(--color-fg-disabled)}#torrent-list .torrent.selected{background-color:var(--color-bg-selected);color:var(--color-fg-selected)}#torrent-list .torrent.selected .icon{background-color:var(--color-fg-selected)}#torrent-list .icon{background-position:center;background-repeat:no-repeat}#torrent-list .torrent-pauseresume-button{background-position:center center;background-repeat:no-repeat;background-size:var(--pauseresume-size);margin-left:calc(var(--pauseresume-size) / 2);width:var(--pauseresume-size)}#torrent-list .torrent-pauseresume-button[data-action=pause]{background-image:var(--image-pause-circle-idle)}#torrent-list .torrent-pauseresume-button[data-action=pause]:active,#torrent-list .torrent-pauseresume-button[data-action=pause]:hover{background-image:var(--image-pause-circle-active)}#torrent-list .torrent-pauseresume-button[data-action=resume]{background-image:var(--image-play-circle-idle)}#torrent-list .torrent-pauseresume-button[data-action=resume]:active,#torrent-list .torrent-pauseresume-button[data-action=resume]:hover{background-image:var(--image-play-circle-active)}#torrent-list .torrent-progress-bar{background-repeat:no-repeat;border-color:var(--color-border-starkest);border-radius:3px;border-style:solid;border-width:1px;height:calc(var(--progressbar-height) - var(--progressbar-border) * 2)}#torrent-list .torrent-progress-bar.full{flex-grow:1;margin:2px 0}#torrent-list .torrent-progress-bar.compact{min-width:100px;width:10vw}#torrent-list .torrent-progress-bar.leech{background:linear-gradient(to right,var(--color-progressbar-leech) 0,var(--color-progressbar-leech) var(--progress, 30%),transparent var(--progress, 30%)),no-repeat}#torrent-list .torrent-progress-bar.leech.queued{background:linear-gradient(to right,var(--color-progressbar-queued) 0,var(--color-progressbar-queued) var(--progress, 30%),transparent var(--progress, 30%)),no-repeat}#torrent-list .torrent-progress-bar.magnet{background:linear-gradient(to right,var(--color-progressbar-magnet) 0,var(--color-progressbar-magnet) var(--progress, 30%),transparent var(--progress, 30%)),no-repeat}#torrent-list .torrent-progress-bar.seed.paused{background-color:var(--color-progressbar-seed-paused)}#torrent-list .torrent-progress-bar.seed:not(.paused){background:linear-gradient(to right,var(--color-progressbar-seed-1) 0,var(--color-progressbar-seed-1) var(--progress, 30%),var(--color-progressbar-seed-2) var(--progress, 30%)),no-repeat}#torrent-list .torrent-progress-bar.seed.queued{background-color:var(--color-progressbar-seed-paused)}#torrent-list .torrent-progress-bar.verify{background:linear-gradient(to right,var(--color-progressbar-verify) 0,var(--color-progressbar-verify) var(--progress, 30%),transparent var(--progress, 30%)),no-repeat}#torrent-list .torrent-progress-bar.paused{background:linear-gradient(to right,var(--color-progressbar-paused) 0,var(--color-progressbar-paused) var(--progress, 30%),transparent var(--progress, 30%)),no-repeat}@media (width < 600px){input[type=checkbox]{height:20px;width:20px}}@media (width < 600px){#inspector,#prefs-dialog{left:0}}@media (width >= 600px){#inspector,#prefs-dialog{border-left:1px solid var(--color-border-default);width:570px}}#prefs-dialog{background:var(--color-bg-primary);bottom:0;right:0;top:var(--popup-top);z-index:var(--z-index-popup)}#prefs-dialog .tabs-page{grid-column-gap:8px;grid-row-gap:5px;grid-template-columns:1fr 1fr;margin:20px}#prefs-dialog .tabs-page:not(.hidden){display:grid}#prefs-dialog .tabs-page .section-label{font-weight:700;grid-column:span 2;padding-bottom:5px}#prefs-dialog .tabs-page .section-label:not(:first-of-type){margin-top:20px}#prefs-dialog .alt-speed-section-label{background:transparent var(--image-alt-speed-enabled) no-repeat;background-position:left;background-position-y:4px;background-size:20px;padding-left:22px}#prefs-dialog :disabled,#prefs-dialog .disabled{color:var(--color-fg-disabled)}#prefs-dialog #alt-times-div,#prefs-dialog #autostart-div,#prefs-dialog #port-forwarding,#prefs-dialog #randomize-port,#prefs-dialog #suffix-div,#prefs-dialog #use-dht-div,#prefs-dialog #use-lpd-div,#prefs-dialog #use-pex-div,#prefs-dialog #utp-enabled,#prefs-dialog .alt-speed-label{grid-column:span 2}#prefs-dialog #default-trackers{height:300px}#prefs-dialog .blocklist-size-label,#prefs-dialog .blocklist-update-button,#prefs-dialog .register-handler-button,#prefs-dialog .port-status{grid-column:2/3}#prefs-dialog .blocklist-size-label{font-size:smaller}#prefs-dialog .blocklist-size-number{font-weight:bolder}#prefs-dialog .port-status-label{display:inline-block;font-weight:700;margin-left:5px}#prefs-dialog .port-status-label[data-open=true]{color:var(--color-fg-port-open)}#prefs-dialog .port-status-label[data-open=false]{color:var(--color-fg-port-closed)}#prefs-dialog #default-trackers,#prefs-dialog .default-trackers-label{grid-column:1/3}#prefs-dialog .alt-speed-label{font-size:smaller;margin:-10px 0 10px}#prefs-dialog.ui-tabs .ui-tabs-panel{padding:0;user-select:none;-webkit-user-select:none}.tabs-container{align-items:stretch;background:var(--color-bg-primary);bottom:0;display:flex;flex-direction:column;position:absolute;right:0;top:var(--popup-top);z-index:var(--z-index-popup)}@media (width < 600px){.tabs-container{left:0}}@media (width >= 600px){.tabs-container{width:550px}}.tabs-container-close{font-size:150%;cursor:pointer;background:var(--color-bg-primary);border:0;color:var(--color-fg-primary);position:absolute;padding:10px 16px}.tabs-buttons{align-self:center;background-color:var(--color-bg-tabs);border:1px solid var(--color-border-starkest);border-radius:6px;display:flex;margin:10px 0}.tabs-buttons button{appearance:none;border:1px solid transparent;border-radius:6px;color:var(--color-fg-primary);font-weight:400}.tabs-pages{box-sizing:border-box;flex:1;overflow-x:hidden;overflow-y:auto}@media (width < 600px){.tabs-pages{padding:0 8px 20px}}@media (width >= 600px){.tabs-pages{padding:0 20px 20px}}.tabs-button{background:none;border:1px solid transparent;font-size:14px;padding:3px 8px}.tabs-button:active,.tabs-button:checked,.tabs-button.selected{background-color:var(--color-bg-odd);border:1px solid var(--color-fg-primary);border-radius:5px}.inspector-info-page{font-size:14px;grid-column-gap:8px;grid-row-gap:8px;grid-template-columns:auto 1fr;margin:20px;padding:12px}.inspector-info-page:not(.hidden){display:grid}.inspector-info-page .section-label{font-size:16px;font-weight:700;grid-column:span 2;padding-bottom:5px}.inspector-info-page .section-label:not(:first-of-type){margin-top:20px}.inspector-info-page label{font-weight:500}.inspector-info-page :not(.section-label){overflow-x:hidden;text-overflow:ellipsis}.inspector-info-magnet button{background-color:var(--color-fg-primary);background-position:top;background-repeat:no-repeat;border:0;cursor:pointer;height:1rem;-webkit-mask:var(--image-magnet) no-repeat center/14px;mask:var(--image-magnet) no-repeat center/14px;vertical-align:middle;width:1rem}#inspector .tabs-button,#prefs-dialog .tabs-button{height:30px;margin:0;min-width:40px}#inspector-file-list{margin:0;padding:0}#inspector-file-list .inspector-torrent-file-list-entry{display:grid;grid-column-gap:5px;grid-template-areas:"check name priority" "blank1 info blank2";grid-template-columns:20px 1fr 65px;margin-bottom:4px;padding:5px}#inspector-file-list .inspector-torrent-file-list-entry:nth-child(2n){background-color:var(--color-bg-even)}#inspector-file-list .inspector-torrent-file-list-entry:nth-child(odd){background-color:var(--color-bg-odd)}#inspector-file-list .inspector-torrent-file-list-entry.skip{opacity:.5}#inspector-file-list .file-wanted-control{grid-area:check}#inspector-file-list .inspector-torrent-file-list-entry-name{color:var(--color-fg-primary);cursor:pointer;font-size:14px;grid-area:name;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}#inspector-file-list .inspector-torrent-file-list-entry.skip>.inspector-torrent-file-list-entry-name{color:var(--color-fg-disabled)}#inspector-file-list .inspector-torrent-file-list-entry-progress{color:var(--color-fg-secondary);font-size:12px;grid-area:info}#inspector-file-list .single-file .inspector-torrent-file-list-entry>.file-wanted-control,#inspector-file-list .inspector-torrent-file-list-entry.complete>.file-wanted-control{cursor:default}#inspector-header{margin:8px 0}#torrent-inspector-name{font-size:large;font-weight:700}#inspector-tiers-list{color:var(--color-fg-primary);margin:0 10px;padding:0}#inspector-tiers-list .tier-list-row{display:grid;font-size:12px;grid-column-gap:8px;grid-row-gap:4px;padding:8px 12px}#inspector-tiers-list .tier-list-row:nth-child(2n of.tier-list-row){background-color:var(--color-bg-even)}#inspector-tiers-list .tier-list-row:nth-child(odd of.tier-list-row){background-color:var(--color-bg-odd)}#inspector-tiers-list .tier-list-torrent{color:var(--color-fg-primary);font-weight:bolder;overflow-x:hidden;padding-top:12px;padding-bottom:8px;text-overflow:ellipsis;white-space:nowrap}#inspector-tiers-list .tier-list-tracker{font-size:14px;font-weight:bolder;grid-column:span 2;padding-bottom:4px}#inspector-tiers-list .tier-announce,#inspector-tiers-list .tier-scrape,#inspector-tiers-list .tier-state{text-align:left}#inspector-tiers-list .tier-downloads,#inspector-tiers-list .tier-leechers,#inspector-tiers-list .tier-seeders{text-align:right}.peer-list{--table-border: 1px solid var(--color-border-default);border:var(--table-border);border-collapse:collapse;cursor:default;table-layout:fixed;text-align:left;width:100%}.peer-list td,.peer-list th{font-size:smaller;padding:5px}.peer-list td{border:var(--table-border);color:var(--color-fg-secondary)}.peer-list .torrent-row td{background:var(--color-bg-odd);color:var(--color-fg-primary);font-weight:bolder;overflow-x:hidden;padding:10px;text-overflow:ellipsis;white-space:nowrap}.peer-list .encryption[data-encrypted=true]{background-color:var(--color-border-starkest);-webkit-mask:var(--image-lock-fill) no-repeat center/14px;mask:var(--image-lock-fill) no-repeat center/14px;width:10px}.peer-list .peer-address,.peer-list .percent-done,.peer-list .speed-down,.peer-list .speed-up{text-align:right}.peer-list .percent-done{width:10%}@media (width < 600px){.peer-list .percent-done{width:12%}}.peer-list .speed-down,.peer-list .speed-up{width:15%}.peer-list .peer-address{width:25%;overflow-x:hidden;text-overflow:ellipsis}@media (width < 600px){.peer-list .peer-address{text-align:left;width:20%}}.peer-list .peer-app-name{overflow-x:hidden;text-overflow:ellipsis;white-space:nowrap}@media (width >= 600px){.peer-list .peer-app-name{width:20%}}.peer-list .status{cursor:pointer;width:10%}.file-priority-radiobox{grid-area:priority}.file-priority-radiobox>*{appearance:none;background-color:var(--color-border-starkest);background-position:center;background-repeat:no-repeat;background-size:10px,20px;border:1px solid var(--color-border-stark);border-radius:0;height:20px;margin:0;padding:0;width:20px}.file-priority-radiobox>.low{background-image:var(--image-chevron-dn);border-right-width:0}.file-priority-radiobox>.normal{background-image:var(--image-baseline)}.file-priority-radiobox>.high{background-image:var(--image-chevron-up);border-left-width:0}.file-priority-radiobox>.checked{background-color:var(--color-bg-hover)}.context-menu{background-color:var(--color-bg-primary);border-radius:5px;color:var(--color-fg-on-popup);padding:10px 5px;z-index:9999;user-select:none;-webkit-user-select:none}.context-menu .context-menuitem{font-size:13px;font-weight:400;list-style:none;padding:5px 15px}.context-menu .context-menuitem:hover:not(:disabled),.context-menu .context-menuitem:focus:not(:disabled){background-color:var(--color-bg-hover);border-radius:6px;cursor:pointer;font-weight:500}.context-menu .context-menuitem:disabled{color:var(--color-fg-disabled);cursor:none}.context-menu .context-menuitem.warning:hover{background-color:var(--color-bg-warn);color:var(--color-fg-warn)}.context-menu-separator{border-bottom:1px solid var(--color-fg-secondary);margin-bottom:10px;padding-bottom:10px}.overflow-menu{background:var(--color-bg-popup);border-radius:5px;color:var(--color-fg-on-popup);overflow:auto;padding:10px;right:0;margin:6px;top:50px;z-index:var(--z-index-popup)}@media (width < 600px){.overflow-menu{height:80vh}}.overflow-menu fieldset{border:0;display:block;margin:8px 0}.overflow-menu fieldset ul{margin:0;padding-left:0}.overflow-menu fieldset ul li{list-style-type:none}.overflow-menu fieldset ul a{cursor:pointer}.overflow-menu .table-row{align-items:center;border-radius:6px;display:flex;flex-direction:row;padding:3px 0}.overflow-menu legend{color:var(--color-fg-primary);font-weight:bolder;margin:12px 0 4px}.overflow-menu button,.overflow-menu label{color:var(--color-fg-primary);display:inline-flex;font-size:1em;width:100%}.overflow-menu button{background:transparent;border:0;cursor:pointer;display:block;padding:4px 0;text-align:left;text-decoration:none;width:150px}.overflow-menu .input-and-label{align-items:center;display:inline-flex;flex-direction:row}.overflow-menu #display-options,.overflow-menu #speed-options{display:flex;flex-direction:column}.overflow-menu #speed-options>.speed-up,.overflow-menu #speed-options>.speed-down{align-items:center;display:flex;flex-direction:row;padding:4px 0}.overflow-menu #speed-options>.speed-up>label,.overflow-menu #speed-options>.speed-down>label{overflow:hidden;width:80px}.overflow-menu #speed-options .alt-speed{display:grid;grid-column-gap:5px;grid-row-gap:5px;grid-template-areas:"check lb" "turtle values";grid-template-columns:22px 1fr;margin-bottom:4px}.overflow-menu #speed-options #alt-speed-check{grid-area:check}.overflow-menu #speed-options #alt-speed-check:checked~#alt-speed-image{background-image:var(--image-alt-speed-enabled);background-position:left;background-size:22px}.overflow-menu #speed-options #alt-speed-check:not(:checked)~#alt-speed-image{background-image:var(--image-alt-speed-disabled);background-size:22px}.overflow-menu #speed-options #alt-speed-image{background-position:center;background-repeat:no-repeat;grid-area:turtle}.overflow-menu #speed-options #alt-speed-label{grid-area:lb}.overflow-menu #speed-options #alt-speed-values-label{font-size:small;grid-area:values}@media (width < 600px){.dialog-buttons{padding-top:var(--dialog-logo-padding)}.dialog-container{opacity:96%;position:absolute;top:var(--popup-top);width:100%}.dialog-logo{padding-bottom:var(--dialog-logo-padding)}.dialog-window{align-items:center;display:flex;flex-direction:column}}@media (width >= 600px){.dialog-container{min-width:500px;position:absolute;top:calc(var(--popup-top) * 2)}.dialog-heading{grid-area:heading}.dialog-logo{grid-area:icon;padding-right:var(--dialog-logo-padding)}.dialog-window{background-color:var(--color-bg-popup);color:var(--color-fg-on-popup);display:grid;grid-column-gap:12px;grid-template-areas:"icon heading" "icon message" "icon workarea" "icon buttons";grid-template-columns:var(--logo-size) 1fr;padding:2px 12px}}.dialog-buttons{display:flex;float:right;grid-area:buttons;margin:10px 0 0;text-align:center}.dialog-buttons button{appearance:none;background:var(--color-bg-primary);border:1px solid var(--color-border-default);border-radius:5px;color:var(--color-fg-primary);margin-left:8px;padding:8px;text-decoration:none}.dialog-buttons-begin{flex-grow:1}.dialog-buttons-end{display:none}dialog{border:0}.dialog-container{color:var(--color-fg-primary);display:block;padding:0;z-index:var(--z-index-popup)}@media (width >= 600px){.dialog-container{border:0;border-radius:8px;max-width:50%}}.dialog-heading{align-items:center;display:flex;font-size:1.2em;font-weight:700}.dialog-logo{background:transparent url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAEAAAABACAYAAACqaXHeAAASBklEQVR42u1aBXAcSbLN7h4Ws2XBMhqXmfGYmcleJi8fLcX+Y+a75UD5mJmZz7C7ZlsryaQRjjQa6Kn/XkVn3MRYY00fUyoyqtVTlZX5KjMru7rlv52cf9E5zX8EuCbggRe9yHsRuFbA77rrLndgYMDT8UL+VyUqeJeIOyDioY2w5b2q/Y1xVq1aFT3yyCPjZ5xxRvJZz3pW6vzzz0/A6Bh+8w42T/kcnNP8s4ChAgsaihX/zqpVTQ+ILP7oVVddet+99z749re+9Wu33377L2+66aaN11577eZrrrlmEDwM3nbjjTc+eccdd/zhbW9723ff8573rB144IHXvl+k+5O33dYkkFWLPqE9JewArp5jRzlG730SK+j84he9ju8fGYnFjohPTByR9f1DdjlOX6G+vr1nfLwx+qIXteTOO09y2WylPCE5kKrkFwrS3tMj7VNTMnPttRNOT8+k2bdvNGLMcNHznvKbm7eafH5r3nW35Zcte+rqH/4wU+kpDpu/JQA0/Ic//KF3wQUXFAX08fb2Z9ZnMmfDZ5cWjTnGKxYXR41JJWBQUkSmwJvB6cZG6YIh7a95jUSe9rSi8X2HssqM1vkNyN4zpZJJNjWZyOCgK9dc47pdXSJ790pc7BJby2bQL+M4OT8SGYk4zlbfdTcUEonfDI6Pfw6hkWcOAZf+JgCUCxswJjb8kpesaR8YuL/R8yTv+xIRsYwOJofGRZulfWDT1ia5d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var(--logo-size);width:var(--logo-size)}.dialog-message{grid-area:message;margin:10px 0 0}.dialog-window{background:var(--color-bg-primary);border-radius:8px;padding:var(--dialog-padding)}.dialog-workarea{display:flex;flex-direction:column;grid-area:workarea;margin:10px 0 0}.dialog-workarea>*{margin-bottom:5px}.about-dialog{max-width:initial}.about-dialog .dialog-workarea>*{margin-bottom:10px}.about-dialog-version-number{margin-left:4px}.about-dialog-version-checksum{font-size:small;font-style:italic;font-weight:400;margin-left:auto;padding-left:10px}.open-torrent input{margin-bottom:15px}.open-torrent input[type=file]{width:100%;box-sizing:border-box}.open-torrent #auto-start-label{margin-left:5px}.shortcuts-dialog table{border-collapse:collapse;width:100%}.shortcuts-dialog th,.shortcuts-dialog td{border:1px solid var(--color-border-stark);padding:5px 10px}#torrent-rename-name,#move-container #torrent-path{min-width:400px}.tabs-pages .content,.inspector-info-page .content,.statistics-dialog .content{column-gap:16px;display:grid;grid-row-gap:6px;grid-template-columns:auto 1fr;margin-top:4px}@media (width < 600px){.tabs-pages .content,.inspector-info-page .content,.statistics-dialog .content{margin:4px 0 16px}}@media (width >= 600px){.tabs-pages .content,.inspector-info-page .content,.statistics-dialog .content{margin:4px 16px 16px}}.tabs-pages .content div,.inspector-info-page .content div,.statistics-dialog .content div{word-break:break-word}.tabs-pages fieldset,.inspector-info-page fieldset,.statistics-dialog fieldset{border:0;margin:0;padding:0}.tabs-pages legend,.inspector-info-page legend,.statistics-dialog legend{font-weight:bolder;margin-bottom:4px}#free-space-text{display:inline-block;font-size:smaller;font-style:italic}.upload-div{display:none}
+:root{--z-index-popup: 2;--dialog-logo-padding: calc(var(--dialog-padding) * .66);--dialog-padding: 20px;--logo-size: 64px;--pauseresume-size: 20px;--popup-top: 51px;--toolbar-height: 50px;--black: #000;--blue-100: #51b3f7;--blue-200: #357aaa;--blue-300: #2c7fea;--blue-400: #1847d4;--dark-mode-black: #121212;--dark-mode-white: #c9d1d9;--default-accent-color-dark: #0c2d6b;--default-border-dark: #575757;--default-border-light: #aeaeae;--default-tinted: rgba(128, 128, 144, .125);--green-100: #26aa55;--green-300: #7cef99;--green-400: #67c87f;--green-500: #34dc70;--grey-200: #e1e4e8;--grey-40: #666;--grey-500: #828282;--grey-900: #191919;--nice-grey: #f8f8f8;--red-500: #d73a49;--white: #fff;--yellow-300: #ffea7f;--image-alt-speed-disabled: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACQAAAASCAQAAACZKrSjAAACOElEQVR42mLABIBOygHIbyeAwu+Mv40qm9q2zkre1rZt27bbcW3btm3bNg5pJpPM7/yFq2+9MpAzuJ03eYmb9PHMhtSgFeQeRjuub1xa4Q/EQ05vNXfaNIgPPZivGR3Pda5cOjhQflWmis8iOva6LWrDCf3lbUbHf8kxzraI/SLadvWBDTegfEZeik+jj4Ab/WGh9LMU31v1UU1vJXKhbAFov8lBfOLQ7JQRQIU/eEhKqz0PTE1p8Y94bPxNNDUy1Cg0o8ovAP1ZTnbiFA5jI5kfAFiW1xnNwzBQa5mar2p6eIjrxv8eIynAk6fN+l/IQQGesFFe4XJ+M1NLARmyi/tWx16Im+bffSMzu9u68thYSQs4hbO5hf4sZRur+YBYKKJdL+UKAEbyi020HOAQK1Qs7Ae+t0If+KcSEY/oq9IMenG+c0x0dUDfbIXbAJxlS20X4Cke2hRPxRFlrpIPgLxo1/AU3Mrl4FcrfCnAU8vFT5boOKBOE9Gxxdtlyvm/P2DBLTbNJwYB+nyHujHAvrTCWq70OdRCcCXyZ+qyq+zPRXzJqoBel98copcsDOjjeZ0z2EgrCDckhPKvqCNaZforwBPQA/jZZWU/l5kAQE2vtlBHiNo5f4xfU158NBf7qgyBVTz0ClzFD5bkFefJMnBTyitbxTdzgC/BA66oHewTqXYEAPmTVpDlpSbzRPoYeTTxxpbrblq/eE8VMUYcEzfFPnVEhvxIgHT/K+3EenE+Nt+iDIGIhxhCqqhVJ+8VkAAAAABJRU5ErkJggg==);--image-alt-speed-enabled: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUg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0ZsAAAAAElFTkSuQmCC);--image-baseline: url('data:image/svg+xml,');--image-chevron-dn: url('data:image/svg+xml,');--image-chevron-up: url('data:image/svg+xml,');--image-lock-fill: url('data:image/svg+xml,');--image-magnet: url('data:image/svg+xml,');--image-pause-circle-active: url('data:image/svg+xml,%0A%0A%0A%0A');--image-pause-circle-idle: url('data:image/svg+xml,%0A%0A%0A');--image-play-circle-active: url('data:image/svg+xml,%0A%0A%0A%0A');--image-play-circle-idle: url('data:image/svg+xml,%0A%0A%0A');--app-image-url: url('data:image/svg+xml,');--audio-image-url: url('data:image/svg+xml,');--folder-image-url: url('data:image/svg+xml,');--font-image-url: url('data:image/svg+xml,');--image-image-url: url('data:image/svg+xml,');--package-image-url: url('data:image/svg+xml,');--text-image-url: url('data:image/svg+xml,');--video-image-url: url('data:image/svg+xml,');--progress: 100%;--color-bg-even: var(--default-tinted);--color-bg-tabs: var(--default-tinted);--color-fg-error: var(--red-500);--color-fg-port-closed: var(--red-500);--color-fg-port-open: var(--green-100);--color-progressbar-background-2: var(--green-400);--color-progressbar-leech: var(--blue-200);--color-progressbar-magnet: var(--yellow-300);--color-progressbar-paused: var(--grey-200);--color-progressbar-queued: var(--blue-400);--color-progressbar-verify: var(--yellow-300);--color-toolbar-background: var(--default-tinted);color-scheme:light dark}@media (prefers-color-scheme: dark){:root{--color-bg-hover: var(--grey-40);--color-bg-odd: var(--black);--color-bg-popup: var(--black);--color-bg-primary: var(--black);--color-bg-selected: var(--default-accent-color-dark);--color-bg-warn: #cf6679;--color-border-default: var(--default-border-dark);--color-border-stark: var(--dark-mode-white);--color-border-starkest: var(--grey-500);--color-fg-disabled: #808088;--color-fg-on-popup: var(--nice-grey);--color-fg-primary: var(--dark-mode-white);--color-fg-secondary: var(--nice-grey);--color-fg-selected: var(--dark-mode-white);--color-fg-tertiary: var(--grey-500);--color-fg-warn: var(--dark-mode-black);--color-progressbar-fg-1: #edefff;--color-progressbar-fg-2: #edefff;--color-progressbar-fg-3: #edefff;--color-progressbar-paused: var(--grey-500);--color-progressbar-seed-1: var(--green-100);--color-progressbar-seed-2: var(--green-400);--color-progressbar-seed-paused: var(--grey-500);--progress-bar-shadow-1: 1px 1px #000;--progress-bar-shadow-2: 1px 1px #000;--progress-bar-shadow-3: 1px 1px #000}:root .contrast-more{--color-bg-even: var(--black);--color-bg-hover: var(--grey-40);--color-bg-selected: var(--blue-300);--color-bg-tabs: var(--black);--color-bg-warn: #cf6679;--color-border-default: var(--white);--color-border-stark: var(--white);--color-border-starkest: var(--white);--color-fg-disabled: var(--white);--color-fg-error: var(--red-500);--color-fg-on-popup: var(--white);--color-fg-port-closed: var(--red-500);--color-fg-port-open: var(--green-100);--color-fg-primary: var(--white);--color-fg-secondary: var(--white);--color-fg-selected: var(--white);--color-fg-tabs: var(--white);--color-fg-tertiary: var(--white);--color-fg-warn: var(--black);--color-progressbar-fg-1: #fff;--color-progressbar-fg-2: #fff;--color-progressbar-fg-3: #000;--color-progressbar-background-2: var(--white);--color-progressbar-magnet: var(--yellow-300);--color-progressbar-paused: var(--grey-500);--color-progressbar-queued: var(--blue-400);--color-progressbar-seed-1: var(--black);--color-progressbar-seed-2: var(--white);--color-progressbar-seed-paused: var(--grey-500);--color-progressbar-verify: var(--yellow-300);--color-toolbar-background: var(--black);--progress-bar-shadow-3: 0}}@media (prefers-color-scheme: light){:root{--color-bg-hover: var(--nice-grey);--color-bg-odd: var(--white);--color-bg-popup: var(--white);--color-bg-primary: var(--white);--color-bg-selected: var(--blue-300);--color-bg-warn: #e4606d5b;--color-border-default: var(--default-border-light);--color-border-stark: var(--grey-500);--color-border-starkest: #d0d7de;--color-dialog-border: var(--nice-grey);--color-fg-disabled: var(--grey-500);--color-fg-error: var(--red-500);--color-fg-on-popup: var(--grey-900);--color-fg-port-closed: var(--red-500);--color-fg-port-open: var(--green-400);--color-fg-primary: #404040;--color-fg-secondary: var(--grey-500);--color-fg-selected: var(--nice-grey);--color-fg-tertiary: var(--grey-500);--color-fg-warn: #cf212e;--color-progressbar-fg-1: #303030;--color-progressbar-fg-2: #edefff;--color-progressbar-fg-3: #edefff;--color-progressbar-leech: var(--blue-100);--color-progressbar-magnet: var(--yellow-300);--color-progressbar-paused: var(--grey-200);--color-progressbar-queued: var(--blue-400);--color-progressbar-seed-1: var(--green-500);--color-progressbar-seed-2: var(--green-300);--color-progressbar-seed-paused: var(--grey-200);--color-progressbar-verify: var(--yellow-300);--progress-bar-shadow-1: 0;--progress-bar-shadow-2: 1px 1px #000;--progress-bar-shadow-3: 1px 1px #000}:root .contrast-more{--color-bg-even: var(--white);--color-bg-hover: var(--grey-40);--color-bg-selected: var(--blue-300);--color-bg-tabs: var(--white);--color-bg-warn: #cf6679;--color-border-default: var(--black);--color-border-stark: var(--black);--color-border-starkest: var(--black);--color-fg-disabled: var(--black);--color-fg-error: var(--red-500);--color-fg-on-popup: var(--black);--color-fg-port-closed: var(--red-500);--color-fg-port-open: var(--green-400);--color-fg-primary: var(--black);--color-fg-secondary: var(--black);--color-fg-selected: var(--white);--color-fg-tabs: var(--black);--color-fg-tertiary: var(--black);--color-fg-warn: var(--white);--color-progressbar-background-2: var(--white);--color-progressbar-fg-1: #fff;--color-progressbar-fg-2: #fff;--color-progressbar-fg-3: #000;--color-progressbar-leech: var(--blue-200);--color-progressbar-magnet: var(--yellow-300);--color-progressbar-paused: var(--grey-500);--color-progressbar-queued: var(--blue-400);--color-progressbar-seed-1: var(--black);--color-progressbar-seed-2: var(--white);--color-progressbar-seed-paused: var(--grey-500);--color-progressbar-verify: var(--yellow-300);--color-toolbar-background: var(--white);--progress-bar-shadow-1: 1px 1px #000;--progress-bar-shadow-3: 0}}@supports (background-color: Canvas){:root .contrast-less{--color-bg-odd: Canvas;--color-bg-primary: Canvas;--color-bg-popup: Canvas}}html,body{background-color:var(--color-bg-primary);color:var(--color-fg-primary);font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica,Arial,sans-serif,"Apple Color Emoji","Segoe UI Emoji",Segoe UI Symbol;height:100%;margin:0}img{border:0}a{color:var(--color-fg-primary);outline:0;text-decoration:underline}.hidden{display:none}#mainwin{display:flex;flex-direction:column;height:100%;position:relative}#mainwin>*{margin:0;padding:0}#mainwin .flexible-space{margin-right:auto}#mainwin-workarea{display:flex;flex:1;flex-direction:row;overflow:auto}.popup,.tabs-container{box-shadow:0 3px 6px -4px #0000001f,0 6px 16px #00000014,0 9px 28px 8px #0000000f;position:absolute}#mainwin-toolbar{align-items:center;background:var(--color-toolbar-background);border-bottom:1px solid var(--color-border-default);display:flex;flex-direction:row;height:var(--toolbar-height);margin:0;width:100%}#mainwin-toolbar button{background-color:transparent;background-position:center;background-repeat:no-repeat;border:0;border-radius:5px;cursor:pointer;height:var(--toolbar-height);margin-right:6px;user-select:none;-webkit-user-select:none;width:var(--toolbar-height)}#mainwin-toolbar button svg{stroke:var(--color-fg-primary)}#mainwin-toolbar button svg g path{fill:var(--color-fg-primary)}#mainwin-toolbar button:disabled{cursor:default}#mainwin-toolbar button:disabled svg{stroke:var(--color-fg-disabled)}#mainwin-toolbar button:disabled svg g path{fill:var(--color-fg-disabled)}#mainwin-toolbar>.toolbar-separator{border-left:1px solid var(--color-border-default);height:25px;margin:0 6px 0 0}#mainwin-toolbar :nth-last-child(2){border:0;flex-grow:1}.toolbar-icon{stroke:var(--color-fg-primary)}#toolbar-overflow{margin-right:4px}#toolbar-overflow svg{fill:var(--color-fg-primary);height:36px;width:36px}#toolbar-overflow.alt-speed-enabled{background-image:var(--image-alt-speed-enabled);background-position:bottom left;background-size:20px}#mainwin-statusbar{white-space:nowrap;align-items:center;background:var(--color-toolbar-background);border-bottom:1px solid var(--color-border-default);display:flex;flex-direction:row;height:30px;padding-left:5px}@media (width < 600px){#mainwin-statusbar :not(select):not(input):not(option):not(.flexible-space){display:none}}#mainwin-statusbar #torrent-search{width:100%;max-width:160px}#mainwin-statusbar select{width:70px}#mainwin-statusbar>*{margin-right:5px}#mainwin-statusbar .speed-container{display:inherit;align-items:inherit;flex-direction:inherit}#mainwin-statusbar .speed-container:not(:nth-child(1 of#mainwin-statusbar .speed-container)){width:100px}#mainwin-statusbar #speed-up-icon,#mainwin-statusbar #speed-dn-icon{fill:var(--color-fg-primary)}#mainwin-statusbar #speed-up-icon svg,#mainwin-statusbar #speed-dn-icon svg{width:20px}#mainwin-statusbar #speed-dn-label,#mainwin-statusbar #speed-up-label{text-align:right}#torrent-container{flex-grow:1;left:0;margin:0;overflow:auto;padding:0;right:0}#torrent-list{cursor:pointer;list-style-type:none;margin:0;padding:0;text-align:left;width:100%;user-select:none;-webkit-user-select:none}#torrent-list .torrent{border-bottom:1px solid var(--color-border-default)}#torrent-list .torrent:nth-child(2n){background-color:var(--color-bg-even)}#torrent-list .torrent:nth-child(odd){background-color:var(--color-bg-odd)}#torrent-list .torrent .icon{background-color:var(--color-fg-primary);background-position:center,top left;-webkit-mask-image:var(--mime-icon-url);-webkit-mask-repeat:no-repeat;mask-image:var(--mime-icon-url);mask-repeat:no-repeat}#torrent-list .torrent .icon[data-icon-multifile=true]{-webkit-mask-image:var(--mime-icon-url),var(--folder-image-url);-webkit-mask-position:top left,bottom right;-webkit-mask-repeat:no-repeat,no-repeat;-webkit-mask-size:16px,16px;mask-image:var(--mime-icon-url),var(--folder-image-url);mask-position:top left,bottom right;mask-repeat:no-repeat,no-repeat;mask-size:16px,16px}#torrent-list .torrent .icon[data-icon-mime-type=audio]{--mime-icon-url: var(--audio-image-url)}#torrent-list .torrent .icon[data-icon-mime-type=application]{--mime-icon-url: var(--app-image-url)}#torrent-list .torrent .icon[data-icon-mime-type=font]{--mime-icon-url: var(--font-image-url)}#torrent-list .torrent .icon[data-icon-mime-type=image]{--mime-icon-url: var(--image-image-url)}#torrent-list .torrent .icon[data-icon-mime-type=model]{--mime-icon-url: var(--package-image-url)}#torrent-list .torrent .icon[data-icon-mime-type=text]{--mime-icon-url: var(--text-image-url)}#torrent-list .torrent .icon[data-icon-mime-type=video]{--mime-icon-url: var(--video-image-url)}#torrent-list .torrent .torrent-name{font-weight:700;margin-bottom:2px;margin-top:2px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}#torrent-list .torrent .torrent-name.compact{font-size:1em;font-weight:400}#torrent-list .torrent .torrent-labels{font-size:small;font-weight:400;margin-bottom:2px;margin-top:2px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;padding:1px 0}#torrent-list .torrent .torrent-labels.compact{flex:1;font-size:small}#torrent-list .torrent .torrent-label{padding:0 8px;margin:0 2px;border-radius:1em;border:1px solid var(--color-border-default)}#torrent-list .torrent .torrent-progress-details.error,#torrent-list .torrent .torrent-peer-details.error{color:var(--color-fg-error)}#torrent-list .torrent .torrent-progress-details,#torrent-list .torrent .torrent-peer-details{font-size:small}#torrent-list .torrent.compact{--icon-size: 16px;align-items:center;display:flex;flex-direction:row-reverse}#torrent-list .torrent.compact .icon{-webkit-mask-size:var(--icon-size),calc(var(--icon-size) / 2);flex-shrink:0;height:var(--icon-size);mask-size:var(--icon-size),calc(var(--icon-size) / 2);width:var(--icon-size)}#torrent-list .torrent.compact .icon[data-icon-multifile=true]{--mime-icon-url: var(--folder-image-url)}#torrent-list .torrent.compact>*{margin:5px}#torrent-list .torrent:not(.compact){--icon-size: 32px;align-items:center;display:grid;grid-column-gap:12px;grid-template-areas:"icon name labels" "icon progress-text progress-text" "icon progressbar progressbar" "icon peers peers";grid-template-columns:var(--icon-size) auto 1fr;padding:6px 12px}#torrent-list .torrent:not(.compact) .icon{background-size:var(--icon-size),calc(var(--icon-size) / 2);grid-area:icon;height:var(--icon-size);width:var(--icon-size)}#torrent-list .torrent:not(.compact) .torrent-name{grid-area:name}#torrent-list .torrent:not(.compact) .torrent-labels{grid-area:labels}#torrent-list .torrent:not(.compact) .torrent-peer-details{grid-area:peers}#torrent-list .torrent:not(.compact) .torrent-progress{display:flex;flex-direction:row;grid-area:progressbar}#torrent-list .torrent:not(.compact) .torrent-progress-details{grid-area:progress-text}#torrent-list .torrent:not(.compact)>*{margin:1px 0}#torrent-list .torrent.paused{color:var(--color-fg-disabled)}#torrent-list .torrent.paused:not(.selected) .torrent-progress-bar{color:var(--color-fg-primary)}#torrent-list .torrent.paused .icon{background-color:var(--color-fg-disabled)}#torrent-list .torrent.selected{background-color:var(--color-bg-selected);color:var(--color-fg-selected)}#torrent-list .torrent.selected .icon{background-color:var(--color-fg-selected)}#torrent-list .icon{background-position:center;background-repeat:no-repeat}#torrent-list .torrent-pauseresume-button{background-position:center center;background-repeat:no-repeat;background-size:var(--pauseresume-size);margin-left:calc(var(--pauseresume-size) / 2);width:var(--pauseresume-size)}#torrent-list .torrent-pauseresume-button[data-action=pause]{background-image:var(--image-pause-circle-idle)}#torrent-list .torrent-pauseresume-button[data-action=pause]:active,#torrent-list .torrent-pauseresume-button[data-action=pause]:hover{background-image:var(--image-pause-circle-active)}#torrent-list .torrent-pauseresume-button[data-action=resume]{background-image:var(--image-play-circle-idle)}#torrent-list .torrent-pauseresume-button[data-action=resume]:active,#torrent-list .torrent-pauseresume-button[data-action=resume]:hover{background-image:var(--image-play-circle-active)}#torrent-list .torrent-progress-bar{font-size:14px;position:relative;border:1px solid var(--color-border-starkest);border-radius:3px;height:18px}#torrent-list .torrent-progress-bar.full{flex-grow:1;margin:2px 0}#torrent-list .torrent-progress-bar.compact{min-width:100px;width:10vw}#torrent-list .torrent-progress-bar.leech.queued:before{background:var(--color-progressbar-queued)}#torrent-list .torrent-progress-bar.leech:before{background:var(--color-progressbar-leech);color:var(--color-progressbar-fg-2);text-shadow:var(--progress-bar-shadow-2)}#torrent-list .torrent-progress-bar.magnet:before{background:var(--color-progressbar-magnet);color:#000}#torrent-list .torrent-progress-bar.seed.paused:before{background:var(--color-progressbar-seed-paused);color:var(--color-progressbar-fg-1);text-shadow:var(--progress-bar-shadow-1)}#torrent-list .torrent-progress-bar.seed:not(.paused):before{background:var(--color-progressbar-seed-1);color:var(--color-progressbar-fg-2);text-shadow:var(--progress-bar-shadow-2)}#torrent-list .torrent-progress-bar.seed:not(.paused):after{background:var(--color-progressbar-seed-2);color:var(--color-progressbar-fg-3);text-shadow:var(--progress-bar-shadow-3)}#torrent-list .torrent-progress-bar.seed.queued:before{background-color:var(--color-progressbar-seed-1)}#torrent-list .torrent-progress-bar.seed:before{background-color:var(--color-progressbar-seed-1);color:var(--color-progressbar-fg-2);text-shadow:var(--progress-bar-shadow-2)}#torrent-list .torrent-progress-bar.verify:before{background:var(--color-progressbar-verify);color:#000}#torrent-list .torrent-progress-bar.paused:before{background:var(--color-progressbar-paused);color:var(--color-progressbar-fg-1);text-shadow:var(--progress-bar-shadow-1)}#torrent-list .torrent-progress-bar:before,#torrent-list .torrent-progress-bar:after{content:attr(data-progress);height:100%;width:100%;position:absolute;border-radius:2px;text-align:center}#torrent-list .torrent-progress-bar:before{clip-path:polygon(0 0,var(--progress, 30%) 0,var(--progress, 30%) 100%,0 100%)}#torrent-list .torrent-progress-bar:after{clip-path:polygon(var(--progress, 30%) 0,100% 0,100% 100%,var(--progress, 30%) 100%)}@media (width < 600px){input[type=checkbox]{height:20px;width:20px}}@media (width < 600px){#inspector,#prefs-dialog{left:0}}@media (width >= 600px){#inspector,#prefs-dialog{border-left:1px solid var(--color-border-default);width:570px}}#prefs-dialog{background:var(--color-bg-primary);bottom:0;right:0;top:var(--popup-top);z-index:var(--z-index-popup)}#prefs-dialog .tabs-page{grid-column-gap:8px;grid-row-gap:5px;grid-template-columns:1fr 1fr;margin:20px}#prefs-dialog .tabs-page:not(.hidden){display:grid}#prefs-dialog .tabs-page .section-label{font-weight:700;grid-column:span 2;padding-bottom:5px}#prefs-dialog .tabs-page .section-label:not(:first-of-type){margin-top:20px}#prefs-dialog .alt-speed-section-label{background:transparent var(--image-alt-speed-enabled) no-repeat;background-position:left;background-position-y:4px;background-size:20px;padding-left:22px}#prefs-dialog :disabled,#prefs-dialog .disabled{color:var(--color-fg-disabled)}#prefs-dialog #alt-times-div,#prefs-dialog #autostart-div,#prefs-dialog #port-forwarding,#prefs-dialog #randomize-port,#prefs-dialog #suffix-div,#prefs-dialog #use-dht-div,#prefs-dialog #use-lpd-div,#prefs-dialog #use-pex-div,#prefs-dialog #utp-enabled,#prefs-dialog .alt-speed-label{grid-column:span 2}#prefs-dialog #default-trackers{height:300px}#prefs-dialog .blocklist-size-label,#prefs-dialog .blocklist-update-button,#prefs-dialog .register-handler-button,#prefs-dialog .port-status{grid-column:2/3}#prefs-dialog .blocklist-size-label{font-size:smaller}#prefs-dialog .blocklist-size-number{font-weight:bolder}#prefs-dialog .port-status-label{display:inline-block;font-weight:700;margin-left:5px}#prefs-dialog .port-status-label[data-open=true]{color:var(--color-fg-port-open)}#prefs-dialog .port-status-label[data-open=false]{color:var(--color-fg-port-closed)}#prefs-dialog #default-trackers,#prefs-dialog .default-trackers-label{grid-column:1/3}#prefs-dialog .alt-speed-label{font-size:smaller;margin:-10px 0 10px}#prefs-dialog.ui-tabs .ui-tabs-panel{padding:0;user-select:none;-webkit-user-select:none}.tabs-container{align-items:stretch;background:var(--color-bg-primary);bottom:0;display:flex;flex-direction:column;position:absolute;right:0;top:var(--popup-top);z-index:var(--z-index-popup)}@media (width < 600px){.tabs-container{left:0}}@media (width >= 600px){.tabs-container{width:550px}}.tabs-container-close{font-size:150%;cursor:pointer;background:var(--color-bg-primary);border:0;color:var(--color-fg-primary);position:absolute;padding:10px 16px}.tabs-buttons{align-self:center;background-color:var(--color-bg-tabs);border:1px solid var(--color-border-starkest);border-radius:6px;display:flex;margin:10px 0}.tabs-buttons button{appearance:none;border:1px solid transparent;border-radius:6px;color:var(--color-fg-primary);font-weight:400}.tabs-pages{box-sizing:border-box;flex:1;overflow-x:hidden;overflow-y:auto}@media (width < 600px){.tabs-pages{padding:0 8px 20px}}@media (width >= 600px){.tabs-pages{padding:0 20px 20px}}.tabs-button{background:none;border:1px solid transparent;font-size:14px;padding:3px 8px}.tabs-button:active,.tabs-button:checked,.tabs-button.selected{background-color:var(--color-bg-odd);border:1px solid var(--color-fg-primary);border-radius:5px}.inspector-info-page{font-size:14px;grid-column-gap:8px;grid-row-gap:8px;grid-template-columns:auto 1fr;margin:20px;padding:12px}.inspector-info-page:not(.hidden){display:grid}.inspector-info-page .section-label{font-size:16px;font-weight:700;grid-column:span 2;padding-bottom:5px}.inspector-info-page .section-label:not(:first-of-type){margin-top:20px}.inspector-info-page label{font-weight:500}.inspector-info-page :not(.section-label){overflow-x:hidden;text-overflow:ellipsis}.inspector-info-magnet button{background-color:var(--color-fg-primary);background-position:top;background-repeat:no-repeat;border:0;cursor:pointer;height:1rem;-webkit-mask:var(--image-magnet) no-repeat center/14px;mask:var(--image-magnet) no-repeat center/14px;vertical-align:middle;width:1rem}#inspector .tabs-button,#prefs-dialog .tabs-button{height:30px;margin:0;min-width:40px}#inspector-file-list{margin:0;padding:0}#inspector-file-list .inspector-torrent-file-list-entry{display:grid;grid-column-gap:5px;grid-template-areas:"check name priority" "blank1 info blank2";grid-template-columns:20px 1fr 65px;margin-bottom:4px;padding:5px}#inspector-file-list .inspector-torrent-file-list-entry:nth-child(2n){background-color:var(--color-bg-even)}#inspector-file-list .inspector-torrent-file-list-entry:nth-child(odd){background-color:var(--color-bg-odd)}#inspector-file-list .inspector-torrent-file-list-entry.skip{opacity:.5}#inspector-file-list .file-wanted-control{grid-area:check}#inspector-file-list .inspector-torrent-file-list-entry-name{color:var(--color-fg-primary);cursor:pointer;font-size:14px;grid-area:name;overflow-wrap:anywhere}#inspector-file-list .inspector-torrent-file-list-entry.skip>.inspector-torrent-file-list-entry-name{color:var(--color-fg-disabled)}#inspector-file-list .inspector-torrent-file-list-entry-progress{color:var(--color-fg-secondary);font-size:12px;grid-area:info}#inspector-file-list .single-file .inspector-torrent-file-list-entry>.file-wanted-control,#inspector-file-list .inspector-torrent-file-list-entry.complete>.file-wanted-control{cursor:default}#inspector-header{margin:8px 0}#torrent-inspector-name{font-size:large;font-weight:700}#inspector-tiers-list{color:var(--color-fg-primary);margin:0 10px;padding:0}#inspector-tiers-list .tier-list-row{display:grid;font-size:12px;grid-column-gap:8px;grid-row-gap:4px;padding:8px 12px}#inspector-tiers-list .tier-list-row:nth-child(2n of.tier-list-row){background-color:var(--color-bg-even)}#inspector-tiers-list .tier-list-row:nth-child(odd of.tier-list-row){background-color:var(--color-bg-odd)}#inspector-tiers-list .tier-list-torrent{color:var(--color-fg-primary);font-weight:bolder;overflow-x:hidden;padding-top:12px;padding-bottom:8px;text-overflow:ellipsis;white-space:nowrap}#inspector-tiers-list .tier-list-tracker{font-size:14px;font-weight:bolder;grid-column:span 2;padding-bottom:4px}#inspector-tiers-list .tier-announce,#inspector-tiers-list .tier-scrape,#inspector-tiers-list .tier-state{text-align:left}#inspector-tiers-list .tier-downloads,#inspector-tiers-list .tier-leechers,#inspector-tiers-list .tier-seeders{text-align:right}.peer-list{--table-border: 1px solid var(--color-border-default);border:var(--table-border);border-collapse:collapse;cursor:default;table-layout:fixed;text-align:left;width:100%}.peer-list td,.peer-list th{font-size:smaller;padding:5px}.peer-list td{border:var(--table-border);color:var(--color-fg-secondary)}.peer-list .torrent-row td{background:var(--color-bg-odd);color:var(--color-fg-primary);font-weight:bolder;overflow-x:hidden;padding:10px;text-overflow:ellipsis;white-space:nowrap}.peer-list .encryption[data-encrypted=true]{background-color:var(--color-border-starkest);-webkit-mask:var(--image-lock-fill) no-repeat center/14px;mask:var(--image-lock-fill) no-repeat center/14px;width:10px}.peer-list .peer-address,.peer-list .percent-done,.peer-list .speed-down,.peer-list .speed-up{text-align:right}.peer-list .percent-done{width:10%}@media (width < 600px){.peer-list .percent-done{width:12%}}.peer-list .speed-down,.peer-list .speed-up{width:15%}.peer-list .peer-address{width:25%;overflow-x:hidden;text-overflow:ellipsis}@media (width < 600px){.peer-list .peer-address{text-align:left;width:20%}}.peer-list .peer-app-name{overflow-x:hidden;text-overflow:ellipsis;white-space:nowrap}@media (width >= 600px){.peer-list .peer-app-name{width:20%}}.peer-list .status{cursor:pointer;width:10%}.file-priority-radiobox{grid-area:priority}.file-priority-radiobox>*{appearance:none;background-color:var(--color-border-starkest);background-position:center;background-repeat:no-repeat;background-size:10px,20px;border:1px solid var(--color-border-stark);border-radius:0;height:20px;margin:0;padding:0;width:20px}.file-priority-radiobox>.low{background-image:var(--image-chevron-dn);border-right-width:0}.file-priority-radiobox>.normal{background-image:var(--image-baseline)}.file-priority-radiobox>.high{background-image:var(--image-chevron-up);border-left-width:0}.file-priority-radiobox>.checked{background-color:var(--color-bg-hover)}.context-menu{background-color:var(--color-bg-primary);border-radius:5px;color:var(--color-fg-on-popup);padding:10px 5px;z-index:9999;user-select:none;-webkit-user-select:none}.context-menu .context-menuitem{font-size:13px;font-weight:400;list-style:none;padding:5px 15px}.context-menu .context-menuitem:hover:not(:disabled),.context-menu .context-menuitem:focus:not(:disabled){background-color:var(--color-bg-hover);border-radius:6px;cursor:pointer;font-weight:500}.context-menu .context-menuitem:disabled{color:var(--color-fg-disabled);cursor:none}.context-menu .context-menuitem.warning:hover{background-color:var(--color-bg-warn);color:var(--color-fg-warn)}.context-menu-separator{border-bottom:1px solid var(--color-fg-secondary);margin-bottom:10px;padding-bottom:10px}.overflow-menu{background:var(--color-bg-popup);border-radius:5px;color:var(--color-fg-on-popup);overflow:auto;padding:10px;right:0;margin:6px;top:50px;z-index:var(--z-index-popup)}@media (width < 600px){.overflow-menu{height:80vh}}.overflow-menu fieldset{border:0;display:block;margin:8px 0}.overflow-menu fieldset ul{margin:0;padding-left:0}.overflow-menu fieldset ul li{list-style-type:none}.overflow-menu fieldset ul a{cursor:pointer}.overflow-menu .table-row{align-items:center;border-radius:6px;display:flex;flex-direction:row;padding:3px 0}.overflow-menu legend{color:var(--color-fg-primary);font-weight:bolder;margin:12px 0 4px}.overflow-menu button,.overflow-menu label{color:var(--color-fg-primary);display:inline-flex;font-size:1em;width:100%}.overflow-menu button{background:transparent;border:0;cursor:pointer;display:block;padding:4px 0;text-align:left;text-decoration:none;width:150px}.overflow-menu .input-and-label{align-items:center;display:inline-flex;flex-direction:row}.overflow-menu #display-options,.overflow-menu #speed-options{display:flex;flex-direction:column}.overflow-menu #speed-options>.speed-up,.overflow-menu #speed-options>.speed-down{align-items:center;display:flex;flex-direction:row;padding:4px 0}.overflow-menu #speed-options>.speed-up>label,.overflow-menu #speed-options>.speed-down>label{overflow:hidden;width:80px}.overflow-menu #speed-options .alt-speed{display:grid;grid-column-gap:5px;grid-row-gap:5px;grid-template-areas:"check lb" "turtle values";grid-template-columns:22px 1fr;margin-bottom:4px}.overflow-menu #speed-options #alt-speed-check{grid-area:check}.overflow-menu #speed-options #alt-speed-check:checked~#alt-speed-image{background-image:var(--image-alt-speed-enabled);background-position:left;background-size:22px}.overflow-menu #speed-options #alt-speed-check:not(:checked)~#alt-speed-image{background-image:var(--image-alt-speed-disabled);background-size:22px}.overflow-menu #speed-options #alt-speed-image{background-position:center;background-repeat:no-repeat;grid-area:turtle}.overflow-menu #speed-options #alt-speed-label{grid-area:lb}.overflow-menu #speed-options #alt-speed-values-label{font-size:small;grid-area:values}@media (width < 600px){.dialog-buttons{padding-top:var(--dialog-logo-padding)}.dialog-container{opacity:96%;position:absolute;top:var(--popup-top);width:100%}.dialog-logo{padding-bottom:var(--dialog-logo-padding)}.dialog-window{align-items:center;display:flex;flex-direction:column}}@media (width >= 600px){.dialog-container{min-width:500px;position:absolute;top:calc(var(--popup-top) * 2)}.dialog-heading{grid-area:heading}.dialog-logo{grid-area:icon;padding-right:var(--dialog-logo-padding)}.dialog-window{background-color:var(--color-bg-popup);color:var(--color-fg-on-popup);display:grid;grid-column-gap:12px;grid-template-areas:"icon heading" "icon message" "icon workarea" "icon buttons";grid-template-columns:var(--logo-size) 1fr;padding:2px 12px}}.dialog-buttons{display:flex;float:right;grid-area:buttons;margin:10px 0 0;text-align:center}.dialog-buttons button{appearance:none;background:var(--color-bg-primary);border:1px solid var(--color-border-default);border-radius:5px;color:var(--color-fg-primary);margin-left:8px;padding:8px;text-decoration:none}.dialog-buttons-begin{flex-grow:1}.dialog-buttons-end{display:none}dialog{border:0}.dialog-container{color:var(--color-fg-primary);display:block;padding:0;z-index:var(--z-index-popup)}@media (width >= 600px){.dialog-container{border:0;border-radius:8px;max-width:50%}}.dialog-heading{align-items:center;display:flex;font-size:1.2em;font-weight:700;overflow-wrap:anywhere}.dialog-logo{background:transparent url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAEAAAABACAYAAACqaXHeAAASBklEQVR42u1aBXAcSbLN7h4Ws2XBMhqXmfGYmcleJi8fLcX+Y+a75UD5mJmZz7C7ZlsryaQRjjQa6Kn/XkVn3MRYY00fUyoyqtVTlZX5KjMru7rlv52cf9E5zX8EuCbggRe9yHsRuFbA77rrLndgYMDT8UL+VyUqeJeIOyDioY2w5b2q/Y1xVq1aFT3yyCPjZ5xxRvJZz3pW6vzzz0/A6Bh+8w42T/kcnNP8s4ChAgsaihX/zqpVTQ+ILP7oVVddet+99z749re+9Wu33377L2+66aaN11577eZrrrlmEDwM3nbjjTc+eccdd/zhbW9723ff8573rB144IHXvl+k+5O33dYkkFWLPqE9JewArp5jRzlG730SK+j84he9ju8fGYnFjohPTByR9f1DdjlOX6G+vr1nfLwx+qIXteTOO09y2WylPCE5kKrkFwrS3tMj7VNTMnPttRNOT8+k2bdvNGLMcNHznvKbm7eafH5r3nW35Zcte+rqH/4wU+kpDpu/JQA0/Ic//KF3wQUXFAX08fb2Z9ZnMmfDZ5cWjTnGKxYXR41JJWBQUkSmwJvB6cZG6YIh7a95jUSe9rSi8X2HssqM1vkNyN4zpZJJNjWZyOCgK9dc47pdXSJ790pc7BJby2bQL+M4OT8SGYk4zlbfdTcUEonfDI6Pfw6hkWcOAZf+JgCUCxswJjb8kpesaR8YuL/R8yTv+xIRsYwOJofGRZulfWDT1ia5dNpJ3HCD0/eCF4j4/kGXhgCU0CdRXy8TGzbI5Otfb9zubjO3Z480AiGAwCThYB6X3QkIWVxX8qWSbD/33Luv//GP7xIQk+7atWt9WYAiC608qPToo492JpPJK83nP/9Gt7m5l24wmUoVZ6ennQ4RpxQwlPEKItYLUtQwEpExtk1N0t/XR4ELex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uvjlosuuugX9Q31x0BICUq7q1ev5japFdZfpSj3e9YHjH2Cobnlr119uv9jjz3GRGtwFuCglDc4i3zeb3/72y+pBywEgGjH0884/cNdnV3XGDFFbGcRVnNPe9rTqORfmgtCnSmGjX3uJvigS775rW/y2K2E+y6eaLfgnJHf/O3Wxa3lMznDdnDr4IPI1K+tByEXmMefeNzBB0eycuVKO5nW5v9s0kPW9evXy69/82saz8RnjG/4wdUjNF4XteaPpXXAihUr3tHX33cbEC4SMJamy5YuY6HCDK6hEG7bqnJuGNbd9fCDBzdMphs2bpD0aJpFlo/fvPGx8T/+9Kc/fZqI7NHVrxmAsgGtcP2BRd2LLsLERbDX0tzi9Pb1Ss/iHoLAR1x+kPAP8wYaznKaX5/yYWvvnr0ysnuE/zMHFPlJ7wReRm7duvVFIyMj39XPfqsZKTWAcBi2roe6urrOo7v5ILx4cAEEs7eD3YJFzQH4GjGsIxaWXta3bMx812wJAI+8uN3xCZNnBgZewA78zR1Pj49h11qNBPvZctcPC0Clmj1Lly59K77AfF1jU2NMH3bgiiWUm8YenYtToWgVQ4xjW1J5H6UqQJTf47w8snd84zsu/vgugCdA4xPjP3ti4xNvAyA/gOGOGh8agCr9YniwuQhfcL0arn82kk03thpX3xqT1YCDEA2Zrx/v1zxWy3MUOTxpnpydmV2H4mctcsFaxvwCKx8aAJJThmgSfARCYgni/0jsEB0AoR4AxIxj+GVRTXJLQViiP69tS9LreciAOKgI47PgsemZ6cGhwaENIrIZPFpmkwmxsqFovgmorcc2tMzwZAK2QFToRS6FN4b0FwJBr5B/HnH+MlDC0f/of/Q/+h/9P04HqxoMB+PnAAAAAElFTkSuQmCC) top left no-repeat;height:var(--logo-size);width:var(--logo-size)}.dialog-message{grid-area:message;margin:10px 0 0}.dialog-window{background:var(--color-bg-primary);border-radius:8px;padding:var(--dialog-padding)}.dialog-workarea{display:flex;flex-direction:column;grid-area:workarea;margin:10px 0 0}.dialog-workarea>*{margin-bottom:5px}.about-dialog{max-width:initial}.about-dialog .dialog-workarea>*{margin-bottom:10px}.about-dialog-version-number{margin-left:4px}.about-dialog-version-checksum{font-size:small;font-style:italic;font-weight:400;margin-left:auto;padding-left:10px}.open-torrent input{margin-bottom:15px}.open-torrent input[type=file]{width:100%;box-sizing:border-box}.open-torrent #auto-start-label{margin-left:5px}.shortcuts-dialog table{border-collapse:collapse;width:100%}.shortcuts-dialog th,.shortcuts-dialog td{border:1px solid var(--color-border-stark);padding:5px 10px}#torrent-rename-name,#move-container #torrent-path{min-width:400px}.tabs-pages .content,.inspector-info-page .content,.statistics-dialog .content{column-gap:16px;display:grid;grid-row-gap:6px;grid-template-columns:auto 1fr;margin-top:4px}@media (width < 600px){.tabs-pages .content,.inspector-info-page .content,.statistics-dialog .content{margin:4px 0 16px}}@media (width >= 600px){.tabs-pages .content,.inspector-info-page .content,.statistics-dialog .content{margin:4px 16px 16px}}.tabs-pages .content div,.inspector-info-page .content div,.statistics-dialog .content div{word-break:break-word}.tabs-pages fieldset,.inspector-info-page fieldset,.statistics-dialog fieldset{border:0;margin:0;padding:0}.tabs-pages legend,.inspector-info-page legend,.statistics-dialog legend{font-weight:bolder;margin-bottom:4px}.tabs-pages span,.inspector-info-page span,.statistics-dialog span{overflow-wrap:anywhere}#free-space-text{display:inline-block;font-size:smaller;font-style:italic}.upload-div{display:none}
/*# sourceMappingURL=transmission-app.css.map */
diff --git a/web/public_html/transmission-app.css.map b/web/public_html/transmission-app.css.map
index c5fa6be25..a3a8db639 100644
--- a/web/public_html/transmission-app.css.map
+++ b/web/public_html/transmission-app.css.map
@@ -1,7 +1,7 @@
{
"version": 3,
"sources": ["../assets/css/transmission-app.scss"],
- "sourcesContent": ["/// MIXINS\n\n@mixin for-phone-only {\n @media (width < 600px) {\n @content;\n }\n}\n\n@mixin for-tablet-portrait-up {\n @media (width >= 600px) {\n @content;\n }\n}\n\n:root {\n /* z-index enum */\n --z-index-popup: 2;\n\n /* various dimensions */\n --dialog-logo-padding: calc(var(--dialog-padding) * 0.66);\n --dialog-padding: 20px;\n --logo-size: 64px;\n --pauseresume-size: 20px;\n --popup-top: 51px; // TODO: ugly that this is hardcoded\n --progressbar-border: 1px;\n --progressbar-height: 20px;\n --toolbar-height: 50px;\n\n /* colors related to torrent status */\n --black: #000;\n --blue-100: #51b3f7;\n --blue-200: #357aaa;\n --blue-300: #2c7fea;\n --blue-400: #1847d4;\n --dark-mode-black: #121212;\n --dark-mode-white: #c9d1d9;\n --default-accent-color-dark: #0c2d6b;\n --default-border-dark: #575757;\n --default-border-light: #aeaeae;\n --default-tinted: rgba(128, 128, 144, 0.125);\n --green-100: #26aa55;\n --green-300: #7cef99;\n --green-400: #67c87f;\n --green-500: #34dc70;\n --grey-200: #e1e4e8;\n --grey-40: #666;\n --grey-500: #828282;\n --grey-900: #191919;\n --nice-grey: #f8f8f8;\n --red-500: #d73a49;\n --white: #fff;\n --yellow-300: #ffea7f;\n\n /* ICONS -- see assets/img/README.md for sources and license details */\n /* Are you a designer? New icon PRs welcomed! */\n --image-alt-speed-disabled: url('../img/modern-tortoise.png');\n --image-alt-speed-enabled: url('../img/modern-tortoise-blue.png');\n --image-baseline: url('../img/horizontal-rule.svg');\n --image-chevron-dn: url('../img/chevron-down.svg');\n --image-chevron-up: url('../img/chevron-up.svg');\n --image-lock-fill: url('../img/lock-fill.svg');\n --image-magnet: url('../img/magnet.svg');\n --image-pause-circle-active: url('../img/pause-circle-active.svg');\n --image-pause-circle-idle: url('../img/pause-circle-idle.svg');\n --image-play-circle-active: url('../img/play-circle-active.svg');\n --image-play-circle-idle: url('../img/play-circle-idle.svg');\n\n --app-image-url: url('../img/box.svg');\n --audio-image-url: url('../img/music.svg');\n --folder-image-url: url('../img/folder.svg');\n --font-image-url: url('../img/type.svg');\n --image-image-url: url('../img/image.svg');\n --package-image-url: url('../img/package.svg');\n --text-image-url: url('../img/file-text.svg');\n --video-image-url: url('../img/film.svg');\n\n --progress: 100%;\n\n --color-bg-even: var(--default-tinted);\n --color-bg-tabs: var(--default-tinted);\n --color-fg-error: var(--red-500);\n --color-fg-port-closed: var(--red-500);\n --color-fg-port-open: var(--green-100);\n --color-progressbar-background-2: var(--green-400);\n --color-progressbar-leech: var(--blue-200);\n --color-progressbar-magnet: var(--yellow-300);\n --color-progressbar-paused: var(--grey-200);\n --color-progressbar-queued: var(--blue-400);\n --color-progressbar-verify: var(--yellow-300);\n --color-toolbar-background: var(--default-tinted);\n\n color-scheme: light dark;\n\n @media (prefers-color-scheme: dark) {\n --color-bg-hover: var(--grey-40);\n --color-bg-odd: var(--black);\n --color-bg-popup: var(--black);\n --color-bg-primary: var(--black);\n --color-bg-selected: var(--default-accent-color-dark);\n --color-bg-warn: #cf6679;\n --color-border-default: var(--default-border-dark);\n --color-border-stark: var(--dark-mode-white);\n --color-border-starkest: var(--grey-500);\n --color-fg-disabled: #808088;\n --color-fg-on-popup: var(--nice-grey);\n --color-fg-primary: var(--dark-mode-white);\n --color-fg-secondary: var(--nice-grey);\n --color-fg-selected: var(--dark-mode-white);\n --color-fg-tertiary: var(--grey-500);\n --color-fg-warn: var(--dark-mode-black);\n --color-progressbar-paused: var(--grey-500);\n --color-progressbar-seed-1: var(--green-100);\n --color-progressbar-seed-2: var(--green-400);\n --color-progressbar-seed-paused: var(--grey-500);\n\n .contrast-more {\n --color-bg-even: var(--black);\n --color-bg-hover: var(--grey-40);\n --color-bg-selected: var(--blue-300);\n --color-bg-tabs: var(--black);\n --color-bg-warn: #cf6679;\n --color-border-default: var(--white);\n --color-border-stark: var(--white);\n --color-border-starkest: var(--white);\n --color-fg-disabled: var(--white);\n --color-fg-error: var(--red-500);\n --color-fg-on-popup: var(--white);\n --color-fg-port-closed: var(--red-500);\n --color-fg-port-open: var(--green-100);\n --color-fg-primary: var(--white);\n --color-fg-secondary: var(--white);\n --color-fg-selected: var(--white);\n --color-fg-tabs: var(--white);\n --color-fg-tertiary: var(--white);\n --color-fg-warn: var(--black);\n --color-progressbar-background-2: var(--white);\n --color-progressbar-magnet: var(--yellow-300);\n --color-progressbar-paused: var(--grey-500);\n --color-progressbar-queued: var(--blue-400);\n --color-progressbar-seed-1: var(--black);\n --color-progressbar-seed-2: var(--white);\n --color-progressbar-seed-paused: var(--grey-500);\n --color-progressbar-verify: var(--yellow-300);\n --color-toolbar-background: var(--black);\n }\n }\n @media (prefers-color-scheme: light) {\n --color-bg-hover: var(--nice-grey);\n --color-bg-odd: var(--white);\n --color-bg-popup: var(--white);\n --color-bg-primary: var(--white);\n --color-bg-selected: var(--blue-300);\n --color-bg-warn: #e4606d5b;\n --color-border-default: var(--default-border-light);\n --color-border-stark: var(--grey-500);\n --color-border-starkest: #d0d7de;\n --color-dialog-border: var(--nice-grey);\n --color-fg-disabled: var(--grey-500);\n --color-fg-error: var(--red-500);\n --color-fg-on-popup: var(--grey-900);\n --color-fg-port-closed: var(--red-500);\n --color-fg-port-open: var(--green-400);\n --color-fg-primary: #404040;\n --color-fg-secondary: var(--grey-500);\n --color-fg-selected: var(--nice-grey);\n --color-fg-tertiary: var(--grey-500);\n --color-fg-warn: #cf212e;\n --color-progressbar-leech: var(--blue-100);\n --color-progressbar-magnet: var(--yellow-300);\n --color-progressbar-paused: var(--grey-200);\n --color-progressbar-queued: var(--blue-400);\n --color-progressbar-seed-1: var(--green-500);\n --color-progressbar-seed-2: var(--green-300);\n --color-progressbar-seed-paused: var(--grey-200);\n --color-progressbar-verify: var(--yellow-300);\n\n .contrast-more {\n --color-bg-even: var(--white);\n --color-bg-hover: var(--grey-40);\n --color-bg-selected: var(--blue-300);\n --color-bg-tabs: var(--white);\n --color-bg-warn: #cf6679;\n --color-border-default: var(--black);\n --color-border-stark: var(--black);\n --color-border-starkest: var(--black);\n --color-fg-disabled: var(--black);\n --color-fg-error: var(--red-500);\n --color-fg-on-popup: var(--black);\n --color-fg-port-closed: var(--red-500);\n --color-fg-port-open: var(--green-400);\n --color-fg-primary: var(--black);\n --color-fg-secondary: var(--black);\n --color-fg-selected: var(--white);\n --color-fg-tabs: var(--black);\n --color-fg-tertiary: var(--black);\n --color-fg-warn: var(--white);\n --color-progressbar-background-2: var(--white);\n --color-progressbar-leech: var(--blue-200);\n --color-progressbar-magnet: var(--yellow-300);\n --color-progressbar-paused: var(--grey-500);\n --color-progressbar-queued: var(--blue-400);\n --color-progressbar-seed-1: var(--black);\n --color-progressbar-seed-2: var(--white);\n --color-progressbar-seed-paused: var(--grey-500);\n --color-progressbar-verify: var(--yellow-300);\n --color-toolbar-background: var(--white);\n }\n }\n}\n\n/* If browser can support using 'system color' keywords (i.e. way to inherit browser colors), use these variables instead */\n@supports (background-color: Canvas) {\n :root {\n .contrast-less {\n --color-bg-odd: Canvas;\n --color-bg-primary: Canvas;\n --color-bg-popup: Canvas;\n }\n }\n}\n\nhtml,\nbody {\n background-color: var(--color-bg-primary);\n color: var(--color-fg-primary);\n font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica,\n Arial, sans-serif, 'Apple Color Emoji', 'Segoe UI Emoji', 'Segoe UI Symbol';\n height: 100%;\n margin: 0;\n}\n\nimg {\n border: 0;\n}\n\na {\n color: var(--color-fg-primary);\n outline: 0;\n text-decoration: underline;\n}\n\n.hidden {\n display: none;\n}\n\n#mainwin {\n display: flex;\n flex-direction: column;\n height: 100%;\n position: relative;\n\n > * {\n margin: 0;\n padding: 0;\n }\n\n .flexible-space {\n margin-right: auto;\n }\n}\n\n#mainwin-workarea {\n display: flex;\n flex: 1;\n flex-direction: row;\n overflow: auto;\n}\n\n.popup,\n.tabs-container {\n box-shadow:\n 0 3px 6px -4px rgba(0, 0, 0, 0.12),\n 0 6px 16px rgba(0, 0, 0, 0.08),\n 0 9px 28px 8px rgba(0, 0, 0, 0.06);\n position: absolute;\n}\n\n/// TOOLBAR\n\n#mainwin-toolbar {\n align-items: center;\n background: var(--color-toolbar-background);\n border-bottom: 1px solid var(--color-border-default);\n display: flex;\n flex-direction: row;\n height: var(--toolbar-height);\n margin: 0;\n width: 100%;\n\n button {\n background-color: transparent;\n background-position: center;\n background-repeat: no-repeat;\n border: 0;\n border-radius: 5px;\n cursor: pointer;\n height: var(--toolbar-height);\n margin-right: 6px;\n user-select: none;\n -webkit-user-select: none;\n width: var(--toolbar-height);\n\n svg {\n stroke: var(--color-fg-primary);\n\n g path {\n fill: var(--color-fg-primary);\n }\n }\n\n &:disabled {\n cursor: default;\n\n svg {\n stroke: var(--color-fg-disabled);\n\n g path {\n fill: var(--color-fg-disabled);\n }\n }\n }\n }\n\n > .toolbar-separator {\n border-left: 1px solid var(--color-border-default);\n height: 25px;\n margin: 0 6px 0 0;\n }\n\n :nth-last-child(2) {\n border: 0;\n flex-grow: 1;\n }\n}\n\n.toolbar-icon {\n stroke: var(--color-fg-primary);\n}\n\n#toolbar-overflow {\n margin-right: 4px;\n\n svg {\n fill: var(--color-fg-primary);\n height: 36px;\n width: 36px;\n }\n\n &.alt-speed-enabled {\n background-image: var(--image-alt-speed-enabled);\n background-position: bottom left;\n background-size: 20px;\n }\n}\n\n/// FILTERBAR\n\n#mainwin-statusbar {\n white-space: nowrap;\n align-items: center;\n background: var(--color-toolbar-background);\n border-bottom: 1px solid var(--color-border-default);\n display: flex;\n flex-direction: row;\n height: 30px;\n padding-left: 5px;\n\n @include for-phone-only {\n :not(select):not(input):not(option):not(.flexible-space) {\n display: none;\n }\n }\n\n #torrent-search {\n width: 100%;\n max-width: 160px;\n }\n\n select {\n width: 70px;\n }\n\n > * {\n margin-right: 5px;\n }\n\n .speed-container {\n display: inherit;\n align-items: inherit;\n flex-direction: inherit;\n\n &:not(:nth-child(1 of #mainwin-statusbar .speed-container)) {\n width: 100px;\n }\n }\n\n #speed-up-icon,\n #speed-dn-icon {\n fill: var(--color-fg-primary);\n\n svg {\n width: 20px;\n }\n }\n\n #speed-dn-label,\n #speed-up-label {\n text-align: right;\n }\n}\n\n/// TORRENT CONTAINER\n\n#torrent-container {\n flex-grow: 1;\n left: 0;\n margin: 0;\n overflow: auto;\n padding: 0;\n right: 0;\n}\n\n#torrent-list {\n cursor: pointer;\n list-style-type: none;\n margin: 0;\n padding: 0;\n text-align: left;\n width: 100%;\n user-select: none;\n -webkit-user-select: none;\n\n .torrent {\n border-bottom: 1px solid var(--color-border-default);\n\n &:nth-child(even) {\n background-color: var(--color-bg-even);\n }\n\n &:nth-child(odd) {\n background-color: var(--color-bg-odd);\n }\n\n .icon {\n // color the background svg fill\n background-color: var(--color-fg-primary);\n background-position:\n center,\n top left;\n -webkit-mask-image: var(--mime-icon-url);\n -webkit-mask-repeat: no-repeat;\n mask-image: var(--mime-icon-url);\n mask-repeat: no-repeat;\n\n &[data-icon-multifile='true'] {\n -webkit-mask-image: var(--mime-icon-url), var(--folder-image-url);\n -webkit-mask-position:\n top left,\n bottom right;\n -webkit-mask-repeat: no-repeat, no-repeat;\n -webkit-mask-size: 16px, 16px;\n mask-image: var(--mime-icon-url), var(--folder-image-url);\n mask-position:\n top left,\n bottom right;\n mask-repeat: no-repeat, no-repeat;\n mask-size: 16px, 16px;\n }\n\n &[data-icon-mime-type='audio'] {\n --mime-icon-url: var(--audio-image-url);\n }\n\n &[data-icon-mime-type='application'] {\n --mime-icon-url: var(--app-image-url);\n }\n\n &[data-icon-mime-type='font'] {\n --mime-icon-url: var(--font-image-url);\n }\n\n &[data-icon-mime-type='image'] {\n --mime-icon-url: var(--image-image-url);\n }\n\n &[data-icon-mime-type='model'] {\n --mime-icon-url: var(--package-image-url);\n }\n\n &[data-icon-mime-type='text'] {\n --mime-icon-url: var(--text-image-url);\n }\n\n &[data-icon-mime-type='video'] {\n --mime-icon-url: var(--video-image-url);\n }\n }\n\n .torrent-name {\n font-weight: bold;\n margin-bottom: 2px;\n margin-top: 2px;\n overflow: hidden;\n text-overflow: ellipsis;\n white-space: nowrap;\n\n &.compact {\n font-size: 1em;\n font-weight: normal;\n }\n }\n\n .torrent-labels {\n font-size: small;\n font-weight: normal;\n margin-bottom: 2px;\n margin-top: 2px;\n overflow: hidden;\n text-overflow: ellipsis;\n white-space: nowrap;\n padding: 1px 0;\n\n &.compact {\n flex: 1;\n font-size: small;\n }\n }\n\n .torrent-label {\n padding: 0 8px;\n margin: 0 2px;\n border-radius: 1em;\n border: 1px solid var(--color-border-default);\n }\n\n .torrent-progress-details,\n .torrent-peer-details {\n &.error {\n color: var(--color-fg-error);\n }\n }\n\n .torrent-progress-details,\n .torrent-peer-details {\n font-size: small;\n }\n\n &.compact {\n --icon-size: 16px;\n\n align-items: center;\n display: flex;\n flex-direction: row-reverse;\n\n .icon {\n -webkit-mask-size: var(--icon-size), calc(var(--icon-size) / 2);\n flex-shrink: 0;\n height: var(--icon-size);\n mask-size: var(--icon-size), calc(var(--icon-size) / 2);\n width: var(--icon-size);\n\n &[data-icon-multifile='true'] {\n --mime-icon-url: var(--folder-image-url);\n }\n }\n\n > * {\n margin: 5px;\n }\n }\n\n &:not(.compact) {\n --icon-size: 32px;\n align-items: center;\n display: grid;\n grid-column-gap: 12px;\n grid-template-areas:\n 'icon name labels'\n 'icon progress-text progress-text'\n 'icon progressbar progressbar'\n 'icon peers peers';\n grid-template-columns: var(--icon-size) auto 1fr;\n padding: 6px 12px;\n\n .icon {\n background-size: var(--icon-size), calc(var(--icon-size) / 2);\n grid-area: icon;\n height: var(--icon-size);\n width: var(--icon-size);\n }\n\n .torrent-name {\n grid-area: name;\n }\n\n .torrent-labels {\n grid-area: labels;\n }\n\n .torrent-peer-details {\n grid-area: peers;\n }\n\n .torrent-progress {\n display: flex;\n flex-direction: row;\n grid-area: progressbar;\n }\n\n .torrent-progress-details {\n grid-area: progress-text;\n }\n\n > * {\n margin: 1px 0;\n }\n }\n\n &.paused {\n color: var(--color-fg-disabled);\n\n .icon {\n background-color: var(--color-fg-disabled);\n }\n }\n\n &.selected {\n background-color: var(--color-bg-selected);\n color: var(--color-fg-selected);\n\n .icon {\n background-color: var(--color-fg-selected);\n }\n }\n }\n\n .icon {\n background-position: center;\n background-repeat: no-repeat;\n }\n\n .torrent-pauseresume-button {\n background-position: center center;\n background-repeat: no-repeat;\n background-size: var(--pauseresume-size);\n margin-left: calc(var(--pauseresume-size) / 2);\n width: var(--pauseresume-size);\n\n &[data-action='pause'] {\n background-image: var(--image-pause-circle-idle);\n\n &:active,\n &:hover {\n background-image: var(--image-pause-circle-active);\n }\n }\n\n &[data-action='resume'] {\n background-image: var(--image-play-circle-idle);\n\n &:active,\n &:hover {\n background-image: var(--image-play-circle-active);\n }\n }\n }\n\n .torrent-progress-bar {\n background-repeat: no-repeat;\n border-color: var(--color-border-starkest);\n border-radius: 3px;\n border-style: solid;\n border-width: 1px;\n height: calc(var(--progressbar-height) - var(--progressbar-border) * 2);\n\n &.full {\n flex-grow: 1;\n margin: 2px 0;\n }\n\n &.compact {\n min-width: 100px;\n width: 10vw;\n }\n\n &.leech {\n &.queued {\n background: linear-gradient(\n to right,\n var(--color-progressbar-queued) 0,\n var(--color-progressbar-queued) var(--progress, 30%),\n transparent var(--progress, 30%)\n ),\n no-repeat;\n }\n\n background: linear-gradient(\n to right,\n var(--color-progressbar-leech) 0,\n var(--color-progressbar-leech) var(--progress, 30%),\n transparent var(--progress, 30%)\n ),\n no-repeat;\n }\n\n &.magnet {\n background: linear-gradient(\n to right,\n var(--color-progressbar-magnet) 0,\n var(--color-progressbar-magnet) var(--progress, 30%),\n transparent var(--progress, 30%)\n ),\n no-repeat;\n }\n\n &.seed {\n &.paused {\n background-color: var(--color-progressbar-seed-paused);\n }\n\n &:not(.paused) {\n background: linear-gradient(\n to right,\n var(--color-progressbar-seed-1) 0,\n var(--color-progressbar-seed-1) var(--progress, 30%),\n var(--color-progressbar-seed-2) var(--progress, 30%)\n ),\n no-repeat;\n }\n\n &.queued {\n background-color: var(--color-progressbar-seed-paused);\n }\n }\n\n &.verify {\n background: linear-gradient(\n to right,\n var(--color-progressbar-verify) 0,\n var(--color-progressbar-verify) var(--progress, 30%),\n transparent var(--progress, 30%)\n ),\n no-repeat;\n }\n\n &.paused {\n background: linear-gradient(\n to right,\n var(--color-progressbar-paused) 0,\n var(--color-progressbar-paused) var(--progress, 30%),\n transparent var(--progress, 30%)\n ),\n no-repeat;\n }\n }\n}\n\n/// PREFERENCES DIALOG\n\n@include for-phone-only {\n input[type='checkbox'] {\n height: 20px;\n width: 20px;\n }\n}\n\n#inspector,\n#prefs-dialog {\n @include for-phone-only {\n left: 0;\n }\n @include for-tablet-portrait-up {\n border-left: 1px solid var(--color-border-default);\n width: 570px;\n }\n}\n\n#prefs-dialog {\n $background-color: var(--color-bg-primary);\n background: $background-color;\n bottom: 0;\n right: 0;\n top: var(--popup-top);\n z-index: var(--z-index-popup);\n\n .tabs-page {\n grid-column-gap: 8px;\n grid-row-gap: 5px;\n grid-template-columns: 1fr 1fr;\n margin: 20px;\n\n &:not(.hidden) {\n display: grid;\n }\n\n .section-label {\n font-weight: bold;\n grid-column: span 2;\n // margin-left: -20px;\n padding-bottom: 5px;\n\n &:not(:first-of-type) {\n margin-top: 20px;\n }\n }\n }\n\n .alt-speed-section-label {\n background: transparent var(--image-alt-speed-enabled) no-repeat;\n background-position: left;\n background-position-y: 4px;\n background-size: 20px;\n padding-left: 22px;\n }\n\n :disabled,\n .disabled {\n color: var(--color-fg-disabled);\n }\n\n #alt-times-div,\n #autostart-div,\n #port-forwarding,\n #randomize-port,\n #suffix-div,\n #use-dht-div,\n #use-lpd-div,\n #use-pex-div,\n #utp-enabled,\n .alt-speed-label {\n grid-column: span 2;\n }\n\n #default-trackers {\n height: 300px;\n }\n\n .blocklist-size-label,\n .blocklist-update-button,\n .register-handler-button,\n .port-status {\n grid-column: 2 / 3;\n }\n\n .blocklist-size-label {\n font-size: smaller;\n }\n\n .blocklist-size-number {\n font-weight: bolder;\n }\n\n .port-status-label {\n display: inline-block;\n font-weight: bold;\n margin-left: 5px;\n\n &[data-open='true'] {\n color: var(--color-fg-port-open);\n }\n\n &[data-open='false'] {\n color: var(--color-fg-port-closed);\n }\n }\n\n #default-trackers,\n .default-trackers-label {\n grid-column: 1 / 3;\n }\n\n .alt-speed-label {\n font-size: smaller;\n // nudge it up next to the section label\n margin: -10px 0 10px;\n }\n}\n\n#prefs-dialog.ui-tabs .ui-tabs-panel {\n padding: 0;\n user-select: none;\n -webkit-user-select: none;\n}\n\n/// TABS\n\n.tabs-container {\n align-items: stretch;\n background: var(--color-bg-primary);\n bottom: 0;\n display: flex;\n flex-direction: column;\n position: absolute;\n right: 0;\n top: var(--popup-top);\n z-index: var(--z-index-popup);\n\n @include for-phone-only {\n left: 0;\n }\n @include for-tablet-portrait-up {\n width: 550px;\n }\n}\n\n.tabs-container-close {\n font-size: 150%;\n cursor: pointer;\n background: var(--color-bg-primary);\n border: 0;\n color: var(--color-fg-primary);\n position: absolute;\n padding: 10px 16px;\n}\n\n.tabs-buttons {\n align-self: center;\n background-color: var(--color-bg-tabs);\n border: 1px solid var(--color-border-starkest);\n border-radius: 6px;\n display: flex;\n margin: 10px 0;\n\n button {\n appearance: none;\n border: 1px solid transparent;\n border-radius: 6px;\n color: var(--color-fg-primary);\n font-weight: 400;\n }\n}\n\n.tabs-pages {\n box-sizing: border-box;\n flex: 1;\n overflow-x: hidden;\n overflow-y: auto;\n\n @include for-phone-only {\n padding: 0 8px 20px;\n }\n @include for-tablet-portrait-up {\n padding: 0 20px 20px;\n }\n}\n\n.tabs-button {\n background: none;\n border: 1px solid transparent;\n font-size: 14px;\n padding: 3px 8px;\n\n &:active,\n &:checked,\n &.selected {\n background-color: var(--color-bg-odd);\n border: 1px solid var(--color-fg-primary);\n border-radius: 5px;\n }\n}\n\n/// INSPECTOR\n\n.inspector-info-page {\n font-size: 14px;\n // TODO: this is (mostly) copied from prefs-dialog.\n // can it be folded into a single set of rules?\n\n grid-column-gap: 8px;\n grid-row-gap: 8px;\n grid-template-columns: auto 1fr;\n margin: 20px;\n padding: 12px;\n\n &:not(.hidden) {\n display: grid;\n }\n\n .section-label {\n font-size: 16px;\n font-weight: bold;\n grid-column: span 2;\n padding-bottom: 5px;\n\n &:not(:first-of-type) {\n margin-top: 20px;\n }\n }\n\n label {\n font-weight: 500;\n }\n\n :not(.section-label) {\n // this section is not copied\n overflow-x: hidden;\n text-overflow: ellipsis;\n }\n}\n\n.inspector-info-magnet button {\n background-color: var(--color-fg-primary);\n\n background-position: top;\n background-repeat: no-repeat;\n border: 0;\n cursor: pointer;\n height: 1rem;\n -webkit-mask: var(--image-magnet) no-repeat center / 14px;\n mask: var(--image-magnet) no-repeat center / 14px;\n vertical-align: middle;\n width: 1rem;\n}\n\n#inspector,\n#prefs-dialog {\n .tabs-button {\n height: 30px;\n margin: 0;\n min-width: 40px;\n }\n}\n\n#inspector-file-list {\n margin: 0;\n padding: 0;\n\n .inspector-torrent-file-list-entry {\n display: grid;\n grid-column-gap: 5px;\n grid-template-areas:\n 'check name priority'\n 'blank1 info blank2';\n grid-template-columns: 20px 1fr 65px;\n margin-bottom: 4px;\n padding: 5px;\n\n &:nth-child(even) {\n background-color: var(--color-bg-even);\n }\n\n &:nth-child(odd) {\n background-color: var(--color-bg-odd);\n }\n\n &.skip {\n opacity: 0.5;\n }\n }\n\n .file-wanted-control {\n grid-area: check;\n }\n\n .inspector-torrent-file-list-entry-name {\n color: var(--color-fg-primary);\n cursor: pointer;\n font-size: 14px;\n grid-area: name;\n overflow: hidden;\n text-overflow: ellipsis;\n white-space: nowrap;\n }\n\n .inspector-torrent-file-list-entry.skip\n > .inspector-torrent-file-list-entry-name {\n color: var(--color-fg-disabled);\n }\n\n .inspector-torrent-file-list-entry-progress {\n color: var(--color-fg-secondary);\n font-size: 12px;\n grid-area: info;\n }\n\n .single-file .inspector-torrent-file-list-entry,\n .inspector-torrent-file-list-entry.complete {\n > .file-wanted-control {\n cursor: default;\n }\n }\n}\n\n#inspector-header {\n margin: 8px 0;\n}\n\n#torrent-inspector-name {\n font-size: large;\n font-weight: bold;\n}\n\n#inspector-tiers-list {\n color: var(--color-fg-primary);\n margin: 0 10px;\n padding: 0;\n\n .tier-list-row {\n display: grid;\n font-size: 12px;\n grid-column-gap: 8px;\n grid-row-gap: 4px;\n padding: 8px 12px;\n\n &:nth-child(even of .tier-list-row) {\n background-color: var(--color-bg-even);\n }\n\n &:nth-child(odd of .tier-list-row) {\n background-color: var(--color-bg-odd);\n }\n }\n\n .tier-list-torrent {\n color: var(--color-fg-primary);\n font-weight: bolder;\n overflow-x: hidden;\n padding-top: 12px;\n padding-bottom: 8px;\n text-overflow: ellipsis;\n white-space: nowrap;\n }\n\n .tier-list-tracker {\n font-size: 14px;\n font-weight: bolder;\n grid-column: span 2;\n padding-bottom: 4px;\n }\n\n .tier-announce,\n .tier-scrape,\n .tier-state {\n text-align: left;\n }\n\n .tier-downloads,\n .tier-leechers,\n .tier-seeders {\n text-align: right;\n }\n}\n\n// Peers Tab\n\n.peer-list {\n --table-border: 1px solid var(--color-border-default);\n\n border: var(--table-border);\n border-collapse: collapse;\n cursor: default;\n table-layout: fixed;\n text-align: left;\n width: 100%;\n\n td,\n th {\n font-size: smaller;\n padding: 5px;\n }\n\n td {\n border: var(--table-border);\n color: var(--color-fg-secondary);\n // padding: 5px 10px;\n }\n\n .torrent-row td {\n background: var(--color-bg-odd);\n color: var(--color-fg-primary);\n font-weight: bolder;\n overflow-x: hidden;\n padding: 10px;\n text-overflow: ellipsis;\n white-space: nowrap;\n }\n\n .encryption[data-encrypted='true'] {\n background-color: var(--color-border-starkest);\n -webkit-mask: var(--image-lock-fill) no-repeat center / 14px;\n mask: var(--image-lock-fill) no-repeat center / 14px;\n width: 10px;\n }\n\n .peer-address,\n .percent-done,\n .speed-down,\n .speed-up {\n text-align: right;\n }\n\n .percent-done {\n width: 10%;\n\n @include for-phone-only {\n width: 12%;\n }\n }\n\n .speed-down,\n .speed-up {\n width: 15%;\n }\n\n .peer-address {\n width: 25%;\n overflow-x: hidden;\n text-overflow: ellipsis;\n\n @include for-phone-only {\n text-align: left;\n width: 20%;\n }\n }\n\n .peer-app-name {\n overflow-x: hidden;\n text-overflow: ellipsis;\n white-space: nowrap;\n @include for-tablet-portrait-up {\n width: 20%;\n }\n }\n\n .status {\n cursor: pointer;\n width: 10%;\n }\n}\n\n/// FILE PRIORITY BUTTONS\n\n.file-priority-radiobox {\n grid-area: priority;\n\n > * {\n appearance: none;\n background-color: var(--color-border-starkest);\n background-position: center;\n background-repeat: no-repeat;\n background-size: 10px, 20px;\n border: 1px solid var(--color-border-stark);\n border-radius: 0;\n height: 20px;\n margin: 0;\n padding: 0;\n width: 20px;\n }\n\n > .low {\n background-image: var(--image-chevron-dn);\n border-right-width: 0;\n }\n\n > .normal {\n background-image: var(--image-baseline);\n }\n\n > .high {\n background-image: var(--image-chevron-up);\n border-left-width: 0;\n }\n\n //if input is checked then change the background color\n > .checked {\n background-color: var(--color-bg-hover);\n }\n}\n\n/// CONTEXT MENU\n\n.context-menu {\n background-color: var(--color-bg-primary);\n border-radius: 5px;\n color: var(--color-fg-on-popup);\n padding: 10px 5px;\n z-index: 9999;\n user-select: none;\n -webkit-user-select: none;\n\n .context-menuitem {\n font-size: 13px;\n font-weight: 400;\n list-style: none;\n padding: 5px 15px;\n\n &:hover:not(:disabled),\n &:focus:not(:disabled) {\n background-color: var(--color-bg-hover);\n border-radius: 6px;\n cursor: pointer;\n font-weight: 500;\n }\n\n &:disabled {\n color: var(--color-fg-disabled);\n cursor: none;\n }\n\n &.warning:hover {\n background-color: var(--color-bg-warn);\n color: var(--color-fg-warn);\n }\n }\n}\n\n.context-menu-separator {\n border-bottom: 1px solid var(--color-fg-secondary);\n margin-bottom: 10px;\n padding-bottom: 10px;\n}\n\n/// OVERFLOW MENU\n\n.overflow-menu {\n background: var(--color-bg-popup);\n border-radius: 5px;\n color: var(--color-fg-on-popup);\n overflow: auto;\n padding: 10px;\n\n right: 0;\n margin: 6px;\n top: 50px;\n z-index: var(--z-index-popup);\n\n @include for-phone-only {\n height: 80vh;\n }\n\n fieldset {\n border: 0;\n display: block;\n margin: 8px 0;\n\n ul {\n margin: 0;\n padding-left: 0;\n\n li {\n list-style-type: none;\n }\n\n a {\n cursor: pointer;\n }\n }\n }\n\n .table-row {\n align-items: center;\n border-radius: 6px;\n display: flex;\n flex-direction: row;\n padding: 3px 0;\n }\n\n legend {\n color: var(--color-fg-primary);\n font-weight: bolder;\n margin: 12px 0 4px;\n }\n\n button,\n label {\n color: var(--color-fg-primary);\n display: inline-flex;\n font-size: 1em;\n width: 100%;\n }\n\n button {\n background: transparent;\n border: 0;\n cursor: pointer;\n display: block;\n padding: 4px 0;\n text-align: left;\n text-decoration: none;\n width: 150px;\n }\n\n .input-and-label {\n align-items: center;\n display: inline-flex;\n flex-direction: row;\n }\n\n #display-options {\n display: flex;\n flex-direction: column;\n }\n\n #speed-options {\n display: flex;\n flex-direction: column;\n\n > .speed-up,\n > .speed-down {\n align-items: center;\n display: flex;\n flex-direction: row;\n padding: 4px 0;\n\n > label {\n overflow: hidden;\n width: 80px;\n }\n }\n\n .alt-speed {\n display: grid;\n grid-column-gap: 5px;\n grid-row-gap: 5px;\n grid-template-areas:\n 'check lb'\n 'turtle values';\n grid-template-columns: 22px 1fr;\n margin-bottom: 4px;\n }\n\n #alt-speed-check {\n grid-area: check;\n\n &:checked ~ #alt-speed-image {\n background-image: var(--image-alt-speed-enabled);\n background-position: left;\n background-size: 22px;\n }\n\n &:not(:checked) ~ #alt-speed-image {\n background-image: var(--image-alt-speed-disabled);\n background-size: 22px;\n }\n }\n\n #alt-speed-image {\n background-position: center;\n background-repeat: no-repeat;\n grid-area: turtle;\n }\n\n #alt-speed-label {\n grid-area: lb;\n }\n\n #alt-speed-values-label {\n font-size: small;\n grid-area: values;\n }\n }\n}\n\n/// DIALOGS\n\n@include for-phone-only {\n .dialog-buttons {\n padding-top: var(--dialog-logo-padding);\n }\n\n .dialog-container {\n opacity: 96%;\n position: absolute;\n top: var(--popup-top);\n width: 100%;\n }\n\n .dialog-logo {\n padding-bottom: var(--dialog-logo-padding);\n }\n\n .dialog-window {\n align-items: center;\n display: flex;\n flex-direction: column;\n }\n}\n\n@include for-tablet-portrait-up {\n .dialog-container {\n min-width: 500px;\n position: absolute;\n top: calc(var(--popup-top) * 2);\n }\n\n .dialog-heading {\n grid-area: heading;\n }\n\n .dialog-logo {\n grid-area: icon;\n padding-right: var(--dialog-logo-padding);\n }\n\n .dialog-window {\n background-color: var(--color-bg-popup);\n color: var(--color-fg-on-popup);\n display: grid;\n grid-column-gap: 12px;\n grid-template-areas:\n 'icon heading'\n 'icon message'\n 'icon workarea'\n 'icon buttons';\n grid-template-columns: var(--logo-size) 1fr;\n padding: 2px 12px;\n }\n}\n\n.dialog-buttons {\n display: flex;\n float: right;\n grid-area: buttons;\n margin: 10px 0 0;\n text-align: center;\n\n button {\n appearance: none;\n background: var(--color-bg-primary);\n border: 1px solid var(--color-border-default);\n border-radius: 5px;\n color: var(--color-fg-primary);\n margin-left: 8px;\n padding: 8px;\n text-decoration: none;\n }\n}\n\n.dialog-buttons-begin {\n flex-grow: 1;\n}\n\n.dialog-buttons-end {\n display: none;\n}\n\ndialog {\n border: 0;\n}\n\n.dialog-container {\n color: var(--color-fg-primary);\n display: block;\n padding: 0;\n z-index: var(--z-index-popup);\n\n @include for-tablet-portrait-up {\n border: 0;\n border-radius: 8px;\n max-width: 50%;\n }\n}\n\n.dialog-heading {\n align-items: center;\n display: flex;\n font-size: 1.2em;\n font-weight: bold;\n}\n\n.dialog-logo {\n background: transparent url('../img/logo.png') top left no-repeat;\n height: var(--logo-size);\n width: var(--logo-size);\n}\n\n.dialog-message {\n grid-area: message;\n margin: 10px 0 0;\n}\n\n.dialog-window {\n background: var(--color-bg-primary);\n border-radius: 8px;\n padding: var(--dialog-padding);\n}\n\n.dialog-workarea {\n display: flex;\n flex-direction: column;\n grid-area: workarea;\n margin: 10px 0 0;\n\n > * {\n margin-bottom: 5px;\n }\n}\n\n/// ABOUT DIALOG\n\n.about-dialog {\n max-width: initial;\n\n .dialog-workarea > * {\n margin-bottom: 10px;\n }\n}\n\n.about-dialog-version-number {\n margin-left: 4px;\n}\n\n.about-dialog-version-checksum {\n font-size: small;\n font-style: italic;\n font-weight: normal;\n margin-left: auto;\n padding-left: 10px;\n}\n\n/// OPEN TORRENT DIALOG\n.open-torrent {\n input {\n margin-bottom: 15px;\n\n &[type='file'] {\n width: 100%;\n box-sizing: border-box;\n }\n }\n\n #auto-start-label {\n margin-left: 5px;\n }\n}\n\n/// HOTKEYS DIALOG\n\n.shortcuts-dialog {\n table {\n border-collapse: collapse;\n width: 100%;\n }\n\n th,\n td {\n border: 1px solid var(--color-border-stark);\n padding: 5px 10px;\n }\n}\n\n/// RENAME DIALOG\n\n#torrent-rename-name {\n min-width: 400px;\n}\n\n/// SET-LOCATION DIALOG\n\n#move-container #torrent-path {\n min-width: 400px;\n}\n\n/// STATISTICS DIALOG\n\n.tabs-pages,\n.inspector-info-page,\n.statistics-dialog {\n .content {\n column-gap: 16px;\n display: grid;\n grid-row-gap: 6px;\n grid-template-columns: auto 1fr;\n margin-top: 4px;\n\n @include for-phone-only {\n margin: 4px 0 16px;\n }\n @include for-tablet-portrait-up {\n margin: 4px 16px 16px;\n }\n\n div {\n word-break: break-word;\n }\n }\n\n fieldset {\n border: 0;\n margin: 0;\n padding: 0;\n }\n\n legend {\n font-weight: bolder;\n margin-bottom: 4px;\n }\n}\n\n/// UPLOAD DIALOG\n\n#free-space-text {\n display: inline-block;\n font-size: smaller;\n font-style: italic;\n}\n\n.upload-div {\n display: none;\n}\n"],
- "mappings": "AAcA,MAEE,iBAAA,EAGA,uBAAA,KAAA,IAAA,kBAAA,EAAA,KACA,kBAAA,KACA,aAAA,KACA,oBAAA,KACA,aAAA,KACA,sBAAA,IACA,sBAAA,KACA,kBAAA,KAGA,SAAA,KACA,YAAA,QACA,YAAA,QACA,YAAA,QACA,YAAA,QACA,mBAAA,QACA,mBAAA,QACA,6BAAA,QACA,uBAAA,QACA,wBAAA,QACA,kBAAA,KAAA,GAAA,EAAA,GAAA,EAAA,GAAA,EAAA,MACA,aAAA,QACA,aAAA,QACA,aAAA,QACA,aAAA,QACA,YAAA,QACA,WAAA,KACA,YAAA,QACA,YAAA,QACA,aAAA,QACA,WAAA,QACA,SAAA,KACA,c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CA/uBF,WA+uBE,OAAA,CAhtBF,oBAgtBE,OAAA,CAzBA,kBAyBA,OACE,YAAA,OACA,cAAA,IAMJ,CAAA,gBACE,QAAA,aACA,UAAA,QACA,WAAA,OAGF,CAAA,WACE,QAAA",
+ "sourcesContent": ["/// MIXINS\n\n@mixin for-phone-only {\n @media (width < 600px) {\n @content;\n }\n}\n\n@mixin for-tablet-portrait-up {\n @media (width >= 600px) {\n @content;\n }\n}\n\n:root {\n /* z-index enum */\n --z-index-popup: 2;\n\n /* various dimensions */\n --dialog-logo-padding: calc(var(--dialog-padding) * 0.66);\n --dialog-padding: 20px;\n --logo-size: 64px;\n --pauseresume-size: 20px;\n --popup-top: 51px; // TODO: ugly that this is hardcoded\n --toolbar-height: 50px;\n\n /* colors related to torrent status */\n --black: #000;\n --blue-100: #51b3f7;\n --blue-200: #357aaa;\n --blue-300: #2c7fea;\n --blue-400: #1847d4;\n --dark-mode-black: #121212;\n --dark-mode-white: #c9d1d9;\n --default-accent-color-dark: #0c2d6b;\n --default-border-dark: #575757;\n --default-border-light: #aeaeae;\n --default-tinted: rgba(128, 128, 144, 0.125);\n --green-100: #26aa55;\n --green-300: #7cef99;\n --green-400: #67c87f;\n --green-500: #34dc70;\n --grey-200: #e1e4e8;\n --grey-40: #666;\n --grey-500: #828282;\n --grey-900: #191919;\n --nice-grey: #f8f8f8;\n --red-500: #d73a49;\n --white: #fff;\n --yellow-300: #ffea7f;\n\n /* ICONS -- see assets/img/README.md for sources and license details */\n /* Are you a designer? New icon PRs welcomed! */\n --image-alt-speed-disabled: url('../img/modern-tortoise.png');\n --image-alt-speed-enabled: url('../img/modern-tortoise-blue.png');\n --image-baseline: url('../img/horizontal-rule.svg');\n --image-chevron-dn: url('../img/chevron-down.svg');\n --image-chevron-up: url('../img/chevron-up.svg');\n --image-lock-fill: url('../img/lock-fill.svg');\n --image-magnet: url('../img/magnet.svg');\n --image-pause-circle-active: url('../img/pause-circle-active.svg');\n --image-pause-circle-idle: url('../img/pause-circle-idle.svg');\n --image-play-circle-active: url('../img/play-circle-active.svg');\n --image-play-circle-idle: url('../img/play-circle-idle.svg');\n\n --app-image-url: url('../img/box.svg');\n --audio-image-url: url('../img/music.svg');\n --folder-image-url: url('../img/folder.svg');\n --font-image-url: url('../img/type.svg');\n --image-image-url: url('../img/image.svg');\n --package-image-url: url('../img/package.svg');\n --text-image-url: url('../img/file-text.svg');\n --video-image-url: url('../img/film.svg');\n\n --progress: 100%;\n\n --color-bg-even: var(--default-tinted);\n --color-bg-tabs: var(--default-tinted);\n --color-fg-error: var(--red-500);\n --color-fg-port-closed: var(--red-500);\n --color-fg-port-open: var(--green-100);\n --color-progressbar-background-2: var(--green-400);\n --color-progressbar-leech: var(--blue-200);\n --color-progressbar-magnet: var(--yellow-300);\n --color-progressbar-paused: var(--grey-200);\n --color-progressbar-queued: var(--blue-400);\n --color-progressbar-verify: var(--yellow-300);\n --color-toolbar-background: var(--default-tinted);\n\n color-scheme: light dark;\n\n @media (prefers-color-scheme: dark) {\n --color-bg-hover: var(--grey-40);\n --color-bg-odd: var(--black);\n --color-bg-popup: var(--black);\n --color-bg-primary: var(--black);\n --color-bg-selected: var(--default-accent-color-dark);\n --color-bg-warn: #cf6679;\n --color-border-default: var(--default-border-dark);\n --color-border-stark: var(--dark-mode-white);\n --color-border-starkest: var(--grey-500);\n --color-fg-disabled: #808088;\n --color-fg-on-popup: var(--nice-grey);\n --color-fg-primary: var(--dark-mode-white);\n --color-fg-secondary: var(--nice-grey);\n --color-fg-selected: var(--dark-mode-white);\n --color-fg-tertiary: var(--grey-500);\n --color-fg-warn: var(--dark-mode-black);\n --color-progressbar-fg-1: #edefff;\n --color-progressbar-fg-2: #edefff;\n --color-progressbar-fg-3: #edefff;\n --color-progressbar-paused: var(--grey-500);\n --color-progressbar-seed-1: var(--green-100);\n --color-progressbar-seed-2: var(--green-400);\n --color-progressbar-seed-paused: var(--grey-500);\n --progress-bar-shadow-1: 1px 1px #000;\n --progress-bar-shadow-2: 1px 1px #000;\n --progress-bar-shadow-3: 1px 1px #000;\n\n .contrast-more {\n --color-bg-even: var(--black);\n --color-bg-hover: var(--grey-40);\n --color-bg-selected: var(--blue-300);\n --color-bg-tabs: var(--black);\n --color-bg-warn: #cf6679;\n --color-border-default: var(--white);\n --color-border-stark: var(--white);\n --color-border-starkest: var(--white);\n --color-fg-disabled: var(--white);\n --color-fg-error: var(--red-500);\n --color-fg-on-popup: var(--white);\n --color-fg-port-closed: var(--red-500);\n --color-fg-port-open: var(--green-100);\n --color-fg-primary: var(--white);\n --color-fg-secondary: var(--white);\n --color-fg-selected: var(--white);\n --color-fg-tabs: var(--white);\n --color-fg-tertiary: var(--white);\n --color-fg-warn: var(--black);\n --color-progressbar-fg-1: #fff;\n --color-progressbar-fg-2: #fff;\n --color-progressbar-fg-3: #000;\n --color-progressbar-background-2: var(--white);\n --color-progressbar-magnet: var(--yellow-300);\n --color-progressbar-paused: var(--grey-500);\n --color-progressbar-queued: var(--blue-400);\n --color-progressbar-seed-1: var(--black);\n --color-progressbar-seed-2: var(--white);\n --color-progressbar-seed-paused: var(--grey-500);\n --color-progressbar-verify: var(--yellow-300);\n --color-toolbar-background: var(--black);\n --progress-bar-shadow-3: 0;\n }\n }\n @media (prefers-color-scheme: light) {\n --color-bg-hover: var(--nice-grey);\n --color-bg-odd: var(--white);\n --color-bg-popup: var(--white);\n --color-bg-primary: var(--white);\n --color-bg-selected: var(--blue-300);\n --color-bg-warn: #e4606d5b;\n --color-border-default: var(--default-border-light);\n --color-border-stark: var(--grey-500);\n --color-border-starkest: #d0d7de;\n --color-dialog-border: var(--nice-grey);\n --color-fg-disabled: var(--grey-500);\n --color-fg-error: var(--red-500);\n --color-fg-on-popup: var(--grey-900);\n --color-fg-port-closed: var(--red-500);\n --color-fg-port-open: var(--green-400);\n --color-fg-primary: #404040;\n --color-fg-secondary: var(--grey-500);\n --color-fg-selected: var(--nice-grey);\n --color-fg-tertiary: var(--grey-500);\n --color-fg-warn: #cf212e;\n --color-progressbar-fg-1: #303030;\n --color-progressbar-fg-2: #edefff;\n --color-progressbar-fg-3: #edefff;\n --color-progressbar-leech: var(--blue-100);\n --color-progressbar-magnet: var(--yellow-300);\n --color-progressbar-paused: var(--grey-200);\n --color-progressbar-queued: var(--blue-400);\n --color-progressbar-seed-1: var(--green-500);\n --color-progressbar-seed-2: var(--green-300);\n --color-progressbar-seed-paused: var(--grey-200);\n --color-progressbar-verify: var(--yellow-300);\n --progress-bar-shadow-1: 0;\n --progress-bar-shadow-2: 1px 1px #000;\n --progress-bar-shadow-3: 1px 1px #000;\n\n .contrast-more {\n --color-bg-even: var(--white);\n --color-bg-hover: var(--grey-40);\n --color-bg-selected: var(--blue-300);\n --color-bg-tabs: var(--white);\n --color-bg-warn: #cf6679;\n --color-border-default: var(--black);\n --color-border-stark: var(--black);\n --color-border-starkest: var(--black);\n --color-fg-disabled: var(--black);\n --color-fg-error: var(--red-500);\n --color-fg-on-popup: var(--black);\n --color-fg-port-closed: var(--red-500);\n --color-fg-port-open: var(--green-400);\n --color-fg-primary: var(--black);\n --color-fg-secondary: var(--black);\n --color-fg-selected: var(--white);\n --color-fg-tabs: var(--black);\n --color-fg-tertiary: var(--black);\n --color-fg-warn: var(--white);\n --color-progressbar-background-2: var(--white);\n --color-progressbar-fg-1: #fff;\n --color-progressbar-fg-2: #fff;\n --color-progressbar-fg-3: #000;\n --color-progressbar-leech: var(--blue-200);\n --color-progressbar-magnet: var(--yellow-300);\n --color-progressbar-paused: var(--grey-500);\n --color-progressbar-queued: var(--blue-400);\n --color-progressbar-seed-1: var(--black);\n --color-progressbar-seed-2: var(--white);\n --color-progressbar-seed-paused: var(--grey-500);\n --color-progressbar-verify: var(--yellow-300);\n --color-toolbar-background: var(--white);\n --progress-bar-shadow-1: 1px 1px #000;\n --progress-bar-shadow-3: 0;\n }\n }\n}\n\n/* If browser can support using 'system color' keywords (i.e. way to inherit browser colors), use these variables instead */\n@supports (background-color: Canvas) {\n :root {\n .contrast-less {\n --color-bg-odd: Canvas;\n --color-bg-primary: Canvas;\n --color-bg-popup: Canvas;\n }\n }\n}\n\nhtml,\nbody {\n background-color: var(--color-bg-primary);\n color: var(--color-fg-primary);\n font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica,\n Arial, sans-serif, 'Apple Color Emoji', 'Segoe UI Emoji', 'Segoe UI Symbol';\n height: 100%;\n margin: 0;\n}\n\nimg {\n border: 0;\n}\n\na {\n color: var(--color-fg-primary);\n outline: 0;\n text-decoration: underline;\n}\n\n.hidden {\n display: none;\n}\n\n#mainwin {\n display: flex;\n flex-direction: column;\n height: 100%;\n position: relative;\n\n > * {\n margin: 0;\n padding: 0;\n }\n\n .flexible-space {\n margin-right: auto;\n }\n}\n\n#mainwin-workarea {\n display: flex;\n flex: 1;\n flex-direction: row;\n overflow: auto;\n}\n\n.popup,\n.tabs-container {\n box-shadow:\n 0 3px 6px -4px rgba(0, 0, 0, 0.12),\n 0 6px 16px rgba(0, 0, 0, 0.08),\n 0 9px 28px 8px rgba(0, 0, 0, 0.06);\n position: absolute;\n}\n\n/// TOOLBAR\n\n#mainwin-toolbar {\n align-items: center;\n background: var(--color-toolbar-background);\n border-bottom: 1px solid var(--color-border-default);\n display: flex;\n flex-direction: row;\n height: var(--toolbar-height);\n margin: 0;\n width: 100%;\n\n button {\n background-color: transparent;\n background-position: center;\n background-repeat: no-repeat;\n border: 0;\n border-radius: 5px;\n cursor: pointer;\n height: var(--toolbar-height);\n margin-right: 6px;\n user-select: none;\n -webkit-user-select: none;\n width: var(--toolbar-height);\n\n svg {\n stroke: var(--color-fg-primary);\n\n g path {\n fill: var(--color-fg-primary);\n }\n }\n\n &:disabled {\n cursor: default;\n\n svg {\n stroke: var(--color-fg-disabled);\n\n g path {\n fill: var(--color-fg-disabled);\n }\n }\n }\n }\n\n > .toolbar-separator {\n border-left: 1px solid var(--color-border-default);\n height: 25px;\n margin: 0 6px 0 0;\n }\n\n :nth-last-child(2) {\n border: 0;\n flex-grow: 1;\n }\n}\n\n.toolbar-icon {\n stroke: var(--color-fg-primary);\n}\n\n#toolbar-overflow {\n margin-right: 4px;\n\n svg {\n fill: var(--color-fg-primary);\n height: 36px;\n width: 36px;\n }\n\n &.alt-speed-enabled {\n background-image: var(--image-alt-speed-enabled);\n background-position: bottom left;\n background-size: 20px;\n }\n}\n\n/// FILTERBAR\n\n#mainwin-statusbar {\n white-space: nowrap;\n align-items: center;\n background: var(--color-toolbar-background);\n border-bottom: 1px solid var(--color-border-default);\n display: flex;\n flex-direction: row;\n height: 30px;\n padding-left: 5px;\n\n @include for-phone-only {\n :not(select):not(input):not(option):not(.flexible-space) {\n display: none;\n }\n }\n\n #torrent-search {\n width: 100%;\n max-width: 160px;\n }\n\n select {\n width: 70px;\n }\n\n > * {\n margin-right: 5px;\n }\n\n .speed-container {\n display: inherit;\n align-items: inherit;\n flex-direction: inherit;\n\n &:not(:nth-child(1 of #mainwin-statusbar .speed-container)) {\n width: 100px;\n }\n }\n\n #speed-up-icon,\n #speed-dn-icon {\n fill: var(--color-fg-primary);\n\n svg {\n width: 20px;\n }\n }\n\n #speed-dn-label,\n #speed-up-label {\n text-align: right;\n }\n}\n\n/// TORRENT CONTAINER\n\n#torrent-container {\n flex-grow: 1;\n left: 0;\n margin: 0;\n overflow: auto;\n padding: 0;\n right: 0;\n}\n\n#torrent-list {\n cursor: pointer;\n list-style-type: none;\n margin: 0;\n padding: 0;\n text-align: left;\n width: 100%;\n user-select: none;\n -webkit-user-select: none;\n\n .torrent {\n border-bottom: 1px solid var(--color-border-default);\n\n &:nth-child(even) {\n background-color: var(--color-bg-even);\n }\n\n &:nth-child(odd) {\n background-color: var(--color-bg-odd);\n }\n\n .icon {\n // color the background svg fill\n background-color: var(--color-fg-primary);\n background-position:\n center,\n top left;\n -webkit-mask-image: var(--mime-icon-url);\n -webkit-mask-repeat: no-repeat;\n mask-image: var(--mime-icon-url);\n mask-repeat: no-repeat;\n\n &[data-icon-multifile='true'] {\n -webkit-mask-image: var(--mime-icon-url), var(--folder-image-url);\n -webkit-mask-position:\n top left,\n bottom right;\n -webkit-mask-repeat: no-repeat, no-repeat;\n -webkit-mask-size: 16px, 16px;\n mask-image: var(--mime-icon-url), var(--folder-image-url);\n mask-position:\n top left,\n bottom right;\n mask-repeat: no-repeat, no-repeat;\n mask-size: 16px, 16px;\n }\n\n &[data-icon-mime-type='audio'] {\n --mime-icon-url: var(--audio-image-url);\n }\n\n &[data-icon-mime-type='application'] {\n --mime-icon-url: var(--app-image-url);\n }\n\n &[data-icon-mime-type='font'] {\n --mime-icon-url: var(--font-image-url);\n }\n\n &[data-icon-mime-type='image'] {\n --mime-icon-url: var(--image-image-url);\n }\n\n &[data-icon-mime-type='model'] {\n --mime-icon-url: var(--package-image-url);\n }\n\n &[data-icon-mime-type='text'] {\n --mime-icon-url: var(--text-image-url);\n }\n\n &[data-icon-mime-type='video'] {\n --mime-icon-url: var(--video-image-url);\n }\n }\n\n .torrent-name {\n font-weight: bold;\n margin-bottom: 2px;\n margin-top: 2px;\n overflow: hidden;\n text-overflow: ellipsis;\n white-space: nowrap;\n\n &.compact {\n font-size: 1em;\n font-weight: normal;\n }\n }\n\n .torrent-labels {\n font-size: small;\n font-weight: normal;\n margin-bottom: 2px;\n margin-top: 2px;\n overflow: hidden;\n text-overflow: ellipsis;\n white-space: nowrap;\n padding: 1px 0;\n\n &.compact {\n flex: 1;\n font-size: small;\n }\n }\n\n .torrent-label {\n padding: 0 8px;\n margin: 0 2px;\n border-radius: 1em;\n border: 1px solid var(--color-border-default);\n }\n\n .torrent-progress-details,\n .torrent-peer-details {\n &.error {\n color: var(--color-fg-error);\n }\n }\n\n .torrent-progress-details,\n .torrent-peer-details {\n font-size: small;\n }\n\n &.compact {\n --icon-size: 16px;\n\n align-items: center;\n display: flex;\n flex-direction: row-reverse;\n\n .icon {\n -webkit-mask-size: var(--icon-size), calc(var(--icon-size) / 2);\n flex-shrink: 0;\n height: var(--icon-size);\n mask-size: var(--icon-size), calc(var(--icon-size) / 2);\n width: var(--icon-size);\n\n &[data-icon-multifile='true'] {\n --mime-icon-url: var(--folder-image-url);\n }\n }\n\n > * {\n margin: 5px;\n }\n }\n\n &:not(.compact) {\n --icon-size: 32px;\n align-items: center;\n display: grid;\n grid-column-gap: 12px;\n grid-template-areas:\n 'icon name labels'\n 'icon progress-text progress-text'\n 'icon progressbar progressbar'\n 'icon peers peers';\n grid-template-columns: var(--icon-size) auto 1fr;\n padding: 6px 12px;\n\n .icon {\n background-size: var(--icon-size), calc(var(--icon-size) / 2);\n grid-area: icon;\n height: var(--icon-size);\n width: var(--icon-size);\n }\n\n .torrent-name {\n grid-area: name;\n }\n\n .torrent-labels {\n grid-area: labels;\n }\n\n .torrent-peer-details {\n grid-area: peers;\n }\n\n .torrent-progress {\n display: flex;\n flex-direction: row;\n grid-area: progressbar;\n }\n\n .torrent-progress-details {\n grid-area: progress-text;\n }\n\n > * {\n margin: 1px 0;\n }\n }\n\n &.paused {\n color: var(--color-fg-disabled);\n\n &:not(.selected) .torrent-progress-bar {\n color: var(--color-fg-primary);\n }\n\n .icon {\n background-color: var(--color-fg-disabled);\n }\n }\n\n &.selected {\n background-color: var(--color-bg-selected);\n color: var(--color-fg-selected);\n\n .icon {\n background-color: var(--color-fg-selected);\n }\n }\n }\n\n .icon {\n background-position: center;\n background-repeat: no-repeat;\n }\n\n .torrent-pauseresume-button {\n background-position: center center;\n background-repeat: no-repeat;\n background-size: var(--pauseresume-size);\n margin-left: calc(var(--pauseresume-size) / 2);\n width: var(--pauseresume-size);\n\n &[data-action='pause'] {\n background-image: var(--image-pause-circle-idle);\n\n &:active,\n &:hover {\n background-image: var(--image-pause-circle-active);\n }\n }\n\n &[data-action='resume'] {\n background-image: var(--image-play-circle-idle);\n\n &:active,\n &:hover {\n background-image: var(--image-play-circle-active);\n }\n }\n }\n\n .torrent-progress-bar {\n font-size: 14px;\n position: relative;\n border: 1px solid var(--color-border-starkest);\n border-radius: 3px;\n height: 18px;\n\n &.full {\n flex-grow: 1;\n margin: 2px 0;\n }\n\n &.compact {\n min-width: 100px;\n width: 10vw;\n }\n\n &.leech {\n &.queued::before {\n background: var(--color-progressbar-queued);\n }\n\n &::before {\n background: var(--color-progressbar-leech);\n color: var(--color-progressbar-fg-2);\n text-shadow: var(--progress-bar-shadow-2);\n }\n }\n\n &.magnet::before {\n background: var(--color-progressbar-magnet);\n color: #000;\n }\n\n &.seed {\n &.paused::before {\n background: var(--color-progressbar-seed-paused);\n color: var(--color-progressbar-fg-1);\n text-shadow: var(--progress-bar-shadow-1);\n }\n\n &:not(.paused) {\n &::before {\n background: var(--color-progressbar-seed-1);\n color: var(--color-progressbar-fg-2);\n text-shadow: var(--progress-bar-shadow-2);\n }\n\n &::after {\n background: var(--color-progressbar-seed-2);\n color: var(--color-progressbar-fg-3);\n text-shadow: var(--progress-bar-shadow-3);\n }\n }\n\n &.queued::before {\n background-color: var(--color-progressbar-seed-1);\n }\n\n &::before {\n background-color: var(--color-progressbar-seed-1);\n color: var(--color-progressbar-fg-2);\n text-shadow: var(--progress-bar-shadow-2);\n }\n }\n\n &.verify::before {\n background: var(--color-progressbar-verify);\n color: #000;\n }\n\n &.paused::before {\n background: var(--color-progressbar-paused);\n color: var(--color-progressbar-fg-1);\n text-shadow: var(--progress-bar-shadow-1);\n }\n\n &::before,\n &::after {\n content: attr(data-progress);\n height: 100%;\n width: 100%;\n position: absolute;\n border-radius: 2px;\n text-align: center;\n }\n\n &::before {\n clip-path: polygon(\n 0 0,\n var(--progress, 30%) 0,\n var(--progress, 30%) 100%,\n 0 100%\n );\n }\n\n &::after {\n clip-path: polygon(\n var(--progress, 30%) 0,\n 100% 0,\n 100% 100%,\n var(--progress, 30%) 100%\n );\n }\n }\n}\n\n/// PREFERENCES DIALOG\n\n@include for-phone-only {\n input[type='checkbox'] {\n height: 20px;\n width: 20px;\n }\n}\n\n#inspector,\n#prefs-dialog {\n @include for-phone-only {\n left: 0;\n }\n @include for-tablet-portrait-up {\n border-left: 1px solid var(--color-border-default);\n width: 570px;\n }\n}\n\n#prefs-dialog {\n $background-color: var(--color-bg-primary);\n background: $background-color;\n bottom: 0;\n right: 0;\n top: var(--popup-top);\n z-index: var(--z-index-popup);\n\n .tabs-page {\n grid-column-gap: 8px;\n grid-row-gap: 5px;\n grid-template-columns: 1fr 1fr;\n margin: 20px;\n\n &:not(.hidden) {\n display: grid;\n }\n\n .section-label {\n font-weight: bold;\n grid-column: span 2;\n // margin-left: -20px;\n padding-bottom: 5px;\n\n &:not(:first-of-type) {\n margin-top: 20px;\n }\n }\n }\n\n .alt-speed-section-label {\n background: transparent var(--image-alt-speed-enabled) no-repeat;\n background-position: left;\n background-position-y: 4px;\n background-size: 20px;\n padding-left: 22px;\n }\n\n :disabled,\n .disabled {\n color: var(--color-fg-disabled);\n }\n\n #alt-times-div,\n #autostart-div,\n #port-forwarding,\n #randomize-port,\n #suffix-div,\n #use-dht-div,\n #use-lpd-div,\n #use-pex-div,\n #utp-enabled,\n .alt-speed-label {\n grid-column: span 2;\n }\n\n #default-trackers {\n height: 300px;\n }\n\n .blocklist-size-label,\n .blocklist-update-button,\n .register-handler-button,\n .port-status {\n grid-column: 2 / 3;\n }\n\n .blocklist-size-label {\n font-size: smaller;\n }\n\n .blocklist-size-number {\n font-weight: bolder;\n }\n\n .port-status-label {\n display: inline-block;\n font-weight: bold;\n margin-left: 5px;\n\n &[data-open='true'] {\n color: var(--color-fg-port-open);\n }\n\n &[data-open='false'] {\n color: var(--color-fg-port-closed);\n }\n }\n\n #default-trackers,\n .default-trackers-label {\n grid-column: 1 / 3;\n }\n\n .alt-speed-label {\n font-size: smaller;\n // nudge it up next to the section label\n margin: -10px 0 10px;\n }\n}\n\n#prefs-dialog.ui-tabs .ui-tabs-panel {\n padding: 0;\n user-select: none;\n -webkit-user-select: none;\n}\n\n/// TABS\n\n.tabs-container {\n align-items: stretch;\n background: var(--color-bg-primary);\n bottom: 0;\n display: flex;\n flex-direction: column;\n position: absolute;\n right: 0;\n top: var(--popup-top);\n z-index: var(--z-index-popup);\n\n @include for-phone-only {\n left: 0;\n }\n @include for-tablet-portrait-up {\n width: 550px;\n }\n}\n\n.tabs-container-close {\n font-size: 150%;\n cursor: pointer;\n background: var(--color-bg-primary);\n border: 0;\n color: var(--color-fg-primary);\n position: absolute;\n padding: 10px 16px;\n}\n\n.tabs-buttons {\n align-self: center;\n background-color: var(--color-bg-tabs);\n border: 1px solid var(--color-border-starkest);\n border-radius: 6px;\n display: flex;\n margin: 10px 0;\n\n button {\n appearance: none;\n border: 1px solid transparent;\n border-radius: 6px;\n color: var(--color-fg-primary);\n font-weight: 400;\n }\n}\n\n.tabs-pages {\n box-sizing: border-box;\n flex: 1;\n overflow-x: hidden;\n overflow-y: auto;\n\n @include for-phone-only {\n padding: 0 8px 20px;\n }\n @include for-tablet-portrait-up {\n padding: 0 20px 20px;\n }\n}\n\n.tabs-button {\n background: none;\n border: 1px solid transparent;\n font-size: 14px;\n padding: 3px 8px;\n\n &:active,\n &:checked,\n &.selected {\n background-color: var(--color-bg-odd);\n border: 1px solid var(--color-fg-primary);\n border-radius: 5px;\n }\n}\n\n/// INSPECTOR\n\n.inspector-info-page {\n font-size: 14px;\n // TODO: this is (mostly) copied from prefs-dialog.\n // can it be folded into a single set of rules?\n\n grid-column-gap: 8px;\n grid-row-gap: 8px;\n grid-template-columns: auto 1fr;\n margin: 20px;\n padding: 12px;\n\n &:not(.hidden) {\n display: grid;\n }\n\n .section-label {\n font-size: 16px;\n font-weight: bold;\n grid-column: span 2;\n padding-bottom: 5px;\n\n &:not(:first-of-type) {\n margin-top: 20px;\n }\n }\n\n label {\n font-weight: 500;\n }\n\n :not(.section-label) {\n // this section is not copied\n overflow-x: hidden;\n text-overflow: ellipsis;\n }\n}\n\n.inspector-info-magnet button {\n background-color: var(--color-fg-primary);\n\n background-position: top;\n background-repeat: no-repeat;\n border: 0;\n cursor: pointer;\n height: 1rem;\n -webkit-mask: var(--image-magnet) no-repeat center / 14px;\n mask: var(--image-magnet) no-repeat center / 14px;\n vertical-align: middle;\n width: 1rem;\n}\n\n#inspector,\n#prefs-dialog {\n .tabs-button {\n height: 30px;\n margin: 0;\n min-width: 40px;\n }\n}\n\n#inspector-file-list {\n margin: 0;\n padding: 0;\n\n .inspector-torrent-file-list-entry {\n display: grid;\n grid-column-gap: 5px;\n grid-template-areas:\n 'check name priority'\n 'blank1 info blank2';\n grid-template-columns: 20px 1fr 65px;\n margin-bottom: 4px;\n padding: 5px;\n\n &:nth-child(even) {\n background-color: var(--color-bg-even);\n }\n\n &:nth-child(odd) {\n background-color: var(--color-bg-odd);\n }\n\n &.skip {\n opacity: 0.5;\n }\n }\n\n .file-wanted-control {\n grid-area: check;\n }\n\n .inspector-torrent-file-list-entry-name {\n color: var(--color-fg-primary);\n cursor: pointer;\n font-size: 14px;\n grid-area: name;\n overflow-wrap: anywhere;\n }\n\n .inspector-torrent-file-list-entry.skip\n > .inspector-torrent-file-list-entry-name {\n color: var(--color-fg-disabled);\n }\n\n .inspector-torrent-file-list-entry-progress {\n color: var(--color-fg-secondary);\n font-size: 12px;\n grid-area: info;\n }\n\n .single-file .inspector-torrent-file-list-entry,\n .inspector-torrent-file-list-entry.complete {\n > .file-wanted-control {\n cursor: default;\n }\n }\n}\n\n#inspector-header {\n margin: 8px 0;\n}\n\n#torrent-inspector-name {\n font-size: large;\n font-weight: bold;\n}\n\n#inspector-tiers-list {\n color: var(--color-fg-primary);\n margin: 0 10px;\n padding: 0;\n\n .tier-list-row {\n display: grid;\n font-size: 12px;\n grid-column-gap: 8px;\n grid-row-gap: 4px;\n padding: 8px 12px;\n\n &:nth-child(even of .tier-list-row) {\n background-color: var(--color-bg-even);\n }\n\n &:nth-child(odd of .tier-list-row) {\n background-color: var(--color-bg-odd);\n }\n }\n\n .tier-list-torrent {\n color: var(--color-fg-primary);\n font-weight: bolder;\n overflow-x: hidden;\n padding-top: 12px;\n padding-bottom: 8px;\n text-overflow: ellipsis;\n white-space: nowrap;\n }\n\n .tier-list-tracker {\n font-size: 14px;\n font-weight: bolder;\n grid-column: span 2;\n padding-bottom: 4px;\n }\n\n .tier-announce,\n .tier-scrape,\n .tier-state {\n text-align: left;\n }\n\n .tier-downloads,\n .tier-leechers,\n .tier-seeders {\n text-align: right;\n }\n}\n\n// Peers Tab\n\n.peer-list {\n --table-border: 1px solid var(--color-border-default);\n\n border: var(--table-border);\n border-collapse: collapse;\n cursor: default;\n table-layout: fixed;\n text-align: left;\n width: 100%;\n\n td,\n th {\n font-size: smaller;\n padding: 5px;\n }\n\n td {\n border: var(--table-border);\n color: var(--color-fg-secondary);\n // padding: 5px 10px;\n }\n\n .torrent-row td {\n background: var(--color-bg-odd);\n color: var(--color-fg-primary);\n font-weight: bolder;\n overflow-x: hidden;\n padding: 10px;\n text-overflow: ellipsis;\n white-space: nowrap;\n }\n\n .encryption[data-encrypted='true'] {\n background-color: var(--color-border-starkest);\n -webkit-mask: var(--image-lock-fill) no-repeat center / 14px;\n mask: var(--image-lock-fill) no-repeat center / 14px;\n width: 10px;\n }\n\n .peer-address,\n .percent-done,\n .speed-down,\n .speed-up {\n text-align: right;\n }\n\n .percent-done {\n width: 10%;\n\n @include for-phone-only {\n width: 12%;\n }\n }\n\n .speed-down,\n .speed-up {\n width: 15%;\n }\n\n .peer-address {\n width: 25%;\n overflow-x: hidden;\n text-overflow: ellipsis;\n\n @include for-phone-only {\n text-align: left;\n width: 20%;\n }\n }\n\n .peer-app-name {\n overflow-x: hidden;\n text-overflow: ellipsis;\n white-space: nowrap;\n @include for-tablet-portrait-up {\n width: 20%;\n }\n }\n\n .status {\n cursor: pointer;\n width: 10%;\n }\n}\n\n/// FILE PRIORITY BUTTONS\n\n.file-priority-radiobox {\n grid-area: priority;\n\n > * {\n appearance: none;\n background-color: var(--color-border-starkest);\n background-position: center;\n background-repeat: no-repeat;\n background-size: 10px, 20px;\n border: 1px solid var(--color-border-stark);\n border-radius: 0;\n height: 20px;\n margin: 0;\n padding: 0;\n width: 20px;\n }\n\n > .low {\n background-image: var(--image-chevron-dn);\n border-right-width: 0;\n }\n\n > .normal {\n background-image: var(--image-baseline);\n }\n\n > .high {\n background-image: var(--image-chevron-up);\n border-left-width: 0;\n }\n\n //if input is checked then change the background color\n > .checked {\n background-color: var(--color-bg-hover);\n }\n}\n\n/// CONTEXT MENU\n\n.context-menu {\n background-color: var(--color-bg-primary);\n border-radius: 5px;\n color: var(--color-fg-on-popup);\n padding: 10px 5px;\n z-index: 9999;\n user-select: none;\n -webkit-user-select: none;\n\n .context-menuitem {\n font-size: 13px;\n font-weight: 400;\n list-style: none;\n padding: 5px 15px;\n\n &:hover:not(:disabled),\n &:focus:not(:disabled) {\n background-color: var(--color-bg-hover);\n border-radius: 6px;\n cursor: pointer;\n font-weight: 500;\n }\n\n &:disabled {\n color: var(--color-fg-disabled);\n cursor: none;\n }\n\n &.warning:hover {\n background-color: var(--color-bg-warn);\n color: var(--color-fg-warn);\n }\n }\n}\n\n.context-menu-separator {\n border-bottom: 1px solid var(--color-fg-secondary);\n margin-bottom: 10px;\n padding-bottom: 10px;\n}\n\n/// OVERFLOW MENU\n\n.overflow-menu {\n background: var(--color-bg-popup);\n border-radius: 5px;\n color: var(--color-fg-on-popup);\n overflow: auto;\n padding: 10px;\n\n right: 0;\n margin: 6px;\n top: 50px;\n z-index: var(--z-index-popup);\n\n @include for-phone-only {\n height: 80vh;\n }\n\n fieldset {\n border: 0;\n display: block;\n margin: 8px 0;\n\n ul {\n margin: 0;\n padding-left: 0;\n\n li {\n list-style-type: none;\n }\n\n a {\n cursor: pointer;\n }\n }\n }\n\n .table-row {\n align-items: center;\n border-radius: 6px;\n display: flex;\n flex-direction: row;\n padding: 3px 0;\n }\n\n legend {\n color: var(--color-fg-primary);\n font-weight: bolder;\n margin: 12px 0 4px;\n }\n\n button,\n label {\n color: var(--color-fg-primary);\n display: inline-flex;\n font-size: 1em;\n width: 100%;\n }\n\n button {\n background: transparent;\n border: 0;\n cursor: pointer;\n display: block;\n padding: 4px 0;\n text-align: left;\n text-decoration: none;\n width: 150px;\n }\n\n .input-and-label {\n align-items: center;\n display: inline-flex;\n flex-direction: row;\n }\n\n #display-options {\n display: flex;\n flex-direction: column;\n }\n\n #speed-options {\n display: flex;\n flex-direction: column;\n\n > .speed-up,\n > .speed-down {\n align-items: center;\n display: flex;\n flex-direction: row;\n padding: 4px 0;\n\n > label {\n overflow: hidden;\n width: 80px;\n }\n }\n\n .alt-speed {\n display: grid;\n grid-column-gap: 5px;\n grid-row-gap: 5px;\n grid-template-areas:\n 'check lb'\n 'turtle values';\n grid-template-columns: 22px 1fr;\n margin-bottom: 4px;\n }\n\n #alt-speed-check {\n grid-area: check;\n\n &:checked ~ #alt-speed-image {\n background-image: var(--image-alt-speed-enabled);\n background-position: left;\n background-size: 22px;\n }\n\n &:not(:checked) ~ #alt-speed-image {\n background-image: var(--image-alt-speed-disabled);\n background-size: 22px;\n }\n }\n\n #alt-speed-image {\n background-position: center;\n background-repeat: no-repeat;\n grid-area: turtle;\n }\n\n #alt-speed-label {\n grid-area: lb;\n }\n\n #alt-speed-values-label {\n font-size: small;\n grid-area: values;\n }\n }\n}\n\n/// DIALOGS\n\n@include for-phone-only {\n .dialog-buttons {\n padding-top: var(--dialog-logo-padding);\n }\n\n .dialog-container {\n opacity: 96%;\n position: absolute;\n top: var(--popup-top);\n width: 100%;\n }\n\n .dialog-logo {\n padding-bottom: var(--dialog-logo-padding);\n }\n\n .dialog-window {\n align-items: center;\n display: flex;\n flex-direction: column;\n }\n}\n\n@include for-tablet-portrait-up {\n .dialog-container {\n min-width: 500px;\n position: absolute;\n top: calc(var(--popup-top) * 2);\n }\n\n .dialog-heading {\n grid-area: heading;\n }\n\n .dialog-logo {\n grid-area: icon;\n padding-right: var(--dialog-logo-padding);\n }\n\n .dialog-window {\n background-color: var(--color-bg-popup);\n color: var(--color-fg-on-popup);\n display: grid;\n grid-column-gap: 12px;\n grid-template-areas:\n 'icon heading'\n 'icon message'\n 'icon workarea'\n 'icon buttons';\n grid-template-columns: var(--logo-size) 1fr;\n padding: 2px 12px;\n }\n}\n\n.dialog-buttons {\n display: flex;\n float: right;\n grid-area: buttons;\n margin: 10px 0 0;\n text-align: center;\n\n button {\n appearance: none;\n background: var(--color-bg-primary);\n border: 1px solid var(--color-border-default);\n border-radius: 5px;\n color: var(--color-fg-primary);\n margin-left: 8px;\n padding: 8px;\n text-decoration: none;\n }\n}\n\n.dialog-buttons-begin {\n flex-grow: 1;\n}\n\n.dialog-buttons-end {\n display: none;\n}\n\ndialog {\n border: 0;\n}\n\n.dialog-container {\n color: var(--color-fg-primary);\n display: block;\n padding: 0;\n z-index: var(--z-index-popup);\n\n @include for-tablet-portrait-up {\n border: 0;\n border-radius: 8px;\n max-width: 50%;\n }\n}\n\n.dialog-heading {\n align-items: center;\n display: flex;\n font-size: 1.2em;\n font-weight: bold;\n overflow-wrap: anywhere;\n}\n\n.dialog-logo {\n background: transparent url('../img/logo.png') top left no-repeat;\n height: var(--logo-size);\n width: var(--logo-size);\n}\n\n.dialog-message {\n grid-area: message;\n margin: 10px 0 0;\n}\n\n.dialog-window {\n background: var(--color-bg-primary);\n border-radius: 8px;\n padding: var(--dialog-padding);\n}\n\n.dialog-workarea {\n display: flex;\n flex-direction: column;\n grid-area: workarea;\n margin: 10px 0 0;\n\n > * {\n margin-bottom: 5px;\n }\n}\n\n/// ABOUT DIALOG\n\n.about-dialog {\n max-width: initial;\n\n .dialog-workarea > * {\n margin-bottom: 10px;\n }\n}\n\n.about-dialog-version-number {\n margin-left: 4px;\n}\n\n.about-dialog-version-checksum {\n font-size: small;\n font-style: italic;\n font-weight: normal;\n margin-left: auto;\n padding-left: 10px;\n}\n\n/// OPEN TORRENT DIALOG\n.open-torrent {\n input {\n margin-bottom: 15px;\n\n &[type='file'] {\n width: 100%;\n box-sizing: border-box;\n }\n }\n\n #auto-start-label {\n margin-left: 5px;\n }\n}\n\n/// HOTKEYS DIALOG\n\n.shortcuts-dialog {\n table {\n border-collapse: collapse;\n width: 100%;\n }\n\n th,\n td {\n border: 1px solid var(--color-border-stark);\n padding: 5px 10px;\n }\n}\n\n/// RENAME DIALOG\n\n#torrent-rename-name {\n min-width: 400px;\n}\n\n/// SET-LOCATION DIALOG\n\n#move-container #torrent-path {\n min-width: 400px;\n}\n\n/// STATISTICS DIALOG\n\n.tabs-pages,\n.inspector-info-page,\n.statistics-dialog {\n .content {\n column-gap: 16px;\n display: grid;\n grid-row-gap: 6px;\n grid-template-columns: auto 1fr;\n margin-top: 4px;\n\n @include for-phone-only {\n margin: 4px 0 16px;\n }\n @include for-tablet-portrait-up {\n margin: 4px 16px 16px;\n }\n\n div {\n word-break: break-word;\n }\n }\n\n fieldset {\n border: 0;\n margin: 0;\n padding: 0;\n }\n\n legend {\n font-weight: bolder;\n margin-bottom: 4px;\n }\n\n span {\n overflow-wrap: anywhere;\n }\n}\n\n/// UPLOAD DIALOG\n\n#free-space-text {\n display: inline-block;\n font-size: smaller;\n font-style: italic;\n}\n\n.upload-div {\n display: none;\n}\n"],
+ "mappings": "AAcA,MAEE,iBAAA,EAGA,uBAAA,KAAA,IAAA,kBAAA,EAAA,KACA,kBAAA,KACA,aAAA,KACA,oBAAA,KACA,aAAA,KACA,kBAAA,KAGA,SAAA,KACA,YAAA,QACA,YAAA,QACA,YAAA,QACA,YAAA,QACA,mBAAA,QACA,mBAAA,QACA,6BAAA,QACA,uBAAA,QACA,wBAAA,QACA,kBAAA,KAAA,GAAA,EAAA,GAAA,EAAA,GAAA,EAAA,MACA,aAAA,QACA,aAAA,QACA,aAAA,QACA,aAAA,QACA,YAAA,QACA,WAAA,KACA,YAAA,QACA,YAAA,QACA,aAAA,QACA,WAAA,QACA,SAAA,KACA,cAAA,QAIA,4BAAA,g2BACA,2BAAA,ooCACA,kBAAA,gUACA,oBAAA,gTACA,oBAAA,+SACA,mBAAA,0VACA,gBAAA,8UACA,6BAAA,w1HACA,2BAAA,st+DACA,4BAAA,gnIACA,0BAAA,on5CAEA,iBAAA,igBACA,mBAAA,kWACA,oBAAA,4VACA,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qtBE,CAAA,QAAA,CAtrBF,oBAsrBE,CAAA,QAAA,CAAA,kBAAA,CAAA,QAnpDF,OA8pDM,IAAA,KAAA,MAGF,CAnuBJ,WAmuBI,CAdF,QAcE,IAAA,CApsBJ,oBAosBI,CAdF,QAcE,IAAA,CAdF,kBAcE,CAdF,QAcE,IACE,WAAA,WAIJ,CAxuBF,WAwuBE,SAAA,CAzsBF,oBAysBE,SAAA,CAnBA,kBAmBA,SACE,OAAA,EAvqDJ,OAwqDI,EAxqDJ,QAyqDI,EAGF,CA9uBF,WA8uBE,OAAA,CA/sBF,oBA+sBE,OAAA,CAzBA,kBAyBA,OACE,YAAA,OACA,cAAA,IAGF,CAnvBF,WAmvBE,KAAA,CAptBF,oBAotBE,KAAA,CA9BA,kBA8BA,KACE,cAAA,SAMJ,CAAA,gBACE,QAAA,aACA,UAAA,QACA,WAAA,OAGF,CAAA,WACE,QAAA",
"names": []
}
diff --git a/web/public_html/transmission-app.js b/web/public_html/transmission-app.js
index 059098832..17f680281 100644
--- a/web/public_html/transmission-app.js
+++ b/web/public_html/transmission-app.js
@@ -1,4 +1,4 @@
-(()=>{var Vt=Object.create;var et=Object.defineProperty;var Nt=Object.getOwnPropertyDescriptor;var _t=Object.getOwnPropertyNames;var Dt=Object.getPrototypeOf,Et=Object.prototype.hasOwnProperty;var Ht=(s,e)=>()=>(e||s((e={exports:{}}).exports,e),e.exports);var Jt=(s,e,t,r)=>{if(e&&typeof e=="object"||typeof e=="function")for(let o of _t(e))!Et.call(s,o)&&o!==t&&et(s,o,{get:()=>e[o],enumerable:!(r=Nt(e,o))||r.enumerable});return s};var zt=(s,e,t)=>(t=s!=null?Vt(Dt(s)):{},Jt(e||!s||!s.__esModule?et(t,"default",{value:s,enumerable:!0}):t,s));var Ot=Ht((q,M)=>{var jt=200,Pe="__lodash_hash_undefined__",Ie=1,ut=2,pt=9007199254740991,de="[object Arguments]",De="[object Array]",Mt="[object AsyncFunction]",mt="[object Boolean]",bt="[object Date]",ht="[object Error]",It="[object Function]",Pt="[object GeneratorFunction]",ge="[object Map]",Ct="[object Number]",Kt="[object Null]",j="[object Object]",tt="[object Promise]",$t="[object Proxy]",ft="[object RegExp]",ue="[object Set]",At="[object String]",qt="[object Symbol]",er="[object Undefined]",Ee="[object WeakMap]",Gt="[object ArrayBuffer]",pe="[object DataView]",tr="[object Float32Array]",rr="[object Float64Array]",sr="[object Int8Array]",or="[object Int16Array]",nr="[object Int32Array]",ir="[object Uint8Array]",ar="[object Uint8ClampedArray]",cr="[object Uint16Array]",lr="[object Uint32Array]",dr=/[\\^$.*+?()[\]{}|]/g,gr=/^\[object .+?Constructor\]$/,ur=/^(?:0|[1-9]\d*)$/,Z={};Z[tr]=Z[rr]=Z[sr]=Z[or]=Z[nr]=Z[ir]=Z[ar]=Z[cr]=Z[lr]=!0;Z[de]=Z[De]=Z[Gt]=Z[mt]=Z[pe]=Z[bt]=Z[ht]=Z[It]=Z[ge]=Z[Ct]=Z[j]=Z[ft]=Z[ue]=Z[At]=Z[Ee]=!1;var Bt=typeof global=="object"&&global&&global.Object===Object&&global,pr=typeof self=="object"&&self&&self.Object===Object&&self,T=Bt||pr||Function("return this")(),vt=typeof q=="object"&&q&&!q.nodeType&&q,rt=vt&&typeof M=="object"&&M&&!M.nodeType&&M,yt=rt&&rt.exports===vt,Ve=yt&&Bt.process,st=function(){try{return Ve&&Ve.binding&&Ve.binding("util")}catch{}}(),ot=st&&st.isTypedArray;function mr(s,e){for(var t=-1,r=s==null?0:s.length,o=0,n=[];++t-1}function Er(s,e){var t=this.__data__,r=fe(t,s);return r<0?(++this.size,t.push([s,e])):t[r][1]=e,this}Y.prototype.clear=Vr;Y.prototype.delete=Nr;Y.prototype.get=_r;Y.prototype.has=Dr;Y.prototype.set=Er;function E(s){var e=-1,t=s==null?0:s.length;for(this.clear();++ea))return!1;var c=n.get(s);if(c&&n.get(e))return c==e;var u=-1,g=!0,d=t&ut?new be:void 0;for(n.set(s,e),n.set(e,s);++u-1&&s%1==0&&s-1&&s%1==0&&s<=pt}function Ut(s){var e=typeof s;return s!=null&&(e=="object"||e=="function")}function re(s){return s!=null&&typeof s=="object"}var kt=ot?Cr(ot):as;function Gs(s){return fs(s)?ss(s):cs(s)}function Bs(){return[]}function vs(){return!1}M.exports=As});var le=class s extends EventTarget{constructor(){super(),this.actions=Object.seal({"deselect-all":{enabled:!1,shortcut:"D",text:"Deselect all"},"move-bottom":{enabled:!1,text:"Move to the back of the queue"},"move-down":{enabled:!1,text:"Move down in the queue"},"move-top":{enabled:!1,text:"Move to the front of the queue"},"move-up":{enabled:!1,text:"Move up in the queue"},"open-torrent":{enabled:!0,shortcut:"O",text:"Open torrent\u2026"},"pause-all-torrents":{enabled:!1,text:"Pause all"},"pause-selected-torrents":{enabled:!1,shortcut:"U",text:"Pause"},"reannounce-selected-torrents":{enabled:!1,text:"Ask tracker for more peers"},"remove-selected-torrents":{enabled:!1,text:"Remove from list\u2026"},"resume-selected-torrents":{enabled:!1,shortcut:"R",text:"Resume"},"resume-selected-torrents-now":{enabled:!1,text:"Resume now"},"select-all":{enabled:!1,shortcut:"A",text:"Select all"},"show-about-dialog":{enabled:!0,text:"About"},"show-inspector":{enabled:!1,shortcut:"I",text:"Torrent Inspector"},"show-labels-dialog":{enabled:!1,shortcut:"K",text:"Edit Labels\u2026"},"show-move-dialog":{enabled:!1,shortcut:"L",text:"Set location\u2026"},"show-overflow-menu":{enabled:!0,text:"More options\u2026"},"show-preferences-dialog":{enabled:!0,shortcut:"P",text:"Edit preferences"},"show-rename-dialog":{enabled:!1,shortcut:"N",text:"Rename\u2026"},"show-shortcuts-dialog":{enabled:!0,text:"Keyboard shortcuts"},"show-statistics-dialog":{enabled:!0,shortcut:"S",text:"Statistics"},"start-all-torrents":{enabled:!1,text:"Start all"},"toggle-compact-rows":{enabled:!0,text:"Compact rows"},"toggle-contrast":{enabled:!0,text:"High contrast UI"},"trash-selected-torrents":{enabled:!1,text:"Trash data and remove from list\u2026"},"verify-selected-torrents":{enabled:!1,shortcut:"V",text:"Verify local data"}})}click(e){if(this.isEnabled(e)){let t=new Event("click");t.action=e,this.dispatchEvent(t)}}getActionForShortcut(e){for(let[t,r]of Object.entries(this.actions))if(e===r.shortcut)return t;return null}allShortcuts(){return new Map(Object.entries(this.actions).filter(([,e])=>e.shortcut).map(([e,t])=>[t.shortcut,e]))}isEnabled(e){return this._getAction(e).enabled}text(e){return this._getAction(e).text}keyshortcuts(e){return this._getAction(e).shortcut}update(e){let t=s._recount(e.selected,e.nonselected);this._updateStates(t)}_getAction(e){let t=this.actions[e];if(!t)throw new Error(`no such action: ${e}`);return t}static _recount(e,t){let r=e.length+t.length,o=e.filter(g=>g.isStopped()).length,n=e.length-o,i=t.filter(g=>g.isStopped()).length,a=t.length-i,l=o+i,c=n+a,u=e.filter(g=>g.isQueued()).length;return{active:c,nonselected_active:a,nonselected_paused:i,paused:l,selected:e.length,selected_active:n,selected_paused:o,selected_queued:u,total:r}}_updateStates(e){let t=(r,o)=>{for(let n of o)this._updateActionState(n,r)};t(e.selected_paused>0,["resume-selected-torrents"]),t(e.paused>0,["start-all-torrents"]),t(e.active>0,["pause-all-torrents"]),t(e.selected_paused>0||e.selected_queued>0,["resume-selected-torrents-now"]),t(e.selected_active>0,["pause-selected-torrents","reannounce-selected-torrents"]),t(e.selected>0,["deselect-all","move-bottom","move-down","move-top","move-up","remove-selected-torrents","show-inspector","show-labels-dialog","show-move-dialog","trash-selected-torrents","verify-selected-torrents"]),t(e.selected===1,["show-rename-dialog"]),t(e.selectedys(o,g,i,c,t))}return a[0].classList.add("selected"),i.children[0].classList.remove("hidden"),{buttons:a,dismiss:n,root:r}}function L(s){let e=document.createElement("dialog");e.classList.add("dialog-container","popup",s),e.open=!0,e.setAttribute("role","dialog");let t=document.createElement("div");t.classList.add("dialog-window"),e.append(t);let r=document.createElement("div");r.classList.add("dialog-logo"),t.append(r);let o=document.createElement("div");o.classList.add("dialog-heading"),t.append(o);let n=document.createElement("div");n.classList.add("dialog-message"),t.append(n);let i=document.createElement("div");i.classList.add("dialog-workarea"),t.append(i);let a=document.createElement("div");a.classList.add("dialog-buttons"),t.append(a);let l=document.createElement("span");l.classList.add("dialog-buttons-begin"),a.append(l);let c=document.createElement("button");c.classList.add("dialog-dismiss-button"),c.textContent="Cancel",a.append(c);let u=document.createElement("button");u.textContent="OK",a.append(u);let g=document.createElement("span");return g.classList.add("dialog-buttons-end"),a.append(g),{confirm:u,dismiss:c,heading:o,message:n,root:e,workarea:i}}function W(){return typeof crypto.randomUUID=="function"?crypto.randomUUID():("10000000-1000-4000-8000"+-1e11).replaceAll(/[018]/g,s=>(s^crypto.getRandomValues(new Uint8Array(1))[0]&15>>s/4).toString(16))}function xs(s){let e=document.createElement("fieldset");e.classList.add("section");let t=document.createElement("legend");t.classList.add("title"),t.textContent=s,e.append(t);let r=document.createElement("div");return r.classList.add("content"),e.append(r),{content:r,root:e}}function Ke(s,e){let t=[],{root:r,content:o}=xs(s);for(let n of e){let i=document.createElement("label");i.textContent=n,o.append(i);let a=document.createElement("div");a.id=W(),o.append(a),i.setAttribute("for",a.id),t.push(a)}return{children:t,root:r}}function J(s,e=100){let t=null;return(...r)=>{t||(t=setTimeout(()=>{t=null,s(...r)},e))}}function Be(s,e){return(0,Rt.default)(s,e)}function Zs(s,e,t){t?s.setAttribute(e,!0):s.removeAttribute(e)}function O(s,e){Zs(s,"disabled",!e)}function ve(s,e){s.classList.toggle("checked",e)}var K=class extends EventTarget{constructor(e){super(),this.listener=t=>{e.contains(t.target)||(this.dispatchEvent(new MouseEvent(t.type,t)),t.preventDefault())},Object.seal(this),this.start()}start(){setTimeout(()=>document.addEventListener("click",this.listener),0)}stop(){document.removeEventListener("click",this.listener)}};function h(s,e){s.textContent!==e&&(s.textContent=e)}var ye=class{constructor(e){this._prefs=e,this._elements={toggle:document.querySelector("#toggle-notifications")}}_setEnabled(e){this.prefs.notifications_enabled=e,h(this._toggle,`${e?"Disable":"Enable"} Notifications`)}_requestPermission(){Notification.requestPermission().then(e=>this._setEnabled(e==="granted"))}toggle(){this._enabled?this._setEnabled(!1):Notification.permission==="granted"?this._setEnabled(!0):Notification.permission!=="denied"&&this._requestPermission()}};var m=class s extends EventTarget{constructor(){super(),this._cache={},this.dispatchPrefsChange=J((e,t,r)=>{let o=new Event("change");Object.assign(o,{key:e,old_value:t,value:r}),this.dispatchEvent(o)});for(let[e,t]of Object.entries(s._Defaults))this._set(e,s._getCookie(e,t)),Object.defineProperty(this,e.replaceAll("-","_"),{get:()=>this._get(e),set:r=>{this._set(e,r)}});Object.seal(this)}entries(){return Object.entries(this._cache)}keys(){return Object.keys(this._cache)}_get(e){let{_cache:t}=this;if(!Object.prototype.hasOwnProperty.call(t,e))throw new Error(e);return t[e]}_set(e,t){let{_cache:r}=this,o=r[e];o!==t&&(r[e]=t,s._setCookie(e,t),this.dispatchPrefsChange(e,o,t))}static _setCookie(e,t){let r=new Date;r.setFullYear(r.getFullYear()+1),document.cookie=`${e}=${t}; SameSite=Strict; expires=${r.toGMTString()}`}static _getCookie(e,t){let r=s._readCookie(e);return r===null?t:r==="true"?!0:r==="false"?!1:/^\d+$/.test(r)?Number.parseInt(r,10):r}static _readCookie(e){let r=`; ${document.cookie}`.split(`; ${e}=`);return r.length===2?r.pop().split(";").shift():null}};m.AltSpeedEnabled="alt-speed-enabled";m.DisplayCompact="compact";m.DisplayFull="full";m.DisplayMode="display-mode";m.ContrastLess="less";m.ContrastMore="more";m.ContrastMode="contrast-mode";m.FilterActive="active";m.FilterAll="all";m.FilterDownloading="downloading";m.FilterFinished="finished";m.FilterMode="filter-mode";m.FilterPaused="paused";m.FilterSeeding="seeding";m.NotificationsEnabled="notifications-enabled";m.RefreshRate="refresh-rate-sec";m.SortAscending="ascending";m.SortByActivity="activity";m.SortByAge="age";m.SortByName="name";m.SortByProgress="progress";m.SortByQueue="queue";m.SortByRatio="ratio";m.SortBySize="size";m.SortByState="state";m.SortDescending="descending";m.SortDirection="sort-direction";m.SortMode="sort-mode";m._Defaults={[m.AltSpeedEnabled]:!1,[m.DisplayMode]:m.DisplayFull,[m.ContrastMode]:window.matchMedia("(prefers-contrast: more)").matches?m.ContrastMore:m.ContrastLess,[m.FilterMode]:m.FilterAll,[m.NotificationsEnabled]:!1,[m.RefreshRate]:5,[m.SortDirection]:m.SortAscending,[m.SortMode]:m.SortByName};var xe=class s extends EventTarget{constructor(e){super(),this.elements=s._create(e),this.elements.dismiss.addEventListener("click",()=>this.close()),document.body.append(this.elements.root),this.elements.dismiss.focus()}close(){this.elements.root.remove(),this.dispatchEvent(new Event("close")),delete this.elements}static _create(e){let t=L("about-dialog");t.root.setAttribute("aria-label","About transmission"),t.heading.textContent="Transmission",t.dismiss.textContent="Close";let r=document.createElement("div");return r.classList.add("about-dialog-version-number"),r.textContent=e.version,t.heading.append(r),r=document.createElement("div"),r.classList.add("about-dialog-version-checksum"),r.textContent=e.checksum,t.heading.append(r),r=document.createElement("div"),r.textContent="A fast and easy bitTorrent client",t.workarea.append(r),r=document.createElement("div"),r.textContent="Copyright \xA9 The Transmission Project",t.workarea.append(r),r=document.createElement("a"),r.href="https://transmissionbt.com/",r.target="_blank",r.textContent="https://transmissionbt.com/",t.workarea.append(r),t.confirm.remove(),delete t.confirm,t}};var Ze=class extends EventTarget{constructor(e){super(),this.action_listener=this._update.bind(this),this.action_manager=e,this.action_manager.addEventListener("change",this.action_listener),Object.assign(this,this._create()),this.show()}show(){for(let[e,t]of Object.entries(this.actions))O(t,this.action_manager.isEnabled(e));document.body.append(this.root)}close(){if(!this.closed){this.action_manager.removeEventListener("change",this.action_listener),this.root.remove(),this.dispatchEvent(new Event("close"));for(let e of Object.keys(this))delete this[e];this.closed=!0}}_update(e){let t=this.actions[e.action];t&&O(t,e.enabled)}_create(){let e=document.createElement("div");e.role="menu",e.classList.add("context-menu","popup"),e.addEventListener("contextmenu",n=>{n.preventDefault()}),e.style.pointerEvents="none";let t={},r=(n,i=!1)=>{let a=document.createElement("div"),l=this.action_manager.text(n);a.role="menuitem",i?a.classList.add("context-menuitem","warning"):a.classList.add("context-menuitem"),a.dataset.action=n,a.textContent=l;let c=this.action_manager.keyshortcuts(n);c&&a.setAttribute("aria-keyshortcuts",c),a.addEventListener("click",()=>{this.action_manager.click(n),this.close()}),t[n]=a,e.append(a)},o=()=>{let n=document.createElement("div");n.classList.add("context-menu-separator"),e.append(n)};return r("resume-selected-torrents"),r("resume-selected-torrents-now"),r("pause-selected-torrents"),o(),r("move-top"),r("move-up"),r("move-down"),r("move-bottom"),o(),r("remove-selected-torrents",!0),r("trash-selected-torrents",!0),o(),r("verify-selected-torrents"),r("show-move-dialog"),r("show-rename-dialog"),r("show-labels-dialog"),o(),r("reannounce-selected-torrents"),o(),r("select-all"),r("deselect-all"),{actions:t,root:e}}};var Tt=new Intl.PluralRules,S=Tt.resolvedOptions().locale,Xs=new Intl.NumberFormat(S),$e=1e3,Fs=[new Intl.NumberFormat(S,{maximumFractionDigits:0,style:"unit",unit:"byte"}),new Intl.NumberFormat(S,{maximumFractionDigits:0,style:"unit",unit:"kilobyte"}),new Intl.NumberFormat(S,{maximumFractionDigits:0,style:"unit",unit:"megabyte"}),new Intl.NumberFormat(S,{maximumFractionDigits:2,style:"unit",unit:"gigabyte"}),new Intl.NumberFormat(S,{maximumFractionDigits:2,style:"unit",unit:"terabyte"}),new Intl.NumberFormat(S,{maximumFractionDigits:2,style:"unit",unit:"petabyte"})],Ws=new Intl.NumberFormat(S,{maximumFractionDigits:2,style:"unit",unit:"kilobyte-per-second"}),Ls=new Intl.NumberFormat(S,{maximumFractionDigits:2,style:"unit",unit:"megabyte-per-second"}),G={_toTruncFixed(s,e){return(Math.floor(s*10**e)/10**e).toFixed(e)},countString(s,e,t){return`${this.number(t)} ${this.ngettext(s,e,t)}`},mem(s){if(s<0)return"Unknown";if(s===0)return"None";let e=s;for(let t of Fs){if(e<$e)return t.format(e);e/=$e}return"E2BIG"},ngettext(s,e,t){return Tt.select(t)==="one"?s:e},number(s){return Xs.format(s)},percentString(s){let e=s<100?1:0;return this._toTruncFixed(s,e)},ratioString(s){return s===-1?"None":s===-2?"∞":this.percentString(s)},size(s){return this.mem(s)},speed(s){return s<999.95?Ws.format(s):Ls.format(s/1e3)},speedBps(s){return this.speed(this.toKBps(s))},stringSanitizer(s){return["E2BIG","NaN"].some(e=>s.includes(e))?"\u2026":s},timeInterval(s,e=3){let t=Math.floor(s/86400),r=[];t&&r.push(this.countString("day","days",t));let o=Math.floor(s%86400/3600);(t||o)&&r.push(this.countString("hour","hours",o));let n=Math.floor(s%3600/60);return t||o||n?(r.push(this.countString("minute","minutes",n)),r=r.slice(0,e),r.length>1?`${r.slice(0,-1).join(", ")} and ${r.slice(-1)}`:r[0]):this.countString("second","seconds",Math.floor(s%60))},timestamp(s){if(!s)return"N/A";let e=new Date(s*1e3),t=new Date,r="",o="",n=t.getFullYear()===e.getFullYear(),i=t.getMonth()===e.getMonth(),a=t.getDate()-e.getDate();n&&i&&Math.abs(a)<=1?a===0?r="Today":a===1?r="Yesterday":r="Tomorrow":r=e.toDateString();let l=e.getHours(),c="AM";l>12&&(l=l-12,c="PM"),l===0&&(l=12),l<10&&(l=`0${l}`);let u=e.getMinutes();return u<10&&(u=`0${u}`),s=e.getSeconds(),s<10&&(s=`0${s}`),o=[l,u,s].join(":"),[r,o,c].join(" ")},toKBps(s){return Math.floor(s/$e)}};var Xe=class extends EventTarget{isDone(){return this.fields.have>=this.fields.size}isEditable(){return this.fields.torrent.getFileCount()>1&&!this.isDone()}refreshWantedHTML(){let e=this.elements.root;e.classList.toggle("skip",!this.fields.isWanted),e.classList.toggle("complete",this.isDone()),O(e.checkbox,this.isEditable()),e.checkbox.checked=this.fields.isWanted}refreshProgressHTML(){let{size:e,have:t}=this.fields,r=100*(e?t/e:1),o=G,n=`${o.size(t)} of ${o.size(e)} (${o.percentString(r)}%)`;h(this.elements.progress,n)}refresh(){let e=0,t=!1,r=!1,o=!1,n=0,i=!1,a=this.fields.torrent.getFiles();for(let l of this.fields.indices){let c=a[l];switch(e+=c.bytesCompleted,n+=c.length,i|=c.wanted,c.priority.toString()){case"-1":r=!0;break;case"1":t=!0;break;default:o=!0;break}}ve(this.elements.priority_low_button,r),ve(this.elements.priority_normal_button,o),ve(this.elements.priority_high_button,t),(this.fields.have!==e||this.fields.size!==n)&&(this.fields.have=e,this.fields.size=n,this.refreshProgressHTML()),this.fields.isWanted!==i&&(this.fields.isWanted=i,this.refreshWantedHTML())}fireWantedChanged(e){let t=new Event("wantedToggled");t.indices=[...this.fields.indices],t.wanted=e,this.dispatchEvent(t)}firePriorityChanged(e){let t=new Event("priorityToggled");t.indices=[...this.fields.indices],t.priority=e,this.dispatchEvent(t)}createRow(e,t,r){let o=document.createElement("li");o.classList.add("inspector-torrent-file-list-entry"),this.elements.root=o;let n=document.createElement("input"),i=W();n.type="checkbox",n.className="file-wanted-control",n.title="Download file",n.id=i,n.addEventListener("change",c=>this.fireWantedChanged(c.target.checked)),o.checkbox=n,o.append(n),n=document.createElement("label"),n.className="inspector-torrent-file-list-entry-name",n.setAttribute("for",i),h(n,r),o.append(n),n=document.createElement("div"),n.className="inspector-torrent-file-list-entry-progress",o.append(n),this.elements.progress=n,n=document.createElement("div"),n.className="file-priority-radiobox";let a=n,l=c=>this.firePriorityChanged(c.target.value);n=document.createElement("input"),n.type="radio",n.value="-1",n.className="low",n.title="Low Priority",n.addEventListener("click",l),this.elements.priority_low_button=n,a.append(n),n=document.createElement("input"),n.type="radio",n.value="0",n.className="normal",n.title="Normal Priority",n.addEventListener("click",l),this.elements.priority_normal_button=n,a.append(n),n=document.createElement("input"),n.type="radio",n.value="1",n.title="High Priority",n.className="high",n.addEventListener("click",l),this.elements.priority_high_button=n,a.append(n),o.append(a),o.style.paddingLeft=`${t*20}px`,this.refresh()}getElement(){return this.elements.root}constructor(e,t,r,o){super(),this.fields={have:0,indices:o,isWanted:!0,size:0,torrent:e},this.elements={priority_high_button:null,priority_low_button:null,priority_normal_button:null,progress:null,root:null},this.createRow(e,t,r)}};var f=class s extends EventTarget{constructor(e){super(),this.fieldObservers={},this.fields={},this.refresh(e)}notifyOnFieldChange(e,t){this.fieldObservers[e]=this.fieldObservers[e]||[],this.fieldObservers[e].push(t)}setField(e,t,r){let o=e[t];if(Be(o,r))return!1;let n=this.fieldObservers[t];if(e===this.fields&&n&&n.length>0)for(let i of n)i.call(this,r,o,t);return e[t]=r,!0}updateFiles(e){let t=!1,r=this.fields.files||[],o=["length","name","bytesCompleted","wanted","priority"];for(let[n,i]of e.entries()){let a=r[n]||{};for(let l of o)l in i&&(t|=this.setField(a,l,i[l]));r[n]=a}return this.fields.files=r,t}static collateTrackers(e){return e.map(t=>t.announce.toLowerCase()).join(" ")}refreshFields(e){let t=!1;for(let[r,o]of Object.entries(e))switch(r){case"files":case"fileStats":t|=this.updateFiles(o);break;case"trackerStats":t|=this.setField(this.fields,"trackers",o);break;case"trackers":r in this.fields||(t|=this.setField(this.fields,r,o));break;case"name":this.setField(this.fields,r,e[r])&&(this.fields.collatedName="",t=!0);break;default:t|=this.setField(this.fields,r,o)}return t}refresh(e){this.refreshFields(e)&&this.dispatchEvent(new Event("dataChanged"))}getComment(){return this.fields.comment}getCreator(){return this.fields.creator}getDateAdded(){return this.fields.addedDate}getDateCreated(){return this.fields.dateCreated}getDesiredAvailable(){return this.fields.desiredAvailable}getDownloadDir(){return this.fields.downloadDir}getDownloadSpeed(){return this.fields.rateDownload}getDownloadedEver(){return this.fields.downloadedEver}getError(){return this.fields.error}getErrorString(){return this.fields.errorString}getETA(){return this.fields.eta}getFailedEver(){return this.fields.corruptEver}getFiles(){return this.fields.files||[]}getFile(e){return this.fields.files[e]}getFileCount(){return this.fields["file-count"]}getHashString(){return this.fields.hashString}getHave(){return this.getHaveValid()+this.getHaveUnchecked()}getHaveUnchecked(){return this.fields.haveUnchecked}getHaveValid(){return this.fields.haveValid}getId(){return this.fields.id}getLabels(){return this.fields.labels.sort()}getLastActivity(){return this.fields.activityDate}getLeftUntilDone(){return this.fields.leftUntilDone}getMagnetLink(){return this.fields.magnetLink}getMetadataPercentComplete(){return this.fields.metadataPercentComplete}getName(){return this.fields.name||"Unknown"}getPeers(){return this.fields.peers||[]}getPeersConnected(){return this.fields.peersConnected}getPeersGettingFromUs(){return this.fields.peersGettingFromUs}getPeersSendingToUs(){return this.fields.peersSendingToUs}getPieceCount(){return this.fields.pieceCount}getPieceSize(){return this.fields.pieceSize}getPrimaryMimeType(){return this.fields["primary-mime-type"]||"application/octet-stream"}getPrivateFlag(){return this.fields.isPrivate}getQueuePosition(){return this.fields.queuePosition}getRecheckProgress(){return this.fields.recheckProgress}getSeedRatioLimit(){return this.fields.seedRatioLimit}getSeedRatioMode(){return this.fields.seedRatioMode}getSizeWhenDone(){return this.fields.sizeWhenDone}getStartDate(){return this.fields.startDate}getStatus(){return this.fields.status}getTotalSize(){return this.fields.totalSize}getTrackers(){return this.fields.trackers||[]}getUploadSpeed(){return this.fields.rateUpload}getUploadRatio(){return this.fields.uploadRatio}getUploadedEver(){return this.fields.uploadedEver}getWebseedsSendingToUs(){return this.fields.webseedsSendingToUs}isFinished(){return this.fields.isFinished}hasExtraInfo(){return"hashString"in this.fields}isSeeding(){return this.getStatus()===s._StatusSeed}isStopped(){return this.getStatus()===s._StatusStopped}isChecking(){return this.getStatus()===s._StatusCheck}isDownloading(){return this.getStatus()===s._StatusDownload}isQueued(){return this.getStatus()===s._StatusDownloadWait||this.getStatus()===s._StatusSeedWait}isDone(){return this.getLeftUntilDone()<1}needsMetaData(){return this.getMetadataPercentComplete()<1}getActivity(){return this.getDownloadSpeed()+this.getUploadSpeed()}getPercentDoneStr(){return G.percentString(100*this.getPercentDone())}getPercentDone(){return this.fields.percentDone}getStateString(){switch(this.getStatus()){case s._StatusStopped:return this.isFinished()?"Seeding complete":"Paused";case s._StatusCheckWait:return"Queued for verification";case s._StatusCheck:return"Verifying local data";case s._StatusDownloadWait:return"Queued for download";case s._StatusDownload:return"Downloading";case s._StatusSeedWait:return"Queued for seeding";case s._StatusSeed:return"Seeding";case null:return"Unknown";default:return"Error"}}seedRatioLimit(e){switch(this.getSeedRatioMode()){case s._RatioUseGlobal:return e.seedRatioLimit();case s._RatioUseLocal:return this.getSeedRatioLimit();default:return-1}}getErrorMessage(){let e=this.getErrorString();switch(this.getError()){case s._ErrTrackerWarning:return`Tracker returned a warning: ${e}`;case s._ErrTrackerError:return`Tracker returned an error: ${e}`;case s._ErrLocalError:return`Error: ${e}`;default:return null}}getCollatedName(){let e=this.fields;return!e.collatedName&&e.name&&(e.collatedName=e.name.toLowerCase()),e.collatedName||""}getCollatedTrackers(){let e=this.fields;return!e.collatedTrackers&&e.trackers&&(e.collatedTrackers=s.collateTrackers(e.trackers)),e.collatedTrackers||""}testState(e){let t=this.getStatus();switch(e){case m.FilterActive:return this.getPeersGettingFromUs()>0||this.getPeersSendingToUs()>0||this.getWebseedsSendingToUs()>0||this.isChecking();case m.FilterSeeding:return t===s._StatusSeed||t===s._StatusSeedWait;case m.FilterDownloading:return t===s._StatusDownload||t===s._StatusDownloadWait;case m.FilterPaused:return this.isStopped();case m.FilterFinished:return this.isFinished();default:return!0}}test(e,t,r,o){let n=this.testState(e);if(n&&r&&(n=this.getCollatedName().includes(r.toLowerCase())),n){let i=this.getLabels();o.length>0&&(n=o.some(a=>i.includes(a)))}return n&&t&&t.length>0&&(n=this.getCollatedTrackers().includes(t)),n}static compareById(e,t){return e.getId()-t.getId()}static compareByName(e,t){return e.getCollatedName().localeCompare(t.getCollatedName())||s.compareById(e,t)}static compareByQueue(e,t){return e.getQueuePosition()-t.getQueuePosition()}static compareByAge(e,t){let r=e.getDateAdded();return t.getDateAdded()-r||s.compareByQueue(e,t)}static compareByState(e,t){let r=e.getStatus();return t.getStatus()-r||s.compareByQueue(e,t)}static compareByActivity(e,t){let r=e.getActivity();return t.getActivity()-r||s.compareByState(e,t)}static compareByRatio(e,t){let r=e.getUploadRatio(),o=t.getUploadRatio();return ro?-1:s.compareByState(e,t)}static compareByProgress(e,t){let r=e.getPercentDone(),o=t.getPercentDone();return r-o||s.compareByRatio(e,t)}static compareBySize(e,t){let r=e.getTotalSize(),o=t.getTotalSize();return r-o||s.compareByName(e,t)}static compareTorrents(e,t,r,o){let n=0;switch(r){case m.SortByActivity:n=s.compareByActivity(e,t);break;case m.SortByAge:n=s.compareByAge(e,t);break;case m.SortByQueue:n=s.compareByQueue(e,t);break;case m.SortByProgress:n=s.compareByProgress(e,t);break;case m.SortBySize:n=s.compareBySize(e,t);break;case m.SortByState:n=s.compareByState(e,t);break;case m.SortByRatio:n=s.compareByRatio(e,t);break;case m.SortByName:n=s.compareByName(e,t);break;default:console.log(`Unrecognized sort mode: ${r}`),n=s.compareByName(e,t);break}return o===m.SortDescending&&(n=-n),n}static sortTorrents(e,t,r){switch(t){case m.SortByActivity:e.sort(this.compareByActivity);break;case m.SortByAge:e.sort(this.compareByAge);break;case m.SortByName:e.sort(this.compareByName);break;case m.SortByProgress:e.sort(this.compareByProgress);break;case m.SortByQueue:e.sort(this.compareByQueue);break;case m.SortByRatio:e.sort(this.compareByRatio);break;case m.SortBySize:e.sort(this.compareBySize);break;case m.SortByState:e.sort(this.compareByState);break;default:console.log(`Unrecognized sort mode: ${t}`),e.sort(this.compareByName);break}return r===m.SortDescending&&e.reverse(),e}};f._StatusStopped=0;f._StatusCheckWait=1;f._StatusCheck=2;f._StatusDownloadWait=3;f._StatusDownload=4;f._StatusSeedWait=5;f._StatusSeed=6;f._RatioUseGlobal=0;f._RatioUseLocal=1;f._RatioUnlimited=2;f._ErrNone=0;f._ErrTrackerWarning=1;f._ErrTrackerError=2;f._ErrLocalError=3;f._TrackerInactive=0;f._TrackerWaiting=1;f._TrackerQueued=2;f._TrackerActive=3;f.Fields={};f.Fields.Metadata=["addedDate","file-count","name","primary-mime-type","totalSize"];f.Fields.Stats=["error","errorString","eta","isFinished","isStalled","labels","leftUntilDone","metadataPercentComplete","peersConnected","peersGettingFromUs","peersSendingToUs","percentDone","queuePosition","rateDownload","rateUpload","recheckProgress","seedRatioMode","seedRatioLimit","sizeWhenDone","status","trackers","downloadDir","uploadedEver","uploadRatio","webseedsSendingToUs"];f.Fields.InfoExtra=["comment","creator","dateCreated","files","hashString","isPrivate","magnetLink","pieceCount","pieceSize"];f.Fields.StatsExtra=["activityDate","corruptEver","desiredAvailable","downloadedEver","fileStats","haveUnchecked","haveValid","peers","startDate","trackerStats"];var Yt=["encryption","speed-up","speed-down","percent-done","status","peer-address","peer-app-name"],ne=class s extends EventTarget{constructor(e){super(),this.closed=!1,this.controller=e,this.elements=this._create(),this.current_page=this.elements.info.root,this.interval=setInterval(this._refreshTorrents.bind(this),3e3),this.name="inspector",this.selection_listener=t=>this._setTorrents(t.selected),this.torrent_listener=()=>this._updateCurrentPage(),this.torrents=[],this.file_torrent=null,this.file_torrent_n=null,this.file_rows=null,this.elements.dismiss.addEventListener("click",()=>this.close()),Object.seal(this),e.addEventListener("torrent-selection-changed",this.selection_listener),this._setTorrents(this.controller.getSelectedTorrents()),document.body.append(this.elements.root)}close(){if(!this.closed){clearInterval(this.interval),this._setTorrents([]),this.elements.root.remove(),this.controller.removeEventListener("torrent-selection-changed",this.selection_listener),this.dispatchEvent(new Event("close"));for(let e of Object.keys(this))this[e]=null;this.closed=!0}}static _createInfoPage(){let e=document.createElement("div");e.classList.add("inspector-info-page");let t={root:e},r=i=>{let a=document.createElement("div");a.textContent=i,a.classList.add("section-label"),e.append(a)},o=i=>{let a=document.createElement("label");h(a,i),e.append(a);let l=document.createElement("span");return e.append(l),l};r("Activity");let n=[["have","Have:"],["availability","Availability:"],["uploaded","Uploaded:"],["downloaded","Downloaded:"],["state","State:"],["running_time","Running time:"],["remaining_time","Remaining:"],["last_activity","Last activity:"],["error","Error:"]];for(let[i,a]of n)t[i]=o(a);r("Details"),n=[["size","Size:"],["location","Location:"],["hash","Hash:"],["privacy","Privacy:"],["origin","Origin:"],["dateAdded","Date added:"],["magnetLink","Magnet:"],["comment","Comment:"],["labels","Labels:"]];for(let[i,a]of n)t[i]=o(a);return t}static _createListPage(e,t){let r=document.createElement("div"),o=document.createElement(e);return o.id=t,r.append(o),{list:o,root:r}}static _createTiersPage(){return s._createListPage("div","inspector-tiers-list")}static _createFilesPage(){return s._createListPage("ul","inspector-file-list")}static _createPeersPage(){let e=document.createElement("table");e.classList.add("peer-list");let t=document.createElement("thead"),r=document.createElement("tr"),o=["","Up","Down","Done","Status","Address","Client"];for(let[i,a]of o.entries()){let l=document.createElement("th"),c=Yt[i];c==="encryption"&&(l.dataset.encrypted=!0),l.classList.add(c),h(l,a),r.append(l)}let n=document.createElement("tbody");return t.append(r),e.append(t),e.append(n),{root:e,tbody:n}}_create(){let e={files:s._createFilesPage(),info:s._createInfoPage(),peers:s._createPeersPage(),tiers:s._createTiersPage()},t=o=>{this.current_page=o,this._updateCurrentPage()};return{...Ge("inspector",[["inspector-tab-info",e.info.root,"Info"],["inspector-tab-peers",e.peers.root,"Peers"],["inspector-tab-tiers",e.tiers.root,"Tiers"],["inspector-tab-files",e.files.root,"Files"]],t.bind(this)),...e}}_setTorrents(e){let t="dataChanged",r=this.torrent_listener;for(let o of this.torrents)o.removeEventListener(t,r);this.torrents=[...e];for(let o of this.torrents)o.addEventListener(t,r);this._refreshTorrents(),this._updateCurrentPage()}static _needsExtraInfo(e){return e.some(t=>!t.hasExtraInfo())}_refreshTorrents(){let{controller:e,torrents:t}=this,r=t.map(o=>o.getId());if(r&&r.length>0){let o=["id",...f.Fields.StatsExtra];s._needsExtraInfo(t)&&o.push(...f.Fields.InfoExtra),e.updateTorrents(r,o)}}_updateCurrentPage(){let{current_page:e,elements:t}=this;switch(e){case t.files.root:this._updateFiles();break;case t.info.root:this._updateInfo();break;case t.peers.root:this._updatePeers();break;case t.tiers.root:this._updateTiers();break;default:console.warn("unexpected page"),console.log(e)}}_updateInfo(){let e="None",t="Mixed",r="Unknown",o=G,n=Date.now(),{elements:i,torrents:a}=this,l=a.reduce((g,d)=>g+d.getSizeWhenDone(),0),c=null;if(a.length===0)c=e;else if(a.every(g=>g.isFinished()))c="Finished";else if(a.every(g=>g.isStopped()))c="Paused";else{let g=p=>p.getStateString(),d=g(a[0]);c=a.every(p=>g(p)===d)?d:t}h(i.info.state,c);let u=c;if(a.length===0)c=e;else{let g=a.reduce((I,C)=>I+C.getHaveValid(),0),d=a.reduce((I,C)=>I+C.getHaveUnchecked(),0),p=a.reduce((I,C)=>I+C.getLeftUntilDone(),0),b=100*(l?(l-p)/l:1);c=o.percentString(b),d?c=`${o.size(g)} of ${o.size(l)} (${c}%), ${o.size(d)} Unverified`:p?c=`${o.size(g)} of ${o.size(l)} (${c}%)`:c=`${o.size(g)} (100%)`}if(h(i.info.have,o.stringSanitizer(c)),a.length===0)c=e;else if(l===0)c=e;else{let g=a.reduce((d,p)=>p.getHave()+p.getDesiredAvailable(),0);c=`${o.percentString(100*g/l)}%`}if(h(i.info.availability,o.stringSanitizer(c)),a.length===0)c=e;else{let g=a.reduce((p,b)=>p+b.getDownloadedEver(),0),d=a.reduce((p,b)=>p+b.getFailedEver(),0);c=d?`${o.size(g)} (+${o.size(d)} discarded after failed checksum)`:o.size(g)}if(h(i.info.downloaded,o.stringSanitizer(c)),a.length===0)c=e;else{let g=a.reduce((p,b)=>p+b.getUploadedEver(),0),d=a.reduce((p,b)=>p+b.getSizeWhenDone(),0)||a.reduce((p,b)=>p+b.getHaveValid(),0);c=`${o.size(g)} (Ratio: ${o.ratioString(oe.ratio(g,d))})`}if(h(i.info.uploaded,c),a.length===0)c=e;else if(a.every(g=>g.isStopped()))c=u;else{let g=p=>p.getStartDate(),d=g(a[0]);c=a.every(p=>g(p)===d)?o.timeInterval(n/1e3-d):t}if(h(i.info.running_time,c),a.length===0)c=e;else{let g=p=>p.getETA(),d=g(a[0]);a.every(p=>g(p)===d)?d<0?c=r:c=o.timeInterval(d):c=t}if(h(i.info.remaining_time,c),a.length===0)c=e;else{let g=a.reduce((p,b)=>Math.max(p,b.getLastActivity()),-1),d=Math.floor(n/1e3);if(0p.getErrorString(),d=g(a[0]);c=a.every(p=>g(p)===d)?d:t}if(h(i.info.error,c||e),a.length===0)c=e;else{let g=a.reduce((d,p)=>d+p.getTotalSize(),0);if(g){let d=C=>C.getPieceSize(),p=a.reduce((C,y)=>C+y.getPieceCount(),0),b=o.number(p),I=d(a[0]);c=a.every(C=>d(C)===I)?`${o.size(g)} (${b} pieces @ ${o.mem(I)})`:`${o.size(g)} (${b} pieces)`}else c="None"}if(h(i.info.size,o.stringSanitizer(c)),a.length===0)c=e;else{let g=p=>p.getHashString(),d=g(a[0]);c=a.every(p=>g(p)===d)?d:t}if(h(i.info.hash,c),a.length===0)c=e;else{let g=p=>p.getPrivateFlag(),d=g(a[0]);a.every(p=>g(p)===d)?d?c="Private to this tracker -- DHT and PEX disabled":c="Public torrent":c=t}if(h(i.info.privacy,c),a.length===0)c=e;else{let g=p=>p.getComment(),d=g(a[0]);c=a.every(p=>g(p)===d)?d:t}if(c=c||e,c.startsWith("https://")||c.startsWith("http://")?(c=encodeURI(c),i.info.comment.innerHTML=`${c}`):h(i.info.comment,c),c=a.length===0?e:a[0].getLabels().join(", "),h(i.info.labels,c),a.length===0)c=e;else{let g=B=>B.getCreator(),d=g(a[0]),p=!a.every(B=>g(B)===d);g=B=>B.getDateCreated();let b=g(a[0]),I=!a.every(B=>g(B)===b),C=!d||d.length===0,y=!b;p||I?c=t:C&&y?c=r:y&&!C?c=`Created by ${d}`:C&&!y?c=`Created on ${new Date(b*1e3).toDateString()}`:c=`Created by ${d} on ${new Date(b*1e3).toDateString()}`}if(h(i.info.origin,c),a.length===0)c=e;else{let g=p=>p.getDownloadDir(),d=g(a[0]);c=a.every(p=>g(p)===d)?d:t}if(h(i.info.location,c),a.length===0)c=e;else{let g=p=>p.getDateAdded(),d=g(a[0]);c=a.every(p=>g(p)===d)?new Date(d*1e3).toLocaleString(navigator.language,{day:"2-digit",hour:"2-digit",hour12:!1,minute:"2-digit",month:"short",second:"2-digit",timeZoneName:"short",weekday:"short",year:"numeric"}):t}if(h(i.info.dateAdded,c),a.length===0)h(i.info.magnetLink,e);else if(a.length>1)h(i.info.magnetLink,t);else{let g=a[0].getMagnetLink();i.info.magnetLink.innerHTML=``}}static _peerStatusTitle(e){let t=Object.seal({"?":"We unchoked this peer, but they're not interested",D:"Downloading from this peer",E:"Encrypted Connection",H:"Peer was discovered through Distributed Hash Table (DHT)",I:"Peer is an incoming connection",K:"Peer has unchoked us, but we're not interested",O:"Optimistic unchoke",T:"Peer is connected via uTP",U:"Uploading to peer",X:"Peer was discovered through Peer Exchange (PEX)",d:"We would download from this peer if they'd let us",u:"We would upload to this peer if they'd ask"});return[...e].filter(r=>t[r]).map(r=>`${r}: ${t[r]}`).join(`
-`)}_updatePeers(){let e=G,{elements:t,torrents:r}=this,{tbody:o}=t.peers,n=[(a,l)=>{l.dataset.encrypted=a.isEncrypted},(a,l)=>h(l,a.rateToPeer?e.speedBps(a.rateToPeer):""),(a,l)=>h(l,a.rateToClient?e.speedBps(a.rateToClient):""),(a,l)=>h(l,`${Math.floor(a.progress*100)}%`),(a,l)=>{h(l,a.flagStr),l.setAttribute("title",s._peerStatusTitle(a.flagStr))},(a,l)=>{h(l,a.address),l.setAttribute("title",a.address)},(a,l)=>{h(l,a.clientName),l.setAttribute("title",a.clientName)}],i=[];for(let a of r){let l=document.createElement("tr");l.classList.add("torrent-row");let c=document.createElement("td");c.setAttribute("colspan",n.length),h(c,a.getName()),l.append(c),i.push(l);for(let u of a.getPeers()){let g=document.createElement("tr");g.classList.add("peer-row");for(let[d,p]of n.entries()){let b=document.createElement("td");b.classList.add(Yt[d]),p(u,b),g.append(b)}i.push(g)}for(;o.firstChild;)o.firstChild.remove();o.append(...i)}}static getAnnounceState(e){switch(e.announceState){case f._TrackerActive:return"Announce in progress";case f._TrackerWaiting:{let t=Math.max(0,e.nextAnnounceTime-Date.now()/1e3);return`Next announce in ${G.timeInterval(t)}`}case f._TrackerQueued:return"Announce is queued";case f._TrackerInactive:return e.isBackup?"Tracker will be used as a backup":"Announce not scheduled";default:return`unknown announce state: ${e.announceState}`}}static lastAnnounceStatus(e){let t="Last Announce",r=["N/A"];if(e.hasAnnounced){let o=G.timestamp(e.lastAnnounceTime);e.lastAnnounceSucceeded?r=[o," (got ",G.countString("peer","peers",e.lastAnnouncePeerCount),")"]:(t="Announce error",r=[e.lastAnnounceResult?`${e.lastAnnounceResult} - `:"",o])}return{label:t,value:r.join("")}}static lastScrapeStatus(e){let t="Last Scrape",r="N/A";if(e.hasScraped){let o=G.timestamp(e.lastScrapeTime);e.lastScrapeSucceeded?r=o:(t="Scrape error",r=(e.lastScrapeResult?`${e.lastScrapeResult} - `:"")+o)}return{label:t,value:r}}static _getOrigin(e){try{let t="udp://";if(e.announce.startsWith(t)){let o="http://",n=e.announce.replace(t,o);return new URL(n).origin.replace(o,t)}return new URL(e.announce).origin}catch{return[e.sitename||e.host||e.announce]}}_updateTiers(){let e="N/A",{list:t}=this.elements.tiers,{torrents:r}=this,o=[];for(let n of r){if(r.length>1){let i=document.createElement("div");i.classList.add("tier-list-torrent"),h(i,n.getName()),o.push(i)}for(let i of n.getTrackers()){let a=s.getAnnounceState(i),l=s.lastAnnounceStatus(i),c=s.lastScrapeStatus(i),u=document.createElement("div");u.classList.add("tier-list-row");let g=document.createElement("div"),d=s._getOrigin(i);g.classList.add("tier-list-tracker"),h(g,`${d} - tier ${i.tier+1}`),g.setAttribute("title",i.announce),u.append(g),g=document.createElement("div"),g.classList.add("tier-announce"),h(g,`${l.label}: ${l.value}`),u.append(g),g=document.createElement("div"),g.classList.add("tier-seeders"),h(g,`Seeders: ${i.seederCount>-1?i.seederCount:e}`),u.append(g),g=document.createElement("div"),g.classList.add("tier-state"),h(g,a),u.append(g),g=document.createElement("div"),g.classList.add("tier-leechers"),h(g,`Leechers: ${i.leecherCount>-1?i.leecherCount:e}`),u.append(g),g=document.createElement("div"),g.classList.add("tier-scrape"),h(g,`${c.label}: ${c.value}`),u.append(g),g=document.createElement("div"),g.classList.add("tier-downloads"),h(g,`Downloads: ${i.downloadCount>-1?i.downloadCount:e}`),u.append(g),o.push(u)}}for(;t.firstChild;)t.firstChild.remove();t.append(...o)}_changeFileCommand(e,t){let{controller:r,file_torrent:o}=this,n=o.getId();r.changeFileCommand(n,e,t)}_onFileWantedToggled(e){let{indices:t,wanted:r}=e;this._changeFileCommand(t,r?"files-wanted":"files-unwanted")}_onFilePriorityToggled(e){let{indices:t,priority:r}=e,o=null;switch(r.toString()){case"-1":o="priority-low";break;case"1":o="priority-high";break;default:o="priority-normal";break}this._changeFileCommand(t,o)}_clearFileList(){let{list:e}=this.elements.files;for(;e.firstChild;)e.firstChild.remove();this.file_torrent=null,this.file_torrent_n=null,this.file_rows=null}static createFileTreeModel(e){let t=[],r={children:{},file_indices:[]};for(let[o,n]of e.getFiles().entries()){let{name:i}=n,a=i.split("/"),l=r;for(let[c,u]of a.entries()){let g=l.children[u];g||(l.children[u]=g={children:{},depth:c,file_indices:[],name:u,parent:l}),l=g}l.file_index=o,delete l.children,t.push(l)}for(let o of t){let{file_index:n}=o,i=o;do i.file_indices.push(n),i=i.parent;while(i)}return r}addNodeToView(e,t,r){let o=new Xe(e,r.depth,r.name,r.file_indices);o.addEventListener("wantedToggled",this._onFileWantedToggled.bind(this)),o.addEventListener("priorityToggled",this._onFilePriorityToggled.bind(this)),this.file_rows.push(o),t.append(o.getElement())}addSubtreeToView(e,t,r){if(r.parent&&this.addNodeToView(e,t,r),r.children)for(let o of Object.values(r.children))this.addSubtreeToView(e,t,o)}_updateFiles(){let{list:e}=this.elements.files,{file_rows:t,file_torrent:r,file_torrent_n:o,torrents:n}=this;if(n.length!==1){this._clearFileList();return}let[i]=n,a=i.getFiles().length;if(i!==r||a!==o){this._clearFileList(),this.file_torrent=i,this.file_torrent_n=a,this.file_rows=[];let l=document.createDocumentFragment(),c=s.createFileTreeModel(i);this.addSubtreeToView(i,l,c),e.append(l)}else for(let l of t)l.refresh()}};var Fe=class s extends EventTarget{constructor(e,t){super(),this.controller=e,this.remote=t,this.elements={},this.torrents=[],this.show()}show(){let e=this.controller.getSelectedTorrents();e.length!==0&&(this.torrents=e,this.elements=s._create(),this.elements.confirm.addEventListener("click",()=>this._onConfirm()),this.elements.dismiss.addEventListener("click",()=>this._onDismiss()),this.elements.entry.value=e[0].getDownloadDir(),document.body.append(this.elements.root),this.elements.entry.focus())}close(){this.elements.root.remove(),this.dispatchEvent(new Event("close")),delete this.controller,delete this.remote,delete this.elements,delete this.torrents}_onDismiss(){this.close()}_onConfirm(){let e=this.torrents.map(r=>r.getId()),t=this.elements.entry.value.trim();this.remote.moveTorrents(e,t),this.close()}static _create(){let e=L("move-dialog");e.root.setAttribute("aria-label","Move Torrent"),e.heading.textContent="Set Torrent Location",confirm.textContent="Apply";let t=document.createElement("label");t.setAttribute("for","torrent-path"),t.textContent="Location:",e.workarea.append(t);let r=document.createElement("input");return r.setAttribute("type","text"),r.id="torrent-path",e.entry=r,e.workarea.append(r),e}};var z=class s extends EventTarget{constructor(e){super(),this.elements=s._create(e),this.elements.dismiss.addEventListener("click",()=>this._onDismiss()),this.options=e,document.body.append(this.elements.root),this.elements.dismiss.focus()}close(){if(!this.closed){this.elements.root.remove(),this.dispatchEvent(new Event("close"));for(let e of Object.keys(this))delete this[e];this.closed=!0}}_onDismiss(){this.close()}static _create(e){let{heading:t,message:r}=e,o=L("confirm-dialog");return o.confirm.remove(),delete o.confirm,o.heading.textContent=t,o.workarea.textContent=r,o}};var $=class extends EventTarget{constructor(e,t,r="",o=[]){super(),this.controller=e,this.remote=t,this.elements=this._create(r),this.elements.dismiss.addEventListener("click",()=>this._onDismiss()),this.elements.confirm.addEventListener("click",()=>this._onConfirm()),document.body.append(this.elements.root),o.length>0&&(this.elements.file_input.files=o),this._updateFreeSpaceInAddDialog(),this.elements.url_input.focus()}close(){if(!this.closed){clearInterval(this.interval),this.elements.root.remove(),this.dispatchEvent(new Event("close"));for(let e of Object.keys(this))delete this[e];this.closed=!0}}_onDismiss(){this.close()}_updateFreeSpaceInAddDialog(){let e=this.elements.folder_input.value;this.remote.getFreeSpace(e,(t,r)=>{if(!this.closed){let o=r>0?`${G.size(r)} Free`:"";this.elements.freespace.textContent=o}})}_onConfirm(){let{controller:e,elements:t,remote:r}=this,{file_input:o,folder_input:n,start_input:i,url_input:a}=t,l=!i.checked,c=n.value.trim();for(let g of o.files){let d=new FileReader;d.addEventListener("load",p=>{let b=p.target.result,I="base64,",C=b.indexOf(I);if(C===-1)return;let y={arguments:{"download-dir":c,metainfo:b.slice(Math.max(0,C+I.length)),paused:l},method:"torrent-add"};r.sendRequest(y,B=>{B.result!=="success"&&(alert(`Error adding "${g.name}": ${B.result}`),e.setCurrentPopup(new z({heading:`Error adding "${g.name}"`,message:B.result})))})}),d.readAsDataURL(g)}let u=a.value.trim();if(u.length>0){/^[\da-f]{40}$/i.test(u)&&(u=`magnet:?xt=urn:btih:${u}`);let g={arguments:{"download-dir":c,filename:u,paused:l},method:"torrent-add"};r.sendRequest(g,d=>{d.result!=="success"&&e.setCurrentPopup(new z({heading:`Error adding "${u}"`,message:d.result}))})}this._onDismiss()}_create(e){let t=L(),{confirm:r,root:o,heading:n,workarea:i}=t;o.classList.add("open-torrent"),n.textContent="Add Torrents",r.textContent="Add";let a=W(),l=document.createElement("label");l.setAttribute("for",a),l.textContent="Please select torrent files to add:",i.append(l);let c=document.createElement("input");c.type="file",c.name="torrent-files[]",c.id=a,c.multiple="multiple",i.append(c),t.file_input=c,a=W(),l=document.createElement("label"),l.setAttribute("for",a),l.textContent="Or enter a URL:",i.append(l),c=document.createElement("input"),c.type="url",c.id=a,c.value=e,i.append(c),t.url_input=c,c.addEventListener("keyup",({key:p})=>{p==="Enter"&&r.click()}),a=W(),l=document.createElement("label"),l.id="add-dialog-folder-label",l.for=a,l.textContent="Destination folder: ",i.append(l);let u=document.createElement("span");u.id="free-space-text",l.append(u),i.append(l),t.freespace=u,c=document.createElement("input"),c.type="text",c.id="add-dialog-folder-input",c.addEventListener("change",()=>this._updateFreeSpaceInAddDialog()),c.value=this.controller.session_properties["download-dir"],i.append(c),t.folder_input=c;let g=document.createElement("div");i.append(g);let d=document.createElement("input");return d.type="checkbox",d.id="auto-start-check",d.checked=this.controller.shouldAddedTorrentsStart(),g.append(d),t.start_input=d,l=document.createElement("label"),l.id="auto-start-label",l.setAttribute("for",d.id),l.textContent="Start when added",g.append(l),t}};var X={_DaemonVersion:"version",_DownSpeedLimit:"speed-limit-down",_DownSpeedLimited:"speed-limit-down-enabled",_QueueMoveBottom:"queue-move-bottom",_QueueMoveDown:"queue-move-down",_QueueMoveTop:"queue-move-top",_QueueMoveUp:"queue-move-up",_Root:"../rpc",_TurtleDownSpeedLimit:"alt-speed-down",_TurtleState:"alt-speed-enabled",_TurtleUpSpeedLimit:"alt-speed-up",_UpSpeedLimit:"speed-limit-up",_UpSpeedLimited:"speed-limit-up-enabled"},ie=class s{constructor(e){this._connection_alert=null,this._controller=e,this._session_id=""}sendRequest(e,t,r){let o=new Headers;o.append("cache-control","no-cache"),o.append("content-type","application/json"),o.append("pragma","no-cache"),this._session_id&&o.append(s._SessionHeader,this._session_id);let n=null;fetch(X._Root,{body:JSON.stringify(e),headers:o,method:"POST"}).then(i=>{if(n=i,i.status===409){let a=new Error(s._SessionHeader);throw a.header=i.headers.get(s._SessionHeader),a}return i.json()}).then(i=>{t&&t.call(r,i,n),this._connection_alert&&(this._connection_alert.close(),this._connection_alert=null)}).catch(i=>{if(i.message===s._SessionHeader){this._session_id=i.header,this.sendRequest(e,t,r);return}console.trace(i),this._controller.togglePeriodicSessionRefresh(!1),this._connection_alert=new z({heading:"Connection failed",message:"Could not connect to the server. You may need to reload the page to reconnect."}),this._controller.setCurrentPopup(this._connection_alert)})}loadDaemonPrefs(e,t){let r={method:"session-get"};this.sendRequest(r,e,t)}checkPort(e,t,r){let o={arguments:{ipProtocol:e},method:"port-test"};this.sendRequest(o,t,r)}renameTorrent(e,t,r,o,n){let i={arguments:{ids:e,name:r,path:t},method:"torrent-rename-path"};this.sendRequest(i,o,n)}setLabels(e,t,r){let o={ids:e,labels:t};this.sendRequest({arguments:o,method:"torrent-set"},r)}loadDaemonStats(e,t){let r={method:"session-stats"};this.sendRequest(r,e,t)}updateTorrents(e,t,r,o){let n={arguments:{fields:t,format:"table"},method:"torrent-get"};e&&(n.arguments.ids=e),this.sendRequest(n,i=>{let a=i.arguments;r.call(o,a.torrents,a.removed)})}getFreeSpace(e,t,r){let o={arguments:{path:e},method:"free-space"};this.sendRequest(o,n=>{let i=n.arguments;t.call(r,i.path,i["size-bytes"])})}changeFileCommand(e,t,r){let o={ids:[e]};o[r]=t,this.sendRequest({arguments:o,method:"torrent-set"},()=>{this._controller.refreshTorrents([e])})}sendTorrentSetRequests(e,t,r,o,n){r||(r={}),r.ids=t;let i={arguments:r,method:e};this.sendRequest(i,o,n)}sendTorrentActionRequests(e,t,r,o){this.sendTorrentSetRequests(e,t,null,r,o)}startTorrents(e,t,r,o){let n=t?"torrent-start-now":"torrent-start";this.sendTorrentActionRequests(n,e,r,o)}stopTorrents(e,t,r){this.sendTorrentActionRequests("torrent-stop",e,t,r)}moveTorrents(e,t,r,o){this.sendTorrentSetRequests("torrent-set-location",e,{location:t,move:!0},r,o)}removeTorrents(e,t){let r={arguments:{"delete-local-data":t,ids:[]},method:"torrent-remove"};if(e)for(let o=0,n=e.length;o{this._controller.refreshTorrents()})}verifyTorrents(e,t,r){this.sendTorrentActionRequests("torrent-verify",e,t,r)}reannounceTorrents(e,t,r){this.sendTorrentActionRequests("torrent-reannounce",e,t,r)}addTorrentByUrl(e,t){/^[\da-f]{40}$/i.test(e)&&(e=`magnet:?xt=urn:btih:${e}`);let r={arguments:{filename:e,paused:t.paused},method:"torrent-add"};this.sendRequest(r,()=>{this._controller.refreshTorrents()})}savePrefs(e){let t={arguments:e,method:"session-set"};this.sendRequest(t,()=>{this._controller.loadDaemonPrefs()})}updateBlocklist(){let e={method:"blocklist-update"};this.sendRequest(e,()=>{this._controller.loadDaemonPrefs()})}moveTorrentsToTop(e,t,r){this.sendTorrentActionRequests(X._QueueMoveTop,e,t,r)}moveTorrentsToBottom(e,t,r){this.sendTorrentActionRequests(X._QueueMoveBottom,e,t,r)}moveTorrentsUp(e,t,r){this.sendTorrentActionRequests(X._QueueMoveUp,e,t,r)}moveTorrentsDown(e,t,r){this.sendTorrentActionRequests(X._QueueMoveDown,e,t,r)}};ie._SessionHeader="X-Transmission-Session-Id";function We(s,e){let t=document.createElement("fieldset");t.classList.add("section",s);let r=document.createElement("legend");return r.classList.add("title"),r.textContent=e,t.append(r),t}function St(s,e,t,r){let o=document.createElement("button");return o.textContent=e,o.addEventListener("click",r),s.append(o),o.dataset.action=t,o}var ae=class extends EventTarget{constructor(e,t,r,o){super(),this.action_listener=this._onActionChange.bind(this),this.action_manager=o,this.action_manager.addEventListener("change",this.action_listener),this.prefs_listener=this._onPrefsChange.bind(this),this.prefs=t,this.prefs.addEventListener("change",this.prefs_listener),this.closed=!1,this.remote=r,this.name="overflow-menu",this.session_listener=this._onSessionChange.bind(this),this.session_manager=e,this.session_manager.addEventListener("session-change",this.session_listener);let{session_properties:n}=e;Object.assign(this,this._create(n)),this.outside=new K(this.root),this.outside.addEventListener("click",()=>this.close()),Object.seal(this),this.show()}show(){document.body.append(this.root)}close(){if(!this.closed){this.outside.stop(),this.session_manager.removeEventListener("session-change",this.session_listener),this.action_manager.removeEventListener("change",this.action_listener),this.prefs.removeEventListener("change",this.prefs_listener),this.root.remove(),this.dispatchEvent(new Event("close"));for(let e of Object.keys(this))this[e]=null;this.closed=!0}}_onSessionChange(e){let{alt_speed_check:t}=this.elements,{session_properties:r}=e;t.checked=r[X._TurtleState]}_onPrefsChange(e){switch(e.key){case m.SortDirection:case m.SortMode:this.root.querySelector(`[data-pref="${e.key}"]`).value=e.value;break;default:break}}_onActionChange(e){let t=this.actions[e.action];t&&this._updateElement(t)}_updateElement(e){if(e.dataset.action){let{action:t}=e.dataset,r=this.action_manager.keyshortcuts(t);r&&e.setAttribute("aria-keyshortcuts",r),O(e,this.action_manager.isEnabled(t))}}_onClick(e){let{action:t,pref:r}=e.target.dataset;if(t){this.action_manager.click(t);return}if(r){this.prefs[r]=e.target.value;return}console.log("unhandled"),console.log(e),console.trace()}_create(e){let t={},r={},o=this._onClick.bind(this),n=document.createElement("div");n.classList.add("overflow-menu","popup");let i=We("display","Display");n.append(i);let a=document.createElement("div");a.id="display-options",i.append(a);let l=document.createElement("div");l.classList.add("table-row"),a.append(l);let c=document.createElement("label");c.id="display-sort-mode-label",c.textContent="Sort by",l.append(c);let u=document.createElement("select");u.id="display-sort-mode-select",u.dataset.pref=m.SortMode,l.append(u);let g=[[m.SortByActivity,"Activity"],[m.SortByAge,"Age"],[m.SortByName,"Name"],[m.SortByProgress,"Progress"],[m.SortByQueue,"Queue order"],[m.SortByRatio,"Ratio"],[m.SortBySize,"Size"],[m.SortByState,"State"]];for(let[A,v]of g){let U=document.createElement("option");U.value=A,U.textContent=v,u.append(U)}c.setAttribute("for",u.id),u.value=this.prefs.sort_mode,u.addEventListener("change",A=>{this.prefs.sort_mode=A.target.value}),l=document.createElement("div"),l.classList.add("table-row"),a.append(l);let d=document.createElement("input");d.id="display-sort-reverse-check",d.dataset.pref=m.SortDirection,d.type="checkbox",l.append(d),c=document.createElement("label"),c.id="display-sort-reverse-label",c.setAttribute("for",d.id),c.textContent="Reverse sort",l.append(c),d.checked=this.prefs.sort_direction!==m.SortAscending,d.addEventListener("input",A=>{this.prefs.sort_direction=A.target.checked?m.SortDescending:m.SortAscending}),l=document.createElement("div"),l.classList.add("table-row"),a.append(l);let p="toggle-compact-rows";d=document.createElement("input"),d.id="display-compact-check",d.dataset.action=p,d.type="checkbox",l.append(d),c=document.createElement("label"),c.id="display-compact-label",c.for=d.id,c.setAttribute("for",d.id),c.textContent=this.action_manager.text(p),d.checked=this.prefs.display_mode===m.DisplayCompact,l.append(c),d.addEventListener("input",A=>{let{checked:v}=A.target;this.prefs.display_mode=v?m.DisplayCompact:m.DisplayFull}),l=document.createElement("div"),l.classList.add("table-row"),a.append(l),p="toggle-contrast",d=document.createElement("input"),d.id="contrast-more-check",d.dataset.action=p,d.type="checkbox",d.classList.add("switch"),c=document.createElement("label"),c.id="contrast-more-label",c.for=d.id,c.setAttribute("for",d.id),c.textContent=this.action_manager.text(p),d.checked=this.prefs.contrast_mode===m.ContrastMore,l.append(d),l.append(c),d.addEventListener("input",A=>{let{checked:v}=A.target;this.prefs.contrast_mode=v?m.ContrastMore:m.ContrastLess}),l=document.createElement("div"),l.classList.add("table-row","display-fullscreen-row"),a.append(l),d=document.createElement("input"),d.id="display-fullscreen-check",d.type="checkbox";let b=()=>document.fullscreenElement!==null;d.checked=b(),d.addEventListener("input",()=>{b()?document.exitFullscreen():document.body.requestFullscreen()}),document.addEventListener("fullscreenchange",()=>{d.checked=b()}),l.append(d),c=document.createElement("label"),c.id="display-fullscreen-label",c.for=d.id,c.setAttribute("for",d.id),c.textContent="Fullscreen",l.append(c),i=We("speed","Speed Limit"),n.append(i),a=document.createElement("div"),a.id="speed-options",i.append(a),l=document.createElement("div"),l.classList.add("speed-up"),a.append(l),c=document.createElement("label"),c.id="speed-up-label",c.textContent="Upload:",l.append(c);let I="Unlimited";u=document.createElement("select"),u.id="speed-up-select",l.append(u);let C=["50","100","250","500","1000","2500","5000","10000",I];for(let A of[...new Set(C).add(`${e[X._UpSpeedLimit]}`).values()].sort((v,U)=>v-U)){let v=document.createElement("option");v.value=A,v.textContent=A===I?I:G.speed(A),u.append(v)}c.setAttribute("for",u.id),u.value=e[X._UpSpeedLimited]?`${e[X._UpSpeedLimit]}`:I,u.addEventListener("change",A=>{let{value:v}=A.target;console.log(A),v===I?this.remote.savePrefs({[X._UpSpeedLimited]:!1}):this.remote.savePrefs({[X._UpSpeedLimited]:!0,[X._UpSpeedLimit]:Number.parseInt(v,10)})}),l=document.createElement("div"),l.classList.add("speed-down"),a.append(l),c=document.createElement("label"),c.id="speed-down-label",c.textContent="Download:",l.append(c),u=document.createElement("select"),u.id="speed-down-select",l.append(u);for(let A of[...new Set(C).add(`${e[X._DownSpeedLimit]}`).values()].sort((v,U)=>v-U)){let v=document.createElement("option");v.value=A,v.textContent=A===I?I:G.speed(A),u.append(v)}c.setAttribute("for",u.id),u.value=e[X._DownSpeedLimited]?`${e[X._DownSpeedLimit]}`:I,u.addEventListener("change",A=>{let{value:v}=A.target;console.log(A),v===I?this.remote.savePrefs({[X._DownSpeedLimited]:!1}):this.remote.savePrefs({[X._DownSpeedLimited]:!0,[X._DownSpeedLimit]:Number.parseInt(v,10)})}),l=document.createElement("div"),l.classList.add("alt-speed"),a.append(l),d=document.createElement("input"),d.id="alt-speed-check",d.type="checkbox",d.checked=e[X._TurtleState],d.addEventListener("change",A=>{this.remote.savePrefs({[X._TurtleState]:A.target.checked})}),l.append(d),r.alt_speed_check=d,c=document.createElement("label"),c.id="alt-speed-image",c.setAttribute("for",d.id),l.append(c),c=document.createElement("label"),c.id="alt-speed-label",c.setAttribute("for",d.id),c.textContent="Use Temp limits",l.append(c),c=document.createElement("label"),c.id="alt-speed-values-label",c.setAttribute("for",d.id);let y=G.speed(e[X._TurtleUpSpeedLimit]),B=G.speed(e[X._TurtleDownSpeedLimit]);c.textContent=`(${y} up, ${B} down)`,l.append(c),i=We("actions","Actions"),n.append(i);for(let A of["show-preferences-dialog","show-shortcuts-dialog","pause-all-torrents","start-all-torrents"]){let v=this.action_manager.text(A);t[A]=St(i,v,A,o)}i=We("help","Help"),n.append(i),a=document.createElement("div"),i.append(a);for(let A of["show-statistics-dialog","show-about-dialog"]){let v=this.action_manager.text(A);t[A]=St(a,v,A,o)}let x=document.createElement("a");return x.href="https://transmissionbt.com/donate.html",x.target="_blank",x.textContent="Donate",a.append(x),this._updateElement=this._updateElement.bind(this),{actions:t,elements:r,root:n}}};var Le=class s extends EventTarget{static _initTimeDropDown(e){for(let t=0;t<24*4;++t){let r=Number.parseInt(t/4,10),o=t%4*15,n=t*15,i=`${r}:${o||"00"}`;e.options[t]=new Option(i,n)}}static _initDayDropDown(e){let t=[["Everyday","127"],["Weekdays","62"],["Weekends","65"],["Sunday","1"],["Monday","2"],["Tuesday","4"],["Wednesday","8"],["Thursday","16"],["Friday","32"],["Saturday","64"]];for(let r=0;t[r];++r){let[o,n]=t[r];e.options[r]=new Option(o,n)}}_checkPort(){for(let[e,t]of Object.entries(this.elements.network.port_status_label))delete t.dataset.open,h(t,"Checking..."),this.remote.checkPort(e,r=>this._onPortChecked(e,r),this)}_onPortChecked(e,t){if(this.closed)return;let r=this.elements.network.port_status_label[e],o=t.arguments["port-is-open"]||!1;r.dataset.open=o,"port-is-open"in t.arguments?h(r,o?"Open":"Closed"):h(r,"Error")}_setBlocklistButtonEnabled(e){let t=this.elements.peers.blocklist_update_button;O(t,e),t.value=e?"Update":"Updating..."}static _getValue(e){if(e.tagName==="TEXTAREA")return e.value;switch(e.type){case"checkbox":case"radio":return e.checked;case"number":case"select-one":case"text":case"url":{let t=e.value;return Number.parseInt(t,10).toString()===t?Number.parseInt(t,10):Number.parseFloat(t).toString()===t?Number.parseFloat(t):t}default:return null}}_onMaybePortChanged(e){(e==="peer-port"||e==="port-forwarding-enabled")&&this._checkPort()}_onControlChanged(e){let{key:t}=e.target.dataset;this.remote.savePrefs({[t]:s._getValue(e.target)}),this._onMaybePortChanged(t)}_onDialogClosed(){this.dispatchEvent(new Event("closed"))}_update(){this._setBlocklistButtonEnabled(!0);for(let[e,t]of Object.entries(this.session_manager.session_properties))for(let r of this.elements.root.querySelectorAll(`[data-key="${e}"]`))if(e==="blocklist-size"){let o=G.number(t);r.innerHTML=`Blocklist has ${o} rules`,h(this.elements.peers.blocklist_update_button,"Update")}else switch(r.type){case"checkbox":case"radio":r.checked=t;break;case"text":case"textarea":case"url":case"email":case"number":case"search":r!==document.activeElement&&(r.value!=t&&this._onMaybePortChanged(e),r.value=t);break;case"select-one":r.value=t;break;default:console.log(r.type);break}}shouldAddedTorrentsStart(){return this.data.elements.root.find("#start-added-torrents")[0].checked}static _createCheckAndLabel(e,t){let r=document.createElement("div");r.id=e;let o=document.createElement("input");o.id=W(),o.type="checkbox",r.append(o);let n=document.createElement("label");return n.textContent=t,n.setAttribute("for",o.id),r.append(n),{check:o,label:n,root:r}}static _enableIfChecked(e,t){let r=()=>{e.tagName==="INPUT"?O(e,t.checked):e.classList.toggle("disabled",!t.checked)};t.addEventListener("change",r),r()}static _getProtocolHandlerRegistered(){return localStorage.getItem("protocol-handler-registered")==="true"}static _updateProtocolHandlerButton(e){e.removeAttribute("disabled"),e.removeAttribute("title"),s._getProtocolHandlerRegistered()?(e.textContent="Remove Browser Handler","unregisterProtocolHandler"in navigator||e.setAttribute("title","Your browser does not support removing protocol handlers. This button only allows you to re-register a handler.")):(e.textContent="Add Browser Handler",e.removeAttribute("title"),"registerProtocolHandler"in navigator||(e.setAttribute("disabled",!0),e.setAttribute("title","Your browser does not support protocol handlers")))}static _toggleProtocolHandler(e){let t=new URL(window.location.href);t.search="addtorrent=%s",this._getProtocolHandlerRegistered()?(navigator.unregisterProtocolHandler?.("magnet",t.toString()),localStorage.removeItem("protocol-handler-registered"),s._updateProtocolHandlerButton(e)):(navigator.registerProtocolHandler("magnet",t.toString(),"Transmission Web"),localStorage.setItem("protocol-handler-registered","true"),s._updateProtocolHandlerButton(e))}static _createTorrentsPage(){let e=document.createElement("div");e.classList.add("prefs-torrents-page");let t=document.createElement("div");t.textContent="Downloading",t.classList.add("section-label"),e.append(t),t=document.createElement("label"),t.textContent="Download to:",e.append(t);let r=document.createElement("input");r.type="text",r.id=W(),r.dataset.key="download-dir",t.setAttribute("for",r.id),e.append(r);let o=r,n=s._createCheckAndLabel("incomplete-dir-div","Use temporary folder:");n.check.title="Separate folder to temporarily store downloads until they are complete.",n.check.dataset.key="incomplete-dir-enabled",n.label.title=n.check.title,e.append(n.root);let i=n.check;r=document.createElement("input"),r.type="text",r.dataset.key="incomplete-dir",e.append(r),s._enableIfChecked(r,n.check);let a=r;n=s._createCheckAndLabel("autostart-div","Start when added"),n.check.dataset.key="start-added-torrents",e.append(n.root);let l=n.check;n=s._createCheckAndLabel("suffix-div",`Append "part" to incomplete files' names`),n.check.dataset.key="rename-partial-files",e.append(n.root);let c=n.check;n=s._createCheckAndLabel("download-queue-div","Download queue size:"),n.check.dataset.key="download-queue-enabled",e.append(n.root);let u=n.check;r=document.createElement("input"),r.type="number",r.dataset.key="download-queue-size",e.append(r),s._enableIfChecked(r,n.check);let g=r;t=document.createElement("div"),t.textContent="Seeding",t.classList.add("section-label"),e.append(t),n=s._createCheckAndLabel("stop-ratio-div","Stop seeding at ratio:"),n.check.dataset.key="seedRatioLimited",e.append(n.root);let d=n.check;r=document.createElement("input"),r.type="number",r.min="0.1",r.step="any",r.dataset.key="seedRatioLimit",e.append(r),s._enableIfChecked(r,n.check);let p=r;n=s._createCheckAndLabel("stop-idle-div","Stop seeding if idle for N mins:"),n.check.dataset.key="idle-seeding-limit-enabled",e.append(n.root);let b=n.check;r=document.createElement("input"),r.type="number",r.min="0.1",r.step="any",r.dataset.key="idle-seeding-limit",e.append(r),s._enableIfChecked(r,n.check);let I=r;t=document.createElement("div"),t.textContent="Magnet Protocol Handler",t.classList.add("section-label"),e.append(t);let C=document.createElement("button");return C.classList.add("register-handler-button"),s._updateProtocolHandlerButton(C),e.append(C),{autostart_check:l,download_dir:o,download_queue_check:u,download_queue_input:g,incomplete_dir_check:i,incomplete_dir_input:a,register_handler_button:C,root:e,stop_idle_check:b,stop_idle_input:I,stop_ratio_check:d,stop_ratio_input:p,suffix_check:c}}static _createSpeedPage(){let e=document.createElement("div");e.classList.add("prefs-speed-page");let t=document.createElement("div");t.textContent="Speed Limits",t.classList.add("section-label"),e.append(t);let r=s._createCheckAndLabel("upload-speed-div","Upload (kB/s):");r.check.dataset.key="speed-limit-up-enabled",e.append(r.root);let o=r.check,n=document.createElement("input");n.type="number",n.dataset.key="speed-limit-up",e.append(n),s._enableIfChecked(n,r.check);let i=n;r=s._createCheckAndLabel("download-speed-div","Download (kB/s):"),r.check.dataset.key="speed-limit-down-enabled",e.append(r.root);let a=r.check;n=document.createElement("input"),n.type="number",n.dataset.key="speed-limit-down",e.append(n),s._enableIfChecked(n,r.check);let l=n;t=document.createElement("div"),t.textContent="Alternative Speed Limits",t.classList.add("section-label","alt-speed-section-label"),e.append(t),t=document.createElement("div"),t.textContent="Override normal speed limits manually or at scheduled times",t.classList.add("alt-speed-label"),e.append(t),t=document.createElement("label"),t.textContent="Upload (kB/s):",e.append(t),n=document.createElement("input"),n.type="number",n.dataset.key="alt-speed-up",n.id=W(),t.setAttribute("for",n.id),e.append(n);let c=n;t=document.createElement("label"),t.textContent="Download (kB/s):",e.append(t),n=document.createElement("input"),n.type="number",n.dataset.key="alt-speed-down",n.id=W(),t.setAttribute("for",n.id),e.append(n);let u=n;r=s._createCheckAndLabel("alt-times-div","Scheduled times"),r.check.dataset.key="alt-speed-time-enabled",e.append(r.root);let g=r.check;t=document.createElement("label"),t.textContent="From:",s._enableIfChecked(t,r.check),e.append(t);let d=document.createElement("select");d.id=W(),d.dataset.key="alt-speed-time-begin",s._initTimeDropDown(d),t.setAttribute("for",d.id),e.append(d),s._enableIfChecked(d,r.check);let p=d;t=document.createElement("label"),t.textContent="To:",s._enableIfChecked(t,r.check),e.append(t),d=document.createElement("select"),d.id=W(),d.dataset.key="alt-speed-time-end",s._initTimeDropDown(d),t.setAttribute("for",d.id),e.append(d),s._enableIfChecked(d,r.check);let b=d;return t=document.createElement("label"),t.textContent="On days:",s._enableIfChecked(t,r.check),e.append(t),d=document.createElement("select"),d.id=W(),d.dataset.key="alt-speed-time-day",s._initDayDropDown(d),t.setAttribute("for",d.id),e.append(d),s._enableIfChecked(d,r.check),{alt_days_select:d,alt_download_speed_input:u,alt_from_select:p,alt_times_check:g,alt_to_select:b,alt_upload_speed_input:c,download_speed_check:a,download_speed_input:l,root:e,upload_speed_check:o,upload_speed_input:i}}static _createPeersPage(){let e=document.createElement("div");e.classList.add("prefs-peers-page");let t=document.createElement("div");t.textContent="Connections",t.classList.add("section-label"),e.append(t),t=document.createElement("label"),t.textContent="Max peers per torrent:",e.append(t);let r=document.createElement("input");r.type="number",r.dataset.key="peer-limit-per-torrent",r.id=W(),t.setAttribute("for",r.id),e.append(r);let o=r;t=document.createElement("label"),t.textContent="Max peers overall:",e.append(t),r=document.createElement("input"),r.type="number",r.dataset.key="peer-limit-global",r.id=W(),t.setAttribute("for",r.id),e.append(r);let n=r;t=document.createElement("div"),t.textContent="Options",t.classList.add("section-label"),e.append(t),t=document.createElement("label"),t.textContent="Encryption mode:",e.append(t);let i=document.createElement("select");i.id=W(),i.dataset.key="encryption",i.options[0]=new Option("Prefer encryption","preferred"),i.options[1]=new Option("Allow encryption","tolerated"),i.options[2]=new Option("Require encryption","required"),e.append(i);let a=i,l=s._createCheckAndLabel("use-pex-div","Use PEX to find more peers");l.check.title="PEX is a tool for exchanging peer lists with the peers you're connected to.",l.check.dataset.key="pex-enabled",l.label.title=l.check.title,e.append(l.root);let c=l.check;l=s._createCheckAndLabel("use-dht-div","Use DHT to find more peers"),l.check.title="DHT is a tool for finding peers without a tracker.",l.check.dataset.key="dht-enabled",l.label.title=l.check.title,e.append(l.root);let u=l.check;l=s._createCheckAndLabel("use-lpd-div","Use LPD to find more peers"),l.check.title="LPD is a tool for finding peers on your local network.",l.check.dataset.key="lpd-enabled",l.label.title=l.check.title,e.append(l.root);let g=l.check;t=document.createElement("div"),t.textContent="Blocklist",t.classList.add("section-label"),e.append(t),l=s._createCheckAndLabel("blocklist-enabled-div","Enable blocklist:"),l.check.dataset.key="blocklist-enabled",e.append(l.root);let d=l.check;r=document.createElement("input"),r.type="url",r.value="http://www.example.com/blocklist",r.dataset.key="blocklist-url",e.append(r),s._enableIfChecked(r,l.check);let p=r;t=document.createElement("label"),t.textContent="Blocklist has {n} rules",t.dataset.key="blocklist-size",t.classList.add("blocklist-size-label"),s._enableIfChecked(t,l.check),e.append(t);let b=document.createElement("button");return b.classList.add("blocklist-update-button"),b.textContent="Update",e.append(b),s._enableIfChecked(b,l.check),{blocklist_enabled_check:d,blocklist_update_button:b,blocklist_url_input:p,dht_check:u,encryption_select:a,lpd_check:g,max_peers_overall_input:n,max_peers_per_torrent_input:o,pex_check:c,root:e}}static _createNetworkPage(){let e=document.createElement("div");e.classList.add("prefs-network-page");let t=document.createElement("div");t.textContent="Listening Port",t.classList.add("section-label"),e.append(t),t=document.createElement("label"),t.textContent="Peer listening port:",e.append(t);let r=document.createElement("input");r.type="number",r.dataset.key="peer-port",r.id=W(),t.setAttribute("for",r.id),e.append(r);let o=r,n=document.createElement("div");n.classList.add("port-status"),t=document.createElement("label"),t.textContent="IPv4 port is",n.append(t);let i=document.createElement("label");i.textContent="?",i.classList.add("port-status-label"),n.append(i),n.append(document.createElement("br")),t=document.createElement("label"),t.textContent="IPv6 port is",n.append(t);let a=document.createElement("label");a.textContent="?",a.classList.add("port-status-label"),n.append(a),e.append(n);let l=s._createCheckAndLabel("randomize-port","Randomize port on launch");l.check.dataset.key="peer-port-random-on-start",e.append(l.root);let c=l.check;l=s._createCheckAndLabel("port-forwarding","Use port forwarding from my router"),l.check.dataset.key="port-forwarding-enabled",e.append(l.root);let u=l.check;t=document.createElement("div"),t.textContent="Options",t.classList.add("section-label"),e.append(t),l=s._createCheckAndLabel("utp-enabled","Enable uTP for peer communication"),l.check.dataset.key="utp-enabled",e.append(l.root);let g=l.check;t=document.createElement("div"),t.textContent="Default Public Trackers",t.classList.add("section-label"),e.append(t);let d=["Trackers to use on all public torrents.","To add a backup URL, add it on the next line after a primary URL.","To add a new primary URL, add it after a blank line."];for(let I of d)t=document.createElement("label"),t.classList.add("default-trackers-label"),t.textContent=I,t.setAttribute("for","default-trackers"),e.append(t);let p=document.createElement("textarea");return p.dataset.key="default-trackers",p.id="default-trackers",e.append(p),{default_trackers_textarea:p,port_forwarding_check:u,port_input:o,port_status_label:{ipv4:i,ipv6:a},random_port_check:c,root:e,utp_check:g}}static _create(){let e={network:s._createNetworkPage(),peers:s._createPeersPage(),speed:s._createSpeedPage(),torrents:s._createTorrentsPage()};return{...Ge("prefs-dialog",[["prefs-tab-torrent",e.torrents.root,"Torrents"],["prefs-tab-speed",e.speed.root,"Speed"],["prefs-tab-peers",e.peers.root,"Peers"],["prefs-tab-network",e.network.root,"Network"]]),...e}}constructor(e,t){super(),this.closed=!1,this.session_manager=e,this.remote=t,this.update_from_session=()=>this._update(),this.elements=s._create(),this.elements.peers.blocklist_update_button.addEventListener("click",n=>{h(n.target,"Updating blocklist..."),this.remote.updateBlocklist(),this._setBlocklistButtonEnabled(!1)}),this.elements.torrents.register_handler_button.addEventListener("click",n=>{s._toggleProtocolHandler(n.currentTarget)}),this.elements.dismiss.addEventListener("click",()=>this.close()),this.outside=new K(this.elements.root),this.outside.addEventListener("click",()=>this.close()),Object.seal(this);let r=this._onControlChanged.bind(this),o=n=>{for(let i of Object.values(n))if(i.tagName==="INPUT")switch(i.type){case"checkbox":case"radio":case"number":case"text":case"url":i.addEventListener("change",r);break;default:console.trace(`unhandled input: ${i.type}`);break}else(i.tagName==="TEXTAREA"||i.tagName==="SELECT")&&i.addEventListener("change",r)};o(this.elements.network),o(this.elements.peers),o(this.elements.speed),o(this.elements.torrents),this.session_manager.addEventListener("session-change",this.update_from_session),this.update_from_session(),document.body.append(this.elements.root)}close(){if(!this.closed){this.outside.stop(),this.session_manager.removeEventListener("session-change",this.update_from_session),this.elements.root.remove(),dispatchEvent(new Event("close"));for(let e of Object.keys(this))this[e]=null;this.closed=!0}}};var Qe=class s extends EventTarget{constructor(e){super(),this.options=e,this.elements=s._create(e),this.elements.dismiss.addEventListener("click",()=>this._onDismiss()),this.elements.confirm.addEventListener("click",()=>this._onConfirm()),document.body.append(this.elements.root),this.elements.dismiss.focus()}close(){if(!this.closed){this.elements.root.remove(),this.dispatchEvent(new Event("close"));for(let e of Object.keys(this))delete this[e];this.closed=!0}}_onDismiss(){this.close()}_onConfirm(){let{remote:e,torrents:t,trash:r}=this.options;t.length>0&&e.removeTorrents(t,r),this.close()}static _create(e){let{trash:t}=e,{heading:r,message:o}=s._createMessage(e),n=L("remove-dialog");return n.heading.textContent=r,n.message.textContent=o,n.confirm.textContent=t?"Trash":"Remove",n}static _createMessage(e){let t=null,r=null,{torrents:o,trash:n}=e,[i]=o;return n&&o.length===1?(t=`Remove ${i.getName()} and delete data?`,r="All data downloaded for this torrent will be deleted. Are you sure you want to remove it?"):n?(t=`Remove ${o.length} transfers and delete data?`,r="All data downloaded for these torrents will be deleted. Are you sure you want to remove them?"):o.length===1?(t=`Remove ${i.getName()}?`,r="Once removed, continuing the transfer will require the torrent file. Are you sure you want to remove it?"):(t=`Remove ${o.length} transfers?`,r="Once removed, continuing the transfers will require the torrent files. Are you sure you want to remove them?"),{heading:t,message:r}}};var we=class s extends EventTarget{constructor(e,t){super(),this.controller=e,this.remote=t,this.elements={},this.torrents=[],this.show()}show(){let e=this.controller.getSelectedTorrents();if(e.length!==1){console.trace();return}this.torrents=e,this.elements=s._create(),this.elements.dismiss.addEventListener("click",()=>this._onDismiss()),this.elements.confirm.addEventListener("click",()=>this._onConfirm()),this.elements.entry.value=e[0].getName(),document.body.append(this.elements.root),this.elements.entry.focus()}close(){this.elements.root.remove(),this.dispatchEvent(new Event("close")),delete this.controller,delete this.remote,delete this.elements,delete this.torrents}_onDismiss(){this.close()}_onConfirm(){let[e]=this.torrents,t=e.getName(),r=this.elements.entry.value;this.remote.renameTorrent([e.getId()],t,r,o=>{o.result==="success"&&e.refresh(o.arguments)}),this.close()}static _create(){let e=L("rename-dialog");e.root.setAttribute("aria-label","Rename Torrent"),e.heading.textContent="Enter new name:",e.confirm.textContent="Rename";let t=document.createElement("label");t.setAttribute("for","torrent-rename-name"),t.textContent="Enter new name:",e.workarea.append(t);let r=document.createElement("input");return r.setAttribute("type","text"),r.id="torrent-rename-name",e.entry=r,e.workarea.append(r),e}};var Ue=class s extends EventTarget{constructor(e,t){super(),this.controller=e,this.remote=t,this.elements={},this.torrents=[],this.show()}show(){let e=this.controller.getSelectedTorrents();if(e.length===0){console.error("At least one selected torrent expected.");return}let[t]=e;this.torrents=e,this.elements=s._create(),this.elements.dismiss.addEventListener("click",()=>this._onDismiss()),this.elements.confirm.addEventListener("click",()=>this._onConfirm()),this.elements.entry.value=t.getLabels().join(", "),document.body.append(this.elements.root),this.elements.entry.focus()}close(){this.elements.root.remove(),this.dispatchEvent(new Event("close")),delete this.elements,delete this.torrents}_onDismiss(){this.close()}_onConfirm(){let{torrents:e}=this,{remote:t}=this,r=e.map(l=>l.getId()),{elements:o}=this,{entry:n}=o,{value:i}=n,a=i.split(/ *, */).filter(l=>l.length>0);t.setLabels(r,a,l=>{if(l.result==="success")for(let c of e)c.refresh({labels:a})}),this.close()}static _create(){let e=L("labels-dialog");e.root.setAttribute("aria-label","Edit Labels"),e.heading.textContent="Edit Labels:",e.confirm.textContent="Save";let t=document.createElement("label");t.setAttribute("for","torrent-labels"),t.textContent="Labels:",e.workarea.append(t);let r=document.createElement("input");return r.setAttribute("type","text"),r.id="torrent-labels",e.entry=r,e.workarea.append(r),e}};var ke=class s extends EventTarget{constructor(e){super(),this.elements=s._create(e),this.elements.dismiss.addEventListener("click",()=>this._onDismiss()),document.body.append(this.elements.root),this.elements.dismiss.focus()}close(){this.elements.root.remove(),this.dispatchEvent(new Event("close")),delete this.elements}_onDismiss(){this.close()}static _create(e){let t=L("shortcuts-dialog");t.root.setAttribute("aria-label","Keyboard Shortcuts");let r=document.createElement("table"),o=document.createElement("thead");r.append(o);let n=document.createElement("tr");o.append(n);let i=document.createElement("th");i.textContent="Key",n.append(i),i=document.createElement("th"),i.textContent="Action",n.append(i);let a=document.createElement("tbody");r.append(a);let l={};for(let[c,u]of e.allShortcuts().entries()){let g=c.split("+"),d=[g.pop(),...g].join("+");l[d]={name:u,shortcut:c}}for(let[,c]of Object.entries(l).sort()){let{name:u,shortcut:g}=c;n=document.createElement("tr"),a.append(n);let d=document.createElement("td");d.textContent=g.replaceAll("+"," + "),n.append(d),d=document.createElement("td"),d.textContent=e.text(u),n.append(d)}return t.heading.textContent="Transmission",t.dismiss.textContent="Close",t.heading.textContent="Keyboard shortcuts",t.message.append(r),t.confirm.remove(),delete t.confirm,t}};var Oe=class s extends EventTarget{constructor(e){super(),this.remote=e;let t=()=>this.remote.loadDaemonStats(o=>this._update(o.arguments)),r=5e3;this.interval=setInterval(t,r),t(),this.elements=s._create(),this.elements.dismiss.addEventListener("click",()=>this._onDismiss()),document.body.append(this.elements.root),this.elements.dismiss.focus()}close(){if(!this.closed){clearInterval(this.interval),this.elements.root.remove();for(let e of Object.keys(this))delete this[e];this.closed=!0}}_onDismiss(){this.close()}_update(e){console.log(e);let t=G,r=e["current-stats"],o=oe.ratio(r.uploadedBytes,r.downloadedBytes);h(this.elements.session.up,t.size(r.uploadedBytes)),h(this.elements.session.down,t.size(r.downloadedBytes)),this.elements.session.ratio.innerHTML=t.ratioString(o),h(this.elements.session.time,t.timeInterval(r.secondsActive)),r=e["cumulative-stats"],o=oe.ratio(r.uploadedBytes,r.downloadedBytes),h(this.elements.total.up,t.size(r.uploadedBytes)),h(this.elements.total.down,t.size(r.downloadedBytes)),this.elements.total.ratio.innerHTML=t.ratioString(o),h(this.elements.total.time,t.timeInterval(r.secondsActive))}static _create(){let e=L("statistics-dialog"),{confirm:t,dismiss:r,heading:o,root:n,workarea:i}=e;t.remove(),r.textContent="Close",delete e.confirm;let a="Statistics";n.setAttribute("aria-label",a),o.textContent=a;let l=["Uploaded:","Downloaded:","Ratio:","Running time:"],c=Ke("Current session",l),[u,g,d,p]=c.children,b=e.session={};b.up=u,b.down=g,b.ratio=d,b.time=p,i.append(c.root),c=Ke("Total",l);let[I,C,y,B]=c.children,x=e.total={};return x.up=I,x.down=C,x.ratio=y,x.time=B,i.append(c.root),e}};var Q={createIcon:s=>{let e=document.createElement("div");return e.classList.add("icon"),e.dataset.iconMimeType=s.getPrimaryMimeType().split("/",1).pop(),e.dataset.iconMultifile=s.getFileCount()>1?"true":"false",e},formatDL:s=>`\u25BC ${G.speedBps(s.getDownloadSpeed())}`,formatETA:s=>{let e=s.getETA();return e<0||e>=999*60*60?"":`ETA: ${G.timeInterval(e,1)}`},formatLabels:(s,e)=>{let t=s.getLabels();e.innerHTML="";for(let r of t){let o=document.createElement("span");o.classList.add("torrent-label"),o.textContent=r,e.append(o)}},formatUL:s=>`\u25B2 ${G.speedBps(s.getUploadSpeed())}`,getProgressInfo:(s,e)=>{let t=e.getStatus(),r=["torrent-progress-bar"],o=null;if(t===f._StatusStopped&&r.push("paused"),e.needsMetaData())r.push("magnet"),o=e.getMetadataPercentComplete()*100;else if(t===f._StatusCheck)r.push("verify"),o=e.getRecheckProgress()*100;else if(e.getLeftUntilDone()>0)r.push("leech"),o=e.getPercentDone()*100;else{r.push("seed");let n=e.seedRatioLimit(s);o=n>0?e.getUploadRatio()*100/n:100}return e.isQueued()&&r.push("queued"),{classList:r,percent:o}},renderProgressbar:(s,e,t)=>{let r=Q.getProgressInfo(s,e);t.className=r.classList.join(" "),t.style.setProperty("--progress",`${r.percent.toFixed(2)}%`)}},Re=class s{static getPeerDetails(e){let t=G,r=e.getErrorMessage();if(r)return r;if(e.isDownloading()){let o=e.getPeersConnected(),n=e.getWebseedsSendingToUs();return n&&o?["Downloading from",e.getPeersSendingToUs(),"of",t.countString("peer","peers",o),"and",t.countString("web seed","web seeds",n),"\u2013",Q.formatDL(e),Q.formatUL(e)].join(" "):n?["Downloading from",t.countString("web seed","web seeds",n),"\u2013",Q.formatDL(e),Q.formatUL(e)].join(" "):["Downloading from",e.getPeersSendingToUs(),"of",t.countString("peer","peers",o),"\u2013",Q.formatDL(e),Q.formatUL(e)].join(" ")}return e.isSeeding()?["Seeding to",e.getPeersGettingFromUs(),"of",t.countString("peer","peers",e.getPeersConnected()),"-",Q.formatUL(e)].join(" "):e.isChecking()?["Verifying local data (",G.percentString(100*e.getRecheckProgress()),"% tested)"].join(""):e.getStateString()}static getProgressDetails(e,t){if(t.needsMetaData()){let a="retrieving";t.isStopped()&&(a="needs");let l=100*t.getMetadataPercentComplete();return[`Magnetized transfer - ${a} metadata (`,G.percentString(l),"%)"].join("")}let r=t.getSizeWhenDone(),o=t.getTotalSize(),n=t.isDone()||t.isSeeding(),i=[];if(n?(o===r?i.push(G.size(o)):i.push(G.size(r)," of ",G.size(t.getTotalSize())," (",t.getPercentDoneStr(),"%)"),i.push(", uploaded ",G.size(t.getUploadedEver())," (Ratio ",G.ratioString(t.getUploadRatio()),")")):i.push(G.size(r-t.getLeftUntilDone())," of ",G.size(r)," (",t.getPercentDoneStr(),"%)"),!t.isStopped()&&(!n||t.seedRatioLimit(e)>0)){i.push(" - ");let a=t.getETA();a<0||a>=999*60*60?i.push("remaining time unknown"):i.push(G.timeInterval(t.getETA(),1)," remaining")}return i.join("")}render(e,t,r){let o=t.isStopped();r.classList.toggle("paused",o);let n=r._name_container;h(n,t.getName()),Q.formatLabels(t,r._labels_container),n=r._progress_details_container,n.innerHTML=s.getProgressDetails(e,t),Q.renderProgressbar(e,t,r._progressbar),r._progressbar.classList.add("full");let i=t.getError()!==f._ErrNone;n=r._peer_details_container,n.classList.toggle("error",i),h(n,s.getPeerDetails(t)),n=r._toggle_running_button,n.alt=o?"Resume":"Pause",n.dataset.action=o?"resume":"pause"}createRow(e){let t=document.createElement("li");t.className="torrent";let r=Q.createIcon(e),o=document.createElement("div");o.className="torrent-name";let n=document.createElement("div");n.className="torrent-labels";let i=document.createElement("div");i.className="torrent-progress-details";let a=document.createElement("div");a.classList.add("torrent-progress");let l=document.createElement("div");l.classList.add("torrent-progress-bar","full"),a.append(l);let c=document.createElement("div");c.className="torrent-peer-details";let u=document.createElement("a");return u.className="torrent-pauseresume-button",a.append(u),t.append(r),t.append(o),t.append(n),t.append(i),t.append(a),t.append(c),t._icon=r,t._name_container=o,t._labels_container=n,t._progress_details_container=i,t._progressbar=l,t._peer_details_container=c,t._toggle_running_button=u,t}},Te=class s{static getPeerDetails(e){let t=e.getErrorMessage();if(t)return t;if(e.isDownloading()){let r=e.getDownloadSpeed()>0,o=e.getUploadSpeed()>0;if(!o&&!r)return"Idle";let n=[`${Q.formatETA(e)} `];return r&&n.push(Q.formatDL(e)),o&&n.push(Q.formatUL(e)),n.join(" ")}return e.isSeeding()?`Ratio: ${G.ratioString(e.getUploadRatio())}, ${Q.formatUL(e)}`:e.getStateString()}render(e,t,r){r.classList.toggle("paused",t.isStopped());let o=r._name_container;h(o,t.getName()),Q.formatLabels(t,r._labels_container),Q.renderProgressbar(e,t,r._progressbar),r._progressbar.classList.add("compact");let n=t.getError()!==f._ErrNone;o=r._details_container,o.classList.toggle("error",n),h(o,s.getPeerDetails(t))}createRow(e){let t=document.createElement("div");t.classList.add("torrent-progress-bar","compact");let r=Q.createIcon(e),o=document.createElement("div");o.className="torrent-peer-details compact";let n=document.createElement("div");n.className="torrent-labels compact";let i=document.createElement("div");i.className="torrent-name compact";let a=document.createElement("li");return a.append(t),a.append(o),a.append(n),a.append(i),a.append(r),a.className="torrent compact",a._progressbar=t,a._details_container=o,a._labels_container=n,a._name_container=i,a}},Ye=class{constructor(e,t,r){this._view=e,this._torrent=r,this._element=e.createRow(r);let o=()=>this.render(t);this._torrent.addEventListener("dataChanged",o),o()}getElement(){return this._element}render(e){let t=this.getTorrent();t&&this._view.render(e,t,this.getElement())}isSelected(){return this.getElement().classList.contains("selected")}getTorrent(){return this._torrent}getTorrentId(){return this.getTorrent().getId()}};var Se=class s extends EventTarget{constructor(e,t,r){super(),this.action_manager=e,this.notifications=t,this.prefs=r,this.remote=new ie(this),this.addEventListener("torrent-selection-changed",i=>this.action_manager.update(i)),this.filterText="",this._torrents={},this._rows=[],this.dirtyTorrents=new Set,this.changeStatus=!1,this.refilterSoon=J(()=>this._refilter(!1)),this.refilterAllSoon=J(()=>this._refilter(!0)),this.boundPopupCloseListener=this.popupCloseListener.bind(this),this.isTouch="ontouchstart"in window,this.busyclick=!1;for(let i of document.querySelectorAll("button[data-action]")){let{action:a}=i.dataset;O(i,this.action_manager.isEnabled(a)),i.addEventListener("click",()=>{this.action_manager.click(a)})}document.querySelector("#filter-tracker").addEventListener("change",i=>{this.setFilterTracker(i.target.value==="all"?null:i.target.value)}),this.action_manager.addEventListener("change",i=>{for(let a of document.querySelectorAll(`[data-action="${i.action}"]`))O(a,i.enabled)}),this.action_manager.addEventListener("click",i=>{switch(i.action){case"deselect-all":this._deselectAll();break;case"move-bottom":this._moveBottom();break;case"move-down":this._moveDown();break;case"move-top":this._moveTop();break;case"move-up":this._moveUp();break;case"open-torrent":this.setCurrentPopup(new $(this,this.remote));break;case"pause-all-torrents":this._stopTorrents(this._getAllTorrents());break;case"pause-selected-torrents":this._stopTorrents(this.getSelectedTorrents());break;case"reannounce-selected-torrents":this._reannounceTorrents(this.getSelectedTorrents());break;case"remove-selected-torrents":this._removeSelectedTorrents(!1);break;case"resume-selected-torrents":this._startSelectedTorrents(!1);break;case"resume-selected-torrents-now":this._startSelectedTorrents(!0);break;case"select-all":this._selectAll();break;case"show-about-dialog":this.setCurrentPopup(new xe(this.version_info));break;case"show-inspector":this.popup instanceof ne?this.setCurrentPopup(null):this.setCurrentPopup(new ne(this));break;case"show-move-dialog":this.setCurrentPopup(new Fe(this,this.remote));break;case"show-overflow-menu":this.popup instanceof ae?this.setCurrentPopup(null):this.setCurrentPopup(new ae(this,this.prefs,this.remote,this.action_manager));break;case"show-preferences-dialog":this.setCurrentPopup(new Le(this,this.remote));break;case"show-shortcuts-dialog":this.setCurrentPopup(new ke(this.action_manager));break;case"show-statistics-dialog":this.setCurrentPopup(new Oe(this.remote));break;case"show-rename-dialog":this.setCurrentPopup(new we(this,this.remote));break;case"show-labels-dialog":this.setCurrentPopup(new Ue(this,this.remote));break;case"start-all-torrents":this._startTorrents(this._getAllTorrents());break;case"toggle-compact-rows":this.prefs.display_mode=this.prefs.display_mode===m.DisplayCompact?m.DisplayFull:m.DisplayCompact;break;case"trash-selected-torrents":this._removeSelectedTorrents(!0);break;case"verify-selected-torrents":this._verifyTorrents(this.getSelectedTorrents());break;default:console.warn(`unhandled action: ${i.action}`)}});let o=document.querySelector("#filter-mode");o.value=this.prefs.filter_mode,o.addEventListener("change",i=>{this.prefs.filter_mode=i.target.value,this.refilterAllSoon()}),document.addEventListener("keydown",this._keyDown.bind(this)),document.addEventListener("keyup",this._keyUp.bind(this)),o=document.querySelector("#torrent-container"),o.addEventListener("click",i=>{this.popup&&this.popup.name!=="inspector"&&this.setCurrentPopup(null),i.target===i.currentTarget&&this._deselectAll()}),o.addEventListener("dblclick",()=>{(!this.popup||this.popup.name!=="inspector")&&this.action_manager.click("show-inspector")}),o.addEventListener("dragenter",s._dragenter),o.addEventListener("dragover",s._dragenter),o.addEventListener("drop",this._drop.bind(this)),this._setupSearchBox(),this.elements={torrent_list:document.querySelector("#torrent-list")};let n=i=>{if(this.isTouch&&i.touches.length>1)return;let a=i.target;for(;a&&!a.classList.contains("torrent");)a=a.parentNode;let l=this._rows.find(b=>b.getElement()===a);l&&!l.isSelected()&&this._setSelectedRow(l);let c=new Ze(this.action_manager);this.setCurrentPopup(c);let g=document.querySelector("#torrent-container").getBoundingClientRect(),d=Math.min(this.isTouch?i.touches[0].clientX:i.x,g.x+g.width-c.root.clientWidth),p=Math.min(this.isTouch?i.touches[0].clientY:i.y,g.y+g.height-c.root.clientHeight);c.root.style.left=`${d>0?d:0}px`,c.root.style.top=`${p>0?p:0}px`,i.preventDefault()};this.isTouch?(this.elements.torrent_list.addEventListener("touchstart",i=>{this.busyclick?(clearTimeout(this.busyclick),this.busyclick=!1):this.busyclick=setTimeout(n.bind(this),500,i)}),this.elements.torrent_list.addEventListener("touchend",()=>{clearTimeout(this.busyclick),this.busyclick=!1,setTimeout(()=>{this.popup&&(this.popup.root.style.pointerEvents="auto")},1)}),this.elements.torrent_list.addEventListener("touchmove",()=>{clearTimeout(this.busyclick),this.busyclick=!1}),this.elements.torrent_list.addEventListener("contextmenu",i=>{i.preventDefault()})):this.elements.torrent_list.addEventListener("contextmenu",i=>{n(i),this.popup&&(this.popup.root.style.pointerEvents="auto")}),this.loadDaemonPrefs(),this._initializeTorrents(),this.refreshTorrents(),this.togglePeriodicSessionRefresh(!0),this.prefs.addEventListener("change",({key:i,value:a})=>this._onPrefChanged(i,a));for(let[i,a]of this.prefs.entries())this._onPrefChanged(i,a)}_openTorrentFromUrl(){setTimeout(()=>{let e=new URLSearchParams(window.location.search).get("addtorrent");if(e){this.setCurrentPopup(new $(this,this.remote,e));let t=new URL(window.location);t.search="",window.history.pushState("","",t.toString())}},0)}loadDaemonPrefs(){this.remote.loadDaemonPrefs(e=>{this.session_properties=e.arguments,this._openTorrentFromUrl()})}get session_properties(){return this._session_properties}set session_properties(e){if(Be(this._session_properties,e))return;this._session_properties=Object.seal(e);let t=new Event("session-change");t.session_properties=e,this.dispatchEvent(t),this._updateGuiFromSession(e)}_setupSearchBox(){let e=document.querySelector("#torrent-search"),t="blur";e.classList.add(t),e.addEventListener("blur",()=>e.classList.add(t)),e.addEventListener("focus",()=>e.classList.remove(t)),e.addEventListener("keyup",()=>this._setFilterText(e.value))}_onPrefChanged(e,t){switch(e){case m.DisplayMode:{this.torrentRenderer=t==="compact"?new Te:new Re,this.refilterAllSoon();break}case m.ContrastMode:{document.body.classList.remove("contrast-more"),document.body.classList.remove("contrast-less"),document.body.classList.add(`contrast-${t}`);break}case m.FilterMode:case m.SortDirection:case m.SortMode:this.refilterAllSoon();break;case m.RefreshRate:{clearInterval(this.refreshTorrentsInterval);let r=this.refreshTorrents.bind(this),o=Math.max(2,this.prefs.refresh_rate_sec)*1e3;this.refreshTorrentsInterval=setInterval(r,o);break}default:break}}_getAllTorrents(){return Object.values(this._torrents)}static _getTorrentIds(e){return e.map(t=>t.getId())}seedRatioLimit(){let e=this.session_properties;return e&&e.seedRatioLimited?e.seedRatioLimit:-1}_getSelectedRows(){return this._rows.filter(e=>e.isSelected())}getSelectedTorrents(){return this._getSelectedRows().map(e=>e.getTorrent())}_getSelectedTorrentIds(){return s._getTorrentIds(this.getSelectedTorrents())}_setSelectedRow(e){let t=e?e.getElement():null;for(let r of this.elements.torrent_list.children)r.classList.toggle("selected",r===t);this._dispatchSelectionChanged()}_selectRow(e){e.getElement().classList.add("selected"),this._dispatchSelectionChanged()}_deselectRow(e){e.getElement().classList.remove("selected"),this._dispatchSelectionChanged()}_selectAll(){for(let e of this.elements.torrent_list.children)e.classList.add("selected");this._dispatchSelectionChanged()}_deselectAll(){for(let e of this.elements.torrent_list.children)e.classList.remove("selected");this._dispatchSelectionChanged(),delete this._last_torrent_clicked}_indexOfLastTorrent(){return this._rows.findIndex(e=>e.getTorrentId()===this._last_torrent_clicked)}_selectRange(e){let t=this._indexOfLastTorrent();if(t===-1)this._selectRow(e);else{let r=this._rows.indexOf(e),o=Math.min(t,r),n=Math.max(t,r);for(let i=o;i<=n;++i)this._selectRow(this._rows[i])}this._dispatchSelectionChanged()}_dispatchSelectionChanged(){let e=[],t=[];for(let o of this._rows)(o.isSelected()?t:e).push(o.getTorrent());let r=new Event("torrent-selection-changed");r.nonselected=e,r.selected=t,this.dispatchEvent(r)}static _createKeyShortcutFromKeyboardEvent(e){let t=[];return e.ctrlKey&&t.push("Control"),e.altKey&&t.push("Alt"),e.metaKey&&t.push("Meta"),e.shitKey&&t.push("Shift"),t.push(e.key.length===1?e.key.toUpperCase():e.key),t.join("+")}_keyDown(e){let{ctrlKey:t,keyCode:r,metaKey:o,shiftKey:n,target:i}=e,a=["INPUT","TEXTAREA"].includes(i.tagName);if(!a){let g=s._createKeyShortcutFromKeyboardEvent(e),d=this.action_manager.getActionForShortcut(g);if(d){e.preventDefault(),this.action_manager.click(d);return}}if(r===27&&this.popup){this.setCurrentPopup(null),e.preventDefault();return}let c=document.querySelector(".popup:not(.hidden)"),u=this._rows;if(!a&&!c&&!o&&!t){let g=r===16,d=r===38,p=r===40;if((d||p)&&u.length>0){let b=this._indexOfLastTorrent(),I=this._shift_index,C=0,y=u.length-1,B=b;p&&B+1<=y?++B:d&&B-1>=C&&--B;let x=u[B];I>=0?I<=b&&b=b&&b>B?this._selectRow(x):(I>=b&&B>b||I<=b&&b>B)&&this._deselectRow(u[b]):n?this._selectRange(x):this._setSelectedRow(x),x&&(this._last_torrent_clicked=x.getTorrentId(),x.getElement().scrollIntoView(),e.preventDefault())}else g&&(this._shift_index=this._indexOfLastTorrent())}}_keyUp(e){e.keyCode===16&&delete this._shift_index}static _dragenter(e){if(e.dataTransfer&&e.dataTransfer.types){let t=new Set(["text/uri-list","text/plain"]);if(e.dataTransfer.types.some(r=>t.has(r))||e.dataTransfer.types.includes("Files"))return e.stopPropagation(),e.preventDefault(),e.dataTransfer.dropEffect="copy",!1}else e.dataTransfer&&(e.dataTransfer.dropEffect="none");return!0}static _isValidURL(e){try{return!!new URL(e)}catch{return!1}}shouldAddedTorrentsStart(){return this.session_properties["start-added-torrents"]}_drop(e){let t=!this.shouldAddedTorrentsStart();if(!e.dataTransfer||!e.dataTransfer.types)return!0;let r=e.dataTransfer.types.filter(n=>["text/uri-list","text/plain"].includes(n)).pop();for(let n of e.dataTransfer.getData(r).split(`
-`).map(i=>i.trim()).filter(i=>s._isValidURL(i)))this.remote.addTorrentByUrl(n,t);let{files:o}=e.dataTransfer;return o.length>0&&(this.openDialog=new $(this,this.remote,"",o)),e.preventDefault(),!1}togglePeriodicSessionRefresh(e){!e&&this.sessionInterval&&(clearInterval(this.sessionInterval),delete this.sessionInterval),e&&(this.loadDaemonPrefs(),this.sessionInterval||(this.sessionInterval=setInterval(this.loadDaemonPrefs.bind(this),8e3)))}_setFilterText(e){this.filterText=e?e.trim():null,this.refilterAllSoon()}_onTorrentChanged(e){this.changeStatus&&(this._dispatchSelectionChanged(),this.changeStatus=!1);let t=e.currentTarget;this.dirtyTorrents.add(t.getId()),this.refilterSoon()}updateTorrents(e,t){this.remote.updateTorrents(e,t,(r,o)=>{let n=[],i=r.shift(),a={};for(let l of r){for(let[g,d]of i.entries())a[d]=l[g];let{id:c}=a,u=this._torrents[c];if(u){let g=u.needsMetaData();u.refresh(a),g&&!u.needsMetaData()&&n.push(c)}else u=this._torrents[c]=new f(a),u.addEventListener("dataChanged",this._onTorrentChanged.bind(this)),this.dirtyTorrents.add(c),(!("name"in u.fields)||!("status"in u.fields))&&n.push(c)}if(n.length>0){let l=["id",...f.Fields.Metadata,...f.Fields.Stats];this.updateTorrents(n,l),this.refilterSoon()}o&&(this._deleteTorrents(o),this.refilterSoon())})}refreshTorrents(){let e=["id",...f.Fields.Stats];this.updateTorrents("recently-active",e)}_initializeTorrents(){let e=["id",...f.Fields.Metadata,...f.Fields.Stats];this.updateTorrents(null,e)}_onRowClicked(e){let t=e.metaKey||e.ctrlKey,{row:r}=e.currentTarget;if(this.popup&&this.popup.name!=="inspector"&&this.setCurrentPopup(null),e.target.classList.contains("torrent-pauseresume-button"))switch(e.target.dataset.action){case"pause":this._stopTorrents([r.getTorrent()]);break;case"resume":this._startTorrents([r.getTorrent()]);break;default:break}e.stopPropagation(),e.shiftKey?(this._selectRange(r),window.focus()):!r.isSelected()&&t?this._selectRow(r):r.isSelected()?r.isSelected()&&t?this._deselectRow(r):r.isSelected()&&this._setSelectedRow(r):this._setSelectedRow(r),this._last_torrent_clicked=r.getTorrentId()}_deleteTorrents(e){if(e&&e.length>0){for(let t of e)this.dirtyTorrents.add(t),delete this._torrents[t];this.refilterSoon()}}_removeSelectedTorrents(e){let t=this.getSelectedTorrents();t.length>0&&this.setCurrentPopup(new Qe({remote:this.remote,torrents:t,trash:e}))}_startSelectedTorrents(e){this._startTorrents(this.getSelectedTorrents(),e)}_startTorrents(e,t){this.changeStatus=!0,this.remote.startTorrents(s._getTorrentIds(e),t,this.refreshTorrents,this)}_verifyTorrents(e){this.remote.verifyTorrents(s._getTorrentIds(e),this.refreshTorrents,this)}_reannounceTorrents(e){this.remote.reannounceTorrents(s._getTorrentIds(e),this.refreshTorrents,this)}_stopTorrents(e){this.changeStatus=!0,this.remote.stopTorrents(s._getTorrentIds(e),()=>{setTimeout(()=>{this.refreshTorrents()},500)},this)}changeFileCommand(e,t,r){this.remote.changeFileCommand(e,t,r)}_moveTop(){this.remote.moveTorrentsToTop(this._getSelectedTorrentIds(),this.refreshTorrents,this)}_moveUp(){this.remote.moveTorrentsUp(this._getSelectedTorrentIds(),this.refreshTorrents,this)}_moveDown(){this.remote.moveTorrentsDown(this._getSelectedTorrentIds(),this.refreshTorrents,this)}_moveBottom(){this.remote.moveTorrentsToBottom(this._getSelectedTorrentIds(),this.refreshTorrents,this)}_updateGuiFromSession(e){let[,t,r]=e.version.match(/(.*)\s\(([\da-f]+)\)/);this.version_info={checksum:r,version:t},document.querySelector("#toolbar-overflow").classList.toggle("alt-speed-enabled",e[X._TurtleState])}_updateStatusbar(){let e=G,t=this._getAllTorrents(),r=t.reduce((i,a)=>i+a.getUploadSpeed(),0),o=t.reduce((i,a)=>i+a.getDownloadSpeed(),0),n=e.countString("Transfer","Transfers",this._rows.length);h(document.querySelector("#speed-up-label"),e.speedBps(r)),h(document.querySelector("#speed-dn-label"),e.speedBps(o)),h(document.querySelector("#filter-count"),n)}static _displayName(e){let t=e;return t.length>0&&(t=t.charAt(0).toUpperCase()+t.slice(1)),t}_updateFilterSelect(){let e=this._getTrackerCounts(),t=Object.keys(e).sort(),r="";r+=this.filterTracker?'':'';for(let o of t)r+=``;(!this.filterTrackersStr||this.filterTrackersStr!==r)&&(this.filterTrackersStr=r,document.querySelector("#filter-tracker").innerHTML=r)}sortRows(e){let t=e.map(o=>o.getTorrent()),r=e.reduce((o,n)=>(o[n.getTorrent().getId()]=n,o),{});f.sortTorrents(t,this.prefs.sort_mode,this.prefs.sort_direction);for(let[o,n]of t.entries())e[o]=r[n.getId()]}_refilter(e){let{sort_mode:t,sort_direction:r,filter_mode:o}=this.prefs,n=this.filterTracker,i=this.torrentRenderer,a=this.elements.torrent_list,l=null,c=null,u=/^labels:([\w,-\s]*)(.*)$/.exec(this.filterText);u?(l=u[2].trim(),c=u[1].split(",")):(l=this.filterText,c=[]);let g=()=>[...a.children].length,d=()=>[...a.children].reduce((F,w)=>F+w.classList.contains("selected")?1:0,0),p=g(),b=d();if(this._updateFilterSelect(),clearTimeout(this.refilterTimer),delete this.refilterTimer,e){for(;a.firstChild;)a.firstChild.remove();this._rows=[],this.dirtyTorrents=new Set(Object.keys(this._torrents))}let I=[],C=[];for(let F of this._rows)this.dirtyTorrents.has(F.getTorrentId())?C.push(F):I.push(F);for(let F of C)F.getElement().remove();let y=[];for(let F of C){let w=F.getTorrentId(),k=this._torrents[w];k&&k.test(o,n,l,c)&&y.push(F),this.dirtyTorrents.delete(w)}C=y;for(let F of this.dirtyTorrents.values()){let w=this._torrents[F];if(w&&w.test(o,n,l,c)){let k=new Ye(i,this,w),qe=k.getElement();qe.row=k,C.push(k),qe.addEventListener("click",this._onRowClicked.bind(this))}}this.sortRows(C);let B=[],x=I.length,A=C.length,v=document.createDocumentFragment(),U=0,ce=0;for(;U!==x||ce!==A;){let F=null;if(U===x?F=!1:ce===A?F=!0:F=f.compareTorrents(I[U].getTorrent(),C[ce].getTorrent(),t,r)<0,F)B.push(I[U++]);else{let w=C[ce++],k=w.getElement();U===x?v.append(k):a.insertBefore(k,I[U].getElement()),B.push(w)}}a.append(v),this._rows=B,this.dirtyTorrents.clear();for(let[F,w]of B.map(k=>k.getElement()).entries()){let k=F%2===0;w.classList.toggle("even",k),w.classList.toggle("odd",!k)}this._updateStatusbar(),(b!==d()||p!==g())&&this._dispatchSelectionChanged()}setFilterTracker(e){let t=document.querySelector("#filter-tracker");t.value=e,this.filterTracker=e,this.refilterAllSoon()}_getTrackerCounts(){let e={};for(let t of this._getAllTorrents())for(let r of t.getTrackers()){let{sitename:o}=r;e[o]=(e[o]||0)+1}return e}popupCloseListener(e){if(e.target!==this.popup)throw new Error(e);this.popup.removeEventListener("close",this.boundPopupCloseListener),delete this.popup}setCurrentPopup(e){this.popup&&this.popup.close(),this.popup=e,this.popup&&this.popup.addEventListener("close",this.boundPopupCloseListener)}};function Qs(){let s=new le,e=new m,t=new ye(e),r=new Se(s,t,e),o=J(()=>r.elements.torrent_list.scrollTo(0,1));window.addEventListener("load",o),window.addEventListener("orientationchange",o)}document.addEventListener("DOMContentLoaded",Qs);})();
+(()=>{var Vt=Object.create;var et=Object.defineProperty;var St=Object.getOwnPropertyDescriptor;var Dt=Object.getOwnPropertyNames;var Et=Object.getPrototypeOf,_t=Object.prototype.hasOwnProperty;var Jt=(o,e)=>()=>(e||o((e={exports:{}}).exports,e),e.exports);var Ht=(o,e,t,r)=>{if(e&&typeof e=="object"||typeof e=="function")for(let s of Dt(e))!_t.call(o,s)&&s!==t&&et(o,s,{get:()=>e[s],enumerable:!(r=St(e,s))||r.enumerable});return o};var zt=(o,e,t)=>(t=o!=null?Vt(Et(o)):{},Ht(e||!o||!o.__esModule?et(t,"default",{value:o,enumerable:!0}):t,o));var Ot=Jt((q,M)=>{var jt=200,Ke="__lodash_hash_undefined__",Ie=1,ut=2,pt=9007199254740991,de="[object Arguments]",Ee="[object Array]",Mt="[object AsyncFunction]",bt="[object Boolean]",mt="[object Date]",ht="[object Error]",It="[object Function]",Kt="[object GeneratorFunction]",ge="[object Map]",Ct="[object Number]",Pt="[object Null]",j="[object Object]",tt="[object Promise]",$t="[object Proxy]",ft="[object RegExp]",ue="[object Set]",At="[object String]",qt="[object Symbol]",er="[object Undefined]",_e="[object WeakMap]",yt="[object ArrayBuffer]",pe="[object DataView]",tr="[object Float32Array]",rr="[object Float64Array]",or="[object Int8Array]",sr="[object Int16Array]",ir="[object Int32Array]",nr="[object Uint8Array]",ar="[object Uint8ClampedArray]",cr="[object Uint16Array]",lr="[object Uint32Array]",dr=/[\\^$.*+?()[\]{}|]/g,gr=/^\[object .+?Constructor\]$/,ur=/^(?:0|[1-9]\d*)$/,Z={};Z[tr]=Z[rr]=Z[or]=Z[sr]=Z[ir]=Z[nr]=Z[ar]=Z[cr]=Z[lr]=!0;Z[de]=Z[Ee]=Z[yt]=Z[bt]=Z[pe]=Z[mt]=Z[ht]=Z[It]=Z[ge]=Z[Ct]=Z[j]=Z[ft]=Z[ue]=Z[At]=Z[_e]=!1;var Bt=typeof global=="object"&&global&&global.Object===Object&&global,pr=typeof self=="object"&&self&&self.Object===Object&&self,R=Bt||pr||Function("return this")(),Gt=typeof q=="object"&&q&&!q.nodeType&&q,rt=Gt&&typeof M=="object"&&M&&!M.nodeType&&M,vt=rt&&rt.exports===Gt,Ve=vt&&Bt.process,ot=function(){try{return Ve&&Ve.binding&&Ve.binding("util")}catch{}}(),st=ot&&ot.isTypedArray;function br(o,e){for(var t=-1,r=o==null?0:o.length,s=0,i=[];++t-1}function _r(o,e){var t=this.__data__,r=fe(t,o);return r<0?(++this.size,t.push([o,e])):t[r][1]=e,this}Y.prototype.clear=Vr;Y.prototype.delete=Sr;Y.prototype.get=Dr;Y.prototype.has=Er;Y.prototype.set=_r;function _(o){var e=-1,t=o==null?0:o.length;for(this.clear();++ea))return!1;var c=i.get(o);if(c&&i.get(e))return c==e;var u=-1,g=!0,d=t&ut?new me:void 0;for(i.set(o,e),i.set(e,o);++u-1&&o%1==0&&o-1&&o%1==0&&o<=pt}function Qt(o){var e=typeof o;return o!=null&&(e=="object"||e=="function")}function re(o){return o!=null&&typeof o=="object"}var kt=st?Cr(st):ao;function Bo(o){return Ao(o)?oo(o):co(o)}function Go(){return[]}function vo(){return!1}M.exports=yo});var le=class o extends EventTarget{constructor(){super(),this.actions=Object.seal({"deselect-all":{enabled:!1,shortcut:"D",text:"Deselect all"},"move-bottom":{enabled:!1,text:"Move to the back of the queue"},"move-down":{enabled:!1,text:"Move down in the queue"},"move-top":{enabled:!1,text:"Move to the front of the queue"},"move-up":{enabled:!1,text:"Move up in the queue"},"open-torrent":{enabled:!0,shortcut:"O",text:"Open torrent\u2026"},"pause-all-torrents":{enabled:!1,text:"Pause all"},"pause-selected-torrents":{enabled:!1,shortcut:"U",text:"Pause"},"reannounce-selected-torrents":{enabled:!1,text:"Ask tracker for more peers"},"remove-selected-torrents":{enabled:!1,text:"Remove from list\u2026"},"resume-selected-torrents":{enabled:!1,shortcut:"R",text:"Resume"},"resume-selected-torrents-now":{enabled:!1,text:"Resume now"},"select-all":{enabled:!1,shortcut:"A",text:"Select all"},"show-about-dialog":{enabled:!0,text:"About"},"show-inspector":{enabled:!1,shortcut:"I",text:"Torrent Inspector"},"show-labels-dialog":{enabled:!1,shortcut:"K",text:"Edit Labels\u2026"},"show-move-dialog":{enabled:!1,shortcut:"L",text:"Set location\u2026"},"show-overflow-menu":{enabled:!0,text:"More options\u2026"},"show-preferences-dialog":{enabled:!0,shortcut:"P",text:"Edit preferences"},"show-rename-dialog":{enabled:!1,shortcut:"N",text:"Rename\u2026"},"show-shortcuts-dialog":{enabled:!0,text:"Keyboard shortcuts"},"show-statistics-dialog":{enabled:!0,shortcut:"S",text:"Statistics"},"start-all-torrents":{enabled:!1,text:"Start all"},"toggle-compact-rows":{enabled:!0,text:"Compact rows"},"toggle-contrast":{enabled:!0,text:"High contrast UI"},"trash-selected-torrents":{enabled:!1,text:"Trash data and remove from list\u2026"},"verify-selected-torrents":{enabled:!1,shortcut:"V",text:"Verify local data"}})}click(e){if(this.isEnabled(e)){let t=new Event("click");t.action=e,this.dispatchEvent(t)}}getActionForShortcut(e){for(let[t,r]of Object.entries(this.actions))if(e===r.shortcut)return t;return null}allShortcuts(){return new Map(Object.entries(this.actions).filter(([,e])=>e.shortcut).map(([e,t])=>[t.shortcut,e]))}isEnabled(e){return this._getAction(e).enabled}text(e){return this._getAction(e).text}keyshortcuts(e){return this._getAction(e).shortcut}update(e){let t=o._recount(e.selected,e.nonselected);this._updateStates(t)}_getAction(e){let t=this.actions[e];if(!t)throw new Error(`no such action: ${e}`);return t}static _recount(e,t){let r=e.length+t.length,s=e.filter(g=>g.isStopped()).length,i=e.length-s,n=t.filter(g=>g.isStopped()).length,a=t.length-n,l=s+n,c=i+a,u=e.filter(g=>g.isQueued()).length;return{active:c,nonselected_active:a,nonselected_paused:n,paused:l,selected:e.length,selected_active:i,selected_paused:s,selected_queued:u,total:r}}_updateStates(e){let t=(r,s)=>{for(let i of s)this._updateActionState(i,r)};t(e.selected_paused>0,["resume-selected-torrents"]),t(e.paused>0,["start-all-torrents"]),t(e.active>0,["pause-all-torrents"]),t(e.selected_paused>0||e.selected_queued>0,["resume-selected-torrents-now"]),t(e.selected_active>0,["pause-selected-torrents","reannounce-selected-torrents"]),t(e.selected>0,["deselect-all","move-bottom","move-down","move-top","move-up","remove-selected-torrents","show-inspector","show-labels-dialog","show-move-dialog","trash-selected-torrents","verify-selected-torrents"]),t(e.selected===1,["show-rename-dialog"]),t(e.selectedxo(s,g,n,c,t))}return a[0].classList.add("selected"),n.children[0].classList.remove("hidden"),{buttons:a,dismiss:i,root:r}}function W(o){let e=document.createElement("dialog");e.classList.add("dialog-container","popup",o),e.open=!0,e.setAttribute("role","dialog");let t=document.createElement("div");t.classList.add("dialog-window"),e.append(t);let r=document.createElement("div");r.classList.add("dialog-logo"),t.append(r);let s=document.createElement("div");s.classList.add("dialog-heading"),t.append(s);let i=document.createElement("div");i.classList.add("dialog-message"),t.append(i);let n=document.createElement("div");n.classList.add("dialog-workarea"),t.append(n);let a=document.createElement("div");a.classList.add("dialog-buttons"),t.append(a);let l=document.createElement("span");l.classList.add("dialog-buttons-begin"),a.append(l);let c=document.createElement("button");c.classList.add("dialog-dismiss-button"),c.textContent="Cancel",a.append(c);let u=document.createElement("button");u.textContent="OK",a.append(u),t.addEventListener("keyup",({key:d})=>{d==="Enter"&&u.click()});let g=document.createElement("span");return g.classList.add("dialog-buttons-end"),a.append(g),{confirm:u,dismiss:c,heading:s,message:i,root:e,workarea:n}}function F(){return typeof crypto.randomUUID=="function"?crypto.randomUUID():("10000000-1000-4000-8000"+-1e11).replaceAll(/[018]/g,o=>(o^crypto.getRandomValues(new Uint8Array(1))[0]&15>>o/4).toString(16))}function Zo(o){let e=document.createElement("fieldset");e.classList.add("section");let t=document.createElement("legend");t.classList.add("title"),t.textContent=o,e.append(t);let r=document.createElement("div");return r.classList.add("content"),e.append(r),{content:r,root:e}}function Pe(o,e){let t=[],{root:r,content:s}=Zo(o);for(let i of e){let n=document.createElement("label");n.textContent=i,s.append(n);let a=document.createElement("div");a.id=F(),s.append(a),n.setAttribute("for",a.id),t.push(a)}return{children:t,root:r}}function H(o,e=100){let t=null;return(...r)=>{t||(t=setTimeout(()=>{t=null,o(...r)},e))}}function Be(o,e){return(0,Tt.default)(o,e)}function Xo(o,e,t){t?o.setAttribute(e,!0):o.removeAttribute(e)}function Q(o,e){Xo(o,"disabled",!e)}function Ge(o,e){o.classList.toggle("checked",e)}var P=class extends EventTarget{constructor(e){super(),this.listener=t=>{e.contains(t.target)||(this.dispatchEvent(new MouseEvent(t.type,t)),t.preventDefault())},Object.seal(this),this.start()}start(){setTimeout(()=>document.addEventListener("click",this.listener),0)}stop(){document.removeEventListener("click",this.listener)}};function h(o,e){o.textContent!==e&&(o.textContent=e)}var ve=class{constructor(e){this._prefs=e,this._elements={toggle:document.querySelector("#toggle-notifications")}}_setEnabled(e){this.prefs.notifications_enabled=e,h(this._toggle,`${e?"Disable":"Enable"} Notifications`)}_requestPermission(){Notification.requestPermission().then(e=>this._setEnabled(e==="granted"))}toggle(){this._enabled?this._setEnabled(!1):Notification.permission==="granted"?this._setEnabled(!0):Notification.permission!=="denied"&&this._requestPermission()}};var b=class o extends EventTarget{constructor(){super(),this._cache={},this.dispatchPrefsChange=H((e,t,r)=>{let s=new Event("change");Object.assign(s,{key:e,old_value:t,value:r}),this.dispatchEvent(s)});for(let[e,t]of Object.entries(o._Defaults))this._set(e,o._getCookie(e,t)),Object.defineProperty(this,e.replaceAll("-","_"),{get:()=>this._get(e),set:r=>{this._set(e,r)}});Object.seal(this)}entries(){return Object.entries(this._cache)}keys(){return Object.keys(this._cache)}_get(e){let{_cache:t}=this;if(!Object.prototype.hasOwnProperty.call(t,e))throw new Error(e);return t[e]}_set(e,t){let{_cache:r}=this,s=r[e];s!==t&&(r[e]=t,o._setCookie(e,t),this.dispatchPrefsChange(e,s,t))}static _setCookie(e,t){let r=new Date;r.setFullYear(r.getFullYear()+1),document.cookie=`${e}=${t}; SameSite=Strict; expires=${r.toGMTString()}`}static _getCookie(e,t){let r=o._readCookie(e);return r===null?t:r==="true"?!0:r==="false"?!1:/^\d+$/.test(r)?Number.parseInt(r,10):r}static _readCookie(e){let r=`; ${document.cookie}`.split(`; ${e}=`);return r.length===2?r.pop().split(";").shift():null}};b.AltSpeedEnabled="alt-speed-enabled";b.DisplayCompact="compact";b.DisplayFull="full";b.DisplayMode="display-mode";b.ContrastLess="less";b.ContrastMore="more";b.ContrastMode="contrast-mode";b.FilterActive="active";b.FilterAll="all";b.FilterDownloading="downloading";b.FilterFinished="finished";b.FilterMode="filter-mode";b.FilterPaused="paused";b.FilterSeeding="seeding";b.NotificationsEnabled="notifications-enabled";b.RefreshRate="refresh-rate-sec";b.SortAscending="ascending";b.SortByActivity="activity";b.SortByAge="age";b.SortByName="name";b.SortByProgress="progress";b.SortByQueue="queue";b.SortByRatio="ratio";b.SortBySize="size";b.SortByState="state";b.SortDescending="descending";b.SortDirection="sort-direction";b.SortMode="sort-mode";b._Defaults={[b.AltSpeedEnabled]:!1,[b.DisplayMode]:b.DisplayFull,[b.ContrastMode]:window.matchMedia("(prefers-contrast: more)").matches?b.ContrastMore:b.ContrastLess,[b.FilterMode]:b.FilterAll,[b.NotificationsEnabled]:!1,[b.RefreshRate]:5,[b.SortDirection]:b.SortAscending,[b.SortMode]:b.SortByName};var xe=class o extends EventTarget{constructor(e){super(),this.elements=o._create(e),this.elements.dismiss.addEventListener("click",()=>this.close()),document.body.append(this.elements.root),this.elements.dismiss.focus()}close(){this.elements.root.remove(),this.dispatchEvent(new Event("close")),delete this.elements}static _create(e){let t=W("about-dialog");t.root.setAttribute("aria-label","About transmission"),t.heading.textContent="Transmission",t.dismiss.textContent="Close";let r=document.createElement("div");return r.classList.add("about-dialog-version-number"),r.textContent=e.version,t.heading.append(r),r=document.createElement("div"),r.classList.add("about-dialog-version-checksum"),r.textContent=e.checksum,t.heading.append(r),r=document.createElement("div"),r.textContent="A fast and easy bitTorrent client",t.workarea.append(r),r=document.createElement("div"),r.textContent="Copyright \xA9 The Transmission Project",t.workarea.append(r),r=document.createElement("a"),r.href="https://transmissionbt.com/",r.target="_blank",r.textContent="https://transmissionbt.com/",t.workarea.append(r),t.confirm.remove(),delete t.confirm,t}};var Ze=class extends EventTarget{constructor(e){super(),this.action_listener=this._update.bind(this),this.action_manager=e,this.action_manager.addEventListener("change",this.action_listener),Object.assign(this,this._create()),this.show()}show(){for(let[e,t]of Object.entries(this.actions))Q(t,this.action_manager.isEnabled(e));document.body.append(this.root)}close(){if(!this.closed){this.action_manager.removeEventListener("change",this.action_listener),this.root.remove(),this.dispatchEvent(new Event("close"));for(let e of Object.keys(this))delete this[e];this.closed=!0}}_update(e){let t=this.actions[e.action];t&&Q(t,e.enabled)}_create(){let e=document.createElement("div");e.role="menu",e.classList.add("context-menu","popup"),e.addEventListener("contextmenu",i=>{i.preventDefault()}),e.style.pointerEvents="none";let t={},r=(i,n=!1)=>{let a=document.createElement("div"),l=this.action_manager.text(i);a.role="menuitem",n?a.classList.add("context-menuitem","warning"):a.classList.add("context-menuitem"),a.dataset.action=i,a.textContent=l;let c=this.action_manager.keyshortcuts(i);c&&a.setAttribute("aria-keyshortcuts",c),a.addEventListener("click",()=>{this.action_manager.click(i),this.close()}),t[i]=a,e.append(a)},s=()=>{let i=document.createElement("div");i.classList.add("context-menu-separator"),e.append(i)};return r("resume-selected-torrents"),r("resume-selected-torrents-now"),r("pause-selected-torrents"),s(),r("move-top"),r("move-up"),r("move-down"),r("move-bottom"),s(),r("remove-selected-torrents",!0),r("trash-selected-torrents",!0),s(),r("verify-selected-torrents"),r("show-move-dialog"),r("show-rename-dialog"),r("show-labels-dialog"),s(),r("reannounce-selected-torrents"),s(),r("select-all"),r("deselect-all"),{actions:t,root:e}}};var Rt=new Intl.PluralRules,N=Rt.resolvedOptions().locale,Fo=new Intl.NumberFormat(N),$e=1e3,Wo=[new Intl.NumberFormat(N,{maximumFractionDigits:0,style:"unit",unit:"byte"}),new Intl.NumberFormat(N,{maximumFractionDigits:0,style:"unit",unit:"kilobyte"}),new Intl.NumberFormat(N,{maximumFractionDigits:0,style:"unit",unit:"megabyte"}),new Intl.NumberFormat(N,{maximumFractionDigits:2,style:"unit",unit:"gigabyte"}),new Intl.NumberFormat(N,{maximumFractionDigits:2,style:"unit",unit:"terabyte"}),new Intl.NumberFormat(N,{maximumFractionDigits:2,style:"unit",unit:"petabyte"})],Lo=new Intl.NumberFormat(N,{maximumFractionDigits:2,style:"unit",unit:"kilobyte-per-second"}),wo=new Intl.NumberFormat(N,{maximumFractionDigits:2,style:"unit",unit:"megabyte-per-second"}),y={_toTruncFixed(o,e){return(Math.floor(o*10**e)/10**e).toFixed(e)},countString(o,e,t){return`${this.number(t)} ${this.ngettext(o,e,t)}`},mem(o){if(o<0)return"Unknown";if(o===0)return"None";let e=o;for(let t of Wo){if(e<$e)return t.format(e);e/=$e}return"E2BIG"},ngettext(o,e,t){return Rt.select(t)==="one"?o:e},number(o){return Fo.format(o)},percentString(o,e){return e=o<100?e:0,this._toTruncFixed(o,e)},ratioString(o){return o===-1?"None":o===-2?"∞":this.percentString(o,1)},size(o){return this.mem(o)},speed(o){return o<999.95?Lo.format(o):wo.format(o/1e3)},speedBps(o){return this.speed(this.toKBps(o))},stringSanitizer(o){return["E2BIG","NaN"].some(e=>o.includes(e))?"\u2026":o},timeInterval(o,e=3){let t=Math.floor(o/86400),r=[];t&&r.push(this.countString("day","days",t));let s=Math.floor(o%86400/3600);(t||s)&&r.push(this.countString("hour","hours",s));let i=Math.floor(o%3600/60);return t||s||i?(r.push(this.countString("minute","minutes",i)),r=r.slice(0,e),r.length>1?`${r.slice(0,-1).join(", ")} and ${r.slice(-1)}`:r[0]):this.countString("second","seconds",Math.floor(o%60))},timestamp(o){if(!o)return"N/A";let e=new Date(o*1e3),t=new Date,r="",s="",i=t.getFullYear()===e.getFullYear(),n=t.getMonth()===e.getMonth(),a=t.getDate()-e.getDate();i&&n&&Math.abs(a)<=1?a===0?r="Today":a===1?r="Yesterday":r="Tomorrow":r=e.toDateString();let l=e.getHours(),c="AM";l>12&&(l=l-12,c="PM"),l===0&&(l=12),l<10&&(l=`0${l}`);let u=e.getMinutes();return u<10&&(u=`0${u}`),o=e.getSeconds(),o<10&&(o=`0${o}`),s=[l,u,o].join(":"),[r,s,c].join(" ")},toKBps(o){return Math.floor(o/$e)}};var Xe=class extends EventTarget{isDone(){return this.fields.have>=this.fields.size}isEditable(){return this.fields.torrent.getFileCount()>1&&!this.isDone()}refreshWantedHTML(){let e=this.elements.root;e.classList.toggle("skip",!this.fields.isWanted),e.classList.toggle("complete",this.isDone()),Q(e.checkbox,this.isEditable()),e.checkbox.checked=this.fields.isWanted}refreshProgressHTML(){let{size:e,have:t}=this.fields,r=100*(e?t/e:1),s=y,i=`${s.size(t)} of ${s.size(e)} (${s.percentString(r,1)}%)`;h(this.elements.progress,i)}refresh(){let e=0,t=!1,r=!1,s=!1,i=0,n=!1,a=this.fields.torrent.getFiles();for(let l of this.fields.indices){let c=a[l];switch(e+=c.bytesCompleted,i+=c.length,n|=c.wanted,c.priority.toString()){case"-1":r=!0;break;case"1":t=!0;break;default:s=!0;break}}Ge(this.elements.priority_low_button,r),Ge(this.elements.priority_normal_button,s),Ge(this.elements.priority_high_button,t),(this.fields.have!==e||this.fields.size!==i)&&(this.fields.have=e,this.fields.size=i,this.refreshProgressHTML()),this.fields.isWanted!==n&&(this.fields.isWanted=n,this.refreshWantedHTML())}fireWantedChanged(e){let t=new Event("wantedToggled");t.indices=[...this.fields.indices],t.wanted=e,this.dispatchEvent(t)}firePriorityChanged(e){let t=new Event("priorityToggled");t.indices=[...this.fields.indices],t.priority=e,this.dispatchEvent(t)}createRow(e,t,r){let s=document.createElement("li");s.classList.add("inspector-torrent-file-list-entry"),this.elements.root=s;let i=document.createElement("input"),n=F();i.type="checkbox",i.className="file-wanted-control",i.title="Download file",i.id=n,i.addEventListener("change",c=>this.fireWantedChanged(c.target.checked)),s.checkbox=i,s.append(i),i=document.createElement("label"),i.className="inspector-torrent-file-list-entry-name",i.setAttribute("for",n),h(i,r),s.append(i),i=document.createElement("div"),i.className="inspector-torrent-file-list-entry-progress",s.append(i),this.elements.progress=i,i=document.createElement("div"),i.className="file-priority-radiobox";let a=i,l=c=>this.firePriorityChanged(c.target.value);i=document.createElement("input"),i.type="radio",i.value="-1",i.className="low",i.title="Low Priority",i.addEventListener("click",l),this.elements.priority_low_button=i,a.append(i),i=document.createElement("input"),i.type="radio",i.value="0",i.className="normal",i.title="Normal Priority",i.addEventListener("click",l),this.elements.priority_normal_button=i,a.append(i),i=document.createElement("input"),i.type="radio",i.value="1",i.title="High Priority",i.className="high",i.addEventListener("click",l),this.elements.priority_high_button=i,a.append(i),s.append(a),s.style.paddingLeft=`${t*20}px`,this.refresh()}getElement(){return this.elements.root}constructor(e,t,r,s){super(),this.fields={have:0,indices:s,isWanted:!0,size:0,torrent:e},this.elements={priority_high_button:null,priority_low_button:null,priority_normal_button:null,progress:null,root:null},this.createRow(e,t,r)}};var f=class o extends EventTarget{constructor(e){super(),this.fieldObservers={},this.fields={},this.refresh(e)}notifyOnFieldChange(e,t){this.fieldObservers[e]=this.fieldObservers[e]||[],this.fieldObservers[e].push(t)}setField(e,t,r){let s=e[t];if(Be(s,r))return!1;let i=this.fieldObservers[t];if(e===this.fields&&i&&i.length>0)for(let n of i)n.call(this,r,s,t);return e[t]=r,!0}updateFiles(e){let t=!1,r=this.fields.files||[],s=["length","name","bytesCompleted","wanted","priority"];for(let[i,n]of e.entries()){let a=r[i]||{};for(let l of s)l in n&&(t|=this.setField(a,l,n[l]));r[i]=a}return this.fields.files=r,t}static collateTrackers(e){return e.map(t=>t.announce.toLowerCase()).join(" ")}refreshFields(e){let t=!1;for(let[r,s]of Object.entries(e))switch(r){case"files":case"fileStats":t|=this.updateFiles(s);break;case"trackerStats":t|=this.setField(this.fields,"trackers",s);break;case"trackers":r in this.fields||(t|=this.setField(this.fields,r,s));break;case"name":this.setField(this.fields,r,e[r])&&(this.fields.collatedName="",t=!0);break;default:t|=this.setField(this.fields,r,s)}return t}refresh(e){this.refreshFields(e)&&this.dispatchEvent(new Event("dataChanged"))}getComment(){return this.fields.comment}getCreator(){return this.fields.creator}getDateAdded(){return this.fields.addedDate}getDateCreated(){return this.fields.dateCreated}getDesiredAvailable(){return this.fields.desiredAvailable}getDownloadDir(){return this.fields.downloadDir}getDownloadSpeed(){return this.fields.rateDownload}getDownloadedEver(){return this.fields.downloadedEver}getError(){return this.fields.error}getErrorString(){return this.fields.errorString}getETA(){return this.fields.eta}getFailedEver(){return this.fields.corruptEver}getFiles(){return this.fields.files||[]}getFile(e){return this.fields.files[e]}getFileCount(){return this.fields["file-count"]}getHashString(){return this.fields.hashString}getHave(){return this.getHaveValid()+this.getHaveUnchecked()}getHaveUnchecked(){return this.fields.haveUnchecked}getHaveValid(){return this.fields.haveValid}getId(){return this.fields.id}getLabels(){return this.fields.labels.sort()}getLastActivity(){return this.fields.activityDate}getLeftUntilDone(){return this.fields.leftUntilDone}getMagnetLink(){return this.fields.magnetLink}getMetadataPercentComplete(){return this.fields.metadataPercentComplete}getName(){return this.fields.name||"Unknown"}getPeers(){return this.fields.peers||[]}getPeersConnected(){return this.fields.peersConnected}getPeersGettingFromUs(){return this.fields.peersGettingFromUs}getPeersSendingToUs(){return this.fields.peersSendingToUs}getPieceCount(){return this.fields.pieceCount}getPieceSize(){return this.fields.pieceSize}getPrimaryMimeType(){return this.fields["primary-mime-type"]||"application/octet-stream"}getPrivateFlag(){return this.fields.isPrivate}getQueuePosition(){return this.fields.queuePosition}getRecheckProgress(){return this.fields.recheckProgress}getSeedRatioLimit(){return this.fields.seedRatioLimit}getSeedRatioMode(){return this.fields.seedRatioMode}getSizeWhenDone(){return this.fields.sizeWhenDone}getStartDate(){return this.fields.startDate}getStatus(){return this.fields.status}getTotalSize(){return this.fields.totalSize}getTrackers(){return this.fields.trackers||[]}getUploadSpeed(){return this.fields.rateUpload}getUploadRatio(){return this.fields.uploadRatio}getUploadedEver(){return this.fields.uploadedEver}getWebseedsSendingToUs(){return this.fields.webseedsSendingToUs}isFinished(){return this.fields.isFinished}hasExtraInfo(){return"hashString"in this.fields}isSeeding(){return this.getStatus()===o._StatusSeed}isStopped(){return this.getStatus()===o._StatusStopped}isChecking(){return this.getStatus()===o._StatusCheck}isDownloading(){return this.getStatus()===o._StatusDownload}isQueued(){return this.getStatus()===o._StatusDownloadWait||this.getStatus()===o._StatusSeedWait}isDone(){return this.getLeftUntilDone()<1}needsMetaData(){return this.getMetadataPercentComplete()<1}getActivity(){return this.getDownloadSpeed()+this.getUploadSpeed()}getPercentDoneStr(){return y.percentString(100*this.getPercentDone(),1)}getPercentDone(){return this.fields.percentDone}getStateString(){switch(this.getStatus()){case o._StatusStopped:return this.isFinished()?"Seeding complete":"Paused";case o._StatusCheckWait:return"Queued for verification";case o._StatusCheck:return"Verifying local data";case o._StatusDownloadWait:return"Queued for download";case o._StatusDownload:return"Downloading";case o._StatusSeedWait:return"Queued for seeding";case o._StatusSeed:return"Seeding";case null:return"Unknown";default:return"Error"}}seedRatioLimit(e){switch(this.getSeedRatioMode()){case o._RatioUseGlobal:return e.seedRatioLimit();case o._RatioUseLocal:return this.getSeedRatioLimit();default:return-1}}getErrorMessage(){let e=this.getErrorString();switch(this.getError()){case o._ErrTrackerWarning:return`Tracker returned a warning: ${e}`;case o._ErrTrackerError:return`Tracker returned an error: ${e}`;case o._ErrLocalError:return`Error: ${e}`;default:return null}}getCollatedName(){let e=this.fields;return!e.collatedName&&e.name&&(e.collatedName=e.name.toLowerCase()),e.collatedName||""}getCollatedTrackers(){let e=this.fields;return!e.collatedTrackers&&e.trackers&&(e.collatedTrackers=o.collateTrackers(e.trackers)),e.collatedTrackers||""}testState(e){let t=this.getStatus();switch(e){case b.FilterActive:return this.getPeersGettingFromUs()>0||this.getPeersSendingToUs()>0||this.getWebseedsSendingToUs()>0||this.isChecking();case b.FilterSeeding:return t===o._StatusSeed||t===o._StatusSeedWait;case b.FilterDownloading:return t===o._StatusDownload||t===o._StatusDownloadWait;case b.FilterPaused:return this.isStopped();case b.FilterFinished:return this.isFinished();default:return!0}}test(e,t,r,s){let i=this.testState(e);if(i&&r&&(i=this.getCollatedName().includes(r.toLowerCase())),i){let n=this.getLabels();s.length>0&&(i=s.some(a=>n.includes(a)))}return i&&t&&t.length>0&&(i=this.getCollatedTrackers().includes(t)),i}static compareById(e,t){return e.getId()-t.getId()}static compareByName(e,t){return e.getCollatedName().localeCompare(t.getCollatedName())||o.compareById(e,t)}static compareByQueue(e,t){return e.getQueuePosition()-t.getQueuePosition()}static compareByAge(e,t){let r=e.getDateAdded();return t.getDateAdded()-r||o.compareByQueue(e,t)}static compareByState(e,t){let r=e.getStatus();return t.getStatus()-r||o.compareByQueue(e,t)}static compareByActivity(e,t){let r=e.getActivity();return t.getActivity()-r||o.compareByState(e,t)}static compareByRatio(e,t){let r=e.getUploadRatio(),s=t.getUploadRatio();return rs?-1:o.compareByState(e,t)}static compareByProgress(e,t){let r=e.getPercentDone(),s=t.getPercentDone();return r-s||o.compareByRatio(e,t)}static compareBySize(e,t){let r=e.getTotalSize(),s=t.getTotalSize();return r-s||o.compareByName(e,t)}static compareTorrents(e,t,r,s){let i=0;switch(r){case b.SortByActivity:i=o.compareByActivity(e,t);break;case b.SortByAge:i=o.compareByAge(e,t);break;case b.SortByQueue:i=o.compareByQueue(e,t);break;case b.SortByProgress:i=o.compareByProgress(e,t);break;case b.SortBySize:i=o.compareBySize(e,t);break;case b.SortByState:i=o.compareByState(e,t);break;case b.SortByRatio:i=o.compareByRatio(e,t);break;case b.SortByName:i=o.compareByName(e,t);break;default:console.log(`Unrecognized sort mode: ${r}`),i=o.compareByName(e,t);break}return s===b.SortDescending&&(i=-i),i}static sortTorrents(e,t,r){switch(t){case b.SortByActivity:e.sort(this.compareByActivity);break;case b.SortByAge:e.sort(this.compareByAge);break;case b.SortByName:e.sort(this.compareByName);break;case b.SortByProgress:e.sort(this.compareByProgress);break;case b.SortByQueue:e.sort(this.compareByQueue);break;case b.SortByRatio:e.sort(this.compareByRatio);break;case b.SortBySize:e.sort(this.compareBySize);break;case b.SortByState:e.sort(this.compareByState);break;default:console.log(`Unrecognized sort mode: ${t}`),e.sort(this.compareByName);break}return r===b.SortDescending&&e.reverse(),e}};f._StatusStopped=0;f._StatusCheckWait=1;f._StatusCheck=2;f._StatusDownloadWait=3;f._StatusDownload=4;f._StatusSeedWait=5;f._StatusSeed=6;f._RatioUseGlobal=0;f._RatioUseLocal=1;f._RatioUnlimited=2;f._ErrNone=0;f._ErrTrackerWarning=1;f._ErrTrackerError=2;f._ErrLocalError=3;f._TrackerInactive=0;f._TrackerWaiting=1;f._TrackerQueued=2;f._TrackerActive=3;f.Fields={};f.Fields.Metadata=["addedDate","file-count","name","primary-mime-type","totalSize"];f.Fields.Stats=["error","errorString","eta","isFinished","isStalled","labels","leftUntilDone","metadataPercentComplete","peersConnected","peersGettingFromUs","peersSendingToUs","percentDone","queuePosition","rateDownload","rateUpload","recheckProgress","seedRatioMode","seedRatioLimit","sizeWhenDone","status","trackers","downloadDir","uploadedEver","uploadRatio","webseedsSendingToUs"];f.Fields.InfoExtra=["comment","creator","dateCreated","files","hashString","isPrivate","magnetLink","pieceCount","pieceSize"];f.Fields.StatsExtra=["activityDate","corruptEver","desiredAvailable","downloadedEver","fileStats","haveUnchecked","haveValid","peers","startDate","trackerStats"];var Yt=["encryption","speed-up","speed-down","percent-done","status","peer-address","peer-app-name"],ie=class o extends EventTarget{constructor(e){super(),this.closed=!1,this.controller=e,this.elements=this._create(),this.current_page=this.elements.info.root,this.interval=setInterval(this._refreshTorrents.bind(this),3e3),this.name="inspector",this.selection_listener=t=>this._setTorrents(t.selected),this.torrent_listener=()=>this._updateCurrentPage(),this.torrents=[],this.file_torrent=null,this.file_torrent_n=null,this.file_rows=null,this.elements.dismiss.addEventListener("click",()=>this.close()),Object.seal(this),e.addEventListener("torrent-selection-changed",this.selection_listener),this._setTorrents(this.controller.getSelectedTorrents()),document.body.append(this.elements.root)}close(){if(!this.closed){clearInterval(this.interval),this._setTorrents([]),this.elements.root.remove(),this.controller.removeEventListener("torrent-selection-changed",this.selection_listener),this.dispatchEvent(new Event("close"));for(let e of Object.keys(this))this[e]=null;this.closed=!0}}static _createInfoPage(){let e=document.createElement("div");e.classList.add("inspector-info-page");let t={root:e},r=n=>{let a=document.createElement("div");a.textContent=n,a.classList.add("section-label"),e.append(a)},s=n=>{let a=document.createElement("label");h(a,n),e.append(a);let l=document.createElement("span");return e.append(l),l};r("Activity");let i=[["have","Have:"],["availability","Availability:"],["uploaded","Uploaded:"],["downloaded","Downloaded:"],["state","State:"],["running_time","Running time:"],["remaining_time","Remaining:"],["last_activity","Last activity:"],["error","Error:"]];for(let[n,a]of i)t[n]=s(a);r("Details"),i=[["name","Name:"],["size","Size:"],["location","Location:"],["hash","Hash:"],["privacy","Privacy:"],["origin","Origin:"],["dateAdded","Date added:"],["magnetLink","Magnet:"],["comment","Comment:"],["labels","Labels:"]];for(let[n,a]of i)t[n]=s(a);return t}static _createListPage(e,t){let r=document.createElement("div"),s=document.createElement(e);return s.id=t,r.append(s),{list:s,root:r}}static _createTiersPage(){return o._createListPage("div","inspector-tiers-list")}static _createFilesPage(){return o._createListPage("ul","inspector-file-list")}static _createPeersPage(){let e=document.createElement("table");e.classList.add("peer-list");let t=document.createElement("thead"),r=document.createElement("tr"),s=["","Up","Down","Done","Status","Address","Client"];for(let[n,a]of s.entries()){let l=document.createElement("th"),c=Yt[n];c==="encryption"&&(l.dataset.encrypted=!0),l.classList.add(c),h(l,a),r.append(l)}let i=document.createElement("tbody");return t.append(r),e.append(t),e.append(i),{root:e,tbody:i}}_create(){let e={files:o._createFilesPage(),info:o._createInfoPage(),peers:o._createPeersPage(),tiers:o._createTiersPage()},t=s=>{this.current_page=s,this._updateCurrentPage()};return{...ye("inspector",[["inspector-tab-info",e.info.root,"Info"],["inspector-tab-peers",e.peers.root,"Peers"],["inspector-tab-tiers",e.tiers.root,"Tiers"],["inspector-tab-files",e.files.root,"Files"]],t.bind(this)),...e}}_setTorrents(e){let t="dataChanged",r=this.torrent_listener;for(let s of this.torrents)s.removeEventListener(t,r);this.torrents=[...e];for(let s of this.torrents)s.addEventListener(t,r);this._refreshTorrents(),this._updateCurrentPage()}static _needsExtraInfo(e){return e.some(t=>!t.hasExtraInfo())}_refreshTorrents(){let{controller:e,torrents:t}=this,r=t.map(s=>s.getId());if(r&&r.length>0){let s=["id",...f.Fields.StatsExtra];o._needsExtraInfo(t)&&s.push(...f.Fields.InfoExtra),e.updateTorrents(r,s)}}_updateCurrentPage(){let{current_page:e,elements:t}=this;switch(e){case t.files.root:this._updateFiles();break;case t.info.root:this._updateInfo();break;case t.peers.root:this._updatePeers();break;case t.tiers.root:this._updateTiers();break;default:console.warn("unexpected page"),console.log(e)}}_updateInfo(){let e="None",t="Mixed",r="Unknown",s=y,i=Date.now(),{elements:n,torrents:a}=this,l=a.reduce((g,d)=>g+d.getSizeWhenDone(),0),c=null;if(a.length===0)c=e;else if(a.every(g=>g.isFinished()))c="Finished";else if(a.every(g=>g.isStopped()))c="Paused";else{let g=p=>p.getStateString(),d=g(a[0]);c=a.every(p=>g(p)===d)?d:t}h(n.info.state,c);let u=c;if(a.length===0)c=e;else{let g=a.reduce((I,C)=>I+C.getHaveValid(),0),d=a.reduce((I,C)=>I+C.getHaveUnchecked(),0),p=a.reduce((I,C)=>I+C.getLeftUntilDone(),0),m=100*(l?(l-p)/l:1);c=s.percentString(m,1),d?c=`${s.size(g)} of ${s.size(l)} (${c}%), ${s.size(d)} Unverified`:p?c=`${s.size(g)} of ${s.size(l)} (${c}%)`:c=`${s.size(g)} (100%)`}if(h(n.info.have,s.stringSanitizer(c)),a.length===0)c=e;else if(l===0)c=e;else{let g=a.reduce((d,p)=>p.getHave()+p.getDesiredAvailable(),0);c=`${s.percentString(100*g/l,1)}%`}if(h(n.info.availability,s.stringSanitizer(c)),a.length===0)c=e;else{let g=a.reduce((p,m)=>p+m.getDownloadedEver(),0),d=a.reduce((p,m)=>p+m.getFailedEver(),0);c=d?`${s.size(g)} (+${s.size(d)} discarded after failed checksum)`:s.size(g)}if(h(n.info.downloaded,s.stringSanitizer(c)),a.length===0)c=e;else{let g=a.reduce((p,m)=>p+m.getUploadedEver(),0),d=a.reduce((p,m)=>p+m.getSizeWhenDone(),0)||a.reduce((p,m)=>p+m.getHaveValid(),0);c=`${s.size(g)} (Ratio: ${s.ratioString(se.ratio(g,d))})`}if(h(n.info.uploaded,c),a.length===0)c=e;else if(a.every(g=>g.isStopped()))c=u;else{let g=p=>p.getStartDate(),d=g(a[0]);c=a.every(p=>g(p)===d)?s.timeInterval(i/1e3-d):t}if(h(n.info.running_time,c),a.length===0)c=e;else{let g=p=>p.getETA(),d=g(a[0]);a.every(p=>g(p)===d)?d<0?c=r:c=s.timeInterval(d):c=t}if(h(n.info.remaining_time,c),a.length===0)c=e;else{let g=a.reduce((p,m)=>Math.max(p,m.getLastActivity()),-1),d=Math.floor(i/1e3);if(0p.getErrorString(),d=g(a[0]);c=a.every(p=>g(p)===d)?d:t}if(h(n.info.error,c||e),a.length===1?c=a[0].getName():c=a.length>0?t:e,h(n.info.name,c),a.length===0)c=e;else{let g=a.reduce((d,p)=>d+p.getTotalSize(),0);if(g){let d=C=>C.getPieceSize(),p=a.reduce((C,v)=>C+v.getPieceCount(),0),m=s.number(p),I=d(a[0]);c=a.every(C=>d(C)===I)?`${s.size(g)} (${m} pieces @ ${s.mem(I)})`:`${s.size(g)} (${m} pieces)`}else c="None"}if(h(n.info.size,s.stringSanitizer(c)),a.length===0)c=e;else{let g=p=>p.getHashString(),d=g(a[0]);c=a.every(p=>g(p)===d)?d:t}if(h(n.info.hash,c),a.length===0)c=e;else{let g=p=>p.getPrivateFlag(),d=g(a[0]);a.every(p=>g(p)===d)?d?c="Private to this tracker -- DHT and PEX disabled":c="Public torrent":c=t}if(h(n.info.privacy,c),a.length===0)c=e;else{let g=p=>p.getComment(),d=g(a[0]);c=a.every(p=>g(p)===d)?d:t}if(c=c||e,c.startsWith("https://")||c.startsWith("http://")?(c=encodeURI(c),n.info.comment.innerHTML=`${c}`):h(n.info.comment,c),c=a.length===0?e:a[0].getLabels().join(", "),h(n.info.labels,c),a.length===0)c=e;else{let g=B=>B.getCreator(),d=g(a[0]),p=!a.every(B=>g(B)===d);g=B=>B.getDateCreated();let m=g(a[0]),I=!a.every(B=>g(B)===m),C=!d||d.length===0,v=!m;p||I?c=t:C&&v?c=r:v&&!C?c=`Created by ${d}`:C&&!v?c=`Created on ${new Date(m*1e3).toDateString()}`:c=`Created by ${d} on ${new Date(m*1e3).toDateString()}`}if(h(n.info.origin,c),a.length===0)c=e;else{let g=p=>p.getDownloadDir(),d=g(a[0]);c=a.every(p=>g(p)===d)?d:t}if(h(n.info.location,c),a.length===0)c=e;else{let g=p=>p.getDateAdded(),d=g(a[0]);c=a.every(p=>g(p)===d)?new Date(d*1e3).toLocaleString(navigator.language,{day:"2-digit",hour:"2-digit",hour12:!1,minute:"2-digit",month:"short",second:"2-digit",timeZoneName:"short",weekday:"short",year:"numeric"}):t}if(h(n.info.dateAdded,c),a.length===0)h(n.info.magnetLink,e);else if(a.length>1)h(n.info.magnetLink,t);else{let g=a[0].getMagnetLink();n.info.magnetLink.innerHTML=``}}static _peerStatusTitle(e){let t=Object.seal({"?":"We unchoked this peer, but they're not interested",D:"Downloading from this peer",E:"Encrypted Connection",H:"Peer was discovered through Distributed Hash Table (DHT)",I:"Peer is an incoming connection",K:"Peer has unchoked us, but we're not interested",O:"Optimistic unchoke",T:"Peer is connected via uTP",U:"Uploading to peer",X:"Peer was discovered through Peer Exchange (PEX)",d:"We would download from this peer if they'd let us",u:"We would upload to this peer if they'd ask"});return[...e].filter(r=>t[r]).map(r=>`${r}: ${t[r]}`).join(`
+`)}_updatePeers(){let e=y,{elements:t,torrents:r}=this,{tbody:s}=t.peers,i=[(a,l)=>{l.dataset.encrypted=a.isEncrypted},(a,l)=>h(l,a.rateToPeer?e.speedBps(a.rateToPeer):""),(a,l)=>h(l,a.rateToClient?e.speedBps(a.rateToClient):""),(a,l)=>h(l,`${Math.floor(a.progress*100)}%`),(a,l)=>{h(l,a.flagStr),l.setAttribute("title",o._peerStatusTitle(a.flagStr))},(a,l)=>{h(l,a.address),l.setAttribute("title",a.address)},(a,l)=>{h(l,a.clientName),l.setAttribute("title",a.clientName)}],n=[];for(let a of r){let l=document.createElement("tr");l.classList.add("torrent-row");let c=document.createElement("td");c.setAttribute("colspan",i.length),h(c,a.getName()),l.append(c),n.push(l);for(let u of a.getPeers()){let g=document.createElement("tr");g.classList.add("peer-row");for(let[d,p]of i.entries()){let m=document.createElement("td");m.classList.add(Yt[d]),p(u,m),g.append(m)}n.push(g)}for(;s.firstChild;)s.firstChild.remove();s.append(...n)}}static getAnnounceState(e){switch(e.announceState){case f._TrackerActive:return"Announce in progress";case f._TrackerWaiting:{let t=Math.max(0,e.nextAnnounceTime-Date.now()/1e3);return`Next announce in ${y.timeInterval(t)}`}case f._TrackerQueued:return"Announce is queued";case f._TrackerInactive:return e.isBackup?"Tracker will be used as a backup":"Announce not scheduled";default:return`unknown announce state: ${e.announceState}`}}static lastAnnounceStatus(e){let t="Last Announce",r=["N/A"];if(e.hasAnnounced){let s=y.timestamp(e.lastAnnounceTime);e.lastAnnounceSucceeded?r=[s," (got ",y.countString("peer","peers",e.lastAnnouncePeerCount),")"]:(t="Announce error",r=[e.lastAnnounceResult?`${e.lastAnnounceResult} - `:"",s])}return{label:t,value:r.join("")}}static lastScrapeStatus(e){let t="Last Scrape",r="N/A";if(e.hasScraped){let s=y.timestamp(e.lastScrapeTime);e.lastScrapeSucceeded?r=s:(t="Scrape error",r=(e.lastScrapeResult?`${e.lastScrapeResult} - `:"")+s)}return{label:t,value:r}}static _getOrigin(e){try{let t="udp://";if(e.announce.startsWith(t)){let s="http://",i=e.announce.replace(t,s);return new URL(i).origin.replace(s,t)}return new URL(e.announce).origin}catch{return[e.sitename||e.host||e.announce]}}_updateTiers(){let e="N/A",{list:t}=this.elements.tiers,{torrents:r}=this,s=[];for(let i of r){if(r.length>1){let n=document.createElement("div");n.classList.add("tier-list-torrent"),h(n,i.getName()),s.push(n)}for(let n of i.getTrackers()){let a=o.getAnnounceState(n),l=o.lastAnnounceStatus(n),c=o.lastScrapeStatus(n),u=document.createElement("div");u.classList.add("tier-list-row");let g=document.createElement("div"),d=o._getOrigin(n);g.classList.add("tier-list-tracker"),h(g,`${d} - tier ${n.tier+1}`),g.setAttribute("title",n.announce),u.append(g),g=document.createElement("div"),g.classList.add("tier-announce"),h(g,`${l.label}: ${l.value}`),u.append(g),g=document.createElement("div"),g.classList.add("tier-seeders"),h(g,`Seeders: ${n.seederCount>-1?n.seederCount:e}`),u.append(g),g=document.createElement("div"),g.classList.add("tier-state"),h(g,a),u.append(g),g=document.createElement("div"),g.classList.add("tier-leechers"),h(g,`Leechers: ${n.leecherCount>-1?n.leecherCount:e}`),u.append(g),g=document.createElement("div"),g.classList.add("tier-scrape"),h(g,`${c.label}: ${c.value}`),u.append(g),g=document.createElement("div"),g.classList.add("tier-downloads"),h(g,`Downloads: ${n.downloadCount>-1?n.downloadCount:e}`),u.append(g),s.push(u)}}for(;t.firstChild;)t.firstChild.remove();t.append(...s)}_changeFileCommand(e,t){let{controller:r,file_torrent:s}=this,i=s.getId();r.changeFileCommand(i,e,t)}_onFileWantedToggled(e){let{indices:t,wanted:r}=e;this._changeFileCommand(t,r?"files-wanted":"files-unwanted")}_onFilePriorityToggled(e){let{indices:t,priority:r}=e,s=null;switch(r.toString()){case"-1":s="priority-low";break;case"1":s="priority-high";break;default:s="priority-normal"}this._changeFileCommand(t,s)}_clearFileList(){let{list:e}=this.elements.files;for(;e.firstChild;)e.firstChild.remove();this.file_torrent=null,this.file_torrent_n=null,this.file_rows=null}static createFileTreeModel(e){let t=[],r={children:{},file_indices:[]};for(let[s,i]of e.getFiles().entries()){let{name:n}=i,a=n.split("/"),l=r;for(let[c,u]of a.entries()){let g=l.children[u];g||(l.children[u]=g={children:{},depth:c,file_indices:[],name:u,parent:l}),l=g}l.file_index=s,delete l.children,t.push(l)}for(let s of t){let{file_index:i}=s,n=s;do n.file_indices.push(i),n=n.parent;while(n)}return r}addNodeToView(e,t,r){let s=new Xe(e,r.depth,r.name,r.file_indices);s.addEventListener("wantedToggled",this._onFileWantedToggled.bind(this)),s.addEventListener("priorityToggled",this._onFilePriorityToggled.bind(this)),this.file_rows.push(s),t.append(s.getElement())}addSubtreeToView(e,t,r){if(r.parent&&this.addNodeToView(e,t,r),r.children)for(let s of Object.values(r.children))this.addSubtreeToView(e,t,s)}_updateFiles(){let{list:e}=this.elements.files,{file_rows:t,file_torrent:r,file_torrent_n:s,torrents:i}=this;if(i.length!==1){this._clearFileList();return}let[n]=i,a=n.getFiles().length;if(n!==r||a!==s){this._clearFileList(),this.file_torrent=n,this.file_torrent_n=a,this.file_rows=[];let l=document.createDocumentFragment(),c=o.createFileTreeModel(n);this.addSubtreeToView(n,l,c),e.append(l)}else for(let l of t)l.refresh()}};var Fe=class o extends EventTarget{constructor(e,t){super(),this.controller=e,this.remote=t,this.elements={},this.torrents=[],this.show()}show(){let e=this.controller.getSelectedTorrents();e.length!==0&&(this.torrents=e,this.elements=o._create(),this.elements.confirm.addEventListener("click",()=>this._onConfirm()),this.elements.dismiss.addEventListener("click",()=>this._onDismiss()),this.elements.entry.value=e[0].getDownloadDir(),document.body.append(this.elements.root),this.elements.entry.focus())}close(){this.elements.root.remove(),this.dispatchEvent(new Event("close")),delete this.controller,delete this.remote,delete this.elements,delete this.torrents}_onDismiss(){this.close()}_onConfirm(){let e=this.torrents.map(r=>r.getId()),t=this.elements.entry.value.trim();this.remote.moveTorrents(e,t),this.close()}static _create(){let e=W("move-dialog");e.root.setAttribute("aria-label","Move Torrent"),e.heading.textContent="Set Torrent Location",confirm.textContent="Apply";let t=document.createElement("label");t.setAttribute("for","torrent-path"),t.textContent="Location:",e.workarea.append(t);let r=document.createElement("input");return r.setAttribute("type","text"),r.id="torrent-path",e.entry=r,e.workarea.append(r),e}};var z=class o extends EventTarget{constructor(e){super(),this.elements=o._create(e),this.elements.dismiss.addEventListener("click",()=>this._onDismiss()),this.options=e,document.body.append(this.elements.root),this.elements.dismiss.focus()}close(){if(!this.closed){this.elements.root.remove(),this.dispatchEvent(new Event("close"));for(let e of Object.keys(this))delete this[e];this.closed=!0}}_onDismiss(){this.close()}static _create(e){let{heading:t,message:r}=e,s=W("confirm-dialog");return s.confirm.remove(),delete s.confirm,s.heading.textContent=t,s.workarea.textContent=r,s}};var $=class extends EventTarget{constructor(e,t,r="",s=null){super(),this.controller=e,this.remote=t,this.elements=this._create(r),this.elements.dismiss.addEventListener("click",()=>this._onDismiss()),this.elements.confirm.addEventListener("click",()=>this._onConfirm()),document.body.append(this.elements.root),s&&(this.elements.file_input.files=s),this._updateFreeSpaceInAddDialog(),this.elements.url_input.focus()}close(){if(!this.closed){clearInterval(this.interval),this.elements.root.remove(),this.dispatchEvent(new Event("close"));for(let e of Object.keys(this))delete this[e];this.closed=!0}}_onDismiss(){this.close()}_updateFreeSpaceInAddDialog(){let e=this.elements.folder_input.value;this.remote.getFreeSpace(e,(t,r)=>{this.closed||(this.elements.freespace.textContent=r>0?`${y.size(r)} Free`:"")})}_onConfirm(){let{controller:e,elements:t,remote:r}=this,{file_input:s,folder_input:i,start_input:n,url_input:a}=t,l=!n.checked,c=i.value.trim();for(let g of s.files){let d=new FileReader;d.addEventListener("load",p=>{let m=p.target.result,I="base64,",C=m.indexOf(I);if(C===-1)return;let v={arguments:{"download-dir":c,metainfo:m.slice(Math.max(0,C+I.length)),paused:l},method:"torrent-add"};r.sendRequest(v,B=>{B.result!=="success"&&(alert(`Error adding "${g.name}": ${B.result}`),e.setCurrentPopup(new z({heading:`Error adding "${g.name}"`,message:B.result})))})}),d.readAsDataURL(g)}let u=a.value.trim();if(u.length>0){/^[\da-f]{40}$/i.test(u)&&(u=`magnet:?xt=urn:btih:${u}`);let g={arguments:{"download-dir":c,filename:u,paused:l},method:"torrent-add"};r.sendRequest(g,d=>{d.result!=="success"&&e.setCurrentPopup(new z({heading:`Error adding "${u}"`,message:d.result}))})}this._onDismiss()}_create(e){let t=W(),{confirm:r,root:s,heading:i,workarea:n}=t;s.classList.add("open-torrent"),i.textContent="Add Torrents",r.textContent="Add";let a=F(),l=document.createElement("label");l.setAttribute("for",a),l.textContent="Please select torrent files to add:",n.append(l);let c=document.createElement("input");c.type="file",c.name="torrent-files[]",c.id=a,c.multiple=!0,n.append(c),t.file_input=c,a=F(),l=document.createElement("label"),l.setAttribute("for",a),l.textContent="Or enter a URL:",n.append(l),c=document.createElement("input"),c.type="url",c.id=a,c.value=e,n.append(c),t.url_input=c,a=F(),l=document.createElement("label"),l.id="add-dialog-folder-label",l.for=a,l.textContent="Destination folder: ",n.append(l);let u=document.createElement("span");u.id="free-space-text",l.append(u),n.append(l),t.freespace=u,c=document.createElement("input"),c.type="text",c.id="add-dialog-folder-input",c.addEventListener("change",()=>this._updateFreeSpaceInAddDialog()),c.value=this.controller.session_properties["download-dir"],n.append(c),t.folder_input=c;let g=document.createElement("div");n.append(g);let d=document.createElement("input");return d.type="checkbox",d.id="auto-start-check",d.checked=this.controller.shouldAddedTorrentsStart(),g.append(d),t.start_input=d,l=document.createElement("label"),l.id="auto-start-label",l.setAttribute("for",d.id),l.textContent="Start when added",g.append(l),t}};var X={_DaemonVersion:"version",_DownSpeedLimit:"speed-limit-down",_DownSpeedLimited:"speed-limit-down-enabled",_QueueMoveBottom:"queue-move-bottom",_QueueMoveDown:"queue-move-down",_QueueMoveTop:"queue-move-top",_QueueMoveUp:"queue-move-up",_Root:"../rpc",_TurtleDownSpeedLimit:"alt-speed-down",_TurtleState:"alt-speed-enabled",_TurtleUpSpeedLimit:"alt-speed-up",_UpSpeedLimit:"speed-limit-up",_UpSpeedLimited:"speed-limit-up-enabled"},ne=class o{constructor(e){this._connection_alert=null,this._controller=e,this._session_id=""}sendRequest(e,t,r){let s=new Headers;s.append("cache-control","no-cache"),s.append("content-type","application/json"),s.append("pragma","no-cache"),this._session_id&&s.append(o._SessionHeader,this._session_id);let i=null;fetch(X._Root,{body:JSON.stringify(e),headers:s,method:"POST"}).then(n=>{if(i=n,n.status===409){let a=new Error(o._SessionHeader);throw a.header=n.headers.get(o._SessionHeader),a}return n.json()}).then(n=>{t&&t.call(r,n,i),this._connection_alert&&(this._connection_alert.close(),this._connection_alert=null)}).catch(n=>{if(n.message===o._SessionHeader){this._session_id=n.header,this.sendRequest(e,t,r);return}console.trace(n),this._controller.togglePeriodicSessionRefresh(!1),this._connection_alert=new z({heading:"Connection failed",message:"Could not connect to the server. You may need to reload the page to reconnect."}),this._controller.setCurrentPopup(this._connection_alert)})}loadDaemonPrefs(e,t){let r={method:"session-get"};this.sendRequest(r,e,t)}checkPort(e,t,r){let s={arguments:{ipProtocol:e},method:"port-test"};this.sendRequest(s,t,r)}renameTorrent(e,t,r,s,i){let n={arguments:{ids:e,name:r,path:t},method:"torrent-rename-path"};this.sendRequest(n,s,i)}setLabels(e,t,r){let s={ids:e,labels:t};this.sendRequest({arguments:s,method:"torrent-set"},r)}loadDaemonStats(e,t){let r={method:"session-stats"};this.sendRequest(r,e,t)}updateTorrents(e,t,r,s){let i={arguments:{fields:t,format:"table"},method:"torrent-get"};e&&(i.arguments.ids=e),this.sendRequest(i,n=>{let a=n.arguments;r.call(s,a.torrents,a.removed)})}getFreeSpace(e,t,r){let s={arguments:{path:e},method:"free-space"};this.sendRequest(s,i=>{let n=i.arguments;t.call(r,n.path,n["size-bytes"])})}changeFileCommand(e,t,r){let s={ids:[e]};s[r]=t,this.sendRequest({arguments:s,method:"torrent-set"},()=>{this._controller.refreshTorrents([e])})}sendTorrentSetRequests(e,t,r,s,i){r||(r={}),r.ids=t;let n={arguments:r,method:e};this.sendRequest(n,s,i)}sendTorrentActionRequests(e,t,r,s){this.sendTorrentSetRequests(e,t,null,r,s)}startTorrents(e,t,r,s){let i=t?"torrent-start-now":"torrent-start";this.sendTorrentActionRequests(i,e,r,s)}stopTorrents(e,t,r){this.sendTorrentActionRequests("torrent-stop",e,t,r)}moveTorrents(e,t,r,s){this.sendTorrentSetRequests("torrent-set-location",e,{location:t,move:!0},r,s)}removeTorrents(e,t){let r={arguments:{"delete-local-data":t,ids:[]},method:"torrent-remove"};if(e)for(let s=0,i=e.length;s{this._controller.refreshTorrents()})}verifyTorrents(e,t,r){this.sendTorrentActionRequests("torrent-verify",e,t,r)}reannounceTorrents(e,t,r){this.sendTorrentActionRequests("torrent-reannounce",e,t,r)}addTorrentByUrl(e,t){/^[\da-f]{40}$/i.test(e)&&(e=`magnet:?xt=urn:btih:${e}`);let r={arguments:{filename:e,paused:t.paused},method:"torrent-add"};this.sendRequest(r,()=>{this._controller.refreshTorrents()})}savePrefs(e){let t={arguments:e,method:"session-set"};this.sendRequest(t,()=>{this._controller.loadDaemonPrefs()})}updateBlocklist(){let e={method:"blocklist-update"};this.sendRequest(e,()=>{this._controller.loadDaemonPrefs()})}moveTorrentsToTop(e,t,r){this.sendTorrentActionRequests(X._QueueMoveTop,e,t,r)}moveTorrentsToBottom(e,t,r){this.sendTorrentActionRequests(X._QueueMoveBottom,e,t,r)}moveTorrentsUp(e,t,r){this.sendTorrentActionRequests(X._QueueMoveUp,e,t,r)}moveTorrentsDown(e,t,r){this.sendTorrentActionRequests(X._QueueMoveDown,e,t,r)}};ne._SessionHeader="X-Transmission-Session-Id";function We(o,e){let t=document.createElement("fieldset");t.classList.add("section",o);let r=document.createElement("legend");return r.classList.add("title"),r.textContent=e,t.append(r),t}function Nt(o,e,t,r){let s=document.createElement("button");return s.textContent=e,s.addEventListener("click",r),o.append(s),s.dataset.action=t,s}var ae=class extends EventTarget{constructor(e,t,r,s){super(),this.action_listener=this._onActionChange.bind(this),this.action_manager=s,this.action_manager.addEventListener("change",this.action_listener),this.prefs_listener=this._onPrefsChange.bind(this),this.prefs=t,this.prefs.addEventListener("change",this.prefs_listener),this.closed=!1,this.remote=r,this.name="overflow-menu",this.session_listener=this._onSessionChange.bind(this),this.session_manager=e,this.session_manager.addEventListener("session-change",this.session_listener);let{session_properties:i}=e;Object.assign(this,this._create(i)),this.outside=new P(this.root),this.outside.addEventListener("click",()=>this.close()),Object.seal(this),this.show()}show(){document.body.append(this.root)}close(){if(!this.closed){this.outside.stop(),this.session_manager.removeEventListener("session-change",this.session_listener),this.action_manager.removeEventListener("change",this.action_listener),this.prefs.removeEventListener("change",this.prefs_listener),this.root.remove(),this.dispatchEvent(new Event("close"));for(let e of Object.keys(this))this[e]=null;this.closed=!0}}_onSessionChange(e){let{alt_speed_check:t}=this.elements,{session_properties:r}=e;t.checked=r[X._TurtleState]}_onPrefsChange(e){switch(e.key){case b.SortDirection:case b.SortMode:this.root.querySelector(`[data-pref="${e.key}"]`).value=e.value;break;default:break}}_onActionChange(e){let t=this.actions[e.action];t&&this._updateElement(t)}_updateElement(e){if(e.dataset.action){let{action:t}=e.dataset,r=this.action_manager.keyshortcuts(t);r&&e.setAttribute("aria-keyshortcuts",r),Q(e,this.action_manager.isEnabled(t))}}_onClick(e){let{action:t,pref:r}=e.target.dataset;if(t){this.action_manager.click(t);return}if(r){this.prefs[r]=e.target.value;return}console.log("unhandled"),console.log(e),console.trace()}_create(e){let t={},r={},s=this._onClick.bind(this),i=document.createElement("div");i.classList.add("overflow-menu","popup");let n=We("display","Display");i.append(n);let a=document.createElement("div");a.id="display-options",n.append(a);let l=document.createElement("div");l.classList.add("table-row"),a.append(l);let c=document.createElement("label");c.id="display-sort-mode-label",c.textContent="Sort by",l.append(c);let u=document.createElement("select");u.id="display-sort-mode-select",u.dataset.pref=b.SortMode,l.append(u);let g=[[b.SortByActivity,"Activity"],[b.SortByAge,"Age"],[b.SortByName,"Name"],[b.SortByProgress,"Progress"],[b.SortByQueue,"Queue order"],[b.SortByRatio,"Ratio"],[b.SortBySize,"Size"],[b.SortByState,"State"]];for(let[A,G]of g){let U=document.createElement("option");U.value=A,U.textContent=G,u.append(U)}c.setAttribute("for",u.id),u.value=this.prefs.sort_mode,u.addEventListener("change",A=>{this.prefs.sort_mode=A.target.value}),l=document.createElement("div"),l.classList.add("table-row"),a.append(l);let d=document.createElement("input");d.id="display-sort-reverse-check",d.dataset.pref=b.SortDirection,d.type="checkbox",l.append(d),c=document.createElement("label"),c.id="display-sort-reverse-label",c.setAttribute("for",d.id),c.textContent="Reverse sort",l.append(c),d.checked=this.prefs.sort_direction!==b.SortAscending,d.addEventListener("input",A=>{this.prefs.sort_direction=A.target.checked?b.SortDescending:b.SortAscending}),l=document.createElement("div"),l.classList.add("table-row"),a.append(l);let p="toggle-compact-rows";d=document.createElement("input"),d.id="display-compact-check",d.dataset.action=p,d.type="checkbox",l.append(d),c=document.createElement("label"),c.id="display-compact-label",c.for=d.id,c.setAttribute("for",d.id),c.textContent=this.action_manager.text(p),d.checked=this.prefs.display_mode===b.DisplayCompact,l.append(c),d.addEventListener("input",A=>{let{checked:G}=A.target;this.prefs.display_mode=G?b.DisplayCompact:b.DisplayFull}),l=document.createElement("div"),l.classList.add("table-row"),a.append(l),p="toggle-contrast",d=document.createElement("input"),d.id="contrast-more-check",d.dataset.action=p,d.type="checkbox",d.classList.add("switch"),c=document.createElement("label"),c.id="contrast-more-label",c.for=d.id,c.setAttribute("for",d.id),c.textContent=this.action_manager.text(p),d.checked=this.prefs.contrast_mode===b.ContrastMore,l.append(d),l.append(c),d.addEventListener("input",A=>{let{checked:G}=A.target;this.prefs.contrast_mode=G?b.ContrastMore:b.ContrastLess}),l=document.createElement("div"),l.classList.add("table-row","display-fullscreen-row"),a.append(l),d=document.createElement("input"),d.id="display-fullscreen-check",d.type="checkbox";let m=()=>document.fullscreenElement!==null;d.checked=m(),d.addEventListener("input",()=>{m()?document.exitFullscreen():document.body.requestFullscreen()}),document.addEventListener("fullscreenchange",()=>{d.checked=m()}),l.append(d),c=document.createElement("label"),c.id="display-fullscreen-label",c.for=d.id,c.setAttribute("for",d.id),c.textContent="Fullscreen",l.append(c),n=We("speed","Speed Limit"),i.append(n),a=document.createElement("div"),a.id="speed-options",n.append(a),l=document.createElement("div"),l.classList.add("speed-up"),a.append(l),c=document.createElement("label"),c.id="speed-up-label",c.textContent="Upload:",l.append(c);let I="Unlimited";u=document.createElement("select"),u.id="speed-up-select",l.append(u);let C=["50","100","250","500","1000","2500","5000","10000",I];for(let A of[...new Set(C).add(`${e[X._UpSpeedLimit]}`).values()].sort((G,U)=>G-U)){let G=document.createElement("option");G.value=A,G.textContent=A===I?I:y.speed(A),u.append(G)}c.setAttribute("for",u.id),u.value=e[X._UpSpeedLimited]?`${e[X._UpSpeedLimit]}`:I,u.addEventListener("change",A=>{let{value:G}=A.target;console.log(A),G===I?this.remote.savePrefs({[X._UpSpeedLimited]:!1}):this.remote.savePrefs({[X._UpSpeedLimited]:!0,[X._UpSpeedLimit]:Number.parseInt(G,10)})}),l=document.createElement("div"),l.classList.add("speed-down"),a.append(l),c=document.createElement("label"),c.id="speed-down-label",c.textContent="Download:",l.append(c),u=document.createElement("select"),u.id="speed-down-select",l.append(u);for(let A of[...new Set(C).add(`${e[X._DownSpeedLimit]}`).values()].sort((G,U)=>G-U)){let G=document.createElement("option");G.value=A,G.textContent=A===I?I:y.speed(A),u.append(G)}c.setAttribute("for",u.id),u.value=e[X._DownSpeedLimited]?`${e[X._DownSpeedLimit]}`:I,u.addEventListener("change",A=>{let{value:G}=A.target;console.log(A),G===I?this.remote.savePrefs({[X._DownSpeedLimited]:!1}):this.remote.savePrefs({[X._DownSpeedLimited]:!0,[X._DownSpeedLimit]:Number.parseInt(G,10)})}),l=document.createElement("div"),l.classList.add("alt-speed"),a.append(l),d=document.createElement("input"),d.id="alt-speed-check",d.type="checkbox",d.checked=e[X._TurtleState],d.addEventListener("change",A=>{this.remote.savePrefs({[X._TurtleState]:A.target.checked})}),l.append(d),r.alt_speed_check=d,c=document.createElement("label"),c.id="alt-speed-image",c.setAttribute("for",d.id),l.append(c),c=document.createElement("label"),c.id="alt-speed-label",c.setAttribute("for",d.id),c.textContent="Use Temp limits",l.append(c),c=document.createElement("label"),c.id="alt-speed-values-label",c.setAttribute("for",d.id);let v=y.speed(e[X._TurtleUpSpeedLimit]),B=y.speed(e[X._TurtleDownSpeedLimit]);c.textContent=`(${v} up, ${B} down)`,l.append(c),n=We("actions","Actions"),i.append(n);for(let A of["show-preferences-dialog","show-shortcuts-dialog","pause-all-torrents","start-all-torrents"]){let G=this.action_manager.text(A);t[A]=Nt(n,G,A,s)}n=We("help","Help"),i.append(n),a=document.createElement("div"),n.append(a);for(let A of["show-statistics-dialog","show-about-dialog"]){let G=this.action_manager.text(A);t[A]=Nt(a,G,A,s)}let x=document.createElement("a");return x.href="https://transmissionbt.com/donate.html",x.target="_blank",x.textContent="Donate",a.append(x),this._updateElement=this._updateElement.bind(this),{actions:t,elements:r,root:i}}};var Le=class o extends EventTarget{static _initTimeDropDown(e){for(let t=0;t<24*4;++t){let r=t/4,s=t%4*15,i=t*15,n=`${r}:${s||"00"}`;e.options[t]=new Option(n,i)}}static _initDayDropDown(e){let t=[["Everyday","127"],["Weekdays","62"],["Weekends","65"],["Sunday","1"],["Monday","2"],["Tuesday","4"],["Wednesday","8"],["Thursday","16"],["Friday","32"],["Saturday","64"]];for(let r=0;t[r];++r){let[s,i]=t[r];e.options[r]=new Option(s,i)}}_checkPort(){for(let[e,t]of Object.entries(this.elements.network.port_status_label))delete t.dataset.open,h(t,"Checking..."),this.remote.checkPort(e,r=>this._onPortChecked(e,r),this)}_onPortChecked(e,t){if(this.closed)return;let r=this.elements.network.port_status_label[e],s=t.arguments["port-is-open"]||!1;r.dataset.open=s,"port-is-open"in t.arguments?h(r,s?"Open":"Closed"):h(r,"Error")}_setBlocklistButtonEnabled(e){let t=this.elements.peers.blocklist_update_button;Q(t,e),t.value=e?"Update":"Updating..."}static _getValue(e){if(e.tagName==="TEXTAREA")return e.value;switch(e.type){case"checkbox":case"radio":return e.checked;case"number":case"select-one":case"text":case"url":{let t=e.value;return Number.parseInt(t,10).toString()===t?Number.parseInt(t,10):Number.parseFloat(t).toString()===t?Number.parseFloat(t):t}default:return null}}_onMaybePortChanged(e){(e==="peer-port"||e==="port-forwarding-enabled")&&this._checkPort()}_onControlChanged(e){let{key:t}=e.target.dataset;this.remote.savePrefs({[t]:o._getValue(e.target)}),this._onMaybePortChanged(t)}_onDialogClosed(){this.dispatchEvent(new Event("closed"))}_update(){this._setBlocklistButtonEnabled(!0);for(let[e,t]of Object.entries(this.session_manager.session_properties))for(let r of this.elements.root.querySelectorAll(`[data-key="${e}"]`))if(e==="blocklist-size"){let s=y.number(t);r.innerHTML=`Blocklist has ${s} rules`,h(this.elements.peers.blocklist_update_button,"Update")}else switch(r.type){case"checkbox":case"radio":r.checked=t;break;case"text":case"textarea":case"url":case"email":case"number":case"search":r!==document.activeElement&&(r.value!=t&&this._onMaybePortChanged(e),r.value=t);break;case"select-one":r.value=t;break;default:console.log(r.type);break}}shouldAddedTorrentsStart(){return this.data.elements.root.find("#start-added-torrents")[0].checked}static _createCheckAndLabel(e,t){let r=document.createElement("div");r.id=e;let s=document.createElement("input");s.id=F(),s.type="checkbox",r.append(s);let i=document.createElement("label");return i.textContent=t,i.setAttribute("for",s.id),r.append(i),{check:s,label:i,root:r}}static _enableIfChecked(e,t){let r=()=>{e.tagName==="INPUT"?Q(e,t.checked):e.classList.toggle("disabled",!t.checked)};t.addEventListener("change",r),r()}static _getProtocolHandlerRegistered(){return localStorage.getItem("protocol-handler-registered")==="true"}static _updateProtocolHandlerButton(e){e.removeAttribute("disabled"),e.removeAttribute("title"),o._getProtocolHandlerRegistered()?(e.textContent="Remove Browser Handler","unregisterProtocolHandler"in navigator||e.setAttribute("title","Your browser does not support removing protocol handlers. This button only allows you to re-register a handler.")):(e.textContent="Add Browser Handler",e.removeAttribute("title"),"registerProtocolHandler"in navigator||(e.setAttribute("disabled",!0),e.setAttribute("title","Your browser does not support protocol handlers")))}static _toggleProtocolHandler(e){let t=new URL(window.location.href);t.search="addtorrent=%s",this._getProtocolHandlerRegistered()?(navigator.unregisterProtocolHandler?.("magnet",t.toString()),localStorage.removeItem("protocol-handler-registered"),o._updateProtocolHandlerButton(e)):(navigator.registerProtocolHandler("magnet",t.toString(),"Transmission Web"),localStorage.setItem("protocol-handler-registered","true"),o._updateProtocolHandlerButton(e))}static _createTorrentsPage(){let e=document.createElement("div");e.classList.add("prefs-torrents-page");let t=document.createElement("div");t.textContent="Downloading",t.classList.add("section-label"),e.append(t),t=document.createElement("label"),t.textContent="Download to:",e.append(t);let r=document.createElement("input");r.type="text",r.id=F(),r.dataset.key="download-dir",t.setAttribute("for",r.id),e.append(r);let s=r,i=o._createCheckAndLabel("incomplete-dir-div","Use temporary folder:");i.check.title="Separate folder to temporarily store downloads until they are complete.",i.check.dataset.key="incomplete-dir-enabled",i.label.title=i.check.title,e.append(i.root);let n=i.check;r=document.createElement("input"),r.type="text",r.dataset.key="incomplete-dir",e.append(r),o._enableIfChecked(r,i.check);let a=r;i=o._createCheckAndLabel("autostart-div","Start when added"),i.check.dataset.key="start-added-torrents",e.append(i.root);let l=i.check;i=o._createCheckAndLabel("suffix-div",`Append "part" to incomplete files' names`),i.check.dataset.key="rename-partial-files",e.append(i.root);let c=i.check;i=o._createCheckAndLabel("download-queue-div","Download queue size:"),i.check.dataset.key="download-queue-enabled",e.append(i.root);let u=i.check;r=document.createElement("input"),r.type="number",r.dataset.key="download-queue-size",e.append(r),o._enableIfChecked(r,i.check);let g=r;t=document.createElement("div"),t.textContent="Seeding",t.classList.add("section-label"),e.append(t),i=o._createCheckAndLabel("stop-ratio-div","Stop seeding at ratio:"),i.check.dataset.key="seedRatioLimited",e.append(i.root);let d=i.check;r=document.createElement("input"),r.type="number",r.min="0.1",r.step="any",r.dataset.key="seedRatioLimit",e.append(r),o._enableIfChecked(r,i.check);let p=r;i=o._createCheckAndLabel("stop-idle-div","Stop seeding if idle for N mins:"),i.check.dataset.key="idle-seeding-limit-enabled",e.append(i.root);let m=i.check;r=document.createElement("input"),r.type="number",r.min="0.1",r.step="any",r.dataset.key="idle-seeding-limit",e.append(r),o._enableIfChecked(r,i.check);let I=r;t=document.createElement("div"),t.textContent="Magnet Protocol Handler",t.classList.add("section-label"),e.append(t);let C=document.createElement("button");return C.classList.add("register-handler-button"),o._updateProtocolHandlerButton(C),e.append(C),{autostart_check:l,download_dir:s,download_queue_check:u,download_queue_input:g,incomplete_dir_check:n,incomplete_dir_input:a,register_handler_button:C,root:e,stop_idle_check:m,stop_idle_input:I,stop_ratio_check:d,stop_ratio_input:p,suffix_check:c}}static _createSpeedPage(){let e=document.createElement("div");e.classList.add("prefs-speed-page");let t=document.createElement("div");t.textContent="Speed Limits",t.classList.add("section-label"),e.append(t);let r=o._createCheckAndLabel("upload-speed-div","Upload (kB/s):");r.check.dataset.key="speed-limit-up-enabled",e.append(r.root);let s=r.check,i=document.createElement("input");i.type="number",i.dataset.key="speed-limit-up",e.append(i),o._enableIfChecked(i,r.check);let n=i;r=o._createCheckAndLabel("download-speed-div","Download (kB/s):"),r.check.dataset.key="speed-limit-down-enabled",e.append(r.root);let a=r.check;i=document.createElement("input"),i.type="number",i.dataset.key="speed-limit-down",e.append(i),o._enableIfChecked(i,r.check);let l=i;t=document.createElement("div"),t.textContent="Alternative Speed Limits",t.classList.add("section-label","alt-speed-section-label"),e.append(t),t=document.createElement("div"),t.textContent="Override normal speed limits manually or at scheduled times",t.classList.add("alt-speed-label"),e.append(t),t=document.createElement("label"),t.textContent="Upload (kB/s):",e.append(t),i=document.createElement("input"),i.type="number",i.dataset.key="alt-speed-up",i.id=F(),t.setAttribute("for",i.id),e.append(i);let c=i;t=document.createElement("label"),t.textContent="Download (kB/s):",e.append(t),i=document.createElement("input"),i.type="number",i.dataset.key="alt-speed-down",i.id=F(),t.setAttribute("for",i.id),e.append(i);let u=i;r=o._createCheckAndLabel("alt-times-div","Scheduled times"),r.check.dataset.key="alt-speed-time-enabled",e.append(r.root);let g=r.check;t=document.createElement("label"),t.textContent="From:",o._enableIfChecked(t,r.check),e.append(t);let d=document.createElement("select");d.id=F(),d.dataset.key="alt-speed-time-begin",o._initTimeDropDown(d),t.setAttribute("for",d.id),e.append(d),o._enableIfChecked(d,r.check);let p=d;t=document.createElement("label"),t.textContent="To:",o._enableIfChecked(t,r.check),e.append(t),d=document.createElement("select"),d.id=F(),d.dataset.key="alt-speed-time-end",o._initTimeDropDown(d),t.setAttribute("for",d.id),e.append(d),o._enableIfChecked(d,r.check);let m=d;return t=document.createElement("label"),t.textContent="On days:",o._enableIfChecked(t,r.check),e.append(t),d=document.createElement("select"),d.id=F(),d.dataset.key="alt-speed-time-day",o._initDayDropDown(d),t.setAttribute("for",d.id),e.append(d),o._enableIfChecked(d,r.check),{alt_days_select:d,alt_download_speed_input:u,alt_from_select:p,alt_times_check:g,alt_to_select:m,alt_upload_speed_input:c,download_speed_check:a,download_speed_input:l,root:e,upload_speed_check:s,upload_speed_input:n}}static _createPeersPage(){let e=document.createElement("div");e.classList.add("prefs-peers-page");let t=document.createElement("div");t.textContent="Connections",t.classList.add("section-label"),e.append(t),t=document.createElement("label"),t.textContent="Max peers per torrent:",e.append(t);let r=document.createElement("input");r.type="number",r.dataset.key="peer-limit-per-torrent",r.id=F(),t.setAttribute("for",r.id),e.append(r);let s=r;t=document.createElement("label"),t.textContent="Max peers overall:",e.append(t),r=document.createElement("input"),r.type="number",r.dataset.key="peer-limit-global",r.id=F(),t.setAttribute("for",r.id),e.append(r);let i=r;t=document.createElement("div"),t.textContent="Options",t.classList.add("section-label"),e.append(t),t=document.createElement("label"),t.textContent="Encryption mode:",e.append(t);let n=document.createElement("select");n.id=F(),n.dataset.key="encryption",n.options[0]=new Option("Prefer encryption","preferred"),n.options[1]=new Option("Allow encryption","tolerated"),n.options[2]=new Option("Require encryption","required"),e.append(n);let a=n,l=o._createCheckAndLabel("use-pex-div","Use PEX to find more peers");l.check.title="PEX is a tool for exchanging peer lists with the peers you're connected to.",l.check.dataset.key="pex-enabled",l.label.title=l.check.title,e.append(l.root);let c=l.check;l=o._createCheckAndLabel("use-dht-div","Use DHT to find more peers"),l.check.title="DHT is a tool for finding peers without a tracker.",l.check.dataset.key="dht-enabled",l.label.title=l.check.title,e.append(l.root);let u=l.check;l=o._createCheckAndLabel("use-lpd-div","Use LPD to find more peers"),l.check.title="LPD is a tool for finding peers on your local network.",l.check.dataset.key="lpd-enabled",l.label.title=l.check.title,e.append(l.root);let g=l.check;t=document.createElement("div"),t.textContent="Blocklist",t.classList.add("section-label"),e.append(t),l=o._createCheckAndLabel("blocklist-enabled-div","Enable blocklist:"),l.check.dataset.key="blocklist-enabled",e.append(l.root);let d=l.check;r=document.createElement("input"),r.type="url",r.value="http://www.example.com/blocklist",r.dataset.key="blocklist-url",e.append(r),o._enableIfChecked(r,l.check);let p=r;t=document.createElement("label"),t.textContent="Blocklist has {n} rules",t.dataset.key="blocklist-size",t.classList.add("blocklist-size-label"),o._enableIfChecked(t,l.check),e.append(t);let m=document.createElement("button");return m.classList.add("blocklist-update-button"),m.textContent="Update",e.append(m),o._enableIfChecked(m,l.check),{blocklist_enabled_check:d,blocklist_update_button:m,blocklist_url_input:p,dht_check:u,encryption_select:a,lpd_check:g,max_peers_overall_input:i,max_peers_per_torrent_input:s,pex_check:c,root:e}}static _createNetworkPage(){let e=document.createElement("div");e.classList.add("prefs-network-page");let t=document.createElement("div");t.textContent="Listening Port",t.classList.add("section-label"),e.append(t),t=document.createElement("label"),t.textContent="Peer listening port:",e.append(t);let r=document.createElement("input");r.type="number",r.dataset.key="peer-port",r.id=F(),t.setAttribute("for",r.id),e.append(r);let s=r,i=document.createElement("div");i.classList.add("port-status"),t=document.createElement("label"),t.textContent="IPv4 port is",i.append(t);let n=document.createElement("label");n.textContent="?",n.classList.add("port-status-label"),i.append(n),i.append(document.createElement("br")),t=document.createElement("label"),t.textContent="IPv6 port is",i.append(t);let a=document.createElement("label");a.textContent="?",a.classList.add("port-status-label"),i.append(a),e.append(i);let l=o._createCheckAndLabel("randomize-port","Randomize port on launch");l.check.dataset.key="peer-port-random-on-start",e.append(l.root);let c=l.check;l=o._createCheckAndLabel("port-forwarding","Use port forwarding from my router"),l.check.dataset.key="port-forwarding-enabled",e.append(l.root);let u=l.check;t=document.createElement("div"),t.textContent="Options",t.classList.add("section-label"),e.append(t),l=o._createCheckAndLabel("utp-enabled","Enable uTP for peer communication"),l.check.dataset.key="utp-enabled",e.append(l.root);let g=l.check;t=document.createElement("div"),t.textContent="Default Public Trackers",t.classList.add("section-label"),e.append(t);let d=["Trackers to use on all public torrents.","To add a backup URL, add it on the next line after a primary URL.","To add a new primary URL, add it after a blank line."];for(let I of d)t=document.createElement("label"),t.classList.add("default-trackers-label"),t.textContent=I,t.setAttribute("for","default-trackers"),e.append(t);let p=document.createElement("textarea");return p.dataset.key="default-trackers",p.id="default-trackers",e.append(p),{default_trackers_textarea:p,port_forwarding_check:u,port_input:s,port_status_label:{ipv4:n,ipv6:a},random_port_check:c,root:e,utp_check:g}}static _create(){let e={network:o._createNetworkPage(),peers:o._createPeersPage(),speed:o._createSpeedPage(),torrents:o._createTorrentsPage()};return{...ye("prefs-dialog",[["prefs-tab-torrent",e.torrents.root,"Torrents"],["prefs-tab-speed",e.speed.root,"Speed"],["prefs-tab-peers",e.peers.root,"Peers"],["prefs-tab-network",e.network.root,"Network"]]),...e}}constructor(e,t){super(),this.closed=!1,this.session_manager=e,this.remote=t,this.update_from_session=()=>this._update(),this.elements=o._create(),this.elements.peers.blocklist_update_button.addEventListener("click",i=>{h(i.target,"Updating blocklist..."),this.remote.updateBlocklist(),this._setBlocklistButtonEnabled(!1)}),this.elements.torrents.register_handler_button.addEventListener("click",i=>{o._toggleProtocolHandler(i.currentTarget)}),this.elements.dismiss.addEventListener("click",()=>this.close()),this.outside=new P(this.elements.root),this.outside.addEventListener("click",()=>this.close()),Object.seal(this);let r=this._onControlChanged.bind(this),s=i=>{for(let n of Object.values(i))if(n.tagName==="INPUT")switch(n.type){case"checkbox":case"radio":case"number":case"text":case"url":n.addEventListener("change",r);break;default:console.trace(`unhandled input: ${n.type}`);break}else(n.tagName==="TEXTAREA"||n.tagName==="SELECT")&&n.addEventListener("change",r)};s(this.elements.network),s(this.elements.peers),s(this.elements.speed),s(this.elements.torrents),this.session_manager.addEventListener("session-change",this.update_from_session),this.update_from_session(),document.body.append(this.elements.root)}close(){if(!this.closed){this.outside.stop(),this.session_manager.removeEventListener("session-change",this.update_from_session),this.elements.root.remove(),dispatchEvent(new Event("close"));for(let e of Object.keys(this))this[e]=null;this.closed=!0}}};var we=class o extends EventTarget{constructor(e){super(),this.options=e,this.elements=o._create(e),this.elements.dismiss.addEventListener("click",()=>this._onDismiss()),this.elements.confirm.addEventListener("click",()=>this._onConfirm()),document.body.append(this.elements.root),this.elements.dismiss.focus()}close(){if(!this.closed){this.elements.root.remove(),this.dispatchEvent(new Event("close"));for(let e of Object.keys(this))delete this[e];this.closed=!0}}_onDismiss(){this.close()}_onConfirm(){let{remote:e,torrents:t,trash:r}=this.options;t.length>0&&e.removeTorrents(t,r),this.close()}static _create(e){let{trash:t}=e,{heading:r,message:s}=o._createMessage(e),i=W("remove-dialog");return i.heading.textContent=r,i.message.textContent=s,i.confirm.textContent=t?"Trash":"Remove",i}static _createMessage(e){let t=null,r=null,{torrents:s,trash:i}=e,[n]=s;return i&&s.length===1?(t=`Remove ${n.getName()} and delete data?`,r="All data downloaded for this torrent will be deleted. Are you sure you want to remove it?"):i?(t=`Remove ${s.length} transfers and delete data?`,r="All data downloaded for these torrents will be deleted. Are you sure you want to remove them?"):s.length===1?(t=`Remove ${n.getName()}?`,r="Once removed, continuing the transfer will require the torrent file. Are you sure you want to remove it?"):(t=`Remove ${s.length} transfers?`,r="Once removed, continuing the transfers will require the torrent files. Are you sure you want to remove them?"),{heading:t,message:r}}};var Ue=class o extends EventTarget{constructor(e,t){super(),this.controller=e,this.remote=t,this.elements={},this.torrents=[],this.show()}show(){let e=this.controller.getSelectedTorrents();if(e.length!==1){console.trace();return}this.torrents=e,this.elements=o._create(),this.elements.dismiss.addEventListener("click",()=>this._onDismiss()),this.elements.confirm.addEventListener("click",()=>this._onConfirm()),this.elements.entry.value=e[0].getName(),document.body.append(this.elements.root),this.elements.entry.focus()}close(){this.elements.root.remove(),this.dispatchEvent(new Event("close")),delete this.controller,delete this.remote,delete this.elements,delete this.torrents}_onDismiss(){this.close()}_onConfirm(){let[e]=this.torrents,t=e.getName(),r=this.elements.entry.value;this.remote.renameTorrent([e.getId()],t,r,s=>{s.result==="success"&&e.refresh(s.arguments)}),this.close()}static _create(){let e=W("rename-dialog");e.root.setAttribute("aria-label","Rename Torrent"),e.heading.textContent="Enter new name:",e.confirm.textContent="Rename";let t=document.createElement("label");t.setAttribute("for","torrent-rename-name"),t.textContent="Enter new name:",e.workarea.append(t);let r=document.createElement("input");return r.setAttribute("type","text"),r.id="torrent-rename-name",e.entry=r,e.workarea.append(r),e}};var Qe=class o extends EventTarget{constructor(e,t){super(),this.controller=e,this.remote=t,this.elements={},this.torrents=[],this.show()}show(){let e=this.controller.getSelectedTorrents();if(e.length===0){console.error("At least one selected torrent expected.");return}let[t]=e;this.torrents=e,this.elements=o._create(),this.elements.dismiss.addEventListener("click",()=>this._onDismiss()),this.elements.confirm.addEventListener("click",()=>this._onConfirm()),this.elements.entry.value=t.getLabels().join(", "),document.body.append(this.elements.root),this.elements.entry.focus()}close(){this.elements.root.remove(),this.dispatchEvent(new Event("close")),delete this.elements,delete this.torrents}_onDismiss(){this.close()}_onConfirm(){let{torrents:e}=this,{remote:t}=this,r=e.map(l=>l.getId()),{elements:s}=this,{entry:i}=s,{value:n}=i,a=n.split(/ *, */).filter(l=>l.length>0);t.setLabels(r,a,l=>{if(l.result==="success")for(let c of e)c.refresh({labels:a})}),this.close()}static _create(){let e=W("labels-dialog");e.root.setAttribute("aria-label","Edit Labels"),e.heading.textContent="Edit Labels:",e.confirm.textContent="Save";let t=document.createElement("label");t.setAttribute("for","torrent-labels"),t.textContent="Labels:",e.workarea.append(t);let r=document.createElement("input");return r.setAttribute("type","text"),r.id="torrent-labels",e.entry=r,e.workarea.append(r),e}};var ke=class o extends EventTarget{constructor(e){super(),this.elements=o._create(e),this.elements.dismiss.addEventListener("click",()=>this._onDismiss()),document.body.append(this.elements.root),this.elements.dismiss.focus()}close(){this.elements.root.remove(),this.dispatchEvent(new Event("close")),delete this.elements}_onDismiss(){this.close()}static _create(e){let t=W("shortcuts-dialog");t.root.setAttribute("aria-label","Keyboard Shortcuts");let r=document.createElement("table"),s=document.createElement("thead");r.append(s);let i=document.createElement("tr");s.append(i);let n=document.createElement("th");n.textContent="Key",i.append(n),n=document.createElement("th"),n.textContent="Action",i.append(n);let a=document.createElement("tbody");r.append(a);let l={};for(let[c,u]of e.allShortcuts().entries()){let g=c.split("+"),d=[g.pop(),...g].join("+");l[d]={name:u,shortcut:c}}for(let[,c]of Object.entries(l).sort()){let{name:u,shortcut:g}=c;i=document.createElement("tr"),a.append(i);let d=document.createElement("td");d.textContent=g.replaceAll("+"," + "),i.append(d),d=document.createElement("td"),d.textContent=e.text(u),i.append(d)}return t.heading.textContent="Transmission",t.dismiss.textContent="Close",t.heading.textContent="Keyboard shortcuts",t.message.append(r),t.confirm.remove(),delete t.confirm,t}};var Oe=class o extends EventTarget{constructor(e){super(),this.remote=e;let t=()=>this.remote.loadDaemonStats(s=>this._update(s.arguments)),r=5e3;this.interval=setInterval(t,r),t(),this.elements=o._create(),this.elements.dismiss.addEventListener("click",()=>this._onDismiss()),document.body.append(this.elements.root),this.elements.dismiss.focus()}close(){if(!this.closed){clearInterval(this.interval),this.elements.root.remove();for(let e of Object.keys(this))delete this[e];this.closed=!0}}_onDismiss(){this.close()}_update(e){console.log(e);let t=y,r=e["current-stats"],s=se.ratio(r.uploadedBytes,r.downloadedBytes);h(this.elements.session.up,t.size(r.uploadedBytes)),h(this.elements.session.down,t.size(r.downloadedBytes)),this.elements.session.ratio.innerHTML=t.ratioString(s),h(this.elements.session.time,t.timeInterval(r.secondsActive)),r=e["cumulative-stats"],s=se.ratio(r.uploadedBytes,r.downloadedBytes),h(this.elements.total.up,t.size(r.uploadedBytes)),h(this.elements.total.down,t.size(r.downloadedBytes)),this.elements.total.ratio.innerHTML=t.ratioString(s),h(this.elements.total.time,t.timeInterval(r.secondsActive))}static _create(){let e=W("statistics-dialog"),{confirm:t,dismiss:r,heading:s,root:i,workarea:n}=e;t.remove(),r.textContent="Close",delete e.confirm;let a="Statistics";i.setAttribute("aria-label",a),s.textContent=a;let l=["Uploaded:","Downloaded:","Ratio:","Running time:"],c=Pe("Current session",l),[u,g,d,p]=c.children,m=e.session={};m.up=u,m.down=g,m.ratio=d,m.time=p,n.append(c.root),c=Pe("Total",l);let[I,C,v,B]=c.children,x=e.total={};return x.up=I,x.down=C,x.ratio=v,x.time=B,n.append(c.root),e}};var L={createIcon:o=>{let e=document.createElement("div");return e.classList.add("icon"),e.dataset.iconMimeType=o.getPrimaryMimeType().split("/",1).pop(),e.dataset.iconMultifile=o.getFileCount()>1?"true":"false",e},formatDL:o=>`\u25BC ${y.speedBps(o.getDownloadSpeed())}`,formatETA:o=>{let e=o.getETA();return e<0||e>=999*60*60?"":`ETA: ${y.timeInterval(e,1)}`},formatLabels:(o,e)=>{let t=o.getLabels();e.innerHTML="";for(let r of t){let s=document.createElement("span");s.classList.add("torrent-label"),s.textContent=r,e.append(s)}},formatUL:o=>`\u25B2 ${y.speedBps(o.getUploadSpeed())}`,getProgressInfo:(o,e)=>{let t=e.getStatus(),r=["torrent-progress-bar"],s=null;if(t===f._StatusStopped&&r.push("paused"),e.needsMetaData())r.push("magnet"),s=e.getMetadataPercentComplete()*100;else if(t===f._StatusCheck)r.push("verify"),s=e.getRecheckProgress()*100;else if(e.getLeftUntilDone()>0)r.push("leech"),s=e.getPercentDone()*100;else{r.push("seed");let i=e.seedRatioLimit(o);s=i>0?e.getUploadRatio()*100/i:100}return e.isQueued()&&r.push("queued"),{classList:r,percent:s}},renderProgressbar:(o,e,t)=>{let r=L.getProgressInfo(o,e),s=`${y.percentString(r.percent,2)}%`;t.className=r.classList.join(" "),t.style.setProperty("--progress",s),t.dataset.progress=s}},Te=class o{static getPeerDetails(e){let t=y,r=e.getErrorMessage();if(r)return r;if(e.isDownloading()){let s=e.getPeersConnected(),i=e.getWebseedsSendingToUs();return i&&s?["Downloading from",e.getPeersSendingToUs(),"of",t.countString("peer","peers",s),"and",t.countString("web seed","web seeds",i),"\u2013",L.formatDL(e),L.formatUL(e)].join(" "):i?["Downloading from",t.countString("web seed","web seeds",i),"\u2013",L.formatDL(e),L.formatUL(e)].join(" "):["Downloading from",e.getPeersSendingToUs(),"of",t.countString("peer","peers",s),"\u2013",L.formatDL(e),L.formatUL(e)].join(" ")}return e.isSeeding()?["Seeding to",e.getPeersGettingFromUs(),"of",t.countString("peer","peers",e.getPeersConnected()),"-",L.formatUL(e)].join(" "):e.isChecking()?["Verifying local data (",y.percentString(100*e.getRecheckProgress(),1),"% tested)"].join(""):e.getStateString()}static getProgressDetails(e,t){if(t.needsMetaData()){let a="retrieving";t.isStopped()&&(a="needs");let l=100*t.getMetadataPercentComplete();return[`Magnetized transfer - ${a} metadata (`,y.percentString(l,1),"%)"].join("")}let r=t.getSizeWhenDone(),s=t.getTotalSize(),i=t.isDone()||t.isSeeding(),n=[];if(i?(s===r?n.push(y.size(s)):n.push(y.size(r)," of ",y.size(t.getTotalSize())," (",t.getPercentDoneStr(),"%)"),n.push(", uploaded ",y.size(t.getUploadedEver())," (Ratio ",y.ratioString(t.getUploadRatio()),")")):n.push(y.size(r-t.getLeftUntilDone())," of ",y.size(r)," (",t.getPercentDoneStr(),"%)"),!t.isStopped()&&(!i||t.seedRatioLimit(e)>0)){n.push(" - ");let a=t.getETA();a<0||a>=999*60*60?n.push("remaining time unknown"):n.push(y.timeInterval(t.getETA(),1)," remaining")}return n.join("")}render(e,t,r){let s=t.isStopped();r.classList.toggle("paused",s);let i=r._name_container;h(i,t.getName()),L.formatLabels(t,r._labels_container),i=r._progress_details_container,i.innerHTML=o.getProgressDetails(e,t),L.renderProgressbar(e,t,r._progressbar),r._progressbar.classList.add("full");let n=t.getError()!==f._ErrNone;i=r._peer_details_container,i.classList.toggle("error",n),h(i,o.getPeerDetails(t)),i=r._toggle_running_button,i.alt=s?"Resume":"Pause",i.dataset.action=s?"resume":"pause"}createRow(e){let t=document.createElement("li");t.className="torrent";let r=L.createIcon(e),s=document.createElement("div");s.className="torrent-name";let i=document.createElement("div");i.className="torrent-labels";let n=document.createElement("div");n.className="torrent-progress-details";let a=document.createElement("div");a.classList.add("torrent-progress");let l=document.createElement("div");l.classList.add("torrent-progress-bar","full"),a.append(l);let c=document.createElement("div");c.className="torrent-peer-details";let u=document.createElement("a");return u.className="torrent-pauseresume-button",a.append(u),t.append(r),t.append(s),t.append(i),t.append(n),t.append(a),t.append(c),t._icon=r,t._name_container=s,t._labels_container=i,t._progress_details_container=n,t._progressbar=l,t._peer_details_container=c,t._toggle_running_button=u,t}},Re=class o{static getPeerDetails(e){let t=e.getErrorMessage();if(t)return t;if(e.isDownloading()){let r=e.getDownloadSpeed()>0,s=e.getUploadSpeed()>0;if(!s&&!r)return"Idle";let i=[`${L.formatETA(e)} `];return r&&i.push(L.formatDL(e)),s&&i.push(L.formatUL(e)),i.join(" ")}return e.isSeeding()?`Ratio: ${y.ratioString(e.getUploadRatio())}, ${L.formatUL(e)}`:e.getStateString()}render(e,t,r){r.classList.toggle("paused",t.isStopped());let s=r._name_container;h(s,t.getName()),L.formatLabels(t,r._labels_container),L.renderProgressbar(e,t,r._progressbar),r._progressbar.classList.add("compact");let i=t.getError()!==f._ErrNone;s=r._details_container,s.classList.toggle("error",i),h(s,o.getPeerDetails(t))}createRow(e){let t=document.createElement("div");t.classList.add("torrent-progress-bar","compact");let r=L.createIcon(e),s=document.createElement("div");s.className="torrent-peer-details compact";let i=document.createElement("div");i.className="torrent-labels compact";let n=document.createElement("div");n.className="torrent-name compact";let a=document.createElement("li");return a.append(t),a.append(s),a.append(i),a.append(n),a.append(r),a.className="torrent compact",a._progressbar=t,a._details_container=s,a._labels_container=i,a._name_container=n,a}},Ye=class{constructor(e,t,r){this._view=e,this._torrent=r,this._element=e.createRow(r);let s=()=>this.render(t);this._torrent.addEventListener("dataChanged",s),s()}getElement(){return this._element}render(e){let t=this.getTorrent();t&&this._view.render(e,t,this.getElement())}isSelected(){return this.getElement().classList.contains("selected")}getTorrent(){return this._torrent}getTorrentId(){return this.getTorrent().getId()}};var Ne=class o extends EventTarget{constructor(e,t,r){super(),this.action_manager=e,this.notifications=t,this.prefs=r,this.remote=new ne(this),this.addEventListener("torrent-selection-changed",n=>this.action_manager.update(n)),this.filterText="",this._torrents={},this._rows=[],this.dirtyTorrents=new Set,this.changeStatus=!1,this.refilterSoon=H(()=>this._refilter(!1)),this.refilterAllSoon=H(()=>this._refilter(!0)),this.boundPopupCloseListener=this.popupCloseListener.bind(this),this.isTouch="ontouchstart"in window,this.busyclick=!1;for(let n of document.querySelectorAll("button[data-action]")){let{action:a}=n.dataset;Q(n,this.action_manager.isEnabled(a)),n.addEventListener("click",()=>{this.action_manager.click(a)})}document.querySelector("#filter-tracker").addEventListener("change",n=>{this.setFilterTracker(n.target.value==="all"?null:n.target.value)}),this.action_manager.addEventListener("change",n=>{for(let a of document.querySelectorAll(`[data-action="${n.action}"]`))Q(a,n.enabled)}),this.action_manager.addEventListener("click",n=>{switch(n.action){case"deselect-all":this._deselectAll();break;case"move-bottom":this._moveBottom();break;case"move-down":this._moveDown();break;case"move-top":this._moveTop();break;case"move-up":this._moveUp();break;case"open-torrent":this.setCurrentPopup(new $(this,this.remote));break;case"pause-all-torrents":this._stopTorrents(this._getAllTorrents());break;case"pause-selected-torrents":this._stopTorrents(this.getSelectedTorrents());break;case"reannounce-selected-torrents":this._reannounceTorrents(this.getSelectedTorrents());break;case"remove-selected-torrents":this._removeSelectedTorrents(!1);break;case"resume-selected-torrents":this._startSelectedTorrents(!1);break;case"resume-selected-torrents-now":this._startSelectedTorrents(!0);break;case"select-all":this._selectAll();break;case"show-about-dialog":this.setCurrentPopup(new xe(this.version_info));break;case"show-inspector":this.popup instanceof ie?this.setCurrentPopup(null):this.setCurrentPopup(new ie(this));break;case"show-move-dialog":this.setCurrentPopup(new Fe(this,this.remote));break;case"show-overflow-menu":this.popup instanceof ae?this.setCurrentPopup(null):this.setCurrentPopup(new ae(this,this.prefs,this.remote,this.action_manager));break;case"show-preferences-dialog":this.setCurrentPopup(new Le(this,this.remote));break;case"show-shortcuts-dialog":this.setCurrentPopup(new ke(this.action_manager));break;case"show-statistics-dialog":this.setCurrentPopup(new Oe(this.remote));break;case"show-rename-dialog":this.setCurrentPopup(new Ue(this,this.remote));break;case"show-labels-dialog":this.setCurrentPopup(new Qe(this,this.remote));break;case"start-all-torrents":this._startTorrents(this._getAllTorrents());break;case"toggle-compact-rows":this.prefs.display_mode=this.prefs.display_mode===b.DisplayCompact?b.DisplayFull:b.DisplayCompact;break;case"trash-selected-torrents":this._removeSelectedTorrents(!0);break;case"verify-selected-torrents":this._verifyTorrents(this.getSelectedTorrents());break;default:console.warn(`unhandled action: ${n.action}`)}});let s=document.querySelector("#filter-mode");s.value=this.prefs.filter_mode,s.addEventListener("change",n=>{this.prefs.filter_mode=n.target.value,this.refilterAllSoon()}),document.addEventListener("keydown",this._keyDown.bind(this)),document.addEventListener("keyup",this._keyUp.bind(this)),s=document.querySelector("#torrent-container"),s.addEventListener("click",n=>{this.popup&&this.popup.name!=="inspector"&&this.setCurrentPopup(null),n.target===n.currentTarget&&this._deselectAll()}),s.addEventListener("dblclick",()=>{(!this.popup||this.popup.name!=="inspector")&&this.action_manager.click("show-inspector")}),s.addEventListener("dragenter",o._dragenter),s.addEventListener("dragover",o._dragenter),s.addEventListener("drop",this._drop.bind(this)),this._setupSearchBox(),this.elements={torrent_list:document.querySelector("#torrent-list")};let i=n=>{if(this.isTouch&&n.touches.length>1)return;let a=n.target;for(;a&&!a.classList.contains("torrent");)a=a.parentNode;let l=this._rows.find(m=>m.getElement()===a);l&&!l.isSelected()&&this._setSelectedRow(l);let c=new Ze(this.action_manager);this.setCurrentPopup(c);let g=document.querySelector("#torrent-container").getBoundingClientRect(),d=Math.min(this.isTouch?n.touches[0].clientX:n.x,g.x+g.width-c.root.clientWidth),p=Math.min(this.isTouch?n.touches[0].clientY:n.y,g.y+g.height-c.root.clientHeight);c.root.style.left=`${d>0?d:0}px`,c.root.style.top=`${p>0?p:0}px`,n.preventDefault()};this.isTouch?(this.elements.torrent_list.addEventListener("touchstart",n=>{this.busyclick?(clearTimeout(this.busyclick),this.busyclick=!1):this.busyclick=setTimeout(i.bind(this),500,n)}),this.elements.torrent_list.addEventListener("touchend",()=>{clearTimeout(this.busyclick),this.busyclick=!1,setTimeout(()=>{this.popup&&(this.popup.root.style.pointerEvents="auto")},1)}),this.elements.torrent_list.addEventListener("touchmove",()=>{clearTimeout(this.busyclick),this.busyclick=!1}),this.elements.torrent_list.addEventListener("contextmenu",n=>{n.preventDefault()})):this.elements.torrent_list.addEventListener("contextmenu",n=>{i(n),this.popup&&(this.popup.root.style.pointerEvents="auto")}),this.loadDaemonPrefs(),this._initializeTorrents(),this.refreshTorrents(),this.togglePeriodicSessionRefresh(!0),this.prefs.addEventListener("change",({key:n,value:a})=>this._onPrefChanged(n,a));for(let[n,a]of this.prefs.entries())this._onPrefChanged(n,a)}_openTorrentFromUrl(){setTimeout(()=>{let e=new URLSearchParams(window.location.search).get("addtorrent");if(e){this.setCurrentPopup(new $(this,this.remote,e));let t=new URL(window.location);t.search="",window.history.pushState("","",t.toString())}},0)}loadDaemonPrefs(){this.remote.loadDaemonPrefs(e=>{this.session_properties=e.arguments,this._openTorrentFromUrl()})}get session_properties(){return this._session_properties}set session_properties(e){if(Be(this._session_properties,e))return;this._session_properties=Object.seal(e);let t=new Event("session-change");t.session_properties=e,this.dispatchEvent(t),this._updateGuiFromSession(e)}_setupSearchBox(){let e=document.querySelector("#torrent-search"),t="blur";e.classList.add(t),e.addEventListener("blur",()=>e.classList.add(t)),e.addEventListener("focus",()=>e.classList.remove(t)),e.addEventListener("keyup",()=>this._setFilterText(e.value))}_onPrefChanged(e,t){switch(e){case b.DisplayMode:{this.torrentRenderer=t==="compact"?new Re:new Te,this.refilterAllSoon();break}case b.ContrastMode:{document.body.classList.remove("contrast-more"),document.body.classList.remove("contrast-less"),document.body.classList.add(`contrast-${t}`);break}case b.FilterMode:case b.SortDirection:case b.SortMode:this.refilterAllSoon();break;case b.RefreshRate:{clearInterval(this.refreshTorrentsInterval);let r=this.refreshTorrents.bind(this),s=Math.max(2,this.prefs.refresh_rate_sec)*1e3;this.refreshTorrentsInterval=setInterval(r,s);break}default:break}}_getAllTorrents(){return Object.values(this._torrents)}static _getTorrentIds(e){return e.map(t=>t.getId())}seedRatioLimit(){let e=this.session_properties;return e&&e.seedRatioLimited?e.seedRatioLimit:-1}_getSelectedRows(){return this._rows.filter(e=>e.isSelected())}getSelectedTorrents(){return this._getSelectedRows().map(e=>e.getTorrent())}_getSelectedTorrentIds(){return o._getTorrentIds(this.getSelectedTorrents())}_setSelectedRow(e){let t=e?e.getElement():null;for(let r of this.elements.torrent_list.children)r.classList.toggle("selected",r===t);this._dispatchSelectionChanged()}_selectRow(e){e.getElement().classList.add("selected"),this._dispatchSelectionChanged()}_deselectRow(e){e.getElement().classList.remove("selected"),this._dispatchSelectionChanged()}_selectAll(){for(let e of this.elements.torrent_list.children)e.classList.add("selected");this._dispatchSelectionChanged()}_deselectAll(){for(let e of this.elements.torrent_list.children)e.classList.remove("selected");this._dispatchSelectionChanged(),delete this._last_torrent_clicked}_indexOfLastTorrent(){return this._rows.findIndex(e=>e.getTorrentId()===this._last_torrent_clicked)}_selectRange(e){let t=this._indexOfLastTorrent();if(t===-1)this._selectRow(e);else{let r=this._rows.indexOf(e),s=Math.min(t,r),i=Math.max(t,r);for(let n=s;n<=i;++n)this._selectRow(this._rows[n])}this._dispatchSelectionChanged()}_dispatchSelectionChanged(){let e=[],t=[];for(let s of this._rows)(s.isSelected()?t:e).push(s.getTorrent());let r=new Event("torrent-selection-changed");r.nonselected=e,r.selected=t,this.dispatchEvent(r)}static _createKeyShortcutFromKeyboardEvent(e){let t=[];return e.ctrlKey&&t.push("Control"),e.altKey&&t.push("Alt"),e.metaKey&&t.push("Meta"),e.shiftKey&&t.push("Shift"),t.push(e.key.length===1?e.key.toUpperCase():e.key),t.join("+")}_keyDown(e){let{ctrlKey:t,keyCode:r,metaKey:s,shiftKey:i,target:n}=e,a=["INPUT","TEXTAREA"].includes(n.tagName);if(!a){let g=o._createKeyShortcutFromKeyboardEvent(e),d=this.action_manager.getActionForShortcut(g);if(d){e.preventDefault(),this.action_manager.click(d);return}}if(r===27&&this.popup){this.setCurrentPopup(null),e.preventDefault();return}let c=document.querySelector(".popup:not(.hidden)"),u=this._rows;if(!a&&!c&&!s&&!t){let g=r===16,d=r===38,p=r===40;if((d||p)&&u.length>0){let m=this._indexOfLastTorrent(),I=this._shift_index,C=0,v=u.length-1,B=m;p&&B+1<=v?++B:d&&B-1>=C&&--B;let x=u[B];I>=0?I<=m&&m=m&&m>B?this._selectRow(x):(I>=m&&B>m||I<=m&&m>B)&&this._deselectRow(u[m]):i?this._selectRange(x):this._setSelectedRow(x),x&&(this._last_torrent_clicked=x.getTorrentId(),x.getElement().scrollIntoView(),e.preventDefault())}else g&&(this._shift_index=this._indexOfLastTorrent())}}_keyUp(e){e.keyCode===16&&delete this._shift_index}static _dragenter(e){if(e.dataTransfer&&e.dataTransfer.types){let t=new Set(["text/uri-list","text/plain"]);if(e.dataTransfer.types.some(r=>t.has(r))||e.dataTransfer.types.includes("Files"))return e.stopPropagation(),e.preventDefault(),e.dataTransfer.dropEffect="copy",!1}else e.dataTransfer&&(e.dataTransfer.dropEffect="none");return!0}static _isValidURL(e){try{return!!new URL(e)}catch{return!1}}shouldAddedTorrentsStart(){return this.session_properties["start-added-torrents"]}_drop(e){let t=!this.shouldAddedTorrentsStart();if(!e.dataTransfer||!e.dataTransfer.types)return!0;let r=e.dataTransfer.types.findLast(i=>["text/uri-list","text/plain"].includes(i));for(let i of e.dataTransfer.getData(r).split(`
+`).map(n=>n.trim()).filter(n=>o._isValidURL(n)))this.remote.addTorrentByUrl(i,t);let{files:s}=e.dataTransfer;return s.length>0&&this.setCurrentPopup(new $(this,this.remote,"",s)),e.preventDefault(),!1}togglePeriodicSessionRefresh(e){!e&&this.sessionInterval&&(clearInterval(this.sessionInterval),delete this.sessionInterval),e&&(this.loadDaemonPrefs(),this.sessionInterval||(this.sessionInterval=setInterval(this.loadDaemonPrefs.bind(this),8e3)))}_setFilterText(e){this.filterText=e?e.trim():null,this.refilterAllSoon()}_onTorrentChanged(e){this.changeStatus&&(this._dispatchSelectionChanged(),this.changeStatus=!1);let t=e.currentTarget;this.dirtyTorrents.add(t.getId()),this.refilterSoon()}updateTorrents(e,t){this.remote.updateTorrents(e,t,(r,s)=>{let i=[],n=r.shift(),a={};for(let l of r){for(let[g,d]of n.entries())a[d]=l[g];let{id:c}=a,u=this._torrents[c];if(u){let g=u.needsMetaData();u.refresh(a),g&&!u.needsMetaData()&&i.push(c)}else u=this._torrents[c]=new f(a),u.addEventListener("dataChanged",this._onTorrentChanged.bind(this)),this.dirtyTorrents.add(c),(!("name"in u.fields)||!("status"in u.fields))&&i.push(c)}if(i.length>0){let l=["id",...f.Fields.Metadata,...f.Fields.Stats];this.updateTorrents(i,l),this.refilterSoon()}s&&(this._deleteTorrents(s),this.refilterSoon())})}refreshTorrents(){let e=["id",...f.Fields.Stats];this.updateTorrents("recently-active",e)}_initializeTorrents(){let e=["id",...f.Fields.Metadata,...f.Fields.Stats];this.updateTorrents(null,e)}_onRowClicked(e){let t=e.metaKey||e.ctrlKey,{row:r}=e.currentTarget;if(this.popup&&this.popup.name!=="inspector"&&this.setCurrentPopup(null),e.target.classList.contains("torrent-pauseresume-button"))switch(e.target.dataset.action){case"pause":this._stopTorrents([r.getTorrent()]);break;case"resume":this._startTorrents([r.getTorrent()]);break;default:break}e.stopPropagation(),e.shiftKey?(this._selectRange(r),window.focus()):!r.isSelected()&&t?this._selectRow(r):r.isSelected()?r.isSelected()&&t?this._deselectRow(r):r.isSelected()&&this._setSelectedRow(r):this._setSelectedRow(r),this._last_torrent_clicked=r.getTorrentId()}_deleteTorrents(e){if(e&&e.length>0){for(let t of e)this.dirtyTorrents.add(t),delete this._torrents[t];this.refilterSoon()}}_removeSelectedTorrents(e){let t=this.getSelectedTorrents();t.length>0&&this.setCurrentPopup(new we({remote:this.remote,torrents:t,trash:e}))}_startSelectedTorrents(e){this._startTorrents(this.getSelectedTorrents(),e)}_startTorrents(e,t){this.changeStatus=!0,this.remote.startTorrents(o._getTorrentIds(e),t,this.refreshTorrents,this)}_verifyTorrents(e){this.remote.verifyTorrents(o._getTorrentIds(e),this.refreshTorrents,this)}_reannounceTorrents(e){this.remote.reannounceTorrents(o._getTorrentIds(e),this.refreshTorrents,this)}_stopTorrents(e){this.changeStatus=!0,this.remote.stopTorrents(o._getTorrentIds(e),()=>{setTimeout(()=>{this.refreshTorrents()},500)},this)}changeFileCommand(e,t,r){this.remote.changeFileCommand(e,t,r)}_moveTop(){this.remote.moveTorrentsToTop(this._getSelectedTorrentIds(),this.refreshTorrents,this)}_moveUp(){this.remote.moveTorrentsUp(this._getSelectedTorrentIds(),this.refreshTorrents,this)}_moveDown(){this.remote.moveTorrentsDown(this._getSelectedTorrentIds(),this.refreshTorrents,this)}_moveBottom(){this.remote.moveTorrentsToBottom(this._getSelectedTorrentIds(),this.refreshTorrents,this)}_updateGuiFromSession(e){let[,t,r]=e.version.match(/(.*)\s\(([\da-f]+)\)/);this.version_info={checksum:r,version:t},document.querySelector("#toolbar-overflow").classList.toggle("alt-speed-enabled",e[X._TurtleState])}_updateStatusbar(){let e=y,t=this._getAllTorrents(),r=t.reduce((n,a)=>n+a.getUploadSpeed(),0),s=t.reduce((n,a)=>n+a.getDownloadSpeed(),0),i=e.countString("Transfer","Transfers",this._rows.length);h(document.querySelector("#speed-up-label"),e.speedBps(r)),h(document.querySelector("#speed-dn-label"),e.speedBps(s)),h(document.querySelector("#filter-count"),i)}static _displayName(e){let t=e;return t.length>0&&(t=t.charAt(0).toUpperCase()+t.slice(1)),t}_updateFilterSelect(){let e=this._getTrackerCounts(),t=Object.keys(e).sort(),r="";r+=this.filterTracker?'':'';for(let s of t)r+=``;(!this.filterTrackersStr||this.filterTrackersStr!==r)&&(this.filterTrackersStr=r,document.querySelector("#filter-tracker").innerHTML=r)}sortRows(e){let t=e.map(s=>s.getTorrent()),r=e.reduce((s,i)=>(s[i.getTorrent().getId()]=i,s),{});f.sortTorrents(t,this.prefs.sort_mode,this.prefs.sort_direction);for(let[s,i]of t.entries())e[s]=r[i.getId()]}_refilter(e){let{sort_mode:t,sort_direction:r,filter_mode:s}=this.prefs,i=this.filterTracker,n=this.torrentRenderer,a=this.elements.torrent_list,l=null,c=null,u=/^labels:([\w,-\s]*)(.*)$/.exec(this.filterText);u?(l=u[2].trim(),c=u[1].split(",")):(l=this.filterText,c=[]);let g=()=>[...a.children].length,d=()=>[...a.children].reduce((w,k)=>w+k.classList.contains("selected")?1:0,0),p=g(),m=d();if(this._updateFilterSelect(),e){for(;a.firstChild;)a.firstChild.remove();this._rows=[],this.dirtyTorrents=new Set(Object.keys(this._torrents))}let I=[],C=[];for(let w of this._rows)this.dirtyTorrents.has(w.getTorrentId())?C.push(w):I.push(w);for(let w of C)w.getElement().remove();let v=[];for(let w of C){let k=w.getTorrentId(),T=this._torrents[k];T&&T.test(s,i,l,c)&&v.push(w),this.dirtyTorrents.delete(k)}C=v;for(let w of this.dirtyTorrents.values()){let k=this._torrents[w];if(k&&k.test(s,i,l,c)){let T=new Ye(n,this,k),qe=T.getElement();qe.row=T,C.push(T),qe.addEventListener("click",this._onRowClicked.bind(this))}}this.sortRows(C);let B=[],x=I.length,A=C.length,G=document.createDocumentFragment(),U=0,ce=0;for(;U!==x||ce!==A;){let w=null;if(U===x?w=!1:ce===A?w=!0:w=f.compareTorrents(I[U].getTorrent(),C[ce].getTorrent(),t,r)<0,w)B.push(I[U++]);else{let k=C[ce++],T=k.getElement();U===x?G.append(T):a.insertBefore(T,I[U].getElement()),B.push(k)}}a.append(G),this._rows=B,this.dirtyTorrents.clear(),this._updateStatusbar(),(m!==d()||p!==g())&&this._dispatchSelectionChanged()}setFilterTracker(e){let t=document.querySelector("#filter-tracker");t.value=e,this.filterTracker=e,this.refilterAllSoon()}_getTrackerCounts(){let e={};for(let t of this._getAllTorrents())for(let r of t.getTrackers()){let{sitename:s}=r;e[s]=(e[s]||0)+1}return e}popupCloseListener(e){if(e.target!==this.popup)throw new Error(e);this.popup.removeEventListener("close",this.boundPopupCloseListener),delete this.popup}setCurrentPopup(e){this.popup&&this.popup.close(),this.popup=e,this.popup&&this.popup.addEventListener("close",this.boundPopupCloseListener)}};function Uo(){let o=new le,e=new b,t=new ve(e),r=new Ne(o,t,e),s=H(()=>r.elements.torrent_list.scrollTo(0,1));window.addEventListener("load",s),window.addEventListener("orientationchange",s)}document.addEventListener("DOMContentLoaded",Uo);})();
//# sourceMappingURL=transmission-app.js.map