Skip to content

armgit / peach

Public Imported from GitHub
0

Peach: Local-first video metadata scraper and media manager.

fix(web): 页面上独立的任务进度条单独成框

longmeidaoc96c776c7e20
diff --git a/CHANGELOG.md b/CHANGELOG.md
index 245838c00..bf8e3ac4b 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -33,6 +33,7 @@ Removed / Fixed / Security。
### 修复
- **关注**:rule34video 作品里站方单列在 Characters 一组的角色(如 `harry potter (harry potter)`)记成角色,归到题材一排,不再和 `sex`、`doggystyle position` 混在内容标签里;站方没单列成角色的标签照旧算内容标签。已入库的条目用 `scripts/backfill_rule34video_characters.py` 重读详情页补上。
+- **界面**:「发现」页读取作品资料、系统诊断页生成诊断报告时,进度条放进自己的框里,不再直接摊在页面上;诊断报告的进度占满整行,不再挤在右上角的按钮旁。
- **关注**:批量删除作品、清空回收站后,关注新作和想要清单里已经取到的封面不再被当成无用缓存一起删掉;没有番号的作品封面同样保留。升级后,被删掉的封面由补封面任务陆续重新取回。
- **界面**:作品详情缺封面时改为空状态卡,可以点「立即重试」当场重新获取官方封面,取不到时写明原因;浅色主题下缺图的缩略图格不再白底白字。
- **馆藏**:`MCDV-24`(无码)与 `MCDV-024`(有码)不再被当成同一部,资料和封面各取各的;升级后,扫描时按旧规则补零写成 `MCDV-024` 的无码片自动改回 `MCDV-24` 并重新取资料。
diff --git a/frontend/src/react/components/task-progress.tsx b/frontend/src/react/components/task-progress.tsx
index 2d466a696..5ce7bd884 100644
--- a/frontend/src/react/components/task-progress.tsx
+++ b/frontend/src/react/components/task-progress.tsx
@@ -7,7 +7,7 @@ export function TaskProgress({ label, value = 0, total, embedded = false }: {
label: string; value?: number; total?: number | null; embedded?: boolean;
}) {
return (
- <div data-task-progress className={embedded ? 'flex flex-col gap-1.5' : cardClass({
+ <div data-task-progress={embedded ? 'embedded' : 'framed'} className={embedded ? 'flex flex-col gap-1.5' : cardClass({
variant: 'outlined', padding: 'none', className: 'flex flex-col gap-1.5 px-4 py-3.5',
})}>
{total && total > 0 ? <>
diff --git a/frontend/src/react/diagnostics/diagnostics-page.tsx b/frontend/src/react/diagnostics/diagnostics-page.tsx
index e4a6ad2cc..78055df2b 100644
--- a/frontend/src/react/diagnostics/diagnostics-page.tsx
+++ b/frontend/src/react/diagnostics/diagnostics-page.tsx
@@ -83,8 +83,8 @@ export function DiagnosticsPage(props: DiagnosticsProps) {
const attention = Object.entries(data.checks).filter(([, check]) => ['warning', 'failed', 'unknown'].includes(check.status));
const other = Object.entries(data.checks).filter(([, check]) => !['warning', 'failed', 'unknown'].includes(check.status));
return <div className="flex min-w-0 flex-col gap-6">
- <div data-guide-target="report" className="flex flex-wrap justify-end gap-2"><DownloadReport />
- <Button variant="secondary" onClick={refresh} {...busyProps(action.busy === 'refresh')}>重新检查</Button></div>
+ <div data-guide-target="report"><DiagnosticExportAction kind="support">
+ <Button variant="secondary" onClick={refresh} {...busyProps(action.busy === 'refresh')}>重新检查</Button></DiagnosticExportAction></div>
{refreshError ? <Note tone="error">{refreshError}</Note> : null}
{attention.length ? <Section guide="attention" title={`需要关注 · ${attention.length} 项`}>
{attention.map(([key, check]) => <Check key={key} name={key} check={check} />)}
diff --git a/frontend/src/react/diagnostics/scraping-export.tsx b/frontend/src/react/diagnostics/scraping-export.tsx
index da4fd49bb..22e4ab5e4 100644
--- a/frontend/src/react/diagnostics/scraping-export.tsx
+++ b/frontend/src/react/diagnostics/scraping-export.tsx
@@ -1,13 +1,12 @@
-import { useState } from 'react';
+import { useState, type ReactNode } from 'react';
import { useQuery } from '@tanstack/react-query';
import { Button, ButtonLink } from '@/components/base/buttons/button';
import { Input } from '@/components/base/input/input';
import { ApiError, apiGet, apiSend } from '../../api';
import { diagnosticHeaders } from '../../browser-diagnostics';
import { Fieldset, FieldsetTitle } from '../components/fieldset';
-import { LoadingDots } from '../components/loading-dots';
import { Note } from '../components/note';
-import { Progress } from '../components/progress';
+import { TaskProgress } from '../components/task-progress';
import { queryClient } from '../query';
import { busyProps, useAction } from '../settings/use-action';
@@ -20,7 +19,11 @@ interface ExportState {
download_url?: string; error?: string;
}
-export function DiagnosticExportAction({ kind, codes = '' }: { kind: 'support' | 'scraping'; codes?: string }) {
+/** 导出按钮与它的进度、回执。刮削记录在卡片底栏里,进度复用卡片;诊断报告摆在页头,进度自己带框,
+ * `children` 是页头同一排的其他按钮。 */
+export function DiagnosticExportAction({ kind, codes = '', children }: {
+ kind: 'support' | 'scraping'; codes?: string; children?: ReactNode;
+}) {
const action = useAction();
const query = useQuery({ queryKey: KEY, queryFn: ({ signal }) => apiGet<ExportState>(URL, signal),
refetchInterval: query => ['running', 'cancelling'].includes(query.state.data?.status || '') ? 1000 : false });
@@ -40,17 +43,17 @@ export function DiagnosticExportAction({ kind, codes = '' }: { kind: 'support' |
const cancel = () => void action.run('cancel', signal => apiSend<ExportState>(
`${URL}/${state!.job_id}/cancel`, {}, 'POST', signal), update);
return <div className="flex min-w-0 flex-col gap-3">
- <div className="flex flex-wrap gap-2">
+ <div className={kind === 'support' ? 'flex flex-wrap justify-end gap-2' : 'flex flex-wrap gap-2'}>
<Button type="button" variant="secondary" disabled={active} {...busyProps(action.busy === 'start')} onClick={start}>{label}</Button>
{mine && active ? <Button type="button" variant="secondary" disabled={state.status === 'cancelling'}
{...busyProps(action.busy === 'cancel')} onClick={cancel}>取消导出</Button> : null}
{mine && state.status === 'complete' && state.download_url ? <ButtonLink variant="secondary"
href={state.download_url}>下载已生成的文件</ButtonLink> : null}
+ {children}
</div>
- {mine && active ? state.total && state.total > 0 ? <div className="flex flex-col gap-2" role="status">
- <span className="text-body-2-regular">{state.stage} · {state.done || 0} / {state.total} 项</span>
- <Progress label="导出进度" value={state.done || 0} max={state.total} />
- </div> : <LoadingDots label={`${state.stage || '准备导出'}${state.rows ? ` · ${state.rows} 条候选` : ''}${state.files ? ` · ${state.files} 个文件` : ''}`} /> : null}
+ {mine && active ? <TaskProgress embedded={kind === 'scraping'} value={state.done || 0} total={state.total}
+ label={state.total ? `${state.stage} · ${state.done || 0} / ${state.total} 项`
+ : `${state.stage || '准备导出'}${state.rows ? ` · ${state.rows} 条候选` : ''}${state.files ? ` · ${state.files} 个文件` : ''}`} /> : null}
{mine && state.status === 'complete' ? <p role="status" className="text-body-2-regular text-text-secondary">
导出已完成 · {((state.bytes || 0) / 1024 / 1024).toFixed(2)} MiB</p> : null}
{mine && state.status === 'cancelled' ? <Note tone="neutral">导出已取消</Note> : null}
diff --git a/frontend/src/react/jav/jav-page.tsx b/frontend/src/react/jav/jav-page.tsx
index 441054886..d88cada09 100644
--- a/frontend/src/react/jav/jav-page.tsx
+++ b/frontend/src/react/jav/jav-page.tsx
@@ -144,7 +144,7 @@ function Discover({ readOnly, receipt, resource, query, navigate, clearText }: {
</>} />
{waiting ? <div role="status" aria-label="正在读取推荐" dangerouslySetInnerHTML={{ __html: javContentSkeleton('discover', layout) }} /> : null}
{discoveries.error ? <Note tone="error" title="推荐未取得">{errorMessage(discoveries.error)}</Note> : null}
- {scope === 'external' && metadata?.status === 'running' ? <div data-jav-metadata="" className="min-w-0"><TaskProgress embedded
+ {scope === 'external' && metadata?.status === 'running' ? <div data-jav-metadata="" className="min-w-0"><TaskProgress
label={`正在读取作品资料 · ${metadata.completed} / ${metadata.total} 部`} value={metadata.completed} total={metadata.total} /></div> : null}
{metadata && metadata.status !== 'running' && (metadata.status !== 'complete' || metadata.failed > 0)
? <Note tone="neutral" action={<Button variant="secondary" {...busyProps(metadataAction.busy === 'retry')}
diff --git a/frontend/test/react/diagnostics.test.tsx b/frontend/test/react/diagnostics.test.tsx
index 57d708bab..624c9df14 100644
--- a/frontend/test/react/diagnostics.test.tsx
+++ b/frontend/test/react/diagnostics.test.tsx
@@ -34,6 +34,7 @@ it('刮削记录显示后台进度并支持取消', async () => {
const host = await mount(<QueryClientProvider client={queryClient}><ScrapingExport /></QueryClientProvider>);
await settle();
expect(host.querySelector('[role="progressbar"]')?.getAttribute('aria-valuenow')).toBe('2');
+ expect(host.querySelector('[data-task-progress]')?.getAttribute('data-task-progress')).toBe('embedded');
expect((buttonNamed('导出刮削记录', host) as HTMLButtonElement).disabled).toBe(true);
await click(buttonNamed('取消导出', host));
await settle();
@@ -120,6 +121,17 @@ it('恢复动作的名称与实际目标一致', async () => {
expect(linkNamed('打开来源和凭证', host)?.getAttribute('href')).toBe('/sources');
});
+it('页头的诊断报告进度自己带框,和重新检查同排', async () => {
+ vi.stubGlobal('fetch', vi.fn(async (url: string) => new Response(JSON.stringify(url.startsWith('/api/diagnostics/exports')
+ ? { status: 'running', kind: 'support', job_id: 'report', stage: '收集日志', done: 1, total: 4 }
+ : data()))));
+ const { host } = await open();
+ await settle();
+ const report = host.querySelector('[data-guide-target="report"]')!;
+ expect(report.querySelector('[data-task-progress]')?.getAttribute('data-task-progress')).toBe('framed');
+ expect(buttonNamed('取消导出', report)?.parentElement).toBe(buttonNamed('重新检查', report)?.parentElement);
+});
+
it('诊断报告启动时附浏览器环境,产物使用直接下载链接', async () => {
const create = vi.spyOn(URL, 'createObjectURL');
const fetch = vi.fn(async (_url: string, options?: RequestInit) => new Response(JSON.stringify(options?.method === 'POST'
diff --git a/frontend/test/react/jav-page.test.tsx b/frontend/test/react/jav-page.test.tsx
index 1fb35505c..d19de9986 100644
--- a/frontend/test/react/jav-page.test.tsx
+++ b/frontend/test/react/jav-page.test.tsx
@@ -103,3 +103,14 @@ it('没有推荐时空态的查看口味在左,主入口在右', async () => {
const main = [...host.querySelectorAll('[data-empty-state] a')].find((link) => link.textContent === '浏览馆藏');
expect(main?.className).toContain('bg-button-primary');
});
+
+it('发现页读取作品资料的进度单独成框', async () => {
+ history.replaceState(null, '', '/jav?tab=discover');
+ vi.stubGlobal('fetch', vi.fn(async () => ({ ok: true, status: 200, json: async () => ({ items: [], candidate_total: 0, limited: false,
+ metadata_job: { job_id: 'm', status: 'running', completed: 37, total: 100, failed: 0, requests: 0, bytes: 0 } }) })));
+ const host = await mount(<QueryClientProvider client={queryClient}><JavPage tab="discover" readOnly navigate={vi.fn()} receipt={vi.fn()} /></QueryClientProvider>);
+ await settle();
+ const progress = host.querySelector('[data-task-progress]');
+ expect(progress?.getAttribute('data-task-progress')).toBe('framed');
+ expect(progress?.querySelector('[role="progressbar"]')?.getAttribute('aria-valuenow')).toBe('37');
+});
diff --git a/web/dist/peach-app.diagnostics-page-yTNOV5os.js b/web/dist/peach-app.diagnostics-page-DS1L_wLs.js
similarity index 51%
rename from web/dist/peach-app.diagnostics-page-yTNOV5os.js
rename to web/dist/peach-app.diagnostics-page-DS1L_wLs.js
index eaeec8548..d800da34c 100644
--- a/web/dist/peach-app.diagnostics-page-yTNOV5os.js
+++ b/web/dist/peach-app.diagnostics-page-DS1L_wLs.js
@@ -1,15 +1,15 @@
(function() {
try {
var e = typeof globalThis < "u" ? globalThis : typeof window < "u" ? window : typeof global < "u" ? global : typeof self < "u" ? self : {}, t = new e.Error().stack;
- t && (e._sentryDebugIds = e._sentryDebugIds || {}, e._sentryDebugIds[t] = "6af8e849-7d10-4c99-9069-a7bbd03bfb41", e._sentryDebugIdIdentifier = "sentry-dbid-6af8e849-7d10-4c99-9069-a7bbd03bfb41");
+ t && (e._sentryDebugIds = e._sentryDebugIds || {}, e._sentryDebugIds[t] = "2cc05748-2a4c-4130-93b7-a6ff4beab2d8", e._sentryDebugIdIdentifier = "sentry-dbid-2cc05748-2a4c-4130-93b7-a6ff4beab2d8");
} catch {}
})();
-import { ApiError as e, Button as t, ButtonLink as n, Chip as r, DIAGNOSTICS_KEY as i, Disclosure as a, EmptyState as o, Fact as s, FactList as c, Fieldset as l, FieldsetTitle as u, Input as d, LOC as f, LinkButton as p, LoadingDots as m, Note as h, Progress as g, Section as _, SettingsCard as v, SettingsSectionLabel as y, Stack as b, __toESM as x, apiGet as S, apiSend as C, busyProps as w, configurationSection as ee, cx as T, diagnosticHeaders as E, diagnosticsSkeleton as D, errorMessage as O, fetchDiagnostics as k, fmtDur as A, fmtSize as j, queryClient as te, require_jsx_runtime as ne, require_react as re, settingsPath as ie, tl as M, useAction as N, useQuery as P } from "./peach-app.js";
-import { ErrorExcerpt as F } from "./peach-app.error-excerpt-B8v2xEIP.js";
-import { DataTable as I } from "./peach-app.data-table-aWN3V7mT.js";
-import { SiteMark as L } from "./peach-app.site-mark-D_VlIyJz.js";
+import { ApiError as e, Button as t, ButtonLink as n, Chip as r, DIAGNOSTICS_KEY as i, Disclosure as a, EmptyState as o, Fact as s, FactList as c, Fieldset as l, FieldsetTitle as u, Input as d, LOC as f, LinkButton as p, Note as m, Section as h, SettingsCard as g, SettingsSectionLabel as _, Stack as v, TaskProgress as y, __toESM as b, apiGet as ee, apiSend as x, busyProps as S, configurationSection as C, cx as w, diagnosticHeaders as T, diagnosticsSkeleton as E, errorMessage as D, fetchDiagnostics as O, fmtDur as k, fmtSize as A, queryClient as j, require_jsx_runtime as M, require_react as N, settingsPath as P, tl as F, useAction as I, useQuery as L } from "./peach-app.js";
+import { ErrorExcerpt as R } from "./peach-app.error-excerpt-B8v2xEIP.js";
+import { DataTable as z } from "./peach-app.data-table-aWN3V7mT.js";
+import { SiteMark as B } from "./peach-app.site-mark-D_VlIyJz.js";
// src/react/diagnostics/health-list.tsx
-var R = /* @__PURE__ */ x(re(), 1), z = ne(), B = (e) => e.title || e.name || e.code || `作品 #${e.id}`, V = (e) => [[
+var V = /* @__PURE__ */ b(N(), 1), H = M(), U = (e) => e.title || e.name || e.code || `作品 #${e.id}`, W = (e) => [[
"作品",
"番号",
"文件名",
@@ -18,7 +18,7 @@ var R = /* @__PURE__ */ x(re(), 1), z = ne(), B = (e) => e.title || e.name || e.
"时长(秒)",
"大小(字节)"
], ...e.map((e) => [
- B(e),
+ U(e),
e.code ?? "",
e.name,
f[e.location] || e.location,
@@ -26,20 +26,20 @@ var R = /* @__PURE__ */ x(re(), 1), z = ne(), B = (e) => e.title || e.name || e.
e.duration ?? "",
e.size ?? ""
])].map((e) => e.map((e) => String(e ?? "").replace(/[\t\r\n]+/g, " ")).join(" ")).join("\n");
-function H({ group: e, openItem: n, receipt: r }) {
- let i = N(), [s, c] = (0, R.useState)([]), l = (e) => void i.run("copy", () => navigator.clipboard.writeText(V(e)), () => r("已复制清单")), u = [
+function G({ group: e, openItem: n, receipt: r }) {
+ let i = I(), [s, c] = (0, V.useState)([]), l = (e) => void i.run("copy", () => navigator.clipboard.writeText(W(e)), () => r("已复制清单")), u = [
{
id: "title",
label: "作品",
- value: B,
- render: (e) => /* @__PURE__ */ (0, z.jsxs)("span", {
+ value: U,
+ render: (e) => /* @__PURE__ */ (0, H.jsxs)("span", {
className: "flex min-w-0 flex-col gap-1",
- children: [/* @__PURE__ */ (0, z.jsx)(p, {
+ children: [/* @__PURE__ */ (0, H.jsx)(p, {
variant: "primary",
className: "justify-start whitespace-normal text-left",
onClick: () => n(e.id),
- children: B(e)
- }), e.name && e.name !== B(e) ? /* @__PURE__ */ (0, z.jsx)("span", {
+ children: U(e)
+ }), e.name && e.name !== U(e) ? /* @__PURE__ */ (0, H.jsx)("span", {
"data-middle-truncate": !0,
title: e.name,
className: "block min-w-0 text-caption-1-regular text-text-secondary",
@@ -52,7 +52,7 @@ function H({ group: e, openItem: n, receipt: r }) {
label: "番号",
width: 144,
value: (e) => e.code || "",
- render: (e) => /* @__PURE__ */ (0, z.jsx)("span", {
+ render: (e) => /* @__PURE__ */ (0, H.jsx)("span", {
className: "whitespace-nowrap",
children: e.code || "未识别"
})
@@ -70,7 +70,7 @@ function H({ group: e, openItem: n, receipt: r }) {
width: 320,
min: 180,
value: (e) => e.path,
- render: (e) => /* @__PURE__ */ (0, z.jsx)("span", {
+ render: (e) => /* @__PURE__ */ (0, H.jsx)("span", {
"data-middle-truncate": !0,
title: e.path,
className: "block min-w-0 w-full text-body-2-regular text-text-secondary",
@@ -82,25 +82,25 @@ function H({ group: e, openItem: n, receipt: r }) {
label: "时长",
width: 112,
value: (e) => e.duration ?? 0,
- render: (e) => e.duration && e.duration > 0 ? A(e.duration) : "未取得"
+ render: (e) => e.duration && e.duration > 0 ? k(e.duration) : "未取得"
},
{
id: "size",
label: "大小",
width: 112,
value: (e) => e.size ?? 0,
- render: (e) => e.size === null ? "未取得" : j(e.size)
+ render: (e) => e.size === null ? "未取得" : A(e.size)
}
];
- return /* @__PURE__ */ (0, z.jsx)(a, {
+ return /* @__PURE__ */ (0, H.jsx)(a, {
summary: `${e.label} · ${e.count === null ? "未取得" : `${e.count.toLocaleString()} 项`}`,
- children: e.count === null ? /* @__PURE__ */ (0, z.jsx)(h, {
+ children: e.count === null ? /* @__PURE__ */ (0, H.jsx)(m, {
tone: "neutral",
children: "清单未取得,请重新检查。"
- }) : e.items.length ? /* @__PURE__ */ (0, z.jsxs)(b, { children: [
- /* @__PURE__ */ (0, z.jsxs)("div", {
+ }) : e.items.length ? /* @__PURE__ */ (0, H.jsxs)(v, { children: [
+ /* @__PURE__ */ (0, H.jsxs)("div", {
className: "flex flex-wrap items-center justify-between gap-2",
- children: [e.truncated ? /* @__PURE__ */ (0, z.jsxs)("span", {
+ children: [e.truncated ? /* @__PURE__ */ (0, H.jsxs)("span", {
className: "text-body-2-regular text-text-secondary",
children: [
"已载入 ",
@@ -109,19 +109,19 @@ function H({ group: e, openItem: n, receipt: r }) {
e.count.toLocaleString(),
" 项"
]
- }) : null, /* @__PURE__ */ (0, z.jsx)(t, {
+ }) : null, /* @__PURE__ */ (0, H.jsx)(t, {
size: "small",
variant: "secondary",
- ...w(i.busy === "copy"),
+ ...S(i.busy === "copy"),
onClick: () => l(e.items),
children: "复制当前清单"
})]
}),
- i.error ? /* @__PURE__ */ (0, z.jsx)(h, {
+ i.error ? /* @__PURE__ */ (0, H.jsx)(m, {
tone: "error",
children: i.error
}) : null,
- /* @__PURE__ */ (0, z.jsx)(I, {
+ /* @__PURE__ */ (0, H.jsx)(z, {
label: e.label,
title: "作品清单",
unit: "部作品",
@@ -129,19 +129,19 @@ function H({ group: e, openItem: n, receipt: r }) {
items: e.items,
columns: u,
rowId: (e) => String(e.id),
- rowLabel: B,
+ rowLabel: U,
selected: s,
onSelected: c,
- actions: (e) => /* @__PURE__ */ (0, z.jsx)(t, {
+ actions: (e) => /* @__PURE__ */ (0, H.jsx)(t, {
size: "small",
variant: "secondary",
- ...w(i.busy === "copy"),
+ ...S(i.busy === "copy"),
onClick: () => l(e),
children: "复制所选"
})
})
- ] }) : /* @__PURE__ */ (0, z.jsx)(o, {
- icon: M,
+ ] }) : /* @__PURE__ */ (0, H.jsx)(o, {
+ icon: F,
title: "清单为空",
size: "compact",
children: "没有需要处理的作品。"
@@ -149,21 +149,21 @@ function H({ group: e, openItem: n, receipt: r }) {
});
}
// src/react/diagnostics/scraping-export.tsx
-var U = "/api/diagnostics/exports", W = ["diagnostic-export"];
-function G({ kind: r, codes: i = "" }) {
- let a = N(), o = P({
- queryKey: W,
- queryFn: ({ signal: e }) => S(U, e),
+var K = "/api/diagnostics/exports", q = ["diagnostic-export"];
+function J({ kind: r, codes: i = "", children: a }) {
+ let o = I(), s = L({
+ queryKey: q,
+ queryFn: ({ signal: e }) => ee(K, e),
refetchInterval: (e) => ["running", "cancelling"].includes(e.state.data?.status || "") ? 1e3 : !1
- }), s = o.data, c = s?.kind === r, l = s?.status === "running" || s?.status === "cancelling", u = r === "support" ? "下载诊断报告" : "导出刮削记录", d = (e) => {
- te.setQueryData(W, e);
- }, f = () => void a.run("start", async (t) => {
- let n = await fetch(U, {
+ }), c = s.data, l = c?.kind === r, u = c?.status === "running" || c?.status === "cancelling", d = r === "support" ? "下载诊断报告" : "导出刮削记录", f = (e) => {
+ j.setQueryData(q, e);
+ }, p = () => void o.run("start", async (t) => {
+ let n = await fetch(K, {
method: "POST",
signal: t,
credentials: "same-origin",
headers: {
- ...await E(),
+ ...await T(),
"Content-Type": "application/json"
},
body: JSON.stringify({
@@ -174,110 +174,98 @@ function G({ kind: r, codes: i = "" }) {
if (!n.ok) throw new e(a?.detail || a?.error || "诊断导出未启动", n.status, a);
if (!a || !a.job_id) throw Error("导出任务状态未取得");
return a;
- }, d), p = () => void a.run("cancel", (e) => C(`${U}/${s.job_id}/cancel`, {}, "POST", e), d);
- return /* @__PURE__ */ (0, z.jsxs)("div", {
+ }, f), h = () => void o.run("cancel", (e) => x(`${K}/${c.job_id}/cancel`, {}, "POST", e), f);
+ return /* @__PURE__ */ (0, H.jsxs)("div", {
className: "flex min-w-0 flex-col gap-3",
children: [
- /* @__PURE__ */ (0, z.jsxs)("div", {
- className: "flex flex-wrap gap-2",
+ /* @__PURE__ */ (0, H.jsxs)("div", {
+ className: r === "support" ? "flex flex-wrap justify-end gap-2" : "flex flex-wrap gap-2",
children: [
- /* @__PURE__ */ (0, z.jsx)(t, {
+ /* @__PURE__ */ (0, H.jsx)(t, {
type: "button",
variant: "secondary",
- disabled: l,
- ...w(a.busy === "start"),
- onClick: f,
- children: u
+ disabled: u,
+ ...S(o.busy === "start"),
+ onClick: p,
+ children: d
}),
- c && l ? /* @__PURE__ */ (0, z.jsx)(t, {
+ l && u ? /* @__PURE__ */ (0, H.jsx)(t, {
type: "button",
variant: "secondary",
- disabled: s.status === "cancelling",
- ...w(a.busy === "cancel"),
- onClick: p,
+ disabled: c.status === "cancelling",
+ ...S(o.busy === "cancel"),
+ onClick: h,
children: "取消导出"
}) : null,
- c && s.status === "complete" && s.download_url ? /* @__PURE__ */ (0, z.jsx)(n, {
+ l && c.status === "complete" && c.download_url ? /* @__PURE__ */ (0, H.jsx)(n, {
variant: "secondary",
- href: s.download_url,
+ href: c.download_url,
children: "下载已生成的文件"
- }) : null
+ }) : null,
+ a
]
}),
- c && l ? s.total && s.total > 0 ? /* @__PURE__ */ (0, z.jsxs)("div", {
- className: "flex flex-col gap-2",
- role: "status",
- children: [/* @__PURE__ */ (0, z.jsxs)("span", {
- className: "text-body-2-regular",
- children: [
- s.stage,
- " · ",
- s.done || 0,
- " / ",
- s.total,
- " 项"
- ]
- }), /* @__PURE__ */ (0, z.jsx)(g, {
- label: "导出进度",
- value: s.done || 0,
- max: s.total
- })]
- }) : /* @__PURE__ */ (0, z.jsx)(m, { label: `${s.stage || "准备导出"}${s.rows ? ` · ${s.rows} 条候选` : ""}${s.files ? ` · ${s.files} 个文件` : ""}` }) : null,
- c && s.status === "complete" ? /* @__PURE__ */ (0, z.jsxs)("p", {
+ l && u ? /* @__PURE__ */ (0, H.jsx)(y, {
+ embedded: r === "scraping",
+ value: c.done || 0,
+ total: c.total,
+ label: c.total ? `${c.stage} · ${c.done || 0} / ${c.total} 项` : `${c.stage || "准备导出"}${c.rows ? ` · ${c.rows} 条候选` : ""}${c.files ? ` · ${c.files} 个文件` : ""}`
+ }) : null,
+ l && c.status === "complete" ? /* @__PURE__ */ (0, H.jsxs)("p", {
role: "status",
className: "text-body-2-regular text-text-secondary",
children: [
"导出已完成 · ",
- ((s.bytes || 0) / 1024 / 1024).toFixed(2),
+ ((c.bytes || 0) / 1024 / 1024).toFixed(2),
" MiB"
]
}) : null,
- c && s.status === "cancelled" ? /* @__PURE__ */ (0, z.jsx)(h, {
+ l && c.status === "cancelled" ? /* @__PURE__ */ (0, H.jsx)(m, {
tone: "neutral",
children: "导出已取消"
}) : null,
- o.isError ? /* @__PURE__ */ (0, z.jsx)(h, {
+ s.isError ? /* @__PURE__ */ (0, H.jsx)(m, {
tone: "error",
- action: /* @__PURE__ */ (0, z.jsx)(t, {
+ action: /* @__PURE__ */ (0, H.jsx)(t, {
type: "button",
variant: "secondary",
- ...w(o.isFetching),
+ ...S(s.isFetching),
onClick: () => {
- o.refetch();
+ s.refetch();
},
children: "重新读取"
}),
children: "导出进度未取得"
}) : null,
- a.error || c && s.status === "failed" ? /* @__PURE__ */ (0, z.jsx)(h, {
+ o.error || l && c.status === "failed" ? /* @__PURE__ */ (0, H.jsx)(m, {
tone: "error",
- children: a.error || s?.error
+ children: o.error || c?.error
}) : null
]
});
}
-function K() {
- let [e, t] = (0, R.useState)("");
- return /* @__PURE__ */ (0, z.jsx)(l, {
+function Y() {
+ let [e, t] = (0, V.useState)("");
+ return /* @__PURE__ */ (0, H.jsx)(l, {
layout: "stack",
labelledBy: "scraping-export-title",
- footer: /* @__PURE__ */ (0, z.jsx)(G, {
+ footer: /* @__PURE__ */ (0, H.jsx)(J, {
kind: "scraping",
codes: e
}),
- children: /* @__PURE__ */ (0, z.jsxs)("div", {
+ children: /* @__PURE__ */ (0, H.jsxs)("div", {
className: "flex min-w-0 flex-col gap-4",
"aria-label": "导出刮削记录",
children: [
- /* @__PURE__ */ (0, z.jsx)(u, {
+ /* @__PURE__ */ (0, H.jsx)(u, {
id: "scraping-export-title",
children: "刮削记录"
}),
- /* @__PURE__ */ (0, z.jsx)("p", {
+ /* @__PURE__ */ (0, H.jsx)("p", {
className: "text-body-2-regular text-text-secondary",
children: "导出作品资料、来源取值及演员、厂牌和系列归属,供排查刮削错误。"
}),
- /* @__PURE__ */ (0, z.jsx)(d, {
+ /* @__PURE__ */ (0, H.jsx)(d, {
label: "问题番号(可选)",
name: "scraping-codes",
value: e,
@@ -293,7 +281,7 @@ function K() {
});
}
// src/react/diagnostics/diagnostics-page.tsx
-var q = {
+var X = {
ok: "正常",
warning: "需检查",
failed: "需处理",
@@ -301,7 +289,7 @@ var q = {
disabled: "未配置",
stale: "待复查",
unchecked: "尚无记录"
-}, J = { "/tasks": "查看任务" }, Y = [
+}, te = { "/tasks": "查看任务" }, ne = [
["媒体库与挂载", ["media_mounts", "data_root"]],
["数据库与迁移", ["database", "schema"]],
["工具", ["ffmpeg"]],
@@ -312,150 +300,152 @@ var q = {
"version"
]],
["后台任务", ["tasks"]]
-], X = (e) => new Date(e).toLocaleString();
-function Z({ status: e }) {
- return /* @__PURE__ */ (0, z.jsx)(r, {
+], Z = (e) => new Date(e).toLocaleString();
+function Q({ status: e }) {
+ return /* @__PURE__ */ (0, H.jsx)(r, {
variant: "caption",
"data-diagnostic-status": e,
color: e === "failed" ? "rose" : e === "ok" ? "lime" : e === "warning" || e === "stale" ? "yellow" : "neutral",
- children: q[e] ?? "未取得"
+ children: X[e] ?? "未取得"
});
}
-function Q() {
- return /* @__PURE__ */ (0, z.jsx)(G, { kind: "support" });
+function re() {
+ return /* @__PURE__ */ (0, H.jsx)(J, { kind: "support" });
}
function $({ name: e, check: t, compact: r = !1 }) {
- let i = t.target === "/settings/library" && (e === "security" || e === "port") ? ie("网络与访问") : t.target, a = r ? "h4" : "h3";
- return /* @__PURE__ */ (0, z.jsxs)("div", {
+ let i = t.target === "/settings/library" && (e === "security" || e === "port") ? P("网络与访问") : t.target, a = r ? "h4" : "h3";
+ return /* @__PURE__ */ (0, H.jsxs)("div", {
"data-diagnostic-check": e,
- className: T("flex flex-col gap-4 border-b border-separator-border pr-3 last:border-b-0 sm:flex-row sm:items-center sm:justify-between", r ? "py-3" : "py-5"),
- children: [/* @__PURE__ */ (0, z.jsxs)("div", {
- className: T("flex min-w-0 flex-1 flex-col", r ? "gap-1" : "gap-2"),
+ className: w("flex flex-col gap-4 border-b border-separator-border pr-3 last:border-b-0 sm:flex-row sm:items-center sm:justify-between", r ? "py-3" : "py-5"),
+ children: [/* @__PURE__ */ (0, H.jsxs)("div", {
+ className: w("flex min-w-0 flex-1 flex-col", r ? "gap-1" : "gap-2"),
children: [
- /* @__PURE__ */ (0, z.jsxs)("div", {
+ /* @__PURE__ */ (0, H.jsxs)("div", {
className: "flex flex-wrap items-center gap-3",
- children: [/* @__PURE__ */ (0, z.jsx)(a, {
- className: T("text-text-primary", r ? "text-body-2-medium" : "text-body-medium"),
+ children: [/* @__PURE__ */ (0, H.jsx)(a, {
+ className: w("text-text-primary", r ? "text-body-2-medium" : "text-body-medium"),
children: t.label
- }), /* @__PURE__ */ (0, z.jsx)(Z, { status: t.status })]
+ }), /* @__PURE__ */ (0, H.jsx)(Q, { status: t.status })]
}),
- /* @__PURE__ */ (0, z.jsx)("p", {
+ /* @__PURE__ */ (0, H.jsx)("p", {
"data-check-reason": !0,
- className: T("text-body-2-regular break-words", r ? "text-text-secondary" : "text-text-primary"),
+ className: w("text-body-2-regular break-words", r ? "text-text-secondary" : "text-text-primary"),
children: t.reason
}),
- t.action ? /* @__PURE__ */ (0, z.jsxs)("p", {
+ t.action ? /* @__PURE__ */ (0, H.jsxs)("p", {
className: "text-body-2-regular text-text-secondary",
children: ["处理建议:", t.action]
}) : null
]
- }), i ? /* @__PURE__ */ (0, z.jsx)("div", {
+ }), i ? /* @__PURE__ */ (0, H.jsx)("div", {
className: "shrink-0 self-end sm:self-auto",
- children: /* @__PURE__ */ (0, z.jsx)(n, {
+ children: /* @__PURE__ */ (0, H.jsx)(n, {
size: "small",
variant: "secondary",
href: i,
- children: i.startsWith("/settings/") ? `打开${ee(i)}` : J[i] ?? "打开相关页面"
+ children: i.startsWith("/settings/") ? `打开${C(i)}` : te[i] ?? "打开相关页面"
})
}) : null]
});
}
-function ae(e) {
- let r = P({
+function ie(e) {
+ let r = L({
queryKey: i,
- queryFn: ({ signal: e }) => k(e),
+ queryFn: ({ signal: e }) => O(e),
staleTime: 1e4
- }), o = N(), [l, u] = (0, R.useState)(""), d = () => void o.run("refresh", async () => {
+ }), o = I(), [l, u] = (0, V.useState)(""), d = () => void o.run("refresh", async () => {
let e = await r.refetch();
if (e.error) throw e.error;
return e.data;
- }, () => u(""), (e) => u(O(e))), f = r.data;
- if (!f && r.isPending) return /* @__PURE__ */ (0, z.jsx)("div", {
+ }, () => u(""), (e) => u(D(e))), f = r.data;
+ if (!f && r.isPending) return /* @__PURE__ */ (0, H.jsx)("div", {
role: "status",
"aria-label": "正在读取系统诊断",
- dangerouslySetInnerHTML: { __html: D() }
+ dangerouslySetInnerHTML: { __html: E() }
});
- if (!f) return /* @__PURE__ */ (0, z.jsxs)("div", {
+ if (!f) return /* @__PURE__ */ (0, H.jsxs)("div", {
className: "ui-configpage",
children: [
- /* @__PURE__ */ (0, z.jsx)(Q, {}),
- /* @__PURE__ */ (0, z.jsx)(h, {
+ /* @__PURE__ */ (0, H.jsx)(re, {}),
+ /* @__PURE__ */ (0, H.jsx)(m, {
tone: "error",
title: "诊断读取失败",
- action: /* @__PURE__ */ (0, z.jsx)(t, {
+ action: /* @__PURE__ */ (0, H.jsx)(t, {
variant: "secondary",
onClick: d,
- ...w(o.busy === "refresh"),
+ ...S(o.busy === "refresh"),
children: "重新检查"
}),
- children: r.error ? O(r.error) : "诊断报告未取得。"
+ children: r.error ? D(r.error) : "诊断报告未取得。"
}),
- /* @__PURE__ */ (0, z.jsx)(K, {})
+ /* @__PURE__ */ (0, H.jsx)(Y, {})
]
});
let p = Object.entries(f.checks).filter(([, e]) => [
"warning",
"failed",
"unknown"
- ].includes(e.status)), m = Object.entries(f.checks).filter(([, e]) => ![
+ ].includes(e.status)), y = Object.entries(f.checks).filter(([, e]) => ![
"warning",
"failed",
"unknown"
].includes(e.status));
- return /* @__PURE__ */ (0, z.jsxs)("div", {
+ return /* @__PURE__ */ (0, H.jsxs)("div", {
className: "flex min-w-0 flex-col gap-6",
children: [
- /* @__PURE__ */ (0, z.jsxs)("div", {
+ /* @__PURE__ */ (0, H.jsx)("div", {
"data-guide-target": "report",
- className: "flex flex-wrap justify-end gap-2",
- children: [/* @__PURE__ */ (0, z.jsx)(Q, {}), /* @__PURE__ */ (0, z.jsx)(t, {
- variant: "secondary",
- onClick: d,
- ...w(o.busy === "refresh"),
- children: "重新检查"
- })]
+ children: /* @__PURE__ */ (0, H.jsx)(J, {
+ kind: "support",
+ children: /* @__PURE__ */ (0, H.jsx)(t, {
+ variant: "secondary",
+ onClick: d,
+ ...S(o.busy === "refresh"),
+ children: "重新检查"
+ })
+ })
}),
- l ? /* @__PURE__ */ (0, z.jsx)(h, {
+ l ? /* @__PURE__ */ (0, H.jsx)(m, {
tone: "error",
children: l
}) : null,
- p.length ? /* @__PURE__ */ (0, z.jsx)(_, {
+ p.length ? /* @__PURE__ */ (0, H.jsx)(h, {
guide: "attention",
title: `需要关注 · ${p.length} 项`,
- children: p.map(([e, t]) => /* @__PURE__ */ (0, z.jsx)($, {
+ children: p.map(([e, t]) => /* @__PURE__ */ (0, H.jsx)($, {
name: e,
check: t
}, e))
}) : null,
- /* @__PURE__ */ (0, z.jsx)(_, {
+ /* @__PURE__ */ (0, H.jsx)(h, {
guide: "health",
title: "库健康",
- children: /* @__PURE__ */ (0, z.jsxs)(b, { children: [f.library.issue_at ? /* @__PURE__ */ (0, z.jsxs)("p", {
+ children: /* @__PURE__ */ (0, H.jsxs)(v, { children: [f.library.issue_at ? /* @__PURE__ */ (0, H.jsxs)("p", {
className: "text-body-2-regular text-text-secondary",
- children: ["处理记录 · ", X(f.library.issue_at)]
- }) : null, Object.entries(f.library.groups).map(([t, n]) => /* @__PURE__ */ (0, z.jsx)(H, {
+ children: ["处理记录 · ", Z(f.library.issue_at)]
+ }) : null, Object.entries(f.library.groups).map(([t, n]) => /* @__PURE__ */ (0, H.jsx)(G, {
group: n,
...e
}, t))] })
}),
- m.length ? /* @__PURE__ */ (0, z.jsx)("section", {
+ y.length ? /* @__PURE__ */ (0, H.jsx)("section", {
"aria-label": "系统检查",
- children: /* @__PURE__ */ (0, z.jsx)(a, {
- summary: `其他检查 · ${m.length} 项`,
+ children: /* @__PURE__ */ (0, H.jsx)(a, {
+ summary: `其他检查 · ${y.length} 项`,
contentClassName: "gap-5",
- children: Y.map(([e, t]) => {
- let n = m.filter(([e]) => t.some((t) => t === e));
- return n.length ? /* @__PURE__ */ (0, z.jsxs)("section", {
+ children: ne.map(([e, t]) => {
+ let n = y.filter(([e]) => t.some((t) => t === e));
+ return n.length ? /* @__PURE__ */ (0, H.jsxs)("section", {
"aria-label": e,
"data-diagnostic-group": "",
className: "flex min-w-0 flex-col gap-2",
- children: [/* @__PURE__ */ (0, z.jsxs)("h3", {
+ children: [/* @__PURE__ */ (0, H.jsxs)("h3", {
className: "flex items-center gap-2 px-3 text-body-medium text-text-primary",
- children: [e, /* @__PURE__ */ (0, z.jsxs)("span", {
+ children: [e, /* @__PURE__ */ (0, H.jsxs)("span", {
className: "text-caption-1-regular text-text-secondary",
children: [n.length, " 项"]
})]
- }), /* @__PURE__ */ (0, z.jsx)(v, { children: n.map(([e, t]) => /* @__PURE__ */ (0, z.jsx)($, {
+ }), /* @__PURE__ */ (0, H.jsx)(g, { children: n.map(([e, t]) => /* @__PURE__ */ (0, H.jsx)($, {
name: e,
check: t,
compact: !0
@@ -464,44 +454,44 @@ function ae(e) {
})
})
}) : null,
- /* @__PURE__ */ (0, z.jsx)(K, {}),
- /* @__PURE__ */ (0, z.jsxs)("section", {
+ /* @__PURE__ */ (0, H.jsx)(Y, {}),
+ /* @__PURE__ */ (0, H.jsxs)("section", {
"data-guide-target": "sessions",
"aria-label": "来源会话",
className: "flex min-w-0 flex-col gap-3",
children: [
- /* @__PURE__ */ (0, z.jsx)(y, { children: "来源会话" }),
- f.sources.map((e) => /* @__PURE__ */ (0, z.jsx)("article", {
+ /* @__PURE__ */ (0, H.jsx)(_, { children: "来源会话" }),
+ f.sources.map((e) => /* @__PURE__ */ (0, H.jsx)("article", {
"data-diagnostic-source": e.source,
- children: /* @__PURE__ */ (0, z.jsx)(v, { children: /* @__PURE__ */ (0, z.jsxs)(b, { children: [
- /* @__PURE__ */ (0, z.jsxs)("div", {
+ children: /* @__PURE__ */ (0, H.jsx)(g, { children: /* @__PURE__ */ (0, H.jsxs)(v, { children: [
+ /* @__PURE__ */ (0, H.jsxs)("div", {
className: "flex flex-wrap items-center justify-between gap-2",
- children: [/* @__PURE__ */ (0, z.jsxs)("h3", {
+ children: [/* @__PURE__ */ (0, H.jsxs)("h3", {
className: "flex min-w-0 items-center gap-2 text-body-medium text-text-primary",
- children: [/* @__PURE__ */ (0, z.jsx)(L, { source: e.source }), e.label]
- }), /* @__PURE__ */ (0, z.jsx)(Z, { status: e.status })]
+ children: [/* @__PURE__ */ (0, H.jsx)(B, { source: e.source }), e.label]
+ }), /* @__PURE__ */ (0, H.jsx)(Q, { status: e.status })]
}),
- /* @__PURE__ */ (0, z.jsx)(F, {
+ /* @__PURE__ */ (0, H.jsx)(R, {
text: e.reason,
className: "text-body-regular text-text-primary"
}),
- /* @__PURE__ */ (0, z.jsxs)(c, { children: [
- /* @__PURE__ */ (0, z.jsx)(s, {
+ /* @__PURE__ */ (0, H.jsxs)(c, { children: [
+ /* @__PURE__ */ (0, H.jsx)(s, {
term: "上次解析成功",
- children: e.last_success_at ? X(e.last_success_at) : "尚无成功记录"
+ children: e.last_success_at ? Z(e.last_success_at) : "尚无成功记录"
}),
- e.last_check_at ? /* @__PURE__ */ (0, z.jsxs)(s, {
+ e.last_check_at ? /* @__PURE__ */ (0, H.jsxs)(s, {
term: "上次检查",
- children: [X(e.last_check_at), e.elapsed_s !== void 0 && e.elapsed_s !== null ? ` · ${e.elapsed_s.toFixed(2)} 秒` : ""]
+ children: [Z(e.last_check_at), e.elapsed_s !== void 0 && e.elapsed_s !== null ? ` · ${e.elapsed_s.toFixed(2)} 秒` : ""]
}) : null,
- /* @__PURE__ */ (0, z.jsx)(s, {
+ /* @__PURE__ */ (0, H.jsx)(s, {
term: "暂停访问至",
- children: e.cooldown_until ? X(e.cooldown_until) : "未暂停"
+ children: e.cooldown_until ? Z(e.cooldown_until) : "未暂停"
})
] })
] }) })
}, e.source)),
- /* @__PURE__ */ (0, z.jsx)("div", { children: /* @__PURE__ */ (0, z.jsx)(n, {
+ /* @__PURE__ */ (0, H.jsx)("div", { children: /* @__PURE__ */ (0, H.jsx)(n, {
size: "small",
variant: "secondary",
href: "/sources",
@@ -512,6 +502,6 @@ function ae(e) {
]
});
}
-export { ae as DiagnosticsPage };
+export { ie as DiagnosticsPage };
-//# debugId=6af8e849-7d10-4c99-9069-a7bbd03bfb41
\ No newline at end of file
+//# debugId=2cc05748-2a4c-4130-93b7-a6ff4beab2d8
\ No newline at end of file
diff --git a/web/dist/peach-app.jav-page-C2bS144a.js b/web/dist/peach-app.jav-page-DUZe3Cv7.js
similarity index 99%
rename from web/dist/peach-app.jav-page-C2bS144a.js
rename to web/dist/peach-app.jav-page-DUZe3Cv7.js
index c48e01de5..69ee9b09d 100644
--- a/web/dist/peach-app.jav-page-C2bS144a.js
+++ b/web/dist/peach-app.jav-page-DUZe3Cv7.js
@@ -1,7 +1,7 @@
(function() {
try {
var e = typeof globalThis < "u" ? globalThis : typeof window < "u" ? window : typeof global < "u" ? global : typeof self < "u" ? self : {}, t = new e.Error().stack;
- t && (e._sentryDebugIds = e._sentryDebugIds || {}, e._sentryDebugIds[t] = "16f7f01e-86e5-4d9c-ab8a-5510149ba395", e._sentryDebugIdIdentifier = "sentry-dbid-16f7f01e-86e5-4d9c-ab8a-5510149ba395");
+ t && (e._sentryDebugIds = e._sentryDebugIds || {}, e._sentryDebugIds[t] = "bf58e55d-c7b8-47af-9c17-200b1573e873", e._sentryDebugIdIdentifier = "sentry-dbid-bf58e55d-c7b8-47af-9c17-200b1573e873");
} catch {}
})();
import { $fe21c36db05242bb$export$d7b12c4107be0d61 as e, ArtSlot as t, Button as n, ButtonLink as r, Chip as i, CloudDownloadDialog as a, DISCOVERY_SORTS as o, DOWNLOADS_KEY as s, DOWNLOADS_URL as c, E3 as l, EmptyFocusButton as u, EmptyState as d, FilterGlassRows as f, FilterIconButton as p, FilterPill as m, GlassPill as h, Help as g, Input as _, JAV_LAYOUTS as v, JAV_RECOMMENDATION_GRID as ee, JavHeader as y, LibraryShortcuts as te, M6 as b, Note as x, PHASES as S, Pagination as C, SEGMENT as w, SEGMENTED_TRACK as T, SegmentedRadioGroup as E, Segments as ne, SortKeys as re, SourceAvatar as ie, TaskProgress as ae, WANTS_KEY as oe, WantMagnets as D, Wt as se, __toESM as ce, addWant as le, apiGet as O, appSettingsStore as ue, avatarInner as k, busyProps as A, cachedMagnetStates as j, cardClass as M, cardRatio as de, coverUrl as fe, discoveryArtwork as pe, discoveryKey as me, discoveryScore as he, entityDisplayName as N, entityPath as ge, errorMessage as P, fetchDiscoveries as _e, fetchWants as F, gridLayout as ve, invalidateWants as I, javContentSkeleton as ye, javLayout as be, javTagSkeleton as xe, pageWindow as L, peachHistory$1 as R, qE as z, recommendationScore as Se, relayoutCovers as Ce, removeWants as B, require_jsx_runtime as V, require_react as H, resetWants as U, searchNote as W, shellNavigate as G, spriteGlyph as K, storeJavLayout as we, textLang as Te, useAction as q, useEntityNames as J, useQuery as Y, wantName as X, wireHorizontalScroller as Ee } from "./peach-app.js";
@@ -592,7 +592,6 @@ function Be({ readOnly: e, receipt: a, resource: s, query: c, navigate: u, clear
"data-jav-metadata": "",
className: "min-w-0",
children: /* @__PURE__ */ (0, Q.jsx)(ae, {
- embedded: !0,
label: `正在读取作品资料 · ${V.completed} / ${V.total} 部`,
value: V.completed,
total: V.total
@@ -814,4 +813,4 @@ function Be({ readOnly: e, receipt: a, resource: s, query: c, navigate: u, clear
}
export { ze as JavPage };
-//# debugId=16f7f01e-86e5-4d9c-ab8a-5510149ba395
\ No newline at end of file
+//# debugId=bf58e55d-c7b8-47af-9c17-200b1573e873
\ No newline at end of file
diff --git a/web/dist/peach-app.js b/web/dist/peach-app.js
index da8cba193..21507bc3b 100644
--- a/web/dist/peach-app.js
+++ b/web/dist/peach-app.js
@@ -2,7 +2,7 @@
(function() {
try {
var e = typeof globalThis < "u" ? globalThis : typeof window < "u" ? window : typeof global < "u" ? global : typeof self < "u" ? self : {}, t = new e.Error().stack;
- t && (e._sentryDebugIds = e._sentryDebugIds || {}, e._sentryDebugIds[t] = "a03b049d-cf65-4ed7-98ed-223ad15089da", e._sentryDebugIdIdentifier = "sentry-dbid-a03b049d-cf65-4ed7-98ed-223ad15089da");
+ t && (e._sentryDebugIds = e._sentryDebugIds || {}, e._sentryDebugIds[t] = "5b9cdf81-0f25-447c-8196-620e09223a68", e._sentryDebugIdIdentifier = "sentry-dbid-5b9cdf81-0f25-447c-8196-620e09223a68");
} catch {}
})();
var e = Object.create, t = Object.defineProperty, n = Object.getOwnPropertyDescriptor, r = Object.getOwnPropertyNames, i = Object.getPrototypeOf, a = Object.prototype.hasOwnProperty, o = (e, t) => () => (t || (e((t = { exports: {} }).exports, t, t.exports), e = null), t.exports), s = (e, n) => {
@@ -46065,7 +46065,7 @@ function UH({ label: e, value: t, max: n = 100, stops: r = [] }) {
// src/react/components/task-progress.tsx
function WH({ label: e, value: t = 0, total: n, embedded: r = !1 }) {
return /* @__PURE__ */ (0, I.jsx)("div", {
- "data-task-progress": !0,
+ "data-task-progress": r ? "embedded" : "framed",
className: r ? "flex flex-col gap-1.5" : BH({
variant: "outlined",
padding: "none",
@@ -78430,8 +78430,8 @@ async function g6(e, t) {
if (r.status === "rejected") throw r.reason;
if (n.status === "rejected") throw n.reason;
}
-var _6 = h6(() => import("./peach-app.jav-page-C2bS144a.js")), v6 = h6(() => import("./peach-app.stats-page-DhNggTPt.js")), y6 = h6(() => import("./peach-app.taste-page-O5P41pRb.js")), b6 = h6(() => import("./peach-app.review-page-kd1HFP2A.js")), x6 = h6(() => import("./peach-app.data-cleanup-page-CZOBqkVd.js")), S6 = h6(() => import("./peach-app.duplicates-page-Bau8HIlx.js")), C6 = h6(() => import("./peach-app.quality-goals-page-Deoy7rhD.js")), w6 = h6(() => import("./peach-app.scraping-page-Ddbx11Bn.js")), T6 = h6(async () => {
- let [{ ConfigurationPage: e }, { DiagnosticsPage: t }] = await Promise.all([import("./peach-app.configuration-page-BkqUJk6k.js"), import("./peach-app.diagnostics-page-yTNOV5os.js")]);
+var _6 = h6(() => import("./peach-app.jav-page-DUZe3Cv7.js")), v6 = h6(() => import("./peach-app.stats-page-DhNggTPt.js")), y6 = h6(() => import("./peach-app.taste-page-O5P41pRb.js")), b6 = h6(() => import("./peach-app.review-page-kd1HFP2A.js")), x6 = h6(() => import("./peach-app.data-cleanup-page-CZOBqkVd.js")), S6 = h6(() => import("./peach-app.duplicates-page-Bau8HIlx.js")), C6 = h6(() => import("./peach-app.quality-goals-page-Deoy7rhD.js")), w6 = h6(() => import("./peach-app.scraping-page-Ddbx11Bn.js")), T6 = h6(async () => {
+ let [{ ConfigurationPage: e }, { DiagnosticsPage: t }] = await Promise.all([import("./peach-app.configuration-page-BkqUJk6k.js"), import("./peach-app.diagnostics-page-DS1L_wLs.js")]);
return {
ConfigurationPage: e,
DiagnosticsPage: t
@@ -83585,4 +83585,4 @@ if (!$9) throw Error("主界面宿主缺失");
KRe($9);
export { tR as $2ec61d1d4f780267$export$a8a3e93435678ff9, lR as $3a442827418ebe87$export$eb2fcfdbd7ba97d4, Ez as $542a13ca2fa5b484$export$5b6b19405a83ff9d, AD as $72abaeab4d80592f$export$78efe591171d7d45, vB as $76d00c5a4edb230a$export$76ccd210b9029917, hB as $76d00c5a4edb230a$export$816b5d811295e6bc, xB as $76d00c5a4edb230a$export$b59bdbef9ce70de2, CB as $76d00c5a4edb230a$export$f6f0c3fe4ec306ea, mB as $76d00c5a4edb230a$export$f850895b287ef28e, fhe as $b4f18e3395fe64d7$export$3d96ec278d3efce4, dhe as $b4f18e3395fe64d7$export$3e41faf802a29e71, che as $b4f18e3395fe64d7$export$b2539bed5023c21c, DB as $b4f18e3395fe64d7$export$e51a686c67fdaa2d, hhe as $bd263d78e9bf3c56$export$f5c9f3c2c4054eec, _E as $ea3928288112382f$export$439d29a4e110a164, zz as $f2ff30fde7b014be$export$3ddf2d174ce01153, Kz as $fe21c36db05242bb$export$a98f0dcb43a68a25, qz as $fe21c36db05242bb$export$d7b12c4107be0d61, Yhe as $l, $j as ACCENTS, Tke as AMANE_BRIDGE_CHECK_URL, Y$ as AMANE_BRIDGE_KEY, Eke as AMANE_BRIDGE_REBUILD_URL, or as ApiError, oW as ArtSlot, p2 as BATCH_DELETE_TEXT, J as Button, NL as ButtonLink, iV as Bx, w$ as CLEANUP_ENTRY, C$ as CLEANUP_ENTRY_GRID, Yf as CLEANUP_HASH_REDIRECTS, qf as CLEANUP_TOOLS, _n as CLOUD_LOCATIONS, Y1 as CLOUD_PROXY_HELP, Gr as COLUMN_SORT, s1 as CONFIGURATION_KEY, iX as CONFIGURATION_URL, Dke as COOKIE_TEXT_LIMIT, J$ as COVER_JOB_KEY, Ji as CREDENTIAL_STATE, W$ as CUSTOM_SOURCES_KEY, U$ as CUSTOM_SOURCES_URL, QV as Checkbox, ZV as CheckboxGlyph, HV as ChevronSortDown, aW as Chip, mW as CloudDownloadDialog, qH as CollapseChevron, KH as CollapseRegion, _$ as CollectionSummary, iwe as DEFAULT_CATEGORY, ur as DEFAULT_SORT, UQ as DIAGNOSTICS_KEY, rTe as DIRECTORY_TEMPLATE_ERROR, A0 as DISCOVERY_SORTS, cW as DOWNLOADS_KEY, sW as DOWNLOADS_URL, wY as DUPLICATES_KEY, aY as DataTableFooter, tY as DataTableFrame, iY as DataTableSort, $H as Disclosure, Uve as DownloadsPanel, Bhe as E3, awe as ENTITY_REVIEW_KINDS, q1 as ENTRY_LINKS_HELP, J1 as ENTRY_LINKS_HINT, XB as Ea, bge as EmptyFocusButton, wV as EmptyState, ZH as ErrorText, U_e as ExternalLink, Br as FEEDS_KEY, fX as FEED_SCHEDULE_KEY, x$ as FIELDSET_FOOT, NPe as FLOW_LABEL_X, q3 as FLOW_VIEWBOX, Rr as FOLLOW_CHECK_KEY, Lr as FOLLOW_CREDENTIALS_KEY, A8 as FOLLOW_INITIAL_RANGE_OPTIONS, Ir as FOLLOW_MANAGE_KEY, KZ as FOLLOW_MANAGE_NAV, zr as FOLLOW_RESOLVE_KEY, dX as FOLLOW_SCHEDULE_KEY, K_e as Fact, G_e as FactList, QH as FieldLabel, P$ as Fieldset, N$ as FieldsetTitle, lpe as FilterGlass, EL as FilterGlassRows, TL as FilterIconButton, DL as FilterPill, H_e as Footer, tV as Gg, OL as GlassPill, cV as HN, XH as Help, hV as HintText, TPe as IDLE_POLL_MS, qCe as IDLE_REPAIR, xL as IconButton, GQ as IndexSearch, bV as Input, yV as InputBase, I$ as IssueRow, _M as JAV_LAYOUTS, M0 as JAV_RECOMMENDATION_GRID, LX as JUNK_KEY, jW as JavHeader, VCe as KEEP_LABELS, Hr as LAYOUTS, K1 as LIBRARY_FOLDER_HELP, dH as LIBRARY_PROCESSING_KEY, XY as LINKS_KEY, ZY as LINK_CHECK_KEY, kwe as LINK_KINDS, QY as LINK_PRUNE_KEY, tr as LOC, mV as Label, z$ as LibraryProcessingCard, VV as LibraryShortcuts, DH as LinkButton, Zhe as Lo, VH as LoadingDots, Vhe as M6, Pwe as MEDIA_PROCESSING_KEY, mX as MEDIA_PROCESSING_URL, kY as MEDIA_REPAIR_KEY, OY as MEDIA_REPAIR_URL, vr as MEDIA_SOURCES_KEY, gs as MEDIA_SOURCE_ICONS, hn as MEDIA_SOURCE_OPTIONS, KV as MENU_ITEM, qV as MENU_ITEM_INTERACTIVE, GV as MENU_POPOVER_SURFACE, $he as Ma, jH as MenuDialog, bK as MixCard, xV as ModalFrame, Tx as MotionConfigContext, fV as NR, F$ as NameLink, CV as Note, gge as OA, _X as ORGANIZE_KEY, u2 as ORGANIZE_PARAMETER_HINT, l2 as ORGANIZE_SCOPE_HINT, c2 as ORGANIZE_TEXT, bX as ORPHAN_RECORDS_KEY, f2 as ORPHAN_RECORDS_TEXT, $B as OV, RB as P7, PX as PERFORMER_DELETE_KEY, Qve as PHASES, aX as PICK_FOLDER_URL, E$ as PLAIN_STAT_STRIP, V$ as PLAYLISTS_KEY, kAe as POLICY_COLUMNS, jAe as POLICY_COVER_NOTE, AAe as POLICY_MATRIX, G1 as POLICY_SUMMARY, rY as Pagination, R$ as PathLine, uV as Pf, XI as PillTabList, qOe as PlainStat, UH as Progress, PY as QUALITY_GOALS_KEY, lV as RB, O$ as REPAIR_CARD_TEXT, AY as REPAIR_LIBRARIES_KEY, TX as RESOURCE_APPLY_KEY, wX as RESOURCE_SCAN_KEY, d2 as RESOURCE_SYNC_TEXT, $Oe as RESULT_PANEL, eke as RESULT_SECTION, rwe as REVIEW_CATEGORIES, IX as REVIEW_COUNTS_KEY, owe as REVIEW_DECISION_LABELS, LY as REVIEW_KEY, RY as REVIEW_LABELS, BY as REVIEW_QUEUES, VY as REVIEW_QUEUE_LABELS, GG as RetryNote, hge as Rf, pV as Rk, z_e as Rows, Cke as SCRAPING_CHECK_URL, K$ as SCRAPING_COVER_URL, q$ as SCRAPING_KEY, Ske as SCRAPING_SETTINGS_URL, yU as SEGMENT, vU as SEGMENTED_TRACK, uX as SETTINGS_KEY, oX as SETTINGS_URL, dr as SORT_DEFAULT_DIR, lr as SORT_OPTIONS, vn as SOURCE_LABELS, v3 as STATS_KEY, GOe as STAT_STRIP, KOe as STAT_STRIP_SIX, R_e as Section, tke as SectionHeading, V_e as SectionSkeleton, _U as SegmentedRadioGroup, sve as SegmentedTabList, RG as Segments, nY as Select, nW as Select$1, d1 as SelectField, rW as SelectItem, fY as SelectionActions, jj as SelectionDock, pY as SelectionPopover, JH as SettingsCard, L_e as SettingsRow, YH as SettingsSectionLabel, X_e as SiteLabel, _G as SortDirectionIcon, BG as SortKeys, EQ as SourceAvatar, rU as SourceLabel, eU as SourceMark, B_e as Stack, JOe as StatCard, L$ as StatusLabel, fge as Su, X2 as Switch, aL as TASKS_KEY, mPe as TASTE_REFRESH_KEY, hPe as TASTE_WINDOWS, pX as THUMBNAIL_JOBS_KEY, zX as TRASH_KEY, Hfe as TRIGGER_LABELS, KJ as Table, mY as TableColumnControls, hY as TableColumnResizer, _Y as TableSelectionHeader, f$ as TagManager, W_e as TaskCenterLink, WH as TaskProgress, _V as TextField, gV as TextFieldContext, ZB as Un, gW as WANTS_KEY, d4 as WantMagnets, Gg as WithPromise, HB as Wt, YB as Xc, dV as Xf, WB as Xl, UB as Xt, BB as _8, o as __commonJSMin, s as __exportAll, l as __toESM, mge as aB, Ti as addAlias, wi as addSource, vW as addWant, mS as animate, B as apiGet, V as apiSend, dM as appSettingsStore, STe as applyConfirmText, NX as applyLeftovers, xTe as applyPlanText, wTe as applyText, hM as applyTheme, yy as asNumber, uTe as attachOrphan, si as authorAvatar, li as authorGroups, oi as authorInitial, ai as authorName, Pq as autoResetPageIndex, go as avatarInner, w3 as bandRows, iTe as baseName, KCe as batchOperate, fue as beginPlayerGuidePreview, Ij as boundedPreference, UCe as bulkCloudPreferences, OV as busyProps, pge as cB, UMe as cachedMagnetStates, zg as calcGeneratorVelocity, pwe as canApprove, mg as cancelFrame, hTe as candidateText, BH as cardClass, AM as cardRatio, JB as cc, Wi as checkEvidenceGap, Ui as checkFailures, Pi as checkFeeds, Nwe as checkLine, Vi as checkReceipt, Hi as checkSummary, kke as checkText, Gi as checkedText, oK as clickedBlank, q5 as closeDrawerAfterNav, FCe as cloudLocations, E0 as cloudProxySkeleton, XC as clsx, nge as cn, cv as collectMotionValues, eJ as columnVisibilityFeature, VJ as column_getCanSort, LJ as column_getSortFn, dwe as commonReviewSources, Of as configurationSection, yPe as configureTasteBrowser, ol as confirmModal, Bfe as controlTask, gq as copyInstancePropertiesWithoutMemos, co as coverUrl, Gq as createColumnHelper, gke as createPlaylist, Yi as credentialDone, S0 as credentialsSkeleton, Swe as currentReviewRow, q as cx, rV as dZ, ywe as decisionPayload, bwe as decisionReceipt, vwe as defaultChoice, ETe as deletePerformerVideos, vke as deletePlaylist, x as diagnosticHeaders, W1 as diagnosticsSkeleton, EW as discoveryArtwork, wW as discoveryKey, tje as discoveryScore, i9 as disposeStage, zCe as distinctName, zi as dropSources, dge as du, WCe as duplicateVictims, fL as elapsedText, tn as entityDisplayName, ho as entityFaceImg, Nn as entityPath, ei as errorHeadline, cr as errorMessage, z as esc, Nq as expandRowModel, MB as f1, $r as feedIntervalText, Q$ as fetchAmaneBridge, _i as fetchCheckJob, c1 as fetchConfiguration, Z$ as fetchCoverJob, gi as fetchCredentials, G$ as fetchCustomSources, FX as fetchDeletePerformers, TTe as fetchDeletePlan, WQ as fetchDiagnostics, TW as fetchDiscoveries, EY as fetchDuplicates, Ife as fetchEarlier, Lwe as fetchFeedSchedule, ji as fetchFeeds, hi as fetchFollow, Iwe as fetchFollowSchedule, VX as fetchJunkSummary, yH as fetchLibraryProcessing, tX as fetchLinkCheck, nX as fetchLinkPrune, eX as fetchLinkStats, Fwe as fetchMediaProcessing, jY as fetchMediaRepair, yr as fetchMediaSources, vX as fetchOrganize, Xwe as fetchOrganizeExample, xX as fetchOrphanRecords, Ai as fetchPending, H$ as fetchPlaylists, FY as fetchQualityGoals, MY as fetchRepairLibraries, vi as fetchResolveJob, DX as fetchResourceApply, EX as fetchResourceScan, qY as fetchReview, BX as fetchReviewCounts, hX as fetchSettings, X$ as fetchSources, y3 as fetchStats, yi as fetchSuggestions, sL as fetchTasks, W3 as fetchTaste, bPe as fetchTasteJob, Rwe as fetchThumbnailJobs, HX as fetchTrashSummary, _W as fetchWants, lwe as filterReviewRows, $n as firstGrapheme, QK as flexRender, FPe as flowGraph, IPe as flowLabel, PNe as fmtCount, qn as fmtDur, Yn as fmtSize, Ffe as foldByKind, Qfe as foldRoutine, Ii as followFeedByName, Vr as followSuggestKey, epe as followupDetail, Pfe as followupTally, pg as frame, IB as g4, rJ as getDefaultPaginationState, kM as gridLayout, ci as groupByAuthor, Zfe as groupFollowups, WY as groupReviewRows, yTe as hasChanges, OX as hasResourceRoots, lL as hasResultProblems, EPe as historySpan, NB as i2, wPe as importTasteExport, C0 as indexersSkeleton, Fg as interpolate, xW as invalidateWants, dL as isActive, Qr as isBroken, Kr as isLayout, yv as isMotionValue, zY as isReviewCategory, $fe as isRoutine, w0 as javBrowserSkeleton, P0 as javContentSkeleton, SM as javLayout, N0 as javTagSkeleton, jTe as junkBreakdown, yke as keepPlaylist, ke as keepPreviousData, fi as keepSelected, b3 as known, Ihe as l7, Xfe as latestOfKind, KNe as lengthRows, Sr as localTime, Fi as lookupFeedActor, LB as m7, nV as mM, En as mapLimit, ki as markItem, T3 as max, WNe as mediumRows, Lfe as mergeFinished, E3 as min, Dwe as mirrorText, XCe as missingToolText, DY as mixedCloudPreferences, gL as momentText, hS as motion, uv as motionValue, nn as nameFallback, He as notifyManager, Hhe as oe, oTe as organizeOutcome, X0 as overlayHost, qr as pageSizeOf, di as pageWindow, mr as paginationRange, Ri as patchSource, W as peachHistory, W as peachHistory$1, _we as pendingGenres, INe as percentText, $we as pickOrganizeFolder, T$ as plainStatClass, aTe as planSummary, x3 as playedFor, RNe as playedItemUrl, oL as pollInterval, Js as popCount, hke as posterUrl, Zye as previewLibraryColor, Qwe as previewOrganize, $Ce as previewUrl, Jfe as problemDestination, mH as processingActive, pL as progressText, nU as providerIcon, Mwe as pruneText, AX as purgeCount, dTe as purgeOrphan, aV as pv, uge as qE, H as queryClient, PB as r2, MPe as radarRows, VNe as radialArc, HNe as radialBarSize, BNe as radialCeiling, zNe as radialSlices, KN as randomId, APe as rankDetail, jPe as rankShares, C3 as reachedShare, mL as readableErrorHeadline, nje as recommendationScore, Cwe as recordGenre, pTe as recordsText, bke as recreatePlaylist, pke as refreshPlaylists, Cl as relayoutCovers, Bi as reloadFollowManage, Ewe as reloadReview, PAe as rememberShape, tTe as rememberTemplates, Ei as removeAlias, Ni as removeFeed, Ci as removeSource, CPe as removeTasteSource, yW as removeWants, Di as renameAliasGroup, _ke as renamePlaylist, Se as replaceEqualDeep, JNe as replayRows, re as require_jsx_runtime, A as require_react, N as require_react_dom, fq as require_with_selector, bW as resetWants, pr as resolveFollowSort, Hg as resolveStartTime, f_e as restartEffectText, mke as resumeAssetId, cwe as reviewGroupingOptions, UY as reviewQueueData, HY as reviewQueueOf, ATe as reviewSummary, uwe as reviewWindow, hwe as rowEvidence, KY as rowFieldName, uJ as rowPaginationFeature, jJ as rowSelectionFeature, WJ as rowSortingFeature, GY as rowSubject, gwe as rowTags, mwe as rowTitle, Nhe as s5, Oi as saveCredential, bTe as scanLine, Uwe as schedulePollInterval, CW as searchNote, fwe as selectReviewRange, pi as selectionState, Mi as setFeedEnabled, Si as setSourceEnabled, Mf as settingsPath, Twe as settleReviewRows, RCe as sharedNamePrefix, Ep as shellNavigate, v8 as showToast, zn as siteMarkUrl, wq as skipFirstRun, JI as sortCx, Yr as sortLabel, yn as sourceDefaultCost, qi as sourceIconUrl, CTe as sourceMeta, zs as spinnerHtml, Ng as spring, EV as spriteGlyph, bi as startCheck, Awe as startLinkCheck, jwe as startLinkPrune, eTe as startOrganize, xi as startResolve, _Te as startResourceApply, gTe as startResourceScan, SPe as startTasteRefresh, WOe as statCardClass, Wfe as statusLabel, YCe as statusLine, Zr as statusText, jM as storeJavLayout, xwe as submitDecision, _L as summaryItems, Kq as tableFeatures, Tq as tableMemo, ui as tableRows, qfe as taskIssues, Yfe as taskSubject, G3 as tasteDate, OPe as tasteDimensions, DPe as tasteHours, U3 as tasteKey, _Pe as tasteRefetchInterval, vPe as tasteTime, eL as textLang, $m as time, qhe as tl, mi as toggleGroup, K3 as topScores, ige as um, Qhe as uo, OH as useAction, VZ as useBackgroundJob, JU as useClientUpdates, dm as useConstant, vL as useEntityNames, wL as useHorizontalScroller, fm as useIsomorphicLayoutEffect, aK as useLibraryTints, Ft as useMutation, $V as useOverlayScrollbar, Pt as useQuery, ae as useQueryClient, rS as useReducedMotion, Hwe as useRunSchedule, Bwe as useSaveFollowSchedule, gX as useSaveSettings, Wwe as useSaveThumbnailMode, GJ as useTable, cY as useTablePreferences, jL as useViewGlide, GCe as victimBytes, Jhe as vl, SW as wantName, LNe as watchNote, S3 as watchedShare, Dc as wireHorizontalScroller, nTe as withOrganizeJob };
-//# debugId=a03b049d-cf65-4ed7-98ed-223ad15089da
\ No newline at end of file
+//# debugId=5b9cdf81-0f25-447c-8196-620e09223a68
\ No newline at end of file