mirror of
https://github.com/moku-project/Moku.git
synced 2026-06-13 09:19:56 -05:00
Chore: Flathub Support (Tinkering Around)
This commit is contained in:
@@ -272,6 +272,14 @@
|
||||
migrateFrom = null; migrateTo = null; migrateError = null; migrateProgress = null;
|
||||
}
|
||||
|
||||
async function browseDownloadsFolder() {
|
||||
const picked = await invoke<string | null>("pick_downloads_folder");
|
||||
if (picked) {
|
||||
downloadsPathInput = picked;
|
||||
pathsFieldError = { ...pathsFieldError, dl: undefined };
|
||||
}
|
||||
}
|
||||
|
||||
function addExtraScanDir() {
|
||||
const dir = newScanDir.trim();
|
||||
if (!dir || extraScanDirs.includes(dir)) return;
|
||||
@@ -1633,6 +1641,11 @@
|
||||
onkeydown={(e) => e.key === "Enter" && savePaths()}
|
||||
oninput={() => { pathsFieldError = { ...pathsFieldError, dl: undefined }; }}
|
||||
/>
|
||||
{#if !isExternalServer}
|
||||
<button class="sec-action-btn" onclick={browseDownloadsFolder} title="Browse for folder">
|
||||
Browse
|
||||
</button>
|
||||
{/if}
|
||||
<div class="path-actions">
|
||||
{#if pathsFieldError.dl}
|
||||
<span class="path-field-error">{pathsFieldError.dl}</span>
|
||||
@@ -3118,4 +3131,4 @@
|
||||
.content-action-btn:hover { color: var(--text-muted); border-color: var(--border-strong); background: var(--bg-overlay); }
|
||||
.content-action-active-allow { color: var(--color-success) !important; border-color: color-mix(in srgb, var(--color-success) 40%, transparent) !important; background: color-mix(in srgb, var(--color-success) 10%, transparent) !important; }
|
||||
.content-action-active-block { color: var(--color-error) !important; border-color: color-mix(in srgb, var(--color-error) 40%, transparent) !important; background: color-mix(in srgb, var(--color-error) 10%, transparent) !important; }
|
||||
</style>
|
||||
</style>
|
||||
Reference in New Issue
Block a user